1"use strict";(self.webpackChunknodebb=self.webpackChunknodebb||[]).push([[5707],{7642(A,C,e){var h,g;h=[e(8454),e(984),e(7536),e(2269),e(2473),e(7459),e(1749),e(76)],g=(function(m,l,v,x,c,M,k,j){const f={},E={"event:user_status_change":I,"event:voted":R,"event:bookmarked":B,"event:topic_deleted":l.setDeleteState,"event:topic_restored":l.setDeleteState,"event:topic_purged":O,"event:topic_locked":l.setLockedState,"event:topic_unlocked":l.setLockedState,"event:topic_pinned":l.setPinnedState,"event:topic_unpinned":l.setPinnedState,"event:topic_moved":b,"event:post_edited":L,"event:post_purged":D,"event:post_deleted":P,"event:post_restored":P,"posts.bookmark":y,"posts.unbookmark":y,"posts.upvote":S,"posts.downvote":S,"posts.unvote":S,"event:new_post":v.onNewPost};f.init=function(){f.removeListeners();for(const[t,o]of Object.entries(E))socket.on(t,o)},f.removeListeners=function(){for(const[t,o]of Object.entries(E))socket.removeListener(t,o)};function I(t){app.updateUserStatus($(`[data-uid="${t.uid}"] [component="user/status"]`),t.status)}function R(t){const o=$('[data-pid="'+t.post.pid+'"] [component="post/vote-count"]').filter(function(p,d){return $(d).closest("[data-pid]").attr("data-pid")===String(t.post.pid)}),n=$('.reputation[data-uid="'+t.post.uid+'"]');o.text(t.post.votes).attr("data-votes",t.post.votes),n.text(t.user.reputation).attr("data-reputation",t.user.reputation)}function B(t){$('[data-pid="'+t.post.pid+'"] .bookmarkCount').filter(function(o,n){return $(n).closest("[data-pid]").attr("data-pid")===String(t.post.pid)}).text(t.post.bookmarks).attr("data-bookmarks",t.post.bookmarks)}function O(t){ajaxify.data.category&&ajaxify.data.category.slug&&String(t.tid)===String(ajaxify.data.tid)&&ajaxify.go("category/"+ajaxify.data.category.slug,null,!0)}function b(t){t&&t.slug&&String(t.tid)===String(ajaxify.data.tid)&&ajaxify.go("topic/"+t.slug,null,!0)}function L(t){if(!t||!t.post||String(t.post.tid)!==String(ajaxify.data.tid))return;const o=c.get("post/content",t.post.pid).filter(function(i,s){return String($(s).closest("[data-pid]").attr("data-pid"))===String(t.post.pid)}),n=$(`[data-pid="${t.post.pid}"]`),p=n.find('[component="post/editor"]').filter(function(i,s){return String($(s).closest("[data-pid]").attr("data-pid"))===String(t.post.pid)}),d=c.get("topic/title"),r=c.get("navbar/title").find("span"),a=c.get("breadcrumb/current");if(t.topic.rescheduled)return ajaxify.go("topic/"+t.topic.slug,null,!0);if(d.length&&t.topic.title&&t.topic.renamed){ajaxify.data.title=t.topic.title;const i="topic/"+t.topic.slug+(window.location.search?window.location.search:"");history.replaceState({url:i},null,window.location.protocol+"//"+window.location.host+config.relative_path+"/"+i),d.fadeOut(250,function(){d.text(t.topic.title).fadeIn(250)}),a.is(":visible")&&a.fadeOut(250,function(){a.find("span").text(t.topic.title),a.fadeIn(250)}),r.fadeOut(250,function(){r.text(t.topic.title).fadeIn(250)})}if(t.post.changed){o.fadeOut(250,function(){if(o.html(t.post.content),o.find("img:not(.not-responsive)").addClass("img-fluid"),x.wrapImagesInLinks(o.parent()),v.addBlockquoteEllipses(o.parent()),o.fadeIn(250),t.post.edited){const s={editor:t.editor,editedISO:utils.toISOString(t.post.edited)};app.parseAndTranslate("partials/topic/post-editor",s,function(u){p.replaceWith(u),n.find('[component="post/edit-indicator"]').removeClass("hidden").translateAttr("title",`[[global:edited-timestamp, ${j.isoTimeToLocaleString(s.editedISO,config.userLang)}]]`),n.find('[component="post/editor"] .timeago').timeago(),k.fire("action:posts.edited",t)})}});const i=$(`[component="post/parent"][data-parent-pid="${t.post.pid}"]`);i.length&&(i.find('[component="post/parent/content"]').html(t.post.content),i.find("img:not(.not-responsive)").addClass("img-fluid"),i.find('[component="post/parent/content"] img:not(.emoji)').each(function(){x.wrapImageInLink($(this))}))}else k.fire("action:posts.edited",t);t.topic.tags&&t.topic.tagsupdated&&Promise.all([e.e(56),e.e(63)]).then(function(){var i=[e(63)];(function(s){s.updateTopicTags([t.topic])}).apply(null,i)}).catch(e.oe),t.topic.thumbsupdated&&Promise.all([e.e(3662),e.e(47),e.e(6159)]).then(function(){var i=[e(6159)];(function(s){s.updateTopicThumbs(t.topic.tid)}).apply(null,i)}).catch(e.oe),m.removeMenu(c.get("post","pid",t.post.pid))}function D(t){!t||String(t.tid)!==String(ajaxify.data.tid)||(c.get("post","pid",t.pid).fadeOut(500,function(){$(this).remove(),v.showBottomPostBar()}),ajaxify.data.postcount-=1,m.updatePostCount(ajaxify.data.postcount),e.e(8631).then(function(){var o=[e(8631)];(function(n){n.onPostPurged(t)}).apply(null,o)}).catch(e.oe),$(`[component="post/parent"][data-parent-pid="${t.pid}"]`).remove())}function P(t){const o=c.get("post","pid",t.pid),{isAdminOrMod:n}=ajaxify.data.privileges,p=String(t.uid)===String(app.user.uid),d=n||p,r=!!t.deleted;o.length&&(o.toggleClass("deleted"),m.toggle(t.pid,r),d||(o.find('[component="post/tools"]').toggleClass("hidden",r),r?o.find('[component="post/content"]').translateText("[[topic:post-is-deleted]]"):o.find('[component="post/content"]').html(t.content)));const a=$(`[component="post/parent"][data-parent-pid="${t.pid}"]`);a.length&&!d&&a.each((i,s)=>{const u=$(s);r?u.find('[component="post/parent/content"]').translateText("[[topic:post-is-deleted]]"):u.find('[component="post/parent/content"]').html(t.content)})}function y(t){const o=$('[data-pid="'+t.post.pid+'"] [component="post/bookmark"]').filter(function(n,p){return $(p).closest("[data-pid]").attr("data-pid")===String(t.post.pid)});o.length&&(o.attr("data-bookmarked",t.isBookmarked),o.find('[component="post/bookmark/on"]').toggleClass("hidden",!t.isBookmarked),o.find('[component="post/bookmark/off"]').toggleClass("hidden",t.isBookmarked))}function S(t){const o=$('[data-pid="'+t.post.pid+'"]');o.find('[component="post/upvote"]').filter(function(n,p){return $(p).closest("[data-pid]").attr("data-pid")===String(t.post.pid)}).toggleClass("upvoted",t.upvote),o.find('[component="post/downvote"]').filter(function(n,p){return $(p).closest("[data-pid]").attr("data-pid")===String(t.post.pid)}).toggleClass("downvoted",t.downvote)}return f}).apply(C,h),g!==void 0&&(A.exports=g)}}]);
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.