PageSourceSearch

https://noelillart.com/js/72c5eb94e5bf.js

js noelillart.com collected 2026-10-05 01:43:48 UTC 1,196,757 bytes, 1 lines download raw bytes

1(self.webpackChunktumblr=self.webpackChunktumblr||[]).push([[939],{187(e,t,i){"use strict";var n=i(81515),s=i(19698),o=i(19061),r=s.extend({getName:function(){return"embed"},getLabel:function(){return n("Embed")},getType:function(){return s.TYPE_SUBVIEW},getSubviewConstructor:function(){return o},getSubviewOptions:function(){return{embedCode:this.postModel.getEmbedCode()}}});e.exports=r},471(e,t,i){"use strict";var n=i(27513),s=i(45427),o=n.extend({model:s});e.exports=o},745(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<a href=\"#\" class=\"compose-toggle compose-start\" data-js-compose-toggle>' +\n__e( message ) +\n'</a><a href=\"#\" class=\"compose-toggle compose-cancel\" data-js-compose-toggle>' +\n__e( __('Nevermind') ) +\n'</a>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},892(e,t,i){var n=i(55679),s=i(50226);e.exports=function(e){var t=n.result(e,"logKey"),i=n.result(e,"logEnv");if(t){var o=n.result(e,"logOptions")||{};return i&&(o.env=i),s.log(t,o)}}},1100(e,t,i){var n=i(55679),s=i(80160).extend({url:"/svc/onlinestatus",parse:function(e){return n.result(e,"response")||{}}});e.exports=s},1218(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"popover popover_menu popover_gradient\"><div class=\"popover_inner\"><ul class=\"popover_inner_list\"> ';\n _.forEach(types, function(type) { ;\n__p += ' ';\n if (!type.active) { ;\n__p += ' <li class=\"popover_menu_item\" data-js-menu-item><a href=\"/explore/' +\n__e( type.id ) +\n'\" class=\"content-control ' +\n((__t = ( (type.id == currentType) ? 'active' : '' )) == null ? '' : __t) +\n'\" style=\"font-weight:bold;\" data-text=\"' +\n__e( type.name ) +\n'\" data-content-type=\"' +\n__e( type.id ) +\n'\"> ' +\n__e( type.name ) +\n' </a></li> ';\n } ;\n__p += ' ';\n }); ;\n__p += ' </ul></div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},1744(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div class=\"results-scroller\" data-subview=\"searchResults[]\"></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},1860(e,t,i){"use strict";var n=i(81515),s=i(19698).extend({defaults:{popupUrl:null,popupOptions:null},getName:function(){return"pinterest"},getLabel:function(){return n("Pinterest")},getPopupOptions:function(){return this.get("popupOptions")},getPopupUrl:function(){return this.get("popupUrl")}});e.exports=s},1991(e,t,i){var n=i(55679),s=i(78947),o=n.keys(s("keys"));e.exports=function(e){return o.indexOf(e.log_key)>=0}},2266(e,t,i){var n=i(55679),s=i(20833);e.exports=function(e,t,i){n.isObject(i)&&s(i),Object.defineProperty(e,t,{value:i,writeable:!1,enumerable:!0,configurable:!1})}},2456(e,t,i){"use strict";var n=i(27513),s=i(37136),o=n.extend({model:s});e.exports=o},2468(e,t,i){var n=i(73142);e.exports=n},2606(e,t,i){"use strict";var n=i(17604).sprintf,s=i(95921).truncateLongStrings;function o(){}o.prototype.genericFieldMap={one:"quote",two:"source"},o.prototype.typeAttributes={quote:"",source:""},o.prototype.generateTweetText=function(e,t){var i,o=this.getHtmlStripped("quote"),r=this.getHtmlStripped("source");return i=(r=r.replace(/[\r\n\s]*\[\[MORE\]\].*$/gi,""))&&o.length+(r.length>1?7:6)<=t?i=n("“%s” - %s",o,r):o?n("“%s”",s(o,t-2)):r,s(i,t)},o.prototype.editorField="two",o.prototype.validate=function(e,t,i){var n=[];return(!t.quote||t.quote.length<1)&&n.push("No quote."),e.call(this,t,{errors:n})},e.exports=o},2616(e,t,i){var n;i.amdD,n=function(e){var t=i(17917),n=t.Promise.all,s=Array.prototype.slice;return function(e){var i=[];return n(s.call(arguments,1)).then(function(n){return t.reduce(e,function(e,i){return t(i.apply(void 0,n),o)},i)});function o(e){return i.push(e),i}}}.call(t,i,t,e),void 0===n||(e.exports=n)},2681(e,t,i){"use strict";var n=i(55679),s=i(28724),o=new s({delegateObject:function(e){var t={},i={};e&&(n.each(e,function(e,n){void 0!==e&&("function"==typeof e?t[n]=e:i[n]=e)},this),s.onto(this,t),n.extend(this,i))}});e.exports=o},2896(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(29970),r=i(97960),a=s.extend({defaults:{include_info_popover:!0,disableUnfollowConfirm:!1},className:"poptica_header",initialize:function(e){this.options=n.extend({},this.defaults,e);var t=n.extend({model:this.model},n.pick(this.options,"targetPost","include_info_popover","disableUnfollowConfirm"));this.header=new o(t),this.posts=new r({model:this.model}),this.bindEvents()},bindEvents:function(){this.listenToOnce(this.header,"ready",this._triggerReady)},_triggerReady:function(){this.trigger("ready")},render:function(){return this.$el.append(this.header.render().el,this.posts.render().el),this}});e.exports=a},3006(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div data-subview=\"textEditor\"></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},3021(e,t,i){"use strict";var n=i(74692),s=i(81441),o=i(96663);e.exports=function(e){var t=n(e.el).find("video[data-crt-video]");return t.length?(e.$video=t,new s(e)):new o(e)}},3211(e){function t(){var e,i;for(i=arguments[0]||{},this.config={},this.config.elements=i.elements?i.elements:[],this.config.attributes=i.attributes?i.attributes:{},this.config.attributes[t.ALL]=this.config.attributes[t.ALL]?this.config.attributes[t.ALL]:[],this.config.allow_comments=!!i.allow_comments&&i.allow_comments,this.allowed_elements={},this.config.protocols=i.protocols?i.protocols:{},this.config.classnames=i.classnames?i.classnames:{},this.config.add_attributes=i.add_attributes?i.add_attributes:{},this.dom=i.dom?i.dom:document,e=0;e<this.config.elements.length;e++)this.allowed_elements[this.config.elements[e]]=!0;
1if(this.config.remove_element_contents={},this.config.remove_all_contents=!1,i.remove_contents)if(i.remove_contents instanceof Array)for(e=0;e<i.remove_contents.length;e++)this.config.remove_element_contents[i.remove_contents[e]]=!0;else this.config.remove_all_contents=!0;this.transformers=i.transformers?i.transformers:[]}t.REGEX_PROTOCOL=/^([A-Za-z0-9\+\-\.\&\;\*\s]*?)(?:\:|&*0*58|&*x0*3a)/i,t.RELATIVE="__RELATIVE__",t.ALL="__ALL__",t.prototype.clean_node=function(e){var i=this.dom.createDocumentFragment();function n(e,t){var i;for(i=0;i<t.length;i++)if(t[i]===e)return i;return-1}function s(){var e,t,i=[],n={};for(e=0;e<arguments.length;e++)if(arguments[e]&&arguments[e].length)for(t=0;t<arguments[e].length;t++)n[arguments[e][t]]||(n[arguments[e][t]]=!0,i.push(arguments[e][t]));return i}function o(e){var t;switch(e.nodeType){case 1:a.call(this,e);break;case 3:case 5:t=e.cloneNode(!1),this.current_element.appendChild(t);break;case 8:this.config.allow_comments&&(t=e.cloneNode(!1),this.current_element.appendChild(t));break;default:console&&console.log&&console.log("unknown node type",e.nodeType)}}function r(e,t){for(var i=[],s=0;s<e.length;s++)-1!==n(e[s],t)&&i.push(e[s]);return i}function a(e){var i,a,c,u,h,d,p,g,f,m=l.call(this,e);if(a=(e=m.node).nodeName.toLowerCase(),i=this.current_element,this.allowed_elements[a]||m.whitelist){this.current_element=this.dom.createElement(e.nodeName),i.appendChild(this.current_element);var _=this.config.attributes;for(c=s(_[a],_[t.ALL],m.attr_whitelist),this.config.classnames[a]&&this.config.classnames[a].length&&c.push("class"),y=0;y<c.length;y++){h=c[y];var v="object"==typeof c[y]||c[y]instanceof Object;if(h=v?c[y].name:c[y],u=e.attributes[h]){var b=(p=u.value).toLowerCase();if(f=!0,this.config.protocols[a]&&this.config.protocols[a][h])for(var y in f=!1,(g=this.config.protocols[a][h]).push(t.RELATIVE),g)if(0===b.indexOf(g[y].toLowerCase())){f=!0;break}"class"===h&&this.config.classnames[a]&&(f=!!(p=r(p.split(" "),this.config.classnames[a]).join(" "))),v&&(f=b.match(c[y].value)),f&&((d=document.createAttribute(h)).value=p,this.current_element.setAttributeNode(d))}}if(this.config.add_attributes[a])for(h in this.config.add_attributes[a])(d=document.createAttribute(h)).value=this.config.add_attributes[a][h],this.current_element.setAttributeNode(d)}else if(-1!==n(e,this.whitelist_nodes)){for(this.current_element=e.cloneNode(!0);this.current_element.childNodes.length>0;)this.current_element.removeChild(this.current_element.firstChild);i.appendChild(this.current_element)}if(!this.config.remove_all_contents&&!this.config.remove_element_contents[a])for(y=0;y<e.childNodes.length;y++)o.call(this,e.childNodes[y]);this.current_element.normalize&&this.current_element.normalize(),this.current_element=i}function l(e){var t,i,o,r={attr_whitelist:[],node:e,whitelist:!1};for(t=0;t<this.transformers.length;t++)if(null!==(o=this.transformers[t]({allowed_elements:this.allowed_elements,config:this.config,node:e,node_name:e.nodeName.toLowerCase(),whitelist_nodes:this.whitelist_nodes,dom:this.dom}))){if("object"!=typeof o)throw new Error("transformer output must be an object or null");if(o.whitelist_nodes&&o.whitelist_nodes instanceof Array)for(i=0;i<o.whitelist_nodes.length;i++)-1===n(o.whitelist_nodes[i],this.whitelist_nodes)&&this.whitelist_nodes.push(o.whitelist_nodes[i]);r.whitelist=!!o.whitelist,o.attr_whitelist&&(r.attr_whitelist=s(r.attr_whitelist,o.attr_whitelist)),r.node=o.node?o.node:r.node}return r}this.current_element=i,this.whitelist_nodes=[];for(var c=0;c<e.childNodes.length;c++)o.call(this,e.childNodes[c]);return i.normalize&&i.normalize(),i},e.exports=t},3226(e,t,i){"use strict";var n=i(81515),s=i(49779);e.exports=function(e,t,i){var o=n("Sorry, we seem to be having technical trouble. Please try again later.");throw"function"==typeof i?i(e):s.alert("string"==typeof i?i:o),new Error("require.ensure error: ".concat(t,": ").concat(e))}},3573(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<div data-subview="searchView"></div><div class="messaging-share-post-main"><div class="messaging-share-post-results-wrapper"><div data-subview="errorView"></div><div data-subview="resultsView"></div><div data-subview="favoritesLoaderView"></div></div><div data-subview="loader"></div></div>
1<div data-js-external class="messaging-share-post-external-networks-wrapper"><div data-subview="externalNetworksView"></div></div><div data-js-submission class="messaging-share-post-submission"><div data-subview="messageView"></div></div><div data-js-external-network-subview-wrapper></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},3640(e,t,i){"use strict";var n,s=i(74692),o=i(71742),r=i(66174),a=i(88855),l=o.extend({name:"footer",initialize:function(){this.createFooter()},createFooter:function(){s(".l-footer").length&&(this.footerView=new r({el:".l-footer"})),s(".sidebar_nav").length&&(this.sidebarFooterView=new a({el:".pinned_sidebar_footer"}))}});e.exports=function(){return n||(n=new l),n}},4068(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"message-container conversation-message-post--' +\n__e( postType ) +\n' ' +\n__e( _.isEmpty(thumbnail) ? 'no-thumbnail' : 'has-thumbnail' ) +\n'' +\n__e( isDisabled ? ' is-disabled' : '' ) +\n'\"><div class=\"avatar\"><a href=\"' +\n__e( blogUrl ) +\n'\" target=\"_blank\" data-js-tumblelog-name=\"' +\n__e( name ) +\n'\"><img src=\"' +\n__e( avatarUrl ) +\n'\"></a></div> ';\n if (isDisabled) { ;\n__p += ' <div class=\"message-bubble\" data-js-message-bubble><div class=\"message-bubble-header\">' +\n__e( actionString ) +\n'</div></div> ';\n } else { ;\n__p += ' <div class=\"message-bubble\" data-js-message-bubble> ';\n if (!_.isEmpty(url)) { ;\n__p += ' <a href=\"' +\n__e( url ) +\n'\" data-js-tumblelog-name=\"' +\n__e( postBlogName ) +\n'\" data-js-post-id=\"' +\n__e( postId ) +\n'\"> ';\n } ;\n__p += ' <div class=\"message-bubble-header\" data-js-summary><span class=\"name\">' +\n__e( actionString ) +\n'</span> ';\n if (!_.isEmpty(message)) { ;\n__p += ' <span class=\"text\">' +\n__e( message ) +\n'</span> ';\n } ;\n__p += ' </div> ';\n if (!_.isEmpty(url)) { ;\n__p += ' </a> ';\n } ;\n__p += ' <button class=\"retry-button\" data-js-retry-button>' +\n__e( __('Retry') ) +\n'</button></div> ';\n if (!_.isEmpty(url)) { ;\n__p += ' <a href=\"' +\n__e( url ) +\n'\" data-js-tumblelog-name=\"' +\n__e( postBlogName ) +\n'\" data-js-post-id=\"' +\n__e( postId ) +\n'\" class=\"icon\"></a> ';\n } ;\n__p += ' ';\n } ;\n__p += ' </div> ';\n if (!_.isEmpty(thumbnail)) { ;\n__p += ' <div class=\"thumbnail\"> ';\n if (!_.isEmpty(url)) { ;\n__p += ' <a href=\"' +\n__e( url ) +\n'\" data-js-tumblelog-name=\"' +\n__e( postBlogName ) +\n'\" data-js-post-id=\"' +\n__e( postId ) +\n'\"> ';\n } ;\n__p += ' <img class=\"full-width\" src=\"' +\n__e( _.get(thumbnail, 'url') ) +\n'\" width=\"' +\n__e( _.get(thumbnail, 'width') ) +\n'\" height=\"' +\n__e( _.get(thumbnail, 'height') ) +\n'\"> ';\n if (!_.isEmpty(url)) { ;\n__p += ' </a> ';\n } ;\n__p += ' </div> ';\n } ;\n\n\n}\nreturn __p\n}").apply(void 0,r(s))},4127(e,t,i){"use strict";var n=("https:"===document.location.protocol?"https://":"http://")+"fc.yahoo.com/sdarla/php/client.php?f=1197719150";var s,o=0,r=i(27496),a=function(){clearTimeout(s),s=null,window.DARLA&&!window.DARLA.inProgress()?r.trigger("darla:ready"):++o<5?s=setTimeout(a,1e3):r.trigger("darla:failure")};e.exports=function(){var e=document.createElement("script");e.async=!0;var t=document.getElementsByTagName("script")[0];e.src=n,t.parentNode.insertBefore(e,t),e.onload=a}},4244(e,t,i){"use strict";i.d(t,{A:()=>S});var n=i(28017),s=i.n(n),o=i(74692),r=i.n(o),a=i(27496),l=i.n(a),c=i(80976),u=i(55679),h=i.n(u);function d(e){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},d(e)}function p(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,s,o,r,a=[],l=!0,c=!1;try{if(o=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=o.call(i)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(e){c=!0,s=e}
1finally{try{if(!l&&null!=i.return&&(r=i.return(),Object(r)!==r))return}finally{if(c)throw s}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return g(e,t);var i={}.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?g(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function g(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=Array(t);i<t;i++)n[i]=e[i];return n}function f(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,m(n.key),n)}}function m(e){var t=function(e,t){if("object"!=d(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=d(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==d(t)?t:t+""}var _=function(){return e=function e(t){var i=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},s=arguments.length>2?arguments[2]:void 0,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.element=t,this.manager=s,this.properties=n,this._onServed(),this.visibleTime=null,this.minimumVisibleTime=1e3,this.maximumVisibleTime=1e4,(0,u.isEmpty)(this.properties)||"dashboard_right_rail"!==this.properties.placement_id||l().on("darla:success",function(){var e=p(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],2),t=e[0],n=e[1];"AUTO"===t&&"LREC4"===n[0]&&"LREC"===n[1]&&i._onRotate()}),this._setupWatcher(o)},t=[{key:"_setupWatcher",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;this.watcher=t?c.Ay.createContainer(t).create(this.element):c.Ay.create(this.element),this.watcher.enterViewport(function(){e._onVisible()}),(0,u.isEmpty)(this.properties)||"dashboard_right_rail"!==this.properties.placement_id?this.watcher.exitViewport(function(){e._onInvisible()}):l().on("ads-interaction:sidebar-ad-hidden",this._onInvisible,this)}},{key:"_onServed",value:function(){this._fireEvent("serve")}},{key:"_onVisible",value:function(){this.visibleTime=Date.now()}},{key:"_onInvisible",value:function(){this._setViewDuration(),!(0,u.isEmpty)(this.properties)&&this.properties.view_duration>=this.minimumVisibleTime&&(this._fireEvent("viewable"),this.watcher.destroy(),l().off("ads-interaction:sidebar-ad-hidden"))}},{key:"_setViewDuration",value:function(){this.visibleTime&&(this.properties.view_duration=Date.now()-this.visibleTime,this.properties.view_duration>=this.maximumVisibleTime&&(this.properties.view_duration=this.maximumVisibleTime))}},{key:"_fireEvent",value:function(e){this.properties.event=e,this.manager.supplyLog(this.properties)}},{key:"_onRotate",value:function(){this._setViewDuration(),this._fireEvent("rotate"),this._onVisible(),this.properties.view_duration=0}},{key:"onBeforeUnload",value:function(){this._setViewDuration(),this._fireEvent("unload"),this.watcher.destroy()}}],t&&f(e.prototype,t),i&&f(e,i),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,i}();const v=_;function b(e){return b="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},b(e)}function y(e,t){var i="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!i){if(Array.isArray(e)||(i=function(e,t){if(e){if("string"==typeof e)return w(e,t);var i={}.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?w(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){i&&(e=i);var n=0,s=function(){};return{s,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:s}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,r=!0,a=!1;return{s:function(){i=i.call(e)},n:function(){var e=i.next();return r=e.done,e},e:function(e){a=!0,o=e},f:function(){try{r||null==i.return||i.return()}finally{if(a)throw o}}}}function w(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=Array(t);i<t;i++)n[i]=e[i];return n}function C(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,x(n.key),n)}}function x(e){var t=function(e,t){if("object"!=b(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=b(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==b(t)?t:t+""}var k=function(){return e=function e(t){var i=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e);var n=!1;this.globalProperties={},this.pixels={},h().get(t,"supplyLogging")?(this.data=t.supplyLogging,n=!0):this.data=s().get("Components/SupplyLogging"),this.data&&this._checkForAdblockers().then(this._getGlobalProperties.bind(null,t)).catch(this._getGlobalProperties.bind(null,t)).then(function(e){if(i.globalProperties=e,r()(window).on("beforeunload",i._onBeforeUnload.bind(i)),!n&&h().get(i,"data.dashboard_right_rail")&&(i.pixels.dashboard_right_rail=new v(r()("#sidebar-ad"),h().assign({location_id:"dashboard_right_rail"},i.globalProperties),i)),!n&&h().get(i,"data.dashboard_sponsored_day")){var t=r()(".takeover-container");t.length<1&&(t=r()("#posts li:not(:empty)").not("#new_post_buttons, :not([class])").get(0)),i.pixels.dashboard_sponsored_day=new v(t,h().assign({location_id:"dashboard_sponsored_day"},i.globalProperties),i)}var s=!1,o=!1,a=!1;for(var c in i.data)h().includes(c,"dashboard_instream_")?s=!0:h().includes(c,"peepr_instream_")?o=!0:h().includes(c,"blog_network_instream_")&&(a=!0);!n&&s&&(l().on("dashboard:nextPageLoaded",i._processDashboardInstreamPixels,i),i._processDashboardInstreamPixels()),!n&&o&&(l().on("indashblog:nextPageLoaded",i._processPeeprInstreamPixels,i),l().on("peepr:close",i._unloadPeeprPixels,i)),n&&h().get(i,"data.blog_network_sticky")&&(i.pixels.blog_network_sticky=new v(r()(".sticky-darla-ad"),h().assign({location_id:"blog_network_sticky"},i.globalProperties),i)),n&&h().get(i,"data.blog_network_related_posts")&&(i.pixels.blog_network_related_posts,new v(r()(".related-posts-wrapper .related-posts"),h().assign({location_id:"blog_network_related_posts"},i.globalProperties),i)),n&&h().get(i,"data.blog_network_permalink")&&(i.pixels.blog_network_permalink=new v(r()("body.permalink .post-wrapper"),h().assign({location_id:"blog_network_permalink"},i.globalProperties),i)),n&&a&&(window.Optica.$win.on("next_page_loaded",function(){i._processOpticaInsteamPixels()}),i._processOpticaInsteamPixels())})},t=[{key:"_processOpticaInsteamPixels",value:function(){this._processInstreamPixels("section#posts .container article")}},{key:"_processDashboardInstreamPixels",value:function(){this._processInstreamPixels("[data-supply-logging]")}},{key:"_processPeeprInstreamPixels",value:function(){this._processInstreamPixels("div.indash_blog .posts .post",".peepr-drawer-container .peepr-drawer")}},{key:"_processInstreamPixels",value:function(e){var t=this,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=r()(e),s=null;i&&(s=r()(i)),r()(e+"[data-supply-logging]").each(function(e,i){var o,a=r()(i),l=n.index(a)+1,c=y(a.data("supply-logging"));try{for(c.s();!(o=c.n()).done;){var u=o.value,d=u+"_"+l;t.pixels.hasOwnProperty(d)||(t.pixels[d]=new v(a,h().assign({location_id:u,ad_position:l},t.globalProperties),t,s))}}catch(e){c.e(e)}finally{c.f()}})}},{key:"_getGlobalProperties",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,i=!1;t&&t.err&&"error"===t.err.type&&(i=!0);var n={adblock_enabled:i,client_timestamp:Date.now(),view_duration:0};return h().get(e,"supplyLogging")&&(n.opt_out=!e.adsEnabled,n.nsfw=!!e.isAdult,n.optica_theme=!!e.isOptica),n}},{key:"_checkForAdblockers",value:function(){return new("Promise"in window?Promise:i(12104))(function(e,t){window.Tumblr.ABP&&t({err:{type:"error"}});var i=document.createElement("script");i.async=!0;var n=document.getElementsByTagName("head")[0];i.src="/assets/scripts/tumblr/dashboard/showads.js",n.appendChild(i);var s=function(){i.removeEventListener("load",s),e()};i.addEventListener("load",s),i.addEventListener("error",function(e){t({err:e})})})}},{key:"_unloadPeeprPixels",value:function(){for(var e in this.pixels)if(this.pixels.hasOwnProperty(e)){var t=this.pixels[e];h().startsWith(e,"peepr")&&(t.onBeforeUnload(),delete this.pixels[e])}}},{key:"_onBeforeUnload",value:function(){for(var e in this.pixels)this.pixels.hasOwnProperty(e)&&this.pixels[e].onBeforeUnload()}},{key:"supplyLog",value:function(e){h().has(e,"event")&&l().trigger("Kraken:supply_"+e.event,{loggingData:e})}}],t&&C(e.prototype,t),n&&C(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,n}();const S=k},4284(e,t,i){"use strict";var n=i(55679),s=i(27513),o=i(18024),r=i(24771),a=s.extend({model:o,initialize:function(){this.listenTo(r,"change:type",this.onStateModelChange)},isPushState:function(){return r.get("pushState")},onStateModelChange:function(){this.setActive(r.get("type"))},getActive:function(){return this._activeTab},setActive:function(e){var t=this.get(e);if(t){if(this._activeTab){if(this._activeTab.id===e)return;this._activeTab.set("active",!1)}t.set("active",!0),this._activeTab=t,r.setType(this._activeTab.id)}},getHidden:function(){return n.invoke(this.where({visible:!1}),"toJSON")},hasHidden:function(){return this.where({visible:!1}).length>0}});e.exports=a},4298(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n\n\n    var color = (typeof loader_color !== 'undefined') ? loader_color : '#D9D9D9';\n;\n__p += ' <div class=\"Knight-Rider-loader centered animate\"><div class=\"Knight-Rider-bar\" style=\"background-color:' +\n((__t = ( color )) == null ? '' : __t) +\n'\"></div><div class=\"Knight-Rider-bar\" style=\"background-color:' +\n((__t = ( color )) == null ? '' : __t) +\n'\"></div><div class=\"Knight-Rider-bar\" style=\"background-color:' +\n((__t = ( color )) == null ? '' : __t) +\n'\"></div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},4408(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(48357),r=i(28017),a=i(81515),l=i(21189),
1c=i(71092),u=i(27496),h=i(44890),d=i(77594),p=i(38578),g=i(26124),f=i(52376),m=c.extend({template:f,className:"fast-compose",defaults:{tabIndex:-1,icons:[{name:"text",label:"Text"},{name:"photo",label:"Photo"},{name:"quote",label:"Quote"},{name:"link",label:"Link"},{name:"chat",label:"Chat"},{name:"audio",label:"Audio"},{name:"video",label:"Video"}]},events:{"click .post-tab-switching .tab-post-type":"clickCreate","mouseover .post-tab-switching .tab-post-type":"mouseoverIcon","click .post-tab-switching":"close"},mixins:[p,d],keycommands:{"keydown:c":"nextIcon","keydown:shift+c":"previousIcon","keydown:tab":"nextIcon","keydown:shift+tab":"previousIcon","keydown:right":"nextIcon","keydown:left":"previousIcon","keydown:enter":"enterCreate","keydown:escape":"close"},initialize:function(e){this.loggingData=e?e.loggingData:{},s.forEach(this.get("icons"),function(e){e.label=a(e.label)}),this.$body=n("body"),this.$glass=null,this.$plexiInstance=n('.plexi[data-token="body-plexi"]'),this.resumeKeycommandsOnClose=!0},bindEvents:function(){this.listenTo(u,"DOMEventor:keydown:tab",this.disableKey),this.listenTo(u,"DOMEventor:keydown:shift+tab",this.disableKey),this.listenTo(this,"change:tabIndex",function(e,t){this.$(".selected").removeClass("selected"),this.$('[data-index="'+t+'"]').addClass("selected")})},render:function(){return this.$el.append(this.template(this.toJSON())),this.bindEvents(),this},open:function(){s.defer(s.bind(this.show,this))},show:function(){u.trigger("keycommands:suspend");s.forEach(this.$(".tab-post-type"),function(e,t){var i=n(e),s=i.find(".post-type-icon"),r=i.find(".post-type-name");o.animate(s,{opacity:["1","0"],translateY:["0px","15px"]},{duration:150,delay:50*t}),o.animate(r,{opacity:["1","0"],translateY:["0px","-15px"]},{duration:150,delay:50*t})},this),n(".post-tab-switching").addClass("finish-animating")},enterCreate:function(e){var t=this.$(".selected");if(t.length){var i=t.attr("data-post-type");this.createNew(i),this.close()}},clickCreate:function(e){this.createNew(n(e.currentTarget).data("postType"))},disableKey:function(e){e.preventDefault()},mouseoverIcon:function(e){this.$(".selected").removeClass("selected"),this.set("tabIndex",n(e.currentTarget).data("index"))},nextIcon:function(e){var t=this.get("tabIndex")+1;t>=this.get("icons").length&&(t=0),this.set("tabIndex",t)},previousIcon:function(e){var t=this.get("tabIndex")-1;t<0&&(t=this.get("icons").length-1),this.set("tabIndex",t)},createNew:function(e){this.resumeKeycommandsOnClose=!1,r.has("Components/PostFormBuilder")?u.trigger("postForms:open",{updateURL:!1,postFormType:g.containerType("modal"),postType:e,fastCompose:!0,loggingData:this.loggingData}):u.trigger("fastCompose:create",{type:e,loggingData:this.loggingData})},close:function(){var e=this.$(".tab-post-type"),t=Math.floor(.5*(e.length-1));l.all(s.map(e,function(e,i){var s=n(e),r=50*Math.floor(Math.abs(i-t));return o.animate(s,{opacity:["0","1"],translateY:["-500px","0px"]},{duration:150,delay:r})},this)).then(function(){u.trigger("fastCompose:close:complete")})},teardown:function(){return this.resumeKeycommandsOnClose&&u.trigger("keycommands:resume"),this.remove()}});e.exports=h.bool("is_logged_in")?m:s.noop},4419(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(48357),r=i(71092),a=i(27496),l=i(21987),c=i(75450),u=i(88729),h=i(25046),d=i(63747),p=i(68320),g=i(38904),f=r.extend({survey:g,templates:{surveyStep:c,surveyOptions:u,surveyMessage:h,surveyForm:d},duration:200,events:{"click [data-survey-nav-to]":"surveyLinkHandler","click [data-survey-nav-back]":"surveyBackHandler"},initialize:function(e){e=e||{},this.abuseform=e.abuseform,this.abuseform.on("change:complete",s.bind(this.updateSubmitButton,this)),this.abuseform.on("change:loading",s.bind(this.updateLoadingIndicator,this)),this.history=[],this.$surveyContainer=this.abuseform.$surveyContainer,this.$surveyStep=this.abuseform.$surveyStep},updateSubmitButton:function(){!0===this.abuseform.get("complete")?this.submitButton.removeAttr("disabled"):this.submitButton.attr("disabled","disabled")},updateLoadingIndicator:function(){this.submitButton.toggleClass("loading",this.abuseform.get("loading"))},surveyLinkHandler:function(e){this.history.push(this.abuseform.get("surveyStep"));var t=n(e.currentTarget).data("survey-nav-to");this.displaySurveyStep(t)},surveyBackHandler:function(){var e=this.history.pop();this.displaySurveyStep(e,!0)},displaySurveyStep:function(e,t){var i,r,c=this.survey[e];a.trigger("abuseforms:formview:savestate",this.abuseform.get("surveyStep")),this.abuseform.set("surveyStep",e),a.trigger("Kraken:abuseform:stepviewed",{loggingData:{step:e}}),c.displayBackButton=!!this.history.length,a.trigger("drawerform:errortag:removeall");var u=this.$surveyStep.clone().addClass("dummy-step");"start"===e?(this.flaggingForm=new l({abuseform:this.abuseform}),this.$surveyStep.html(this.flaggingForm.render().$el)):(c.options&&(i=this.templates.surveyOptions(s.extend(c,this.abuseform.templateAttributes))),c.message&&(i=this.templates.surveyMessage(s.extend(c,this.abuseform.templateAttributes))),c.form&&(c.formName=e,i=this.templates.surveyForm(s.extend(c,this.abuseform.templateAttributes)),this.captcha=new p),c.stepContent=i,this.$surveyStep.html(this.templates.surveyStep(s.extend(c,this.abuseform.templateAttributes))),!this.abuseform.get("wasPreviewAutoclosed")&&this.history.length>0&&(a.trigger("abuseform:contentpreview:close"),a.trigger("Kraken:abuseform:contentpreview:close"),this.abuseform.set("wasPreviewAutoclosed",!0))),this.abuseform.navigation.update(c),this.abuseform.dynamicfields.update(),this.abuseform.update_description(c),u.appendTo(this.$surveyContainer),this.abuseform.get("mobileMode")&&u.is(":empty")||(o.animate(u,{translateX:[t?"290px":"-290px","0"],opacity:[0,1]},{duration:this.duration,easing:"easeOut",complete:function(e){n(e).remove()}}),c.options&&((r=this.$surveyStep.find(".option")).css("opacity",0),s.each(r,function(e,i){o.animate(e,{translateX:[0,t?"-70px":"70px"],opacity:[1,0]},{delay:this.duration/4*(i+1),duration:this.duration,easing:"easeOut"})},this)),o.animate(this.$surveyStep,{translateX:["0",t?"-290px":"290px"],op
1acity:[1,0]},{duration:this.duration,easing:"easeOut"})),this.submitButton=this.abuseform.$el.find("[data-survey-submit]"),a.trigger("drawerform:validation:trigger"),c.form&&(a.trigger("abuseforms:formview:restorestate",e),a.trigger("drawer:enableCloseConfirmation"))}});e.exports=f},4432(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<a href=\"' +\n__e( url ) +\n'\" class=\"follow_list_item_blog blog' +\n__e( (!following) ? ' has_follow_button' : '' ) +\n'' +\n__e( (pt ? ' pt' : '') ) +\n'' +\n__e( (wordedFollowButton) ? ' has-worded-follow-button' : '' ) +\n'\" data-pt=\"' +\n__e( pt ) +\n'\" data-log-index=\"' +\n__e( sponsored ? 1 : 0 ) +\n'\" data-peepr=\\'{\"tumblelog\":\"' +\n__e( name ) +\n'\"}\\'><div class=\"hide_overflow ' +\n__e( (!following) ? ' has_follow_button' : '' ) +\n'\"><span class=\"tumblelog_title\"> ' +\n__e( name ) +\n' <span><br><small class=\"tumblelog_name\"> ' +\n__e( (!sponsored ? title : 'Sponsored') ) +\n' </small></span></span></div><div class=\"avatar\" style=\"background-image:url(\\'' +\n__e( avatar_url ) +\n'\\');\"><img src=\"' +\n__e( avatar_url ) +\n'\" class=\"avatar_img\" alt=\"\"></div></a> ';\n if (!following) { ;\n__p += ' ';\n if (wordedFollowButton) { ;\n__p += ' <a class=\"follow-button-right worded-follow-button\" data-follow-button href=\"/follow/' +\n__e( name ) +\n'\" data-tumblelog-name=\"' +\n__e( name ) +\n'\" data-follow-source=\"' +\n__e( followSource ) +\n'\" data-peepr=\\'{\"tumblelog\":\"' +\n__e( name ) +\n'\"}\\'>><div class=\"follow-text\" title=\"' +\n((__t = ( __('Follow') )) == null ? '' : __t) +\n'\">' +\n((__t = ( __('Follow') )) == null ? '' : __t) +\n'</div></a> ';\n } else { ;\n__p += ' <a class=\"follow plus-follow-button\" data-follow-button href=\"/follow/' +\n__e( name ) +\n'\" data-tumblelog-name=\"' +\n__e( name ) +\n'\" data-follow-source=\"' +\n__e( followSource ) +\n'\" title=\"' +\n((__t = ( __('Follow') )) == null ? '' : __t) +\n'\"><span class=\"icon_plus follow_icon\"></span></a> ';\n } ;\n__p += ' ';\n } ;\n__p += ' ';\n if (dismissable) { ;\n__p += ' <div class=\"dismiss\"><i class=\"icon_close\"></i></div> ';\n } ;\n\n\n}\nreturn __p\n}").apply(void 0,r(s))},4734(e,t,i){"use strict";var n=i(27496),s=i(81515),o=i(19698),r=o.extend({getName:function(){return"flag"},getLabel:function(){return s("Report")},getType:function(){return o.TYPE_CALLBACK},onClickHandler:function(e){n.trigger("abuseform:open",{mode:"post",post:this.getPostModel()}),n.trigger("Kraken:abuseform:open",{mode:"post"})}});e.exports=r},4883(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(88174),r=i(81512),a=i(43315),l=i(79990),c=i(19407),u=r.extend({className:"conversation-compose-plugin conversation-compose-plugin--gif-search",template:c,defaults:s.defaults({selectedGif:null,query:"",resultLimit:200,resultImageWidth:250},r.prototype.defaults),events:{click:"_onClick"},initialize:function(e){e=s.extend({},e),s.extend(this,s.pick(e,"collection")),this.popoverOptions={collection:this.collection,query:this.get("query"),resultLimit:this.get("resultLimit"),imageWidth:this.get("resultImageWidth"),loggingContext:this.getName(),loadFullImageBeforeSelect:!1,autoTeardown:!0,teardownOnEscape:!0,pinnedTarget:this.$el,pinnedSide:"top",isFixedPosition:!0}},getName:function(){return"messaging-gif"},onEdit:function(e,t,i){var s,o,r;this.$el.is(":visible")||(r=(o=n(i.currentTarget)).height(),s={pinnedTarget:o,shift:{x:0,y:Math.ceil(-.8*r)}}),this._openGifSearchPopover(e,t,s)},_onClick:function(e){e.preventDefault(),this._openGifSearchPopover(this.get("query")),this.trigger("click",this)},_openGifSearchPopover:function(e,t,i){var n;this.gifSearchPopover&&this._closePopover(),n=s.extend({},this.popoverOptions,i,{query:e,selectedImageUrl:t}),this.gifSearchPopover=new o(n),this.gifSearchPopover.render(),this.toggleActive(!0),this.listenToOnce(this.gifSearchPopover,"close",this._onGifSearchPopoverClose),this.listenToOnce(this.gifSearchPopover,"selectImage",this._onGifSearchPopoverSelectImage),this.listenTo(this.collection,"search",function(e){this.set("query",e)})},_closePopover:function(){this.stopListening(this.gifSearchPopover),this.stopListening(this.collection),this.gifSearchPopover.teardown(),this.toggleActive(!1)},_onGifSearchPopoverSelectImage:function(e){var t,i,n,o,r,c,u,h=s.get(e,"postId"),d=s.get(e,"postBlogUuid"),p=this.get("resultImageWidth"),g=this.getName();s.isEmpty(h)||s.isEmpty(d)||(n=s.get(e,"mediaUrl",""),r=s.get(e,"width"),c=s.get(e,"height"),u=this.get("query"),o=n.replace(/_\d+\./,"_"+p+"."),t=l.createImagePostMessage(h,d,o,r,c,{context:g,loggingData:{query:u}}),i=new a({url:o,width:r,height:c,message:t,context:g,editCallback:s.bind(s.partial(this.onEdit,u,n),this),loggingData:{query:u,postId:h,postBlogUuid:d}}),this.addToImagePreview(i),this._closePopover())},_onGifSearchPopoverClose:function(){this._closePopover()}});e.exports=u},5042(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div class=\"popover_inner\"></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},5143(e,t,i){"use strict";var n=i(74692);var s=function(){var e,t,i={animation:null,transition:null},n=document.createElement("div"),s={animation:"animationend",MozAnimation:"animationend",WebkitAnimation:"webkitAnimationEnd"};for(t in s)if(t in n.style){i.animation=s[t];break}var o={transition:"transitionend",MozTransition:"transitionend",WebkitTransition:"webkitTransitionEnd"};for(e in o)if(e in n.style){i.transition=o[e];break}return i}();e.exports={animation:function(e,t){s.animation?n(e).one(s.animation,function(e){t(e)}):setTimeout(function(e){t(e)},0)},transition:function(e,t){s.transition?n(e).one(s.transition,function(e){t(e)}):setTimeout(function(e){t(e)},0)}}},5217(e,t,i){"use strict";var n=i(55679),s=i(80160),o=i(31384),r=s.extend({defaults:{mediaUrl:"",postUrl:"",rootPostUrl:"",rootPostUrlHash:"",rootBlog:"",rootBlogUrl:"",rootBlogKey:"",postTags:[],popularSearchTag:"",width:0,height:0},initialize:function(e,t){this.attributes={},this.set(n.defaults(o(e||{}),this.defaults))}});e.exports=r},5795(e,t,i){"use strict";var n=i(55679),s=i(50283).extend({className:"conversation-compose-plugins-container",mixins:[],renderWithTemplate:n.noop,defaults:{isDisabled:!1},initialize:function(e){e=n.extend({},e),n.extend(this,n.pick(e,"pluginsArray"))},afterRender:function(){this.listenTo(this,"change:isDisabled",this._onChangeIsDisabled),n.each(this.pluginsArray,n.bind(this._addPluginView,this)),this._onChangeIsDisabled(this,this.get("isDisabled"))},toggleDisabled:function(e){this.set("isDisabled",e)},_addPluginView:function(e){e.render(),this.$el.append(e.el),this.listenTo(e,"preview:add:image",this._onPluginViewPreviewAddImage),this.listenTo(e,"click",this._onPluginViewClick)},_onPluginViewPreviewAddImage:function(e){this.trigger("plugin:preview:add:image",e)},_onPluginViewClick:function(e){this.trigger("plugin:click",e)},_onChangeIsDisabled:function(e,t){n.each(this.pluginsArray,n.bind(function(e){e.toggleDisabled(t)}),this)}});e.exports=s},6453(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(71742),r=i(27496),a=i(33086),l=i(77594),c=i(10394),u=o.extend({name:"HelpForm",mixins:[l],keycommands:{"keydown:shift+h":"open"},initialize:function(){this.drawerManager=a(),this.bindEvents()},bindEvents:function(){this.listenTo(r,"helpform:open",this.open),this.listenTo(r,"helpform:close",this.close),this.listenTo(this.drawerManager,"open:helpform",this.openEventHandler),this.listenTo(this.drawerManager,"open:helpform:terminated",s.partial(this.openEventHandler,{category:"terminated"})),this.listenTo(this.drawerManager,"open:helpform:login",s.partial(this.openEventHandler,{category:"login"}))},close:function(){this.drawerManager.close(),r.trigger("helpform:closed")},openEventHandler:function(e){this.open(e),r.trigger("Kraken:helpform:opened:withButton")},open:function(e){var t=n(document.activeElement).is("input,textarea,div[contenteditable]");this.drawerManager.canOpen()&&!t?this.drawerManager.open(c,e):this.drawerManager.close()}});e.exports=u},6479(e,t,i){"use strict";var n,s=i(61985),o=i(28017),r=i(27496);e.exports=function(){if(null==n){var e=o.get("Context/userinfo");(n=!(!e||!e.name)&&new s(e))&&(n.listenTo(r,"post:like:set",n.incrementLikeCount),n.listenTo(r,"post:unlike:set",n.decrementLikeCount),n.listenTo(r,"tumblelog:follow",n.incrementFollowingCount),n.listenTo(r,"tumblelog:unfollow",n.decrementFollowingCount))}return n}},6554(e,t,i){"use strict";var n=i(55679),s=i(44890),o=i(71742),r=i(27496),a=o.extend({name:"MessagingLogger",defaults:{isDebugEnabled:!1,platform:"web"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults)))},logInboxOpened:function(e){var t={conversationCount:e,status_indicator_enabled:s.bool("status_indicator")};this._logIt("inbox:open",t)},logInboxClosed:function(){this._logIt("inbox:closed")},logConversationOpened:function(e,t){this._logIt("conversation:open",{conversationId:e.get("id"),context:t,status_indicator_enabled:s.bool("status_indicator"),status_indicator:-1!==e.getOtherParticipant().get("seconds_since_last_activity")?"greendot":"none"})},logConversationClosed:function(e,t){this._logIt("conversation:closed",{conversationId:e.get("id"),context:t})},logConversationDeleted:function(e){this._logIt("conversation:deleted",{conversationId:e.get("id")})},logConversationStarted:function(e,t){this._logIt("conversation:started",{context:t})},logMessageSent:function(e,t){!n.isEmpty(t)&&t.isNew()&&this.logConversationStarted(t),this._logIt("message:sent",this._getMessageLoggingData(e,t))},logMessageFailed:function(e,t){this._logIt("message:failure",this._getMessageLoggingData(e,t))},logFollow:function(e){this._logIt("conversation:follow",{blogName:e})},logBlock:function(e){this._logIt("block",{blockingBlog:e.currentTumblelog,blockedBlog:e.blockedTumblelog})},logNotification:function(e){this._logIt("notification:display",{conversationId:e})},logNotificationPermissionGranted:function(){this._logIt("notification:permission:granted")},logNotificationPermissionDenied:function(){this._logIt("notification:permission:denied")},logConversationWindowsLoaded:function(e,t){this._logIt("conversation:windows:loaded",{numOpen:e.length,numMinimized:t.length})},logConversationMinimized:function(e){this._logIt("conversation:minimized",{conversationId:e.get("id")})},logConversationUnminimized:function(e){this._logIt("conversation:unminimized",{conversationId:e.get("id")})},logConversationSpamIntent:function(e){this._logIt("conversation:spam:intent",{conversationId:e.get("id")})},logConversationSpamSuccess:function(e){this._logIt("conversation:spam:success",{conversationId:e.get("id")})},logConversationSpamFail:function(e){this._logIt("conversation:spam:fail",{conversationId:e.get("id")})},logImagePreviewAdd:function(e,t){this._logImagePreviewAction("add",e,t)},logImagePreviewDismiss:function(e,t){this._logImagePreviewAction("dismiss",e,t)},logImagePreviewEdit:function(e,t){this._logImagePreviewAction("edit",e,t)}
1,logComposePluginClick:function(e,t){var i,s=t.getName();n.isEmpty(s)||(i=s+":intent",this._logIt(i,{conversationId:e.get("id")}))},logPeeprOpen:function(e,t,i,o,r){var a={url:e,blogName:t,status_indicator_enabled:s.bool("status_indicator"),status_indicator:r?"greendot":"none"};n.isEmpty(i)||n.extend(a,{postId:i}),n.isEmpty(o)||n.extend(a,{searchTagTerm:o}),this._logIt("peepr:open",a),this._logIt("Kraken:peepr:open",a)},logMessagingPermalinkOpen:function(e){var t={blogName:e};this._logIt("conversation-permalink:open",t)},logInboxEmptyNewMessageClick:function(e,t){var i={blogName:e},n=t?"new:inbox:empty:new-message:button:click":"old:inbox:empty:new-message:button:click";this._logIt(n,i)},logEmptySuggestionClick:function(e,t,i,n){var s={sendingBlog:e,receivingBlog:t,context:i},o=n?"new:inbox:empty:suggestion":"old:inbox:empty:suggestion";this._logIt(o,s)},_logImagePreviewAction:function(e,t,i){var s,o,r,a=i.get("context");n.isEmpty(a)||(s=i.get("loggingData"),o=a+":"+e,r=n.extend({},s,{conversationId:t.get("id")}),this._logIt(o,r))},_getMessageLoggingData:function(e,t){var i,s,o,r,a,l,c,u,h;return n.isEmpty(e)?null:(i=(l=e.isPost())?0:(e.getMessage()||"").length,s=e.get("type"),o=e.get("context"),a=e.get("loggingData"),h=e.get("creationUserAction"),r=n.extend({},a,{conversationId:t?t.get("id"):null,messageLength:i,messageType:s}),n.isEmpty(h)||n.extend(r,{creationUserAction:h}),l&&(c=e.get("post").toJSON(),u=n.get(c,"blog.uuid")||n.get(c,"blog"),n.extend(r,{postBlogUuid:u,postId:n.get(c,"id")})),n.isEmpty(o)||n.extend(r,{context:o}),r)},_logIt:function(e,t){t=t||{},n.extend(t,{platform:this.get("platform")}),r.trigger("Kraken:Messaging:"+e,{loggingData:t})}});e.exports=a},7052(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div class=\"conversation-preview-image-container\" data-js-image-container><a href=\"#\" class=\"conversation-preview-remove\" data-js-preview-remove>' +\n__e( __('Remove') ) +\n'</a></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},7229(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<h1 class=\"form-heading\"> ';\n if (title) { ;\n__p += ' ' +\n((__t = ( __(title) )) == null ? '' : __t) +\n' ';\n } else { ;\n__p += ' ' +\n__e( __('Report this') ) +\n' ';\n } ;\n__p += ' </h1><div class=\"form-description\"> ';\n if (description instanceof Array) { ;\n__p += ' ';\n _.each(description, function(line) { ;\n__p += ' ';\n if (line.link) { ;\n__p += ' <p class=\"description-multiline\">' +\n((__t = ( __(line.text, '<a target=\"_blank\" href=\"'+ line.link +'\">', '</a>') )) == null ? '' : __t) +\n'</p> ';\n } else { ;\n__p += ' <p class=\"description-multiline\">' +\n((__t = ( __(line.text) )) == null ? '' : __t) +\n'</p> ';\n } ;\n__p += ' ';\n }); ;\n__p += ' ';\n } else if (description) { ;\n__p += ' ' +\n((__t = ( __(description) )) == null ? '' : __t) +\n' ';\n } else { ;\n__p += ' ' +\n((__t = ( __('Seeing something that violates our %1$sUser Guidelines%2$s? Help us keep Tumblr safe by making a report to our team of trained experts. %3$sLearn more%4$s about our moderation process and what you can do to help.', '<a href=\"https://www.tumblr.com/policy/user-guidelines\" target=\"_blank\">', '</a>', '<a href=\"https://help.tumblr.com/hc/articles/360011799473-Content-moderation-on-Tumblr\" target=\"_blank\">', '</a>') )) == null ? '' : __t) +\n' ';\n } ;\n__p += ' </div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},7256(e,t,i){var n=i(55679),s=i(80965),o=i(27839),r=o.getRealNow,a=s.get("tmgioct");function l(e){return n.isString(e)?e:JSON.stringify(e)}e.exports=function(e,t,i){this.name=t,this.log_key=n.result(e,"log_key"),this.data=i||null;var s=r(),c=n.result(e,"generate_relative_id"),u=n.result(e,"env"),h=e.uuid,d={category:this.log_key},p=new Array(8);p[0]=l(s),p[1]=l(a),p[2]=l(h),p[3]=l(c),p[4]=l(o.getElapsed(s)),p[5
1]=l(t),p[6]=l(i),p[7]=l(u),d.fields=p,this.json=d}},7410(e,t,i){"use strict";var n=i(55679),s=i(27496),o=i(71092),r=i(91398),a=o.extend({tagName:"a",className:"sidebar_link explore_link avatar_align",template:r,defaults:{exploreLinkHref:"/explore",exploreLinkLabel:"Explore all of Tumblr"},events:{click:"onClick"},initialize:function(e){this.options=n.defaults(e,this.defaults),this.$el.attr({href:this.options.exploreLinkHref})},render:function(){return this.$el.html(this.template(this.options)),this},onClick:function(){s.trigger("explore-links:click",{loggingData:{source:"recommended-blogs-unit"}})}});e.exports=a},7419(e,t,i){"use strict";var n=i(55679),s=i(17145),o={requestFullscreen:["requestFullScreen"]},r=s.extend({vendors:["moz","webkit","ms","o","khtml"],cssPrefixes:["-moz-","-webkit-","-ms-","-o-","",""],el:document.body||document.documentElement,get:n.memoize(function(e){var t=this._getProp(e);return!t&&o[e]&&n.each(o[e],function(e){var i=this._getProp(e);i&&(t=i)},this),t}),prop:function(e){return!!this.get(e)},cssFilters:n.memoize(function(){var e=document.createElement("div");return e.style.cssText=this.cssPrefixes.join("filter:blur(5px); "),!!e.style.length}),positionSticky:n.memoize(function(){var e=document.createElement("div");return e.style.cssText=this.cssPrefixes.join("position: sticky; "),!!e.style.length}),_getProp:function(e){var t=!1;return"string"==typeof this.el[e]||"string"==typeof this._styles()[e]?e:(e=e.charAt(0).toUpperCase()+e.substr(1),n.forEac
1h(this.vendors,function(i){var n=i+e;n in this.el&&(t=n),n in this._styles()&&(t=n)},this),t)},_styles:n.memoize(function(){return this.el.style})});e.exports=new r},7521(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(38578),r=i(53346),a=s.extend({template:r,mixins:[o],className:"primary-nav",initialize:function(e){e=n.extend({},e),n.extend(this.attributes,e)},render:function(){return this.$el.html(this.template(this.toJSON())),this}});e.exports=a},7695(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(71092),r=i(80965),a=i(74692),l=i(64491),c=i(38578),u=i(78355),h=i(56292),d=i(51904),p=i(19223),g=o.extend({className:"mobile-app-banner",mixins:[l,c],events:{"click .open.mobile-banner-button":"__clickOpen","click .mobile-banner-close":"__clickClose"},template:u,__clickOpen:function(e){var t=this;this.isIos()&&setTimeout(function(){document.webkitHidden||document.hidden||confirm(s("Open in the app store?"))&&(document.location.href=t.get("install_url_open_failed"))},200)},__clickClose:function(e){e.preventDefault(),this.closeBanner(),this.setCookie(),this.hideBanner()},closeBanner:function(){this.$el.remove()},setCookie:function(){var e=new Date;e.setDate(e.getDate()+3),r.set("hide_download_app_prompt","1",e)},showBanner:function(){a(document.documentElement).addClass("mobile-app-banner-visible")},hideBanner:function(){a(document.documentElement).removeClass("mobile-app-banner-visible")},isIos:function(){var e=this.attributes.handset;return"iphone"===e||"ipad"===e},initialize:function(e){n.extend(this.attributes,e),this.$el.addClass(this.get("type")),"app-gate"===this.get("type")?this.get("has_app")?this.subViews.bannerInternals=new d(e):this.subViews.bannerInternals=new p(e):this.subViews.bannerInternals=new h(e)},render:function(){return!r.get("hide_download_app_prompt")&&(this.showBanner(),this.$el.html(this.template(this.toJSON())),this.attachSubViews(),this)}});e.exports=g},7784(e,t,i){"use strict";e.exports=i(2896)},7864(e,t,i){"use strict";var n=i(80160).extend({defaults:{participant:null}});e.exports=n},7888(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p +=\n((__t = ( _subview('drawer-content') )) == null ? '' : __t);\n\n}\nreturn __p\n}").apply(void 0,r(s))},8012(e){"use strict";var t=[].slice,i=[].push;function n(){this.length=0}n.prototype={slice:t,indexOf:Array.prototype.indexOf},n.prototype.push=function(){if(this.triggered_with)for(var e=1<=arguments.length?t.call(arguments,0):[],n=0;n<e.length;n+=1)e[n].apply(null,this.triggered_with);return i.apply(this,arguments)},n.prototype.trigger=function(){var e=1<=arguments.length?t.call(arguments,0):[],i=this.length;this.triggered_with=e;for(var n=0;n<i;n+=1)this[n].apply(null,this.triggered_with);return this},e.exports=n},8038(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(87931),r=i(84088),a=i(12720),l=i(7410),c=s.extend({defaults:{header:!0,tumblelogs:[],dismissable:!0,refresh:!0,numShow:4,primaTumblelogPopover:!1,exploreLink:!1},initialize:function(e){this.options=n.defaults(e,this.defaults),this.pageUrl=this.getPageUrl(),this.options.header&&(this.headerView=new r({$el:this.$(".section_header"),headline:this.options.headline})),this.options.exploreLink&&(this.exploreLinkView=new l({exploreLinkLabel:this.options.exploreLinkLabel})),this.collection=new o(this.options.tumblelogs),this.listView=new a({el:this.el,collection:this.collection,dismissable:this.options.dismissable,refresh:this.options.refresh,numShow:this.options.numShow,primaTumblelogPopover:this.options.primaTumblelogPopover,pageUrl:this.getPageUrl(),wordedFollowButton:this.options.wordedFollowButton})},getPageUrl:function(){return window.location.pathname.split("/")[1]},render:function(){return this.headerView&&this.$el.append(this.headerView.render().el),this.$el.append(this.listView.render().el),this.exploreLinkView&&this.$el.after(this.exploreLinkView.render().el),this},updateTumblelogs:function(e){this.collection.reset(e)}});e.exports=c},8133(e,t,i){"use strict";var n=i(97583).extend({logKey:"dashboard_sharing",events:{"dashboard-share:*":"handleEvent"},logEnv:{location:document.location.pathname},handleEvent:function(e,t){t=t||{},this.log(e,t)}});e.exports=n},8155(e,t,i){"use strict";var n=i(81515),s=i(71092),o=i(7229),r=s.extend({className:"form-header",initialize:function(e){return e=e||{},this.templateAttributes={__:n,title:void 0!==e.title?e.title:"",description:void 0!==e.description?e.description:"",inNativeApp:e.inNativeApp},this},render:function(){return this.$el.html(o(this.templateAttributes)),this}});e.exports=r},8210(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(27496),r=i(38578),a=i(27975),l=i(96152),c=s.extend({template:a,className:"search-field",mixins:[r],events:{"submit form":"__submitForm"},__submitForm:function(){this.toggleLoader(!0)},__handleSearchClick:function(){var e=this.$searchInput.val();this.$el.hasClass("search-term-exists")?e===this.get("search_term")?this.setFocus():this.$submitForm.trigger("submit"):!e&&this.$mobileLogoWrapper.hasClass("show-search-field")?this.hideSearchField():e&&this.$mobileLogoWrapper.hasClass("show-search-field")?this.$submitForm.trigger("submit"):this.showSearchField()},__handleNsfwFilterClick:function(e){this.$searchNsfwFilterInput.val(e),this.$submitForm.prop("action","/search/"+this.get("search_term")),this.$searchInput.prop("name",""),this.$submitForm.trigger("submit")},__handleFilterChange:function(e){var t="top";"CREATED_DESC"===e.get("sort")&&(t="recent");var i=e.get("post_type").toLowerCase();this.$searchFilterSortInput.val(t),this.$searchFilterPostTypeInput.val(i),this.$searchNsfwFilterInput.val(e.get("filter_nsfw")),this.$submitForm.prop("action","/search/"+this.get("search_term")),this.$searchInput.prop("name",""),this.$submitForm.trigger("submit")},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,e),this.listenTo(o,"mobileHeader:search:click",this.__handleSearchClick),this.listenTo(o,"mobileHeader:nsfw:update",this.__handleNsfwFilterClick),this.listenTo(o,"mobileHeader:filter:update",this.__handleFilterChange),this.listenTo(o,"drawer:open",this.hideSearchField)},render:function(){return this.get("search_term")&&this.$el.addClass("search-term-exists"),this.$el.html(this.template(this.toJSON())),this.$searchInput=this.$(".search-input"),this.$searchNsfwFilterInput=this.$(".search-nsfw-filter-input"),this.$searchFilterSortInput=this.$(".filter-sort-input"),this.$searchFilterPostTypeInput=this.$(".filter-post-type-input"),this.$submitForm=this.$("form"),this.$mobileLogoWrapper=this.$el.parent(),this},toggleLoader:function(e){e?this.loader?this.loader.set("loading",!0):this.loader=new l({$container:this.$el,type:"bar",classModifiers:"top",loading:!0}):this.loader.set("loading",!1)},showSearchField:function(){this.$mobileLogoWrapper.addClass("show-search-field"),n.delay(n.bind(this.setFocus,this),250)},hideSearchField:function(){this.$searchInput.blur(),this.$mobileLogoWrapper.removeClass("show-search-field")},setFocus:function(){var e=2*this.$searchInput.val().length;this.$searchInput.focus(),this.$searchInput.get(0).setSelectionRange(e,e)}});e.exports=c},8414(e,t,i){"use strict";var n=i(55068);e.exports=function(e){return new n(e)}},8468(e,t,i){"use strict";var n=i(55679),s=i(81299),o=i(12118),r=s.extend({name:"html",formatters:{link:o},escape:function(e){return n.escape(e)},applyFormatting:function(e,t){var i=n.bind(this.escape,this),s=n.bind(this.getFormatter,this),o={};
1n.forEach(t,function(e){var t=s(e.type);if(t){var i=e.position,r=e.attributes,a=i[0],l=i[1];n.isEmpty(o[a])&&(o[a]=[]),n.isEmpty(o[l])&&(o[l]=[]),o[a].push(n.bind(t.open,this,r)),o[l].unshift(n.bind(t.close,this,r))}},this);var r,a,l=n.sortBy(n.keys(o),function(e){return n.parseInt(e)}),c="",u=0;return n.forEach(l,function(t){r=o[t],a=e.substr(u,t-u),c+=i(a),n.forEach(r,function(e){c+=e()}),u=t},this),a=e.substr(u),c+=i(a)}});e.exports=r},8579(e,t,i){var n=i(55679),s=i(27839).getRealNow;e.exports=function(e,t,i){this.name=t,this.log_key=n.result(e,"log_key"),this.data=i||{};var o=s(),r={pt:this.data.pt,event_data:{timestamp:o,eventString:this.data.eventName||t}};this.data.video_details&&(r.event_data.data=this.data.video_details),this.data.extraData&&(r.event_data.data=r.event_data.data||{},n.extend(r.event_data.data,this.data.extraData)),this.json=r}},8689(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(44384),r=i(59492),a=o.extend({events:{click:"openSharePopover"},openSharePopover:function(e){var t=n(e.currentTarget);return new r({postId:t.attr("data-post-id"),blogUuid:t.attr("data-tumblelog-uuid"),favoritesNames:s.compact([t.attr("data-tumblelog-name"),t.attr("data-parent-tumblelog-name")]),externalNetworksData:this.model.get("share_popover_data"),pinnedTarget:t}).render()}});e.exports=a},8901(e,t,i){"use strict";var n=i(3226);e.exports=function(e){i.e(169).then(function(t){try{e(i(19821))}catch(e){n(e,"post-activity")}}.bind(null,i)).catch(i.oe)}},8925(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(5143).transition,r=i(53010),a=i(64491),l=i(59952),c=i(77594),u=i(79350),h=s.extend({className:"popover--blog-search",mixins:[a,l,c],template:u,keycommands:{"keydown:down":"targetNextLi","keydown:tab":"targetNextLi","keydown:up":"targetPrevLi","keydown:shift+tab":"targetPrevLi","keyup:enter":"selectLi"},defaults:{keycommands:!1,keyboardFocusClass:"keyboard_focus"},initialize:function(e){this.options=n.defaults(e,this.defaults),this.Subview?(this.subview=new this.Subview(e),this.bindEvents()):this.remove()},render:function(){return this.$el.html(this.template()),this.$(".popover_inner").append(this.subview.render().$el),this.$main=this.$el.find(".popover"),n.delay(n.bind(function(){this.$main.addClass("popover--active"),this.bindClickOutside()},this),1),this},bindEvents:function(){this.listenTo(this.subview,"remove",this.hide),this.options.keycommands||this.disableKeys()},bindClickOutside:function(){this._popoverBase.autoTeardown&&(this.clickOutside=new r(this.el),this.clickOutside.on("click:outside",this.hide,this))},unbindClickOutside:function(){this.clickOutside&&(this.clickOutside.remove(),this.clickOutside=null)},targetNextLi:function(e){e.preventDefault(),this.$active?(this.$active.removeClass(this.options.keyboardFocusClass),this.$active=this.$active.next().length?this.$active.next():this.$(".popover_menu_item").first()):this.$active=this.$(".popover_menu_item").first(),this.$active.addClass(this.options.keyboardFocusClass),this.scrollToActive()},targetPrevLi:function(e){e.preventDefault(),this.$active?(this.$active.removeClass(this.options.keyboardFocusClass),this.$active=this.$active.prev().length?this.$active.prev():this.$(".popover_menu_item").last()):this.$active=this.$(".popover_menu_item").last(),this.$active.addClass(this.options.keyboardFocusClass),this.scrollToActive()},selectLi:function(){this.$active&&this.trigger("itemSelected",this.$active)},scrollToActive:function(){this.$scrollable=this.$scrollable||this.$(".popover_inner"),this.$scrollable.scrollTop(this.$scrollable.scrollTop()+this.$active.position().top-this.$scrollable.height()+this.$active.outerHeight())},hide:function(){this.$main.removeClass("popover--active"),this.unbindClickOutside(),o(this.$el,n.bind(function(){this.subview.remove(),this.remove(),this.teardown()},this))}});e.exports=h},9045(e,t,i){"use strict";var n=i(55679),s=i(2616);e.exports=function(e,t){e=n.map(e,function(e){return n.bind(e,this)},t||this);var i=Array.prototype.slice.call(arguments,1);return i[0]=e,s.apply(null,i)}},9367(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div data-subview=\"resultView[]\"></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},9380(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(81515),r=i(27513),a=i(93049),l=i(68311),c=r.extend({url:"/svc/conversations/participant_suggestions",model:a,resultCache:{},fetchFlags:["empty","post"],initialize:function(){return this.getNoResultsFoundMessage=l([o("That isn't anyone."),o("Uh, who?"),o("Huh what?"),o("Never heard of 'em."),o("???"),o("Eh?"),o("Whaaa?")]),r.prototype.initialize.apply(this,arguments)},parse:function(e,t){return s.get(e,"response.blogs")||e},fetchByQuery:function(e,t,i){return i=i||{},s.extend(i,{reset:!0,data:{q:e,participant:t}}),this.fetch(i)},fetchFavorites:function(e,t,i,n,o,r){return e=e||8,r=r||{},s.extend(r,{reset:!0,data:{limit:e,participant:t,include_recent:i,exclude_active:n},flag:o}),this.fetch(r)},fetch:function(e){var t=JSON.stringify(s.get(e,"data")),i=s.get(e,"flag",""),o=new n.Deferred,a=s.get(this.resultCache,t);return this.cancelFetch(),a&&-1!==this.fetchFlags.indexOf(i)?(this.reset(a),this.trigger("sync",this),o.resolve(),o):(this._request=r.prototype.fetch.apply(this,arguments),this._request.then(s.bind(function(e){-1!==this.fetchFlags.indexOf(i)&&s.set(this.resultCache,t,this.parse(e))},this)).always(s.bind(function(){this._request=null},this)),this._request)},cancelFetch:function(){this._request&&(this._request.abort(),this._request=null)}});e.exports=c},9428(e,t,i){"use strict";var n=i(81515),s=i(19698).extend({getName:function(){return"reddit"},getLabel:function(){return n("Reddit")},getPopupOptions:function(){return"scrollbars=1,width=860,height=600"},getPopupUrl:function(){return""+encodeURIComponent(this.getPostUrl())}});e.exports=s},9553(e){"use strict";var t={isUrl:function(e){var t="%[0-9a-fA-F]{2}",i="(25[0-5]|2[0-4][0-9]|[0-1][0-9][0-9]|[1-9][0-9]|[0-9])",n="a-zA-Z0-9\\-\\_\\~",s="\\u00C0-\\u9FFF",o=n+s+".:\\[\\]@!$&'()*+,;=",r="(["+o+"]|"+t+")*";return!0===new RegExp("^(http|https):\\/\\/("+('([a-zA-Z0-9$\\-_.+!*"(),;:&=]|'+t+")+@")+")?"+("("+("("+i+"(\\."+i+"){3})")+"|localhost|"+("(["+n+s+"]+\\.)+([a-zA-Z]{2,})")+")(:[0-9]+)?")+"(\\/?("+(r+"(\\/"+r+")*")+")?("+("\\?(["+o+"/?]|"+t+")*")+")?("+("\\#(["+o+"/?]|"+t+")*")+")?)?$").test(e)},isImageUrl:function(e){var i=t.isUrl(e),n=!0===/.+[.](jpg|jpeg|png|gif)([?]|$)/.test(e);return i&&n}};e.exports=t},10074(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(50283),r=i(98237),a=i(57505),l=i(7052),c=i(48357),u=i(84970),h=o.extend({className:"conversation-preview",template:l,mixins:[r],events:{"click [data-js-image-container]":"_onImageContainerClick","click [data-js-preview-remove]":"_onClickPreviewRemove"},defaults:{isVisible:!1,isEditable:!1,maxHeight:150,maxWidth:210,animateInDurationMs:300,animateOutDurationMs:200,animateInEasing:[.22,.685,.03,.895],animateOutEasing:[.895,.03,.685,.22]},afterRender:function(){this.listenTo(this,"change:isVisible",this._onChangeIsVisible),this.listenTo(this,"change:isEditable",this._onChangeIsEditable),this._onChangeIsVisible(this,this.get("isVisible")),this._onChangeIsEditable(this,this.get("isEditable"))},hasImage:function(){return!s.isEmpty(this.previewImageModel)},addImage:function(e){var t=e.get("height"),i=e.get("width"),n=this.get("maxHeight"),o=this.get("maxWidth"),r=a.maxSize(i,t,o,n),l=this.js$("image-container");return this.previewImageView&&this.previewImageView.remove(),this.previewImageView=new u({src:e.get("url"),width:s.get(r,"width"),height:s.get(r,"height")}),l.append(this.previewImageView.render().$el),this.set("isVisible",!0),this.set("isEditable",s.isFunction(e.get("editCallback"))),this.previewImageModel=e,this._slideElement(l)},_slideElement:function(e,t){var i=new n.Deferred,o=e.height()+(e.offset().top-this.$el.offset().top);return c.animate(e,{translateY:t?[o,0]:[0,o]},{duration:t?this.get("animateOutDurationMs"):this.get("animateInDurationMs"),easing:t?this.get("animateOutEasing"):this.get("animateInEasing"),complete:s.bind(function(){i.resolve(),e.css("transform","")},this)}),i},getMessage:function(){return s.isEmpty(this.previewImageModel)?null:this.previewImageModel.get("message")},close:function(){return this.trigger("closing",this.previewImageModel),this._slideElement(this.js$("image-container"),!0).then(s.bind(this._onAfterCloseAnimation,this))},_onAfterCloseAnimation:function(){var e=this.previewImageModel;this.previewImageView.remove(),delete this.previewImageModel,delete this.previewImageView,this.set("isVisible",!1),this.trigger("close",e)},_onImageContainerClick:function(e){var t,i=this.previewImageModel;this.get("isEditable")&&!s.isEmpty(i)&&(t=i.get("editCallback"),s.isFunction(t)&&(e.preventDefault(),t(e),this.trigger("edit",i)))},_onClickPreviewRemove:function(e){e.preventDefault(),e.stopPropagation(),this.trigger("dismiss",this.previewImageModel),this.close()},_onChangeIsVisible:function(e,t){this.$el.toggle(t)},_onChangeIsEditable:function(e,t){this.$el.toggleClass("editable",t)}});e.exports=h},10394(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(28017),r=i(27496),a=i(38578),l=i(41872),c=i(73953),u=i(81245),h=i(68722),d=i(99243),p=i(55379),g=i(83195),f=i(68320);i(38136);var m=g.extend({mixins:[a,l],templates:{helpForm:c,suggestions:u,suggestionItem:p,ticketCreated:h,errorMessage:d},events:{"click .help-form-next":"onFormNextClick","click .help-form-submit":"onFormSubmitClick","click .help-form-dismiss":"dismissForm","click .suggestion.with-link":"onSuggestionClick","change [data-validate-input]":"onFieldInputChange","change .category":"onCategoryChange","change .account-help-type":"onAccountHelpTypeChange"},className:"help-form",initialize:function(e){try{g.prototype.initialize.call(this,e),this.set("suggestionsShown",!1),this.on("change:complete",this.updateSubmitButton),this.set("captchaSuccess",!1),this.set("wasFormTouched",!1),this.set("wasFaqLoaded",!1),this.set("mobileMode",e.mobileMode||!1),r.on("drawer:close",s.bind(this.teardown,this));var t=o.get("Components/HelpForm");this.templateAttributes.email=t.email,this.templateAttributes.tumblelogs=t.tumblelogs,this.templateAttributes.suspendedTumblelogs=t.suspended_tumblelogs,this.templateAttributes.languageNotice=t.language_notice,this.templateAttributes.categories=t.category_opt;var i=this.getCategoryFromHash();this.templateAttributes.preSelectedCategory=e&&e.category?e.category:i,this.templateAttributes.categoryAllowsFiles="terminated"!==this.templateAttributes.preSelectedCategory,this.templateAttributes.supportsFileChooser=this.supportsFileChooser(),this.templateAttributes.recaptcha=t.recaptcha,this.captcha=new f({callback:this.onCaptchaSuccess.bind(this),expiredCallback:this.onCaptchaExpire.bind(this)}),this.lang=t.lang,this.setUpResponseHandler(),n(".contact_button_static").remove(),n(".static_help_form").remove()}catch(e){this.onCatchFallBack(e)}},onCaptchaSuccess:function(){this.set("captchaSuccess",!0),this.updateSubmitButton()},onCaptchaExpire:function(){this.set("captchaSuccess",!1),this.updateSubmitButton()},onCatchFallBack:function(e){window.location&&(this.get("mobileMode")&&"/help"!==window.location.pathname?s.defer(function(){n(".help-form").remove()}):"/support"!==window.location.pathname?window.location="/support":s.defer(function(){r.trigger("helpform:close"),r.trigger("Kraken:helpform:close")}))},dismissForm:function(){this.logEvent("foundItClicked"),this.get("mobileMode")?void 0!==window.history&&window.history.length>2?window.history.go(-1):window.location="/dashboard":(r.trigger("helpform:close"),r.trigger("Kraken:helpform:close"))},setUpResponseHandler:function(){window.help_modal={},window.help_modal.evaluate_response=s.bind(function(e){e.meta&&201===e.meta.status?this.onRequestSuccess():this.onRequestFail(e)},this)},getFaqs:function(){n.ajax({url:"/svc/faqs/"+this.lang}).then(s.bind(this.onFaqRequestSuccess,this),s.bind(this.onFaqRequestFail,this))},onFaqRequestSuccess:function(e){void 0!==e.response.faqs?this.prepareFaqIndex(e.response.faqs):this.prepareFaqIndex([])},onFaqRequestFail:function(){this.prepareFaqIndex([])},prepareFaqIndex:function(e){var t;this.keywordIndex={},this.faqList={},void 0!==e&&e.length>0&&s.each(e,function(e){s.each(e.keywords.split(","),function(i){this.faqList[e.id]={},this.faqList[e.id].question=e.question,this.faqList[e.id].answer=e.answer,t=e.question.match('(https?://[^"]+)'),this.faqList[e.id].faqLink=null!==t&&t[0],void 0===this.keywordIndex[i]&&(this.keywordIndex[i]=[]),this.keywordIndex[i].push(e.id)},this)},this),this.set("wasFaqLoaded",!0)},updateSubmitButton:function(){!0===this.get("complete")&&!0===this.get("captchaSuccess")?this.nextFormButton.removeAttr("disabled"):this.nextFormButton.attr("disabled","disabled")},onCategoryChange:function(){this.updateReleventBlogRequired(),this.updateTerminationForm(),this.updateAppealsLink(),this.updateAccountAccessFields(),this.fieldValidation.validateAllFields()},updateReleventBlogRequired:function(){"explicit"===this.categoryField.val()||"appeal"===this.categoryField.val()||"terminated"===this.categoryField.val()||"accountmanagement"===this.categoryField.val()?(this.tumblelogField.attr("required","required"),this.blogOptionalIndicator.addClass("not-shown"),this.get("mobileMode")&&this.blogOptionalIndicator.addClass("hidden")):(this.tumblelogField.removeClass("error"),r.trigger("drawerform:errortag:remove",{field:this.tumblelogField}),this.tumblelogField.removeAttr("required"),this.blogOptionalIndicator.removeClass("not-shown"),this.get("mobileMode")&&this.blogOptionalIndicator.removeClass("hidden"))},updateTerminationForm:function(){var e="terminated"===this.categoryField.val();this.filePicker.toggleClass("hidden",e),this.tumblelogField.find("option.notsuspended").attr("disabled",e?"disabled":null),this.tumblelogField.find("option.suspended").attr("disabled",e?null:"disabled")},updateAppealsLink:function(){"appeal"===this.categoryField.val()?(this.appealsLink.removeClass("not-shown"),this.get("mobileMode")&&this.appealsLink.removeClass("hidden")):(this.appealsLink.addClass("not-shown"),this.get("mobileMode")&&this.appealsLink.addClass("hidden"))},updateAccountAccessFields:function(){"accountmanagement"===this.categoryField.val()?(this.accountAccessHelpType.removeClass("hidden"),this.accountAccessAction.removeClass("hidden"),this.accountHelpTypeField.attr("required","required"),this.accountAccessActionField.attr("required","required")):(this.accountAccessHelpType.addClass("hidden"),this.accountAccessAction.addClass("hidden"),this.accountHelpTypeField.removeClass("error").removeAttr("required"),this.accountAccessActionField.removeClass("error").removeAttr("required"),r.trigger("drawerform:errortag:remove",{field:this.accountHelpTypeField}),r.trigger("drawerform:errortag:remove",{field:this.accountAccessActionField})),this.updateAccountEmailConfirmedVisibility()},updateAccountEmailConfirmedVisibility:function(){var e="accountmanagement"===this.categoryField.val(),t=this.accountHelpTypeField.val();e&&!("account_reason_email_forgot"===t||"account_reason_email_no_access"===t)?(this.accountAccessEmailConfirmed.removeClass("hidden"),this.accountEmailConfirmedCheckbox.attr("required","required")):(this.accountAccessEmailConfirmed.addClass("hidden"),this.accountEmailConfirmedCheckbox.prop("checked",!1).removeClass("error").removeAttr("required"),r.trigger("drawerform:errortag:remove",{field:this.accountEmailConfirmedCheckbox}))},onAccountHelpTypeChange:function(){this.updateAccountEmailConfirmedVisibility(),this.fieldValidation.validateAllFields()},getCategoryFromHash:function(){if(window.location&&window.location.hash){return{appeal:"appeal"}[window.location.hash.substring(1)]||""}return""},onRequestSuccess:function(){this.$el.html(this.templates.ticketCreated(this.templateAttributes)),this.resetScroll(),this.logEvent("submit:success"),r.trigger("drawer:disableCloseConfirmation"),setTimeout(function(){r.trigger("helpform:close"),r.trigger("Kraken:helpform:close")},5e3)},onRequestFail:function(e){var t=this.get("suggestionsShown")?n(".help-form-submit"):n(".help-form-next"),i=s.clone(this.templateAttributes),o=n(".error-message");o&&o.remove(),e.response&&e.response.errors&
1&s.extend(i,e.response),n(this.templates.errorMessage(i)).insertBefore(t.closest(".form-group")),t.removeClass("loading"),this.logEvent("submit:error",{error:e})},onFormNextClick:function(e){if(e.target&&e.preventDefault(),r.trigger("drawerform:errortag:removeall"),!this.get("wasFaqLoaded"))return this.nextFormButton.addClass("loading"),void this.once("change:wasFaqLoaded",this.onFormNextClick,this);var t=this.getSuggestions();t.length>0?(this.set("suggestionsShown",!0),this.form.addClass("not-shown"),this.get("mobileMode")&&this.form.addClass("hidden"),this.$el.prepend(this.templates.suggestions(s.extend(this.templateAttributes))),this.fillInSuggestions(t),this.resetScroll(),this.logEvent("suggestions:found",{suggestions:t})):(this.form.find("form").submit(),this.nextFormButton.addClass("loading"),this.logEvent("suggestions:notfound")),this.sendLogQuery()},onSuggestionClick:function(e){var t=n(e.target);this.logEvent("suggestions:clicked",{faqLink:t.attr("href")})},onFieldInputChange:function(e){this.get("wasFormTouched")||(this.set("wasFormTouched",!0),r.trigger("drawer:enableCloseConfirmation"),this.getFaqs())},resetScroll:function(){var e;this.get("mobileMode")?e=n("body"):(void 0===this.drawer&&(this.drawer=this.$el.closest(".drawer")),e=this.drawer),s.defer(function(){e.scrollTop(0)})},logEvent:function(e,t){if(e&&e.length){var i={category:this.categoryField.val()||"",query:this.bodyField.val()||""};s.extend(i,t),r.trigger("Kraken:helpform:"+e,{loggingData:i})}},fillInSuggestions:function(e){var t=n(".suggestions-list");s.each(e,function(e){e.faqLink?n("<a></a>").attr({href:e.faqLink,target:"_blank",class:"suggestion with-link"}).html(this.templates.suggestionItem(e)).appendTo(t):n("<div></div>").attr({class:"suggestion"}).html(this.templates.suggestionItem(e)).appendTo(t)},this)},onFormSubmitClick:function(){this.form.find("form").submit(),this.$el.find(".help-form-submit").addClass("loading")},sendLogQuery:function(){n.ajax({url:"/help/query",type:"POST",data:{query:this.bodyField.val(),matched:this.get("suggestionsShown")?1:0}})},getSuggestions:function(){var e=this.bodyField.val().trim().toLowerCase(),t={},i=[];return s.each(this.keywordIndex,function(i,n){(0===e.indexOf(n)||e.indexOf(" "+n)>0)&&s.each(i,function(e,i){void 0===t[e]&&(t[e]=0),t[e]+=i<10?.05*(10-i):0},this)},this),t=s.chain(t).map(function(e,t){return{name:t,score:e}}).sortBy(function(e){return e.score}).reverse().filter(function(e,t){return t<5}).value(),s.each(t,function(e){i.push(this.faqList[e.name])},this),i},render:function(){return this.$el.html(this.templates.helpForm(this.templateAttributes)),this.form=this.$el.find(".form-container.form"),this.bodyField=this.$el.find(".body"),this.categoryField=this.$el.find(".category"),this.nextFormButton=this.$el.find(".help-form-next"),this.tumblelogField=this.$el.find(".tumblelog"),this.blogOptionalIndicator=this.$el.find("#blog_optional_indicator"),this.filePicker=this.$el.find("#support-form-filepicker"),this.appealsLink=this.$el.find("#appeals-link"),this.accountAccessEmailConfirmed=this.$el.find("#account-access-email-confirmed"),this.accountAccessHelpType=this.$el.find("#account-access-help-type"),this.accountAccessAction=this.$el.find("#account-access-action"),this.accountEmailConfirmedCheckbox=this.$el.find(".account-email-confirmed-checkbox"),this.accountHelpTypeField=this.$el.find(".account-help-type"),this.accountAccessActionField=this.$el.find(".account-access-action"),this.setUpSelector(this.$el.find(".category")),this.setUpSelector(this.$el.find(".tumblelog")),this.setUpSelector(this.$el.find(".account-help-type")),this.setUpSelector(this.$el.find(".account-access-action")),this.updateTerminationForm(),this.updateAppealsLink(),this.updateAccountAccessFields(),this},teardown:function(){window.location&&"/support"===window.location.pathname&&(r.trigger("helpform:navigateBackToHelp"),r.trigger("Kraken:helpform:navigateBackToHelp"))}});e.exports=m},10587(e,t,i){"use strict";var n=i(44384).extend({});e.exports=n},10631(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape;\nwith (obj) {\n__p +=\n__e( __(\'Add Photo\')) +\n\' <input type="file" class="input-file-picker" data-js-file-picker name="messaging-photo" accept="image/*" tabindex="-1">\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},10708(e,t,i){var n=i(55679),s=i(27839),o=s.getRealNow,r=s.realStartedAt;e.exports=function(e,t,i){this.name=t,this.log_key=n.result(e,"log_key"),this.data=i||null;var s=o(),a=n.result(e,"generate_relative_id"),l=n.result(e,"env"),c=e.uuid,u={};u.log_key=this.log_key,u.uuid=c,u.event=this.name,u.ts=s,!1!==a&&void 0!==a&&(u.rid=a),u.elapsed=u.ts-r,u.data=this.data,u.env=l,this.json=u}},10737(e,t,i){"use strict";var n=i(93664);e.exports=n},10768(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(80160),r=i(27496),a=i(80867),l=i(49779),c=i(93405),u=i(81515),h=i(6479),d=o.extend({defaults:{},endpoints:{like:"/svc/like",unlike:"/svc/unlike",reblog:"/fast_reblog",reply:"/svc/reply",publish:"/publish",queue:"/publish",destroy:"/svc/post/delete",promote:"/svc/promote",unpromote:"/svc/unpromote",answer:"/answer",deny:"/deny_submission",approve:"/approve_submission",remove_source:"remove_app_attribution",subscription:"/svc/blog/:tumblelog/posts/:post_id/sub
1scription"},initialize:function(e){this._createPostTumblelogModel("tumblelog",this.get("tumblelog-data")),this._createPostTumblelogModel("parentTumblelog",this.get("tumblelog-parent-data")),this._createPostTumblelogModel("rootTumblelog",this.get("tumblelog-root-data")),this.listenTo(this,"like:success",this.logClientLike)},logClientLike:function(){r.trigger("ads:client_like",{loggingData:{userAction:"client_like",postData:this.attributes}})},_createPostTumblelogModel:function(e,t){e=e||"tumblelog";var i=!1;(t=t||!1)&&t.name&&(i=new a(n(t).omit(n.isUndefined).omit(n.isNull).value())),this[e]=i},_setTumblelog:function(){this.tumblelog=new a(n({name:this.get("tumblelog"),ignoring:!1,sponsor:this.get("sponsored"),following:this.get("following"),mention_key:this.get("tumblelog_mention_key")}).omit(n.isUndefined).omit(n.isNull).value())},_setReblogTumblelog:function(){var e=this.get("reblog_source");e&&e.name&&(this.reblogTumblelog=new a(n({name:e.name,ignoring:!1,following:e.following}).omit(n.isUndefined).omit(n.isNull).value()))},getRootTumblelogUuid:function(){return this.get("tumblelog-root-data")?this.get("tumblelog-root-data").uuid:this.get("tumblelog-data")?this.get("tumblelog-data").uuid:this.get("reblogged_root_uuid")||this.get("tumblelog_uuid")},_xhrRequest:function(e,t,i){var o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"POST";i.init&&i.init();var r=s.ajax({data:t,type:o,url:e,withFormKey:!0});return r.done(n.bind(function(e){i[200]&&i[200].call(this,e)},this)),r.fail(n.bind(function(e){i[e.status]&&i[e.status].call(this,e.status)},this)),r.always(n.bind(function(){i.always&&i.always()},this)),r},_xhrSuccess:function(e){this.trigger(e+":success")},_xhrFailure:function(e){l.alert(u("Sorry, we seem to be having technical trouble.  Please try again later.")),this.trigger(e+":failure")},_xhrForbidden:function(e){this.trigger(e+":forbidden")},_setCarouselIndex:function(e){return this.get("is_carousel")?n.extend(e,{offset:this.get("carousel_index")}):e},save:function(e,t,i,s){if(i||(i={}),this.endpoints[e]){var o={200:n.bind(this._xhrSuccess,this,e),401:n.bind(this._xhrFailure,this,e),404:n.bind(this._xhrFailure,this,e),403:n.bind(this._xhrForbidden,this,e),500:n.bind(this._xhrFailure,this,e)},r=this.endpoints[e];return r.indexOf(":")>-1&&(r=this.replaceEndPointVariables(r)),this._xhrRequest(r,t,n.defaults(i,o),s)}throw new Error("Missing endpoint url for "+e)},replaceEndPointVariables:function(e){return e.replace(":tumblelog",this.get("tumblelog")).replace(":post_id",this.get("id"))},like:function(e){if(!1===this.get("liked")){this.set("liked",!0);var t=this.likePayload(e,this.getLikeSource("like"));this.save("like",{data:t})}this.trigger("like:set",this),r.trigger("post:like:set",this.get("id"),this,e)},unlike:function(){if(!0===this.get("liked")){this.set("liked",!1);var e=this.likePayload("mouse",this.getLikeSource("unlike"));this.save("unlike",{data:e})}this.trigger("unlike:set",this),r.trigger("post:unlike:set",this.get("id"))},toggleLike:function(){this.get("liked")?this.unlike():this.like()},getLikeSource:function(e){var t="LIKE_";switch(e=e||"like"){case"unlike":t="UNLIKE_";break;case"reply":t="REPLY_";break;case"ignore":t="IGNORE_"}var i=location.pathname;return i.match(/^\/dashboard\/iframe/)?t+"SOURCE_IFRAME":i.match(/^\/dashboard/)?t+"SOURCE_DASHBOARD":i.match(/^\/tagged/)?t+"SOURCE_TAG_PAGE":i.match(/^\/likes/)?t+"SOURCE_LIKES_PAGE":i.match(/^\/inbox/)?t+"SOURCE_INBOX":i.match(/^\/search/)?t+"SOURCE_SEARCH_RESULTS_PAGE":i.match(/^\/explore/)?t+"SOURCE_DISCOVER":i.match(/^\/tv/)?t+"SOURCE_TV":i.match(/^\/indash_blog\/peepr/)?t+this.getPeeprSource():t+"SOURCE_UNKNOWN"},getPeeprSource:function(){if(window.parent&&window.parent.location&&window.parent.location.pathname.match(/search/))return"SOURCE_SEARCH_PEEPR";return"SOURCE_PEEPR"},getEmbedCode:function(e,t){var i={embed_key:this.get("embed_key"),embed_did:this.get("embed_did"),post_id:this.get("id"),post_url:this.get("post_url")};return e&&(i.language=e),t&&(i.width=t),new c(i).getCode()},likePayload:function(e,t){e=e||"mouse",t=t||"LIKE_SOURCE_UNKNOWN";var i={id:this.get("id"),root_id:this.get("root_id"),key:this.get("reblog_key"),placement_id:this.get("placement_id")||!1,is_recommended:this.get("is_recommended")||"",pt:this.get("pt"),tumblelog_name:this.get("tumblelog-name"),method:e,source:t};return this._setCarouselIndex(i)},reblog:function(e){e=n.extend({},e,{reblogId:this.get("id"),reblogKey:this.get("reblog_key"),reblogBlogName:this.get("reblog_name"),pt:this.get("pt")}),r.trigger("postForms:reblog",e)},fastReblog:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:h().attributes.fastqueue_web_lab;this.trigger("fastreblog:success",e),r.trigger("post:fastreblog:set",{model:this});
1var t={reblog_key:this.get("reblog_key"),reblog_post_id:this.get("id"),queue:e,pt:this.get("pt"),tumblelog:this.get("tumblelog")};t=this._setCarouselIndex(t);var i={200:n.bind(function(t){this.set("reblogged",!0),this.trigger("fastreblog:ajax:success",t.response);var i={model:this.clone(),toastOptions:{type:e?"queue":"selfReblog",avatar:t.response.post_tumblelog.avatar,fromTumblelogName:t.response.post_tumblelog.name_or_id}};r.trigger("post:fastReblog:showtoast",i)},this)};this.save("reblog",t,i)},reply:function(e){var t=this,i={reply_text:e,post_id:this.get("id"),tumblelog:this.get("tumblelog"),tumblelog_key:this.get("tumblelog-key")||this.get("tumblelog_key"),source:this.getLikeSource("reply")},n={200:function(){t.trigger("replied"),t._setSubscriptionStatus(!0)}};return this.save("reply",{data:i},n)},destroy:function(e){var t={post_id:this.get("id"),channel_id:this.get("tumblelog")};this.save("destroy",t,e)},publish:function(){this.save("publish",{id:this.get("id")}).fail(n.bind(function(e){this.trigger("publish:failure",s.parseJSON(e.responseText))},this))},promote:function(e){var t={tag:e,post_id:this.get("id"),reblog_key:this.get("reblog_key"),tumblelog_name:this.get("tumblelog")};return this.save("promote",t)},unpromote:function(e){var t={tag_id:e,post_id:this.get("id"),reblog_key:this.get("reblog_key"),tumblelog_name:this.get("tumblelog")};return this.save("unpromote",t)},queue:function(){var e={id:this.get("id"),queue:"queue"};this.save("queue",e)},removeSource:function(){var e={post_id:this.get("id"),tumblelog_id:this.get("tumblelog")};return this.save("remove_source",e)},approve:function(e){var t={id:this.get("id"),queue:e};return this.save("approve",t)},deny:function(){return this.save("deny",{pid:this.get("id")})},answer:function(e){var t={post_id:this.get("id"),tumblelog:this.get("tumblelog"),key:this.get("tumblelog-key"),answer_text:e};return this.save("answer",t)},embedFocus:function(){this.trigger("embed:focus",this)},updateReblogControl:function(e){this.trigger("reblog:success",e)},dismiss:function(){this.trigger("dismiss",this)},_setSubscriptionStatus:function(e){"boolean"!=typeof e&&(e=!this.get("isSubscribed")),this.set("isSubscribed",e)},_toggleSubscription:function(e){var t=this,i=this.get("isSubscribed")?"DELETE":"POST";return this.save("subscription",{},{200:function(){t._setSubscriptionStatus(!t.get("isSubscribed"))}},i)}});e.exports=d},10860(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"carousel-arrow carousel-arrow-left\"></div><div class=\"carousel-arrow carousel-arrow-right\"></div><div class=\"carousel-button-container\"> ';\n for (i = 0; i < photoCount; i++) { ;\n__p += ' <span class=\"carousel-button' +\n__e( i === 0 ? ' current' : '' ) +\n'\" data-carousel-button-index=\"' +\n__e( i ) +\n'\">&#x25cf;</span> ';\n } ;\n__p += ' </div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},11092(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(71092),r=i(27496),a=i(81515),l=i(5143),c=o.extend({el:".ui_dialog",translations:{},defaultTemplates:{dialog:i(30764),content:i(48391),button:i(12484)},events:{"click .ui_button":"buttonClick"},defaultDialog:{text:"",type:"default",has_form:"auto",visible_glass:!0,confirm_by_enter:!0,close_by_space:!0,key_tab:!0,key_close:!0,scroll_lock:!1,keycommand_maintain:!1,animate:!0,animate_in:{dialog_el:".ui_dialog",dialog_class:"fade-in-up"},on_close:function(){},on_open:function(){}},initialize:function(e){this.options=s.extend(this.defaults,this.options),this.templates=this.defaultTemplates,this.is_visible=!1,this.dialogQueueOrder=[],this.dialogQueue={},this.queueCounter=0,this.currentDialog=!1,this.currentDialogId=0,this.uid=0,this.$body=n("body"),this._initClickLock(),this._setupKeys(),r&&!t.Dialog&&(this.listenTo(r,"dialog:dialog",this.dialog),this.listenTo(r,"dialog:confirm",this.confirm),this.listenTo(r,"dialog:confirm:promise",this.confirmPromise),this.listenTo(r,"dialog:alert",this.alert),this.listenTo(r,"dialog:close",this.close))},dialog:function(e){return!!s.isObject(e)&&this._dialog(e)}
1,confirm:function(e,t,i,n,o){s.isString(e)&&(e={text:e});var r={callback_ok:t,callback_cancel:i,text_ok:n,text_cancel:o},l={text:(e=s.extend(this.defaultDialog,r,e)).text,customClass:e.customClass||null,type:"confirm",visible_glass:!0,keycommand_maintain:e.keycommand_maintain||!1,templates:e.templates||null,escape_button:0,animate_in:{dialog_el:e.animate_in.dialog_el||".ui_dialog",dialog_class:e.animate_in.dialog_class||"fade-in-up"},buttons:{0:{text:e.text_cancel||a("Cancel"),close:!0,callback:s.isFunction(e.callback_cancel)?e.callback_cancel:function(){}},1:{text:e.text_ok||a("OK"),selected:!0,btn_class:"blue",close:!0,callback:s.isFunction(e.callback_ok)?e.callback_ok:function(){}}}};return this._dialog(l)},confirmPromise:function(e,t){this.confirm(t,e.resolve,e.reject)},alert:function(e,t,i){s.isString(e)&&(e={text:e});var n={callback_ok:t,text_ok:i},o={text:(e=s.extend({},n,e)).text,customClass:e.customClass||null,type:"alert",visible_glass:!0,keycommand_maintain:e.keycommand_maintain||!1,templates:e.templates||null,escape_button:0,buttons:{0:{text:e.text_ok||a("OK"),selected:!0,btn_class:"blue",close:!0,callback:s.isFunction(e.callback_ok)?e.callback_ok:function(){}}}};return this._dialog(o)},getDialogEl:function(){return this.el},buttonClick:function(e){var t=n(e.currentTarget),i=t.data("btn-id");if(s.isUndefined(this.currentDialog.buttons[i])||t.hasClass("disabled"))return!1;var o=this.currentDialog.buttons[i],r=null;s.isFunction(o.callback)&&(r=o.callback(this)),!1!==r&&(!s.isUndefined(o.close)&&o.close||s.isUndefined(o.close))&&this.close()},isActive:function(e){return!1!==this.currentDialog&&this.currentDialog.uid===e},close:function(e){if(!1===this.currentDialog)return!1;if(s.isUndefined(e)&&(e=!1),!1!==e&&this.currentDialog.uid!==e)return!1;if(l.transition(this.$dialog_lock,s.bind(function(){this.$dialog_lock.hide(),n(".ui_dialog_pos").remove()},this)),l.animation(this.$dialog_el,s.bind(function(){n(".ui_dialog_pos").remove()},this)),this.$dialog_lock.removeClass("opaque"),this.$dialog_el.addClass("fade-out-down"),this.is_visible=!1,this.currentDialog.keycommand_maintain||r.trigger("keycommands:resume"),s.isFunction(this.currentDialog.on_close)&&this.currentDialog.on_close(),r.trigger("dialog:closed"),this.currentDialog=!1,n("html").removeClass("dialog_lock"),this.dialogQueueOrder.length>0){var t=this.dialogQueueOrder.shift(),i=this.dialogQueue[t];delete this.dialogQueue[t],this._dialog(i)}},_tab:function(e){var t=this.$el.find(".buttons .tab_frame"),i=t.filter(".focus"),n=t.index(i),s=!1;s=n+1<t.length?n+1:0,i.removeClass("focus init_focus");var o=t.eq(s);o.length>0&&(o.addClass("focus"),o.find("button").focus())},_formIsTabToButton:function(e,t){var i=this.$el.find(":focus");if(0===i.length)return!0;var n=this.$el.find(".buttons .tab_frame"),s=this.$el.find(":input:visible"),o=s.index(i);if(t&&o===s.length-1)return this.$el.find(":input:visible:first").focus(),e.preventDefault(),n.removeClass("focus init_focus"),!1;if(o>=0){var r=this.$el.find(":input:visible:eq("+(o+1)+")");if(r.length>0&&r.hasClass("ui_button"))return!0}return n.removeClass("focus init_focus"),!1},_select:function(e){var t=this.$el.find(".buttons .tab_frame.focus");1===t.length&&t.find(".ui_button").click()},_formIsFocusOnButton:function(e){var t=this.$el.find(":focus");return 0!==t.length&&t.hasClass("ui_button")},_escape:function(e){if(!s.isUndefined(this.currentDialog.escape_button)){var t=this.$el.find(".btn_"+this.currentDialog.escape_button);t.length&&t.click()}},_dialog:function(e){if(s.isUndefined(e.uid)&&(e.uid=this._getUid()),!1!==this.currentDialog)return this.dialogQueueOrder.push(this.queueCounter),this.dialogQueue[this.queueCounter]=e,this.queueCounter++,e.uid;s.defaults(e,this.defaultDialog);var t=this._buildButtons(e.buttons);s.extend(e,{buttons_html:t});var i=this.templates;s.isObject(e.templates)&&(i=s.extend({},this.templates,e.templates));var o=s.isString(i.dialog)?s.template(i.dialog):i.dialog,a=s.isString(i.content)?s.template(i.content):i.content;e.content_html=a(e);var l=o(e);this.$dialog_lock.show(),s.isUndefined(e.visible_glass)?this.$dialog_lock.removeClass("opaque"):e.visible_glass&&s.defer(s.bind(function(){this.$dialog_lock.addClass("opaque")},this)),!s.isUndefined(e.scroll_lock)&&e.scroll_lock&&n("html").addClass("dialog_lock"),this.currentDialogId=e.uid,this.currentDialog=e;var c=n('<div id="dialog_'+this.currentDialogId+'" class="ui_dialog_pos">'+l+"</div>");return s.isString(e.customClass)&&c.addClass(e.customClass),c.appendTo(this.$body),this.setElement(c),this.is_visible=!0,this.$dialog_el=this.$el.find(e.animate_in.dialog_el),e.animate&&s.isObject(e.animate_in)&&this.$dialog_el.length&&this.$dialog_el.addClass(e.animate_in.dialog_class),this._focus(),this.currentDialog.keycommand_maintain||r.trigger("keycommands:suspend"),s.isUndefined(e.has_form)&&(e.has_form="auto"),"auto"===e.has_form&&(e.has_form=this.$el.find("form, input").length>0),s.isFunction(e.on_open)&&e.on_open(),this.el=this.$el[0],this.delegateEvents(),r.trigger("dialog:opened"),e.uid},_button:function(e,t,i,n){var o=(s.isString(this.templates.button)?s.template(this.templates.button):this.templates.button)({btn_class:t,text:e,btn_id:s.isUndefined(i)?"":i});return o='<div class="tab_frame">'+o+"</div>"},_focus:function(){if(!this.currentDialog)return!1;for(var e in this.currentDialog.buttons){var t=this.currentDialog.buttons[e];if(!s.isUndefined(t.selected)&&t.selected){var i=this.$el.find(".btn_"+e);i.length>0&&i.parent().addClass("focus init_focus")}}},_setupKeys:function(){n(document).on("keydown",s.bind(function(e){var t=e.ctrlKey||e.shiftKey||e.metaKey;if(this.is_visible&&!t){var i=e.keyCode||e.which;if(9===i&&this.currentDialog.key_tab){if(this.currentDialog.has_form&&!this._formIsTabToButton(e,!0))return;e.preventDefault(),this._tab(e)}if(13===i&&this.currentDialog.confirm_by_enter||32===i&&this.currentDialog.close_by_space){if(this.currentDialog.has_form&&32===i&&!this._formIsFocusOnButton(e))return;e.preventDefault(),this._select(e)}27===i&&this.currentDialog.key_close&&(e.preventDefault(),this._escape(e))}},this))},_buildButtons:function(e){if(!s.isObject(e))return"";var t=0;for(var i in e)e.hasOwnProperty(i)&&t++;for(var n="",o=0;o<t;o++)if(!s.isUndefined(e[o])){var r=s.isUndefined(e[o].text)?"":e[o].text,a=s.isUndefined(e[o].btn_class)?"":e[o].btn_class,l=!s.isUndefined(e[o].selected)&&e[o].selected;n+=this._button(r,a,o,l)}return n},_initClickLock:function(){var e=this.$dialog_lock=n("<div>",{class:"ui_dialog_lock",css:{display:"none"}});
1n(document).ready(function(){e.prependTo("body")})},_getUid:function(){return this.uid++},__:function(e){return a(e)}});e.exports=new c},11229(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<a data-start-conversation href=\"/conversation/new/' +\n__e( name ) +\n'\" class=\"inbox-row\"> ';\n if (blogIsAdult && isSafeModeEnabled && !isUser) { ;\n__p += ' <canvas class=\"avatar post-activity-avatar-image post_sub_avatar_image pixelated-avatar needs-drawing hide\" data-image-url=\"' +\n__e( avatarUrl ) +\n'\" width=\"36\" height=\"36\" alt=\"' +\n__e( name ) +\n'\"></canvas> ';\n } else { ;\n__p += ' <img class=\"avatar\" src=\"' +\n__e( avatarUrl ) +\n'\"> ';\n } ;\n__p += ' <div class=\"info-container\"> ';\n if (isNewEmptyInboxEnabled) { ;\n__p += ' <h3>' +\n__e( name ) +\n'</h3><h4 class=\"tags\" data-js-tags-string>' +\n__e( tagsString ) +\n'</h4><h4 class=\"send-link\">' +\n__e( __('Send a message') ) +\n'</h4> ';\n } else { ;\n__p += ' <h3>' +\n__e( name ) +\n'</h3><h4>' +\n__e( title ) +\n'</h4> ';\n } ;\n__p += ' </div></a>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},11459(e,t,i){"use strict";var n=i(97583).extend({logKey:"user_tag_filtering",logOptions:{init_event:!1},events:{"userTagFiltering:*":"handleEvent"},logEnv:{location:document.location.pathname},handleEvent:function(e,t){this.log(e,t)}});e.exports=n},12097(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(60475),r=s.extend({tagName:"ul",template:o,events:{"click [data-js-ask]":"_onClickAsk","click [data-js-message]":"_onClickMessage"},getTemplateData:function(){return{hasMessaging:!0===this.model.get("can_receive_messages"),hasAsks:!0===this.model.get("asks"),hasSubmissions:!0===this.model.get("submissions"),url:this.model.get("url")}},_onClickMessage:function(e){e.preventDefault(),this.trigger("messagingSelected"),this.trigger("popoverClose")},_onClickAsk:function(e){e.preventDefault(),this.trigger("askSelected"),n.delay(n.bind(function(){this.trigger("popoverClose")},this),1)}});e.exports=r},12104(e,t,i){e.exports=function e(t,i,n){function s(r,a){if(!i[r]){if(!t[r]){var l="function"==typeof _dereq_&&_dereq_;if(!a&&l)return l(r,!0);if(o)return o(r,!0);var c=new Error("Cannot find module '"+r+"'");throw c.code="MODULE_NOT_FOUND",c}var u=i[r]={exports:{}};t[r][0].call(u.exports,function(e){var i=t[r][1][e];return s(i||e)},u,u.exports,e,t,i,n)}return i[r].exports}for(var o="function"==typeof _dereq_&&_dereq_,r=0;r<n.length;r++)s(n[r]);return s}({1:[function(e,t,i){"use strict";t.exports=function(e){var t=e._SomePromiseArray;function i(e){var i=new t(e),n=i.promise();return i.setHowMany(1),i.setUnwrap(),i.init(),n}e.any=function(e){return i(e)},e.prototype.any=function(){return i(this)}}},{}],2:[function(e,t,i){"use strict";var n;try{throw new Error}catch(e){n=e}var s=e("./schedule"),o=e("./queue");function r(){this._customScheduler=!1,this._isTickUsed=!1,this._lateQueue=new o(16),this._normalQueue=new o(16),this._haveDrainedQueues=!1;var e=this;this.drainQueues=function(){e._drainQueues()},this._schedule=s}function a(e,t,i){this._lateQueue.push(e,t,i),this._queueTick()}function l(e,t,i){this._normalQueue.push(e,t,i),this._queueTick()}function c(e){this._normalQueue._pushOne(e),this._queueTick()}function u(e){for(;e.length()>0;)h(e)}function h(e){var t=e.shift();if("function"!=typeof t)t._settlePromises();else{var i=e.shift(),n=e.shift();t.call(i,n)}}r.prototype.setScheduler=function(e){var t=this._schedule;return this._schedule=e,this._customScheduler=!0,t},r.prototype.hasCustomScheduler=function(){return this._customScheduler},r.prototype.haveItemsQueued=function(){return this._isTickUsed||this._haveDrainedQueues},r.prototype.fatalError=function(e,t){t?(process.stderr.write("Fatal "+(e instanceof Error?e.stack:e)+"\n"),process.exit(2)):this.throwLater(e)},r.prototype.throwLater=function(e,t){if(1===arguments.length&&(t=e,e=function(){throw t}),"undefined"!=typeof setTimeout)setTimeout(function(){e(t)},0);else try{this._schedule(function(){e(t)})}catch(e){throw new Error("No async scheduler available\n\n    See http://goo.gl/MqrFmX\n")}},r.prototype.invokeLater=a,r.prototype.invoke=l,r.prototype.settlePromises=c,r.prototype._drainQueues=function(){u(this._normalQueue),this._reset(),this._haveDrainedQueues=!0,u(this._lateQueue)},r.prototype._queueTick=function(){this._isTickUsed||(this._isTickUsed=!0,this._schedule(this.drainQueues))},r.prototype._reset=function(){this._isTickUsed=!1}
1,t.exports=r,t.exports.firstLineError=n},{"./queue":26,"./schedule":29}],3:[function(e,t,i){"use strict";t.exports=function(e,t,i,n){var s=!1,o=function(e,t){this._reject(t)},r=function(e,t){t.promiseRejectionQueued=!0,t.bindingPromise._then(o,o,null,this,e)},a=function(e,t){50397184&this._bitField||this._resolveCallback(t.target)},l=function(e,t){t.promiseRejectionQueued||this._reject(e)};e.prototype.bind=function(o){s||(s=!0,e.prototype._propagateFrom=n.propagateFromFunction(),e.prototype._boundValue=n.boundValueFunction());var c=i(o),u=new e(t);u._propagateFrom(this,1);var h=this._target();if(u._setBoundTo(c),c instanceof e){var d={promiseRejectionQueued:!1,promise:u,target:h,bindingPromise:c};h._then(t,r,void 0,u,d),c._then(a,l,void 0,u,d),u._setOnCancel(c)}else u._resolveCallback(h);return u},e.prototype._setBoundTo=function(e){void 0!==e?(this._bitField=2097152|this._bitField,this._boundTo=e):this._bitField=-2097153&this._bitField},e.prototype._isBound=function(){return!(2097152&~this._bitField)},e.bind=function(t,i){return e.resolve(i).bind(t)}}},{}],4:[function(e,t,i){"use strict";var n;function s(){try{Promise===o&&(Promise=n)}catch(e){}return o}"undefined"!=typeof Promise&&(n=Promise);var o=e("./promise")();o.noConflict=s,t.exports=o},{"./promise":22}],5:[function(e,t,i){"use strict";var n=Object.create;if(n){var s=n(null),o=n(null);s[" size"]=o[" size"]=0}t.exports=function(t){var i,n=e("./util"),s=n.canEvaluate;function o(e,i){var s;if(null!=e&&(s=e[i]),"function"!=typeof s){var o="Object "+n.classString(e)+" has no method '"+n.toString(i)+"'";throw new t.TypeError(o)}return s}function r(e){return o(e,this.pop()).apply(e,this)}function a(e){return e[this]}function l(e){var t=+this;return t<0&&(t=Math.max(0,t+e.length)),e[t]}n.isIdentifier,t.prototype.call=function(e){var t=[].slice.call(arguments,1);return t.push(e),this._then(r,void 0,void 0,t,void 0)},t.prototype.get=function(e){var t;if("number"==typeof e)t=l;else if(s){var n=i(e);t=null!==n?n:a}else t=a;return this._then(t,void 0,void 0,e,void 0)}}},{"./util":36}],6:[function(e,t,i){"use strict";t.exports=function(t,i,n,s){var o=e("./util"),r=o.tryCatch,a=o.errorObj,l=t._async;t.prototype.break=t.prototype.cancel=function(){if(!s.cancellation())return this._warn("cancellation is disabled");for(var e=this,t=e;e._isCancellable();){if(!e._cancelBy(t)){t._isFollowing()?t._followee().cancel():t._cancelBranched();break}var i=e._cancellationParent;if(null==i||!i._isCancellable()){e._isFollowing()?e._followee().cancel():e._cancelBranched();break}e._isFollowing()&&e._followee().cancel(),e._setWillBeCancelled(),t=e,e=i}},t.prototype._branchHasCancelled=function(){this._branchesRemainingToCancel--},t.prototype._enoughBranchesHaveCancelled=function(){return void 0===this._branchesRemainingToCancel||this._branchesRemainingToCancel<=0},t.prototype._cancelBy=function(e){return e===this?(this._branchesRemainingToCancel=0,this._invokeOnCancel(),!0):(this._branchHasCancelled(),!!this._enoughBranchesHaveCancelled()&&(this._invokeOnCancel(),!0))},t.prototype._cancelBranched=function(){this._enoughBranchesHaveCancelled()&&this._cancel()},t.prototype._cancel=function(){this._isCancellable()&&(this._setCancelled(),l.invoke(this._cancelPromises,this,void 0))},t.prototype._cancelPromises=function(){this._length()>0&&this._settlePromises()},t.prototype._unsetOnCancel=function(){this._onCancelField=void 0},t.prototype._isCancellable=function(){return this.isPending()&&!this._isCancelled()},t.prototype.isCancellable=function(){return this.isPending()&&!this.isCancelled()},t.prototype._doInvokeOnCancel=function(e,t){if(o.isArray(e))for(var i=0;i<e.length;++i)this._doInvokeOnCancel(e[i],t);else if(void 0!==e)if("function"==typeof e){if(!t){var n=r(e).call(this._boundValue());n===a&&(this._attachExtraTrace(n.e),l.throwLater(n.e))}}else e._resultCancelled(this)},t.prototype._invokeOnCancel=function(){var e=this._onCancel();this._unsetOnCancel(),l.invoke(this._doInvokeOnCancel,this,e)},t.prototype._invokeInternalOnCancel=function(){this._isCancellable()&&(this._doInvokeOnCancel(this._onCancel(),!0),this._unsetOnCancel())},t.prototype._resultCancelled=function(){this.cancel()}}},{"./util":36}],7:[function(e,t,i){"use strict";
1t.exports=function(t){var i=e("./util"),n=e("./es5").keys,s=i.tryCatch,o=i.errorObj;function r(e,r,a){return function(l){var c=a._boundValue();e:for(var u=0;u<e.length;++u){var h=e[u];if(h===Error||null!=h&&h.prototype instanceof Error){if(l instanceof h)return s(r).call(c,l)}else if("function"==typeof h){var d=s(h).call(c,l);if(d===o)return d;if(d)return s(r).call(c,l)}else if(i.isObject(l)){for(var p=n(h),g=0;g<p.length;++g){var f=p[g];if(h[f]!=l[f])continue e}return s(r).call(c,l)}}return t}}return r}},{"./es5":13,"./util":36}],8:[function(e,t,i){"use strict";t.exports=function(e){var t=!1,i=[];function n(){this._trace=new n.CapturedTrace(o())}function s(){if(t)return new n}function o(){var e=i.length-1;if(e>=0)return i[e]}return e.prototype._promiseCreated=function(){},e.prototype._pushContext=function(){},e.prototype._popContext=function(){return null},e._peekContext=e.prototype._peekContext=function(){},n.prototype._pushContext=function(){void 0!==this._trace&&(this._trace._promiseCreated=null,i.push(this._trace))},n.prototype._popContext=function(){if(void 0!==this._trace){var e=i.pop(),t=e._promiseCreated;return e._promiseCreated=null,t}return null},n.CapturedTrace=null,n.create=s,n.deactivateLongStackTraces=function(){},n.activateLongStackTraces=function(){var i=e.prototype._pushContext,s=e.prototype._popContext,r=e._peekContext,a=e.prototype._peekContext,l=e.prototype._promiseCreated;n.deactivateLongStackTraces=function(){e.prototype._pushContext=i,e.prototype._popContext=s,e._peekContext=r,e.prototype._peekContext=a,e.prototype._promiseCreated=l,t=!1},t=!0,e.prototype._pushContext=n.prototype._pushContext,e.prototype._popContext=n.prototype._popContext,e._peekContext=e.prototype._peekContext=o,e.prototype._promiseCreated=function(){var e=this._peekContext();e&&null==e._promiseCreated&&(e._promiseCreated=this)}},n}},{}],9:[function(e,t,i){"use strict";t.exports=function(t,i,n,s){var o,r,a,l,c=t._async,u=e("./errors").Warning,h=e("./util"),d=e("./es5"),p=h.canAttachTrace,g=/[\\\/]bluebird[\\\/]js[\\\/](release|debug|instrumented)/,f=/\((?:timers\.js):\d+:\d+\)/,m=/[\/<\(](.+?):(\d+):(\d+)\)?\s*$/,_=null,v=null,b=!1,y=!(0==h.env("BLUEBIRD_DEBUG")),w=!(0==h.env("BLUEBIRD_WARNINGS")||!y&&!h.env("BLUEBIRD_WARNINGS")),C=!(0==h.env("BLUEBIRD_LONG_STACK_TRACES")||!y&&!h.env("BLUEBIRD_LONG_STACK_TRACES")),x=0!=h.env("BLUEBIRD_W_FORGOTTEN_RETURN")&&(w||!!h.env("BLUEBIRD_W_FORGOTTEN_RETURN"));!function(){var e=[];function i(){for(var t=0;t<e.length;++t)e[t]._notifyUnhandledRejection();n()}function n(){e.length=0}l=function(t){e.push(t),setTimeout(i,1)},d.defineProperty(t,"_unhandledRejectionCheck",{value:i}),d.defineProperty(t,"_unhandledRejectionClear",{value:n})}(),t.prototype.suppressUnhandledRejections=function(){var e=this._target();e._bitField=-1048577&e._bitField|524288},t.prototype._ensurePossibleRejectionHandled=function(){524288&this._bitField||(this._setRejectionIsUnhandled(),l(this))},t.prototype._notifyUnhandledRejectionIsHandled=function(){ee("rejectionHandled",o,void 0,this)},t.prototype._setReturnedNonUndefined=function(){this._bitField=268435456|this._bitField},t.prototype._returnedNonUndefined=function(){return!!(268435456&this._bitField)},t.prototype._notifyUnhandledRejection=function(){if(this._isRejectionUnhandled()){var e=this._settledValue();this._setUnhandledRejectionIsNotified(),ee("unhandledRejection",r,e,this)}},t.prototype._setUnhandledRejectionIsNotified=function(){this._bitField=262144|this._bitField},t.prototype._unsetUnhandledRejectionIsNotified=function(){this._bitField=-262145&this._bitField},t.prototype._isUnhandledRejectionNotified=function(){return(262144&this._bitField)>0},t.prototype._setRejectionIsUnhandled=function(){this._bitField=1048576|this._bitField},t.prototype._unsetRejectionIsUnhandled=function(){this._bitField=-1048577&this._bitField,this._isUnhandledRejectionNotified()&&(this._unsetUnhandledRejectionIsNotified(),this._notifyUnhandledRejectionIsHandled())},t.prototype._isRejectionUnhandled=function(){return(1048576&this._bitField)>0},t.prototype._warn=function(e,t,i){return W(e,t,i||this)},t.onPossiblyUnhandledRejection=function(e){var i=t._getContext();r=h.contextBind(i,e)},t.onUnhandledRejectionHandled=function(e){var i=t._getContext();o=h.contextBind(i,e)};var k=function(){};t.longStackTraces=function(){if(c.haveItemsQueued()&&!ue.longStackTraces)throw new Error("cannot enable long stack traces after promises have been created\n\n    See http://goo.gl/MqrFmX\n");if(!ue.longStackTraces&&ne()){var e=t.prototype._captureStackTrace,n=t.prototype._attachExtraTrace,s=t.prototype._dereferenceTrace;ue.longStackTraces=!0,k=function(){if(c.haveItemsQueued()&&!ue.longStackTraces)throw new Error("cannot enable long stack traces after promises have been created\n\n    See http://goo.gl/MqrFmX\n");t.prototype._captureStackTrace=e,t.prototype._attachExtraTrace=n,t.prototype._dereferenceTrace=s,i.deactivateLongStackTraces(),ue.longStackTraces=!1},t.prototype._captureStackTrace=V,t.prototype._attachExtraTrace=U,t.prototype._dereferenceTrace=z,i.activateLongStackTraces()}},t.hasLongStackTraces=function(){return ue.longStackTraces&&ne()};var S={unhandledrejection:{before:function(){var e=h.global.onunhandledrejection;return h.global.onunhandledrejection=null,e},after:function(e){h.global.onunhandledrejection=e}},rejectionhandled:{before:function(){var e=h.global.onrejectionhandled;return h.global.onrejectionhandled=null,e},after:function(e){h.global.onrejectionhandled=e}}},T=function(){var e=function(e,t){if(!e)return!h.global.dispatchEvent(t);var i;try{return i=e.before(),!h.global.dispatchEvent(t)}finally{e.after(i)}};try{if("function"==typeof CustomEvent){var t=new CustomEvent("CustomEvent");return h.global.dispatchEvent(t),function(t,i){t=t.toLowerCase();var n=new CustomEvent(t,{detail:i,cancelable:!0});return d.defineProperty(n,"promise",{value:i.promise}),d.defineProperty(n,"reason",{value:i.reason}),e(S[t],n)}}return"function"==typeof Event?(t=new Event("CustomEvent"),h.global.dispatchEvent(t),function(t,i){t=t.toLowerCase();var n=new Event(t,{cancelable:!0});return n.detail=i,d.defineProperty(n,"promise",{value:i.promise}),d.defineProperty(n,"reason",{value:i.reason}),e(S[t],n)}):((t=document.createEvent("CustomEvent")).initCustomEvent("testingtheevent",!1,!0,{}),h.global.dispatchEvent(t),function(t,i){t=t.toLowerCase();var n=document.createEvent("CustomEvent");
1return n.initCustomEvent(t,!1,!0,i),e(S[t],n)})}catch(e){}return function(){return!1}}(),E=h.isNode?function(){return process.emit.apply(process,arguments)}:h.global?function(e){var t="on"+e.toLowerCase(),i=h.global[t];return!!i&&(i.apply(h.global,[].slice.call(arguments,1)),!0)}:function(){return!1};function P(e,t){return{promise:t}}var I={promiseCreated:P,promiseFulfilled:P,promiseRejected:P,promiseResolved:P,promiseCancelled:P,promiseChained:function(e,t,i){return{promise:t,child:i}},warning:function(e,t){return{warning:t}},unhandledRejection:function(e,t,i){return{reason:t,promise:i}},rejectionHandled:P},F=function(e){var t=!1;try{t=E.apply(null,arguments)}catch(e){c.throwLater(e),t=!0}var i=!1;try{i=T(e,I[e].apply(null,arguments))}catch(e){c.throwLater(e),i=!0}return i||t};function A(){return!1}function M(e,t,i){var n=this;try{e(t,i,function(e){if("function"!=typeof e)throw new TypeError("onCancel must be a function, got: "+h.toString(e));n._attachCancellationCallback(e)})}catch(e){return e}}function j(e){if(!this._isCancellable())return this;var t=this._onCancel();void 0!==t?h.isArray(t)?t.push(e):this._setOnCancel([t,e]):this._setOnCancel(e)}function R(){return this._onCancelField}function D(e){this._onCancelField=e}function $(){this._cancellationParent=void 0,this._onCancelField=void 0}function N(e,t){if(1&t){this._cancellationParent=e;var i=e._branchesRemainingToCancel;void 0===i&&(i=0),e._branchesRemainingToCancel=i+1}2&t&&e._isBound()&&this._setBoundTo(e._boundTo)}function O(e,t){2&t&&e._isBound()&&this._setBoundTo(e._boundTo)}t.config=function(e){if("longStackTraces"in(e=Object(e))&&(e.longStackTraces?t.longStackTraces():!e.longStackTraces&&t.hasLongStackTraces()&&k()),"warnings"in e){var i=e.warnings;ue.warnings=!!i,x=ue.warnings,h.isObject(i)&&"wForgottenReturn"in i&&(x=!!i.wForgottenReturn)}if("cancellation"in e&&e.cancellation&&!ue.cancellation){if(c.haveItemsQueued())throw new Error("cannot enable cancellation after promises are in use");t.prototype._clearCancellationData=$,t.prototype._propagateFrom=N,t.prototype._onCancel=R,t.prototype._setOnCancel=D,t.prototype._attachCancellationCallback=j,t.prototype._execute=M,L=N,ue.cancellation=!0}if("monitoring"in e&&(e.monitoring&&!ue.monitoring?(ue.monitoring=!0,t.prototype._fireEvent=F):!e.monitoring&&ue.monitoring&&(ue.monitoring=!1,t.prototype._fireEvent=A)),"asyncHooks"in e&&h.nodeSupportsAsyncResource){var o=ue.asyncHooks,r=!!e.asyncHooks;o!==r&&(ue.asyncHooks=r,r?n():s())}return t},t.prototype._fireEvent=A,t.prototype._execute=function(e,t,i){try{e(t,i)}catch(e){return e}},t.prototype._onCancel=function(){},t.prototype._setOnCancel=function(e){},t.prototype._attachCancellationCallback=function(e){},t.prototype._captureStackTrace=function(){},t.prototype._attachExtraTrace=function(){},t.prototype._dereferenceTrace=function(){},t.prototype._clearCancellationData=function(){},t.prototype._propagateFrom=function(e,t){};var L=O;function B(){var e=this._boundTo;return void 0!==e&&e instanceof t?e.isFulfilled()?e.value():void 0:e}function V(){this._trace=new le(this._peekContext())}function U(e,t){if(p(e)){var i=this._trace;if(void 0!==i&&t&&(i=i._parent),void 0!==i)i.attachExtraTrace(e);else if(!e.__stackCleaned__){var n=X(e);h.notEnumerableProp(e,"stack",n.message+"\n"+n.stack.join("\n")),h.notEnumerableProp(e,"__stackCleaned__",!0)}}}function z(){this._trace=void 0}function H(e,t,i,n,s){if(void 0===e&&null!==t&&x){if(void 0!==s&&s._returnedNonUndefined())return;if(!(65535&n._bitField))return;i&&(i+=" ");var o="",r="";if(t._trace){for(var a=t._trace.stack.split("\n"),l=J(a),c=l.length-1;c>=0;--c){var u=l[c];if(!f.test(u)){var h=u.match(m);h&&(o="at "+h[1]+":"+h[2]+":"+h[3]+" ");break}}if(l.length>0){var d=l[0];for(c=0;c<a.length;++c)if(a[c]===d){c>0&&(r="\n"+a[c-1]);break}}}var p="a promise was created in a "+i+"handler "+o+"but was not returned from it, see http://goo.gl/rRqMUw"+r;n._warn(p,!0,t)}}function q(e,t){var i=e+" is deprecated and will be removed in a future version.";return t&&(i+=" Use "+t+" instead."),W(i)}function W(e,i,n){if(ue.warnings){var s,o=new u(e);
1if(i)n._attachExtraTrace(o);else if(ue.longStackTraces&&(s=t._peekContext()))s.attachExtraTrace(o);else{var r=X(o);o.stack=r.message+"\n"+r.stack.join("\n")}F("warning",o)||Z(o,"",!0)}}function G(e,t){for(var i=0;i<t.length-1;++i)t[i].push("From previous event:"),t[i]=t[i].join("\n");return i<t.length&&(t[i]=t[i].join("\n")),e+"\n"+t.join("\n")}function K(e){for(var t=0;t<e.length;++t)(0===e[t].length||t+1<e.length&&e[t][0]===e[t+1][0])&&(e.splice(t,1),t--)}function Q(e){for(var t=e[0],i=1;i<e.length;++i){for(var n=e[i],s=t.length-1,o=t[s],r=-1,a=n.length-1;a>=0;--a)if(n[a]===o){r=a;break}for(a=r;a>=0;--a){var l=n[a];if(t[s]!==l)break;t.pop(),s--}t=n}}function J(e){for(var t=[],i=0;i<e.length;++i){var n=e[i],s="    (No stack trace)"===n||_.test(n),o=s&&se(n);s&&!o&&(b&&" "!==n.charAt(0)&&(n="    "+n),t.push(n))}return t}function Y(e){for(var t=e.stack.replace(/\s+$/g,"").split("\n"),i=0;i<t.length;++i){var n=t[i];if("    (No stack trace)"===n||_.test(n))break}return i>0&&"SyntaxError"!=e.name&&(t=t.slice(i)),t}function X(e){var t=e.stack,i=e.toString();return t="string"==typeof t&&t.length>0?Y(e):["    (No stack trace)"],{message:i,stack:"SyntaxError"==e.name?t:J(t)}}function Z(e,t,i){if("undefined"!=typeof console){var n;if(h.isObject(e)){var s=e.stack;n=t+v(s,e)}else n=t+String(e);"function"==typeof a?a(n,i):"function"!=typeof console.log&&"object"!=typeof console.log||console.log(n)}}function ee(e,t,i,n){var s=!1;try{"function"==typeof t&&(s=!0,"rejectionHandled"===e?t(n):t(i,n))}catch(e){c.throwLater(e)}"unhandledRejection"===e?F(e,i,n)||s||Z(i,"Unhandled rejection "):F(e,n)}function te(e){var t;if("function"==typeof e)t="[function "+(e.name||"anonymous")+"]";else{if(t=e&&"function"==typeof e.toString?e.toString():h.toString(e),/\[object [a-zA-Z0-9$_]+\]/.test(t))try{t=JSON.stringify(e)}catch(e){}0===t.length&&(t="(empty array)")}return"(<"+ie(t)+">, no stack trace)"}function ie(e){var t=41;return e.length<t?e:e.substr(0,t-3)+"..."}function ne(){return"function"==typeof ce}var se=function(){return!1},oe=/[\/<\(]([^:\/]+):(\d+):(?:\d+)\)?\s*$/;function re(e){var t=e.match(oe);if(t)return{fileName:t[1],line:parseInt(t[2],10)}}function ae(e,t){if(ne()){for(var i,n,s=(e.stack||"").split("\n"),o=(t.stack||"").split("\n"),r=-1,a=-1,l=0;l<s.length;++l)if(c=re(s[l])){i=c.fileName,r=c.line;break}for(l=0;l<o.length;++l){var c;if(c=re(o[l])){n=c.fileName,a=c.line;break}}r<0||a<0||!i||!n||i!==n||r>=a||(se=function(e){if(g.test(e))return!0;var t=re(e);return!!(t&&t.fileName===i&&r<=t.line&&t.line<=a)})}}function le(e){this._parent=e,this._promisesCreated=0;var t=this._length=1+(void 0===e?0:e._length);ce(this,le),t>32&&this.uncycle()}h.inherits(le,Error),i.CapturedTrace=le,le.prototype.uncycle=function(){var e=this._length;if(!(e<2)){for(var t=[],i={},n=0,s=this;void 0!==s;++n)t.push(s),s=s._parent;for(n=(e=this._length=n)-1;n>=0;--n){var o=t[n].stack;void 0===i[o]&&(i[o]=n)}for(n=0;n<e;++n){var r=i[t[n].stack];if(void 0!==r&&r!==n){r>0&&(t[r-1]._parent=void 0,t[r-1]._length=1),t[n]._parent=void 0,t[n]._length=1;var a=n>0?t[n-1]:this;r<e-1?(a._parent=t[r+1],a._parent.uncycle(),a._length=a._parent._length+1):(a._parent=void 0,a._length=1);for(var l=a._length+1,c=n-2;c>=0;--c)t[c]._length=l,l++;return}}}},le.prototype.attachExtraTrace=function(e){if(!e.__stackCleaned__){this.uncycle();for(var t=X(e),i=t.message,n=[t.stack],s=this;void 0!==s;)n.push(J(s.stack.split("\n"))),s=s._parent;Q(n),K(n),h.notEnumerableProp(e,"stack",G(i,n)),h.notEnumerableProp(e,"__stackCleaned__",!0)}};var ce=function(){var e=/^\s*at\s*/,t=function(e,t){return"string"==typeof e?e:void 0!==t.name&&void 0!==t.message?t.toString():te(t)};if("number"==typeof Error.stackTraceLimit&&"function"==typeof Error.captureStackTrace){Error.stackTraceLimit+=6,_=e,v=t;var i=Error.captureStackTrace;return se=function(e){return g.test(e)},function(e,t){Error.stackTraceLimit+=6,i(e,t),Error.stackTraceLimit-=6}}var n,s=new Error;if("string"==typeof s.stack&&s.stack.split("\n")[0].indexOf("stackDetection@")>=0)return _=/@/,v=t,b=!0,function(e){e.stack=(new Error).stack};try{throw new Error}catch(e){n="stack"in e}return!("stack"in s)&&n&&"number"==typeof Error.stackTraceLimit?(_=e,v=t,function(e){Error.stackTraceLimit+=6;try{throw new Error}catch(t){e.stack=t.stack}Error.stackTraceLimit-=6}):(v=function(e,t){return"string"==typeof e?e:"object"!=typeof t&&"function"!=typeof t||void 0===t.name||void 0===t.message?te(t):t.toString()},null)}();"undefined"!=typeof console&&void 0!==console.warn&&(a=function(e){console.warn(e)},h.isNode&&process.stderr.isTTY?a=function(e,t){var i=t?"�[33m":"�[31m";console.warn(i+e+"�[0m\n")}:h.isNode||"string"!=typeof(new Error).stack||(a=function(e,t){console.warn("%c"+e,t?"color: darkorange":"color: red")}));
1var ue={warnings:w,longStackTraces:!1,cancellation:!1,monitoring:!1,asyncHooks:!1};return C&&t.longStackTraces(),{asyncHooks:function(){return ue.asyncHooks},longStackTraces:function(){return ue.longStackTraces},warnings:function(){return ue.warnings},cancellation:function(){return ue.cancellation},monitoring:function(){return ue.monitoring},propagateFromFunction:function(){return L},boundValueFunction:function(){return B},checkForgottenReturns:H,setBounds:ae,warn:W,deprecated:q,CapturedTrace:le,fireDomEvent:T,fireGlobalEvent:E}}},{"./errors":12,"./es5":13,"./util":36}],10:[function(e,t,i){"use strict";t.exports=function(e){function t(){return this.value}function i(){throw this.reason}e.prototype.return=e.prototype.thenReturn=function(i){return i instanceof e&&i.suppressUnhandledRejections(),this._then(t,void 0,void 0,{value:i},void 0)},e.prototype.throw=e.prototype.thenThrow=function(e){return this._then(i,void 0,void 0,{reason:e},void 0)},e.prototype.catchThrow=function(e){if(arguments.length<=1)return this._then(void 0,i,void 0,{reason:e},void 0);var t=arguments[1],n=function(){throw t};return this.caught(e,n)},e.prototype.catchReturn=function(i){if(arguments.length<=1)return i instanceof e&&i.suppressUnhandledRejections(),this._then(void 0,t,void 0,{value:i},void 0);var n=arguments[1];n instanceof e&&n.suppressUnhandledRejections();var s=function(){return n};return this.caught(i,s)}}},{}],11:[function(e,t,i){"use strict";t.exports=function(e,t){var i=e.reduce,n=e.all;function s(){return n(this)}function o(e,n){return i(e,n,t,t)}e.prototype.each=function(e){return i(this,e,t,0)._then(s,void 0,void 0,this,void 0)},e.prototype.mapSeries=function(e){return i(this,e,t,t)},e.each=function(e,n){return i(e,n,t,0)._then(s,void 0,void 0,e,void 0)},e.mapSeries=o}},{}],12:[function(e,t,i){"use strict";var n,s,o=e("./es5"),r=o.freeze,a=e("./util"),l=a.inherits,c=a.notEnumerableProp;function u(e,t){function i(n){if(!(this instanceof i))return new i(n);c(this,"message","string"==typeof n?n:t),c(this,"name",e),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):Error.call(this)}return l(i,Error),i}var h=u("Warning","warning"),d=u("CancellationError","cancellation error"),p=u("TimeoutError","timeout error"),g=u("AggregateError","aggregate error");try{n=TypeError,s=RangeError}catch(e){n=u("TypeError","type error"),s=u("RangeError","range error")}for(var f="join pop push shift unshift slice filter forEach some every map indexOf lastIndexOf reduce reduceRight sort reverse".split(" "),m=0;m<f.length;++m)"function"==typeof Array.prototype[f[m]]&&(g.prototype[f[m]]=Array.prototype[f[m]]);o.defineProperty(g.prototype,"length",{value:0,configurable:!1,writable:!0,enumerable:!0}),g.prototype.isOperational=!0;var _=0;function v(e){if(!(this instanceof v))return new v(e);c(this,"name","OperationalError"),c(this,"message",e),this.cause=e,this.isOperational=!0,e instanceof Error?(c(this,"message",e.message),c(this,"stack",e.stack)):Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}g.prototype.toString=function(){var e=Array(4*_+1).join(" "),t="\n"+e+"AggregateError of:\n";_++,e=Array(4*_+1).join(" ");for(var i=0;i<this.length;++i){for(var n=this[i]===this?"[Circular AggregateError]":this[i]+"",s=n.split("\n"),o=0;o<s.length;++o)s[o]=e+s[o];t+=(n=s.join("\n"))+"\n"}return _--,t},l(v,Error);var b=Error.__BluebirdErrorTypes__;b||(b=r({CancellationError:d,TimeoutError:p,OperationalError:v,RejectionError:v,AggregateError:g}),o.defineProperty(Error,"__BluebirdErrorTypes__",{value:b,writable:!1,enumerable:!1,configurable:!1})),t.exports={Error,TypeError:n,RangeError:s,CancellationError:b.CancellationError,OperationalError:b.OperationalError,TimeoutError:b.TimeoutError,AggregateError:b.AggregateError,Warning:h}},{"./es5":13,"./util":36}],13:[function(e,t,i){var n=function(){"use strict";return void 0===this}();if(n)t.exports={freeze:Object.freeze,defineProperty:Object.defineProperty,getDescriptor:Object.getOwnPropertyDescriptor,keys:Object.keys,names:Object.getOwnPropertyNames,getPrototypeOf:Object.getPrototypeOf,isArray:Array.isArray,isES5:n,propertyIsWritable:function(e,t){var i=Object.getOwnPropertyDescriptor(e,t);return!(i&&!i.writable&&!i.set)}};else{var s={}.hasOwnProperty,o={}.toString,r={}.constructor.prototype,a=function(e){var t=[];
1for(var i in e)s.call(e,i)&&t.push(i);return t},l=function(e,t){return{value:e[t]}},c=function(e,t,i){return e[t]=i.value,e},u=function(e){return e},h=function(e){try{return Object(e).constructor.prototype}catch(e){return r}},d=function(e){try{return"[object Array]"===o.call(e)}catch(e){return!1}};t.exports={isArray:d,keys:a,names:a,defineProperty:c,getDescriptor:l,freeze:u,getPrototypeOf:h,isES5:n,propertyIsWritable:function(){return!0}}}},{}],14:[function(e,t,i){"use strict";t.exports=function(e,t){var i=e.map;e.prototype.filter=function(e,n){return i(this,e,n,t)},e.filter=function(e,n,s){return i(e,n,s,t)}}},{}],15:[function(e,t,i){"use strict";t.exports=function(t,i,n){var s=e("./util"),o=t.CancellationError,r=s.errorObj,a=e("./catch_filter")(n);function l(e,t,i){this.promise=e,this.type=t,this.handler=i,this.called=!1,this.cancelPromise=null}function c(e){this.finallyHandler=e}function u(e,t){return null!=e.cancelPromise&&(arguments.length>1?e.cancelPromise._reject(t):e.cancelPromise._cancel(),e.cancelPromise=null,!0)}function h(){return p.call(this,this.promise._target()._settledValue())}function d(e){if(!u(this,e))return r.e=e,r}function p(e){var s=this.promise,a=this.handler;if(!this.called){this.called=!0;var l=this.isFinallyHandler()?a.call(s._boundValue()):a.call(s._boundValue(),e);if(l===n)return l;if(void 0!==l){s._setReturnedNonUndefined();var p=i(l,s);if(p instanceof t){if(null!=this.cancelPromise){if(p._isCancelled()){var g=new o("late cancellation observer");return s._attachExtraTrace(g),r.e=g,r}p.isPending()&&p._attachCancellationCallback(new c(this))}return p._then(h,d,void 0,this,void 0)}}}return s.isRejected()?(u(this),r.e=e,r):(u(this),e)}return l.prototype.isFinallyHandler=function(){return 0===this.type},c.prototype._resultCancelled=function(){u(this.finallyHandler)},t.prototype._passThrough=function(e,t,i,n){return"function"!=typeof e?this.then():this._then(i,n,void 0,new l(this,t,e),void 0)},t.prototype.lastly=t.prototype.finally=function(e){return this._passThrough(e,0,p,p)},t.prototype.tap=function(e){return this._passThrough(e,1,p)},t.prototype.tapCatch=function(e){var i=arguments.length;if(1===i)return this._passThrough(e,1,void 0,p);var n,o=new Array(i-1),r=0;for(n=0;n<i-1;++n){var l=arguments[n];if(!s.isObject(l))return t.reject(new TypeError("tapCatch statement predicate: expecting an object but got "+s.classString(l)));o[r++]=l}o.length=r;var c=arguments[n];return this._passThrough(a(o,c,this),1,void 0,p)},l}},{"./catch_filter":7,"./util":36}],16:[function(e,t,i){"use strict";t.exports=function(t,i,n,s,o,r){var a=e("./errors").TypeError,l=e("./util"),c=l.errorObj,u=l.tryCatch,h=[];function d(e,i,n){for(var o=0;o<i.length;++o){n._pushContext();var r=u(i[o])(e);if(n._popContext(),r===c){n._pushContext();var a=t.reject(c.e);return n._popContext(),a}var l=s(r,n);if(l instanceof t)return l}return null}function p(e,i,s,o){if(r.cancellation()){var a=new t(n),l=this._finallyPromise=new t(n);this._promise=a.lastly(function(){return l}),a._captureStackTrace(),a._setOnCancel(this)}else(this._promise=new t(n))._captureStackTrace();this._stack=o,this._generatorFunction=e,this._receiver=i,this._generator=void 0,this._yieldHandlers="function"==typeof s?[s].concat(h):h,this._yieldedPromise=null,this._cancellationPhase=!1}l.inherits(p,o),p.prototype._isResolved=function(){return null===this._promise},p.prototype._cleanup=function(){this._promise=this._generator=null,r.cancellation()&&null!==this._finallyPromise&&(this._finallyPromise._fulfill(),this._finallyPromise=null)},p.prototype._promiseCancelled=function(){if(!this._isResolved()){var e;if(void 0!==this._generator.return)this._promise._pushContext(),e=u(this._generator.return).call(this._generator,void 0),this._promise._popContext();else{var i=new t.CancellationError("generator .return() sentinel");t.coroutine.returnSentinel=i,this._promise._attachExtraTrace(i),this._promise._pushContext(),e=u(this._generator.throw).call(this._generator,i),this._promise._popContext()}this._cancellationPhase=!0,this._yieldedPromise=null,this._continue(e)}},p.prototype._promiseFulfilled=function(e){this._yieldedPromise=null,this._promise._pushContext();var t=u(this._generator.next).call(this._generator,e);this._promise._popContext(),this._continue(t)}
1,p.prototype._promiseRejected=function(e){this._yieldedPromise=null,this._promise._attachExtraTrace(e),this._promise._pushContext();var t=u(this._generator.throw).call(this._generator,e);this._promise._popContext(),this._continue(t)},p.prototype._resultCancelled=function(){if(this._yieldedPromise instanceof t){var e=this._yieldedPromise;this._yieldedPromise=null,e.cancel()}},p.prototype.promise=function(){return this._promise},p.prototype._run=function(){this._generator=this._generatorFunction.call(this._receiver),this._receiver=this._generatorFunction=void 0,this._promiseFulfilled(void 0)},p.prototype._continue=function(e){var i=this._promise;if(e===c)return this._cleanup(),this._cancellationPhase?i.cancel():i._rejectCallback(e.e,!1);var n=e.value;if(!0===e.done)return this._cleanup(),this._cancellationPhase?i.cancel():i._resolveCallback(n);var o=s(n,this._promise);if(o instanceof t||null!==(o=d(o,this._yieldHandlers,this._promise))){var r=(o=o._target())._bitField;50397184&r?33554432&r?t._async.invoke(this._promiseFulfilled,this,o._value()):16777216&r?t._async.invoke(this._promiseRejected,this,o._reason()):this._promiseCancelled():(this._yieldedPromise=o,o._proxy(this,null))}else this._promiseRejected(new a("A value %s was yielded that could not be treated as a promise\n\n    See http://goo.gl/MqrFmX\n\n".replace("%s",String(n))+"From coroutine:\n"+this._stack.split("\n").slice(1,-7).join("\n")))},t.coroutine=function(e,t){if("function"!=typeof e)throw new a("generatorFunction must be a function\n\n    See http://goo.gl/MqrFmX\n");var i=Object(t).yieldHandler,n=p,s=(new Error).stack;return function(){var t=e.apply(this,arguments),o=new n(void 0,void 0,i,s),r=o.promise();return o._generator=t,o._promiseFulfilled(void 0),r}},t.coroutine.addYieldHandler=function(e){if("function"!=typeof e)throw new a("expecting a function but got "+l.classString(e));h.push(e)},t.spawn=function(e){if(r.deprecated("Promise.spawn()","Promise.coroutine()"),"function"!=typeof e)return i("generatorFunction must be a function\n\n    See http://goo.gl/MqrFmX\n");var n=new p(e,this),s=n.promise();return n._run(t.spawn),s}}},{"./errors":12,"./util":36}],17:[function(e,t,i){"use strict";t.exports=function(t,i,n,s,o){var r=e("./util");r.canEvaluate,r.tryCatch,r.errorObj,t.join=function(){var e,t=arguments.length-1;t>0&&"function"==typeof arguments[t]&&(e=arguments[t]);var n=[].slice.call(arguments);e&&n.pop();var s=new i(n).promise();return void 0!==e?s.spread(e):s}}},{"./util":36}],18:[function(e,t,i){"use strict";t.exports=function(t,i,n,s,o,r){var a=e("./util"),l=a.tryCatch,c=a.errorObj,u=t._async;function h(e,i,n,s){this.constructor$(e),this._promise._captureStackTrace();var r=t._getContext();if(this._callback=a.contextBind(r,i),this._preservedValues=s===o?new Array(this.length()):null,this._limit=n,this._inFlight=0,this._queue=[],u.invoke(this._asyncInit,this,void 0),a.isArray(e))for(var l=0;l<e.length;++l){var c=e[l];c instanceof t&&c.suppressUnhandledRejections()}}function d(e,i,s,o){if("function"!=typeof i)return n("expecting a function but got "+a.classString(i));var r=0;if(void 0!==s){if("object"!=typeof s||null===s)return t.reject(new TypeError("options argument must be an object but it is "+a.classString(s)));if("number"!=typeof s.concurrency)return t.reject(new TypeError("'concurrency' must be a number but it is "+a.classString(s.concurrency)));r=s.concurrency}return new h(e,i,r="number"==typeof r&&isFinite(r)&&r>=1?r:0,o).promise()}a.inherits(h,i),h.prototype._asyncInit=function(){this._init$(void 0,-2)},h.prototype._init=function(){},h.prototype._promiseFulfilled=function(e,i){var n=this._values,o=this.length(),a=this._preservedValues,u=this._limit;if(i<0){if(n[i=-1*i-1]=e,u>=1&&(this._inFlight--,this._drainQueue(),this._isResolved()))return!0}else{if(u>=1&&this._inFlight>=u)return n[i]=e,this._queue.push(i),!1;null!==a&&(a[i]=e);var h=this._promise,d=this._callback,p=h._boundValue();h._pushContext();var g=l(d).call(p,e,i,o),f=h._popContext();if(r.checkForgottenReturns(g,f,null!==a?"Promise.filter":"Promise.map",h),g===c)return this._reject(g.e),!0;var m=s(g,this._promise);if(m instanceof t){var _=(m=m._target())._bitField;if(!(50397184&_))return u>=1&&this._inFlight++,n[i]=m,m._proxy(this,-1*(i+1)),!1;if(!(33554432&_))return 16777216&_?(this._reject(m._reason()),!0):(this._cancel(),!0);g=m._value()}n[i]=g}return++this._totalResolved>=o&&(null!==a?this._filter(n,a):this._resolve(n),!0)},h.prototype._drainQueue=function(){for(var e=this._queue,t=this._limit,i=this._values;e.length>0&&this._inFlight<t;){if(this._isResolved())return;var n=e.pop();this._promiseFulfilled(i[n],n)}},h.prototype._filter=function(e,t){for(var i=t.length,n=new Array(i),s=0,o=0;o<i;
1++o)e[o]&&(n[s++]=t[o]);n.length=s,this._resolve(n)},h.prototype.preservedValues=function(){return this._preservedValues},t.prototype.map=function(e,t){return d(this,e,t,null)},t.map=function(e,t,i,n){return d(e,t,i,n)}}},{"./util":36}],19:[function(e,t,i){"use strict";t.exports=function(t,i,n,s,o){var r=e("./util"),a=r.tryCatch;t.method=function(e){if("function"!=typeof e)throw new t.TypeError("expecting a function but got "+r.classString(e));return function(){var n=new t(i);n._captureStackTrace(),n._pushContext();var s=a(e).apply(this,arguments),r=n._popContext();return o.checkForgottenReturns(s,r,"Promise.method",n),n._resolveFromSyncValue(s),n}},t.attempt=t.try=function(e){if("function"!=typeof e)return s("expecting a function but got "+r.classString(e));var n,l=new t(i);if(l._captureStackTrace(),l._pushContext(),arguments.length>1){o.deprecated("calling Promise.try with more than 1 argument");var c=arguments[1],u=arguments[2];n=r.isArray(c)?a(e).apply(u,c):a(e).call(u,c)}else n=a(e)();var h=l._popContext();return o.checkForgottenReturns(n,h,"Promise.try",l),l._resolveFromSyncValue(n),l},t.prototype._resolveFromSyncValue=function(e){e===r.errorObj?this._rejectCallback(e.e,!1):this._resolveCallback(e,!0)}}},{"./util":36}],20:[function(e,t,i){"use strict";var n=e("./util"),s=n.maybeWrapAsError,o=e("./errors").OperationalError,r=e("./es5");function a(e){return e instanceof Error&&r.getPrototypeOf(e)===Error.prototype}var l=/^(?:name|message|stack|cause)$/;function c(e){var t;if(a(e)){(t=new o(e)).name=e.name,t.message=e.message,t.stack=e.stack;for(var i=r.keys(e),s=0;s<i.length;++s){var c=i[s];l.test(c)||(t[c]=e[c])}return t}return n.markAsOriginatingFromRejection(e),e}function u(e,t){return function(i,n){if(null!==e){if(i){var o=c(s(i));e._attachExtraTrace(o),e._reject(o)}else if(t){var r=[].slice.call(arguments,1);e._fulfill(r)}else e._fulfill(n);e=null}}}t.exports=u},{"./errors":12,"./es5":13,"./util":36}],21:[function(e,t,i){"use strict";t.exports=function(t){var i=e("./util"),n=t._async,s=i.tryCatch,o=i.errorObj;function r(e,t){var r=this;if(!i.isArray(e))return a.call(r,e,t);var l=s(t).apply(r._boundValue(),[null].concat(e));l===o&&n.throwLater(l.e)}function a(e,t){var i=this._boundValue(),r=void 0===e?s(t).call(i,null):s(t).call(i,null,e);r===o&&n.throwLater(r.e)}function l(e,t){var i=this;if(!e){var r=new Error(e+"");r.cause=e,e=r}var a=s(t).call(i._boundValue(),e);a===o&&n.throwLater(a.e)}t.prototype.asCallback=t.prototype.nodeify=function(e,t){if("function"==typeof e){var i=a;void 0!==t&&Object(t).spread&&(i=r),this._then(i,l,void 0,this,e)}return this}}},{"./util":36}],22:[function(e,t,i){"use strict";t.exports=function(){var i=function(){return new y("circular promise resolution chain\n\n    See http://goo.gl/MqrFmX\n")},n=function(){return new $.PromiseInspection(this._target())},s=function(e){return $.reject(new y(e))};function o(){}var r={},a=e("./util");a.setReflectHandler(n);var l=function(){var e=process.domain;return void 0===e?null:e},c=function(){return null},u=function(){return{domain:l(),async:null}},h=a.isNode&&a.nodeSupportsAsyncResource?e("async_hooks").AsyncResource:null,d=function(){return{domain:l(),async:new h("Bluebird::Promise")}},p=a.isNode?u:c;a.notEnumerableProp($,"_getContext",p);var g=function(){p=d,a.notEnumerableProp($,"_getContext",d)},f=function(){p=u,a.notEnumerableProp($,"_getContext",u)},m=e("./es5"),_=e("./async"),v=new _;m.defineProperty($,"_async",{value:v});var b=e("./errors"),y=$.TypeError=b.TypeError;$.RangeError=b.RangeError;var w=$.CancellationError=b.CancellationError;$.TimeoutError=b.TimeoutError,$.OperationalError=b.OperationalError,$.RejectionError=b.OperationalError,$.AggregateError=b.AggregateError;var C=function(){},x={},k={},S=e("./thenables")($,C),T=e("./promise_array")($,C,S,s,o),E=e("./context")($),P=E.create,I=e("./debuggability")($,E,g,f),F=(I.CapturedTrace,e("./finally")($,S,k)),A=e("./catch_filter")(k),M=e("./nodeback"),j=a.errorObj,R=a.tryCatch;function D(e,t){if(null==e||e.constructor!==$)throw new y("the promise constructor cannot be invoked directly\n\n    See http://goo.gl/MqrFmX\n");if("function"!=typeof t)throw new y("expecting a function but got "+a.classString(t))}function $(e){e!==C&&D(this,e),this._bitField=0,this._fulfillmentHandler0=void 0,this._rejectionHandler0=void 0,this._promise0=void 0,this._receiver0=void 0,this._resolveFromExecutor(e),this._promiseCreated(),this._fireEvent("promiseCreated",this)}function N(e){this.promise._resolveCallback(e)}function O(e){this.promise._rejectCallback(e,!1)}function L(e){var t=new $(C);t._fulfillmentHandler0=e,t._rejectionHandler0=e,t._promise0=e,t._receiver0=e}return $.prototype.toString=function(){return"[object Promise]"},$.prototype.caught=$.prototype.catch=function(e){var t=arguments.length;if(t>1){var i,n=new Array(t-1),o=0;for(i=0;i<t-1;++i){var r=arguments[i];if(!a.isObject(r))return s("Catch statement predicate: expecting an object but got "+a.classString(r));n[o++]=r}if(n.length=o,"function"!=typeof(e=arguments[i]))throw new y("The last argument to .catch() must be a function, got "+a.toString(e));return this.then(void 0,A(n,e,this))}return this.then(void 0,e)},$.prototype.reflect=function(){return this._then(n,n,void 0,this,void 0)},$.prototype.then=function(e,t){if(I.warnings()&&arguments.length>0&&"function"!=typeof e&&"function"!=typeof t){var i=".then() only accepts functions but was passed: "+a.classString(e);arguments.length>1&&(i+=", "+a.classString(t)),this._warn(i)}return this._then(e,t,void 0,void 0,void 0)},$.prototype.done=function(e,t){this._then(e,t,void 0,void 0,void 0)._setIsFinal()},$.prototype.spread=function(e){return"function"!=typeof e?s("expecting a function but got "+a.classString(e)):this.all()._then(e,void 0,void 0,x,void 0)},$.prototype.toJSON=function(){var e={isFulfilled:!1,isRejected:!1,fulfillmentValue:void 0,rejectionReason:void 0};return this.isFulfilled()?(e.fulfillmentValue=this.value(),e.isFulfilled=!0):this.isRejected()&&(e.rejectionReason=this.reason(),e.isRejected=!0),e},$.prototype.all=function(){return arguments.length>0&&this._warn(".all() was passed arguments but it does not take any"),new T(this).promise()},$.prototype.error=function(e){return this.caught(a.originatesFromRejection,e)},$.getNewLibraryCopy=t.exports,$.is=function(e){return e instanceof $},$.fromNode=$.fromCallback=function(e){var t=new $(C);t._captureStackTrace();var i=arguments.length>1&&!!Object(arguments[1]).multiArgs,n=R(e)(M(t,i));return n===j&&t._rejectCallback(n.e,!0),t._isFateSealed()||t._setAsyncGuaranteed(),t},$.all=function(e){return new T(e).promise()},$.cast=function(e){var t=S(e);return t instanceof $||((t=new $(C))._captureStackTrace(),t._setFulfilled(),t._rejectionHandler0=e),t},$.resolve=$.fulfilled=$.cast,$.reject=$.rejected=function(e){var t=new $(C);return t._captureStackTrace(),t._rejectCallback(e,!0),t}
1,$.setScheduler=function(e){if("function"!=typeof e)throw new y("expecting a function but got "+a.classString(e));return v.setScheduler(e)},$.prototype._then=function(e,t,i,n,s){var o=void 0!==s,r=o?s:new $(C),l=this._target(),c=l._bitField;o||(r._propagateFrom(this,3),r._captureStackTrace(),void 0===n&&2097152&this._bitField&&(n=50397184&c?this._boundValue():l===this?void 0:this._boundTo),this._fireEvent("promiseChained",this,r));var u=p();if(50397184&c){var h,d,g=l._settlePromiseCtx;33554432&c?(d=l._rejectionHandler0,h=e):16777216&c?(d=l._fulfillmentHandler0,h=t,l._unsetRejectionIsUnhandled()):(g=l._settlePromiseLateCancellationObserver,d=new w("late cancellation observer"),l._attachExtraTrace(d),h=t),v.invoke(g,l,{handler:a.contextBind(u,h),promise:r,receiver:n,value:d})}else l._addCallbacks(e,t,r,n,u);return r},$.prototype._length=function(){return 65535&this._bitField},$.prototype._isFateSealed=function(){return!!(117506048&this._bitField)},$.prototype._isFollowing=function(){return!(67108864&~this._bitField)},$.prototype._setLength=function(e){this._bitField=-65536&this._bitField|65535&e},$.prototype._setFulfilled=function(){this._bitField=33554432|this._bitField,this._fireEvent("promiseFulfilled",this)},$.prototype._setRejected=function(){this._bitField=16777216|this._bitField,this._fireEvent("promiseRejected",this)},$.prototype._setFollowing=function(){this._bitField=67108864|this._bitField,this._fireEvent("promiseResolved",this)},$.prototype._setIsFinal=function(){this._bitField=4194304|this._bitField},$.prototype._isFinal=function(){return(4194304&this._bitField)>0},$.prototype._unsetCancelled=function(){this._bitField=-65537&this._bitField},$.prototype._setCancelled=function(){this._bitField=65536|this._bitField,this._fireEvent("promiseCancelled",this)},$.prototype._setWillBeCancelled=function(){this._bitField=8388608|this._bitField},$.prototype._setAsyncGuaranteed=function(){if(!v.hasCustomScheduler()){var e=this._bitField;this._bitField=e|(536870912&e)>>2^134217728}},$.prototype._setNoAsyncGuarantee=function(){this._bitField=-134217729&this._bitField|536870912},$.prototype._receiverAt=function(e){var t=0===e?this._receiver0:this[4*e-4+3];if(t!==r)return void 0===t&&this._isBound()?this._boundValue():t},$.prototype._promiseAt=function(e){return this[4*e-4+2]},$.prototype._fulfillmentHandlerAt=function(e){return this[4*e-4+0]},$.prototype._rejectionHandlerAt=function(e){return this[4*e-4+1]},$.prototype._boundValue=function(){},$.prototype._migrateCallback0=function(e){e._bitField;var t=e._fulfillmentHandler0,i=e._rejectionHandler0,n=e._promise0,s=e._receiverAt(0);void 0===s&&(s=r),this._addCallbacks(t,i,n,s,null)},$.prototype._migrateCallbackAt=function(e,t){var i=e._fulfillmentHandlerAt(t),n=e._rejectionHandlerAt(t),s=e._promiseAt(t),o=e._receiverAt(t);void 0===o&&(o=r),this._addCallbacks(i,n,s,o,null)},$.prototype._addCallbacks=function(e,t,i,n,s){var o=this._length();if(o>=65531&&(o=0,this._setLength(0)),0===o)this._promise0=i,this._receiver0=n,"function"==typeof e&&(this._fulfillmentHandler0=a.contextBind(s,e)),"function"==typeof t&&(this._rejectionHandler0=a.contextBind(s,t));else{var r=4*o-4;this[r+2]=i,this[r+3]=n,"function"==typeof e&&(this[r+0]=a.contextBind(s,e)),"function"==typeof t&&(this[r+1]=a.contextBind(s,t))}return this._setLength(o+1),o},$.prototype._proxy=function(e,t){this._addCallbacks(void 0,void 0,t,e,null)},$.prototype._resolveCallback=function(e,t){if(!(117506048&this._bitField)){if(e===this)return this._rejectCallback(i(),!1);var n=S(e,this);if(!(n instanceof $))return this._fulfill(e);t&&this._propagateFrom(n,2);var s=n._target();if(s!==this){var o=s._bitField;if(50397184&o)if(33554432&o)this._fulfill(s._value());else if(16777216&o)this._reject(s._reason());else{var r=new w("late cancellation observer");s._attachExtraTrace(r),this._reject(r)}else{var a=this._length();a>0&&s._migrateCallback0(this);for(var l=1;l<a;++l)s._migrateCallbackAt(this,l);this._setFollowing(),this._setLength(0),this._setFollowee(n)}}else this._reject(i())}},$.prototype._rejectCallback=function(e,t,i){var n=a.ensureErrorObject(e),s=n===e;if(!s&&!i&&I.warnings()){var o="a promise was rejected with a non-error: "+a.classString(e);this._warn(o,!0)}this._attachExtraTrace(n,!!t&&s),this._reject(e)},$.prototype._resolveFromExecutor=function(e){if(e!==C){var t=this;this._captureStackTrace(),this._pushContext();var i=!0,n=this._execute(e,function(e){t._resolveCallback(e)},function(e){t._rejectCallback(e,i)});i=!1,this._popContext(),void 0!==n&&t._rejectCallback(n,!0)}},$.prototype._settlePromiseFromHandler=function(e,t,i,n){var s=n._bitField;if(!(65536&s)){var o;n._pushContext(),t===x?i&&"number"==typeof i.length?o=R(e).apply(this._boundValue(),i):(o=j).e=new y("cannot .spread() a non-array: "+a.classString(i)):o=R(e).call(t,i);var r=n._popContext();65536&(s=n._bitField)||(o===k?n._reject(i):o===j?n._rejectCallback(o.e,!1):(I.checkForgottenReturns(o,r,"",n,this),n._resolveCallback(o)))}},$.prototype._target=function(){for(var e=this;e._isFollowing();)e=e._followee();return e},$.prototype._followee=function(){return this._rejectionHandler0},$.prototype._setFollowee=function(e){this._rejectionHandler0=e},$.prototype._settlePromise=function(e,t,i,s){var r=e instanceof $,a=this._bitField,l=!!(134217728&a);65536&a?(r&&e._invokeInternalOnCancel(),i instanceof F&&i.isFinallyHandler()?(i.cancelPromise=e,R(t).call(i,s)===j&&e._reject(j.e)):t===n?e._fulfill(n.call(i)):i instanceof o?i._promiseCancelled(e):r||e instanceof T?e._cancel():i.cancel()):"function"==typeof t?r?(l&&e._setAsyncGuaranteed(),this._settlePromiseFromHandler(t,i,s,e)):t.call(i,s,e):i instanceof o?i._isResolved()||(33554432&a?i._promiseFulfilled(s,e):i._promiseRe
1jected(s,e)):r&&(l&&e._setAsyncGuaranteed(),33554432&a?e._fulfill(s):e._reject(s))},$.prototype._settlePromiseLateCancellationObserver=function(e){var t=e.handler,i=e.promise,n=e.receiver,s=e.value;"function"==typeof t?i instanceof $?this._settlePromiseFromHandler(t,n,s,i):t.call(n,s,i):i instanceof $&&i._reject(s)},$.prototype._settlePromiseCtx=function(e){this._settlePromise(e.promise,e.handler,e.receiver,e.value)},$.prototype._settlePromise0=function(e,t,i){var n=this._promise0,s=this._receiverAt(0);this._promise0=void 0,this._receiver0=void 0,this._settlePromise(n,e,s,t)},$.prototype._clearCallbackDataAtIndex=function(e){var t=4*e-4;this[t+2]=this[t+3]=this[t+0]=this[t+1]=void 0},$.prototype._fulfill=function(e){var t=this._bitField;if(!((117506048&t)>>>16)){if(e===this){var n=i();return this._attachExtraTrace(n),this._reject(n)}this._setFulfilled(),this._rejectionHandler0=e,(65535&t)>0&&(134217728&t?this._settlePromises():v.settlePromises(this),this._dereferenceTrace())}},$.prototype._reject=function(e){var t=this._bitField;if(!((117506048&t)>>>16)){if(this._setRejected(),this._fulfillmentHandler0=e,this._isFinal())return v.fatalError(e,a.isNode);(65535&t)>0?v.settlePromises(this):this._ensurePossibleRejectionHandled()}},$.prototype._fulfillPromises=function(e,t){for(var i=1;i<e;i++){var n=this._fulfillmentHandlerAt(i),s=this._promiseAt(i),o=this._receiverAt(i);this._clearCallbackDataAtIndex(i),this._settlePromise(s,n,o,t)}},$.prototype._rejectPromises=function(e,t){for(var i=1;i<e;i++){var n=this._rejectionHandlerAt(i),s=this._promiseAt(i),o=this._receiverAt(i);this._clearCallbackDataAtIndex(i),this._settlePromise(s,n,o,t)}},$.prototype._settlePromises=function(){var e=this._bitField,t=65535&e;if(t>0){if(16842752&e){var i=this._fulfillmentHandler0;this._settlePromise0(this._rejectionHandler0,i,e),this._rejectPromises(t,i)}else{var n=this._rejectionHandler0;this._settlePromise0(this._fulfillmentHandler0,n,e),this._fulfillPromises(t,n)}this._setLength(0)}this._clearCancellationData()},$.prototype._settledValue=function(){var e=this._bitField;return 33554432&e?this._rejectionHandler0:16777216&e?this._fulfillmentHandler0:void 0},"undefined"!=typeof Symbol&&Symbol.toStringTag&&m.defineProperty($.prototype,Symbol.toStringTag,{get:function(){return"Object"}}),$.defer=$.pending=function(){return I.deprecated("Promise.defer","new Promise"),{promise:new $(C),resolve:N,reject:O}},a.notEnumerableProp($,"_makeSelfResolutionError",i),e("./method")($,C,S,s,I),e("./bind")($,C,S,I),e("./cancel")($,T,s,I),e("./direct_resolve")($),e("./synchronous_inspection")($),e("./join")($,T,S,C,v),$.Promise=$,$.version="3.7.2",e("./call_get.js")($),e("./generators.js")($,s,C,S,o,I),e("./map.js")($,T,s,S,C,I),e("./nodeify.js")($),e("./promisify.js")($,C),e("./props.js")($,T,S,s),e("./race.js")($,C,S,s),e("./reduce.js")($,T,s,S,C,I),e("./settle.js")($,T,I),e("./some.js")($,T,s),e("./timers.js")($,C,I),e("./using.js")($,s,S,P,C,I),e("./any.js")($),e("./each.js")($,C),e("./filter.js")($,C),a.toFastProperties($),a.toFastProperties($.prototype),L({a:1}),L({b:2}),L({c:3}),L(1),L(function(){}),L(void 0),L(!1),L(new $(C)),I.setBounds(_.firstLineError,a.lastLineError),$}},{"./any.js":1,"./async":2,"./bind":3,"./call_get.js":5,"./cancel":6,"./catch_filter":7,"./context":8,"./debuggability":9,"./direct_resolve":10,"./each.js":11,"./errors":12,"./es5":13,"./filter.js":14,"./finally":15,"./generators.js":16,"./join":17,"./map.js":18,"./method":19,"./nodeback":20,"./nodeify.js":21,"./promise_array":23,"./promisify.js":24,"./props.js":25,"./race.js":27,"./reduce.js":28,"./settle.js":30,"./some.js":31,"./synchronous_inspection":32,"./thenables":33,"./timers.js":34,"./using.js":35,"./util":36,async_hooks:void 0}],23:[function(e,t,i){"use strict";t.exports=function(t,i,n,s,o){var r=e("./util");function a(e){switch(e){case-2:return[];case-3:return{};case-6:return new Map}}function l(e){var n=this._promise=new t(i);e instanceof t&&(n._propagateFrom(e,3),e.suppressUnhandledRejections()),n._setOnCancel(this),this._values=e,this._length=0,this._totalResolved=0,this._init(void 0,-2)}return r.isArray,r.inherits(l,o),l.prototype.length=function(){return this._length},l.prototype.promise=function(){return this._promise},l.prototype._init=function e(i,o){var l=n(this._values,this._promise);if(l instanceof t){var c=(l=l._target())._bitField;if(this._values=l,!(50397184&c))return this._promise._setAsyncGuaranteed(),l._then(e,this._reject,void 0,this,o);if(!(33554432&c))return 16777216&c?this._reject(l._reason()):this._cancel();l=l._value()}if(null!==(l=r.asArray(l)))0!==l.length?this._iterate(l):-5===o?this._resolveEmptyArray():this._resolve(a(o));else{var u=s("expecting an array or an iterable object but got "+r.classString(l)).reason();this._promise._rejectCallback(u,!1)}},l.prototype._iterate=function(e){var i=this.getActualLength(e.length);this._length=i,this._values=this.shouldCopyValues()?new Array(i):this._values;for(var s=this._promise,o=!1,r=null,a=0;a<i;++a){var l=n(e[a],s);r=l instanceof t?(l=l._target())._bitField:null,o?null!==r&&l.suppressUnhandledRejections():null!==r?50397184&r?o=33554432&r?this._promiseFulfilled(l._value(),a):16777216&r?this._promiseRe
1jected(l._reason(),a):this._promiseCancelled(a):(l._proxy(this,a),this._values[a]=l):o=this._promiseFulfilled(l,a)}o||s._setAsyncGuaranteed()},l.prototype._isResolved=function(){return null===this._values},l.prototype._resolve=function(e){this._values=null,this._promise._fulfill(e)},l.prototype._cancel=function(){!this._isResolved()&&this._promise._isCancellable()&&(this._values=null,this._promise._cancel())},l.prototype._reject=function(e){this._values=null,this._promise._rejectCallback(e,!1)},l.prototype._promiseFulfilled=function(e,t){return this._values[t]=e,++this._totalResolved>=this._length&&(this._resolve(this._values),!0)},l.prototype._promiseCancelled=function(){return this._cancel(),!0},l.prototype._promiseRejected=function(e){return this._totalResolved++,this._reject(e),!0},l.prototype._resultCancelled=function(){if(!this._isResolved()){var e=this._values;if(this._cancel(),e instanceof t)e.cancel();else for(var i=0;i<e.length;++i)e[i]instanceof t&&e[i].cancel()}},l.prototype.shouldCopyValues=function(){return!0},l.prototype.getActualLength=function(e){return e},l}},{"./util":36}],24:[function(e,t,i){"use strict";t.exports=function(t,i){var n={},s=e("./util"),o=e("./nodeback"),r=s.withAppended,a=s.maybeWrapAsError,l=s.canEvaluate,c=e("./errors").TypeError,u="Async",h={__isPromisified__:!0},d=new RegExp("^(?:"+["arity","length","name","arguments","caller","callee","prototype","__isPromisified__"].join("|")+")$"),p=function(e){return s.isIdentifier(e)&&"_"!==e.charAt(0)&&"constructor"!==e};function g(e){return!d.test(e)}function f(e){try{return!0===e.__isPromisified__}catch(e){return!1}}function m(e,t,i){var n=s.getDataPropertyOrDefault(e,t+i,h);return!!n&&f(n)}function _(e,t,i){for(var n=0;n<e.length;n+=2){var s=e[n];if(i.test(s))for(var o=s.replace(i,""),r=0;r<e.length;r+=2)if(e[r]===o)throw new c("Cannot promisify an API that has normal methods with '%s'-suffix\n\n    See http://goo.gl/MqrFmX\n".replace("%s",t))}}function v(e,t,i,n){for(var o=s.inheritedDataKeys(e),r=[],a=0;a<o.length;++a){var l=o[a],c=e[l],u=n===p||p(l,c,e);"function"!=typeof c||f(c)||m(e,l,t)||!n(l,c,e,u)||r.push(l,c)}return _(r,t,i),r}var b,y=function(e){return e.replace(/([$])/,"\\$")};function w(e,l,c,u,h,d){var p=function(){return this}(),g=e;function f(){var s=l;l===n&&(s=this);var c=new t(i);c._captureStackTrace();var u="string"==typeof g&&this!==p?this[g]:e,h=o(c,d);try{u.apply(s,r(arguments,h))}catch(e){c._rejectCallback(a(e),!0,!0)}return c._isFateSealed()||c._setAsyncGuaranteed(),c}return"string"==typeof g&&(e=u),s.notEnumerableProp(f,"__isPromisified__",!0),f}var C=l?b:w;function x(e,t,i,o,r){for(var a=new RegExp(y(t)+"$"),l=v(e,t,a,i),c=0,u=l.length;c<u;c+=2){var h=l[c],d=l[c+1],p=h+t;if(o===C)e[p]=C(h,n,h,d,t,r);else{var g=o(d,function(){return C(h,n,h,d,t,r)});s.notEnumerableProp(g,"__isPromisified__",!0),e[p]=g}}return s.toFastProperties(e),e}function k(e,t,i){return C(e,t,void 0,e,null,i)}t.promisify=function(e,t){if("function"!=typeof e)throw new c("expecting a function but got "+s.classString(e));if(f(e))return e;var i=k(e,void 0===(t=Object(t)).context?n:t.context,!!t.multiArgs);return s.copyDescriptors(e,i,g),i},t.promisifyAll=function(e,t){if("function"!=typeof e&&"object"!=typeof e)throw new c("the target of promisifyAll must be an object or a function\n\n    See http://goo.gl/MqrFmX\n");var i=!!(t=Object(t)).multiArgs,n=t.suffix;"string"!=typeof n&&(n=u);var o=t.filter;"function"!=typeof o&&(o=p);var r=t.promisifier;if("function"!=typeof r&&(r=C),!s.isIdentifier(n))throw new RangeError("suffix must be a valid identifier\n\n    See http://goo.gl/MqrFmX\n");for(var a=s.inheritedDataKeys(e),l=0;l<a.length;++l){var h=e[a[l]];"constructor"!==a[l]&&s.isClass(h)&&(x(h.prototype,n,o,r,i),x(h,n,o,r,i))}return x(e,n,o,r,i)}}},{"./errors":12,"./nodeback":20,"./util":36}],25:[function(e,t,i){"use strict";t.exports=function(t,i,n,s){var o,r=e("./util"),a=r.isObject,l=e("./es5");"function"==typeof Map&&(o=Map);var c=function(){var e=0,t=0;function i(i,n){this[e]=i,this[e+t]=n,e++}return function(n){t=n.size,e=0;var s=new Array(2*n.size);
1return n.forEach(i,s),s}}(),u=function(e){for(var t=new o,i=e.length/2|0,n=0;n<i;++n){var s=e[i+n],r=e[n];t.set(s,r)}return t};function h(e){var t,i=!1;if(void 0!==o&&e instanceof o)t=c(e),i=!0;else{var n=l.keys(e),s=n.length;t=new Array(2*s);for(var r=0;r<s;++r){var a=n[r];t[r]=e[a],t[r+s]=a}}this.constructor$(t),this._isMap=i,this._init$(void 0,i?-6:-3)}function d(e){var i,o=n(e);return a(o)?(i=o instanceof t?o._then(t.props,void 0,void 0,void 0,void 0):new h(o).promise(),o instanceof t&&i._propagateFrom(o,2),i):s("cannot await properties of a non-object\n\n    See http://goo.gl/MqrFmX\n")}r.inherits(h,i),h.prototype._init=function(){},h.prototype._promiseFulfilled=function(e,t){if(this._values[t]=e,++this._totalResolved>=this._length){var i;if(this._isMap)i=u(this._values);else{i={};for(var n=this.length(),s=0,o=this.length();s<o;++s)i[this._values[s+n]]=this._values[s]}return this._resolve(i),!0}return!1},h.prototype.shouldCopyValues=function(){return!1},h.prototype.getActualLength=function(e){return e>>1},t.prototype.props=function(){return d(this)},t.props=function(e){return d(e)}}},{"./es5":13,"./util":36}],26:[function(e,t,i){"use strict";function n(e,t,i,n,s){for(var o=0;o<s;++o)i[o+n]=e[o+t],e[o+t]=void 0}function s(e){this._capacity=e,this._length=0,this._front=0}s.prototype._willBeOverCapacity=function(e){return this._capacity<e},s.prototype._pushOne=function(e){var t=this.length();this._checkCapacity(t+1),this[this._front+t&this._capacity-1]=e,this._length=t+1},s.prototype.push=function(e,t,i){var n=this.length()+3;if(this._willBeOverCapacity(n))return this._pushOne(e),this._pushOne(t),void this._pushOne(i);var s=this._front+n-3;this._checkCapacity(n);var o=this._capacity-1;this[s+0&o]=e,this[s+1&o]=t,this[s+2&o]=i,this._length=n},s.prototype.shift=function(){var e=this._front,t=this[e];return this[e]=void 0,this._front=e+1&this._capacity-1,this._length--,t},s.prototype.length=function(){return this._length},s.prototype._checkCapacity=function(e){this._capacity<e&&this._resizeTo(this._capacity<<1)},s.prototype._resizeTo=function(e){var t=this._capacity;this._capacity=e,n(this,0,this,t,this._front+this._length&t-1)},t.exports=s},{}],27:[function(e,t,i){"use strict";t.exports=function(t,i,n,s){var o=e("./util"),r=function(e){return e.then(function(t){return a(t,e)})};function a(e,a){var l=n(e);if(l instanceof t)return r(l);if(null===(e=o.asArray(e)))return s("expecting an array or an iterable object but got "+o.classString(e));var c=new t(i);void 0!==a&&c._propagateFrom(a,3);for(var u=c._fulfill,h=c._reject,d=0,p=e.length;d<p;++d){var g=e[d];(void 0!==g||d in e)&&t.cast(g)._then(u,h,void 0,c,null)}return c}t.race=function(e){return a(e,void 0)},t.prototype.race=function(){return a(this,void 0)}}},{"./util":36}],28:[function(e,t,i){"use strict";t.exports=function(t,i,n,s,o,r){var a=e("./util"),l=a.tryCatch;function c(e,i,n,s){this.constructor$(e);var r=t._getContext();this._fn=a.contextBind(r,i),void 0!==n&&(n=t.resolve(n))._attachCancellationCallback(this),this._initialValue=n,this._currentCancellable=null,this._eachValues=s===o?Array(this._length):0===s?null:void 0,this._promise._captureStackTrace(),this._init$(void 0,-5)}function u(e,t){this.isFulfilled()?t._resolve(e):t._reject(e)}function h(e,t,i,s){return"function"!=typeof t?n("expecting a function but got "+a.classString(t)):new c(e,t,i,s).promise()}function d(e){this.accum=e,this.array._gotAccum(e);var i=s(this.value,this.array._promise);return i instanceof t?(this.array._currentCancellable=i,i._then(p,void 0,void 0,this,void 0)):p.call(this,i)}function p(e){var i,n=this.array,s=n._promise,o=l(n._fn);s._pushContext(),(i=void 0!==n._eachValues?o.call(s._boundValue(),e,this.index,this.length):o.call(s._boundValue(),this.accum,e,this.index,this.length))instanceof t&&(n._currentCancellable=i);var a=s._popContext();return r.checkForgottenReturns(i,a,void 0!==n._eachValues?"Promise.each":"Promise.reduce",s),i}a.inherits(c,i),c.prototype._gotAccum=function(e){void 0!==this._eachValues&&null!==this._eachValues&&e!==o&&this._eachValues.push(e)},c.prototype._eachComplete=function(e){return null!==this._eachValues&&this._eachValues.push(e),this._eachValues},c.prototype._init=function(){},c.prototype._resolveEmptyArray=function(){this._resolve(void 0!==this._eachValues?this._eachValues:this._initialValue)},c.prototype.shouldCopyValues=function(){return!1},c.prototype._resolve=function(e){this._promise._resolveCallback(e),this._values=null},c.prototype._resultCancelled=function(e){if(e===this._initialValue)return this._cancel();this._isResolved()||(this._resultCancelled$(),this._currentCancellable instanceof t&&this._currentCancellable.cancel(),this._initialValue instanceof t&&this._initialValue.cancel())},c.prototype._iterate=function(e){var i,n;this._values=e;var s=e.length;void 0!==this._initialValue?(i=this._initialValue,n=0):(i=t.resolve(e[0]),n=1),this._currentCancellable=i;for(var o=n;o<s;++o){var r=e[o];r instanceof t&&r.suppressUnhandledRejections()}if(!i.isRejected())for(;n<s;++n){var a={accum:null,value:e[n],index:n,length:s,array:this};i=i._then(d,void 0,void 0,a,void 0),127&n||i._setNoAsyncGuarantee()}void 0!==this._eachValues&&(i=i._then(this._eachComplete,void 0,void 0,this,void 0)),i._then(u,u,void 0,i,this)},t.prototype.reduce=function(e,t){return h(this,e,t,null)},t.reduce=function(e,t,i,n){return h(e,t,i,n)}}},{"./util":36}],29:[function(e,t,n){"use strict";var s,o=e("./util"),r=function(){throw new Error("No async scheduler available\n\n    See http://goo.gl/MqrFmX\n")},a=o.getNativePromise();if(o.isNode&&"undefined"==typeof MutationObserver){var l=i.g.setImmediate,c=process.nextTick;s=o.isRecentNode?function(e){l.call(i.g,e)}:function(e){c.call(process,e)}}else if("function"==typeof a&&"function"==typeof a.resolve){var u=a.resolve();s=function(e){u.then(e)}}else s="undefined"==typeof MutationObserver||"undefined"!=typeof window&&window.navigator&&(window.navigator.standalone||window.cordova)||!("classList"in document.documentElement)?"undefined"!=typeof setImmediate?function(e){setImmediate(e)}:"undefined"!=typeof setTimeout?function(e){setTimeout(e,0)}:r:function(){var e=document.createElement("div"),t={attributes:!0},i=!1,n=document.createElement("div");new MutationObserver(function(){e.classList.toggle("foo"),i=!1}).observe(n,t);var s=function(){i||(i=!0,n.classList.toggle("foo"))};return function(i){var n=new MutationObserver(function(){n.disconnect(),i()});n.observe(e,t),s()}}();t.exports=s},{"./util":36}],30:[function(e,t,i){"use strict";
1t.exports=function(t,i,n){var s=t.PromiseInspection;function o(e){this.constructor$(e)}e("./util").inherits(o,i),o.prototype._promiseResolved=function(e,t){return this._values[e]=t,++this._totalResolved>=this._length&&(this._resolve(this._values),!0)},o.prototype._promiseFulfilled=function(e,t){var i=new s;return i._bitField=33554432,i._settledValueField=e,this._promiseResolved(t,i)},o.prototype._promiseRejected=function(e,t){var i=new s;return i._bitField=16777216,i._settledValueField=e,this._promiseResolved(t,i)},t.settle=function(e){return n.deprecated(".settle()",".reflect()"),new o(e).promise()},t.allSettled=function(e){return new o(e).promise()},t.prototype.settle=function(){return t.settle(this)}}},{"./util":36}],31:[function(e,t,i){"use strict";t.exports=function(t,i,n){var s=e("./util"),o=e("./errors").RangeError,r=e("./errors").AggregateError,a=s.isArray,l={};function c(e){this.constructor$(e),this._howMany=0,this._unwrap=!1,this._initialized=!1}function u(e,t){if((0|t)!==t||t<0)return n("expecting a positive integer\n\n    See http://goo.gl/MqrFmX\n");var i=new c(e),s=i.promise();return i.setHowMany(t),i.init(),s}s.inherits(c,i),c.prototype._init=function(){if(this._initialized)if(0!==this._howMany){this._init$(void 0,-5);var e=a(this._values);!this._isResolved()&&e&&this._howMany>this._canPossiblyFulfill()&&this._reject(this._getRangeError(this.length()))}else this._resolve([])},c.prototype.init=function(){this._initialized=!0,this._init()},c.prototype.setUnwrap=function(){this._unwrap=!0},c.prototype.howMany=function(){return this._howMany},c.prototype.setHowMany=function(e){this._howMany=e},c.prototype._promiseFulfilled=function(e){return this._addFulfilled(e),this._fulfilled()===this.howMany()&&(this._values.length=this.howMany(),1===this.howMany()&&this._unwrap?this._resolve(this._values[0]):this._resolve(this._values),!0)}
1,c.prototype._promiseRejected=function(e){return this._addRejected(e),this._checkOutcome()},c.prototype._promiseCancelled=function(){return this._values instanceof t||null==this._values?this._cancel():(this._addRejected(l),this._checkOutcome())},c.prototype._checkOutcome=function(){if(this.howMany()>this._canPossiblyFulfill()){for(var e=new r,t=this.length();t<this._values.length;++t)this._values[t]!==l&&e.push(this._values[t]);return e.length>0?this._reject(e):this._cancel(),!0}return!1},c.prototype._fulfilled=function(){return this._totalResolved},c.prototype._rejected=function(){return this._values.length-this.length()},c.prototype._addRejected=function(e){this._values.push(e)},c.prototype._addFulfilled=function(e){this._values[this._totalResolved++]=e},c.prototype._canPossiblyFulfill=function(){return this.length()-this._rejected()},c.prototype._getRangeError=function(e){var t="Input array must contain at least "+this._howMany+" items but contains only "+e+" items";return new o(t)},c.prototype._resolveEmptyArray=function(){this._reject(this._getRangeError(0))},t.some=function(e,t){return u(e,t)},t.prototype.some=function(e){return u(this,e)},t._SomePromiseArray=c}},{"./errors":12,"./util":36}],32:[function(e,t,i){"use strict";t.exports=function(e){function t(e){void 0!==e?(e=e._target(),this._bitField=e._bitField,this._settledValueField=e._isFateSealed()?e._settledValue():void 0):(this._bitField=0,this._settledValueField=void 0)}t.prototype._settledValue=function(){return this._settledValueField};var i=t.prototype.value=function(){if(!this.isFulfilled())throw new TypeError("cannot get fulfillment value of a non-fulfilled promise\n\n    See http://goo.gl/MqrFmX\n");return this._settledValue()},n=t.prototype.error=t.prototype.reason=function(){if(!this.isRejected())throw new TypeError("cannot get rejection reason of a non-rejected promise\n\n    See http://goo.gl/MqrFmX\n");return this._settledValue()},s=t.prototype.isFulfilled=function(){return!!(33554432&this._bitField)},o=t.prototype.isRejected=function(){return!!(16777216&this._bitField)},r=t.prototype.isPending=function(){return!(50397184&this._bitField)},a=t.prototype.isResolved=function(){return!!(50331648&this._bitField)};t.prototype.isCancelled=function(){return!!(8454144&this._bitField)},e.prototype.__isCancelled=function(){return!(65536&~this._bitField)},e.prototype._isCancelled=function(){return this._target().__isCancelled()},e.prototype.isCancelled=function(){return!!(8454144&this._target()._bitField)},e.prototype.isPending=function(){return r.call(this._target())},e.prototype.isRejected=function(){return o.call(this._target())},e.prototype.isFulfilled=function(){return s.call(this._target())},e.prototype.isResolved=function(){return a.call(this._target())},e.prototype.value=function(){return i.call(this._target())},e.prototype.reason=function(){var e=this._target();return e._unsetRejectionIsUnhandled(),n.call(e)},e.prototype._value=function(){return this._settledValue()},e.prototype._reason=function(){return this._unsetRejectionIsUnhandled(),this._settledValue()},e.PromiseInspection=t}},{}],33:[function(e,t,i){"use strict";t.exports=function(t,i){var n=e("./util"),s=n.errorObj,o=n.isObject;function r(e,n){if(o(e)){if(e instanceof t)return e;var r=l(e);if(r===s){n&&n._pushContext();var a=t.reject(r.e);return n&&n._popContext(),a}if("function"==typeof r)return u(e)?(a=new t(i),e._then(a._fulfill,a._reject,void 0,a,null),a):h(e,r,n)}return e}function a(e){return e.then}function l(e){try{return a(e)}catch(e){return s.e=e,s}}var c={}.hasOwnProperty;function u(e){try{return c.call(e,"_promise0")}catch(e){return!1}}function h(e,o,r){var a=new t(i),l=a;r&&r._pushContext(),a._captureStackTrace(),r&&r._popContext();var c=!0,u=n.tryCatch(o).call(e,h,d);function h(e){a&&(a._resolveCallback(e),a=null)}function d(e){a&&(a._rejectCallback(e,c,!0),a=null)}return c=!1,a&&u===s&&(a._rejectCallback(u.e,!0,!0),a=null),l}return r}},{"./util":36}],34:[function(e,t,i){"use strict";t.exports=function(t,i,n){var s=e("./util"),o=t.TimeoutError;function r(e){this.handle=e}r.prototype._resultCancelled=function(){clearTimeout(this.handle)};var a=function(e){return l(+this).thenReturn(e)},l=t.delay=function(e,s){var o,l;return void 0!==s?(o=t.resolve(s)._then(a,null,null,e,void 0),n.cancellation()&&s instanceof t&&o._setOnCancel(s)):(o=new t(i),l=setTimeout(function(){o._fulfill()},+e),n.cancellation()&&o._setOnCancel(new r(l)),o._captureStackTrace()),o._setAsyncGuaranteed(),o};t.prototype.delay=function(e){return l(e,this)};var c=function(e,t,i){var n;n="string"!=typeof t?t instanceof Error?t:new o("operation timed out"):new o(t),s.markAsOriginatingFromRejection(n),e._attachExtraTrace(n),e._reject(n),null!=i&&i.cancel()};function u(e){return clearTimeout(this.handle),e}function h(e){throw clearTimeout(this.handle),e}t.prototype.timeout=function(e,t){var i,s;e=+e;var o=new r(setTimeout(function(){i.isPending()&&c(i,t,s)},e));return n.cancellation()?(s=this.then(),(i=s._then(u,h,void 0,o,void 0))._setOnCancel(o)):i=this._then(u,h,void 0,o,void 0),i}}},{"./util":36}],35:[function(e,t,i){"use strict";
1t.exports=function(t,i,n,s,o,r){var a=e("./util"),l=e("./errors").TypeError,c=e("./util").inherits,u=a.errorObj,h=a.tryCatch,d={};function p(e){setTimeout(function(){throw e},0)}function g(e){var t=n(e);return t!==e&&"function"==typeof e._isDisposable&&"function"==typeof e._getDisposer&&e._isDisposable()&&t._setDisposable(e._getDisposer()),t}function f(e,i){var s=0,r=e.length,a=new t(o);function l(){if(s>=r)return a._fulfill();var o=g(e[s++]);if(o instanceof t&&o._isDisposable()){try{o=n(o._getDisposer().tryDispose(i),e.promise)}catch(e){return p(e)}if(o instanceof t)return o._then(l,p,null,null,null)}l()}return l(),a}function m(e,t,i){this._data=e,this._promise=t,this._context=i}function _(e,t,i){this.constructor$(e,t,i)}function v(e){return m.isDisposer(e)?(this.resources[this.index]._setDisposable(e),e.promise()):e}function b(e){this.length=e,this.promise=null,this[e-1]=null}m.prototype.data=function(){return this._data},m.prototype.promise=function(){return this._promise},m.prototype.resource=function(){return this.promise().isFulfilled()?this.promise().value():d},m.prototype.tryDispose=function(e){var t=this.resource(),i=this._context;void 0!==i&&i._pushContext();var n=t!==d?this.doDispose(t,e):null;return void 0!==i&&i._popContext(),this._promise._unsetDisposable(),this._data=null,n},m.isDisposer=function(e){return null!=e&&"function"==typeof e.resource&&"function"==typeof e.tryDispose},c(_,m),_.prototype.doDispose=function(e,t){return this.data().call(e,e,t)},b.prototype._resultCancelled=function(){for(var e=this.length,i=0;i<e;++i){var n=this[i];n instanceof t&&n.cancel()}},t.using=function(){var e=arguments.length;if(e<2)return i("you must pass at least 2 arguments to Promise.using");var s,o=arguments[e-1];if("function"!=typeof o)return i("expecting a function but got "+a.classString(o));var l=!0;2===e&&Array.isArray(arguments[0])?(e=(s=arguments[0]).length,l=!1):(s=arguments,e--);for(var c=new b(e),d=0;d<e;++d){var p=s[d];if(m.isDisposer(p)){var g=p;(p=p.promise())._setDisposable(g)}else{var _=n(p);_ instanceof t&&(p=_._then(v,null,null,{resources:c,index:d},void 0))}c[d]=p}var y=new Array(c.length);for(d=0;d<y.length;++d)y[d]=t.resolve(c[d]).reflect();var w=t.all(y).then(function(e){for(var t=0;t<e.length;++t){var i=e[t];if(i.isRejected())return u.e=i.error(),u;if(!i.isFulfilled())return void w.cancel();e[t]=i.value()}C._pushContext(),o=h(o);var n=l?o.apply(void 0,e):o(e),s=C._popContext();return r.checkForgottenReturns(n,s,"Promise.using",C),n}),C=w.lastly(function(){var e=new t.PromiseInspection(w);return f(c,e)});return c.promise=C,C._setOnCancel(c),C},t.prototype._setDisposable=function(e){this._bitField=131072|this._bitField,this._disposer=e},t.prototype._isDisposable=function(){return(131072&this._bitField)>0},t.prototype._getDisposer=function(){return this._disposer},t.prototype._unsetDisposable=function(){this._bitField=-131073&this._bitField,this._disposer=void 0},t.prototype.disposer=function(e){if("function"==typeof e)return new _(e,this,s());throw new l}}},{"./errors":12,"./util":36}],36:[function(e,t,n){"use strict";var s,o=e("./es5"),r="undefined"==typeof navigator,a={e:{}},l="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==i.g?i.g:void 0!==this?this:null;function c(){try{var e=s;return s=null,e.apply(this,arguments)}catch(e){return a.e=e,a}}function u(e){return s=e,c}var h=function(e,t){var i={}.hasOwnProperty;function n(){for(var n in this.constructor=e,this.constructor$=t,t.prototype)i.call(t.prototype,n)&&"$"!==n.charAt(n.length-1)&&(this[n+"$"]=t.prototype[n])}return n.prototype=t.prototype,e.prototype=new n,e.prototype};function d(e){return null==e||!0===e||!1===e||"string"==typeof e||"number"==typeof e}function p(e){return"function"==typeof e||"object"==typeof e&&null!==e}function g(e){return d(e)?new Error(T(e)):e}function f(e,t){var i,n=e.length,s=new Array(n+1);for(i=0;i<n;++i)s[i]=e[i];return s[i]=t,s}function m(e,t,i){if(!o.isES5)return{}.hasOwnProperty.call(e,t)?e[t]:void 0;var n=Object.getOwnPropertyDescriptor(e,t);return null!=n?null==n.get&&null==n.set?n.value:i:void 0}function _(e,t,i){if(d(e))return e;var n={value:i,configurable:!0,enumerable:!1,writable:!0};return o.defineProperty(e,t,n),e}function v(e){throw e}var b=function(){var e=[Array.prototype,Object.prototype,Function.prototype],t=function(t){for(var i=0;i<e.length;++i)if(e[i]===t)return!0;return!1};if(o.isES5){var i=Object.getOwnPropertyNames;return function(e){for(var n=[],s=Object.create(null);null!=e&&!t(e);){var r;try{r=i(e)}catch(e){return n}for(var a=0;a<r.length;++a){var l=r[a];if(!s[l]){s[l]=!0;var c=Object.getOwnPropertyDescriptor(e,l);null!=c&&null==c.get&&null==c.set&&n.push(l)}}e=o.getPrototypeOf(e)}return n}}var n={}.hasOwnProperty;return function(i){if(t(i))return[];var s=[];e:for(var o in i)if(n.call(i,o))s.push(o);else{for(var r=0;r<e.length;++r)if(n.call(e[r],o))continue e;s.push(o)}return s}}(),y=/this\s*\.\s*\S+\s*=/;function w(e){try{if("function"==typeof e){var t=o.names(e.prototype),i=o.isES5&&t.length>1,n=t.length>0&&!(1===t.length&&"constructor"===t[0]),s=y.test(e+"")&&o.names(e).length>0;if(i||n||s)return!0}return!1}catch(e){return!1}}function C(e){function t(){}t.prototype=e;var i=new t;function n(){return typeof i.foo}return n(),n(),e}var x=/^[a-z$_][a-z$_0-9]*$/i;function k(e){return x.test(e)}function S(e,t,i){for(var n=new Array(e),s=0;s<e;++s)n[s]=t+s+i;return n}function T(e){try{return e+""}
1catch(e){return"[no string representation]"}}function E(e){return e instanceof Error||null!==e&&"object"==typeof e&&"string"==typeof e.message&&"string"==typeof e.name}function P(e){try{_(e,"isOperational",!0)}catch(e){}}function I(e){return null!=e&&(e instanceof Error.__BluebirdErrorTypes__.OperationalError||!0===e.isOperational)}function F(e){return E(e)&&o.propertyIsWritable(e,"stack")}var A="stack"in new Error?function(e){return F(e)?e:new Error(T(e))}:function(e){if(F(e))return e;try{throw new Error(T(e))}catch(e){return e}};function M(e){return{}.toString.call(e)}function j(e,t,i){for(var n=o.names(e),s=0;s<n.length;++s){var r=n[s];if(i(r))try{o.defineProperty(t,r,o.getDescriptor(e,r))}catch(e){}}}var R=function(e){return o.isArray(e)?e:null};if("undefined"!=typeof Symbol&&Symbol.iterator){var D="function"==typeof Array.from?function(e){return Array.from(e)}:function(e){for(var t,i=[],n=e[Symbol.iterator]();!(t=n.next()).done;)i.push(t.value);return i};R=function(e){return o.isArray(e)?e:null!=e&&"function"==typeof e[Symbol.iterator]?D(e):null}}var $,N="undefined"!=typeof process&&"[object process]"===M(process).toLowerCase(),O="undefined"!=typeof process&&void 0!==process.env;function L(e){return O?process.env[e]:void 0}function B(){if("function"==typeof Promise)try{if("[object Promise]"===M(new Promise(function(){})))return Promise}catch(e){}}function V(e,t){if(null===e||"function"!=typeof t||t===$)return t;null!==e.domain&&(t=e.domain.bind(t));var i=e.async;if(null!==i){var n=t;t=function(){var e=new Array(2).concat([].slice.call(arguments));return e[0]=n,e[1]=this,i.runInAsyncScope.apply(i,e)}}return t}var U,z={setReflectHandler:function(e){$=e},isClass:w,isIdentifier:k,inheritedDataKeys:b,getDataPropertyOrDefault:m,thrower:v,isArray:o.isArray,asArray:R,notEnumerableProp:_,isPrimitive:d,isObject:p,isError:E,canEvaluate:r,errorObj:a,tryCatch:u,inherits:h,withAppended:f,maybeWrapAsError:g,toFastProperties:C,filledRange:S,toString:T,canAttachTrace:F,ensureErrorObject:A,originatesFromRejection:I,markAsOriginatingFromRejection:P,classString:M,copyDescriptors:j,isNode:N,hasEnvVariables:O,env:L,global:l,getNativePromise:B,contextBind:V};z.isRecentNode=z.isNode&&(process.versions&&process.versions.node?U=process.versions.node.split(".").map(Number):process.version&&(U=process.version.split(".").map(Number)),0===U[0]&&U[1]>10||U[0]>0),z.nodeSupportsAsyncResource=z.isNode&&function(){var t=!1;try{t="function"==typeof e("async_hooks").AsyncResource.prototype.runInAsyncScope}catch(e){t=!1}return t}(),z.isNode&&z.toFastProperties(process);try{throw new Error}catch(e){z.lastLineError=e}t.exports=z},{"./es5":13,async_hooks:void 0}]},{},[4])(4),"undefined"!=typeof window&&null!==window?window.P=window.Promise:"undefined"!=typeof self&&null!==self&&(self.P=self.Promise)},12118(e,t,i){"use strict";var n=i(55679),s=i(17604).sprintf;var o={open:function(e){var t=function(e){return n(e).omit(n.isUndefined).reduce(function(e,t,i){return(e?e+" ":"")+s('%s="%s"',n.escape(i),n.escape(t))},"")}({"data-js-tumblelog-name":e.blog_name,"data-js-post-id":e.post_id,"data-js-messaging-tumblelog-name":e.messaging_blog_name,target:"_blank",href:e.url});return"<a "+t+">"},close:function(e){return"</a>"}};e.exports=o},12461(e){var t={saveSelection:function(e,t){if(!(t=t||window.getSelection())||!t.rangeCount)return null;for(var i,n,s=t.getRangeAt(0),o=0,r=[e];!n&&(i=r.pop());)if(i.nodeType===i.TEXT_NODE)i===s.startContainer?(o+=s.startOffset,n=!0):o+=i.length;else{var a=i.childNodes.length;if("false"!==i.getAttribute("contenteditable"))for(;a--;)r.push(i.childNodes[a])}return{container:e,endContainer:s.endContainer,start:o,end:o+s.toString().length,selection:t,anchorNode:t.anchorNode}},restoreSelection:function(e){if(e){var t=0,i=document.createRange();i.setStart(e.container,0),i.collapse(!0);for(var n,s=[e.container],o=!1,r=!1;!r&&(n=s.pop());)if(n.nodeType===n.TEXT_NODE){var a=t+n.length;!o&&e.start>=t&&e.start<a&&(i.setStart(n,e.start-t),o=!0),o||a!==e.end||(i.setStart(n,e.end-t),o=!0),o&&e.end>=t&&e.end<=a&&(i.setEnd(n,e.end-t),r=!0),t=a}else{var l=n.childNodes.length;if("false"!==n.getAttribute("contenteditable"))for(;l--;)s.push(n.childNodes[l])}if(!r){var c=e.end-t;try{i.setEnd(e.endContainer,c)}catch(e){}}var u=window.getSelection();u.removeAllRanges();try{u.addRange(i)}catch(e){}}},setToStart:function(e){if(e){var t=document.createRange();t.setStart(e,0),t.setEnd(e,0),t.collapse(!0);var i=window.getSelection();i.removeAllRanges();try{i.addRange(t)}
1catch(e){}}},setToEnd:function(e){for(var t=[e],i=null,n=e,s=0;i=t.pop();)if(3===i.nodeType)n=i,s=i.length;else for(var o=i.childNodes.length;o--;)t.push(i.childNodes[o]);var r=document.createRange();r.setStart(n,s),r.setEnd(n,s),r.collapse(!0);var a=window.getSelection();a.removeAllRanges();try{a.addRange(r)}catch(e){}}};e.exports=t},12484(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<button class=\"ui_button btn_' +\n((__t = ( btn_id )) == null ? '' : __t) +\n' chrome ' +\n((__t = ( btn_class )) == null ? '' : __t) +\n'\" data-btn-id=\"' +\n((__t = ( btn_id )) == null ? '' : __t) +\n'\"><span>' +\n((__t = ( text )) == null ? '' : __t) +\n'</span></button>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},12509(e){e.exports={debugMode:!1}},12720(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(71092),r=i(27496),a=i(80270),l=o.extend({captureIsReady:!1,impressionLogQueue:[],initialize:function(e){this.options=s.defaults(e,this.defaults),this.subviews=[],this.viewed=[],this.pageUrl=this.options.pageUrl,this.bindEvents()},bindEvents:function(){this.listenTo(this.collection,"add",this.onTumblelogAdded),this.listenTo(this.collection,"remove",this.onTumblelogRemoved),this.listenTo(this.collection,"dismiss",this.onDismiss),this.listenTo(this.collection,"reset",this.onTumblelogsReset),this.listenTo(this.collection,"change:following",this.onFollow),this.listenTo(r,"TumblelogPopover:show",this.onPopoverShow),this.listenTo(r,"TumblelogPopover:hide",this.onPopoverHide),this.listenToOnce(r,"capture:init",this.flushQueue)},onTumblelogAdded:function(e){var t=!s.isUndefined(e.get("pt"))&&e.get("pt"),i=!!e.get("premium"),n=new a({model:e,dismissable:this.options.dismissable&&!i,primaTumblelogPopover:this.options.primaTumblelogPopover,pageUrl:this.pageUrl,pt:t,sponsored:i,wordedFollowButton:this.options.wordedFollowButton});this.subviews.push(n),this.$el.append(n.render().el),"explore"!==this.pageUrl&&this.logImpression()},onTumblelogRemoved:function(e,t,i){this.subviews=s.filter(this.subviews,function(t){return t.model!==e})},onTumblelogsReset:function(){s.each(this.subviews,function(e){e.remove()}),this.subviews=[],this.render()},onFollow:function(e,t){if(t&&this.options.refresh&&this.collection.length>this.options.numShow){var i=this.getView(e);this.popoverShown?this.queuedView=i:(this.collection.remove(e),this.slideUp(i))}},onDismiss:function(e){if(this.options.refresh){var t=this.getView(e);this.slideLeft(t),this.collection.remove(e)}"explore"!==this.pageUrl&&n.ajax({method:"POST",url:"/svc/search/log_dismissal",data:{tumblelog_name:e.get("name"),page:this.pageUrl},withFormKey:!0})},onPopoverShow:function(){this.popoverShown=!0},onPopoverHide:function(){this.popoverShown=!1,this.queuedView&&this.options.refresh&&(this.slideUp(this.queuedView),this.collection.remove(this.queuedView.model),this.queuedView=null)},logImpression:function(){s.forEach(this.collection.slice(0,this.options.numShow),function(e,t){var i=this.getView(e);if(s.isEmpty(i)||-1!==s.indexOf(this.viewed,e))return this;this.viewed.push(e),this.triggerEvent("impression",this.prepLoggingData(!1,e,i)),this.impressionLogQueue.push(s.bind(function(){r.trigger("Capture:push","recommended_blog_impressions","impressions",this.prepLoggingData(!0,e,i))},this))},this),this.captureIsReady&&this.flushQueue()},prepLoggingData:function(e,t,i){var n={tumblelog_name:t.get("name"),algorithm_id:t.get("algorithm_id")||"",format:"RECOMMEND_FORMAT_DASH_SIDEBAR"};return e&&(n=s.extend(n,{page:this.pageUrl,ts:Math.floor(s.now()/1e3)})),n},triggerEvent:function(e,t){r.trigger("recommendedBlogs:"+e,{loggingData:t})},flushQueue:function(){for(var e=0;e<this.impressionLogQueue.length;e++)this.impressionLogQueue[e]();this.impressionLogQueue=[],this.captureIsReady=!0},getView:function(e){return s.find(this.subviews,{model:e})},render:function(){return this.collection.each(s.bind(this.onTumblelogAdded,this)),this},slideLeft:function(e){e.$el.animate({left:-1*e.$el.width()},250).slideUp(300,e.$el.remove)},slideUp:function(e){e.$el.animate({opacity:0}
1,100).slideUp(300,e.$el.remove)}});e.exports=l},13024(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(87722),r=s.extend({className:"loader-bar",template:o,defaults:{classModifiers:"",loading:!1},initialize:function(e){this.options=n.extend({},this.defaults,e),this.$el.addClass(this.get("classModifiers")),this.interval=null,this.timeout=null},afterRender:function(){this.$bars=this.$el.find(".bar"),!0===this.get("loading")&&this.toggleLoading(this.get("loading"))},toggleLoading:function(e){this.currentBar=0,this.counter=0,!0===e?(clearTimeout(this.timeout),this.$el.addClass("loading"),this.$bars.addClass("animating"),this.startAnimating()):(this.$el.removeClass("loading"),this.stopAnimating(),this.timeout=setTimeout(n.bind(function(){this.$bars.removeClass("animating")},this),300))},showBar:function(e){this.$bars.eq(e).addClass("active")},hideBar:function(e){this.$bars.eq(e).removeClass("active")},loop:function(){var e=this.$bars.eq(this.currentBar);e.remove(),this.$el.append(e),this.currentBar+=1,this.currentBar>=this.$bars.length&&(this.currentBar=0),this.counter++},startAnimating:function(){this.stopAnimating(),this.loop(),this.interval=setInterval(n.bind(function(){this.loop()},this),300)},stopAnimating:function(){clearInterval(this.interval)},beforeRemove:function(){clearInterval(this.interval),clearTimeout(this.timeout)}});e.exports=r},13482(e,t,i){"use strict";var n=i(28724),s=i(44890),o=new n({isLoggedIn:function(){return s.bool("is_logged_in")},redirect:function(e){return function(t){t.preventDefault(),window.location.href=e}},redirectLink:function(e){return e||(e="/register"),function(t){var i=t.currentTarget.attributes.href,n=e+"?redirect_to=";n+=i?encodeURIComponent(i.value):encodeURIComponent(window.location.href),t.preventDefault(),window.location.href=n}}});e.exports=o},13701(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<figure data-js-select style=\"width: ' +\n__e( width ) +\n'px; height: ' +\n__e( height ) +\n'px;\"><img data-js-img data-img-src=\"' +\n__e( mediaUrl ) +\n'\" width=\"' +\n__e( width ) +\n'\" height=\"' +\n__e( height ) +\n'\"></figure><footer><nav class=\"tags\"> ';\n _.each(tags, function(tag) { ;\n__p += ' ';\n if (!_.isEmpty(tag)) { ;\n__p += ' <a href=\"#\" data-js-tag=\"' +\n__e( tag ) +\n'\">#' +\n__e( tag ) +\n'</a> ';\n } ;\n__p += ' ';\n }) ;\n__p += ' </nav><a class=\"attribution\" href=\"http://tmblr.co/' +\n__e( rootPostUrlHash ) +\n'\" target=\"_blank\">' +\n__e( __('Originally posted by %1$s', rootBlog) ) +\n'</a></footer>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},13714(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<div class="v-center-outer"><div class="v-center-inner"><div class="v-center-content"><div data-subview="content"></div></div></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},13752(e,t,i){"use strict";var n=new(i(28724))({before:{sync:function(e,t,i){i.withFormKey=!0}}});e.exports=n},13760(e,t,i){"use strict";var n=i(74692),s=i(91685),o=i(26024),r=s.extend(o,{filmstrip_thumbnail_count:10,render:function(){var e=this.player.options_.crtOptions.filmstrip,t=e.url,i=.5*e.width,s=.5*e.height;return this.$el=n('<div class="crt-progress-tooltip"></div>'),this.$thumbnail=n('<div class="crt-progress-tooltip-thumbnail"></div>'),this.$el.css({transform:"translateX(-50%)",width:i+6+"px",height:s+6+"px"}),this.$thumbnail.css({width:i+"px",height:s+"px","background-image":"url("+t+")","background-size":i*this.filmstrip_thumbnail_count+"px "+s+"px"}),this.$el.append(this.$thumbnail),this},update:function(e){e||(e={});var t=e.hoverX||0;this.$el.css("left",t+"px");var i=isNaN(e.hoverPercent)?0:100*e.hoverPercent,n=100/(this.filmstrip_thumbnail_count-1),s=Math.floor(i/this.filmstrip_thumbnail_count)*n;this.$thumbnail.css("background-position",s+"% 0%")}});e.exports=r},14169(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<span class=\"snowman-container\"><i data-subscription-indicator class=\"subscribe-activity ' +\n((__t = ( (canSubscribe && isSubscribed) ? 'is-subscribed' : '')) == null ? '' : __t) +\n'\"></i> <i class=\"snowman-icon\"></i></span>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},14653(e,t,i){"use strict";var n=i(55679),s=i(90263),o=i(80160).extend({defaults:{background_color:null,link_color:null,avatar_shape:null,header_image_focused:null,show_header_image:!0,adjustBrightnessFactor:.3},getHeaderImage:function(){return!0===this.get("show_header_image")?this.get("header_image_focused"):null}
1,getBackgroundTint:function(){return this.getTint(this.get("background_color"))},getAccentTint:function(){return this.getTint(this.get("link_color"))},getTint:function(e){var t;return this.get("tint"+e)?this.get("tint"+e):n.isEmpty(e)?null:(t=s.isLight(e,.5)?s.isLight(e,.05,.95)?o.TINT_WHITE:o.TINT_LIGHT:o.TINT_DARK,this.set("tint"+e,t),t)},isDark:function(e){return this.getTint(e)===o.TINT_DARK},isReadableOn:function(e,t){return e=s.hexToHsv(e),t=s.hexToHsv(t),!s.compare(e,t)},adjustColorForBackground:function(e,t){var i=this.get("adjustBrightnessFactor");return this.isReadableOn(e,t)?e:this.adjustBrightness(e,this.isDark(e)?i:-1*i)},getReadableColor:function(e,t){return this.isReadableOn(e,t)?e:s.readable(e)},adjustBrightness:function(e,t){return s.brighten(e,t)},getTintSuffix:function(e){return e===o.TINT_WHITE?"-white":e===o.TINT_LIGHT?"-light":e===o.TINT_DARK?"-dark":void 0}},{TINT_LIGHT:"light",TINT_DARK:"dark",TINT_WHITE:"white"});e.exports=o},14670(e,t,i){var n=i(81515);e.exports=function(e){return!(-1===e||e>14400)&&(e>=10800?n("Active in the last 4 hours"):e>=7200?n("Active in the last 3 hours"):e>=3600?n("Active in the last 2 hours"):e>=0&&n("Active in the last hour"))}},15437(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<button tabindex=\"-1\" data-js-theme-button data-js-unread-button class=\"unread-button\">' +\n__e( title ) +\n'</button>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},15539(e,t,i){"use strict";var n=i(55679),s=i(17604).sprintf,o=i(80160),r=o.extend({endpoint:"/svc/post/%s/%s/%s",parse:function(e){return{dashboardHTML:e.trim()}},sync:function(e,t,i){if("read"!==e)throw new Error("The DashboardPostFetch model may only READ from server!");if(!1===((i=n.defaults(i||{},{pageRoot:!1,direction:!1,refPostID:!1})).pageRoot&&i.direction))throw new Error(s("These two fetch params must be passed: pageRoot [%s], direction [%s]",i.pageRoot,i.direction));return n.defaults(i,{dataType:"html",emulateHTTP:!0,url:s(this.endpoint,i.pageRoot,i.direction,i.refPostID)}),o.prototype.sync.call(this,e,t,i)}});e.exports=r},15855(e,t,i){"use strict";var n=i(55679),s=i(91685);window.videojs=s;var o=i(21189),r=i(96589),a=i(98589),l=i(39153),c=i(27547);s.registerComponent("BigPlayToggle",i(80399)),s.registerComponent("AnimatingMuteToggle",i(48332)),s.registerComponent("CrtSeekBar",i(31078)),s.registerComponent("LoadingSpinner",i(47405)),s.registerComponent("HDToggle",i(81826)),s.registerComponent("CrtDurationDisplay",i(39644)),s.log=n.noop,s.log.error=n.noop,s.log.warn=n.noop,s.log.history=[];var u;s.plugin("crt",function(e){this.crt=this.options_.crt,this.options_.crt=null,this.hoverSlider=new a(this,e),this.detectBuffering=new l(this,e),this.eventDispatcher=new c(this,e)});e.exports=function(e,t){var i=n.merge({},(u||(u={children:["mediaLoader","posterImage","bigPlayToggle","loadingSpinner",{name:"controlBar",children:["playToggle","timeDivider","crtDurationDisplay",{name:"progressControl",children:["crtSeekBar"]},"fullscreenToggle","hDToggle","animatingMuteToggle"]},"errorDisplay"],hls:{withCredentials:!1},plugins:{crt:{}},crtOptions:{filmstrip:!1,hdUrl:!1,duration:null,livestream:!1},controls:!0,autoplay:!1,volume:.8,muted:!0,techOrder:["html5"]}),u),t);t.crtOptions.techOrder&&(i.techOrder=t.crtOptions.techOrder);var a=o.defer(),l=s(e,i,function(){var e;t.src&&t.type?(this.src(t),a.resolve(this)):t.file?(e=t.file.type||"video/mp4",this.src({src:r(t.file),type:e}),a.resolve(this),delete t.file):a.resolve(this)});return"function"==typeof l.skippy&&l.skippy(),a.promise}},15897(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<svg height="\' +\n((__t = ( height )) == null ? \'\' : __t) +\n\'px" viewBox="0 0 90 117" version="1.1" xmlns="http://www.w3.org/2000/svg"><g id="t"><path d="M84.887609,37.7063334 L73.3440965,37.7063334 L73.3440965,49.5487626 L54.5664049,49.5487626 L54.5664049,76.5907908 C54.6769956,83.4040424 58.567532,84.1940039 61.7672553,84.1940039 C63.1495547,84.1940039 64.6395831,83.9935162 66.1100857,83.6416636 L66.1100857,59.1040666 L84.887609,59.1040666 L84.887609,37.7063334 L84.887609,37.7063334 Z M82.9947746,91.1724414 C80.8511333,92.3497239 78.1277746,93.2454244 75.5348693,93.5916153 L77.4563192,99.2257528 C74.0089872,103.714413 65.4305506,106.805986 57.5792856,106.938202 C57.313161,106.942531 57.0514128,106.944863 56.7889914,106.944863 L56.7873082,106.944863 C51.3176985,106.944529 46.7681628,105.994211 43,104.403464 C47.4104977,111.071679 55.2442568,116.4995 68.3311573,116.5 L68.3326722,116.5 C68.5950936,116.5 68.8568418,116.498002 69.1231347,116.493672 C76.9742314,116.361457 85.5524997,113.269717 89,108.781057 L82.9947746,91.1724414 L82.9947746,91.1724414 Z M54.6429936,28.1510294 L66.1866744,28.1510294 L66.1866744,12.5 L54.6429936,12.5 L54.6429936,28.1510294 Z" id="Fill-1" fill-opacity="0.1" fill="#000000"></path><path d="M72.2676149,79.3896643 C72.2054093,79.2043758 72.0321341,79.0795111 71.8373453,79.0795111 L56.7965877,79.0795111 C56.5929601,79.0795111 56.4088448,78.9492903 56.3571457,78.7517832 C56.182036,78.0837739 56.0773037,77.2672995 56.0611269,76.2583394 L56.0611269,51.7631035 C56.0611269,51.5113656 56.264421,51.3073307 56.5152448,51.3073307 L74.2111661,51.3073307 C74.4619899,51.3073307 74.6652839,51.1032958 74.6652839,50.851
15579 L74.6652839,25.7924225 C74.6652839,25.5406846 74.4619899,25.3366497 74.2111661,25.3366497 L56.5911257,25.3366497 C56.3404686,25.3366497 56.1371746,25.1326148 56.1371746,24.8808769 L56.1371746,0.455772807 C56.1371746,0.204034907 55.9338805,0 55.6830567,0 L24.7823615,0 C22.5726436,0 20.0227125,1.64483267 19.6498122,4.69363975 C18.1070122,17.3021266 12.3455688,24.8661475 1.51845143,28.497768 L0.310361133,28.9024903 C0.125078372,28.9645878 0,29.1386619 0,29.33483 L0,50.8515579 C0,51.1032958 0.203294047,51.3073307 0.454117876,51.3073307 L11.5120466,51.3073307 L11.5120466,77.8084356 C11.5120466,77.8238345 11.5125469,77.8397354 11.5125469,77.8551343 C11.5128804,78.0178266 11.5142146,78.1816906 11.51755,78.3473957 C11.5187174,78.4113345 11.5213858,78.4766123 11.5232202,78.5408858 C11.5262221,78.65939 11.529224,78.7777269 11.5338936,78.8977376 C11.5368955,78.9747319 11.5413983,79.0530653 11.5450673,79.1305617 C11.5502372,79.239358 11.5549068,79.3476522 11.5614108,79.4576201 C11.566414,79.542816 11.5729181,79.6291835 11.578755,79.7150489 C11.5857594,79.8186565 11.5922635,79.9219292 11.6004353,80.0265411 C11.6074397,80.1172605 11.6161118,80.2091515 11.6241168,80.3005404 C11.6329557,80.4016372 11.6412942,80.5025667 11.6513005,80.6045005 C11.6604729,80.6997391 11.671313,80.795982 11.6816528,80.8918901 C11.6923262,80.9913132 11.7024992,81.0904015 11.7141732,81.1903267 C11.7258472,81.2892477 11.7388554,81.3888381 11.7513632,81.4884286 C11.763871,81.5868474 11.7760453,81.6850988 11.7895538,81.7840198 C11.8035626,81.8861209 11.8189055,81.9890589 11.8340817,82.0918296 C11.8482572,82.1892441 11.8624328,82.2864913 11.8777757,82.384408 C11.8941193,82.4890198 11.9117971,82.5941338 11.929308,82.6994151 C11.9456516,82.7968296 11.9618284,82.8942442 11.9790058,82.9921608 C11.9980177,83.099116 12.0180303,83.2064059 12.0382096,83.3138631 C12.0562209,83.4104408 12.0743989,83.5070184 12.0934109,83.6040982 C12.1152579,83.7145683 12.1381055,83.8252057 12.1612867,83.936178 C12.1809657,84.030747 12.2006447,84.1254835 12.2213243,84.2203874 C12.2460065,84.3335355 12.2716892,84.446851 12.2977055,84.5605013 C12.3193858,84.6547357 12.341066,84.74897 12.3635801,84.8433717 C12.3910974,84.9585284 12.4196152,85.0740199 12.4486334,85.1895113 C12.4718146,85.2820719 12.4953294,85.3747998 12.5195112,85.4675277 C12.5503638,85.586032 12.5820504,85.7047037 12.6145707,85.8235427 C12.6392529,85.9142621 12.6644353,86.0049814 12.6899513,86.0958682 C12.7241394,86.2167158 12.7591613,86.3375634 12.7948504,86.4587457 C12.8212002,86.548126 12.8482171,86.6375064 12.8754008,86.7270541 C12.9129243,86.850245 12.9514485,86.9736033 12.9906397,87.0971289 C13.0184905,87.1845007 13.0468416,87.2718725 13.0755262,87.3592443 C13.1168855,87.4851133 13.1589118,87.6111496 13.2019388,87.7370185 C13.2311237,87.8222144 13.2609758,87.9075777 13.2909946,87.9927735 C13.3361896,88.1213205 13.3820516,88.2497002 13.4290811,88.3784146 C13.4594334,88.4609324 13.4904529,88.5434502 13.5216391,88.625968 C13.5711701,88.7578626 13.6213682,88.8895898 13.6730673,89.0214844 C13.7037532,89.0998177 13.7352729,89.1781511 13.7667927,89.2566518 C13.8213269,89.3923961 13.8763613,89.5283078 13.9330635,89.6640521 C13.9642498,89.7385357 13.9964366,89.8130193 14.0282899,89.8875029 C14.0878272,90.0269296 14.1478648,90.1661888 14.2099037,90.3056155 C14.2409231,90.3752451 14.2729432,90.4448747 14.3046297,90.5145044 C14.370004,90.6586176 14.4358786,90.8027309 14.504088,90.9466768 C14.5341068,91.0102808 14.5654598,91.0737174 14.5959789,91.1373214 C14.6680241,91.2867907 14.7404027,91.4360927 14.815283,91.5852274 C14.8436341,91.641634 14.8731526,91.697706 14.9018372,91.7541127 C14.9815538,91.9102772 15.0617708,92.0664418 15.1448228,92.2221042 C15.1690046,92.267966 15.1945206,92.3133257 15.2192027,92.3590201 C15.3085921,92.5248926 15.3988153,92.6907651 15.4920404,92.8561355 C15.5097181,92.887268 15.5282297,92.9184005 15.5460742,92.949533 C15.6479714,93.1287958 15.7513695,93.3077238 15.8577695,93.4861498 L15.8742799,93.5132652 C16.9738022,95.3502488 18.3148091,97.1350103 19.9326561,98.8007653 L19.9521683,98.8213529 C20.1187727,98.9925816 20.2890461,99.1621364 20.4616542,99.3308544 C20.479332,99.3480944 20.4965094,99.3655018 20.5141872,99.3827419 C20.6797909,99.5437604 20.8490637,99.7032725 21.0201709,99.8617803 C21.0461872,99.8858829 21.0717032,99.9101528 21.0977195,99.9342554 C21.2643238,100.087407 21.4342637,100.238718 21.6058712,100.389359 C21.6383916,100.417813 21.6704116,100.44677 21.7030988,100.475057 C21.872038,100.622015 22.0444793,100.7673 22.2185884,100.911581 C22.2557784,100.942546 22.2924681,100.973679 22.3298248,101.004309 C22.502433,101.145911 22.678043,101.28584 22.8553207,101.424765 C22.89668,101.457236 22.9377057,101.489708 22.9792317,101.522012 C23.1555088,101.658593 23.3347878,101.7935 23.5159013,101.927404 C23.5612631,101.960712 23.6061245,101.994355 23.651653,102.027496 C23.8320994,102.15939
11 24.0153809,102.289612 24.2008305,102.418661 C24.2493609,102.452471 24.2978913,102.486449 24.346922,102.52026 C24.5323715,102.647802 24.7206562,102.773671 24.9109421,102.898536 C24.9619741,102.932012 25.013006,102.965488 25.0643716,102.998629 C25.2558249,103.122657 25.4501133,103.24501 25.6465697,103.366025 C25.6991026,103.39833 25.7516355,103.430466 25.8043352,103.462603 C26.0022926,103.582949 26.2025847,103.70162 26.4055452,103.818785 C26.4597459,103.850253 26.51428,103.881385 26.5688142,103.912518 C26.7736092,104.029181 26.980739,104.144337 27.1905371,104.25782 C27.2452381,104.287446 27.3004393,104.316905 27.3554738,104.346196 C27.5677735,104.459512 27.782408,104.571154 28.0000443,104.681122 C28.0550788,104.709074 28.1106136,104.736524 28.1659816,104.764142 C28.3867867,104.87411 28.6097597,104.982738 28.8357346,105.089024 C28.8897685,105.114466 28.9443027,105.139573 28.9985033,105.164847 C29.2288143,105.271802 29.4612933,105.377251 29.6971077,105.480523 C29.7489735,105.50312 29.8015064,105.525381 29.8537058,105.547977 C30.0945234,105.651919 30.3376757,105.754355 30.5843303,105.854448 C30.6328607,105.874199 30.6822249,105.893447 30.7310889,105.912863 C30.983914,106.014127 31.2390739,106.113885 31.4980695,106.210798 C31.5412632,106.227033 31.5852908,106.2426 31.6286513,106.258668 C31.8954851,106.357422 32.1648206,106.454501 32.4381585,106.548736 C32.4733472,106.560787 32.509203,106.572336 32.5445585,106.584387 C32.828403,106.681132 33.1149159,106.776036 33.4057648,106.867593 C33.4282789,106.87479 33.4512933,106.881485 33.4738074,106.888515 C33.7789987,106.983921 34.0873585,107.077151 34.400388,107.166866 L34.409894,107.169544 C38.4652683,108.330819 43.18139,109 48.6553199,109 L53.1037739,108.942924 C63.9650794,108.942924 74.7269893,105.061909 78.2870533,100.359733 L79,99.4175567 L72.2676149,79.3896643" id="Fill-2" fill="#1E2F42"></path><path d="M32.448223,4.7330102 C32.4585446,4.65063285 32.4866327,4.58035994 32.5,4.5 L25.175929,4.5 C25.16933,4.5 24.5388693,4.52084651 24.4447909,5.28006299 C23.3336168,14.2707933 20.1665927,21.1634232 14.8599619,26.0968173 C13.9767079,26.9179008 14.8592851,28.3438694 15.9927944,27.9244175 C16.0271432,27.9116406 16.0613227,27.8983593 16.0955023,27.8845737 C25.7605349,23.987453 30.9834088,16.5844198 32.448223,4.7330102" id="Fill-3" fill="#9871A8"></path><path d="M23.1679089,78.1842256 L23.1679089,51.9589251 C23.1679089,51.7054461 22.9694465,51.5 22.7247468,51.5 L15.5,51.5 L15.5,78.1842256 C15.5,81.1442332 16.1027135,88.7364683 21.6845695,95.2913609 C23.8207671,97.7998591 26.4206405,99.8312303 29.4698627,101.380587 C30.5080863,101.908106 31.4927462,100.569758 30.7278764,99.6719633 C25.0922939,93.0567346 23.1679089,84.4561452 23.1679089,78.1842256" id="Fill-4" fill="#E78A27"></path><path d="M12.0376547,32.5 L4.96251513,32.5 C4.70705323,32.5 4.5,32.7040119 4.5,32.9557213 L4.5,46.0442787 C4.5,46.2959881 4.70705323,46.5 4.96251513,46.5 L12.0376547,46.5 C12.2929468,46.5 12.5,46.2959881 12.5,46.0442787 L12.5,32.9557213 C12.5,32.7040119 12.2929468,32.5 12.0376547,32.5" id="Fill-5" fill="#3EAB7E"></path><path d="M74.4745621,98.6738707 L69.9488912,85.2248789 C69.8662282,84.9791354 69.5994599,84.8559275 69.3578427,84.9485436 C66.7716492,85.9389133 63.9391435,86.5154523 61.4661296,86.5154523 C55.3287826,86.5154523 52.1637807,83.1922006 52.0589849,76.6366323 L52.0584819,47.5209064 C52.0584819,47.2681032 52.2628757,47.063205 52.5150563,47.063205 L70.306706,47.063205 C70.5588867,47.063205 70.7632805,46.8583067 70.7632805,46.6055036 L70.7632805,30.4015628 C70.7632805,30.1487597 70.5588867,29.9438614 70.306706,29.9438614 L52.5913477,29.9438614 C52.3393347,29.9438614 52.1347732,29.7389631 52.1347732,29.48616 L52.1347732,4.9577014 C52.1347732,4.70489828 51.9303794,4.5 51.6783664,4.5 L37.4467569,4.5 C37.4402177,4.5 36.8154668,4.52084281 36.7222405,5.27992454 C35.0483576,18.9464212 28.6849869,27.7820921 17.2899072,32.2288386 C17.116533,32.2964096 17,32.4628159 17,32.6495608 L17,46.6055036 C17,46.8583067 17.2043938,47.063205 17.4565745,47.063205 L28.117748,47.063205 C28.3699287,47.063205 28.5743225,47.2681032 28.5743225,47.5209064 L28.5743225,78.1569809 C28.5743225,88.1267361 34.4569737,104.998991 56.505011,105 L56.5071907,105 C56.756521,105 57.0048452,104.997815 57.2580319,104.993445 C63.9612764,104.879818 70.9552665,102.439696 74.3630593,99.1551043 C74.4916648,99.031056 74.5317387,98.8433026 74.4745621,98.6738707" id="Fill-6" fill="#3996C7"></path><path d="M31.2295842,9 C31.5280455,7.64658989 31.768842,6.22666567 31.9491486,4.73398109 C31.9592856,4.6512605 31.9868717,4.58069478 32,4.5 L24.8068486,4.5 C24.8003676,4.5 24.1811766,4.52093337 24.0887798,5.28331333 C23.9337328,6.56514481 23.736642,7.80291492 23.5,9 L31.2295842,9" id="Fill-7" fill="#FFFFFF"></path><path d="M23.5,59 L23.5,51.9794127 C23.5,51.7146177 23.2929424,51.5 23.0376449,51.5 L15.5,51.5 L15.5,59 L23.5,59" id="Fill-8" fill="#CD512D"></path></g></svg>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},15991(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"pop-menu\"><ul class=\"inner select-right\" data-js-scrollbar> ';
1\n _.forEach(channels, function(channel) { ;\n__p += ' <li class=\"item-option ' +\n__e( channel.name === currentTumblelog ? 'selected' : '' ) +\n'\" data-js-tumblelog><div class=\"avatar\"><img src=\"' +\n__e( channel.avatarUrl ) +\n'\" alt=\"' +\n__e( channel.name ) +\n'\"> ';\n if (isShowBadges) { ;\n__p += ' <span class=\"unread-indicator tab_notice tab-notice--outlined on-light ';\n if (channel.badgeCountString) { ;\n__p += 'tab-notice--active ';\n } ;\n__p += '\" data-js-channel-badge=\"' +\n__e( channel.name ) +\n'\"><span class=\"tab_notice_value\" data-js-channel-badge-text>' +\n__e( channel.badgeCountString ) +\n'</span></span> ';\n } ;\n__p += ' </div><div class=\"info-container\"><p class=\"name\">' +\n__e( channel.displayName ) +\n'</p><p class=\"title\">' +\n((__t = ( channel.directory_safe_title )) == null ? '' : __t) +\n'</p></div></li> ';\n }) ;\n__p += ' </ul></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},16016(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"message\"> ' +\n__e( message ) +\n' ';\n if (!_.isEmpty(actionText)) { ;\n__p += ' <span class=\"action-container\"><a href=\"#\" data-js-action class=\"action\">' +\n__e( actionText ) +\n'</a></span> ';\n } ;\n__p += ' </div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},16089(e,t,i){"use strict";var n=i(55679),s=i(21189),o=i(48357).animate,r=i(98044),a=i(98237),l=i(38578),c=i(27496),u=i(29546),h=r.extend({mixins:[a,l],events:{"click [data-js-text]":"_onClickNewPost","click [data-js-photo]":"_onClickNewPost","click [data-js-quote]":"_onClickNewPost","click [data-js-link]":"_onClickNewPost","click [data-js-chat]":"_onClickNewPost","click [data-js-audio]":"_onClickNewPost","click [data-js-video]":"_onClickNewPost"},setPostType:function(e){this.postType=e},animateShow:function(e,t){return e||(e=0),t||(t=0),this.$el.css({display:"block",opacity:1}),function(i){var n=this.js$(i),r=n.children("i"),a=n.children(".new_post_label_text"),l=this.$(".new_post_label").not(n),c=l.children("i"),u=l.children(".new_post_label_text"),h=[o(c,{scale:1,translateY:[0,10],opacity:1},{duration:e,delay:t}),o(u,{translateY:[0,10],opacity:1},{duration:e,delay:t})];return n.length&&r.length&&h.push(o(r,{scale:[1,1.5],translateY:[0,0],opacity:1},{duration:e,delay:t}),o(a,{translateY:[0,0],opacity:1},{duration:e,delay:t})),s.all(h)}.call(this,this.postType)},animateHide:function(e,t){e||(e=0),t||(t=0),function(i){var n=this.js$(i),r=n.children("i"),a=n.children(".new_post_label_text"),l=this.$(".new_post_label").not(n),c=l.children("i"),u=l.children(".new_post_label_text"),h=[o(c,{scale:[1,1],translateY:[10,0],opacity:0},{duration:e,delay:t}),o(u,{translateY:[10,0],opacity:0},{duration:e,delay:t})];return n.length&&r.length&&h.push(o(r,{scale:[1.5,1],translateY:[0,0],opacity:0},{duration:e,delay:.5*e+t}),o(a,{translateY:[0,0],opacity:0},{duration:e,delay:t})),s.all(h)}.call(this,this.postType).then(n.bind(function(){this.$el.css({display:"none",opacity:0})},this))},_onClickNewPost:function(e){if(e.stopPropagation(),e.preventDefault(),this.get("enabled")){var t=e.currentTarget.getAttribute("data-post-endpoint")||e.currentTarget.getAttribute("data-post-type");c.trigger("postForms:open",{postType:t,postFormType:u.inline})}}});e.exports=h},16124(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div class=\"form-main\"><input type=\"email\" data-js-email placeholder=\"' +\n__e( __('To email') ) +\n'\" class=\"email input\" aria-label=\"' +\n__e( __('To email') ) +\n'\"> <textarea maxlength=\"255\" data-js-message placeholder=\"' +\n__e( __('Message (Optional)') ) +\n'\" class=\"message textarea\" aria-label=\"' +\n__e( __('Optional email message content') ) +\n'\"></textarea> <label class=\"reply-option\"><span class=\"binary-switch reply-switch\"><input type=\"checkbox\" data-js-allow-reply-checkbox> <span class=\"binary-switch-track\"></span> <span class=\"binary-switch-button\"></span> </span> ' +\n__e( __('Let them reply to my email address') ) +\n' </label></div><div class=\"form-result form-result--fail\" data-js-fail-container> ' +\n__e( __('Something went screwy.') ) +\n' </div><footer class=\"footer\"><button type=\"submit\" class=\"button tx-button blue\" data-js-submit-button data-js-text-sending=\"' +\n__e( __('Sending...') ) +\n'\">
1' +\n__e( __('Send') ) +\n'</button></footer><div class=\"form-result form-result--success\" data-js-success-container> ' +\n__e( __('Post shared!') ) +\n' </div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},16268(e,t,i){"use strict";var n=i(27496),s=i(44384).extend({events:{click:"_onExpand"},_onExpand:function(e){e.preventDefault();var t=this.$el.parent(),i=t.find(".post_media.truncated"),s=i.find("img.photo");this.$el.remove(),i.removeClass("truncated"),i.velocity({"max-height":s.attr("height")},50,function(){n.trigger("post:photo_expanded",t)})}});e.exports=s},16309(e,t,i){var n=i(55679),s=i(44890),o=i(50283),r=i(80158),a=i(34197),l=i(14670),c=o.extend({template:a,className:"chat-status-banner",subviews:{statusIndicator:{constructor:r,options:function(e){return{isOnline:-1!==e.get("seconds_since_last_activity"),canSeeUIFlag:s.bool("status_indicator"),name:e.get("name")}}}},initialize:function(e){this.set("name",n.get(e,"name","")),this.listenTo(this,"setActiveTime",function(e){this.set("lastOnlineString",l(e)),this.render()})},render:function(){return this.get("lastOnlineString")?o.prototype.render.call(this):this}});e.exports=c},16400(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div data-subview=\"statusIndicator\"></div> ' +\n__e( _('Send a message') );\n\n}\nreturn __p\n}").apply(void 0,r(s))},16572(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(60786),r=s.extend({className:"conversation-message-timestamp",template:o,initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus"))},getTemplateData:function(){return{label:this.model.get("tsHeader")}}});e.exports=r},16716(e,t,i){"use strict";var n=i(71092),s=i(27496),o=i(38578),r=n.extend({mixins:[o],el:".compose-button",events:{click:"toggleOpen"},defaults:{open:!1},loggingData:{source:"compose-button"},initialize:function(){this.on("change:open",this.onChangeOpen),this.listenTo(s,"fastCompose:init:complete",this.open),this.listenTo(s,"fastCompose:dismiss:complete",this.close)},toggleOpen:function(){this.toggle("open")},open:function(){this.set("open",!0)},close:function(){this.set("open",!1)},onChangeOpen:function(e,t){t?s.trigger("fastCompose:init",{loggingData:this.loggingData}):s.trigger("fastCompose:dismiss",{loggingData:this.loggingData})}});e.exports=r},16964(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(62822),r=i(31993),a=i(16124),l=r.extend({className:"external-network-email-subview external-network-form-subview",template:a,events:n.defaults({"input [data-js-email]":"_onEmailInput"},r.prototype.events),getTitle:function(){return s("Email")},afterRender:function(){n.defer(n.bind(this.focus,this)),r.prototype.afterRender.apply(this,arguments)},focus:function(){this.js$("email").focus()},isFormFieldsValid:function(){return o.isEmail(this.js$("email").val())},onFormSubmit:function(e){var t,i,n;this.isFormValid()&&(t=this.js$("email").val(),i=this.js$("message").val(),n=this.js$("allow-reply-checkbox").is(":checked"),this.share({email:t,message:i,isAllowReply:n}))},_onEmailInput:function(e){this.validateForm()}});e.exports=l},16998(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(71092),r=i(27496),a=i(80965),l=i(64491),c=i(59952),u=i(31048),h=i(85176),d=i(10768),p=i(97030),g=o.extend({className:"popover--post-share-popover",mixins:[l,c,p],template:u,defaults:{popoverData:{},forceSocialFallback:!1,forceEmailFallback:!1,tumblelogShare:!1},events:{"click .embed_post":"__embedPostClick","click .share_email":"__emailTriggerClick","click .share_facebook":"__shareFacebookClick","click .share_pinterest":"__sharePinterestClick","click .share_twitter":"__shareTwitterClick","click .share_reddit":"__shareRedditClick","click .share_permalink":"__sharePermalinkClick","click .flag_post":"__flagPostClick","click .cancel":"__cancelClick","click .popover_menu_item_anchor":"__checkIfPremiumPost","input .email_address":"__emailFormInput","input .twitter .share_message":"__shareTwitterInput","change .reply_to_input":"__replyToChange","keydown .share_form":"__submitKeydown","submit .share_form":"__submit","focus input":"__suspendKeyCommands","focus textarea":"__suspendKeyCommands","blur textarea":"__resumeKeyCommands","blur input":"__resumeKeyCommands"},__embedPostClick:function(e){e.preventDefault(),r.trigger("dashboard-share:embed"),this._showEmbedCode()},__emailTriggerClick:function(e){e.preventDefault(),r.trigger("dashboard-share:email"),this._toggleEmailForm()},__shareFacebookClick:function(e){e.preventDefault(),r.trigger("dashboard-share:facebook"),this._shareFacebook()},__sharePinterestClick:function(e){e.preventDefault(),r.trigger("dashboard-share:pinterest"),this._sharePinterest()},__shareRedditClick:function(e){e.preventDefault(),r.trigger("dashboard-share:reddit"),this._shareReddit()},__shareTwitterClick:function(e){e.preventDefault(),r.trigger("dashboard-share:twitter"),this._shareTwitter()},__sharePermalinkClick:function(){this.resetAndHide()},__flagPostClick:function(e){e.preventDefault(),this.onClickOutside(),r.trigger("abuseform:open",{mode:"post",post:this.model}),r.trigger("Kraken:abuseform:open",{mode:"post"})},__cancelClick:function(e){e.preventDefault(),this._cancelOrClose()},__emailFormInput:function(){var e=g.validateEmail(this.$emailAddress.val());this.$submitButton.attr("disabled",!e)},__shareTwitterInput:function(e){e.preventDefault();var t=g.validateTwitter(this.$shareMessage.val(),this.$characterCount);this.$submitButton.attr("disabled",!t)},__replyToChange:function(e){var t=n(e.currentTarget).is(":checked");a.set("share_popover_reply_to",t,31536e3)},__submitKeydown:function(e){13===e.keyCode&&(e.ctrlKey||e.metaKey||e.altKey)&&(e.preventDefault(),e.stopPropagation(),this.submitForm(
1))},__submit:function(){return this.submitForm(),!1},__submitSuccess:function(){this.$status.show(),this._fadeoutPopover()},__submitError:function(){this.$errorStatus.html(this.errorText),this.$submitButton.html(this.$submitButton.data("label")),this.$submitButton.attr("disabled",!1),this.$errorStatus.addClass("active")},__suspendKeyCommands:function(){r.trigger("keycommands:suspend indashblog:keycommands:suspend")},__resumeKeyCommands:function(){r.trigger("keycommands:resume indashblog:keycommands:resume")},__checkIfPremiumPost:function(){var e=n("[data-id="+this.options.popoverData.post_id+"]").data("json");if(e&&e.pt){var t=new d(e),i=this.loggingData({userAction:"share"});i&&i.modelData&&(i.modelData=t.toJSON()),r.trigger("useraction:explore_click:share",{model:t,loggingData:i})}},_shareTwitter:function(){!this.options.forceSocialFallback&&this.twitterUsername?(this.$serviceCancel.show(),this.$submitButton.html("Tweet"),this.$shareForm.data("type","twitter"),this.$shareLabel.text("@"+this.twitterUsername),this.$shareMessage.val(" [URL]"),this.$shareForm.addClass("active"),this.$shareOptions.removeClass("active"),this.$shareMessage.get(0).setSelectionRange(0,0),this.$shareMessage.attr("placeholder",""),this.$submitButton.attr("disabled",!1),this.$shareForm.addClass("twitter"),g.validateTwitter(this.$shareMessage.val(),this.$characterCount),this.$shareForm.hasClass("active")&&(this.$shareMessage.focus(),this.$shareMessage.get(0).setSelectionRange(0,0))):this._shareTwitterFallback()},_shareTwitterFallback:function(){var e=this.tinyUrl||this.url||this.model.get("url");window.open(""+encodeURIComponent(e),"twitter-share-dialog","width=626,height=258");var t=this._getGenericShareData();this.model.shareTwitter(t),this.resetAndHide()},_shareFacebook:function(){!this.options.forceSocialFallback&&this.hasFacebook?this.model.facebookStatus().done(s.bind(this._shareFacebookSuccess,this)).fail(s.bind(this._shareFacebookFallback,this)):this._shareFacebookFallback()},_shareFacebookSuccess:function(e){e?(this.$serviceCancel.show(),this.$submitButton.html(this.$submitButton.data("label")),this.$shareForm.data("type","facebook"),this.$shareLabel.text(e),this.$submitButton.attr("disabled",!1),this.$shareForm.addClass("facebook"),this.$shareOptions.toggleClass("active"),this.$shareForm.toggleClass("active"),this.$shareForm.hasClass("active")&&this.$shareMessage.focus()):this._shareFacebookFallback()},_shareFacebookFallback:function(){var e=this.url||this.model.get("url");window.open(""+encodeURIComponent(e),"facebook-share-dialog","width=626,height=436");var t=this._getGenericShareData();this.model.shareFacebook(t),this.resetAndHide()},_sharePinterest:function(){var e=this.model.get("pinterest_share_window");window.open(e.url,e.name,e.dimensions);var t=this._getGenericShareData();this.model.sharePinterest(t),this.resetAndHide()},_shareReddit:function(){window.open(""+this.model.get("post_url"),"reddit-share-dialog","scrollbars=1,width=860,height=600");var e=this._getGenericShareData();this.model.shareReddit(e),this.resetAndHide()},_toggleEmailForm:function(){this.options.forceEmailFallback||!this.model.get("tumblelog_share")&&!this.model.get("has_user")?this._emailFormFallback():(this.$submitButton.html(this.$submitButton.data("label")),this.$shareForm.data("type","email"),this.$shareOptions.toggleClass("active"),this.$shareForm.toggleClass("active"),this.$replyTo.addClass("active"),this.$shareForm.hasClass("active")&&this.$emailAddress.length&&this.$emailAddress.focus())},_emailFormFallback:function(){var e=this._getGenericShareData();this.model.shareEmail(e);var t="mailto:?body="+this.url;if(this.model.get("embed_key")){var i=window.open();
1i.document.write('<html><script>location.href = "'+t+'";setTimeout(function(){window.close();},500);<\/script></html>'),i.document.close()}else window.location.href=t;this.resetAndHide()},_showEmbedCode:function(){this.$serviceCancel.show(),this.$shareForm.data("type","embed"),this.$shareLabel.text(this.$shareLabel.data("embed-label")),this.$shareForm.addClass("active"),this.$shareOptions.removeClass("active"),this.$shareMessage.attr("placeholder",""),this.$shareForm.addClass("embed");var e=this.$shareForm.find(".embed_code_text");e.length&&(e.click(function(){e.select()}),setTimeout(function(){e.trigger("click")},100))},_fadeoutPopover:function(){setTimeout(s.bind(function(){this.$el.fadeOut(150,s.bind(this.resetAndHide,this))},this),1250)},_cancelOrClose:function(){var e=this.$emailAddress.val()||"";"email"===this.$shareForm.data("type")&&e.length?(this.$emailAddress.val(""),this.$submitButton.attr("disabled",!0)):this.resetForm()},_getGenericShareData:function(){return[{name:"post_id",value:this.model.get("post_id")},{name:"tumblelog_name",value:this.model.get("tumblelog_name")},{name:"share_fallback",value:!0}]},initialize:function(e){this.options=s.extend({},this.defaults,e),this.model=new h(this.options.popoverData),this.listenTo(this.model,"error",this.__submitError),this.listenTo(this.model,"success",this.__submitSuccess)},cacheSelectors:function(){this.$shareForm=this.$(".share_form"),this.$shareLabel=this.$(".share_label"),this.$replyTo=this.$(".reply_to"),this.$shareOptions=this.$(".share_options"),this.$submitButton=this.$("button.email_submit"),this.$emailAddress=this.$(".email_address"),this.$shareMessage=this.$(".share_message"),this.$embedCode=this.$(".embed_code_text"),this.$characterCount=this.$(".character_count"),this.$serviceCancel=this.$(".cancel.service"),this.$status=this.$(".status"),this.$errorStatus=this.$(".error_status"),this.$statusMessage=this.$(".status_message"),this.$replyToInput=this.$(".reply_to_input"),this.sentText=this.$status.data("sent")||"",this.errorText=this.$status.data("error")||"",this.$(".share_twitter").length&&(this.twitterUsername=this.$(".share_twitter").data("twitter-username")),this.$(".share_facebook").length&&(this.hasFacebook=this.$(".share_facebook").data("has-facebook")),this.url=this.$shareOptions.data("post-url"),this.tinyUrl=this.$shareOptions.data("post-tiny-url"),this.tumblelogName=this.$shareOptions.data("tumblelog-name"),this.embedKey=this.$shareOptions.data("embed-key"),this.postId=this.$shareOptions.data("post-id"),this.rootId=this.$shareOptions.data("root-id")},render:function(){return this.delegateEvents(),this.$el.html(this.template(this.model.toJSON())),this.cacheSelectors(),this.$replyToInput.prop("checked","true"===a.get("share_popover_reply_to")),this},resetForm:function(){this.$serviceCancel.hide(),this.$submitButton.html(this.$submitButton.data("label")),this.$submitButton.attr("disabled",!0),this.$emailAddress.val(""),this.$shareMessage.val(""),this.$shareMessage.attr("placeholder",this.$shareMessage.attr("title")),this.$shareOptions.addClass("active"),this.$shareForm.removeClass("active"),this.$shareForm.removeClass("facebook"),this.$shareForm.removeClass("twitter"),this.$shareForm.removeClass("embed"),this.$status.hide(),this.$statusMessage.html(this.sentText),this.$replyTo.removeClass("active"),this.$errorStatus.removeClass("active"),this.$el.show()},resetAndHide:function(){this.resetForm(),this.teardown()},submitForm:function(){var e=this.$shareForm.serializeArray();switch(this.$shareForm.data("type")){case"facebook":this.model.shareFacebook(e);break;case"twitter":this.model.shareTwitter(e);break;default:this.model.shareEmail(e)}this.$submitButton.attr("disabled",!0),this.$submitButton.html(this.$submitButton.data("label-sending"))},teardown:function(){return this.__resumeKeyCommands(),this.$el.remove(),this}},{placeholderSupport:function(){return"placeholder"in document.createElement("input")},validateEmail:function(e){return/\S+@\S+\.\S+/.test(e)},validateTwitter:function(e,t){var i=e.match(/\[URL\]/gi),n=i?24*i.length:0,s=280-e.length-n,o=!(!t||!t.length)&&t;return o&&(o.removeClass("character-limit").html(s),s<10&&o.addClass("character-limit")),!(s<0||280===s)}});e.exports=g},17025(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(98237),r=i(46919),a=s.extend({className:"messaging-share-post-error",mixins:[o],template:r,defaults:{title:null},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults)))},setTitle:function(e){this.set("title",e)},getTemplateData:function(){return{title:this.get("title")}},afterRender:function(){this.listenTo(this,"change:title",this._onChangeTitle)},_onChangeTitle:function(e,t){this.js$("title").text(t)}});e.exports=a},17080(e,t,i){function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function s(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,o(n.key),n)}}function o(e){var t=function(e,t){if("object"!=n(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var s=i.call(e,t||"default");if("object"!=n(s))return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==n(t)?t:t+""}var r=i(33309),a=function(){return e=function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.viewabilityComponents=[],this.startHeartBeat()},(t=[{key:"startHeartBeat",value:function(){var e=this;
1window.setInterval(function(){e.viewabilityComponents.forEach(function(e){return e.stateChanged(r.POSITION_CHANGE)})},150)}},{key:"handleNewViewabilityComponent",value:function(e){this.viewabilityComponents.push(e)}}])&&s(e.prototype,t),i&&s(e,i),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,i}();e.exports=a},17137(e,t,i){var n=i(74692),s=i(55679),o=i(27496),r=i(71742),a=i(28017),l=r.extend({name:"peepr",params:"",selector:"body",initialize:function(){var e=a.get("Components/Peepr")||{};this.params=e,e.blog_name&&(this.listenToOnce(o,"peepr:close",this.onPeeprClose),n(document).ready(s.bind(this.onPeeprRequestWithParams,this))),this.$container=n(this.container),this.bindEvents()},bindEvents:function(){this.listenTo(o,"peepr-open-request",this.onPeeprRequest),this.$container.on("click","[data-peepr]",s.bind(this.onPeeprTargetClicked,this))},onPeeprTargetClicked:function(e){if(!e.ctrlKey&&!e.metaKey){e.preventDefault();var t=n(e.currentTarget),i=t.data("peepr");if(i){var s=i.tumblelog,r=i.postId,a=i.searchTagTerm,l=i.replyNoteToTumblelogName;o.trigger("peepr-open-request",{tumblelog_name:s,post_id:r,searchTagTerm:a,reply_note_to_tumblelog_name:l})}else window.open(t.attr("href"))}},onPeeprClose:function(){window.Backbone.history.navigate("/dashboard")},onPeeprRequestWithParams:function(){o.trigger("peepr-open-request",{tumblelog_name:this.params.blog_name,post_id:this.params.post_id})},onPeeprRequest:function(e){e.tumblelog_name&&(e.editing_appearance=void 0!==e.editing_appearance&&e.editing_appearance,void 0===e.should_bypass_safemode&&void 0!==this.params.bn&&(e.should_bypass_safemode=this.params.bn),this.open(e))},open:function(e){var t="".concat(e.tumblelog_name);e.post_id?window.location="".concat(t,"/").concat(e.post_id):e.searchTagTerm?window.location="".concat(t,"/search/").concat(e.searchTagTerm):window.location=t}});e.exports=l},17145(e,t,i){var n=i(21391),s=i(71827);function o(){}o.extend=n.Model.extend,s.applyTo(o),e.exports=o},17383(e,t,i){"use strict";var n=i(27513),s=i(19452),o=n.extend({model:s,getByNamespace:function(e){return this.filter(function(t){return this._isNamespaceMatch(e,t.get("namespace"))},this)},_isNamespaceMatch:function(e,t){return e===t||0===t.indexOf(e+":")}});e.exports=o},17579(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(31993),r=i(63349),a=i(98237),l=o.extend({className:"external-network-twitter-subview external-network-form-subview",template:r,mixins:[a],defaults:n.defaults({username:null,urlToken:"[URL]",shortUrlLength:23,characterLimit:280,characterCount:0,characterCountExceedsLenghClass:"exceeds-length"},o.prototype.defaults),events:n.defaults({"input [data-js-message]":"_onMessageInput"},o.prototype.events),getTitle:function(){var e=this.get("username");return n.isEmpty(e)?s("Twitter"):s("Twitter (@%1$s)",e)},getTemplateData:function(){return{urlToken:this.get("urlToken")}},afterRender:function(){this.listenTo(this,"change:characterCount",this._onChangeCharacterCount),this._updateCharacterCount(),this._onChangeCharacterCount(this,this.get("characterCount")),n.defer(n.bind(this.focus,this)),o.prototype.afterRender.apply(this,arguments)},isFormFieldsValid:function(){var e=this.get("characterCount");return e>0&&e<=this.get("characterLimit")},onFormSubmit:function(e){this.isFormValid()&&this.share({message:this._getMessage()})},focus:function(){this.js$("message").focus()},_getMessage:function(){return this.js$("message").val()},_updateCharacterCount:function(){var e=this._calculateCharacterCount(this._getMessage());this.set("characterCount",e)},_updateCharacterCountContainer:function(e){var t=this.js$("character-count"),i=this.get("characterCountExceedsLenghClass"),n=this.get("characterLimit")-e;t.text(n).toggleClass(i,n<0)},_getUrlTokenCountFromMessage:function(e){var t=this.get("urlToken"),i=new RegExp(n.escapeRegExp(t),"ig"),s=e.match(i);return n.isEmpty(s)?0:s.length},_getAdditionalUrLengthFromMessage:function(e){var t=this.get("urlToken"),i=this.get("shortUrlLength"),n=this._getUrlTokenCountFromMessage(e);return 0===n?0:n*i-n*t.length},_calculateCharacterCount:function(e){return e.length+this._getAdditionalUrLengthFromMessage(e)},_onChangeCharacterCount:function(e,t){this._updateCharacterCountContainer(t)},_onMessageInput:function(e){this._updateCharacterCount(),this.validateForm()}});e.exports=l},17917(e){e.exports=function(){var e;return function e(t,i,n){function s(r,a){if(!i[r]){if(!t[r]){if(o)return o(r,!0);throw new Error("Cannot find module '"+r+"'")}var l=i[r]={exports:{}};t[r][0].call(l.exports,function(e){var i=t[r][1][e];return s(i||e)},l,l.exports,e,t,i,n)}return i[r].exports}for(var o=void 0,r=0;r<n.length;r++)s(n[r]);return s}({1:[function(e,t,i){var n=t.exports=e("../when");n.callbacks=e("../callbacks"),n.cancelable=e("../cancelable"),n.delay=e("../delay"),n.fn=e("../function"),n.guard=e("../guard"),n.keys=e("../keys"),n.nodefn=n.node=e("../node"),n.parallel=e("../parallel"),n.pipeline=e("../pipeline"),n.poll=e("../poll"),n.sequence=e("../sequence"),n.timeout=e("../timeout")},{"../callbacks":2,"../cancelable":3,"../delay":4,"../function":5,"../guard":6,"../keys":7,"../node":26,"../parallel":27,"../pipeline":28,"../poll":29,"../sequence":30,"../timeout":31,"../w
1hen":32}],2:[function(t,i,n){!function(e){e(function(e){var t=e("./when").Promise,i=e("./lib/liftAll"),n=Array.prototype.slice,s=e("./lib/apply")(t,r);return{lift:c,liftAll:u,apply:o,call:l,promisify:h};function o(e,t){return s(e,this,t||[])}function r(e,t,i,n){i.push(g(n.resolve,n),g(n.reject,n)),a(e,t,i,n)}function a(e,t,i,n){try{e.apply(t,i)}catch(e){n.reject(e)}}function l(e){return s(e,this,n.call(arguments,1))}function c(e){var t=arguments.length>1?n.call(arguments,1):[];return function(){return s(e,this,t.concat(n.call(arguments)))}}function u(e,t,n){return i(c,t,n,e)}function h(e,i){return function(){var n=this;return t.all(arguments).then(function(s){var o,r,a=t._defer();return"number"==typeof i.callback&&(o=d(s,i.callback)),"number"==typeof i.errback&&(r=d(s,i.errback)),r<o?(p(s,r,a._handler.reject,a._handler),p(s,o,a._handler.resolve,a._handler)):(p(s,o,a._handler.resolve,a._handler),p(s,r,a._handler.reject,a._handler)),e.apply(n,s),a})}}function d(e,t){return t<0?e.length+t+2:t}function p(e,t,i,n){"number"==typeof t&&e.splice(t,0,g(i,n))}function g(e,t){return function(){arguments.length>1?e.call(t,n.call(arguments)):e.apply(t,arguments)}}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"./lib/apply":11,"./lib/liftAll":23,"./when":32}],3:[function(t,i,n){!function(e){e(function(){return function(e,t){return e.cancel=function(){try{e.reject(t(e))}catch(t){e.reject(t)}return e.promise},e}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e()})},{}],4:[function(t,i,n){!function(e){e(function(e){var t=e("./when");return function(e,i){return t(i).delay(e)}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"./when":32}],5:[function(t,i,n){!function(e){e(function(e){var t=e("./when"),i=t.try,n=e("./lib/liftAll"),s=e("./lib/apply")(t.Promise),o=Array.prototype.slice;return{lift:a,liftAll:l,call:i,apply:r,compose:c};function r(e,t){return s(e,this,null==t?[]:o.call(t))}function a(e){var t=arguments.length>1?o.call(arguments,1):[];return function(){return s(e,this,t.concat(o.call(arguments)))}}function l(e,t,i){return n(a,t,i,e)}function c(e){var n=o.call(arguments,1);return function(){var s=this,r=o.call(arguments),a=i.apply(s,[e].concat(r));return t.reduce(n,function(e,t){return t.call(s,e)},a)}}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"./lib/apply":11,"./lib/liftAll":23,"./when":32}],6:[function(t,i,n){!function(e){e(function(e){var t=e("./when"),i=Array.prototype.slice;return n.n=s,n;function n(e,n){return function(){var s=i.call(arguments);return t(e()).withThis(this).then(function(e){return t(n.apply(this,s)).finally(e)})}}function s(e){var i=0,n=[];return function(){return t.promise(function(t){i<e?t(s):n.push(t),i+=1})};function s(){i=Math.max(i-1,0),n.length>0&&n.shift()(s)}}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"./when":32}],7:[function(t,i,n){!function(e){"use strict";e(function(e){var t=e("./when"),i=t.Promise,n=t.resolve;return{all:t.lift(s),map:o,settle:r};function s(e){for(var t,n=i._defer(),s=i._handler(n),o={},r=Object.keys(e),a=r.length,l=0;l<r.length;++l)t=r[l],i._handler(e[t]).fold(c,t,o,s);return 0===a&&s.resolve(o),n;function c(e,t,i){this[e]=t,0===--a&&i.resolve(o)}}function o(e,t){return n(e).then(function(e){return s(Object.keys(e).reduce(function(t,s){return t[s]=n(e[s]).fold(i,s),t},{}))});function i(e,i){return t(i,e)}}function r(e){var s=Object.keys(e),o={};if(0===s.length)return n(o);var r=i._defer(),l=i._handler(r),c=s.map(function(t){return e[t]});return t.settle(c).then(function(e){a(s,e,o,l)}),r}function a(e,t,i,n){for(var s=0;s<e.length;s++)i[e[s]]=t[s];n.resolve(i)}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"./when":32}],8:[function(t,i,n){!function(e){"use strict";e(function(e){return e("./makePromise")({scheduler:new(e("./Scheduler"))(e("./env").asap)})})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"./Scheduler":9,"./env":21,"./makePromise":24}],9:[function(t,i,n){!function(e){"use strict";e(function(){function e(e){this._async=e,this._running=!1,this._queue=this,this._queueLen=0,this._afterQueue={},this._afterQueueLen=0;var t=this;this.drain=function(){t._drain()}}return e.prototype.enqueue=function(e){this._queue[this._queueLen++]=e,this.run()},e.prototype.afterQueue=function(e){this._afterQueue[this._afterQueueLen++]=e,this.run()},e.prototype.run=function(){this._running||(this._running=!0,this._async(this.drain))},e.prototype._drain=function(){for(var e=0;e<this._queueLen;++e)this._queue[e].run(),this._queue[e]=void 0;for(this._queueLen=0,this._running=!1,e=0;e<this._afterQueueLen;++e)this._afterQueue[e].run(),this._afterQueue[e]=void 0;this._afterQueueLen=0},e})}("function"==typeof e&&e.amd?e:function(e){i.exports=e()})},{}],10:[function(t,i,n){!function(e){"use strict";e(function(){function e(t){Error.call(this),this.message=t,this.name=e.name,"function"==typeof Error.captureStackTrace&&Error.captureStackTrace(this,e)}return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e})}("function"==typeof e&&e.amd?e:function(e){i.exports=e()})},{}],11:[function(t,i,n){!function(e){"use strict";e(function(){return e.tryCatchResolve=t,e;function e(e,i){return arguments.length<2&&(i=t),n;function n(t,n,o){var r=e._defer(),a=o.length;return s({f:t,thisArg:n,args:o,params:new Array(a),i:a-1,call:i},r._handler),r}function s(t,n){if(t.i<0)return i(t.f,t.thisArg,t.params,n);e._handler(t.args[t.i]).fold(o,t,void 0,n)}function o(e,t,i){e.params[e.i]=t,e.i-=1,s(e,i)}}function t(e,t,i,n){try{n.resolve(e.apply(t,i))}catch(e){n.reject(e)}}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e()})},{}],12:[function(t,i,n){!function(e){"use strict";e(function(e){var t=e("../state"),i=e("../apply");return function(e){var n=i(e),s=e.resolve,o=e.all,r=Array.prototype.reduce,a=Array.prototype.reduceRight,l=Array.prototype.slice;return e.any=c,e.some=u,e.settle=g,e.map=h,e.filter=d,e.reduce=m,e.reduceRight=_,e.prototype.spread=function(e){return this.then(o).then(function(t){return e.apply(this,t)})},e;function c(t){for(var i,n,s=e._defer(),o=s._handler,r=t.length>>>0,a=r,l=[],c=0;c<r;++c)if(void 0!==(n=t[c])||c in t){if((i=e._handler(n)).state()>
10){o.become(i),e._visitRemaining(t,c,i);break}i.visit(o,u,h)}else--a;return 0===a&&o.reject(new RangeError("any(): array must not be empty")),s;function u(e){l=null,this.resolve(e)}function h(e){this.resolved||(l.push(e),0===--a&&this.reject(l))}}function u(t,i){var n,s,o,r=e._defer(),a=r._handler,l=[],c=[],u=t.length>>>0,h=0;for(o=0;o<u;++o)(void 0!==(s=t[o])||o in t)&&++h;for(i=Math.max(i,0),n=h-i+1,i>(h=Math.min(i,h))?a.reject(new RangeError("some(): array must contain at least "+i+" item(s), but had "+h)):0===h&&a.resolve(l),o=0;o<u;++o)(void 0!==(s=t[o])||o in t)&&e._handler(s).visit(a,d,p,a.notify);return r;function d(e){this.resolved||(l.push(e),0===--h&&(c=null,this.resolve(l)))}function p(e){this.resolved||(c.push(e),0===--n&&(l=null,this.reject(c)))}}function h(t,i){return e._traverse(i,t)}function d(t,i){var n=l.call(t);return e._traverse(i,n).then(function(e){return p(n,e)})}function p(t,i){for(var n=i.length,s=new Array(n),o=0,r=0;o<n;++o)i[o]&&(s[r++]=e._handler(t[o]).value);return s.length=r,s}function g(e){return o(e.map(f))}function f(i){var n;return i instanceof e&&(n=i._handler.join()),n&&0===n.state()||!n?s(i).then(t.fulfilled,t.rejected):(n._unreport(),t.inspect(n))}function m(e,t){return arguments.length>2?r.call(e,v(t),arguments[2]):r.call(e,v(t))}function _(e,t){return arguments.length>2?a.call(e,v(t),arguments[2]):a.call(e,v(t))}function v(e){return function(t,i,s){return n(e,void 0,[t,i,s])}}}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"../apply":11,"../state":25}],13:[function(t,i,n){!function(e){"use strict";e(function(){return function(i){var o=i.resolve,r=i.reject,a=i.prototype.catch;function l(e,i){return function(n){return t(n,i)?e.call(this,n):r(n)}}function c(e,t,i,s){var o=e.call(t);return n(o)?u(o,i,s):i(s)}function u(e,t,i){return o(e).then(function(){return t(i)})}return i.prototype.done=function(e,t){this._handler.visit(this._handler.receiver,e,t)},i.prototype.catch=i.prototype.otherwise=function(t){return arguments.length<2?a.call(this,t):"function"!=typeof t?this.ensure(e):a.call(this,l(arguments[1],t))},i.prototype.finally=i.prototype.ensure=function(e){return"function"!=typeof e?this:this.then(function(t){return c(e,this,s,t)},function(t){return c(e,this,r,t)})},i.prototype.else=i.prototype.orElse=function(e){return this.then(void 0,function(){return e})},i.prototype.yield=function(e){return this.then(function(){return e})},i.prototype.tap=function(e){return this.then(e).yield(this)},i};function e(){throw new TypeError("catch predicate must be a function")}function t(e,t){return i(t)?e instanceof t:t(e)}function i(e){return e===Error||null!=e&&e.prototype instanceof Error}function n(e){return("object"==typeof e||"function"==typeof e)&&null!==e}function s(e){return e}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e()})},{}],14:[function(t,i,n){!function(e){"use strict";e(function(){return function(e){return e.prototype.fold=function(t,i){var n=this._beget();return this._handler.fold(function(i,n,s){e._handler(i).fold(function(e,i,n){n.resolve(t.call(this,i,e))},n,this,s)},i,n._handler.receiver,n._handler),n},e}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e()})},{}],15:[function(t,i,n){!function(e){"use strict";e(function(e){var t=e("../state").inspect;return function(e){return e.prototype.inspect=function(){return t(e._handler(this))},e}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"../state":25}],16:[function(t,i,n){!function(e){"use strict";e(function(){return function(e){var t=e.resolve;return e.iterate=i,e.unfold=n,e;function i(e,t,i,s){return n(function(t){return[t,e(t)]},t,i,s)}function n(e,i,s,o){return t(o).then(function(n){return t(i(n)).then(function(i){return i?n:t(e(n)).spread(r)})});function r(o,r){return t(s(o)).then(function(){return n(e,i,s,r)})}}}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e()})},{}],17:[function(t,i,n){!function(e){"use strict";e(function(){return function(e){return e.prototype.progress=function(e){return this.then(void 0,void 0,e)},e}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e()})},{}],18:[function(t,i,n){!function(e){"use strict";e(function(e){var t=e("../env"),i=e("../TimeoutError");function n(e,i,n,s){return t.setTimer(function(){e(n,s,i)},i)}return function(e){function s(e,t,i){n(o,e,t,i)}function o(e,t){t.resolve(e)}function r(e,t,n){var s=void 0===e?new i("timed out after "+n+"ms"):e;t.reject(s)}return e.prototype.delay=function(e){var t=this._beget();return this._handler.fold(s,e,void 0,t._handler),t},e.prototype.timeout=function(e,i){var s=this._beget(),o=s._handler,a=n(r,e,i,s._handler);return this._handler.visit(o,function(e){t.clearTimer(a),this.resolve(e)},function(e){t.clearTimer(a),this.reject(e)},o.notify),s},e}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"../TimeoutError":10,"../env":21}],19:[function(t,i,n){!function(e){"use strict";e(function(e){var t=e("../env").setTimer,i=e("../format");return function(e){var o,r=s,a=s;"undefined"!=typeof console&&(o=console,r=void 0!==o.error?function(e){o.error(e)}:function(e){o.log(e)},a=void 0!==o.info?function(e){o.info(e)}:function(e){o.log(e)}),e.onPotentiallyUnhandledRejection=function(e){p(h,e)},e.onPotentiallyUnhandledRejectionHandled=function(e){p(d,e)},e.onFatalRejection=function(e){p(n,e.value)};var l=[],c=[],u=null;function h(e){e.handled||(c.push(e),r("Potentially unhandled rejection ["+e.id+"] "+i.formatError(e.value)))}function d(e){var t=c.indexOf(e);t>=0&&(c.splice(t,1),a("Handled previous rejection ["+e.id+"] "+i.formatObject(e.value)))}function p(e,i){l.push(e,i),null===u&&(u=t(g,0))}function g(){for(u=null;l.length>0;)l.shift()(l.shift())}return e};function n(e){throw e}function s(){}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"../env":21,"../format":22}],20:[function(t,i,n){!function(e){"use strict";e(function(){return function(e){return e.prototype.with=e.prototype.withThis=function(e){var t=this._beget(),i=t._handler;return i.receiver=e,this._handler.chain(i,e),t},e}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e()})},{}],21:[function(t,i,n){!function(e){"use strict";e(function(e){var t,i="undefined"!=typeof setTimeout&&setTimeout,n=function(e,t){return setTimeout(e,t)},s=function(e){return clearTimeout(e)},o=function(e){return i(e,0)};if(a())o=function(e){return process.nextTick(e)};else if(t=l())o=c(t);else if(!i){var r=e("vertx");n=function(e,t){return r.setTimer(t,e)},s=r.cancelTimer,o=r.runOnLoop||r.runOnContext}return{setTimer:n,clearTimer:s,asap:o};function a(){return"undefined"!=typeof process&&"[object process]"===Object.prototype.toString.call(process)}function l(){return"undefined"!=typeof MutationObserver&&MutationObserver||"undefined"!=typeof WebKitMutationObserver&&WebKitMutationObserver}function c(e){var t,i=document.createTextNode("");function n(){var e=t;t=void 0,e()}new e(n).observe(i,{characterData:!0}
1);var s=0;return function(e){t=e,i.data=s^=1}}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{}],22:[function(t,i,n){!function(e){"use strict";e(function(){return{formatError:e,formatObject:t,tryStringify:i};function e(e){var i="object"==typeof e&&null!==e&&(e.stack||e.message)?e.stack||e.message:t(e);return e instanceof Error?i:i+" (WARNING: non-Error used)"}function t(e){var t=String(e);return"[object Object]"===t&&"undefined"!=typeof JSON&&(t=i(e,t)),t}function i(e,t){try{return JSON.stringify(e)}catch(e){return t}}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e()})},{}],23:[function(t,i,n){!function(e){"use strict";e(function(){return function(i,n,s,o){return void 0===n&&(n=e),Object.keys(o).reduce(function(e,t){var s=o[t];return"function"==typeof s?n(e,i(s),t):e},void 0===s?t(o):s)};function e(e,t,i){return e[i]=t,e}function t(e){return"function"==typeof e?e.bind():Object.create(e)}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e()})},{}],24:[function(t,i,n){!function(e){"use strict";e(function(){return function(e){var t=e.scheduler,i=te(),n=Object.create||function(e){function t(){}return t.prototype=e,new t};function s(e,t){this._handler=e===C?t:o(e)}function o(e){var t=new S;try{e(i,n,s)}catch(e){n(e)}return t;function i(e){t.resolve(e)}function n(e){t.reject(e)}function s(e){t.notify(e)}}function r(e){return V(e)?e:new s(C,new T(b(e)))}function a(e){return new s(C,new T(new F(e)))}function l(){return R}function c(){return new s(C,new S)}function u(e,t){return new t(C,new S(e.receiver,e.join().context))}function h(e){return p(Y,null,e)}function d(e,t){return p(W,e,t)}function p(e,t,i){for(var n,o="function"==typeof t?u:h,r=new S,a=i.length>>>0,l=new Array(a),c=0;c<i.length&&!r.resolved;++c)void 0!==(n=i[c])||c in i?g(i,o,c,n,r):--a;return 0===a&&r.become(new P(l)),new s(C,r);function u(n,s,o){o.resolved||g(i,h,n,e(t,s,n),o)}function h(e,t,i){l[e]=t,0===--a&&i.become(new P(l))}}function g(e,t,i,n,s){if(U(n)){var o=y(n),r=o.state();0===r?o.fold(t,i,void 0,s):r>0?t(i,o.value,s):(s.become(o),f(e,i+1,o))}else t(i,n,s)}function f(e,t,i){for(var n=t;n<e.length;++n)m(b(e[n]),i)}function m(e,t){if(e!==t){var i=e.state();0===i?e.visit(e,void 0,e._unreport):i<0&&e._unreport()}}function _(e){return"object"!=typeof e||null===e?a(new TypeError("non-iterable passed to race()")):0===e.length?l():1===e.length?r(e[0]):v(e)}function v(e){var t,i,n,o=new S;for(t=0;t<e.length;++t)if(void 0!==(i=e[t])||t in e){if(0!==(n=b(i)).state()){o.become(n),f(e,t+1,n);break}n.visit(o,o.resolve,o.reject)}return new s(C,o)}function b(e){return V(e)?e._handler.join():U(e)?w(e):new P(e)}function y(e){return V(e)?e._handler.join():w(e)}function w(e){try{var t=e.then;return"function"==typeof t?new E(t,e):new P(e)}catch(e){return new F(e)}}function C(){}function x(){}s.resolve=r,s.reject=a,s.never=l,s._defer=c,s._handler=b,s.prototype.then=function(e,t,i){var n=this._handler,s=n.join().state();if("function"!=typeof e&&s>0||"function"!=typeof t&&s<0)return new this.constructor(C,n);var o=this._beget(),r=o._handler;return n.chain(r,n.receiver,e,t,i),o},s.prototype.catch=function(e){return this.then(void 0,e)},s.prototype._beget=function(){return u(this._handler,this.constructor)},s.all=h,s.race=_,s._traverse=d,s._visitRemaining=f,C.prototype.when=C.prototype.become=C.prototype.notify=C.prototype.fail=C.prototype._unreport=C.prototype._report=X,C.prototype._state=0,C.prototype.state=function(){return this._state},C.prototype.join=function(){for(var e=this;void 0!==e.handler;)e=e.handler;return e},C.prototype.chain=function(e,t,i,n,s){this.when({resolver:e,receiver:t,fulfilled:i,rejected:n,progress:s})},C.prototype.visit=function(e,t,i,n){this.chain(k,e,t,i,n)},C.prototype.fold=function(e,t,i,n){this.when(new B(e,t,i,n))},J(C,x),x.prototype.become=function(e){e.fail()};var k=new x;function S(e,t){s.createContext(this,t),this.consumers=void 0,this.receiver=e,this.handler=void 0,this.resolved=!1}function T(e){this.handler=e}function E(e,i){S.call(this),t.enqueue(new O(e,i,this))}function P(e){s.createContext(this),this.value=e}J(C,S),S.prototype._state=0,S.prototype.resolve=function(e){this.become(b(e))},S.prototype.reject=function(e){this.resolved||this.become(new F(e))},S.prototype.join=function(){if(!this.resolved)return this;for(var e=this;void 0!==e.handler;)if((e=e.handler)===this)return this.handler=D();return e},S.prototype.run=function(){var e=this.consumers,t=this.handler;this.handler=this.handler.join(),this.consumers=void 0;for(var i=0;i<e.length;++i)t.when(e[i])},S.prototype.become=function(e){this.resolved||(this.resolved=!0,this.handler=e,void 0!==this.consumers&&t.enqueue(this),void 0!==this.context&&e._report(this.context))},S.prototype.when=function(e){this.resolved?t.enqueue(new $(e,this.handler)):void 0===this.consumers?this.consumers=[e]:this.consumers.push(e)},S.prototype.notify=function(e){this.resolved||t.enqueue(new N(e,this))},S.prototype.fail=function(e){var t=void 0===e?this.context:e;this.resolved&&this.handler.join().fail(t)},S.prototype._report=function(e){this.resolved&&this.handler.join()._report(e)},S.prototype._unreport=function(){this.resolved&&this.handler.join()._unreport()},J(C,T),T.prototype.when=function(e){t.enqueue(new $(e,this))},T.prototype._report=function(e){this.join()._report(e)},T.prototype._unreport=function(){this.join()._unreport()},J(S,E),J(C,P),P.prototype._state=1,P.prototype.fold=function(e,t,i,n){H(e,t,this,i,n)},P.prototype.when=function(e){z(e.fulfilled,this,e.receiver,e.resolver)};var I=0;function F(e){s.createContext(this),this.id=++I,this.value=e,this.handled=!1,this.reported=!1,this._report()}function A(e,t){this.rejection=e,this.context=t}function M(e){this.rejection=e}J(C,F),F.prototype._state=-1,F.prototype.fold=function(e,t,i,n){n.become(this)},F.prototype.when=function(e){"function"==typeof e.rejected&&this._unreport(),z(e.rejected,this,e.receiver,e.resolver)},F.prototype._report=function(e){t.afterQueue(new A(this,e))},F.prototype._unreport=function(){this.handled||(this.handled=!0,t.afterQueue(new M(this)))},F.prototype.fail=function(e){this.reported=!0,i("unhandledRejection",this),s.onF
1atalRejection(this,void 0===e?this.context:e)},A.prototype.run=function(){this.rejection.handled||this.rejection.reported||(this.rejection.reported=!0,i("unhandledRejection",this.rejection)||s.onPotentiallyUnhandledRejection(this.rejection,this.context))},M.prototype.run=function(){this.rejection.reported&&(i("rejectionHandled",this.rejection)||s.onPotentiallyUnhandledRejectionHandled(this.rejection))},s.createContext=s.enterContext=s.exitContext=s.onPotentiallyUnhandledRejection=s.onPotentiallyUnhandledRejectionHandled=s.onFatalRejection=X;var j=new C,R=new s(C,j);function D(){return new F(new TypeError("Promise cycle"))}function $(e,t){this.continuation=e,this.handler=t}function N(e,t){this.handler=t,this.value=e}function O(e,t,i){this._then=e,this.thenable=t,this.resolver=i}function L(e,t,i,n,s){try{e.call(t,i,n,s)}catch(e){n(e)}}function B(e,t,i,n){this.f=e,this.z=t,this.c=i,this.to=n,this.resolver=k,this.receiver=this}function V(e){return e instanceof s}function U(e){return("object"==typeof e||"function"==typeof e)&&null!==e}function z(e,t,i,n){if("function"!=typeof e)return n.become(t);s.enterContext(t),G(e,t.value,i,n),s.exitContext()}function H(e,t,i,n,o){if("function"!=typeof e)return o.become(i);s.enterContext(i),K(e,t,i.value,n,o),s.exitContext()}function q(e,t,i,n,o){if("function"!=typeof e)return o.notify(t);s.enterContext(i),Q(e,t,n,o),s.exitContext()}function W(e,t,i){try{return e(t,i)}catch(e){return a(e)}}function G(e,t,i,n){try{n.become(b(e.call(i,t)))}catch(e){n.become(new F(e))}}function K(e,t,i,n,s){try{e.call(n,t,i,s)}catch(e){s.become(new F(e))}}function Q(e,t,i,n){try{n.notify(e.call(i,t))}catch(e){n.notify(e)}}function J(e,t){t.prototype=n(e.prototype),t.prototype.constructor=t}function Y(e,t){return t}function X(){}function Z(){if("function"==typeof CustomEvent)try{return new CustomEvent("unhandledRejection")instanceof CustomEvent}catch(e){}return!1}function ee(){if("undefined"!=typeof document&&"function"==typeof document.createEvent)try{return document.createEvent("CustomEvent").initCustomEvent("eventType",!1,!0,{}),!0}catch(e){}return!1}function te(){return"undefined"!=typeof process&&null!==process&&"function"==typeof process.emit?function(e,t){return"unhandledRejection"===e?process.emit(e,t.value,t):process.emit(e,t)}:"undefined"!=typeof self&&Z()?function(e,t){return function(i,n){var s=new t(i,{detail:{reason:n.value,key:n},bubbles:!1,cancelable:!0});return!e.dispatchEvent(s)}}(self,CustomEvent):"undefined"!=typeof self&&ee()?function(e,t){return function(i,n){var s=t.createEvent("CustomEvent");return s.initCustomEvent(i,!1,!0,{reason:n.value,key:n}),!e.dispatchEvent(s)}}(self,document):X}return $.prototype.run=function(){this.handler.join().when(this.continuation)},N.prototype.run=function(){var e=this.handler.consumers;if(void 0!==e)for(var t,i=0;i<e.length;++i)q((t=e[i]).progress,this.value,this.handler,t.receiver,t.resolver)},O.prototype.run=function(){var e=this.resolver;function t(t){e.resolve(t)}function i(t){e.reject(t)}function n(t){e.notify(t)}L(this._then,this.thenable,t,i,n)},B.prototype.fulfilled=function(e){this.f.call(this.c,this.z,e,this.to)},B.prototype.rejected=function(e){this.to.reject(e)},B.prototype.progress=function(e){this.to.notify(e)},s}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e()})},{}],25:[function(t,i,n){!function(e){"use strict";e(function(){return{pending:e,fulfilled:i,rejected:t,inspect:n};function e(){return{state:"pending"}}function t(e){return{state:"rejected",reason:e}}function i(e){return{state:"fulfilled",value:e}}function n(n){var s=n.state();return 0===s?e():s>0?i(n.value):t(n.value)}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e()})},{}],26:[function(t,i,n){!function(e){e(function(e){var t=e("./when"),i=e("./lib/liftAll"),n=e("./lib/env").setTimer,s=Array.prototype.slice,o=e("./lib/apply")(t.Promise,a);return{lift:c,liftAll:u,apply:r,call:l,createCallback:h,bindCallback:d,liftCallback:p};function r(e,t){return o(e,this,t||[])}function a(e,t,i,n){var s=h(n);try{switch(i.length){case 2:e.call(t,i[0],i[1],s);break;case 1:e.call(t,i[0],s);break;case 0:e.call(t,s);break;default:i.push(s),e.apply(t,i)}}catch(e){n.reject(e)}}
1function l(e){return o(e,this,s.call(arguments,1))}function c(e){var t=arguments.length>1?s.call(arguments,1):[];return function(){var i,n=t.length,s=arguments.length,r=new Array(s+n);for(i=0;i<n;++i)r[i]=t[i];for(i=0;i<s;++i)r[i+n]=arguments[i];return o(e,this,r)}}function u(e,t,n){return i(c,t,n,e)}function h(e){return function(t,i){t?e.reject(t):arguments.length>2?e.resolve(s.call(arguments,1)):e.resolve(i)}}function d(e,i){return e=t(e),i&&e.then(s,o),e;function s(e){o(null,e)}function o(e,t){n(function(){i(e,t)},0)}}function p(e){return function(t){return d(t,e)}}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"./lib/apply":11,"./lib/env":21,"./lib/liftAll":23,"./when":32}],27:[function(t,i,n){!function(e){e(function(e){var t=e("./when"),i=t.Promise.all,n=Array.prototype.slice;return function(e){return i(n.call(arguments,1)).then(function(i){return t.map(e,function(e){return e.apply(void 0,i)})})}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"./when":32}],28:[function(t,i,n){!function(e){e(function(e){var t=e("./when"),i=t.Promise.all,n=Array.prototype.slice;return function(e){var s=function(e,t){return s=function(e,t){return t(e)},t.apply(null,e)};return i(n.call(arguments,1)).then(function(i){return t.reduce(e,function(e,t){return s(e,t)},i)})}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"./when":32}],29:[function(t,i,n){!function(e){"use strict";e(function(e){var t=e("./when"),i=t.try,n=e("./cancelable");return function(e,s,o,r){var a,l,c;function u(e){a.resolve(e)}function h(e){i(s).then(d,c),void 0!==e&&a.notify(e)}function d(){l||t(e(),function(e){t(o(e),function(t){return t?u(e):h(e)},function(){h(e)})},c)}return l=!1,a=n(t.defer(),function(){l=!0}),c=a.reject,o=o||function(){return!1},"function"!=typeof s&&(s=function(e){return function(){return t().delay(e)}}(s)),r?h():d(),a.promise=Object.create(a.promise),a.promise.cancel=a.cancel,a.promise}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"./cancelable":3,"./when":32}],30:[function(t,i,n){!function(e){e(function(e){var t=e("./when"),i=t.Promise.all,n=Array.prototype.slice;return function(e){var s=[];return i(n.call(arguments,1)).then(function(i){return t.reduce(e,function(e,n){return t(n.apply(void 0,i),o)},s)});function o(e){return s.push(e),s}}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"./when":32}],31:[function(t,i,n){!function(e){e(function(e){var t=e("./when");return function(e,i){return t(i).timeout(e)}})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"./when":32}],32:[function(t,i,n){!function(e){"use strict";e(function(e){var t=e("./lib/decorators/timed"),i=e("./lib/decorators/array"),n=e("./lib/decorators/flow"),s=e("./lib/decorators/fold"),o=e("./lib/decorators/inspect"),r=e("./lib/decorators/iterate"),a=e("./lib/decorators/progress"),l=e("./lib/decorators/with"),c=e("./lib/decorators/unhandledRejection"),u=e("./lib/TimeoutError"),h=[i,n,s,r,a,o,l,t,c].reduce(function(e,t){return t(e)},e("./lib/Promise")),d=e("./lib/apply")(h);function p(e,t,i,n){var s=h.resolve(e);return arguments.length<2?s:s.then(t,i,n)}function g(e){return new h(e)}function f(e){return function(){for(var t=0,i=arguments.length,n=new Array(i);t<i;++t)n[t]=arguments[t];return d(e,this,n)}}function m(e){for(var t=0,i=arguments.length-1,n=new Array(i);t<i;++t)n[t]=arguments[t+1];return d(e,this,n)}function _(){return new v}function v(){var e=h._defer();function t(t){e._handler.resolve(t)}function i(t){e._handler.reject(t)}function n(t){e._handler.notify(t)}this.promise=e,this.resolve=t,this.reject=i,this.notify=n,this.resolver={resolve:t,reject:i,notify:n}}function b(e){return e&&"function"==typeof e.then}function y(){return h.all(arguments)}function w(e){return p(e,h.all)}function C(e){return p(e,h.settle)}function x(e,t){return p(e,function(e){return h.map(e,t)})}function k(e,t){return p(e,function(e){return h.filter(e,t)})}return p.promise=g,p.resolve=h.resolve,p.reject=h.reject,p.lift=f,p.try=m,p.attempt=m,p.iterate=h.iterate,p.unfold=h.unfold,p.join=y,p.all=w,p.settle=C,p.any=f(h.any),p.some=f(h.some),p.race=f
1(h.race),p.map=x,p.filter=k,p.reduce=f(h.reduce),p.reduceRight=f(h.reduceRight),p.isPromiseLike=b,p.Promise=h,p.defer=_,p.TimeoutError=u,p})}("function"==typeof e&&e.amd?e:function(e){i.exports=e(t)})},{"./lib/Promise":8,"./lib/TimeoutError":10,"./lib/apply":11,"./lib/decorators/array":12,"./lib/decorators/flow":13,"./lib/decorators/fold":14,"./lib/decorators/inspect":15,"./lib/decorators/iterate":16,"./lib/decorators/progress":17,"./lib/decorators/timed":18,"./lib/decorators/unhandledRejection":19,"./lib/decorators/with":20}]},{},[1])(1)}()},18024(e,t,i){"use strict";var n=i(80160).extend({defaults:{visible:!0,active:!1}});e.exports=n},18356(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(81515),r=i(28017),a=i(49779),l=i(21189),c={_getCurrentTumblelog:function(){var e="",t=r.get("Context/userinfo");return t&&s.each(t.channels,function(t){t.is_current&&(e=t.name)}),e},block:function(e){e=e||{};var t={};return t.tumblelog=e.currentTumblelog||this._getCurrentTumblelog(),e.blockedTumblelog?t.blocked_tumblelog=e.blockedTumblelog:e.blockedPost&&(t.blocked_post=e.blockedPost),e.context&&(t.block_context=e.context),n.ajax({url:"/svc/block/add",type:"POST",data:t,withFormKey:!0})},unblock:function(e){e=e||{};var t={};return t.tumblelog=e.currentTumblelog||this._getCurrentTumblelog(),t.blocked_tumblelog=e.blockedTumblelog,n.ajax({url:"/svc/block/remove",type:"POST",data:t,withFormKey:!0})},confirmBlock:function(e){var t,i=(e=e||{}).currentTumblelog||this._getCurrentTumblelog(),n=l.defer();if(e.blockedTumblelog)t=o("%1$sAre you sure you want to block %2$s from %3$s?%4$sThey won't be able to follow %3$s, send %3$s messages, see %3$s in search results, or interact with any of %3$s's posts.%5$s","<h3>",e.blockedTumblelog,i,"</h3><small>","</small>");else{if(!e.blockedPost)return n.reject(),n.promise;t=o("%1$sBlock messages from this sender?%2$sAny further messages sent from their IP address will be blocked from your inbox. This can't be undone, by the way.%3$s","<h3>","</h3><small>","</small>")}return a.confirm(t,function(){n.resolve(e.blockedTumblelog?e.blockedTumblelog:e.blockedPost)},function(){n.reject()},o("Block"),o("Nevermind")),n.promise.catch(s.noop),n.promise}};e.exports=c},18398(e,t,i){"use strict";var n=i(55679),s=i(27513),o=i(85252),r=i(21189),a=s.extend({model:o,_listenToUploadModel:function(e){this.listenTo(e,"change",this._onUploadModelChange)},_stopListeningToUploadModel:function(e){this.stopListening(e)},_onUploadModelChange:function(e){n.has(e.changed,"complete")&&this.trigger("complete",this,e),n.has(e.changed,"error")&&e.get("error")&&this.trigger("error",this,e),n.has(e.changed,"complete")&&this.allComplete()&&this.trigger("allComplete",this)},add:function(e){return n.isArray(e)?n.forEach(e,this._listenToUploadModel,this):this._listenToUploadModel(e),s.prototype.add.apply(this,arguments)},remove:function(e){return n.isArray(e)?n.forEach(e,this._stopListeningToUploadModel,this):this._stopListeningToUploadModel(e),s.prototype.remove.apply(this,arguments)},removeIncomplete:function(e){var t=this.where({uploading:!1,complete:!1});return this.remove(t,e)},removeFailed:function(e){var t=this.filter(function(e){return e.get("error")});return this.remove(t,e)},allComplete:function(){return!!this.length&&this.every(function(e){return e.get("complete")})},anyUploading:function(){return this.length>0&&this.any(function(e){return e.get("uploading")})},getProgress:function(){var e=0,t=0;return this.forEach(function(i){i.get("error")&&(e+=i.get("bytesLoaded")||0,t+=i.get("bytesTotal")||0)}),t?e/t:0},promise:function(){if(this.allComplete())return r.resolve(this);var e=r.promise(n.bind(function(e,t){var i,s;i=n.bind(function(){this.stopListening(this,"uploads:allComplete",i),this.stopListening(this,"uploads:error",s),e.apply(this,arguments)},this),s=n.bind(function(){this.stopListening(this,"uploads:allComplete",i),this.stopListening(this,"uploads:error",s),t.apply(this,arguments)},this),this.listenToOnce(this,"uploads:allComplete",i),this.listenToOnce(this,"uploads:error",s)},this));return e}});e.exports=a},18486(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div data-subview=\"networkView[]\"></div><div data-subview=\"networksLoaderView\"></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},18675(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(71742),r=i(27496),a=i(95349),l=i(99098),c=i(4127),u=o.extend({name:"YamPlusAd",counter:1,adConfiguration:{name:"LREC",sp:1197719223,ps:"LREC",ssl:1},initialize:function(e){this.listenTo(r,"darla:ready",this.setupFirstAd),this.listenTo(r,"darla:failure",this.checkAdexist),this.listenTo(r,"darla:success",this.checkAdexist),this.listenTo(r,"component:YamPlusAd",this.setupAd),window.DARLA_CONFIG||this.setupDarla()}
1,$placeholderFor:function(e){return s("#yam-plus-ad-units-"+e)},canServeAds:function(){return window.DARLA},checkAdexist:function(e){if(this.canServeAds()&&e){var t=e[0].replace("LREC",""),i=this.$placeholderFor(t);0===i.find(".darla").length&&i.parents(".yamplus-unit-container").remove()}},setupDarla:function(){window.DARLA_CONFIG=l(this.setupFirstAd(!0)),c()},setupFirstAd:function(e){var t=s(".yam-plus-ad-container, .sidebar-ad-content").eq(0);if(!t.length)return null;var i={dest:t.find(".yam-plus-ad-target").attr("id"),id:t.attr("data-yam-ad-id")};return e?i:this.setupAd(i)},setupAd:function(e){if(this.counter=this.counter+1,a.logSaw(this.name,"setupAd",window.DARLA),!this.canServeAds())return a.logSaw(this.name,"Cannot serve ads -- NO DARLA"),!1;e=n.defaults(e,{asz:"300x250",w:"300",h:"250",pos:"LREC-"+this.counter,id:!1,dest:!1,fdb:!0});var t=n.defaults({name:"LRECP"},this.adConfiguration);return a.logSaw(this.name,"DARLA.add",t),window.DARLA.add(t),window.DARLA.isAutoOn()||window.DARLA.startAuto(),window.DARLA.event("AUTO"),!0}});e.exports=u},19061(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(36452),r=i(96187),a=i(98237),l=o.extend({tagName:"form",className:"external-network-embed-subview external-network-form-subview",defaults:{embedCode:null},mixins:[a],events:{"click [data-js-embed-code]":"_onEmbedCodeClick"},template:r,getTitle:function(){return s("Embed")},getTemplateData:function(){return{embedCode:this.get("embedCode")}},afterRender:function(){n.defer(n.bind(this.selectEmbedCode,this))},selectEmbedCode:function(){var e=this.js$("embed-code");e.focus(),e.select()},_onEmbedCodeClick:function(e){this.selectEmbedCode()}});e.exports=l},19118(e,t,i){"use strict";var n=i(55679),s=i(21189),o=i(48357).animate,r=i(9045),a=i(67127),l=i(73885),c=i(71092),u=(i(95349),i(64491)),h=i(98237),d=i(38578),p=i(98044),g=i(70962),f=i(37068),m=c.extend({mixins:[u,h,d,l],template:f,defaultOptions:{animateDuringPrepare:!0,animateHeightWithContent:!1,startHeight:null,useLoader:!0,loaderDelay:250,transitionBackground:!1},defaults:{minHeight:!1,pretransition:!1,midtransition:!1},initialize:function(e){e instanceof c&&(e={postForm:e}),this.options=e=n.extend({},this.defaultOptions,e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),e.postForm&&this.setPostForm(e.postForm),this.listenTo(this,"change:minHeight",this._onChangeMinHeight),this.listenTo(this,"change:pretransition",this._onChangePretransition),this.listenTo(this,"change:midtransition",this._onChangeMidtransition)},_onChangeMinHeight:function(e,t){o(this.$el,"stop"),t||n.isNumber(t)?o(this.$el,{"min-height":t},{duration:a(Math.min(Math.max(250,t),750))}):(t=n.parseInt(this.$el.css("min-height"),10)||0,o(this.$el,{"min-height":[0,t]},{duration:a(Math.min(Math.max(250,t),750))}).then(n.bind(function(){this.$el.css("min-height","")},this)))},_onChangePretransition:function(e,t){t?this.$el.addClass("post-form-container-pretransition"):this.$el.removeClass("post-form-container-pretransition")},_onChangeMidtransition:function(e,t){t?this.$el.addClass("post-form-container-transition"):this.$el.removeClass("post-form-container-transition")},setPostFormComponent:function(e){if(this._postFormComponent!==e)return this._postFormComponent&&this.stopListening(this._postFormComponent),this._postFormComponent=e,this.postForm=e.postForm,this},prepare:function(e){return this.isRendered()||this.render(),this.trigger("prepared",this),this.loadingDelay=n.delay(n.bind(function(){this.loader&&this.options.useLoader&&this.loader.set("loading",!0)},this),this.options.loadingDelay),this.options.animateDuringPrepare&&(this._hideOriginalContent=this.hideOriginalContent(e).then(n.bind(function(){return this._hideOriginalContent=!1,this},this))),s.resolve(this)},attach:function(e){return this.loader&&(clearTimeout(this.loadingDelay),this.loader.set("loading",!1)),this.set("pretransition",!0),this.postForm.forceHidden(),this.attachSubView(this.postForm,"postForm"),s.resolve(this)},hideOriginalContent:function(e){var t=this.options.startHeight||this.originalContent.measureHeight(),i=this.postForm.measureHeight();return t||this.options.originalContent||(t=i),r([function(){null!=t&&this.$el.css("height",t),this.set("midtransition",!0),this.originalContent.set("enabled",!1)},function(){return s.join(e(),this.originalContent.animateHide(a(100)))}],this)},showPostForm:function(e){var t=this.options.startHeight||this.originalContent.measureHeight(),i=this.postForm.measureHeight();return t||this.options.originalContent||(t=i),r([function(){if(!this.options.animateHeightWithContent&&!this.originalContent.get("hidden"))return this._hideOriginalContent||this.hideOriginalContent(e)},function(){var n=[];return this.options.animateHeightWithContent&&!this.originalContent.get("hidden")&&n.push(this._hideOriginalContent||this.hideOriginalContent(e)),null==i||null==t||(i===t?this.$el.height(i):n.push(o(this.$el,{height:[i,t]},{duration:a(150),easing:[.4,1.3,.7,1]}))),s.all(n)},function(){return this.set("placeholder",!1),this.postForm.animateShow(a(100))},function(){this.set("pretransition",!1),this.set("midtransition",!1),this.$el.css("height","")}],this)},hidePostForm:function(e){var t=this.postForm.measureHeight(),i=this.originalContent.measureHeight();return i||this.options.originalContent||(i=t),r([function(){this.$el.css("height",t),this.set("midtransition",!0)},function(){return this.postForm.animateHide(a(100))},function(){if(this.set("pretransition",!0),null==i||null==t)0;else{if(i!==t)return o(this.$el,{height:[i,t]},{duration:a(100),easing:[0,0,.6,1]});this.$el.height(i)}},function(){return s.join(e(),this.originalContent.animateShow(a(50)))},function(){this.set("midtransition",!1),this.set("pretransition",!1),this.$el.css("height",""),this.originalContent.set("enabled",!0)}],this)},serialize:function(){return{originalContent:!!this.options.originalContent,transitionBackgroun
1d:this.options.transitionBackground}},beforeRender:function(){this.loader||(this.loader=new g),this.originalContent||(this.options.originalContent instanceof p?this.originalContent=this.options.originalContent:this.originalContent=new p({el:this.options.originalContent})),this.originalContent.$el.detach()},render:function(){return this.$el.html(this.template(this.serialize())),this.subViews.originalContent=this.originalContent,this.subViews.loader=this.loader,this.subViews.postForm=this.postForm,this.attachSubViews(),this},afterRender:function(){return this.$el.addClass("post-forms-above-glass is_persistent"),this.renderSubViews()},beforeTeardown:function(){return this.subViews.loader=null,this},afterTeardown:function(){return this.$el.removeClass("post-forms-above-glass post-form-container-pretransition post-form-container-transition is_persistent"),this.loader&&(this.loader.remove(),this.loader=null),this.$el.children(".post-transition-background").remove(),delete this.postForm,this.trigger("torndown",this),this.teardownSubViews()}});e.exports=m},19124(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(71092).extend({el:"body",defaults:{},events:{"change .flat_select select":"__selectChange"},__selectChange:function(e){var t=n(e.currentTarget);this.updateSelect(t)},initialize:function(e){this.options=s.extend({},this.defaults,e)},updateSelect:function(e){e.siblings("label").text(e.find(":selected").text())}});e.exports=o},19188(e,t,i){var n=i(55679),s=i(74692),o=i(51342),r=i(12461),a=i(58521),l=i(33595),c=i(37673),u=i(31710),h=i(47640),d=function(){var e="<span>&#8203;</span>",t=/\u200B/g,i=16,d=13,p=8,g=46,f=function(e,t){if(!e)throw new Error("A valid element parameter is required to initalize the editor");this.element=e,this.keyComboEvents=t.keyComboEvents||new u({element:this.element}),this.keyComboEvents.on("meta+b meta+i meta+k meta+u",n.noop),this.config={placeholder:!1,onChange:function(){},onSelection:function(e){},onClientEvent:function(e){},pasteHook:function(e,t){return!1},filterForSetData:function(e){return e},filterForGetData:function(e){return e},filterRules:{elements:["p","br","div"],attributes:{},remove_contents:["style","noscript","script","meta"],protocols:{}},forceSingleLine:!1,smartQuotes:{enabled:!1,config:{}}},n.extend(this.config,t||{}),this.dataFilter=new o(this.config.filterRules),this.onChange=function(){this.previousRawData!==x.call(this)&&(w.call(this),b.call(this),this.config.onChange.apply(this,arguments),this.previousRawData=x.call(this))},this.keyModifiers={shift:!1},this.undoManager=new l(this),this.config.smartQuotes.enabled&&(this.smartQuoter=new c(this)),m.call(this)};function m(){C.call(this,e);var t=s("<div />",{"data-js":"editor-wrapper",class:"editor-wrapper"}).css("position","relative"),i=s("<div />",{"data-js":"editor-slot",class:"editor-slot"}).css("position","relative");s(this.element).wrap(t).wrap(i),this.placeholderElement=s("<div />",{"data-js":"editor-placeholder",class:"editor-placeholder"}).css("position","absolute"),(i=s(this.element).parent()).append(this.placeholderElement),b.call(this),_.call(this)}function _(){var e=this,t=function(){E.call(this),v.call(this),this.onChange()};s(this.element).on("input keydown keyup keypress mousedown mouseup",function(t){e.config.onClientEvent.call(e,t)}),s(this.element).on("keydown",function(t){if(t.keyCode===i)e.keyModifiers.shift=!0;else if(t.keyCode===p)F.call(e);else if(t.keyCode===d)return e.config.forceSingleLine||t.metaKey||S.call(e,this,!1),void t.preventDefault();n.defer(function(){e.onChange(t)})}),s(this.element).on("keyup",function(s){s.keyCode===i?e.keyModifiers.shift=!1:s.keyCode===d?F.call(e):s.keyCode!==p&&s.keyCode!==g||n.defer(function(){F.call(e)}),t.call(e)}),s(this.element).on("input",function(i){t.call(e)}),s(this.element).on("blur",function(t){e.onChange()});var o=!1;s(this.element).on("mouseup",function(){o=!1,v.call(e)}),s(this.element).on("mousedown",function(e){o=!0}),s(this.element).on("mouseleave",function(){o&&v.call(e)}),s(this.element).on("paste",function(t){var i=(t.originalEvent||t).clipboardData;e.config.pasteHook(i,e.keyModifiers.shift)||y.call(e,i,t),t.preventDefault()}),s(this.element).on("drop",function(e){e.stopPropagation(),e.preventDefault()}),this.placeholderElement.on("click",function(){e.isEmpty()&&s(e.element).focus()}),s(this.element).on("focus",function(){n.defer(function(){e.onChange()})})}function v(){var e=this;setTimeout(function(){var t=a.getSelection();e.config.onSelection.call(e,t)},200)}function b(){var e=this.isEmpty()?this.config.placeholder:"",t=s(this.placeholderElement);t.html(e);var i=t.outerHeight();i&&s(this.element).css("min-height",Math.max(parseInt(t.css("min-height"),10)||0,i))}function y(e,t){var i="";if(n.contains(e.types,"text/plain"))i=e.getData("text/plain"),i=this.dataFilter.filterPlaintext(i),k.call(this,i);else{if(!n.contains(e.types,"text/html"))return;i=e.getData("text/html");var s=(i=this.dataFilter.filterHTML(i)).replace(/<br(\s*)\/*>/gi,"\n").replace(/(<[p|div])/gi,"\n$1"),o=document.implementation.createHTMLDocument("");o.body.innerHTML=s;var r=o.body,a=(r.textContent||r.innerText||"").split("\n").join("<br>");k.call(this,a)}if(this.config.forceSingleLine){var l=x.call(this).replace(/<br\s*\/*>/g," ");C.call(this,l)}this.onChange(t)}
1function w(){s(this.element).contents().filter(function(){return 3===this.nodeType}).wrap("<span></span>")}function C(e){s(this.element).html(e)}function x(){return s(this.element).html().trim()}function k(e){if(e=e.replace(/[<]br\s?\/?[>]$/,""),e=this.dataFilter.convertToBrowserSpaces(e)){var t=a.getSelection();if(t&&t.focusNode){var i=t.getRangeAt(0);i.deleteContents();var n=i.createContextualFragment(e);i.insertNode(n),t.removeAllRanges(),i.collapse(!1),t.addRange(i)}else h.warn("Cannot insert without the editor having a cursor or selection")}else h.warn("Cannot insert empty data")}function S(e,t){t||e.lastChild&&"br"===e.lastChild.nodeName.toLowerCase()||e.appendChild(document.createElement("br"));var i=a.getSelection();if(i){var n=i.getRangeAt(0),s=document.createElement("br");n.deleteContents(),n.insertNode(s),n.setStartAfter(s),n.setEndAfter(s),n.collapse(!1),i.removeAllRanges(),i.addRange(n)}}function T(e){s(e).contents().each(function(e,i){i.nodeType===Node.TEXT_NODE?i.textContent=i.textContent.replace(t,""):i.nodeType===Node.ELEMENT_NODE&&T(i)})}function E(){if(!this.isEmpty()){var e=P.call(this);if(e&&e.nodeType===Node.ELEMENT_NODE){var i=e.textContent||e.innerText||"";if(i.match(t)){var n=r.saveSelection(e);n.start-=(i.substr(0,n.start).match(t)||"").length||0,n.end-=(i.substr(0,n.end).match(t)||"").length||0,T(e),r.restoreSelection(n)}}}}function P(){var e=I.call(this);if(!e){var t=s(this.element).children();if(!t.length)return null;e=t.last().get(0)}return e}function I(e){return e||(e=!a.getSelection()&&this.lastSelection?a.getParentNodes(this.lastSelection.anchorNode):a.getNodeList()),n.find(e.reverse(),function(e){return e.nodeType===Node.ELEMENT_NODE})}function F(){this.isEmpty()&&(C.call(this,e),this.setCursorToEnd())}return f.prototype.getData=function(e){var i=x.call(this),n=(i=this.config.filterForGetData.call(this,i)).replace(/<br(\s*)\/*>/gi,"\n").replace(/(<[p|div])/gi,"\n$1").replace(t,""),s=document.createElement("div");s.innerHTML=n;var o=s.textContent||s.innerText||"";return e?o.trim():o},f.prototype.setData=function(e){e=this.config.filterForSetData.call(this,e),e=this.dataFilter.filterPlaintext(e),C.call(this,e),F.call(this),this.onChange()},f.prototype.setHTML=function(e){C.call(this,e),this.onChange()},f.prototype.getHTML=function(){return x.call(this)},f.prototype.insertData=function(e,t){t&&(e=this.dataFilter.filterHTML(e)),k.call(this,e),this.onChange()},f.prototype.blur=function(){return s(this.element).blur()},f.prototype.focus=function(e){var t=s(this.element).focus();return e||this.setCursorToEnd(),t},f.prototype.hasFocus=function(){return s(this.element).is(":focus")},f.prototype.setPlaceholder=function(e){this.config.placeholder=e,b.call(this)},f.prototype.isEmpty=function(){var t=this.getData(!1);if(""===t||"\n"===t||"\r\n"===t)return!0;var i=x.call(this);return i===e||"<span>​</span>"===i||""===i},f.prototype.getCurrentElement=function(){return a.getNearestElement()},f.prototype.setCursorToStart=function(e){var t=s(this.element);(e=e&&t.find(e).first().get(0)||t.children().first().get(0))&&r.setToStart(e)},f.prototype.setCursorToEnd=function(e){var t=s(this.element);(e=e&&t.find(e).last().get(0)||t.children().last().get(0))&&r.setToEnd(e)},f.prototype.teardown=function(){this.undoManager.teardown(),this.keyComboEvents.off()},f}();e.exports=d},19223(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(38578),r=i(89934),a=s.extend({mixins:[o],template:r,initialize:function(e){n.extend(this.attributes,e)},render:function(){return this.$el.html(this.template(this.toJSON())),this}});e.exports=a},19254(e,t,i){"use strict";var n=i(8925),s=i(64119),o=n.extend({className:n.prototype.className+" blog-search-autocomplete-popover",bindEvents:function(){n.prototype.bindEvents.apply(this,arguments),this.listenTo(this,"itemSelected",this.subview.selectTerm)},Subview:s});e.exports=o},19407(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p +=\n__e( __('Add GIF') );\n\n}\nreturn __p\n}").apply(void 0,r(s))},19452(e,t,i){"use strict";var n=i(80160).extend({idAttribute:"namespace",defaults:{namespace:null,view:null,isActive:!0}});e.exports=n},19698(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(21189),r=i(71742),a=i(36452),l=r.extend({name:"BaseExternalNetwork",
1initialize:function(e){s.extend(this.attributes,s.pick(e,s.keys(this.defaults))),s.extend(this,s.pick(e,"postModel"))},getName:function(){return null},getLabel:function(){return null},getType:function(){return l.TYPE_POPUP},getPopupUrl:function(){return null},getPopupOptions:function(){return null},getSubviewConstructor:function(){return null},getSubviewOptions:function(){return null},getButtonHref:function(){return null},onClickHandler:function(e){},getPostModel:function(){return this.postModel},getPostUrl:function(){return this.postModel.get("post_url")},getPostTinyUrl:function(){return this.postModel.get("post_tiny_url")},getShareUrl:function(){return"/svc/share/"+this.getName()},isTypePopup:function(){return this.isTypeEqual(l.TYPE_POPUP)},isTypeSubview:function(){return this.isTypeEqual(l.TYPE_SUBVIEW)},isTypeCallback:function(){return this.isTypeEqual(l.TYPE_CALLBACK)},isTypeHref:function(){return this.isTypeEqual(l.TYPE_HREF)},isTypeEqual:function(e){return this.getType()===e},createSubviewInstance:function(e){var t,i;return t=this.getSubviewConstructor(),s.isEmpty(t)?null:t.prototype instanceof a?(i=new t(s.extend({},this.getSubviewOptions(),e)),this.listenToOnce(i,"remove",function(e){this.stopListening(e),this.afterSubviewRemoved(e)}),this.listenTo(i,"share",function(e,t){this.onSubviewShare(e,t)}),this.afterSubviewCreated(i),i):null},getSubviewInstance:function(e){var t=o.defer(),i=this.createSubviewInstance(e);return s.isEmpty(i)?t.reject("Could not create external network subview (subview constructor must extend ExternalNetworkEmbedSubview)."):t.resolve(i),t.promise},getShareRequestDataFromSubviewData:function(e){return e},sendShareRequest:function(e){return n.ajax({url:this.getShareUrl(),method:"POST",withFormKey:!0,data:e})},onSubviewShare:function(e,t){var i=this.getShareRequestDataFromSubviewData(e),n=s.extend({},this._getBaseShareRequestData(),i);return this._beforeShare(t,e),this.sendShareRequest(n).then(s.bind(function(){this._afterShareSuccess(t,e),this._afterShare(t,e)},this)).fail(s.bind(function(){this._afterShareFail(t,e),this._afterShare(t,e)},this))},afterSubviewCreated:function(e){},afterSubviewRemoved:function(e){},_getBaseShareRequestData:function(){var e=this.getPostModel(),t={post_id:e.get("post_id"),tumblelog_name:e.get("tumblelog_name")};return this.isTypeSubview()||s.extend(t,{share_fallback:!0}),t},_beforeShare:function(e,t){e.set({isSharing:!0,isShareSuccess:!1,isShareFail:!1}),this.trigger("share:start")},_afterShareSuccess:function(e,t){e.set({isShareSuccess:!0,isShareFail:!1}),e.onShareSuccess(t),this.trigger("share:success")},_afterShareFail:function(e,t){e.set({isShareFail:!0,isShareSuccess:!1}),e.onShareFail(t),this.trigger("share:fail")},_afterShare:function(e,t){e.set("isSharing",!1),e.afterShare(t),this.trigger("share:finished")}},{TYPE_POPUP:"popup",TYPE_SUBVIEW:"subview",TYPE_CALLBACK:"callback",TYPE_HREF:"href"});e.exports=l},19951(e,t,i){"use strict";var n=i(27513),s=i(70201),o=n.extend({model:s,comparator:function(e){return e.get("width")}});e.exports=o},20341(e,t,i){"use strict";var n=i(55679);e.exports=function(e){return n.isFunction(e.serialize)?e.serialize():n.isFunction(e.toJSON)?e.toJSON():void 0}},20833(e){function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t(e)}e.exports=function e(i){var n,s;for(s in Object.freeze(i),i)n=i[s],i.hasOwnProperty(s)&&null!==n&&"object"===t(n)&&!Object.isFrozen(n)&&e(n)}},20851(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div data-subview=\"blogSelector\" class=\"blog-selector\"></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},20948(e,t,i){"use strict";var n=i(55679),s=i(27496),o=i(44890),r=i(50283),a=i(86232),l=i(16400),c=i(80158),u=r.extend({template:l,className:"messaging-popover-icon nav_icon",events:{click:"_onIconClick"},initialize:function(e){this.options=n.extend({},this.defaults,e),n.extend(this,n.pick(e,"model"))},subviews:{statusIndicator:{constructor:c,options:function(e){return{isOnline:e.model.get("isOnline"),canSeeUIFlag:o.bool("status_indicator"),name:e.model.get("name")}}}},showPopover:function(){this.popover||(this.popover=new a({pinnedTarget:this.$el,model:this.model,preventInteraction:!0}),this.popover.render(),this.listenTo(this.popover.getView(),"messagingSelected",this._onMessagingSelected),this.listenTo(this.popover.getView(),"askSelected",this._onAskSelected),this.listenTo(this.popover,"close",this._onPopoverClose))},openMessaging:function(){s.trigger("messaging:conversation:open:tumblelogs",[this.model],"peepr")},openAsk:function(){s.trigger("ask:form:open",{recipient:this.model.get("name"),allow_anonymous:this.model.get("anonymous_asks")})},_onIconClick:function(){this.openMessaging(),(this.model.get("asks")||this.model.get("submissions"))&&this.showPopover()},_onMessagingSelected:function(){this.openMessaging()},_onAskSelected:function(){this.openAsk()},_onPopoverClose:function(){this.stopListening(this.popover),this.stopListening(this.popover.getView()),this.popover=null}});e.exports=u},21100(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(2078),r=i(28017),a=i(27496),l=i(80867),c=i(44890),u=i(83195),h=i(8155),d=i(4419),p=i(73026),g=i(43606),f=i(23062),m=i(28497),_=i(29016),v=i(50695),b=i(62822),y=i(38904),w=u.extend({templates:{layout:m,success:_,error:v},className:"abuse-form",attributes:{"aria-role":"dialog",tabIndex:-1},survey:y,initialize:function(e){e=e||{},u.prototype.initialize.call(this,e),this.set("mobileMode",e.mobileMode||!1),this.listenTo(a,"drawer:close",this.teardown),s.bindAll(this,"render","afterRe
1nder");var t=this;if(this.render=s.wrap(this.render,function(e){return e(),t.afterRender(),t}),this.contexts=w.CONTEXTS,e.mode)switch(this.mode=e.mode,this.mode){case"standalone":var i=e.formType;e.formType&&this.survey[i]||(i="abuse"),this.set("surveyStep",i),e.tumblelog&&(this.tumblelog=new l({name:e.tumblelog})),this.postData=e.postData;break;case"community":e.tumblelog&&(this.tumblelog=new l({name:e.tumblelog})),this.set("surveyStep","community-abuse");break;case"blogcard":this.set("surveyStep","start"),this.tumblelog=new l({name:e.tumblelog}),this.posts=this.getBlogcardPosts();break;case"post":this.set("surveyStep","start"),this.tumblelog=new l({name:e.post.get("tumblelog_name")}),this.posts=[{id:e.post.get("post_id"),rootId:e.post.get("root_id"),postUrl:e.post.get("post_url")}],this.embedCode=e.post.get("embed_code");break;case"chat_message":case"chat":i=e.formType;e.formType&&this.survey[i]&&"start"!==i||(i="abuse"),"harassment-self-where"===s.get(y,"harassment-self-psa.options[0].to")&&s.set(y,"harassment-self-psa.options[0].to","harassment-self-blog"),this.set("surveyStep",i);break;case"message":this.set("surveyStep","start"),this.sender=e.sender&&new l({name:e.sender}),e.postData?(this.tumblelog=new l({name:e.postData.tumblelog_name}),this.posts=[{id:e.postData.post_id,rootId:e.postData.post_id,postUrl:e.postData.post_url}]):(this.tumblelog=new l({name:e.post.get("tumblelog-name")}),this.posts=[{id:e.post.get("id"),rootId:e.post.get("root_id"),postUrl:e.post.get("post_url")}]);break;default:this.mode="standalone",this.set("surveyStep","abuse")}else this.mode="standalone",this.set("surveyStep","abuse");this.fillTemplateAttributes()},teardown:function(){n("body").removeClass("abuseform-open"),this.selfDestroyTimer&&(clearTimeout(this.selfDestroyTimer),this.selfDestroyTimer=null)},fillTemplateAttributes:function(){var e=r.get("Components/AbuseForm")||{};if(this.set("nativeApp",e.native_app||!1),this.templateAttributes.Flags=c,this.templateAttributes.recaptcha=e.recaptcha,this.templateAttributes.email=e.email,this.templateAttributes.lang=e.lang,this.templateAttributes.languageNotice=e.language_notice,this.templateAttributes.formToken=e.form_token,this.templateAttributes.safesearch=n(".nsfw_filter_enabled").length,this.templateAttributes.tumblelog=this.tumblelog,this.templateAttributes.posts=this.posts,this.templateAttributes.mode=this.mode,this.templateAttributes.hideTitles="standalone"===this.mode||"chat_message"===this.mode,this.templateAttributes.inNativeApp=!!this.get("nativeApp"),this.templateAttributes.is_eu=e.is_eu,this.templateAttributes.is_brazil=e.is_brazil,this.templateAttributes.child_exploitation_visible=e.child_exploitation_visible,this.templateAttributes.is_ncii_visible=e.is_ncii_visible,this.templateAttributes.prefillFields=e.prefill_fields,"community"===this.templateAttributes.prefillFields.context){var t=this.templateAttributes.prefillFields.tumblelog,i="".concat(t);this.templateAttributes.prefillFields.urlreporting=i}if(this.templateAttributes.prefillFields){if(s.delay(function(){a.trigger("drawerform:validation:trigger")}),this.templateAttributes.prefillFields.urlreporting){var o=this.templateAttributes.prefillFields.urlreporting;b.isReportableTumblrUrl(o)||(this.templateAttributes.prefillFields.urlreporting="")}if(this.templateAttributes.prefillFields.email){var l=this.templateAttributes.prefillFields.email;b.isEmail(l)||(this.templateAttributes.prefillFields.email="")}}this.tumblelog&&(this.templateAttributes.tumblelogUrl=this.tumblelog.get("url")),this.templateAttributes.sender=this.sender,this.templateAttributes.supportsFileChooser=this.supportsFileChooser()},getBlogcardPosts:function(){var e=this.tumblelog.get("highlighted_post"),t=[];return s.each(e,function(e){e=n(e),t.push({id:e.data("id"),rootId:e.data("root_id"),postUrl:e.data("json").share_popover_data.post_url})},this),t},getFlaggedContent:function(){switch(this.mode){case"post":case"message":return n('.post[data-post-id="'+this.posts[0].id+'"]').first();case"blogcard":var e=n(".indash_header_wrapper.tumblelog_name_"+this.tumblelog).first();return 0===e.find(".recent_posts").length&&(e=e.closest(".popover")),e}},hideFlaggedContent:function(){var e=this.getFlaggedContent();e&&e.addClass("is_flagged")},displaySuccessMessage:function(){this.templateAttributes.customSuccessMessage=!1,this.survey[this.get("surveyStep")].customSuccessMessage&&(this.templateAttributes.customSuccessMessage=this.survey[this.get("surveyStep")].customSuccessMessage),this.templateAttributes.alternativeResponseText=this.get("surveyStep").indexOf("someoneelse")>=0,this.$el.html(this.templates.success(this.templateAttributes)),a.trigger("drawer:disableCloseConfirmation"),this.selfDe
1stroyTimer&&clearTimeout(this.selfDestroyTimer),this.selfDestroyTimer=setTimeout(function(){a.trigger("abuseform:close"),a.trigger("Kraken:abuseform:close")},15e3)},displayErrorMessage:function(e){this.removeErrorMessage(),this.errorMessage=n(this.templates.error(s.extend(this.templateAttributes,{errors:e}))),this.errorMessage.appendTo(this.$surveyStep);var t=this.errorMessage.get(0);t&&t.scrollIntoView({behavior:"smooth"})},removeErrorMessage:function(){this.errorMessage&&(this.errorMessage.remove(),this.errorMessage=null)},getPlatform:function(){return this.get("nativeApp")?this.get("nativeApp"):this.get("mobileMode")?"mobileweb":"web"},logSubmission:function(e){(e=e||{}).reason||(e.reason=this.get("surveyStep")),e.blocked=this.get("blockFlagSet"),e.platform=this.getPlatform(),a.trigger("Kraken:abuseform:submitted",{loggingData:e}),this.get("blockFlagSet")&&a.trigger("Kraken:blocks:block_added",{loggingData:{from:"abuseform"}})},update_description:function(e){this.header.remove(),this.header=new h({title:e.title,description:e.description,inNativeApp:this.templateAttributes.inNativeApp}),this.header.render().$el.insertBefore(this.$surveyContainer)},render:function(){return this.$el.append(this.templates.layout(this.templateAttributes)),this.$surveyContainer=this.$(".survey"),this.$surveyStep=this.$(".survey-step"),n("body").addClass("abuseform-open"),this.header=new h({title:this.survey[this.get("surveyStep")].title,description:this.survey[this.get("surveyStep")].description,inNativeApp:this.templateAttributes.inNativeApp}),this.header.render().$el.insertBefore(this.$surveyContainer),this.formView=new p({el:this.$surveyStep,abuseform:this,recaptcha:this.templateAttributes.recaptcha}),this.navigation=new f({abuseform:this}),this.dynamicfields=new g({el:this.$surveyContainer,abuseform:this}),this.surveyView=new d({el:this.$surveyContainer,abuseform:this}),this.surveyView.displaySurveyStep(this.get("surveyStep")),this},afterRender:function(){var e=this.el;setTimeout(function(){try{o.createFocusTrap(e,{initialFocus:e}).activate()}catch(e){0}},1e3)}});e.exports=w},21343(e,t,i){var n=i(32284).A;e.exports=n},21550(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(50283),r=i(59952),a=i(54269),l=o.extend({className:"popover--messaging-share-post popover popover_menu popover_gradient",mixins:[r],initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"viewOptions"))},render:function(){var e=n.isFunction(this.viewOptions)?this.viewOptions(this):this.viewOptions;return this.$wrapper=s("<div />").addClass("popover-inner popover_inner").appendTo(this.$el),this.$pinned.addClass("active"),this.sharePostView&&(this.stopListening(this.sharePostView),this.sharePostView.remove()),this.sharePostView=new a(e),this.listenToOnce(this.sharePostView,"close",this.teardown),this.$wrapper.html(this.sharePostView.render().$el),this},teardown:function(){return this.sharePostView&&this.sharePostView.remove(),this.remove()},getView:function(){return this.sharePostView}});e.exports=l},21632(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p +=\n__e( page_title );\n\n}\nreturn __p\n}").apply(void 0,r(s))},21848(e,t,i){var n=i(55679),s=i(74692),o=i(59034),r=function(){var e=function(e){e=e||{},this.openTray=e.openTray||this.openTray,this.closeTray=e.closeTray||this.closeTray,this.onTrayOpened=e.onTrayOpened||function(e){},this.onTrayClosed=e.onTrayClosed||function(e){},this.customOffset=e.customOffset||n.noop,this.keyboardEvents=e.keyboardEvents,t.call(this),o.call(this,e)};function t(){this.element=s("<div />",{class:"inline-controls"}).css({position:"absolute",top:0,left:0}),this.opener=s("<div />",{class:"opener"}),this.isTrayOpen=!1;var e=this;this.opener.on("mousedown",function(t){return t.preventDefault(),t.stopPropagation(),i.call(e,null,!0),!1}),this.tray=s("<div />",{class:"tray"}),this.element.append(this.opener),this.element.append(this.tray),this.hide()}function i(e,t){"boolean"!=typeof e&&(e=!this.isTrayOpen),e?(this.openTray.call(this,this.tray),this.isTrayOpen=!0,this.onTrayOpened.call(this,t)):(this.closeTray.
1call(this,this.tray),this.isTrayOpen=!1,this.onTrayClosed.call(this,t)),s(this.opener).toggleClass("open",this.isTrayOpen),t?s(this.opener).toggleClass("closed",!this.isTrayOpen):s(this.opener).removeClass("closed")}n.assign(e.prototype,o.prototype);var r=n.memoize(function(e,t){var i;return n.isFunction(t)?i=t.call():n.isObject(t)&&(i=t),n.pick(n.defaults(n.isObject(i)?i:{},{x:e.x||e,y:e.y||0}),["x","y"])});return e.prototype.addToTray=function(e,t){var i;t=t||{},this.tray.append(e),i=t.keyboard,this.keyboardEvents&&i&&this.keyboardEvents.on(i.shortcut,i.callback,i.context)},e.prototype.openTray=function(e){e.show()},e.prototype.closeTray=function(e){e.hide()},e.prototype.open=function(e,t){if(e){t=r(t||0,this.customOffset||0);var n=s(e).position(),o=parseInt(s(e).css("margin-top"),10)||0;i.call(this,!1),this.show(n.left+t.x,n.top+t.y+o)}},e.prototype.close=function(){i.call(this,!1),this.hide()},e.prototype.toggleTrayWithIntent=function(e){i.call(this,e,!0)},e}();e.exports=r},21987(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(81515),r=i(21189),a=i(18356),l=i(71092),c=i(38578),u=i(76156),h=l.extend({mixins:[c],events:{"change [data-flag-action]":"onFlagClick","click [data-submit-flag-form]":"onFlagFormSubmit",'change input[type="radio"]':"onInputChange",'change input[type="checkbox"]':"onInputChange","submit form":"onSubmit",'change input[name="block"]':"onBlockChange"},initialize:function(e){e=e||{},this.abuseform=e.abuseform,this.set("loading",!1),this.on("change:loading",this.updateLoadingIndicator),this.abuseform.set("blockFlagSet","message"!==this.abuseform.mode||!!this.abuseform.sender),this.abuseform.set("optionFlagSet",!1)},onBlockChange:function(e){this.abuseform.set("blockFlagSet",n(e.target).prop("checked")),this.updateFlagButton()},onInputChange:function(){var e=!1;s.each(this.$radiosAndCheckboxes,function(t){e=n(t).is(":checked")||e}),this.$submitButton.attr("disabled",!e)},onFlagFormSubmit:function(e){e.preventDefault(),this.set("loading",!0);var t=[];if(this.$form.find("[name=flag]:checked").length&&t.push(n.ajax({url:"/svc/flag",type:"POST",data:this.getFlagRequestData(),withFormKey:!0})),this.abuseform.get("blockFlagSet")){var i=this.abuseform.sender||this.abuseform.tumblelog,o=this.abuseform.tumblelog.id;t.push("Anonymous"===i.id?a.block({blockedPost:this.abuseform.posts[0].id,currentTumblelog:o}):i.block())}r.all(t).then(s.bind(this.onSubmitSuccess,this),s.bind(this.onSubmitError,this)).finally(s.bind(this.onCallComplete,this))},getFlagRequestData:function(){var e=this.$form.serializeArray(),t={};return s.each(e,function(e){t[e.name]=e.value}),"post"===this.abuseform.mode||"message"===this.abuseform.mode?(t.post_id=this.abuseform.posts[0].id,t.root_id=this.abuseform.posts[0].rootId,t.context=this.abuseform.mode):"blogcard"===this.abuseform.mode?t.context="blogcard":"standalone"===this.abuseform.mode&&this.abuseform.postData&&(t.post_id=this.abuseform.postData.post_id),this.abuseform.postData&&this.abuseform.postData.tumblelog_name?t.tumblelog_name=this.abuseform.postData.tumblelog_name:t.tumblelog_name=this.abuseform.tumblelog.get("name"),t},onSubmitSuccess:function(){this.abuseform.hideFlaggedContent();var e=this.$("form").find("input[type=radio]:checked"),t={reason:e.length?e.val():"block_only"};this.abuseform.logSubmission(t),this.abuseform.displaySuccessMessage()},onSubmitError:function(){this.abuseform.displayErrorMessage()},onCallComplete:function(){this.set("loading",!1)},onSubmit:function(e){e.preventDefault()},updateLoadingIndicator:function(){this.$submitButton.toggleClass("loading",this.get("loading"))},updateFlagButton:function(){var e=n(".chrome.flag");this.abuseform.get("blockFlagSet")&&this.abuseform.get("optionFlagSet")?e.find(".label").text(o("Flag and block")):this.abuseform.get("blockFlagSet")?e.find(".label").text(o("Block")):e.find(".label").text(o("Flag"))},onFlagClick:function(e){var t=n(e.target).data("flag-action"),i=n(".chrome.flag"),s=n(".chrome.continue");this.abuseform.set("optionFlagSet",!0),this.updateFlagButton(),"cg"===t?(i.hide(),s.show()):(i.show(),s.hide())},render:function(){return this.$el.html(u(this.abuseform.templateAttributes)),this.$form=this.$("form"),this.$submitButton=this.$("[data-submit-flag-form]"),this.$radiosAndCheckboxes=this.$('input[type="radio"], input[type="checkbox"]'),this}});e.exports=h},22538(e,t,i){var n,s=i(55679),o=i(28017);var r={get:s.memoize(function(e){n||(n=o.get("Context/hosts"));var t=s.snakeCase(e);return s.endsWith(t,"_host")||(t+="_host"),s.get(n,t)})};e.exports=r},22568(e,t,i){var n=i(55679),s=i(71742),o=i(74692),r={v:"tumblr"},a=s.extend({name:"AutomatticWebAnalytics",initialize:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=(this.data||{}).automattic_id,i=e.isBlogNetwork,n=this.getLoggingData(t,i),s=this.getImageUrl(n);this.createPixel(s)},outputDebugCode:function(e){var t=e.tid,i=e.user_id,n=0===t&&!i;console.groupCollapsed("".concat(this.name).concat(n?" (warning!)":"")),n&&console.warn("This is a non-blog-network entry without a user id. It might be fine (e.g. login page), but please make sure."),console.info(e),console.groupEnd()},getLoggingData:function(e,t){var i=n.extend({},r,{tid:t?3:0,rand:Math.round(1e7*Math.random()),_ts:Date.now(),ref:document.location.href});return e&&(i.user_id=e),i},getImageUrl:function(e){var t=o.param(e);return"".concat("/g.webp","?").concat(t)},createPixel:function(e){new Image(1,1).src=e}});e.exports=a},23043(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<p class=\"no-results-text\" style=\"color: ' +\n__e( model.themeParams.title_color ) +\n';\">' +\n((__t = ( __('Nothing here about<br/>%s.', _.escape(model.term)) )) == null ? '' : __t) +\n'</p>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},23049(e,t,i){"use strict";var n=i(44384),s=i(27496),o=i(97030),r=n.extend({events:{"click img":"toggle","click a":"_checkIfPremiumPost"},mixins:[o],initialize:function(e){n.prototype.initialize.call(this,e)},toggle:function(e){this.toggleThumbnail(),this.toggleHighres()}
1,toggleThumbnail:function(){var e=this.$el.find(".image_thumbnail");if(e.length){var t=e.hasClass("enlarged");e.toggleClass("enlarged"),e.attr("width",t?e.data("thumbnail-width"):e.data("width")),e.attr("height",t?e.data("thumbnail-height"):e.data("height"))}},toggleHighres:function(){this.$el.find(".photo_info").toggleClass("hidden")},_checkIfPremiumPost:function(e){this.model.get("pt")&&s.trigger("useraction:explore_click:caption",{model:this.model,loggingData:this.loggingData({userAction:"caption"})})}});e.exports=r},23062(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(98623),r=s.extend({className:"form-row",template:o,events:{"click [data-survey-nav-to]":"surveyLinkHandler","click [data-survey-nav-back]":"surveyBackHandler","click [data-survey-submit]":"onSubmitClick","click [data-survey-dismiss]":"onDismissClick"},initialize:function(e){e=e||{},this.abuseform=e.abuseform,this.abuseform.get("mobileMode")&&this.$el.addClass("fixed-row")},surveyLinkHandler:function(e){this.abuseform.get("mobileMode")&&this.abuseform.surveyView.surveyLinkHandler(e)},surveyBackHandler:function(e){this.abuseform.get("mobileMode")&&this.abuseform.surveyView.surveyBackHandler(e)},onSubmitClick:function(e){this.abuseform.get("mobileMode")&&this.abuseform.formView.onSubmitClick(e)},onDismissClick:function(e){this.abuseform.get("mobileMode")&&this.abuseform.formView.onDismissClick(e)},update:function(e){n.extend(e,{complete:this.abuseform.get("complete")}),this.$el.html(this.template(e)),this.abuseform.get("mobileMode")?this.$el.insertAfter(this.abuseform.$surveyContainer):this.abuseform.$surveyStep.append(this.$el)}});e.exports=r},23182(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(16016),r=s.extend({className:"conversation-message-error",template:o,defaults:{message:null,showErrorIconClass:"show-icon",showErrorIcon:!1,actionText:null},events:{"click [data-js-action]":"_onClickAction"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","actionCallback"))},getTemplateData:function(){return{message:this.get("message"),actionText:this.get("actionText")}},afterRender:function(){this.$el.toggleClass(this.get("showErrorIconClass"),this.get("showErrorIcon"))},_onClickAction:function(e){e.preventDefault(),n.isFunction(this.actionCallback)&&this.actionCallback()}});e.exports=r},23325(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(31384),r=i(80160),a=i(57982),l=i(54892),c=i(57505),u=r.extend({defaults:{url:"",preuploadUrl:"",externalUrl:"",file:null,photoRaw:null,base64:null,isSelfie:!1,isSelfieGif:!1,width:null,height:null,caption:"",id:"",livephotoUrl:"",livephotoStillImageTime:"",primaryUrl:"",iosUrl:"",androidUrl:""},initialize:function(){this.on("change:externalUrl",function(e,t){t&&this.readUrl(t),this.set({preuploadUrl:null,base64:null})},this),this.get("externalUrl")&&!this.get("base64")&&this.trigger("change:file",this,this.get("file")),this.on("change:file",function(e,t){t&&this.readFile(t),this.set({externalUrl:null,base64:null})},this),this.get("file")&&!this.get("base64")&&this.trigger("change:file",this,this.get("file"))},readUrl:function(e,t){t||(t="photo:readUrl"),a.load(e).then(n.bind(function(e){this.set({url:e.src,width:e.width,height:e.height}),this.trigger(t,!0,this)},this),n.bind(function(i){this.set({url:e,width:null,height:null}),this.trigger(t,!1,this)},this))},readFile:function(e){l.canReadFiles()?l.read(e).then(n.bind(function(e){if(!e.file.type.match(/image\/(jpg|jpeg|png)/i))return this.readUrl(e.objectUrl||e.base64,"photo:readFile");var t=s("<img/>");t.attr("src",e.objectUrl||e.base64),a.load(e.objectUrl||e.base64).then(n.bind(function(i){var n=c.drawScaledAndRotated(t,i.width,i.height,e.rotation,e.mirrored,1080);return this.readUrl(n.toDataURL(e.file.type),"photo:readFile")},this))},this),n.bind(function(){this.trigger("photo:readFile",!1,this)},this)):this.trigger("photo:readFile",!1,this)},getDisplayUrl:function(){return this.get("preuploadUrl")?this.get("preuploadUrl"):this.get("externalUrl")?this.get("externalUrl"):this.get("base64")?this.get("base64"):this.get("url")},getUploadUrl:function(){return this.get("preuploadUrl")?this.get("preuploadUrl"):this.get("externalUrl")?this.get("externalUrl"):""},parse:function(e){return o(e,0)},toJSON:function(){var e=r.prototype.toJSON.apply(this,arguments);return e.displayUrl=this.getDisplayUrl(),e.uploadUrl=this.getUploadUrl(
1),e}});e.exports=u},23463(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(19254),r=s.extend({events:{click:"showPopover",blur:"onInputBlur"},initialize:function(){this.popover=null,this.bindEvents()},bindEvents:function(){this.listenTo(this.model,"change:matchTerm",this.onMatchTermChange)},onMatchTermChange:function(){this.model.get("typeAheadMatches").length?this.showPopover():this.hidePopover()},showPopover:function(){this.model.getItems().then(n.bind(function(){!this.popover&&this.model.hasMatches()&&(this.popover=new o({pinnedTarget:this.$el,model:this.model,shift:{x:-this.getLeftOffset(),y:0},preventInteraction:!0,keycommands:!0}).render(),this.listenTo(this.popover,"close",this.onPopoverClose))},this))},getLeftOffset:function(){return this._leftOffset=this._leftOffset||this.$el.width()/2,this._leftOffset},onInputBlur:function(){n.delay(n.bind(this.hidePopover,this),100)},hidePopover:function(){this.popover&&this.popover.hide()},onPopoverClose:function(){n.defer(n.bind(function(){this.popover=null},this))}});e.exports=r},24516(e,t,i){"use strict";var n=i(55679),s=i(50283),o=s.prototype,r=i(85179),a=i(77594),l=i(1744),c=i(30321),u=i(96058),h=i(48357),d=h.animate,p=h.hook,g=i(21189),f=i(64147),m=function(e){var t=Math.round(e.position().top);return{top:t,bottom:Math.round(t+e.height())}},_=function(e,t){return!(t.bottom<e.top||t.top>e.bottom)},v=s.extend({className:"gif-search-results",template:l,mixins:[a,r],keycommands:{"keydown:down":"_onKeyPressDown","keydown:up":"_onKeyPressUp","keydown:enter":"_onKeyPressEnter"},subviews:{searchResults:{constructor:c,options:function(e){return{eventBus:e.eventBus,imageWidth:e.get("imageWidth"),onSelect:n.bind(e._onSubviewSelect,e),onClear:n.bind(e._onSubviewClear,e),loadFullImageBeforeSelect:e.get("loadFullImageBeforeSelect")}},collection:function(e){return e.collection}}},defaults:{renderBatchSize:50,renderBatchDelay:5,selectedImageUrl:"",imageWidth:null,loadFullImageBeforeSelect:!0,enablePreloading:!0,isPreloading:!1,preloadPollInterval:1e3,selectedView:null,isFocused:!1},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","collection","keyboardManager","keyboardNamespace")),this.keyboardViewName="searchResults"},setCollection:function(e){this.collection&&this.stopListening(this.collection),this.collection=e,this.eventBus.trigger("gifsearch:resultChange",this.collection),this.rendered&&this.render()},populatePreloadQueue:function(){var e;this._preloadQueue=n.range((e=this.$el,Math.ceil(e.get(0).scrollHeight/e.height()))),this.sortPreloadQueue()},sortPreloadQueue:function(){var e,t;n.isEmpty(this._preloadQueue)||(t=this.$el,e=Math.floor(t.scrollTop()/t.outerHeight(!0)),this._preloadQueue=n.sortBy(this._preloadQueue,function(t){return Math.abs(e-t)+(t<e?.1:0)}))},clearPreloadQueue:function(){this._preloadQueue&&(this._preloadQueue.length=0)},processPreloadQueue:function(){var e,t;this.get("isPreloading")||(this.rendered&&!n.isEmpty(this._preloadQueue)?(e=this._preloadQueue.shift(),t=this.getViewsAtPageIndex(e),this.set("isPreloading",!0),this.preloadSubviews(t).finally(n.bind(function(){this.set("isPreloading",!1)},this)).catch(n.noop)):this.stopPreloadPoller())},startPreloadPoller:function(){this.stopPreloadPoller(),this._preloadTimer=setInterval(n.bind(this.processPreloadQueue,this),this.get("preloadPollInterval"))},stopPreloadPoller:function(){this._preloadTimer&&(clearInterval(this._preloadTimer),this._preloadTimer=null)},renderCollectionSubviews:function(e){if("searchResults"!==e)return o.renderCollectionSubviews.apply(this,arguments);var t=this.subviews[e],i=t.container||n.bind(function(){return this.$('[data-subview="'+e+'[]"]')},this),s=t.prepareView||function(i,n){var s=new t.constructor(n);return s.$el.attr("data-subview",e),i.append(s.$el),s},r=t.options||{},a=t.collection;if(n.isFunction(a)&&(a=a(this)),!a)return null;var l=this.get("renderBatchSize"),c=this.get("renderBatchDelay");this._deferredRenders=n(a.models).groupBy(function(e,t){return Math.floor(t/l)}).toArray().map(function(t,o){return n.delay(this.createCollectionSubviewRenderer(t,i,s,r,e,!!o),o*c)}
1,this).value()},hideViews:function(e){n.each(e,function(e){e.rendered&&(e.set("isSelectable",!1),e.$el.css("opacity",0))})},animateShowViews:function(e){var t=0;n.each(e,function(e){this.animateShowView(e,100*t++)},this)},animateShowView:function(e,t,i,s){var o,r=!1;s=n.isNumber(s)?s:250,t=n.isNumber(t)?t:0,i=n.isNumber(i)?i:1e3,p(e.$el,"translateY","40px");var a=function(){r=!0,d(e.$el,"stop"),d(e.$el,{translateY:0,opacity:1},{duration:s,delay:t,complete:n.bind(function(){e.rendered&&(e.set("isSelectable",!0),e.$el.css({transform:"",opacity:""}))},this)})};i>0&&(o=setTimeout(a,i)),e.getLoadPromise().then(function(){o&&clearTimeout(o),r||a()})},beforeRender:function(){this.$el.css("visibility","hidden"),this.removeSubviews()},afterRender:function(){this.collection&&0!==this.collection.length&&(this.listenTo(this.eventBus,"image:full:loading",this.cancelPreloads),this.listenTo(this,"change:selectedView",this._onChangeSelectedView),this.listenTo(this,"change:isFocused",this._onChangeIsFocused),this._setIsFocusedDebounced=n.debounce(n.bind(this._setIsFocused,this),0),n.defer(n.bind(function(){if(this.rendered){this._deferredRenders||(this._deferredRenders=[]);var e=n.delay(n.bind(this.resetMasonry,this),this.get("renderBatchDelay")*this._deferredRenders.length);this._deferredRenders.push(e),this.scrollbar?this.scrollbar.update():this.scrollbar=new f(this.$el)}},this)))},removeSubviews:function(){return n.forEach(this._deferredRenders,clearTimeout),this._deferredRenders=[],delete this.masonry,o.removeSubviews.apply(this,arguments)},resetMasonry:function(){this.setupMasonary(),this.setupElementCaches(),this.get("enablePreloading")&&(this.populatePreloadQueue(),this.startPreloadPoller()),this.setSelectedImage(),this.setupVirtualization();var e=this.getSubviewsInBounds();this.hideViews(e),this.$el.css("visibility",""),this.animateShowViews(e)},getViewBounds:function(e){return n.result(this._elementPositionCache,e.cid)?this._elementPositionCache[e.cid]:m(e.$el)},getSubviewsInBounds:function(e){var t;return e=e||(t=this.$el,{top:Math.round(t.scrollTop()),bottom:Math.round(t.scrollTop()+t.height())}),n.filter(this.searchResults,function(t){return _(this.getViewBounds(t),e)},this)},setupMasonary:function(){this.masonry?this.masonry.reload():this.masonry=new u(this.$(".results-scroller").get(0),{transitionDuration:0,isFitWidth:!0,gutter:10},this)},setupElementCaches:function(){var e=this.$el;this._pageIndexCache={},this._elementPositionCache={},n.each(this.searchResults,function(t){var i=function(e,t){return Math.floor(t.position().top/e.height())}(e,t.$el);n.isArray(this._pageIndexCache[i])||(this._pageIndexCache[i]=[]),this._pageIndexCache[i].push(t),this._elementPositionCache[t.cid]=m(t.$el)},this)},getViewsAtPageIndex:function(e){return this._pageIndexCache[e]||[]},setupVirtualization:function(){var e=n.bind(function(){this.rendered&&(this.sortPreloadQueue(),this.virtualizeSubviews())},this),t=n.debounce(e,250);this.$el.off(".image-search-virtualization").on("scroll.image-search-virtualization",t),this.virtualizeSubviews()},setSelectedImage:function(){var e,t;if(this.get("selectedImageUrl")&&(t=n.find(this.searchResults,function(e,t){return e.model.get("mediaUrl")===this.get("selectedImageUrl")},this))){if(t.set("isPreselected",!0),0===(e=t.$el.offset().top-this.$el.offset().top))return;e-=(this.$el.height()-t.$el.height())/2,this.$el.scrollTop(e)}},cancelPreloads:function(){this.stopPreloadPoller(),this.clearPreloadQueue()},cancelFullImageLoads:function(){this.eventBus.trigger("image:full:cancelLoad")},preloadSubviews:function(e,t){return g.all(n.map(e,function(e){return e.loadImage()}))},_virtualizeSubviews:function(e,t,i){n.forEach(this.searchResults,function(s,o){if(s&&s.$el){var r=this.getViewBounds(s);_(r,e)?n.isFunction(t)&&t.call(this,s,function(e,t){return t.bottom>=e.bottom&&t.top<=e.top}(r,e)):n.isFunction(i)&&i.call(this,s)}},this)},virtualizeSubviews:function(){var e=this.$el,t={top:e.scrollTop(),bottom:e.scrollTop()+e.height()};this._virtualizeSubviews(t,function(e,t){e.set({isVirtualized:!1}),t&&!1===e.get("isImpressionLogged")&&(this.eventBus.trigger("image:impression",e),e.set("isImpressionLogged",!0))},function(e){e.set({isVirtualized:!0})})},beforeRemove:function(){this.$el.off(),this.cancelPreloads(),this.cancelFullImageLoads(),this.keyboardManager.remove(this.keyboardNamespace),this.scrollbar&&this.scrollbar.destroy()},_setIsFocused:function(e){this.rendered&&this.set("isFocused",e)},_onChangeSelectedView:function(e,t){var i=this.previous("selectedView");i&&i.setSelected(!1),t&&t.setSelected(!0)},_onChangeIsFocused:function(e,t){t?(this.keyboardManager.add(this.keyboardNamespace,this),this.trigger("focus",this)):(this.set("selectedView",null),this.keyboardManager.remove(this.keyboardNamespace),this.trigger("blur",this))},_onSubviewSelect:function(e){this.get("isFocused")||this._setIsFocused(!0),this.setSelectedIndex(this.keyboardViewName,n.indexOf(this.searchResults,e)),this.set("selectedView",this.get
1SelectedView(this.keyboardViewName))},_onSubviewClear:function(){this.set("selectedView",null),this.deselect(this.keyboardViewName)},focus:function(){var e=this.get("selectedView"),t=!n.isEmpty(e);this._setIsFocused(!0),t?this.setSelectedIndex(this.keyboardViewName,n.indexOf(this.searchResults,e)):this.set("selectedView",this.selectFirst(this.keyboardViewName))},isLastViewSelected:function(){return this.isLastSelected(this.keyboardViewName)},isFirstViewSelected:function(){return this.isFirstSelected(this.keyboardViewName)},_onKeyPressDown:function(e){var t;e.preventDefault(),t=this.isLastViewSelected()?this.selectFirst(this.keyboardViewName):this.selectNext(this.keyboardViewName),this.set("selectedView",t)},_onKeyPressUp:function(e){var t;e.preventDefault(),t=this.isFirstViewSelected()?this.selectLast(this.keyboardViewName):this.selectPrevious(this.keyboardViewName),this.set("selectedView",t)},_onKeyPressEnter:function(e){var t=this.get("selectedView");e.preventDefault(),t&&t.select(e)}});e.exports=v},24655(e){"use strict";var t={};e.exports=function(e,i){if(e in t)return t[e];var n=window[e];if(!i||!i(n)){var s=document.createElement("div");document.body.appendChild(s),n=s.contentWindow[e],document.body.removeChild(s)}return t[e]=n,n}},24743(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, \'\') }\nwith (obj) {\n__p += \'<div class="popover popover_menu popover_gradient message-controls-popover"><div class="popover_inner"><ul> \';
1\n if (this.showFlagAndBlock) { ;\n__p += \' <li class="popover_menu_item" data-action="block" data-block="\' +\n__e( this.options.blockString ) +\n\'"><a class="popover_menu_item_anchor" href="#">\' +\n__e( __(\'Block\') ) +\n\'</a></li><li class="popover_menu_item" data-action="flag"><a class="popover_menu_item_anchor" href="#">\' +\n__e( __(\'Report\') ) +\n\'</a></li> \';\n } ;\n__p += \' <li class="popover_menu_item" data-action="delete" data-confirm="\' +\n((__t = ( __(\'Are you sure you want to delete this?\') )) == null ? \'\' : __t) +\n\'"><a class="popover_menu_item_anchor" href="#">\' +\n__e( __(\'Delete\') ) +\n\'</a></li></ul></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},24771(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(27496),r=i(80160),a=i(44890),l=r.extend({defaults:{type:null,types:{},initializing:!0,pushState:!0},initialize:function(){this.promisePool={},this.listenTo(this,"change:type",this.envChanged)},setup:function(e,t){this.set({types:e,type:t},{silent:!0}),this.updateMeta()},setType:function(e){this.trigger("before:change:type",e,this.get("type")),n.find(this.get("types"),{id:e})&&e!==this.get("type")&&(this.set("type",e),n.delay(n.bind(this.updateMeta,this),200))},getType:function(){return n.find(this.get("types"),{id:this.get("type")})},getFragment:function(){return this.get("type")+window.location.search},env:function(){var e={is_logged_in:a.bool("is_logged_in"),type:this.get("type")};return e},envChanged:function(){var e={loggingData:{pathname:"/explore/".concat(this.get("type"))}};o.trigger("Kraken:ScreenView",e),o.trigger("DiscoveryStateModel:change:env",{loggingData:{env:this.env()}})},updateMeta:function(){var e=this.getType();e&&this.set({blogHeader:e.blogHeader,searchHeader:e.searchHeader,showSearches:e.showSearches,showBlogs:e.showBlogs,hero:e.hero,pt:e.pt,rootUrl:e.rootUrl})},setLoading:function(e,t){this.timeout&&clearTimeout(this.timeout),this.promisePool[e]=t,this.timeout=n.defer(n.bind(this.setCallback,this))},setCallback:function(){var e=n.values(this.promisePool),t=n.keys(this.promisePool);this.trigger("loading",t),s.when.apply(s,e).then(n.bind(function(){this.promisePool={},this.trigger("loaded",t)},this))}});e.exports=new l},25039(e,t,i){"use strict";var n=i(97583).extend({logKey:"notes_interactions",logOptions:{init_event:!1},logEnv:{location:document.location.pathname},events:{"notes-interactions:*":"log"}});e.exports=n},25046(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"survey-result\"> ';\n _.each(message, function(field) { ;\n__p += ' <div class=\"form-row\"> ';\n if (field.type === 'text') { ;\n__p += ' ';\n if (typeof field.link !== 'undefined') { ;\n__p += ' <p>' +\n((__t = ( __(field.text, '<a target=\"_blank\" href=\"'+ field.link +'\">', '</a>') )) == null ? '' : __t) +\n'</p> ';\n } else { ;\n__p += ' <p>' +\n((__t = ( __(field.text) )) == null ? '' : __t) +\n'</p> ';\n } ;\n__p += ' ';\n } else if (field.type === 'link') { ;\n__p += ' <a href=\"' +\n((__t = ( field.href )) == null ? '' : __t) +\n'\" target=\"_blank\">' +\n((__t = ( __(field.text) )) == null ? '' : __t) +\n'</a> ';\n } else if (field.type === 'highlight') { ;\n__p += ' <p class=\"highlight\">' +\n((__t = ( __(field.text) )) == null ? '' : __t) +\n'</p> ';\n } ;\n__p += ' </div> ';\n }); ;\n__p += ' </div> ';\n if (typeof options !== 'undefined') { ;\n__p += ' <div class=\"options\"> ';\n _.each(options, function(option) { ;\n__p += ' ';\n if (mode !== 'standalone' && typeof option.flaggingTo !== 'undefined') { ;\n__p += ' <div class=\"option\" data-survey-nav-to=\"' +\n((__t = ( option.flaggingTo )) == null ? '' : __t) +\n'\"> ' +\n((__t = ( __(option.name) )) == null ? '' : __t) +\n' </div> ';\n } else { ;\n__p += ' <div class=\"option\" data-survey-nav-to=\"' +\n((__t = ( option.to )) == null ? '' : __t) +\n'\"> ' +\n((__t = ( __(option.name) )) == null ? '' : __t) +\n' </div> ';\n } ;\n__p += ' ';\n }); ;\n__p += ' </div> ';\n } ;\n\n\n}\nreturn __p\n}").apply(void 0,r(s))},25144(e,t,i){"use strict";var n=i(3226),s=new(i(89826))("account-popover");e.exports=function(e){s.start(),i.e(860).then(function(t){try{e(i(68114))}catch(e){n(e,"account-popover")}finally{s.end()}}.bind(null,i)).catch(i.oe)}},25152(e,t,i){var n=i(55679),s=i(62535),o=i(42562),r=s.extend({name:"MessagingPoller",defaults:n.defaults({url:o,frequency:15e3},s.prototype.defaults),initialize:function(e){return e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"channels","user")),this._requestData={unread_messages:!0},s.prototype.initialize.apply(this,arguments)},getRequestData:function(){return this._requestData},hasResponseChanged:function(e){return!n.isEmpty(n.get(e,"unread_messages"))}});e.exports=r},25252(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(33255);e.exports=function(e,t){var i=o.nodeFromString(e),r=s(i);return n.isFunction(t)&&(t=n.rest(arguments)),n.each(t,function(e){e(i,r)}),r.html()}},25256(e,t,i){"use strict";var n=i(55679),s=[16,24,30,40,48,64,96,128,200,512],o=n.last(s);e.exports=function(e,t){var i=function(t){var i;return t=null==t?128:(i=t)>=o?o:n.find(s,function(e){return e>=i}),(e||"").replace(/^(.*_)?(\d+)(\D.*)?$/,"$1"+t+"$3")};return i.toString=function(){return this()},null!=t?i(t):i}},25352(e,t,i){"use strict";var n=i(74692),s=i(71092),o=(i(44890),i(41784)),r=s.extend({className:"types-tabs",template:o,events:{"click [data-content-type]":"onContentTypeClick"},initialize:function(){this.bindEvents()},bindEvents:function(){this.listenTo(this.collection,"change:active",this.toggleActive),this.listenTo(this.collection,"change:visible",this.toggleTabVisibility)},render:function(){return this.$el.html(this.template(this.serialize())),this},serialize:function(){return{types:this.collection.toJSON()}},toggleActive:function(e,t){this.$("[data-content-type="+e.id+"]").toggleClass("active",t)},toggleTabVisibility:function(e,t){this.$("[data-content-type="+e.id+"]").toggleClass("hidden",!t),this.$(".more-control
1s").toggleClass("hidden",!this.collection.hasHidden())},onContentTypeClick:function(e){var t=this.collection.getActive();if(this.collection.isPushState()&&!e.metaKey&&!e.altKey&&"answertime"!==t.id){e.preventDefault();var i=n(e.currentTarget);this.collection.setActive(i.data("contentType"))}}});e.exports=r},25462(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(71092),r=i(27496),a=i(38333),l=i(64491),c=i(98237),u=i(38578),h=i(77566),d=o.extend({defaults:{placeholder:"",name:"",syncWithModel:!0,forceSingleLine:!1,smartQuotesEnabled:!1},events:{},mixins:[u,l,c],template:h,initialize:function(e){this.set(e),this.onChange=e.onChange||n.noop,this.onClientEvent=e.onClientEvent||n.noop,this.pasteHook=e.pasteHook||n.noop,this.smartQuotesEnabled=e.smartQuotesEnabled,this.disableEdit=e.disableEdit||!1;var t=this.get("name");t&&this.get("syncWithModel")&&this.$el.attr("data-name",t)},_initializeEditor:function(e,t){var i={placeholder:t,onChange:this._composeOnChange(),onClientEvent:this._composeOnClientEvent(),pasteHook:this.pasteHook,runIFrameSanitization:!0,forceSingleLine:this.get("forceSingleLine"),filterRules:{elements:["p","br"],attributes:{},remove_contents:["style","noscript","script","meta"],protocols:{}},smartQuotes:{enabled:this.smartQuotesEnabled}};this.editor=new a.PlainTextEditor(e,i),this.disableEdit&&this.disable()},_composeOnChange:function(){var e=[this.onChange],t=this;return this.get("syncWithModel")&&e.unshift(this.updateModelFromEditor),function(i){n.each(e,function(e){e.call(t,i)})}},_composeOnClientEvent:function(){var e=this.onClientEvent,t=this;return function(i){r.trigger("plainTextEditor:onClientEvent",i,t.editor),e.call(this,i)}},render:function(){this.$el.html(this.template({ariaLabel:this.get("ariaLabel")}));var e=this.js$("plainTextEditor").get(0);(this._initializeEditor(e,this.get("placeholder")),this.get("syncWithModel"))&&(this._modelValue().length>0&&this.set("placeholder",!1),this.updateEditorFromModel());return this},teardown:function(){return this.$el.empty(),delete this.editor,this},serialize:function(){return this.toJSON()},getEditorValue:function(e){return void 0!==e||(e=!0),this.editor?this.editor.getData(e):null},setEditorValue:function(e){this.editor&&this.editor.setData(e)},updateModelFromEditor:function(){if(!this.editor)return!1;var e=this.get("name"),t=this.getEditorValue();""!==t?s(this.editor.element).addClass("has-text"):s(this.editor.element).removeClass("has-text"),this.model.get(e)!==t&&this.model.set(e,t)},updateEditorFromModel:function(){var e=this.getEditorValue(),t=this._modelValue();t.trim()&&t.trim()!==e.trim()&&this.setEditorValue(t)},_modelValue:function(){return this.model.get(this.get("name"))||""},focus:function(e){this.editor&&this.editor.focus(e)},blur:function(){this.editor&&this.editor.element.blur()},setCursorToEnd:function(){this.editor&&n.isFunction(this.editor.setCursorToEnd)&&this.editor.setCursorToEnd()},enable:function(){s(this.editor.element).attr("contenteditable",!0)},disable:function(){s(this.editor.element).removeAttr("contenteditable")}});e.exports=d},25910(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(80160),r=i(95870),a=o.extend({defaults:{type:null,summary:null,state:null,photos:[],is_nsfw:!1},setType:function(e){n.contains(["photo","link","quote","audio","video","chat"],e)&&this.set("type",e)},getMessage:function(){return"gif"===this.getType()?null:this.get("summary")},getActionMarkup:function(e,t,i){var o,r,a,l,c;return t=t||"",i=i||"",e=n.escape(e),l=(r=!n.isEmpty(e))?s("%1$s%2$s%3$s sent a post that's no longer available",t,e,i):s("sent a post that's no longer available"),this.isDisabled()?l:(o=this.getType(),a=r?s("%1$s%2$s%3$s sent a post",t,e,i):s("sent a post"),c=r?{photo:s("%1$s%2$s%3$s sent a photo post",t,e,i),photoset:s("%1$s%2$s%3$s sent a photoset",t,e,i),gif:s("%1$s%2$s%3$s sent a GIF",t,e,i),link:s("%1$s%2$s%3$s sent a link",t,e,i),quote:s("%1$s%2$s%3$s sent a quote",t,e,i),audio:s("%1$s%2$s%3$s sent an audio post",t,e,i),video:s("%1$s%2$s%3$s sent a video",t,e,i),chat:s("%1$s%2$s%3$s sent a chat",t,e,i)}:{photo:s("sent a photo post"),photoset:s("sent a photoset"),gif:s("sent a GIF"),link:s("sent a link"),quote:s("sent a quote"),audio:s("sent an audio post"),video:s("sent a video"),chat:s("sent a chat")},n.has(c,o)?n.get(c,o):a)},getType:function(){if("photo"===this.get("type")){if(this._isThumbnailGIF())return"gif";if((this.get("photos")||[]).length>1)return"photoset"}return this.get("type")}
1,getThumbnail:function(e){var t,i=this._getClientThumbnail();return n.isEmpty(i)?(t=this._getPostThumbnail(e),n.isEmpty(t)?null:t):i},hasThumbnail:function(e){return!n.isEmpty(this.getThumbnail(e))},getScaledDimensionsForWidth:function(e,t){return n.has(e,"width")&&n.has(e,"height")?{width:t,height:Math.round(n.get(e,"height")/(n.get(e,"width")/t))}:null},isDisabled:function(){return"disabled"===this.get("state")},addThumbnail:function(e,t,i){!n.isEmpty(e)&&n.isNumber(t)&&n.isNumber(i)&&this.set("clientThumbnail",{url:e,width:t,height:i})},_getClientThumbnail:function(){return this.get("clientThumbnail")},_getPostThumbnail:function(e){var t,i,s=this.get("thumbnail_url"),o=this.get("thumbnail_height"),r=this.get("thumbnail_width"),a=this.get("photos");return e=e||250,!n.isEmpty(a)||!n.isEmpty(s)&&n.isFinite(o)&&n.isFinite(r)?n.isEmpty(a)?{url:s,height:o,width:r}:(i=n.sortBy(n.get(n.first(a),"alt_sizes"),"width"),t=n.find(i,function(t){return n.get(t,"width",0)>=e}),n.isEmpty(t)?n.last(i):t):null},_isThumbnailGIF:function(){var e=n.get(this.getThumbnail(),"url");return!n.isEmpty(e)&&"gif"===(r.getExtension(e)||"").toLowerCase()}});e.exports=a},26024(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(91685),r=o.getComponent("Component"),a=o.extend(r,{constructor:function(e,t){this.options=t||{},this.player=e,this.$player=s(this.player.el()),this._selectorCache(),this.player.on("dispose",n.bind(this.dispose,this)),this.player.ready(n.bind(function(){this.initialize.apply(this,arguments)},this))},_selectorCache:function(){this.$$=n.memoize(function(e){return this.$player.find(e)},n.identity),this.$$.remove=n.bind(function(e){this.$$.cache.delete(e)},this),this.$$.clear=n.bind(function(){this.$$.cache=new n.memoize.Cache},this)},initialize:function(){},dispose:function(){this.$$.clear(),this.$player.off()}});e.exports=a},26124(e,t,i){"use strict";i(41257);var n=i(55679),s=i(74692),o=i(21189),r=i(9045),a=i(73885),l=i(71742),c=i(27496),u=i(37552),h=(i(95349),i(21391)),d=(i(67127),i(79052)),p=i(77599),g=i(29546),f="/dashboard",m=i(81515),_=s("body"),v=i(60480),b=i(49779),y=i(6479),w=i(31787),C=i(89161),x=i(52181),k=i(80756),S=i(19118),T=i(16089),E=l.extend({name:"PostFormBuilder",initialize:function(){var e=this.data;if(this.user=y(),this.user){c.trigger("postForms:initializing"),v(n.bind(function(e){this.PostFormComponent=e},this));var t={baseRoute:null,currentChannel:null,supportImageSearch:!1,minFullWidthSize:300,redirectTo:!1,reblogActionContext:!1,updateURL:!0};n.extend(this,t,n.pick(e,n.keys(t))),this._addGlobalEventListeners(),this.user.set(e.limits),this.user.set(e.dashboardSettings),this.user.set("language",e.language||"en_US"),C.setEmbedRegexes(e.embedRegexes),this.glassView=new x,this.modal=new k,this.modalContainer=new S({className:"post-form-modal-content",animateHeightWithContent:!0}),this.modal.setContentSubView(this.modalContainer),this.postButtons=new T({el:"#new_post"}),this.postButtonsContainer=new S({el:this.postButtons.$el.parent(),originalContent:this.postButtons,transitionBackground:!0,animateHeightWithContent:!0,useLoader:!1}),this.scrollHelper=new d,this.saveHook=new p(n.extend({$postButtonsContainer:this.postButtonsContainer.$el},e)),this.legacyEvents(),this._updateData=n.once(this.updateData),this.render()}},updateData:function(){return s.ajax({url:"/svc/post/get_post_form_builder_data",type:"POST",withFormKey:!0,data:{}}).then(n.bind(function(e){var t=e.response;return n.forEach(t.channels,function(e){var t=!!e.name&&this.user.getChannel(e.name);t&&t.set(n.omit(e,"name"))},this),this.user.set(t.limits),t},this))},legacyEvents:function(){n.forEach({"postForms:closed":["post:form:hide","keycommands:resume"],"postForms:saved":["post:form:success"],"postForms:opened":["post:form:show","keycommands:suspend"]},function(e,t){this.listenTo(c,t,function(){var t=n.toArray(arguments);n.each(e,function(e){c.trigger.apply(c,[].concat(e,t))},this)})},this)},_addGlobalEventListeners:function(){this.listenTo(c,"postForms:open",this.fetchAndCreatePostFormComponent),this.listenTo(c,"postForms:new",this._createPostFormNew),this.listenTo(c,"postForms:edit",this._createPostFormEdit),this.listenTo(c,"postForms:reblog",this._createPostFormReblog),this.listenTo(c,"postForms:saved",this.destroyPostForm),this._registerDismissListener(),this.listenTo(c,"postForms:dismissListener:suspend",function(){this._toggleDismissListener(!1)}),this.listenTo(c,"postForms:dismissListener:resume",function(){this._toggleDismissListener(!0)})},_toggleDismissListener:function(e){this.stopListening(c,"postForms:close"),e&&this._registerDismissListener()},_registerDismissListener:function(){this.listenTo(c,"postForms:close",this.dismissPostForm)},createInlineContainer:function(e){return!!e&&new S({el:e.parent(),originalContent:e,transitionBackgroun
1d:!0})},fetchAndCreatePostFormComponent:function(e){n.isEmpty(this.PostFormComponent)?v(n.bind(function(t){this.PostFormComponent=t,this._createPostForm(e)},this)):this._createPostForm(e)},_createPostFormNew:function(e){this.fetchAndCreatePostFormComponent(e)},_createPostFormEdit:function(e){e.postEl&&(e.containerView=this.createInlineContainer(e.postEl),e.postFormType=g.inline),this.fetchAndCreatePostFormComponent(e);var t=new RegExp(/\/blog\/\w+\/review/);if(this.baseRoute&&this.baseRoute.match(t)){var i={loggingData:{post_id:e.editId,blog_name:e.channelId,page:"EditPost"}};c.trigger("Kraken:EditPost",i)}},_createPostFormReblog:function(e){this.fetchAndCreatePostFormComponent(e)},_createPostForm:function(e){if(this.postForm)return this.destroyPostForm(e).then(n.bind(function(){return this._createPostForm(e)},this));c.trigger("postForms:opening"),e=n.extend({fastCompose:!1,supportImageSearch:this.supportImageSearch,minFullWidthSize:this.minFullWidthSize,updateURL:this.updateURL,glass:!0,postFormType:g.modal},e),n.defaults(e,{containerView:e.postFormType===g.inline?this.postButtonsContainer:null}),this.glass=e.glass,e.post||(e.post=this._createPostModel(e)),e.url||(e.url=this._postFormUrl(e.post)),e.containerView===this.postButtonsContainer&&this.postButtons.setPostType(e.post.get("type")),this._updateData();var t=e.postFormType===g.modal,i=["supportImageSearch","minFullWidthSize","post"];"photo"===e.post.get("type")&&i.push("showPhotoBooth");var a=this.postForm=new this.PostFormComponent(n.extend(n.pick(e,i),{isModal:t,popoverContainer:t?this.modal.$el:_,redirectTo:this.redirectTo,reblogActionContext:this.reblogActionContext,fastCompose:e.fastCompose})),l=this.postFormContainer=e.containerView||this.modalContainer;if(!l)throw new Error("No post form container!");this.listenTo(a,"pauseScrollHelper",this.pauseScrollHelper),this.listenTo(a,"resumeScrollHelper",this.resumeScrollHelper),l.isRendered()||l.render(),l.setPostFormComponent(a);var d=n.once(n.bind(function(){return e.glass?this.glassView.show():o.resolve()},this)),p=r([function(){return c.trigger("Header:hide"),o.join(l.prepare(d),a.whenRendered(!0))},function(){return a.disable(),l.attach(d)},function(){return e.updateURL&&h.history.navigate(e.url,{replace:!0}),function(){var e=u.rect(),i=e.windowScrollTop,o=e.windowHeight,r=a.getRect().offsetHeight,h=l.$el.offset().top,d=h+r,p=s("[prima-component=header]").height()||0,g=r+40<o,f=this.scrollHelper.calculateScrollTop(h-20,d+20+p,o,g),m=t?this.modal.$el:null;l===this.postButtonsContainer&&i<f&&o>r&&(f=i),this.previousScrollPosition=!t&&i,this.scrollHelper.scrollToPosition(f,400,m),this.listenTo(c,"Photoset:dragScroll",function(e,t){n.isNumber(t)||(t=50);var i=u.rect().windowScrollTop+e;this.scrollHelper.scrollToPosition(i,t,m)}),this.listenTo(c,"Photoset:scrollToRow",function(e,t,i){n.isNumber(i)||(i=50),e+=0,this.scrollHelper.checkScrollBounds(!1,{keepInside:!0,contentPadding:70,contentRect:{offsetTop:e,offsetHeight:t}})})}.call(this),l.showPostForm(d)},function(){return d()},function(){a.enable()}],this).then(n.bind(function(){return c.trigger("postForms:opened"),_.addClass("postforms-open"),a},this),n.bind(function(){this.destroyPostForm()},this));return e.postFormType===g.inline&&p.then(n.bind(function(){this.scrollHelper.start({el:l.$el})},this)),p.catch(function(e){e instanceof Error&&n.defer(function(){throw e})}),p},_postFormStateChanged:function(e){if(this.postForm){var t=this.postForm.initialPostState;return this.postForm.post.deepHasChanged(t)}return!1},dismissPostForm:function(){this.postForm&&!this.postForm.isEnabled()||(this._postFormStateChanged()?this._buildDismissPrompt():this.destroyPostForm())},_buildDismissPrompt:function(){var e=m("Discard this post?");this.postForm&&this.postForm.post&&"edit"===this.postForm.post.get("mode")&&(e=m("Discard edits to this post?"));var t={text:e,text_ok:m("Discard"),text_cancel:m("Nevermind"),keycommand_maintain:!0};b.confirm(t,n.bind(function(){this.destroyPostForm(),c.trigger("postForms:dismissListener:resume")},this),function(){n.defer(function(){c.trigger("postForms:dismissListener:resume")})}),c.trigger("postForms:dismissListener:suspend")},destroyPostForm:function(e,t){e=n.extend({updateURL:this.updateURL,url:this.baseRoute,glass:this.glass},e),this.scrollHelper.stop();var i=this.postForm,s=this.postFormContainer,a=!!i.fastCompose;this.postForm=null,this.postFormContainer=null,this.stopListening(i),this.stopListening(c,"Photoset:
1dragScroll");var l=n.once(n.bind(function(){return e.glass?this.glassView.hide():o.resolve()},this)),u=i&&!!i.postForm.get("saved"),d=i&&i.post&&i.post.get("state"),p={didSave:u,newState:u?d:null};c.trigger("postForms:closing",p);var g=r([function(){u&&this.saveHook.preExecute(t)},function(){i&&i.disable()},function(){if(function(){if(!1!==this.previousScrollPosition){var e=this.previousScrollPosition;this.scrollHelper.scrollToPosition(e,400)}}.call(this),s)return s.hidePostForm(l).then(function(){s.teardown()})},function(){if(i&&i.remove(),e.updateURL){var t=h.history.root||"",n=e.url?e.url.replace(new RegExp("^"+t),""):"";h.history.navigate(n,{replace:!0})}},function(){return l()},function(){u&&t&&(this.saveHook.$inlinePostEl=s.$el,this.saveHook.execute(t,{fastCompose:a}))}],this).then(function(){return c.trigger("postForms:closed",p),c.trigger("Header:show"),_.removeClass("postforms-open"),i});return g.catch(function(e){e instanceof Error&&n.defer(function(){throw e})}),g},pauseScrollHelper:function(){this.scrollHelper&&this.scrollHelper.pause()},resumeScrollHelper:function(){this.scrollHelper&&this.scrollHelper.resume()},_createPostModel:function(e){"string"==typeof e&&(e={postType:e});var t=n.extend({tumblelog:e.channelId||this.currentChannel||this.user.getChannel().get("name"),editorType:this.user.get("defaultEditorType"),contextData:{baseRoute:this.baseRoute,contextPage:e.contextPage}},n.pick(e,"tags","sourceUrl","loggingData"));return e.reblogId?n.defaults(t,{lookupData:{reblog_id:e.reblogId,reblog_key:e.reblogKey,reblog_blog_name:e.reblogBlogName||"",carousel_index:e.carousel_index},mode:"reblog",pt:e.pt,reblogSource:e.reblogSource}):e.editId?n.defaults(t,{lookupData:{post_id:e.editId,channel_id:e.channelId||this.redirectChannel},mode:"edit"}):n.defaults(t,{type:e.postType||e.type||"text",mode:"new"}),new w(t)},_postFormUrl:function(e){if(e){if(e.has("lookupData")){var t=e.get("lookupData");return t.reblog_id?this._reblogPostUrl(t.reblog_id,t.reblog_key):t.post_id?this._editPostUrl(t.post_id):this._newPostUrl(e.get("type"))}return e.has("reblog_id")?this._reblogPostUrl(e.get("reblog_id"),e.get("reblog_key")):e.has("id")?this._editPostUrl(e.get("id")):this._newPostUrl(e.get("type"))}return this._newPostUrl("text")},_newPostUrl:function(e){return(this.baseRoute!==f?this.baseRoute:"")+"/new/"+e},_editPostUrl:function(e){return"/edit/"+e},_reblogPostUrl:function(e,t){return"/reblog/"+e+"/"+t},render:function(){return this.glassView.render().$el.appendTo("body"),this.modal.render().$el.appendTo("body"),this},updateBaseRoute:function(e){var t;e?this.baseRoute=e:(t=h&&h.history?h.history.location.pathname:f,this.baseRoute=t)}},{containerType:function(e){return g[e]}});a.applyTo(E.prototype),e.exports=E},26771(e,t,i){"use strict";var n=i(55679),s=i(21391),o=new(i(28724))({defaults:{relationKeys:function(){return n.keys(this.relations)},getRelations:function(){return n.pick(this.attributes,this.relationKeys())}},before:{initialize:function(e,t){this._bootstrapRelations(e,t)}},extend:{_isModelOrCollection:function(e){return e instanceof s.Collection||e instanceof s.Model},_bootstrapRelations:function(e,t){this._isBootstrapped||(n.forEach(this.relations,function(i,s){var o=this.attributes[s];!n.isEmpty(o)&&o instanceof i||(this.attributes[s]=new i(e[s],t))},this),this._isBootstrapped=!0)}},around:{set:function(e,t,i,o){var r,a,l,c,u,h,d=this.attributes,p=this.relationKeys(),g=!this._isBootstrapped;return n.isObject(t)?(r=t,o=i):(r={})[t]=i,o=o||{},u=n.result(o,"relationalSetOptions")||{},this._bootstrapRelations(r,o),a=n.pick(r,p),n.isEmpty(a)?e.apply(this,n.rest(arguments)):(h=n.isEmpty(this.relationsOrder)?n.keys(a):this.relationsOrder,g||n.forEach(h,function(e){r[e]&&(c=a[e],l=d[e],this._isModelOrCollection(l)&&(o.unset?l instanceof s.Collection?l.reset():l instanceof s.Model&&l.clear():(this._isModelOrCollection(c)&&(c=c.toJSON()),o.reset&&l instanceof s.Collection?l.reset(c,n.extend({},o,u[e])):l.set(c,n.extend({},o,u[e])))))},this),e.call(this,n.omit(r,p),o))},toJSON:function(e){var t=e.apply(this,n.rest(arguments))||{};for(var i in this.relations)this.relations.hasOwnProperty(i)&&(t[i]=n.result(t[i],"toJSON")||t[i]);return t}}});e.exports=o},27006(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div class=\"see-all-tags\"><span class=\"ellipses\">...</span> ' +\n__e( __('See all') ) +\n' </div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},27160(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(17145).extend({fetchOpenGraphData:function(e){var t=s.ajax({url:"/svc/post/fetch_og",type:"POST",withFormKey:!0,data:{url:e}});return this.xhr=t,t.then(function(e){return(s.parseJSON(e)||{}).response}).always(n.bind(function(){this.xhr=null},this))},abort:function(){this.xhr&&this.xhr.abort()}});e.exports=o},27301(e,t,i){"use strict";var n=i(55679),s=i(97583).extend({logKey:"vendorbutton",logEnv:{referrer:document.location.pathname},events:{"VendorButton:*":"handleEvent"},handleEvent:function(e,t){var i=n.extend({},t);i.post_id=t.postData.id,i.root_post_id=t.postData.root_id,i.tumblelog=t.postData.tumblelog,delete i.postData,this.log(e,i)}});e.exports=s},27365(e,t,i){"use strict";var n=i(50283),s=i(66048),o=n.extend({template:s,className:"filter-icon",render:function(){return this.$el.html(this.template()),this}});e.exports=o},27496(e,t,i){"use strict";var n=i(55679),s=i(21391),o=function(){};o.extend=s.Model.extend,n.extend(o.prototype,s.Events),o.prototype.trigger=function(){return n.isObject(arguments[1])&&(arguments[1].loggingData=arguments[1].loggingData||{}),s.Events.trigger.apply(this,arguments)},e.exports=new o},27513(e,t,i){"use strict";var n=i(21391).Collection,s=i(13752),o=i(71827);n=n.extend();s.applyTo(n.prototype),o.applyTo(n),e.exports=n},27547(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(91685),r=i(27496),a=i(44890),l=i(26024),c=o.extend(l,{videoConversionLogged:!1,loggingInProgress:!1,startSeekTime:null,loadStartTime:0,triggerElement:s(),initialize:function(e,t){this.player.crt.on("playerReady",n.bind(function(){this.setPlayerData(),this.bindEvents(),this.cacheUnloadData(),this.playerData.duration=this.player.duration(),this.player.options_.crtOptions["hls-service"]&&(n.isFinite(this.playerData.duration)?this.playerData.type="replay":this.playerData.type="live")},this)),this.$doc=s(document)},setPlayerData:function(){var e=this.player.crt.$post.data("json");if(this.playerData={postData:e,platform:"web",app_version:null,type:"video",post_id:null,root_post_id:null,blog_uuid:null,vendor:null,duration:this.player.crt.get("duration"),time_elapsed:null},void 0!==e)this.playerData.post_id=e["post-id"],this.playerData.root_post_id=e.root_id,this.playerData.blog_uuid=e.tumblelog;else{var t=this.player.options_.crtOptions;void 0!==t["iframe-post-data"]&&(this.playerData.post_id=t["iframe-post-data"].post_id,this.playerData.blog_uuid=t["iframe-post-data"].blog);var i=t["hls-service"];i&&(this.playerData.type="live",this.playerData.vendor=i)}},bindEvents:function(){this.$player.on("mousedown touchstart",n.bind(this.setTriggerElement,this)),this.player.on("userPlay",n.bind(this.onUserPlay,this)),this.player.on("play",n.bind(this.onVJSPlay,this)),this.player.on("pause",n.bind(this.onVJSPause,this)),this.player.on("loop",n.bind(this.onLooped,this)),this.player.on("end",n.bind(this.onVideoEnded,this)),this.player.on("restart",n.bind(this.onRestart,this)),this.player.on("muteClicked",n.bind(this.onMuteClicked,this)),this.player.on("fullscreenchange",n.bind(this.onFullscreenChange,this)),this.player.on("error",n.bind(this.onError,this)),this.player.on("seeking",n.bind(this.onSeeking,this)),this.player.on("resolutionchange",n.bind(this.onResolutionChange,this)),this.player.on("timeupdate",n.bind(this.onTimeUpdate,this)),this.$player.on("stopwaiting",n.bind(this.onStopWaiting,this)),this.player.on("firstplay",n.bind(this.onLoadStart,this)),this.player.on("loadeddata",n.bind(this.onLoadedData,this))},triggerEvent:function(e,t){t=this._buildLoggingData(t),r.trigger("VideoPlayer:"+e,{loggingData:t})},_buildLoggingData:function(e){return(e=n.extend({},this.playerData,e)).time_elapsed=this.player.crt.getElapsed(),e.position=this.player.crt.getPosition(),e},setTriggerElement:function(e){this.triggerElement=s(e.target)},onLogComplete:function(){this.triggerElement=s()},cacheUnloadData:function(){this.triggerEvent("cacheUnload")},onError:function(e){var t=this.player.error(),i="MEDIA_ERR_CUSTOM";if(t){switch(t.code){case 1:i="MEDIA_ERR_ABORTED";break;case 2:i="MEDIA_ERR_NETWORK";break;case 3:i="MEDIA_ERR_DECODE";break;case 4:i="MEDIA_ERR_SRC_NOT_SUPPORTED";break;case 5:i="MEDIA_ERR_ENCRYPTED"}this.triggerEvent("failed",{code:t.code,name:i})}},onUserPlay:function(e){this.onPlay(!0,e)},onVJSPlay:function(e){this.onPlay(!1,e)},onPlay:function(e,t){if(e||0!==this.triggerElement.closest(".vjs-big-play-button").length||0!==this.triggerElement.closest(".vjs-play-control").length){var i=this.player.crt.get("autoplay"),n={};t.onDock&&(n.onDock=!0),this.logConversion({name:"CONVERSION_ACTION_HTML5_VIDEO",extra:{player:this.player.techName,player_version:2}}),this.triggerEvent(i?"auto_play":"play",n),this.onLogComplete()}},onVJSPause:function(){this.onPause(!1)},onPause:function(e){(e||0!==this.triggerElement.closest(".vjs-big-play-button").length||0!==this.triggerElement.closest(".vjs-play-control").length)&&(this.triggerEvent("pause",this.playerData),this.onLogComplete())},onLooped:function(){this.triggerEvent("loop")},onVideoEnded:function(){this.triggerEvent("end")},onRestart:function(e){var t=n.pick(e,["start","end"]);this.triggerEvent("restart",t)},onFullscreenChange:function(){var e=this.player.isFullscreen();this.triggerEvent("fullscreen",{fullscreen:e}),this.player.crt.set("isFullscreen",e),this.onLogComplete()},onMuteClicked:function(){var e=this.player.muted()?"mute":"unmute";this.triggerEvent(e),this.player.crt.set("muted","mute"===e),this.onLogComplete()},onSeeking:function(){if(0!==this.triggerElement.closest(".vjs-progress-control").length){this.startSeekTime||(this.startSeekTime=this.player.crt.getStartSeekJumpPosition());var e={start:this.startSeekTime};this.triggerEvent("scrub_start",e),this.$doc.one("mouseup.crtEvents touchend.crtEvents",n.bind(this.onSeeked,this))}},onSeeked:function(){if(this.startSeekTime){var e={start:this.startSeekTime,end:this.player.currentTime()};this.triggerEvent("scrub_stop",e),this.startSeekTime=null}},onTimeUpdate:function(){this.triggerEvent("timeupdate")}
1,onResolutionChange:function(e){var t=n.pick(e,"resolution");this.triggerEvent("resolutionchange",t)},onStopWaiting:function(e,t){!t.timeWaited||t.timeWaited<2e3||this.triggerEvent("waiting",t)},onLoadStart:function(){this.loadStartTime=n.now()},onLoadedData:function(){var e=n.now()-this.loadStartTime;this.triggerEvent("initialLoad",{loadTime:e})},logConversion:function(e){if(!this.videoConversionLogged&&a.bool("is_logged_in")&&!this.loggingInProgress){this.loggingInProgress=!0;var t=s.ajax({url:"/svc/log/conversion",type:"POST",contentType:"application/x-www-form-urlencoded",withFormKey:!0,data:"log="+JSON.stringify(e)});t.done(n.bind(this.onConversionSuccess,this)),t.fail(n.bind(this.onConversionFail,this))}},onConversionSuccess:function(){this.videoConversionLogged=!0,this.loggingInProgress=!1},onConversionFail:function(){this.loggingInProgress=!1}});e.exports=c},27641(e,t,i){"use strict";var n=i(97583).extend({logKey:"explore_trending",logOptions:{init_event:!1},events:{"explore-trending:*":"log"},logEnv:{location:document.location.pathname}});e.exports=n},27687(e,t,i){var n=i(55679),s=i(21391),o=i(44890),r=i(27839),a=i(2266),l=i(57220),c=i(31859),u=i(78947),h=i(10708);function d(e,t){e.uuid?e=(t=e).uuid:t||!e||n.isString(e)||(t=e,e=void 0),this.options=n.extend({},this.defaults,t),delete this.options.log_key,delete this.options.env,delete this.options.uuid,a(this,"uuid",e||this._generate_uuid()),t.env||(t.env={}),n.each(t.flags,function(e){t.env.flags||(t.env.flags={}),t.env.flags[e]=o.bool(e)}),a(this,"env",t.env),this.log_key=t.log_key||this.log_key,this.events=[],this.event_count=0,this.pending_events=[],this.event_counts={},this.started_at||(this.started_at=this.options.started_at||r.getRealNow()),delete this.options.started_at,this.initialize(t),this.options.init_event&&this.trigger("init")}n.extend(d.prototype,s.Events,{EventClass:h,initialize:n.noop,_generate_uuid:function(){return u("default_session")||c()},defaults:{init_event:!0,keep_counts:!1},pending_log_events:function(){var e=this.pending_events;return this.pending_events=[],e},generate_relative_id:function(){return this.event_count},unloaded:function(e){e||(e={}),e=this.before_unloaded(e)||{},this.options.keep_counts&&n.extend(e,{event_counts:this.event_counts}),n.isEmpty(e)||this.trigger("unload",e)},before_unloaded:function(e){return e},replaced:function(e){this.before_replaced(e);for(var t=this.pending_log_events();t.length;)this.log_lady.pending_events.push(t.shift())},before_replaced:n.noop,stop:function(){this.log_lady&&this.log_lady.unwatch(this)},trigger:function(e,t){var i=new this.EventClass(this,e,t);return this.options.keep_counts&&"init"!==e&&"unload"!==e&&(this.event_counts[e]||(this.event_counts[e]=0),this.event_counts[e]++),this.event_count+=1,this.pending_events.push(i),s.Events.trigger.call(this,e,i,this),this}}),d.extend=l,e.exports=d},27839(e,t,i){"use strict";var n=i(55679),s=i(28017),o=n.once(function(){return s.get("Context/time")}),r=n.get(window,"Tumblr.getRealNow");if(!r){0;var a=window.performance,l=a&&a.timing&&a.timing.responseStart||Date.now();(r=function(){return o()+(Date.now()-l)}).startedAt=(new Date).getTime(),r.realStartedAt=r()}e.exports={getRealNow:r,startedAt:r.startedAt,realStartedAt:r.realStartedAt,getElapsed:function(e){return(e||r())-r.realStartedAt}}},27845(e,t,i){function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function s(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,o(n.key),n)}}function o(e){var t=function(e,t){if("object"!=n(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var s=i.call(e,t||"default");if("object"!=n(s))return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==n(t)?t:t+""}function r(e,t,i){return t=l(t),function(e,t){if(t&&("object"==n(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,a()?Reflect.construct(t,i||[],l(e).constructor):t.apply(e,i))}function a(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(a=function(){return!!e})()}function l(e){return l=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},l(e)}
1function c(e,t){return c=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},c(e,t)}var u=i(55679),h=i(77171),d=i(33309);function p(e){return e?"1":"0"}var g=function(e){function t(e,i){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(n=r(this,t,[e.video,i])).videoPlayer=e,n.duration=0,n.timedMacroState={},n.currentTimePos=0,n.isInViewHalfTime=!1,n.setupMacroValues(),n.addEventListeners(),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&c(e,t)}(t,e),i=t,(n=[{key:"setupMacroValues",value:function(){this.callbackMacros={"$(V_SKIP_AVAIL)":this.macroIsSkipAvailable,"$(V_AUTOPLAYED)":this.macroIsAutoplayed,"$(V_PLAYER_WIDTH)":this.getElWidth,"$(V_PLAYER_HEIGHT)":this.getElHeight,"$(V_EXPANDED)":this.macroIsExpanded,"$(V_MUTED)":this.macroIsMuted,"$(V_AUD_INFO)":this.macroIsMuted,"$(V_MOAT_IVT)":this.getIVT,"$(V_VIEW_INFO)":this.macroIsInView,"$(V_IS_INVIEW_100_HALFTIME)":this.macroIsInViewHalfTime,"$(V_AUD_TIME_INVIEW_100)":this.getTimedMacroValue,"$(V_TIME_INVIEW_50)":this.getTimedMacroValue,"$(V_TIME_INVIEW_50_MAX_CONTINUOUS)":this.getTimedMacroValue},this.timedMacros={"$(V_AUD_TIME_INVIEW_100)":{a:!0,p:100},"$(V_TIME_INVIEW_50)":{p:50},"$(V_TIME_INVIEW_50_MAX_CONTINUOUS)":{c:!0,p:50},"$(V_IS_INVIEW_100_HALFTIME)":{c:!0,p:100}},this.setAutoplayState(),this.resetAllTimedMacroState()}},{key:"resetTimedMacroState",value:function(e){var t=this;u.forEach(this.timedMacros,function(i,n){e(i)&&(t.timedMacroState[n]=0)})}},{key:"resetAllTimedMacroState",value:function(){this.resetTimedMacroState(function(e){return!0})}},{key:"resetContinuousTimedMacros",value:function(){this.resetTimedMacroState(function(e){return e.c})}},{key:"resetAudioTimedMacros",value:function(){this.resetTimedMacroState(function(e){return e.a})}},{key:"setAutoplayState",value:function(){this.autoplay=this.videoPlayer.player.crt.get("autoplay")}},{key:"isAutoplay",value:function(){return this.autoplay}},{key:"macroIsAutoplayed",value:function(){return p(this.isAutoplay())}},{key:"macroIsSkipAvailable",value:function(){return p(!1)}},{key:"macroIsInViewHalfTime",value:function(e){if(!1===this.isInViewHalfTime){var t=1e3*this.maxDuration()/2;this.getTimedMacroValue(e)>=Math.min(15e3,t)&&(this.isInViewHalfTime=!0)}return p(this.isInViewHalfTime)}},{key:"macroIsInView",value:function(){return this.percentageInView()>=50?1:2}},{key:"isMuted",value:function(){return this.videoPlayer.player.crt.get("muted")}},{key:"macroIsMuted",value:function(){return!1===this.isMuted()?"1":"2"}},{key:"isExpanded",value:function(){return this.videoPlayer.player.crt.get("isFullscreen")}},{key:"macroIsExpanded",value:function(){return p(this.isExpanded())}},{key:"getIVT",value:function(){var e=u.get(window,"DARLA.metrics.getIvtSignals");return e?window.encodeURIComponent(e()):"-1"}},{key:"addEventListeners",value:function(){this.videoPlayer.on({"change:muted":this.handleMute,"change:paused":this.handlePause,"change:_position":this.positionChanged},this),this.videoPlayer.player.on("loop",u.bind(this.handleLoop,this))}},{key:"handleMute",value:function(e,t){t&&this.resetAudioTimedMacros(),this.stateChangeFn(d.POSITION_CHANGE)}},{key:"handlePause",value:function(){this.stateChangeFn(d.RESET_CONTINUOUS),this.resetContinuousTimedMacros()}},{key:"positionChanged",value:function(e,t){this.processTimedMacros(t),this.currentTimePos=t,this.stateChangeFn(d.POSITION_CHANGE)}},{key:"handleLoop",value:function(){this.resetState(),this.stateChangeFn(d.RESET)}},{key:"timePosition",value:function(){return this.currentTimePos}},{key:"maxDuration",value:function(){return 0===this.duration&&(this.duration=this.videoPlayer.player.crt.get("duration")),this.duration}},{key:"resetState",value:function(){this.resetAllTimedMacroState()}},{key:"processTimedMacros",value:function(e){var t=this;u.forEach(this.timedMacros,function(i,n){var s=!0,o=!0;if(i.a&&t.videoPlayer.player.crt.get("muted")&&(s=!1),i.p&&t.percentageInView()<i.p&&(o=!1),s&&o){var r=e-t.timePosition();t.timedMacroState[n]=Math.min(t.maxDuration(),t.timedMacroState[n]+r)}else!0===i.c&&(t.timedMacroState[n]=0)})}},{key:"getTimedMacroValue",value:function(e){return Math.round(1e3*this.timedMacroState[e])}},{key:"getDurationMacroValue",value:function(e,t){return p(this.timedMacroState[e]>=t)}},{key:"getMacroValue",value:function(e){return this.callbackMacros[e]?this.callbackMacros[e].call(this,e):"-1"}}])&&s(i.prototype,n),o&&s(i,o),Object.defineProperty(i,"prototype",{writable:!1}),i;var i,n,o}(h);e.exports=g},27880(e,t,i){"use strict";var n=i(74692),s=i(91685),o=i(26024),r=s.extend(o,{seeking:!1,render:function(){return this.$el=n('<div class="vjs-hover-handle vjs-slider-handle" aria-live="off"><span class="vjs-control-text"></span></div>'),this},update:function(e){e||(e={}),this.$time_el=this.$time_el||this.$el.find(".vjs-hover-handle-time");var t=e.hoverX||0,i=e.hoverTime||"0:00",n=s.formatTime(i);this.$time_el.html(n),this.$el.css("left",t+"px")}});e.exports=r},27975(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, \'\') }\nwith (obj) {\n__p += \'<form action="/search" method="get"><input type="text" placeholder="\' +\n__e( __(\'Search Tumblr\') ) +\n\'" autocomplete="off" class="search-input" id="search-input" name="q" value="\';\n if (search_term) { ;\n__p +=\n__e( search_term );\n } ;\n__p += \'"> <input type="hidden" class="search-nsfw-filter-input" name="filter_nsfw"> <input type="hidden" class="filter-sort-input" name="sort" value="top"> <input type="hidden" class="filter-post-type-input" name="filter_post_type" value="any"> \' +\n((__t = ( _subview(\'loader\') )) == null ? \'\' : __t) +\n\' </form>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},28017(e,t,i){var n,s=i(55679);e.exports={get:function(e){if(!n)throw new Error("Data hasn't been initialized with `setup`.");if(!s.isString(e))return null;var t=s.get(n,e.replace(/\//g,"."));return s.cloneDeep(t)},has:function(e){if(!n)throw new Error("Data hasn't been initialized with `setup`.");return s.isString(e)?s.has(n,e.replace(/\//g,".")):null},setup:s.once(function(e){n=s.isObject(e)?e:{}})}},28497(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<div class="form-container form"><div class="survey"><div class="survey-step"></div></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},28724(e,t,i){var n=i(55679);function s(e,t){n.each(t,function(t,i){var n=e[i];e[i]=function(){return t.apply(this,arguments),n.apply(this,arguments)}})}function o(e,t){n.each(t,function(t,i){var n=e[i];e[i]=function(){var e=n.apply(this,arguments);return t.apply(this,arguments),e}})}function r(e,t){n.each(t,function(t,i){var s=e[i];e[i]=function(){var e=n.toArray(arguments);return e.unshift(n.bind(s,this)),t.apply(this,e)}})}function a(e,t){n.each(t,function(t,i){var s=i in e&&e[i];e[i]=function(){var e=n.toArray(arguments),i=s?n.bind(s,this):n.noop;return e.unshift(i),t.apply(this,e)}})}function l(){this.mixins=n.filter(arguments,function(e){return e instanceof l}),this.properties=arguments[this.mixins.length]||{}}l.prototype.mixins=null,l.prototype.properties=null,l.prototype.applyTo=function(e){var t=this.properties;!function(e,t){n.defaults(e,t)}(e,t.defaults),function(e,t){n.extend(e,t)}(e,t.extend),n.extend(e,n.omit(t,"before","after","around","onto","defaults","extend","applyTo")),n.invoke(this.mixins,"applyTo",e),s(e,t.before),o(e,t.after),r(e,t.around),a(e,t.onto),n.isFunction(t.applyTo)&&t.applyTo.apply(this,arguments)},l.before=s,l.after=o,l.around=r,l.onto=a,e.exports=l},29016(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"form-container success\"><div class=\"success-message\"><h1 class=\"message-title\"> ' +\n((__t = ( __('Got it') )) == null ? '' : __t) +\n' </h1> ';\n if (customSuccessMessage) { ;\n__p += ' ';\n if (customSuccessMessage instanceof Array) { ;\n__p += ' ';\n _.each(customSuccessMessage, function(line) { ;\n__p += ' ';\n if (line.link) { ;\n__p += ' <p class=\"message-text\">' +\n((__t = ( __(line.text, '<a class=\"message-link\"  target=\"_blank\" href=\"'+ line.link +'\">', '</a>') )) == null ? '' : __t) +\n'</p> ';\n } else { ;\n__p += ' <p class=\"message-text\">' +\n((__t = ( __(line.text) )) == null ? '' : __t) +\n'</p> ';\n } ;\n__p += ' ';\n }); ;\n__p += ' ';\n } else { ;\n__p += ' <p class=\"message-text\"> ' +\n__e( customSuccessMessage ) +\n' </p> ';\n } ;\n__p += ' ';\n } else if (alternativeResponseText) { ;\n__p += ' <p class=\"message-text\"> ' +\n__e( __('Thanks for bringing this to our attention. We\\'re looking into it.') ) +\n' </p> ';\n } else { ;\n__p += ' <p class=\"message-text\"> ' +\n__e( __('We\\'re on the case and we\\'ll get back to you as soon as we can.') ) +\n' </p><p class=\"message-text\"> ' +\n__e( __('Also: We know it\\'s tempting to submit the same thing a few times in hopes that it\\'ll get addressed sooner, but really it just clogs up our system and makes it harder for us to respond quickly. We\\'re kind of like an elevator button.') ) +\n' </p> ';\n } ;\n__p += ' ';\n if (inNativeApp) { ;\n__p += ' <button class=\"chrome big blue\" onclick=\"history.go(-1)\">' +\n__e( __('Done') ) +\n'</button> ';\n } ;\n__p += ' </div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},29131(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"gif-search-message-container\"> ';\n if (header) { ;\n__p += ' <h2 class=\"gif-search-message-header\">' +\n((__t = ( header )) == null ? '' : __t) +\n'</h2> ';\n } ;\n__p += ' <div class=\"gif-search-message-body\">' +\n((__t = ( body )) == null ? '' : __t) +\n'</div> ';\n if (hasResults) { ;\n__p += ' <p><span class=\"gif-search-show-results\" data-js-showresults>' +\n__e( __('View results anyway') ) +\n'</span></p> ';\n } ;\n__p += ' </div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},29546(e){"use strict";e.exports={modal:1,inline:2}},29697(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(80976).Ay,r=i(27496),a=i(44384),l=i(93257),c=i(49737),u=i(56515),h=i(49746),d=i(48256),p=i(10737),g=i(21343),f=i(95870),m=i(6479),_=a.extend({events:{"click .post_content a":"contentLinkClick"},hasSubViews:{header:l,content:c,footer:u,tags:h},initialize:function(e){a.prototype.initialize.apply(this,arguments),this.render()},render:function(){a.prototype.render.apply(this,arguments),this.bindEvents(),d.hasInstance()&&"photo"===this.model.get("type")&&(this.livePhoto=d.getInstance().create(this.$el.find("[data-live-photo]")));var e=this.$el.find("[data-carousel]");e.length&&(this.carousel=new p({el:e,model:this.model,redirectUrlPrimary:e.data("redirect-url-primary")}),e.append(this.carousel.render().$el));var t=this.$el.find("[data-native-audio]");return t.length&&(this.audio=new g({el:t,model:this.model,albumArt:t.data("album-art"),streamUrl:t.data("stream-url"),track:t.data("track"),artist:t.data("artist"),noId3:t.data("no-id3"),preview:!1}),t.append(this.audio.render().$el)),this},bindEvents:function(){this.listenTo(r,"flagged:"+this.model.tumblelog.get("name"),this.onFlagged),this.scrollMonitor=o.create(this.$el,-this.$el.height()/2),this.scrollMonitor.enterVie
1wport(n.bind(this.onViewportEnter,this)),this.listenTo(this.model,"like:set",this.onLike),this.listenTo(this.model,"unlike:set",this.onUnlike),this.listenTo(this.model,"reblog:success",this.onReblog)},contentLinkClick:function(e){var t=e.currentTarget.href,i=s(e.currentTarget),n=f.parseTumblelogUrl(t);if(m()&&!i.is(".sponsored_post, .read_more")&&n){var o={tumblelog_name:n.tumblelog_name};if(t.indexOf("tagged/")>-1){var a=t.split("tagged/")[1];""!==a&&(o.searchTagTerm=a)}n.post_id&&(o.post_id=n.post_id),e.preventDefault(),e.stopPropagation(),r.trigger("peepr-open-request",o)}},onViewportEnter:function(e){var t={loggingData:{id:this.model.get("id"),tumblelog:this.model.get("tumblelog")}};r.trigger("search:post:impression",t),this.scrollMonitor.destroy()},onFlagged:function(e){this.$el.addClass("is_flagged")},onLike:function(){this.logEvent("like")},onUnlike:function(){this.logEvent("unlike")},onReblog:function(){this.logEvent("reblog")},loggingData:function(){return{post_id:this.model.get("id"),blog:this.model.get("tumblelog"),initiator:"post_masonry"}},logEvent:function(e){r.trigger("search-post:logging-event",e,this.loggingData())}});e.exports=_},29758(e,t,i){"use strict";var n=i(50283),s=i(77594),o=i(98237),r=i(3006),a=i(81515),l=i(55679),c=i(25462),u=n.extend({className:"gif-search-input",template:r,mixins:[s,o],defaults:{isFocused:!1},events:{"focus [data-js-plainTextEditor]":"_onFocus","blur [data-js-plainTextEditor]":"_onBlur"},subviews:{textEditor:{constructor:c,options:function(e){return{forceSingleLine:!0,placeholder:a("Find a GIF"),syncWithModel:!1,onChange:l.debounce(l.bind(e._onUserChangeInput,e),250)}}}},initialize:function(e){e=l.extend({},e),l.extend(this,l.pick(e,"eventBus","keyboardManager","keyboardNamespace"))},afterRender:function(){this.listenTo(this,"change:isFocused",this._onChangeIsFocused)},_onChangeIsFocused:function(e,t){t?(this.keyboardManager.add(this.keyboardNamespace,this),this.trigger("focus",this)):(this.keyboardManager.remove(this.keyboardNamespace),this.trigger("blur",this))},_onUserChangeInput:function(){this.trigger("userQueryChanged",this.textEditor.getEditorValue())},focus:function(){this.textEditor.focus()},_onFocus:function(){this.set("isFocused",!0)},_onBlur:function(){this.set("isFocused",!1)},setValue:function(e){this.textEditor.setEditorValue(e)}});e.exports=u},29833(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(38578),r=i(21632),a=s.extend({template:r,className:"page-title",mixins:[o],initialize:function(e){e=n.extend({},e),n.extend(this.attributes,e)},render:function(){return this.$el.html(this.template(this.toJSON())),this}});e.exports=a},29970(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(44890),r=i(28017),a=i(71092),l=i(27496),c=i(90263),u=i(95870),h=i(81515),d=i(57988),p=i(30800),g=i(91852),f=a.extend({className:"indash_tumblelog_compact",template:d,defaults:{current_data:{},unfollow_data:{},follow_data:{},template_data:{},hide_posts_on_unfollow:!1,stripDescriptionLineBreaks:!1,include_info_popover:!0},events:{"click .description a":"_descriptionLinkClicked","click .info_popover_button":"_infoPopoverButtonClicked","click .follow":"_onFollowClick","click .unfollow":"_onFollowClick"},initialize:function(e){if(this.options=n.extend({},this.defaults,e||{}),this.bindEvents(),this.is_rendered=!1,this.assets_host=r.get("Context/hosts/assets_host")||"",this.$description=null,this.$description_inner=null,!n.isEmpty(this.current_data)){var t=n.extend({},this.current_data,this.model.toJSON());this.model.set(t,{silent:!0})}this.model.get("global_theme_params")&&n.delay(n.bind(this.render,this),1)},bindEvents:function(){this.listenTo(this.model,"change:following",this._renderFollowButton),this.listenTo(this.model,"change:global_theme_params",this.render)},render:function(){var e=this.model.toJSON();if(e.following||(e.following=!1),this.is_rendered||!e.global_theme_params)return this;var t=n.result(p,e.global_theme_params.title_font),i=c.hexToRgb(e.global_theme_params.title_color);return this.$el.html(this.template(n.merge({},e,{hide_headers_flag:o.bool("hide_default_headers_blog_cards"),blog_card_compact:!0,show_navigation:!0,show_share_controls:!1,show_user_controls:this.options.include_info_popover,show_follow_button:!0,show_dismiss_controls:!1,title_font_family:!!t&&t.family,title_color_rgb:String(n.values(i).join(",")),followText:h("Follow"),unfollowText:h("Unfollow")},this.options.template_data))),this.$description=this.$(".description"),this.$description_inner=this.$description.find(".description_inner"),this._renderFontStyles(),this._renderInlineStyles(),this.__addSnowMan(),this.is_rendered=!0,this.$description.length&&(n.delay(n.bind(this.truncateDescription,this),100),this.options.stripDescriptionLineBreaks&&this.stripDescriptionLineBreaks()),this.trigger("ready"),this},stripDescriptionLineBreaks:function(){this.$description_inner.find("br").remove();var e=this.$description_inner.html().replace(/[\n\r]/g," ");this.$description_inner.html(e)},truncateDescription:function(){var e=this.$description_inner.get(0);if(!(e.scrollHeight<=e.clientHeight)){var t=this.model.get("global_theme_params").background_color,
1i=c.hexToRgb(t);this.$description.append(this.description_gradient_template({background_color:String(n.values(i).join(","))}))}},__addSnowMan:function(){var e={el:this.$("[data-snowman-container]"),tumblelogName:this.model.get("name")};this.options.include_info_popover&&(e.infoPopover={el:this.$el,auto_show:!1,trigger:this.$el.find(".info_popover_button"),useRecipient:!0,showAsks:!0,showAnonymousAsks:!0,skip_glass:!0,targetPost:this.options.targetPost}),this.snowman=new g(e)},_onFollowClick:function(e){if(e.preventDefault(),o.bool("is_logged_in")){var t={follow_data:this.options.follow_data};this.model.get("following")?this._confirm_unfollow(t):(l.trigger("tumblelog:log_follow"),this.model.follow(t))}else window.open("/follow/"+this.model.get("name"),"_self")},_confirm_unfollow:function(e){var t={tumblelog:this.model.get("name")},i=this.model.requestUnfollow();if(this.options.disableUnfollowConfirm)i.resolve(),l.trigger("tumblelog:log_unfollow",{loggingData:t});else{var n={text:h("Are you sure you want to unfollow %1$s?").replace("%1$s","<strong>"+this.model.get("name")+"</strong>"),text_ok:h("Ok"),text_cancel:h("Nevermind")};i.promise.then(function(){l.trigger("tumblelog:log_unfollow",{loggingData:t})}),l.trigger("dialog:confirm:promise",i,n)}},_infoPopoverButtonClicked:function(e){e.preventDefault(),e.stopPropagation(),l.trigger("popticainfopopover:show")},_descriptionLinkClicked:function(e){e.preventDefault();var t=s(e.currentTarget).attr("href");try{if(u&&u.hasAllowedProtocol(t)){if(!u.isAbsoluteUrl(t))t="http://"+this.model.get("name")+".tumblr.com/"+(t="/"===t.charAt(0)?t.substr(1):t);window.open(t,"_blank")}}catch(e){0}},_renderFollowButton:function(){var e=this.model.get("following");this.$el.find(".follow").toggle(!e),this.$el.find(".unfollow").toggle(e)},_hidePosts:function(){},_open_dialog:function(e,t){function i(e,t){e.is_disabled=e.is_menu_open,t&&t()}this.is_disabled=!0,e.fail(n.bind(i,null,this)),e.done(n.bind(i,null,this,t))},_renderInlineStyles:function(){var e=this.model.get("global_theme_params"),t=this.model.get("has_default_header")&&o.bool("hide_default_headers_blog_cards"),i=!(!(e.header_image_focused&&e.header_stretch&&e.show_header_image)||t),n=c.hexToHsv(e.background_color),s=c.hexToHsv(e.link_color),r=e.link_color;return c.compare(s,n)&&(r=c.readable(n)),i||(this.$(".navigation .nav_icon").css("color",r),this.$(".navigation .blog_name").css("color",r),this.$(".navigation button").css({color:e.background_color,"background-color":r})),this.$(".description a").css("color",e.link_color),this},_renderFontStyles:function(){if(p){var e=this.model.get("global_theme_params");if(n.has(p,e.title_font)){var t=n.result(p,e.title_font),i="webfont_"+t.path;if(t.path&&!s("head #"+i).length){var o=this.assets_host+"/fonts/"+t.path+"/stylesheet.css";o+=n.has(t,"_v")?"?v="+t._v:"",s("<link>",{id:i,rel:"stylesheet",type:"text/css",href:o}).appendTo(s("head"))}}}},description_gradient_template:n.template('<div class="description_gradient" style="background: -moz-linear-gradient(top,  rgba(<%= background_color %>,0) 0%, rgba(<%= background_color %>,0.75) 50%, rgba(<%= background_color %>,1) 100%);background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(<%= background_color %>,0)), color-stop(50%,rgba(<%= background_color %>,0.75)), color-stop(100%,rgba(<%= background_color %>,1)));background: -webkit-linear-gradient(top,  rgba(<%= background_color %>,0) 0%,rgba(<%= background_color %>,0.75) 50%,rgba(<%= background_color %>,1) 100%);background: -o-linear-gradient(top,  rgba(<%= background_color %>,0) 0%,rgba(<%= background_color %>,0.75) 50%,rgba(<%= background_color %>,1) 100%);background: -ms-linear-gradient(top,  rgba(<%= background_color %>,0) 0%,rgba(<%= background_color %>,0.75) 50%,rgba(<%= background_color %>,1) 100%);background: linear-gradient(to bottom, rgba(<%= background_color %>,0) 0%,rgba(<%= background_color %>,0.75) 50%,rgba(<%= background_color %>,1) 100%);"></div>')});e.exports=f},30106(e,t,i){"use strict";var n=i(55679),s=i(58527),o=i(95921).truncateLongStrings;function r(){}r.prototype.genericFieldMap={two:"caption",three:"linkthrough"},r.prototype.editorField="two",r.prototype.typeAttributes={caption:"",layout:"",linkthrough:"",photos:[]},r.prototype.allowAnswerFields=["caption"],r.prototype.generateTweetText=function(e,t){var i=this.getHtmlStripped("caption");return i=i.replace(/[\r\n\s]*\[\[MORE\]\].*$/gi,""),o(i,t)},r.prototype.MAX_IMAGES=10,r.prototype.resetPreserveFields=["caption","tags"],r.prototype.afterDelegate=function(e){e.apply(this,n.rest(arguments)),this.photos=new s(this.attributes.photos,{parse:!0}),this.on("change:photos",function(e,t){this.photos.reset(t,{parse:!0}),delete this.attributes.photos},this),this.trigger("change:photos",this,this.get("photos")),this.listenTo(this.photos,"add remove change:preuploadUrl change:externalUrl",function(){this.trigger("validate")})},r.prototype.parseForType=function(e,t,i){return t.layout=i.photoset_layout,delete t.photoset_layout,t},r.prototype.serializeForServer=function(e){var t=this,i=e.apply(this,n.rest(arguments));
1return n.forEach(this.photos.toJSON(),function(e){i["images["+e.id+"]"]=e.uploadUrl,i["caption["+e.id+"]"]=(e.caption||"").substr(0,200),i["photo_redirect_url_primary["+e.id+"]"]=e.primaryUrl||"",i["photo_redirect_url_ios["+e.id+"]"]=e.iosUrl||"",i["photo_redirect_url_android["+e.id+"]"]=e.androidUrl||"",e.photoRaw&&(i.photo_raw=e.photoRaw,i.is_selfie_gif=e.isSelfieGif,i.is_selfie=e.isSelfie)}),i["post[carousel_display]"]=t.get("carouselDisplay"),i["post[redirect_url_primary]"]=t.get("redirectUrlPrimary"),i["post[photoset_layout]"]=t.get("layout"),i["post[photoset_order]"]=this.photos.pluck("id").join(","),i},r.prototype.canAddPhotos=function(e){return this.photos.length<this.MAX_IMAGES},r.prototype.validate=function(e,t,i){var n=[];return 0===this.photos.length&&n.push("No photos specified."),this.photos.all(function(e){return e.getUploadUrl()||!e.has("upload")})||n.push("Uploads in progress."),e.call(this,t,{errors:n})},e.exports=r},30190(e,t,i){"use strict";var n=i(55679);e.exports=function(e,t){return{constructor:e,options:function(e){var i=n.isFunction(t)?t(e):t;return n.extend(n.pick(e,e.viewOptionKeys),i)}}}},30291(e,t,i){"use strict";var n=i(55679),s=i(21391),o=i(80160);e.exports.extend=function(e,t){e||(e={}),t||(t={});var i=new s.Collection,r=Object.create(null),a=Object.create(null),l=e.idAttribute||o.prototype.idAttribute;return e.constructor=function(e,t){var s,o;if(!n.isObject(e))throw new Error("SingletonModel requires attributes");if(s=e[l],n.isEmpty(s)&&!n.isNumber(s)&&n.defer(function(){throw new Error('SingletonModel attributes require a "'+l+'"')}),o=r[s],a[s]++||(a[s]=1),o)n.keys(e).length>=2&&o.set(e,t),!0!==o.collection&&(o.collection=!0);else{r[s]=this;try{Object.defineProperty(this,"collection",{value:!0,configurable:!1,enumerable:!0,writable:!1})}finally{this.collection||(this.collection=!0)}this.constructor.__super__.constructor.call(this,e,t),i.add(this)}return o||this},e.release=function(){0===--a[this.id]&&(delete r[this.id],delete a[this.id],i.remove(this))},e.toString=function(){return this.id},e.toJSON=e.toJSON||o.prototype.toJSON,t.getCollection=function(){return i},o.extend(e,t)}},30321(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(50283),r=i(13701),a=i(57982),l=i(98237),c=i(78421),u=i(21189),h=o.extend({className:"gif-search-result",tagName:"a",attributes:{href:"#",tabIndex:1},template:r,events:{"click [data-js-select]":"_onClickSelect","click [data-js-tag]":"_onClickTag",mouseenter:"_onMouseEnter",mouseleave:"_onMouseLeave"},mixins:[l],defaults:{skipTags:["gif","gifs"],imageWidth:null,isVirtualized:!0,hasStillImage:!0,isPreselected:!1,unloadImageOnVirtualize:!1,isLoaded:!1,isSelectable:!0,loadFullImageBeforeSelect:!0,loadingFullImage:!1,containerWidth:150,isImpressionLogged:!1,isSelected:!1},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","onSelect","onClear")),this._loadDefer=u.defer()},afterRender:function(){this.listenTo(this,"change:isPreselected",this._onChangeIsPreselected),this.listenTo(this,"change:isVirtualized",this._onChangeIsVirtualized),this.listenTo(this,"change:hasStillImage",this._onChangeHasStillImage),this.listenTo(this,"change:isSelectable",this._onChangeIsSelectable),this.listenTo(this,"change:isLoaded",this._onChangeIsLoaded),this.listenTo(this,"change:isSelected",this._onChangeIsSelected),this.listenTo(this.eventBus,"image:full:cancelLoad",this._onCancelAllFullImageLoads),this._onChangeIsVirtualized(this,this.get("isVirtualized")),this._onChangeHasStillImage(this,this.get("hasStillImage")),this._onChangeIsPreselected(this,this.get("isPreselected")),this._onChangeIsSelectable(this,this.get("isSelectable")),this._onChangeIsLoaded(this,this.get("isLoaded"))},getTemplateData:function(){var e=this.model.toJSON(),t=e.popularSearchTag?[e.popularSearchTag]:e.postTags,i=this.get("skipTags"),s=this.get("containerWidth"),o=Math.round(this.model.get("height")*(s/this.model.get("width")));return t=n.reject(t,function(e){return n.contains(i,e.toLowerCase())}),n.extend(e,{tags:t.slice(0,3),width:s,height:o}),this.get("imageWidth")&&n.extend(e,{mediaUrl:e.mediaUrl.replace(/_\d+\./,"_"+this.get("imageWidth")+".")}),e},loadImage:function(){var e=this.js$("img"),t=e.attr("data-img-src");return this.get("isLoaded")||(e.attr("src",t),a.load(t,100).then(n.bind(function(){this.rendered&&this.set("isLoaded",!0),this._loadDefer.resolve()},this))),this._loadDefer.promise},unloadImage:function(){this.js$("img").removeAttr("src")},refreshStillImage:function(){this._onChangeHasStillImage(this,this.get("hasStillImage"))},getLoadPromise:function(){return this._loadDefer.promise},_onCancelAllFullImageLoads:function(){this._cancelLoadFullImage()},_onClickSelect:function(e){e.preventDefault(),n.isFunction(this.onSelect)&&this.onSelect(this,this.model);var t=this.model.get("mediaUrl"),i=this.js$("img").attr("src"),s=function(){this.$el.addClass("gif-search-result--selected"),this.eventBus.trigger("image:select",this.model,this)};this.get("loadFullImageBeforeSelect")&&t!==i?this._loadFullImage(t,s):s.call(this)},select:function(e){this._onClickSelect(e)},_loadFullImage:function(e,t){this.eventBus.trigger("image:full:cancelLoad"),this.set("loadingFullImage",!0),this.eventBus.trigger("image:full:loading"),this.loader=new c({variation:"centered small",loading:!0}),this.$el.addClass("loading-full").append(this.loader.render().$el),a.load(e).then(n.bind(function(){this.get("loadingFullImage")&&n.isFunction(t)&&t.call(this)},this)).finally(n.bind(this._cancelLoadFullImage,this))},_cancelLoadFullImage:function(){this.rendered&&this.get("loadingFullImage")&&(this.loader&&(this.loader.remove(),this.loader=null),this.$el.removeClass("loading-full"),this.set("loadingFullImage",!1))},_onClickTag:function(e){var t=s(e.target).attr("data-js-tag");this.eventBus.trigger("image:tag",t,this.model),e.preventDefault(),e.stopPropagation()},_onChangeIsPreselected:function(e,t){this.$el.toggleClass("gif-search-result--preselected",t)},_onChangeIsVirtualized:function(e,t){this.$el.toggleClass("off",t),t&&this.get("unloadImageOnVirtualize")?this.unloadImage():t||this.loadImage()},_onChangeHasStillImage:function(e,t){this._removeStillCanvas(),t&&this._prepareCreateStillCanvas()},_onChangeIsSelectable:function(e,t){this.$el.toggleClass("gif-search-result--selectable",t)},_onChangeIsLoaded:function(e,t){this.$el.toggleClass("loaded",t)},_createStillCanvas:function(){if(this.rendered){var e=this.js$("img"),t=e.parent(),i=parseInt(e.width(),10),n=parseInt(e.height(),10),o=s("<canvas />").attr({width:i,height:n});this.$("canvas").remove(),t.append(o),o.get(0).getContext("2d").drawImage(e.get(0),0,0,i,n),this.$el.addClass("show-still")}},_prepareCreateStillCanvas:function(){this.getLoadPromise().then(n.bind(this._createStillCanvas,this)).catch(n.noop)},_removeStillCanvas:function(){this.$("canvas").remove(),this.$el.removeClass("show-still")},setSelected:function(e){this.rendered&&this.set("isSelected",e)},_onChangeIsSelected:function(e,t){this.$el.toggleClass("selected",t),this.$el.focus()},_onMouseEnter:function(e){n.isFunction(this.onSelect)&&this.onSelect(this)},_onMouseLeave:function(e){n.isFunction(this.onClear)&&this.onClear(this)}});e.exports=h},30351(e,t,i){"use strict";i.d(t,{Ay:()=>p,I3:()=>c,Ot:()=>h,SK:()=>d,T9:()=>u});var n=i(55679),s=i(27839),o=i(98052),r=i.n(o),a=i(8579),l=i.n(a),c="pt",u="/services/bblog";function h(e){var t=[];
1return(0,n.forEach)(e,function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=e.pt,s=e.event_data,o=(0,n.find)(t,{pt:i});o||(o={pt:i,events:[]},t.push(o)),o.events.push(s)}),t}var d=r().extend({build_payload:function(){var e=r().prototype.build_payload.call(this),t=this.event_payload_name&&(0,n.isEmpty)(e[this.event_payload_name]);return(0,n.isEmpty)(e)||t?{}:(e.flushTime=(0,s.getRealNow)(),e)}});const p=new d({EventClass:l(),event_payload_name:"trackers",event_filter:function(e){var t=e.data;return(0,n.has)(t,c)},payload_formatter:h,endpoint:u})},30365(e,t){!function(t){"use strict";var i=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.msRequestAnimationFrame||function(e){return window.setTimeout(e,1e3/60)};function n(){this.frames=[],this.lastId=0,this.raf=i,this.batch={hash:{},read:[],write:[],mode:null}}n.prototype.read=function(e,t){var i=this.add("read",e,t),n=i.id;return this.batch.read.push(i.id),"reading"===this.batch.mode||this.batch.scheduled||this.scheduleBatch(),n},n.prototype.write=function(e,t){var i=this.add("write",e,t),n=this.batch.mode,s=i.id;return this.batch.write.push(i.id),"writing"===n||"reading"===n||this.batch.scheduled||this.scheduleBatch(),s},n.prototype.defer=function(e,t,i){"function"==typeof e&&(i=t,t=e,e=1);var n=this,s=e-1;return this.schedule(s,function(){n.run({fn:t,ctx:i})})},n.prototype.clear=function(e){if("function"==typeof e)return this.clearFrame(e);e=Number(e);var t=this.batch.hash[e];if(t){var i=this.batch[t.type],n=i.indexOf(e);delete this.batch.hash[e],~n&&i.splice(n,1)}},n.prototype.clearFrame=function(e){var t=this.frames.indexOf(e);~t&&this.frames.splice(t,1)},n.prototype.scheduleBatch=function(){var e=this;this.schedule(0,function(){e.batch.scheduled=!1,e.runBatch()}),this.batch.scheduled=!0},n.prototype.uniqueId=function(){return++this.lastId},n.prototype.flush=function(e){for(var t;t=e.shift();)this.run(this.batch.hash[t])},n.prototype.runBatch=function(){try{this.batch.mode="reading",this.flush(this.batch.read),this.batch.mode="writing",this.flush(this.batch.write),this.batch.mode=null}catch(e){throw this.runBatch(),e}},n.prototype.add=function(e,t,i){var n=this.uniqueId();return this.batch.hash[n]={id:n,fn:t,ctx:i,type:e}},n.prototype.run=function(e){var t=e.ctx||this,i=e.fn;if(delete this.batch.hash[e.id],!this.onError)return i.call(t);try{i.call(t)}catch(e){this.onError(e)}},n.prototype.loop=function(){var e=this,t=this.raf;this.looping||(t(function i(){var n=e.frames.shift();e.frames.length?t(i):e.looping=!1,n&&n()}),this.looping=!0)},n.prototype.schedule=function(e,t){return this.frames[e]?this.schedule(e+1,t):(this.loop(),this.frames[e]=t)},t=t||new n,void 0!==e&&e.exports?e.exports=t:"function"==typeof define&&define.amd?define(function(){return t}):window.fastdom=t}(window.fastdom)},30764(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div class=\"ui_dialog ' +\n((__t = ( type )) == null ? '' : __t) +\n'\"> ' +\n((__t = ( content_html )) == null ? '' : __t) +\n' <div class=\"buttons\">' +\n((__t = ( buttons_html )) == null ? '' : __t) +\n'</div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},30785(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n\n if (typeof language !== 'undefined' && typeof width !== 'undefined') { ;\n__p += ' <div class=\"tumblr-post\" data-href=\"' +\n__e( embed_host ) +\n'/embed/post/' +\n__e( embed_key ) +\n'/' +\n__e( post_id ) +\n'\" data-did=\"' +\n__e( embed_did ) +\n'\" data-language=\"' +\n__e( language ) +\n'\" data-width=\"' +\n__e( width ) +\n'\"><a href=\"' +\n__e( post_url ) +\n'\">' +\n__e( post_url ) +\n'</a></div> ';\n } else if (typeof language != 'undefined') { ;\n__p += ' <div class=\"tumblr-post\" data-href=\"' +\n__e( embed_host ) +\n'/embed/post/' +\n__e( embed_key ) +\n'/' 
1+\n__e( post_id ) +\n'\" data-did=\"' +\n__e( embed_did ) +\n'\" data-language=\"' +\n__e( language ) +\n'\"><a href=\"' +\n__e( post_url ) +\n'\">' +\n__e( post_url ) +\n'</a></div> ';\n } else if (typeof width != 'undefined') { ;\n__p += ' <div class=\"tumblr-post\" data-href=\"' +\n__e( embed_host ) +\n'/embed/post/' +\n__e( embed_key ) +\n'/' +\n__e( post_id ) +\n'\" data-did=\"' +\n__e( embed_did ) +\n'\" data-width=\"' +\n__e( width ) +\n'\"><a href=\"' +\n__e( post_url ) +\n'\">' +\n__e( post_url ) +\n'</a></div> ';\n } else { ;\n__p += ' <div class=\"tumblr-post\" data-href=\"' +\n__e( embed_host ) +\n'/embed/post/' +\n__e( embed_key ) +\n'/' +\n__e( post_id ) +\n'\" data-did=\"' +\n__e( embed_did ) +\n'\"><a href=\"' +\n__e( post_url ) +\n'\">' +\n__e( post_url ) +\n'</a></div> ';\n } ;\n__p += ' <script async src=\"' +\n__e( secure_assets_host ) +\n'/post.js\"><\/script>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},30800(e){"use strict";e.exports={"1785 GLC Baskerville":{display_name:"1785 Baskerville",family:"'1785 GLC Baskerville', serif",path:"1785glcbaskerville",_v:"1"},"Alternate Gothic":{display_name:"Alternate Gothic",family:"'Alternate Gothic', sans-serif",path:"alternategothic",_v:"3"},Arquitecta:{display_name:"Arquitecta",family:"'Arquitecta', sans-serif",path:"arquitecta",_v:"3"},Avalon:{display_name:"Avalon",family:"'Avalon', sans-serif",path:"avalon",_v:"1"},Baskerville:{display_name:"Baskerville",family:"Baskerville, 'Times New Roman', Times, serif"},"Bodoni Recut FS":{display_name:"Bodoni",family:"'Bodoni Recut FS', serif",path:"bodonirecutfs",_v:"3"},Bookmania:{display_name:"Bookmania",family:"'Bookmania', serif",path:"bookmania",_v:"1"},"Brutal Type":{display_name:"Brutal Type",family:"'Brutal Type', sans-serif",path:"brutaltype",_v:"1"},Calluna:{display_name:"Calluna",family:"'Calluna', serif",path:"calluna",_v:"3"},"Calluna Sans":{display_name:"Calluna Sans",family:"'Calluna Sans', sans-serif",path:"callunasans",_v:"3"},Capita:{display_name:"Capita",family:"'Capita', serif",path:"capita",_v:"1"},"Caslon FS":{display_name:"Caslon FS",family:"'Caslon FS', serif",path:"caslonfs",_v:"3"},"Clarendon Text Pro":{display_name:"Clarendon",family:"'Clarendon Text Pro', serif",path:"clarendontextpro",_v:"3"},"Clearface FS":{display_name:"Clearface",family:"'Clearface FS', serif",path:"clearface",_v:"4"},FangSong:{display_name:"Fang Song",family:"'FangSong', 'STFangsong', sans-serif"},Favorit:{display_name:"Favorit",family:"'Favorit', sans-serif",path:"favorit",_v:"1"},"Garamond Classic FS":{display_name:"Garamond",family:"'Garamond Classic FS', serif",path:"garamondclassicfs",_v:"3"},Georgia:{display_name:"Georgia",family:"Georgia, Palatino, 'Palatino Linotype', Times, 'Times New Roman', serif"},Gibson:{display_name:"Gibson",family:"'Gibson', sans-serif",path:"gibson",_v:"3"},"Grumpy Black 48":{display_name:"Grumpy",family:"'Grumpy Black 48', serif",path:"grumpyblack48",_v:"3"},"Helvetica Neue":{display_name:"Helvetica",family:"'Helvetica Neue', Arial, Helvetica, sans-serif"},Kaiti:{display_name:"Kaiti",family:"'Kaiti TC', 'KaiTi', sans-serif"},"Lorimer No 2":{display_name:"Lorimer No 2",family:"'Lorimer No 2', sans-serif",path:"lorimerno2",_v:"3"},"Lucida Sans":{display_name:"Lucida Sans",family:"'Lucida Sans', 'Lucida Grande', 'Lucida Sans Unicode', sans-serif"},"News Gothic FS":{display_name:"News Gothic",family:"'News Gothic FS', sans-serif",path:"newsgothicfs",_v:"3"},"Pratt Pro":{display_name:"Pratt Pro",family:"'Pratt Pro', serif",path:"prattpro",_v:"1"},Quadrat:{display_name:"Quadrat",family:"'Quadrat', serif",path:"quadrat",_v:"1"},SimHei:{display_name:"Sim Hei",family:"'SimHei', 'STHeiti', sans-serif"},"Sofia Pro":{display_name:"Sofia Pro",family:"'Sofia Pro', sans-serif",path:"sofiapro",_v:"2"},Spade:{display_name:"Spade",family:"'Spade', serif",path:"spade",_v:"1"},"Square Serif":{display_name:"Square Serif",family:"'Square Serif', serif",path:"squareserif",_v:"4"},Streetscript:{display_name:"Streetscript",family:"'Streetscript', sans-serif",path:"streetscript",_v:"1"},"Typewriter FS":{display_name:"Typewriter",family:"'Typewriter FS', serif",path:"typewriterfs",_v:"1"}
1,Verdana:{display_name:"Verdana",family:"Verdana, Geneva, Tahoma, sans-serif"},Ziclets:{display_name:"Ziclets",family:"'Ziclets', serif",path:"ziclets",_v:"1"}}},31048(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, \'\') }\nwith (obj) {\n__p += \'<div class="popover popover_menu popover_gradient popover_share_social"><div class="popover_inner"><ul class="share_options active" data-tumblelog-name="\' +\n__e( tumblelog_name ) +\n\'" data-post-id="\' +\n__e( post_id ) +\n\'" data-root-id="\' +\n__e( root_id ) +\n\'" data-post-url="\' +\n__e( post_url ) +\n\'" data-post-tiny-url="\' +\n__e( post_tiny_url ) +\n\'" data-embed-key="\' +\n__e( embed_key ) +\n\'" data-embed-did="\' +\n__e( embed_did ) +\n\'"> \';\n if(!is_private) { ;\n__p += \' \';\n if(show_permalink) { ;\n__p += \' <li class="share_permalink popover_menu_item"><a class="popover_menu_item_anchor" data-share-type="permalink" href="\' +\n__e( post_url ) +\n\'" target="_blank" class="external" title="\' +\n__e( permalink_label ) +\n\'" rel="noopener"> \' +\n__e( permalink_label ) +\n\' <i class="icon icon_arrow_carrot_right"></i></a></li> \';\n } ;\n__p += \' \';\n if(show_embed) { ;\n__p += \' <li class="embed_post popover_menu_item"><a class="popover_menu_item_anchor" data-share-type="embed" href="#">\' +\n__e( __(\'Embed\') ) +\n\'</a></li> \';\n } ;\n__p += \' \';\n if(show_email) { ;\n__p += \' <li class="share_email popover_menu_item"><a class="popover_menu_item_anchor" data-share-type="email" href="#">\' +\n__e( __(\'Email\') ) +\n\'</a></li> \';\n } ;\n__p += \' \';\n if(show_twitter) { ;\n__p += \' <li class="share_twitter popover_menu_item" data-twitter-username="\' +\n__e( twitter_username ) +\n\'"><a class="popover_menu_item_anchor" data-share-type="twitter" href="#">\' +\n__e( __(\'Twitter\') ) +\n\'</a></li> \';\n } ;\n__p += \' \';\n if(show_facebook) { ;\n__p += \' <li class="share_facebook popover_menu_item" data-has-facebook=""><a class="popover_menu_item_anchor" data-share-type="facebook" href="#">\' +\n__e( __(\'Facebook\') ) +\n\'</a></li> \';\n } ;\n__p += \' \';\n if(show_pinterest) { ;\n__p += \' <li class="share_pinterest popover_menu_item"><a class="popover_menu_item_anchor" data-share-type="pinterest" href="#">\' +\n__e( __(\'Pinterest\') ) +\n\'</a></li> \';\n } ;\n__p += \' \';\n if(show_reddit) { ;\n__p += \' <li class="share_reddit popover_menu_item"><a class="popover_menu_item_anchor" data-share-type="reddit" href="#">\' +\n__e( __(\'Reddit\') ) +\n\'</a></li> \';\n } ;\n__p += \' \';\n if(show_flagging) { ;\n__p += \' <li class="flag_post popover_menu_item"><a class="popover_menu_item_anchor" href="#">\' +\n__e( __(\'Report this post\') ) +\n\'</a></li> \';\n } ;\n__p += \' \';\n if (show_reporting_links) { ;\n__p += \' <li class="popover_menu_item"><a class="popover_menu_item_anchor" target="_blank" href="\' +\n__e( abuse_url ) +\n\'">\' +\n__e( __(\'Report Abuse\') ) +\n\'</a></li> \';\n } ;\n__p += \' \';\n } ;\n__p += \' </ul> \';\n if(!is_private) { ;\n__p += \' <form method="post" class="share_form email_form" id="share_email_\' +\n__e( post_id ) +\n\'" novalidate><div class="form_wrapper"><div class="share_label" data-embed-label="\' +\n__e( __(\'Embed\') ) +\n\'"></div><span class="cancel service icon_arrow_thin_left"></span><div class="input_group"><ul><li><input type="email" class="email_address" name="email_address" maxlength="100" placeholder="\' +\n__e( __(\'Email\') ) +\n\'" title="\' +\n__e( __(\'Email\') ) +\n\'"> <input type="hidden" name="post_id" value="\' +\n__e( post_id ) +\n\'"> <input type="hidden" name="tumblelog_name" value="\' +\n__e( tumblelog_name ) +\n\'"> <span class="cancel icon_close"></span></li><li><textarea name="message" class="share_message" maxlength="255" placeholder="\' +\n__e( __(\'Message (Optional)\') ) +\n\'" title="\' +\n__e( __(\'Message (Optional)\') ) +\n\'"></textarea><div class="character_count">140</div></li></ul></div> \';\n if(show_embed) { ;\n__p += \' <div class="embed_code_wrapper"><textarea name="embed_code" class="embed_code_text" spellcheck="false" readonly="readonly">\' +\n__e( embed_code ) +\n\'</textarea></div> \';\n } ;\n__p += \' \';\n if(has_user) { ;\n__p += \' <div class="reply_to" title="\' +\n__e( __(\'Let them reply to\') ) +\n\'"><div class="menu_item_option"><label class="binary-switch"><input type="checkbox" id="allow_reply_to_\' +\n__e( post_id ) +\n\'" class="reply_to_input" name="allow_reply_to"> <span class="binary-switch-track"></span> <span class="binary-switch-button"></span></label></div><label class="menu_item_label" for="allow_reply_to_\' +\n__e( post_id ) +\n\'"> \' +\n((__t = ( __(\'Let them reply to <span>\') )) == null ? \'\' : __t) +\n\' </label></div> \';\n } ;\n__p += \' <div class="error_status"></div><button type="submit" class="tx-button blue email_submit" data-label-sending="\' +\n__e( __(\'Sending...\') ) +\n\'" data-label="\' +\n__e( __(\'Send\') ) +\n\'" disabled="disabled">\' +\n__e( __(\'Send\') ) +\n\'</button></div></form><div class="status" data-sent="\' +\n__e( __(\'Sent!\') ) +\n\'" data-error="\' +\n__e( __(\'Error!\') ) +\n\'"><span class="status_message">\' +\n__e( __(\'Sent!\') ) +\n\'</span></div> \';\n } ;\n__p += \' </div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},31078(e,t,i){"use strict";var n=i(91685),s=i(55679),o=n.getComponent("SeekBar"),r=n.extend(o,{constructor:function(){o.prototype.constructor.apply(this,arguments),this.handle=document.createElement("div"),this.handle.className="vjs-seek-handle vjs-slider-handle",this.handle.setAttribute("aria-live","off"),this.el_.appendChild(this.handle),this.boundDetectDuration=s.bind(this.detectDuration,this),this.player().on("loadedmetadata",this.boundDetectDuration)},handleMouseMove:function(e){o.prototype.handleMouseMove.apply(this,arguments),this.update()},detectDuration:function(){s.isFinite(this.player().duration())||null==this.el_||this.dispose()},update:function(){if(this.el_){var e=this.getPercent();isNaN(e)&&(e=0);var t=(100*e).toFixed(2)+"%";this.handle.style.left=t,this.bar.el().style.width=t}},dispose:function(){this.player().off("loadedmetadata",this.boundDetectDuration),o.prototype.dispose.apply(this,arguments)}});e.exports=r},31384(e,t,i){"use strict";var n=i(55679),s=function(e,t){return null==t?t=5:n.isNumber(t)||(t=0),n.transform(e,function(e,i,o){t&&n.isObject(i)&&(i=s(i,t-1)),e[n.camelCase(o)]=i})};e.exports=s},31663(e,t,i){"use strict";var n=i(97583).extend({logKey:"reactivation",logOptions:{init_event:!1},events:{"reactivation:*":"handleEvent"},logEnv:{location:document.location.pathname},handleEvent:function(e,t){this.log(e,t)}});e.exports=n},31710(e,t,i){var n=i(55679),s=i(74692),o=i(81203),r=function(){var e=function(e){e=e||{},this.debounceRate=e.debounceRate||100,this.element=e.element||document,this.humanKeys=e.humanKeys||new o,this.subscribers={},this.listening=!1};function t(){s(this.element).on("keydown.keycombos",r.bind(this)),this.listening=!0}function i(){s(this.element).off("keydown.keycombos"),this.listening=!1}function r(e){var t=this.humanKeys.translate(e);
1t&&l.call(this,t)&&(a.call(this,t,e),e.preventDefault(),e.stopImmediatePropagation())}function a(e,t){n.each(u.call(this,e),function(i){n.has(i,"callback")&&n.has(i,"context")&&i.callback.call(i.context,t,e)})}function l(e){return u.call(this,e).length>0}function c(e,t){var i=u.call(this,e);return n.filter(i,{callback:t}).length>0}function u(e){return n.has(this.subscribers,e)?this.subscribers[e]:[]}function h(e,i,s){if(!c.call(this,e,i))return n.has(this.subscribers,e)||(this.subscribers[e]=[]),this.subscribers[e].push({callback:i,context:s}),this.listening||t.call(this),this}function d(){this.subscribers={},i.call(this)}function p(e,t){return e?n.has(this.subscribers,e)?(t&&(this.subscribers[e]=n.reject(this.subscribers[e],{callback:t})),t&&0!==this.subscribers[e].length||delete this.subscribers[e],0===n.values(this.subscribers).length&&i.call(this),this):this:(d.call(this),this)}return e.prototype.on=function(e,t,i){n.each((e||"").split(" "),function(e){h.call(this,this.humanKeys.normalize(e),t,i)},this)},e.prototype.off=function(e,t){e?n.each(e.split(" "),function(e){p.call(this,this.humanKeys.normalize(e),t)},this):p.call(this,null,t)},e}();e.exports=r},31787(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}var s=i(55679),o=i(80160),r=i(41257),a=i(2681),l=i(41699),c=i(30106),u=i(2606),h=i(50506),d=i(44904),p=i(35232),g=i(76419),f=i(84342),m=i(38723),_=i(95921),v=i(95870),b=i(9553),y=i(28017),w=o.extend({mixins:[a],typeDelegateMap:{text:l,photo:c,quote:u,link:h,chat:d,audio:p,video:g,note:f},_VALID_STATES:{published:"0",draft:"1",queued:"2",scheduled:"on.2",private:"private",unapproved:"0 3",transcoding:"4"},_FORMAT_CODE_TO_EDITOR_TYPE:{0:"rich",1:"html",2:"markdown"},_STATE_CODE_TO_TEXT:{published:"published",0:"published","0 3":"published",1:"draft",2:"queued",3:"unapproved",4:"transcoding","on.2":"scheduled",private:"private"},defaults:{carouselDisplay:!1,postDate:String(),customUrl:String(),sourceUrl:String(),state:"published",editorType:"rich",tags:[],publish_on:String(),tumblelog:String(),uploading:!1,mode:"new",contentStats:{},loading:!1,hasLoadingInlineImages:!1,members_only:!1,owner_flagged_nsfw:!1,canBeLiked:!0,canBeReblogged:!0,enableCTA:!1,tspSkipLightbox:!0,ctaTextCode:"0",enableRedirectUrls:!1,redirectUrlPrimary:String(),redirectUrlIOS:String(),redirectUrlAndroid:String()},shortUrlLength:29,typeAttributes:{},editorField:!1,resetPreserveFields:[],resetAttributes:[],allowAnswerFields:[],_syntheticAttributes:{pseudoState:function(){var e=this.get("state"),t=this.get("publish_on");return"published"===e&&1===parseInt(this.get("is_private"),10)&&(e="private"),"queued"===e?s.isEmpty(t)?"queued":"scheduled":e},formattedSourceUrl:function(){var e,t=this.get("sourceUrl");return s.isEmpty(t)?"":(e=v.addProtocolIfMissing(t,"https:"),b.isUrl(e)?e:t)},formattedRedirectUrlPrimary:function(){var e,t=this.get("redirectUrlPrimary");return s.isEmpty(t)?"":(e=v.addProtocolIfMissing(t,"https:"),b.isUrl(e)?e:t)}},initialize:function(e,t){s.has(e,"tags")||this.set("tags",[]),this._assignPostTypeFunctionality()},_assignPostTypeFunctionality:function(){var e=this.get("type"),t=s.bind(function(e){return e in this.typeDelegateMap&&this.typeDelegateMap[e].prototype},this);e?(this.delegateObject(t(e)),this.afterDelegate()):this.listenToOnce(this,"change:type",function(e,i){this.delegateObject(t(i)),this.afterDelegate()})},afterDelegate:function(){s.defaults(this.attributes,this.typeAttributes)},_normalizeType:function(e,t){var i={regular:"text",conversation:"chat"};return!1===t&&(i=s.invert(i)),e in i?i[e]:e},get:function(e){return(this._syntheticAttributes[e]||o.prototype.get).apply(this,arguments)},getHtmlStripped:function(e,t,i){return void 0!==t||(t=!0),void 0!==i||(i=" "),s.trim(_.stripHtml(this.get(e)||"",t,i))},fetch:function(e){var t={data:e};return o.prototype.fetch.call(this,t)},parse:function(e,t){if(!1===t.parse)return this.attributes;var i=e.post,n=t.data,o={},r=i.id?"edit":"reblog";o.type=this._normalizeType(i.type,!0),o.can_reblog_as=s.map(i.can_reblog_as,s.bind(function(e){return this._normalizeType(e,!0)}
1,this)),this.set("type",o.type),s.forEach(this.genericFieldMap,function(e,t){o[e]=i[t]});return s.extend(o,s.omit(i,["one","two","three","state","publish_on","tags","type","can_reblog_as"]),{createdPost:!!e.created_post,postTumblelog:e.post_tumblelog||{},postContextPage:e.post_context_page}),"edit"===r?(o["post-id"]=i.id,o.tags=i.tags?i.tags.split(","):[],o.tumblelog=o.postTumblelog.name_or_id||!1):"reblog"===r&&s.extend(o,s.pick(n,["reblog_id","reblog_key"])),"state"in i&&(o.state=this._extractState(i)),i.from_app&&1===s.parseInt(i.format)||(o.editorType=this._FORMAT_CODE_TO_EDITOR_TYPE[s.parseInt(i.format||0)]),o.editorType||(o.editorType=this.get("editorType")||this._FORMAT_CODE_TO_EDITOR_TYPE[0]),s.has(i,"custom_tweet")&&(o.customTweet=i.custom_tweet),s.extend(o,{sourceUrl:o.source_url||"",carouselDisplay:o.carousel_display||!1,htmlEdited:"rich"!==o.format&&!(this.editorField&&!i[this.editorField]),postDate:o.date||"",customUrl:o.slug||"",canBeLiked:o.can_be_liked,canBeReblogged:o.can_be_reblogged},s.mapValues(s.pick(o,["html_mode","members_only","carousel_display","owner_flagged_nsfw"]),m)),s.has(i,"ads_cta_text_code")&&null!==i.ads_cta_text_code&&(o.enableCTA=!0,o.ctaTextCode=i.ads_cta_text_code||"0"),s.has(i,"redirect_url_primary")&&null!==i.redirect_url_primary&&(o.enableRedirectUrls=!0,o.redirectUrlPrimary=i.redirect_url_primary||"",o.redirectUrlIOS=i.redirect_url_ios||"",o.redirectUrlAndroid=i.redirect_url_android||""),"edit"!==r||"queued"!==o.state||s.isEmpty(i.publish_on)||(o.state="scheduled",o.publish_on=i.publish_on),this.parseForType(o,i)},parseForType:function(e,t){return e},sync:function(e,t,i){return s.defaults(i||(i={}),{emulateHTTP:!0,forServer:!0,url:{create:"/svc/post/update",read:"/svc/post/fetch",update:"/svc/post/update"}[e]}),i.parse="read"===e,o.prototype.sync.call(this,e,t,i)},toJSON:function(e){return(e=s.defaults(e||{},{forServer:!1})).forServer?this.serializeForServer(e):o.prototype.toJSON.call(this,e)},serializeForServer:function(){var e=this,t=e.attributes,i={channel_id:t.tumblelog,post_id:t["post-id"],"post[date]":t.postDate,"post[one]":this.getAttributeFromGeneric("one"),"post[publish_on]":t.publish_on,"post[slug]":t.customUrl,"post[tags]":t.tags.join(),"post[two]":this.getAttributeFromGeneric("two"),"post[three]":this.getAttributeFromGeneric("three"),thumbnail:this.getAttributeFromGeneric("thumbnail"),editor_type:t.editorType,send_to_twitter:t.send_to_twitter,custom_tweet:t.customTweet,loggingData:t.loggingData,carousel_display:t.carouselDisplay,members_only:t.members_only,owner_flagged_nsfw:t.owner_flagged_nsfw,content_stats:t.contentStats,carousel_index:t.carousel_index,can_be_liked:t.canBeLiked,can_be_reblogged:t.canBeReblogged,enable_cta:t.enableCTA,tsp_skip_lightbox:t.tspSkipLightbox,cta_text_code:t.ctaTextCode,enable_redirect_urls:t.enableRedirectUrls,redirect_url_primary:e.get("formattedRedirectUrlPrimary"),redirect_url_ios:t.redirectUrlIOS,redirect_url_android:t.redirectUrlAndroid};"edit"===t.mode&&(i.edit_post_id=t["post-id"]),i["post[source_url]"]=e.get("formattedSourceUrl"),i["post[state]"]=e._VALID_STATES[t.state],i["post[type]"]=this._normalizeType(t.type,!1);var n={reblog:t.is_reblog,reblog_key:t.reblog_key,reblog_post_id:t.reblog_id,pt:t.pt||window.name,remove_reblog_tree:t.remove_reblog_tree,reblog_source:t.reblogSource};s.extend(i,s.pick(n,function(e){return!s.isUndefined(e)})),this.getAttributeFromGeneric("thumbnail")&&(i.thumbnail_pre_upload="1");var o=this.getContextPage();return s.extend(i,{context_id:t.tumblelog,context_page:o,context_bundle:y.get("Context/name"),"is_rich_text[one]":"0","is_rich_text[two]":"0","is_rich_text[three]":"0"}),this.editorField&&(i["is_rich_text["+this.editorField+"]"]="1"),t.reblogActionContext&&(i.reblog_source=t.reblogActionContext),t.shareData&&s.isObject(t.shareData)&&(t.shareData.canonicalUrl=i["post[source_url]"],i.share_data=t.shareData),i},validate:function(e,t){var i="errors"in t?t.errors:[];if(e.state&&(s.has(this._VALID_STATES,e.state)||i.push('Invalid "state" value')),e.hasLoadingInlineImages&&i.push("There are still pending images."),s.each(this.defaults,function(t,s){n(t)!==n(e[s])&&i.push('Invalid "'+s+'" type. Expected '+n(t)+", got "+n(e[s])+".")}),i.length)return i},_extractState:function(e){var t=this._STATE_CODE_TO_TEXT[e.state];return 1===parseInt(e.is_private,10)&&(t="private"),t},findBlogChannelByName:function(e){if(this.attributes.tumblelog&&this.attributes.tumblelog.collection&&"findWhere"in this.attributes.tumblelog.collection)return this.attributes.tumblelog.collection.findWhere({name_or_id:e})},getPreservedData:function(){return this.resetPreserveFields.some(s.bind(function(e){return this.get(e)&&this.get(e).length>0},this))}
1,softReset:function(){s.forEach(this.resetAttributes,function(e){s.has(this.typeAttributes,e)?this.set(e,this.typeAttributes[e]):s.has(this.defaults,e)?this.set(e,this.defaults[e]):this.unset(e)},this)},getLookupData:function(){if("reblog"===this.get("mode"))return{reblog_id:this.get("reblog_id"),reblog_key:this.get("reblog_key"),post_type:this.get("type")}},getContextPage:function(){var e=this.attributes,t="dashboard";return e.contextData&&(e.contextData.contextPage?t=e.contextData.contextPage:"baseRoute"in e.contextData&&(t=e.contextData.baseRoute.split("/").pop())),t},getAttributeFromGeneric:function(e){return this.get(this.genericFieldMap[e])},getTweetText:function(){var e=this.get("customTweet");return s.isString(e)||((e=this.generateTweetText(280-this.shortUrlLength-1))?e+=" [URL]":e="[URL]"),e},getTweetTextLength:function(e){s.isString(e)||(e=this.getTweetText());var t=(e=s.trim(e).replace(/([^\s])\[URL\]/gi,"$1 [URL]").replace(/\[URL\]([^\s])/gi,"[URL] $1")).length;return t+=(this.shortUrlLength-5)*(e.match(/\[URL\]/gi)||"").length},generateTweetText:function(e){return""},canEditMedia:function(){return!this.get("is_reblog")},isReblog:function(){return!!this.get("is_reblog")},allowsTypeSwitch:function(e){return!1},canPreview:function(){return this.isValid()},deepHasChanged:function(e){var t=this.toJSON(),i=this.get("mode"),n=s.keys(e),o=s.keys(t);if(s.isEqual(e,t))return!1;if("new"!==i)return!0;var r=s.difference(o,n);return s.reduce(r,function(e,i){var n=t[i];return e+(s.isUndefined(n)||s.isNull(n)?0:n.length)},0)>0||(e=s.omit(e,r),t=s.omit(t,r),!s.isEqual(e,t))}});r({"Tumblr.Prima.PostForms.Post":w}),e.exports=w},31859(e){e.exports=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)})}},31993(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(36452),r=i(74988),a=i(98237),l=o.extend({tagName:"form",mixins:[a],className:"external-network-form-subview",defaults:n.defaults({isFormValid:!1,isShowConfetti:!0},o.prototype.defaults),events:{"click [data-js-success-container]":"_onSuccessContainerClick",submit:"_onFormSubmit"},initialize:function(e){n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),o.prototype.initialize.apply(this,arguments)},afterRender:function(){var e=this.getSubmitButtonElement();this.listenTo(this,"change:isFormValid",this._onChangeIsFormValid),this.listenTo(this,"change:isSharing",this._onChangeIsSharing),n.isEmpty(e)||(this.submitTextDefault=e.text(),this.submitTextSending=e.attr("data-text-sending")||s("Sending...")),this.validateForm(),this._setSubmitButtonState(),this._toggleElement(this.getShareFailElement(),!1),this._toggleElement(this.getShareSuccessElement(),!1)},getSubmitButtonElement:function(){return this.js$("submit-button")},getShareSuccessElement:function(){return this.js$("success-container")},getShareFailElement:function(){return this.js$("fail-container")},onShareSuccess:function(e){var t,i=this.getShareSuccessElement();this._toggleElement(i,!0),this._toggleElement(this.getShareFailElement(),!1),i&&this.get("isShowConfetti")&&(t=this._createConfettiView(),i.append(t.render().$el))},onShareFail:function(e){this._toggleElement(this.getShareFailElement(),!0),this._toggleElement(this.getShareSuccessElement(),!1)},isFormFieldsValid:function(){return!0},validateForm:function(){this.set("isFormValid",this.isFormFieldsValid())},setFormIsValid:function(e){this.set("isFormValid",e)},isFormValid:function(){return this.get("isFormValid")},onFormSubmit:function(e){},_createConfettiView:function(){return new r({className:"external-network-form-subview-confetti",autoParty:!0,amount:30,speed:.2})},_setSubmitButtonState:function(){var e=this.getSubmitButtonElement(),t=this.get("isFormValid"),i=this.get("isSharing"),n=!t||i;e.prop("disabled",n),e.text(i?this.submitTextSending:this.submitTextDefault)},_onChangeIsSharing:function(e,t){this._setSubmitButtonState()},_onChangeIsFormValid:function(e,t){this._setSubmitButtonState()},_onSuccessContainerClick:function(e){this.close()},_toggleElement:function(e,t){n.isEmpty(e)||e.toggleClass("visible",t)},_onFormSubmit:function(e){e.preventDefault(),this.onFormSubmit(e)}});e.exports=l},32284(e,t,i){"use strict";i.d(t,{A:()=>p});
1var n=i(50283),s=i.n(n),o=i(55679),r=i.n(o),a=i(55938),l=i.n(a),c=i(74692),u=i.n(c),h=i(27496),d=i.n(h);const p=s().extend({className:"native-audio-container",template:l(),events:{"click .play-pause":"playPause","mousedown .audio-player":"onMouseDown","mousemove .audio-player":"onMouseMove","mouseup .audio-player":"onMouseUp","mouseleave .audio-player":"onMouseLeave"},initialize:function(e){e=e||{},this.streamUrl=e.streamUrl+"?plead=please-dont-download-this-or-our-lawyers-wont-let-us-host-audio",this.playing=!1,this.track=e.track,this.artist=e.artist,this.albumArt=e.albumArt,this.preview=e.preview,this.noId3=e.noId3,this.model=e.model,this.dragging=!1,this.mousedown=!1},render:function(){this.$el.html(this.template({post:this.model,streamUrl:this.streamUrl,track:this.track,artist:this.artist,albumArt:this.albumArt,noId3:this.noId3}));var e=this.$("audio"),t=this.$(".audio-source");return this.player=e[0],this.icon=this.$(".icon"),this.progress=this.$(".progress"),this.$player=this.$(".audio-player"),this.artist||this.track||this.$(".track-no-id3").css("display","block"),e.on("playing",r().bind(this.onPlay,this)),e.on("pause",r().bind(this.onPause,this)),e.on("timeupdate",r().bind(this.onTimeUpdate,this)),e.on("error",r().bind(this.onError,this)),t.on("error",r().bind(this.onError,this)),this.listenTo(d(),"NativeAudio:play",this.stopOtherAudio),this},onPlay:function(){this.model&&d().trigger("NativeAudio:play",this.model.get("id")),this.icon.removeClass("icon_play").addClass("icon_pause"),this.playing=!0},stopOtherAudio:function(e){this.model&&this.model.get("id")!==e&&(this.pause(),this.setPlayerTime(0))},onMouseDown:function(e){u()(e.target).hasClass("play-pause")||(this.mousedown=!0),this.dragging=!1},onError:function(){this.icon.removeClass("icon_pause icon_play").addClass("icon_close"),this.$el.addClass("error"),this.undelegateEvents()},onMouseMove:function(e){if(this.mousedown){this.dragging=!0,this.playing&&this.pause();var t,i=u()(e.target);if(i.hasClass("audio-player"))t=e.offsetX/this.$player.outerWidth()*this.player.duration;else{var n=i.closest(".audio-player").offset();t=(e.pageX-n.left)/this.$player.outerWidth()*this.player.duration}this.setPlayerTime(t)}},onMouseUp:function(e){var t=u()(e.target);if(this.playing){if(this.mousedown&&!this.dragging&&t.hasClass("audio-player")){var i=e.offsetX/this.$player.outerWidth()*this.player.duration;this.setPlayerTime(i)}}else this.play();this.mousedown=!1,this.dragging=!1},onMouseLeave:function(e){this.mousedown=!1,this.dragging=!1},onPause:function(){this.icon.removeClass("icon_pause").addClass("icon_play"),this.playing=!1},afterRender:function(){this.$el.toggleClass("audio-player--preview-player",this.preview)},playPause:function(e){e.stopPropagation(),this.playing?this.pause():this.play()},play:function(){this.player.play()},pause:function(){this.player.pause()},setPlayerTime:function(e){isNaN(e)||(this.player.currentTime=e)},teardown:function(){u()(this.player).off()},onTimeUpdate:function(){this.player.currentTime===this.player.duration?this.progress.css("width",0):this.progress.css("width",this.player.currentTime/this.player.duration*100+"%")}})},32435(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<a class=\"avatar\" href=\"' +\n__e( url ) +\n'\" target=\"_blank\" data-js-tumblelog-name=\"' +\n__e( name ) +\n'\"> ';\n if (canPixelateAvatar) { ;\n__p += ' <canvas class=\"pixelated-avatar needs-drawing hide\" data-image-url=\"' +\n__e( avatarUrl ) +\n'\" alt=\"' +\n__e( name ) +\n'\"></canvas> ';\n } else { ;\n__p += ' <img src=\"' +\n__e( avatarUrl ) +\n'\"> ';\n } ;\n__p += ' </a><div class=\"message-bubble\" data-js-message-bubble><div class=\"message-bubble-header\"><a href=\"' +\n__e( url ) +\n'\" class=\"name\" target=\"_blank\" data-js-tumblelog-name=\"' +\n__e( name ) +\n'\">' +\n__e( name ) +\n'</a><button class=\"retry-button\" data-js-retry-button>
1' +\n__e( __('Retry') ) +\n'</button></div><div class=\"message\">' +\n((__t = ( message )) == null ? '' : __t) +\n'</div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},33086(e,t,i){"use strict";var n,s=i(74692),o=i(55679),r=i(81515),a=i(71742),l=i(27496),c=i(77594),u=i(49779),h=i(42062),d=a.extend({name:"drawer",selector:"body",mixins:[c],defaults:{suspended:!1,needsCloseConfirmation:!1},keycommands:{"keydown:escape":"initiateClose"},initialize:function(){this.$glass=null,this.$container=s(this.container),this.bindEvents()},bindEvents:function(){this.listenTo(l,"post:form:show",this.suspend),this.listenTo(l,"post:form:hide",this.resume),this.listenTo(l,"drawer:suspend",this.suspend),this.listenTo(l,"drawer:resume",this.resume),this.listenTo(l,"drawer:enableCloseConfirmation",this.enableCloseConfirmation),this.listenTo(l,"drawer:disableCloseConfirmation",this.disableCloseConfirmation),this.listenTo(l,"drawer:hideGlass",this.hideGlass),this.listenTo(l,"indashblog:post:photo_lightbox",this.disableKeys),this.listenTo(l,"tumblr_lightbox:form:hide",this.enableKeys),this.$container.on("click.drawerOpen keyup","[data-drawer-open]",o.bind(this.onClickOpen,this))},suspend:function(){this.set("suspended",!0)},resume:function(){this.set("suspended",!1)},enableCloseConfirmation:function(){this.set("needsCloseConfirmation",!0)},disableCloseConfirmation:function(){this.set("needsCloseConfirmation",!1)},canOpen:function(){return!this.get("suspended")&&!this.view},isSuspended:function(){return this.get("suspended")},isOpen:function(){return!!this.view},toggle:function(e,t){this.canOpen?this.open(e,t):this.close()},open:function(e,t,i,n){this.containerDrawerName=n,this.view=new h({subviews:{"drawer-content":{constructor:e,options:t||{}}}}),this.view.$el.addClass(i),this._toggleContainerDrawerClass(n,!0),this.showGlass(),l.trigger("keycommands:suspend"),this.append(),this.trigger("open"),l.trigger("drawer:open")},replace:function(e,t,i,n){this.view?(this._toggleContainerDrawerClass(this.containerDrawerName,!1),this._toggleContainerDrawerClass(n,!0),this.view.animateRemove(),this.view=null,this.containerDrawerName=n,o.delay(o.bind(function(){this.view=new h({subviews:{"drawer-content":{constructor:e,options:t||{}}}}),this.view.$el.addClass(i),this.append()},this),400)):this.open(e,t,i)},onClickOpen:function(e){if("keyup"!==o.get(e,"type")||13===o.get(e,"keyCode")){e.preventDefault();var t=s(e.currentTarget).attr("data-drawer-open");this.trigger("open:"+t),l.trigger("drawer:open:"+t)}},initiateClose:function(){this.view&&!this.get("suspended")&&(!0===this.get("needsCloseConfirmation")?u.confirm(r("Close without sending?"),o.bind(this.close,this),this.noop,r("OK"),r("Cancel")):this.close())},close:function(){this.view&&(this._toggleContainerDrawerClass(this.containerDrawerName,!1),this.view.animateRemove(),this.view=null,this.containerDrawerName=null,this.hideGlass(),l.trigger("keycommands:resume"),this.trigger("close"),l.trigger("drawer:close"))},remove:function(){return this.close(),this},showGlass:function(){this.$glass=s("<div>",{class:"ui_peepr_glass"}).appendTo(this.$container);var e=o.bind(function(){this.$container.addClass("peepr")},this);this.animationDelay=o.delay(e,50),this.$glass.on("click",o.bind(this.initiateClose,this))},hideGlass:function(){var e=this.$glass;this.$glass=null,this.$container.removeClass("peepr"),this.animationDelay&&clearTimeout(this.animationDelay),o.delay(function(){e.remove()},150)},_getContainerClassNameForDrawerName:function(e){return o.isEmpty(e)?null:"peepr--"+e},_toggleContainerDrawerClass:function(e,t){var i=this._getContainerClassNameForDrawerName(e);o.isEmpty(this.$container)||o.isEmpty(i)||this.$container.toggleClass(i,t)}});e.exports=function(){return n||(n=new d),n}},33253(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(44579),r=i(20851),a=s.extend({className:"inbox-sender",template:r,subviews:{blogSelector:{constructor:o,options:function(e){return{className:"inbox-sender-blog-selector",collection:e.channels,popoverOptions:{popoverContainer:e.popoverContainer},currentTumblelog:e.channels.findWhere({uuid:e.currentBlogModel.getId()}),badgeCountField:"unread_messages_count_sum"}}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","user","channels","currentBlogModel","popoverContainer"))},afterRenderSubviews:function(){this.listenTo(this.blogSelector,"change:currentTumblelog",this._onBlogSelectorChange)},_onBlogSelectorChange:function(e,t){this.currentBlogModel.setChannel(t)}});e.exports=a},33255(e){"use strict";function t(e){var t=document.implementation.createHTMLDocument("");return t.body.appendChild(e.cloneNode(!0)),t.body}e.exports={nodeFromString:function(e){var t=document.implementation.createHTMLDocument("");return t.body.innerHTML=e,t.body},wrapNode:t,outerHTML:function(e){return t(e).innerHTML},stripTags:function(e){var t=document.implementation.createHTMLDocument("");return t.body.innerHTML=e,(t.body.textContent||t.body.innerText||"").trim()}}},33300(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(13024),r=i(59908),a=s.extend({className:"loader-container",template:r,defaults:{type:"",classModifiers:"",loading:!1},initialize:function(e){this.options=n.extend({},this.defaults,e),this.$container=e.$container,"bar"===this.get("type")&&this.createBarLoader(),this.listenTo(this,"change:loading",this._onChangeLoading),this.attach()},createBarLoader:function(){this.subviews.loaderType=new o(this.options)},_onChangeLoading:function(e,t){this.subviews.loaderType.toggleLoading(t)}
1,attach:function(){this.render(),this.$el.attr("data-subview=loader"),this.$container.find("[data-subview=loader]").replaceWith(this.$el)}});e.exports=a},33309(e){e.exports={POSITION_CHANGE:"position_change",RESET:"reset",RESET_AUDIO:"reset_audio",RESET_CONTINUOUS:"reset_continuous"}},33389(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<input type=\"text\" class=\"blog-search-input\" placeholder=\"' +\n__e( __('Search %s', model.blogname) ) +\n'\">';\n\n}\nreturn __p\n}").apply(void 0,r(s))},33455(e,t,i){var n,s=i(28017);e.exports=(n||(n=s.get("Components/LogLady")),n)},33595(e,t,i){var n=i(55679),s=i(74692),o=i(12461),r=function(){var e=90,t=function(e,t){this.editor=e,this.modifierKeyCode=!1,this.isShift=!1,this.currState=null,this.undoStates=[],this.redoStates=[],this.afterRestore=t||function(){},this.isRestoring=!1;var s=this,o=n.debounce(function(){s.isTorndown||u.call(s)},500);this.defaultOnChange=e.onChange,e.onChange=function(e){if(s.isRestoring)s.isRestoring=!1;else{if("updateAsyncImage"===e)return;s.currState?o():u.call(s)}s.defaultOnChange.call(this)},i.call(this)};function i(){var t=this;s(this.editor.element).on("keydown.undoManager",function(i){if(i.keyCode===e&&function(e){return/Mac/.test(navigator.platform)?e.metaKey:e.ctrlKey}(i)&&!i.altKey)return i.shiftKey?a.call(t):r.call(t),i.preventDefault(),!1})}function r(){if(u.call(this),this.undoStates.length){var e=this.undoStates.pop();h.call(this,e),this.redoStates.push(this.currState),l.call(this)}}function a(){if(this.redoStates.length){var e=this.redoStates.pop();h.call(this,e),this.undoStates.push(this.currState),l.call(this)}}function l(){this.currState=c.call(this)}function c(){return{data:this.editor.getData(!0,!0),selection:o.saveSelection(this.editor.element)}}function u(){var e=c.call(this);this.currState?e.data!==this.currState.data&&(this.undoStates.push(this.currState),this.currState=e):this.currState=e}function h(e){(this.isRestoring=!0,this.editor.setData(e.data,!0),e.selection)?o.restoreSelection(e.selection):window.getSelection().removeAllRanges();this.afterRestore()}return t.prototype.undo=function(){r.call(this)},t.prototype.redo=function(){a.call(this)},t.prototype.teardown=function(){this.isTorndown=!0,this.editor.onChange=this.defaultOnChange,this.undoStates.length=0,this.redoStates.length=0,this.currState=null,s(this.editor.element).off(".undoManager")},t}();e.exports=r},33718(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<a class=\"avatar\" href=\"' +\n__e( url ) +\n'\" target=\"_blank\" data-js-tumblelog-name=\"' +\n__e( name ) +\n'\" data-js-theme-avatar-shape-class> ';\n if (canPixelateAvatar) { ;\n__p += ' <canvas class=\"avatar pixelated-avatar needs-drawing hide\" data-image-url=\"' +\n__e( avatarUrl ) +\n'\" alt=\"' +\n__e( name ) +\n'\"></canvas> ';\n } else { ;\n__p += ' <img src=\"' +\n__e( avatarUrl ) +\n'\"> ';\n } ;\n__p += ' <div data-subview=\"statusIndicator\"></div></a><div class=\"name\"><a href=\"' +\n__e( url ) +\n'\" target=\"_blank\" data-js-tumblelog-name=\"' +\n__e( name ) +\n'\">' +\n__e( name ) +\n'</a></div> ';\n if (!_.isEmpty(description)) { ;\n__p += ' <div class=\"description\" data-js-description><a href=\"' +\n__e( url ) +\n'\" target=\"_blank\" data-js-tumblelog-name=\"' +\n__e( name ) +\n'\"> ' +\n__e( description ) +\n' </a></div> ';\n } ;\n__p += ' ';\n if (!_.isEmpty(relationship)) { ;\n__p += ' <div class=\"relationship\">' +\n__e( relationship ) +\n'</div> ';\n } ;\n__p += ' ';\n if (!_.isEmpty(tagsMarkup)) { ;\n__p += ' <div class=\"tags\">' +\n((__t = ( tagsMarkup )) == null ? '' : __t) +\n'</div> ';\n } ;\n\n\n}\nreturn __p\n}").apply(void 0,r(s))},33905(e,t,i){"use strict";var n=i(81515),s=i(19698),o=i(17579),r=s.extend({defaults:{isPopup:!0,username:null,urlToken:"[URL]"},getName:function(){return"twitter"},getLabel:function(){return n("Twitter")},getType:function(){return this.get("isPopup")?s.TYPE_POPUP:s.TYPE_SUBVIEW},getPopupUrl:function(){var e=this.getPostTinyUrl()||this.getPostUrl();return""+encodeURIComponent(e)},getPopupOptions:function(){return"width=550,height=420"},getSubviewConstructor:function(){return o},getSubviewOptions:function(){return{username:this.get("username"),urlToken:this.get("urlToken")}}});e.exports=r},33924(e,t,i){"use strict";var n=i(55679),s=i(27496),o=i(44384),r=i(97030),a=i(8901),l=o.extend({events:{"click .note_count":"showNotes"},mixins:[r],initialize:function(e){this.bindEvents()},bindEvents:function(){this.listenTo(this.model,"change:liked",this.updateCount)}
1,render:function(){this.$notesLabel=this.$el.find(".note_link_current")},updateCount:function(e,t){var i,n=this.$notesLabel.text();t?(i=this.$notesLabel.data("more"),this.$notesLabel.data("less",n)):(i=this.$notesLabel.data("less"),this.$notesLabel.data("more",n)),this.$notesLabel.text(i),this.$notesLabel.attr("title",i)},showNotes:function(e){s.trigger("useraction:click:post:notes",{event:e}),this.model.get("pt")&&s.trigger("useraction:explore_click:notes",{model:this.model,loggingData:this.loggingData({userAction:"notes"})}),a(n.bind(function(e){return new e({pinnedTarget:this.$(".note_link_current"),postModel:this.model}).render()},this))}});e.exports=l},34197(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<span class=\"status-text\"><div data-subview=\"statusIndicator\"></div>' +\n__e( lastOnlineString ) +\n'</span>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},34783(e){e.exports={CONTEXT:{V_SKIP_AVAIL:"$(V_SKIP_AVAIL)",V_AUTOPLAYED:"$(V_AUTOPLAYED)",V_PLAYER_WIDTH:"$(V_PLAYER_WIDTH)",V_PLAYER_HEIGHT:"$(V_PLAYER_HEIGHT)",V_EXPANDED:"$(V_EXPANDED)",V_AUD_INFO:"$(V_AUD_INFO)",V_AUD_TIME_INVIEW_100:"$(V_AUD_TIME_INVIEW_100)",V_MUTED:"$(V_MUTED)",V_MOAT_IVT:"$(V_MOAT_IVT)",V_TIME_INVIEW_50:"$(V_TIME_INVIEW_50)",V_IS_INVIEW_100_HALFTIME:"$(V_IS_INVIEW_100_HALFTIME)",V_TIME_INVIEW_50_MAX_CONTINUOUS:"$(V_TIME_INVIEW_50_MAX_CONTINUOUS)",V_VIEW_INFO:"$(V_VIEW_INFO)"},RULE:{V_VIEW_TYPE:"$(V_VIEW_TYPE)",S_VIEW_TYPE:"$(S_VIEW_TYPE)"}}},35232(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(95921).truncateLongStrings;function r(){}r.prototype.genericFieldMap={two:"caption",three:"url"},r.prototype.editorField="two",r.prototype.allowsTypeSwitch=function(){return"new"===this.get("mode")},r.prototype.typeAttributes={service:!1,preuploadUrl:"",trackTitle:"",trackArtist:"",trackAlbum:"",preuploadAlbumArt:!1,albumArt:"",caption:"",confirmTos:!1},r.prototype.allowAnswerFields=["caption"],r.prototype.generateTweetText=function(e,t){var i=this.getHtmlStripped("caption");return i=i.replace(/[\r\n\s]*\[\[MORE\]\].*$/gi,""),o(i,t)},r.prototype.resetPreserveFields=["caption","tags"],r.prototype.resetAttributes=["service","url","preuploadUrl","trackTitle","trackArtist","trackAlbum","confirmTos","preuploadAlbumArt","albumArt","copyrightFallback"],r.prototype.parseForType=function(e,t,i){i.service&&"direct"!==i.service||(t.url=i.audio_url),delete t.audio_url,t.albumArt=i.audio_artwork,delete t.audio_artwork;var n=i.id3_tags||{};return delete t.id3_tags,t.trackTitle=n.Title||"",t.trackArtist=n.Artist||"",t.trackAlbum=n.Album||"",t},r.prototype.serializeForServer=function(e){var t=e.apply(this,n.rest(arguments)),i={"id3_tags[title]":this.get("trackTitle")||null,"id3_tags[artist]":this.get("trackArtist")||null,"id3_tags[album]":this.get("trackAlbum")||null,preuploaded_url:this.get("preuploadUrl"),confirm_tos:this.get("confirmTos"),artwork_pre_upload:this.get("preuploadAlbumArt"),album_art:this.get("albumArt"),remove_album_art:"edit"===this.get("mode")&&n.isEmpty(this.get("albumArt")),copyright_fallback:this.get("copyrightFallback")};return n.extend(t,n.pick(i,function(e){return!n.isUndefined(e)})),n.isEmpty(t.preuploaded_url)||(t["post[three]"]=null),t},r.prototype.validate=function(e,t,i){var o=[];return n.isEmpty(t.url)?o.push(s("Please choose an audio source before continuing.")):t.preuploadUrl?t.confirmTos||o.push(s("You must agree that you have permission to share this file.")):n.isEmpty(t.url)&&o.push(s("Please choose an audio source before continuing.")),e.call(this,t,{errors:o})},e.exports=r},35543(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<i class=\"icon_filter show-filter-popover nav_icon\"></i>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},35552(e,t,i){"use strict";var n=i(71742),s=i(27496),o=i(33086),r=i(21100),a=n.extend({name:"AbuseForm",initialize:function(){this.drawerManager=o(),this.bindEvents()},bindEvents:function(){this.listenTo(s,"abuseform:open",this.open),this.listenTo(s,"abuseform:close",this.close)},close:function(){this.drawerManager.close()},open:function(e){this.drawerManager.isSuspended()||(this.drawerManager.isOpen()?this.drawerManager.replace(r,e):this.drawerManager.open(r,e))}});e.exports=a},35642(e,t,i){"use strict";var n=i(74692),s=i(50283),o=i(44890),r=i(27496),a=i(28017),l=i(16716),c=i(64528),u=i(63224),h=i(86758),d=i(58360),p=i(59213),g=i(6479),f=s.extend({defaults:{headerHeight:52,headerTop:0},events:{"click .tab_discover > a":"onClickExplore","click .login-button":"onClickLogin","click .signup-button":"onClickSignup",mouseenter:"__mouseenter",mouseleave:"__mouseleave"},initialize:function(){var e=o.bool("is_logged_in");this.logo=new u({el:'[prima-component="header-logo"]',data:a.get("Components/DesktopDashboardLogo")}),e&&(this.accountMenu=new h({el:".tab_nav_account"}),n(".tab_activity").length&&(this.activityMenu=new d({el:".tab_activity"})),this._initializeMessaging()),this.set("headerTop",this.$el.position().top),this.listenTo(r,"Header:hide",this.hide),this.listenTo(r,"Header:show",this.show),this.listenTo(r,"Header:setTransparent",this.setTransparent),this.listenTo(r,"notificationBannerManager:update",this.onNotificationBannerChange),this.$window=n(window)},onNotificationBannerChange:function(e){var t=e.bannerHeight;this.set("headerTop",t)},enableCompose:function(){this.composeBtn=new l,this.switcher=new c},disableSticky:function(){this.$el.addClass("l-header-container--u
1nstuck")},setTransparent:function(e){this.$el.toggleClass("l-header-container--transparent",!!e)},hide:function(){var e=this.$window.scrollTop()+this.get("headerTop"),t=e<this.get("headerHeight")?e:this.get("headerHeight");this.$el.css({position:"absolute",top:e+"px"}),this.$el.velocity({translateY:[-t,0],translateZ:"0px"},150).velocity({translateY:"0px",translateZ:"0px",top:0},0)},show:function(){var e=this,t=this.$window.scrollTop(),i=t<this.get("headerHeight")?t:this.get("headerHeight");this.$el.css({position:"absolute",top:t+"px",transform:"translateY("+-i+"px) translateZ(0)"}),this.$el.velocity({translateY:[0,-i],translateZ:"0px"},150,function(){e.$el.css({position:"",top:"",transform:""})}).css({position:"fixed",top:this.get("headerTop")})},onClickExplore:function(){r.trigger("explore-links:click",{loggingData:{source:"app-header"}})},onClickLogin:function(){r.trigger("Kraken:ClickLogin")},onClickSignup:function(){r.trigger("Kraken:ClickSignup")},_initializeMessaging:function(){var e=g(),t=this.$(".tab_messaging");o.bool("is_logged_in")&&t.length>0&&e.canMessage()?this.messaging=new p({inboxAnchorEl:t,inboxPopoverOptions:{isFixedPosition:"fixed"===this.$el.css("position")}}).render():t.length&&t.hide()},__mouseenter:function(){r.trigger("Header:mouseenter")},__mouseleave:function(){r.trigger("Header:mouseleave")}});e.exports=f},36301(e,t,i){"use strict";var n=i(74692),s=i(27496),o=i(44384),r=i(97030),a=i(95870),l=i(6479),c=o.extend({events:{click:"_onClick"},mixins:[r],_onClick:function(e){var t=this,i=n(e.currentTarget),o=i.find(".photo-clickthough");if(o.length){var r=o.attr("href");a.isTumblelogUrl(r)&&r.indexOf("tagged/")>-1&&l()&&(e.preventDefault(),s.trigger("peepr-open-request",{tumblelog_name:this.model.get("tumblelog"),searchTagTerm:r.split("tagged/")[1]}))}else{var c=i.data("lightbox");c&&setTimeout(function(){e.isDefaultPrevented()||t._openLightbox(c)},0)}},_openLightbox:function(e){s.trigger("tumblelogPopover:init",[e]),this.$el.trigger("tumblelogPopover",[{opened:!0}]),this.model.get("pt")&&s.trigger("useraction:explore_click:media",{model:this.model,loggingData:this.loggingData({userAction:"photo"})})}});e.exports=c},36452(e,t,i){"use strict";var n=i(55679),s=i(50283),o=s.extend({defaults:{isSharing:!1,isShareSuccess:!1,isShareFail:!1},initialize:function(e){n.extend(this.attributes,n.pick(e,n.keys(this.defaults)))},getTitle:function(){return null},onShareSuccess:function(e){},onShareFail:function(e){},afterShare:function(e){},isShareSuccess:function(){return this.get("isShareSuccess")},isShareFail:function(){return this.get("isShareFail")},share:function(e){this.trigger("share",e,this)},close:function(){this.trigger("close",this)},remove:function(){return this.trigger("remove",this),s.prototype.remove.apply(this,arguments)}});e.exports=o},36824(e,t,i){"use strict";var n=[].slice,s=function(e,t){return function(){return e.apply(t,arguments)}},o=i(8012);function r(){this._on_resolved=new o,this._on_rejected=new o,this.then=s(this.then,this),this.fail=s(this.fail,this),this.resolve=s(this.resolve,this),this.reject=s(this.reject,this)}r.prototype.then=function(){return this._on_resolved.push.apply(this._on_resolved,arguments),this},r.prototype.success=r.prototype.then,r.prototype.fail=function(){return this._on_resolved.push.apply(this._on_rejected,arguments),this},r.prototype.resolve=function(){if(!this.resolved&&!this.rejected)return this._on_resolved.trigger.apply(this._on_resolved,arguments),this.resolved=!0,this},r.prototype.reject=function(){if(!this.resolved&&!this.rejected)return this._on_rejected.trigger.apply(this._on_rejected,arguments),this.rejected=!0,this},r.prototype.reject_timeout=function(){var e=1<=arguments.length?n.call(arguments,0):[],t=e.shift();return setTimeout(s(function(){this.reject.apply(this,e)},this),t),this},r.prototype.promise=function(){var e=this;return new function(){var t=this;this.fail=function(){return e.fail.apply(e,arguments),t},this.then=function(){return e.then.apply(e,arguments),t},this.success=this.then,this.reject_timeout=function(){return e.reject_timeout.apply(e,arguments),t},this.cid=e.cid}},e.exports=r},36910(e,t,i){"use strict";var n=i(55679),s=i(71742),o=i(17383),r=s.extend({name:"BaseKeyboardManager",defaults:{isDebugEnabled:!1,keepInactiveItems:!0,allowMultipleActiveViews:!1},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),this.collection=new o,this.listenTo(this.collection,"add",this._onAddItem),this.listenTo(this.collection,"remove",this._onRemoveItem),this.listenTo(this.collection,"change:isActive",this._onItemActiveChange)},addKeyboardAccess:n.noop,removeKeyboardAccess:n.noop,add:function(e,t){return!(!e||!t)&&(!this.collection.get(e)&&(this.get("keepInactiveItems")||this.get("allowMultipleActiveViews")||this.collection.remove(this.collection.models),this.collection.unshift({namespace:e,view:t}),this._adjustActiveStates(),!0))},remove:function(e){var t=this.collection.getByNamespace(e);return!n.isEmpty(t)&&(this.collection.remove(t),this._adjustActiveStates(),!0)},toggle:function(e,t,i){return i?this.add(e,t):this.remove(e)},_onAddItem:function(e){return this.addKeyboardAccess(e.get("view"))},_onRemoveItem:function(e){return this.removeKeyboardAccess(e.get("view"))},_adjustActiveStates:function(){var e,t;0!==this.collection.length&&(e=this.collection.first(),t=this.collection.rest(),e&&e.set("isActive",!0),this.get("allowMultipleActiveViews")||n.each(t,function(e){e.set("isActive",!1)},this))},_onItemActiveChange:function(e,t){return t?this.addKeyboardAccess(e.get("view")):this.removeKeyboardAccess(e.get("view"))}});e.exports=r},37068(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }
1\nwith (obj) {\n\n if (transitionBackground) { ;\n__p += ' <div class=\"post-transition-background\"></div> ';\n } ;\n__p += ' ';\n if (originalContent) { ;\n__p += ' <div data-subview=\"originalContent\"></div> ';\n } ;\n__p += ' <div data-subview=\"loader\"></div><div data-subview=\"postForm\"></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},37136(e,t,i){"use strict";var n=i(80160).extend({idAttribute:"name",defaults:{name:null,filePath:null,fileType:"audio/mpeg"}});e.exports=n},37158(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(60874),r=i(77594),a=i(64147),l=i(10768),c=i(78421),u=i(85179),h=i(471),d=i(92163),p=i(61442),g=i(18486),f=s.extend({className:"messaging-share-post-external-networks",template:g,defaults:{isLoading:!1,isFocused:!1,focusedView:null,isExternalSharingEnabled:!0},mixins:[r,o,u],keycommands:{"keydown:left":"_onKeyPressLeft","keydown:right":"_onKeyPressRight","keydown:backspace":"_onKeyPressBackspace","keydown:shift+backspace":"_onKeyPressBackspace"},subviews:{networkView:{constructor:d,options:function(e){return{onFocus:n.bind(n.partial(e._setIsFocusedDebounced,!0),e),onBlur:n.bind(n.partial(e._setIsFocusedDebounced,!1),e),onShowSubview:n.bind(e._onShowSubview,e),onShareSuccess:n.bind(e._onShareSuccess,e),onShareFail:n.bind(e._onShareFail,e),onShareClick:n.bind(e._onShareClick,e)}},collection:function(e){return e.collection}},networksLoaderView:{constructor:c,options:{className:"messaging-share-post-favorites-loader",variation:"small centered",loading:!1}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"keyboardNamespace","keyboardManager","externalNetworksDataModel")),this._setIsFocusedDebounced=n.debounce(n.bind(this._setIsFocused,this),0),this.keyboardViewName="networkView",this.collection=new h,this.disableKeys()},afterRenderSubviews:function(){if(this.listenTo(this.collection,"reset update",this._onCollectionChange),this.listenTo(this,"change:isFocused",this._onChangeIsFocused),this.listenTo(this,"change:focusedView",this._onChangeFocusedView),this.listenTo(this,"change:isLoading",this._onChangeIsLoading),this.listenTo(this.externalNetworksDataModel,"request",this._externalNetworksDataModelRequest),this.listenTo(this.externalNetworksDataModel,"sync",this._externalNetworksDataModelSync),this.scrollbar=new a(this.$el),this.updateScrollbar(!0),this._onChangeIsLoading(this,this.get("isLoading")),this.externalNetworksDataModel.isPopulated())this.updateComponents();else{if(!this.externalNetworksDataModel.isValid())return void 0;this.externalNetworksDataModel.fetch()}},beforeRemove:function(){this.keyboardManager.remove(this.keyboardNamespace),this.scrollbar&&this.scrollbar.destroy()},resetFocus:function(){this.set("focusedView",null),this.deselect(this.keyboardViewName)},toggle:function(e){this.$el.toggle(e),e||this.resetFocus()},focus:function(){this.focusFirst()},focusFirst:function(){this.set("focusedView",this.selectFirst(this.keyboardViewName))},focusLast:function(){this.set("focusedView",this.selectLast(this.keyboardViewName))},focusNext:function(){this.set("focusedView",this.selectNext(this.keyboardViewName))},focusPrevious:function(){this.set("focusedView",this.selectPrevious(this.keyboardViewName))},isLastFocused:function(){return this.isLastSelected(this.keyboardViewName)},isFirstFocused:function(){return this.isFirstSelected(this.keyboardViewName)},updateScrollbar:function(e){this.rendered&&this.scrollbar&&n.defer(n.bind(this.scrollbar.update,this.scrollbar))},updateComponents:function(){this.collection.reset(n.map(this._getExternalNetworks(),function(e){return{component:e}}))},_setIsFocused:function(e){this.rendered&&this.set("isFocused",e)},_getExternalNetworks:function(){var e=this.get("isExternalSharingEnabled"),t=[{Constructor:p.Flag,options:this._getFlagOptions,isExternal:!1},{Constructor:p.Permalink,options:this._getPermalinkOptions,isExternal:!1},{Constructor:p.CopyPermalink,options:this._getPermalinkOptions,isExternal:!1},{Constructor:p.Embed,options:this._getEmbedOptions,isExternal:!1,isIncluded:this._isShowEmbed},{Constructor:p.Email,options:this._getEmailOptions,isExternal:!0},{Constructor:p.Twitter,options:this._getTwitterOptions,isExternal:!0}
1,{Constructor:p.Pinterest,options:this._getPinterestOptions,isIncluded:this._isShowPinterest,isExternal:!0},{Constructor:p.Reddit,options:this._getRedditOptions,isExternal:!0}];return n.reduce(t,n.bind(function(t,i){var s;return!e&&i.isExternal||n.isFunction(i.isIncluded)&&!i.isIncluded.call(this)||(s=new i.Constructor(this._getBaseAndNetworkOptions(i.options.call(this))),t.push(s)),t},this),[])},_getPermalinkOptions:function(){return{}},_getEmbedOptions:function(){return{}},_getEmailOptions:function(){return{}},_getTwitterOptions:function(){var e=this.externalNetworksDataModel.get("twitter_username");return{isPopup:n.isEmpty(e),username:e}},_getPinterestOptions:function(){var e=this.externalNetworksDataModel.get("pinterest_share_window"),t=n.get(e,"url");return{popupOptions:n.get(e,"dimensions"),popupUrl:t}},_isShowPinterest:function(){return this.externalNetworksDataModel.get("show_pinterest")},_isShowEmbed:function(){return this.externalNetworksDataModel.get("show_embed")},_getRedditOptions:function(){return{}},_getFlagOptions:function(){return{}},_getBaseExternalNetworkOptions:function(){var e=this.externalNetworksDataModel.toJSON(),t=n.extend({},e,{id:n.get(e,"post_id")});return{postModel:new l(t)}},_getBaseAndNetworkOptions:function(e){return this._baseExternalNetworkOptions||(this._baseExternalNetworkOptions=this._getBaseExternalNetworkOptions()),n.extend({},this._baseExternalNetworkOptions,e)},_onKeyPressLeft:function(e){e.preventDefault(),this.focusPrevious()},_onKeyPressRight:function(e){e.preventDefault(),this.focusNext()},_onKeyPressBackspace:function(e){e.preventDefault()},_onChangeFocusedView:function(e,t){var i=this.previous("focusedView");i&&i.setFocused(!1),t&&t.setFocused(!0)},_onChangeIsFocused:function(e,t){t?(this.keyboardManager.add(this.keyboardNamespace,this),this.trigger("focus",this)):(this.set("focusedView",null),this.keyboardManager.remove(this.keyboardNamespace),this.trigger("blur",this))},_onCollectionChange:function(){this.resetFocus(),this.updateScrollbar()},_onShowSubview:function(e){this.trigger("share:subview:show",e)},_onShareSuccess:function(e){this.trigger("share:success",e)},_onShareFail:function(e){this.trigger("share:fail",e)},_onShareClick:function(e){this.trigger("share:click",e)},_onChangeIsLoading:function(e,t){this.networksLoaderView.set("loading",t)},_externalNetworksDataModelRequest:function(e){this.set("isLoading",!0)},_externalNetworksDataModelSync:function(e){this.set("isLoading",!1),this.updateComponents()}});e.exports=f},37271(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(80160),r=i(26771),a=i(19951),l=i(70201),c=o.extend({mixins:[r],relations:{alt_sizes:a,original_size:l},defaults:{alt_sizes:null,original_size:null},getActionMarkup:function(e,t,i){return e=n.escape(e),t=t||"",i=i||"",n.isEmpty(e)?s("sent a photo"):s("%1$s%2$s%3$s sent a photo",t,e,i)},getAltSizes:function(){return this.get("alt_sizes")},getHighResImageUrl:function(){var e=this.getAltSizes().sort().last();return n.isEmpty(e)?null:e.get("url")},getOriginalSize:function(){return this.get("original_size")},hasAltSizes:function(){return!this.getAltSizes().isEmpty()},getImageAtSize:function(e){var t,i=this.getAltSizes().sort();return e=e||250,i.isEmpty()?this.getOriginalSize():(t=i.find(function(t){return t.get("width")>=e}),n.isEmpty(t)&&(t=i.last()),t)}});e.exports=c},37335(e,t,i){"use strict";var n=i(55679),s=i(50283).extend({className:"popover--conversation-popover",defaults:{animationSpeed:250,skipAnimationOnRender:!1,skipAnimationOnRemove:!1},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"viewOptions","viewConstructor")),n.isFunction(this.viewOptions)&&(this.viewOptions=this.viewOptions.call(this,this))},render:function(){return this.conversationView=new this.viewConstructor(this.viewOptions),this.$el.html(this.conversationView.render().$el),!this.get("skipAnimationOnRender")&&this.get("animationSpeed")>=0&&this._animateIn(),this},teardown:function(){var e=this.get("animationSpeed");return!this.get("skipAnimationOnRemove")&&e>=0?(this.$el.addClass("hide-popover"),setTimeout(n.bind(this.remove,this),e)):this.remove(),this},beforeRemove:function(){this.conversationView&&this.conversationView.remove()},getView:function(){return this.conversationView},poll:function(){var e=this.getView();if(e)return e.poll()},refresh:function(e){var t=this.getView();if(t)return t.refresh(e)},fetch:function(){var e=this.getView();if(e)return e.fetch()},focus:function(){var e=this.getView();if(e)return e.focus()},isMinimized:function(){var e=this.getView();if(e)return e.isMinimized()},_animateIn:function(){this.$el.addClass("hide-popover"),n.defer(n.bind(function(){this.rendered&&this.$el.removeClass("hide-popover")},this))}});e.exports=s},37552(e,t,i){var n=i(55679),s=i(74692),o=i(27496),r=s(document),a=s(window),l={},c={};function u(){c.documentHeight=l.documentHeight,l.documentHeight=r.height(),c.windowHeight=l.windowHeight,l.windowHeight=a.height(),c.windowWidth=l.windowWidth,l.windowWidth=a.width(),c.windowScrollTop=c.windowScrollY=l.windowScrollTop,l.windowScrollTop=l.windowScrollY=a.scrollTop()}l.documentHeight=c.documentHeight=null,l.windowHeight=c.windowHeight=null,l.windowWidth=c.windowHeight=null,l.windowScrollTop=c.windowScrollTop=null,l.windowScrollY=c.windowScrollY=null;var h,d=!Object.hasOwnProperty.call(window,"requestAnimationFrame")&&window.requestAnimationFrame||!Object.hasOwnProperty.call(window,"webkitRequestAnimationFrame")&&window.webkitRequestAnimationFrame||!Object.hasOwnProperty.call(window,"mozRequestAnimationFrame")&&window.mozRequestAnimationFrame||!Object.hasOwnProperty.call(window,"oRequestAnimationFrame")&&window.oRequestAnimationFrame||function(e){window.setTimeout(function(){e()},50)};function p(){r.off("keydown.DOMEventor keyup.DOMEventor"),o.on("DOMEventor:startKeyboardObserver",h),o.off("DOMEventor:stopKeyboardObserver")}h=function(){var e=[],t={8:"backspace",9:"tab",13:"enter",16:"shift",17:"ctrl",18:"alt",20:"capslock",27:"escape",32:"space",33:"pageup",34:"pagedown",35:"end",36:"home",37:"left",38:"up",39:"right",40:"down",45:"insert",46:"delete",48:"0",49:"1",50:"2",51:"3",52:"4",53:"5",54:"6",55:"7",56:"8",57:"9",65:"a",66:"b",67:"c",68:"d",69:"e",70:"f",71:"g",72:"h",73:"i",74:"j",75:"k",76:"l",77:"m",78:"n",79:"o",80:"p",81:"q",82:"r",83:"s",84:"t",85:"u",86:"v",87:"w",88:"x",89:"y",90:"z",91:"leftmeta",92:"rightmeta",93:"rightmeta",96:"num0",97:"num1",98:"num2",99:"num3",100:"num4",101:"num5",102:"num6",103:"num7",104:"num8",105:"num9",106:"multiply",107:"add",109:"subtract",110:"decimal",111:"devide",112:"f1",113:"f2",114:"f3",115:"f4",116:"f5",117:"f6",118:"f7",119:"f8",120:"f9",121:"f10",122:"f11",123:"f12",144:"numlock",145:"scrolllock",186:"semicolon",187:"equal",188:"comma",189:"dash",190:"period",191:"forwardslash",192:"graveaccent",219:"openbracket",220:"backslash",221:"closebracket",222:"singlequote"};
1r.on("keydown.DOMEventor keyup.DOMEventor",function(i){var n=i.type;if("keyup"===n||"keydown"===n){var r=s(i.target),a=i.which;if(!((r.is("input")||r.is("textarea")||r.is("select"))&&a>=48&&a<=90)||i.metaKey||i.ctrlKey||i.altKey){a>=48&&a<=90&&"keydown"===n&&(e[a]=1);var l="";for(var c in e)"keydown"===n&&a!==parseInt(c,10)&&(l+=t[c]?t[c]+"+":"");var u=n+":"+(i.altKey&&18!==a?"alt+":"")+(i.ctrlKey&&17!==a?"ctrl+":"")+(i.metaKey&&91!==a&&92!==a&&93!==a?"meta+":"")+(i.shiftKey&&16!==a?"shift+":"")+(l||"")+(t[a]||"");o.trigger("DOMEventor:"+u,i,u),"keyup"===n&&(e=[])}}}),o.off("DOMEventor:startKeyboardObserver"),o.on("DOMEventor:stopKeyboardObserver",p)};var g={init:n.once(function(){u(),function(){var e,t=0;function i(i){t--||(c.documentHeight=l.documentHeight,l.documentHeight=r.height(),t=1),c.windowScrollTop=c.windowScrollY=l.windowScrollTop,l.windowScrollTop=l.windowScrollY=a.scrollTop(),o.trigger("DOMEventor:flatscroll",l),e=!1}a.on("scroll.DOMEventor-nextScrollLoop",function(){e||(d(i),e=!0)})}(),function(){var e;function t(t){u(),o.trigger("DOMEventor:flatresize",l),e=!1}a.on("resize.DOMEventor-nextResizeLoop",function(){e||(d(t),e=!0)})}(),h(),o.on("DOMEventor:updateRect",u)}),rect:function(){return l},lastRect:function(){return c}};e.exports=g},37569(e,t,i){"use strict";var n=i(55679),s=i(97583).extend({logKey:"dashboard_embed",logOptions:{init_event:!1},events:{"/^post:((?:un)?docked)$/":"handleEvent","post:embed:stateChange":"logStateChange"},handleEvent:function(e,t){var i=n.extend({},t);i.postData&&(i.post_id=i.postData.id,i.tumblelog=i.postData.tumblelog,delete i.postData),this.log(e,i)},logStateChange:function(e,t){if(!n.isEmpty(t)&&t.state&&t.postID&&t.service){if("tumblr"===t.service)return;this.log(t.state,{service:t.service,post_id:t.postID})}}});e.exports=s},37623(e,t,i){"use strict";var n=i(55679);function s(e,t){return n.zipObject(e,n.map(e,t))}function o(e,t){return n.isFunction(t)&&(t=s(n.keys(e),t)),n.transform(e,function(e,i,s){e[n.result(t,s)||s]=i},{})}o.createKeyMap=s,e.exports=o},37673(e,t,i){var n=i(55679),s=i(74692),o=i(58521),r=i(12461),a=i(98635),l=function(){function e(){var e=this;s(this.editor.element).on("keypress",function(n){var s=!1;if(34===n.charCode)s=i.call(e);else{if(39!==n.charCode)return;s=t.call(e)}s&&n.preventDefault()})}function t(){var e=this.config.singleQuotes;return l.call(this,e.open,e.close,e.prime)}function i(){var e=this.config.doubleQuotes;return l.call(this,e.open,e.close,e.prime)}function l(e,t,i){var a=o.getSelection();if(!a.isCollapsed)return!1;var l=a.anchorNode;l.normalize();var c=r.saveSelection(l),u=l.textContent.slice(0,c.start),h=u.charAt(u.length-1),d=l.lastChild&&"BR"===l.lastChild.nodeName?l.lastChild:null,p=n.any(this.config.openingMatches,function(e){return e.test(h)})||d,g="";g=!h||p?e:/\d/.test(h)?i:t;var f=document.createTextNode(g),m=a.getRangeAt(0);return m.deleteContents(),m.insertNode(f),d&&d.previousSibling&&"BR"===d.previousSibling.nodeName&&s(d).remove(),m.setEndAfter(f),m.collapse(!1),a.removeAllRanges(),a.addRange(m),!0}return function(t,i){if(a.browser.msie)return null;this.editor=t,this.config={openingMatches:[/\s/,/\u200B/,/[=]/],singleQuotes:{open:"‘",close:"’",prime:"′"},doubleQuotes:{open:"“",close:"”",prime:"″"}},n.extend(this.config,i||{}),e.call(this)}}();e.exports=l},38037(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(27496),r=i(64491),a=i(59952),l=i(28017),c=i(24743),u=s.extend({className:"popover--message-controls-popover",mixins:[r,a],template:c,events:{'click [data-action="delete"]':"_delete",'click [data-action="block"]':"_block",'click [data-action="flag"]':"_flag"},initialize:function(e){this.options=n.extend({},e),this.showFlagAndBlock=this.options.blockString&&this._notUsersOwnBlog(),this.post=e.post},_getSender:function(){return!(!this.options.blockString||-1!==this.options.blockString.indexOf(":"))&&this.options.blockString},_notUsersOwnBlog:function(){var e=this._getSender();if(e){var t=l.get("Context/userinfo/channels");return t=n.pluck(t,"name"),!n.includes(t,e)}return!0},_delete:function(e){e.preventDefault(),this.post.delete(e)},_block:function(e){e.preventDefault(),this.post.block(e)},_flag:function(e){e.preventDefault();var t={mode:"message",post:this.post.model},i=this._getSender();i&&(t.sender=i),o.trigger("abuseform:open",t),o.trigger("Kraken:abuseform:open",t)},render:function(){return this.$el.html(this.template()),this},teardown:function(){return this.$el.remove(),this}});e.exports=u},38039(e,t,i){var n=i(55679),s=i(74692),o=i(50283),r=i(39349),a=i(98621),l=i(98237),c=i(57505),u=i(44890),h=i(6479),d=i(80158),p=o.extend({className:"inbox-conversation",template:r,mixins:[l],subviews:{statusIndicator:{constructor:d,options:function(e){return{isOnline:-1!==e.otherParticipant.get("seconds_since_last_activity"),canSeeUIFlag:u.bool("status_indicator"),name:e.otherParticipant.get("name")}}}}
1,defaults:{maxInitialMessageLength:100,currentMessage:null},events:{"click [data-open-conversation]":"_onClickConversation"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","channels","currentBlogModel")),this.participants=this.model.get("participants"),this.sortedParticipants=this.participants.getSortedByChannels(this._getOwnSortedBlogIds()),this.otherParticipant=n.first(this.sortedParticipants),this.set("currentMessage",this.model.getInboxMessage())},afterRender:function(){this.listenTo(this.model,"change:last_read_ts change:last_modified_ts",this._onChangeTimestamps),this.listenTo(this,"change:currentMessage",this._onChangeCurrentMessage),this._onChangeCurrentMessage(this,this.get("currentMessage"));var e=this.$el.find(".pixelated-avatar");n.each(e,n.bind(function(e){s(e).removeClass("hide").addClass("show"),c.drawPixelatedImages(this)},this))},openConversation:function(){this.eventBus.trigger(this.eventBus.CONVERSATION_OPEN_CONVERSATION_MODEL,this.model,"inbox")},getTemplateData:function(){var e=h(),t=this.otherParticipant.get("is_adult"),i=e.get("channels").map(function(e){return e.name}),s=n.contains(i,this.model.get("blogName")),o=u.bool("safe_mode")&&e.get("safe_mode");return{name:this.otherParticipant.get("name"),avatarUrl:this.otherParticipant.getAvatarUrl(),message:this._getEscapedMessageMarkup(this.get("currentMessage")),isSafeModeEnabled:o,isUser:s,blogIsAdult:t}},getMessageParticipant:function(e){return this.participants.get(e.get("participant"))},_getEscapedMessageMarkup:function(e){var t,i=this._getAdditionalBlogName(e),s=n.escape(e.getMessage());return n.isEmpty(s)||(s=s.substring(0,this.get("maxInitialMessageLength"))),t=e.getActionMarkup(i,'<span class="name">',"</span>"),n.compact([t,s]).join(": ")},_safeTruncateMessage:function(e){var t=this.js$("message"),i=this.js$("message-text"),s=function(){a(t),n.isFunction(e)&&e.call(this,i.html())};t.height()?s.call(this):(this.$el.css("visibility","hidden"),n.defer(n.bind(function(){this.rendered&&(s.call(this),this.$el.css("visibility",""))},this)))},_isLastMessageFromSelf:function(e){return!n.isEmpty(e)&&!n.isEmpty(this.otherParticipant)&&this.otherParticipant.get("uuid")!==e.get("uuid")},_getAdditionalBlogName:function(e){var t;return n.isEmpty(e)?null:(t=this.getMessageParticipant(e),n.isEmpty(t)?null:this._isLastMessageFromSelf(t)?t.get("name"):null)},_onChangeTimestamps:function(e){this.set("currentMessage",this.model.getInboxMessage())},_onChangeCurrentMessage:function(e,t){var i=this.getMessageParticipant(t),s=t.get("truncatedText");this.$el.toggleClass("is-unread",this.model.isUnread()&&!this._isLastMessageFromSelf(i)),n.isEmpty(s)?(this.js$("message-text").html(this._getEscapedMessageMarkup(t)),this._safeTruncateMessage(function(e){t.set("truncatedText",e)})):this.js$("message-text").html(s)},_onClickConversation:function(e){e.preventDefault(),this.openConversation()},_getOwnSortedBlogIds:function(){return this.channels.getSortedIds(this.currentBlogModel.getId())}});e.exports=p},38044(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, \'\') }\nwith (obj) {\n__p += \'<div class="post_form_wrapper v_center_el"><div class="post_avatar"><a class="post_avatar_link use_blog_avatar animating" data-user-avatar-url="\' +\n__e( sender.avatar_url ) +\n\'" data-avatar-url="\' +\n__e( sender.avatar_url ) +\n\'" data-blog-url="\' +\n__e( sender.blog_url ) +\n\'"><span class="post_avatar_link blog_avatar anonymous" data-anonymous-avatar-url="/images/anonymous_avatar_64.gif" style="background-image: url(/images/anonymous_avatar_64.gif);"></span> <span class="post_avatar_link blog_avatar new" style="background-image: url(\' +\n__e( sender.avatar_url ) +\n\');"></span></a></div><div class="post-container"><form enctype="multipart/form-data" class="active"><div class="post-container-inner post post-form--asks"><div class="post-form--header"><div class="controls-container"> \';\n\n                        var senderMarkup = \'<span class="ask-from"><span class="tumblelog_name">\' + sender.name + \'</span><span class="anonymous">\' + __(\'anonymous\') + \'</span></span>\';\n                        var recipientMarkup = \'<span class="ask-recipient-label">\' + recipient.name + \'</span>\';\n                        ;\n__p += \' \' +\n((__t = ( __(\'%1$s <span class="ask-to-label">to</span> %2$s\', senderMarkup, recipientMarkup) )) == null ? \'\' : __t) +\n\' <span class="ask-character-count"></span></div></div><div class="post-form--form post-content-text"><textarea class="ask-question" name="question" placeholder="\' +\n__e( __(\'Ask me anything\') ) +\n\'" maxlength="\' +\n__e( character_limit ) +\n\'" autofocus></textarea></div><div class="post-form--bottom"><div class="post-form--controls"><div class="controls-container"><div class="control left"><button type="button" class="chrome flat close">\' +\n__e( __(\'Close\') ) +\n\'</button></div> \';\n if(recipient.allow_anonymous) { ;\n__p += \' <div class="control right"><div class="ask-anonymously"> \';\n var randId = Math.floor(Math.random() * 1000000) ;\n__p += \' <label class="binary_switch"><input id="ask_anonymously_switch_\' +\n__e(randId) +\n\'" class="ask-anonymously-switch" type="checkbox" name="anonymous" value="1"> <span class="binary_switch_track"></span> <span class="binary_switch_button"></span></label> <label class="ask-anonymously-label" for="ask_anonymously_switch_\' +\n__e(randId) +\n\'">\' +\n__e( __(\'Ask anonymously\') ) +\n\'</label></div></div> \';\n } ;\n__p += \' <div class="control right"><button class="chrome blue ask-button" type="submit" disabled="disabled">\' +\n__e( __(\'Ask\') ) +\n\'</button></div></div></div><ul class="post-form--error-bar messages errors-ask"></ul></div></div></form></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},38136(e,t,i){"use strict";var n=i(74692);function s(){return n('iframe[src^=""]').parent().parent()[0]}var o=document.createElement("div");function r(){var e=s();if(e){var t=0,i=0,n=e.getBoundingClientRect(),r=document.querySelectorAll(".abuse-form, .help-form");if(r.length){var a,l=r[0].getBoundingClientRect();t=l.left,i=l.width,o.style.display="hidden"===e.style.visibility?"none":"block",(n.left<t||n.right>t+i)&&(o.style="\n            position: absolute;\n            zIndex: -1000;\n            left: ".concat(n.left,"px;\n            top: ").concat(n.top,"px;\n            width: ").concat(n.width,"px;\n            height: ").concat(n.height,"px;\n        "),a="captcha_placeholder",o.id=a,document.getElementById(a)||document.body.append(o),e.style.left="".concat(t+(i-n.width)/2,"px"))}}}var a=null;function l(){var e=s();e&&function(e){a&&"function"==typeof a.disconnect&&a.disconnect(),(a=new MutationObserver(r)).observe(e,{attributes:!0,attributeFilter:["style"]})}(e)}window.addEventListener("DOMContentLoaded",function(){new MutationObserver(l).observe(document.body,{childList:!0})})},38333(e,t,i){var n=i(55679),s=i(12509);e.exports=n.extend(s,{RichTextEditor:i(79348),PlainTextEditor:i(19188),SelectionContext:i(58521),SelectionPersistence:i(12461),Utils:i(98635),HumanKeys:i(81203)})},38578(e,t,i){"use strict";var n=i(55679),s=i(21391),o=i(28724),r=i(51954),a=new o(n.extend({},r.props,{defaults:n.extend({},s.Events),before:{initialize:function(){var e=n.defaults({},n.result(this,"defaults"));this.attributes={},this.set(e),this.changed={}}}}));e.exports=a},38723(e,t,i){"use strict";var n=i(55679);e.exports=function(e){if(n.isString(e)){if("true"===(e=e.toLowerCase())||"1"===e||"on"===e)return!0;
1if("false"===e||""===e||"off"===e)return!1;if(e=n.parseInt(e),n.isNaN(e))return!0}return!!e}},38904(e){"use strict";var t="If anyone is sending you unwanted messages or reblogging your posts in an abusive way, we encourage you to be proactive and block the hell out of them. And if someone blocks you, don't attempt to circumvent the block feature or otherwise try to communicate with them. Bear in mind that many victims of online harassment are younger; being a teenager is complicated enough without the anxiety, sadness and isolation caused by bullying.",i="Don't encourage violence or hatred. Don't post content for the purpose of promoting or inciting the hatred of, or dehumanizing, individuals or groups based on race, ethnic or national origin, religion, gender, gender identity, age, veteran status, sexual orientation, disability, or disease.",n="Don't use Tumblr to deceptively obtain personal information. Don't post content that violates anyone's privacy, especially personally identifying or confidential information like credit card numbers, social security numbers, or unlisted contact information. Do not post private messages without the sender's consent. And absolutely do not post unauthorized nude imagery—that is, private photos or videos taken or posted without the subject's consent.",s="Don't post or solicit content that features child abuse, the sexualization of minors, or the facilitation or promotion of child sexual abuse.",o="Don't post content that actively promotes or glorifies self-harm. This includes content that urges or encourages others to: cut or injure themselves; embrace anorexia, bulimia, or other eating disorders; or attempt suicide rather than, e.g., seeking counseling or treatment, or joining together in supportive conversation with those suffering or recovering from depression or other conditions.",r="When a trademark is used in a confusingly similar manner, it may be considered trademark infringement. However, please note that a trademark does not give you the sole and exclusive right to use that trademark in every context. For example, a website using the name of your business in the context of reviewing your products or even criticizing your brand is NOT infringing your trademark. Please consult your own legal counsel or refer to %1$sLumen's FAQs about Trademark%2$s for more information. <br><br> If you believe that your trademark has been infringed upon, please submit your complaint via the form below.",a="Don't do things that may cause confusion between your blog and another person, organization, or company, like registering a deliberately confusing URL or pretending to be a celebrity or an elected official.<br><br> Don't impersonate anyone. <br><br> While you're free to ridicule, parody, or marvel at the alien beauty of Benedict Cumberbatch, you can't pretend that you're actually Benedict Cumberbatch.",l="We don't tolerate content that promotes, encourages, or incites acts of terrorism. That includes content which supports or celebrates terrorist organizations, their leaders, or associated violent activities.",c="Unlawful Uses or Content",u="Don't use Tumblr to conduct illegal behavior, like fraud or phishing. That should be pretty obvious to you, a decent human being. Additionally, don't use Tumblr to buy, sell, trade or share instructions to manufacture any types of drugs, substances, devices, goods or weapons which may be restricted — this includes firearms, firearm parts, 3D printed firearms or parts, explosives, accessories, ammunition or anything else designed to hurt others. <br><br> Don't use Tumblr to facilitate sex trafficking, other forms of human trafficking, or illegal prostitution. If you see this activity on Tumblr, report it, and encourage victims to contact law enforcement or the National Human Trafficking Hotline at 1-888-373-7888.",h="\nWe encourage Tumblr users to express themselves freely, including about political issues, but there is a specific set of election interference\nactivities that are strictly prohibited on Tumblr. This form is designed to allow you to report those <i>limited and specific</i> types of\ncontent so that we can prioritize them.\n<br><br>\nTo get to these important reports promptly, <i>we can't accept any other content reports through this form</i> (even if the post might be about\npolitical issues). Please <b>only</b> submit reports of election interference that fall into one of the options below through this form.\nIf you submit something that does not fall within the specific types of content listed below, we will not be able to respond to it. Report anything\noutside these narrow categories through the appropriate form at %1$stumblr.com/abuse%2$s.\n",d="What’s going on?",p="Clearly explain how the content or user violates the option you selected. Include specific evidence, quotes, or examples. Reports without clear detail may not be actionable.",g="URL of the content you're reporting",f=[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g}]}
1,{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"How did you learn that a child may be involved?",fields:[{type:"textarea",optional:!0,name:"age_evidence",placeholder:"e.g. age stated in bio, mentioned in a post, said in a direct message, etc."}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],m={start:{title:"",description:"",template:"start"},abuse:{title:"What kind of violation is it?",options:[{name:"Copyright violation",to:"copyright"},{name:"Trademark violation",to:"trademark"},{name:"Report illegal content in the EU",to:"illegal-eu",visibility:"eu"},{name:"Report non-consensual intimate imagery",to:"ncii",visibility:"ncii"},{name:"Report violating content under Brazil ECA",to:"illegal-br",visibility:"brazil"},{name:"Harm to minors",to:"minors-start",visibility:"harm_to_minors"},{name:"Child exploitation",to:"child-exploitation",visibility:"child_exploitation"},{name:"Privacy violation",to:"privacy"},{name:"Impersonation or Non-Genuine Behavior",to:"non-genuine"},{name:"Suicide, self injury, or eating disorder concern",to:"selfharm-start"},{name:"Hate speech violation",to:"hatespeech"},{name:"Suspected terrorism",to:"terrorism-start"},{name:"Sexually explicit material",to:"sexually-explicit-material"},{name:"Gore, mutilation, or bestiality",to:"gore"},{name:"Violent content or threat",to:"violentthreats-start"},{name:"I’m being harassed",to:"harassment"},{name:"Unlawful uses or content",to:"unlawful-uses-or-content"},{name:"Spam",to:"reporting-spam"},{name:"Election Interference",to:"election-interference"},{name:"Appealing Reports Decisions",to:"dsa-reporter-appeal"}],prev:"start"},"community-abuse":{title:"What kind of violation is it?",options:[{name:"Trademark violation",to:"trademark"},{name:"Report illegal content in the EU",to:"illegal-eu",visibility:"eu"},{name:"Report non-consensual intimate imagery",to:"ncii",visibility:"ncii"},{name:"Report violating content under Brazil ECA",to:"illegal-br",visibility:"brazil"},{name:"Harm to minors",to:"minors-start",visibility:"harm_to_minors"},{name:"Child exploitation",to:"child-exploitation",visibility:"child_exploitation"},{name:"Impersonation or Non-Genuine Behavior",to:"non-genuine"},{name:"Suicide, self injury, or eating disorder concern",to:"selfharm-start"},{name:"Hate speech violation",to:"hatespeech"},{name:"Suspected terrorism",to:"terrorism-start"},{name:"Sexually explicit material",to:"sexually-explicit-material"},{name:"Gore, mutilation, or bestiality",to:"gore"},{name:"Violent content or threat",to:"violentthreats-start"},{name:"Unlawful uses or content",to:"unlawful-uses-or-content"},{name:"Spam",to:"reporting-spam"},{name:"Election Interference",to:"election-interference"},{name:"Appealing Reports Decisions",to:"dsa-reporter-appeal"}],prev:"start"},harassment:{title:"Harassment",tagline:"Are you the person being harassed?",description:t,options:[{name:"Yes",to:"harassment-self",flaggingTo:"harassment-self"},{name:"No",to:"harassment-someoneelse-psa"}],prev:"start"},"harassment-self":{title:"Harassment",description:t,tagline:"What kind of harassment is taking place?",options:[{name:"My privacy is being violated (e.g. explicit private photos or personal contact information).",to:"privacy-self"},{name:"I’m being threatened with specific bodily harm, theft, property damage, or financial harm.",to:"violentthreats-form"},{name:"Someone posted content sexualizing me against my wishes.",to:"harassment-self-uws"},{name:"I’m being targeted and harassed.",to:"harassment-self-psa"}],prev:"harassment"},"harassment-someoneelse-psa":{title:"Harassment",description:t,message:[{type:"text",text:"We appreciate you bringing this to our attention. In these cases, we need to hear directly from someone who is being featured or discussed on this blog."}],button:{type:"dismiss"},prev:"harassment"},"harassment-self-psa":{title:"Harassment",description:[{type:"text",text:t},{type:"text",link:"",text:"You can and should stop viewing content from a blogger that bothers you. Unfollow them, to start with. You can also block them. If you need help doing so, %1$shave a look at the docs%2$s. Blocked users can't follow you, can’t see your posts on their dashboard, reblog your posts, like your posts, or do anything else with your posts. You also won't get Asks or messages from users you've blocked, and you won’t appear in their search results. If you block someone, and don't otherwise initiate contact with that person, they won’t have a way of communicating with you on Tumblr."}],options:[{name:"If using the block feature has not solved this issue, you can report it here",to:"harassment-self-where"}],prev:"harassment-self"},"harassment-self-where":{title:"Harassment",description:t,tagline:"Where on Tumblr is the harassment taking place?",options:[{name:"Somewhere on a blog or in a post (including tags)",to:"harassment-self-blog"},{name:"In an inbox message (an Ask or Fan Mail)",to:"harassment-self-inbox"}],prev:"harassment-self-psa"},"harassment-self-inbox":{title:"Harassment",description:t,form:[{groupType:"permalink-hint"},{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]}
1,{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"harassment-self-where"},"harassment-self-blog":{title:"Harassment",description:t,form:[{groupType:"permalink-hint"},{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"harassment-self"},"harassment-self-uws":{title:"Harassment",description:t,form:[{groupType:"permalink-hint"},{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"harassment-self"},"harassment-self-message":{title:"Harassment",description:t,form:[{groupLabel:"Content you're reporting",fields:[{type:"post-id",name:"post-id"}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"start"},"harassment-self-message-anon-notice":{title:"Harassment",description:t,message:[{type:"text",text:"We're sorry you've had a negative experience with anonymous messages on Tumblr. Because not all anonymous messages are associated with a​ Tumblr​ account, we can't always take action against a specific account. However, there are some steps that you can take to prevent any further unwanted interactions."},{type:"text",link:"/docs/social#ask",text:"First, you can block the IP address from which any given anonymous message was sent. Just click or tap the ellipses on the message, select Block and you'll permanently prevent any anonymous messages from that ​IP ​address from ever getting to your inbox. Just an FYI: There is no way to undo this action. Additionally, the person sending unwanted anonymous messages could still send you anonymous messages from another IP address. If you're receiving these anonymous messages from multiple IP addresses, you can disable anonymous messages or even disable the Ask feature entirely in your blog settings. If you need help with any aspect of Asks, just check the %1$shelp docs%2$s."}],button:{type:"dismiss"},prev:"start"},"harassment-someoneelse-uws":{title:"Harassment",description:t,form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"harassment"},"violentthreats-start":{title:"Violent content or threat",description:i,tagline:"What are you reporting?",options:[{name:"Imagery of gore, mutilation, or bestiality",to:"gore"},{name:"Content that promotes, encourages, or incites acts of terrorism",to:"terrorism"},{name:"A specific threat directed at an individual or content that glorifies violence/the perpetrators of violence",to:"violentthreats-form"},{name:"Content for the purpose of promoting or inciting violence or hatred against an individual or group on the basis of race, ethnic or national origin, religion, gender, gender identity, age, veteran status, sexual orientation, disability, or disease",to:"hatespeech"}],prev:"start"},"violentthreats-form":{title:"Violent content or threat",description:i,form:[{groupType:"permalink-hint"},{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]}
1,{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"terrorism-start"},privacy:{title:"Privacy violation",description:n,tagline:"Is it your privacy that's being violated?",options:[{name:"Yes",to:"privacy-self"},{name:"No",to:"privacy-someoneelse"}],prev:"start"},"privacy-someoneelse":{title:"Privacy violation",description:n,tagline:"What kind of content are you reporting on behalf of someone else?",options:[{name:"Their name",to:"privacy-self-name"},{name:"Their IP address",to:"privacy-self-ip"},{name:"Their personal contact information",to:"privacy-someoneelse-form"},{name:"Unwanted sexualization",to:"harassment-someoneelse-uws"},{name:"Their explicit private images",to:"privacy-someoneelse-form"}],prev:"privacy"},"privacy-self":{title:"Privacy violation",description:n,tagline:"What kind of content are you reporting",options:[{name:"My name",to:"privacy-self-name"},{name:"My IP address",to:"privacy-self-ip"},{name:"Unwanted sexualization",to:"harassment-self-blog"},{name:"My personal contact information",to:"privacy-self-form"},{name:"My explicit private images",to:"privacy-self-image"},{name:"My private messages without consent",to:"privacy-self-messages"}],prev:"privacy"},"privacy-self-name":{title:"Privacy violation",description:n,tagline:"What kind of content are you reporting",message:[{type:"highlight",text:"Name"},{type:"text",text:"Unfortunately, your name isn't considered private information, and posting it isn't a violation of either the law or of our User Guidelines. If you're uncomfortable with the post, try to communicate with the person who posted it and make your feelings on it known."}],button:{type:"dismiss"},prev:"privacy-self"},"privacy-self-ip":{title:"Privacy violation",description:n,tagline:"What kind of content are you reporting",message:[{type:"highlight",text:"IP address"},{type:"text",text:"Unfortunately, your IP address isn't considered private information, and posting it isn't a violation of either the law or of our User Guidelines. If you're uncomfortable with the post, try to communicate with the person who posted it and make your feelings on it known."}],button:{type:"dismiss"},prev:"privacy-self"},"privacy-self-form":{title:"Privacy violation",description:n,form:[{groupType:"permalink-hint"},{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"privacy-self"},"privacy-self-messages":{title:"Privacy violation",description:n,form:[{groupType:"permalink-hint"},{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"privacy-self"},"privacy-someoneelse-form":{title:"Privacy violation",description:n,form:[{groupType:"permalink-hint"},{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"privacy-someoneelse"},"privacy-self-image":{title:"Privacy violation",description:n,form:[{groupType:"permalink-hint"},{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"privacy-self"},"minors-start":{title:"Harm to minors",description:s,options:[{name:"Is the content you are reporting suspected child sexual abuse material?",to:"minors-csai"},{name:"Is the content you are reporting an illustration or other depiction of child sexual abuse that does not feature a real person?",to:"minors-illusticim"},{name:"Is the content you are reporting harassment of a minor?",to:"harassment"}],prev:"start"},"minors-csai":{title:"Harm to minors",description:s,form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g}]}
1,{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"start"},"minors-illusticim":{title:"Harm to minors",description:s,form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"start"},"child-exploitation":{title:"Child exploitation",description:"Use this section to report content involving the sexual exploitation of minors (individuals under 18). If you believe someone is in immediate danger, contact local emergency services.",tagline:"What are you reporting?",options:[{name:"Report sexual content involving a real child",to:"minors-real-child"},{name:"Report a sexualized depiction of a child (no real children involved)",to:"minors-fictional"},{name:"Report adult sexual content shared by a real child (no children depicted)",to:"minors-adult-shared-by-minor"},{name:"I'm not sure if this content involves a real child",to:"minors-unsure"}],prev:"start"},"minors-real-child":{title:"Child exploitation",description:"Use this option to report content involving a real minor. This includes visual content (images/videos/GIFs) or written content (posts, stories, chats, tags, captions).",tagline:"What type of content are you reporting?",options:[{name:"Report visual content (images, videos, GIFs)",to:"minors-real-child-visual"},{name:"Written content (posts, stories, chats, tags, captions)",to:"minors-real-child-written"}],prev:"child-exploitation"},"minors-real-child-visual":{title:"Child exploitation",description:"Use this option to report images, videos, or GIFs involving a real minor.",tagline:"How would you describe the content?",options:[{name:"Report graphic sexual content involving a real child",to:"minors-csam-visual"},{name:"Report sexually suggestive or inappropriate content involving a real child",to:"minors-suggestive-visual"}],prev:"minors-real-child"},"minors-csam-visual":{title:"Child exploitation",description:"Report graphic sexual content involving a real child.",form:f,button:{type:"submit"},prev:"minors-real-child-visual"},"minors-suggestive-visual":{title:"Child exploitation",description:"Report sexually suggestive or otherwise inappropriate content involving a real child.",form:f,button:{type:"submit"},prev:"minors-real-child-visual"},"minors-real-child-written":{title:"Child exploitation",description:"Report written content involving the sexual exploitation of a real child. This includes posts, stories, chats, tags, and captions.",form:f,button:{type:"submit"},prev:"minors-real-child"},"minors-fictional":{title:"Child exploitation",description:"Use this option to report sexualized depictions where no real children are involved (for example, drawn, animated, fictional, or AI-generated depictions). If you believe a real child may be involved, please go back and choose a different option.",tagline:"How would you describe the content?",options:[{name:"Graphic sexual content (no real child involved)",to:"minors-fictional-graphic"},{name:"Sexually suggestive content (sexualizes children without direct sexual acts)",to:"minors-fictional-suggestive"}],prev:"child-exploitation"},"minors-fictional-graphic":{title:"Child exploitation",description:"Report graphic sexual content that depicts a drawn, animated, or AI-generated child engaged in a sex act or similar behavior.",form:f,button:{type:"submit"},prev:"minors-fictional"},"minors-fictional-suggestive":{title:"Child exploitation",description:"Report sexually suggestive content that sexualizes children without depicting direct sexual acts.",form:f,button:{type:"submit"},prev:"minors-fictional"},"minors-adult-shared-by-minor":{title:"Child exploitation",description:"Use this option to report adult sexual content that appears to be posted by a real child, even if no children are depicted.",form:f,button:{type:"submit"},prev:"child-exploitation"},"minors-unsure":{title:"Child exploitation",description:"Use this option if you're unsure whether the person shown or described 
1is under 18.",form:f,button:{type:"submit"},prev:"child-exploitation"},"selfharm-start":{title:"Promotion or glorification of self-harm",description:o,tagline:"What kind of self harm are you reporting?",options:[{name:"Disordered Eating, Eating Disorders",to:"selfharm-disordered-eating"},{name:"Self Injury",to:"selfharm-self-injury"},{name:"Suicide",to:"selfharm-suicide"}],prev:"start"},"selfharm-suicide":{title:"Suicide",description:o,tagline:"Is the user threatening suicide and in imminent danger?",options:[{name:"Yes",to:"selfharm-form-urgent"},{name:"No",to:"selfharm-form"}],prev:"start"},"selfharm-disordered-eating":{title:"Disordered Eating",description:o,tagline:"What kind of eating disorder content are you reporting?",options:[{name:"Bulimia, Calorie Restriction, Anorexia content",to:"selfharm-form"},{name:"Encouraging Extreme Overeating or Feederism",to:"selfharm-form"}],prev:"start"},"selfharm-self-injury":{title:"Self Injury",description:o,tagline:"What kind of self injury content are you reporting?",options:[{name:"Self Injury, Cutting, Self Mutilation",to:"selfharm-form"},{name:"Hard Drug Use",to:"selfharm-form"}]},"selfharm-form":{title:"Promotion or glorification of self-harm",description:o,tagline:"Self harm, person is not in imminent danger",form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"selfharm"},"selfharm-form-urgent":{title:"Promotion or glorification of self-harm",description:o,tagline:"Is this user threatening suicide? - Yes",message:[{type:"text",text:"We will review the information and may contact the blogger or the appropriate authorities to follow up. Please rest assured that these reports are kept confidential. In the meantime, we recommend that you encourage the blogger to contact a suicide prevention hotline. Support from a friend can be instrumental in getting a person the help that he or she needs."}],form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g}]},{groupLabel:"Describe, as best you can, why you think this user is in danger",fields:[{type:"textarea",name:"description",placeholder:"Short explanation"}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"selfharm"},copyright:{title:"Copyright infringement",description:[{type:"text",text:"Tumblr responds to notices of alleged copyright infringement as per our %1$sTerms of Service%2$s and the Digital Millennium Copyright Act. Please note that we require a valid and complete DMCA notice from the copyright holder or authorized representative before removing content.",link:""}],tagline:"Are you making a copyright claim or reporting an attribution issue?",message:[{type:"text",text:"If you are the copyright owner, you'll need to file a request under the Digital Millennium Copyright Act (DMCA). Don't worry, we've got a form for that."},{type:"link",text:"File a DMCA request",href:"/dmca"}],button:{type:"dismiss"},prev:"copyright"},"reporting-spam":{title:"Report spam and/or bot",description:[{type:"text",text:"Seeing something annoying? %1$sLearn more%2$s about how you can report spam.",link:""}],form:[{groupType:"permalink-hint"},{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"start"},trademark:{title:"Trademark infringement",description:[{type:"text",text:r,link:""}],tagline:"Are you the trademark holder or an authorized representative?",options:[{name:"Yes",to:"trademark-holder"},{name:"No",to:"trademark-notholder"}],prev:"misuse"},"trademark-notholder":{title:"Trademark infringement",description:[{type:"text",text:r,link:""}],tagline:"Are you the trademark holder or an authorized representative?",message:[{type:"text",text:"Thanks for bringing this to our attention, but we need to hear directly from the trademark holder or their authorized representative. Get in contact with them if you can, and refer them to our %1$sabuse form%2$s.",link:"/abuse/trademark"}],button:{type:"dismiss"},prev:"trademark"},"trademark-holder":{title:"Trademark infringement",description:[{type:"text",text:r,link:""}],form:[{groupLabel:"Your information",fields:[{type:"input-name",name:"name"},{type:"input",name:"company",optional:!0,placeholder:"Your company, if applicable"},{type:"input-email",name:"email"},{type:"input",name:"contactinfo",optional:!0,placeholder:"Other contact info, like your address"}]},{groupLabel:"Trademark information",fields:[{type:"input",name:"trademark",placeholder:"Trademark"},{type:"input",name:"trademark-type",placeholder:"Type of trademark (e.g., word, design, etc)"},{type:"input",name:"trademark-jurisdiction",placeholder:"Jurisdiction"},{type:"input",name:"trademark-regnumber",optional:!0,placeholder:"Registration number (if not granted)"},{type:"input",name:"trademark-serialnumber",optional:!0,placeholder:"Serial number"}]},{groupLabel:"Registration documentation",fields:[{type:"file",name:"trademark-regdocument"},{type:"input-link",name:"urlreporting",placeholder:g}]}
1,{groupLabel:"How is this content infringing your trademark(s)?",fields:[{type:"textarea",name:"description",placeholder:"Short explanation"}]},{groupLabel:"",fields:[{type:"checkbox",name:"consent",text:"I understand that a copy of this notice, including any contact information I provided above, will be forwarded to the blog owner."}]}],button:{type:"submit"},prev:"trademark"},"non-genuine":{title:"Impersonation or Non-Genuine Behavior",description:a,tagline:"Whose identity is being impersonated or confused?",options:[{name:"My own",to:"non-genuine-own-start"},{name:"My company, brand, or organization",to:"trademark"},{name:"Someone else's",to:"non-genuine-else"}],prev:"misuse"},"non-genuine-own-start":{title:"Impersonation or Non-Genuine Behavior",description:a,tagline:"Is your privacy being violated (e.g. explicit private photos or personal contact information)?",options:[{name:"Yes",to:"privacy-self"},{name:"No",to:"non-genuine-own"}],prev:"non-genuine"},"non-genuine-own":{title:"Impersonation or Non-Genuine Behavior",description:a,form:[{groupType:"permalink-hint"},{groupLabel:"Some information about you",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]},{groupLabel:"Where confusion or impersonation takes place",fields:[{type:"input-link",name:"urlreporting",placeholder:"URL with an example of the impersonation",is_tumblr_url:!0}]},{groupLabel:d,fields:[{type:"textarea",name:"explanation",placeholder:p}]}],button:{type:"submit"},prev:"non-genuine"},"non-genuine-else":{title:"Confusion or impersonation",description:a,tagline:"Whose identity is being impersonated or confused?",message:[{type:"highlight",text:"Someone else's"},{type:"text",text:"We appreciate your bringing this to our attention. In these cases, we need to hear directly from the person being impersonated by this blog. Get in contact with them if you can, and refer them to our %1$sabuse form%2$s.",link:"/abuse/non-genuine"}],button:{type:"dismiss"},prev:"non-genuine"},"non-genuine-company-notauthorized":{title:"Confusion or impersonation",description:a,tagline:"Are you an authorized representative for the company, brand, or organization being impersonated?",message:[{type:"highlight",text:"No"},{type:"text",text:"We appreciate your bringing this to our attention. In these cases, we need to hear directly from an authorized representative for the company, brand or organization being impersonated by this blog. Get in contact with them if you can, and refer them to our %1$sabuse form%2$s.",link:"/abuse/non-genuine"}],button:{type:"dismiss"},prev:"non-genuine-company"},"non-genuine-company-authorized":{title:"Confusion or impersonation",description:a,tagline:"Are you reporting an impersonation/confusion issue or a trademark violation?",options:[{name:"Impersonation/confusion",to:"non-genuine-company-authorized-impersonation"},{name:"Trademark violation",to:"trademark"}],prev:"non-genuine-company"},"non-genuine-company-authorized-impersonation":{title:"Confusion or impersonation",description:a,form:[{groupLabel:"Some information about you",fields:[{type:"input-name",name:"name"},{type:"input-email",name:"email"}]},{groupLabel:"Information about company",fields:[{type:"input",name:"impersonated-company",placeholder:"Company/brand/organization"},{type:"input",name:"affiliation",placeholder:"Your affiliation"}]},{groupLabel:"Examples of the impersonation or confusion",fields:[{type:"input-link",name:"urlreporting"},{type:"textarea",name:"explanation",placeholder:"Explain how these examples are impersonating or causing confusion with your brand"}]}],button:{type:"submit"},prev:"non-genuine-company-authorized"},"sexually-explicit-material":{title:"Sexually explicit material",description:[{type:"text",text:"We do not allow visual depictions of sexually explicit acts. If you see this content on Tumblr, please provide us with the details below.<br><br>We do allow nudity and other kinds of content intended for adult audiences. This type of content should have a Content Label applied. Please %1$sclick here%2$s to learn more.",link:""}],form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g}]}
1,{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"hateful"},"dsa-reporter-appeal":{title:"Appealing Reports Decisions",description:[{type:"text",text:"If you previously reported to us that a user or piece of content violates our policies, and you believe the outcome from that report (our decision) was incorrect, you can appeal our moderation decision here. Please only use this form if we have already responded to your report — we won’t be able to reply to new reports sent via this form. <br><br>In order to re-evaluate your report (and yes, a human being will take a look!), we’ll need you to provide additional context about why you believe the user or content you reported violates Tumblr’s policies. You can review Tumblr’s User Guidelines %1$shere%2$s. <br><br>In order to connect your submission here to your original report, please provide the email that you used to submit your report.",link:""}],form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:"Link to the Content you previously reported to us"}]},{groupLabel:"Describe, what you are reporting",fields:[{type:"textarea",name:"description",placeholder:"Description of why you believe our earlier decision was wrong. This description must include new/additional information above and beyond what was originally reported."}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email",placeholder:"Email associated with your original report"}]}],button:{type:"submit"},prev:"start"},gore:{title:"Gore, mutilation, or bestiality",description:"Don't post gore just to be shocking. Don't showcase the mutilation or torture of human beings, animals, or their remains.",form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"hateful"},hatespeech:{title:"Hate speech",description:"Don't encourage violence or hatred. Don't post content for the purpose of promoting or inciting the hatred of, or dehumanizing, individuals or groups based on race, ethnic or national origin, religion, gender, gender identity, age, veteran status, sexual orientation, disability, or disease.",form:[{groupType:"permalink-hint"},{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:"Specific post/image/comment URL you're reporting",is_tumblr_url:!0}]},{groupLabel:"Describe, what you are reporting",fields:[{type:"textarea",name:"description",placeholder:"A clear description of the exact text, content, or behaviors you are reporting"}]},{groupLabel:"Describe, as best you can, how it violates Tumblr's Hate Speech Policy",fields:[{type:"textarea",name:"explanation",placeholder:"An explanation as to how this content is in violation of our Hate Speech policy"}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"hatespeech-start"},"terrorism-start":{title:"Suspected terrorism",description:l,tagline:"What are you reporting?",options:[{name:"Imagery of gore, mutilation, or bestiality",to:"gore"},{name:"Content that promotes, encourages, or incites acts of terrorism",to:"terrorism"},{name:"A specific threat directed at an individual or content that glorifies violence/the perpetrators of violence",to:"violentthreats-form"},{name:"Content for the purpose of promoting or inciting the hatred of, or dehumanizing, individuals or groups based on race, ethnic or national origin, religion, gender, gender identity, age, veteran status, sexual orientation, disability, or disease",to:"hatespeech"}],prev:"start"},terrorism:{title:"Suspected terrorism",description:l,form:[{groupType:"permalink-hint"},{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]}
1,{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"terrorism-start"},"illegal-eu":{title:"Report illegal content in the EU",description:"Tumblr respects the Digital Services Act (DSA) and the rights it affords those in the EU to report content published in violation of EU law.\nThis form is only for use by individuals in the European Union to report content they believe is illegal in the EU.\n<br><br>We’ve designed this form to help you submit a notice that’s precise and sufficiently substantiated, as required by the DSA. Please fill it out completely to the best of your ability. If you submit a notice through this form that isn’t reporting illegal content, doesn’t include all the necessary elements, or isn’t specific enough for us to evaluate, we may not be able to process and act on it.\n<br><br>We can only review notices submitted using this form that pertain to illegal content in the EU and that contain all of the required information. To report other violations of our guidelines, please use our Abuse Form at: Tumblr.com/abuse.",form:[{groupType:"permalink-hint"},{groupLabel:"Content you're reporting",required:!0,fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:"What category of illegal content are you reporting?",required:!0,fields:[{type:"select",name:"illegal-eu-category",placeholder:"Select a category",options:["Hate Speech","Terrorism","Harm to Minors","Promotion of Self-Harm","Sexually Explicit Material","Violent Content, Threats, Gore & Mutilation","Non-Genuine Social Gestures/Schemes","Deceptive Links","Harassment","Privacy Violation","Election Interference","Human Trafficking and Prostitution","Spam","Other"]}]},{groupLabel:"In which EU country do you believe this content is illegal?",required:!0,fields:[{type:"select",name:"country",placeholder:"Select country",options:["EU","Austria","Belgium","Bulgaria","Cyprus","Czech Republic","Germany","Denmark","Estonia","Spain","Finland","France","Greece","Croatia","Hungary","Ireland","Italy","Lithuania","Luxembourg","Latvia","Malta","Netherlands","Poland","Portugal","Romania","Sweden","Slovenia","Slovakia"]}]},{groupLabel:"Why do you believe this content is illegal?",required:!0,fields:[{type:"textarea",name:"description",placeholder:"Tell us which EU law or regulation you think may apply. If you're not sure, the more specific your information, the better we can review and respond to your report. Include details such as usernames, tags, or links to the content you are reporting."}]},{groupLabel:"Document Upload",fields:[{type:"file",name:"illegal-eu-attachment",optional:!0}]},{groupLabel:"A little about yourself",groupDescription:"If you provide your email, we will acknowledge receipt of your report and notify you of our decision, as required under EU law.",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",optional:!0,name:"email"}]},{groupLabel:"",fields:[{type:"checkbox",name:"acknowledgement",text:"I believe that the information and allegations in my report are accurate and complete."}]}],button:{type:"submit"},prev:"start"},ncii:{title:"Report non-consensual intimate imagery",description:"Use this form to submit a takedown notice for a non-consensual intimate visual depiction or intimate image abuse (e.g. U.S. federal Take It Down Act, UK Online Safety Act). This form is only for use by the depicted identifiable individual or their authorized representative to report authentic or synthetic (e.g. AI-generated or altered) intimate images.\n<br><br>To process your notice we require: your typed electronic signature, the URL of the depiction, a good-faith statement that the depiction is not consensual, and a valid contact email. Anonymous reports are not accepted under the statute.\n<br><br>If your report does not include all of the required information, or is not for non-consensual intimate imagery, we may not be able to process it. To report other violations of our guidelines, please use our Abuse Form at: Tumblr.com/abuse.",form:[{groupType:"permalink-hint"},{groupLabel:"URL of the depiction",required:!0,fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0},{type:"checkbox",name:"ncii-synthetic",optional:!0,text:"Please check this box if the reported image is synthetic (e.g. AI-generated, AI-altered, deepfake)."}]},{groupLabel:"Additional details to help us locate the depiction",groupDescription:"For example, post identifiers, timestamps, or any context that helps us positively identify the depiction.",fields:[{type:"textarea",
1name:"ncii-depiction-details",optional:!0,placeholder:"Optional — additional locating context."}]},{groupLabel:"Name of the depicted identifiable individual",required:!0,fields:[{type:"input",name:"ncii-depicted-name",placeholder:"Full name of the person depicted"}]},{groupLabel:"You are reporting as",required:!0,fields:[{type:"select",name:"ncii-reporter-capacity",placeholder:"Select an option",options:["I am the identifiable individual depicted","I am a parent or legal guardian of the identifiable individual depicted","I am an authorized representative of the identifiable individual depicted"]}]},{groupLabel:"Basis of authority",groupDescription:"Briefly describe your relationship to the depicted individual and the basis of your authority to report on their behalf. Examples of authority include power of attorney or a signed consent form. We may contact you afterwards to request documentation proving that you are an authorized representative.",dependsOn:{field:"ncii-reporter-capacity",values:["I am a parent or legal guardian of the identifiable individual depicted","I am an authorized representative of the identifiable individual depicted"]},fields:[{type:"textarea",name:"ncii-authority-basis",optional:!0,placeholder:"Describe your relationship and basis of authority."}]},{groupLabel:"Good-faith statement",required:!0,fields:[{type:"checkbox",name:"ncii-good-faith",text:"I have a good-faith belief that the intimate visual depiction identified in this request is not consensual, including that it was published without the consent of the depicted identifiable individual."},{type:"checkbox",name:"ncii-public-concern",text:"I have a good-faith belief that the intimate visual depiction identified in this request is not a matter of public concern and is not being shared for the purposes of journalism, commentary, satire, or political speech."},{type:"checkbox",name:"ncii-accuracy",text:"I believe that the information in this report is accurate and complete."}]},{groupLabel:"Electronic signature",groupDescription:"Type your full legal name. This serves as your electronic signature under the Take It Down Act.",required:!0,fields:[{type:"input",name:"ncii-signature",placeholder:"Full legal name"}]},{groupLabel:"Your contact information",groupDescription:"A valid email address is required. Anonymous reports cannot be processed under the Take It Down Act.",required:!0,fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"start"},"illegal-br":{title:"Report violating content under Brazil ECA",description:"Tumblr respects the Brazil Digital ECA (Estatuto Digital da Criança e do Adolescente) and the rights it affords to children and adolescents in Brazil. This form is only for use by individuals in Brazil who are: the victim, their representatives (such as a parent or guardian), the Public Prosecutor's Office, or a representative from an accredited and/or registered organization with a statutory purpose of the defense of children's and adolescent's rights.\n<br><br>Please be aware that the ECA does not permit anonymous reporting.\n<br><br>We've designed this form to help you submit a notice that is precise and sufficiently substantiated, as required by the ECA. Please complete all fields to the best of your ability. If your report does not contain the necessary elements, lacks sufficient detail, or you are not an eligible reporting party under Article 29 of the ECA, we may be unable to process or act on it.\n<br><br>We can only review notices submitted using this form that pertain to violating content in the ECA, sent by the appropriate parties, and that contain all of the required information. To report other violations of our guidelines, please use our Abuse Form at: Tumblr.com/abuse.",form:[{groupType:"permalink-hint"},{groupLabel:"Content you're reporting",required:!0,fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:"What category of violating content are you reporting?",required:!0,fields:[{type:"select",name:"illegal-br-category",placeholder:"Select a category",options:["Child exploitation","Harassment","Violent content or threat","Suicide, self injury, or eating disorder concern","Sale of drugs or prohibited materials","Sexually explicit material","Predatory, unfair or deceptive advertising"]}]},{groupLabel:"To submit this report, you must be one of the following. Please select the option that applies to you as the reporting party:",required:!0,fields:[{type:"select",name:"illegal-br-reporting-party",placeholder:"Select reporting party",options:["The affected victim","A representative of a victim (parent, legal guardian, or legal representative)","An official from the Brazil Public Prosecutor's Office","A representative from an accredited and registered organization with a statutory purpose of the defense of children's and adolescent's rights"]}]},{groupLabel:"Organization / authority to report",required:!0,dependsOn:{field:"illegal-br-reporting-party",values:["An official from the Brazil Public Prosecutor's Office","A representative from an accredited and registered organization with a statutory purpose of the defense of children's and adolescent's rights"]}
1,fields:[{type:"textarea",name:"illegal-br-organization",placeholder:"Please provide information regarding the nature of your relationship to the victim, your organization's official name, address, and contact information if this report is from the Brazil Public Prosecutor's Office, or you are a representative from an accredited and registered organization with a statutory purpose of the defense of children's and adolescent's rights."}]},{groupLabel:"Why do you believe this content is violating?",required:!0,fields:[{type:"textarea",name:"description",placeholder:"Tell us why you believe this content is violating. The more information you provide, the better we can review and respond to your report. Please include details such as usernames, tags, or links to the content you are reporting."}]},{groupLabel:"Supporting Document Upload",fields:[{type:"file",name:"illegal-br-attachment",optional:!0}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",name:"name"},{type:"input-email",name:"email"}]},{groupLabel:"",fields:[{type:"checkbox",name:"eca-accuracy",text:"Under penalty of nullity, I confirm that the information and allegations in my report are accurate and complete."}]},{groupLabel:"",fields:[{type:"checkbox",name:"eca-good-faith",text:"I have a good faith belief that the information and allegations contained in this report are accurate and complete."}]}],button:{type:"submit"},prev:"start"},edr:{title:"EMERGENCY DISCLOSURE REQUEST FORM",description:[{text:'Please provide completed responses to the questions on this form to assist Tumblr, Inc. ("Tumblr") in determining whether to exercise its discretion to disclose information to respond to an emergency situation.'},{text:"For more information about our Emergency Disclosure policies, please refer to %1$sTumblr's Law Enforcement Guidelines%2$s.",link:""},{text:"Please email %[email protected]%2$s during business hours, if you have any questions about this form.",link:"mailto:[email protected]"}],customSuccessMessage:[{text:"We have received your emergency disclosure request and a member of our team will be in touch shortly."},{text:"For more information on Tumblr's law enforcement processes, please review our %1$sLaw Enforcement Guidelines%2$s.",link:""}],form:[{groupType:"vertical-layout",groupLabel:"Information in Tumblr's possession that you are seeking to obtain on an emergency basis",fields:[{type:"textarea",name:"description"}]},{groupType:"vertical-layout",groupLabel:"Tumblr username/URL (e.g. staff.tumblr.com) of the account(s) containing information necessary to prevent the emergency",fields:[{type:"textarea",name:"bloginfo"}]},{groupType:"vertical-layout",groupLabel:"Identity of the individual in danger or serious physical injury",fields:[{type:"textarea",name:"identity"}]},{groupType:"vertical-layout",groupLabel:"Describe the nature of the emergency involving danger of death or serious physical injury.",fields:[{type:"textarea",name:"nature"}]},{groupType:"vertical-layout",groupLabel:"Describe the imminence of the threatened death or serious physical injury. If possible, provide information that suggests that there is a specific deadline before which it is necessary to receive the requested information.",fields:[{type:"textarea",name:"threat"}]},{groupType:"vertical-layout",groupLabel:"Explain/describe how the specific information requested will assist in averting the threatened death or serious physical injury.",fields:[{type:"textarea",name:"explanation"}]},{groupType:"vertical-layout",groupLabel:"Links to any specific posts containing relevant information",fields:[{type:"textarea",name:"links"}]},{groupType:"vertical-layout",groupLabel:"Describe and attach any other relevant details or context regarding the particular circumstances. For example, if a Tumblr post made by the user is the basis for the emergency, please include the post permalink in this form and explain its relevance in the area below.",fields:[{type:"textarea",name:"context"}]},{groupType:"vertical-layout",groupLabel:"I declare that the foregoing is true and correct."},{groupLabel:"Digital signature of law enforcement officer",fields:[{type:"input-name",name:"signature"}]},{groupLabel:"Date",fields:[{type:"input",name:"date"}]},{groupLabel:"Printed name of law enforcement officer",fields:[{type:"input-name",name:"name"}]},{groupLabel:"Phone number",fields:[{type:"input",name:"phone"}]},{groupLabel:"Email address",fields:[{type:"input-email",name:"email"}]}],button:{type:"submit"}},lpr:{title:"Legal Process/Request Form",description:[{text:'Please attach your legal process and complete the required fields below to submit your request to Tumblr, Inc. ("Tumblr"). If this is an emergency, please use the form located at %1$shttps://www.tumblr.com/abuse/edr%2$s.',link:""},{text:"For more information about our policies regarding the disclosure of user data, including our User Notice Policy, please review %1$sTumblr's Law Enforcement Guidelines%2$s.",link:""},{text:"Any questions should be directed to %[email protected]%2$s.",link:"mailto:[email protected]"}],customSuccessMessage:[{text:"We have received your Legal Process Request and a member of our team will be in touch shortly."},{text:"For more information on Tumblr's law enforcement processes, please review our %1$sLaw Enforcement Guidelines%2$s.",link:""}],form:[{groupType:"vertical-layout",groupLabelBold:"Complete the following required fields:"},{groupType:"vertical-layout",groupLabel:"Upload Legal Process",fields:[{type:"file",name:"lpr-legalprocessdocument",accept:"image/*,application/pdf",multiple_files:!0}]},{groupType:"vertical-layout",fields:[{type:"leinput-name",name:"name",placeholder:"Officer name"},{type:"input-email",name:"email",placeholder:"Officer email"},{type:"select",name:"legal-process-type",placeholder:"Type of Legal Process",options:["Preservation","Subpoena","Search Warrant","Court Order","Other"]},{type:"select",name:"country",placeholder:"Country",options:["Afghanistan","Albania","Algeria","Andorra","Angola","Antigua and Barbuda","Argentina","Armenia","Aruba","Australia","Austria","Azerbaijan","Bahamas","Bahrain","Bangladesh","Barbados","Belarus","Belgium","Belize","Benin","Bhutan","Bolivia","Bosnia and Herzegovina","Botswana","Brazil","Brunei","Bulgaria","Burkina Faso","Burma","Burundi","Cabo Verde","Cambodia","Cameroon","Canada","Central African Republic","Chad","Chile","China","Colombia","Comoros","Congo","Costa Rica","Cote d'Ivoire","Croatia","Cuba","Curacao","Cyprus","Czechia","Czech Republic","Denmark","Djibouti","Dominica","Dominican Republic","Ecuador","Egypt","El Salvador","Equatorial Guinea","Eritrea","Estonia","Ethiopia","Fiji","Finland","France","Gabon","Gambia","Georgia","Germany","Ghana","Greece","Grenada","Guatemala","Guinea","Guinea-Bissau","Guyana","Haiti","Honduras","Hong Kong","Hungary","Iceland","India","Indonesia","Iran","Iraq","Ireland","Israel","Italy","Jamaica","Japan","Jordan","Kazakhstan","Kenya","Kiribati","Kosovo","Kuwait","Kyrgyzstan","Laos","Latvia","Lebanon","Lesotho","Liberia","Libya","Liechtenstein","Lithuania","Luxembourg","Macau","Macedonia","Madagascar","Malawi","Malaysia","Maldives","Mali","Malta","Marshall Islands","Mauritania","Mauritius","Mexico","Micronesia","Moldova","Monaco","Mongolia","Montenegro","Morocco","Mozambique","Namibia","Nauru","Nepal","Netherlands","New Zealand","Nicaragua","Niger","Nigeria","North Korea","Norway","Oman","Pakistan","Palau","Palestine","Panama","Papua New Guinea","Paraguay","Peru","Philippines","Poland","Portugal","Qatar","Romania","Russia","Rwanda","Samoa","Saudi Arabia","Senegal","Serbia","Seychelles","Sierra Leone","Singapore","Slovakia","Slovenia","Solomon Islands","Somalia","South Africa","South Korea","South Sudan","Spain","Sri Lanka","Sudan","Suriname","Swaziland","Sweden","Switzerland","Syria","Taiwan","Tajikistan","Tanzania","Thailand","Timor-Leste","Togo","Tonga","Trinidad and Tobago","Tunisia","Turkey","Turkmenistan","Tuvalu","Uganda","Ukraine","United Arab Emirates","United Kingdom","United States","Uruguay","Uzbekistan","Vanuatu","Venezuela","Vietnam","Yemen","Zambia","Zimbabwe","Saint Martin","Réunion","Mayotte","Gibraltar","American Samoa","Antarctica","Anguilla","Bermuda","British Indian Ocean Territory","British Virgin Islands","Cayman Islands","Cape Verde","Christmas Island","Cocos Islands","Cook Islands","Democratic Republic of the Congo","East Timor","Falkland Islands","Faroe Islands","French Polynesia","Greenland","Guam","Guernsey","Isle of Man","Ivory Coast","Jersey","French Guiana","Guadeloupe","Martinique","Montserrat","Myanmar","Niue","Northern Mariana Islands","Pitcairn","Saint Helena","Saint Barthelemy","Saint Kitts and Nevis","Saint Lucia","Saint Pierre and Miquelon","Saint Vincent and the Grenadines","S
1ao Tome and Principe","San Marino","Sint Maarten","Puerto Rico","Western Sahara","Wallis and Futuna","Vatican","U.S. Virgin Islands","Turks and Caicos Islands","Åland Islands","South Georgia and the South Sandwich Islands","United States Minor Outlying Islands","Virgin Islands (British)","Virgin Islands (U.S.)","Indian Ocean Area","Pacific Ocean Area","Atlantic Ocean Area"]},{type:"select",name:"state",placeholder:"State",options:["N/A","Alabama","Alaska","Arizona","Arkansas","California","Colorado","Connecticut","Delaware","Florida","Georgia","Hawaii","Idaho","Illinois","Indiana","Iowa","Kansas","Kentucky","Louisiana","Maine","Maryland","Massachusetts","Michigan","Minnesota","Mississippi","Missouri","Montana","Nebraska","Nevada","New Hampshire","New Jersey","New Mexico","New York","North Carolina","North Dakota","Ohio","Oklahoma","Oregon","Pennsylvania","Rhode Island","South Carolina","South Dakota","Tennessee","Texas","Utah","Vermont","Virginia","Washington","West Virginia","Wisconsin","Wyoming"]}]},{groupType:"vertical-layout",groupLabel:"Date of Legal Process",fields:[{type:"input-date",name:"legal-process-date",placeholder:"Date of Legal Process"}]},{groupType:"vertical-layout",fields:[{type:"letextarea",name:"lpr-identifiers",placeholder:"Identifiers listed in legal process"}]},{groupLabel:"",groupType:"vertical-layout",fields:[{type:"checkbox",name:"acknowledgement",text:"I acknowledge and understand Tumblr’s policy on user notification as outlined in the %1$sTumblr Legal Guidelines%2$s.",link:""}]}],button:{type:"submit"}},"election-interference":{title:"Election Interference",description:[{type:"text",text:h,link:""}],tagline:"Please select one of the following for your report:",options:[{name:"Fake Polling Sites (Websites, links, or content that impersonate official voting locations or provide fraudulent ways to vote).",to:"election-fake-polling-sites"},{name:"Voter Confusion (Intentionally providing false information about how to register to vote, someone's right to vote, or the time, date, place, or method of voting in an election).",to:"election-voter-confusion"},{name:"Voter Intimidation (Content that attempts to threaten, intimidate, or coerce specific individuals to vote/refrain from voting, or to vote a certain way).",to:"election-voter-intimidation"},{name:"Other",to:"election-other"}],prev:"start"},"election-fake-polling-sites":{title:"Election Interference",description:"Fake Polling Sites: Websites, links, or content that impersonate official voting locations or provide fraudulent ways to vote (i.e. a site that purports to allow online voting in a state when online voting is not an accepted method of voting in that state).",form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:"Describe, as best you can, how it violates Tumblr's User Guidelines",fields:[{type:"textarea",name:"description",placeholder:"Clearly explain how the content violates the selected option above. Provide specific evidence, quotes, or examples from the content. We will not be able to act on reports submitted through this form that do not clearly explain how they meet the above noted criteria."}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"election-interference"},"election-voter-confusion":{title:"Election Interference",description:"Voter Confusion: Intentionally providing false information about how to register to vote, someone's right to vote, or the time, date, place, or method of voting in an election.",form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:"Describe, as best you can, how it violates Tumblr's User Guidelines",fields:[{type:"textarea",name:"description",placeholder:"Clearly explain how the content violates the selected option above. Provide specific evidence, quotes, or examples from the content. We will not be able to act on reports submitted through this form that do not clearly explain how they meet the above noted criteria."}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"election-interference"},"election-voter-intimidation":{title:"Election Interference",description:"Voter Intimidation: Content that attempts to threaten, intimidate, or coerce specific individuals to vote/refrain from voting, or to vote a certain way.",form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:"Describe, as best you can, how it violates Tumblr's User Guidelines",fields:[{type:"textarea",
1name:"description",placeholder:"Clearly explain how the content violates the selected option above. Provide specific evidence, quotes, or examples from the content. We will not be able to act on reports submitted through this form that do not clearly explain how they meet the above noted criteria."}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"election-interference"},"election-other":{title:"Election Interference",description:[{type:"text",text:h,link:""}],form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:"Please describe the type of report you are submitting",fields:[{type:"textarea",name:"reporttype",placeholder:"Before submitting a report, carefully review the types of content that qualify as election interference."}]},{groupLabel:"Describe, as best you can, how it violates Tumblr's User Guidelines",fields:[{type:"textarea",name:"description",placeholder:"Clearly explain how the content violates the selected option above. Provide specific evidence, quotes, or examples from the content. We will not be able to act on reports submitted through this form that do not clearly explain how they meet the above noted criteria."}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"election-interference"},"unlawful-uses-or-content":{title:c,tagline:"What are you reporting?",description:u,options:[{name:"Human trafficking or illegal prostitution",to:"trafficking"},{name:"Sale of drugs or prohibited materials",to:"drug-sale"},{name:"Phishing",to:"phishing"},{name:"Report illegal content in the EU",to:"illegal-eu",visibility:"eu"},{name:"Report non-consensual intimate imagery",to:"ncii",visibility:"ncii"},{name:"Report violating content under Brazil ECA",to:"illegal-br",visibility:"brazil"}],prev:"start"},trafficking:{title:c,tagline:"Human trafficking or illegal prostitution",description:u,form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"unlawful-uses-or-content"},"drug-sale":{title:c,tagline:"Sale of drugs or prohibited materials",description:u,form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g,is_tumblr_url:!0}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"unlawful-uses-or-content"},phishing:{title:c,tagline:"Phishing",description:u,form:[{groupLabel:"Content you're reporting",fields:[{type:"input-link",name:"urlreporting",placeholder:g}]},{groupLabel:d,fields:[{type:"textarea",name:"description",placeholder:p}]},{groupLabel:"A little about yourself",fields:[{type:"input-name",optional:!0,name:"name"},{type:"input-email",name:"email"}]}],button:{type:"submit"},prev:"unlawful-uses-or-content"}};e.exports=m},39153(e,t,i){"use strict";var n=i(55679),s=i(91685),o=i(26024),r=s.extend(o,{elSelector:".vjs-progress-holder",lastPlayPosition:0,currentPlayPosition:0,lastWaitedTime:0,buffering:!1,polling:!1,interval:100,initialize:function(e,t){this.player.on("play",n.bind(this.startPolling,this)),this.player.on("ended",n.bind(this.stopPolling,this)),this.player.on("pause",n.bind(this.stopPolling,this)),this.player.one("dispose",n.bind(this.stopPolling,this))},checkBuffering:function(){this.currentPlayPosition=this.player.currentTime();var e=1/this.interval;if(!this.buffering&&this.currentPlayPosition<this.lastPlayPosition+e&&!this.player.paused()&&(this.lastWaitedTime=n.now(),this.$player.trigger("waiting"),this.buffering=!0),this.buffering&&this.currentPlayPosition>this.lastPlayPosition+e&&!this.player.paused()){var t=n.now()-this.lastWaitedTime;this.$player.trigger("stopwaiting",{timeWaited:t}),this.buffering=!1}this.lastPlayPosition=this.currentPlayPosition},tick:function(){this.polling&&(this.checkBuffering(),n.delay(n.bind(this.tick,this),this.interval))},startPolling:function(e){this.polling||(this.polling=!0,this.tick())},stopPolling:function(e){this.polling=!1}});e.exports=r},39277(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(81515),r=i(71092),a=i(27496),l=i(62822),c=100,u=350,h=r.extend({events:{'change [data-validate-input="dropdown"]':"fieldValidationHandler",'change [data-validate-input="input-date"]':"fieldValidationHandler",'keyup [data-validate-input="name"]':"fieldValidationHandler",'blur [data-validate-input="name"]':"fieldValidationHandler",'keyup [data-validate-input="lename"]':"fieldValidationHandler",'blur [data-validate-input="lename"]':"fieldValidationHandler",'keyup [data-validate-input="email"]':"fieldValidationHandler",'blur [data-validate-input="email"]':"fieldValidationHandler",'keyup [data-validate-input="text"]':"fieldValidationHandler",'blur [data-validate-input="text"]':"fieldValidationHandler",'keyup [data-validate-input="text-abuse-form"]':"fieldValidationHandler",'blur [data-validate-input="text-abuse-form"]':"fieldValidationHandler",'keyup [data-validate-input="text-abuse-form-with-range-and-education"]':"fieldValidationHandler",'focusout [data-validate-input="text-abuse-form-with-range-and-education"]':"fieldValidationHandler",'keyup [data-validate-input="letext-abuse-form"]':"fieldValidationHandler",'blur [data-validate-input="letext-abuse-form"]':"fieldValidationHandler",'keyup [data-validate-input="url"]':"fieldValidationHandler",'blur [data-validate-input="url"]':"fieldValidationHandler",'keyup [data-validate-input="tumblr_url"]':"fieldValidationHandler",'blur [data-validate-input="tumblr_url"]':"fieldValidationHandler",'change [data-validate-input="file"]':"fieldValidationHandler",'change [data-validate-input="checkbox"]':"validateAllFields",'keyup [data-validate-input="blog"]':"fieldValidationHandler",'blur [data-validate-input="blog"]':"fieldValidationHandler"},validationErrorMessages:{name:"Name length has to be within 1 ~ "+20..toString()+" characters",text:"Under 5000 characters, please","text-abuse-form":"Under 350 characters, please","text-abuse-form-with-range":"Text length has to be between "+c.toString()+" and "+u.toString()+" characters, please","text-abuse-form-with-range-and-education":"Reports with more detail help us address the issue faster. Please provide between "+c.toString()+" and "+u.toString()+" characters.",email:"We gotta write you back, though",url:"Invalid URL",tumblr_url:"Invalid Tumblr post/media permalink",blog:"Please enter your blog name or blog URL"},initialize:function(){this.listenTo(a,"drawerform:validation:trigger",this.validateAllFields),this.initializeCharacterCounters()},initializeCharacterCounters:function(){this.$('[data-validate-input="text-abuse-form"], [data-validate-input="text-abuse-form-with-range-and-education"]').each(function(){var e=n(this);this.updateCharacterCounter(e,!1)}.bind(this))},validateAllFields:function(){var e=n("[data-validate-input]:visible"),t=e.length>0;s.each(e,function(e){var i=n(e),s=i.data("validate-input"),o="checkbox"===s?i.prop("checked"):(i.val()||"").trim(),r
1=i.prop("required");if(!this.isFieldValid(o,s,r))return t=!1,!1},this),a.trigger("drawerform:validation",{status:t})},updateDependentGroups:function(e,t){var i=n('[data-depends-on-field="'+e+'"]');i.each(function(){var e=n(this),i=-1!==JSON.parse(e.attr("data-depends-on-values")).indexOf(t);e.toggle(i),e.find("[data-validate-input]").each(function(){var e=n(this);e.prop("required",i),i||(e.removeClass("error"),a.trigger("drawerform:errortag:remove",{field:e}))})}),i.length&&n(".form-container").trigger("scroll")},fieldValidationHandler:function(e){var t=n(e.target),i=t.data("validate-input"),s="checkbox"===i?t.prop("checked"):(t.val()||"").trim(),r=t.prop("required");if("dropdown"===i&&this.updateDependentGroups(t.attr("name"),s),"text-abuse-form"!==i&&"text-abuse-form-with-range-and-education"!==i||this.updateCharacterCounter(t,"focusout"===e.type||"blur"===e.type),"focusout"===e.type){var l=t.val();"string"==typeof l&&l!==l.trim()&&t.val(l.trim())}this.isFieldValid(s,i,r)?(t.hasClass("error")&&t.removeClass("error"),a.trigger("drawerform:errortag:remove",{field:t}),"focusout"!==e.type||"url"!==i&&"tumblr_url"!==i||!s.length||0===s.indexOf("http")||n(e.target).val("http://"+s)):"focusout"===e.type&&(t.addClass("error"),a.trigger("drawerform:errortag:show",{field:t,text:o(this.validationErrorMessages[i])})),this.validateAllFields()},isFieldValid:function(e,t,i){var n;if(i=void 0!==i&&i,"checkbox"===t)return!i||!0===e;if(l.isBlank(e))return!i;switch(t){case"name":n=l.maxLength(e,20);break;case"lename":case"letext-abuse-form":case"file":case"dropdown":case"input-date":case"select":n=!0;break;case"email":n=l.isEmail(e);break;case"text":case"blog":n=l.maxLength(e,5e3);break;case"text-abuse-form":n=l.maxLength(e,u);break;case"text-abuse-form-with-range":case"text-abuse-form-with-range-and-education":n=l.range(e,c,u);break;case"url":n=l.isUrl(e);break;case"tumblr_url":n=l.isReportableTumblrUrl(e)||l.isReportableTumblrUrl(decodeURIComponent(e));break;case"checkbox":n=this.isAtLeastOneChecked()}return n},updateCharacterCounter:function(e,t){var i=e.attr("name"),n=e.val().trim(),s=n.length,o=e.data("validate-input"),r=e.prop("required"),a=e.siblings('.character-counter[data-field-name="'+i+'"]');if(a.length){a.find(".current-count").text(s),a.removeClass("counter-under-min counter-over-max counter-valid");var l=this.isFieldValid(n,o,r);s>u?a.addClass("counter-over-max"):l?a.addClass("counter-valid"):t&&a.addClass("counter-under-min")}},isAtLeastOneChecked:function(){return n('input[type="checkbox"]:checked').length>0}});e.exports=h},39349(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, \'\') }\nwith (obj) {\n__p += \'<a data-open-conversation href="#" class="inbox-row"><div data-subview="statusIndicator"></div> \';\n if (blogIsAdult && isSafeModeEnabled && !isUser) { ;\n__p += \' <canvas class="avatar post-activity-avatar-image post_sub_avatar_image pixelated-avatar needs-drawing hide" data-image-url="\' +\n__e( avatarUrl ) +\n\'" width="36" height="36" alt="\' +\n__e( name ) +\n\'"></canvas> \';\n } else { ;\n__p += \' <img class="avatar" src="\' +\n__e( avatarUrl ) +\n\'"> \';\n } ;\n__p += \' <div class="info-container"><div class="name-container"><h3 class="name">\' +\n__e( name ) +\n\'</h3></div><h4 class="message" data-js-message><span class="text" data-js-message-text>\' +\n((__t = ( message )) == null ? \'\' : __t) +\n\'</span></h4></div></a>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},39366(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<form class=\"blog-search-form\"><div data-subview=\"filters\"></div><i class=\"icon_arrow_thin_left clear-search nav_icon\"></i> ';\n if (!(model.isSafeModeEnabled && model.isAdult)) { ;\n__p += ' <i class=\"icon_search toggle-search nav_icon\"></i> ';\n } ;\n__p += ' <div data-subview=\"input\"></div></form>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},39424(e,t,i){"use strict";var n=i(55679),s=i(44384),o=i(27496),r=i(97030),a=i(8901),l=s.extend({events:{click:"showNotes"},mixins:[r],showNotes:function(e){o.trigger("useraction:click:post:reply",{event:e}),this.model.get("pt")&&o.trigger("useraction:explore_click:reply",{model:this.model,loggingData:this.loggingData({userAction:"reply"})}),a(n.bind(function(e){return new e({pinnedTarget:this.$el.closest(".post_footer").find(".note_link_current"),postModel:this.model}).render()},this))}});e.exports=l},39644(e,t,i){"use strict";var n=i(91685),s=i(55679),o=n.getComponent("DurationDisplay"),r=n.extend(o,{constructor:function(){o.prototype.constructor.apply(this,arguments),this.boundDetectDuration=s.bind(this.detectDuration,this),this.player().on("loadedmetadata",this.boundDetectDuration)},detectDuration:function(){s.isFinite(this.player().duration())||null==this.el_||this.dispose()},dispose:function(){this.player().off("loadedmetadata",this.boundDetectDuration),o.prototype.dispose.apply(this,arguments)}});e.exports=r},39770(e,t,i){"use strict";var n=i(74692),s=i(50283),o=i(10860),r=s.extend({autoAppend:!0,template:o,events:{"click .carousel-button":"onCarouselButtonClick","click .carousel-arrow-right":"goToNextItem","click .carousel-arrow-left":"goToPrevItem"},initialize:function(e){e=e||{},this.photoCount=e.photoCount||0,this.currentItem=0},switchCarouselItem:function(e){this.trigger("switchCarouselItem",e)},goToItem:function(e){e>=0&&e<=this.photoCount-1?(this.$(".carousel-button").removeClass("current"),this.$('.carousel-button[data-carousel-button-index="'+e+'"]').addClass("current"),this.currentItem=e,this.switchCarouselItem(this.currentItem)):e<0?this.trigger("peekLeft"):e>this.photoCount-1&&this.trigger("peekRight")},goToNextItem:function(e){this.goToItem(this.currentItem+1)},goToPrevItem:function(e){this.goToItem(this.currentItem-1)},onCarouselButtonClick:function(e){var t=n(e.target).data("carousel-button-index");this.goToItem(t)},render:function(){return this.$el.html(this.template({photoCount:this.photoCount})),this}});e.exports=r},39779(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(27496),r=i(44384),a=i(78421),l=i(97030),c=r.extend({events:{click:"displayShownPhotoInLightbox",mouseenter:function(){this.toggleLoader(!0)},mouseleave:function(){this.toggleLoader(!1)}},mixins:[l],initialize:function(){this.boundShowNextPhotosetPhotoAndReCycle=s.bind(this.showNextPhotosetPhotoAndReCycle,this),this.loader=new a({variation:"small"}),this.$(".photo-post-icons").append(this.loader.render().$el),this.$deferredImgs=this.$("img[data-src]"),this.$el.hoverIntent({over:s.bind(this.cyclePhotoset,this),out:s.bind(this.stopPhotosetCycle,this),interval:350})},loadDeferreds:function(){this.$deferredImgs.length&&(this.$deferredImgs.imagesLoaded(s.bind(function(){this.toggleLoader(!1),this.$deferredImgs=[],this._cycling&&this.cyclePhotoset()},this)),this.$deferredImgs.each(function(e,t){var i=n(t);i.attr("src",""),i.attr("src",i.data("src"))}))},cyclePhotoset:function(e){this._cycling=!0,this.$deferredImgs.length?this.loadDeferreds():(s.isNumber(e)||(e=1300),this._photosetCycleRate||this.showNextPhotosetPhoto(),this._photosetCycleRate=e,this.$ph
1otoset().css("background-color","#000"),this._photosetCycleTimeout&&clearTimeout(this._photosetCycleTimeout),this._photosetCycleTimeout=setTimeout(this.boundShowNextPhotosetPhotoAndReCycle,this._photosetCycleRate),o.trigger("PhotosetMediaView:cycle",{view:this}))},showNextPhotosetPhotoAndReCycle:function(){this.showNextPhotosetPhoto(),this.cyclePhotoset()},showNextPhotosetPhoto:function(){var e=this.$shown().next();e.length||(e=this.$photoset().find(".photoset_photo:first")),this.$shown().removeClass("shown"),e.addClass("shown"),this._$shown=e},stopPhotosetCycle:function(){clearTimeout(this._photosetCycleTimeout),this._photosetCycleRate=null,this._cycling=!1,this.$photoset().css("background-color",""),this.toggleLoader(!1)},$photoset:function(){return"_$photoset"in this||(this._$photoset=this.$(".photoset_photos")),this._$photoset},$shown:function(){return this._$shown&&this._$shown.length||(this._$shown=this.$photoset().find(".photoset_photo.shown")),this._$shown&&this._$shown.length||(this._$shown=this.$photoset().find(".photoset_photo:last").addClass("shown")),this._$shown},toggleLoader:function(e){this.$deferredImgs.length&&(this.loader.set("loading",e),this.$el.toggleClass("loading-deferred-images",e))},displayShownPhotoInLightbox:function(e){var t=this.$shown().data("lightbox"),i=s.collect(this.$photoset().find("[data-lightbox]"),function(e){return n(e).data("lightbox")}),r=s.indexOf(i,t);o.trigger("tumblelogPopover:init",i,r+1),this.stopPhotosetCycle(),this.$el.trigger("tumblelogPopover",[{opened:!0}]),this.model.get("pt")&&o.trigger("useraction:explore_click:media",{model:this.model,loggingData:this.loggingData({userAction:"photo"})})}});e.exports=c},39945(e,t,i){"use strict";var n=i(97583).extend({logKey:"toastlog",events:{"toastlog:*":"log"}});e.exports=n},40290(e,t,i){"use strict";var n=i(71742),s=i(44890),o=i(72178),r=n.extend({name:"MobileNav",autoAppend:!0,view:function(){if(this.data)return this.data.npfMobileCreate=s.bool("redpop_post_form_mobile_create"),new o(this.data)}});e.exports=r},40370(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape;\nwith (obj) {\n__p += \'<div class="knight-rider-loader \' +\n__e( variation ) +\n\'" data-js-knightrider><div class="knight-rider-bar"></div><div class="knight-rider-bar"></div><div class="knight-rider-bar"></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},40516(e,t,i){"use strict";var n=i(97583).extend({logKey:"header_search",logEnv:{referrer:document.location.pathname},events:{"header_search:*":"log"}});e.exports=n},40663(e,t,i){"use strict";var n=i(3226);e.exports=function(e){i.e(795).then(function(t){try{e(i(5555))}catch(e){n(e,"reblog-graph")}}.bind(null,i)).catch(i.oe)}},40718(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<div class="messaging-conversation messaging-conversation--open" data-js-theme-background-tint data-js-conversation-open data-js-theme-accent-color-on-white><div data-subview="headerView"></div><div class="conversation-main" data-js-theme-background-color data-js-main><div data-subview="messagesView"></div><div data-subview="conversationLoaderView"></div></div><div data-subview="previewView"></div><div data-subview="composeView"></div></div><div class="messaging-conversation messaging-conversation--minimized" data-js-conversation-minimized data-js-theme-accent-color-on-white data-js-theme-avatar-shape-class><div data-subview="minimizedView"></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},40726(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<div class="nav-wrapper"><div data-subview="primaryNav"></div><div data-subview="secondaryNav"></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},41257(e,t,i){"use strict";var n=i(55679),s=i(95349);e.exports=function(e,t){t=t||"Exposer";var i=window;n.each(e,function(e,o){if(n.has(i,o))throw new Error('"'+o+'" already exists');s.log(t,"%s.%s",i,o),n.set(i,o,e)})}},41301(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(50283),r=i(98409),a=o.extend({className:"conversation-actions",tagName:"ul",template:r,events:{"click [data-js-block-blogname]":"_onBlockClick","click [data-js-delete-conversation]":"_onDeleteConversationClick"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","user","participants")),this.blockableParticipants=this.participants.getWithout(this.user.channels.pluck("uuid"))},getTemplateData:function(){return{blockableParticipants:n.invoke(this.blockableParticipants,"toJSON")}},_onBlockClick:function(e){var t=s(e.currentTarget).attr("data-js-block-blogname");e.preventDefault(),n.isEmpty(t)||this.trigger("block",t)},_onDeleteConversationClick:function(e){e.preventDefault(),this.trigger("delete")}});e.exports=a},41565(e,t,i){"use strict";var n=i(55679),s=i(27496),o=i(13482),r=i(97030),a=i(71092),l=i(56556),c=i(97960),u=a.extend({hidePopoverTimeout:null,mixins:[o,r],initialize:function(e){this.postModel=this.model,this.model=this.model.parentTumblelog,this.model&&(this.listenTo(this.postModel,"start_following",this.open),this.listenTo(this.postModel,"stop_following",this.close),this.$brick=this.$el.closest(".post_brick"),this.isLoggedIn()&&this.$("[data-popover-trigger]").hoverIntent({over:n.bind(this.showBlogCardPopover,this),out:n.noop,sensitivity:3}),this._open=!1)},open:function(){!this._open&&this.model&&(this.$brick.addClass("reblog-follow-tray-opening"),s.trigger("post:follow_tray_change"),this.$el.addClass("open"),this.$brick.addClass("reblog-follow-tray-open").removeClass("reblog-follow-tray-opening"),this.postsView||(this.postsView=new c({model:this.model,blog_bg_color:!1}),this.$el.append(this.postsView.render().el)),this._open=!0)},close:function(){this._open&&(this.$brick.addClass("reblog-follow-tray-closing"),s.trigger("post:follow_tray_change"),this.$el.removeClass("open"),this.$brick.removeClass("reblog-follow-tray-open").removeClass("reblog-follow-tray-closing"),this._open=!1)},showBlogCardPopover:function(){this.popover&&(this.popover.teardown(),this.popover=null),s.trigger("TumblelogPopover:log_follow_open",{loggingData:{postId:this.postModel.get("id"),tumblelog:this.model.get("name"),position:this.$brick.index()}}),this.popover=new l({model:this.model,pinnedTarget:this.$(".tray-header")}),this.popover.openPopover()}});e.exports=u},41665(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(28724),r=function(){for(var e="transform WebkitTransform MozTransform OTransform msTransform".split(" "),t=0;t<e.length;t++)if(!s.isUndefined(document.createElement("div").style[e[t]]))return!0;return!1}(),a=new o({before:{initialize:function(){this._draggable={dragging:!1,dragX:!1,$doc:n(document),pointerDown:!1,transform:r},this.events=s.extend({"mousedown [data-draggabletags]":"_dragEvents","touchstart [data-draggabletags]":"_dragEvents","touchmove [data-draggabletags]":"_dragEvents","mouseleave [data-draggabletags]":"_dragEvents","mouseup [data-draggabletags]":"_dragEvents","touchend [data-draggabletags]":"_dragEvents","click [data-draggabletags] a":"_dragLinkHandler"},s.result(this,"events")),this.$el.one("mouseenter",s.bind(this._dragSetup,this))}},_dragSetup:function(){this._dragOverflowing()&&this.$el.addClass("draggable")},_dragGetInnerEl:function(){return this._draggable.$dragInner||(this._draggable.$dragInner=this.$("[data-draggabletags]")),this._draggable.$dragInner},_dragOverflowing:function(){return this.$el.width()<this._dragGetInnerEl().width()},_dragCheckMouseOut:function(e){var t=e.relatedTarget||e.toElement;t&&"HTML"!==t.nodeName||this._dragEnd(e)},_dragGetDimensions:function(){var e=this.$el.width(),t=this._dragGetInnerEl().width();return{parentWidth:e,innerWidth:t,maxLeft:0,maxRight:e-t-10}},_dragEvents:function(e){switch(e.type){case"mousedown":case"touchstart":this._dragStart(e);break;case"mousemove":case"touchmove":this._draggable.pointerDown&&this._dragMove(e);break;case"touchend":case"mouseup":this._dragEnd(e)}},_dragBindDocEvents:function(){this._draggable.$doc.on("mousemove.tagsDraggable",s.bind(this._dragEvents,this)),this._draggable.$doc.on("mouseup.tagsDraggable",s.bind(this._dragReset,this)),this._draggable.$doc.on("mouseout",s.bind(this._dragCheckMouseOut,this))},_dragUnbindDocEvents:function(){this._draggable.$doc.off("mousemove.tagsDraggable"),this._draggable.$doc.off("mouseup.tagsDraggable"),this._draggable.$doc.off("mouseout")},_dragLinkHandler:function(e){this._draggable.dragging&&(e.stopPropagation(),e.preventDefault())},_dragStart:function(e){if(e.preventDefault(),!this._draggable.dragging&&!this._draggable.pointerDown&&this._dragOverflowing()){var t=s.parseInt(this.$el.css("padding-left").replace("px",""));this._draggable.pointerDown=!0,this._draggable.startX=this._dragGetInnerEl().position().left-t,this._draggable.pageX="pageX"in e?e.pageX:e.originalEvent.touches[0].pageX,this._dragBindDocEvents()}},_dragMove:function(e){e.preventDefault(),e.stopPropagation(),this._dragGetInnerEl().addClass("dragging"),this._draggable.dragging=!0;var t=("clientX"in e?e.clientX:e.originalEvent.touches[0].clientX)-this._draggable.pageX;this._draggable.dragX=t+this._draggable.startX,this._dragSet(this._draggable.dragX)},_dragSet:function(e){this._draggable.transform?this._dragGetInnerEl().css("transform","translate("+e+"px, 0)"):this._dragGetInnerEl().css("left",e)},_dragResetPosition:function(){var e=this._dragGetDimensions();this._draggable.dragX>e.maxLeft?this._dragSet(e.maxLeft):this._draggable.dragX<e.maxRight&&this._dragSet(e.maxRight)},_dragEnd:function(e){e.preventDefault(),e.stopPropagation();var t=s.bind(this._dragReset,this);s.delay(t,100)},_dragReset:function(){(this._draggable.dragging||this._draggable.pointerDown)&&(this._draggable.dragging=!1,this._draggable.pointerDown=!1,this._dragGetInnerEl().removeClass("dragging"),this._dragResetPosition(),this._dragUnbindDocEvents())}});e.exports=a},41699(e,t,i){"use strict";var n=i(55679),s=i(17604).sprintf,o=i(95921).truncateLongStrings;function r(){}r.prototype.genericFieldMap={one:"title",two:"body"},r.prototype.editorField="two",r.prototype.typeAttributes={title:"",body:""},r.prototype.allowAnswerFields=["title","body"],r.prototype.generateTweetText=function(e,t){var i,n=this.getHtmlStripped("title"),r=this.getHtmlStripped("body");return r=r.replace(/[\r\n\s]*\[\[MORE\]\].*$/gi,""),i=n&&r?s("%s - %s",
1n,r):n||r||"",o(i,t)},r.prototype.validate=function(e,t,i){var s=[],o=!n.isUndefined(t.reblog_tree)&&!1!==t.reblog_tree&&""!==t.reblog_tree;return(!t.body||t.body.length<1)&&(!t.title||t.title.length<1)&&(o||s.push("Post body empty.")),e.call(this,t,{errors:s})},e.exports=r},41784(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n\n _.forEach(types, function(type) {\n\n    /* set the bold style on template render to accurately measure the control width */\n;\n__p += ' <a href=\"' +\n__e( type.rootUrl ) +\n'\" class=\"content-control ' +\n((__t = ( (type.active) ? 'active' : '' )) == null ? '' : __t) +\n'\" style=\"font-weight:bold;\" data-text=\"' +\n__e( type.name ) +\n'\" data-content-type=\"' +\n__e( type.id ) +\n'\"> ';\n if (type.showSponsoredBadge) { ;\n__p += ' <div class=\"sponsored_badge light mini\"><div class=\"sponsored_badge_icon\"><span class=\"dollar_sign\">$</span> <span class=\"ring\"></span></div></div> ';\n } ;\n__p += ' ' +\n__e( type.name ) +\n' </a> ';\n }); ;\n__p += ' <span class=\"content-control more-controls hidden\"><span class=\"type-text\">' +\n__e( __('More') ) +\n'</span><i class=\"icon_arrow_carrot_down\"></i></span>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},41872(e,t,i){"use strict";var n=i(74692),s=i(55679),o=new(i(28724))({setUpSelector:function(e){e.on("change",s.bind(this.__select_change,this))},__select_change:function(e){var t=n(e.currentTarget);this.__update_select(t)},__update_select:function(e){e.siblings("label").text(e.find(":selected").text())}});e.exports=o},41956(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(71092),r=i(64491),a=i(38578),l=i(27496),c=i(59797),u=i(87335),h=i(71280),d=o.extend({className:"nav-menu",template:c,mixins:[r,a],events:{"click .menu-burger":"__clickMenuBurger","click [data-subnav]":"__clickSubnav","click .sneeze-guard":"__clickSneezeGuard"},__clickSneezeGuard:function(e){e.preventDefault(),this.closeDrawer()},__clickSubnav:function(e){e.preventDefault(),this.openSubNav(s(e.currentTarget).data("subnav"))},__clickMenuBurger:function(e){e.preventDefault(),this.toggleDrawer()},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,e),this.get("drawer_open")&&this.openDrawer(),this.get("logged_in")?this.subViews.drawer=new u(e):this.subViews.drawer=new h(e),this.listenTo(l,"mobileHeader:search:click",this.closeDrawer)},render:function(){return this.$el.html(this.template()),this.$body=s("body"),this.$html=s("html"),this.attachSubViews(),this},toggleDrawer:function(){this.$el.hasClass("subnav-active")?this.closeSubNav():this.get("drawer_open")?this.closeDrawer():this.openDrawer()},openDrawer:function(){this.set("drawer_open",!0),this.$body.addClass("nav-drawer-open"),this.$html.addClass("nav-drawer-open"),this.$el.addClass("active"),l.trigger("drawer:open")},closeDrawer:function(){this.set("drawer_open",!1),this.$body.removeClass("nav-drawer-open"),this.$html.removeClass("nav-drawer-open"),this.$el.removeClass("active subnav-active"),l.trigger("drawer:closed")},openSubNav:function(e){this.$el.addClass("subnav-active"),l.trigger("drawer:subnav:open",e)},closeSubNav:function(){this.$el.removeClass("subnav-active"),l.trigger("drawer:subnav:close")}});e.exports=d},42e3(e,t,i){"use strict";var n=i(50283),s=i(40370),o=n.extend({className:"knight-rider-container",template:s,defaults:{variation:"",loading:!1},_onChangeLoading:function(e,t){this.$el.toggleClass("loading",t),this.$el.find("[data-js-knightRider]").toggleClass("animate",t),this.$el.toggle(t)},afterRender:function(){this._onChangeLoading(this,this.get("loading")),this.listenTo(this,"change:loading",this._onChangeLoading)}});e.exports=o},42062(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(50283),r=i(7888),a=o.extend({template:r,className:"drawer",defaults:{visible:!1},initialize:function(e){e.subviews&&(this.$body=n("body"))},afterRender:function(){this.show()},show:function(){this.get("visible")||(this.set("visible",!0),this.toggleAnimation("open",!0))},hide:function(e){this.get("visible")?(this.set("visible",!1),this.toggleAnimation("open",!1),s.delay(e,500)):e()},toggleAnimation:function(e,t){var i=s.bind(function(){this.$el.toggleClass(e,t)},this);window.requestAnimationFrame?window.requestAnimationFrame(i):s.defer(i)},animateRemove:function(){return this.hide(s.bind(function(){this.remove()},this)),this}});e.exports=a},42562(e){e.exports="/svc/user/counts"},42714(e,t,i){"use strict";var n=i(55679),s=i(71742),o=i(83792),r=i(18398),a=(i(85252),s.extend({name:"Upload",initialize:function(e){e=n.extend({},e),this.collection=e.collection||(e.collection=new r),this.indexView=new o(e),this.listenTo(this.collection,"all",this._relayCollectionEvent)},_relayCollectionEvent:function(){this.trigger.apply(this,arguments)},addFiles:function(e){return this.indexView.add({files:e})},promise:function(){return this.indexView.promise()},teardown:function(){return this.remove()},remove:function(){return this.indexView.remove(),this.stopListening(),this},render:function(){return this.indexView.render(),this},getElement:function(){return this.indexView.$el},getCurrentRequest:function(){return this.indexView.jqXHR}}));e.exports=a},43038(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div class=\"tooltip_wrapper ' +\n__e( placement ) +\n' ' +\n__e( class_name ) +\n'\" style=\"left:' +\n__e( left_css ) +\n';\"><div class=\"tooltip\"> ' +\n((__t = ( text )) == null ? '' : __t) +\n' </div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},43315(e,t,i){"use strict";var n=i(80160).extend({defaults:{message:null,url:null,width:null,height:null,editCallback:null}});e.exports=n},43606(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(81515),r=i(27496),a=i(48357),l=i(71092),c=l.extend({events:{"click [data-edit-button]":"onEditButtonClick","click [data-done-button]":"onDoneButtonClick","keyup [data-add-url-field]":"onInputKeyup","click [data-remove-url-field]":"onRemoveButtonClick"},initialize:function(){this.editMode=!1},addAttributesToField:function(e){var t=e.find(".optional-tag").length,i=e.find("input"),n=i.data("original-placeholder"),s=i.data("field-group-name");i.attr({name:s,placeholder:n}),t||i.prop("required",!0)},addUrlField:function(e){var t=n(e.target).data("field-group-name"),i=this.containers[t],s=i.find(".input-row").last(),r=s.find("input");i.removeClass("no-edit-button"),r.attr("name")||this.addAttributesToField(s),s.removeClass("no-remove-button");var l=s.clone(!0).addClass("no-remove-button");l.find("input").val("").removeClass("error").removeAttr("required").removeAttr("name").attr("placeholder",o("Add a new URL")),a.animate(l,{opacity:[1,0]},{duration:200,easing:"easeIn"}),l.appendTo(i)},onEditButtonClick:function(e){this.enterEditMode(e)},onDoneButtonClick:function(e){this.exitEditMode(e)},onRemoveButtonClick:function(e){var t=n(e.target).data("field-group-name"),i=this.containers[t],s=n(e.target).next("input");if(r.trigger("drawerform:errortag:remove",{field:s}),n(e.target).parent().remove(),1===i.find(".input-row").length){var o=i.find(".input-row").last();i.addClass("no-edit-button"),this.addAttributesToField(o),this.exitEditMode(e)}r.trigger("drawerform:validation:trigger")},exitEditMode:function(e){this.editMode=!1;var t=n(e.target).data("field-group-name");this.containers[t].removeClass("edit-mode")},enterEditMode:function(e){this.editMode=!0;var t=n(e.target).data("field-group-name");this.containers[t].addClass("edit-mode")},onInputKeyup:function(e){if(this.editMode)this.exitEditMode(e);else{var t=n(e.target).data("field-group-name"),i=this.containers[t].find("input");i.last().val().trim().length&&i.length<10&&this.addUrlField(e)}},update:function(){this.containers={},this.$el.find(".dynamic-fields").each(s.bind(function(e,t){var i=n(t),s=n(t).data("field-group-name");this.containers[s]=i},this))}});e.exports=c},43736(e,t,i){var n=i(55679),s=i(81515),o=i(74692),r=i(95093),a=i(44890),l=i(50283),c=i(98237),u=i(57505),h=i(33255),d=i(98621),p=i(96791),g=i(80158),f=i(33718),m=n.template('<a href="<%- blogUrl %>/tagged/<%- tag %>" data-js-tumblelog-name="<%- blogName %>" data-js-tumblelog-tag="<%- tag %>">'),_=l.extend({className:"conversation-icebreakers",template:f,mixins:[c],defaults:{isShowTags:!0,isShowRelationship:!0,isShowDescription:!0}
1,subviews:{statusIndicator:{constructor:g,options:function(e){return{isOnline:-1!==e.participant.get("seconds_since_last_activity"),canSeeUIFlag:a.bool("status_indicator"),name:e.participant.get("name")}}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","participant"))},getTemplateData:function(){return{description:this.get("isShowDescription")?this._getCleanDescriptionString():null,relationship:this.get("isShowRelationship")?this._getRelationshipString():null,tagsMarkup:this.get("isShowTags")?this._getTagsDescriptionMarkup():null,canPixelateAvatar:this.participant.get("can_pixelate_avatar"),name:this.participant.get("name"),avatarUrl:this.participant.getAvatarUrl(),url:this.participant.get("url")}},afterRender:function(){this.theme=new p({el:this.el,theme:this.participant.get("theme")}).render(),this.get("isShowDescription")&&n.defer(n.bind(function(){d(this.js$("description"))},this));var e=this.$el.find(".pixelated-avatar");n.each(e,n.bind(function(e){o(e).removeClass("hide").addClass("show"),u.drawPixelatedImages(this)},this))},_getOpeningTagAnchor:function(e){var t=this.participant.get("name"),i=this.participant.get("url");return m({blogUrl:i,blogName:t,tag:e})},_getClosingTagAnchor:function(){return"</a>"},_getOpeningTagText:function(){return'<span class="text">'},_getClosingTagText:function(){return"</span>"},_getTagsDescriptionMarkup:function(){var e=this.participant.getBlogTags(),t=this._getOpeningTagText(),i=this._getClosingTagText(),o=this._getClosingTagAnchor();return e.length>1?s("%1$sPosts about%2$s %3$s#%4$s%5$s %6$sand%7$s %8$s#%9$s%10$s",t,i,this._getOpeningTagAnchor(e[0]),n.escape(e[0]),o,t,i,this._getOpeningTagAnchor(e[1]),n.escape(e[1]),o):1===e.length?s("%1$sPosts about%2$s %3$s#%4$s%5$s",t,i,this._getOpeningTagAnchor(e[0]),n.escape(e[0]),o):null},_getCleanDescriptionString:function(){return h.stripTags(this.participant.getDescription())},_getRelationshipString:function(){var e;if(this.participant.isMutuals()){if(e=this._getRelativeTimeString(this.participant.getDurationMutualsSeconds()),!n.isEmpty(e))return s("Mutuals for %1$s",e)}else if(this.participant.isFollowingYou()){if(e=this._getRelativeTimeString(this.participant.getDurationFollowingYouSeconds()),!n.isEmpty(e))return s("Followed you %1$s ago",e)}else if(this.participant.isFollowing()&&(e=this._getRelativeTimeString(this.participant.getDurationFollowingSeconds()),!n.isEmpty(e)))return s("Following for %1$s",e);return s("Not following each other")},_getRelativeTimeString:function(e){return n.isNumber(e)?r(Date.now()-1e3*e).fromNow(!0):null}});e.exports=_},44370(e,t,i){"use strict";var n=i(55679),s=i(64147),o=s.extend({defaults:n.defaults({isDisabled:!1,isAtTop:!1,isAtBottom:!1,topThreshold:50,bottomThreshold:50},s.prototype.defaults),initialize:function(e){return this.options=e||{},s.prototype.initialize.call(this,this.options.el,this.options)},render:function(){return this.listenTo(this,"change:isAtTop",this._changeIsAtTop),this.listenTo(this,"change:isAtBottom",this._changeIsAtBottom),s.prototype.render.apply(this,arguments)},_stealScroll:function(e){return this.get("isDisabled")?(e.preventDefault(),void e.stopPropagation()):s.prototype._stealScroll.apply(this,arguments)},update:function(){return this._updateInfiniteScrollFlags(),s.prototype.update.apply(this,arguments)},_onScrollStop:function(){return this._updateInfiniteScrollFlags(),s.prototype._onScrollStop.apply(this,arguments)},getCurrentPositions:function(){return this._setCurrentPositions(),{height:this._currentHeight,scrollBottom:this._currentScrollBottom,scrollTop:this._currentScrollTop}},isAtTop:function(){return this.get("isAtTop")},isAtBottom:function(){return this.get("isAtBottom")},_isAtTop:function(e){return this._isUserScroll()&&!this.get("isDisabled")&&this._currentScrollTop<=e&&this._currentHeight>e},_isAtBottom:function(e){return this._isUserScroll()&&!this.get("isDisabled")&&this._currentScrollBottom<=e&&this._currentHeight>e},_isUserScroll:function(){return!!n.isFinite(this._previousScrollHeight)&&Math.abs(this._currentScrollHeight-this._previousScrollHeight)<=5},setDisabled:function(e){this.set("isDisabled",e)},isDisabled:function(){return this.get("isDisabled")},_setCurrentPositions:function(){var e=this.container;this._previousScrollHeight=this._currentScrollHeight,this._currentScrollHeight=e.scrollHeight,this._currentHeight=e.clientHeight,this._currentScrollBottom=e.scrollHeight-e.scrollTop-this.container.clientHeight,this._currentScrollTop=e.scrollTop},_updateInfiniteScrollFlags:function(){if(this.destroyed)return!1;this._setCurrentPositions(),this.set({isAtTop:this._isAtTop(this.get("topThreshold")),isAtBottom:this._isAtBottom(this.get("bottomThreshold"))})},_changeIsAtTop:function(e,t){this.trigger("scrolltop",t)},_changeIsAtBottom:function(e,t){this.trigger("scrollbottom",t)}});e.exports=o},44384(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(64491),r=i(13482),a=s.extend({mixins:[o,r],initialize:function(e){this.buildSubviews(e.subViews)},buildSubviews:function(e){e||(e={}
1),n.forEach(this.hasSubViews,function(t,i){if(!1!==e[i]){var s={model:this.model,el:this.$('[data-subview="'+i+'"]')};e[i]&&n.isObject(e[i])&&(s.subViews=e[i]);var o=new t(s);!1!==n.result(o,"shouldAttachAsSubview")&&(this.subViews[i]=o)}},this)},attachedToDOM:function(){n(this.subViews).filter("attachedToDOM").invoke("attachedToDOM").value()},beforeTeardown:function(){return this.stopListening(this.model),this},render:function(){return this.attachSubViews(),this},afterRender:function(){this.renderSubViews()},remove:function(){this.teardown(),s.prototype.remove.apply(this,arguments)}});e.exports=a},44579(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(92712),r=i(84701),a=i(98237),l=i(25256),c=s.extend({template:o,mixins:[a],defaults:{currentTumblelog:!1,isOpen:!1,requiresDropdown:!1,showCaret:!0,showName:!0,dropdownClass:null,popoverOptions:null,avatarSize:96,badgeCountField:null,showTotalBadge:!0,showNumberInBadge:!1,includeCurrentBlogInTotalBadge:!1,maxBadgeCount:99,badgeActiveClass:"has-badge"},events:{"click [data-js-button]":"toggleDropdown"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"collection")),this.get("currentTumblelog")||this.set("currentTumblelog",this.collection.findWhere({is_current:!0})),this.set("requiresDropdown",this.collection.length>1),!n.isEmpty(this.get("badgeCountField"))&&this.get("requiresDropdown")||this.set("showTotalBadge",!1)},getTemplateData:function(){var e=this.get("showTotalBadge"),t=e&&this.get("showNumberInBadge"),i=e?this.getBadgeCount():null;return{avatarUrl:l(this.getCurrentTumblelogProperty("avatar_url"),this.get("avatarSize")),displayName:this.getCurrentTumblelogProperty("name"),requiresDropdown:this.get("requiresDropdown"),hasBadge:e&&i>0,badgeCountString:t?this.getBadgeCountString(i):null}},createDropdown:function(){var e=n.extend({},this.get("popoverOptions"),{identifier:"blogSelector:dropdown",pinnedTarget:this.js$("avatar"),shift:{x:86,y:10},collection:this.collection,currentTumblelog:this.getCurrentTumblelog(),badgeCountField:this.get("badgeCountField"),maxBadgeCount:this.get("maxBadgeCount")});this.dropdown=new r(e),this.get("dropdownClass")&&this.dropdown.$el.addClass(this.get("dropdownClass")),this.listenTo(this.dropdown,"change:currentTumblelog",this.adjustCurrentTumblelog),this.listenTo(this.dropdown,"open",this._onDropdownOpen),this.listenTo(this.dropdown,"close",this._onDropdownClose)},_onDropdownOpen:function(){this.set("isOpen",!0)},_onDropdownClose:function(){this.set("isOpen",!1)},_onChangeIsOpen:function(e,t){this.js$("caret").toggleClass("is-open",t)},toggleDropdown:function(){this.get("requiresDropdown")&&(this.dropdown.isOrWasRecentlyRendered()||(this.createDropdown(),this.dropdown.render()))},afterRender:function(){return this.get("showTotalBadge")&&(this.listenTo(this.collection,"change:"+this.get("badgeCountField"),this._onBadgeCountChange),this._onBadgeCountChange()),this.get("requiresDropdown")&&(this.createDropdown(),this.js$("button").addClass("has-dropdown"),this.listenTo(this,"change:isOpen",this._onChangeIsOpen),this.listenTo(this,"change:showCaret",this._onChangeShowCaret),this._onChangeIsOpen(this,this.get("isOpen")),this._onChangeShowCaret(this,this.get("showCaret"))),this.listenTo(this,"change:showName",this._onChangeShowName),this._onChangeShowName(this,this.get("showName")),this},getCurrentTumblelog:function(){return this.get("currentTumblelog")},getCurrentTumblelogProperty:function(e){var t=this.getCurrentTumblelog();if(t&&t.has(e)&&n.isString(e))return t.get(e)}
1,adjustCurrentTumblelog:function(){var e;this.set("currentTumblelog",this.dropdown.get("currentTumblelog")),this.rendered&&(e=l(this.getCurrentTumblelogProperty("avatar_url"),this.get("avatarSize")),this.js$("avatar").attr("src",e),this.js$("label").text(this.getCurrentTumblelogProperty("name")),this.get("showTotalBadge")&&!this.get("includeCurrentBlogInTotalBadge")&&this._onBadgeCountChange())},teardown:function(){return this.remove(),this},getBadgeCount:function(){var e,t=this.get("currentTumblelog");return this.get("badgeCountField")?(e=n.sum(this.collection.pluck(this.get("badgeCountField"))),t&&!this.get("includeCurrentBlogInTotalBadge")&&(e-=t.get(this.get("badgeCountField"))),Math.max(0,e)):null},getBadgeCountString:function(e){var t=this.get("maxBadgeCount");return e>t?t+"+":e>0?e:""},updateBadge:function(e){var t=this.js$("badge");t.toggleClass(this.get("badgeActiveClass"),e>0),this.get("showNumberInBadge")&&t.text(this.getBadgeCountString(e))},_onBadgeCountChange:function(){this.updateBadge(this.getBadgeCount())},_onChangeShowCaret:function(e,t){this.js$("caret").toggle(t)},_onChangeShowName:function(e,t){this.js$("label").toggle(t)}});e.exports=c},44727(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(98237),r=i(55731),a=s.extend({className:"conversation-message-sticker message-container",mixins:[o],template:r,defaults:{thumbnailWidth:210,rawWidth:1280,errorClassName:"is-error"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","participants","conversation"))},afterRenderSubviews:function(){this.listenTo(this.model,"change:isError",this._onModelIsErrorChange)},getTemplateData:function(){var e=this.model.toJSON(),t=e.sticker.original_size_url,i=e.sticker.url,n=this.participants.get(this.model.get("participant"));return{name:n?n.get("name"):null,avatarUrl:n?n.getAvatarUrl():null,blogUrl:n?n.get("url"):null,rawUrl:t||null,url:i||null,thumbnailWidth:this.get("thumbnailWidth"),rawWidth:this.get("rawWidth")}},_onModelIsErrorChange:function(e){this.$el.toggleClass(this.get("errorClassName"),e)}});e.exports=a},44731(e,t,i){"use strict";var n=i(55679),s=i(27513),o=i(94246),r=i(86115),a=s.extend({url:"/svc/conversations/messages",mixins:[o],model:r,_getRoot:function(e){return n.has(e,"response")?n.get(e,"response.messages"):e},parse:function(e,t){return n.get(this._getRoot(e),"data")||[]},parsePreviousLink:function(e,t){return n.get(this._getRoot(e),"_links.previous")},parseNextLink:function(e,t){return n.get(this._getRoot(e),"_links.next")},poll:function(e){return e=e||{},n.extend(e,{cache:!1,remove:!1,skipParseLinks:!0}),this.fetch(e)}});e.exports=a},44740(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div class=\"elevator\"></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},44765(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(57505),r=i(98621),a=i(98237),l=i(44890),c=i(50283),u=i(6479),h=i(11229),d=c.extend({className:"inbox-recipient",template:h,mixins:[a],defaults:{isSelected:!1,context:"inbox:recipients"},events:{"click [data-start-conversation]":"_onStartConversationClick",mouseenter:"_onRecipientHover",mouseleave:"_onRecipientLeave"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","onSelect","onClear","context","isNewEmptyInboxEnabled"))},afterRender:function(){this.listenTo(this,"change:isSelected",this._onChangeIsSelected),this.isNewEmptyInboxEnabled&&r(this.js$("tags-string"));var e=this.$el.find(".pixelated-avatar");n.each(e,n.bind(function(e){this.$(e).removeClass("hide").addClass("show"),o.drawPixelatedImages(this)},this))},setSelected:function(e){this.rendered&&this.set("isSelected",e)},getTemplateData:function(){var e=u(),t=this.model.get("is_adult"),i=n.pluck(e.get("
1channels"),"name"),s=n.contains(i,this.model.get("name")),o=l.bool("safe_mode")&&e.get("safe_mode");return{name:this.model.get("name"),title:this.model.get("title"),avatarUrl:this.model.getAvatarUrl(),isNewEmptyInboxEnabled:this.isNewEmptyInboxEnabled,tagsString:this.getTagsString(),isSafeModeEnabled:o,isUser:s,blogIsAdult:t}},getTagsString:function(){var e=this.model.get("tags");return n.isEmpty(e)?null:e.length>1?s("Posts about #%1$s and #%2$s",e[0],e[1]):1===e.length?s("Posts about #%1$s",e[0]):void 0},_onStartConversationClick:function(e){e.preventDefault(),this.eventBus.trigger(this.eventBus.CONVERSATION_OPEN_PARTICIPANT_MODELS,[this.model],this.get("context")),this.isNewEmptyInboxEnabled&&this.eventBus.trigger(this.eventBus.NEW_EMPTY_INBOX_SUGGESTION_CLICK,this.model,this.get("context"),!0)},_onChangeIsSelected:function(e,t){this.$el.toggleClass("selected",t)},_onRecipientHover:function(){n.isFunction(this.onSelect)&&this.onSelect(this,this.model)},_onRecipientLeave:function(){n.isFunction(this.onClear)&&this.onClear(this,this.model)}});e.exports=d},44838(e,t,i){"use strict";var n=i(44384),s=i(8689),o=i(10587),r=i(90752),a=i(60538),l=i(92148),c=i(39424),u=i(59929),h=i(94755),d=i(73488),p=n.extend({hasSubViews:{share:s,adminMenu:o,creatorMenu:r,sponsorMenu:a,ignore:l,reply:c,reblog:u,like:h,reblogGraph:d}});e.exports=p},44861(e,t,i){"use strict";var n=i(55679),s=["like","reblog","answer","reply","photo","with_commentary"];e.exports=function(e){var t=e.closest(".post");return{postId:n.get(t.data("json"),"post-id")||t.attr("data-post-id"),noteCount:t.find(".note_link_current").data("count"),noteType:e.attr("class").split(" ").filter(function(e){return n.includes(s,e)}).join("_")}}},44904(e,t,i){"use strict";var n=i(55679),s=i(17604).sprintf,o=i(95921).truncateLongStrings;function r(){}r.prototype.genericFieldMap={one:"title",two:"chat"},r.prototype.typeAttributes={title:"",chat:""},r.prototype.generateTweetText=function(e,t){var i,n=this.getHtmlStripped("title"),r=this.getHtmlStripped("chat");return i=n&&r?s("%s - %s",n,r):n||r||"",o(i,t)},r.prototype.validate=function(e,t,i){var n=[];return(!t.chat||t.chat.length<1)&&n.push("No chat."),e.call(this,t,{errors:n})},r.prototype.serializeForServer=function(e){var t=e.apply(this,n.rest(arguments));return t["post[two]"]=this.get("chat").replace(/\u00A0/gm," "),t},e.exports=r},44939(e,t,i){var n=i(21391),s=i(55679),o=function(){};o.extend=n.Model.extend,s.extend(o.prototype,n.Events),s.extend(o.prototype,{CONVERSATION_FETCHING:"conversation:fetching",CONVERSATION_OPEN_CONVERSATION_MODEL:"conversation:open:model:conversation",CONVERSATION_OPEN_PARTICIPANT_MODELS:"conversation:open:model:partipants",CONVERSATION_OPEN_TUMBLR_URL:"conversation:open:tumblr:url",CONVERSATION_OPEN_MESSAGING_URL:"conversation:open:messaging:url",CONVERSATION_DELETE_MODEL:"conversation:delete:model",CONVERSATION_MESSAGE_SENT:"conversation:message:sent",CONVERSATION_MESSAGE_SENDING:"conversation:message:sending",CONVERSATION_MESSAGE_FAILED:"conversation:message:failed",CONVERSATION_MESSAGE_INPUT:"conversation:message:input",CONVERSATION_MESSAGES_SEND_REQUESTED:"conversation:messages:send:requested",CONVERSATION_MESSAGES_SENDING:"conversation:messages:sending",CONVERSATION_MESSAGES_UNREAD_FETCHED:"conversation:messages:unread:fetched",CONVERSATION_MARK_AS_SPAM:"conversation:spam",CONVERSATION_IMAGE_PREVIEW_ADD:"conversation:image:preview:add",CONVERSATION_IMAGE_PREVIEW_DISMISS:"conversation:image:preview:dismiss",CONVERSATION_IMAGE_PREVIEW_EDIT:"conversation:image:preview:edit",CONVERSATION_IMAGE_LIGHTBOX:"conversation:image:lightbox",CONVERSATION_COMPOSE_PLUGIN_CLICK:"conversation:compose:plugin:click",BLOCK:"block",NEW_EMPTY_INBOX_SUGGESTION_CLICK:"new:inbox:suggestion:click",NEW_EMPTY_INBOX_NEW_MESSAGE_CLICK:"new:inbox:new-message:click",OLD_EMPTY_INBOX_SUGGESTION_CLICK:"old:inbox:suggestion:click",OLD_EMPTY_INBOX_NEW_MESSAGE_CLICK:"old:inbox:new-message:click"}),e.exports=o},45400(e,t,i){"use strict";var n=i(97583).extend({logKey:"linkpost_interactions",logOptions:{init_event:!1},events:{"linkpost:*":"handleEvent"},logEnv:{location:document.location.pathname},handleEvent:function(e,t){this.log(e,t)}});e.exports=n},45427(e,t,i){"use strict";var n=i(80160).extend({defaults:{component:null}});e.exports=n},45668(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(71742),r=i(89529),a=i(27496),l=i(80976).Ay,c=o.extend({name:"MediaEmbedHarness",$post:null,channel:null,wat
1cher:null,_data:{service:"",embedID:"",postID:"",source:""},videoState:"",initialize:function(e){e.embedID&&(this._data=s.pick(e,s.keys(this._data)),this.$iframe=n("#"+this._data.embedID),this.iframe=this.$iframe.get(0),this.$post=this.$iframe.closest(".post"),this.post=this.$post.get(0),this.postId=this.$post.data("post-id"),this.isPinned=this.$post.data("is-pinned"),this.channel=new r({namespace:this._data.embedID+":"+this._data.service+":"+this._data.postID,window:this._data.source}),this.channel.on_connection(s.bind(function(){this.channel.listen_to("stateChanged",this.__onStateChange,this),this.channel.listen_to("playerReady",this.__autoplayPinnedPost,this),this.channel.listen_to("heightChanged",this.__onHeightChange,this)},this)),this._setupWatcher())},__autoplayPinnedPost:function(){this.isPinned&&this.autoplay()},autoplay:function(){this.channel&&this.channel.send("autoplay")},play:function(){this.channel&&this.channel.send("play")},pause:function(){this.channel&&this.channel.send("pause")},getState:function(){this.channel.call("getState").then(function(e,t){return t})},getData:function(){return this._data},_setupWatcher:function(){this.post&&(this.watcher=l.create(this.post,-52),this.watcher.fullyEnterViewport(s.bind(function(){"autoplaying"===this.videoState&&this.autoplay(),this.trigger("fullyEnterViewport")},this)),this.watcher.partiallyExitViewport(s.bind(function(){this.trigger("partiallyExitViewport")},this)),this.watcher.exitViewport(s.bind(function(){this.trigger("exitViewport")},this)))},__onStateChange:function(e){this.videoState=e;var t={loggingData:s.extend({},s.omit(this._data,"source"),{state:e})};t.loggingData.postID&&"null"!==t.loggingData.postID||(t.loggingData.postID=this.postId?this.postId.toString():""),this.trigger("stateChange",e,this),a.trigger("post:embed:stateChange",t)},__onHeightChange:function(e){this.$iframe.parent().addBack().height(e)}});e.exports=c},45707(e,t,i){"use strict";var n=i(55679),s=i(27513),o=i(94246),r=i(79990),a=s.extend({url:"/svc/conversations",mixins:[o],model:r,comparator:function(e){return-e.get("last_modified_ts")},_getRoot:function(e){return n.has(e,"response")?n.get(e,"response"):e},parse:function(e,t){return n.get(this._getRoot(e),"conversations")||[]},parsePreviousLink:function(e,t){return n.get(this._getRoot(e),"_links.previous")},parseNextLink:function(e,t){return n.get(this._getRoot(e),"_links.next")},fetchInbox:function(e,t){t=t||{};var i=n.extend({},t.data,{participant:e});return n.extend(t,{cache:!1,remove:!1,skipParseLinks:0!==this.length,data:i,isFetchInbox:!0}),this.fetch(t)},getUnreadCount:function(){return n.reduce(this.models,function(e,t){return t.isUnread()?e+1:e},0)}});e.exports=a},45736(e,t,i){"use strict";var n="ace"in window,s=window.ace,o=i(47496);i(56861),i(7613),i(29994),i(8263),i(59118),i(74144),i(88949),o.require=o.acequire,n?window.ace=s:delete window.ace,e.exports=o},45989(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(27496),r=i(13482),a=i(44384),l=i(56556),c=i(97030),u=a.extend({hidePopoverTimeout:null,mixins:[r,c],events:{click:"checkIfPremiumPost"},initialize:function(e){a.prototype.initialize.apply(this,arguments),this.isLoggedIn()&&this.$("[data-popover-trigger]").hoverIntent({over:n.bind(this.showBlogCardPopover,this),out:n.noop,sensitivity:3})},checkIfPremiumPost:function(){this.model.get("pt")&&o.trigger("useraction:explore_click:lightbox",{model:this.model,loggingData:this.loggingData({userAction:"lightbox"})})},showBlogCardPopover:function(e){var t;this.popover&&(this.popover.teardown(),this.popover=null),t="parent"===s(e.target).attr("data-popover-trigger")?this.model.parentTumblelog:this.model.tumblelog;var i=this.$el.closest("article");o.trigger("TumblelogPopover:log_follow_open",{loggingData:{postId:this.model.get("id"),tumblelog:t.get("name"),position:i.index()}}),this.popover=new l({model:t,pinnedTarget:this.$el}),this.popover.openPopover()},hideBlogCardPopover:function(e){this.popover&&this.popover.closePopover()},teardown:function(){this.$el.off("mouseenter mouseleave")}});e.exports=u},46010(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(50283),r=i(64147),a=o.extend({defaults:{isScrollEnabled:!1,isAdjustToBrowserHeightEnabled:!1},initialize:function(e){e=s.extend({},e),s.extend(this.attributes,s.pick(e,s.keys(this.defaults))),s.extend(this,s.pick(e,"collection"))},render:function(){return this.get("isScrollEnabled")?(this.$rootContainer=n("<div />").addClass("scroller").appendTo(this.$el),this.scrollBar=new r({el:this.$rootContainer.get(0)}),this.get("isAdjustToBrowserHeightEnabled")&&this.listenTo(this.scrollBar,"resize",this._onScrollResize)):this.$rootContainer=this.$el,this.listenTo(this.collection,"reset",this._onCollectionReset),this.listenTo(this.collection,"add",this._onCollectionAdd),this.listenTo(this.collection,"remove",this._onCollectionRemove),this._renderAllPopovers(),this.scrollBar&&s.defer(s.bind(this._updateScroll,this)),this},remove:function(){this.scrollBar&&(this.stopListening(this.scrollBar),this.scrollBar.remove())},_renderAllPopovers:function(){var e=this.$rootContainer;this.rendered&&(e.empty(),this.collection.each(s.bind(function(t){var i=t.getPopover();this.rendered&&i&&e.append(i.$el)},this)))},_updateScroll:function(){this.rendered&&this.scrollBar&&(this.get("isAdjustToBrowserHeightEnabled")&&this._updateScrollHeight(),this.scrollBar.update(
1))},_updateScrollHeight:function(){var e,t;this.scrollBar&&this.rendered&&(e=n(window).height(),t=this.$rootContainer.get(0).scrollHeight,this.$el.height(Math.min(e-89,t)),this.$rootContainer.scrollTop(t))},_onCollectionAdd:function(e,t,i){var n=e.getPopover().$el,o=t.indexOf(e),r=this.$rootContainer,a=r.children();this.rendered&&(0===a.length||0===o?r.prepend(n):o>=a.length?r.append(n):n.insertBefore(s.get(a,o)),this.scrollBar&&this._updateScroll())},_onCollectionRemove:function(e,t,i){this.scrollBar&&s.defer(s.bind(this._updateScroll,this))},_onCollectionReset:function(e,t){this._renderAllPopovers()},_onScrollResize:function(){this._updateScrollHeight()}});e.exports=a},46209(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, \'\') }\nwith (obj) {\n__p += \'<div class="message-container has-thumbnail"><div class="avatar"><a href="\' +\n__e( blogUrl ) +\n\'" target="_blank" data-js-tumblelog-name="\' +\n__e( name ) +\n\'"><img src="\' +\n__e( avatarUrl ) +\n\'"></a></div><div class="message-bubble" data-js-message-bubble><button class="retry-button" data-js-retry-button>\' +\n__e( __(\'Retry\') ) +\n\'</button> \';\n if (!_.isEmpty(highResUrl) && !_.isEmpty(lowResUrl)) { ;\n__p += \' <a href="\' +\n__e( highResUrl ) +\n\'" data-js-lightbox-url="\' +\n__e( highResUrl ) +\n\'" data-js-lightbox-width="\' +\n__e( originalWidth ) +\n\'" data-js-lightbox-height="\' +\n__e( originalHeight ) +\n\'" data-js-lightbox-lowres-url="\' +\n__e( lowResUrl ) +\n\'"> \';\n } ;\n__p += \' <div class="thumbnail" data-js-thumbnail><div class="conversation-image-loader" data-js-image-loader-container></div><img class="full-width" data-js-message-image src="\' +\n__e( thumbnailImageUrl ) +\n\'" width="\' +\n__e( thumbnailWidth ) +\n\'" height="\' +\n__e( thumbnailHeight ) +\n\'"><div class="overlay" data-js-overlay-container data-js-tumblelog-name="\' +\n__e( name ) +\n\'"><p class="text" data-js-overlay-text></p></div></div> \';\n if (!_.isEmpty(highResUrl) && !_.isEmpty(lowResUrl)) { ;\n__p += \' </a> \';\n } ;\n__p += \' </div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},46520(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<span class="toggle-filter"><div data-subview="filterIcon"></div><div data-subview="filters"></div></span><span class="search-label" for="search-input"></span>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},46556(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(71092),r=i(43038),a=o.extend({class_name:"tumblr_tooltip",template:r,defaults:{selector:"",class_name:"",offset:"50%",placement:"up"},initialize:function(e){this.options=e||{},this.options.selector=n.trim((e.selector||this.defaults.selector)+" "),this.options.class_name=e.class_name||this.defaults.class_name,this.options.offset=e.offset||this.defaults.offset,this.options.placement=e.placement||this.defaults.placement,this.tooltips=n(this.options.selector+"[data-tooltip]"),this.tooltips.on("remove",n.proxy(this.remove,this)),this.tooltips.on("mouseenter",s.bind(this.show,this)),this.tooltips.on("mouseleave",s.bind(this.hide,this))},show:function(e){var t=n(e.currentTarget);this.tooltip_template_data={tooltip:t.data("tooltip")};var i=n(this.tooltip(this.tooltip_template_data));t.append(i),this.setElement(i),this.delegateEvents(),i.removeClass("is_closed").addClass("is_open")},hide:function(e){var t=n(e.currentTarget).find("."+this.class_name);t.removeClass("is_open").addClass("is_closed"),t.on("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd",s.bind(function(e){this.remove(e)},this))},remove:function(e){n(e.currentTarget).remove()},tooltip:function(e){return this.class_name="tooltip_wrapper",this.attributes={text:e.tooltip,placement:this.options.placement,class_name:this.options.class_name,left_css:this.options.offset},this.template(this.attributes)}});e.exports=a},46919(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<p data-js-title>' +\n__e( title ) +\n'</p>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},47405(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(91685),r=o.getComponent("Component"),a=o.extend(r,{isHidden:!0,constructor:function(e,t){r.call(this,e,t),e.ready(s.bind(this.onReady,this))},onReady:function(){this.$player=n(this.player().el_),this.$el=n(this.el()),this.$loader=this.$el.find(".Knight-Rider-loader");var e=s.bind(this.hideLoader,this),t=s.bind(this.showLoader,this);this.player().on("waiting",t),this.player().on("canplay",e),this.player().on("canplaythrough",e),this.player().on("playing",e),this.player().on("seeking",t),this.player().on("seeked",e),this.player().on("ended",e),this.player().on("resolutionchange",t)},createEl:function(){return r.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",innerHTML:'<div class="Knight-Rider-loader centered"><div class="Knight-Rider-bar"></div><div class="Knight-Rider-bar"></div><div class="Knight-Rider-bar"></div></div>'},{"aria-label":"loading"})},hideLoader:function(e){return this.isHidden||(this.$loader.removeClass("animate"),this.$player.removeClass("vjs-loading"),this.isHidden=!0),this},showLoader:function(e){return this.isHidden?(this.$loader.addClass("animate"),this.$player.addClass("vjs-loading"),this.isHidden=!1,this):this},dispose:function(){r.prototype.dispose.apply(this,arguments),this.$player=null,this.$el=null}});e.exports=a},47483(e,t,i){"use strict";var n=i(81515),s=i(19698),o=s.extend({getName:function(){return"permalink"},getLabel:function(){return n("Permalink")},getType:function(){return s.TYPE_HREF},getButtonHref:function(){return this.getPostUrl()}});e.exports=o},47516(e,t,i){var n=i(74692),s=i(71742),o=i(27496),r=i(7419),a=s.extend({name:"SponsoredPosts",initialize:function(){if(this.isScrollEnabled=!1,this.transform=r.get("transform"),this.transform){this.rings=n(),this.ctas=n();var e=n.proxy(this.checkForRingsAndCTAs,this);o.on("AutoPaginator:after",e),o.on("sponsoredPosts:checkRings",e),this.checkForRingsAndCTAs()}},checkForRingsAndCTAs:function(){this.rings=this.rings.add(".sponsored_badge_icon .ring, .recommendation-reason-footer .icon_explore"),this.ctas=this.ctas.add(".tsp-cta-animated").map(function(){var e=n(this);this.$el=e,this.elHeight=e.height(),this.elBottom=e.offset().top+e.height(),this.$aCTA=e.find("a.cta"),this.$aCTA.css("color","#ffffff"),this.$overlay=e.find(".tsp-opacity-overlay");var t=/([\d]+)[^\d]+([\d]+)[^\d]+([\d]+).+/.exec(this.$overlay.css("border-top-color")),i=t[1],s=t[2],o=t[3];return this.overlayColor=i+", "+s+", "+o,this.$aCTA.addClass("cta-color-applied"),this}),!this.isScrollEnabled&&(this.rings.length>0||this.ctas.length>0)&&(this.isScrollEnabled=!0,o.on("DOMEventor:flatscroll",this.onWindowScroll,this))},onWindowScroll:function(e){var t,i,n=e.windowScrollTop;for(t=0,i=this.rings.length;t<i;t++)this.rings[t].style[this.transform]="rotate("+n+"deg)";for(t=0,i=this.ctas.length;t<i;t++)this._setCtaVisual(e,this.ctas[t])},_setCtaVisual:function(e,t){var i,n=e.windowHeight-(t.elBottom-e.windowScrollTop);n<t.elHeight?i=1:n>=0&&n<=200?i=1-n/200:(i=0,this.ctas=this.ctas.not(t),t.$el.removeClass("tsp-cta-animated"));var s=2*(i-.5),o="rgba("+t.overlayColor+", "+s+")";t.$overlay.css({opacity:i,"border-color":o});var r=i<.5?"#FFFFFF":"";t.$aCTA.css("color",r)}});e.exports=a},47525(e,t,i){"use strict";var n=i(74692),s=i(50283),o=i(53855),r=s.extend({template:o,events:{"click [data-filter]":"onFilterClick","click .sort_filter.toggle":"onToggleFilterClick","click .option-radio":"onCheckboxClick","change [type=checkbox]":"onCheckboxChange"},initialize:function(){this.bindEvents()},afterRender:function(){this.onPostTypeChange(),this.onSortChange(),this.onPostRoleChange(),this.onFilterNsfwChange()},bindEvents:function(){this.listenTo(this.model,"change:sort",this.onSortChange),this.listenTo(this.model,"change:post_type",this.onPostTypeChange),this.listenTo(this.model,"change:post_role",this.onPostRoleChange),this.listenTo(this.model,"change:filter_nsfw",this.onFilterNsfwChange)},onPostRoleChange:function(){this.$("#post_role").prop("checked",this.model.get("post_role")!==this.model.defaults.post_role)},onPostTypeChange:function(){this.$(".post_type_filter.active").removeClass("active"),this.$('[data-filter="post_type:'+this.model.get("post_type")+'"]').addClass("active")},onFilterNsfwChange:function(){this.$(".search-nsfw-filter-checkbox-input").prop("checked",this.model.get("filter_nsfw")!==this.model.defaults.filter_nsfw)},onSortChange:function(){this.$(".sort_filter.active").removeClass("active"),this.$('[data-filter="sort:'+this.model.get("sort")+'"]').addClass("active")},onFilterClick:function(e){var t=n(e.currentTarget).data("filter").split(":");this.model.set(t[0],t[1])},onCheckboxChange:function(e){var t=n(e.currentTarget),i=e.currentTarget.id,s=t.data("value"),o=t.prop("checked");this.model.set(i,o?s:this.model.defaults[i])},onCheckboxClick:function(e){e.stopPropagation()},onToggleFilterClick:function(e){var t=n(e.currentTarget).find("[type=checkbox]"),i=t.prop("checked");t.prop("checked",!i).trigger("change")}});e.exports=r},47640(e,t,i){var n=i(55679),s=i(12509),o={};n.each(["assert","clear","constructor","count","debug","dir","dirxml","error","group","groupCollapsed","groupEnd","info","log","markTimeline","profile","profileEnd","table","t
1ime","timeEnd","timeStamp","timeline","timelineEnd","trace","warn"],function(e){var t;o[e]=(t=e,function(){return s.debugMode?window.console[t].bind(window.console).apply(this,arguments):n.noop})}),e.exports=o},47709(e,t,i){var n=i(55679),s=i(74692),o=i(48357).animate,r=i(59034),a=function(){var e={},t=function(e,t,s){s=s||{},this.applyCommand=e,this.inverseCommand=t,this.template=n.template(s.template||'<div class="<%= className %>" title="<%= title %>" data-name="<%= name %>" data-el="<%= el %>" data-command="<%= command %>" data-type="<%= type %>">&nbsp;</div>'),this.controls=s.controls||{},this.controlsOrder=s.controlsOrder||n.keys(this.controls),this.onAction=s.onAction||n.noop,this.keyboardEvents=s.keyboardEvents,i.call(this),this.keyboardEvents&&a.call(this),r.call(this,s)};function i(){var e=this,t=n.reduce(this.controlsOrder,function(e,t){return n.has(this.controls,t)&&e.push(this.template(n.extend({name:t},this.controls[t]))),e},[],this);this.element=s("<div />",{class:"bubbles"}).css({position:"absolute",top:0,left:0}).html(t),this.buttons=s(this.element).find("[data-command]"),this.hide(),this.buttons.on("mousedown",function(e){e.preventDefault()}),this.buttons.on("mouseup",function(t){t.preventDefault(),u.call(e,this)})}function a(){n.each(this.controls,function(e,t){n.has(e,"keyboard")&&this.keyboardEvents.on(e.keyboard,n.partial(c.bind(this),t)),n.has(e,"keyboardInverse")&&this.keyboardEvents.on(e.keyboardInverse,n.partial(l.bind(this),t))},this)}function l(t){n.has(this.controls,t)&&e[t]&&c.call(this,t)}function c(t){var i,s,o,r;n.has(this.controls,t)&&(i=e[t],o=(s=this.controls[t]).command,r=s.el,i&&this.inverseCommand&&"function"==typeof this.inverseCommand?this.inverseCommand(o,r,this):this.applyCommand&&"function"==typeof this.applyCommand&&this.applyCommand(o,r,this),this.onAction(this))}function u(e){c.call(this,s(e).attr("data-name"))}function h(){this.buttons.removeClass("active"),this.buttons.filter(function(){return e[s(this).attr("data-name")]}).addClass("active")}return n.assign(t.prototype,r.prototype),t.prototype.setActives=function(t){e=n.reduce(this.controls,function(e,i,n){var o=i.command,r=(i.el||"").toUpperCase(),a=function(e,t){var i=!1;return s.each(e,function(e,n){if(n===t||void 0!==n.nodeName&&n.nodeName===t)return i=!0,!1}),i}(t,r),l=!1;try{l=document.queryCommandEnabled(o)&&document.queryCommandState(o)}catch(e){l=!1}return e[n]=l||a,e},{},this),h.call(this)},t.prototype.open=function(e,t){if(!this.isShown){var i=s(this.element).children("[data-command]"),n=s(this.element).find(".shim");s(this.element).css({width:"auto"}),n.remove(),i.removeAttr("style")}this.showOverTarget(e,t)},t.prototype.closeWithShim=function(e,t,i,r){var a=s(this.element),l=s(e),c=s('<div class="shim">&nbsp;</div>').get(0),u=n.has(o,"Promise");i=u?i:200;var h=a.width();a.css("width",h+t);var d=h/2-(l.position().left+t/2);l.before(c).hide();var p=s(c).offset().left+d,g=s(c).offset().top;this.isAnimating=!0,n.forEach(this.buttons,function(e,t){o(e,"stop"),o(e,{opacity:0},{duration:.5*i})}),o(a,{left:"+="+d},{easing:"ease",duration:i});var f=o(c,{width:t},{easing:"ease",duration:i}),m=n.bind(function(){n.isFunction(r)&&r.call(this,p,g),this.isAnimating=!1,this.hide()},this);u?f.then(m):n.delay(m,i)},t.prototype.getActiveStates=function(){return e},t}();e.exports=a},48256(e,t,i){"use strict";var n,s=i(59753);e.exports={getInstance:function(){return n||(n=new s),n},hasInstance:function(){return!!n}}},48332(e,t,i){"use strict";var n=i(91685),s=i(64792),o=n.getComponent("MuteToggle"),r=n.getComponent("ClickableComponent"),a=n.extend(o,{constructor:function(e,t){o.prototype.constructor.call(this,e,t),this.addListeners(e)},addListeners:function(e){this.on("click",this.onMuteClick)},onMuteClick:function(){this.player_.trigger("muteClicked")},createEl:function(){var e="vjs-mute-control vjs-control";return this.player_.options_.muted&&(e+=" vjs-vol-0"),r.prototype.createEl.call(this,"div",{className:e,innerHTML:s()},{})},update:function(){var e=this.player_.volume(),t=3;0===e||this.player_.muted()?t=0:e<.33?t=1:e<.67&&(t=2),this.controlText(this.player_.muted()?"Unmute":"Mute");for(var i=0;i<4;i++)n.removeClass(this.el_,"vjs-vol-"+i);n.addClass(this.el_,"vjs-vol-"+t)}});e.exports=a},48374(e,t,i){"use strict";var n=i(55679),s=i(69107),o=i(44579),r=s.extend({className:"conversation-compose-plugin conversation-compose-plugin--blog-selector",defaults:n.defaults({currentTumblelog:null},s.prototype.defaults),renderWithTemplate:n.noop,initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults)));var t=n.extend({className:"conversation-compose-plugin-blog-selector",showName:!1,showCaret:!1},n.pick(e,"collection","currentTumblelog","popoverOptions"));this.blogSelectorView=new o(t)},afterRender:function(){this.blogSelectorView.render(),this.$el.html(this.blogSelectorView.el)},getName:function(){return"blog-selector"},getBlogSelector:function(){return this.blogSelectorView}});e.exports=r},48391(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<span class=\"text\">' +\n((__t = ( text )) == null ? '' : __t) +\n'</span>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},48442(e,t,i){"use strict";var n=i(55679),s={loadedLogs:[],startLogs:function(e){n.each(e,function(e){var t=e.start();this.loadedLogs.push(t.logKey)},this)},startLog:function(e){this.startLogs([e])}};e.exports=s},49353(e,t,i){"use strict";var n=i(97583).extend({logKey:"gifsearch_interactions",logOptions:{init_event:!1},events:{"gifsearch:*":"handleEvent"},logEnv:{location:document.location.pathname},handleEvent:function(e,t){"unload"!==e&&this.log(e,t)}});e.exports=n},49387(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(71742),r=i(27496),a=o.extend({name:"MessagingShareLogger",defaults:{namespace:"postchrome-interactions",platform:"web",isDebugEnabled:!1},initialize:function(e){e=s.extend({},e),s.extend(this.attributes,s.pick(e,s.keys(this.defaults)))},logShareIntent:function(e,t){this._logIt("share:intent",{postId:e,postBlogUuid:t})}
1,logExternalNetworkClicked:function(e){var t=e.getName(),i=e.getPostModel(),o=s.extend({},this._getCommonExternalShareData(e),{viewType:e.getType()});this._logIt("share:external",o),r.trigger("dashboard-share:"+t),e.isTypePopup()&&!s.isEmpty(i)&&n.ajax({url:"/svc/share/"+t,method:"POST",withFormKey:!0,data:{post_id:i.get("post_id"),tumblelog_name:i.get("tumblelog_name"),share_fallback:!0}})},logExternalNetworkShareSuccess:function(e){this._logIt("share:external:success",this._getCommonExternalShareData(e))},logExternalNetworkShareFail:function(e){this._logIt("share:external:fail",this._getCommonExternalShareData(e))},_logIt:function(e,t){t=t||{},s.extend(t,{platform:this.get("platform")}),r.trigger(this.get("namespace")+":"+e,{loggingData:t})},_getCommonExternalShareData:function(e){var t=e.getPostModel(),i={network:e.getName()};return s.isEmpty(t)||s.extend(i,{postId:t.get("post_id"),tumblelogName:t.get("tumblelog_name")}),i}});e.exports=a},49430(e,t,i){var n=i(3226);e.exports=function(e){Promise.resolve().then(function(t){try{e(i(26124))}catch(e){n(e,"post-form-builder")}}.bind(null,i)).catch(i.oe)}},49444(e,t,i){"use strict";var n=i(71092),s=i(27496),o=i(74692),r=i(55679),a=n.extend({className:"point-follow",styles:{position:"fixed",top:-75,left:-75,height:150,width:150,"z-index":999,transform:"translate3d(-999px,-999px,0)"},initialize:function(e){e=e||{},this.styles=r.extend({},this.styles,e.styles),this.bindEvents(),this.render()},render:function(){return this.$el.css(this.styles),this.$el.appendTo("body"),this},bindEvents:function(){o(window).on("mousemove.pointFollow",r.bind(this.onMouseMove,this)),this.listenTo(s,"DOMEventor:flatscroll",this.onWindowScroll,this)},onMouseMove:function(e){this.mousePosX=e.clientX,this.mousePosY=e.clientY},onWindowScroll:function(){this.timeout&&clearTimeout(this.timeout),this.timeout=r.delay(r.bind(this.onScrollStop,this),350),this.$el.css("transform","translate3d("+this.mousePosX+"px,"+this.mousePosY+"px, 0)")},onScrollStop:function(){this.$el.css("transform","translate3d(-999px,-999px, 0)"),this.timeout=null}});e.exports=a},49737(e,t,i){"use strict";var n=i(44890),s=i(44384),o=i(84549),r=i(23049),a=i(16268),l=i(64875),c=i(27496),u=s.extend({hasSubViews:{media:o,expand:a,body:r},events:{tumblelogPopover:"__popoverLaunched"},limitHeightTo:400,limitBuffer:150,initialize:function(e){s.prototype.initialize.call(this,e),this.listenTo(c,"discover:inline-images:ready",this.limitHeight)},attachedToDOM:function(){this.limitHeight(),s.prototype.attachedToDOM.apply(this,arguments)},limitHeight:function(){if(this.limitHeightTo&&n.bool("truncate_all_brick_posts")){var e=this.$el.height();if(this.desiredHeight&&e<=this.desiredHeight)return;if(this.desiredHeight=e,e>this.limitHeightTo+this.limitBuffer)new l({parent:this}).render()}},__popoverLaunched:function(e){this.subViews.expandContent&&this.subViews.expandContent.expand()}});e.exports=u},49746(e,t,i){"use strict";var n=i(44384),s=i(41665),o=i(27496),r=i(97030),a=n.extend({mixins:[s,r],events:{"click .post_tag":"_checkIfPremiumPost"},_checkIfPremiumPost:function(e){this.model.get("pt")&&o.trigger("useraction:explore_click:tag_click",{model:this.model,loggingData:this.loggingData({userAction:"tag_click"})})}});e.exports=a},49773(e,t,i){"use strict";var n=i(55679),s=i(27513),o=i(5217),r=s.extend({model:o,previousFrom:function(e){return this.rotateFrom(e,-1)},nextFrom:function(e){return this.rotateFrom(e,1)},rotateFrom:function(e,t){for(var i=(n.isNumber(e)?this.at(e):this.findWhere({mediaUrl:e}))||this.sample(),s=this.indexOf(i)+t;s<0;)s+=this.length;return this.at(s%this.length)}});e.exports=r},49779(e,t,i){"use strict";var n=i(55679),s=i(71742),o=i(11092),r=s.extend({name:"Dialog",initialize:function(e){this.dialogView=o,this.options=n.extend({},this.defaults,e)},alert:function(e,t,i){return this.dialogView.alert.call(this.dialogView,e,t,i)},confirm:function(e,t,i,n,s){return this.dialogView.confirm.call(this.dialogView,e,t,i,n,s)},dialog:function(e){return this.dialogView.dialog.call(this.dialogView,e)},isActive:function(e){return this.dialogView.isActive.call(this.dialogView,e)},close:function(e){return this.dialogView.close.call(this.dialogView,e)},getDialogEl:function(){return this.dialogView.getDialogEl.call(this.dialogView)},__:function(e){return this.dialogView.__.call(this.dialogView,e)}});e.exports=new r},50052(e,t,i){var n=i(55679),s=i(74692),o=i(71742),r=i(57982),a=i(54892),l=o.extend({name:"MessagingImageUploader",defaults:{imageUploadMaxBytes:null,file:null},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults)))},uploadImage:function(){var e=new s.Deferred,t=this.get("imageUploadMaxBytes"),i=this.get("file"),o=function(){e.resolve.apply(this,arguments)},l=function(){e.reject.apply(this,arguments)};return i?n.get(i,"type","").match(/image\/(jpg|jpeg|png|gif)/i)?n.get(i,"size")>t?e.reject({type:"size"}):(a.read(i).then(function(e){r.load(e.objectUrl||e.base64).then(o,l)}),e):e.reject({type:"format"}):e.reject()}});e.exports=l},50226(e,t,i){var n=new(i(98052))({EventClass:i(7256),event_payload_name:"payload",event_filter:function(){return!1},endpoint:function(){return[window.location.protocol,"//",window.location.hostname,"/services/cslog"].join("")}});e.exports=n},50283(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(21391),r=i(21189),a=i(20341),l=i(30190),c=i(51954),u=i(71092);function h(e,t,i){return n.isFunction(e)&&(e=e(t,i)),e instanceof s?e:t.$(e)}var d=u.extend({rendered:!1,disposed:!1,keepElement:!1,_setup:function(e){e||(e={});var t=n.extend({},n.result(this.constructor.__super__,"defaults"),n.result(this,"defaults"));n.extend(t,n.pick(e,n.keys(t))),this.attributes={},this.set(t),this.changed={};var i=this.render;this.render=n.bind(function(){this._beforeRender.apply(this,arguments),this.beforeRender.apply(this,arguments);var e=i.apply(this,arguments);return this.afterRender.apply(this,arguments),this._afterRender.apply(this,arguments),e},this);var s=this.remove;this.remove=n.bind(function(){if(this.disposed)return this;this._beforeRemove.apply(this,arguments),this.beforeRemove.apply(this,arguments);var e=s.apply(this,arguments);return this.afterRemove.apply(this,arguments),this._afterRemove.apply(this,arguments),e},this),this.subviews=n.extend({},this.subviews,e.subviews)},initialize:n.noop,_registerSubview:function(e){return this._subviews||(this._subviews=[]),this._subviews.push(e),e},appendSubview:function(e,t){return n.isString(t)&&(t=this.$(t)),this._registerSubview(e),e.render(),(t||this.$el).append(e.el),e},removeSubviews:function(){var e=n.flatten(this._subviews);e&&(n.invoke(e,"remove"),delete this._subviews)}
1,renderSubviews:function(){this.subviews&&n.forEach(this.subviews,function(e,t){e instanceof o.View?this.renderSubview(e,{name:t}):e.collection?this.renderCollectionSubviews(t):this.renderSubview(t)},this)},_createDefaultContainerFunction:function(e){return n.bind(function(){return this.$('[data-subview="'+e+'[]"]')},this)},_createDefaultPrepareViewFunction:function(e){var t=this.subviews[e];return n.bind(function(i,n){var s=new t.constructor(n);return s.$el.attr("data-subview",e),i.append(s.$el),s},this)},renderCollectionSubviews:function(e){var t=this.subviews[e];if(t){var i=t.container||this._createDefaultContainerFunction(e),n=t.prepareView||this._createDefaultPrepareViewFunction(e),s=t.options||{},o=this.createCollectionSubviewRenderer(t.collection,i,n,s,e);this.rendered?o():this.once("rendered",o,this)}},renderSubview:function(e,t){var i,s,r,a;if(n.isString(e)){if(a=e,!(e=this.subviews[a]))return void 0;i=e.container||'[data-subview="'+a+'"]',r=e.options||{},s=e.prepareView||function(t,i){if(!n.isEmpty(t)){var s=new e.constructor(i);return s.$el.attr("data-subview",a),t.replaceWith(s.$el),s}}}else e instanceof o.View&&(t||(t={}),a=t.name||"",i=t.container||'[data-subview="'+a+'"]',r=t.options||{},s=t.prepareView||function(t){return e.$el.attr("data-subview",a),t.replaceWith(e.$el),e});var l=this.createSubviewRenderer(i,s,r,a);this.rendered?l():this.once("rendered",l,this)},createSubviewRenderer:function(e,t,i,s){return n.bind(function(){if(this.el){i=i||{},n.isFunction(i)&&(i=i.call(i,this));var o=h(e,this,s);if(!n.isEmpty(o)){var r=t.call(this,o,i);s&&n.set(this,s,r),r.render(),this._registerSubview(r)}}},this)},createCollectionSubviewRenderer:function(e,t,i,s,r,a,l){var c;return n.bind(function(){if(this.el){var u=0;
1if(r&&(a?u=this[r].length:this[r]=[]),!0===e&&(e=this.collection),n.isFunction(e)&&(e=e(this)),e instanceof o.Collection&&(e=e.models),!n.isEmpty(e)){var d=h(t,this,r);n.isEmpty(d)||(a||(d=(c=d).clone()),n.forEach(e,function(e,t){var o;(o=n.isFunction(s)?s.call(s,this,e)||{}:n.extend({},s)).model||(o.model=e);var a="";r&&(a=r+"["+(u+t)+"]"),l&&n.extend(o,l),this.createSubviewRenderer(d,i,o,a).call(this)},this),a||c.replaceWith(d))}}},this)},_beforeRender:n.noop,beforeRender:n.noop,render:function(){return!this.disposed&&(this.renderWithTemplate(),this)},afterRender:n.noop,_afterRender:function(){this.renderSubviews(),this.rendered=!0,this.trigger("rendered",this),this._verifySubviewsRendered()},getTemplateData:function(){var e=a(this);return this.model&&(e.model=a(this.model)),this.collection&&(e.collection={items:a(this.collection),length:this.collection.length}),e},renderWithTemplate:function(e){if(n.isUndefined(this.template))throw new Error("Template function needed.");var t;return t=n.isFunction(this.template)?this.template(e||this.getTemplateData()):this.template,this.$el.html(t),this},afterRenderSubviews:n.noop,_verifySubviewsRendered:function(){var e=n.bind(function(){this.afterRenderSubviews(),this.trigger("renderedSubviews")},this),t=n.reject(this._subviews,function(e){return!0===e.rendered||!0===e._rendered});n.isEmpty(t)?e():r.map(t,function(e){return r.promise(n.partial(function(t,i){e.once("rendered",t)},e))}).then(e)},_beforeRemove:function(){this.removeSubviews()},beforeRemove:n.noop,remove:function(){return this.keepElement?(this.undelegateEvents(),this.stopListening()):u.prototype.remove.apply(this,arguments),this},afterRemove:n.noop,_afterRemove:function(){n.forEach(["el","$el","options","model","collection","subviews","_subviews","defaults","attributes"],n.bind(function(e){this[e]&&delete this[e]},this)),this.rendered=!1,this.disposed=!0}},{subviewWithOptions:function(e){return l.call(null,this,e)}});c.mixin.applyTo(d.prototype),e.exports=d},50506(e,t,i){"use strict";var n=i(55679),s=i(17604).sprintf,o=i(95870),r=i(95921).truncateLongStrings,a=i(9553);function l(){}l.prototype.genericFieldMap={one:"title",two:"url",three:"caption",thumbnail:"thumbnail",excerpt:"excerpt",author:"author"},l.prototype.typeAttributes={title:"",url:"",caption:"",excerpt:"",author:""},l.prototype.allowAnswerFields=["caption"],l.prototype.generateTweetText=function(e,t){var i,n=this.getHtmlStripped("title"),a=this.getHtmlStripped("url"),l=this.getHtmlStripped("caption");return l=l.replace(/[\r\n\s]*\[\[MORE\]\].*$/gi,""),i=n&&l?s("%s - %s",n,l):n||l||o.parseUrl(a).host||"",r(i,t)},l.prototype.editorField="three",l.prototype.typeAttributes={title:"",url:"",excerpt:"",author:""},l.prototype.resetPreserveFields=["caption","tags"],l.prototype.resetAttributes=["title","url","thumbnail","excerpt","author"],l.prototype.softReset=function(e){e.apply(this,n.rest(arguments)),n.isEmpty(this.get("thumbnail"))||"new"===this.get("mode")||this.set("remove_thumbnail",1)},l.prototype.serializeForServer=function(e){var t=e.apply(this,n.rest(arguments));return this.get("remove_thumbnail")&&(t.remove_thumbnail=this.get("remove_thumbnail")),n.extend(t,{author:this.getAttributeFromGeneric("author"),excerpt:this.getAttributeFromGeneric("excerpt")}),t},l.prototype.validate=function(e,t,i){var n=[];return t.loading&&n.push("Loading OpenGraph data."),(!t.url||t.url.length<1)&&n.push("No url."),a.isUrl(t.url)||n.push("Not a valid URL"),e.call(this,t,{errors:n})},e.exports=l},50681(e,t,i){"use strict";var n=i(80160).extend({idAttribute:"channelId",defaults:{channelId:null,data:null}});e.exports=n},50695(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n\n if (errors) { ;\n__p += ' ';\n _.each(errors, function(error) { ;\n__p += ' <div class=\"error-message\"><div class=\"error-text\"> ' +\n((__t = ( error.error )) == null ? '' : __t) +\n' </div></div> ';\n }); ;\n__p += ' ';\n } else { ;\n__p += ' <div class=\"error-message\"><div class=\"error-text\"> ' +\n((__t = ( __('Oops. There was an error. Try again.') )) == null ? '' : __t) +\n' </div></div> ';\n } ;\n\n\n}\nreturn __p\n}").apply(void 0,r(s))},51007(e){e.exports=function(e){return'<noscript data-subview="'+e+'"></noscript>'}},51342(e,t,i){var n=i(55679),s=i(74692),o=i(3211),r=function(){var e=["P","FIGURE","H2","BLOCKQUOTE","UL","OL","PRE"],t=["FIGURE","IFRAME","IMG","HR"],i=function(t){return n.contains(e,t.nodeName)},r=function(e){return e&&n.contains(t,e.nodeName)},a=function(e){return"false"===s(e).attr("contenteditable")},l=function(e){this.sanitizeConfig=e};function c(e){!function(e){e.normalize();for(var t=document.createTreeWalker(e,NodeFilter.SHOW_TEXT,null,!1);t.nextNode();){var i=t.currentNode;s(i).parent().is(e)&&""!==i.nodeValue.trim()&&s(i).wrap("<p>")}}(e),s(e).children().each(function(){var e=s(this).get(0),t="DIV"===e.n
1odeName,n="HR"===e.nodeName;i(e)||r(e)||t||n||s(this).wrap("<p>")})}function u(e){return n.filter(s(e).find("*").toArray(),function(e){return i(e)||a(e)})}function h(t){if(!a(t)){var i=s(t).children(e.join()).toArray(),o=!1;n.each(i,function(e){o||(s(e).unwrap(),o=!0),h(e)})}}function d(t){var i,o=(i=t,n.filter(i,function(t){return n.contains(e,t.nodeName)}));o.shift();for(var r=o.shift();r&&!s(r).is("[contentEditable]");){var a=r.parentNode;s(r).contents().unwrap(),c(a),r=o.shift()}}function p(e,i){var n=s(e).text();i&&(n=n.replace(/\n|\r/gm,"").trim());var o=e&&"HR"===e.nodeName;return""===n&&!r(e)&&!function(e){return s(e).find(t.join()).length}(e)&&!o}function g(e){var t=document.implementation.createHTMLDocument("");return t.body.innerHTML=e,t.body}return l.prototype.flattenBlocksDown=function(e,t){!function(e,t){e.normalize(),t||c(e);var o=u(e);!o.length&&t||(t&&(c(e),o=u(e)),s(e).empty(),n.each(o,function(t){var o=n.some(s(t).children().toArray(),function(e){return i(e)});(a(t)||!p(t)&&!o)&&s(e).append(t)}))}(e,t)},l.prototype.unBlock=function(e){h(e)},l.prototype.unwrapParentBlocks=function(e){d(e)},l.prototype.scrubSpansAndBadAttrs=function(e,t){return function(e){if(e&&e.length){for(var t=e.shift(),i=!1,o=["style","dir"];t;){var r=s(t).find("span").toArray();"SPAN"===t.nodeName&&r.push(t),r.length&&(i=!0),s(r).contents().unwrap(),n.each(o,function(e){s(t).removeAttr(e),s(t).find("["+e+"]").removeAttr(e)}),t=e.shift()}return i}}(e)},l.prototype.blockifyInlineNodes=function(e){c(e)},l.prototype.inlinify=function(e,t){!function(e,t){var i=u(e);n.each(i,function(e){s(e).find("li").contents().unwrap(),t&&(s(e).find("br:last-child").remove(),s(e).append("<br>")),s(e).contents().unwrap()})}(e,t)},l.prototype.getBlockNodes=function(e){return u(e)},l.prototype.isEmptyElement=function(e,t){return p(e,t)},l.prototype.filterHTML=function(e){var t,i,n=g(e),s=new o(this.sanitizeConfig).clean_node(n);return(t=s,(i=document.implementation.createHTMLDocument("")).body.appendChild(t.cloneNode(!0)),i.body).innerHTML.replace(/[<]p[>][ ]*[<]\/p[>]/g,"")},l.prototype.filterPlaintext=function(e,t){var i=n.escape(e);return i=(i=i.replace(/\r\n/g,"\n")).replace(/\r/g,"\n"),t&&(i=i.replace(/\n([ ]*\n)+/g,"</p><p>")),i=i.replace(/\n/g,"<br>"),t&&(i="<p>"+i+"</p>"),i},l.prototype.convertToBrowserSpaces=function(e){return e.replace(/[ ]{2}/g,"  ").replace(/[ ]$/," ")},l.prototype.sanitizeIFrames=function(e){var t=g(e);return s(t).find("iframe").each(function(){s(this).attr("data-original-src",s(this).attr("src")),s(this).attr("src","javascript:''")}),t.innerHTML},l.prototype.unSanitizeIFrames=function(e){var t=g(e);return s(t).find("iframe[data-original-src]").each(function(){s(this).attr("src",s(this).attr("data-original-src")),s(this).removeAttr("data-original-src")}),t.innerHTML},l}();e.exports=r},51347(e,t,i){var n=i(57892);e.exports=n},51382(e,t,i){"use strict";var n=i(55679),s=i(27496),o=i(80160),r=i(27513),a=o.extend({urlRoot:"/svc/search/blog_search",defaults:{next_offset:0,limit:10,sort:"CREATED_DESC",post_type:"ANY",term:"",unsetTerm:"",post_role:"ANY",filter_nsfw:!1,showOriginalPostsSwitch:!0,showNsfwSwitch:!1},initialize:function(){this.listenTo(this,"change:unsetTerm",this.onUnsetTermChange),this.listenTo(s,"peeprsearch:change:term",this.onTermSelect),this.listenTo(this,"change:term change:sort change:post_type change:post_role",this.resetSearch),this.posts=new r},resetSearch:function(){this.set(n.pick(this.defaults,["limit","next_offset"])),this.posts.reset(),this.trigger("search:reset")},reset:function(){this.posts.reset(),this.set(this.defaults),this.trigger("reset")},url:function(){var e=this.get("term").replace(/#/g,"");return this.urlRoot+"/"+this.get("blogname")+"/"+e},onTermSelect:function(e){this.search(e.term)},onUnsetTermChange:function(){s.trigger("peeprsearch:change:unsetTerm",{term:this.get("unsetTerm")})},search:function(e){(e=e||this.get("unsetTerm")).length&&this.set("term",e)},fetch:function(){this.get("next_offset")<0||o.prototype.fetch.apply(this,arguments)},parse:function(e){return this.posts.length?n.each(e.response.posts,function(e){this.posts.add(e)},this):this.posts.reset(e.response.posts),delete e.response.posts,e.response},sync:function(e,t,i){"read"===e&&(i.data=this.pick("next_offset","limit","sort","post_type","post_role","filter_nsfw")),o.prototype.sync.apply(this,arguments)}});e.exports=a},51805(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(50283),r=i(70305),a=i(77594),l=i(29758),c=i(24516),u=i(94625),h=i(96152),d=i(55147),p=o.extend({className:"gif-search-container",template:d,mixins:[a],keycommands:{"keydown:tab":"_onKeyPressTab","keydown:shift+tab":"_onKeyPressShiftTab"},subviews:{searchInput:{constructor:l,options:function(e){return{eventBus:e.eventBus,keyboardManager:e.keyboardManager,keyboardNamespace:"gifsearch:input"}}},searchResults:{constructor:c,options:function(e){return{imageWidth:e.get("imageWidth"),selectedImageUrl:e.get("selectedImageUrl"),loadFullImageBeforeSelect:e.get("loadFullImageBeforeSelect"),eventBus:e.eventBus,keyboardManager:e.keyboardManager,keyboardNamespace:"gifsearch:results"}}},searchMessage:{constructor:u,options:function(e){return{eventBus:e.eventBus}}}},defaults:{imageWidth:null,loadFullImageBeforeSelect:!0,resultLimit:200,selectedImageUrl:"",query:null,loggingContext:null,focusIndex:0,tabbingView:null},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","collection")),this.keyboardManager=new r({allowMultipleActiveViews:!0}),this.noResults=[s("Nothing turned up. Bummer."),s("Looked around but didn't see anything about that."),s("Sadly, nothing."),s("Tragically, nothing."),s("Welcome to the void. There is nothing here."),s("We found nothing. Here it isn't."),s("Couldn't find that. Please, don't be upset. Please."),s("Sincerely, we found nothing."),s("Maybe try a similar search but use different words? Du
1nno.")],this.listenTo(this,"change:query",this._onChangeQuery),this.listenTo(this.eventBus,"image:tag",function(e,t){this.set("query",e),this.searchInput.setValue(this.get("query"))}),this.listenTo(this.eventBus,"showHiddenResults",function(){this.searchResults.setCollection(this.get("currentResults")),this.hasResults()&&this.searchMessage.hide()})},afterRenderSubviews:function(){this.listenTo(this,"change:focusIndex",this._onChangeFocusIndex),this.listenTo(this.searchInput,"focus",this._onChangeFocusView),this.listenTo(this.searchResults,"focus",this._onChangeFocusView),this.listenTo(this.searchInput,"userQueryChanged",function(e){this.setQuery(e)}),this.loader=new h({$container:this.$el,type:"bar",classModifiers:"top",loading:!1}),n.isString(this.get("query"))&&(this._onChangeQuery(this,this.get("query")),this.searchInput.setValue(this.get("query"))),n.defer(n.bind(function(){this.rendered&&this.searchInput.focus()},this)),this._focusViews=[this.searchInput,this.searchResults],this._tabbableViews=[this.searchResults],this.keyboardManager.add("gifsearch:main",this),this.focusKeys()},beforeRemove:function(){this.keyboardManager.remove("gifsearch"),this.currentQuery&&this.currentQuery.reject()},hasResults:function(){return!(n.isEmpty(this.get("currentResults"))||n.isEmpty(this.get("currentResults").models))},dismiss:function(){this.trigger("dismiss")},_onKeyPressTab:function(e){e.preventDefault(),this._moveFocusDown()},_onKeyPressShiftTab:function(e){e.preventDefault(),this._moveFocusUp()},_moveFocusUp:function(){var e=this.get("tabbingView");e&&e.set("isFocused",!1),this.set("focusIndex",Math.max(0,this.get("focusIndex")-1))},_moveFocusDown:function(){var e=this._focusViews||[];this.set("focusIndex",Math.min(e.length-1,this.get("focusIndex")+1))},_onChangeFocusView:function(e){var t=this._focusViews,i=n.indexOf(t,e);this.set("tabbingView",n.contains(this._tabbableViews,e)?e:null),this.set("focusIndex",i)},_onChangeFocusIndex:function(e,t){var i=n.get(this._focusViews,t);this.set("tabbingView",n.contains(this._tabbableViews,i)?i:null),n.result(i,"focus")},_onChangeQuery:function(e,t){n.isString(t)&&(this.rendered&&this.loader.set("loading",!0),this.currentQuery&&this.currentQuery.reject(),this.searchResults.cancelPreloads(),this.searchResults.cancelFullImageLoads(),this.currentQuery=this.collection.fetchGifs(t,this.get("resultLimit"),this.get("loggingContext")),this.currentQuery.promise.then(n.bind(function(e){if(this.set("currentResults",e.media),this.rendered){this.loader.set("loading",!1);var t=e.get("message");t&&(t.header||t.body)?this.searchMessage.setMessage(t.header,t.body,this.hasResults()):(this.searchResults.setCollection(this.get("currentResults")),this.hasResults()?this.searchMessage.hide():this.searchMessage.setMessage("",n.sample(this.noResults),!1))}this.currentQuery=null},this)))},setQuery:function(e){this.set("query",e)},getQuery:function(){return this.get("query")}});e.exports=p},51904(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(38578),r=i(62633),a=s.extend({mixins:[o],template:r,initialize:function(e){n.extend(this.attributes,e)},render:function(){return this.set("install_url",this.get("install_url")+"?referrer=mobile_gate"),this.set("open_url",this.get("open_url")+"&referrer=mobile_gate"),this.$el.html(this.template(this.toJSON())),this}});e.exports=a},51954(e,t,i){"use strict";var n=i(55679),s=i(21391),o=i(28724),r=s.Model.prototype,a={get:r.get,has:r.has,set:r.set,unset:r.unset,clear:r.clear,hasChanged:r.hasChanged,changedAttributes:r.changedAttributes,previous:r.previous,toJSON:r.toJSON,toggle:function(e){this.set(e,!this.get(e))},_validate:n.constant(!0)},l=new o(n.extend({},a,{defaults:n.extend({},s.Events)}));e.exports={props:a,mixin:l}},52181(e,t,i){"use strict";var n=i(55679),s=i(48357).animate,o=i(71092),r=i(67127),a=i(64491),l=i(98237),c=i(38578),u=o.extend({className:"post-forms-glass",mixins:[a,l,c],initialize:function(e){this.options=e=n.extend({active:!1,visible:!1},e),this.set({active:!!e.active,visible:!!e.visible}),this.get("visible")?this.$el.css({opacity:1,display:"block"}):this.$el.css({opacity:0,display:this.get("active")?"block":"none"}),this.listenTo(this,{"change:active":this._changeActive,"change:visible":this._changeVisible})},show:function(e){return this.set("active",!(null!=e&&!e)),this.attributes.visible&&this._showing?this._showing:(this.attributes.visible=!0,this._show())},hide:function(e){return this.set("active",!(null==e&&!e)),!this.attributes.visible&&this._hiding?this._hiding:(this.attributes.visible=!1,this._hide())},_show:function(){return this._showing=s(this.$el,{opacity:1},{duration:r(150),display:"block"})},_hide:function(){return this._hiding=s(this.$el,{opacity:0}
1,{duration:r(150),display:this.get("active")?"block":"none"})},_changeActive:function(e,t){t?this.$el.addClass(this.className+"_active active"):(this.$el.removeClass(this.className+"_active active"),!this._changing||n.has(this.changed,"visible")||this.get("visible")||this.$el.css("display","none"))},_changeVisible:function(e,t){t?(this.$el.addClass(this.className+"_visible visible"),this._show()):(this.$el.removeClass(this.className+"_visible visible"),this._hide())},render:function(){return this}});e.exports=u},52376(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"post-tab-switching\"><div class=\"tab-post-types count-' +\n__e( icons.length ) +\n'\"> ';\n _.forEach(icons, function(icon, i) { ;\n__p += ' <div class=\"tab-post-type item\" data-index=\"' +\n__e( i ) +\n'\" data-post-type=\"' +\n__e( icon.name ) +\n'\"><div class=\"post-type-icon icon-' +\n__e( icon.name ) +\n'\"><i class=\"post-type-icon-overlay\"></i></div><div class=\"post-type-name\"><span class=\"post-type-name-span\">' +\n__e( icon.label ) +\n'</span></div></div> ';\n }); ;\n__p += ' </div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},52394(e,t,i){var n=i(71092),s=i(27496),o=n.extend({events:{click:"_onLinkClick"},initialize:function(e){e&&e.postModel?this.postModelJSON=e.postModel.toJSON():this.postModelJSON=""},_onLinkClick:function(){this._triggerEvent("buttonClick")},_triggerEvent:function(e){s.trigger("CTAButton:"+e,{loggingData:{postData:this.postModelJSON,userAction:"action_click"}})}});e.exports=o},52831(e,t,i){"use strict";var n=i(55679),s=i(71742),o=i(60525),r=s.extend({name:"MessagingUnreadManager",defaults:{dataChannelKey:"mention_key",overridesExpirationInMs:500},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"channels"));var t=this.channels.map(function(e){return{channelId:e.get("uuid")}});this.unreadCollection=new o(t),this.unreadCollectionOverrides=new o(t),this.listenTo(this.unreadCollection,"change:data",this._onUnreadCollectionChange)},setData:function(e){this._pruneOverrides(),this._updateUnreadCollection(e),this.unreadData=e},setConversationModelCount:function(e,t){var i,n=e.get("id"),s=e.get("participantUuid"),o=this.unreadCollectionOverrides.findWhere({channelId:s});o&&((i=o.get("data")||{})[n]=t,o.set({data:i,updateDate:new Date}),this._updateUnreadCollection(this.unreadData))},_getOverridesData:function(){var e=this.get("dataChannelKey");return this.unreadCollectionOverrides.reduce(function(t,i){var s=i.get("data"),o=this.channels.get(i.get("channelId")).get(e);return n.isEmpty(s)||(t[o]=s),t},{},this)},_pruneOverrides:function(){var e=new Date,t=this.get("overridesExpirationInMs");this.unreadCollectionOverrides.each(function(i){var s=i.get("updateDate");n.isDate(s)&&e-s>t&&i.set({updateDate:null,data:null})})},_updateUnreadCollection:function(e,t){var i=this._getOverridesData();this.unreadCollection.each(function(t){var s=this.channels.get(t.get("channelId")).get(this.get("dataChannelKey")),o=n.get(e,s),r=n.get(i,s);n.isEmpty(r)||(o=n.merge({},o,r)),t.set("data",o)},this)},_onUnreadCollectionChange:function(e){var t=e.get("data")||null,i=e.previous("data")||null,s=this.channels.get(e.get("channelId"));this.trigger("change:channel",s,t),n.each(t,function(e,t){n.get(i,t)!==e&&this.trigger("change:conversation",t,e,s)},this)}});e.exports=r},53010(e,t,i){var n=i(55679),s=i(74692),o=i(21391);function r(e,t){this.options=n.extend({preventInteraction:!1,ignoreSelectors:[]},t),this._onClick=n.bind(this._onClick,this,e),document.addEventListener("click",this._onClick,!0)}r.prototype._isForcedInsideTarget=function(e){return!n.isEmpty(this.options.ignoreSelectors)&&!n.isEmpty(e.closest(this.options.ignoreSelectors.join(",")))},r.prototype._onClick=function(e,t){var i=s(t.target);e===t.target||s.contains(e,t.target)||this._isForcedInsideTarget(i)?this.trigger("click:inside",t):(this.trigger("click:outside"),this.options.preventInteraction&&(t.preventDefault(),t.stopPropagation()))},r.prototype.remove=function(){return document.removeEventListener("click",this._onClick,!0),this.off(),this},n.extend(r.prototype,o.Events),e.exports=r},53346(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<nav class=\"nav-site-sections\"><a href=\"/dashboard\" class=\"nav-item with-icon\"><span class=\"nav-text nav-item-dashboard\">' +\n__e( __('Dashboard') ) +\n'</span></a><a href=\"/likes\" class=\"nav-item with-icon\"><span class=\"nav-count\">';\n if(parseInt(likes, 10) > 0) { ;\n__p +=\n__e( likes );\n } ;\n__p += ' </span><span class=\"nav-text nav-item-likes\">' +\n__e( __('Likes') ) +\n'</span></a><a href=\"/following\" class=\"nav-item with-icon\"><span class=\"nav-count\">' +\n__e( following ) +\n'</span><span class=\"nav-text nav-item-following\">' +\n__e( __('Following') ) +\n'</span></a><a href=\"/settings\" class=\"nav-item with-icon\" data-subnav=\"settings\"><span class=\"nav-text nav-item-settings has-subnav\">' +\n__e( __('Settings') ) +\n'</span></a><a href=\"' +\n__e( url_prefix ) +\n'' +\n__e( npfMobileCreate ? '/dashboard/new' : '/new/text' ) +\n'\" class=\"nav-item with-icon\"><span class=\"nav-text nav-item-create-post\">' +\n__e( __('Create a post') ) +\n'</span></a></nav><nav class=\"nav-blog-list\"><span class=\"nav-section-title\">' +\n__e( __('Blogs') ) +\n'</span> ';\n _.each(blogs, function(blog) { ;\n__p += ' <a href=\"' +\n__e( blog.url ) +\n'\" class=\"nav-item\"><img src=\"' +\n__e( blog.avatar ) +\n'\" class=\"blog-avatar\"><div class=\"blog-name-wrapper\"><span class=\"blog-name\">' +\n__e( blog.name ) +\n'</span><span class=\"blog-title\">' +\n((__t = ( blog.safe_title )) == null ? '' : __t) +\n'</span></div></a> ';\n }); ;\n__p += ' </nav>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},53388(e,t,i){"use strict";var n=i(55679),s=i(21391),o=i(73419),r=i(28017),a=i(81515),l=i(95349),c=i(48442),u=i(4244).A,h=s.Router.extend({root:"/",constructor:function(e){e||(e={}),e.bootstrap||(e.bootstrap=o()),this.bootloader(e.bootstrap),s.Router.apply(this,arguments)},getName:function(){return"Prima/Router"},logs:function(){return[]},bootloader:function(e){n.isEmpty(e),r.setup(e),l.log("Exec","Bootstrap/Data"),a.setup(e.Translations,n.get(e,"Context.language_simple","en")),l.log("Exec","Bootstrap/Translations"),c.startLogs(this.logs()),l.log("Exec","Bootstrap/logs"),new u({})}},{start:function(e){return new this(e)}});e.exports=h},53750(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(71092),r=i(27496),a=i(98979),l=o.extend({events:{click:"onMoreClick"}
1,defaults:{parentSelector:".content-controls",buffer:180},initialize:function(e){this.options=n.defaults(e,this.defaults),this.$typeText=this.$(".type-text"),this.initialMoreText=this.$typeText.text(),this.controlEls=s(".types-tabs > .content-control").not(".more-controls"),this.bindEvents(),this.refresh()},bindEvents:function(){this.listenTo(r,"DOMEventor:flatresize",n.throttle(n.bind(this.refresh,this),500)),this.listenTo(this.collection,"change:active",this.updateText)},refresh:function(){var e=s(this.options.parentSelector).width(),t=this.getBuffer(),i=[];this.collection.invoke("set",{visible:!0}),this.popover&&(this.popover.hide(),this.popover=null),n.each(this.controlEls,function(n){var o=s(n),r=this.collection.get(o.data("content-type"));r.get("showSponsoredBadge")||(t+=o.outerWidth(),e<=t&&i.push(r))},this),i.length>1&&n.invoke(i,"set",{visible:!1}),this.updateText()},getBuffer:function(){var e=this.collection.where({showSponsoredBadge:!0}),t=this.options.buffer;return e.length&&n.each(e,function(e){t+=s('[data-content-type="'+e.id+'"]').outerWidth()},this),t},updateText:function(){var e=this.collection.findWhere({active:!0,visible:!1});this.$typeText.text(e?e.get("name"):this.initialMoreText),this.$el.toggleClass("active",void 0!==e)},onMoreClick:function(){this.popover=new a({collection:this.collection,pinnedTarget:this.$el,popoverContainer:s(".types-tabs"),shift:{x:10,y:50}}).render()}});e.exports=l},53855(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, \'\') }\nwith (obj) {\n__p += \'<ul class="popover_inner_list search_filter_items"><li class="popover_menu_item sort_filter" data-filter="sort:POPULARITY_DESC"><span class="popover_menu_item_anchor"><i class="icon icon_checkmark"></i> \' +\n__e( __(\'Top Posts\') ) +\n\' </span></li><li class="popover_menu_item sort_filter" data-filter="sort:CREATED_DESC"><span class="popover_menu_item_anchor"><i class="icon icon_checkmark"></i> \' +\n__e( __(\'Recent Posts\') ) +\n\' </span></li></ul> \';\n if (model.showOriginalPostsSwitch) { ;\n__p += \' <ul class="popover_inner_list search_filter_items"><li class="popover_menu_item sort_filter toggle"><span class="popover_menu_item_anchor"><div class="option-radio"><label class="binary_switch"><input type="checkbox" name="post_role" id="post_role" data-value="ORIGINAL"> <span class="binary_switch_track"></span> <span class="binary_switch_button"></span></label></div> \' +\n__e( __(\'Original Posts\') ) +\n\' </span></li></ul> \';\n } ;\n__p += \' <ul class="popover_inner_list search_filter_items"><li class="popover_menu_item post_type_filter" data-filter="post_type:ANY"><span class="popover_menu_item_anchor"><i class="icon icon_checkmark"></i> \' +\n__e( __(\'All Types\') ) +\n\' </span></li><li class="popover_menu_item post_type_filter post_text_filter" data-filter="post_type:TEXT"><span class="popover_menu_item_anchor"><i class="icon icon_checkmark"></i> <i class="icon post_type_icon icon_post_text_small"></i> \' +\n__e( __(\'Text\') ) +\n\' </span></li><li class="popover_menu_item post_type_filter post_photo_filter" data-filter="post_type:PHOTO"><span class="popover_menu_item_anchor"><i class="icon icon_checkmark"></i> <i class="icon post_type_icon icon_post_photo_small"></i> \' +\n__e( __(\'Photo\') ) +\n\' </span></li><li class="popover_menu_item post_type_filter post_quote_filter" data-filter="post_type:QUOTE"><span class="popover_menu_item_anchor"><i class="icon icon_checkmark"></i> <i class="icon post_type_icon icon_post_quote_small"></i> \' +\n__e( __(\'Quote\') ) +\n\' </span></li><li class="popover_menu_item post_type_filter post_link_filter" data-filter="post_type:LINK"><span class="popover_menu_item_anchor"><i class="icon icon_checkmark"></i> <i class="icon post_type_icon icon_post_link_small"></i> \' +\n__e( __(\'Link\') ) +\n\' </span></li><li class="popover_menu_item post_type_filter post_chat_filter" data-filter="post_type:CHAT"><span class="popover_menu_item_anchor"><i class="icon icon_checkmark"></i> <i class="icon post_type_icon icon_post_chat_small"></i> \' +\n__e( __(\'Chat\') ) +\n\' </span></li><li class="popover_menu_item post_type_filter post_audio_filter" data-filter="post_type:AUDIO"><span class="popover_menu_item_anchor"><i class="icon icon_checkmark"></i> <i class="icon post_type_icon icon_post_audio_small"></i> \' +\n__e( __(\'Audio\') ) +\n\' </span></li><li class="popover_menu_item post_type_filter post_video_filter" data-filter="post_type:VIDEO"><span class="popover_menu_item_anchor"><i class="icon icon_checkmark"></i> <i class="icon post_type_icon icon_post_video_small"></i> \' +\n__e( __(\'Video\') ) +\n\' </span></li></ul> \';\n if (model.showNsfwSwitch) { ;\n__p += \' <ul class="popover_inner_list search_filter_items"><li class="popover_menu_item sort_filter toggle"><span class="popover_menu_item_anchor"><div class="option-radio"><label class="binary_switch"><input type="checkbox" name="filter_nsfw" id="filter_nsfw" data-value="true" class="search-nsfw-filter-checkbox-input"> <span class="binary_switch_track"></span> <span class="binary_switch_button"></span></label></div> \' +\n__e( __(\'Safe search\') ) +\n\' </span></li></ul> \';\n } ;\n\n\n}\nreturn __p\n}').apply(void 0,r(s))},54125(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(64491),r=i(38578),a=i(55060),l=i(86804),c=i(29833),u=i(8210),h=s.extend({className:"nav-logo-title",mixins:[o,r],template:a,initialize:function(e){e=n.extend({},e),n.extend(this.attributes,e),this.subViews.logo=new l,this.get("page_title")&&this.get("logged_in")&&!this.get("search_term")?(this.subViews.pageTitle=new c(e),this.set("show_page_title",!0)):this.set("show_page_title",!1),this.set("show_search_field",!!this.get("search_term")),this.subViews.searchField=new u(e)},render:function(){return this.$el.html(this.template(this.toJSON())),this.attachSubViews(),this}});e.exports=h},54269(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(27496),r=i(98237),a=i(77594),l=i(50283),c=i(96152),u=i(3573),h=i(78421),d=i(68211),p=i(89945),g=i(37158),f=i(66771),m=i(17025),_=i(48374),v=i(70305),b=i(79990),y=i(96791),w=i(85474),C=i(9380),x=i(7864),k=l.extend({className:"messaging-share-post",template:u,defaults:{senderBlog:null,isSending:!1,isLoading:!1,isLoadingFavorites:!1,isDisabled:!1,isEmpty:!1,isShowFavorites:!0,isShowMessage:!1,isS
1howExternalNetworksRow:!0,isExternalSharingEnabled:!0,isShowingExternalNetworkSubview:!1,closeAfterExternalNetworkShareMs:3e3,showLoadingAfterMs:250,numFavorites:10,defaultPlaceholder:null,additionalFavoritesPlaceholder:null,sendingPlaceholder:null,currentPlaceholder:null,focusIndex:0,isResultContainerFocused:!1,isExternalNetworksContainerFocused:!1,loadingClass:"is-loading",baseLoggingContext:"post-chrome",tabbingView:null},mixins:[r,a],keycommands:{"keydown:up":"_onKeyPressUp","keydown:down":"_onKeyPressDown","keydown:tab":"_onKeyPressTab","keydown:shift+tab":"_onKeyPressShiftTab","keydown:escape":"_onKeyPressEscape"},subviews:{searchView:{constructor:d,options:function(e){return{collection:e.collection,selectedRecipientModel:e.selectedRecipientModel,keyboardManager:e.keyboardManager,keyboardNamespace:"messagingshare:search"}}},resultsView:{constructor:p,options:function(e){return{collection:e.collection,selectedRecipientModel:e.selectedRecipientModel,keyboardManager:e.keyboardManager,keyboardNamespace:"messagingshare:results"}}},messageView:{constructor:w,options:function(e){return{isAutoValidationEnabled:!1,className:"messaging-share-post-message",placeholder:e.get("currentPlaceholder"),keyboardManager:e.keyboardManager,keyboardNamespace:"messagingshare:message",buttonSubmittedClass:"submitted--send-a-post",animationSpeed:250,pluginsArray:e.pluginsArray,isSendAPost:!0}}},externalNetworksView:{constructor:g,options:function(e){return{isExternalSharingEnabled:e.get("isExternalSharingEnabled"),keyboardManager:e.keyboardManager,keyboardNamespace:"messagingshare:external",externalNetworksDataModel:e.externalNetworksDataModel}}},errorView:{constructor:m},favoritesLoaderView:{constructor:h,options:{className:"messaging-share-post-favorites-loader",variation:"small centered",loading:!1}}},initialize:function(e){var t;e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"favoritesCollection","shareData","channels","popoverContainer","additionalFavorites","externalNetworksDataModel")),this.collection=new C,t=this.channels.findWhere({uuid:n.get(e,"senderBlogUuid")})||this.channels.first(),this.keyboardManager=new v({allowMultipleActiveViews:!0}),n.isEmpty(this.get("defaultPlaceholder"))&&this.set("defaultPlaceholder",s("Say something if you like...")),n.isEmpty(this.get("additionalFavoritesPlaceholder"))&&this.set("additionalFavoritesPlaceholder",s("Discuss this post if you like...")),n.isEmpty(this.get("sendingPlaceholder"))&&this.set("sendingPlaceholder",s("Sending...")),this.set({currentPlaceholder:this.get("defaultPlaceholder"),senderBlog:t}),this.additionalFavoritesIds=n.pluck(n.invoke(this.additionalFavorites,"toJSON"),"uuid"),this.channelIds=this.channels.pluck("uuid"),this.selectedRecipientModel=new x,this.blogSelectorPlugin=new _({collection:this.channels,currentTumblelog:t,popoverOptions:{popoverContainer:this.popoverContainer}}),this.pluginsArray=[this.blogSelectorPlugin],this.disableKeys()},afterRenderSubviews:function(){this.loader=new c({$container:this.$el,type:"bar",classModifiers:"top",loading:!1}),this._onSearchInputDebounced=n.bind(n.debounce(function(){this._onSearchInput(this.searchView.getQuery())},250),this),this.listenTo(this.selectedRecipientModel,"change:participant",this._onChangeSelectedRecipient),this.listenTo(this,"change:isSending",this._onChangeIsSending),this.listenTo(this,"change:isDisabled",this._onChangeIsDisabled),this.listenTo(this,"change:isLoading",this._onChangeIsLoading),this.listenTo(this,"change:isLoadingFavorites",this._onChangeisLoadingFavorites),this.listenTo(this,"change:isEmpty",this._onChangeIsEmpty),this.listenTo(this,"change:isShowFavorites",this._onChangeIsShowFavorites),this.listenTo(this,"change:isShowExternalNetworksRow",this._onChangeIsShowExternalNetworksRow),this.listenTo(this,"change:isShowMessage",this._onChangeIsShowMessage),this.listenTo(this,"change:currentPlaceholder",this._onChangeCurrentPlaceholder),this.listenTo(this,"change:focusIndex",this._onChangeFocusIndex),this.listenTo(this.blogSelectorPlugin.getBlogSelector(),"change:currentTumblelog",this._onBlogSelectorChange),this.listenTo(this.messageView,"submit:animated",this._onMessageSubmit),this.listenTo(this.searchView,"search",this._onSearchInputDebounced),this.listenTo(this.searchView,"clear",this._onSearchClear),this.listenTo(this.searchView,"focus",this._onViewFocusChange),this.listenTo(this.searchView,"submit",this._onSearchSubmit),this.listenTo(this.messageView,"focus",this._onViewFocusChange),this.listenTo(this.resultsView,"focus",this._onViewFocusChange),this.listenTo(this.externalNetworksView,"focus",this._onViewFocusChange),this.listenTo(this.externalNetworksView,"share:subview:show",this._onExternalNetworkShowSubview),this.listenTo(this.externalNetworksView,"share:success",this._onExternalNetworkShareSuccess),this.listenTo(this.externalNetworksView,"share:fail",this._onExternalNetworkShareFail),this.listenTo(this.externalNetworksView,"share:click",this._onExternalNetworkClick),this.listenTo(this.collection,"sync",this._onCollectionSync),this._setVie
1wStates(),this._fetchFavorites(),this._setCollectionState(),this.messageTheme=new y({removeDataAttrAfterApplyingTheme:!1,el:this.messageView.el}),this.searchTheme=new y({removeDataAttrAfterApplyingTheme:!1,el:this.searchView.el}),n.defer(n.bind(function(){this.rendered&&this.searchView.focus()},this)),this.keyboardManager.add("messagingshare:main",this),this.focusKeys()},beforeRemove:function(){this.keyboardManager.remove("messagingshare")},fetchByQuery:function(e){n.isEmpty(e)?this.set({isEmpty:!1,isShowFavorites:!0,isLoading:!1}):(this.set("isLoading",!0),this.collection.fetchByQuery(e,this.get("senderBlog").get("uuid")).always(n.bind(function(){this.rendered&&this.set("isLoading",!1)},this)))},getSelectedRecipient:function(){return this.selectedRecipientModel.get("participant")},clearSelectedRecipient:function(){this.selectedRecipientModel.set("participant",null)},sendPost:function(e,t){var i,s,r,a=this.shareData,l=n.get(this.shareData,"postId"),c=n.get(this.shareData,"blogUuid"),u=n.get(this.shareData,"isNsfw"),h=[],d=!n.isEmpty(e),p=this._getLoggingContext();this.get("isDisabled")||this.get("isSending")||n.isEmpty(a)||(s=b.createPostMessage(l,c,{context:p,creationUserAction:t,is_nsfw:u}),h.push(s),d&&(r=b.createTextMessage(e,{context:p,creationUserAction:t}),h.push(r)),i=this._createConversation(),n.isEmpty(i)||(this.set("isSending",!0),i.appendToQueue(h),o.trigger("messaging:conversation:open:model",i,p),this.close()))},close:function(){this.trigger("close")},_createConversation:function(){var e=this.get("senderBlog"),t=this.getSelectedRecipient();if(n.isEmpty(e)||n.isEmpty(t))return null;var i=e.toJSON(),s=t.toJSON();return new b({participantUuid:e.get("uuid"),participants:[i,s]})},_onCollectionSync:function(e){var t;this.rendered&&!n.isEmpty(this.searchView.getQuery())?(this.clearSelectedRecipient(),(t=0===this.collection.length)&&this.errorView.setTitle(this.collection.getNoResultsFoundMessage()),this.set({isShowFavorites:!1,isEmpty:t}),this._resetResultsScroll()):this._setCollectionState()},_resetResultsScroll:function(){this.resultsView.$el.scrollLeft(0)},_resetExternalNetworksScroll:function(){this.externalNetworksView.$el.scrollLeft(0)},_applyTheme:function(e){this.messageTheme.setTheme(e),this.searchTheme.setTheme(e)},_setViewStates:function(){var e=this.get("isShowMessage"),t=this.get("isEmpty"),i=this.get("isLoadingFavorites"),n=this.get("isShowExternalNetworksRow");this.js$("submission").toggleClass("show-submission",e),this.js$("external").toggle(n),this.errorView.$el.toggle(t),this.resultsView.toggle(!t),this.favoritesLoaderView.set("loading",i
1),this._setFocusViews()},_onSearchInput:function(e){this.rendered&&this.fetchByQuery(e)},_onSearchClear:function(){this.rendered&&(this.fetchByQuery(null),this.clearSelectedRecipient())},_onSearchSubmit:function(){this.get("isShowFavorites")||1===this.collection.length&&this.selectedRecipientModel.set("participant",this.collection.first())},_setPlaceholderState:function(){var e=this.getSelectedRecipient(),t=this.get("isSending"),i=!n.isEmpty(e)&&n.contains(this.additionalFavoritesIds,e.get("uuid"));t?this.set("currentPlaceholder",this.get("sendingPlaceholder")):this.set("currentPlaceholder",i?this.get("additionalFavoritesPlaceholder"):this.get("defaultPlaceholder"))},_setButtonState:function(){var e=this.get("isSending"),t=this.get("isDisabled"),i=e||t;this.messageView.set("isDisabled",i)},_setDisabledState:function(){var e=this.getSelectedRecipient(),t=this.get("senderBlog"),i=!n.isEmpty(e)&&e.get("uuid")===t.get("uuid");this.set("isDisabled",i)},_setCollectionState:function(){this.get("isShowFavorites")&&this.collection.reset(this.favoritesCollection.toJSON())},_setFocusViews:function(){var e=[this.searchView],t=[];this.get("isEmpty")||this.get("isLoadingFavorites")||(e.push(this.resultsView),t.push(this.resultsView)),this.get("isShowExternalNetworksRow")&&(e.push(this.externalNetworksView),t.push(this.externalNetworksView)),this.get("isShowMessage")&&e.push(this.messageView),this._focusViews=e,this._tabbableViews=t},_getLoggingContext:function(){var e=this.get("baseLoggingContext"),t=this.getSelectedRecipient();return n.isEmpty(t)?e:e+":"+(n.contains(this.additionalFavoritesIds,t.get("uuid"))?"trail":this.get("isShowFavorites")?"favorites":"search")},_onChangeIsSending:function(e,t){this._setButtonState(),this._setPlaceholderState()},_onChangeIsDisabled:function(e,t){this._setButtonState()},_onChangeSelectedRecipient:function(e,t){var i=!n.isEmpty(t);i?(this.messageView.focus(),this._applyTheme(t.get("theme"))):this.searchView.focus(),this.set("isShowMessage",i),this._setViewStates(),this._setDisabledState(),this._setPlaceholderState()},_onChangeIsEmpty:function(){this._setViewStates()},_onChangeIsShowFavorites:function(){this._setCollectionState(),this._resetResultsScroll()},_onChangeIsShowExternalNetworksRow:function(){this._setViewStates(),this._resetExternalNetworksScroll()},_onChangeIsShowMessage:function(e,t){this.set("isShowExternalNetworksRow",!t)},_onBlogSelectorChange:function(e,t){this.set("senderBlog",t),this.messageView.focus(),this._setDisabledState()},_onChangeIsLoading:function(e,t){if(this._loaderTimeout&&(clearTimeout(this._loaderTimeout),this._loaderTimeout=null),!t)return this.$el.removeClass(this.get("loadingClass")),void this.loader.set("loading",!1);this._loaderTimeout=setTimeout(n.bind(function(){this.rendered&&(this.loader.set("loading",!0),this.$el.addClass(this.get("loadingClass")))},this),this.get("showLoadingAfterMs"))},_onChangeisLoadingFavorites:function(){this._setViewStates()},_onMessageSubmit:function(e,t){this.sendPost(e,t)},_onChangeCurrentPlaceholder:function(e,t){this.messageView.setPlaceholder(t)},_addAdditionalFavorites:function(){!n.isEmpty(this.additionalFavorites)&&n.isArray(this.additionalFavorites)&&n.each(this.additionalFavorites.reverse(),function(e){var t=e.get("uuid"),i=this.favoritesCollection.get(t);n.contains(this.channelIds,t)||(n.isEmpty(i)?this.favoritesCollection.unshift(e):(this.favoritesCollection.remove(t),this.favoritesCollection.unshift(i)))},this)},_fetchFavorites:function(){var e=this;this.set("isLoadingFavorites",!0),this.favoritesCollection.fetchFavorites(this.get("numFavorites"),null,!0,!1,"post").always(function(){e.rendered&&(e._addAdditionalFavorites(),e._setCollectionState(),e.set("isLoadingFavorites",!1))})},_getFocusViews:function(){return this._focusViews},_moveFocusUp:function(){this.set("focusIndex",Math.max(0,this.get("focusIndex")-1))},_moveFocusDown:function(){var e=this._getFocusViews()||[];this.set("focusIndex",Math.min(e.length-1,this.get("focusIndex")+1))},_onViewFocusChange:function(e){var t=this._getFocusViews(),i=n.indexOf(t,e);this.set("tabbingView",n.contains(this._tabbableViews,e)?e:null),this.set("focusIndex",i,{silent:!0})},_onChangeFocusIndex:function(e,t){var i=n.get(this._getFocusViews(),t);this.set("tabbingView",n.contains(this._tabbableViews,i)?i:null),n.result(i,"focu
1s")},_onKeyPressTab:function(e){var t=this.get("tabbingView");e.preventDefault(),n.isEmpty(t)||t.isLastFocused()?this._moveFocusDown():t.focusNext()},_onKeyPressShiftTab:function(e){var t=this.get("tabbingView");e.preventDefault(),n.isEmpty(t)||t.isFirstFocused()?this._moveFocusUp():t.focusPrevious()},_onKeyPressEscape:function(e){this.close(),e.preventDefault()},_onKeyPressUp:function(e){e.preventDefault(),this._moveFocusUp()},_onKeyPressDown:function(e){e.preventDefault(),this._moveFocusDown()},_onExternalNetworkShowSubview:function(e){var t="messagingshare:externalnetwork",i=new f({externalNetworkSubview:e});i.render(),this.disableKeys(),this.keyboardManager.add(t,i),this.listenToOnce(i,"goBack",function(){this.stopListening(e),this.keyboardManager.remove(t,i),this.enableKeys(),i.remove(),this.set("isShowingExternalNetworkSubview",!1),this.searchView.focus()}),this.listenToOnce(i,"close",function(){this.close()}),this.js$("external-network-subview-wrapper").html(i.$el),this.set("isShowingExternalNetworkSubview",!0)},_onExternalNetworkShareSuccess:function(e){setTimeout(n.bind(function(){this.rendered&&this.close()},this),this.get("closeAfterExternalNetworkShareMs")),this.trigger("external:success",e)},_onExternalNetworkShareFail:function(e){this.trigger("external:fail",e)},_onExternalNetworkClick:function(e){this.trigger("external:click",e)}});e.exports=k},54663(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(50283),r=i(745),a=o.extend({className:"inbox-compose-toggle",template:r,defaults:{isComposing:!1},events:{"click [data-js-compose-toggle]":"_onClickToggleCompose"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","isNewEmptyInboxEnabled"))},afterRender:function(){this.listenTo(this,"change:isComposing",this._onChangeIsComposing)},getTemplateData:function(){return{message:this.isNewEmptyInboxEnabled?s("New Message"):s("Compose message")}},_onChangeIsComposing:function(e,t){this.$el.toggleClass("active",t)},_onClickToggleCompose:function(e){var t;e.preventDefault(),this.set("isComposing",!this.get("isComposing")),t=this.isNewEmptyInboxEnabled?this.eventBus.NEW_EMPTY_INBOX_NEW_MESSAGE_CLICK:this.eventBus.OLD_EMPTY_INBOX_NEW_MESSAGE_CLICK,this.eventBus.trigger(t,this.isNewEmptyInboxEnabled)}});e.exports=a},54892(e,t,i){function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function s(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,o(n.key),n)}}function o(e){var t=function(e,t){if("object"!=n(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var s=i.call(e,t||"default");if("object"!=n(s))return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==n(t)?t:t+""}var r=i(55679),a=i(21189),l=i(88146),c="FileReader"in window&&"readAsDataURL"in FileReader.prototype,u=(window.URL||window.webkitURL||window.mozURL||window.msURL||{}).createObjectURL,h=[],d=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),null!=t&&this.read(t)}return t=e,i=[{key:"read",value:function(e){var t,i=this,n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return this.file=e,e?c?(e.type.match(/image\/(jpg|jpeg)/i)||(n=!1),t=n&&"readAsBinaryString"in FileReader.prototype?this.readBinaryString(e).then(function(t){try{var n=new l.JpegFile(t.binary,e.name);t.rotation=function(e){switch(e){case 1:case 2:default:return 0;case 3:case 4:return 180;case 5:case 8:return 270;case 6:case 7:return 90}}(n.tiff.Orientation.value),t.mirrored=function(e){switch(e){case 2:case 4:case 5:case 7:return!0;default:return!1}}(n.tiff.Orientation.value)}catch(e){}return i.readDataUrl(e).then(function(e){return r.extend(t,e)})}):this.readDataUrl(e),this.promise=t,t):a.reject("FileReader is not supported"):a.reject("No file to read")}},{key:"readDataUrl",value:function(e){var t=new FileReader;return"readAsDataURL"in t?a.promise(function(i,n){t.onload=function(e){var n=e.target.result;i(n),t.onload=null,t.onerror=null},t.onerror=function(){n(),t.onload=null,t.onerror=null}
1,t.readAsDataURL(e)}).then(r.bind(this._onLoadDataUrl,this),r.bind(this._onError,this)):a.reject("FileReader.readAsDataURL is not supported")}},{key:"_onLoadDataUrl",value:function(e){var t={base64:e,file:this.file};return u&&(t.objectUrl=u(this.file),h.push(t.objectUrl)),a.resolve(t)}},{key:"readBinaryString",value:function(e){var t=new FileReader;return"readAsBinaryString"in t?a.promise(function(i,n){t.onload=function(e){var n=e.target.result;i(n),t.onload=null,t.onerror=null},t.onerror=function(){n(),t.onload=null,t.onerror=null},t.readAsBinaryString(e)}).then(r.bind(this._onLoadBinaryString,this),r.bind(this._onError,this)):a.reject("FileReader.readAsBinaryString is not supported")}},{key:"_onLoadBinaryString",value:function(e){return a.resolve({binary:e,file:this.file})}},{key:"_onError",value:function(e){return a.reject("Failed to read file")}}],n=[{key:"read",value:function(t,i){return new e(t,i).promise}},{key:"canReadFiles",value:function(){return c}}],i&&s(t.prototype,i),n&&s(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,i,n}();e.exports=d},54980(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(50283),r=i(98237),a=i(77770),l=o.extend({className:"conversation-error",mixins:[r],template:a,defaults:{message:null,isLoading:!1,showButton:!0,buttonText:null,buttonTextLoading:null,buttonTextCurrent:null},events:{"click [data-js-button]":"_onClickButton"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","buttonCallback")),n.isEmpty(this.get("message"))&&this.set("message",s("Something went screwy.")),n.isEmpty(this.get("buttonText"))&&this.set("buttonText",s("Retry")),n.isEmpty(this.get("buttonTextLoading"))&&this.set("buttonTextLoading",s("Retrying...")),n.isEmpty(this.get("buttonTextCurrent"))&&this.set("buttonTextCurrent",this.get("buttonText"))},afterRender:function(){this.listenTo(this,"change:isLoading",this._onChangeIsLoading),this.listenTo(this,"change:buttonTextCurrent",this._onChangeButtonTextCurrent),this.listenTo(this,"change:showButton",this._onChangeShowButton),this._onChangeIsLoading(this,this.get("isLoading")),this._onChangeShowButton(this,this.get("showButton"))},getTemplateData:function(){return{message:this.get("message"),buttonText:this.get("buttonTextCurrent")}},_onClickButton:function(e){e.preventDefault(),this.get("isLoading")||(this.set("isLoading",!0),this.trigger("buttonClick"),n.isFunction(this.buttonCallback)&&this.buttonCallback.call(this,this))},_onChangeIsLoading:function(e,t){var i=t?this.get("buttonTextLoading"):this.get("buttonText");this.set("buttonTextCurrent",i),this.js$("button").toggleClass("disabled",t).prop("disabled",t)},_onChangeButtonTextCurrent:function(e,t){this.js$("button").text(t)},_onChangeShowButton:function(e,t){this.js$("button").toggle(t)}});e.exports=l},55060(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"mobile-logo-wrapper';\n if(show_page_title) { ;\n__p += ' show-page-title ';\n } ;\n__p += ' ';\n if(!_.isUndefined(show_search_field) && show_search_field) { ;\n__p += ' show-search-field ';\n } ;\n__p += '\"><div data-subview=\"logo\"></div><div data-subview=\"pageTitle\"></div><div data-subview=\"searchField\"></div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},55068(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(50283),r=i(27496),a=i(44890),l=i(6479),c=i(39366),u=i(62490),h=i(73549),d=i(91673),p=i(51382),g=o.extend({className:"peepr-blog-search",template:c,subviews:{filters:{constructor:u},input:{constructor:h}},events:{"submit .blog-search-form":"formSubmitHandler","click .blog-search-form":"onFormClick","click .clear-search":"clearSearch","click .toggle-search":"toggleSearch"},initialize:function(e){this.options=e,this.user=l(),this.searchActive=!1,this.blog=e.blog,this.model=new p({blogname:this.blog.tumblelog_name_or_id,themeParams:this.blog.get("global_theme_params"),isAdult:this.blog.get("nsfw"),isSafeModeEnabled:a.bool("safe_mode")&&this.user.get("safe_mode")}),n.each(this.subviews,function(e){e.options=e.options||{},e.options.model=this.model},this),this.bindEvents()},bindEvents:function(){this.listenTo(this.model.posts,"reset",this.onPostsReset),this.listenTo(this.model.posts,"add",this.onPostsAdd),this.listenTo(this.model,"search:reset",this.onSearchReset),this.listenTo(this.model,"change:next_offset",this.onOffsetChange),this.listenTo(this.model,"change:term",n.bind(this.log,this,"search-start",{})),this.listenTo(r,"indashblog:search:fetch-requested",this.onFetchRequested),this.listenTo(r,"indashblog:ready-animation-start",this.onPeeprReady)},onPeeprReady:function(){this.setWidth()},setWidth:function(){var e=this.$el.parents(".navigation_inner"),t=e.width(),i=e.find(".header_controls").outerWidth();this.$el.width(t-i)},onFetchRequested:function(e){this.model.fetch(e)},formSubmitHandler:function(e){e.preventDefault(),this.model.search()},onFormClick:function(e){e.stopPropagation()},toggleSearch:function(e){e=n.defaults(e,{force:null,focus:!0}),this.model.get("term").length&&null===e.force?this.clearSearch():(this.searchActive=n.isBoolean(e.force)?e.force:!this.searchActive,this.$el.toggleClass("show-search",this.searchActive),s(".indash_header_wrapper").toggleClass("search-active",this.searchActive),this.searchActive?e.focus&&n.delay(n.bind(this.input.focusInput,this.input),300):this.model.reset())},clearSearch:function(){this.toggleSearch({force:!1}),r.trigger("indashblog:search:clear"),this.log("search-clear")},onSearchReset:function(){var e=this.model.get("term").length>0;this.$el.toggleClass("term-entered",e),e&&(r.trigger("indashblog:search:start"),this.searchActive||this.toggleSearch({focus:!1,force:!0}))},onPostsReset:function(e){e.length&&(r.trigger("indashblog:search:complete",e.toJSON()),this.log("search-complete"))},onOffsetChange:function(e,t){t>=0||(r.trigger("indashblog:search:results-end",this.model.posts.length?null:new d({model:this.model})),this.log("search-results-end"))},onPostsAdd:function(e){r.trigger("indashblog:search:post-added",e.toJSON())},log:function(e,t){var i={loggingData:n.defaults({blogname:this.blog.tumblelog_name_or_id,term:this.model.get("term"),sort:this.model.get("sort"),post_type:this.model.get("post_type"),post_role:this.model.get("post_role"),next_offset:this.model.get("next_offset")},t||{})};r.trigger("peepr-search:"+e,i)},remove:function(){this.model.stopListening(),o.prototype.remove.call(this)}});e.exports=g},55147(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<div data-subview="searchInput"></div><div data-subview="loader"></div><div data-subview="searchResults"></div><div data-subview="searchMessage"></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},55379(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div class=\"question\">' +\n((__t = ( question )) == null ? '' : __t) +\n'</div><div class=\"answer\">' +\n((__t = ( answer )) == null ? '' : __t) +\n'</div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},55731(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"message-container has-thumbnail\"><div class=\"avatar\"><a href=\"' +\n__e( blogUrl ) +\n'\" target=\"_blank\" data-js-tumblelog-name=\"' +\n__e( name ) +\n'\"><img src=\"' +\n__e( avatarUrl ) +\n'\"></a></div><div class=\"message-bubble\" data-js-message-bubble><button class=\"retry-button\" data-js-retry-button>
1' +\n__e( __('Retry') ) +\n'</button> ';\n if (!_.isEmpty(rawUrl)) { ;\n__p += ' <a href=\"' +\n__e( rawUrl ) +\n'\" data-js-lightbox-url=\"' +\n__e( rawUrl ) +\n'\" data-js-lightbox-width=\"' +\n__e( rawWidth ) +\n'\" data-js-lightbox-height=\"' +\n__e( rawWidth ) +\n'\" data-js-lightbox-lowres-url=\"' +\n__e( url ) +\n'\"> ';\n } ;\n__p += ' <div class=\"thumbnail\" data-js-thumbnail><img class=\"full-width\" data-js-message-image src=\"' +\n__e( url ) +\n'\" width=\"' +\n__e( thumbnailWidth ) +\n'\"></div> ';\n if (!_.isEmpty(rawUrl)) { ;\n__p += ' </a> ';\n } ;\n__p += ' </div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},55869(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"mobile-banner-body\"><span class=\"mobile-banner-heading\">' +\n__e( __('Use the Tumblr app!') ) +\n'</span><span class=\"mobile-banner-subheading\">' +\n__e( __('Find communities and join group chats.') ) +\n'</span></div><div class=\"mobile-banner-controls\"><a href=\"' +\n__e( open_url ) +\n'\" class=\"open mobile-banner-button secondary-cta tx-button\" role=\"button\">' +\n__e( __('Open') ) +\n'</a><a href=\"' +\n__e( install_url ) +\n'\" class=\"install mobile-banner-button primary-cta tx-button\" role=\"button\">' +\n__e( __('Install the app') ) +\n'</a> ';\n if (show_close_button) { ;\n__p += ' <a href=\"#\" class=\"mobile-banner-close\"></a> ';\n } ;\n__p += ' </div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},55938(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, \'\') }\nwith (obj) {\n__p += \'<div class="audio-player\';\n if (albumArt) { ;\n__p += \' has-art \';\n } ;\n__p += \'"><div class="progress"></div><div class="play-pause"><i class="icon icon_play"></i></div><div class="audio-info"><div class="track-name">\' +\n__e( track ) +\n\'</div><div class="track-artist">\' +\n__e( artist ) +\n\'</div><div class="track-no-id3">\' +\n__e( noId3 ) +\n\'</div></div><audio preload="none"><source class="audio-source" src="\' +\n__e( streamUrl ) +\n\'"></audio></div> \';\n if (albumArt) { ;\n__p += \' <div class="audio-image"><img src="\' +\n__e( albumArt ) +\n\'" alt="\' +\n__e( track ) +\n\'"></div> \';\n } ;\n\n\n}\nreturn __p\n}').apply(void 0,r(s))},56292(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(38578),r=i(55869),a=s.extend({mixins:[o],template:r,initialize:function(e){n.extend(this.attributes,e)},render:function(){return this.set("install_url",this.get("install_url").replace("campaign_name","mobile_banner_dashboard")),this.set("open_url",this.get("open_url")+"&referrer=mobile_banner_dashboard"),this.$el.html(this.template(this.toJSON())),this}});e.exports=a},56315(e,t,i){var n=i(27513),s=i(80867),o=n.extend({model:s});e.exports=o},56515(e,t,i){"use strict";var n=i(44384),s=i(44838),o=i(33924),r=n.extend({hasSubViews:{controls:s,notes:o}});e.exports=r},56553(e,t,i){"use strict";var n=i(55679),s=i(50283).extend({renderWithTemplate:n.noop,initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"channels"))},afterRender:function(){this.listenTo(this.channels,"change:unread_messages_count_sum",this._onChangeChannelUnreadCount),this._onChangeChannelUnreadCount()},updateBadge:function(e){e>0&&this.$(".tab_notice_value").text(e>99?"99+":e),this.$(".tab_notice").toggleClass("tab-notice--active",e>0)},_onChangeChannelUnreadCount:function(){this.updateBadge(n.sum(this.channels.pluck("unread_messages_count_sum")))}});e.exports=s},56556(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(71092),r=i(27496),a=i(64491),l=i(59952),c=i(7784),u=o.extend({mixins:[a,l],className:"tumblelog_popover popover popover--blog-card",blogCardView:null,initialize:function(e){e||(e={}),e.identifier="TumblelogPopover",this.$targetPost=s(e.pinnedTarget).closest(".post"),o.prototype.initialize.call(this,e)},openPopover:function(){if(this.blogCardView)return this.render(),this;this.blogCardView=new c({model:this.model,targetPost:this.$targetPost}),this.listenToOnce(this.blogCardView,"ready",this.render)},closePopover:function(){this.animateOut(),n.delay(n.bind(this.teardown,this),250)},onMouseMove:function(e){this.overElement(e,this.$el)||this.overElement(e,this.$pinned)?this.teardownTimer&&(clearTimeout(this.teardownTimer),this.teardownTimer=null):this.teardownTimer||(this.teardownTimer=n.delay(n.bind(this.closePopover,this),300))},overElement:function(e,t){var i=t.offset();return e.pageX>i.left&&e.pageY>i.top&&e.pageX<i.left+t.outerWidth()&&e.pageY<i.top+t.outerHeight()},render:function(){return this.blogCardView.render(),this.$el.html(this.blogCardView.el),n.defer(n.bind(this.animateIn,this)),this.boundMouseMove=n.bind(this.onMouseMove,this),s("body").on("mousemove",this.boundMouseMove),this._logOpen(),this},animateIn:function(){return this.$el.css("opacity",1),this},animateOut:function(){return this.$el.css("opacity",0),this},_logOpen:function(){r.trigger("popover:blogcard:open",{loggingData:{blog:this.model.get("name")}})},teardown:function(){return s("body").off("mousemove",this.boundMouseMove),this.$el.remove(),this}});e.exports=u},56604(e,t,i){"use strict";var n=i(55679);function s(e){return e&&e.nodeType&&1===e.nodeType}e.exports=function(e,t){if(s(e))return e;if(n.isString(e)){var i=(t||document).querySelector(e);
1if(s(i))return i}return!(!e||!e.jquery)&&e.get(0)}},56703(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(50283),r=i(67019),a=o.extend({className:"inbox-empty-blogs",template:r,defaults:{numItemsPerRow:4},events:{"click [data-js-start-conversation]":"_onStartConversation"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","collection"))},afterRender:function(){this.listenTo(this.collection,"update reset",this.render)},getTemplateData:function(){var e,t=this.get("numItemsPerRow"),i=n.map(this.collection.models,function(e){return n.extend(e.toJSON(),{avatarUrl:e.getAvatarUrl()})});return i.length>0&&(e=Math.max(1,Math.floor(i.length/t)),i=i.slice(0,e*t)),{blogs:i}},_onStartConversation:function(e){var t=s(e.currentTarget).attr("data-js-start-conversation"),i=this.collection.findWhere({name:t});this.eventBus.trigger(this.eventBus.CONVERSATION_OPEN_PARTICIPANT_MODELS,[i],"inbox:empty"),this.eventBus.trigger(this.eventBus.OLD_EMPTY_INBOX_SUGGESTION_CLICK,i,"old:inbox:empty",!1),e.preventDefault()}});e.exports=a},57220(e,t,i){var n=i(55679);e.exports=function(e,t){var i,s=this;i=e&&n.has(e,"constructor")?e.constructor:function(){return s.apply(this,arguments)},n.extend(i,s,t);var o=function(){this.constructor=i};return o.prototype=s.prototype,i.prototype=new o,e.defaults&&(n.extend(i.prototype.defaults,e.defaults),delete e.defaults),e&&n.extend(i.prototype,e),i.__super__=s.prototype,i}},57505(e,t,i){"use strict";var n=i(74692),s=i(55679),o=function(e,t,i){if(0===i)return 0;var n=null==i?t:t/i;return 2===arguments.length?Math.round(e*n):void 0},r=function(e,t,i){if(0===i)return 0;var n=null==i?t:t/i;return Math.round(e/n)},a=function(e){var t;e instanceof n?e=(t=e).get(0):t=n(e);var i=document.createElement("canvas");return i.width=e.width||t.width(),i.height=e.height||t.height(),i},l={widthForHeight:o,heightForWidth:r,maxSize:function(e,t,i,n){var s=e,a=t,l=e/t;return(e>i||t>n)&&(l>i/n?a=r(s=i,l):s=o(a=n,l)),{width:s,height:a}},cropBox:function(e,t,i,n,s,a){null!=s||(s=.5),null!=a||(a=.5);var l=0,c=e,u=t,h=e/t,d=i/n;return h>d?(c=o(t,d),l=Math.round(s*(e-c))):h<d&&(u=r(e,d),l=Math.round(a*(t-u))),{left:l,top:0,width:c,height:u}},createCanvasForEl:a,drawElToCanvas:function(e,t,i){e instanceof n?e=e.get(0):n(e),t?t instanceof n&&(t=t.get(0)):t=a(e);var s=t.width,o=t.height,r=t.getContext("2d");
1return r.save(),i&&(r.translate(t.width,0),r.scale(-1,1)),r.drawImage(e,0,0,s,o),r.restore(),t},drawScaledAndRotated:function(e,t,i,s,o,a){e instanceof n?e=e.get(0):n(e);var l=90===s||270===s;l?a&&i>a&&(t=r(a,i,t),i=a):a&&t>a&&(i=r(a,t,i),t=a);var c=document.createElement("canvas");l?(c.width=i,c.height=t):(c.width=t,c.height=i);var u=c.getContext("2d");return u.save(),u.translate(.5*c.width,.5*c.height),u.rotate(s*Math.PI/180),o&&u.scale(-1,1),u.drawImage(e,-.5*t,-.5*i,t,i),u.restore(),c},drawPixelatedImages:function(e){var t=e.$(".needs-drawing");s.each(t,function(e){var t=e.getContext("2d"),i=new Image;t.mozImageSmoothingEnabled=!1,t.imageSmoothingEnabled=!1,t.msImageSmoothingEnabled=!1,t.imageSmoothingEnabled=!1;i.onload=function(){t.fillStyle="#FFF",t.fillRect(0,0,e.width,e.height),t.drawImage(i,0,0,4,4),t.drawImage(e,0,0,4,4,0,0,e.width,e.height)},i.src=n(e).data("image-url")}),t.removeClass("needs-drawing")}};e.exports=l},57892(e,t,i){"use strict";var n=i(50283),s=i(27006),o=i(27496),r=i(74692),a=n.extend({events:{"click .see-all-tags":"_expandTags","click .post_tag":"_clickTag"},hasExpandedTags:!1,template:s,_expandTags:function(e){o.trigger("postchrome-interactions:expand-tags-click",{loggingData:{action:"expand-tags-click"}}),this.hasExpandedTags=!0,this.$el.removeClass("fadeable"),this.$(".see-all-tags").remove()},render:function(){this.$el.append(this.template())},_clickTag:function(e){var t=r(e.target);o.trigger("postchrome-interactions:tag-click",{loggingData:{action:"tag-click",tag:t.text(),hasExpandedTags:this.hasExpandedTags?"true":"false",wasHidden:this.hasExpandedTags&&t.position().top>81?"true":"false",postId:this.model.get("id"),tagIndex:t.index()}})}});e.exports=a},57982(e,t,i){"use strict";var n=i(55679),s=i(21189),o=i(17145).extend({constructor:function(e){null!=e&&this.load(e)},load:function(e,t){if(this.src=e,!e)return s.reject("No URL to load");var i=this,o=s.promise(function(s,o){var r,a=new Image;if(a.src=e,i._img=a,a.onload=function(){s(a),a.onload=null,a.error=null,clearInterval(r)},a.onerror=function(){o(a),a.onload=null,a.error=null,clearInterval(r)},a.complete)a.naturalWidth||a.naturalHeight?"function"==typeof a.onload&&a.onload():"function"==typeof a.onerror&&a.onerror();else if(t){var l=function(){return!(!a.naturalWidth&&!a.naturalHeight)&&("function"==typeof a.onload&&a.onload(),!0)};l()||(n.isNumber(t)||(t=100),r=setInterval(l,t))}});return this.promise=o=o.then(n.bind(this._onLoad,this),n.bind(this._onError,this)),o},_onLoad:function(e){return this._img===e?(this.width=e.naturalWidth,this.height=e.naturalHeight,this.src=e.src,this.loaded=!0,s.resolve({width:this.width,height:this.height,src:this.src})):this.promise},_onError:function(e){return this._img===e?(this.width=null,this.height=null,this.src=e.src,this.loaded=!1,s.reject(this.src+" failed to load")):this.promise}},{load:function(e,t){return new o(e,t).promise}});e.exports=o},57988(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n\n\n    // Checks to see if we're using the compact blog card used for Up and Coming blogs\n    // Also used as the popover for Explore posts, Search posts, and Recommended blogs\n    var is_blog_card_compact = (typeof blog_card_compact === 'boolean') ? blog_card_compact : false;\n\n    var has_avatar = (avatar_url && global_theme_params.show_avatar);\n    var has_bg_img = (global_theme_params.header_image_focused && global_theme_params.show_header_image);\n    var has_title = (title && global_theme_params.show_title);\n    var has_description = (description_sanitized && global_theme_params.show_description);\n\n    // Hide the header image if the blog card is compact and the image is default\n    var hide_default_header = is_blog_card_compact ? has_default_header && hide_headers_flag : false;\n\n    var expanded_name = (cname) ? cname : name + '.tumblr.com';\n    var description_color = (title_color_rgb) ? 'rgba(' + title_color_rgb + ',0.7)' : global_theme_params.title_color;\n\n    var header_class = (global_theme_params.header_stretch) ? '' : ' no_stretch_header';\n    header_class += (has_bg_img && !hide_default_header) ? '' : ' no_header_image';\n    header_class += (has_avatar) ? '' : ' no_avatar';\n    header_class += ((has_bg_img && !hide_default_header) && !has_avatar && !has_title && !has_description) ? ' header_image_only' : '';\n    header_class += (has_title || has_description) ? ' has_info' : ' no_info';\n;\n__p += ' <div class=\"indash_header_wrapper ' +\n((__t = ( header_class )) == null ? '' : __t) +\n' tumblelog_name_' +\n__e( name ) +\n'\" style=\"background-color:' +\n((__t = ( global_theme_params.background_color )) == null ? '' : __t) +\n'; color:' +\n((__t = ( global_theme_params.title_color )) == null ? '' : __t) +\n'\"> ';\n if (show_navigation) { ;\n__p += ' <div class=\"navigation\"><div class=\"navigation_bg\" style=\"background-color: ' +\n((__t = ( global_theme_params.background_color )) == null ? '' : __t) +\n'\"></div><div class=\"navigation_inner\"> ';\n if(name !== 'undefined') { ;\n__p += ' <h3><a href=\"' +\n__e( url ) +\n'\" target=\"_blank\" class=\"blog_name\" data-peepr=\\'{\"tumblelog\"
1: \"' +\n__e( name ) +\n'\"}\\'><span class=\"name\"> ' +\n__e( name ) +\n' </span><span class=\"full_url\">' +\n__e( expanded_name ) +\n'</span></a></h3> ';\n } ;\n__p += ' ';\n if (show_share_controls) { ;\n__p += ' <a class=\"open_blog_button nav_icon icon_export\"></a> ';\n } ;\n__p += ' ';\n if (!customizable && show_user_controls) { ;\n__p += ' <a data-snowman-container class=\"info_popover_button nav_icon user_dropdown_lockup\"><i class=\"user_dropdown_icon user_dropdown_icon_user icon_user_settings\"></i> </a> ';\n } ;\n__p += ' ';\n if (!customizable && show_follow_button) { ;\n__p += ' ';\n if (following) { ;\n__p += ' <button class=\"chrome unfollow\" type=\"button\">' +\n__e( unfollowText ) +\n'</button> <button class=\"chrome follow\" type=\"button\" style=\"display:none;\">' +\n__e( followText ) +\n'</button> ';\n } else { ;\n__p += ' <button class=\"chrome unfollow\" type=\"button\" style=\"display:none;\">' +\n__e( unfollowText ) +\n'</button> <button class=\"chrome follow\" type=\"button\">' +\n__e( followText ) +\n'</button> ';\n } ;\n__p += ' ';\n } ;\n__p += ' </div></div> ';\n } ;\n__p += ' ';\n if(global_theme_params.header_image_focused && global_theme_params.show_header_image && !hide_default_header) { ;\n__p += ' <div class=\"header_image_wrapper';\n if(has_avatar) { ;\n__p += ' has_avatar';\n } ;\n__p += '\"><div class=\"header_image\" style=\"background-image:url(' +\n__e( global_theme_params.header_image_focused ) +\n')\"> ';\n if(is_blog_card_compact || !customizable) { ;\n__p += ' <a href=\"' +\n((__t = ( url )) == null ? '' : __t) +\n'\" target=\"_blank\"><img src=\"' +\n__e( global_theme_params.header_image_focused ) +\n'\" data-peepr=\\'{\"tumblelog\": \"' +\n__e( name ) +\n'\"}\\' alt=\"' +\n__e( title ) +\n'\"> </a> ';\n } else { ;\n__p += ' <img src=\"' +\n__e( global_theme_params.header_image_focused ) +\n'\" alt=\"\"> ';\n } ;\n__p += ' </div></div> ';\n } ;\n__p += ' ';\n if(avatar_url && global_theme_params.show_avatar) { ;\n__p += ' <div class=\"avatar ' +\n((__t = ( global_theme_params.avatar_shape )) == null ? '' : __t) +\n'\" style=\"background-color:' +\n((__t = ( global_theme_params.background_color )) == null ? '' : __t) +\n'; background-image:url(' +\n((__t = ( avatar_url )) == null ? '' : __t) +\n'); color:' +\n((__t = ( global_theme_params.background_color )) == null ? '' : __t) +\n';\"> ';\n if(is_blog_card_compact || !customizable) { ;\n__p += ' <a href=\"' +\n((__t = ( url )) == null ? '' : __t) +\n'\" target=\"_blank\"><img src=\"' +\n((__t = ( avatar_url )) == null ? '' : __t) +\n'\" data-peepr=\\'{\"tumblelog\": \"' +\n__e( name ) +\n'\"}\\' alt=\"' +\n__e( title ) +\n'\"></a> ';\n } else { ;\n__p += ' <img src=\"' +\n((__t = ( avatar_url )) == null ? '' : __t) +\n'\" alt=\"\"> ';\n } ;\n__p += ' </div> ';\n } ;\n__p += ' ';\n if(has_title || has_description) { ;\n__p += ' <div class=\"info_wrapper\"><div class=\"info\"> ';\n if(has_title) { ;\n__p += ' <h1 class=\"title\" style=\"font-family:' +\n((__t = ( title_font_family || 'inherit' )) == null ? '' : __t) +\n'; font-weight:' +\n((__t = ( global_theme_params.title_font_weight )) == null ? '' : __t) +\n';\">' +\n__e( title ) +\n'</h1> ';\n } ;\n__p += ' ';\n if(has_description) { ;\n__p += ' <div class=\"description\" style=\"color:' +\n((__t = ( description_color )) == null ? '' : __t) +\n'\"><div class=\"description_inner\">' +\n((__t = ( description_sanitized )) == null ? '' : __t) +\n'</div></div> ';\n } ;\n__p += ' </div></div> ';\n } ;\n__p += ' </div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},58360(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(27496),r=i(6479),a=s.extend({initialize:function(e){this.user=r(),this.channels=this.user.channels,this.mentionKeys=this.channels.reduce(function(e,t){return e[t.get("mention_key")]=t.id,e},{}),this.listenTo(o,"activity:updateActivityUnreadCounts",this.getUnreadActivityBadgeCount),this.listenTo(this.channels,"change:unread_activity_count_sum",this.updateBadge),this.listenTo(o,"refresh_activities_count",this.user.getUnreadActivityBadgeCount)},getUnreadActivityBadgeCount:function(e){n.each(e,function(e,t){var i=this.mentionKeys[t],n=this.channels.get(i);n&&n.set("unread_activity_count_sum",e)},this)},updateBadge:function(){var e=n.sum(this.channels.pluck("unread_activity_count_sum"));e>0&&this.$(".tab_notice_value").text(e>99?"99+":e),this.$(".tab_notice").toggleClass("tab-notice--active",e>0)}});e.exports=a},58521(e,t,i){var n,s,o,r=i(55679),a=i(74692),l=(n=function(e){return Array.prototype.indexOf.call(e.parentNode.childNodes,e)},s=function(e){return e instanceof HTMLElement},o={getParentNodes:function(e,t){if(t=t||[],!e||o.isEditorNode(e))return t;var i=e.parentNode;return o.isEditorNode(i)?t:i?(t.push(i),o.getParentNodes(i,t)):t},getRootElements:function(e){var t=(e=e||o.getSelection())&&e.anchorNode?e.anchorNode:null;if(!t||o.isEditorNode(t))return[];var i=o.getParentNodes(t),r=e.focusNode,a=o.getParentNodes(r),l=i.length?i.pop():t,c=a.length?a.pop():r,u=n(l),h=n(c);if(h<u){var d=u;u=h,h=d}for(var p=[],g=l.parentNode,f=u;f<=h;f++){var m=g.childNodes[f];s(m)&&p.push(m)}return p},getNodeList:function(e,t){var i=(e=e||o.getSelection())&&e.anchorNode?e.anchorNode:null;if(!i||o.isEditorNode(i))return[];var n=e.focusNode,s=[i];n&&!o.isEditorNode(n)&&(s=s.concat([n]));var a=o.getParentNodes(i);if(s=s.concat(a),!t){var l=o.getParentNodes(n);s=s.concat(l)}return r.union(s)},getNodeByNames:function(e,t,i){var n=o.getNodeList(i);return n=t?n.reverse():n,this.getNodesByNames(n,e)[0]},getNodesByNames:function(e,t){return r.filter(e,function(e){return-1!==r.indexOf(t,e.nodeName)})},getNearestElement:function(e){e=e||o.getSelection();var t=o.getNodeList();return r.find(t,function(e){return 1===e.nodeType})},getContextCoordinates:function(e,t){var i=o.getSelection(),n=i.getRangeAt(0).cloneRange(),s=a(e).offset();if(t||!i.isCollapsed){var r=(t||n).getBoundingClientRect();
1return{x:r.left+r.width/2-s.left,y:r.top-s.top+a(window).scrollTop()}}if(n.getClientRects){n.collapse(!0);var l=n.getClientRects()[0];if(l)return{x:l.left-s.left,y:l.top-s.top+a(window).scrollTop()}}},getSelection:function(){var e=window.getSelection();return e.anchorNode&&a(e.anchorNode).closest("[contenteditable]").length?e:null},collapseToEnd:function(){var e=o.getSelection();e&&e.collapseToEnd()},collapseToStart:function(){var e=o.getSelection();e&&e.collapseToStart()},isInContext:function(e,t){return a(e.anchorNode).closest(t).length>0},isEditorNode:function(e){return a(e).is('[contentEditable="true"]')},hasSelection:function(){var e=o.getSelection();return e&&!e.isCollapsed},rangeFromElement:function(e){var t,i,n=o.getSelection();return!(!n||!n.isCollapsed)&&((t=(i=n.getRangeAt(0)).cloneRange()).selectNodeContents(e),t.setEnd(i.startContainer,i.startOffset),t)},isCursorAtEnd:function(e,t){var i=this.rangeFromElement(e);if(!i)return!1;var n=i.toString(),s=e.textContent;return t&&(n=n.trim(),s=s.trim()),n.length===s.length},isCursorAtStart:function(e){var t=this.rangeFromElement(e);return!!t&&0===t.startOffset&&0===t.endOffset}});e.exports=l},58527(e,t,i){"use strict";var n=i(55679),s=i(27513),o=i(23325),r=s.extend({model:o,add:function(e,t){return e&&!n.isArray(e)&&(e=[e]),n.forEac
1h(e,function(e,t){e.id||(n.isFunction(e.set)?e.set("id",this.generateId(t)):e.id=this.generateId(t))},this),s.prototype.add.apply(this,arguments)},generateId:function(e){var t=1+(e||0),i=n.map(n.range(this.length+1),function(e){return"o"+(t+e)});return n.find(i,function(e){return!this.get(e)},this)},setIdOrder:function(e,t){t||(t={}),this.models=n.map(e,function(e){return this.get(e)},this),t.silent||this.trigger("sort",this,t)}});e.exports=r},59034(e,t,i){var n=i(47640),s=function(){var e=function(e){if(!this.element)return n.error("ControlBase requires an element"),null;e=e||{},this.onShow=e.onShow||function(e){e.element.show()},this.onHide=e.onHide||function(e){e.element.hide()},this.isShown=!1,this.element.hide()};function t(e,t){"number"==typeof e&&"number"==typeof t&&this.element.css({left:e+"px",top:t+"px"})}function i(){var e=this.element.get(0).getBoundingClientRect().left;e<0&&this.element.css("left","+="+-1*e+"px");var t=this.element.get(0).getBoundingClientRect().top;t<0&&this.element.css("top","+="+-1*t+"px")}return e.prototype.hide=function(){this.isShown&&(this.isShown=!1,this.onHide(this))},e.prototype.showOverTarget=function(e,t){var n=e-this.element.width()/2,s=t-this.element.height()-10;this.show(n,s),i.call(this)},e.prototype.show=function(e,i){t.call(this,e,i),this.isShown||(this.isShown=!0,this.onShow(this))},e.prototype.size=function(e,t){e&&"number"==typeof e&&this.element.width(e),t&&"number"==typeof t&&this.element.width(t)},e}();e.exports=s},59213(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(44890),r=i(71742),a=i(27496),l=i(6479),c=i(18356),u=i(49779),h=i(80867),d=i(91474),p=i(6554),g=i(25152),f=i(44939),m=i(52831),_=i(82192),v=i(84464),b=i(70305),y=i(79284),w=i(64232),C=i(56553),x=i(60179),k=i(67750),S=i(80874),T=i(93049),E=i(79990),P=i(45707),I=i(99631),F=i(9380),A=i(95207),M=new f,j="messaging:conversation:open:tumblelogs",R="messaging:conversation:open:model",D="messaging:conversation:open:id",$="messaging:conversation:open:name",N="messaging:inbox:open",O=r.extend({name:"Messaging",defaults:{resetPollingTypingDebounceRate:3e4},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"inboxAnchorEl","inboxPopoverOptions")),this.eventBus=M,this.user=l(),this.channels=this._getChannelsEnabledForMessagingAsCollection(),this.activeWindow=new d,this.inboxCollection=new P,this.currentBlogModel=new S({channel:this._getInitiallySelectedChannel
1()}),this.favoritesCollection=new F,this.emptyInboxCollection=new F,this.unreadManager=new m({channels:this.channels}),this.inboxBadge=new C({el:this.inboxAnchorEl,channels:this.channels}).render(),this.messagingLogger=new p,this.messagingNotifier=new y({isEnabled:this.isDesktopNotificationEnabled(),notificationIcon:this.getMessagingNotificationIcon()}),this.keyboardManager=new b,this.windowPersistenceManager=new v({user:this.user,isSyncEnabled:!1}),this.notificationSoundManager=new w,this.searchImageQueries=new A,this.windowManager=new _({eventBus:this.eventBus,user:this.user,channels:this.channels,currentBlogModel:this.currentBlogModel,keyboardManager:this.keyboardManager,persistenceManager:this.windowPersistenceManager,inboxConfig:{constructor:x,options:{favoritesCollection:this.favoritesCollection,emptyInboxCollection:this.emptyInboxCollection,appendFavoritesToInboxLimit:this.getAppendFavoritesToInboxLimit(),isAutoFetch:!1,isNewEmptyInboxEnabled:this.isNewEmptyInboxEnabled()},popoverOptions:n.extend({autoTeardown:!0,pinnedSide:"bottom",isFixedPosition:!0,pinnedTarget:this.inboxAnchorEl},this.inboxPopoverOptions)},conversationConfig:{constructor:k,options:{isAutoFetch:!1,collection:this.searchImageQueries,imageUploadMaxBytes:this.getImageUploadMaxBytes(),canModifySafeMode:this.getCanModifySafeMode(),isSafeModeEnabled:o.bool("safe_mode")&&this.user.get("safe_mode"),isProjectXEnabled:!0}}}),this._onConversationMessageInputThrottled=n.throttle(this._onConversationMessageInput,this.get("resetPollingTypingDebounceRate"),{leading:!0,trailing:!1}),this.listenTo(a,j,this._onEventBusOpenConversationUsingTumblelogModels),this.listenTo(a,R,this._onEventBusOpenConversationUsingModel),this.listenTo(a,D,this._onEventBusOpenConversationUsingIdAndParticipant),this.listenTo(a,$,this._onEventBusOpenConversationUsingBlogName),this.listenTo(a,N,this._onEventBusOpenInboxFromRoute),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_OPEN_CONVERSATION_MODEL,this._onOpenConversationUsingConversationModel),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_OPEN_PARTICIPANT_MODELS,this._onOpenConversationUsingParticipantModels),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_OPEN_TUMBLR_URL,this._onConversationClickBlog),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_OPEN_MESSAGING_URL,this._onConversationClickMessagingBlog),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_DELETE_MODEL,this._onConversationDelete),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_FETCHING,this._onConversationFetching),this.listenTo(this.eventBus,this.eventBus.BLOCK,this._onBlock),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_MESSAGES_SEND_REQUESTED,this._onConversationMessagesSendRequested),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_MESSAGE_SENT,this._onConversationMessageSent),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_MESSAGE_FAILED,this._onConversationMessageFailed),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_MESSAGE_INPUT,this._onConversationMessageInputThrottled),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_MESSAGES_UNREAD_FETCHED,this._playConversationSounds),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_MARK_AS_SPAM,this._onConversationMarkAsSpam),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_IMAGE_PREVIEW_ADD,this._onConversationImagePreviewAdd),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_IMAGE_PREVIEW_DISMISS,this._onConversationImagePreviewDismiss),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_IMAGE_PREVIEW_EDIT,this._onConversationImagePreviewEdit),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_IMAGE_LIGHTBOX,this._onConversationImageLightbox),this.listenTo(this.eventBus,this.eventBus.CONVERSATION_COMPOSE_PLUGIN_CLICK,this._onConversationComposePluginClick),this.listenTo(this.eventBus,this.eventBus.NEW_EMPTY_INBOX_SUGGESTION_CLICK,this._onEmptyInboxSuggestionClick),this.listenTo(this.eventBus,this.eventBus.OLD_EMPTY_INBOX_SUGGESTION_CLICK,this._onEmptyInboxSuggestionClick),this.listenTo(this.eventBus,this.eventBus.NEW_EMPTY_INBOX_NEW_MESSAGE_CLICK,this._onEmptyInboxNewMessageClick),this.listenTo(this.eventBus,this.eventBus.OLD_EMPTY_INBOX_NEW_MESSAGE_CLICK,this._onEmptyInboxNewMessageClick),this.listenTo(a,"toaster:updateMessagingUnreadCounts",this._onPollUpdate),this.listenTo(a,"logout",this._onEventBusLogout),this.listenTo(this.currentBlogModel,"change",this._onCurrentBlogModelChange),this.listenTo(this.windowManager,"change",this._onWindowManagerChange),this.listenTo(this.unreadManager,"change:channel",this._onUnreadManagerChannelChange),this.listenTo(this.unreadManager,"change:conversation",this._onUnreadManagerConversationChange),this.listenTo(this.windowManager,"inbox:added",this._onWindowManagerInboxAdded),this.listenTo(this.windowManager,"inbox:removed",this._onWindowManagerInboxRemoved),this.listenTo(this.windowManager,"conversation:added",this._onWindowManagerConversationAdded),this.listenTo(this.windowManager,"conversation:removed",this._onWindowManagerConversationRemoved),this.listenTo(this.windowManager,"conversations:loaded",this._onWindowManagerConversationsLoaded),this.listenTo(this.windowManager,"conversation:minimized",this._onWindowManagerConversationMinimized),this.listenTo(this.windowManager,"conversation:unminimized",this._onWindowManagerConversationUnminimized),this.listenTo(this.messagingNotifier,"notification:display",this._onDesktopNotificationDisplayed),this.listenTo(this.messagingNotifier,"notification:permission:change",this._onDesktopNotificationPermissionChange),this.listenTo(this.channels,"change:unread_messages_count_sum",n.debounce(n.bind(this._onChannelsUnreadMessageCountChange,this),0)),this.messagingPoller=new g({channels:this.channels,user:this.user,callback:n.bind(this._onPollUpdate,this),frequency:this.getPollingFrequencyInbox()}),this._onWindowManagerChange(this.windowManager)},render:function(){return this.inboxAnchorEl&&this.inboxAnchorEl.on("click.messaging",n.bind(this._onClickInboxAnchor,this)),this.windowManager.loadConversationsState(),this},openInboxPopover:function(){this.inboxPopover||(this.inboxPopover=this.windowManager.addInbox(this.inboxCollection))},openConversationPopover:function(e,t){var i;n.isEmpty(e.get("participantUuid"))&&e.set("participantUuid",this.getCurrentBlogId()),i=this.windowManager.getConversationPopover(e),this.windowManager.removeInbox(this.inboxCollection),i?i.refresh(e):this.windowManager.addConversation(e,{context:t})},fetchInbox:function(){var e=this.getCurrentBlogId();
1if(this._pendingInboxRequest&&this._pendingInboxBlog){if(e===this._pendingInboxBlog)return;this._pendingInboxRequest.abort()}this._pendingInboxBlog=e,this._pendingInboxRequest=this.inboxCollection.fetchInbox(e).always(n.bind(function(){this._pendingInboxRequest=null,this._pendingInboxBlog=null},this)).done(n.bind(function(){this.messagingLogger.logInboxOpened(this.inboxCollection.size())},this))},getCurrentChannel:function(){return this.currentBlogModel.getChannel()},getCurrentBlogId:function(){return this.currentBlogModel.getId()},getPollingFrequencyInbox:function(){return n.get(this.data,"polling_frequency_inbox")},getCanModifySafeMode:function(){return n.get(this.data,"can_modify_safe_mode")},getPollingFrequencyConversation:function(){return n.get(this.data,"polling_frequency_conversation")},getAppendFavoritesToInboxLimit:function(){return n.get(this.data,"append_favorites_to_inbox_limit")},isDesktopNotificationEnabled:function(){return n.get(this.data,"is_desktop_notifications_enabled",!1)},isNewEmptyInboxEnabled:function(){return n.get(this.data,"is_new_empty_inbox_enabled",!1)},getBackoffRatesInbox:function(){return[1,1,2,2,4]},getBackoffRatesConversation:function(){return[1,1,1,1,2,2,2,2,4,4,4,4,8,8,8,8,16]},getMessagingNotificationIcon:function(){return n.get(this.data,"messaging_notification_icon","")},getImageUploadMaxBytes:function(){return n.get(this.data,"image_upload_max_bytes",10485760)},_onWindowManagerInboxAdded:function(e,t){this.fetchInbox()},_onWindowManagerInboxRemoved:function(e,t){delete this.inboxPopover,this.messagingLogger.logInboxClosed()},_onWindowManagerConversationAdded:function(e,t,i){var s=n.get(i,"isFromPersistence",!1);t.isMinimized()||(t.fetch().always(n.bind(function(){s||this.messagingLogger.logConversationOpened(e,n.get(i,"context"))},this)),t.focus())},_onWindowManagerConversationRemoved:function(e,t,i){this.messagingLogger.logConversationClosed(e,n.get(i,"context"))},_onWindowManagerConversationsLoaded:function(e,t){0===e.length&&0===t.length||this.messagingLogger.logConversationWindowsLoaded(e,t)},_onWindowManagerConversationMinimized:function(e,t){this.messagingLogger.logConversationMinimized(e)},_onWindowManagerConversationUnminimized:function(e,t){this.messagingLogger.logConversationUnminimized(e)},_getChannelsEnabledForMessagingAsCollection:function(){return new I(n.invoke(this.user.getChannelsEnabledForMessaging(),"toJSON"))},_getInitiallySelectedChannel:function(){return this.channels.get(this.user.getCurrentMessagingChannelUuid())||n.first(this.channels.models)},_onClickInboxAnchor:function(e){e.preventDefault(),this.openInboxPopover()},_onEventBusOpenConversationUsingIdAndParticipant:function(e,t,i){this._openConversationUsingIdAndParticipant(e,t,i)},_onEventBusOpenConversationUsingTumblelogModels:function(e,t){this._openConversationUsingTumblelogModels(e,t)},_onEventBusOpenConversationUsingModel:function(e,t){this.openConversationPopover(e,t)},_onEventBusOpenConversationUsingBlogName:function(e,t){this._openConversationFromBlogName(e,t)},_onEventBusOpenInboxFromRoute:function(){this.openInboxPopover()},_onOpenConversationUsingConversationModel:function(e,t){this.openConversationPopover(e,t)},_openConversationUsingIdAndParticipant:function(e,t,i){var s=new E({id:e,participantUuid:t});s.fetchConversation().then(n.bind(function(){this.openConversationPopover(s,i)},this))},_openConversationUsingTumblelogModels:function(e,t){var i=n.map(e,function(e){return new T(e.toJSON(),{parse:!0})});this._onOpenConversationUsingParticipantModels(i,t)},_onOpenConversationUsingParticipantModels:function(e,t){var i=new T(this.getCurrentChannel().toJSON()),s=n.find(e,function(e){return e.get("name")===i.get("name")});if(n.isEmpty(s)){var o=new E({participants:[i].concat(e),participantUuid:this.getCurrentBlogId()});this.openConversationPopover(o,t)}},_onPollUpdate:function(e){e=n.get(e,"unread_messages"),!0!==n.get(e,"error")&&this.unreadManager.setData(e)},_onConversationClickBlog:function(e){var t=n.get(e,"url"),i=n.get(e,"blogName"),s=n.get(e,"postId"),o=n.get(e,"searchTagTerm"),r=n.get(e,"originalEvent"),l=n.get(e,"otherParticipant"),c=!!l&&-1!==l.get("seconds_since_last_activity");r&&r.preventDefault(),a.trigger("peepr-open-request",{url:t,tumblelog_name:i,post_id:s,searchTagTerm:o}),this.messagingLogger.logPeeprOpen(t,i,s,o,c)},_onConversationClickMessagingBlog:function(e){var t=n.get(e,"blogName"),i=n.get(e,"originalEvent");i&&i.preventDefault(),this._openConversationFromBlogName(t,"conversation-permalink"),this.messagingLogger.logMessagingPermalinkOpen(t)},_onDesktopNotificationDisplayed:function(e){this.messagingLogger.logNotification(e)},_onDesktopNotificationPermissionChange:function(e){e?this.messagingLogger.logNotificationPermissionGranted():this.messagingLogger.logNotificationPermissionDenied()},_onConversationMarkAsSpam:function(e,t){var i;e&&t&&(i=s("%1$s will be blocked and reported. And any trace of this conversation will disappear from your inbox.",t.get("name")),u.confirm(i,n.bind(function(){this.messagingLogger.logConversationSpamIntent(e),this._removeConversation(e),e.markAsSpam().then(n.bind(function(){this.messagingLogger.logConversationSpamSuccess(e)},this)).fail(n.bind(function(){this.messagingLogger.logConversationSpamFail(e)},this))},this),null,s("Mark it spam"),s("Nevermind")))},_onConversationImagePreviewAdd:function(e,t){this.messagingLogger.logImagePreviewAdd(e,t)},_onConversationImagePreviewDismiss:function(e,t){this.messagingLogger.logImagePreviewDismiss(e,t)},_onConversationImagePreviewEdit:function(e,t){this.messagingLogger.logImagePreviewEdit(e,t)},_onConversationImageLightbox:function(e){var t=n.get(e,"lightBoxImageData"),i=n.get(e,"lightBoxIndex",0);a.trigger("lightbox-open-request",t,i)},_onConversationComposePluginClick:function(e,t){this.messagingLogger.logComposePluginClick(e,t)},_onBlock:function(e,t){n.isEmpty(e)||c.confirmBlock(e).then(n.bind(function(){c.block(e).then(n.bind(function(){this._onBlockSuccess(e,t)},this))},this))},_onBlockSuccess:function(e,t){n.isEmpty(e)||(t&&this._removeConversation(t),a.trigger("blocks:block_added",{loggingData:{from:"messaging"}}),this.messagingLogger.logBlock(e))},_removeConversation:function(e){this.windowManager.removeConversation(e),this.inboxCollection.remove(e)},_copyCollectionData:function(e,t){t.reset(e.models),t.setNextLink(e.getNextLink())},_onCurrentBlogModelChange:function(){var e=this.currentBlogModel.getPrevChannel(),t=this.currentBlogModel.getChannel();e&&this._copyCollectionData(this.inboxCollection,e.get("conversations")),t&&(this._copyCollectionData(t.get("conversations"),this.inboxCollection),this.user.setCurrentMessagingChannelUuid(t.get("uuid"))),this.fetchInbox()},_onConversationDelete:function(e){u.confirm(s("Permanently delete this conversation?"),n.bind(function(){this.messagingLogger.logConversationDeleted(e),e.destroy(),this.windowManager.removeConversation(e),this.inboxCollection.remove(e.get("id"))},this),null,s("Delete"),s("Nevermind"))},_onConversationFetching:function(e){this.unreadManager.setConversationModelCount(e,0)},_onUnreadManagerChannelChange:function(e,t){var i=this.getCurrentChannel(),s=n.sum
1(t);this.windowManager.isInboxOpen()&&i===e&&this.fetchInbox(),e.set("unread_messages_count_sum",s)},_onUnreadManagerConversationChange:function(e,t,i){this._generateBrowserNotification(e,t,i),this._setConversationUnreadCount(e,t,i)},_onChannelsUnreadMessageCountChange:function(e,t){t>e.previous("unread_messages_count_sum")&&this._playSoundName("notification-sound")},_playConversationSounds:function(){this._playSoundName("receive-sound")},_playSoundName:function(e){this.user.isSoundsEnabled()&&this.notificationSoundManager.playSoundName(e)},_setConversationUnreadCount:function(e,t,i){var n=this.windowManager.getConversationModelByIdAndParticipant(e,i.get("uuid"));n&&n.set("unreadCount",t)},_generateBrowserNotification:function(e,t,i){var n,s=!1;t<=0||(this.activeWindow.isActive&&this.windowManager.get("isConversationOpen")?(n=this.windowManager.getConversationModelByIdAndParticipant(e,i.get("uuid")))&&this.windowManager.isConversationMinimized(n)&&(s=!0):s=!0,s&&this.messagingNotifier.notifyOnUnread(e,i))},_showErrorMessage:function(e){u.alert(e)},_onWindowManagerChange:function(e){var t,i,n=e.isInboxOpen(),s=e.isConversationOpen(),o=n||s;this.user.isVerifiedEmail()&&o?(s?(t=this.getPollingFrequencyConversation(),i=this.getBackoffRatesConversation()):(t=this.getPollingFrequencyInbox(),i=this.getBackoffRatesInbox()),this.messagingPoller.setFrequency(t),this.messagingPoller.setBackoffRates(i),this.messagingPoller.start()):this.messagingPoller.stop()},_onConversationMessagesSendRequested:function(){this._playSoundName("send-sound")},_onConversationMessageSent:function(e,t){this.messagingLogger.logMessageSent(e,t)},_onConversationMessageFailed:function(e,t){this.messagingLogger.logMessageFailed(e,t)},_onConversationMessageInput:function(e,t){this.messagingPoller.resetPollingFrequency(),this.messagingPoller.poll()},_openConversationFromBlogName:function(e,t){var i=new h({name:e});return i.fetch_popover_data().then(n.bind(function(){n.isEmpty(i.get("uuid"))?this._showErrorMessage(s("Could not load conversation.")):i.get("can_receive_messages")?this._openConversationUsingTumblelogModels([i],t):this._showErrorMessage(s("This Tumblr can't receive messages."))},this))},_onEventBusLogout:function(){this.windowPersistenceManager.clear()},_onEmptyInboxNewMessageClick:function(e){this.messagingLogger.logInboxEmptyNewMessageClick(this.currentBlogModel.getChannel().get("name"),e)},_onEmptyInboxSuggestionClick:function(e,t,i){this.messagingLogger.logEmptySuggestionClick(this.currentBlogModel.getChannel().get("name"),e.get("name"),t,i)}});e.exports=O},59383(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(71742),r=i(27496),a=i(89529),l=i(45668),c=i(73131),u=o.extend({name:"EmbedManager",harnessCollection:{},harnessRequests:{},requestID:0,currentlyPlaying:null,initialize:function(){return a.on("embed*",n.bind(this._handleMessage,this)),this.listenTo(r,"CrtControl:playerCreated",this.createCrtHarness),this.on("harnessCreated",this.__onHarnessCreated),this},createCrtHarness:function(e){e.on("ready",n.bind(function(){var t=e.$el.attr("id");t in this.harnessCollection||(this.harnessCollection[t]=new c(e,t),this.trigger("harnessCreated",this.harnessCollection[t]))},this)),e.on("teardown",n.bind(function(){var t=e.$el.attr("id");this.currentlyPlaying===this.harnessCollection[t]&&(this.currentlyPlaying=null),delete this.harnessCollection[t]},this))},createHarness:function(e){e.embedID in this.harnessCollection?this.harnessCollection[e.embedID].channel.setWindow(e.source):(this.harnessCollection[e.embedID]=new l(e),this.trigger("harnessCreated",this.harnessCollection[e.embedID]))},getHarness:function(e){var t=s.Deferred();return this.harnessCollection[e]?t.resolve(this.harnessCollection[e]):(t.requestID=++this.requestID,t.embedID=e,this.harnessRequests[t.requestID]=t),t.promise()},_handleMessage:function(e){var t,i=JSON.parse(e.data);i&&i.method&&(t=i.method.match(/^(embed\-.+?)\:(.+?)\:(.+?)\:_syn$/))&&(i.embedID=t[1],i.service=t[2],i.postID=t[3],i.source=e.source,this.createHarness(i))},__onHarnessCreated:function(e){n.forEach(this.harnessRequests,n.bind(function(t){t.embedID===e.getData().embedID&&(t.resolve(e),delete this.harnessRequests[t.requestID])},this)),this.listenTo(e,"stateChange",this.__onHarnessStateChange)},__onHarnessStateChange:function(e,t){"playing"===e||"focus"===e?(this.currentlyPlaying&&this.currentlyPlaying!==t&&this.currentlyPlaying.pause(),this.currentlyPlaying=t):this.currentlyPlaying===t&&(this.currentlyPlaying=null)}});e.exports=new u},59386(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(71742),r=i(27496),a=i(67421),l=[],c=o.extend({name:"CrtControl",maxLoopTime:10,playerSelector:"[data-crt-video]",peeprOpen:!1,initialize:function(e){e=e||{},this.listenTo(r,"CrtControl:newPlayer",this.playerFactory,this),this.listenTo(r,"DOMEventor:flatscroll",n.throttle(this.onScroll,500),this),this.listenTo(r,"peepr:close",this.onPeeprClose,this),this.listenTo(r,"peepr:open",this.onPeeprOpen,this)},onPeeprOpen:function(){this.peeprOpen=!0},onPeeprClose:function(){this.peeprOpen=!1},findPlayers:function(e){var t=s(this.playerSelector);t.length&&this.playerFactory(t,e)},playerFactory:function(e,t){n.defer(n.bind(function(){n.each(e,function(e){this.newPlayer(e,t)},this)},this))},newPlayer:function(e,t){if(e.player)return e.player;var i=new a(e,t);return l.push(i),i.render(),this.bindPlayerEvents(i),r.trigger("CrtControl:playerCreated",i,t),i},bindPlayerEvents:function(e){this.listenTo(e,"ready",this.onPlayerReady),this.listenTo(e,"teardown",this.onPlayerTeardown)},onPlayerReady:function(){this.playInViewport()},onPlayerTeardown:function(e){if((e=n.where(l,{_id:e._id})).length){var t=n.indexOf(l,e[0]);t>
1-1&&(e=l.splice(t,1))}},onScroll:function(){this.playInViewport()},pauseAutoplaying:function(){n.each(l,function(e){e.get("autoplay")&&e.get("loaded")&&e.pause()})},getInViewport:function(){var e=this;return n.filter(l,function(t){return!(!t.watcher||e.peeprOpen&&!t.get("isInPeepr"))&&(t.watcher.isFullyInViewport&&t.$el.is(":visible"))})},playInViewport:function(){var e=this.getInViewport();if(e.length){var t=e[0];t.get("paused")&&t.get("autoplay")&&(this.pauseAutoplaying(),t.play())}}});e.exports=new c},59492(e,t,i){"use strict";var n=i(55679),s=i(21391),o=i(71742),r=i(6479),a=i(80867),l=i(27496),c=i(49387),u=i(21550),h=i(9380),d=i(93049),p=i(87343),g=new h,f=o.extend({name:"MessagingSharePost",initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),this.options=e,this.user=r(),this.channels=this._getChannelsEnabledForMessagingAsCollection(),this.messagingShareLogger=new c},render:function(){return this.openPopover(this.options),this},openPopover:function(e){var t,i,s=n.get(e,"postId"),o=n.get(e,"blogUuid"),r=n.get(e,"isNsfw"),a=n.get(e,"favoritesNames",[]),l=n.get(e,"popoverContainer"),c=n.get(e,"pinnedTarget"),h=n.get(e,"externalNetworksData",{}),d=new p(n.extend({post_id:s,tumblelog_name:o},h));return n.isEmpty(s)||n.isEmpty(o)||n.isEmpty(c)?null:(t={viewOptions:n.bind(function(e){return{shareData:{blogUuid:o,postId:s,isNsfw:r},popoverContainer:e.el,favoritesCollection:g,additionalFavorites:this._getAdditionalFavoritesAsParticipants(a),channels:this.channels,externalNetworksDataModel:d,isExternalSharingEnabled:this.isExternalSharingEnabled(),senderBlogUuid:this.user.getCurrentMessagingChannelUuid()}},this),autoTeardown:!0,teardownOnEscape:!1,pinnedSide:"bottom",isFixedPosition:!1,pinnedTarget:c,popoverContainer:l},this.messagingShareLogger.logShareIntent(s,o),i=new u(t).render(),this._afterPopoverOpen(i),i)},isExternalSharingEnabled:function(){return n.get(this.data,"is_external_sharing_enabled",!1)},_afterPopoverOpen:function(e){var t=e.getView();this.listenToOnce(e,"close",function(){this._onPopoverClose(e)}),this.listenTo(t,"external:click",this._onPopoverExternalNetworkShareClick),this.listenTo(t,"external:success",this._onPopoverExternalNetworkShareSuccess),this.listenTo(t,"external:fail",this._onPopoverExternalNetworkShareFail),l.trigger("keycommands:suspend")},_onPopoverClose:function(e){this.stopListening(e),this.stopListening(e.getView()),l.trigger("keycommands:resume")},_onPopoverExternalNetworkShareClick:function(e){this.messagingShareLogger.logExternalNetworkClicked(e)},_onPopoverExternalNetworkShareSuccess:function(e){this.messagingShareLogger.logExternalNetworkShareSuccess(e)},_onPopoverExternalNetworkShareFail:function(e){this.messagingShareLogger.logExternalNetworkShareFail(e)},_getChannelsEnabledForMessagingAsCollection:function(){return new s.Collection(this.user.getChannelsEnabledForMessaging())},_getAdditionalFavoritesAsParticipants:function(e){return n.reduce(e,function(e,t){var i=new a({name:t});return i.get("uuid")&&i.get("can_receive_messages")&&e.push(new d(i.toJSON(),{parse:!0})),e},[],this)}});e.exports=f},59542(e,t,i){"use strict";var n=i(55679),s=i(21391),o=i(27496),r=i(71742),a=i(51805),l=i(95207),c=function(){};c.extend=s.Model.extend,n.extend(c.prototype,s.Events);var u=new c,h=r.extend({name:"ImageSearch",selector:"body",defaults:{resultLimit:200,imageWidth:250,loadFullImageBeforeSelect:!1,query:null,selectedImageUrl:null,loggingContext:null},initialize:function(e){e=e||{},n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"collection")),n.isEmpty(this.collection)&&(this.collection=new l),this.view=new a(n.extend({eventBus:u,collection:this.collection,query:this.get("query"),imageWidth:this.get("imageWidth"),loadFullImageBeforeSelect:this.get("loadFullImageBeforeSelect"),resultLimit:this.get("resultLimit"),selectedImageUrl:this.get("selectedImageUrl"),loggingContext:this.get("loggingContext")},this.viewOptions)),this.listenTo(u,"image:select",function(e,t){this.logGifSearchEvent("select",t),this.trigger("selectImage",e.toJSON(),this.getQuery())}),this.listenTo(u,"image:impression",function(e){this.logGifSearchEvent("impression",e)}),this.listenTo(u,"gifsearch:resultChange",function(e){this.logGifSearchResultChange("search",e)}),this.listenTo(this.view,"dismiss",function(){this.trigger("dismiss")})},render:function(){return this.view.render(),this.trigger("append"),this.view},setQuery:function(e){this.view.setQuery(e)},getQuery:function(){return this.view.getQuery()},getCurrentResults:function(){return this.view.get("currentResults")},logGifSearchEvent:function(e,t){var i={popularSearch:t.model.get("popularSearchTag")?t.model.get("popularSearchTag"):null,query:this.getQuery()?this.getQuery():null,resultsIndex:this.getCurrentResults().indexOf(t.model),top:Math.round(t.$el.position().top),left
1:Math.round(t.$el.position().left),postBlog:t.model.get("postBlog"),postId:t.model.get("postId"),context:this.get("loggingContext")};o.trigger("gifsearch:"+e,{loggingData:i})},logGifSearchResultChange:function(e,t){var i=this.getQuery();if(i){var n={query:i,context:this.get("loggingContext")};o.trigger("gifsearch:"+e,{loggingData:n})}}});e.exports=h},59753(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(71742),r=o.prototype,a=i(59980),l=i(59980).LivePhoto,c=["width","height","data-pin-url","data-pin-description"];var u=o.extend({name:"LivePhotos",autoAppend:!0,initialize:function(){this.instances=[]},create:function(e){var t,i,o=e instanceof s?e:s(e);if(o.length){var r,a,u=o.closest("a, [data-lightbox]");if(u.length)u.on("mousedown.livephoto touchstart.livephoto",function(){r=!1,u.prop("livePhotoSneezeguard",!0),a=setTimeout(function(){u.prop("livePhotoSneezeguard",!1),r=!0},750)}),u.on("click.livephoto",function(e){clearTimeout(a),r&&e.preventDefault()});var h=new l(o.get(0));return this.instances.push(h),t=o,i=h.img,t instanceof s&&(t=t.get(0)),i instanceof s&&(i=i.get(0)),t&&i&&n.forEach(c,function(e){t.hasAttribute(e)&&i.setAttribute(e,t.getAttribute(e))}),h}return null},remove:function(){return a.cleanup(),r.remove.call(this)},append:function(){return a.addStyles(),r.append.call(this)}});e.exports=u},59796(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"container\" data-js-theme-accent-color-on-grey><div class=\"avatar\" data-js-theme-avatar-shape-class><img src=\"' +\n__e( avatarUrl ) +\n'\" alt=\"' +\n__e( name ) +\n'\" title=\"' +\n__e( name ) +\n'\"></div><div class=\"name\">' +\n__e( name ) +\n'</div><div class=\"title\">';\n if (!_.isEmpty(title)) { ;\n__p +=\n__e( title );\n } else { ;\n__p += '&nbsp;';\n } ;\n__p += '</div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},59797(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<div class="menu-burger"><div class="burger bun top"></div><div class="burger patty"></div><div class="burger bun bottom"></div></div><div class="drawer" data-subview="drawer"></div><div class="sneeze-guard"></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},59908(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div class=\"loader-type\" data-subview=\"loaderType\"></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},59929(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(38578),r=i(44384),a=i(13482),l=i(27496),c=r.extend({mixins:[o,a],events:function(){return{click:this.isLoggedIn()?"onClick":this.redirectLink()}},initialize:function(){this.listenTo(this.model,"fastreblog:success",this.onFastReblogged),this.render()},render:function(){return this.$el.toggleClass("reblogged",!!this.get("startedFastReblog")||!!this.model.get("reblogged")),this.$el.toggleClass("queued",!!this.get("fastRebloggedQueue")),this.started_fast_reblog=!1,this},onClick:function(e){return e.preventDefault(),this._logReblog(),e.altKey&&!this.model.reblogged?(this.set("startedFastReblog",!0),this.model.fastReblog()):this.model.reblog()},onFastReblogged:function(e){this.set("fastReblogQueue",e);var t=s('<div class="post_reblog_poof post_poof"></div>');e&&t.addClass("queue"),this.get("startedFastReblog")||this.$el.height()>s(window).height()&&t.css("top",.5*s(window).height()),this.$el.append(t),n.delay(function(e){t.fadeOut(200,function(){t.remove(),e.render()})},300,this)},_logReblog:function(){l.trigger("post:log-reblog",{loggingData:{blog:this.model.get("tumblelog"),post_id:this.model.id,position:this.model.get("collection_index"),initiator:"post_masonry"}})}});e.exports=c},59952(e,t,i){"use strict";var n=i(74692),s=i(55679),o=(i(17604).sprintf,i(28724)),r=i(27496),a=n("body"),l=n(window),c=i(53010);var u=new o({removeAutoTeardown:function(){this._popoverBase.clickOutside&&(this._popoverBase.clickOutside.remove(),this._popoverBase.clickOutside=null)},setupAutoTeardown:function(){this.isRendered()&&(this.removeAutoTeardown(),this._popoverBase.autoTeardown&&(this._popoverBase.clickOutside=new c(this.el,this.options),this._popoverBase.clickOutside.on("click:outside",this.onClickOutside,this)))},onClickOutside:function(){this._popoverBase.shouldTeardown?(this._popoverBase.lastAutoTeardown=s.now(),this.teardown()):this._popoverBase.shouldTeardown=!0},reposition:function(){if(this.$pinned.closest("body").length){var e=this.pinnedRect(),t=this.isContainerBody?0:this.$container.scrollTop(),i=this.isContainerBody?0:this.$container.scrollLeft(),n=this.isContainerBody?0:this.$container.offset().top,o=this.isContainerBody?0:this.$container.offset().left,r=this._popoverBase.shift,a=this._popoverBase.pinnedSide,l={visibility:"visible"},c={},u=this.$el.width(),h=null,d=null,p=null,g=null;this.debug("reposition: pinnedSide=%s, shift=%O, pinnedRect=%O",a,r,e),this._popoverBase.isFixedPosition&&(l.position="fixed"),"top"===a||"bottom"===a?(s.extend(l,{left:e.left+Math.floor(e.width/2)+r.x}),(c={top:e.top+t-r.y,bottom:e.top+t+e.height+r.y,left:e.left+i-r.x,r
1ight:e.left+i+e.width+r.x}).center=(c.right-c.left)/2,h=n+c.top-this.$el.height(),d=n+c.bottom+this.$el.height(),"top"===a&&this._crossesViewportEdge("top",h)&&!this._crossesViewportEdge("bottom",d)&&(a="bottom"),"bottom"===a&&this._crossesViewportEdge("bottom",d)&&!this._crossesViewportEdge("top",h)&&(a="top"),"bottom"===a?s.extend(l,{top:c.bottom,transform:"translateX(-50%)"}):"top"===a&&s.extend(l,{top:c.top,right:"",transform:"translateX(-50%) translateY(-100%)"}),p=o+(c.center+c.left)-u/2,g=o+(c.center+c.left)+u/2,this._crossesViewportEdge("left",p)&&!this._crossesViewportEdge("right",g)&&s.extend(l,{left:this._popoverBase.minDistanceFromContainer+"px",transform:"top"===a?"translateX(0) translateY(-100%)":"translateX(0)"}),!this._crossesViewportEdge("left",p)&&this._crossesViewportEdge("right",g)&&s.extend(l,{left:"auto",right:this._popoverBase.minDistanceFromContainer+"px",transform:"top"===a?"translateX(0) translateY(-100%)":"translateX(0)"})):"left"===a||"right"===a?(s.extend(l,{top:e.top-r.y}),p=o+(c={left:e.left+i-r.x,r
1ight:e.left+i+e.width+r.x}).left-this.$el.width(),g=o+c.right+this.$el.width(),"left"===a&&this._crossesViewportEdge("left",p)&&!this._crossesViewportEdge("right",g)&&(a="right"),"right"===a&&this._crossesViewportEdge("right",g)&&!this._crossesViewportEdge("left",p)&&(a="left"),"left"===a?s.extend(l,{left:c.left,transform:"translateX(-100%) translateY(-50%)"}):"right"===a&&s.extend(l,{left:c.right,transform:"translateY(-50%)"})):s.extend(l,{top:e.top-r.y,left:e.left+r.x,transform:""}),s.extend(l,{transform:l.transform}),this.$el.css(l),this.debug("reposition: ad-hoc css %O",l),this.$el.removeClass("top bottom left right").addClass(a)}else this.$el.css("visibility","hidden")},_crossesViewportEdge:function(e,t){var i=n(window),s={top:i.scrollTop(),left:i.scrollLeft(),right:i.scrollLeft()+i.width(),bottom:i.scrollTop()+i.height()};return s=this._popoverBase.isFixedPosition?{top:0,left:0,right:i.width(),bottom:i.height()}:{top:i.scrollTop(),left:i.scrollLeft(),right:i.scrollLeft()+i.width(),bottom:i.scrollTop()+i.height()},this.debug("viewportCheck against %s side (%s) coordinate=[%s]",e,s[e],t),"top"===e?s.top>t:"bottom"===e?s.bottom<t:"left"===e?s.left>t:"right"===e?s.right<t:void 0},isRendered:function(){return this.rendered||this._rendered},isOrWasRecentlyRendered:function(e){s.isNumber(e)||(e=100);var t=this._popoverBase.lastAutoTeardown;return s.now()-t<e||this.isRendered()},setPinnedSide:function(e){return this._popoverBase.pinnedSide=e,this},setPinnedTarget:function(e){return this.$pinned=n(e).addClass("pinned-target"),this.debug("setPinnedTarget: %O",this.$pinned),this}
1,setPopoverContainer:function(e){return this.$container=n(e),this.isContainerBody=this.$container.is(a),this.debug("setPopoverContainer: %O, isContainerBody=%s",this.$container,this.isContainerBody),this},setShift:function(e){if(!s.isObject(e)||!s.isNumber(e.x)||!s.isNumber(e.y))throw new Error("Popover shift needs to be: {Object} => x: {Number}, y: {Number}");return this._popoverBase.shift.x=e.x,this._popoverBase.shift.y=e.y,this},getShift:function(){return this._popoverBase.shift},_initializeDebugger:function(){this.debug=s.noop},defaults:{pinnedRect:function(){var e,t,i=this.$container.offset();t=e=this.$pinned.offset(),this._popoverBase.isFixedPosition&&(this.isContainerBody?e.top-=l.scrollTop():e.top-=this.$container.scrollTop());var n={};return n.height=this.$pinned.outerHeight(),n.width=this.$pinned.outerWidth(),n.top=Math.round(e.top-i.top),n.left=Math.round(t.left-i.left),n.bottom=Math.round(n.top+n.height),n.right=Math.round(n.left+n.width),this.debug("pinnedRect calculation: container %O, pinned %O, containerOffset %O, pinnedOffset %O",this.$container,this.$pinned,i,t),this.debug("pinnedRect results: height(pinnedOuterHeight)=%s, width(pinnedOuterWidth)=%s, top(pTop-cTop)=%s, left=(pLeft-cLeft)=%s, bottom(top+height)=%s, right(left+width)=%s",n.height,n.width,n.top,n.left,n.bottom,n.right),n},teardown:s.noop},after:{initialize:function(e){var t={identifier:"popover",pinnedSide:"bottom",className:"popover--base",autoTeardown:!0,teardownOnEscape:!0,minDistanceFromContainer:10,shift:{x:0,y:0},clickOutside:null,lastAutoTeardown:0,shouldTeardown:!0,isFixedPosition:!1};this._popoverBase=s.defaults(s.pick(e||{},s.keys(t)),t),this._initializeDebugger(),this.setPinnedTarget(e.pinnedTarget||null),this.setPopoverContainer(e.popoverContainer||a),this._popoverBase.autoTeardown&&this.listenTo(this,"rendered",this.setupAutoTeardown)},render:function(){this.$el.addClass(this._popoverBase.className),this.$el.appendTo(this.$container);var e=this.$el.children().first(),t=e.width();e.width(t-t%2),this.reposition(),this.isContainerBody&&(this.debug("DOMEventor subscribe: flatresize + flatscroll reposition active"),this.listenTo(r,"DOMEventor:flatresize",this.reposition),this._popoverBase.isFixedPosition||this.listenTo(r,"DOMEventor:flatscroll",this.reposition)),this._popoverBase.teardownOnEscape&&this.listenTo(r,"DOMEventor:keyup:escape",this.teardown),this.trigger("open",this),r.trigger(this._popoverBase.identifier+":open",this)},teardown:function(){this.$pinned.removeClass("pinned-target"),this._popoverBase.teardownOnEscape&&this.stopListening(r,"DOMEventor:keyup:escape"),this.removeAutoTeardown(),this.trigger("close",this),r.trigger(this._popoverBase.identifier+":close",this)}},before:{teardown:function(){this.$el.off("mousewheel DOMMouseScroll")}}});e.exports=u},59980(e){var t;t=function(){return function(e){var t={};function i(n){if(t[n])return t[n].exports;var s=t[n]={exports:{},id:n,loaded:!1};return e[n].call(s.exports,s,s.exports,i),s.loaded=!0,s.exports}return i.m=e,i.c=t,i.p="",i(0)}([function(e,t,i){var n=i(1),s=i(4),o=0,r=!0;function a(e,t){r&&l(),"object"==typeof e&&"[object Object]"===e.toString()&&(e=(t=e).elements,delete t.elements),e||(e="img[data-live-photo]"),"string"==typeof e&&(e=document.querySelectorAll(e)),e instanceof HTMLElement&&(e=[e]);var i=[];return Array.prototype.forEach.call(e,function(e){if("string"==typeof e&&(e=document.querySelector(e)),e){var s=new n(e,t);i.push(s)}}),i}function l(){s.use(),o++}function c(e,t){return a(e,t)}c.initialize=a,c.addStyles=l,c.noStyles=function(){r=!1},c.cleanup=function(){for(;o>0;)s.unuse(),o--},c.LivePhoto=n,e.exports=c},function(e,t,i){var n=i(2),s="ontouchstart"in window||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints;function o(e,t,i,s){var o=document.createElement("video");return o.src=e+(i?"#"+i:""),o.controls=!1,o.muted=s||!1,o.preload="auto",t&&(o.className=t),n(o,!s),o}function r(e,t){if(e.paused){var i=e.muted,n=e.currentTime,s=function(){e.removeEventListener("loadedmetadata",s),e.currentTime=n,t&&t(e)};e.muted=!0,e.play(),e.pause(),e.muted=i,e.duration>=0?s():e.addEventListener("loadedmetadata",s)}}function a(){var e=["mousedown"];return s&&e.push("touchstart"),e}function l(){var e=["mouseup","mouseout"];return s&&e.push("touchend"),e}function c(e,t,i,n){if(!(this instanceof c))return new c(e,t,i,n);var s,r;if(e instanceof HTMLElement&&(n=t,t=(r=e).getAttribute("data-live-photo"),i=parseFloat(r.getAttribute("data-live-photo-still-image-time")),e=r.src),n||(n={}),this.postrollMs=n.postrollMs||375,this.deactivateMs=n.deactivateMs||500,this.previewMs=n.previewMs||500,this.stillImageTime=i||NaN,!e&&!n.noErrors)throw new Error("LivePhoto 
1Error: Missing keyframeUrl");if(!t&&!n.noErrors)throw new Error("LivePhoto Error: Missing videoUrl");s=function(e,t,i){var n=document.createElement("div");n.className="live-photo",n.setAttribute("data-live-photo","");var s=document.createElement("img");s.className="live-photo-keyframe",s.src=e;var r=o(t,"live-photo-postroll",i,!0),a=o(t,"live-photo-video"),l=document.createElement("i");return l.className="live-photo-icon",n.appendChild(s),n.appendChild(r),n.appendChild(a),n.appendChild(l),{container:n,img:s,postroll:r,video:a,icon:l}}(e,t,i),r&&(r.parentNode.insertBefore(s.container,r),r.parentNode.removeChild(r)),this.container=s.container,this.img=s.img,this.video=s.video,this.postroll=s.postroll,this.icon=s.icon,this.__onVideoCanPlayThrough=this._onVideoCanPlayThrough.bind(this),this.__onVideoLoadededMetadata=this._onVideoLoadededMetadata.bind(this),this.__onPostrollTimeUpdate=this._onPostrollTimeUpdate.bind(this),this.__startVideoPlayback=this._startVideoPlayback.bind(this),this.__startPostrollPlayback=this._startPostrollPlayback.bind(this),this.__resetPlayback=this._resetPlayback.bind(this),this.__resetPreview=this._resetPreview.bind(this),this.video.addEventListener("canplaythrough",this.__onVideoCanPlayThrough),this.video.duration?(this._setDuration(this.video.duration),this._resetPostroll()):(this._setDuration(0),this.video.addEventListener("loadedmetadata",this.__onVideoLoadededMetadata)),this._playing=!1,this._canPlayThrough=!1,this._playWhenReady=!1,!1!==n.useEventHandlers&&this._addEventHandlers(n.playEvents,n.stopEvents)}c.prototype={_addEventHandlers:function(e,t){var i=this.container,n=!1,s=this.play.bind(this),o=this.video,c=this.postroll,u=function(e){if(e.preventDefault(),n)s();else{var t=!1,i=!1;r(o,function(){t=!0,i&&s()}),r(c,function(){i=!0,t&&s()}),n=!0}};e&&!1!==e||(e=a),"function"==typeof e&&(e=e(this)),"string"==typeof e&&(e=e.split(/[,\s]+/)),e.forEach(function(e){e&&i.addEventListener(e,u)});var h=this.stop.bind(this),d=function(e){e.preventDefault(),h()};t&&!1!==t||(t=l),"function"==typeof t&&(t=t(this)),"string"==typeof t&&(t=t.split(/[,\s]+/)),t.forEach(function(e){e&&i.addEventListener(e,d)})},_onVideoCanPlayThrough:function(){this._canPlayThrough=!0,this._playWhenReady&&(this._playWhenReady=!1,this.play()),this.container.classList.remove("loading"),this.video.removeEventListener("canplaythrough",this.__onVideoCanPlayThrough)},_onVideoLoadededMetadata:function(){this._setDuration(this.video.duration||0),this._resetPostroll(),this.video.removeEventListener("loadedmetadata",this.__onVideoLoadededMetadata)},_onPostrollTimeUpdate:function(e){this.postroll.currentTime>=this.stillImageTime-.1&&this._resetPreview()},_clearTimeouts:function(){clearTimeout(this._resetVideoTimeout),clearTimeout(this._resetPostrollTimeout),clearTimeout(this._resetPreviewTimeout),this.postroll.removeEventListener("timeupdate",this.__onPostrollTimeUpdate)},_setDuration:function(e){this.duration=e,("number"!=typeof this.stillImageTime||isNaN(this.stillImageTime))&&(this.stillImageTime=.5*e),this.previewStart=Math.max(0,this.stillImageTime-this.previewMs/1e3)},_resetPostroll:function(){this.postroll.pause(),this.postroll.currentTime=this.stillImageTime},_resetVideo:function(){this.video.pause(),this.video.currentTime=0,this.video.muted=!1},_startVideoPlayback:function(){this.video.play(),this._resetPostroll()},_startPostrollPlayback:function(){this._resetPostroll(),this.postroll.play()},_resetPlayback:function(){this._playing=!1,this._resetVideo(),this._resetPostroll()},_resetPreview:function(){this.postroll.removeEventListener("timeupdate",this.__onPostrollTimeUpdate),this._resetPostroll(),this.container.classList.remove("preview")},load:function(){this.video.load(),this.postroll.load()},play:function(){if(!this._playing){if(!this._canPlayThrough)return this._playWhenReady=!0,this._clearTimeouts(),this.load(),void this.container.classList.add("loading");this._playing=!0,this._clearTimeouts(),this._startPostrollPlayback(),this.video.currentTime=0,this._resetPostrollTimeout=setTimeout(this.__startVideoPlayback,this.postrollMs),this.container.classList.add("active")}},stop:function(){this._playing&&(this.video.muted=!0,this._clearTimeouts(),this.container.classList.remove("active"),this._resetVideoTimeout=setTimeout(this.__resetPlayback,this.deactivateMs))},preview:function(){this._playing||(this._clearTimeouts(),this.postroll.currentTime=this.previewStart,this.postroll.play(),this.container.classList.add("preview"),this._previewCompleteTimeout=setTimeout(this.__resetPreview,1e3*(this.stillImageTime-this.previewStart)),this.postroll.addEventListener("timeupdate",this.__onPostrollTimeUpdate))}},e.exports=c},function(e,t,i){"use strict";var n,s=(n=i(3))&&"object"==typeof n&&"default"in n?n.default:n;function o(e){var t,i;function n(s){t=requestAnimationFrame(n),e(s-(i||s)),i=s}this.start=function(){t||n(0)},this.stop=function(){cancelAnimationFrame(t),t=null,i=0}}function r(e,t,i,n){function s(t){Boolean(e[i])===Boolean(n)&&t.stopImmediatePropagation(),delete e[i]}return e.addEventListener(t,s,!1),s}function a(e,t,i,n){function s(e){i[t]=e}n&&s(e[t]),Object.defineProperty(e,t,{get:function(){return i[t]},set:s})}function l(e,t,i){i.addEventListener(t,function(){return e.dispatchEvent(new Event(t))})}function c(e,t){Promise.resolve().then(function(){e.dispatchEvent(new Event(t))})}var u,h=/iPhone|iPod/i.test(navigator.userAgent)&&void 0===document.head.style.grid,d=s(),p=s(),g=s("nativeplay"),f=s("nativepause"),m=[],_=0;function v(e,t,i){(u||0)+200<Date.now()&&(e[p]=!0,u=Date.now()),i||(e.currentTime=t),m[++_%3]=100*t|0}function b(e){return e.driver.currentTime>=e.video.duration}function y(e){var t=this;t.video.readyState>=t.video.HAVE_FUTURE_DATA?(t.hasAudio||(t.driver.currentTime=t.video.currentTime+e*t.video.playbackRate/1e3,t.video.loop&&b(t)&&(t.driver.currentTime=0)),v(t.video,t.driver.currentTime)):t.video.networkState!==t.video.NETWORK_IDLE||t.video.buffered.length||t.video.load(),t.video.ended&&(delete t.video[p],t.video.pause(!0))}function w(){var e=this,t=e[d];e.webkitDisplayingFullscreen?e[g]():("data:"!==t.driver.src&&t.driver.src!==e.src&&(v(e,0,!0),t.driver.src=e.src),e.paused&&(t.paused=!1,e.buffered.length||e.load(),t.driver.play(),t.updater.start(),t.hasAudio||(c(e,"play"),t.video.readyState>=t.video.HAVE_ENOUGH_DATA&&c(e,"playing"))))}function C(e){var t=this,i=t[d];i.driver.pause(),i.updater.stop(),t.webkitDisplayingFullscreen&&t[f](),i.paused&&!e||(i.paused=!0,i.hasAudio||c(t,"pause"),t.ended&&(t[p]=!0,c(t,"ended")))}function x(e,t){var i=e[d]={};i.paused=!0,i.hasAudio=t,i.video=e,i.updater=new o(y.bind(i)),t?i.driver=function(e){var t=new Audio;return l(e,"play",t),l(e,"playing",t),l(e,"pause",t),t.crossOrigin=e.crossOrigin,t.src=e.src||e.currentSrc||"data:",t}(e):(e.addEventListener("canplay",function(){e.paused||c(e,"playing")}),i.driver={src:e.src||e.currentSrc||"data:",muted:!0,paused:!0,pause:function(){i.driver.paused=!0},play:function(){i.driver.paused=!1,b(i)&&v(e,0)},get ended(){return b(i)}}),e.addEventListener("emptied",function(){var t=!i.driver.src||"data:"===i.driver.src;i.driver.src&&i.driver.src!==e.src&&(v(e,0,!0),i.driver.src=e.src,t?i.driver.play():i.updater.stop())},!1),e.addEventListener("webkitbeginfullscreen",function(){e.paused?t&&!i.driver.buffered.length&&i.driver.load():(e.pause(),e[g]())}),t&&(e.addEventListener("webkitendfullscreen",function(){i.driver.currentTime=e.currentTime}),e.addEventListener("seeking",function(){m.indexOf(100*e.currentTime|0)<0&&(i.driver.currentTime=e.currentTime)}))}function k(e,t,i){void 0===t&&(t=!0),void 0===i&&(i=!0),i&&!h||e[d]||(x(e,t),function(e){var t=e[d];e[g]=e.play,e[f]=e.pause,e.play=w,e.pause=C,a(e,"paused",t.driver),a(e,"muted",t.driver,!0),a(e,"playbackRate",t.driver,!0),a(e,"ended",t.driver),a(e,"loop",t.driver,!0),r(e,"seeking"),r(e,"seeked"),r(e,"timeupdate",p,!1),r(e,"ended",p,!1)}(e),e.classList.add("IIV"),!t&&e.autoplay&&e.play(),"MacIntel"!==navigator.platform&&"Windows"!==navigator.platform||console.warn("iphone-inline-video is not guaranteed to work in emulated environments"))}k.isWhitelisted=h,e.exports=k},function(e,t){"use strict";var i="undefined"==typeof Symbol?function(e){return"@"+(e||"@")+Math.random()}:Symbol;e.exports=i},function(e,t,i){var n,s=0,o=i(5);"string"==typeof o&&(o=[[e.id,o,""]]),t.use=t.ref=function(){return s++||(t.locals=o.locals,n=i(7)(o,{})),t},t.unuse=t.unref=function(){--s||(n(),n=null)}}
1,function(e,t,i){(e.exports=i(6)()).push([e.id,".live-photo {\n  position: relative;\n  overflow: hidden;\n  cursor: pointer; }\n  .live-photo video,\n  .live-photo img {\n    display: block;\n    max-width: 100%;\n    pointer-events: none;\n    -ms-touch-action: none;\n        touch-action: none; }\n  .live-photo video {\n    position: absolute;\n    top: 0;\n    right: 0;\n    bottom: 0;\n    left: 0;\n    width: 100%;\n    height: 100%; }\n    .live-photo video::-webkit-media-controls-start-playback-button {\n      display: none; }\n  .live-photo .live-photo-icon {\n    display: block;\n    position: absolute;\n    top: 12px;\n    left: 12px;\n    width: 24px;\n    height: 24px;\n    background: url(\"data:image/svg+xml;charset=utf-8,%3Csvg width='48' height='48' viewBox='0 0 48 48' xmlns='http://www.w3.org/2000/svg' fill='%23fff'%3E%3Ctitle%3ELive Photo%3C/title%3E%3Cg fill-rule='evenodd'%3E%3Cpath d='M24 36c6.627 0 12-5.373 12-12s-5.373-12-12-12-12 5.373-12 12 5.373 12 12 12zm0-2c5.523 0 10-4.477 10-10s-4.477-10-10-10-10 4.477-10 10 4.477 10 10 10z'/%3E%3Cpath d='M24 29a5 5 0 1 0 0-10 5 5 0 0 0 0 10zm0-3a2 2 0 1 0 0-4 2 2 0 0 0 0 4zm0-19a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm4.788.63a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm4.462 1.85a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm3.831 2.94a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm2.94 3.831a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm1.849 4.462a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm.63 4.788a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm-.63 4.788a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm-1.85 4.461a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm-2.94 3.831a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm-3.831 2.94a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm-4.462 1.849a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM24 44a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm-4.788-.63a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm-4.462-1.85a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm-3.831-2.94a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm-2.94-3.831a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM6.13 30.288a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM5.5 25.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm.63-4.788a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm1.85-4.462a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm2.94-3.831a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm3.831-2.94a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zm4.462-1.849a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3z'/%3E%3C/g%3E%3C/svg%3E\") center center;\n    background-size: contain;\n    -webkit-filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.5));\n            filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.5));\n    pointer-events: none; }\n  .live-photo .live-photo-postroll,\n  .live-photo .live-photo-video {\n    opacity: 0; }\n  .live-photo .live-photo-video {\n    -webkit-filter: blur(7.5px);\n            filter: blur(7.5px); }\n  .live-photo .live-photo-keyframe,\n  .live-photo .live-photo-postroll,\n  .live-photo .live-photo-video {\n    will-change: transform, filter, opacity;\n    transition: opacity 0.5s linear, -webkit-transform 0.5s ease-out, -webkit-filter 0.5s linear;\n    transition: transform 0.5s ease-out, filter 0.5s linear, opacity 0.5s linear;\n    transition: transform 0.5s ease-out, filter 0.5s linear, opacity 0.5s linear, -webkit-transform 0.5s ease-out, -webkit-filter 0.5s linear; }\n  .live-photo.loading .live-photo-icon {\n    -webkit-animation: live-photo-icon-loading 0.5s linear alternate infinite both;\n            animation: live-photo-icon-loading 0.5s linear alternate infinite both; }\n  .live-photo.preview .live-photo-postroll {\n    opacity: 1;\n    transition-duration: 0s; }\n  .live-photo.active video,\n  .live-photo.active img {\n    -webkit-transform: scale(1.075, 1.075);\n        -ms-transform: scale(1.075, 1.075);\n            transform: scale(1.075, 1.075); }\n  .live-photo.active .live-photo-postroll {\n    -webkit-animation: live-photo-post-roll 1s both;\n            animation: live-photo-post-roll 1s both; }\n  .live-photo.active .live-photo-video {\n    opacity: 1;\n    -webkit-filter: none;\n            filter: none;\n    transition-delay: 0.375s;\n    transition-duration: 0.625s; }\n\n@-webkit-keyframes live-photo-icon-loading {\n  0% {\n    opacity: 1; }\n  100% {\n    opacity: 0.75; } }\n\n@keyframes live-photo-icon-loading {\n  0% {\n    opacity: 1; }\n  100% {\n    opacity: 0.75; } }\n\n@-webkit-keyframes live-photo-post-roll {\n  0% {\n    opacity: 0;\n    -webkit-filter: blur(0);\n            filter: blur(0); }\n  2% {\n    opacity: 1; }\n  37.5% {\n    opacity: 1;\n    -webkit-filter: blur(7.5px);\n            filter: blur(7.5px); }\n  100% {\n    opacity: 0; } }\n\n@keyframes live-photo-post-roll {\n  0% {\n    opacity: 0;\n    -webkit-filter: blur(0);\n            filter: blur(0); }\n  2% {\n    opacity: 1; }\n  37.5% {\n    opacity: 1;\n    -webkit-filter: blur(7.5px);\n            filter: blur(7.5px); }\n  100% {\n    opacity: 0; } }\n",""])},function(e,t){e.exports=function(){var e=[];return e.toString=function(){for(var e=[],t=0;t<this.length;t++){var i=this[t];i[2]?e.push("@media "+i[2]+"{"+i[1]+"}"):e.push(i[1])}return e.join("")},e.i=function(t,i){"string"==typeof t&&(t=[[null,t,""]]);for(var n={},s=0;s<this.length;s++){var o=this[s][0];"number"==typeof o&&(n[o]=!0)}for(s=0;s<t.length;s++){var r=t[s];"number"==typeof r[0]&&n[r[0]]||(i&&!r[2]?r[2]=i:i&&(r[2]="("+r[2]+") and ("+i+")"),e.push(r))}},e}},function(e,t,i){var n={},s=function(e){var t;return function(){return void 0===t&&(t=e.apply(this,arguments)),t}},o=s(function(){return/msie [6-9]\b/.test(window.navigator.userAgent.toLowerCase())}),r=s(function(){return document.head||document.getElementsByTagName("head")[0]}),a=null,l=0,c=[];function u(e,t){for(var i=0;i<e.length;i++){var s=e[i],o=n[s.id];if(o){o.refs++;for(var r=0;r<o.parts.length;r++)o.parts[r](s.parts[r]);for(;r<s.parts.length;r++)o.parts.push(f(s.parts[r],t))}else{var a=[];for(r=0;r<s.parts.length;r++)a.push(f(s.parts[r],t));n[s.id]={id:s.id,refs:1,parts:a}}}}function h(e){for(var t=[],i={},n=0;n<e.length;n++){var s=e[n],o=s[0],r={css:s[1],media:s[2],sourceMap:s[3]};i[o]?i[o].parts.push(r):t.push(i[o]={id:o,parts:[r]})}return t}function d(e,t){var i=r(),n=c[c.length-1];if("top"===e.insertAt)n?n.nextSibling?i.insertBefore(t,n.nextSibling):i.appendChild(t):i.insertBefore(t,i.firstChild),c.push(t);else{if("bottom"!==e.insertAt)throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'.");i.appendChild(t)}}function p(e){e.parentNode.removeChild(e);var t=c.indexOf(e);t>=0&&c.splice(t,1)}function g(e){var t=document.createElement("style");return t.type="text/css",d(e,t),t}function f(e,t){var i,n,s;if(t.singleton){var o=l++;
1i=a||(a=g(t)),n=v.bind(null,i,o,!1),s=v.bind(null,i,o,!0)}else e.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(i=function(e){var t=document.createElement("link");return t.rel="stylesheet",d(e,t),t}(t),n=y.bind(null,i),s=function(){p(i),i.href&&URL.revokeObjectURL(i.href)}):(i=g(t),n=b.bind(null,i),s=function(){p(i)});return n(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;n(e=t)}else s()}}e.exports=function(e,t){void 0===(t=t||{}).singleton&&(t.singleton=o()),void 0===t.insertAt&&(t.insertAt="bottom");var i=h(e);return u(i,t),function(e){for(var s=[],o=0;o<i.length;o++){var r=i[o];(a=n[r.id]).refs--,s.push(a)}for(e&&u(h(e),t),o=0;o<s.length;o++){var a;if(0===(a=s[o]).refs){for(var l=0;l<a.parts.length;l++)a.parts[l]();delete n[a.id]}}}};var m,_=(m=[],function(e,t){return m[e]=t,m.filter(Boolean).join("\n")});function v(e,t,i,n){var s=i?"":n.css;if(e.styleSheet)e.styleSheet.cssText=_(t,s);else{var o=document.createTextNode(s),r=e.childNodes;r[t]&&e.removeChild(r[t]),r.length?e.insertBefore(o,r[t]):e.appendChild(o)}}function b(e,t){var i=t.css,n=t.media;if(n&&e.setAttribute("media",n),e.styleSheet)e.styleSheet.cssText=i;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(i))}}function y(e,t){var i=t.css,n=t.sourceMap;n&&(i+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(n))))+" */");var s=new Blob([i],{type:"text/css"}),o=e.href;e.href=URL.createObjectURL(s),o&&URL.revokeObjectURL(o)}}])},e.exports=t()},60179(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(98237),r=i(50283),a=i(96152),l=i(63522),c=i(94121),u=i(72578),h=i(71315),d=i(69464),p=i(71271),g=r.extend({className:"messaging-inbox",template:p,defaults:{isLoading:!1,isAutoFetch:!0,isEmpty:!1,isLoadingEmptyInboxFavorites:!1,numFavorites:5},mixins:[o],subviews:{headerView:{constructor:c,options:function(e){return{eventBus:e.eventBus,user:e.user,channels:e.channels,currentBlogModel:e.currentBlogModel,popoverContainer:e.popoverContainer,isNewEmptyInboxEnabled:e.isNewEmptyInboxEnabled}}},composeView:{constructor:u,options:function(e){return{eventBus:e.eventBus,favoritesCollection:e.favoritesCollection,currentBlogModel:e.currentBlogModel,keyboardManager:e.keyboardManager,isNewEmptyInboxEnabled:e.isNewEmptyInboxEnabled}}},conversationsView:{constructor:l,options:function(e){return{eventBus:e.eventBus,collection:e.collection,emptyInboxCollection:e.emptyInboxCollection,currentBlogModel:e.currentBlogModel,channels:e.channels,favoritesCollection:e.favoritesCollection,appendFavoritesToInboxLimit:e.appendFavoritesToInboxLimit,isNewEmptyInboxEnabled:e.isNewEmptyInboxEnabled}}},inboxRecipientsView:{constructor:d,options:function(e){return{eventBus:e.eventBus,collection:e.favoritesCollection,title:s("Recently Followed"),context:"new:inbox:empty",isNewEmptyInboxEnabled:e.isNewEmptyInboxEnabled}}},emptyView:{constructor:h,options:function(e){return{eventBus:e.eventBus,collection:e.emptyInboxCollection}}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","collection","user","channels","favoritesCollection","emptyInboxCollection","popoverContainer","currentBlogModel","appendFavoritesToInboxLimit","keyboardManager","isNewEmptyInboxEnabled"))},afterRenderSubviews:function(){this.loader=new a({$container:this.$el,type:"bar",classModifiers:"top",loading:!1}),this.set({isLoading:!this.getCurrentChannel().get("isInboxFetched"),isEmpty:0===this.collection.length}),this.listenTo(this,"change",this._setViewStates),this.listenTo(this.collection,"sync error",this._onSyncCollection),this.listenTo(this.collection,"update reset",this._onChangeCollection),this.listenTo(this.collection,"request",this._onRequestCollection),this.listenTo(this.composeView,"submit",this._onComposeSubmitRecipient),this.listenTo(this.headerView,"change:isComposing",this._setViewStates),this._setVie
1wStates(),this.get("isAutoFetch")&&this.fetch(),this._fetchEmptyInboxFavorites(),this.isNewEmptyInboxEnabled&&this._fetchFavorites()},beforeRemove:function(){this.keyboardManager.remove("inbox")},getTemplateData:function(){return{isNewEmptyInboxEnabled:this.isNewEmptyInboxEnabled}},getCurrentChannel:function(){return this.currentBlogModel.getChannel()},fetch:function(e){this.collection.fetchInbox(this.currentBlogModel.getId(),e)},_onComposeSubmitRecipient:function(e){this.eventBus.trigger(this.eventBus.CONVERSATION_OPEN_PARTICIPANT_NAMES,e)},_setViewStates:function(){var e=this.get("isEmpty"),t=this.get("isLoading")||this.get("isLoadingEmptyInboxFavorites"),i=this.headerView.get("isComposing");this.loader.set("loading",t&&!i),this.conversationsView.toggle(!i&&!e&&!t),this.emptyView.toggle(e&&!i&&!t&&!this.isNewEmptyInboxEnabled),this.inboxRecipientsView&&this.inboxRecipientsView.toggle(e&&!i&&!t&&this.isNewEmptyInboxEnabled),this.composeView.$el.toggle(i),i&&this.composeView.focus()},_onChangeCollection:function(){this.set("isEmpty",0===this.collection.length)},_onSyncCollection:function(){this.set({isLoading:!1,isEmpty:0===this.collection.length}),this.getCurrentChannel().set("isInboxFetched",!0)},_onRequestCollection:function(e,t,i){this.set({isEmpty:0===this.collection.length,isLoading:!this.getCurrentChannel().get("isInboxFetched")})},_fetchEmptyInboxFavorites:function(){var e=this;this.set("isLoadingEmptyInboxFavorites",!0),this.emptyInboxCollection.fetchFavorites(null,null,null,this.isNewEmptyInboxEnabled,"empty").then(function(){e.rendered&&(e.isNewEmptyInboxEnabled||e.favoritesCollection.reset(n.take(e.emptyInboxCollection.toJSON(),e.get("numFavorites"))))}).always(function(){e.rendered&&e.set("isLoadingEmptyInboxFavorites",!1)})},_fetchFavorites:function(){var e=this.get("numFavorites"),t=this.currentBlogModel.getId();this.favoritesCollection.fetchFavorites(e,t,null,!0)}});e.exports=g},60186(e,t,i){"use strict";var n=i(80160),s=i(55679),o=i(81515),r=n.extend({urlRoot:"/svc/post/ask",validate:function(e){return s.trim(e.question)?this.isUrl(e.question)?{error:o("Sorry, but please don't include links in questions.")}:void 0:{error:o("You need to enter a question!")}},isUrl:function(e){return!!(e.match(/(http|https):\/\//i)||e.match(/www\./i)||e.match(/[a-zA-Z0-9]+(\.arpa|\.root|\.aero|\.biz|\.cat|\.com|\.coop|\.edu|\.gov|\.info|\.int|\.jobs|\.mil|\.mobi|\.museum|\.name|\.net|\.org|\.pro|\.travel|TLD|\.ac|\.ad|\.ae|\.af|\.ag|\.ai|\.al|\.am|\.an|\.ao|\.aq|\.ar|\.as|\.at|\.au|\.aw|\.ax|\.az|\.ba|\.bb|\.bd|\.be|\.bf|\.bg|\.bh|\.bi|\.bj|\.bm|\.bn|\.bo|\.br|\.bs|\.bt|\.bv|\.bw|\.by|\.bz|\.ca|\.cc|\.cd|\.cf|\.cg|\.ch|\.ci|\.ck|\.cl|\.cm|\.cn|\.co|\.cr|\.cu|\.cv|\.cx|\.cy|\.cz|\.de|\.dj|\.dk|\.dm|\.do|\.dz|\.ec|\.ee|\.eg|\.er|\.es|\.et|\.eu|\.fi|\.fj|\.fk|\.fm|\.fo|\.fr|\.ga|\.gb|\.gd|\.ge|\.gf|\.gg|\.gh|\.gi|\.gl|\.gm|\.gn|\.gp|\.gq|\.gr|\.gs|\.gt|\.gu|\.gw|\.gy|\.hk|\.hm|\.hn|\.hr|\.ht|\.hu|\.id|\.ie|\.il|\.im|\.in|\.io|\.iq|\.ir|\.is|\.it|\.je|\.jm|\.jo|\.jp|\.ke|\.kg|\.kh|\.ki|\.km|\.kn|\.kr|\.kw|\.ky|\.kz|\.la|\.lb|\.lc|\.li|\.lk|\.lr|\.ls|\.lt|\.lu|\.lv|\.ly|\.ma|\.mc|\.md|\.mg|\.mh|\.mk|\.ml|\.mm|\.mn|\.mo|\.mp|\.mq|\.mr|\.ms|\.mt|\.mu|\.mv|\.mw|\.mx|\.my|\.mz|\.na|\.nc|\.ne|\.nf|\.ng|\.ni|\.nl|\.no|\.np|\.nr|\.nu|\.nz|\.om|\.pa|\.pe|\.pf|\.pg|\.ph|\.pk|\.pl|\.pm|\.pn|\.pr|\.ps|\.pt|\.pw|\.py|\.qa|\.re|\.ro|\.ru|\.rw|\.sa|\.sb|\.sc|\.sd|\.se|\.sg|\.sh|\.si|\.sj|\.sk|\.sl|\.sm|\.sn|\.so|\.sr|\.st|\.su|\.sv|\.sy|\.sz|\.tc|\.td|\.tf|\.tg|\.th|\.tj|\.tk|\.tl|\.tm|\.tn|\.to|\.tp|\.tr|\.tt|\.tv|\.tw|\.tz|\.ua|\.ug|\.uk|\.um|\.us|\.uy|\.uz|\.va|\.vc|\.ve|\.vg|\.vi|\.vn|\.vu|\.wf|\.ws|\.ye|\.yt|\.yu|\.za|\.zm|\.zw)/i))},save:function(e,t){var i=(t=t||{}).success,o=t.error;t.success=s.bind(function(e,t){if(s.isEmpty(s.result(t.response,"errors")))this.trigger("save:success"),i&&i.call(null,e,t);else{var n=t.response.errors[0];this.trigger("save:error",n),o&&o.call(null,e,n)}this.set("isSaving",!1)},this),t.error=s.bind(function(e,t){this.trigger("save:error",t),o&&o.call(null,e,t)},this),this.set("isSaving",!0),!n.prototype.save.call(this,e,t)&&this.validationError&&(this.trigger("save:error",this.validationError.error),this.set("isSaving",!1))}});e.exports=r},60360(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, \'\') }\nwith (obj) {\n\n if (!isSendAPost) { ;\n__p += \' <div class="text-input-container"><textarea class="text-input" placeholder="\' +\n__e( placeholder ) +\n\'" rows="1" maxlength="4096" data-js-text-input></textarea></div><div class="compose-text-input-container"><div data-subview="composePluginsView" class="compose-plugins-container"></div><div class="submit-button"><button type="submit" data-js-submit-button data-js-theme-accent-color-on-white class="submit">\' +\n__e( __(\'Send\') ) +\n\'</button></div></div> \';\n } else { ;\n__p += \' <div data-subview="composePluginsView" class="compose-plugins-container"></div><div class="compose-text-input-container"><div class="text-input-container"><textarea class="text-input" placeholder="\' +\n__e( placeholder ) +\n\'" rows="1" maxlength="4096" data-js-text-input></textarea></div><div class="submit-button"><button type="submit" data-js-submit-button data-js-theme-accent-color-on-white class="submit">\' +\n__e( __(\'Send\') ) +\n\'</button></div></div> \';\n } ;\n\n\n}\nreturn __p\n}').apply(void 0,r(s))},60475(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n\n if (hasMessaging) { ;\n__p += ' <li data-js-message><a href=\"#\">' +\n__e( _('Send a message') ) +\n'</a></li> ';\n } ;\n__p += ' ';\n if (hasAsks) { ;\n__p += ' <li data-js-ask><a class=\"ask\" href=\"' +\n__e( url ) +\n'/ask\">' +\n__e( _('Ask a question') ) +\n'</a></li> ';\n } ;\n__p += ' ';\n if (hasSubmissions) { ;\n__p += ' <li data-js-submit><a class=\"submit\" target=\"_blank\" href=\"' +\n__e( url ) +\n'/submit\">
1' +\n__e( _('Submit') ) +\n'</a></li> ';\n } ;\n\n\n}\nreturn __p\n}").apply(void 0,r(s))},60480(e,t,i){"use strict";var n=i(3226);e.exports=function(e){i.e(464).then(function(t){try{e(i(45034))}catch(e){n(e,"post-form")}}.bind(null,i)).catch(i.oe)}},60500(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(25256),r=i(50283),a=i(77594),l=i(98237),c=i(38044),u=r.extend({className:"ask-form",template:c,mixins:[a,l],keycommands:{"keydown:enter":"preventNewlines","keydown:escape":"dismiss"},events:{"click button.close":"dismiss","change .ask-anonymously-switch":"toggleAnonymous","submit form":"submit","input .ask-question":"onTextAreaUpdate"},initialize:function(e){this.characterLimit=e.characterLimit,this.sender=e.sender,this.recipient=e.recipient,this.onTextAreaUpdate=s.throttle(s.bind(this.onTextAreaUpdate,this),100),this.listenTo(this.model,"change:isSaving",this.toggleSubmit),this.listenTo(this.model,"save:success",this.render),this.listenTo(this.model,"save:error",this.displayErrors)},getTemplateData:function(){var e={};return e.recipient=s.clone(this.recipient)||{},e.recipient.allow_anonymous=e.recipient.allowAnonymous,e.sender=this.sender.toJSON(),e.sender.avatar_url=o(this.sender.get("avatar_url"))(128),e.character_limit=this.characterLimit,e},dismiss:function(){this.trigger("close")},toggleSubmit:function(e,t){t?this.disableSubmit():this.enableSubmit()},toggleAnonymous:function(e){var t=this.$(e.target);this.isAnonymous=t.prop("checked");var i=this.$$(".post_avatar_link"),n=this.$$(".ask-from .tumblelog_name"),s=this.$$(".ask-from .anonymous");this.isAnonymous?(i.removeClass("use_blog_avatar"),n.hide(),s.show()):(i.addClass("use_blog_avatar"),n.show(),s.hide())},submit:function(e){e.preventDefault(),this.trigger("submit",{question:this.$$(".ask-question").val(),anonymous:this.isAnonymous})},preventNewlines:function(e){e.preventDefault()},onTextAreaUpdate:function(){var e=this.$$(".ask-question").val(),t=e;e.match(/\n/g)&&(e=e.replace(/\n/g,""));var i=s.trim(e).length;0<i&&i<=this.characterLimit?this.enableSubmit():this.disableSubmit(),e!==t&&this.$$(".ask-question").val(e);var n=this.characterLimit-e.length,o=this.$$(".ask-character-count");o.text(n),n<=100?(o.addClass("active"),o.removeClass("count-ok count-warning count-danger"),n>40?o.addClass("count-ok"):n>20?o.addClass("count-warning"):o.addClass("count-danger")):o.removeClass("active")},enableSubmit:function(){this.model.get("isSaving")||this.$$(".ask-button").prop("disabled",!1)},disableSubmit:function(){this.$$(".ask-button").prop("disabled",!0)},showMessages:function(e,t){var i=this.$$("."+e);i.get(0)&&(i.removeClass("active").hide().empty(),"string"==typeof t&&(t=[t]),s.each(t,s.bind(function(e){var t=n("<li/>",{text:e});i.append(t)},this)),i.show(),s.defer(function(){i.addClass("active")}))},displayErrors:function(e){this.showMessages("errors-ask",e)}});e.exports=u},60525(e,t,i){"use strict";var n=i(27513),s=i(50681),o=n.extend({model:s});e.exports=o},60538(e,t,i){"use strict";var n=i(44384).extend({});e.exports=n},60697(e,t,i){"use strict";var n=i(71742),s=i(44890),o=i(76252),r=n.extend({name:"elevator",selector:"body",autoAppend:!0,view:function(e){return!s.bool("is_mobile")&&new o(e)}});e.exports=r},60786(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div data-js-label class=\"inline-activity timestamp\">' +\n__e( label ) +\n'</div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},60874(e,t,i){"use strict";var n=i(55679),s=new(i(28724))({defaults:{removeCollectionSubviews:function(e){var t=this[e];this.subviews[e]&&!n.isEmpty(t)&&(t=this[e],this._subviews=n.difference(this._subviews,t),n.invoke(t,"remove"),this[e].length=0)},removeCollectionSubview:function(e,t){var i,s=this[e];this.subviews[e]&&!n.isEmpty(s)&&(i=n.findWhere(s,{model:t}))&&(this._subviews=n.without(this._subviews,i),i.remove(),this[e]=n.without(this[e],i))},addNewCollectionSubview:function(e,t,i){var s=this.subviews[e];if(i||(i=this._getSubviewCollection(e)),s&&i){var o=s.container||this._createDefaultContainerFunction(e),r=s.prepareViewForAdd||this._createDefaultPrepareViewForAddFunction(e),a=s.options||{},l={insertionIndex:i.indexOf(t)},c=n.has(this,e),u=this.createCollectionSubviewRenderer([t],o,r,a,e,c,l);this._isBatchRenderingInProgress(e)?this.once("rendered:"+e,u,this):this.rendered?u():this.once("rendered",u,this)}},sortCollectionSubviews:function(e,t){var i,s=this.subviews[e];t||(t=this._getSubviewCollection(e)),s&&t&&this[e]&&(i=n.pluck(t.models,"cid"),i=n.zipObject(i,n.range(0,i.length)),this[e]=n.sortBy(this[e],function(e){return n.get(i,e.model.cid,0)}))},batchRenderCollectionSubviews:function(e){var t=this.subviews[e];if(t){var i=t.container||this._createDefaultContainerFunction(e),s=t.prepareView||this._createDefaultPrepareViewFunction(e),o=t.options||{},r=n.result(t,"batchSize")||5,a=n.result(t,"batchDelay")||100,l=this._getSubviewCollection(e),c=n.chunk(l.models,r),u=n.map(c,function(t,r){return n.bind(function(){return this.createCollectionSubviewRenderer(t,i,s,o,e,r>0).call(this)},this)},this),h=n.bind(function(){this._scheduleBatchRenders(e,u,a)},this);this.rendered?h():this.once("rendered",h,this)}},_isBatchRenderingInProgress:function(e){return n.get(this._deferredRenders,e,[]).length>0},_scheduleBatchRenders:function(e,t,i){var s=t.length,o=function(){this._afterBatchRenderCollectionSubviews(e)},r=function(t){t.call(this,e),this._afterEachBatchRenderCollectionSubviews(e),0===--s&&o.call(this)};this._deferredRenders||(this._deferredRenders={}),n.has(this._deferredRenders,e)||(this._deferredRenders[e]=[]),this._cancelBatchRenders(e),0!==s?n.each(t,function(t,s){var o;0!==s?(o=setTimeout(n.bind(function(){r.call(this,t),this._deferredRenders[e]=n.without(this._deferredRenders[e],o)},this),i*(s+1)),this._deferredRenders[e].push(o)):r.call(this,t)},this):o.call(this)},_cancelBatchRenders:function(e){n.isEmpty(this._deferredRenders)||(n.isEmpty(e)||n.has(this._deferredRenders,e))&&(n.isEmpty(e)?(n.each(this._deferredRenders,function(e,t){n.each(e,function(e){clearTimeout(e)},this)},this),this._deferredRenders={}):(n.each(this._deferredRenders[e],function(e){clearTimeout(e)},this),this._deferredRenders[e].length=0))},_afterEachBatchRenderCollectionSubviews:function(e){this.trigger("batch:rendered:"+e)},_afterBatchRenderCollectionSubviews:function(e){this.trigger("rendered:"+e)},_attachCollectionListeners:function(e){var t=this._getSubviewCollection(e);t&&(this.listenTo(t,"add",n.partial(this.addNewCollectionSubview,e)),this.listenTo(t,"remove",n.partial(this.removeCollectionSubview,e)),this.listenTo(t,"reset",n.partial(this.renderCollectionSubviews,e)),this.listenTo(t,"update",n.partial(this.sortCollectionSubviews,e)))},_getSubviewCollection:function(e){var t=n.get(this.subviews[e],"collection");return!0===t?this.collection:n.isFunction(t)?t(this):t||null},_createDefaultPrepareViewForAddFunction:function(e){var t=this.subviews[e];return n.bind(function(i,s){var o=i.children(),r=new t.constructor(s),a=s.insertionIndex;return r.$el.attr("data-subview",e),n.isNumber(a)&&a<o.length?r.$el.insertBefore(o.get(a)):i.append(r.$el),r},this)}}
1,before:{renderSubviews:function(){n.each(this.subviews,function(e,t){e.collection&&this._attachCollectionListeners(t)},this)},beforeRemove:function(){this._cancelBatchRenders()}},around:{renderCollectionSubviews:function(e,t){var i=this.subviews[t];if(i)return this.removeCollectionSubviews(t),!0===n.result(i,"enableBatchRendering")?this.batchRenderCollectionSubviews(t):e.apply(this,n.rest(arguments))}}});e.exports=s},61014(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"Knight-Rider-loader ';\n if (loading) { ;\n__p += 'animate';\n} ;\n__p += '\"><div class=\"Knight-Rider-bar\"></div><div class=\"Knight-Rider-bar\"></div><div class=\"Knight-Rider-bar\"></div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},61371(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(50283),r=i(98237),a=i(15437),l=o.extend({className:"conversation-pill hide-pill",template:a,mixins:[r],events:{"click [data-js-unread-button]":"_onClick"},defaults:{count:0,maxCount:99},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus"))},afterRender:function(){this.listenTo(this,"change:count",this._onChangeCount),this._onChangeCount(this,this.get("count"))},setCount:function(e){this.set("count",n.isFinite(e)?e:0)},getCount:function(){return this.get("count")},getTitle:function(e){var t;return n.isFinite(e)?(t=this.get("maxCount"),s(e>1?"%1$s unread messages":"%1$s unread message",e>t?t+"+":e)):null},getTemplateData:function(){return{title:this.getTitle(this.get("count"))}},_onChangeCount:function(e,t){var i=this.getTitle(t);this.$el.toggleClass("hide-pill",0===t||n.isEmpty(i)),t>0&&this.js$("unread-button").text(i)},_onClick:function(e){e.preventDefault(),this.trigger("click")}});e.exports=l},61442(e,t,i){"use strict";var n=i(9428),s=i(1860),o=i(47483),r=i(4734),a=i(187),l=i(85346),c=i(33905),u=i(73001);e.exports={Reddit:n,Pinterest:s,Permalink:o,Embed:a,Flag:r,Email:l,Twitter:c,CopyPermalink:u}},61551(e,t,i){function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function s(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,o(n.key),n)}}function o(e){var t=function(e,t){if("object"!=n(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var s=i.call(e,t||"default");if("object"!=n(s))return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==n(t)?t:t+""}var r=i(55679),a=i(98544),l=i(34783),c=i(96991),u={VIDEO_30_SEC:{d:30}},h={VIDEO_START:0,VIDEO_QUARTILE_25:25,VIDEO_QUARTILE_50:50,VIDEO_QUARTILE_75:75,VIDEO_QUARTILE_100:98},d={viewabilityDefStatic:"STATIC_VIEW",viewabilityDefStatic3P:"STATIC_VIEW_3P",viewabilityDefVideo:"VIDEO_VIEW",viewabilityDefVideo3P:"VIDEO_VIEW_3P"},p=function(){return e=function e(t,i,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.beacons=i,this.beaconHandler=new c,this.rules=[],this.context=n,this.processRules(t,this.beacons),this.processTimedBeacons(this.beacons,n.maxDuration())},(t=[{key:"processTimedBeacons",value:function(e,t){var i=this;t<=0||r.forEach(e,function(n,s){u[s]&&i.processRule(s,e,u[s]),void 0!==h[s]&&i.processRule(s,e,{d:h[s]/100*t})})}},{key:"processRules",value:function(e,t){var i=this;r.forEach(e,function(e,n){r.isArray(e)?r.forEach(e,function(e){return i.processRule(n,t,e)}):i.processRule(n,t,e)})}},{key:"processRule",value:function(e,t,i){var n=new a(e,i);d[e]&&t[d[e]]?n.setBeacons(t[d[e]]):(void 0!==h[e]&&t[e]||void 0!==u[e]&&t[e])&&n.setBeacons(t[e]),this.rules.push(n)}},{key:"checkRules",value:function(e){var t=this;r.forEach(this.rules,function(i){i.checkRule(e)&&(i.firedBeacons||(t.fireBeacons(i),i.firedBeacons=!0))})}},{key:"resetContinuousRules",value:function(){this.resetRules(function(e){return e.reqContinuous})}},{key:"resetAudioOnContinuousRules",value:function(){this.resetRules(function(e){return e.reqContinuous&&e.reqAudioOn})}},{key:"resetRules",value:function(e){var t=r.filter(this.rules,e);r.forEach(t,function(e){return e.reset()})}},{key:"replaceMacros",value:function(e,t,i){return r.forEach(l.CONTEXT,function(t){if(e.indexOf(t)){var n=i.getMacroValue(t);void 0!==n&&(e=e.replace(t,n))}}),r.forEach(l.RULE,function(i){if(e.indexOf(i)){var n=t.getMacroValue(i);void 0!==n&&(e=e.replace(i,n))}}),e}},{key:"fireBeacons",value:function(e){var t=this;r.forEach(e.getBeacons(),function(i){i=t.replaceMacros(i,e,t.context),t.beaconHandler.fireBeacon(i)})}}])&&s(e.prototype,t),i&&s(e,i),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,i}();e.exports=p},61985(e,t,i){"use strict";var n=i(55679),s=i(30291),o=i(80160),r=i(56315),a=s.extend({idAttribute:"name",initialize:function(e){this.channels=new r(e.channels)},incrementLikeCount:function(){var e=this.get("liked_post_count");this.set("liked_post_count",e+1)},decrementLikeCount:function(){var e=this.get("liked_post_count");e>0&&this.set("liked_post_count",e-1)},incrementFollowingCount:function(){var e=this.get("friend_count");this.set("friend_count",e+1)},decrementFollowingCount:function(){var e=this.get("friend_count");e>0&&this.set("friend_count",e-1)},getUnreadCount:function(){return this.channels.reduce(function(e,t){return parseInt(e,10)+parseInt(t.get("unread_count"),10)},0)},getChannel:function(e){return null==e&&(e=this.get("primary")),this.channels.findWhere({name:e})},canMessage:function(){return this.get("can_message")},isSoundsEnabled:function(){return this.get("is_sounds_enabled")},isVerifiedEmail:function(){return this.get("is_verified_email")},getChannelsEnabledForMessaging:function(){return this.channels.where({can_send_messages:!0})},getCurrentMessagingChannelUuid:function(){var e;return n.isEmpty(this._currentMessagingChannelUuid)&&(e=this.channels.findWhere({is_current:!0,
1can_send_messages:!0})||n.first(this.getChannelsEnabledForMessaging()))&&(this._currentMessagingChannelUuid=e.get("uuid")),this._currentMessagingChannelUuid},setCurrentMessagingChannelUuid:function(e){this._currentMessagingChannelUuid=e},toJSON:function(){var e=o.prototype.toJSON.apply(this,arguments);return e.channels=this.channels.toJSON(),e},getChannelProperty:function(e,t){var i=this.getChannel(e);if(!i||!("get"in i))return null;var n=i.get(t);return void 0===n?null:n}});e.exports=a},62490(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(35543),r=i(68100),a=s.extend({className:"search-filters",template:o,events:{"click .show-filter-popover":"showPopover"},initialize:function(){this.listenTo(this.model,"search:reset",this.hidePopover)},showPopover:function(){this.popover||(this.popover=new r({pinnedTarget:this.$el,model:this.model,preventInteraction:!0}),this.popover.render(),this.listenTo(this.popover,"close",this.onPopoverClose))},hidePopover:function(){this.popover&&this.popover.hide()},onPopoverClose:function(){n.defer(n.bind(function(){this.popover=null},this))}});e.exports=a},62535(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(71742).extend({name:"BasePoller",defaults:{url:null,requestType:"GET",dataType:"JSON",cache:!1,frequency:6e4,backoffRates:[],stopAfterNumErrors:3,isPolling:!1,hasPolled:!1,isDebugEnabled:!1},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"callback")),this.currentErrorCount=0,this.currentUnchangedCount=0},start:function(e){this.set("isPolling",!0),e?this.scheduleNextPoll():this.poll()},stop:function(){this.set("isPolling",!1),this.cancel()},cancel:function(){this.cancelCurrent(),this.cancelNext()},cancelCurrent:function(){this._currentRequest&&(n.result(this._currentRequest,"abort"),this._currentRequest=null)},cancelNext:function(){this._nextPollToken&&(clearTimeout(this._nextPollToken),this._nextPollToken=null)},beforeRemove:function(){this.stop()},setFrequency:function(e){this.set("frequency",e),this.resetPollingFrequency()},setBackoffRates:function(e){this.set("backoffRates",e),this.resetPollingFrequency()},resetPollingFrequency:function(){this.currentUnchangedCount=0,this.set("hasPolled",!1)},poll:function(){this.cancel(),this._lastPollTime=(new Date).getTime();var e=this.makeRequest.call(this);return e.done(n.bind(this._onRequestSuccess,this)).fail(n.bind(this._onRequestFail,this)).always(n.bind(this._onRequestAlways,this)),this._currentRequest=e,e},getRequestData:function(){return{}},hasResponseChanged:function(){return!0},resetErrorCount:function(){this.currentErrorCount=0,this.start()},parse:function(e){return e},getBackoffRate:function(){var e,t=this.get("backoffRates");return n.isEmpty(t)||!n.isArray(t)||0===this.currentUnchangedCount?1:(e=Math.min(this.currentUnchangedCount,t.length)-1,Math.max(1,n.get(t,e,1)))},getPollingFrequency:function(){return this.get("frequency")*this.getBackoffRate()},makeRequest:function(){var e=this.getRequestData(),t={url:this.get("url"),type:this.get("requestType"),dataType:this.get("dataType"),cache:this.get("cache"),data:e};return s.ajax(t)},scheduleNextPoll:function(){var e=this.getPollingFrequency();if(this.set("hasPolled",!0),!this.get("isPolling"))return!1;!n.isFinite(e)||e<=0||(this.currentErrorCount<=this.get("stopAfterNumErrors")?(this.cancelNext(),this._nextPollToken=setTimeout(n.bind(this.poll,this),e)):this.stop())},_onRequestSuccess:function(e){this.currentErrorCount=0,e=this.parse(e),this.callback&&this.callback(e,this._lastPollTime),this.hasResponseChanged(e)||!this.get("hasPolled")?this.currentUnchangedCount=0:this.currentUnchangedCount++},_onRequestFail:function(){this.currentErrorCount++},_onRequestAlways:function(){this.scheduleNextPoll()}});e.exports=o},62633(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div class=\"mobile-banner-body\"><span class=\"mobile-banner-heading\">' +\n__e( __('Want to see more stuff?') ) +\n'</span><span class=\"mobile-banner-subheading\">' +\n__e( __('Use the Tumblr app!') ) +\n'</span></div>
1<div class=\"mobile-banner-controls\"><a href=\"' +\n__e( open_url ) +\n'\" class=\"open mobile-banner-button mobile-banner-open secondary-cta tx-button\" role=\"button\">' +\n__e( __('Open') ) +\n'</a><a href=\"' +\n__e( install_url ) +\n'\" class=\"install mobile-banner-button mobile-banner-install primary-cta tx-button blue\" role=\"button\">' +\n__e( __('Install the app') ) +\n'</a></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},62822(e,t,i){var n=i(74692),s={tumblrUrlBasePattern:"^\\s*((https?:)?[/\\\\]+)?([a-z0-9\\.-])*(.com|.net)",tumblrUrlEolPattern:"\\/?\\s*\\/*[a-zA-Z0-9_]*?",isBlank:function(e){return""===n.trim(e)},minLength:function(e,t){return e.length>=t},maxLength:function(e,t){return e.length<=t},range:function(e,t,i){return e.length>=t&&e.length<=i},pattern:function(e,t){return new RegExp(t,"gi").test(e)},isEmail:function(e){return this.pattern(e,"^[a-zA-Z0-9._+-]+@[a-zA-Z0-9][a-zA-Z0-9.-]*[.]{1}[a-zA-Z]{2,20}$")},isUrl:function(e){return this.pattern(e,"^\\s*((https?:)?[/\\\\]+)?([a-z0-9_-]+\\.){1,}([a-z\\.]{2,6})(/[^\\s]*)?\\s*$")},isReportableTumblrUrl:function(e){return this.isTumblrPostUrl(e)||this.isTumblrImageUrl(e)||this.isTumblrSubmissionsUrl(e)||this.isTumblrChatUrl(e)||this.isTumblrChatMessageUrl(e)||this.isTumblrBlogUrl(e)||this.isTumblrBlogViewUrl(e)},isTumblrBlogUrl:function(e){return this.pattern(e,this.tumblrUrlBasePattern+this.tumblrUrlEolPattern)},isTumblrSubmissionsUrl:function(e){return this.pattern(e,this.tumblrUrlBasePattern+"\\/submissions\\/[a-z0-9-_\\/\\.]{1,}"+this.tumblrUrlEolPattern)},isTumblrChatUrl:function(e){return this.pattern(e,this.tumblrUrlBasePattern+"\\/chats?\\/[0-9]{1,}"+this.tumblrUrlEolPattern)},isTumblrChatMessageUrl:function(e){return this.pattern(e,this.tumblrUrlBasePattern+"\\/chat_message\\/[a-z0-9-_\\/\\.]{1,}"+this.tumblrUrlEolPattern)},isTumblrPostUrl:function(e){return this.pattern(e,this.tumblrUrlBasePattern+"\\/(?:post|blog|private)\\/[a-z0-9-_\\/\\.]{1,}"+this.tumblrUrlEolPattern)},isTumblrBlogViewUrl:function(e){return this.pattern(e,this.tumblrUrlBasePattern+"\\/blog\\/view\\/[a-z0-9-_\\/\\.]{1,}"+this.tumblrUrlEolPattern)},isTumblrImageUrl:function(e){return this.pattern(e,this.tumblrUrlBasePattern+"\\/image\\/[a-z0-9-_\\/\\.]{1,}"+this.tumblrUrlEolPattern)},equals:function(e,t){return e===t},isPhoneNumber:function(e){return e&&/^\d+$/.test(e)&&(10===e.length||11===e.length)},isPostalCode:function(e){return e&&/^\d+$/.test(e)&&(5===e.length||9===e.length)}};e.exports=s},63224(e,t,i){"use strict";var n=i(50283),s=i(28017),o=i(55679),r=i(74692),a=n.extend({events:{mouseleave:"onMouseLeave",mouseenter:"onMouseEnter"},defaults:{totalImages:1,changeOnHover:!0,image:!1,shouldAnimate:!1},initialize:function(e){this.assetsHost=s.get("Context/hosts/assets_host"),this.isRetina=window.devicePixelRatio&&window.devicePixelRatio>1,this.$imageContainer=this.$(".preload-container"),this.animations=o.get(e,"data.animations",[]);var t=Array.isArray(this.animations)&&this.animations.length>0;this.set("shouldAnimate",t),t&&(this.set("totalImages",this.animations.length),this.generateImageIds(),this.get("image")||(this.applyRandomImage(),this.addImageToContainer()),this.setBackgroundImage(this.get("image")),this.listenTo(this,"change:image",function(e,t){this.addImageToContainer(),this.setBackgroundImage(t)}))},generateImageIds:function(){this.imageIds=o.shuffle(o.range(1,this.get("totalImages")+1))},onMouseEnter:function(e){var t=this;if(this.get("shouldAnimate")){var i=this.getCurrentImageObject();i.get(0)&&i.get(0).complete?this.$el.addClass("opacity-switch"):i.on("load",function(){t.$el.is(":hover")&&t.get("image")===i.data("imgId")&&t.onMouseEnter()})}},onMouseLeave:function(e){var t=this;this.get("shouldAnimate")&&(this.$el.removeClass("opacity-switch"),this.get("changeOnHover")&&setTimeout(function(){t.applyRandomImage()},200))},addImageToContainer:function(){if(!this.getCurrentImageObject().get(0)){var e=this.get("image");if(e>this.animations.length)return;var t=this.animations[e-1],i=this.isRetina?1:0;if(!Array.isArray(t)||i>t.length)return;var n=t[i];n&&r('<img data-img-id="'+e+'" alt="Tumblr">').attr("src",n).appendTo(this.$imageContainer)}},applyRandomImage:function(){0===this.imageIds.length&&this.generateImageIds(),this.set("image",this.imageIds[0]),this.imageIds.shift()},getCurrentImageObject:function(){return this.$imageContainer.find('[data-img-id="'.concat(this.get("image"),'"]'))}
1,setBackgroundImage:function(e){this.$imageContainer.css("background-image","url(".concat(this.getCurrentImageObject().attr("src"),")"))}});e.exports=a},63349(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<form class=\"form-main\"><textarea data-js-message placeholder=\"' +\n__e( __('Message (Optional)') ) +\n'\" class=\"message textarea\" aria-label=\"' +\n__e( __('Optional Twitter message content') ) +\n'\"> ' +\n__e( urlToken ) +\n'</textarea></form><div class=\"form-result form-result--fail\" data-js-fail-container> ' +\n__e( __('Something went screwy.') ) +\n' </div><footer class=\"footer\"><button type=\"submit\" class=\"button tx-button blue\" data-js-submit-button data-js-text-sending=\"' +\n__e( __('Sending...') ) +\n'\">' +\n__e( __('Send') ) +\n'</button><div data-js-character-count class=\"character-count\"></div></footer><div class=\"form-result form-result--success\" data-js-success-container> ' +\n__e( __('Post shared!') ) +\n' </div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},63522(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(50283),r=i(60874),a=i(98237),l=i(78421),c=i(38039),u=i(44370),h=i(69464),d=i(89760),p=o.extend({className:"inbox-conversations",template:d,mixins:[a,r],defaults:{isPaginating:!1,showFavorites:!1,hasNextPage:!0,showLoadingContainer:!0,appendFavoritesToInboxLimit:3},subviews:{conversations:{constructor:c,enableBatchRendering:!0,options:function(e){return{eventBus:e.eventBus,channels:e.channels,currentBlogModel:e.currentBlogModel}},collection:function(e){return e.collection}},paginationLoaderView:{constructor:l,options:{variation:"small h-centered",loading:!1}},favoritesView:{constructor:h,options:function(e){return{showMessageOnEmpty:!1,eventBus:e.eventBus,collection:e.favoritesCollection,title:e.isNewEmptyInboxEnabled?s("Recently Followed"):s("More Tumblrs to talk to"),context:"inbox:moretumblrs",isNewEmptyInboxEnabled:e.isNewEmptyInboxEnabled}}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","collection","channels","favoritesCollection","currentBlogModel","isNewEmptyInboxEnabled"))},afterRenderSubviews:function(){this.scrollBar=new u({el:this.el}),this.listenTo(this,"change:isPaginating",this._onChangeIsPaginating),this.listenTo(this,"change:showFavorites",this._onChangeShowFavorites),this.listenTo(this,"change:hasNextPage",this._onChangeHasNextPage),this.listenTo(this,"change:showLoadingContainer",this._onChangeShowLoadingContainer),this.listenTo(this.collection,"sort",this._onCollectionSort),this.listenTo(this.collection,"update reset change",this._onCollectionChange),this.listenTo(this.favoritesCollection,"update reset",this._onFavoritesCollectionChange),this.listenTo(this.collection,"reset",this._onCollectionReset),this.listenTo(this,"batch:rendered:conversations",this._onConversationsBatchRendered),this.listenTo(this.collection,"sync",this._onCollectionSync),this.listenTo(this.collection,"change:hasNextPage",this._onChangeCollectionHasNextPage),this.listenTo(this.scrollBar,"scrollbottom",this._onScrollBottom),this._setViewStates(),this._onChangeCollectionHasNextPage(this.collection,this.collection.hasNextPage()),this._onChangeShowFavorites(this,this.get("showFavorites")),this._onChangeHasNextPage(this,this.get("hasNextPage")),this._onChangeShowLoadingContainer(this,this.get("showLoadingContainer")),n.defer(n.bind(this.updateScrollBar,this))},toggle:function(e){this.$el.toggle(e),this.updateScrollBar()},beforeRemove:function(){this.scrollBar&&this.scrollBar.destroy()},getNextPage:function(){this.rendered&&this.collection.hasNextPage()&&(this.set("isPaginating",!0),this.collection.fetchNextPage().always(n.bind(function(){this.rendered&&this.set("isPaginating",!1)},this)))},updateScrollBar:function(){this.scrollBar&&this.scrollBar.update()},_setViewStates:function(){var e=this.get("hasNextPage"),t=this.collection.length>0&&!e&&this.collection.length<=this.get("appendFavoritesToInboxLimit");this.set({showFavorites:t,showLoadingContainer:e}),this.updateScrollBar()},_saveModelOrder:function(){this.lastModelOrder=this._getModelOrderString()},_getModelOrderString:function(){return n.pluck(this.collection.models,"cid").join(" ")},_onCollectionSort:function(e){var t=this._getModelOrderString();this.lastModelOrder&&-1===t.indexOf(this.lastModelOrder)&&this.renderCollectionSubviews("c
1onversations"),this._saveModelOrder()},_onCollectionChange:function(e,t){this._setViewStates(),this._saveModelOrder()},_onCollectionSync:function(){this._onChangeCollectionHasNextPage(this.collection,this.collection.hasNextPage())},_onCollectionReset:function(e){this.$el.scrollTop(0),this._saveModelOrder()},_onConversationsBatchRendered:function(){this.updateScrollBar()},_onChangeCollectionHasNextPage:function(e,t){this.set("hasNextPage",t&&e.length>=10)},_onChangeHasNextPage:function(e,t){this._setViewStates()},_onChangeIsPaginating:function(e,t){this.paginationLoaderView.set("loading",t)},_onScrollBottom:function(e){e&&this.getNextPage()},_onChangeShowFavorites:function(e,t){this.favoritesView.$el.toggle(t)},_onChangeShowLoadingContainer:function(e,t){this.js$("loader-container").toggle(t)},_onFavoritesCollectionChange:function(){this.updateScrollBar()}});e.exports=p},63696(e,t,i){var n=i(55679),s=i(17604).sprintf,o=i(81515),r=i(51007),a=(i(95349),{__:o,sprintf:s,_subview:r});e.exports=function(){return n.extend(n.templateSettings.imports,a),a}},63717(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, \'\') }\nwith (obj) {\n__p += \'<div class="splash-bg" data-img-src="\' +\n__e( splash.image ) +\n\'"></div><div class="splash-sections"><div class="splash-section top"><a href="/login" class="splash-login">\' +\n__e( __(\'Log in\') ) +\n\'</a></div><div class="splash-section middle"><div class="middle-inner"><span class="splash-pitch">\' +\n__e( __(\'Splash headline\') ) +\n\'</span><a href="/register" class="signin tx-button blue" role="button">\' +\n__e( __(\'Get started\') ) +\n\'</a> \';\n if(has_app) { ;\n__p += \'<a href="\' +\n__e( app_url ) +\n\'" class="tx-button get-the-app" role="button">\' +\n__e( __(\'Get the app\') ) +\n\'</a>\';\n } ;\n__p += \' </div></div><div class="splash-section bottom"><a href="\' +\n__e( splash.url ) +\n\'" target="_blank" rel="nofollow" class="splash-avatar" style="background-image:url(\' +\n__e( splash.avatar ) +\n\')"></a> <a href="\' +\n__e( splash.url ) +\n\'" target="_blank" rel="nofollow" class="splash-name">\' +\n__e( __(\'Posted by\') ) +\n\'&nbsp;<strong>\' +\n__e( splash.name ) +\n\'</strong></a></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},63747(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<form class=\"survey-result\" data-abuse-form><input type=\"hidden\" name=\"form_key\" value=\"' +\n__e( formKey ) +\n'\"> <input type=\"hidden\" name=\"abuse_type\" value=\"' +\n__e( formName ) +\n'\"> <input type=\"hidden\" name=\"source\" value=\"' +\n__e( _.get(prefillFields, 'source', '') ) +\n'\"> ';\n if (formToken) { ;\n__p += ' <input type=\"hidden\" name=\"form_token\" value=\"' +\n__e( formToken ) +\n'\"> ';\n } ;\n__p += ' ';\n if (mode === 'chat_message' || mode === 'chat') { ;\n__p += ' <input type=\"hidden\" required name=\"reason\" value=\"' +\n__e( _.get(prefillFields, 'reason', '') ) +\n'\"> ';\n } ;\n__p += ' ';\n if (languageNotice) { ;\n__p += ' <div class=\"form-row\"><span class=\"language-notice\">' +\n__e( __('Just so you know, we\\'re not yet able to address queries that are written in [language]. You can still use this form to contact our Support team, but you\\'ll need to fill it out in English. Sorry about that, and thanks for your patience.') ) +\n'</span></div> ';\n } ;\n__p += ' ';\n _.each(form, function(group) { ;\n__p += ' <div class=\"form-row\" ';\n if (group.dependsOn) { ;\n__p += ' data-depends-on-field=\"' +\n__e( group.dependsOn.field ) +\n'\" data-depends-on-values=\"' +\n__e( JSON.stringify(group.dependsOn.values) ) +\n'\" style=\"display:none\" ';\n } ;\n__p += '> ';\n if (group.groupType === 'vertical-layout') { ;\n__p += ' <div class=\"row-field\"> ';\n } else if (group.groupType === 'permalink-hint') { ;\n__p += ' <p> ' +\n((__t = ( __('Need help finding a permalink? Click %1$shere%2$s.', '<a href=\"https://tumblr.zendesk.com/hc/en-us/articles/223857008#permalink\" target=\"_blank\" rel=\"noopener noreferrer\">','</a>') )) == null ? '' : __t) +\n' ';\n } else { ;\n__p += ' </p><div class=\"row-label\"> ';\n } ;\n__p += ' ';\n if (group.groupLabelBold) { ;\n__p += ' <p class=\"form-subheading-tagline bold\">' +\n__e( __(group.groupLabelBold) ) +\n'</p> ';\n } else { ;\n__p += ' ' +\n__e(__(group.groupLabel) );\n if (group.required) { ;\n__p += ' *';\n } ;\n__p += ' ';\n } ;\n__p += ' ';\n if (group.groupDescription) { ;\n__p += ' <p class=\"form-group-description\">' +\n__e( __(group.groupDescription) ) +\n'</p> ';\n } ;\n__p += ' ';\n if (group.groupType === 'permalink-hint') { ;\n__p += ' <p></p> ';\n } else { ;\n__p += ' </div> ';\n } ;\n__p += ' ';\n if (group.groupType === 'vertical-layout') { ;\n__p += ' <div class=\"row-field\"> ';\n } else { ;\n__p += ' <div class=\"row-content\"> ';\n } ;\n__p += ' ';\n _.each(group.fields, function(field) { ;\n__p += ' <div class=\"row-field\"> ';\n if (field.type === 'text') { ;\n__p += ' ';\n if (typeof field.link !== 'undefined') { ;\n__p += ' <p>' +\n((__t = ( __(field.text, '<a target=\"_blank\" href=\"/abuse/'+ _t.sanitize(field.link, true) +'\">', '</a>') )) == null ? '' : __t) +\n'</p> ';\n } else { ;\n__p += ' <p>' +\n__e( __(field.text) ) +\n'</p> ';\n } ;\n__p += ' ';\n } else if (field.type === 'input') { ;\n__p += ' ';\n if (field.optional === true) { ;\n__p += ' <input class=\"text_field\" name=\"' +\n__e( field.name ) +\n'\" data-validate-input=\"text-abuse-form\" placeholder=\"' +\n__e( __(field.placeholder) ) +\n'\"><div class=\"optional-tag\">' +\n__e( __('Optional') ) +\n'</div> ';\n } else { ;\n__p += ' <input class=\"text_field\" data-validate-input=\"text-abuse-form\" required name=\"' +\n__e( field.name ) +\n'\" placeholder=\"' +\n__e( __(field.placeholder) ) +\n'\"> ';\n } ;\n__p += ' ';\n } else if (field.type === 'post-id') { ;\n__p += ' <input type=\"hidden\" name=\"' +\n__e( field.name ) +\n'\" value=\"' +\n__e( posts[0].id ) +\n'\"> ';\n if (sender) { ;\n__p += ' <span class=\"text_field input-link\">' +\n__e( __('Message from %1$s', sender) ) +\n'</span> ';\n } else { ;\n__p += ' <span class=\"text_field input-link\">' +\n__e( __('Anonymous message') ) +\n'</span> ';\n } ;\n__p += ' ';\n } else if (field.type === 'input-link') { ;\n__p += ' ';\n hasPostsOrBlog = (posts && posts.length > 0) || (typeof tumblelogUrl !== 'undefined') ;\n__p += ' ';\n if (field.name === 'urlreporting' && mode !== 'standalone' && hasPostsOrBlog) { ;\n__p += ' ';\n if (posts && posts.length > 0) { ;\n__p += ' ';\n _.each(posts, function (post) { ;\n__p += ' ';\n if (field.is_tumblr_url === true) { ;\n__p += ' <input class=\"text_field input-link\" data-validate-input=\"tumblr_url\" required name=\"' +\n__e( field.name ) +\n'[]\" value=\"' +\n__e( post.postUrl ) +\n'\"> ';\n } else { ;\n__p += ' <input class=\"text_field input-link\" data-validate-input=\"url\" required name=\"' +\n__e( field.name ) +\n'[]\" value=\"' +\n__e( post.postUrl ) +\n'\"> ';\n } ;\n__p += ' ';\n }) ;\n__p += ' ';\n } else if (typeof tumblelogUrl !== 'undefined') { ;\n__p += ' ';\n if (field.is_tumblr_url === true) { ;\n__p += ' <input class=\"text_field input-link\" data-validate-input=\"tumblr_url\" required name=\"' +\n__e( field.name ) +\n'[]\" value=\"\"> ';\n } else { ;\n__p += ' <input class=\"text_field input-link\" data-validate-input=\"url\" required name=\"' +\n__e( field.name ) +\n'[]\" value=\"' +\n__e( tumblelogUrl ) +\n'\"> ';\n } ;\n__p += ' ';\n } ;\n__p += ' ';\n } else { ;\n__p += ' <div class=\"dynamic-fields no-edit-button\" data-field-group-name=\"' +\n__e( field.name ) +\n'[]\"> ';\n if (field.optional === true) { ;\n__p += ' <div class=\"input-row no-remove-button\"><div class=\"remove-url-button\" data-field-group-name=\"' +\n__e( field.name ) +\n'[]\" data-remove-url-field></div> ';\n if (field.is_tumblr_url === true) { ;\n__p += ' <input class=\"text_field input-link\" name=\"' +\n__e( field.name ) +\n'[]\" data-field-group-name=\"' +\n__e( field.name ) +\n'[]\" data-validate-input=\"tumblr_url\" placeholder=\"' +\n__e( field.placeholder ? __(field.placeholder) : __('URL') ) +\n'\" data-original-placeholder=\"' +\n__e( field.placeholder ? __(field.placeholder) : __('URL') ) +\n'\" data-add-url-field> ';\n } else { ;\n__p += ' <input class=\"text_field input-link\" name=\"' +\n__e( field.name ) +\n'[]\" data-field-group-name=\"' +\n__e( field.name ) +\n'[]\" data-validate-input=\"url\" placeholder=\"' +\n__e( field.placeholder ? __(field.placeholder) : __('URL') ) +\n'\" data-original-placeholder=\"' +\n__e( field.placeholder ? __(field.placeholder) : __('URL') ) +\n'\" data-add-url-field> ';\n } ;\n__p += ' <div class=\"optional-tag\">' +\n__e( __('Optional') ) +\n'</div></div> ';\n } else { ;\n__p += ' <div class=\"input-row no-remove-button\"><div class=\"remove-url-button\" data-field-group-name=\"' +\n__e( field.name ) +\n'[]\" data-remove-url-field></div> ';\n if (field.is_tumblr_url === true) { ;\n__p += ' <input class=\"text_field input-link\" data-validate-input=\"tumblr_url\" required name=\"' +\n__e( field.name ) +\n'[]\" data-field-group-name=\"' +\n__e( field.name ) +\n'[]\" placeholder=\"' +\n__e( field.placeholder ? __(field.placeholder) : __('URL') ) +\n'\" data-original-placeholder=\"' +\n__e( field.placeholder ? __(field.placeholder) : __('URL') ) +\n'\" data-add-url-field value=\"' +\n__e( _.get(prefillFields, field.name, '') ) +\n'\"> ';\n } else { ;\n__p += ' <input class=\"text_field input-link\" data-validate-input=\"url\" required name=\"' +\n__e( field.name ) +\n'[]\" data-field-group-name=\"' +\n__e( field.name ) +\n'[]\" placeholder=\"' +\n__e( field.placeholder ? __(field.placeholder) : __('URL') ) +\n'\" data-original-placeholder=\"' +\n__e( field.placeholder ? __(field.placeholder) : __('URL') ) +\n'\" data-add-url-field value=\"' +\n__e( _.get(prefillFields, field.name, '') ) +\n'\"> ';\n } ;\n__p += ' </div> ';\n } ;\n__p += ' </div><div class=\"url-manipulator\"><div class=\"edit-button\" data-field-group-name=\"' +\n__e( field.name ) +\n'[]\" data-edit-button>' +\n__e( __('Edit') ) +\n'</div><div class=\"done-button\" data-field-group-name=\"' +\n__e( field.name ) +\n'[]\" data-done-button>' +\n__e( __('Done') ) +\n'</div></div> ';\n } ;\n__p += ' ';\n } else if (field.type === 'input-name') { ;\n__p += ' ';\n if (field.optional === true) { ;\n__p += ' <input class=\"text_field\" data-validate-input=\"name\" name=\"' +\n__e( field.name ) +\n'\" placeholder=\"' +\n__e( __('Name') ) +\n'\"><div class=\"optional-tag\">' +\n__e( __('Optional') ) +\n'</div> ';\n } else { ;\n__p += ' <input class=\"text_field\" data-validate-input=\"name\" required name=\"' +\n__e( field.name ) +\n'\" placeholder=\"' +\n__e( __('Name') ) +\n'\"> ';\n } ;\n__p += ' ';\n } else if (field.type === 'leinput-name') { ;\n__p += ' ';\n if (field.optional === true) { ;\n__p += ' <input class=\"text_field\" data-validate-input=\"lename\" name=\"' +\n__e( field.name ) +\n'\" placeholder=\"' +\n__e( __('Name') ) +\n'\"><div class=\"optional-tag\">' +\n__e( __('Optional') ) +\n'</div> ';\n } else { ;\n__p += ' <input class=\"text_field\" data-validate-input=\"lename\" required name=\"' +\n__e( field.name ) +\n'\" placeholder=\"' +\n__e( __('Name') ) +\n'\"> ';\n } ;\n__p += ' ';\n } else if (field.type === 'input-email') { ;\n__p += ' ';\n if (field.optional === true) { ;\n__p += ' ';\n if (email || (prefillFields && prefillFields[field.name])) { ;\n__p += ' <input class=\"text_field\" value=\"' +\n__e( _.get(prefillFields, field.name, email) ) +\n'\" data-validate-input=\"email\" name=\"' +\n__e( field.name ) +\n'\" placeholder=\"' +\n__e( __('Email address') ) +\n'\"> ';\n } else { ;\n__p += ' <input class=\"text_field\" data-validate-input=\"email\" name=\"' +\n__e( field.name ) +\n'\" placeholder=\"' +\n__e( __('Email address') ) +\n'\"> ';\n } ;\n__p += ' <div class=\"optional-tag\">' +\n__e( __('Optional') ) +\n'</div> ';\n } else { ;\n__p += ' ';\n if (email || (prefillFields && prefillFields[field.name])) { ;\n__p += ' <input class=\"text_field\" value=\"' +\n__e( _.get(prefillFields, field.name, email) ) +\n'\" data-validate-input=\"email\" required name=\"' +\n__e( field.name ) +\n'\" placeholder=\"' +\n__e( __('Email address') ) +\n'\"> ';\n } else { ;\n__p += ' <input class=\"text_field\" data-validate-input=\"email\" required name=\"' +\n__e( field.name ) +\n'\" placeholder=\"' +\n__e( __('Email address') ) +\n'\"> ';\n } ;\n__p += ' ';\n } ;\n__p += ' ';\n } else if (field.type === 'textarea') { ;\n__p += ' ';\n if (field.optional === true) { ;\n__p += ' <textarea name=\"' +\n__e( field.name ) +\n'\" data-validate-input=\"text-abuse-form\" cols=\"30\" rows=\"5\" placeholder=\"' +\n__e( __(field.placeholder) ) +\n'\"></textarea><div class=\"optional-tag\">' +\n__e( __('Optional') ) +\n'</div> ';\n } else { ;\n__p += ' <textarea name=\"' +\n__e( field.name ) +\n'\" data-validate-input=\"text-abuse-form-with-range-and-education\" required minlength=\"100\" cols=\"30\" rows=\"5\" placeholder=\"' +\n__e( __(field.placeholder) ) +\n'\"></textarea> ';\n } ;\n__p += ' <div class=\"character-counter\" data-field-name=\"' +\n__e( field.name ) +\n'\"><span class=\"current-count\">0</span>
1 / 350 ' +\n__e( __('characters') ) +\n' </div> ';\n } else if (field.type === 'letextarea') { ;\n__p += ' <textarea name=\"' +\n__e( field.name ) +\n'\" data-validate-input=\"letext-abuse-form\" required cols=\"30\" rows=\"5\" placeholder=\"' +\n__e( __(field.placeholder) ) +\n'\"></textarea> ';\n } else if (field.type === 'file' && supportsFileChooser) { ;\n__p += ' ';\n if (field.optional === true) { ;\n__p += ' <div class=\"optional-tag\">' +\n__e( __('Optional') ) +\n'</div><div class=\"image-upload-input\"><label class=\"image-upload\" for=\"image-upload\"></label> <input id=\"image-upload\" class=\"image-upload\" data-validate-input=\"file\" type=\"file\" name=\"attachments[]\" accept=\"' +\n__e( field.accept ? field.accept : 'image/*' ) +\n'\" ' +\n__e( field.multiple_files ? 'multiple' : '' ) +\n'></div> ';\n } else { ;\n__p += ' <div class=\"image-upload-input\"><label class=\"image-upload\" for=\"image-upload\"></label> <input id=\"image-upload\" class=\"image-upload\" data-validate-input=\"file\" required type=\"file\" name=\"attachments[]\" accept=\"' +\n__e( field.accept ? field.accept : 'image/*' ) +\n'\" ' +\n__e( field.multiple_files ? 'multiple' : '' ) +\n'></div> ';\n } ;\n__p += ' <div class=\"image-upload-preview\"><img src=\"\"><div class=\"btn_remove btn-remove-uploaded\" data-tooltip=\"' +\n__e( __('Remove image') ) +\n'\"></div></div><div class=\"document-upload-preview\"><img src=\"/images/check.webp\"> <span class=\"document-upload-name\"></span><div class=\"btn_remove btn-remove-uploaded\" data-tooltip=\"' +\n__e( __('Remove image') ) +\n'\"></div></div> ';\n } else if (field.type === 'input-date') { ;\n__p += ' <input class=\"text_field\" type=\"date\" data-validate-input=\"input-date\" required name=\"' +\n__e( field.name ) +\n'\" placeholder=\"' +\n__e( __(field.placeholder) ) +\n'\"> ';\n } else if (field.type === 'select') { ;\n__p += ' <select required class=\"select_field\" name=\"' +\n__e( field.name ) +\n'\" data-validate-input=\"dropdown\"><option value=\"\" disabled=\"disabled\" selected=\"selected\" hidden>' +\n__e( __(field.placeholder) ) +\n'</option> ';\n for (var i = 0; i < field.options.length; i++) { ;\n__p += ' <option>' +\n__e( __(field.options[i]) ) +\n'</option> ';\n } ;\n__p += ' </select> ';\n } else if (field.type === 'checkbox') { ;\n__p += ' <div class=\"checkbox\"><label class=\"binary_switch\"><input type=\"checkbox\" name=\"' +\n__e( field.name ) +\n'\" data-validate-input=\"checkbox\" id=\"' +\n__e( field.name ) +\n'\" ';\n if (field.optional !== true) { ;\n__p += ' required ';\n } ;\n__p += '> <span class=\"binary_switch_track\"></span> <span class=\"binary_switch_button\"></span></label> ';\n if (typeof field.link !== 'undefined') { ;\n__p += ' <label for=\"' +\n__e( field.name ) +\n'\">' +\n((__t = ( __(field.text, '<a target=\"_blank\" href=\"'+ field.link +'\">', '</a>') )) == null ? '' : __t) +\n'</label> ';\n } else { ;\n__p += ' <label for=\"' +\n__e( field.name ) +\n'\">' +\n__e( __(field.text) ) +\n'</label> ';\n } ;\n__p += ' </div> ';\n } ;\n__p += ' </div> ';\n }); ;\n__p += ' </div></div> ';\n }); ;\n__p += ' ' +\n((__t = ( recaptcha )) == null ? '' : __t) +\n' </div></div></form>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},64119(e,t,i){"use strict";var n=i(74692),s=i(27496),o=i(50283),r=i(88628),a=o.extend({template:r,events:{"click [data-term]":"onTermClick"},initialize:function(){this.bindEvents()},bindEvents:function(){this.listenTo(this.model,"change:typeAheadMatches",this.render)},onTermClick:function(e){this.selectTerm(n(e.currentTarget))},selectTerm:function(e){s.trigger("peeprsearch:change:term",{term:e.attr("data-term")})}});e.exports=a},64147(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(30365),r=i(27496),a=i(71092),l=i(38578),c=a.extend({mixins:[l],tplScrollbarWrapper:'<div class="tx-scroll"></div>',tplScrollbarTrackVertical:'<div data-js-track-vertical class="tx-scrollbar-track tx-scrollbar-track--vertical"><div data-js-thumb-vertical class="tx-scrollbar-thumb"></div></div>',tplScrollbarTrackHorizontal:'<div data-js-track-horizontal class="tx-scrollbar-track tx-scrollbar-track--horizontal"><div data-js-thumb-horizontal class="tx-scrollbar-thumb"></div></div>',defaults:{trackActiveClass:"tx-scrollbar-track--active",scrollingClass:"tx-scroll--scrolling",containerClass:"tx-scroll-container",containerClassVertical:"tx-scroll-container--vertical",containerClassHorizontal:"tx-scroll-container--horizontal",infiniteScrollPercent:.9,isScrollable:!1,isScrollableHorizontal:!1,isScrollableVertical:!1,isScrolling:!1,nativeScrollbarSize:20},events:{"mousedown [data-js-thumb-vertical]":"_onVerticalThumbMousedown","mousedown [data-js-thumb-horizontal]":"_onHorizontalThumbMousedown"},destroyed:!1,constructor:function(e){var t=this._getElementFromOptions(e);return null===t?null:(this.container=t,this.$container=s(t),n.extend(e,{el:this._getWrappedElement(t)}),a.prototype.constructor.call(this,e))},initialize:function(e){this.$window=s(window),this._onScrollStopDebounced=n.debounce(n.bind(this._onScrollStop,this),150),this._onResizeDebounced=n.debounce(n.bind(this._onResize,this),150),this.render()},render:function(){return this.rendered&&!this.destroyed?this:(this.listenTo(r,"DOMEventor:flatresize",this._onResizeDebounced),this.listenTo(this,"change:isScrollableVertical",this._onChangeIsScrollableVertical),this.listenTo(this,"change:isScrollableHorizontal",this._onChangeIsScrollableHorizontal),this.listenTo(this,"change:isScrollable",this._onChangeIsScrollable),this.update(),this.destroyed=!1,a.prototype.render.apply(this,arguments))},getVerticalTrack:function(){return this.$verticalTrack},getHorizontalTrack:function(){return this.$horizontalTrack},getVerticalThumb:function(){return this.$verticalThumb},getHorizontalThumb:function(){return this.$horizontalThumb}
1,getScrollContainer:function(){return this.container},isScrollable:function(){return this.get("isScrollable")},isScrollableVertical:function(){return this.get("isScrollableVertical")},isScrollableHorizontal:function(){return this.get("isScrollableHorizontal")},update:function(){var e,t,i;this.destroyed||(e=this._isScrollableVertical(),t=this._isScrollableHorizontal(),i=e||t,this.set({isScrollableVertical:e,isScrollableHorizontal:t,isScrollable:i}),this._updateScrollConstants(),e&&(this._updateVerticalThumbHeight(),this._positionVerticalThumb()),t&&(this._updateHorizontalThumbWidth(),this._positionHorizontalThumb()))},remove:function(){return this.destroy()},destroy:function(){this.$container.off(".txScroll"),this.$window.off(".txScroll"),this.set({isScrollable:!1,isScrollableHorizontal:!1,isScrollableVertical:!1}),this.undelegateEvents(),this.stopListening(),this._unwrapContainer(),this.destroyed=!0},_getElementFromOptions:function(e){return e instanceof s?e.get(0):e instanceof window.Element?e:n.get(e,"el",null)},_getWrappedElement:function(e){var t=e instanceof s?e:s(e),i=s(this.tplScrollbarWrapper);return t.wrap(i),(i=t.parent()).get(0)},_unwrapContainer:function(){this.$container.unwrap()},_appendVerticalTrack:function(){var e=s(this.tplScrollbarTrackVertical);this.$verticalTrack=e,this.$verticalThumb=e.find("[data-js-thumb-vertical]"),this.$el.append(e)},_removeVerticalTrack:function(){var e=this.getVerticalTrack();e&&(e.remove(),delete this.$verticalTrack,delete this.$verticalThumb)},_appendHorizontalTrack:function(){var e=s(this.tplScrollbarTrackHorizontal);this.$horizontalTrack=e,this.$horizontalThumb=e.find("[data-js-thumb-horizontal]"),this.$el.append(e)},_removeHorizontalTrack:function(){var e=this.getHorizontalTrack(!0);e&&(e.remove(),delete this.$horizontalTrack,delete this.$horizontalThumb)},_onChangeIsScrollable:function(e,t){var i;this.destroyed||((i="ontouchstart"in document.documentElement)||this.$container.off("wheel.txScroll"),this.$container.off("scroll.txScroll"),this.$container.toggleClass(this.get("containerClass"),t),t&&(this.$container.on("scroll",n.bind(this._onScroll,this)),i||this.$container.on("wheel.txScroll",n.bind(this._stealScroll,this))))},_onChangeIsScrollableVertical:function(e,t){this.destroyed||(this.$container.toggleClass(this.get("containerClassVertical"),t),t?this._appendVerticalTrack():this._removeVerticalTrack())},_onChangeIsScrollableHorizontal:function(e,t){this.destroyed||(this.$container.toggleClass(this.get("containerClassHorizontal"),t),t?this._appendHorizontalTrack():this._removeHorizontalTrack())},_updateScrollConstants:function(){var e=this.getVerticalTrack(),t=this.getHorizontalTrack(),i=this.getVerticalThumb(),n=this.getHorizontalThumb();this.currentScrollTop=this.$container.scrollTop(),this.currentScrollLeft=this.$container.scrollLeft(),this.get("isScrollableVertical")&&e&&i&&(this.percentageDifferenceVertical=(this.container.scrollHeight-this.$container.height())/(e.height()-i.height())),this.get("isScrollableHorizontal")&&t&&n&&(this.percentageDifferenceHorizontal=(this.container.scrollWidth-this.$container.width())/(t.width()-n.width()))},_onResize:function(){this.trigger("resize"),this.update()},_getAddedScrollbarHeight:function(){return this.get("isScrollableHorizontal")?this.get("nativeScrollbarSize"):0},_getAddedScrollbarWidth:function(){return this.get("isScrollableVertical")?this.get("nativeScrollbarSize"):0},_isScrollableVertical:function(){return this.container&&this.container.scrollHeight>this.$container.height()+this._getAddedScrollbarHeight()},_isScrollableHorizontal:function(){return this.container&&this.container.scrollWidth>this.$container.width()+this._getAddedScrollbarWidth()},_getScrollTop:function(e,t){return e.pageY-t.offset().top},_getScrollLeft:function(e,t){return e.pageX-t.offset().left},_onVerticalThumbMousedown:function(e){var t=this.getVerticalTrack();e.preventDefault(),t&&(t.addClass(this.get("trackActiveClass")),this.$window.on("mousemove.txScroll",n.bind(this._onVerticalThumbMousemove,this)),this.$window.on("mouseup.txScroll",n.bind(this._onVerticalThumbMouseup,this)),this.mouseDownOriginalOffsetY=this._getScrollTop(e,t),this._updateScrollConstants())},_onHorizontalThumbMousedown:function(e){var t=this.getHorizontalTrack();e.preventDefault(),t&&(t.addClass(this.get("trackActiveClass")),this.$window.on("mousemove.txScroll",n.bind(this._onHorizontalThumbMousemove,this)),this.$window.on("mouseup.txScroll",n.bind(this._onHorizontalThumbMouseup,this)),this.mouseDownOriginalOffsetX=this._getScrollLeft(e,t),this._updateScrollConstants())},_onVerticalThumbMousemove:function(e){var t,i=this.getVerticalTrack();i&&o.read(function(){this.destroyed||(t=this._getScrollTop(e,i)-this.mouseDownOriginalOffsetY,o.write(function(){this.destroyed||this.$container.scrollTop(this.currentScrollTop+t*this.percentageDifferenceVertical)},this))},this)},_onVerticalThumbMouseup:function(e){var t=this.getVerticalTrack();e.preventDefault(),t&&t.removeClass(this.get("trackActiveClass")),this.$window.off(".txScroll")},_onHorizontalThumbMousemove:function(e){var t,i=this.getHorizontalTrack();i&&o.read(function(){this.destroyed||(t=this._getScrollLeft(e,i)-this.mouseDownOriginalOffsetX,o.write(function(){this.destroyed||this.$container.scrollLeft(this.currentScrollLeft+t*this.percentageDifferenceHorizontal)},this))},this)},_onHorizontalThumbMouseup:function(e){var t=this.getHorizontalTrack();e.preventDefault(),t&&t.removeClass(this.get("trackActiveClass")),this.$window.off(".txScroll")},_updateVerticalThumbHeight:function(){var e,t=this.getVerticalThumb(),i=this.getVerticalTrack();i&&t&&(e=this.$container.height()/this.container.scrollHeight,t.height(i.height()*e))},_updateHorizontalThumbWidth:function(){var e,t=this.getHorizontalThumb(),i=this.getHorizontalTrack();i&&t&&(e=this.$container.width()/this.container.scrollWidth,t.width(i.width()*e))},_positionVerticalThumb:function(){var e,t,i,n=this.getVerticalTrack(),s=this.getVerticalThumb();!this.destroyed&&n&&s&&(i=this.container.scrollTop,e=i/(this.container.scrollHeight-this.$container.height()),t=n.height()-s.height(),o.write(function(){this.destroyed||(s.css("transform","translate3d(0, "+t*e+"px, 0)"),this.trigger("scroll:vertical",i,e),this.trigger("scroll",i,e),e>this.get("infiniteScrollPercent")&&this.trigger("infinitescroll",i,e))},this))},_positionHorizontalThumb:function(){var e,t,i,n=this.getHorizontalTrack(),s=this.getHorizontalThumb();!this.destroyed&&n&&s&&(i=this.container.scrollLeft,e=i/(this.container.scrollWidth-this.$container.width()),t=n.width()-s.width(),o.write(function(){this.destroyed||(s.css("transform","translate3d("+t*e+"px, 0, 0)"),this.trigger("scroll:horizontal",i,e))},this))},_onScroll:function(){this.get("isScrolling")||(this.trigger("scrollstart"),this.$el.addClass(this.get("scrollingClass"))),this.set("isScrolling",!0),this._onScrollStopDebounced(),this.get("isScrollableVertical")&&o.read(n.bind(this._positionVerticalThumb,this)),this.get("isScrollableHorizontal")&&o.read(n.bind(this._positionHorizontalThumb,this))},_onScrollStop:function(){this.destroyed||(this.trigger("scrollstop"),this.set("isScrolling",!1),this.$el.removeClass(this.get("scrollingClass")))},_stealScroll:function(e){var t=e.currentTarget,i=e.originalEvent.deltaX,n=e.originalEvent.deltaY,o=Math.abs(i)>0,r=Math.abs(n)>0;this.get("isScrollableHorizontal")&&o&&(i<0&&t.scrollLeft<=0&&e.preventDefault(),i>0&&t.scrollLeft>=t.scrollWidth-s(t).width()-this._getAddedScrollbarWidth()&&e.preventDefault()),this.get("isScrollableVertical")&&r&&(n<0&&t.scrollTop<=0&&e.preventDefault(),n>0&&t.scrollTop>=t.scrollHeight-s(t).height()-this._getAddedScrollbarHeight()&&e.preventDefault())}});e.exports=c},64173(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(50283),r=i(59952),a=i(41301),l=o.extend({className:"popover--conversation-actions info_popover popover_gradient popover",mixins:[r],initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"viewOptions")),this.view=new a(this.viewOptions)},render:function(){return this.$wrapper=s("<div />").addClass("popover-inner popover_inner").appendTo(this.$el),this.$wrapper.html(this.view.render().$el),this},teardown:function(){return this.remove()},getView:function(){return this.view}});e.exports=l},64232(e,t,i){var n,s=i(71742),o=i(55679),r=i(2456),a=i(37136),l=i(86698),c=s.extend({name:"NotificationSoundManager",initialize:function(){var e=o.get(this.data,"sounds",[]),t=o.get(this.data,"soundpacks",{});this.soundCollection=new r(this._getSoundModels(e)),this.soundPackCollections=this._getSoundpackCollections(t)},playSoundName:function(e){var t=this.soundCollection.get(e);o.isEmpty(t)||this._playSoundModel(t)},playRandomFromSoundpack:function(e){var t=o.get(this.soundPackCollections,e);t&&this._playSoundModel(t.sample())},_playSoundModel:function(e){var t=new l({model:e}).render();this.listenToOnce(t,"ended",this._removeSoundView),t.play()},_removeSoundView:function(e){e.remove()},_getSoundModels:function(e){return o.map(e,function(e,t){return new a({name:t,filePath:e})})},_getSoundpackCollections:function(e){var t=this;return o.reduce(e,function(e,i,n){return e[n]=new r(t._getSoundModels(i)),e},{})}});e.exports=function(){return null==n&&(n=new c),n}},64423(e,t,i){"use strict";var n=i(71742),s=i(68222),o=i(27845),r=i(61551),a=i(33309),l=n.extend({name:"Viewability",autoAppend:!0,defaults:{},initialize:function(e){var t=this,i=e.isVideo,n=e.beacons,a=e.beaconRules,l=e.element;this.el=l,this.context=i?new o(this.el,function(){return t.stateChanged}):new s(this.el,function(){return t.stateChanged}),this.rulesEngine=new r(a,n,this.context)},stateChanged:function(e){switch(e){case a.RESET:this.rulesEngine.resetRules(function(e){return!0});break;case a.RESET_AUDIO:this.rulesEngine.resetAudioOnContinuousRules();break;case a.RESET_CONTINUOUS:this.rulesEngine.resetContinuousRules();break;default:this.rulesEngine.checkRules(this.context)}}});e.exports=l},64491(e,t,i){"use strict";var n=i(55679),s=new(i(28724))({defaults:{teardown:function(){return this},beforeTeardown:function(){},afterTeardown:function(){return this.teardownSubViews()},render:function(){return this},beforeRender:function(){},afterRender:function(){return this.renderSubViews()},attachSubView:function(e,t){if(1===arguments.length)if("string"==typeof e){if(t=e,!(e=this.subViews[t]))return this}else t=e.$el.data("subview")||"";var i=this.$('[data-subview="'+t+'"]');return i.length>1&&(i=i.first()),e&&i.length&&(i.replaceWith(e.$el),e.$el.attr("data-subview",t)),this}
1,attachSubViews:function(e){return n.forEach(this.subViews,this.attachSubView,this),this},teardownSubViews:function(){return n.forEach(this.subViews,function(e,t){e&&n.isFunction(e.teardown)&&e.teardown(),this.subViews[t]=null},this),this.subViews={},this},renderSubViews:function(){return n.forEach(this.subViews,function(e){e&&n.isFunction(e.render)&&e.render()},this),this},isInitialized:function(){return this._initialized},isRendered:function(){return this._rendered},isRendering:function(){return this._rendering},isRemoved:function(){return this._removed}},around:{initialize:function(e){this._initialized=!1,this._rendering=!1,this._rendered=!1,this._removed=!1,this.subViews={};var t=e.apply(this,n.rest(arguments));return this._initialized=!0,t},teardown:function(e){var t=n.rest(arguments);n.isFunction(this.beforeTeardown)&&this.beforeTeardown.apply(this,t);var i=e.apply(this,t);return n.isFunction(this.afterTeardown)&&this.afterTeardown.apply(this,t),this._rendered=!1,i},render:function(e){var t=n.rest(arguments);this._rendering=!0,n.isFunction(this.beforeRender)&&this.beforeRender.apply(this,t);var i=e.apply(this,t);return n.isFunction(this.afterRender)&&this.afterRender.apply(this,t),this._rendering=!1,this._rendered=!0,this.trigger("rendered"),i}},after:{remove:function(){this._removed=!0,this.subViews=null}}});e.exports=s},64528(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(71742),r=i(27496),a=i(77594),l=i(4408),c=o.extend({name:"switcher",mixins:[a],keycommands:{"keydown:alt+c":"macFastCompose","keydown:z+c":"winFastCompose"},loggingData:{},initialize:function(){this.$body=n("body"),this.$glass=null,this.suspended=!1,this.bindEvents()},bindEvents:function(){this.listenTo(r,"keycommands:suspend",this.suspend),this.listenTo(r,"keycommands:resume",this.resume),this.listenTo(r,"fastCompose:close:complete",this.dismissFastCompose),this.listenTo(r,"fastCompose:dismiss",this.dismissFastCompose),this.listenTo(r,"fastCompose:init",this.initFastCompose)},suspend:function(){this.suspended=!0},resume:function(){this.suspended=!1},macFastCompose:function(e){"MacIntel"===navigator.platform&&this.initFastCompose(e)},winFastCompose:function(e){"Win32"===navigator.platform&&this.initFastCompose(e)},initFastCompose:function(e){this.suspended||this.fastCompose||(this.determineSource(e),this.fastCompose=new l({loggingData:this.loggingData}),this.$body.append(this.fastCompose.render().el),this.showPlexi(),this.fastCompose.open(),r.trigger("fastCompose:init:complete"))},dismissFastCompose:function(){this.fastCompose&&(this.hidePlexi(),this.fastCompose.teardown(),this.fastCompose=null),r.trigger("fastCompose:dismiss:complete")},showPlexi:function(){this.$glass=n("<div>",{class:"glass show"}).appendTo(this.$body),s.defer(s.bind(function(){this.$glass.addClass("blue")},this)),r.trigger("drawer:suspend")},hidePlexi:function(){this.$glass.remove(),this.$glass=null,r.trigger("drawer:resume")},determineSource:function(e){this.loggingData.source="fast-compose",e&&(e.originalEvent instanceof window.KeyboardEvent?this.loggingData.source="keycommand":e.loggingData&&e.loggingData.source&&(this.loggingData.source=e.loggingData.source))}});e.exports=c},64792(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<div class="mute-icon"><div class="speaker"></div><div class="unmuted"></div><div class="muted"></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},64875(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(27496),r=i(44384),a=r.extend({events:{click:"_onClick"},className:"expand-post-content",classOnTruncatedEl:"truncated-content",transitionTime:50,initialize:function(e){this.parent=e.parent,this.parent.subViews||(this.parent.subViews={}),this.parent.subViews.expandContent=this,this.$photoPostIcons=this.parent.$(".photo-post-icons")},_onClick:function(e){this.expand()},expand:function(){this.parent.$el.velocity(this._parentDesiredCSS(),this.transitionTime,n.bind(function(){o.trigger("post:photo_expanded",this.parent.$el),o.trigger("search:post:photo_expanded",this.parent.$el)}
1,this)),this.$photoPostIcons.velocity({bottom:this.originalPhotoPostBottom},this.transitionTime,n.bind(function(){this.$photoPostIcons.css("bottom",""),this.$photoPostIcons=null},this)),this.$el.velocity({opacity:0},this.transitionTime,n.bind(function(){this.remove(),delete this.parent.subViews.expandContent},this))},_parentTruncatedCSS:function(){return{"max-height":this.parent.limitHeightTo+this.$el.height(),overflow:"hidden"}},_parentDesiredCSS:function(){return{"max-height":this.parent.desiredHeight}},render:function(){if(r.prototype.render.apply(this,arguments),this.$el.attr("data-subview","expandContent"),this.$el.text(s("Expand")),this.parent.$el.after(this.$el),this.parent.$el.css(this._parentTruncatedCSS()),this.$photoPostIcons.length){var e=this.$photoPostIcons[0].offsetTop;if(e>this.parent.limitHeightTo){var t=e-this.parent.limitHeightTo+20;this.originalPhotoPostBottom=parseFloat(this.$photoPostIcons[0].style.bottom),this.$photoPostIcons.css({bottom:t})}}return this}});e.exports=a},65364(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<div class="conversation-pagination-loader" data-js-loader-container><div data-subview="paginationLoaderView"></div></div><div data-js-header></div><div data-subview="messagesView[]" class="message-list"></div><div data-subview="statusBannerView"></div><div data-subview="pillView"></div><div data-js-footer></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},65707(e,t,i){"use strict";var n=i(55679),s=i(27496),o=i(71092),r=i(64491),a=i(38578),l=i(46520),c=i(27365),u=i(68100),h=i(51382),d=o.extend({className:"nav-search",mixins:[r,a],template:l,events:{"click .search-label":"__searchLabelClick","click .filter-icon":"__filterIconClick"},__searchLabelClick:function(){s.trigger("mobileHeader:search:click")},togglePopover:function(){this.popover||(this.popover=new u({pinnedTarget:this.subViews.filterIcon.$el,model:this.model}),this.popover.render(),this.listenTo(this.popover,"close",this.onPopoverClose))},onPopoverClose:function(){n.defer(n.bind(function(){this.popover=null},this))},__filterIconClick:function(){this.togglePopover()},onFilterChange:function(e){s.trigger("mobileHeader:filter:update",e),this.popover.hide()},bindEvents:function(){this.model&&(this.listenTo(this.model,"change:sort",this.onFilterChange),this.listenTo(this.model,"change:post_type",this.onFilterChange),this.listenTo(this.model,"change:filter_nsfw",this.onFilterChange))},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,e),this.get("logged_in")&&(this.subViews.filterIcon=new c,this.model=new h({showOriginalPostsSwitch:!1,showNsfwSwitch:!0,sort:this.get("filter_sort").toUpperCase(),post_type:this.get("filter_post_type").toUpperCase(),filter_nsfw:this.get("filter_nsfw")}),this.bindEvents())},render:function(){return this.$el.html(this.template(this.toJSON())),this.attachSubViews(),this},teardown:function(){this.popover&&this.popover.teardown()}});e.exports=d},66048(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<i class=\"icon_filter\"></i>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},66174(e,t,i){"use strict";var n=i(50283).extend({});e.exports=n},66303(e,t,i){var n,s=i(74692);function o(e,t,i){return!!s.ajax({url:e,type:"POST",data:JSON.stringify(t),contentType:"text/plain",async:i})}n=window.navigator&&window.navigator.sendBeacon?function(e,t,i){var n=window.navigator.sendBeacon(e,JSON.stringify(t));return n||(n=o(e,t,i)),n}:o,e.exports=n},66311(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(27496),r=i(80160),a=i(27513),l=r.extend({defaults:{maxRender:20,matchTerm:"",typeAheadMatches:[]},urlRoot:"/svc/search/blog_search_typeahead",url:function(){return this.urlRoot+"/"+this.get("blogname")},initialize:function(){this.items=new a,this.fetched=!1,this.listenTo(o,"peeprsearch:change:unsetTerm",this.onUnsetTermChange),this.listenTo(this,"change:matchTerm sync",this.setMatches)},onUnsetTermChange:function(e){this.set("matchTerm",e.term)},hasMatches:function(){return this.items.length&&this.get("typeAheadMatches").length||!this.fetched},setMatches:function(){var e=this.get("matchTerm");if(e.length){var t=this.items.filter(function(t){return t.get("tag").indexOf(e)>-1});this.set("typeAheadMatches",s.invoke(t,"toJSON"))}else this.set("typeAheadMatches",this.items.toJSON())},getItems:function(){if(this.items.length){var e=n.Deferred();return e.resolve(),e.promise()}return this.fetch(arguments)},parse:function(e){return this.items.reset(e.tags),this.fetched=!0,s.omit(e,"tags")}});e.exports=l},66419(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"message-container conversation-message-post--' +\n__e( postType ) +\n' ' +\n__e( _.isEmpty(thumbnail) ? 'no-thumbn
1ail' : 'has-thumbnail' ) +\n'' +\n__e( isDisabled ? ' is-disabled' : '' ) +\n'\"><div class=\"avatar\"><a href=\"' +\n__e( blogUrl ) +\n'\" target=\"_blank\" data-js-tumblelog-name=\"' +\n__e( name ) +\n'\"><img src=\"' +\n__e( avatarUrl ) +\n'\"></a></div> ';\n if (isDisabled) { ;\n__p += ' <div class=\"message-bubble\" data-js-message-bubble><div class=\"message-bubble-header\">' +\n__e( actionString ) +\n'</div></div> ';\n } else { ;\n__p += ' <div class=\"message-bubble\" data-js-message-bubble><div class=\"message-bubble-header\" data-js-summary><span class=\"name\">' +\n__e( actionString ) +\n'</span></div><div class=\"post-content-inner\"><p> ';\n if (isProjectXEnabled) { ;\n__p += ' <span class=\"message\">' +\n__e( __('This post may contain sensitive content.') ) +\n'</span><br> ' +\n((__t = ( __('%1$sLearn more%2$s', '<a class=\"link link-safemode-settings\" href=\"/docs/nsfw\" target=\"_blank\" data-js-theme-accent-color>','</a>') )) == null ? '' : __t) +\n' ';\n } else { ;\n__p += ' <span class=\"message\">' +\n__e( __('This post may contain sensitive media.') ) +\n'</span><br> ';\n if (canModifySafeMode) { ;\n__p += ' ' +\n((__t = ( __('%1$sSafe Mode is on%2$s', '<a class=\"link link-safemode-settings\" href=\"/settings/account#safe_mode\" target=\"_blank\" data-js-theme-accent-color>','</a>') )) == null ? '' : __t) +\n' ';\n } else { ;\n__p += ' ' +\n((__t = ( __('%1$sWhy am I seeing this?%2$s', '<a class=\"link link-safemode-settings\" href=\"/docs/nsfw\" target=\"_blank\" data-js-theme-accent-color>','</a>') )) == null ? '' : __t) +\n' ';\n } ;\n__p += ' ';\n } ;\n__p += ' </p></div><button class=\"retry-button\" data-js-retry-button>' +\n__e( __('Retry') ) +\n'</button></div> ';\n } ;\n__p += ' </div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},66458(e,t,i){"use strict";var n=i(97583).extend({logKey:"related_recommendations",logOptions:{init_event:!1},events:{"rapid-recommendations:*":"handleEvent"},logEnv:{location:document.location.pathname},handleEvent:function(e,t){this.log(e,t)}});e.exports=n},66596(e,t,i){"use strict";var n=i(55679),s=i(95093),o=i(21189),r=i(50283),a=i(60874),l=i(98237),c=i(78421),u=i(44370),h=i(95185),d=i(61371),p=i(65364),g=i(16309),f=r.extend({className:"conversation-messages",template:p,mixins:[l,a],defaults:{isVisible:!0,isPaginating:!1,tsHeaderThreshold:36e5,collapseMessagesThreshold:6e4,pillClickScrollSpeed:500,pillBottomThreshold:80},subviews:{paginationLoaderView:{constructor:c,options:{variation:"small h-centered",loading:!1}},messagesView:{constructor:h,options:function(e){return{eventBus:e.eventBus,participants:e.participants,conversation:e.conversation,formatter:e.messageFormatter,animateInMessage:e.animateInMessage,isSafeModeEnabled:e.isSafeModeEnabled,afterRetryClick:n.bind(e.afterRetryClick,e),afterImageUnblur:n.bind(e.afterImageUnblur,e),canModifySafeMode:e.canModifySafeMode,isProjectXEnabled:e.isProjectXEnabled}},collection:function(e){return e.collection}},statusBannerView:{constructor:g,options:function(e){return{otherParticipant:e.otherParticipant,name:e.otherParticipant.get("name")}}},pillView:{constructor:d,options:function(e){return{eventBus:e.eventBus}}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","collection","participants","conversation","messageFormatter","animateInMessage","isSafeModeEnabled","otherParticipant","canModifySafeMode","isProjectXEnabled"))},afterRenderSubviews:function(){this.scrollBar=new u({el:this.el,bottomThreshold:this.get("pillBottomThreshold")}),this.listenTo(this.collection,"update reset",this._onCollectionUpdate),this.listenTo(this.collection,"change:hasNextPage",this._onChangeHasNextPage),this.listenTo(this.collection,"change:isError",this._onChangeMessageIsError),this.listenTo(this.scrollBar,"scrolltop",this._onScrollChangeIsAtTop),this.listenTo(this.scrollBar,"scrollbottom",this._onScrollChangeIsAtBottom),this.listenTo(this.scrollBar,"scrollstop",this._createPositionSnapshot),this.listenTo(this.pillView,"click",this._onPillViewClick),this.listenTo(this,"change:isPaginating",this._onChangeIsPaginating),this.listenTo(this,"change:isVisible",this._onChangeIsVisible),this._onChangeHasNextPage(this.collection,this.collection.hasNextPage()),n.defer(n.bind(function(){this._processMessages(),this.updateScrollBar(),this.scrollToBottom()},this))},beforeRemove:function(){this.scrollBar&&this.scrollBar.destroy()},scrollToBottom:function(e){this._setScrollTop(this.el.scrollHeight,e)},getNextPage:function(){this.collection.hasNextPage()&&(this.set("isPaginating",!0),this.collection.fetchNextPage({at:0,isPaginating:!0,scrollBottom:this._getCurrentScrollBottom()}).always(n.bind(function(){this.set("isPaginating",!1)},this)))},updateScrollBar:function(){var e,t=this.scrollBar.isDisabled();this.scrollBar.setDisabled(!0),this.scrollBar&&this.scrollBar.update(
1),(e=this._getPositionDiff())&&this._setScrollTop(this.$el.scrollTop()+e.height+e.scrollTop),this._createPositionSnapshot(),this.scrollBar.setDisabled(t)},afterRetryClick:function(e){this.trigger("messageRetryClick",e)},afterImageUnblur:function(e){this.trigger("messageImageUnblur",e)},toggle:function(e){this.set("isVisible",e)},isAtBottom:function(){return!this._lastPosition||!this.scrollBar||this._lastPosition.scrollBottom<this.get("pillBottomThreshold")},showPill:function(e){return this._pillDefer&&this._pillDefer.reject(),this._pillDefer=o.defer(),this.pillView.setCount(e),this._pillDefer.promise},addHeaderView:function(e){var t=this._getCurrentScrollBottom();return this.js$("header").append(e.render().$el),this._adjustScrollbarAfterNewElements(t),e},removeHeaderView:function(e){return e.remove()},addFooterView:function(e){return this.js$("footer").append(e.render().$el),e},removeFooterView:function(e){return e.remove()},setIsAnimating:function(e){this.$el.toggleClass("is-animating",e)},_onChangeIsVisible:function(e,t){this.$el.css("visibility",t?"":"hidden"),t&&(this.updateScrollBar(),this.scrollToBottom())},_setScrollTop:function(e,t){t?this.$el.animate({scrollTop:e},t):this.$el.scrollTop(e),this._createPositionSnapshot()},_getCurrentScrollBottom:function(){return this.el.scrollHeight-this.$el.scrollTop()},_onCollectionUpdate:function(e,t){this._processMessages(t),n.get(t,"isPaginating")&&this._adjustScrollbarAfterNewElements(n.get(t,"scrollBottom")),n.defer(n.bind(function(){this.rendered&&this._adjustScrollbarAfterFetch(t)},this))},_adjustScrollbarAfterFetch:function(e){this.scrollBar&&this.scrollBar.update(),n.get(e,"isPolling")||n.get(e,"isPaginating")||this.scrollToBottom(),this._createPositionSnapshot()},_adjustScrollbarAfterNewElements:function(e){n.isNumber(e)&&(this.scrollBar.setDisabled(!0),this._setScrollTop(this.el.scrollHeight-e),n.delay(n.bind(function(){this.scrollBar.setDisabled(!1)},this),500))},_onChangeIsPaginating:function(e,t){this.paginationLoaderView.set("loading",t)},_onChangeHasNextPage:function(e,t){this.js$("loader-container").toggle(t)},_processMessages:function(e){var t,i=this.get("tsHeaderThreshold"),s=this.get("collapseMessagesThreshold"),o=(new Date).getTime();n.get(e,"isPolling")&&(o="new"),this.collection.each(function(e){e.set({tsHeader:this._getTimestampHeader(e,t,i),isCollapsed:this._getIsCollapsed(e,t,s,o)}),t=e},this)},_getTimestampHeader:function(e,t,i){var n=e?e.getTimestamp():null,o=t?t.getTimestamp():null;return!o||n-o>i?s(n).calendar():null},_getIsCollapsed:function(e,t,i,n){return e.has("collapseGroup")||e.set("collapseGroup",e.isNew()?"new":n),!!t&&(e.get("collapseGroup")===t.get("collapseGroup")&&(e.get("participant")===t.get("participant")&&e.getTimestamp()-t.getTimestamp()<i))},_getScrollPosition:function(){return this.scrollBar.getCurrentPositions()},_createPositionSnapshot:function(){this._lastPosition=this._getScrollPosition()},_getPositionDiff:function(){if(this._lastPosition){var e=this._getScrollPosition();return{scrollTop:this._lastPosition.scrollTop-e.scrollTop,scrollBottom:this._lastPosition.scrollBottom-e.scrollBottom,height:this._lastPosition.height-e.height}}},_onScrollChangeIsAtTop:function(e){e&&this.getNextPage()},_onScrollChangeIsAtBottom:function(e){e&&this._pillDefer&&(this._pillDefer.resolve(this.pillView.getCount()),this.pillView.setCount(0))},_onPillViewClick:function(){this.pillView.setCount(0),this.scrollToBottom(this.get("pillClickScrollSpeed")),this._pillDefer&&this._pillDefer.resolve()},_onChangeMessageIsError:function(){this.scrollToBottom()}});e.exports=f},66771(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(93063),r=i(98237),a=i(77594),l=s.extend({className:"messaging-share-post-external-network-subview-wrapper",template:o,mixins:[r,a],events:{"click [data-js-back-button]":"_onBackButtonClick"},keycommands:{"keydown:escape":"_onKeyPressEscape"},initialize:function(e){n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"externalNetworkSubview"))},getTemplateData:function(){return{title:this.externalNetworkSubview.getTitle()}},afterRender:function(){this.externalNetworkSubview.render(),this.listenTo(this.externalNetworkSubview,"changeTitle",this._onSubviewChangeTitle),this.listenToOnce(this.externalNetworkSubview,"close",this._onSubviewClose),this.js$("external-net
1work-subview").html(this.externalNetworkSubview.$el)},goBack:function(){this.trigger("goBack")},close:function(){this.trigger("close")},remove:function(){return this.externalNetworkSubview.remove(),s.prototype.remove.apply(this,arguments)},_onSubviewChangeTitle:function(e){this.js$("title").text(e)},_onSubviewClose:function(){this.close()},_onBackButtonClick:function(e){e.preventDefault(),this.goBack()},_onKeyPressEscape:function(e){e.preventDefault(),this.externalNetworkSubview.isShareSuccess()?this.close():this.goBack()}});e.exports=l},67019(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n\n if (!_.isEmpty(blogs)) { ;\n__p += ' <div class=\"blogs\"> ';\n _.each(blogs, function(blog) { ;\n__p += ' <a class=\"blog\" href=\"/messaging/conversation/' +\n__e( blog.name ) +\n'\" data-js-start-conversation=\"' +\n__e( blog.name ) +\n'\"><img class=\"avatar\" src=\"' +\n__e( blog.avatarUrl ) +\n'\" alt=\"' +\n__e( blog.name ) +\n'\" title=\"' +\n__e( blog.name ) +\n'\" width=\"40\" height=\"40\"> </a> ';\n }) ;\n__p += ' </div> ';\n } ;\n\n\n}\nreturn __p\n}").apply(void 0,r(s))},67103(e,t,i){var n=i(55679),s=i(74692),o=i(48357),r=i(98635),a=i(12461),l=i(59034),c=i(47640),u=function(){var e=13,t=27,i=function(e){this.onChange="onChange"in e&&n.isFunction(e.onChange)?e.onChange:n.noop,this.onDismiss=e.onDismiss||n.noop,this.bypassClasse
1s="bypassClasses"in e&&n.isArray(e.bypassClasses)?e.bypassClasses:[],this.maxWidth="maxWidth"in e&&n.isNumber(e.maxWidth)?e.maxWidth:600,this.minWidth="minWidth"in e&&n.isNumber(e.minWidth)?e.minWidth:200,this.linkElement=null,this.labels=n.extend({},{Edit:"Edit",Remove:"Remove",Open:"Open",Done:"Done"},e.labels),this.actionNames={edit:this.labels.Edit,remove:this.labels.Remove,open:this.labels.Open,done:this.labels.Done},u.call(this),l.call(this)};function u(){this.element=s("<div />",{class:"link-bubbles"}).css({position:"absolute",top:0,left:0}),this.linkUrl=s("<div />",{class:"url"}),this.linkEditInput=s("<input />",{type:"text",placeholder:"http://"}),this.linkEditDone=s("<div />",{class:"done"}).text(this.actionNames.done),this.linkUrl.hide(),this.linkUrl.append(this.linkEditInput).append(this.linkEditDone),h.call(this),this.element.append(this.linkUrl),this.hide()}function h(){var e=this,t=s("<div />",{class:"options"}),i={edit:function(){d.call(this)},remove:function(){var e=window.getSelection(),t=document.createRange();t.selectNodeContents(this.linkElement),e.removeAllRanges(),e.addRange(t),window.document.execCommand("unlink",!1,null),e.removeAllRanges(),this.onChange(),this.hide()},open:function(){var e=s(this.linkElement).attr("href");-1===e.indexOf("://")&&(e="http://"+e),window.open(e,"_blank")}};for(var n in i){var o=s("<div />",{class:n}).text(this.actionNames[n]);s(o).on("click",function(t){return function(){t.call(e)}}(i[n])),t.append(o)}t.hide(),s(this.element).append(t)}function d(){this.linkElement||c.error("Cannot edit link without a valid linkElement");var e=this.linkElement;p.call(this,function(t){s(e).attr("href",t)},s(e).attr("href"))}function p(i,n){n&&(this.linkEditInput.val(n),this.linkUrl.addClass("modified"));var o=this,r=function(){var e=s(o.linkEditInput).val().trim();i(e),o.onChange(),o.close()};s(this.linkEditInput).on("keydown",function(i){o.linkUrl.addClass("modified"),i.keyCode===e?(i.preventDefault(),r()):i.keyCode===t&&(o.close(),o.onDismiss(),i.stopPropagation())}),s(this.linkEditInput).on("keyup",function(i){i.keyCode!==t&&i.keyCode!==e&&g.call(o)}),s(this.linkEditInput).on("paste",function(e){o.linkUrl.addClass("modified"),g.call(o)}),this.linkEditDone.on("click",function(e){e.preventDefault(),r()}),this.element.find(".options").hide(),this.linkUrl.show(),this.show(),g.call(this),s(this.linkEditInput).focus()}function g(){var e=s(this.linkEditInput).val(),t=s(this.linkEditDone).outerWidth(),i=s(this.linkUrl).outerWidth()-s(this.linkUrl).width(),n=r.calcTextWidth(s(this.linkEditInput).get(0),e)+t+i+r.calcTextWidth(s(this.linkEditInput).get(0),"A"),a=n<this.minWidth?this.minWidth:n;a=a>this.maxWidth?this.maxWidth:a;var l=s(this.element),c=a-l.width();if(0!==c){var u=Math.floor(c/2);o(l,{width:a,left:"-="+u},{duration:40,easing:"ease"})}}return n.assign(i.prototype,l.prototype),i.prototype.createLink=function(e){p.call(this,function(t){a.restoreSelection(e),window.document.execCommand("createLink",!1,t);var i=window.getSelection(),n=i.getRangeAt(0);n.collapse(!1),i.removeAllRanges(),i.addRange(n)})},i.prototype.showOptions=function(e){this.linkElement=e,this.linkUrl.hide(),this.element.css({width:"",left:0}),this.element.find(".options").show()},i.prototype.close=function(){this.linkUrl.hide(),this.element.find(".options").hide(),this.element.css("width",""),this.linkEditInput.val("").unbind(),this.linkEditDone.unbind(),this.linkUrl.removeClass("modified"),this.linkElement=null,this.hide()},i.prototype.isValidLink=function(e){return!!e&&!n.some(this.bypassClasse
1s,function(t){return s(e).hasClass(t)})},i}();e.exports=u},67127(e){"use strict";var t=1,i=function(e){return e*t};i.get=function(){return t},i.set=function(e){t=e},e.exports=i},67421(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(80976).Ay,r=i(30365),a=i(17145),l=i(38578),c=i(44890),u=i(27496),h=i(7419),d=i(15855),p=a.extend({mixins:[l],defaults:{loaded:!1,paused:!0,muted:!0,autoplay:!1,_preload:!1,_preloadThreshold:10,loop:!0,autoheight:!1,watch:!0,duration:0,hideFullscreen:!1,_elapsed:0,_position:0,_startSeekJumpTime:null,minLoopDuration:0,isAd:!1,isInPeepr:!1,isFullscreen:!1},classNames:{base:"crt-video crt-skin-default",autoplay:"crt-state-autoplaying",autoheight:"crt-autoheight",hideFullscreen:"crt-hide-fullscreen-toggle"},constructor:function(e,t){this._id=n.uniqueId("crtplayer"),this.initialize(e,t)},initialize:function(e,t){t||(t={}),n.isObject(t.attributes)&&this.set(t.attributes),this.video=e,this.$video=s(this.video);var i=this.$video.data("crt-options")||{};this.$video.removeAttr("data-crt-options"),this.vjsOptions=n.defaults({crt:this,crtOptions:i},t.vjsOptions||{}),i&&i.duration&&this.set("duration",i.duration),this.vjsOptions.crtOptions.livestream&&(this.set("autoplay",!0),this.set("minLoopDuration",60)),r.write(function(){this.$video.addClass(this.classNames.base)},this)},render:function(){return r.write(function(){d(this.video,this.vjsOptions).then(n.bind(this.ready,this))},this),this},ready:function(e){this.player=e,this.player.muted(this.get("muted")),this.el=e.player_.el(),this.$el=s(this.el),this.$post=this.$el.closest(".post, .video-ad"),this.playerID=this.player.id_,this.hasLooped=!1,this._bindEvents(),this.setLoopState(!0),this.setAutoheightState(n.get(this.vjsOptions,"crtOptions.autoheight")),this.setFullscreenControl(!h.prop("requestFullscreen")),this.shouldForceHD()&&this.player.src({src:this.vjsOptions.crtOptions.hdUrl,type:"video/mp4"}),this.get("watch")&&this.setupWatcher()},_bindEvents:function(){this.listenTo(u,"peepr:open",this.pause),this.listenTo(u,"post:form:show",this.pause),this.listenTo(u,"post:docked:afterRender",this.onDockedAfterRender),this.on("change:autoplay",this.onChangeAutoplay,this),this.on("change:autoheight",this.onChangeAutoheight,this),this.on("change:duration",this.onChangeDuration,this),this.on("change:loop",this.onChangeLoop,this),this.on("change:muted",this.onChangeMuted,this),this.player.one("loadedmetadata",n.bind(this.onLoadedMetadata,this)),this.player.on("durationchange",n.bind(this.onUpdateDuration,this)),this.player.on("play",n.bind(this.onPlay,this)),this.player.on("pause",n.bind(this.onPause,this)),this.player.on("ended",n.bind(this.onEnded,this)),this.player.on("fullscreenchange",n.bind(this.onFullscreenChange,this)),this.player.on("error",n.bind(this.onError,this))},setupWatcher:function(){this.watcher=o.create(this.el,-100),this.watcher.fullyEnterViewport(n.bind(function(){this.trigger("fullyEnterViewport")},this)),this.watcher.partiallyExitViewport(n.bind(function(){this.trigger("partiallyExitViewport")},this)),this.watcher.exitViewport(n.bind(function(){this.trigger("exitViewport"),this.shouldAutoplay()&&this.pause()},this))},onClickPlayer:function(e){s(e.target).closest(".vjs-mute-control").length||s(e.target).closest(".vjs-fullscreen-control").length||this.pause(),this.set("autoplay",!1),this.set("muted",!1),this.$el.off("click.crtAutoPlay touchend.crtAutoPlay")},restart:function(){this.get("autoplay")&&(this.set("autoplay",!1),this.set("muted",!1),this.onTimeUpdate(),this.player.trigger({type:"restart",start:this.player.currentTime(),end:0}),this.player.currentTime(0))},pollTimeUpdate:function(){this.get("paused")||void 0===this.player||null==this.player||(this.onTimeUpdate(),setTimeout(n.bind(this.pollTimeUpdate,this),150))},shouldAutoplay:function(){return!(!this.get("autoplay")||c.bool("is_mobile")||!this.$el.is(":visible")||!(this.get("duration")>this.get("minLoopDuration")||0===this.get("duration")||this.vjsOptions.crtOptions.livestream))},shouldForceHD:function(){return!(!this.vjsOptions.forceHD||!this.vjsOptions.crtOptions.hdUrl)},play:function(e){e||(e={}),this.player.paused()&&(this.player.play(),e.skipLog||(e.type="userPlay",this.player.trigger(e)))},pause:function(e){e||(e={}),this.player.paused()||(this.player.pause(),e.skipLog||this.player.trigger("pause"))},onPlay:function(){this.set("paused",!1),this.pollTimeUpdate()},onPause:function(){this.set("paused",!0)},onUpdateDuration:function(e){this.set("duration",this.player.duration())},onLoadedMetadata:function(e){var t=this.shouldAutoplay();this.setMutedState(t),this.setAutoplayState(t),t&&this.$el.on("click.crtAutoPlay touchend.crtAutoPlay",n.bind(this.onClickPlayer,this)),u.trigger("CrtPlayer:ready",this),this.trigger("playerReady",this),this.trigger("ready",this),this.set("loaded",!0)},onEnded:function(e){!0===this.get("loop")?(this.play({skipLog:!0}),this.player.trigger("loop"),this.get("autoplay")||this.hasLooped||(this.hasLooped=!0)):(this.pause({skipLog:!0}),this.player.trigger("end"))},onError:function(e){this.set("paused",!0),this.set("loop",!1),this.set("autoplay",!1),this.trigger("error",e)},onChangeAutoplay:function(e,t,i){this.setAutoplayState(t,i)},onChangeAutoheight:function(e,t){this.setAutoheightState(t)},onChangeDuration:function(e,t){this.setLoopState(!0)},onChangeLoop:function(e,t){this.setLoopState(t)},onChangeMuted:function(e,t){this.player.muted(t)},onFullscreenChange:function(){this.$post.hasClass("docked")&&(this.player.isFullscreen()?(this.cached_top=this.$el.position().top,this.$el.css("top",0)):this.$el.css("top",this.cached_top))},onDockedAfterRender:function(e){n.isEmpty(e.embedID)||this.playerID===e.embedID&&this.player.trigger("CRTPlayer:updateDimensions")},setLoopState:function(e){n.isUndefined(e)&&(e=this.get("loop")),this.set("loop",e),void 0!==this.get("duration")&&this.get("duration")<=this.get("minLoopDuration")&&this.set("loop",!1)},setMutedState:function(e){n.isUndefined(e)&&(e=this.get("muted")),this.set("muted",e)},setAutoplayState:function(e){n.isUndefined(e)&&(e=this.get("autoplay")),this.set("autoplay",e),this.toggleAttrClass("autoplay",e),!e&&this.get("duration")&&this.setLoopState(!0)},setAutoheightState:function(e){(n.isUndefined(e)||n.isNull(e))&&(e=this.get("autoheight")),this.set("autoheight",e),this.toggleAttrClass("autoheight",e)},setFullscreenControl:function(e){n.isUndefined(e)&&(e=this.get("hideFullscreen")),this.set("hideFullscreen",e),this.toggleAttrClass("hideFullscreen",e)},onTimeUpdate:function(){var e=this.get("_position"),t=this.player.currentTime(),i=Math.abs(e-t);i<.3&&this.set("_elapsed",this.get("_elapsed")+i),this.set("_position",t),this.set("_startSeekJumpTime",t)},getStartSeekJumpPosition:function(){return this.get("_startSeekJumpTime")},getPosition:function(){return Math.floor(this.get("_position"))},getElapsed:function(){return Math.floor(this.get("_elapsed"))},toggleAttrClass:function(e,t){this.classNames[e]&&r.write(function(){this.$el.toggleClass(this.classNames[e],t)},this)},teardown:function(){this.trigger("teardown",this),this.off(),this.stopListening(),this.watcher&&(this.watcher.destroy(),this.watcher=null),this.player&&(this.player.dis
1pose(),this.player=null)}});e.exports=p},67750(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(48357),r=i(81515),a=i(50283),l=i(78421),c=i(98237),u=i(5143).animation,h=i(7419),d=i(27496),p=i(72681),g=i(66596),f=i(23182),m=i(10074),_=i(85474),v=i(91450),b=i(54980),y=i(96791),w=i(79990),C=i(64173),x=i(43736),k=i(72042).html,S=i(68311),T=i(4883),E=i(69823),P=i(40718),I=a.extend({template:P,className:"messaging-conversation-wrapper",defaults:{isError:!1,canSend:!0,isPossibleSpam:!1,isLoading:!0,isHidePendingPost:!1,isFetching:!0,isFetched:!1,isFetchingIcebreakers:!1,isOffline:!1,isAutoFetch:!0,isMinimized:!1,isDropping:!1,isCurrentDropValid:!0,animateInMessageDuration:500,minimizeOpeningClass:"is-minimize-opening",minimizeClosingClass:"is-minimize-closing",droppingClassName:"is-dropping",noBlurSupportClass:"no-blur-support",imagePreviewAnimateInDurationMs:300,imagePreviewAnimateOutDurationMs:200,imagePreviewAnimateInEasing:[.22,.685,.03,.895],imagePreviewAnimateOutEasing:[.895,.03,.685,.22],imageUploadMaxBytes:null,canModifySafeMode:!0,isProjectXEnabled:!1},events:{"click [data-js-tumblelog-name]":"_onBlogClick","click [data-js-messaging-tumblelog-name]":"_onMessagingBlogClick","click [data-js-lightbox-url]":"_onImageLightboxUrlClick","click [data-js-main]":"_onMainContainerClick",dragover:"_onDragOver",dragenter:"_onDragEnter",dragleave:"_onDragLeave",drop:"_onDragDrop",keydown:"_onKeyDown"},mixins:[c],subviews:{conversationLoaderView:{constructor:l,options:{variation:"small centered",loading:!1}},headerView:{constructor:p,options:function(e){return{eventBus:e.eventBus,participants:e.sortedParticipants,theme:e.theme,channels:e.channels,user:e.user}}},messagesView:{constructor:g,options:function(e){return{eventBus:e.eventBus,collection:e.model.get("messages"),participants:e.model.get("participants"),conversation:e.model,isSafeModeEnabled:e.isSafeModeEnabled,messageFormatter:e.messageFormatter,animateInMessage:n.bind(e._animateInMessage,e),otherParticipant:e.otherParticipant,canModifySafeMode:e.canModifySafeMode,isProjectXEnabled:e.isProjectXEnabled}}},previewView:{constructor:m,options:function(e){return{animateInDurationMs:e.get("imagePreviewAnimateInDurationMs"),animateOutDurationMs:e.get("imagePreviewAnimateOutDurationMs"),animateInEasing:e.get("imagePreviewAnimateInEasing"),animateOutEasing:e.get("imagePreviewAnimateOutEasing")}}},composeView:{constructor:_,options:function(e){return{eventBus:e.eventBus,keyboardManager:e.keyboardManager,keyboardNamespace:e.keyboardNamespace+":compose",pluginsArray:e.getPluginsArray(),pluginAnimateInDurationMs:e.get("imagePreviewAnimateOutDurationMs"),pluginAnimateOutDurationMs:e.get("imagePreviewAnimateInDurationMs"),pluginAnimateInEasing:e.get("imagePreviewAnimateOutEasing"),pluginAnimateOutEasing:e.get("imagePreviewAnimateInEasing")}}},minimizedView:{constructor:v,options:function(e){return{eventBus:e.eventBus,model:e.model}}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","user","model","channels","messageFormatter","popoverContainer","keyboardManager","collection","isSafeModeEnabled","canModifySafeMode","isProjectXEnabled")),this.keyboardNamespace="conversation:"+this.cid,this.model||(this.model=new w),this.messageFormatter||(this.messageFormatter=new k),this.conversation=this.model,this.sortedParticipants=this._getSortedParticipantsCopy(),this.otherParticipant=this.conversation.getOtherParticipant(),this.getGenericErrorMessage=S([r("Something went screwy."),r("Something's busted."),r("Something got snagged."),r("Something's acting up."),r("Something sucks!"),r("Internet is being dumb."),r("Computer weirdness."),r("The server is being foolish."),r("Something fizzled."),r("The internet evaporated."),r("The internet is being wiggly."),r("Something went splat."),r("Server turned to dust."),r("Something's wonky."),r("Something's not happening."),r("Something's not working."),r("Something got messed up."),r("Unknown, totally annoying error."),r("A nameless error mysteriously occurred."),r("Our computer is a loser."),r("Something pooped out."),r("Something fell into a volcano."),r("Something is all gummed up."),r("Something melted.")]),this.permanentPostErrorMessage=r("Can't send this post."),this.getRetryPostErrorMessage=S([r("Hrm. Post didn't send."),r("Blegh. Post didn't send."),r("Fffft. Post didn't send."),r("Welp. Post didn't send."),r("Sending machine broke.")]),this.customErrorMessages={403.7001:r("Please verify your email address before talking to a Tumblr."),403.7003:r("Sorry, %1$s only allows messages from Tumblrs they follow.",this.otherParticipant.get("name")),409:r("You can only send messages to Tumblrs you follow."),429:r("You've hit the daily limit on new conversations. Impressive.")}
1,this.getSpamErrorMessage=S([r("Look sketchy?"),r("Look suspicious?"),r("Look fishy?"),r("Look shady?"),r("Seem fake?"),r("Is this spam?")]),this.easeOutExpo=[.19,1,.22,1],this.dragCount=0},render:function(){return this.imageUploadPlugin=new E({imageUploadMaxBytes:this.getImageUploadMaxBytes()}),a.prototype.render.apply(this,arguments)},afterRenderSubviews:function(){this.listenTo(this,"change:isError change:isLoading",this._setOpenViewStates),this.listenTo(this,"change:isHidePendingPost change:isFetching change:isError change:isFetchingIcebreakers",this._setLoadingState),this.listenTo(this,"change:isOffline",this._onChangeIsOffline),this.listenTo(this,"change:canSend",this._onChangeCanSend),this.listenTo(this,"change:isPossibleSpam",this._onChangeIsPossibleSpam),this.listenTo(this,"change:isMinimized",this._onChangeIsMinimized),this.listenTo(this,"change:isDropping",this._onChangeIsDropping),this.listenTo(this,"change:isCurrentDropValid",this._onChangeIsCurrentDropValid),this.listenTo(d,"tumblr_lightbox:form:hide",this._onTumblrLightboxFormHide),this.listenTo(this.composeView,"submit",this._onComposeSubmit),this.listenTo(this.composeView,"resize",this._onComposeResize),this.listenTo(this.composeView,"input",this._onComposeInput),this.listenTo(this.composeView,"focus",this._onComposeFocus),this.listenTo(this.composeView,"blur",this._onComposeBlur),this.listenTo(this.composeView,"plugin:preview:add:image",this._onComposeViewPluginPreviewAddImage),this.listenTo(this.composeView,"plugin:click",this._onComposeViewPluginClick),this.listenTo(this.composeView,"pasteBlob",this._onComposePasteBlob),this.listenTo(this.headerView,"closeClick",this._onTriggeredClose),this.listenTo(this.headerView,"minimizeClick",this._onHeaderMinimizeClick),this.listenTo(this.headerView,"moreActionsClick",this._onHeaderMoreActions),this.listenTo(this.conversation,"change:id",this._onChangeId),this.listenTo(this.conversation,"change:unreadCount",this._onChangeUnreadCount),this.listenTo(this.conversation,"change:can_send",this._onChangeConversationCanSend),this.listenTo(this.conversation,"change:is_possible_spam",this._onChangeConversationIsPossibleSpam),this.listenTo(this.conversation.get("messages"),"change:hasNextPage",this._onChangeMessagesHasNextPage),this.listenTo(this.messagesView,"pillClick",this._onPillClick),this.listenTo(this.messagesView,"messageRetryClick",this._onMessageRetryClick),this.listenTo(this.messagesView,"messageImageUnblur",this._onMessageImageUnblur),this.listenTo(this.composeView,"close",this._onTriggeredClose),this.listenTo(this.minimizedView,"click",this._onMinimizedViewClick),this.listenTo(this.previewView,"close",this._onPreviewViewClose),this.listenTo(this.previewView,"closing",this._onPreviewViewClosing),this.listenTo(this.previewView,"dismiss",this._onPreviewViewDismiss),this.listenTo(this.previewView,"edit",this._onPreviewViewEdit),this._setLoadingState(),this._setMainViewStates(),this._setOpenViewStates(),this._onChangeConversationCanSend(this.conversation,this.conversation.get("can_send")),this._onChangeCanSend(this,this.get("canSend")),this._onChangeConversationIsPossibleSpam(this.conversation,this.conversation.get("is_possible_spam")),this._onChangeIsPossibleSpam(this,this.get("isPossibleSpam")),this.get("isAutoFetch")&&this.fetch(),this.mainTheme=this._applyTheme(this.el),this.js$("conversation-open").toggleClass(this.get("noBlurSupportClass"),!h.cssFilters())},beforeRemove:function(){this.conversation.get("messages").reset(this.conversation.getInboxMessage()),this.keyboardManager.remove(this.keyboardNamespace),this.trigger("close")},fetch:function(e){return e=e||{},n.extend(e,{error:n.bind(this._onFetchConversationFail,this)}),this.set("isFetching",!0),this.eventBus.trigger(this.eventBus.CONVERSATION_FETCHING,this.conversation),this._pendingQueueItems=this.conversation.getQueueItems(),this.conversation.clearQueue(),this.conversation.fetchConversation(e).then(n.bind(this._onFetchConversationSuccess,this)).always(n.bind(this._onFetchConversationAlways,this))},poll:function(e,t){return e=e||{},this.eventBus.trigger(this.eventBus.CONVERSATION_FETCHING,this.conversation),this.conversation.poll(e,t).then(n.bind(function(){this.messagesView.scrollToBottom()},this))},refresh:function(e){this._queueMessages(e.getQueueItems()),this.unminimize(),this.focus()},focus:function(){return this.isMinimized()?this.focusMinimized():this.focusCompose(),this},getImageUploadMaxBytes:function(){return this.get("imageUploadMaxBytes")},getPluginsArray:function(){var e=[];return e.push(new T({collection:this.collection})),n.isEmpty(this.imageUploadPlugin)||e.push(this.imageUploadPlugin),e},isMinimized:function(){return this.get("isMinimized")},focusMinimized:function(){this.minimizedView&&this.minimizedView.focus()},focusCompose:function(){this.composeView&&this.composeView.focus()},toggleMinimize:function(e,t){var i,o,r,a=new s.Deferred,l=this.get("minimizeOpeningClass"),c=this.get("minimizeClosingClass"),u=this.js$("conversation-open"),h=this.js$("conversation-minimized"),d=[a];return e===this.isMinimized()?(new s.Deferred).resolve():(i=function(){this.set("isMinimized",e)},o=function(){a.resolve()},t?(i.call(this),o.call(this)):e?this._addAnimationClass(u,c).then(n.bind(function(){i.call(this),this._addAnimationClass(h,l).then(n.bind(o,this))},this)):this._addAnimationClass(h,c).then(n.bind(function(){i.call(this),this._addAnimationClass(u,l).then(n.bind(o,this))},this)),e||this.get("isFetched")||(r=this.fetch(),d.push(r)),s.when.apply(s,d))},minimize:function(e){return this.toggleMinimize(!0,e)},unminimize:function(e){return this.toggleMinimize(!1,e)},_showError:function(e){var t,i,n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return this.conversationErrorView&&this.conversationErrorView.remove(),i=this.js$("main"),t=new b(e),i.append(t.render().$el),this.conversationErrorView=t,this.set({isOffline:n,isError:!0}),this._applyTheme(t.el),t},_hideError:function(){this.conversationErrorView&&(this.conversationErrorView.remove(),this.conversationErrorView=null),this.set({isError:!1,isOffline:!1}),this.focus()},_onFetchConversationSuccess:function(){this.rendered&&(this.set("isFetched",!0),this._hideError(),this.conversation.markAsRead(),this.otherParticipant.set(this.conversation.getOtherParticipant().toJSON()),this.messagesView.statusBannerView.trigger("setActiveTime",this.otherParticipant.get("seconds_since_last_activity")),this.minimizedView.trigger("setIsOnline",
1-1!==this.otherParticipant.get("seconds_since_last_activity")),this._queueMessages(this._pendingQueueItems),this._pendingQueueItems=null,this.conversation.get("messages").hasNextPage()||(this.set("isFetchingIcebreakers",!0),this._createIcebreakersView().always(n.bind(function(){this.set("isFetchingIcebreakers",!1),this.focus()},this))))},_flushMessageQueue:function(){var e;return this.conversation.hasQueue()?(e=this.conversation.getQueueItems(),this.eventBus.trigger(this.eventBus.CONVERSATION_MESSAGES_SEND_REQUESTED,e,this.conversation),this.conversation.isFlushingQueue()||(this.eventBus.trigger(this.eventBus.CONVERSATION_MESSAGES_SENDING,e,this.conversation),this._flushDefer=this.conversation.flushMessageQueue().progress(n.bind(this._onFlushProgress,this)).fail(n.bind(this._onFlushFail,this)).always(n.bind(this._onFlushAlways,this))),this._flushDefer):(new s.Deferred).reject()},_onFlushProgress:function(e,t){this.rendered&&this.set("isHidePendingPost",!t&&!this._canRenderPendingMessage(e)),t?this.eventBus.trigger(this.eventBus.CONVERSATION_MESSAGE_SENT,e,this.conversation):this.eventBus.trigger(this.eventBus.CONVERSATION_MESSAGE_SENDING,e,this.conversation)},_onFlushFail:function(e){this.eventBus.trigger(this.eventBus.CONVERSATION_MESSAGE_FAILED,e,this.conversation),this.rendered&&(this._canRenderPendingMessage(e)||(this.conversation.get("messages").remove(e),this._showPostSendingError(e)),this._flushMessageQueue())},_onFlushAlways:function(){this.rendered&&(this.set("isHidePendingPost",!1),this.focus())},_onFetchConversationFail:function(e,t){var i,s=t.status,o=n.get(t,"responseJSON.errors.0.code");this.rendered&&(n.isFinite(o)&&o>0&&(i=this.customErrorMessages[s+"."+o]),n.isEmpty(i)&&(i=n.get(this.customErrorMessages,s,this.getGenericErrorMessage())),this._showError({message:i,buttonCallback:n.bind(this._onConversationErrorRetryClick,this),showButton:e.canRetryFetch(n.get(t,"status"))}))},_showPostSendingError:function(e){var t,i,s;if(this.rendered){if(!e.canRetry())return t=this.permanentPostErrorMessage,i=r("Close"),s=this._onPostSendingErrorCloseClick,void this._showError({message:t,buttonCallback:n.bind(s,this),buttonText:i},!1);t=this.getRetryPostErrorMessage(),s=n.partial(this._onPostSendingErrorRetryClick,e),this._showError({message:t,buttonCallback:n.bind(s,this),buttonText:i})}},_onPostSendingErrorCloseClick:function(){this._hideError()},_onPostSendingErrorRetryClick:function(e){this._resendMessage(e).then(n.bind(function(){this._hideError()},this))},_onFetchConversationAlways:function(){this.rendered&&this.set("isFetching",!1)},_onComposeSubmit:function(e,t){var i,s,o=this.previewView.getMessage(),r=!n.isEmpty(e),a=!n.isEmpty(o);r&&(i=w.createTextMessage(e,{hasAnimation:!0,creationUserAction:t})),a&&(o.set({isFromPreview:!0,hasAnimation:!0,creationUserAction:t}),r&&i.set({context:o.get("context")})),s=n.compact([o,i]),a?this.previewView.close().then(n.bind(function(){n.delay(n.bind(function(){this.rendered&&this._queueMessages(s)},this),150)},this)):this._queueMessages(s),this.messagesView.scrollToBottom()},_canRenderPendingMessage:function(e){return!n.isEmpty(e)&&(!e.isPost()||e.getPost().hasThumbnail())},_queueMessages:function(e,t){return n.isEmpty(e)?(new s.Deferred).reject():(t=n.extend({},t,{isSendingMessage:!0}),n.isArray(e)||(e=[e]),n.each(e,n.bind(function(e){e.set("isQueued",!0),this.conversation.addMessage(e,t)},this)),this.conversation.appendToQueue(e,t),this._flushMessageQueue())},_resendMessage:function(e){var t=this.conversation.get("messages");return t.last()!==e&&t.remove(e),this._queueMessages(e)},_onComposeResize:function(){this.messagesView.updateScrollBar()},_onComposeInput:function(e,t){this.trigger("compose:input",e,t),this.eventBus.trigger(this.eventBus.CONVERSATION_MESSAGE_INPUT,this.conversation,e)},_onComposeFocus:function(e){this.trigger("compose:focus",e)},_onComposeBlur:function(e){this.trigger("compose:blur",e)},_onComposePasteBlob:function(e){this._isFileDropEnabled()&&this._addImageToFilePreview(e,"clipboard")},_onChangeId:function(e){e.isNew()||this.trigger("created",e)},_onChangeUnreadCount:function(e,t){0===t||this.isMinimized()||(this.messagesView.isAtBottom()?this._fetchUnreadMessages().then(n.bind(function(){this.eventBus.trigger(this.eventBus.CONVERSATION_MESSAGES_UNREAD_FETCHED)},this)):this.messagesView.showPill(t).then(n.bind(this._fetchUnreadMessages,this)).catch(n.noop))},_fetchUnreadMessages:function(){var e=this.conversation.get("unreadCount"),t=Math.min(10,e+5);return 0===e?(new s.Deferred).reject():(this.conversation.markAsRead(),this.poll(null,t))},_getSortedParticipantsCopy:function(){var e=this.conversation.get("participants"),t=this.channels.getSortedIds(this.conversation.get("participantUuid")),i=e.getSortedByChannels(t,!0);return new e.constructor(i)}
1,_setLoadingState:function(){var e=this.get("isFetching")||this.get("isHidePendingPost")||this.get("isFetchingIcebreakers");this.set("isLoading",!this.get("isError")&&e)},_setMainViewStates:function(){var e=this.get("isMinimized"),t=this.js$("conversation-open"),i=this.js$("conversation-minimized");t.toggle(!e),i.toggle(e),e?i.css("display",""):t.css("display","")},_setOpenViewStates:function(){var e=this.get("isError"),t=this.get("isLoading");this.messagesView.toggle(!e&&!t),this.composeView.set("isDisabled",e||t),this.conversationLoaderView.set("loading",t)},_setDragDropClasses:function(){var e=this.get("droppingClassName"),t=this.get("isCurrentDropValid"),i=this.get("isDropping"),n=this._isFileDropEnabled()&&i&&t;this.js$("conversation-open").toggleClass(e,n),this.js$("conversation-minimized").toggleClass(e,n)},_createIcebreakersView:function(){var e;return this.icebreakersView?((e=new s.Deferred).reject(),e):this.otherParticipant.fetchAdditionalInfo(this.conversation.getParticipantId()).then(n.bind(function(){var e;this.rendered&&(e=this.conversation.isNew(),this.icebreakersView=new x({participant:this.otherParticipant,isShowTags:e,isShowRelationship:!e,isShowDescription:!e}),this.messagesView.addHeaderView(this.icebreakersView))},this))},_onTriggeredClose:function(){this.trigger("close")},_onHeaderMoreActions:function(e){this.actionsPopover&&this.actionsPopover.isOrWasRecentlyRendered()||this._showMoreActionsPopover(e)},_onHeaderMinimizeClick:function(){this.minimize()},_onMinimizedViewClick:function(){this.unminimize()},_onPillClick:function(){this.focus()},_onBlogClick:function(e){var t=s(e.currentTarget);this.eventBus.trigger(this.eventBus.CONVERSATION_OPEN_TUMBLR_URL,{blogName:t.attr("data-js-tumblelog-name"),postId:t.attr("data-js-post-id"),searchTagTerm:t.attr("data-js-tumblelog-tag"),url:t.attr("href"),originalEvent:e,otherParticipant:this.otherParticipant})},_onMessagingBlogClick:function(e){var t=s(e.currentTarget);this.eventBus.trigger(this.eventBus.CONVERSATION_OPEN_MESSAGING_URL,{blogName:t.attr("data-js-messaging-tumblelog-name"),url:t.attr("href"),originalEvent:e})},_onImageLightboxUrlClick:function(e){e.preventDefault();var t,i=s(e.currentTarget),o=i.attr("data-js-lightbox-width"),r=i.attr("data-js-lightbox-height"),a=i.attr("data-js-lightbox-lowres-url"),l=i.attr("data-js-lightbox-url");n.isEmpty(a)||n.isEmpty(l)||(t={width:o,height:r,low_res:a,high_res:l},n.get(t,"low_res")&&(this.eventBus.trigger(this.eventBus.CONVERSATION_IMAGE_LIGHTBOX,{lightBoxImageData:[t]}),this.composeView.set("isLightboxOpen",!0)))},_onActionsBlock:function(e){var t=this.conversation.getParticipantModel();n.isEmpty(t)||this.eventBus.trigger(this.eventBus.BLOCK,{currentTumblelog:t.get("name"),blockedTumblelog:e,context:"messaging"},this.conversation)},_onActionsDelete:function(){this.eventBus.trigger(this.eventBus.CONVERSATION_DELETE_MODEL,this.conversation)},_applyTheme:function(e){var t;return n.isEmpty(this.otherParticipant)?null:(t=this.otherParticipant.get("theme"),n.isEmpty(t)?null:new y({el:e,theme:t}).render())},_showMoreActionsPopover:function(e){var t;this.actionsPopover&&this.actionsPopover.remove(),this.actionsPopover=new C({autoTeardown:!0,pinnedSide:"bottom",pinnedTarget:e,popoverContainer:this.popoverContainer,viewOptions:{participants:this.conversation.get("participants"),user:this.user}}),t=this.actionsPopover.getView(),this.listenTo(t,"block",this._onActionsBlock),this.listenTo(t,"delete",this._onActionsDelete),this.actionsPopover.render()},_animateInMessage:function(e,t,i){var s,r,a=e.$el,l=this.composeView.$el.offset(),c=a.offset(),u=Math.max(0,l.top-c.top)+a.height();i.get("isFromPreview")?s=0:(r=t.offset(),s=l.left-r.left),this.messagesView.setIsAnimating(!0),o.animate(a,{translateY:[0,u],translateX:[0,s],opacity:[1,1]},{duration:this.get("animateInMessageDuration"),easing:this.easeOutExpo,complete:n.bind(function(){this.messagesView.setIsAnimating(!1),i.set("hasAnimation",!1),a.css("transform","")},this)})},_addAnimationClass:function(e,t){var i=new s.Deferred;return e.removeClass(t),u(e,function(){e.removeClass(t),i.resolve()}),e.addClass(t),i},_addImageToFilePreview:function(e,t){var i=function(){this.imageUploadPlugin.addImageFile(e,t)};this.isMinimized()?this.unminimize().then(n.bind(i,this)):i.call(this)},_isFileDropEnabled:function(){return this.rendered&&!this.previewView.hasImage()&&this.get("canSend")&&!this.get("isError")},_onConversationErrorRetryClick:function(e){return this.fetch()},_onChangeIsOffline:function(e,t){this.composeView.set("isOffline",t)},_onMessageRetryClick:function(e){this._resendMessage(e)},_onMessageImageUnblur:function(e){this.conversation.unblurImages()},_onChangeConversationCanSend:function(e,t){this.set("canSend",t)},_onChangeConversationIsPossibleSpam:function(e,t){this.set("isPossibleSpam",t)},_onChangeCanSend:function(e,t){var i=r("This Tumblr can't receive messages.");this.composeView.toggle(t),!t&&this.canSendErrorView||t&&!this.canSendErrorView||(t?(this.messagesView.removeFooterView(this.canSendErrorView),delete this.canSendErrorView):(this.canSendErrorView=new f({message:i,showErrorIcon:!0}),this.messagesView.addFooterView(this.canSendErrorView)))},_onChangeIsPossibleSpam:function(e,t){t&&this.isPossibleSpamView||!t&&!this.isPossibleSpamView||(t?(this.isPossibleSpamView=new f({message:this.getSpamErrorMessage(),actionText:r("Mark as spam"),actionCallback:n.bind(this._onMarkAsSpamLinkClick,this)}),this.messagesView.addFooterView(this.isPossibleSpamView)):(this.messagesView.removeFooterView(this.isPossibleSpamView),delete this.isPossibleSpamView))},_onChangeIsMinimized:function(e,t){this._setMainViewStates(),t||n.defer(n.bind(function(){this.messagesView.updateScrollBar(),this.focus(),this.conversation.get("unreadCount")>0&&(this._fetchUnreadMessages(),this.messagesView.scrollToBottom())},this)),this.trigger(t?"minimized":"unminimized")},_onChangeIsDropping:function(e,t){this._setDragDropClasses()},_onChangeIsCurrentDropValid:function(e,t){this._setDragDropClasses()},_onMainContainerClick:function(){window.getSelection().isCollapsed&&this.focus()},_onKeyDown:function(e){9===e.keyCode&&(e.shiftKey?this.trigger("keydown:shift+tab",e):this.trigger("keydown:tab",e))},_onDragOver:function(e){var t=n.get(e,"originalEvent.dataTransfer.types",[]),i=n.contains(t,"Files"),s=this._isFileDropEnabled();e.preventDefault(),this.set("isCurrentDropValid",i),n.set(e,"originalEvent.dataTransfer.dropEffect",i&&s?"copy":"none")},_onDragEnter:function(){this.dragCount++,this.set("isDropping",!0)},_onDragLeave:function(){this.dragCount--,this.set("isDropping",this.dragCount>0)},_onDragDrop:function(e){var t=n.get(e,"originalEvent.dataTransfer.files",[]);e.preventDefault(),this.dragCount=0,this.set("isDropping",!1),0!==t.length&&(this.previewView.hasImage()?this.isMinimized()&&this.unminimize():this._isFileDropEnabled()&&this._addImageToFilePreview(n.last(t),"drop"))},_onComposeViewPluginPreviewAddImage:function(e){this.previewView.addImage(e),this.messagesView.updateScrollBar(),this.composeView.toggleAutoValidation(!1),this.focus(),this.eventBus.trigger(this.eventBus.CONVERSATION_IMAGE_PREVIEW_ADD,this.conversation,e)},_onComposeViewPluginClick:function(e){this.eventBus.trigger(this.eventBus.CONVERSATION_COMPOSE_PLUGIN_CLICK,this.conversation,e)},_onPreviewViewClosing:function(e){this.focus()},_onPreviewViewClose:function(e){this.messagesView.updateScrollBar(),this.composeView.toggleAutoValidation(!0),this.focus()},_onPreviewViewDismiss:function(e){this.eventBus.trigger(this.eventBus.CONVERSATION_IMAGE_PREVIEW_DISMISS,this.conversation,e)},_onPreviewViewEdit:function(e){this.eventBus.trigger(this.eventBus.CONVERSATION_IMAGE_PREVIEW_EDIT,this.conversation,e)},_onMarkAsSpamLinkClick:function(){this.eventBus.trigger(this.eventBus.CONVERSATION_MARK_AS_SPAM,this.conversation,this.otherParticipant)},_onChangeMessagesHasNextPage:function(e,t){!this.rendered||this.conversation.isNew()||t||this._createIcebreakersView()},_onTumblrLightboxFormHide:function(){this.composeView.set("isLightboxOpen",!1)}});e.exports=I},67800(e,t,i){"use strict";var n=i(55679),s=i(27513),o=i(77370),r=s.extend({model:o,comparator:function(e){return e.getConversation().get("lastOpenedDateTs")},getByIdAndParticipant:function(e,t){var i=this.find(function(i){var n=i.getConversation();return n.get("id")===e&&n.get("participantUuid")===t});return i?i.getConversation():null},getByConversationModel:function(e){return this.find(function(t){var i=t.getConversation();return!n.isEmpty(i)&&i.isSameConversation(e)})}});e.exports=r},68100(e,t,i){"use strict";var n=i(8925),s=i(47525),o=n.extend({className:n.prototype.className+" blog-search-filters-popover",Subview:s});e.exports=o},68211(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(50283),r=i(98237),a=i(77594),l=i(76343),c=o.extend({className:"messaging-share-post-search",template:l,mixins:[r,a],events:{"input [data-js-in
1put]":"_onInputChange","focus [data-js-input]":"_onInputFocus","blur [data-js-input]":"_onInputBlur",click:"_onContainerClick"},defaults:{hasSelectedBlogNameClass:"has-selected-blog",isFocused:!1,currentQuery:""},keycommands:{"keydown:backspace":"_onKeyPressBackspace","keydown:enter":"_onKeyPressEnter"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"selectedRecipientModel","keyboardManager","keyboardNamespace")),this.disableKeys()},afterRender:function(){this.listenTo(this.selectedRecipientModel,"change:participant",this._onChangeSelectedRecipient),this.listenTo(this,"change:isFocused",this._onChangeIsFocused),this.listenTo(this,"change:currentQuery",this._onChangeCurrentQuery),this.js$("selected-blog").hide()},focus:function(){this.js$("input").focus()},getQuery:function(){return this.get("currentQuery")},_clearInput:function(){this._setInputValue()},_setInputValue:function(e){e=e||"",this.js$("input").val(e),this._prevVal=e},_getSelectedRecipient:function(){return this.selectedRecipientModel.get("participant")},_hasSelectedRecipient:function(){return!n.isEmpty(this._getSelectedRecipient())},_onChangeSelectedRecipient:function(e,t){this._setBlogPillRecipient(t),n.isEmpty(t)?this._setInputValue(this.get("currentQuery")):this._clearInput()},_setBlogPillRecipient:function(e){var t=!n.isEmpty(e);this.js$("selected-blog").text(t?e.get("name"):"").toggle(t),this.$el.toggleClass(this.get("hasSelectedBlogNameClass"),t)},_setCurrentQuery:function(e,t){t&&this.unset("currentQuery",{silent:!0}),this.set("currentQuery",e)},_onInputChange:function(e){var t,i,n=s(e.currentTarget).val();this._prevVal!==n&&(t=this.get("currentQuery"),i=this._hasSelectedRecipient()&&n===t,this._setCurrentQuery(n,i),this._prevVal=n)},_onKeyPressBackspace:function(e){this._hasSelectedRecipient()&&(e.preventDefault(),this._setCurrentQuery("",!0))},_onKeyPressEnter:function(e){e.preventDefault(),this.trigger("submit",this)},_onContainerClick:function(){this.focus()},_onInputFocus:function(){this.set("isFocused",!0)},_onInputBlur:function(){this.set("isFocused",!1)},_onChangeIsFocused:function(e,t){t?(this.keyboardManager.add(this.keyboardNamespace,this),this.trigger("focus",this)):(this.keyboardManager.remove(this.keyboardNamespace),this.trigger("blur",this))},_onChangeCurrentQuery:function(e,t){t=t||"",this._hasSelectedRecipient()&&this._setBlogPillRecipient(null),n.isEmpty(t)?this.trigger("clear"):this.trigger("search",t)}});e.exports=c},68222(e,t,i){function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function s(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,o(n.key),n)}}function o(e){var t=function(e,t){if("object"!=n(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var s=i.call(e,t||"default");if("object"!=n(s))return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==n(t)?t:t+""}function r(e,t,i){return t=l(t),function(e,t){if(t&&("object"==n(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,a()?Reflect.construct(t,i||[],l(e).constructor):t.apply(e,i))}function a(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(a=function(){return!!e})()}function l(e){return l=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},l(e)}function c(e,t){return c=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},c(e,t)}var u=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),r(this,t,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&c(e,t)}(t,e),i=t,(n=[{key:"isMuted",value:function(){return!0}},{key:"timePosition",value:function(){return 0!==this.timeInView?this.getTimeOffset()-this.timeInView:0}},{key:"maxDuration",value:function(){return 0}},{key:"getMacroValue",value:function(e){return""}}])&&s(i.prototype,n),o&&s(i,o),Object.defineProperty(i,"prototype",{writable:!1}),i;var i,n,o}(i(77171));e.exports=u},68311(e,t,i){"use strict";var n=i(55679);e.exports=function(e){var t,i;return e=e||[],function(){return n.isEmpty(t)&&(t=n.shuffle(e),n.isEmpty(i)||(t=n.without(t,i))),i=t.pop()}}},68318(e,t,i){"use strict";var n=i(55679),s=i(45736),o=s.acequire("ace/mode/html").Mode,r=s.acequire("ace/tokenizer").Tokenizer,a=function(){o.apply(this,arguments),function(){var e=new this.HighlightRules,t=this.$rules=e.getRules(),i={token:function(e,t,i,n){return["meta.tag.tumblr.begin",t=t?"entity.other.tumblr.prefix":"","entity.other.tumblr.tag","meta.tag.tumblr.end"]},regex:/(\{|\{\/)((?:(?:Plaintext|JS|JSPlaintext|URLEncoded|RGB)?(?:select:|font:|text:|image:|color:|lang:))|block:)?([\-_a-zA-Z0-9 ]+)(\})/},s=["string","keyword","variable","constant"];
1n.forEach(t,function(e,t){e.unshift(i),t.match(/^css-/i)&&n.forEach(e,function(e){e.token=function(e,t){var i=e.token;return n.contains(s,i)?t+i:i}(e,"css_"),"caseInsensitive"in e&&(e.caseInsensitive=!1)}),"start_tag_stuff"===t&&n.forEach(e,function(e){"meta.tag.punctuation.end"===e.token&&(e.regex="/?>|}")}),"end_tag_stuff"===t&&n.forEach(e,function(e){"meta.tag.punctuation.end"===e.token&&(e.regex=">|}")})}),this.$tokenizer=new r(this.$rules)}.call(this)};a.prototype=new o,e.exports=a},68320(e,t,i){var n=i(50283),s=i(27496),o=i(55679),r=i(74692),a=n.extend({defaults:{target:"g-recaptcha",sitekey:""},initialize:function(e){this.options=e||{};var t=document.createElement("script");t.src="",window.onNocaptchaCallback=o.bind(this.setupCaptcha,this);var i=document.getElementsByTagName("script")[0];i.parentNode.insertBefore(t,i)},setupCaptcha:function(){this.sitekey=r(".g-recaptcha").data("sitekey"),window.grecaptcha.render(this.options.target||"g-recaptcha",{callback:this.options.callback,"expired-callback":this.options.expiredCallback,theme:this.options.theme||"light",type:this.options.type||"image",sitekey:this.options.sitekey||r(".g-recaptcha").data("sitekey")}),s&&s.on("abouttumblr:change",function(e){0!==e&&5!==e||window.grecaptcha.reset()})},refresh:function(){window.grecaptcha.reset()}});e.exports=a},68592(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div aria-label=\"' +\n__e( ariaText ) +\n'\" title=\"online\" class=\"status-indicator\"></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},68707(e,t,i){"use strict";var n=i(74692),s=i(91685),o=i(26024),r=s.extend(o,{render:function(){return this.$el=n('<div class="vjs-hover-slider-time" aria-live="off"></div>'),this},update:function(e){e||(e={});var t=e.hoverX||0,i=e.hoverTime||"0:00",n=s.formatTime(i);this.$el.html(n),this.$el.css("left",t+"px")}});e.exports=r},68722(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div class=\"form-container success\"><div class=\"success-message\"><h1 class=\"message-title\"> ' +\n((__t = ( __('Got it') )) == null ? '' : __t) +\n' </h1><p class=\"message-text\"> ' +\n((__t = ( __('Our Support team will be emailing you shortly.') )) == null ? '' : __t) +\n' <br> ' +\n((__t = ( __('And thanks for bringing this thing to our attention.') )) == null ? '' : __t) +\n' </p></div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},68921(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(71742),r=i(27496),a=i(52181),l=i(80756),c=i(60500),u=i(60186),h=o.extend({name:"AskComponent",initialize:function(e){e=e||{},this.user=e.user,this.user&&(this.blog=this.user.getChannel(),this.question=new u({recipient:null,anonymous:!1,question:""}),this.listenTo(r,"ask:form:open",this.presentAskForm),this.listenTo(this.question,"save:success",this.onSaveSuccess))},presentAskForm:function(e){return this.askFormView||(this.question.set("recipient",e.recipient),n("body").addClass("postforms-open"),r.trigger("drawer:suspend"),r.trigger("keycommands:suspend"),this.glass=new a,this.modal=new l,this.askFormView=new c({model:this.question,characterLimit:500,recipient:{name:e.recipient,allowAnonymous:e.allow_anonymous},sender:this.blog}),this.askFormView.render(),this.modal.setContentSubView(this.askFormView),this.glass.render().$el.appendTo("body"),this.modal.render().$el.appendTo("body"),this.glass.show().then(s.bind(this.modal.show,this.modal)),this.listenTo(this.askFormView,"close",this.dismissAskForm),this.listenTo(this.askFormView,"submit",this.submit)),this},beforeRemove:function(){this.dismissAskForm()},dismissAskForm:function(){this.askFormView&&(this.stopListening(this.askFormView),this.modal.hide(),this.modal.remove(),this.modal=null,this.glass.hide(),this.glass.remove(),this.glass=null,this.askFormView.remove(),this.askFormView=null,r.trigger("keycommands:resume"),r.trigger("drawer:resume"),r.trigger("ask:form:hidden"),n("body").removeClass("postforms-open"))},submit:function(e){this.question.set("anonymous",!!e.anonymous),this.question.set("question",e.question),this.question.save()},onSaveSuccess:function(){r.trigger("ask:form:success"),this.dismissAskForm()}});e.exports=h},69053(e,t,i){"use strict";var n=i(44384).extend({hasSubViews:{}});e.exports=n},69107(e,t,i){"use strict";var n=i(55679),s=i(50283).extend({defaults:{isDisabled:!1,isActive:!1},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults)))},getName:function(){return null},addToImagePreview:function(e){this.trigger("preview:add:image",e)},toggleActive:function(e){this.set("isActive",e)},toggleDisabled:function(e){this.set("isDisabled",e)}});e.exports=s},69271(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(50283),r=i(59952),a=o.extend({className:"popover--inbox-popover",mixins:[r],defaults:{animationSpeed:100},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"viewOptions","viewConstructor"))},render:function(){return this.$wrapper=s("<div />").addClass("popover-inner").appendTo(this.$el),this.$wrapper.addClass("hide-popover"),this.$pinned.addClass("active"),this._createView(this.viewOptions),n.defer(n.bind(function(){this.$wrapper.removeClass("hide-popover")},this)),this},teardown:function(){var e=this.get("animationSpeed");return this.$wrapper.addClass("hide-popover"),this.$pinned.removeClass("active"),e>0?setTimeout(n.bind(this._afterHide,this),this.get("animationSpeed")):this._afterHide(),this},getView:function(){return this.inboxView},_createView:function(e){e=n.isFunction(e)?e.call(this,this):e,this.inboxView&&this.inboxView.remove(),this.inboxView=new this.viewConstructor(e),this.$wrapper.html(this.inboxView.render().$el)},_afterHide:function(){this.inboxView&&this.inboxView.remove(),this.$el.remove()}});e.exports=a},69464(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(60874),r=i(98237),a=i(77594),l=i(85179),c=i(44765),u=i(77656),h=s.extend({className:"inbox-recipients",template:u,mixins:[r,a,o,l],keycommands:{"keydown:down":"_onKeyPressDown","keydown:up":"_onKeyPressUp","keydown:enter":"_onKeyPressEnter"},defaults:{isEmpty:!0,showMessageOnEmpty:!0,selectedView:null,context:"inbox:recipients"},subviews:{recipients:{constructor:c,options:function(e){return{eventBus:e.eventBus,onSelect:n.bind(e._onSubviewSelect,e),onClear:n.bind(e._onSubviewClear,e),context:e.context,isNewEmptyInboxEnabled:e.isNewEmptyInboxEnabled}},collection:function(e){return e.collection}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","collection","title","context","isNewEmptyInboxEnabled")),this.keyboardViewName="recipients",this.disableKeys()},afterRender:function(){this.listenTo(this.collection,"reset update",this._onCollectionChange),this.listenTo(this.collection,"sync",this._onCollectionSync),this.listenTo(this.collection,"sort",this._onCollectionSort),this.listenTo(this,"change:isEmpty",this._onChangeIsEmpty),this.listenTo(this,"change:selectedView",this._onChangeSelectedView),this._onCollectionChange(this.collection),this._onChangeIsEmpty(this,this.get("isEmpty"))},getTemplateData:function(){return{title:this.title,noResultsText:this.collection.getNoResultsFoundMessage()}},toggle:function(e){this.$el.toggle(e),e&&this.deselect(this.keyboardViewName)},_onChangeSelectedView:function(e,t){var i=this.previous("selectedView");i&&i.setSelected(!1),t&&t.setSelected(!0)},_onChangeIsEmpty:function(e,t){this.get("showMessageOnEmpty")?this.js$("no-results-container").toggle(t):(this.js$("container").toggle(!t),this.js$("no-results-container").hide())},_shuffleNoResultsText:function(){this.js$("no-results-text").text(this.collection.getNoResultsFoundMessage())},_onCollectionSort:function(){this.renderCollectionSubviews("recipients")},_onCollectionChange:function(e){this.set("isEmpty",0===e.length),this.deselect(this.keyboardViewName)},_onCollectionSync:function(e){0===e.length&&this.get("showMessageOnEmpty")&&this._shuffleNoResultsText()},_onSubviewSelect:function(e){this.set("selectedView",e),this.setSelectedIndex(this.keyboardViewName,n.indexOf(this.recipients,e))},_onSubviewClear:function(e){this.set("selectedView",null),this.deselect(this.keyboardViewName)},_onKeyPressDown:function(e){var t;e.preventDefault(),t=this.isLastSelected(this.keyboardViewName)?this.selectFirst(this.keyboardViewName):this.selectNext(this.keyboardViewName),this.set("selectedView",t)},_onKeyPressUp:function(e){var t;e.preventDefault(),t=this.isFirstSelected(this.keyboardViewName)?this.selectLast(this.keyboardViewName):this.selectPrevious(this.keyboardViewName),this.set("selectedView",t)},_onKeyPressEnter:function(e){var t,i=this.get("selectedView");e.preventDefault(),i?t=i.model:1===this.collection.length&&(t=this.collection.first()),t&&this.eventBus.trigger(this.eventBus.CONVERSATION_OPEN_PARTICIPANT_MODELS,[t],this.context)}});e.exports=h},69523(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape;\nwith (obj) {\n__p += \'<div class="content"><div class="header-container"><h2 class="header" data-js-header>\' +\n__e( header ) +\n\'</h2></div><div data-subview="blogsView"></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},69661(e,t,i){"use strict";var n=i(55679),s=i(27513),o=i(93049),r=s.extend({model:o,getSortedByChannels:function(e,t){var i=this.clone(),s=t?-1:1,o=e.length;return i.sortBy(function(t){var i=n.indexOf(e,t.get("uuid"));return s*(i>-1?o-i:-1)})},getWithout:function(e){return this.clone().filter(function(t){return!n.contains(e,t.get("uuid"))})}});e.exports=r},69823(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(74692),r=i(98237),a=i(49779),l=i(81512),c=i(43315),u=i(79990),h=i(50052),d=i(10631),p=l.extend({className:"conversation-compose-plugin conversation-compose-plugin--image-upload",template:d,mixins:[r],defaults:n.defaults({isFilePickerOpen:!1},l.prototype.defaults),events:{click:"_onClick",focus:"_onFocus","change [data-js-file-picker]":"_onFilePickerChange","click [data-js-file-picker]":"_onFilePickerClick"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,"imageUploadMaxBytes"))},getName:function(){return"messaging-image-upload"},afterRender:function(){this.listenTo(this,"change:isFilePickerOpen",this._onChangeIsFilePickerOpen),l.prototype.afterRe
1nder.apply(this,arguments)},addImageFile:function(e,t){var i,o,r=Math.floor(this.get("imageUploadMaxBytes")/1048576);this.messagingImageUploader=new h({file:e,imageUploadMaxBytes:this.get("imageUploadMaxBytes")}),this.messagingImageUploader.uploadImage().then(n.bind(function(s){var r=n.get(s,"src"),a=n.get(s,"width"),l=n.get(s,"height");o=u.createImageMessage(r,e,a,l,{context:this.getName(),loggingData:{imageSource:t}}),i=new c({url:r,file:e,width:a,height:l,message:o,context:this.getName(),editCallback:n.bind(this.onEdit,this),loggingData:{imageSource:t}}),this.addToImagePreview(i)},this),function(e){var t=n.get(e,"type");if(t)switch(t){case"format":a.alert(s("Invalid file type."));break;case"size":a.alert(s("Image must be smaller than %1$sMB",r))}else a.alert(s("Something about that file is off. Try sending something else."))})},_openFilePicker:function(){this.$el.focus(),this.set("isFilePickerOpen",!0),this.js$("file-picker").click()},onEdit:function(){this._openFilePicker()},_onFilePickerChange:function(e){var t=n.first(o(e.target).prop("files"));this.set("isFilePickerOpen",!1),this.js$("file-picker").val(""),this.addImageFile(t,"filesystem")},_onFilePickerClick:function(e){e.stopPropagation()},_onClick:function(e){this._openFilePicker(),this.trigger("click",this)},_onFocus:function(){this.set("isFilePickerOpen",!1)},_onChangeIsFilePickerOpen:function(e,t){this.toggleActive(t)}});e.exports=p},69843(e,t,i){"use strict";i.d(t,{A:()=>c});var n=i(97583),s=i.n(n),o=i(30351),r=i(44890),a=i.n(r),l=s().extend({logKey:"little_sister",logSpots:[],events:function(){return a().bool("little_sister")?{"LSLog:*":"log"}:{}},log:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t.pt,n=t.is_ad,s=t.video_details,r=t.extraData;i&&(o.Ay.log(i).trigger(e,{pt:i,eventName:e,video_details:s,extraData:r}),(n||"supply_unload"===e)&&o.Ay.flush())}});const c=l},69912(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div class=\"avatar\"><img src=\"' +\n__e( avatarUrl ) +\n'\" title=\"' +\n__e( blogName ) +\n'\"></div><div data-subview=\"statusIndicator\"></div><div class=\"conversation-minimized-badge tab_notice tab-notice--outlined ' +\n__e( statusIndicatorUiFlag ? 'status-indicator-active'  : '' ) +\n'\" data-js-badge><span class=\"tab_notice_value\" data-js-badge-value>2</span></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},70201(e,t,i){"use strict";var n=i(80160).extend({idAttribute:"url",defaults:{width:null,height:null,url:null}});e.exports=n},70241(e){"use strict";e.exports=function(e,t){return t||(t=this),function(){var i=Array.prototype.slice.call(arguments);return i.unshift(this),e.apply(t,i)}}},70305(e,t,i){"use strict";var n=i(55679),s=i(36910).extend({name:"MessagingKeyboardManager",addKeyboardAccess:function(e){return!!n.isFunction(n.get(e,"soloKeys"))&&(e.enableKeys(),e.soloKeys(!0),!0)},removeKeyboardAccess:function(e){return!!n.isFunction(n.get(e,"unSoloKeys"))&&(e.disableKeys(),e.unSoloKeys(),!0)}});e.exports=s},70589(e,t,i){"use strict";var n=i(55679),s=i(97583).extend({logKey:"video_interactions",logEnv:{referrer:document.location.pathname},events:{"VideoPlayer:cacheUnload":"cacheUnloadLog","VideoPlayer:timeupdate":"updateLogCache","VideoPlayer:*":"handleEvent"},initialize:function(){this.excludedEvents=["cacheUnload","timeupdate"],this.unloadData={},n.each(this.loggers,function(e){e.before_unloaded=n.bind(this.beforeUnloaded,this)},this)},handleEvent:function(e,t){if(!n.contains(this.excludedEvents,e)){var i=n.extend({},t);i.postData&&(i.post_id=i.postData.id,delete i.postData),this.log(e,i)}},cacheUnloadLog:function(e,t){this.unloadData[t.id]=t},beforeUnloaded:function(e){n.each(this.unloadData,function(e){this.handleEvent("unload",e)},this)},updateLogCache:function(e,t){this.unloadData[t.id]=n.extend(this.unloadData[t.id],n.pick(t,["elapsed","position"]))}});e.exports=s},70962(e,t,i){"use strict";var n=i(71092),s=i(64491),o=i(98237),r=i(38578),a=i(61014),l=n.extend({className:"post-forms-loader",mixins:[s,o,r],template:a,initialize:function(e){this.listenTo(this,"change:loading",this._onChangeLoading),this.set("loading",e&&e.loading)},_onChangeLoading:function(e,t){this.isRendered()&&(t?(this.$el.addClass("loading"),this.$$(".Knight-Rider-loader").addClass("animate")):(this.$el.removeClass("loading"),this.$$(".Knight-Rider-loader").removeClass("animate")))},render:function(){return this.$el.html(this.template(this.attributes)),this}});e.exports=l},71092(e,t,i){"use strict";var n=i(55679),s=i(21391),o=i(71827),r=["model","collection","el","id","attributes","className","tagName","events"],a=["_setup"];function l(e,t){t||(t={}),e||(e=[]),n.each(e,function(e){n.isFunction(this[e])&&this[e].call(this,t)},this)}var c=s.View.extend({constructor:function(e){this.cid=n.uniqueId("view"),e||(e={}),n.extend(this,n.pick(e,r)),this._elAttributes=this.attributes,this.attributes={},this._ensureElement(),this.setupMethods=n.union(a,this.constructor.__super__.setupMethods,this.setupMethods),l.call(this,this.setupMethods,e),this.initialize.apply(this,arguments),this.delegateEvents()},_setup:n.noop,_ensureElement:function(){if(this.el)this.setElement(n.result(this,"el"),!1);else{var e=n.extend({},n.result(this,"_elAttributes"));this.id&&(e.id=n.result(this,"id")),this.className&&(e.class=n.result(this,"className"));var t=s.$("<"+n.result(this,"tagName")+">").attr(e);this.setElement(t,!1)}}});o.applyTo(c),e.exports=c},71271(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, \'\') }\nwith (obj) {\n__p += \'<div data-subview="headerView"></div><div data-subview="composeView"></div><div class="inbox-main"><div data-subview="loader"></div><div data-subview="conversationsView"></div></div> \';\n if (isNewEmptyInboxEnabled) { ;\n__p += \' <div class="empty-suggestions"><div data-subview="inboxRecipientsView"></div></div> \';\n } ;\n__p += \' <div data-subview="emptyView"></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},71280(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(38578),r=i(27496),a=i(63717),l=s.extend({template:a,mixins:[o],className:"drawer logged-out",initialize:function(e){e=n.extend({},e),n.extend(this.attributes,e),this.listenToOnce(r,"drawer:open",this.downloadBackgroun
1d)},downloadBackground:function(){var e=new Image,t=this.$splashBg.data("img-src");e.onload=n.bind(function(){this.$splashBg.css("background-image","url("+t+")"),this.$splashBg.addClass("loaded")},this),e.src=t},render:function(){return this.$el.html(this.template(this.toJSON())),this.$splashBg=this.$(".splash-bg"),this}});e.exports=l},71315(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(98237),r=i(50283),a=i(56703),l=i(69523),c=r.extend({className:"inbox-empty",template:l,mixins:[o],subviews:{blogsView:{constructor:a,options:function(e){return{collection:e.collection,eventBus:e.eventBus}}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","collection"))},getTemplateData:function(){return{header:s("Talk to a Tumblr")}},toggle:function(e){this.$el.toggle(e)}});e.exports=c},71641(e,t,i){"use strict";i.d(t,{A:()=>M});var n=i(97583),s=i.n(n),o=i(55679),r=i.n(o),a=i(77232),l=i.n(a);function c(e){return c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}function u(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,h(n.key),n)}}function h(e){var t=function(e,t){if("object"!=c(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=c(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==c(t)?t:t+""}var d=function(){return e=function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e);var n=t.screen,s=t.location,r=t.navigator,a=r.appVersion,c=r.browserLanguage,u=r.cookieEnabled,h=r.onLine,d=r.language,p=r.languages,g=r.userAgent,f=r.vendor,m=new(l())(g).getResult(),_=m.browser,v=m.os,b=m.device,y=(new t.Date).getTime(),w="".concat(t.outerWidth,"x").concat(t.outerHeight);(0,o.assign)(this,{appVersion:a,browserName:_.name,browserVersion:_.version,client:t,colorDepth:n.colorDepth,cookiesEnabled:u,createdAt:y,deviceModel:b.model,deviceType:b.type,deviceVendor:b.vendor,hasJavascript:!0,isOnline:h,language:d||c,languages:p||[],location:s,osName:v.name,osVersion:v.version,resolution:w,screenHeight:n.height,screenWidth:n.width,userAgent:g,vendor:f},i)},(t=[{key:"screenType",get:function(){if(this.page)return this.page;var e=this.location.pathname,t={Dashboard:"/dashboard",Explore:"/explore",Tagged:"/tagged",SearchResults:"/search",About:"/about",Jobs:"/jobs",Logo:"/logo",Business:"/business",Buttons:"/buttons",Press:"/press",Developers:"/developers",Terms:"/terms",Policy:"/policy",Apps:"/apps",Themes:"/themes",Analytics:"/analytics"};for(var i in t)if(t.hasOwnProperty(i)){var n=t[i];if((0,o.startsWith)(e,n))return i}return"Unknown"}},{key:"timezone",get:function(){return(new this.client.Date).getTimezoneOffset()}},{key:"isHeadlessBrowser",get:function(){var e=this;return(0,o.some)(["_phantom","Buffer","callPhantom","domAutomation","domAutomationController","emit","spawn","webdriver"],function(t){return!!e.client[t]})}},{key:"plugins",get:function(){return(0,o.map)(this.client.navigator.plugins,"name")}},{key:"hasImages",get:function(){var e=this.client.document.getElementById("clp_image");return!!e&&e.width>0}},{key:"hasFlash",get:function(){var e=this.client,t=e.ActiveXObject,i=e.navigator,n=!1;try{n=new t("ShockwaveFlash.ShockwaveFlash")}catch(e){n=i.mimeTypes["application/x-shockwave-flash"]&&i.mimeTypes["application/x-shockwave-flash"].enabledPlugin}return!!n}},{key:"platform",get:function(){var e=(0,o.get)(this,"client.navigator.platform"),t=(0,o.includes)(["iPhone","iPod","iPad","iPhone Simulator","iPod Simulator","iPad Simulator"],e),i=(0,o.includes)(["Android"],e);return t?"Web:iOS":i?"Web:Android":"Web"}},{key:"toJSON",value:function(){var e=this.appVersion,t=this.colorDepth,i=this.cookiesEnabled,n=this.hasFlash,s=this.hasImages,o=this.hasJavascript,r=this.language,a=this.languages,l=this.isOnline,c=this.platform,u=this.plugins,h=this.resolution,d=this.screenHeight,p=this.screenWidth,g=this.createdAt;return{app_version:e,color_depth:t,cookies_enabled:i,flash_enabled:n,images_enabled:s,javascript_enabled:o,language:r,languages:a,online:l,platform:c,plugins:u,resolution:h,screen_height:d,screen_width:p,time_zone_offset:this.timezone,timestamp:g,user_agent:this.userAgent}}}])&&u(e.prototype,t),i&&u(e,i),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,i}();const p=d;var g=i(30351),f=i(8579);function m(e){return m="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},m(e)}function _(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,v(n.key),n)}}function v(e){var t=function(e,t){if("object"!=m(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=m(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==m(t)?t:t+""}function b(e,t,i){return t=w(t),function(e,t){if(t&&("object"==m(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,y()?Reflect.construct(t,i||[],w(e).constructor):t.apply(e,i))}function y(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(y=function(){return!!e})()}
1function w(e){return w=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},w(e)}function C(e,t){return C=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},C(e,t)}var x=["follow","impression","like","reblog","share","unfollow","unlike","supply_serve","supply_rotate","supply_unload","supply_viewable","NotificationBlogSwitch","NotificationClick","NotificationFollowClick","NotificationRebloggerClick","NotificationPostPreviewClick","NotificationReplyClick","NotificationFlagIconClick","ClickLogin","ClickSignup","ActivityClick","AccountClick","SearchPopover","SearchExecute","SignUpCTAClickRegister","NotesInteractionOpen","Messaging:inbox:open","Messaging:inbox:closed","Messaging:conversation:started","Messaging:conversation:deleted","Messaging:conversation:open","Messaging:conversation:closed","Messaging:conversation:follow","Messaging:conversation:windows:loaded","Messaging:conversation:minimized","Messaging:conversation:unminimized","Messaging:conversation:spam:intent","Messaging:conversation:spam:success","Messaging:conversation:spam:fail","Messaging:messaging-image-upload:add","Messaging:messaging-image-upload:dismiss","Messaging:messaging-image-upload:edit","Messaging:messaging-image-upload:intent","Messaging:messaging-gif:add","Messaging:messaging-gif:dismiss","Messaging:messaging-gif:edit","Messaging:messaging-gif:intent","Messaging:post-chrome:add","Messaging:post-chrome:dismiss","Messaging:post-chrome:edit","Messaging:post-chrome:intent","Messaging:message:sent","Messaging:message:failure","Messaging:block","Messaging:notification:display","Messaging:notification:permission:granted","Messaging:notification:permission:denied","Messaging:peepr:open","Messaging:conversation-permalink:open","Messaging:new:inbox:empty:new-message:button:click","Messaging:old:inbox:empty:new-message:button:click","customTheme:enabled","customTheme:disabled","cname:enabled","cname:disabled","Transparency:report","blocks:block_added","blocks:ip_block_added","blocks:blocklist:more_loaded","blocks:blocklist:opened","blocks:block_added:block_already_exists","blocks:block_removed","abuseform:open","abuseform:close","abuseform:submitted","abuseform:stepviewed","abuseform:contentpreview:close","helpform:closed","helpform:opened:withButton","helpform:close","helpform:open","helpform:opened:withLink","helpform:navigateBackToHelp","loginregister:captchaShown","loginregister:flowComplete","loginregister:beginFlow","peepr:open","peepr:postsAndBlogFetch","peepr:like_update","peepr:close","peepr:follow_update","peepr:timeline:posts-fetched","peepr:log:close","peepr:log:paginate","peepr:log:peepr_reblog","peepr:log:peepr_reblog_success","peepr:log:peepr_like_update","peepr:log:peepr_follow","peepr:log:reload","peepr:log:load","peepr:log:ajax-error","peepr:timeline:posts-fetched","MagicLink:LoginSuccess","MagicLink:Sent","MagicLink:UsePasswordButtonPressed","MagicLink:BackButtonPressed","safeMode:SafeModeToggled","safeMode:BlogFlaggedAdultByUser","safeMode:FilteringSettingLinkClicked","safeMode:SafeModeBlogPageShown","safeMode:NsfwPostPreview","safeMode:PFNSFW","safeMode:SurveyOptionSelected","safeMode:FilteringSettingLinkClicked","safeMode:NsfwDocLinkClicked","safeMode:SafeModeSafeSearchToggleClicked","ReviewExplicitClick","InfoExplicitClick","InfoExplicitReblogClick","RequestReviewExplicit","CancelReviewExplicit","LearnMoreExplicit","ScreenView","EditPost","Teads"],k=function(e){function t(e,i){var n,s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var o=(n=b(this,t,[e,i,s])).data,a=o.extraData,l=o.eventDetails,c=o.eventString,u=o.ts,h=o._experiments,d=o._clientOverrides;n.experiments=h||{},n.overrides=d||{},delete n.data._experiments,delete n.data._clientOverrides;var g=new p(window,n.overrides);return n.json.event_data.kraken={event_name:c||n.name,client_session_id:g.sessionID||"",page:g.screenType||"Unknown",section:g.section||"",client_timestamp:u||Date.now(),event_details:r().assign({},a,l,r().omit(n.data,"pt","extraData","eventDetails")),experiments:n.experiments},n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&C(e,t)}(t,e),i=t,n&&_(i.prototype,n),s&&_(i,s),Object.defineProperty(i,"prototype",{writable:!1}),i;var i,n,s}(i.n(f)());const S=k;function T(){var e=new p(window,arguments.length>0&&void 0!==arguments[0]?arguments[0]:{});return{language:e.language,manufacturer:e.vendor,os_version:e.osVersion,platform:e.platform,build_version:"1787228234-5e10ed8",carrier:"",connection:"",model:""}}var E=new g.SK({EventClass:S,payload_formatter:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];if(!e.length)return{};var t=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return r().groupBy(e,function(e){return r().has(e,g.I3)&&!!e.pt})}(e),i=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=(0,g.Ot)(e),i=function(e){var t=e.kraken;return delete t.pt,t},n=function(e){return e.data=e.data||e.kraken.event_details,delete e.data.pt,delete e.kraken,e};return t.map(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.pt,s=e.events;return{pt:t,krakenEvents:s.map(i),events:s.map(n)}})}(t.true),n=function(){return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[]).map(function(e){return e.event_data.kraken})}(t.false);return r().assign({krakenClientDetails:T()},i.length&&{trackers:i},n.length&&{krakenEvents:n})},event_filter:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.data,i=e.name;return!!t.pt||r().includes(x,i)},endpoint:g.T9});const P=E;var I=i(44890),F=i.n(I),A=s().extend({logKey:"kraken",logSpots:[],events:function(){return F().bool("kraken_web_logging_library")?{"Kraken:*":"log"}:{}},log:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};P.log("kraken").trigger(e,t),(t.is_ad||"supply_unload"===e)&&P.flush()}});const M=A},71742(e,t,i){"use strict";var n=i(55679),s=i(21391),o=i(17145),r=i(28017),a=(i(95349),i(56604)),l=i(51954),c=["selector","container","rootEl","view","viewOptions","autoAppend"],u=o.extend({name:null,rootEl:null,selector:null,view:null,viewOptions:{},autoAppend:!1,defaults:{},constructor:function(e){e||(e={}),this.cid=n.uniqueId("component"),n.extend(this,n.pick(e,c));var t=n.result(this,"defaults"),i=n.extend({},t,n.pick(e,n.keys(t)));this.attributes={},this.set(i,{silent:!0}),this.changed={},(this.autoAppend||this.selector)&&this.setContainer(),this.selector||(this.selector=this.defaultSelector);var o=n.isFunction(this.viewOptions)?this.viewOptions.call(this.viewOptions,this):this.viewOptions;this.view&&this.view.prototype&&this.view.prototype instanceof s.View?this.view=new this.view(o):n.isFunction(this.view)&&(this.view=this.view.call(this,o)),this.initialize.apply(this,arguments),this.autoAppend&&this.append()},initialize:n.noop,setContainer:function(){return this.selector||(this.selector=this.defaultSelector),this.container=this.selector,this.container},getOwnData:function(){return this.data},remove:function(){n.result(this,"beforeRemove"),this.view&&n.isFunction(this.view.remove)&&this.view.remove();return n.each(["container","view","defaults","attributes"],n.bind(function(e){this[e]&&delete this[e]},this)),this.stopListening(),this.trigger("remove"),this},append:function(){return this.view&&n.isFunction(this.view.render)&&(this.container?this.container.appendChild(this.view.render().el):this.view.render()),this.trigger("append"),this}});Object.defineProperties(u.prototype,{defaultSelector:{get:function(){return"[prima-component="+this.name+"]"},set:function(){0}},container:{get:function(){return this._container},set:function(e){var t=a(e,this.rootEl);this._container=t}},data:{get:function(){return this._data||(this._data=r.get("Components/"+this.name)),this._data},set:function(e){this._data=e}}}),l.mixin.applyTo(u.prototype),e.exports=u},71827(e,t,i){var n=i(55679),s=i(21391).Model.extend;function o(e){var t=s.apply(this,arguments);return n.has(e,"mixins")&&e.mixins.forEach(function(e){e.applyTo(t.prototype)}),t}e.exports.applyTo=function(e){e.extend=o}},72042(e,t,i){e.exports={html:i(8468)}},72178(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(71092),r=i(27496),a=i(37552),l=i(44890),c=i(64491),u=i(38578),h=i(93146),d=i(54125),p=i(41956),g=i(65707),f=o.extend({className:"mobile-header",mixins:[c,u],template:h,defaults:{logged_in:!1},initialize:function(e){e=s.extend({},e),s.extend(this.attributes,s.pick(e,s.keys(this.defaults))),this.subViews.logoTitle=new d(e),this.subViews.navMenu=new p(e),l.bool("mobile_web_sticky_header")&&this.setSticky(),this.subViews.search=new g(e)},render:function(){return this.$el.html(this.template()),this.attachSubViews(),this},setSticky:function(){n("body").addClass("sticky-header"),this.lastPosition=a.rect().windowScrollTop,this.listenTo(r,"DOMEventor:flatscroll",this.get
1ScrollDirection)},getScrollDirection:function(e){e.windowScrollTop>45?s.delay(s.bind(function(){this.$el.addClass("sticky")},this),500):this.$el.removeClass("sticky"),this.lastPosition<e.windowScrollTop&&e.windowScrollTop>45?this.$el.addClass("hide-nav"):this.$el.removeClass("hide-nav"),this.lastPosition=e.windowScrollTop}});e.exports=f},72202(e,t,i){"use strict";var n=i(41257);n({"Tumblr.Prima.Upload":i(42714),"Tumblr.Prima.Ligature":i(38333),"Tumblr.Events":i(27496),"Tumblr.Prima.Events":i(27496),"Tumblr.Prima.Dialog":i(49779),"Tumblr.Dialog":i(49779),"Tumblr.PostMessageChannel":i(89529),"Tumblr.Prima.DOMEventor":i(37552),"Tumblr.Prima.gutterMediaManager":i(90375),"Tumblr.Prima.Vendor.when":i(21189),"Tumblr.Prima.Vendor.sequence":i(2616),"Tumblr.log_lady":i(2468),"Tumblr.Prima.logLady":i(2468),"Tumblr.Prima.Models.Post":i(10768),"Tumblr.Prima.Models.Tumblelog":i(80867),"Tumblr.Prima.CrtPlayer":i(67421),"Tumblr.Prima.CrtControl":i(59386),"Tumblr.Prima.BlogCard":i(7784),"Tumblr.Prima.Url":i(95870),"Tumblr.Prima.ToolTip":i(88206),"Tumblr.Prima.SharePopover":i(16998),"Tumblr.Prima.Messaging.SharePost":i(59492),"Tumblr.Prima.utils.caniuse":i(7419),"Tumblr.Prima.ConfettiView":i(74988),"Tumblr.Prima.FlatSelect":i(96399),"Tumblr.Prima.Mixins.loggingData":i(97030),"Tumblr.Prima.Mixins.withFormKeyTrue":i(13752),"Tumblr.Prima.Scrollbar":i(64147),"Tumblr.Prima.MessageControlsPopover":i(38037),"Tumblr.Prima.Block":i(18356),"Tumblr.Prima.SafeMode":i(91007),"Tumblr.Prima.PeeprSearch":i(8414),"Tumblr.Prima.MessagingPopover":i(95141),"Tumblr.Prima.currentUser":i(6479),"Tumblr.Prima.AdsPaginationHelper":i(79281),"Tumblr.Prima.SortableView":i(92483),"Tumblr.Prima.getLoggingPayloadFromNote":i(44861),"Tumblr.Prima.Snowman":i(91852),"Tumblr.Prima.postActivityLoader":i(8901),"Tumblr.Prima.KnightRiderLoader":i(78421),"Tumblr.Prima.Lib.hosts":i(22538),"Tumblr.Prima.LivePhotos":i(48256),"Tumblr.Prima.Carousel":i(10737),"Tumblr.Prima.ExpandableTags":i(51347),"Tumblr.Prima.Translate":i(81515),"Tumblr.Prima.NativeAudio":i(21343),"Tumblr.Prima.CTAButton":i(52394),"Tumblr.Prima.Viewability":i(64423),"Tumblr.Prima.ViewabilityTracker":i(17080),"Tumblr.Prima.StatusIndicator":i(80158),"Tumblr.Prima.Utils.CanvasTools":i(57505),"Tumblr.Prima.Utils.Cookie":i(80965)}),e.exports=n},72578(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(81515),r=i(50283),a=i(98237),l=i(9380),c=i(69464),u=i(96152),h=i(77652),d=r.extend({className:"inbox-compose",template:h,defaults:{isShowFavorites:!0,isLoading:!1,showLoadingAfterMs:250,hasEditorFocus:!1},events:{"input [data-js-textinput]":"_onTextInputChange","focus [data-js-textinput]":"_onTextInputFocus","blur [data-js-textinput]":"_onTextInputBlur"},mixins:[a],subviews:{favoritesView:{constructor:c,options:function(e){return{showMessageOnEmpty:!1,eventBus:e.eventBus,collection:e.favoritesCollection,title:e.isNewEmptyInboxEnabled?o("Recently Followed"):o("Favorites"),context:"inbox:favorites",isNewEmptyInboxEnabled:e.isNewEmptyInboxEnabled}}},searchResultView:{constructor:c,options:function(e){return{eventBus:e.eventBus,collection:e.collection,context:"inbox:typeahead"}}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","favoritesCollection","currentBlogModel","keyboardManager","isNewEmptyInboxEnabled")),this.collection=new l,this._debouncedSearch=n.bind(n.debounce(this._search,250),this)},afterRenderSubviews:function(){this.loader=new u({$container:this.$el,type:"bar",classModifiers:"top",loading:!1}),this.listenTo(this,"change:isShowFavorites",this._onChangeIsShowFavorites),this.listenTo(this,"change:isLoading",this._onChangeIsLoading),this.listenTo(this,"change:hasEditorFocus",this._onChangeHasEditorFocus),this._onChangeIsShowFavorites(this,this.get("isShowFavorites"))},_setKeyboardState:function(){this.keyboardManager.remove("inbox:compose"),this.get("hasEditorFocus")&&(this.get("isShowFavorites")?this.keyboardManager.add("inbox:compose:favorites",this.favoritesView):this.keyboardManager.add("inbox:compose:results",this.searchResultView))},_onChangeHasEditorFocus:function(e,t){this._setKeyboardState()},fetchResults:function(e){var t=this.currentBlogModel.getChannel().get("uuid");return this.set("isLoading",!0),this.collection.fetchByQuery(e,t).always(n.bind(function(){this.rendered&&this.set({isShowFavorites:!1,isLoading:!1})},this))},clear:function(){this.js$("textinput").val("")},focus:function(){this.js$("textinput").focus()},blur:function(){this.js$("textinput").blur()},beforeRemove:function(){this.keyboardManager.remove("inbox:compose")},_search:function(e){n.isEmpty(e)?this.set("isShowFavorites",!0):this.fetchResults(e)},_onTextInputChange:function(e){this._debouncedSearch(s(e.target).val())},_onTextInputBlur:function(e){this.set("hasEditorFocus",!1)},_onTextInputFocus:function(e){this.set("hasEditorFocus",!0)},_onChangeIsShowFavorites:function(e,t){this.favoritesView.toggle(t),this.searchResultView.toggle(!t),this._setKeyboardState()},_onChangeIsLoading:function(e,t){if(this._loaderTimeout&&(clearTimeout(this._loaderTimeout),this._loaderTimeout=null),!t)return this.loader.set("loading",!1);this._loaderTimeout=setTimeout(n.bind(function(){this.loader.set("loading",!0)},this),this.get("showLoadingAfterMs"))}});e.exports=d},72607(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape;\nwith (obj) {\n__p += \'<nav class="nav-site-sections"><a href="/settings/password" class="nav-item"><span class="nav-text">\' +\n__e( __(\'Change Password\') ) +\n\'</span></a><a href="/settings/tfa" class="nav-item"><span class="nav-text">\' +\n__e( __(\'Two Factor Authentication\') ) +\n\'</span></a><a href="/help" class="nav-item"><span class="nav-text">\' +\n__e( __(\'Help\') ) +\n\'</span></a><a href="/settings/account" class="nav-item" target="_blank"><span class="nav-text desktop-view">\' +\n__e( __(\'Account\') ) +\n\'</span></a><a href="/settings/notifications" class="nav-item" target="_blank"><span class="nav-text desktop-view">\' +\n__e( __(\'Notifications\') ) +\n\'</span></a><a href="/settings/apps" class="nav-item" target="_blank"><span class="nav-text desktop-view">\' +\n__e( __(\'Apps\') ) +\n\'</span></a></nav>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},72627(e,t,i){"use strict";var n=i(97583).extend({logKey:"roadblock",events:{"roadblock:*":"log"}});e.exports=n},72681(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(98237),r=i(99467),a=s.extend({className:"conversation-header",template:r,mixins:[o],defaults:{separator:"+"},attributes:{"data-js-theme-background-color-or-image-class":!0,"data-js-theme-accent-color-on-background":!0},events:{"click [data-js-close]":"_onClickCloseButton","click [data-js-more-actions]":"_onClickMoreActions","click [data-js-minimize]":"_onClickMinimizeButton"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","participants","user","channels"))},getTemplateData:function(){var e;return e=this.channels.length>1?this.participants.toJSON():n.invoke(this.participants.getWithout(this.channels.pluck("uuid")),"toJSON"),{participants:e=n.filter(e,function(e){return!n.isEmpty(n.get(e,"name"))}),separator:this.get("separator")}},_onClickCloseButton:function(e){this.trigger("closeClick"),e.preventDefault()},_onClickMoreActions:function(e){var t=e.currentTarget;this.trigger("moreActionsClick",t),e.preventDefault()},_onClickMinimizeButton:function(e){this.trigger("minimizeClick"),e.preventDefault()}});e.exports=a},72790(e,t,i){"use strict";var n=i(97583).extend({logKey:"postchrome_interactions",logOptions:{init_event:!1},events:{"postchrome-interactions:*":"handleEvent"},logEnv:{location:document.location.pathname},handleEvent:function(e,t){this.log(e,t)}});e.exports=n},73001(e,t,i){"use strict";var n=i(81515),s=i(19698),o=i(49779),r=s.extend({getName:function(){return"copy-permalink"},getLabel:function(){return n("Copy Link")},getType:function(){return s.TYPE_CALLBACK},getButtonHref:function(){return this.getPostUrl()},onClickHandler:function(e){e.preventDefault(),this._copyText(this.getPostUrl(),e.currentTarget)?o.alert(n("It's copied! Paste it wherever!")):o.alert(n("Failed to copy permalink."))},_copyText:function(e,t){var i=document.createElement("input");i.value=e,t.appendChild(i),i.focus(),i.select();var n=!1;try{n=document.execCommand("copy")}catch(e){}return t.removeChild(i),n}});e.exports=r},73026(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(21189),r=i(18356),a=i(71092),l=i(27496),c=a.extend({events:{"click [data-survey-submit]":"onSubmitClick","click [data-survey-dismiss]":"onDismissClick"},initialize:function(e){this.abuseform=e.abuseform,this.savedFormState={},this.recaptcha=e.recaptcha,this.listenTo(l,"abuseforms:formview:savestate",this.saveFormState),this.listenTo(l,"abuseforms:formview:restorestate",this.restoreFormState)},onSubmitClick:function(e){e.preventDefault(),this.trimFormFields(),this.abuseform.set("loading",!0),this.createTicket()},createTicket:function(){var e=[];
1if(e.push(n.ajax({url:"/abuse/ticket/new",type:"POST",contentType:!1,processData:!1,data:this.prepareData(),withFormKey:!0})),this.abuseform.get("blockFlagSet")){var t=this.abuseform.sender||this.abuseform.tumblelog,i=this.abuseform.tumblelog.id;e.push("Anonymous"===t.id?r.block({blockedPost:this.abuseform.posts[0].id,currentTumblelog:i}):t.block())}o.all(e).done(s.bind(this.onSubmitSuccess,this),s.bind(this.onSubmitError,this))},prepareData:function(){var e=this.$("[data-abuse-form]");return new FormData(e[0]||{})},trimFormFields:function(){this.$("[data-abuse-form]").find("input[data-validate-input], textarea[data-validate-input]").each(function(){var e=n(this),t=e.val();if("string"==typeof t){var i=t.trim();t!==i&&e.val(i)}})},saveFormState:function(e){this.$("[data-abuse-form]").length&&(this.savedFormState[e]=this.$("[data-abuse-form]").serializeArray())},restoreFormState:function(e){if(this.savedFormState[e]){var t=this.savedFormState[e];s.each(t,function(e){e.value&&!s.isEmpty(e.value)&&(this.$('input[name="'+e.name+'"]').length?this.$('input[name="'+e.name+'"]'):this.$('textarea[name="'+e.name+'"]')).val(e.value).trigger("blur")},this),l.trigger("drawerform:validation:trigger")}},onSubmitSuccess:function(){this.abuseform.set("loading",!1),this.abuseform.hideFlaggedContent(),this.abuseform.logSubmission(),this.abuseform.displaySuccessMessage()},onSubmitError:function(e){this.abuseform.set("loading",!1);var t=n.parseJSON(e.responseText||{}),i=t.response&&t.response.errors&&t.response.errors.errors||"";this.abuseform.displayErrorMessage(i)},onDismissClick:function(){this.abuseform.get("mobileMode")?void 0!==window.history&&window.history.length>2?window.history.go(-1):window.location="":(l.trigger("abuseform:close"),l.trigger("Kraken:abuseform:close"))}});e.exports=c},73131(e,t,i){"use strict";var n=i(74692),s=i(45668),o=s.extend({player:{},$post:{},initialize:function(e,t){this.player=e,this.post=this.player.$el.closest(".post")[0],this.$post=n(this.post),this._data={},this._data.embedID=t,this._data.service="tumblr",this._data.postID=this.$post.data("post-id"),this.connected=!0,this._setupWatcher(),this.listenTo(this.player,"change:paused",this.__onStateChange),this.listenTo(this.player,"change:autoplay",this.__onStateChange)},play:function(){var e=this.getState();"autoplaying"===e?this.player.restart():"playing"!==e&&this.player.play({onDock:!0})},pause:function(){"paused"!==this.getState()&&this.player.pause()},getState:function(){var e=this.player.get("paused"),t=this.player.get("autoplay");return e?"paused":t?"autoplaying":"playing"},__onStateChange:function(){var e=this.getState();s.prototype.__onStateChange.call(this,e)}});e.exports=o},73142(e,t,i){var n=i(27496),s=new(i(98052))({EventClass:i(10708),event_payload_name:"events",event_filter:i(1991),endpoint:"/svc/log/lady"});n.on("Capture:push",function(e,t,i){s.log(e,{init_event:!1}).trigger(t,i)}),e.exports=s},73419(e,t,i){var n=i(24655);e.exports=function(){var e=n("JSON"),t={},i=document.getElementById("bootloader");if(i){try{t=e.parse(i.getAttribute("data-bootstrap"))}catch(e){0}i.parentNode.removeChild(i)}return t}},73488(e,t,i){"use strict";var n=i(74692),s=i(27496),o=i(44384).extend({events:{click:"openReblogGraph"},openReblogGraph:function(e){var t=n(e.target).closest(".reblog-graph-control");s.trigger("useraction:click:reblog-graph",{model:this.model,rootPostTs:t.data("root-post-ts"),rootPostTumblelogKey:t.data("root-post-tumblelog-key"),target:t})}});e.exports=o},73549(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(27496),r=i(98237),a=i(23463),l=i(66311),c=i(33389),u=s.extend({className:"search-input",template:c,mixins:[r],$$cacheKeys:{"blog-search-input":".blog-search-input"},initialize:function(){this.autocompletePopover=null,this.bindEvents(),this.blogSearchAutocompleteModel=new l({blogname:this.model.get("blogname")})},afterRender:function(){this.blogSearchAutocompleteHelper=new a({model:this.blogSearchAutocompleteModel,el:this.$$(".blog-search-input")})},events:{"focus .blog-search-input":"inputFocusHandler","keyup .blog-search-input":"inputKeyUpHandler","blur .blog-search-input":"inputBlurHandler"},bindEvents:function(){this.listenTo(this.model,"change:term",this.onTermChange),this.listenTo(this.model,"reset",this.onModelReset)},inputKeyUpHandler:function(){this.model.set("unsetTerm",this.getTerm()),this.blogSearchAutocompleteModel.set("matchTerm",this.getTerm())},focusInput:function(){this.$$(".blog-search-input").focus(),this.blogSearchAutocompleteHelper.showPopover()},getTerm:function(){return n.trim(this.$$(".blog-search-input").val())},setTerm:function(e){this.$$(".blog-search-input").val(e).blur()},onTermChange:function(e,t){this.setTerm(t)},onModelReset:function(){this.setTerm("")},inputFocusHandler:function(){o.trigger("indashblog:keycommands:suspend",!0)},inputBlurHandler:function(){o.trigger("indashblog:keycommands:resume")}});e.exports=u},73783(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div data-subview=\"senderView\"></div><div data-subview=\"composeToggleView\"></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},73885(e,t,i){"use strict";var n=i(55679),s=i(21189),o=new(i(28724))({defaults:{whenEvent:function(e,t){return 1===arguments.length&&(t=e,e=this),s.promise(n.bind(function(i,n){this.listenToOnce(e,t,function(){i.call(null,arguments)})},this))}}});e.exports=o},73953(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, \'\') }\nwith (obj) {\n__p += \'<div class="form-container form"><div class="form-header with-border"><h1 class="form-heading">\' +\n((__t = ( __(\'Help me, Tumblr\') )) == null ? \'\' : __t) +\n\'</h1><div class="form-description"><p> \' +\n((__t = ( __(\'You got it. Describe the problem you\\\'re having as best you can, and a member of our Support team will be in touch with you as soon as possible.\') )) == null ? \'\' : __t) +\n\' </p><br><p> \' +\n((__t = ( __(\'%1$sNote:%2$s This form is for technical issues and general weirdness. If you\\\'re reporting a violation of our User Guidelines, use %3$sthis other form%4$s instead.\', \'<strong>\', \'</strong>\', \'<a href="/abuse">\', \'</a>\') )) == null ? \'\' : __t) +\n\' </p></div></div><form action="/support/ticket/new" src="" method="POST" enctype="multipart/form-data" target="help_form_target"><div id="help_form_target" name="help_form_target" style="width:0;height:0;border:none;margin:0;padding:0;"></div><input type="hidden" name="jsonp" value="help_modal.evaluate_response"> <input type="hidden" name="support_type" id="support_form_support_type" value="support"> <input type="hidden" name="form_key" id="support_form_form_key" value="\' +\n((__t = ( formKey )) == null ? \'\' : __t) +\n\'"> <input type="hidden" name="source" value="support_form"> \';\n if (languageNotice) { ;\n__p += \' <div class="form-group"><div class="group-row"><span class="language-notice">\' +\n((__t = ( __(\'Just so you know, we\\\'re not yet able to address queries that are written in [language]. You can still use this form to contact our Support team, but you\\\'ll need to fill it out in English. Sorry about that, and thanks for your patience.\') )) == null ? \'\' : __t) +\n\'</span></div></div> \';\n } ;\n__p += \' <div class="form-group"><div class="group-label"><h3 class="settings_subheading">\' +\n((__t = ( __(\'Choose a category for support:\') )) == null ? \'\' : __t) +\n\'</h3></div><div class="group-content"><div class="flat_select attached"> \';\n if (preSelectedCategory) { ;\n__p += \' <select aria-label="\' +\n__e( __(\'Select a category for the problem you are experiencing\') ) +\n\'" name="subject" id="category" class="category" data-validate-input="dropdown"><option value="\' +\n((__t = ( __(\'Category\') )) == null ? \'\' : __t) +\n\'" disabled="disabled">\' +\n((__t = ( __(\'Category\') )) == null ? \'\' : __t) +\n\'</option> \';\n _.each(categories, function (category, name) { ;\n__p += \' \';\n if (name === preSelectedCategory) { ;\n__p += \' <option value="\' +\n((__t = ( name )) == null ? \'\' : __t) +\n\'" selected="selected">\' +\n((__t = ( __(category) )) == null ? \'\' : __t) +\n\'</option> \';\n } else { ;\n__p += \' <option value="\' +\n((__t = ( name )) == null ? \'\' : __t) +\n\'">\' +\n((__t = ( __(category) )) == null ? \'\' : __t) +\n\'</option> \';\n } ;\n__p += \' \';\n }); ;\n__p += \' </select> <label aria-hidden="true" for="category" class="current_selection">\' +\n((__t = ( categories[preSelectedCategory] )) == null ? \'\' : __t) +\n\'</label> \';\n } else { ;\n__p += \' <select aria-label="\' +\n__e( __(\'Select a category for the problem you are experiencing\') ) +\n\'" name="subject" id="category" class="category" data-validate-input="dropdown" required><option value="\' +\n((__t = ( __(\'Category\') )) == null ? \'\' : __t) +\n\'" disabled="disabled" selected="selected">\' +\n((__t = ( __(\'Category\') )) == null ? \'\' : __t) +\n\'</option> \';\n _.each(categories, function (category, name) { ;\n__p += \' <option value="\' +\n((__t = ( name )) == null ? \'\' : __t) +\n\'">\' +\n((__t = ( __(category) )) == null ? \'\' : __t) +\n\'</option> \';\n }); ;\n__p += \' </select> <label aria-hidden="true" for="category" class="current_selection">\' +\n((__t = ( __(\'Category\') )) == null ? \'\' : __t) +\n\'</label> \';\n } ;\n__p += \' <i aria-hidden="true" class="icon"></i></div><textarea aria-label="\' +\n__e( __(\'Please provide some information about the problem\') ) +\n\'" class="body" data-validate-input="text" required name="body" cols="30" rows="5" placeholder="\' +\n((__t = ( __(\'The more details, the better\') )) == null ? \'\' : __t) +\n\'"></textarea><div id="appeals-link" class="form-link"><a href="" target="_blank"> \' +\n((__t = ( __(\'More about appeals\') )) == null ? \'\' : __t) +\n\' </a></div></div></div><div class="form-group hidden not-shown" id="account-access-help-type"><div class="group-label"><h3 class="settings_subheading">\' +\n__e( __(\'How can we help?\') ) +\n\'</h3></div><div class="group-content"><div class="flat_select"><select aria-label="\' +\n__e( __(\'How can we help?\') ) +\n\'" name="account_help_type" id="account-help-type" class="account-help-type" data-validate-input="dropdown"><option value="" disabled="disabled" selected="selected">\' +\n__e( __(\'Select an option\') ) +\n\'</option><option value="account_reason_pas">\' +\n__e( __(\'I can\\\'t get password reset emails\') ) +\n\'</option><option value="account_reason_tfa">\' +\n__e( __(\'I can\\\'t get two-factor authentication codes\') ) +\n\'</option><option value="account_reason_regr">\' +\n__e( __(\'I have deleted my account or blog by accident\') ) +\n\'</option><option value="account_reason_hacked">\' +\n__e( __(\'My account was hacked\') ) +\n\'</option><option value="account_reason_email_forgot">\' +\n__e( __(\'I don\\\'t remember the account\\\'s email address\') ) +\n\'</option><option value="account_reason_email_no_access">\' +\n__e( __(\'I know the account\\\'s email address, but can\\\'t access that email\') ) +\n\'</option></select> <label aria-hidden="true" for="account-help-type" class="current_selection">\' +\n__e( __(\'Select an option\') ) +\n\'</label> <i aria-hidden="true" class="icon"></i></div></div></div><div class="form-group hidden not-shown" id="account-access-action"><div class="group-label"><h3 class="settings_subheading">\' +\n__e( __(\'Do you wish to regain access or delete the account?\') ) +\n\'</h3></div><div class="group-content"><div class="flat_select"><select aria-label="\' +\n__e( __(\'Do you wish to regain access or delete the account?\') ) +\n\'" name="account_access_action" id="account-access-action-select" class="account-access-action" data-validate-input="dropdown"><option value="" disabled="disabled" selected="selected">\' +\n__e( __(\'Select an option\') ) +\n\'</option><option value="regain_access_to_account">\' +\n__e( __(\'Regain access to my account\') ) +\n\'</option><option value="delete_account">\' +\n__e( __(\'Delete my account\') ) +\n\'</option></select> <label aria-hidden="true" for="account-access-action" class="current_selection">\' +\n__e( __(\'Select an option\') ) +\n\'</label> <i aria-hidden="true" class="icon"></i></div></div></div> \';\n if (supportsFileChooser && categoryAllowsFiles) { ;\n__p += \' <div class="form-group" id="support-form-filepicker"><div class="group-label"><h3 class="settings_subheading">\' +\n((__t = ( __(\'Attachment\') )) == null ? \'\' : __t) +\n\'</h3><div class="sub-label">\' +\n((__t = ( __(\'Optional\') )) == null ? \'\' : __t) +\n\'</div></div><div class="group-content"><div class="image-upload-input"><input aria-label="\' +\n__e( __(\'Please upload any screenshots that might be relevant\') ) +\n\'" id="image-upload" class="image-upload" type="file" name="attachments[]" accept="image/*"> <label aria-hidden="true" class="image-upload" for="image-upload"></label></div><div class="image-upload-preview"><img title="\' +\n__e( __(\'Uploaded image\') ) +\n\'" src=""> <button aria-label="\' +\n__e( __(\'Remove image\') ) +\n\'" class="btn_remove btn-remove-uploaded" data-tooltip="\' +\n((__t = ( __(\'Remove image\') )) == null ? \'\' : __t) +\n\'"></button></div></div></div> \';\n } ;\n__p += \' <div class="form-group"><div class="group-label"><h3 class="settings_subheading">\' +\n((__t = ( __(\'Relevant blog\') )) == null ? \'\' : __t) +\n\'</h3><div id="blog_optional_indicator" class="sub-label">\' +\n__e( __(\'Optional\') ) +\n\'</div><div class="sub-label">\' +\n__e( __(\'Let us know which blog you need help with.\') ) +\n\'</div></div><div class="group-content" id="support_form_blogs_wrapper"> \';\n if ((tumblelogs && _.size(tumblelogs) >= 1) || (suspendedTumblelogs && _.size(suspendedTumblelogs) >= 1)) { ;\n__p += \' <div class="flat_select"><select aria-label="\' +\n__e( __(\'Please select the blog that has the problem, if applicable\') ) +\n\'" name="support_form_blog" id="tumblelog" class="tumblelog" data-validate-input="dropdown"><option value="" selected="selected">\' +\n((__t = ( __(\'None selected\') )) == null ? \'\' : __t) +\n\'</option> \';\n_.each(tumblelogs, function (tumblelog) { ;\n__p += \' <option class="notsuspended" value="\' +\n__e( tumblelog.name ) +\n\'">\' +\n__e( tumblelog.name ) +\n\'</option> \';\n }); ;\n__p += \' \';\n_.each(suspendedTumblelogs, function (tumblelog) { ;\n__p += \' <option class="suspended" value="\' +\n__e( tumblelog.name ) +\n\'">\' +\n__e( tumblelog.name ) +\n\'</option> \';\n }); ;\n__p += \' </select> <label aria-hidden="true" for="tumblelog" class="current_selection">\' +\n((__t = ( __(\'None selected\') )) == null ? \'\' : __t) +\n\'</label> <i aria-hidden="true" class="icon"></i></div> \';\n } else { ;\n__p += \' <input aria-label="\' +\n__e( __(\'Please let us know which blog has the problem, if applicable\') ) +\n\'" id="tumblelog" class="text_field tumblelog" data-validate-input="blog" name="support_form_blog" placeholder="\' +\n__e( __(\'Blog name\') ) +\n\'"> \';\n } ;\n__p += \' </div></div><div class="form-group"><div class="group-label"><h3 class="settings_subheading">\' +\n__e( __(\'Account email\') ) +\n\'</h3><div class="sub-label">\' +\n((__t = ( __(\'You can change this email address in your <a href="">account settings</a>.\') )) == null ? \'\' : __t) +\n\'</div></div><div class="group-content"><input aria-label="\' +\n__e( __(\'Please provide the email address where we should contact you\') ) +\n\'" class="text_field" data-validate-input="email" required name="user_email" placeholder="\' +\n((__t = ( __(\'Email address\') )) == null ? \'\' : __t) +\n\'" value="\' +\n((__t = ( email )) == null ? \'\' : __t) +\n\'" \' +\n((__t = ( email ? \'readonly\' : \'\' )) == null ? \'\' : __t) +\n\' ></div></div><div class="form-group hidden not-shown" id="account-access-email-confirmed" style="padding-top: 0; margin-top: -14px;"><div class="group-label"><h3 class="settings_subheading">&nbsp;</h3></div><div class="group-content"><div class="checkbox"><label class="binary_switch"><input type="c
1heckbox" name="account_email_confirmed" id="account-email-confirmed-checkbox" class="account-email-confirmed-checkbox" data-validate-input="checkbox"> <span class="binary_switch_track"></span> <span class="binary_switch_button"></span></label> <label for="account-email-confirmed-checkbox">\' +\n__e( __(\'This is the email registered for the account in question\') ) +\n\'</label></div></div></div> \' +\n((__t = ( recaptcha )) == null ? \'\' : __t) +\n\' <div class="form-group"><button class="chrome big blue right help-form-next" disabled="disabled"><span class="label">\' +\n((__t = ( __(\'Next\') )) == null ? \'\' : __t) +\n\'</span><span class="Knight-Rider-loader animate"><span class="Knight-Rider-bar"></span><span class="Knight-Rider-bar"></span><span class="Knight-Rider-bar"></span></span></button></div></form></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},74988(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(50283),r=i(27496),a=o.extend({id:"milestone-confetti",tagName:"canvas",defaults:{amount:100,autoParty:!1,colors:["#ff492f","#ff8a00","#e8d738","#00cf35","#00b8ff","#7c5cff"],size:40,speed:.5,onDone:n.noop},__resize:function(){this.$parent.length&&(this.el.width=this.$parent.width(),this.el.height=this.$parent.height())},_updateConfetti:function(e,t){this.confettiAngle+=.001,e.off||(e.tiltAngle+=e.tiltAngleIncrement,e.tilt=15*Math.sin(e.tiltAngle-t/3),e.y+=(Math.cos(this.confettiAngle+e.density)+.5*e.radius)*this.options.speed),e.y>this.el.height+20&&(this.isAnimating?(e.tilt=a.range(-10,10,!0),e.tileAngle=0,e.tiltAngleIncrement=a.range(.05,.1),e.x=Math.random()*this.el.width,e.y=-20):e.off||(e.off=!0,this.confettiOffscreen++))},_stopAnimating:function(){this.animationInterval&&(clearInterval(this.animationInterval),this.animationInterval=null),this.isAnimating=!1},_startAnimating:function(e){e=e||!1,this._stopAnimating(),this.animationInterval=setInterval(s.bind(this.draw,this),15),this.isAnimating=!!e||this.isAnimating},initialize:function(e){this.options=s.extend({},this.defaults,e||{}),this.colors=this.options.colors,this.$win=n(window),this.$parent=n(),this.context=this.el.getContext("2d"),this.animationInterval=null,this.confetti=[],this.confettiAngle=0,this.confettiOffscreen=0,this.isAnimating=!1},render:function(){return s.defer(s.bind(this.setup,this)),this},setup:function(){this.$parent=this.$el.parent(),this.$parent.length&&(this.el.width=this.$parent.width(),this.el.height=this.$parent.height()),this.listenTo(r,"DOMEventor:flatresize",this.__resize);for(var e=this.options.size,t=.5*e,i=0,n=this.options.amount;i<n;i++)this.confetti.push({x:Math.random()*this.el.width,y:Math.random()*-this.el.height,radius:a.range(t,e),density:a.range(10,n),tilt:a.range(-10,10,!0),tiltAngle:0,tiltAngleIncrement:a.range(.05,.1),color:this.colors[a.range(0,this.colors.length-1,!0)],off:!1});this.options.autoParty&&this.party()},draw:function(){if(this.context.clearRect(0,0,this.el.width,this.el.height),this.confettiOffscreen===this.confetti.length)return this.trigger("confetti:animation:finished"),void this.remove();for(var e=0;e<this.confetti.length;e++){var t=this.confetti[e];this.context.beginPath(),this.context.lineWidth=.5*t.radius,this.context.strokeStyle=t.color,this.context.moveTo(t.x+t.tilt+t.radius/5,t.y),this.context.lineTo(t.x+t.tilt,t.y+t.tilt+t.radius/5),this.context.stroke(),this._updateConfetti(t,e)}},party:function(){return this.confettiOffscreen=0,this._startAnimating(!0),this},stopPartying:function(){return this.isAnimating=!1,this},remove:function(){return this._stopAnimating(),this.options.onDone(),o.prototype.remove.call(this)}},{range:function(e,t,i){i=i||!1;var n=(t-e)*Math.random()+e;return i?Math.round(n):n}});e.exports=a},75165(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(38578),r=i(27496),a=s.extend({mixins:[o],className:"secondary-nav",templates:{settings:i(72607)},_getTemplate:function(e){if("settings"===e)return this.templates.settings(this.toJSON())},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,e),this.listenTo(r,"drawer:subnav:open",this.render)},render:function(e){return e&&this.$el.html(this._getTemplate(e)),this}});e.exports=a},75450(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"form-row\"> ';\n if (!hideTitles) { ;\n__p += ' <h3 class=\"form-subheading\">' +\n((__t = ( __(title) )) == null ? '' : __t) +\n'</h3> ';\n } ;\n__p += ' ';\n if (typeof tagline !== 'undefined') { ;\n__p += ' <p class=\"form-subheading-tagline ' +\n((__t = ( (hideTitles) ? 'bold' : '')) == null ? '' : __t) +\n' \">' +\n((__t = ( __(tagline) )) == null ? '' : __t) +\n'</p> ';\n } ;\n__p += ' </div><div class=\"step-content\"> ' +\n((__t = ( stepContent )) == null ? '' : __t) +\n' </div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},75793(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(81515),r=i(38578),a=i(71092),l=i(27496),c=i(48357),u=a.extend({mixins:[r],el:".form-container",defaultText:"A few details, please",initialize:function(e){this.set("mobileMode",!(void 0===e||!e.mobileMode)&&e.mobileMode),this.errorTags={},this.listenTo(l,"drawerform:errortag:show",this.showErrorTag),this.listenTo(l,"drawerform:errortag:remove",this.removeErrorTag),this.listenTo(l,"drawerform:errortag:removeall",this.removeAllErrorTags)},showErrorTag:function(e){if(void 0!==e&&e.field){var t=e.field,i=e.text||o(this.defaultText),r=t.attr("name");if(!this.errorTags[r])if(this.errorTags[r]=n("<div>
1").addClass("drawer-error-tag").text(i),this.get("mobileMode")){this.groupName&&this.labelName||(this.formClass=t.parents(".form").parent().attr("class"),"help-form"===this.formClass?(this.groupName=".form-group",this.labelName=".group-label"):"abuse-form"===this.formClass&&(this.groupName=".form-row",this.labelName=".row-label"));var a=t.parents(this.groupName).find(this.labelName);this.errorTags[r].addClass(r).appendTo(a),c.animate(this.errorTags[r],"fadeIn",{duration:100,easing:"easeInOut"}),c.animate(this.errorTags[r],"fadeOut",{duration:100,easing:"easeIn",delay:3e3,complete:s.bind(function(){this.removeErrorTag({field:t})},this)})}else void 0===this.$drawer&&(this.$drawer=n(".drawer"),this.$formContainer=n(".form-container"),this.$formContainer.on("scroll",s.bind(this.updateErrortagPosition,this))),this.errorTags[r].css({top:t.offset().top,right:this.$drawer.width()}).insertAfter(this.$drawer),c.animate(this.errorTags[r],{translateX:["-5px","0px"]},{duration:100,easing:"easeInOut"})}},removeErrorTag:function(e){var t=e.field.attr("name");void 0!==this.errorTags&&this.errorTags[t]&&(this.errorTags[t].remove(),delete this.errorTags[t])},removeAllErrorTags:function(){void 0!==this.errorTags&&this.errorTags&&s.each(this.errorTags,function(e,t){e&&(e.remove(),e="",delete this.errorTags[t])},this)},updateErrortagPosition:function(){void 0!==this.errorTags&&this.errorTags&&s.each(this.errorTags,function(e,t){var i=n('.form-container [name="'+t+'"]');i.length||(i=n('form [name="'.concat(t,'"]'))),i?e.css({top:i.offset().top}):(e.remove(),this.removeErrorTag({field:i}))},this)},remove:function(){return this.removeAllErrorTags(),void 0!==this.$formContainer&&this.$formContainer.off("scroll",s.bind(this.updateErrortagPosition,this)),a.prototype.remove.apply(this)}});e.exports=u},76156(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, \'\') }\nwith (obj) {\n__p += \'<div class="form-row"><h3 class="form-subheading">\' +\n((__t = ( __(\'What\\\'s going on?\') )) == null ? \'\' : __t) +\n\'</h3></div><form><input type="hidden" name="context" value="\' +\n__e( _.get(prefillFields, \'context\', \'\') ) +\n\'"> <input type="hidden" name="source" value="\' +\n__e( _.get(prefillFields, \'source\', \'\') ) +\n\'"> \';\n if (mode !== \'message\') { ;\n__p += \' <div class="form-row checkmark-row"><input class="option-radio" type="radio" name="flag" id="flag-nsfw" data-flag-action="nsfw" value="nsfw"> <label class="option-label" for="flag-nsfw"> \' +\n__e( __(\'Report sexually explicit material\') ) +\n\' \';\n if (safesearch) { ;\n__p += \' <div class="sub-label"> \' +\n((__t = ( __(\'Adult-oriented content is currently being hidden ( %1$s ) but this post still showed up.\', \'<i class="icon_lock_thick_12"></i>\') )) == null ? \'\' : __t) +\n\' </div> \';\n } ;\n__p += \' </label></div> \';\n } ;\n__p += \' <div class="form-row checkmark-row"><input class="option-radio" type="radio" name="flag" id="flag-spam" data-flag-action="spam" value="spam"> <label class="option-label" for="flag-spam"> \' +\n__e( __(\'Report spam and/or bot\') ) +\n\' </label></div><div class="form-row checkmark-row"><input class="option-radio" type="radio" name="flag" id="flag-cg" data-flag-action="cg" value="cg"> <label class="option-label" for="flag-cg"> \' +\n__e( __(\'Report something else\') ) +\n\' </label></div> \';\n if (mode === \'message\') { ;\n__p += \' \';\n if (sender) { ;\n__p += \' <div class="form-row ignore"><div class="option-radio"><label class="binary_switch"><input type="checkbox" name="block" id="block" checked="checked"> <span class="binary_switch_track"></span> <span class="binary_switch_button"></span></label></div><label class="option-label" for="block"> \' +\n__e( __(\'Block %1$s\', sender) ) +\n\' </label></div> \';\n } ;\n__p += \' \';\n } else if (tumblelog) { ;\n__p += \' <div class="form-row ignore"><div class="option-radio"><label class="binary_switch"><input type="checkbox" name="block" id="block" checked="checked"> <span class="binary_switch_track"></span> <span class="binary_switch_button"></span></label></div><label class="option-label" for="block"> \' +\n__e( __(\'Block %1$s\', tumblelog) ) +\n\' </label></div> \';\n } ;
1\n__p += \' <div class="form-row form-controls"> \';\n if (mode === \'message\' && !sender) { ;\n__p += \' <button class="chrome big red right flag" type="button" data-submit-flag-form disabled="disabled"><span class="label">\' +\n__e( __(\'Report\') ) +\n\'</span><span class="Knight-Rider-loader animate"><span class="Knight-Rider-bar"></span><span class="Knight-Rider-bar"></span><span class="Knight-Rider-bar"></span></span></button> <button class="chrome big blue right continue" type="button" data-survey-nav-to="abuse"><span class="label">\' +\n((__t = ( __(\'Continue\') )) == null ? \'\' : __t) +\n\'</span></button> \';\n } else { ;\n__p += \' <button class="chrome big red right flag" type="button" data-submit-flag-form><span class="label">\' +\n((__t = ( __(\'Block\') )) == null ? \'\' : __t) +\n\'</span><span class="Knight-Rider-loader animate"><span class="Knight-Rider-bar"></span><span class="Knight-Rider-bar"></span><span class="Knight-Rider-bar"></span></span></button> <button class="chrome big blue right continue" type="button" data-survey-nav-to="abuse"><span class="label">\' +\n((__t = ( __(\'Continue\') )) == null ? \'\' : __t) +\n\'</span></button> \';\n } ;\n__p += \' </div></form>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},76198(e,t,i){"use strict";var n,s=i(71742),o=i(35642),r=s.extend({name:"header",autoAppend:!0,append:function(){this.headerView=new o({el:this.container}),this.enableFunctionality()},enableFunctionality:function(){this.headerView.enableCompose()},disableSticky:function(){this.headerView.disableSticky()}});e.exports=function(){return n||(n=new r),n}},76252(e,t,i){"use strict";var n=i(74692),s=i(50283),o=i(27496),r=s.extend({template:i(44740),className:"elevator-wrapper",defaults:{fadeScrollDistance:2e3,visible:!1},events:{click:"elevate"},initialize:function(){this.listenTo(o,"DOMEventor:flatscroll",this.onScroll),this.on("change:visible",this.toggleVisibility)},elevate:function(){n("html").velocity("scroll",1e3)},onScroll:function(e){e&&(e.windowScrollY>=this.get("fadeScrollDistance")?this.set("visible",!0):this.set("visible",!1))},toggleVisibility:function(e,t){this.$el.toggleClass("visible",t)}});e.exports=r},76343(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape;\nwith (obj) {\n__p += \'<div class="search-input-wrapper" data-js-search-container><div class="search-input-container"><input type="text" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false" class="search-input" placeholder="\' +\n__e( __(\'Message to...\') ) +\n\'" data-js-in
1put> <button class="selected-blog" data-js-selected-blog data-js-theme-accent-color-as-background></button></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},76419(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(37623),r=i(31384),a=i(95921).truncateLongStrings;function l(){}l.prototype.genericFieldMap={one:"embedCode",two:"caption"},l.prototype.allowAnswerFields=["caption"],l.prototype.editorField="two",l.prototype.resetPreserveFields=["caption","tags"],l.prototype.resetAttributes=["preuploadUrl","preuploadKey","embedCode","confirmTos","copyrightFallback"],l.prototype.typeAttributes={caption:"",confirmTos:!1},l.prototype.generateTweetText=function(e,t){var i=this.getHtmlStripped("caption");return i=i.replace(/[\r\n\s]*\[\[MORE\]\].*$/gi,""),a(i,t)},l.prototype.validate=function(e,t,i){var n=[];return t.embedCode?0===t.embedCode.length&&n.push("No embed specified."):t.preuploadUrl?t.confirmTos||n.push(s("You must agree that you have permission to share this file.")):t.video?0===t.video.embed_code.length&&n.push("Direct embed missing."):n.push("No video specified."),e.call(this,t,{errors:n})},l.prototype.canPreview=function(){return!this.get("preuploadKey")&&this.isValid()},l.prototype.serializeForServer=function(e){var t=e.apply(this,n.rest(arguments)),i=n.omit({preuploaded_url:this.get("preuploadUrl"),preuploaded_ch:this.get("preuploadKey"),confirm_tos:this.get("confirmTos"),copyright_fallback:this.get("copyrightFallback")},n.isUndefined);return n.extend(t,i),t=o(t,{embedCode:"embed_code"})},l.prototype.getEmbedData=function(e){var t=!1;return this.has("video")?t={isNativeVideo:!0,embedRenderContext:"inline",width:(t=r(this.get("video"))).dimensions.width,height:t.dimensions.height,previewIframe:t.previewIframe,embedCode:t.embedCode}:this.has("video_embed")&&(t=r(this.get("video_embed"))),t},e.exports=l},76689(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div data-js-message-container></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},77171(e,t,i){function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function s(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,o(n.key),n)}}function o(e){var t=function(e,t){if("object"!=n(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var s=i.call(e,t||"default");if("object"!=n(s))return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==n(t)?t:t+""}var r=i(55679),a=i(74692),l=i(92414),c=function(){return e=function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.el=t,this.stateChangeFn=i,this.positionMonitor=new l({el:this.el,headerEl:a(".l-header-container").get(0)}),this.timeInView=0,this.isLargeElement=this.getElHeight()*this.getElWidth()>3e5},(t=[{key:"isMuted",value:function(){}},{key:"getTimeOffset",value:function(){return Date.now()/1e3}},{key:"percentageInView",value:function(){var e=100*this.positionMonitor.getPercentageInView();return e>0&&0===this.timeInView?this.timeInView=this.getTimeOffset():0===e&&(this.timeInView=0),e}},{key:"timePosition",value:function(){}},{key:"maxDuration",value:function(){}},{key:"getElHeight",value:function(){var e=this.positionMonitor.getElHeight();return r.isNumber(e)?e:-1}},{key:"getElWidth",value:function(){var e=this.positionMonitor.getElWidth();return r.isNumber(e)?e:-1}},{key:"getMacroValue",value:function(e){}}])&&s(e.prototype,t),i&&s(e,i),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,i}();e.exports=c},77232(e,t,i){var n;!function(s,o){"use strict";var r="function",a="undefined",l="object",c="string",u="major",h="model",d="name",p="type",g="vendor",f="version",m="architecture",_="console",v="mobile",b="tablet",y="smarttv",w="wearable",C="embedded",x="Amazon",k="Apple",S="ASUS",T="BlackBerry",E="Browser",P="Chrome",I="Firefox",F="Google",A="Honor",M="Huawei",j="LG",R="Microsoft",D="Motorola",$="Nvidia",N="OnePlus",O="Opera",L="OPPO",B="Samsung",V="Sharp",U="Sony",z="Xiaomi",H="Zebra",q="Facebook",W="Chromium OS",G="Mac OS",K=" Browser",Q=function(e){for(var t={},i=0;i<e.length;i++)t[e[i].toUpperCase()]=e[i];return t},J=function(e,t){return typeof e===c&&-1!==Y(t).indexOf(Y(e))},Y=function(e){return e.toLowerCase()},X=function(e,t){if(typeof e===c)return e=e.replace(/^\s\s*/,""),typeof t===a?e:e.substring(0,500)},Z=function(e,t){for(var i,n,s,a,c,u,h=0;h<t.length&&!c;){var d=t[h],p=t[h+1];for(i=n=0;i<d.length&&!c&&d[i];)if(c=d[i++].exec(e))for(s=0;s<p.length;s++)u=c[++n],typeof(a=p[s])===l&&a.length>0?2===a.length?typeof a[1]==r?this[a[0]]=a[1].call(this,u):this[a[0]]=a[1]:3===a.length?typeof a[1]!==r||a[1].exec&&a[1].test?this[a[0]]=u?u.replace(a[1],a[2]):o:this[a[0]]=u?a[1].call(this,u,a[2]):o:4===a.length&&(this[a[0]]=u?a[3].call(this,u.replace(a[1],a[2])):o):this[a]=u||o;h+=2}},ee=function(e,t){for(var i in t)if(typeof t[i]===l&&t[i].length>0){for(var n=0;n<t[i].length;n++)if(J(t[i][n],e))return"?"===i?o:i}else if(J(t[i],e))return"?"===i?o:i;return t.hasOwnProperty("*")?t["*"]:e},te={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2",8.1:"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},ie={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[f,[d,"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[f,[d,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[d,f],[/opios[\/ ]+([\w\.]+)/i],[f,[d,O+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[f,[d,O+" GX"]],[/\bopr\/([\w\.]+)/i],[f,[d,O]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[f,[d,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[f,[d,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon)\/([-\w\.]+)/i,/(heytap|ovi|115)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[d,f],[/quark(?:pc)?\/([-\w\.]+)/i],[f,[d,"Quark"]],[/\bddg\/([\w\.]+)/i],[f,[d,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[f,[d,"
1UC"+E]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[f,[d,"WeChat"]],[/konqueror\/([\w\.]+)/i],[f,[d,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[f,[d,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[f,[d,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[f,[d,"Smart Lenovo "+E]],[/(avast|avg)\/([\w\.]+)/i],[[d,/(.+)/,"$1 Secure "+E],f],[/\bfocus\/([\w\.]+)/i],[f,[d,I+" Focus"]],[/\bopt\/([\w\.]+)/i],[f,[d,O+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[f,[d,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[f,[d,"Dolphin"]],[/coast\/([\w\.]+)/i],[f,[d,O+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[f,[d,"MIUI"+K]],[/fxios\/([\w\.-]+)/i],[f,[d,I]],[/\bqihoobrowser\/?([\w\.]*)/i],[f,[d,"360"]],[/\b(qq)\/([\w\.]+)/i],[[d,/(.+)/,"$1Browser"],f],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[d,/(.+)/,"$1"+K],f],[/samsungbrowser\/([\w\.]+)/i],[f,[d,B+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[f,[d,"Sogou Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[d,"Sogou Mobile"],f],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[d,f],[/(lbbrowser|rekonq)/i,/\[(linkedin)app\]/i],[d],[/ome\/([\w\.]+) \w* ?(iron) saf/i,/ome\/([\w\.]+).+qihu (360)[es]e/i],[f,d],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[d,q],f],[/(Klarna)\/([\w\.]+)/i,/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/(daum)apps[\/ ]([\w\.]+)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i],[d,f],[/\bgsa\/([\w\.]+) .*safari\//i],[f,[d,"GSA"]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[f,[d,"TikTok"]],[/headlesschrome(?:\/([\w\.]+)| )/i],[f,[d,P+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[d,P+" WebView"],f],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[f,[d,"Android "+E]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[d,f],[/version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i],[f,[d,"Mobile Safari"]],[/version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i],[f,d],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[d,[f,ee,{"1.0":"/8",1.2:"/1",1.3:"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"}]],[/(webkit|khtml)\/([\w\.]+)/i],[d,f],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[d,"Netscape"],f],[/(wolvic|librewolf)\/([\w\.]+)/i],[d,f],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[f,[d,I+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(amaya|dillo|doris|icab|ladybird|lynx|mosaic|netsurf|obigo|polaris|w3m|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/\b(links) \(([\w\.]+)/i],[d,[f,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[d,[f,/master.|lts./,""]]],cpu:[[/\b((amd|x|x86[-_]?|wow|win)64)\b/i],[[m,"amd64"]],[/(ia32(?=;))/i,/\b((i[346]|x)86)(pc)?\b/i],[[m,"ia32"]],[/\b(aarch64|arm(v?[89]e?l?|_?64))\b/i],[[m,"arm64"]],[/\b(arm(v[67])?ht?n?[fl]p?)\b/i],[[m,"armhf"]],[/( (ce|mobile); ppc;|\/[\w\.]+arm\b)/i],[[m,"arm"]],[/((ppc|powerpc)(64)?)( mac|;|\))/i],[[m,/ower/,"",Y]],[/ sun4\w[;\)]/i],[[m,"sparc"]],[/\b(avr32|ia64(?=;)|68k(?=\))|\barm(?=v([1-7]|[5-7]1)l?|;|eabi)|(irix|mips|sparc)(64)?\b|pa-risc)/i],[[m,Y]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[h,[g,B],[p,b]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr])[-\w]+)/i,/sec-(sgh\w+)/i],[h,[g,B],[p,v]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[h,[g,k],[p,v]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[h,[g,k],[p,b]],[/(macintosh);/i],[h,[g,k]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[h,[g,V],[p,v]],[/\b((?:brt|eln|hey2?|gdi|jdn)-a?[lnw]09|(?:ag[rm]3?|jdn2|kob2)-a?[lw]0[09]hn)(?: bui|\)|;)/i],[h,[g,A],[p,b]],[/honor([-\w ]+)[;\)]/i],[h,[g,A],[p,v]],[/\b((?:ag[rs][2356]?k?|bah[234]?|bg[2o]|bt[kv]|cmr|cpn|db[ry]2?|jdn2|got|kob2?k?|mon|pce|scm|sht?|[tw]gr|vrd)-[ad]?[lw][0125][09]b?|605hw|bg2-u03|(?:gem|fdr|m2|ple|t1)-[7a]0[1-4][lu]|t1-a2[13][lw]|mediapad[\w\. ]*(?= bui|\)))\b(?!.+d\/s)/i],[h,[g,M],[p,b]],[/(?:huawei)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[h,[g,M],[p,v]],[/oid[^\)]+; (2[\dbc]{4}(182|283|rp\w{2})[cgl]|m2105k81a?c)(?: bui|\))/i,/\b((?:red)?mi[-_ ]?pad[\w- ]*)(?: bui|\))/i],[[h,/_/g," "],[g,z],[p,b]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite|pro)?)(?: bui|\))/i,/ ([\w ]+) miui\/v?\d/i],[[h,/_/g," "],[g,z],[p,v]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[h,[g,L],[p,v]],[/\b(opd2(\d{3}a?))(?: bui|\))/i],[h,[g,ee,{OnePlus:["304","403","203"],"*":L}],[p,b]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[h,[g,"Vivo"],[p,v]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[h,[g,"Realme"],[p,v]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto(?! 360)[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[h,[g,D],[p,v]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[h,[g,D],[p,b]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[h,[g,j],[p,b]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv|watch)\w+)/i,/\blg-?([\d\w]+) bui/i],[h,[g,j],[p,v]],[/(ideatab[-\w ]+|602lv|d-42a|a101lv|a2109a|a3500-hv|s[56]000|pb-6505[my]|tb-?x?\d{3,4}
1(?:f[cu]|xu|[av])|yt\d?-[jx]?\d+[lfmx])( bui|;|\)|\/)/i,/lenovo ?(b[68]0[08]0-?[hf]?|tab(?:[\w- ]+?)|tb[\w-]{6,7})( bui|;|\)|\/)/i],[h,[g,"Lenovo"],[p,b]],[/(nokia) (t[12][01])/i],[g,h,[p,b]],[/(?:maemo|nokia).*(n900|lumia \d+|rm-\d+)/i,/nokia[-_ ]?(([-\w\. ]*))/i],[[h,/_/g," "],[p,v],[g,"Nokia"]],[/(pixel (c|tablet))\b/i],[h,[g,F],[p,b]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[h,[g,F],[p,v]],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[h,[g,U],[p,v]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[h,"Xperia Tablet"],[g,U],[p,b]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[h,[g,N],[p,v]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[h,[g,x],[p,b]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[h,/(.+)/g,"Fire Phone $1"],[g,x],[p,v]],[/(playbook);[-\w\),; ]+(rim)/i],[h,g,[p,b]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[h,[g,T],[p,v]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[h,[g,S],[p,b]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[h,[g,S],[p,v]],[/(nexus 9)/i],[h,[g,"HTC"],[p,b]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[g,[h,/_/g," "],[p,v]],[/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])\w*(\)| bui)/i],[h,[g,"TCL"],[p,b]],[/(itel) ((\w+))/i],[[g,Y],h,[p,ee,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[h,[g,"Acer"],[p,b]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[h,[g,"Meizu"],[p,v]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[h,[g,"Ulefone"],[p,v]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[h,[g,"Energizer"],[p,v]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[h,[g,"Cat"],[p,v]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[h,[g,"Smartfren"],[p,v]],[/droid.+; (a(?:015|06[35]|142p?))/i],[h,[g,"Nothing"],[p,v]],[/; (x67 5g|tikeasy \w+|ac[1789]\d\w+)( b|\))/i,/archos ?(5|gamepad2?|([\w ]*[t1789]|hello) ?\d+[\w ]*)( b|\))/i],[h,[g,"Archos"],[p,b]],[/archos ([\w ]+)( b|\))/i,/; (ac[3-6]\d\w{2,8})( b|\))/i],[h,[g,"Archos"],[p,v]],[/(imo) (tab \w+)/i,/(infinix) (x1101b?)/i],[g,h,[p,b]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus(?! zenw)|dell|jolla|meizu|motorola|polytron|infinix|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (hmd|imo) ([\w ]+?)(?: bui|\))/i,/(hp) ([\w ]+\w)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w ]+?)(?: bui|\)|\/)/i,/(oppo) ?([\w ]+) bui/i],[g,h,[p,v]],[/(kobo)\s(ereader|touch)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i,/(nook)[\w ]+build\/(\w+)/i,/(dell) (strea[kpr\d ]*[\dko])/i,/(le[- ]+pan)[- ]+(\w{1,9}) bui/i,/(trinity)[- ]*(t\d{3}) bui/i,/(gigaset)[- ]+(q\w{1,9}) bui/i,/(vodafone) ([\w ]+)(?:\)| bui)/i],[g,h,[p,b]],[/(surface duo)/i],[h,[g,R],[p,b]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[h,[g,"Fairphone"],[p,v]],[/(u304aa)/i],[h,[g,"AT&T"],[p,v]],[/\bsie-(\w*)/i],[h,[g,"Siemens"],[p,v]],[/\b(rct\w+) b/i],[h,[g,"RCA"],[p,b]],[/\b(venue[\d ]{2,7}) b/i],[h,[g,"Dell"],[p,b]],[/\b(q(?:mv|ta)\w+) b/i],[h,[g,"Verizon"],[p,b]],[/\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i],[h,[g,"Barnes & Noble"],[p,b]],[/\b(tm\d{3}\w+) b/i],[h,[g,"NuVision"],[p,b]],[/\b(k88) b/i],[h,[g,"ZTE"],[p,b]],[/\b(nx\d{3}j) b/i],[h,[g,"ZTE"],[p,v]],[/\b(gen\d{3}) b.+49h/i],[h,[g,"Swiss"],[p,v]],[/\b(zur\d{3}) b/i],[h,[g,"Swiss"],[p,b]],[/\b((zeki)?tb.*\b) b/i],[h,[g,"Zeki"],[p,b]],[/\b([yr]\d{2}) b/i,/\b(dragon[- ]+touch |dt)(\w{5}) b/i],[[g,"Dragon Touch"],h,[p,b]],[/\b(ns-?\w{0,9}) b/i],[h,[g,"Insignia"],[p,b]],[/\b((nxa|next)-?\w{0,9}) b/i],[h,[g,"NextBook"],[p,b]],[/\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i],[[g,"Voice"],h,[p,v]],[/\b(lvtel\-)?(v1[12]) b/i],[[g,"LvTel"],h,[p,v]],[/\b(ph-1) /i],[h,[g,"Essential"],[p,v]],[/\b(v(100md|700na|7011|917g).*\b) b/i],[h,[g,"Envizen"],[p,b]],[/\b(trio[-\w\. ]+) b/i],[h,[g,"MachSpeed"],[p,b]],[/\btu_(1491) b/i],[h,[g,"Rotor"],[p,b]],[/((?:tegranote|shield t(?!.+d tv))[\w- ]*?)(?: b|\))/i],[h,[g,$],[p,b]],[/(sprint) (\w+)/i],[g,h,[p,v]],[/(kin\.[onetw]{3})/i],[[h,/\./g," "],[g,R],[p,v]],[/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[h,[g,H],[p,b]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[h,[g,H],[p,v]],[/smart-tv.+(samsung)/i],[g,[p,y]],[/hbbtv.+maple;(\d+)/i],[[h,/^/,"SmartTV"],[g,B],[p,y]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[g,j],[p,y]],[/(apple) ?tv/i],[g,[h,k+" TV"],[p,y]],[/crkey/i],[[h,P+"cast"],[g,F],[p,y]],[/droid.+aft(\w+)( bui|\))/i],[h,[g,x],[p,y]],[/(shield \w+ tv)/i],[h,[g,$],[p,y]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[h,[g,V],[p,y]],[/(bravia[\w ]+)( bui|\))/i],[h,[g,U],[p,y]],[/(mi(tv|box)-?\w+) bui/i],[h,[g,z],[p,y]],[/Hbbtv.*(technisat) (.*);/i],[g,h,[p,y]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[g,X],[h,X],[p,y]],[/droid.+; ([\w- ]+) (?:android tv|smart[- ]?tv)/i],[h,[p,y]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[p,y]],[/(ouya)/i,/(nintendo) ([wids3utch]+)/i],[g,h,[p,_]],[/droid.+; (shield)( bui|\))/i],[h,[g,$],[p,_]],[/(playstation \w+)/i],[h,[g,U],[p,_]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[h,[g,R],[p,_]],[/\b(sm-[lr]\d\d[0156][fnuw]?s?|gear live)\b/i],[h,[g,B],[p,w]],[/((pebble))app/i,/(asu
vendor: 4,189 bytes, line 1
1s|google|lg|oppo) ((pixel |zen)?watch[\w ]*)( bui|\))/i],[g,h,[p,w]],[/(ow(?:19|20)?we?[1-3]{1,3})/i],[h,[g,L],[p,w]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[h,[g,k],[p,w]],[/(opwwe\d{3})/i],[h,[g,N],[p,w]],[/(moto 360)/i],[h,[g,D],[p,w]],[/(smartwatch 3)/i],[h,[g,U],[p,w]],[/(g watch r)/i],[h,[g,j],[p,w]],[/droid.+; (wt63?0{2,3})\)/i],[h,[g,H],[p,w]],[/droid.+; (glass) \d/i],[h,[g,F],[p,w]],[/(pico) (4|neo3(?: link|pro)?)/i],[g,h,[p,w]],[/; (quest( \d| pro)?)/i],[h,[g,q],[p,w]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[g,[p,C]],[/(aeobc)\b/i],[h,[g,x],[p,C]],[/(homepod).+mac os/i],[h,[g,k],[p,C]],[/windows iot/i],[[p,C]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i],[h,[p,v]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[h,[p,b]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[p,b]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[p,v]],[/droid .+?; ([\w\. -]+)( bui|\))/i],[h,[g,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[f,[d,"EdgeHTML"]],[/(arkweb)\/([\w\.]+)/i],[d,f],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[f,[d,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[d,f],[/ladybird\//i],[[d,"LibWeb"]],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[f,d]],os:[[/microsoft (windows) (vista|xp)/i],[d,f],[/(windows (?:phone(?: os)?|mobile|iot))[\/ ]?([\d\.\w ]*)/i],[d,[f,ee,te]],[/windows nt 6\.2; (arm)/i,/windows[\/ ]([ntce\d\. ]+\w)(?!.+xbox)/i,/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[f,ee,te],[d,"Windows"]],[/[adehimnop]{4,7}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[f,/_/g,"."],[d,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[d,G],[f,/_/g,"."]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[f,d],[/(ubuntu) ([\w\.]+) like android/i],[[d,/(.+)/,"$1 Touch"],f],[/(android|bada|blackberry|kaios|maemo|meego|openharmony|qnx|rim tablet os|sailfish|series40|symbian|tizen|webos)\w*[-\/; ]?([\d\.]*)/i],[d,f],[/\(bb(10);/i],[f,[d,T]],[/(?:symbian ?os|symbos|s60(?=;)|series ?60)[-\/ ]?([\w\.]*)/i],[f,[d,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[f,[d,I+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[f,[d,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[f,[d,"watchOS"]],[/crkey\/([\d\.]+)/i],[f,[d,P+"cast"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[d,W],f],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) ([wids345portablevuch]+)/i,/(xbox); +xbox ([^\);]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux)(?: arm\w*| x86\w*| ?)([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[d,f],[/(sunos) ?([\w\.\d]*)/i],[[d,"Solaris"],f],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[d,f]]},ne=function(e,t){if(typeof e===l&&(t=e,e=o),!(this instanceof ne))return new ne(e,t).getResult();var i=typeof s!==a&&s.navigator?s.navigator:o,n=e||(i&&i.userAgent?i.userAgent:""),_=i&&i.userAgentData?i.userAgentData:o,y=t?function(e,t){var i={};for(var n in e)t[n]&&t[n].length%2==0?i[n]=t[n].concat(e[n]):i[n]=e[n];return i}(ie,t):ie,w=i&&i.userAgent==n;return this.getBrowser=function(){var e,t={};return t[d]=o,t[f]=o,Z.call(t,n,y.browser),t[u]=typeof(e=t[f])===c?e.replace(/[^\d\.]/g,"").split(".")[0]:o,w&&i&&i.brave&&typeof i.brave.isBrave==r&&(t[d]="Brave"),t},this.getCPU=function(){var e={};return e[m]=o,Z.call(e,n,y.cpu),e},this.getDevice=function(){var e={};
1return e[g]=o,e[h]=o,e[p]=o,Z.call(e,n,y.device),w&&!e[p]&&_&&_.mobile&&(e[p]=v),w&&"Macintosh"==e[h]&&i&&typeof i.standalone!==a&&i.maxTouchPoints&&i.maxTouchPoints>2&&(e[h]="iPad",e[p]=b),e},this.getEngine=function(){var e={};return e[d]=o,e[f]=o,Z.call(e,n,y.engine),e},this.getOS=function(){var e={};return e[d]=o,e[f]=o,Z.call(e,n,y.os),w&&!e[d]&&_&&_.platform&&"Unknown"!=_.platform&&(e[d]=_.platform.replace(/chrome os/i,W).replace(/macos/i,G)),e},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return n},this.setUA=function(e){return n=typeof e===c&&e.length>500?X(e,500):e,this},this.setUA(n),this};ne.VERSION="0.7.41",ne.BROWSER=Q([d,f,u]),ne.CPU=Q([m]),ne.DEVICE=Q([h,g,p,_,v,y,b,w,C]),ne.ENGINE=ne.OS=Q([d,f]),typeof t!==a?(e.exports&&(t=e.exports=ne),t.UAParser=ne):i.amdO?(n=function(){return ne}.call(t,i,t,e))===o||(e.exports=n):typeof s!==a&&(s.UAParser=ne);var se=typeof s!==a&&(s.jQuery||s.Zepto);if(se&&!se.ua){var oe=new ne;se.ua=oe.getResult(),se.ua.get=function(){return oe.getUA()},se.ua.set=function(e){oe.setUA(e);var t=oe.getResult();for(var i in t)se.ua[i]=t[i]}}}("object"==typeof window?window:this)},77370(e,t,i){"use strict";var n=i(80160).extend({defaults:{popover:null,model:null,options:null,skipAnimation:!1,isMinimizing:!1},getOptions:function(){return this.get("options")},getConversation:function(){return this.get("model")},getPopover:function(){return this.get("popover")},getView:function(){var e=this.getPopover();return e?e.getView():null}});e.exports=n},77494(e,t,i){"use strict";var n=i(10768),s=i(29697);e.exports=function(e,t){return t||(t={}),e.jquery?(t.el=e,t.model||(t.model=new n(t.el.data("json")))):t.model=e instanceof n?e:new n(e),new s(t)}},77566(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div class=\"editor editor-plaintext\" aria-label=\"' +\n__e( ariaLabel ) +\n'\" contenteditable=\"true\" data-js-plaintexteditor></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},77594(e,t,i){"use strict";var n=i(28724),s=i(27496),o=i(55679),r=i(84315),a=new n({__bindKeycommands:function(){o.result(this,"keycommands")&&(o.each(o.result(this,"keycommands"),this.__bindKey,this),r.add({id:this.__keyId,keys:o.keys(o.result(this,"keycommands"))}))},__bindKey:function(e,t){this.listenTo(s,"DOMEventor:"+t,this.__keyFn)},__keyFn:function(e,t){!this.__keysDisabled&&r.shouldRun(t,this.__keyId)&&this[this.keycommands[t]].apply(this,arguments)},focusKeys:function(){r.focus(this.__keyId)},unfocusKeys:function(){r.unfocus(this.__keyId)},soloKeys:function(e){r.solo(this.__keyId,e)},unSoloKeys:function(){r.unSolo(this.__keyId)},disableKeys:function(){this.__keysDisabled=!0},enableKeys:function(){this.__keysDisabled=!1},before:{initialize:function(){this.keycommands||(this.keycommands={}),this.__keysDisabled=!1,this.__keyId=o.uniqueId("keycomms"),this.__bindKeycommands()},stopListening:function(e){(o.isEmpty(e)||e===this)&&r.remove(this.__keyId)}}});e.exports=a},77599(e,t,i){"use strict";var n,s,o,r,a=i(55679),l=i(74692),c=i(99227),u=i(27496),h=i(15539),d=i(6479),p=(n=".post_container",s=".post:not([data-is-pinned])",o=["dashboard","drafts","inbox"],r={preExecute:function(){if("queue"===this.contextData.contextPage)return l(window).off("beforeunload"),void window.location.replace(this.contextData.baseRoute)},execute:function(e,t){if(t=a.merge({fastCompose:!1},t||{}),this.saveResponse=e.responseJSON,-1!==o.indexOf(this.contextData.contextPage)){var i=!this.saveResponse.post.is_edit&&!this.saveResponse.post.is_reblog,n="post_dashboard_html"in this.saveResponse,s=!(!this.saveResponse.post||!this.saveResponse.post.is_edit)&&this.contextData.contextPage!==this.saveResponse.post_context_page&&this.$inlinePostEl.hasClass("post_container");if(i?this._fetchMorePosts():n&&(s?this._removeInline():this._updateInline()),this._displayNotification(this.saveResponse,t),this.saveResponse.context_tumblelog){var r=this.saveResponse.context_tumblelog.name_or_id,u=l('#dashboard_controls_open_blog[data-blog-name="'+r+'"]');a.forEach(this.saveResponse.context_tumblelog,function(e,t){if(t.match(/_count$/i)){var i=u.find('[data-blog-control
1s-count="'+t+'"]');i.toggleClass("count_0",e<="0"),i.find(".count").text(c(e).format("0,0"))}},this);var h=d().getChannel(r),p=a.pick(this.saveResponse.context_tumblelog,h.keys());h.set(p)}}},_fetchMorePosts:function(){var e=this.contextData.baseRoute.replace(/^\/|\/$/g,""),t="drafts"===this.contextData.contextPage?"after":"before",i=this._findLatestPostId();(new h).fetch({pageRoot:e,direction:t,refPostID:i,success:a.bind(this._fetchSuccess,this),error:this._fetchFailure})},_fetchSuccess:function(e){var t=l(e.get("dashboardHTML")),i=this.contextData.$postButtonsContainer.nextAll(n).has(s).first();0===i.length?this.contextData.$postButtonsContainer.parent().append(t):t.insertBefore(i),l(".no_posts_found").remove(),u.trigger("posts:load")},_fetchFailure:function(){console.error("Failed loading dashboard HTML after successful post submission.")},_findLatestPostId:function(){return this.contextData.$postButtonsContainer.nextAll(n).find(s).first().data("post-id")},_updateInline:function(){var e=l(this.saveResponse.post_dashboard_html.trim());this.$inlinePostEl.replaceWith(e.eq(0)),u.trigger("posts:load")},_removeInline:function(){var e=this.contextData.baseRoute.split("/");e.splice(-1,1);var t=this.$inlinePostEl;t.fadeOut(200,function(){t.remove()}),l("#posts .post").not(".new_post").length<=1&&(window.location=e.join("/"))},_displayNotification:function(e,t){var i=this.contextData.baseRoute.split("/")[1]||"",n=e.message,s=a.parseInt(this.contextData.notificationDelay),o={type:"dashboard"===e.post_context_page?"dashReblog":e.post_context_page,url:e.post_tumblelog.post_url,tumblelog:{name:e.post_tumblelog.name_or_id,url:e.post_tumblelog.url,avatar:e.post_tumblelog.avatar}};(!e.created_post||e.post.is_reblog||t&&t.fastCompose||"tagged"===i.toLowerCase())&&a.delay(function(){u.trigger("postForms:saveHook:toast",n,o)},s)}},function(e){this.contextData=a.defaults(e||{},{notificationDelay:250}),a.extend(this,r)});e.exports=p},77652(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape;\nwith (obj) {\n__p += \'<div class="inbox-compose-input"><label class="label"><span class="label-text-container"> \' +\n__e( __(\'To:\') ) +\n\' </span><span class="input-container"><input type="text" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false" class="input" data-js-textinput></span></label></div><div class="inbox-compose-main"><div data-subview="loader"></div><div data-subview="favoritesView"></div><div data-subview="searchResultView"></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},77656(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div data-js-container> ';\n if (title) { ;\n__p += ' <h2>' +\n__e( title ) +\n'</h2> ';\n } ;\n__p += ' <div data-subview=\"recipients[]\"></div><div data-js-no-results-container class=\"no-results\"><p data-js-no-results-text>' +\n__e( noResultsText ) +\n'</p></div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},77770(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div class=\"content\"><label>' +\n__e( message ) +\n'</label> <button data-js-theme-button data-js-button class=\"chrome\">' +\n__e( buttonText ) +\n'</button></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},78355(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\', __e = _.escape;\nwith (obj) {\n__p += \'<div class="mobile-banner banner-context-dashboard \' +\n__e( banner_class ) +\n\'"><div class="mobile-banner-inner"><div class="mobile-banner-full"><div data-subview="bannerInternals"></div></div></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},78421(e,t,i){"use strict";var n=i(42e3);e.exports=n},78947(e,t,i){var n=i(55679),s=i(33455),o=[].slice;e.exports=function(){for(var e,t=o.apply(arguments),i=s,r=0;r<t.length;r++){if(e=t[r],!i||!n.has(i,e))return null;i=i[e]}return i}},79052(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(48357).animate,r=i(67127),a=i(17145),l=i(21391),c=i(37552),u=i(27496),h=i(95349),d=s("html"),p=a.extend({defaults:{keepInside:!1,scrollSpeedMs:250,triggerPadding:-50,contentPadding:20,debounceMs:200},start:function(e){return this._running&&this.stop(),this._running=!0,e&&!n.isPlainObject(e)&&(e={el:e}),this.options=e=n.extend({},this.defaults,e),this.$el=s(e.el),this.updateContentRect(),this.listenTo(u,"DOMEventor:flatscroll",this.checkScrollBounds),this},stop:function(){return this._running=!1,this._scrollTop=!1,this._ignoreScroll=!0,this.cancelEnfor
1ceScrollBounds(),this.stopListening(),this},pause:function(){this._running&&(this._ignoreScroll=!0)},resume:function(){this._running&&this._ignoreScroll&&(this._ignoreScroll=!1,this.checkScrollBounds())},updateContentRect:function(){this.contentRect||(this.contentRect={}),this.lastContentRect&&(this.lastContentRect.offsetTop=this.contentRect.offsetTop,this.lastContentRect.offsetLeft=this.contentRect.offsetLeft,this.lastContentRect.offsetHeight=this.contentRect.offsetHeight,this.lastContentRect.offsetWidth=this.contentRect.offsetWidth);var e=this.$el.offset();return this.contentRect.offsetTop=e.top,this.contentRect.offsetLeft=e.left,this.contentRect.offsetHeight=this.$el.outerHeight(),this.contentRect.offsetWidth=this.$el.outerWidth(),this.lastContentRect||(this.lastContentRect=n.clone(this.contentRect)),this.contentRect},calculateScrollTop:function(e,t,i,n){return n?e:t-i},checkScrollBounds:function(e,t){if(!this._ignoreScroll){t=t?n.extend({},this.defaults,this.options,t):this.options,e||(e=c.rect());var i,s,o=t.contentRect||this.updateContentRect(),r=t.triggerPadding||0,a=t.contentPadding||0,l=o.offsetHeight,u=o.offsetTop,h=u+l,d=e.windowHeight,p=Math.max(0,e.windowScrollTop),g=p+d;return t.keepInside?(i=p-u,s=h-g):(i=p-h,s=u-g),s>r?(this._scrollTop=this.calculateScrollTop(u-a,h+a,d,l+2*a>d),this.enforceScrollBounds(t),!0):i>r?(this._scrollTop=this.calculateScrollTop(u-a,h+a,d,t.bottom||l+2*a<d),this.enforceScrollBounds(t),!0):(this._scrollTop=!1,this.cancelEnforceScrollBounds(),!1)}},enforceScrollBounds:function(e){var t=null!=e.scrollTop?e.scrollTop:this._scrollTop,i=e.scrollSpeedMs,s=e.debounceMs,o=e.container;s?this._enforceTimeout||(this._enforceTimeout=n.delay(n.bind(function(){null==e.scrollTop&&(t=this._scrollTop),!1!==this.scrollTop&&this.scrollToPosition(t,i,o)},this),s)):this.scrollToPosition(t,i,o)},cancelEnforceScrollBounds:function(){this._enforceTimeout,clearTimeout(this._enforceTimeout),this._enforceTimeout=!1},scrollToPosition:function(e,t,i){this._ignoreScroll||null==e?h.logSaw("PostFormBuilder","scrollToPosition -- returning early",this._ignoreScroll,e):(this._ignoreScroll=!0,o(d,"stop"),o(d,"scroll",{offset:e,container:i,duration:r(t||this.defaults.scrollSpeedMs)}).then(n.bind(function(){this._ignoreScroll=!1},this)))}});n.extend(p.prototype,l.Events),e.exports=p},79281(e,t,i){"use strict";var n=i(71742).extend({name:"AdsPaginationHelper",defaults:{nextAdPos:0},initialize:function(){this.set(this.data)},getNextAdPos:function(){return this.get("nextAdPos")}});e.exports=n},79284(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(71742),r=i(27496),a=o.extend({name:"MessagingNotifier",defaults:{isEnabled:!1,notificationTimeout:5e3,notificationIcon:null},initialize:function(e){n.extend(this.attributes,n.pick(e,n.keys(this.defaults)))},notifyOnUnread:function(e,t){var i=s("New message for %1$s",t.get("name")),n={conversationId:e,channelUuid:t.get("uuid")};this._generateNotification(i,n)},_supportsNotifications:function(){return this.get("isEnabled")&&"Notification"in window},_needsNotificationPermission:function(){return this._supportsNotifications()&&"granted"!==window.Notification.permission&&"denied"!==window.Notification.permission},_isNotificationPermissionGranted:function(){return this._supportsNotifications()&&"granted"===window.Notification.permission},_requestPermission:function(e){window.Notification.requestPermission(e)},_generateNotification:function(e,t){var i,s;this._supportsNotifications()&&(s={icon:this.get("notificationIcon")},this._isNotificationPermissionGranted()?(i=new Notification(e,s))instanceof Notification&&(i.addEventListener("click",n.bind(function(e){r.trigger("messaging:conversation:open:id",t.conversationId,t.channelUuid,"notification"),e.target.close()}),this),n.delay(n.bind(function(){this.close()},i),this.get("notificationTimeout")),this.trigger("notification:display",t.conversationId)):this._needsNotificationPermission()&&this._requestPermission(n.bind(function(i){this.trigger("notification:permission:change","granted"===i),this._generateNotification(e,t)},this)))}});e.exports=a},79348(e,t,i){var n=i(55679),s=i(74692),o=i(48357).animate,r=i(67103),a=i(47709),l=i(51342),c=i(12461),u=i(58521),h=i(21848),d=i(98635),p=i(33595),g=i(37673),f=i(31710),m=i(81203),_=(window.URL||window.webkitURL||window.mozURL||window.msURL||{}).createObjectURL,v=i(47640),b=function(){var e="<p><br></p>",t=["P","FIGURE","H2","BLOCKQUOTE","UL","OL","DIV","PRE"],i=["H2","BLOCKQUOTE","PRE"],b=["PRE"],y=["UL","OL"],w=["P","H2","BLOCKQUOTE","UL","OL","PRE"],C=["IMG","IFRAME","FIGURE","HR"],x={shift:16,enter
1:13,esc:27,backspace:8,delete:46,tab:9,right:39,metaLeft:91,metaRight:93,leftArrow:37,rightArrow:38,upArrow:39,downArrow:40},k=function(e,t){if(!e)throw new Error("A valid element parameter is required to initalize the editor");t=t||{},this.element=e,this.humanKeys=new m,this.keyComboEvents=t.keyComboEvents||new f({element:this.element,humanKeys:this.humanKeys});var i=n.template("<%= title %> (<%= shortcut %>)"),o=n.bind(function(e,t){return i({title:e,shortcut:this.humanKeys.pretty(t)})},this);this.config={labels:{},placeholder:!1,characterLimit:null,onChange:n.noop,onSelection:function(e){},onAsyncImageAdded:function(e,t,i,n){},onAsyncImageFailed:function(){v.warn("Unknown source type for inserting an image.")},onFileAdded:function(e,t,i){},onClientEvent:function(e){},flattenBlocks:!0,smartQuotes:{enabled:!1,config:{}},runIFrameSanitization:!1,mediaHolderClass:"media-holder",mediaHolderCallback:function(e,t,i,s){i.is("hr, img, figure")&&n.isEmpty(i.find("iframe"))&&s.addClass("media-holder-draggable"),s.addClass("media-holder-"+i.prop("tagName").toLowerCase())},mediaHolderEvents:{keydown:n.noop,keyup:n.noop,mousedown:n.noop,mouseup:n.noop,mouseenter:n.noop,mouseleave:n.noop,click:n.noop,dragstart:n.noop},imgKeyAttr:"data-img-key",imgSizeAttrs:{width:"data-orig-width",height:"data-orig-height"},addImgAttrs:{toImg:!1,toImgParent:!1},fakeClass:"fake",mediaKillerMarkup:"<div>×</div>",mediaMoverMarkup:"<div>&#8597;</div>",pasteHook:function(e,t){return!1},blurHook:function(e){return!1},documentMousedownHook:function(e){return!1},filterForSetData:function(e){return e},filterForGetData:function(e){return e},filterRules:{elements:["a","b","i","ul","ol","li","p","h2","blockquote","img","iframe","figure","br","hr","pre","sub","sup","small"],attributes:{a:["href","title"],img:["src","alt","data-orig-width","data-orig-height"],hr:["data-label"],iframe:["src","width","height","frameborder"],figure:["data-orig-width","data-orig-height"]},classnames:{hr:["read-more"]},remove_contents:["style","noscript","script","meta"],protocols:{a:{href:["http","https","mailto"]}}},animateShowControls:function(e){e.element.show()},animateHideControls:function(e){e.element.hide()}
1,linkConfig:{bypassClasses:[],labels:t.labels,onChange:function(){this.onChange.call(this)},onDismiss:function(){this.lastSelection&&(c.restoreSelection(this.lastSelection),H.call(this))}},inlineControlsConfig:{openTray:h.prototype.openTray,closeTray:h.prototype.closeTray,onTrayOpened:function(e){},onTrayClosed:function(e){},keyboardEvents:this.keyComboEvents},formattingControlsConfig:{controls:{bold:{el:"b",className:"bold",command:"bold",type:"inline",title:o("Bold","meta+b"),keyboard:"meta+b"},italic:{el:"i",className:"italic",command:"italic",type:"inline",title:o("Italic","meta+i"),keyboard:"meta+i"},headline:{el:"h2",className:"headline",command:"formatBlock",type:"block",title:o("Headline","meta+shift+2"),keyboard:"meta+shift+2"},link:{el:"a",className:"link",command:"createLink",type:"inline",title:o("Link","meta+k"),keyboard:"meta+k"},strikethrough:{el:"strike",className:"strikethrough",command:"strikethrough",type:"inline",title:o("Strikethrough","meta+shift+6"),keyboard:"meta+shift+6"},orderedList:{el:"ol",className:"ordered-list",command:"insertOrderedList",type:"list",title:o("Ordered List","meta+shift+7"),keyboard:"meta+shift+7"},unorderedList:{el:"ul",className:"unordered-list",command:"insertUnorderedList",type:"list",title:o("Unordered List","meta+shift+8"),keyboard:"meta+shift+8"},blockquote:{el:"blockquote",className:"quote",command:"formatBlock",type:"block",title:o("Blockquote","meta+shift+9"),keyboard:"meta+shift+9"},clear:{el:"",command:"removeFormat",type:"inline",keyboard:"meta+shift+0"},pre:{el:"pre",command:"formatBlock",type:"block",keyboard:"meta+alt+1"},superscript:{el:"sup",command:"superscript",type:"inline",keyboard:"meta+dot"},subscript:{el:"sub",command:"subscript",type:"inline",keyboard:"meta+comma"},small:{el:"small",command:"insertHTML",type:"inline",keyboard:"meta+shift+minus",keyboardInverse:"meta+shift+plus"}},controlsOrder:["bold","italic","headline","link","strikethrough","orderedList","unorderedList","blockquote"],onShow:function(e){n.isFunction(this.animateShowControls)?this.animateShowControls.call(this,e):e.element.show()},onHide:function(e){n.isFunction(this.animateHideControls)?this.animateHideControls.call(this,e):e.element.hide()},onAction:function(e){var t=u.getNodeList();e.setActives(t)}},showStaticControls:!0},n.merge(this.config,t||{}),this.applyCommand=n.bind(N,this),this.inverseCommand=n.bind(O,this),this.animateShowControls=n.bind(this.config.animateShowControls,this),this.animateHideControls=n.bind(this.config.animateHideControls,this),this.onChange=function(e){var t=X.call(this);this.previousRawData!==t&&(K.call(this),this.config.onChange.call(this),this.previousRawData=t)};var d=S(this.config.linkConfig,this);this.linkControl=new r(d);var _=S(this.config.inlineControlsConfig,this);this.inlineControls=new h(_);var b=S(n.defaults({keyboardEvents:this.keyComboEvents},this.config.formattingControlsConfig),this);this.contextualControls=new a(this.applyCommand,this.inverseCommand,b);var y=this.config.formattingControlsConfig.onShow,w=this.config.formattingControlsConfig.onHide,C=S(n.defaults({onShow:function(e){y.apply(this,arguments),e.listener=e.listener||function(t){var i=u.getNodeList();e.setActives(i),document.removeEventListener("mousedown",e.listener,!1)},document.addEventListener("mousedown",e.listener)},onHide:function(e){w.apply(this,arguments),document.removeEventListener("mousedown",e.listener,!1)}},this.config.formattingControlsConfig),this);this.staticControls=new a(this.applyCommand,this.inverseCommand,C),this.dataFilter=new l(this.config.filterRules),this.keyModifiers={shift:!1,meta:!1},this.undoManager=new p(this,n.bind(function(){for(var e in this.mediaTracker){var t=this.mediaTracker[e].updatedSource;if(t){var i=ae.call(this,e);s(i).attr("src",t)}}G.call(this)},this)),this.config.smartQuotes.enabled&&(this.smartQuoter=new g(this,this.config.smartQuotes.config)),this.mediaTracker={},T.call(this)};function S(e,t){return n.mapValues(e,function(e,t){return t.match(/^on[A-Z]/)&&n.isFunction(e)?n.bind(e,this):e},t)}function T(){Y.call(this,e);var t=s("<div />",{"data-js":"editor-wrapper",class:"editor-wrapper"}).css("position","relative"),i=s("<div />",{"data-js":"editor-slot",class:"editor-slot"}).css("position","relative");s(this.element).wrap(t).wrap(i),i=s(this.element).parent(),this.wrapper=i.parent().get(0),this.placeholderElement=s("<div />",{"data-js":"editor-placeholder",class:"editor-placeholder"}).css("position","absolute"),this.placeholderElement.on("click",n.bind(function(e){this.focus()},this)),i.append(this.contextualControls.element),i.append(this.linkControl.element),i.append(this.placeholderElement),i.append(this.inl
1ineControls.element),K.call(this),this.controlBar=s("<div />",{"data-js":"control-bar",class:"control-bar disabled"});var o=s("<div />",{class:"static-controls control"});this.controlBar.append(o),this.controlBar.append(this.staticControls.element);var r=this;o.on("mousedown",function(e){e.preventDefault(),e.stopPropagation();var t=u.getNodeList();r.staticControls.setActives(n.pluck(t,"nodeName"));var i=s(this).position();return r.staticControls.isShown?r.staticControls.hide():r.staticControls.open(i.left+s(this).width()/2,0),r.contextualControls.hide(),r.linkControl.close(),!1}),this.config.showStaticControls&&s(this.wrapper).append(this.controlBar),E.call(this),D.call(this)}function E(){var e=this,i=function(){return e.inlineControls.isTrayOpen||e.contextualControls.isShown||e.staticControls.isShown||e.linkControl.isShown};s(this.element).on("input keydown keyup keypress mousedown mouseup",function(t){e.controlBar.removeClass("disabled"),e.config.onClientEvent.call(e,t)});var o=function(){H.call(this),this.onChange()};s(this.element).on("keydown",function(t){if(t.keyCode===x.shift)e.keyModifiers.shift=!0;else if(n.contains([x.metaLeft,x.metaRight],t.keyCode))e.keyModifiers.meta=!0;else{if(t.keyCode===x.esc)return void(i()&&(e.contextualControls.hide(),e.staticControls.hide(),e.inlineControls.isTrayOpen&&e.inlineControls.toggleTrayWithIntent(!1),t.stopPropagation()));t.keyCode===x.backspace?(R.call(e,t),ie.call(e)):t.keyCode===x.enter&&(A.call(e,t),F.call(e,t),d.browser.safari&&t.shiftKey&&(t.preventDefault(),I.call(e)))}var s=n.contains(n.values(n.omit(x,"enter")),t.keyCode);!P.call(e)||s||e.keyModifiers.meta||(e.keyModifiers.meta=!1,t.preventDefault()),L.call(e,t),H.call(e,t)}),s(this.element).on("keyup",function(t){t.keyCode===x.shift?e.keyModifiers.shift=!1:n.contains([x.metaLeft,x.metaRight],t.keyCode)?e.keyModifiers.meta=!1:t.keyCode===x.enter?ie.call(e):t.keyCode!==x.backspace&&t.keyCode!==x.delete||(z.call(e),n.defer(function(){j.call(e)}));var i=!1;t.keyCode===x.right&&!t.shiftKey&&e.inlineControls&&(i=e.inlineControls.isShown),t.keyCode===x.esc||i||o.call(e)}),s(this.element).on("input",function(){o.call(e)});var r=!1;s(this.element).on("mouseup",function(){r=!1,H.call(e)}),s(this.element).on("mousedown",function(e){r=!0}),document.addEventListener("mousedown",function(t){var i=function(){r=!1,M.call(e),e.controlBar.addClass("disabled")};e.wrapper===t.target||s.contains(e.wrapper,t.target)||e.config.documentMousedownHook(t,i)||i()},!0),document.addEventListener("mouseup",function(t){r&&(H.call(e),r=!1)},!0),s(this.element).on("focus",function(){if(e.controlBar.removeClass("disabled"),!te.call(e)){var i=s(e.element).children(t.join());if(i.length){var o=i.first().get(0);c.setToStart(o)}}n.defer(function(){e.onChange()})}),s(this.element).on("blur",function(t){var s=function(t){if(!i()){var s=u.getSelection();s&&u.isInContext(s,e.element)&&s.removeAllRanges(),H.call(e,function(){e.onChange(),n.isFunction(t)&&t()})}};e.config.blurHook(t,s)||n.defer(s)}),s(this.element).on("paste",function(t){var i=(t.originalEvent||t).clipboardData;i&&(e.config.pasteHook(i,e.keyModifiers.shift)||J.call(e,i),G.call(e),t.preventDefault())}),s(this.element).on("cut",function(t){e.contextualControls.hide(),e.staticControls.hide(),e.linkControl.close(),n.defer(function(){j.call(e),G.call(e),e.onChange()})})}function P(){return!!this.config.characterLimit&&this.element.innerText.length>this.config.characterLimit}function I(){for(var e=te.call(this),t=n.contains(b,e.nodeName)?"\n":"<br>",i=u.isCursorAtEnd(e)&&!u.isCursorAtStart(e)?1:0,s=0;s<i;s++)t+=t;Z.call(this,t)}function F(e){var t,i,o=u.getNodeByNames(b);o&&!this.keyModifiers.shift&&u.isCursorAtEnd(o)&&(t=(i=s(o)).text(),e.preventDefault(),t.match(/\n\n$/)?(n.last(i.contents()).remove(),this.insertNewParagraphAfter(o)):(i.append("\n\n"),c.setToEnd(o)))}function A(e){var t=u.getNodeByNames(["BLOCKQUOTE"]);if(t&&!this.keyModifiers.shift&&u.isCursorAtEnd(t,!0)){var i="P"===t.lastElementChild.nodeName?t.lastChild:null;i&&i.previousSibling&&this.dataFilter.isEmptyElement(i,!0)&&(e.preventDefault(),s(i).remove(),this.insertNewParagraphAfter(t))}}function M(){this.contextualControls.hide(),this.staticControls.hide(),this.linkControl.close(),this.inlineControls.close()}function j(){s(this.element).has(C.join()).length||(s(this.element).find("ul:not(:has(li)),ol:not(:has(li))").remove(),n.some(s(this.element).children().toArray(),function(e){return e.textContent.length>0})||(Y.call(this,""),ie.call(this),K.call(this)))}function R(e){if(u.getSelection().isCollapsed){var t=te.call(this);if(t&&!(c.saveSelection(t).start>0)){var i=s(t).prev().get(0);i&&ve.call(this,i)&&(s(i).remove(),e.preventDefault())}}}function D(){var e=this,t=s(e.element).offset().top,i=null,o=!1,r=function(e){return e.dataTransfer.types&&n.some(e.dataTransfer.types,function(e){return"Files"===e})},a=function(e){return"false"===s(e.target||e.srcElement).attr("contenteditable")},l=function(e,t){return e<t.top+.66*t.height},c=function(e,i){var n=s(i).offset().top-t,o=s(i).get(0).getBoundingClientRect().height;return{element:i,top:n,bottom:n+o,height:o,isAfter:e>n+.66*o}},u=function(){s(e.element).find(".over-top, .over-bottom").each(function(){s(this).removeClass("over-top").removeClass("over-bottom"),""===s(this).attr("class").trim()&&s(this).removeAttr("class")})},h=function(n){var o=null,r=n.pageY-t,a=s(e.element).children();i&&r>i.top&&l(r,i)||(a.each(function(){var e=c(r,this);if(l(r,e)&&(n.target||n.srcElement)!==this)return o=e,!1}),o||((o=c(r,a.last().get(0))).isAfter=!0),o&&i&&i.element===o.element&&i.isAfter===o.isAfter||(u(),i=o))};s(e.element).unbind("dragstart dragenter dragleave dragover dragend drop"),s(e.element).on("dragleave",function(e){u()}),s(e.element).on("dragover",function(e){if(!o)return e.preventDefault(),void e.stopPropagation();n.debounce(h,100)(e.originalEvent),i&&(s(i.element).addClass(i.isAfter?"over-bottom":"over-top"),r(e.originalEvent)&&e.stopPropagation()),e.preventDefault()}),s(e.element).on("dragenter",function(e){e.preventDefault(),r(e.originalEvent)&&(o="file")}),s(e.element).on("dragstart",function(t){if(M.call(e),a(t.originalEvent)){o="media";var i=t.originalEvent.target||t.originalEvent.srcElement,r=t.originalEvent.dataTransfer;if(r){r.effectAllowed="move",r.dropEffect="move";try{var l=s(i).find("img").attr("src")||"";
1l.match(/^\s*data:/)&&(l=""),r.setData("text/uri-list",l),r.setData("text/plain",l)}catch(t){}}n.defer(function(){s(i).addClass("dragging")})}}),s(e.element).on("drop",function(t){var s,o,a;u(),r(t.originalEvent)&&(s=t.originalEvent.dataTransfer.files,o=i.element,a=i.isAfter?1:-1,s.length&&(e.onChange(),n.each(s,function(t){e.config.onFileAdded.call(e,t,o,a)}),H.call(e))),t.stopPropagation(),t.preventDefault()}),s(e.element).on("dragend",function(t){if(a(t.originalEvent)){u();var n=t.originalEvent.target||t.originalEvent.srcElement,r=s(n).data("origHeight"),l=n;if(i&&l!==i.element){var c=s(n).remove();i.isAfter?s(i.element).after(c):s(i.element).before(c),ge.call(e,c)}s(l).animate({height:r},200,function(){s(l).removeClass("dragging")}),e.onChange(),H.call(e)}o=!1})}function $(e,t,i){var n=s(this.element),o=c.saveSelection(this.element);n.find(i).wrap("<"+t+">"),n.find(i).contents().unwrap(),c.restoreSelection(o),window.document.execCommand(e),n.find(t).wrap("<"+i+">"),n.find(t).contents().unwrap(),c.restoreSelection(o)}function N(e,t,o){var r,a,l,h=this,d=function(){window.document.execCommand(e),h.config.flattenBlocks&&U.call(h)};switch(e){case"formatBlock":!function(e){var t=c.saveSelection(h.element),o=u.getRootElements();switch(n.each(i,function(e){u.getNodesByNames(o,[e]).length&&O.call(h,"formatBlock",e)}),V.call(h),e.toLowerCase()){case"blockquote":o=u.getRootElements();var r=[],a=[];o=n.each(o,function(e){n.contains(w,e.nodeName.toUpperCase())?a.push(e):(r.push(a),a=[])}),a.length&&r.push(a),n.each(r,function(t){s(t).wrapAll(document.createElement(e))});break;case"pre":window.document.execCommand("formatBlock",!1,"<"+e+">"),B.call(this);break;default:window.document.execCommand("formatBlock",!1,"<"+e+">")}c.restoreSelection(t)}(t);break;case"createLink":l=c.saveSelection(h.element),!o||o.isAnimating||l.selection.isCollapsed||setTimeout(function(){s(h.linkControl.linkEditInput).focus(),o.closeWithShim(o.element.find(".link").get(0),200,240,function(e,t){var i=e-s(h.wrapper).offset().left,n=t-s(h.wrapper).offset().top;h.linkControl.size(200),h.linkControl.show(i,n),h.linkControl.createLink(l)}),l.selection.removeAllRanges(),h.blur(!0)},30);break;case"insertOrderedList":case"insertUnorderedList":d();break;case"removeFormat":r=h.contextualControls.controls,a=h.contextualControls.getActiveStates(),n.each(a,function(e,t){var i=r[t];e&&O.call(h,i.command,i.el)}),window.document.execCommand("removeFormat");break;case"insertHTML":$.call(this,"underline","U",t);break;default:window.document.execCommand(e)}H.call(this),z.call(this),h.onChange()}function O(e,t){var o=this;switch(e){case"formatBlock":var r=c.saveSelection(this.element);V.call(o),n.each(u.getRootElements(),function(e){o.dataFilter.unBlock(e),"pre"===e.nodeName.toLowerCase()&&(e.innerHTML=e.innerHTML.replace("\n","<br>"));var t=e.nodeName.toUpperCase();if(n.contains(i,t)){var r=s(e).contents();s(r).wrapAll("<p>"),s(e.firstChild).unwrap()}}),c.restoreSelection(r);break;case"insertOrderedList":case"insertUnorderedList":V.call(this);break;case"createLink":window.document.execCommand("unlink");break;case"insertHTML":$.call(this,"underline","U",t);break;default:window.document.execCommand(e)}z.call(this),H.call(this),this.onChange()}function L(e){var t=function(){return!!u.getNodeByNames(["UL","OL"])};e.keyCode===x.tab&&t()&&(e.preventDefault(),e.stopPropagation(),e.shiftKey?(N.call(this,"outdent"),t()||N.call(this,"formatBlock","p")):N.call(this,"indent"))}function B(){var e=u.getNodeByNames(b);e&&s(e).find("br").replaceWith("\n")}function V(){if(u.getNodeByNames(y)){do{window.document.execCommand("outdent")}while(u.getNodeByNames(y));u.getNodeByNames(["H2"])||window.document.execCommand("formatBlock",!1,"<p>"),this.dataFilter.blockifyInlineNodes(this.element)}}function U(){var e=c.saveSelection(this.element),t=u.getNodeList(null,!0);this.dataFilter.unwrapParentBlocks(t),c.restoreSelection(e)}function z(){var e=c.saveSelection(this.element),t=u.getNodeList();this.dataFilter.scrubSpansAndBadAttrs(t)&&e.end>e.start&&c.restoreSelection(e)}function H(e){var t=this;setTimeout(function(){var i=u.getSelection();if(!i)return he.call(t),void(n.isFunction(e)&&e());i.isCollapsed?W.call(t,i):q.call(t,i),he.call(t),ne.call(t),t.config.onSelection.call(t,i),u.isInContext(i,t.element)&&(t.lastSelection=c.saveSelection(t.element)),G.call(t),K.call(t),n.isFunction(e)&&e()},20)}function q(e){if(u.isInContext(e,this.element)){var t=u.getContextCoordinates(s(this.element).parent().parent()),i=u.getNodeList(e);
1this.contextualControls.setActives(n.pluck(i,"nodeName")),this.staticControls.setActives(n.pluck(i,"nodeName")),this.linkControl.close(),this.inlineControls.close(),""!==e.toString().trim()&&t&&!this.staticControls.isShown&&this.contextualControls.open(t.x,t.y)}}function W(e){this.contextualControls.hide();var t=u.getNodeList(e),i=n.find(t,function(e){return"A"===e.nodeName});if(this.linkControl.isValidLink(i)){var o=u.getContextCoordinates(s(this.element).parent().parent(),i);this.linkControl.showOptions(i),this.linkControl.showOverTarget(o.x,o.y)}else this.linkControl.close();this.staticControls.setActives(n.pluck(t,"nodeName"))}function G(){var e=u.getSelection();if(e&&e.isCollapsed&&u.isInContext(e,this.element)){var t=te.call(this);if(t&&"P"===t.nodeName&&this.dataFilter.isEmptyElement(t)&&!this.isEmpty())this.inlineControls.open(t);else if(this.isEmpty()){this.inlineControls.open(t);var i=d.calcTextWidth(this.placeholderElement,this.config.placeholder);this.inlineControls.open(t,i)}else this.inlineControls.close()}else this.inlineControls.close()}function K(){var e=this.isEmpty()?this.config.placeholder:"",t=s(this.placeholderElement);t.html(e);var i=t.outerHeight();i&&s(this.element).css("min-height",Math.max(parseInt(t.css("min-height"),10)||0,i))}function Q(e){var t=this.element.innerText.length,i=this.config.characterLimit;if(t+e.length>=i){var n=i-t,s=n>0?n:0;e=e.slice(0,s)}return e}function J(e){var i="";if(e.items&&e.items.length){var o=n.find(e.items,function(e){return/image\/\w+/.test(e.type)});if(o){var r=o.getAsFile();if(r)return void this.config.onFileAdded.call(this,r)}}n.contains(e.types,"text/html")?i=e.getData("text/html"):(i=e.getData("text/plain"),i=this.dataFilter.filterPlaintext(i,!0)),i=(i=i.replace(new RegExp("</t(d|h)></tr>","g"),"<br></td></tr>")).replace(/\u00a0/g," "),i=this.dataFilter.filterHTML(i),i=this.dataFilter.convertToBrowserSpaces(i),this.config.characterLimit&&(i=Q.call(this,i));var a=document.createElement("div");if(a.innerHTML=i,this.dataFilter.flattenBlocksDown(a,!0),s(a).find(C.join()).remove(),n.some(a.children,function(e){return n.contains(t,e.nodeName)})){var l=u.getSelection(),c=l.getRangeAt(0);c.deleteContents();var h=te.call(this);if(""===s(h).text().trim()){var d=s(h).index(),p=s(h).parent(),g=d+a.children.length-1;s(h).replaceWith(a.children);var f=s(p).children().eq(g).get(0);c.selectNodeContents(f),c.collapse(!1),l.removeAllRanges(),l.addRange(c)}else this.dataFilter.inlinify(a),Z.call(this,a.innerHTML)}else Z.call(this,a.innerHTML);this.onChange()}function Y(e){s(this.element).html(e)}function X(){return s(this.element).html().trim()}function Z(e){if(e){var t=u.getSelection();if(t&&t.focusNode){var i=t.getRangeAt(0);i.deleteContents(),e=this.dataFilter.convertToBrowserSpaces(e);var n=document.createElement("div");n.innerHTML=e;for(var s,o=n.lastChild,r=document.createDocumentFragment();s=n.firstChild;)r.appendChild(s);i.insertNode(r),i.setStartAfter(o),i.collapse(!1),t.removeAllRanges(),t.addRange(i)}else v.warn("Cannot insert without the editor having a cursor or selection")}else v.warn("Cannot insert empty data")}function ee(){var e=te.call(this);if(!e){var i=s(this.element).children(t.join());if(!i.length)return null;e=i.last().get(0)}return e}function te(){var e=u.getSelection()||this.lastSelection;return u.getNodeByNames(t,!0,e)}function ie(){var t=ee.call(this);if(t){if("div"===t.nodeName.toLowerCase())try{window.document.execCommand("formatBlock",!1,"<p>")}catch(e){}}else Y.call(this,e),this.setCursorToStart()}function ne(){s(this.element).children(w.join()).last().get(0)||s(this.element).append(e)}function se(e,t,i,o,r){var a=this,l=function(e){var l,c,u,h,d=n.uniqueId(),p=0===e.lastIndexOf("data:",0)?"file":e;a.mediaTracker[d]={originalSource:p,file:t},c=s("<img />",{src:e}),l=c.get(0),u=(h=s("<figure />")).get(0),c.attr(a.config.imgKeyAttr,d),h.append(c),ce.call(a,u,i,o,r),re.call(a,l,function(i){oe.call(a,l,i),a.config.onAsyncImageAdded.call(a,d,e,t,i||{})}),a.onChange()};if(!e&&t)if(_)l(_(t));else{var c=new FileReader;c.onload=function(e){l(e.target.result)},c.readAsDataURL(t)}else{if("string"!=typeof e)return void a.config.onAsyncImageFailed.call(a);l(e)}}function oe(e,t){var i,o={},r=this.config,a={toImg:e,toImgParent:s(e).parent("figure").get(0)};r.addImgAttrs&&(i=n.reduce(a,function(e,t,i){return!0!==r.addImgAttrs&&!0!==r.addImgAttrs[i]||e.push(t),e},[])),n.isEmpty(i)||!r.imgSizeAttrs||n.isEmpty(t)||(r.imgSizeAttrs.height&&(o[r.imgSizeAttrs.height]=t.height),r.imgSizeAttrs.height&&(o[r.imgSizeAttrs.width]=t.width),s(i).attr(o))}
1function re(e,t){var i=function(e){var i={width:e.naturalWidth,height:e.naturalHeight};n.isFunction(t)&&t.call(this,i)};e.complete?i.call(this,e):s(e).one({"load.getImageAttributes":n.bind(n.partial(i,e),this),error:n.bind(function(){s(e).off(".getImageAttributes"),t.call(this,null)},this)})}function ae(e){return s(this.element).find("img["+this.config.imgKeyAttr+'="'+e+'"]').get(0)}function le(e,t,i){var o=ae.call(this,e);n.isEmpty(i)||o&&oe.call(this,o,i),t&&(s(o).attr("src",t),this.mediaTracker[e].updatedSource=t)}function ce(t,i,n,o){var r;i=i||ee.call(this),r=this.dataFilter.isEmptyElement(i.outerHTML,!0)?0:u.isCursorAtStart(i)?-1:1,n="number"==typeof n?n:r;var a=s(t).get(0),l=pe.call(this,a);ge.call(this,l),n<0?s(i).before(l):n>0?s(i).after(l):0===n&&s(i).replaceWith(l),M.call(this);var h=s(l).nextAll(w.join()).get(0);h||(h=s(e).get(0),s(l).after(h)),o||(this.focus(!0),c.setToStart(h)),ue.call(this,l,!1,H)}function ue(e,t,i){var r=this;t=t||!1,i=i||n.noop;var a=s(e),l=a.find("figure"),c=a.find(".media-button");a.length&&l.length?(t&&c.length&&c.hide(),o(l,{opacity:t?0:[1,0],translateY:t?-25:[0,-25]},{duration:180,easing:"easeOutQuad",complete:function(){l.removeAttr("style")}}),o(e,t?"slideUp":"slideDown",{duration:200,easing:"easeOutQuart",begin:function(){a.css("pointer-events","none")},complete:function(){a.css("pointer-events",""),i.call(r,e)}})):i.call(r)}function he(){var e=this,t=te.call(this);s(t).removeClass(e.config.fakeClass),s(e.element).children("p").each(function(i,n){t!==n&&e.dataFilter.isEmptyElement(n)&&(0===i&&ve.call(e,s(n).next().get(0))||s(n).is(":last-child")&&ve.call(e,s(n).prev().get(0))||ve.call(e,s(n).prev().get(0))&&ve.call(e,s(n).next().get(0))?de.call(e,n):s(n).hasClass(e.config.fakeClass)&&s(n).remove()),void 0!==s(n).attr("class")&&""===s(n).attr("class").trim()&&s(n).removeAttr("class")}),s(this.element).children("."+this.config.mediaHolderClass).each(function(t,i){var n=s(this).next().get(0);n&&!ve.call(e,n)||s(this).after(de.call(e)),s(this).prev().get(0)||s(this).before(de.call(e))})}function de(t){return t=t||s(e).get(0),s(t).addClass(this.config.fakeClass),t}function pe(e){var t=s(e),i=s("<div />",{class:this.config.mediaHolderClass,contentEditable:!1,draggable:!0});t.wrap(i),i=t.parent(),n.isFunction(this.config.mediaHolderCallback)&&this.config.mediaHolderCallback(this,e,t,i);var o=s(this.config.mediaKillerMarkup);if(o.addClass("media-killer"),i.append(o),!i.hasClass("media-holder-draggable")){var r=s(this.config.mediaMoverMarkup);r.addClass("media-mover"),i.append(r)}return i}function ge(e){var t=this,i=e?s(e):s(this.element).find('[contenteditable="false"]'),n=this.config.mediaHolderEvents;i.each(function(e,i){var o=s(i),r=null;o.off("keydown").on("keydown",function(e){n.keydown.call(null,e,o),e.isPropagationStopped()||(e.keyCode!==x.delete&&e.keyCode!==x.backspace||o.remove(),e.preventDefault(),e.stopPropagation())}),o.off("keyup").on("keyup",function(e){n.keyup.call(null,e,o)}),o.on("mousedown",function(e){r=e.originalEvent.target,n.mousedown.call(null,e,o,r)}),o.on("mouseup",function(e){n.mouseup.call(null,e,o,r),s(r).hasClass("media-killer")&&r===e.target&&ue.call(t,o,!0,function(){o.remove(),j.call(t),H.call(t),t.onChange()})}),o.on("mouseenter",function(e){s(e.currentTarget).addClass("show-controls"),n.mouseenter.call(null,e,o,r)}),o.on("mouseleave",function(e){s(e.currentTarget).removeClass("show-controls"),n.mouseleave.call(null,e,o,r)}),o.on("dragstart",function(e){var t=s(r);t.hasClass("media-killer")&&(e.preventDefault(),e.stopPropagation()),o.hasClass("media-holder-draggable")||t.hasClass("media-mover")||(e.preventDefault(),e.stopPropagation()),n.dragstart.call(null,e,o,r)})})}function fe(e){n.each(s(e).find("."+this.config.mediaHolderClass),function(e){s(e).find(".media-killer, .media-mover").remove();var t=s(e).children().first();t.length?s(t).unwrap():(s(e).contents().wrap("<div>"),s(e).children().first().unwrap().contents().unwrap())})}function me(e){var t=this,i=s(e).find("."+this.config.fakeClass+", ."+this.config.fakeClass+"-intent");n.each(i,function(e){t.dataFilter.isEmptyElement(e)&&s(e).remove()})}function _e(){var e=this;n.each(s(this.element).find(C.join()),function(t){var i=u.getParentNodes(t),s=n.some(i,function(e){return n.contains(C,e.nodeName)});be.call(e,t)||s||pe.call(e,t)})}function ve(e){return s(e).hasClass(this.config.mediaHolderClass)}function be(e){var t=s(e).closest("[class="+this.config.mediaHolderClass+"]");return t.length?t.get(0):null}function ye(t,i,o){var r,a;return i=!!n.isBoolean(i)&&i,t=t||ee.call(this),r=s(t)[i?"prev":"next"](),!o&&r.length>0&&this.dataFilter.isEmptyElement(r)?(c.setToStart(r.get(0)),r):(a=s(e).get(0),s(t)[i?"before":"after"](a),c.setToStart(a),a)}return k.prototype.getData=function(e,t){var i=this,o=X.call(this);o=this.config.filterForGetData.call(this,o),this.config.runIFrameSanitization&&(o=this.dataFilter.unSanitizeIFrames(o));var r=document.createElement("div");if(r.innerHTML=o,fe.call(this,r),me.call(this,r),t||s(r).find("["+i.config.imgKeyAttr+"]").removeAttr(i.config.imgKeyAttr),e)for(var a=function(e){var t=s(r).children(":"+e+"-child").get(0);return t&&i.dataFilter.isEmptyElement(t,!0)?t:null},l=function(){return n.compact([a("first"),a("last")])};l().length;)n.forEach(l(),function(e){s(e).remove()});return r.innerHTML},k.prototype.setData=function(e,t,i){t&&(e=this.config.filterForSetData.call(this,e),e=this.dataFilter.filterHTML(e)),this.config.runIFrameSanitization&&(e=this.dataFilter.sanitizeIFrames(e)),Y.call(this,e),i?this.dataFilter.flattenBlocksDown(this.element):this.dataFilter.blockifyInlineNodes(this.element),ie.call(this),_e.call(this),ge.call(this),ne.call(this),this.onChange()},k.prototype.insertData=function(e,t,i){t&&(e=this.dataFilter.filterHTML(e)),Z.call(this,e),i&&this.dataFilter.flattenBlocksDown(u.getNearestElement()),this.onChange()},k.prototype.blur=function(e){return e||M.call(this),s(this.element).blur()}
1,k.prototype.focus=function(e){var t=s(this.element).focus();return e||this.setCursorToEnd(),t},k.prototype.hasFocus=function(){return s(this.element).is(":focus")},k.prototype.setPlaceholder=function(e){this.config.placeholder=e,K.call(this)},k.prototype.insertMedia=function(e,t,i,n){t&&(e=this.dataFilter.filterHTML(e)),ce.call(this,e,i,n),this.onChange()},k.prototype.addControl=function(e){s(this.wrapper).find("[data-js=control-bar]").append(e)},k.prototype.isEmpty=function(){var t=X.call(this);return""===t||"<br>"===t||t===e||"<p></p>"===t},k.prototype.getCurrentElement=function(){return u.getNearestElement()},k.prototype.getAsyncImage=function(e){return ae.call(this,e)},k.prototype.insertAsyncImage=function(e,t,i,n,s){se.call(this,e,t,i,n,s),this.onChange()},k.prototype.updateAsyncImage=function(e,t,i){le.call(this,e,t,i),this.onChange("updateAsyncImage")},k.prototype.setCursorToStart=function(e,t){var i=s(this.element);(e=e&&i.find(e).first().get(0)||i.children().first().get(0))&&c.setToStart(e),t||H.call(this)},k.prototype.setCursorToEnd=function(e,t){var i=s(this.element);(e=e&&i.find(e).last().get(0)||i.children().last().get(0))&&c.setToEnd(e),t||H.call(this)},k.prototype.insertNewParagraphAfter=function(e,t){return ye.call(this,e,!1,t)},k.prototype.insertNewParagraphBefore=function(e,t){return ye.call(this,e,!0,t)},k.prototype.isEmptyElement=function(e){return e=e||ee.call(this),this.dataFilter.isEmptyElement(e)},k.prototype.hasSelection=function(e){return e=e||ee.call(this),u.hasSelection(e)},k.prototype.isCursorAtEnd=function(e){return e=e||ee.call(this),u.isCursorAtEnd(e)},k.prototype.isCursorAtStart=function(e){return e=e||ee.call(this),u.isCursorAtStart(e)},k.prototype.teardown=function(){this.undoManager.teardown(),this.keyComboEvents.off()},k}();e.exports=b},79350(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div class=\"popover popover_menu popover_gradient\"><div class=\"popover_inner\"></div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},79714(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p +=\n__e( headline );\n\n}\nreturn __p\n}").apply(void 0,r(s))},79990(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(26771),r=i(89953),a=i(80160),l=i(86115),c=i(44731),u=i(69661),h=a.extend({url:"/svc/conversations/messages",mixins:[o,r],relations:{messages:c,participants:u},relationsOrder:["participants","messages"],defaults:{id:null,status:null,last_modified_ts:null,last_read_ts:null,participants:null,messages:null,can_send:!0,is_possible_spam:!1,is_blurred_images:!1,lastOpenedDateTs:null,participantUuid:null,unreadCount:0},fetchNonErrorCodes:[404],fetchNoRetryOnErrorCodes:[403,429],isUnread:function(){return this.get("last_modified_ts")>this.get("last_read_ts")},flushMessageQueue:function(e){return this.flushQueue(this.sendMessage,e)},canRetryFetch:function(e){return n.isFinite(e)&&!n.contains(this.fetchNoRetryOnErrorCodes,e)},markAsRead:function(){var e=(new Date).getTime();this.set({last_read_ts:parseInt(e/1e3,10),unreadCount:0})},parse:function(e,t){var i=n.get(e,"response")||e;return n.get(t,"isFetchInbox")&&n.extend(i,this.pick("is_possible_spam","is_blurred_images")),i},destroy:function(e){var t={conversation_id:this.get("id"),participant:this.get("participantUuid")};return e=n.extend({},e,{url:this.url+"?"+s.param(t)}),a.prototype.destroy.call(this,e)},markAsSpam:function(e){e=e||"inline";var t={conversation_id:this.get("id"),participant:this.get("participantUuid"),context:e,type:"spam"};return s.ajax({url:"/svc/conversations/flag",method:"POST",withFormKey:!0,data:t})},fetchConversation:function(e){var t=new s.Deferred,i=function(){t.resolve.apply(this,arguments)},o=function(){t.reject.apply(this,arguments)};return this.fetch(this._getFullFetchOptions(e)).then(n.bind(i,this)).fail(n.bind(function(e,t){var s=n.get(e,"status");this.isNew()&&n.contains(this.fetchNonErrorCodes,s)?i.call(this,{},t):o.apply(this,arguments)},this)),t},poll:function(e,t){var i;return this.isNew()?(new s.Deferred).reject():(i={participant:this.get("participantUuid"),conversation_id:this.get("id")},t&&n.extend(i,{limit:t}),this.get("messages").poll({isPolling:!0,data:i}))},getConversationDataForMessage:function(){var e={participant:this.get("participantUuid")};return this.isNew()?n.extend(e,{participants:this.getParticipantsIds()}):n.extend(e,{conversation_id:this.get("id")}),e},addMessage:function(e,t){return t=t||{},e.set(this.getConversationDataForMessage()),this.get("messages").add(e),e},sendMessage:function(e,t){return t=t||{},e.set(this.getConversationDataForMessage()),e.save(null,t).then(n.bind(function(e){var i=this.parse(e,t);this.isNew()?this.set(n.omit(i,"messages")):this.set(n.pick(i,"is_possible_spam"))},this))},getParticipantModel:function(){return this.get("participants").get(this.get("participantUuid"))},getParticipantId:function(){return this.get("participantUuid")},getParticipantsIds:function(){return this.get("participants").pluck("uuid")},getOtherParticipant:function(){var e=this.get("participants").getWithout([this.getParticipantId()]);return n.first(e)},getInboxMessage:function(){var e=this.get("messages").where({isError:!1});return n.last(e)},isSameConversation:function(e){var t=e.getParticipantId(),i=e.getParticipantsIds(),s=this.getParticipantId(),o=this.getParticipantsIds();return s===t&&n.union(o,i).length===o.length},unblurImages:function(){this.set("is_blurred_images",!1);var e={conversation_id:this.get("id"),participant:this.get("participantUuid"),type:"unblur"};s.ajax({url:"/svc/conversations/flag",method:"POST",withFormKey:!0,data:e})},shouldBlurImageMessage:function(e){return!(!this.get("is_blurred_images")||!e.isImage())&&e.get("participant")!==this.getParticipantId()},_getFullFetchOptions:function(e){var t=this.isNew()?this._getDataForFetchByParticipants():this._getDataForFetchById();return t=n.extend({},t,{participant:this.get("participantUuid")}),n.extend({},e,{isFetching:!0,cache:!1,reset:!0,data:t})},_getDataForFetchById:function(e){return{conversation_id:this.get("id")}},_getDataForFetchByParticipants:function(e){return{participants:this.getParticipantsIds()}}},{createPostMessage:function(e,t,i){return i=n.extend({},i,{type:l.POST,post:{blog:t,id:e,is_nsfw:n.get(i,"is_nsfw",!1)}}),new l(n.omit(i,"is_nsfw"))},createTextMessage:function(e,t){return t=n.extend({},t,{type:l.TEXT,message:e,content:{text:e}}),new l(t)},createImagePostMessage:function(e,t,i,n,s,o){var r=h.createPostMessage(e,t,o),a=r.getPost();return a.setType("photo"),a.addThumbnail(i,n,s),r},createImageMessage:function(e,t,i,s,o){return o=n.extend({},o,{type:l.IMAGE,file:t,image:{original_size:{width:i,height:s,url:e}}}),new l(o)},createStickerMessage:function(e,t,i,s){return s=n.extend({},s,{type:l.STICKER,sticker_id:e,sticker:{url:t,original_size_url:i}}),new l(s)}});e.exports=h},80158(e,t,i){var n=i(81515),s=i(50283),o=i(68592),r=s.extend({template:o,className:"status-indicator-wrapper",initialize:function(e){this.set({isOnline:e.isOnline&&e.canSeeUIFlag,ariaText:n("%1$s is online",e.name)})},render:function(){return this.get("isOnline")?s.prototype.render.call(this):this}});e.exports=r},80160(e,t,i){"use strict";var n=i(21391),s=i(13752),o=i(71827),r=n.Model.extend({});s.applyTo(r.prototype),o.applyTo(r),e.exports=r},80234(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '';\nwith (obj) {\n__p += '<div class=\"post_animated_heart post_poof' +\n((__t = ( liked ? '' : ' unliked' )) == null ? '' : __t) +\n'\"><span class=\"heart_left\"></span><span class=\"heart_right\"></span></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},80270(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(27496),r=i(13482),a=i(97030),l=i(56556),c=i(4432),u=s.extend({tagName:"li",className:"item",template:c,mixins:[r,a],defaults:{followSource:"FOLLOW_SOURCE_RECOMMENDED_BLOG",wordedFollowButton:!1},events:{"click .follow_list_item_blog":"onPeeprOpen","click .icon_close"
1:"dismissClicked"},initialize:function(e){this.options=n.defaults(e,this.defaults),this.options.primaTumblelogPopover&&this.isLoggedIn()&&this.$el.hoverIntent({over:n.bind(this.showBlogCardPopover,this),out:n.noop,sensitivity:3}),n.extend(this.events,{"click [data-follow-button]":this.isLoggedIn()?"followClicked":this.redirect("/register?redirect_to=/"+this.options.pageUrl)}),this.delegateEvents(),this.bindEvents()},bindEvents:function(){this.listenTo(this.model,"change:following",this.onFollow)},render:function(){var e=n.extend(this.model.toJSON(),this.options);return this.$el.html(this.template(e)),this.cacheSelectors(),this},cacheSelectors:function(){this.$followButton=this.$el.find("[data-follow-button]"),this.$dismissButton=this.$el.find(".dismiss")},onFollow:function(e,t){this.$followButton.removeClass("hide"),this.$followButton.toggleClass("is-following",t),this.$dismissButton.toggle(!t)},onPeeprOpen:function(){o.trigger("useraction:click:peepr",{model:this.model,loggingData:this.loggingData({userAction:"posts"})})},logRow:function(e){"explore"===this.options.pageUrl&&o.trigger(e,{loggingData:{tumblelog:this.model.get("name"),position:this.$el.index()}})},triggerEvent:function(e,t){o.trigger("recommendedBlogs:"+e,{loggingData:t})},followClicked:function(e){e.preventDefault(),this.triggerEvent("follow",{tumblelog:this.model.get("name"),position:this.$el.index()}),this.logRow("tumblelog:log_follow"),this.model.follow({source:this.options.followSource,pt:this.model.get("pt")})},dismissClicked:function(){this.triggerEvent("dismiss",{userAction:"blog_dismissal"}),this.model.trigger("dismiss",this.model),o.trigger("useraction:dismiss:recommended_tumblelog",{model:this.model,loggingData:this.loggingData({userAction:"blog_dismissal"})})},showBlogCardPopover:function(){if(this.popover&&this.popover.isRendered())return this;this.logRow("TumblelogPopover:log_follow_open"),this.popover=new l({model:this.model,pinnedTarget:this.$el,shift:{x:-120,y:0}}),this.popover.openPopover()}});e.exports=u},80317(e,t,i){var n=i(55679),s=(i(95349),i(17604).sprintf);function o(e){e=n.extend({entries:{},name:"Dictionary"},e),this._hadLastLookup=!1,this._entries=e.entries,this._name=e.name}o.prototype.addEntries=function(e){return n.extend(this._entries,e),this},o.prototype.lookup=function(e){return n.has(this._entries,e)?(this._hadLastLookup=!0,this._entries[e]):(this._hadLastLookup=!1,e)},o.prototype.lookupWithFormatting=function(e){var t;return arguments.length>1?(t=this.lookup(s.apply(this,arguments)),this._hadLastLookup||(t=s.apply(this,function(e,t,i){null!=i||(i=this);var n=e.apply(i,t);return(t=Array.prototype.slice.call(t,1)).unshift(n),t}(this.lookup,arguments,this)))):t=this.lookup(e),t},o.prototype.get=function(e){var t=this.lookupWithFormatting.apply(this,arguments);return!this._hadLastLookup&&this.logMissing,t},o.prototype.getEntries=function(){return n.cloneDeep(this._entries)},e.exports=o},80399(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(91685),r=i(5143).animation,a=o.getComponent("ClickableComponent"),l=o.extend(a,{constructor:function(){a.prototype.constructor.apply(this,arguments),this.player().usingNativeControls()&&this.player().controls(!1)},createEl:function(){return a.prototype.createEl.call(this,"div",{className:"vjs-big-play-button",innerHTML:'<span class="vjs-big-play-button-icon"></span><span class="vjs-big-pause-button-icon"></span></span><span aria-hidden="true"></span>'},{"aria-label":"play video"})},handleClick:function(){this.$el=this.$el||n(this.el()),this.player_.userActive(!0),this.player().usingNativeControls()?this.player().paused()&&(this.player().play(),this.player().controls(!0)):this.togglePlay()},togglePlay:function(){r(this.$el,s.bind(function(e){this.$el.removeClass("poof-play poof-pause")},this)),this.player().paused()?(this.player().play(),this.$el.removeClass("poof-pause").addClass("poof-play")):(this.player().pause(),this.$el.removeClass("poof-play").addClass("poof-pause"))},ready:function(){"Flash"===this.player().techName_&&this.hide()}});e.exports=l},80476(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"carousel-wrapper\"><div class=\"carousel-item-container\"> ';\n _.forEach(post.get('photoset_photos'), function(photo, sequence) { ;\n__p += ' ';\n if (photo.primary_url || redirect_url_primary) { ;\n__p += ' <a target=\"_blank\" href=\"' +\n__e( photo.primary_url ? photo.primary_url : redirect_url_primary ) +\n'\"> ';\n } ;\n__p += ' <img class=\"carousel-item carousel-item-' +\n__e( sequence ) +\n'\" src=\"' +\n__e( photo.high_res ) +\n'\" alt=\"' +\n__e( photo.caption ) +\n'\"> ';\n if (photo.primary_url || redirect_url_primary) { ;\n__p += ' </a> ';\n } ;\n__p += ' ';\n }) ;\n__p += ' </div></div><div data-subview=\"carouselPositionView\"></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},80648(e,t,i){var n=i(55679),s=i(17604).sprintf,o=i(21391),r=i(95093),a=i(53388);i(63696)();var l=i(28017),c=i(95349),u=i(44890),h=i(37552),d=i(6479),p=i(76198),g=i(3640),f=i(47516),m=i(17137),_=i(68921),v=i(40290),b=i(48256),y=i(18675),w=i(22568),C=a.extend({getName:function(){return this.name=l.get("Context/name"),s("Context/%s",this.name)},logs:function(){var e=[i(37569),i(70589),i(27301),i(8133),i(66458),i(27641),i(72627),i(45400),i(88879),i(94386),i(40516),i(49353),i(69843).A,i(71641).A,i(31663),i(25039),i(72790),i(39945),i(87213),i(86602),i(11459)];return n.union(e,a.prototype.logs.apply(this))},constructor:function(){a.apply(this,arguments),this.startHistory(),this.initializeApp()},bootloader:function(e){a.prototype.bootloader.apply(this,arguments),h.init(),c.log("Exec","Bootstrap/DOMEventor"),c.log("Exec","Bootstrap/Legacy"),i(72202)},initializeApp:function(){u.bool("is_mobile_handset")?new v:new p,new g,new f,u.bool("indash_blogs")&&(this.peepr=new m),u.bool("ask_form")&&(this.askForm=new _({user:d()})),u.bool("livephotos_web")&&(this.livePhotos=b.getInstance()),r.locale(l.get("Context.language")),u.bool("lrec_on_blog_pages_peepr")&&(this.yamPlusAd=new y),new w},startHistory:function(e){o.History.started||n.isEmpty(this.routes)||(this.routeFound=o.history.start({pushState:"pushState"in window.history,hashChange:!!e&&!("pushState"in window.history),root:this.root}))}});e.exports=C},80756(e,t,i){"use strict";var n=i(74692),s=i(48357).animate,o=i(71092),r=i(67127),a=i(64491),l=i(98237),c=i(38578),u=i(13714),h=o.extend({className:"post-forms-modal",mixins:[a,l,c],template:u,initialize:function(e){this.set("visible",e&&e.visible),this.get("visible")?this.$el.css({opacity:1,display:"block"}):this.$el.css({opacity:0,display:"none"}),this.$body=n("body"),this.listenTo(this,"change:visible",this._toggleVisible)},show:function(){return this.attributes.visible=!0,this._show()},hide:function(){return this.attributes.visible=!1,this._hide()},setContentSubView:function(e){return this.subViews.content&&(this.stopListening(this.subViews.content),this.subViews.content.remove()),this.subViews.content=e,this.listenTo(e,"prepared",this._onSubViewPrepare),this.listenTo(e,"torndown",this._onSubViewTeardown),this.isRendered()&&this.attachSubView("content"),this},_onSubViewPrepare:function(e){this.show()},_onSubViewTeardown:function(e){this.hide()},_show:function(){return this._disableBodyScroll(),this.$el.css("display","block"),s(this.$el,{opacity:1},{duration:r(100),display:"block"})},_hide:function(){return this._enableBodyScroll(),s(this.$el,{opacity:0}
1,{duration:r(100),display:"none"})},_toggleVisible:function(e,t){t?(this.$el.addClass(this.className+"_visible visible"),this._show()):(this.$el.removeClass(this.className+"_visible visible"),this._hide())},_disableBodyScroll:function(){this.$body.css("overflow","hidden")},_enableBodyScroll:function(){this.$body.css("overflow","")},render:function(){return this.$el.html(this.template(this.attributes)),this.attachSubViews(),this}});e.exports=h},80867(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(21189),r=i(27496),a=i(18356),l=i(30291);var c=function(e){return function(e){return e.has("avatar_url")&&e.has("global_theme_params")}(e)?"/svc/"+e.get("name")+"/posts/highlighted":"/svc/tumblelog_popover/"+e.get("name")};function u(e,t){return o.promise(function(i,o){var r={tumblelog:e.get("name")};s.has(t,"include_member_data")&&(r.include_member_data=t.include_member_data),s.has(t,"include_activity_data")&&s.has(t,"include_member_data")&&(r.include_activity_data=t.include_activity_data),s.has(t,"include_activity_notifications")&&s.has(t,"include_member_data")&&(r.include_activity_notifications=t.include_activity_notifications);n.ajax({data:r,type:"GET",error:function(e,t){o(t)},success:function(t){e.set(t.response),i()},url:"/svc/data/tumblelog",withFormKey:!0})})}var h=l.extend({save_following:function(e,t){t||(t={}),e||(e={}),e.following=!!e.following;var i=this;return t.force||i.get("following")!==e.following?function(e,t,i){var s=n.Deferred(),o={data:{tumblelog:e.get("name"),page_url:window.location.href}};["placement_id","pt","source","context","tlt","offset"].forEach(function(e){i.hasOwnProperty(e)&&(o.data[e]=i[e])});var r=t.following?"/svc/follow":"/svc/unfollow";return n.ajax({beforeSend:function(){i.wait||e.set({following:t.following},i)},cache:!i.force,data:o,error:function(n,o){i.wait||e.set({following:!t.following},i),s.reject(o)},type:"POST",success:function(){i.wait&&e.set({following:t.following},i),s.resolve()},url:r,withFormKey:!0}),s.promise()}(i,e,t).then(s.bindKey(i,"save_following",e)):n.when(i.get("following"))},fetch_popover_data:function(e){e||(e={}),e.is_user_mention=!!e.is_user_mention,e.is_tumblelog_popover=!!e.is_tumblelog_popover;var t=this;return!e.force&&t.has("highlighted_posts")?n.when(t.get("highlighted_posts")):function(e,t){var i=n.Deferred(),o={};return s.has(t,"is_tumblelog_popover")&&(o.is_tumblelog_popover=t.is_tumblelog_popover),s.has(t,"is_user_mention")&&(o.is_user_mention=t.is_user_mention),n.ajax({cache:!t.force,data:o,error:function(e,t){i.reject(t)},type:"GET",success:function(t){s.has(t,"highlighted_posts")||(t={highlighted_posts:t}),e.set(t),i.resolve()},url:c(e),withFormKey:!0}),i.promise()}(t,e).then(s.bindKey(t,"fetch_popover_data",null))},fetch_analytics_data:function(){return u(this,{include_member_data:!0,include_activity_data:!0})},fetch_activity_notifications:function(){return u(this,{include_member_data:!0,include_activity_data:!0,include_activity_notifications:!0})},toggle_spam:function(){return n.ajax({url:"/spam/toggle",type:"POST",data:{tumblelog:this.id},withFormKey:!0})},toggle_nsfw:function(){return n.ajax({url:"/nsfw/toggle",type:"POST",data:{tumblelog:this.id},withFormKey:!0})},toggle_adult:function(){return n.ajax({url:"/adult/toggle",type:"POST",data:{tumblelog:this.id},withFormKey:!0})},toggle_uniblock:function(){return n.ajax({url:"/uniblock/toggle",type:"POST",data:{tumblelog:this.id},withFormKey:!0})},toggle_suspended:function(){return n.ajax({url:"/suspended/toggle",type:"POST",data:{tumblelog:this.id},withFormKey:!0})},follow:function(e){return this.save_following({following:!0},e)},_unfollow:function(e){this.save_following({following:!1},e)},requestUnfollow:function(e){var t=o.defer();return t.promise.then(s.bind(this._unfollow,this,e)).catch(s.noop),t},block:function(){return a.block({blockedTumblelog:this.id})},unblock:function(){return a.unblock({blockedTumblelog:this.id})},toggleSubscription:function(e){var t=this.get("name"),i=!!this.get("is_subscribed"),r={url:"/svc/blog/"+t+"/subscription",type:i?"DELETE":"POST",withFormKey:!0};return e&&(r.data={source:e}),o.promise(function(e,t){n.ajax(s.assign(r,{success:e,error:t}))}).then(s.bind(function(){this.set({is_subscribed:!i})},this))},defaults:null,idAttribute:"name",initialize:function(){this.bindEvents()},bindEvents:function(){var e=this.get("name");this.on("change:following",function(){if(this.previous("following")){var t=this.get("following")?"tumblelog:follow":"tumblelog:unfollow";r.trigger(t,{name:e,loggingData:e})}this._updateSubscriptionStatus()},this),this.on("change:twitter_send_posts",this._updateUserSocial),this.on("change:facebook_opengraph_send_posts",this._updateUserSocial)},_updateSubscriptionStatus:function(){this.get("following")?this.set("can_subscribe",!0):this.set({can_subscribe:!1,is_subscribed:!1})},_updateUserSocial:function(){var e={tumblelog_name_or_id:this.get("name"),page:"tumblelog","tumblelog[facebook_opengraph_send_posts]":this.get("facebook_opengraph_send_posts")?"on":"off","tumblelog[twitter_send_posts]":this.get("twitter_send_posts")?"on":"off"};n.ajax({data:e,type:"POST",url:"/settings/save",withFormKey:!0})},getDisplayName:function(){return this.get("is_legacy_private_channel")?this.get("directory_safe_title"):this.get("name")},parse:function(e){return e},validate:function(){return!1},destroy:function(){return this},fetch:function(){return this},save:function(){return this},url:function(){},urlRoot:function(){}},{collection:null,modelFromToken:function(e){var t=h.getCollection(),i=n.Deferred(),s=t.findWhere({token:e});return s?i.resolve(s):function(e,t){return n.ajax({cache:!t.force,data:t.data,type:"GET",url:"/svc/tumblelog_popover/"+e,withFormKey:!0})}(e,{data:{is_user_mention:!0}
1}).then(function(t){var n=new h(t);n.set({token:e}),i.resolve(n)},function(){i.reject()}),i.promise()}});h.collection=h.getCollection(),e.exports=h},80869(e,t,i){"use strict";var n=i(50283),s=i(14169),o=i(80867),r=n.extend({template:s,defaults:{canSubscribe:!1},events:{click:"__toggleInfoPopover"},initialize:function(e){return this.options=e,this.model||(this.model=new o({name:this.options.tumblelogName})),this.set({canSubscribe:this.model.get("can_subscribe"),isSubscribed:this.model.get("is_subscribed"),isBlocking:this.model.get("is_blocking")}),this.listenTo(this.model,"change:is_subscribed",this.__subscribeActionSuccess),e.infoPopoverOnDemand||this.__createInfoPopover(),this},__subscribeActionSuccess:function(e){if(e.id===this.model.get("name")){var t=this.model.get("is_subscribed");this.$("[data-subscription-indicator]").toggleClass("is-subscribed",t)}},__toggleInfoPopover:function(e){e.preventDefault(),e.stopPropagation(),this.options.infoPopoverOnDemand&&!this.infoPopover&&this.__createInfoPopover(),this.infoPopover.toggle()},__createInfoPopover:function(){this.options.infoPopover&&(this.options.infoPopover.model=this.model,this.options.infoPopover.url=this.model.get("url"),this.options.infoPopover.useRecipient&&(this.options.infoPopover.recipient=this.model.get("name")),this.options.infoPopover.showAsks&&(this.options.infoPopover.asks=this.model.get("asks")),this.options.infoPopover.showAnonymousAsks&&(this.options.infoPopover.anonymous_asks=this.model.get("anonymous_asks")),this.infoPopover=new Tumblr.TumblelogPopover.PopticaInfoPopover(this.options.infoPopover))}});e.exports=r},80874(e,t,i){"use strict";var n=i(80160).extend({defaults:{channel:null},getChannel:function(){return this.get("channel")},setChannel:function(e){return this.set("channel",e)},getId:function(){return this.get("channel").get("uuid")},getPrevChannel:function(){return this.previous("channel")},getPrevProperty:function(e){var t=this.getPrevChannel();return t?t.get(e):null},getPrevId:function(){return this.getPrevProperty("uuid")}});e.exports=n},80965(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}var s=i(55679),o={path:"/",secure:!1,domain:""};function r(e){var t=decodeURIComponent(document.cookie).match(new RegExp(e+"=([^;]+)"));return t&&t.length>1?t[1]:null}function a(e,t,i,r){"object"===n(t)&&(t=JSON.stringify(t));var a=encodeURIComponent(e)+"="+encodeURIComponent(t);if(s.isPlainObject(i)&&(i=!!(r=i)&&r.expires),(r=s.extend({expires:i},o,r)).expires instanceof Date)a+=";expires="+r.expires.toGMTString();else if("number"==typeof r.expires){var l=new Date;l.setTime(l.getTime()+1e3*r.expires),a+=";expires="+l.toGMTString()}if(r.path&&(a+=";path="+encodeURI(r.path)),(r.secure||r.sameSite&&"none"===r.sameSite.toLowerCase())&&(a+=";secure"),r.domain&&(a+=";domain="+encodeURI(r.domain)),r.sameSite){var c=r.sameSite.toLowerCase();"none"!==c&&"lax"!==c&&"strict"!==c||(a+=";samesite="+c)}document.cookie=a}function l(e,t){var i=r(e);try{i=JSON.parse(i)}catch(e){return i}return t?s.get(i,t):i}var c={has:function(e){return new RegExp(e+"=([^;]+)").test(decodeURIComponent(document.cookie))},get:r,set:a,unset:function(e){a(e,"",-1)},getHash:l,setHash:function(e,t,i,n){var o;s.isPlainObject(t)?(n=i,o=t):(o=l(e)||{},s.isPlainObject(o)||(o={}),s.set(o,t,i)),a(e,JSON.stringify(o),n)}};e.exports=c},81203(e,t,i){var n=i(55679),s=function(){var e=["ctrl","meta","alt","shift"],t={37:"LEFT",38:"UP",39:"RIGHT",40:"DOWN",187:"PLUS",61:"PLUS",188:"COMMA",189:"MINUS",173:"MINUS",190:"DOT",32:"SPACE"},i={LEFT:"←",RIGHT:"→",DOWN:"↓",UP:"↑",PLUS:"+",COMMA:",",MINUS:"-",DOT:".",SPACE:"Space"},s={Win:{meta:"ctrl"},Linux:{meta:"ctrl"}},o={Mac:{meta:"⌘",shift:"⇧",alt:"⌥"}},r={Win:"-",Linux:"-",Mac:""},a=function(n){n=n||{},this.modifiers=n.modifiers||e,this.separator=n.separator||"+",this.specialKeys=n.specialKeys||t,this.prettyMapping=n.prettyMapping||i,this.platformModifiers=n.platformsModififiers||s,this.platformPrettyMapping=n.platformPrettyModifiers||o,this.platformPrettySeperators=n.platformPrettySeperators||r};function l(){return navigator.platform.match(/^Win/i)?"Win":navigator.platform.match(/^Mac/i)?"Mac":navigator.platform.match(/^Linux/i)?"Linux":navigator.platform}function c(){return n.extend({},this.prettyMapping,this.platformPrettyMapping[l.call(this)])}function u(){return this.platformModifiers[l.call(this)]||{}}function h(){var e=l.call(this);return n.has(this.platformPrettySeperators,e)?this.platformPrettySeperators[e]:this.seperator}function d(e){return this.specialKeys[e.keyCode]||String.fromCharCode(e.keyCode)}function p(e){return n.filter(this.modifiers,function(t){return e[t+"Key"]}
1)}return a.prototype.translate=function(e){var t=p.call(this,e);return 0===t.length?null:t.concat(d.call(this,e)).join(this.separator)},a.prototype.normalize=function(e){var t=e.split(this.separator),i=u.call(this),s="";return n.each(this.modifiers,function(e){var o=n.indexOf(t,e.toLowerCase()),r=i[e]||e;o>=0&&(s+=r+this.separator,t.splice(o,1))},this),s+t.join(this.separator).toUpperCase()},a.prototype.pretty=function(e){var t=this.normalize(e),i=c.call(this),s=h.call(this);return n.map(t.split(this.separator),function(e){return i[e]||(t=e).charAt(0).toUpperCase()+t.slice(1).toLowerCase();var t},this).join(s)},a}();e.exports=s},81245(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<div class="form-container suggestions"><div class="form-header with-border"><h1 class="form-heading">\' +\n((__t = ( __(\'Does any of this help?\') )) == null ? \'\' : __t) +\n\'</h1></div><div class="suggestions-list"></div><div class="form-group"><button class="chrome big left help-form-dismiss"> \' +\n((__t = ( __(\'Yep, found it\') )) == null ? \'\' : __t) +\n\' </button> <button class="chrome big blue right help-form-submit"><span class="label">\' +\n((__t = ( __(\'No, send my thing\') )) == null ? \'\' : __t) +\n\'</span><span class="Knight-Rider-loader animate"><span class="Knight-Rider-bar"></span><span class="Knight-Rider-bar"></span><span class="Knight-Rider-bar"></span></span></button></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},81299(e,t,i){"use strict";var n=i(55679),s=i(17145).extend({name:"unknown",formatters:{},constructor:function(e){this.options=e||{},n.isFunction(this.formatters)?this.formatters=this.formatters():this.formatters=n.clone(this.formatters||{})},registerFormatter:function(e,t){this.formatters[e]=t},getFormatter:function(e){return n.result(this.formatters,e)},escape:function(e){return e},applyFormatting:function(e,t){return this.escape(e)},postFilter:function(e){return e},render:function(e,t){return this.postFilter(this.applyFormatting(e,t))}});e.exports=s},81441(e,t,i){"use strict";var n=i(59386),s=i(44384).extend({initialize:function(e){this.$video=e.$video||this.$("video[data-crt-video]"),this.video=this.$video[0],this.video&&n.playerFactory([this.video])}});e.exports=s},81512(e,t,i){"use strict";var n=i(69107).extend({tagName:"button",attributes:{"data-js-theme-accent-color-on-white":!0},afterRender:function(){this.listenTo(this,"change:isActive",this._onChangeIsActive),this.listenTo(this,"change:isDisabled",this._onChangeIsDisabled),this._onChangeIsActive(this,this.get("isActive")),this._onChangeIsDisabled(this,this.get("isDisabled"))},_onChangeIsActive:function(e,t){this.$el.toggleClass("active",t)},_onChangeIsDisabled:function(e,t){this.$el.prop("disabled",t)}});e.exports=n},81515(e,t,i){var n=i(55679),s=new(i(80317))({name:"Translations"});var o=n.bind(s.get,s);o.setup=n.once(function(e,t){s.addEntries(n.isObject(e)?e:{}),this.locale=t}),e.exports=o},81826(e,t,i){"use strict";var n=i(55679),s=i(91685),o=s.getComponent("Component"),r=s.extend(o,{sdURL:null,hdURL:null,forceHD:null,isUsingSD:!0,timeIntervalBinding:null,constructor:function(e,t){o.prototype.constructor.call(this,e,t),this.addListeners(e)},addListeners:function(e){this.on("click",this.toggleHDState)},createEl:function(){return this.hdURL=this.player_.options_.crtOptions.hdUrl,this.forceHD=this.player_.options_.forceHD,!this.hdURL||this.forceHD?o.prototype.createEl.call(this,"div",{},{}):(this.player_.addClass("vjs-has-hd-toggle"),o.prototype.createEl.call(this,"div",{className:"vjs-hd-toggle vjs-sd vjs-menu-button vjs-control",innerHTML:"<span>HD</span>"},{}))},currentSource:function(){return this.player_.currentSrc()},toggleSrc:function(){var e;this.isUsingSD?(this.sdURL=this.currentSource(),e=this.hdURL,s.removeClass(this.el_,"vjs-sd"),s.addClass(this.el_,"vjs-hd")):(e=this.sdURL,s.removeClass(this.el_,"vjs-hd"),s.addClass(this.el_,"vjs-sd")),this.isUsingSD=!this.isUsingSD,this.player_.src({src:e,type:"video/mp4"})},toggleHDState:function(){var e=this.player_.currentTime(),t=this.player_.paused(),i=this.player_.muted();this.player_.addClass("vjs-quality-toggling"),this.player_.trigger({type:"resolutionchange",resolution:this.isUsingSD?"hd":"sd"}),n.delay(n.bind(function(){this.player_.pause(),this.toggleSrc(),this.player_.ready(function(){this.player_.one("loadedmetadata",n.bind(function(){this.player_.currentTime(e)},this)),this.timeIntervalBinding=n.bind(function(){this.player_.currentTime()-e>.1&&(this.player_.removeClass("vjs-quality-toggling"),this.player_.off("timeupdate",this.timeIntervalBinding),t&&(this.player_.pause(),this.player_.muted(i))
1)},this),this.player_.on("timeupdate",this.timeIntervalBinding),n.defer(n.bind(function(){this.player_.load(),!1===i&&!0===t&&this.player_.muted(!0),this.player_.play()},this))})},this),300)}});e.exports=r},81899(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p +=\n__e( label );\n\n}\nreturn __p\n}").apply(void 0,r(s))},82192(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(21189),r=i(71742),a=i(69271),l=i(67800),c=i(1100),u=i(37335),h=i(46010),d=r.extend({name:"MessagingWindowManager",defaults:{isInboxOpen:!1,isConversationOpen:!1,inboxAnimationSpeed:100,conversationAnimationSpeed:250,isMultipleOpenWindowsEnabled:!1,conversationPopoversContainerClass:"messaging-conversation-popovers",containerClass:"messaging-conversations-container",openConversationsContainerClass:"messaging-open-conversations",minimizedConversationsContainerClass:"messaging-minimized-conversations",bodyClassConversationsHasOpen:"messaging-conversations-open",bodyClassConversationsHasMinimized:"messaging-conversations-minimized",containerClassConversationsHasOpen:"has-open",containerClassConversationsHasMinimized:"has-minimized",persistenceKeyOpen:"open",persistenceKeyMinimized:"minimized"},initialize:function(e){e=s.extend({},e),s.extend(this.attributes,s.pick(e,s.keys(this.defaults))),s.extend(this,s.pick(e,"eventBus","user","channels","currentBlogModel","keyboardManager","inboxConfig","conversationConfig","persistenceManager")),this.openConversations=new l,this.minimizedConversations=new l,this.onlineStatusModel=new c,this.onlineStatusModel.on("sync",this._setParticipantOnlineStatuses,this),this.listenTo(this.openConversations,"add remove",this._onConversationsCollectionChange),this.listenTo(this.minimizedConversations,"add remove",this._onConversationsCollectionChange),this.listenTo(this.openConversations,"add remove",this._onOpenConversationsCollectionChange),this.listenTo(this.minimizedConversations,"add remove",this._onMinimizedConversationsCollectionChange),this.listenTo(this.openConversations,"add",this._onConversationAdd),this.listenTo(this.openConversations,"remove",this._onConversationRemove),this.listenTo(this.minimizedConversations,"add",this._onConversationAdd),this.listenTo(this.minimizedConversations,"remove",this._onConversationRemove),this.persistenceManager&&this.listenTo(this.persistenceManager,"sync",this._onPersistenceManagerSync)},remove:function(e){this.isInboxOpen()&&this.removeInbox(),this.isConversationOpen()&&this.removeConversations(e)},saveConversationsState:function(e,t){this.persistenceManager&&!this.get("isSyncing")&&this.persistenceManager.save(e.pluck("model"),t)},loadConversationsState:function(){var e,t;this.persistenceManager&&(t=this.persistenceManager.load(this.get("persistenceKeyMinimized")),e=this.persistenceManager.load(this.get("persistenceKeyOpen")),t.then(s.bind(function(e){var t=this;this._addLoadedConversationModels(e,this.minimizedConversations,{isMinimized:!0}),e.length&&setTimeout(function(){t._getOnlineStatusOfParticipants(e)},1e3),this.trigger("conversations:loaded:minimized",e)},this)),e.then(s.bind(function(e){this._addLoadedConversationModels(e,this.openConversations),this.trigger("conversations:loaded:open",e)},this)),o.join(e,t).spread(s.bind(function(e,t){this.trigger("conversations:loaded",e,t)},this)))},_addLoadedConversationModels:function(e,t,i){s.each(e,function(e,n){s.delay(s.bind(function(){this._addLoadedConversationModel(e,t,i)},this),n)},this)},_getOnlineStatusOfParticipants:function(e){this.otherParticipants=e.map(function(e){return e.getOtherParticipant()}),this.onlineStatusModel.fetch({data:{participantIds:this.otherParticipants.map(function(e){return e.get("uuid")})}})},_setParticipantOnlineStatuses:function(e){var t=this;e=e.toJSON(),s.forIn(e,function(e,i){s.find(t.otherParticipants,function(e){return e.get("name")===i}).set("seconds_since_last_activity",e)}),delete this.otherParticipants},_addLoadedConversationModel:function(e,t,i){var n=this._createConversationPopover(e,{skipAnimationOnRender:!0},i),s={isFromPersistence:!0,context:"persistence"};return t.add({model:e,popover:n,options:s},s)},addInbox:function(e,t){var i=this.get("inboxAnimationSpeed");return this.isInboxOpen()||(this.inboxCollection=e,this.inboxPopover=this._createInboxPopover(e),this.trigger("inbox:adding",e,this.inboxPopover,t),i>0?setTimeout(s.bind(function(){this._afterInboxOpened(t)},this),i):this._afterInboxOpened(t),this.listenToOnce(this.inboxPopover,"close",function(){this._onInboxClose(t)}),this.set("isInboxOpen",!0)),this.inboxPopover},removeInbox:function(e){e||(e=this.inboxCollection),e===this.inboxCollection&&this.inboxPopover&&this.inboxPopover.teardown()},isInboxOpen:function(){return this.get("isInboxOpen")},addConversation:function(e,t){var i;return this.get("isMultipleOpenWindowsEnabled")||this.minimizeConversations(!0),i=this._createConversationPopover(e),e.set("lastOpenedDateTs",(new Date).getTime()),this.openConversations.add({model:e,popover:i,options:t}),i},removeConversation:function(e,t){var i=this._getWindowModel(e);this.openConversations.remove(i,{skipAnimation:t})},isConversationMinimized:function(e){var t,i=this.getConversationPopover(e);return!!i&&((t=i.getView())&&t.isMinimized())},removeConversations:function(e){this.openConversations.remove(this.openConversations.models,{skipAnimation:e})},isConversationOpen:function(){return this.get("isConversationOpen")},getConversationPopover:function(e){var t=this._getWindowModel(e);return t?t.getPopover():null},getConversationModelByIdAndParticipant:function(e,t){return this.openConversations.getByIdAndParticipant(e,t)||this.minimizedConversations.getByIdAndParticipant(e,t)},minimizeConversations:function(e){var t=s.clone(this.openConversations.models);s.each(t,function(t){t.getView().minimize(e)})},_createConversationPopover:function(e,t,i){var n,o=s.result(this.conversationConfig,"options"),r=s.get(this.conversationConfig,"constructor"),a=s.get(this.conversationConfig,"popoverOptions"),l=s.bind(function(t){return s.extend({},o,{eventBus:this.eventBus,user:this.user,channels:this.channels,model:e,popoverContainer:t.el,keyboardManager:this.keyboardManager},i)},this);return a=s.extend({},a,{viewConstructor:r,viewOptions:l}
1,t),this.conversationsPopoversContainer||this._createConversationsPopoversContainer(),(n=new u(a)).render(),this._removeTimer&&clearTimeout(this._removeTimer),n},_createInboxPopover:function(e){var t,i=s.result(this.inboxConfig,"options"),n=s.get(this.inboxConfig,"constructor"),o=s.result(this.inboxConfig,"popoverOptions"),r=s.bind(function(t){return s.extend({},i,{eventBus:this.eventBus,collection:e,user:this.user,channels:this.channels,currentBlogModel:this.currentBlogModel,keyboardManager:this.keyboardManager,popoverContainer:t.el})},this);return o=s.extend({},o,{viewConstructor:n,animationSpeed:this.get("inboxAnimationSpeed"),viewOptions:r}),(t=new a(o)).render(),t},_removeConversationPopover:function(e,t){var i=this.get("conversationAnimationSpeed");t||i<=0?e.remove():e.teardown(),this._checkRemoveConversationPopoversContainer(t)},_checkRemoveConversationPopoversContainer:function(e){var t=this.get("conversationAnimationSpeed"),i=function(){var e=this.openConversations.length>0,t=this.minimizedConversations.length>0;e||t||this._removeConversationPopoversContainer()};this._removeTimer&&(clearTimeout(this._removeTimer),this._removeTimer=null),e||t<=0?i.call(this):this._removeTimer=setTimeout(s.bind(function(){i.call(this),this._removeTimer=null},this),t)},_focusNextConversationWindow:function(e){return this._incrementFocusConversationWindow(e,1)},_focusPreviousConversationWindow:function(e){return this._incrementFocusConversationWindow(e,-1)},_incrementFocusConversationWindow:function(e,t){var i,n,o,r,a=[];return a.push.apply(a,this.openConversations.models),a.push.apply(a,this.minimizedConversations.models),!((r=a.length)<2)&&(i=s.indexOf(a,e),!((n=i+=t)>=r||n<0)&&(o=s.get(a,n),!s.isEmpty(o)&&(o.getPopover().focus(),!0)))},_callAfterDelay:function(e,t){t>0?setTimeout(s.bind(e,this),t):e.call(this)},_onConversationAdd:function(e,t,i){s.get(i,"isMoving",!1)||this._afterConversationWindowModelAdded(e,i)},_onConversationRemove:function(e,t,i){var n=s.get(i,"skipAnimation",!1);s.get(i,"isMoving",!1)||this._afterConversationWindowModelRemoved(e,n)},_onPersistenceManagerSync:function(e,t){this._syncFlushData||(this._syncFlushData={}),s.set(this._syncFlushData,e,t),this._syncFlushTimer||(this._syncFlushTimer=setTimeout(s.bind(function(){this._flushSync(this._syncFlushData),delete this._syncFlushTimer,delete this._syncFlushData},this),50))},_flushSync:function(e){var t,i,n=s.get(e,this.get("persistenceKeyOpen"),[]),o=s.get(e,this.get("persistenceKeyMinimized"),[]),r=this.openConversations.pluck("model"),a=this.minimizedConversations.pluck("model"),l=this._getConversationLookupCache(n),c=this._getConversationLookupCache(o),u=this._getConversationLookupCache(r),h=this._getConversationLookupCache(a),d=[],p=[];this.set("isSyncing",!0),s.each(u,s.bind(function(e,t){s.has(l,t)||(s.has(c,t)?p.push(e):d.push(e))},this)),t=s.reduce(h,s.bind(function(e,t,i){return!s.has(c,i)&&s.has(l,i)&&e.push(t),e},this),[]),i=s.reduce(l,s.bind(function(e,t,i){return s.has(u,i)||s.has(h,i)||e.push(t),e},this),[]),s.each(p,s.bind(function(e){this.openConversations.getByConversationModel(e).getView().minimize(!0)},this)),s.each(t,s.bind(function(e){this.minimizedConversations.getByConversationModel(e).getView().unminimize(!0)},this)),s.each(d,s.bind(function(e){this.removeConversation(e,!0)},this)),s.each(i,s.bind(function(e){this.addConversation(e)},this)),this.set("isSyncing",!1)},_getConversationLookupCacheKey:function(e){return[e.getParticipantId()].concat(e.getParticipantsIds()).join(":")},_getConversationLookupCache:function(e){return s.mapKeys(e,this._getConversationLookupCacheKey)},_insertElementAtIndex:function(e,t,i){var n=t.children();0===n.length||0===i?t.prepend(e):i>=n.length?t.append(e):e.insertBefore(s.get(n,i))},_onConversationWindowTab:function(e,t){this._focusNextConversationWindow(e)&&t.preventDefault()},_onConversationWindowShiftTab:function(e,t){this._focusPreviousConversationWindow(e)&&t.preventDefault()},_onMinimizedConversationsCollectionChange:function(e,t,i){s.get(i,"isFromPersistence")||this.saveConversationsState(this.minimizedConversations,this.get("persistenceKeyMinimized"))},_onOpenConversationsCollectionChange:function(e,t,i){s.get(i,"isFromPersistence")||this.saveConversationsState(this.openConversations,this.get("persistenceKeyOpen"))},_onConversationsCollectionChange:function(){var e=this.openConversations.length>0||this.minimizedConversations.length>0;this.set("isConversationOpen",e),this._addBodyClasses(),this._addContainerClasses()},_addBodyClasses:function(){var e=n("body");e.toggleClass(this.get("bodyClassConversationsHasOpen"),this.openConversations.length>0),e.toggleClass(this.get("bodyClassConversationsHasMinimized"),this.minimizedConversations.length>0)}
1,_addContainerClasses:function(){var e=this.conversationsPopoversContainer;e&&(e.toggleClass(this.get("containerClassConversationsHasOpen"),this.openConversations.length>0),e.toggleClass(this.get("containerClassConversationsHasMinimized"),this.minimizedConversations.length>0))},_onInboxClose:function(e){var t=this.get("inboxAnimationSpeed");this.trigger("inbox:removing",this.inboxCollection,this.inboxPopover,e),this.set("isInboxOpen",!1),t>0?setTimeout(s.bind(function(){this._afterInboxClosed(e)},this),t):this._afterInboxClosed(e)},_onChangeConversationMinimized:function(e,t){var i=t?this.openConversations:this.minimizedConversations,n=t?this.minimizedConversations:this.openConversations,s=i.getByConversationModel(e),o=t?"conversation:minimized":"conversation:unminimized",r={isMoving:!0};t||this.get("isMultipleOpenWindowsEnabled")||this.minimizeConversations(!0),i.remove(s,r),n.add(s,r),this.trigger(o,s.getConversation(),s.getPopover())},_afterInboxOpened:function(e){this.trigger("inbox:added",this.inboxCollection,this.inboxPopover,e)},_afterInboxClosed:function(e){this.trigger("inbox:removed",this.inboxCollection,this.inboxPopover,e),this.inboxPopover=null,this.inboxCollection=null},_createConversationsPopoversContainer:function(){return this.conversationsPopoversContainer||(this.conversationsPopoversContainer=n("<div />").addClass(this.get("conversationPopoversContainerClass")),this.openConversationsContainer=new h({collection:this.openConversations,className:[this.get("containerClass"),this.get("openConversationsContainerClass")].join(" ")}).render(),this.minimizedConversationsContainer=new h({collection:this.minimizedConversations,className:[this.get("containerClass"),this.get("minimizedConversationsContainerClass")].join(" "),isScrollEnabled:!0,isAdjustToBrowserHeightEnabled:!0}).render(),this.conversationsPopoversContainer.append(this.openConversationsContainer.$el),this.conversationsPopoversContainer.append(this.minimizedConversationsContainer.$el),n("body").append(this.conversationsPopoversContainer),this._addContainerClasses()),this.conversationsPopoversContainer},_removeConversationPopoversContainer:function(){this.conversationsPopoversContainer&&(this.conversationsPopoversContainer.remove(),this.conversationsPopoversContainer=null),this.openConversationsContainer&&(this.openConversationsContainer.remove(),this.openConversationsContainer=null),this.minimizedConversationsContainer&&(this.minimizedConversationsContainer.remove(),this.minimizedConversationsContainer=null)},_getWindowModel:function(e){return this.openConversations.getByConversationModel(e)||this.minimizedConversations.getByConversationModel(e)},_addConversationWindowEvents:function(e){var t=e.getView();this.listenTo(t,"keydown:tab",function(t){this._onConversationWindowTab(e,t)}),this.listenTo(t,"keydown:shift+tab",function(t){this._onConversationWindowShiftTab(e,t)}),this.listenToOnce(t,"close",function(){this.removeConversation(e.getConversation())}),this.listenTo(t,"change:isMinimized",function(t,i){this._onChangeConversationMinimized(e.getConversation(),i)})},_afterConversationWindowModelAdded:function(e){var t=e.getConversation(),i=e.getPopover(),n=e.getOptions(),s=this.get("conversationAnimationSpeed");this.trigger("conversation:adding",t,i,n),this._addConversationWindowEvents(e),this._callAfterDelay(function(){this.trigger("conversation:added",t,i,n)},s)},_afterConversationWindowModelRemoved:function(e,t){var i=this.get("conversationAnimationSpeed"),n=e.getView(),o=e.getPopover(),r=e.getConversation(),a=e.getOptions(),l=function(){this.trigger("conversation:removed",r,o,a)};this.stopListening(o),this.stopListening(n),this._removeConversationPopover(o,t),this.trigger("conversation:removing",r,o,a),t||i<=0?l.call(this):setTimeout(s.bind(l,this),i)}});e.exports=d},83121(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(50283),r=i(98237),a=i(57505),l=i(78421),c=i(46209),u=o.extend({className:"conversation-message-image",mixins:[r],template:c,defaults:{thumbnailWidth:195,isBlurred:!1,blurClassName:"is-blur",unblurringClassName:"is-unblurring",errorClassName:"is-error",pendingClassName:"is-pending",blurAnimationDurationMs:300,blurMessageString:null},events:{"click [data-js-overlay-container]":"_onOverlayContainerClick"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","participants","conversation","model","setRetryButtonState","afterImageUnblur")),this.set("blurMessageString",s("Blurred because you don't follow this Tumblr yet. Click to reveal.")),this.image=this.model.getImage()},afterRenderSubviews:function(){this.listenTo(this,"change:isBlurred",this._onChangeIsBlurred),this.listenTo(this.model,"change:isPending",this._onModelIsPendingChange),this.listenTo(this.model,"change:isError",this._onModelIsErrorChange),this.listenTo(this.conversation,"change:is_blurred_images",this._onChangeConversationIsBlurredImages),this.listenTo(this.image.getAltSizes(),"update reset",this._onModelImagesUpdate),this._onChangeConversationIsBlurredImages(this.conversation,this.conversation.get("is_blurred_images")),this._onChangeIsBlurred(this,this.get("isBlurred"))},getTemplateData:function(){var e=this.image.getImageAtSize(this.get("thumbnailWidth")),t=this.getThumbnailDimensions(e),i=n.get(t,"width"),s=n.get(t,"height"),o=this.participants.get(this.model.get("participant"));return this.thumbnailUrl=this.thumbnailUrl||e.get("url"),{name:o?o.get("name"):null,avatarUrl:o?o.getAvatarUrl():null,blogUrl:o?o.get("url"):null,highResUrl:this.image.hasAltSizes()?this.image.getHighResImageUrl():null,lowResUrl:this.thumbnailUrl,thumbnailImageUrl:this.thumbnailUrl,originalWidth:this.image.getOriginalSize().get("width"),originalHeight:this.image.getOriginalSize().get("height"),thumbnailWidth:i,thumbnailHeight:s}},getThumbnailDimensions:function(e){var t=this.get("thumbnailWidth"),i=a.heightForWidth(t,e.get("width"),e.get("height"));return n.extend({},{width:t,height:i})},_onModelIsPendingChange:function(e,t){t?(this.imageLoaderView=new l({variation:"small centered",loading:t}),this.js$("image-loader-container").append(this.imageLoaderView.render().$el)):this._removeImageLoader(),this.$el.toggleClass(this.get("pendingClassName"),t)},_onModelIsErrorChange:function(e,t){this.$el.toggleClass(this.get("errorClassName"),t)},_removeImageLoader:function(){this.imageLoaderView&&this.imageLoaderView.remove()},_onModelImagesUpdate:function(){this.renderWithTemplate(),this._toggleBlurred(this.get("isBlurred")),n.isFunction(this.setRetryButtonState)&&this.setRetryButtonState()},_toggleBlurred:function(e){var t=this.get("unblurringClassName"),i=this.js$("overlay-text",!0),s=!e&&this.previous("isBlurred"),o=this.get("blurClassName");this.$el.toggleClass(o,e).toggleClass(t,s),e?i.text(this.get("blurMessageString")):s||i.empty(),this._unblurTimer&&clearTimeout(this._unblurTimer),s&&(this._unblurTimer=n.delay(n.bind(function(){this.rendered&&(i.empty(),this.$el.removeClass(t),delete this._unblurTimer)},this),this.get("blurAnimationDurationMs")))},_onChangeIsBlurred:function(e,t){this._toggleBlurred(t)},_onChangeConversationIsBlurredImages:function(e,t){this.set("isBlurred",t&&e.shouldBlurImageMessage(this.model))},_onOverlayContainerClick:function(e){this.get("isBlurred")&&(e.preventDefault(),e.stopImmediatePropagation(),this.set("isBlurred",!1),n.isFunction(this.afterImageUnblur)&&this.afterImageUnblur(this.model))}});e.exports=u},83195(e,t,i){"use strict";var n=i(92531);e.exports=n},83331(e,t,i){"use strict";var n=i(80160).extend({defaults:{text:null,formatting:[]}});e.exports=n},83792(e,t,i){"use strict";var n=i(55679),s=i(17604).sprintf,o=i(71092),r=i(28724),a=i(21189),l=i(27496),c=i(81515),u=i(18398),h=i(85252),d=i(70241),p=["add","submit","send","done","fail","always","progress","progressall","start","stop","change","paste","drop","dragover","chunksend","chunkdone","chunkfail","chunkalways"],g=["add","send","progress","active","enable","disable"],f=o.extend({tagName:"input",attributes:{type:"file"},defaults:{name:"photo",maxUploadSize:!1,uploadPattern:!1,mediaType:"image",f
1ileUpload:{singleFileUploads:!0,limitConcurrentUploads:1,sequentialUploads:!1,autoUpload:!0,formData:[],dataType:"json",dropZone:null,pasteZone:null}},_createUploadModel:function(e,t){var i=new h(e);return this.collection.add(i,t||{}),i},_createUploadModelForFile:function(e,t,i){t=n.extend({file:e},t);var s=this._createUploadModel(t,i);return e._uploadModel=s,s},initialize:function(e){if(this.defaults.message={cancel:c("Canceled upload"),error:c("Upload error"),filesize:c("The file is too big. Squish it down, and try again!"),filetype:{image:c("This is not a valid image file."),video:c("This is not a valid video file."),audio:c("This is not a valid audio file."),default:c("This is not a supported file.")}},this.options=n.merge({},this.defaults,e),this.options.url&&(this.options.fileUpload.url=this.options.url),this.options.collection?this.collection=this.options.collection:this.collection=new u,!this.options.fileUpload.url)throw new Error("Upload requires an endpoint URL");this.$el.prop("tabindex",-1),this.options.fileUpload.multiple&&this.$el.prop("multiple",!0),this.options.accept&&this.$el.prop("accept",this.options.accept);var t=n.merge({},this._fileUploadWrap);n.forEach(p,function(e){n.isFunction(t.defaults[e])||(t.defaults[e]=n.noop)},this),new r(t).applyTo(this.options.fileUpload),n.forEach(p,function(e){this.options.fileUpload[e]=d(this.options.fileUpload[e],this)},this),this.$el.attr("name",this.options.name).fileupload(this.options.fileUpload),this._fileUpload=this.$el.data("blueimp-fileupload"),n.forEach(g,function(e){this[e]=function(){var t=n.toArray(arguments);t.unshift(e),this._fileUploadInvoke.apply(this,t)}},this)},_fileUploadInvoke:function(e){return this._fileUpload[e].apply(this._fileUpload,n.rest(arguments))},validateFile:function(e,t){t||(t=this.options);var i=[];return t.maxUploadSize&&e.size>t.maxUploadSize&&(l.trigger("postform-interaction:upload-limit-hit",{loggingData:{fileSize:e.size,fileType:e.type,maxSize:t.maxUploadSize}}),i.push({type:"filesize",message:s(t.message.filesize,t.maxUploadSize)})),t.uploadPattern&&e.type&&!t.uploadPattern.test(e.type)&&i.push({type:"filetype",message:t.message.filetype[t.mediaType]||t.message.filetype.default}),i},upload:function(e){this.add({files:[e]})},cancel:function(){var e;return this.jqXHR?(e=this.jqXHR.abort(),this.jqXHR=null):e=a.reject(this.options.message.cancel),e},_forMatchingFiles:function(e,t){var i=n.rest(arguments);this.collection.forEach(function(s){if(n.contains(e,s.get("file"))){var o=n.clone(i);o[0]=s,t.apply(this,o)}},this)},promise:function(){return this.collection.promise()},_fileUploadWrap:{defaults:{change:function(e,t,i){this._fileUpload.options.replaceFileInput&&this.setElement(e)},add:function(e,t,i){var s=i.files[0],o=this.validateFile(s),r={},a={};if(!n.isEmpty(o)){r.error=n.pluck(o,"message"),r.file=s;var l={errorType:"validation",messages:o,file:s};this.collection.trigger("invalid",this.collection,new this.collection.model(r)),this.trigger("error",l),a.silent=!0}return this._createUploadModelForFile(s,r,a),n.isEmpty(o)},send:function(e,t,i){return!0}},before:{},after:{done:function(e,t,i){var s,o=n.get(i,"result.meta.status"),r=n.get(i,"result.response"),a=n.get(i,"result.errors");200!==o||n.isEmpty(r)?s={error:r&&r.msg?r.msg:n.isArray(a)?n.isEmpty(a)?c("Woops :("):a:a.join(" "),uploading:!1}:(n.isArray(r)&&(r=r[0]),s=n.extend({complete:!0,uploading:!1},r));this._forMatchingFiles(i.files,function(e,t){e.set(t)},s)},fail:function(e,t,i){var s;(s="abort"===i.errorThrown?{uploading:!1}:{error:this.options.message.error,uploading:!1}).responseJSON=n.get(i,"jqXHR.responseJSON"),this._forMatchingFiles(i.files,function(e,t){e.set(t)},s)},progress:function(e,t,i){this._forMatchingFiles(i.files,function(e,t){e.set(t)},{bytesLoaded:i.loaded,bytesTotal:i.total})}},around:{add:function(e,t,i,s){var o=e.apply(this,n.rest(arguments));return!1!==o&&!i.isDefaultPrevented()&&((s.autoUpload||!1!==s.autoUpload&&this._fileUpload.options.autoUpload)&&s.process().done(n.bind(function(){this.jqXHR=s.submit()},this)),o)},send:function(e,t,i,s){s.withFormKey=!0;var o=e.apply(this,n.rest(arguments));if(o){this._forMatchingFiles(s.files,function(e,t){e.set(t)},{uploading:!0});var r={files:s.files};this.collection.trigger("send",this.collection,r),this.trigger("send",r)}return o}}}});e.exports=f},84088(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(81515),r=i(79714),a=s.extend({tagName:"li",className:"section_header no_pu
1sh recommended-blogs-unit-header",template:r,defaults:{headline:"Recommended Blogs"},initialize:function(e){this.options=n.defaults({},e,this.defaults)},render:function(){return this.$el.html(this.template({headline:o(this.options.headline)})),this}});e.exports=a},84315(e,t,i){"use strict";var n=i(17145),s=i(55679),o=n.extend({soloId:null,constructor:function(){this.keySets=[],this.soloBubblingWhitelist=[]},add:function(e){this.keySets.unshift(e)},remove:function(e){var t=this.getSetForId(e);t&&(this.unSolo(e),this.keySets=s.without(this.keySets,t),this.soloBubblingWhitelist=s.without(this.soloBubblingWhitelist,e))},focus:function(e){var t=this.getSetForId(e);t&&(this.keySets=s.without(this.keySets,t),this.keySets.unshift(t))},unfocus:function(e){var t=this.getSetForId(e);t&&(this.keySets=s.without(this.keySets,t),this.keySets.push(t))},solo:function(e,t){this.getSetForId(e)&&(this.soloId=e,!0===t&&this.soloBubblingWhitelist.push(e))},unSolo:function(e){this.soloId===e&&(this.soloId=null,this.soloBubblingWhitelist=s.without(this.soloBubblingWhitelist,e))},getSetForId:function(e){return this.keySets[s.findIndex(this.keySets,{id:e})]},getSetsWithKey:function(e){return s.where(this.keySets,{keys:[e]})},shouldRun:function(e,t){var i=this.getSetsWithKey(e);return this.soloId===t||!(!s.isEmpty(this.soloBubblingWhitelist)&&!s.contains(this.soloBubblingWhitelist,t))&&(!(i.length>1)||i[0].id===t)}});e.exports=new o},84342(e,t,i){"use strict";i(55679);var n=i(95921).truncateLongStrings;function s(){}s.prototype.genericFieldMap={one:"ask",two:"answer",three:"caption"},s.prototype.editorField="three",s.prototype.typeAttributes={ask:"",answer:"",caption:""},s.prototype.generateTweetText=function(e,t){return n(this.getHtmlStripped("ask"),t)},s.prototype.validate=function(e,t,i){var n=[];return t.ask||n.push("Post question empty."),e.call(this,t,{errors:n})},e.exports=s},84464(e,t,i){"use strict";var n=i(74692),s=i(21189),o=i(55679),r=i(71742),a=i(79990),l=r.extend({name:"MessagingWindowPersistence",defaults:{storageKeyPrefix:"messaging",isSyncEnabled:!1},initialize:function(e){e=o.extend({},e),o.extend(this.attributes,o.pick(e,o.keys(this.defaults))),o.extend(this,o.pick(e,"user")),this.get("isSyncEnabled")&&this._addSyncListeners()},save:function(e,t){var i,n=s.defer(),r=this._getStorageKey(t);return i=o.map(e,this._getObjectFromModel),this._saveLocalStorage(r,i),n.resolve(),n.promise},load:function(e){var t=s.defer(),i=this._getStorageKey(e),n=this._loadLocalStorage(i),r=o.map(n,this._getModelFromObject);return t.resolve(r||[]),t.promise},clear:function(){var e,t=window.localStorage;if(t){e=this._getStorageKey();try{o.each(o.keys(t),function(i){o.startsWith(i,e+":")&&t.removeItem(i)})}catch(e){this._triggerError(e)}}},remove:function(){this.get("isSyncEnabled")&&this._removeSyncListeners()},_addSyncListeners:function(){n(window).on("storage.messaging-window-persistence",o.bind(this._onStorageChange,this))},_removeSyncListeners:function(){n(window).off(".messaging-window-persistence")},_onStorageChange:function(e){var t,i,n=o.get(e,"originalEvent.key"),s=o.get(e,"originalEvent.newValue"),r=this._getStorageKey(),a=n.substring(r.length+1);if(!o.isEmpty(n)&&!o.isEmpty(a)&&o.startsWith(n,r)&&!o.isEmpty(s))try{t=JSON.parse(s),i=o.map(t,this._getModelFromObject),this.trigger("sync",a,i),this.trigger("sync:"+a,i)}catch(e){this._triggerError(e)}},_getStorageKey:function(e){var t=[this.get("storageKeyPrefix"),this.user.get("name"),e];return o.compact(t).join(":")},_saveLocalStorage:function(e,t){if(window.localStorage)try{window.localStorage.setItem(e,JSON.stringify(t))}catch(e){this._triggerError(e)}},_loadLocalStorage:function(e){var t;if(!window.localStorage)return[];try{return t=window.localStorage.getItem(e),o.isEmpty(t)?[]:JSON.parse(t)}catch(e){return this._triggerError(e),[]}},_getObjectFromModel:function(e){var t=["uuid","url","name","avatar_url","theme"],i=e.get("participants").map(function(e){return e.pick(t)});return{id:e.get("id"),participantUuid:e.get("participantUuid"),participants:i,lastOpenedDateTs:e.get("lastOpenedDateTs")}},_getModelFromObject:function(e){return new a(e)},_triggerError:function(e){this.trigger("error",e)}});e.exports=l},84549(e,t,i){"use strict";var n=i(3021),s=i(36301),o=i(39779),r=i(69053);function a(e){switch(e.model.get("type")){case"photo":return new s(e);case"photoset":return new o(e);case"audio":return new r(e);case"video":return new n(e);case"regular":if(e.el.has("video"))return new n(e)}}a.prototype.shouldAttachAsSubview=!1,e.exports=a},84701(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(15991),r=i(59952),a=i(98237),l=i(25256),c=i(64147),u=s.extend({className:"popover--blog-selector-dropdown",events:{"click [data-js-tumblelog]":"selectBlog"},mixins:[a,r],template:o,defaults:{currentTumblelog:!1,avatarSize:96,badgeCountField:null,maxBadgeCount:99,badgeActiveClass:"tab-notice--active"},initialize:function(e){if(e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"collection")),!this.get("currentTumblelog")){var t=this.collection.findWhere({is_current:!0});this.set("currentTumblelog",t)}},selectBlog:function(e){var t=this.$(e.currentTarget).index();this.set("currentTumblelog",this.collection.at(t)),this.teardown()},createScrollbar:function(){this.scrollbar||(this.scrollbar=new c(this.js$("scrollbar")))},afterRender:function(){return this.js$("scrollbar").addClass("popover-sublist popover-sublist--scrollable"),n.defer(n.bind(this.createScrollbar,this)),this.delegateEvents(),this.isShowBadges()&&this.listenTo(this.collection,"change:"+this.get("badgeCountField"),this._onBadgeCountChange),this},isShowBadges:function(){return!n.isEmpty(this.get("badgeCountField"))},getBadgeCount:function(e){return this.get("badgeCountField")&&e?e.get(this.get("badgeCountField")):null}
1,getBadgeCountString:function(e){var t=this.get("maxBadgeCount");return e<=0?"":e>t?t+"+":e},getTemplateData:function(){var e,t=this.toJSON(),i=this.get("currentTumblelog");return i&&n.extend(t,{currentTumblelog:i.get("name")}),e=this.collection.map(function(e){return n.extend({avatarUrl:l(e.get("avatar_url"),this.get("avatarSize")),displayName:e.getDisplayName(),badgeCountString:this.getBadgeCountString(this.getBadgeCount(e))},e.toJSON())},this),n.extend(t,{channels:e,isShowBadges:this.isShowBadges()}),t},beforeTeardown:function(){this.scrollbar&&(this.scrollbar.destroy(),this.scrollbar=null),this.stopListening()},teardown:function(){return this.remove()},updateBadge:function(e){var t,i=this.$$("[data-js-channel-badge="+e.get("name")+"]");0!==i.length&&(t=this.getBadgeCount(e),i.toggleClass(this.get("badgeActiveClass"),t>0),t>0&&i.find("[data-js-channel-badge-text]").text(this.getBadgeCountString(t)))},_onBadgeCountChange:function(e){return this.updateBadge(e)}});e.exports=u},84970(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(95852),r=s.extend({className:"conversation-preview-image",template:o,defaults:{width:null,height:null,src:null,context:null,loggingData:null},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults)))}});e.exports=r},85176(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(80160),r=i(28017),a=i(93405),l=o.extend({url:function(){return"/svc/post/share/"+this.get("tumblelog_name")+"/"+this.get("post_id")},parse:function(e){return!s.isUndefined(e)&&s.has(e,"response")&&s.result(e.response,"share_popover_data")||{}},hostname:function(){var e=r.get("Context/hosts");return s.isEmpty(e)?"":e.www_host},defaults:{abuse_url:"",embed_code:"",embed_did:"",form_key:n("#tumblr_form_key").attr("content"),has_facebook:!1,has_user:!1,is_private:!1,permalink_label:"",post_id:"",post_tiny_url:"",post_url:"",root_id:"",show_email:!0,show_embed:!0,show_facebook:!0,show_permalink:!0,show_pinterest:!0,show_reporting_links:!0,show_t
1witter:!0,show_reddit:!0,show_flagging:!0,tumblelog_name:"",twitter_username:"",embed_key:"",pinterest_share_window:{},tumblelog_share:!1},initialize:function(e){this.get("embed_code")||this.set("embed_code",new a(this.toJSON()).getCode())},shareEmail:function(e){return this.get("tumblelog_share")?this.share("/svc/email_tumblelog",e):this.share("/svc/share/email",e)},shareTwitter:function(e){if(!this.get("tumblelog_share"))return this.share("/svc/share/twitter",e)},shareFacebook:function(e){if(!this.get("tumblelog_share"))return this.share("/svc/share/facebook",e)},sharePinterest:function(e){return this.share("/svc/share/pinterest",e)},shareReddit:function(e){return this.share("/svc/share/reddit",e)},facebookStatus:function(){return n.ajax({url:this.hostname()+"/svc/facebook_status",type:"post",data:{form_key:this.get("form_key")}})},share:function(e,t){return(t=t||[]).push({name:"form_key",value:this.get("form_key")}),n.ajax({url:this.hostname()+e,type:"post",data:t,success:s.bind(function(){this.trigger("success")},this),error:s.bind(function(){this.trigger("error")},this)}),this}});e.exports=l},85179(e,t,i){"use strict";var n=i(55679),s=new(i(28724))({defaults:{hasSelection:function(e){return this._validateParams(e)?n.has(this._selectedIndexes,e):null},getSelectedIndex:function(e){return this._validateParams(e)?n.get(this._selectedIndexes,e,0):null},deselect:function(e){this._validateParams(e)&&this.hasSelection(e)&&delete this._selectedIndexes[e]},resetSelected:function(e){this._validateParams(e)&&this.setSelectedIndex(e,0)},setSelectedIndex:function(e,t){var i;return this._validateParams(e)?(i=n.get(this,e,[]),t=Math.max(0,Math.min(t,i.length-1)),n.set(this._selectedIndexes,e,t),t):null},getSelectedView:function(e){var t;return this._validateParams(e)?(t=n.get(this,e,[]),n.get(t,this.getSelectedIndex(e))):null},isFirstSelected:function(e){return this._validateParams(e)?0===this.getSelectedIndex(e):null},isLastSelected:function(e){var t;
1return this._validateParams(e)?(t=n.get(this,e,[]),this.getSelectedIndex(e)===t.length-1):null},selectFirst:function(e){var t;if(!this._validateParams(e))return null;t=n.get(this,e,[]);var i=this.setSelectedIndex(e,0);return n.get(t,i)},selectLast:function(e){var t;if(!this._validateParams(e))return null;t=n.get(this,e,[]);var i=this.setSelectedIndex(e,t.length-1);return n.get(t,i)},selectNext:function(e){var t,i;return this._validateParams(e)?this.hasSelection(e)?(t=n.get(this,e,[]),i=this._increaseSelectedIndex(e),n.get(t,i)):this.selectFirst(e):null},selectPrevious:function(e){var t,i;return this._validateParams(e)?(t=n.get(this,e,[]),i=this._decreaseSelectedIndex(e),n.get(t,i)):null},_validateParams:function(e){return!!e},_increaseSelectedIndex:function(e){return this._validateParams(e)?this.setSelectedIndex(e,this.getSelectedIndex(e)+1):null},_decreaseSelectedIndex:function(e){return this._validateParams(e)?this.setSelectedIndex(e,this.getSelectedIndex(e)-1):null}},before:{initialize:function(){this._selectedIndexes={}}}});e.exports=s},85252(e,t,i){"use strict";var n=i(55679),s=i(80160).extend({defaults:{url:"",file:null,error:!1,uploading:!1,complete:!1,bytesLoaded:0,bytesTotal:0},initialize:function(e,t){this.options=n.extend({},t),this.options.jqXHR&&this.setUploadRequest(this.options.jqXHR)},setUploadRequest:function(e){return this.jqXHR=e,e.then(function(){}),e},_uploadDone:function(){this.set({error:!1,uploading:!1,complete:!0})},_uploadFail:function(){this.set({error:!0,uploading:!1,complete:!1})},cancelUpload:function(){var e;return this.jqXHR&&(e=this.jqXHR.abort(),this.jqXHR=null),e},getProgress:function(){return this.get("bytesTotal")?this.get("bytesLoaded")/this.get("bytesTotal"):0}});e.exports=s},85346(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(19698),r=i(16964),a=o.extend({getName:function(){return"email"},getLabel:function(){return s("Email")},getType:function(){return o.TYPE_SUBVIEW},getSubviewConstructor:function(){return r},getShareRequestDataFromSubviewData:function(e){var t={message:n.get(e,"message"),email_address:n.get(e,"email")};return n.get(e,"isAllowReply",!1)&&n.extend(t,{allow_reply_to:!0}),t}});e.exports=a},85474(e,t,i){"use strict";var n=i(55679),s=i(48357),o=i(81515),r=i(98237),a=i(77594),l=i(50283),c=i(5795),u=i(68311),h=i(60360),d=l.extend({className:"conversation-compose",template:h,mixins:[r,a],events:{"click [data-js-submit-button]":"_onSubmitButtonClick","input [data-js-text-input]":"_onTextInputChange","keydown [data-js-text-input]":"_onTextInputKeydown","focus [data-js-text-input]":"_onTextInputFocus","blur [data-js-text-input]":"_onTextInputBlur","paste [data-js-text-input]":"_onTextInputPaste"},keycommands:{"keydown:escape":"_onKeyPressEscape"},defaults:{isValid:!0,isDisabled:!1,isOffline:!1,placeholder:null,offlinePlaceholder:null,currentPlaceholder:null,currentText:null,hasEditorFocus:!1,isAutoValidationEnabled:!0,buttonSubmittedClass:"submitted",hideComposePluginsClass:"hide-compose-plugins-container",hidingComposePluginsClass:"hiding-compose-plugins-container",isShufflePlaceholder:!0,isPluginsVisible:!0,composeAnimationSpeed:200,pluginAnimateInDurationMs:200,pluginAnimateOutDurationMs:300,pluginAnimateInEasing:[.895,.03,.685,.22],pluginAnimateOutEasing:[.22,.685,.03,.895],isLightboxOpen:!1},subviews:{composePluginsView:{constructor:c,options:function(e){return{pluginsArray:e.pluginsArray}}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","keyboardManager","keyboardNamespace","pluginsArray","isGifSearchEnabled","isSendAPost")),this.getRandomPlaceholder=u([o("New message"),o("Your message here"),o("Write a message"),o("Say something"),o("Say your thing")]),n.isEmpty(this.pluginsArray)&&this.hideComposePluginsView(!0),this.set("isShufflePlaceholder",n.isEmpty(this.get("placeholder"))),n.isEmpty(this.get("placeholder"))&&this.set("placeholder",this.getRandomPlaceholder()),this.set("currentPlaceholder",this.get("placeholder")),n.isEmpty(this.get("offlinePlaceholder"))&&this.set("offlinePlaceholder",o("Currently offline")),this.keyboardManager&&this.disableKeys()},afterRenderSubviews:function(){this.listenTo(this,"change:isValid",this._onChangeIsValid),this.listenTo(this,"change:isDisabled",this._onChangeIsDisabled),this.listenTo(this,"change:isOffline",this._onChangeIsOffline),this.listenTo(this,"change:currentPlaceholder",this._onChangeCurrentPlaceholder),this.listenTo(this,"change:currentText",this._onChangeCurrentText),this.listenTo(this,"change:hasEditorFocus",this._onChangeHasEditorFocus),this.listenTo(this,"change:isAutoValidationEnabled",this._onChangeIsAutoValidationEnabled),this.listenTo(this.composePluginsView,"plugin:preview:add:image",this._onComposePluginPreviewAddImage),this.listenTo(this.composePluginsView,"plugin:click",this._onComposePluginClick),this._onChangeIsValid(this,this.get("isValid")),this._onChangeIsDisabled(this,this.get("isDisabled")),this._onChangeIsOffline(this,this.get("isOffline")),this._onChangeCurrentPlaceholder(this,this.get("currentPlaceholder")),this._onChangeCurrentText(this,this.get("currentText")),this._setValidState(),n.defer(n.bind(function(){this._resizeInput()},this))},getTemplateData:function(){return{placeholder:this.get("placeholder"),isSendAPost:this.isSendAPost}},hideComposePluginsView:function(e){var t,i=this.get("hideComposePluginsClass"),o=this.get("hidingComposePluginsClass");this.get("isPluginsVisible")&&(this.set("isPluginsVisible",!1),e?this.$el.addClass(i):(this.$el.addClass(o),this._resizeInput(),t=this.composePluginsView.$el.outerWidth(),s.animate(this.$el,{marginLeft:[-t,0]},{duration:this.get("pluginAnimateOutDurationMs"),easing:this.get("pluginAnimateOutEasing"),complete:n.bind(function(){this._resizeInput(),this.$el.css("marginLeft","").addClass(i).removeClass(o)},this)})))},showComposePluginsView:function(e){var t,i=this.get("hideComposePluginsClass");this.get("isPluginsVisible")||(this.set("isPluginsVisible",!0),e?this.$el.removeClass(i):(t=this.composePluginsView.$el.outerWidth(),this.$el.css("margin-left",-t).removeClass(i),this._resizeInput(),s.animate(this.$el,{marginLeft:[
10,-t]},{duration:this.get("pluginAnimateInDurationMs"),easing:this.get("pluginAnimateInEasing"),complete:n.bind(function(){this._resizeInput(),this.$el.css("marginLeft","")},this)})))},toggle:function(e){this.$el.toggle(e),e&&this.$el.css("display","")},submit:function(e){var t=this.get("currentText");this.get("isValid")&&!this.get("isDisabled")&&(this.trigger("submit",t,e),this._startAnimation(n.bind(function(){this.trigger("submit:animated",t,e)},this)),this.clear())},escape:function(){this.get("isLightboxOpen")||(n.isEmpty(this.get("currentText"))?this.trigger("close"):this.clear())},clear:function(){this.js$("text-input").val(""),this.set("currentText",""),this.get("isShufflePlaceholder")&&this._setPlaceholderState(),this._resizeInput()},focus:function(){n.defer(n.bind(function(){this.rendered&&this.js$("text-input").focus()},this))},getMessage:function(){return this.js$("text-input").val()},setPlaceholder:function(e){this.set({placeholder:e,isShufflePlaceholder:!1}),this._setPlaceholderState()},beforeRemove:function(){this.keyboardManager&&this.keyboardManager.remove(this.keyboardNamespace)},toggleAutoValidation:function(e){this.set("isAutoValidationEnabled",e)},_onComposePluginPreviewAddImage:function(e){this.trigger("plugin:preview:add:image",e)},_onComposePluginClick:function(e){this.trigger("plugin:click",e)},_onKeyPressEscape:function(e){e.preventDefault(),this.escape()},_onTextInputChange:function(){var e=n.trim(this.js$("text-input").val());this._resizeInput(),this.set("currentText",e),this.trigger("input",e,this)},_setValidState:function(){this.get("isAutoValidationEnabled")?this.set("isValid",!n.isEmpty(this.get("currentText"))):this.set("isValid",!0)},_resizeInput:function(){var e,t=this.js$("text-input"),i=t.get(0);this._originalInputHeight||(this._originalInputHeight=t.outerHeight()),this.$el.css("height",this.$el.height()),t.css("height","auto"),e=i.scrollHeight,Math.abs(e-this._originalInputHeight)<5&&(e=this._originalInputHeight),t.css("height",e),this.$el.css("height",""),this._detectResize()},_detectResize:function(){var e=this.$el.height();this._previousHeight?e!==this._previousHeight&&(this.trigger("resize",e),this._previousHeight=e):this._previousHeight=e},_startAnimation:function(e){var t=this.js$("submit-button"),i=this.get("buttonSubmittedClass");n.isEmpty(i)?n.isFunction(e)&&e.call(this):(t.addClass(i),n.delay(n.bind(function(){t.removeClass(i),n.isFunction(e)&&e.call(this)},this),this.get("composeAnimationSpeed")))},_setPlaceholderState:function(){this.set("currentPlaceholder",this.get("isShufflePlaceholder")?this.getRandomPlaceholder():this.get("placeholder"))},_onChangeCurrentText:function(e,t){this._setValidState()},_onChangeIsValid:function(e,t){this.js$("submit-button").prop("disabled",!t||this.get("isDisabled"))},_onSubmitButtonClick:function(e){e.preventDefault(),this.submit("button")},_onChangeIsDisabled:function(e,t){this.js$("text-input").prop("disabled",t),this.js$("submit-button").prop("disabled",t||!this.get("isValid")),this.composePluginsView.toggleDisabled(t)},_onChangeIsOffline:function(e,t){t?(this.set("previousPlaceholder",this.get("placeholder")),this.set("currentPlaceholder",this.get("offlinePlaceholder"))):this.set("currentPlaceholder",this.get("previousPlaceholder"))},_onChangeCurrentPlaceholder:function(e,t){this.js$("text-input").attr("placeholder",t)},_onTextInputFocus:function(){this.set("hasEditorFocus",!0),this.trigger("focus",this)},_onTextInputBlur:function(){this.set("hasEditorFocus",!1),this.trigger("blur",this)},_onTextInputPaste:function(e){var t,i,s=n.get(e,"originalEvent.clipboardData.items",[]),o=n.filter(s,{kind:"file"});this.get("isDisabled")||0!==o.length&&(t=n.last(o))&&(i=n.result(t,"getAsFile"),this.trigger("pasteBlob",i))},_onTextInputKeydown:function(e){13!==e.keyCode||e.shiftKey||(this.submit("keyboard"),e.preventDefault())},_onChangeHasEditorFocus:function(e,t){this.keyboardManager&&this.keyboardManager.toggle(this.keyboardNamespace,e,t)},_onChangeIsAutoValidationEnabled:function(e,t){this._setValidState()}});e.exports=d},85757(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(98237),r=i(72042).html,a=i(74692),l=i(57505),c=i(32435),u=s.extend({className:"conversation-message-text message-container",mixins:[o],template:c,defaults:{fullWidthBubblePercentThreshold:60,fullWidthBubbleClass:"full-width-bubble"},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","participants")),this.formatter=e.formatter||new r},afterRenderSubviews:function(){this.listenTo(this.model.get("content"),"change",this.render),this.$el.width()?this._setBubbleStyles():n.defer(n.bind(this._setBubbleStyles,this));var e=this.$el.find(".pixelated-avatar");n.each(e,n.bind(function(e){a(e).removeClass("hide").addClass("show"),l.drawPixelatedImages(this)},this))},getTemplateData:function(){var e=this.participants.get(this.model.get("participant")),t=this.model.toJSON();return{message:this.formatter.render(n.get(t,"content.text"),n.get(t,"content.formatting")),canPixelateAvatar:e?e.get("can_pixelate_avatar"):null,avatarUrl:e?e.getAvatarUrl():null,name:e?e.get("name"):null,url:e?e.get("url"):null}},_setBubbleStyles:function(){var e=this.get("fullWidthBubblePercentThreshold"),t=this.js$("message-bubble"),i=this.$el.width();t.width()>e/100*i&&t.addClass(this.get("fullWidthBubbleClass"))}});e.exports=u},86042(e,t,i){"use strict";var n=i(55679),s=i(17604).sprintf,o=i(81515),r=i(27496),a=i(71092),l=i(13482),c=i(38578),u=a.extend({mixins:[l,c],defaults:{isParent:!1},events:function(){return{click:this.isLoggedIn()?"onClick":this.redirect("/register?redirect_to=/explore")}},initialize:function(e){this.pt=this.model.get("pt"),this.postModel=this.model,"parent"===this.$el.attr("data-follow")?(this.model=this.model.parentTumblelog,this.set("isParent",!0)):this.model=this.model.tumblelog,this.model&&this.listenTo(this.model,"change:following",this.updateFollowStatus)},onClick:function(e){e.preventDefault(),this._following()?this._confirmUnfollow():(this._logFollowingChange(!0),this.model.follow({pt:this.pt,source:"FOLLOW_SOURCE_DISCOVER_POSTS_GRID"}),this.get("isParent")||this.postModel.trigger("start_following"))},_logFollowingChange:function(e){var t=e?"post:log_follow":"post:log_unfollow",i=this.$el.closest("article"),n=JSON.parse(i.attr("data-json"));r.trigger(t,{loggingData:{postId:n.id,tumblelog:n.tumblelog,position:i.index()}})},_following:function(){return this.model.get("following")},_newlyFollowing:function(){return this._following()&&!this.$el.hasClass("is-following")},_newlyUnfollowing:function(){return!this._following()&&this.$el.hasClass("is-following")},updateFollowStatus:function(){this.$el.addClass("animating"),this._newlyFollowing()?(this.$el.addClass("is-following show-unfollow"),this.$el.css({width:this.$(".unfollow-text").width()})):this._newlyUnfollowing()&&(this.$el.removeClass("is-following"),this.$el.css({width:this.$(".follow-text").width()})),n.delay(function(e){e.removeClass("animating")},300,this.$el)},_setFollowButtonClass:function(){this.$el.toggleClass("is-following",this._following())},_confirmUnfollow:function(){var e={text:s(o("Are you sure you want to unfollow %1$s?"),"<strong>"+this.model.get("name")+"</strong>
1"),text_ok:o("Ok"),text_cancel:o("Nevermind")},t=this.model.requestUnfollow({pt:this.pt,source:"UNFOLLOW_SOURCE_DISCOVER_POSTS_GRID"}),i=this;t.promise.then(function(){i._logFollowingChange(!1),i.get("isParent")||i.postModel.trigger("stop_following")}),r.trigger("dialog:confirm:promise",t,e)}});e.exports=u},86115(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(80160),r=i(42714),a=i(26771),l=i(83331),c=i(25910),u=i(37271),h={TEXT:"TEXT",POST:"POSTREF",IMAGE:"IMAGE",STICKER:"STICKER"},d=o.extend({mixins:[a],relations:{content:l,post:c,image:u},idAttribute:"ts",defaults:{conversation_id:null,type:h.TEXT,ts:null,participant:null,participants:null,content:null,message:null,post:null,image:null,file:null,sticker:null,sticker_id:null,collapseGroup:null,clientTs:null,tsHeader:null,isQueued:!1,isPending:!1,isError:!1,isCollapsed:!1,canRetry:!0,hasAnimation:!1,context:null,creationUserAction:null},persistedFields:["conversation_id","type","participant","participants","message","post","context","sticker_id"],saveNoRetryOnErrorCodes:[403,404],validSendMessageContexts:["post-chrome","messaging-gif","messaging-image-upload"],initialize:function(){return this.set("clientTs",Date.now()),o.prototype.initialize.apply(this,arguments)},parse:function(e,t){var i=n.get(e,"response.messages.data.0")||e,s=n.get(i,"images");return n.isArray(s)&&n.extend(i,{image:n.first(s)}),i},save:function(e,t){var i,a,l,c,u;return t=n.extend({validate:!0,parse:!0},t),(e=e||{})&&this.set(e),a=this.toJSON(),l=n.pick(a,this.persistedFields),c=this._getServerLoggingContext(),n.isEmpty(c)?delete l.context:n.extend(l,{context:c}),n.extend(t,{data:l,emulateJSON:!0}),this.isImage()?(u=this.get("file"),this.uploader=new r({name:"data",uploadPattern:/^image\/(?:.*)$/i,accept:"image/*",url:this.url(),fileUpload:{multiple:!1,formData:l}}),this.uploader.addFiles([u]),(i=this.uploader.getCurrentRequest())?i.then(n.bind(function(e){t.parse&&(e=this.parse(e,t)),this.set(e,t)},this)):(i=new s.Deferred).reject()):i=o.prototype.save.call(this,e,t),this.set({isPending:!0,isQueued:!1}),i.then(n.bind(function(){this.set("isError",!1)},this)).fail(n.bind(function(e){this.set({isError:!0,canRetry:this._canRetryOnErrorCode(n.get(e,"status"))})},this)).always(n.bind(function(){this.set("isPending",!1)},this)),i},getActionMarkup:function(e,t,i){return t=t||"",i=i||"",this.isText()?n.isEmpty(e)?null:t+n.escape(e)+i:this.isPost()?this.getPost().getActionMarkup(e,t,i):this.isImage()?this.getImage().getActionMarkup(e,t,i):null},getPost:function(){return this.get("post")},getImage:function(){return this.get("image")},getTimestamp:function(){var e=this.get("ts");return e?parseInt(e,10):this.get("clientTs")},getMessage:function(){return this.isText()?this.get("content").get("text"):this.isPost()?this.getPost().getMessage():""},isError:function(){return this.get("isError")},isText:function(){return this.get("type")===h.TEXT},isPost:function(){return this.get("type")===h.POST},isImage:function(){return this.get("type")===h.IMAGE},isDisabledPost:function(){return this.isPost()&&this.get("post").isDisabled()},isPending:function(){return this.get("isPending")},canRetry:function(){return this.get("canRetry")},_canRetryOnErrorCode:function(e){return n.isFinite(e)&&!n.contains(this.saveNoRetryOnErrorCodes,e)},_getServerLoggingContext:function(){var e=this.get("context");return!n.isEmpty(e)&&(e=n.first(e.split(":")),n.contains(this.validSendMessageContexts,e))?e:null}},h);e.exports=d},86232(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(12097),r=i(64491),a=i(59952),l=i(5042),c=s.extend({className:"popover--messaging-peepr popover info_popover popover_gradient",template:l,mixins:[r,a],initialize:function(e){this.options=n.extend({},this.defaults,e),this.view=new o({model:this.model})},render:function(){return this.$el.html(this.template),this.$(".popover_inner").append(this.view.render().$el),this.listenTo(this.view,"popoverClose",this.teardown),this},teardown:function(){this.view.remove(),this.remove()},getView:function(){return this.view}});e.exports=c},86602(e,t,i){"use strict";var n=i(97583).extend({logKey:"ads_interactions",logOptions:{init_event:!1},events:{"ads-interaction:*":"handleEvent"},logEnv:{location:document.location.pathname},handleEvent:function(e,t){this.log(e,t)}});e.exports=n},86698(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(96500),r=s.extend({tagName:"audio",template:o,defaults:{filePath:null,fileType:null},events:{ended:"triggerRemove"},initialize:function(e){n.extend(this,n.pick(e,"model"))},getTemplateData:function(){return this.model.toJSON()},play:function(){this.el.play()},triggerRemove:function(){this.trigger("ended",this)}});e.exports=r},86758(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(27496),r=i(6479),a=i(25144),l=s.extend({events:{click:"openPopover"},updateBadge:function(e){e>0&&this.$(".tab_notice_value").text(e>99?"99+":e),this.$(".tab_notice").toggleClass("tab-notice--active",e>0)},initialize:function(){this.popover=null,this.user=r(),this.updateBadge(this.user.getUnreadCount()),this.popoverOptions={container:this.$el,viewOptions:{}}},openPopover:function(e){if(e.preventDefault(),this.popover)this.popover.show();else{var t=this.$el.closest(".l-header-container");t.length&&(this.popoverOptions.viewOptions.isFixedPosition="fixed"===t.css("position")),a(n.bind(function(e){this.popover=new e(this.popoverOptions).render()},this))}o.trigger("Kraken:AccountClick",{loggingData:{source:"app-header"}})}});e.exports=l},86804(e,t,i){"use strict";var n=i(71092),s=i(92701),o=n.extend({template:s,className:"mobile-logo",render:function(){return this.$el.html(this.template()),this}});e.exports=o},87213(e,t,i){"use strict";var n=i(97583).extend({logKey:"async_loading",events:{"async-loading:*":"log"}});e.exports=n},87335(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(38578),r=i(64491),a=i(40726),l=i(7521),c=i(75165),u=s.extend({template:a,mixins:[r,o],className:"drawer logged-in",initialize:function(e){e=n.extend({},e),n.extend(this.attributes,e),this.subViews.primaryNav=new l(e),this.subViews.secondaryNav=new c(e)},render:function(){return this.$el.html(this.template(this.toJSON())),this.attachSubViews(),this}});e.exports=u},87343(e,t,i){var n=i(55679),s=i(80160).extend({url:function(){return"/svc/post/share/"+this.get("tumblelog_name")+"/"+this.get("post_id")},defaults:{post_id:null,tumblelog_name:null,twitter_username:null,pinterest_share_window:null,show_pinterest:null,show_embed:null,post_url:null},parse:function(e){return n.get(e,"response.share_popover_data",e)},isValid:function(){return!n.isEmpty(this.get("post_id"))&&!n.isEmpty(this.get("tumblelog_name"))},isPopulated:function(){return!n.isEmpty(this.get("post_url"))}});e.exports=s},87564(e,t,i){"use strict";var n=i(55679),s=i(80160),o=s.prototype,r=i(49773),a=function(e,t,i){this.name="EmbedError",this.message=e,this.input=t,this.data=i,this.stack=(new Error).stack},l=s.extend({idAttribute:"query",url:"/svc/search/inline_gif",defaults:{query:"",limit:200,loggingContext:null},initialize:function(e,t){this.media=new r},fetch:function(e){var t=this.get("loggingContext"),i={q:this.get("query"),limit:this.get("limit")};return n.isEmpty(t)||n.extend(i,{context:t}),e=n.extend({type:"POST",withFormKey:!0,data:i},e),o.fetch.call(this,e)},parse:function(e,t){if(t&&t.xhr&&(e=(e||{}).response),n.isEmpty(e))throw new a("Invalid GIF search response",this.get("query"),e);return this.media.reset(e.media),delete e.media,e.ts=n.now(),e},toJSON:function(){var e=o.toJSON.apply(this,arguments);return e.media=this.media?this.media.toJSON():[],e}});e.exports=l},87722(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<div class="bar white"></div><div class="bar red"></div><div class="bar orange"></div><div class="bar green"></div><div class="bar purple"></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},87931(e,t,i){"use strict";var n=i(55679),s=i(27513),o=i(80867),r=s.extend({url:"/svc/search/get_recommended_tumblelogs",model:o,defaults:{limit:6},initialize:function(e){this.options=n.defaults(e,this.defaults),this.on("remove",this.onTumblelogRemoved)},onTumblelogRemoved:function(){var e={limit:1,remove:!1,page:this.getPageUrl()};this.fetch(e)},getPageUrl:function(){return window.location.pathname.split("/")[1]},parse:function(e){return e.response.blogs}});e.exports=r},88146(e){"use strict";var t=function(){};var i=e.exports={};
1i.stringIsClean=function(e){for(var t=0;t<e.length;t++)if(e.charCodeAt(t)<32)return!1;return!0},i.parseNum=function(e,t,i,n){var s,o,r=">"===e;for(void 0===i&&(i=0),void 0===n&&(n=t.length-i),s=r?i:i+n-1;r?s<i+n:s>=i;r?s++:s--)o<<=8,o+=t.charCodeAt(s);return o},i.parseSnum=function(e,t,i,n){var s,o,r,a=">"===e;for(void 0===i&&(i=0),void 0===n&&(n=t.length-i),s=a?i:i+n-1;a?s<i+n:s>=i;a?s++:s--)void 0===r&&(r=!(128&~t.charCodeAt(s))),o<<=8,o+=r?255&~t.charCodeAt(s):t.charCodeAt(s);return r&&(o+=1,o*=-1),o},i.Rational=function(e,t){return this.num=e,this.den=t||1,this},i.Rational.prototype.toString=function(){return 0===this.num||1===this.den?""+this.num:1===this.num?this.num+" / "+this.den:this.num/this.den},i.Rational.prototype.asFloat=function(){return this.num/this.den},i.MetaGroup=function(e,t){return this.fieldName=e,this.description=t,this.metaProps={},this},i.MetaGroup.prototype._addProperty=function(e,t,n){var s=new i.MetaProp(e,t,n);this[s.fieldName]=s,this.metaProps[s.fieldName]=s},i.MetaGroup.prototype.toString=function(){return"[MetaGroup "+this.description+"]"},i.MetaProp=function(e,t,i){return this.fieldName=e,this.description=t,this.value=i,this},i.MetaProp.prototype.toString=function(){return""+this.value},i.JpegFile=function(e,t){var n=this._SOS;this.metaGroups={},this._binary_data=e,this.filename=t;var s,o,r,a=0,l=0;if(this._binary_data.slice(0,2)!==this._SOI_MARKER)throw new Error("Doesn't look like a JPEG file. First two bytes are "+this._binary_data.charCodeAt(0)+","+this._binary_data.charCodeAt(1)+".");for(a+=2;a<this._binary_data.length&&(s=this._binary_data.charCodeAt(a++),o=this._binary_data.charCodeAt(a++),l=a,s==this._DELIM)&&o!==n;){for(a+=i.parseNum(">",this._binary_data,a,2);a<this._binary_data.length;)if((s=this._binary_data.charCodeAt(a++))==this._DELIM&&0!==this._binary_data.charCodeAt(a++)){a-=2;break}this._markers[o]?(this._markers[o][0],r=this._markers[o][1]):r=void 0,r&&this[r](o,l+2)}if(void 0===this.general)throw Error("Invalid JPEG file.");return this},i.JpegFile.prototype.toString=function(){return"[JpegFile "+this.filename+" "+this.general.type+" "+this.general.pixelWidth+"x"+this.general.pixelHeight+" Depth: "+this.general.depth+"]"},i.JpegFile.prototype._SOI_MARKER="ÿØ",i.JpegFile.prototype._DELIM=255,i.JpegFile.prototype._EOI=217,i.JpegFile.prototype._SOS=218,i.JpegFile.prototype._sofHandler=function(e,t){if(void 0!==this.general)throw Error("Unexpected multiple-frame image");this._addMetaGroup("general","General"),this.general._addProperty("depth","Depth",i.parseNum(">",this._binary_data,t,1)),this.general._addProperty("pixelHeight","Pixel Height",i.parseNum(">",this._binary_data,t+1,2)),this.general._addProperty("pixelWidth","Pixel Width",i.parseNum(">",this._binary_data,t+3,2)),this.general._addProperty("type","Type",this._markers[e][2])},i.JpegFile.prototype._JFIF_IDENT="JFIF\0",i.JpegFile.prototype._JFXX_IDENT="JFXX\0",i.JpegFile.prototype._EXIF_IDENT="Exif\0",i.JpegFile.prototype._types={1:["BYTE",1],2:["ASCII",1],3:["SHORT",2],4:["LONG",4],5:["RATIONAL",8],6:["SBYTE",1],7:["UNDEFINED",1],8:["SSHORT",2],9:["SLONG",4],10:["SRATIONAL",8],11:["FLOAT",4],12:["DOUBLE",8]},i.JpegFile.prototype._tifftags={256:["Image width","ImageWidth"],257:["Image height","ImageLength"],258:["Number of bits per component","BitsPerSample"],259:["Compression scheme","Compression",{1:"uncompressed",6:"JPEG compression"}],262:["Pixel composition","PhotmetricInerpretation",{2:"RGB",6:"YCbCr"}],274:["Orientation of image","Orientation",{1:"Normal",2:"Reverse?",3:"Upside-down",4:"Upside-down Reverse",5:"90 degree CW",6:"90 degree CW reverse",7:"90 degree CCW",8:"90 degree CCW reverse"}],277:["Number of components","SamplesPerPixel"],284:["Image data arrangement","PlanarConfiguration",{1:"chunky format",2:"planar format"}],530:["Subsampling ratio of Y to C","YCbCrSubSampling"],531:["Y and C positioning","YCbCrPositioning",{1:"centered",2:"co-sited"}],282:["X Resolution","XResolution"],283:["Y Resolution","YResolution"],296:["Resolution Unit","ResolutionUnit",{2:"inches",3:"centimeters"}],273:["Image data location","StripOffsets"],278:["Number of rows per strip","RowsPerStrip"],279:["Bytes per compressed strip","StripByteCounts"],513:["Offset to JPEG SOI","JPEGInterchangeFormat"],514:["Bytes of JPEG Data","JPEGInterchangeFormatLength"],301:["Transfer function","TransferFunction"],318:["White point chromaticity","WhitePoint"],319:["Chromaticities of primaries","PrimaryChromaticities"],529:["Color space transformation matrix coefficients","YCbCrCoefficients"],532:["Pair of black and white reference values","ReferenceBlackWhite"],306:["Date and time","DateTime"],270:["Image title","ImageDescription"],271:["Make","Make"],272:["Model","Model"],305:["Software","Software"],315:["Person who created the image","Artist"],316:["Host Computer","HostComputer"],33432:["Copyright holder","Copyright"],34665:["Exif tag","ExifIfdPointer"],34853
1:["GPS tag","GPSInfoIfdPointer"]},i.JpegFile.prototype._exiftags={36864:["Exif Version","ExifVersion"],40960:["FlashPix Version","FlashpixVersion"],40961:["Color Space","ColorSpace"],37121:["Meaning of each component","ComponentsConfiguration"],37122:["Compressed Bits Per Pixel","CompressedBitsPerPixel"],40962:["Pixel X Dimension","PixelXDimension"],40963:["Pixel Y Dimension","PixelYDimension"],37500:["Manufacturer notes","MakerNote"],37510:["User comments","UserComment"],40964:["Related audio file","RelatedSoundFile"],36867:["Date Time Original","DateTimeOriginal"],36868:["Date Time Digitized","DateTimeDigitized"],37520:["DateTime subseconds","SubSecTime"],37521:["DateTimeOriginal subseconds","SubSecTimeOriginal"],37522:["DateTimeDigitized subseconds","SubSecTimeDigitized"],33434:["Exposure time","ExposureTime"],33437:["FNumber","FNumber"],34850:["Exposure program","ExposureProgram"],34852:["Spectral sensitivity","SpectralSensitivity"],34855:["ISO Speed Ratings","ISOSpeedRatings"],34856:["Optoelectric coefficient","OECF"],37377:["Shutter Speed","ShutterSpeedValue"],37378:["Aperture Value","ApertureValue"],37379:["Brightness","BrightnessValue"],37380:["Exposure Bias Value","ExposureBiasValue"],37381:["Max Aperture Value","MaxApertureValue"],37382:["Subject Distance","SubjectDistance"],37383:["Metering Mode","MeteringMode"],37384:["Light Source","LightSource"],37385:["Flash","Flash"],37386:["Focal Length","FocalLength"],37396:["Subject Area","SubjectArea"],41483:["Flash Energy","FlashEnergy"],41484:["Spatial Frequency Response","SpatialFrequencyResponse"],41486:["Focal Plane X Resolution","FocalPlaneXResolution"],41487:["Focal Plane Y Resolution","FocalPlaneYResolution"],41488:["Focal Plane Resolution Unit","FocalPlaneResolutionUnit"],41492:["Subject Location","SubjectLocation"],41493:["Exposure Index","ExposureIndex"],41495:["Sensing Method","SensingMethod"],41728:["File Source","FileSource"],41729:["Scene Type","SceneType"],41730:["CFA Pattern","CFAPattern"],41985:["Custom Rendered","CustomRendered"],41986:["Exposure Mode","Exposure Mode"],41987:["White Balance","WhiteBalance"],41988:["Digital Zoom Ratio","DigitalZoomRatio"],41989:["Focal length in 35 mm film","FocalLengthIn35mmFilm"],41990:["Scene Capture Type","SceneCaptureType"],41991:["Gain Control","GainControl"],41992:["Contrast","Contrast"],41993:["Saturation","Saturation"],41994:["Sharpness","Sharpness"],41995:["Device settings description","DeviceSettingDescription"],41996:["Subject distance range","SubjectDistanceRange"],42016:["Unique image ID","ImageUniqueID"],40965:["Interoperability tag","InteroperabilityIFDPointer"]},i.JpegFile.prototype._gpstags={0:["GPS tag version","GPSVersionID"],1:["North or South Latitude","GPSLatitudeRef"],2:["Latitude","GPSLatitude"],3:["East or West Longitude","GPSLongitudeRef"],4:["Longitude","GPSLongitude"],5:["Altitude reference","GPSAltitudeRef"],6:["Altitude","GPSAltitude"],7:["GPS time (atomic clock)","GPSTimeStamp"],8:["GPS satellites usedd for measurement","GPSSatellites"],9:["GPS receiver status","GPSStatus"],10:["GPS mesaurement mode","GPSMeasureMode"],11:["Measurement precision","GPSDOP"],12:["Speed unit","GPSSpeedRef"],13:["Speed of GPS receiver","GPSSpeed"],14:["Reference for direction of movement","GPSTrackRef"],15:["Direction of movement","GPSTrack"],16:["Reference for direction of image","GPSImgDirectionRef"],17:["Direction of image","GPSImgDirection"],18:["Geodetic survey data used","GPSMapDatum"],19:["Reference for latitude of destination","GPSDestLatitudeRef"],20:["Latitude of destination","GPSDestLatitude"],21:["Reference for longitude of destination","GPSDestLongitudeRef"],22:["Longitude of destination","GPSDestLongitude"],23:["Reference for bearing of destination","GPSDestBearingRef"],24:["Bearing of destination","GPSDestBearing"],25:["Reference for distance to destination","GPSDestDistanceRef"],26:["Distance to destination","GPSDestDistance"],27:["Name of GPS processing method","GPSProcessingMethod"],28:["Name of GPS area","GPSAreaInformation"],29:["GPS Date","GPSDateStamp"],30:["GPS differential correction","GPSDifferential"]},i.JpegFile.prototype._markers={192:["SOF0","_sofHandler","Baseline DCT"],193:["SOF1","_sofHandler","Extended sequential DCT"],194:["SOF2","_sofHandler","Progressive DCT"],195:["SOF3","_sofHandler","Lossless (sequential)"],197:["SOF5","_sofHandler","Differential sequential DCT"],198:["SOF6","_sofHandler","Differential progressive DCT"],199:["SOF7","_sofHandler","Differential lossless (sequential)"],200:["JPG",null,"Reserved for JPEG extensions"],201:["SOF9","_sofHandler","Extended sequential DCT"],202:["SOF10","_sofHandler","Progressive DCT"],203:["SOF11","_sofHandler","Lossless (sequential)"],205:["SOF13","_sofHandler","Differential sequential DCT"],206:["SOF14","_sofHandler","Differential progressive DCT"],207:["SOF15","_sofHandler","Differential lossless (sequential)"],196:["DHT",null,"Define Huffman table(s)"],204:["DAC",null,"Define arithmetic coding conditioning(s)"],208:["RST0",null,"Restart with modulo 8 count “0”"],209:["RST1",null,"Restart with modulo 8 count “1”"],210:["RST2",null,"Restart with modulo 8 count “2”"],211:["RST3",null,"Restart with modulo 8 count “3”"],212:["RST4",null,"Restart with modulo 8 count “4”"],213:["RST5",null,"Restart with modulo 8 count “5”"],214:["RST6",null,"Restart with modulo 8 count “6”"],215:["RST7",null,"Restart with modulo 8 count “7”"],216:["SOI",null,"Start of image"],217:["EOI",null,"End of image"],218:["SOS",null,"Start of scan"],219:["DQT",null,"Define quantization table(s)"],220:["DNL",null,"Define number of lines"],221:["DRI",null,"Define restart interval"],222:["DHP",null,"Define hierarchical progression"],223:["EXP",null,"Expand reference component(s)"],224:["APP0","_app0Handler","Reserved for application segments"],225:["APP1","_app1Handler"],226:["APP2",null],227:["APP3",null],228:["APP4",null],229:["APP5",null],230:["APP6",null],231:["APP7",null],232:["APP8",null],233:["APP9",null],234:["APP10",null],235:["APP11",null],236:["APP12",null],237:["APP13",null],238:["APP14",null],239:["APP15",null],240:["JPG0",null],241:["JPG1",null],242:["JPG2",null],243:["JPG3",null],244:["JPG4",null],245:["JPG5",null],246:["JPG6",null],247:["JPG7",null],248:["JPG8",null],249:["JPG9",null],250:["JPG10",null],251:["JPG11",null],252:["JPG12",null],253:["JPG13",null],254:["COM",null],1:["JPG13",null]},i.JpegFile.prototype._addMetaGroup=function(e,t){var n=new i.MetaGroup(e,t);return this[n.fieldName]=n,this.metaGroups[n.fieldName]=n,n},i.JpegFile.prototype._parseIfd=function(e,n,s,o,r,a,l){var c,u,h,d,p,g,f,m,_,v,b,y=i.parseNum(e,n,s+o,2);b=this._addMetaGroup(a,l);for(var w=0;w<y;w++)if(c=s+o+2+12*w,u=i.parseNum(e,n,c,2),d=i.parseNum(e,n,c+2,2),g=i.parseNum(e,n,c+4,4),f=i.parseNum(e,n,c+8,4),void 0!==this._types[d]){if(h=this._types[d][0],f=(p=this._types[d][1])*g<=4?c+8:s+f,"UNDEFINED"==h)m=void 0;else if("ASCII"==h)m=(m=n.slice(f,f+g)).split("\0")[0],i.stringIsClean(m)||(m="");else{m=[];for(var C=0;C<g;C++,f+=p)"BYTE"!=h&&"SHORT"!=h&&"LONG"!=h||m.push(i.parseNum(e,n,f,p)),"SBYTE"!=h&&"SSHORT"!=h&&"SLONG"!=h||m.push(i.parseSnum(e,n,f,p)),"RATIONAL"==h&&(_=i.parseNum(e,n,f,4),v=i.parseNum(e,n,f+4,4),m.push(new i.Rational(_,v))),"SRATIONAL"==h&&(_=i.parseSnum(e,n,f,4),v=i.parseSnum(e,n,f+4,4),m.push(new i.Rational(_,v))),m.push();1===g&&(m=m[0])}r.hasOwnProperty(u)?b._addProperty(r[u][1],r[u][0],m):t()}},i.JpegFile.prototype._jfifHandler=function(e,t){if(void 0!==this.jfif)throw Error("Multiple JFIF segments found");this._addMetaGroup("jfif","JFIF"),this.jfif._addProperty("version_major","Version Major",this._binary_data.charCodeAt(t+5)),this.jfif._addProperty("version_minor","Version Minor",this._binary_data.charCodeAt(t+6)),this.jfif._addProperty("version","JFIF Version",this.jfif.version_major.value+"."+this.jfif.version_minor.value),this.jfif._addProperty("units","Density Unit",this._binary_data.charCodeAt(t+7)),this.jfif._addProperty("Xdensity","X density",i.parseNum(">",this._binary_data,t+8,2)),this.jfif._addProperty("Ydensity","Y Density",i.parseNum(">",this._binary_data,t+10,2)),this.jfif._addProperty("Xthumbnail","X Thumbnail",i.parseNum(">",this._binary_data,t+12,1)),this.jfif._addProperty("Ythumbnail","Y Thumbnail",i.parseNum(">",this._binary_data,t+13,1))},i.JpegFile.prototype._app0Handler=function(e,t){var i=this._binary_data.slice(t,t+5);i==this._JFIF_IDENT?this._jfifHandler(e,t):this._JFXX_IDENT},i.JpegFile.prototype._app1Handler=function(e,t){this._binary_data.slice(t,t+5)==this._EXIF_IDENT&&this._exifHandler(e,t+6)},i.JpegFile.prototype._exifHandler=function(e,t){if(void 0!==this.exif)throw new Error("Multiple JFIF segments found");var n,s,o,r=this._binary_data.slice(t,t+2);if("II"===r)n="<";else{if("MM"!==r)throw new Error("Malformed TIFF meta-data. Unknown endianess: "+r);n=">"}if(42!==(s=i.parseNum(n,this._binary_data,t+2,2)))throw new Error("Malformed TIFF meta-data. Bad magic: "+s);if(o=i.parseNum(n,this._binary_data,t+4,4),this._parseIfd(n,this._binary_data,t,o,this._tifftags,"tiff","TIFF"),this.tiff.ExifIfdPointer&&this._parseIfd(n,this._binary_data,t,this.tiff.ExifIfdPointer.value,this._exiftags,"exif","Exif"),this.tiff.GPSInfoIfdPointer){var a,l;if(this._parseIfd(n,this._binary_data,t,this.tiff.GPSInfoIfdPointer.value,this._gpstags,"gps","GPS"),this.gps.GPSLatitude)a=this.gps.GPSLatitude.value[0].asFloat
1()+1/60*this.gps.GPSLatitude.value[1].asFloat()+1/3600*this.gps.GPSLatitude.value[2].asFloat(),"S"===this.gps.GPSLatitudeRef.value&&(a=-a),this.gps._addProperty("latitude","Dec. Latitude",a);if(this.gps.GPSLongitude)l=this.gps.GPSLongitude.value[0].asFloat()+1/60*this.gps.GPSLongitude.value[1].asFloat()+1/3600*this.gps.GPSLongitude.value[2].asFloat(),"W"===this.gps.GPSLongitudeRef.value&&(l=-l),this.gps._addProperty("longitude","Dec. Longitude",l)}}},88174(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(59952),r=i(59542),a=s.extend({className:"popover--gif-search",mixins:[o],defaults:{query:null},initialize:function(e){this.gifSearch=new r(n.pick(e,"collection","query","imageWidth","loadFullImageBeforeSelect","selectedImageUrl","resultLimit","loggingContext")),this.listenTo(this,"change:query",function(e,t){this.gifSearch.setQuery(t)}),this.listenTo(this.gifSearch,"all",this.trigger)},render:function(){this.gifSearch.render().$el.appendTo(this.$el)},teardown:function(){return n.result(this.gifSearch,"remove"),this.$el.remove(),this}});e.exports=a},88206(e,t,i){"use strict";var n=i(71742),s=i(46556),o=n.extend({name:"ToolTip",class_name:"tumblr_tooltip",initialize:function(e){this.toolTipView=new s(e)}});e.exports=o},88628(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<ul class=\"popover_inner_list search_filter_items\"><li class=\"popover_header\"> ' +\n__e( __('Popular Tags:') ) +\n' </li> ';\n for (var i = 0; i < model.maxRender && i < model.typeAheadMatches.length; i++) { ;\n__p += ' <li class=\"popover_menu_item\" data-term=\"' +\n__e( model.typeAheadMatches[i].tag ) +\n'\"><span class=\"popover_menu_item_anchor\">#' +\n__e( model.typeAheadMatches[i].tag ) +\n' </span></li> ';\n } ;\n__p += ' </ul>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},88729(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"options\"> ';\n _.each(options, function(option) { ;\n__p += ' ';\n if (option.visibility === 'eu' && !is_eu) { ;\n__p += ' ';\n } else if (option.visibility === 'brazil' && !is_brazil) { ;\n__p += ' ';\n } else if (option.visibility === 'child_exploitation' && !child_exploitation_visible) { ;\n__p += ' ';\n } else if (option.visibility === 'harm_to_minors' && child_exploitation_visible) { ;\n__p += ' ';\n } else if (option.visibility === 'ncii' && !is_ncii_visible) { ;\n__p += ' ';\n } else if (mode !== 'standalone' && typeof option.flaggingTo !== 'undefined') { ;\n__p += ' <button class=\"option\" data-survey-nav-to=\"' +\n((__t = ( option.flaggingTo )) == null ? '' : __t) +\n'\"> ' +\n((__t = ( __(option.name) )) == null ? '' : __t) +\n' </button> ';\n } else { ;\n__p += ' <button class=\"option\" data-survey-nav-to=\"' +\n((__t = ( option.to )) == null ? '' : __t) +\n'\"> ' +\n((__t = ( __(option.name) )) == null ? '' : __t) +\n' </button> ';\n } ;\n__p += ' ';\n }); ;\n__p += ' </div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},88855(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(27496),r=i(5143).transition,a=s.extend({defaults:{fadeScrollDistance:2e3,visible:!0},initialize:function(){this.listenTo(o,"DOMEventor:flatscroll",this.onScroll),this.on("change:visible",this.toggleVisibility),this.$nav=this.$el.find(".sidebar_nav")},onScroll:function(e){e&&(e.windowScrollY>=this.get("fadeScrollDistance")?this.set("visible",!1):this.set("visible",!0))},toggleVisibility:function(e,t){!0===t?(this.showElement(),n.defer(n.bind(function(){this.$nav.toggleClass("visible",t)},this))):(r(this.$nav,n.bind(function(){this.hideElement()},this)),this.$nav.toggleClass("visible",t)),o.trigger("toastr:canDisplayToggle",t)},hideElement:function(){this.$el.css("display","none")},showElement:function(){this.$el.css("display","block")}});e.exports=a},88879(e,t,i){"use strict";var n=i(97583),s=i(28017),o=n.extend({logKey:"recommended_blogs",logEnv:{context:s.get("Context/name"),location:document.location.pathname},logOptions:{init_event:!1},events:{"recommendedBlogs:*":"log"}});e.exports=o},89161(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(21189),r=i(33255),a=i(17145),l=function(e,t,i){this.name="EmbedError",this.message=e,this.input=t,this.data=i,this.stack=(new Error).stack};l.prototype=new Error;var c=a.extend({constructor:function(e){this.setEmbedRegexes(e||[])},setEmbedRegexes:function(e){this.regexes=e,this.services=n.unique(n.values(e))},isValidEmbedService:function(e){return n.any(this.regexes,function(t,i){return new RegExp(i,"mi").test(e)})},isValidEmbedServiceName:function(e){return n.contains(this.services,e)},getUrlFromEmbedCode:function(e){var t=s(r.nodeFromString(e)),i=t.find("iframe[src], embed[src], script[src]").first(),n=t.find("object[data]").first();return i.attr("src")||n.attr("data")||!1},fetchEmbedData:function(e,t,i){var r=s.ajax({url:"/svc/post/get_video_data",type:"POST",withFormKey:!0,data:JSON.stringify({embed_url:e,embed_width:t})});return o(r).then(n.bind(function(s){if(n.isEmpty(s)||"false"===s||!n.isPlainObject(s))throw new l("Invalid embed response",e,s);if(s.thumbnail||i)return s;var r=n.bind(this.fetchEmbedData,this,e,t,!0);return o.promise(function(e,t){n.delay(function(){r().then(function(e){return e},function(){return s})},2e3)})},this)).catch(function(e){return o.reject(e)})},parseEmbedData:function(e,t){if(!n.isString(e))throw"The input is invali
1d. Expected a string";var i=n.trim(e);if(this.isValidEmbedService(i))return this.fetchEmbedData(i,t);var s=this.getUrlFromEmbedCode(i);return n.isEmpty(s)?o.reject(new l("Invalid embed code",e)):o.resolve({unsupported:!0,thumbnail:!1,embed_render_context:"blank",url:s,preview_iframe:"",embed_code:e})}});e.exports=new c},89529(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}var s=i(24655)("JSON",function(e){return e&&e.stringify}),o=[].slice,r=function(e,t){return function(){return e.apply(t,arguments)}},a=Object.prototype.toString;function l(e){return"string"==typeof e||e&&"object"===n(e)&&"[object String]"===a.call(e)||!1}var c,u=i(8012),h=i(36824),d=1,p={},g=[],f=[];c=window.addEventListener?"addEventListener":"attachEvent",(0,window[c])("attachEvent"===c?"onmessage":"message",function(e){var t;if("string"==typeof e.data){try{e.data&&"{"===e.data[0]&&(t=s.parse(e.data))}catch(e){}t&&t.method&&function(e,t){for(var i,n=g.length-1;n>=0;n--)g[n].message_callback(e,t);for(n=f.length-1;n>=0;n--)(i=f[n])&&i.shouldRespond&&i.shouldRespond(e,t)&&i.cb(e,t)}(e,t)}},!1);var m=function(e){e.cid_response&&e.cid_response in p&&(p[e.cid_response].resolve.call(null,this,e.response),delete p[e.cid_response])};function _(e){if(e||(e={}),!(s&&s.stringify&&s.parse))throw"Must have JSON parsing and stringify";if(e.iframe&&(e.window=e.iframe.contentWindow,!e.origin)){var t=e.iframe.src.match(/^(http(?:s)?:\/\/[\w_\-\.]+(?::\d+)?)\/?/);t&&(e.origin=t[1])}this.namespace=e.namespace?e.namespace+":":"",this.origin=e.origin||"*",this.responders={_method_callback_responder:m,_syn:r(this._syn,this)},this._on_connected=new u,this._unanswered_calls={},this.on_connection(r(this.enable_sending_post_message,this)),g.push(this),e.window&&this.setWindow(e.window)}function v(e,t,i){i||(i=this.origin),e.postMessage(t,i)}_.prototype.setWindow=function(e){e&&(this.window=e,this.call("_syn").then(r(function(e,t){"ack"===t&&this._is_connected()},this)))},_.on=function(e,t){var i;i="*"===e?function(){return!0}:"*"===e[e.length-1]?function(t,i){return 0===i.method.indexOf(e.substring(0,e.length-2))}:function(t,i){return i.method===e},f.push({shouldRespond:i,cb:t})},_.off=function(e){for(var t,i=f.length-1;i>=0;i--)if(f[i].cb===e){t=i;break}return!!(t&&t>-1)&&(f.splice(t,1),!0)},_.prototype.match_origin=function(e){return"*"===this.origin||this.origin===e},_.prototype.message_callback=function(e,t){var i;if((!this.window||e.source===this.window)&&this.match_origin(e.origin)){if(t.method&&t.method.slice(0,this.namespace.length)===this.namespace&&(i=t.method.slice(this.namespace.length,t.method.length)),t.args&&l(t.args))try{t.args=s.parse(t.args)}catch(e){return}this.call_responder(i,e,t)}},_.prototype.call_responder=function(e,t,i){var n,s;if(e){if(i.args||(i.args=[]),!(s=this.responders[e]))return this._unanswered_calls[e]||(this._unanswered_calls[e]=[]),void this._unanswered_calls[e].push(arguments);n=s.apply(t,i.args),i.cid&&"_method_callback_responder"!==e&&this.send_to_window(t.source,"_method_callback_responder",{cid_response:i.cid,response:n})}},_.prototype._syn=function(){return this._is_connected(),"ack"},_.prototype._is_connected=function(){this.connected||(this.connected=!0,this._on_connected.trigger(this))},_.prototype.on_connection=function(e){return this._on_connected.push.apply(this._on_connected,arguments),this},_.prototype.method=function(e){var t=this,i=function(){var i=1<=arguments.length?o.call(arguments,0):[];return i.unshift(e),t.send.apply(t,i)};return i},_.prototype.call=function(){var e=1<=arguments.length?o.call(arguments,0):[];if(this.window)return e.unshift(this.window),this.call_on_window.apply(this,e);console.warn("no window specified on channel")},_.prototype.call_on_window=function(e,t){var i=3<=arguments.length?o.call(arguments,2):[],n=function(){var e=new h;return e.cid=d,d+=1,p[e.cid]=e,e}();try{var r=s.stringify({method:this.namespace+t,args:i,cid:n.cid});"_syn"===t||"_method_callback_responder"===t?v.call(this,e,r):this.send_post_message(e,r)}catch(e){n.reject(e)}return n.promise()},_.prototype.send=function(){var e=1<=arguments.length?o.call(arguments,0):[];if(this.window)return e.unshift(this.window),this.send_to_window.apply(this,e);console.warn("no window specified on channel")},_.prototype.send_to_window=function(e,t){var i=3<=arguments.length?o.call(arguments,2):[],n=s.stringify({method:this.namespace+t,args:i});"_syn"===t||"_method_callback_responder"===t?v.call(this,e,n):this.send_post_message(e,n)},_.prototype.send_post_message=function(){this._delayed_sent_messages||(this._delayed_sent_messages=[]),this._delayed_sent_messages.push(arguments)},_.prototype.enable_sending_post_message=function(){if(this.send_post_message=v,this._delayed_sent_messages){for(var e=0;e<this._delayed_sent_messages.length;e+=1)v.apply(this,this._delayed_sent_messages[e]);delete this._delayed_sent_messages}},_.prototype.listening_to=function(e){return e in this.responders},_.prototype.listen_to=function(e,t,i){if(l(e)){if(e in this.responders)console.warn("already listening to this method, turn it off first");else if(i&&(t=r(t,i)),this.responders[e]=t,this._unanswered_calls[e]){var n,s=this._unanswered_calls[e];delete this._unanswered_calls[e];for(var o=0;o<s.length;o+=1)n=s[o],this.call_responder.apply(this,n)}}else{var a=e;for(e in a)a.hasOwnProperty(e)&&this.listen_to(e,a[e],i)}},_.prototype.stop_listen_to=function(e){"_method_callback_responder"!==e?delete this.responders[e]:console.warn("cannot disable the method callback responder")},_.prototype.ensureChannelConnection=function(e){this.send_to_window(e,"_syn")},e.exports=_},89760(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<div data-js-conversations-container><div data-subview="conversations[]"></div><div data-subview="favoritesView"></div></div>
1<div class="inbox-pagination-loader" data-js-loader-container><div data-subview="paginationLoaderView"></div></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},89826(e,t,i){function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function s(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,o(n.key),n)}}function o(e){var t=function(e,t){if("object"!=n(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var s=i.call(e,t||"default");if("object"!=n(s))return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==n(t)?t:t+""}var r=i(55679),a=i(27496),l=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),r.isString(t)?t={chunkName:t}:t||(t={}),t.chunkName,this.chunkName=t.chunkName||""},(t=[{key:"start",value:function(){this.startTime=Date.now()}},{key:"end",value:function(){this.startTime&&a.trigger("async-loading:complete:"+this.chunkName,{loggingData:{chunkName:this.chunkName,latency:Date.now()-this.startTime,userAgent:r.get(window,"navigator.userAgent",""),path:r.get(document,"location.pathname")}})}}])&&s(e.prototype,t),i&&s(e,i),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,i}();e.exports=l},89934(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div class=\"mobile-banner-body\"><span class=\"mobile-banner-heading\">' +\n__e( __('Want to see more stuff?') ) +\n'</span></div><div class=\"mobile-banner-controls\"><a href=\"/register\" class=\"mobile-banner-button signup primary-cta tx-button blue\">' +\n__e( __('Sign up') ) +\n'</a><a href=\"/login\" class=\"mobile-banner-button login secondary-cta tx-button white\">' +\n__e( __('Log in') ) +\n'</a></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},89945(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(60874),r=i(77594),a=i(64147),l=i(85179),c=i(99722),u=i(9367),h=s.extend({className:"messaging-share-post-results",template:u,defaults:{isFocused:!1,focusedView:null,selectedView:null},mixins:[r,o,l],keycommands:{"keydown:left":"_onKeyPressLeft","keydown:right":"_onKeyPressRight","keydown:backspace":"_onKeyPressBackspace","keydown:shift+backspace":"_onKeyPressBackspace"},subviews:{resultView:{constructor:c,options:function(e){return{onSelect:n.bind(e._onSubviewSelect,e),onFocus:n.bind(n.partial(e._setIsFocusedDebounced,!0),e),onBlur:n.bind(n.partial(e._setIsFocusedDebounced,!1),e)}},collection:function(e){return e.collection}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"collection","selectedRecipientModel","keyboardNamespace","keyboardManager")),this.keyboardViewName="resultView",this.disableKeys()},afterRenderSubviews:function(){this.listenTo(this.collection,"reset update",this._onCollectionChange),this.listenTo(this,"change:isFocused",this._onChangeIsFocused),this.listenTo(this,"change:focusedView",this._onChangeFocusedView),this.listenTo(this,"change:selectedView",this._onChangeSelectedView),this.listenTo(this.selectedRecipientModel,"change:participant",this._onChangeSelectedRecipientModel),this._setIsFocusedDebounced=n.debounce(n.bind(this._setIsFocused,this),0),this.scrollbar=new a(this.$el),this.updateScrollbar()},resetFocus:function(){this.set("focusedView",null),this.deselect(this.keyboardViewName)},toggle:function(e){this.$el.toggle(e),e||this.resetFocus()},focus:function(){var e=this.get("selectedView"),t=!n.isEmpty(e);t&&this.setSelectedIndex(this.keyboardViewName,n.indexOf(this.resultView,e)),t?this.set("focusedView",this.getSelectedView(this.keyboardViewName)):this.focusFirst()},focusFirst:function(){this.set("focusedView",this.selectFirst(this.keyboardViewName))},focusLast:function(){this.set("focusedView",this.selectLast(this.keyboardViewName))},focusNext:function(){this.set("focusedView",this.selectNext(this.keyboardViewName))},focusPrevious:function(){this.set("focusedView",this.selectPrevious(this.keyboardViewName))},isLastFocused:function(){return this.isLastSelected(this.keyboardViewName)},isFirstFocused:function(){return this.isFirstSelected(this.keyboardViewName)},updateScrollbar:function(e){this.rendered&&this.scrollbar&&n.defer(n.bind(this.scrollbar.update,this.scrollbar))},beforeRemove:function(){this.keyboardManager.remove(this.keyboardNamespace),this.scrollbar&&this.scrollbar.destroy()},_onKeyPressLeft:function(e){e.preventDefault(),this.focusPrevious()},_onKeyPressRight:function(e){e.preventDefault(),this.focusNext()},_onKeyPressBackspace:function(e){e.preventDefault()},_onChangeFocusedView:function(e,t){var i=this.previous("focusedView");i&&i.setFocused(!1),t&&t.setFocused(!0)},_onChangeSelectedView:function(e,t){var i=this.previous("selectedView");i&&i.setSelected(!1),t&&t.setSelected(!0)},_onSubviewSelect:function(e,t){var i=e!==this.get("selectedView")?e:null,s=n.isEmpty(i)?null:t;this.selectedRecipientModel.set("participant",s),this.set("selectedView",i)},_setIsFocused:function(e){this.rendered&&this.set("isFocused",e)},_onChangeIsFocused:function(e,t){t?(this.keyboardManager.add(this.keyboardNamespace,this),this.trigger("focus",this)):(this.set("focusedView",null),this.keyboardManager.remove(this.keyboardNamespace),this.trigger("blur",this))},_onCollectionChange:function(){this.resetFocus(),this.updateScrollbar()},_onChangeSelectedRecipientModel:function(e,t){var i;n.isEmpty(t)?this.set("selectedView",null):(i=n.find(this.resultView,function(e){return e.model.get("uuid")===t.get("uuid")}),this.set("selectedView",i))}});e.exports=h},89953(e,t,i){"use strict";var n=i(55679),s=i(74692),o=new(i(28724))({extend:{getQueue:function(){return this.queue||(this.queue=[]),this.queue},getQueueItems:function(){return n.pluck(this.getQueue(),"item")},clearQueue:function(){this.getQueue().length=0},isFlushingQueue:function(){return!0===this._isFlushingQueue},hasQueue:function(){return this.getQueue().length>0},appendToQueue:function(e,t){var i=this.getQueue();return e=this._getItemsAsArray(e),i.push.apply(i,this._constructItemWrappers(e,t)),i},prependToQueue:function(e,t){var i=this.getQueue();return e=this._getItemsAsArray(e),i.unshift.apply(i,this._constructItemWrappers(e,t)),i},removeFromQueue:function(e){return e=this._getItemsAsArray(e),this.queue=n.reduce(this.getQueue(),function(t,i){var s=n.get(i,"item");
1return n.contains(e,s)||t.push(i),t},[]),this.queue},flushQueue:function(e,t){var i,o=this.getQueue();return this._isFlushingQueue?this._flushQueueDeferred:n.isFunction(e)?(this._isFlushingQueue=!0,this._flushQueueDeferred=new s.Deferred,(i=function(){var s,r,a;if(this._isFlushingQueue){if(0===o.length)return this._isFlushingQueue=!1,void this._onQueueSuccess(t);s=o.shift(),r=n.get(s,"item"),a=n.get(s,"options"),this._onQueueItemStart(r,a,t),e.call(this,r,a,t).then(n.bind(function(){this._onQueueItemSuccess(r,a,t),i.call(this)},this)).fail(n.bind(function(){this._isFlushingQueue=!1,this._onQueueItemFail(r,a,t)},this))}}).call(this),this._flushQueueDeferred):(new s.Deferred).reject()},abortFlush:function(){this._isFlushingQueue&&(this._isFlushingQueue=!1,this._flushQueueDeferred.reject())},_getItemsAsArray:function(e){return n.isArray(e)||(e=[e]),e},_constructItemWrappers:function(e,t){return n.map(e,function(e){return{item:e,options:t}})},_onQueueItemStart:function(e,t,i){this._flushQueueDeferred.notify(e,!1,t,i,this.getQueueItems())},_onQueueItemSuccess:function(e,t,i){this._flushQueueDeferred.notify(e,!0,t,i,this.getQueueItems())},_onQueueItemFail:function(e,t,i){this._flushQueueDeferred.reject(e,t,i,this.getQueueItems())},_onQueueSuccess:function(e){this._flushQueueDeferred.resolve(e)}}});e.exports=o},90263(e,t,i){"use strict";var n=i(55679);function s(e,t,i){return"#"+((1<<24)+(e<<16)+(t<<8)+i).toString(16).slice(1)}function o(e){(e=String(e).replace(/[^0-9a-f]/gi,"")).length<6&&(e=e[0]+e[0]+e[1]+e[1]+e[2]+e[2]);var t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?{r:parseInt(t[1],16),g:parseInt(t[2],16),b:parseInt(t[3],16)}:null}function r(e,t,i){var n=Math.min(Math.min(e,t),i),s=Math.max(Math.max(e,t),i),o=s-n,r={h:6,s:s?(s-n)/s:0,v:s/255};return o?r.h+=s===e?(t-i)/o:s===t?2+(i-e)/o:4+(e-t)/o:r.h=0,r.h=60*r.h%360,r}function a(e,t,i){var n,s,o;if(t){n=s=o=0;var r=(e+360)%360/60,a=i*t,l=i-a,c=a*(1-Math.abs(r%2-1));r<1?(n=a,s=c):r<2?(n=c,s=a):r<3?(s=a,o=c):r<4?(s=c,o=a):r<5?(o=a,n=c):(o=c,n=a),n+=l,s+=l,o+=l}else n=s=o=i;return{r:Math.round(255*n),g:Math.round(255*s),b:Math.round(255*o)}}function l(e){(e=String(e).replace(/[^0-9a-f]/gi,"")).length<6&&(e=e[0]+e[0]+e[1]+e[1]+e[2]+e[2]);var t=o(e);return r(t.r,t.g,t.b)}function c(e,t,i){return"string"==typeof e&&(e=l(e)),t||(t=.2),i||(i=.8),e.s<t&&e.v>i}e.exports={rgbToHex:s,hexToRgb:o,rgbToHsv:r,hsvToRgb:a,hexToHsv:l,hsvToHex:function(e,t,i){var n=a(e,t,i);return s(n.r,n.g,n.b)},brighten:function(e,t){(e=String(e).replace(/[^0-9a-f]/gi,"")).length<6&&(e=e[0]+e[0]+e[1]+e[1]+e[2]+e[2]),t=t||0;var i=parseInt(e,16),n=t<0?0:255,s=t<0?-t:t,o=i>>16,r=i>>8&255,a=255&i;return"#"+(16777216+65536*(Math.round((n-o)*s)+o)+256*(Math.round((n-r)*s)+r)+(Math.round((n-a)*s)+a)).toString(16).slice(1)},readable:function(e){return"string"==typeof e&&(e=l(e)),c(e)?"#444":"#FFF"},compare:function(e,t,i){var s={upperBound:.8,lowerBound:.2,diffBound:.1,hueBound:15};n.extend(s,i),"string"==typeof e&&(e=l(e)),"string"==typeof t&&(t=l(t));var o=s.upperBound,r=s.lowerBound,a=s.diffBound,c=s.hueBound,u=Math.abs(e.h-t.h),h=Math.abs(e.s-t.s),d=Math.abs(e.v-t.v);return u<=a&&h<=a&&d<=a||h<=a&&d<=a&&(h>=o||h<=r&&d>=o||d<=r&&u<=c)},isLight:c}},90375(e,t,i){"use strict";var n=i(71742),s=i(37552),o=i(27496),r=i(74692),a=i(55679),l=n.extend({name:"GutterMediaManager",gutteredView:null,gutterMargin:17,gutterWidth:300,maxViewWidth:300,viewportTransitionWidth:990,initialize:function(){this.layoutHasGutter=this.$right_column().length>0,this.layoutHasGutter||(this.gutterMargin=-65)},$right_column:function(){return this._$right_column||(this._$right_column=r(".right_column")),this._$right_column}
1,toggleBackground:function(e){this.layoutHasGutter&&(e?(this.$right_column().addClass("has_docked_post"),this.$right_column().on("click.gutterManager",a.bind(this.handleGutterClick,this))):(this.$right_column().removeClass("has_docked_post"),this.$right_column().off("click.gutterManager")))},putViewInGutter:function(e,t){return t=a.defaults(t||{},{winRect:s.rect(),gutterPosition:this.gutterPosition(),animation:null,dimRadar:!0,removeOnGutterClick:!1,onDock:a.noop,onUndock:a.noop,dockLoggingName:"post:docked",dockLoggingData:null,undockLoggingName:"post:undocked",undockLoggingData:null}),!!this.isDockable(e,t)&&(t.onDock=t.onDock||a.noop,this.gutteredView&&this.removeGutteredView(),this.gutteredView={view:e,options:t},t.onDock.call(e,t),t.dimRadar&&this.toggleBackground(!0),t.dockLoggingName&&t.dockLoggingData&&o.trigger(t.dockLoggingName,{loggingData:t.dockLoggingData}),this.gutteredView)},removeGutteredView:function(){if(this.gutteredView){var e=this.gutteredView.options,t=this.gutteredView.view;e.onUndock=e.onUndock||a.noop,e.onUndock.call(t,e),this.gutteredView=null,e.dimRadar&&this.toggleBackgroun
1d(!1),e.undockLoggingName&&e.undockLoggingData&&o.trigger(e.undockLoggingName,{loggingData:e.undockLoggingData})}},isViewInGutter:function(e){return this.gutteredView&&this.gutteredView.view===e},isDockable:function(e,t){if(!this.gutteredView)return!0;var i=!this.gutteredView||this.gutteredView.options.alwaysEvict,n=t.alwaysEvict;return!(this.gutteredView.view===e||n&&!i)},handleGutterClick:function(e){this.gutteredView&&(e.preventDefault(),this.gutteredView.options.removeOnGutterClick&&this.removeGutteredView())},gutterPosition:function(){var e=s.rect(),t=this.viewportTransitionWidth/2-this.gutterMargin-this.gutterWidth,i={width:this.maxViewWidth,left:"50%",bottom:20,translateX:t},n=this.maxViewWidth-this.gutterWidth+this.viewportTransitionWidth;return e.windowWidth<n&&(i.width=n-e.windowWidth),i.width<this.gutterWidth&&(i.width=this.gutterWidth),i}});e.exports=new l},90752(e,t,i){"use strict";var n=i(44384).extend({});e.exports=n},91007(e,t,i){"use strict";var n=[{id:"-1",appeal:"OWNER_APPEAL_NSFW_UNAVAILABLE",readable:"unavailable"},{id:"0",appeal:"OWNER_APPEAL_NSFW_NONE",readable:"none"},{id:"1",appeal:"OWNER_APPEAL_NSFW_AVAILABLE_PRIORITIZE",readable:"available_prioritize"},{id:"2",appeal:"OWNER_APPEAL_NSFW_AVAILABLE",readable:"available"},{id:"3",appeal:"OWNER_APPEAL_NSFW_IN_REVIEW",readable:"in_review"},{id:"4",appeal:"OWNER_APPEAL_NSFW_COMPLETE",readable:"complete"}],s=i(74692),o=i(55679),r=i(81515),a=i(27496),l=i(49779),c=function(e){return this.xhr&&this.xhr.abort(),this.xhr=s.ajax({method:"POST",url:"/svc/appeal",data:{post_id:this.model.get("id"),blog_name:this.model.get("tumblelog"),state:e},withFormKey:!0}),this.xhr},u={_handleProjectXBannerRequest:function(e,t,i){var a=this,c=i.model.get("classification-status");if(o.isObject(c)){var u=c.classification,h=c.status,d=!!i.model.get("reblogged_from_tumblr_url")||!!i.model.get("is_reblog"),p={type:"wide",visible_glass:!0,escape_button:0};if(h===o.find(n,{appeal:"OWNER_APPEAL_NSFW_IN_REVIEW"}).readable||h===o.find(n,{appeal:"OWNER_APPEAL_NSFW_NONE"}).readable||h===o.find(n,{appeal:"OWNER_APPEAL_NSFW_COMPLETE"}).readable){var g=d?"InfoExplicitReblogClick":"InfoExplicitClick";this.logExplicitAction(g,{postId:t,state:h})}else this.logExplicitAction("ReviewExplicitClick",{postId:t});var f={text:r("Appeal"),callback:function(){a.logExplicitAction("RequestReviewExplicit",{postId:t}),a.request(e,t,i),i.model.set("classification-status",{classification:u,status:o.find(n,{appeal:"OWNER_APPEAL_NSFW_IN_REVIEW"}).readable});var l=r(d?"This reblog is in content appeal":"Your post is in content appeal"),c=s(e.target).closest(".x-banner");c.addClass("in-review"),c.find(".message-status").text(l);var h=c.find(".review");h.addClass("question-mark"),h.removeClass("appeal"),h.html("<span>?</span>")}},m=function(e){return{text:r("Learn more"),callback:function(){a.logExplicitAction("LearnMoreExplicit",{postId:t}),window.open(e,"_blank")}}},_={text:r("Dismiss"),btn_class:"blue",callback:function(){a.logExplicitAction("CancelReviewExplicit",{postId:t})}},v={none:r("This content contains sexually explicit content which violates our User Guidelines."),available:r("This post was flagged because we think it contains sexually explicit content which violates our User Guidelines. It has been hidden from others, but not deleted. If you think this was done in error, tap Appeal and a real, live human will review it."),in_review:r("Your post is in content appeal. Once a decision has been made, we'll send you an email."),complete:r("This post was flagged because it contains sexually explicit content which violates our User Guidelines. It has not been deleted but is now only viewable to you. This decision cannot be appealed."),reblog:r("This post was flagged because somewhere in your reblog there might be sexually explicit content which is a violation of our User Guidelines.")},b="",y="";if(d&&h!==o.find(n,{appeal:"OWNER_APPEAL_NSFW_COMPLETE"}).readable&&h!==o.find(n,{appeal:"OWNER_APPEAL_NSFW_AVAILABLE_PRIORITIZE"}).readable&&h!==o.find(n,{appeal:"OWNER_APPEAL_NSFW_AVAILABLE"}).readable)o.extend(p,{text:v.reblog,buttons:{0:m(y),1:_}});else switch(h){case o.find(n,{appeal:"OWNER_APPEAL_NSFW_AVAILABLE_PRIORITIZE"}).readable:case o.find(n,{appeal:"OWNER_APPEAL_NSFW_AVAILABLE"}).readable:o.extend(p,{text:v.available,buttons:{0:f,1:m(y),2:_}});break;case o.find(n,{appeal:"OWNER_APPEAL_NSFW_IN_REVIEW"}).readable:o.extend(p,{text:v.in_review,buttons:{0:m(b),1:_}});break;case o.find(n,{appeal:"OWNER_APPEAL_NSFW_COMPLETE"}).readable:case o.find(n,{appeal:"OWNER_APPEAL_NSFW_UNAVAILABLE"}).readable:o.extend(p,{text:v.complete,buttons:{0:m(y),1:_}});break;default:o.extend(p,{text:v.none,buttons:{0:m(y),1:_}})}l.dialog(p)}},request:function(e,t,i){var s;this._appealState=o.bind(c,i),this.xhr=this._appealState((s="OWNER_APPEAL_NSFW_IN_REVIEW",parseInt(o.find(n,{appeal:s}).id,10))),this.xhr.done(o.bind(function(){l.alert(r("Okay! We'll review the status of this and email you when we're done."))},this)),this.logAction("RequestReviewButtonClicked",t)},openPeepr:function(e,t){a.trigger("peepr-open-request",{tumblelog_name:e,post_id:t,editing_appearance:!1,should_bypass_safemode_forpost:!0,should_bypass_safemode_forblog:!1}),this.logAction("ShowNsfwPostAnywaysClicked",t)},getAppealArray:function(){return n},logAction:function(e,t){(o.isNumber(t)||o.isString(t))&&a.trigger("safeMode:".concat(e),{loggingData:{postId:t}})},logExplicitAction:function(e,t){var i=t.postId,n=t.state;(o.isNumber(i)||o.isString(i))&&("InfoExplicitClick"!==e||o.isString(n))&&a.trigger("Kraken:".concat(e),{loggingData:{state:n,postId:i}})}};e.exports=u},91398(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p +=\n__e( exploreLinkLabel );\n\n}\nreturn __p\n}").apply(void 0,r(s))},91450(e,t,i){var n=i(55679),s=i(44890),o=i(50283),r=i(98237),a=i(80158),l=i(69912),c=o.extend({className:"conversation-minimized",tagName:"a",attributes:{href:"#"},template:l,mixins:[r],events:{click:"_onClick"},defaults:{maxBadgeCount:99,activeBadgeClass:"tab-notice--active",newMessageClass:"new-message"},subviews:{statusIndicator:{constructor:a,options:function(e){return{isOnline:e.get("isOnline"),canSeeUIFlag:s.bool("status_indicator"),name:e.participant.get("name")}}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus")),this.participant=this.model.getOtherParticipant(),this.set({blogName:this.participant?this.participant.get("name"):null,avatarUrl:this.participant?this.participant.getAvatarUrl():null,
1statusIndicatorUiFlag:s.bool("status_indicator")})},setIsOnline:function(e){this.set("isOnline",e),this.renderSubviews()},afterRenderSubviews:function(){this.listenTo(this.model,"change:unreadCount",this._onChangeUnreadCount),this.listenTo(this.model,"sync",this._onConversationSync),this.listenTo(this,"setIsOnline",this.setIsOnline),this.listenTo(this.participant,"change:seconds_since_last_activity",function(e,t){this.setIsOnline(-1!==t)})},updateBadge:function(e){var t=this.get("maxBadgeCount"),i=this.get("activeBadgeClass");e>0&&this.js$("badge-value").text(e>t?t+"+":e),this.js$("badge").toggleClass(i,e>0)},animate:function(){var e=this.get("newMessageClass");this.$el.addClass(e),n.delay(n.bind(function(){this.$el.removeClass(e)},this),250)},focus:function(){this.$el.focus()},blur:function(){this.$el.blur()},_onChangeUnreadCount:function(e,t){this.updateBadge(t),t>0&&this.animate()},_onConversationSync:function(e){this.renderWithTemplate(),this.renderSubviews()},_onClick:function(e){e.preventDefault(),this.blur(),this.trigger("click")}});e.exports=c},91474(e,t,i){"use strict";var n,s=i(55679),o=function(){window.onfocus=s.bind(this.onFocus,this),window.onblur=s.bind(this.onBlur,this)};o.prototype.onFocus=function(e){this.isActive=!0},o.prototype.onBlur=function(e){this.isActive=!1},o.prototype.isActive=!0;e.exports=function(){return null==n&&(n=new o),n}},91673(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(27496),r=i(50283),a=i(23043),l=r.extend({className:"search-no-results",template:a,afterRender:function(){this.setHeight(),this.listenTo(o,"DOMEventor:flatresize",s.throttle(this.setHeight,300))},setHeight:function(){var e=n(".indash_blog .posts"),t=e.outerHeight()-e.height(),i=n(".indash_blog .header").height();this.$el.height(n(window).height()-i-t)}});e.exports=l},91720(e,t,i){e.exports=function(){if(i.g.Blob)try{return new Blob(["asdf"],{type:"text/plain"}),Blob}catch(e){}var e=i.g.WebKitBlobBuilder||i.g.MozBlobBuilder||i.g.MSBlobBuilder;return function(t,i){var n=new e,s=i.endings,o=i.type;if(s)for(var r=0,a=t.length;r<a;++r)n.append(t[r],s);else for(r=0,a=t.length;r<a;++r)n.append(t[r]);return o?n.getBlob(o):n.getBlob()}}()},91852(e,t,i){"use strict";var n=i(71742),s=i(80869),o=n.extend({name:"Snowman",autoAppend:!0,initialize:function(e){this.view=new s(e)}});e.exports=o},92148(e,t,i){"use strict";var n=i(44384).extend({});e.exports=n},92163(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(81899),r=s.extend({className:"messaging-share-post-external-network",tagName:"a",attributes:{href:"#",tabIndex:1},events:{focus:"_onFocus",blur:"_onBlur",click:"_onClick"},defaults:{isFocused:!1,focusedClass:"is-focused"},template:o,initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"onFocus","onBlur","onShareSuccess","onShareFail","onShareClick","onShowSubview")),this.component=this.model.get("component")},getTemplateData:function(){return{label:this.component.getLabel()}},afterRender:function(){this.listenTo(this,"change:isFocused",this._onChangeIsFocused),this.listenTo(this.component,"share:fail",this._onShareFail),this.listenToOnce(this.component,"share:success",this._onShareSuccess),this._setLinkClass(),this._setLinkHref()},remove:function(){this.stopListening(this.component)},setFocused:function(e){this.rendered&&this.set("isFocused",e)},_setLinkHref:function(){var e=this.component.getButtonHref();n.isEmpty(e)||this.$el.attr({href:e,target:"_blank"})},_setLinkClass:function(){this.$el.addClass("network--"+this.component.getName())},_onFocus:function(e){e.preventDefault(),n.isFunction(this.onFocus)&&this.onFocus(this,this.model)},_onBlur:function(e){e.preventDefault(),n.isFunction(this.onBlur)&&this.onBlur(this,this.model)},_onClick:function(e){this.onShareClick&&this.onShareClick(this.component),this.component.isTypeHref()||(e.preventDefault(),this.component.isTypeCallback()?this.component.onClickHandler(e):this.component.isTypePopup()?this._openShareWindow():this.component.isTypeSubview()&&this.component.getSubviewInstance().then(n.bind(function(e){n.isFunction(this.onShowSubview)&&this.onShowSubview(e)},this)).catch(n.bind(function(e){0},this)))},_openShareWindow:function(){var e=this.component.getPopupUrl(),t=this.component.getPopupOptions(),i=this.component.getName();n.isEmpty(e)||window.open(e,i+"-share-dialog",t)},_onChangeIsFocused:function(e,t){this.$el.toggleClass(this.get("focusedClass"),t),t&&this.$el.focus()},_onShareSuccess:function(){n.isFunction(this.onShareSuccess)&&this.onShareSuccess(this.component)},_onShareFail:function(){n.isFunction(this.onShareFail)&&this.onShareFail(this.component)}});e.exports=r},92414(e,t,i){var n=i(55679),s=i(74692),o=i(27496),r=i(50283).extend({defaults:{frameLeft:null,frameTop:null,frameRight:null,frameBottom:null,isTabHidden:!1,headerHeight:0},initialize:function(e){this.listenTo(o,"DOMEventor:flatresize",this.setHeaderHeight),this.$headerEl=s(e.headerEl),this.setHeaderHeight(),this.$window=s(window),this.setFramePositions(),s(document).on("visibilitychange",n.bind(this.setVisibility,this))},setVisibility:function(e){this.set("isTabHidden","hidden"===document.visibilityState)},setHeaderHeight:function(){this.set("headerHeight",this.getFramePosition(this.$headerEl.outerHeight()))},setFramePositions:function(){this.set({frameTop:this.getFramePosition(this.$window.scrollTop())+this.get("headerHeight"),frameBottom:this.getFramePosition(this.$window.scrollTop())+this.getFramePosition(this.$window.height()),frameLeft:this.getFramePosition(this.$window.scrollLeft()),frameRight:this.getFramePosition(this.$window.scrollLeft())+this.getFramePosition(this.$window.width())})},getFramePosition:function(e){return n.isNumber(e)?e:-1},getElWidth:function(){var e=this.$el.width();return n.isNumber(e)?e:-1},getElHeight:function(){var e=this.$el.height();return n.isNumber(e)?e:-1},getPercentageInView:function(){if(this.get("isTabHidden"))return 0;this.setFramePositions();var e=this.getElWidth(),t=this.getElHeight(),i=this.$el.offset(),n=i.left,s=i.top,o=i.left+e,r=i.top+t,a=0,l=0,c=0,u=0,h=0,d=0,p=0,g=0,f=0;if(this.get("frameTop")>r||this.get("frameBottom")<s||this.get("frameLeft")>o||this.get("frameRight")<n)return 0;this.get("frameTop")>s&&(a=(d=this.get("frameTop")-s)*e),this.get("frameBottom")<r&&(l=(p=r-this.get("frameBottom"))*e),this.get("frameLeft")>n&&(c=(g=this.get("frameLeft")-n)*t),this.get("frameRight")<o&&(u=(f=o-this.get("frameRight"))*t),a&&u&&(h+=d*f),a&&c&&(h+=d*g),l&&u&&(h+=p*f),l&&c&&(h+=p*g);var m=e*t;return(m-(a+l+c+u-h))/m}});e.exports=r},92483(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(71092),r=i(48357),a=o.extend({initialize:function(e){this.el=e.el||null,this.itemSelector=e.itemSelector||".item",this.dropInParent=e.dropInParent||!1,this.transparentPlaceholder=e.transparentPlaceholder,this.beforeDragStart=e.beforeDragStart||n.noop,this.afterDragEnd=e.afterDragEnd||n.noop,this.scrollable=e.scrollable||!1,this.$items=this.$(this.itemSelector),this.isAnimating=!1,this.disableAnimation=e.disableAnimation||!1,this.disableAnimation&&(this.calculateDropTarget=n.throttle(this.calculateDropTarget,500)),this.$currentlyDraggedItem=null,this.$placeholder=null,this.placeholderElement=null,this.renderedPlaceholder=!1,this.reloadItems()},itemEvents:function(e){e||(e=this.itemSelector);var t={};return t["dragstart "+e]="setPlaceholder",t["dragenter "+e]="calculateDropTarget",t["dragend "+e]="resetPlaceholder",this.dropInParent?(t.dragover="cancelEvent",t.drop="dropItemAndResetPlaceholder"):(t["dragover "+e]="cancelEvent",t["drop "+e]="dropItem"),t},setPlaceholder:function(e){this.renderedPlaceholder=!1,e.originalEvent.dataTransfer.effectAllowed="move";try{e.originalEvent.dataTransfer.setData("text/html","")}catch(e){}if(this.$currentlyDraggedItem=s(e.currentTarget),this.$currentlyDraggedItem){if(this.$placeholder=this.$currentlyDraggedItem.clone().addClass("sortable-placeholder"),this.transparentPlaceholder&&this.$placeholder.addClass("transparent-placeholder"),!this.disableAnimation){var t=this.$currentlyDraggedItem.outerWidth();this.$placeholder.data("item-width",t).data("need-animation",!1)}this.placeholderElement=this.$placeholder.get(0),this.$currentlyDraggedItem.addClass("sortable-dragging"),this.beforeDragStart(),this.trigger("dragstart",this),this.scrollable&&(this.$el.on("dragover."+this.cid,n.throttle(function(e){var t=.2,i=window.innerHeight,n=e.originalEvent.clientY/i,s=this.getBoundingClientRect();n<t&&s.top<0?window.scrollBy(0,-200*(t-n)):n>.8&&window.scrollBy(0,200*(t+n-1)),e.preventDefault()},50)),this.$currentlyDraggedItem.one("dragend",n.bind(function(){this.$el.off(["dragenter."+this.cid,"dragover."+this.cid].join(" "))},this)))}},calculateDropTarget:function(e){if(this.$currentlyDraggedItem&&!this.isAnimating){e.preventDefault(),this.renderedPlaceholder=!0;var t=e.currentTarget,i=s(t);if(t===this.placeholderElement)return!1;this.$currentlyDraggedItem.hide();var n,o=i.index(this.itemSelector),r=this.$placeholder.index(this.itemSelector),a=this.$placeholder.data("need-animation")||!1,l=this.$placeholder.data("item-width");return this.disableAnimation||(n=s("<span>").css({width:l,display:"inline-block"}),this.$placeholder.after(n),a&&this.$placeholder.css({width:0,padding:0})),r<o?i.after(this.placeholderElement):i.before(this.placeholderElement),this.disableAnimation||(a?this.animatePlaceholderWidth(n,this.$placeholder,l,200):this.$placeholder.data("need-animation",!0)),this.lastDroppable=t,!1}},animatePlaceholderWidth:function(e,t,i,s){this.isAnimating=!0,r.animate(e,"stop"),r.animate(t,"stop"),r.animate(e,{width:0},s,"easeInOutQuart",n.bind(function(){e.remove(),this.isAnimating=!1},this)),r.animate(t,{width:i},s,"easeInOutQuart")},cancelEvent:function(e){this.$currentlyDraggedItem&&e.preventDefault()},dropItem:function(e){return this.$currentlyDraggedItem&&this.renderedPlaceholder&&this.placeholderElement&&(e.stopPropagation(),this.$currentlyDraggedItem.insertAfter(this.placeholderElement)),!1},resetPlaceholder:function(e){this.renderedPlaceholder=!1,this.placeholderElement=null,this.$currentlyDraggedItem&&(this.$currentlyDraggedItem.removeClass("sortable-dragging").show(),this.$currentlyDraggedItem=null,this.$placeholder.detach(),e.stopPropagation(),this.afterDragEnd(),this.trigger("dragend",this),this.lastDroppable=null)},dropItemAndResetPlaceholder:function(e){return this.dropItem(e),this.resetPlaceholder(e)},sequence:function(){var e=this.$(this.itemSelector).toArray();return n.uniq(n.pluck(e,"id"))},reloadItems:function(){return this.$items=this.$(this.itemSelector),n.each(this.$items,function(e){e.draggable=!0,s(e).find("a").attr("draggable",!1),s(e).find("img").attr("draggable",!1)}),this.delegateEvents(this.itemEvents(this.itemSelector)),this},disableItems:function(){return n.each(this.$items,function(e){e.draggable=!1}),this.undelegateEvents(),this},teardown:function(){return this.undelegateEvents(),this.scrollable&&this.$el.off(["dragenter."+this.cid,"dragover."+this.cid].join(" ")),n.each(this.$items,function(e){s(e).add("a, img",e).removeAttr("draggable")}),this.$items=null,this.$placeholder=null,this.beforeDragStart=null,this.afterDragEnd=null,this.calculateDropTarget=null,this}});e.exports=a},92531(e,t,i){"use strict";var n=i(74692),s=i(71092),o=i(81515),r=i(38578),a=i(27496),l=i(93650),c=i(39277),u=i(75793),h=s.extend({mixins:[r],templateAttributes:{__:o,formKey:n("#tumblr_form_key").attr("content")},initialize:function(e){e=e||{},this.set("complete",!1),this.fieldValidation=new c({el:this.$el}),this.imageUpload=new l({el:this.$el}),this.errortags=new u({mobileMode:void 0!==e.mobileMode&&e.mobileMode}),this._bindEvents()},_bindEvents:function(){this.listenTo(a,"drawer:close",this._teardown),this.listenTo(a,"drawerform:validation",this._updateCompleteStatus)},_updateCompleteStatus:function(e){this.set("complete",e.status)},_teardown:function(){this.fieldValidation.remove(),this.imageUpload.remove(),this.errortags.remove()},isAndroidKitKatWebView:function(e){if(null==e)return!1;var t=-1!==(e=e.toLowerCase()).indexOf("android 4.4"),i=-1!==e.indexOf("version/");return t&&i},supportsFileChooser:function(){return!this.isAndroidKitKatWebView(navigator.userAgent)}});e.exports=h},92536(e,t,i){var n=i(74692),s=i(55679),o=i(71742),r=i(7695),a=o.extend({name:"MobileAppBanner",defaults:{type:"download-banner"},initialize:function(e){this.options=s.extend(this.defaults,e||{})},render:function(){return this.data&&(s.extend(this.data,this.options),(this.data.has_app||"app-gate"===this.options.type)&&(this.bannerView=new r(this.data).render().el),n(this.options.attachTo).append(this.bannerView)),this}});e.exports=a},92701(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<a href="/" class="logo-link"><svg class="svg-logo" width="29px" height="39px" viewBox="0 0 29 39" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><path class="inner" d="M13.4404585,32.9978573 L13.1859215,33 C5.40091922,33 3.7112324,27.2768093 3.7112324,23.9359304 L3.7112324,14.6527709 L0.644574576,14.6527709 C0.288572835,14.6527709 0,14.3641866 0,14.0082147 L0,9.6266323 C0,9.1644545 0.291787135,8.7523442 0.72736069,8.5979279 C4.72423734,7.1880393 5.97738627,3.70267176 6.16328007,1.05159549 C6.21292323,0.34336573 6.58403216,0 7.20071368,0 L11.7729503,0 C12.1289164,0 12.4175249,0.28854863 12.4175249,0.64452051 L12.4175249,8.0664341 L17.7675867,8.0664341 C18.1235885,8.0664341 18.4121613,8.3550185 18.4121613,8.7109547 L18.4121613,13.9746459 C18.4121613,14.3306178 18.1235885,14.6191665 17.7675867,14.6191665 L12.3906676,14.6191665 L12.3906676,23.2008456 C12.3906676,25.3559968 13.8110674,25.9521997 14.6886074,25.9521997 C15.5299686,25.9319513 16.3586512,25.6757572 16.7738319,25.5090561 C17.0821548,25.3853159 17.3529775,25.3033938 17.595693,25.3640676 C17.8213012,25.420456 17.9700163,25.5802291 18.0701239,25.8719917 L19.4885237,30.0155572 C19.6024885,30.3446026 19.702489,30.70361 19.464595,30.9576614 C18.3476967,32.1504243 15.7600055,32.9595389 13.4404585,32.9978573 L13.4404585,32.9978573 Z"></path></svg></a>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},92712(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"blog-selector-container\"><div class=\"selected-blog\" data-js-button><img class=\"avatar\" src=\"' +\n__e( avatarUrl ) +\n'\" alt=\"' +\n((__t = ( displayName )) == null ? '' : __t) +\n'\" data-js-avatar> <span class=\"name\" data-js-label>' +\n((__t = ( displayName )) == null ? '' : __t) +\n'</span> ';\n if (requiresDropdown) { ;\n__p += ' <span class=\"caret ' +\n__e( hasBadge ? 'has-badge' : '' ) +\n'\" data-js-caret data-js-badge>';
1\n if (badgeCountString) { ;\n__p +=\n__e( badgeCountString );\n } ;\n__p += '</span> ';\n } ;\n__p += ' </div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},93049(e,t,i){"use strict";var n=i(55679),s=i(26771),o=i(25256),r=i(80160),a=i(14653),l=r.extend({url:"/svc/conversations/participant_info",mixins:[s],relations:{theme:a},defaults:{theme:null,is_blog_following_you:!1,is_following_blog:!1,duration_blog_following_you:null,duration_following_blog:null,seconds_since_last_activity:-1,blog_tags:[]},idAttribute:"uuid",parse:function(e){return!n.has(e,"theme")&&n.has(e,"global_theme_params")&&n.extend(e,{theme:n.get(e,"global_theme_params")}),n.get(e,"response",e)},getAvatarUrl:function(e){return e=e||96,o(this.get("avatar_url"),e)},getAvatarShape:function(){return this.get("theme").get("avatar_shape")},getBlogTags:function(){var e=this.get("blog_tags");return n.isArray(e)?e:[]},getDescription:function(){return!0!==this.get("theme").get("show_description")?"":this.get("description")},fetchAdditionalInfo:function(e,t){return t=n.extend({},t,{merge:!0,data:{q:this.get("uuid"),participant:e}}),this.fetch(t)},isFollowingYou:function(){return!0===this.get("is_blog_following_you")},isFollowing:function(){return!0===this.get("is_following_blog")},isMutuals:function(){return this.isFollowingYou()&&this.isFollowing()},getDurationFollowingYouSeconds:function(){var e=this.get("duration_blog_following_you");return this.isFollowingYou()&&n.isNumber(e)?e:null},getDurationFollowingSeconds:function(){var e=this.get("duration_following_blog");return this.isFollowing()&&n.isNumber(e)?e:null},getDurationMutualsSeconds:function(){var e,t;return this.isMutuals()?(e=this.getDurationFollowingSeconds(),t=this.getDurationFollowingYouSeconds(),Math.min(e,t)):null}});e.exports=l},93063(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div class=\"header\"><a href=\"#\" data-js-back-button class=\"back-button\">' +\n__e( __('Back') ) +\n'</a><div data-js-title class=\"title\">' +\n__e( title ) +\n'</div></div><div class=\"external-network-subview\" data-js-external-network-subview></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},93146(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),'return function(obj) {\nobj || (obj = {});\nvar __t, __p = \'\';\nwith (obj) {\n__p += \'<div data-subview="navMenu"></div><div data-subview="logoTitle"></div><div data-subview="search"></div>\';\n\n}\nreturn __p\n}').apply(void 0,r(s))},93257(e,t,i){"use strict";var n=i(44384),s=i(86042),o=i(45989),r=i(41565),a=n.extend({hasSubViews:{follow:s,info:o,"reblog-follow-tray":r,"reblog-parent-follow":s}});e.exports=a},93342(e,t,i){"use strict";i.d(t,{A:()=>n});const n=".ace-tumblr .ace_gutter{background:rgba(0,0,0,.1);color:#444;overflow:hidden}.ace-tumblr .ace_gutter-layer{width:100%;text-align:right}.ace-tumblr .ace_gutter-layer .ace_gutter-cell{padding-right:6px}.ace-tumblr .ace_text-layer{cursor:text;color:hsl(0,0%,94.8666666667%)}.ace-tumblr .ace_cursor{border-left:2px solid hsl(0,0%,56%)}.ace-tumblr .ace_cursor.ace_overwrite{border-left:0;border-bottom:1px solid hsl(0,0%,56%)}.ace-tumblr .ace_active-line{background-color:hsla(0,0%,100%,.02)}.ace-tumblr .ace_marker-layer .ace_selection{background-color:hsla(0,0%,100%,.1);transition:background-color .25s ease,margin .25s ease-out,padding .2s ease-out}.ace-tumblr .ace_marker-layer .ace_bracket{margin:-1px 0 0 -1px;border:1px solid hsla(0,0%,100%,.25)}.ace-tumblr .ace_marker-layer .ace_active_line{background:hsla(0,0%,100%,.031)}.ace-tumblr.search-highlight .ace_marker-layer .ace_selection{transition-duration:0s;background-color:hsla(0,0%,100%,.2);margin:-5px;padding:5px}.ace-tumblr.search-highlight .ace_marker-layer .ace_selection.ace_start:not(:last-child){margin-bottom:0;padding-top:0;padding-bottom:0}.ace-tumblr.search-highlight .ace_marker-layer .ace_selection.ace_start+.ace_selection{margin-top:5px;padding-top:0;padding-bottom:0}.ace-tumblr .ace_invisible{color:hsla(0,0%,100%,.25)}.ace-tumblr .ace_keyword{color:#ff8a00}.ace-tumblr .ace_constant{color:#ff8a00}.ace-tumblr .ace_constant.ace_language{color:#00cf35}.ace-tumblr .ace_constant.ace_boolean{color:#ff492f}.ace-tumblr .ace_constant.ace_numeric{color:#ff492f}.ace-tumblr .ace_invalid.ace_illegal{color:hsl(0,0%,94.8666666667%);background-color:rgba(83.5,62.5,97,.75)}.ace-tumblr .ace_invalid.ace_deprecated{text-decoration:underline;font-style:italic;color:rgb(236,174.5,159.5)}
1.ace-tumblr .ace_support{color:#ff8a00}.ace-tumblr .ace_support.ace_type{color:#7c5cff}.ace-tumblr .ace_storage.ace_type{color:#7c5cff}.ace-tumblr .ace_string{color:rgb(153,163,174.2)}.ace-tumblr .ace_comment{color:#748089}.ace-tumblr .ace_variable{color:#00cf35}.ace-tumblr .ace_tumblr.ace_tag{color:#00b8ff}.ace-tumblr .ace_tumblr.ace_tag.ace_begin{color:#00b8ff}.ace-tumblr .ace_tumblr.ace_tag.ace_end{color:#00b8ff}.ace-tumblr .ace_tumblr.ace_prefix{color:#7c5cff}.ace-tumblr .ace_css_keyword{color:#ff8a00}.ace-tumblr .ace_css_variable{color:#00cf35}.ace-tumblr .ace_css_constant{color:#ff492f}.ace-tumblr .ace_css_string{color:rgb(153,163,174.2)}.ace-tumblr .ace_attribute-name{color:rgb(153,163,174.2)}.ace-tumblr .ace_attribute-equals{color:hsl(0,0%,94.8666666667%)}.ace-tumblr .ace_attribute-value{color:#00cf35}.ace-tumblr .ace_xml_pe{color:#444}"},93405(e,t,i){"use strict";var n=i(55679),s=i(71742),o=i(30785),r=i(28017),a=s.extend({name:"PostEmbedCodeGenerator",defaults:{embed_host:"",secure_assets_host:"",tumblelog_mention_key:"",post_id:"",post_url:"",embed_key:"",embed_did:""},initialize:function(e){this.options=n.extend({},this.defaults,e);var t=r.get("Context/hosts");t&&(t.embed_host&&(this.options.embed_host=t.embed_host),t.secure_assets_host&&(this.options.secure_assets_host=t.secure_assets_host)),this.template=o},getCode:function(){return this.template(this.options)}});e.exports=a},93650(e,t,i){"use strict";var n=i(74692),s=i(55679),o=i(81515),r=i(71092),a=i(27496),l=r.extend({events:{"change .image-upload":"onImageUploadClick","click .btn-remove-uploaded":"onRemoveImageClick"},onImageUploadClick:function(e){var t=e.currentTarget;if(this.imageUploadEl=n(".image-upload-input"),this.documentPreviewEl=n(".document-upload-preview"),this.imagePreviewEl=n(".image-upload-preview"),t.files&&t.files[0]){if(t.files[0].size>15e6)return a.trigger("drawerform:errortag:show",{field:this.imageUploadEl,text:o("File is too big.")}),void n(t).replaceWith(n(t).val("").clone(!0));if(a.trigger("drawerform:errortag:remove",{field:this.imageUploadEl}),this.imageUploadEl.addClass("hidden"),t.files[0].type.match(/^image/)){var i=new FileReader;i.readAsDataURL(t.files[0]),i.onload=s.bind(function(e){this.imagePreviewEl.removeClass("hidden"),e.target.result&&e.target.result.length?(this.imagePreviewEl.find("img").attr("src",e.target.result),this.imagePreviewEl.addClass("shown")):this.imageUploadEl.removeClass("hidden")},this)}else{this.documentPreviewEl.removeClass("hidden"),this.documentPreviewEl.find("img").attr("src","/images/check.webp"),this.documentPreviewEl.addClass("shown");for(var r=[],l=0;l<t.files.length;l++)r.push(t.files[l].name);this.documentPreviewEl.find("span").html(r.join(", "))}}},onRemoveImageClick:function(e){e.preventDefault();var t=n(".image-upload-input input");t.replaceWith(t.val("").clone(!0)),n(".image-upload-input input").trigger("change"),this.imagePreviewEl.removeClass("shown"),this.documentPreviewEl.removeClass("shown"),this.imageUploadEl.removeClass("hidden")}});e.exports=l},93664(e,t,i){"use strict";var n=i(50283),s=i(39770),o=i(55679),r=i(80476),a=i(80976).Ay,l=i(27496),c=i(5143),u=i(97030),h=n.extend({className:"carousel-container",template:r,hasPeeked:!1,mixins:[u],subviews:{carouselPositionView:{constructor:s,options:function(e){return{photoCount:e.model.get("photoset_photos").length}}}},events:{"click .carousel-item-container a":"contentLinkClick"},initialize:function(e){e=e||{},this.currentItem=0,this.redirectUrlPrimary=e.redirect_url_primary,this.setupWatcher(),this.model.set("is_carousel",!0),this.model.set("carousel_index",this.currentItem)},afterRenderSubviews:function(){var e=this;o.defer(function(){e.imageWidth=e.carouselPositionView.$el.width(),window.parent.postMessage("resize_photoset_iframe;"+e.model.get("id")+";"+e.imageWidth,"*")}),this.carouselItemContainer=this.$(".carousel-item-container"),this.listenTo(this.carouselPositionView,"switchCarouselItem",this.processCarouselItemSwitch),this.listenTo(this.carouselPositionView,"peekLeft",this.peekLeft),this.listenTo(this.carouselPositionView,"peekRight",this.peekRight),this.peekIfInViewport(),this.listenTo(l,"DOMEventor:flatscroll",o.throttle(this.peekIfInViewport,500),this)},render:function(){return this.$el.html(this.template({post:this.model,redirect_url_primary:this.redirectUrlPrimary})),this},peekIfInViewport:function(){var e=this;!this.hasPeeked&&this.watcher&&this.watcher.isFullyInViewport&&(this.carouselItemContainer.addClass("peek-animation"),c.animation(this.carouselItemContainer,function(){e.carouselItemContainer.removeClass("peek-animation")}),this.hasPeeked=!0,this.stopListening(l,"DOMEventor:flatscroll"),this.watcher=null)},peekLeft:function(){var e=this.$(".carousel-wrapper");e.addClass("peek-left-animation"),c.animation(e,function(){e.removeClass("peek-left-animation")})},peekRight:function(){var e=this.$(".carousel-wrapper");e.addClass("peek-right-animation"),c.animation(e,function(){e.removeClass("peek-right-animation")})},processCarouselItemSwitch:function(e){this.model.get("pt")&&l.trigger("carousel:slide",{loggingData:this.loggingData({userAction:"slide",extraData:{offset:this.currentItem,target_offset:e}})}),this.carouselItemContainer.css({transform:"translate3d("+e*-this.imageWidth+"px, 0, 0)"}),this.currentItem=e,this.model.set("carousel_index",e)},setupWatcher:function(){this.watcher=a.create(this.$el,-100)},contentLinkClick:function(){this.model.get("pt")&&l.trigger("carousel:click_thru",{loggingData:this.loggingData({userAction:"click_thru",extraData:{offset:this.currentItem}})})}});e.exports=h},94121(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(33253),r=i(54663),a=i(73783),l=s.extend({className:"inbox-header",template:a,defaults:{isComposing:!1},subviews:{senderView:{constructor:o,options:function(e){return{eventBus:e.eventBus,user:e.user,channels:e.channels,popoverContainer:e.popoverContainer,currentBlogModel:e.currentBlogModel}}},composeToggleView:{constructor:r,options:function(e){return{eventBus:e.eventBus,isNewEmptyInboxEnabled:e.isNewEmptyInboxEnabled}}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","user","channels","popoverContainer","currentBlogModel","isNewEmptyInboxEnabled"))},afterRenderSubviews:function(){this.listenTo(this.composeToggleView,"change:isComposing",function(e,t){this.set("isComposing",t)}),this.listenTo(this,"change:isComposing",function(e,t){this.composeToggleView.set("isComposing",t)})}});e.exports=l},94246(e,t,i){"use strict";var n=i(55679),s=i(21189),o=new(i(28724))({extend:{setNextLink:function(e){var t,i=this.hasNextPage();this._nextLink=e,i!==(t=this.hasNextPage())&&this.trigger("change:hasNextPage",this,t)},setPreviousLink:function(e){var t,i=this.hasPreviousPage();this._previousLink=e,i!==(t=this.hasPreviousPage())&&this.trigger("change:hasPreviousPage",this,t)},getNextLink:function(){return this._nextLink},getPreviousLink:function(){return this._previousLink},hasNextPage:function(){return!n.isEmpty(this.getNextLink())},hasPreviousPage:function(){return!n.isEmpty(this.getPreviousLink())},fetchNextPage:function(e,t){return e=e||{},this.hasNextPage()?(!1!==e.isInfiniteScroll&&n.extend(e,{skipParsePreviousLink:!0,remove:!1}),this._fetchPage(this.getNextLink(),e)):s.reject()},fetchPreviousPage:function(e,t){return e=e||{},this.hasPreviousPage()?(!1!==e.isInfiniteScroll&&n.extend(e,{skipParseNextLink:!0,remove:!1}),this._fetchPage(this.getPreviousLink(),e)):s.reject()},_fetchPage:function(e,t){var i=n.isString(e)?e:e.href;return t=t||{},n.extend(t,{url:i}),this.fetch(t)}},defaults:{parsePreviousLink:function(e,t){return null},parseNextLink:function(e,t){return null}},before:{reset:function(e){this.setPreviousLink(null),this.setNextLink(null)},parse:function(e,t){(t=t||{}).skipParseLinks||(!t.skipParsePreviousLink&&n.isFunction(this.parsePreviousLink)&&this.setPreviousLink(this.parsePreviousLink(e,t)),!t.skipParseNextLink&&n.isFunction(this.parseNextLink)&&this.setNextLink(this.parseNextLink(e,t)))}}});e.exports=o},94337(e,t,i){"use strict";var n=i(45736).acequire("ace/lib/dom"),s={isDark:!0,cssClass:"ace-tumblr",cssText:i(93342).A};n.importCssString(s.cssText,s.cssClass),e.exports=s},94386(e,t,i){"use strict";var n=i(97583).extend({logKey:"postform_interactions",logOptions:{init_event:!1},events:{"postform-interaction:*":"handleEvent"},logEnv:{location:document.location.pathname},handleEvent:function(e,t){this.log(e,t)}});e.exports=n},94625(e,t,i){"use strict";var n=i(55679),s=i(25252),o=i(50283),r=i(29131),a=o.extend({className:"gif-search-message",template:r,defaults:{header:"",body:"",hasResults:!1},events:{"click [data-js-showResults]":"_onClickShowResults"},initialize:function(e){n.extend(this,n.pick(e,"eventBus"))},_onClickShowResults:function(){this.eventBus.trigger("showHiddenResults")},_filterMessageHtml:function(e,t){t.find("script, link").remove(),t.find("a[onerror]").removeAttr("onerror")},getTemplateData:function(){var e=o.prototype.getTemplateData.apply(this,arguments);return e.body=s(e.body||"",this._filterMessageHtml),e},afterRender:function(){this.rendered||this.listenTo(this,"change",this.render),this.$el.toggleClass("gif-search-message--hidden",!(this.get("header")||this.get("message")))},setMessage:function(e,t,i){n.isString(t)||(t=e,e=""),n.isBoolean(i)||(i=this.get("hasResults")),this.set({header:e,body:t,hasResults:i}),t||e?this.show():this.hide()},show:function(){this.$el.removeClass("gif-search-message--hidden")},hide:function(){this.$el.addClass("gif-search-message--hidden")}});e.exports=a},94755(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(44384),r=i(13482),a=i(27496),l=i(80234),c=o.extend({heartTemplate:l,mixins:[r],events:function(){return{click:this.isLoggedIn()?"onClick":this.redirect("/register?redirect_to=/explore")}},initialize:function(e){this.listenTo(this.model,"like:set",this.updateLikeStatus),this.listenTo(this.model,"unlike:set",this.updateLikeStatus),this.render()},onClick:function(e){e.preventDefault(),this._liked()?(this.model.unlike(),this._logUnlike()):(this.model.like(),this._logLike())},render:function(){return this},_liked:function(){return this.model.get("liked")},updateLikeStatus:function(){var e=this._liked();this.$el.toggleClass("liked",e);var t=s(this.heartTemplate({liked:e}));this.$el.append(t),n.delay(function(){t.fadeOut(200,function(){t.remove()})},300)},_logLike:function(){a.trigger("post:like:set",{loggingData:{blog:this.model.get("tumblelog"),post_id:this.model.id,position:this.model.get("collection_index"),initiator:"post_masonry"}})},_logUnlike:function(){a.trigger("post:unlike:set",{loggingData:{blog:this.model.get("tumblelog"),postId:this.model.id,position:this.model.get("collection_index"),initiator:"post_masonry"}})}});e.exports=c},95141(e,t,i){"use strict";e.exports=i(20948)},95185(e,t,i){"use strict";var n=i(55679),s=i(81515),o=i(50283),r=i(98237),a=i(86115),l=i(76689),c=i(85757),u=i(97016),h=i(95759),d=i(83121),p=i(16572),g=i(44727),f=o.extend({className:"conversation-message",template:l,mixins:[r],defaults:{pendingClassName:"is-pending"},events:{"click [data-js-retry-button]":"_onRetryClick"},messagesTypes:{},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","participants","conversation","afterRetryClick","formatter","animateInMessage","afterImageUnblur","isSafeModeEnabled","canModifySafeMode","isProjectXEnabled")),this.addMessageType(a.STICKER,g,function(e){return{conversation:e.conversation}}),this.isProjectXEnabled&&!this.canModifySafeMode&&!0===this.model.get("post").get("is_nsfw")?this.addMessageType(a.POST,h,function(e){return{conversation:e.conversation,canModifySafeMode:e.canModifySafeMode}}):this.addMessageType(a.POST,u),this.addMessageType(a.IMAGE,d,function(e){return{conversation:e.conversation,afterImageUnblur:n.bind(e.afterImageUnblur,e)}}),this.addMessageType(a.TEXT,c,function(e){return{formatter:e.formatter}})},afterRenderSubviews:function(){var e=this.createMessageView(this.model.get("type"));e?(this.js$("message-container").html(e.render().$el),this.model.get("hasAnimation")&&n.isFunction(this.animateInMessage)&&this.animateInMessage(this,this.js$("message-bubble"),this.model),this.listenTo(this.model,"change:isPending",this._onChangeIsPending),this.listenTo(this.model,"change:isError",this._onChangeIsError),this.listenTo(this.model,"change:isCollapsed",this._onChangeIsCollapsed),this.listenTo(this.model,"change:isQueued",this._onChangeIsQueued),this.listenTo(this.model,"change:tsHeader",this._onChangeTsHeader),this.listenTo(this.model,"change:isPending change:isError change:canRetry change:id",this.setRetryButtonState),this._onChangeIsPending(this.model,this.model.get("isPending")),this._onChangeIsError(this.model,this.model.get("isError")),this._onChangeTsHeader(this.model,this.model.get("tsHeader")),this._onChangeIsCollapsed(this.model,this.model.get("isCollapsed")),this._onChangeIsQueued(this.model,this.model.get("isQueued")),this.setRetryButtonState()):this.remove()},addMessageType:function(e,t,i){this.messagesTypes[e]={constructor:t,options:i}},getMessageType:function(e){return n.get(this.messagesTypes,e)},createMessageView:function(e){var t,i=this.getMessageType(e);return n.isEmpty(i)||!n.has(i,"constructor")?null:(t=n.get(i,"options",{}),n.isFunction(t)&&(t=t.call(this,this)),n.extend(t,{model:this.model,participants:this.participants,eventBus:this.eventBus,setRetryButtonState:n.bind(this.setRetryButtonState,this)}),new i.constructor(t))},setRetryButtonState:function(){var e,t,i,n,o,r,a,l;this.rendered&&0!==(e=this.js$("retry-button",!0)).length&&(o=this.model.isNew(),t=this.model.get("isPending"),i=this.model.get("canRetry"),n=this.model.get("isError"),r=s(i?"Retry":"Could not send"),a=t?s("Trying..."):r,l=n&&o,e.toggle(l),l&&(e.text(a).prop("disabled",t||!i),e.toggleClass(this.get("pendingClassName"),t)))},_onChangeTsHeader:function(e,t){this.timestampView&&this.timestampView.remove(),n.isEmpty(t)||(this.timestampView=new p({model:this.model}),this.$el.prepend(this.timestampView.render().$el))},_onChangeIsCollapsed:function(e,t){this.$el.toggleClass("collapsed",t)}
1,_onChangeIsPending:function(e,t){this.$el.toggleClass("pending",t)},_onChangeIsError:function(e,t){this.$el.toggleClass("error",t)},_onChangeIsQueued:function(e,t){this.$el.toggleClass("queued",t)},_onRetryClick:function(e){e.preventDefault(),this.model.get("canRetry")&&(this.trigger("retryClick",this.model),n.isFunction(this.afterRetryClick)&&this.afterRetryClick(this.model))}});e.exports=f},95207(e,t,i){"use strict";var n=i(55679),s=i(21189),o=i(27513),r=i(87564),a=o.extend({model:r,resultCountForQuery:function(e){e=(e||"").toLowerCase().trim();var t=this.get(e);return t?t.media.length:0},fetchGifs:function(e,t,i,o){var a,l=s.defer();e=(e||"").toLowerCase().trim();var c=this.get(e);return c||(c=new r({query:e,limit:t,loggingContext:i}),this.add(c)),!o&&n.now()-c.get("ts")<3e5?(this.trigger("search",e,!0),l.resolve(c)):(this.trigger("search",e,!1),a=c.fetch({success:function(){a=null,l.resolve(c)},error:function(e){a=null,l.reject(e)}})),l.promise.catch(function(){a&&a.abort()}),l},clearCache:function(e){this.remove(e)}});e.exports=a},95759(e,t,i){"use strict";var n=i(55679),s=i(97016),o=i(96791),r=i(66419),a=i(27496),l=i(74692),c=s.extend({className:"conversation-message-safemode-post",template:r,events:{"click .link-safemode-settings":"_onlinkClick"},initialize:function(e){n.extend(this,n.pick(e,"conversation","canModifySafeMode")),s.prototype.initialize.apply(this,arguments)},getTemplateData:function(){var e=this.model.get("post"),t=this.participants.get(this.model.get("participant")),i=this.getThumbnailAtWidth(this.get("thumbnailWidth"));return{postType:e.getType(),isDisabled:e.isDisabled(),actionString:t?e.getActionMarkup(t.get("name")):null,thumbnail:i,avatarUrl:t?t.getAvatarUrl():null,name:t?t.get("name"):null,blogUrl:t?t.get("url"):null,canModifySafeMode:this.canModifySafeMode?this.canModifySafeMode:null,isProjectXEnabled:this.isProjectXEnabled?this.isProjectXEnabled:null}},afterRenderSubviews:function(){this.theme=new o({el:this.el,theme:this.conversation.getOtherParticipant().get("theme")}).render()},_onlinkClick:function(e){e.preventDefault();a.trigger("Kraken:safeMode:FilteringSettingLinkClicked",{loggingData:{source:"messaging_post"}}),window.open(l(e.currentTarget).attr("href"))}});e.exports=c},95852(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<img src=\"' +\n__e( src ) +\n'\" width=\"' +\n__e( width ) +\n'\" height=\"' +\n__e( height ) +\n'\" alt=\"' +\n__e( __('GIF') ) +\n'\">';\n\n}\nreturn __p\n}").apply(void 0,r(s))},95870(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}var s=i(55679),o={aElement:document.createElement("a"),acceptedProtocols:["http:","https:","tumblr:","mailto:"],_setUrl:function(e){return this.aElement.setAttribute("href",e),this.aElement.setAttribute("href",this.aElement.href),this.aElement.href},parseUrl:function(e){if(!s.startsWith(e,"http"))throw new URIError("Missing protocol in URL to be parsed. Must be http or https");return this._setUrl(e),{url:e,href:this.aElement.href,protocol:this.aElement.protocol,host:this.aElement.hostname,port:this.aElement.port,query:this.aElement.search,hash:this.aElement.hash,path:this.aElement.pathname}},parseTumblelogUrl:function(e){try{-1===e.indexOf("://")&&(e="https://"+e);var t=this.parseUrl(e),i=!1;if(s.endsWith(t.host,"tumblr.com")?i=t.host.match(/([a-zA-Z0-9-_]+)\.tumblr\.com/i):s.endsWith(t.host,"tumblr.net")?i=t.host.match(/(?:^|\/\/)(?:([\w\-\_]+)\.)(?:[\w\-\_]+\.)*tumblr\.net/i):s.endsWith(t.host,"t.dev")&&(i=t.host.match(/([a-zA-Z0-9-_]+)\.t\.dev/i)),i){var n=i[1];if("www"===n)return!1;var o={tumblelog_name:n},r=t.path.match(/post\/([0-9]+)/i);return r&&(o.post_id=r[1]),o}return!1}catch(e){return!1}},isTumblelogUrl:function(e){return!1!==this.parseTumblelogUrl(e)},parseTumblelogShortUrl:function(e){try{-1===e.indexOf("://")&&(e="https://"+e);var t=this.parseUrl(e);return"tmblr.co"===t.host&&(s.startsWith(t.path,"/m")?{mentionKey:t.path.match(/^\/m([^\/]+)/)[0]}:!!s.startsWith(t.path,"/Z")&&{postTinyUrlHash:t.path.match(/^\/Z([^\/]+)/)[0]})}catch(e){return!1}},isTumblelogShortUrl:function(e){return!1!==this.parseTumblelogShortUrl(e)},isTumblrMediaUrl:function(e){return!!e&&(-1===e.indexOf("://")&&(e="https://"+e),!!e.match(/^https?:\/\/(\d+\.)media\.tumblr\.com\//i))},hasAllowedProtocol:function(e){this._setUrl(e);var t=this.aElement.protocol;if(":"===t&&(t=location.protocol),-1===this.acceptedProtocols.indexOf(t))throw new Error("Unsupported protocol detected in URL: "+e);return!0},isAbsoluteUrl:function(e){return!!new RegExp("^(?:[a-z]+:)?//","i").test(e||"")},getParameter:function(e){var t=(new RegExp("[?|&]"+e+"=([^&;]+?)(&|#|;|$)").exec(location.search)||[null,""])[1].replace(/\+/g,"%20");return decodeURIComponent(t)||null},httpBuildQuery:function(e,t){var i=[];for(var s in e)if(e.hasOwnProperty(s)){var o=t?t+"["+s+"]":s,r=e[
1s];if(!r)continue;i.push("object"===n(r)?this.httpBuildQuery(r,o):encodeURIComponent(o)+"="+encodeURIComponent(r))}return i.join("&")},buildUrl:function(e,t){var i=this.httpBuildQuery(t);return e+(s.isEmpty(i)?"":"?"+i)},getQueryStringHash:function(e){var t={};return e.replace(new RegExp("([^?=&]+)(=([^&]*))?","g"),function(e,i,n,s){t[i]=s}),t},isProtocolRelative:function(e){return new RegExp("^//[^/]","i").test(e||"")},getExtension:function(e){var t,i;return this.isProtocolRelative(e)&&(e=this.addProtocolIfMissing(e,"https:")),s.startsWith(e,"http")&&(i=this.parseUrl(e),s.isEmpty(i.path)||(t=i.path)),t||(t=e),s.last(t.split("."))},addProtocolIfMissing:function(e,t){if(s.any(this.acceptedProtocols,function(t){return s.startsWith(e,t)}))return e;if(-1===this.acceptedProtocols.indexOf(t))throw new Error("Attempting to add an unsupported protocol: "+t);return(this.isProtocolRelative(e)?t:t+"//")+e}};e.exports=o},95921(e,t,i){"use strict";var n=i(55679),s={normalizeSpace:function(e){return e.trim().replace(" "," ").replace(/\s\s+/," ")},stripScripts:function(e){return e.replace(new RegExp("<script[^>]*>([\\S\\s]*?)</script\\s*>","img"),"")},stripTags:function(e){return e.replace(/<\w+(\s+("[^"]*"|'[^']*'|[^>])+)?>|<\/\w+>/gi,"")},truncateLongStrings:function(e,t,i){return n.isString(e)||(e=""),i||(i="…"),e.length<=t?e:n.trunc(e,t-i.length,i)},stripHtml:function(e,t,i){if(!e)return"";void 0===t&&(t=!0);var s=e;"string"==typeof i&&(s=n.trim(s.replace(/(<br\s*\/?>)/gi,"$1"+i).replace(/(<\/(?:p|figure|h[1-6])\s*>)/gi,"$1"+i)));try{var o=document.implementation.createHTMLDocument("");o.body.innerHTML=this.stripScripts(s),s=(s=o.body.textContent||o.body.innerText||"").trim()}catch(e){s=this.stripScripts(this.stripTags(s)).trim()}return t&&(s=this.normalizeSpace(s)),s}};e.exports=s},96152(e,t,i){"use strict";var n=i(33300);e.exports=n},96187(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<div class=\"form-main\"><textarea spellcheck=\"false\" readonly=\"readonly\" data-js-embed-code class=\"embed-code textarea\" aria-label=\"' +\n__e( __('Embed code') ) +\n'\">' +\n__e( embedCode ) +\n'</textarea></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},96399(e,t,i){"use strict";var n=i(71742),s=i(19124),o=n.extend({name:"FlatSelect",view:function(e){return new s(e)}});e.exports=o},96500(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape;\nwith (obj) {\n__p += '<source src=\"' +\n__e( filePath ) +\n'\" type=\"' +\n__e( fileType ) +\n'\">';\n\n}\nreturn __p\n}").apply(void 0,r(s))},96589(e){"use strict";var t=(window.URL||window.webkitURL||window.mozURL||window.msURL||{}).createObjectURL;e.exports=t},96663(e,t,i){"use strict";var n=i(44384).extend({events:{click:"toggleVideoPlayer"},toggleVideoPlayer:function(e){var t=this.$(".video_embed"),i=t.data("render-context"),n=this.$("script.embed_source");"blank"!==i?n.length&&(this.$(".video_poster").hide(),n.parent().html(n.html())):window.open(t.data("post-url"))}});e.exports=n},96791(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(98237),r=i(38578),a=i(44890),l=s.extend({mixins:[o,r],defaults:{removeDataAttrAfterApplyingTheme:!0},configuration:{"theme-background-color":{themeField:"background_color",applyStyle:"background-color"},"theme-accent-color":{themeField:"link_color",applyStyle:"color"},"theme-accent-color-on-white":{themeField:"link_color",unsetMissingStyle:"color",applyStyle:function(e,t,i){e.css("color",i.adjustColorForBackground(t,"#ffffff"))}},"theme-accent-color-on-grey":{themeField:"link_color",unsetMissingStyle:"color",applyStyle:function(e,t,i){e.css("color",i.adjustColorForBackground(t,"#f2f2f2"))}},"theme-accent-color-on-background":{themeField:"link_color",unsetMissingStyle:"color",applyStyle:function(e,t,i){e.css("color",i.getReadableColor(t,i.get("background_color")))}},"theme-accent-color-as-background":{themeField:"link_color",unsetMissingStyle:"background-color",applyStyle:function(e,t,i){e.css("background-color",i.adjustColorForBackgroun
1d(t,"#ffffff"))}},"theme-button":{themeField:function(e){var t=e.get("background_color"),i=e.get("link_color");return n.isEmpty(t)||n.isEmpty(i)?null:{text:t,background:e.getReadableColor(i,t)}},applyStyle:function(e,t,i){e.addClass("themed"),i.getHeaderImage()||e.css({"background-color":t.background,"border-color":t.background,color:t.text})}},"theme-header-image":{themeField:function(e){return e.getHeaderImage()},applyStyle:function(e,t){e.css("background-image","url("+t+")")}},"theme-background-tint":{themeField:function(e){return e.getTintSuffix(e.getBackgroundTint())},applyStyle:function(e,t,i){e.addClass("theme-background"+t)}},"theme-background-color-or-image-class":{themeField:"background_color",applyStyle:function(e,t,i){n.isEmpty(i.getHeaderImage())?e.css("background-color",t):e.addClass("has-image")}},"theme-avatar-shape-class":{themeField:"avatar_shape",applyStyle:function(e,t){e.addClass("avatar-shape--"+t)}}},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"theme"))},render:function(){this.theme&&!a.bool("aim_messenger")&&n.each(this.configuration,function(e,t){var i,s,o=e.unsetMissingStyle,r=e.applyStyle;i=n.isFunction(e.themeField)?e.themeField.call(this,this.theme):this.theme.get(e.themeField),0!==(s=this.js$(t)).length&&(n.isEmpty(i)?n.isFunction(o)?o.call(this,s,i,this.theme):n.isEmpty(o)?n.isFunction(r)||s.css(r,""):s.css(o,""):(n.isFunction(r)?r.call(this,s,i,this.theme):s.css(r,i),this.get("removeDataAttrAfterApplyingTheme")&&s.removeAttr("data-js-"+t)))},this)},setTheme:function(e){return this.theme=e,this.render()}});e.exports=l},96991(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function s(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,o(n.key),n)}}function o(e){var t=function(e,t){if("object"!=n(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var s=i.call(e,t||"default");if("object"!=n(s))return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==n(t)?t:t+""}var r=i(95349),a=function(){return e=function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.body=document.body},(t=[{key:"fireBeacon",value:function(e){var t=this,i=document.createElement("div");i.setAttribute("src",e),i.style.display="none",i.addEventListener("load",function(){r.logSaw("moatLogs","endpoint fired: ".concat(e)),t.destroyIframe(i)}),this.body.appendChild(i)}},{key:"destroyIframe",value:function(e){this.body.removeChild(e)}}])&&s(e.prototype,t),i&&s(e,i),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,i}();e.exports=a},97016(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(98237),r=i(98621),a=i(4068),l=s.extend({className:"conversation-message-post",mixins:[o],template:a,defaults:{thumbnailWidth:210},initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"eventBus","participants","model","setRetryButtonState"))},afterRenderSubviews:function(){this.listenTo(this.model,"change:isError change:isPending",this._onModelChange),this.listenTo(this.model.get("post"),"change:summary change:state",this._onModelChange),this._startTruncateSummary()},getThumbnailAtWidth:function(e){var t,i=this.model.get("post"),s=i.getThumbnail(e);return n.isEmpty(s)?null:(t=i.getScaledDimensionsForWidth(s,e),n.extend({},s,t))},getTemplateData:function(){var e=this.model.get("post"),t=this.participants.get(this.model.get("participant")),i=this.getThumbnailAtWidth(this.get("thumbnailWidth"));return{postType:e.getType(),isDisabled:e.isDisabled(),isError:this.model.get("isError"),isPending:this.model.get("isPending"),actionString:t?e.getActionMarkup(t.get("name")):null,message:e.getMessage(),thumbnail:i,avatarUrl:t?t.getAvatarUrl():null,name:t?t.get("name"):null,blogUrl:t?t.get("url"):null,url:e.get("post_url"),postBlogName:e.get("blog_name"),postId:e.get("id")}},_startTruncateSummary:function(){n.defer(n.bind(this._truncateSummary,this))},_truncateSummary:function(){r(this.js$("summary",!0))},_onModelChange:function(){this.renderWithTemplate(),this._startTruncateSummary(),n.isFunction(this.setRetryButtonState)&&this.setRetryButtonState()}});e.exports=l},97030(e,t,i){"use strict";var n=i(55679),s=new(i(28724))({loggingData:function(e){var t={};return!n.isEmpty(this.model)&&n.isFunction(this.model.toJSON)&&(t.modelData=this.model.toJSON()),n.isObject(e)&&(t=n.extend(t,e)),t}});e.exports=s},97583(e,t,i){"use strict";var n=i(21391),s=i(55679),o=i(17145),r=i(27496),a=i(95349),l=[];l.push(i(892));var c=/^\/(.+)\/([gimy]*)$/,u=o.extend({constructor:function(){this._eventHandlers=[],this.setupEndpoints(),this.initialize();var e=s.result(this,"events")||{};
1s.forEach(e,this._addEventHandlerByString,this);var t=s.result(this,"eventBus");this.listenTo(t,"all",this._handleEvent),a.log("LogLady","[instrument]",this.logKey)},logSpots:l,eventBus:r,_addEventHandlerByString:function(e,t){var i,n=t.match(c);if(n){var s=new RegExp(n[1],n[2]);i=function(e){var t=e.match(s);if(t){for(var i=new Array(t.length-1),n=0;n<t.length;n+=1)n>0&&(i[n-1]=t[n]);return i}}}else if("*"===t[t.length-1]){var o=t.substring(0,t.length-1);i=function(e){if(0===e.indexOf(o))return[e.substring(o.length,e.length)]}}else i=function(e){return e===t?[e]:null};this._addEventHandler(e,i)},_addEventHandler:function(e,t){this._eventHandlers.push({method:e,matcher:t})},_handleEvent:function(e,t){for(var i,n,o,r=this._eventHandlers.length-1;r>=0;r--)(o=(i=this._eventHandlers[r]).callback||this[i.method])&&(n=i.matcher.call(this,e,t),s.isArray(n)&&(t&&t.loggingData&&n.push(s.cloneDeep(t.loggingData)),o.apply(this,n)))},setupEndpoints:function(){var e=s.result(this,"logSpots");this.loggers=s(e).map(function(e){return e(this)},this).compact().value()},initialize:s.noop,log:function(){for(var e=this.loggers.length-1;e>=0;e--){var t=this.loggers[e];t.trigger.apply(t,arguments)}}},{start:function(){return this._setupInstance||(this._setupInstance=new this),this._setupInstance}});s.extend(u.prototype,n.Events),e.exports=u},97736(e,t,i){"use strict";var n=i(71092),s=i(15897),o=n.extend({className:"tumblr-t",defaults:{height:120},initialize:function(e){e=e||{},this.height=e.height||this.defaults.height},render:function(){return this.$el.append(s({height:this.height})),this}});e.exports=o},97866(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(25352),r=i(4284),a=i(53750),l=(i(44890),i(24771),s.extend({defaults:{types:[]},initialize:function(e){n.defaults(e,this.defaults),this.collection=new r(e.types),this.collection.onStateModelChange(),this.tabsView=new o({collection:this.collection}),this.render()},render:function(){this.$el.append(this.tabsView.render().$el),this.setControlWidth(),this.setupOverflowHandler()},setControlWidth:function(){var e=this.$(".content-control").not(".more-controls"),t=e.length;function i(e){var t=window.getComputedStyle(e,null);return e.offsetWidth+(parseInt(t.getPropertyValue("margin-left"),10)||0)+(parseInt(t.getPropertyValue("margin-right"),10)||0)}for(var n=0;n<t;n++){var s=e[n];s.style.width=i(s)+3+"px",s.style["font-weight"]=""}},setupOverflowHandler:function(){this.tabOverflowHandler=new a({el:this.$(".more-controls"),collection:this.collection})}}));e.exports=l},97960(e,t,i){"use strict";var n=i(55679),s=i(74692),o=i(71092),r=i(27496),a=i(4298),l=o.extend({className:"recent_posts",template:a,events:{"click a":"onPostClick",mouseenter:"onMouseEnter"},defaults:{on_bottom:!0,blog_bg_color:!0,$popover:s(),min_load_time:500,model:{},dashboard_post:{}},initialize:function(e){n.extend(this,this.defaults,e),this.model&&(this.renderLoader(),this.renderInlineStyles(),this.posts=this.model.get("highlighted_posts"),n.isUndefined(this.posts)&&this.fetchPosts(),this.bindEvents())},bindEvents:function(){this.listenTo(this.model,"change:highlighted_posts",this.render),this.listenTo(this.model,"change:global_theme_params",this.renderInlineStyles)},fetchPosts:function(){this.model.fetch_popover_data({is_tumblelog_popover:!0})},updatePosts:function(e){this.model=e,this.posts=this.model.get("highlighted_posts"),n.isUndefined(this.posts)?this.fetchPosts():this.render(!0)},renderLoader:function(){var e=this.model.toJSON();this.$el.html(this.template({loader_color:e.global_theme_params?e.global_theme_params.title_color:"#D9D9D9"}))},renderInlineStyles:function(){var e=this.model.get("global_theme_params");e&&this.blog_bg_color&&(this.$el.css("background-color",e.background_color),this.$el.css("color",e.title_color))},render:function(e){var t=this.posts||this.model.get("highlighted_posts");if(!n.isArray(t))return this;var i=t.join("");return t.length<2?(setTimeout(n.bind(function(){this.$popover.addClass("is_empty"),this.$el.html("")},this),this.min_load_time),this):(this.$el.addClass("has_"+t.length+"_posts"),!0===e?this.$el.addClass("is_cached").html(i):setTimeout(n.bind(function(){this.$el.addClass("is_loaded").html(i)},this),this.min_load_time),this)},onPostClick:function(e){},onMouseEnter:function(e){r.trigger("TumblelogPopover:mouseenter_posts")}});e.exports=l},98044(e,t,i){"use strict";var n=i(55679),s=i(48357).animate,o=i(71092),r=i(64491),a=i(38578),l=o.extend({defaults:{hidden:!1,enabled:!0},mixins:[r,a],initialize:function(e){this.set("hasContent",e&&e.el),this.originalCSS=this._getCSS(["opacity"]),this.listenTo(this,"change:enabled",this._onChangeEnabled),this.listenTo(this,"change:hidden",this._onChangeHidden)},_getCSS:function(e){var t={};
1return n.forEach(e,function(e){t[e]=this.$el.css(e)},this),t},_onChangeEnabled:function(e,t){this.$el.toggleClass("no-pointer-events",!t)},_onChangeHidden:function(e,t){this.$el.toggleClass("collapse",t)},measureHeight:function(){if(!this.get("hasContent"))return null;var e=this.get("hidden");this.set("hidden",!1);var t=this.$el.outerHeight();return this.set("hidden",e),t},animateShow:function(e,t){return e||(e=0),t||(t=0),s(this.$el,{opacity:1},{duration:e,delay:t,begin:n.bind(function(){this.set("hidden",!1)},this)})},animateHide:function(e,t){return e||(e=0),t||(t=0),s(this.$el,{opacity:0},{duration:e,delay:t}).then(n.bind(function(){this.set("hidden",!0)},this))},render:function(){return this},teardown:function(){return this.$el.css(this.originalCSS),this}});e.exports=l},98052(e,t,i){var n=i(55679),s=i(74692),o=i(21391),r=(i(95349),i(44890)),a=i(27839).getRealNow,l=i(57220),c=i(31859),u=i(66303),h=[].slice,d=i(78947),p=i(27687),g=i(10708);function f(e){this.watching={},this.pending_events=[],this.endpoint=e.endpoint,this.overrides=e.overrides,e.event_payload_name&&(this.event_payload_name=e.event_payload_name),e.event_filter&&(this.event_filter=e.event_filter),e.payload_formatter&&(this.payload_formatter=e.payload_formatter),n.bindAll(this,"_flush_from_timeout"),this._flush_from_timeout();var t=e.EventClass||g;this.Log=p.extend({EventClass:t}),s(window).on("beforeunload.log_lady",n.bind(this._flush_on_unload,this)),this.set_flush_rate()}n.extend(f.prototype,o.Events,{initialize:n.noop,defaults:{flush_rate:15e3},min_flush_rate:function(){var e=n.map(this.watching,function(e){return n.result(e,"flush_rate")});return e.push(this.defaults.flush_rate),n.min(e)},set_flush_rate:function(e){return e&&(this.defaults.flush_rate=e),this.flush_rate=this.min_flush_rate(),this.flush_is_overdue()&&this._flush_from_timeout(),this.flush_rate},flush:function(){var e=n.result(this,"endpoint"),t=this.build_payload();if(e&&!n.isEmpty(t)&&(!this.event_payload_name||!n.isEmpty(t[this.event_payload_name]))&&r.bool("log_lady")){0;var i=s("#tumblr_form_key").attr("content");return i&&(t.form_key=i),u(e,t,!this.unloading),this.last_flush_at=a(),!0}},_flush_on_unload:function(){this._flush_timeout&&clearTimeout(this._flush_timeout),this._trigger_unloads(),this.unloading=!0,this.flush()},_trigger_unloads:function(){var e;for(var t in this.watching)"function"==typeof(e=this.watching[t]).unloaded&&e.unloaded()},_flush_from_timeout:function(){this._flush_timeout&&clearTimeout(this._flush_timeout),!1!==this.flush()&&(this._flush_timeout=setTimeout(this._flush_from_timeout,this.flush_rate))},flush_is_overdue:function(){return this.last_flush_at||(this.last_flush_at=a()),a()-this.last_flush_at>this.flush_rate},watch:function(){var e,t,i,s=h.apply(arguments);for(i=0;i<s.length;i++)e=s[i],this.is_valid(e)&&(e.log_lady=this,this.watching[e.log_key]&&(t=this.watching[e.log_key])&&n.isFunction(t.replaced)&&t.replaced(e),this.watching[e.log_key]=e);return this.set_flush_rate(),this},unwatch:function(e){this.watching[e.log_key]&&e&&n.isFunction(e.replaced)&&e.replaced(),delete this.watching[e.log_key]},pending_log_events:function(){var e=this.pending_events;return this.pending_events=[],e},payload_formatter:function(e){return e},event_filter:function(){return!0},build_payload:function(){var e=n.merge({},this.watching,[this]),t=n(e).collect(function(e){return e.pending_log_events()}).flatten().filter(this.event_filter).collect(n.bind(function(e){return e.json},this)).value(),i={};return this.event_payload_name?i[this.event_payload_name]=this.payload_formatter(t):i=this.payload_formatter(t),i},is_valid:function(e){var t=!!e;return t&&(t=n.result(e,"log_key")),t&&(t=n.result(e,"uuid")),t&&(t=n.isFunction(e.pending_log_events)),t},log:function(e,t){if(e){if(!(e in this.watching)){t&&t.log_key&&console.warn("log key gets overridden by log name");var i=d("keys",e);t=n.extend({},i,t,{log_key:e});var s=new this.Log(t);this.watch(s)}return this.watching[e]}},new_uuid:c}),f.extend=l,f.Log=p,e.exports=f},98237(e,t,i){"use strict";var n=i(55679),s=i(28724);function o(e){return n.trim(e)}var r=function(e,t){return e=o(e),t&&n.isFunction(this.$$)&&this.$$.cache.delete(e),e},a=function(e){if(this.$$)return e=o(e),this.$(e)},l=function(e){this.$$&&(e=o(e),this.$$.cache.delete(e))},c=function(e){if(this.$$)return e=o(e),this.$$.cache.delete(e),this.$(e)},u=function(){this.$$&&(this.$$.cache=new n.memoize.Cache)},h=function(e){return"[data-js-"+e+"]"},d=function(e){return function(){var e=n.memoize(n.bind(a,this),n.bind(r,this));e.update=n.bind(c,this),e.remove=n.bind(l,this),e.empty=n.bind(u,this);var t=function(t,i){return e(h(t),i)};return t.update=function(t){e.update(h(t))},t.remove=function(t){e.remove(h(t))},this.$$=e,this.js$=t,this.$$initialize=n.noop,e}.call(e)},p=new s({defaults:{$$cacheKeys:{},$$cacheSelectors:function(e){return void 0===e&&(e=this.$$cacheKeys),n.forEac
1h(e,function(e){this.$$.update(e)},this),this},$$initialize:function(){return d(this)},$$:function(){return d(this).apply(this,arguments)}},before:{initialize:function(){this.$$initialize()},render:function(){this.$$.empty()}},after:{setElement:function(){n.isFunction(this.$$.empty)&&this.$$.empty()},remove:function(){n.isFunction(this.$$.empty)&&this.$$.empty()},render:function(){n.isFunction(this.$$cacheSelectors)&&this.$$cacheSelectors()}}});e.exports=p},98409(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<li><a class=\"external-link\" href=\"/settings/dashboard\">' +\n__e( __('Sound settings') ) +\n'</a></li><li><a href=\"#\" data-js-delete-conversation>' +\n__e( __('Delete conversation') ) +\n'</a></li> ';\n _.each(blockableParticipants, function(p) { ;\n__p += ' <li><a href=\"#\" data-js-block-blogname=\"' +\n__e( p.name ) +\n'\">' +\n__e( __('Block %1$s', p.name) ) +\n'</a></li> ';\n }) ;\n\n\n}\nreturn __p\n}").apply(void 0,r(s))},98544(e){function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t(e)}function i(e,t){for(var i=0;i<t.length;i++){var s=t[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(e,n(s.key),s)}}function n(e){var i=function(e,i){if("object"!=t(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var s=n.call(e,i||"default");if("object"!=t(s))return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===i?String:Number)(e)}(e,"string");return"symbol"==t(i)?i:i+""}var s=function(){return e=function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.beacons=[],this.ruleKey=t,this.originalRule=i,this.reqAudioOn=i.a||!1,this.reqContinuous=i.c||!1,this.reqDuration=i.d||!1,this.reqPercentInView=i.p||!1,this.reqRuleType=i.t||!1,this.firedBeacons=!1,this.totalTimeMeetingReqs=0,this.lastMetReqTime=0,this.macroValues={"$(V_VIEW_TYPE)":this.reqRuleType,"$(S_VIEW_TYPE)":this.reqRuleType}},(t=[{key:"reset",value:function(){this.totalTimeMeetingReqs=0}},{key:"checkRule",value:function(e){var t=!1;return this.audioCheck(e)||(t=!0),this.percentInView(e)||(t=!0),t?(this.reqContinuous&&(this.lastMetReqTime=!1),!1):(!1===this.lastMetReqTime?this.totalTimeMeetingReqs=0:this.totalTimeMeetingReqs+=e.timePosition()-this.lastMetReqTime,this.lastMetReqTime=e.timePosition(),this.durationCheck())}},{key:"setBeacons",value:function(e){this.beacons=e}},{key:"getBeacons",value:function(){return this.beacons}},{key:"audioCheck",value:function(e){return!this.reqAudioOn||!e.isMuted()}},{key:"percentInView",value:function(e){return!(this.reqPercentInView>0&&e.percentageInView()<this.reqPercentInView)}},{key:"durationCheck",value:function(){return!(this.reqDuration&&this.totalTimeMeetingReqs<this.reqDuration)}},{key:"getMacroValue",value:function(e){return this.macroValues[e]?this.macroValues[e]:"-1"}},{key:"print",value:function(e){console.log(e,this.ruleKey,this.originalRule)}}])&&i(e.prototype,t),n&&i(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,n}();e.exports=s},98589(e,t,i){"use strict";var n=i(55679),s=i(91685),o=i(26024),r=i(27880),a=i(68707),l=i(13760),c=s.extend(o,{elSelector:".vjs-progress-holder",initialize:function(e,t){this.children={},this.$el=this.$$(this.elSelector),this.createChildren(),this.$player.on("mousemove.sliderHover",this.elSelector,n.bind(this.onMouseMove,this)),this.$player.on("mouseenter.sliderHover",this.elSelector,n.bind(this.onMouseEnter,this)),this.$player.on("mouseout.sliderHover",this.elSelector,n.bind(this.onMouseOut,this)),this.player.on("dispose",n.bind(this.dispose,this))},createChildren:function(){this.children.hoverSliderHandle=new r(this.player),this.children.hoverSliderTime=new a(this.player),this.player.options_.crtOptions.filmstrip&&(this.$el.addClass("with-filmstrip"),this.children.progressBarTooltip=new l(this.player)),this.appendChildren()},appendChildren:function(){n.each(this.children,n.bind(function(e){this.$el.append(e.render().$el)},this))},updateChildren:function(e){n.each(this.children,function(t){t.update(e)})},onMouseMove:function(e){this.$el.removeClass("auto-hide");var t=this.$el.offset(),i=this.$el.width(),n=e.pageX-t.left,s=Math.max(0,Math.min(1,(e.pageX-t.left)/i))*this.player.player().duration(),o=s/this.player.player().duration();n<0?n=0:n>i&&(n=i),this.updateChildren({hoverX:n,hoverTime:s,hoverPercent:o})},onMouseOut:function(e){this.$el.addClass("auto-hide")},onMouseEnter:function(e){this.$el.removeClass("auto-hide")},dispose:function(){n.each(this.children,function(e){n.result(e,"dispose")}),o.prototype.dispose.apply(this,arguments)}});e.exports=c},98621(e,t,i){"use strict";var n=i(55679),s=i(74692);function o(e,t){return e.scrollHeight-t.maxHeight<5}function r(e){return parseInt(s(e).css("max-height"),10)}function a(e,t,i){var r=s(e).contents();n.each(r.get().reverse(),function(e){e.nodeType===Node.TEXT_NODE?function(e,t,i){var s,r=e.nodeValue,a=n.get(t,"truncationString","..."),l="",c="",u=0,h=r.length;if(o(i,t))return!0;for(;u<=h;)s=u+h>>>1,l=n.trimRight(r.substring(0,s))+a,e.nodeValue=l,o(i,t)?(u=s+1,l.length>c.length&&(c=l)):h=s-1;c.length>0?e.nodeValue=c:e.nodeValue=""}(e,t,i):a(e,t,i)})}
1e.exports=function(e,t){if(t=t||{},n.defaults(t,{truncationString:"..."}),e instanceof s&&(e=e.get(0)),n.has(t,"maxHeight")||n.extend(t,{maxHeight:r(e)}),n.isFinite(n.get(t,"maxHeight"))&&!o(e,t))return a(e,t,e)}},98623(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n\n if (displayBackButton) { ;\n__p += ' <button class=\"survey-back-button\" data-survey-nav-back> ' +\n((__t = ( __('Go back') )) == null ? '' : __t) +\n' </button> ';\n } ;\n__p += ' ';\n if (typeof button !== 'undefined') { ;\n__p += ' ';\n if (button.type === 'submit') { ;\n__p += ' ';\n if (complete) { ;\n__p += ' <button class=\"chrome big right blue\" data-survey-submit> ';\n } else { ;\n__p += ' <button class=\"chrome big right blue\" data-survey-submit disabled=\"disabled\"> ';\n } ;\n__p += ' ';\n if (this.abuseform.get('blockFlagSet')) { ;\n__p += ' <span class=\"label\">' +\n__e( __('Submit and block') ) +\n'</span> ';\n } else { ;\n__p += ' <span class=\"label\">' +\n__e( __('Submit') ) +\n'</span> ';\n } ;\n__p += ' <span class=\"Knight-Rider-loader animate\"><span class=\"Knight-Rider-bar\"></span><span class=\"Knight-Rider-bar\"></span><span class=\"Knight-Rider-bar\"></span></span></button> ';\n } else if (button.type === 'dismiss') { ;\n__p += ' <button class=\"chrome big right red\" data-survey-dismiss><span class=\"label\">' +\n__e( __('Got it') ) +\n'</span></button> ';\n } else if (button.type === 'link') { ;\n__p += ' <a href=\"https://www.tumblr.com' +\n((__t = ( button.href )) == null ? '' : __t) +\n'\" class=\"chrome big right blue\"><span class=\"label\">' +\n__e( __(button.text) ) +\n'</span></a> ';\n } ;\n__p += ' ';\n } ;\n__p += '</button>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},98635(e,t,i){var n=i(55679),s=i(74692),o=function(){var e,t,i=function(){};return i.calcTextWidth=function(e,t){var i=n.reduce(["font-style","font-weight","font-size","font-family"],function(t,i){return t+" "+s(e).css(i)},"").trim(),o=document.createElement("canvas").getContext("2d");o.font=i;var r=o.measureText(t);return Math.round(r.width)},i.browser=(e=function(e){e=e.toLowerCase();var t=/(chrome)[ \/]([\w.]+)/.exec(e)||/(webkit)[ \/]([\w.]+)/.exec(e)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(e)||/(trident)[ \/]([\w.]+)/.exec(e)||/(msie) ([\w.]+)/.exec(e)||e.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(e)||[];return{browser:t[1]||"",version:t[2]||"0"}}(navigator.userAgent),t={},e.browser&&(t[e.browser]=!0,t.version=e.version),t.trident&&(t.msie=!0),t.chrome?t.webkit=!0:t.webkit&&(t.safari=!0),t),i}();e.exports=o},98979(e,t,i){"use strict";var n=i(55679),s=i(71092),o=i(53010),r=i(5143).transition,a=i(64491),l=i(59952),c=i(1218),u=s.extend({className:"popover--discover-tabs",events:{"click .content-control":"hide"},template:c,mixins:[a,l],render:function(){var e={types:this.collection.getHidden(),currentType:"todo-fix-this"};return this.$el.html(this.template(e)),this.$main=this.$el.find(".popover"),n.delay(n.bind(function(){this.$main.addClass("popover--active"),this.bindClickOutside()},this),1),this},bindClickOutside:function(){this.clickOutside=new o(this.el,{preventInteraction:!0}),this.clickOutside.on("click:outside",this.hide,this)},unbindClickOutside:function(){this.clickOutside&&(this.clickOutside.remove(),this.clickOutside=null)},hide:function(){this.unbindClickOutside(),this.$main.removeClass("popover--active"),r(this.$el,n.bind(function(){this.afterHide()},this))},afterHide:function(){this.remove()}});e.exports=u},99098(e,t,i){"use strict";var n=i(55679),s=i(27496);e.exports=function(e){e=n.extend({dest:!1,id:!1},e);var t={positions:{DEFAULT:{w:"300",h:"250"},LREC:{dest:!1,id:!1}},events:{getEm:{ps:["LREC"],sp:1197719223},AUTO:{sp:1197719223,ps:{LREC:{autoRT:1e4,autoIV:1,autoMax:25,id:"LREC"}},autoStart:1,autoRT:1e4,autoDDG:1,ssl:!0,npv:!0}},onFailure:function(){s.trigger("darla:failure",arguments)},onSuccess:function(){s.trigger("darla:success",arguments)}
1,onFinishParse:function(e,t){t.ps().forEach(function(e){""!==e.hasErr&&s.trigger("darla:failure",arguments)})}};return t.positions.LREC.dest=e.dest,t.positions.LREC.id=e.id,t}},99243(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"error-message\"><div class=\"error-text\"> ';\n if (errors) { ;\n__p += ' ';\n _.each(errors, function (error) { ;\n__p += ' <div>' +\n__e( error.error ) +\n'</div> ';\n }) ;\n__p += ' ';\n } else { ;\n__p += ' ' +\n((__t = ( __('Oops. There was an error. Try again.') )) == null ? '' : __t) +\n' ';\n } ;\n__p += ' </div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},99467(e,t,i){var n=i(55679),s=void 0!==n?n.templateSettings.imports:{},o=n.keys,r=n.values;e.exports=Function(o(s),"return function(obj) {\nobj || (obj = {});\nvar __t, __p = '', __e = _.escape, __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\nwith (obj) {\n__p += '<div class=\"conversation-header-image\" data-js-theme-header-image></div><div class=\"conversation-header-main\"><div data-js-title class=\"title\"> ';\n var lastIndex = participants.length - 2; ;\n__p += ' ';\n _.each(participants, function(p, i) { ;\n__p += ' <a href=\"' +\n__e( p.url ) +\n'\" target=\"_blank\" data-js-tumblelog-name=\"' +\n__e( p.name ) +\n'\">' +\n__e( p.name ) +\n'</a> ' +\n__e( (i === lastIndex) ? ' ' + separator + ' ' : (i < lastIndex ? ', ' : '') ) +\n' ';\n }) ;\n__p += ' </div><div class=\"controls\" data-js-theme-accent-color-on-background><a href=\"#\" data-js-more-actions class=\"more-actions\">' +\n__e( __('Actions') ) +\n'</a><a href=\"#\" data-js-minimize class=\"minimize\">' +\n__e( __('Minimize') ) +\n'</a><a href=\"#\" data-js-close class=\"close\">' +\n__e( __('Close') ) +\n'</a></div></div>';\n\n}\nreturn __p\n}").apply(void 0,r(s))},99631(e,t,i){"use strict";var n=i(55679),s=i(27513),o=i(99987),r=s.extend({model:o,getSortedModels:function(e){return this.sortBy(function(t){return t.get("uuid")===e?-1:0})},getSortedIds:function(e){var t=this.getSortedModels(e);return n.pluck(n.invoke(t,"toJSON"),"uuid")}});e.exports=r},99722(e,t,i){"use strict";var n=i(55679),s=i(50283),o=i(59796),r=i(96791),a=s.extend({className:"messaging-share-post-result",tagName:"a",attributes:{href:"#",tabIndex:1},events:{click:"_onSelect",focus:"_onFocus",blur:"_onBlur"},defaults:{isSelected:!1,isFocused:!1,selectedClass:"is-selected",focusedClass:"is-focused"},template:o,initialize:function(e){e=n.extend({},e),n.extend(this.attributes,n.pick(e,n.keys(this.defaults))),n.extend(this,n.pick(e,"onSelect","onFocus","onBlur"))},afterRender:function(){this.listenTo(this,"change:isSelected",this._onChangeIsSelected),this.listenTo(this,"change:isFocused",this._onChangeIsFocused),this.conversationTheme=new r({theme:this.model.get("theme"),el:this.el}).render()},getTemplateData:function(){return{name:this.model.get("name"),title:this.model.get("title"),avatarUrl:this.model.getAvatarUrl(),avatarShape:this.model.getAvatarShape()}},setSelected:function(e){this.rendered&&this.set("isSelected",e)},setFocused:function(e){this.rendered&&this.set("isFocused",e)},_onSelect:function(e){e.preventDefault(),n.isFunction(this.onSelect)&&this.onSelect(this,this.model)},_onFocus:function(e){e.preventDefault(),n.isFunction(this.onFocus)&&this.onFocus(this,this.model)},_onBlur:function(e){e.preventDefault(),n.isFunction(this.onBlur)&&this.onBlur(this,this.model)},_onChangeIsSelected:function(e,t){this.$el.toggleClass(this.get("selectedClass"),t)},_onChangeIsFocused:function(e,t){this.$el.toggleClass(this.get("focusedClass"),t),t&&this.$el.focus()}});e.exports=a},99987(e,t,i){"use strict";var n=i(55679),s=i(80160),o=i(26771),r=i(45707),a=i(80867),l=s.extend({idAttribute:"uuid",mixins:[o],relations:{conversations:r},defaults:{conversations:null,unread_messages_count_sum:0}});n.defaults(l.prototype,a.prototype),e.exports=l}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.