Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/dist
diff options
context:
space:
mode:
authorChristopher Ng <chrng8@gmail.com>2022-07-19 21:04:00 +0300
committerChristopher Ng <chrng8@gmail.com>2022-07-19 21:04:00 +0300
commit2f6ab453027cf0e67efa72b97c4e6f869683ee37 (patch)
tree8c75af39ba1b4df796f170890742c3a9b53e6e82 /dist
parent047acc32ad07de4bb481c267b9f730ce644efbd1 (diff)
Buttonify comment postingenh/a11y-post-comment
Signed-off-by: Christopher Ng <chrng8@gmail.com>
Diffstat (limited to 'dist')
-rw-r--r--dist/comments-comments-app.js4
-rw-r--r--dist/comments-comments-app.js.map2
2 files changed, 3 insertions, 3 deletions
diff --git a/dist/comments-comments-app.js b/dist/comments-comments-app.js
index 650859e54b1..44566193960 100644
--- a/dist/comments-comments-app.js
+++ b/dist/comments-comments-app.js
@@ -1,3 +1,3 @@
/*! For license information please see comments-comments-app.js.LICENSE.txt */
-!function(){var n,e={93365:function(n,t,e){var r={"./af":36026,"./af.js":36026,"./ar":28093,"./ar-dz":41943,"./ar-dz.js":41943,"./ar-kw":23969,"./ar-kw.js":23969,"./ar-ly":40594,"./ar-ly.js":40594,"./ar-ma":18369,"./ar-ma.js":18369,"./ar-sa":32579,"./ar-sa.js":32579,"./ar-tn":76442,"./ar-tn.js":76442,"./ar.js":28093,"./az":86425,"./az.js":86425,"./be":22004,"./be.js":22004,"./bg":42982,"./bg.js":42982,"./bm":21067,"./bm.js":21067,"./bn":8366,"./bn-bd":63837,"./bn-bd.js":63837,"./bn.js":8366,"./bo":95040,"./bo.js":95040,"./br":521,"./br.js":521,"./bs":83242,"./bs.js":83242,"./ca":73046,"./ca.js":73046,"./cs":25794,"./cs.js":25794,"./cv":28231,"./cv.js":28231,"./cy":10927,"./cy.js":10927,"./da":42832,"./da.js":42832,"./de":29415,"./de-at":3331,"./de-at.js":3331,"./de-ch":45524,"./de-ch.js":45524,"./de.js":29415,"./dv":44700,"./dv.js":44700,"./el":88752,"./el.js":88752,"./en-au":90444,"./en-au.js":90444,"./en-ca":65959,"./en-ca.js":65959,"./en-gb":62762,"./en-gb.js":62762,"./en-ie":40909,"./en-ie.js":40909,"./en-il":79909,"./en-il.js":79909,"./en-in":87942,"./en-in.js":87942,"./en-nz":75200,"./en-nz.js":75200,"./en-sg":21415,"./en-sg.js":21415,"./eo":27447,"./eo.js":27447,"./es":86756,"./es-do":47049,"./es-do.js":47049,"./es-mx":15915,"./es-mx.js":15915,"./es-us":57133,"./es-us.js":57133,"./es.js":86756,"./et":72182,"./et.js":72182,"./eu":14419,"./eu.js":14419,"./fa":2916,"./fa.js":2916,"./fi":49964,"./fi.js":49964,"./fil":16448,"./fil.js":16448,"./fo":26094,"./fo.js":26094,"./fr":35833,"./fr-ca":56994,"./fr-ca.js":56994,"./fr-ch":2740,"./fr-ch.js":2740,"./fr.js":35833,"./fy":69542,"./fy.js":69542,"./ga":93264,"./ga.js":93264,"./gd":77457,"./gd.js":77457,"./gl":83043,"./gl.js":83043,"./gom-deva":24034,"./gom-deva.js":24034,"./gom-latn":28379,"./gom-latn.js":28379,"./gu":406,"./gu.js":406,"./he":73219,"./he.js":73219,"./hi":99834,"./hi.js":99834,"./hr":28754,"./hr.js":28754,"./hu":93945,"./hu.js":93945,"./hy-am":81319,"./hy-am.js":81319,"./id":24875,"./id.js":24875,"./is":23724,"./is.js":23724,"./it":79906,"./it-ch":34303,"./it-ch.js":34303,"./it.js":79906,"./ja":77105,"./ja.js":77105,"./jv":15026,"./jv.js":15026,"./ka":67416,"./ka.js":67416,"./kk":79734,"./kk.js":79734,"./km":60757,"./km.js":60757,"./kn":58369,"./kn.js":58369,"./ko":77687,"./ko.js":77687,"./ku":95544,"./ku.js":95544,"./ky":85431,"./ky.js":85431,"./lb":13613,"./lb.js":13613,"./lo":34252,"./lo.js":34252,"./lt":84619,"./lt.js":84619,"./lv":93760,"./lv.js":93760,"./me":93393,"./me.js":93393,"./mi":12369,"./mi.js":12369,"./mk":48664,"./mk.js":48664,"./ml":23099,"./ml.js":23099,"./mn":98539,"./mn.js":98539,"./mr":778,"./mr.js":778,"./ms":39970,"./ms-my":82625,"./ms-my.js":82625,"./ms.js":39970,"./mt":15714,"./mt.js":15714,"./my":53055,"./my.js":53055,"./nb":73945,"./nb.js":73945,"./ne":63645,"./ne.js":63645,"./nl":4829,"./nl-be":12823,"./nl-be.js":12823,"./nl.js":4829,"./nn":23756,"./nn.js":23756,"./oc-lnc":41228,"./oc-lnc.js":41228,"./pa-in":97877,"./pa-in.js":97877,"./pl":53066,"./pl.js":53066,"./pt":28677,"./pt-br":81592,"./pt-br.js":81592,"./pt.js":28677,"./ro":32722,"./ro.js":32722,"./ru":59138,"./ru.js":59138,"./sd":32568,"./sd.js":32568,"./se":49753,"./se.js":49753,"./si":58024,"./si.js":58024,"./sk":31058,"./sk.js":31058,"./sl":43452,"./sl.js":43452,"./sq":2795,"./sq.js":2795,"./sr":26976,"./sr-cyrl":38819,"./sr-cyrl.js":38819,"./sr.js":26976,"./ss":7467,"./ss.js":7467,"./sv":42787,"./sv.js":42787,"./sw":80298,"./sw.js":80298,"./ta":57532,"./ta.js":57532,"./te":76076,"./te.js":76076,"./tet":40452,"./tet.js":40452,"./tg":64794,"./tg.js":64794,"./th":48245,"./th.js":48245,"./tk":8870,"./tk.js":8870,"./tl-ph":36056,"./tl-ph.js":36056,"./tlh":15249,"./tlh.js":15249,"./tr":22053,"./tr.js":22053,"./tzl":39871,"./tzl.js":39871,"./tzm":39574,"./tzm-latn":19210,"./tzm-latn.js":19210,"./tzm.js":39574,"./ug-cn":91532,"./ug-cn.js":91532,"./uk":11432,"./uk.js":11432,"./ur":88523,"./ur.js":88523,"./uz":54958,"./uz-latn":68735,"./uz-latn.js":68735,"./uz.js":54958,"./vi":83398,"./vi.js":83398,"./x-pseudo":56665,"./x-pseudo.js":56665,"./yo":11642,"./yo.js":11642,"./zh-cn":5462,"./zh-cn.js":5462,"./zh-hk":92530,"./zh-hk.js":92530,"./zh-mo":41650,"./zh-mo.js":41650,"./zh-tw":97333,"./zh-tw.js":97333};function o(n){var t=s(n);return e(t)}function s(n){if(!e.o(r,n)){var t=new Error("Cannot find module '"+n+"'");throw t.code="MODULE_NOT_FOUND",t}return r[n]}o.keys=function(){return Object.keys(r)},o.resolve=s,n.exports=o,o.id=93365},7346:function(n,e,r){"use strict";var o=r(17499),s=r(9944),a=r(79753),i=r(22200),c=r(16453),u=r(4820),m=r(34741),l=r(20144),d=r(97e3),p=r.n(d),f=r(80351),h=r.n(f),g=r(56286),v=r.n(g),A=r(79440),C=r.n(A),b=r(33521),j=r.n(b),y=r(28017),_=r.n(y),w=r(11243),x=r.n(w),k=r(13408),O=r.n(k),P={name:"Moment",props:{timestamp:{type:Number,required:!0},format:{type:String,default:"LLL"}},computed:{title:function(){return h().unix(this.timestamp).format(this.format)},formatted:function(){return h().unix(this.timestamp).fromNow()}}},E=r(51900),R=(0,E.Z)(P,(function(){var n=this,t=n.$createElement;return(n._self._c||t)("span",{staticClass:"live-relative-timestamp",attrs:{"data-timestamp":1e3*n.timestamp,title:n.title}},[n._v(n._s(n.formatted))])}),[],!1,null,null,null).exports,D=function(){return(0,a.generateRemoteUrl)("dav/comments")},T=r(81063);u.default.defaults.headers["X-Requested-With"]="XMLHttpRequest",(0,T.getPatcher)().patch("request",u.default);var I=(0,T.createClient)(D());function S(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}function M(n){return function(){var t=this,e=arguments;return new Promise((function(r,o){var s=n.apply(t,e);function a(n){S(s,r,o,a,i,"next",n)}function i(n){S(s,r,o,a,i,"throw",n)}a(void 0)}))}}function z(n,t,e){return N.apply(this,arguments)}function N(){return(N=M(regeneratorRuntime.mark((function n(t,e,r){var o,s,a,c,m;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return o=["",t,e].join("/"),n.next=3,u.default.post(D()+o,{actorDisplayName:(0,i.getCurrentUser)().displayName,actorId:(0,i.getCurrentUser)().uid,actorType:"users",creationDateTime:(new Date).toUTCString(),message:r,objectType:"files",verb:"comment"});case 3:return s=n.sent,a=parseInt(s.headers["content-location"].split("/").pop()),c=o+"/"+a,n.next=8,I.stat(c,{details:!0});case 8:return m=n.sent,n.abrupt("return",m.data);case 10:case"end":return n.stop()}}),n)})))).apply(this,arguments)}function B(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}function U(n){return function(){var t=this,e=arguments;return new Promise((function(r,o){var s=n.apply(t,e);function a(n){B(s,r,o,a,i,"next",n)}function i(n){B(s,r,o,a,i,"throw",n)}a(void 0)}))}}function q(n,t,e){return $.apply(this,arguments)}function $(){return($=U(regeneratorRuntime.mark((function n(t,e,r){var o;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return o=["",t,e,r].join("/"),n.next=3,I.deleteFile(o);case 3:case"end":return n.stop()}}),n)})))).apply(this,arguments)}function L(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}function F(n){return function(){var t=this,e=arguments;return new Promise((function(r,o){var s=n.apply(t,e);function a(n){L(s,r,o,a,i,"next",n)}function i(n){L(s,r,o,a,i,"throw",n)}a(void 0)}))}}function Z(n,t,e,r){return G.apply(this,arguments)}function G(){return(G=F(regeneratorRuntime.mark((function n(t,e,r,o){var s;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return s=["",t,e,r].join("/"),n.next=3,I.customRequest(s,Object.assign({method:"PROPPATCH",data:'<?xml version="1.0"?>\n\t\t\t<d:propertyupdate\n\t\t\t\txmlns:d="DAV:"\n\t\t\t\txmlns:oc="http://owncloud.org/ns">\n\t\t\t<d:set>\n\t\t\t\t<d:prop>\n\t\t\t\t\t<oc:message>'.concat(o,"</oc:message>\n\t\t\t\t</d:prop>\n\t\t\t</d:set>\n\t\t\t</d:propertyupdate>")}));case 3:return n.abrupt("return",n.sent);case 4:case"end":return n.stop()}}),n)})))).apply(this,arguments)}var W=r(26932);function H(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}function V(n){return function(){var t=this,e=arguments;return new Promise((function(r,o){var s=n.apply(t,e);function a(n){H(s,r,o,a,i,"next",n)}function i(n){H(s,r,o,a,i,"throw",n)}a(void 0)}))}}var Y={props:{id:{type:Number,default:null},message:{type:String,default:""},ressourceId:{type:[String,Number],required:!0}},data:function(){return{deleted:!1,editing:!1,loading:!1}},methods:{onEdit:function(){this.editing=!0},onEditCancel:function(){this.editing=!1,this.updateLocalMessage(this.message)},onEditComment:function(n){var e=this;return V(regeneratorRuntime.mark((function r(){return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return e.loading=!0,r.prev=1,r.next=4,Z(e.commentsType,e.ressourceId,e.id,n);case 4:e.logger.debug("Comment edited",{commentsType:e.commentsType,ressourceId:e.ressourceId,id:e.id,message:n}),e.$emit("update:message",n),e.editing=!1,r.next=13;break;case 9:r.prev=9,r.t0=r.catch(1),(0,W.x2)(t("comments","An error occurred while trying to edit the comment")),console.error(r.t0);case 13:return r.prev=13,e.loading=!1,r.finish(13);case 16:case"end":return r.stop()}}),r,null,[[1,9,13,16]])})))()},onDeleteWithUndo:function(){var n=this;this.deleted=!0;var e=setTimeout(this.onDelete,W.et);(0,W.yl)(t("comments","Comment deleted"),(function(){clearTimeout(e),n.deleted=!1}))},onDelete:function(){var n=this;return V(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,q(n.commentsType,n.ressourceId,n.id);case 3:n.logger.debug("Comment deleted",{commentsType:n.commentsType,ressourceId:n.ressourceId,id:n.id}),n.$emit("delete",n.id),e.next=12;break;case 7:e.prev=7,e.t0=e.catch(0),(0,W.x2)(t("comments","An error occurred while trying to delete the comment")),console.error(e.t0),n.deleted=!1;case 12:case"end":return e.stop()}}),e,null,[[0,7]])})))()},onNewComment:function(n){var e=this;return V(regeneratorRuntime.mark((function r(){var o;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return e.loading=!0,r.prev=1,r.next=4,z(e.commentsType,e.ressourceId,n);case 4:o=r.sent,e.logger.debug("New comment posted",{commentsType:e.commentsType,ressourceId:e.ressourceId,newComment:o}),e.$emit("new",o),e.$emit("update:message",""),e.localMessage="",r.next=15;break;case 11:r.prev=11,r.t0=r.catch(1),(0,W.x2)(t("comments","An error occurred while trying to create the comment")),console.error(r.t0);case 15:return r.prev=15,e.loading=!1,r.finish(15);case 18:case"end":return r.stop()}}),r,null,[[1,11,15,18]])})))()}}},X={name:"Comment",components:{ActionButton:v(),Actions:C(),ActionSeparator:j(),Avatar:_(),Moment:R,RichContenteditable:x()},mixins:[O(),Y],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}},data:function(){return{expanded:!1,localMessage:""}},computed:{isOwnComment:function(){return(0,i.getCurrentUser)().uid===this.actorId},renderedContent:function(){return this.isEmptyMessage?"":this.renderContent(this.localMessage)},isEmptyMessage:function(){return!this.localMessage||""===this.localMessage.trim()},timestamp:function(){return parseInt(h()(this.creationDateTime).format("x"),10)/1e3}},watch:{message:function(n){this.updateLocalMessage(n)}},beforeMount:function(){this.updateLocalMessage(this.message)},methods:{updateLocalMessage:function(n){this.localMessage=n.toString()},onSubmit:function(){var n=this;if(""!==this.localMessage.trim())return this.editor?(this.onNewComment(this.localMessage.trim()),void this.$nextTick((function(){n.$refs.editor.$el.focus()}))):void this.onEditComment(this.localMessage.trim())},onExpand:function(){this.expanded=!0}}},Q=r(93379),K=r.n(Q),J=r(7795),nn=r.n(J),tn=r(90569),en=r.n(tn),rn=r(3565),on=r.n(rn),sn=r(19216),an=r.n(sn),cn=r(44589),un=r.n(cn),mn=r(84820),ln={};ln.styleTagTransform=un(),ln.setAttributes=on(),ln.insert=en().bind(null,"head"),ln.domAPI=nn(),ln.insertStyleElement=an(),K()(mn.Z,ln),mn.Z&&mn.Z.locals&&mn.Z.locals;var dn=(0,E.Z)(X,(function(){var n=this,t=n.$createElement,e=n._self._c||t;return e("div",{directives:[{name:"show",rawName:"v-show",value:!n.deleted,expression:"!deleted"}],staticClass:"comment",class:{"comment--loading":n.loading}},[e("div",{staticClass:"comment__header"},[e("Avatar",{staticClass:"comment__avatar",attrs:{"display-name":n.actorDisplayName,user:n.actorId,size:32}}),n._v(" "),e("span",{staticClass:"comment__author"},[n._v(n._s(n.actorDisplayName))]),n._v(" "),n.isOwnComment&&n.id&&!n.loading?e("Actions",{staticClass:"comment__actions"},[n.editing?e("ActionButton",{attrs:{icon:"icon-close"},on:{click:n.onEditCancel}},[n._v("\n\t\t\t\t"+n._s(n.t("comments","Cancel edit"))+"\n\t\t\t")]):[e("ActionButton",{attrs:{"close-after-click":!0,icon:"icon-rename"},on:{click:n.onEdit}},[n._v("\n\t\t\t\t\t"+n._s(n.t("comments","Edit comment"))+"\n\t\t\t\t")]),n._v(" "),e("ActionSeparator"),n._v(" "),e("ActionButton",{attrs:{"close-after-click":!0,icon:"icon-delete"},on:{click:n.onDeleteWithUndo}},[n._v("\n\t\t\t\t\t"+n._s(n.t("comments","Delete comment"))+"\n\t\t\t\t")])]],2):n._e(),n._v(" "),n.id&&n.loading?e("div",{staticClass:"comment_loading icon-loading-small"}):n.creationDateTime?e("Moment",{staticClass:"comment__timestamp",attrs:{timestamp:n.timestamp}}):n._e()],1),n._v(" "),n.editor||n.editing?e("div",{staticClass:"comment__editor "},[e("RichContenteditable",{ref:"editor",attrs:{"auto-complete":n.autoComplete,contenteditable:!n.loading,value:n.localMessage},on:{"update:value":n.updateLocalMessage,submit:n.onSubmit}}),n._v(" "),e("input",{directives:[{name:"tooltip",rawName:"v-tooltip",value:n.t("comments","Post comment"),expression:"t('comments', 'Post comment')"}],staticClass:"comment__submit",class:n.loading?"icon-loading-small":"icon-confirm",attrs:{type:"submit",disabled:n.isEmptyMessage,value:""},on:{click:n.onSubmit}})],1):e("div",{staticClass:"comment__message",class:{"comment__message--expanded":n.expanded},domProps:{innerHTML:n._s(n.renderedContent)},on:{click:n.onExpand}})])}),[],!1,null,"4bced5e9",null).exports,pn=r(7582),fn=r(18635);function hn(n,t){var e=Object.keys(n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable}))),e.push.apply(e,r)}return e}function gn(n){for(var t=1;t<arguments.length;t++){var e=null!=arguments[t]?arguments[t]:{};t%2?hn(Object(e),!0).forEach((function(t){vn(n,t,e[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(e)):hn(Object(e)).forEach((function(t){Object.defineProperty(n,t,Object.getOwnPropertyDescriptor(e,t))}))}return n}function vn(n,t,e){return t in n?Object.defineProperty(n,t,{value:e,enumerable:!0,configurable:!0,writable:!0}):n[t]=e,n}function An(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}function Cn(n){return function(){var t=this,e=arguments;return new Promise((function(r,o){var s=n.apply(t,e);function a(n){An(s,r,o,a,i,"next",n)}function i(n){An(s,r,o,a,i,"throw",n)}a(void 0)}))}}var bn=20;function jn(n){return yn.apply(this,arguments)}function yn(){return yn=Cn(regeneratorRuntime.mark((function n(t){var e,r,o,s,a,i=arguments;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return e=t.commentsType,r=t.ressourceId,o=i.length>1&&void 0!==i[1]?i[1]:{},s=null,a=["",e,r].join("/"),n.next=6,I.customRequest(a,Object.assign({method:"REPORT",data:'<?xml version="1.0"?>\n\t\t\t<oc:filter-comments\n\t\t\t\txmlns:d="DAV:"\n\t\t\t\txmlns:oc="http://owncloud.org/ns"\n\t\t\t\txmlns:nc="http://nextcloud.org/ns"\n\t\t\t\txmlns:ocs="http://open-collaboration-services.org/ns">\n\t\t\t\t<oc:limit>'.concat(bn,"</oc:limit>\n\t\t\t\t<oc:offset>").concat(o.offset||0,"</oc:offset>\n\t\t\t</oc:filter-comments>")},o)).then((function(n){return s=n,n.data})).then(pn.parseXML).then((function(n){return _n(n,!0)})).then((function(n){return(0,fn.processResponsePayload)(s,n,!0)})).then((function(n){return n.data}));case 6:return n.abrupt("return",n.sent);case 7:case"end":return n.stop()}}),n)}))),yn.apply(this,arguments)}function _n(n){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],e=n.multistatus.response;return e.map((function(n){var e=n.propstat.prop,r=gn(gn({},e),{},{actorDisplayName:wn(e.actorDisplayName,2),message:wn(e.message,2)});return(0,pn.prepareFileFromProps)(r,r.id.toString(),t)}))}function wn(n){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,e=new DOMParser,r=n,o=0;o<t;o++)r=e.parseFromString(r,"text/html").documentElement.textContent;return r}function xn(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}var kn=function(n){var t=u.default.CancelToken.source(),e=function(){var e,r=(e=regeneratorRuntime.mark((function e(r,o){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",n(r,Object.assign({cancelToken:t.token},o)));case 1:case"end":return e.stop()}}),e)})),function(){var n=this,t=arguments;return new Promise((function(r,o){var s=e.apply(n,t);function a(n){xn(s,r,o,a,i,"next",n)}function i(n){xn(s,r,o,a,i,"throw",n)}a(void 0)}))});return function(n,t){return r.apply(this,arguments)}}();return{request:e,cancel:t.cancel}};function On(n,t){(null==t||t>n.length)&&(t=n.length);for(var e=0,r=new Array(t);e<t;e++)r[e]=n[e];return r}function Pn(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}function En(n){return function(){var t=this,e=arguments;return new Promise((function(r,o){var s=n.apply(t,e);function a(n){Pn(s,r,o,a,i,"next",n)}function i(n){Pn(s,r,o,a,i,"throw",n)}a(void 0)}))}}l.default.use(m.default);var Rn={name:"Comments",components:{Comment:dn,EmptyContent:p()},data:function(){return{error:"",loading:!1,done:!1,ressourceId:null,offset:0,comments:[],cancelRequest:function(){},editorData:{actorDisplayName:(0,i.getCurrentUser)().displayName,actorId:(0,i.getCurrentUser)().uid,key:"editor"},Comment:dn}},computed:{hasComments:function(){return this.comments.length>0},isFirstLoading:function(){return this.loading&&0===this.offset}},methods:{update:function(n){var t=this;return En(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.ressourceId=n,t.resetState(),t.getComments();case 3:case"end":return e.stop()}}),e)})))()},onScrollBottomReached:function(){this.error||this.done||this.loading||this.getComments()},genMentionsData:function(n){return Object.values(n).flat().reduce((function(n,t){return n[t.mentionId]={icon:"icon-user",id:t.mentionId,label:t.mentionDisplayName,source:"users",primary:(0,i.getCurrentUser)().uid===t.mentionId},n}),{})},getComments:function(){var n=this;return En(regeneratorRuntime.mark((function e(){var r,o,s,a,i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n.cancelRequest("cancel"),e.prev=1,n.loading=!0,n.error="",o=kn(jn),s=o.request,a=o.cancel,n.cancelRequest=a,e.next=8,s({commentsType:n.commentsType,ressourceId:n.ressourceId},{offset:n.offset});case 8:i=e.sent,n.logger.debug("Processed ".concat(i.length," comments"),{comments:i}),i.length<bn&&(n.done=!0),(r=n.comments).push.apply(r,function(n){if(Array.isArray(n))return On(n)}(c=i)||function(n){if("undefined"!=typeof Symbol&&null!=n[Symbol.iterator]||null!=n["@@iterator"])return Array.from(n)}(c)||function(n,t){if(n){if("string"==typeof n)return On(n,t);var e=Object.prototype.toString.call(n).slice(8,-1);return"Object"===e&&n.constructor&&(e=n.constructor.name),"Map"===e||"Set"===e?Array.from(n):"Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?On(n,t):void 0}}(c)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),n.offset+=bn,e.next=21;break;case 15:if(e.prev=15,e.t0=e.catch(1),"cancel"!==e.t0.message){e.next=19;break}return e.abrupt("return");case 19:n.error=t("comments","Unable to load the comments list"),console.error("Error loading the comments list",e.t0);case 21:return e.prev=21,n.loading=!1,e.finish(21);case 24:case"end":return e.stop()}var c}),e,null,[[1,15,21,24]])})))()},autoComplete:function(n,t){var e=this;return En(regeneratorRuntime.mark((function r(){var o;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,u.default.get((0,a.generateOcsUrl)("core/autocomplete/get"),{params:{search:n,itemType:"files",itemId:e.ressourceId,sorter:"commenters|share-recipients",limit:(0,c.loadState)("comments","maxAutoCompleteResults")}});case 2:return o=r.sent,r.abrupt("return",t(o.data.ocs.data));case 4:case"end":return r.stop()}}),r)})))()},onNewComment:function(n){this.comments.unshift(n)},onDelete:function(n){var t=this.comments.findIndex((function(t){return t.props.id===n}));t>-1?this.comments.splice(t,1):console.error("Could not find the deleted comment in the list",n)},resetState:function(){this.error="",this.loading=!1,this.done=!1,this.offset=0,this.comments=[]}}},Dn=r(56282),Tn={};Tn.styleTagTransform=un(),Tn.setAttributes=on(),Tn.insert=en().bind(null,"head"),Tn.domAPI=nn(),Tn.insertStyleElement=an(),K()(Dn.Z,Tn),Dn.Z&&Dn.Z.locals&&Dn.Z.locals;var In=(0,E.Z)(Rn,(function(){var n=this,t=n.$createElement,e=n._self._c||t;return e("div",{staticClass:"comments",class:{"icon-loading":n.isFirstLoading}},[e("Comment",n._b({staticClass:"comments__writer",attrs:{"auto-complete":n.autoComplete,editor:!0,"ressource-id":n.ressourceId},on:{new:n.onNewComment}},"Comment",n.editorData,!1)),n._v(" "),n.isFirstLoading?n._e():[!n.hasComments&&n.done?e("EmptyContent",{attrs:{icon:"icon-comment"}},[n._v("\n\t\t\t"+n._s(n.t("comments","No comments yet, start the conversation!"))+"\n\t\t")]):n._l(n.comments,(function(t){return e("Comment",n._b({key:t.props.id,staticClass:"comments__list",attrs:{"auto-complete":n.autoComplete,message:t.props.message,"ressource-id":n.ressourceId,"user-data":n.genMentionsData(t.props.mentions)},on:{"update:message":function(e){return n.$set(t.props,"message",e)},delete:n.onDelete}},"Comment",t.props,!1))})),n._v(" "),n.loading&&!n.isFirstLoading?e("div",{staticClass:"comments__info icon-loading"}):n.hasComments&&n.done?e("div",{staticClass:"comments__info"},[n._v("\n\t\t\t"+n._s(n.t("comments","No more messages"))+"\n\t\t")]):n.error?e("EmptyContent",{staticClass:"comments__error",attrs:{icon:"icon-error"},scopedSlots:n._u([{key:"desc",fn:function(){return[e("button",{attrs:{icon:"icon-history"},on:{click:n.getComments}},[n._v("\n\t\t\t\t\t"+n._s(n.t("comments","Retry"))+"\n\t\t\t\t")])]},proxy:!0}],null,!1,1182580137)},[n._v("\n\t\t\t"+n._s(n.error)+"\n\t\t\t")]):n._e()]],2)}),[],!1,null,"3808dce0",null).exports;function Sn(n,t){for(var e=0;e<t.length;e++){var r=t[e];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(n,r.key,r)}}function Mn(n,t,e){return t&&Sn(n.prototype,t),e&&Sn(n,e),Object.defineProperty(n,"prototype",{writable:!1}),n}function zn(n,t){if(!(n instanceof t))throw new TypeError("Cannot call a class as a function")}var Nn=(0,o.IY)().setApp("comments").detectUser().build();l.default.mixin({data:function(){return{logger:Nn}},methods:{t:s.translate,n:s.translatePlural}});var Bn=Mn((function n(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"files",e=arguments.length>1?arguments[1]:void 0;zn(this,n),l.default.mixin({data:function(){return{commentsType:t}}});var r=l.default.extend(In);return new r(e)}));window.OCA&&!window.OCA.Comments&&Object.assign(window.OCA,{Comments:{}}),Object.assign(window.OCA.Comments,{View:Bn}),console.debug("OCA.Comments.View initialized")},84820:function(n,t,e){"use strict";var r=e(87537),o=e.n(r),s=e(23645),a=e.n(s)()(o());a.push([n.id,".comment[data-v-4bced5e9]{position:relative;padding:10px 0 15px}.comment__header[data-v-4bced5e9]{display:flex;align-items:center;min-height:44px;padding:5px 0}.comment__author[data-v-4bced5e9],.comment__actions[data-v-4bced5e9]{margin-left:10px !important}.comment__author[data-v-4bced5e9]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:var(--color-text-maxcontrast)}.comment_loading[data-v-4bced5e9],.comment__timestamp[data-v-4bced5e9]{margin-left:auto;color:var(--color-text-maxcontrast)}.comment__editor[data-v-4bced5e9],.comment__message[data-v-4bced5e9]{position:relative;padding-left:42px}.comment__submit[data-v-4bced5e9]{position:absolute;right:0;bottom:0;width:44px;height:44px;margin:1px;cursor:pointer;opacity:.7;border:none;background-color:rgba(0,0,0,0) !important}.comment__submit[data-v-4bced5e9]:disabled{cursor:not-allowed;opacity:.5}.comment__submit[data-v-4bced5e9]:focus,.comment__submit[data-v-4bced5e9]:hover{opacity:1}.comment__message[data-v-4bced5e9]{white-space:pre-wrap;word-break:break-word;max-height:70px;overflow:hidden}.comment__message--expanded[data-v-4bced5e9]{max-height:none;overflow:visible}.rich-contenteditable__input[data-v-4bced5e9]{min-height:44px;margin:0;padding:10px}","",{version:3,sources:["webpack://./apps/comments/src/components/Comment.vue"],names:[],mappings:"AA0PA,0BACC,iBAAA,CACA,mBAAA,CAEA,kCACC,YAAA,CACA,kBAAA,CACA,eAAA,CACA,aAAA,CAGD,qEAEC,2BAAA,CAGD,kCACC,eAAA,CACA,kBAAA,CACA,sBAAA,CACA,mCAAA,CAGD,uEAEC,gBAAA,CACA,mCAAA,CAGD,qEAEC,iBAAA,CAEA,iBAAA,CAGD,kCACC,iBAAA,CACA,OAAA,CACA,QAAA,CACA,UAAA,CACA,WAAA,CAEA,UAAA,CACA,cAAA,CACA,UAAA,CACA,WAAA,CACA,yCAAA,CAEA,2CACC,kBAAA,CACA,UAAA,CAGD,gFAEC,SAAA,CAIF,mCACC,oBAAA,CACA,qBAAA,CACA,eAAA,CACA,eAAA,CACA,6CACC,eAAA,CACA,gBAAA,CAKH,8CACC,eAAA,CACA,QAAA,CACA,YA7EiB",sourcesContent:['\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n@use "sass:math";\n\n$comment-padding: 10px;\n\n.comment {\n\tposition: relative;\n\tpadding: $comment-padding 0 $comment-padding * 1.5;\n\n\t&__header {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t\tmin-height: 44px;\n\t\tpadding: math.div($comment-padding, 2) 0;\n\t}\n\n\t&__author,\n\t&__actions {\n\t\tmargin-left: $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-left: auto;\n\t\tcolor: var(--color-text-maxcontrast);\n\t}\n\n\t&__editor,\n\t&__message {\n\t\tposition: relative;\n\t\t// Avatar size, align with author name\n\t\tpadding-left: 32px + $comment-padding;\n\t}\n\n\t&__submit {\n\t\tposition: absolute;\n\t\tright: 0;\n\t\tbottom: 0;\n\t\twidth: 44px;\n\t\theight: 44px;\n\t\t// Align with input border\n\t\tmargin: 1px;\n\t\tcursor: pointer;\n\t\topacity: .7;\n\t\tborder: none;\n\t\tbackground-color: transparent !important;\n\n\t\t&:disabled {\n\t\t\tcursor: not-allowed;\n\t\t\topacity: .5;\n\t\t}\n\n\t\t&:focus,\n\t\t&:hover {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\n\t&__message {\n\t\twhite-space: pre-wrap;\n\t\tword-break: break-word;\n\t\tmax-height: 70px;\n\t\toverflow: hidden;\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:""}]),t.Z=a},56282:function(n,t,e){"use strict";var r=e(87537),o=e.n(r),s=e(23645),a=e.n(s)()(o());a.push([n.id,".comments__error[data-v-3808dce0]{margin-top:0}.comments__info[data-v-3808dce0]{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:"AAsRC,kCACC,YAAA,CAGD,iCACC,WAAA,CACA,mCAAA,CACA,iBAAA,CACA,gBAAA",sourcesContent:["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n.comments {\n\t// Do not add emptycontent top margin\n\t&__error{\n\t\tmargin-top: 0;\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:""}]),t.Z=a},69862:function(){},40964:function(){}},r={};function o(n){var t=r[n];if(void 0!==t)return t.exports;var s=r[n]={id:n,loaded:!1,exports:{}};return e[n].call(s.exports,s,s.exports,o),s.loaded=!0,s.exports}o.m=e,o.amdD=function(){throw new Error("define cannot be used indirect")},o.amdO={},n=[],o.O=function(t,e,r,s){if(!e){var a=1/0;for(m=0;m<n.length;m++){e=n[m][0],r=n[m][1],s=n[m][2];for(var i=!0,c=0;c<e.length;c++)(!1&s||a>=s)&&Object.keys(o.O).every((function(n){return o.O[n](e[c])}))?e.splice(c--,1):(i=!1,s<a&&(a=s));if(i){n.splice(m--,1);var u=r();void 0!==u&&(t=u)}}return t}s=s||0;for(var m=n.length;m>0&&n[m-1][2]>s;m--)n[m]=n[m-1];n[m]=[e,r,s]},o.n=function(n){var t=n&&n.__esModule?function(){return n.default}:function(){return n};return o.d(t,{a:t}),t},o.d=function(n,t){for(var e in t)o.o(t,e)&&!o.o(n,e)&&Object.defineProperty(n,e,{enumerable:!0,get:t[e]})},o.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(n){if("object"==typeof window)return window}}(),o.o=function(n,t){return Object.prototype.hasOwnProperty.call(n,t)},o.r=function(n){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(n,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(n,"__esModule",{value:!0})},o.nmd=function(n){return n.paths=[],n.children||(n.children=[]),n},o.j=6335,function(){o.b=document.baseURI||self.location.href;var n={6335:0};o.O.j=function(t){return 0===n[t]};var t=function(t,e){var r,s,a=e[0],i=e[1],c=e[2],u=0;if(a.some((function(t){return 0!==n[t]}))){for(r in i)o.o(i,r)&&(o.m[r]=i[r]);if(c)var m=c(o)}for(t&&t(e);u<a.length;u++)s=a[u],o.o(n,s)&&n[s]&&n[s][0](),n[s]=0;return o.O(m)},e=self.webpackChunknextcloud=self.webpackChunknextcloud||[];e.forEach(t.bind(null,0)),e.push=t.bind(null,e.push.bind(e))}(),o.nc=void 0;var s=o.O(void 0,[7874],(function(){return o(7346)}));s=o.O(s)}();
-//# sourceMappingURL=comments-comments-app.js.map?v=3285e87b6453b8f08a7c \ No newline at end of file
+!function(){var n,e={93365:function(n,t,e){var r={"./af":36026,"./af.js":36026,"./ar":28093,"./ar-dz":41943,"./ar-dz.js":41943,"./ar-kw":23969,"./ar-kw.js":23969,"./ar-ly":40594,"./ar-ly.js":40594,"./ar-ma":18369,"./ar-ma.js":18369,"./ar-sa":32579,"./ar-sa.js":32579,"./ar-tn":76442,"./ar-tn.js":76442,"./ar.js":28093,"./az":86425,"./az.js":86425,"./be":22004,"./be.js":22004,"./bg":42982,"./bg.js":42982,"./bm":21067,"./bm.js":21067,"./bn":8366,"./bn-bd":63837,"./bn-bd.js":63837,"./bn.js":8366,"./bo":95040,"./bo.js":95040,"./br":521,"./br.js":521,"./bs":83242,"./bs.js":83242,"./ca":73046,"./ca.js":73046,"./cs":25794,"./cs.js":25794,"./cv":28231,"./cv.js":28231,"./cy":10927,"./cy.js":10927,"./da":42832,"./da.js":42832,"./de":29415,"./de-at":3331,"./de-at.js":3331,"./de-ch":45524,"./de-ch.js":45524,"./de.js":29415,"./dv":44700,"./dv.js":44700,"./el":88752,"./el.js":88752,"./en-au":90444,"./en-au.js":90444,"./en-ca":65959,"./en-ca.js":65959,"./en-gb":62762,"./en-gb.js":62762,"./en-ie":40909,"./en-ie.js":40909,"./en-il":79909,"./en-il.js":79909,"./en-in":87942,"./en-in.js":87942,"./en-nz":75200,"./en-nz.js":75200,"./en-sg":21415,"./en-sg.js":21415,"./eo":27447,"./eo.js":27447,"./es":86756,"./es-do":47049,"./es-do.js":47049,"./es-mx":15915,"./es-mx.js":15915,"./es-us":57133,"./es-us.js":57133,"./es.js":86756,"./et":72182,"./et.js":72182,"./eu":14419,"./eu.js":14419,"./fa":2916,"./fa.js":2916,"./fi":49964,"./fi.js":49964,"./fil":16448,"./fil.js":16448,"./fo":26094,"./fo.js":26094,"./fr":35833,"./fr-ca":56994,"./fr-ca.js":56994,"./fr-ch":2740,"./fr-ch.js":2740,"./fr.js":35833,"./fy":69542,"./fy.js":69542,"./ga":93264,"./ga.js":93264,"./gd":77457,"./gd.js":77457,"./gl":83043,"./gl.js":83043,"./gom-deva":24034,"./gom-deva.js":24034,"./gom-latn":28379,"./gom-latn.js":28379,"./gu":406,"./gu.js":406,"./he":73219,"./he.js":73219,"./hi":99834,"./hi.js":99834,"./hr":28754,"./hr.js":28754,"./hu":93945,"./hu.js":93945,"./hy-am":81319,"./hy-am.js":81319,"./id":24875,"./id.js":24875,"./is":23724,"./is.js":23724,"./it":79906,"./it-ch":34303,"./it-ch.js":34303,"./it.js":79906,"./ja":77105,"./ja.js":77105,"./jv":15026,"./jv.js":15026,"./ka":67416,"./ka.js":67416,"./kk":79734,"./kk.js":79734,"./km":60757,"./km.js":60757,"./kn":58369,"./kn.js":58369,"./ko":77687,"./ko.js":77687,"./ku":95544,"./ku.js":95544,"./ky":85431,"./ky.js":85431,"./lb":13613,"./lb.js":13613,"./lo":34252,"./lo.js":34252,"./lt":84619,"./lt.js":84619,"./lv":93760,"./lv.js":93760,"./me":93393,"./me.js":93393,"./mi":12369,"./mi.js":12369,"./mk":48664,"./mk.js":48664,"./ml":23099,"./ml.js":23099,"./mn":98539,"./mn.js":98539,"./mr":778,"./mr.js":778,"./ms":39970,"./ms-my":82625,"./ms-my.js":82625,"./ms.js":39970,"./mt":15714,"./mt.js":15714,"./my":53055,"./my.js":53055,"./nb":73945,"./nb.js":73945,"./ne":63645,"./ne.js":63645,"./nl":4829,"./nl-be":12823,"./nl-be.js":12823,"./nl.js":4829,"./nn":23756,"./nn.js":23756,"./oc-lnc":41228,"./oc-lnc.js":41228,"./pa-in":97877,"./pa-in.js":97877,"./pl":53066,"./pl.js":53066,"./pt":28677,"./pt-br":81592,"./pt-br.js":81592,"./pt.js":28677,"./ro":32722,"./ro.js":32722,"./ru":59138,"./ru.js":59138,"./sd":32568,"./sd.js":32568,"./se":49753,"./se.js":49753,"./si":58024,"./si.js":58024,"./sk":31058,"./sk.js":31058,"./sl":43452,"./sl.js":43452,"./sq":2795,"./sq.js":2795,"./sr":26976,"./sr-cyrl":38819,"./sr-cyrl.js":38819,"./sr.js":26976,"./ss":7467,"./ss.js":7467,"./sv":42787,"./sv.js":42787,"./sw":80298,"./sw.js":80298,"./ta":57532,"./ta.js":57532,"./te":76076,"./te.js":76076,"./tet":40452,"./tet.js":40452,"./tg":64794,"./tg.js":64794,"./th":48245,"./th.js":48245,"./tk":8870,"./tk.js":8870,"./tl-ph":36056,"./tl-ph.js":36056,"./tlh":15249,"./tlh.js":15249,"./tr":22053,"./tr.js":22053,"./tzl":39871,"./tzl.js":39871,"./tzm":39574,"./tzm-latn":19210,"./tzm-latn.js":19210,"./tzm.js":39574,"./ug-cn":91532,"./ug-cn.js":91532,"./uk":11432,"./uk.js":11432,"./ur":88523,"./ur.js":88523,"./uz":54958,"./uz-latn":68735,"./uz-latn.js":68735,"./uz.js":54958,"./vi":83398,"./vi.js":83398,"./x-pseudo":56665,"./x-pseudo.js":56665,"./yo":11642,"./yo.js":11642,"./zh-cn":5462,"./zh-cn.js":5462,"./zh-hk":92530,"./zh-hk.js":92530,"./zh-mo":41650,"./zh-mo.js":41650,"./zh-tw":97333,"./zh-tw.js":97333};function o(n){var t=s(n);return e(t)}function s(n){if(!e.o(r,n)){var t=new Error("Cannot find module '"+n+"'");throw t.code="MODULE_NOT_FOUND",t}return r[n]}o.keys=function(){return Object.keys(r)},o.resolve=s,n.exports=o,o.id=93365},404:function(n,e,r){"use strict";var o=r(17499),s=r(9944),a=r(79753),i=r(22200),c=r(16453),u=r(4820),m=r(34741),l=r(20144),d=r(97e3),p=r.n(d),f=r(80351),h=r.n(f),g=r(56286),v=r.n(g),A=r(79440),j=r.n(A),C=r(33521),y=r.n(C),b=r(28017),_=r.n(b),w=r(1412),x=r.n(w),k=r(11243),O=r.n(k),R=r(13408),D=r.n(R),P=r(73723),E={name:"Moment",props:{timestamp:{type:Number,required:!0},format:{type:String,default:"LLL"}},computed:{title:function(){return h().unix(this.timestamp).format(this.format)},formatted:function(){return h().unix(this.timestamp).fromNow()}}},T=r(51900),I=(0,T.Z)(E,(function(){var n=this,t=n.$createElement;return(n._self._c||t)("span",{staticClass:"live-relative-timestamp",attrs:{"data-timestamp":1e3*n.timestamp,title:n.title}},[n._v(n._s(n.formatted))])}),[],!1,null,null,null).exports,S=function(){return(0,a.generateRemoteUrl)("dav/comments")},M=r(81063);u.default.defaults.headers["X-Requested-With"]="XMLHttpRequest",(0,M.getPatcher)().patch("request",u.default);var z=(0,M.createClient)(S());function B(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}function N(n){return function(){var t=this,e=arguments;return new Promise((function(r,o){var s=n.apply(t,e);function a(n){B(s,r,o,a,i,"next",n)}function i(n){B(s,r,o,a,i,"throw",n)}a(void 0)}))}}function q(n,t,e){return $.apply(this,arguments)}function $(){return($=N(regeneratorRuntime.mark((function n(t,e,r){var o,s,a,c,m;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return o=["",t,e].join("/"),n.next=3,u.default.post(S()+o,{actorDisplayName:(0,i.getCurrentUser)().displayName,actorId:(0,i.getCurrentUser)().uid,actorType:"users",creationDateTime:(new Date).toUTCString(),message:r,objectType:"files",verb:"comment"});case 3:return s=n.sent,a=parseInt(s.headers["content-location"].split("/").pop()),c=o+"/"+a,n.next=8,z.stat(c,{details:!0});case 8:return m=n.sent,n.abrupt("return",m.data);case 10:case"end":return n.stop()}}),n)})))).apply(this,arguments)}function U(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}function L(n){return function(){var t=this,e=arguments;return new Promise((function(r,o){var s=n.apply(t,e);function a(n){U(s,r,o,a,i,"next",n)}function i(n){U(s,r,o,a,i,"throw",n)}a(void 0)}))}}function Z(n,t,e){return F.apply(this,arguments)}function F(){return(F=L(regeneratorRuntime.mark((function n(t,e,r){var o;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return o=["",t,e,r].join("/"),n.next=3,z.deleteFile(o);case 3:case"end":return n.stop()}}),n)})))).apply(this,arguments)}function G(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}function H(n){return function(){var t=this,e=arguments;return new Promise((function(r,o){var s=n.apply(t,e);function a(n){G(s,r,o,a,i,"next",n)}function i(n){G(s,r,o,a,i,"throw",n)}a(void 0)}))}}function V(n,t,e,r){return W.apply(this,arguments)}function W(){return(W=H(regeneratorRuntime.mark((function n(t,e,r,o){var s;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return s=["",t,e,r].join("/"),n.next=3,z.customRequest(s,Object.assign({method:"PROPPATCH",data:'<?xml version="1.0"?>\n\t\t\t<d:propertyupdate\n\t\t\t\txmlns:d="DAV:"\n\t\t\t\txmlns:oc="http://owncloud.org/ns">\n\t\t\t<d:set>\n\t\t\t\t<d:prop>\n\t\t\t\t\t<oc:message>'.concat(o,"</oc:message>\n\t\t\t\t</d:prop>\n\t\t\t</d:set>\n\t\t\t</d:propertyupdate>")}));case 3:return n.abrupt("return",n.sent);case 4:case"end":return n.stop()}}),n)})))).apply(this,arguments)}var Y=r(26932);function Q(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}function X(n){return function(){var t=this,e=arguments;return new Promise((function(r,o){var s=n.apply(t,e);function a(n){Q(s,r,o,a,i,"next",n)}function i(n){Q(s,r,o,a,i,"throw",n)}a(void 0)}))}}var K={props:{id:{type:Number,default:null},message:{type:String,default:""},ressourceId:{type:[String,Number],required:!0}},data:function(){return{deleted:!1,editing:!1,loading:!1}},methods:{onEdit:function(){this.editing=!0},onEditCancel:function(){this.editing=!1,this.updateLocalMessage(this.message)},onEditComment:function(n){var e=this;return X(regeneratorRuntime.mark((function r(){return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return e.loading=!0,r.prev=1,r.next=4,V(e.commentsType,e.ressourceId,e.id,n);case 4:e.logger.debug("Comment edited",{commentsType:e.commentsType,ressourceId:e.ressourceId,id:e.id,message:n}),e.$emit("update:message",n),e.editing=!1,r.next=13;break;case 9:r.prev=9,r.t0=r.catch(1),(0,Y.x2)(t("comments","An error occurred while trying to edit the comment")),console.error(r.t0);case 13:return r.prev=13,e.loading=!1,r.finish(13);case 16:case"end":return r.stop()}}),r,null,[[1,9,13,16]])})))()},onDeleteWithUndo:function(){var n=this;this.deleted=!0;var e=setTimeout(this.onDelete,Y.et);(0,Y.yl)(t("comments","Comment deleted"),(function(){clearTimeout(e),n.deleted=!1}))},onDelete:function(){var n=this;return X(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,Z(n.commentsType,n.ressourceId,n.id);case 3:n.logger.debug("Comment deleted",{commentsType:n.commentsType,ressourceId:n.ressourceId,id:n.id}),n.$emit("delete",n.id),e.next=12;break;case 7:e.prev=7,e.t0=e.catch(0),(0,Y.x2)(t("comments","An error occurred while trying to delete the comment")),console.error(e.t0),n.deleted=!1;case 12:case"end":return e.stop()}}),e,null,[[0,7]])})))()},onNewComment:function(n){var e=this;return X(regeneratorRuntime.mark((function r(){var o;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return e.loading=!0,r.prev=1,r.next=4,q(e.commentsType,e.ressourceId,n);case 4:o=r.sent,e.logger.debug("New comment posted",{commentsType:e.commentsType,ressourceId:e.ressourceId,newComment:o}),e.$emit("new",o),e.$emit("update:message",""),e.localMessage="",r.next=15;break;case 11:r.prev=11,r.t0=r.catch(1),(0,Y.x2)(t("comments","An error occurred while trying to create the comment")),console.error(r.t0);case 15:return r.prev=15,e.loading=!1,r.finish(15);case 18:case"end":return r.stop()}}),r,null,[[1,11,15,18]])})))()}}},J={name:"Comment",components:{ActionButton:v(),Actions:j(),ActionSeparator:y(),ArrowRight:P.default,Avatar:_(),Button:x(),Moment:I,RichContenteditable:O()},mixins:[D(),K],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}},data:function(){return{expanded:!1,localMessage:""}},computed:{isOwnComment:function(){return(0,i.getCurrentUser)().uid===this.actorId},renderedContent:function(){return this.isEmptyMessage?"":this.renderContent(this.localMessage)},isEmptyMessage:function(){return!this.localMessage||""===this.localMessage.trim()},timestamp:function(){return parseInt(h()(this.creationDateTime).format("x"),10)/1e3}},watch:{message:function(n){this.updateLocalMessage(n)}},beforeMount:function(){this.updateLocalMessage(this.message)},methods:{updateLocalMessage:function(n){this.localMessage=n.toString()},onSubmit:function(){var n=this;if(""!==this.localMessage.trim())return this.editor?(this.onNewComment(this.localMessage.trim()),void this.$nextTick((function(){n.$refs.editor.$el.focus()}))):void this.onEditComment(this.localMessage.trim())},onExpand:function(){this.expanded=!0}}},nn=r(93379),tn=r.n(nn),en=r(7795),rn=r.n(en),on=r(90569),sn=r.n(on),an=r(3565),cn=r.n(an),un=r(19216),mn=r.n(un),ln=r(44589),dn=r.n(ln),pn=r(24044),fn={};fn.styleTagTransform=dn(),fn.setAttributes=cn(),fn.insert=sn().bind(null,"head"),fn.domAPI=rn(),fn.insertStyleElement=mn(),tn()(pn.Z,fn),pn.Z&&pn.Z.locals&&pn.Z.locals;var hn=(0,T.Z)(J,(function(){var n=this,t=n.$createElement,e=n._self._c||t;return e("div",{directives:[{name:"show",rawName:"v-show",value:!n.deleted,expression:"!deleted"}],staticClass:"comment",class:{"comment--loading":n.loading}},[e("div",{staticClass:"comment__header"},[e("Avatar",{staticClass:"comment__avatar",attrs:{"display-name":n.actorDisplayName,user:n.actorId,size:32}}),n._v(" "),e("span",{staticClass:"comment__author"},[n._v(n._s(n.actorDisplayName))]),n._v(" "),n.isOwnComment&&n.id&&!n.loading?e("Actions",{staticClass:"comment__actions"},[n.editing?e("ActionButton",{attrs:{icon:"icon-close"},on:{click:n.onEditCancel}},[n._v("\n\t\t\t\t"+n._s(n.t("comments","Cancel edit"))+"\n\t\t\t")]):[e("ActionButton",{attrs:{"close-after-click":!0,icon:"icon-rename"},on:{click:n.onEdit}},[n._v("\n\t\t\t\t\t"+n._s(n.t("comments","Edit comment"))+"\n\t\t\t\t")]),n._v(" "),e("ActionSeparator"),n._v(" "),e("ActionButton",{attrs:{"close-after-click":!0,icon:"icon-delete"},on:{click:n.onDeleteWithUndo}},[n._v("\n\t\t\t\t\t"+n._s(n.t("comments","Delete comment"))+"\n\t\t\t\t")])]],2):n._e(),n._v(" "),n.id&&n.loading?e("div",{staticClass:"comment_loading icon-loading-small"}):n.creationDateTime?e("Moment",{staticClass:"comment__timestamp",attrs:{timestamp:n.timestamp}}):n._e()],1),n._v(" "),n.editor||n.editing?e("div",{staticClass:"comment__editor "},[e("RichContenteditable",{ref:"editor",attrs:{"auto-complete":n.autoComplete,contenteditable:!n.loading,value:n.localMessage},on:{"update:value":n.updateLocalMessage,submit:n.onSubmit}}),n._v(" "),e("Button",{staticClass:"comment__submit",attrs:{type:"tertiary-no-background","native-type":"submit","aria-label":n.t("comments","Post comment"),disabled:n.isEmptyMessage},on:{click:n.onSubmit},scopedSlots:n._u([{key:"icon",fn:function(){return[n.loading?e("span",{staticClass:"icon-loading-small"}):e("ArrowRight",{attrs:{size:20}})]},proxy:!0}],null,!1,2357784758)})],1):e("div",{staticClass:"comment__message",class:{"comment__message--expanded":n.expanded},domProps:{innerHTML:n._s(n.renderedContent)},on:{click:n.onExpand}})])}),[],!1,null,"4a15fc2d",null).exports,gn=r(7582),vn=r(18635);function An(n,t){var e=Object.keys(n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable}))),e.push.apply(e,r)}return e}function jn(n){for(var t=1;t<arguments.length;t++){var e=null!=arguments[t]?arguments[t]:{};t%2?An(Object(e),!0).forEach((function(t){Cn(n,t,e[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(e)):An(Object(e)).forEach((function(t){Object.defineProperty(n,t,Object.getOwnPropertyDescriptor(e,t))}))}return n}function Cn(n,t,e){return t in n?Object.defineProperty(n,t,{value:e,enumerable:!0,configurable:!0,writable:!0}):n[t]=e,n}function yn(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}function bn(n){return function(){var t=this,e=arguments;return new Promise((function(r,o){var s=n.apply(t,e);function a(n){yn(s,r,o,a,i,"next",n)}function i(n){yn(s,r,o,a,i,"throw",n)}a(void 0)}))}}var _n=20;function wn(n){return xn.apply(this,arguments)}function xn(){return xn=bn(regeneratorRuntime.mark((function n(t){var e,r,o,s,a,i=arguments;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return e=t.commentsType,r=t.ressourceId,o=i.length>1&&void 0!==i[1]?i[1]:{},s=null,a=["",e,r].join("/"),n.next=6,z.customRequest(a,Object.assign({method:"REPORT",data:'<?xml version="1.0"?>\n\t\t\t<oc:filter-comments\n\t\t\t\txmlns:d="DAV:"\n\t\t\t\txmlns:oc="http://owncloud.org/ns"\n\t\t\t\txmlns:nc="http://nextcloud.org/ns"\n\t\t\t\txmlns:ocs="http://open-collaboration-services.org/ns">\n\t\t\t\t<oc:limit>'.concat(_n,"</oc:limit>\n\t\t\t\t<oc:offset>").concat(o.offset||0,"</oc:offset>\n\t\t\t</oc:filter-comments>")},o)).then((function(n){return s=n,n.data})).then(gn.parseXML).then((function(n){return kn(n,!0)})).then((function(n){return(0,vn.processResponsePayload)(s,n,!0)})).then((function(n){return n.data}));case 6:return n.abrupt("return",n.sent);case 7:case"end":return n.stop()}}),n)}))),xn.apply(this,arguments)}function kn(n){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],e=n.multistatus.response;return e.map((function(n){var e=n.propstat.prop,r=jn(jn({},e),{},{actorDisplayName:On(e.actorDisplayName,2),message:On(e.message,2)});return(0,gn.prepareFileFromProps)(r,r.id.toString(),t)}))}function On(n){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,e=new DOMParser,r=n,o=0;o<t;o++)r=e.parseFromString(r,"text/html").documentElement.textContent;return r}function Rn(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}var Dn=function(n){var t=u.default.CancelToken.source(),e=function(){var e,r=(e=regeneratorRuntime.mark((function e(r,o){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",n(r,Object.assign({cancelToken:t.token},o)));case 1:case"end":return e.stop()}}),e)})),function(){var n=this,t=arguments;return new Promise((function(r,o){var s=e.apply(n,t);function a(n){Rn(s,r,o,a,i,"next",n)}function i(n){Rn(s,r,o,a,i,"throw",n)}a(void 0)}))});return function(n,t){return r.apply(this,arguments)}}();return{request:e,cancel:t.cancel}};function Pn(n,t){(null==t||t>n.length)&&(t=n.length);for(var e=0,r=new Array(t);e<t;e++)r[e]=n[e];return r}function En(n,t,e,r,o,s,a){try{var i=n[s](a),c=i.value}catch(n){return void e(n)}i.done?t(c):Promise.resolve(c).then(r,o)}function Tn(n){return function(){var t=this,e=arguments;return new Promise((function(r,o){var s=n.apply(t,e);function a(n){En(s,r,o,a,i,"next",n)}function i(n){En(s,r,o,a,i,"throw",n)}a(void 0)}))}}l.default.use(m.default);var In={name:"Comments",components:{Comment:hn,EmptyContent:p()},data:function(){return{error:"",loading:!1,done:!1,ressourceId:null,offset:0,comments:[],cancelRequest:function(){},editorData:{actorDisplayName:(0,i.getCurrentUser)().displayName,actorId:(0,i.getCurrentUser)().uid,key:"editor"},Comment:hn}},computed:{hasComments:function(){return this.comments.length>0},isFirstLoading:function(){return this.loading&&0===this.offset}},methods:{update:function(n){var t=this;return Tn(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.ressourceId=n,t.resetState(),t.getComments();case 3:case"end":return e.stop()}}),e)})))()},onScrollBottomReached:function(){this.error||this.done||this.loading||this.getComments()},genMentionsData:function(n){return Object.values(n).flat().reduce((function(n,t){return n[t.mentionId]={icon:"icon-user",id:t.mentionId,label:t.mentionDisplayName,source:"users",primary:(0,i.getCurrentUser)().uid===t.mentionId},n}),{})},getComments:function(){var n=this;return Tn(regeneratorRuntime.mark((function e(){var r,o,s,a,i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n.cancelRequest("cancel"),e.prev=1,n.loading=!0,n.error="",o=Dn(wn),s=o.request,a=o.cancel,n.cancelRequest=a,e.next=8,s({commentsType:n.commentsType,ressourceId:n.ressourceId},{offset:n.offset});case 8:i=e.sent,n.logger.debug("Processed ".concat(i.length," comments"),{comments:i}),i.length<_n&&(n.done=!0),(r=n.comments).push.apply(r,function(n){if(Array.isArray(n))return Pn(n)}(c=i)||function(n){if("undefined"!=typeof Symbol&&null!=n[Symbol.iterator]||null!=n["@@iterator"])return Array.from(n)}(c)||function(n,t){if(n){if("string"==typeof n)return Pn(n,t);var e=Object.prototype.toString.call(n).slice(8,-1);return"Object"===e&&n.constructor&&(e=n.constructor.name),"Map"===e||"Set"===e?Array.from(n):"Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?Pn(n,t):void 0}}(c)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),n.offset+=_n,e.next=21;break;case 15:if(e.prev=15,e.t0=e.catch(1),"cancel"!==e.t0.message){e.next=19;break}return e.abrupt("return");case 19:n.error=t("comments","Unable to load the comments list"),console.error("Error loading the comments list",e.t0);case 21:return e.prev=21,n.loading=!1,e.finish(21);case 24:case"end":return e.stop()}var c}),e,null,[[1,15,21,24]])})))()},autoComplete:function(n,t){var e=this;return Tn(regeneratorRuntime.mark((function r(){var o;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,u.default.get((0,a.generateOcsUrl)("core/autocomplete/get"),{params:{search:n,itemType:"files",itemId:e.ressourceId,sorter:"commenters|share-recipients",limit:(0,c.loadState)("comments","maxAutoCompleteResults")}});case 2:return o=r.sent,r.abrupt("return",t(o.data.ocs.data));case 4:case"end":return r.stop()}}),r)})))()},onNewComment:function(n){this.comments.unshift(n)},onDelete:function(n){var t=this.comments.findIndex((function(t){return t.props.id===n}));t>-1?this.comments.splice(t,1):console.error("Could not find the deleted comment in the list",n)},resetState:function(){this.error="",this.loading=!1,this.done=!1,this.offset=0,this.comments=[]}}},Sn=r(56282),Mn={};Mn.styleTagTransform=dn(),Mn.setAttributes=cn(),Mn.insert=sn().bind(null,"head"),Mn.domAPI=rn(),Mn.insertStyleElement=mn(),tn()(Sn.Z,Mn),Sn.Z&&Sn.Z.locals&&Sn.Z.locals;var zn=(0,T.Z)(In,(function(){var n=this,t=n.$createElement,e=n._self._c||t;return e("div",{staticClass:"comments",class:{"icon-loading":n.isFirstLoading}},[e("Comment",n._b({staticClass:"comments__writer",attrs:{"auto-complete":n.autoComplete,editor:!0,"ressource-id":n.ressourceId},on:{new:n.onNewComment}},"Comment",n.editorData,!1)),n._v(" "),n.isFirstLoading?n._e():[!n.hasComments&&n.done?e("EmptyContent",{attrs:{icon:"icon-comment"}},[n._v("\n\t\t\t"+n._s(n.t("comments","No comments yet, start the conversation!"))+"\n\t\t")]):n._l(n.comments,(function(t){return e("Comment",n._b({key:t.props.id,staticClass:"comments__list",attrs:{"auto-complete":n.autoComplete,message:t.props.message,"ressource-id":n.ressourceId,"user-data":n.genMentionsData(t.props.mentions)},on:{"update:message":function(e){return n.$set(t.props,"message",e)},delete:n.onDelete}},"Comment",t.props,!1))})),n._v(" "),n.loading&&!n.isFirstLoading?e("div",{staticClass:"comments__info icon-loading"}):n.hasComments&&n.done?e("div",{staticClass:"comments__info"},[n._v("\n\t\t\t"+n._s(n.t("comments","No more messages"))+"\n\t\t")]):n.error?e("EmptyContent",{staticClass:"comments__error",attrs:{icon:"icon-error"},scopedSlots:n._u([{key:"desc",fn:function(){return[e("button",{attrs:{icon:"icon-history"},on:{click:n.getComments}},[n._v("\n\t\t\t\t\t"+n._s(n.t("comments","Retry"))+"\n\t\t\t\t")])]},proxy:!0}],null,!1,1182580137)},[n._v("\n\t\t\t"+n._s(n.error)+"\n\t\t\t")]):n._e()]],2)}),[],!1,null,"3808dce0",null).exports;function Bn(n,t){for(var e=0;e<t.length;e++){var r=t[e];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(n,r.key,r)}}function Nn(n,t,e){return t&&Bn(n.prototype,t),e&&Bn(n,e),Object.defineProperty(n,"prototype",{writable:!1}),n}function qn(n,t){if(!(n instanceof t))throw new TypeError("Cannot call a class as a function")}var $n=(0,o.IY)().setApp("comments").detectUser().build();l.default.mixin({data:function(){return{logger:$n}},methods:{t:s.translate,n:s.translatePlural}});var Un=Nn((function n(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"files",e=arguments.length>1?arguments[1]:void 0;qn(this,n),l.default.mixin({data:function(){return{commentsType:t}}});var r=l.default.extend(zn);return new r(e)}));window.OCA&&!window.OCA.Comments&&Object.assign(window.OCA,{Comments:{}}),Object.assign(window.OCA.Comments,{View:Un}),console.debug("OCA.Comments.View initialized")},24044:function(n,t,e){"use strict";var r=e(87537),o=e.n(r),s=e(23645),a=e.n(s)()(o());a.push([n.id,".comment[data-v-4a15fc2d]{position:relative;padding:10px 0 15px}.comment__header[data-v-4a15fc2d]{display:flex;align-items:center;min-height:44px;padding:5px 0}.comment__author[data-v-4a15fc2d],.comment__actions[data-v-4a15fc2d]{margin-left:10px !important}.comment__author[data-v-4a15fc2d]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:var(--color-text-maxcontrast)}.comment_loading[data-v-4a15fc2d],.comment__timestamp[data-v-4a15fc2d]{margin-left:auto;color:var(--color-text-maxcontrast)}.comment__editor[data-v-4a15fc2d],.comment__message[data-v-4a15fc2d]{position:relative;padding-left:42px}.comment__submit[data-v-4a15fc2d]{position:absolute !important;right:0;bottom:0;margin:1px}.comment__message[data-v-4a15fc2d]{white-space:pre-wrap;word-break:break-word;max-height:70px;overflow:hidden}.comment__message--expanded[data-v-4a15fc2d]{max-height:none;overflow:visible}.rich-contenteditable__input[data-v-4a15fc2d]{min-height:44px;margin:0;padding:10px}","",{version:3,sources:["webpack://./apps/comments/src/components/Comment.vue"],names:[],mappings:"AAkQA,0BACC,iBAAA,CACA,mBAAA,CAEA,kCACC,YAAA,CACA,kBAAA,CACA,eAAA,CACA,aAAA,CAGD,qEAEC,2BAAA,CAGD,kCACC,eAAA,CACA,kBAAA,CACA,sBAAA,CACA,mCAAA,CAGD,uEAEC,gBAAA,CACA,mCAAA,CAGD,qEAEC,iBAAA,CAEA,iBAAA,CAGD,kCACC,4BAAA,CACA,OAAA,CACA,QAAA,CAEA,UAAA,CAGD,mCACC,oBAAA,CACA,qBAAA,CACA,eAAA,CACA,eAAA,CACA,6CACC,eAAA,CACA,gBAAA,CAKH,8CACC,eAAA,CACA,QAAA,CACA,YA7DiB",sourcesContent:['\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n@use "sass:math";\n\n$comment-padding: 10px;\n\n.comment {\n\tposition: relative;\n\tpadding: $comment-padding 0 $comment-padding * 1.5;\n\n\t&__header {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t\tmin-height: 44px;\n\t\tpadding: math.div($comment-padding, 2) 0;\n\t}\n\n\t&__author,\n\t&__actions {\n\t\tmargin-left: $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-left: auto;\n\t\tcolor: var(--color-text-maxcontrast);\n\t}\n\n\t&__editor,\n\t&__message {\n\t\tposition: relative;\n\t\t// Avatar size, align with author name\n\t\tpadding-left: 32px + $comment-padding;\n\t}\n\n\t&__submit {\n\t\tposition: absolute !important;\n\t\tright: 0;\n\t\tbottom: 0;\n\t\t// Align with input border\n\t\tmargin: 1px;\n\t}\n\n\t&__message {\n\t\twhite-space: pre-wrap;\n\t\tword-break: break-word;\n\t\tmax-height: 70px;\n\t\toverflow: hidden;\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:""}]),t.Z=a},56282:function(n,t,e){"use strict";var r=e(87537),o=e.n(r),s=e(23645),a=e.n(s)()(o());a.push([n.id,".comments__error[data-v-3808dce0]{margin-top:0}.comments__info[data-v-3808dce0]{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:"AAsRC,kCACC,YAAA,CAGD,iCACC,WAAA,CACA,mCAAA,CACA,iBAAA,CACA,gBAAA",sourcesContent:["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n.comments {\n\t// Do not add emptycontent top margin\n\t&__error{\n\t\tmargin-top: 0;\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:""}]),t.Z=a},69862:function(){},40964:function(){}},r={};function o(n){var t=r[n];if(void 0!==t)return t.exports;var s=r[n]={id:n,loaded:!1,exports:{}};return e[n].call(s.exports,s,s.exports,o),s.loaded=!0,s.exports}o.m=e,o.amdD=function(){throw new Error("define cannot be used indirect")},o.amdO={},n=[],o.O=function(t,e,r,s){if(!e){var a=1/0;for(m=0;m<n.length;m++){e=n[m][0],r=n[m][1],s=n[m][2];for(var i=!0,c=0;c<e.length;c++)(!1&s||a>=s)&&Object.keys(o.O).every((function(n){return o.O[n](e[c])}))?e.splice(c--,1):(i=!1,s<a&&(a=s));if(i){n.splice(m--,1);var u=r();void 0!==u&&(t=u)}}return t}s=s||0;for(var m=n.length;m>0&&n[m-1][2]>s;m--)n[m]=n[m-1];n[m]=[e,r,s]},o.n=function(n){var t=n&&n.__esModule?function(){return n.default}:function(){return n};return o.d(t,{a:t}),t},o.d=function(n,t){for(var e in t)o.o(t,e)&&!o.o(n,e)&&Object.defineProperty(n,e,{enumerable:!0,get:t[e]})},o.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(n){if("object"==typeof window)return window}}(),o.o=function(n,t){return Object.prototype.hasOwnProperty.call(n,t)},o.r=function(n){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(n,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(n,"__esModule",{value:!0})},o.nmd=function(n){return n.paths=[],n.children||(n.children=[]),n},o.j=6335,function(){o.b=document.baseURI||self.location.href;var n={6335:0};o.O.j=function(t){return 0===n[t]};var t=function(t,e){var r,s,a=e[0],i=e[1],c=e[2],u=0;if(a.some((function(t){return 0!==n[t]}))){for(r in i)o.o(i,r)&&(o.m[r]=i[r]);if(c)var m=c(o)}for(t&&t(e);u<a.length;u++)s=a[u],o.o(n,s)&&n[s]&&n[s][0](),n[s]=0;return o.O(m)},e=self.webpackChunknextcloud=self.webpackChunknextcloud||[];e.forEach(t.bind(null,0)),e.push=t.bind(null,e.push.bind(e))}(),o.nc=void 0;var s=o.O(void 0,[7874],(function(){return o(404)}));s=o.O(s)}();
+//# sourceMappingURL=comments-comments-app.js.map?v=e3194bdf3acaf08e2db5 \ No newline at end of file
diff --git a/dist/comments-comments-app.js.map b/dist/comments-comments-app.js.map
index fd029e7898e..c4cf7dc33a2 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=3285e87b6453b8f08a7c","mappings":";gBAAIA,2BCAJ,IAAIC,EAAM,CACT,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,aAAc,MACd,UAAW,MACX,aAAc,MACd,UAAW,MACX,aAAc,MACd,UAAW,MACX,aAAc,MACd,UAAW,MACX,aAAc,MACd,UAAW,MACX,aAAc,MACd,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,KACR,UAAW,MACX,aAAc,MACd,UAAW,KACX,OAAQ,MACR,UAAW,MACX,OAAQ,IACR,UAAW,IACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,M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/node_modules/@nextcloud/moment/node_modules/moment/locale|sync|/^\\.\\/.*$","webpack:///nextcloud/apps/comments/src/components/Moment.vue?vue&type=script&lang=js&","webpack:///nextcloud/apps/comments/src/components/Moment.vue","webpack://nextcloud/./apps/comments/src/components/Moment.vue?9b20","webpack:///nextcloud/apps/comments/src/components/Moment.vue?vue&type=template&id=57999be6&","webpack:///nextcloud/apps/comments/src/utils/davUtils.js","webpack:///nextcloud/apps/comments/src/services/DavClient.js","webpack:///nextcloud/apps/comments/src/services/NewComment.js","webpack:///nextcloud/apps/comments/src/services/DeleteComment.js","webpack:///nextcloud/apps/comments/src/services/EditComment.js","webpack:///nextcloud/apps/comments/src/mixins/CommentMixin.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?1ef0","webpack://nextcloud/./apps/comments/src/components/Comment.vue?7f26","webpack:///nextcloud/apps/comments/src/components/Comment.vue?vue&type=template&id=4bced5e9&scoped=true&","webpack:///nextcloud/apps/comments/src/services/GetComments.js","webpack:///nextcloud/apps/comments/src/utils/cancelableRequest.js","webpack:///nextcloud/apps/comments/src/views/Comments.vue","webpack:///nextcloud/apps/comments/src/views/Comments.vue?vue&type=script&lang=js&","webpack://nextcloud/./apps/comments/src/views/Comments.vue?c8a6","webpack://nextcloud/./apps/comments/src/views/Comments.vue?f45b","webpack:///nextcloud/apps/comments/src/views/Comments.vue?vue&type=template&id=3808dce0&scoped=true&","webpack:///nextcloud/apps/comments/src/services/CommentsInstance.js","webpack:///nextcloud/apps/comments/src/comments-app.js","webpack:///nextcloud/apps/comments/src/components/Comment.vue?vue&type=style&index=0&id=4bced5e9&lang=scss&scoped=true&","webpack:///nextcloud/apps/comments/src/views/Comments.vue?vue&type=style&index=0&id=3808dce0&lang=scss&scoped=true&","webpack:///nextcloud/webpack/bootstrap","webpack:///nextcloud/webpack/runtime/amd define","webpack:///nextcloud/webpack/runtime/amd options","webpack:///nextcloud/webpack/runtime/compat get default export","webpack:///nextcloud/webpack/runtime/define property getters","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/jsonp chunk loading","webpack:///nextcloud/webpack/runtime/nonce","webpack:///nextcloud/webpack/startup"],"sourcesContent":["var deferred = [];\n__webpack_require__.O = function(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(function(key) { return __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 map = {\n\t\"./af\": 36026,\n\t\"./af.js\": 36026,\n\t\"./ar\": 28093,\n\t\"./ar-dz\": 41943,\n\t\"./ar-dz.js\": 41943,\n\t\"./ar-kw\": 23969,\n\t\"./ar-kw.js\": 23969,\n\t\"./ar-ly\": 40594,\n\t\"./ar-ly.js\": 40594,\n\t\"./ar-ma\": 18369,\n\t\"./ar-ma.js\": 18369,\n\t\"./ar-sa\": 32579,\n\t\"./ar-sa.js\": 32579,\n\t\"./ar-tn\": 76442,\n\t\"./ar-tn.js\": 76442,\n\t\"./ar.js\": 28093,\n\t\"./az\": 86425,\n\t\"./az.js\": 86425,\n\t\"./be\": 22004,\n\t\"./be.js\": 22004,\n\t\"./bg\": 42982,\n\t\"./bg.js\": 42982,\n\t\"./bm\": 21067,\n\t\"./bm.js\": 21067,\n\t\"./bn\": 8366,\n\t\"./bn-bd\": 63837,\n\t\"./bn-bd.js\": 63837,\n\t\"./bn.js\": 8366,\n\t\"./bo\": 95040,\n\t\"./bo.js\": 95040,\n\t\"./br\": 521,\n\t\"./br.js\": 521,\n\t\"./bs\": 83242,\n\t\"./bs.js\": 83242,\n\t\"./ca\": 73046,\n\t\"./ca.js\": 73046,\n\t\"./cs\": 25794,\n\t\"./cs.js\": 25794,\n\t\"./cv\": 28231,\n\t\"./cv.js\": 28231,\n\t\"./cy\": 10927,\n\t\"./cy.js\": 10927,\n\t\"./da\": 42832,\n\t\"./da.js\": 42832,\n\t\"./de\": 29415,\n\t\"./de-at\": 3331,\n\t\"./de-at.js\": 3331,\n\t\"./de-ch\": 45524,\n\t\"./de-ch.js\": 45524,\n\t\"./de.js\": 29415,\n\t\"./dv\": 44700,\n\t\"./dv.js\": 44700,\n\t\"./el\": 88752,\n\t\"./el.js\": 88752,\n\t\"./en-au\": 90444,\n\t\"./en-au.js\": 90444,\n\t\"./en-ca\": 65959,\n\t\"./en-ca.js\": 65959,\n\t\"./en-gb\": 62762,\n\t\"./en-gb.js\": 62762,\n\t\"./en-ie\": 40909,\n\t\"./en-ie.js\": 40909,\n\t\"./en-il\": 79909,\n\t\"./en-il.js\": 79909,\n\t\"./en-in\": 87942,\n\t\"./en-in.js\": 87942,\n\t\"./en-nz\": 75200,\n\t\"./en-nz.js\": 75200,\n\t\"./en-sg\": 21415,\n\t\"./en-sg.js\": 21415,\n\t\"./eo\": 27447,\n\t\"./eo.js\": 27447,\n\t\"./es\": 86756,\n\t\"./es-do\": 47049,\n\t\"./es-do.js\": 47049,\n\t\"./es-mx\": 15915,\n\t\"./es-mx.js\": 15915,\n\t\"./es-us\": 57133,\n\t\"./es-us.js\": 57133,\n\t\"./es.js\": 86756,\n\t\"./et\": 72182,\n\t\"./et.js\": 72182,\n\t\"./eu\": 14419,\n\t\"./eu.js\": 14419,\n\t\"./fa\": 2916,\n\t\"./fa.js\": 2916,\n\t\"./fi\": 49964,\n\t\"./fi.js\": 49964,\n\t\"./fil\": 16448,\n\t\"./fil.js\": 16448,\n\t\"./fo\": 26094,\n\t\"./fo.js\": 26094,\n\t\"./fr\": 35833,\n\t\"./fr-ca\": 56994,\n\t\"./fr-ca.js\": 56994,\n\t\"./fr-ch\": 2740,\n\t\"./fr-ch.js\": 2740,\n\t\"./fr.js\": 35833,\n\t\"./fy\": 69542,\n\t\"./fy.js\": 69542,\n\t\"./ga\": 93264,\n\t\"./ga.js\": 93264,\n\t\"./gd\": 77457,\n\t\"./gd.js\": 77457,\n\t\"./gl\": 83043,\n\t\"./gl.js\": 83043,\n\t\"./gom-deva\": 24034,\n\t\"./gom-deva.js\": 24034,\n\t\"./gom-latn\": 28379,\n\t\"./gom-latn.js\": 28379,\n\t\"./gu\": 406,\n\t\"./gu.js\": 406,\n\t\"./he\": 73219,\n\t\"./he.js\": 73219,\n\t\"./hi\": 99834,\n\t\"./hi.js\": 99834,\n\t\"./hr\": 28754,\n\t\"./hr.js\": 28754,\n\t\"./hu\": 93945,\n\t\"./hu.js\": 93945,\n\t\"./hy-am\": 81319,\n\t\"./hy-am.js\": 81319,\n\t\"./id\": 24875,\n\t\"./id.js\": 24875,\n\t\"./is\": 23724,\n\t\"./is.js\": 23724,\n\t\"./it\": 79906,\n\t\"./it-ch\": 34303,\n\t\"./it-ch.js\": 34303,\n\t\"./it.js\": 79906,\n\t\"./ja\": 77105,\n\t\"./ja.js\": 77105,\n\t\"./jv\": 15026,\n\t\"./jv.js\": 15026,\n\t\"./ka\": 67416,\n\t\"./ka.js\": 67416,\n\t\"./kk\": 79734,\n\t\"./kk.js\": 79734,\n\t\"./km\": 60757,\n\t\"./km.js\": 60757,\n\t\"./kn\": 58369,\n\t\"./kn.js\": 58369,\n\t\"./ko\": 77687,\n\t\"./ko.js\": 77687,\n\t\"./ku\": 95544,\n\t\"./ku.js\": 95544,\n\t\"./ky\": 85431,\n\t\"./ky.js\": 85431,\n\t\"./lb\": 13613,\n\t\"./lb.js\": 13613,\n\t\"./lo\": 34252,\n\t\"./lo.js\": 34252,\n\t\"./lt\": 84619,\n\t\"./lt.js\": 84619,\n\t\"./lv\": 93760,\n\t\"./lv.js\": 93760,\n\t\"./me\": 93393,\n\t\"./me.js\": 93393,\n\t\"./mi\": 12369,\n\t\"./mi.js\": 12369,\n\t\"./mk\": 48664,\n\t\"./mk.js\": 48664,\n\t\"./ml\": 23099,\n\t\"./ml.js\": 23099,\n\t\"./mn\": 98539,\n\t\"./mn.js\": 98539,\n\t\"./mr\": 778,\n\t\"./mr.js\": 778,\n\t\"./ms\": 39970,\n\t\"./ms-my\": 82625,\n\t\"./ms-my.js\": 82625,\n\t\"./ms.js\": 39970,\n\t\"./mt\": 15714,\n\t\"./mt.js\": 15714,\n\t\"./my\": 53055,\n\t\"./my.js\": 53055,\n\t\"./nb\": 73945,\n\t\"./nb.js\": 73945,\n\t\"./ne\": 63645,\n\t\"./ne.js\": 63645,\n\t\"./nl\": 4829,\n\t\"./nl-be\": 12823,\n\t\"./nl-be.js\": 12823,\n\t\"./nl.js\": 4829,\n\t\"./nn\": 23756,\n\t\"./nn.js\": 23756,\n\t\"./oc-lnc\": 41228,\n\t\"./oc-lnc.js\": 41228,\n\t\"./pa-in\": 97877,\n\t\"./pa-in.js\": 97877,\n\t\"./pl\": 53066,\n\t\"./pl.js\": 53066,\n\t\"./pt\": 28677,\n\t\"./pt-br\": 81592,\n\t\"./pt-br.js\": 81592,\n\t\"./pt.js\": 28677,\n\t\"./ro\": 32722,\n\t\"./ro.js\": 32722,\n\t\"./ru\": 59138,\n\t\"./ru.js\": 59138,\n\t\"./sd\": 32568,\n\t\"./sd.js\": 32568,\n\t\"./se\": 49753,\n\t\"./se.js\": 49753,\n\t\"./si\": 58024,\n\t\"./si.js\": 58024,\n\t\"./sk\": 31058,\n\t\"./sk.js\": 31058,\n\t\"./sl\": 43452,\n\t\"./sl.js\": 43452,\n\t\"./sq\": 2795,\n\t\"./sq.js\": 2795,\n\t\"./sr\": 26976,\n\t\"./sr-cyrl\": 38819,\n\t\"./sr-cyrl.js\": 38819,\n\t\"./sr.js\": 26976,\n\t\"./ss\": 7467,\n\t\"./ss.js\": 7467,\n\t\"./sv\": 42787,\n\t\"./sv.js\": 42787,\n\t\"./sw\": 80298,\n\t\"./sw.js\": 80298,\n\t\"./ta\": 57532,\n\t\"./ta.js\": 57532,\n\t\"./te\": 76076,\n\t\"./te.js\": 76076,\n\t\"./tet\": 40452,\n\t\"./tet.js\": 40452,\n\t\"./tg\": 64794,\n\t\"./tg.js\": 64794,\n\t\"./th\": 48245,\n\t\"./th.js\": 48245,\n\t\"./tk\": 8870,\n\t\"./tk.js\": 8870,\n\t\"./tl-ph\": 36056,\n\t\"./tl-ph.js\": 36056,\n\t\"./tlh\": 15249,\n\t\"./tlh.js\": 15249,\n\t\"./tr\": 22053,\n\t\"./tr.js\": 22053,\n\t\"./tzl\": 39871,\n\t\"./tzl.js\": 39871,\n\t\"./tzm\": 39574,\n\t\"./tzm-latn\": 19210,\n\t\"./tzm-latn.js\": 19210,\n\t\"./tzm.js\": 39574,\n\t\"./ug-cn\": 91532,\n\t\"./ug-cn.js\": 91532,\n\t\"./uk\": 11432,\n\t\"./uk.js\": 11432,\n\t\"./ur\": 88523,\n\t\"./ur.js\": 88523,\n\t\"./uz\": 54958,\n\t\"./uz-latn\": 68735,\n\t\"./uz-latn.js\": 68735,\n\t\"./uz.js\": 54958,\n\t\"./vi\": 83398,\n\t\"./vi.js\": 83398,\n\t\"./x-pseudo\": 56665,\n\t\"./x-pseudo.js\": 56665,\n\t\"./yo\": 11642,\n\t\"./yo.js\": 11642,\n\t\"./zh-cn\": 5462,\n\t\"./zh-cn.js\": 5462,\n\t\"./zh-hk\": 92530,\n\t\"./zh-hk.js\": 92530,\n\t\"./zh-mo\": 41650,\n\t\"./zh-mo.js\": 41650,\n\t\"./zh-tw\": 97333,\n\t\"./zh-tw.js\": 97333\n};\n\n\nfunction webpackContext(req) {\n\tvar id = webpackContextResolve(req);\n\treturn __webpack_require__(id);\n}\nfunction webpackContextResolve(req) {\n\tif(!__webpack_require__.o(map, req)) {\n\t\tvar e = new Error(\"Cannot find module '\" + req + \"'\");\n\t\te.code = 'MODULE_NOT_FOUND';\n\t\tthrow e;\n\t}\n\treturn map[req];\n}\nwebpackContext.keys = function webpackContextKeys() {\n\treturn Object.keys(map);\n};\nwebpackContext.resolve = webpackContextResolve;\nmodule.exports = webpackContext;\nwebpackContext.id = 93365;","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Moment.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!./Moment.vue?vue&type=script&lang=js&\"","<!-- TODO: Move to vue components -->\n\n<template>\n\t<span class=\"live-relative-timestamp\" :data-timestamp=\"timestamp * 1000\" :title=\"title\">{{ formatted }}</span>\n</template>\n\n<script>\nimport moment from '@nextcloud/moment'\n\nexport default {\n\tname: 'Moment',\n\tprops: {\n\t\ttimestamp: {\n\t\t\ttype: Number,\n\t\t\trequired: true,\n\t\t},\n\t\tformat: {\n\t\t\ttype: String,\n\t\t\tdefault: 'LLL',\n\t\t},\n\t},\n\tcomputed: {\n\t\ttitle() {\n\t\t\treturn moment.unix(this.timestamp).format(this.format)\n\t\t},\n\t\tformatted() {\n\t\t\treturn moment.unix(this.timestamp).fromNow()\n\t\t},\n\t},\n}\n</script>\n","import { render, staticRenderFns } from \"./Moment.vue?vue&type=template&id=57999be6&\"\nimport script from \"./Moment.vue?vue&type=script&lang=js&\"\nexport * from \"./Moment.vue?vue&type=script&lang=js&\"\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 null,\n null\n \n)\n\nexport default component.exports","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('span',{staticClass:\"live-relative-timestamp\",attrs:{\"data-timestamp\":_vm.timestamp * 1000,\"title\":_vm.title}},[_vm._v(_vm._s(_vm.formatted))])}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { generateRemoteUrl } from '@nextcloud/router'\n\nconst getRootPath = function() {\n\treturn generateRemoteUrl('dav/comments')\n}\n\nexport { getRootPath }\n","/**\n * @copyright Copyright (c) 2021 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { createClient, getPatcher } from 'webdav'\nimport axios from '@nextcloud/axios'\n\nimport { getRootPath } from '../utils/davUtils'\n\n// Add this so the server knows it is an request from the browser\naxios.defaults.headers['X-Requested-With'] = 'XMLHttpRequest'\n\n// force our axios\nconst patcher = getPatcher()\npatcher.patch('request', axios)\n\n// init webdav client\nconst client = createClient(getRootPath())\n\nexport default client\n","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { getCurrentUser } from '@nextcloud/auth'\nimport { getRootPath } from '../utils/davUtils'\nimport axios from '@nextcloud/axios'\nimport client from './DavClient'\n\n/**\n * Retrieve the comments list\n *\n * @param {string} commentsType the ressource type\n * @param {number} ressourceId the ressource ID\n * @param {string} message the message\n * @return {object} the new comment\n */\nexport default async function(commentsType, ressourceId, message) {\n\tconst ressourcePath = ['', commentsType, ressourceId].join('/')\n\n\tconst response = await axios.post(getRootPath() + ressourcePath, {\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: 'files',\n\t\tverb: 'comment',\n\t})\n\n\t// Retrieve comment id from ressource location\n\tconst commentId = parseInt(response.headers['content-location'].split('/').pop())\n\tconst commentPath = ressourcePath + '/' + commentId\n\n\t// Fetch newly created comment data\n\tconst comment = await client.stat(commentPath, {\n\t\tdetails: true,\n\t})\n\n\treturn comment.data\n}\n","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport client from './DavClient'\n\n/**\n * Delete a comment\n *\n * @param {string} commentsType the ressource type\n * @param {number} ressourceId the ressource ID\n * @param {number} commentId the comment iD\n */\nexport default async function(commentsType, ressourceId, commentId) {\n\tconst commentPath = ['', commentsType, ressourceId, commentId].join('/')\n\n\t// Fetch newly created comment data\n\tawait client.deleteFile(commentPath)\n}\n","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport client from './DavClient'\n\n/**\n * Edit an existing comment\n *\n * @param {string} commentsType the ressource type\n * @param {number} ressourceId the ressource ID\n * @param {number} commentId the comment iD\n * @param {string} message the message content\n */\nexport default async function(commentsType, ressourceId, commentId, message) {\n\tconst commentPath = ['', commentsType, ressourceId, commentId].join('/')\n\n\treturn await client.customRequest(commentPath, Object.assign({\n\t\tmethod: 'PROPPATCH',\n\t\tdata: `<?xml version=\"1.0\"?>\n\t\t\t<d:propertyupdate\n\t\t\t\txmlns:d=\"DAV:\"\n\t\t\t\txmlns:oc=\"http://owncloud.org/ns\">\n\t\t\t<d:set>\n\t\t\t\t<d:prop>\n\t\t\t\t\t<oc:message>${message}</oc:message>\n\t\t\t\t</d:prop>\n\t\t\t</d:set>\n\t\t\t</d:propertyupdate>`,\n\t}))\n}\n","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport NewComment from '../services/NewComment'\nimport DeleteComment from '../services/DeleteComment'\nimport EditComment from '../services/EditComment'\nimport { showError, showUndo, TOAST_UNDO_TIMEOUT } from '@nextcloud/dialogs'\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\tressourceId: {\n\t\t\ttype: [String, Number],\n\t\t\trequired: true,\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\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.commentsType, this.ressourceId, this.id, message)\n\t\t\t\tthis.logger.debug('Comment edited', { commentsType: this.commentsType, ressourceId: this.ressourceId, 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.deleted = true\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})\n\t\t},\n\t\tasync onDelete() {\n\t\t\ttry {\n\t\t\t\tawait DeleteComment(this.commentsType, this.ressourceId, this.id)\n\t\t\t\tthis.logger.debug('Comment deleted', { commentsType: this.commentsType, ressourceId: this.ressourceId, 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}\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.commentsType, this.ressourceId, message)\n\t\t\t\tthis.logger.debug('New comment posted', { commentsType: this.commentsType, ressourceId: this.ressourceId, 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","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 - @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n -\n - @author John Molakvoæ <skjnldsv@protonmail.com>\n -\n - @license GNU AGPL version 3 or any later version\n -\n - This program is free software: you can redistribute it and/or modify\n - it under the terms of the GNU Affero General Public License as\n - published by the Free Software Foundation, either version 3 of the\n - License, or (at your option) any later version.\n -\n - This program is distributed in the hope that it will be useful,\n - but WITHOUT ANY WARRANTY; without even the implied warranty of\n - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n - GNU Affero General Public License for more details.\n -\n - You should have received a copy of the GNU Affero General Public License\n - along with this program. If not, see <http://www.gnu.org/licenses/>.\n -\n -->\n<template>\n\t<div v-show=\"!deleted\"\n\t\t:class=\"{'comment--loading': loading}\"\n\t\tclass=\"comment\">\n\t\t<!-- Comment header toolbar -->\n\t\t<div class=\"comment__header\">\n\t\t\t<!-- Author -->\n\t\t\t<Avatar class=\"comment__avatar\"\n\t\t\t\t:display-name=\"actorDisplayName\"\n\t\t\t\t:user=\"actorId\"\n\t\t\t\t:size=\"32\" />\n\t\t\t<span class=\"comment__author\">{{ actorDisplayName }}</span>\n\n\t\t\t<!-- Comment actions,\n\t\t\t\tshow if we have a message id and current user is author -->\n\t\t\t<Actions v-if=\"isOwnComment && id && !loading\" class=\"comment__actions\">\n\t\t\t\t<template v-if=\"!editing\">\n\t\t\t\t\t<ActionButton :close-after-click=\"true\"\n\t\t\t\t\t\ticon=\"icon-rename\"\n\t\t\t\t\t\t@click=\"onEdit\">\n\t\t\t\t\t\t{{ t('comments', 'Edit comment') }}\n\t\t\t\t\t</ActionButton>\n\t\t\t\t\t<ActionSeparator />\n\t\t\t\t\t<ActionButton :close-after-click=\"true\"\n\t\t\t\t\t\ticon=\"icon-delete\"\n\t\t\t\t\t\t@click=\"onDeleteWithUndo\">\n\t\t\t\t\t\t{{ t('comments', 'Delete comment') }}\n\t\t\t\t\t</ActionButton>\n\t\t\t\t</template>\n\n\t\t\t\t<ActionButton v-else\n\t\t\t\t\ticon=\"icon-close\"\n\t\t\t\t\t@click=\"onEditCancel\">\n\t\t\t\t\t{{ t('comments', 'Cancel edit') }}\n\t\t\t\t</ActionButton>\n\t\t\t</Actions>\n\n\t\t\t<!-- Show loading if we're editing or deleting, not on new ones -->\n\t\t\t<div v-if=\"id && loading\" class=\"comment_loading icon-loading-small\" />\n\n\t\t\t<!-- Relative time to the comment creation -->\n\t\t\t<Moment v-else-if=\"creationDateTime\" class=\"comment__timestamp\" :timestamp=\"timestamp\" />\n\t\t</div>\n\n\t\t<!-- Message editor -->\n\t\t<div v-if=\"editor || editing\" class=\"comment__editor \">\n\t\t\t<RichContenteditable ref=\"editor\"\n\t\t\t\t:auto-complete=\"autoComplete\"\n\t\t\t\t:contenteditable=\"!loading\"\n\t\t\t\t:value=\"localMessage\"\n\t\t\t\t@update:value=\"updateLocalMessage\"\n\t\t\t\t@submit=\"onSubmit\" />\n\t\t\t<input v-tooltip=\"t('comments', 'Post comment')\"\n\t\t\t\t:class=\"loading ? 'icon-loading-small' :'icon-confirm'\"\n\t\t\t\tclass=\"comment__submit\"\n\t\t\t\ttype=\"submit\"\n\t\t\t\t:disabled=\"isEmptyMessage\"\n\t\t\t\tvalue=\"\"\n\t\t\t\t@click=\"onSubmit\">\n\t\t</div>\n\n\t\t<!-- Message content -->\n\t\t<!-- The html is escaped and sanitized before rendering -->\n\t\t<!-- eslint-disable-next-line vue/no-v-html-->\n\t\t<div v-else\n\t\t\t:class=\"{'comment__message--expanded': expanded}\"\n\t\t\tclass=\"comment__message\"\n\t\t\t@click=\"onExpand\"\n\t\t\tv-html=\"renderedContent\" />\n\t</div>\n</template>\n\n<script>\nimport { getCurrentUser } from '@nextcloud/auth'\nimport moment from '@nextcloud/moment'\n\nimport ActionButton from '@nextcloud/vue/dist/Components/ActionButton'\nimport Actions from '@nextcloud/vue/dist/Components/Actions'\nimport ActionSeparator from '@nextcloud/vue/dist/Components/ActionSeparator'\nimport Avatar from '@nextcloud/vue/dist/Components/Avatar'\nimport RichContenteditable from '@nextcloud/vue/dist/Components/RichContenteditable'\nimport RichEditorMixin from '@nextcloud/vue/dist/Mixins/richEditor'\n\nimport Moment from './Moment'\nimport CommentMixin from '../mixins/CommentMixin'\n\nexport default {\n\tname: 'Comment',\n\n\tcomponents: {\n\t\tActionButton,\n\t\tActions,\n\t\tActionSeparator,\n\t\tAvatar,\n\t\tMoment,\n\t\tRichContenteditable,\n\t},\n\tmixins: [RichEditorMixin, CommentMixin],\n\n\tinheritAttrs: false,\n\n\tprops: {\n\t\tactorDisplayName: {\n\t\t\ttype: String,\n\t\t\trequired: true,\n\t\t},\n\t\tactorId: {\n\t\t\ttype: String,\n\t\t\trequired: true,\n\t\t},\n\t\tcreationDateTime: {\n\t\t\ttype: String,\n\t\t\tdefault: null,\n\t\t},\n\n\t\t/**\n\t\t * Force the editor display\n\t\t */\n\t\teditor: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: false,\n\t\t},\n\n\t\t/**\n\t\t * Provide the autocompletion data\n\t\t */\n\t\tautoComplete: {\n\t\t\ttype: Function,\n\t\t\trequired: true,\n\t\t},\n\t},\n\n\tdata() {\n\t\treturn {\n\t\t\texpanded: false,\n\t\t\t// Only change data locally and update the original\n\t\t\t// parent data when the request is sent and resolved\n\t\t\tlocalMessage: '',\n\t\t}\n\t},\n\n\tcomputed: {\n\n\t\t/**\n\t\t * Is the current user the author of this comment\n\t\t *\n\t\t * @return {boolean}\n\t\t */\n\t\tisOwnComment() {\n\t\t\treturn getCurrentUser().uid === this.actorId\n\t\t},\n\n\t\t/**\n\t\t * Rendered content as html string\n\t\t *\n\t\t * @return {string}\n\t\t */\n\t\trenderedContent() {\n\t\t\tif (this.isEmptyMessage) {\n\t\t\t\treturn ''\n\t\t\t}\n\t\t\treturn this.renderContent(this.localMessage)\n\t\t},\n\n\t\tisEmptyMessage() {\n\t\t\treturn !this.localMessage || this.localMessage.trim() === ''\n\t\t},\n\n\t\ttimestamp() {\n\t\t\t// seconds, not milliseconds\n\t\t\treturn parseInt(moment(this.creationDateTime).format('x'), 10) / 1000\n\t\t},\n\t},\n\n\twatch: {\n\t\t// If the data change, update the local value\n\t\tmessage(message) {\n\t\t\tthis.updateLocalMessage(message)\n\t\t},\n\t},\n\n\tbeforeMount() {\n\t\t// Init localMessage\n\t\tthis.updateLocalMessage(this.message)\n\t},\n\n\tmethods: {\n\t\t/**\n\t\t * Update local Message on outer change\n\t\t *\n\t\t * @param {string} message the message to set\n\t\t */\n\t\tupdateLocalMessage(message) {\n\t\t\tthis.localMessage = message.toString()\n\t\t},\n\n\t\t/**\n\t\t * Dispatch message between edit and create\n\t\t */\n\t\tonSubmit() {\n\t\t\t// Do not submit if message is empty\n\t\t\tif (this.localMessage.trim() === '') {\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tif (this.editor) {\n\t\t\t\tthis.onNewComment(this.localMessage.trim())\n\t\t\t\tthis.$nextTick(() => {\n\t\t\t\t\t// Focus the editor again\n\t\t\t\t\tthis.$refs.editor.$el.focus()\n\t\t\t\t})\n\t\t\t\treturn\n\t\t\t}\n\t\t\tthis.onEditComment(this.localMessage.trim())\n\t\t},\n\n\t\tonExpand() {\n\t\t\tthis.expanded = true\n\t\t},\n\t},\n\n}\n</script>\n\n<style lang=\"scss\" scoped>\n@use \"sass:math\";\n\n$comment-padding: 10px;\n\n.comment {\n\tposition: relative;\n\tpadding: $comment-padding 0 $comment-padding * 1.5;\n\n\t&__header {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t\tmin-height: 44px;\n\t\tpadding: math.div($comment-padding, 2) 0;\n\t}\n\n\t&__author,\n\t&__actions {\n\t\tmargin-left: $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-left: auto;\n\t\tcolor: var(--color-text-maxcontrast);\n\t}\n\n\t&__editor,\n\t&__message {\n\t\tposition: relative;\n\t\t// Avatar size, align with author name\n\t\tpadding-left: 32px + $comment-padding;\n\t}\n\n\t&__submit {\n\t\tposition: absolute;\n\t\tright: 0;\n\t\tbottom: 0;\n\t\twidth: 44px;\n\t\theight: 44px;\n\t\t// Align with input border\n\t\tmargin: 1px;\n\t\tcursor: pointer;\n\t\topacity: .7;\n\t\tborder: none;\n\t\tbackground-color: transparent !important;\n\n\t\t&:disabled {\n\t\t\tcursor: not-allowed;\n\t\t\topacity: .5;\n\t\t}\n\n\t\t&:focus,\n\t\t&:hover {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\n\t&__message {\n\t\twhite-space: pre-wrap;\n\t\tword-break: break-word;\n\t\tmax-height: 70px;\n\t\toverflow: hidden;\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</style>\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=4bced5e9&lang=scss&scoped=true&\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\n\n options.insert = insertFn.bind(null, \"head\");\n \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=4bced5e9&lang=scss&scoped=true&\";\n export default content && content.locals ? content.locals : undefined;\n","import { render, staticRenderFns } from \"./Comment.vue?vue&type=template&id=4bced5e9&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=4bced5e9&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 \"4bced5e9\",\n null\n \n)\n\nexport default component.exports","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{directives:[{name:\"show\",rawName:\"v-show\",value:(!_vm.deleted),expression:\"!deleted\"}],staticClass:\"comment\",class:{'comment--loading': _vm.loading}},[_c('div',{staticClass:\"comment__header\"},[_c('Avatar',{staticClass:\"comment__avatar\",attrs:{\"display-name\":_vm.actorDisplayName,\"user\":_vm.actorId,\"size\":32}}),_vm._v(\" \"),_c('span',{staticClass:\"comment__author\"},[_vm._v(_vm._s(_vm.actorDisplayName))]),_vm._v(\" \"),(_vm.isOwnComment && _vm.id && !_vm.loading)?_c('Actions',{staticClass:\"comment__actions\"},[(!_vm.editing)?[_c('ActionButton',{attrs:{\"close-after-click\":true,\"icon\":\"icon-rename\"},on:{\"click\":_vm.onEdit}},[_vm._v(\"\\n\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Edit comment'))+\"\\n\\t\\t\\t\\t\")]),_vm._v(\" \"),_c('ActionSeparator'),_vm._v(\" \"),_c('ActionButton',{attrs:{\"close-after-click\":true,\"icon\":\"icon-delete\"},on:{\"click\":_vm.onDeleteWithUndo}},[_vm._v(\"\\n\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Delete comment'))+\"\\n\\t\\t\\t\\t\")])]:_c('ActionButton',{attrs:{\"icon\":\"icon-close\"},on:{\"click\":_vm.onEditCancel}},[_vm._v(\"\\n\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Cancel edit'))+\"\\n\\t\\t\\t\")])],2):_vm._e(),_vm._v(\" \"),(_vm.id && _vm.loading)?_c('div',{staticClass:\"comment_loading icon-loading-small\"}):(_vm.creationDateTime)?_c('Moment',{staticClass:\"comment__timestamp\",attrs:{\"timestamp\":_vm.timestamp}}):_vm._e()],1),_vm._v(\" \"),(_vm.editor || _vm.editing)?_c('div',{staticClass:\"comment__editor \"},[_c('RichContenteditable',{ref:\"editor\",attrs:{\"auto-complete\":_vm.autoComplete,\"contenteditable\":!_vm.loading,\"value\":_vm.localMessage},on:{\"update:value\":_vm.updateLocalMessage,\"submit\":_vm.onSubmit}}),_vm._v(\" \"),_c('input',{directives:[{name:\"tooltip\",rawName:\"v-tooltip\",value:(_vm.t('comments', 'Post comment')),expression:\"t('comments', 'Post comment')\"}],staticClass:\"comment__submit\",class:_vm.loading ? 'icon-loading-small' :'icon-confirm',attrs:{\"type\":\"submit\",\"disabled\":_vm.isEmptyMessage,\"value\":\"\"},on:{\"click\":_vm.onSubmit}})],1):_c('div',{staticClass:\"comment__message\",class:{'comment__message--expanded': _vm.expanded},domProps:{\"innerHTML\":_vm._s(_vm.renderedContent)},on:{\"click\":_vm.onExpand}})])}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { parseXML, prepareFileFromProps } from 'webdav/dist/node/tools/dav'\nimport { processResponsePayload } from 'webdav/dist/node/response'\nimport client from './DavClient'\n\nexport const DEFAULT_LIMIT = 20\n/**\n * Retrieve the comments list\n *\n * @param {object} data destructuring object\n * @param {string} data.commentsType the ressource type\n * @param {number} data.ressourceId the ressource ID\n * @param {object} [options] optional options for axios\n * @return {object[]} the comments list\n */\nexport default async function({ commentsType, ressourceId }, options = {}) {\n\tlet response = null\n\tconst ressourcePath = ['', commentsType, ressourceId].join('/')\n\n\treturn await client.customRequest(ressourcePath, Object.assign({\n\t\tmethod: 'REPORT',\n\t\tdata: `<?xml version=\"1.0\"?>\n\t\t\t<oc:filter-comments\n\t\t\t\txmlns:d=\"DAV:\"\n\t\t\t\txmlns:oc=\"http://owncloud.org/ns\"\n\t\t\t\txmlns:nc=\"http://nextcloud.org/ns\"\n\t\t\t\txmlns:ocs=\"http://open-collaboration-services.org/ns\">\n\t\t\t\t<oc:limit>${DEFAULT_LIMIT}</oc:limit>\n\t\t\t\t<oc:offset>${options.offset || 0}</oc:offset>\n\t\t\t</oc:filter-comments>`,\n\t}, options))\n\t\t// See example on how it's done normaly\n\t\t// https://github.com/perry-mitchell/webdav-client/blob/9de2da4a2599e06bd86c2778145b7ade39fe0b3c/source/interface/stat.js#L19\n\t\t// Waiting for proper REPORT integration https://github.com/perry-mitchell/webdav-client/issues/207\n\t\t.then(res => {\n\t\t\tresponse = res\n\t\t\treturn res.data\n\t\t})\n\t\t.then(parseXML)\n\t\t.then(xml => processMultistatus(xml, true))\n\t\t.then(comments => processResponsePayload(response, comments, true))\n\t\t.then(response => response.data)\n}\n\n// https://github.com/perry-mitchell/webdav-client/blob/9de2da4a2599e06bd86c2778145b7ade39fe0b3c/source/interface/directoryContents.js#L32\n/**\n * @param {any} result -\n * @param {any} isDetailed -\n */\nfunction processMultistatus(result, isDetailed = false) {\n\t// Extract the response items (directory contents)\n\tconst {\n\t\tmultistatus: { response: responseItems },\n\t} = result\n\treturn responseItems.map(item => {\n\t\t// Each item should contain a stat object\n\t\tconst {\n\t\t\tpropstat: { prop: props },\n\t\t} = item\n\t\t// Decode HTML entities\n\t\tconst decodedProps = {\n\t\t\t...props,\n\t\t\t// Decode twice to handle potentially double-encoded entities\n\t\t\t// FIXME Remove this once https://github.com/nextcloud/server/issues/29306 is resolved\n\t\t\tactorDisplayName: decodeHtmlEntities(props.actorDisplayName, 2),\n\t\t\tmessage: decodeHtmlEntities(props.message, 2),\n\t\t}\n\t\treturn prepareFileFromProps(decodedProps, decodedProps.id.toString(), isDetailed)\n\t})\n}\n\n/**\n * @param {any} value -\n * @param {any} passes -\n */\nfunction 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 * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport axios from '@nextcloud/axios'\n\n/**\n * Create a cancel token\n *\n * @return {import('axios').CancelTokenSource}\n */\nconst createCancelToken = () => axios.CancelToken.source()\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\t/**\n\t * Generate an axios cancel token\n\t */\n\tconst cancelToken = createCancelToken()\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\treturn request(\n\t\t\turl,\n\t\t\tObject.assign({ cancelToken: cancelToken.token }, options)\n\t\t)\n\t}\n\n\treturn {\n\t\trequest: fetch,\n\t\tcancel: cancelToken.cancel,\n\t}\n}\n\nexport default cancelableRequest\n","<!--\n - @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n -\n - @author John Molakvoæ <skjnldsv@protonmail.com>\n -\n - @license GNU AGPL version 3 or any later version\n -\n - This program is free software: you can redistribute it and/or modify\n - it under the terms of the GNU Affero General Public License as\n - published by the Free Software Foundation, either version 3 of the\n - License, or (at your option) any later version.\n -\n - This program is distributed in the hope that it will be useful,\n - but WITHOUT ANY WARRANTY; without even the implied warranty of\n - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n - GNU Affero General Public License for more details.\n -\n - You should have received a copy of the GNU Affero General Public License\n - along with this program. If not, see <http://www.gnu.org/licenses/>.\n -\n -->\n\n<template>\n\t<div class=\"comments\" :class=\"{ 'icon-loading': isFirstLoading }\">\n\t\t<!-- Editor -->\n\t\t<Comment v-bind=\"editorData\"\n\t\t\t:auto-complete=\"autoComplete\"\n\t\t\t:editor=\"true\"\n\t\t\t:ressource-id=\"ressourceId\"\n\t\t\tclass=\"comments__writer\"\n\t\t\t@new=\"onNewComment\" />\n\n\t\t<template v-if=\"!isFirstLoading\">\n\t\t\t<EmptyContent v-if=\"!hasComments && done\" icon=\"icon-comment\">\n\t\t\t\t{{ t('comments', 'No comments yet, start the conversation!') }}\n\t\t\t</EmptyContent>\n\n\t\t\t<!-- Comments -->\n\t\t\t<Comment v-for=\"comment in comments\"\n\t\t\t\tv-else\n\t\t\t\t:key=\"comment.props.id\"\n\t\t\t\tv-bind=\"comment.props\"\n\t\t\t\t:auto-complete=\"autoComplete\"\n\t\t\t\t:message.sync=\"comment.props.message\"\n\t\t\t\t:ressource-id=\"ressourceId\"\n\t\t\t\t:user-data=\"genMentionsData(comment.props.mentions)\"\n\t\t\t\tclass=\"comments__list\"\n\t\t\t\t@delete=\"onDelete\" />\n\n\t\t\t<!-- Loading more message -->\n\t\t\t<div v-if=\"loading && !isFirstLoading\" class=\"comments__info icon-loading\" />\n\n\t\t\t<div v-else-if=\"hasComments && done\" class=\"comments__info\">\n\t\t\t\t{{ t('comments', 'No more messages') }}\n\t\t\t</div>\n\n\t\t\t<!-- Error message -->\n\t\t\t<EmptyContent v-else-if=\"error\" class=\"comments__error\" icon=\"icon-error\">\n\t\t\t\t{{ error }}\n\t\t\t\t<template #desc>\n\t\t\t\t\t<button icon=\"icon-history\" @click=\"getComments\">\n\t\t\t\t\t\t{{ t('comments', 'Retry') }}\n\t\t\t\t\t</button>\n\t\t\t\t</template>\n\t\t\t</EmptyContent>\n\t\t</template>\n\t</div>\n</template>\n\n<script>\nimport { generateOcsUrl } from '@nextcloud/router'\nimport { getCurrentUser } from '@nextcloud/auth'\nimport { loadState } from '@nextcloud/initial-state'\nimport axios from '@nextcloud/axios'\nimport VTooltip from 'v-tooltip'\nimport Vue from 'vue'\n\nimport EmptyContent from '@nextcloud/vue/dist/Components/EmptyContent'\n\nimport Comment from '../components/Comment'\nimport getComments, { DEFAULT_LIMIT } from '../services/GetComments'\nimport cancelableRequest from '../utils/cancelableRequest'\n\nVue.use(VTooltip)\n\nexport default {\n\tname: 'Comments',\n\n\tcomponents: {\n\t\t// Avatar,\n\t\tComment,\n\t\tEmptyContent,\n\t},\n\n\tdata() {\n\t\treturn {\n\t\t\terror: '',\n\t\t\tloading: false,\n\t\t\tdone: false,\n\n\t\t\tressourceId: null,\n\t\t\toffset: 0,\n\t\t\tcomments: [],\n\n\t\t\tcancelRequest: () => {},\n\n\t\t\teditorData: {\n\t\t\t\tactorDisplayName: getCurrentUser().displayName,\n\t\t\t\tactorId: getCurrentUser().uid,\n\t\t\t\tkey: 'editor',\n\t\t\t},\n\n\t\t\tComment,\n\t\t}\n\t},\n\n\tcomputed: {\n\t\thasComments() {\n\t\t\treturn this.comments.length > 0\n\t\t},\n\t\tisFirstLoading() {\n\t\t\treturn this.loading && this.offset === 0\n\t\t},\n\t},\n\n\tmethods: {\n\t\t/**\n\t\t * Update current ressourceId and fetch new data\n\t\t *\n\t\t * @param {number} ressourceId the current ressourceId (fileId...)\n\t\t */\n\t\tasync update(ressourceId) {\n\t\t\tthis.ressourceId = ressourceId\n\t\t\tthis.resetState()\n\t\t\tthis.getComments()\n\t\t},\n\n\t\t/**\n\t\t * Ran when the bottom of the tab is reached\n\t\t */\n\t\tonScrollBottomReached() {\n\t\t\t/**\n\t\t\t * Do not fetch more if we:\n\t\t\t * - are showing an error\n\t\t\t * - already fetched everything\n\t\t\t * - are currently loading\n\t\t\t */\n\t\t\tif (this.error || this.done || this.loading) {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tthis.getComments()\n\t\t},\n\n\t\t/**\n\t\t * Make sure we have all mentions as Array of objects\n\t\t *\n\t\t * @param {Array} mentions the mentions list\n\t\t * @return {object[]}\n\t\t */\n\t\tgenMentionsData(mentions) {\n\t\t\tconst list = Object.values(mentions).flat()\n\t\t\treturn list.reduce((mentions, mention) => {\n\t\t\t\tmentions[mention.mentionId] = {\n\t\t\t\t\t// TODO: support groups\n\t\t\t\t\ticon: 'icon-user',\n\t\t\t\t\tid: mention.mentionId,\n\t\t\t\t\tlabel: mention.mentionDisplayName,\n\t\t\t\t\tsource: 'users',\n\t\t\t\t\tprimary: getCurrentUser().uid === mention.mentionId,\n\t\t\t\t}\n\t\t\t\treturn mentions\n\t\t\t}, {})\n\t\t},\n\n\t\t/**\n\t\t * Get the existing shares infos\n\t\t */\n\t\tasync getComments() {\n\t\t\t// Cancel any ongoing request\n\t\t\tthis.cancelRequest('cancel')\n\n\t\t\ttry {\n\t\t\t\tthis.loading = true\n\t\t\t\tthis.error = ''\n\n\t\t\t\t// Init cancellable request\n\t\t\t\tconst { request, cancel } = cancelableRequest(getComments)\n\t\t\t\tthis.cancelRequest = cancel\n\n\t\t\t\t// Fetch comments\n\t\t\t\tconst comments = await request({\n\t\t\t\t\tcommentsType: this.commentsType,\n\t\t\t\t\tressourceId: this.ressourceId,\n\t\t\t\t}, { offset: this.offset })\n\n\t\t\t\tthis.logger.debug(`Processed ${comments.length} comments`, { comments })\n\n\t\t\t\t// We received less than the requested amount,\n\t\t\t\t// we're done fetching comments\n\t\t\t\tif (comments.length < DEFAULT_LIMIT) {\n\t\t\t\t\tthis.done = true\n\t\t\t\t}\n\n\t\t\t\t// Insert results\n\t\t\t\tthis.comments.push(...comments)\n\n\t\t\t\t// Increase offset for next fetch\n\t\t\t\tthis.offset += DEFAULT_LIMIT\n\t\t\t} catch (error) {\n\t\t\t\tif (error.message === 'cancel') {\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tthis.error = t('comments', 'Unable to load the comments list')\n\t\t\t\tconsole.error('Error loading the comments list', error)\n\t\t\t} finally {\n\t\t\t\tthis.loading = false\n\t\t\t}\n\t\t},\n\n\t\t/**\n\t\t * Autocomplete @mentions\n\t\t *\n\t\t * @param {string} search the query\n\t\t * @param {Function} callback the callback to process the results with\n\t\t */\n\t\tasync autoComplete(search, callback) {\n\t\t\tconst results = await axios.get(generateOcsUrl('core/autocomplete/get'), {\n\t\t\t\tparams: {\n\t\t\t\t\tsearch,\n\t\t\t\t\titemType: 'files',\n\t\t\t\t\titemId: this.ressourceId,\n\t\t\t\t\tsorter: 'commenters|share-recipients',\n\t\t\t\t\tlimit: loadState('comments', 'maxAutoCompleteResults'),\n\t\t\t\t},\n\t\t\t})\n\t\t\treturn callback(results.data.ocs.data)\n\t\t},\n\n\t\t/**\n\t\t * Add newly created comment to the list\n\t\t *\n\t\t * @param {object} comment the new comment\n\t\t */\n\t\tonNewComment(comment) {\n\t\t\tthis.comments.unshift(comment)\n\t\t},\n\n\t\t/**\n\t\t * Remove deleted comment from the list\n\t\t *\n\t\t * @param {number} id the deleted comment\n\t\t */\n\t\tonDelete(id) {\n\t\t\tconst index = this.comments.findIndex(comment => comment.props.id === id)\n\t\t\tif (index > -1) {\n\t\t\t\tthis.comments.splice(index, 1)\n\t\t\t} else {\n\t\t\t\tconsole.error('Could not find the deleted comment in the list', id)\n\t\t\t}\n\t\t},\n\n\t\t/**\n\t\t * Reset the current view to its default state\n\t\t */\n\t\tresetState() {\n\t\t\tthis.error = ''\n\t\t\tthis.loading = false\n\t\t\tthis.done = false\n\t\t\tthis.offset = 0\n\t\t\tthis.comments = []\n\t\t},\n\t},\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.comments {\n\t// Do not add emptycontent top margin\n\t&__error{\n\t\tmargin-top: 0;\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</style>\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 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=3808dce0&lang=scss&scoped=true&\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\n\n options.insert = insertFn.bind(null, \"head\");\n \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=3808dce0&lang=scss&scoped=true&\";\n export default content && content.locals ? content.locals : undefined;\n","import { render, staticRenderFns } from \"./Comments.vue?vue&type=template&id=3808dce0&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=3808dce0&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 \"3808dce0\",\n null\n \n)\n\nexport default component.exports","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"comments\",class:{ 'icon-loading': _vm.isFirstLoading }},[_c('Comment',_vm._b({staticClass:\"comments__writer\",attrs:{\"auto-complete\":_vm.autoComplete,\"editor\":true,\"ressource-id\":_vm.ressourceId},on:{\"new\":_vm.onNewComment}},'Comment',_vm.editorData,false)),_vm._v(\" \"),(!_vm.isFirstLoading)?[(!_vm.hasComments && _vm.done)?_c('EmptyContent',{attrs:{\"icon\":\"icon-comment\"}},[_vm._v(\"\\n\\t\\t\\t\"+_vm._s(_vm.t('comments', 'No comments yet, start the conversation!'))+\"\\n\\t\\t\")]):_vm._l((_vm.comments),function(comment){return _c('Comment',_vm._b({key:comment.props.id,staticClass:\"comments__list\",attrs:{\"auto-complete\":_vm.autoComplete,\"message\":comment.props.message,\"ressource-id\":_vm.ressourceId,\"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))}),_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('EmptyContent',{staticClass:\"comments__error\",attrs:{\"icon\":\"icon-error\"},scopedSlots:_vm._u([{key:\"desc\",fn:function(){return [_c('button',{attrs:{\"icon\":\"icon-history\"},on:{\"click\":_vm.getComments}},[_vm._v(\"\\n\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Retry'))+\"\\n\\t\\t\\t\\t\")])]},proxy:true}],null,false,1182580137)},[_vm._v(\"\\n\\t\\t\\t\"+_vm._s(_vm.error)+\"\\n\\t\\t\\t\")]):_vm._e()]:_vm._e()],2)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { getLoggerBuilder } from '@nextcloud/logger'\nimport { translate as t, translatePlural as n } from '@nextcloud/l10n'\nimport CommentsApp from '../views/Comments'\nimport Vue from 'vue'\n\nconst logger = getLoggerBuilder()\n\t.setApp('comments')\n\t.detectUser()\n\t.build()\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} commentsType the comments endpoint type\n\t * @param {object} options the vue options (propsData, parent, el...)\n\t */\n\tconstructor(commentsType = 'files', options) {\n\t\t// Add comments type as a global mixin\n\t\tVue.mixin({\n\t\t\tdata() {\n\t\t\t\treturn {\n\t\t\t\t\tcommentsType,\n\t\t\t\t}\n\t\t\t},\n\t\t})\n\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 * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport CommentsInstance from './services/CommentsInstance'\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","// 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-4bced5e9]{position:relative;padding:10px 0 15px}.comment__header[data-v-4bced5e9]{display:flex;align-items:center;min-height:44px;padding:5px 0}.comment__author[data-v-4bced5e9],.comment__actions[data-v-4bced5e9]{margin-left:10px !important}.comment__author[data-v-4bced5e9]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:var(--color-text-maxcontrast)}.comment_loading[data-v-4bced5e9],.comment__timestamp[data-v-4bced5e9]{margin-left:auto;color:var(--color-text-maxcontrast)}.comment__editor[data-v-4bced5e9],.comment__message[data-v-4bced5e9]{position:relative;padding-left:42px}.comment__submit[data-v-4bced5e9]{position:absolute;right:0;bottom:0;width:44px;height:44px;margin:1px;cursor:pointer;opacity:.7;border:none;background-color:rgba(0,0,0,0) !important}.comment__submit[data-v-4bced5e9]:disabled{cursor:not-allowed;opacity:.5}.comment__submit[data-v-4bced5e9]:focus,.comment__submit[data-v-4bced5e9]:hover{opacity:1}.comment__message[data-v-4bced5e9]{white-space:pre-wrap;word-break:break-word;max-height:70px;overflow:hidden}.comment__message--expanded[data-v-4bced5e9]{max-height:none;overflow:visible}.rich-contenteditable__input[data-v-4bced5e9]{min-height:44px;margin:0;padding:10px}\", \"\",{\"version\":3,\"sources\":[\"webpack://./apps/comments/src/components/Comment.vue\"],\"names\":[],\"mappings\":\"AA0PA,0BACC,iBAAA,CACA,mBAAA,CAEA,kCACC,YAAA,CACA,kBAAA,CACA,eAAA,CACA,aAAA,CAGD,qEAEC,2BAAA,CAGD,kCACC,eAAA,CACA,kBAAA,CACA,sBAAA,CACA,mCAAA,CAGD,uEAEC,gBAAA,CACA,mCAAA,CAGD,qEAEC,iBAAA,CAEA,iBAAA,CAGD,kCACC,iBAAA,CACA,OAAA,CACA,QAAA,CACA,UAAA,CACA,WAAA,CAEA,UAAA,CACA,cAAA,CACA,UAAA,CACA,WAAA,CACA,yCAAA,CAEA,2CACC,kBAAA,CACA,UAAA,CAGD,gFAEC,SAAA,CAIF,mCACC,oBAAA,CACA,qBAAA,CACA,eAAA,CACA,eAAA,CACA,6CACC,eAAA,CACA,gBAAA,CAKH,8CACC,eAAA,CACA,QAAA,CACA,YA7EiB\",\"sourcesContent\":[\"\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n@use \\\"sass:math\\\";\\n\\n$comment-padding: 10px;\\n\\n.comment {\\n\\tposition: relative;\\n\\tpadding: $comment-padding 0 $comment-padding * 1.5;\\n\\n\\t&__header {\\n\\t\\tdisplay: flex;\\n\\t\\talign-items: center;\\n\\t\\tmin-height: 44px;\\n\\t\\tpadding: math.div($comment-padding, 2) 0;\\n\\t}\\n\\n\\t&__author,\\n\\t&__actions {\\n\\t\\tmargin-left: $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-left: auto;\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t}\\n\\n\\t&__editor,\\n\\t&__message {\\n\\t\\tposition: relative;\\n\\t\\t// Avatar size, align with author name\\n\\t\\tpadding-left: 32px + $comment-padding;\\n\\t}\\n\\n\\t&__submit {\\n\\t\\tposition: absolute;\\n\\t\\tright: 0;\\n\\t\\tbottom: 0;\\n\\t\\twidth: 44px;\\n\\t\\theight: 44px;\\n\\t\\t// Align with input border\\n\\t\\tmargin: 1px;\\n\\t\\tcursor: pointer;\\n\\t\\topacity: .7;\\n\\t\\tborder: none;\\n\\t\\tbackground-color: transparent !important;\\n\\n\\t\\t&:disabled {\\n\\t\\t\\tcursor: not-allowed;\\n\\t\\t\\topacity: .5;\\n\\t\\t}\\n\\n\\t\\t&:focus,\\n\\t\\t&:hover {\\n\\t\\t\\topacity: 1;\\n\\t\\t}\\n\\t}\\n\\n\\t&__message {\\n\\t\\twhite-space: pre-wrap;\\n\\t\\tword-break: break-word;\\n\\t\\tmax-height: 70px;\\n\\t\\toverflow: hidden;\\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__error[data-v-3808dce0]{margin-top:0}.comments__info[data-v-3808dce0]{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\":\"AAsRC,kCACC,YAAA,CAGD,iCACC,WAAA,CACA,mCAAA,CACA,iBAAA,CACA,gBAAA\",\"sourcesContent\":[\"\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n.comments {\\n\\t// Do not add emptycontent top margin\\n\\t&__error{\\n\\t\\tmargin-top: 0;\\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","// 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","__webpack_require__.amdD = function () {\n\tthrow new Error('define cannot be used indirect');\n};","__webpack_require__.amdO = {};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(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__.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 = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(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 = function(module) {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","__webpack_require__.j = 6335;","__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\t6335: 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = function(chunkId) { return installedChunks[chunkId] === 0; };\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = function(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(function(id) { return 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, [7874], function() { return __webpack_require__(7346); })\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n"],"names":["deferred","map","webpackContext","req","id","webpackContextResolve","__webpack_require__","o","e","Error","code","keys","Object","resolve","module","exports","_vm","this","_h","$createElement","_self","_c","staticClass","attrs","timestamp","title","_v","_s","formatted","getRootPath","generateRemoteUrl","axios","getPatcher","patch","createClient","commentsType","ressourceId","message","ressourcePath","join","actorDisplayName","getCurrentUser","displayName","actorId","uid","actorType","creationDateTime","Date","toUTCString","objectType","verb","response","commentId","parseInt","headers","split","pop","commentPath","client","details","comment","data","assign","method","props","type","Number","default","String","required","deleted","editing","loading","methods","onEdit","onEditCancel","updateLocalMessage","onEditComment","EditComment","logger","debug","$emit","showError","t","console","error","onDeleteWithUndo","timeOutDelete","setTimeout","onDelete","TOAST_UNDO_TIMEOUT","showUndo","clearTimeout","DeleteComment","onNewComment","NewComment","newComment","localMessage","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","directives","name","rawName","value","expression","class","isOwnComment","on","_e","editor","ref","autoComplete","onSubmit","isEmptyMessage","expanded","domProps","renderedContent","onExpand","DEFAULT_LIMIT","offset","then","res","parseXML","xml","processMultistatus","comments","processResponsePayload","result","isDetailed","responseItems","multistatus","item","propstat","prop","decodedProps","decodeHtmlEntities","prepareFileFromProps","toString","passes","parser","DOMParser","decoded","i","parseFromString","documentElement","textContent","request","cancelToken","fetch","url","token","cancel","isFirstLoading","_b","editorData","hasComments","done","_l","key","genMentionsData","mentions","$event","$set","scopedSlots","_u","fn","getComments","proxy","getLoggerBuilder","setApp","detectUser","build","Vue","n","CommentInstance","View","CommentsApp","window","OCA","Comments","CommentsInstance","___CSS_LOADER_EXPORT___","push","__webpack_module_cache__","moduleId","cachedModule","undefined","loaded","__webpack_modules__","call","m","amdD","amdO","O","chunkIds","priority","notFulfilled","Infinity","length","fulfilled","j","every","splice","r","getter","__esModule","d","a","definition","defineProperty","enumerable","get","g","globalThis","Function","obj","prototype","hasOwnProperty","Symbol","toStringTag","nmd","paths","children","b","document","baseURI","self","location","href","installedChunks","chunkId","webpackJsonpCallback","parentChunkLoadingFunction","moreModules","runtime","some","chunkLoadingGlobal","forEach","bind","nc","__webpack_exports__"],"sourceRoot":""} \ No newline at end of file
+{"version":3,"file":"comments-comments-app.js?v=e3194bdf3acaf08e2db5","mappings":";gBAAIA,2BCAJ,IAAIC,EAAM,CACT,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,aAAc,MACd,UAAW,MACX,aAAc,MACd,UAAW,MACX,aAAc,MACd,UAAW,MACX,aAAc,MACd,UAAW,MACX,aAAc,MACd,UAAW,MACX,aAAc,MACd,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,KACR,UAAW,MACX,aAAc,MACd,UAAW,KACX,OAAQ,MACR,UAAW,MACX,OAAQ,IACR,UAAW,IACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,KACX,aAAc,KACd,UAAW,MACX,aAAc,MACd,UAAW,MACX,OAAQ,MACR,UAAW,MACX,OAAQ,MACR,UAAW,MACX,UAAW,MACX,aAAc,MACd,UAAW,MACX,aAAc,MACd,UAAW,MACX,aAAc,MACd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RR,EAAoBsM,EAAI,gBCAxBtM,EAAoB6N,EAAIC,SAASC,SAAWC,KAAKC,SAASC,KAK1D,IAAIC,EAAkB,CACrB,KAAM,GAaPnO,EAAoB+L,EAAEO,EAAI,SAAS8B,GAAW,OAAoC,IAA7BD,EAAgBC,IAGrE,IAAIC,EAAuB,SAASC,EAA4B/K,GAC/D,IAKI+H,EAAU8C,EALVpC,EAAWzI,EAAK,GAChBgL,EAAchL,EAAK,GACnBiL,EAAUjL,EAAK,GAGI0F,EAAI,EAC3B,GAAG+C,EAASyC,MAAK,SAAS3O,GAAM,OAA+B,IAAxBqO,EAAgBrO,MAAe,CACrE,IAAIwL,KAAYiD,EACZvO,EAAoBC,EAAEsO,EAAajD,KACrCtL,EAAoB4L,EAAEN,GAAYiD,EAAYjD,IAGhD,GAAGkD,EAAS,IAAItG,EAASsG,EAAQxO,GAGlC,IADGsO,GAA4BA,EAA2B/K,GACrD0F,EAAI+C,EAASI,OAAQnD,IACzBmF,EAAUpC,EAAS/C,GAChBjJ,EAAoBC,EAAEkO,EAAiBC,IAAYD,EAAgBC,IACrED,EAAgBC,GAAS,KAE1BD,EAAgBC,GAAW,EAE5B,OAAOpO,EAAoB+L,EAAE7D,IAG1BwG,EAAqBV,KAA4B,sBAAIA,KAA4B,uBAAK,GAC1FU,EAAmBC,QAAQN,EAAqBO,KAAK,KAAM,IAC3DF,EAAmBtD,KAAOiD,EAAqBO,KAAK,KAAMF,EAAmBtD,KAAKwD,KAAKF,OClDvF1O,EAAoB6O,QAAKrD,ECGzB,IAAIsD,EAAsB9O,EAAoB+L,OAAEP,EAAW,CAAC,OAAO,WAAa,OAAOxL,EAAoB,QAC3G8O,EAAsB9O,EAAoB+L,EAAE+C","sources":["webpack:///nextcloud/webpack/runtime/chunk loaded","webpack:///nextcloud/node_modules/@nextcloud/moment/node_modules/moment/locale|sync|/^\\.\\/.*$","webpack:///nextcloud/apps/comments/src/components/Moment.vue?vue&type=script&lang=js&","webpack:///nextcloud/apps/comments/src/components/Moment.vue","webpack://nextcloud/./apps/comments/src/components/Moment.vue?9b20","webpack:///nextcloud/apps/comments/src/components/Moment.vue?vue&type=template&id=57999be6&","webpack:///nextcloud/apps/comments/src/utils/davUtils.js","webpack:///nextcloud/apps/comments/src/services/DavClient.js","webpack:///nextcloud/apps/comments/src/services/NewComment.js","webpack:///nextcloud/apps/comments/src/services/DeleteComment.js","webpack:///nextcloud/apps/comments/src/services/EditComment.js","webpack:///nextcloud/apps/comments/src/mixins/CommentMixin.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?8b64","webpack://nextcloud/./apps/comments/src/components/Comment.vue?7f26","webpack:///nextcloud/apps/comments/src/components/Comment.vue?vue&type=template&id=4a15fc2d&scoped=true&","webpack:///nextcloud/apps/comments/src/services/GetComments.js","webpack:///nextcloud/apps/comments/src/utils/cancelableRequest.js","webpack:///nextcloud/apps/comments/src/views/Comments.vue","webpack:///nextcloud/apps/comments/src/views/Comments.vue?vue&type=script&lang=js&","webpack://nextcloud/./apps/comments/src/views/Comments.vue?c8a6","webpack://nextcloud/./apps/comments/src/views/Comments.vue?f45b","webpack:///nextcloud/apps/comments/src/views/Comments.vue?vue&type=template&id=3808dce0&scoped=true&","webpack:///nextcloud/apps/comments/src/services/CommentsInstance.js","webpack:///nextcloud/apps/comments/src/comments-app.js","webpack:///nextcloud/apps/comments/src/components/Comment.vue?vue&type=style&index=0&id=4a15fc2d&lang=scss&scoped=true&","webpack:///nextcloud/apps/comments/src/views/Comments.vue?vue&type=style&index=0&id=3808dce0&lang=scss&scoped=true&","webpack:///nextcloud/webpack/bootstrap","webpack:///nextcloud/webpack/runtime/amd define","webpack:///nextcloud/webpack/runtime/amd options","webpack:///nextcloud/webpack/runtime/compat get default export","webpack:///nextcloud/webpack/runtime/define property getters","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/jsonp chunk loading","webpack:///nextcloud/webpack/runtime/nonce","webpack:///nextcloud/webpack/startup"],"sourcesContent":["var deferred = [];\n__webpack_require__.O = function(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(function(key) { return __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 map = {\n\t\"./af\": 36026,\n\t\"./af.js\": 36026,\n\t\"./ar\": 28093,\n\t\"./ar-dz\": 41943,\n\t\"./ar-dz.js\": 41943,\n\t\"./ar-kw\": 23969,\n\t\"./ar-kw.js\": 23969,\n\t\"./ar-ly\": 40594,\n\t\"./ar-ly.js\": 40594,\n\t\"./ar-ma\": 18369,\n\t\"./ar-ma.js\": 18369,\n\t\"./ar-sa\": 32579,\n\t\"./ar-sa.js\": 32579,\n\t\"./ar-tn\": 76442,\n\t\"./ar-tn.js\": 76442,\n\t\"./ar.js\": 28093,\n\t\"./az\": 86425,\n\t\"./az.js\": 86425,\n\t\"./be\": 22004,\n\t\"./be.js\": 22004,\n\t\"./bg\": 42982,\n\t\"./bg.js\": 42982,\n\t\"./bm\": 21067,\n\t\"./bm.js\": 21067,\n\t\"./bn\": 8366,\n\t\"./bn-bd\": 63837,\n\t\"./bn-bd.js\": 63837,\n\t\"./bn.js\": 8366,\n\t\"./bo\": 95040,\n\t\"./bo.js\": 95040,\n\t\"./br\": 521,\n\t\"./br.js\": 521,\n\t\"./bs\": 83242,\n\t\"./bs.js\": 83242,\n\t\"./ca\": 73046,\n\t\"./ca.js\": 73046,\n\t\"./cs\": 25794,\n\t\"./cs.js\": 25794,\n\t\"./cv\": 28231,\n\t\"./cv.js\": 28231,\n\t\"./cy\": 10927,\n\t\"./cy.js\": 10927,\n\t\"./da\": 42832,\n\t\"./da.js\": 42832,\n\t\"./de\": 29415,\n\t\"./de-at\": 3331,\n\t\"./de-at.js\": 3331,\n\t\"./de-ch\": 45524,\n\t\"./de-ch.js\": 45524,\n\t\"./de.js\": 29415,\n\t\"./dv\": 44700,\n\t\"./dv.js\": 44700,\n\t\"./el\": 88752,\n\t\"./el.js\": 88752,\n\t\"./en-au\": 90444,\n\t\"./en-au.js\": 90444,\n\t\"./en-ca\": 65959,\n\t\"./en-ca.js\": 65959,\n\t\"./en-gb\": 62762,\n\t\"./en-gb.js\": 62762,\n\t\"./en-ie\": 40909,\n\t\"./en-ie.js\": 40909,\n\t\"./en-il\": 79909,\n\t\"./en-il.js\": 79909,\n\t\"./en-in\": 87942,\n\t\"./en-in.js\": 87942,\n\t\"./en-nz\": 75200,\n\t\"./en-nz.js\": 75200,\n\t\"./en-sg\": 21415,\n\t\"./en-sg.js\": 21415,\n\t\"./eo\": 27447,\n\t\"./eo.js\": 27447,\n\t\"./es\": 86756,\n\t\"./es-do\": 47049,\n\t\"./es-do.js\": 47049,\n\t\"./es-mx\": 15915,\n\t\"./es-mx.js\": 15915,\n\t\"./es-us\": 57133,\n\t\"./es-us.js\": 57133,\n\t\"./es.js\": 86756,\n\t\"./et\": 72182,\n\t\"./et.js\": 72182,\n\t\"./eu\": 14419,\n\t\"./eu.js\": 14419,\n\t\"./fa\": 2916,\n\t\"./fa.js\": 2916,\n\t\"./fi\": 49964,\n\t\"./fi.js\": 49964,\n\t\"./fil\": 16448,\n\t\"./fil.js\": 16448,\n\t\"./fo\": 26094,\n\t\"./fo.js\": 26094,\n\t\"./fr\": 35833,\n\t\"./fr-ca\": 56994,\n\t\"./fr-ca.js\": 56994,\n\t\"./fr-ch\": 2740,\n\t\"./fr-ch.js\": 2740,\n\t\"./fr.js\": 35833,\n\t\"./fy\": 69542,\n\t\"./fy.js\": 69542,\n\t\"./ga\": 93264,\n\t\"./ga.js\": 93264,\n\t\"./gd\": 77457,\n\t\"./gd.js\": 77457,\n\t\"./gl\": 83043,\n\t\"./gl.js\": 83043,\n\t\"./gom-deva\": 24034,\n\t\"./gom-deva.js\": 24034,\n\t\"./gom-latn\": 28379,\n\t\"./gom-latn.js\": 28379,\n\t\"./gu\": 406,\n\t\"./gu.js\": 406,\n\t\"./he\": 73219,\n\t\"./he.js\": 73219,\n\t\"./hi\": 99834,\n\t\"./hi.js\": 99834,\n\t\"./hr\": 28754,\n\t\"./hr.js\": 28754,\n\t\"./hu\": 93945,\n\t\"./hu.js\": 93945,\n\t\"./hy-am\": 81319,\n\t\"./hy-am.js\": 81319,\n\t\"./id\": 24875,\n\t\"./id.js\": 24875,\n\t\"./is\": 23724,\n\t\"./is.js\": 23724,\n\t\"./it\": 79906,\n\t\"./it-ch\": 34303,\n\t\"./it-ch.js\": 34303,\n\t\"./it.js\": 79906,\n\t\"./ja\": 77105,\n\t\"./ja.js\": 77105,\n\t\"./jv\": 15026,\n\t\"./jv.js\": 15026,\n\t\"./ka\": 67416,\n\t\"./ka.js\": 67416,\n\t\"./kk\": 79734,\n\t\"./kk.js\": 79734,\n\t\"./km\": 60757,\n\t\"./km.js\": 60757,\n\t\"./kn\": 58369,\n\t\"./kn.js\": 58369,\n\t\"./ko\": 77687,\n\t\"./ko.js\": 77687,\n\t\"./ku\": 95544,\n\t\"./ku.js\": 95544,\n\t\"./ky\": 85431,\n\t\"./ky.js\": 85431,\n\t\"./lb\": 13613,\n\t\"./lb.js\": 13613,\n\t\"./lo\": 34252,\n\t\"./lo.js\": 34252,\n\t\"./lt\": 84619,\n\t\"./lt.js\": 84619,\n\t\"./lv\": 93760,\n\t\"./lv.js\": 93760,\n\t\"./me\": 93393,\n\t\"./me.js\": 93393,\n\t\"./mi\": 12369,\n\t\"./mi.js\": 12369,\n\t\"./mk\": 48664,\n\t\"./mk.js\": 48664,\n\t\"./ml\": 23099,\n\t\"./ml.js\": 23099,\n\t\"./mn\": 98539,\n\t\"./mn.js\": 98539,\n\t\"./mr\": 778,\n\t\"./mr.js\": 778,\n\t\"./ms\": 39970,\n\t\"./ms-my\": 82625,\n\t\"./ms-my.js\": 82625,\n\t\"./ms.js\": 39970,\n\t\"./mt\": 15714,\n\t\"./mt.js\": 15714,\n\t\"./my\": 53055,\n\t\"./my.js\": 53055,\n\t\"./nb\": 73945,\n\t\"./nb.js\": 73945,\n\t\"./ne\": 63645,\n\t\"./ne.js\": 63645,\n\t\"./nl\": 4829,\n\t\"./nl-be\": 12823,\n\t\"./nl-be.js\": 12823,\n\t\"./nl.js\": 4829,\n\t\"./nn\": 23756,\n\t\"./nn.js\": 23756,\n\t\"./oc-lnc\": 41228,\n\t\"./oc-lnc.js\": 41228,\n\t\"./pa-in\": 97877,\n\t\"./pa-in.js\": 97877,\n\t\"./pl\": 53066,\n\t\"./pl.js\": 53066,\n\t\"./pt\": 28677,\n\t\"./pt-br\": 81592,\n\t\"./pt-br.js\": 81592,\n\t\"./pt.js\": 28677,\n\t\"./ro\": 32722,\n\t\"./ro.js\": 32722,\n\t\"./ru\": 59138,\n\t\"./ru.js\": 59138,\n\t\"./sd\": 32568,\n\t\"./sd.js\": 32568,\n\t\"./se\": 49753,\n\t\"./se.js\": 49753,\n\t\"./si\": 58024,\n\t\"./si.js\": 58024,\n\t\"./sk\": 31058,\n\t\"./sk.js\": 31058,\n\t\"./sl\": 43452,\n\t\"./sl.js\": 43452,\n\t\"./sq\": 2795,\n\t\"./sq.js\": 2795,\n\t\"./sr\": 26976,\n\t\"./sr-cyrl\": 38819,\n\t\"./sr-cyrl.js\": 38819,\n\t\"./sr.js\": 26976,\n\t\"./ss\": 7467,\n\t\"./ss.js\": 7467,\n\t\"./sv\": 42787,\n\t\"./sv.js\": 42787,\n\t\"./sw\": 80298,\n\t\"./sw.js\": 80298,\n\t\"./ta\": 57532,\n\t\"./ta.js\": 57532,\n\t\"./te\": 76076,\n\t\"./te.js\": 76076,\n\t\"./tet\": 40452,\n\t\"./tet.js\": 40452,\n\t\"./tg\": 64794,\n\t\"./tg.js\": 64794,\n\t\"./th\": 48245,\n\t\"./th.js\": 48245,\n\t\"./tk\": 8870,\n\t\"./tk.js\": 8870,\n\t\"./tl-ph\": 36056,\n\t\"./tl-ph.js\": 36056,\n\t\"./tlh\": 15249,\n\t\"./tlh.js\": 15249,\n\t\"./tr\": 22053,\n\t\"./tr.js\": 22053,\n\t\"./tzl\": 39871,\n\t\"./tzl.js\": 39871,\n\t\"./tzm\": 39574,\n\t\"./tzm-latn\": 19210,\n\t\"./tzm-latn.js\": 19210,\n\t\"./tzm.js\": 39574,\n\t\"./ug-cn\": 91532,\n\t\"./ug-cn.js\": 91532,\n\t\"./uk\": 11432,\n\t\"./uk.js\": 11432,\n\t\"./ur\": 88523,\n\t\"./ur.js\": 88523,\n\t\"./uz\": 54958,\n\t\"./uz-latn\": 68735,\n\t\"./uz-latn.js\": 68735,\n\t\"./uz.js\": 54958,\n\t\"./vi\": 83398,\n\t\"./vi.js\": 83398,\n\t\"./x-pseudo\": 56665,\n\t\"./x-pseudo.js\": 56665,\n\t\"./yo\": 11642,\n\t\"./yo.js\": 11642,\n\t\"./zh-cn\": 5462,\n\t\"./zh-cn.js\": 5462,\n\t\"./zh-hk\": 92530,\n\t\"./zh-hk.js\": 92530,\n\t\"./zh-mo\": 41650,\n\t\"./zh-mo.js\": 41650,\n\t\"./zh-tw\": 97333,\n\t\"./zh-tw.js\": 97333\n};\n\n\nfunction webpackContext(req) {\n\tvar id = webpackContextResolve(req);\n\treturn __webpack_require__(id);\n}\nfunction webpackContextResolve(req) {\n\tif(!__webpack_require__.o(map, req)) {\n\t\tvar e = new Error(\"Cannot find module '\" + req + \"'\");\n\t\te.code = 'MODULE_NOT_FOUND';\n\t\tthrow e;\n\t}\n\treturn map[req];\n}\nwebpackContext.keys = function webpackContextKeys() {\n\treturn Object.keys(map);\n};\nwebpackContext.resolve = webpackContextResolve;\nmodule.exports = webpackContext;\nwebpackContext.id = 93365;","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Moment.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!./Moment.vue?vue&type=script&lang=js&\"","<!-- TODO: Move to vue components -->\n\n<template>\n\t<span class=\"live-relative-timestamp\" :data-timestamp=\"timestamp * 1000\" :title=\"title\">{{ formatted }}</span>\n</template>\n\n<script>\nimport moment from '@nextcloud/moment'\n\nexport default {\n\tname: 'Moment',\n\tprops: {\n\t\ttimestamp: {\n\t\t\ttype: Number,\n\t\t\trequired: true,\n\t\t},\n\t\tformat: {\n\t\t\ttype: String,\n\t\t\tdefault: 'LLL',\n\t\t},\n\t},\n\tcomputed: {\n\t\ttitle() {\n\t\t\treturn moment.unix(this.timestamp).format(this.format)\n\t\t},\n\t\tformatted() {\n\t\t\treturn moment.unix(this.timestamp).fromNow()\n\t\t},\n\t},\n}\n</script>\n","import { render, staticRenderFns } from \"./Moment.vue?vue&type=template&id=57999be6&\"\nimport script from \"./Moment.vue?vue&type=script&lang=js&\"\nexport * from \"./Moment.vue?vue&type=script&lang=js&\"\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 null,\n null\n \n)\n\nexport default component.exports","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('span',{staticClass:\"live-relative-timestamp\",attrs:{\"data-timestamp\":_vm.timestamp * 1000,\"title\":_vm.title}},[_vm._v(_vm._s(_vm.formatted))])}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { generateRemoteUrl } from '@nextcloud/router'\n\nconst getRootPath = function() {\n\treturn generateRemoteUrl('dav/comments')\n}\n\nexport { getRootPath }\n","/**\n * @copyright Copyright (c) 2021 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { createClient, getPatcher } from 'webdav'\nimport axios from '@nextcloud/axios'\n\nimport { getRootPath } from '../utils/davUtils'\n\n// Add this so the server knows it is an request from the browser\naxios.defaults.headers['X-Requested-With'] = 'XMLHttpRequest'\n\n// force our axios\nconst patcher = getPatcher()\npatcher.patch('request', axios)\n\n// init webdav client\nconst client = createClient(getRootPath())\n\nexport default client\n","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { getCurrentUser } from '@nextcloud/auth'\nimport { getRootPath } from '../utils/davUtils'\nimport axios from '@nextcloud/axios'\nimport client from './DavClient'\n\n/**\n * Retrieve the comments list\n *\n * @param {string} commentsType the ressource type\n * @param {number} ressourceId the ressource ID\n * @param {string} message the message\n * @return {object} the new comment\n */\nexport default async function(commentsType, ressourceId, message) {\n\tconst ressourcePath = ['', commentsType, ressourceId].join('/')\n\n\tconst response = await axios.post(getRootPath() + ressourcePath, {\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: 'files',\n\t\tverb: 'comment',\n\t})\n\n\t// Retrieve comment id from ressource location\n\tconst commentId = parseInt(response.headers['content-location'].split('/').pop())\n\tconst commentPath = ressourcePath + '/' + commentId\n\n\t// Fetch newly created comment data\n\tconst comment = await client.stat(commentPath, {\n\t\tdetails: true,\n\t})\n\n\treturn comment.data\n}\n","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport client from './DavClient'\n\n/**\n * Delete a comment\n *\n * @param {string} commentsType the ressource type\n * @param {number} ressourceId the ressource ID\n * @param {number} commentId the comment iD\n */\nexport default async function(commentsType, ressourceId, commentId) {\n\tconst commentPath = ['', commentsType, ressourceId, commentId].join('/')\n\n\t// Fetch newly created comment data\n\tawait client.deleteFile(commentPath)\n}\n","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport client from './DavClient'\n\n/**\n * Edit an existing comment\n *\n * @param {string} commentsType the ressource type\n * @param {number} ressourceId the ressource ID\n * @param {number} commentId the comment iD\n * @param {string} message the message content\n */\nexport default async function(commentsType, ressourceId, commentId, message) {\n\tconst commentPath = ['', commentsType, ressourceId, commentId].join('/')\n\n\treturn await client.customRequest(commentPath, Object.assign({\n\t\tmethod: 'PROPPATCH',\n\t\tdata: `<?xml version=\"1.0\"?>\n\t\t\t<d:propertyupdate\n\t\t\t\txmlns:d=\"DAV:\"\n\t\t\t\txmlns:oc=\"http://owncloud.org/ns\">\n\t\t\t<d:set>\n\t\t\t\t<d:prop>\n\t\t\t\t\t<oc:message>${message}</oc:message>\n\t\t\t\t</d:prop>\n\t\t\t</d:set>\n\t\t\t</d:propertyupdate>`,\n\t}))\n}\n","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport NewComment from '../services/NewComment'\nimport DeleteComment from '../services/DeleteComment'\nimport EditComment from '../services/EditComment'\nimport { showError, showUndo, TOAST_UNDO_TIMEOUT } from '@nextcloud/dialogs'\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\tressourceId: {\n\t\t\ttype: [String, Number],\n\t\t\trequired: true,\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\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.commentsType, this.ressourceId, this.id, message)\n\t\t\t\tthis.logger.debug('Comment edited', { commentsType: this.commentsType, ressourceId: this.ressourceId, 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.deleted = true\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})\n\t\t},\n\t\tasync onDelete() {\n\t\t\ttry {\n\t\t\t\tawait DeleteComment(this.commentsType, this.ressourceId, this.id)\n\t\t\t\tthis.logger.debug('Comment deleted', { commentsType: this.commentsType, ressourceId: this.ressourceId, 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}\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.commentsType, this.ressourceId, message)\n\t\t\t\tthis.logger.debug('New comment posted', { commentsType: this.commentsType, ressourceId: this.ressourceId, 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","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 - @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n -\n - @author John Molakvoæ <skjnldsv@protonmail.com>\n -\n - @license GNU AGPL version 3 or any later version\n -\n - This program is free software: you can redistribute it and/or modify\n - it under the terms of the GNU Affero General Public License as\n - published by the Free Software Foundation, either version 3 of the\n - License, or (at your option) any later version.\n -\n - This program is distributed in the hope that it will be useful,\n - but WITHOUT ANY WARRANTY; without even the implied warranty of\n - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n - GNU Affero General Public License for more details.\n -\n - You should have received a copy of the GNU Affero General Public License\n - along with this program. If not, see <http://www.gnu.org/licenses/>.\n -\n -->\n<template>\n\t<div v-show=\"!deleted\"\n\t\t:class=\"{'comment--loading': loading}\"\n\t\tclass=\"comment\">\n\t\t<!-- Comment header toolbar -->\n\t\t<div class=\"comment__header\">\n\t\t\t<!-- Author -->\n\t\t\t<Avatar class=\"comment__avatar\"\n\t\t\t\t:display-name=\"actorDisplayName\"\n\t\t\t\t:user=\"actorId\"\n\t\t\t\t:size=\"32\" />\n\t\t\t<span class=\"comment__author\">{{ actorDisplayName }}</span>\n\n\t\t\t<!-- Comment actions,\n\t\t\t\tshow if we have a message id and current user is author -->\n\t\t\t<Actions v-if=\"isOwnComment && id && !loading\" class=\"comment__actions\">\n\t\t\t\t<template v-if=\"!editing\">\n\t\t\t\t\t<ActionButton :close-after-click=\"true\"\n\t\t\t\t\t\ticon=\"icon-rename\"\n\t\t\t\t\t\t@click=\"onEdit\">\n\t\t\t\t\t\t{{ t('comments', 'Edit comment') }}\n\t\t\t\t\t</ActionButton>\n\t\t\t\t\t<ActionSeparator />\n\t\t\t\t\t<ActionButton :close-after-click=\"true\"\n\t\t\t\t\t\ticon=\"icon-delete\"\n\t\t\t\t\t\t@click=\"onDeleteWithUndo\">\n\t\t\t\t\t\t{{ t('comments', 'Delete comment') }}\n\t\t\t\t\t</ActionButton>\n\t\t\t\t</template>\n\n\t\t\t\t<ActionButton v-else\n\t\t\t\t\ticon=\"icon-close\"\n\t\t\t\t\t@click=\"onEditCancel\">\n\t\t\t\t\t{{ t('comments', 'Cancel edit') }}\n\t\t\t\t</ActionButton>\n\t\t\t</Actions>\n\n\t\t\t<!-- Show loading if we're editing or deleting, not on new ones -->\n\t\t\t<div v-if=\"id && loading\" class=\"comment_loading icon-loading-small\" />\n\n\t\t\t<!-- Relative time to the comment creation -->\n\t\t\t<Moment v-else-if=\"creationDateTime\" class=\"comment__timestamp\" :timestamp=\"timestamp\" />\n\t\t</div>\n\n\t\t<!-- Message editor -->\n\t\t<div v-if=\"editor || editing\" class=\"comment__editor \">\n\t\t\t<RichContenteditable ref=\"editor\"\n\t\t\t\t:auto-complete=\"autoComplete\"\n\t\t\t\t:contenteditable=\"!loading\"\n\t\t\t\t:value=\"localMessage\"\n\t\t\t\t@update:value=\"updateLocalMessage\"\n\t\t\t\t@submit=\"onSubmit\" />\n\t\t\t<Button class=\"comment__submit\"\n\t\t\t\ttype=\"tertiary-no-background\"\n\t\t\t\tnative-type=\"submit\"\n\t\t\t\t:aria-label=\"t('comments', 'Post comment')\"\n\t\t\t\t:disabled=\"isEmptyMessage\"\n\t\t\t\t@click=\"onSubmit\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<span v-if=\"loading\" class=\"icon-loading-small\" />\n\t\t\t\t\t<ArrowRight v-else :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t</Button>\n\t\t</div>\n\n\t\t<!-- Message content -->\n\t\t<!-- The html is escaped and sanitized before rendering -->\n\t\t<!-- eslint-disable-next-line vue/no-v-html-->\n\t\t<div v-else\n\t\t\t:class=\"{'comment__message--expanded': expanded}\"\n\t\t\tclass=\"comment__message\"\n\t\t\t@click=\"onExpand\"\n\t\t\tv-html=\"renderedContent\" />\n\t</div>\n</template>\n\n<script>\nimport { getCurrentUser } from '@nextcloud/auth'\nimport moment from '@nextcloud/moment'\n\nimport ActionButton from '@nextcloud/vue/dist/Components/ActionButton'\nimport Actions from '@nextcloud/vue/dist/Components/Actions'\nimport ActionSeparator from '@nextcloud/vue/dist/Components/ActionSeparator'\nimport Avatar from '@nextcloud/vue/dist/Components/Avatar'\nimport Button from '@nextcloud/vue/dist/Components/Button'\nimport RichContenteditable from '@nextcloud/vue/dist/Components/RichContenteditable'\nimport RichEditorMixin from '@nextcloud/vue/dist/Mixins/richEditor'\nimport ArrowRight from 'vue-material-design-icons/ArrowRight'\n\nimport Moment from './Moment'\nimport CommentMixin from '../mixins/CommentMixin'\n\nexport default {\n\tname: 'Comment',\n\n\tcomponents: {\n\t\tActionButton,\n\t\tActions,\n\t\tActionSeparator,\n\t\tArrowRight,\n\t\tAvatar,\n\t\tButton,\n\t\tMoment,\n\t\tRichContenteditable,\n\t},\n\tmixins: [RichEditorMixin, CommentMixin],\n\n\tinheritAttrs: false,\n\n\tprops: {\n\t\tactorDisplayName: {\n\t\t\ttype: String,\n\t\t\trequired: true,\n\t\t},\n\t\tactorId: {\n\t\t\ttype: String,\n\t\t\trequired: true,\n\t\t},\n\t\tcreationDateTime: {\n\t\t\ttype: String,\n\t\t\tdefault: null,\n\t\t},\n\n\t\t/**\n\t\t * Force the editor display\n\t\t */\n\t\teditor: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: false,\n\t\t},\n\n\t\t/**\n\t\t * Provide the autocompletion data\n\t\t */\n\t\tautoComplete: {\n\t\t\ttype: Function,\n\t\t\trequired: true,\n\t\t},\n\t},\n\n\tdata() {\n\t\treturn {\n\t\t\texpanded: false,\n\t\t\t// Only change data locally and update the original\n\t\t\t// parent data when the request is sent and resolved\n\t\t\tlocalMessage: '',\n\t\t}\n\t},\n\n\tcomputed: {\n\n\t\t/**\n\t\t * Is the current user the author of this comment\n\t\t *\n\t\t * @return {boolean}\n\t\t */\n\t\tisOwnComment() {\n\t\t\treturn getCurrentUser().uid === this.actorId\n\t\t},\n\n\t\t/**\n\t\t * Rendered content as html string\n\t\t *\n\t\t * @return {string}\n\t\t */\n\t\trenderedContent() {\n\t\t\tif (this.isEmptyMessage) {\n\t\t\t\treturn ''\n\t\t\t}\n\t\t\treturn this.renderContent(this.localMessage)\n\t\t},\n\n\t\tisEmptyMessage() {\n\t\t\treturn !this.localMessage || this.localMessage.trim() === ''\n\t\t},\n\n\t\ttimestamp() {\n\t\t\t// seconds, not milliseconds\n\t\t\treturn parseInt(moment(this.creationDateTime).format('x'), 10) / 1000\n\t\t},\n\t},\n\n\twatch: {\n\t\t// If the data change, update the local value\n\t\tmessage(message) {\n\t\t\tthis.updateLocalMessage(message)\n\t\t},\n\t},\n\n\tbeforeMount() {\n\t\t// Init localMessage\n\t\tthis.updateLocalMessage(this.message)\n\t},\n\n\tmethods: {\n\t\t/**\n\t\t * Update local Message on outer change\n\t\t *\n\t\t * @param {string} message the message to set\n\t\t */\n\t\tupdateLocalMessage(message) {\n\t\t\tthis.localMessage = message.toString()\n\t\t},\n\n\t\t/**\n\t\t * Dispatch message between edit and create\n\t\t */\n\t\tonSubmit() {\n\t\t\t// Do not submit if message is empty\n\t\t\tif (this.localMessage.trim() === '') {\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tif (this.editor) {\n\t\t\t\tthis.onNewComment(this.localMessage.trim())\n\t\t\t\tthis.$nextTick(() => {\n\t\t\t\t\t// Focus the editor again\n\t\t\t\t\tthis.$refs.editor.$el.focus()\n\t\t\t\t})\n\t\t\t\treturn\n\t\t\t}\n\t\t\tthis.onEditComment(this.localMessage.trim())\n\t\t},\n\n\t\tonExpand() {\n\t\t\tthis.expanded = true\n\t\t},\n\t},\n\n}\n</script>\n\n<style lang=\"scss\" scoped>\n@use \"sass:math\";\n\n$comment-padding: 10px;\n\n.comment {\n\tposition: relative;\n\tpadding: $comment-padding 0 $comment-padding * 1.5;\n\n\t&__header {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t\tmin-height: 44px;\n\t\tpadding: math.div($comment-padding, 2) 0;\n\t}\n\n\t&__author,\n\t&__actions {\n\t\tmargin-left: $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-left: auto;\n\t\tcolor: var(--color-text-maxcontrast);\n\t}\n\n\t&__editor,\n\t&__message {\n\t\tposition: relative;\n\t\t// Avatar size, align with author name\n\t\tpadding-left: 32px + $comment-padding;\n\t}\n\n\t&__submit {\n\t\tposition: absolute !important;\n\t\tright: 0;\n\t\tbottom: 0;\n\t\t// Align with input border\n\t\tmargin: 1px;\n\t}\n\n\t&__message {\n\t\twhite-space: pre-wrap;\n\t\tword-break: break-word;\n\t\tmax-height: 70px;\n\t\toverflow: hidden;\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</style>\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=4a15fc2d&lang=scss&scoped=true&\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\n\n options.insert = insertFn.bind(null, \"head\");\n \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=4a15fc2d&lang=scss&scoped=true&\";\n export default content && content.locals ? content.locals : undefined;\n","import { render, staticRenderFns } from \"./Comment.vue?vue&type=template&id=4a15fc2d&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=4a15fc2d&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 \"4a15fc2d\",\n null\n \n)\n\nexport default component.exports","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{directives:[{name:\"show\",rawName:\"v-show\",value:(!_vm.deleted),expression:\"!deleted\"}],staticClass:\"comment\",class:{'comment--loading': _vm.loading}},[_c('div',{staticClass:\"comment__header\"},[_c('Avatar',{staticClass:\"comment__avatar\",attrs:{\"display-name\":_vm.actorDisplayName,\"user\":_vm.actorId,\"size\":32}}),_vm._v(\" \"),_c('span',{staticClass:\"comment__author\"},[_vm._v(_vm._s(_vm.actorDisplayName))]),_vm._v(\" \"),(_vm.isOwnComment && _vm.id && !_vm.loading)?_c('Actions',{staticClass:\"comment__actions\"},[(!_vm.editing)?[_c('ActionButton',{attrs:{\"close-after-click\":true,\"icon\":\"icon-rename\"},on:{\"click\":_vm.onEdit}},[_vm._v(\"\\n\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Edit comment'))+\"\\n\\t\\t\\t\\t\")]),_vm._v(\" \"),_c('ActionSeparator'),_vm._v(\" \"),_c('ActionButton',{attrs:{\"close-after-click\":true,\"icon\":\"icon-delete\"},on:{\"click\":_vm.onDeleteWithUndo}},[_vm._v(\"\\n\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Delete comment'))+\"\\n\\t\\t\\t\\t\")])]:_c('ActionButton',{attrs:{\"icon\":\"icon-close\"},on:{\"click\":_vm.onEditCancel}},[_vm._v(\"\\n\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Cancel edit'))+\"\\n\\t\\t\\t\")])],2):_vm._e(),_vm._v(\" \"),(_vm.id && _vm.loading)?_c('div',{staticClass:\"comment_loading icon-loading-small\"}):(_vm.creationDateTime)?_c('Moment',{staticClass:\"comment__timestamp\",attrs:{\"timestamp\":_vm.timestamp}}):_vm._e()],1),_vm._v(\" \"),(_vm.editor || _vm.editing)?_c('div',{staticClass:\"comment__editor \"},[_c('RichContenteditable',{ref:\"editor\",attrs:{\"auto-complete\":_vm.autoComplete,\"contenteditable\":!_vm.loading,\"value\":_vm.localMessage},on:{\"update:value\":_vm.updateLocalMessage,\"submit\":_vm.onSubmit}}),_vm._v(\" \"),_c('Button',{staticClass:\"comment__submit\",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('span',{staticClass:\"icon-loading-small\"}):_c('ArrowRight',{attrs:{\"size\":20}})]},proxy:true}],null,false,2357784758)})],1):_c('div',{staticClass:\"comment__message\",class:{'comment__message--expanded': _vm.expanded},domProps:{\"innerHTML\":_vm._s(_vm.renderedContent)},on:{\"click\":_vm.onExpand}})])}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { parseXML, prepareFileFromProps } from 'webdav/dist/node/tools/dav'\nimport { processResponsePayload } from 'webdav/dist/node/response'\nimport client from './DavClient'\n\nexport const DEFAULT_LIMIT = 20\n/**\n * Retrieve the comments list\n *\n * @param {object} data destructuring object\n * @param {string} data.commentsType the ressource type\n * @param {number} data.ressourceId the ressource ID\n * @param {object} [options] optional options for axios\n * @return {object[]} the comments list\n */\nexport default async function({ commentsType, ressourceId }, options = {}) {\n\tlet response = null\n\tconst ressourcePath = ['', commentsType, ressourceId].join('/')\n\n\treturn await client.customRequest(ressourcePath, Object.assign({\n\t\tmethod: 'REPORT',\n\t\tdata: `<?xml version=\"1.0\"?>\n\t\t\t<oc:filter-comments\n\t\t\t\txmlns:d=\"DAV:\"\n\t\t\t\txmlns:oc=\"http://owncloud.org/ns\"\n\t\t\t\txmlns:nc=\"http://nextcloud.org/ns\"\n\t\t\t\txmlns:ocs=\"http://open-collaboration-services.org/ns\">\n\t\t\t\t<oc:limit>${DEFAULT_LIMIT}</oc:limit>\n\t\t\t\t<oc:offset>${options.offset || 0}</oc:offset>\n\t\t\t</oc:filter-comments>`,\n\t}, options))\n\t\t// See example on how it's done normaly\n\t\t// https://github.com/perry-mitchell/webdav-client/blob/9de2da4a2599e06bd86c2778145b7ade39fe0b3c/source/interface/stat.js#L19\n\t\t// Waiting for proper REPORT integration https://github.com/perry-mitchell/webdav-client/issues/207\n\t\t.then(res => {\n\t\t\tresponse = res\n\t\t\treturn res.data\n\t\t})\n\t\t.then(parseXML)\n\t\t.then(xml => processMultistatus(xml, true))\n\t\t.then(comments => processResponsePayload(response, comments, true))\n\t\t.then(response => response.data)\n}\n\n// https://github.com/perry-mitchell/webdav-client/blob/9de2da4a2599e06bd86c2778145b7ade39fe0b3c/source/interface/directoryContents.js#L32\n/**\n * @param {any} result -\n * @param {any} isDetailed -\n */\nfunction processMultistatus(result, isDetailed = false) {\n\t// Extract the response items (directory contents)\n\tconst {\n\t\tmultistatus: { response: responseItems },\n\t} = result\n\treturn responseItems.map(item => {\n\t\t// Each item should contain a stat object\n\t\tconst {\n\t\t\tpropstat: { prop: props },\n\t\t} = item\n\t\t// Decode HTML entities\n\t\tconst decodedProps = {\n\t\t\t...props,\n\t\t\t// Decode twice to handle potentially double-encoded entities\n\t\t\t// FIXME Remove this once https://github.com/nextcloud/server/issues/29306 is resolved\n\t\t\tactorDisplayName: decodeHtmlEntities(props.actorDisplayName, 2),\n\t\t\tmessage: decodeHtmlEntities(props.message, 2),\n\t\t}\n\t\treturn prepareFileFromProps(decodedProps, decodedProps.id.toString(), isDetailed)\n\t})\n}\n\n/**\n * @param {any} value -\n * @param {any} passes -\n */\nfunction 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 * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport axios from '@nextcloud/axios'\n\n/**\n * Create a cancel token\n *\n * @return {import('axios').CancelTokenSource}\n */\nconst createCancelToken = () => axios.CancelToken.source()\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\t/**\n\t * Generate an axios cancel token\n\t */\n\tconst cancelToken = createCancelToken()\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\treturn request(\n\t\t\turl,\n\t\t\tObject.assign({ cancelToken: cancelToken.token }, options)\n\t\t)\n\t}\n\n\treturn {\n\t\trequest: fetch,\n\t\tcancel: cancelToken.cancel,\n\t}\n}\n\nexport default cancelableRequest\n","<!--\n - @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n -\n - @author John Molakvoæ <skjnldsv@protonmail.com>\n -\n - @license GNU AGPL version 3 or any later version\n -\n - This program is free software: you can redistribute it and/or modify\n - it under the terms of the GNU Affero General Public License as\n - published by the Free Software Foundation, either version 3 of the\n - License, or (at your option) any later version.\n -\n - This program is distributed in the hope that it will be useful,\n - but WITHOUT ANY WARRANTY; without even the implied warranty of\n - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n - GNU Affero General Public License for more details.\n -\n - You should have received a copy of the GNU Affero General Public License\n - along with this program. If not, see <http://www.gnu.org/licenses/>.\n -\n -->\n\n<template>\n\t<div class=\"comments\" :class=\"{ 'icon-loading': isFirstLoading }\">\n\t\t<!-- Editor -->\n\t\t<Comment v-bind=\"editorData\"\n\t\t\t:auto-complete=\"autoComplete\"\n\t\t\t:editor=\"true\"\n\t\t\t:ressource-id=\"ressourceId\"\n\t\t\tclass=\"comments__writer\"\n\t\t\t@new=\"onNewComment\" />\n\n\t\t<template v-if=\"!isFirstLoading\">\n\t\t\t<EmptyContent v-if=\"!hasComments && done\" icon=\"icon-comment\">\n\t\t\t\t{{ t('comments', 'No comments yet, start the conversation!') }}\n\t\t\t</EmptyContent>\n\n\t\t\t<!-- Comments -->\n\t\t\t<Comment v-for=\"comment in comments\"\n\t\t\t\tv-else\n\t\t\t\t:key=\"comment.props.id\"\n\t\t\t\tv-bind=\"comment.props\"\n\t\t\t\t:auto-complete=\"autoComplete\"\n\t\t\t\t:message.sync=\"comment.props.message\"\n\t\t\t\t:ressource-id=\"ressourceId\"\n\t\t\t\t:user-data=\"genMentionsData(comment.props.mentions)\"\n\t\t\t\tclass=\"comments__list\"\n\t\t\t\t@delete=\"onDelete\" />\n\n\t\t\t<!-- Loading more message -->\n\t\t\t<div v-if=\"loading && !isFirstLoading\" class=\"comments__info icon-loading\" />\n\n\t\t\t<div v-else-if=\"hasComments && done\" class=\"comments__info\">\n\t\t\t\t{{ t('comments', 'No more messages') }}\n\t\t\t</div>\n\n\t\t\t<!-- Error message -->\n\t\t\t<EmptyContent v-else-if=\"error\" class=\"comments__error\" icon=\"icon-error\">\n\t\t\t\t{{ error }}\n\t\t\t\t<template #desc>\n\t\t\t\t\t<button icon=\"icon-history\" @click=\"getComments\">\n\t\t\t\t\t\t{{ t('comments', 'Retry') }}\n\t\t\t\t\t</button>\n\t\t\t\t</template>\n\t\t\t</EmptyContent>\n\t\t</template>\n\t</div>\n</template>\n\n<script>\nimport { generateOcsUrl } from '@nextcloud/router'\nimport { getCurrentUser } from '@nextcloud/auth'\nimport { loadState } from '@nextcloud/initial-state'\nimport axios from '@nextcloud/axios'\nimport VTooltip from 'v-tooltip'\nimport Vue from 'vue'\n\nimport EmptyContent from '@nextcloud/vue/dist/Components/EmptyContent'\n\nimport Comment from '../components/Comment'\nimport getComments, { DEFAULT_LIMIT } from '../services/GetComments'\nimport cancelableRequest from '../utils/cancelableRequest'\n\nVue.use(VTooltip)\n\nexport default {\n\tname: 'Comments',\n\n\tcomponents: {\n\t\t// Avatar,\n\t\tComment,\n\t\tEmptyContent,\n\t},\n\n\tdata() {\n\t\treturn {\n\t\t\terror: '',\n\t\t\tloading: false,\n\t\t\tdone: false,\n\n\t\t\tressourceId: null,\n\t\t\toffset: 0,\n\t\t\tcomments: [],\n\n\t\t\tcancelRequest: () => {},\n\n\t\t\teditorData: {\n\t\t\t\tactorDisplayName: getCurrentUser().displayName,\n\t\t\t\tactorId: getCurrentUser().uid,\n\t\t\t\tkey: 'editor',\n\t\t\t},\n\n\t\t\tComment,\n\t\t}\n\t},\n\n\tcomputed: {\n\t\thasComments() {\n\t\t\treturn this.comments.length > 0\n\t\t},\n\t\tisFirstLoading() {\n\t\t\treturn this.loading && this.offset === 0\n\t\t},\n\t},\n\n\tmethods: {\n\t\t/**\n\t\t * Update current ressourceId and fetch new data\n\t\t *\n\t\t * @param {number} ressourceId the current ressourceId (fileId...)\n\t\t */\n\t\tasync update(ressourceId) {\n\t\t\tthis.ressourceId = ressourceId\n\t\t\tthis.resetState()\n\t\t\tthis.getComments()\n\t\t},\n\n\t\t/**\n\t\t * Ran when the bottom of the tab is reached\n\t\t */\n\t\tonScrollBottomReached() {\n\t\t\t/**\n\t\t\t * Do not fetch more if we:\n\t\t\t * - are showing an error\n\t\t\t * - already fetched everything\n\t\t\t * - are currently loading\n\t\t\t */\n\t\t\tif (this.error || this.done || this.loading) {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tthis.getComments()\n\t\t},\n\n\t\t/**\n\t\t * Make sure we have all mentions as Array of objects\n\t\t *\n\t\t * @param {Array} mentions the mentions list\n\t\t * @return {object[]}\n\t\t */\n\t\tgenMentionsData(mentions) {\n\t\t\tconst list = Object.values(mentions).flat()\n\t\t\treturn list.reduce((mentions, mention) => {\n\t\t\t\tmentions[mention.mentionId] = {\n\t\t\t\t\t// TODO: support groups\n\t\t\t\t\ticon: 'icon-user',\n\t\t\t\t\tid: mention.mentionId,\n\t\t\t\t\tlabel: mention.mentionDisplayName,\n\t\t\t\t\tsource: 'users',\n\t\t\t\t\tprimary: getCurrentUser().uid === mention.mentionId,\n\t\t\t\t}\n\t\t\t\treturn mentions\n\t\t\t}, {})\n\t\t},\n\n\t\t/**\n\t\t * Get the existing shares infos\n\t\t */\n\t\tasync getComments() {\n\t\t\t// Cancel any ongoing request\n\t\t\tthis.cancelRequest('cancel')\n\n\t\t\ttry {\n\t\t\t\tthis.loading = true\n\t\t\t\tthis.error = ''\n\n\t\t\t\t// Init cancellable request\n\t\t\t\tconst { request, cancel } = cancelableRequest(getComments)\n\t\t\t\tthis.cancelRequest = cancel\n\n\t\t\t\t// Fetch comments\n\t\t\t\tconst comments = await request({\n\t\t\t\t\tcommentsType: this.commentsType,\n\t\t\t\t\tressourceId: this.ressourceId,\n\t\t\t\t}, { offset: this.offset })\n\n\t\t\t\tthis.logger.debug(`Processed ${comments.length} comments`, { comments })\n\n\t\t\t\t// We received less than the requested amount,\n\t\t\t\t// we're done fetching comments\n\t\t\t\tif (comments.length < DEFAULT_LIMIT) {\n\t\t\t\t\tthis.done = true\n\t\t\t\t}\n\n\t\t\t\t// Insert results\n\t\t\t\tthis.comments.push(...comments)\n\n\t\t\t\t// Increase offset for next fetch\n\t\t\t\tthis.offset += DEFAULT_LIMIT\n\t\t\t} catch (error) {\n\t\t\t\tif (error.message === 'cancel') {\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tthis.error = t('comments', 'Unable to load the comments list')\n\t\t\t\tconsole.error('Error loading the comments list', error)\n\t\t\t} finally {\n\t\t\t\tthis.loading = false\n\t\t\t}\n\t\t},\n\n\t\t/**\n\t\t * Autocomplete @mentions\n\t\t *\n\t\t * @param {string} search the query\n\t\t * @param {Function} callback the callback to process the results with\n\t\t */\n\t\tasync autoComplete(search, callback) {\n\t\t\tconst results = await axios.get(generateOcsUrl('core/autocomplete/get'), {\n\t\t\t\tparams: {\n\t\t\t\t\tsearch,\n\t\t\t\t\titemType: 'files',\n\t\t\t\t\titemId: this.ressourceId,\n\t\t\t\t\tsorter: 'commenters|share-recipients',\n\t\t\t\t\tlimit: loadState('comments', 'maxAutoCompleteResults'),\n\t\t\t\t},\n\t\t\t})\n\t\t\treturn callback(results.data.ocs.data)\n\t\t},\n\n\t\t/**\n\t\t * Add newly created comment to the list\n\t\t *\n\t\t * @param {object} comment the new comment\n\t\t */\n\t\tonNewComment(comment) {\n\t\t\tthis.comments.unshift(comment)\n\t\t},\n\n\t\t/**\n\t\t * Remove deleted comment from the list\n\t\t *\n\t\t * @param {number} id the deleted comment\n\t\t */\n\t\tonDelete(id) {\n\t\t\tconst index = this.comments.findIndex(comment => comment.props.id === id)\n\t\t\tif (index > -1) {\n\t\t\t\tthis.comments.splice(index, 1)\n\t\t\t} else {\n\t\t\t\tconsole.error('Could not find the deleted comment in the list', id)\n\t\t\t}\n\t\t},\n\n\t\t/**\n\t\t * Reset the current view to its default state\n\t\t */\n\t\tresetState() {\n\t\t\tthis.error = ''\n\t\t\tthis.loading = false\n\t\t\tthis.done = false\n\t\t\tthis.offset = 0\n\t\t\tthis.comments = []\n\t\t},\n\t},\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.comments {\n\t// Do not add emptycontent top margin\n\t&__error{\n\t\tmargin-top: 0;\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</style>\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 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=3808dce0&lang=scss&scoped=true&\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\n\n options.insert = insertFn.bind(null, \"head\");\n \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=3808dce0&lang=scss&scoped=true&\";\n export default content && content.locals ? content.locals : undefined;\n","import { render, staticRenderFns } from \"./Comments.vue?vue&type=template&id=3808dce0&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=3808dce0&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 \"3808dce0\",\n null\n \n)\n\nexport default component.exports","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"comments\",class:{ 'icon-loading': _vm.isFirstLoading }},[_c('Comment',_vm._b({staticClass:\"comments__writer\",attrs:{\"auto-complete\":_vm.autoComplete,\"editor\":true,\"ressource-id\":_vm.ressourceId},on:{\"new\":_vm.onNewComment}},'Comment',_vm.editorData,false)),_vm._v(\" \"),(!_vm.isFirstLoading)?[(!_vm.hasComments && _vm.done)?_c('EmptyContent',{attrs:{\"icon\":\"icon-comment\"}},[_vm._v(\"\\n\\t\\t\\t\"+_vm._s(_vm.t('comments', 'No comments yet, start the conversation!'))+\"\\n\\t\\t\")]):_vm._l((_vm.comments),function(comment){return _c('Comment',_vm._b({key:comment.props.id,staticClass:\"comments__list\",attrs:{\"auto-complete\":_vm.autoComplete,\"message\":comment.props.message,\"ressource-id\":_vm.ressourceId,\"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))}),_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('EmptyContent',{staticClass:\"comments__error\",attrs:{\"icon\":\"icon-error\"},scopedSlots:_vm._u([{key:\"desc\",fn:function(){return [_c('button',{attrs:{\"icon\":\"icon-history\"},on:{\"click\":_vm.getComments}},[_vm._v(\"\\n\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('comments', 'Retry'))+\"\\n\\t\\t\\t\\t\")])]},proxy:true}],null,false,1182580137)},[_vm._v(\"\\n\\t\\t\\t\"+_vm._s(_vm.error)+\"\\n\\t\\t\\t\")]):_vm._e()]:_vm._e()],2)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","/**\n * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { getLoggerBuilder } from '@nextcloud/logger'\nimport { translate as t, translatePlural as n } from '@nextcloud/l10n'\nimport CommentsApp from '../views/Comments'\nimport Vue from 'vue'\n\nconst logger = getLoggerBuilder()\n\t.setApp('comments')\n\t.detectUser()\n\t.build()\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} commentsType the comments endpoint type\n\t * @param {object} options the vue options (propsData, parent, el...)\n\t */\n\tconstructor(commentsType = 'files', options) {\n\t\t// Add comments type as a global mixin\n\t\tVue.mixin({\n\t\t\tdata() {\n\t\t\t\treturn {\n\t\t\t\t\tcommentsType,\n\t\t\t\t}\n\t\t\t},\n\t\t})\n\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 * @copyright Copyright (c) 2020 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport CommentsInstance from './services/CommentsInstance'\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","// 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-4a15fc2d]{position:relative;padding:10px 0 15px}.comment__header[data-v-4a15fc2d]{display:flex;align-items:center;min-height:44px;padding:5px 0}.comment__author[data-v-4a15fc2d],.comment__actions[data-v-4a15fc2d]{margin-left:10px !important}.comment__author[data-v-4a15fc2d]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:var(--color-text-maxcontrast)}.comment_loading[data-v-4a15fc2d],.comment__timestamp[data-v-4a15fc2d]{margin-left:auto;color:var(--color-text-maxcontrast)}.comment__editor[data-v-4a15fc2d],.comment__message[data-v-4a15fc2d]{position:relative;padding-left:42px}.comment__submit[data-v-4a15fc2d]{position:absolute !important;right:0;bottom:0;margin:1px}.comment__message[data-v-4a15fc2d]{white-space:pre-wrap;word-break:break-word;max-height:70px;overflow:hidden}.comment__message--expanded[data-v-4a15fc2d]{max-height:none;overflow:visible}.rich-contenteditable__input[data-v-4a15fc2d]{min-height:44px;margin:0;padding:10px}\", \"\",{\"version\":3,\"sources\":[\"webpack://./apps/comments/src/components/Comment.vue\"],\"names\":[],\"mappings\":\"AAkQA,0BACC,iBAAA,CACA,mBAAA,CAEA,kCACC,YAAA,CACA,kBAAA,CACA,eAAA,CACA,aAAA,CAGD,qEAEC,2BAAA,CAGD,kCACC,eAAA,CACA,kBAAA,CACA,sBAAA,CACA,mCAAA,CAGD,uEAEC,gBAAA,CACA,mCAAA,CAGD,qEAEC,iBAAA,CAEA,iBAAA,CAGD,kCACC,4BAAA,CACA,OAAA,CACA,QAAA,CAEA,UAAA,CAGD,mCACC,oBAAA,CACA,qBAAA,CACA,eAAA,CACA,eAAA,CACA,6CACC,eAAA,CACA,gBAAA,CAKH,8CACC,eAAA,CACA,QAAA,CACA,YA7DiB\",\"sourcesContent\":[\"\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n@use \\\"sass:math\\\";\\n\\n$comment-padding: 10px;\\n\\n.comment {\\n\\tposition: relative;\\n\\tpadding: $comment-padding 0 $comment-padding * 1.5;\\n\\n\\t&__header {\\n\\t\\tdisplay: flex;\\n\\t\\talign-items: center;\\n\\t\\tmin-height: 44px;\\n\\t\\tpadding: math.div($comment-padding, 2) 0;\\n\\t}\\n\\n\\t&__author,\\n\\t&__actions {\\n\\t\\tmargin-left: $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-left: auto;\\n\\t\\tcolor: var(--color-text-maxcontrast);\\n\\t}\\n\\n\\t&__editor,\\n\\t&__message {\\n\\t\\tposition: relative;\\n\\t\\t// Avatar size, align with author name\\n\\t\\tpadding-left: 32px + $comment-padding;\\n\\t}\\n\\n\\t&__submit {\\n\\t\\tposition: absolute !important;\\n\\t\\tright: 0;\\n\\t\\tbottom: 0;\\n\\t\\t// Align with input border\\n\\t\\tmargin: 1px;\\n\\t}\\n\\n\\t&__message {\\n\\t\\twhite-space: pre-wrap;\\n\\t\\tword-break: break-word;\\n\\t\\tmax-height: 70px;\\n\\t\\toverflow: hidden;\\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__error[data-v-3808dce0]{margin-top:0}.comments__info[data-v-3808dce0]{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\":\"AAsRC,kCACC,YAAA,CAGD,iCACC,WAAA,CACA,mCAAA,CACA,iBAAA,CACA,gBAAA\",\"sourcesContent\":[\"\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n\\n.comments {\\n\\t// Do not add emptycontent top margin\\n\\t&__error{\\n\\t\\tmargin-top: 0;\\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","// 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","__webpack_require__.amdD = function () {\n\tthrow new Error('define cannot be used indirect');\n};","__webpack_require__.amdO = {};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(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__.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 = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(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 = function(module) {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","__webpack_require__.j = 6335;","__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\t6335: 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = function(chunkId) { return installedChunks[chunkId] === 0; };\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = function(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(function(id) { return 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, [7874], function() { return __webpack_require__(404); })\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n"],"names":["deferred","map","webpackContext","req","id","webpackContextResolve","__webpack_require__","o","e","Error","code","keys","Object","resolve","module","exports","_vm","this","_h","$createElement","_self","_c","staticClass","attrs","timestamp","title","_v","_s","formatted","getRootPath","generateRemoteUrl","axios","getPatcher","patch","createClient","commentsType","ressourceId","message","ressourcePath","join","actorDisplayName","getCurrentUser","displayName","actorId","uid","actorType","creationDateTime","Date","toUTCString","objectType","verb","response","commentId","parseInt","headers","split","pop","commentPath","client","details","comment","data","assign","method","props","type","Number","default","String","required","deleted","editing","loading","methods","onEdit","onEditCancel","updateLocalMessage","onEditComment","EditComment","logger","debug","$emit","showError","t","console","error","onDeleteWithUndo","timeOutDelete","setTimeout","onDelete","TOAST_UNDO_TIMEOUT","showUndo","clearTimeout","DeleteComment","onNewComment","NewComment","newComment","localMessage","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","directives","name","rawName","value","expression","class","isOwnComment","on","_e","editor","ref","autoComplete","onSubmit","isEmptyMessage","scopedSlots","_u","key","fn","proxy","expanded","domProps","renderedContent","onExpand","DEFAULT_LIMIT","offset","then","res","parseXML","xml","processMultistatus","comments","processResponsePayload","result","isDetailed","responseItems","multistatus","item","propstat","prop","decodedProps","decodeHtmlEntities","prepareFileFromProps","toString","passes","parser","DOMParser","decoded","i","parseFromString","documentElement","textContent","request","cancelToken","fetch","url","token","cancel","isFirstLoading","_b","editorData","hasComments","done","_l","genMentionsData","mentions","$event","$set","getComments","getLoggerBuilder","setApp","detectUser","build","Vue","n","CommentInstance","View","CommentsApp","window","OCA","Comments","CommentsInstance","___CSS_LOADER_EXPORT___","push","__webpack_module_cache__","moduleId","cachedModule","undefined","loaded","__webpack_modules__","call","m","amdD","amdO","O","chunkIds","priority","notFulfilled","Infinity","length","fulfilled","j","every","splice","r","getter","__esModule","d","a","definition","defineProperty","enumerable","get","g","globalThis","Function","obj","prototype","hasOwnProperty","Symbol","toStringTag","nmd","paths","children","b","document","baseURI","self","location","href","installedChunks","chunkId","webpackJsonpCallback","parentChunkLoadingFunction","moreModules","runtime","some","chunkLoadingGlobal","forEach","bind","nc","__webpack_exports__"],"sourceRoot":""} \ No newline at end of file