!function(){var n={6555:function(){}},r={};function w(e){if(r[e])return r[e].exports;var t=r[e]={exports:{}};return n[e](t,t.exports,w),t.exports}w.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return w.d(t,{a:t}),t},w.d=function(e,t){for(var n in t)w.o(t,n)&&!w.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},w.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},function(){"use strict";var a=CoreUtilities,R=React,S=w.n(R),e=ReactDOM,t=PropTypes,n=w.n(t),r=ReactUtilities,i={common:[],feature:"Feature.Profile"},N=HeaderScripts,l="Heading.Statistics",q="Label.JoinDate",x="Label.PlaceVisits";function o(e){e=e.translate;return S().createElement("div",{className:"container-header"},S().createElement("h3",null,e(l)))}o.propTypes={translate:n().func.isRequired};var C=o;function c(e){var t=e.label,n=e.value,e=e.translate;return S().createElement("li",{className:"profile-stat"},S().createElement("p",{className:"text-label"},e(t)),S().createElement("p",{className:"text-lead"},n))}c.propTypes={label:n().string.isRequired,value:n().string.isRequired,translate:n().func.isRequired};var O=c;function u(e){var t=e.label,n=e.gameData,e=e.translate,r=0;return n.forEach(function(e){r+=Number.isNaN(e.placeVisits)?0:e.placeVisits}),r=a.numberFormat.getNumberFormat(r),S().createElement(O,{translate:e,label:t,value:r})}u.propTypes={label:n().string.isRequired,gameData:n().arrayOf(n().shape({placeVisits:n().number})).isRequired,translate:n().func.isRequired};var A=u,s=(t=Roblox).EnvironmentUrls.gamesApi,f=t.EnvironmentUrls.usersApi,d=function(e){return{url:"".concat(s,"/v2/users/").concat(e,"/games"),withCredentials:!0}},p={public:"Public"},m=50,v=function(e){return{url:"".concat(f,"/v1/users/").concat(e),withCredentials:!0}},T=function(e,t){t={accessFilter:p.public,cursor:t,limit:m};return a.httpService.get(d(e),t).then(function(e){return e.data})},D=function(e){return a.httpService.get(v(e),{}).then(function(e){return e.data})};function P(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,a=!1,i=void 0;try{for(var l,o=e[Symbol.iterator]();!(r=(l=o.next()).done)&&(n.push(l.value),!t||n.length!==t);r=!0);}catch(e){a=!0,i=e}finally{try{r||null==o.return||o.return()}finally{if(a)throw i}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return b(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return b(e,t)}(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 b(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function h(e){function t(e){u(new Date(e).toLocaleDateString())}var n=e.translate,r=N.authenticatedUser.created,a=N.authenticatedUser.id,i=q,l=x,o=P((0,R.useState)([]),2),c=o[0],u=o[1],s=P((0,R.useState)([]),2),e=s[0],f=s[1],o=P((0,R.useState)(!1),2),s=o[0],d=o[1],o=P((0,R.useState)(!1),2),p=o[0],m=o[1],v=null===(o=window)||void 0===o||null===(v=o.location)||void 0===v?void 0:v.pathname,v=v?v.split("/"):[],b=null!=v&&v.length&&3<v.length&&!Number.isNaN(v[2])?v[2]:a,h=parseInt(b,10)===a,g=(0,R.useCallback)(function(){h?t(r):D(b).then(function(e){null!=e&&e.created&&t(null==e?void 0:e.created)}).catch(console.debug)},[r,h,b]),y=(0,R.useCallback)(function(r,a){T(b,a).then(function(e){var t,n;e&&(t=e.nextPageCursor,n=e.data,e=(e=r).concat(n),t&&a!==t?y(e,t):(f(e),d(!0)))},function(){0<r.length&&(f(r),d(!0))}).catch(console.debug)},[b]),E=(0,R.useRef)(),w=(0,R.useCallback)(function(){var e;(null===(e=E.current)||void 0===e?void 0:e.getBoundingClientRect().top)<window.pageYOffset+window.innerHeight&&(p?window.removeEventListener("scroll",w):(m(!0),y([]),g()))},[y,p]);return(0,R.useEffect)(function(){return p||(w(),window.addEventListener("scroll",w)),function(){window.removeEventListener("scroll",w)}},[p,w]),S().createElement("div",{className:"section profile-statistics",ref:E},S().createElement(C,{translate:n}),S().createElement("div",{className:"section-content"},S().createElement("ul",{className:"profile-stats-container"},S().createElement(O,{translate:n,label:i,value:c}),s&&S().createElement(A,{translate:n,label:l,gameData:e}))))}h.propTypes={translate:n().func.isRequired};var g=h;function y(e){e=e.translate;return S().createElement(g,{translate:e})}y.propTypes={translate:n().func.isRequired};var E=(0,r.withTranslations)(y,i);w(6555),(0,a.ready)(function(){(0,e.render)(S().createElement(E,null),document.getElementById("profile-statistics-container"))})}()}();
//# sourceMappingURL=https://js.rbxcdn.com/267adedcfd46c18e9a18-profileStatistics.js.map

/* Bundle detector */
window.Roblox && window.Roblox.BundleDetector && window.Roblox.BundleDetector.bundleDetected("ProfileStatistics");