PageSourceSearch

https://www.rkan.my/build/js/pages/index-f9336434.js

js rkan.my collected 2026-10-08 10:20:26 UTC 7,617 bytes, 1 lines download raw bytes

1import{_ as S,y as T,B as I,m as u,u as L,ac as p,n as M,C as g,s as _,r as h,o as r,c as b,a as s,b as a,x as l,t as m,F as w,g as c,w as v,d as A,e as f,E as y,av as F}from"../../assets/app-55c29f84.js";import{V as P,a as j,u as V}from"./VibbsList-8813591a.js";import{C as z}from"./CommentsList-c18325ff.js";import"./PostContentType-0c6943e0.js";import"./ShareOptionsMenu-314e4eb5.js";import"./PostAnalyticsModal-920b8b53.js";import"./InfoTooltip-d3a0fd4d.js";const D={props:["tab"],components:{VibbItem:P,VibbsList:j,BaseButton:T,BaseIcon:I,CommentsList:z},data(){return{currentTab:this.tab?this.tab:"",vibbId:this.$route.query.id?this.$route.query.id:0,currentPage:1,isAtTop:!0,isAtBottom:!0,show_upload_video:!1,loadingVibbDetail:!0}},mounted(){this.handleGetVibbs(),this.vibbId&&this.loadVibbInfo(this.vibbId),this.show_upload_video=this.config.ffmegEnable},unmounted(){this.unsetVibbsList(),this.unsetVibbInfo(),this.setShowVibbComment(!1)},watch:{vibbsList(){this.isAtBottom=!(this.filteredVibbs.length>0)},$route(){this.vibbId=this.$route.query.id?this.$route.query.id:0},deletedPost(){this.updateButtonState(),this.isAtBottom?this.handleScrollUp():this.handleScrollDown()}},computed:{...u(L,["user","authenticated"]),...u(p,["loadingVibbsList","vibbsList","vibbInfo","deletedPost"]),...u(M,["isMobile","config"]),...u(V,["currentVibb","showVibbComment"]),vibbMenus(){return[{name:this.$t("For you"),isShow:!0,isActive:this.currentTab==="",tab:""},{name:this.$t("Following"),isShow:!0,isActive:this.currentTab==="following",tab:"following"}]},filteredVibbs(){return this.vibbsList.filter(e=>e.id!=this.vibbId)}},methods:{...g(p,["getVibbsForYouList","getFollowingVibbsList","getVibbById","unsetVibbsList","unsetVibbInfo"]),...g(V,["setShowVibbComment"]),onScroll(e){this.updateButtonState(),e.preventDefault()},updateButtonState(){const e=this.$refs.vibbContainer;this.isAtTop=e.scrollTop===0,this.isAtBottom=e.scrollHeight-e.scrollTop===e.clientHeight},async loadVibbInfo(e){try{await this.getVibbById(e)}catch(t){this.showError(t.error)}finally{this.loadingVibbDetail=!1}},handleGetVibbs(){this.currentTab==="following"?this.getFollowingVibbsList(this.currentPage):this.getVibbsForYouList(this.currentPage)},loadMoreVibbs(e){this.currentTab==="following"?this.getFollowingVibbsList(++this.currentPage).then(t=>{t.length===0?(e.complete(),this.isAtBottom=!0):e.loaded()}):this.getVibbsForYouList(++this.currentPage).then(t=>{t.length===0?(e.complete(),this.isAtBottom=!0):e.loaded()})},handleCreateVibb(){if(!this.authenticated){this.$router.push({name:"login"});return}if(this.user){let e="vibb.allow_create";this.checkPermission(e)&&this.$router.push({name:"vibb_create"})}},handleScrollUp(){this.$refs.vibbContainer.scrollBy({top:-100})},handleScrollDown(){this.$refs.vibbContainer.scrollBy({top:100})},changeTab(e){this.currentTab=e;let t=this.$router.resolve({name:"vibb"});_(t.fullPath+(e!=""?"/"+e:"")),this.currentPage=1,this.vibbId=0,this.unsetVibbInfo(),this.handleGetVibbs()},handleBackToHome(){this.$router.push({name:"home"})},handleToggleComment(){this.setShowVibbComment(!this.showVibbComment)}}},U={class:"bg-black fixed inset-0 z-[999] px-4 pt-16 pb-4"},H={class:"absolute top-base-2 start-base-2 end-base-2 flex flex-wrap items-center justify-between gap-2 z-[1001]"},N={class:"flex-1"},q={class:"flex-3 main-content-menu lists-list flex justify-center items-center text-white"},E={class:"flex-1 flex gap-base-2 justify-center"},G={class:"flex-1 text-end"},Y={class:"flex items-center justify-center h-full"},J={class:"flex gap-base-2 px-4 py-base-2"},K={class:"text-lg font-bold flex-1"},O={class:"hidden md:flex flex-col gap-4 items-center justify-center absolute top-0 end-10 bottom-0"};function Q(e,t,R,W,n,i){const d=h("BaseIcon"),k=h("BaseButton"),C=h("VibbItem"),B=h("VibbsList"),x=h("CommentsList");return r(),b("div",U,[s("div",H,[s("div",N,[s("button",{onClick:t[0]||(t[0]=(...o)=>i.handleBackToHome&&i.handleBackToHome(...o)),class:"flex items-center justify-center bg-white text-main-color w-10 h-10 rounded-full"},[a(d,{name:"caret_left",size:"24"})])]),s("div",q,[s("div",E,[s("button",{class:l(["main-content-menu-item flex items-center px-3 py-1 cursor-pointer border-b-2",n.currentTab==""?"border-primary-color text-primary-color dark:border-dark-primary-color dark:text-dark-primary-color":"border-transparent"]),onClick:t[1]||(t[1]=o=>i.changeTab(""))},m(e.$t("For you")),3),s("button",{class:l(["main-content-menu-item flex items-center px-3 py-1 cursor-pointer border-b-2",n.currentTab=="following"?"border-primary-color text-primary-color dark:border-dark-primary-color dark:text-dark-primary-color":"border-transparent"]),onClick:t[2]||(t[2]=o=>i.changeTab("following"))},m(e.$t("Following")),3)])]),s("div",G,[n.show_upload_video?(r(),b(w,{key:0},[e.isMobile?(r(),b("button",{key:0,onClick:t[3]||(t[3]=(...o)=>i.handleCreateVibb&&i.handleCreateVibb(...o)),class:"flex items-center justify-center justify-self-end bg-white text-main-color w-10 h-10 rounded-full ms-auto"},[a(d,{name:"plus_circle",size:"24"})])):(r(),c(k,{key:1,onClick:i.handleCreateVibb},{default:v(()=>[A(m(e.$t("Create new vibb")),1)]),_:1},8,["onClick"]))],64)):f("",!0)])]),s("div",Y,[s("div",{ref:"vibbContainer",class:l(["flex items-center vibb-container w-full h-full scrollbar-hidden",{"fixed inset-0 z-10":e.isMobile}]),style:y({"overflow-y":e.showVibbComment&&e.isMobile?"hidden":"scroll"}),onScroll:t[4]||(t[4]=(...o)=>i.onScroll&&i.onScroll(...o))},[n.vibbId?(r(),b(w,{key:0},[e.vibbInfo?(r(),c(C,{key:0,item:e.vibbInfo},null,8,["item"])):(r(),b("div",{key:1,class:l(["vibb-wrapper min-h-full w-full",e.isMobile?"py-0":"py-2"])},[s("div",{class:l(["h-full relative mx-auto bg-web-wash dark:bg-dark-web-wash",{"rounded-md":!e.isMobile}]),style:y({width:e.isMobile?"100%":"calc(0.5625 * (100vh - 6rem))"})}
1,null,6)],2))],64)):f("",!0),(r(),c(B,{key:n.currentTab,loading:e.loadingVibbsList,"vibbs-list":i.filteredVibbs,onLoadMore:i.loadMoreVibbs},null,8,["loading","vibbs-list","onLoadMore"]))],38),a(F,{name:e.isMobile?"slide-up":"slide-left"},{default:v(()=>[e.showVibbComment?(r(),b("div",{key:0,class:l(["flex flex-col bg-white w-full rounded-md overflow-hidden z-10 absolute dark:bg-slate-800",e.isMobile?"bottom-0 start-0 end-0 max-h-[70vh]":"top-[4.5rem] bottom-6 end-40 max-w-md"])},[s("div",J,[s("h3",K,m(e.$filters.numberShortener(e.currentVibb.comment_count,e.$t("[number] comment"),e.$t("[number] comments"))),1),s("button",{onClick:t[5]||(t[5]=(...o)=>i.handleToggleComment&&i.handleToggleComment(...o))},[a(d,{name:"close"})])]),a(x,{item:e.currentVibb,emptyMessage:e.$t("No comments"),"has-menu-footer":!1,"comments-list-class":"overflow-auto scrollbar-hidden scroll-smooth"},null,8,["item","emptyMessage"])],2)):f("",!0)]),_:1},8,["name"]),s("div",O,[s("button",{class:l(["w-12 h-12 flex items-center justify-center bg-white shadow-md rounded-full relative hover:bg-hover dark:bg-slate-800 dark:text-white dark:shadow-slate-600 transition-all duration-300 ease-linear",n.isAtTop?"opacity-0 top-[64px]":"opacity-100 top-0 z-10"]),onClick:t[6]||(t[6]=(...o)=>i.handleScrollUp&&i.handleScrollUp(...o))},[a(d,{name:"arrow_up"})],2),s("button",{class:l(["w-12 h-12 flex items-center justify-center bg-white shadow-md rounded-full relative hover:bg-hover dark:bg-slate-800 dark:text-white dark:shadow-slate-600 transition-all duration-300 ease-linear",n.isAtBottom?"opacity-0 -top-[64px]":"opacity-100 top-0 z-10"]),onClick:t[7]||(t[7]=(...o)=>i.handleScrollDown&&i.handleScrollDown(...o))},[a(d,{name:"arrow_down"})],2)])])])}const oe=S(D,[["render",Q]]);export{oe as default};

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.