-
Notifications
You must be signed in to change notification settings - Fork 66
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: GitHub <noreply@github.com>
- Loading branch information
1 parent
32b907a
commit d0cf327
Showing
47 changed files
with
2,624 additions
and
1,303 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
(function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode(".activity[data-v-7e59872d]{display:flex;flex-direction:column;overflow:hidden;height:100%}.activity__actions[data-v-7e59872d]{display:flex;flex-direction:column;width:100%}.activity__list[data-v-7e59872d]{flex-grow:1;overflow:scroll}.activity__empty-content[data-v-7e59872d]{height:100%}[data-v-7e59872d] .empty-content__icon span{background-size:64px;width:64px;height:64px}")),document.head.appendChild(e)}}catch(t){console.error("vite-plugin-css-injected-by-js",t)}})(); | ||
/*! third party licenses: js/vendor.LICENSE.txt */ | ||
import{b as c,d as l,v as u,f as v}from"./NcCheckboxRadioSwitch-l-6YVD9V-78BKpMCq.chunk.mjs";import{d as f,e as p,o as d,g as y,k as g,t as o}from"./index-CuJjSc4s.chunk.mjs";import{a as m,N as h,b as _,A as b}from"./Activity-B-sYiPXI.chunk.mjs";import{g as A,a as I,b as r}from"./api-CF78xqem.chunk.mjs";import{l as S}from"./logger-CK4DU0SJ.chunk.mjs";import{l as P}from"./activity-sidebar.mjs";import"./_commonjsHelpers-BdswosdL.chunk.mjs";const x=f({__name:"ActivitySidebarPlugin",props:{plugin:null,fileInfo:null},emits:["reload-activities"],setup(t,{emit:i}){const s=t,a=p();return d(()=>{var n;return s.plugin.mount(a.value,{context:(n=y())==null?void 0:n.proxy,fileInfo:s.fileInfo,reload:()=>i("reload-activities")})}),g(()=>s.plugin.unmount()),{__sfc:!0,props:s,emit:i,attachTarget:a}}});var C=function(){var t=this,i=t._self._c;return t._self._setupProxy,i("div",{ref:"attachTarget"})},N=[],w=c(x,C,N,!1,null,null);const k=w.exports,E={name:"ActivityTab",components:{Activity:b,NcEmptyContent:_,NcIconSvgWrapper:h,NcLoadingIcon:v,ActivitySidebarPlugin:k},data(){return{error:"",loading:!0,fileInfo:null,activities:[],lightningBoltSVG:P,sidebarPlugins:[]}},mounted(){this.sidebarPlugins=r()},methods:{async update(t){this.sidebarPlugins=[];let i=r();i.length>0&&this.$nextTick(()=>{this.sidebarPlugins=i}),this.fileInfo=t,this.resetState(),await this.getActivities()},async getActivities(){try{this.loading=!0;const t=await this.processActivities(await this.loadRealActivities()),i=await I({fileInfo:this.fileInfo});this.activities=[...t,...i].sort((s,a)=>a.timestamp-s.timestamp)}catch(t){this.error=o("activity","Unable to load the activity list"),console.error("Error loading the activity list",t)}finally{this.loading=!1}},resetState(){this.loading=!0,this.error="",this.activities=[]},async loadRealActivities(){try{const{data:t}=await l.get(u("apps/activity/api/v2/activity/filter"),{params:{format:"json",object_type:"files",object_id:this.fileInfo.id}});return t.ocs.data}catch(t){if(t.response!==void 0&&t.response.status===304)return[];throw e}},processActivities(t){t=t.map(s=>new m(s)),S.debug("Processed ".concat(t.length," activity(ies)"),{activities:t,fileInfo:this.fileInfo});const i=A();return t.filter(s=>!i||i.every(a=>a(s)))},t:o}};var T=function(){var t=this,i=t._self._c;return i("div",{staticClass:"activity",class:{"icon-loading":t.loading}},[t.error?i("NcEmptyContent",{attrs:{name:t.error},scopedSlots:t._u([{key:"icon",fn:function(){return[i("NcIconSvgWrapper",{attrs:{svg:t.lightningBoltSVG}})]},proxy:!0}],null,!1,63559581)}):[t.sidebarPlugins.length>0?i("div",{staticClass:"activity__actions"},t._l(t.sidebarPlugins,function(s,a){return i("ActivitySidebarPlugin",{key:a,attrs:{plugin:s,"file-info":t.fileInfo},on:{"reload-activities":function(n){return t.getActivities()}}})}),1):t._e(),t.loading?i("NcEmptyContent",{staticClass:"activity__empty-content",attrs:{name:t.t("activity","Loading activities")},scopedSlots:t._u([{key:"icon",fn:function(){return[i("NcLoadingIcon")]},proxy:!0}],null,!1,3085876643)}):t.activities.length===0?i("NcEmptyContent",{staticClass:"activity__empty-content",attrs:{name:t.t("activity","No activity yet")},scopedSlots:t._u([{key:"icon",fn:function(){return[i("span",{staticClass:"icon-activity"})]},proxy:!0}])}):i("ul",{staticClass:"activity__list"},t._l(t.activities,function(s){return i("Activity",{key:s.id,attrs:{activity:s,"show-previews":!1},on:{reload:function(a){return t.getActivities()}}})}),1)]],2)},j=[],L=c(E,T,j,!1,null,"7e59872d");const U=L.exports;export{U as default}; |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.