PageSourceSearch

https://gamelo.net/lib/PopForums/dist/PopForums.min.js

js gamelo.net collected 2026-09-25 11:47:29 UTC 18,553 bytes, 2 lines download raw bytes

1"use strict";$(function(){if(0<$("#ForumContainer #TopBreadcrumb").length&&($(window).scroll(function(){PopForums.checkScroll()}),$(window).on("resize",function(){PopForums.checkScroll()}),PopForums.checkScroll()),window.location.hash){for(var o=window.location.hash;"#"==o.charAt(0);)o=o.substr(1);var t=$("div[data-postID='"+o+"']");if(0<$("#PostStream").has(t).length){var e=t.offset();if(e){var r=$("#ForumContainer #FixedBreadcrumb").outerHeight(),s=parseInt($(".postItem").css("margin-top"),10),a=e.top-r-s+PopForums.navOffset;$("html,body").animate({scrollTop:a},"fast")}}$(window).on("load",function(){setTimeout(function(){PopForums.checkScroll()},1e3)})}});var PopForums={};PopForums.areaPath="/"+document.location.pathname.split("/")[1]+"/Forums",PopForums.currentTopicState=null,PopForums.navOffset=0,PopForums.editorCSS="/lib/bootstrap/dist/css/bootstrap.min.css,/lib/PopForums/dist/Editor.min.css",PopForums.postNoImageToolbar="cut copy paste | bold italic | bullist numlist blockquote removeformat | link",PopForums.editorSettings={theme:"silver",plugins:"paste lists image link",content_css:PopForums.editorCSS,menubar:!1,toolbar:"cut copy paste | bold italic | bullist numlist blockquote removeformat | link | image",statusbar:!1,target_list:!1,link_title:!1,image_description:!1,image_dimensions:!1,browser_spellcheck:!0,object_resizing:!1,relative_urls:!1,remove_script_host:!1,contextmenu:"",mobile:{theme:"silver"}},PopForums.checkScroll=function(){var o=$("#ForumContainer #FixedBreadcrumb"),t=$("#ForumContainer #TopBreadcrumb");0<t.length&&(PopForums.crumbTop=t.offset().top+PopForums.navOffset);var e=document.documentElement.scrollTop||document.body.scrollTop;if(e>PopForums.crumbTop&&"none"===o.css("display")){var r=$("#ForumContainer #TopBreadcrumb").outerWidth();o.css("width",r+"px"),o.css("top",PopForums.navOffset),o.fadeIn(150)}else e<PopForums.crumbTop&&o.fadeOut(150)},PopForums.processLogin=function(){PopForums.processLoginBase("/Identity/Login")},PopForums.processLoginExternal=function(){PopForums.processLoginBase("/Identity/LoginAndAssociate")},PopForums.processLoginBase=function(o){$.ajax({url:PopForums.areaPath+o,type:"POST",data:{email:$("#EmailLogin").val(),password:$("#PasswordLogin").val(),persistCookie:$("#PersistCookie").is(":checked")},dataType:"json",success:function(o){var t=$("#LoginResult");switch(o.result){case!0:var e=$("#Referrer").val();location=e;break;default:t.html(o.message),t.removeClass("d-none")}},error:function(){var o=$("#LoginResult");o.html("There was an unknown error while attempting login"),o.removeClass("d-none")}})},PopForums.topicListSetup=function(t){PopForums.startTimeUpdater();var e=$("#NewTopicButton");e.click(function(){var o=$("#NewTopic");o.load(PopForums.areaPath+"/Forum/PostTopic/"+t,function(){"true"==$("#IsImageEnabled").val().toLowerCase()||(PopForums.editorSettings.toolbar=PopForums.postNoImageToolbar),"true"==$("#IsPlainText").val().toLowerCase()||(PopForums.editorSettings.selector="#NewTopic #FullText",tinyMCE.init(PopForums.editorSettings)),o.slideDown(),e.hide(),$("#PreviewModal").on("shown.bs.modal",function(){PopForums.previewPost()})})})},PopForums.loadReply=function(t,o,e,r){$(window).off("scroll",PopForums.ScrollLoad);var s=$("#NewReply"),a=PopForums.areaPath+"/Forum/PostReply/"+t;null!=o&&(a+="?quotePostID="+o),null!=e&&(a+=null==o?"?replyID="+e:"&replyID="+e),s.load(a,function(){if("true"==$("#IsImageEnabled").val().toLowerCase()||(PopForums.editorSettings.toolbar=PopForums.postNoImageToolbar),"true"==$("#IsPlainText").val().toLowerCase()||(PopForums.editorSettings.selector="#NewReply #FullText",tinyMCE.init(PopForums.editorSettings)),s.slideDown(),$("#ReplyButton").hide(),PopForums.scrollToElement("NewReply"),$("#MorePostsBeforeReplyButton").click(function(){$.get(PopForums.areaPath+"/Forum/TopicPartial/"+t+"?lastPost="+PopForums.currentTopicState.lastVisiblePost+"&lowpage="+PopForums.currentTopicState.lowPage,function(o){var t=$(o),e=t.find(".pagerLinks").detach(),r=t.find(".lastPostID").detach();PopForums.currentTopicState.lastVisiblePost=r.val(),$("#PostStream").append(t),e.replaceAll(".pagerLinks"),$(".postItem img:not('.avatar')").addClass("postImage"),$(".morePostsButton").remove(),PopForums.setReplyMorePosts(PopForums.currentTopicState.lastVisiblePost)})}),r){var o=(new signalR.HubConnectionBuilder).withUrl("/TopicsHub").build();o.start().then(function(){o.invoke("getLastPostID",t).then(function(o){PopForums.setReplyMorePosts(o)})})}$("#PreviewModal").on("shown.bs.modal",function(){PopForums.previewPost()}),PopForums.TopicState.replyLoaded=!0})}
1,PopForums.loadComment=function(o,t){var e=$("[data-postid*='"+t+"']").find(".commentHolder"),r=PopForums.areaPath+"/Forum/PostReply/"+o;null!=t&&(r+="?replyID="+t),e.load(r,function(){"true"==$("#IsImageEnabled").val().toLowerCase()||(PopForums.editorSettings.toolbar=PopForums.postNoImageToolbar),"true"==$("#IsPlainText").val().toLowerCase()||(PopForums.editorSettings.selector=".postForm #FullText",tinyMCE.init(PopForums.editorSettings)),e.slideDown(),$("#PreviewModal").on("shown.bs.modal",function(){PopForums.previewPost()})})},PopForums.previewPost=function(){tinyMCE.triggerSave();var t=$("#ParsedFullText");$.ajax({url:PopForums.areaPath+"/Forum/PreviewText",type:"POST",data:{FullText:$(".postForm #FullText").val(),IsPlainText:$(".postForm #IsPlainText").val()},dataType:"json",converters:{"text json":!0},success:function(o){t.html(o)},error:function(){t.html("There was a problem getting the preview.")}})},PopForums.loadFeed=function(){var o=(new signalR.HubConnectionBuilder).withUrl("/FeedHub").build();o.on("notifyFeed",function(o){var t=$("#FeedList"),e=PopForums.populateFeedRow(o);t.prepend(e),e.fadeIn()}),o.start().then(function(){return o.invoke("listenToAll")}),PopForums.startTimeUpdater()},PopForums.populateFeedRow=function(o){var t=$("#ActivityFeedTemplate").clone();return t.removeAttr("id"),t.find(".feedItemText").html(o.message),t.find(".fTime").attr("data-utc",o.utc),t.find(".fTime").text(o.timeStamp),t},PopForums.setReplyMorePosts=function(o){o==PopForums.currentTopicState.lastVisiblePost?$("#MorePostsBeforeReplyButton").css("visibility","hidden"):$("#MorePostsBeforeReplyButton").css("visibility","visible")},PopForums.topicSetup=function(e,o,t,r){PopForums.startTimeUpdater();var s=$("#LastPostID").val();PopForums.currentTopicState=new PopForums.TopicState(o,s,t,e);var a=(new signalR.HubConnectionBuilder).withUrl("/TopicsHub").build();a.on("fetchNewPost",function(o){PopForums.TopicState.replyLoaded||PopForums.currentTopicState.highPage!=PopForums.currentTopicState.pageCount||($.get(PopForums.areaPath+"/Forum/Post/"+o,function(o){$(o).appendTo("#PostStream")}),$("#LastPostID").val(o),PopForums.currentTopicState.lastVisiblePost=o)}),a.on("notifyNewPosts",function(o){PopForums.setReplyMorePosts(o)}),a.start().then(function(){return a.invoke("listenTo",e)}),$(".postItem img:not('.avatar')").addClass("postImage"),$(document).on("click","#ReplyButton,.replyLink",function(){PopForums.loadReply(e,null,r,!0)}),$(document).on("click",".quoteLink",function(){var o=$(this).parents(".postItem").attr("data-postID");PopForums.loadReply(e,o,r,!0)}),$(document).on("click",".postNameLink",function(){var o=$(this).parents(".postItem").find(".miniProfileBox"),t=$(this).parents(".postItem").attr("data-userID"),e=$(this).find(".twirl");PopForums.loadMiniProfile(t,o,e)}),$(document).on("click",".voteCount",function(){var o=$(this).parents(".postItem"),t=o.attr("data-postID");o.find(".voters").slideDown(function(){$(this).load(PopForums.areaPath+"/Forum/Voters/"+t),$(this).mouseleave(function(){$(this).hide()}),$(this).css("display","block")}).css("display","block")}),$(document).on("click",".voteUp",function(){var t=$(this).parents(".postItem"),o=t.attr("data-postID"),e=$(this).closest(".postToolContainer").children(".voteCount");$.ajax({url:PopForums.areaPath+"/Forum/VotePost/"+o,type:"POST",success:function(o){e.html(o),t.find(".voteUp").replaceWith('<li class="list-inline-item">Voted</li>')}})}),PopForums.SetupSubscribeButton(e),PopForums.SetupFavoriteButton(e),$("#TopicModLogButton").click(function(){var o=$("#TopicModerationLog");o.is(":hidden")?o.load(PopForums.areaPath+"/Moderator/TopicModerationLog/"+e,function(){o.slideDown()}):o.slideUp()}),$(document).on("click",".postModLogButton",function(){var o=$(this).attr("data-postID"),t=$(this).closest(".postToolContainer").find(".moderationLog");t.is(":hidden")?t.load(PopForums.areaPath+"/Moderator/PostModerationLog/"+o,function(){t.slideDown()}):t.slideUp()}),$(document).on("click",".morePostsButton",function(){PopForums.LoadMorePosts(e,this)}),$(document).on("click",".previousPostsButton",function(){PopForums.currentTopicState.addStartPage();var o=PopForums.currentTopicState.lowPage,t=e,r=$("#PostStream"),s=$(this).detach();$.get(PopForums.areaPath+"/Forum/TopicPage/"+t+"?pageNumber="+o+"&low="+PopForums.currentTopicState.lowPage+"&high="+PopForums.currentTopicState.highPage,function(o){var t=$(o),e=t.find(".pagerLinks").detach();r.prepend(t),e.replaceAll(".pagerLinks"),1<PopForums.currentTopicState.lowPage&&r.prepend(s),$(".postItem img:not('.avatar')").addClass("postImage"),PopForums.currentTopicState.highPage==PopForums.currentTopicState.pageCount&&1==PopForums.currentTopicState.lowPage&&$(".pagerLinks").remove()})}),$(window).on("scroll",PopForums.ScrollLoad)},PopForums.qaTopicSetup=function(t){PopForums.startTimeUpdater(),$(".postItem img:not('.avatar')").addClass("postImage"),$(document).on("click",".commentLink",function(){var o=$(this).parents(".postItem").attr("data-postid");PopForums.loadComment(t,o)}),$(document).on("click","#ReplyButton",function(){var o=$(this).parents(".postContainer").attr("data-postid");PopForums.loadReply(t,null,o)}),$(document).on("click",".postNameLink",function(){var o=$(this).parents(".postUserData").find(".miniProfileBox"),t=$(this).parents(".postUserData").attr("data-userID"),e=$(this).find(".twirl");PopForums.loadMiniProfile(t,o,e)}
1),$(document).on("click",".voteUp",function(){var e=$(this).parents(".postItem"),o=e.attr("data-postid"),r=$(this).parents(".answerData").find(".badge");$.ajax({url:PopForums.areaPath+"/Forum/VotePost/"+o,type:"POST",success:function(o){r.html(o);var t=e.find(".voteUp");t.html("Voted"),t.removeClass("btn-link")}})}),$(document).on("click",".answerButton",function(){var o=$(this),t=o.parents(".postItem"),e=t.attr("data-postid"),r=t.attr("data-topicid");$.ajax({url:PopForums.areaPath+"/Forum/SetAnswer/",type:"POST",data:{postID:e,topicID:r},success:function(){$(".answerStatus").removeClass("check-icon").addClass("star-icon"),o.removeClass("star-icon").addClass("check-icon")}})}),PopForums.SetupSubscribeButton(t),PopForums.SetupFavoriteButton(t),$("#TopicModLogButton").click(function(){var o=$("#TopicModerationLog");o.is(":none")?o.load(PopForums.areaPath+"/Moderator/TopicModerationLog/"+t,function(){o.slideDown()}):o.slideUp()}),$(document).on("click",".postModLogButton",function(){var o=$(this).attr("data-postID"),t=$(this).closest(".postToolContainer").find(".moderationLog");t.is(":hidden")?t.load(PopForums.areaPath+"/Moderator/PostModerationLog/"+o,function(){t.slideDown()}):t.slideUp()})},PopForums.SetupSubscribeButton=function(o){var e=$("#SubscribeButton");e.click(function(){var t=$("#AsyncResponse");$.ajax({url:PopForums.areaPath+"/Subscription/ToggleSubscription/"+o,type:"POST",dataType:"json",success:function(o){switch(o.data.isSubscribed){case!0:e.val("Unsubscribe");break;case!1:e.val("Subscribe");break;default:t.html(o.Message)}},error:function(){t.html("There was an unknown error while attempting to use subscription")}})})},PopForums.SetupFavoriteButton=function(o){var e=$("#FavoriteButton");e.click(function(){var t=$("#AsyncResponse");$.ajax({url:PopForums.areaPath+"/Favorites/ToggleFavorite/"+o,type:"POST",dataType:"json",success:function(o){switch(o.data.isFavorite){case!0:e.val("Remove From Favorites");break;case!1:e.val("Make Favorite");break;default:t.html(o.Message)}},error:function(){t.html("There was an unknown error while attempting to use favorites")}})})},PopForums.ScrollLoad=function(){var o=$(window),t=$("#StreamBottom").offset().top-(o.scrollTop()+o.height());if(!PopForums.currentTopicState.loadingPosts&&t<250&&PopForums.currentTopicState.highPage<PopForums.currentTopicState.pageCount){PopForums.currentTopicState.loadingPosts=!0;
1var e=$(".morePostsButton");PopForums.LoadMorePosts(PopForums.currentTopicState.topicID,e)}},PopForums.LoadMorePosts=function(o,t){PopForums.currentTopicState.addEndPage();var e=PopForums.currentTopicState.highPage,r=o,a=$("#PostStream"),i=$(t).detach();$.get(PopForums.areaPath+"/Forum/TopicPage/"+r+"?pageNumber="+e+"&low="+PopForums.currentTopicState.lowPage+"&high="+PopForums.currentTopicState.highPage,function(o){var t=$(o),e=t.find(".pagerLinks").detach(),r=t.find(".lastPostID").detach(),s=t.find(".pageCount").detach();PopForums.currentTopicState.lastVisiblePost=r.val(),PopForums.currentTopicState.pageCount=s.val(),t=$("<div>").append(t),a.append(t),e.replaceAll(".pagerLinks"),PopForums.currentTopicState.highPage!=PopForums.currentTopicState.pageCount&&a.append(i),PopForums.currentTopicState.highPage==PopForums.currentTopicState.pageCount&&1==PopForums.currentTopicState.lowPage&&$(".pagerLinks").remove(),$(".postItem img:not('.avatar')").addClass("postImage"),PopForums.currentTopicState.loadingPosts=!1})},PopForums.TopicState=function(o,t,e,r){this.lowPage=o,this.highPage=o,this.lastVisiblePost=t,this.pageCount=e,this.loadingPosts=!1,this.topicID=r,this.replyLoaded=!1},PopForums.TopicState.prototype.addEndPage=function(){this.highPage++},PopForums.TopicState.prototype.addStartPage=function(){this.lowPage--},PopForums.postNewTopic=function(){$("SubmitNewTopic").attr("disabled","disabled"),tinyMCE.triggerSave(),$.ajax({url:PopForums.areaPath+"/Forum/PostTopic",type:"POST",data:{Title:$("#NewTopic #Title").val(),FullText:$("#NewTopic #FullText").val(),IncludeSignature:$("#NewTopic #IncludeSignature").is(":checked"),ItemID:$("#NewTopic #ItemID").val(),IsPlainText:$("#NewTopic #IsPlainText").val()},dataType:"json",success:function(o){var t=$("#PostResponseMessage");switch(o.result){case!0:window.location=o.redirect;break;default:t.html(o.message),$("#SubmitNewTopic").removeAttr("disabled"),t.show()}},error:function(){var o=$("#PostResponseMessage");o.html("There was an unknown error while trying to post"),$("#SubmitNewTopic").removeAttr("disabled"),o.show()}})},PopForums.postReply=function(){$("#SubmitReply").attr("disabled","disabled"),tinyMCE.triggerSave(),$.ajax({url:PopForums.areaPath+"/Forum/PostReply",type:"POST",data:{Title:$("#NewReply #Title").val(),FullText:$("#NewReply #FullText").val(),IncludeSignature:$("#NewReply #IncludeSignature").is(":checked"),ItemID:$("#NewReply #ItemID").val(),CloseOnReply:$("#CloseOnReply").is(":checked"),IsPlainText:$("#NewReply #IsPlainText").val(),ParentPostID:$("#NewReply #ParentPostID").val()},dataType:"json",success:function(o){var t=$("#PostResponseMessage");switch(o.result){case!0:window.location=o.redirect;break;default:t.html(o.message),$("#SubmitReply").removeAttr("disabled"),t.show()}},error:function(){var o=$("#PostResponseMessage");o.html("There was an unknown error while trying to post"),$("#SubmitReply").removeAttr("disabled"),o.show()}})},PopForums.loadMiniProfile=function(o,t,e){t.is(":hidden")?t.load(PopForums.areaPath+"/Account/MiniProfile/"+o,function(){t.slideDown()}):t.slideUp(),e.toggleClass("glyphicon-chevron-right glyphicon-chevron-down")},PopForums.scrollToElement=function(o){var t=document.getElementById(o),e=0;if(t.offsetParent)for(;t.offsetParent;)e+=t.offsetTop,t=t.offsetParent;else t.y&&(e+=t.y);var r=$("#TopBreadcrumb");r&&(e-=r.outerHeight()),e+=PopForums.navOffset,scrollTo(0,e)},PopForums.homeSetup=function(){var o=(new signalR.HubConnectionBuilder).withUrl("/ForumsHub").build();o.on("notifyForumUpdate",function(o){PopForums.updateForumStats(o)}),o.start().then(function(){return o.invoke("listenToAll")}),PopForums.startTimeUpdater()},PopForums.recentListen=function(s){var o=(new signalR.HubConnectionBuilder).withUrl("/RecentHub").build();o.on("notifyRecentUpdate",function(o){var t=$('#TopicList tr[data-topicID="'+o.topicID+'"]');if(0!=t.length)t.fadeOut(),t.remove();else{var e=$("#TopicList tr:not('#TopicTemplate')");e.length==s&&e.last().remove()}var r=PopForums.populateTopicRow(o).hide();r.removeClass("hidden"),$("#TopicList").prepend(r),r.fadeIn()}),o.start().then(function(){return o.invoke("register")})},PopForums.forumListen=function(s,o){var t=(new signalR.HubConnectionBuilder).withUrl("/
1ForumsHub").build();t.on("notifyUpdatedTopic",function(o){var t=$('#TopicList tr[data-topicID="'+o.topicID+'"]');if(0!=t.length)t.fadeOut(),t.remove();else{var e=$("#TopicList tr:not('#TopicTemplate')");e.length==s&&e.last().remove()}var r=PopForums.populateTopicRow(o).hide();r.removeClass("hidden"),$("#TopicList").prepend(r),r.fadeIn()}),t.start().then(function(){return t.invoke("listenTo",o)})},PopForums.populateTopicRow=function(o){var t=$("#TopicTemplate").clone();return t.attr("data-topicid",o.topicID),t.removeAttr("id"),t.find(".startedByName").text(o.startedByName),t.find(".indicatorLink").attr("href",o.link),t.find(".titleLink").text(o.title),t.find(".titleLink").attr("href",o.link),t.find(".forumTitle").text(o.forumTitle),t.find(".viewCount").text(o.viewCount),t.find(".replyCount").text(o.replyCount),t.find(".lastPostTime").text(o.lastPostTime),t.find(".lastPostName").text(o.lastPostName),t.find(".fTime").attr("data-utc",o.utc),t},PopForums.updateForumStats=function(o){var t=$("[data-forumid='"+o.forumID+"']");t.find(".topicCount").text(o.topicCount),t.find(".postCount").text(o.postCount),t.find(".lastPostTime").text(o.lastPostTime),t.find(".lastPostName").text(o.lastPostName),t.find(".fTime").attr("data-utc",o.utc),t.find(".newIndicator .icon-file-text2").removeClass("text-muted").addClass("text-primary")},PopForums.startTimeUpdater=function(){setTimeout(function(){PopForums.startTimeUpdater(),PopForums.updateTimes()},6e4)},PopForums.updateTimes=function(){var t=[],o=$(".fTime");$.each(o,function(){var o=$(this).attr("data-utc");(new Date-new Date(o+"Z"))/36e5<48&&t.push(o)}),0<t.length&&$.ajax({url:PopForums.areaPath+"/Time/GetTimes",type:"POST",data:{times:t},dataType:"json",traditional:!0,success:function(o){$.each(o,function(){$(".fTime[data-utc='"+this.key+"']").text(this.value)})},error:function(){}})};
2//# sourceMappingURL=PopForums.min.js.map

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.