From 1b067aab42f77f19214ce4fad272a7a6f9c5b736 Mon Sep 17 00:00:00 2001 From: Edward Ly Date: Thu, 18 Sep 2025 15:32:26 -0700 Subject: [PATCH 1/2] fix(comments): expand long comment on click This is a temporary fix that only applies while the server is still using Vue 2.x (or `@nextcloud/vue` 8.x). Once migrated to Vue 3.x, this fix may be reverted. Signed-off-by: Edward Ly --- apps/comments/src/components/Comment.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/comments/src/components/Comment.vue b/apps/comments/src/components/Comment.vue index 8c7bf862781..970bb444f42 100644 --- a/apps/comments/src/components/Comment.vue +++ b/apps/comments/src/components/Comment.vue @@ -95,7 +95,7 @@ :class="{'comment__message--expanded': expanded}" :text="richContent.message" :arguments="richContent.mentions" - @click="onExpand" /> + @click.native="onExpand" /> From 0e79e6f101200ccf6b24d8ec8293cdeb5cc4429e Mon Sep 17 00:00:00 2001 From: nextcloud-command Date: Sun, 21 Sep 2025 16:02:49 +0000 Subject: [PATCH 2/2] chore(assets): Recompile assets Signed-off-by: nextcloud-command --- dist/7462-7462.js | 4 ++-- dist/7462-7462.js.map | 2 +- dist/comments-comments-app.js | 4 ++-- dist/comments-comments-app.js.map | 2 +- dist/comments-comments-tab.js | 4 ++-- dist/comments-comments-tab.js.map | 2 +- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/dist/7462-7462.js b/dist/7462-7462.js index a8c950aaffe..186ac17d94d 100644 --- a/dist/7462-7462.js +++ b/dist/7462-7462.js @@ -1,2 +1,2 @@ -"use strict";(self.webpackChunknextcloud=self.webpackChunknextcloud||[]).push([[7462],{10396:(e,n,i)=>{i.d(n,{A:()=>l});var o=i(85168),s=i(70395),a=i(80486),r=i(10767),c=i(65899),d=i(36564),m=i(96689);const l={props:{id:{type:Number,default:null},message:{type:String,default:""},resourceId:{type:[String,Number],required:!0},resourceType:{type:String,default:"files"}},data:()=>({deleted:!1,editing:!1,loading:!1}),computed:{...(0,c.n2)(d.h)},methods:{onEdit(){this.editing=!0},onEditCancel(){this.editing=!1,this.updateLocalMessage(this.message)},async onEditComment(e){this.loading=!0;try{await(0,r.A)(this.resourceType,this.resourceId,this.id,e),m.A.debug("Comment edited",{resourceType:this.resourceType,resourceId:this.resourceId,id:this.id,message:e}),this.$emit("update:message",e),this.editing=!1}catch(e){(0,o.Qg)(t("comments","An error occurred while trying to edit the comment")),console.error(e)}finally{this.loading=!1}},onDeleteWithUndo(){this.$emit("delete"),this.deleted=!0,this.deletedCommentLimboStore.addId(this.id);const e=setTimeout(this.onDelete,o.Br);(0,o._h)(t("comments","Comment deleted"),()=>{clearTimeout(e),this.deleted=!1,this.deletedCommentLimboStore.removeId(this.id)})},async onDelete(){try{await(0,a.A)(this.resourceType,this.resourceId,this.id),m.A.debug("Comment deleted",{resourceType:this.resourceType,resourceId:this.resourceId,id:this.id}),this.$emit("delete",this.id)}catch(e){(0,o.Qg)(t("comments","An error occurred while trying to delete the comment")),console.error(e),this.deleted=!1,this.deletedCommentLimboStore.removeId(this.id)}},async onNewComment(e){this.loading=!0;try{const t=await(0,s.A)(this.resourceType,this.resourceId,e);m.A.debug("New comment posted",{resourceType:this.resourceType,resourceId:this.resourceId,newComment:t}),this.$emit("new",t),this.$emit("update:message",""),this.localMessage=""}catch(e){(0,o.Qg)(t("comments","An error occurred while trying to create the comment")),console.error(e)}finally{this.loading=!1}}}}},10767:(t,e,n)=>{n.d(e,{A:()=>o});var i=n(35550);async function o(t,e,n,o){const s=["",t,e,n].join("/");return await i.A.customRequest(s,Object.assign({method:"PROPPATCH",data:`\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t${o}\n\t\t\t\t\n\t\t\t\n\t\t\t`}))}},29369:(t,e,n)=>{n.d(e,{A:()=>v});var i=n(21777),o=n(53334),s=n(57505),a=n(24764),r=n(15502),c=n(41944),d=n(74095),m=n(4604),l=n(88289),A=n(77764),p=n(33691),u=n(66001),h=n(37793),C=n(16502),g=n(10396),_=n(65899),y=n(36564);const v={name:"Comment",components:{IconArrowRight:p.A,IconClose:u.A,IconTrashCanOutline:h.A,IconPencilOutline:C.A,NcActionButton:s.A,NcActions:a.A,NcActionSeparator:r.A,NcAvatar:c.A,NcButton:d.A,NcDateTime:m.A,NcLoadingIcon:l.A,NcRichContenteditable:()=>Promise.all([n.e(4208),n.e(7838),n.e(5258)]).then(n.bind(n,95528)),NcRichText:()=>Promise.all([n.e(4208),n.e(7838),n.e(4508)]).then(n.bind(n,64508))},mixins:[g.A],inheritAttrs:!1,props:{actorDisplayName:{type:String,required:!0},actorId:{type:String,required:!0},creationDateTime:{type:String,default:null},editor:{type:Boolean,default:!1},autoComplete:{type:Function,required:!0},userData:{type:Object,default:()=>({})},tag:{type:String,default:"div"}},data:()=>({expanded:!1,localMessage:"",submitted:!1}),computed:{...(0,_.n2)(y.h),isOwnComment(){return(0,i.HW)().uid===this.actorId},richContent(){const t={};let e=this.localMessage;return Object.keys(this.userData).forEach((n,i)=>{const o=`mention-${i}`,s=new RegExp(`@${n}|@"${n}"`,"g");e=e.replace(s,`{${o}}`),t[o]={component:A.A,props:{user:n,displayName:this.userData[n].label,primary:this.userData[n].primary}}}),{mentions:t,message:e}},isEmptyMessage(){return!this.localMessage||""===this.localMessage.trim()},timestamp(){return Date.parse(this.creationDateTime)},isLimbo(){return this.deletedCommentLimboStore.checkForId(this.id)}},watch:{message(t){this.updateLocalMessage(t)}},beforeMount(){this.updateLocalMessage(this.message)},methods:{t:o.Tl,updateLocalMessage(t){this.localMessage=t.toString(),this.submitted=!1},onSubmit(){if(""!==this.localMessage.trim())return this.editor?(this.onNewComment(this.localMessage.trim()),void this.$nextTick(()=>{this.$refs.editor.$el.focus()})):void this.onEditComment(this.localMessage.trim())},onExpand(){this.expanded=!0}}}},36564:(t,e,n)=>{n.d(e,{h:()=>i});const i=(0,n(65899).nY)("deletedCommentLimbo",{state:()=>({idsInLimbo:[]}),actions:{addId(t){this.idsInLimbo.push(t)},removeId(t){const e=this.idsInLimbo.indexOf(t);e>-1&&this.idsInLimbo.splice(e,1)},checkForId(t){this.idsInLimbo.includes(t)}}})},36768:(t,e,n)=>{n.d(e,{A:()=>r});var i=n(71354),o=n.n(i),s=n(76314),a=n.n(s)()(o());a.push([t.id,".comment[data-v-54060d57]{display:flex;gap:8px;padding:5px 10px}.comment__side[data-v-54060d57]{display:flex;align-items:flex-start;padding-top:6px}.comment__body[data-v-54060d57]{display:flex;flex-grow:1;flex-direction:column;container-type:inline-size}.comment__header[data-v-54060d57]{display:flex;align-items:center;min-height:44px}.comment__actions[data-v-54060d57]{margin-inline-start:10px !important}.comment__author[data-v-54060d57]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:var(--color-text-maxcontrast)}.comment_loading[data-v-54060d57],.comment__timestamp[data-v-54060d57]{margin-inline-start:auto;text-align:end;white-space:nowrap;color:var(--color-text-maxcontrast)}.comment__editor-group[data-v-54060d57]{position:relative}.comment__editor-description[data-v-54060d57]{color:var(--color-text-maxcontrast);padding-block:var(--default-grid-baseline)}.comment__submit[data-v-54060d57]{position:absolute !important;bottom:5px;inset-inline-end:0}.comment__message[data-v-54060d57]{white-space:pre-wrap;word-break:normal;max-height:70px;overflow:hidden;margin-top:-6px}.comment__message--expanded[data-v-54060d57]{max-height:none;overflow:visible}.rich-contenteditable__input[data-v-54060d57]{min-height:44px;margin:0;padding:10px}","",{version:3,sources:["webpack://./apps/comments/src/components/Comment.vue"],names:[],mappings:"AAKA,0BACC,YAAA,CACA,OAAA,CACA,gBAAA,CAEA,gCACC,YAAA,CACA,sBAAA,CACA,eAAA,CAGD,gCACC,YAAA,CACA,WAAA,CACA,qBAAA,CACA,0BAAA,CAGD,kCACC,YAAA,CACA,kBAAA,CACA,eAAA,CAGD,mCACC,mCAAA,CAGD,kCACC,eAAA,CACA,kBAAA,CACA,sBAAA,CACA,mCAAA,CAGD,uEAEC,wBAAA,CACA,cAAA,CACA,kBAAA,CACA,mCAAA,CAGD,wCACC,iBAAA,CAGD,8CACC,mCAAA,CACA,0CAAA,CAGD,kCACC,4BAAA,CACA,UAAA,CACA,kBAAA,CAGD,mCACC,oBAAA,CACA,iBAAA,CACA,eAAA,CACA,eAAA,CACA,eAAA,CACA,6CACC,eAAA,CACA,gBAAA,CAKH,8CACC,eAAA,CACA,QAAA,CACA,YA5EiB",sourcesContent:['\n@use "sass:math";\n\n$comment-padding: 10px;\n\n.comment {\n\tdisplay: flex;\n\tgap: 8px;\n\tpadding: 5px $comment-padding;\n\n\t&__side {\n\t\tdisplay: flex;\n\t\talign-items: flex-start;\n\t\tpadding-top: 6px;\n\t}\n\n\t&__body {\n\t\tdisplay: flex;\n\t\tflex-grow: 1;\n\t\tflex-direction: column;\n\t\tcontainer-type: inline-size;\n\t}\n\n\t&__header {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t\tmin-height: 44px;\n\t}\n\n\t&__actions {\n\t\tmargin-inline-start: $comment-padding !important;\n\t}\n\n\t&__author {\n\t\toverflow: hidden;\n\t\twhite-space: nowrap;\n\t\ttext-overflow: ellipsis;\n\t\tcolor: var(--color-text-maxcontrast);\n\t}\n\n\t&_loading,\n\t&__timestamp {\n\t\tmargin-inline-start: auto;\n\t\ttext-align: end;\n\t\twhite-space: nowrap;\n\t\tcolor: var(--color-text-maxcontrast);\n\t}\n\n\t&__editor-group {\n\t\tposition: relative;\n\t}\n\n\t&__editor-description {\n\t\tcolor: var(--color-text-maxcontrast);\n\t\tpadding-block: var(--default-grid-baseline);\n\t}\n\n\t&__submit {\n\t\tposition: absolute !important;\n\t\tbottom: 5px;\n\t\tinset-inline-end: 0;\n\t}\n\n\t&__message {\n\t\twhite-space: pre-wrap;\n\t\tword-break: normal;\n\t\tmax-height: 70px;\n\t\toverflow: hidden;\n\t\tmargin-top: -6px;\n\t\t&--expanded {\n\t\t\tmax-height: none;\n\t\t\toverflow: visible;\n\t\t}\n\t}\n}\n\n.rich-contenteditable__input {\n\tmin-height: 44px;\n\tmargin: 0;\n\tpadding: $comment-padding;\n}\n\n'],sourceRoot:""}]);const r=a},51195:(t,e,n)=>{function i(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;const n=new DOMParser;let i=t;for(let t=0;ti})},54416:(t,e,n)=>{n.d(e,{A:()=>i});const i=n(29369).A},59834:(t,e,n)=>{n.d(e,{X:()=>i,Y:()=>o});var i=function(){var t=this,e=t._self._c;return e(t.tag,{directives:[{name:"show",rawName:"v-show",value:!t.deleted&&!t.isLimbo,expression:"!deleted && !isLimbo"}],tag:"component",staticClass:"comment",class:{"comment--loading":t.loading}},[e("div",{staticClass:"comment__side"},[e("NcAvatar",{staticClass:"comment__avatar",attrs:{"display-name":t.actorDisplayName,user:t.actorId,size:32}})],1),t._v(" "),e("div",{staticClass:"comment__body"},[e("div",{staticClass:"comment__header"},[e("span",{staticClass:"comment__author"},[t._v(t._s(t.actorDisplayName))]),t._v(" "),t.isOwnComment&&t.id&&!t.loading?e("NcActions",{staticClass:"comment__actions"},[t.editing?e("NcActionButton",{on:{click:t.onEditCancel},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconClose",{attrs:{size:20}})]},proxy:!0}],null,!1,2888946197)},[t._v("\n\t\t\t\t\t"+t._s(t.t("comments","Cancel edit"))+"\n\t\t\t\t")]):[e("NcActionButton",{attrs:{"close-after-click":""},on:{click:t.onEdit},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconPencilOutline",{attrs:{size:20}})]},proxy:!0}],null,!1,3345211262)},[t._v("\n\t\t\t\t\t\t"+t._s(t.t("comments","Edit comment"))+"\n\t\t\t\t\t")]),t._v(" "),e("NcActionSeparator"),t._v(" "),e("NcActionButton",{attrs:{"close-after-click":""},on:{click:t.onDeleteWithUndo},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconTrashCanOutline",{attrs:{size:20}})]},proxy:!0}],null,!1,1034796883)},[t._v("\n\t\t\t\t\t\t"+t._s(t.t("comments","Delete comment"))+"\n\t\t\t\t\t")])]],2):t._e(),t._v(" "),t.id&&t.loading?e("div",{staticClass:"comment_loading icon-loading-small"}):t.creationDateTime?e("NcDateTime",{staticClass:"comment__timestamp",attrs:{timestamp:t.timestamp,"ignore-seconds":!0}}):t._e()],1),t._v(" "),t.editor||t.editing?e("form",{staticClass:"comment__editor",on:{submit:function(t){t.preventDefault()}}},[e("div",{staticClass:"comment__editor-group"},[e("NcRichContenteditable",{ref:"editor",attrs:{"auto-complete":t.autoComplete,contenteditable:!t.loading,label:t.editor?t.t("comments","New comment"):t.t("comments","Edit comment"),placeholder:t.t("comments","Write a comment …"),value:t.localMessage,"user-data":t.userData,"aria-describedby":"tab-comments__editor-description"},on:{"update:value":t.updateLocalMessage,submit:t.onSubmit}}),t._v(" "),e("div",{staticClass:"comment__submit"},[e("NcButton",{attrs:{type:"tertiary-no-background","native-type":"submit","aria-label":t.t("comments","Post comment"),disabled:t.isEmptyMessage},on:{click:t.onSubmit},scopedSlots:t._u([{key:"icon",fn:function(){return[t.loading?e("NcLoadingIcon"):e("IconArrowRight",{attrs:{size:20}})]},proxy:!0}],null,!1,758946661)})],1)],1),t._v(" "),e("div",{staticClass:"comment__editor-description",attrs:{id:"tab-comments__editor-description"}},[t._v("\n\t\t\t\t"+t._s(t.t("comments","@ for mentions, : for emoji, / for smart picker"))+"\n\t\t\t")])]):e("NcRichText",{staticClass:"comment__message",class:{"comment__message--expanded":t.expanded},attrs:{text:t.richContent.message,arguments:t.richContent.mentions},on:{click:t.onExpand}})],1)])},o=[]},65463:(t,e,n)=>{n.d(e,{A:()=>s});var i=n(59834),o=n(54416);n(75070);const s=(0,n(14486).A)(o.A,i.X,i.Y,!1,null,"54060d57",null).exports},70395:(t,e,n)=>{n.d(e,{A:()=>c});var i=n(21777),o=n(17003),s=n(51195),a=n(65043),r=n(35550);async function c(t,e,n){const c=["",t,e].join("/"),d=await a.Ay.post((0,o.e)()+c,{actorDisplayName:(0,i.HW)().displayName,actorId:(0,i.HW)().uid,actorType:"users",creationDateTime:(new Date).toUTCString(),message:n,objectType:t,verb:"comment"}),m=c+"/"+parseInt(d.headers["content-location"].split("/").pop()),l=await r.A.stat(m,{details:!0}),A=l.data.props;return A.actorDisplayName=(0,s.j)(A.actorDisplayName,2),A.message=(0,s.j)(A.message,2),l.data}},70452:(t,e,n)=>{n.d(e,{A:()=>r});var i=n(65043),o=n(21777),s=n(81222),a=n(63814);const r=(0,n(85471).pM)({props:{resourceId:{type:Number,required:!0},resourceType:{type:String,default:"files"}},data:()=>({editorData:{actorDisplayName:(0,o.HW)().displayName,actorId:(0,o.HW)().uid,key:"editor"},userData:{}}),methods:{async autoComplete(t,e){const{data:n}=await i.Ay.get((0,a.KT)("core/autocomplete/get"),{params:{search:t,itemType:"files",itemId:this.resourceId,sorter:"commenters|share-recipients",limit:(0,s.C)("comments","maxAutoCompleteResults")}});return n.ocs.data.forEach(t=>{this.userData[t.id]=t}),e(Object.values(this.userData))},genMentionsData(t){return Object.values(t).flat().forEach(t=>{this.userData[t.mentionId]={icon:"icon-user",id:t.mentionId,label:t.mentionDisplayName,source:"users",primary:(0,o.HW)()?.uid===t.mentionId}}),this.userData}}})},75070:(t,e,n)=>{n(86635)},80486:(t,e,n)=>{n.d(e,{A:()=>o});var i=n(35550);async function o(t,e,n){const o=["",t,e,n].join("/");await i.A.deleteFile(o)}},86635:(t,e,n)=>{var i=n(85072),o=n.n(i),s=n(97825),a=n.n(s),r=n(77659),c=n.n(r),d=n(55056),m=n.n(d),l=n(10540),A=n.n(l),p=n(41113),u=n.n(p),h=n(36768),C={};C.styleTagTransform=u(),C.setAttributes=m(),C.insert=c().bind(null,"head"),C.domAPI=a(),C.insertStyleElement=A(),o()(h.A,C),h.A&&h.A.locals&&h.A.locals}}]); -//# sourceMappingURL=7462-7462.js.map?v=df273d28c362a92d76d7 \ No newline at end of file +"use strict";(self.webpackChunknextcloud=self.webpackChunknextcloud||[]).push([[7462],{1554:(t,e,n)=>{n.d(e,{A:()=>r});var i=n(71354),o=n.n(i),a=n(76314),s=n.n(a)()(o());s.push([t.id,".comment[data-v-3cab0376]{display:flex;gap:8px;padding:5px 10px}.comment__side[data-v-3cab0376]{display:flex;align-items:flex-start;padding-top:6px}.comment__body[data-v-3cab0376]{display:flex;flex-grow:1;flex-direction:column;container-type:inline-size}.comment__header[data-v-3cab0376]{display:flex;align-items:center;min-height:44px}.comment__actions[data-v-3cab0376]{margin-inline-start:10px !important}.comment__author[data-v-3cab0376]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:var(--color-text-maxcontrast)}.comment_loading[data-v-3cab0376],.comment__timestamp[data-v-3cab0376]{margin-inline-start:auto;text-align:end;white-space:nowrap;color:var(--color-text-maxcontrast)}.comment__editor-group[data-v-3cab0376]{position:relative}.comment__editor-description[data-v-3cab0376]{color:var(--color-text-maxcontrast);padding-block:var(--default-grid-baseline)}.comment__submit[data-v-3cab0376]{position:absolute !important;bottom:5px;inset-inline-end:0}.comment__message[data-v-3cab0376]{white-space:pre-wrap;word-break:normal;max-height:70px;overflow:hidden;margin-top:-6px}.comment__message--expanded[data-v-3cab0376]{max-height:none;overflow:visible}.rich-contenteditable__input[data-v-3cab0376]{min-height:44px;margin:0;padding:10px}","",{version:3,sources:["webpack://./apps/comments/src/components/Comment.vue"],names:[],mappings:"AAKA,0BACC,YAAA,CACA,OAAA,CACA,gBAAA,CAEA,gCACC,YAAA,CACA,sBAAA,CACA,eAAA,CAGD,gCACC,YAAA,CACA,WAAA,CACA,qBAAA,CACA,0BAAA,CAGD,kCACC,YAAA,CACA,kBAAA,CACA,eAAA,CAGD,mCACC,mCAAA,CAGD,kCACC,eAAA,CACA,kBAAA,CACA,sBAAA,CACA,mCAAA,CAGD,uEAEC,wBAAA,CACA,cAAA,CACA,kBAAA,CACA,mCAAA,CAGD,wCACC,iBAAA,CAGD,8CACC,mCAAA,CACA,0CAAA,CAGD,kCACC,4BAAA,CACA,UAAA,CACA,kBAAA,CAGD,mCACC,oBAAA,CACA,iBAAA,CACA,eAAA,CACA,eAAA,CACA,eAAA,CACA,6CACC,eAAA,CACA,gBAAA,CAKH,8CACC,eAAA,CACA,QAAA,CACA,YA5EiB",sourcesContent:['\n@use "sass:math";\n\n$comment-padding: 10px;\n\n.comment {\n\tdisplay: flex;\n\tgap: 8px;\n\tpadding: 5px $comment-padding;\n\n\t&__side {\n\t\tdisplay: flex;\n\t\talign-items: flex-start;\n\t\tpadding-top: 6px;\n\t}\n\n\t&__body {\n\t\tdisplay: flex;\n\t\tflex-grow: 1;\n\t\tflex-direction: column;\n\t\tcontainer-type: inline-size;\n\t}\n\n\t&__header {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t\tmin-height: 44px;\n\t}\n\n\t&__actions {\n\t\tmargin-inline-start: $comment-padding !important;\n\t}\n\n\t&__author {\n\t\toverflow: hidden;\n\t\twhite-space: nowrap;\n\t\ttext-overflow: ellipsis;\n\t\tcolor: var(--color-text-maxcontrast);\n\t}\n\n\t&_loading,\n\t&__timestamp {\n\t\tmargin-inline-start: auto;\n\t\ttext-align: end;\n\t\twhite-space: nowrap;\n\t\tcolor: var(--color-text-maxcontrast);\n\t}\n\n\t&__editor-group {\n\t\tposition: relative;\n\t}\n\n\t&__editor-description {\n\t\tcolor: var(--color-text-maxcontrast);\n\t\tpadding-block: var(--default-grid-baseline);\n\t}\n\n\t&__submit {\n\t\tposition: absolute !important;\n\t\tbottom: 5px;\n\t\tinset-inline-end: 0;\n\t}\n\n\t&__message {\n\t\twhite-space: pre-wrap;\n\t\tword-break: normal;\n\t\tmax-height: 70px;\n\t\toverflow: hidden;\n\t\tmargin-top: -6px;\n\t\t&--expanded {\n\t\t\tmax-height: none;\n\t\t\toverflow: visible;\n\t\t}\n\t}\n}\n\n.rich-contenteditable__input {\n\tmin-height: 44px;\n\tmargin: 0;\n\tpadding: $comment-padding;\n}\n\n'],sourceRoot:""}]);const r=s},10396:(e,n,i)=>{i.d(n,{A:()=>l});var o=i(85168),a=i(70395),s=i(80486),r=i(10767),c=i(65899),m=i(36564),d=i(96689);const l={props:{id:{type:Number,default:null},message:{type:String,default:""},resourceId:{type:[String,Number],required:!0},resourceType:{type:String,default:"files"}},data:()=>({deleted:!1,editing:!1,loading:!1}),computed:{...(0,c.n2)(m.h)},methods:{onEdit(){this.editing=!0},onEditCancel(){this.editing=!1,this.updateLocalMessage(this.message)},async onEditComment(e){this.loading=!0;try{await(0,r.A)(this.resourceType,this.resourceId,this.id,e),d.A.debug("Comment edited",{resourceType:this.resourceType,resourceId:this.resourceId,id:this.id,message:e}),this.$emit("update:message",e),this.editing=!1}catch(e){(0,o.Qg)(t("comments","An error occurred while trying to edit the comment")),console.error(e)}finally{this.loading=!1}},onDeleteWithUndo(){this.$emit("delete"),this.deleted=!0,this.deletedCommentLimboStore.addId(this.id);const e=setTimeout(this.onDelete,o.Br);(0,o._h)(t("comments","Comment deleted"),()=>{clearTimeout(e),this.deleted=!1,this.deletedCommentLimboStore.removeId(this.id)})},async onDelete(){try{await(0,s.A)(this.resourceType,this.resourceId,this.id),d.A.debug("Comment deleted",{resourceType:this.resourceType,resourceId:this.resourceId,id:this.id}),this.$emit("delete",this.id)}catch(e){(0,o.Qg)(t("comments","An error occurred while trying to delete the comment")),console.error(e),this.deleted=!1,this.deletedCommentLimboStore.removeId(this.id)}},async onNewComment(e){this.loading=!0;try{const t=await(0,a.A)(this.resourceType,this.resourceId,e);d.A.debug("New comment posted",{resourceType:this.resourceType,resourceId:this.resourceId,newComment:t}),this.$emit("new",t),this.$emit("update:message",""),this.localMessage=""}catch(e){(0,o.Qg)(t("comments","An error occurred while trying to create the comment")),console.error(e)}finally{this.loading=!1}}}}},10767:(t,e,n)=>{n.d(e,{A:()=>o});var i=n(35550);async function o(t,e,n,o){const a=["",t,e,n].join("/");return await i.A.customRequest(a,Object.assign({method:"PROPPATCH",data:`\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t${o}\n\t\t\t\t\n\t\t\t\n\t\t\t`}))}},29369:(t,e,n)=>{n.d(e,{A:()=>b});var i=n(21777),o=n(53334),a=n(57505),s=n(24764),r=n(15502),c=n(41944),m=n(74095),d=n(4604),l=n(88289),A=n(77764),p=n(33691),u=n(66001),h=n(37793),C=n(16502),g=n(10396),_=n(65899),y=n(36564);const b={name:"Comment",components:{IconArrowRight:p.A,IconClose:u.A,IconTrashCanOutline:h.A,IconPencilOutline:C.A,NcActionButton:a.A,NcActions:s.A,NcActionSeparator:r.A,NcAvatar:c.A,NcButton:m.A,NcDateTime:d.A,NcLoadingIcon:l.A,NcRichContenteditable:()=>Promise.all([n.e(4208),n.e(7838),n.e(5258)]).then(n.bind(n,95528)),NcRichText:()=>Promise.all([n.e(4208),n.e(7838),n.e(4508)]).then(n.bind(n,64508))},mixins:[g.A],inheritAttrs:!1,props:{actorDisplayName:{type:String,required:!0},actorId:{type:String,required:!0},creationDateTime:{type:String,default:null},editor:{type:Boolean,default:!1},autoComplete:{type:Function,required:!0},userData:{type:Object,default:()=>({})},tag:{type:String,default:"div"}},data:()=>({expanded:!1,localMessage:"",submitted:!1}),computed:{...(0,_.n2)(y.h),isOwnComment(){return(0,i.HW)().uid===this.actorId},richContent(){const t={};let e=this.localMessage;return Object.keys(this.userData).forEach((n,i)=>{const o=`mention-${i}`,a=new RegExp(`@${n}|@"${n}"`,"g");e=e.replace(a,`{${o}}`),t[o]={component:A.A,props:{user:n,displayName:this.userData[n].label,primary:this.userData[n].primary}}}),{mentions:t,message:e}},isEmptyMessage(){return!this.localMessage||""===this.localMessage.trim()},timestamp(){return Date.parse(this.creationDateTime)},isLimbo(){return this.deletedCommentLimboStore.checkForId(this.id)}},watch:{message(t){this.updateLocalMessage(t)}},beforeMount(){this.updateLocalMessage(this.message)},methods:{t:o.Tl,updateLocalMessage(t){this.localMessage=t.toString(),this.submitted=!1},onSubmit(){if(""!==this.localMessage.trim())return this.editor?(this.onNewComment(this.localMessage.trim()),void this.$nextTick(()=>{this.$refs.editor.$el.focus()})):void this.onEditComment(this.localMessage.trim())},onExpand(){this.expanded=!0}}}},36564:(t,e,n)=>{n.d(e,{h:()=>i});const i=(0,n(65899).nY)("deletedCommentLimbo",{state:()=>({idsInLimbo:[]}),actions:{addId(t){this.idsInLimbo.push(t)},removeId(t){const e=this.idsInLimbo.indexOf(t);e>-1&&this.idsInLimbo.splice(e,1)},checkForId(t){this.idsInLimbo.includes(t)}}})},37009:(t,e,n)=>{var i=n(85072),o=n.n(i),a=n(97825),s=n.n(a),r=n(77659),c=n.n(r),m=n(55056),d=n.n(m),l=n(10540),A=n.n(l),p=n(41113),u=n.n(p),h=n(1554),C={};C.styleTagTransform=u(),C.setAttributes=d(),C.insert=c().bind(null,"head"),C.domAPI=s(),C.insertStyleElement=A(),o()(h.A,C),h.A&&h.A.locals&&h.A.locals},40296:(t,e,n)=>{n(37009)},51195:(t,e,n)=>{function i(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;const n=new DOMParser;let i=t;for(let t=0;ti})},54416:(t,e,n)=>{n.d(e,{A:()=>i});const i=n(29369).A},65463:(t,e,n)=>{n.d(e,{A:()=>a});var i=n(86984),o=n(54416);n(40296);const a=(0,n(14486).A)(o.A,i.X,i.Y,!1,null,"3cab0376",null).exports},70395:(t,e,n)=>{n.d(e,{A:()=>c});var i=n(21777),o=n(17003),a=n(51195),s=n(65043),r=n(35550);async function c(t,e,n){const c=["",t,e].join("/"),m=await s.Ay.post((0,o.e)()+c,{actorDisplayName:(0,i.HW)().displayName,actorId:(0,i.HW)().uid,actorType:"users",creationDateTime:(new Date).toUTCString(),message:n,objectType:t,verb:"comment"}),d=c+"/"+parseInt(m.headers["content-location"].split("/").pop()),l=await r.A.stat(d,{details:!0}),A=l.data.props;return A.actorDisplayName=(0,a.j)(A.actorDisplayName,2),A.message=(0,a.j)(A.message,2),l.data}},70452:(t,e,n)=>{n.d(e,{A:()=>r});var i=n(65043),o=n(21777),a=n(81222),s=n(63814);const r=(0,n(85471).pM)({props:{resourceId:{type:Number,required:!0},resourceType:{type:String,default:"files"}},data:()=>({editorData:{actorDisplayName:(0,o.HW)().displayName,actorId:(0,o.HW)().uid,key:"editor"},userData:{}}),methods:{async autoComplete(t,e){const{data:n}=await i.Ay.get((0,s.KT)("core/autocomplete/get"),{params:{search:t,itemType:"files",itemId:this.resourceId,sorter:"commenters|share-recipients",limit:(0,a.C)("comments","maxAutoCompleteResults")}});return n.ocs.data.forEach(t=>{this.userData[t.id]=t}),e(Object.values(this.userData))},genMentionsData(t){return Object.values(t).flat().forEach(t=>{this.userData[t.mentionId]={icon:"icon-user",id:t.mentionId,label:t.mentionDisplayName,source:"users",primary:(0,o.HW)()?.uid===t.mentionId}}),this.userData}}})},80486:(t,e,n)=>{n.d(e,{A:()=>o});var i=n(35550);async function o(t,e,n){const o=["",t,e,n].join("/");await i.A.deleteFile(o)}},86984:(t,e,n)=>{n.d(e,{X:()=>i,Y:()=>o});var i=function(){var t=this,e=t._self._c;return e(t.tag,{directives:[{name:"show",rawName:"v-show",value:!t.deleted&&!t.isLimbo,expression:"!deleted && !isLimbo"}],tag:"component",staticClass:"comment",class:{"comment--loading":t.loading}},[e("div",{staticClass:"comment__side"},[e("NcAvatar",{staticClass:"comment__avatar",attrs:{"display-name":t.actorDisplayName,user:t.actorId,size:32}})],1),t._v(" "),e("div",{staticClass:"comment__body"},[e("div",{staticClass:"comment__header"},[e("span",{staticClass:"comment__author"},[t._v(t._s(t.actorDisplayName))]),t._v(" "),t.isOwnComment&&t.id&&!t.loading?e("NcActions",{staticClass:"comment__actions"},[t.editing?e("NcActionButton",{on:{click:t.onEditCancel},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconClose",{attrs:{size:20}})]},proxy:!0}],null,!1,2888946197)},[t._v("\n\t\t\t\t\t"+t._s(t.t("comments","Cancel edit"))+"\n\t\t\t\t")]):[e("NcActionButton",{attrs:{"close-after-click":""},on:{click:t.onEdit},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconPencilOutline",{attrs:{size:20}})]},proxy:!0}],null,!1,3345211262)},[t._v("\n\t\t\t\t\t\t"+t._s(t.t("comments","Edit comment"))+"\n\t\t\t\t\t")]),t._v(" "),e("NcActionSeparator"),t._v(" "),e("NcActionButton",{attrs:{"close-after-click":""},on:{click:t.onDeleteWithUndo},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconTrashCanOutline",{attrs:{size:20}})]},proxy:!0}],null,!1,1034796883)},[t._v("\n\t\t\t\t\t\t"+t._s(t.t("comments","Delete comment"))+"\n\t\t\t\t\t")])]],2):t._e(),t._v(" "),t.id&&t.loading?e("div",{staticClass:"comment_loading icon-loading-small"}):t.creationDateTime?e("NcDateTime",{staticClass:"comment__timestamp",attrs:{timestamp:t.timestamp,"ignore-seconds":!0}}):t._e()],1),t._v(" "),t.editor||t.editing?e("form",{staticClass:"comment__editor",on:{submit:function(t){t.preventDefault()}}},[e("div",{staticClass:"comment__editor-group"},[e("NcRichContenteditable",{ref:"editor",attrs:{"auto-complete":t.autoComplete,contenteditable:!t.loading,label:t.editor?t.t("comments","New comment"):t.t("comments","Edit comment"),placeholder:t.t("comments","Write a comment …"),value:t.localMessage,"user-data":t.userData,"aria-describedby":"tab-comments__editor-description"},on:{"update:value":t.updateLocalMessage,submit:t.onSubmit}}),t._v(" "),e("div",{staticClass:"comment__submit"},[e("NcButton",{attrs:{type:"tertiary-no-background","native-type":"submit","aria-label":t.t("comments","Post comment"),disabled:t.isEmptyMessage},on:{click:t.onSubmit},scopedSlots:t._u([{key:"icon",fn:function(){return[t.loading?e("NcLoadingIcon"):e("IconArrowRight",{attrs:{size:20}})]},proxy:!0}],null,!1,758946661)})],1)],1),t._v(" "),e("div",{staticClass:"comment__editor-description",attrs:{id:"tab-comments__editor-description"}},[t._v("\n\t\t\t\t"+t._s(t.t("comments","@ for mentions, : for emoji, / for smart picker"))+"\n\t\t\t")])]):e("NcRichText",{staticClass:"comment__message",class:{"comment__message--expanded":t.expanded},attrs:{text:t.richContent.message,arguments:t.richContent.mentions},nativeOn:{click:function(e){return t.onExpand.apply(null,arguments)}}})],1)])},o=[]}}]); +//# sourceMappingURL=7462-7462.js.map?v=3fcd1d8bc575a39150b5 \ No newline at end of file diff --git a/dist/7462-7462.js.map b/dist/7462-7462.js.map index e80003edbd8..539ca850ab2 100644 --- a/dist/7462-7462.js.map +++ b/dist/7462-7462.js.map @@ -1 +1 @@ -{"version":3,"file":"7462-7462.js?v=df273d28c362a92d76d7","mappings":"yMAaA,SACCA,MAAO,CACNC,GAAI,CACHC,KAAMC,OACNC,QAAS,MAEVC,QAAS,CACRH,KAAMI,OACNF,QAAS,IAEVG,WAAY,CACXL,KAAM,CAACI,OAAQH,QACfK,UAAU,GAEXC,aAAc,CACbP,KAAMI,OACNF,QAAS,UAIXM,KAAIA,KACI,CACNC,SAAS,EACTC,SAAS,EACTC,SAAS,IAIXC,SAAU,KACNC,EAAAA,EAAAA,IAAUC,EAAAA,IAGdC,QAAS,CAERC,MAAAA,GACCC,KAAKP,SAAU,CAChB,EACAQ,YAAAA,GACCD,KAAKP,SAAU,EAEfO,KAAKE,mBAAmBF,KAAKd,QAC9B,EACA,mBAAMiB,CAAcjB,GACnBc,KAAKN,SAAU,EACf,UACOU,EAAAA,EAAAA,GAAYJ,KAAKV,aAAcU,KAAKZ,WAAYY,KAAKlB,GAAII,GAC/DmB,EAAAA,EAAOC,MAAM,iBAAkB,CAAEhB,aAAcU,KAAKV,aAAcF,WAAYY,KAAKZ,WAAYN,GAAIkB,KAAKlB,GAAII,YAC5Gc,KAAKO,MAAM,iBAAkBrB,GAC7Bc,KAAKP,SAAU,CAChB,CAAE,MAAOe,IACRC,EAAAA,EAAAA,IAAUC,EAAE,WAAY,uDACxBC,QAAQH,MAAMA,EACf,CAAE,QACDR,KAAKN,SAAU,CAChB,CACD,EAGAkB,gBAAAA,GACCZ,KAAKO,MAAM,UACXP,KAAKR,SAAU,EACfQ,KAAKa,yBAAyBC,MAAMd,KAAKlB,IACzC,MAAMiC,EAAgBC,WAAWhB,KAAKiB,SAAUC,EAAAA,KAChDC,EAAAA,EAAAA,IAAST,EAAE,WAAY,mBAAoB,KAC1CU,aAAaL,GACbf,K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OlC,eAAA,EAAerC,EAAcF,EAAYwC,GACvD,MAAMC,EAAc,CAAC,GAAIvC,EAAcF,EAAYwC,GAAWE,KAAK,WAG7DC,EAAAA,EAAOsJ,WAAWxJ,EACzB,C,yJCRIyJ,EAAU,CAAC,EAEfA,EAAQC,kBAAoB,IAC5BD,EAAQE,cAAgB,IACxBF,EAAQG,OAAS,SAAc,KAAM,QACrCH,EAAQI,OAAS,IACjBJ,EAAQK,mBAAqB,IAEhB,IAAI,IAASL,GAKJ,KAAW,IAAQM,QAAS,IAAQA,M","sources":["webpack:///nextcloud/apps/comments/src/mixins/CommentMixin.js","webpack:///nextcloud/apps/comments/src/services/EditComment.js","webpack:///nextcloud/apps/comments/src/components/Comment.vue","webpack:///nextcloud/apps/comments/src/store/deletedCommentLimbo.js","webpack:///nextcloud/apps/comments/src/components/Comment.vue?vue&type=style&index=0&id=54060d57&prod&lang=scss&scoped=true","webpack:///nextcloud/apps/comments/src/utils/decodeHtmlEntities.js","webpack:///nextcloud/apps/comments/src/components/Comment.vue?vue&type=script&lang=js","webpack://nextcloud/./apps/comments/src/components/Comment.vue?d1f7","webpack://nextcloud/./apps/comments/src/components/Comment.vue?7f26","webpack:///nextcloud/apps/comments/src/services/NewComment.js","webpack:///nextcloud/apps/comments/src/mixins/CommentView.ts","webpack:///nextcloud/apps/comments/src/services/DeleteComment.js","webpack://nextcloud/./apps/comments/src/components/Comment.vue?5d91"],"sourcesContent":["/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { showError, showUndo, TOAST_UNDO_TIMEOUT } from '@nextcloud/dialogs'\nimport NewComment from '../services/NewComment.js'\nimport DeleteComment from '../services/DeleteComment.js'\nimport EditComment from '../services/EditComment.js'\nimport { mapStores } from 'pinia'\nimport { useDeletedCommentLimbo } from '../store/deletedCommentLimbo.js'\nimport logger from '../logger.js'\n\nexport default {\n\tprops: {\n\t\tid: {\n\t\t\ttype: Number,\n\t\t\tdefault: null,\n\t\t},\n\t\tmessage: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\t\tresourceId: {\n\t\t\ttype: [String, Number],\n\t\t\trequired: true,\n\t\t},\n\t\tresourceType: {\n\t\t\ttype: String,\n\t\t\tdefault: 'files',\n\t\t},\n\t},\n\n\tdata() {\n\t\treturn {\n\t\t\tdeleted: false,\n\t\t\tediting: false,\n\t\t\tloading: false,\n\t\t}\n\t},\n\n\tcomputed: {\n\t\t...mapStores(useDeletedCommentLimbo),\n\t},\n\n\tmethods: {\n\t\t// EDITION\n\t\tonEdit() {\n\t\t\tthis.editing = true\n\t\t},\n\t\tonEditCancel() {\n\t\t\tthis.editing = false\n\t\t\t// Restore original value\n\t\t\tthis.updateLocalMessage(this.message)\n\t\t},\n\t\tasync onEditComment(message) {\n\t\t\tthis.loading = true\n\t\t\ttry {\n\t\t\t\tawait EditComment(this.resourceType, this.resourceId, this.id, message)\n\t\t\t\tlogger.debug('Comment edited', { resourceType: this.resourceType, resourceId: this.resourceId, id: this.id, message })\n\t\t\t\tthis.$emit('update:message', message)\n\t\t\t\tthis.editing = false\n\t\t\t} catch (error) {\n\t\t\t\tshowError(t('comments', 'An error occurred while trying to edit the comment'))\n\t\t\t\tconsole.error(error)\n\t\t\t} finally {\n\t\t\t\tthis.loading = false\n\t\t\t}\n\t\t},\n\n\t\t// DELETION\n\t\tonDeleteWithUndo() {\n\t\t\tthis.$emit('delete')\n\t\t\tthis.deleted = true\n\t\t\tthis.deletedCommentLimboStore.addId(this.id)\n\t\t\tconst timeOutDelete = setTimeout(this.onDelete, TOAST_UNDO_TIMEOUT)\n\t\t\tshowUndo(t('comments', 'Comment deleted'), () => {\n\t\t\t\tclearTimeout(timeOutDelete)\n\t\t\t\tthis.deleted = false\n\t\t\t\tthis.deletedCommentLimboStore.removeId(this.id)\n\t\t\t})\n\t\t},\n\t\tasync onDelete() {\n\t\t\ttry {\n\t\t\t\tawait DeleteComment(this.resourceType, this.resourceId, this.id)\n\t\t\t\tlogger.debug('Comment deleted', { resourceType: this.resourceType, resourceId: this.resourceId, id: this.id })\n\t\t\t\tthis.$emit('delete', this.id)\n\t\t\t} catch (error) {\n\t\t\t\tshowError(t('comments', 'An error occurred while trying to delete the comment'))\n\t\t\t\tconsole.error(error)\n\t\t\t\tthis.deleted = false\n\t\t\t\tthis.deletedCommentLimboStore.removeId(this.id)\n\t\t\t}\n\t\t},\n\n\t\t// CREATION\n\t\tasync onNewComment(message) {\n\t\t\tthis.loading = true\n\t\t\ttry {\n\t\t\t\tconst newComment = await NewComment(this.resourceType, this.resourceId, message)\n\t\t\t\tlogger.debug('New comment posted', { resourceType: this.resourceType, resourceId: this.resourceId, newComment })\n\t\t\t\tthis.$emit('new', newComment)\n\n\t\t\t\t// Clear old content\n\t\t\t\tthis.$emit('update:message', '')\n\t\t\t\tthis.localMessage = ''\n\t\t\t} catch (error) {\n\t\t\t\tshowError(t('comments', 'An error occurred while trying to create the comment'))\n\t\t\t\tconsole.error(error)\n\t\t\t} finally {\n\t\t\t\tthis.loading = false\n\t\t\t}\n\t\t},\n\t},\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport client from './DavClient.js'\n\n/**\n * Edit an existing comment\n *\n * @param {string} resourceType the resource type\n * @param {number} resourceId the resource ID\n * @param {number} commentId the comment iD\n * @param {string} message the message content\n */\nexport default async function(resourceType, resourceId, commentId, message) {\n\tconst commentPath = ['', resourceType, resourceId, commentId].join('/')\n\n\treturn await client.customRequest(commentPath, Object.assign({\n\t\tmethod: 'PROPPATCH',\n\t\tdata: `\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t${message}\n\t\t\t\t\n\t\t\t\n\t\t\t`,\n\t}))\n}\n","\n\n\n\n\n\n","/**\n * SPDX-FileCopyrightText: 2024 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { defineStore } from 'pinia'\n\nexport const useDeletedCommentLimbo = defineStore('deletedCommentLimbo', {\n\tstate: () => ({\n\t\tidsInLimbo: [],\n\t}),\n\tactions: {\n\t\taddId(id) {\n\t\t\tthis.idsInLimbo.push(id)\n\t\t},\n\n\t\tremoveId(id) {\n\t\t\tconst index = this.idsInLimbo.indexOf(id)\n\t\t\tif (index > -1) {\n\t\t\t\tthis.idsInLimbo.splice(index, 1)\n\t\t\t}\n\t\t},\n\n\t\tcheckForId(id) {\n\t\t\tthis.idsInLimbo.includes(id)\n\t\t},\n\t},\n})\n","// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, `.comment[data-v-54060d57]{display:flex;gap:8px;padding:5px 10px}.comment__side[data-v-54060d57]{display:flex;align-items:flex-start;padding-top:6px}.comment__body[data-v-54060d57]{display:flex;flex-grow:1;flex-direction:column;container-type:inline-size}.comment__header[data-v-54060d57]{display:flex;align-items:center;min-height:44px}.comment__actions[data-v-54060d57]{margin-inline-start:10px !important}.comment__author[data-v-54060d57]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:var(--color-text-maxcontrast)}.comment_loading[data-v-54060d57],.comment__timestamp[data-v-54060d57]{margin-inline-start:auto;text-align:end;white-space:nowrap;color:var(--color-text-maxcontrast)}.comment__editor-group[data-v-54060d57]{position:relative}.comment__editor-description[data-v-54060d57]{color:var(--color-text-maxcontrast);padding-block:var(--default-grid-baseline)}.comment__submit[data-v-54060d57]{position:absolute !important;bottom:5px;inset-inline-end:0}.comment__message[data-v-54060d57]{white-space:pre-wrap;word-break:normal;max-height:70px;overflow:hidden;margin-top:-6px}.comment__message--expanded[data-v-54060d57]{max-height:none;overflow:visible}.rich-contenteditable__input[data-v-54060d57]{min-height:44px;margin:0;padding:10px}`, \"\",{\"version\":3,\"sources\":[\"webpack://./apps/comments/src/components/Comment.vue\"],\"names\":[],\"mappings\":\"AAKA,0BACC,YAAA,CACA,OAAA,CACA,gBAAA,CAEA,gCACC,YAAA,CACA,sBAAA,CACA,eAAA,CAGD,gCACC,YAAA,CACA,WAAA,CACA,qBAAA,CACA,0BAAA,CAGD,kCACC,YAAA,CACA,kBAAA,CACA,eAAA,CAGD,mCACC,mCAAA,CAGD,kCACC,eAAA,CACA,kBAAA,CACA,sBAAA,CACA,mCAAA,CAGD,uEAEC,wBAAA,CACA,cAAA,CACA,kBAAA,CACA,mCAAA,CAGD,wCACC,iBAAA,CAGD,8CACC,mCAAA,CACA,0CAAA,CAGD,kCACC,4BAAA,CACA,UAAA,CACA,kBAAA,CAGD,mCACC,oBAAA,CACA,iBAAA,CACA,eAAA,CACA,eAAA,CACA,eAAA,CACA,6CACC,eAAA,CACA,gBAAA,CAKH,8CACC,eAAA,CACA,QAAA,CACA,YA5EiB\",\"sourcesContent\":[\"\\n@use \\\"sass:math\\\";\\n\\n$comment-padding: 10px;\\n\\n.comment {\\n\\tdisplay: flex;\\n\\tgap: 8px;\\n\\tpadding: 5px $comment-padding;\\n\\n\\t&__side {\\n\\t\\tdisplay: flex;\\n\\t\\talign-items: flex-start;\\n\\t\\tpadding-top: 6px;\\n\\t}\\n\\n\\t&__body {\\n\\t\\tdisplay: flex;\\n\\t\\tflex-grow: 1;\\n\\t\\tflex-direction: column;\\n\\t\\tcontainer-type: inline-size;\\n\\t}\\n\\n\\t&__header {\\n\\t\\tdisplay: flex;\\n\\t\\talign-items: center;\\n\\t\\tmin-height: 44px;\\n\\t}\\n\\n\\t&__actions {\\n\\t\\tmargin-inline-start: $comment-padding !important;\\n\\t}\\n\\n\\t&__author {\\n\\t\\toverflow: hidden;\\n\\t\\twhite-space: nowrap;\\n\\t\\ttext-overflow: ellipsis;\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t}\\n\\n\\t&_loading,\\n\\t&__timestamp {\\n\\t\\tmargin-inline-start: auto;\\n\\t\\ttext-align: end;\\n\\t\\twhite-space: nowrap;\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t}\\n\\n\\t&__editor-group {\\n\\t\\tposition: relative;\\n\\t}\\n\\n\\t&__editor-description {\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t\\tpadding-block: var(--default-grid-baseline);\\n\\t}\\n\\n\\t&__submit {\\n\\t\\tposition: absolute !important;\\n\\t\\tbottom: 5px;\\n\\t\\tinset-inline-end: 0;\\n\\t}\\n\\n\\t&__message {\\n\\t\\twhite-space: pre-wrap;\\n\\t\\tword-break: normal;\\n\\t\\tmax-height: 70px;\\n\\t\\toverflow: hidden;\\n\\t\\tmargin-top: -6px;\\n\\t\\t&--expanded {\\n\\t\\t\\tmax-height: none;\\n\\t\\t\\toverflow: visible;\\n\\t\\t}\\n\\t}\\n}\\n\\n.rich-contenteditable__input {\\n\\tmin-height: 44px;\\n\\tmargin: 0;\\n\\tpadding: $comment-padding;\\n}\\n\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","/**\n * SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\n/**\n * @param {any} value -\n * @param {any} passes -\n */\nexport function decodeHtmlEntities(value, passes = 1) {\n\tconst parser = new DOMParser()\n\tlet decoded = value\n\tfor (let i = 0; i < passes; i++) {\n\t\tdecoded = parser.parseFromString(decoded, 'text/html').documentElement.textContent\n\t}\n\treturn decoded\n}\n","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=script&lang=js\"","var render = function render(){var _vm=this,_c=_vm._self._c;return _c(_vm.tag,{directives:[{name:\"show\",rawName:\"v-show\",value:(!_vm.deleted && !_vm.isLimbo),expression:\"!deleted && !isLimbo\"}],tag:\"component\",staticClass:\"comment\",class:{'comment--loading': _vm.loading}},[_c('div',{staticClass:\"comment__side\"},[_c('NcAvatar',{staticClass:\"comment__avatar\",attrs:{\"display-name\":_vm.actorDisplayName,\"user\":_vm.actorId,\"size\":32}})],1),_vm._v(\" \"),_c('div',{staticClass:\"comment__body\"},[_c('div',{staticClass:\"comment__header\"},[_c('span',{staticClass:\"comment__author\"},[_vm._v(_vm._s(_vm.actorDisplayName))]),_vm._v(\" \"),(_vm.isOwnComment && _vm.id && !_vm.loading)?_c('NcActions',{staticClass:\"comment__actions\"},[(!_vm.editing)?[_c('NcActionButton',{attrs:{\"close-after-click\":\"\"},on:{\"click\":_vm.onEdit},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconPencilOutline',{attrs:{\"size\":20}})]},proxy:true}],null,false,3345211262)},[_vm._v(\"\\n\\t\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Edit comment'))+\"\\n\\t\\t\\t\\t\\t\")]),_vm._v(\" \"),_c('NcActionSeparator'),_vm._v(\" \"),_c('NcActionButton',{attrs:{\"close-after-click\":\"\"},on:{\"click\":_vm.onDeleteWithUndo},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconTrashCanOutline',{attrs:{\"size\":20}})]},proxy:true}],null,false,1034796883)},[_vm._v(\"\\n\\t\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Delete comment'))+\"\\n\\t\\t\\t\\t\\t\")])]:_c('NcActionButton',{on:{\"click\":_vm.onEditCancel},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconClose',{attrs:{\"size\":20}})]},proxy:true}],null,false,2888946197)},[_vm._v(\"\\n\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Cancel edit'))+\"\\n\\t\\t\\t\\t\")])],2):_vm._e(),_vm._v(\" \"),(_vm.id && _vm.loading)?_c('div',{staticClass:\"comment_loading icon-loading-small\"}):(_vm.creationDateTime)?_c('NcDateTime',{staticClass:\"comment__timestamp\",attrs:{\"timestamp\":_vm.timestamp,\"ignore-seconds\":true}}):_vm._e()],1),_vm._v(\" \"),(_vm.editor || _vm.editing)?_c('form',{staticClass:\"comment__editor\",on:{\"submit\":function($event){$event.preventDefault();}}},[_c('div',{staticClass:\"comment__editor-group\"},[_c('NcRichContenteditable',{ref:\"editor\",attrs:{\"auto-complete\":_vm.autoComplete,\"contenteditable\":!_vm.loading,\"label\":_vm.editor ? _vm.t('comments', 'New comment') : _vm.t('comments', 'Edit comment'),\"placeholder\":_vm.t('comments', 'Write a comment …'),\"value\":_vm.localMessage,\"user-data\":_vm.userData,\"aria-describedby\":\"tab-comments__editor-description\"},on:{\"update:value\":_vm.updateLocalMessage,\"submit\":_vm.onSubmit}}),_vm._v(\" \"),_c('div',{staticClass:\"comment__submit\"},[_c('NcButton',{attrs:{\"type\":\"tertiary-no-background\",\"native-type\":\"submit\",\"aria-label\":_vm.t('comments', 'Post comment'),\"disabled\":_vm.isEmptyMessage},on:{\"click\":_vm.onSubmit},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [(_vm.loading)?_c('NcLoadingIcon'):_c('IconArrowRight',{attrs:{\"size\":20}})]},proxy:true}],null,false,758946661)})],1)],1),_vm._v(\" \"),_c('div',{staticClass:\"comment__editor-description\",attrs:{\"id\":\"tab-comments__editor-description\"}},[_vm._v(\"\\n\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', '@ for mentions, : for emoji, / for smart picker'))+\"\\n\\t\\t\\t\")])]):_c('NcRichText',{staticClass:\"comment__message\",class:{'comment__message--expanded': _vm.expanded},attrs:{\"text\":_vm.richContent.message,\"arguments\":_vm.richContent.mentions},on:{\"click\":_vm.onExpand}})],1)])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import { render, staticRenderFns } from \"./Comment.vue?vue&type=template&id=54060d57&scoped=true\"\nimport script from \"./Comment.vue?vue&type=script&lang=js\"\nexport * from \"./Comment.vue?vue&type=script&lang=js\"\nimport style0 from \"./Comment.vue?vue&type=style&index=0&id=54060d57&prod&lang=scss&scoped=true\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"54060d57\",\n null\n \n)\n\nexport default component.exports","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { getCurrentUser } from '@nextcloud/auth'\nimport { getRootPath } from '../utils/davUtils.js'\nimport { decodeHtmlEntities } from '../utils/decodeHtmlEntities.js'\nimport axios from '@nextcloud/axios'\nimport client from './DavClient.js'\n\n/**\n * Retrieve the comments list\n *\n * @param {string} resourceType the resource type\n * @param {number} resourceId the resource ID\n * @param {string} message the message\n * @return {object} the new comment\n */\nexport default async function(resourceType, resourceId, message) {\n\tconst resourcePath = ['', resourceType, resourceId].join('/')\n\n\tconst response = await axios.post(getRootPath() + resourcePath, {\n\t\tactorDisplayName: getCurrentUser().displayName,\n\t\tactorId: getCurrentUser().uid,\n\t\tactorType: 'users',\n\t\tcreationDateTime: (new Date()).toUTCString(),\n\t\tmessage,\n\t\tobjectType: resourceType,\n\t\tverb: 'comment',\n\t})\n\n\t// Retrieve comment id from resource location\n\tconst commentId = parseInt(response.headers['content-location'].split('/').pop())\n\tconst commentPath = resourcePath + '/' + commentId\n\n\t// Fetch newly created comment data\n\tconst comment = await client.stat(commentPath, {\n\t\tdetails: true,\n\t})\n\n\tconst props = comment.data.props\n\t// Decode twice to handle potentially double-encoded entities\n\t// FIXME Remove this once https://github.com/nextcloud/server/issues/29306\n\t// is resolved\n\tprops.actorDisplayName = decodeHtmlEntities(props.actorDisplayName, 2)\n\tprops.message = decodeHtmlEntities(props.message, 2)\n\n\treturn comment.data\n}\n","/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\nimport axios from '@nextcloud/axios';\nimport { getCurrentUser } from '@nextcloud/auth';\nimport { loadState } from '@nextcloud/initial-state';\nimport { generateOcsUrl } from '@nextcloud/router';\nimport { defineComponent } from 'vue';\nexport default defineComponent({\n props: {\n resourceId: {\n type: Number,\n required: true,\n },\n resourceType: {\n type: String,\n default: 'files',\n },\n },\n data() {\n return {\n editorData: {\n actorDisplayName: getCurrentUser().displayName,\n actorId: getCurrentUser().uid,\n key: 'editor',\n },\n userData: {},\n };\n },\n methods: {\n /**\n * Autocomplete @mentions\n *\n * @param {string} search the query\n * @param {Function} callback the callback to process the results with\n */\n async autoComplete(search, callback) {\n const { data } = await axios.get(generateOcsUrl('core/autocomplete/get'), {\n params: {\n search,\n itemType: 'files',\n itemId: this.resourceId,\n sorter: 'commenters|share-recipients',\n limit: loadState('comments', 'maxAutoCompleteResults'),\n },\n });\n // Save user data so it can be used by the editor to replace mentions\n data.ocs.data.forEach(user => { this.userData[user.id] = user; });\n return callback(Object.values(this.userData));\n },\n /**\n * Make sure we have all mentions as Array of objects\n *\n * @param mentions the mentions list\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n genMentionsData(mentions) {\n Object.values(mentions)\n .flat()\n .forEach(mention => {\n this.userData[mention.mentionId] = {\n // TODO: support groups\n icon: 'icon-user',\n id: mention.mentionId,\n label: mention.mentionDisplayName,\n source: 'users',\n primary: getCurrentUser()?.uid === mention.mentionId,\n };\n });\n return this.userData;\n },\n },\n});\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport client from './DavClient.js'\n\n/**\n * Delete a comment\n *\n * @param {string} resourceType the resource type\n * @param {number} resourceId the resource ID\n * @param {number} commentId the comment iD\n */\nexport default async function(resourceType, resourceId, commentId) {\n\tconst commentPath = ['', resourceType, resourceId, commentId].join('/')\n\n\t// Fetch newly created comment data\n\tawait client.deleteFile(commentPath)\n}\n","\n import API from \"!../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=style&index=0&id=54060d57&prod&lang=scss&scoped=true\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\noptions.insert = insertFn.bind(null, \"head\");\noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=style&index=0&id=54060d57&prod&lang=scss&scoped=true\";\n export default content && content.locals ? content.locals : undefined;\n"],"names":["props","id","type","Number","default","message","String","resourceId","required","resourceType","data","deleted","editing","loading","computed","mapStores","useDeletedCommentLimbo","methods","onEdit","this","onEditCancel","updateLocalMessage","onEditComment","EditComment","logger","debug","$emit","error","showError","t","console","onDeleteWithUndo","deletedCommentLimboStore","addId","timeOutDelete","setTimeout","onDelete","TOAST_UNDO_TIMEOUT","showUndo","clearTimeout","removeId","DeleteComment","onNewComment","newComment","NewComment","localMessage","async","commentId","commentPath","join","client","customRequest","Object","assign","method","name","components","IconArrowRight","IconClose","IconTrashCanOutline","IconPencilOutline","NcActionButton","NcActions","NcActionSeparator","NcAvatar","NcButton","NcDateTime","NcLoadingIcon","NcRichContenteditable","NcRichText","mixins","CommentMixin","inheritAttrs","actorDisplayName","actorId","creationDateTime","editor","Boolean","autoComplete","Function","userData","tag","expanded","submitted","isOwnComment","getCurrentUser","uid","richContent","mentions","keys","forEach","user","index","key","regex","RegExp","replace","component","NcUserBubble","displayName","label","primary","isEmptyMessage","trim","timestamp","Date","parse","isLimbo","checkForId","watch","beforeMount","toString","onSubmit","$nextTick","$refs","$el","focus","onExpand","defineStore","state","idsInLimbo","actions","push","indexOf","splice","includes","___CSS_LOADER_EXPORT___","module","decodeHtmlEntities","value","passes","arguments","length","undefined","parser","DOMParser","decoded","i","parseFromString","documentElement","textContent","render","_vm","_c","_self","directives","rawName","expression","staticClass","class","attrs","_v","_s","on","scopedSlots","_u","fn","proxy","_e","$event","preventDefault","ref","staticRenderFns","resourcePath","response","axios","post","getRootPath","actorType","toUTCString","objectType","verb","parseInt","headers","split","pop","comment","stat","details","defineComponent","editorData","search","callback","get","generateOcsUrl","params","itemType","itemId","sorter","limit","loadState","ocs","values","genMentionsData","flat","mention","mentionId","icon","mentionDisplayName","source","deleteFile","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","locals"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"7462-7462.js?v=3fcd1d8bc575a39150b5","mappings":"0JAGIA,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,gvCAAivC,GAAG,CAAC,QAAU,EAAE,QAAU,CAAC,wDAAwD,MAAQ,GAAG,SAAW,keAAke,eAAiB,CAAC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,EAAInE,SAASwF,MAAM,KAAMtE,UAAU,MAAM,IAC51G,EACIuE,EAAkB,E","sources":["webpack:///nextcloud/apps/comments/src/components/Comment.vue?vue&type=style&index=0&id=3cab0376&prod&lang=scss&scoped=true","webpack:///nextcloud/apps/comments/src/mixins/CommentMixin.js","webpack:///nextcloud/apps/comments/src/services/EditComment.js","webpack:///nextcloud/apps/comments/src/components/Comment.vue","webpack:///nextcloud/apps/comments/src/store/deletedCommentLimbo.js","webpack://nextcloud/./apps/comments/src/components/Comment.vue?d279","webpack:///nextcloud/apps/comments/src/utils/decodeHtmlEntities.js","webpack:///nextcloud/apps/comments/src/components/Comment.vue?vue&type=script&lang=js","webpack://nextcloud/./apps/comments/src/components/Comment.vue?7f26","webpack:///nextcloud/apps/comments/src/services/NewComment.js","webpack:///nextcloud/apps/comments/src/mixins/CommentView.ts","webpack:///nextcloud/apps/comments/src/services/DeleteComment.js","webpack://nextcloud/./apps/comments/src/components/Comment.vue?d1f7"],"sourcesContent":["// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, `.comment[data-v-3cab0376]{display:flex;gap:8px;padding:5px 10px}.comment__side[data-v-3cab0376]{display:flex;align-items:flex-start;padding-top:6px}.comment__body[data-v-3cab0376]{display:flex;flex-grow:1;flex-direction:column;container-type:inline-size}.comment__header[data-v-3cab0376]{display:flex;align-items:center;min-height:44px}.comment__actions[data-v-3cab0376]{margin-inline-start:10px !important}.comment__author[data-v-3cab0376]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:var(--color-text-maxcontrast)}.comment_loading[data-v-3cab0376],.comment__timestamp[data-v-3cab0376]{margin-inline-start:auto;text-align:end;white-space:nowrap;color:var(--color-text-maxcontrast)}.comment__editor-group[data-v-3cab0376]{position:relative}.comment__editor-description[data-v-3cab0376]{color:var(--color-text-maxcontrast);padding-block:var(--default-grid-baseline)}.comment__submit[data-v-3cab0376]{position:absolute !important;bottom:5px;inset-inline-end:0}.comment__message[data-v-3cab0376]{white-space:pre-wrap;word-break:normal;max-height:70px;overflow:hidden;margin-top:-6px}.comment__message--expanded[data-v-3cab0376]{max-height:none;overflow:visible}.rich-contenteditable__input[data-v-3cab0376]{min-height:44px;margin:0;padding:10px}`, \"\",{\"version\":3,\"sources\":[\"webpack://./apps/comments/src/components/Comment.vue\"],\"names\":[],\"mappings\":\"AAKA,0BACC,YAAA,CACA,OAAA,CACA,gBAAA,CAEA,gCACC,YAAA,CACA,sBAAA,CACA,eAAA,CAGD,gCACC,YAAA,CACA,WAAA,CACA,qBAAA,CACA,0BAAA,CAGD,kCACC,YAAA,CACA,kBAAA,CACA,eAAA,CAGD,mCACC,mCAAA,CAGD,kCACC,eAAA,CACA,kBAAA,CACA,sBAAA,CACA,mCAAA,CAGD,uEAEC,wBAAA,CACA,cAAA,CACA,kBAAA,CACA,mCAAA,CAGD,wCACC,iBAAA,CAGD,8CACC,mCAAA,CACA,0CAAA,CAGD,kCACC,4BAAA,CACA,UAAA,CACA,kBAAA,CAGD,mCACC,oBAAA,CACA,iBAAA,CACA,eAAA,CACA,eAAA,CACA,eAAA,CACA,6CACC,eAAA,CACA,gBAAA,CAKH,8CACC,eAAA,CACA,QAAA,CACA,YA5EiB\",\"sourcesContent\":[\"\\n@use \\\"sass:math\\\";\\n\\n$comment-padding: 10px;\\n\\n.comment {\\n\\tdisplay: flex;\\n\\tgap: 8px;\\n\\tpadding: 5px $comment-padding;\\n\\n\\t&__side {\\n\\t\\tdisplay: flex;\\n\\t\\talign-items: flex-start;\\n\\t\\tpadding-top: 6px;\\n\\t}\\n\\n\\t&__body {\\n\\t\\tdisplay: flex;\\n\\t\\tflex-grow: 1;\\n\\t\\tflex-direction: column;\\n\\t\\tcontainer-type: inline-size;\\n\\t}\\n\\n\\t&__header {\\n\\t\\tdisplay: flex;\\n\\t\\talign-items: center;\\n\\t\\tmin-height: 44px;\\n\\t}\\n\\n\\t&__actions {\\n\\t\\tmargin-inline-start: $comment-padding !important;\\n\\t}\\n\\n\\t&__author {\\n\\t\\toverflow: hidden;\\n\\t\\twhite-space: nowrap;\\n\\t\\ttext-overflow: ellipsis;\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t}\\n\\n\\t&_loading,\\n\\t&__timestamp {\\n\\t\\tmargin-inline-start: auto;\\n\\t\\ttext-align: end;\\n\\t\\twhite-space: nowrap;\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t}\\n\\n\\t&__editor-group {\\n\\t\\tposition: relative;\\n\\t}\\n\\n\\t&__editor-description {\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t\\tpadding-block: var(--default-grid-baseline);\\n\\t}\\n\\n\\t&__submit {\\n\\t\\tposition: absolute !important;\\n\\t\\tbottom: 5px;\\n\\t\\tinset-inline-end: 0;\\n\\t}\\n\\n\\t&__message {\\n\\t\\twhite-space: pre-wrap;\\n\\t\\tword-break: normal;\\n\\t\\tmax-height: 70px;\\n\\t\\toverflow: hidden;\\n\\t\\tmargin-top: -6px;\\n\\t\\t&--expanded {\\n\\t\\t\\tmax-height: none;\\n\\t\\t\\toverflow: visible;\\n\\t\\t}\\n\\t}\\n}\\n\\n.rich-contenteditable__input {\\n\\tmin-height: 44px;\\n\\tmargin: 0;\\n\\tpadding: $comment-padding;\\n}\\n\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { showError, showUndo, TOAST_UNDO_TIMEOUT } from '@nextcloud/dialogs'\nimport NewComment from '../services/NewComment.js'\nimport DeleteComment from '../services/DeleteComment.js'\nimport EditComment from '../services/EditComment.js'\nimport { mapStores } from 'pinia'\nimport { useDeletedCommentLimbo } from '../store/deletedCommentLimbo.js'\nimport logger from '../logger.js'\n\nexport default {\n\tprops: {\n\t\tid: {\n\t\t\ttype: Number,\n\t\t\tdefault: null,\n\t\t},\n\t\tmessage: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\t\tresourceId: {\n\t\t\ttype: [String, Number],\n\t\t\trequired: true,\n\t\t},\n\t\tresourceType: {\n\t\t\ttype: String,\n\t\t\tdefault: 'files',\n\t\t},\n\t},\n\n\tdata() {\n\t\treturn {\n\t\t\tdeleted: false,\n\t\t\tediting: false,\n\t\t\tloading: false,\n\t\t}\n\t},\n\n\tcomputed: {\n\t\t...mapStores(useDeletedCommentLimbo),\n\t},\n\n\tmethods: {\n\t\t// EDITION\n\t\tonEdit() {\n\t\t\tthis.editing = true\n\t\t},\n\t\tonEditCancel() {\n\t\t\tthis.editing = false\n\t\t\t// Restore original value\n\t\t\tthis.updateLocalMessage(this.message)\n\t\t},\n\t\tasync onEditComment(message) {\n\t\t\tthis.loading = true\n\t\t\ttry {\n\t\t\t\tawait EditComment(this.resourceType, this.resourceId, this.id, message)\n\t\t\t\tlogger.debug('Comment edited', { resourceType: this.resourceType, resourceId: this.resourceId, id: this.id, message })\n\t\t\t\tthis.$emit('update:message', message)\n\t\t\t\tthis.editing = false\n\t\t\t} catch (error) {\n\t\t\t\tshowError(t('comments', 'An error occurred while trying to edit the comment'))\n\t\t\t\tconsole.error(error)\n\t\t\t} finally {\n\t\t\t\tthis.loading = false\n\t\t\t}\n\t\t},\n\n\t\t// DELETION\n\t\tonDeleteWithUndo() {\n\t\t\tthis.$emit('delete')\n\t\t\tthis.deleted = true\n\t\t\tthis.deletedCommentLimboStore.addId(this.id)\n\t\t\tconst timeOutDelete = setTimeout(this.onDelete, TOAST_UNDO_TIMEOUT)\n\t\t\tshowUndo(t('comments', 'Comment deleted'), () => {\n\t\t\t\tclearTimeout(timeOutDelete)\n\t\t\t\tthis.deleted = false\n\t\t\t\tthis.deletedCommentLimboStore.removeId(this.id)\n\t\t\t})\n\t\t},\n\t\tasync onDelete() {\n\t\t\ttry {\n\t\t\t\tawait DeleteComment(this.resourceType, this.resourceId, this.id)\n\t\t\t\tlogger.debug('Comment deleted', { resourceType: this.resourceType, resourceId: this.resourceId, id: this.id })\n\t\t\t\tthis.$emit('delete', this.id)\n\t\t\t} catch (error) {\n\t\t\t\tshowError(t('comments', 'An error occurred while trying to delete the comment'))\n\t\t\t\tconsole.error(error)\n\t\t\t\tthis.deleted = false\n\t\t\t\tthis.deletedCommentLimboStore.removeId(this.id)\n\t\t\t}\n\t\t},\n\n\t\t// CREATION\n\t\tasync onNewComment(message) {\n\t\t\tthis.loading = true\n\t\t\ttry {\n\t\t\t\tconst newComment = await NewComment(this.resourceType, this.resourceId, message)\n\t\t\t\tlogger.debug('New comment posted', { resourceType: this.resourceType, resourceId: this.resourceId, newComment })\n\t\t\t\tthis.$emit('new', newComment)\n\n\t\t\t\t// Clear old content\n\t\t\t\tthis.$emit('update:message', '')\n\t\t\t\tthis.localMessage = ''\n\t\t\t} catch (error) {\n\t\t\t\tshowError(t('comments', 'An error occurred while trying to create the comment'))\n\t\t\t\tconsole.error(error)\n\t\t\t} finally {\n\t\t\t\tthis.loading = false\n\t\t\t}\n\t\t},\n\t},\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport client from './DavClient.js'\n\n/**\n * Edit an existing comment\n *\n * @param {string} resourceType the resource type\n * @param {number} resourceId the resource ID\n * @param {number} commentId the comment iD\n * @param {string} message the message content\n */\nexport default async function(resourceType, resourceId, commentId, message) {\n\tconst commentPath = ['', resourceType, resourceId, commentId].join('/')\n\n\treturn await client.customRequest(commentPath, Object.assign({\n\t\tmethod: 'PROPPATCH',\n\t\tdata: `\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t${message}\n\t\t\t\t\n\t\t\t\n\t\t\t`,\n\t}))\n}\n","\n\n\n\n\n\n","/**\n * SPDX-FileCopyrightText: 2024 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { defineStore } from 'pinia'\n\nexport const useDeletedCommentLimbo = defineStore('deletedCommentLimbo', {\n\tstate: () => ({\n\t\tidsInLimbo: [],\n\t}),\n\tactions: {\n\t\taddId(id) {\n\t\t\tthis.idsInLimbo.push(id)\n\t\t},\n\n\t\tremoveId(id) {\n\t\t\tconst index = this.idsInLimbo.indexOf(id)\n\t\t\tif (index > -1) {\n\t\t\t\tthis.idsInLimbo.splice(index, 1)\n\t\t\t}\n\t\t},\n\n\t\tcheckForId(id) {\n\t\t\tthis.idsInLimbo.includes(id)\n\t\t},\n\t},\n})\n","\n import API from \"!../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=style&index=0&id=3cab0376&prod&lang=scss&scoped=true\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\noptions.insert = insertFn.bind(null, \"head\");\noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=style&index=0&id=3cab0376&prod&lang=scss&scoped=true\";\n export default content && content.locals ? content.locals : undefined;\n","/**\n * SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\n/**\n * @param {any} value -\n * @param {any} passes -\n */\nexport function decodeHtmlEntities(value, passes = 1) {\n\tconst parser = new DOMParser()\n\tlet decoded = value\n\tfor (let i = 0; i < passes; i++) {\n\t\tdecoded = parser.parseFromString(decoded, 'text/html').documentElement.textContent\n\t}\n\treturn decoded\n}\n","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=script&lang=js\"","import { render, staticRenderFns } from \"./Comment.vue?vue&type=template&id=3cab0376&scoped=true\"\nimport script from \"./Comment.vue?vue&type=script&lang=js\"\nexport * from \"./Comment.vue?vue&type=script&lang=js\"\nimport style0 from \"./Comment.vue?vue&type=style&index=0&id=3cab0376&prod&lang=scss&scoped=true\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"3cab0376\",\n null\n \n)\n\nexport default component.exports","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { getCurrentUser } from '@nextcloud/auth'\nimport { getRootPath } from '../utils/davUtils.js'\nimport { decodeHtmlEntities } from '../utils/decodeHtmlEntities.js'\nimport axios from '@nextcloud/axios'\nimport client from './DavClient.js'\n\n/**\n * Retrieve the comments list\n *\n * @param {string} resourceType the resource type\n * @param {number} resourceId the resource ID\n * @param {string} message the message\n * @return {object} the new comment\n */\nexport default async function(resourceType, resourceId, message) {\n\tconst resourcePath = ['', resourceType, resourceId].join('/')\n\n\tconst response = await axios.post(getRootPath() + resourcePath, {\n\t\tactorDisplayName: getCurrentUser().displayName,\n\t\tactorId: getCurrentUser().uid,\n\t\tactorType: 'users',\n\t\tcreationDateTime: (new Date()).toUTCString(),\n\t\tmessage,\n\t\tobjectType: resourceType,\n\t\tverb: 'comment',\n\t})\n\n\t// Retrieve comment id from resource location\n\tconst commentId = parseInt(response.headers['content-location'].split('/').pop())\n\tconst commentPath = resourcePath + '/' + commentId\n\n\t// Fetch newly created comment data\n\tconst comment = await client.stat(commentPath, {\n\t\tdetails: true,\n\t})\n\n\tconst props = comment.data.props\n\t// Decode twice to handle potentially double-encoded entities\n\t// FIXME Remove this once https://github.com/nextcloud/server/issues/29306\n\t// is resolved\n\tprops.actorDisplayName = decodeHtmlEntities(props.actorDisplayName, 2)\n\tprops.message = decodeHtmlEntities(props.message, 2)\n\n\treturn comment.data\n}\n","/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\nimport axios from '@nextcloud/axios';\nimport { getCurrentUser } from '@nextcloud/auth';\nimport { loadState } from '@nextcloud/initial-state';\nimport { generateOcsUrl } from '@nextcloud/router';\nimport { defineComponent } from 'vue';\nexport default defineComponent({\n props: {\n resourceId: {\n type: Number,\n required: true,\n },\n resourceType: {\n type: String,\n default: 'files',\n },\n },\n data() {\n return {\n editorData: {\n actorDisplayName: getCurrentUser().displayName,\n actorId: getCurrentUser().uid,\n key: 'editor',\n },\n userData: {},\n };\n },\n methods: {\n /**\n * Autocomplete @mentions\n *\n * @param {string} search the query\n * @param {Function} callback the callback to process the results with\n */\n async autoComplete(search, callback) {\n const { data } = await axios.get(generateOcsUrl('core/autocomplete/get'), {\n params: {\n search,\n itemType: 'files',\n itemId: this.resourceId,\n sorter: 'commenters|share-recipients',\n limit: loadState('comments', 'maxAutoCompleteResults'),\n },\n });\n // Save user data so it can be used by the editor to replace mentions\n data.ocs.data.forEach(user => { this.userData[user.id] = user; });\n return callback(Object.values(this.userData));\n },\n /**\n * Make sure we have all mentions as Array of objects\n *\n * @param mentions the mentions list\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n genMentionsData(mentions) {\n Object.values(mentions)\n .flat()\n .forEach(mention => {\n this.userData[mention.mentionId] = {\n // TODO: support groups\n icon: 'icon-user',\n id: mention.mentionId,\n label: mention.mentionDisplayName,\n source: 'users',\n primary: getCurrentUser()?.uid === mention.mentionId,\n };\n });\n return this.userData;\n },\n },\n});\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport client from './DavClient.js'\n\n/**\n * Delete a comment\n *\n * @param {string} resourceType the resource type\n * @param {number} resourceId the resource ID\n * @param {number} commentId the comment iD\n */\nexport default async function(resourceType, resourceId, commentId) {\n\tconst commentPath = ['', resourceType, resourceId, commentId].join('/')\n\n\t// Fetch newly created comment data\n\tawait client.deleteFile(commentPath)\n}\n","var render = function render(){var _vm=this,_c=_vm._self._c;return _c(_vm.tag,{directives:[{name:\"show\",rawName:\"v-show\",value:(!_vm.deleted && !_vm.isLimbo),expression:\"!deleted && !isLimbo\"}],tag:\"component\",staticClass:\"comment\",class:{'comment--loading': _vm.loading}},[_c('div',{staticClass:\"comment__side\"},[_c('NcAvatar',{staticClass:\"comment__avatar\",attrs:{\"display-name\":_vm.actorDisplayName,\"user\":_vm.actorId,\"size\":32}})],1),_vm._v(\" \"),_c('div',{staticClass:\"comment__body\"},[_c('div',{staticClass:\"comment__header\"},[_c('span',{staticClass:\"comment__author\"},[_vm._v(_vm._s(_vm.actorDisplayName))]),_vm._v(\" \"),(_vm.isOwnComment && _vm.id && !_vm.loading)?_c('NcActions',{staticClass:\"comment__actions\"},[(!_vm.editing)?[_c('NcActionButton',{attrs:{\"close-after-click\":\"\"},on:{\"click\":_vm.onEdit},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconPencilOutline',{attrs:{\"size\":20}})]},proxy:true}],null,false,3345211262)},[_vm._v(\"\\n\\t\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Edit comment'))+\"\\n\\t\\t\\t\\t\\t\")]),_vm._v(\" \"),_c('NcActionSeparator'),_vm._v(\" \"),_c('NcActionButton',{attrs:{\"close-after-click\":\"\"},on:{\"click\":_vm.onDeleteWithUndo},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconTrashCanOutline',{attrs:{\"size\":20}})]},proxy:true}],null,false,1034796883)},[_vm._v(\"\\n\\t\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Delete comment'))+\"\\n\\t\\t\\t\\t\\t\")])]:_c('NcActionButton',{on:{\"click\":_vm.onEditCancel},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconClose',{attrs:{\"size\":20}})]},proxy:true}],null,false,2888946197)},[_vm._v(\"\\n\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Cancel edit'))+\"\\n\\t\\t\\t\\t\")])],2):_vm._e(),_vm._v(\" \"),(_vm.id && _vm.loading)?_c('div',{staticClass:\"comment_loading icon-loading-small\"}):(_vm.creationDateTime)?_c('NcDateTime',{staticClass:\"comment__timestamp\",attrs:{\"timestamp\":_vm.timestamp,\"ignore-seconds\":true}}):_vm._e()],1),_vm._v(\" \"),(_vm.editor || _vm.editing)?_c('form',{staticClass:\"comment__editor\",on:{\"submit\":function($event){$event.preventDefault();}}},[_c('div',{staticClass:\"comment__editor-group\"},[_c('NcRichContenteditable',{ref:\"editor\",attrs:{\"auto-complete\":_vm.autoComplete,\"contenteditable\":!_vm.loading,\"label\":_vm.editor ? _vm.t('comments', 'New comment') : _vm.t('comments', 'Edit comment'),\"placeholder\":_vm.t('comments', 'Write a comment …'),\"value\":_vm.localMessage,\"user-data\":_vm.userData,\"aria-describedby\":\"tab-comments__editor-description\"},on:{\"update:value\":_vm.updateLocalMessage,\"submit\":_vm.onSubmit}}),_vm._v(\" \"),_c('div',{staticClass:\"comment__submit\"},[_c('NcButton',{attrs:{\"type\":\"tertiary-no-background\",\"native-type\":\"submit\",\"aria-label\":_vm.t('comments', 'Post comment'),\"disabled\":_vm.isEmptyMessage},on:{\"click\":_vm.onSubmit},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [(_vm.loading)?_c('NcLoadingIcon'):_c('IconArrowRight',{attrs:{\"size\":20}})]},proxy:true}],null,false,758946661)})],1)],1),_vm._v(\" \"),_c('div',{staticClass:\"comment__editor-description\",attrs:{\"id\":\"tab-comments__editor-description\"}},[_vm._v(\"\\n\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', '@ for mentions, : for emoji, / for smart picker'))+\"\\n\\t\\t\\t\")])]):_c('NcRichText',{staticClass:\"comment__message\",class:{'comment__message--expanded': _vm.expanded},attrs:{\"text\":_vm.richContent.message,\"arguments\":_vm.richContent.mentions},nativeOn:{\"click\":function($event){return _vm.onExpand.apply(null, arguments)}}})],1)])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }"],"names":["___CSS_LOADER_EXPORT___","push","module","id","props","type","Number","default","message","String","resourceId","required","resourceType","data","deleted","editing","loading","computed","mapStores","useDeletedCommentLimbo","methods","onEdit","this","onEditCancel","updateLocalMessage","onEditComment","EditComment","logger","debug","$emit","error","showError","t","console","onDeleteWithUndo","deletedCommentLimboStore","addId","timeOutDelete","setTimeout","onDelete","TOAST_UNDO_TIMEOUT","showUndo","clearTimeout","removeId","DeleteComment","onNewComment","newComment","NewComment","localMessage","async","commentId","commentPath","join","client","customRequest","Object","assign","method","name","components","IconArrowRight","IconClose","IconTrashCanOutline","IconPencilOutline","NcActionButton","NcActions","NcActionSeparator","NcAvatar","NcButton","NcDateTime","NcLoadingIcon","NcRichContenteditable","NcRichText","mixins","CommentMixin","inheritAttrs","actorDisplayName","actorId","creationDateTime","editor","Boolean","autoComplete","Function","userData","tag","expanded","submitted","isOwnComment","getCurrentUser","uid","richContent","mentions","keys","forEach","user","index","key","regex","RegExp","replace","component","NcUserBubble","displayName","label","primary","isEmptyMessage","trim","timestamp","Date","parse","isLimbo","checkForId","watch","beforeMount","toString","onSubmit","$nextTick","$refs","$el","focus","onExpand","defineStore","state","idsInLimbo","actions","indexOf","splice","includes","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","locals","decodeHtmlEntities","value","passes","arguments","length","undefined","parser","DOMParser","decoded","i","parseFromString","documentElement","textContent","resourcePath","response","axios","post","getRootPath","actorType","toUTCString","objectType","verb","parseInt","headers","split","pop","comment","stat","details","defineComponent","editorData","search","callback","get","generateOcsUrl","params","itemType","itemId","sorter","limit","loadState","ocs","values","genMentionsData","flat","mention","mentionId","icon","mentionDisplayName","source","deleteFile","render","_vm","_c","_self","directives","rawName","expression","staticClass","class","attrs","_v","_s","on","scopedSlots","_u","fn","proxy","_e","$event","preventDefault","ref","nativeOn","apply","staticRenderFns"],"sourceRoot":""} \ No newline at end of file diff --git a/dist/comments-comments-app.js b/dist/comments-comments-app.js index 93a56066f6d..871b09a8031 100644 --- a/dist/comments-comments-app.js +++ b/dist/comments-comments-app.js @@ -1,2 +1,2 @@ -(()=>{var e,n,o,s={36768:(t,e,n)=>{"use strict";n.d(e,{A:()=>r});var o=n(71354),s=n.n(o),i=n(76314),a=n.n(i)()(s());a.push([t.id,".comment[data-v-54060d57]{display:flex;gap:8px;padding:5px 10px}.comment__side[data-v-54060d57]{display:flex;align-items:flex-start;padding-top:6px}.comment__body[data-v-54060d57]{display:flex;flex-grow:1;flex-direction:column;container-type:inline-size}.comment__header[data-v-54060d57]{display:flex;align-items:center;min-height:44px}.comment__actions[data-v-54060d57]{margin-inline-start:10px !important}.comment__author[data-v-54060d57]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:var(--color-text-maxcontrast)}.comment_loading[data-v-54060d57],.comment__timestamp[data-v-54060d57]{margin-inline-start:auto;text-align:end;white-space:nowrap;color:var(--color-text-maxcontrast)}.comment__editor-group[data-v-54060d57]{position:relative}.comment__editor-description[data-v-54060d57]{color:var(--color-text-maxcontrast);padding-block:var(--default-grid-baseline)}.comment__submit[data-v-54060d57]{position:absolute !important;bottom:5px;inset-inline-end:0}.comment__message[data-v-54060d57]{white-space:pre-wrap;word-break:normal;max-height:70px;overflow:hidden;margin-top:-6px}.comment__message--expanded[data-v-54060d57]{max-height:none;overflow:visible}.rich-contenteditable__input[data-v-54060d57]{min-height:44px;margin:0;padding:10px}","",{version:3,sources:["webpack://./apps/comments/src/components/Comment.vue"],names:[],mappings:"AAKA,0BACC,YAAA,CACA,OAAA,CACA,gBAAA,CAEA,gCACC,YAAA,CACA,sBAAA,CACA,eAAA,CAGD,gCACC,YAAA,CACA,WAAA,CACA,qBAAA,CACA,0BAAA,CAGD,kCACC,YAAA,CACA,kBAAA,CACA,eAAA,CAGD,mCACC,mCAAA,CAGD,kCACC,eAAA,CACA,kBAAA,CACA,sBAAA,CACA,mCAAA,CAGD,uEAEC,wBAAA,CACA,cAAA,CACA,kBAAA,CACA,mCAAA,CAGD,wCACC,iBAAA,CAGD,8CACC,mCAAA,CACA,0CAAA,CAGD,kCACC,4BAAA,CACA,UAAA,CACA,kBAAA,CAGD,mCACC,oBAAA,CACA,iBAAA,CACA,eAAA,CACA,eAAA,CACA,eAAA,CACA,6CACC,eAAA,CACA,gBAAA,CAKH,8CACC,eAAA,CACA,QAAA,CACA,YA5EiB",sourcesContent:['\n@use "sass:math";\n\n$comment-padding: 10px;\n\n.comment {\n\tdisplay: flex;\n\tgap: 8px;\n\tpadding: 5px $comment-padding;\n\n\t&__side {\n\t\tdisplay: flex;\n\t\talign-items: flex-start;\n\t\tpadding-top: 6px;\n\t}\n\n\t&__body {\n\t\tdisplay: flex;\n\t\tflex-grow: 1;\n\t\tflex-direction: column;\n\t\tcontainer-type: inline-size;\n\t}\n\n\t&__header {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t\tmin-height: 44px;\n\t}\n\n\t&__actions {\n\t\tmargin-inline-start: $comment-padding !important;\n\t}\n\n\t&__author {\n\t\toverflow: hidden;\n\t\twhite-space: nowrap;\n\t\ttext-overflow: ellipsis;\n\t\tcolor: var(--color-text-maxcontrast);\n\t}\n\n\t&_loading,\n\t&__timestamp {\n\t\tmargin-inline-start: auto;\n\t\ttext-align: end;\n\t\twhite-space: nowrap;\n\t\tcolor: var(--color-text-maxcontrast);\n\t}\n\n\t&__editor-group {\n\t\tposition: relative;\n\t}\n\n\t&__editor-description {\n\t\tcolor: var(--color-text-maxcontrast);\n\t\tpadding-block: var(--default-grid-baseline);\n\t}\n\n\t&__submit {\n\t\tposition: absolute !important;\n\t\tbottom: 5px;\n\t\tinset-inline-end: 0;\n\t}\n\n\t&__message {\n\t\twhite-space: pre-wrap;\n\t\tword-break: normal;\n\t\tmax-height: 70px;\n\t\toverflow: hidden;\n\t\tmargin-top: -6px;\n\t\t&--expanded {\n\t\t\tmax-height: none;\n\t\t\toverflow: visible;\n\t\t}\n\t}\n}\n\n.rich-contenteditable__input {\n\tmin-height: 44px;\n\tmargin: 0;\n\tpadding: $comment-padding;\n}\n\n'],sourceRoot:""}]);const r=a},42634:()=>{},59169:()=>{},63779:()=>{},68049:(t,e,n)=>{"use strict";n.d(e,{A:()=>r});var o=n(71354),s=n.n(o),i=n(76314),a=n.n(i)()(s());a.push([t.id,".comments[data-v-fbac7ea2]{min-height:100%;display:flex;flex-direction:column}.comments__empty[data-v-fbac7ea2],.comments__error[data-v-fbac7ea2]{flex:1 0}.comments__retry[data-v-fbac7ea2]{margin:0 auto}.comments__info[data-v-fbac7ea2]{height:60px;color:var(--color-text-maxcontrast);text-align:center;line-height:60px}","",{version:3,sources:["webpack://./apps/comments/src/views/Comments.vue"],names:[],mappings:"AACA,2BACC,eAAA,CACA,YAAA,CACA,qBAAA,CAEA,oEAEC,QAAA,CAGD,kCACC,aAAA,CAGD,iCACC,WAAA,CACA,mCAAA,CACA,iBAAA,CACA,gBAAA",sourcesContent:["\n.comments {\n\tmin-height: 100%;\n\tdisplay: flex;\n\tflex-direction: column;\n\n\t&__empty,\n\t&__error {\n\t\tflex: 1 0;\n\t}\n\n\t&__retry {\n\t\tmargin: 0 auto;\n\t}\n\n\t&__info {\n\t\theight: 60px;\n\t\tcolor: var(--color-text-maxcontrast);\n\t\ttext-align: center;\n\t\tline-height: 60px;\n\t}\n}\n"],sourceRoot:""}]);const r=a},77199:()=>{},81873:(e,n,o)=>{"use strict";var s=o(21777),i=o(53334),a=o(65899),r=o(85471),c=o(85168),l=o(55042),m=o(11275),d=o(74095);const u={name:"RefreshIcon",emits:["click"],props:{title:{type:String},fillColor:{type:String,default:"currentColor"},size:{type:Number,default:24}}};var p=o(14486);const A=(0,p.A)(u,function(){var t=this,e=t._self._c;return e("span",t._b({staticClass:"material-design-icon refresh-icon",attrs:{"aria-hidden":t.title?null:"true","aria-label":t.title,role:"img"},on:{click:function(e){return t.$emit("click",e)}}},"span",t.$attrs,!1),[e("svg",{staticClass:"material-design-icon__svg",attrs:{fill:t.fillColor,width:t.size,height:t.size,viewBox:"0 0 24 24"}},[e("path",{attrs:{d:"M17.65,6.35C16.2,4.9 14.21,4 12,4A8,8 0 0,0 4,12A8,8 0 0,0 12,20C15.73,20 18.84,17.45 19.73,14H17.65C16.83,16.33 14.61,18 12,18A6,6 0 0,1 6,12A6,6 0 0,1 12,6C13.66,6 15.14,6.69 16.22,7.78L13,11H20V4L17.65,6.35Z"}},[t.title?e("title",[t._v(t._s(t.title))]):t._e()])])])},[],!1,null,null,null).exports,h={name:"MessageReplyTextOutlineIcon",emits:["click"],props:{title:{type:String},fillColor:{type:String,default:"currentColor"},size:{type:Number,default:24}}},g=(0,p.A)(h,function(){var t=this,e=t._self._c;return e("span",t._b({staticClass:"material-design-icon message-reply-text-outline-icon",attrs:{"aria-hidden":t.title?null:"true","aria-label":t.title,role:"img"},on:{click:function(e){return t.$emit("click",e)}}},"span",t.$attrs,!1),[e("svg",{staticClass:"material-design-icon__svg",attrs:{fill:t.fillColor,width:t.size,height:t.size,viewBox:"0 0 24 24"}},[e("path",{attrs:{d:"M9 11H18V13H9V11M18 7H6V9H18V7M22 4V22L18 18H4C2.9 18 2 17.11 2 16V4C2 2.9 2.9 2 4 2H20C21.1 2 22 2.89 22 4M20 4H4V16H18.83L20 17.17V4Z"}},[t.title?e("title",[t._v(t._s(t.title))]):t._e()])])])},[],!1,null,null,null).exports;var C=o(57578),f=o(57505),y=o(24764),_=o(15502),v=o(41944),b=o(4604),x=o(88289),w=o(77764),I=o(33691),T=o(66001),k=o(37793),D=o(16502),N=o(63814);const S=function(){return(0,N.dC)("dav/comments")};function O(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;const n=new DOMParser;let o=t;for(let t=0;t{B.setHeaders({"X-Requested-With":"XMLHttpRequest",requesttoken:t??""})};(0,s.zo)(M),M((0,s.do)());const L=B,$=(0,a.nY)("deletedCommentLimbo",{state:()=>({idsInLimbo:[]}),actions:{addId(t){this.idsInLimbo.push(t)},removeId(t){const e=this.idsInLimbo.indexOf(t);e>-1&&this.idsInLimbo.splice(e,1)},checkForId(t){this.idsInLimbo.includes(t)}}}),j=(0,o(35947).YK)().setApp("comments").detectUser().build(),P={props:{id:{type:Number,default:null},message:{type:String,default:""},resourceId:{type:[String,Number],required:!0},resourceType:{type:String,default:"files"}},data:()=>({deleted:!1,editing:!1,loading:!1}),computed:{...(0,a.n2)($)},methods:{onEdit(){this.editing=!0},onEditCancel(){this.editing=!1,this.updateLocalMessage(this.message)},async onEditComment(e){this.loading=!0;try{await async function(t,e,n,o){const s=["",t,e,n].join("/");return await L.customRequest(s,Object.assign({method:"PROPPATCH",data:`\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t${o}\n\t\t\t\t\n\t\t\t\n\t\t\t`}))}(this.resourceType,this.resourceId,this.id,e),j.debug("Comment edited",{resourceType:this.resourceType,resourceId:this.resourceId,id:this.id,message:e}),this.$emit("update:message",e),this.editing=!1}catch(e){(0,c.Qg)(t("comments","An error occurred while trying to edit the comment")),console.error(e)}finally{this.loading=!1}},onDeleteWithUndo(){this.$emit("delete"),this.deleted=!0,this.deletedCommentLimboStore.addId(this.id);const e=setTimeout(this.onDelete,c.Br);(0,c._h)(t("comments","Comment deleted"),()=>{clearTimeout(e),this.deleted=!1,this.deletedCommentLimboStore.removeId(this.id)})},async onDelete(){try{await async function(t,e,n){const o=["",t,e,n].join("/");await L.deleteFile(o)}(this.resourceType,this.resourceId,this.id),j.debug("Comment deleted",{resourceType:this.resourceType,resourceId:this.resourceId,id:this.id}),this.$emit("delete",this.id)}catch(e){(0,c.Qg)(t("comments","An error occurred while trying to delete the comment")),console.error(e),this.deleted=!1,this.deletedCommentLimboStore.removeId(this.id)}},async onNewComment(e){this.loading=!0;try{const t=await async function(t,e,n){const o=["",t,e].join("/"),i=await E.Ay.post(S()+o,{actorDisplayName:(0,s.HW)().displayName,actorId:(0,s.HW)().uid,actorType:"users",creationDateTime:(new Date).toUTCString(),message:n,objectType:t,verb:"comment"}),a=o+"/"+parseInt(i.headers["content-location"].split("/").pop()),r=await L.stat(a,{details:!0}),c=r.data.props;return c.actorDisplayName=O(c.actorDisplayName,2),c.message=O(c.message,2),r.data}(this.resourceType,this.resourceId,e);j.debug("New comment posted",{resourceType:this.resourceType,resourceId:this.resourceId,newComment:t}),this.$emit("new",t),this.$emit("update:message",""),this.localMessage=""}catch(e){(0,c.Qg)(t("comments","An error occurred while trying to create the comment")),console.error(e)}finally{this.loading=!1}}}},H={name:"Comment",components:{IconArrowRight:I.A,IconClose:T.A,IconTrashCanOutline:k.A,IconPencilOutline:D.A,NcActionButton:f.A,NcActions:y.A,NcActionSeparator:_.A,NcAvatar:v.A,NcButton:d.A,NcDateTime:b.A,NcLoadingIcon:x.A,NcRichContenteditable:()=>Promise.all([o.e(4208),o.e(7838),o.e(5258)]).then(o.bind(o,95528)),NcRichText:()=>Promise.all([o.e(4208),o.e(7838),o.e(4508)]).then(o.bind(o,64508))},mixins:[P],inheritAttrs:!1,props:{actorDisplayName:{type:String,required:!0},actorId:{type:String,required:!0},creationDateTime:{type:String,default:null},editor:{type:Boolean,default:!1},autoComplete:{type:Function,required:!0},userData:{type:Object,default:()=>({})},tag:{type:String,default:"div"}},data:()=>({expanded:!1,localMessage:"",submitted:!1}),computed:{...(0,a.n2)($),isOwnComment(){return(0,s.HW)().uid===this.actorId},richContent(){const t={};let e=this.localMessage;return Object.keys(this.userData).forEach((n,o)=>{const s=`mention-${o}`,i=new RegExp(`@${n}|@"${n}"`,"g");e=e.replace(i,`{${s}}`),t[s]={component:w.A,props:{user:n,displayName:this.userData[n].label,primary:this.userData[n].primary}}}),{mentions:t,message:e}},isEmptyMessage(){return!this.localMessage||""===this.localMessage.trim()},timestamp(){return Date.parse(this.creationDateTime)},isLimbo(){return this.deletedCommentLimboStore.checkForId(this.id)}},watch:{message(t){this.updateLocalMessage(t)}},beforeMount(){this.updateLocalMessage(this.message)},methods:{t:i.Tl,updateLocalMessage(t){this.localMessage=t.toString(),this.submitted=!1},onSubmit(){if(""!==this.localMessage.trim())return this.editor?(this.onNewComment(this.localMessage.trim()),void this.$nextTick(()=>{this.$refs.editor.$el.focus()})):void this.onEditComment(this.localMessage.trim())},onExpand(){this.expanded=!0}}};var q=o(85072),V=o.n(q),z=o(97825),W=o.n(z),F=o(77659),G=o.n(F),U=o(55056),Y=o.n(U),Q=o(10540),K=o.n(Q),Z=o(41113),X=o.n(Z),J=o(36768),tt={};tt.styleTagTransform=X(),tt.setAttributes=Y(),tt.insert=G().bind(null,"head"),tt.domAPI=W(),tt.insertStyleElement=K(),V()(J.A,tt),J.A&&J.A.locals&&J.A.locals;const et=(0,p.A)(H,function(){var t=this,e=t._self._c;return e(t.tag,{directives:[{name:"show",rawName:"v-show",value:!t.deleted&&!t.isLimbo,expression:"!deleted && !isLimbo"}],tag:"component",staticClass:"comment",class:{"comment--loading":t.loading}},[e("div",{staticClass:"comment__side"},[e("NcAvatar",{staticClass:"comment__avatar",attrs:{"display-name":t.actorDisplayName,user:t.actorId,size:32}})],1),t._v(" "),e("div",{staticClass:"comment__body"},[e("div",{staticClass:"comment__header"},[e("span",{staticClass:"comment__author"},[t._v(t._s(t.actorDisplayName))]),t._v(" "),t.isOwnComment&&t.id&&!t.loading?e("NcActions",{staticClass:"comment__actions"},[t.editing?e("NcActionButton",{on:{click:t.onEditCancel},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconClose",{attrs:{size:20}})]},proxy:!0}],null,!1,2888946197)},[t._v("\n\t\t\t\t\t"+t._s(t.t("comments","Cancel edit"))+"\n\t\t\t\t")]):[e("NcActionButton",{attrs:{"close-after-click":""},on:{click:t.onEdit},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconPencilOutline",{attrs:{size:20}})]},proxy:!0}],null,!1,3345211262)},[t._v("\n\t\t\t\t\t\t"+t._s(t.t("comments","Edit comment"))+"\n\t\t\t\t\t")]),t._v(" "),e("NcActionSeparator"),t._v(" "),e("NcActionButton",{attrs:{"close-after-click":""},on:{click:t.onDeleteWithUndo},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconTrashCanOutline",{attrs:{size:20}})]},proxy:!0}],null,!1,1034796883)},[t._v("\n\t\t\t\t\t\t"+t._s(t.t("comments","Delete comment"))+"\n\t\t\t\t\t")])]],2):t._e(),t._v(" "),t.id&&t.loading?e("div",{staticClass:"comment_loading icon-loading-small"}):t.creationDateTime?e("NcDateTime",{staticClass:"comment__timestamp",attrs:{timestamp:t.timestamp,"ignore-seconds":!0}}):t._e()],1),t._v(" "),t.editor||t.editing?e("form",{staticClass:"comment__editor",on:{submit:function(t){t.preventDefault()}}},[e("div",{staticClass:"comment__editor-group"},[e("NcRichContenteditable",{ref:"editor",attrs:{"auto-complete":t.autoComplete,contenteditable:!t.loading,label:t.editor?t.t("comments","New comment"):t.t("comments","Edit comment"),placeholder:t.t("comments","Write a comment …"),value:t.localMessage,"user-data":t.userData,"aria-describedby":"tab-comments__editor-description"},on:{"update:value":t.updateLocalMessage,submit:t.onSubmit}}),t._v(" "),e("div",{staticClass:"comment__submit"},[e("NcButton",{attrs:{type:"tertiary-no-background","native-type":"submit","aria-label":t.t("comments","Post comment"),disabled:t.isEmptyMessage},on:{click:t.onSubmit},scopedSlots:t._u([{key:"icon",fn:function(){return[t.loading?e("NcLoadingIcon"):e("IconArrowRight",{attrs:{size:20}})]},proxy:!0}],null,!1,758946661)})],1)],1),t._v(" "),e("div",{staticClass:"comment__editor-description",attrs:{id:"tab-comments__editor-description"}},[t._v("\n\t\t\t\t"+t._s(t.t("comments","@ for mentions, : for emoji, / for smart picker"))+"\n\t\t\t")])]):e("NcRichText",{staticClass:"comment__message",class:{"comment__message--expanded":t.expanded},attrs:{text:t.richContent.message,arguments:t.richContent.mentions},on:{click:t.onExpand}})],1)])},[],!1,null,"54060d57",null).exports;var nt=o(81222);const ot=(0,r.pM)({props:{resourceId:{type:Number,required:!0},resourceType:{type:String,default:"files"}},data:()=>({editorData:{actorDisplayName:(0,s.HW)().displayName,actorId:(0,s.HW)().uid,key:"editor"},userData:{}}),methods:{async autoComplete(t,e){const{data:n}=await E.Ay.get((0,N.KT)("core/autocomplete/get"),{params:{search:t,itemType:"files",itemId:this.resourceId,sorter:"commenters|share-recipients",limit:(0,nt.C)("comments","maxAutoCompleteResults")}});return n.ocs.data.forEach(t=>{this.userData[t.id]=t}),e(Object.values(this.userData))},genMentionsData(t){return Object.values(t).flat().forEach(t=>{this.userData[t.mentionId]={icon:"icon-user",id:t.mentionId,label:t.mentionDisplayName,source:"users",primary:(0,s.HW)()?.uid===t.mentionId}}),this.userData}}});var st=o(54290),it=o(90176);const at=async function(t,e){let{resourceType:n,resourceId:o}=t;const s=["",n,o].join("/"),i=e.datetime?`${e.datetime.toISOString()}`:"",a=await L.customRequest(s,Object.assign({method:"REPORT",data:`\n\t\t\t\n\t\t\t\t${e.limit??20}\n\t\t\t\t${e.offset||0}\n\t\t\t\t${i}\n\t\t\t`},e)),r=await a.text(),c=await(0,R.h4)(r),l=rt(c,!0);return(0,st.hq)(a,l,!0)},rt=function(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const{multistatus:{response:n}}=t;return n.map(t=>{const n=t.propstat.prop;return(0,it.ch)(n,n.id.toString(),e)})},ct={name:"Comments",components:{Comment:et,NcEmptyContent:m.A,NcButton:d.A,IconRefresh:A,IconMessageReplyTextOutline:g,IconAlertCircleOutline:C.A},directives:{elementVisibility:l.Zx},mixins:[ot],data(){return{error:"",loading:!1,done:!1,currentResourceId:this.resourceId,offset:0,comments:[],cancelRequest:()=>{},Comment:et,userData:{}}},computed:{hasComments(){return this.comments.length>0},isFirstLoading(){return this.loading&&0===this.offset}},watch:{resourceId(){this.currentResourceId=this.resourceId}},methods:{t:i.Tl,async onVisibilityChange(t){if(t)try{await((t,e,n)=>{const o=["",t,e].join("/"),s=n.toUTCString();return L.customRequest(o,{method:"PROPPATCH",data:`\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t${s}\n\t\t\t\t\n\t\t\t\n\t\t\t`})})(this.resourceType,this.currentResourceId,new Date)}catch(t){(0,c.Qg)(t.message||(0,i.Tl)("comments","Failed to mark comments as read"))}},async update(t){this.currentResourceId=t,this.resetState(),this.getComments()},onScrollBottomReached(){this.error||this.done||this.loading||this.getComments()},async getComments(){this.cancelRequest("cancel");try{this.loading=!0,this.error="";const{request:t,abort:e}=function(t){const e=new AbortController,n=e.signal;return{request:async function(e,o){return await t(e,Object.assign({signal:n},o))},abort:()=>e.abort()}}(at);this.cancelRequest=e;const{data:n}=await t({resourceType:this.resourceType,resourceId:this.currentResourceId},{offset:this.offset})||{data:[]};this.logger.debug(`Processed ${n.length} comments`,{comments:n}),n.length<20&&(this.done=!0),this.comments.push(...n),this.offset+=20}catch(t){if("cancel"===t.message)return;this.error=(0,i.Tl)("comments","Unable to load the comments list"),console.error("Error loading the comments list",t)}finally{this.loading=!1}},onNewComment(t){this.comments.unshift(t)},onDelete(t){const e=this.comments.findIndex(e=>e.props.id===t);e>-1?this.comments.splice(e,1):console.error("Could not find the deleted comment in the list",t)},resetState(){this.error="",this.loading=!1,this.done=!1,this.offset=0,this.comments=[]}}};var lt=o(68049),mt={};mt.styleTagTransform=X(),mt.setAttributes=Y(),mt.insert=G().bind(null,"head"),mt.domAPI=W(),mt.insertStyleElement=K(),V()(lt.A,mt),lt.A&<.A.locals&<.A.locals;const dt=(0,p.A)(ct,function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"element-visibility",rawName:"v-element-visibility",value:t.onVisibilityChange,expression:"onVisibilityChange"}],staticClass:"comments",class:{"icon-loading":t.isFirstLoading}},[e("Comment",t._b({staticClass:"comments__writer",attrs:{"auto-complete":t.autoComplete,"resource-type":t.resourceType,editor:!0,"user-data":t.userData,"resource-id":t.currentResourceId},on:{new:t.onNewComment}},"Comment",t.editorData,!1)),t._v(" "),t.isFirstLoading?t._e():[!t.hasComments&&t.done?e("NcEmptyContent",{staticClass:"comments__empty",attrs:{name:t.t("comments","No comments yet, start the conversation!")},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconMessageReplyTextOutline")]},proxy:!0}],null,!1,326612300)}):e("ul",t._l(t.comments,function(n){return e("Comment",t._b({key:n.props.id,staticClass:"comments__list",attrs:{tag:"li","auto-complete":t.autoComplete,"resource-type":t.resourceType,message:n.props.message,"resource-id":t.currentResourceId,"user-data":t.genMentionsData(n.props.mentions)},on:{"update:message":function(e){return t.$set(n.props,"message",e)},delete:t.onDelete}},"Comment",n.props,!1))}),1),t._v(" "),t.loading&&!t.isFirstLoading?e("div",{staticClass:"comments__info icon-loading"}):t.hasComments&&t.done?e("div",{staticClass:"comments__info"},[t._v("\n\t\t\t"+t._s(t.t("comments","No more messages"))+"\n\t\t")]):t.error?[e("NcEmptyContent",{staticClass:"comments__error",attrs:{name:t.error},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconAlertCircleOutline")]},proxy:!0}],null,!1,3663249556)}),t._v(" "),e("NcButton",{staticClass:"comments__retry",on:{click:t.getComments},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconRefresh")]},proxy:!0}],null,!1,2997625269)},[t._v("\n\t\t\t\t"+t._s(t.t("comments","Retry"))+"\n\t\t\t")])]:t._e()]],2)},[],!1,null,"fbac7ea2",null).exports;r.Ay.use(a.R2),o.nc=(0,s.aV)(),r.Ay.mixin({data:()=>({logger:j}),methods:{t:i.t,n:i.n}}),window.OCA&&!window.OCA.Comments&&Object.assign(window.OCA,{Comments:{}}),Object.assign(window.OCA.Comments,{View:class{constructor(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"files",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n=(0,a.Ey)();return e={...e,propsData:{...e.propsData??{},resourceType:t},pinia:n},new(r.Ay.extend(dt))(e)}}}),console.debug("OCA.Comments.View initialized")},86833:()=>{}},i={};function a(t){var e=i[t];if(void 0!==e)return e.exports;var n=i[t]={id:t,loaded:!1,exports:{}};return s[t].call(n.exports,n,n.exports,a),n.loaded=!0,n.exports}a.m=s,e=[],a.O=(t,n,o,s)=>{if(!n){var i=1/0;for(m=0;m=s)&&Object.keys(a.O).every(t=>a.O[t](n[c]))?n.splice(c--,1):(r=!1,s0&&e[m-1][2]>s;m--)e[m]=e[m-1];e[m]=[n,o,s]},a.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return a.d(e,{a:e}),e},a.d=(t,e)=>{for(var n in e)a.o(e,n)&&!a.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},a.f={},a.e=t=>Promise.all(Object.keys(a.f).reduce((e,n)=>(a.f[n](t,e),e),[])),a.u=t=>t+"-"+t+".js?v="+{640:"d4c5c018803ee8751b2a",780:"e3ee44fa7690af29d8d7",3564:"29e8338d43e0d4bd3995",4508:"40b53e5d2d42025bc3a7",5258:"80a9b9a289e4eb695373",5810:"b550a24d46f75f92c2d5",5862:"8bc76a21d9622c29e1a9",7471:"6423b9b898ffefeb7d1d",7838:"37c7bd8d5fada1bd542c"}[t],a.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),a.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n={},o="nextcloud:",a.l=(t,e,s,i)=>{if(n[t])n[t].push(e);else{var r,c;if(void 0!==s)for(var l=document.getElementsByTagName("script"),m=0;m{r.onerror=r.onload=null,clearTimeout(p);var s=n[t];if(delete n[t],r.parentNode&&r.parentNode.removeChild(r),s&&s.forEach(t=>t(o)),e)return e(o)},p=setTimeout(u.bind(null,void 0,{type:"timeout",target:r}),12e4);r.onerror=u.bind(null,r.onerror),r.onload=u.bind(null,r.onload),c&&document.head.appendChild(r)}},a.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},a.nmd=t=>(t.paths=[],t.children||(t.children=[]),t),a.j=7062,(()=>{var t;a.g.importScripts&&(t=a.g.location+"");var e=a.g.document;if(!t&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(t=e.currentScript.src),!t)){var n=e.getElementsByTagName("script");if(n.length)for(var o=n.length-1;o>-1&&(!t||!/^http(s?):/.test(t));)t=n[o--].src}if(!t)throw new Error("Automatic publicPath is not supported in this browser");t=t.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),a.p=t})(),(()=>{a.b=document.baseURI||self.location.href;var t={7062:0};a.f.j=(e,n)=>{var o=a.o(t,e)?t[e]:void 0;if(0!==o)if(o)n.push(o[2]);else{var s=new Promise((n,s)=>o=t[e]=[n,s]);n.push(o[2]=s);var i=a.p+a.u(e),r=new Error;a.l(i,n=>{if(a.o(t,e)&&(0!==(o=t[e])&&(t[e]=void 0),o)){var s=n&&("load"===n.type?"missing":n.type),i=n&&n.target&&n.target.src;r.message="Loading chunk "+e+" failed.\n("+s+": "+i+")",r.name="ChunkLoadError",r.type=s,r.request=i,o[1](r)}},"chunk-"+e,e)}},a.O.j=e=>0===t[e];var e=(e,n)=>{var o,s,i=n[0],r=n[1],c=n[2],l=0;if(i.some(e=>0!==t[e])){for(o in r)a.o(r,o)&&(a.m[o]=r[o]);if(c)var m=c(a)}for(e&&e(n);la(81873));r=a.O(r)})(); -//# sourceMappingURL=comments-comments-app.js.map?v=efb62f69f1b06e9dee11 \ No newline at end of file +(()=>{var e,n,o,s={1554:(t,e,n)=>{"use strict";n.d(e,{A:()=>r});var o=n(71354),s=n.n(o),i=n(76314),a=n.n(i)()(s());a.push([t.id,".comment[data-v-3cab0376]{display:flex;gap:8px;padding:5px 10px}.comment__side[data-v-3cab0376]{display:flex;align-items:flex-start;padding-top:6px}.comment__body[data-v-3cab0376]{display:flex;flex-grow:1;flex-direction:column;container-type:inline-size}.comment__header[data-v-3cab0376]{display:flex;align-items:center;min-height:44px}.comment__actions[data-v-3cab0376]{margin-inline-start:10px !important}.comment__author[data-v-3cab0376]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:var(--color-text-maxcontrast)}.comment_loading[data-v-3cab0376],.comment__timestamp[data-v-3cab0376]{margin-inline-start:auto;text-align:end;white-space:nowrap;color:var(--color-text-maxcontrast)}.comment__editor-group[data-v-3cab0376]{position:relative}.comment__editor-description[data-v-3cab0376]{color:var(--color-text-maxcontrast);padding-block:var(--default-grid-baseline)}.comment__submit[data-v-3cab0376]{position:absolute !important;bottom:5px;inset-inline-end:0}.comment__message[data-v-3cab0376]{white-space:pre-wrap;word-break:normal;max-height:70px;overflow:hidden;margin-top:-6px}.comment__message--expanded[data-v-3cab0376]{max-height:none;overflow:visible}.rich-contenteditable__input[data-v-3cab0376]{min-height:44px;margin:0;padding:10px}","",{version:3,sources:["webpack://./apps/comments/src/components/Comment.vue"],names:[],mappings:"AAKA,0BACC,YAAA,CACA,OAAA,CACA,gBAAA,CAEA,gCACC,YAAA,CACA,sBAAA,CACA,eAAA,CAGD,gCACC,YAAA,CACA,WAAA,CACA,qBAAA,CACA,0BAAA,CAGD,kCACC,YAAA,CACA,kBAAA,CACA,eAAA,CAGD,mCACC,mCAAA,CAGD,kCACC,eAAA,CACA,kBAAA,CACA,sBAAA,CACA,mCAAA,CAGD,uEAEC,wBAAA,CACA,cAAA,CACA,kBAAA,CACA,mCAAA,CAGD,wCACC,iBAAA,CAGD,8CACC,mCAAA,CACA,0CAAA,CAGD,kCACC,4BAAA,CACA,UAAA,CACA,kBAAA,CAGD,mCACC,oBAAA,CACA,iBAAA,CACA,eAAA,CACA,eAAA,CACA,eAAA,CACA,6CACC,eAAA,CACA,gBAAA,CAKH,8CACC,eAAA,CACA,QAAA,CACA,YA5EiB",sourcesContent:['\n@use "sass:math";\n\n$comment-padding: 10px;\n\n.comment {\n\tdisplay: flex;\n\tgap: 8px;\n\tpadding: 5px $comment-padding;\n\n\t&__side {\n\t\tdisplay: flex;\n\t\talign-items: flex-start;\n\t\tpadding-top: 6px;\n\t}\n\n\t&__body {\n\t\tdisplay: flex;\n\t\tflex-grow: 1;\n\t\tflex-direction: column;\n\t\tcontainer-type: inline-size;\n\t}\n\n\t&__header {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t\tmin-height: 44px;\n\t}\n\n\t&__actions {\n\t\tmargin-inline-start: $comment-padding !important;\n\t}\n\n\t&__author {\n\t\toverflow: hidden;\n\t\twhite-space: nowrap;\n\t\ttext-overflow: ellipsis;\n\t\tcolor: var(--color-text-maxcontrast);\n\t}\n\n\t&_loading,\n\t&__timestamp {\n\t\tmargin-inline-start: auto;\n\t\ttext-align: end;\n\t\twhite-space: nowrap;\n\t\tcolor: var(--color-text-maxcontrast);\n\t}\n\n\t&__editor-group {\n\t\tposition: relative;\n\t}\n\n\t&__editor-description {\n\t\tcolor: var(--color-text-maxcontrast);\n\t\tpadding-block: var(--default-grid-baseline);\n\t}\n\n\t&__submit {\n\t\tposition: absolute !important;\n\t\tbottom: 5px;\n\t\tinset-inline-end: 0;\n\t}\n\n\t&__message {\n\t\twhite-space: pre-wrap;\n\t\tword-break: normal;\n\t\tmax-height: 70px;\n\t\toverflow: hidden;\n\t\tmargin-top: -6px;\n\t\t&--expanded {\n\t\t\tmax-height: none;\n\t\t\toverflow: visible;\n\t\t}\n\t}\n}\n\n.rich-contenteditable__input {\n\tmin-height: 44px;\n\tmargin: 0;\n\tpadding: $comment-padding;\n}\n\n'],sourceRoot:""}]);const r=a},42634:()=>{},59169:()=>{},63779:()=>{},68049:(t,e,n)=>{"use strict";n.d(e,{A:()=>r});var o=n(71354),s=n.n(o),i=n(76314),a=n.n(i)()(s());a.push([t.id,".comments[data-v-fbac7ea2]{min-height:100%;display:flex;flex-direction:column}.comments__empty[data-v-fbac7ea2],.comments__error[data-v-fbac7ea2]{flex:1 0}.comments__retry[data-v-fbac7ea2]{margin:0 auto}.comments__info[data-v-fbac7ea2]{height:60px;color:var(--color-text-maxcontrast);text-align:center;line-height:60px}","",{version:3,sources:["webpack://./apps/comments/src/views/Comments.vue"],names:[],mappings:"AACA,2BACC,eAAA,CACA,YAAA,CACA,qBAAA,CAEA,oEAEC,QAAA,CAGD,kCACC,aAAA,CAGD,iCACC,WAAA,CACA,mCAAA,CACA,iBAAA,CACA,gBAAA",sourcesContent:["\n.comments {\n\tmin-height: 100%;\n\tdisplay: flex;\n\tflex-direction: column;\n\n\t&__empty,\n\t&__error {\n\t\tflex: 1 0;\n\t}\n\n\t&__retry {\n\t\tmargin: 0 auto;\n\t}\n\n\t&__info {\n\t\theight: 60px;\n\t\tcolor: var(--color-text-maxcontrast);\n\t\ttext-align: center;\n\t\tline-height: 60px;\n\t}\n}\n"],sourceRoot:""}]);const r=a},77199:()=>{},86833:()=>{},93186:(e,n,o)=>{"use strict";var s=o(21777),i=o(53334),a=o(65899),r=o(85471),c=o(85168),l=o(55042),m=o(11275),d=o(74095);const u={name:"RefreshIcon",emits:["click"],props:{title:{type:String},fillColor:{type:String,default:"currentColor"},size:{type:Number,default:24}}};var p=o(14486);const A=(0,p.A)(u,function(){var t=this,e=t._self._c;return e("span",t._b({staticClass:"material-design-icon refresh-icon",attrs:{"aria-hidden":t.title?null:"true","aria-label":t.title,role:"img"},on:{click:function(e){return t.$emit("click",e)}}},"span",t.$attrs,!1),[e("svg",{staticClass:"material-design-icon__svg",attrs:{fill:t.fillColor,width:t.size,height:t.size,viewBox:"0 0 24 24"}},[e("path",{attrs:{d:"M17.65,6.35C16.2,4.9 14.21,4 12,4A8,8 0 0,0 4,12A8,8 0 0,0 12,20C15.73,20 18.84,17.45 19.73,14H17.65C16.83,16.33 14.61,18 12,18A6,6 0 0,1 6,12A6,6 0 0,1 12,6C13.66,6 15.14,6.69 16.22,7.78L13,11H20V4L17.65,6.35Z"}},[t.title?e("title",[t._v(t._s(t.title))]):t._e()])])])},[],!1,null,null,null).exports,h={name:"MessageReplyTextOutlineIcon",emits:["click"],props:{title:{type:String},fillColor:{type:String,default:"currentColor"},size:{type:Number,default:24}}},g=(0,p.A)(h,function(){var t=this,e=t._self._c;return e("span",t._b({staticClass:"material-design-icon message-reply-text-outline-icon",attrs:{"aria-hidden":t.title?null:"true","aria-label":t.title,role:"img"},on:{click:function(e){return t.$emit("click",e)}}},"span",t.$attrs,!1),[e("svg",{staticClass:"material-design-icon__svg",attrs:{fill:t.fillColor,width:t.size,height:t.size,viewBox:"0 0 24 24"}},[e("path",{attrs:{d:"M9 11H18V13H9V11M18 7H6V9H18V7M22 4V22L18 18H4C2.9 18 2 17.11 2 16V4C2 2.9 2.9 2 4 2H20C21.1 2 22 2.89 22 4M20 4H4V16H18.83L20 17.17V4Z"}},[t.title?e("title",[t._v(t._s(t.title))]):t._e()])])])},[],!1,null,null,null).exports;var C=o(57578),f=o(57505),y=o(24764),_=o(15502),v=o(41944),b=o(4604),x=o(88289),w=o(77764),I=o(33691),T=o(66001),k=o(37793),D=o(16502),N=o(63814);const S=function(){return(0,N.dC)("dav/comments")};function O(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;const n=new DOMParser;let o=t;for(let t=0;t{B.setHeaders({"X-Requested-With":"XMLHttpRequest",requesttoken:t??""})};(0,s.zo)(M),M((0,s.do)());const L=B,$=(0,a.nY)("deletedCommentLimbo",{state:()=>({idsInLimbo:[]}),actions:{addId(t){this.idsInLimbo.push(t)},removeId(t){const e=this.idsInLimbo.indexOf(t);e>-1&&this.idsInLimbo.splice(e,1)},checkForId(t){this.idsInLimbo.includes(t)}}}),j=(0,o(35947).YK)().setApp("comments").detectUser().build(),P={props:{id:{type:Number,default:null},message:{type:String,default:""},resourceId:{type:[String,Number],required:!0},resourceType:{type:String,default:"files"}},data:()=>({deleted:!1,editing:!1,loading:!1}),computed:{...(0,a.n2)($)},methods:{onEdit(){this.editing=!0},onEditCancel(){this.editing=!1,this.updateLocalMessage(this.message)},async onEditComment(e){this.loading=!0;try{await async function(t,e,n,o){const s=["",t,e,n].join("/");return await L.customRequest(s,Object.assign({method:"PROPPATCH",data:`\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t${o}\n\t\t\t\t\n\t\t\t\n\t\t\t`}))}(this.resourceType,this.resourceId,this.id,e),j.debug("Comment edited",{resourceType:this.resourceType,resourceId:this.resourceId,id:this.id,message:e}),this.$emit("update:message",e),this.editing=!1}catch(e){(0,c.Qg)(t("comments","An error occurred while trying to edit the comment")),console.error(e)}finally{this.loading=!1}},onDeleteWithUndo(){this.$emit("delete"),this.deleted=!0,this.deletedCommentLimboStore.addId(this.id);const e=setTimeout(this.onDelete,c.Br);(0,c._h)(t("comments","Comment deleted"),()=>{clearTimeout(e),this.deleted=!1,this.deletedCommentLimboStore.removeId(this.id)})},async onDelete(){try{await async function(t,e,n){const o=["",t,e,n].join("/");await L.deleteFile(o)}(this.resourceType,this.resourceId,this.id),j.debug("Comment deleted",{resourceType:this.resourceType,resourceId:this.resourceId,id:this.id}),this.$emit("delete",this.id)}catch(e){(0,c.Qg)(t("comments","An error occurred while trying to delete the comment")),console.error(e),this.deleted=!1,this.deletedCommentLimboStore.removeId(this.id)}},async onNewComment(e){this.loading=!0;try{const t=await async function(t,e,n){const o=["",t,e].join("/"),i=await E.Ay.post(S()+o,{actorDisplayName:(0,s.HW)().displayName,actorId:(0,s.HW)().uid,actorType:"users",creationDateTime:(new Date).toUTCString(),message:n,objectType:t,verb:"comment"}),a=o+"/"+parseInt(i.headers["content-location"].split("/").pop()),r=await L.stat(a,{details:!0}),c=r.data.props;return c.actorDisplayName=O(c.actorDisplayName,2),c.message=O(c.message,2),r.data}(this.resourceType,this.resourceId,e);j.debug("New comment posted",{resourceType:this.resourceType,resourceId:this.resourceId,newComment:t}),this.$emit("new",t),this.$emit("update:message",""),this.localMessage=""}catch(e){(0,c.Qg)(t("comments","An error occurred while trying to create the comment")),console.error(e)}finally{this.loading=!1}}}},H={name:"Comment",components:{IconArrowRight:I.A,IconClose:T.A,IconTrashCanOutline:k.A,IconPencilOutline:D.A,NcActionButton:f.A,NcActions:y.A,NcActionSeparator:_.A,NcAvatar:v.A,NcButton:d.A,NcDateTime:b.A,NcLoadingIcon:x.A,NcRichContenteditable:()=>Promise.all([o.e(4208),o.e(7838),o.e(5258)]).then(o.bind(o,95528)),NcRichText:()=>Promise.all([o.e(4208),o.e(7838),o.e(4508)]).then(o.bind(o,64508))},mixins:[P],inheritAttrs:!1,props:{actorDisplayName:{type:String,required:!0},actorId:{type:String,required:!0},creationDateTime:{type:String,default:null},editor:{type:Boolean,default:!1},autoComplete:{type:Function,required:!0},userData:{type:Object,default:()=>({})},tag:{type:String,default:"div"}},data:()=>({expanded:!1,localMessage:"",submitted:!1}),computed:{...(0,a.n2)($),isOwnComment(){return(0,s.HW)().uid===this.actorId},richContent(){const t={};let e=this.localMessage;return Object.keys(this.userData).forEach((n,o)=>{const s=`mention-${o}`,i=new RegExp(`@${n}|@"${n}"`,"g");e=e.replace(i,`{${s}}`),t[s]={component:w.A,props:{user:n,displayName:this.userData[n].label,primary:this.userData[n].primary}}}),{mentions:t,message:e}},isEmptyMessage(){return!this.localMessage||""===this.localMessage.trim()},timestamp(){return Date.parse(this.creationDateTime)},isLimbo(){return this.deletedCommentLimboStore.checkForId(this.id)}},watch:{message(t){this.updateLocalMessage(t)}},beforeMount(){this.updateLocalMessage(this.message)},methods:{t:i.Tl,updateLocalMessage(t){this.localMessage=t.toString(),this.submitted=!1},onSubmit(){if(""!==this.localMessage.trim())return this.editor?(this.onNewComment(this.localMessage.trim()),void this.$nextTick(()=>{this.$refs.editor.$el.focus()})):void this.onEditComment(this.localMessage.trim())},onExpand(){this.expanded=!0}}};var q=o(85072),V=o.n(q),z=o(97825),W=o.n(z),F=o(77659),G=o.n(F),U=o(55056),Y=o.n(U),Q=o(10540),K=o.n(Q),Z=o(41113),X=o.n(Z),J=o(1554),tt={};tt.styleTagTransform=X(),tt.setAttributes=Y(),tt.insert=G().bind(null,"head"),tt.domAPI=W(),tt.insertStyleElement=K(),V()(J.A,tt),J.A&&J.A.locals&&J.A.locals;const et=(0,p.A)(H,function(){var t=this,e=t._self._c;return e(t.tag,{directives:[{name:"show",rawName:"v-show",value:!t.deleted&&!t.isLimbo,expression:"!deleted && !isLimbo"}],tag:"component",staticClass:"comment",class:{"comment--loading":t.loading}},[e("div",{staticClass:"comment__side"},[e("NcAvatar",{staticClass:"comment__avatar",attrs:{"display-name":t.actorDisplayName,user:t.actorId,size:32}})],1),t._v(" "),e("div",{staticClass:"comment__body"},[e("div",{staticClass:"comment__header"},[e("span",{staticClass:"comment__author"},[t._v(t._s(t.actorDisplayName))]),t._v(" "),t.isOwnComment&&t.id&&!t.loading?e("NcActions",{staticClass:"comment__actions"},[t.editing?e("NcActionButton",{on:{click:t.onEditCancel},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconClose",{attrs:{size:20}})]},proxy:!0}],null,!1,2888946197)},[t._v("\n\t\t\t\t\t"+t._s(t.t("comments","Cancel edit"))+"\n\t\t\t\t")]):[e("NcActionButton",{attrs:{"close-after-click":""},on:{click:t.onEdit},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconPencilOutline",{attrs:{size:20}})]},proxy:!0}],null,!1,3345211262)},[t._v("\n\t\t\t\t\t\t"+t._s(t.t("comments","Edit comment"))+"\n\t\t\t\t\t")]),t._v(" "),e("NcActionSeparator"),t._v(" "),e("NcActionButton",{attrs:{"close-after-click":""},on:{click:t.onDeleteWithUndo},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconTrashCanOutline",{attrs:{size:20}})]},proxy:!0}],null,!1,1034796883)},[t._v("\n\t\t\t\t\t\t"+t._s(t.t("comments","Delete comment"))+"\n\t\t\t\t\t")])]],2):t._e(),t._v(" "),t.id&&t.loading?e("div",{staticClass:"comment_loading icon-loading-small"}):t.creationDateTime?e("NcDateTime",{staticClass:"comment__timestamp",attrs:{timestamp:t.timestamp,"ignore-seconds":!0}}):t._e()],1),t._v(" "),t.editor||t.editing?e("form",{staticClass:"comment__editor",on:{submit:function(t){t.preventDefault()}}},[e("div",{staticClass:"comment__editor-group"},[e("NcRichContenteditable",{ref:"editor",attrs:{"auto-complete":t.autoComplete,contenteditable:!t.loading,label:t.editor?t.t("comments","New comment"):t.t("comments","Edit comment"),placeholder:t.t("comments","Write a comment …"),value:t.localMessage,"user-data":t.userData,"aria-describedby":"tab-comments__editor-description"},on:{"update:value":t.updateLocalMessage,submit:t.onSubmit}}),t._v(" "),e("div",{staticClass:"comment__submit"},[e("NcButton",{attrs:{type:"tertiary-no-background","native-type":"submit","aria-label":t.t("comments","Post comment"),disabled:t.isEmptyMessage},on:{click:t.onSubmit},scopedSlots:t._u([{key:"icon",fn:function(){return[t.loading?e("NcLoadingIcon"):e("IconArrowRight",{attrs:{size:20}})]},proxy:!0}],null,!1,758946661)})],1)],1),t._v(" "),e("div",{staticClass:"comment__editor-description",attrs:{id:"tab-comments__editor-description"}},[t._v("\n\t\t\t\t"+t._s(t.t("comments","@ for mentions, : for emoji, / for smart picker"))+"\n\t\t\t")])]):e("NcRichText",{staticClass:"comment__message",class:{"comment__message--expanded":t.expanded},attrs:{text:t.richContent.message,arguments:t.richContent.mentions},nativeOn:{click:function(e){return t.onExpand.apply(null,arguments)}}})],1)])},[],!1,null,"3cab0376",null).exports;var nt=o(81222);const ot=(0,r.pM)({props:{resourceId:{type:Number,required:!0},resourceType:{type:String,default:"files"}},data:()=>({editorData:{actorDisplayName:(0,s.HW)().displayName,actorId:(0,s.HW)().uid,key:"editor"},userData:{}}),methods:{async autoComplete(t,e){const{data:n}=await E.Ay.get((0,N.KT)("core/autocomplete/get"),{params:{search:t,itemType:"files",itemId:this.resourceId,sorter:"commenters|share-recipients",limit:(0,nt.C)("comments","maxAutoCompleteResults")}});return n.ocs.data.forEach(t=>{this.userData[t.id]=t}),e(Object.values(this.userData))},genMentionsData(t){return Object.values(t).flat().forEach(t=>{this.userData[t.mentionId]={icon:"icon-user",id:t.mentionId,label:t.mentionDisplayName,source:"users",primary:(0,s.HW)()?.uid===t.mentionId}}),this.userData}}});var st=o(54290),it=o(90176);const at=async function(t,e){let{resourceType:n,resourceId:o}=t;const s=["",n,o].join("/"),i=e.datetime?`${e.datetime.toISOString()}`:"",a=await L.customRequest(s,Object.assign({method:"REPORT",data:`\n\t\t\t\n\t\t\t\t${e.limit??20}\n\t\t\t\t${e.offset||0}\n\t\t\t\t${i}\n\t\t\t`},e)),r=await a.text(),c=await(0,R.h4)(r),l=rt(c,!0);return(0,st.hq)(a,l,!0)},rt=function(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const{multistatus:{response:n}}=t;return n.map(t=>{const n=t.propstat.prop;return(0,it.ch)(n,n.id.toString(),e)})},ct={name:"Comments",components:{Comment:et,NcEmptyContent:m.A,NcButton:d.A,IconRefresh:A,IconMessageReplyTextOutline:g,IconAlertCircleOutline:C.A},directives:{elementVisibility:l.Zx},mixins:[ot],data(){return{error:"",loading:!1,done:!1,currentResourceId:this.resourceId,offset:0,comments:[],cancelRequest:()=>{},Comment:et,userData:{}}},computed:{hasComments(){return this.comments.length>0},isFirstLoading(){return this.loading&&0===this.offset}},watch:{resourceId(){this.currentResourceId=this.resourceId}},methods:{t:i.Tl,async onVisibilityChange(t){if(t)try{await((t,e,n)=>{const o=["",t,e].join("/"),s=n.toUTCString();return L.customRequest(o,{method:"PROPPATCH",data:`\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t${s}\n\t\t\t\t\n\t\t\t\n\t\t\t`})})(this.resourceType,this.currentResourceId,new Date)}catch(t){(0,c.Qg)(t.message||(0,i.Tl)("comments","Failed to mark comments as read"))}},async update(t){this.currentResourceId=t,this.resetState(),this.getComments()},onScrollBottomReached(){this.error||this.done||this.loading||this.getComments()},async getComments(){this.cancelRequest("cancel");try{this.loading=!0,this.error="";const{request:t,abort:e}=function(t){const e=new AbortController,n=e.signal;return{request:async function(e,o){return await t(e,Object.assign({signal:n},o))},abort:()=>e.abort()}}(at);this.cancelRequest=e;const{data:n}=await t({resourceType:this.resourceType,resourceId:this.currentResourceId},{offset:this.offset})||{data:[]};this.logger.debug(`Processed ${n.length} comments`,{comments:n}),n.length<20&&(this.done=!0),this.comments.push(...n),this.offset+=20}catch(t){if("cancel"===t.message)return;this.error=(0,i.Tl)("comments","Unable to load the comments list"),console.error("Error loading the comments list",t)}finally{this.loading=!1}},onNewComment(t){this.comments.unshift(t)},onDelete(t){const e=this.comments.findIndex(e=>e.props.id===t);e>-1?this.comments.splice(e,1):console.error("Could not find the deleted comment in the list",t)},resetState(){this.error="",this.loading=!1,this.done=!1,this.offset=0,this.comments=[]}}};var lt=o(68049),mt={};mt.styleTagTransform=X(),mt.setAttributes=Y(),mt.insert=G().bind(null,"head"),mt.domAPI=W(),mt.insertStyleElement=K(),V()(lt.A,mt),lt.A&<.A.locals&<.A.locals;const dt=(0,p.A)(ct,function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"element-visibility",rawName:"v-element-visibility",value:t.onVisibilityChange,expression:"onVisibilityChange"}],staticClass:"comments",class:{"icon-loading":t.isFirstLoading}},[e("Comment",t._b({staticClass:"comments__writer",attrs:{"auto-complete":t.autoComplete,"resource-type":t.resourceType,editor:!0,"user-data":t.userData,"resource-id":t.currentResourceId},on:{new:t.onNewComment}},"Comment",t.editorData,!1)),t._v(" "),t.isFirstLoading?t._e():[!t.hasComments&&t.done?e("NcEmptyContent",{staticClass:"comments__empty",attrs:{name:t.t("comments","No comments yet, start the conversation!")},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconMessageReplyTextOutline")]},proxy:!0}],null,!1,326612300)}):e("ul",t._l(t.comments,function(n){return e("Comment",t._b({key:n.props.id,staticClass:"comments__list",attrs:{tag:"li","auto-complete":t.autoComplete,"resource-type":t.resourceType,message:n.props.message,"resource-id":t.currentResourceId,"user-data":t.genMentionsData(n.props.mentions)},on:{"update:message":function(e){return t.$set(n.props,"message",e)},delete:t.onDelete}},"Comment",n.props,!1))}),1),t._v(" "),t.loading&&!t.isFirstLoading?e("div",{staticClass:"comments__info icon-loading"}):t.hasComments&&t.done?e("div",{staticClass:"comments__info"},[t._v("\n\t\t\t"+t._s(t.t("comments","No more messages"))+"\n\t\t")]):t.error?[e("NcEmptyContent",{staticClass:"comments__error",attrs:{name:t.error},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconAlertCircleOutline")]},proxy:!0}],null,!1,3663249556)}),t._v(" "),e("NcButton",{staticClass:"comments__retry",on:{click:t.getComments},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconRefresh")]},proxy:!0}],null,!1,2997625269)},[t._v("\n\t\t\t\t"+t._s(t.t("comments","Retry"))+"\n\t\t\t")])]:t._e()]],2)},[],!1,null,"fbac7ea2",null).exports;r.Ay.use(a.R2),o.nc=(0,s.aV)(),r.Ay.mixin({data:()=>({logger:j}),methods:{t:i.t,n:i.n}}),window.OCA&&!window.OCA.Comments&&Object.assign(window.OCA,{Comments:{}}),Object.assign(window.OCA.Comments,{View:class{constructor(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"files",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n=(0,a.Ey)();return e={...e,propsData:{...e.propsData??{},resourceType:t},pinia:n},new(r.Ay.extend(dt))(e)}}}),console.debug("OCA.Comments.View initialized")}},i={};function a(t){var e=i[t];if(void 0!==e)return e.exports;var n=i[t]={id:t,loaded:!1,exports:{}};return s[t].call(n.exports,n,n.exports,a),n.loaded=!0,n.exports}a.m=s,e=[],a.O=(t,n,o,s)=>{if(!n){var i=1/0;for(m=0;m=s)&&Object.keys(a.O).every(t=>a.O[t](n[c]))?n.splice(c--,1):(r=!1,s0&&e[m-1][2]>s;m--)e[m]=e[m-1];e[m]=[n,o,s]},a.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return a.d(e,{a:e}),e},a.d=(t,e)=>{for(var n in e)a.o(e,n)&&!a.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},a.f={},a.e=t=>Promise.all(Object.keys(a.f).reduce((e,n)=>(a.f[n](t,e),e),[])),a.u=t=>t+"-"+t+".js?v="+{640:"d4c5c018803ee8751b2a",780:"e3ee44fa7690af29d8d7",3564:"29e8338d43e0d4bd3995",4508:"40b53e5d2d42025bc3a7",5258:"80a9b9a289e4eb695373",5810:"b550a24d46f75f92c2d5",5862:"8bc76a21d9622c29e1a9",7471:"6423b9b898ffefeb7d1d",7838:"37c7bd8d5fada1bd542c"}[t],a.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),a.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n={},o="nextcloud:",a.l=(t,e,s,i)=>{if(n[t])n[t].push(e);else{var r,c;if(void 0!==s)for(var l=document.getElementsByTagName("script"),m=0;m{r.onerror=r.onload=null,clearTimeout(p);var s=n[t];if(delete n[t],r.parentNode&&r.parentNode.removeChild(r),s&&s.forEach(t=>t(o)),e)return e(o)},p=setTimeout(u.bind(null,void 0,{type:"timeout",target:r}),12e4);r.onerror=u.bind(null,r.onerror),r.onload=u.bind(null,r.onload),c&&document.head.appendChild(r)}},a.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},a.nmd=t=>(t.paths=[],t.children||(t.children=[]),t),a.j=7062,(()=>{var t;a.g.importScripts&&(t=a.g.location+"");var e=a.g.document;if(!t&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(t=e.currentScript.src),!t)){var n=e.getElementsByTagName("script");if(n.length)for(var o=n.length-1;o>-1&&(!t||!/^http(s?):/.test(t));)t=n[o--].src}if(!t)throw new Error("Automatic publicPath is not supported in this browser");t=t.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),a.p=t})(),(()=>{a.b=document.baseURI||self.location.href;var t={7062:0};a.f.j=(e,n)=>{var o=a.o(t,e)?t[e]:void 0;if(0!==o)if(o)n.push(o[2]);else{var s=new Promise((n,s)=>o=t[e]=[n,s]);n.push(o[2]=s);var i=a.p+a.u(e),r=new Error;a.l(i,n=>{if(a.o(t,e)&&(0!==(o=t[e])&&(t[e]=void 0),o)){var s=n&&("load"===n.type?"missing":n.type),i=n&&n.target&&n.target.src;r.message="Loading chunk "+e+" failed.\n("+s+": "+i+")",r.name="ChunkLoadError",r.type=s,r.request=i,o[1](r)}},"chunk-"+e,e)}},a.O.j=e=>0===t[e];var e=(e,n)=>{var o,s,i=n[0],r=n[1],c=n[2],l=0;if(i.some(e=>0!==t[e])){for(o in r)a.o(r,o)&&(a.m[o]=r[o]);if(c)var m=c(a)}for(e&&e(n);la(93186));r=a.O(r)})(); +//# sourceMappingURL=comments-comments-app.js.map?v=4980ed137948afb652fe \ No newline at end of file diff --git a/dist/comments-comments-app.js.map b/dist/comments-comments-app.js.map index edf90d4fb9d..f39406d31e0 100644 --- a/dist/comments-comments-app.js.map +++ b/dist/comments-comments-app.js.map @@ -1 +1 @@ -{"version":3,"file":"comments-comments-app.js?v=efb62f69f1b06e9dee11","mappings":"UAAIA,ECAAC,EACAC,E,oFCEAC,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,gvCAAivC,GAAG,CAAC,QAAU,EAAE,QAAU,CAAC,wDAAwD,MAAQ,GAAG,SAAW,keAAke,eAAiB,CAAC,w5CAA05C,WAAa,MAE9xG,S,0HCJIH,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,kUAAmU,GAAG,CAAC,QAAU,EAAE,QAAU,CAAC,oDAAoD,MAAQ,GAAG,SAAW,wHAAwH,eAAiB,CAAC,uTAAuT,WAAa,MAE/5B,S,wICaA,MCpB0G,EDoB1G,CACEC,KAAM,cACNC,MAAO,CAAC,SACRC,MAAO,CACLC,MAAO,CACLC,KAAMC,QAERC,UAAW,CACTF,KAAMC,OACNE,QAAS,gBAEXC,KAAM,CACJJ,KAAMK,OACNF,QAAS,M,eEff,SAXgB,OACd,ECRW,WAAkB,IAAIG,EAAIC,KAAKC,EAAGF,EAAIG,MAAMD,GAAG,OAAOA,EAAG,OAAOF,EAAII,GAAG,CAACC,YAAY,oCAAoCC,MAAM,CAAC,cAAcN,EAAIP,MAAQ,KAAO,OAAO,aAAaO,EAAIP,MAAM,KAAO,OAAOc,GAAG,CAAC,MAAQ,SAASC,GAAQ,OAAOR,EAAIS,MAAM,QAASD,EAAO,IAAI,OAAOR,EAAIU,QAAO,GAAO,CAACR,EAAG,MAAM,CAACG,YAAY,4BAA4BC,MAAM,CAAC,KAAON,EAAIJ,UAAU,MAAQI,EAAIF,KAAK,OAASE,EAAIF,KAAK,QAAU,cAAc,CAACI,EAAG,OAAO,CAACI,MAAM,CAAC,EAAI,uNAAuN,CAAEN,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EAAM4K,QAAUoH,EAChBL,EAAmB,GAAG3R,EACvB,GAGuC,SAAWmO,EAASA,EAE/D,GAYH1B,EAAoBQ,EAAEM,EAAKY,GAA0C,IAA7BuD,EAAgBvD,GAGxD,IAAI8D,EAAuB,CAACC,EAA4BxT,KACvD,IAKIgO,EAAUyB,EALVjB,EAAWxO,EAAK,GAChByT,EAAczT,EAAK,GACnB0T,EAAU1T,EAAK,GAGI/B,EAAI,EAC3B,GAAGuQ,EAASmF,KAAM9X,GAAgC,IAAxBmX,EAAgBnX,IAAa,CACtD,IAAImS,KAAYyF,EACZ1F,EAAoBsB,EAAEoE,EAAazF,KACrCD,EAAoBO,EAAEN,GAAYyF,EAAYzF,IAGhD,GAAG0F,EAAS,IAAI1J,EAAS0J,EAAQ3F,EAClC,CAEA,IADGyF,GAA4BA,EAA2BxT,GACrD/B,EAAIuQ,EAAS5Q,OAAQK,IACzBwR,EAAUjB,EAASvQ,GAChB8P,EAAoBsB,EAAE2D,EAAiBvD,IAAYuD,EAAgBvD,IACrEuD,EAAgBvD,GAAS,KAE1BuD,EAAgBvD,GAAW,EAE5B,OAAO1B,EAAoBQ,EAAEvE,IAG1B4J,EAAqBd,KAA4B,sBAAIA,KAA4B,uBAAK,GAC1Fc,EAAmBjO,QAAQ4N,EAAqB7B,KAAK,KAAM,IAC3DkC,EAAmBjY,KAAO4X,EAAqB7B,KAAK,KAAMkC,EAAmBjY,KAAK+V,KAAKkC,G,KCvFvF7F,EAAoBgD,QAAKlT,ECGzB,IAAIgW,EAAsB9F,EAAoBQ,OAAE1Q,EAAW,CAAC,MAAO,IAAOkQ,EAAoB,QAC9F8F,EAAsB9F,EAAoBQ,EAAEsF,E","sources":["webpack:///nextcloud/webpack/runtime/chunk loaded","webpack:///nextcloud/webpack/runtime/load script","webpack:///nextcloud/apps/comments/src/components/Comment.vue?vue&type=style&index=0&id=54060d57&prod&lang=scss&scoped=true","webpack:///nextcloud/apps/comments/src/views/Comments.vue?vue&type=style&index=0&id=fbac7ea2&prod&lang=scss&scoped=true","webpack:///nextcloud/node_modules/vue-material-design-icons/Refresh.vue","webpack:///nextcloud/node_modules/vue-material-design-icons/Refresh.vue?vue&type=script&lang=js","webpack://nextcloud/./node_modules/vue-material-design-icons/Refresh.vue?0940","webpack:///nextcloud/node_modules/vue-material-design-icons/Refresh.vue?vue&type=template&id=2864f909","webpack:///nextcloud/node_modules/vue-material-design-icons/MessageReplyTextOutline.vue?vue&type=script&lang=js","webpack:///nextcloud/node_modules/vue-material-design-icons/MessageReplyTextOutline.vue","webpack://nextcloud/./node_modules/vue-material-design-icons/MessageReplyTextOutline.vue?87e1","webpack:///nextcloud/node_modules/vue-material-design-icons/MessageReplyTextOutline.vue?vue&type=template&id=5d6c4e92","webpack:///nextcloud/apps/comments/src/utils/davUtils.js","webpack:///nextcloud/apps/comments/src/utils/decodeHtmlEntities.js","webpack:///nextcloud/apps/comments/src/services/DavClient.js","webpack:///nextcloud/apps/comments/src/store/deletedCommentLimbo.js","webpack:///nextcloud/apps/comments/src/logger.js","webpack:///nextcloud/apps/comments/src/mixins/CommentMixin.js","webpack:///nextcloud/apps/comments/src/services/EditComment.js","webpack:///nextcloud/apps/comments/src/services/DeleteComment.js","webpack:///nextcloud/apps/comments/src/services/NewComment.js","webpack:///nextcloud/apps/comments/src/components/Comment.vue?vue&type=script&lang=js","webpack:///nextcloud/apps/comments/src/components/Comment.vue","webpack://nextcloud/./apps/comments/src/components/Comment.vue?5d91","webpack://nextcloud/./apps/comments/src/components/Comment.vue?7f26","webpack://nextcloud/./apps/comments/src/components/Comment.vue?d1f7","webpack:///nextcloud/apps/comments/src/mixins/CommentView.ts","webpack:///nextcloud/apps/comments/src/services/GetComments.ts","webpack:///nextcloud/apps/comments/src/views/Comments.vue?vue&type=script&lang=js","webpack:///nextcloud/apps/comments/src/views/Comments.vue","webpack:///nextcloud/apps/comments/src/services/ReadComments.ts","webpack:///nextcloud/apps/comments/src/utils/cancelableRequest.js","webpack://nextcloud/./apps/comments/src/views/Comments.vue?e4a1","webpack://nextcloud/./apps/comments/src/views/Comments.vue?f45b","webpack://nextcloud/./apps/comments/src/views/Comments.vue?0e41","webpack:///nextcloud/apps/comments/src/services/CommentsInstance.js","webpack:///nextcloud/apps/comments/src/comments-app.js","webpack:///nextcloud/webpack/bootstrap","webpack:///nextcloud/webpack/runtime/compat get default export","webpack:///nextcloud/webpack/runtime/define property getters","webpack:///nextcloud/webpack/runtime/ensure chunk","webpack:///nextcloud/webpack/runtime/get javascript chunk filename","webpack:///nextcloud/webpack/runtime/global","webpack:///nextcloud/webpack/runtime/hasOwnProperty shorthand","webpack:///nextcloud/webpack/runtime/make namespace object","webpack:///nextcloud/webpack/runtime/node module decorator","webpack:///nextcloud/webpack/runtime/runtimeId","webpack:///nextcloud/webpack/runtime/publicPath","webpack:///nextcloud/webpack/runtime/jsonp chunk loading","webpack:///nextcloud/webpack/runtime/nonce","webpack:///nextcloud/webpack/startup"],"sourcesContent":["var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar chunkIds = deferred[i][0];\n\t\tvar fn = deferred[i][1];\n\t\tvar priority = deferred[i][2];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var inProgress = {};\nvar dataWebpackPrefix = \"nextcloud:\";\n// loadScript function to load a script via script tag\n__webpack_require__.l = (url, done, key, chunkId) => {\n\tif(inProgress[url]) { inProgress[url].push(done); return; }\n\tvar script, needAttach;\n\tif(key !== undefined) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tfor(var i = 0; i < scripts.length; i++) {\n\t\t\tvar s = scripts[i];\n\t\t\tif(s.getAttribute(\"src\") == url || s.getAttribute(\"data-webpack\") == dataWebpackPrefix + key) { script = s; break; }\n\t\t}\n\t}\n\tif(!script) {\n\t\tneedAttach = true;\n\t\tscript = document.createElement('script');\n\n\t\tscript.charset = 'utf-8';\n\t\tscript.timeout = 120;\n\t\tif (__webpack_require__.nc) {\n\t\t\tscript.setAttribute(\"nonce\", __webpack_require__.nc);\n\t\t}\n\t\tscript.setAttribute(\"data-webpack\", dataWebpackPrefix + key);\n\n\t\tscript.src = url;\n\t}\n\tinProgress[url] = [done];\n\tvar onScriptComplete = (prev, event) => {\n\t\t// avoid mem leaks in IE.\n\t\tscript.onerror = script.onload = null;\n\t\tclearTimeout(timeout);\n\t\tvar doneFns = inProgress[url];\n\t\tdelete inProgress[url];\n\t\tscript.parentNode && script.parentNode.removeChild(script);\n\t\tdoneFns && doneFns.forEach((fn) => (fn(event)));\n\t\tif(prev) return prev(event);\n\t}\n\tvar timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000);\n\tscript.onerror = onScriptComplete.bind(null, script.onerror);\n\tscript.onload = onScriptComplete.bind(null, script.onload);\n\tneedAttach && document.head.appendChild(script);\n};","// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, `.comment[data-v-54060d57]{display:flex;gap:8px;padding:5px 10px}.comment__side[data-v-54060d57]{display:flex;align-items:flex-start;padding-top:6px}.comment__body[data-v-54060d57]{display:flex;flex-grow:1;flex-direction:column;container-type:inline-size}.comment__header[data-v-54060d57]{display:flex;align-items:center;min-height:44px}.comment__actions[data-v-54060d57]{margin-inline-start:10px !important}.comment__author[data-v-54060d57]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:var(--color-text-maxcontrast)}.comment_loading[data-v-54060d57],.comment__timestamp[data-v-54060d57]{margin-inline-start:auto;text-align:end;white-space:nowrap;color:var(--color-text-maxcontrast)}.comment__editor-group[data-v-54060d57]{position:relative}.comment__editor-description[data-v-54060d57]{color:var(--color-text-maxcontrast);padding-block:var(--default-grid-baseline)}.comment__submit[data-v-54060d57]{position:absolute !important;bottom:5px;inset-inline-end:0}.comment__message[data-v-54060d57]{white-space:pre-wrap;word-break:normal;max-height:70px;overflow:hidden;margin-top:-6px}.comment__message--expanded[data-v-54060d57]{max-height:none;overflow:visible}.rich-contenteditable__input[data-v-54060d57]{min-height:44px;margin:0;padding:10px}`, \"\",{\"version\":3,\"sources\":[\"webpack://./apps/comments/src/components/Comment.vue\"],\"names\":[],\"mappings\":\"AAKA,0BACC,YAAA,CACA,OAAA,CACA,gBAAA,CAEA,gCACC,YAAA,CACA,sBAAA,CACA,eAAA,CAGD,gCACC,YAAA,CACA,WAAA,CACA,qBAAA,CACA,0BAAA,CAGD,kCACC,YAAA,CACA,kBAAA,CACA,eAAA,CAGD,mCACC,mCAAA,CAGD,kCACC,eAAA,CACA,kBAAA,CACA,sBAAA,CACA,mCAAA,CAGD,uEAEC,wBAAA,CACA,cAAA,CACA,kBAAA,CACA,mCAAA,CAGD,wCACC,iBAAA,CAGD,8CACC,mCAAA,CACA,0CAAA,CAGD,kCACC,4BAAA,CACA,UAAA,CACA,kBAAA,CAGD,mCACC,oBAAA,CACA,iBAAA,CACA,eAAA,CACA,eAAA,CACA,eAAA,CACA,6CACC,eAAA,CACA,gBAAA,CAKH,8CACC,eAAA,CACA,QAAA,CACA,YA5EiB\",\"sourcesContent\":[\"\\n@use \\\"sass:math\\\";\\n\\n$comment-padding: 10px;\\n\\n.comment {\\n\\tdisplay: flex;\\n\\tgap: 8px;\\n\\tpadding: 5px $comment-padding;\\n\\n\\t&__side {\\n\\t\\tdisplay: flex;\\n\\t\\talign-items: flex-start;\\n\\t\\tpadding-top: 6px;\\n\\t}\\n\\n\\t&__body {\\n\\t\\tdisplay: flex;\\n\\t\\tflex-grow: 1;\\n\\t\\tflex-direction: column;\\n\\t\\tcontainer-type: inline-size;\\n\\t}\\n\\n\\t&__header {\\n\\t\\tdisplay: flex;\\n\\t\\talign-items: center;\\n\\t\\tmin-height: 44px;\\n\\t}\\n\\n\\t&__actions {\\n\\t\\tmargin-inline-start: $comment-padding !important;\\n\\t}\\n\\n\\t&__author {\\n\\t\\toverflow: hidden;\\n\\t\\twhite-space: nowrap;\\n\\t\\ttext-overflow: ellipsis;\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t}\\n\\n\\t&_loading,\\n\\t&__timestamp {\\n\\t\\tmargin-inline-start: auto;\\n\\t\\ttext-align: end;\\n\\t\\twhite-space: nowrap;\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t}\\n\\n\\t&__editor-group {\\n\\t\\tposition: relative;\\n\\t}\\n\\n\\t&__editor-description {\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t\\tpadding-block: var(--default-grid-baseline);\\n\\t}\\n\\n\\t&__submit {\\n\\t\\tposition: absolute !important;\\n\\t\\tbottom: 5px;\\n\\t\\tinset-inline-end: 0;\\n\\t}\\n\\n\\t&__message {\\n\\t\\twhite-space: pre-wrap;\\n\\t\\tword-break: normal;\\n\\t\\tmax-height: 70px;\\n\\t\\toverflow: hidden;\\n\\t\\tmargin-top: -6px;\\n\\t\\t&--expanded {\\n\\t\\t\\tmax-height: none;\\n\\t\\t\\toverflow: visible;\\n\\t\\t}\\n\\t}\\n}\\n\\n.rich-contenteditable__input {\\n\\tmin-height: 44px;\\n\\tmargin: 0;\\n\\tpadding: $comment-padding;\\n}\\n\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, `.comments[data-v-fbac7ea2]{min-height:100%;display:flex;flex-direction:column}.comments__empty[data-v-fbac7ea2],.comments__error[data-v-fbac7ea2]{flex:1 0}.comments__retry[data-v-fbac7ea2]{margin:0 auto}.comments__info[data-v-fbac7ea2]{height:60px;color:var(--color-text-maxcontrast);text-align:center;line-height:60px}`, \"\",{\"version\":3,\"sources\":[\"webpack://./apps/comments/src/views/Comments.vue\"],\"names\":[],\"mappings\":\"AACA,2BACC,eAAA,CACA,YAAA,CACA,qBAAA,CAEA,oEAEC,QAAA,CAGD,kCACC,aAAA,CAGD,iCACC,WAAA,CACA,mCAAA,CACA,iBAAA,CACA,gBAAA\",\"sourcesContent\":[\"\\n.comments {\\n\\tmin-height: 100%;\\n\\tdisplay: flex;\\n\\tflex-direction: column;\\n\\n\\t&__empty,\\n\\t&__error {\\n\\t\\tflex: 1 0;\\n\\t}\\n\\n\\t&__retry {\\n\\t\\tmargin: 0 auto;\\n\\t}\\n\\n\\t&__info {\\n\\t\\theight: 60px;\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t\\ttext-align: center;\\n\\t\\tline-height: 60px;\\n\\t}\\n}\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","\n\n","import mod from \"-!../vue-loader/lib/index.js??vue-loader-options!./Refresh.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../vue-loader/lib/index.js??vue-loader-options!./Refresh.vue?vue&type=script&lang=js\"","import { render, staticRenderFns } from \"./Refresh.vue?vue&type=template&id=2864f909\"\nimport script from \"./Refresh.vue?vue&type=script&lang=js\"\nexport * from \"./Refresh.vue?vue&type=script&lang=js\"\n\n\n/* normalize component */\nimport normalizer from \"!../vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('span',_vm._b({staticClass:\"material-design-icon refresh-icon\",attrs:{\"aria-hidden\":_vm.title ? null : 'true',\"aria-label\":_vm.title,\"role\":\"img\"},on:{\"click\":function($event){return _vm.$emit('click', $event)}}},'span',_vm.$attrs,false),[_c('svg',{staticClass:\"material-design-icon__svg\",attrs:{\"fill\":_vm.fillColor,\"width\":_vm.size,\"height\":_vm.size,\"viewBox\":\"0 0 24 24\"}},[_c('path',{attrs:{\"d\":\"M17.65,6.35C16.2,4.9 14.21,4 12,4A8,8 0 0,0 4,12A8,8 0 0,0 12,20C15.73,20 18.84,17.45 19.73,14H17.65C16.83,16.33 14.61,18 12,18A6,6 0 0,1 6,12A6,6 0 0,1 12,6C13.66,6 15.14,6.69 16.22,7.78L13,11H20V4L17.65,6.35Z\"}},[(_vm.title)?_c('title',[_vm._v(_vm._s(_vm.title))]):_vm._e()])])])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import mod from \"-!../vue-loader/lib/index.js??vue-loader-options!./MessageReplyTextOutline.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../vue-loader/lib/index.js??vue-loader-options!./MessageReplyTextOutline.vue?vue&type=script&lang=js\"","\n\n","import { render, staticRenderFns } from \"./MessageReplyTextOutline.vue?vue&type=template&id=5d6c4e92\"\nimport script from \"./MessageReplyTextOutline.vue?vue&type=script&lang=js\"\nexport * from \"./MessageReplyTextOutline.vue?vue&type=script&lang=js\"\n\n\n/* normalize component */\nimport normalizer from \"!../vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('span',_vm._b({staticClass:\"material-design-icon message-reply-text-outline-icon\",attrs:{\"aria-hidden\":_vm.title ? null : 'true',\"aria-label\":_vm.title,\"role\":\"img\"},on:{\"click\":function($event){return _vm.$emit('click', $event)}}},'span',_vm.$attrs,false),[_c('svg',{staticClass:\"material-design-icon__svg\",attrs:{\"fill\":_vm.fillColor,\"width\":_vm.size,\"height\":_vm.size,\"viewBox\":\"0 0 24 24\"}},[_c('path',{attrs:{\"d\":\"M9 11H18V13H9V11M18 7H6V9H18V7M22 4V22L18 18H4C2.9 18 2 17.11 2 16V4C2 2.9 2.9 2 4 2H20C21.1 2 22 2.89 22 4M20 4H4V16H18.83L20 17.17V4Z\"}},[(_vm.title)?_c('title',[_vm._v(_vm._s(_vm.title))]):_vm._e()])])])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { generateRemoteUrl } from '@nextcloud/router'\n\nconst getRootPath = function() {\n\treturn generateRemoteUrl('dav/comments')\n}\n\nexport { getRootPath }\n","/**\n * SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\n/**\n * @param {any} value -\n * @param {any} passes -\n */\nexport function decodeHtmlEntities(value, passes = 1) {\n\tconst parser = new DOMParser()\n\tlet decoded = value\n\tfor (let i = 0; i < passes; i++) {\n\t\tdecoded = parser.parseFromString(decoded, 'text/html').documentElement.textContent\n\t}\n\treturn decoded\n}\n","/**\n * SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { createClient } from 'webdav'\nimport { getRootPath } from '../utils/davUtils.js'\nimport { getRequestToken, onRequestTokenUpdate } from '@nextcloud/auth'\n\n// init webdav client\nconst client = createClient(getRootPath())\n\n// set CSRF token header\nconst setHeaders = (token) => {\n\tclient.setHeaders({\n\t\t// Add this so the server knows it is an request from the browser\n\t\t'X-Requested-With': 'XMLHttpRequest',\n\t\t// Inject user auth\n\t\trequesttoken: token ?? '',\n\t})\n}\n\n// refresh headers when request token changes\nonRequestTokenUpdate(setHeaders)\nsetHeaders(getRequestToken())\n\nexport default client\n","/**\n * SPDX-FileCopyrightText: 2024 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { defineStore } from 'pinia'\n\nexport const useDeletedCommentLimbo = defineStore('deletedCommentLimbo', {\n\tstate: () => ({\n\t\tidsInLimbo: [],\n\t}),\n\tactions: {\n\t\taddId(id) {\n\t\t\tthis.idsInLimbo.push(id)\n\t\t},\n\n\t\tremoveId(id) {\n\t\t\tconst index = this.idsInLimbo.indexOf(id)\n\t\t\tif (index > -1) {\n\t\t\t\tthis.idsInLimbo.splice(index, 1)\n\t\t\t}\n\t\t},\n\n\t\tcheckForId(id) {\n\t\t\tthis.idsInLimbo.includes(id)\n\t\t},\n\t},\n})\n","/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { getLoggerBuilder } from '@nextcloud/logger'\n\nexport default getLoggerBuilder()\n\t.setApp('comments')\n\t.detectUser()\n\t.build()\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { showError, showUndo, TOAST_UNDO_TIMEOUT } from '@nextcloud/dialogs'\nimport NewComment from '../services/NewComment.js'\nimport DeleteComment from '../services/DeleteComment.js'\nimport EditComment from '../services/EditComment.js'\nimport { mapStores } from 'pinia'\nimport { useDeletedCommentLimbo } from '../store/deletedCommentLimbo.js'\nimport logger from '../logger.js'\n\nexport default {\n\tprops: {\n\t\tid: {\n\t\t\ttype: Number,\n\t\t\tdefault: null,\n\t\t},\n\t\tmessage: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\t\tresourceId: {\n\t\t\ttype: [String, Number],\n\t\t\trequired: true,\n\t\t},\n\t\tresourceType: {\n\t\t\ttype: String,\n\t\t\tdefault: 'files',\n\t\t},\n\t},\n\n\tdata() {\n\t\treturn {\n\t\t\tdeleted: false,\n\t\t\tediting: false,\n\t\t\tloading: false,\n\t\t}\n\t},\n\n\tcomputed: {\n\t\t...mapStores(useDeletedCommentLimbo),\n\t},\n\n\tmethods: {\n\t\t// EDITION\n\t\tonEdit() {\n\t\t\tthis.editing = true\n\t\t},\n\t\tonEditCancel() {\n\t\t\tthis.editing = false\n\t\t\t// Restore original value\n\t\t\tthis.updateLocalMessage(this.message)\n\t\t},\n\t\tasync onEditComment(message) {\n\t\t\tthis.loading = true\n\t\t\ttry {\n\t\t\t\tawait EditComment(this.resourceType, this.resourceId, this.id, message)\n\t\t\t\tlogger.debug('Comment edited', { resourceType: this.resourceType, resourceId: this.resourceId, id: this.id, message })\n\t\t\t\tthis.$emit('update:message', message)\n\t\t\t\tthis.editing = false\n\t\t\t} catch (error) {\n\t\t\t\tshowError(t('comments', 'An error occurred while trying to edit the comment'))\n\t\t\t\tconsole.error(error)\n\t\t\t} finally {\n\t\t\t\tthis.loading = false\n\t\t\t}\n\t\t},\n\n\t\t// DELETION\n\t\tonDeleteWithUndo() {\n\t\t\tthis.$emit('delete')\n\t\t\tthis.deleted = true\n\t\t\tthis.deletedCommentLimboStore.addId(this.id)\n\t\t\tconst timeOutDelete = setTimeout(this.onDelete, TOAST_UNDO_TIMEOUT)\n\t\t\tshowUndo(t('comments', 'Comment deleted'), () => {\n\t\t\t\tclearTimeout(timeOutDelete)\n\t\t\t\tthis.deleted = false\n\t\t\t\tthis.deletedCommentLimboStore.removeId(this.id)\n\t\t\t})\n\t\t},\n\t\tasync onDelete() {\n\t\t\ttry {\n\t\t\t\tawait DeleteComment(this.resourceType, this.resourceId, this.id)\n\t\t\t\tlogger.debug('Comment deleted', { resourceType: this.resourceType, resourceId: this.resourceId, id: this.id })\n\t\t\t\tthis.$emit('delete', this.id)\n\t\t\t} catch (error) {\n\t\t\t\tshowError(t('comments', 'An error occurred while trying to delete the comment'))\n\t\t\t\tconsole.error(error)\n\t\t\t\tthis.deleted = false\n\t\t\t\tthis.deletedCommentLimboStore.removeId(this.id)\n\t\t\t}\n\t\t},\n\n\t\t// CREATION\n\t\tasync onNewComment(message) {\n\t\t\tthis.loading = true\n\t\t\ttry {\n\t\t\t\tconst newComment = await NewComment(this.resourceType, this.resourceId, message)\n\t\t\t\tlogger.debug('New comment posted', { resourceType: this.resourceType, resourceId: this.resourceId, newComment })\n\t\t\t\tthis.$emit('new', newComment)\n\n\t\t\t\t// Clear old content\n\t\t\t\tthis.$emit('update:message', '')\n\t\t\t\tthis.localMessage = ''\n\t\t\t} catch (error) {\n\t\t\t\tshowError(t('comments', 'An error occurred while trying to create the comment'))\n\t\t\t\tconsole.error(error)\n\t\t\t} finally {\n\t\t\t\tthis.loading = false\n\t\t\t}\n\t\t},\n\t},\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport client from './DavClient.js'\n\n/**\n * Edit an existing comment\n *\n * @param {string} resourceType the resource type\n * @param {number} resourceId the resource ID\n * @param {number} commentId the comment iD\n * @param {string} message the message content\n */\nexport default async function(resourceType, resourceId, commentId, message) {\n\tconst commentPath = ['', resourceType, resourceId, commentId].join('/')\n\n\treturn await client.customRequest(commentPath, Object.assign({\n\t\tmethod: 'PROPPATCH',\n\t\tdata: `\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t${message}\n\t\t\t\t\n\t\t\t\n\t\t\t`,\n\t}))\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport client from './DavClient.js'\n\n/**\n * Delete a comment\n *\n * @param {string} resourceType the resource type\n * @param {number} resourceId the resource ID\n * @param {number} commentId the comment iD\n */\nexport default async function(resourceType, resourceId, commentId) {\n\tconst commentPath = ['', resourceType, resourceId, commentId].join('/')\n\n\t// Fetch newly created comment data\n\tawait client.deleteFile(commentPath)\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { getCurrentUser } from '@nextcloud/auth'\nimport { getRootPath } from '../utils/davUtils.js'\nimport { decodeHtmlEntities } from '../utils/decodeHtmlEntities.js'\nimport axios from '@nextcloud/axios'\nimport client from './DavClient.js'\n\n/**\n * Retrieve the comments list\n *\n * @param {string} resourceType the resource type\n * @param {number} resourceId the resource ID\n * @param {string} message the message\n * @return {object} the new comment\n */\nexport default async function(resourceType, resourceId, message) {\n\tconst resourcePath = ['', resourceType, resourceId].join('/')\n\n\tconst response = await axios.post(getRootPath() + resourcePath, {\n\t\tactorDisplayName: getCurrentUser().displayName,\n\t\tactorId: getCurrentUser().uid,\n\t\tactorType: 'users',\n\t\tcreationDateTime: (new Date()).toUTCString(),\n\t\tmessage,\n\t\tobjectType: resourceType,\n\t\tverb: 'comment',\n\t})\n\n\t// Retrieve comment id from resource location\n\tconst commentId = parseInt(response.headers['content-location'].split('/').pop())\n\tconst commentPath = resourcePath + '/' + commentId\n\n\t// Fetch newly created comment data\n\tconst comment = await client.stat(commentPath, {\n\t\tdetails: true,\n\t})\n\n\tconst props = comment.data.props\n\t// Decode twice to handle potentially double-encoded entities\n\t// FIXME Remove this once https://github.com/nextcloud/server/issues/29306\n\t// is resolved\n\tprops.actorDisplayName = decodeHtmlEntities(props.actorDisplayName, 2)\n\tprops.message = decodeHtmlEntities(props.message, 2)\n\n\treturn comment.data\n}\n","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=script&lang=js\"","\n\n\n\n\n\n","\n import API from \"!../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=style&index=0&id=54060d57&prod&lang=scss&scoped=true\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\noptions.insert = insertFn.bind(null, \"head\");\noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=style&index=0&id=54060d57&prod&lang=scss&scoped=true\";\n export default content && content.locals ? content.locals : undefined;\n","import { render, staticRenderFns } from \"./Comment.vue?vue&type=template&id=54060d57&scoped=true\"\nimport script from \"./Comment.vue?vue&type=script&lang=js\"\nexport * from \"./Comment.vue?vue&type=script&lang=js\"\nimport style0 from \"./Comment.vue?vue&type=style&index=0&id=54060d57&prod&lang=scss&scoped=true\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"54060d57\",\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c(_vm.tag,{directives:[{name:\"show\",rawName:\"v-show\",value:(!_vm.deleted && !_vm.isLimbo),expression:\"!deleted && !isLimbo\"}],tag:\"component\",staticClass:\"comment\",class:{'comment--loading': _vm.loading}},[_c('div',{staticClass:\"comment__side\"},[_c('NcAvatar',{staticClass:\"comment__avatar\",attrs:{\"display-name\":_vm.actorDisplayName,\"user\":_vm.actorId,\"size\":32}})],1),_vm._v(\" \"),_c('div',{staticClass:\"comment__body\"},[_c('div',{staticClass:\"comment__header\"},[_c('span',{staticClass:\"comment__author\"},[_vm._v(_vm._s(_vm.actorDisplayName))]),_vm._v(\" \"),(_vm.isOwnComment && _vm.id && !_vm.loading)?_c('NcActions',{staticClass:\"comment__actions\"},[(!_vm.editing)?[_c('NcActionButton',{attrs:{\"close-after-click\":\"\"},on:{\"click\":_vm.onEdit},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconPencilOutline',{attrs:{\"size\":20}})]},proxy:true}],null,false,3345211262)},[_vm._v(\"\\n\\t\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Edit comment'))+\"\\n\\t\\t\\t\\t\\t\")]),_vm._v(\" \"),_c('NcActionSeparator'),_vm._v(\" \"),_c('NcActionButton',{attrs:{\"close-after-click\":\"\"},on:{\"click\":_vm.onDeleteWithUndo},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconTrashCanOutline',{attrs:{\"size\":20}})]},proxy:true}],null,false,1034796883)},[_vm._v(\"\\n\\t\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Delete comment'))+\"\\n\\t\\t\\t\\t\\t\")])]:_c('NcActionButton',{on:{\"click\":_vm.onEditCancel},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconClose',{attrs:{\"size\":20}})]},proxy:true}],null,false,2888946197)},[_vm._v(\"\\n\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Cancel edit'))+\"\\n\\t\\t\\t\\t\")])],2):_vm._e(),_vm._v(\" \"),(_vm.id && _vm.loading)?_c('div',{staticClass:\"comment_loading icon-loading-small\"}):(_vm.creationDateTime)?_c('NcDateTime',{staticClass:\"comment__timestamp\",attrs:{\"timestamp\":_vm.timestamp,\"ignore-seconds\":true}}):_vm._e()],1),_vm._v(\" \"),(_vm.editor || _vm.editing)?_c('form',{staticClass:\"comment__editor\",on:{\"submit\":function($event){$event.preventDefault();}}},[_c('div',{staticClass:\"comment__editor-group\"},[_c('NcRichContenteditable',{ref:\"editor\",attrs:{\"auto-complete\":_vm.autoComplete,\"contenteditable\":!_vm.loading,\"label\":_vm.editor ? _vm.t('comments', 'New comment') : _vm.t('comments', 'Edit comment'),\"placeholder\":_vm.t('comments', 'Write a comment …'),\"value\":_vm.localMessage,\"user-data\":_vm.userData,\"aria-describedby\":\"tab-comments__editor-description\"},on:{\"update:value\":_vm.updateLocalMessage,\"submit\":_vm.onSubmit}}),_vm._v(\" \"),_c('div',{staticClass:\"comment__submit\"},[_c('NcButton',{attrs:{\"type\":\"tertiary-no-background\",\"native-type\":\"submit\",\"aria-label\":_vm.t('comments', 'Post comment'),\"disabled\":_vm.isEmptyMessage},on:{\"click\":_vm.onSubmit},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [(_vm.loading)?_c('NcLoadingIcon'):_c('IconArrowRight',{attrs:{\"size\":20}})]},proxy:true}],null,false,758946661)})],1)],1),_vm._v(\" \"),_c('div',{staticClass:\"comment__editor-description\",attrs:{\"id\":\"tab-comments__editor-description\"}},[_vm._v(\"\\n\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', '@ for mentions, : for emoji, / for smart picker'))+\"\\n\\t\\t\\t\")])]):_c('NcRichText',{staticClass:\"comment__message\",class:{'comment__message--expanded': _vm.expanded},attrs:{\"text\":_vm.richContent.message,\"arguments\":_vm.richContent.mentions},on:{\"click\":_vm.onExpand}})],1)])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\nimport axios from '@nextcloud/axios';\nimport { getCurrentUser } from '@nextcloud/auth';\nimport { loadState } from '@nextcloud/initial-state';\nimport { generateOcsUrl } from '@nextcloud/router';\nimport { defineComponent } from 'vue';\nexport default defineComponent({\n props: {\n resourceId: {\n type: Number,\n required: true,\n },\n resourceType: {\n type: String,\n default: 'files',\n },\n },\n data() {\n return {\n editorData: {\n actorDisplayName: getCurrentUser().displayName,\n actorId: getCurrentUser().uid,\n key: 'editor',\n },\n userData: {},\n };\n },\n methods: {\n /**\n * Autocomplete @mentions\n *\n * @param {string} search the query\n * @param {Function} callback the callback to process the results with\n */\n async autoComplete(search, callback) {\n const { data } = await axios.get(generateOcsUrl('core/autocomplete/get'), {\n params: {\n search,\n itemType: 'files',\n itemId: this.resourceId,\n sorter: 'commenters|share-recipients',\n limit: loadState('comments', 'maxAutoCompleteResults'),\n },\n });\n // Save user data so it can be used by the editor to replace mentions\n data.ocs.data.forEach(user => { this.userData[user.id] = user; });\n return callback(Object.values(this.userData));\n },\n /**\n * Make sure we have all mentions as Array of objects\n *\n * @param mentions the mentions list\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n genMentionsData(mentions) {\n Object.values(mentions)\n .flat()\n .forEach(mention => {\n this.userData[mention.mentionId] = {\n // TODO: support groups\n icon: 'icon-user',\n id: mention.mentionId,\n label: mention.mentionDisplayName,\n source: 'users',\n primary: getCurrentUser()?.uid === mention.mentionId,\n };\n });\n return this.userData;\n },\n },\n});\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\nimport { parseXML } from 'webdav';\n// https://github.com/perry-mitchell/webdav-client/issues/339\nimport { processResponsePayload } from 'webdav/dist/node/response.js';\nimport { prepareFileFromProps } from 'webdav/dist/node/tools/dav.js';\nimport client from './DavClient.js';\nexport const DEFAULT_LIMIT = 20;\n/**\n * Retrieve the comments list\n *\n * @param {object} data destructuring object\n * @param {string} data.resourceType the resource type\n * @param {number} data.resourceId the resource ID\n * @param {object} [options] optional options for axios\n * @param {number} [options.offset] the pagination offset\n * @param {number} [options.limit] the pagination limit, defaults to 20\n * @param {Date} [options.datetime] optional date to query\n * @return {{data: object[]}} the comments list\n */\nexport const getComments = async function ({ resourceType, resourceId }, options) {\n const resourcePath = ['', resourceType, resourceId].join('/');\n const datetime = options.datetime ? `${options.datetime.toISOString()}` : '';\n const response = await client.customRequest(resourcePath, Object.assign({\n method: 'REPORT',\n data: `\n\t\t\t\n\t\t\t\t${options.limit ?? DEFAULT_LIMIT}\n\t\t\t\t${options.offset || 0}\n\t\t\t\t${datetime}\n\t\t\t`,\n }, options));\n const responseData = await response.text();\n const result = await parseXML(responseData);\n const stat = getDirectoryFiles(result, true);\n return processResponsePayload(response, stat, true);\n};\n// https://github.com/perry-mitchell/webdav-client/blob/8d9694613c978ce7404e26a401c39a41f125f87f/source/operations/directoryContents.ts\nconst getDirectoryFiles = function (result, isDetailed = false) {\n // Extract the response items (directory contents)\n const { multistatus: { response: responseItems }, } = result;\n // Map all items to a consistent output structure (results)\n return responseItems.map(item => {\n // Each item should contain a stat object\n const props = item.propstat.prop;\n return prepareFileFromProps(props, props.id.toString(), isDetailed);\n });\n};\n","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comments.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comments.vue?vue&type=script&lang=js\"","\n\n\n\n\n\n\n","/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\nimport client from './DavClient.js';\n/**\n * Mark comments older than the date timestamp as read\n *\n * @param resourceType the resource type\n * @param resourceId the resource ID\n * @param date the date object\n */\nexport const markCommentsAsRead = (resourceType, resourceId, date) => {\n const resourcePath = ['', resourceType, resourceId].join('/');\n const readMarker = date.toUTCString();\n return client.customRequest(resourcePath, {\n method: 'PROPPATCH',\n data: `\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t${readMarker}\n\t\t\t\t\n\t\t\t\n\t\t\t`,\n });\n};\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\n/**\n * Creates a cancelable axios 'request object'.\n *\n * @param {Function} request the axios promise request\n * @return {object}\n */\nconst cancelableRequest = function(request) {\n\tconst controller = new AbortController()\n\tconst signal = controller.signal\n\n\t/**\n\t * Execute the request\n\t *\n\t * @param {string} url the url to send the request to\n\t * @param {object} [options] optional config for the request\n\t */\n\tconst fetch = async function(url, options) {\n\t\tconst response = await request(\n\t\t\turl,\n\t\t\tObject.assign({ signal }, options),\n\t\t)\n\t\treturn response\n\t}\n\n\treturn {\n\t\trequest: fetch,\n\t\tabort: () => controller.abort(),\n\t}\n}\n\nexport default cancelableRequest\n","\n import API from \"!../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comments.vue?vue&type=style&index=0&id=fbac7ea2&prod&lang=scss&scoped=true\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\noptions.insert = insertFn.bind(null, \"head\");\noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comments.vue?vue&type=style&index=0&id=fbac7ea2&prod&lang=scss&scoped=true\";\n export default content && content.locals ? content.locals : undefined;\n","import { render, staticRenderFns } from \"./Comments.vue?vue&type=template&id=fbac7ea2&scoped=true\"\nimport script from \"./Comments.vue?vue&type=script&lang=js\"\nexport * from \"./Comments.vue?vue&type=script&lang=js\"\nimport style0 from \"./Comments.vue?vue&type=style&index=0&id=fbac7ea2&prod&lang=scss&scoped=true\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"fbac7ea2\",\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('div',{directives:[{name:\"element-visibility\",rawName:\"v-element-visibility\",value:(_vm.onVisibilityChange),expression:\"onVisibilityChange\"}],staticClass:\"comments\",class:{ 'icon-loading': _vm.isFirstLoading }},[_c('Comment',_vm._b({staticClass:\"comments__writer\",attrs:{\"auto-complete\":_vm.autoComplete,\"resource-type\":_vm.resourceType,\"editor\":true,\"user-data\":_vm.userData,\"resource-id\":_vm.currentResourceId},on:{\"new\":_vm.onNewComment}},'Comment',_vm.editorData,false)),_vm._v(\" \"),(!_vm.isFirstLoading)?[(!_vm.hasComments && _vm.done)?_c('NcEmptyContent',{staticClass:\"comments__empty\",attrs:{\"name\":_vm.t('comments', 'No comments yet, start the conversation!')},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconMessageReplyTextOutline')]},proxy:true}],null,false,326612300)}):_c('ul',_vm._l((_vm.comments),function(comment){return _c('Comment',_vm._b({key:comment.props.id,staticClass:\"comments__list\",attrs:{\"tag\":\"li\",\"auto-complete\":_vm.autoComplete,\"resource-type\":_vm.resourceType,\"message\":comment.props.message,\"resource-id\":_vm.currentResourceId,\"user-data\":_vm.genMentionsData(comment.props.mentions)},on:{\"update:message\":function($event){return _vm.$set(comment.props, \"message\", $event)},\"delete\":_vm.onDelete}},'Comment',comment.props,false))}),1),_vm._v(\" \"),(_vm.loading && !_vm.isFirstLoading)?_c('div',{staticClass:\"comments__info icon-loading\"}):(_vm.hasComments && _vm.done)?_c('div',{staticClass:\"comments__info\"},[_vm._v(\"\\n\\t\\t\\t\"+_vm._s(_vm.t('comments', 'No more messages'))+\"\\n\\t\\t\")]):(_vm.error)?[_c('NcEmptyContent',{staticClass:\"comments__error\",attrs:{\"name\":_vm.error},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconAlertCircleOutline')]},proxy:true}],null,false,3663249556)}),_vm._v(\" \"),_c('NcButton',{staticClass:\"comments__retry\",on:{\"click\":_vm.getComments},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconRefresh')]},proxy:true}],null,false,2997625269)},[_vm._v(\"\\n\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Retry'))+\"\\n\\t\\t\\t\")])]:_vm._e()]:_vm._e()],2)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { getCSPNonce } from '@nextcloud/auth'\nimport { t, n } from '@nextcloud/l10n'\nimport { PiniaVuePlugin, createPinia } from 'pinia'\nimport Vue from 'vue'\nimport CommentsApp from '../views/Comments.vue'\nimport logger from '../logger.js'\n\nVue.use(PiniaVuePlugin)\n// eslint-disable-next-line camelcase\n__webpack_nonce__ = getCSPNonce()\n\n// Add translates functions\nVue.mixin({\n\tdata() {\n\t\treturn {\n\t\t\tlogger,\n\t\t}\n\t},\n\tmethods: {\n\t\tt,\n\t\tn,\n\t},\n})\n\nexport default class CommentInstance {\n\n\t/**\n\t * Initialize a new Comments instance for the desired type\n\t *\n\t * @param {string} resourceType the comments endpoint type\n\t * @param {object} options the vue options (propsData, parent, el...)\n\t */\n\tconstructor(resourceType = 'files', options = {}) {\n\t\tconst pinia = createPinia()\n\n\t\t// Merge options and set `resourceType` property\n\t\toptions = {\n\t\t\t...options,\n\t\t\tpropsData: {\n\t\t\t\t...(options.propsData ?? {}),\n\t\t\t\tresourceType,\n\t\t\t},\n\t\t\tpinia,\n\t\t}\n\t\t// Init Comments component\n\t\tconst View = Vue.extend(CommentsApp)\n\t\treturn new View(options)\n\t}\n\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport CommentsInstance from './services/CommentsInstance.js'\n\n// Init Comments\nif (window.OCA && !window.OCA.Comments) {\n\tObject.assign(window.OCA, { Comments: {} })\n}\n\n// Init Comments App view\nObject.assign(window.OCA.Comments, { View: CommentsInstance })\nconsole.debug('OCA.Comments.View initialized')\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \"-\" + chunkId + \".js?v=\" + {\"640\":\"d4c5c018803ee8751b2a\",\"780\":\"e3ee44fa7690af29d8d7\",\"3564\":\"29e8338d43e0d4bd3995\",\"4508\":\"40b53e5d2d42025bc3a7\",\"5258\":\"80a9b9a289e4eb695373\",\"5810\":\"b550a24d46f75f92c2d5\",\"5862\":\"8bc76a21d9622c29e1a9\",\"7471\":\"6423b9b898ffefeb7d1d\",\"7838\":\"37c7bd8d5fada1bd542c\"}[chunkId] + \"\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = (module) => {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","__webpack_require__.j = 7062;","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/^blob:/, \"\").replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = document.baseURI || self.location.href;\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t7062: 0\n};\n\n__webpack_require__.f.j = (chunkId, promises) => {\n\t\t// JSONP chunk loading for javascript\n\t\tvar installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined;\n\t\tif(installedChunkData !== 0) { // 0 means \"already installed\".\n\n\t\t\t// a Promise means \"currently loading\".\n\t\t\tif(installedChunkData) {\n\t\t\t\tpromises.push(installedChunkData[2]);\n\t\t\t} else {\n\t\t\t\tif(true) { // all chunks have JS\n\t\t\t\t\t// setup Promise in chunk cache\n\t\t\t\t\tvar promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject]));\n\t\t\t\t\tpromises.push(installedChunkData[2] = promise);\n\n\t\t\t\t\t// start chunk loading\n\t\t\t\t\tvar url = __webpack_require__.p + __webpack_require__.u(chunkId);\n\t\t\t\t\t// create error before stack unwound to get useful stacktrace later\n\t\t\t\t\tvar error = new Error();\n\t\t\t\t\tvar loadingEnded = (event) => {\n\t\t\t\t\t\tif(__webpack_require__.o(installedChunks, chunkId)) {\n\t\t\t\t\t\t\tinstalledChunkData = installedChunks[chunkId];\n\t\t\t\t\t\t\tif(installedChunkData !== 0) installedChunks[chunkId] = undefined;\n\t\t\t\t\t\t\tif(installedChunkData) {\n\t\t\t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n\t\t\t\t\t\t\t\tvar realSrc = event && event.target && event.target.src;\n\t\t\t\t\t\t\t\terror.message = 'Loading chunk ' + chunkId + ' failed.\\n(' + errorType + ': ' + realSrc + ')';\n\t\t\t\t\t\t\t\terror.name = 'ChunkLoadError';\n\t\t\t\t\t\t\t\terror.type = errorType;\n\t\t\t\t\t\t\t\terror.request = realSrc;\n\t\t\t\t\t\t\t\tinstalledChunkData[1](error);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\t\t\t\t\t__webpack_require__.l(url, loadingEnded, \"chunk-\" + chunkId, chunkId);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n};\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar chunkIds = data[0];\n\tvar moreModules = data[1];\n\tvar runtime = data[2];\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = self[\"webpackChunknextcloud\"] = self[\"webpackChunknextcloud\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","__webpack_require__.nc = undefined;","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [4208], () => (__webpack_require__(81873)))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n"],"names":["deferred","inProgress","dataWebpackPrefix","___CSS_LOADER_EXPORT___","push","module","id","name","emits","props","title","type","String","fillColor","default","size","Number","_vm","this","_c","_self","_b","staticClass","attrs","on","$event","$emit","$attrs","_v","_s","_e","getRootPath","generateRemoteUrl","decodeHtmlEntities","value","passes","arguments","length","undefined","parser","DOMParser","decoded","i","parseFromString","documentElement","textContent","client","createClient","setHeaders","token","requesttoken","onRequestTokenUpdate","getRequestToken","useDeletedCommentLimbo","defineStore","state","idsInLimbo","actions","addId","removeId","index","indexOf","splice","checkForId","includes","getLoggerBuilder","setApp","detectUser","build","message","resourceId","required","resourceType","data","deleted","editing","loading","computed","mapStores","methods","onEdit","onEditCancel","updateLocalMessage","onEditComment","async","commentId","commentPath","join","customRequest","Object","assign","method","EditComment","logger","debug","error","showError","t","console","onDeleteWithUndo","deletedCommentLimboStore","timeOutDelete","setTimeout","onDelete","TOAST_UNDO_TIMEOUT","showUndo","clearTimeout","deleteFile","DeleteComment","onNewComment","newComment","resourcePath","response","axios","post","actorDisplayName","getCurrentUser","displayName","actorId","uid","actorType","creationDateTime","Date","toUTCString","objectType","verb","parseInt","headers","split","pop","comment","stat","details","NewComment","localMessage","components","IconArrowRight","IconClose","IconTrashCanOutline","IconPencilOutline","NcActionButton","NcActions","NcActionSeparator","NcAvatar","NcButton","NcDateTime","NcLoadingIcon","NcRichContenteditable","NcRichText","mixins","CommentMixin","inheritAttrs","editor","Boolean","autoComplete","Function","userData","tag","expanded","submitted","isOwnComment","richContent","mentions","keys","forEach","user","key","regex","RegExp","replace","component","NcUserBubble","label","primary","isEmptyMessage","trim","timestamp","parse","isLimbo","watch","beforeMount","toString","onSubmit","$nextTick","$refs","$el","focus","onExpand","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","locals","directives","rawName","expression","class","scopedSlots","_u","fn","proxy","preventDefault","ref","defineComponent","editorData","search","callback","get","generateOcsUrl","params","itemType","itemId","sorter","limit","loadState","ocs","values","genMentionsData","flat","mention","mentionId","icon","mentionDisplayName","source","getComments","_ref","datetime","toISOString","offset","responseData","text","result","parseXML","getDirectoryFiles","processResponsePayload","isDetailed","multistatus","responseItems","map","item","propstat","prop","prepareFileFromProps","Comment","NcEmptyContent","IconRefresh","IconMessageReplyTextOutline","IconAlertCircleOutline","elementVisibility","CommentView","done","currentResourceId","comments","cancelRequest","hasComments","isFirstLoading","onVisibilityChange","isVisible","markCommentsAsRead","date","readMarker","e","update","resetState","onScrollBottomReached","request","abort","controller","AbortController","signal","url","cancelableRequest","unshift","findIndex","_l","$set","Vue","use","PiniaVuePlugin","__webpack_nonce__","getCSPNonce","mixin","n","window","OCA","Comments","View","constructor","pinia","createPinia","propsData","extend","CommentsApp","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","exports","loaded","__webpack_modules__","call","m","O","chunkIds","priority","notFulfilled","Infinity","fulfilled","j","every","r","getter","__esModule","d","a","definition","o","defineProperty","enumerable","f","chunkId","Promise","all","reduce","promises","u","g","globalThis","obj","prototype","hasOwnProperty","l","script","needAttach","scripts","document","getElementsByTagName","s","getAttribute","createElement","charset","timeout","nc","setAttribute","src","onScriptComplete","prev","event","onerror","onload","doneFns","parentNode","removeChild","bind","target","head","appendChild","Symbol","toStringTag","nmd","paths","children","scriptUrl","importScripts","location","currentScript","tagName","toUpperCase","test","Error","p","b","baseURI","self","href","installedChunks","installedChunkData","promise","resolve","reject","errorType","realSrc","webpackJsonpCallback","parentChunkLoadingFunction","moreModules","runtime","some","chunkLoadingGlobal","__webpack_exports__"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"comments-comments-app.js?v=4980ed137948afb652fe","mappings":"UAAIA,ECAAC,EACAC,E,mFCEAC,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,gvCAAivC,GAAG,CAAC,QAAU,EAAE,QAAU,CAAC,wDAAwD,MAAQ,GAAG,SAAW,keAAke,eAAiB,CAAC,w5CAA05C,WAAa,MAE9xG,S,0HCJIH,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,kUAAmU,GAAG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YyF,EAAYzF,IAGhD,GAAG0F,EAAS,IAAI1J,EAAS0J,EAAQ3F,EAClC,CAEA,IADGyF,GAA4BA,EAA2B1T,GACrD/B,EAAIyQ,EAAS9Q,OAAQK,IACzB0R,EAAUjB,EAASzQ,GAChBgQ,EAAoBsB,EAAE2D,EAAiBvD,IAAYuD,EAAgBvD,IACrEuD,EAAgBvD,GAAS,KAE1BuD,EAAgBvD,GAAW,EAE5B,OAAO1B,EAAoBQ,EAAEvE,IAG1B4J,EAAqBd,KAA4B,sBAAIA,KAA4B,uBAAK,GAC1Fc,EAAmBnO,QAAQ8N,EAAqB7B,KAAK,KAAM,IAC3DkC,EAAmBnY,KAAO8X,EAAqB7B,KAAK,KAAMkC,EAAmBnY,KAAKiW,KAAKkC,G,KCvFvF7F,EAAoBgD,QAAKpT,ECGzB,IAAIkW,EAAsB9F,EAAoBQ,OAAE5Q,EAAW,CAAC,MAAO,IAAOoQ,EAAoB,QAC9F8F,EAAsB9F,EAAoBQ,EAAEsF,E","sources":["webpack:///nextcloud/webpack/runtime/chunk loaded","webpack:///nextcloud/webpack/runtime/load script","webpack:///nextcloud/apps/comments/src/components/Comment.vue?vue&type=style&index=0&id=3cab0376&prod&lang=scss&scoped=true","webpack:///nextcloud/apps/comments/src/views/Comments.vue?vue&type=style&index=0&id=fbac7ea2&prod&lang=scss&scoped=true","webpack:///nextcloud/node_modules/vue-material-design-icons/Refresh.vue","webpack:///nextcloud/node_modules/vue-material-design-icons/Refresh.vue?vue&type=script&lang=js","webpack://nextcloud/./node_modules/vue-material-design-icons/Refresh.vue?0940","webpack:///nextcloud/node_modules/vue-material-design-icons/Refresh.vue?vue&type=template&id=2864f909","webpack:///nextcloud/node_modules/vue-material-design-icons/MessageReplyTextOutline.vue?vue&type=script&lang=js","webpack:///nextcloud/node_modules/vue-material-design-icons/MessageReplyTextOutline.vue","webpack://nextcloud/./node_modules/vue-material-design-icons/MessageReplyTextOutline.vue?87e1","webpack:///nextcloud/node_modules/vue-material-design-icons/MessageReplyTextOutline.vue?vue&type=template&id=5d6c4e92","webpack:///nextcloud/apps/comments/src/utils/davUtils.js","webpack:///nextcloud/apps/comments/src/utils/decodeHtmlEntities.js","webpack:///nextcloud/apps/comments/src/services/DavClient.js","webpack:///nextcloud/apps/comments/src/store/deletedCommentLimbo.js","webpack:///nextcloud/apps/comments/src/logger.js","webpack:///nextcloud/apps/comments/src/mixins/CommentMixin.js","webpack:///nextcloud/apps/comments/src/services/EditComment.js","webpack:///nextcloud/apps/comments/src/services/DeleteComment.js","webpack:///nextcloud/apps/comments/src/services/NewComment.js","webpack:///nextcloud/apps/comments/src/components/Comment.vue?vue&type=script&lang=js","webpack:///nextcloud/apps/comments/src/components/Comment.vue","webpack://nextcloud/./apps/comments/src/components/Comment.vue?d279","webpack://nextcloud/./apps/comments/src/components/Comment.vue?7f26","webpack://nextcloud/./apps/comments/src/components/Comment.vue?d1f7","webpack:///nextcloud/apps/comments/src/mixins/CommentView.ts","webpack:///nextcloud/apps/comments/src/services/GetComments.ts","webpack:///nextcloud/apps/comments/src/views/Comments.vue?vue&type=script&lang=js","webpack:///nextcloud/apps/comments/src/views/Comments.vue","webpack:///nextcloud/apps/comments/src/services/ReadComments.ts","webpack:///nextcloud/apps/comments/src/utils/cancelableRequest.js","webpack://nextcloud/./apps/comments/src/views/Comments.vue?e4a1","webpack://nextcloud/./apps/comments/src/views/Comments.vue?f45b","webpack://nextcloud/./apps/comments/src/views/Comments.vue?0e41","webpack:///nextcloud/apps/comments/src/services/CommentsInstance.js","webpack:///nextcloud/apps/comments/src/comments-app.js","webpack:///nextcloud/webpack/bootstrap","webpack:///nextcloud/webpack/runtime/compat get default export","webpack:///nextcloud/webpack/runtime/define property getters","webpack:///nextcloud/webpack/runtime/ensure chunk","webpack:///nextcloud/webpack/runtime/get javascript chunk filename","webpack:///nextcloud/webpack/runtime/global","webpack:///nextcloud/webpack/runtime/hasOwnProperty shorthand","webpack:///nextcloud/webpack/runtime/make namespace object","webpack:///nextcloud/webpack/runtime/node module decorator","webpack:///nextcloud/webpack/runtime/runtimeId","webpack:///nextcloud/webpack/runtime/publicPath","webpack:///nextcloud/webpack/runtime/jsonp chunk loading","webpack:///nextcloud/webpack/runtime/nonce","webpack:///nextcloud/webpack/startup"],"sourcesContent":["var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar chunkIds = deferred[i][0];\n\t\tvar fn = deferred[i][1];\n\t\tvar priority = deferred[i][2];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var inProgress = {};\nvar dataWebpackPrefix = \"nextcloud:\";\n// loadScript function to load a script via script tag\n__webpack_require__.l = (url, done, key, chunkId) => {\n\tif(inProgress[url]) { inProgress[url].push(done); return; }\n\tvar script, needAttach;\n\tif(key !== undefined) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tfor(var i = 0; i < scripts.length; i++) {\n\t\t\tvar s = scripts[i];\n\t\t\tif(s.getAttribute(\"src\") == url || s.getAttribute(\"data-webpack\") == dataWebpackPrefix + key) { script = s; break; }\n\t\t}\n\t}\n\tif(!script) {\n\t\tneedAttach = true;\n\t\tscript = document.createElement('script');\n\n\t\tscript.charset = 'utf-8';\n\t\tscript.timeout = 120;\n\t\tif (__webpack_require__.nc) {\n\t\t\tscript.setAttribute(\"nonce\", __webpack_require__.nc);\n\t\t}\n\t\tscript.setAttribute(\"data-webpack\", dataWebpackPrefix + key);\n\n\t\tscript.src = url;\n\t}\n\tinProgress[url] = [done];\n\tvar onScriptComplete = (prev, event) => {\n\t\t// avoid mem leaks in IE.\n\t\tscript.onerror = script.onload = null;\n\t\tclearTimeout(timeout);\n\t\tvar doneFns = inProgress[url];\n\t\tdelete inProgress[url];\n\t\tscript.parentNode && script.parentNode.removeChild(script);\n\t\tdoneFns && doneFns.forEach((fn) => (fn(event)));\n\t\tif(prev) return prev(event);\n\t}\n\tvar timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000);\n\tscript.onerror = onScriptComplete.bind(null, script.onerror);\n\tscript.onload = onScriptComplete.bind(null, script.onload);\n\tneedAttach && document.head.appendChild(script);\n};","// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, `.comment[data-v-3cab0376]{display:flex;gap:8px;padding:5px 10px}.comment__side[data-v-3cab0376]{display:flex;align-items:flex-start;padding-top:6px}.comment__body[data-v-3cab0376]{display:flex;flex-grow:1;flex-direction:column;container-type:inline-size}.comment__header[data-v-3cab0376]{display:flex;align-items:center;min-height:44px}.comment__actions[data-v-3cab0376]{margin-inline-start:10px !important}.comment__author[data-v-3cab0376]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:var(--color-text-maxcontrast)}.comment_loading[data-v-3cab0376],.comment__timestamp[data-v-3cab0376]{margin-inline-start:auto;text-align:end;white-space:nowrap;color:var(--color-text-maxcontrast)}.comment__editor-group[data-v-3cab0376]{position:relative}.comment__editor-description[data-v-3cab0376]{color:var(--color-text-maxcontrast);padding-block:var(--default-grid-baseline)}.comment__submit[data-v-3cab0376]{position:absolute !important;bottom:5px;inset-inline-end:0}.comment__message[data-v-3cab0376]{white-space:pre-wrap;word-break:normal;max-height:70px;overflow:hidden;margin-top:-6px}.comment__message--expanded[data-v-3cab0376]{max-height:none;overflow:visible}.rich-contenteditable__input[data-v-3cab0376]{min-height:44px;margin:0;padding:10px}`, \"\",{\"version\":3,\"sources\":[\"webpack://./apps/comments/src/components/Comment.vue\"],\"names\":[],\"mappings\":\"AAKA,0BACC,YAAA,CACA,OAAA,CACA,gBAAA,CAEA,gCACC,YAAA,CACA,sBAAA,CACA,eAAA,CAGD,gCACC,YAAA,CACA,WAAA,CACA,qBAAA,CACA,0BAAA,CAGD,kCACC,YAAA,CACA,kBAAA,CACA,eAAA,CAGD,mCACC,mCAAA,CAGD,kCACC,eAAA,CACA,kBAAA,CACA,sBAAA,CACA,mCAAA,CAGD,uEAEC,wBAAA,CACA,cAAA,CACA,kBAAA,CACA,mCAAA,CAGD,wCACC,iBAAA,CAGD,8CACC,mCAAA,CACA,0CAAA,CAGD,kCACC,4BAAA,CACA,UAAA,CACA,kBAAA,CAGD,mCACC,oBAAA,CACA,iBAAA,CACA,eAAA,CACA,eAAA,CACA,eAAA,CACA,6CACC,eAAA,CACA,gBAAA,CAKH,8CACC,eAAA,CACA,QAAA,CACA,YA5EiB\",\"sourcesContent\":[\"\\n@use \\\"sass:math\\\";\\n\\n$comment-padding: 10px;\\n\\n.comment {\\n\\tdisplay: flex;\\n\\tgap: 8px;\\n\\tpadding: 5px $comment-padding;\\n\\n\\t&__side {\\n\\t\\tdisplay: flex;\\n\\t\\talign-items: flex-start;\\n\\t\\tpadding-top: 6px;\\n\\t}\\n\\n\\t&__body {\\n\\t\\tdisplay: flex;\\n\\t\\tflex-grow: 1;\\n\\t\\tflex-direction: column;\\n\\t\\tcontainer-type: inline-size;\\n\\t}\\n\\n\\t&__header {\\n\\t\\tdisplay: flex;\\n\\t\\talign-items: center;\\n\\t\\tmin-height: 44px;\\n\\t}\\n\\n\\t&__actions {\\n\\t\\tmargin-inline-start: $comment-padding !important;\\n\\t}\\n\\n\\t&__author {\\n\\t\\toverflow: hidden;\\n\\t\\twhite-space: nowrap;\\n\\t\\ttext-overflow: ellipsis;\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t}\\n\\n\\t&_loading,\\n\\t&__timestamp {\\n\\t\\tmargin-inline-start: auto;\\n\\t\\ttext-align: end;\\n\\t\\twhite-space: nowrap;\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t}\\n\\n\\t&__editor-group {\\n\\t\\tposition: relative;\\n\\t}\\n\\n\\t&__editor-description {\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t\\tpadding-block: var(--default-grid-baseline);\\n\\t}\\n\\n\\t&__submit {\\n\\t\\tposition: absolute !important;\\n\\t\\tbottom: 5px;\\n\\t\\tinset-inline-end: 0;\\n\\t}\\n\\n\\t&__message {\\n\\t\\twhite-space: pre-wrap;\\n\\t\\tword-break: normal;\\n\\t\\tmax-height: 70px;\\n\\t\\toverflow: hidden;\\n\\t\\tmargin-top: -6px;\\n\\t\\t&--expanded {\\n\\t\\t\\tmax-height: none;\\n\\t\\t\\toverflow: visible;\\n\\t\\t}\\n\\t}\\n}\\n\\n.rich-contenteditable__input {\\n\\tmin-height: 44px;\\n\\tmargin: 0;\\n\\tpadding: $comment-padding;\\n}\\n\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, `.comments[data-v-fbac7ea2]{min-height:100%;display:flex;flex-direction:column}.comments__empty[data-v-fbac7ea2],.comments__error[data-v-fbac7ea2]{flex:1 0}.comments__retry[data-v-fbac7ea2]{margin:0 auto}.comments__info[data-v-fbac7ea2]{height:60px;color:var(--color-text-maxcontrast);text-align:center;line-height:60px}`, \"\",{\"version\":3,\"sources\":[\"webpack://./apps/comments/src/views/Comments.vue\"],\"names\":[],\"mappings\":\"AACA,2BACC,eAAA,CACA,YAAA,CACA,qBAAA,CAEA,oEAEC,QAAA,CAGD,kCACC,aAAA,CAGD,iCACC,WAAA,CACA,mCAAA,CACA,iBAAA,CACA,gBAAA\",\"sourcesContent\":[\"\\n.comments {\\n\\tmin-height: 100%;\\n\\tdisplay: flex;\\n\\tflex-direction: column;\\n\\n\\t&__empty,\\n\\t&__error {\\n\\t\\tflex: 1 0;\\n\\t}\\n\\n\\t&__retry {\\n\\t\\tmargin: 0 auto;\\n\\t}\\n\\n\\t&__info {\\n\\t\\theight: 60px;\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t\\ttext-align: center;\\n\\t\\tline-height: 60px;\\n\\t}\\n}\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","\n\n","import mod from \"-!../vue-loader/lib/index.js??vue-loader-options!./Refresh.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../vue-loader/lib/index.js??vue-loader-options!./Refresh.vue?vue&type=script&lang=js\"","import { render, staticRenderFns } from \"./Refresh.vue?vue&type=template&id=2864f909\"\nimport script from \"./Refresh.vue?vue&type=script&lang=js\"\nexport * from \"./Refresh.vue?vue&type=script&lang=js\"\n\n\n/* normalize component */\nimport normalizer from \"!../vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('span',_vm._b({staticClass:\"material-design-icon refresh-icon\",attrs:{\"aria-hidden\":_vm.title ? null : 'true',\"aria-label\":_vm.title,\"role\":\"img\"},on:{\"click\":function($event){return _vm.$emit('click', $event)}}},'span',_vm.$attrs,false),[_c('svg',{staticClass:\"material-design-icon__svg\",attrs:{\"fill\":_vm.fillColor,\"width\":_vm.size,\"height\":_vm.size,\"viewBox\":\"0 0 24 24\"}},[_c('path',{attrs:{\"d\":\"M17.65,6.35C16.2,4.9 14.21,4 12,4A8,8 0 0,0 4,12A8,8 0 0,0 12,20C15.73,20 18.84,17.45 19.73,14H17.65C16.83,16.33 14.61,18 12,18A6,6 0 0,1 6,12A6,6 0 0,1 12,6C13.66,6 15.14,6.69 16.22,7.78L13,11H20V4L17.65,6.35Z\"}},[(_vm.title)?_c('title',[_vm._v(_vm._s(_vm.title))]):_vm._e()])])])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import mod from \"-!../vue-loader/lib/index.js??vue-loader-options!./MessageReplyTextOutline.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../vue-loader/lib/index.js??vue-loader-options!./MessageReplyTextOutline.vue?vue&type=script&lang=js\"","\n\n","import { render, staticRenderFns } from \"./MessageReplyTextOutline.vue?vue&type=template&id=5d6c4e92\"\nimport script from \"./MessageReplyTextOutline.vue?vue&type=script&lang=js\"\nexport * from \"./MessageReplyTextOutline.vue?vue&type=script&lang=js\"\n\n\n/* normalize component */\nimport normalizer from \"!../vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('span',_vm._b({staticClass:\"material-design-icon message-reply-text-outline-icon\",attrs:{\"aria-hidden\":_vm.title ? null : 'true',\"aria-label\":_vm.title,\"role\":\"img\"},on:{\"click\":function($event){return _vm.$emit('click', $event)}}},'span',_vm.$attrs,false),[_c('svg',{staticClass:\"material-design-icon__svg\",attrs:{\"fill\":_vm.fillColor,\"width\":_vm.size,\"height\":_vm.size,\"viewBox\":\"0 0 24 24\"}},[_c('path',{attrs:{\"d\":\"M9 11H18V13H9V11M18 7H6V9H18V7M22 4V22L18 18H4C2.9 18 2 17.11 2 16V4C2 2.9 2.9 2 4 2H20C21.1 2 22 2.89 22 4M20 4H4V16H18.83L20 17.17V4Z\"}},[(_vm.title)?_c('title',[_vm._v(_vm._s(_vm.title))]):_vm._e()])])])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { generateRemoteUrl } from '@nextcloud/router'\n\nconst getRootPath = function() {\n\treturn generateRemoteUrl('dav/comments')\n}\n\nexport { getRootPath }\n","/**\n * SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\n/**\n * @param {any} value -\n * @param {any} passes -\n */\nexport function decodeHtmlEntities(value, passes = 1) {\n\tconst parser = new DOMParser()\n\tlet decoded = value\n\tfor (let i = 0; i < passes; i++) {\n\t\tdecoded = parser.parseFromString(decoded, 'text/html').documentElement.textContent\n\t}\n\treturn decoded\n}\n","/**\n * SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { createClient } from 'webdav'\nimport { getRootPath } from '../utils/davUtils.js'\nimport { getRequestToken, onRequestTokenUpdate } from '@nextcloud/auth'\n\n// init webdav client\nconst client = createClient(getRootPath())\n\n// set CSRF token header\nconst setHeaders = (token) => {\n\tclient.setHeaders({\n\t\t// Add this so the server knows it is an request from the browser\n\t\t'X-Requested-With': 'XMLHttpRequest',\n\t\t// Inject user auth\n\t\trequesttoken: token ?? '',\n\t})\n}\n\n// refresh headers when request token changes\nonRequestTokenUpdate(setHeaders)\nsetHeaders(getRequestToken())\n\nexport default client\n","/**\n * SPDX-FileCopyrightText: 2024 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { defineStore } from 'pinia'\n\nexport const useDeletedCommentLimbo = defineStore('deletedCommentLimbo', {\n\tstate: () => ({\n\t\tidsInLimbo: [],\n\t}),\n\tactions: {\n\t\taddId(id) {\n\t\t\tthis.idsInLimbo.push(id)\n\t\t},\n\n\t\tremoveId(id) {\n\t\t\tconst index = this.idsInLimbo.indexOf(id)\n\t\t\tif (index > -1) {\n\t\t\t\tthis.idsInLimbo.splice(index, 1)\n\t\t\t}\n\t\t},\n\n\t\tcheckForId(id) {\n\t\t\tthis.idsInLimbo.includes(id)\n\t\t},\n\t},\n})\n","/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { getLoggerBuilder } from '@nextcloud/logger'\n\nexport default getLoggerBuilder()\n\t.setApp('comments')\n\t.detectUser()\n\t.build()\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { showError, showUndo, TOAST_UNDO_TIMEOUT } from '@nextcloud/dialogs'\nimport NewComment from '../services/NewComment.js'\nimport DeleteComment from '../services/DeleteComment.js'\nimport EditComment from '../services/EditComment.js'\nimport { mapStores } from 'pinia'\nimport { useDeletedCommentLimbo } from '../store/deletedCommentLimbo.js'\nimport logger from '../logger.js'\n\nexport default {\n\tprops: {\n\t\tid: {\n\t\t\ttype: Number,\n\t\t\tdefault: null,\n\t\t},\n\t\tmessage: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\t\tresourceId: {\n\t\t\ttype: [String, Number],\n\t\t\trequired: true,\n\t\t},\n\t\tresourceType: {\n\t\t\ttype: String,\n\t\t\tdefault: 'files',\n\t\t},\n\t},\n\n\tdata() {\n\t\treturn {\n\t\t\tdeleted: false,\n\t\t\tediting: false,\n\t\t\tloading: false,\n\t\t}\n\t},\n\n\tcomputed: {\n\t\t...mapStores(useDeletedCommentLimbo),\n\t},\n\n\tmethods: {\n\t\t// EDITION\n\t\tonEdit() {\n\t\t\tthis.editing = true\n\t\t},\n\t\tonEditCancel() {\n\t\t\tthis.editing = false\n\t\t\t// Restore original value\n\t\t\tthis.updateLocalMessage(this.message)\n\t\t},\n\t\tasync onEditComment(message) {\n\t\t\tthis.loading = true\n\t\t\ttry {\n\t\t\t\tawait EditComment(this.resourceType, this.resourceId, this.id, message)\n\t\t\t\tlogger.debug('Comment edited', { resourceType: this.resourceType, resourceId: this.resourceId, id: this.id, message })\n\t\t\t\tthis.$emit('update:message', message)\n\t\t\t\tthis.editing = false\n\t\t\t} catch (error) {\n\t\t\t\tshowError(t('comments', 'An error occurred while trying to edit the comment'))\n\t\t\t\tconsole.error(error)\n\t\t\t} finally {\n\t\t\t\tthis.loading = false\n\t\t\t}\n\t\t},\n\n\t\t// DELETION\n\t\tonDeleteWithUndo() {\n\t\t\tthis.$emit('delete')\n\t\t\tthis.deleted = true\n\t\t\tthis.deletedCommentLimboStore.addId(this.id)\n\t\t\tconst timeOutDelete = setTimeout(this.onDelete, TOAST_UNDO_TIMEOUT)\n\t\t\tshowUndo(t('comments', 'Comment deleted'), () => {\n\t\t\t\tclearTimeout(timeOutDelete)\n\t\t\t\tthis.deleted = false\n\t\t\t\tthis.deletedCommentLimboStore.removeId(this.id)\n\t\t\t})\n\t\t},\n\t\tasync onDelete() {\n\t\t\ttry {\n\t\t\t\tawait DeleteComment(this.resourceType, this.resourceId, this.id)\n\t\t\t\tlogger.debug('Comment deleted', { resourceType: this.resourceType, resourceId: this.resourceId, id: this.id })\n\t\t\t\tthis.$emit('delete', this.id)\n\t\t\t} catch (error) {\n\t\t\t\tshowError(t('comments', 'An error occurred while trying to delete the comment'))\n\t\t\t\tconsole.error(error)\n\t\t\t\tthis.deleted = false\n\t\t\t\tthis.deletedCommentLimboStore.removeId(this.id)\n\t\t\t}\n\t\t},\n\n\t\t// CREATION\n\t\tasync onNewComment(message) {\n\t\t\tthis.loading = true\n\t\t\ttry {\n\t\t\t\tconst newComment = await NewComment(this.resourceType, this.resourceId, message)\n\t\t\t\tlogger.debug('New comment posted', { resourceType: this.resourceType, resourceId: this.resourceId, newComment })\n\t\t\t\tthis.$emit('new', newComment)\n\n\t\t\t\t// Clear old content\n\t\t\t\tthis.$emit('update:message', '')\n\t\t\t\tthis.localMessage = ''\n\t\t\t} catch (error) {\n\t\t\t\tshowError(t('comments', 'An error occurred while trying to create the comment'))\n\t\t\t\tconsole.error(error)\n\t\t\t} finally {\n\t\t\t\tthis.loading = false\n\t\t\t}\n\t\t},\n\t},\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport client from './DavClient.js'\n\n/**\n * Edit an existing comment\n *\n * @param {string} resourceType the resource type\n * @param {number} resourceId the resource ID\n * @param {number} commentId the comment iD\n * @param {string} message the message content\n */\nexport default async function(resourceType, resourceId, commentId, message) {\n\tconst commentPath = ['', resourceType, resourceId, commentId].join('/')\n\n\treturn await client.customRequest(commentPath, Object.assign({\n\t\tmethod: 'PROPPATCH',\n\t\tdata: `\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t${message}\n\t\t\t\t\n\t\t\t\n\t\t\t`,\n\t}))\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport client from './DavClient.js'\n\n/**\n * Delete a comment\n *\n * @param {string} resourceType the resource type\n * @param {number} resourceId the resource ID\n * @param {number} commentId the comment iD\n */\nexport default async function(resourceType, resourceId, commentId) {\n\tconst commentPath = ['', resourceType, resourceId, commentId].join('/')\n\n\t// Fetch newly created comment data\n\tawait client.deleteFile(commentPath)\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { getCurrentUser } from '@nextcloud/auth'\nimport { getRootPath } from '../utils/davUtils.js'\nimport { decodeHtmlEntities } from '../utils/decodeHtmlEntities.js'\nimport axios from '@nextcloud/axios'\nimport client from './DavClient.js'\n\n/**\n * Retrieve the comments list\n *\n * @param {string} resourceType the resource type\n * @param {number} resourceId the resource ID\n * @param {string} message the message\n * @return {object} the new comment\n */\nexport default async function(resourceType, resourceId, message) {\n\tconst resourcePath = ['', resourceType, resourceId].join('/')\n\n\tconst response = await axios.post(getRootPath() + resourcePath, {\n\t\tactorDisplayName: getCurrentUser().displayName,\n\t\tactorId: getCurrentUser().uid,\n\t\tactorType: 'users',\n\t\tcreationDateTime: (new Date()).toUTCString(),\n\t\tmessage,\n\t\tobjectType: resourceType,\n\t\tverb: 'comment',\n\t})\n\n\t// Retrieve comment id from resource location\n\tconst commentId = parseInt(response.headers['content-location'].split('/').pop())\n\tconst commentPath = resourcePath + '/' + commentId\n\n\t// Fetch newly created comment data\n\tconst comment = await client.stat(commentPath, {\n\t\tdetails: true,\n\t})\n\n\tconst props = comment.data.props\n\t// Decode twice to handle potentially double-encoded entities\n\t// FIXME Remove this once https://github.com/nextcloud/server/issues/29306\n\t// is resolved\n\tprops.actorDisplayName = decodeHtmlEntities(props.actorDisplayName, 2)\n\tprops.message = decodeHtmlEntities(props.message, 2)\n\n\treturn comment.data\n}\n","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=script&lang=js\"","\n\n\n\n\n\n","\n import API from \"!../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=style&index=0&id=3cab0376&prod&lang=scss&scoped=true\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\noptions.insert = insertFn.bind(null, \"head\");\noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comment.vue?vue&type=style&index=0&id=3cab0376&prod&lang=scss&scoped=true\";\n export default content && content.locals ? content.locals : undefined;\n","import { render, staticRenderFns } from \"./Comment.vue?vue&type=template&id=3cab0376&scoped=true\"\nimport script from \"./Comment.vue?vue&type=script&lang=js\"\nexport * from \"./Comment.vue?vue&type=script&lang=js\"\nimport style0 from \"./Comment.vue?vue&type=style&index=0&id=3cab0376&prod&lang=scss&scoped=true\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"3cab0376\",\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c(_vm.tag,{directives:[{name:\"show\",rawName:\"v-show\",value:(!_vm.deleted && !_vm.isLimbo),expression:\"!deleted && !isLimbo\"}],tag:\"component\",staticClass:\"comment\",class:{'comment--loading': _vm.loading}},[_c('div',{staticClass:\"comment__side\"},[_c('NcAvatar',{staticClass:\"comment__avatar\",attrs:{\"display-name\":_vm.actorDisplayName,\"user\":_vm.actorId,\"size\":32}})],1),_vm._v(\" \"),_c('div',{staticClass:\"comment__body\"},[_c('div',{staticClass:\"comment__header\"},[_c('span',{staticClass:\"comment__author\"},[_vm._v(_vm._s(_vm.actorDisplayName))]),_vm._v(\" \"),(_vm.isOwnComment && _vm.id && !_vm.loading)?_c('NcActions',{staticClass:\"comment__actions\"},[(!_vm.editing)?[_c('NcActionButton',{attrs:{\"close-after-click\":\"\"},on:{\"click\":_vm.onEdit},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconPencilOutline',{attrs:{\"size\":20}})]},proxy:true}],null,false,3345211262)},[_vm._v(\"\\n\\t\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Edit comment'))+\"\\n\\t\\t\\t\\t\\t\")]),_vm._v(\" \"),_c('NcActionSeparator'),_vm._v(\" \"),_c('NcActionButton',{attrs:{\"close-after-click\":\"\"},on:{\"click\":_vm.onDeleteWithUndo},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconTrashCanOutline',{attrs:{\"size\":20}})]},proxy:true}],null,false,1034796883)},[_vm._v(\"\\n\\t\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Delete comment'))+\"\\n\\t\\t\\t\\t\\t\")])]:_c('NcActionButton',{on:{\"click\":_vm.onEditCancel},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconClose',{attrs:{\"size\":20}})]},proxy:true}],null,false,2888946197)},[_vm._v(\"\\n\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Cancel edit'))+\"\\n\\t\\t\\t\\t\")])],2):_vm._e(),_vm._v(\" \"),(_vm.id && _vm.loading)?_c('div',{staticClass:\"comment_loading icon-loading-small\"}):(_vm.creationDateTime)?_c('NcDateTime',{staticClass:\"comment__timestamp\",attrs:{\"timestamp\":_vm.timestamp,\"ignore-seconds\":true}}):_vm._e()],1),_vm._v(\" \"),(_vm.editor || _vm.editing)?_c('form',{staticClass:\"comment__editor\",on:{\"submit\":function($event){$event.preventDefault();}}},[_c('div',{staticClass:\"comment__editor-group\"},[_c('NcRichContenteditable',{ref:\"editor\",attrs:{\"auto-complete\":_vm.autoComplete,\"contenteditable\":!_vm.loading,\"label\":_vm.editor ? _vm.t('comments', 'New comment') : _vm.t('comments', 'Edit comment'),\"placeholder\":_vm.t('comments', 'Write a comment …'),\"value\":_vm.localMessage,\"user-data\":_vm.userData,\"aria-describedby\":\"tab-comments__editor-description\"},on:{\"update:value\":_vm.updateLocalMessage,\"submit\":_vm.onSubmit}}),_vm._v(\" \"),_c('div',{staticClass:\"comment__submit\"},[_c('NcButton',{attrs:{\"type\":\"tertiary-no-background\",\"native-type\":\"submit\",\"aria-label\":_vm.t('comments', 'Post comment'),\"disabled\":_vm.isEmptyMessage},on:{\"click\":_vm.onSubmit},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [(_vm.loading)?_c('NcLoadingIcon'):_c('IconArrowRight',{attrs:{\"size\":20}})]},proxy:true}],null,false,758946661)})],1)],1),_vm._v(\" \"),_c('div',{staticClass:\"comment__editor-description\",attrs:{\"id\":\"tab-comments__editor-description\"}},[_vm._v(\"\\n\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', '@ for mentions, : for emoji, / for smart picker'))+\"\\n\\t\\t\\t\")])]):_c('NcRichText',{staticClass:\"comment__message\",class:{'comment__message--expanded': _vm.expanded},attrs:{\"text\":_vm.richContent.message,\"arguments\":_vm.richContent.mentions},nativeOn:{\"click\":function($event){return _vm.onExpand.apply(null, arguments)}}})],1)])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\nimport axios from '@nextcloud/axios';\nimport { getCurrentUser } from '@nextcloud/auth';\nimport { loadState } from '@nextcloud/initial-state';\nimport { generateOcsUrl } from '@nextcloud/router';\nimport { defineComponent } from 'vue';\nexport default defineComponent({\n props: {\n resourceId: {\n type: Number,\n required: true,\n },\n resourceType: {\n type: String,\n default: 'files',\n },\n },\n data() {\n return {\n editorData: {\n actorDisplayName: getCurrentUser().displayName,\n actorId: getCurrentUser().uid,\n key: 'editor',\n },\n userData: {},\n };\n },\n methods: {\n /**\n * Autocomplete @mentions\n *\n * @param {string} search the query\n * @param {Function} callback the callback to process the results with\n */\n async autoComplete(search, callback) {\n const { data } = await axios.get(generateOcsUrl('core/autocomplete/get'), {\n params: {\n search,\n itemType: 'files',\n itemId: this.resourceId,\n sorter: 'commenters|share-recipients',\n limit: loadState('comments', 'maxAutoCompleteResults'),\n },\n });\n // Save user data so it can be used by the editor to replace mentions\n data.ocs.data.forEach(user => { this.userData[user.id] = user; });\n return callback(Object.values(this.userData));\n },\n /**\n * Make sure we have all mentions as Array of objects\n *\n * @param mentions the mentions list\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n genMentionsData(mentions) {\n Object.values(mentions)\n .flat()\n .forEach(mention => {\n this.userData[mention.mentionId] = {\n // TODO: support groups\n icon: 'icon-user',\n id: mention.mentionId,\n label: mention.mentionDisplayName,\n source: 'users',\n primary: getCurrentUser()?.uid === mention.mentionId,\n };\n });\n return this.userData;\n },\n },\n});\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\nimport { parseXML } from 'webdav';\n// https://github.com/perry-mitchell/webdav-client/issues/339\nimport { processResponsePayload } from 'webdav/dist/node/response.js';\nimport { prepareFileFromProps } from 'webdav/dist/node/tools/dav.js';\nimport client from './DavClient.js';\nexport const DEFAULT_LIMIT = 20;\n/**\n * Retrieve the comments list\n *\n * @param {object} data destructuring object\n * @param {string} data.resourceType the resource type\n * @param {number} data.resourceId the resource ID\n * @param {object} [options] optional options for axios\n * @param {number} [options.offset] the pagination offset\n * @param {number} [options.limit] the pagination limit, defaults to 20\n * @param {Date} [options.datetime] optional date to query\n * @return {{data: object[]}} the comments list\n */\nexport const getComments = async function ({ resourceType, resourceId }, options) {\n const resourcePath = ['', resourceType, resourceId].join('/');\n const datetime = options.datetime ? `${options.datetime.toISOString()}` : '';\n const response = await client.customRequest(resourcePath, Object.assign({\n method: 'REPORT',\n data: `\n\t\t\t\n\t\t\t\t${options.limit ?? DEFAULT_LIMIT}\n\t\t\t\t${options.offset || 0}\n\t\t\t\t${datetime}\n\t\t\t`,\n }, options));\n const responseData = await response.text();\n const result = await parseXML(responseData);\n const stat = getDirectoryFiles(result, true);\n return processResponsePayload(response, stat, true);\n};\n// https://github.com/perry-mitchell/webdav-client/blob/8d9694613c978ce7404e26a401c39a41f125f87f/source/operations/directoryContents.ts\nconst getDirectoryFiles = function (result, isDetailed = false) {\n // Extract the response items (directory contents)\n const { multistatus: { response: responseItems }, } = result;\n // Map all items to a consistent output structure (results)\n return responseItems.map(item => {\n // Each item should contain a stat object\n const props = item.propstat.prop;\n return prepareFileFromProps(props, props.id.toString(), isDetailed);\n });\n};\n","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comments.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comments.vue?vue&type=script&lang=js\"","\n\n\n\n\n\n\n","/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\nimport client from './DavClient.js';\n/**\n * Mark comments older than the date timestamp as read\n *\n * @param resourceType the resource type\n * @param resourceId the resource ID\n * @param date the date object\n */\nexport const markCommentsAsRead = (resourceType, resourceId, date) => {\n const resourcePath = ['', resourceType, resourceId].join('/');\n const readMarker = date.toUTCString();\n return client.customRequest(resourcePath, {\n method: 'PROPPATCH',\n data: `\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t${readMarker}\n\t\t\t\t\n\t\t\t\n\t\t\t`,\n });\n};\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\n/**\n * Creates a cancelable axios 'request object'.\n *\n * @param {Function} request the axios promise request\n * @return {object}\n */\nconst cancelableRequest = function(request) {\n\tconst controller = new AbortController()\n\tconst signal = controller.signal\n\n\t/**\n\t * Execute the request\n\t *\n\t * @param {string} url the url to send the request to\n\t * @param {object} [options] optional config for the request\n\t */\n\tconst fetch = async function(url, options) {\n\t\tconst response = await request(\n\t\t\turl,\n\t\t\tObject.assign({ signal }, options),\n\t\t)\n\t\treturn response\n\t}\n\n\treturn {\n\t\trequest: fetch,\n\t\tabort: () => controller.abort(),\n\t}\n}\n\nexport default cancelableRequest\n","\n import API from \"!../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comments.vue?vue&type=style&index=0&id=fbac7ea2&prod&lang=scss&scoped=true\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\noptions.insert = insertFn.bind(null, \"head\");\noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Comments.vue?vue&type=style&index=0&id=fbac7ea2&prod&lang=scss&scoped=true\";\n export default content && content.locals ? content.locals : undefined;\n","import { render, staticRenderFns } from \"./Comments.vue?vue&type=template&id=fbac7ea2&scoped=true\"\nimport script from \"./Comments.vue?vue&type=script&lang=js\"\nexport * from \"./Comments.vue?vue&type=script&lang=js\"\nimport style0 from \"./Comments.vue?vue&type=style&index=0&id=fbac7ea2&prod&lang=scss&scoped=true\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"fbac7ea2\",\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('div',{directives:[{name:\"element-visibility\",rawName:\"v-element-visibility\",value:(_vm.onVisibilityChange),expression:\"onVisibilityChange\"}],staticClass:\"comments\",class:{ 'icon-loading': _vm.isFirstLoading }},[_c('Comment',_vm._b({staticClass:\"comments__writer\",attrs:{\"auto-complete\":_vm.autoComplete,\"resource-type\":_vm.resourceType,\"editor\":true,\"user-data\":_vm.userData,\"resource-id\":_vm.currentResourceId},on:{\"new\":_vm.onNewComment}},'Comment',_vm.editorData,false)),_vm._v(\" \"),(!_vm.isFirstLoading)?[(!_vm.hasComments && _vm.done)?_c('NcEmptyContent',{staticClass:\"comments__empty\",attrs:{\"name\":_vm.t('comments', 'No comments yet, start the conversation!')},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconMessageReplyTextOutline')]},proxy:true}],null,false,326612300)}):_c('ul',_vm._l((_vm.comments),function(comment){return _c('Comment',_vm._b({key:comment.props.id,staticClass:\"comments__list\",attrs:{\"tag\":\"li\",\"auto-complete\":_vm.autoComplete,\"resource-type\":_vm.resourceType,\"message\":comment.props.message,\"resource-id\":_vm.currentResourceId,\"user-data\":_vm.genMentionsData(comment.props.mentions)},on:{\"update:message\":function($event){return _vm.$set(comment.props, \"message\", $event)},\"delete\":_vm.onDelete}},'Comment',comment.props,false))}),1),_vm._v(\" \"),(_vm.loading && !_vm.isFirstLoading)?_c('div',{staticClass:\"comments__info icon-loading\"}):(_vm.hasComments && _vm.done)?_c('div',{staticClass:\"comments__info\"},[_vm._v(\"\\n\\t\\t\\t\"+_vm._s(_vm.t('comments', 'No more messages'))+\"\\n\\t\\t\")]):(_vm.error)?[_c('NcEmptyContent',{staticClass:\"comments__error\",attrs:{\"name\":_vm.error},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconAlertCircleOutline')]},proxy:true}],null,false,3663249556)}),_vm._v(\" \"),_c('NcButton',{staticClass:\"comments__retry\",on:{\"click\":_vm.getComments},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('IconRefresh')]},proxy:true}],null,false,2997625269)},[_vm._v(\"\\n\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Retry'))+\"\\n\\t\\t\\t\")])]:_vm._e()]:_vm._e()],2)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { getCSPNonce } from '@nextcloud/auth'\nimport { t, n } from '@nextcloud/l10n'\nimport { PiniaVuePlugin, createPinia } from 'pinia'\nimport Vue from 'vue'\nimport CommentsApp from '../views/Comments.vue'\nimport logger from '../logger.js'\n\nVue.use(PiniaVuePlugin)\n// eslint-disable-next-line camelcase\n__webpack_nonce__ = getCSPNonce()\n\n// Add translates functions\nVue.mixin({\n\tdata() {\n\t\treturn {\n\t\t\tlogger,\n\t\t}\n\t},\n\tmethods: {\n\t\tt,\n\t\tn,\n\t},\n})\n\nexport default class CommentInstance {\n\n\t/**\n\t * Initialize a new Comments instance for the desired type\n\t *\n\t * @param {string} resourceType the comments endpoint type\n\t * @param {object} options the vue options (propsData, parent, el...)\n\t */\n\tconstructor(resourceType = 'files', options = {}) {\n\t\tconst pinia = createPinia()\n\n\t\t// Merge options and set `resourceType` property\n\t\toptions = {\n\t\t\t...options,\n\t\t\tpropsData: {\n\t\t\t\t...(options.propsData ?? {}),\n\t\t\t\tresourceType,\n\t\t\t},\n\t\t\tpinia,\n\t\t}\n\t\t// Init Comments component\n\t\tconst View = Vue.extend(CommentsApp)\n\t\treturn new View(options)\n\t}\n\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport CommentsInstance from './services/CommentsInstance.js'\n\n// Init Comments\nif (window.OCA && !window.OCA.Comments) {\n\tObject.assign(window.OCA, { Comments: {} })\n}\n\n// Init Comments App view\nObject.assign(window.OCA.Comments, { View: CommentsInstance })\nconsole.debug('OCA.Comments.View initialized')\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \"-\" + chunkId + \".js?v=\" + {\"640\":\"d4c5c018803ee8751b2a\",\"780\":\"e3ee44fa7690af29d8d7\",\"3564\":\"29e8338d43e0d4bd3995\",\"4508\":\"40b53e5d2d42025bc3a7\",\"5258\":\"80a9b9a289e4eb695373\",\"5810\":\"b550a24d46f75f92c2d5\",\"5862\":\"8bc76a21d9622c29e1a9\",\"7471\":\"6423b9b898ffefeb7d1d\",\"7838\":\"37c7bd8d5fada1bd542c\"}[chunkId] + \"\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = (module) => {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","__webpack_require__.j = 7062;","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/^blob:/, \"\").replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = document.baseURI || self.location.href;\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t7062: 0\n};\n\n__webpack_require__.f.j = (chunkId, promises) => {\n\t\t// JSONP chunk loading for javascript\n\t\tvar installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined;\n\t\tif(installedChunkData !== 0) { // 0 means \"already installed\".\n\n\t\t\t// a Promise means \"currently loading\".\n\t\t\tif(installedChunkData) {\n\t\t\t\tpromises.push(installedChunkData[2]);\n\t\t\t} else {\n\t\t\t\tif(true) { // all chunks have JS\n\t\t\t\t\t// setup Promise in chunk cache\n\t\t\t\t\tvar promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject]));\n\t\t\t\t\tpromises.push(installedChunkData[2] = promise);\n\n\t\t\t\t\t// start chunk loading\n\t\t\t\t\tvar url = __webpack_require__.p + __webpack_require__.u(chunkId);\n\t\t\t\t\t// create error before stack unwound to get useful stacktrace later\n\t\t\t\t\tvar error = new Error();\n\t\t\t\t\tvar loadingEnded = (event) => {\n\t\t\t\t\t\tif(__webpack_require__.o(installedChunks, chunkId)) {\n\t\t\t\t\t\t\tinstalledChunkData = installedChunks[chunkId];\n\t\t\t\t\t\t\tif(installedChunkData !== 0) installedChunks[chunkId] = undefined;\n\t\t\t\t\t\t\tif(installedChunkData) {\n\t\t\t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n\t\t\t\t\t\t\t\tvar realSrc = event && event.target && event.target.src;\n\t\t\t\t\t\t\t\terror.message = 'Loading chunk ' + chunkId + ' failed.\\n(' + errorType + ': ' + realSrc + ')';\n\t\t\t\t\t\t\t\terror.name = 'ChunkLoadError';\n\t\t\t\t\t\t\t\terror.type = errorType;\n\t\t\t\t\t\t\t\terror.request = realSrc;\n\t\t\t\t\t\t\t\tinstalledChunkData[1](error);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\t\t\t\t\t__webpack_require__.l(url, loadingEnded, \"chunk-\" + chunkId, chunkId);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n};\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar chunkIds = data[0];\n\tvar moreModules = data[1];\n\tvar runtime = data[2];\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = self[\"webpackChunknextcloud\"] = self[\"webpackChunknextcloud\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","__webpack_require__.nc = undefined;","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [4208], () => (__webpack_require__(93186)))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n"],"names":["deferred","inProgress","dataWebpackPrefix","___CSS_LOADER_EXPORT___","push","module","id","name","emits","props","title","type","String","fillColor","default","size","Number","_vm","this","_c","_self","_b","staticClass","attrs","on","$event","$emit","$attrs","_v","_s","_e","getRootPath","generateRemoteUrl","decodeHtmlEntities","value","passes","arguments","length","undefined","parser","DOMParser","decoded","i","parseFromString","documentElement","textContent","client","createClient","setHeaders","token","requesttoken","onRequestTokenUpdate","getRequestToken","useDeletedCommentLimbo","defineStore","state","idsInLimbo","actions","addId","removeId","index","indexOf","splice","checkForId","includes","getLoggerBuilder","setApp","detectUser","build","message","resourceId","required","resourceType","data","deleted","editing","loading","computed","mapStores","methods","onEdit","onEditCancel","updateLocalMessage","onEditComment","async","commentId","commentPath","join","customRequest","Object","assign","method","EditComment","logger","debug","error","showError","t","console","onDeleteWithUndo","deletedCommentLimboStore","timeOutDelete","setTimeout","onDelete","TOAST_UNDO_TIMEOUT","showUndo","clearTimeout","deleteFile","DeleteComment","onNewComment","newComment","resourcePath","response","axios","post","actorDisplayName","getCurrentUser","displayName","actorId","uid","actorType","creationDateTime","Date","toUTCString","objectType","verb","parseInt","headers","split","pop","comment","stat","details","NewComment","localMessage","components","IconArrowRight","IconClose","IconTrashCanOutline","IconPencilOutline","NcActionButton","NcActions","NcActionSeparator","NcAvatar","NcButton","NcDateTime","NcLoadingIcon","NcRichContenteditable","NcRichText","mixins","CommentMixin","inheritAttrs","editor","Boolean","autoComplete","Function","userData","tag","expanded","submitted","isOwnComment","richContent","mentions","keys","forEach","user","key","regex","RegExp","replace","component","NcUserBubble","label","primary","isEmptyMessage","trim","timestamp","parse","isLimbo","watch","beforeMount","toString","onSubmit","$nextTick","$refs","$el","focus","onExpand","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","locals","directives","rawName","expression","class","scopedSlots","_u","fn","proxy","preventDefault","ref","nativeOn","apply","defineComponent","editorData","search","callback","get","generateOcsUrl","params","itemType","itemId","sorter","limit","loadState","ocs","values","genMentionsData","flat","mention","mentionId","icon","mentionDisplayName","source","getComments","_ref","datetime","toISOString","offset","responseData","text","result","parseXML","getDirectoryFiles","processResponsePayload","isDetailed","multistatus","responseItems","map","item","propstat","prop","prepareFileFromProps","Comment","NcEmptyContent","IconRefresh","IconMessageReplyTextOutline","IconAlertCircleOutline","elementVisibility","CommentView","done","currentResourceId","comments","cancelRequest","hasComments","isFirstLoading","onVisibilityChange","isVisible","markCommentsAsRead","date","readMarker","e","update","resetState","onScrollBottomReached","request","abort","controller","AbortController","signal","url","cancelableRequest","unshift","findIndex","_l","$set","Vue","use","PiniaVuePlugin","__webpack_nonce__","getCSPNonce","mixin","n","window","OCA","Comments","View","constructor","pinia","createPinia","propsData","extend","CommentsApp","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","exports","loaded","__webpack_modules__","call","m","O","chunkIds","priority","notFulfilled","Infinity","fulfilled","j","every","r","getter","__esModule","d","a","definition","o","defineProperty","enumerable","f","chunkId","Promise","all","reduce","promises","u","g","globalThis","obj","prototype","hasOwnProperty","l","script","needAttach","scripts","document","getElementsByTagName","s","getAttribute","createElement","charset","timeout","nc","setAttribute","src","onScriptComplete","prev","event","onerror","onload","doneFns","parentNode","removeChild","bind","target","head","appendChild","Symbol","toStringTag","nmd","paths","children","scriptUrl","importScripts","location","currentScript","tagName","toUpperCase","test","Error","p","b","baseURI","self","href","installedChunks","installedChunkData","promise","resolve","reject","errorType","realSrc","webpackJsonpCallback","parentChunkLoadingFunction","moreModules","runtime","some","chunkLoadingGlobal","__webpack_exports__"],"sourceRoot":""} \ No newline at end of file diff --git a/dist/comments-comments-tab.js b/dist/comments-comments-tab.js index 47d0f699054..329fc2a4716 100644 --- a/dist/comments-comments-tab.js +++ b/dist/comments-comments-tab.js @@ -1,2 +1,2 @@ -(()=>{var e,o,n,r={1836:(e,o,n)=>{"use strict";var r=n(21777),i=n(81222),a=n(51651),s=n(85471),c=n(96689),d=n(45505),l=n(54290),u=n(90176),m=n(35550);var f=n(65899);let p,b;function v(){window.OCA.Activity.registerSidebarAction({mount:async(e,t)=>{let{fileInfo:o,reload:r}=t;const i=(0,f.Ey)();if(!p){const{default:e}=await Promise.all([n.e(4208),n.e(7462),n.e(8057)]).then(n.bind(n,98057));p=s.Ay.extend(e)}b=new p({el:e,pinia:i,propsData:{reloadCallback:r,resourceId:o.id}}),c.A.info("Comments plugin mounted in Activity sidebar action",{fileInfo:o})},unmount:()=>{b&&b.$destroy()}}),window.OCA.Activity.registerSidebarEntries(async e=>{let{fileInfo:t,limit:o,offset:r}=e;const{data:i}=await async function(e,t){let{resourceType:o,resourceId:n}=e;const r=["",o,n].join("/"),i=t.datetime?`${t.datetime.toISOString()}`:"",a=await m.A.customRequest(r,Object.assign({method:"REPORT",data:`\n\t\t\t\n\t\t\t\t${t.limit??20}\n\t\t\t\t${t.offset||0}\n\t\t\t\t${i}\n\t\t\t`},t)),s=await a.text(),c=function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const{multistatus:{response:o}}=e;return o.map(e=>{const o=e.propstat.prop;return(0,u.ch)(o,o.id.toString(),t)})}(await(0,d.h4)(s),!0);return(0,l.hq)(a,c,!0)}({resourceType:"files",resourceId:t.id},{limit:o,offset:r});c.A.debug("Loaded comments",{fileInfo:t,comments:i});const{default:f}=await Promise.all([n.e(4208),n.e(7462),n.e(3920)]).then(n.bind(n,93920)),p=s.Ay.extend(f);return i.map(e=>({_CommentsViewInstance:void 0,timestamp:(0,a.A)(e.props?.creationDateTime).toDate().getTime(),mount(o,n){let{reload:r}=n;this._CommentsViewInstance=new p({el:o,propsData:{comment:e,resourceId:t.id,reloadCallback:r}})},unmount(){this._CommentsViewInstance?.$destroy()}}))}),window.OCA.Activity.registerSidebarFilter(e=>"comments"!==e.type),c.A.info("Comments plugin registered for Activity sidebar action")}if(s.Ay.use(f.R2),n.nc=(0,r.aV)(),(0,i.C)("comments","activityEnabled",!1)&&void 0!==OCA?.Activity?.registerSidebarAction)window.addEventListener("DOMContentLoaded",function(){v()});else{let e=null;const o=new OCA.Files.Sidebar.Tab({id:"comments",name:t("comments","Comments"),iconSvg:'',async mount(t,o,n){e&&e.$destroy(),e=new OCA.Comments.View("files",{parent:n,propsData:{resourceId:o.id}}),await e.update(o.id),e.$mount(t)},update(t){e.update(t.id)},destroy(){e.$destroy(),e=null},scrollBottomReached(){e.onScrollBottomReached()}});window.addEventListener("DOMContentLoaded",function(){OCA.Files&&OCA.Files.Sidebar&&OCA.Files.Sidebar.registerTab(o)})}},17003:(e,t,o)=>{"use strict";o.d(t,{e:()=>r});var n=o(63814);const r=function(){return(0,n.dC)("dav/comments")}},35550:(e,t,o)=>{"use strict";o.d(t,{A:()=>c});var n=o(45505),r=o(17003),i=o(21777);const a=(0,n.UU)((0,r.e)()),s=e=>{a.setHeaders({"X-Requested-With":"XMLHttpRequest",requesttoken:e??""})};(0,i.zo)(s),s((0,i.do)());const c=a},42634:()=>{},59169:()=>{},63779:()=>{},77199:()=>{},86833:()=>{},96689:(e,t,o)=>{"use strict";o.d(t,{A:()=>n});const n=(0,o(35947).YK)().setApp("comments").detectUser().build()}},i={};function a(e){var t=i[e];if(void 0!==t)return t.exports;var o=i[e]={id:e,loaded:!1,exports:{}};return r[e].call(o.exports,o,o.exports,a),o.loaded=!0,o.exports}a.m=r,e=[],a.O=(t,o,n,r)=>{if(!o){var i=1/0;for(l=0;l=r)&&Object.keys(a.O).every(e=>a.O[e](o[c]))?o.splice(c--,1):(s=!1,r0&&e[l-1][2]>r;l--)e[l]=e[l-1];e[l]=[o,n,r]},a.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return a.d(t,{a:t}),t},a.d=(e,t)=>{for(var o in t)a.o(t,o)&&!a.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},a.f={},a.e=e=>Promise.all(Object.keys(a.f).reduce((t,o)=>(a.f[o](e,t),t),[])),a.u=e=>e+"-"+e+".js?v="+{640:"d4c5c018803ee8751b2a",780:"e3ee44fa7690af29d8d7",3564:"29e8338d43e0d4bd3995",3920:"663552bcb408022c67c0",4508:"40b53e5d2d42025bc3a7",5258:"80a9b9a289e4eb695373",5810:"b550a24d46f75f92c2d5",5862:"8bc76a21d9622c29e1a9",7462:"df273d28c362a92d76d7",7471:"6423b9b898ffefeb7d1d",7838:"37c7bd8d5fada1bd542c",8057:"2989a820b017942edb87"}[e],a.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),a.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),o={},n="nextcloud:",a.l=(e,t,r,i)=>{if(o[e])o[e].push(t);else{var s,c;if(void 0!==r)for(var d=document.getElementsByTagName("script"),l=0;l{s.onerror=s.onload=null,clearTimeout(f);var r=o[e];if(delete o[e],s.parentNode&&s.parentNode.removeChild(s),r&&r.forEach(e=>e(n)),t)return t(n)},f=setTimeout(m.bind(null,void 0,{type:"timeout",target:s}),12e4);s.onerror=m.bind(null,s.onerror),s.onload=m.bind(null,s.onload),c&&document.head.appendChild(s)}},a.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},a.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),a.j=2122,(()=>{var e;a.g.importScripts&&(e=a.g.location+"");var t=a.g.document;if(!e&&t&&(t.currentScript&&"SCRIPT"===t.currentScript.tagName.toUpperCase()&&(e=t.currentScript.src),!e)){var o=t.getElementsByTagName("script");if(o.length)for(var n=o.length-1;n>-1&&(!e||!/^http(s?):/.test(e));)e=o[n--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),a.p=e})(),(()=>{a.b=document.baseURI||self.location.href;var e={2122:0};a.f.j=(t,o)=>{var n=a.o(e,t)?e[t]:void 0;if(0!==n)if(n)o.push(n[2]);else{var r=new Promise((o,r)=>n=e[t]=[o,r]);o.push(n[2]=r);var i=a.p+a.u(t),s=new Error;a.l(i,o=>{if(a.o(e,t)&&(0!==(n=e[t])&&(e[t]=void 0),n)){var r=o&&("load"===o.type?"missing":o.type),i=o&&o.target&&o.target.src;s.message="Loading chunk "+t+" failed.\n("+r+": "+i+")",s.name="ChunkLoadError",s.type=r,s.request=i,n[1](s)}},"chunk-"+t,t)}},a.O.j=t=>0===e[t];var t=(t,o)=>{var n,r,i=o[0],s=o[1],c=o[2],d=0;if(i.some(t=>0!==e[t])){for(n in s)a.o(s,n)&&(a.m[n]=s[n]);if(c)var l=c(a)}for(t&&t(o);da(1836));s=a.O(s)})(); -//# sourceMappingURL=comments-comments-tab.js.map?v=d70a2d12a64141511aac \ No newline at end of file +(()=>{var e,o,n,r={1836:(e,o,n)=>{"use strict";var r=n(21777),i=n(81222),a=n(51651),s=n(85471),c=n(96689),d=n(45505),l=n(54290),u=n(90176),m=n(35550);var f=n(65899);let p,b;function v(){window.OCA.Activity.registerSidebarAction({mount:async(e,t)=>{let{fileInfo:o,reload:r}=t;const i=(0,f.Ey)();if(!p){const{default:e}=await Promise.all([n.e(4208),n.e(7462),n.e(8057)]).then(n.bind(n,98057));p=s.Ay.extend(e)}b=new p({el:e,pinia:i,propsData:{reloadCallback:r,resourceId:o.id}}),c.A.info("Comments plugin mounted in Activity sidebar action",{fileInfo:o})},unmount:()=>{b&&b.$destroy()}}),window.OCA.Activity.registerSidebarEntries(async e=>{let{fileInfo:t,limit:o,offset:r}=e;const{data:i}=await async function(e,t){let{resourceType:o,resourceId:n}=e;const r=["",o,n].join("/"),i=t.datetime?`${t.datetime.toISOString()}`:"",a=await m.A.customRequest(r,Object.assign({method:"REPORT",data:`\n\t\t\t\n\t\t\t\t${t.limit??20}\n\t\t\t\t${t.offset||0}\n\t\t\t\t${i}\n\t\t\t`},t)),s=await a.text(),c=function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const{multistatus:{response:o}}=e;return o.map(e=>{const o=e.propstat.prop;return(0,u.ch)(o,o.id.toString(),t)})}(await(0,d.h4)(s),!0);return(0,l.hq)(a,c,!0)}({resourceType:"files",resourceId:t.id},{limit:o,offset:r});c.A.debug("Loaded comments",{fileInfo:t,comments:i});const{default:f}=await Promise.all([n.e(4208),n.e(7462),n.e(3920)]).then(n.bind(n,93920)),p=s.Ay.extend(f);return i.map(e=>({_CommentsViewInstance:void 0,timestamp:(0,a.A)(e.props?.creationDateTime).toDate().getTime(),mount(o,n){let{reload:r}=n;this._CommentsViewInstance=new p({el:o,propsData:{comment:e,resourceId:t.id,reloadCallback:r}})},unmount(){this._CommentsViewInstance?.$destroy()}}))}),window.OCA.Activity.registerSidebarFilter(e=>"comments"!==e.type),c.A.info("Comments plugin registered for Activity sidebar action")}if(s.Ay.use(f.R2),n.nc=(0,r.aV)(),(0,i.C)("comments","activityEnabled",!1)&&void 0!==OCA?.Activity?.registerSidebarAction)window.addEventListener("DOMContentLoaded",function(){v()});else{let e=null;const o=new OCA.Files.Sidebar.Tab({id:"comments",name:t("comments","Comments"),iconSvg:'',async mount(t,o,n){e&&e.$destroy(),e=new OCA.Comments.View("files",{parent:n,propsData:{resourceId:o.id}}),await e.update(o.id),e.$mount(t)},update(t){e.update(t.id)},destroy(){e.$destroy(),e=null},scrollBottomReached(){e.onScrollBottomReached()}});window.addEventListener("DOMContentLoaded",function(){OCA.Files&&OCA.Files.Sidebar&&OCA.Files.Sidebar.registerTab(o)})}},17003:(e,t,o)=>{"use strict";o.d(t,{e:()=>r});var n=o(63814);const r=function(){return(0,n.dC)("dav/comments")}},35550:(e,t,o)=>{"use strict";o.d(t,{A:()=>c});var n=o(45505),r=o(17003),i=o(21777);const a=(0,n.UU)((0,r.e)()),s=e=>{a.setHeaders({"X-Requested-With":"XMLHttpRequest",requesttoken:e??""})};(0,i.zo)(s),s((0,i.do)());const c=a},42634:()=>{},59169:()=>{},63779:()=>{},77199:()=>{},86833:()=>{},96689:(e,t,o)=>{"use strict";o.d(t,{A:()=>n});const n=(0,o(35947).YK)().setApp("comments").detectUser().build()}},i={};function a(e){var t=i[e];if(void 0!==t)return t.exports;var o=i[e]={id:e,loaded:!1,exports:{}};return r[e].call(o.exports,o,o.exports,a),o.loaded=!0,o.exports}a.m=r,e=[],a.O=(t,o,n,r)=>{if(!o){var i=1/0;for(l=0;l=r)&&Object.keys(a.O).every(e=>a.O[e](o[c]))?o.splice(c--,1):(s=!1,r0&&e[l-1][2]>r;l--)e[l]=e[l-1];e[l]=[o,n,r]},a.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return a.d(t,{a:t}),t},a.d=(e,t)=>{for(var o in t)a.o(t,o)&&!a.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},a.f={},a.e=e=>Promise.all(Object.keys(a.f).reduce((t,o)=>(a.f[o](e,t),t),[])),a.u=e=>e+"-"+e+".js?v="+{640:"d4c5c018803ee8751b2a",780:"e3ee44fa7690af29d8d7",3564:"29e8338d43e0d4bd3995",3920:"663552bcb408022c67c0",4508:"40b53e5d2d42025bc3a7",5258:"80a9b9a289e4eb695373",5810:"b550a24d46f75f92c2d5",5862:"8bc76a21d9622c29e1a9",7462:"3fcd1d8bc575a39150b5",7471:"6423b9b898ffefeb7d1d",7838:"37c7bd8d5fada1bd542c",8057:"2989a820b017942edb87"}[e],a.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),a.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),o={},n="nextcloud:",a.l=(e,t,r,i)=>{if(o[e])o[e].push(t);else{var s,c;if(void 0!==r)for(var d=document.getElementsByTagName("script"),l=0;l{s.onerror=s.onload=null,clearTimeout(f);var r=o[e];if(delete o[e],s.parentNode&&s.parentNode.removeChild(s),r&&r.forEach(e=>e(n)),t)return t(n)},f=setTimeout(m.bind(null,void 0,{type:"timeout",target:s}),12e4);s.onerror=m.bind(null,s.onerror),s.onload=m.bind(null,s.onload),c&&document.head.appendChild(s)}},a.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},a.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),a.j=2122,(()=>{var e;a.g.importScripts&&(e=a.g.location+"");var t=a.g.document;if(!e&&t&&(t.currentScript&&"SCRIPT"===t.currentScript.tagName.toUpperCase()&&(e=t.currentScript.src),!e)){var o=t.getElementsByTagName("script");if(o.length)for(var n=o.length-1;n>-1&&(!e||!/^http(s?):/.test(e));)e=o[n--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),a.p=e})(),(()=>{a.b=document.baseURI||self.location.href;var e={2122:0};a.f.j=(t,o)=>{var n=a.o(e,t)?e[t]:void 0;if(0!==n)if(n)o.push(n[2]);else{var r=new Promise((o,r)=>n=e[t]=[o,r]);o.push(n[2]=r);var i=a.p+a.u(t),s=new Error;a.l(i,o=>{if(a.o(e,t)&&(0!==(n=e[t])&&(e[t]=void 0),n)){var r=o&&("load"===o.type?"missing":o.type),i=o&&o.target&&o.target.src;s.message="Loading chunk "+t+" failed.\n("+r+": "+i+")",s.name="ChunkLoadError",s.type=r,s.request=i,n[1](s)}},"chunk-"+t,t)}},a.O.j=t=>0===e[t];var t=(t,o)=>{var n,r,i=o[0],s=o[1],c=o[2],d=0;if(i.some(t=>0!==e[t])){for(n in s)a.o(s,n)&&(a.m[n]=s[n]);if(c)var l=c(a)}for(t&&t(o);da(1836));s=a.O(s)})(); +//# sourceMappingURL=comments-comments-tab.js.map?v=5657d90eabdcb4f9b37f \ No newline at end of file diff --git a/dist/comments-comments-tab.js.map b/dist/comments-comments-tab.js.map index e6d9e7570ab..cfabd750647 100644 --- a/dist/comments-comments-tab.js.map +++ b/dist/comments-comments-tab.js.map @@ -1 +1 @@ -{"version":3,"file":"comments-comments-tab.js?v=d70a2d12a64141511aac","mappings":"UAAIA,ECAAC,EACAC,E,qJCSJ,IAAIC,EACAC,EAIG,SAASC,IACZC,OAAOC,IAAIC,SAASC,sBAAsB,CACtCC,MAAOC,MAAOC,EAAEC,KAA2B,IAAzB,SAAEC,EAAQ,OAAEC,GAAQF,EAClC,MAAMG,GAAQC,EAAAA,EAAAA,MACd,IAAKd,EAAuB,CACxB,MAAQe,QAASC,SAAgC,mEAEjDhB,EAAwBiB,EAAAA,GAAIC,OAAOF,EACvC,CACAf,EAA4B,IAAID,EAAsB,CAClDS,KACAI,QACAM,UAAW,CACPC,eAAgBR,EAChBS,WAAYV,EAASW,MAG7BC,EAAAA,EAAOC,KAAK,qDAA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AmBzC,QAAQoC,EAAqBlC,KAAK,KAAM,IAC3DuC,EAAmBhE,KAAO2D,EAAqBlC,KAAK,KAAMuC,EAAmBhE,KAAKyB,KAAKuC,G,KCvFvFlH,EAAoB6D,QAAKhI,ECGzB,IAAIsL,EAAsBnH,EAAoBS,OAAE5E,EAAW,CAAC,MAAO,IAAOmE,EAAoB,OAC9FmH,EAAsBnH,EAAoBS,EAAE0G,E","sources":["webpack:///nextcloud/webpack/runtime/chunk loaded","webpack:///nextcloud/webpack/runtime/load script","webpack:///nextcloud/apps/comments/src/comments-activity-tab.ts","webpack:///nextcloud/apps/comments/src/services/GetComments.ts","webpack:///nextcloud/apps/comments/src/comments-tab.js","webpack:///nextcloud/apps/comments/src/utils/davUtils.js","webpack:///nextcloud/apps/comments/src/services/DavClient.js","webpack:///nextcloud/apps/comments/src/logger.js","webpack:///nextcloud/webpack/bootstrap","webpack:///nextcloud/webpack/runtime/compat get default export","webpack:///nextcloud/webpack/runtime/define property getters","webpack:///nextcloud/webpack/runtime/ensure chunk","webpack:///nextcloud/webpack/runtime/get javascript chunk filename","webpack:///nextcloud/webpack/runtime/global","webpack:///nextcloud/webpack/runtime/hasOwnProperty shorthand","webpack:///nextcloud/webpack/runtime/make namespace object","webpack:///nextcloud/webpack/runtime/node module decorator","webpack:///nextcloud/webpack/runtime/runtimeId","webpack:///nextcloud/webpack/runtime/publicPath","webpack:///nextcloud/webpack/runtime/jsonp chunk loading","webpack:///nextcloud/webpack/runtime/nonce","webpack:///nextcloud/webpack/startup"],"sourcesContent":["var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar chunkIds = deferred[i][0];\n\t\tvar fn = deferred[i][1];\n\t\tvar priority = deferred[i][2];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var inProgress = {};\nvar dataWebpackPrefix = \"nextcloud:\";\n// loadScript function to load a script via script tag\n__webpack_require__.l = (url, done, key, chunkId) => {\n\tif(inProgress[url]) { inProgress[url].push(done); return; }\n\tvar script, needAttach;\n\tif(key !== undefined) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tfor(var i = 0; i < scripts.length; i++) {\n\t\t\tvar s = scripts[i];\n\t\t\tif(s.getAttribute(\"src\") == url || s.getAttribute(\"data-webpack\") == dataWebpackPrefix + key) { script = s; break; }\n\t\t}\n\t}\n\tif(!script) {\n\t\tneedAttach = true;\n\t\tscript = document.createElement('script');\n\n\t\tscript.charset = 'utf-8';\n\t\tscript.timeout = 120;\n\t\tif (__webpack_require__.nc) {\n\t\t\tscript.setAttribute(\"nonce\", __webpack_require__.nc);\n\t\t}\n\t\tscript.setAttribute(\"data-webpack\", dataWebpackPrefix + key);\n\n\t\tscript.src = url;\n\t}\n\tinProgress[url] = [done];\n\tvar onScriptComplete = (prev, event) => {\n\t\t// avoid mem leaks in IE.\n\t\tscript.onerror = script.onload = null;\n\t\tclearTimeout(timeout);\n\t\tvar doneFns = inProgress[url];\n\t\tdelete inProgress[url];\n\t\tscript.parentNode && script.parentNode.removeChild(script);\n\t\tdoneFns && doneFns.forEach((fn) => (fn(event)));\n\t\tif(prev) return prev(event);\n\t}\n\tvar timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000);\n\tscript.onerror = onScriptComplete.bind(null, script.onerror);\n\tscript.onload = onScriptComplete.bind(null, script.onload);\n\tneedAttach && document.head.appendChild(script);\n};","/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\nimport moment from '@nextcloud/moment';\nimport Vue, {} from 'vue';\nimport logger from './logger.js';\nimport { getComments } from './services/GetComments.js';\nimport { PiniaVuePlugin, createPinia } from 'pinia';\nVue.use(PiniaVuePlugin);\nlet ActivityTabPluginView;\nlet ActivityTabPluginInstance;\n/**\n * Register the comments plugins for the Activity sidebar\n */\nexport function registerCommentsPlugins() {\n window.OCA.Activity.registerSidebarAction({\n mount: async (el, { fileInfo, reload }) => {\n const pinia = createPinia();\n if (!ActivityTabPluginView) {\n const { default: ActivityCommentAction } = await import('./views/ActivityCommentAction.vue');\n // @ts-expect-error Types are broken for Vue2\n ActivityTabPluginView = Vue.extend(ActivityCommentAction);\n }\n ActivityTabPluginInstance = new ActivityTabPluginView({\n el,\n pinia,\n propsData: {\n reloadCallback: reload,\n resourceId: fileInfo.id,\n },\n });\n logger.info('Comments plugin mounted in Activity sidebar action', { fileInfo });\n },\n unmount: () => {\n // destroy previous instance if available\n if (ActivityTabPluginInstance) {\n ActivityTabPluginInstance.$destroy();\n }\n },\n });\n window.OCA.Activity.registerSidebarEntries(async ({ fileInfo, limit, offset }) => {\n const { data: comments } = await getComments({ resourceType: 'files', resourceId: fileInfo.id }, { limit, offset });\n logger.debug('Loaded comments', { fileInfo, comments });\n const { default: CommentView } = await import('./views/ActivityCommentEntry.vue');\n // @ts-expect-error Types are broken for Vue2\n const CommentsViewObject = Vue.extend(CommentView);\n return comments.map((comment) => ({\n _CommentsViewInstance: undefined,\n timestamp: moment(comment.props?.creationDateTime).toDate().getTime(),\n mount(element, { reload }) {\n this._CommentsViewInstance = new CommentsViewObject({\n el: element,\n propsData: {\n comment,\n resourceId: fileInfo.id,\n reloadCallback: reload,\n },\n });\n },\n unmount() {\n this._CommentsViewInstance?.$destroy();\n },\n }));\n });\n window.OCA.Activity.registerSidebarFilter((activity) => activity.type !== 'comments');\n logger.info('Comments plugin registered for Activity sidebar action');\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\nimport { parseXML } from 'webdav';\n// https://github.com/perry-mitchell/webdav-client/issues/339\nimport { processResponsePayload } from 'webdav/dist/node/response.js';\nimport { prepareFileFromProps } from 'webdav/dist/node/tools/dav.js';\nimport client from './DavClient.js';\nexport const DEFAULT_LIMIT = 20;\n/**\n * Retrieve the comments list\n *\n * @param {object} data destructuring object\n * @param {string} data.resourceType the resource type\n * @param {number} data.resourceId the resource ID\n * @param {object} [options] optional options for axios\n * @param {number} [options.offset] the pagination offset\n * @param {number} [options.limit] the pagination limit, defaults to 20\n * @param {Date} [options.datetime] optional date to query\n * @return {{data: object[]}} the comments list\n */\nexport const getComments = async function ({ resourceType, resourceId }, options) {\n const resourcePath = ['', resourceType, resourceId].join('/');\n const datetime = options.datetime ? `${options.datetime.toISOString()}` : '';\n const response = await client.customRequest(resourcePath, Object.assign({\n method: 'REPORT',\n data: `\n\t\t\t\n\t\t\t\t${options.limit ?? DEFAULT_LIMIT}\n\t\t\t\t${options.offset || 0}\n\t\t\t\t${datetime}\n\t\t\t`,\n }, options));\n const responseData = await response.text();\n const result = await parseXML(responseData);\n const stat = getDirectoryFiles(result, true);\n return processResponsePayload(response, stat, true);\n};\n// https://github.com/perry-mitchell/webdav-client/blob/8d9694613c978ce7404e26a401c39a41f125f87f/source/operations/directoryContents.ts\nconst getDirectoryFiles = function (result, isDetailed = false) {\n // Extract the response items (directory contents)\n const { multistatus: { response: responseItems }, } = result;\n // Map all items to a consistent output structure (results)\n return responseItems.map(item => {\n // Each item should contain a stat object\n const props = item.propstat.prop;\n return prepareFileFromProps(props, props.id.toString(), isDetailed);\n });\n};\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\n// eslint-disable-next-line n/no-missing-import, import/no-unresolved\nimport MessageReplyText from '@mdi/svg/svg/message-reply-text.svg?raw'\nimport { getCSPNonce } from '@nextcloud/auth'\nimport { loadState } from '@nextcloud/initial-state'\nimport { registerCommentsPlugins } from './comments-activity-tab.ts'\n\n// @ts-expect-error __webpack_nonce__ is injected by webpack\n__webpack_nonce__ = getCSPNonce()\n\nif (loadState('comments', 'activityEnabled', false) && OCA?.Activity?.registerSidebarAction !== undefined) {\n\t// Do not mount own tab but mount into activity\n\twindow.addEventListener('DOMContentLoaded', function() {\n\t\tregisterCommentsPlugins()\n\t})\n} else {\n\t// Init Comments tab component\n\tlet TabInstance = null\n\tconst commentTab = new OCA.Files.Sidebar.Tab({\n\t\tid: 'comments',\n\t\tname: t('comments', 'Comments'),\n\t\ticonSvg: MessageReplyText,\n\n\t\tasync mount(el, fileInfo, context) {\n\t\t\tif (TabInstance) {\n\t\t\t\tTabInstance.$destroy()\n\t\t\t}\n\t\t\tTabInstance = new OCA.Comments.View('files', {\n\t\t\t\t// Better integration with vue parent component\n\t\t\t\tparent: context,\n\t\t\t\tpropsData: {\n\t\t\t\t\tresourceId: fileInfo.id,\n\t\t\t\t},\n\t\t\t})\n\t\t\t// Only mount after we have all the info we need\n\t\t\tawait TabInstance.update(fileInfo.id)\n\t\t\tTabInstance.$mount(el)\n\t\t},\n\t\tupdate(fileInfo) {\n\t\t\tTabInstance.update(fileInfo.id)\n\t\t},\n\t\tdestroy() {\n\t\t\tTabInstance.$destroy()\n\t\t\tTabInstance = null\n\t\t},\n\t\tscrollBottomReached() {\n\t\t\tTabInstance.onScrollBottomReached()\n\t\t},\n\t})\n\n\twindow.addEventListener('DOMContentLoaded', function() {\n\t\tif (OCA.Files && OCA.Files.Sidebar) {\n\t\t\tOCA.Files.Sidebar.registerTab(commentTab)\n\t\t}\n\t})\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { generateRemoteUrl } from '@nextcloud/router'\n\nconst getRootPath = function() {\n\treturn generateRemoteUrl('dav/comments')\n}\n\nexport { getRootPath }\n","/**\n * SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { createClient } from 'webdav'\nimport { getRootPath } from '../utils/davUtils.js'\nimport { getRequestToken, onRequestTokenUpdate } from '@nextcloud/auth'\n\n// init webdav client\nconst client = createClient(getRootPath())\n\n// set CSRF token header\nconst setHeaders = (token) => {\n\tclient.setHeaders({\n\t\t// Add this so the server knows it is an request from the browser\n\t\t'X-Requested-With': 'XMLHttpRequest',\n\t\t// Inject user auth\n\t\trequesttoken: token ?? '',\n\t})\n}\n\n// refresh headers when request token changes\nonRequestTokenUpdate(setHeaders)\nsetHeaders(getRequestToken())\n\nexport default client\n","/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { getLoggerBuilder } from '@nextcloud/logger'\n\nexport default getLoggerBuilder()\n\t.setApp('comments')\n\t.detectUser()\n\t.build()\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \"-\" + chunkId + \".js?v=\" + {\"640\":\"d4c5c018803ee8751b2a\",\"780\":\"e3ee44fa7690af29d8d7\",\"3564\":\"29e8338d43e0d4bd3995\",\"3920\":\"663552bcb408022c67c0\",\"4508\":\"40b53e5d2d42025bc3a7\",\"5258\":\"80a9b9a289e4eb695373\",\"5810\":\"b550a24d46f75f92c2d5\",\"5862\":\"8bc76a21d9622c29e1a9\",\"7462\":\"df273d28c362a92d76d7\",\"7471\":\"6423b9b898ffefeb7d1d\",\"7838\":\"37c7bd8d5fada1bd542c\",\"8057\":\"2989a820b017942edb87\"}[chunkId] + \"\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = (module) => {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","__webpack_require__.j = 2122;","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/^blob:/, \"\").replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = document.baseURI || self.location.href;\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t2122: 0\n};\n\n__webpack_require__.f.j = (chunkId, promises) => {\n\t\t// JSONP chunk loading for javascript\n\t\tvar installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined;\n\t\tif(installedChunkData !== 0) { // 0 means \"already installed\".\n\n\t\t\t// a Promise means \"currently loading\".\n\t\t\tif(installedChunkData) {\n\t\t\t\tpromises.push(installedChunkData[2]);\n\t\t\t} else {\n\t\t\t\tif(true) { // all chunks have JS\n\t\t\t\t\t// setup Promise in chunk cache\n\t\t\t\t\tvar promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject]));\n\t\t\t\t\tpromises.push(installedChunkData[2] = promise);\n\n\t\t\t\t\t// start chunk loading\n\t\t\t\t\tvar url = __webpack_require__.p + __webpack_require__.u(chunkId);\n\t\t\t\t\t// create error before stack unwound to get useful stacktrace later\n\t\t\t\t\tvar error = new Error();\n\t\t\t\t\tvar loadingEnded = (event) => {\n\t\t\t\t\t\tif(__webpack_require__.o(installedChunks, chunkId)) {\n\t\t\t\t\t\t\tinstalledChunkData = installedChunks[chunkId];\n\t\t\t\t\t\t\tif(installedChunkData !== 0) installedChunks[chunkId] = undefined;\n\t\t\t\t\t\t\tif(installedChunkData) {\n\t\t\t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n\t\t\t\t\t\t\t\tvar realSrc = event && event.target && event.target.src;\n\t\t\t\t\t\t\t\terror.message = 'Loading chunk ' + chunkId + ' failed.\\n(' + errorType + ': ' + realSrc + ')';\n\t\t\t\t\t\t\t\terror.name = 'ChunkLoadError';\n\t\t\t\t\t\t\t\terror.type = errorType;\n\t\t\t\t\t\t\t\terror.request = realSrc;\n\t\t\t\t\t\t\t\tinstalledChunkData[1](error);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\t\t\t\t\t__webpack_require__.l(url, loadingEnded, \"chunk-\" + chunkId, chunkId);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n};\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar chunkIds = data[0];\n\tvar moreModules = data[1];\n\tvar runtime = data[2];\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = self[\"webpackChunknextcloud\"] = self[\"webpackChunknextcloud\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","__webpack_require__.nc = undefined;","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [4208], () => (__webpack_require__(1836)))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n"],"names":["deferred","inProgress","dataWebpackPrefix","ActivityTabPluginView","ActivityTabPluginInstance","registerCommentsPlugins","window","OCA","Activity","registerSidebarAction","mount","async","el","_ref","fileInfo","reload","pinia","createPinia","default","ActivityCommentAction","Vue","extend","propsData","reloadCallback","resourceId","id","logger","info","unmount","$destroy","registerSidebarEntries","limit","offset","_ref2","data","comments","options","resourceType","resourcePath","join","datetime","toISOString","response","client","customRequest","Object","assign","method","responseData","text","stat","result","isDetailed","arguments","length","undefined","multistatus","responseItems","map","item","props","propstat","prop","prepareFileFromProps","toString","getDirectoryFiles","parseXML","processResponsePayload","getComments","debug","CommentView","CommentsViewObject","comment","_CommentsViewInstance","timestamp","moment","creationDateTime","toDate","getTime","element","_ref3","this","registerSidebarFilter","activity","type","use","PiniaVuePlugin","__webpack_nonce__","getCSPNonce","loadState","addEventListener","TabInstance","commentTab","Files","Sidebar","Tab","name","t","iconSvg","context","Comments","View","parent","update","$mount","destroy","scrollBottomReached","onScrollBottomReached","registerTab","getRootPath","generateRemoteUrl","createClient","setHeaders","token","requesttoken","onRequestTokenUpdate","getRequestToken","getLoggerBuilder","setApp","detectUser","build","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","exports","module","loaded","__webpack_modules__","call","m","O","chunkIds","fn","priority","notFulfilled","Infinity","i","fulfilled","j","keys","every","key","splice","r","n","getter","__esModule","d","a","definition","o","defineProperty","enumerable","get","f","e","chunkId","Promise","all","reduce","promises","u","g","globalThis","Function","obj","prototype","hasOwnProperty","l","url","done","push","script","needAttach","scripts","document","getElementsByTagName","s","getAttribute","createElement","charset","timeout","nc","setAttribute","src","onScriptComplete","prev","event","onerror","onload","clearTimeout","doneFns","parentNode","removeChild","forEach","setTimeout","bind","target","head","appendChild","Symbol","toStringTag","value","nmd","paths","children","scriptUrl","importScripts","location","currentScript","tagName","toUpperCase","test","Error","replace","p","b","baseURI","self","href","installedChunks","installedChunkData","promise","resolve","reject","error","errorType","realSrc","message","request","webpackJsonpCallback","parentChunkLoadingFunction","moreModules","runtime","some","chunkLoadingGlobal","__webpack_exports__"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"comments-comments-tab.js?v=5657d90eabdcb4f9b37f","mappings":"UAAIA,ECAAC,EACAC,E,qJCSJ,IAAIC,EACAC,EAIG,SAASC,IACZC,OAAOC,IAAIC,SAASC,sBAAsB,CACtCC,MAAOC,MAAOC,EAAEC,KAA2B,IAAzB,SAAEC,EAAQ,OAAEC,GAAQF,EAClC,MAAMG,GAAQC,EAAAA,EAAAA,MACd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EAAUzB,EAASK,GAChBf,EAAoB6B,EAAEsE,EAAiBhE,IAAYgE,EAAgBhE,IACrEgE,EAAgBhE,GAAS,KAE1BgE,EAAgBhE,GAAW,EAE5B,OAAOnC,EAAoBS,EAAEhF,IAG1ByL,EAAqBjB,KAA4B,sBAAIA,KAA4B,uBAAK,GAC1FiB,EAAmBzC,QAAQoC,EAAqBlC,KAAK,KAAM,IAC3DuC,EAAmBhE,KAAO2D,EAAqBlC,KAAK,KAAMuC,EAAmBhE,KAAKyB,KAAKuC,G,KCvFvFlH,EAAoB6D,QAAKhI,ECGzB,IAAIsL,EAAsBnH,EAAoBS,OAAE5E,EAAW,CAAC,MAAO,IAAOmE,EAAoB,OAC9FmH,EAAsBnH,EAAoBS,EAAE0G,E","sources":["webpack:///nextcloud/webpack/runtime/chunk loaded","webpack:///nextcloud/webpack/runtime/load script","webpack:///nextcloud/apps/comments/src/comments-activity-tab.ts","webpack:///nextcloud/apps/comments/src/services/GetComments.ts","webpack:///nextcloud/apps/comments/src/comments-tab.js","webpack:///nextcloud/apps/comments/src/utils/davUtils.js","webpack:///nextcloud/apps/comments/src/services/DavClient.js","webpack:///nextcloud/apps/comments/src/logger.js","webpack:///nextcloud/webpack/bootstrap","webpack:///nextcloud/webpack/runtime/compat get default export","webpack:///nextcloud/webpack/runtime/define property getters","webpack:///nextcloud/webpack/runtime/ensure chunk","webpack:///nextcloud/webpack/runtime/get javascript chunk filename","webpack:///nextcloud/webpack/runtime/global","webpack:///nextcloud/webpack/runtime/hasOwnProperty shorthand","webpack:///nextcloud/webpack/runtime/make namespace object","webpack:///nextcloud/webpack/runtime/node module decorator","webpack:///nextcloud/webpack/runtime/runtimeId","webpack:///nextcloud/webpack/runtime/publicPath","webpack:///nextcloud/webpack/runtime/jsonp chunk loading","webpack:///nextcloud/webpack/runtime/nonce","webpack:///nextcloud/webpack/startup"],"sourcesContent":["var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar chunkIds = deferred[i][0];\n\t\tvar fn = deferred[i][1];\n\t\tvar priority = deferred[i][2];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var inProgress = {};\nvar dataWebpackPrefix = \"nextcloud:\";\n// loadScript function to load a script via script tag\n__webpack_require__.l = (url, done, key, chunkId) => {\n\tif(inProgress[url]) { inProgress[url].push(done); return; }\n\tvar script, needAttach;\n\tif(key !== undefined) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tfor(var i = 0; i < scripts.length; i++) {\n\t\t\tvar s = scripts[i];\n\t\t\tif(s.getAttribute(\"src\") == url || s.getAttribute(\"data-webpack\") == dataWebpackPrefix + key) { script = s; break; }\n\t\t}\n\t}\n\tif(!script) {\n\t\tneedAttach = true;\n\t\tscript = document.createElement('script');\n\n\t\tscript.charset = 'utf-8';\n\t\tscript.timeout = 120;\n\t\tif (__webpack_require__.nc) {\n\t\t\tscript.setAttribute(\"nonce\", __webpack_require__.nc);\n\t\t}\n\t\tscript.setAttribute(\"data-webpack\", dataWebpackPrefix + key);\n\n\t\tscript.src = url;\n\t}\n\tinProgress[url] = [done];\n\tvar onScriptComplete = (prev, event) => {\n\t\t// avoid mem leaks in IE.\n\t\tscript.onerror = script.onload = null;\n\t\tclearTimeout(timeout);\n\t\tvar doneFns = inProgress[url];\n\t\tdelete inProgress[url];\n\t\tscript.parentNode && script.parentNode.removeChild(script);\n\t\tdoneFns && doneFns.forEach((fn) => (fn(event)));\n\t\tif(prev) return prev(event);\n\t}\n\tvar timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000);\n\tscript.onerror = onScriptComplete.bind(null, script.onerror);\n\tscript.onload = onScriptComplete.bind(null, script.onload);\n\tneedAttach && document.head.appendChild(script);\n};","/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\nimport moment from '@nextcloud/moment';\nimport Vue, {} from 'vue';\nimport logger from './logger.js';\nimport { getComments } from './services/GetComments.js';\nimport { PiniaVuePlugin, createPinia } from 'pinia';\nVue.use(PiniaVuePlugin);\nlet ActivityTabPluginView;\nlet ActivityTabPluginInstance;\n/**\n * Register the comments plugins for the Activity sidebar\n */\nexport function registerCommentsPlugins() {\n window.OCA.Activity.registerSidebarAction({\n mount: async (el, { fileInfo, reload }) => {\n const pinia = createPinia();\n if (!ActivityTabPluginView) {\n const { default: ActivityCommentAction } = await import('./views/ActivityCommentAction.vue');\n // @ts-expect-error Types are broken for Vue2\n ActivityTabPluginView = Vue.extend(ActivityCommentAction);\n }\n ActivityTabPluginInstance = new ActivityTabPluginView({\n el,\n pinia,\n propsData: {\n reloadCallback: reload,\n resourceId: fileInfo.id,\n },\n });\n logger.info('Comments plugin mounted in Activity sidebar action', { fileInfo });\n },\n unmount: () => {\n // destroy previous instance if available\n if (ActivityTabPluginInstance) {\n ActivityTabPluginInstance.$destroy();\n }\n },\n });\n window.OCA.Activity.registerSidebarEntries(async ({ fileInfo, limit, offset }) => {\n const { data: comments } = await getComments({ resourceType: 'files', resourceId: fileInfo.id }, { limit, offset });\n logger.debug('Loaded comments', { fileInfo, comments });\n const { default: CommentView } = await import('./views/ActivityCommentEntry.vue');\n // @ts-expect-error Types are broken for Vue2\n const CommentsViewObject = Vue.extend(CommentView);\n return comments.map((comment) => ({\n _CommentsViewInstance: undefined,\n timestamp: moment(comment.props?.creationDateTime).toDate().getTime(),\n mount(element, { reload }) {\n this._CommentsViewInstance = new CommentsViewObject({\n el: element,\n propsData: {\n comment,\n resourceId: fileInfo.id,\n reloadCallback: reload,\n },\n });\n },\n unmount() {\n this._CommentsViewInstance?.$destroy();\n },\n }));\n });\n window.OCA.Activity.registerSidebarFilter((activity) => activity.type !== 'comments');\n logger.info('Comments plugin registered for Activity sidebar action');\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\nimport { parseXML } from 'webdav';\n// https://github.com/perry-mitchell/webdav-client/issues/339\nimport { processResponsePayload } from 'webdav/dist/node/response.js';\nimport { prepareFileFromProps } from 'webdav/dist/node/tools/dav.js';\nimport client from './DavClient.js';\nexport const DEFAULT_LIMIT = 20;\n/**\n * Retrieve the comments list\n *\n * @param {object} data destructuring object\n * @param {string} data.resourceType the resource type\n * @param {number} data.resourceId the resource ID\n * @param {object} [options] optional options for axios\n * @param {number} [options.offset] the pagination offset\n * @param {number} [options.limit] the pagination limit, defaults to 20\n * @param {Date} [options.datetime] optional date to query\n * @return {{data: object[]}} the comments list\n */\nexport const getComments = async function ({ resourceType, resourceId }, options) {\n const resourcePath = ['', resourceType, resourceId].join('/');\n const datetime = options.datetime ? `${options.datetime.toISOString()}` : '';\n const response = await client.customRequest(resourcePath, Object.assign({\n method: 'REPORT',\n data: `\n\t\t\t\n\t\t\t\t${options.limit ?? DEFAULT_LIMIT}\n\t\t\t\t${options.offset || 0}\n\t\t\t\t${datetime}\n\t\t\t`,\n }, options));\n const responseData = await response.text();\n const result = await parseXML(responseData);\n const stat = getDirectoryFiles(result, true);\n return processResponsePayload(response, stat, true);\n};\n// https://github.com/perry-mitchell/webdav-client/blob/8d9694613c978ce7404e26a401c39a41f125f87f/source/operations/directoryContents.ts\nconst getDirectoryFiles = function (result, isDetailed = false) {\n // Extract the response items (directory contents)\n const { multistatus: { response: responseItems }, } = result;\n // Map all items to a consistent output structure (results)\n return responseItems.map(item => {\n // Each item should contain a stat object\n const props = item.propstat.prop;\n return prepareFileFromProps(props, props.id.toString(), isDetailed);\n });\n};\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\n// eslint-disable-next-line n/no-missing-import, import/no-unresolved\nimport MessageReplyText from '@mdi/svg/svg/message-reply-text.svg?raw'\nimport { getCSPNonce } from '@nextcloud/auth'\nimport { loadState } from '@nextcloud/initial-state'\nimport { registerCommentsPlugins } from './comments-activity-tab.ts'\n\n// @ts-expect-error __webpack_nonce__ is injected by webpack\n__webpack_nonce__ = getCSPNonce()\n\nif (loadState('comments', 'activityEnabled', false) && OCA?.Activity?.registerSidebarAction !== undefined) {\n\t// Do not mount own tab but mount into activity\n\twindow.addEventListener('DOMContentLoaded', function() {\n\t\tregisterCommentsPlugins()\n\t})\n} else {\n\t// Init Comments tab component\n\tlet TabInstance = null\n\tconst commentTab = new OCA.Files.Sidebar.Tab({\n\t\tid: 'comments',\n\t\tname: t('comments', 'Comments'),\n\t\ticonSvg: MessageReplyText,\n\n\t\tasync mount(el, fileInfo, context) {\n\t\t\tif (TabInstance) {\n\t\t\t\tTabInstance.$destroy()\n\t\t\t}\n\t\t\tTabInstance = new OCA.Comments.View('files', {\n\t\t\t\t// Better integration with vue parent component\n\t\t\t\tparent: context,\n\t\t\t\tpropsData: {\n\t\t\t\t\tresourceId: fileInfo.id,\n\t\t\t\t},\n\t\t\t})\n\t\t\t// Only mount after we have all the info we need\n\t\t\tawait TabInstance.update(fileInfo.id)\n\t\t\tTabInstance.$mount(el)\n\t\t},\n\t\tupdate(fileInfo) {\n\t\t\tTabInstance.update(fileInfo.id)\n\t\t},\n\t\tdestroy() {\n\t\t\tTabInstance.$destroy()\n\t\t\tTabInstance = null\n\t\t},\n\t\tscrollBottomReached() {\n\t\t\tTabInstance.onScrollBottomReached()\n\t\t},\n\t})\n\n\twindow.addEventListener('DOMContentLoaded', function() {\n\t\tif (OCA.Files && OCA.Files.Sidebar) {\n\t\t\tOCA.Files.Sidebar.registerTab(commentTab)\n\t\t}\n\t})\n}\n","/**\n * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { generateRemoteUrl } from '@nextcloud/router'\n\nconst getRootPath = function() {\n\treturn generateRemoteUrl('dav/comments')\n}\n\nexport { getRootPath }\n","/**\n * SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { createClient } from 'webdav'\nimport { getRootPath } from '../utils/davUtils.js'\nimport { getRequestToken, onRequestTokenUpdate } from '@nextcloud/auth'\n\n// init webdav client\nconst client = createClient(getRootPath())\n\n// set CSRF token header\nconst setHeaders = (token) => {\n\tclient.setHeaders({\n\t\t// Add this so the server knows it is an request from the browser\n\t\t'X-Requested-With': 'XMLHttpRequest',\n\t\t// Inject user auth\n\t\trequesttoken: token ?? '',\n\t})\n}\n\n// refresh headers when request token changes\nonRequestTokenUpdate(setHeaders)\nsetHeaders(getRequestToken())\n\nexport default client\n","/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { getLoggerBuilder } from '@nextcloud/logger'\n\nexport default getLoggerBuilder()\n\t.setApp('comments')\n\t.detectUser()\n\t.build()\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \"-\" + chunkId + \".js?v=\" + {\"640\":\"d4c5c018803ee8751b2a\",\"780\":\"e3ee44fa7690af29d8d7\",\"3564\":\"29e8338d43e0d4bd3995\",\"3920\":\"663552bcb408022c67c0\",\"4508\":\"40b53e5d2d42025bc3a7\",\"5258\":\"80a9b9a289e4eb695373\",\"5810\":\"b550a24d46f75f92c2d5\",\"5862\":\"8bc76a21d9622c29e1a9\",\"7462\":\"3fcd1d8bc575a39150b5\",\"7471\":\"6423b9b898ffefeb7d1d\",\"7838\":\"37c7bd8d5fada1bd542c\",\"8057\":\"2989a820b017942edb87\"}[chunkId] + \"\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = (module) => {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","__webpack_require__.j = 2122;","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/^blob:/, \"\").replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = document.baseURI || self.location.href;\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t2122: 0\n};\n\n__webpack_require__.f.j = (chunkId, promises) => {\n\t\t// JSONP chunk loading for javascript\n\t\tvar installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined;\n\t\tif(installedChunkData !== 0) { // 0 means \"already installed\".\n\n\t\t\t// a Promise means \"currently loading\".\n\t\t\tif(installedChunkData) {\n\t\t\t\tpromises.push(installedChunkData[2]);\n\t\t\t} else {\n\t\t\t\tif(true) { // all chunks have JS\n\t\t\t\t\t// setup Promise in chunk cache\n\t\t\t\t\tvar promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject]));\n\t\t\t\t\tpromises.push(installedChunkData[2] = promise);\n\n\t\t\t\t\t// start chunk loading\n\t\t\t\t\tvar url = __webpack_require__.p + __webpack_require__.u(chunkId);\n\t\t\t\t\t// create error before stack unwound to get useful stacktrace later\n\t\t\t\t\tvar error = new Error();\n\t\t\t\t\tvar loadingEnded = (event) => {\n\t\t\t\t\t\tif(__webpack_require__.o(installedChunks, chunkId)) {\n\t\t\t\t\t\t\tinstalledChunkData = installedChunks[chunkId];\n\t\t\t\t\t\t\tif(installedChunkData !== 0) installedChunks[chunkId] = undefined;\n\t\t\t\t\t\t\tif(installedChunkData) {\n\t\t\t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n\t\t\t\t\t\t\t\tvar realSrc = event && event.target && event.target.src;\n\t\t\t\t\t\t\t\terror.message = 'Loading chunk ' + chunkId + ' failed.\\n(' + errorType + ': ' + realSrc + ')';\n\t\t\t\t\t\t\t\terror.name = 'ChunkLoadError';\n\t\t\t\t\t\t\t\terror.type = errorType;\n\t\t\t\t\t\t\t\terror.request = realSrc;\n\t\t\t\t\t\t\t\tinstalledChunkData[1](error);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\t\t\t\t\t__webpack_require__.l(url, loadingEnded, \"chunk-\" + chunkId, chunkId);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n};\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar chunkIds = data[0];\n\tvar moreModules = data[1];\n\tvar runtime = data[2];\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = self[\"webpackChunknextcloud\"] = self[\"webpackChunknextcloud\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","__webpack_require__.nc = undefined;","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [4208], () => (__webpack_require__(1836)))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n"],"names":["deferred","inProgress","dataWebpackPrefix","ActivityTabPluginView","ActivityTabPluginInstance","registerCommentsPlugins","window","OCA","Activity","registerSidebarAction","mount","async","el","_ref","fileInfo","reload","pinia","createPinia","default","ActivityCommentAction","Vue","extend","propsData","reloadCallback","resourceId","id","logger","info","unmount","$destroy","registerSidebarEntries","limit","offset","_ref2","data","comments","options","resourceType","resourcePath","join","datetime","toISOString","response","client","customRequest","Object","assign","method","responseData","text","stat","result","isDetailed","arguments","length","undefined","multistatus","responseItems","map","item","props","propstat","prop","prepareFileFromProps","toString","getDirectoryFiles","parseXML","processResponsePayload","getComments","debug","CommentView","CommentsViewObject","comment","_CommentsViewInstance","timestamp","moment","creationDateTime","toDate","getTime","element","_ref3","this","registerSidebarFilter","activity","type","use","PiniaVuePlugin","__webpack_nonce__","getCSPNonce","loadState","addEventListener","TabInstance","commentTab","Files","Sidebar","Tab","name","t","iconSvg","context","Comments","View","parent","update","$mount","destroy","scrollBottomReached","onScrollBottomReached","registerTab","getRootPath","generateRemoteUrl","createClient","setHeaders","token","requesttoken","onRequestTokenUpdate","getRequestToken","getLoggerBuilder","setApp","detectUser","build","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","exports","module","loaded","__webpack_modules__","call","m","O","chunkIds","fn","priority","notFulfilled","Infinity","i","fulfilled","j","keys","every","key","splice","r","n","getter","__esModule","d","a","definition","o","defineProperty","enumerable","get","f","e","chunkId","Promise","all","reduce","promises","u","g","globalThis","Function","obj","prototype","hasOwnProperty","l","url","done","push","script","needAttach","scripts","document","getElementsByTagName","s","getAttribute","createElement","charset","timeout","nc","setAttribute","src","onScriptComplete","prev","event","onerror","onload","clearTimeout","doneFns","parentNode","removeChild","forEach","setTimeout","bind","target","head","appendChild","Symbol","toStringTag","value","nmd","paths","children","scriptUrl","importScripts","location","currentScript","tagName","toUpperCase","test","Error","replace","p","b","baseURI","self","href","installedChunks","installedChunkData","promise","resolve","reject","error","errorType","realSrc","message","request","webpackJsonpCallback","parentChunkLoadingFunction","moreModules","runtime","some","chunkLoadingGlobal","__webpack_exports__"],"sourceRoot":""} \ No newline at end of file