"use strict";(self.webpackChunkpixelfed=self.webpackChunkpixelfed||[]).push([[399],{32232:(t,e,s)=>{s.r(e),s.d(e,{default:()=>r});vari=s(42755),o=s(88231),n=s(99247),a=s(22583);constr={components:{drawer:i.default,sidebar:o.default,"status-card":n.default,"profile-card":a.default},data:function(){return{isLoaded:!0,isLoading:!0,profile:window._sharedData.user,feed:[],popular:[],popularAccounts:[],popularLoaded:!1,breadcrumbItems:[{text:"Discover",href:"/i/web/discover"},{text:"Find Friends",active:!0}]}},mounted:function(){this.fetchConfig()},methods:{fetchConfig:function(){vart=this;axios.get("/api/pixelfed/v2/discover/meta").then((function(e){0==e.data.friends.enabled?t.$router.push("/i/web/discover"):t.fetchPopularAccounts()})).catch((function(e){t.isLoading=!1}))},fetchPopular:function(){vart=this;axios.get("/api/pixelfed/v2/discover/account-insights").then((function(e){t.popular=e.data,t.popularLoaded=!0,t.isLoading=!1})).catch((function(e){t.isLoading=!1}))},formatCount:function(t){returnApp.util.format.count(t)},timeago:function(t){returnApp.util.format.timeAgo(t)},fetchPopularAccounts:function(){vart=this;axios.get("/api/pixelfed/discover/accounts/popular").then((function(e){t.popularAccounts=e.data,t.isLoading=!1})).catch((function(e){t.isLoading=!1}))},follow:function(t){vare=this;axios.post("/api/v1/accounts/"+this.popularAccounts[t].id+"/follow").then((function(t){e.newlyFollowed++,e.$store.commit("updateRelationship",[t.data]),e.$emit("update-profile",{following_count:e.profile.following_count+1})}))},unfollow:function(t){vare=this;axios.post("/api/v1/accounts/"+this.popularAccounts[t].id+"/unfollow").then((function(t){e.newlyFollowed--,e.$store.commit("updateRelationship",[t.data]),e.$emit("update-profile",{following_count:e.profile.following_count-1})}))}}}},77366:(t,e,s)=>{s.r(e),s.d(e,{default:()=>l});vari=s(80979),o=s(26535),n=s(22583),a=s(30765),r=s.n(a);constl={props:{status:{type:Object},profile:{type:Object},useDropdownMenu:{type:Boolean,default:!1}},components:{"comment-drawer":o.default,"read-more":i.default,"profile-hover-card":n.default},data:function(){return{key:1,menuLoading:!0,sensitive:!1,showCommentDrawer:!1,isReblogging:!1,isBookmarking:!1,owner:!1,admin:!1,license:!1}},mounted:function(){vart=this;this.license=!(!this.status.media_attachments||!this.status.media_attachments.length)&&this.status.media_attachments.filter((function(t){returnt.hasOwnProperty("license")&&t.license&&t.license.hasOwnProperty("id")})).map((function(t){returnt.license}))[0],this.admin=window._sharedData.user.is_admin,this.owner=this.status.account.id==window._sharedData.user.id,this.status.reply_count&&this.autoloadComments&&setTimeout((function(){t.showCommentDrawer=!0}),1e3)},computed:{hideCounts:{get:function(){return1==this.$store.state.hideCounts}},fixedHeight:{get:function(){return1==this.$store.state.fixedHeight}},autoloadComments:{get:function(){return1==this.$store.state.autoloadComments}},newReactions:{get:function(){returnthis.$store.state.newReactions}}},watch:{status:{deep:!0,immediate:!0,handler:function(t,e){this.isBookmarking=!1}}},methods:{toggleLightbox:function(t){r()({el:t.target})},timeago:function(t){vare=App.util.format.timeAgo(t);returne.endsWith("s")||e.endsWith("m")||e.endsWith("h")?e:newIntl.DateTimeFormat(void0,{year:"numeric",month:"short",day:"numeric",hour:"numeric",minute:"numeric"}).format(newDate(t))},count:function(t){returnApp.util.format.count(t)},openMenu:function(){this.$emit("menu")},scopeIcon:function(t){switch(t){case"public":default:return"far fa-globe";case"unlisted":return"far fa-lock-open";case"private":return"far fa-lock"}},scopeTitle:function(t){switch(t){case"public":return"Visible to everyone";case"unlisted":return"Hidden from public feeds";case"private":return"Only visible to followers";default:return""}},goToPost:function(){location.pathname.split("/").pop()!=this.status.id?this.$router.push({name:"post",path:"/i/web/post/".concat(this.status.id),params:{id:this.status.id,cachedStatus:this.status,cachedProfile:this.profile}}):location.hr