;// bundle: page___f0965c759f30cf7752d04c564bbd6f6e_m
;// files: Thumbnails/ThumbnailUtils.js, extensions/ThreeDeeThumbnails.js, extensions/AnimatedThumbnails.js, Thumbnails/ThumbnailView.js, Thumbnails/ThumbnailSpinner.js, ~/viewapp/widgets/lazyLoadImage/angularLazyImg.js, ~/Generated/js/Roblox_TranslationResources_Feature_ProfileResources_en_us_standard.js, ~/viewapp/pages/profile/profile.js, utilities/datetime/formatDateTimesI18n.js, ~/viewapp/pages/profile/services/profileUtilitiesConstantsServices.js, ~/viewapp/pages/profile/services/profileService.js, ~/viewapp/pages/profile/filters/profileHeaderStatusTextFilter.js, ~/viewapp/pages/profile/constants/layout.js, ~/viewapp/pages/profile/constants/profileJsonEndPoints.js, ~/viewapp/pages/profile/controllers/profileBaseController.js, ~/viewapp/pages/profile/controllers/profileUtilitiesController.js, ~/viewapp/pages/profile/controllers/profileHeaderController.js, ~/viewapp/pages/profile/controllers/profileAccoutrementsController.js, ~/viewapp/pages/profile/controllers/profileCollectionsController.js, ~/viewapp/pages/profile/controllers/profileGridController.js, ~/viewapp/pages/profile/directives/profileHeaderDataDirective.js, ~/viewapp/pages/profile/directives/profileUtilitiesDirective.js, ~/viewapp/pages/profile/directives/profileAccoutrementsDataDirective.js, ~/viewapp/pages/profile/directives/profileAccoutrementsSliderDirective.js, ~/viewapp/pages/profile/directives/profileAccoutrementsPageDirective.js, ~/viewapp/pages/profile/directives/profileEmptyTabDirective.js, ~/viewapp/pages/profile/directives/profileStatusInputElementDirective.js, ~/viewapp/pages/profile/directives/profileTabClickDirective.js, ~/viewapp/pages/profile/directives/scrollHorizontally.js, jquery/jquery.history.js, utilities/jquery.history.override.js, utilities/robloxTabs.js, utilities/robloxAds.js, StringTruncator.js, VotingPanel.js, GameItemCard.js, GenericConfirmation.js, utilities/dialog.js, common/deviceMeta.js, TosModalCheck.js, AbuseReport/AbuseReportDispatcher.js

;// Thumbnails/ThumbnailUtils.js
Roblox=Roblox||{},Roblox.ThumbnailUtils=function(){var n='<div class="thumbnail-loader"><span class="spinner spinner-default"></span></div>',t=".thumbnail-loader";return{addLightsToScene:function(n,t){var h=!1,o=$("#use-dynamic-thumbnail-lighting"),r,u,f,i,e,s,c;return o!==null&&o.length>0&&(h=o.data("use-dynamic-thumbnail-lighting")==="True"),h?(i=new THREE.AmbientLight(4473924),t.add(i),r=new THREE.DirectionalLight(13948116),r.target=t,r.position.set(-7.5,.5,-6).normalize(),t.add(r),u=new THREE.DirectionalLight(11316396),u.target=t,u.position.set(20,4,-0).normalize(),t.add(u),f=new THREE.DirectionalLight(11316396),f.target=t,f.position.set(0,1,1).normalize(),t.add(f)):(i=new THREE.AmbientLight(8882048),n.add(i),e=new THREE.DirectionalLight(11316396),e.position.set(-.671597898,.671597898,.312909544).normalize(),n.add(e),s=new THREE.DirectionalLight(4473924),c=(new THREE.Vector3).copy(e.position).negate().normalize(),s.position.set(c),n.add(s)),{scene:n,camera:t}}}}();

;// extensions/ThreeDeeThumbnails.js
$(function(){function r(n){var t,r;for(t in i)if(i[t].container==n)return i[t].renderer;return r={container:n,renderer:new THREE.WebGLRenderer({antialias:!0,alpha:!0})},i.push(r),r.renderer}function a(n,t){Roblox.ThumbnailUtils.addLightsToScene(n,t)}function u(n){n.find("canvas").remove()}function v(n){return n.parent()?typeof n.parent().data("moderation-mode")=="string":!1}function y(n,t,i,u,f,e){function l(){return i.parent().width()}function y(){return i.parent().height()}function b(){p.render(c,h)}function k(){w.enabled&&w.update(),TWEEN.update(),b(),requestAnimationFrame(k)}function it(){h.aspect=l()/y(),h.updateProjectionMatrix(),p.setSize(l(),y())}function rt(){p.setSize(l(),y());var n=p.domElement,t;$(window).resize(function(){clearTimeout(t),t=setTimeout(it,100)}).on("beforeunload",function(){$(n).hide()});return n}function ut(){var n=new THREE.OrbitControls(h,i.get(0),u,"static");return tt?(n.autoRotate=!1,n.minDistance=.1,n.noPan=!1,n.noKeys=!1,n.noResetToInitialCameraPosition=!0):(n.rotateSpeed=1.5,n.zoomSpeed=1.5,n.dynamicDampingFactor=.3),n.addEventListener("change",b),n}function g(n){a(c,h),c.add(h),c.add(n);var t=rt();w=ut(),b(),k(),f(t)}var p=r(i),tt=v(i),d=new THREE.Vector3(u.aabb.max.x,u.aabb.max.y,u.aabb.max.z).length()*4,ft=Math.max(d,s),nt=typeof u.camera.fov!="undefined"?u.camera.fov:70,h=new THREE.PerspectiveCamera(nt,l()/y(),o,ft),c=new THREE.Scene,w,et=new THREE.OBJMTLLoader;et.load(n,t,g,undefined,e)}var t=$("#image-retry-data"),f=t?t.data("ga-logging-percent"):0,e=window.GoogleAnalyticsEvents&&GoogleAnalyticsEvents.FireEvent||function(){},n=function(n){Math.random()<=f/100&&e(n)},o=.1,s=1e3,h=500,c=t?t.data("image-retry-max-times"):10,l=t?t.data("image-retry-timer"):1500,i=[];$.fn.load3DThumbnail=function(t,i){function o(){f=!0}function e(t,r,u,f){function o(i){if(i.realRegeneration=!0,u-->0)i.retriesDone++,setTimeout(function(){e(t,r,u,i)},l);else{var f=+new Date-i.start;n(["ThumbnailGenTime","3D","Gave Up",f]),n(["ThumbnailGenRetries","3D","Gave Up",i.retriesDone])}}function s(t,u){var f=+new Date-u.start;t.Final?$.getJSON(t.Url,function(t){u.realRegeneration&&(n(["ThumbnailGenTime","3D","Success",f]),n(["ThumbnailGenRetries","3D","Success",u.retriesDone])),r(t,u)}).fail(function(){n(["ThumbnailGenErrors","3D","Failure",t.Url]),n(["ThumbnailGenTime","3D","Failure",f]),n(["ThumbnailGenRetries","3D","Failure",u.retriesDone]),i("3D Thumbnail failed to load")}):o(u)}$.ajax({url:t+"&_="+$.now(),method:"GET",crossDomain:!0,contentType:"application/json; charset=utf-8",dataType:"json",xhrFields:{withCredentials:!0},cache:!1}).success(function(n){s(n,f)}).fail(function(){o(f)})}var f=!1;return this.each(function(){var o=$(this),s;try{s=function(){function v(){s&&(clearTimeout(s),s=undefined)}function p(){s=setTimeout(function(){f||Roblox.ThumbnailSpinner.show(o)},h)}function w(){v(),Roblox.ThumbnailSpinner.hide(o)}function b(n){var t=new MutationObserver(function(i){i.forEach(function(i){var f=i.removedNodes,u,e;if(i.type==="childList")for(u=0;u<f.length;++u)if(f[u]===n){e=r(o),e.forceContextLoss(),t.disconnect();return}})});t.observe(n.parentNode,{childList:!0})}function k(r,e){var s=+new Date;y(r.obj,r.mtl,o,r,function(i){if(u(o),!f){w(),o.append(i),b(i);var r=+new Date-s;e.realRegeneration&&n(["ThumbnailInBrowserRenderTime","3D","Success",r]),t(i,e)}},i)}var a={start:+new Date,realRegeneration:!1,retriesDone:0},l=Roblox.Endpoints.generateAbsoluteUrl(o.data("3d-url"),null,!0),s;l&&(u(o),p(),e(l,k,c,a))},s()}catch(l){i(l)}}),{cancel:o}}});

;// extensions/AnimatedThumbnails.js
$(function(){function f(n){n.find("canvas").remove()}function e(n){var i,r;for(i in t)if(t[i].container===n)return t[i].renderer;return r={container:n,renderer:new THREE.WebGLRenderer({antialias:!0,alpha:!0})},t.push(r),r.renderer}function y(n,t){Roblox.ThumbnailUtils.addLightsToScene(n,t)}function p(n,t,r){function p(){return n.parent().width()}function b(){return n.parent().height()}function ct(n,t,i){var f,u,r;i.preload(),f=new THREE.MTLLoader.MaterialCreator,f.setMaterials(i),t.children[1].geometry.computeBoundingBox(),u=t.children[1].geometry.boundingBox,r=new THREE.Vector3,r.subVectors(u.max,u.min),r.multiplyScalar(.5),r.add(u.min),r.applyMatrix4(t.children[0].matrixWorld),t.children[1].geometry.applyMatrix((new THREE.Matrix4).makeTranslation(-r.x,-r.y,-r.z)),t.children[1].geometry.verticesNeedUpdate=!0,t.children[1].position.x=r.x,t.children[1].position.y=r.y,t.children[1].position.z=r.z,ut[n]=t,t.matrixAutoUpdate=!1,o.add(t),rt++,lt()}function lt(){rt===kt&&at()}function at(){y(o,s),o.add(s);var n=ft();l=dt(o,s),d(),it(),r(n)}function d(){w.render(o,s)}function it(){wt(),l.enabled&&l.update(),TWEEN.update(),d(),u=requestAnimationFrame(it)}function wt(){var u,t,n,r;for(l.update(),c===nt.length&&(c=0,i+=1),u=nt[c],t=0;t<h.length;++t)n=u[h[t]],r=ut[h[t]],typeof n!="undefined"&&typeof r!="undefined"&&(r.children[1].position.set(n.Position.x,n.Position.y,n.Position.z),r.children[1].quaternion.set(n.Rotation.x,n.Rotation.y,n.Rotation.z,n.Rotation.w),r.updateMatrix());c++,o.updateMatrixWorld}function bt(){s.aspect=p()/b(),s.updateProjectionMatrix(),w.setSize(p(),b())}function ft(){w.setSize(p(),b());var n=w.domElement,t;$(window).resize(function(){clearTimeout(t),t=setTimeout(bt,100)}).on("beforeunload",function(){$(n).hide()});return n}function dt(i,r){var u=new THREE.OrbitControls(r,n.get(0),t,"animated");return u.addEventListener("change",d),u}var w=e(n),g=t.aabb.max,pt=new THREE.Vector3(g.x,g.y,g.z).length()*4,yt=Math.max(pt,v),vt=typeof t.camera.fov!="undefined"?t.camera.fov:70,s=new THREE.PerspectiveCamera(vt,p()/b(),a,yt),o=new THREE.Scene,k,nt,c;o.add(s);var l,ut={},et=new THREE.OBJMTLLoader,h=Object.keys(t.partobjs),rt=0,kt=h.length;for(k=0;k<h.length;++k){var tt=h[k],ot=t.partobjs[tt].files["scene.obj"].content,st=t.partobjs[tt].files["scene.mtl"].content;function ht(n){return function(t,i){return ct(n,t,i)}}et.load(ot,st,ht(tt))}nt=t.frames,c=0}var r=$("#image-retry-data"),o=10,s=r?r.data("ga-logging-percent"):0,h=window.GoogleAnalyticsEvents&&GoogleAnalyticsEvents.FireEvent||function(){},n=function(n){Math.random()<=s/100&&h(n)},c=500,l=1500,u=null,a=.1,v=1e3,t=[],i=0;$.fn.getNumOfLoops=function(){return i},$.fn.clearCurrentAnimationFrame=function(){i=0,cancelAnimationFrame(u)},$.fn.loadAnimatedThumbnail=function(t,r,u){function a(){s=!0}function h(t,i,u,f){function e(r){if(r.realRegeneration=!0,u-->0)r.retriesDone++,setTimeout(function(){h(t,i,u,r)},l);else{var f=+new Date-r.start;n(["ThumbnailGenTime","Animated","Gave Up",f]),n(["ThumbnailGenRetries","Animated","Gave Up",r.retriesDone])}}function o(t,u){var f=+new Date-u.start;t.Final?$.getJSON(t.Url,function(t){u.realRegeneration&&(n(["ThumbnailGenTime","Animated","Success",f]),n(["ThumbnailGenRetries","Animated","Success",u.retriesDone])),i(t,u)}).fail(function(){n(["ThumbnailGenErrors","Animated","Failure",t.Url]),n(["ThumbnailGenTime","Animated","Failure",f]),n(["ThumbnailGenRetries","Animated","Failure",u.retriesDone]),r("Animated Thumbnail failed to load")}):e(u)}$.ajax({url:t+"&_="+$.now(),method:"GET",crossDomain:!0,contentType:"application/json; charset=utf-8",dataType:"json",xhrFields:{withCredentials:!0},cache:!1}).success(function(n){o(n,f)}).fail(function(){e(f)})}var s=!1;return this.each(function(){var l=$(this),a;try{a=function(){function y(){a&&(clearTimeout(a),a=undefined)}function w(){a=setTimeout(function(){s||Roblox.ThumbnailSpinner.show(l)},c)}function b(){y(),Roblox.ThumbnailSpinner.hide(l)}function k(n){var t=new MutationObserver(function(i){i.forEach(function(i){var u=i.removedNodes,r,f;if(i.type==="childList")for(r=0;r<u.length;++r)if(u[r]===n){f=e(l),f.forceContextLoss(),t.disconnect();return}})});t.observe(n.parentNode,{childList:!0})}function d(u,e){i=0;var o=+new Date;p(l,u,function(i){if(f(l),!s){b(),l.append(i),k(i);var r=+new Date-o;e.realRegeneration&&n(["ThumbnailInBrowserRenderTime","Animated","Success",r]),t(i,e)}},r)}var v={start:+new Date,realRegeneration:!1,retriesDone:0},a;((u===null||u==="")&&(u=Roblox.Endpoints.generateAbsoluteUrl(l.data("animated-asset-url"),null,!0)),u)&&(f(l),w(),h(u,d,o,v))},a()}catch(v){r(v)}}),{cancel:a}}});

;// Thumbnails/ThumbnailView.js
typeof Roblox=="undefined"&&(Roblox={}),Roblox.ThumbnailView=function(){function o(n){var t=n.find("canvas");t.remove()}function w(n){n.forEach(function(n){n.reload()})}function y(n){n.forEach(function(n){n.showSpinner()})}function h(){if(n===null)try{var t=document.createElement("canvas");n=!!window.WebGLRenderingContext&&(t.getContext("webgl")||t.getContext("experimental-webgl"))?!0:!1}catch(i){n=!1}return n}function l(){return Roblox&&Roblox.LocalStorage?Roblox.LocalStorage.isAvailable():window.localStorage&&localStorage.setItem&&localStorage.getItem}function p(){l()&&(localStorage.getItem(u)==="true"?i=!0:(i=!1,localStorage.setItem(u,"false")))}function t(n,t){return h()?e(n)?t?!0:i:!1:!1}function b(n,t){(h()||(i=!1),e(t)||n!==!0)&&(i=n,l()&&localStorage.setItem(u,n.toString()))}function e(n){return typeof n.data("3d-thumbs-enabled")=="string"||n.hasClass("3d-thumbs-enabled")}function v(i){function a(){return i.find(".thumbnail-span")}function tt(){return i.find(".thumbnail-span-original")}function ni(){return i.find(".thumbnail-span-try-it-on")}function k(n){return n.find("img")}function u(){return i.find(".thumbnail-holder")}function l(){return i.find(f)}function ht(){return i.find(c)}function et(n,t){n.html(t.html()),n.data("url",t.data("url")?t.data("url"):""),n.data("3d-url",t.data("3d-url")?t.data("3d-url"):""),n.data("orig-retry-url",t.data("orig-retry-url")?t.data("orig-retry-url"):""),n.data("retry-url",t.data("retry-url")?t.data("retry-url"):""),n.data("animated-asset-url",t.data("animated-asset-url")?t.data("animated-asset-url"):"")}function rt(){return d==="static"&&"2D"||(h?ti:ii)}function it(){return d==="static"&&"3D"||wt}function st(){return Roblox.Lang.ItemResources?w?Roblox.Lang.ItemResources["Action.TakeOff"]:Roblox.Lang.ItemResources["Action.TryOn"]:w?"Take Off":"Try On"}function ft(){var n=a();o(i),Roblox.ThumbnailSpinner.show(n),k(n).hide();n.one("thumbnailLoaded",function(){k(n).show(),Roblox.ThumbnailSpinner.hide(n)})}function bt(){h?($(f).addClass("bundle-animation-play"),l().html(h&&nt.getIsLoopingThroughAnimations()?rt():it())):l().html(t(u(),h)?rt():it()),t(u(),h)||(e(u())?n?l().css("visibility","visible"):l().addClass("disabled"):l().css("visibility","hidden")),ht().html(st())}function kt(n){v=undefined,i.find("canvas").not(n).remove()}function dt(){v=undefined,l().addClass("disabled")}function gt(){v&&v.cancel(),ct();var n=t(u(),h);b(!n,u()),n!==t(u(),h)&&(p!==""?i.load(p+"&_="+$.now(),function(){y()}):y())}function ct(){tt().length>0&&(ht().html(st()),w?et(a(),ni()):et(a(),tt()))}function lt(){h?nt.startAnimationLoop():y()}function at(n){return function(t,i){kt(t);var r=+new Date;Roblox.ThumbnailMetrics.logFinalThumbnailTime(r-i.start,n)}}function vt(n){return function(){dt(),Roblox.ThumbnailMetrics.logThumbnailTimeout(n)}}function y(n){var e=t(u(),h),r,f;n||(n=a()),e?(o(i),k(n).hide(),d==="static"?v=n.load3DThumbnail(at("3dThumbnail"),vt("3dThumbnail")):(v=n.clearCurrentAnimationFrame(),v=n.loadAnimatedThumbnail(at("AnimationThumbnail"),vt("AnimationThumbnail"),yt)),k(n).hide()):(s&&(s=!1,r=n.data("orig-retry-url"),n.data("retry-url",r)),f=n.data("retry-url"),f?(ft(n),n.loadRobloxThumbnails()):(o(i),Roblox.ThumbnailSpinner.hide(u()),k(n).show())),bt()}function ut(){var n=a(),e,r,f;if(s=!0,e=t(u(),h),e){y(n);return}r=n.data("orig-retry-url"),typeof r!="undefined"?(n.data("retry-url",r),y(n)):(p!==""&&u().data("url",p),f=u().data("url"),f&&i.load(f+"&_="+$.now(),function(){y(n)}))}function pt(){function st(){return n}function s(){return i.find("#current-animation-name")}function k(){g.removeClass("hidden"),s().removeClass("hidden"),n=!0,ft(),b(!0),clearInterval(f),f=setInterval(b,e)}function tt(){clearTimeout(c),clearInterval(f),r=0,o=0}function b(i){var h,f;n?(h=a(),r+=e,(h.getNumOfLoops()>=et||i||r>ot)&&(u!==null&&t>=u.length&&(o++,t=0),f=e-100,f=f>0?f:0,h.fadeOut(f),c=setTimeout(function(){w($(u[t]),!0),t+=1,r=0,h.fadeIn(500),v!==-1&&o>=v&&(tt(),g.addClass("hidden"),s().addClass("hidden"),n=!1,l().html(it()))},f))):tt()}function w(n,i){var u=n.attr("data-animated-asset-url"),f=n.attr("data-static-url"),e=n.attr("data-three-dee-type"),r;t=parseInt(n.attr("data-index")),r=n.attr("data-name"),s().html(r),y(f,u,e,i),$(".bundle-animation-btn.selected").removeClass("selected"),n.addClass("selected")}function y(t,i,r,u){yt=i,p=t,d=r,n=u,ut()}function ht(){n?(n=!1,l().html(n?rt():it())):k()}var u=$(".bundle-animation-btn"),n=!1,t=0,f,c,r=0,e=200,o=0,v=-1,et=3,ot=1e4;i.on("click",".bundle-animation-play",function(){!$(this).hasClass("disabled")&&h&&nt.clickToggleAnimationLoopButton()});return{startAnimationLoop:k,getIsLoopingThroughAnimations:st,clickToggleAnimationLoopButton:ht,changeThumbnailFromBundleItem:w,changeThumbnail:y}}var v,yt="",p="",d="static",g=$(".bundle-animation-btn-container"),h=g!==null&&g.length>0,nt=h?pt():null,w=!1,ot;d=u().data("3dtype")||"static",tt().length>0&&et(a(),tt());var wt="<span class='icon-bigplay-fill'></span>",ii="<span class='icon-bigstop-fill'></span>",ti="<span class='icon-pause-fill'></span>";ot={container:i,holder:u,span:a,button:l,showSpinner:ft,outerLoad:lt,reload:ut,bundleAnimationCtrl:nt};i.on("click",f,function(){$(this).hasClass("disabled")||h||gt()}).on("click",c,function(){w=!w,ct(),ut()});return lt(),r.push(ot),ot}function a(n){$(n).each(function(){var n=$(this).parent();v(n)})}var u="RobloxUse3DThumbnailsV2",r=[],f=".enable-three-dee",n=null,c=".try-it-on",i=!1,s=!1;return $(".bundle-animation-btn").click(function(n){var t=$(n.currentTarget);r[0].bundleAnimationCtrl.changeThumbnailFromBundleItem(t,!1)}),p(),$(function(){a(".thumbnail-holder")}),{showSpinner:function(){return y(r)},reloadThumbnail:function(){return w(r)},setupDelayedThumbnailHolders:function(){a(".delayed-thumbnail-holder")}}}();

;// Thumbnails/ThumbnailSpinner.js
Roblox=Roblox||{},Roblox.ThumbnailSpinner=function(){var t='<div class="thumbnail-loader"><span class="spinner spinner-default"></span></div>',n=".thumbnail-loader";return{show:function(i){if(!(i.find(n).length>0)){var r=$(t);i.append(r)}},hide:function(t){t.find(n).remove()}}}();

;// ~/viewapp/widgets/lazyLoadImage/angularLazyImg.js
angular.module("angularLazyImg",[]).factory("LazyImgMagic",["$window","$rootScope","lazyImgConfig","lazyImgHelpers",function(n,t,i,r){"use strict";function v(){for(var t,n=f.length-1;n>=0;n--)t=f[n],t&&r.isElementInView(t.$elem[0],u.offset,a)&&(d(t),f.splice(n,1));f.length===0&&h()}function w(n){o.forEach(function(t){t[n]("scroll",l),t[n]("touchmove",l)}),c[n]("resize",l),c[n]("resize",p)}function y(){s=!0,setTimeout(function(){v(),w("on")},1)}function h(){s=!1,w("off")}function k(n){var t=f.indexOf(n);t!==-1&&f.splice(t,1)}function d(n){var i=new Image;i.onerror=function(){u.errorClass&&n.$elem.addClass(u.errorClass),t.$emit("lazyImg:error",n);u.onError(n)},i.onload=function(){b(n.$elem,n.src),n.$elem.removeClass(u.loadingClass),u.successClass&&n.$elem.addClass(u.successClass),t.$emit("lazyImg:success",n);u.onSuccess(n)},i.src=n.src}function b(n,t){n[0].nodeName.toLowerCase()==="img"?n[0].src=t:n.css("background-image",'url("'+t+'")')}function e(n){n.addClass(u.loadingClass),this.$elem=n}var a,c,f,s,u,l,p,o;return f=[],s=!1,u=i.getOptions(),c=angular.element(n),a=r.getWinDimensions(),p=r.throttle(function(){a=r.getWinDimensions()},60),o=[u.container||c],l=r.throttle(v,30),e.prototype.setSource=function(n){this.src=n,f.unshift(this),s||y()},e.prototype.removeImage=function(){k(this),f.length===0&&h()},e.prototype.checkImages=function(){v()},e.addContainer=function(n){h(),o.push(n),y()},e.removeContainer=function(n){h(),o.splice(o.indexOf(n),1),y()},e}]).provider("lazyImgConfig",function(){"use strict";this.options={offset:100,errorClass:null,successClass:null,onError:function(){},onSuccess:function(){},loadingClass:"icon-placeholder-game"},this.$get=function(){var n=this.options;return{getOptions:function(){return n}}},this.setOptions=function(n){angular.extend(this.options,n)}}).factory("lazyImgHelpers",["$window",function(n){"use strict";function t(){return{height:n.innerHeight,width:n.innerWidth}}function i(n,t,i){var r=n.getBoundingClientRect(),u=i.height+t;return n.offsetParent&&r.left>=0&&r.right<=i.width+t&&(r.top>=0&&r.top<=u||r.bottom<=u&&r.bottom>=0-t)}function r(n,t,i){var r,u;return function(){var e=i||this,f=+new Date,o=arguments;r&&f<r+t?(clearTimeout(u),u=setTimeout(function(){r=f,n.apply(e,o)},t)):(r=f,n.apply(e,o))}}return{isElementInView:i,getWinDimensions:t,throttle:r}}]).directive("lazyImg",["$rootScope","LazyImgMagic",function(n,t){"use strict";function i(i,r,u){var f=new t(r);u.$observe("lazyImg",function(n){n&&f.setSource(n)}),i.$on("$destroy",function(){f.removeImage()}),n.$on("lazyImg.runCheck",function(){f.checkImages()}),n.$on("lazyImg:refresh",function(){f.checkImages()})}return{link:i,restrict:"A"}}]).directive("lazyImgContainer",["LazyImgMagic",function(n){"use strict";function t(t,i){n.addContainer(i),t.$on("$destroy",function(){n.removeContainer(i)})}return{link:t,restrict:"A"}}]);

;// ~/Generated/js/Roblox_TranslationResources_Feature_ProfileResources_en_us_standard.js
var Roblox=Roblox||{};Roblox.Lang=Roblox.Lang||{},Roblox.Lang["Feature.Profile"]={"Action.Accept":"Accept","Action.AddFriend":"Add Friend","Action.BlockUser":"Block User","Action.CancelBlockUser":"Cancel","Action.Chat":"Chat","Action.Close":"Close","Action.ConfirmBlockUser":"Block","Action.ConfirmUnblockUser":"Unblock","Action.Favorites":"Favorites","Action.Follow":"Follow","Action.GridView":"Grid View","Action.ImpersonateUser":"Impersonate User","Action.Inventory":"Inventory","Action.JoinGame":"Join","Action.Message":"Message","Action.Pending":"Pending","Action.Save":"Save","Action.SeeAll":"See All","Action.SeeLess":"See Less","Action.SeeMore":"See More","Action.SlideshowView":"Slideshow View","Action.Trade":"Trade","Action.TradeItems":"Trade Items","Action.UnblockUser":"Unblock User","Action.Unfollow":"Unfollow","Action.Unfriend":"Unfriend","Action.UpdateStatus":"Update Status","Description.AboutSuccess":"Successfully updated description.","Description.AboutWarning":"Keep yourself safe, do not share personal details online.","Description.BlockUserFooter":"When you've blocked a user, neither of you can directly contact the other.","Description.BlockUserPrompt":"Are you sure you want to block this user?","Description.ChangeAlias":"Only you can see this information","Description.Error":"Unable to update description, please try again later.","Description.PlaceholderStatus":"Tell the Roblox community about what you like to make, build, and explore...","Description.UnblockUserPrompt":"Are you sure you want to unblock this user?","Heading.AboutTab":"About","Heading.BlockUserTitle":"Warning","Heading.Collections":"Collections","Heading.CurrentlyWearing":"Currently Wearing","Heading.FavoriteGames":"Favorites","Heading.Friends":"Friends","Heading.FriendsNum":"Friends ({friendsCount})","Heading.Games":"Experiences","Heading.GameTitle":"Experiences","Heading.Groups":"Groups","Heading.PlayerAssetsBadges":"Badges","Heading.PlayerAssetsClothing":"Clothing","Heading.PlayerAssetsModels":"Models","Heading.PlayerBadge":"Badges","Heading.Profile":"Profile","Heading.ProfileGroups":"Groups","Heading.RobloxBadge":"Roblox Badges","Heading.Statistics":"Statistics","Label.About":"About","Label.Alias":"Alias","Label.BlockWarningBody":"Are you sure you want to block this user?","Label.BlockWarningConfirm":"Block","Label.BlockWarningFooter":"When you've blocked a user, neither of you can directly contact the other.","Label.Cancel":"Cancel","Label.ChangeAlias":"Set Alias","Label.Creations":"Creations","Label.Followers":"Followers","Label.Following":"Following","Label.ForumPosts":"Forum Posts","Label.Friends":"Friends","Label.GridView":"Grid View","Label.JoinDate":"Join Date","Label.LoadMore":"Load More","Label.Members":"Members","Label.PastUsername":"Past Usernames","Label.PastUsernames":"Previous usernames","Label.PlaceVisits":"Place Visits","Label.Playing":"Active","Label.Quotation":'"{userStatus}"',"Label.Rank":"Rank","Label.ReadMore":"Read More","Label.ReportAbuse":"Report Abuse","Label.ShowLess":"Show Less","Label.SlideshowView":"Slideshow View","Label.UnblockWarningBody":"Are you sure you want to unblock this user?","Label.UnblockWarningConfirm":"Unblock","Label.Visits":"Visits","Label.WarningTitle":"Warning","Message.AcceptFriendRequestError":"Unable to accept friend request.","Message.AliasHasError":"An error has occurred. Please try again later","Message.AliasIsModerated":"Please avoid using full names or offensive language.","Message.BlockError":"Unable to block user. You may have blocked too many people.","Message.BlockRequestError":"Unable to block user.","Message.ChangeStatus":"What are you up to?","Message.ErrorBlockLimit":"Operation failed! You may have blocked too many people.","Message.ErrorGeneral":"Something went wrong. Please check back in a few minutes.","Message.FollowError":"Unable to follow user.","Message.ImpersonateUserError":"Unable to impersonate user.","Message.NoCreation":"{username} has no creations.","Message.RemoveFriendError":"Unable to unfriend user.","Message.SendFriendRequestError":"Unable to send friend request.","Message.Sharing":"Sharing...","Message.UnfollowError":"Unable to unfollow user.","Message.UpdateStatusError":"Unable to update status.","Response.TooManyAttempts":"Too many attempts. Please try again later."},Roblox.Lang.ProfileResources=Roblox.Lang["Feature.Profile"];

;// ~/viewapp/pages/profile/profile.js
"use strict";var profile=angular.module("profile",["modal","thumbnails","captchaV2"]).config(["languageResourceProvider",function(n){var t=Roblox.Lang.ProfileResources||{},i={"Message.AcceptFriendRequestError":t&&t["Message.AcceptFriendRequestError"]||"Unable to accept friend request.","Message.SendFriendRequestError":t&&t["Message.SendFriendRequestError"]||"Unable to send friend request.","Message.RemoveFriendError":t&&t["Message.RemoveFriendError"]||"Unable to unfriend user.","Message.FollowError":t&&t["Message.FollowError"]||"Unable to follow user.","Message.UnfollowError":t&&t["Message.UnfollowError"]||"Unable to unfollow user.","Message.BlockError":t&&t["Message.BlockError"]||"Unable to block user. You may have blocked too many people.","Message.BlockRequestError":t&&t["Message.BlockRequestError"]||"Unable to block user.","Message.ImpersonateUserError":t&&t["Message.ImpersonateUserError"]||"Unable to impersonate user.","Message.UpdateStatusError":t&&t["Message.UpdateStatusError"]||"Unable to update status."};n.setLanguageKeysFromFile(t),n.setLanguageKeysFromFile(i)}]);

;// utilities/datetime/formatDateTimesI18n.js
"use strict";Roblox=Roblox||{},Roblox.FormatDateTimesI18n=function(){document.addEventListener("DOMContentLoaded",function(){for(var u=(new Roblox.Intl).getDateTimeFormatter(),t=document.getElementsByClassName("date-time-i18n"),i,e,r,s,h,o,f,n=0;n<t.length;n++){if(i=t[n].getAttribute("data-date-time-i18n-value"),e=t[n].getAttribute("data-date-time-i18n-format"),e==="custom")try{s=t[n].getAttribute("data-date-time-i18n-options").replace(/'/g,'"'),h=JSON.parse(s),r=u.getCustomDateTime(i,h)}catch(c){r=u.getShortDate(i)}else r=e==="full"?u.getFullDate(i):u.getShortDate(i);t[n].innerHTML=r}for(o=document.querySelectorAll(".wait-for-i18n-format-render"),f=0;f<o.length;f++)o[f].classList.remove("invisible")})}();

;// ~/viewapp/pages/profile/services/profileUtilitiesConstantsServices.js
"use strict";profile.factory("profileUtilitiesConstantsServices",["languageResource",function(n){return{layout:{linkName:n.get("Action.SeeMore"),nameOfOpen:n.get("Action.SeeMore"),nameOfClose:n.get("Action.SeeLess")},userModal:{block:{titleText:n.get("Heading.BlockUserTitle"),bodyText:n.get("Description.BlockUserPrompt"),actionButtonText:n.get("Action.ConfirmBlockUser"),neutralButtonText:n.get("Action.CancelBlockUser"),footerText:n.get("Description.BlockUserFooter")},unblock:{titleText:n.get("Heading.BlockUserTitle"),bodyText:n.get("Description.UnblockUserPrompt"),actionButtonText:n.get("Action.ConfirmUnblockUser"),neutralButtonText:n.get("Action.CancelBlockUser")},error:{blockLimitError:n.get("Message.ErrorBlockLimit"),generalError:n.get("Message.ErrorGeneral")},menu:{blockUserText:n.get("Action.BlockUser"),unblockUserText:n.get("Action.UnblockUser")},pastUsername:{titleText:n.get("Label.PastUsername"),neutralButtonShow:!1}},message:{acceptFriendRequestFailed:n.get("Message.AcceptFriendRequestError"),sendFriendRequestFailed:n.get("Message.SendFriendRequestError"),removeFriendFailed:n.get("Message.RemoveFriendError"),followFailed:n.get("Message.FollowError"),unfollowFailed:n.get("Message.UnfollowError"),blockFailed:n.get("Message.BlockError"),blockRequestFailed:n.get("Message.BlockRequestError"),impersonateUserFailed:n.get("Message.ImpersonateUserError"),updateStatusFailed:n.get("Message.UpdateStatusError"),tooManyAttempts:n.get("Response.TooManyAttempts")},errorCodes:{captchaNeeded:14}}}]);

;// ~/viewapp/pages/profile/services/profileService.js
"use strict";profile.factory("profileService",["httpService","$rootScope","$timeout","$window","$filter","localStorageService",function(n,t,i,r,u,f){var o={},s=function(){var u,n,t,e,i,o,r;if(f.storage()){for(u=[Roblox.EnvironmentUrls.friendsApi,Roblox.EnvironmentUrls.presenceApi],n=[],t=0;t<f.getLength();t++)for(e=f.getKey(t),i=0;i<u.length;i++)o=u[i],e.indexOf(o)>-1&&n.push(e);for(r=0;r<n.length;r++)f.removeLocalStorage(n[r])}},e=function(t,i){var r={url:Roblox.EnvironmentUrls.friendsApi+t};return s(),n.httpPost(r,i)},h={accountDescription:Roblox.EnvironmentUrls.accountInformationApi+"/v1/description"},c=function(t,i,r,u){var f={url:t,withCredentials:!0},e;switch(r){case n.methods.get:return f.noCache=!u,n.httpGet(f,i);case n.methods.post:return f.headers={"Content-Type":"application/x-www-form-urlencoded"},i!=null&&(e=$.param(i)),n.httpPost(f,e);case n.methods.patch:return f.headers={"Content-Type":"application/x-www-form-urlencoded"},i!=null&&(e=$.param(i)),n.httpPatch(f,e);case n.methods.delete:return n.httpDelete(f,i)}};return{acceptFriendRequestV2:function(n){return e("/v1/users/"+n+"/accept-friend-request")},sendFriendRequestV2:function(n,t){var i=null;return t&&(i={}),e("/v1/users/"+n+"/request-friendship",i)},removeFriendV2:function(n){return e("/v1/users/"+n+"/unfriend")},followV2:function(n,t){return e("/v1/users/"+n+"/follow",t)},unfollowV2:function(n){return e("/v1/users/"+n+"/unfollow")},blockUser:function(t,i){var r={url:t},u={blockeeId:i};return n.httpPost(r,u)},impersonateUser:function(t){var i={url:Roblox.EnvironmentUrls.authApi+"/v2/users/"+t+"/impersonate"};return n.httpPost(i,{})},updateStatus:function(t,i){var u={url:t,headers:{"Content-Type":"application/x-www-form-urlencoded; charset=UTF-8"}},r={status:i,sendToFacebook:!1};return r=$.param(r),n.httpPost(u,r)},setAccountInformationUrl:function(n){h.accountDescription=n+"/v1/description"},getFriendshipCountV2:function(t){var i={url:Roblox.EnvironmentUrls.friendsApi+"/v1/users/"+t+"/friends/count",withCredentials:!0,retryable:!0};return n.httpGet(i)},getCollections:function(t,i){var r={url:t},u={userId:i};return n.httpGet(r,u)},getPlayerAssets:function(t,i,r){var u={url:t},f={assetTypeId:r,userId:i};return n.httpGet(u,f)},setProfileData:function(n){o=n},getProfileData:function(){return o},refreshLazyLoadImage:function(){i(function(){t.$emit("lazyImg:refresh")})},getUpdatedHeaderData:function(t,i){var r={url:t},u={userId:i};return n.httpGet(r,u)}}}]);

;// ~/viewapp/pages/profile/filters/profileHeaderStatusTextFilter.js
"use strict";profile.filter("statusfilter",function(){return function(n){return n?'"'+n+'"':""}});

;// ~/viewapp/pages/profile/constants/layout.js
profile.constant("layoutLibrary",{templateLinks:{userStatus:"user-status"}});

;// ~/viewapp/pages/profile/constants/profileJsonEndPoints.js
profile.constant("profileJsonEndPoints",{collections:"/users/profile/robloxcollections-json",playerAssets:"/users/profile/playerassets-json",profileHeaderData:"/users/profile/profileheader-json"});

;// ~/viewapp/pages/profile/controllers/profileBaseController.js
"use strict";profile.controller("profileBaseController",["$log","$scope",function(n,t){t.appMeta={isI18nEnabled:Roblox.I18nData&&Roblox.I18nData.isI18nEnabledForGroups}}]);

;// ~/viewapp/pages/profile/controllers/profileUtilitiesController.js
"use strict";profile.controller("profileUtilitiesController",["$log","$scope","modalService","profileService","profileJsonEndPoints","profileUtilitiesConstantsServices",function(n,t,i,r,u,f){t.layoutContent={showMore:!0,linkName:f.layout.linkName,nameOfOpen:f.layout.nameOfOpen,nameOfClose:f.layout.nameOfClose},t.toggleContent=function(n){t.layoutContent.showMore=!n,t.layoutContent.linkName=n?t.layoutContent.nameOfClose:t.layoutContent.nameOfOpen},t.loadMore=function(){t.layoutContent.showMore=!1},t.showPastUsernames=function(){var r=f.userModal,n=r.pastUsername;n.bodyText=t.pageData.previousUsernames,i.open(n)},t.initializeDescription=function(){r.getDescription().then(function(n){t.data.description=n.description,t.layout.showEditBox=t.isDescriptionEmpty()?!0:!1,t.layout.showEditButton=t.isDescriptionEmpty()?!1:!0},function(){n.debug("Error getting personal description")})},t.updateDescription=function(){r.updateDescription(t.data.description).then(function(n){t.data.description=n.description,t.layout.showEditButton=!0,t.layout.showEditBox=!1},function(i){n.debug("Error updating personal description"),t.layout.descriptionError=i.message})},t.openEditBox=function(){t.layout.showEditButton=!1,t.layout.showEditBox=!0},t.isDescriptionEmpty=function(){return t.data.description==null||t.data.description.length===0},t.getPlayerAssets=function(i){var f=u.playerAssets;return r.getPlayerAssets(f,t.pageData.profileUserId,i).then(function(i){n.debug("my player assets: ",i),t.assets=i.Assets,t.data.title=i.Title,t.data.assetUrl=i.AssetTypeInventoryUrl,t.layout.showSeeAllButton=i.IsSeeAllHeaderButtonVisible,r.refreshLazyLoadImage()})},t.init=function(){t.layout||(t.layout={showSeeAllButton:!1},t.data={title:"",assetUrl:"",description:""},t.pageData=r.getProfileData(),t.assets=[])},t.init()}]);

;// ~/viewapp/pages/profile/controllers/profileHeaderController.js
"use strict";profile.controller("profileHeaderController",["$scope","profileService","realtimeService","chatDispatchService","$document","$log","$filter","modalService","profileUtilitiesConstantsServices","profileJsonEndPoints","httpStatusCodes","thumbnailConstants","captchaV2Constants","urlService",function(n,t,i,r,u,f,e,o,s,h,c,l,a,v){function ut(){var t=[],r=i.notificationTypes.friendshipNotifications;t[r.friendshipCreated]=n.callbackForAcceptingFriendRequest,t[r.friendshipDestroyed]=n.updateLayoutByRemovingFriendRequest,t[r.friendshipDeclined]=n.updateLayoutByDecliningFriendRequest,t[r.friendshipRequested]=n.callbackForSendingFriendRequest,i.listenToNotification(i.realTimeTypes.friendshipNotifications,t)}var d="#profile-trade-items",b="#profile-block-user",y="#profile-header-more",g="#profile-header-impersonate",k="#profile-header-update-status",nt="#profile-follow-user",tt="#userStatusText",it="#profile-message";n.thumbnailTypes=l.thumbnailTypes;var p=Roblox&&Roblox.Endpoints?Roblox.Endpoints.getAbsoluteUrl("/Login/Signup.aspx"):"/Login/Signup.aspx",rt=Roblox&&Roblox.Endpoints?Roblox.Endpoints.getAbsoluteUrl("/Home"):"/Home",w=function(n){return n&&n.EventArgs};n.profileHeaderLayout={},n.updateMessageBtnDisplay=function(){var i=h.profileHeaderData;t.getUpdatedHeaderData(i,n.profileHeaderLayout.profileUserId).then(function(t){t&&(n.profileHeaderLayout.canMessage=t.CanMessage,n.profileHeaderLayout.messagesDisabled=t.MessagesDisabled),n.setMessageBtnDisplay(n.profileHeaderLayout)},function(){n.setMessageBtnDisplay(n.profileHeaderLayout)})},n.captcha={actionTypes:a.captchaActionTypes,activated:!1,inputParams:{unifiedCaptchaId:"",dataExchange:""}},n.setMessageBtnDisplay=function(n){if(n){var t=n.canMessage&&n.userId>0;n.enableMessageBtn=t,n.isChatDisabledByPrivacySetting?(n.showMessageBtn=!0,n.showMessageLink=!1,n.showChatBtn=!1):(n.showMessageBtn=!n.areFriends,n.showMessageLink=t&&n.areFriends,n.showChatBtn=n.userId>0&&n.areFriends),n.messagesDisabled===!0&&(n.showMessageBtn=!1,n.showMessageLink=!1)}},n.acceptFriendRequest=function(){n.profileHeaderLayout.userId?t.acceptFriendRequestV2(n.profileHeaderLayout.profileUserId).then(function(){n.updateLayoutByAcceptingFR()},function(t){var i=n.parseErrorFromApiResponse(t),r=i&&i.userFacingMessage?i.userFacingMessage:s.message.acceptFriendRequestFailed;n.displayError(r)}):window.location=p},n.updateLayoutBySendingFRFromMyself=function(){n.profileHeaderLayout.maySendFriendInvitation=!1,n.profileHeaderLayout.friendRequestPending=!0},n.sendFriendRequest=function(){n.profileHeaderLayout.userId?t.sendFriendRequestV2(n.profileHeaderLayout.profileUserId,v.getParam("friendshipSourceType")).then(function(t){f.debug(t),n.updateLayoutBySendingFRFromMyself(),u.triggerHandler("Roblox.Friendship.FriendRequestSent")},function(t){var i=n.parseErrorFromApiResponse(t),r=s.message.sendFriendRequestFailed;t.status===c.tooManyAttempts?r=s.message.tooManyAttempts:i&&i.userFacingMessage&&(r=i.userFacingMessage),n.displayError(r)}):window.location=p},n.updateFriendshipCount=function(){t.getFriendshipCountV2(n.profileHeaderLayout.profileUserId).then(function(t){n.profileHeaderLayout.friendsCount=t.count})},n.updateLayoutByAcceptingFR=function(){n.profileHeaderLayout.areFriends||(n.profileHeaderLayout.incomingFriendRequestPending=!1,n.profileHeaderLayout.friendRequestPending=!1,n.profileHeaderLayout.areFriends=!0,n.updateFriendshipCount(),n.updateMessageBtnDisplay())},n.callbackForAcceptingFriendRequest=function(t){if(!w(t))return!1;n.$evalAsync(function(){var i=parseInt(t.EventArgs.UserId1),r=parseInt(t.EventArgs.UserId2),u=parseInt(n.profileHeaderLayout.profileUserId),f=parseInt(n.profileHeaderLayout.userId);i===f&&r===u&&n.updateLayoutByAcceptingFR(),r===f&&i===u&&(n.profileHeaderLayout.incomingFriendRequestPending=!1,n.profileHeaderLayout.areFriends=!0)})},n.updateLayoutByRemovingFriendRequest=function(t){n.$evalAsync(function(){if(w(t)&&parseInt(t.EventArgs.UserId2)!==parseInt(n.profileHeaderLayout.profileUserId))return!1;n.profileHeaderLayout.areFriends&&(n.profileHeaderLayout.maySendFriendInvitation=!0,n.profileHeaderLayout.originalMaySendFriendInvitation=n.profileHeaderLayout.maySendFriendInvitation,n.profileHeaderLayout.areFriends=!1,n.updateFriendshipCount(),n.updateMessageBtnDisplay())})},n.updateLayoutByDecliningFriendRequest=function(){n.$evalAsync(function(){n.profileHeaderLayout.maySendFriendInvitation=!0,n.profileHeaderLayout.originalMaySendFriendInvitation=n.profileHeaderLayout.maySendFriendInvitation,n.profileHeaderLayout.areFriends=!1})},n.callbackForSendingFriendRequest=function(t){if(!w(t))return!1;n.$evalAsync(function(){var i=parseInt(t.EventArgs.UserId1),u=parseInt(t.EventArgs.UserId2),r=parseInt(n.profileHeaderLayout.profileUserId),f=parseInt(n.profileHeaderLayout.userId);i===r?(n.profileHeaderLayout.incomingFriendRequestPending=!0,n.profileHeaderLayout.friendRequestPending=!1,n.profileHeaderLayout.areFriends=!1):i===f&&u===r&&n.updateLayoutBySendingFRFromMyself()})},n.removeFriend=function(){n.profileHeaderLayout.userId?t.removeFriendV2(n.profileHeaderLayout.profileUserId).then(function(){n.updateLayoutByRemovingFriendRequest()},function(t){var i=n.parseErrorFromApiResponse(t),r=i&&i.userFacingMessage?i.userFacingMessage:s.message.removeFriendFailed;n.displayError(r)}):window.location=p};angular.element(y).on("click",nt,function(){n.profileHeaderLayout.isFollowing?n.unFollow():n.follow()});n.follow=function(){n.profileHeaderLayout.userId?n.sendFollow():window.location=p},n.sendFollow=function(i){t.followV2(n.profileHeaderLayout.profileUserId,i).then(function(t){t.success&&(n.profileHeaderLayout.isFollowing=!0,n.incrementFollowers(1))},function(t){var i=n.parseErrorFromApiResponse(t),r=s.message.followFailed;if(t&&t.status===c.tooManyAttempts)r=s.message.tooManyAttempts;else{if(i&&i.code===s.errorCodes.captchaNeeded){n.activateCaptcha(i);return}i&&i.userFacingMessage&&(r=i.userFacingMessage)}n.displayError(r)})},n.activateCaptcha=function(t){var i=t.fieldData,r,f="",u;if(i!=null){try{u=JSON.parse(i),r=u.dxBlob,f=u.unifiedCaptchaId}catch(e){r=i}n.captcha.inputParams.unifiedCaptchaId=f,n.captcha.inputParams.dataExchange=r}n.captcha.activated=!0},n.followUserCaptchaPassed=function(t){n.sendFollow(t)},n.followUserCaptchaFailed=function(){n.captcha.activated=!1},n.incrementFollowers=function(t){n.profileHeaderLayout.followersCount!=null&&(n.profileHeaderLayout.followersCount=n.profileHeaderLayout.followersCount+t)},n.displayError=function(t){n.profileHeaderLayout.errorMsg=t,n.profileHeaderLayout.hasError=!0},n.clearError=function(){n.profileHeaderLayout.errorMsg="",n.profileHeaderLayout.hasError=!1,n.profileHeaderLayout.statusError=null},n.parseErrorFromApiResponse=function(n){return n&&n.errors&&n.errors[0]},n.unFollow=function(){n.profileHeaderLayout.userId?t.unfollowV2(n.profileHeaderLayout.profileUserId).then(function(){n.profileHeaderLayout.isFollowing=!1,n.incrementFollowers(-1)},function(t){var i=n.parseErrorFromApiResponse(t),r=i&&i.userFacingMessage?i.userFacingMessage:s.message.unfollowFailed;n.displayError(r)}):window.location=p},n.sendMessage=function(){window.location=n.profileHeaderLayout.userId?n.profileHeaderLayout.messageUrl:p};angular.element(y).on("click",it,function(){n.sendMessage()});n.chat=function(){var t=n.profileHeaderLayout.profileUserId,i=r.buildPermissionVerifier(n.profileHeaderLayout);r.startChat(t,i)};angular.element(y).on("click touchstart",d,function(){var t=n.profileHeaderLayout.profileUserId;Roblox.EventStream.SendEvent("tradeEntryPoint","profileMenu",{partnerId:t}),window.location.href=Roblox.Endpoints.getAbsoluteUrl("/users/"+t+"/trade")});angular.element(y).on("click",b,function(){n.blockUser()});n.blockUser=function(){var i=s.userModal,u=i.block,r;u.actionButtonShow=!0,r=i.unblock,r.actionButtonShow=!0;var e=i.error.blockLimitError,h=i.error.generalError,c=i.menu.blockUserText,l=i.menu.unblockUserText,a=n.profileHeaderLayout.isVieweeBlocked?r:u,v=o.open(a);v.result.then(function(){var i=n.profileHeaderLayout.isVieweeBlocked?"/userblock/unblockuser":"/userblock/blockuser";t.blockUser(i,n.profileHeaderLayout.profileUserId).then(function(t){var i,r;t&&t.success?(i=n.profileHeaderLayout.isVieweeBlocked,i?(n.profileHeaderLayout.maySendFriendInvitation=n.profileHeaderLayout.originalMaySendFriendInvitation,n.profileHeaderLayout.mayFollow=n.profileHeaderLayout.originalMayFollow,n.setMessageBtnDisplay(n.profileHeaderLayout),n.profileHeaderLayout.canTrade=n.profileHeaderLayout.originalCanTrade):(n.profileHeaderLayout.maySendFriendInvitation=!1,n.profileHeaderLayout.incomingFriendRequestPending=!1,n.profileHeaderLayout.friendRequestPending=!1,n.profileHeaderLayout.mayFollow=!1,n.profileHeaderLayout.enableMessageBtn=!1,n.profileHeaderLayout.canTrade=!1),n.profileHeaderLayout.isVieweeBlocked=!i,r=n.profileHeaderLayout.isVieweeBlocked?c:l,angular.element(b).text(r)):n.displayError(t.error||e)},function(){n.displayError(h)})},function(){f.debug("Modal dismissed at: "+new Date)})};angular.element(y).on("click touchstart",g,function(){n.impersonateUser()});n.impersonateUser=function(){t.impersonateUser(n.profileHeaderLayout.profileUserId).then(function(){window.location=rt},function(t){var i=t&&t.errors&&t.errors[0]&&t.errors[0].message;n.displayError(i||s.message.impersonateUserFailed)})},n.revealStatusForm=function(){},n.isUserStatusDisabled=function(){return!0},n.updateStatus=function(i){i?(n.$evalAsync(function(){n.profileHeaderLayout.statusFormSending=!0}),t.updateStatus(n.profileHeaderLayout.updateStatusUrl,n.sanitizeStatus(n.profileHeaderLayout.statusTextInput)).then(function(t){t&&t.success?(n.profileHeaderLayout.statusFormShown=!1,n.clearError(),n.profileHeaderLayout.statusInputFocused=!1,n.profileHeaderLayout.statusText=t.message):n.profileHeaderLayout.statusError=t.message||s.message.updateStatusFailed,n.profileHeaderLayout.statusFormSending=!1},function(){n.profileHeaderLayout.statusError=s.message.updateStatusFailed,n.profileHeaderLayout.statusFormSending=!1})):n.$evalAsync(function(){n.profileHeaderLayout.statusFormShown=!1,n.profileHeaderLayout.statusFormSending=!1,n.profileHeaderLayout.statusInputFocused=!1,n.clearError()})},n.blurStatusForm=function(t){if(t&&typeof t.target!="undefined"){var i=t.target,r="#"+i.getAttribute("id");if(i.getAttribute("id")!=null&&r==k||r==tt)return}n.updateStatus(!1)},n.sanitizeStatus=function(n){return n.replace(/}|{/gi,"")},n.getAbbreviatedStringFromCountValue=function(n){return n||n===0?e("abbreviate")(n):"?"},n.getStringFromCountValue=function(n){return n||n===0?n.toString():"?"},ut();angular.element(y).on("click touchstart",k,function(){n.revealStatusForm()});angular.element(u).on("click touchstart",function(t){for(var r=document.querySelectorAll("#statusForm"),i=0;i<r.length;i++)if(r[i].contains(t.target))return;n.blurStatusForm(t)})}]);

;// ~/viewapp/pages/profile/controllers/profileAccoutrementsController.js
"use strict";profile.controller("profileAccoutrementsController",["$scope","$log",function(n){n.profileAccoutrementsLayout={},n.getAccoutrementsPage=function(t){angular.element(".profile-accoutrements-slider ul").css("display","none"),angular.element(".profile-accoutrements-slider ul:nth-child("+(t+1)+")").css("display","block"),n.profileAccoutrementsLayout.currentPageNumber=t}}]);

;// ~/viewapp/pages/profile/controllers/profileCollectionsController.js
"use strict";profile.controller("profileCollectionsController",["$scope","$log","profileService","profileJsonEndPoints",function(n,t,i,r){n.onClickTradeLink=function(){Roblox.EventStream.SendEvent("tradeEntryPoint","profileInventory",{partnerId:n.pageData.profileUserId})},n.collections=[],n.pageData=i.getProfileData(),n.getCollectionsData=function(){var u=r.collections;return i.getCollections(u,n.pageData.profileUserId).then(function(r){t.debug("my collections: ",r),n.collections=r.CollectionsItems,i.refreshLazyLoadImage()})}}]);

;// ~/viewapp/pages/profile/controllers/profileGridController.js
"use strict";profile.controller("profileGridController",["$scope",function(n){n.NumberOfVisibleRows=0,n.isGridOn=!1,n.visibleItems=0,n.containerHeight=n.NumberOfVisibleRows*232+8*(n.NumberOfVisibleRows-1),n.elementClassName="",n.containerClassName="",n.elementWidthWithPadding=160,n.init=function(t,i){n.elementClassName=t,n.containerClassName=i,n.loadMore(),n.loadMore()},n.loadMore=function(){var i=n.visibleItems,t=6*(n.NumberOfVisibleRows+1),r=angular.element.find("."+n.elementClassName);n.showImages(i,t,r),n.NumberOfVisibleRows++,n.visibleItems=t},n.showImages=function(t,i,r){for(var f,u=t;u<i;u++)f=angular.element(r).find("."+n.containerClassName+"[data-index="+u+"] img"),angular.element(f).attr("src")||angular.element(f).attr("src",angular.element(f).attr("data-src"))},n.updateDisplay=function(t){n.isGridOn=t}}]);

;// ~/viewapp/pages/profile/directives/profileHeaderDataDirective.js
"use strict";profile.directive("profileHeaderData",["profileService",function(n){return{restrict:"A",scope:{profileHeaderLayout:"=",setMessageBtnDisplay:"&"},link:function(t,i,r){var u=Roblox.DeviceMeta(),f={userId:Roblox.CurrentUser.userId,profileUserId:r.profileuserid,profileUserName:Roblox.ProfileHeaderData.profileusername,friendsCount:Number.parseInt(r.friendscount,10),followersCount:Number.parseInt(r.followerscount,10),followingsCount:Number.parseInt(r.followingscount,10),areFriends:r.arefriends==="true",friendRequestPending:r.friendrequestpending==="true",friendUrl:r.friendurl,incomingFriendRequestPending:r.incomingfriendrequestpending==="true",originalMaySendFriendInvitation:r.maysendfriendinvitation==="true",maySendFriendInvitation:r.maysendfriendinvitation==="true",originalMayFollow:r.mayfollow==="true",mayFollow:r.mayfollow==="true",isFollowing:r.isfollowing==="true",canMessage:r.canmessage==="true",messagesDisabled:r.messagesdisabled==="true",messageUrl:r.messageurl,canBeFollowed:r.canbefollowed==="true",originalCanTrade:r.cantrade==="true",canTrade:r.cantrade==="true",isBlockButtonVisible:r.isblockbuttonvisible==="true",isVieweeBlocked:r.isvieweeblocked==="true",getFollowScript:r.getfollowscript,isMoreBtnVisible:r.ismorebtnvisible==="true",mayImpersonate:r.mayimpersonate==="true",mayUpdateStatus:!1,updateStatusUrl:r.updatestatusurl,statusText:r.statustext,statusDate:r.statusdate,editStatusMaxLength:r.editstatusmaxlength,inApp:u.isInApp,inAndroidApp:u.isAndroidApp,iniOSApp:u.isIosApp,isChatDisabledByPrivacySetting:r.ischatdisabledbyprivacysetting==="true",previousUsernames:Roblox.ProfileHeaderData.previoususernames};t.profileHeaderLayout=f,n.setProfileData(f),t.setMessageBtnDisplay({layout:t.profileHeaderLayout}),Roblox&&Roblox.Performance&&Roblox.Performance.setPerformanceMark("header_data")}}}]);

;// ~/viewapp/pages/profile/directives/profileUtilitiesDirective.js
profile.directive("truncate",function(){return{scope:{layoutContent:"="},link:function(n,t){if(n.layoutContent||(n.layoutContent={}),n.layoutContent.hasMoreContent=!1,t.find("li")&&t.find("li").length>0){var r=t.find("li").length,u=t.find("li").width(),f=Math.floor(t.width()/u);f+1<r&&(n.layoutContent.hasMoreContent=!0)}}}});

;// ~/viewapp/pages/profile/directives/profileAccoutrementsDataDirective.js
"use strict";profile.directive("profileAccoutrementsData",function(){return{restrict:"A",scope:{profileAccoutrementsLayout:"="},link:function(n,t,i){n.profileAccoutrementsLayout={numberOfAccoutrements:i.numberofaccoutrements,numberOfPages:Math.ceil(i.numberofaccoutrements/i.accoutrementsperpage),currentPageNumber:0,inTouchScreen:i.intouchscreen==="true"}}}});

;// ~/viewapp/pages/profile/directives/profileAccoutrementsSliderDirective.js
"use strict";profile.directive("profileAccoutrementsSlider",function(){return{restrict:"A",scope:{profileAccoutrementsLayout:"="},link:function(n,t){var r=95;n.$watch("profileAccoutrementsLayout",function(n){if(n&&(n.inTouchScreen||Roblox.DeviceFeatureDetection.isTouch)){var u=n.numberOfAccoutrements;t.css("width",u*r)}},!0)}}});

;// ~/viewapp/pages/profile/directives/profileAccoutrementsPageDirective.js
"use strict";profile.directive("profileAccoutrementsPage",function(){return{restrict:"A",scope:{profileAccoutrementsLayout:"="},link:function(n,t){n.$watch("profileAccoutrementsLayout",function(n){var u,r,f;if(n&&(u=n.numberOfPages,u>1))for(r=0;r<u;r++)f=angular.element(t.children()[r]),f.removeClass("hidden")},!0)}}});

;// ~/viewapp/pages/profile/directives/profileEmptyTabDirective.js
"use strict";profile.directive("profileEmptyTab",function(){return{restrict:"AC",link:function(n,t){n.profileLayout=n.profileLayout||{},t.children().length===0&&(n.profileLayout.userHasNoCreations=!0)}}});

;// ~/viewapp/pages/profile/directives/profileStatusInputElementDirective.js
"use strict";profile.directive("statusInputElement",["$timeout",function(n){return{link:function(t,i){t.$watch(function(){return t.profileHeaderLayout.statusInputFocused},function(t){t===!0&&n(function(){i[0].focus()})});i.on("focus",function(){var i=this;t.profileHeaderLayout.focusedElement!=i&&(t.profileHeaderLayout.focusedElement=i,n(function(){i.select()},10))});i.on("blur",function(){t.profileHeaderLayout.focusedElement=null,t.profileHeaderLayout.statusInputFocused=!1})}}}]);

;// ~/viewapp/pages/profile/directives/profileTabClickDirective.js
"use strict";profile.directive("profileTabClick",["profileService",function(n){return{restrict:"A",link:function(t,i){var u=i.find(".rbx-tab");u.click(function(){n.refreshLazyLoadImage()})}}}]);

;// ~/viewapp/pages/profile/directives/scrollHorizontally.js
"use strict";profile.directive("horizontalScrollBar",function(){return{restrict:"A",link:function(n,t,i){var r=t[0];t.bind("scroll",function(){r.scrollLeft+r.offsetWidth>r.scrollWidth-100&&n.$apply(i.horizontalScrollBar)})}}});

;// jquery/jquery.history.js
typeof window.console=="undefined"&&(window.console={}),typeof window.console.emulated=="undefined"&&(typeof window.console.log=="function"?window.console.hasLog=!0:(typeof window.console.log=="undefined"&&(window.console.log=function(){}),window.console.hasLog=!1),typeof window.console.debug=="function"?window.console.hasDebug=!0:(typeof window.console.debug=="undefined"&&(window.console.debug=window.console.hasLog?function(){for(var t=["console.debug:"],n=0;n<arguments.length;n++)t.push(arguments[n]);window.console.log.apply(window.console,t)}:function(){}),window.console.hasDebug=!1),typeof window.console.warn=="function"?window.console.hasWarn=!0:(typeof window.console.warn=="undefined"&&(window.console.warn=window.console.hasLog?function(){for(var t=["console.warn:"],n=0;n<arguments.length;n++)t.push(arguments[n]);window.console.log.apply(window.console,t)}:function(){}),window.console.hasWarn=!1),typeof window.console.error=="function"?window.console.hasError=!0:(typeof window.console.error=="undefined"&&(window.console.error=function(){var t="An error has occured.",i,n;if(window.console.hasLog){for(i=["console.error:"],n=0;n<arguments.length;n++)i.push(arguments[n]);window.console.log.apply(window.console,i),t="An error has occured. More information is available in your browser's javascript console."}for(n=0;n<arguments.length;++n){if(typeof arguments[n]!="string")break;t+="\n"+arguments[n]}if(typeof Error!="undefined")throw new Error(t);else throw t;}),window.console.hasError=!1),typeof window.console.trace=="function"?window.console.hasTrace=!0:(typeof window.console.trace=="undefined"&&(window.console.trace=function(){window.console.error("console.trace does not exist")}),window.console.hasTrace=!1),window.console.emulated=!0),function(n){n.History||!1?window.console.warn("$.History has already been defined..."):(n.History={options:{debug:!1},state:"",$window:null,$iframe:null,handlers:{generic:[],specific:{}},extractHash:function(n){return n.replace(/^[^#]*#/,"").replace(/^#+|#+$/,"")},getState:function(){var t=n.History;return t.state},setState:function(t){var i=n.History;return t=i.extractHash(t),i.state=t},getHash:function(){var t=n.History;return t.extractHash(window.location.hash||location.hash)},setHash:function(t){var i=n.History;return t=i.extractHash(t),typeof window.location.hash!="undefined"?window.location.hash!==t&&(window.location.hash=t):location.hash!==t&&(location.hash=t),t},go:function(t){var i=n.History,r,u;return t=i.extractHash(t),r=i.getHash(),u=i.getState(),t!==r?i.setHash(t):(t!==u&&i.setState(t),i.trigger()),!0},hashchange:function(){var i=n.History,r=i.getHash();return i.go(r),!0},bind:function(t,i){var r=n.History;return i?(typeof r.handlers.specific[t]=="undefined"&&(r.handlers.specific[t]=[]),r.handlers.specific[t].push(i)):(i=t,r.handlers.generic.push(i)),!0},trigger:function(t){var u=n.History,i,f,e,r;if(typeof t=="undefined"&&(t=u.getState()),typeof u.handlers.specific[t]!="undefined")for(r=u.handlers.specific[t],i=0,f=r.length;i<f;++i)e=r[i],e(t);for(r=u.handlers.generic,i=0,f=r.length;i<f;++i)e=r[i],e(t);return!0},construct:function(){var t=n.History;return n(document).ready(function(){t.domReady()}),!0},configure:function(t){var i=n.History;return i.options=n.extend(i.options,t),!0},domReadied:!1,domReady:function(){var t=n.History;if(!t.domRedied)return t.domRedied=!0,t.$window=n(window),t.$window.bind("hashchange",this.hashchange),setTimeout(t.hashchangeLoader,200),!0},nativeSupport:function(t){t=t||n.browser;var e=t.version,o=parseInt(e,10),u=e.split(/[^0-9]/g),r=parseInt(u[0],10),f=parseInt(u[1],10),s=parseInt(u[2],10),i=!1;return(t.msie||!1)&&o>=8?i=!0:(t.webkit||!1)&&o>=528?i=!0:t.mozilla||!1?r>1?i=!0:r===1&&(f>9?i=!0:f===9&&s>=2&&(i=!0)):(t.opera||!1)&&(r>10?i=!0:r===10&&f>=60&&(i=!0)),i},hashchangeLoader:function(){var t=n.History,f=t.nativeSupport(),r,i,u;return f?(u=t.getHash(),u&&t.$window.trigger("hashchange")):(n.browser.msie?(t.$iframe=n('<iframe id="jquery-history-iframe" style="display: none;"></$iframe>').prependTo(document.body)[0],t.$iframe.contentWindow.document.open(),t.$iframe.contentWindow.document.close(),i=!1,r=function(){var n=t.getHash(),r=t.getState(),u=t.extractHash(t.$iframe.contentWindow.document.location.hash);r!==n?(i||(t.$iframe.contentWindow.document.open(),t.$iframe.contentWindow.document.close(),t.$iframe.contentWindow.document.location.hash=n),i=!1,t.$window.trigger("hashchange")):r!==u&&(i=!0,t.setHash(u))}):r=function(){var n=t.getHash(),i=t.getState();i!==n&&t.$window.trigger("hashchange")},setInterval(r,200)),!0}},n.History.construct())}(jQuery);

;// utilities/jquery.history.override.js
$.History.extractHash=function(){return function(n){return n.replace(/^[^#!\/]*#/,"").replace(/^#+|#+$/,"")}}();

;// utilities/robloxTabs.js
$(function(){$.History.bind(function(n){var t="#"+n.substring(2);$(".rbx-tab a").each(function(){$(this).attr("href")==t&&$(this).click()})});var n=".rbx-tab";$(n).click(function(n){if(n.hasOwnProperty("originalEvent")){var t="!/"+$(this).find("a").attr("href").substring(1);$.History.go(t)}})});

;// utilities/robloxAds.js
"use strict";var Roblox=Roblox||{};Roblox.AdsHelper=Roblox.AdsHelper||{},Roblox.AdsLibrary={},Roblox.AdsLibrary.adsIdList=["Skyscraper-Abp-Left","Skyscraper-Abp-Right","Leaderboard-Abp","GamePageAdDiv1","GamePageAdDiv2","GamePageAdDiv3","ProfilePageAdDiv1","ProfilePageAdDiv2"],Roblox.AdsLibrary.adsParameters={"Skyscraper-Abp-Left":{element:$("#Skyscraper-Abp-Left"),template:null,fitTwoAds:!0,fitOneAd:!1,isSkyscraper:!0},"Skyscraper-Abp-Right":{element:$("#Skyscraper-Abp-Right"),tempalte:null,fitTwoAds:!0,fitOneAd:!0,isSkyscraper:!0},"Leaderboard-Abp":{element:$("#Leaderboard-Abp"),tempalte:null,fitTwoAds:!0,fitOneAd:!0,isLeaderboard:!0},GamePageAdDiv1:{element:$("#GamePageAdDiv1"),template:null,isPageAd:!0},GamePageAdDiv2:{element:$("#GamePageAdDiv2"),template:null,isPageAd:!0},GamePageAdDiv3:{element:$("#GamePageAdDiv3"),template:null,isPageAd:!0},ProfilePageAdDiv1:{element:$("#ProfilePageAdDiv1"),template:null,isPageAd:!0},ProfilePageAdDiv2:{element:$("#ProfilePageAdDiv2"),template:null,isPageAd:!0}},Roblox.AdsHelper.AdRefresher=function(){function c(n){return!n||!$.trim($(n).html())}function h(n){t.push(n)}function s(){return googletag.pubadsReady}function r(n){var u,f,e,i;typeof n=="undefined"&&(n=v),u=!1;for(f in t){if(e="#"+t[f]+" [data-js-adtype]",i=$(e),typeof i=="undefined")return;if(i.attr("data-js-adtype")==="iframead")o(i);else if(i.attr("data-js-adtype")==="gptAd")if(s())u=!0;else if(n>0){setTimeout(function(){r(--n)},y);break}}u&&googletag.cmd.push(function(){googletag.pubads().refresh()})}function o(n){var i=n.attr("src"),r,u,t;typeof i=="string"&&(r=i.indexOf("?")<0?"?":"&",u=i+r+"nocache="+(new Date).getMilliseconds().toString(),typeof n[0]!="undefined")&&(t=n[0].contentDocument,t===undefined&&(t=n[0].contentWindow),t&&t.location.href!=="about:blank"&&t.location.replace(u))}function n(n,t,i){i.length&&c(i)&&(i.append(n),r())}function b(){for(var u=$(window).width(),f,r,t,i=0;i<Roblox.AdsLibrary.adsIdList.length;i++)r=Roblox.AdsLibrary.adsIdList[i],t=Roblox.AdsLibrary.adsParameters[r],t&&!t.template&&(f=t.element,t.template=f.html());for(i=0;i<Roblox.AdsLibrary.adsIdList.length;i++)(r=Roblox.AdsLibrary.adsIdList[i],t=Roblox.AdsLibrary.adsParameters[r],t)&&(t.isSkyscraper?u>=e&&t.fitTwoAds?n(t.template,r,t.element):u<e&&u>=l?t.fitOneAd?n(t.template,r,t.element):t.element.empty():t.element.empty():t.isLeaderboard?u<p?t.element.empty():n(t.template,r,t.element):t.isPageAd&&(u<w?t.element.empty():n(t.template,r,t.element)))}var t=[],i=20,u=970,f=160,p=728,y=100,v=16,e=$("[data-max-width-for-two-ads]").attr("data-max-width-for-two-ads")||u+f*2+48-i,l=$("[data-max-width-for-one-ads]").attr("data-max-width-for-one-ads")||u+f+24-i,a=1024,w=a-i;return{registerAd:h,refreshAds:r,adjustAdsFitScreen:b,getAds:n}}(),Roblox.AdsHelper.DynamicAdCreator=function(){function n(){var n=$(".dynamic-ad").filter(".unpopulated");n.each(function(n,t){var i=$(t),u=i.attr("data-ad-slot"),f=parseInt(i.attr("data-ad-width")),e=parseInt(i.attr("data-ad-height")),r=i.children(".ad-slot").attr("id");googletag.cmd.push(function(){var n=googletag.defineSlot(u,[f,e],r).addService(googletag.pubads());googletag.display(r),googletag.pubads().refresh([n])}),i.removeClass("unpopulated")})}return{populateNewAds:n}}(),$(function(){$(window).resize(function(){Roblox.AdsHelper.AdRefresher.adjustAdsFitScreen()})});

;// StringTruncator.js
function InitStringTruncator(){isInitialized||(fitStringSpan=document.createElement("span"),fitStringSpan.style.display="inline-block",fitStringSpan.style.visibility="hidden",fitStringSpan.style.height="0px",fitStringSpan.style.padding="0px",document.body.appendChild(fitStringSpan),isInitialized=!0)}function fitStringToWidth(n,t,i){function o(n){return n.replace("<","&lt;").replace(">","&gt;")}var u,r,f,e,s;if(isInitialized||InitStringTruncator(),i&&(fitStringSpan.className=i),u=o(n),fitStringSpan.innerHTML=u,fitStringSpan.offsetWidth>t){for(r=0,e=n.length;s=e-r>>1;)f=r+s,fitStringSpan.innerHTML=o(n.substring(0,f))+"&hellip;",fitStringSpan.offsetWidth>t?e=f:r=f;u=n.substring(0,r)+"&hellip;"}return u}function fitStringToWidthSafe(n,t,i){var r=fitStringToWidth(n,t,i),u;return r.indexOf("&hellip;")!=-1&&(u=r.lastIndexOf(" "),u!=-1&&u+10<=r.length&&(r=r.substring(0,u+2)+"&hellip;")),r}function fitStringToWidthSafeText(n,t,i){return fitStringToWidthSafe(n,t,i).replace("&hellip;","...")}var isInitialized=!1,fitStringSpan=null;

;// VotingPanel.js
var Roblox=Roblox||{};Roblox.Voting=function(){var i=function(){var t=$(".voting-panel"),i,u;t.length!==0&&($(".users-vote .upvote").unbind().click(function(){r($(this),!0)}),$(".users-vote .downvote").unbind().click(function(){r($(this),!1)}),i=parseInt(t.data("total-up-votes")),u=parseInt(t.data("total-down-votes")),n(i,u))},e=function(n,t){var r="/games/votingservice/"+t;$.ajax({url:r,success:function(t){n.replaceWith(t),$(function(){i()})}})},r=function(n,i){var e=$(".voting-panel").data("user-authenticated");if(!e){f("GuestUser");return}var o=$(".voting-panel").data("target-id"),r="/voting/vote?assetId="+o+"&vote=",u=$(".voting-panel").data("vote-url");u&&(r=u),n.hasClass("selected")||n.find("i").hasClass("selected")||n.find(".icon-like, .icon-dislike").hasClass("selected")?t(r,null):t(r,i)},t=function(n,t){$(".voting-panel .loading").show(),$.ajax({type:"POST",url:n+t,success:o,error:s})},o=function(t){var o=$(".icon-like").length;if($(".voting-panel .loading").hide(),t.Success){u(t.Model.UpVotes,t.Model.DownVotes);var i=$(".voting-panel .upvote"),r=$(".voting-panel .downvote"),e=$(".users-vote");o&&(i=$(".voting-panel .upvote .icon-like"),r=$(".voting-panel .downvote .icon-dislike")),t.Model.UserVote!==null?e.hasClass("has-voted")||e.addClass("has-voted"):e.removeClass("has-voted"),i.hasClass("selected")&&i.removeClass("selected"),r.hasClass("selected")&&r.removeClass("selected"),t.Model.UserVote!==null&&(t.Model.UserVote?i.addClass("selected"):r.addClass("selected")),n(t.Model.UpVotes,t.Model.DownVotes)}else f(t.ModalType)},s=function(){$(".voting-panel .loading").hide()},n=function(n,t,i){var e=i||$("#voting-section"),r,u,f;isNaN(n)||isNaN(t)||(r=n===0?0:t===0?100:Math.floor(n/(n+t)*100),r>100&&(r=100),u=e.find(".vote-container"),f=u.find(".vote-background"),u.find(".vote-percentage").css("width",r+"%"),t>0?f.addClass("has-votes"):f.removeClass("has-votes"))},u=function(t,i){t=Roblox.NumberFormatting.abbreviatedFormat(t),i=Roblox.NumberFormatting.abbreviatedFormat(i),$(".voting-panel .total-upvotes-text").text(t),$(".voting-panel .total-downvotes-text").text(i),$(".voting-panel #vote-up-text").text(t),$(".voting-panel #vote-down-text").text(i),n(t,i)},h=function(n){var t=Roblox.Lang.VotingPanelResources,i=Roblox.Intl&&t&&new Roblox.Intl,r=$("#voting-section"),u=r.data("accountPageUrl"),f=r.data("registerUrl"),o="<a href='"+u+"'>"+t["Label.AccountPageTitle"]+"</a>",s="<a href='"+f+"'>"+t["Label.LoginOrRegisterPageTitle"]+"</a>",e={EmailIsVerified:{titleText:t["Label.EmailVerifiedTitle"],bodyContent:i.f(t["Label.EmailVerifiedMessage"],{accountPageLink:o}),onAccept:function(){window.location.href=u},acceptColor:Roblox.Dialog.green,acceptText:t["Label.Accept"],declineText:t["Label.Decline"],allowHtmlContentInBody:!0},PlayGame:{titleText:t["Label.PlayGameTitle"],bodyContent:t["Label.PlayGameMessage"],showAccept:!1,declineText:t["Label.Ok"]},UseModel:{titleText:t["Label.UseModelTitle"],bodyContent:t["Label.UseModelMessage"],showAccept:!1,declineText:t["Label.Ok"]},InstallPlugin:{titleText:t["Label.InstallPluginTitle"],bodyContent:t["Label.InstallPluginMessage"],showAccept:!1,declineText:t["Label.Ok"]},BuyGamePass:{titleText:t["Label.BuyGamePassTitle"],bodyContent:t["Label.BuyGamePassMessage"],showAccept:!1,declineText:t["Label.Ok"]},FloodCheckThresholdMet:{titleText:t["Label.FloodCheckTitle"],bodyContent:t["Label.FloodCheckMessage"],showAccept:!1,declineText:t["Label.Ok"]},GuestUser:{titleText:t["Label.GuestUserTitle"],bodyContent:"<div>"+t["Label.YouMustLoginToVote"]+"</div><div>"+i.f(t["Label.GuestUserMessage"],{loginOrRegisterPageLink:s})+"</div>",onAccept:function(){window.location.href=f},acceptColor:Roblox.Dialog.green,acceptText:t["Label.Login"],declineText:t["Label.Decline"],allowHtmlContentInBody:!0},Error:{titleText:t["Label.UnknownProblemTitle"],bodyContent:t["Label.UnknownProblemMessage"],showAccept:!1,declineText:t["Label.Ok"]},AssetNotVoteable:{titleText:t["Label.AssetNotVoteableTitle"],bodyContent:t["Label.AssetNotVoteableMessage"],showAccept:!1,declineText:t["Label.Ok"]}};return e[n]||e.Error},f=function(n){n&&Roblox.Dialog.open(h(n))};return{Vote:t,Initialize:i,SetVotes:u,UpdateVoteBar:n,LoadVotingService:e}}(),$(function(){Roblox.Voting.Initialize()});

;// GameItemCard.js
var Roblox=Roblox||{};$(function(){var n=$("[data-voting-processed=false]");n.each(function(n,t){var i=$(t),r=i.find(".vote-container"),u=parseInt(r.attr("data-upvotes")),f=parseInt(r.attr("data-downvotes"));Roblox.Voting.UpdateVoteBar(u,f,i),i.attr("data-voting-processed",!0)})});

;// GenericConfirmation.js
typeof Roblox=="undefined"&&(Roblox={}),typeof Roblox.GenericConfirmation=="undefined"&&(Roblox.GenericConfirmation=function(){function w(){n.isOpen=!1,t()}function k(t){var a,e,o,s,l;n.isOpen=!0,a={titleText:"",bodyContent:"",footerText:"",acceptText:Roblox.Resources.GenericConfirmation.yes,declineText:Roblox.Resources.GenericConfirmation.No,acceptColor:u,declineColor:f,xToCancel:!1,onAccept:function(){return!1},onDecline:function(){return!1},onCancel:function(){return!1},imageUrl:null,allowHtmlContentInBody:!1,allowHtmlContentInFooter:!1,dismissable:!0,fieldValidationRequired:!1,onOpenCallback:function(){}},t=$.extend({},a,t),c.overlayClose=t.dismissable,c.escClose=t.dismissable,e=$(i),e.html(t.acceptText),e.attr("class","btn-large "+t.acceptColor),e.unbind(),e.bind("click",function(){return v(e)?!1:(t.fieldValidationRequired?nt(t.onAccept):h(t.onAccept),!1)}),o=$(r),o.html(t.declineText),o.attr("class","btn-large "+t.declineColor),o.unbind(),o.bind("click",function(){return v(o)?!1:(h(t.onDecline),!1)}),$('[data-modal-handle="confirmation"] div.Title').text(t.titleText),s=$("[data-modal-handle='confirmation']"),t.imageUrl==null?s.addClass("noImage"):(s.find("img.GenericModalImage").attr("src",t.imageUrl),s.removeClass("noImage")),t.allowHtmlContentInBody?$("[data-modal-handle='confirmation'] div.Message").html(t.bodyContent):$("[data-modal-handle='confirmation'] div.Message").text(t.bodyContent),$.trim(t.footerText)==""?$('[data-modal-handle="confirmation"] div.ConfirmationModalFooter').hide():$('[data-modal-handle="confirmation"] div.ConfirmationModalFooter').show(),t.allowHtmlContentInFooter?$('[data-modal-handle="confirmation"] div.ConfirmationModalFooter').html(t.footerText):$('[data-modal-handle="confirmation"] div.ConfirmationModalFooter').text(t.footerText),$("[data-modal-handle='confirmation']").modal(c),l=$("a.genericmodal-close"),l.unbind(),l.bind("click",function(){return h(t.onCancel),!1}),t.xToCancel||l.hide(),t.onOpenCallback()}function a(n){n.hasClass(f)?n.addClass(s):n.hasClass(l)?n.addClass(e):n.hasClass(u)&&n.addClass(o)}function v(n){return n.hasClass(o)||n.hasClass(s)||n.hasClass(e)?!0:!1}function b(){var n=$(i),t=$(r);a(n),a(t)}function g(){var u=$(i),t=$(r),n=o+" "+s+" "+e;u.removeClass(n),t.removeClass(n)}function p(){if(n.isOpen){var t=$(i);t.click()}}function y(){var n=$(r);n.click()}function t(t){n.isOpen=!1,typeof t!="undefined"?$.modal.close(t):$.modal.close()}function h(n){t(),typeof n=="function"&&n()}function nt(n){if(typeof n=="function"){var i=n();if(i!=="undefined"&&i==!1)return!1}t()}var l="btn-primary",u="btn-neutral",f="btn-negative",e="btn-disabled-primary",o="btn-disabled-neutral",s="btn-disabled-negative",d="btn-none",i="#roblox-confirm-btn",r="#roblox-decline-btn",n={isOpen:!1},c={overlayClose:!0,escClose:!0,opacity:80,overlayCss:{backgroundColor:"#000"},onClose:w};return{open:k,close:t,disableButtons:b,enableButtons:g,clickYes:p,clickNo:y,status:n,green:l,blue:u,gray:f,none:d}}()),$(document).keypress(function(n){Roblox.GenericConfirmation.status.isOpen&&n.which===13&&Roblox.GenericConfirmation.clickYes()});

;// utilities/dialog.js
typeof Roblox=="undefined"&&(Roblox={}),typeof Roblox.Dialog=="undefined"&&(Roblox.Dialog=function(){function g(f){var k,c,v,w,o,b;n.isOpen=!0,k={titleText:"",bodyContent:"",footerText:"",footerMiddleAligned:!1,acceptText:Roblox.Lang.ControlsResources["Action.Yes"]||a.Yes,declineText:Roblox.Lang.ControlsResources["Action.No"]||a.No,acceptColor:h,declineColor:s,xToCancel:!1,onAccept:function(){return!1},onDecline:function(){return!1},onCancel:function(){return!1},imageUrl:null,showAccept:!0,showDecline:!0,allowHtmlContentInBody:!1,allowHtmlContentInFooter:!1,dismissable:!0,fieldValidationRequired:!1,onOpenCallback:function(){},onCloseCallback:t,cssClass:null,checkboxAgreementText:Roblox.Lang.ControlsResources["Action.Agree"]||a.Agree,checkboxAgreementRequired:!1},f=$.extend({},k,f),i.overlayClose=f.dismissable,i.escClose=f.dismissable,f.onCloseCallback&&(i.onClose=function(){f.onCloseCallback(),t()}),c=$(u),c.html(f.acceptText),c.attr("class",f.acceptColor),c.unbind(),c.bind("click",function(){return p(c)?!1:(f.fieldValidationRequired?nt(f.onAccept):l(f.onAccept),!1)}),v=$(e),v.html(f.declineText),v.attr("class",f.declineColor),v.unbind(),v.bind("click",function(){return p(v)?!1:(l(f.onDecline),!1)}),w=$(tt),w.unbind(),w.bind("change",function(){w.is(":checked")?y(c):r(c)}),o=$('[data-modal-type="confirmation"]'),o.find(".modal-title").text(f.titleText),f.imageUrl==null?o.addClass("noImage"):(o.find("img.modal-thumb").attr("src",f.imageUrl),o.removeClass("noImage")),n.extraClass&&(o.removeClass(n.extraClass),n.extraClass=!1),f.cssClass!=null&&(o.addClass(f.cssClass),n.extraClass=f.cssClass),f.allowHtmlContentInBody?o.find(".modal-message").html(f.bodyContent):o.find(".modal-message").text(f.bodyContent),f.checkboxAgreementRequired?(r(c),o.find(".modal-checkbox.checkbox > input").prop("checked",!1),o.find(".modal-checkbox.checkbox > label").text(f.checkboxAgreementText),o.find(".modal-checkbox.checkbox").show()):(o.find(".modal-checkbox.checkbox > input").prop("checked",!0),o.find(".modal-checkbox.checkbox").hide()),$.trim(f.footerText)==""?o.find(".modal-footer").hide():o.find(".modal-footer").show(),f.allowHtmlContentInFooter?o.find(".modal-footer").html(f.footerText):o.find(".modal-footer").text(f.footerText),f.footerMiddleAligned&&o.find(".modal-footer").addClass("modal-footer-center"),o.modal(i),b=$(d+" .modal-header .close"),b.unbind(),b.bind("click",function(){return l(f.onCancel),!1}),f.xToCancel||b.hide(),f.showAccept||c.hide(),f.showDecline||v.hide(),$("#rbx-body").addClass("modal-mask"),f.onOpenCallback()}function r(n){n.hasClass(s)?n.addClass(f):n.hasClass(v)?n.addClass(o):n.hasClass(h)&&n.addClass(c)}function p(n){return n.hasClass(c)||n.hasClass(f)||n.hasClass(o)?!0:!1}function rt(){var n=$(u),t=$(e);r(n),r(t)}function y(n){n.hasClass(f)?(n.removeClass(f),n.addClass(s)):n.hasClass(o)?(n.removeClass(o),n.addClass(v)):n.hasClass(c)&&(n.removeClass(c),n.addClass(h))}function w(){var n=$(u),t=$(e);y(n),y(t)}function k(){if(n.isOpen){var t=$(u);t.click()}}function b(){var n=$(e);n.click()}function t(t){n.isOpen=!1,typeof t!="undefined"?$.modal.close(t):$.modal.close(),$("#rbx-body").removeClass("modal-mask")}function l(n){t(),typeof n=="function"&&n()}function nt(n){if(typeof n=="function"){var i=n();if(i!=="undefined"&&i==!1)return!1}t()}function ut(n,t){var i=$(".modal-body");n?(i.find(".modal-btns").hide(),i.find(".modal-processing").show()):(i.find(".modal-btns").show(),i.find(".modal-processing").hide()),typeof t!="undefined"&&t!==""&&$.modal.close("."+t)}var d=".simplemodal-container",v="btn-primary-md",h="btn-secondary-md",s="btn-control-md",o="btn-primary-md disabled",c="btn-secondary-md disabled",f="btn-control-md disabled",it="btn-none",u=".modal-btns #confirm-btn",e=".modal-btns #decline-btn",tt="#modal-checkbox-input",n={isOpen:!1},i={overlayClose:!0,escClose:!0,opacity:80,zIndex:1040,overlayCss:{backgroundColor:"#000"},onClose:t,focus:!1},a={Yes:"Yes",No:"No",Agree:"Agree"};return{open:g,close:t,disableButtons:rt,enableButtons:w,clickYes:k,clickNo:b,status:n,toggleProcessing:ut,green:v,blue:h,white:s,none:it}}()),$(document).keypress(function(n){Roblox.Dialog.isOpen&&n.which===13&&Roblox.Dialog.clickYes()});

;// common/deviceMeta.js
var Roblox=Roblox||{};Roblox.DeviceMeta=function(){var t=document.querySelector('meta[name="device-meta"]');if(t===null){console.debug("Error loading device information from meta tag - please check if meta tag is present");return}var n=t.dataset||{},i={android:"android",ios:"ios",xbox:"xbox",uwp:"uwp",amazon:"amazon",win32:"win32",universalapp:"universalApp",unknown:"unknown"},r={computer:"computer",tablet:"tablet",phone:"phone",console:"console"};return function(){return{deviceType:r[n.deviceType]||"",appType:i[n.appType]||"",isInApp:n.isInApp==="true",isDesktop:n.isDesktop==="true",isPhone:n.isPhone==="true",isTablet:n.isTablet==="true",isConsole:n.isConsole==="true",isAndroidApp:n.isAndroidApp==="true",isIosApp:n.isIosApp==="true",isUWPApp:n.isUwpApp==="true",isXboxApp:n.isXboxApp==="true",isAmazonApp:n.isAmazonApp==="true",isWin32App:n.isWin32App==="true",isStudio:n.isStudio==="true",isIosDevice:n.isIosDevice==="true",isAndroidDevice:n.isAndroidDevice==="true",isUniversalApp:n.isUniversalApp==="true"}}}();

;// TosModalCheck.js
function showTosModal(n,t,i,r){Roblox.Dialog.open({titleText:n,bodyContent:t,acceptText:i,onAccept:function(){submitTosAgreement(r)},acceptColor:Roblox.Dialog.blue,fieldValidationRequired:!1,dismissable:!1,xToCancel:!1,declineColor:Roblox.Dialog.none,allowHtmlContentInBody:!0})}function submitTosAgreement(n){$.ajax({type:"POST",url:n,contentType:"application/json; charset=utf-8",success:function(){}})}$(function(){var n,t,i,r,u="/UserCheck/show-tos",f=$("#TosAgreementInfo").data("terms-check-needed");$.ajax({type:"GET",url:u,data:{isLicensingTermsCheckNeeded:f},contentType:"application/json; charset=utf-8",success:function(u){if(u.PartialViewName){var f=Roblox.Intl&&new Roblox.Intl,e='<a href="'+u.TermsOfServiceUrl+'" class="text-link" target="_blank">',s=' <a href="'+u.PrivacyUrl+'" class="text-link" target="_blank">',o='<a href="'+u.LegalChangesUrl+'" class="text-link" target="_blank">';u.PartialViewName==="CaptureTosAgreement_v2"?(n=f.f(u.LangResources["Heading.TosHaveChangedTitle"]),t=f.f(u.LangResources["Message.AgreeToTosAndPrivacyBody"],{tosLinkStart:e,tosLinkEnd:"</a>",privacyLinkStart:s,privacyLinkEnd:"</a>",legalChangesLinkStart:o,legalChangesLinkEnd:"</a>"}),i=f.f(u.LangResources["Label.IAgree"]),r="/UserCheck/update-tos"):u.PartialViewName==="CaptureTosAgreementWithExplicitLicenseClause"&&(n=f.f(u.LangResources["Heading.TosAgreementTitle"]),t=f.f(u.LangResources["Message.TosAgreementBody"],{tosLinkStart:e,tosLinkEnd:"</a>",legalChangesLinkStart:o,legalChangesLinkEnd:"</a>"}),i=f.f(u.LangResources["Label.IAgree"]),r="/UserCheck/update-tos-licensing"),showTosModal(n,t,i,r)}},error:function(){}})});

;// AbuseReport/AbuseReportDispatcher.js
var Roblox=Roblox||{};Roblox.AbuseReportDispatcher=function(){var i=!1,n=function(n,t){n=n.replace(/[\[\]]/g,"\\$&");var r=new RegExp("[?&]"+n+"(=([^&#]*)|&|#|$)"),i=r.exec(t);return i?i[2]?decodeURIComponent(i[2].replace(/\+/g," ")):"":null},r=function(t){var i,o;if(typeof t!="string")return!1;t=t.toLowerCase();var s=t.split("?"),f=s[0],r,u=Roblox.AbuseReportPVMeta,h=Roblox.DeviceMeta();if(u.inApp=h.isInApp,f&&typeof f=="string"&&(r=f.split("abusereport/")[1]),r&&(i={actionName:r,id:n("id",t),redirectUrl:n("redirecturl",t)},n("conversationid",t)&&(i.conversationId=n("conversationid",t)),n("partyguid",t)&&(i.partyGuid=n("partyguid",t)),i.id&&i.redirectUrl)){var c=$.param(i),e="abusereport/embedded/"+r+"?"+c,l=Roblox.Endpoints.getAbsoluteUrl("/"+e);u.inApp?u.inAppEnabled?(o={urlPath:e,feature:"Abuse Report"},console.debug("Calling navigateToFeature for Hybrid Overlay"),Roblox.Hybrid.Navigation.navigateToFeature(o,function(n){console.debug("navigateToFeature ---- status:"+n)})):window.location.href=t:window.location.href=u.phoneEnabled?l:t}},t=function(n){n.preventDefault();var t=$(this).attr("href");t&&r(t)},u=function(){if(!i){$(".abuse-report-modal").click(t);$(".messages-container").on("click",".abuse-report-modal",t);$("#AjaxCommentsContainer").on("click",".abuse-report-modal",t);$("#item-context-menu").on("click",".abuse-report-modal",t);$(".GroupWallPane").on("click",".abuse-report-modal",t);$(".group-details-container").on("click",".abuse-report-modal",t);i=!0}};return{triggerUrlAction:r,initialize:u}}(),$(document).ready(function(){Roblox.AbuseReportDispatcher.initialize()});

;//Bundle detector
Roblox && Roblox.BundleDetector && Roblox.BundleDetector.bundleDetected('page');