From 034104a0275655e89d8c2a3df939478ab9256aa8 Mon Sep 17 00:00:00 2001 From: Maurice Renck Date: Fri, 29 Oct 2021 19:22:07 +0200 Subject: [PATCH] fix: panel view with header --- composer.json | 2 +- index.js | 2 +- package.json | 50 ++++++++++++------------ src/components/views/Komments.vue | 64 ++++++++++++++++--------------- vendor/composer/installed.php | 8 ++-- 5 files changed, 64 insertions(+), 62 deletions(-) diff --git a/composer.json b/composer.json index 4e256e3..11e12b0 100644 --- a/composer.json +++ b/composer.json @@ -1,6 +1,6 @@ { "name": "mauricerenck/komments", - "version": "1.0.0", + "version": "1.0.1", "description": "A comment and webmention plugin for Kirby 3", "type": "kirby-plugin", "license": "MIT", diff --git a/index.js b/index.js index 341adbc..b11be5f 100644 --- a/index.js +++ b/index.js @@ -1 +1 @@ -(function () {function wb(a){return a&&a.__esModule?{d:a.default}:{d:a}}var na={data:function(){return{komments:[]}},created:function(){this.load()},methods:{load:function(){var t=this;this.$api.get("komments/queued").then(function(e){t.komments=e})}}};if(typeof na==="function"){na=na.options}Object.assign(na,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("div",{staticClass:"k-komments"},[_c("k-list",{attrs:{"data-size":"medium"}},_vm._l(_vm.komments,function(komment){return _c("k-list-item",{key:komment.title,attrs:{"link":komment.url+"#komments","info":""+komment.author,"text":komment.title+" - "+komment.komment,"image":{ratio:"1/1",cover:true,back:"pattern",url:komment.image},"target":"_self"}})}),1)],1)};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var oa={data:function(){return{komments:[]}},created:function(){this.load()},methods:{load:function(){var t=this;this.$api.get("komments/spam").then(function(e){t.komments=e})}}};if(typeof oa==="function"){oa=oa.options}Object.assign(oa,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("div",{staticClass:"k-spam-komments"},[_c("k-list",{attrs:{"data-size":"medium"}},_vm._l(_vm.komments,function(komment){return _c("k-list-item",{key:komment.title,attrs:{"link":komment.url+"#komments","info":""+komment.author,"text":komment.title+" - "+komment.komment,"image":{ratio:"1/1",cover:true,back:"pattern",url:komment.image},"target":"_self"}})}),1)],1)};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var ga={},xb="2.0.0",yb=256,zb=Number.MAX_SAFE_INTEGER||9007199254740991,Ab=16;ga={SEMVER_SPEC_VERSION:xb,MAX_LENGTH:yb,MAX_SAFE_INTEGER:zb,MAX_SAFE_COMPONENT_LENGTH:Ab};var Z,_,Da={},D=Da={};function Ea(){throw new Error("setTimeout has not been defined")}function Fa(){throw new Error("clearTimeout has not been defined")}function Ra($){if(Z===setTimeout)return setTimeout($,0);if((Z===Ea||!Z)&&setTimeout)return Z=setTimeout,setTimeout($,0);try{return Z($,0)}catch(e){try{return Z.call(null,$,0)}catch(e){return Z.call(this,$,0)}}}function Bb($){if(_===clearTimeout)return clearTimeout($);if((_===Fa||!_)&&clearTimeout)return _=clearTimeout,clearTimeout($);try{return _($)}catch(e){try{return _.call(null,$)}catch(e){return _.call(this,$)}}}!function(){try{Z="function"==typeof setTimeout?setTimeout:Ea}catch($){Z=Ea}try{_="function"==typeof clearTimeout?clearTimeout:Fa}catch($){_=Fa}}();var ha,T=[],Ga=!1,Sa=-1;function Cb(){Ga&&ha&&(Ga=!1,ha.length?T=ha.concat(T):Sa=-1,T.length&&Ta())}function Ta(){if(!Ga){var $=Ra(Cb);Ga=!0;for(var e=T.length;e;){for(ha=T,T=[];++Sa1)for(var r=1;r)?=?)"),z("XRANGEIDENTIFIERLOOSE","".concat(k[x.NUMERICIDENTIFIERLOOSE],"|x|X|\\*")),z("XRANGEIDENTIFIER","".concat(k[x.NUMERICIDENTIFIER],"|x|X|\\*")),z("XRANGEPLAIN","[v=\\s]*(".concat(k[x.XRANGEIDENTIFIER],")")+"(?:\\.(".concat(k[x.XRANGEIDENTIFIER],")")+"(?:\\.(".concat(k[x.XRANGEIDENTIFIER],")")+"(?:".concat(k[x.PRERELEASE],")?").concat(k[x.BUILD],"?")+")?)?"),z("XRANGEPLAINLOOSE","[v=\\s]*(".concat(k[x.XRANGEIDENTIFIERLOOSE],")")+"(?:\\.(".concat(k[x.XRANGEIDENTIFIERLOOSE],")")+"(?:\\.(".concat(k[x.XRANGEIDENTIFIERLOOSE],")")+"(?:".concat(k[x.PRERELEASELOOSE],")?").concat(k[x.BUILD],"?")+")?)?"),z("XRANGE","^".concat(k[x.GTLT],"\\s*").concat(k[x.XRANGEPLAIN],"$")),z("XRANGELOOSE","^".concat(k[x.GTLT],"\\s*").concat(k[x.XRANGEPLAINLOOSE],"$")),z("COERCE","".concat("(^|[^\\d])(\\d{1,").concat(Ha,"})")+"(?:\\.(\\d{1,".concat(Ha,"}))?")+"(?:\\.(\\d{1,".concat(Ha,"}))?")+"(?:$|[^\\d])"),z("COERCERTL",k[x.COERCE],!0),z("LONETILDE","(?:~>?)"),z("TILDETRIM","(\\s*)".concat(k[x.LONETILDE],"\\s+"),!0);var Ib="$1~";z("TILDE","^".concat(k[x.LONETILDE]).concat(k[x.XRANGEPLAIN],"$")),z("TILDELOOSE","^".concat(k[x.LONETILDE]).concat(k[x.XRANGEPLAINLOOSE],"$")),z("LONECARET","(?:\\^)"),z("CARETTRIM","(\\s*)".concat(k[x.LONECARET],"\\s+"),!0);var Jb="$1^";z("CARET","^".concat(k[x.LONECARET]).concat(k[x.XRANGEPLAIN],"$")),z("CARETLOOSE","^".concat(k[x.LONECARET]).concat(k[x.XRANGEPLAINLOOSE],"$")),z("COMPARATORLOOSE","^".concat(k[x.GTLT],"\\s*(").concat(k[x.LOOSEPLAIN],")$|^$")),z("COMPARATOR","^".concat(k[x.GTLT],"\\s*(").concat(k[x.FULLPLAIN],")$|^$")),z("COMPARATORTRIM","(\\s*)".concat(k[x.GTLT],"\\s*(").concat(k[x.LOOSEPLAIN],"|").concat(k[x.XRANGEPLAIN],")"),!0);var Kb="$1$2$3";z("HYPHENRANGE","^\\s*(".concat(k[x.XRANGEPLAIN],")")+"\\s+-\\s+"+"(".concat(k[x.XRANGEPLAIN],")")+"\\s*$"),z("HYPHENRANGELOOSE","^\\s*(".concat(k[x.XRANGEPLAINLOOSE],")")+"\\s+-\\s+"+"(".concat(k[x.XRANGEPLAINLOOSE],")")+"\\s*$"),z("STAR","(<|>)?=?\\s*\\*"),z("GTE0","^\\s*>=\\s*0.0.0\\s*$"),z("GTE0PRE","^\\s*>=\\s*0.0.0-0\\s*$");var Lb={};var pa={};function Mb(o){return(Mb="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(o){return typeof o}:function(o){return o&&"function"==typeof Symbol&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o})(o)}var Nb=["includePrerelease","loose","rtl"],Ob=function(o){return o?"object"!==Mb(o)?{loose:!0}:Nb.filter(function(t){return o[t]}).reduce(function(o,t){return o[t]=!0,o},{}):{}};pa=Ob;var Ia={},Va=/^[0-9]+$/,Wa=function(r,e){var $=Va.test(r),q=Va.test(e);return $&&q&&(r=+r,e=+e),r===e?0:$&&!q?-1:q&&!$?1:rYa)throw new TypeError("version is longer than ".concat(Ya," characters"));B("SemVer",r,i),this.options=i,this.loose=!!i.loose,this.includePrerelease=!!i.includePrerelease;var t=r.trim().match(i.loose?Za[$a.LOOSE]:Za[$a.FULL]);if(!t)throw new TypeError("Invalid Version: ".concat(r));if(this.raw=r,this.major=+t[1],this.minor=+t[2],this.patch=+t[3],this.major>qa||this.major<0)throw new TypeError("Invalid major version");if(this.minor>qa||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>qa||this.patch<0)throw new TypeError("Invalid patch version");t[4]?this.prerelease=t[4].split(".").map(function(e){if(/^[0-9]+$/.test(e)){var r=+e;if(r>=0&&r=0;)"number"==typeof this.prerelease[i]&&(this.prerelease[i]++,i=-2);-1===i&&this.prerelease.push(0)}r&&(this.prerelease[0]===r?isNaN(this.prerelease[1])&&(this.prerelease=[r,0]):this.prerelease=[r,0]);break;default:throw new Error("invalid increment argument: ".concat(e));}return this.format(),this.raw=this.version,this}}]),e}();C=Sb;var U={},Tb=ga.MAX_LENGTH,_a=aa,ab=ba,Ub=function(r,$){if($=pa($),r instanceof C)return r;if("string"!=typeof r)return null;if(r.length>Tb)return null;if(!($.loose?_a[ab.LOOSE]:_a[ab.FULL]).test(r))return null;try{return new C(r,$)}catch(e){return null}};U=Ub;var Vb={},Wb=function($,r){var p=U($,r);return p?p.version:null};Vb=Wb;var Xb={},Yb=function(r,$){var e=U(r.trim().replace(/^[=v]+/,""),$);return e?e.version:null};Xb=Yb;var Zb={},$b=function(r,n,$,e){"string"==typeof $&&(e=$,$=void 0);try{return new C(r,$).inc(n,e).version}catch(i){return null}};Zb=$b;var K={},_b=function($,e,r){return new C($,r).compare(new C(e,r))};K=_b;var Ja={},ac=function($,r,e){return 0===K($,r,e)};Ja=ac;var bc={},cc=function(e,r){if(Ja(e,r))return null;var $=U(e),a=U(r),p=$.prerelease.length||a.prerelease.length,j=p?"pre":"",E=p?"prerelease":"";for(var M in $)if(("major"===M||"minor"===M||"patch"===M)&&$[M]!==a[M])return j+M;return E};bc=cc;var dc={},ec=function(r,$){return new C(r,$).major};dc=ec;var fc={},gc=function(r,$){return new C(r,$).minor};fc=gc;var hc={},ic=function($,r){return new C($,r).patch};hc=ic;var jc={},kc=function(e,r){var $=U(e,r);return $&&$.prerelease.length?$.prerelease:null};jc=kc;var lc={},mc=function(r,$,m){return K($,r,m)};lc=mc;var nc={},oc=function($,r){return K($,r,!0)};nc=oc;var Ka={},pc=function(r,e,$){var a=new C(r,$),i=new C(e,$);return a.compare(i)||a.compareBuild(i)};Ka=pc;var qc={},rc=function(r,$){return r.sort(function(r,p){return Ka(r,p,$)})};qc=rc;var sc={},tc=function(r,$){return r.sort(function(r,e){return Ka(e,r,$)})};sc=tc;var ca={},uc=function($,r,c){return K($,r,c)>0};ca=uc;var ra={},vc=function($,r,a){return K($,r,a)<0};ra=vc;var bb={},wc=function($,r,e){return 0!==K($,r,e)};bb=wc;var La={},xc=function($,r,e){return K($,r,e)>=0};La=xc;var Ma={},yc=function($,r,e){return K($,r,e)<=0};Ma=yc;var sa={};function ta(r){return(ta="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(r){return typeof r}:function(r){return r&&"function"==typeof Symbol&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r})(r)}var zc=function(r,e,$,t){switch(e){case"===":return"object"===ta(r)&&(r=r.version),"object"===ta($)&&($=$.version),r===$;case"!==":return"object"===ta(r)&&(r=r.version),"object"===ta($)&&($=$.version),r!==$;case"":case"=":case"==":return Ja(r,$,t);case"!=":return bb(r,$,t);case">":return ca(r,$,t);case">=":return La(r,$,t);case"<":return ra(r,$,t);case"<=":return Ma(r,$,t);default:throw new TypeError("Invalid operator: ".concat(e));}};sa=zc;var Ac={},ua=aa,va=ba,Bc=function($,r){if($ instanceof C)return $;if("number"==typeof $&&($=String($)),"string"!=typeof $)return null;var e=null;if((r=r||{}).rtl){for(var a;(a=ua[va.COERCERTL].exec($))&&(!e||e.index+e[0].length!==$.length);)e&&a.index+a[0].length===e.index+e[0].length||(e=a),ua[va.COERCERTL].lastIndex=a.index+a[1].length+a[2].length;ua[va.COERCERTL].lastIndex=-1}else e=$.match(ua[va.COERCE]);return null===e?null:U("".concat(e[2],".").concat(e[3]||"0",".").concat(e[4]||"0"),r)};Ac=Bc;var Cc,Dc=false;function Ec(){if(Dc)return;Dc=true;Cc={};Cc=function(t){t.prototype[Symbol.iterator]=function*(){for(let t=this.head;t;t=t.next)yield t.value}}}var Fc={};function A(t){var l=this;if(l instanceof A||(l=new A),l.tail=null,l.head=null,l.length=0,t&&"function"==typeof t.forEach)t.forEach(function(t){l.push(t)});else if(arguments.length>0)for(var i=0,e=arguments.length;i1)i=l;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");e=this.head.next,i=this.head.value}for(var r=0;null!==e;r++)i=t(i,e.value,r),e=e.next;return i},A.prototype.reduceReverse=function(t,l){var i,e=this.tail;if(arguments.length>1)i=l;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");e=this.tail.prev,i=this.tail.value}for(var r=this.length-1;null!==e;r--)i=t(i,e.value,r),e=e.prev;return i},A.prototype.toArray=function(){for(var t=new Array(this.length),l=0,i=this.head;null!==i;l++)t[l]=i.value,i=i.next;return t},A.prototype.toArrayReverse=function(){for(var t=new Array(this.length),l=0,i=this.tail;null!==i;l++)t[l]=i.value,i=i.prev;return t},A.prototype.slice=function(t,l){(l=l||this.length)<0&&(l+=this.length),(t=t||0)<0&&(t+=this.length);var i=new A;if(lthis.length&&(l=this.length);for(var e=0,r=this.head;null!==r&&ethis.length&&(l=this.length);for(var e=this.length,r=this.tail;null!==r&&e>l;e--)r=r.prev;for(;null!==r&&e>t;e--,r=r.prev)i.push(r.value);return i},A.prototype.splice=function(t,l,...i){t>this.length&&(t=this.length-1),t<0&&(t=this.length+t);for(var e=0,r=this.head;null!==r&&ethis[W])return ea(this,this[N].get($)),!1;var u=this[N].get($).value;return this[R]&&(this[eb]||this[R]($,u.value)),u.now=a,u.maxAge=e,u.value=r,this[Q]+=t-u.length,u.length=t,this.get($),ka(this),!0}var n=new Mc($,r,t,a,e);return n.length>this[W]?(this[R]&&this[R]($,r),!1):(this[Q]+=n.length,this[F].unshift(n),this[N].set($,this[F].head),ka(this),!0)}},{key:"has",value:function($){if(!this[N].has($))return!1;var r=this[N].get($).value;return!wa(this,r)}},{key:"get",value:function($){return Oa(this,$,!0)}},{key:"peek",value:function($){return Oa(this,$,!1)}},{key:"pop",value:function(){var $=this[F].tail;return $?(ea(this,$),$.value):null}},{key:"del",value:function($){ea(this,this[N].get($))}},{key:"load",value:function($){this.reset();for(var r=Date.now(),e=$.length-1;e>=0;e--){var a=$[e],t=a.e||0;if(0===t)this.set(a.k,a.v);else{var u=t-r;u>0&&this.set(a.k,a.v,u)}}}},{key:"prune",value:function(){var $=this;this[N].forEach(function(r,e){return Oa($,e,!1)})}}]),$}(),Oa=function($,r,e){var a=$[N].get(r);if(a){var t=a.value;if(wa($,t)){if(ea($,a),!$[ja])return}else e&&($[fb]&&(a.value.now=Date.now()),$[F].unshiftNode(a));return t.value}},wa=function($,r){if(!r||!r.maxAge&&!$[X])return!1;var e=Date.now()-r.now;return r.maxAge?e>r.maxAge:$[X]&&e>$[X]},ka=function($){if($[Q]>$[W])for(var r=$[F].tail;$[Q]>$[W]&&null!==r;){var e=r.prev;ea($,r),r=e}},ea=function($,r){if(r){var e=r.value;$[R]&&$[R](e.key,e.value),$[Q]-=e.length,$[N].delete(e.key),$[F].removeNode(r)}},Mc=function $(r,e,a,t,u){cb(this,$),this.key=r,this.value=e,this.length=a,this.now=t,this.maxAge=u||0},gb=function($,r,e,a){var t=e.value;wa($,t)&&(ea($,e),$[ja]||(t=void 0)),t&&r.call(a,t.value,t.key,$)};Jc=Lc;var J={};function Nc(t){return Qc(t)||Pc(t)||ib(t)||Oc()}function Oc(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Pc(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function Qc(t){if(Array.isArray(t))return Pa(t)}function hb(t,r){var e="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=ib(t))||r&&t&&"number"==typeof t.length){e&&(t=e);var a=0,$=function(){};return{s:$,n:function(){return a>=t.length?{done:!0}:{done:!1,value:t[a++]}},e:function(t){throw t},f:$}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var n,c=!0,o=!1;return{s:function(){e=e.call(t)},n:function(){var t=e.next();return c=t.done,t},e:function(t){o=!0,n=t},f:function(){try{c||null==e.return||e.return()}finally{if(o)throw n}}}}function ib(t,r){if(t){if("string"==typeof t)return Pa(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);return"Object"===e&&t.constructor&&(e=t.constructor.name),"Map"===e||"Set"===e?Array.from(t):"Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?Pa(t,r):void 0}}function Pa(t,r){(null==r||r>t.length)&&(r=t.length);for(var e=0,a=new Array(r);e1){var $=this.set[0];if(this.set=this.set.filter(function(t){return!lb(t[0])}),0===this.set.length)this.set=[$];else if(this.set.length>1){var n,c=hb(this.set);try{for(c.s();!(n=c.n()).done;){var o=n.value;if(1===o.length&&Xc(o[0])){this.set=[o];break}}}catch(i){c.e(i)}finally{c.f()}}}this.format()}return Sc(t,[{key:"format",value:function(){return this.range=this.set.map(function(t){return t.join(" ").trim()}).join("||").trim(),this.range}},{key:"toString",value:function(){return this.range}},{key:"parseRange",value:function(t){var r=this;t=t.trim();var e=Object.keys(this.options).join(","),a="parseRange:".concat(e,":").concat(t),$=kb.get(a);if($)return $;var n=this.options.loose,c=n?H[G.HYPHENRANGELOOSE]:H[G.HYPHENRANGE];t=t.replace(c,gd(this.options.includePrerelease)),B("hyphen replace",t),t=t.replace(H[G.COMPARATORTRIM],Uc),B("comparator trim",t,H[G.COMPARATORTRIM]),t=(t=(t=t.replace(H[G.TILDETRIM],Vc)).replace(H[G.CARETTRIM],Wc)).split(/\s+/).join(" ");var o,i=n?H[G.COMPARATORLOOSE]:H[G.COMPARATOR],d=t.split(" ").map(function(t){return Yc(t,r.options)}).join(" ").split(/\s+/).map(function(t){return fd(t,r.options)}).filter(this.options.loose?function(t){return!!t.match(i)}:function(){return!0}).map(function(t){return new Y(t,r.options)}),s=(d.length,new Map),u=hb(d);try{for(u.s();!(o=u.n()).done;){var v=o.value;if(lb(v))return[v];s.set(v.value,v)}}catch(q){u.e(q)}finally{u.f()}s.size>1&&s.has("")&&s.delete("");var l=Nc(s.values());return kb.set(a,l),l}},{key:"intersects",value:function(r,e){if(!(r instanceof t))throw new TypeError("a Range is required");return this.set.some(function(t){return mb(t,e)&&r.set.some(function(r){return mb(r,e)&&t.every(function(t){return r.every(function(r){return t.intersects(r,e)})})})})}},{key:"test",value:function(t){if(!t)return!1;if("string"==typeof t)try{t=new C(t,this.options)}catch(e){return!1}for(var r=0;r=".concat(e,".").concat($,".0").concat(a," <").concat(e,".").concat(+$+1,".0-0"):">=".concat(e,".").concat($,".0").concat(a," <").concat(+e+1,".0.0-0"):c?(B("replaceCaret pr",c),o="0"===e?"0"===$?">=".concat(e,".").concat($,".").concat(n,"-").concat(c," <").concat(e,".").concat($,".").concat(+n+1,"-0"):">=".concat(e,".").concat($,".").concat(n,"-").concat(c," <").concat(e,".").concat(+$+1,".0-0"):">=".concat(e,".").concat($,".").concat(n,"-").concat(c," <").concat(+e+1,".0.0-0")):(B("no pr"),o="0"===e?"0"===$?">=".concat(e,".").concat($,".").concat(n).concat(a," <").concat(e,".").concat($,".").concat(+n+1,"-0"):">=".concat(e,".").concat($,".").concat(n).concat(a," <").concat(e,".").concat(+$+1,".0-0"):">=".concat(e,".").concat($,".").concat(n," <").concat(+e+1,".0.0-0")),B("caret return",o),o})},cd=function(t,r){return B("replaceXRanges",t,r),t.split(/\s+/).map(function(t){return dd(t,r)}).join(" ")},dd=function(t,r){t=t.trim();var e=r.loose?H[G.XRANGELOOSE]:H[G.XRANGE];return t.replace(e,function(e,a,$,n,c,o){B("xRange",t,e,a,$,n,c,o);var i=I($),d=i||I(n),s=d||I(c),u=s;return"="===a&&u&&(a=""),o=r.includePrerelease?"-0":"",i?e=">"===a||"<"===a?"<0.0.0-0":"*":a&&u?(d&&(n=0),c=0,">"===a?(a=">=",d?($=+$+1,n=0,c=0):(n=+n+1,c=0)):"<="===a&&(a="<",d?$=+$+1:n=+n+1),"<"===a&&(o="-0"),e="".concat(a+$,".").concat(n,".").concat(c).concat(o)):d?e=">=".concat($,".0.0").concat(o," <").concat(+$+1,".0.0-0"):s&&(e=">=".concat($,".").concat(n,".0").concat(o," <").concat($,".").concat(+n+1,".0-0")),B("xRange return",e),e})},ed=function(t,r){return B("replaceStars",t,r),t.trim().replace(H[G.STAR],"")},fd=function(t,r){return B("replaceGTE0",t,r),t.trim().replace(H[r.includePrerelease?G.GTE0PRE:G.GTE0],"")},gd=function(t){return function(r,e,a,$,n,c,o,i,d,s,u,v,l){return e=I(a)?"":I($)?">=".concat(a,".0.0").concat(t?"-0":""):I(n)?">=".concat(a,".").concat($,".0").concat(t?"-0":""):c?">=".concat(e):">=".concat(e).concat(t?"-0":""),i=I(d)?"":I(s)?"<".concat(+d+1,".0.0-0"):I(u)?"<".concat(d,".").concat(+s+1,".0-0"):v?"<=".concat(d,".").concat(s,".").concat(u,"-").concat(v):t?"<".concat(d,".").concat(s,".").concat(+u+1,"-0"):"<=".concat(i),"".concat(e," ").concat(i).trim()}},hd=function(t,r,e){for(var a=0;a0){var n=t[$].semver;if(n.major===r.major&&n.minor===r.minor&&n.patch===r.patch)return!0}return!1}return!0};var Y={};function id(r){return(id="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(r){return typeof r}:function(r){return r&&"function"==typeof Symbol&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r})(r)}function jd(r,e){if(!(r instanceof e))throw new TypeError("Cannot call a class as a function")}function nb(r,e){for(var t=0;t="!==this.operator&&">"!==this.operator||">="!==e.operator&&">"!==e.operator),s=!("<="!==this.operator&&"<"!==this.operator||"<="!==e.operator&&"<"!==e.operator),a=this.semver.version===e.semver.version,$=!(">="!==this.operator&&"<="!==this.operator||">="!==e.operator&&"<="!==e.operator),i=sa(this.semver,"<",e.semver,t)&&(">="===this.operator||">"===this.operator)&&("<="===e.operator||"<"===e.operator),n=sa(this.semver,">",e.semver,t)&&("<="===this.operator||"<"===this.operator)&&(">="===e.operator||">"===e.operator);return o||s||a&&$||i||n}}],[{key:"ANY",get:function(){return la}}]),r}();Y=ld;var ob=aa,pb=ba;var S={},md=function(a,$,r){try{$=new J($,r)}catch(e){return!1}return $.test(a)};S=md;var nd={},od=function(r,$){return new J(r,$).set.map(function(r){return r.map(function(r){return r.value}).join(" ").trim().split(" ")})};nd=od;var pd={},qd=function(r,$,e){var a=null,n=null,h=null;try{h=new J($,e)}catch(l){return null}return r.forEach(function(r){h.test(r)&&(a&&-1!==n.compare(r)||(n=new C(a=r,e)))}),a};pd=qd;var rd={},sd=function(r,$,e){var a=null,c=null,n=null;try{n=new J($,e)}catch(l){return null}return r.forEach(function(r){n.test(r)&&(a&&1!==c.compare(r)||(c=new C(a=r,e)))}),a};rd=sd;var td={},ud=function(e,r){e=new J(e,r);var $=new C("0.0.0");if(e.test($))return $;if($=new C("0.0.0-0"),e.test($))return $;$=null;for(var a=function(r){var a=e.set[r],w=null;a.forEach(function(e){var r=new C(e.semver.version);switch(e.operator){case">":0===r.prerelease.length?r.patch++:r.prerelease.push(0),r.raw=r.format();case"":case">=":w&&!ca(r,w)||(w=r);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: ".concat(e.operator));}}),!w||$&&!ca($,w)||($=w)},w=0;w":t=ca,a=Ma,o=ra,m=">",n=">=";break;case"<":t=ra,a=La,o=ca,m="<",n="<=";break;default:throw new TypeError("Must provide a hilo val of \"<\" or \">\"");}if(S(r,e,v))return!1;for(var s=function($){var s=e.set[$],i=null,P=null;return s.forEach(function(r){r.semver===yd&&(r=new Y(">=0.0.0")),i=i||r,P=P||r,t(r.semver,i.semver,v)?i=r:o(r.semver,P.semver,v)&&(P=r)}),i.operator===m||i.operator===n?{v:!1}:P.operator&&P.operator!==m||!a(r,P.semver)?P.operator===n&&o(r,P.semver)?{v:!1}:void 0:{v:!1}},i=0;i",r)};Ad=Bd;var Cd={},Dd=function($,e,r){return Qa($,e,"<",r)};Cd=Dd;var Ed={},Fd=function($,n,e){return $=new J($,e),n=new J(n,e),$.intersects(n)};Ed=Fd;var Gd={};function Hd(r,t){return Kd(r)||Jd(r,t)||qb(r,t)||Id()}function Id(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Jd(r,t){var e=null==r?null:"undefined"!=typeof Symbol&&r[Symbol.iterator]||r["@@iterator"];if(null!=e){var n,a,o=[],i=!0,l=!1;try{for(e=e.call(r);!(i=(n=e.next()).done)&&(o.push(n.value),!t||o.length!==t);i=!0);}catch(f){l=!0,a=f}finally{try{i||null==e.return||e.return()}finally{if(l)throw a}}return o}}function Kd(r){if(Array.isArray(r))return r}function Ld(r,t){var e="undefined"!=typeof Symbol&&r[Symbol.iterator]||r["@@iterator"];if(!e){if(Array.isArray(r)||(e=qb(r))||t&&r&&"number"==typeof r.length){e&&(r=e);var n=0,a=function(){};return{s:a,n:function(){return n>=r.length?{done:!0}:{done:!1,value:r[n++]}},e:function(r){throw r},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i=!0,l=!1;return{s:function(){e=e.call(r)},n:function(){var r=e.next();return i=r.done,r},e:function(r){l=!0,o=r},f:function(){try{i||null==e.return||e.return()}finally{if(l)throw o}}}}function qb(r,t){if(r){if("string"==typeof r)return rb(r,t);var e=Object.prototype.toString.call(r).slice(8,-1);return"Object"===e&&r.constructor&&(e=r.constructor.name),"Map"===e||"Set"===e?Array.from(r):"Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?rb(r,t):void 0}}function rb(r,t){(null==t||t>r.length)&&(t=r.length);for(var e=0,n=new Array(t);e=".concat(v)):$.push("*")}var h=$.join(" || "),L="string"==typeof t.raw?t.raw:String(t);return h.length=r.length?{done:!0}:{done:!1,value:r[t++]}},e:function(r){throw r},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,$=!0,u=!1;return{s:function(){a=a.call(r)},n:function(){var r=a.next();return $=r.done,r},e:function(r){u=!0,o=r},f:function(){try{$||null==a.return||a.return()}finally{if(u)throw o}}}}function Nd(r,e){if(r){if("string"==typeof r)return sb(r,e);var a=Object.prototype.toString.call(r).slice(8,-1);return"Object"===a&&r.constructor&&(a=r.constructor.name),"Map"===a||"Set"===a?Array.from(r):"Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?sb(r,e):void 0}}function sb(r,e){(null==e||e>r.length)&&(e=r.length);for(var a=0,t=new Array(e);a"===f.operator||">="===f.operator?t=ub(t,f,a):"<"===f.operator||"<="===f.operator?n=vb(n,f,a):u.add(f.semver)}}catch(b){i.e(b)}finally{i.f()}if(u.size>1)return null;if(t&&n){if(($=K(t.semver,n.semver,a))>0)return null;if(0===$&&(">="!==t.operator||"<="!==n.operator))return null}var v,s,l,c,w,p=fa(u);try{for(p.s();!(v=p.n()).done;){var q=v.value;if(t&&!S(q,String(t),a))return null;if(n&&!S(q,String(n),a))return null;var E,y=fa(e);try{for(y.s();!(E=y.n()).done;){var m=E.value;if(!S(q,String(m),a))return!1}}catch(b){y.e(b)}finally{y.f()}return!0}}catch(b){p.e(b)}finally{p.f()}var h,g=fa(e);try{for(g.s();!(h=g.n()).done;){var d=h.value;if(w=w||">"===d.operator||">="===d.operator,c=c||"<"===d.operator||"<="===d.operator,t)if(">"===d.operator||">="===d.operator){if((s=ub(t,d,a))===d&&s!==t)return!1}else if(">="===t.operator&&!S(t.semver,String(d),a))return!1;if(n)if("<"===d.operator||"<="===d.operator){if((l=vb(n,d,a))===d&&l!==n)return!1}else if("<="===n.operator&&!S(n.semver,String(d),a))return!1;if(!d.operator&&(n||t)&&0!==$)return!1}}catch(b){g.e(b)}finally{g.f()}return!(t&&c&&!n&&0!==$)&&!(n&&w&&!t&&0!==$)},ub=function(r,e,a){if(!r)return e;var t=K(r.semver,e.semver,a);return t>0?r:t<0?e:">"===e.operator&&">="===r.operator?e:r},vb=function(r,e,a){if(!r)return e;var t=K(r.semver,e.semver,a);return t<0?r:t>0?e:"<"===e.operator&&"<="===r.operator?e:r};Md=Od;Lb={re:aa,src:Fb,tokens:ba,SEMVER_SPEC_VERSION:ga.SEMVER_SPEC_VERSION,SemVer:C,compareIdentifiers:Ia.compareIdentifiers,rcompareIdentifiers:Ia.rcompareIdentifiers,parse:U,valid:Vb,clean:Xb,inc:Zb,diff:bc,major:dc,minor:fc,patch:hc,prerelease:jc,compare:K,rcompare:lc,compareLoose:nc,compareBuild:Ka,sort:qc,rsort:sc,gt:ca,lt:ra,eq:Ja,neq:bb,gte:La,lte:Ma,cmp:sa,coerce:Ac,Comparator:Y,Range:J,satisfies:S,toComparators:nd,maxSatisfying:pd,minSatisfying:rd,minVersion:td,validRange:vd,outside:Qa,gtr:Ad,ltr:Cd,intersects:Ed,simplifyRange:Gd,subset:Md};var xa={data:function(){return{version:"",releaseInfo:0,hasVersionDiff:!1,hasError:!1}},created:function(){this.load()},computed:{},methods:{load:function(){var e=this;this.$api.get("komments/version").then(function(r){e.version=r.version}).then(function(){fetch("https://repo.packagist.org/p/mauricerenck/komments.json",{method:"GET"}).then(function(e){return e.json()}).then(function(r){"error"===r.status&&(e.hasError=!0),e.releaseInfo=e.version;var t=e.version;Object.keys(r.packages["mauricerenck/komments"]).sort().forEach(function(r){var $svGQ$$interop$default=wb(Lb);if(!$svGQ$$interop$default.d.valid(r))return!1;$svGQ$$interop$default.d.gt(r,t)&&(e.hasVersionDiff=$svGQ$$interop$default.d.gt(r,t),e.releaseInfo=r.toString())})}).catch(function(r){console.log("catch",r),e.hasError=!0})})}}};if(typeof xa==="function"){xa=xa.options}Object.assign(xa,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("div",{staticClass:"k-support"},[_vm.hasError?_c("div",{staticClass:"error"},[_c("k-info-field",{attrs:{"theme":"negative","label":"Ooops","text":"The current version could not be fetched. You may have reached an API limit"}})],1):_c("div",{staticClass:"versionBox"},[_vm.hasVersionDiff?_c("div",[_c("h4",{staticClass:"update-available"},[_vm._v("There is an update available")]),_vm._v(" "),_c("h3",{staticClass:"version"},[_vm._v(_vm._s(this.releaseInfo))])]):_c("div",[_c("h4",[_vm._v("Your Komments plugin is up to date")])]),_vm._v(" "),_c("small",{staticClass:"align-center"},[_vm._v("Your installed version is "+_vm._s(this.version))])])])};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var ya={components:{QueuedKomments:na,SpamKomments:oa,Support:xa}};if(typeof ya==="function"){ya=ya.options}Object.assign(ya,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("k-view",{staticClass:"k-kommentviews-view"},[_c("k-header",[_vm._v("Komments")]),_vm._v(" "),_c("k-grid",{attrs:{"gutter":"large"}},[_c("k-column",{attrs:{"width":"2/4"}},[_c("k-headline-field",{attrs:{"label":"In moderation"}}),_vm._v(" "),_c("QueuedKomments")],1),_vm._v(" "),_c("k-column",{attrs:{"width":"1/4"}},[_c("k-headline-field",{attrs:{"label":"Marked as spam"}}),_vm._v(" "),_c("SpamKomments")],1),_vm._v(" "),_c("k-column",{attrs:{"width":"1/4"}},[_c("k-headline-field",{attrs:{"label":"Plugin"}}),_vm._v(" "),_c("Support")],1)],1)],1)};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var ma={data:function(){return{selectedKomment:{},kommentList:[]}},props:{title:String,queuedKomments:Array,version:Object},created:function(){this.kommentList=this.queuedKomments,this.selectKomment(this.kommentList[0].id),this.loadKomments()},methods:{loadKomments:function(){var t=this;this.$api.get("komments/queued").then(function(e){t.komments=e})},selectKomment:function(t){this.selectedKomment=this.queuedKomments.find(function(e){return e.id===t})},onMarkAsSpam:function(t){for(var e=0;e0},on:{"click":function($event){return _vm.markAsVerified(_vm.komment.slug,_vm.komment.id,true)}}},[_vm._v(" Verified ")]),_vm._v(" "),_vm.komment.spamlevel===0?_c("k-button",{attrs:{"icon":"toggle-off"},on:{"click":function($event){return _vm.markAsSpam(_vm.komment.slug,_vm.komment.id,true)}}},[_vm._v(" Spam ")]):_c("k-button",{attrs:{"theme":"negative","icon":"toggle-on"},on:{"click":function($event){return _vm.markAsSpam(_vm.komment.slug,_vm.komment.id,false)}}},[_vm._v(" Spam ")]),_vm._v(" "),_vm.komment.status===true?_c("k-button",{staticClass:"publish",attrs:{"theme":"positive","icon":"toggle-on"},on:{"click":function($event){return _vm.publish(_vm.komment.slug,_vm.komment.id,false)}}},[_vm._v(" Published ")]):_c("k-button",{staticClass:"publish",attrs:{"disabled":_vm.komment.spamlevel>0,"icon":"toggle-off"},on:{"click":function($event){return _vm.publish(_vm.komment.slug,_vm.komment.id,true)}}},[_vm._v(" Published ")])],1),_vm._v(" "),_c("template",{slot:"right"},[_c("k-button",{attrs:{"theme":"negative","icon":"trash"},on:{"click":function($event){return _vm.$refs.deleteDialog.open()}}},[_vm._v(" Delete ")]),_vm._v(" "),_c("k-dialog",{ref:"deleteDialog",attrs:{"button":"Delete","theme":"negative","icon":"trash"},on:{"submit":function($event){return _vm.deleteKomment(_vm.komment.slug,_vm.komment.id,_vm.$refs)}}},[_c("k-text",[_vm._v(" Do you really want to delete the comment? This cannot be undone. ")])],1)],1)],2)],1),_vm._v(" "),_c("div",{staticClass:"text"},[_vm._v(" "+_vm._s(_vm.komment.komment)+" ")])],1)};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var Aa={props:{queuedKomments:Array,onSelectKomment:Function,selectedKomment:Object},methods:{}};if(typeof Aa==="function"){Aa=Aa.options}Object.assign(Aa,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("div",{staticClass:"komments-list"},[_c("ul",_vm._l(_vm.queuedKomments,function(komment,index){return _c("li",{key:index,staticClass:"list-item",class:{active:_vm.selectedKomment.id===komment.id,isSpam:komment.spamlevel>0,isVerified:komment.verified===true},on:{"click":function($event){return _vm.onSelectKomment(komment.id)},"keypress":function($event){return _vm.onSelectKomment(komment.id)}}},[_c("k-grid",[_c("k-column",{staticClass:"avatar",attrs:{"width":"2/12"}},[komment.image?_c("img",{attrs:{"src":komment.image}}):_vm._e()]),_vm._v(" "),_c("k-column",{attrs:{"width":"10/12"}},[_c("div",{staticClass:"komment-preview"},[_c("div",{staticClass:"author"},[_c("strong",[_vm._v(_vm._s(komment.author))])]),_vm._v(" "),_c("div",{staticClass:"meta"},[_vm._v(_vm._s(komment.published)+" - "+_vm._s(komment.title))]),_vm._v(" "),_c("div",{staticClass:"preview"},[_vm._v(" "+_vm._s(komment.komment.substr(0,60)+"\u2026")+" ")])])]),_vm._v(" "),_c("k-column",{attrs:{"width":"2/12"}}),_vm._v(" "),_c("k-column",{attrs:{"width":"10/12"}},[_c("div",{staticClass:"status"},[komment.status===false?_c("span",{staticClass:"badge",attrs:{"alt":"pending","title":"pending"}},[_vm._v(" pending ")]):komment.status===true?_c("span",{staticClass:"badge blue",attrs:{"alt":"published","title":"published"}},[_vm._v(" published ")]):_vm._e(),_vm._v(" "),komment.verified===true?_c("span",{staticClass:"badge green",attrs:{"alt":"Verified user","title":"Verified user"}},[_vm._v(" verified ")]):_vm._e(),_vm._v(" "),komment.spamlevel>0?_c("span",{staticClass:"badge red",attrs:{"alt":"Possible spam comment","title":"Possible spam comment"}},[_vm._v(" spam ")]):_vm._e()])])],1)],1)}),0)])};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var Ba={props:{version:Object}};if(typeof Ba==="function"){Ba=Ba.options}Object.assign(Ba,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("div",[_vm.version.error?_c("div",{staticClass:"error"},[_c("k-info-field",{attrs:{"theme":"negative","label":"Sorry","text":"The current version could not be fetched."}})],1):_c("div",{staticClass:"version-box"},[_vm.version.updateAvailable?_c("div",[_c("h4",{staticClass:"update-available"},[_vm._v("There is an update available")]),_vm._v(" "),_c("h3",{staticClass:"version"},[_vm._v(_vm._s(_vm.version.latest))])]):_c("div",[_c("h4",[_vm._v("This plugin is up to date")])]),_vm._v(" "),_c("small",{staticClass:"align-center"},[_vm._v(" Your installed version is "+_vm._s(_vm.version.local)+" ")])])])};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var Ca={props:{queuedComments:Number}};if(typeof Ca==="function"){Ca=Ca.options}Object.assign(Ca,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("div",{staticClass:"kommentsPendingCounter"},[_c("k-headline",[_vm._v("Pending Comments")]),_vm._v(" "),_c("div",{staticClass:"count"},[_vm._v(_vm._s(_vm.queuedComments))])],1)};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());panel.plugin("mauricerenck/komments",{components:{"k-komments-view":ma,KommentDetails:za,KommentList:Aa,KommentVersion:Ba},fields:{komments:ma,kommentsPending:Ca},views:{queuedKommments:{component:ya,icon:"chat",label:"Komments"}}});})(); \ No newline at end of file +(function () {function yb(a){return a&&a.__esModule?{d:a.default}:{d:a}}var pa={data:function(){return{komments:[]}},created:function(){this.load()},methods:{load:function(){var t=this;this.$api.get("komments/queued").then(function(e){t.komments=e})}}};if(typeof pa==="function"){pa=pa.options}Object.assign(pa,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("div",{staticClass:"k-komments"},[_c("k-list",{attrs:{"data-size":"medium"}},_vm._l(_vm.komments,function(komment){return _c("k-list-item",{key:komment.title,attrs:{"link":komment.url+"#komments","info":""+komment.author,"text":komment.title+" - "+komment.komment,"image":{ratio:"1/1",cover:true,back:"pattern",url:komment.image},"target":"_self"}})}),1)],1)};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var qa={data:function(){return{komments:[]}},created:function(){this.load()},methods:{load:function(){var t=this;this.$api.get("komments/spam").then(function(e){t.komments=e})}}};if(typeof qa==="function"){qa=qa.options}Object.assign(qa,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("div",{staticClass:"k-spam-komments"},[_c("k-list",{attrs:{"data-size":"medium"}},_vm._l(_vm.komments,function(komment){return _c("k-list-item",{key:komment.title,attrs:{"link":komment.url+"#komments","info":""+komment.author,"text":komment.title+" - "+komment.komment,"image":{ratio:"1/1",cover:true,back:"pattern",url:komment.image},"target":"_self"}})}),1)],1)};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var ia={},zb="2.0.0",Ab=256,Bb=Number.MAX_SAFE_INTEGER||9007199254740991,Cb=16;ia={SEMVER_SPEC_VERSION:zb,MAX_LENGTH:Ab,MAX_SAFE_INTEGER:Bb,MAX_SAFE_COMPONENT_LENGTH:Cb};var aa,ba,Fa={},F=Fa={};function Ga(){throw new Error("setTimeout has not been defined")}function Ha(){throw new Error("clearTimeout has not been defined")}function Ua($){if(aa===setTimeout)return setTimeout($,0);if((aa===Ga||!aa)&&setTimeout)return aa=setTimeout,setTimeout($,0);try{return aa($,0)}catch(e){try{return aa.call(null,$,0)}catch(e){return aa.call(this,$,0)}}}function Db($){if(ba===clearTimeout)return clearTimeout($);if((ba===Ha||!ba)&&clearTimeout)return ba=clearTimeout,clearTimeout($);try{return ba($)}catch(e){try{return ba.call(null,$)}catch(e){return ba.call(this,$)}}}!function(){try{aa="function"==typeof setTimeout?setTimeout:Ga}catch($){aa=Ga}try{ba="function"==typeof clearTimeout?clearTimeout:Ha}catch($){ba=Ha}}();var ja,W=[],Ia=!1,Va=-1;function Eb(){Ia&&ja&&(Ia=!1,ja.length?W=ja.concat(W):Va=-1,W.length&&Wa())}function Wa(){if(!Ia){var $=Ua(Eb);Ia=!0;for(var e=W.length;e;){for(ja=W,W=[];++Va1)for(var r=1;r)?=?)"),z("XRANGEIDENTIFIERLOOSE","".concat(k[x.NUMERICIDENTIFIERLOOSE],"|x|X|\\*")),z("XRANGEIDENTIFIER","".concat(k[x.NUMERICIDENTIFIER],"|x|X|\\*")),z("XRANGEPLAIN","[v=\\s]*(".concat(k[x.XRANGEIDENTIFIER],")")+"(?:\\.(".concat(k[x.XRANGEIDENTIFIER],")")+"(?:\\.(".concat(k[x.XRANGEIDENTIFIER],")")+"(?:".concat(k[x.PRERELEASE],")?").concat(k[x.BUILD],"?")+")?)?"),z("XRANGEPLAINLOOSE","[v=\\s]*(".concat(k[x.XRANGEIDENTIFIERLOOSE],")")+"(?:\\.(".concat(k[x.XRANGEIDENTIFIERLOOSE],")")+"(?:\\.(".concat(k[x.XRANGEIDENTIFIERLOOSE],")")+"(?:".concat(k[x.PRERELEASELOOSE],")?").concat(k[x.BUILD],"?")+")?)?"),z("XRANGE","^".concat(k[x.GTLT],"\\s*").concat(k[x.XRANGEPLAIN],"$")),z("XRANGELOOSE","^".concat(k[x.GTLT],"\\s*").concat(k[x.XRANGEPLAINLOOSE],"$")),z("COERCE","".concat("(^|[^\\d])(\\d{1,").concat(Ja,"})")+"(?:\\.(\\d{1,".concat(Ja,"}))?")+"(?:\\.(\\d{1,".concat(Ja,"}))?")+"(?:$|[^\\d])"),z("COERCERTL",k[x.COERCE],!0),z("LONETILDE","(?:~>?)"),z("TILDETRIM","(\\s*)".concat(k[x.LONETILDE],"\\s+"),!0);var Kb="$1~";z("TILDE","^".concat(k[x.LONETILDE]).concat(k[x.XRANGEPLAIN],"$")),z("TILDELOOSE","^".concat(k[x.LONETILDE]).concat(k[x.XRANGEPLAINLOOSE],"$")),z("LONECARET","(?:\\^)"),z("CARETTRIM","(\\s*)".concat(k[x.LONECARET],"\\s+"),!0);var Lb="$1^";z("CARET","^".concat(k[x.LONECARET]).concat(k[x.XRANGEPLAIN],"$")),z("CARETLOOSE","^".concat(k[x.LONECARET]).concat(k[x.XRANGEPLAINLOOSE],"$")),z("COMPARATORLOOSE","^".concat(k[x.GTLT],"\\s*(").concat(k[x.LOOSEPLAIN],")$|^$")),z("COMPARATOR","^".concat(k[x.GTLT],"\\s*(").concat(k[x.FULLPLAIN],")$|^$")),z("COMPARATORTRIM","(\\s*)".concat(k[x.GTLT],"\\s*(").concat(k[x.LOOSEPLAIN],"|").concat(k[x.XRANGEPLAIN],")"),!0);var Mb="$1$2$3";z("HYPHENRANGE","^\\s*(".concat(k[x.XRANGEPLAIN],")")+"\\s+-\\s+"+"(".concat(k[x.XRANGEPLAIN],")")+"\\s*$"),z("HYPHENRANGELOOSE","^\\s*(".concat(k[x.XRANGEPLAINLOOSE],")")+"\\s+-\\s+"+"(".concat(k[x.XRANGEPLAINLOOSE],")")+"\\s*$"),z("STAR","(<|>)?=?\\s*\\*"),z("GTE0","^\\s*>=\\s*0.0.0\\s*$"),z("GTE0PRE","^\\s*>=\\s*0.0.0-0\\s*$");var Nb={};var ra={};function Ob(o){return(Ob="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(o){return typeof o}:function(o){return o&&"function"==typeof Symbol&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o})(o)}var Pb=["includePrerelease","loose","rtl"],Qb=function(o){return o?"object"!==Ob(o)?{loose:!0}:Pb.filter(function(t){return o[t]}).reduce(function(o,t){return o[t]=!0,o},{}):{}};ra=Qb;var Ka={},Ya=/^[0-9]+$/,Za=function(r,e){var $=Ya.test(r),q=Ya.test(e);return $&&q&&(r=+r,e=+e),r===e?0:$&&!q?-1:q&&!$?1:r_a)throw new TypeError("version is longer than ".concat(_a," characters"));C("SemVer",r,i),this.options=i,this.loose=!!i.loose,this.includePrerelease=!!i.includePrerelease;var t=r.trim().match(i.loose?ab[bb.LOOSE]:ab[bb.FULL]);if(!t)throw new TypeError("Invalid Version: ".concat(r));if(this.raw=r,this.major=+t[1],this.minor=+t[2],this.patch=+t[3],this.major>sa||this.major<0)throw new TypeError("Invalid major version");if(this.minor>sa||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>sa||this.patch<0)throw new TypeError("Invalid patch version");t[4]?this.prerelease=t[4].split(".").map(function(e){if(/^[0-9]+$/.test(e)){var r=+e;if(r>=0&&r=0;)"number"==typeof this.prerelease[i]&&(this.prerelease[i]++,i=-2);-1===i&&this.prerelease.push(0)}r&&(this.prerelease[0]===r?isNaN(this.prerelease[1])&&(this.prerelease=[r,0]):this.prerelease=[r,0]);break;default:throw new Error("invalid increment argument: ".concat(e));}return this.format(),this.raw=this.version,this}}]),e}();D=Ub;var X={},Vb=ia.MAX_LENGTH,cb=ca,db=da,Wb=function(r,$){if($=ra($),r instanceof D)return r;if("string"!=typeof r)return null;if(r.length>Vb)return null;if(!($.loose?cb[db.LOOSE]:cb[db.FULL]).test(r))return null;try{return new D(r,$)}catch(e){return null}};X=Wb;var Xb={},Yb=function($,r){var p=X($,r);return p?p.version:null};Xb=Yb;var Zb={},$b=function(r,$){var e=X(r.trim().replace(/^[=v]+/,""),$);return e?e.version:null};Zb=$b;var _b={},ac=function(r,n,$,e){"string"==typeof $&&(e=$,$=void 0);try{return new D(r,$).inc(n,e).version}catch(i){return null}};_b=ac;var N={},bc=function($,e,r){return new D($,r).compare(new D(e,r))};N=bc;var La={},cc=function($,r,e){return 0===N($,r,e)};La=cc;var dc={},ec=function(e,r){if(La(e,r))return null;var $=X(e),a=X(r),p=$.prerelease.length||a.prerelease.length,j=p?"pre":"",E=p?"prerelease":"";for(var M in $)if(("major"===M||"minor"===M||"patch"===M)&&$[M]!==a[M])return j+M;return E};dc=ec;var fc={},gc=function(r,$){return new D(r,$).major};fc=gc;var hc={},ic=function(r,$){return new D(r,$).minor};hc=ic;var jc={},kc=function($,r){return new D($,r).patch};jc=kc;var lc={},mc=function(e,r){var $=X(e,r);return $&&$.prerelease.length?$.prerelease:null};lc=mc;var nc={},oc=function(r,$,m){return N($,r,m)};nc=oc;var pc={},qc=function($,r){return N($,r,!0)};pc=qc;var Ma={},rc=function(r,e,$){var a=new D(r,$),i=new D(e,$);return a.compare(i)||a.compareBuild(i)};Ma=rc;var sc={},tc=function(r,$){return r.sort(function(r,p){return Ma(r,p,$)})};sc=tc;var uc={},vc=function(r,$){return r.sort(function(r,e){return Ma(e,r,$)})};uc=vc;var ea={},wc=function($,r,c){return N($,r,c)>0};ea=wc;var ta={},xc=function($,r,a){return N($,r,a)<0};ta=xc;var eb={},yc=function($,r,e){return 0!==N($,r,e)};eb=yc;var Na={},zc=function($,r,e){return N($,r,e)>=0};Na=zc;var Oa={},Ac=function($,r,e){return N($,r,e)<=0};Oa=Ac;var ua={};function va(r){return(va="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(r){return typeof r}:function(r){return r&&"function"==typeof Symbol&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r})(r)}var Bc=function(r,e,$,t){switch(e){case"===":return"object"===va(r)&&(r=r.version),"object"===va($)&&($=$.version),r===$;case"!==":return"object"===va(r)&&(r=r.version),"object"===va($)&&($=$.version),r!==$;case"":case"=":case"==":return La(r,$,t);case"!=":return eb(r,$,t);case">":return ea(r,$,t);case">=":return Na(r,$,t);case"<":return ta(r,$,t);case"<=":return Oa(r,$,t);default:throw new TypeError("Invalid operator: ".concat(e));}};ua=Bc;var Cc={},wa=ca,xa=da,Dc=function($,r){if($ instanceof D)return $;if("number"==typeof $&&($=String($)),"string"!=typeof $)return null;var e=null;if((r=r||{}).rtl){for(var a;(a=wa[xa.COERCERTL].exec($))&&(!e||e.index+e[0].length!==$.length);)e&&a.index+a[0].length===e.index+e[0].length||(e=a),wa[xa.COERCERTL].lastIndex=a.index+a[1].length+a[2].length;wa[xa.COERCERTL].lastIndex=-1}else e=$.match(wa[xa.COERCE]);return null===e?null:X("".concat(e[2],".").concat(e[3]||"0",".").concat(e[4]||"0"),r)};Cc=Dc;var Ec,Fc=false;function Gc(){if(Fc)return;Fc=true;Ec={};Ec=function(e){e.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}}var Hc={};function B(t){var e=this;if(e instanceof B||(e=new B),e.tail=null,e.head=null,e.length=0,t&&"function"==typeof t.forEach)t.forEach(function(t){e.push(t)});else if(arguments.length>0)for(var l=0,i=arguments.length;l1)l=e;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");i=this.head.next,l=this.head.value}for(var r=0;null!==i;r++)l=t(l,i.value,r),i=i.next;return l},B.prototype.reduceReverse=function(t,e){var l,i=this.tail;if(arguments.length>1)l=e;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");i=this.tail.prev,l=this.tail.value}for(var r=this.length-1;null!==i;r--)l=t(l,i.value,r),i=i.prev;return l},B.prototype.toArray=function(){for(var t=new Array(this.length),e=0,l=this.head;null!==l;e++)t[e]=l.value,l=l.next;return t},B.prototype.toArrayReverse=function(){for(var t=new Array(this.length),e=0,l=this.tail;null!==l;e++)t[e]=l.value,l=l.prev;return t},B.prototype.slice=function(t,e){(e=e||this.length)<0&&(e+=this.length),(t=t||0)<0&&(t+=this.length);var l=new B;if(ethis.length&&(e=this.length);for(var i=0,r=this.head;null!==r&&ithis.length&&(e=this.length);for(var i=this.length,r=this.tail;null!==r&&i>e;i--)r=r.prev;for(;null!==r&&i>t;i--,r=r.prev)l.push(r.value);return l},B.prototype.splice=function(t,e,...l){t>this.length&&(t=this.length-1),t<0&&(t=this.length+t);for(var i=0,r=this.head;null!==r&&ithis[Z])return ga(this,this[O].get(t)),!1;var a=this[O].get(t).value;return this[U]&&(this[hb]||this[U](t,a.value)),a.now=r,a.maxAge=f,a.value=$,this[T]+=e-a.length,a.length=e,this.get(t),ma(this),!0}var n=new Oc(t,$,e,r,f);return n.length>this[Z]?(this[U]&&this[U](t,$),!1):(this[T]+=n.length,this[G].unshift(n),this[O].set(t,this[G].head),ma(this),!0)}},{key:"has",value:function(t){if(!this[O].has(t))return!1;var $=this[O].get(t).value;return!ya(this,$)}},{key:"get",value:function(t){return Qa(this,t,!0)}},{key:"peek",value:function(t){return Qa(this,t,!1)}},{key:"pop",value:function(){var t=this[G].tail;return t?(ga(this,t),t.value):null}},{key:"del",value:function(t){ga(this,this[O].get(t))}},{key:"load",value:function(t){this.reset();for(var $=Date.now(),f=t.length-1;f>=0;f--){var r=t[f],e=r.e||0;if(0===e)this.set(r.k,r.v);else{var a=e-$;a>0&&this.set(r.k,r.v,a)}}}},{key:"prune",value:function(){var t=this;this[O].forEach(function($,f){return Qa(t,f,!1)})}}]),t}(),Qa=function(t,$,f){var r=t[O].get($);if(r){var e=r.value;if(ya(t,e)){if(ga(t,r),!t[la])return}else f&&(t[ib]&&(r.value.now=Date.now()),t[G].unshiftNode(r));return e.value}},ya=function(t,$){if(!$||!$.maxAge&&!t[_])return!1;var f=Date.now()-$.now;return $.maxAge?f>$.maxAge:t[_]&&f>t[_]},ma=function(t){if(t[T]>t[Z])for(var $=t[G].tail;t[T]>t[Z]&&null!==$;){var f=$.prev;ga(t,$),$=f}},ga=function(t,$){if($){var f=$.value;t[U]&&t[U](f.key,f.value),t[T]-=f.length,t[O].delete(f.key),t[G].removeNode($)}},Oc=function t($,f,r,e,a){fb(this,t),this.key=$,this.value=f,this.length=r,this.now=e,this.maxAge=a||0},jb=function(t,$,f,r){var e=f.value;ya(t,e)&&(ga(t,f),t[la]||(e=void 0)),e&&$.call(r,e.value,e.key,t)};Lc=Nc;var K={};function Pc(t){return Sc(t)||Rc(t)||lb(t)||Qc()}function Qc(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Rc(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function Sc(t){if(Array.isArray(t))return Ra(t)}function kb(t,r){var e="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=lb(t))||r&&t&&"number"==typeof t.length){e&&(t=e);var a=0,$=function(){};return{s:$,n:function(){return a>=t.length?{done:!0}:{done:!1,value:t[a++]}},e:function(t){throw t},f:$}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var n,c=!0,o=!1;return{s:function(){e=e.call(t)},n:function(){var t=e.next();return c=t.done,t},e:function(t){o=!0,n=t},f:function(){try{c||null==e.return||e.return()}finally{if(o)throw n}}}}function lb(t,r){if(t){if("string"==typeof t)return Ra(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);return"Object"===e&&t.constructor&&(e=t.constructor.name),"Map"===e||"Set"===e?Array.from(t):"Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?Ra(t,r):void 0}}function Ra(t,r){(null==r||r>t.length)&&(r=t.length);for(var e=0,a=new Array(r);e1){var $=this.set[0];if(this.set=this.set.filter(function(t){return!ob(t[0])}),0===this.set.length)this.set=[$];else if(this.set.length>1){var n,c=kb(this.set);try{for(c.s();!(n=c.n()).done;){var o=n.value;if(1===o.length&&Zc(o[0])){this.set=[o];break}}}catch(i){c.e(i)}finally{c.f()}}}this.format()}return Uc(t,[{key:"format",value:function(){return this.range=this.set.map(function(t){return t.join(" ").trim()}).join("||").trim(),this.range}},{key:"toString",value:function(){return this.range}},{key:"parseRange",value:function(t){var r=this;t=t.trim();var e=Object.keys(this.options).join(","),a="parseRange:".concat(e,":").concat(t),$=nb.get(a);if($)return $;var n=this.options.loose,c=n?I[H.HYPHENRANGELOOSE]:I[H.HYPHENRANGE];t=t.replace(c,id(this.options.includePrerelease)),C("hyphen replace",t),t=t.replace(I[H.COMPARATORTRIM],Wc),C("comparator trim",t,I[H.COMPARATORTRIM]),t=(t=(t=t.replace(I[H.TILDETRIM],Xc)).replace(I[H.CARETTRIM],Yc)).split(/\s+/).join(" ");var o,i=n?I[H.COMPARATORLOOSE]:I[H.COMPARATOR],d=t.split(" ").map(function(t){return $c(t,r.options)}).join(" ").split(/\s+/).map(function(t){return hd(t,r.options)}).filter(this.options.loose?function(t){return!!t.match(i)}:function(){return!0}).map(function(t){return new Q(t,r.options)}),s=(d.length,new Map),u=kb(d);try{for(u.s();!(o=u.n()).done;){var v=o.value;if(ob(v))return[v];s.set(v.value,v)}}catch(q){u.e(q)}finally{u.f()}s.size>1&&s.has("")&&s.delete("");var l=Pc(s.values());return nb.set(a,l),l}},{key:"intersects",value:function(r,e){if(!(r instanceof t))throw new TypeError("a Range is required");return this.set.some(function(t){return pb(t,e)&&r.set.some(function(r){return pb(r,e)&&t.every(function(t){return r.every(function(r){return t.intersects(r,e)})})})})}},{key:"test",value:function(t){if(!t)return!1;if("string"==typeof t)try{t=new D(t,this.options)}catch(e){return!1}for(var r=0;r=".concat(e,".").concat($,".0").concat(a," <").concat(e,".").concat(+$+1,".0-0"):">=".concat(e,".").concat($,".0").concat(a," <").concat(+e+1,".0.0-0"):c?(C("replaceCaret pr",c),o="0"===e?"0"===$?">=".concat(e,".").concat($,".").concat(n,"-").concat(c," <").concat(e,".").concat($,".").concat(+n+1,"-0"):">=".concat(e,".").concat($,".").concat(n,"-").concat(c," <").concat(e,".").concat(+$+1,".0-0"):">=".concat(e,".").concat($,".").concat(n,"-").concat(c," <").concat(+e+1,".0.0-0")):(C("no pr"),o="0"===e?"0"===$?">=".concat(e,".").concat($,".").concat(n).concat(a," <").concat(e,".").concat($,".").concat(+n+1,"-0"):">=".concat(e,".").concat($,".").concat(n).concat(a," <").concat(e,".").concat(+$+1,".0-0"):">=".concat(e,".").concat($,".").concat(n," <").concat(+e+1,".0.0-0")),C("caret return",o),o})},ed=function(t,r){return C("replaceXRanges",t,r),t.split(/\s+/).map(function(t){return fd(t,r)}).join(" ")},fd=function(t,r){t=t.trim();var e=r.loose?I[H.XRANGELOOSE]:I[H.XRANGE];return t.replace(e,function(e,a,$,n,c,o){C("xRange",t,e,a,$,n,c,o);var i=J($),d=i||J(n),s=d||J(c),u=s;return"="===a&&u&&(a=""),o=r.includePrerelease?"-0":"",i?e=">"===a||"<"===a?"<0.0.0-0":"*":a&&u?(d&&(n=0),c=0,">"===a?(a=">=",d?($=+$+1,n=0,c=0):(n=+n+1,c=0)):"<="===a&&(a="<",d?$=+$+1:n=+n+1),"<"===a&&(o="-0"),e="".concat(a+$,".").concat(n,".").concat(c).concat(o)):d?e=">=".concat($,".0.0").concat(o," <").concat(+$+1,".0.0-0"):s&&(e=">=".concat($,".").concat(n,".0").concat(o," <").concat($,".").concat(+n+1,".0-0")),C("xRange return",e),e})},gd=function(t,r){return C("replaceStars",t,r),t.trim().replace(I[H.STAR],"")},hd=function(t,r){return C("replaceGTE0",t,r),t.trim().replace(I[r.includePrerelease?H.GTE0PRE:H.GTE0],"")},id=function(t){return function(r,e,a,$,n,c,o,i,d,s,u,v,l){return e=J(a)?"":J($)?">=".concat(a,".0.0").concat(t?"-0":""):J(n)?">=".concat(a,".").concat($,".0").concat(t?"-0":""):c?">=".concat(e):">=".concat(e).concat(t?"-0":""),i=J(d)?"":J(s)?"<".concat(+d+1,".0.0-0"):J(u)?"<".concat(d,".").concat(+s+1,".0-0"):v?"<=".concat(d,".").concat(s,".").concat(u,"-").concat(v):t?"<".concat(d,".").concat(s,".").concat(+u+1,"-0"):"<=".concat(i),"".concat(e," ").concat(i).trim()}},jd=function(t,r,e){for(var a=0;a0){var n=t[$].semver;if(n.major===r.major&&n.minor===r.minor&&n.patch===r.patch)return!0}return!1}return!0};var Q={};function kd(r){return(kd="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(r){return typeof r}:function(r){return r&&"function"==typeof Symbol&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r})(r)}function ld(r,e){if(!(r instanceof e))throw new TypeError("Cannot call a class as a function")}function qb(r,e){for(var t=0;t="!==this.operator&&">"!==this.operator||">="!==e.operator&&">"!==e.operator),s=!("<="!==this.operator&&"<"!==this.operator||"<="!==e.operator&&"<"!==e.operator),a=this.semver.version===e.semver.version,$=!(">="!==this.operator&&"<="!==this.operator||">="!==e.operator&&"<="!==e.operator),i=ua(this.semver,"<",e.semver,t)&&(">="===this.operator||">"===this.operator)&&("<="===e.operator||"<"===e.operator),n=ua(this.semver,">",e.semver,t)&&("<="===this.operator||"<"===this.operator)&&(">="===e.operator||">"===e.operator);return o||s||a&&$||i||n}}],[{key:"ANY",get:function(){return na}}]),r}();Q=nd;var rb=ca,sb=da;var V={},od=function(a,$,r){try{$=new K($,r)}catch(e){return!1}return $.test(a)};V=od;var pd={},qd=function(r,$){return new K(r,$).set.map(function(r){return r.map(function(r){return r.value}).join(" ").trim().split(" ")})};pd=qd;var rd={},sd=function(r,$,e){var a=null,n=null,h=null;try{h=new K($,e)}catch(l){return null}return r.forEach(function(r){h.test(r)&&(a&&-1!==n.compare(r)||(n=new D(a=r,e)))}),a};rd=sd;var td={},ud=function(r,$,e){var a=null,c=null,n=null;try{n=new K($,e)}catch(l){return null}return r.forEach(function(r){n.test(r)&&(a&&1!==c.compare(r)||(c=new D(a=r,e)))}),a};td=ud;var vd={},wd=function(e,r){e=new K(e,r);var $=new D("0.0.0");if(e.test($))return $;if($=new D("0.0.0-0"),e.test($))return $;$=null;for(var a=function(r){var a=e.set[r],w=null;a.forEach(function(e){var r=new D(e.semver.version);switch(e.operator){case">":0===r.prerelease.length?r.patch++:r.prerelease.push(0),r.raw=r.format();case"":case">=":w&&!ea(r,w)||(w=r);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: ".concat(e.operator));}}),!w||$&&!ea($,w)||($=w)},w=0;w":t=ea,a=Oa,o=ta,m=">",n=">=";break;case"<":t=ta,a=Na,o=ea,m="<",n="<=";break;default:throw new TypeError("Must provide a hilo val of \"<\" or \">\"");}if(V(r,e,v))return!1;for(var s=function($){var s=e.set[$],i=null,P=null;return s.forEach(function(r){r.semver===Ad&&(r=new Q(">=0.0.0")),i=i||r,P=P||r,t(r.semver,i.semver,v)?i=r:o(r.semver,P.semver,v)&&(P=r)}),i.operator===m||i.operator===n?{v:!1}:P.operator&&P.operator!==m||!a(r,P.semver)?P.operator===n&&o(r,P.semver)?{v:!1}:void 0:{v:!1}},i=0;i",r)};Cd=Dd;var Ed={},Fd=function($,e,r){return Sa($,e,"<",r)};Ed=Fd;var Gd={},Hd=function($,n,e){return $=new K($,e),n=new K(n,e),$.intersects(n)};Gd=Hd;var Id={};function Jd(r,t){return Md(r)||Ld(r,t)||tb(r,t)||Kd()}function Kd(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Ld(r,t){var e=null==r?null:"undefined"!=typeof Symbol&&r[Symbol.iterator]||r["@@iterator"];if(null!=e){var n,a,o=[],i=!0,l=!1;try{for(e=e.call(r);!(i=(n=e.next()).done)&&(o.push(n.value),!t||o.length!==t);i=!0);}catch(f){l=!0,a=f}finally{try{i||null==e.return||e.return()}finally{if(l)throw a}}return o}}function Md(r){if(Array.isArray(r))return r}function Nd(r,t){var e="undefined"!=typeof Symbol&&r[Symbol.iterator]||r["@@iterator"];if(!e){if(Array.isArray(r)||(e=tb(r))||t&&r&&"number"==typeof r.length){e&&(r=e);var n=0,a=function(){};return{s:a,n:function(){return n>=r.length?{done:!0}:{done:!1,value:r[n++]}},e:function(r){throw r},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i=!0,l=!1;return{s:function(){e=e.call(r)},n:function(){var r=e.next();return i=r.done,r},e:function(r){l=!0,o=r},f:function(){try{i||null==e.return||e.return()}finally{if(l)throw o}}}}function tb(r,t){if(r){if("string"==typeof r)return ub(r,t);var e=Object.prototype.toString.call(r).slice(8,-1);return"Object"===e&&r.constructor&&(e=r.constructor.name),"Map"===e||"Set"===e?Array.from(r):"Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?ub(r,t):void 0}}function ub(r,t){(null==t||t>r.length)&&(t=r.length);for(var e=0,n=new Array(t);e=".concat(v)):$.push("*")}var h=$.join(" || "),L="string"==typeof t.raw?t.raw:String(t);return h.length=r.length?{done:!0}:{done:!1,value:r[t++]}},e:function(r){throw r},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,$=!0,u=!1;return{s:function(){a=a.call(r)},n:function(){var r=a.next();return $=r.done,r},e:function(r){u=!0,o=r},f:function(){try{$||null==a.return||a.return()}finally{if(u)throw o}}}}function Pd(r,e){if(r){if("string"==typeof r)return vb(r,e);var a=Object.prototype.toString.call(r).slice(8,-1);return"Object"===a&&r.constructor&&(a=r.constructor.name),"Map"===a||"Set"===a?Array.from(r):"Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?vb(r,e):void 0}}function vb(r,e){(null==e||e>r.length)&&(e=r.length);for(var a=0,t=new Array(e);a2&&void 0!==arguments[2]?arguments[2]:{};if(r===e)return!0;r=new K(r,a),e=new K(e,a);var t,n=!1,o=ha(r.set);try{r:for(o.s();!(t=o.n()).done;){var $,u=t.value,i=ha(e.set);try{for(i.s();!($=i.n()).done;){var s=$.value,v=Rd(u,s,a);if(n=n||null!==v,v)continue r}}catch(l){i.e(l)}finally{i.f()}if(n)return!1}}catch(l){o.e(l)}finally{o.f()}return!0},Rd=function(r,e,a){if(r===e)return!0;if(1===r.length&&r[0].semver===Ta){if(1===e.length&&e[0].semver===Ta)return!0;r=a.includePrerelease?[new Q(">=0.0.0-0")]:[new Q(">=0.0.0")]}if(1===e.length&&e[0].semver===Ta){if(a.includePrerelease)return!0;e=[new Q(">=0.0.0")]}var t,n,o,$,u=new Set,i=ha(r);try{for(i.s();!(o=i.n()).done;){var s=o.value;">"===s.operator||">="===s.operator?t=wb(t,s,a):"<"===s.operator||"<="===s.operator?n=xb(n,s,a):u.add(s.semver)}}catch(S){i.e(S)}finally{i.f()}if(u.size>1)return null;if(t&&n){if(($=N(t.semver,n.semver,a))>0)return null;if(0===$&&(">="!==t.operator||"<="!==n.operator))return null}var v,l,f,p,c,w=ha(u);try{for(w.s();!(v=w.n()).done;){var m=v.value;if(t&&!V(m,String(t),a))return null;if(n&&!V(m,String(n),a))return null;var q,E=ha(e);try{for(E.s();!(q=E.n()).done;){var y=q.value;if(!V(m,String(y),a))return!1}}catch(S){E.e(S)}finally{E.f()}return!0}}catch(S){w.e(S)}finally{w.f()}var h=!(!n||a.includePrerelease||!n.semver.prerelease.length)&&n.semver,g=!(!t||a.includePrerelease||!t.semver.prerelease.length)&&t.semver;h&&1===h.prerelease.length&&"<"===n.operator&&0===h.prerelease[0]&&(h=!1);var d,b=ha(e);try{for(b.s();!(d=b.n()).done;){var A=d.value;if(c=c||">"===A.operator||">="===A.operator,p=p||"<"===A.operator||"<="===A.operator,t)if(g&&A.semver.prerelease&&A.semver.prerelease.length&&A.semver.major===g.major&&A.semver.minor===g.minor&&A.semver.patch===g.patch&&(g=!1),">"===A.operator||">="===A.operator){if((l=wb(t,A,a))===A&&l!==t)return!1}else if(">="===t.operator&&!V(t.semver,String(A),a))return!1;if(n)if(h&&A.semver.prerelease&&A.semver.prerelease.length&&A.semver.major===h.major&&A.semver.minor===h.minor&&A.semver.patch===h.patch&&(h=!1),"<"===A.operator||"<="===A.operator){if((f=xb(n,A,a))===A&&f!==n)return!1}else if("<="===n.operator&&!V(n.semver,String(A),a))return!1;if(!A.operator&&(n||t)&&0!==$)return!1}}catch(S){b.e(S)}finally{b.f()}return!(t&&p&&!n&&0!==$)&&!(n&&c&&!t&&0!==$)&&!g&&!h},wb=function(r,e,a){if(!r)return e;var t=N(r.semver,e.semver,a);return t>0?r:t<0?e:">"===e.operator&&">="===r.operator?e:r},xb=function(r,e,a){if(!r)return e;var t=N(r.semver,e.semver,a);return t<0?r:t>0?e:"<"===e.operator&&"<="===r.operator?e:r};Od=Qd;Nb={re:ca,src:Hb,tokens:da,SEMVER_SPEC_VERSION:ia.SEMVER_SPEC_VERSION,SemVer:D,compareIdentifiers:Ka.compareIdentifiers,rcompareIdentifiers:Ka.rcompareIdentifiers,parse:X,valid:Xb,clean:Zb,inc:_b,diff:dc,major:fc,minor:hc,patch:jc,prerelease:lc,compare:N,rcompare:nc,compareLoose:pc,compareBuild:Ma,sort:sc,rsort:uc,gt:ea,lt:ta,eq:La,neq:eb,gte:Na,lte:Oa,cmp:ua,coerce:Cc,Comparator:Q,Range:K,satisfies:V,toComparators:pd,maxSatisfying:rd,minSatisfying:td,minVersion:vd,validRange:xd,outside:Sa,gtr:Cd,ltr:Ed,intersects:Gd,simplifyRange:Id,subset:Od};var za={data:function(){return{version:"",releaseInfo:0,hasVersionDiff:!1,hasError:!1}},created:function(){this.load()},computed:{},methods:{load:function(){var e=this;this.$api.get("komments/version").then(function(r){e.version=r.version}).then(function(){fetch("https://repo.packagist.org/p/mauricerenck/komments.json",{method:"GET"}).then(function(e){return e.json()}).then(function(r){"error"===r.status&&(e.hasError=!0),e.releaseInfo=e.version;var t=e.version;Object.keys(r.packages["mauricerenck/komments"]).sort().forEach(function(r){var $svGQ$$interop$default=yb(Nb);if(!$svGQ$$interop$default.d.valid(r))return!1;$svGQ$$interop$default.d.gt(r,t)&&(e.hasVersionDiff=$svGQ$$interop$default.d.gt(r,t),e.releaseInfo=r.toString())})}).catch(function(r){console.log("catch",r),e.hasError=!0})})}}};if(typeof za==="function"){za=za.options}Object.assign(za,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("div",{staticClass:"k-support"},[_vm.hasError?_c("div",{staticClass:"error"},[_c("k-info-field",{attrs:{"theme":"negative","label":"Ooops","text":"The current version could not be fetched. You may have reached an API limit"}})],1):_c("div",{staticClass:"versionBox"},[_vm.hasVersionDiff?_c("div",[_c("h4",{staticClass:"update-available"},[_vm._v("There is an update available")]),_vm._v(" "),_c("h3",{staticClass:"version"},[_vm._v(_vm._s(this.releaseInfo))])]):_c("div",[_c("h4",[_vm._v("Your Komments plugin is up to date")])]),_vm._v(" "),_c("small",{staticClass:"align-center"},[_vm._v("Your installed version is "+_vm._s(this.version))])])])};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var Aa={components:{QueuedKomments:pa,SpamKomments:qa,Support:za}};if(typeof Aa==="function"){Aa=Aa.options}Object.assign(Aa,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("k-view",{staticClass:"k-kommentviews-view"},[_c("k-header",[_vm._v("Komments")]),_vm._v(" "),_c("k-grid",{attrs:{"gutter":"large"}},[_c("k-column",{attrs:{"width":"2/4"}},[_c("k-headline-field",{attrs:{"label":"In moderation"}}),_vm._v(" "),_c("QueuedKomments")],1),_vm._v(" "),_c("k-column",{attrs:{"width":"1/4"}},[_c("k-headline-field",{attrs:{"label":"Marked as spam"}}),_vm._v(" "),_c("SpamKomments")],1),_vm._v(" "),_c("k-column",{attrs:{"width":"1/4"}},[_c("k-headline-field",{attrs:{"label":"Plugin"}}),_vm._v(" "),_c("Support")],1)],1)],1)};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var oa={data:function(){return{selectedKomment:{},kommentList:[]}},props:{title:String,queuedKomments:Array,version:Object},created:function(){this.kommentList=this.queuedKomments,this.selectKomment(this.kommentList[0].id),this.loadKomments()},methods:{loadKomments:function(){var t=this;this.$api.get("komments/queued").then(function(e){t.komments=e})},selectKomment:function(t){this.selectedKomment=this.queuedKomments.find(function(e){return e.id===t})},onMarkAsSpam:function(t){for(var e=0;e0},on:{"click":function($event){return _vm.markAsVerified(_vm.komment.slug,_vm.komment.id,true)}}},[_vm._v(" Verified ")]),_vm._v(" "),_vm.komment.spamlevel===0?_c("k-button",{attrs:{"icon":"toggle-off"},on:{"click":function($event){return _vm.markAsSpam(_vm.komment.slug,_vm.komment.id,true)}}},[_vm._v(" Spam ")]):_c("k-button",{attrs:{"theme":"negative","icon":"toggle-on"},on:{"click":function($event){return _vm.markAsSpam(_vm.komment.slug,_vm.komment.id,false)}}},[_vm._v(" Spam ")]),_vm._v(" "),_vm.komment.status===true?_c("k-button",{staticClass:"publish",attrs:{"theme":"positive","icon":"toggle-on"},on:{"click":function($event){return _vm.publish(_vm.komment.slug,_vm.komment.id,false)}}},[_vm._v(" Published ")]):_c("k-button",{staticClass:"publish",attrs:{"disabled":_vm.komment.spamlevel>0,"icon":"toggle-off"},on:{"click":function($event){return _vm.publish(_vm.komment.slug,_vm.komment.id,true)}}},[_vm._v(" Published ")])],1),_vm._v(" "),_c("template",{slot:"right"},[_c("k-button",{attrs:{"theme":"negative","icon":"trash"},on:{"click":function($event){return _vm.$refs.deleteDialog.open()}}},[_vm._v(" Delete ")]),_vm._v(" "),_c("k-dialog",{ref:"deleteDialog",attrs:{"button":"Delete","theme":"negative","icon":"trash"},on:{"submit":function($event){return _vm.deleteKomment(_vm.komment.slug,_vm.komment.id,_vm.$refs)}}},[_c("k-text",[_vm._v(" Do you really want to delete the comment? This cannot be undone. ")])],1)],1)],2)],1),_vm._v(" "),_c("div",{staticClass:"text"},[_vm._v(" "+_vm._s(_vm.komment.komment)+" ")])],1)};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var Ca={props:{queuedKomments:Array,onSelectKomment:Function,selectedKomment:Object},methods:{}};if(typeof Ca==="function"){Ca=Ca.options}Object.assign(Ca,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("div",{staticClass:"komments-list"},[_c("ul",_vm._l(_vm.queuedKomments,function(komment,index){return _c("li",{key:index,staticClass:"list-item",class:{active:_vm.selectedKomment.id===komment.id,isSpam:komment.spamlevel>0,isVerified:komment.verified===true},on:{"click":function($event){return _vm.onSelectKomment(komment.id)},"keypress":function($event){return _vm.onSelectKomment(komment.id)}}},[_c("k-grid",[_c("k-column",{staticClass:"avatar",attrs:{"width":"2/12"}},[komment.image?_c("img",{attrs:{"src":komment.image}}):_vm._e()]),_vm._v(" "),_c("k-column",{attrs:{"width":"10/12"}},[_c("div",{staticClass:"komment-preview"},[_c("div",{staticClass:"author"},[_c("strong",[_vm._v(_vm._s(komment.author))])]),_vm._v(" "),_c("div",{staticClass:"meta"},[_vm._v(_vm._s(komment.published)+" - "+_vm._s(komment.title))]),_vm._v(" "),_c("div",{staticClass:"preview"},[_vm._v(" "+_vm._s(komment.komment.substr(0,60)+"\u2026")+" ")])])]),_vm._v(" "),_c("k-column",{attrs:{"width":"2/12"}}),_vm._v(" "),_c("k-column",{attrs:{"width":"10/12"}},[_c("div",{staticClass:"status"},[komment.status===false?_c("span",{staticClass:"badge",attrs:{"alt":"pending","title":"pending"}},[_vm._v(" pending ")]):komment.status===true?_c("span",{staticClass:"badge blue",attrs:{"alt":"published","title":"published"}},[_vm._v(" published ")]):_vm._e(),_vm._v(" "),komment.verified===true?_c("span",{staticClass:"badge green",attrs:{"alt":"Verified user","title":"Verified user"}},[_vm._v(" verified ")]):_vm._e(),_vm._v(" "),komment.spamlevel>0?_c("span",{staticClass:"badge red",attrs:{"alt":"Possible spam comment","title":"Possible spam comment"}},[_vm._v(" spam ")]):_vm._e()])])],1)],1)}),0)])};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var Da={props:{version:Object}};if(typeof Da==="function"){Da=Da.options}Object.assign(Da,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("div",[_vm.version.error?_c("div",{staticClass:"error"},[_c("k-info-field",{attrs:{"theme":"negative","label":"Sorry","text":"The current version could not be fetched."}})],1):_c("div",{staticClass:"version-box"},[_vm.version.updateAvailable?_c("div",[_c("h4",{staticClass:"update-available"},[_vm._v("There is an update available")]),_vm._v(" "),_c("h3",{staticClass:"version"},[_vm._v(_vm._s(_vm.version.latest))])]):_c("div",[_c("h4",[_vm._v("This plugin is up to date")])]),_vm._v(" "),_c("small",{staticClass:"align-center"},[_vm._v(" Your installed version is "+_vm._s(_vm.version.local)+" ")])])])};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());var Ea={props:{queuedComments:Number}};if(typeof Ea==="function"){Ea=Ea.options}Object.assign(Ea,function(){var render=function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c("div",{staticClass:"kommentsPendingCounter"},[_c("k-headline",[_vm._v("Pending Comments")]),_vm._v(" "),_c("div",{staticClass:"count"},[_vm._v(_vm._s(_vm.queuedComments))])],1)};var staticRenderFns=[];return{render:render,staticRenderFns:staticRenderFns,_compiled:true,_scopeId:null,functional:undefined}}());panel.plugin("mauricerenck/komments",{components:{"k-komments-view":oa,KommentDetails:Ba,KommentList:Ca,KommentVersion:Da},fields:{komments:oa,kommentsPending:Ea},views:{queuedKommments:{component:Aa,icon:"chat",label:"Komments"}}});})(); \ No newline at end of file diff --git a/package.json b/package.json index 0e55331..0b20abc 100644 --- a/package.json +++ b/package.json @@ -1,27 +1,27 @@ { - "name": "komments", - "version": "1.0.0", - "description": "A comment and webmention plugin for Kirby 3", - "main": "index.js", - "author": "Maurice Renck", - "scripts": { - "dev": "parcel watch src/index.js --no-source-maps -d ./", - "build": "parcel build src/index.js --no-source-maps --experimental-scope-hoisting -d ./", - "build-css": "sass src/komments.scss assets/komments.css" - }, - "posthtml": { - "recognizeSelfClosing": true - }, - "dependencies": { - "semver": "^7.3.4", - "vue": "^2.6.11", - "vue-hot-reload-api": "^2.3.4" - }, - "devDependencies": { - "@vue/component-compiler-utils": "^3.1.2", - "cssnano": "^4.1.10", - "sass": "^1.32.6", - "stylus": "^0.54.7", - "vue-template-compiler": "^2.6.11" - } + "name": "komments", + "version": "1.0.1", + "description": "A comment and webmention plugin for Kirby 3", + "main": "index.js", + "author": "Maurice Renck", + "scripts": { + "dev": "parcel watch src/index.js --no-source-maps -d ./", + "build": "parcel build src/index.js --no-source-maps --experimental-scope-hoisting -d ./", + "build-css": "sass src/komments.scss assets/komments.css" + }, + "posthtml": { + "recognizeSelfClosing": true + }, + "dependencies": { + "semver": "^7.3.4", + "vue": "^2.6.11", + "vue-hot-reload-api": "^2.3.4" + }, + "devDependencies": { + "@vue/component-compiler-utils": "^3.1.2", + "cssnano": "^4.1.10", + "sass": "^1.32.6", + "stylus": "^0.54.7", + "vue-template-compiler": "^2.6.11" + } } diff --git a/src/components/views/Komments.vue b/src/components/views/Komments.vue index ef109fe..ece15d8 100644 --- a/src/components/views/Komments.vue +++ b/src/components/views/Komments.vue @@ -1,34 +1,36 @@