From d0d26287411cbf05bbb468a0ac25ac92c3fc2e35 Mon Sep 17 00:00:00 2001 From: iOS Date: Tue, 6 Sep 2022 08:49:04 +0200 Subject: [PATCH] lotr init --- .obsidian/community-plugins.json | 3 +- .../obsidian-activity-history/data.json | 14 +- .../plugins/obsidian-admonition/data.json | 2 +- .obsidian/plugins/obsidian-admonition/main.js | 2 +- .../plugins/obsidian-admonition/manifest.json | 2 +- .obsidian/plugins/obsidian-commits/data.json | 199 +++++++++++------- .../obsidian-reminder-plugin/data.json | 25 ++- .../plugins/obsidian-task-completer/main.js | 8 + .../obsidian-task-completer/manifest.json | 1 + .../plugins/obsidian-tasks-plugin/main.js | 39 ++-- .../obsidian-tasks-plugin/manifest.json | 2 +- .../plugins/obsidian-tasks-plugin/styles.css | 1 + .obsidian/plugins/obsidian42-brat/data.json | 5 +- .obsidian/plugins/podnotes/data.json | 56 ++++- .../plugins/templater-obsidian/data.json | 3 +- .obsidian/workspace | 30 ++- 00.01 Admin/Calendars/2022-09-04.md | 6 +- 00.01 Admin/Calendars/2022-09-05.md | 112 ++++++++++ 00.01 Admin/Calendars/2022-09-06.md | 111 ++++++++++ 00.01 Admin/Test sheet.md | 98 +-------- ... Gogh Color Blind It Sure Looks Like It.md | 71 +++++++ 01.02 Home/@Shopping list.md | 10 +- 01.02 Home/Cinematheque.md | 2 +- 01.02 Home/Household.md | 3 +- 01.03 Family/Ophélie Bédier.md | 3 +- 03.03 Food & Wine/@@Recipes.md | 6 +- 03.03 Food & Wine/Hoppin' John.md | 2 +- 03.03 Food & Wine/Lamb Siniyah.md | 2 +- 03.04 Cinematheque/Men in Black (1997).md | 94 +++++++++ 03.04 Cinematheque/Men in Black 3 (2012).md | 94 +++++++++ 03.04 Cinematheque/Men in Black II (2002).md | 93 ++++++++ ...ngs - The Fellowship of the Ring (2001).md | 93 ++++++++ ...e Rings - The Return of the King (2003).md | 93 ++++++++ ...rd of the Rings - The Two Towers (2002).md | 93 ++++++++ 34 files changed, 1129 insertions(+), 249 deletions(-) create mode 100644 .obsidian/plugins/obsidian-task-completer/main.js create mode 100644 .obsidian/plugins/obsidian-task-completer/manifest.json create mode 100644 00.01 Admin/Calendars/2022-09-05.md create mode 100644 00.01 Admin/Calendars/2022-09-06.md create mode 100644 00.03 News/Was Vincent van Gogh Color Blind It Sure Looks Like It.md create mode 100644 03.04 Cinematheque/Men in Black (1997).md create mode 100644 03.04 Cinematheque/Men in Black 3 (2012).md create mode 100644 03.04 Cinematheque/Men in Black II (2002).md create mode 100644 03.04 Cinematheque/The Lord of the Rings - The Fellowship of the Ring (2001).md create mode 100644 03.04 Cinematheque/The Lord of the Rings - The Return of the King (2003).md create mode 100644 03.04 Cinematheque/The Lord of the Rings - The Two Towers (2002).md diff --git a/.obsidian/community-plugins.json b/.obsidian/community-plugins.json index 4657cc28..f1bab196 100644 --- a/.obsidian/community-plugins.json +++ b/.obsidian/community-plugins.json @@ -60,5 +60,6 @@ "obsidian-smart-typography", "podnotes", "emoji-shortcodes", - "obsidian-banners" + "obsidian-banners", + "obsidian-task-completer" ] \ No newline at end of file diff --git a/.obsidian/plugins/obsidian-activity-history/data.json b/.obsidian/plugins/obsidian-activity-history/data.json index ee680c9e..cebe883a 100644 --- a/.obsidian/plugins/obsidian-activity-history/data.json +++ b/.obsidian/plugins/obsidian-activity-history/data.json @@ -12,8 +12,8 @@ "checkpointList": [ { "path": "/", - "date": "2022-09-04", - "size": 6900372 + "date": "2022-09-06", + "size": 6918154 } ], "activityHistory": [ @@ -970,7 +970,15 @@ }, { "date": "2022-09-04", - "value": 5957 + "value": 8414 + }, + { + "date": "2022-09-05", + "value": 18836 + }, + { + "date": "2022-09-06", + "value": 1045 } ] } diff --git a/.obsidian/plugins/obsidian-admonition/data.json b/.obsidian/plugins/obsidian-admonition/data.json index 7f322f00..554f5911 100644 --- a/.obsidian/plugins/obsidian-admonition/data.json +++ b/.obsidian/plugins/obsidian-admonition/data.json @@ -106,7 +106,7 @@ }, "syntaxHighlight": false, "copyButton": true, - "version": "9.0.4", + "version": "9.0.5", "autoCollapse": false, "defaultCollapseType": "open", "injectColor": true, diff --git a/.obsidian/plugins/obsidian-admonition/main.js b/.obsidian/plugins/obsidian-admonition/main.js index 9134118d..772c12bb 100644 --- a/.obsidian/plugins/obsidian-admonition/main.js +++ b/.obsidian/plugins/obsidian-admonition/main.js @@ -5,7 +5,7 @@ if you want to view the source, please visit the github repository of this plugi var c6=Object.create;var X1=Object.defineProperty;var a6=Object.getOwnPropertyDescriptor;var e6=Object.getOwnPropertyNames;var i6=Object.getPrototypeOf,n6=Object.prototype.hasOwnProperty;var p4=a=>X1(a,"__esModule",{value:!0});var o6=(a,c)=>{p4(a);for(var e in c)X1(a,e,{get:c[e],enumerable:!0})},t6=(a,c,e)=>{if(c&&typeof c=="object"||typeof c=="function")for(let i of e6(c))!n6.call(a,i)&&i!=="default"&&X1(a,i,{get:()=>c[i],enumerable:!(e=a6(c,i))||e.enumerable});return a},J=a=>t6(p4(X1(a!=null?c6(i6(a)):{},"default",a&&a.__esModule&&"default"in a?{get:()=>a.default,enumerable:!0}:{value:a,enumerable:!0})),a);o6(exports,{default:()=>r4});var x=J(require("obsidian"));var d4=J(require("obsidian")),g2=J(require("obsidian"));function r6(a,c){for(let e=0;e=0}function R(a){return((n1(a)?a.ownerDocument:a.document)||window.document).documentElement}function o1(a){return O(a)==="html"?a:a.assignedSlot||a.parentNode||(i2(a)?a.host:null)||R(a)}function A4(a){return!B(a)||j(a).position==="fixed"?null:a.offsetParent}function C6(a){var c=navigator.userAgent.toLowerCase().indexOf("firefox")!==-1,e=navigator.userAgent.indexOf("Trident")!==-1;if(e&&B(a)){var i=j(a);if(i.position==="fixed")return null}for(var n=o1(a);B(n)&&["html","body"].indexOf(O(n))<0;){var o=j(n);if(o.transform!=="none"||o.perspective!=="none"||o.contain==="paint"||["transform","perspective"].indexOf(o.willChange)!==-1||c&&o.willChange==="filter"||c&&o.filter&&o.filter!=="none")return n;n=n.parentNode}return null}function X(a){for(var c=w(a),e=A4(a);e&&L2(e)&&j(e).position==="static";)e=A4(e);return e&&(O(e)==="html"||O(e)==="body"&&j(e).position==="static")?c:e||C6(a)||c}function p1(a){return["top","bottom"].indexOf(a)>=0?"x":"y"}var $=Math.max,f1=Math.min,O1=Math.round;function d1(a,c,e){return $(a,f1(c,e))}function I1(){return{top:0,right:0,bottom:0,left:0}}function B1(a){return Object.assign({},I1(),a)}function R1(a,c){return c.reduce(function(e,i){return e[i]=a,e},{})}var H6=function(c,e){return c=typeof c=="function"?c(Object.assign({},e.rects,{placement:e.placement})):c,B1(typeof c!="number"?c:R1(c,l1))};function g6(a){var c,e=a.state,i=a.name,n=a.options,o=e.elements.arrow,r=e.modifiersData.popperOffsets,t=I(e.placement),l=p1(t),f=[P,T].indexOf(t)>=0,s=f?"height":"width";if(!(!o||!r)){var h=H6(n.padding,e),m=z1(o),z=l==="y"?k:P,v=l==="y"?D:T,M=e.rects.reference[s]+e.rects.reference[l]-r[l]-e.rects.popper[s],p=r[l]-e.rects.reference[l],C=X(o),H=C?l==="y"?C.clientHeight||0:C.clientWidth||0:0,L=M/2-p/2,d=h[z],N=H-m[s]-h[v],V=H/2-m[s]/2+L,y=d1(d,V,N),A=l;e.modifiersData[i]=(c={},c[A]=y,c.centerOffset=y-V,c)}}function V6(a){var c=a.state,e=a.options,i=e.element,n=i===void 0?"[data-popper-arrow]":i;n!=null&&(typeof n=="string"&&(n=c.elements.popper.querySelector(n),!n)||!D1(c.elements.popper,n)||(c.elements.arrow=n))}var y4={name:"arrow",enabled:!0,phase:"main",fn:g6,effect:V6,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};var L6={top:"auto",right:"auto",bottom:"auto",left:"auto"};function x6(a){var c=a.x,e=a.y,i=window,n=i.devicePixelRatio||1;return{x:O1(O1(c*n)/n)||0,y:O1(O1(e*n)/n)||0}}function S4(a){var c,e=a.popper,i=a.popperRect,n=a.placement,o=a.offsets,r=a.position,t=a.gpuAcceleration,l=a.adaptive,f=a.roundOffsets,s=f===!0?x6(o):typeof f=="function"?f(o):o,h=s.x,m=h===void 0?0:h,z=s.y,v=z===void 0?0:z,M=o.hasOwnProperty("x"),p=o.hasOwnProperty("y"),C=P,H=k,L=window;if(l){var d=X(e),N="clientHeight",V="clientWidth";d===w(e)&&(d=R(e),j(d).position!=="static"&&(N="scrollHeight",V="scrollWidth")),d=d,n===k&&(H=D,v-=d[N]-i.height,v*=t?1:-1),n===P&&(C=T,m-=d[V]-i.width,m*=t?1:-1)}var y=Object.assign({position:r},l&&L6);if(t){var A;return Object.assign({},y,(A={},A[H]=p?"0":"",A[C]=M?"0":"",A.transform=(L.devicePixelRatio||1)<2?"translate("+m+"px, "+v+"px)":"translate3d("+m+"px, "+v+"px, 0)",A))}return Object.assign({},y,(c={},c[H]=p?v+"px":"",c[C]=M?m+"px":"",c.transform="",c))}function b6(a){var c=a.state,e=a.options,i=e.gpuAcceleration,n=i===void 0?!0:i,o=e.adaptive,r=o===void 0?!0:o,t=e.roundOffsets,l=t===void 0?!0:t;if(!1)var f;var s={placement:I(c.placement),popper:c.elements.popper,popperRect:c.rects.popper,gpuAcceleration:n};c.modifiersData.popperOffsets!=null&&(c.styles.popper=Object.assign({},c.styles.popper,S4(Object.assign({},s,{offsets:c.modifiersData.popperOffsets,position:c.options.strategy,adaptive:r,roundOffsets:l})))),c.modifiersData.arrow!=null&&(c.styles.arrow=Object.assign({},c.styles.arrow,S4(Object.assign({},s,{offsets:c.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),c.attributes.popper=Object.assign({},c.attributes.popper,{"data-popper-placement":c.placement})}var w4={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:b6,data:{}};var n2={passive:!0};function N6(a){var c=a.state,e=a.instance,i=a.options,n=i.scroll,o=n===void 0?!0:n,r=i.resize,t=r===void 0?!0:r,l=w(c.elements.popper),f=[].concat(c.scrollParents.reference,c.scrollParents.popper);return o&&f.forEach(function(s){s.addEventListener("scroll",e.update,n2)}),t&&l.addEventListener("resize",e.update,n2),function(){o&&f.forEach(function(s){s.removeEventListener("scroll",e.update,n2)}),t&&l.removeEventListener("resize",e.update,n2)}}var k4={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:N6,data:{}};var A6={left:"right",right:"left",bottom:"top",top:"bottom"};function S1(a){return a.replace(/left|right|bottom|top/g,function(c){return A6[c]})}var y6={start:"end",end:"start"};function o2(a){return a.replace(/start|end/g,function(c){return y6[c]})}function u1(a){var c=w(a),e=c.pageXOffset,i=c.pageYOffset;return{scrollLeft:e,scrollTop:i}}function M1(a){return _(R(a)).left+u1(a).scrollLeft}function x2(a){var c=w(a),e=R(a),i=c.visualViewport,n=e.clientWidth,o=e.clientHeight,r=0,t=0;return i&&(n=i.width,o=i.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(r=i.offsetLeft,t=i.offsetTop)),{width:n,height:o,x:r+M1(a),y:t}}function b2(a){var c,e=R(a),i=u1(a),n=(c=a.ownerDocument)==null?void 0:c.body,o=$(e.scrollWidth,e.clientWidth,n?n.scrollWidth:0,n?n.clientWidth:0),r=$(e.scrollHeight,e.clientHeight,n?n.scrollHeight:0,n?n.clientHeight:0),t=-i.scrollLeft+M1(a),l=-i.scrollTop;return j(n||e).direction==="rtl"&&(t+=$(e.clientWidth,n?n.clientWidth:0)-o),{width:o,height:r,x:t,y:l}}function C1(a){var c=j(a),e=c.overflow,i=c.overflowX,n=c.overflowY;return/auto|scroll|overlay|hidden/.test(e+n+i)}function t2(a){return["html","body","#document"].indexOf(O(a))>=0?a.ownerDocument.body:B(a)&&C1(a)?a:t2(o1(a))}function s1(a,c){var e;c===void 0&&(c=[]);var i=t2(a),n=i===((e=a.ownerDocument)==null?void 0:e.body),o=w(i),r=n?[o].concat(o.visualViewport||[],C1(i)?i:[]):i,t=c.concat(r);return n?t:t.concat(s1(o1(r)))}function w1(a){return Object.assign({},a,{left:a.x,top:a.y,right:a.x+a.width,bottom:a.y+a.height})}function S6(a){var c=_(a);return c.top=c.top+a.clientTop,c.left=c.left+a.clientLeft,c.bottom=c.top+a.clientHeight,c.right=c.left+a.clientWidth,c.width=a.clientWidth,c.height=a.clientHeight,c.x=c.left,c.y=c.top,c}function T4(a,c){return c===a2?w1(x2(a)):B(c)?S6(c):w1(b2(R(a)))}function w6(a){var c=s1(o1(a)),e=["absolute","fixed"].indexOf(j(a).position)>=0,i=e&&B(a)?X(a):a;return n1(i)?c.filter(function(n){return n1(n)&&D1(n,i)&&O(n)!=="body"}):[]}function N2(a,c,e){var i=c==="clippingParents"?w6(a):[].concat(c),n=[].concat(i,[e]),o=n[0],r=n.reduce(function(t,l){var f=T4(a,l);return t.top=$(f.top,t.top),t.right=f1(f.right,t.right),t.bottom=f1(f.bottom,t.bottom),t.left=$(f.left,t.left),t},T4(a,o));return r.width=r.right-r.left,r.height=r.bottom-r.top,r.x=r.left,r.y=r.top,r}function c1(a){return a.split("-")[1]}function F1(a){var c=a.reference,e=a.element,i=a.placement,n=i?I(i):null,o=i?c1(i):null,r=c.x+c.width/2-e.width/2,t=c.y+c.height/2-e.height/2,l;switch(n){case k:l={x:r,y:c.y-e.height};break;case D:l={x:r,y:c.y+c.height};break;case T:l={x:c.x+c.width,y:t};break;case P:l={x:c.x-e.width,y:t};break;default:l={x:c.x,y:c.y}}var f=n?p1(n):null;if(f!=null){var s=f==="y"?"height":"width";switch(o){case i1:l[f]=l[f]-(c[s]/2-e[s]/2);break;case c2:l[f]=l[f]+(c[s]/2-e[s]/2);break;default:}}return l}function K(a,c){c===void 0&&(c={});var e=c,i=e.placement,n=i===void 0?a.placement:i,o=e.boundary,r=o===void 0?L4:o,t=e.rootBoundary,l=t===void 0?a2:t,f=e.elementContext,s=f===void 0?y1:f,h=e.altBoundary,m=h===void 0?!1:h,z=e.padding,v=z===void 0?0:z,M=B1(typeof v!="number"?v:R1(v,l1)),p=s===y1?x4:y1,C=a.elements.reference,H=a.rects.popper,L=a.elements[m?p:s],d=N2(n1(L)?L:L.contextElement||R(a.elements.popper),r,l),N=_(C),V=F1({reference:N,element:H,strategy:"absolute",placement:n}),y=w1(Object.assign({},H,V)),A=s===y1?y:N,E={top:d.top-A.top+M.top,bottom:A.bottom-d.bottom+M.bottom,left:d.left-A.left+M.left,right:A.right-d.right+M.right},S=a.modifiersData.offset;if(s===y1&&S){var Z=S[n];Object.keys(E).forEach(function(e1){var W=[T,D].indexOf(e1)>=0?1:-1,h1=[k,D].indexOf(e1)>=0?"y":"x";E[e1]+=Z[h1]*W})}return E}function A2(a,c){c===void 0&&(c={});var e=c,i=e.placement,n=e.boundary,o=e.rootBoundary,r=e.padding,t=e.flipVariations,l=e.allowedAutoPlacements,f=l===void 0?e2:l,s=c1(i),h=s?t?V2:V2.filter(function(v){return c1(v)===s}):l1,m=h.filter(function(v){return f.indexOf(v)>=0});m.length===0&&(m=h);var z=m.reduce(function(v,M){return v[M]=K(a,{placement:M,boundary:n,rootBoundary:o,padding:r})[I(M)],v},{});return Object.keys(z).sort(function(v,M){return z[v]-z[M]})}function k6(a){if(I(a)===J1)return[];var c=S1(a);return[o2(a),c,o2(c)]}function T6(a){var c=a.state,e=a.options,i=a.name;if(!c.modifiersData[i]._skip){for(var n=e.mainAxis,o=n===void 0?!0:n,r=e.altAxis,t=r===void 0?!0:r,l=e.fallbackPlacements,f=e.padding,s=e.boundary,h=e.rootBoundary,m=e.altBoundary,z=e.flipVariations,v=z===void 0?!0:z,M=e.allowedAutoPlacements,p=c.options.placement,C=I(p),H=C===p,L=l||(H||!v?[S1(p)]:k6(p)),d=[p].concat(L).reduce(function(v1,Q){return v1.concat(I(Q)===J1?A2(c,{placement:Q,boundary:s,rootBoundary:h,padding:f,flipVariations:v,allowedAutoPlacements:M}):Q)},[]),N=c.rects.reference,V=c.rects.popper,y=new Map,A=!0,E=d[0],S=0;S=0,T1=h1?"width":"height",x1=K(c,{placement:Z,boundary:s,rootBoundary:h,altBoundary:m,padding:f}),m1=h1?W?T:P:W?D:k;N[T1]>V[T1]&&(m1=S1(m1));var u2=S1(m1),b1=[];if(o&&b1.push(x1[e1]<=0),t&&b1.push(x1[m1]<=0,x1[u2]<=0),b1.every(function(v1){return v1})){E=Z,A=!1;break}y.set(Z,b1)}if(A)for(var G1=v?3:1,M2=function(Q){var $1=d.find(function(C2){var A1=y.get(C2);if(A1)return A1.slice(0,Q).every(function(H2){return H2})});if($1)return E=$1,"break"},N1=G1;N1>0;N1--){var _1=M2(N1);if(_1==="break")break}c.placement!==E&&(c.modifiersData[i]._skip=!0,c.placement=E,c.reset=!0)}}var P4={name:"flip",enabled:!0,phase:"main",fn:T6,requiresIfExists:["offset"],data:{_skip:!1}};function E4(a,c,e){return e===void 0&&(e={x:0,y:0}),{top:a.top-c.height-e.y,right:a.right-c.width+e.x,bottom:a.bottom-c.height+e.y,left:a.left-c.width-e.x}}function D4(a){return[k,T,D,P].some(function(c){return a[c]>=0})}function P6(a){var c=a.state,e=a.name,i=c.rects.reference,n=c.rects.popper,o=c.modifiersData.preventOverflow,r=K(c,{elementContext:"reference"}),t=K(c,{altBoundary:!0}),l=E4(r,i),f=E4(t,n,o),s=D4(l),h=D4(f);c.modifiersData[e]={referenceClippingOffsets:l,popperEscapeOffsets:f,isReferenceHidden:s,hasPopperEscaped:h},c.attributes.popper=Object.assign({},c.attributes.popper,{"data-popper-reference-hidden":s,"data-popper-escaped":h})}var O4={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:P6};function E6(a,c,e){var i=I(a),n=[P,k].indexOf(i)>=0?-1:1,o=typeof e=="function"?e(Object.assign({},c,{placement:a})):e,r=o[0],t=o[1];return r=r||0,t=(t||0)*n,[P,T].indexOf(i)>=0?{x:t,y:r}:{x:r,y:t}}function D6(a){var c=a.state,e=a.options,i=a.name,n=e.offset,o=n===void 0?[0,0]:n,r=e2.reduce(function(s,h){return s[h]=E6(h,c.rects,o),s},{}),t=r[c.placement],l=t.x,f=t.y;c.modifiersData.popperOffsets!=null&&(c.modifiersData.popperOffsets.x+=l,c.modifiersData.popperOffsets.y+=f),c.modifiersData[i]=r}var I4={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:D6};function O6(a){var c=a.state,e=a.name;c.modifiersData[e]=F1({reference:c.rects.reference,element:c.rects.popper,strategy:"absolute",placement:c.placement})}var B4={name:"popperOffsets",enabled:!0,phase:"read",fn:O6,data:{}};function y2(a){return a==="x"?"y":"x"}function I6(a){var c=a.state,e=a.options,i=a.name,n=e.mainAxis,o=n===void 0?!0:n,r=e.altAxis,t=r===void 0?!1:r,l=e.boundary,f=e.rootBoundary,s=e.altBoundary,h=e.padding,m=e.tether,z=m===void 0?!0:m,v=e.tetherOffset,M=v===void 0?0:v,p=K(c,{boundary:l,rootBoundary:f,padding:h,altBoundary:s}),C=I(c.placement),H=c1(c.placement),L=!H,d=p1(C),N=y2(d),V=c.modifiersData.popperOffsets,y=c.rects.reference,A=c.rects.popper,E=typeof M=="function"?M(Object.assign({},c.rects,{placement:c.placement})):M,S={x:0,y:0};if(!!V){if(o||t){var Z=d==="y"?k:P,e1=d==="y"?D:T,W=d==="y"?"height":"width",h1=V[d],T1=V[d]+p[Z],x1=V[d]-p[e1],m1=z?-A[W]/2:0,u2=H===i1?y[W]:A[W],b1=H===i1?-A[W]:-y[W],G1=c.elements.arrow,M2=z&&G1?z1(G1):{width:0,height:0},N1=c.modifiersData["arrow#persistent"]?c.modifiersData["arrow#persistent"].padding:I1(),_1=N1[Z],v1=N1[e1],Q=d1(0,y[W],M2[W]),$1=L?y[W]/2-m1-Q-_1-E:u2-Q-_1-E,C2=L?-y[W]/2+m1+Q+v1+E:b1+Q+v1+E,A1=c.elements.arrow&&X(c.elements.arrow),H2=A1?d==="y"?A1.clientTop||0:A1.clientLeft||0:0,l4=c.modifiersData.offset?c.modifiersData.offset[c.placement][d]:0,f4=V[d]+$1-l4-H2,s4=V[d]+C2-l4;if(o){var h4=d1(z?f1(T1,f4):T1,h1,z?$(x1,s4):x1);V[d]=h4,S[d]=h4-h1}if(t){var Q3=d==="x"?k:P,J3=d==="x"?D:T,Y1=V[N],m4=Y1+p[Q3],v4=Y1-p[J3],z4=d1(z?f1(m4,f4):m4,Y1,z?$(v4,s4):v4);V[N]=z4,S[N]=z4-Y1}}c.modifiersData[i]=S}}var R4={name:"preventOverflow",enabled:!0,phase:"main",fn:I6,requiresIfExists:["offset"]};function S2(a){return{scrollLeft:a.scrollLeft,scrollTop:a.scrollTop}}function w2(a){return a===w(a)||!B(a)?u1(a):S2(a)}function k2(a,c,e){e===void 0&&(e=!1);var i=R(c),n=_(a),o=B(c),r={scrollLeft:0,scrollTop:0},t={x:0,y:0};return(o||!o&&!e)&&((O(c)!=="body"||C1(i))&&(r=w2(c)),B(c)?(t=_(c),t.x+=c.clientLeft,t.y+=c.clientTop):i&&(t.x=M1(i))),{x:n.left+r.scrollLeft-t.x,y:n.top+r.scrollTop-t.y,width:n.width,height:n.height}}function B6(a){var c=new Map,e=new Set,i=[];a.forEach(function(o){c.set(o.name,o)});function n(o){e.add(o.name);var r=[].concat(o.requires||[],o.requiresIfExists||[]);r.forEach(function(t){if(!e.has(t)){var l=c.get(t);l&&n(l)}}),i.push(o)}return a.forEach(function(o){e.has(o.name)||n(o)}),i}function T2(a){var c=B6(a);return b4.reduce(function(e,i){return e.concat(c.filter(function(n){return n.phase===i}))},[])}function P2(a){var c;return function(){return c||(c=new Promise(function(e){Promise.resolve().then(function(){c=void 0,e(a())})})),c}}function E2(a){var c=a.reduce(function(e,i){var n=e[i.name];return e[i.name]=n?Object.assign({},n,i,{options:Object.assign({},n.options,i.options),data:Object.assign({},n.data,i.data)}):i,e},{});return Object.keys(c).map(function(e){return c[e]})}var F4={placement:"bottom",modifiers:[],strategy:"absolute"};function Z4(){for(var a=arguments.length,c=new Array(a),e=0;e(this.setSelectedItem(this.selectedItem-1,!0),!1)),i.register([],"ArrowDown",()=>(this.setSelectedItem(this.selectedItem+1,!0),!1)),i.register([],"Enter",n=>(this.useSelectedItem(n),!1)),i.register([],"Tab",n=>(this.useSelectedItem(n),!1))}chooseSuggestion(c){if(!this.items||!this.items.length)return;let e=this.items[this.selectedItem];e&&this.owner.selectSuggestion(e,c)}onSuggestionClick(c,e){if(c.preventDefault(),!this.suggestions||!this.suggestions.length)return;let i=this.suggestions.indexOf(e);this.setSelectedItem(i,!1),this.useSelectedItem(c)}onSuggestionMouseover(c,e){if(!this.suggestions||!this.suggestions.length)return;let i=this.suggestions.indexOf(e);this.setSelectedItem(i,!1)}empty(){this.containerEl.empty()}setSuggestions(c){this.containerEl.empty();let e=[];c.forEach(i=>{let n=this.containerEl.createDiv("suggestion-item");this.owner.renderSuggestion(i,n),e.push(n)}),this.items=c,this.suggestions=e,this.setSelectedItem(0,!1)}useSelectedItem(c){if(!this.items||!this.items.length)return;let e=this.items[this.selectedItem];e&&this.owner.selectSuggestion(e,c),q.Platform.isMobile&&this.chooseSuggestion(c)}wrap(c,e){return(c%e+e)%e}setSelectedItem(c,e){let i=this.wrap(c,this.suggestions.length),n=this.suggestions[this.selectedItem],o=this.suggestions[i];n&&n.removeClass("is-selected"),o&&o.addClass("is-selected"),this.selectedItem=i,e&&o.scrollIntoView(!1)}},O2=class extends q.FuzzySuggestModal{constructor(c,e,i){super(c);this.items=[];this.scope=new q.Scope;this.emptyStateText="No match found";this.limit=100;this.inputEl=e,this.items=i,this.suggestEl=createDiv("suggestion-container"),this.suggestEl.style.width=`${e.clientWidth}px`,this.contentEl=this.suggestEl.createDiv("suggestion"),this.suggester=new q4(this,this.contentEl,this.scope),this.scope.register([],"Escape",this.close.bind(this)),this.inputEl.addEventListener("input",this.onInputChanged.bind(this)),this.inputEl.addEventListener("focus",this.onInputChanged.bind(this)),this.inputEl.addEventListener("blur",this.close.bind(this)),this.suggestEl.on("mousedown",".suggestion-container",n=>{n.preventDefault()})}empty(){this.suggester.empty()}onInputChanged(){let c=this.modifyInput(this.inputEl.value),e=this.getSuggestions(c);e.length>0?this.suggester.setSuggestions(e.slice(0,this.limit)):this.onNoSuggestion(),this.open()}modifyInput(c){return c}onNoSuggestion(){this.empty(),this.renderSuggestion(null,this.contentEl.createDiv("suggestion-item"))}open(){this.app.keymap.pushScope(this.scope),document.body.appendChild(this.suggestEl),this.popper=D2(this.inputEl,this.suggestEl,{placement:"bottom-start",modifiers:[{name:"offset",options:{offset:[0,10]}},{name:"flip",options:{fallbackPlacements:["top"]}}]})}close(){this.app.keymap.popScope(this.scope),this.suggester.setSuggestions([]),this.popper&&this.popper.destroy(),this.suggestEl.detach()}createPrompt(c){this.promptEl||(this.promptEl=this.suggestEl.createDiv("prompt-instructions"));let e=this.promptEl.createDiv("prompt-instruction");for(let i of c)e.appendChild(i)}},I2=class extends O2{constructor(c,e){super(c.app,e.inputEl,c.iconManager.iconDefinitions);this.plugin=c;this.icons=c.iconManager.iconDefinitions,this.text=e,this.createPrompts(),this.inputEl.addEventListener("input",this.getItem.bind(this))}createPrompts(){}getItem(){let c=this.inputEl.value,e=this.icons.find(i=>i.name===c.trim());e!=this.icon&&(this.icon=e,this.icons&&this.onInputChanged())}getItemText(c){return c.name}onChooseItem(c){this.text.setValue(c.name),this.icon=c}selectSuggestion({item:c}){this.text.setValue(c.name),this.icon=c,this.onClose(),this.close()}renderSuggestion(c,e){let{item:i,match:n}=c||{},o=e.createDiv({cls:"suggestion-content icon"});if(!i){o.setText(this.emptyStateText),o.parentElement.addClass("is-selected");return}let r=n.matches.map(l=>createSpan("suggestion-highlight"));for(let l=0;ls[0]===l);if(f){let s=r[n.matches.indexOf(f)];o.appendChild(s),s.appendText(i.name.substring(f[0],f[1])),l+=f[1]-f[0]-1;continue}o.appendText(i.name[l])}let t=createDiv("suggestion-flair admonition-suggester-icon");t.appendChild(this.plugin.iconManager.getIconNode(i)??createDiv()),o.prepend(t),o.createDiv({cls:"suggestion-note",text:this.plugin.iconManager.getIconModuleName(i)})}getItems(){return this.icons}},U4=class extends O2{constructor(c,e,i){super(c.app,e.inputEl,i);this.plugin=c;this.admonitions=[...i],this.text=e,this.createPrompts(),this.inputEl.addEventListener("input",this.getItem.bind(this))}createPrompts(){}getItem(){let c=this.inputEl.value,e=this.admonitions.find(i=>i.type===c.trim());e!=this.admonition&&(this.admonition=e,this.admonitions&&this.onInputChanged())}getItemText(c){return c.type}onChooseItem(c){this.text.setValue(c.type),this.admonition=c}selectSuggestion({item:c}){this.text.setValue(c.type),this.onClose(),this.close()}renderSuggestion(c,e){let{item:i,match:n}=c||{},o=e.createDiv({cls:"suggestion-content icon"});if(!i){o.setText(this.emptyStateText),o.parentElement.addClass("is-selected");return}let r=n.matches.map(l=>createSpan("suggestion-highlight"));for(let l=0;ls[0]===l);if(f){let s=r[n.matches.indexOf(f)];o.appendChild(s),s.appendText(i.type.substring(f[0],f[1])),l+=f[1]-f[0]-1;continue}o.appendText(i.type[l])}let t=createDiv("suggestion-flair admonition-suggester-icon");t.appendChild(this.plugin.iconManager.getIconNode(i.icon)??createDiv()).setAttribute("color",`rgb(${i.color})`),o.prepend(t)}getItems(){return this.admonitions}},r2=class extends q.Modal{constructor(c){super(c.app);this.plugin=c;this.collapse=this.plugin.data.autoCollapse?this.plugin.data.defaultCollapseType:"none";this.containerEl.addClass("insert-admonition-modal"),this.onOpen=()=>this.display(!0)}async display(c){let{contentEl:e}=this;e.empty(),new q.Setting(e).setName("Admonition Type").addText(t=>{t.setPlaceholder("Admonition Type").setValue(this.type);let l=new U4(this.plugin,t,this.plugin.admonitionArray),f=()=>{t.inputEl.value&&this.plugin.admonitions[t.inputEl.value]?(this.type=t.inputEl.value,this.title?.length||(this.title=this.type[0].toUpperCase()+this.type.slice(1).toLowerCase()),n.setValue(this.title)):(new q.Notice("No admonition type by that name exists."),t.inputEl.value=""),this.buildAdmonition()};t.inputEl.onblur=f,l.onClose=f,c&&(l.open(),t.inputEl.focus())});let n;new q.Setting(e).setName("Admonition Title").setDesc("Leave blank to render without a title.").addText(t=>{n=t,t.setValue(this.title),t.onChange(l=>{if(this.title=l,l.length==0?this.noTitle=!0:this.noTitle=!1,this.element){let f=this.plugin.admonitions[this.type],s=this.plugin.getAdmonitionElement(this.type,this.title,f.icon,f.injectColor??this.plugin.data.injectColor?f.color:null,this.collapse);s.createDiv({cls:"admonition-content",text:"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla et euismod nulla."}),this.element.replaceWith(s),this.element=s}})}),new q.Setting(e).setName("Make Collapsible").addDropdown(t=>{t.addOption("open","Open"),t.addOption("closed","Closed"),t.addOption("none","None"),t.setValue(this.collapse),t.onChange(l=>{this.collapse=l,this.buildAdmonition()})}),this.admonitionEl=this.contentEl.createDiv(),this.buildAdmonition(),new q.Setting(e).addButton(t=>t.setButtonText("Insert").setCta().onClick(()=>{this.insert=!0,this.close()})).addExtraButton(t=>{t.setIcon("cross").setTooltip("Cancel").onClick(()=>this.close()),t.extraSettingsEl.setAttr("tabindex",0),t.extraSettingsEl.onkeydown=l=>{l.key=="Enter"&&this.close()}})}buildAdmonition(){if(this.admonitionEl.empty(),this.type&&this.plugin.admonitions[this.type]){let c=this.plugin.admonitions[this.type];this.element=this.plugin.getAdmonitionElement(this.type,this.title,c.icon,c.injectColor??this.plugin.data.injectColor?c.color:null,this.collapse),this.element.createDiv({cls:"admonition-content",text:"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla et euismod nulla."}),this.admonitionEl.appendChild(this.element)}}};var W4='/*\nTHIS IS A GENERATED/BUNDLED FILE BY ESBUILD\nif you want to view the source, please visit the github repository of this plugin\n*/\n\nfunction T(n,e,i){let t=document.createElement(n);typeof e=="string"&&(e={cls:e});let o=e||{},l=o.cls,s=o.text,a=o.attr,r=o.title,d=o.value,c=o.type,g=i||o.parent,f=o.prepend,m=o.href;return l&&(Array.isArray(l)?t.className=l.join(" "):t.className=l),s&&(t.textContent=s),a&&Object.keys(a).forEach(p=>{let E=a[p];E!==null&&t.setAttribute(p,String(E))}),r&&(t.title=r),d&&(t instanceof HTMLInputElement||t instanceof HTMLSelectElement||t instanceof HTMLOptionElement)&&(t.value=d),c&&t instanceof HTMLStyleElement&&t.setAttribute("type",c),m&&(t instanceof HTMLAnchorElement||t instanceof HTMLLinkElement)&&(t.href=m),g&&(f?g.insertBefore(t,g.firstChild):g.appendChild(t)),t}var h=function(n,e){return T("div",n,e)};Node.prototype.createDiv=function(n,e){return h(n,this)};Node.prototype.createEl=function(n,e,i){return T(n,e,this)};Element.prototype.addClass=function(...n){let e=[];for(let i=0;i{y(),b()};function w(){return new Promise((n,e)=>{let i=document.querySelector(".markdown-preview-sizer");if(i)n(i);else{let t=new MutationObserver(o=>{for(let l of o)if(l.type=="childList"&&l.addedNodes.length){for(let s of Array.from(l.addedNodes))if(s instanceof HTMLDivElement){if(s.hasClass("publish-renderer")){let a=s.querySelector(".markdown-preview-sizer");a&&(t.disconnect(),n(a))}s.hasClass("markdown-preview-sizer")&&(t.disconnect(),n(i))}}});t.observe(document.body,{attributes:!1,childList:!0,characterData:!1,subtree:!0})}})}async function b(){let n=await w();new MutationObserver(i=>{i.forEach(t=>{t.type=="childList"&&t.addedNodes.length&&t.addedNodes.forEach(o=>{if(o&&o instanceof HTMLDivElement&&!o.childElementCount){let l=new MutationObserver(s=>{for(let a of s)if(a.type=="childList"&&a.addedNodes.length)for(let r of Array.from(a.addedNodes))r instanceof HTMLPreElement&&(!M.has(r)&&Array.from(r.classList).some(d=>/language-ad-(\\w+)/.test(d))?(l.disconnect(),M.add(r),v(r)):(l.disconnect(),H(r)))});l.observe(o,{attributes:!1,childList:!0,characterData:!1,subtree:!1})}o&&o instanceof HTMLElement&&o.children.length&&o.firstElementChild instanceof HTMLPreElement&&H(o.firstElementChild)})})}).observe(n,{attributes:!1,childList:!0,subtree:!1})}function H(n){let e=new MutationObserver(i=>{i.forEach(t=>{t.target instanceof HTMLPreElement&&!M.has(t.target)&&t.type==="attributes"&&t.attributeName==="class"&&Array.from(t.target.classList).some(o=>/language-ad-(\\w+)/.test(o))&&(e.disconnect(),M.add(t.target),v(t.target))})});e.observe(n,{attributes:!0,childList:!1,characterData:!1,subtree:!1})}function v(n){let[,e]=n.classList.toString().match(/language-ad-(\\w+)/);if(!e||!(e in u.ADMONITION_ICON_MAP))return;let{title:i=e[0].toUpperCase()+e.slice(1).toLowerCase(),collapse:t,content:o,icon:l=u.ADMONITION_ICON_MAP[e].icon,color:s=u.ADMONITION_ICON_MAP[e].color}=N(e,n.innerText),a=L(e,i,l,s,t),d=a.createDiv("admonition-content-holder").createDiv("admonition-content");d.innerText=o,n.replaceWith(a)}function y(){let n=document.querySelectorAll("pre[class*=\'language-ad\']");if(!!n.length)for(let e of Array.from(n)){M.add(e);let[,i]=e.classList.toString().match(/language-ad-(\\w+)/);if(!i||!(i in u.ADMONITION_ICON_MAP))continue;let{title:t=i[0].toUpperCase()+i.slice(1).toLowerCase(),collapse:o,content:l,icon:s=u.ADMONITION_ICON_MAP[i].icon,color:a=u.ADMONITION_ICON_MAP[i].color}=N(i,e.innerText),r=L(i,t,s,a,o),c=r.createDiv("admonition-content-holder").createDiv("admonition-content");c.innerText=l,e.replaceWith(r)}}\n';var z3=J(require("obsidian"));var G4={};var _4={};var $4={};var Y4={};var B2={"Admonition Settings":"Admonition Settings","Use Obsidian's markdown syntax highlighter in admonition code blocks. This setting is experimental and could cause errors.":"Use Obsidian's markdown syntax highlighter in admonition code blocks. This setting is experimental and could cause errors.","Markdown Syntax Highlighting":"Markdown Syntax Highlighting","Try to sync internal links to the metadata cache to display in graph view. This setting could have unintended consequences. Use at your own risk.":"Try to sync internal links to the metadata cache to display in graph view. This setting could have unintended consequences. Use at your own risk."," Sync Links to Metadata Cache":" Sync Links to Metadata Cache","Allows admonitions to be created using ":"Allows admonitions to be created using "," or ":" or ",", instead of using a code block.":", instead of using a code block."," Enable Non-codeblock Admonitions":" Enable Non-codeblock Admonitions","Collapsible by Default":"Collapsible by Default","All admonitions will be collapsible by default. Use ":"All admonitions will be collapsible by default. Use "," to prevent.":" to prevent.","Default Collapse Type":"Default Collapse Type","Collapsible admonitions will be either opened or closed.":"Collapsible admonitions will be either opened or closed.","Add Copy Button":"Add Copy Button","Add a 'copy content' button to admonitions.":"Add a 'copy content' button to admonitions.","Add New":"Add New","Add a new Admonition type.":"Add a new Admonition type.","Add Additional":"Add Additional","Register Commands":"Register Commands","Unregister Commands":"Unregister Commands",Edit:"Edit",Delete:"Delete","Admonition Type":"Admonition Type","Admonition Title":"Admonition Title","This will be the default title for this admonition type.":"This will be the default title for this admonition type.","Admonition type cannot be empty.":"Admonition type cannot be empty.","Admonition type cannot include spaces.":"Admonition type cannot include spaces.","Types must be a valid CSS selector.":"Types must be a valid CSS selector.","Invalid icon name.":"Invalid icon name.","Icon cannot be empty.":"Icon cannot be empty.","Upload Image":"Upload Image","There was an error parsing the image.":"There was an error parsing the image.","Admonition Icon":"Admonition Icon",Color:"Color",Save:"Save","No Admonition Title by Default":"No Admonition Title by Default","The admonition will have no title unless ":"The admonition will have no title unless "," is explicitly provided.":" is explicitly provided.","Show Copy Button":"Show Copy Button","A copy button will be added to the admonition.":"A copy button will be added to the admonition.","Parse Titles as Markdown":"Parse Titles as Markdown","Admonition Titles will be rendered as markdown.":"Admonition Titles will be rendered as markdown."};var X4={};var K4={};var Q4={};var J4={};var c3={};var a3={};var e3={};var i3={};var n3={};var o3={};var t3={};var r3={};var l3={};var f3={};var s3={};var h3={};var m3={"Admonition Settings":"Admonition \u8BBE\u7F6E","Use Obsidian's markdown syntax highlighter in admonition code blocks. This setting is experimental and could cause errors.":"\u5728 admonition \u4EE3\u7801\u5757\u4E2D\u4F7F\u7528 Obsidian \u7684 markdown \u7CFB\u7EDF\u7EA7\u9AD8\u4EAE\u3002\u8BE5\u8BBE\u7F6E\u4E3A\u5B9E\u9A8C\u6027\uFF0C\u53EF\u80FD\u4F1A\u5F15\u53D1\u9519\u8BEF"," Markdown Syntax Highlighting":" Markdown \u7CFB\u7EDF\u9AD8\u4EAE","Try to sync internal links to the metadata cache to display in graph view. This setting could have unintended consequences. Use at your own risk.":"Try to sync internal links to the metadata cache to display in graph view. This setting could have unintended consequences. Use at your own risk."," Sync Links to Metadata Cache":" Sync Links to Metadata Cache","Allows admonitions to be created using ":"\u5141\u8BB8 admonitions \u521B\u5EFA\u4F7F\u7528"," or ":"\u6216",", instead of using a code block.":"\uFF0C\u800C\u975E\u4EE3\u7801\u5757"," Enable Non-codeblock Admonitions":" \u5141\u8BB8\u975E\u4EE3\u7801\u5757\u7684 Admonitions","Collapsible by Default":"\u53EF\u6298\u53E0\u9ED8\u8BA4\u503C","All admonitions will be collapsible by default. Use ":"\u6240\u6709\u7684 admonitions \u9ED8\u8BA4\u53EF\u6298\u53E0\u3002\u4F7F\u7528"," to prevent.":" \u6765\u963B\u6B62\u3002","Default Collapse Type":"\u9ED8\u8BA4\u53EF\u6298\u53E0\u7C7B\u578B","Collapsible admonitions will be either opened or closed.":"Collapsible admonitions \u8981\u4E48\u662F openede \u8981\u4E48\u662F closed","Add Copy Button":"\u6DFB\u52A0\u590D\u5236\u6309\u94AE","Add a 'copy content' button to admonitions.":"\u4E3A admonitions \u65B0\u589E\u4E00\u4E2A\u201C\u590D\u5236\u5185\u5BB9\u201D\u6309\u94AE\u3002","Add New":"\u65B0\u589E","Add a new Admonition type.":"\u6DFB\u52A0\u4E00\u4E2A\u65B0\u7684 Admonition \u7C7B\u578B\u3002","Add Additional":"\u989D\u5916\u6DFB\u52A0","Register Commands":"\u6CE8\u518C\u547D\u4EE4","Unregister Commands":"\u6CE8\u9500\u547D\u4EE4",Edit:"\u7F16\u8F91",Delete:"\u5220\u9664","Admonition type cannot be empty.":"Admonition \u7C7B\u578B\u4E0D\u80FD\u4E3A\u7A7A\u3002","Admonition type cannot include spaces.":"Admonition \u7C7B\u578B\u4E0D\u80FD\u5305\u542B\u7A7A\u683C","Admonition Type":"Admonition \u7C7B\u578B","Types must be a valid CSS selector.":"\u7C7B\u578B\u5FC5\u987B\u4E3A\u5408\u6CD5\u7684 css \u9009\u62E9\u5668\u3002","Invalid icon name.":"\u975E\u6CD5\u56FE\u6807\u540D\u79F0","Icon cannot be empty.":"\u56FE\u6807\u4E0D\u80FD\u4E3A\u7A7A","Upload Image":"\u4E0A\u4F20\u56FE\u50CF","There was an error parsing the image.":"\u4E0A\u4F20\u56FE\u50CF\u65F6\u51FA\u9519\u4E86\u3002","Admonition Icon":"Admonition \u56FE\u6807",Color:"\u989C\u8272",Save:"\u4FDD\u5B58"};var v3={};var Z6={ar:G4,cs:_4,da:$4,de:Y4,en:B2,"en-gb":X4,es:K4,fr:Q4,hi:J4,id:c3,it:a3,ja:e3,ko:i3,nl:n3,nn:o3,pl:t3,pt:r3,"pt-br":l3,ro:f3,ru:s3,tr:h3,"zh-cn":m3,"zh-tw":v3},p3=Z6[z3.moment.locale()];function g(a){return p3&&p3[a]||B2[a]}var Z1=J(require("obsidian"));async function d3(a,c,e={cta:"Yes",secondary:"No"}){return new Promise((i,n)=>{try{let o=new u3(a,c,e);o.onClose=()=>{i(o.confirmed)},o.open()}catch{n()}})}var u3=class extends Z1.Modal{constructor(c,e,i){super(c);this.text=e;this.buttons=i;this.confirmed=!1}async display(){this.contentEl.empty(),this.contentEl.addClass("confirm-modal"),this.contentEl.createEl("p",{text:this.text});let c=this.contentEl.createDiv("fantasy-calendar-confirm-buttons");new Z1.ButtonComponent(c).setButtonText(this.buttons.cta).setCta().onClick(()=>{this.confirmed=!0,this.close()}),new Z1.ButtonComponent(c).setButtonText(this.buttons.secondary).onClick(()=>{this.close()})}onOpen(){this.display()}};var H1={octicons:"Octicons",rpg:"RPG Awesome"};var M3=(a=>c=>{try{a.querySelector(c)}catch{return!1}return!0})(document.createDocumentFragment()),l2=class extends u.PluginSettingTab{constructor(c,e){super(c,e);this.plugin=e;this.queue=[];this.converted=0}async display(){this.containerEl.empty(),this.containerEl.addClass("admonition-settings"),this.containerEl.createEl("h2",{text:g("Admonition Settings")});let c=this.containerEl.createDiv("admonitions-nested-settings");u.Platform.isMobile||new u.Setting(c).setName("Export Custom Types as CSS").setDesc("Export a CSS snippet for custom callout types.").addButton(i=>i.setIcon("download").onClick(()=>{let n=[`/* This snippet was auto-generated by the Admonitions plugin */ +`);return s!==void 0&&s!=="none"&&s!=="open"&&s!=="closed"&&(s="closed"),"title"in l||e.noTitle||(f=i),f&&f.trim()===""&&s!==void 0&&s!=="none"&&(f=i,new d4.Notice("An admonition must have a title if it is collapsible.")),{title:f,collapse:s,content:z,icon:h,color:m}}var M4='',K1="admonition-add-command",C4='',Q1="admonition-remove-command",H4='',P1="admonition-warning",g4='',E1="admonition-spin",V4={note:{type:"note",color:"68, 138, 255",icon:{type:"font-awesome",name:"pencil-alt"},command:!1,noTitle:!1},seealso:{type:"note",color:"68, 138, 255",icon:{type:"font-awesome",name:"pencil-alt"},command:!1,noTitle:!1},abstract:{type:"abstract",color:"0, 176, 255",icon:{type:"font-awesome",name:"book"},command:!1,noTitle:!1},summary:{type:"abstract",color:"0, 176, 255",icon:{type:"font-awesome",name:"book"},command:!1,noTitle:!1},tldr:{type:"abstract",color:"0, 176, 255",icon:{type:"font-awesome",name:"book"},command:!1,noTitle:!1},info:{type:"info",color:"0, 184, 212",icon:{type:"font-awesome",name:"info-circle"},command:!1,noTitle:!1},todo:{type:"info",color:"0, 184, 212",icon:{type:"font-awesome",name:"info-circle"},command:!1,noTitle:!1},tip:{type:"tip",color:"0, 191, 165",icon:{type:"font-awesome",name:"fire"},command:!1,noTitle:!1},hint:{type:"tip",color:"0, 191, 165",icon:{type:"font-awesome",name:"fire"},command:!1,noTitle:!1},important:{type:"tip",color:"0, 191, 165",icon:{type:"font-awesome",name:"fire"},command:!1,noTitle:!1},success:{type:"success",color:"0, 200, 83",icon:{type:"font-awesome",name:"check-circle"},command:!1,noTitle:!1},check:{type:"success",color:"0, 200, 83",icon:{type:"font-awesome",name:"check-circle"},command:!1,noTitle:!1},done:{type:"success",color:"0, 200, 83",icon:{type:"font-awesome",name:"check-circle"},command:!1,noTitle:!1},question:{type:"question",color:"100, 221, 23",icon:{type:"font-awesome",name:"question-circle"},command:!1,noTitle:!1},help:{type:"question",color:"100, 221, 23",icon:{type:"font-awesome",name:"question-circle"},command:!1,noTitle:!1},faq:{type:"question",color:"100, 221, 23",icon:{type:"font-awesome",name:"question-circle"},command:!1,noTitle:!1},warning:{type:"warning",color:"255, 145, 0",icon:{type:"font-awesome",name:"exclamation-triangle"},command:!1,noTitle:!1},caution:{type:"warning",color:"255, 145, 0",icon:{type:"font-awesome",name:"exclamation-triangle"},command:!1,noTitle:!1},attention:{type:"warning",color:"255, 145, 0",icon:{type:"font-awesome",name:"exclamation-triangle"},command:!1,noTitle:!1},failure:{type:"failure",color:"255, 82, 82",icon:{type:"font-awesome",name:"times-circle"},command:!1,noTitle:!1},fail:{type:"failure",color:"255, 82, 82",icon:{type:"font-awesome",name:"times-circle"},command:!1,noTitle:!1},missing:{type:"failure",color:"255, 82, 82",icon:{type:"font-awesome",name:"times-circle"},command:!1,noTitle:!1},danger:{type:"danger",color:"255, 23, 68",icon:{type:"font-awesome",name:"bolt"},command:!1,noTitle:!1},error:{type:"danger",color:"255, 23, 68",icon:{type:"font-awesome",name:"bolt"},command:!1,noTitle:!1},bug:{type:"bug",color:"245, 0, 87",icon:{type:"font-awesome",name:"bug"},command:!1,noTitle:!1},example:{type:"example",color:"124, 77, 255",icon:{type:"font-awesome",name:"list-ol"},command:!1,noTitle:!1},quote:{type:"quote",color:"158, 158, 158",icon:{type:"font-awesome",name:"quote-right"},command:!1,noTitle:!1},cite:{type:"quote",color:"158, 158, 158",icon:{type:"font-awesome",name:"quote-right"},command:!1,noTitle:!1}};var u=J(require("obsidian"));var q=J(require("obsidian"));var k="top",D="bottom",T="right",P="left",J1="auto",l1=[k,D,T,P],i1="start",c2="end",L4="clippingParents",a2="viewport",y1="popper",x4="reference",V2=l1.reduce(function(a,c){return a.concat([c+"-"+i1,c+"-"+c2])},[]),e2=[].concat(l1,[J1]).reduce(function(a,c){return a.concat([c,c+"-"+i1,c+"-"+c2])},[]),l6="beforeRead",f6="read",s6="afterRead",h6="beforeMain",m6="main",v6="afterMain",z6="beforeWrite",p6="write",d6="afterWrite",b4=[l6,f6,s6,h6,m6,v6,z6,p6,d6];function O(a){return a?(a.nodeName||"").toLowerCase():null}function w(a){if(a==null)return window;if(a.toString()!=="[object Window]"){var c=a.ownerDocument;return c&&c.defaultView||window}return a}function n1(a){var c=w(a).Element;return a instanceof c||a instanceof Element}function B(a){var c=w(a).HTMLElement;return a instanceof c||a instanceof HTMLElement}function i2(a){if(typeof ShadowRoot=="undefined")return!1;var c=w(a).ShadowRoot;return a instanceof c||a instanceof ShadowRoot}function u6(a){var c=a.state;Object.keys(c.elements).forEach(function(e){var i=c.styles[e]||{},n=c.attributes[e]||{},o=c.elements[e];!B(o)||!O(o)||(Object.assign(o.style,i),Object.keys(n).forEach(function(r){var t=n[r];t===!1?o.removeAttribute(r):o.setAttribute(r,t===!0?"":t)}))})}function M6(a){var c=a.state,e={popper:{position:c.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(c.elements.popper.style,e.popper),c.styles=e,c.elements.arrow&&Object.assign(c.elements.arrow.style,e.arrow),function(){Object.keys(c.elements).forEach(function(i){var n=c.elements[i],o=c.attributes[i]||{},r=Object.keys(c.styles.hasOwnProperty(i)?c.styles[i]:e[i]),t=r.reduce(function(l,f){return l[f]="",l},{});!B(n)||!O(n)||(Object.assign(n.style,t),Object.keys(o).forEach(function(l){n.removeAttribute(l)}))})}}var N4={name:"applyStyles",enabled:!0,phase:"write",fn:u6,effect:M6,requires:["computeStyles"]};function I(a){return a.split("-")[0]}function _(a){var c=a.getBoundingClientRect();return{width:c.width,height:c.height,top:c.top,right:c.right,bottom:c.bottom,left:c.left,x:c.left,y:c.top}}function z1(a){var c=_(a),e=a.offsetWidth,i=a.offsetHeight;return Math.abs(c.width-e)<=1&&(e=c.width),Math.abs(c.height-i)<=1&&(i=c.height),{x:a.offsetLeft,y:a.offsetTop,width:e,height:i}}function D1(a,c){var e=c.getRootNode&&c.getRootNode();if(a.contains(c))return!0;if(e&&i2(e)){var i=c;do{if(i&&a.isSameNode(i))return!0;i=i.parentNode||i.host}while(i)}return!1}function j(a){return w(a).getComputedStyle(a)}function L2(a){return["table","td","th"].indexOf(O(a))>=0}function R(a){return((n1(a)?a.ownerDocument:a.document)||window.document).documentElement}function o1(a){return O(a)==="html"?a:a.assignedSlot||a.parentNode||(i2(a)?a.host:null)||R(a)}function A4(a){return!B(a)||j(a).position==="fixed"?null:a.offsetParent}function C6(a){var c=navigator.userAgent.toLowerCase().indexOf("firefox")!==-1,e=navigator.userAgent.indexOf("Trident")!==-1;if(e&&B(a)){var i=j(a);if(i.position==="fixed")return null}for(var n=o1(a);B(n)&&["html","body"].indexOf(O(n))<0;){var o=j(n);if(o.transform!=="none"||o.perspective!=="none"||o.contain==="paint"||["transform","perspective"].indexOf(o.willChange)!==-1||c&&o.willChange==="filter"||c&&o.filter&&o.filter!=="none")return n;n=n.parentNode}return null}function X(a){for(var c=w(a),e=A4(a);e&&L2(e)&&j(e).position==="static";)e=A4(e);return e&&(O(e)==="html"||O(e)==="body"&&j(e).position==="static")?c:e||C6(a)||c}function p1(a){return["top","bottom"].indexOf(a)>=0?"x":"y"}var $=Math.max,f1=Math.min,O1=Math.round;function d1(a,c,e){return $(a,f1(c,e))}function I1(){return{top:0,right:0,bottom:0,left:0}}function B1(a){return Object.assign({},I1(),a)}function R1(a,c){return c.reduce(function(e,i){return e[i]=a,e},{})}var H6=function(c,e){return c=typeof c=="function"?c(Object.assign({},e.rects,{placement:e.placement})):c,B1(typeof c!="number"?c:R1(c,l1))};function g6(a){var c,e=a.state,i=a.name,n=a.options,o=e.elements.arrow,r=e.modifiersData.popperOffsets,t=I(e.placement),l=p1(t),f=[P,T].indexOf(t)>=0,s=f?"height":"width";if(!(!o||!r)){var h=H6(n.padding,e),m=z1(o),z=l==="y"?k:P,v=l==="y"?D:T,M=e.rects.reference[s]+e.rects.reference[l]-r[l]-e.rects.popper[s],p=r[l]-e.rects.reference[l],C=X(o),H=C?l==="y"?C.clientHeight||0:C.clientWidth||0:0,L=M/2-p/2,d=h[z],N=H-m[s]-h[v],V=H/2-m[s]/2+L,y=d1(d,V,N),A=l;e.modifiersData[i]=(c={},c[A]=y,c.centerOffset=y-V,c)}}function V6(a){var c=a.state,e=a.options,i=e.element,n=i===void 0?"[data-popper-arrow]":i;n!=null&&(typeof n=="string"&&(n=c.elements.popper.querySelector(n),!n)||!D1(c.elements.popper,n)||(c.elements.arrow=n))}var y4={name:"arrow",enabled:!0,phase:"main",fn:g6,effect:V6,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};var L6={top:"auto",right:"auto",bottom:"auto",left:"auto"};function x6(a){var c=a.x,e=a.y,i=window,n=i.devicePixelRatio||1;return{x:O1(O1(c*n)/n)||0,y:O1(O1(e*n)/n)||0}}function S4(a){var c,e=a.popper,i=a.popperRect,n=a.placement,o=a.offsets,r=a.position,t=a.gpuAcceleration,l=a.adaptive,f=a.roundOffsets,s=f===!0?x6(o):typeof f=="function"?f(o):o,h=s.x,m=h===void 0?0:h,z=s.y,v=z===void 0?0:z,M=o.hasOwnProperty("x"),p=o.hasOwnProperty("y"),C=P,H=k,L=window;if(l){var d=X(e),N="clientHeight",V="clientWidth";d===w(e)&&(d=R(e),j(d).position!=="static"&&(N="scrollHeight",V="scrollWidth")),d=d,n===k&&(H=D,v-=d[N]-i.height,v*=t?1:-1),n===P&&(C=T,m-=d[V]-i.width,m*=t?1:-1)}var y=Object.assign({position:r},l&&L6);if(t){var A;return Object.assign({},y,(A={},A[H]=p?"0":"",A[C]=M?"0":"",A.transform=(L.devicePixelRatio||1)<2?"translate("+m+"px, "+v+"px)":"translate3d("+m+"px, "+v+"px, 0)",A))}return Object.assign({},y,(c={},c[H]=p?v+"px":"",c[C]=M?m+"px":"",c.transform="",c))}function b6(a){var c=a.state,e=a.options,i=e.gpuAcceleration,n=i===void 0?!0:i,o=e.adaptive,r=o===void 0?!0:o,t=e.roundOffsets,l=t===void 0?!0:t;if(!1)var f;var s={placement:I(c.placement),popper:c.elements.popper,popperRect:c.rects.popper,gpuAcceleration:n};c.modifiersData.popperOffsets!=null&&(c.styles.popper=Object.assign({},c.styles.popper,S4(Object.assign({},s,{offsets:c.modifiersData.popperOffsets,position:c.options.strategy,adaptive:r,roundOffsets:l})))),c.modifiersData.arrow!=null&&(c.styles.arrow=Object.assign({},c.styles.arrow,S4(Object.assign({},s,{offsets:c.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),c.attributes.popper=Object.assign({},c.attributes.popper,{"data-popper-placement":c.placement})}var w4={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:b6,data:{}};var n2={passive:!0};function N6(a){var c=a.state,e=a.instance,i=a.options,n=i.scroll,o=n===void 0?!0:n,r=i.resize,t=r===void 0?!0:r,l=w(c.elements.popper),f=[].concat(c.scrollParents.reference,c.scrollParents.popper);return o&&f.forEach(function(s){s.addEventListener("scroll",e.update,n2)}),t&&l.addEventListener("resize",e.update,n2),function(){o&&f.forEach(function(s){s.removeEventListener("scroll",e.update,n2)}),t&&l.removeEventListener("resize",e.update,n2)}}var k4={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:N6,data:{}};var A6={left:"right",right:"left",bottom:"top",top:"bottom"};function S1(a){return a.replace(/left|right|bottom|top/g,function(c){return A6[c]})}var y6={start:"end",end:"start"};function o2(a){return a.replace(/start|end/g,function(c){return y6[c]})}function u1(a){var c=w(a),e=c.pageXOffset,i=c.pageYOffset;return{scrollLeft:e,scrollTop:i}}function M1(a){return _(R(a)).left+u1(a).scrollLeft}function x2(a){var c=w(a),e=R(a),i=c.visualViewport,n=e.clientWidth,o=e.clientHeight,r=0,t=0;return i&&(n=i.width,o=i.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(r=i.offsetLeft,t=i.offsetTop)),{width:n,height:o,x:r+M1(a),y:t}}function b2(a){var c,e=R(a),i=u1(a),n=(c=a.ownerDocument)==null?void 0:c.body,o=$(e.scrollWidth,e.clientWidth,n?n.scrollWidth:0,n?n.clientWidth:0),r=$(e.scrollHeight,e.clientHeight,n?n.scrollHeight:0,n?n.clientHeight:0),t=-i.scrollLeft+M1(a),l=-i.scrollTop;return j(n||e).direction==="rtl"&&(t+=$(e.clientWidth,n?n.clientWidth:0)-o),{width:o,height:r,x:t,y:l}}function C1(a){var c=j(a),e=c.overflow,i=c.overflowX,n=c.overflowY;return/auto|scroll|overlay|hidden/.test(e+n+i)}function t2(a){return["html","body","#document"].indexOf(O(a))>=0?a.ownerDocument.body:B(a)&&C1(a)?a:t2(o1(a))}function s1(a,c){var e;c===void 0&&(c=[]);var i=t2(a),n=i===((e=a.ownerDocument)==null?void 0:e.body),o=w(i),r=n?[o].concat(o.visualViewport||[],C1(i)?i:[]):i,t=c.concat(r);return n?t:t.concat(s1(o1(r)))}function w1(a){return Object.assign({},a,{left:a.x,top:a.y,right:a.x+a.width,bottom:a.y+a.height})}function S6(a){var c=_(a);return c.top=c.top+a.clientTop,c.left=c.left+a.clientLeft,c.bottom=c.top+a.clientHeight,c.right=c.left+a.clientWidth,c.width=a.clientWidth,c.height=a.clientHeight,c.x=c.left,c.y=c.top,c}function T4(a,c){return c===a2?w1(x2(a)):B(c)?S6(c):w1(b2(R(a)))}function w6(a){var c=s1(o1(a)),e=["absolute","fixed"].indexOf(j(a).position)>=0,i=e&&B(a)?X(a):a;return n1(i)?c.filter(function(n){return n1(n)&&D1(n,i)&&O(n)!=="body"}):[]}function N2(a,c,e){var i=c==="clippingParents"?w6(a):[].concat(c),n=[].concat(i,[e]),o=n[0],r=n.reduce(function(t,l){var f=T4(a,l);return t.top=$(f.top,t.top),t.right=f1(f.right,t.right),t.bottom=f1(f.bottom,t.bottom),t.left=$(f.left,t.left),t},T4(a,o));return r.width=r.right-r.left,r.height=r.bottom-r.top,r.x=r.left,r.y=r.top,r}function c1(a){return a.split("-")[1]}function F1(a){var c=a.reference,e=a.element,i=a.placement,n=i?I(i):null,o=i?c1(i):null,r=c.x+c.width/2-e.width/2,t=c.y+c.height/2-e.height/2,l;switch(n){case k:l={x:r,y:c.y-e.height};break;case D:l={x:r,y:c.y+c.height};break;case T:l={x:c.x+c.width,y:t};break;case P:l={x:c.x-e.width,y:t};break;default:l={x:c.x,y:c.y}}var f=n?p1(n):null;if(f!=null){var s=f==="y"?"height":"width";switch(o){case i1:l[f]=l[f]-(c[s]/2-e[s]/2);break;case c2:l[f]=l[f]+(c[s]/2-e[s]/2);break;default:}}return l}function K(a,c){c===void 0&&(c={});var e=c,i=e.placement,n=i===void 0?a.placement:i,o=e.boundary,r=o===void 0?L4:o,t=e.rootBoundary,l=t===void 0?a2:t,f=e.elementContext,s=f===void 0?y1:f,h=e.altBoundary,m=h===void 0?!1:h,z=e.padding,v=z===void 0?0:z,M=B1(typeof v!="number"?v:R1(v,l1)),p=s===y1?x4:y1,C=a.elements.reference,H=a.rects.popper,L=a.elements[m?p:s],d=N2(n1(L)?L:L.contextElement||R(a.elements.popper),r,l),N=_(C),V=F1({reference:N,element:H,strategy:"absolute",placement:n}),y=w1(Object.assign({},H,V)),A=s===y1?y:N,E={top:d.top-A.top+M.top,bottom:A.bottom-d.bottom+M.bottom,left:d.left-A.left+M.left,right:A.right-d.right+M.right},S=a.modifiersData.offset;if(s===y1&&S){var Z=S[n];Object.keys(E).forEach(function(e1){var W=[T,D].indexOf(e1)>=0?1:-1,h1=[k,D].indexOf(e1)>=0?"y":"x";E[e1]+=Z[h1]*W})}return E}function A2(a,c){c===void 0&&(c={});var e=c,i=e.placement,n=e.boundary,o=e.rootBoundary,r=e.padding,t=e.flipVariations,l=e.allowedAutoPlacements,f=l===void 0?e2:l,s=c1(i),h=s?t?V2:V2.filter(function(v){return c1(v)===s}):l1,m=h.filter(function(v){return f.indexOf(v)>=0});m.length===0&&(m=h);var z=m.reduce(function(v,M){return v[M]=K(a,{placement:M,boundary:n,rootBoundary:o,padding:r})[I(M)],v},{});return Object.keys(z).sort(function(v,M){return z[v]-z[M]})}function k6(a){if(I(a)===J1)return[];var c=S1(a);return[o2(a),c,o2(c)]}function T6(a){var c=a.state,e=a.options,i=a.name;if(!c.modifiersData[i]._skip){for(var n=e.mainAxis,o=n===void 0?!0:n,r=e.altAxis,t=r===void 0?!0:r,l=e.fallbackPlacements,f=e.padding,s=e.boundary,h=e.rootBoundary,m=e.altBoundary,z=e.flipVariations,v=z===void 0?!0:z,M=e.allowedAutoPlacements,p=c.options.placement,C=I(p),H=C===p,L=l||(H||!v?[S1(p)]:k6(p)),d=[p].concat(L).reduce(function(v1,Q){return v1.concat(I(Q)===J1?A2(c,{placement:Q,boundary:s,rootBoundary:h,padding:f,flipVariations:v,allowedAutoPlacements:M}):Q)},[]),N=c.rects.reference,V=c.rects.popper,y=new Map,A=!0,E=d[0],S=0;S=0,T1=h1?"width":"height",x1=K(c,{placement:Z,boundary:s,rootBoundary:h,altBoundary:m,padding:f}),m1=h1?W?T:P:W?D:k;N[T1]>V[T1]&&(m1=S1(m1));var u2=S1(m1),b1=[];if(o&&b1.push(x1[e1]<=0),t&&b1.push(x1[m1]<=0,x1[u2]<=0),b1.every(function(v1){return v1})){E=Z,A=!1;break}y.set(Z,b1)}if(A)for(var G1=v?3:1,M2=function(Q){var $1=d.find(function(C2){var A1=y.get(C2);if(A1)return A1.slice(0,Q).every(function(H2){return H2})});if($1)return E=$1,"break"},N1=G1;N1>0;N1--){var _1=M2(N1);if(_1==="break")break}c.placement!==E&&(c.modifiersData[i]._skip=!0,c.placement=E,c.reset=!0)}}var P4={name:"flip",enabled:!0,phase:"main",fn:T6,requiresIfExists:["offset"],data:{_skip:!1}};function E4(a,c,e){return e===void 0&&(e={x:0,y:0}),{top:a.top-c.height-e.y,right:a.right-c.width+e.x,bottom:a.bottom-c.height+e.y,left:a.left-c.width-e.x}}function D4(a){return[k,T,D,P].some(function(c){return a[c]>=0})}function P6(a){var c=a.state,e=a.name,i=c.rects.reference,n=c.rects.popper,o=c.modifiersData.preventOverflow,r=K(c,{elementContext:"reference"}),t=K(c,{altBoundary:!0}),l=E4(r,i),f=E4(t,n,o),s=D4(l),h=D4(f);c.modifiersData[e]={referenceClippingOffsets:l,popperEscapeOffsets:f,isReferenceHidden:s,hasPopperEscaped:h},c.attributes.popper=Object.assign({},c.attributes.popper,{"data-popper-reference-hidden":s,"data-popper-escaped":h})}var O4={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:P6};function E6(a,c,e){var i=I(a),n=[P,k].indexOf(i)>=0?-1:1,o=typeof e=="function"?e(Object.assign({},c,{placement:a})):e,r=o[0],t=o[1];return r=r||0,t=(t||0)*n,[P,T].indexOf(i)>=0?{x:t,y:r}:{x:r,y:t}}function D6(a){var c=a.state,e=a.options,i=a.name,n=e.offset,o=n===void 0?[0,0]:n,r=e2.reduce(function(s,h){return s[h]=E6(h,c.rects,o),s},{}),t=r[c.placement],l=t.x,f=t.y;c.modifiersData.popperOffsets!=null&&(c.modifiersData.popperOffsets.x+=l,c.modifiersData.popperOffsets.y+=f),c.modifiersData[i]=r}var I4={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:D6};function O6(a){var c=a.state,e=a.name;c.modifiersData[e]=F1({reference:c.rects.reference,element:c.rects.popper,strategy:"absolute",placement:c.placement})}var B4={name:"popperOffsets",enabled:!0,phase:"read",fn:O6,data:{}};function y2(a){return a==="x"?"y":"x"}function I6(a){var c=a.state,e=a.options,i=a.name,n=e.mainAxis,o=n===void 0?!0:n,r=e.altAxis,t=r===void 0?!1:r,l=e.boundary,f=e.rootBoundary,s=e.altBoundary,h=e.padding,m=e.tether,z=m===void 0?!0:m,v=e.tetherOffset,M=v===void 0?0:v,p=K(c,{boundary:l,rootBoundary:f,padding:h,altBoundary:s}),C=I(c.placement),H=c1(c.placement),L=!H,d=p1(C),N=y2(d),V=c.modifiersData.popperOffsets,y=c.rects.reference,A=c.rects.popper,E=typeof M=="function"?M(Object.assign({},c.rects,{placement:c.placement})):M,S={x:0,y:0};if(!!V){if(o||t){var Z=d==="y"?k:P,e1=d==="y"?D:T,W=d==="y"?"height":"width",h1=V[d],T1=V[d]+p[Z],x1=V[d]-p[e1],m1=z?-A[W]/2:0,u2=H===i1?y[W]:A[W],b1=H===i1?-A[W]:-y[W],G1=c.elements.arrow,M2=z&&G1?z1(G1):{width:0,height:0},N1=c.modifiersData["arrow#persistent"]?c.modifiersData["arrow#persistent"].padding:I1(),_1=N1[Z],v1=N1[e1],Q=d1(0,y[W],M2[W]),$1=L?y[W]/2-m1-Q-_1-E:u2-Q-_1-E,C2=L?-y[W]/2+m1+Q+v1+E:b1+Q+v1+E,A1=c.elements.arrow&&X(c.elements.arrow),H2=A1?d==="y"?A1.clientTop||0:A1.clientLeft||0:0,l4=c.modifiersData.offset?c.modifiersData.offset[c.placement][d]:0,f4=V[d]+$1-l4-H2,s4=V[d]+C2-l4;if(o){var h4=d1(z?f1(T1,f4):T1,h1,z?$(x1,s4):x1);V[d]=h4,S[d]=h4-h1}if(t){var Q3=d==="x"?k:P,J3=d==="x"?D:T,Y1=V[N],m4=Y1+p[Q3],v4=Y1-p[J3],z4=d1(z?f1(m4,f4):m4,Y1,z?$(v4,s4):v4);V[N]=z4,S[N]=z4-Y1}}c.modifiersData[i]=S}}var R4={name:"preventOverflow",enabled:!0,phase:"main",fn:I6,requiresIfExists:["offset"]};function S2(a){return{scrollLeft:a.scrollLeft,scrollTop:a.scrollTop}}function w2(a){return a===w(a)||!B(a)?u1(a):S2(a)}function k2(a,c,e){e===void 0&&(e=!1);var i=R(c),n=_(a),o=B(c),r={scrollLeft:0,scrollTop:0},t={x:0,y:0};return(o||!o&&!e)&&((O(c)!=="body"||C1(i))&&(r=w2(c)),B(c)?(t=_(c),t.x+=c.clientLeft,t.y+=c.clientTop):i&&(t.x=M1(i))),{x:n.left+r.scrollLeft-t.x,y:n.top+r.scrollTop-t.y,width:n.width,height:n.height}}function B6(a){var c=new Map,e=new Set,i=[];a.forEach(function(o){c.set(o.name,o)});function n(o){e.add(o.name);var r=[].concat(o.requires||[],o.requiresIfExists||[]);r.forEach(function(t){if(!e.has(t)){var l=c.get(t);l&&n(l)}}),i.push(o)}return a.forEach(function(o){e.has(o.name)||n(o)}),i}function T2(a){var c=B6(a);return b4.reduce(function(e,i){return e.concat(c.filter(function(n){return n.phase===i}))},[])}function P2(a){var c;return function(){return c||(c=new Promise(function(e){Promise.resolve().then(function(){c=void 0,e(a())})})),c}}function E2(a){var c=a.reduce(function(e,i){var n=e[i.name];return e[i.name]=n?Object.assign({},n,i,{options:Object.assign({},n.options,i.options),data:Object.assign({},n.data,i.data)}):i,e},{});return Object.keys(c).map(function(e){return c[e]})}var F4={placement:"bottom",modifiers:[],strategy:"absolute"};function Z4(){for(var a=arguments.length,c=new Array(a),e=0;e(this.setSelectedItem(this.selectedItem-1,!0),!1)),i.register([],"ArrowDown",()=>(this.setSelectedItem(this.selectedItem+1,!0),!1)),i.register([],"Enter",n=>(this.useSelectedItem(n),!1)),i.register([],"Tab",n=>(this.useSelectedItem(n),!1))}chooseSuggestion(c){if(!this.items||!this.items.length)return;let e=this.items[this.selectedItem];e&&this.owner.selectSuggestion(e,c)}onSuggestionClick(c,e){if(c.preventDefault(),!this.suggestions||!this.suggestions.length)return;let i=this.suggestions.indexOf(e);this.setSelectedItem(i,!1),this.useSelectedItem(c)}onSuggestionMouseover(c,e){if(!this.suggestions||!this.suggestions.length)return;let i=this.suggestions.indexOf(e);this.setSelectedItem(i,!1)}empty(){this.containerEl.empty()}setSuggestions(c){this.containerEl.empty();let e=[];c.forEach(i=>{let n=this.containerEl.createDiv("suggestion-item");this.owner.renderSuggestion(i,n),e.push(n)}),this.items=c,this.suggestions=e,this.setSelectedItem(0,!1)}useSelectedItem(c){if(!this.items||!this.items.length)return;let e=this.items[this.selectedItem];e&&this.owner.selectSuggestion(e,c),q.Platform.isMobile&&this.chooseSuggestion(c)}wrap(c,e){return(c%e+e)%e}setSelectedItem(c,e){let i=this.wrap(c,this.suggestions.length),n=this.suggestions[this.selectedItem],o=this.suggestions[i];n&&n.removeClass("is-selected"),o&&o.addClass("is-selected"),this.selectedItem=i,e&&o.scrollIntoView(!1)}},O2=class extends q.FuzzySuggestModal{constructor(c,e,i){super(c);this.items=[];this.scope=new q.Scope;this.emptyStateText="No match found";this.limit=100;this.inputEl=e,this.items=i,this.suggestEl=createDiv("suggestion-container"),this.suggestEl.style.width=`${e.clientWidth}px`,this.contentEl=this.suggestEl.createDiv("suggestion"),this.suggester=new q4(this,this.contentEl,this.scope),this.scope.register([],"Escape",this.close.bind(this)),this.inputEl.addEventListener("input",this.onInputChanged.bind(this)),this.inputEl.addEventListener("focus",this.onInputChanged.bind(this)),this.inputEl.addEventListener("blur",this.close.bind(this)),this.suggestEl.on("mousedown",".suggestion-container",n=>{n.preventDefault()})}empty(){this.suggester.empty()}onInputChanged(){let c=this.modifyInput(this.inputEl.value),e=this.getSuggestions(c);e.length>0?this.suggester.setSuggestions(e.slice(0,this.limit)):this.onNoSuggestion(),this.open()}modifyInput(c){return c}onNoSuggestion(){this.empty(),this.renderSuggestion(null,this.contentEl.createDiv("suggestion-item"))}open(){this.app.keymap.pushScope(this.scope),document.body.appendChild(this.suggestEl),this.popper=D2(this.inputEl,this.suggestEl,{placement:"bottom-start",modifiers:[{name:"offset",options:{offset:[0,10]}},{name:"flip",options:{fallbackPlacements:["top"]}}]})}close(){this.app.keymap.popScope(this.scope),this.suggester.setSuggestions([]),this.popper&&this.popper.destroy(),this.suggestEl.detach()}createPrompt(c){this.promptEl||(this.promptEl=this.suggestEl.createDiv("prompt-instructions"));let e=this.promptEl.createDiv("prompt-instruction");for(let i of c)e.appendChild(i)}},I2=class extends O2{constructor(c,e){super(c.app,e.inputEl,c.iconManager.iconDefinitions);this.plugin=c;this.icons=c.iconManager.iconDefinitions,this.text=e,this.createPrompts(),this.inputEl.addEventListener("input",this.getItem.bind(this))}createPrompts(){}getItem(){let c=this.inputEl.value,e=this.icons.find(i=>i.name===c.trim());e!=this.icon&&(this.icon=e,this.icons&&this.onInputChanged())}getItemText(c){return c.name}onChooseItem(c){this.text.setValue(c.name),this.icon=c}selectSuggestion({item:c}){this.text.setValue(c.name),this.icon=c,this.onClose(),this.close()}renderSuggestion(c,e){let{item:i,match:n}=c||{},o=e.createDiv({cls:"suggestion-content icon"});if(!i){o.setText(this.emptyStateText),o.parentElement.addClass("is-selected");return}let r=n.matches.map(l=>createSpan("suggestion-highlight"));for(let l=0;ls[0]===l);if(f){let s=r[n.matches.indexOf(f)];o.appendChild(s),s.appendText(i.name.substring(f[0],f[1])),l+=f[1]-f[0]-1;continue}o.appendText(i.name[l])}let t=createDiv("suggestion-flair admonition-suggester-icon");t.appendChild(this.plugin.iconManager.getIconNode(i)??createDiv()),o.prepend(t),o.createDiv({cls:"suggestion-note",text:this.plugin.iconManager.getIconModuleName(i)})}getItems(){return this.icons}},U4=class extends O2{constructor(c,e,i){super(c.app,e.inputEl,i);this.plugin=c;this.admonitions=[...i],this.text=e,this.createPrompts(),this.inputEl.addEventListener("input",this.getItem.bind(this))}createPrompts(){}getItem(){let c=this.inputEl.value,e=this.admonitions.find(i=>i.type===c.trim());e!=this.admonition&&(this.admonition=e,this.admonitions&&this.onInputChanged())}getItemText(c){return c.type}onChooseItem(c){this.text.setValue(c.type),this.admonition=c}selectSuggestion({item:c}){this.text.setValue(c.type),this.onClose(),this.close()}renderSuggestion(c,e){let{item:i,match:n}=c||{},o=e.createDiv({cls:"suggestion-content icon"});if(!i){o.setText(this.emptyStateText),o.parentElement.addClass("is-selected");return}let r=n.matches.map(l=>createSpan("suggestion-highlight"));for(let l=0;ls[0]===l);if(f){let s=r[n.matches.indexOf(f)];o.appendChild(s),s.appendText(i.type.substring(f[0],f[1])),l+=f[1]-f[0]-1;continue}o.appendText(i.type[l])}let t=createDiv("suggestion-flair admonition-suggester-icon");t.appendChild(this.plugin.iconManager.getIconNode(i.icon)??createDiv()).setAttribute("color",`rgb(${i.color})`),o.prepend(t)}getItems(){return this.admonitions}},r2=class extends q.Modal{constructor(c){super(c.app);this.plugin=c;this.collapse=this.plugin.data.autoCollapse?this.plugin.data.defaultCollapseType:"none";this.containerEl.addClass("insert-admonition-modal"),this.onOpen=()=>this.display(!0)}async display(c){let{contentEl:e}=this;e.empty(),new q.Setting(e).setName("Admonition Type").addText(t=>{t.setPlaceholder("Admonition Type").setValue(this.type);let l=new U4(this.plugin,t,this.plugin.admonitionArray),f=()=>{t.inputEl.value&&this.plugin.admonitions[t.inputEl.value]?(this.type=t.inputEl.value,this.title?.length||(this.title=this.type[0].toUpperCase()+this.type.slice(1).toLowerCase()),n.setValue(this.title)):(new q.Notice("No admonition type by that name exists."),t.inputEl.value=""),this.buildAdmonition()};t.inputEl.onblur=f,l.onClose=f,c&&(l.open(),t.inputEl.focus())});let n;new q.Setting(e).setName("Admonition Title").setDesc("Leave blank to render without a title.").addText(t=>{n=t,t.setValue(this.title),t.onChange(l=>{if(this.title=l,l.length==0?this.noTitle=!0:this.noTitle=!1,this.element){let f=this.plugin.admonitions[this.type],s=this.plugin.getAdmonitionElement(this.type,this.title,f.icon,f.injectColor??this.plugin.data.injectColor?f.color:null,this.collapse);s.createDiv({cls:"admonition-content",text:"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla et euismod nulla."}),this.element.replaceWith(s),this.element=s}})}),new q.Setting(e).setName("Make Collapsible").addDropdown(t=>{t.addOption("open","Open"),t.addOption("closed","Closed"),t.addOption("none","None"),t.setValue(this.collapse),t.onChange(l=>{this.collapse=l,this.buildAdmonition()})}),this.admonitionEl=this.contentEl.createDiv(),this.buildAdmonition(),new q.Setting(e).addButton(t=>t.setButtonText("Insert").setCta().onClick(()=>{this.insert=!0,this.close()})).addExtraButton(t=>{t.setIcon("cross").setTooltip("Cancel").onClick(()=>this.close()),t.extraSettingsEl.setAttr("tabindex",0),t.extraSettingsEl.onkeydown=l=>{l.key=="Enter"&&this.close()}})}buildAdmonition(){if(this.admonitionEl.empty(),this.type&&this.plugin.admonitions[this.type]){let c=this.plugin.admonitions[this.type];this.element=this.plugin.getAdmonitionElement(this.type,this.title,c.icon,c.injectColor??this.plugin.data.injectColor?c.color:null,this.collapse),this.element.createDiv({cls:"admonition-content",text:"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla et euismod nulla."}),this.admonitionEl.appendChild(this.element)}}};var W4='/*\nTHIS IS A GENERATED/BUNDLED FILE BY ESBUILD\nif you want to view the source, please visit the github repository of this plugin\n*/\n\nfunction T(n,e,i){let t=document.createElement(n);typeof e=="string"&&(e={cls:e});let o=e||{},l=o.cls,s=o.text,a=o.attr,r=o.title,d=o.value,c=o.type,g=i||o.parent,f=o.prepend,m=o.href;return l&&(Array.isArray(l)?t.className=l.join(" "):t.className=l),s&&(t.textContent=s),a&&Object.keys(a).forEach(p=>{let E=a[p];E!==null&&t.setAttribute(p,String(E))}),r&&(t.title=r),d&&(t instanceof HTMLInputElement||t instanceof HTMLSelectElement||t instanceof HTMLOptionElement)&&(t.value=d),c&&t instanceof HTMLStyleElement&&t.setAttribute("type",c),m&&(t instanceof HTMLAnchorElement||t instanceof HTMLLinkElement)&&(t.href=m),g&&(f?g.insertBefore(t,g.firstChild):g.appendChild(t)),t}var h=function(n,e){return T("div",n,e)};Node.prototype.createDiv=function(n,e){return h(n,this)};Node.prototype.createEl=function(n,e,i){return T(n,e,this)};Element.prototype.addClass=function(...n){let e=[];for(let i=0;i{y(),b()};function w(){return new Promise((n,e)=>{let i=document.querySelector(".markdown-preview-sizer");if(i)n(i);else{let t=new MutationObserver(o=>{for(let l of o)if(l.type=="childList"&&l.addedNodes.length){for(let s of Array.from(l.addedNodes))if(s instanceof HTMLDivElement){if(s.hasClass("publish-renderer")){let a=s.querySelector(".markdown-preview-sizer");a&&(t.disconnect(),n(a))}s.hasClass("markdown-preview-sizer")&&(t.disconnect(),n(i))}}});t.observe(document.body,{attributes:!1,childList:!0,characterData:!1,subtree:!0})}})}async function b(){let n=await w();new MutationObserver(i=>{i.forEach(t=>{t.type=="childList"&&t.addedNodes.length&&t.addedNodes.forEach(o=>{if(o&&o instanceof HTMLDivElement&&!o.childElementCount){let l=new MutationObserver(s=>{for(let a of s)if(a.type=="childList"&&a.addedNodes.length)for(let r of Array.from(a.addedNodes))r instanceof HTMLPreElement&&(!M.has(r)&&Array.from(r.classList).some(d=>/language-ad-(\\w+)/.test(d))?(l.disconnect(),M.add(r),v(r)):(l.disconnect(),H(r)))});l.observe(o,{attributes:!1,childList:!0,characterData:!1,subtree:!1})}o&&o instanceof HTMLElement&&o.children.length&&o.firstElementChild instanceof HTMLPreElement&&H(o.firstElementChild)})})}).observe(n,{attributes:!1,childList:!0,subtree:!1})}function H(n){let e=new MutationObserver(i=>{i.forEach(t=>{t.target instanceof HTMLPreElement&&!M.has(t.target)&&t.type==="attributes"&&t.attributeName==="class"&&Array.from(t.target.classList).some(o=>/language-ad-(\\w+)/.test(o))&&(e.disconnect(),M.add(t.target),v(t.target))})});e.observe(n,{attributes:!0,childList:!1,characterData:!1,subtree:!1})}function v(n){let[,e]=n.classList.toString().match(/language-ad-(\\w+)/);if(!e||!(e in u.ADMONITION_ICON_MAP))return;let{title:i=e[0].toUpperCase()+e.slice(1).toLowerCase(),collapse:t,content:o,icon:l=u.ADMONITION_ICON_MAP[e].icon,color:s=u.ADMONITION_ICON_MAP[e].color}=N(e,n.innerText),a=L(e,i,l,s,t),d=a.createDiv("admonition-content-holder").createDiv("admonition-content");d.innerText=o,n.replaceWith(a)}function y(){let n=document.querySelectorAll("pre[class*=\'language-ad\']");if(!!n.length)for(let e of Array.from(n)){M.add(e);let[,i]=e.classList.toString().match(/language-ad-(\\w+)/);if(!i||!(i in u.ADMONITION_ICON_MAP))continue;let{title:t=i[0].toUpperCase()+i.slice(1).toLowerCase(),collapse:o,content:l,icon:s=u.ADMONITION_ICON_MAP[i].icon,color:a=u.ADMONITION_ICON_MAP[i].color}=N(i,e.innerText),r=L(i,t,s,a,o),c=r.createDiv("admonition-content-holder").createDiv("admonition-content");c.innerText=l,e.replaceWith(r)}}\n';var z3=J(require("obsidian"));var G4={};var _4={};var $4={};var Y4={};var B2={"Admonition Settings":"Admonition Settings","Use Obsidian's markdown syntax highlighter in admonition code blocks. This setting is experimental and could cause errors.":"Use Obsidian's markdown syntax highlighter in admonition code blocks. This setting is experimental and could cause errors.","Markdown Syntax Highlighting":"Markdown Syntax Highlighting","Try to sync internal links to the metadata cache to display in graph view. This setting could have unintended consequences. Use at your own risk.":"Try to sync internal links to the metadata cache to display in graph view. This setting could have unintended consequences. Use at your own risk."," Sync Links to Metadata Cache":" Sync Links to Metadata Cache","Allows admonitions to be created using ":"Allows admonitions to be created using "," or ":" or ",", instead of using a code block.":", instead of using a code block."," Enable Non-codeblock Admonitions":" Enable Non-codeblock Admonitions","Collapsible by Default":"Collapsible by Default","All admonitions will be collapsible by default. Use ":"All admonitions will be collapsible by default. Use "," to prevent.":" to prevent.","Default Collapse Type":"Default Collapse Type","Collapsible admonitions will be either opened or closed.":"Collapsible admonitions will be either opened or closed.","Add Copy Button":"Add Copy Button","Add a 'copy content' button to admonitions.":"Add a 'copy content' button to admonitions.","Add New":"Add New","Add a new Admonition type.":"Add a new Admonition type.","Add Additional":"Add Additional","Register Commands":"Register Commands","Unregister Commands":"Unregister Commands",Edit:"Edit",Delete:"Delete","Admonition Type":"Admonition Type","Admonition Title":"Admonition Title","This will be the default title for this admonition type.":"This will be the default title for this admonition type.","Admonition type cannot be empty.":"Admonition type cannot be empty.","Admonition type cannot include spaces.":"Admonition type cannot include spaces.","Types must be a valid CSS selector.":"Types must be a valid CSS selector.","Invalid icon name.":"Invalid icon name.","Icon cannot be empty.":"Icon cannot be empty.","Upload Image":"Upload Image","There was an error parsing the image.":"There was an error parsing the image.","Admonition Icon":"Admonition Icon",Color:"Color",Save:"Save","No Admonition Title by Default":"No Admonition Title by Default","The admonition will have no title unless ":"The admonition will have no title unless "," is explicitly provided.":" is explicitly provided.","Show Copy Button":"Show Copy Button","A copy button will be added to the admonition.":"A copy button will be added to the admonition.","Parse Titles as Markdown":"Parse Titles as Markdown","Admonition Titles will be rendered as markdown.":"Admonition Titles will be rendered as markdown."};var X4={};var K4={};var Q4={};var J4={};var c3={};var a3={};var e3={};var i3={};var n3={};var o3={};var t3={};var r3={};var l3={};var f3={};var s3={};var h3={};var m3={"Admonition Settings":"Admonition \u8BBE\u7F6E","Use Obsidian's markdown syntax highlighter in admonition code blocks. This setting is experimental and could cause errors.":"\u5728 admonition \u4EE3\u7801\u5757\u4E2D\u4F7F\u7528 Obsidian \u7684 markdown \u8BED\u6CD5\u9AD8\u4EAE\u3002\u8BE5\u8BBE\u7F6E\u4E3A\u5B9E\u9A8C\u6027\u9009\u9879\uFF0C\u53EF\u80FD\u4F1A\u5F15\u53D1\u9519\u8BEF\u3002","Markdown Syntax Highlighting":"Markdown \u8BED\u6CD5\u9AD8\u4EAE","Try to sync internal links to the metadata cache to display in graph view. This setting could have unintended consequences. Use at your own risk.":"\u5C1D\u8BD5\u5C06\u5185\u90E8\u94FE\u63A5\u540C\u6B65\u81F3 metadata \u7F13\u5B58\uFF0C\u4EE5\u4FBF\u5728\u56FE\u5F62\u89C6\u56FE\u4E2D\u663E\u793A\u3002\u8FD9\u4E2A\u8BBE\u7F6E\u53EF\u80FD\u4F1A\u4EA7\u751F\u610F\u60F3\u4E0D\u5230\u7684\u540E\u679C\u3002\u4F7F\u7528\u65F6\u8BF7\u81EA\u884C\u627F\u62C5\u98CE\u9669\u3002"," Sync Links to Metadata Cache":" \u540C\u6B65\u94FE\u63A5\u81F3 metadata \u7F13\u5B58","Allows admonitions to be created using ":"\u5141\u8BB8 admonitions \u521B\u5EFA\u4F7F\u7528\uFF0C"," or ":" \u6216 ",", instead of using a code block.":"\uFF0C\u800C\u975E\u4F7F\u7528\u4EE3\u7801\u5757\u3002"," Enable Non-codeblock Admonitions":" \u5141\u8BB8\u975E\u4EE3\u7801\u5757\u7684 Admonitions","Collapsible by Default":"\u9ED8\u8BA4\u6298\u53E0","All admonitions will be collapsible by default. Use ":"\u6240\u6709\u7684 admonitions \u9ED8\u8BA4\u53EF\u6298\u53E0\u3002\u4F7F\u7528 "," to prevent.":" \u6765\u963B\u6B62\u3002","Default Collapse Type":"\u9ED8\u8BA4\u53EF\u6298\u53E0\u7C7B\u578B","Collapsible admonitions will be either opened or closed.":"\u53EF\u6298\u53E0\u7684 admonitions \u5C06\u662F\u6253\u5F00\u7684\u6216\u662F\u5173\u95ED\u7684\u3002","Add Copy Button":"\u6DFB\u52A0\u590D\u5236\u6309\u94AE","Add a 'copy content' button to admonitions.":"\u4E3A admonitions \u65B0\u589E\u4E00\u4E2A\u201C\u590D\u5236\u5185\u5BB9\u201D\u6309\u94AE\u3002","Add New":"\u65B0\u589E","Add a new Admonition type.":"\u6DFB\u52A0\u4E00\u4E2A\u65B0\u7684 Admonition \u7C7B\u578B\u3002","Add Additional":"\u989D\u5916\u6DFB\u52A0","Register Commands":"\u6CE8\u518C\u547D\u4EE4","Unregister Commands":"\u6CE8\u9500\u547D\u4EE4",Edit:"\u7F16\u8F91",Delete:"\u5220\u9664","Admonition Type":"Admonition \u7C7B\u578B","Admonition Title":"Admonition \u540D\u79F0","This will be the default title for this admonition type.":"\u8FD9\u5C06\u4F1A\u6210\u4E3A\u8BE5\u7C7B\u578B admonition \u7684\u9ED8\u8BA4\u540D\u79F0\u3002","Admonition type cannot be empty.":"Admonition \u7C7B\u578B\u4E0D\u80FD\u4E3A\u7A7A\u3002","Admonition type cannot include spaces.":"Admonition \u7C7B\u578B\u4E0D\u80FD\u5305\u542B\u7A7A\u683C","Types must be a valid CSS selector.":"\u7C7B\u578B\u5FC5\u987B\u4E3A\u5408\u6CD5\u7684 CSS \u9009\u62E9\u5668\u3002","Invalid icon name.":"\u975E\u6CD5\u56FE\u6807\u540D\u79F0\u3002","Icon cannot be empty.":"\u56FE\u6807\u4E0D\u80FD\u4E3A\u7A7A\u3002","Upload Image":"\u4E0A\u4F20\u56FE\u50CF","There was an error parsing the image.":"\u4E0A\u4F20\u56FE\u50CF\u65F6\u51FA\u9519\u4E86\u3002","Admonition Icon":"Admonition \u56FE\u6807",Color:"\u989C\u8272",Save:"\u4FDD\u5B58","No Admonition Title by Default":"\u65E0\u9ED8\u8BA4 Admonition \u540D\u79F0","The admonition will have no title unless ":"\u8BE5 admonition \u5C06\u6CA1\u6709\u540D\u79F0\uFF0C\u9664\u975E "," is explicitly provided.":" \u662F\u660E\u786E\u89C4\u5B9A\u7684\u3002","Show Copy Button":"\u663E\u793A\u590D\u5236\u6309\u94AE","A copy button will be added to the admonition.":"\u4E00\u4E2A\u590D\u5236\u6309\u94AE\u5C06\u88AB\u6DFB\u52A0\u81F3\u8BE5 admonition ","Parse Titles as Markdown":"\u5C06\u540D\u79F0\u8F6C\u53D8\u4E3A Markdown","Admonition Titles will be rendered as markdown.":"Admonition \u540D\u79F0\u5C06\u4EE5 markdown \u5F62\u5F0F\u5448\u73B0\u3002"};var v3={};var Z6={ar:G4,cs:_4,da:$4,de:Y4,en:B2,"en-gb":X4,es:K4,fr:Q4,hi:J4,id:c3,it:a3,ja:e3,ko:i3,nl:n3,nn:o3,pl:t3,pt:r3,"pt-br":l3,ro:f3,ru:s3,tr:h3,"zh-cn":m3,"zh-tw":v3},p3=Z6[z3.moment.locale()];function g(a){return p3&&p3[a]||B2[a]}var Z1=J(require("obsidian"));async function d3(a,c,e={cta:"Yes",secondary:"No"}){return new Promise((i,n)=>{try{let o=new u3(a,c,e);o.onClose=()=>{i(o.confirmed)},o.open()}catch{n()}})}var u3=class extends Z1.Modal{constructor(c,e,i){super(c);this.text=e;this.buttons=i;this.confirmed=!1}async display(){this.contentEl.empty(),this.contentEl.addClass("confirm-modal"),this.contentEl.createEl("p",{text:this.text});let c=this.contentEl.createDiv("fantasy-calendar-confirm-buttons");new Z1.ButtonComponent(c).setButtonText(this.buttons.cta).setCta().onClick(()=>{this.confirmed=!0,this.close()}),new Z1.ButtonComponent(c).setButtonText(this.buttons.secondary).onClick(()=>{this.close()})}onOpen(){this.display()}};var H1={octicons:"Octicons",rpg:"RPG Awesome"};var M3=(a=>c=>{try{a.querySelector(c)}catch{return!1}return!0})(document.createDocumentFragment()),l2=class extends u.PluginSettingTab{constructor(c,e){super(c,e);this.plugin=e;this.queue=[];this.converted=0}async display(){this.containerEl.empty(),this.containerEl.addClass("admonition-settings"),this.containerEl.createEl("h2",{text:g("Admonition Settings")});let c=this.containerEl.createDiv("admonitions-nested-settings");u.Platform.isMobile||new u.Setting(c).setName("Export Custom Types as CSS").setDesc("Export a CSS snippet for custom callout types.").addButton(i=>i.setIcon("download").onClick(()=>{let n=[`/* This snippet was auto-generated by the Admonitions plugin */ `],o=new Blob([this.plugin.calloutManager.generateCssString()],{type:"text/css"});createEl("a",{attr:{download:"custom_callouts.css",href:URL.createObjectURL(o)}}).click()}).setDisabled(!Object.keys(this.plugin.data.userAdmonitions).length)),new u.Setting(c).setName("Use CSS Snippet for Custom Callouts").setDesc("Instead of managing it internally, Admonitions will maintain a CSS snippet to enable your custom types for callouts.").addToggle(i=>i.setValue(this.plugin.data.useSnippet).onChange(n=>{this.plugin.data.useSnippet=n,this.plugin.saveSettings(),this.plugin.calloutManager.setUseSnippet()})),new u.Setting(c).setName(g("Add New")).setDesc("Add a new Admonition type. All custom Admonitions will also be usable as callouts.").addButton(i=>i.setTooltip(g("Add Additional")).setButtonText("+").onClick(async()=>{let o=new F(this.plugin);o.onClose=async()=>{if(o.saved){let r={type:o.type,color:o.color,icon:o.icon,command:!1,title:o.title,injectColor:o.injectColor,noTitle:o.noTitle,copy:o.copy};this.plugin.addAdmonition(r),this.plugin.calloutManager.addAdmonition(r),this.display()}},o.open()})),this.additionalEl=c.createDiv("additional"),this.buildTypes(),this.buildAdmonitions(this.containerEl.createEl("details",{cls:"admonitions-nested-settings",attr:{...this.plugin.data.open.admonitions?{open:!0}:{}}})),this.buildIcons(this.containerEl.createEl("details",{cls:"admonitions-nested-settings",attr:{...this.plugin.data.open.icons?{open:!0}:{}}})),this.buildOtherSyntaxes(this.containerEl.createEl("details",{cls:"admonitions-nested-settings",attr:{...this.plugin.data.open.other?{open:!0}:{}}})),this.buildAdvanced(this.containerEl.createEl("details",{cls:"admonitions-nested-settings",attr:{...this.plugin.data.open.advanced?{open:!0}:{}}})),this.containerEl.createDiv("coffee").createEl("a",{href:"https://www.buymeacoffee.com/valentine195"}).createEl("img",{attr:{src:"https://img.buymeacoffee.com/button-api/?text=Buy me a coffee&emoji=\u2615&slug=valentine195&button_colour=e3e7ef&font_colour=262626&font_family=Inter&outline_colour=262626&coffee_colour=ff0000"}})}buildAdmonitions(c){c.empty(),c.ontoggle=()=>{this.plugin.data.open.admonitions=c.open,this.plugin.saveSettings()};let e=c.createEl("summary");new u.Setting(e).setHeading().setName("Admonitions & Callouts"),e.createDiv("collapser").createDiv("handle"),new u.Setting(c).setName("Add Drop Shadow").setDesc("A drop shadow will be added to admonitions.").addToggle(i=>{i.setValue(this.plugin.data.dropShadow).onChange(async n=>{this.plugin.data.dropShadow=n,this.display(),await this.plugin.saveSettings()})}),new u.Setting(c).setName(g("Collapsible by Default")).setDesc(createFragment(i=>{i.createSpan({text:"All admonitions & callouts will be collapsible by default. Use "}),i.createEl("code",{text:"collapse: none"}),i.createSpan({text:g(" to prevent.")})})).addToggle(i=>{i.setValue(this.plugin.data.autoCollapse).onChange(async n=>{this.plugin.data.autoCollapse=n,this.display(),await this.plugin.saveSettings()})}),this.plugin.data.autoCollapse&&new u.Setting(c).setName(g("Default Collapse Type")).setDesc("Collapsible admonitions & callouts will be either opened or closed.").addDropdown(i=>{i.addOption("open","open"),i.addOption("closed","closed"),i.setValue(this.plugin.data.defaultCollapseType),i.onChange(async n=>{this.plugin.data.defaultCollapseType=n,await this.plugin.saveSettings()})}),new u.Setting(c).setName(g("Add Copy Button")).setDesc("Add a 'copy content' button to admonitions & callouts.").addToggle(i=>{i.setValue(this.plugin.data.copyButton),i.onChange(async n=>{this.plugin.data.copyButton=n,n||document.querySelectorAll(".admonition-content-copy").forEach(o=>{o.detach()}),await this.plugin.saveSettings()})}),new u.Setting(c).setName(g("Parse Titles as Markdown")).setDesc(g("Admonition Titles will be rendered as markdown.")).addToggle(i=>{i.setValue(this.plugin.data.parseTitles),i.onChange(async n=>{this.plugin.data.parseTitles=n,await this.plugin.saveSettings()})}),new u.Setting(c).setName("Set Admonition Colors").setDesc("Disable this setting to turn off admonition coloring by default. Can be overridden in the admonition definition.").addToggle(i=>i.setValue(this.plugin.data.injectColor).setTooltip(`${this.plugin.data.injectColor?"Disable":"Enable"} Admonition Color`).onChange(async n=>{this.plugin.data.injectColor=n,await this.plugin.saveSettings(),await this.buildTypes()})),new u.Setting(c).setName("Hide Empty Admonitions").setDesc("Any admonition that does not have content inside it will be hidden.").addToggle(i=>i.setValue(this.plugin.data.hideEmpty).onChange(async n=>{this.plugin.data.hideEmpty=n,await this.plugin.saveSettings(),await this.buildTypes()}))}buildIcons(c){c.empty(),c.ontoggle=()=>{this.plugin.data.open.icons=c.open,this.plugin.saveSettings()};let e=c.createEl("summary");new u.Setting(e).setHeading().setName("Icon Packs"),e.createDiv("collapser").createDiv("handle"),new u.Setting(c).setName("Use Font Awesome Icons").setDesc("Font Awesome Free icons will be available in the item picker. Existing Admonitions defined using Font Awesome icons will continue to work.").addToggle(r=>{r.setValue(this.plugin.data.useFontAwesome).onChange(t=>{this.plugin.data.useFontAwesome=t,this.plugin.iconManager.setIconDefinitions(),this.plugin.saveSettings()})});let i,n=Object.entries(H1).filter(([r])=>!this.plugin.data.icons.includes(r));new u.Setting(c).setName("Load Additional Icons").setDesc("Load an additional icon pack. This requires an internet connection.").addDropdown(r=>{if(!n.length){r.setDisabled(!0);return}for(let[t,l]of n)r.addOption(t,l);r.onChange(t=>i=t),i=r.getValue()}).addExtraButton(r=>{r.setIcon("plus-with-circle").setTooltip("Load").onClick(async()=>{!i||!i.length||(await this.plugin.iconManager.downloadIcon(i),this.buildIcons(c))}),n.length||r.setDisabled(!0)});let o=c.createDiv("admonitions-nested-settings");new u.Setting(o);for(let r of this.plugin.data.icons)new u.Setting(o).setName(H1[r]).addExtraButton(t=>{t.setIcon("reset").setTooltip("Redownload").onClick(async()=>{await this.plugin.iconManager.removeIcon(r),await this.plugin.iconManager.downloadIcon(r),this.buildIcons(c)})}).addExtraButton(t=>{t.setIcon("trash").onClick(async()=>{Object.values(this.plugin.data.userAdmonitions).find(l=>l.icon.type==r)&&!await d3(this.plugin.app,"You have Admonitions using icons from this pack. Are you sure you want to remove it?")||(await this.plugin.iconManager.removeIcon(r),this.buildIcons(c))})})}buildOtherSyntaxes(c){c.empty(),c.ontoggle=()=>{this.plugin.data.open.other=c.open,this.plugin.saveSettings()};let e=c.createEl("summary");new u.Setting(e).setHeading().setName("Additional Syntaxes"),e.createDiv("collapser").createDiv("handle"),c.createEl("p",{text:"Obsidian 0.14 has introduced Callout boxes to its core functionality using the same syntax as the Microsoft Document callouts.",cls:"setting-item"}),c.createEl("p",{text:"This has rendered the Microsoft Document syntax for Admonitions obsolete, but Admonitions can still be used to create and manage your custom callout types.",cls:"setting-item"}),c.createEl("p",{text:"Your existing code block Admonitions will always work!",cls:"setting-item"}),this.plugin.data.msDocConverted||new u.Setting(c).setName("Convert MSDoc Admonitions to Callouts").setDesc(createFragment(i=>{let n=i.createDiv("admonition-convert");(0,u.setIcon)(n.createSpan(),P1),n.createSpan({text:"This "}),n.createEl("strong",{text:"will"}),n.createSpan({text:" modify notes. Use at your own risk and please make backups."}),i.createEl("p",{text:"With large vaults, this could take awhile!"})})).addButton(i=>i.setButtonText("Convert").setCta().onClick(()=>{this.queue=this.plugin.app.vault.getMarkdownFiles(),this.notice=new u.Notice(createFragment(n=>{let o=n.createDiv("admonition-convert");o.createSpan({text:"Converting MS-doc admonitions..."}),(0,u.setIcon)(o.createSpan("admonition-convert-icon"),E1)}),0),this.checkAndReplace()})),new u.Setting(c).setName("Convert Codeblock Admonitions to Callouts").setDesc(createFragment(i=>{let n=i.createDiv("admonition-convert");(0,u.setIcon)(n.createSpan(),P1),n.createSpan({text:"This "}),n.createEl("strong",{text:"will"}),n.createSpan({text:" modify notes. Use at your own risk and please make backups."}),i.createEl("p",{text:"With large vaults, this could take awhile!"})})).addButton(i=>i.setButtonText("Convert").setCta().onClick(()=>{this.queue=this.plugin.app.vault.getMarkdownFiles(),this.notice=new u.Notice(createFragment(n=>{let o=n.createDiv("admonition-convert");o.createSpan({text:"Converting Codeblock admonitions..."}),(0,u.setIcon)(o.createSpan("admonition-convert-icon"),E1)}),0),this.converted=0,this.checkAndReplaceCodeBlocks()}))}async checkAndReplace(){if(!this.queue.length){this.converted?this.notice.setMessage(`${this.converted} MS-doc Admonitions converted!`):this.notice.setMessage("No MS-doc Admonitions found to convert."),this.plugin.data.msDocConverted=!0,this.plugin.saveSettings().then(()=>this.display()),setTimeout(()=>{this.notice.hide(),this.notice=void 0},2e3);return}setTimeout(async()=>{let c=this.queue.shift(),e=await this.app.vault.read(c);/> \[!([^ :]+)(?::[ ]?(.+))\](x|\+|\-)?/.test(e)&&(this.converted++,await this.plugin.app.vault.modify(c,e.replace(/> \[!([^ :]+)(?::[ ]?(.+))\](x|\+|\-)?/g,"> [!$1]$3 $2"))),this.checkAndReplace()})}async checkAndReplaceCodeBlocks(){if(!this.queue.length){this.converted?this.notice.setMessage(`${this.converted} Codeblock Admonitions converted!`):this.notice.setMessage("No Codeblock Admonitions found to convert."),this.display(),setTimeout(()=>{this.notice.hide(),this.notice=void 0},2e3);return}setTimeout(async()=>{let c=this.queue.shift(),e=await this.app.vault.read(c);/^(`{3,})ad-(\w+)([\s\S]*?)?\n^\1/m.test(e)&&(e=this.replaceCodeBlockInPlace(e),this.app.vault.modify(c,e)),this.checkAndReplaceCodeBlocks()})}replaceCodeBlockInPlace(c){let e=c.match(/^(`{3,})ad-(\w+)([\s\S]*?)?\n^\1/gm)??[];for(let i of e){let[,n]=i.match(/^`{3,}ad-(\w+)/),o="",r="";if(!n)continue;let t=[],l=!0;for(let s of i.split(` `).slice(1,-1)){if(l){if(/^title:/.test(s)){o=s.match(/^title:(.*)/)?.[1].trim()??n[0].toUpperCase()+n.slice(1).toLowerCase();continue}if(/^collapse:/.test(s)){r=(s.match(/^collapse:\s?(.*)/)?.[1].trim()??"open")=="open"?"+":"-";continue}/^(title|collapse|color|icon):/.test(s)||(l=!1)}t.push(s)}let f=t.join(` diff --git a/.obsidian/plugins/obsidian-admonition/manifest.json b/.obsidian/plugins/obsidian-admonition/manifest.json index 12b6e6a5..f87b1acb 100644 --- a/.obsidian/plugins/obsidian-admonition/manifest.json +++ b/.obsidian/plugins/obsidian-admonition/manifest.json @@ -1,7 +1,7 @@ { "id": "obsidian-admonition", "name": "Admonition", - "version": "9.0.4", + "version": "9.0.5", "minAppVersion": "0.14.0", "description": "Enhanced callouts for Obsidian.md", "author": "Jeremy Valentine", diff --git a/.obsidian/plugins/obsidian-commits/data.json b/.obsidian/plugins/obsidian-commits/data.json index 90a03bda..eff61215 100644 --- a/.obsidian/plugins/obsidian-commits/data.json +++ b/.obsidian/plugins/obsidian-commits/data.json @@ -1590,9 +1590,9 @@ "links": 0 }, "00.01 Admin/Test sheet.md": { - "size": 12366, + "size": 10826, "tags": 5, - "links": 10 + "links": 12 }, "00.01 Admin/Templates/layout$address.md": { "size": 51, @@ -5568,14 +5568,59 @@ "size": 1367, "tags": 1, "links": 3 + }, + "00.03 News/Was Vincent van Gogh Color Blind It Sure Looks Like It.md": { + "size": 4846, + "tags": 3, + "links": 1 + }, + "00.01 Admin/Calendars/2022-09-05.md": { + "size": 1213, + "tags": 0, + "links": 6 + }, + "03.04 Cinematheque/Men in Black (1997).md": { + "size": 1993, + "tags": 1, + "links": 1 + }, + "03.04 Cinematheque/Men in Black II (2002).md": { + "size": 1963, + "tags": 1, + "links": 1 + }, + "03.04 Cinematheque/Men in Black 3 (2012).md": { + "size": 1966, + "tags": 1, + "links": 1 + }, + "03.04 Cinematheque/The Lord of the Rings - The Fellowship of the Ring (2001).md": { + "size": 2064, + "tags": 1, + "links": 1 + }, + "03.04 Cinematheque/The Lord of the Rings - The Return of the King (2003).md": { + "size": 2054, + "tags": 1, + "links": 1 + }, + "03.04 Cinematheque/The Lord of the Rings - The Two Towers (2002).md": { + "size": 2040, + "tags": 1, + "links": 1 + }, + "00.01 Admin/Calendars/2022-09-06.md": { + "size": 1135, + "tags": 0, + "links": 4 } }, "commitTypes": { "/": { - "Refactor": 756, - "Create": 810, - "Link": 1697, - "Expand": 756 + "Refactor": 774, + "Create": 828, + "Link": 1715, + "Expand": 757 } }, "dailyCommits": { @@ -5586,9 +5631,9 @@ "3": 9, "4": 13, "5": 6, - "6": 33, - "7": 259, - "8": 407, + "6": 53, + "7": 262, + "8": 409, "9": 391, "10": 252, "11": 201, @@ -5597,29 +5642,30 @@ "14": 214, "15": 224, "16": 186, - "17": 179, + "17": 205, "18": 372, "19": 189, "20": 139, - "21": 114, - "22": 257, + "21": 115, + "22": 260, "23": 63 } }, "weeklyCommits": { "/": { - "Mon": 611, - "Tue": 491, + "Mon": 658, + "Tue": 495, "Wed": 541, "Thu": 374, "Fri": 346, "Sat": 0, - "Sun": 1656 + "Sun": 1660 } }, "recentCommits": { "/": { "Expanded": [ + " 2022-09-05 ", " Kiosk ", " Household ", " 2022-09-04 ", @@ -5669,10 +5715,27 @@ " @@Zürich ", " 2022-08-26 ", " 2022-08-25 ", - " 2022-08-06 ", - " 2022-02-28 " + " 2022-08-06 " ], "Created": [ + " Untitled ", + " 2022-09-06 ", + " The Lord of the Rings - The Return of the King (2003) ", + " The Lord of the Rings - The Two Towers (2002) ", + " The Lord of the Rings - The Fellowship of the Ring (2001) ", + " Men in Black 3 (2012) ", + " Men in Black II (2002) ", + " Men in Black (1997) ", + " Untitled ", + " Untitled ", + " Untitled ", + " Untitled ", + ".md\"> <% tp.date.now(\"YYYY-MM-DD\", -1) %> ", + ".md\"> <% tp.date.now(\"YYYY-MM-DD\", -1) %> ", + " 2022-09-05 ", + " 2022-09-05 ", + " 2022-09-05 ", + " Was Vincent van Gogh Color Blind It Sure Looks Like It ", " Kiosk ", " You Must Remember This - 1989 sex lies and videotape Rob Lowe and James Spader (Erotic 80s Part 12) ", " 2022-09-04 ", @@ -5705,27 +5768,16 @@ " Untitled ", " The Deacon and the Dog City Journal ", " Opinion Maternal Instinct Is a Myth That Men Created ", - " Was King Arthur a Real Person ", - " Why Don’t Millennials Have Hobbies ", - " ‘Screw This City’ There’s Never Been a Worse Time to Rent an Apartment in NYC ", - " 2022-08-28 ", - " 2022-11-02 Juventus - PSG ", - " Renegades Born in the USA - Our Unlikely Friendship ", - " 2022-09-08 Diamond League Final ", - " 2022-08-27 ", - " 2022-08-26 ", - " 2022-08-25 ", - " Untitled ", - " Untitled ", - " Untitled ", - " Untitled ", - " ReadItLater ", - " ReadItLater ", - " ReadItLater ", - " ReadItLater ", - " Untitled " + " Was King Arthur a Real Person " ], "Renamed": [ + " The Lord of the Rings - The Two Towers (2002) ", + " The Lord of the Rings - The Return of the King (2003) ", + " The Lord of the Rings - The Fellowship of the Ring (2001) ", + " Men in Black 3 (2012) ", + " Men in Black II (2002) ", + " Men in Black (1997) ", + " Was Vincent van Gogh Color Blind It Sure Looks Like It ", " Kiosk ", " 2022-09-03 Nantes - Paris SG (0-3) ", " 2022-08-31 Toulouse - Paris SG (0-3) ", @@ -5769,16 +5821,16 @@ " Le Mezzerie ", " Django (1966) ", " Bebek ", - " Dolder Grand ", - " GoldenEye (1995) ", - " Romain Gary ", - " Template Music ", - " Template Wiki ", - " Template Game ", - " Template TVShow ", - " Template Movie " + " Dolder Grand " ], "Tagged": [ + " The Lord of the Rings - The Return of the King (2003) ", + " The Lord of the Rings - The Fellowship of the Ring (2001) ", + " The Lord of the Rings - The Two Towers (2002) ", + " Men in Black II (2002) ", + " Men in Black 3 (2012) ", + " Men in Black (1997) ", + " Was Vincent van Gogh Color Blind It Sure Looks Like It ", " Kiosk ", " Paris SG ", " Monocle ", @@ -5822,16 +5874,11 @@ " The Queen's Gambit (2020) ", " The Simpsons (1989–) ", " Mad Men (2007–2015) ", - " House of Cards (2013–2018) ", - " The Office (2005–2013) ", - " Narcos (2015–2017) ", - " Succession (2018–) ", - " Peaky Blinders (2013–2022) ", - " Spiral (2005–2020) ", - " Californication (2007–2014) ", - " Breaking Bad (2008–2013) " + " House of Cards (2013–2018) " ], "Refactored": [ + " 2022-09-05 ", + " Test sheet ", " Server Cloud ", " Server Cloud ", " Server Cloud ", @@ -5880,11 +5927,18 @@ " Obsidian plugins ", " @Reading master ", " Equity Tasks ", - " Crypto Tasks ", - " VC Tasks ", - " Storage and Syncing " + " Crypto Tasks " ], "Deleted": [ + " Ytes ", + " Test ", + " with a title ", + " Untitled ", + " Test ", + ".md\"> <% tp.date.now(\"YYYY-MM-DD\", -1) %> ", + ".md\"> <% tp.date.now(\"YYYY-MM-DD\", -1) %> ", + " 2022-09-05 ", + " 2022-09-05 ", " You Must Remember This - 1989 sex lies and videotape Rob Lowe and James Spader (Erotic 80s Part 12) ", " You Must Remember This - 1989 sex lies and videotape Rob Lowe and James Spader (Erotic 80s Part 12) ", " Romain Gary 2 ", @@ -5926,18 +5980,20 @@ " Morning Buns ", " Bibimbap ", " Email alias ", - " Landing Page ", - " DG - News Page ", - " Mobile - CH ", - " WiFI - ZH Guest ", - " Untitled ", - " Churros with Bittersweet Chocolate Sauce 1 ", - " Shopping ", - " delete ", - " 2022-03-31 ", - " Installer Node Exporte... Doc SysNetAdmin " + " Landing Page " ], "Linked": [ + " 2022-09-06 ", + " 2022-09-05 ", + " The Lord of the Rings - The Return of the King (2003) ", + " The Lord of the Rings - The Fellowship of the Ring (2001) ", + " The Lord of the Rings - The Two Towers (2002) ", + " Men in Black II (2002) ", + " Men in Black 3 (2012) ", + " Men in Black (1997) ", + " 2022-09-05 ", + " Was Vincent van Gogh Color Blind It Sure Looks Like It ", + " Test sheet ", " 2022-09-04 ", " League Tables ", " Kiosk ", @@ -5977,18 +6033,7 @@ " Nextcloud ", " 2022-08-31 ", " 2022-11-19 Fiancailles Marguerite & Arnold - Paris ", - " 2023-01-14 Mariage Marguerite & Arnold ", - " Was King Arthur a Real Person ", - " Opinion Maternal Instinct Is a Myth That Men Created ", - " 2022-08-31 ", - " 2022-08-30 ", - " Test sheet ", - " 2022-08-30 ", - " 2022-08-30 ", - " Derinkuyu Mysterious underground city in Turkey found in man’s basement ", - " The Deacon and the Dog City Journal ", - " Why Don’t Millennials Have Hobbies ", - " 2022-08-19 " + " 2023-01-14 Mariage Marguerite & Arnold " ], "Removed Tags from": [ " Le Miel de Paris ", diff --git a/.obsidian/plugins/obsidian-reminder-plugin/data.json b/.obsidian/plugins/obsidian-reminder-plugin/data.json index 76f3ca5d..4e190268 100644 --- a/.obsidian/plugins/obsidian-reminder-plugin/data.json +++ b/.obsidian/plugins/obsidian-reminder-plugin/data.json @@ -315,7 +315,7 @@ "01.03 Family/Ophélie Bédier.md": [ { "title": ":birthday: **[[Ophélie Bédier|Ophélie]]** %%done_del%%", - "time": "2022-09-05", + "time": "2023-09-05", "rowNumber": 100 } ], @@ -341,15 +341,10 @@ } ], "01.02 Home/Household.md": [ - { - "title": "♻ [[Household]]: *Cardboard* recycling collection %%done_del%%", - "time": "2022-09-06", - "rowNumber": 77 - }, { "title": "🛎 🧻 REMINDER [[Household]]: check need for toilet paper %%done_del%%", "time": "2022-09-12", - "rowNumber": 85 + "rowNumber": 86 }, { "title": "♻ [[Household]]: *Paper* recycling collection %%done_del%%", @@ -359,12 +354,17 @@ { "title": ":bed: [[Household]] Change bedsheets %%done_del%%", "time": "2022-09-17", - "rowNumber": 88 + "rowNumber": 89 + }, + { + "title": "♻ [[Household]]: *Cardboard* recycling collection %%done_del%%", + "time": "2022-09-20", + "rowNumber": 77 }, { "title": "🛎 🛍 REMINDER [[Household]]: Monthly shop in France %%done_del%%", "time": "2022-09-24", - "rowNumber": 83 + "rowNumber": 84 }, { "title": "🛌 [[Household]]: Buy new bed clothes", @@ -576,6 +576,13 @@ "time": "2022-10-10", "rowNumber": 86 } + ], + "00.01 Admin/Calendars/2022-09-05.md": [ + { + "title": "17:44 :camera_flash: [[2022-09-05|Memo]], [[@Computer Set Up|Tech stack]]: find a solution to sync pictures from iphone to external hard drive", + "time": "2022-09-09", + "rowNumber": 80 + } ] }, "debug": false, diff --git a/.obsidian/plugins/obsidian-task-completer/main.js b/.obsidian/plugins/obsidian-task-completer/main.js new file mode 100644 index 00000000..1426d0e5 --- /dev/null +++ b/.obsidian/plugins/obsidian-task-completer/main.js @@ -0,0 +1,8 @@ +var In=Object.create;var Lt=Object.defineProperty,Hn=Object.defineProperties,Fn=Object.getOwnPropertyDescriptor,Wn=Object.getOwnPropertyDescriptors,zn=Object.getOwnPropertyNames,Mi=Object.getOwnPropertySymbols,qn=Object.getPrototypeOf,Di=Object.prototype.hasOwnProperty,Kn=Object.prototype.propertyIsEnumerable;var Oi=(n,t,e)=>t in n?Lt(n,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[t]=e,Se=(n,t)=>{for(var e in t||(t={}))Di.call(t,e)&&Oi(n,e,t[e]);if(Mi)for(var e of Mi(t))Kn.call(t,e)&&Oi(n,e,t[e]);return n},ke=(n,t)=>Hn(n,Wn(t)),Ti=n=>Lt(n,"__esModule",{value:!0});var $n=(n,t)=>()=>(t||n((t={exports:{}}).exports,t),t.exports),jn=(n,t)=>{Ti(n);for(var e in t)Lt(n,e,{get:t[e],enumerable:!0})},Gn=(n,t,e)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of zn(t))!Di.call(n,i)&&i!=="default"&&Lt(n,i,{get:()=>t[i],enumerable:!(e=Fn(t,i))||e.enumerable});return n},Ri=n=>Gn(Ti(Lt(n!=null?In(qn(n)):{},"default",n&&n.__esModule&&"default"in n?{get:()=>n.default,enumerable:!0}:{value:n,enumerable:!0})),n);var Ce=(n,t,e)=>new Promise((i,s)=>{var r=h=>{try{l(e.next(h))}catch(a){s(a)}},o=h=>{try{l(e.throw(h))}catch(a){s(a)}},l=h=>h.done?i(h.value):Promise.resolve(h.value).then(r,o);l((e=e.apply(n,t)).next())});var Ei=$n(Zt=>{"use strict";Object.defineProperty(Zt,"__esModule",{value:!0});require("obsidian");var Un=n=>{var t;return n?(t=n.plugins.plugins.dataview)===null||t===void 0?void 0:t.api:window.DataviewAPI},Jn=n=>n.plugins.enabledPlugins.has("dataview");Zt.getAPI=Un;Zt.isPluginEnabled=Jn});jn(exports,{default:()=>Ci});var Nn=Ri(Ei()),Et=Ri(require("obsidian"));var x=class{constructor(){}lineAt(t){if(t<0||t>this.length)throw new RangeError(`Invalid position ${t} in document of length ${this.length}`);return this.lineInner(t,!1,1,0)}line(t){if(t<1||t>this.lines)throw new RangeError(`Invalid line number ${t} in ${this.lines}-line document`);return this.lineInner(t,!0,1,0)}replace(t,e,i){let s=[];return this.decompose(0,t,s,2),i.length&&i.decompose(0,i.length,s,1|2),this.decompose(e,this.length,s,1),G.from(s,this.length-(e-t)+i.length)}append(t){return this.replace(this.length,this.length,t)}slice(t,e=this.length){let i=[];return this.decompose(t,e,i,0),G.from(i,e-t)}eq(t){if(t==this)return!0;if(t.length!=this.length||t.lines!=this.lines)return!1;let e=this.scanIdentical(t,1),i=this.length-this.scanIdentical(t,-1),s=new yt(this),r=new yt(t);for(let o=e,l=e;;){if(s.next(o),r.next(o),o=0,s.lineBreak!=r.lineBreak||s.done!=r.done||s.value!=r.value)return!1;if(l+=s.value.length,s.done||l>=i)return!0}}iter(t=1){return new yt(this,t)}iterRange(t,e=this.length){return new Ae(this,t,e)}iterLines(t,e){let i;if(t==null)i=this.iter();else{e==null&&(e=this.lines+1);let s=this.line(t).from;i=this.iterRange(s,Math.max(s,e==this.lines+1?this.length:e<=1?0:this.line(e-1).to))}return new Me(i)}toString(){return this.sliceString(0)}toJSON(){let t=[];return this.flatten(t),t}static of(t){if(t.length==0)throw new RangeError("A document must have at least one line");return t.length==1&&!t[0]?x.empty:t.length<=32?new D(t):G.from(D.split(t,[]))}},D=class extends x{constructor(t,e=Xn(t)){super();this.text=t,this.length=e}get lines(){return this.text.length}get children(){return null}lineInner(t,e,i,s){for(let r=0;;r++){let o=this.text[r],l=s+o.length;if((e?i:l)>=t)return new Bi(s,l,i,o);s=l+1,i++}}decompose(t,e,i,s){let r=t<=0&&e>=this.length?this:new D(Li(this.text,t,e),Math.min(e,this.length)-Math.max(0,t));if(s&1){let o=i.pop(),l=Qt(r.text,o.text.slice(),0,r.length);if(l.length<=32)i.push(new D(l,o.length+r.length));else{let h=l.length>>1;i.push(new D(l.slice(0,h)),new D(l.slice(h)))}}else i.push(r)}replace(t,e,i){if(!(i instanceof D))return super.replace(t,e,i);let s=Qt(this.text,Qt(i.text,Li(this.text,0,t)),e),r=this.length+i.length-(e-t);return s.length<=32?new D(s,r):G.from(D.split(s,[]),r)}sliceString(t,e=this.length,i=` +`){let s="";for(let r=0,o=0;r<=e&&ot&&o&&(s+=i),tr&&(s+=l.slice(Math.max(0,t-r),e-r)),r=h+1}return s}flatten(t){for(let e of this.text)t.push(e)}scanIdentical(){return 0}static split(t,e){let i=[],s=-1;for(let r of t)i.push(r),s+=r.length+1,i.length==32&&(e.push(new D(i,s)),i=[],s=-1);return s>-1&&e.push(new D(i,s)),e}},G=class extends x{constructor(t,e){super();this.children=t,this.length=e,this.lines=0;for(let i of t)this.lines+=i.lines}lineInner(t,e,i,s){for(let r=0;;r++){let o=this.children[r],l=s+o.length,h=i+o.lines-1;if((e?h:l)>=t)return o.lineInner(t,e,i,s);s=l+1,i=h+1}}decompose(t,e,i,s){for(let r=0,o=0;o<=e&&r=o){let a=s&((o<=t?1:0)|(h>=e?2:0));o>=t&&h<=e&&!a?i.push(l):l.decompose(t-o,e-o,i,a)}o=h+1}}replace(t,e,i){if(i.lines=r&&e<=l){let h=o.replace(t-r,e-r,i),a=this.lines-o.lines+h.lines;if(h.lines>5-1&&h.lines>a>>5+1){let c=this.children.slice();return c[s]=h,new G(c,this.length-(e-t)+i.length)}return super.replace(r,l,h)}r=l+1}return super.replace(t,e,i)}sliceString(t,e=this.length,i=` +`){let s="";for(let r=0,o=0;rt&&r&&(s+=i),to&&(s+=l.sliceString(t-o,e-o,i)),o=h+1}return s}flatten(t){for(let e of this.children)e.flatten(t)}scanIdentical(t,e){if(!(t instanceof G))return 0;let i=0,[s,r,o,l]=e>0?[0,0,this.children.length,t.children.length]:[this.children.length-1,t.children.length-1,-1,-1];for(;;s+=e,r+=e){if(s==o||r==l)return i;let h=this.children[s],a=t.children[r];if(h!=a)return i+h.scanIdentical(a,e);i+=h.length+1}}static from(t,e=t.reduce((i,s)=>i+s.length+1,-1)){let i=0;for(let u of t)i+=u.lines;if(i<32){let u=[];for(let p of t)p.flatten(u);return new D(u,e)}let s=Math.max(32,i>>5),r=s<<1,o=s>>1,l=[],h=0,a=-1,c=[];function f(u){let p;if(u.lines>r&&u instanceof G)for(let g of u.children)f(g);else u.lines>o&&(h>o||!h)?(d(),l.push(u)):u instanceof D&&h&&(p=c[c.length-1])instanceof D&&u.lines+p.lines<=32?(h+=u.lines,a+=u.length+1,c[c.length-1]=new D(p.text.concat(u.text),p.length+1+u.length)):(h+u.lines>s&&d(),h+=u.lines,a+=u.length+1,c.push(u))}function d(){h!=0&&(l.push(c.length==1?c[0]:G.from(c,a)),a=-1,h=c.length=0)}for(let u of t)f(u);return d(),l.length==1?l[0]:new G(l,e)}};x.empty=new D([""],0);function Xn(n){let t=-1;for(let e of n)t+=e.length+1;return t}function Qt(n,t,e=0,i=1e9){for(let s=0,r=0,o=!0;r=e&&(h>i&&(l=l.slice(0,i-s)),s0?1:(t instanceof D?t.text.length:t.children.length)<<1]}nextInner(t,e){for(this.done=this.lineBreak=!1;;){let i=this.nodes.length-1,s=this.nodes[i],r=this.offsets[i],o=r>>1,l=s instanceof D?s.text.length:s.children.length;if(o==(e>0?l:0)){if(i==0)return this.done=!0,this.value="",this;e>0&&this.offsets[i-1]++,this.nodes.pop(),this.offsets.pop()}else if((r&1)==(e>0?0:1)){if(this.offsets[i]+=e,t==0)return this.lineBreak=!0,this.value=` +`,this;t--}else if(s instanceof D){let h=s.text[o+(e<0?-1:0)];if(this.offsets[i]+=e,h.length>Math.max(0,t))return this.value=t==0?h:e>0?h.slice(t):h.slice(0,h.length-t),this;t-=h.length}else{let h=s.children[o+(e<0?-1:0)];t>h.length?(t-=h.length,this.offsets[i]+=e):(e<0&&this.offsets[i]--,this.nodes.push(h),this.offsets.push(e>0?1:(h instanceof D?h.text.length:h.children.length)<<1))}}}next(t=0){return t<0&&(this.nextInner(-t,-this.dir),t=this.value.length),this.nextInner(t,this.dir)}},Ae=class{constructor(t,e,i){this.value="",this.done=!1,this.cursor=new yt(t,e>i?-1:1),this.pos=e>i?t.length:0,this.from=Math.min(e,i),this.to=Math.max(e,i)}nextInner(t,e){if(e<0?this.pos<=this.from:this.pos>=this.to)return this.value="",this.done=!0,this;t+=Math.max(0,e<0?this.pos-this.to:this.from-this.pos);let i=e<0?this.pos-this.from:this.to-this.pos;t>i&&(t=i),i-=t;let{value:s}=this.cursor.next(t);return this.pos+=(s.length+t)*e,this.value=s.length<=i?s:e<0?s.slice(s.length-i):s.slice(0,i),this.done=!this.value,this}next(t=0){return t<0?t=Math.max(t,this.from-this.pos):t>0&&(t=Math.min(t,this.to-this.pos)),this.nextInner(t,this.cursor.dir)}get lineBreak(){return this.cursor.lineBreak&&this.value!=""}},Me=class{constructor(t){this.inner=t,this.afterBreak=!0,this.value="",this.done=!1}next(t=0){let{done:e,lineBreak:i,value:s}=this.inner.next(t);return e?(this.done=!0,this.value=""):i?this.afterBreak?this.value="":(this.afterBreak=!0,this.next()):(this.value=s,this.afterBreak=!1),this}get lineBreak(){return!1}};typeof Symbol!="undefined"&&(x.prototype[Symbol.iterator]=function(){return this.iter()},yt.prototype[Symbol.iterator]=Ae.prototype[Symbol.iterator]=Me.prototype[Symbol.iterator]=function(){return this});var Bi=class{constructor(t,e,i,s){this.from=t,this.to=e,this.number=i,this.text=s}get length(){return this.to-this.from}},wt="lc,34,7n,7,7b,19,,,,2,,2,,,20,b,1c,l,g,,2t,7,2,6,2,2,,4,z,,u,r,2j,b,1m,9,9,,o,4,,9,,3,,5,17,3,3b,f,,w,1j,,,,4,8,4,,3,7,a,2,t,,1m,,,,2,4,8,,9,,a,2,q,,2,2,1l,,4,2,4,2,2,3,3,,u,2,3,,b,2,1l,,4,5,,2,4,,k,2,m,6,,,1m,,,2,,4,8,,7,3,a,2,u,,1n,,,,c,,9,,14,,3,,1l,3,5,3,,4,7,2,b,2,t,,1m,,2,,2,,3,,5,2,7,2,b,2,s,2,1l,2,,,2,4,8,,9,,a,2,t,,20,,4,,2,3,,,8,,29,,2,7,c,8,2q,,2,9,b,6,22,2,r,,,,,,1j,e,,5,,2,5,b,,10,9,,2u,4,,6,,2,2,2,p,2,4,3,g,4,d,,2,2,6,,f,,jj,3,qa,3,t,3,t,2,u,2,1s,2,,7,8,,2,b,9,,19,3,3b,2,y,,3a,3,4,2,9,,6,3,63,2,2,,1m,,,7,,,,,2,8,6,a,2,,1c,h,1r,4,1c,7,,,5,,14,9,c,2,w,4,2,2,,3,1k,,,2,3,,,3,1m,8,2,2,48,3,,d,,7,4,,6,,3,2,5i,1m,,5,ek,,5f,x,2da,3,3x,,2o,w,fe,6,2x,2,n9w,4,,a,w,2,28,2,7k,,3,,4,,p,2,5,,47,2,q,i,d,,12,8,p,b,1a,3,1c,,2,4,2,2,13,,1v,6,2,2,2,2,c,,8,,1b,,1f,,,3,2,2,5,2,,,16,2,8,,6m,,2,,4,,fn4,,kh,g,g,g,a6,2,gt,,6a,,45,5,1ae,3,,2,5,4,14,3,4,,4l,2,fx,4,ar,2,49,b,4w,,1i,f,1k,3,1d,4,2,2,1x,3,10,5,,8,1q,,c,2,1g,9,a,4,2,,2n,3,2,,,2,6,,4g,,3,8,l,2,1l,2,,,,,m,,e,7,3,5,5f,8,2,3,,,n,,29,,2,6,,,2,,,2,,2,6j,,2,4,6,2,,2,r,2,2d,8,2,,,2,2y,,,,2,6,,,2t,3,2,4,,5,77,9,,2,6t,,a,2,,,4,,40,4,2,2,4,,w,a,14,6,2,4,8,,9,6,2,3,1a,d,,2,ba,7,,6,,,2a,m,2,7,,2,,2,3e,6,3,,,2,,7,,,20,2,3,,,,9n,2,f0b,5,1n,7,t4,,1r,4,29,,f5k,2,43q,,,3,4,5,8,8,2,7,u,4,44,3,1iz,1j,4,1e,8,,e,,m,5,,f,11s,7,,h,2,7,,2,,5,79,7,c5,4,15s,7,31,7,240,5,gx7k,2o,3k,6o".split(",").map(n=>n?parseInt(n,36):1);for(let n=1;nn)return wt[t-1]<=n;return!1}function Pi(n){return n>=127462&&n<=127487}var Vi=8205;function Q(n,t,e=!0,i=!0){return(e?Ni:Zn)(n,t,i)}function Ni(n,t,e){if(t==n.length)return t;t&&Ii(n.charCodeAt(t))&&Hi(n.charCodeAt(t-1))&&t--;let i=_t(n,t);for(t+=De(i);t=0&&Pi(_t(n,o));)r++,o-=2;if(r%2==0)break;t+=2}else break}return t}function Zn(n,t,e){for(;t>0;){let i=Ni(n,t-2,e);if(i=56320&&n<57344}function Hi(n){return n>=55296&&n<56320}function _t(n,t){let e=n.charCodeAt(t);if(!Hi(e)||t+1==n.length)return e;let i=n.charCodeAt(t+1);return Ii(i)?(e-55296<<10)+(i-56320)+65536:e}function De(n){return n<65536?1:2}var Oe=/\r\n?|\n/,K=function(n){return n[n.Simple=0]="Simple",n[n.TrackDel=1]="TrackDel",n[n.TrackBefore=2]="TrackBefore",n[n.TrackAfter=3]="TrackAfter",n}(K||(K={})),J=class{constructor(t){this.sections=t}get length(){let t=0;for(let e=0;et)return r+(t-s);r+=l}else{if(i!=K.Simple&&a>=t&&(i==K.TrackDel&&st||i==K.TrackBefore&&st))return null;if(a>t||a==t&&e<0&&!l)return t==s||e<0?r:r+h;r+=h}s=a}if(t>s)throw new RangeError(`Position ${t} is out of range for changeset of length ${s}`);return r}touchesRange(t,e=t){for(let i=0,s=0;i=0&&s<=e&&l>=t)return se?"cover":!0;s=l}return!1}toString(){let t="";for(let e=0;e=0?":"+s:"")}return t}toJSON(){return this.sections}static fromJSON(t){if(!Array.isArray(t)||t.length%2||t.some(e=>typeof e!="number"))throw new RangeError("Invalid JSON representation of ChangeDesc");return new J(t)}static create(t){return new J(t)}},T=class extends J{constructor(t,e){super(t);this.inserted=e}apply(t){if(this.length!=t.length)throw new RangeError("Applying change set to a document with the wrong length");return Te(this,(e,i,s,r,o)=>t=t.replace(s,s+(i-e),o),!1),t}mapDesc(t,e=!1){return Re(this,t,e,!0)}invert(t){let e=this.sections.slice(),i=[];for(let s=0,r=0;s=0){e[s]=l,e[s+1]=o;let h=s>>1;for(;i.length0&&st(i,e,r.text),r.forward(c),l+=c}let a=t[o++];for(;l>1].toJSON()))}return t}static of(t,e,i){let s=[],r=[],o=0,l=null;function h(c=!1){if(!c&&!s.length)return;od||f<0||d>e)throw new RangeError(`Invalid change range ${f} to ${d} (in doc of length ${e})`);let p=u?typeof u=="string"?x.of(u.split(i||Oe)):u:x.empty,g=p.length;if(f==d&&g==0)return;fo&&F(s,f-o,-1),F(s,d-f,g),st(r,s,p),o=d}}return a(t),h(!l),l}static empty(t){return new T(t?[t,-1]:[],[])}static fromJSON(t){if(!Array.isArray(t))throw new RangeError("Invalid JSON representation of ChangeSet");let e=[],i=[];for(let s=0;sl&&typeof o!="string"))throw new RangeError("Invalid JSON representation of ChangeSet");if(r.length==1)e.push(r[0],0);else{for(;i.length=0&&e<=0&&e==n[s+1]?n[s]+=t:t==0&&n[s]==0?n[s+1]+=e:i?(n[s]+=t,n[s+1]+=e):n.push(t,e)}function st(n,t,e){if(e.length==0)return;let i=t.length-2>>1;if(i>1])),!(e||o==n.sections.length||n.sections[o+1]<0);)l=n.sections[o++],h=n.sections[o++];t(s,a,r,c,f),s=a,r=c}}}function Re(n,t,e,i=!1){let s=[],r=i?[]:null,o=new bt(n),l=new bt(t);for(let h=-1;;)if(o.ins==-1&&l.ins==-1){let a=Math.min(o.len,l.len);F(s,a,-1),o.forward(a),l.forward(a)}else if(l.ins>=0&&(o.ins<0||h==o.i||o.off==0&&(l.len=0&&h=0){let a=0,c=o.len;for(;c;)if(l.ins==-1){let f=Math.min(c,l.len);a+=f,c-=f,l.forward(f)}else if(l.ins==0&&l.lenh||o.ins>=0&&o.len>h)&&(l||i.length>a),r.forward2(h),o.forward(h)}}}}var bt=class{constructor(t){this.set=t,this.i=0,this.next()}next(){let{sections:t}=this.set;this.i>1;return e>=t.length?x.empty:t[e]}textBit(t){let{inserted:e}=this.set,i=this.i-2>>1;return i>=e.length&&!t?x.empty:e[i].slice(this.off,t==null?void 0:this.off+t)}forward(t){t==this.len?this.next():(this.len-=t,this.off+=t)}forward2(t){this.ins==-1?this.forward(t):t==this.ins?this.next():(this.ins-=t,this.off+=t)}},nt=class{constructor(t,e,i){this.from=t,this.to=e,this.flags=i}get anchor(){return this.flags&16?this.to:this.from}get head(){return this.flags&16?this.from:this.to}get empty(){return this.from==this.to}get assoc(){return this.flags&4?-1:this.flags&8?1:0}get bidiLevel(){let t=this.flags&3;return t==3?null:t}get goalColumn(){let t=this.flags>>5;return t==33554431?void 0:t}map(t,e=-1){let i,s;return this.empty?i=s=t.mapPos(this.from,e):(i=t.mapPos(this.from,1),s=t.mapPos(this.to,-1)),i==this.from&&s==this.to?this:new nt(i,s,this.flags)}extend(t,e=t){if(t<=this.anchor&&e>=this.anchor)return w.range(t,e);let i=Math.abs(t-this.anchor)>Math.abs(e-this.anchor)?t:e;return w.range(this.anchor,i)}eq(t){return this.anchor==t.anchor&&this.head==t.head}toJSON(){return{anchor:this.anchor,head:this.head}}static fromJSON(t){if(!t||typeof t.anchor!="number"||typeof t.head!="number")throw new RangeError("Invalid JSON representation for SelectionRange");return w.range(t.anchor,t.head)}static create(t,e,i){return new nt(t,e,i)}},w=class{constructor(t,e){this.ranges=t,this.mainIndex=e}map(t,e=-1){return t.empty?this:w.create(this.ranges.map(i=>i.map(t,e)),this.mainIndex)}eq(t){if(this.ranges.length!=t.ranges.length||this.mainIndex!=t.mainIndex)return!1;for(let e=0;et.toJSON()),main:this.mainIndex}}static fromJSON(t){if(!t||!Array.isArray(t.ranges)||typeof t.main!="number"||t.main>=t.ranges.length)throw new RangeError("Invalid JSON representation for EditorSelection");return new w(t.ranges.map(e=>nt.fromJSON(e)),t.main)}static single(t,e=t){return new w([w.range(t,e)],0)}static create(t,e=0){if(t.length==0)throw new RangeError("A selection needs at least one range");for(let i=0,s=0;st?4:0))}static normalized(t,e=0){let i=t[e];t.sort((s,r)=>s.from-r.from),e=t.indexOf(i);for(let s=1;sr.head?w.range(h,l):w.range(l,h))}}return new w(t,e)}};function Wi(n,t){for(let e of n.ranges)if(e.to>t)throw new RangeError("Selection points outside of document")}var Ee=0,v=class{constructor(t,e,i,s,r){this.combine=t,this.compareInput=e,this.compare=i,this.isStatic=s,this.id=Ee++,this.default=t([]),this.extensions=typeof r=="function"?r(this):r}static define(t={}){return new v(t.combine||(e=>e),t.compareInput||((e,i)=>e===i),t.compare||(t.combine?(e,i)=>e===i:Le),!!t.static,t.enables)}of(t){return new Bt([],this,0,t)}compute(t,e){if(this.isStatic)throw new Error("Can't compute a static facet");return new Bt(t,this,1,e)}computeN(t,e){if(this.isStatic)throw new Error("Can't compute a static facet");return new Bt(t,this,2,e)}from(t,e){return e||(e=i=>i),this.compute([t],i=>e(i.field(t)))}};function Le(n,t){return n==t||n.length==t.length&&n.every((e,i)=>e===t[i])}var Bt=class{constructor(t,e,i,s){this.dependencies=t,this.facet=e,this.type=i,this.value=s,this.id=Ee++}dynamicSlot(t){var e;let i=this.value,s=this.facet.compareInput,r=this.id,o=t[r]>>1,l=this.type==2,h=!1,a=!1,c=[];for(let f of this.dependencies)f=="doc"?h=!0:f=="selection"?a=!0:(((e=t[f.id])!==null&&e!==void 0?e:1)&1)==0&&c.push(t[f.id]);return{create(f){return f.values[o]=i(f),1},update(f,d){if(h&&d.docChanged||a&&(d.docChanged||d.selection)||Be(f,c)){let u=i(f);if(l?!zi(u,f.values[o],s):!s(u,f.values[o]))return f.values[o]=u,1}return 0},reconfigure:(f,d)=>{let u=i(f),p=d.config.address[r];if(p!=null){let g=ee(d,p);if(this.dependencies.every(m=>m instanceof v?d.facet(m)===f.facet(m):m instanceof rt?d.field(m,!1)==f.field(m,!1):!0)||(l?zi(u,g,s):s(u,g)))return f.values[o]=g,0}return f.values[o]=u,1}}}};function zi(n,t,e){if(n.length!=t.length)return!1;for(let i=0;in[h.id]),s=e.map(h=>h.type),r=i.filter(h=>!(h&1)),o=n[t.id]>>1;function l(h){let a=[];for(let c=0;ci===s),t);return t.provide&&(e.provides=t.provide(e)),e}create(t){let e=t.facet(qi).find(i=>i.field==this);return((e==null?void 0:e.create)||this.createF)(t)}slot(t){let e=t[this.id]>>1;return{create:i=>(i.values[e]=this.create(i),1),update:(i,s)=>{let r=i.values[e],o=this.updateF(r,s);return this.compareF(r,o)?0:(i.values[e]=o,1)},reconfigure:(i,s)=>s.config.address[this.id]!=null?(i.values[e]=s.field(this),0):(i.values[e]=this.create(i),1)}}init(t){return[this,qi.of({field:this,create:t})]}get extension(){return this}},vt={lowest:4,low:3,default:2,high:1,highest:0};function Pt(n){return t=>new Pe(t,n)}var Ki={highest:Pt(vt.highest),high:Pt(vt.high),default:Pt(vt.default),low:Pt(vt.low),lowest:Pt(vt.lowest)},Pe=class{constructor(t,e){this.inner=t,this.prec=e}},Vt=class{of(t){return new te(this,t)}reconfigure(t){return Vt.reconfigure.of({compartment:this,extension:t})}get(t){return t.config.compartments.get(this)}},te=class{constructor(t,e){this.compartment=t,this.inner=e}},Nt=class{constructor(t,e,i,s,r,o){for(this.base=t,this.compartments=e,this.dynamicSlots=i,this.address=s,this.staticValues=r,this.facets=o,this.statusTemplate=[];this.statusTemplate.length>1]}static resolve(t,e,i){let s=[],r=Object.create(null),o=new Map;for(let d of _n(t,e,o))d instanceof rt?s.push(d):(r[d.facet.id]||(r[d.facet.id]=[])).push(d);let l=Object.create(null),h=[],a=[];for(let d of s)l[d.id]=a.length<<1,a.push(u=>d.slot(u));let c=i==null?void 0:i.config.facets;for(let d in r){let u=r[d],p=u[0].facet,g=c&&c[d]||[];if(u.every(m=>m.type==0))if(l[p.id]=h.length<<1|1,Le(g,u))h.push(i.facet(p));else{let m=p.combine(u.map(b=>b.value));h.push(i&&p.compare(m,i.facet(p))?i.facet(p):m)}else{for(let m of u)m.type==0?(l[m.id]=h.length<<1|1,h.push(m.value)):(l[m.id]=a.length<<1,a.push(b=>m.dynamicSlot(b)));l[p.id]=a.length<<1,a.push(m=>Qn(m,p,u))}}let f=a.map(d=>d(l));return new Nt(t,o,f,l,h,r)}};function _n(n,t,e){let i=[[],[],[],[],[]],s=new Map;function r(o,l){let h=s.get(o);if(h!=null){if(h<=l)return;let a=i[h].indexOf(o);a>-1&&i[h].splice(a,1),o instanceof te&&e.delete(o.compartment)}if(s.set(o,l),Array.isArray(o))for(let a of o)r(a,l);else if(o instanceof te){if(e.has(o.compartment))throw new RangeError("Duplicate use of compartment in extensions");let a=t.get(o.compartment)||o.inner;e.set(o.compartment,a),r(a,l)}else if(o instanceof Pe)r(o.inner,o.prec);else if(o instanceof rt)i[l].push(o),o.provides&&r(o.provides,l);else if(o instanceof Bt)i[l].push(o),o.facet.extensions&&r(o.facet.extensions,l);else{let a=o.extension;if(!a)throw new Error(`Unrecognized extension value in extension set (${o}). This sometimes happens because multiple instances of @codemirror/state are loaded, breaking instanceof checks.`);r(a,l)}}return r(n,vt.default),i.reduce((o,l)=>o.concat(l))}function It(n,t){if(t&1)return 2;let e=t>>1,i=n.status[e];if(i==4)throw new Error("Cyclic dependency between fields and/or facets");if(i&2)return i;n.status[e]=4;let s=n.computeSlot(n,n.config.dynamicSlots[e]);return n.status[e]=2|s}function ee(n,t){return t&1?n.config.staticValues[t>>1]:n.values[t>>1]}var $i=v.define(),ji=v.define({combine:n=>n.some(t=>t),static:!0}),Gi=v.define({combine:n=>n.length?n[0]:void 0,static:!0}),Ui=v.define(),Ji=v.define(),Xi=v.define(),Yi=v.define({combine:n=>n.length?n[0]:!1}),xt=class{constructor(t,e){this.type=t,this.value=e}static define(){return new Zi}},Zi=class{of(t){return new xt(this,t)}},Qi=class{constructor(t){this.map=t}of(t){return new E(this,t)}},E=class{constructor(t,e){this.type=t,this.value=e}map(t){let e=this.type.map(this.value,t);return e===void 0?void 0:e==this.value?this:new E(this.type,e)}is(t){return this.type==t}static define(t={}){return new Qi(t.map||(e=>e))}static mapEffects(t,e){if(!t.length)return t;let i=[];for(let s of t){let r=s.map(e);r&&i.push(r)}return i}};E.reconfigure=E.define();E.appendConfig=E.define();var P=class{constructor(t,e,i,s,r,o){this.startState=t,this.changes=e,this.selection=i,this.effects=s,this.annotations=r,this.scrollIntoView=o,this._doc=null,this._state=null,i&&Wi(i,e.newLength),r.some(l=>l.type==P.time)||(this.annotations=r.concat(P.time.of(Date.now())))}static create(t,e,i,s,r,o){return new P(t,e,i,s,r,o)}get newDoc(){return this._doc||(this._doc=this.changes.apply(this.startState.doc))}get newSelection(){return this.selection||this.startState.selection.map(this.changes)}get state(){return this._state||this.startState.applyTransaction(this),this._state}annotation(t){for(let e of this.annotations)if(e.type==t)return e.value}get docChanged(){return!this.changes.empty}get reconfigured(){return this.startState.config!=this.state.config}isUserEvent(t){let e=this.annotation(P.userEvent);return!!(e&&(e==t||e.length>t.length&&e.slice(0,t.length)==t&&e[t.length]=="."))}};P.time=xt.define();P.userEvent=xt.define();P.addToHistory=xt.define();P.remote=xt.define();function tr(n,t){let e=[];for(let i=0,s=0;;){let r,o;if(i=n[i]))r=n[i++],o=n[i++];else if(s=0;s--){let r=i[s](n);r instanceof P?n=r:Array.isArray(r)&&r.length==1&&r[0]instanceof P?n=r[0]:n=ts(t,St(r),!1)}return n}function ir(n){let t=n.startState,e=t.facet(Xi),i=n;for(let s=e.length-1;s>=0;s--){let r=e[s](n);r&&Object.keys(r).length&&(i=_i(n,Ve(t,r,n.changes.newLength),!0))}return i==n?n:P.create(t,n.changes,n.selection,i.effects,i.annotations,i.scrollIntoView)}var sr=[];function St(n){return n==null?sr:Array.isArray(n)?n:[n]}var X=function(n){return n[n.Word=0]="Word",n[n.Space=1]="Space",n[n.Other=2]="Other",n}(X||(X={})),nr=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/,Ne;try{Ne=new RegExp("[\\p{Alphabetic}\\p{Number}_]","u")}catch(n){}function rr(n){if(Ne)return Ne.test(n);for(let t=0;t"\x80"&&(e.toUpperCase()!=e.toLowerCase()||nr.test(e)))return!0}return!1}function or(n){return t=>{if(!/\S/.test(t))return X.Space;if(rr(t))return X.Word;for(let e=0;e-1)return X.Word;return X.Other}}var S=class{constructor(t,e,i,s,r,o){this.config=t,this.doc=e,this.selection=i,this.values=s,this.status=t.statusTemplate.slice(),this.computeSlot=r,o&&(o._state=this);for(let l=0;ls.set(h,l)),e=null),s.set(o.value.compartment,o.value.extension)):o.is(E.reconfigure)?(e=null,i=o.value):o.is(E.appendConfig)&&(e=null,i=St(i).concat(o.value));let r;e?r=t.startState.values.slice():(e=Nt.resolve(i,s,this),r=new S(e,this.doc,this.selection,e.dynamicSlots.map(()=>null),(l,h)=>h.reconfigure(l,this),null).values),new S(e,t.newDoc,t.newSelection,r,(o,l)=>l.update(o,t),t)}replaceSelection(t){return typeof t=="string"&&(t=this.toText(t)),this.changeByRange(e=>({changes:{from:e.from,to:e.to,insert:t},range:w.cursor(e.from+t.length)}))}changeByRange(t){let e=this.selection,i=t(e.ranges[0]),s=this.changes(i.changes),r=[i.range],o=St(i.effects);for(let l=1;lo.spec.fromJSON(l,h)))}}return S.create({doc:t.doc,selection:w.fromJSON(t.selection),extensions:e.extensions?s.concat([e.extensions]):s})}static create(t={}){let e=Nt.resolve(t.extensions||[],new Map),i=t.doc instanceof x?t.doc:x.of((t.doc||"").split(e.staticFacet(S.lineSeparator)||Oe)),s=t.selection?t.selection instanceof w?t.selection:w.single(t.selection.anchor,t.selection.head):w.single(0);return Wi(s,i.length),e.staticFacet(ji)||(s=s.asSingle()),new S(e,i,s,e.dynamicSlots.map(()=>null),(r,o)=>o.create(r),null)}get tabSize(){return this.facet(S.tabSize)}get lineBreak(){return this.facet(S.lineSeparator)||` +`}get readOnly(){return this.facet(Yi)}phrase(t,...e){for(let i of this.facet(S.phrases))if(Object.prototype.hasOwnProperty.call(i,t)){t=i[t];break}return e.length&&(t=t.replace(/\$(\$|\d*)/g,(i,s)=>{if(s=="$")return"$";let r=+(s||1);return!r||r>e.length?i:e[r-1]})),t}languageDataAt(t,e,i=-1){let s=[];for(let r of this.facet($i))for(let o of r(this,e,i))Object.prototype.hasOwnProperty.call(o,t)&&s.push(o[t]);return s}charCategorizer(t){return or(this.languageDataAt("wordChars",t).join(""))}wordAt(t){let{text:e,from:i,length:s}=this.doc.lineAt(t),r=this.charCategorizer(t),o=t-i,l=t-i;for(;o>0;){let h=Q(e,o,!1);if(r(e.slice(h,o))!=X.Word)break;o=h}for(;ln.length?n[0]:4});S.lineSeparator=Gi;S.readOnly=Yi;S.phrases=v.define({compare(n,t){let e=Object.keys(n),i=Object.keys(t);return e.length==i.length&&e.every(s=>n[s]==t[s])}});S.languageData=$i;S.changeFilter=Ui;S.transactionFilter=Ji;S.transactionExtender=Xi;Vt.reconfigure=E.define();var ot=class{eq(t){return this==t}range(t,e=t){return kt.create(t,e,this)}};ot.prototype.startSide=ot.prototype.endSide=0;ot.prototype.point=!1;ot.prototype.mapMode=K.TrackDel;var kt=class{constructor(t,e,i){this.from=t,this.to=e,this.value=i}static create(t,e,i){return new kt(t,e,i)}};function Ie(n,t){return n.from-t.from||n.value.startSide-t.value.startSide}var ie=class{constructor(t,e,i,s){this.from=t,this.to=e,this.value=i,this.maxPoint=s}get length(){return this.to[this.to.length-1]}findIndex(t,e,i,s=0){let r=i?this.to:this.from;for(let o=s,l=r.length;;){if(o==l)return o;let h=o+l>>1,a=r[h]-t||(i?this.value[h].endSide:this.value[h].startSide)-e;if(h==o)return a>=0?o:l;a>=0?l=h:o=h+1}}between(t,e,i,s){for(let r=this.findIndex(e,-1e9,!0),o=this.findIndex(i,1e9,!1,r);ru||d==u&&a.startSide>0&&a.endSide<=0)continue;(u-d||a.endSide-a.startSide)<0||(o<0&&(o=d),a.point&&(l=Math.max(l,u-d)),i.push(a),s.push(d-o),r.push(u-o))}return{mapped:i.length?new ie(s,r,i,l):null,pos:o}}},O=class{constructor(t,e,i,s){this.chunkPos=t,this.chunk=e,this.nextLayer=i,this.maxPoint=s}static create(t,e,i,s){return new O(t,e,i,s)}get length(){let t=this.chunk.length-1;return t<0?0:Math.max(this.chunkEnd(t),this.nextLayer.length)}get size(){if(this.isEmpty)return 0;let t=this.nextLayer.size;for(let e of this.chunk)t+=e.value.length;return t}chunkEnd(t){return this.chunkPos[t]+this.chunk[t].length}update(t){let{add:e=[],sort:i=!1,filterFrom:s=0,filterTo:r=this.length}=t,o=t.filter;if(e.length==0&&!o)return this;if(i&&(e=e.slice().sort(Ie)),this.isEmpty)return e.length?O.of(e):this;let l=new He(this,null,-1).goto(0),h=0,a=[],c=new Ct;for(;l.value||h=0){let f=e[h++];c.addInner(f.from,f.to,f.value)||a.push(f)}else l.rangeIndex==1&&l.chunkIndexthis.chunkEnd(l.chunkIndex)||rl.to||r=r&&t<=r+o.length&&o.between(r,t-r,e-r,i)===!1)return}this.nextLayer.between(t,e,i)}}iter(t=0){return At.from([this]).goto(t)}get isEmpty(){return this.nextLayer==this}static iter(t,e=0){return At.from(t).goto(e)}static compare(t,e,i,s,r=-1){let o=t.filter(f=>f.maxPoint>0||!f.isEmpty&&f.maxPoint>=r),l=e.filter(f=>f.maxPoint>0||!f.isEmpty&&f.maxPoint>=r),h=es(o,l,i),a=new Mt(o,h,r),c=new Mt(l,h,r);i.iterGaps((f,d,u)=>is(a,f,c,d,u,s)),i.empty&&i.length==0&&is(a,0,c,0,0,s)}static eq(t,e,i=0,s){s==null&&(s=1e9);let r=t.filter(c=>!c.isEmpty&&e.indexOf(c)<0),o=e.filter(c=>!c.isEmpty&&t.indexOf(c)<0);if(r.length!=o.length)return!1;if(!r.length)return!0;let l=es(r,o),h=new Mt(r,l,0).goto(i),a=new Mt(o,l,0).goto(i);for(;;){if(h.to!=a.to||!We(h.active,a.active)||h.point&&(!a.point||!h.point.eq(a.point)))return!1;if(h.to>s)return!0;h.next(),a.next()}}static spans(t,e,i,s,r=-1){let o=new Mt(t,null,r).goto(e),l=e,h=o.openStart;for(;;){let a=Math.min(o.to,i);if(o.point?(s.point(l,a,o.point,o.activeForPoint(o.to),h,o.pointRank),h=o.openEnd(a)+(o.to>a?1:0)):a>l&&(s.span(l,a,o.active,h),h=o.openEnd(a)),o.to>i)break;l=o.to,o.next()}return h}static of(t,e=!1){let i=new Ct;for(let s of t instanceof kt?[t]:e?lr(t):t)i.add(s.from,s.to,s.value);return i.finish()}};O.empty=new O([],[],null,-1);function lr(n){if(n.length>1)for(let t=n[0],e=1;e0)return n.slice().sort(Ie);t=i}return n}O.empty.nextLayer=O.empty;var Ct=class{constructor(){this.chunks=[],this.chunkPos=[],this.chunkStart=-1,this.last=null,this.lastFrom=-1e9,this.lastTo=-1e9,this.from=[],this.to=[],this.value=[],this.maxPoint=-1,this.setMaxPoint=-1,this.nextLayer=null}finishChunk(t){this.chunks.push(new ie(this.from,this.to,this.value,this.maxPoint)),this.chunkPos.push(this.chunkStart),this.chunkStart=-1,this.setMaxPoint=Math.max(this.setMaxPoint,this.maxPoint),this.maxPoint=-1,t&&(this.from=[],this.to=[],this.value=[])}add(t,e,i){this.addInner(t,e,i)||(this.nextLayer||(this.nextLayer=new Ct)).add(t,e,i)}addInner(t,e,i){let s=t-this.lastTo||i.startSide-this.last.endSide;if(s<=0&&(t-this.lastFrom||i.startSide-this.last.startSide)<0)throw new Error("Ranges must be added sorted by `from` position and `startSide`");return s<0?!1:(this.from.length==250&&this.finishChunk(!0),this.chunkStart<0&&(this.chunkStart=t),this.from.push(t-this.chunkStart),this.to.push(e-this.chunkStart),this.last=i,this.lastFrom=t,this.lastTo=e,this.value.push(i),i.point&&(this.maxPoint=Math.max(this.maxPoint,e-t)),!0)}addChunk(t,e){if((t-this.lastTo||e.value[0].startSide-this.last.endSide)<0)return!1;this.from.length&&this.finishChunk(!0),this.setMaxPoint=Math.max(this.setMaxPoint,e.maxPoint),this.chunks.push(e),this.chunkPos.push(t);let i=e.value.length-1;return this.last=e.value[i],this.lastFrom=e.from[i]+t,this.lastTo=e.to[i]+t,!0}finish(){return this.finishInner(O.empty)}finishInner(t){if(this.from.length&&this.finishChunk(!1),this.chunks.length==0)return t;let e=O.create(this.chunkPos,this.chunks,this.nextLayer?this.nextLayer.finishInner(t):t,this.setMaxPoint);return this.from=null,e}};function es(n,t,e){let i=new Map;for(let r of n)for(let o=0;o=this.minPoint)break}}setRangeIndex(t){if(t==this.layer.chunk[this.chunkIndex].value.length){if(this.chunkIndex++,this.skip)for(;this.chunkIndex=i&&s.push(new He(o,e,i,r));return s.length==1?s[0]:new At(s)}get startSide(){return this.value?this.value.startSide:0}goto(t,e=-1e9){for(let i of this.heap)i.goto(t,e);for(let i=this.heap.length>>1;i>=0;i--)Fe(this.heap,i);return this.next(),this}forward(t,e){for(let i of this.heap)i.forward(t,e);for(let i=this.heap.length>>1;i>=0;i--)Fe(this.heap,i);(this.to-t||this.value.endSide-e)<0&&this.next()}next(){if(this.heap.length==0)this.from=this.to=1e9,this.value=null,this.rank=-1;else{let t=this.heap[0];this.from=t.from,this.to=t.to,this.value=t.value,this.rank=t.rank,t.value&&t.next(),Fe(this.heap,0)}}};function Fe(n,t){for(let e=n[t];;){let i=(t<<1)+1;if(i>=n.length)break;let s=n[i];if(i+1=0&&(s=n[i+1],i++),e.compare(s)<0)break;n[i]=e,n[t]=s,t=i}}var Mt=class{constructor(t,e,i){this.minPoint=i,this.active=[],this.activeTo=[],this.activeRank=[],this.minActive=-1,this.point=null,this.pointFrom=0,this.pointRank=0,this.to=-1e9,this.endSide=0,this.openStart=-1,this.cursor=At.from(t,e,i)}goto(t,e=-1e9){return this.cursor.goto(t,e),this.active.length=this.activeTo.length=this.activeRank.length=0,this.minActive=-1,this.to=t,this.endSide=e,this.openStart=-1,this.next(),this}forward(t,e){for(;this.minActive>-1&&(this.activeTo[this.minActive]-t||this.active[this.minActive].endSide-e)<0;)this.removeActive(this.minActive);this.cursor.forward(t,e)}removeActive(t){se(this.active,t),se(this.activeTo,t),se(this.activeRank,t),this.minActive=ss(this.active,this.activeTo)}addActive(t){let e=0,{value:i,to:s,rank:r}=this.cursor;for(;e-1&&(this.activeTo[r]-this.cursor.from||this.active[r].endSide-this.cursor.startSide)<0){if(this.activeTo[r]>t){this.to=this.activeTo[r],this.endSide=this.active[r].endSide;break}this.removeActive(r),i&&se(i,r)}else if(this.cursor.value)if(this.cursor.from>t){this.to=this.cursor.from,this.endSide=this.cursor.startSide;break}else{let o=this.cursor.value;if(!o.point)this.addActive(i),this.cursor.next();else if(e&&this.cursor.to==this.to&&this.cursor.from=0&&!(this.activeRank[i]t||this.activeTo[i]==t&&this.active[i].endSide>=this.point.endSide)&&e.push(this.active[i]);return e.reverse()}openEnd(t){let e=0;for(let i=this.activeTo.length-1;i>=0&&this.activeTo[i]>t;i--)e++;return e}};function is(n,t,e,i,s,r){n.goto(t),e.goto(i);let o=i+s,l=i,h=i-t;for(;;){let a=n.to+h-e.to||n.endSide-e.endSide,c=a<0?n.to+h:e.to,f=Math.min(c,o);if(n.point||e.point?n.point&&e.point&&(n.point==e.point||n.point.eq(e.point))&&We(n.activeForPoint(n.to+h),e.activeForPoint(e.to))||r.comparePoint(l,f,n.point,e.point):f>l&&!We(n.active,e.active)&&r.compareRange(l,f,n.active,e.active),c>o)break;l=c,a<=0&&n.next(),a>=0&&e.next()}}function We(n,t){if(n.length!=t.length)return!1;for(let e=0;e=t;i--)n[i+1]=n[i];n[t]=e}function ss(n,t){let e=-1,i=1e9;for(let s=0;s=t)return s;if(s==n.length)break;r+=n.charCodeAt(s)==9?e-r%e:1,s=Q(n,s)}return i===!0?-1:n.length}var ze="\u037C",rs=typeof Symbol=="undefined"?"__"+ze:Symbol.for(ze),qe=typeof Symbol=="undefined"?"__styleSet"+Math.floor(Math.random()*1e8):Symbol("styleSet"),os=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:{},lt=class{constructor(t,e){this.rules=[];let{finish:i}=e||{};function s(o){return/^@/.test(o)?[o]:o.split(/,\s*/)}function r(o,l,h,a){let c=[],f=/^@(\w+)\b/.exec(o[0]),d=f&&f[1]=="keyframes";if(f&&l==null)return h.push(o[0]+";");for(let u in l){let p=l[u];if(/&/.test(u))r(u.split(/,\s*/).map(g=>o.map(m=>g.replace(/&/,m))).reduce((g,m)=>g.concat(m)),p,h);else if(p&&typeof p=="object"){if(!f)throw new RangeError("The value of a property ("+u+") should be a primitive value.");r(s(u),p,c,d)}else p!=null&&c.push(u.replace(/_.*/,"").replace(/[A-Z]/g,g=>"-"+g.toLowerCase())+": "+p+";")}(c.length||d)&&h.push((i&&!f&&!a?o.map(i):o).join(", ")+" {"+c.join(" ")+"}")}for(let o in t)r(s(o),t[o],this.rules)}getRules(){return this.rules.join(` +`)}static newName(){let t=os[rs]||1;return os[rs]=t+1,ze+t.toString(36)}static mount(t,e){(t[qe]||new ls(t)).mount(Array.isArray(e)?e:[e])}},re=null,ls=class{constructor(t){if(!t.head&&t.adoptedStyleSheets&&typeof CSSStyleSheet!="undefined"){if(re)return t.adoptedStyleSheets=[re.sheet].concat(t.adoptedStyleSheets),t[qe]=re;this.sheet=new CSSStyleSheet,t.adoptedStyleSheets=[this.sheet].concat(t.adoptedStyleSheets),re=this}else{this.styleTag=(t.ownerDocument||t).createElement("style");let e=t.head||t;e.insertBefore(this.styleTag,e.firstChild)}this.modules=[],t[qe]=this}mount(t){let e=this.sheet,i=0,s=0;for(let r=0;r-1&&(this.modules.splice(l,1),s--,l=-1),l==-1){if(this.modules.splice(s++,0,o),e)for(let h=0;h",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"',229:"Q"},hs=typeof navigator!="undefined"&&/Chrome\/(\d+)/.exec(navigator.userAgent),go=typeof navigator!="undefined"&&/Apple Computer/.test(navigator.vendor),hr=typeof navigator!="undefined"&&/Gecko\/\d+/.test(navigator.userAgent),as=typeof navigator!="undefined"&&/Mac/.test(navigator.platform),mo=typeof navigator!="undefined"&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent),yo=hs&&(as||+hs[1]<57)||hr&&as;for(R=0;R<10;R++)ut[48+R]=ut[96+R]=String(R);var R;for(R=1;R<=24;R++)ut[R+111]="F"+R;var R;for(R=65;R<=90;R++)ut[R]=String.fromCharCode(R+32),oe[R]=String.fromCharCode(R);var R;for(le in ut)oe.hasOwnProperty(le)||(oe[le]=ut[le]);var le;function he(n){let t;return n.nodeType==11?t=n.getSelection?n:n.ownerDocument:t=n,t.getSelection()}function Dt(n,t){return t?n==t||n.contains(t.nodeType!=1?t.parentNode:t):!1}function ar(){let n=document.activeElement;for(;n&&n.shadowRoot;)n=n.shadowRoot.activeElement;return n}function Ke(n,t){if(!t.anchorNode)return!1;try{return Dt(n,t.anchorNode)}catch(e){return!1}}function Ht(n){return n.nodeType==3?Tt(n,0,n.nodeValue.length).getClientRects():n.nodeType==1?n.getClientRects():[]}function ae(n,t,e,i){return e?cs(n,t,e,i,-1)||cs(n,t,e,i,1):!1}function $e(n){for(var t=0;;t++)if(n=n.previousSibling,!n)return t}function cs(n,t,e,i,s){for(;;){if(n==e&&t==i)return!0;if(t==(s<0?0:ce(n))){if(n.nodeName=="DIV")return!1;let r=n.parentNode;if(!r||r.nodeType!=1)return!1;t=$e(n)+(s<0?0:1),n=r}else if(n.nodeType==1){if(n=n.childNodes[t+(s<0?-1:0)],n.nodeType==1&&n.contentEditable=="false")return!1;t=s<0?ce(n):0}else return!1}}function ce(n){return n.nodeType==3?n.nodeValue.length:n.childNodes.length}var fs={left:0,right:0,top:0,bottom:0};function fe(n,t){let e=t?n.left:n.right;return{left:e,right:e,top:n.top,bottom:n.bottom}}function cr(n){return{left:0,right:n.innerWidth,top:0,bottom:n.innerHeight}}function fr(n,t,e,i,s,r,o,l){let h=n.ownerDocument,a=h.defaultView;for(let c=n;c;)if(c.nodeType==1){let f,d=c==h.body;if(d)f=cr(a);else{if(c.scrollHeight<=c.clientHeight&&c.scrollWidth<=c.clientWidth){c=c.parentNode;continue}let g=c.getBoundingClientRect();f={left:g.left,right:g.left+c.clientWidth,top:g.top,bottom:g.top+c.clientHeight}}let u=0,p=0;if(s=="nearest")t.top0&&t.bottom>f.bottom+p&&(p=t.bottom-f.bottom+p+o)):t.bottom>f.bottom&&(p=t.bottom-f.bottom+o,e<0&&t.top-p0&&t.right>f.right+u&&(u=t.right-f.right+u+r)):t.right>f.right&&(u=t.right-f.right+r,e<0&&t.lefte)return f.domBoundsAround(t,e,a);if(d>=t&&s==-1&&(s=h,r=a),a>e&&f.dom.parentNode==this.dom){o=h,l=c;break}c=d,a=d+f.breakAfter}return{from:r,to:l<0?i+this.length:l,startDOM:(s?this.children[s-1].dom.nextSibling:null)||this.dom.firstChild,endDOM:o=0?this.children[o].dom:null}}markDirty(t=!1){this.dirty|=2,this.markParentsDirty(t)}markParentsDirty(t){for(let e=this.parent;e;e=e.parent){if(t&&(e.dirty|=2),e.dirty&1)return;e.dirty|=1,t=!1}}setParent(t){this.parent!=t&&(this.parent=t,this.dirty&&this.markParentsDirty(!0))}setDOM(t){this.dom&&(this.dom.cmView=null),this.dom=t,t.cmView=this}get rootView(){for(let t=this;;){let e=t.parent;if(!e)return t;t=e}}replaceChildren(t,e,i=je){this.markDirty();for(let s=t;sthis.pos||t==this.pos&&(e>0||this.i==0||this.children[this.i-1].breakAfter))return this.off=t-this.pos,this;let i=this.children[--this.i];this.pos-=i.length+i.breakAfter}}};function ys(n,t,e,i,s,r,o,l,h){let{children:a}=n,c=a.length?a[t]:null,f=r.length?r[r.length-1]:null,d=f?f.breakAfter:o;if(!(t==i&&c&&!o&&!d&&r.length<2&&c.merge(e,s,r.length?f:null,e==0,l,h))){if(i0&&(!o&&r.length&&c.merge(e,c.length,r[0],!1,l,0)?c.breakAfter=r.shift().breakAfter:(e2),y={mac:ks||/Mac/.test(j.platform),windows:/Win/.test(j.platform),linux:/Linux|X11/.test(j.platform),ie:ue,ie_version:bs?Ue.documentMode||6:Xe?+Xe[1]:Je?+Je[1]:0,gecko:vs,gecko_version:vs?+(/Firefox\/(\d+)/.exec(j.userAgent)||[0,0])[1]:0,chrome:!!Ye,chrome_version:Ye?+Ye[1]:0,ios:ks,android:/Android\b/.test(j.userAgent),webkit:xs,safari:Ss,webkit_version:xs?+(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent)||[0,0])[1]:0,tabSize:Ue.documentElement.style.tabSize!=null?"tab-size":"-moz-tab-size"},dr=256,_=class extends k{constructor(t){super();this.text=t}get length(){return this.text.length}createDOM(t){this.setDOM(t||document.createTextNode(this.text))}sync(t){this.dom||this.createDOM(),this.dom.nodeValue!=this.text&&(t&&t.node==this.dom&&(t.written=!0),this.dom.nodeValue=this.text)}reuseDOM(t){t.nodeType==3&&this.createDOM(t)}merge(t,e,i){return i&&(!(i instanceof _)||this.length-(e-t)+i.length>dr)?!1:(this.text=this.text.slice(0,t)+(i?i.text:"")+this.text.slice(e),this.markDirty(),!0)}split(t){let e=new _(this.text.slice(t));return this.text=this.text.slice(0,t),this.markDirty(),e}localPosFromDOM(t,e){return t==this.dom?e:e?this.text.length:0}domAtPos(t){return new V(this.dom,t)}domBoundsAround(t,e,i){return{from:i,to:i+this.length,startDOM:this.dom,endDOM:this.dom.nextSibling}}coordsAt(t,e){return Ze(this.dom,t,e)}},U=class extends k{constructor(t,e=[],i=0){super();this.mark=t,this.children=e,this.length=i;for(let s of e)s.setParent(this)}setAttrs(t){if(gs(t),this.mark.class&&(t.className=this.mark.class),this.mark.attrs)for(let e in this.mark.attrs)t.setAttribute(e,this.mark.attrs[e]);return t}reuseDOM(t){t.nodeName==this.mark.tagName.toUpperCase()&&(this.setDOM(t),this.dirty|=4|2)}sync(t){this.dom?this.dirty&4&&this.setAttrs(this.dom):this.setDOM(this.setAttrs(document.createElement(this.mark.tagName))),super.sync(t)}merge(t,e,i,s,r,o){return i&&(!(i instanceof U&&i.mark.eq(this.mark))||t&&r<=0||et&&e.push(i=t&&(s=r),i=h,r++}let o=this.length-t;return this.length=t,s>-1&&(this.children.length=s,this.markDirty()),new U(this.mark,e,o)}domAtPos(t){return As(this.dom,this.children,t)}coordsAt(t,e){return Ds(this,t,e)}};function Ze(n,t,e){let i=n.nodeValue.length;t>i&&(t=i);let s=t,r=t,o=0;t==0&&e<0||t==i&&e>=0?y.chrome||y.gecko||(t?(s--,o=1):r=0)?0:l.length-1];return y.safari&&!o&&h.width==0&&(h=Array.prototype.find.call(l,a=>a.width)||h),o?fe(h,o<0):h||null}var tt=class extends k{constructor(t,e,i){super();this.widget=t,this.length=e,this.side=i,this.prevWidget=null}static create(t,e,i){return new(t.customView||tt)(t,e,i)}split(t){let e=tt.create(this.widget,this.length-t,this.side);return this.length-=t,e}sync(){(!this.dom||!this.widget.updateDOM(this.dom))&&(this.dom&&this.prevWidget&&this.prevWidget.destroy(this.dom),this.prevWidget=null,this.setDOM(this.widget.toDOM(this.editorView)),this.dom.contentEditable="false")}getSide(){return this.side}merge(t,e,i,s,r,o){return i&&(!(i instanceof tt)||!this.widget.compare(i.widget)||t>0&&r<=0||e0?i.length-1:0;s=i[r],!(t>0?r==0:r==i.length-1||s.top0?-1:1);return t==0&&e>0||t==this.length&&e<=0?s:fe(s,t==0)}get isEditable(){return!1}destroy(){super.destroy(),this.dom&&this.widget.destroy(this.dom)}},Qe=class extends tt{domAtPos(t){let{topView:e,text:i}=this.widget;return e?_e(t,0,e,i,(s,r)=>s.domAtPos(r),s=>new V(i,Math.min(s,i.nodeValue.length))):new V(i,Math.min(t,i.nodeValue.length))}sync(){this.setDOM(this.widget.toDOM())}localPosFromDOM(t,e){let{topView:i,text:s}=this.widget;return i?Cs(t,e,i,s):Math.min(e,this.length)}ignoreMutation(){return!1}get overrideDOMText(){return null}coordsAt(t,e){let{topView:i,text:s}=this.widget;return i?_e(t,e,i,s,(r,o,l)=>r.coordsAt(o,l),(r,o)=>Ze(s,r,o)):Ze(s,t,e)}destroy(){var t;super.destroy(),(t=this.widget.topView)===null||t===void 0||t.destroy()}get isEditable(){return!0}};function _e(n,t,e,i,s,r){if(e instanceof U){for(let o of e.children){let l=Dt(o.dom,i),h=l?i.nodeValue.length:o.length;if(n0?-1:1);return i&&i.tope.top?{left:e.left,right:e.right,top:i.top,bottom:i.bottom}:e}get overrideDOMText(){return x.empty}};_.prototype.children=tt.prototype.children=dt.prototype.children=je;function pr(n,t){let e=n.parent,i=e?e.children.indexOf(n):-1;for(;e&&i>=0;)if(t<0?i>0:is&&e0;i--){let s=t[i-1].dom;if(s.parentNode==n)return V.after(s)}return new V(n,0)}function Ms(n,t,e){let i,{children:s}=n;e>0&&t instanceof U&&s.length&&(i=s[s.length-1])instanceof U&&i.mark.eq(t.mark)?Ms(i,t.children[0],e-1):(s.push(t),t.setParent(n)),n.length+=t.length}function Ds(n,t,e){for(let r=0,o=0;o0?h>=t:h>t)&&(t0)){let c=0;if(h==r){if(l.getSide()<=0)continue;c=e=-l.getSide()}let f=l.coordsAt(Math.max(0,t-r),e);return c&&f?fe(f,e<0):f}r=h}let i=n.dom.lastChild;if(!i)return n.dom.getBoundingClientRect();let s=Ht(i);return s[s.length-1]||null}function ti(n,t){for(let e in n)e=="class"&&t.class?t.class+=" "+n.class:e=="style"&&t.style?t.style+=";"+n.style:t[e]=n[e];return t}function ei(n,t){if(n==t)return!0;if(!n||!t)return!1;let e=Object.keys(n),i=Object.keys(t);if(e.length!=i.length)return!1;for(let s of e)if(i.indexOf(s)==-1||n[s]!==t[s])return!1;return!0}function ii(n,t,e){let i=null;if(t)for(let s in t)e&&s in e||n.removeAttribute(i=s);if(e)for(let s in e)t&&t[s]==e[s]||n.setAttribute(i=s,e[s]);return!!i}var Wt=class{eq(t){return!1}updateDOM(t){return!1}compare(t){return this==t||this.constructor==t.constructor&&this.eq(t)}get estimatedHeight(){return-1}ignoreEvent(t){return!0}get customView(){return null}destroy(t){}},L=function(n){return n[n.Text=0]="Text",n[n.WidgetBefore=1]="WidgetBefore",n[n.WidgetAfter=2]="WidgetAfter",n[n.WidgetRange=3]="WidgetRange",n}(L||(L={})),N=class extends ot{constructor(t,e,i,s){super();this.startSide=t,this.endSide=e,this.widget=i,this.spec=s}get heightRelevant(){return!1}static mark(t){return new zt(t)}static widget(t){let e=t.side||0,i=!!t.block;return e+=i?e>0?3e8:-4e8:e>0?1e8:-1e8,new ht(t,e,e,i,t.widget||null,!1)}static replace(t){let e=!!t.block,i,s;if(t.isBlockGap)i=-5e8,s=4e8;else{let{start:r,end:o}=Os(t,e);i=(r?e?-3e8:-1:5e8)-1,s=(o?e?2e8:1:-6e8)+1}return new ht(t,i,s,e,t.widget||null,!0)}static line(t){return new Rt(t)}static set(t,e=!1){return O.of(t,e)}hasHeight(){return this.widget?this.widget.estimatedHeight>-1:!1}};N.none=O.empty;var zt=class extends N{constructor(t){let{start:e,end:i}=Os(t);super(e?-1:5e8,i?1:-6e8,null,t);this.tagName=t.tagName||"span",this.class=t.class||"",this.attrs=t.attributes||null}eq(t){return this==t||t instanceof zt&&this.tagName==t.tagName&&this.class==t.class&&ei(this.attrs,t.attrs)}range(t,e=t){if(t>=e)throw new RangeError("Mark decorations may not be empty");return super.range(t,e)}};zt.prototype.point=!1;var Rt=class extends N{constructor(t){super(-2e8,-2e8,null,t)}eq(t){return t instanceof Rt&&ei(this.spec.attributes,t.spec.attributes)}range(t,e=t){if(e!=t)throw new RangeError("Line decoration ranges must be zero-length");return super.range(t,e)}};Rt.prototype.mapMode=K.TrackBefore;Rt.prototype.point=!0;var ht=class extends N{constructor(t,e,i,s,r,o){super(e,i,r,t);this.block=s,this.isReplace=o,this.mapMode=s?e<=0?K.TrackBefore:K.TrackAfter:K.TrackDel}get type(){return this.startSide=5}eq(t){return t instanceof ht&&gr(this.widget,t.widget)&&this.block==t.block&&this.startSide==t.startSide&&this.endSide==t.endSide}range(t,e=t){if(this.isReplace&&(t>e||t==e&&this.startSide>0&&this.endSide<=0))throw new RangeError("Invalid range for replacement decoration");if(!this.isReplace&&e!=t)throw new RangeError("Widget decorations can only have zero-length ranges");return super.range(t,e)}};ht.prototype.point=!0;function Os(n,t=!1){let{inclusiveStart:e,inclusiveEnd:i}=n;return e==null&&(e=n.inclusive),i==null&&(i=n.inclusive),{start:e??t,end:i??t}}function gr(n,t){return n==t||!!(n&&t&&n.compare(t))}function si(n,t,e,i=0){let s=e.length-1;s>=0&&e[s]+i>=n?e[s]=Math.max(e[s],t):e.push(n,t)}var W=class extends k{constructor(){super(...arguments);this.children=[],this.length=0,this.prevAttrs=void 0,this.attrs=null,this.breakAfter=0}merge(t,e,i,s,r,o){if(i){if(!(i instanceof W))return!1;this.dom||i.transferDOM(this)}return s&&this.setDeco(i?i.attrs:null),ws(this,t,e,i?i.children:[],r,o),!0}split(t){let e=new W;if(e.breakAfter=this.breakAfter,this.length==0)return e;let{i,off:s}=this.childPos(t);s&&(e.append(this.children[i].split(s),0),this.children[i].merge(s,this.children[i].length,null,!1,0,0),i++);for(let r=i;r0&&this.children[i-1].length==0;)this.children[--i].destroy();return this.children.length=i,this.markDirty(),this.length=t,e}transferDOM(t){!this.dom||(this.markDirty(),t.setDOM(this.dom),t.prevAttrs=this.prevAttrs===void 0?this.attrs:this.prevAttrs,this.prevAttrs=void 0,this.dom=null)}setDeco(t){ei(this.attrs,t)||(this.dom&&(this.prevAttrs=this.attrs,this.markDirty()),this.attrs=t)}append(t,e){Ms(this,t,e)}addLineDeco(t){let e=t.spec.attributes,i=t.spec.class;e&&(this.attrs=ti(e,this.attrs||{})),i&&(this.attrs=ti({class:i},this.attrs||{}))}domAtPos(t){return As(this.dom,this.children,t)}reuseDOM(t){t.nodeName=="DIV"&&(this.setDOM(t),this.dirty|=4|2)}sync(t){var e;this.dom?this.dirty&4&&(gs(this.dom),this.dom.className="cm-line",this.prevAttrs=this.attrs?null:void 0):(this.setDOM(document.createElement("div")),this.dom.className="cm-line",this.prevAttrs=this.attrs?null:void 0),this.prevAttrs!==void 0&&(ii(this.dom,this.prevAttrs,this.attrs),this.dom.classList.add("cm-line"),this.prevAttrs=void 0),super.sync(t);let i=this.dom.lastChild;for(;i&&k.get(i)instanceof U;)i=i.lastChild;if(!i||!this.length||i.nodeName!="BR"&&((e=k.get(i))===null||e===void 0?void 0:e.isEditable)==!1&&(!y.ios||!this.children.some(s=>s instanceof _))){let s=document.createElement("BR");s.cmIgnore=!0,this.dom.appendChild(s)}}measureTextSize(){if(this.children.length==0||this.length>20)return null;let t=0;for(let e of this.children){if(!(e instanceof _))return null;let i=Ht(e.dom);if(i.length!=1)return null;t+=i[0].width}return{lineHeight:this.dom.getBoundingClientRect().height,charWidth:t/this.length}}coordsAt(t,e){return Ds(this,t,e)}become(t){return!1}get type(){return L.Text}static find(t,e){for(let i=0,s=0;i=e){if(r instanceof W)return r;if(o>e)break}s=o+r.breakAfter}return null}},at=class extends k{constructor(t,e,i){super();this.widget=t,this.length=e,this.type=i,this.breakAfter=0,this.prevWidget=null}merge(t,e,i,s,r,o){return i&&(!(i instanceof at)||!this.widget.compare(i.widget)||t>0&&r<=0||e0;){if(this.textOff==this.text.length){let{value:r,lineBreak:o,done:l}=this.cursor.next(this.skip);if(this.skip=0,l)throw new Error("Ran out of text content when drawing inline views");if(o){this.posCovered()||this.getLine(),this.content.length?this.content[this.content.length-1].breakAfter=1:this.breakAtStart=1,this.flushBuffer([]),this.curLine=null,t--;continue}else this.text=r,this.textOff=0}let s=Math.min(this.text.length-this.textOff,t,512);this.flushBuffer(e.slice(0,i)),this.getLine().append(pe(new _(this.text.slice(this.textOff,this.textOff+s)),e),i),this.atCursorPos=!0,this.textOff+=s,t-=s,i=0}}span(t,e,i,s){this.buildText(e-t,i,s),this.pos=e,this.openStart<0&&(this.openStart=s)}point(t,e,i,s,r,o){if(this.disallowBlockEffectsFor[o]&&i instanceof ht){if(i.block)throw new RangeError("Block decorations may not be specified via plugins");if(e>this.doc.lineAt(this.pos).to)throw new RangeError("Decorations that replace line breaks may not be specified via plugins")}let l=e-t;if(i instanceof ht)if(i.block){let{type:h}=i;h==L.WidgetAfter&&!this.posCovered()&&this.getLine(),this.addBlockWidget(new at(i.widget||new ni("div"),l,h))}else{let h=tt.create(i.widget||new ni("span"),l,i.startSide),a=this.atCursorPos&&!h.isEditable&&r<=s.length&&(t0),c=!h.isEditable&&(tn.some(t=>t)}),qt=class{constructor(t,e="nearest",i="nearest",s=5,r=5){this.range=t,this.y=e,this.x=i,this.yMargin=s,this.xMargin=r}map(t){return t.empty?this:new qt(this.range.map(t),this.y,this.x,this.yMargin,this.xMargin)}},Vs=E.define({map:(n,t)=>n.map(t)});function pt(n,t,e){let i=n.facet(Ls);i.length?i[0](t):window.onerror?window.onerror(String(t),e,void 0,void 0,t):e?console.error(e+":",t):console.error(t)}var ge=v.define({combine:n=>n.length?n[0]:!0}),mr=0,Kt=v.define(),$t=class{constructor(t,e,i,s){this.id=t,this.create=e,this.domEventHandlers=i,this.extension=s(this)}static define(t,e){let{eventHandlers:i,provide:s,decorations:r}=e||{};return new $t(mr++,t,i,o=>{let l=[Kt.of(o)];return r&&l.push(jt.of(h=>{let a=h.plugin(o);return a?r(a):N.none})),s&&l.push(s(o)),l})}static fromClass(t,e){return $t.define(i=>new t(i),e)}},me=class{constructor(t){this.spec=t,this.mustUpdate=null,this.value=null}update(t){if(this.value){if(this.mustUpdate){let e=this.mustUpdate;if(this.mustUpdate=null,this.value.update)try{this.value.update(e)}catch(i){if(pt(e.state,i,"CodeMirror plugin crashed"),this.value.destroy)try{this.value.destroy()}catch(s){}this.deactivate()}}}else if(this.spec)try{this.value=this.spec.create(t)}catch(e){pt(t.state,e,"CodeMirror plugin crashed"),this.deactivate()}return this}destroy(t){var e;if((e=this.value)===null||e===void 0?void 0:e.destroy)try{this.value.destroy()}catch(i){pt(t.state,i,"CodeMirror plugin crashed")}}deactivate(){this.spec=this.value=null}},Ns=v.define(),Is=v.define(),jt=v.define(),Hs=v.define(),Fs=v.define(),Gt=v.define(),Y=class{constructor(t,e,i,s){this.fromA=t,this.toA=e,this.fromB=i,this.toB=s}join(t){return new Y(Math.min(this.fromA,t.fromA),Math.max(this.toA,t.toA),Math.min(this.fromB,t.fromB),Math.max(this.toB,t.toB))}addToSet(t){let e=t.length,i=this;for(;e>0;e--){let s=t[e-1];if(!(s.fromA>i.toA)){if(s.toAc)break;r+=2}if(!h)return i;new Y(h.fromA,h.toA,h.fromB,h.toB).addToSet(i),o=h.toA,l=h.toB}}},Ut=class{constructor(t,e,i){this.view=t,this.state=e,this.transactions=i,this.flags=0,this.startState=t.state,this.changes=T.empty(this.startState.doc.length);for(let o of i)this.changes=this.changes.compose(o.changes);let s=[];this.changes.iterChangedRanges((o,l,h,a)=>s.push(new Y(o,l,h,a))),this.changedRanges=s;let r=t.hasFocus;r!=t.inputState.notifiedFocused&&(t.inputState.notifiedFocused=r,this.flags|=1)}static create(t,e,i){return new Ut(t,e,i)}get viewportChanged(){return(this.flags&4)>0}get heightChanged(){return(this.flags&2)>0}get geometryChanged(){return this.docChanged||(this.flags&(8|2))>0}get focusChanged(){return(this.flags&1)>0}get docChanged(){return!this.changes.empty}get selectionSet(){return this.transactions.some(t=>t.selection)}get empty(){return this.flags==0&&this.transactions.length==0}},z=function(n){return n[n.LTR=0]="LTR",n[n.RTL=1]="RTL",n}(z||(z={})),oi=z.LTR,yr=z.RTL;function Ws(n){let t=[];for(let e=0;e=e){if(l.level==i)return o;(r<0||(s!=0?s<0?l.frome:t[r].level>l.level))&&(r=o)}}if(r<0)throw new RangeError("Index out of range");return r}},M=[];function Sr(n,t){let e=n.length,i=t==oi?1:2,s=t==oi?2:1;if(!n||i==1&&!xr.test(n))return zs(e);for(let o=0,l=i,h=i;o=0;d-=3)if(Z[d+1]==-c){let u=Z[d+2],p=u&2?i:u&4?u&1?s:i:0;p&&(M[o]=M[Z[d]]=p),l=d;break}}else{if(Z.length==189)break;Z[l++]=o,Z[l++]=a,Z[l++]=h}else if((f=M[o])==2||f==1){let d=f==i;h=d?0:1;for(let u=l-3;u>=0;u-=3){let p=Z[u+2];if(p&2)break;if(d)Z[u+2]|=2;else{if(p&4)break;Z[u+2]|=4}}}for(let o=0;ol;){let c=a,f=M[--a]!=2;for(;a>l&&f==(M[a-1]!=2);)a--;r.push(new gt(a,c,f?2:1))}else r.push(new gt(l,o,0))}else for(let o=0;o1)for(let h of this.points)h.node==t&&h.pos>this.text.length&&(h.pos-=o-1);i=r+o}}readNode(t){if(t.cmIgnore)return;let e=k.get(t),i=e&&e.overrideDOMText;if(i!=null){this.findPointInside(t,i.length);for(let s=i.iter();!s.next().done;)s.lineBreak?this.lineBreak():this.append(s.value)}else t.nodeType==3?this.readTextNode(t):t.nodeName=="BR"?t.nextSibling&&this.lineBreak():t.nodeType==1&&this.readRange(t.firstChild,null)}findPointBefore(t,e){for(let i of this.points)i.node==t&&t.childNodes[i.offset]==e&&(i.pos=this.text.length)}findPointInside(t,e){for(let i of this.points)(t.nodeType==3?i.node==t:t.contains(i.node))&&(i.pos=this.text.length+Math.min(e,i.offset))}};function Ks(n){return n.nodeType==1&&/^(DIV|P|LI|UL|OL|BLOCKQUOTE|DD|DT|H\d|SECTION|PRE)$/.test(n.nodeName)}var ai=class{constructor(t,e){this.node=t,this.offset=e,this.pos=-1}},ci=class extends k{constructor(t){super();this.view=t,this.compositionDeco=N.none,this.decorations=[],this.dynamicDecorationMap=[],this.minWidth=0,this.minWidthFrom=0,this.minWidthTo=0,this.impreciseAnchor=null,this.impreciseHead=null,this.forceSelection=!1,this.lastUpdate=Date.now(),this.setDOM(t.contentDOM),this.children=[new W],this.children[0].setParent(this),this.updateDeco(),this.updateInner([new Y(0,0,0,t.state.doc.length)],0)}get root(){return this.view.root}get editorView(){return this.view}get length(){return this.view.state.doc.length}update(t){let e=t.changedRanges;this.minWidth>0&&e.length&&(e.every(({fromA:o,toA:l})=>lthis.minWidthTo)?(this.minWidthFrom=t.changes.mapPos(this.minWidthFrom,1),this.minWidthTo=t.changes.mapPos(this.minWidthTo,1)):this.minWidth=this.minWidthFrom=this.minWidthTo=0),this.view.inputState.composing<0?this.compositionDeco=N.none:(t.transactions.length||this.dirty)&&(this.compositionDeco=Ar(this.view,t.changes)),(y.ie||y.chrome)&&!this.compositionDeco.size&&t&&t.state.doc.lines!=t.startState.doc.lines&&(this.forceSelection=!0);let i=this.decorations,s=this.updateDeco(),r=Dr(i,s,t.changes);return e=Y.extendWithRanges(e,r),this.dirty==0&&e.length==0?!1:(this.updateInner(e,t.startState.doc.length),t.transactions.length&&(this.lastUpdate=Date.now()),!0)}updateInner(t,e){this.view.viewState.mustMeasureContent=!0,this.updateChildren(t,e);let{observer:i}=this.view;i.ignore(()=>{this.dom.style.height=this.view.viewState.contentHeight+"px",this.dom.style.flexBasis=this.minWidth?this.minWidth+"px":"";let r=y.chrome||y.ios?{node:i.selectionRange.focusNode,written:!1}:void 0;this.sync(r),this.dirty=0,r&&(r.written||i.selectionRange.focusNode!=r.node)&&(this.forceSelection=!0),this.dom.style.height=""});let s=[];if(this.view.viewport.from||this.view.viewport.to=0?t[s]:null;if(!r)break;let{fromA:o,toA:l,fromB:h,toB:a}=r,{content:c,breakAtStart:f,openStart:d,openEnd:u}=de.build(this.view.state.doc,h,a,this.decorations,this.dynamicDecorationMap),{i:p,off:g}=i.findPos(l,1),{i:m,off:b}=i.findPos(o,-1);ys(this,m,b,p,g,c,f,d,u)}}updateSelection(t=!1,e=!1){if((t||!this.view.observer.selectionRange.focusNode)&&this.view.observer.readSelectionRange(),!(e||this.mayControlSelection())||y.ios&&this.view.inputState.rapidCompositionStart)return;let i=this.forceSelection;this.forceSelection=!1;let s=this.view.state.selection.main,r=this.domAtPos(s.anchor),o=s.empty?r:this.domAtPos(s.head);if(y.gecko&&s.empty&&Cr(r)){let h=document.createTextNode("");this.view.observer.ignore(()=>r.node.insertBefore(h,r.node.childNodes[r.offset]||null)),r=o=new V(h,0),i=!0}let l=this.view.observer.selectionRange;(i||!l.focusNode||!ae(r.node,r.offset,l.anchorNode,l.anchorOffset)||!ae(o.node,o.offset,l.focusNode,l.focusOffset))&&(this.view.observer.ignore(()=>{y.android&&y.chrome&&this.dom.contains(l.focusNode)&&Or(l.focusNode,this.dom)&&(this.dom.blur(),this.dom.focus({preventScroll:!0}));let h=he(this.root);if(h)if(s.empty){if(y.gecko){let a=Mr(r.node,r.offset);if(a&&a!=(1|2)){let c=Gs(r.node,r.offset,a==1?1:-1);c&&(r=new V(c,a==1?0:c.nodeValue.length))}}h.collapse(r.node,r.offset),s.bidiLevel!=null&&l.cursorBidiLevel!=null&&(l.cursorBidiLevel=s.bidiLevel)}else if(h.extend)h.collapse(r.node,r.offset),h.extend(o.node,o.offset);else{let a=document.createRange();s.anchor>s.head&&([r,o]=[o,r]),a.setEnd(o.node,o.offset),a.setStart(r.node,r.offset),h.removeAllRanges(),h.addRange(a)}}),this.view.observer.setSelectionRange(r,o)),this.impreciseAnchor=r.precise?null:new V(l.anchorNode,l.anchorOffset),this.impreciseHead=o.precise?null:new V(l.focusNode,l.focusOffset)}enforceCursorAssoc(){if(this.compositionDeco.size)return;let t=this.view.state.selection.main,e=he(this.root);if(!e||!t.empty||!t.assoc||!e.modify)return;let i=W.find(this,t.head);if(!i)return;let s=i.posAtStart;if(t.head==s||t.head==s+i.length)return;let r=this.coordsAt(t.head,-1),o=this.coordsAt(t.head,1);if(!r||!o||r.bottom>o.top)return;let l=this.domAtPos(t.head+t.assoc);e.collapse(l.node,l.offset),e.modify("move",t.assoc<0?"forward":"backward","lineboundary")}mayControlSelection(){let t=this.root.activeElement;return t==this.dom||Ke(this.dom,this.view.observer.selectionRange)&&!(t&&this.dom.contains(t))}nearest(t){for(let e=t;e;){let i=k.get(e);if(i&&i.rootView==this)return i;e=e.parentNode}return null}posFromDOM(t,e){let i=this.nearest(t);if(!i)throw new RangeError("Trying to find position for a DOM position outside of the document");return i.localPosFromDOM(t,e)+i.posAtStart}domAtPos(t){let{i:e,off:i}=this.childCursor().findPos(t,-1);for(;eo||t==o&&r.type!=L.WidgetBefore&&r.type!=L.WidgetAfter&&(!s||e==2||this.children[s-1].breakAfter||this.children[s-1].type==L.WidgetBefore&&e>-2))return r.coordsAt(t-o,e);i=o}}measureVisibleLineHeights(t){let e=[],{from:i,to:s}=t,r=this.view.contentDOM.clientWidth,o=r>Math.max(this.view.scrollDOM.clientWidth,this.minWidth)+1,l=-1,h=this.view.textDirection==z.LTR;for(let a=0,c=0;cs)break;if(a>=i){let u=f.dom.getBoundingClientRect();if(e.push(u.height),o){let p=f.dom.lastChild,g=p?Ht(p):[];if(g.length){let m=g[g.length-1],b=h?m.right-u.left:u.right-m.left;b>l&&(l=b,this.minWidth=r,this.minWidthFrom=a,this.minWidthTo=d)}}}a=d+f.breakAfter}return e}textDirectionAt(t){let{i:e}=this.childPos(t,1);return getComputedStyle(this.children[e].dom).direction=="rtl"?z.RTL:z.LTR}measureTextSize(){for(let s of this.children)if(s instanceof W){let r=s.measureTextSize();if(r)return r}let t=document.createElement("div"),e,i;return t.className="cm-line",t.style.width="99999px",t.textContent="abc def ghi jkl mno pqr stu",this.view.observer.ignore(()=>{this.dom.appendChild(t);let s=Ht(t.firstChild)[0];e=t.getBoundingClientRect().height,i=s?s.width/27:7,t.remove()}),{lineHeight:e,charWidth:i}}childCursor(t=this.length){let e=this.children.length;return e&&(t-=this.children[--e].length),new Ge(this.children,t,e)}computeBlockGapDeco(){let t=[],e=this.view.viewState;for(let i=0,s=0;;s++){let r=s==e.viewports.length?null:e.viewports[s],o=r?r.from-1:this.length;if(o>i){let l=e.lineBlockAt(o).bottom-e.lineBlockAt(i).top;t.push(N.replace({widget:new fi(l),block:!0,inclusive:!0,isBlockGap:!0}).range(i,o))}if(!r)break;i=r.to+1}return N.set(t)}updateDeco(){let t=this.view.state.facet(jt).map((e,i)=>(this.dynamicDecorationMap[i]=typeof e=="function")?e(this.view):e);for(let e=t.length;ee.anchor?-1:1),s;if(!i)return;!e.empty&&(s=this.coordsAt(e.anchor,e.anchor>e.head?-1:1))&&(i={left:Math.min(i.left,s.left),top:Math.min(i.top,s.top),right:Math.max(i.right,s.right),bottom:Math.max(i.bottom,s.bottom)});let r=0,o=0,l=0,h=0;for(let c of this.view.state.facet(Fs).map(f=>f(this.view)))if(c){let{left:f,right:d,top:u,bottom:p}=c;f!=null&&(r=Math.max(r,f)),d!=null&&(o=Math.max(o,d)),u!=null&&(l=Math.max(l,u)),p!=null&&(h=Math.max(h,p))}let a={left:i.left-r,top:i.top-l,right:i.right+o,bottom:i.bottom+h};fr(this.view.scrollDOM,a,e.head0&&e<=0)n=n.childNodes[t-1],t=ce(n);else if(n.nodeType==1&&t=0)n=n.childNodes[t],t=0;else return null}}function Mr(n,t){return n.nodeType!=1?0:(t&&n.childNodes[t-1].contentEditable=="false"?1:0)|(t0;){let a=Q(s.text,o,!1);if(i(s.text.slice(a,o))!=h)break;o=a}for(;ln?t.left-n:Math.max(0,n-t.right)}function Er(n,t){return t.top>n?t.top-n:Math.max(0,n-t.bottom)}function ui(n,t){return n.topt.top+1}function Js(n,t){return tn.bottom?{top:n.top,left:n.left,right:n.right,bottom:t}:n}function di(n,t,e){let i,s,r,o,l,h,a,c;for(let u=n.firstChild;u;u=u.nextSibling){let p=Ht(u);for(let g=0;gB||o==B&&r>b)&&(i=u,s=m,r=b,o=B),b==0?e>m.bottom&&(!a||a.bottomm.top)&&(h=u,c=m):a&&ui(a,m)?a=Xs(a,m.bottom):c&&ui(c,m)&&(c=Js(c,m.top))}}if(a&&a.bottom>=e?(i=l,s=a):c&&c.top<=e&&(i=h,s=c),!i)return{node:n,offset:0};let f=Math.max(s.left,Math.min(s.right,t));if(i.nodeType==3)return Ys(i,f,e);if(!r&&i.contentEditable=="true")return di(i,f,e);let d=Array.prototype.indexOf.call(n.childNodes,i)+(t>=(s.left+s.right)/2?1:0);return{node:n,offset:d}}function Ys(n,t,e){let i=n.nodeValue.length,s=-1,r=1e9,o=0;for(let l=0;le?c.top-e:e-c.bottom)-1;if(c.left-1<=t&&c.right+1>=t&&f=(c.left+c.right)/2,u=d;if((y.chrome||y.gecko)&&Tt(n,l).getBoundingClientRect().left==c.right&&(u=!d),f<=0)return{node:n,offset:l+(u?1:0)};s=l+(u?1:0),r=f}}}return{node:n,offset:s>-1?s:o>0?n.nodeValue.length:0}}function Zs(n,{x:t,y:e},i,s=-1){var r;let o=n.contentDOM.getBoundingClientRect(),l=o.top+n.viewState.paddingTop,h,{docHeight:a}=n.viewState,c=e-l;if(c<0)return 0;if(c>a)return n.state.doc.length;for(let b=n.defaultLineHeight/2,B=!1;h=n.elementAtHeight(c),h.type!=L.Text;)for(;c=s>0?h.bottom+b:h.top-b,!(c>=0&&c<=a);){if(B)return i?null:0;B=!0,s=-s}e=l+c;let f=h.from;if(fn.viewport.to)return n.viewport.to==n.state.doc.length?n.state.doc.length:i?null:Qs(n,o,h,t,e);let d=n.dom.ownerDocument,u=n.root.elementFromPoint?n.root:d,p=u.elementFromPoint(t,e);p&&!n.contentDOM.contains(p)&&(p=null),p||(t=Math.max(o.left+1,Math.min(o.right-1,t)),p=u.elementFromPoint(t,e),p&&!n.contentDOM.contains(p)&&(p=null));let g,m=-1;if(p&&((r=n.docView.nearest(p))===null||r===void 0?void 0:r.isEditable)!=!1){if(d.caretPositionFromPoint){let b=d.caretPositionFromPoint(t,e);b&&({offsetNode:g,offset:m}=b)}else if(d.caretRangeFromPoint){let b=d.caretRangeFromPoint(t,e);b&&({startContainer:g,startOffset:m}=b,(y.safari&&Lr(g,m,t)||y.chrome&&Br(g,m,t))&&(g=void 0))}}if(!g||!n.docView.dom.contains(g)){let b=W.find(n.docView,f);if(!b)return c>h.top+h.height/2?h.to:h.from;({node:g,offset:m}=di(b.dom,t,e))}return n.docView.posFromDOM(g,m)}function Qs(n,t,e,i,s){let r=Math.round((i-t.left)*n.defaultCharacterWidth);n.lineWrapping&&e.height>n.defaultLineHeight*1.5&&(r+=Math.floor((s-e.top)/n.defaultLineHeight)*n.viewState.heightOracle.lineLength);let o=n.state.sliceDoc(e.from,e.to);return e.from+ns(o,r,n.state.tabSize)}function Lr(n,t,e){let i;if(n.nodeType!=3||t!=(i=n.nodeValue.length))return!1;for(let s=n.nextSibling;s;s=s.nextSibling)if(s.nodeType!=1||s.nodeName!="BR")return!1;return Tt(n,i-1,i).getBoundingClientRect().left>e}function Br(n,t,e){if(t!=0)return!1;for(let s=n;;){let r=s.parentNode;if(!r||r.nodeType!=1||r.firstChild!=s)return!1;if(r.classList.contains("cm-line"))break;s=r}let i=n.nodeType==1?n.getBoundingClientRect():Tt(n,0,Math.max(n.nodeValue.length,1)).getBoundingClientRect();return e-i.left>5}function Pr(n,t,e,i){let s=n.state.doc.lineAt(t.head),r=!i||!n.lineWrapping?null:n.coordsAtPos(t.assoc<0&&t.head>s.from?t.head-1:t.head);if(r){let h=n.dom.getBoundingClientRect(),a=n.textDirectionAt(s.from),c=n.posAtCoords({x:e==(a==z.LTR)?h.right-1:h.left+1,y:(r.top+r.bottom)/2});if(c!=null)return w.cursor(c,e?-1:1)}let o=W.find(n.docView,t.head),l=o?e?o.posAtEnd:o.posAtStart:e?s.to:s.from;return w.cursor(l,e?-1:1)}function _s(n,t,e,i){let s=n.state.doc.lineAt(t.head),r=n.bidiSpans(s),o=n.textDirectionAt(s.from);for(let l=t,h=null;;){let a=kr(s,r,o,l,e),c=qs;if(!a){if(s.number==(e?n.state.doc.lines:1))return l;c=` +`,s=n.state.doc.line(s.number+(e?1:-1)),r=n.bidiSpans(s),a=w.cursor(e?s.from:s.to)}if(h){if(!h(c))return l}else{if(!i)return a;h=i(c)}l=a}}function Vr(n,t,e){let i=n.state.charCategorizer(t),s=i(e);return r=>{let o=i(r);return s==X.Space&&(s=o),s==o}}function Nr(n,t,e,i){let s=t.head,r=e?1:-1;if(s==(e?n.state.doc.length:0))return w.cursor(s,t.assoc);let o=t.goalColumn,l,h=n.contentDOM.getBoundingClientRect(),a=n.coordsAtPos(s),c=n.documentTop;if(a)o==null&&(o=a.left-h.left),l=r<0?a.top:a.bottom;else{let u=n.viewState.lineBlockAt(s);o==null&&(o=Math.min(h.right-h.left,n.defaultCharacterWidth*(s-u.from))),l=(r<0?u.top:u.bottom)+c}let f=h.left+o,d=i??n.defaultLineHeight>>1;for(let u=0;;u+=10){let p=l+(d+u)*r,g=Zs(n,{x:f,y:p},!1,r);if(ph.bottom||(r<0?gs))return w.cursor(g,t.assoc,void 0,o)}}function pi(n,t,e){let i=n.state.facet(Hs).map(s=>s(n));for(;;){let s=!1;for(let r of i)r.between(e.from-1,e.from+1,(o,l,h)=>{e.from>o&&e.frome.from?w.cursor(o,1):w.cursor(l,-1),s=!0)});if(!s)return e}}var tn=class{constructor(t){this.lastKeyCode=0,this.lastKeyTime=0,this.chromeScrollHack=-1,this.pendingIOSKey=void 0,this.lastSelectionOrigin=null,this.lastSelectionTime=0,this.lastEscPress=0,this.lastContextMenu=0,this.scrollHandlers=[],this.registeredEvents=[],this.customHandlers=[],this.composing=-1,this.compositionFirstChange=null,this.compositionEndedAt=0,this.rapidCompositionStart=!1,this.mouseSelection=null;for(let e in I){let i=I[e];t.contentDOM.addEventListener(e,s=>{!nn(t,s)||this.ignoreDuringComposition(s)||e=="keydown"&&this.keydown(t,s)||(this.mustFlushObserver(s)&&t.observer.forceFlush(),this.runCustomHandlers(e,t,s)?s.preventDefault():i(t,s))}),this.registeredEvents.push(e)}y.chrome&&y.chrome_version>=102&&t.scrollDOM.addEventListener("wheel",()=>{this.chromeScrollHack<0?t.contentDOM.style.pointerEvents="none":window.clearTimeout(this.chromeScrollHack),this.chromeScrollHack=setTimeout(()=>{this.chromeScrollHack=-1,t.contentDOM.style.pointerEvents=""},100)},{passive:!0}),this.notifiedFocused=t.hasFocus,y.safari&&t.contentDOM.addEventListener("input",()=>null)}setSelectionOrigin(t){this.lastSelectionOrigin=t,this.lastSelectionTime=Date.now()}ensureHandlers(t,e){var i;let s;this.customHandlers=[];for(let r of e)if(s=(i=r.update(t).spec)===null||i===void 0?void 0:i.domEventHandlers){this.customHandlers.push({plugin:r.value,handlers:s});for(let o in s)this.registeredEvents.indexOf(o)<0&&o!="scroll"&&(this.registeredEvents.push(o),t.contentDOM.addEventListener(o,l=>{!nn(t,l)||this.runCustomHandlers(o,t,l)&&l.preventDefault()}))}}runCustomHandlers(t,e,i){for(let s of this.customHandlers){let r=s.handlers[t];if(r)try{if(r.call(s.plugin,i,e)||i.defaultPrevented)return!0}catch(o){pt(e.state,o)}}return!1}runScrollHandlers(t,e){for(let i of this.customHandlers){let s=i.handlers.scroll;if(s)try{s.call(i.plugin,e,t)}catch(r){pt(t.state,r)}}}keydown(t,e){if(this.lastKeyCode=e.keyCode,this.lastKeyTime=Date.now(),e.keyCode==9&&Date.now()s.keyCode==e.keyCode))&&!(e.ctrlKey||e.altKey||e.metaKey)&&!e.synthetic?(this.pendingIOSKey=i,setTimeout(()=>this.flushIOSKey(t),250),!0):!1}flushIOSKey(t){let e=this.pendingIOSKey;return e?(this.pendingIOSKey=void 0,Ft(t.contentDOM,e.key,e.keyCode)):!1}ignoreDuringComposition(t){return/^key/.test(t.type)?this.composing>0?!0:y.safari&&Date.now()-this.compositionEndedAt<100?(this.compositionEndedAt=0,!0):!1:!1}mustFlushObserver(t){return t.type=="keydown"&&t.keyCode!=229||t.type=="compositionend"&&!y.ios}startMouseSelection(t){this.mouseSelection&&this.mouseSelection.destroy(),this.mouseSelection=t}update(t){this.mouseSelection&&this.mouseSelection.update(t),t.transactions.length&&(this.lastKeyCode=this.lastSelectionTime=0)}destroy(){this.mouseSelection&&this.mouseSelection.destroy()}},en=[{key:"Backspace",keyCode:8,inputType:"deleteContentBackward"},{key:"Enter",keyCode:13,inputType:"insertParagraph"},{key:"Delete",keyCode:46,inputType:"deleteContentForward"}],Ir=[16,17,18,20,91,92,224,225],sn=class{constructor(t,e,i,s){this.view=t,this.style=i,this.mustSelect=s,this.lastEvent=e;let r=t.contentDOM.ownerDocument;r.addEventListener("mousemove",this.move=this.move.bind(this)),r.addEventListener("mouseup",this.up=this.up.bind(this)),this.extend=e.shiftKey,this.multiple=t.state.facet(S.allowMultipleSelections)&&Hr(t,e),this.dragMove=Fr(t,e),this.dragging=Wr(t,e)&&gi(e)==1?null:!1,this.dragging===!1&&(e.preventDefault(),this.select(e))}move(t){if(t.buttons==0)return this.destroy();this.dragging===!1&&this.select(this.lastEvent=t)}up(t){this.dragging==null&&this.select(this.lastEvent),this.dragging||t.preventDefault(),this.destroy()}destroy(){let t=this.view.contentDOM.ownerDocument;t.removeEventListener("mousemove",this.move),t.removeEventListener("mouseup",this.up),this.view.inputState.mouseSelection=null}select(t){let e=this.style.get(t,this.extend,this.multiple);(this.mustSelect||!e.eq(this.view.state.selection)||e.main.assoc!=this.view.state.selection.main.assoc)&&this.view.dispatch({selection:e,userEvent:"select.pointer",scrollIntoView:!0}),this.mustSelect=!1}update(t){t.docChanged&&this.dragging&&(this.dragging=this.dragging.map(t.changes)),this.style.update(t)&&setTimeout(()=>this.select(this.lastEvent),20)}};function Hr(n,t){let e=n.state.facet(Ts);return e.length?e[0](t):y.mac?t.metaKey:t.ctrlKey}function Fr(n,t){let e=n.state.facet(Rs);return e.length?e[0](t):y.mac?!t.altKey:!t.ctrlKey}function Wr(n,t){let{main:e}=n.state.selection;if(e.empty)return!1;let i=he(n.root);if(!i||i.rangeCount==0)return!0;let s=i.getRangeAt(0).getClientRects();for(let r=0;r=t.clientX&&o.top<=t.clientY&&o.bottom>=t.clientY)return!0}return!1}function nn(n,t){if(!t.bubbles)return!0;if(t.defaultPrevented)return!1;for(let e=t.target,i;e!=n.contentDOM;e=e.parentNode)if(!e||e.nodeType==11||(i=k.get(e))&&i.ignoreEvent(t))return!1;return!0}var I=Object.create(null),rn=y.ie&&y.ie_version<15||y.ios&&y.webkit_version<604;function zr(n){let t=n.dom.parentNode;if(!t)return;let e=t.appendChild(document.createElement("textarea"));e.style.cssText="position: fixed; left: -10000px; top: 10px",e.focus(),setTimeout(()=>{n.focus(),e.remove(),on(n,e.value)},50)}function on(n,t){let{state:e}=n,i,s=1,r=e.toText(t),o=r.lines==e.selection.ranges.length;if(mi!=null&&e.selection.ranges.every(h=>h.empty)&&mi==r.toString()){let h=-1;i=e.changeByRange(a=>{let c=e.doc.lineAt(a.from);if(c.from==h)return{range:a};h=c.from;let f=e.toText((o?r.line(s++).text:t)+e.lineBreak);return{changes:{from:c.from,insert:f},range:w.cursor(a.from+f.length)}})}else o?i=e.changeByRange(h=>{let a=r.line(s++);return{changes:{from:h.from,to:h.to,insert:a.text},range:w.cursor(h.from+a.length)}}):i=e.replaceSelection(r);n.dispatch(i,{userEvent:"input.paste",scrollIntoView:!0})}I.keydown=(n,t)=>{n.inputState.setSelectionOrigin("select"),t.keyCode==27?n.inputState.lastEscPress=Date.now():Ir.indexOf(t.keyCode)<0&&(n.inputState.lastEscPress=0)};var ln=0;I.touchstart=(n,t)=>{ln=Date.now(),n.inputState.setSelectionOrigin("select.pointer")};I.touchmove=n=>{n.inputState.setSelectionOrigin("select.pointer")};I.mousedown=(n,t)=>{if(n.observer.flush(),ln>Date.now()-2e3&&gi(t)==1)return;let e=null;for(let i of n.state.facet(Es))if(e=i(n,t),e)break;if(!e&&t.button==0&&(e=$r(n,t)),e){let i=n.root.activeElement!=n.contentDOM;i&&n.observer.ignore(()=>ds(n.contentDOM)),n.inputState.startMouseSelection(new sn(n,t,e,i))}};function hn(n,t,e,i){if(i==1)return w.cursor(t,e);if(i==2)return Tr(n.state,t,e);{let s=W.find(n.docView,t),r=n.state.doc.lineAt(s?s.posAtEnd:t),o=s?s.posAtStart:r.from,l=s?s.posAtEnd:r.to;return ln>=t.top&&n<=t.bottom,cn=(n,t,e)=>an(t,e)&&n>=e.left&&n<=e.right;function qr(n,t,e,i){let s=W.find(n.docView,t);if(!s)return 1;let r=t-s.posAtStart;if(r==0)return 1;if(r==s.length)return-1;let o=s.coordsAt(r,-1);if(o&&cn(e,i,o))return-1;let l=s.coordsAt(r,1);return l&&cn(e,i,l)?1:o&&an(i,o)?-1:1}function fn(n,t){let e=n.posAtCoords({x:t.clientX,y:t.clientY},!1);return{pos:e,bias:qr(n,e,t.clientX,t.clientY)}}var Kr=y.ie&&y.ie_version<=11,un=null,dn=0,pn=0;function gi(n){if(!Kr)return n.detail;let t=un,e=pn;return un=n,pn=Date.now(),dn=!t||e>Date.now()-400&&Math.abs(t.clientX-n.clientX)<2&&Math.abs(t.clientY-n.clientY)<2?(dn+1)%3:1}function $r(n,t){let e=fn(n,t),i=gi(t),s=n.state.selection,r=e,o=t;return{update(l){l.docChanged&&(e&&(e.pos=l.changes.mapPos(e.pos)),s=s.map(l.changes),o=null)},get(l,h,a){let c;if(o&&l.clientX==o.clientX&&l.clientY==o.clientY?c=r:(c=r=fn(n,l),o=l),!c||!e)return s;let f=hn(n,c.pos,c.bias,i);if(e.pos!=c.pos&&!h){let d=hn(n,e.pos,e.bias,i),u=Math.min(d.from,f.from),p=Math.max(d.to,f.to);f=u1&&s.ranges.some(d=>d.eq(f))?jr(s,f):a?s.addRange(f):w.create([f])}}}function jr(n,t){for(let e=0;;e++)if(n.ranges[e].eq(t))return w.create(n.ranges.slice(0,e).concat(n.ranges.slice(e+1)),n.mainIndex==e?0:n.mainIndex-(n.mainIndex>e?1:0))}I.dragstart=(n,t)=>{let{selection:{main:e}}=n.state,{mouseSelection:i}=n.inputState;i&&(i.dragging=e),t.dataTransfer&&(t.dataTransfer.setData("Text",n.state.sliceDoc(e.from,e.to)),t.dataTransfer.effectAllowed="copyMove")};function gn(n,t,e,i){if(!e)return;let s=n.posAtCoords({x:t.clientX,y:t.clientY},!1);t.preventDefault();let{mouseSelection:r}=n.inputState,o=i&&r&&r.dragging&&r.dragMove?{from:r.dragging.from,to:r.dragging.to}:null,l={from:s,insert:e},h=n.state.changes(o?[o,l]:l);n.focus(),n.dispatch({changes:h,selection:{anchor:h.mapPos(s,-1),head:h.mapPos(s,1)},userEvent:o?"move.drop":"input.drop"})}I.drop=(n,t)=>{if(!t.dataTransfer)return;if(n.state.readOnly)return t.preventDefault();let e=t.dataTransfer.files;if(e&&e.length){t.preventDefault();let i=Array(e.length),s=0,r=()=>{++s==e.length&&gn(n,t,i.filter(o=>o!=null).join(n.state.lineBreak),!1)};for(let o=0;o{/[\x00-\x08\x0e-\x1f]{2}/.test(l.result)||(i[o]=l.result),r()},l.readAsText(e[o])}}else gn(n,t,t.dataTransfer.getData("Text"),!0)};I.paste=(n,t)=>{if(n.state.readOnly)return t.preventDefault();n.observer.flush();let e=rn?null:t.clipboardData;e?(on(n,e.getData("text/plain")),t.preventDefault()):zr(n)};function Gr(n,t){let e=n.dom.parentNode;if(!e)return;let i=e.appendChild(document.createElement("textarea"));i.style.cssText="position: fixed; left: -10000px; top: 10px",i.value=t,i.focus(),i.selectionEnd=t.length,i.selectionStart=0,setTimeout(()=>{i.remove(),n.focus()},50)}function Ur(n){let t=[],e=[],i=!1;for(let s of n.selection.ranges)s.empty||(t.push(n.sliceDoc(s.from,s.to)),e.push(s));if(!t.length){let s=-1;for(let{from:r}of n.selection.ranges){let o=n.doc.lineAt(r);o.number>s&&(t.push(o.text),e.push({from:o.from,to:Math.min(n.doc.length,o.to+1)})),s=o.number}i=!0}return{text:t.join(n.lineBreak),ranges:e,linewise:i}}var mi=null;I.copy=I.cut=(n,t)=>{let{text:e,ranges:i,linewise:s}=Ur(n.state);if(!e&&!s)return;mi=s?e:null;let r=rn?null:t.clipboardData;r?(t.preventDefault(),r.clearData(),r.setData("text/plain",e)):Gr(n,e),t.type=="cut"&&!n.state.readOnly&&n.dispatch({changes:i,scrollIntoView:!0,userEvent:"delete.cut"})};function mn(n){setTimeout(()=>{n.hasFocus!=n.inputState.notifiedFocused&&n.update([])},10)}I.focus=mn;I.blur=n=>{n.observer.clearSelectionRange(),mn(n)};function yn(n,t){if(n.docView.compositionDeco.size){n.inputState.rapidCompositionStart=t;try{n.update([])}finally{n.inputState.rapidCompositionStart=!1}}}I.compositionstart=I.compositionupdate=n=>{n.inputState.compositionFirstChange==null&&(n.inputState.compositionFirstChange=!0),n.inputState.composing<0&&(n.inputState.composing=0,n.docView.compositionDeco.size&&(n.observer.flush(),yn(n,!0)))};I.compositionend=n=>{n.inputState.composing=-1,n.inputState.compositionEndedAt=Date.now(),n.inputState.compositionFirstChange=null,setTimeout(()=>{n.inputState.composing<0&&yn(n,!1)},50)};I.contextmenu=n=>{n.inputState.lastContextMenu=Date.now()};I.beforeinput=(n,t)=>{var e;let i;if(y.chrome&&y.android&&(i=en.find(s=>s.inputType==t.inputType))&&(n.observer.delayAndroidKey(i.key,i.keyCode),i.key=="Backspace"||i.key=="Delete")){let s=((e=window.visualViewport)===null||e===void 0?void 0:e.height)||0;setTimeout(()=>{var r;(((r=window.visualViewport)===null||r===void 0?void 0:r.height)||0)>s+10&&n.hasFocus&&(n.contentDOM.blur(),n.focus())},100)}};var wn=["pre-wrap","normal","pre-line","break-spaces"],bn=class{constructor(){this.doc=x.empty,this.lineWrapping=!1,this.heightSamples={},this.lineHeight=14,this.charWidth=7,this.lineLength=30,this.heightChanged=!1}heightForGap(t,e){let i=this.doc.lineAt(e).number-this.doc.lineAt(t).number+1;return this.lineWrapping&&(i+=Math.ceil((e-t-i*this.lineLength*.5)/this.lineLength)),this.lineHeight*i}heightForLine(t){return this.lineWrapping?(1+Math.max(0,Math.ceil((t-this.lineLength)/(this.lineLength-5))))*this.lineHeight:this.lineHeight}setDoc(t){return this.doc=t,this}mustRefreshForWrapping(t){return wn.indexOf(t)>-1!=this.lineWrapping}mustRefreshForHeights(t){let e=!1;for(let i=0;i-1,l=Math.round(e)!=Math.round(this.lineHeight)||this.lineWrapping!=o;if(this.lineWrapping=o,this.lineHeight=e,this.charWidth=i,this.lineLength=s,l){this.heightSamples={};for(let h=0;h0}set outdated(t){this.flags=(t?2:0)|this.flags&~2}setHeight(t,e){this.height!=e&&(Math.abs(this.height-e)>ye&&(t.heightChanged=!0),this.height=e)}replace(t,e,i){return q.of(i)}decomposeLeft(t,e){e.push(this)}decomposeRight(t,e){e.push(this)}applyChanges(t,e,i,s){let r=this;for(let o=s.length-1;o>=0;o--){let{fromA:l,toA:h,fromB:a,toB:c}=s[o],f=r.lineAt(l,C.ByPosNoHeight,e,0,0),d=f.to>=h?f:r.lineAt(h,C.ByPosNoHeight,e,0,0);for(c+=d.to-h,h=d.to;o>0&&f.from<=s[o-1].toA;)l=s[o-1].fromA,a=s[o-1].fromB,o--,lr*2){let l=t[e-1];l.break?t.splice(--e,1,l.left,null,l.right):t.splice(--e,1,l.left,l.right),i+=1+l.break,s-=l.size}else if(r>s*2){let l=t[i];l.break?t.splice(i,1,l.left,null,l.right):t.splice(i,1,l.left,l.right),i+=2+l.break,r-=l.size}else break;else if(s=r&&o(this.blockAt(0,i,s,r))}updateHeight(t,e=0,i=!1,s){return s&&s.from<=e&&s.more&&this.setHeight(t,s.heights[s.index++]),this.outdated=!1,this}toString(){return`block(${this.length})`}},$=class extends yi{constructor(t,e){super(t,e,L.Text);this.collapsed=0,this.widgetHeight=0}replace(t,e,i){let s=i[0];return i.length==1&&(s instanceof $||s instanceof H&&s.flags&4)&&Math.abs(this.length-s.length)<10?(s instanceof H?s=new $(s.length,this.height):s.height=this.height,this.outdated||(s.outdated=!1),s):q.of(i)}updateHeight(t,e=0,i=!1,s){return s&&s.from<=e&&s.more?this.setHeight(t,s.heights[s.index++]):(i||this.outdated)&&this.setHeight(t,Math.max(this.widgetHeight,t.heightForLine(this.length-this.collapsed))),this.outdated=!1,this}toString(){return`line(${this.length}${this.collapsed?-this.collapsed:""}${this.widgetHeight?":"+this.widgetHeight:""})`}},H=class extends q{constructor(t){super(t,0)}lines(t,e){let i=t.lineAt(e).number,s=t.lineAt(e+this.length).number;return{firstLine:i,lastLine:s,lineHeight:this.height/(s-i+1)}}blockAt(t,e,i,s){let{firstLine:r,lastLine:o,lineHeight:l}=this.lines(e,s),h=Math.max(0,Math.min(o-r,Math.floor((t-i)/l))),{from:a,length:c}=e.line(r+h);return new et(a,c,i+l*h,l,L.Text)}lineAt(t,e,i,s,r){if(e==C.ByHeight)return this.blockAt(t,i,s,r);if(e==C.ByPosNoHeight){let{from:f,to:d}=i.lineAt(t);return new et(f,d-f,0,0,L.Text)}let{firstLine:o,lineHeight:l}=this.lines(i,r),{from:h,length:a,number:c}=i.lineAt(t);return new et(h,a,s+l*(c-o),l,L.Text)}forEachLine(t,e,i,s,r,o){let{firstLine:l,lineHeight:h}=this.lines(i,r);for(let a=Math.max(t,r),c=Math.min(r+this.length,e);a<=c;){let f=i.lineAt(a);a==t&&(s+=h*(f.number-l)),o(new et(f.from,f.length,s,h,L.Text)),s+=h,a=f.to+1}}replace(t,e,i){let s=this.length-e;if(s>0){let r=i[i.length-1];r instanceof H?i[i.length-1]=new H(r.length+s):i.push(null,new H(s-1))}if(t>0){let r=i[0];r instanceof H?i[0]=new H(t+r.length):i.unshift(new H(t-1),null)}return q.of(i)}decomposeLeft(t,e){e.push(new H(t-1),null)}decomposeRight(t,e){e.push(null,new H(this.length-t-1))}updateHeight(t,e=0,i=!1,s){let r=e+this.length;if(s&&s.from<=e+this.length&&s.more){let o=[],l=Math.max(e,s.from),h=-1,a=t.heightChanged;for(s.from>e&&o.push(new H(s.from-e-1).updateHeight(t,e));l<=r&&s.more;){let f=t.doc.lineAt(l).length;o.length&&o.push(null);let d=s.heights[s.index++];h==-1?h=d:Math.abs(d-h)>=ye&&(h=-2);let u=new $(f,d);u.outdated=!1,o.push(u),l+=f+1}l<=r&&o.push(null,new H(r-l).updateHeight(t,l));let c=q.of(o);return t.heightChanged=a||h<0||Math.abs(c.height-this.height)>=ye||Math.abs(h-this.lines(t.doc,e).lineHeight)>=ye,c}else(i||this.outdated)&&(this.setHeight(t,t.heightForGap(e,e+this.length)),this.outdated=!1);return this}toString(){return`gap(${this.length})`}},xn=class extends q{constructor(t,e,i){super(t.length+e+i.length,t.height+i.height,e|(t.outdated||i.outdated?2:0));this.left=t,this.right=i,this.size=t.size+i.size}get break(){return this.flags&1}blockAt(t,e,i,s){let r=i+this.left.height;return tl))return a;let c=e==C.ByPosNoHeight?C.ByPosNoHeight:C.ByPos;return h?a.join(this.right.lineAt(l,c,i,o,l)):this.left.lineAt(l,c,i,s,r).join(a)}forEachLine(t,e,i,s,r,o){let l=s+this.left.height,h=r+this.left.length+this.break;if(this.break)t=h&&this.right.forEachLine(t,e,i,l,h,o);else{let a=this.lineAt(h,C.ByPos,i,s,r);t=t&&a.from<=e&&o(a),e>a.to&&this.right.forEachLine(a.to+1,e,i,l,h,o)}}replace(t,e,i){let s=this.left.length+this.break;if(ethis.left.length)return this.balanced(this.left,this.right.replace(t-s,e-s,i));let r=[];t>0&&this.decomposeLeft(t,r);let o=r.length;for(let l of i)r.push(l);if(t>0&&Sn(r,o-1),e=i&&e.push(null)),t>i&&this.right.decomposeLeft(t-i,e)}decomposeRight(t,e){let i=this.left.length,s=i+this.break;if(t>=s)return this.right.decomposeRight(t-s,e);t2*e.size||e.size>2*t.size?q.of(this.break?[t,null,e]:[t,e]):(this.left=t,this.right=e,this.height=t.height+e.height,this.outdated=t.outdated||e.outdated,this.size=t.size+e.size,this.length=t.length+this.break+e.length,this)}updateHeight(t,e=0,i=!1,s){let{left:r,right:o}=this,l=e+r.length+this.break,h=null;return s&&s.from<=e+r.length&&s.more?h=r=r.updateHeight(t,e,i,s):r.updateHeight(t,e,i),s&&s.from<=l+o.length&&s.more?h=o=o.updateHeight(t,l,i,s):o.updateHeight(t,l,i),h?this.balanced(r,o):(this.height=this.left.height+this.right.height,this.outdated=!1,this)}toString(){return this.left+(this.break?" ":"-")+this.right}};function Sn(n,t){let e,i;n[t]==null&&(e=n[t-1])instanceof H&&(i=n[t+1])instanceof H&&n.splice(t-1,3,new H(e.length+1+i.length))}var Jr=5,we=class{constructor(t,e){this.pos=t,this.oracle=e,this.nodes=[],this.lineStart=-1,this.lineEnd=-1,this.covering=null,this.writtenTo=t}get isCovered(){return this.covering&&this.nodes[this.nodes.length-1]==this.covering}span(t,e){if(this.lineStart>-1){let i=Math.min(e,this.lineEnd),s=this.nodes[this.nodes.length-1];s instanceof $?s.length+=i-this.pos:(i>this.pos||!this.isCovered)&&this.nodes.push(new $(i-this.pos,-1)),this.writtenTo=i,e>i&&(this.nodes.push(null),this.writtenTo++,this.lineStart=-1)}this.pos=e}point(t,e,i){if(t=Jr)&&this.addLineDeco(s,r)}else e>t&&this.span(t,e);this.lineEnd>-1&&this.lineEnd-1)return;let{from:t,to:e}=this.oracle.doc.lineAt(this.pos);this.lineStart=t,this.lineEnd=e,this.writtenTot&&this.nodes.push(new $(this.pos-t,-1)),this.writtenTo=this.pos}blankContent(t,e){let i=new H(e-t);return this.oracle.doc.lineAt(t).to==e&&(i.flags|=4),i}ensureLine(){this.enterLine();let t=this.nodes.length?this.nodes[this.nodes.length-1]:null;if(t instanceof $)return t;let e=new $(0,-1);return this.nodes.push(e),e}addBlock(t){this.enterLine(),t.type==L.WidgetAfter&&!this.isCovered&&this.ensureLine(),this.nodes.push(t),this.writtenTo=this.pos=this.pos+t.length,t.type!=L.WidgetBefore&&(this.covering=t)}addLineDeco(t,e){let i=this.ensureLine();i.length+=e,i.collapsed+=e,i.widgetHeight=Math.max(i.widgetHeight,t),this.writtenTo=this.pos=this.pos+e}finish(t){let e=this.nodes.length==0?null:this.nodes[this.nodes.length-1];this.lineStart>-1&&!(e instanceof $)&&!this.isCovered?this.nodes.push(new $(0,-1)):(this.writtenToa.clientHeight||a.scrollWidth>a.clientWidth)&&c.overflow!="visible"){let f=a.getBoundingClientRect();i=Math.max(i,f.left),s=Math.min(s,f.right),r=Math.max(r,f.top),o=Math.min(o,f.bottom)}h=c.position=="absolute"||c.position=="fixed"?a.offsetParent:a.parentNode}else if(h.nodeType==11)h=h.host;else break;return{left:i-e.left,right:Math.max(i,s)-e.left,top:r-(e.top+t),bottom:Math.max(r,o)-(e.top+t)}}function Zr(n,t){let e=n.getBoundingClientRect();return{left:0,right:e.right-e.left,top:t,bottom:e.bottom-(e.top+t)}}var be=class{constructor(t,e,i){this.from=t,this.to=e,this.size=i}static same(t,e){if(t.length!=e.length)return!1;for(let i=0;itypeof e!="function"),this.heightMap=q.empty().applyChanges(this.stateDeco,x.empty,this.heightOracle.setDoc(t.doc),[new Y(0,0,0,t.doc.length)]),this.viewport=this.getViewport(0,null),this.updateViewportLines(),this.updateForViewport(),this.lineGaps=this.ensureLineGaps([]),this.lineGapDeco=N.set(this.lineGaps.map(e=>e.draw(!1))),this.computeVisibleRanges()}updateForViewport(){let t=[this.viewport],{main:e}=this.state.selection;for(let i=0;i<=1;i++){let s=i?e.head:e.anchor;if(!t.some(({from:r,to:o})=>s>=r&&s<=o)){let{from:r,to:o}=this.lineBlockAt(s);t.push(new Jt(r,o))}}this.viewports=t.sort((i,s)=>i.from-s.from),this.scaler=this.heightMap.height<=7e6?Dn:new On(this.heightOracle.doc,this.heightMap,this.viewports)}updateViewportLines(){this.viewportLines=[],this.heightMap.forEachLine(this.viewport.from,this.viewport.to,this.state.doc,0,0,t=>{this.viewportLines.push(this.scaler.scale==1?t:Xt(t,this.scaler))})}update(t,e=null){this.state=t.state;let i=this.stateDeco;this.stateDeco=this.state.facet(jt).filter(a=>typeof a!="function");let s=t.changedRanges,r=Y.extendWithRanges(s,Xr(i,this.stateDeco,t?t.changes:T.empty(this.state.doc.length))),o=this.heightMap.height;this.heightMap=this.heightMap.applyChanges(this.stateDeco,t.startState.doc,this.heightOracle.setDoc(this.state.doc),r),this.heightMap.height!=o&&(t.flags|=2);let l=r.length?this.mapViewport(this.viewport,t.changes):this.viewport;(e&&(e.range.headl.to)||!this.viewportIsAppropriate(l))&&(l=this.getViewport(0,e));let h=!t.changes.empty||t.flags&2||l.from!=this.viewport.from||l.to!=this.viewport.to;this.viewport=l,this.updateForViewport(),h&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(this.mapLineGaps(this.lineGaps,t.changes))),t.flags|=this.computeVisibleRanges(),e&&(this.scrollTarget=e),!this.mustEnforceCursorAssoc&&t.selectionSet&&t.view.lineWrapping&&t.state.selection.main.empty&&t.state.selection.main.assoc&&(this.mustEnforceCursorAssoc=!0)}measure(t){let e=t.contentDOM,i=window.getComputedStyle(e),s=this.heightOracle,r=i.whiteSpace;this.defaultTextDirection=i.direction=="rtl"?z.RTL:z.LTR;let o=this.heightOracle.mustRefreshForWrapping(r),l=o||this.mustMeasureContent||this.contentDOMHeight!=e.clientHeight;this.contentDOMHeight=e.clientHeight,this.mustMeasureContent=!1;let h=0,a=0,c=parseInt(i.paddingTop)||0,f=parseInt(i.paddingBottom)||0;(this.paddingTop!=c||this.paddingBottom!=f)&&(this.paddingTop=c,this.paddingBottom=f,h|=8|2),this.editorWidth!=t.scrollDOM.clientWidth&&(s.lineWrapping&&(l=!0),this.editorWidth=t.scrollDOM.clientWidth,h|=8);let d=(this.printing?Zr:Yr)(e,this.paddingTop),u=d.top-this.pixelViewport.top,p=d.bottom-this.pixelViewport.bottom;this.pixelViewport=d;let g=this.pixelViewport.bottom>this.pixelViewport.top&&this.pixelViewport.right>this.pixelViewport.left;if(g!=this.inView&&(this.inView=g,g&&(l=!0)),!this.inView)return 0;let m=e.clientWidth;if((this.contentDOMWidth!=m||this.editorHeight!=t.scrollDOM.clientHeight)&&(this.contentDOMWidth=m,this.editorHeight=t.scrollDOM.clientHeight,h|=8),l){let B=t.docView.measureVisibleLineHeights(this.viewport);if(s.mustRefreshForHeights(B)&&(o=!0),o||s.lineWrapping&&Math.abs(m-this.contentDOMWidth)>s.charWidth){let{lineHeight:it,charWidth:ft}=t.docView.measureTextSize();o=s.refresh(r,it,ft,m/ft,B),o&&(t.docView.minWidth=0,h|=8)}u>0&&p>0?a=Math.max(u,p):u<0&&p<0&&(a=Math.min(u,p)),s.heightChanged=!1;for(let it of this.viewports){let ft=it.from==this.viewport.from?B:t.docView.measureVisibleLineHeights(it);this.heightMap=this.heightMap.updateHeight(s,0,o,new vn(it.from,ft))}s.heightChanged&&(h|=2)}let b=!this.viewportIsAppropriate(this.viewport,a)||this.scrollTarget&&(this.scrollTarget.range.headthis.viewport.to);return b&&(this.viewport=this.getViewport(a,this.scrollTarget)),this.updateForViewport(),(h&2||b)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(o?[]:this.lineGaps)),h|=this.computeVisibleRanges(),this.mustEnforceCursorAssoc&&(this.mustEnforceCursorAssoc=!1,t.docView.enforceCursorAssoc()),h}get visibleTop(){return this.scaler.fromDOM(this.pixelViewport.top)}get visibleBottom(){return this.scaler.fromDOM(this.pixelViewport.bottom)}getViewport(t,e){let i=.5-Math.max(-.5,Math.min(.5,t/1e3/2)),s=this.heightMap,r=this.state.doc,{visibleTop:o,visibleBottom:l}=this,h=new Jt(s.lineAt(o-i*1e3,C.ByHeight,r,0,0).from,s.lineAt(l+(1-i)*1e3,C.ByHeight,r,0,0).to);if(e){let{head:a}=e.range;if(ah.to){let c=Math.min(this.editorHeight,this.pixelViewport.bottom-this.pixelViewport.top),f=s.lineAt(a,C.ByPos,r,0,0),d;e.y=="center"?d=(f.top+f.bottom)/2-c/2:e.y=="start"||e.y=="nearest"&&a=l+Math.max(10,Math.min(i,250)))&&s>o-2*1e3&&ri.from&&l.push({from:i.from,to:r}),o=i.from&&h.from<=i.to&&Mn(l,h.from-10,h.from+10),!h.empty&&h.to>=i.from&&h.to<=i.to&&Mn(l,h.to-10,h.to+10);for(let{from:a,to:c}of l)c-a>1e3&&e.push(_r(t,f=>f.from>=i.from&&f.to<=i.to&&Math.abs(f.from-a)<1e3&&Math.abs(f.to-c)<1e3)||new be(a,c,this.gapSize(i,a,c,s)))}return e}gapSize(t,e,i,s){let r=An(s,i)-An(s,e);return this.heightOracle.lineWrapping?t.height*r:s.total*this.heightOracle.charWidth*r}updateLineGaps(t){be.same(t,this.lineGaps)||(this.lineGaps=t,this.lineGapDeco=N.set(t.map(e=>e.draw(this.heightOracle.lineWrapping))))}computeVisibleRanges(){let t=this.stateDeco;this.lineGaps.length&&(t=t.concat(this.lineGapDeco));let e=[];O.spans(t,this.viewport.from,this.viewport.to,{span(s,r){e.push({from:s,to:r})},point(){}},20);let i=e.length!=this.visibleRanges.length||this.visibleRanges.some((s,r)=>s.from!=e[r].from||s.to!=e[r].to);return this.visibleRanges=e,i?4:0}lineBlockAt(t){return t>=this.viewport.from&&t<=this.viewport.to&&this.viewportLines.find(e=>e.from<=t&&e.to>=t)||Xt(this.heightMap.lineAt(t,C.ByPos,this.state.doc,0,0),this.scaler)}lineBlockAtHeight(t){return Xt(this.heightMap.lineAt(this.scaler.fromDOM(t),C.ByHeight,this.state.doc,0,0),this.scaler)}elementAtHeight(t){return Xt(this.heightMap.blockAt(this.scaler.fromDOM(t),this.state.doc,0,0),this.scaler)}get docHeight(){return this.scaler.toDOM(this.heightMap.height)}get contentHeight(){return this.docHeight+this.paddingTop+this.paddingBottom}},Jt=class{constructor(t,e){this.from=t,this.to=e}};function Qr(n,t,e){let i=[],s=n,r=0;return O.spans(e,n,t,{span(){},point(o,l){o>s&&(i.push({from:s,to:o}),r+=o-s),s=l}},20),s=1)return t[t.length-1].to;let i=Math.floor(n*e);for(let s=0;;s++){let{from:r,to:o}=t[s],l=o-r;if(i<=l)return r+i;i-=l}}function An(n,t){let e=0;for(let{from:i,to:s}of n.ranges){if(t<=s){e+=t-i;break}e+=s-i}return e/n.total}function Mn(n,t,e){for(let i=0;it){let r=[];s.frome&&r.push({from:e,to:s.to}),n.splice(i,1,...r),i+=r.length-1}}}function _r(n,t){for(let e of n)if(t(e))return e}var Dn={toDOM(n){return n},fromDOM(n){return n},scale:1},On=class{constructor(t,e,i){let s=0,r=0,o=0;this.viewports=i.map(({from:l,to:h})=>{let a=e.lineAt(l,C.ByPos,t,0,0).top,c=e.lineAt(h,C.ByPos,t,0,0).bottom;return s+=c-a,{from:l,to:h,top:a,bottom:c,domTop:0,domBottom:0}}),this.scale=(7e6-s)/(e.height-s);for(let l of this.viewports)l.domTop=o+(l.top-r)*this.scale,o=l.domBottom=l.domTop+(l.bottom-l.top),r=l.bottom}toDOM(t){for(let e=0,i=0,s=0;;e++){let r=eXt(s,t)):n.type)}var xe=v.define({combine:n=>n.join(" ")}),bi=v.define({combine:n=>n.indexOf(!0)>-1}),vi=lt.newName(),Tn=lt.newName(),Rn=lt.newName(),En={"&light":"."+Tn,"&dark":"."+Rn};function xi(n,t,e){return new lt(t,{finish(i){return/&/.test(i)?i.replace(/&\w*/,s=>{if(s=="&")return n;if(!e||!e[s])throw new RangeError(`Unsupported selector: ${s}`);return e[s]}):n+" "+i}})}var to=xi("."+vi,{"&.cm-editor":{position:"relative !important",boxSizing:"border-box","&.cm-focused":{outline:"1px dotted #212121"},display:"flex !important",flexDirection:"column"},".cm-scroller":{display:"flex !important",alignItems:"flex-start !important",fontFamily:"monospace",lineHeight:1.4,height:"100%",overflowX:"auto",position:"relative",zIndex:0},".cm-content":{margin:0,flexGrow:2,flexShrink:0,minHeight:"100%",display:"block",whiteSpace:"pre",wordWrap:"normal",boxSizing:"border-box",padding:"4px 0",outline:"none","&[contenteditable=true]":{WebkitUserModify:"read-write-plaintext-only"}},".cm-lineWrapping":{whiteSpace_fallback:"pre-wrap",whiteSpace:"break-spaces",wordBreak:"break-word",overflowWrap:"anywhere",flexShrink:1},"&light .cm-content":{caretColor:"black"},"&dark .cm-content":{caretColor:"white"},".cm-line":{display:"block",padding:"0 2px 0 4px"},".cm-selectionLayer":{zIndex:-1,contain:"size style"},".cm-selectionBackground":{position:"absolute"},"&light .cm-selectionBackground":{background:"#d9d9d9"},"&dark .cm-selectionBackground":{background:"#222"},"&light.cm-focused .cm-selectionBackground":{background:"#d7d4f0"},"&dark.cm-focused .cm-selectionBackground":{background:"#233"},".cm-cursorLayer":{zIndex:100,contain:"size style",pointerEvents:"none"},"&.cm-focused .cm-cursorLayer":{animation:"steps(1) cm-blink 1.2s infinite"},"@keyframes cm-blink":{"0%":{},"50%":{opacity:0},"100%":{}},"@keyframes cm-blink2":{"0%":{},"50%":{opacity:0},"100%":{}},".cm-cursor, .cm-dropCursor":{position:"absolute",borderLeft:"1.2px solid black",marginLeft:"-0.6px",pointerEvents:"none"},".cm-cursor":{display:"none"},"&dark .cm-cursor":{borderLeftColor:"#444"},"&.cm-focused .cm-cursor":{display:"block"},"&light .cm-activeLine":{backgroundColor:"#f3f9ff"},"&dark .cm-activeLine":{backgroundColor:"#223039"},"&light .cm-specialChar":{color:"red"},"&dark .cm-specialChar":{color:"#f78"},".cm-gutters":{display:"flex",height:"100%",boxSizing:"border-box",left:0,zIndex:200},"&light .cm-gutters":{backgroundColor:"#f5f5f5",color:"#6c6c6c",borderRight:"1px solid #ddd"},"&dark .cm-gutters":{backgroundColor:"#333338",color:"#ccc"},".cm-gutter":{display:"flex !important",flexDirection:"column",flexShrink:0,boxSizing:"border-box",minHeight:"100%",overflow:"hidden"},".cm-gutterElement":{boxSizing:"border-box"},".cm-lineNumbers .cm-gutterElement":{padding:"0 3px 0 5px",minWidth:"20px",textAlign:"right",whiteSpace:"nowrap"},"&light .cm-activeLineGutter":{backgroundColor:"#e2f2ff"},"&dark .cm-activeLineGutter":{backgroundColor:"#222227"},".cm-panels":{boxSizing:"border-box",position:"sticky",left:0,right:0},"&light .cm-panels":{backgroundColor:"#f5f5f5",color:"black"},"&light .cm-panels-top":{borderBottom:"1px solid #ddd"},"&light .cm-panels-bottom":{borderTop:"1px solid #ddd"},"&dark .cm-panels":{backgroundColor:"#333338",color:"white"},".cm-tab":{display:"inline-block",overflow:"hidden",verticalAlign:"bottom"},".cm-widgetBuffer":{verticalAlign:"text-top",height:"1em",display:"inline"},".cm-placeholder":{color:"#888",display:"inline-block",verticalAlign:"top"},".cm-button":{verticalAlign:"middle",color:"inherit",fontSize:"70%",padding:".2em 1em",borderRadius:"1px"},"&light .cm-button":{backgroundImage:"linear-gradient(#eff1f5, #d9d9df)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#b4b4b4, #d0d3d6)"}},"&dark .cm-button":{backgroundImage:"linear-gradient(#393939, #111)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#111, #333)"}},".cm-textfield":{verticalAlign:"middle",color:"inherit",fontSize:"70%",border:"1px solid silver",padding:".2em .5em"},"&light .cm-textfield":{backgroundColor:"white"},"&dark .cm-textfield":{border:"1px solid #555",backgroundColor:"inherit"}},En),eo={childList:!0,characterData:!0,subtree:!0,attributes:!0,characterDataOldValue:!0},Si=y.ie&&y.ie_version<=11,Ln=class{constructor(t,e,i){this.view=t,this.onChange=e,this.onScrollChanged=i,this.active=!1,this.selectionRange=new us,this.selectionChanged=!1,this.delayedFlush=-1,this.resizeTimeout=-1,this.queue=[],this.delayedAndroidKey=null,this.scrollTargets=[],this.intersection=null,this.resize=null,this.intersecting=!1,this.gapIntersection=null,this.gaps=[],this.parentCheck=-1,this.dom=t.contentDOM,this.observer=new MutationObserver(s=>{for(let r of s)this.queue.push(r);(y.ie&&y.ie_version<=11||y.ios&&t.composing)&&s.some(r=>r.type=="childList"&&r.removedNodes.length||r.type=="characterData"&&r.oldValue.length>r.target.nodeValue.length)?this.flushSoon():this.flush()}),Si&&(this.onCharData=s=>{this.queue.push({target:s.target,type:"characterData",oldValue:s.prevValue}),this.flushSoon()}),this.onSelectionChange=this.onSelectionChange.bind(this),window.addEventListener("resize",this.onResize=this.onResize.bind(this)),typeof ResizeObserver=="function"&&(this.resize=new ResizeObserver(()=>{this.view.docView.lastUpdate{this.parentCheck<0&&(this.parentCheck=setTimeout(this.listenForScroll.bind(this),1e3)),s.length>0&&s[s.length-1].intersectionRatio>0!=this.intersecting&&(this.intersecting=!this.intersecting,this.intersecting!=this.view.inView&&this.onScrollChanged(document.createEvent("Event")))},{}),this.intersection.observe(this.dom),this.gapIntersection=new IntersectionObserver(s=>{s.length>0&&s[s.length-1].intersectionRatio>0&&this.onScrollChanged(document.createEvent("Event"))},{})),this.listenForScroll(),this.readSelectionRange(),this.dom.ownerDocument.addEventListener("selectionchange",this.onSelectionChange)}onScroll(t){this.intersecting&&this.flush(!1),this.onScrollChanged(t)}onResize(){this.resizeTimeout<0&&(this.resizeTimeout=setTimeout(()=>{this.resizeTimeout=-1,this.view.requestMeasure()},50))}onPrint(){this.view.viewState.printing=!0,this.view.measure(),setTimeout(()=>{this.view.viewState.printing=!1,this.view.requestMeasure()},500)}updateGaps(t){if(this.gapIntersection&&(t.length!=this.gaps.length||this.gaps.some((e,i)=>e!=t[i]))){this.gapIntersection.disconnect();for(let e of t)this.gapIntersection.observe(e);this.gaps=t}}onSelectionChange(t){if(!this.readSelectionRange()||this.delayedAndroidKey)return;let{view:e}=this,i=this.selectionRange;if(e.state.facet(ge)?e.root.activeElement!=this.dom:!Ke(e.dom,i))return;let s=i.anchorNode&&e.docView.nearest(i.anchorNode);s&&s.ignoreEvent(t)||((y.ie&&y.ie_version<=11||y.android&&y.chrome)&&!e.state.selection.main.empty&&i.focusNode&&ae(i.focusNode,i.focusOffset,i.anchorNode,i.anchorOffset)?this.flushSoon():this.flush(!1))}readSelectionRange(){let{root:t}=this.view,e=y.safari&&t.nodeType==11&&ar()==this.view.contentDOM&&io(this.view)||he(t);return!e||this.selectionRange.eq(e)?!1:(this.selectionRange.setRange(e),this.selectionChanged=!0)}setSelectionRange(t,e){this.selectionRange.set(t.node,t.offset,e.node,e.offset),this.selectionChanged=!1}clearSelectionRange(){this.selectionRange.set(null,0,null,0)}listenForScroll(){this.parentCheck=-1;let t=0,e=null;for(let i=this.dom;i;)if(i.nodeType==1)!e&&t{let i=this.delayedAndroidKey;this.delayedAndroidKey=null,this.delayedFlush=-1,this.flush()||Ft(this.view.contentDOM,i.key,i.keyCode)}),(!this.delayedAndroidKey||t=="Enter")&&(this.delayedAndroidKey={key:t,keyCode:e})}flushSoon(){this.delayedFlush<0&&(this.delayedFlush=window.setTimeout(()=>{this.delayedFlush=-1,this.flush()},20))}forceFlush(){this.delayedFlush>=0&&(window.clearTimeout(this.delayedFlush),this.delayedFlush=-1,this.flush())}processRecords(){let t=this.queue;for(let r of this.observer.takeRecords())t.push(r);t.length&&(this.queue=[]);let e=-1,i=-1,s=!1;for(let r of t){let o=this.readMutation(r);!o||(o.typeOver&&(s=!0),e==-1?{from:e,to:i}=o:(e=Math.min(o.from,e),i=Math.max(o.to,i)))}return{from:e,to:i,typeOver:s}}flush(t=!0){if(this.delayedFlush>=0||this.delayedAndroidKey)return;t&&this.readSelectionRange();let{from:e,to:i,typeOver:s}=this.processRecords(),r=this.selectionChanged&&Ke(this.dom,this.selectionRange);if(e<0&&!r)return;this.selectionChanged=!1;let o=this.view.state,l=this.onChange(e,i,s);return this.view.state==o&&this.view.update([]),l}readMutation(t){let e=this.view.docView.nearest(t.target);if(!e||e.ignoreMutation(t))return null;if(e.markDirty(t.type=="attributes"),t.type=="attributes"&&(e.dirty|=4),t.type=="childList"){let i=Bn(e,t.previousSibling||t.target.previousSibling,-1),s=Bn(e,t.nextSibling||t.target.nextSibling,1);return{from:i?e.posAfter(i):e.posAtStart,to:s?e.posBefore(s):e.posAtEnd,typeOver:!1}}else return t.type=="characterData"?{from:e.posAtStart,to:e.posAtEnd,typeOver:t.target.nodeValue==t.oldValue}:null}destroy(){var t,e,i;this.stop(),(t=this.intersection)===null||t===void 0||t.disconnect(),(e=this.gapIntersection)===null||e===void 0||e.disconnect(),(i=this.resize)===null||i===void 0||i.disconnect();for(let s of this.scrollTargets)s.removeEventListener("scroll",this.onScroll);window.removeEventListener("scroll",this.onScroll),window.removeEventListener("resize",this.onResize),window.removeEventListener("beforeprint",this.onPrint),this.dom.ownerDocument.removeEventListener("selectionchange",this.onSelectionChange),clearTimeout(this.parentCheck),clearTimeout(this.resizeTimeout)}};function Bn(n,t,e){for(;t;){let i=k.get(t);if(i&&i.parent==n)return i;let s=t.parentNode;t=s!=n.dom?s:e>0?t.nextSibling:t.previousSibling}return null}function io(n){let t=null;function e(h){h.preventDefault(),h.stopImmediatePropagation(),t=h.getTargetRanges()[0]}if(n.contentDOM.addEventListener("beforeinput",e,!0),document.execCommand("indent"),n.contentDOM.removeEventListener("beforeinput",e,!0),!t)return null;let i=t.startContainer,s=t.startOffset,r=t.endContainer,o=t.endOffset,l=n.docView.domAtPos(n.state.selection.main.anchor);return ae(l.node,l.offset,r,o)&&([i,s,r,o]=[r,o,i,s]),{anchorNode:i,anchorOffset:s,focusNode:r,focusOffset:o}}function so(n,t,e,i){let s,r,o=n.state.selection.main;if(t>-1){let l=n.docView.domBoundsAround(t,e,0);if(!l||n.state.readOnly)return!1;let{from:h,to:a}=l,c=n.docView.impreciseHead||n.docView.impreciseAnchor?[]:ro(n),f=new hi(c,n.state);f.readRange(l.startDOM,l.endDOM);let d=o.from,u=null;(n.inputState.lastKeyCode===8&&n.inputState.lastKeyTime>Date.now()-100||y.android&&f.text.length=o.from&&s.to<=o.to&&(s.from!=o.from||s.to!=o.to)&&o.to-o.from-(s.to-s.from)<=4?s={from:o.from,to:o.to,insert:n.state.doc.slice(o.from,s.from).append(s.insert).append(n.state.doc.slice(s.to,o.to))}:(y.mac||y.android)&&s&&s.from==s.to&&s.from==o.head-1&&s.insert.toString()=="."&&(s={from:o.from,to:o.to,insert:x.of([" "])}),s){let l=n.state;if(y.ios&&n.inputState.flushIOSKey(n)||y.android&&(s.from==o.from&&s.to==o.to&&s.insert.length==1&&s.insert.lines==2&&Ft(n.contentDOM,"Enter",13)||s.from==o.from-1&&s.to==o.to&&s.insert.length==0&&Ft(n.contentDOM,"Backspace",8)||s.from==o.from&&s.to==o.to+1&&s.insert.length==0&&Ft(n.contentDOM,"Delete",46)))return!0;let h=s.insert.toString();if(n.state.facet(Bs).some(f=>f(n,s.from,s.to,h)))return!0;n.inputState.composing>=0&&n.inputState.composing++;let a;if(s.from>=o.from&&s.to<=o.to&&s.to-s.from>=(o.to-o.from)/3&&(!r||r.main.empty&&r.main.from==s.from+s.insert.length)&&n.inputState.composing<0){let f=o.froms.to?l.sliceDoc(s.to,o.to):"";a=l.replaceSelection(n.state.toText(f+s.insert.sliceString(0,void 0,n.state.lineBreak)+d))}else{let f=l.changes(s),d=r&&!l.selection.main.eq(r.main)&&r.main.to<=f.newLength?r.main:void 0;if(l.selection.ranges.length>1&&n.inputState.composing>=0&&s.to<=o.to&&s.to>=o.to-10){let u=n.state.sliceDoc(s.from,s.to),p=$s(n)||n.state.doc.lineAt(o.head),g=o.to-s.to,m=o.to-o.from;a=l.changeByRange(b=>{if(b.from==o.from&&b.to==o.to)return{changes:f,range:d||b.map(f)};let B=b.to-g,it=B-u.length;if(b.to-b.from!=m||n.state.sliceDoc(it,B)!=u||p&&b.to>=p.from&&b.from<=p.to)return{range:b};let ft=l.changes({from:it,to:B,insert:s.insert}),Ai=b.to-o.to;return{changes:ft,range:d?w.range(Math.max(0,d.anchor+Ai),Math.max(0,d.head+Ai)):b.map(ft)}})}else a={changes:f,selection:d&&l.selection.replaceRange(d)}}let c="input.type";return n.composing&&(c+=".compose",n.inputState.compositionFirstChange&&(c+=".start",n.inputState.compositionFirstChange=!1)),n.dispatch(a,{scrollIntoView:!0,userEvent:c}),!0}else if(r&&!r.main.eq(o)){let l=!1,h="select";return n.inputState.lastSelectionTime>Date.now()-50&&(n.inputState.lastSelectionOrigin=="select"&&(l=!0),h=n.inputState.lastSelectionOrigin),n.dispatch({selection:r,scrollIntoView:l,userEvent:h}),!0}else return!1}function no(n,t,e,i){let s=Math.min(n.length,t.length),r=0;for(;r0&&l>0&&n.charCodeAt(o-1)==t.charCodeAt(l-1);)o--,l--;if(i=="end"){let h=Math.max(0,r-Math.min(o,l));e-=o+h-r}return o=o?r-e:0,l=r+(l-o),o=r):l=l?r-e:0,o=r+(o-l),l=r),{from:r,toA:o,toB:l}}function ro(n){let t=[];if(n.root.activeElement!=n.contentDOM)return t;let{anchorNode:e,anchorOffset:i,focusNode:s,focusOffset:r}=n.observer.selectionRange;return e&&(t.push(new ai(e,i)),(s!=e||r!=i)&&t.push(new ai(s,r))),t}function oo(n,t){if(n.length==0)return null;let e=n[0].pos,i=n.length==2?n[1].pos:e;return e>-1&&i>-1?w.single(e+t,i+t):null}var A=class{constructor(t={}){this.plugins=[],this.pluginMap=new Map,this.editorAttrs={},this.contentAttrs={},this.bidiCache=[],this.destroyed=!1,this.updateState=2,this.measureScheduled=-1,this.measureRequests=[],this.contentDOM=document.createElement("div"),this.scrollDOM=document.createElement("div"),this.scrollDOM.tabIndex=-1,this.scrollDOM.className="cm-scroller",this.scrollDOM.appendChild(this.contentDOM),this.announceDOM=document.createElement("div"),this.announceDOM.style.cssText="position: absolute; top: -10000px",this.announceDOM.setAttribute("aria-live","polite"),this.dom=document.createElement("div"),this.dom.appendChild(this.announceDOM),this.dom.appendChild(this.scrollDOM),this._dispatch=t.dispatch||(e=>this.update([e])),this.dispatch=this.dispatch.bind(this),this.root=t.root||ur(t.parent)||document,this.viewState=new wi(t.state||S.create(t)),this.plugins=this.state.facet(Kt).map(e=>new me(e));for(let e of this.plugins)e.update(this);this.observer=new Ln(this,(e,i,s)=>so(this,e,i,s),e=>{this.inputState.runScrollHandlers(this,e),this.observer.intersecting&&this.measure()}),this.inputState=new tn(this),this.inputState.ensureHandlers(this,this.plugins),this.docView=new ci(this),this.mountStyles(),this.updateAttrs(),this.updateState=0,this.requestMeasure(),t.parent&&t.parent.appendChild(this.dom)}get state(){return this.viewState.state}get viewport(){return this.viewState.viewport}get visibleRanges(){return this.viewState.visibleRanges}get inView(){return this.viewState.inView}get composing(){return this.inputState.composing>0}get compositionStarted(){return this.inputState.composing>=0}dispatch(...t){this._dispatch(t.length==1&&t[0]instanceof P?t[0]:this.state.update(...t))}update(t){if(this.updateState!=0)throw new Error("Calls to EditorView.update are not allowed while an update is in progress");let e=!1,i=!1,s,r=this.state;for(let l of t){if(l.startState!=r)throw new RangeError("Trying to update state with a transaction that doesn't start from the previous state.");r=l.state}if(this.destroyed){this.viewState.state=r;return}if(this.observer.clear(),r.facet(S.phrases)!=this.state.facet(S.phrases))return this.setState(r);s=Ut.create(this,r,t);let o=this.viewState.scrollTarget;try{this.updateState=2;for(let l of t){if(o&&(o=o.map(l.changes)),l.scrollIntoView){let{main:h}=l.state.selection;o=new qt(h.empty?h:w.cursor(h.head,h.head>h.anchor?-1:1))}for(let h of l.effects)h.is(Vs)&&(o=h.value)}this.viewState.update(s,o),this.bidiCache=Yt.update(this.bidiCache,s.changes),s.empty||(this.updatePlugins(s),this.inputState.update(s)),e=this.docView.update(s),this.state.facet(Gt)!=this.styleModules&&this.mountStyles(),i=this.updateAttrs(),this.showAnnouncements(t),this.docView.updateSelection(e,t.some(l=>l.isUserEvent("select.pointer")))}finally{this.updateState=0}if(s.startState.facet(xe)!=s.state.facet(xe)&&(this.viewState.mustMeasureContent=!0),(e||i||o||this.viewState.mustEnforceCursorAssoc||this.viewState.mustMeasureContent)&&this.requestMeasure(),!s.empty)for(let l of this.state.facet(ri))l(s)}setState(t){if(this.updateState!=0)throw new Error("Calls to EditorView.setState are not allowed while an update is in progress");if(this.destroyed){this.viewState.state=t;return}this.updateState=2;let e=this.hasFocus;try{for(let i of this.plugins)i.destroy(this);this.viewState=new wi(t),this.plugins=t.facet(Kt).map(i=>new me(i)),this.pluginMap.clear();for(let i of this.plugins)i.update(this);this.docView=new ci(this),this.inputState.ensureHandlers(this,this.plugins),this.mountStyles(),this.updateAttrs(),this.bidiCache=[]}finally{this.updateState=0}e&&this.focus(),this.requestMeasure()}updatePlugins(t){let e=t.startState.facet(Kt),i=t.state.facet(Kt);if(e!=i){let s=[];for(let r of i){let o=e.indexOf(r);if(o<0)s.push(new me(r));else{let l=this.plugins[o];l.mustUpdate=t,s.push(l)}}for(let r of this.plugins)r.mustUpdate!=t&&r.destroy(this);this.plugins=s,this.pluginMap.clear(),this.inputState.ensureHandlers(this,this.plugins)}else for(let s of this.plugins)s.mustUpdate=t;for(let s=0;s-1&&cancelAnimationFrame(this.measureScheduled),this.measureScheduled=0,t&&this.observer.flush();let e=null;try{for(let i=0;;i++){this.updateState=1;let s=this.viewport,r=this.viewState.measure(this);if(!r&&!this.measureRequests.length&&this.viewState.scrollTarget==null)break;if(i>5){console.warn(this.measureRequests.length?"Measure loop restarted more than 5 times":"Viewport failed to stabilize");break}let o=[];r&4||([this.measureRequests,o]=[o,this.measureRequests]);let l=o.map(f=>{try{return f.read(this)}catch(d){return pt(this.state,d),Pn}}),h=Ut.create(this,this.state,[]),a=!1,c=!1;h.flags|=r,e?e.flags|=r:e=h,this.updateState=2,h.empty||(this.updatePlugins(h),this.inputState.update(h),this.updateAttrs(),a=this.docView.update(h));for(let f=0;f{let s=ii(this.contentDOM,this.contentAttrs,e),r=ii(this.dom,this.editorAttrs,t);return s||r});return this.editorAttrs=t,this.contentAttrs=e,i}showAnnouncements(t){let e=!0;for(let i of t)for(let s of i.effects)if(s.is(A.announce)){e&&(this.announceDOM.textContent=""),e=!1;let r=this.announceDOM.appendChild(document.createElement("div"));r.textContent=s.value}}mountStyles(){this.styleModules=this.state.facet(Gt),lt.mount(this.root,this.styleModules.concat(to).reverse())}readMeasured(){if(this.updateState==2)throw new Error("Reading the editor layout isn't allowed during an update");this.updateState==0&&this.measureScheduled>-1&&this.measure(!1)}requestMeasure(t){if(this.measureScheduled<0&&(this.measureScheduled=requestAnimationFrame(()=>this.measure())),t){if(t.key!=null){for(let e=0;ei.spec==t)||null),e&&e.update(this).value}get documentTop(){return this.contentDOM.getBoundingClientRect().top+this.viewState.paddingTop}get documentPadding(){return{top:this.viewState.paddingTop,bottom:this.viewState.paddingBottom}}elementAtHeight(t){return this.readMeasured(),this.viewState.elementAtHeight(t)}lineBlockAtHeight(t){return this.readMeasured(),this.viewState.lineBlockAtHeight(t)}get viewportLineBlocks(){return this.viewState.viewportLines}lineBlockAt(t){return this.viewState.lineBlockAt(t)}get contentHeight(){return this.viewState.contentHeight}moveByChar(t,e,i){return pi(this,t,_s(this,t,e,i))}moveByGroup(t,e){return pi(this,t,_s(this,t,e,i=>Vr(this,t.head,i)))}moveToLineBoundary(t,e,i=!0){return Pr(this,t,e,i)}moveVertically(t,e,i){return pi(this,t,Nr(this,t,e,i))}domAtPos(t){return this.docView.domAtPos(t)}posAtDOM(t,e=0){return this.docView.posFromDOM(t,e)}posAtCoords(t,e=!0){return this.readMeasured(),Zs(this,t,e)}coordsAtPos(t,e=1){this.readMeasured();let i=this.docView.coordsAt(t,e);if(!i||i.left==i.right)return i;let s=this.state.doc.lineAt(t),r=this.bidiSpans(s),o=r[gt.find(r,t-s.from,-1,e)];return fe(i,o.dir==z.LTR==e>0)}get defaultCharacterWidth(){return this.viewState.heightOracle.charWidth}get defaultLineHeight(){return this.viewState.heightOracle.lineHeight}get textDirection(){return this.viewState.defaultTextDirection}textDirectionAt(t){return!this.state.facet(Ps)||tthis.viewport.to?this.textDirection:(this.readMeasured(),this.docView.textDirectionAt(t))}get lineWrapping(){return this.viewState.heightOracle.lineWrapping}bidiSpans(t){if(t.length>lo)return zs(t.length);let e=this.textDirectionAt(t.from);for(let s of this.bidiCache)if(s.from==t.from&&s.dir==e)return s.order;let i=Sr(t.text,e);return this.bidiCache.push(new Yt(t.from,t.to,e,i)),i}get hasFocus(){var t;return(document.hasFocus()||y.safari&&((t=this.inputState)===null||t===void 0?void 0:t.lastContextMenu)>Date.now()-3e4)&&this.root.activeElement==this.contentDOM}focus(){this.observer.ignore(()=>{ds(this.contentDOM),this.docView.updateSelection()})}destroy(){for(let t of this.plugins)t.destroy(this);this.plugins=[],this.inputState.destroy(),this.dom.remove(),this.observer.destroy(),this.measureScheduled>-1&&cancelAnimationFrame(this.measureScheduled),this.destroyed=!0}static scrollIntoView(t,e={}){return Vs.of(new qt(typeof t=="number"?w.cursor(t):t,e.y,e.x,e.yMargin,e.xMargin))}static domEventHandlers(t){return $t.define(()=>({}),{eventHandlers:t})}static theme(t,e){let i=lt.newName(),s=[xe.of(i),Gt.of(xi(`.${i}`,t))];return e&&e.dark&&s.push(bi.of(!0)),s}static baseTheme(t){return Ki.lowest(Gt.of(xi("."+vi,t,En)))}static findFromDOM(t){var e;let i=t.querySelector(".cm-content"),s=i&&k.get(i)||k.get(t);return((e=s==null?void 0:s.rootView)===null||e===void 0?void 0:e.view)||null}};A.styleModule=Gt;A.inputHandler=Bs;A.perLineTextDirection=Ps;A.exceptionSink=Ls;A.updateListener=ri;A.editable=ge;A.mouseSelectionStyle=Es;A.dragMovesSelection=Rs;A.clickAddsSelectionRange=Ts;A.decorations=jt;A.atomicRanges=Hs;A.scrollMargins=Fs;A.darkTheme=bi;A.contentAttributes=Is;A.editorAttributes=Ns;A.lineWrapping=A.contentAttributes.of({class:"cm-lineWrapping"});A.announce=E.define();var lo=4096,Pn={},Yt=class{constructor(t,e,i,s){this.from=t,this.to=e,this.dir=i,this.order=s}static update(t,e){if(e.empty)return t;let i=[],s=t.length?t[t.length-1].dir:z.LTR;for(let r=Math.max(0,t.length-10);r=0;s--){let r=i[s],o=typeof r=="function"?r(n):r;o&&ti(o,e)}return e}var Ao=y.mac?"mac":y.windows?"win":y.linux?"linux":"key";var ho=!y.ios;var ao={".cm-line":{"& ::selection":{backgroundColor:"transparent !important"},"&::selection":{backgroundColor:"transparent !important"}}};ho&&(ao[".cm-line"].caretColor="transparent !important");var Mo=/x/.unicode!=null?"gu":"g";var Do=A.baseTheme({".cm-tooltip":{zIndex:100},"&light .cm-tooltip":{border:"1px solid #bbb",backgroundColor:"#f5f5f5"},"&light .cm-tooltip-section:not(:first-child)":{borderTop:"1px solid #bbb"},"&dark .cm-tooltip":{backgroundColor:"#333338",color:"white"},".cm-tooltip-arrow":{height:`${7}px`,width:`${7*2}px`,position:"absolute",zIndex:-1,overflow:"hidden","&:before, &:after":{content:"''",position:"absolute",width:0,height:0,borderLeft:`${7}px solid transparent`,borderRight:`${7}px solid transparent`},".cm-tooltip-above &":{bottom:`-${7}px`,"&:before":{borderTop:`${7}px solid #bbb`},"&:after":{borderTop:`${7}px solid #f5f5f5`,bottom:"1px"}},".cm-tooltip-below &":{top:`-${7}px`,"&:before":{borderBottom:`${7}px solid #bbb`},"&:after":{borderBottom:`${7}px solid #f5f5f5`,top:"1px"}}},"&dark .cm-tooltip .cm-tooltip-arrow":{"&:before":{borderTopColor:"#333338",borderBottomColor:"#333338"},"&:after":{borderTopColor:"transparent",borderBottomColor:"transparent"}}});var mt=class extends ot{compare(t){return this==t||this.constructor==t.constructor&&this.eq(t)}eq(t){return!1}destroy(t){}};mt.prototype.elementClass="";mt.prototype.toDOM=void 0;mt.prototype.mapMode=K.TrackBefore;mt.prototype.startSide=mt.prototype.endSide=-1;mt.prototype.point=!0;var ki=class{constructor(){this.checkedRE=new RegExp(/^([\s>]*- \[)(x|X)(\] .*)$/),this.unCheckedRE=new RegExp(/^([\s>]*- \[)(.)(\] .*)$/)}check(t){return t.replace(this.unCheckedRE,"$1x$3")}uncheck(t){return t.replace(this.checkedRE,"$1 $3")}};var Ci=class extends Et.Plugin{onload(){return Ce(this,null,function*(){this.dvapi=(0,Nn.getAPI)(),this.TU=new ki,this.registerDomEvent(window,"click",t=>Ce(this,null,function*(){let e=t.target,i=this.app.workspace.getActiveViewOfType(Et.MarkdownView),s=e.nextElementSibling;console.debug("tgt",s,s==null?void 0:s.tagName);let r=o=>{let l=[];console.debug("items",o);for(let h=0;h{(!e.checked&&l.checked||e.checked&&!l.checked)&&l.click()})}else if(e.tagName.toLowerCase()==="input"){let o=A.findFromDOM(document.body);console.debug("elif");let{editor:l}=o.state.field(Et.editorViewField),h=l.offsetToPos(o.posAtDOM(e)).line,a=this.app.workspace.getActiveFile(),f=this.dvapi.page(a.path).file.tasks.values.filter(g=>g.parent===h);console.debug("curious cat",f,this.recurseLivePreviewSubtasks(f).flat(1/0));let d=[];this.recurseLivePreviewSubtasks(f).flat(1/0).forEach(g=>{let{node:m}=o.domAtPos(g.end.offset),b=B=>{d.push(B),[].slice.call(B.children).forEach(b)};[].slice.call(m.children).forEach(b)});let p=d.filter(g=>g.matches("input[type='checkbox']"));p.forEach(g=>{let m=b=>{console.log("clik",b)};g.onclick=m,g.click(),console.log("check status",g.checked,e.checked),(!e.checked&&g.checked||e.checked&&!g.checked)&&g.click()}),console.debug("node",p),this.dvapi.index.touch(),this.app.workspace.trigger("dataview:refresh-views")}}}))})}recurseSubtasks(t){let e=[];function i(s){return e.push(s.children.map(i)),console.log("la",e,t),s.line}return t.map(s=>{e.push(s.line)}),t.map(i),e}recurseLivePreviewSubtasks(t){let e=[];function i(s){return e.push(s.children.map(i)),ke(Se({},s.position),{text:s.text})}return t.map(s=>{e.push(ke(Se({},s.position),{text:s.text}))}),t.map(i),console.debug("finalarr",e.flat(1/0)),e}onunload(){}};0&&(module.exports={}); diff --git a/.obsidian/plugins/obsidian-task-completer/manifest.json b/.obsidian/plugins/obsidian-task-completer/manifest.json new file mode 100644 index 00000000..585a5788 --- /dev/null +++ b/.obsidian/plugins/obsidian-task-completer/manifest.json @@ -0,0 +1 @@ +{"id":"obsidian-task-completer","name":"Obsidian Automatic Recursive Task Completer","version":"1.1.1","minAppVersion":"0.15.4","description":"when you complete a task, this plugin also automatically marks all subtasks as done, so you no longer have to click/toggle every subtask manually.","author":"Tablet","authorUrl":"https://instagram.com/gamergirlandco","isDesktopOnly":false} \ No newline at end of file diff --git a/.obsidian/plugins/obsidian-tasks-plugin/main.js b/.obsidian/plugins/obsidian-tasks-plugin/main.js index 5b07267c..78a15475 100644 --- a/.obsidian/plugins/obsidian-tasks-plugin/main.js +++ b/.obsidian/plugins/obsidian-tasks-plugin/main.js @@ -122,30 +122,31 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -"use strict";var g_=Object.create;var Nn=Object.defineProperty,__=Object.defineProperties,T_=Object.getOwnPropertyDescriptor,b_=Object.getOwnPropertyDescriptors,v_=Object.getOwnPropertyNames,Bd=Object.getOwnPropertySymbols,E_=Object.getPrototypeOf,Hd=Object.prototype.hasOwnProperty,R_=Object.prototype.propertyIsEnumerable;var Gd=(r,e,t)=>e in r?Nn(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,$e=(r,e)=>{for(var t in e||(e={}))Hd.call(e,t)&&Gd(r,t,e[t]);if(Bd)for(var t of Bd(e))R_.call(e,t)&&Gd(r,t,e[t]);return r},Ut=(r,e)=>__(r,b_(e));var h=(r,e)=>()=>(e||r((e={exports:{}}).exports,e),e.exports),w_=(r,e)=>{for(var t in e)Nn(r,t,{get:e[t],enumerable:!0})},zd=(r,e,t,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of v_(e))!Hd.call(r,i)&&i!==t&&Nn(r,i,{get:()=>e[i],enumerable:!(n=T_(e,i))||n.enumerable});return r};var as=(r,e,t)=>(t=r!=null?g_(E_(r)):{},zd(e||!r||!r.__esModule?Nn(t,"default",{value:r,enumerable:!0}):t,r)),M_=r=>zd(Nn({},"__esModule",{value:!0}),r);var ae=(r,e,t)=>new Promise((n,i)=>{var s=u=>{try{o(t.next(u))}catch(l){i(l)}},a=u=>{try{o(t.throw(u))}catch(l){i(l)}},o=u=>u.done?n(u.value):Promise.resolve(u.value).then(s,a);o((t=t.apply(r,e)).next())});var Ef=h((gA,ps)=>{var ef,tf,rf,nf,sf,af,of,uf,lf,ds,Xa,cf,df,ff,Xr,pf,hf,mf,yf,gf,_f,Tf,bf,vf,fs;(function(r){var e=typeof global=="object"?global:typeof self=="object"?self:typeof this=="object"?this:{};typeof define=="function"&&define.amd?define("tslib",["exports"],function(n){r(t(e,t(n)))}):typeof ps=="object"&&typeof ps.exports=="object"?r(t(e,t(ps.exports))):r(t(e));function t(n,i){return n!==e&&(typeof Object.create=="function"?Object.defineProperty(n,"__esModule",{value:!0}):n.__esModule=!0),function(s,a){return n[s]=i?i(s,a):a}}})(function(r){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var s in i)Object.prototype.hasOwnProperty.call(i,s)&&(n[s]=i[s])};ef=function(n,i){if(typeof i!="function"&&i!==null)throw new TypeError("Class extends value "+String(i)+" is not a constructor or null");e(n,i);function s(){this.constructor=n}n.prototype=i===null?Object.create(i):(s.prototype=i.prototype,new s)},tf=Object.assign||function(n){for(var i,s=1,a=arguments.length;s=0;c--)(l=n[c])&&(u=(o<3?l(u):o>3?l(i,s,u):l(i,s))||u);return o>3&&u&&Object.defineProperty(i,s,u),u},sf=function(n,i){return function(s,a){i(s,a,n)}},af=function(n,i){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(n,i)},of=function(n,i,s,a){function o(u){return u instanceof s?u:new s(function(l){l(u)})}return new(s||(s=Promise))(function(u,l){function c(p){try{f(a.next(p))}catch(y){l(y)}}function d(p){try{f(a.throw(p))}catch(y){l(y)}}function f(p){p.done?u(p.value):o(p.value).then(c,d)}f((a=a.apply(n,i||[])).next())})},uf=function(n,i){var s={label:0,sent:function(){if(u[0]&1)throw u[1];return u[1]},trys:[],ops:[]},a,o,u,l;return l={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(l[Symbol.iterator]=function(){return this}),l;function c(f){return function(p){return d([f,p])}}function d(f){if(a)throw new TypeError("Generator is already executing.");for(;s;)try{if(a=1,o&&(u=f[0]&2?o.return:f[0]?o.throw||((u=o.return)&&u.call(o),0):o.next)&&!(u=u.call(o,f[1])).done)return u;switch(o=0,u&&(f=[f[0]&2,u.value]),f[0]){case 0:case 1:u=f;break;case 4:return s.label++,{value:f[1],done:!1};case 5:s.label++,o=f[1],f=[0];continue;case 7:f=s.ops.pop(),s.trys.pop();continue;default:if(u=s.trys,!(u=u.length>0&&u[u.length-1])&&(f[0]===6||f[0]===2)){s=0;continue}if(f[0]===3&&(!u||f[1]>u[0]&&f[1]=n.length&&(n=void 0),{value:n&&n[a++],done:!n}}};throw new TypeError(i?"Object is not iterable.":"Symbol.iterator is not defined.")},Xa=function(n,i){var s=typeof Symbol=="function"&&n[Symbol.iterator];if(!s)return n;var a=s.call(n),o,u=[],l;try{for(;(i===void 0||i-- >0)&&!(o=a.next()).done;)u.push(o.value)}catch(c){l={error:c}}finally{try{o&&!o.done&&(s=a.return)&&s.call(a)}finally{if(l)throw l.error}}return u},cf=function(){for(var n=[],i=0;i1||c(m,g)})})}function c(m,g){try{d(a[m](g))}catch(A){y(u[0][3],A)}}function d(m){m.value instanceof Xr?Promise.resolve(m.value.v).then(f,p):y(u[0][2],m)}function f(m){c("next",m)}function p(m){c("throw",m)}function y(m,g){m(g),u.shift(),u.length&&c(u[0][0],u[0][1])}},hf=function(n){var i,s;return i={},a("next"),a("throw",function(o){throw o}),a("return"),i[Symbol.iterator]=function(){return this},i;function a(o,u){i[o]=n[o]?function(l){return(s=!s)?{value:Xr(n[o](l)),done:o==="return"}:u?u(l):l}:u}},mf=function(n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var i=n[Symbol.asyncIterator],s;return i?i.call(n):(n=typeof ds=="function"?ds(n):n[Symbol.iterator](),s={},a("next"),a("throw"),a("return"),s[Symbol.asyncIterator]=function(){return this},s);function a(u){s[u]=n[u]&&function(l){return new Promise(function(c,d){l=n[u](l),o(c,d,l.done,l.value)})}}function o(u,l,c,d){Promise.resolve(d).then(function(f){u({value:f,done:c})},l)}},yf=function(n,i){return Object.defineProperty?Object.defineProperty(n,"raw",{value:i}):n.raw=i,n};var t=Object.create?function(n,i){Object.defineProperty(n,"default",{enumerable:!0,value:i})}:function(n,i){n.default=i};gf=function(n){if(n&&n.__esModule)return n;var i={};if(n!=null)for(var s in n)s!=="default"&&Object.prototype.hasOwnProperty.call(n,s)&&fs(i,n,s);return t(i,n),i},_f=function(n){return n&&n.__esModule?n:{default:n}},Tf=function(n,i,s,a){if(s==="a"&&!a)throw new TypeError("Private accessor was defined without a getter");if(typeof i=="function"?n!==i||!a:!i.has(n))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?a:s==="a"?a.call(n):a?a.value:i.get(n)},bf=function(n,i,s,a,o){if(a==="m")throw new TypeError("Private method is not writable");if(a==="a"&&!o)throw new TypeError("Private accessor was defined without a setter");if(typeof i=="function"?n!==i||!o:!i.has(n))throw new TypeError("Cannot write private member to an object whose class did not declare it");return a==="a"?o.call(n,s):o?o.value=s:i.set(n,s),s},vf=function(n,i){if(i===null||typeof i!="object"&&typeof i!="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof n=="function"?i===n:n.has(i)},r("__extends",ef),r("__assign",tf),r("__rest",rf),r("__decorate",nf),r("__param",sf),r("__metadata",af),r("__awaiter",of),r("__generator",uf),r("__exportStar",lf),r("__createBinding",fs),r("__values",ds),r("__read",Xa),r("__spread",cf),r("__spreadArrays",df),r("__spreadArray",ff),r("__await",Xr),r("__asyncGenerator",pf),r("__asyncDelegator",hf),r("__asyncValues",mf),r("__makeTemplateObject",yf),r("__importStar",gf),r("__importDefault",_f),r("__classPrivateFieldGet",Tf),r("__classPrivateFieldSet",bf),r("__classPrivateFieldIn",vf)})});var Q=h(mr=>{"use strict";Object.defineProperty(mr,"__esModule",{value:!0});mr.matchAnyPattern=mr.extractTerms=mr.repeatedTimeunitPattern=void 0;function yT(r,e){let t=e.replace(/\((?!\?)/g,"(?:");return`${r}${t}\\s{0,5}(?:,?\\s{0,5}${t}){0,10}`}mr.repeatedTimeunitPattern=yT;function yp(r){let e;return r instanceof Array?e=[...r]:r instanceof Map?e=Array.from(r.keys()):e=Object.keys(r),e}mr.extractTerms=yp;function gT(r){return`(?:${yp(r).sort((t,n)=>n.length-t.length).join("|").replace(/\./g,"\\.")})`}mr.matchAnyPattern=gT});var K=h((co,fo)=>{(function(r,e){typeof co=="object"&&typeof fo!="undefined"?fo.exports=e():typeof define=="function"&&define.amd?define(e):(r=typeof globalThis!="undefined"?globalThis:r||self).dayjs=e()})(co,function(){"use strict";var r=1e3,e=6e4,t=36e5,n="millisecond",i="second",s="minute",a="hour",o="day",u="week",l="month",c="quarter",d="year",f="date",p="Invalid Date",y=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,m=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,g={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_")},A=function(D,v,_){var P=String(D);return!P||P.length>=v?D:""+Array(v+1-P.length).join(_)+D},x={s:A,z:function(D){var v=-D.utcOffset(),_=Math.abs(v),P=Math.floor(_/60),E=_%60;return(v<=0?"+":"-")+A(P,2,"0")+":"+A(E,2,"0")},m:function D(v,_){if(v.date()<_.date())return-D(_,v);var P=12*(_.year()-v.year())+(_.month()-v.month()),E=v.clone().add(P,l),S=_-E<0,O=v.clone().add(P+(S?-1:1),l);return+(-(P+(_-E)/(S?E-O:O-E))||0)},a:function(D){return D<0?Math.ceil(D)||0:Math.floor(D)},p:function(D){return{M:l,y:d,w:u,d:o,D:f,h:a,m:s,s:i,ms:n,Q:c}[D]||String(D||"").toLowerCase().replace(/s$/,"")},u:function(D){return D===void 0}},C="en",z={};z[C]=g;var ne=function(D){return D instanceof ge},fe=function(D,v,_){var P;if(!D)return C;if(typeof D=="string")z[D]&&(P=D),v&&(z[D]=v,P=D);else{var E=D.name;z[E]=D,P=E}return!_&&P&&(C=P),P||!_&&C},ee=function(D,v){if(ne(D))return D.clone();var _=typeof v=="object"?v:{};return _.date=D,_.args=arguments,new ge(_)},M=x;M.l=fe,M.i=ne,M.w=function(D,v){return ee(D,{locale:v.$L,utc:v.$u,x:v.$x,$offset:v.$offset})};var ge=function(){function D(_){this.$L=fe(_.locale,null,!0),this.parse(_)}var v=D.prototype;return v.parse=function(_){this.$d=function(P){var E=P.date,S=P.utc;if(E===null)return new Date(NaN);if(M.u(E))return new Date;if(E instanceof Date)return new Date(E);if(typeof E=="string"&&!/Z$/i.test(E)){var O=E.match(y);if(O){var W=O[2]-1||0,te=(O[7]||"0").substring(0,3);return S?new Date(Date.UTC(O[1],W,O[3]||1,O[4]||0,O[5]||0,O[6]||0,te)):new Date(O[1],W,O[3]||1,O[4]||0,O[5]||0,O[6]||0,te)}}return new Date(E)}(_),this.$x=_.x||{},this.init()},v.init=function(){var _=this.$d;this.$y=_.getFullYear(),this.$M=_.getMonth(),this.$D=_.getDate(),this.$W=_.getDay(),this.$H=_.getHours(),this.$m=_.getMinutes(),this.$s=_.getSeconds(),this.$ms=_.getMilliseconds()},v.$utils=function(){return M},v.isValid=function(){return this.$d.toString()!==p},v.isSame=function(_,P){var E=ee(_);return this.startOf(P)<=E&&E<=this.endOf(P)},v.isAfter=function(_,P){return ee(_){"use strict";var _T=yr&&yr.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(yr,"__esModule",{value:!0});yr.findYearClosestToRef=yr.findMostLikelyADYear=void 0;var TT=_T(K());function bT(r){return r<100&&(r>50?r=r+1900:r=r+2e3),r}yr.findMostLikelyADYear=bT;function vT(r,e,t){let n=TT.default(r),i=n;i=i.month(t-1),i=i.date(e),i=i.year(n.year());let s=i.add(1,"y"),a=i.add(-1,"y");return Math.abs(s.diff(n)){"use strict";Object.defineProperty(q,"__esModule",{value:!0});q.parseTimeUnits=q.TIME_UNITS_PATTERN=q.parseYear=q.YEAR_PATTERN=q.parseOrdinalNumberPattern=q.ORDINAL_NUMBER_PATTERN=q.parseNumberPattern=q.NUMBER_PATTERN=q.TIME_UNIT_DICTIONARY=q.ORDINAL_WORD_DICTIONARY=q.INTEGER_WORD_DICTIONARY=q.MONTH_DICTIONARY=q.FULL_MONTH_NAME_DICTIONARY=q.WEEKDAY_DICTIONARY=void 0;var Es=Q(),ET=Se();q.WEEKDAY_DICTIONARY={sunday:0,sun:0,"sun.":0,monday:1,mon:1,"mon.":1,tuesday:2,tue:2,"tue.":2,wednesday:3,wed:3,"wed.":3,thursday:4,thurs:4,"thurs.":4,thur:4,"thur.":4,thu:4,"thu.":4,friday:5,fri:5,"fri.":5,saturday:6,sat:6,"sat.":6};q.FULL_MONTH_NAME_DICTIONARY={january:1,february:2,march:3,april:4,may:5,june:6,july:7,august:8,september:9,october:10,november:11,december:12};q.MONTH_DICTIONARY=Object.assign(Object.assign({},q.FULL_MONTH_NAME_DICTIONARY),{jan:1,"jan.":1,feb:2,"feb.":2,mar:3,"mar.":3,apr:4,"apr.":4,jun:6,"jun.":6,jul:7,"jul.":7,aug:8,"aug.":8,sep:9,"sep.":9,sept:9,"sept.":9,oct:10,"oct.":10,nov:11,"nov.":11,dec:12,"dec.":12});q.INTEGER_WORD_DICTIONARY={one:1,two:2,three:3,four:4,five:5,six:6,seven:7,eight:8,nine:9,ten:10,eleven:11,twelve:12};q.ORDINAL_WORD_DICTIONARY={first:1,second:2,third:3,fourth:4,fifth:5,sixth:6,seventh:7,eighth:8,ninth:9,tenth:10,eleventh:11,twelfth:12,thirteenth:13,fourteenth:14,fifteenth:15,sixteenth:16,seventeenth:17,eighteenth:18,nineteenth:19,twentieth:20,"twenty first":21,"twenty-first":21,"twenty second":22,"twenty-second":22,"twenty third":23,"twenty-third":23,"twenty fourth":24,"twenty-fourth":24,"twenty fifth":25,"twenty-fifth":25,"twenty sixth":26,"twenty-sixth":26,"twenty seventh":27,"twenty-seventh":27,"twenty eighth":28,"twenty-eighth":28,"twenty ninth":29,"twenty-ninth":29,thirtieth:30,"thirty first":31,"thirty-first":31};q.TIME_UNIT_DICTIONARY={sec:"second",second:"second",seconds:"second",min:"minute",mins:"minute",minute:"minute",minutes:"minute",h:"hour",hr:"hour",hrs:"hour",hour:"hour",hours:"hour",day:"d",days:"d",week:"week",weeks:"week",month:"month",months:"month",qtr:"quarter",quarter:"quarter",quarters:"quarter",y:"year",yr:"year",year:"year",years:"year"};q.NUMBER_PATTERN=`(?:${Es.matchAnyPattern(q.INTEGER_WORD_DICTIONARY)}|[0-9]+|[0-9]+\\.[0-9]+|half(?:\\s{0,2}an?)?|an?\\b(?:\\s{0,2}few)?|few|several|a?\\s{0,2}couple\\s{0,2}(?:of)?)`;function _p(r){let e=r.toLowerCase();return q.INTEGER_WORD_DICTIONARY[e]!==void 0?q.INTEGER_WORD_DICTIONARY[e]:e==="a"||e==="an"?1:e.match(/few/)?3:e.match(/half/)?.5:e.match(/couple/)?2:e.match(/several/)?7:parseFloat(e)}q.parseNumberPattern=_p;q.ORDINAL_NUMBER_PATTERN=`(?:${Es.matchAnyPattern(q.ORDINAL_WORD_DICTIONARY)}|[0-9]{1,2}(?:st|nd|rd|th)?)`;function RT(r){let e=r.toLowerCase();return q.ORDINAL_WORD_DICTIONARY[e]!==void 0?q.ORDINAL_WORD_DICTIONARY[e]:(e=e.replace(/(?:st|nd|rd|th)$/i,""),parseInt(e))}q.parseOrdinalNumberPattern=RT;q.YEAR_PATTERN="(?:[1-9][0-9]{0,3}\\s{0,2}(?:BE|AD|BC|BCE|CE)|[1-2][0-9]{3}|[5-9][0-9])";function wT(r){if(/BE/i.test(r))return r=r.replace(/BE/i,""),parseInt(r)-543;if(/BCE?/i.test(r))return r=r.replace(/BCE?/i,""),-parseInt(r);if(/(AD|CE)/i.test(r))return r=r.replace(/(AD|CE)/i,""),parseInt(r);let e=parseInt(r);return ET.findMostLikelyADYear(e)}q.parseYear=wT;var Tp=`(${q.NUMBER_PATTERN})\\s{0,3}(${Es.matchAnyPattern(q.TIME_UNIT_DICTIONARY)})`,gp=new RegExp(Tp,"i");q.TIME_UNITS_PATTERN=Es.repeatedTimeunitPattern("(?:(?:about|around)\\s{0,3})?",Tp);function MT(r){let e={},t=r,n=gp.exec(t);for(;n;)DT(e,n),t=t.substring(n[0].length).trim(),n=gp.exec(t);return e}q.parseTimeUnits=MT;function DT(r,e){let t=_p(e[1]),n=q.TIME_UNIT_DICTIONARY[e[2].toLowerCase()];r[n]=t}});var bp=h((po,ho)=>{(function(r,e){typeof po=="object"&&typeof ho!="undefined"?ho.exports=e():typeof define=="function"&&define.amd?define(e):(r=typeof globalThis!="undefined"?globalThis:r||self).dayjs_plugin_quarterOfYear=e()})(po,function(){"use strict";var r="month",e="quarter";return function(t,n){var i=n.prototype;i.quarter=function(o){return this.$utils().u(o)?Math.ceil((this.month()+1)/3):this.month(this.month()%3+3*(o-1))};var s=i.add;i.add=function(o,u){return o=Number(o),this.$utils().p(u)===e?this.add(3*o,r):s.bind(this)(o,u)};var a=i.startOf;i.startOf=function(o,u){var l=this.$utils(),c=!!l.u(u)||u;if(l.p(o)===e){var d=this.quarter()-1;return c?this.month(3*d).startOf(r).startOf("day"):this.month(3*d+2).endOf(r).endOf("day")}return a.bind(this)(o,u)}}})});var it=h(Pt=>{"use strict";Object.defineProperty(Pt,"__esModule",{value:!0});Pt.implySimilarTime=Pt.assignSimilarTime=Pt.assignSimilarDate=Pt.assignTheNextDay=void 0;var vp=Ee();function PT(r,e){e=e.add(1,"day"),Ep(r,e),Rp(r,e)}Pt.assignTheNextDay=PT;function Ep(r,e){r.assign("day",e.date()),r.assign("month",e.month()+1),r.assign("year",e.year())}Pt.assignSimilarDate=Ep;function OT(r,e){r.assign("hour",e.hour()),r.assign("minute",e.minute()),r.assign("second",e.second()),r.assign("millisecond",e.millisecond()),r.get("hour")<12?r.assign("meridiem",vp.Meridiem.AM):r.assign("meridiem",vp.Meridiem.PM)}Pt.assignSimilarTime=OT;function Rp(r,e){r.imply("hour",e.hour()),r.imply("minute",e.minute()),r.imply("second",e.second()),r.imply("millisecond",e.millisecond())}Pt.implySimilarTime=Rp});var wp=h(Sr=>{"use strict";Object.defineProperty(Sr,"__esModule",{value:!0});Sr.toTimezoneOffset=Sr.TIMEZONE_ABBR_MAP=void 0;Sr.TIMEZONE_ABBR_MAP={ACDT:630,ACST:570,ADT:-180,AEDT:660,AEST:600,AFT:270,AKDT:-480,AKST:-540,ALMT:360,AMST:-180,AMT:-240,ANAST:720,ANAT:720,AQTT:300,ART:-180,AST:-240,AWDT:540,AWST:480,AZOST:0,AZOT:-60,AZST:300,AZT:240,BNT:480,BOT:-240,BRST:-120,BRT:-180,BST:60,BTT:360,CAST:480,CAT:120,CCT:390,CDT:-300,CEST:120,CET:60,CHADT:825,CHAST:765,CKT:-600,CLST:-180,CLT:-240,COT:-300,CST:-360,CVT:-60,CXT:420,ChST:600,DAVT:420,EASST:-300,EAST:-360,EAT:180,ECT:-300,EDT:-240,EEST:180,EET:120,EGST:0,EGT:-60,EST:-300,ET:-300,FJST:780,FJT:720,FKST:-180,FKT:-240,FNT:-120,GALT:-360,GAMT:-540,GET:240,GFT:-180,GILT:720,GMT:0,GST:240,GYT:-240,HAA:-180,HAC:-300,HADT:-540,HAE:-240,HAP:-420,HAR:-360,HAST:-600,HAT:-90,HAY:-480,HKT:480,HLV:-210,HNA:-240,HNC:-360,HNE:-300,HNP:-480,HNR:-420,HNT:-150,HNY:-540,HOVT:420,ICT:420,IDT:180,IOT:360,IRDT:270,IRKST:540,IRKT:540,IRST:210,IST:330,JST:540,KGT:360,KRAST:480,KRAT:480,KST:540,KUYT:240,LHDT:660,LHST:630,LINT:840,MAGST:720,MAGT:720,MART:-510,MAWT:300,MDT:-360,MESZ:120,MEZ:60,MHT:720,MMT:390,MSD:240,MSK:180,MST:-420,MUT:240,MVT:300,MYT:480,NCT:660,NDT:-90,NFT:690,NOVST:420,NOVT:360,NPT:345,NST:-150,NUT:-660,NZDT:780,NZST:720,OMSST:420,OMST:420,PDT:-420,PET:-300,PETST:720,PETT:720,PGT:600,PHOT:780,PHT:480,PKT:300,PMDT:-120,PMST:-180,PONT:660,PST:-480,PT:-480,PWT:540,PYST:-180,PYT:-240,RET:240,SAMT:240,SAST:120,SBT:660,SCT:240,SGT:480,SRT:-180,SST:-660,TAHT:-600,TFT:300,TJT:300,TKT:780,TLT:540,TMT:300,TVT:720,ULAT:480,UTC:0,UYST:-120,UYT:-180,UZT:300,VET:-210,VLAST:660,VLAT:660,VUT:660,WAST:120,WAT:60,WEST:60,WESZ:60,WET:0,WEZ:0,WFT:720,WGST:-120,WGT:-180,WIB:420,WIT:540,WITA:480,WST:780,WT:0,YAKST:600,YAKT:600,YAPT:600,YEKST:360,YEKT:360};function AT(r){var e;return r==null?null:typeof r=="number"?r:(e=Sr.TIMEZONE_ABBR_MAP[r])!==null&&e!==void 0?e:null}Sr.toTimezoneOffset=AT});var he=h(Ot=>{"use strict";var Mp=Ot&&Ot.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ot,"__esModule",{value:!0});Ot.ParsingResult=Ot.ParsingComponents=Ot.ReferenceWithTimezone=void 0;var kT=Mp(bp()),Rs=Mp(K()),mo=it(),NT=wp();Rs.default.extend(kT.default);var yo=class{constructor(e){var t;e=e!=null?e:new Date,e instanceof Date?this.instant=e:(this.instant=(t=e.instant)!==null&&t!==void 0?t:new Date,this.timezoneOffset=NT.toTimezoneOffset(e.timezone))}};Ot.ReferenceWithTimezone=yo;var Ir=class{constructor(e,t){if(this.reference=e,this.knownValues={},this.impliedValues={},t)for(let i in t)this.knownValues[i]=t[i];let n=Rs.default(e.instant);this.imply("day",n.date()),this.imply("month",n.month()+1),this.imply("year",n.year()),this.imply("hour",12),this.imply("minute",0),this.imply("second",0),this.imply("millisecond",0)}get(e){return e in this.knownValues?this.knownValues[e]:e in this.impliedValues?this.impliedValues[e]:null}isCertain(e){return e in this.knownValues}getCertainComponents(){return Object.keys(this.knownValues)}imply(e,t){return e in this.knownValues?this:(this.impliedValues[e]=t,this)}assign(e,t){return this.knownValues[e]=t,delete this.impliedValues[e],this}delete(e){delete this.knownValues[e],delete this.impliedValues[e]}clone(){let e=new Ir(this.reference);e.knownValues={},e.impliedValues={};for(let t in this.knownValues)e.knownValues[t]=this.knownValues[t];for(let t in this.impliedValues)e.impliedValues[t]=this.impliedValues[t];return e}isOnlyDate(){return!this.isCertain("hour")&&!this.isCertain("minute")&&!this.isCertain("second")}isOnlyTime(){return!this.isCertain("weekday")&&!this.isCertain("day")&&!this.isCertain("month")}isOnlyWeekdayComponent(){return this.isCertain("weekday")&&!this.isCertain("day")&&!this.isCertain("month")}isOnlyDayMonthComponent(){return this.isCertain("day")&&this.isCertain("month")&&!this.isCertain("year")}isValidDate(){let e=this.dateWithoutTimezoneAdjustment();return!(e.getFullYear()!==this.get("year")||e.getMonth()!==this.get("month")-1||e.getDate()!==this.get("day")||this.get("hour")!=null&&e.getHours()!=this.get("hour")||this.get("minute")!=null&&e.getMinutes()!=this.get("minute"))}toString(){return`[ParsingComponents {knownValues: ${JSON.stringify(this.knownValues)}, impliedValues: ${JSON.stringify(this.impliedValues)}}, reference: ${JSON.stringify(this.reference)}]`}dayjs(){return Rs.default(this.date())}date(){let e=this.dateWithoutTimezoneAdjustment();return new Date(e.getTime()+this.getSystemTimezoneAdjustmentMinute(e)*6e4)}dateWithoutTimezoneAdjustment(){let e=new Date(this.get("year"),this.get("month")-1,this.get("day"),this.get("hour"),this.get("minute"),this.get("second"),this.get("millisecond"));return e.setFullYear(this.get("year")),e}getSystemTimezoneAdjustmentMinute(e){var t,n;(!e||e.getTime()<0)&&(e=new Date);let i=-e.getTimezoneOffset(),s=(n=(t=this.get("timezoneOffset"))!==null&&t!==void 0?t:this.reference.timezoneOffset)!==null&&n!==void 0?n:i;return i-s}static createRelativeFromReference(e,t){let n=Rs.default(e.instant);for(let s in t)n=n.add(t[s],s);let i=new Ir(e);return t.hour||t.minute||t.second?(mo.assignSimilarTime(i,n),mo.assignSimilarDate(i,n),e.timezoneOffset!==null&&i.assign("timezoneOffset",-e.instant.getTimezoneOffset())):(mo.implySimilarTime(i,n),e.timezoneOffset!==null&&i.imply("timezoneOffset",-e.instant.getTimezoneOffset()),t.d?(i.assign("day",n.date()),i.assign("month",n.month()+1),i.assign("year",n.year())):(t.week&&i.imply("weekday",n.day()),i.imply("day",n.date()),t.month?(i.assign("month",n.month()+1),i.assign("year",n.year())):(i.imply("month",n.month()+1),t.year?i.assign("year",n.year()):i.imply("year",n.year())))),i}};Ot.ParsingComponents=Ir;var $n=class{constructor(e,t,n,i,s){this.reference=e,this.refDate=e.instant,this.index=t,this.text=n,this.start=i||new Ir(e),this.end=s}clone(){let e=new $n(this.reference,this.index,this.text);return e.start=this.start?this.start.clone():null,e.end=this.end?this.end.clone():null,e}date(){return this.start.date()}toString(){return`[ParsingResult {index: ${this.index}, text: '${this.text}', ...}]`}};Ot.ParsingResult=$n});var R=h(ws=>{"use strict";Object.defineProperty(ws,"__esModule",{value:!0});ws.AbstractParserWithWordBoundaryChecking=void 0;var go=class{constructor(){this.cachedInnerPattern=null,this.cachedPattern=null}patternLeftBoundary(){return"(\\W|^)"}pattern(e){let t=this.innerPattern(e);return t==this.cachedInnerPattern?this.cachedPattern:(this.cachedPattern=new RegExp(`${this.patternLeftBoundary()}${t.source}`,t.flags),this.cachedInnerPattern=t,this.cachedPattern)}extract(e,t){var n;let i=(n=t[1])!==null&&n!==void 0?n:"";t.index=t.index+i.length,t[0]=t[0].substring(i.length);for(let s=2;s{"use strict";Object.defineProperty(bo,"__esModule",{value:!0});var To=Ie(),CT=he(),xT=R(),ST=new RegExp(`(?:within|in|for)\\s*(?:(?:about|around|roughly|approximately|just)\\s*(?:~\\s*)?)?(${To.TIME_UNITS_PATTERN})(?=\\W|$)`,"i"),IT=new RegExp(`(?:(?:about|around|roughly|approximately|just)\\s*(?:~\\s*)?)?(${To.TIME_UNITS_PATTERN})(?=\\W|$)`,"i"),_o=class extends xT.AbstractParserWithWordBoundaryChecking{innerPattern(e){return e.option.forwardDate?IT:ST}innerExtract(e,t){let n=To.parseTimeUnits(t[1]);return CT.ParsingComponents.createRelativeFromReference(e.reference,n)}};bo.default=_o});var Cp=h(Eo=>{"use strict";Object.defineProperty(Eo,"__esModule",{value:!0});var UT=Se(),kp=Ie(),Np=Ie(),Ms=Ie(),FT=Q(),qT=R(),WT=new RegExp(`(?:on\\s{0,3})?(${Ms.ORDINAL_NUMBER_PATTERN})(?:\\s{0,3}(?:to|\\-|\\\u2013|until|through|till)?\\s{0,3}(${Ms.ORDINAL_NUMBER_PATTERN}))?(?:-|/|\\s{0,3}(?:of)?\\s{0,3})(${FT.matchAnyPattern(kp.MONTH_DICTIONARY)})(?:(?:-|/|,?\\s{0,3})(${Np.YEAR_PATTERN}(?![^\\s]\\d)))?(?=\\W|$)`,"i"),Pp=1,Op=2,LT=3,Ap=4,vo=class extends qT.AbstractParserWithWordBoundaryChecking{innerPattern(){return WT}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=kp.MONTH_DICTIONARY[t[LT].toLowerCase()],s=Ms.parseOrdinalNumberPattern(t[Pp]);if(s>31)return t.index=t.index+t[Pp].length,null;if(n.start.assign("month",i),n.start.assign("day",s),t[Ap]){let a=Np.parseYear(t[Ap]);n.start.assign("year",a)}else{let a=UT.findYearClosestToRef(e.refDate,s,i);n.start.imply("year",a)}if(t[Op]){let a=Ms.parseOrdinalNumberPattern(t[Op]);n.end=n.start.clone(),n.end.assign("day",a)}return n}};Eo.default=vo});var Fp=h(wo=>{"use strict";Object.defineProperty(wo,"__esModule",{value:!0});var YT=Se(),Ip=Ie(),Ds=Ie(),Up=Ie(),$T=Q(),jT=R(),BT=new RegExp(`(${$T.matchAnyPattern(Ip.MONTH_DICTIONARY)})(?:-|/|\\s*,?\\s*)(${Ds.ORDINAL_NUMBER_PATTERN})(?!\\s*(?:am|pm))\\s*(?:(?:to|\\-)\\s*(${Ds.ORDINAL_NUMBER_PATTERN})\\s*)?(?:(?:-|/|\\s*,?\\s*)(${Up.YEAR_PATTERN}))?(?=\\W|$)(?!\\:\\d)`,"i"),GT=1,HT=2,xp=3,Sp=4,Ro=class extends jT.AbstractParserWithWordBoundaryChecking{innerPattern(){return BT}innerExtract(e,t){let n=Ip.MONTH_DICTIONARY[t[GT].toLowerCase()],i=Ds.parseOrdinalNumberPattern(t[HT]);if(i>31)return null;let s=e.createParsingComponents({day:i,month:n});if(t[Sp]){let u=Up.parseYear(t[Sp]);s.assign("year",u)}else{let u=YT.findYearClosestToRef(e.refDate,i,n);s.imply("year",u)}if(!t[xp])return s;let a=Ds.parseOrdinalNumberPattern(t[xp]),o=e.createParsingResult(t.index,t[0]);return o.start=s,o.end=s.clone(),o.end.assign("day",a),o}};wo.default=Ro});var Lp=h(Po=>{"use strict";Object.defineProperty(Po,"__esModule",{value:!0});var Mo=Ie(),zT=Se(),KT=Q(),Wp=Ie(),VT=R(),ZT=new RegExp(`((?:in)\\s*)?(${KT.matchAnyPattern(Mo.MONTH_DICTIONARY)})\\s*(?:[,-]?\\s*(${Wp.YEAR_PATTERN})?)?(?=[^\\s\\w]|\\s+[^0-9]|\\s+$|$)`,"i"),XT=1,QT=2,qp=3,Do=class extends VT.AbstractParserWithWordBoundaryChecking{innerPattern(){return ZT}innerExtract(e,t){let n=t[QT].toLowerCase();if(t[0].length<=3&&!Mo.FULL_MONTH_NAME_DICTIONARY[n])return null;let i=e.createParsingResult(t.index+(t[XT]||"").length,t.index+t[0].length);i.start.imply("day",1);let s=Mo.MONTH_DICTIONARY[n];if(i.start.assign("month",s),t[qp]){let a=Wp.parseYear(t[qp]);i.start.assign("year",a)}else{let a=zT.findYearClosestToRef(e.refDate,1,s);i.start.imply("year",a)}return i}};Po.default=Do});var jp=h(Ao=>{"use strict";Object.defineProperty(Ao,"__esModule",{value:!0});var $p=Ie(),JT=Q(),eb=R(),tb=new RegExp(`([0-9]{4})[\\.\\/\\s](?:(${JT.matchAnyPattern($p.MONTH_DICTIONARY)})|([0-9]{1,2}))[\\.\\/\\s]([0-9]{1,2})(?=\\W|$)`,"i"),rb=1,nb=2,Yp=3,ib=4,Oo=class extends eb.AbstractParserWithWordBoundaryChecking{innerPattern(){return tb}innerExtract(e,t){let n=t[Yp]?parseInt(t[Yp]):$p.MONTH_DICTIONARY[t[nb].toLowerCase()];if(n<1||n>12)return null;let i=parseInt(t[rb]);return{day:parseInt(t[ib]),month:n,year:i}}};Ao.default=Oo});var Bp=h(No=>{"use strict";Object.defineProperty(No,"__esModule",{value:!0});var sb=R(),ab=new RegExp("([0-9]|0[1-9]|1[012])/([0-9]{4})","i"),ob=1,ub=2,ko=class extends sb.AbstractParserWithWordBoundaryChecking{innerPattern(){return ab}innerExtract(e,t){let n=parseInt(t[ub]),i=parseInt(t[ob]);return e.createParsingComponents().imply("day",1).assign("month",i).assign("year",n)}};No.default=ko});var Ur=h(As=>{"use strict";Object.defineProperty(As,"__esModule",{value:!0});As.AbstractTimeExpressionParser=void 0;var Be=Ee();function lb(r,e,t,n){return new RegExp(`${r}${e}(\\d{1,4})(?:(?:\\.|:|\uFF1A)(\\d{1,2})(?:(?::|\uFF1A)(\\d{2})(?:\\.(\\d{1,6}))?)?)?(?:\\s*(a\\.m\\.|p\\.m\\.|am?|pm?))?${t}`,n)}function cb(r,e){return new RegExp(`^(${r})(\\d{1,4})(?:(?:\\.|\\:|\\\uFF1A)(\\d{1,2})(?:(?:\\.|\\:|\\\uFF1A)(\\d{1,2})(?:\\.(\\d{1,6}))?)?)?(?:\\s*(a\\.m\\.|p\\.m\\.|am?|pm?))?${e}`,"i")}var Gp=2,rn=3,Ps=4,Os=5,jn=6,Co=class{constructor(e=!1){this.cachedPrimaryPrefix=null,this.cachedPrimarySuffix=null,this.cachedPrimaryTimePattern=null,this.cachedFollowingPhase=null,this.cachedFollowingSuffix=null,this.cachedFollowingTimePatten=null,this.strictMode=e}patternFlags(){return"i"}primaryPatternLeftBoundary(){return"(^|\\s|T|\\b)"}primarySuffix(){return"(?=\\W|$)"}followingSuffix(){return"(?=\\W|$)"}pattern(e){return this.getPrimaryTimePatternThroughCache()}extract(e,t){let n=this.extractPrimaryTimeComponents(e,t);if(!n)return t.index+=t[0].length,null;let i=t.index+t[1].length,s=t[0].substring(t[1].length),a=e.createParsingResult(i,s,n);t.index+=t[0].length;let o=e.text.substring(t.index),l=this.getFollowingTimePatternThroughCache().exec(o);return s.match(/^\d{3,4}/)&&l&&l[0].match(/^\s*([+-])\s*\d{2,4}$/)?null:!l||l[0].match(/^\s*([+-])\s*\d{3,4}$/)?this.checkAndReturnWithoutFollowingPattern(a):(a.end=this.extractFollowingTimeComponents(e,l,a),a.end&&(a.text+=l[0]),this.checkAndReturnWithFollowingPattern(a))}extractPrimaryTimeComponents(e,t,n=!1){let i=e.createParsingComponents(),s=0,a=null,o=parseInt(t[Gp]);if(o>100){if(this.strictMode||t[rn]!=null)return null;s=o%100,o=Math.floor(o/100)}if(o>24)return null;if(t[rn]!=null){if(t[rn].length==1&&!t[jn])return null;s=parseInt(t[rn])}if(s>=60)return null;if(o>12&&(a=Be.Meridiem.PM),t[jn]!=null){if(o>12)return null;let u=t[jn][0].toLowerCase();u=="a"&&(a=Be.Meridiem.AM,o==12&&(o=0)),u=="p"&&(a=Be.Meridiem.PM,o!=12&&(o+=12))}if(i.assign("hour",o),i.assign("minute",s),a!==null?i.assign("meridiem",a):o<12?i.imply("meridiem",Be.Meridiem.AM):i.imply("meridiem",Be.Meridiem.PM),t[Os]!=null){let u=parseInt(t[Os].substring(0,3));if(u>=1e3)return null;i.assign("millisecond",u)}if(t[Ps]!=null){let u=parseInt(t[Ps]);if(u>=60)return null;i.assign("second",u)}return i}extractFollowingTimeComponents(e,t,n){let i=e.createParsingComponents();if(t[Os]!=null){let u=parseInt(t[Os].substring(0,3));if(u>=1e3)return null;i.assign("millisecond",u)}if(t[Ps]!=null){let u=parseInt(t[Ps]);if(u>=60)return null;i.assign("second",u)}let s=parseInt(t[Gp]),a=0,o=-1;if(t[rn]!=null?a=parseInt(t[rn]):s>100&&(a=s%100,s=Math.floor(s/100)),a>=60||s>24)return null;if(s>=12&&(o=Be.Meridiem.PM),t[jn]!=null){if(s>12)return null;let u=t[jn][0].toLowerCase();u=="a"&&(o=Be.Meridiem.AM,s==12&&(s=0,i.isCertain("day")||i.imply("day",i.get("day")+1))),u=="p"&&(o=Be.Meridiem.PM,s!=12&&(s+=12)),n.start.isCertain("meridiem")||(o==Be.Meridiem.AM?(n.start.imply("meridiem",Be.Meridiem.AM),n.start.get("hour")==12&&n.start.assign("hour",0)):(n.start.imply("meridiem",Be.Meridiem.PM),n.start.get("hour")!=12&&n.start.assign("hour",n.start.get("hour")+12)))}return i.assign("hour",s),i.assign("minute",a),o>=0?i.assign("meridiem",o):n.start.isCertain("meridiem")&&n.start.get("hour")>12?n.start.get("hour")-12>s?i.imply("meridiem",Be.Meridiem.AM):s<=12&&(i.assign("hour",s+12),i.assign("meridiem",Be.Meridiem.PM)):s>12?i.imply("meridiem",Be.Meridiem.PM):s<=12&&i.imply("meridiem",Be.Meridiem.AM),i.date().getTime()24)return null}return e}checkAndReturnWithFollowingPattern(e){if(e.text.match(/^\d+-\d+$/))return null;let t=e.text.match(/[^\d:.](\d[\d.]+)\s*-\s*(\d[\d.]+)$/);if(t){if(this.strictMode)return null;let n=t[1],i=t[2];if(i.includes(".")&&!i.match(/\d(\.\d{2})+$/))return null;let s=parseInt(i),a=parseInt(n);if(s>24||a>24)return null}return e}getPrimaryTimePatternThroughCache(){let e=this.primaryPrefix(),t=this.primarySuffix();return this.cachedPrimaryPrefix===e&&this.cachedPrimarySuffix===t?this.cachedPrimaryTimePattern:(this.cachedPrimaryTimePattern=lb(this.primaryPatternLeftBoundary(),e,t,this.patternFlags()),this.cachedPrimaryPrefix=e,this.cachedPrimarySuffix=t,this.cachedPrimaryTimePattern)}getFollowingTimePatternThroughCache(){let e=this.followingPhase(),t=this.followingSuffix();return this.cachedFollowingPhase===e&&this.cachedFollowingSuffix===t?this.cachedFollowingTimePatten:(this.cachedFollowingTimePatten=cb(e,t),this.cachedFollowingPhase=e,this.cachedFollowingSuffix=t,this.cachedFollowingTimePatten)}};As.AbstractTimeExpressionParser=Co});var Hp=h(So=>{"use strict";Object.defineProperty(So,"__esModule",{value:!0});var ks=Ee(),db=Ur(),xo=class extends db.AbstractTimeExpressionParser{constructor(e){super(e)}followingPhase(){return"\\s*(?:\\-|\\\u2013|\\~|\\\u301C|to|\\?)\\s*"}primaryPrefix(){return"(?:(?:at|from)\\s*)??"}primarySuffix(){return"(?:\\s*(?:o\\W*clock|at\\s*night|in\\s*the\\s*(?:morning|afternoon)))?(?!/)(?=\\W|$)"}extractPrimaryTimeComponents(e,t){let n=super.extractPrimaryTimeComponents(e,t);if(n){if(t[0].endsWith("night")){let i=n.get("hour");i>=6&&i<12?(n.assign("hour",n.get("hour")+12),n.assign("meridiem",ks.Meridiem.PM)):i<6&&n.assign("meridiem",ks.Meridiem.AM)}if(t[0].endsWith("afternoon")){n.assign("meridiem",ks.Meridiem.PM);let i=n.get("hour");i>=0&&i<=6&&n.assign("hour",n.get("hour")+12)}t[0].endsWith("morning")&&(n.assign("meridiem",ks.Meridiem.AM),n.get("hour")<12&&n.assign("hour",n.get("hour")))}return n}};So.default=xo});var st=h(nn=>{"use strict";Object.defineProperty(nn,"__esModule",{value:!0});nn.addImpliedTimeUnits=nn.reverseTimeUnits=void 0;function fb(r){let e={};for(let t in r)e[t]=-r[t];return e}nn.reverseTimeUnits=fb;function pb(r,e){let t=r.clone(),n=r.dayjs();for(let i in e)n=n.add(e[i],i);return("day"in e||"d"in e||"week"in e||"month"in e||"year"in e)&&(t.imply("day",n.date()),t.imply("month",n.month()+1),t.imply("year",n.year())),("second"in e||"minute"in e||"hour"in e)&&(t.imply("second",n.second()),t.imply("minute",n.minute()),t.imply("hour",n.hour())),t}nn.addImpliedTimeUnits=pb});var zp=h(Fo=>{"use strict";Object.defineProperty(Fo,"__esModule",{value:!0});var Uo=Ie(),hb=he(),mb=R(),yb=st(),gb=new RegExp(`(${Uo.TIME_UNITS_PATTERN})\\s{0,5}(?:ago|before|earlier)(?=(?:\\W|$))`,"i"),_b=new RegExp(`(${Uo.TIME_UNITS_PATTERN})\\s{0,5}ago(?=(?:\\W|$))`,"i"),Io=class extends mb.AbstractParserWithWordBoundaryChecking{constructor(e){super(),this.strictMode=e}innerPattern(){return this.strictMode?_b:gb}innerExtract(e,t){let n=Uo.parseTimeUnits(t[1]),i=yb.reverseTimeUnits(n);return hb.ParsingComponents.createRelativeFromReference(e.reference,i)}};Fo.default=Io});var Kp=h(Lo=>{"use strict";Object.defineProperty(Lo,"__esModule",{value:!0});var Wo=Ie(),Tb=he(),bb=R(),vb=new RegExp(`(${Wo.TIME_UNITS_PATTERN})\\s{0,5}(?:later|after|from now|henceforth|forward|out)(?=(?:\\W|$))`,"i"),Eb=new RegExp("("+Wo.TIME_UNITS_PATTERN+")(later|from now)(?=(?:\\W|$))","i"),Rb=1,qo=class extends bb.AbstractParserWithWordBoundaryChecking{constructor(e){super(),this.strictMode=e}innerPattern(){return this.strictMode?Eb:vb}innerExtract(e,t){let n=Wo.parseTimeUnits(t[Rb]);return Tb.ParsingComponents.createRelativeFromReference(e.reference,n)}};Lo.default=qo});var an=h(sn=>{"use strict";Object.defineProperty(sn,"__esModule",{value:!0});sn.MergingRefiner=sn.Filter=void 0;var Yo=class{refine(e,t){return t.filter(n=>this.isValid(e,n))}};sn.Filter=Yo;var $o=class{refine(e,t){if(t.length<2)return t;let n=[],i=t[0],s=null;for(let a=1;a{console.log(`${this.constructor.name} merged ${u} and ${l} into ${c}`)}),i=c}}return i!=null&&n.push(i),n}};sn.MergingRefiner=$o});var At=h(Bo=>{"use strict";Object.defineProperty(Bo,"__esModule",{value:!0});var wb=an(),jo=class extends wb.MergingRefiner{shouldMergeResults(e,t,n){return!t.end&&!n.end&&e.match(this.patternBetween())!=null}mergeResults(e,t,n){if(!t.start.isOnlyWeekdayComponent()&&!n.start.isOnlyWeekdayComponent()&&(n.start.getCertainComponents().forEach(s=>{t.start.isCertain(s)||t.start.assign(s,n.start.get(s))}),t.start.getCertainComponents().forEach(s=>{n.start.isCertain(s)||n.start.assign(s,t.start.get(s))})),t.start.date().getTime()>n.start.date().getTime()){let s=t.start.dayjs(),a=n.start.dayjs();t.start.isOnlyWeekdayComponent()&&s.add(-7,"days").isBefore(a)?(s=s.add(-7,"days"),t.start.imply("day",s.date()),t.start.imply("month",s.month()+1),t.start.imply("year",s.year())):n.start.isOnlyWeekdayComponent()&&a.add(7,"days").isAfter(s)?(a=a.add(7,"days"),n.start.imply("day",a.date()),n.start.imply("month",a.month()+1),n.start.imply("year",a.year())):[n,t]=[t,n]}let i=t.clone();return i.start=t.start,i.end=n.start,i.index=Math.min(t.index,n.index),t.index{"use strict";var Mb=Bn&&Bn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Bn,"__esModule",{value:!0});var Db=Mb(At()),Go=class extends Db.default{patternBetween(){return/^\s*(to|-)\s*$/i}};Bn.default=Go});var Zp=h(on=>{"use strict";Object.defineProperty(on,"__esModule",{value:!0});on.mergeDateTimeComponent=on.mergeDateTimeResult=void 0;var Pb=Ee();function Ob(r,e){let t=r.clone(),n=r.start,i=e.start;if(t.start=Ho(n,i),r.end!=null||e.end!=null){let s=r.end==null?r.start:r.end,a=e.end==null?e.start:e.end,o=Ho(s,a);r.end==null&&o.date().getTime(){"use strict";Object.defineProperty(Ko,"__esModule",{value:!0});var Ab=an(),Xp=Zp(),zo=class extends Ab.MergingRefiner{shouldMergeResults(e,t,n){return(t.start.isOnlyDate()&&n.start.isOnlyTime()||n.start.isOnlyDate()&&t.start.isOnlyTime())&&e.match(this.patternBetween())!=null}mergeResults(e,t,n){let i=t.start.isOnlyDate()?Xp.mergeDateTimeResult(t,n):Xp.mergeDateTimeResult(n,t);return i.index=t.index,i.text=t.text+e+n.text,i}};Ko.default=zo});var Qp=h(Gn=>{"use strict";var kb=Gn&&Gn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Gn,"__esModule",{value:!0});var Nb=kb(jt()),Vo=class extends Nb.default{patternBetween(){return new RegExp("^\\s*(T|at|after|before|on|of|,|-)?\\s*$")}};Gn.default=Vo});var Jp=h(Xo=>{"use strict";Object.defineProperty(Xo,"__esModule",{value:!0});var Cb=new RegExp("^\\s*,?\\s*\\(?([A-Z]{2,4})\\)?(?=\\W|$)","i"),xb={ACDT:630,ACST:570,ADT:-180,AEDT:660,AEST:600,AFT:270,AKDT:-480,AKST:-540,ALMT:360,AMST:-180,AMT:-240,ANAST:720,ANAT:720,AQTT:300,ART:-180,AST:-240,AWDT:540,AWST:480,AZOST:0,AZOT:-60,AZST:300,AZT:240,BNT:480,BOT:-240,BRST:-120,BRT:-180,BST:60,BTT:360,CAST:480,CAT:120,CCT:390,CDT:-300,CEST:120,CET:60,CHADT:825,CHAST:765,CKT:-600,CLST:-180,CLT:-240,COT:-300,CST:-360,CVT:-60,CXT:420,ChST:600,DAVT:420,EASST:-300,EAST:-360,EAT:180,ECT:-300,EDT:-240,EEST:180,EET:120,EGST:0,EGT:-60,EST:-300,ET:-300,FJST:780,FJT:720,FKST:-180,FKT:-240,FNT:-120,GALT:-360,GAMT:-540,GET:240,GFT:-180,GILT:720,GMT:0,GST:240,GYT:-240,HAA:-180,HAC:-300,HADT:-540,HAE:-240,HAP:-420,HAR:-360,HAST:-600,HAT:-90,HAY:-480,HKT:480,HLV:-210,HNA:-240,HNC:-360,HNE:-300,HNP:-480,HNR:-420,HNT:-150,HNY:-540,HOVT:420,ICT:420,IDT:180,IOT:360,IRDT:270,IRKST:540,IRKT:540,IRST:210,IST:330,JST:540,KGT:360,KRAST:480,KRAT:480,KST:540,KUYT:240,LHDT:660,LHST:630,LINT:840,MAGST:720,MAGT:720,MART:-510,MAWT:300,MDT:-360,MESZ:120,MEZ:60,MHT:720,MMT:390,MSD:240,MSK:240,MST:-420,MUT:240,MVT:300,MYT:480,NCT:660,NDT:-90,NFT:690,NOVST:420,NOVT:360,NPT:345,NST:-150,NUT:-660,NZDT:780,NZST:720,OMSST:420,OMST:420,PDT:-420,PET:-300,PETST:720,PETT:720,PGT:600,PHOT:780,PHT:480,PKT:300,PMDT:-120,PMST:-180,PONT:660,PST:-480,PT:-480,PWT:540,PYST:-180,PYT:-240,RET:240,SAMT:240,SAST:120,SBT:660,SCT:240,SGT:480,SRT:-180,SST:-660,TAHT:-600,TFT:300,TJT:300,TKT:780,TLT:540,TMT:300,TVT:720,ULAT:480,UTC:0,UYST:-120,UYT:-180,UZT:300,VET:-210,VLAST:660,VLAT:660,VUT:660,WAST:120,WAT:60,WEST:60,WESZ:60,WET:0,WEZ:0,WFT:720,WGST:-120,WGT:-180,WIB:420,WIT:540,WITA:480,WST:780,WT:0,YAKST:600,YAKT:600,YAPT:600,YEKST:360,YEKT:360},Zo=class{constructor(e){this.timezone=Object.assign(Object.assign({},xb),e)}refine(e,t){var n;let i=(n=e.option.timezones)!==null&&n!==void 0?n:{};return t.forEach(s=>{var a,o;let u=e.text.substring(s.index+s.text.length),l=Cb.exec(u);if(!l)return;let c=l[1].toUpperCase(),d=(o=(a=i[c])!==null&&a!==void 0?a:this.timezone[c])!==null&&o!==void 0?o:null;if(d===null)return;e.debug(()=>{console.log(`Extracting timezone: '${c}' into: ${d} for: ${s.start}`)});let f=s.start.get("timezoneOffset");f!==null&&d!=f&&(s.start.isCertain("timezoneOffset")||c!=l[1])||s.start.isOnlyDate()&&c!=l[1]||(s.text+=l[0],s.start.isCertain("timezoneOffset")||s.start.assign("timezoneOffset",d),s.end!=null&&!s.end.isCertain("timezoneOffset")&&s.end.assign("timezoneOffset",d))}),t}};Xo.default=Zo});var Ns=h(Jo=>{"use strict";Object.defineProperty(Jo,"__esModule",{value:!0});var Sb=new RegExp("^\\s*(?:\\(?(?:GMT|UTC)\\s?)?([+-])(\\d{1,2})(?::?(\\d{2}))?\\)?","i"),Ib=1,Ub=2,Fb=3,Qo=class{refine(e,t){return t.forEach(function(n){if(n.start.isCertain("timezoneOffset"))return;let i=e.text.substring(n.index+n.text.length),s=Sb.exec(i);if(!s)return;e.debug(()=>{console.log(`Extracting timezone: '${s[0]}' into : ${n}`)});let a=parseInt(s[Ub]),o=parseInt(s[Fb]||"0"),u=a*60+o;u>14*60||(s[Ib]==="-"&&(u=-u),n.end!=null&&n.end.assign("timezoneOffset",u),n.start.assign("timezoneOffset",u),n.text+=s[0])}),t}};Jo.default=Qo});var eh=h(tu=>{"use strict";Object.defineProperty(tu,"__esModule",{value:!0});var eu=class{refine(e,t){if(t.length<2)return t;let n=[],i=t[0];for(let s=1;si.text.length&&(i=a):(n.push(i),i=a)}return i!=null&&n.push(i),n}};tu.default=eu});var th=h(Hn=>{"use strict";var qb=Hn&&Hn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Hn,"__esModule",{value:!0});var Wb=qb(K()),ru=class{refine(e,t){return e.option.forwardDate&&t.forEach(function(n){let i=Wb.default(e.refDate);if(n.start.isOnlyDayMonthComponent()&&i.isAfter(n.start.dayjs()))for(let s=0;s<3&&i.isAfter(n.start.dayjs());s++)n.start.imply("year",n.start.get("year")+1),e.debug(()=>{console.log(`Forward yearly adjusted for ${n} (${n.start})`)}),n.end&&!n.end.isCertain("year")&&(n.end.imply("year",n.end.get("year")+1),e.debug(()=>{console.log(`Forward yearly adjusted for ${n} (${n.end})`)}));n.start.isOnlyWeekdayComponent()&&i.isAfter(n.start.dayjs())&&(i.day()>=n.start.get("weekday")?i=i.day(n.start.get("weekday")+7):i=i.day(n.start.get("weekday")),n.start.imply("day",i.date()),n.start.imply("month",i.month()+1),n.start.imply("year",i.year()),e.debug(()=>{console.log(`Forward weekly adjusted for ${n} (${n.start})`)}),n.end&&n.end.isOnlyWeekdayComponent()&&(i.day()>n.end.get("weekday")?i=i.day(n.end.get("weekday")+7):i=i.day(n.end.get("weekday")),n.end.imply("day",i.date()),n.end.imply("month",i.month()+1),n.end.imply("year",i.year()),e.debug(()=>{console.log(`Forward weekly adjusted for ${n} (${n.end})`)})))}),t}};Hn.default=ru});var rh=h(iu=>{"use strict";Object.defineProperty(iu,"__esModule",{value:!0});var Lb=an(),nu=class extends Lb.Filter{constructor(e){super(),this.strictMode=e}isValid(e,t){return t.text.replace(" ","").match(/^\d*(\.\d*)?$/)?(e.debug(()=>{console.log(`Removing unlikely result '${t.text}'`)}),!1):t.start.isValidDate()?t.end&&!t.end.isValidDate()?(e.debug(()=>{console.log(`Removing invalid result: ${t} (${t.end})`)}),!1):this.strictMode?this.isStrictModeValid(e,t):!0:(e.debug(()=>{console.log(`Removing invalid result: ${t} (${t.start})`)}),!1)}isStrictModeValid(e,t){return t.start.isOnlyWeekdayComponent()?(e.debug(()=>{console.log(`(Strict) Removing weekday only component: ${t} (${t.end})`)}),!1):t.start.isOnlyTime()&&(!t.start.isCertain("hour")||!t.start.isCertain("minute"))?(e.debug(()=>{console.log(`(Strict) Removing uncertain time component: ${t} (${t.end})`)}),!1):!0}};iu.default=nu});var ou=h(au=>{"use strict";Object.defineProperty(au,"__esModule",{value:!0});var Yb=R(),$b=new RegExp("([0-9]{4})\\-([0-9]{1,2})\\-([0-9]{1,2})(?:T([0-9]{1,2}):([0-9]{1,2})(?::([0-9]{1,2})(?:\\.(\\d{1,4}))?)?(?:Z|([+-]\\d{2}):?(\\d{2})?)?)?(?=\\W|$)","i"),jb=1,Bb=2,Gb=3,nh=4,Hb=5,ih=6,sh=7,ah=8,oh=9,su=class extends Yb.AbstractParserWithWordBoundaryChecking{innerPattern(){return $b}innerExtract(e,t){let n={};if(n.year=parseInt(t[jb]),n.month=parseInt(t[Bb]),n.day=parseInt(t[Gb]),t[nh]!=null)if(n.hour=parseInt(t[nh]),n.minute=parseInt(t[Hb]),t[ih]!=null&&(n.second=parseInt(t[ih])),t[sh]!=null&&(n.millisecond=parseInt(t[sh])),t[ah]==null)n.timezoneOffset=0;else{let i=parseInt(t[ah]),s=0;t[oh]!=null&&(s=parseInt(t[oh]));let a=i*60;a<0?a-=s:a+=s,n.timezoneOffset=a}return n}};au.default=su});var uh=h(lu=>{"use strict";Object.defineProperty(lu,"__esModule",{value:!0});var zb=an(),uu=class extends zb.MergingRefiner{mergeResults(e,t,n){let i=n.clone();return i.index=t.index,i.text=t.text+e+i.text,i.start.assign("weekday",t.start.get("weekday")),i.end&&i.end.assign("weekday",t.start.get("weekday")),i}shouldMergeResults(e,t,n){return t.start.isOnlyWeekdayComponent()&&!t.start.isCertain("hour")&&n.start.isCertain("day")&&e.match(/^,?\s*$/)!=null}};lu.default=uu});var Bt=h(un=>{"use strict";var Fr=un&&un.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(un,"__esModule",{value:!0});un.includeCommonConfiguration=void 0;var Kb=Fr(Jp()),Vb=Fr(Ns()),lh=Fr(eh()),Zb=Fr(th()),Xb=Fr(rh()),Qb=Fr(ou()),Jb=Fr(uh());function ev(r,e=!1){return r.parsers.unshift(new Qb.default),r.refiners.unshift(new Jb.default),r.refiners.unshift(new Kb.default),r.refiners.unshift(new Vb.default),r.refiners.unshift(new lh.default),r.refiners.push(new lh.default),r.refiners.push(new Zb.default),r.refiners.push(new Xb.default(e)),r}un.includeCommonConfiguration=ev});var Ht=h(X=>{"use strict";var tv=X&&X.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(X,"__esModule",{value:!0});X.noon=X.morning=X.midnight=X.yesterdayEvening=X.evening=X.lastNight=X.tonight=X.theDayAfter=X.tomorrow=X.theDayBefore=X.yesterday=X.today=X.now=void 0;var kt=he(),ln=tv(K()),Gt=it(),zn=Ee();function rv(r){let e=ln.default(r.instant),t=new kt.ParsingComponents(r,{});return Gt.assignSimilarDate(t,e),Gt.assignSimilarTime(t,e),r.timezoneOffset!==null&&t.assign("timezoneOffset",e.utcOffset()),t}X.now=rv;function nv(r){let e=ln.default(r.instant),t=new kt.ParsingComponents(r,{});return Gt.assignSimilarDate(t,e),Gt.implySimilarTime(t,e),t}X.today=nv;function iv(r){return ch(r,1)}X.yesterday=iv;function ch(r,e){return cu(r,-e)}X.theDayBefore=ch;function sv(r){return cu(r,1)}X.tomorrow=sv;function cu(r,e){let t=ln.default(r.instant),n=new kt.ParsingComponents(r,{});return t=t.add(e,"day"),Gt.assignSimilarDate(n,t),Gt.implySimilarTime(n,t),n}X.theDayAfter=cu;function av(r,e=22){let t=ln.default(r.instant),n=new kt.ParsingComponents(r,{});return n.imply("hour",e),n.imply("meridiem",zn.Meridiem.PM),Gt.assignSimilarDate(n,t),n}X.tonight=av;function ov(r,e=0){let t=ln.default(r.instant),n=new kt.ParsingComponents(r,{});return t.hour()<6&&(t=t.add(-1,"day")),Gt.assignSimilarDate(n,t),n.imply("hour",e),n}X.lastNight=ov;function uv(r,e=20){let t=new kt.ParsingComponents(r,{});return t.imply("meridiem",zn.Meridiem.PM),t.imply("hour",e),t}X.evening=uv;function lv(r,e=20){let t=ln.default(r.instant),n=new kt.ParsingComponents(r,{});return t=t.add(-1,"day"),Gt.assignSimilarDate(n,t),n.imply("hour",e),n.imply("meridiem",zn.Meridiem.PM),n}X.yesterdayEvening=lv;function cv(r){let e=new kt.ParsingComponents(r,{});return e.imply("hour",0),e.imply("minute",0),e.imply("second",0),e}X.midnight=cv;function dv(r,e=6){let t=new kt.ParsingComponents(r,{});return t.imply("meridiem",zn.Meridiem.AM),t.imply("hour",e),t}X.morning=dv;function fv(r){let e=new kt.ParsingComponents(r,{});return e.imply("meridiem",zn.Meridiem.AM),e.imply("hour",12),e}X.noon=fv});var dh=h(mt=>{"use strict";var pv=mt&&mt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),hv=mt&&mt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),mv=mt&&mt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&pv(e,r,t);return hv(e,r),e},yv=mt&&mt.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(mt,"__esModule",{value:!0});var gv=yv(K()),_v=R(),Tv=it(),Kn=mv(Ht()),bv=/(now|today|tonight|tomorrow|tmr|tmrw|yesterday|last\s*night)(?=\W|$)/i,du=class extends _v.AbstractParserWithWordBoundaryChecking{innerPattern(e){return bv}innerExtract(e,t){let n=gv.default(e.refDate),i=t[0].toLowerCase(),s=e.createParsingComponents();switch(i){case"now":return Kn.now(e.reference);case"today":return Kn.today(e.reference);case"yesterday":return Kn.yesterday(e.reference);case"tomorrow":case"tmr":case"tmrw":return Kn.tomorrow(e.reference);case"tonight":return Kn.tonight(e.reference);default:i.match(/last\s*night/)&&(n.hour()>6&&(n=n.add(-1,"day")),Tv.assignSimilarDate(s,n),s.imply("hour",0));break}return s}};mt.default=du});var fh=h(Vn=>{"use strict";var vv=Vn&&Vn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Vn,"__esModule",{value:!0});var Cs=Ee(),Ev=R(),Rv=vv(K()),wv=it(),Mv=/(?:this)?\s{0,3}(morning|afternoon|evening|night|midnight|noon)(?=\W|$)/i,fu=class extends Ev.AbstractParserWithWordBoundaryChecking{innerPattern(){return Mv}innerExtract(e,t){let n=Rv.default(e.refDate),i=e.createParsingComponents();switch(t[1].toLowerCase()){case"afternoon":i.imply("meridiem",Cs.Meridiem.PM),i.imply("hour",15);break;case"evening":case"night":i.imply("meridiem",Cs.Meridiem.PM),i.imply("hour",20);break;case"midnight":wv.assignTheNextDay(i,n),i.imply("hour",0),i.imply("minute",0),i.imply("second",0);break;case"morning":i.imply("meridiem",Cs.Meridiem.AM),i.imply("hour",6);break;case"noon":i.imply("meridiem",Cs.Meridiem.AM),i.imply("hour",12);break}return i}};Vn.default=fu});var qr=h(gr=>{"use strict";var Dv=gr&&gr.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(gr,"__esModule",{value:!0});gr.toDayJSClosestWeekday=gr.toDayJSWeekday=void 0;var ph=Dv(K());function Pv(r,e,t){if(!t)return hh(r,e);let n=ph.default(r);switch(t){case"this":n=n.day(e);break;case"next":n=n.day(e+7);break;case"last":n=n.day(e-7);break}return n}gr.toDayJSWeekday=Pv;function hh(r,e){let t=ph.default(r),n=t.day();return Math.abs(e-7-n){"use strict";Object.defineProperty(hu,"__esModule",{value:!0});var mh=Ie(),Ov=Q(),Av=R(),kv=qr(),Nv=new RegExp(`(?:(?:\\,|\\(|\\\uFF08)\\s*)?(?:on\\s*?)?(?:(this|last|past|next)\\s*)?(${Ov.matchAnyPattern(mh.WEEKDAY_DICTIONARY)})(?:\\s*(?:\\,|\\)|\\\uFF09))?(?:\\s*(this|last|past|next)\\s*week)?(?=\\W|$)`,"i"),Cv=1,xv=2,Sv=3,pu=class extends Av.AbstractParserWithWordBoundaryChecking{innerPattern(){return Nv}innerExtract(e,t){let n=t[xv].toLowerCase(),i=mh.WEEKDAY_DICTIONARY[n],s=t[Cv],a=t[Sv],o=s||a;o=o||"",o=o.toLowerCase();let u=null;o=="last"||o=="past"?u="last":o=="next"?u="next":o=="this"&&(u="this");let l=kv.toDayJSWeekday(e.refDate,i,u);return e.createParsingComponents().assign("weekday",i).imply("day",l.date()).imply("month",l.month()+1).imply("year",l.year())}};hu.default=pu});var Th=h(Zn=>{"use strict";var Iv=Zn&&Zn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Zn,"__esModule",{value:!0});var _h=Ie(),gh=he(),Uv=Iv(K()),Fv=R(),qv=Q(),Wv=new RegExp(`(this|last|past|next|after\\s*this)\\s*(${qv.matchAnyPattern(_h.TIME_UNIT_DICTIONARY)})(?=\\s*)(?=\\W|$)`,"i"),Lv=1,Yv=2,mu=class extends Fv.AbstractParserWithWordBoundaryChecking{innerPattern(){return Wv}innerExtract(e,t){let n=t[Lv].toLowerCase(),i=t[Yv].toLowerCase(),s=_h.TIME_UNIT_DICTIONARY[i];if(n=="next"||n.startsWith("after")){let u={};return u[s]=1,gh.ParsingComponents.createRelativeFromReference(e.reference,u)}if(n=="last"||n=="past"){let u={};return u[s]=-1,gh.ParsingComponents.createRelativeFromReference(e.reference,u)}let a=e.createParsingComponents(),o=Uv.default(e.reference.instant);return i.match(/week/i)?(o=o.add(-o.get("d"),"d"),a.imply("day",o.date()),a.imply("month",o.month()+1),a.imply("year",o.year())):i.match(/month/i)?(o=o.add(-o.date()+1,"d"),a.imply("day",o.date()),a.assign("year",o.year()),a.assign("month",o.month()+1)):i.match(/year/i)&&(o=o.add(-o.date()+1,"d"),o=o.add(-o.month(),"month"),a.imply("day",o.date()),a.imply("month",o.month()+1),a.assign("year",o.year())),a}};Zn.default=mu});var yt=h(fn=>{"use strict";Object.defineProperty(fn,"__esModule",{value:!0});fn.ParsingContext=fn.Chrono=void 0;var cn=he(),$v=yu(),dn=class{constructor(e){e=e||$v.createCasualConfiguration(),this.parsers=[...e.parsers],this.refiners=[...e.refiners]}clone(){return new dn({parsers:[...this.parsers],refiners:[...this.refiners]})}parseDate(e,t,n){let i=this.parse(e,t,n);return i.length>0?i[0].start.date():null}parse(e,t,n){let i=new xs(e,t,n),s=[];return this.parsers.forEach(a=>{let o=dn.executeParser(i,a);s=s.concat(o)}),s.sort((a,o)=>a.index-o.index),this.refiners.forEach(function(a){s=a.refine(i,s)}),s}static executeParser(e,t){let n=[],i=t.pattern(e),s=e.text,a=e.text,o=i.exec(a);for(;o;){let u=o.index+s.length-a.length;o.index=u;let l=t.extract(e,o);if(!l){a=s.substring(o.index+1),o=i.exec(a);continue}let c=null;l instanceof cn.ParsingResult?c=l:l instanceof cn.ParsingComponents?(c=e.createParsingResult(o.index,o[0]),c.start=l):c=e.createParsingResult(o.index,o[0],l),e.debug(()=>console.log(`${t.constructor.name} extracted result ${c}`)),n.push(c),a=s.substring(u+c.text.length),o=i.exec(a)}return n}};fn.Chrono=dn;var xs=class{constructor(e,t,n){this.text=e,this.reference=new cn.ReferenceWithTimezone(t),this.option=n!=null?n:{},this.refDate=this.reference.instant}createParsingComponents(e){return e instanceof cn.ParsingComponents?e:new cn.ParsingComponents(this.reference,e)}createParsingResult(e,t,n,i){let s=typeof t=="string"?t:this.text.substring(e,t),a=n?this.createParsingComponents(n):null,o=i?this.createParsingComponents(i):null;return new cn.ParsingResult(this.reference,e,s,a,o)}debug(e){this.option.debug&&(this.option.debug instanceof Function?this.option.debug(e):this.option.debug.debug(e))}};fn.ParsingContext=xs});var Wr=h(Tu=>{"use strict";Object.defineProperty(Tu,"__esModule",{value:!0});var bh=Se(),jv=new RegExp("([^\\d]|^)([0-3]{0,1}[0-9]{1})[\\/\\.\\-]([0-3]{0,1}[0-9]{1})(?:[\\/\\.\\-]([0-9]{4}|[0-9]{2}))?(\\W|$)","i"),Ss=1,vh=5,Eh=2,Rh=3,gu=4,_u=class{constructor(e){this.groupNumberMonth=e?Rh:Eh,this.groupNumberDay=e?Eh:Rh}pattern(){return jv}extract(e,t){if(t[Ss]=="/"||t[vh]=="/"){t.index+=t[0].length;return}let n=t.index+t[Ss].length,i=t[0].substr(t[Ss].length,t[0].length-t[Ss].length-t[vh].length);if(i.match(/^\d\.\d$/)||i.match(/^\d\.\d{1,2}\.\d{1,2}\s*$/)||!t[gu]&&t[0].indexOf("/")<0)return;let s=e.createParsingResult(n,i),a=parseInt(t[this.groupNumberMonth]),o=parseInt(t[this.groupNumberDay]);if((a<1||a>12)&&a>12)if(o>=1&&o<=12&&a<=31)[o,a]=[a,o];else return null;if(o<1||o>31)return null;if(s.start.assign("day",o),s.start.assign("month",a),t[gu]){let u=parseInt(t[gu]),l=bh.findMostLikelyADYear(u);s.start.assign("year",l)}else{let u=bh.findYearClosestToRef(e.refDate,o,a);s.start.imply("year",u)}return s}};Tu.default=_u});var Mh=h(vu=>{"use strict";Object.defineProperty(vu,"__esModule",{value:!0});var wh=Ie(),Bv=he(),Gv=R(),Hv=st(),zv=new RegExp(`(this|last|past|next|after|\\+|-)\\s*(${wh.TIME_UNITS_PATTERN})(?=\\W|$)`,"i"),bu=class extends Gv.AbstractParserWithWordBoundaryChecking{innerPattern(){return zv}innerExtract(e,t){let n=t[1].toLowerCase(),i=wh.parseTimeUnits(t[2]);switch(n){case"last":case"past":case"-":i=Hv.reverseTimeUnits(i);break}return Bv.ParsingComponents.createRelativeFromReference(e.reference,i)}};vu.default=bu});var Ph=h(wu=>{"use strict";Object.defineProperty(wu,"__esModule",{value:!0});var Kv=an(),Eu=he(),Vv=Ie(),Zv=st();function Dh(r){return r.text.match(/\s+(before|from)$/i)!=null}function Xv(r){return r.text.match(/\s+(after|since)$/i)!=null}var Ru=class extends Kv.MergingRefiner{patternBetween(){return/^\s*$/i}shouldMergeResults(e,t,n){return!e.match(this.patternBetween())||!Dh(t)&&!Xv(t)?!1:!!n.start.get("day")&&!!n.start.get("month")&&!!n.start.get("year")}mergeResults(e,t,n){let i=Vv.parseTimeUnits(t.text);Dh(t)&&(i=Zv.reverseTimeUnits(i));let s=Eu.ParsingComponents.createRelativeFromReference(new Eu.ReferenceWithTimezone(n.start.date()),i);return new Eu.ParsingResult(n.reference,t.index,`${t.text}${e}${n.text}`,s)}};wu.default=Ru});var yu=h(Te=>{"use strict";var we=Te&&Te.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Te,"__esModule",{value:!0});Te.createConfiguration=Te.createCasualConfiguration=Te.parseDate=Te.parse=Te.GB=Te.strict=Te.casual=void 0;var Qv=we(Dp()),Jv=we(Cp()),e1=we(Fp()),t1=we(Lp()),r1=we(jp()),n1=we(Bp()),i1=we(Hp()),s1=we(zp()),a1=we(Kp()),o1=we(Vp()),u1=we(Qp()),l1=Bt(),c1=we(dh()),d1=we(fh()),f1=we(yh()),p1=we(Th()),Mu=yt(),h1=we(Wr()),m1=we(Mh()),y1=we(Ph());Te.casual=new Mu.Chrono(Oh(!1));Te.strict=new Mu.Chrono(Is(!0,!1));Te.GB=new Mu.Chrono(Is(!1,!0));function g1(r,e,t){return Te.casual.parse(r,e,t)}Te.parse=g1;function _1(r,e,t){return Te.casual.parseDate(r,e,t)}Te.parseDate=_1;function Oh(r=!1){let e=Is(!1,r);return e.parsers.unshift(new c1.default),e.parsers.unshift(new d1.default),e.parsers.unshift(new t1.default),e.parsers.unshift(new p1.default),e.parsers.unshift(new m1.default),e}Te.createCasualConfiguration=Oh;function Is(r=!0,e=!1){return l1.includeCommonConfiguration({parsers:[new h1.default(e),new Qv.default,new Jv.default,new e1.default,new f1.default,new r1.default,new n1.default,new i1.default(r),new s1.default(r),new a1.default(r)],refiners:[new y1.default,new u1.default,new o1.default]},r)}Te.createConfiguration=Is});var Ah=h(Pu=>{"use strict";Object.defineProperty(Pu,"__esModule",{value:!0});var T1=Ur(),Du=class extends T1.AbstractTimeExpressionParser{primaryPrefix(){return"(?:(?:um|von)\\s*)?"}followingPhase(){return"\\s*(?:\\-|\\\u2013|\\~|\\\u301C|bis)\\s*"}extractPrimaryTimeComponents(e,t){return t[0].match(/^\s*\d{4}\s*$/)?null:super.extractPrimaryTimeComponents(e,t)}};Pu.default=Du});var Xn=h(re=>{"use strict";Object.defineProperty(re,"__esModule",{value:!0});re.parseTimeUnits=re.TIME_UNITS_PATTERN=re.parseYear=re.YEAR_PATTERN=re.parseNumberPattern=re.NUMBER_PATTERN=re.TIME_UNIT_DICTIONARY=re.INTEGER_WORD_DICTIONARY=re.MONTH_DICTIONARY=re.WEEKDAY_DICTIONARY=void 0;var Ou=Q(),b1=Se();re.WEEKDAY_DICTIONARY={sonntag:0,so:0,montag:1,mo:1,dienstag:2,di:2,mittwoch:3,mi:3,donnerstag:4,do:4,freitag:5,fr:5,samstag:6,sa:6};re.MONTH_DICTIONARY={januar:1,j\u00E4nner:1,janner:1,jan:1,"jan.":1,februar:2,feber:2,feb:2,"feb.":2,m\u00E4rz:3,maerz:3,m\u00E4r:3,"m\xE4r.":3,mrz:3,"mrz.":3,april:4,apr:4,"apr.":4,mai:5,juni:6,jun:6,"jun.":6,juli:7,jul:7,"jul.":7,august:8,aug:8,"aug.":8,september:9,sep:9,"sep.":9,sept:9,"sept.":9,oktober:10,okt:10,"okt.":10,november:11,nov:11,"nov.":11,dezember:12,dez:12,"dez.":12};re.INTEGER_WORD_DICTIONARY={eins:1,eine:1,einem:1,einen:1,einer:1,zwei:2,drei:3,vier:4,f\u00FCnf:5,fuenf:5,sechs:6,sieben:7,acht:8,neun:9,zehn:10,elf:11,zw\u00F6lf:12,zwoelf:12};re.TIME_UNIT_DICTIONARY={sek:"second",sekunde:"second",sekunden:"second",min:"minute",minute:"minute",minuten:"minute",h:"hour",std:"hour",stunde:"hour",stunden:"hour",tag:"d",tage:"d",tagen:"d",woche:"week",wochen:"week",monat:"month",monate:"month",monaten:"month",monats:"month",quartal:"quarter",quartals:"quarter",quartale:"quarter",quartalen:"quarter",a:"year",j:"year",jr:"year",jahr:"year",jahre:"year",jahren:"year",jahres:"year"};re.NUMBER_PATTERN=`(?:${Ou.matchAnyPattern(re.INTEGER_WORD_DICTIONARY)}|[0-9]+|[0-9]+\\.[0-9]+|half(?:\\s*an?)?|an?\\b(?:\\s*few)?|few|several|a?\\s*couple\\s*(?:of)?)`;function Nh(r){let e=r.toLowerCase();return re.INTEGER_WORD_DICTIONARY[e]!==void 0?re.INTEGER_WORD_DICTIONARY[e]:e==="a"||e==="an"?1:e.match(/few/)?3:e.match(/half/)?.5:e.match(/couple/)?2:e.match(/several/)?7:parseFloat(e)}re.parseNumberPattern=Nh;re.YEAR_PATTERN="(?:[0-9]{1,4}(?:\\s*[vn]\\.?\\s*(?:C(?:hr)?|(?:u\\.?|d\\.?(?:\\s*g\\.?)?)?\\s*Z)\\.?|\\s*(?:u\\.?|d\\.?(?:\\s*g\\.)?)\\s*Z\\.?)?)";function v1(r){if(/v/i.test(r))return-parseInt(r.replace(/[^0-9]+/gi,""));if(/n/i.test(r))return parseInt(r.replace(/[^0-9]+/gi,""));if(/z/i.test(r))return parseInt(r.replace(/[^0-9]+/gi,""));let e=parseInt(r);return b1.findMostLikelyADYear(e)}re.parseYear=v1;var Ch=`(${re.NUMBER_PATTERN})\\s{0,5}(${Ou.matchAnyPattern(re.TIME_UNIT_DICTIONARY)})\\s{0,5}`,kh=new RegExp(Ch,"i");re.TIME_UNITS_PATTERN=Ou.repeatedTimeunitPattern("",Ch);function E1(r){let e={},t=r,n=kh.exec(t);for(;n;)R1(e,n),t=t.substring(n[0].length),n=kh.exec(t);return e}re.parseTimeUnits=E1;function R1(r,e){let t=Nh(e[1]),n=re.TIME_UNIT_DICTIONARY[e[2].toLowerCase()];r[n]=t}});var Sh=h(ku=>{"use strict";Object.defineProperty(ku,"__esModule",{value:!0});var xh=Xn(),w1=Q(),M1=R(),D1=qr(),P1=new RegExp(`(?:(?:\\,|\\(|\\\uFF08)\\s*)?(?:a[mn]\\s*?)?(?:(diese[mn]|letzte[mn]|n(?:\xE4|ae)chste[mn])\\s*)?(${w1.matchAnyPattern(xh.WEEKDAY_DICTIONARY)})(?:\\s*(?:\\,|\\)|\\\uFF09))?(?:\\s*(diese|letzte|n(?:\xE4|ae)chste)\\s*woche)?(?=\\W|$)`,"i"),O1=1,A1=3,k1=2,Au=class extends M1.AbstractParserWithWordBoundaryChecking{innerPattern(){return P1}innerExtract(e,t){let n=t[k1].toLowerCase(),i=xh.WEEKDAY_DICTIONARY[n],s=t[O1],a=t[A1],o=s||a;o=o||"",o=o.toLowerCase();let u=null;o.match(/letzte/)?u="last":o.match(/chste/)?u="next":o.match(/diese/)&&(u="this");let l=D1.toDayJSWeekday(e.refDate,i,u);return e.createParsingComponents().assign("weekday",i).imply("day",l.date()).imply("month",l.month()+1).imply("year",l.year())}};ku.default=Au});var qh=h(Nu=>{"use strict";Object.defineProperty(Nu,"__esModule",{value:!0});var _r=Ee(),N1=new RegExp("(^|\\s|T)(?:(?:um|von)\\s*)?(\\d{1,2})(?:h|:)?(?:(\\d{1,2})(?:m|:)?)?(?:(\\d{1,2})(?:s)?)?(?:\\s*Uhr)?(?:\\s*(morgens|vormittags|nachmittags|abends|nachts|am\\s+(?:Morgen|Vormittag|Nachmittag|Abend)|in\\s+der\\s+Nacht))?(?=\\W|$)","i"),C1=new RegExp("^\\s*(\\-|\\\u2013|\\~|\\\u301C|bis(?:\\s+um)?|\\?)\\s*(\\d{1,2})(?:h|:)?(?:(\\d{1,2})(?:m|:)?)?(?:(\\d{1,2})(?:s)?)?(?:\\s*Uhr)?(?:\\s*(morgens|vormittags|nachmittags|abends|nachts|am\\s+(?:Morgen|Vormittag|Nachmittag|Abend)|in\\s+der\\s+Nacht))?(?=\\W|$)","i"),x1=2,Ih=3,Uh=4,Fh=5,pn=class{pattern(e){return N1}extract(e,t){let n=e.createParsingResult(t.index+t[1].length,t[0].substring(t[1].length));if(n.text.match(/^\d{4}$/)||(n.start=pn.extractTimeComponent(n.start.clone(),t),!n.start))return t.index+=t[0].length,null;let i=e.text.substring(t.index+t[0].length),s=C1.exec(i);return s&&(n.end=pn.extractTimeComponent(n.start.clone(),s),n.end&&(n.text+=s[0])),n}static extractTimeComponent(e,t){let n=0,i=0,s=null;if(n=parseInt(t[x1]),t[Ih]!=null&&(i=parseInt(t[Ih])),i>=60||n>24)return null;if(n>=12&&(s=_r.Meridiem.PM),t[Fh]!=null){if(n>12)return null;let a=t[Fh].toLowerCase();a.match(/morgen|vormittag/)&&(s=_r.Meridiem.AM,n==12&&(n=0)),a.match(/nachmittag|abend/)&&(s=_r.Meridiem.PM,n!=12&&(n+=12)),a.match(/nacht/)&&(n==12?(s=_r.Meridiem.AM,n=0):n<6?s=_r.Meridiem.AM:(s=_r.Meridiem.PM,n+=12))}if(e.assign("hour",n),e.assign("minute",i),s!==null?e.assign("meridiem",s):n<12?e.imply("meridiem",_r.Meridiem.AM):e.imply("meridiem",_r.Meridiem.PM),t[Uh]!=null){let a=parseInt(t[Uh]);if(a>=60)return null;e.assign("second",a)}return e}};Nu.default=pn});var Wh=h(Qn=>{"use strict";var S1=Qn&&Qn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Qn,"__esModule",{value:!0});var I1=S1(At()),Cu=class extends I1.default{patternBetween(){return/^\s*(bis(?:\s*(?:am|zum))?|-)\s*$/i}};Qn.default=Cu});var Lh=h(Jn=>{"use strict";var U1=Jn&&Jn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Jn,"__esModule",{value:!0});var F1=U1(jt()),xu=class extends F1.default{patternBetween(){return new RegExp("^\\s*(T|um|am|,|-)?\\s*$")}};Jn.default=xu});var Su=h(ti=>{"use strict";var q1=ti&&ti.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ti,"__esModule",{value:!0});var W1=q1(K()),Lr=Ee(),L1=R(),Y1=it(),$1=st(),ei=class extends L1.AbstractParserWithWordBoundaryChecking{innerPattern(e){return/(diesen)?\s*(morgen|vormittag|mittags?|nachmittag|abend|nacht|mitternacht)(?=\W|$)/i}innerExtract(e,t){let n=W1.default(e.refDate),i=t[2].toLowerCase(),s=e.createParsingComponents();return Y1.implySimilarTime(s,n),ei.extractTimeComponents(s,i)}static extractTimeComponents(e,t){switch(t){case"morgen":e.imply("hour",6),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Lr.Meridiem.AM);break;case"vormittag":e.imply("hour",9),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Lr.Meridiem.AM);break;case"mittag":case"mittags":e.imply("hour",12),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Lr.Meridiem.AM);break;case"nachmittag":e.imply("hour",15),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Lr.Meridiem.PM);break;case"abend":e.imply("hour",18),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Lr.Meridiem.PM);break;case"nacht":e.imply("hour",22),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Lr.Meridiem.PM);break;case"mitternacht":e.get("hour")>1&&(e=$1.addImpliedTimeUnits(e,{day:1})),e.imply("hour",0),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Lr.Meridiem.AM);break}return e}};ti.default=ei});var jh=h(gt=>{"use strict";var j1=gt&>.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),B1=gt&>.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),G1=gt&>.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&j1(e,r,t);return B1(e,r),e},$h=gt&>.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(gt,"__esModule",{value:!0});var H1=$h(K()),z1=R(),Yr=it(),K1=$h(Su()),Yh=G1(Ht()),V1=new RegExp("(jetzt|heute|morgen|\xFCbermorgen|uebermorgen|gestern|vorgestern|letzte\\s*nacht)(?:\\s*(morgen|vormittag|mittags?|nachmittag|abend|nacht|mitternacht))?(?=\\W|$)","i"),Z1=1,X1=2,Iu=class extends z1.AbstractParserWithWordBoundaryChecking{innerPattern(e){return V1}innerExtract(e,t){let n=H1.default(e.refDate),i=(t[Z1]||"").toLowerCase(),s=(t[X1]||"").toLowerCase(),a=e.createParsingComponents();switch(i){case"jetzt":a=Yh.now(e.reference);break;case"heute":a=Yh.today(e.reference);break;case"morgen":Yr.assignTheNextDay(a,n);break;case"\xFCbermorgen":case"uebermorgen":n=n.add(1,"day"),Yr.assignTheNextDay(a,n);break;case"gestern":n=n.add(-1,"day"),Yr.assignSimilarDate(a,n),Yr.implySimilarTime(a,n);break;case"vorgestern":n=n.add(-2,"day"),Yr.assignSimilarDate(a,n),Yr.implySimilarTime(a,n);break;default:i.match(/letzte\s*nacht/)&&(n.hour()>6&&(n=n.add(-1,"day")),Yr.assignSimilarDate(a,n),a.imply("hour",0));break}return s&&(a=K1.default.extractTimeComponents(a,s)),a}};gt.default=Iu});var Vh=h(Fu=>{"use strict";Object.defineProperty(Fu,"__esModule",{value:!0});var Q1=Se(),zh=Xn(),Kh=Xn(),J1=Q(),eE=R(),tE=new RegExp(`(?:am\\s*?)?(?:den\\s*?)?([0-9]{1,2})\\.(?:\\s*(?:bis(?:\\s*(?:am|zum))?|\\-|\\\u2013|\\s)\\s*([0-9]{1,2})\\.?)?\\s*(${J1.matchAnyPattern(zh.MONTH_DICTIONARY)})(?:(?:-|/|,?\\s*)(${Kh.YEAR_PATTERN}(?![^\\s]\\d)))?(?=\\W|$)`,"i"),Bh=1,Gh=2,rE=3,Hh=4,Uu=class extends eE.AbstractParserWithWordBoundaryChecking{innerPattern(){return tE}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=zh.MONTH_DICTIONARY[t[rE].toLowerCase()],s=parseInt(t[Bh]);if(s>31)return t.index=t.index+t[Bh].length,null;if(n.start.assign("month",i),n.start.assign("day",s),t[Hh]){let a=Kh.parseYear(t[Hh]);n.start.assign("year",a)}else{let a=Q1.findYearClosestToRef(e.refDate,s,i);n.start.imply("year",a)}if(t[Gh]){let a=parseInt(t[Gh]);n.end=n.start.clone(),n.end.assign("day",a)}return n}};Fu.default=Uu});var Zh=h(Wu=>{"use strict";Object.defineProperty(Wu,"__esModule",{value:!0});var Us=Xn(),nE=he(),iE=R(),sE=st(),aE=Q(),qu=class extends iE.AbstractParserWithWordBoundaryChecking{constructor(){super()}innerPattern(){return new RegExp(`(?:\\s*((?:n\xE4chste|kommende|folgende|letzte|vergangene|vorige|vor(?:her|an)gegangene)(?:s|n|m|r)?|vor|in)\\s*)?(${Us.NUMBER_PATTERN})?(?:\\s*(n\xE4chste|kommende|folgende|letzte|vergangene|vorige|vor(?:her|an)gegangene)(?:s|n|m|r)?)?\\s*(${aE.matchAnyPattern(Us.TIME_UNIT_DICTIONARY)})`,"i")}innerExtract(e,t){let n=t[2]?Us.parseNumberPattern(t[2]):1,i=Us.TIME_UNIT_DICTIONARY[t[4].toLowerCase()],s={};s[i]=n;let a=t[1]||t[3]||"";if(a=a.toLowerCase(),!!a)return(/vor/.test(a)||/letzte/.test(a)||/vergangen/.test(a))&&(s=sE.reverseTimeUnits(s)),nE.ParsingComponents.createRelativeFromReference(e.reference,s)}};Wu.default=qu});var Jh=h(Me=>{"use strict";var _t=Me&&Me.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Me,"__esModule",{value:!0});Me.createConfiguration=Me.createCasualConfiguration=Me.parseDate=Me.parse=Me.strict=Me.casual=void 0;var oE=Bt(),Xh=yt(),uE=_t(Wr()),lE=_t(ou()),cE=_t(Ah()),dE=_t(Sh()),fE=_t(qh()),pE=_t(Wh()),hE=_t(Lh()),mE=_t(jh()),yE=_t(Su()),gE=_t(Vh()),_E=_t(Zh());Me.casual=new Xh.Chrono(Qh());Me.strict=new Xh.Chrono(Lu(!0));function TE(r,e,t){return Me.casual.parse(r,e,t)}Me.parse=TE;function bE(r,e,t){return Me.casual.parseDate(r,e,t)}Me.parseDate=bE;function Qh(r=!0){let e=Lu(!1,r);return e.parsers.unshift(new yE.default),e.parsers.unshift(new mE.default),e.parsers.unshift(new _E.default),e}Me.createCasualConfiguration=Qh;function Lu(r=!0,e=!0){return oE.includeCommonConfiguration({parsers:[new lE.default,new uE.default(e),new cE.default,new fE.default,new gE.default,new dE.default],refiners:[new pE.default,new hE.default]},r)}Me.createConfiguration=Lu});var tm=h(Tt=>{"use strict";var vE=Tt&&Tt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),EE=Tt&&Tt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),RE=Tt&&Tt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&vE(e,r,t);return EE(e,r),e},wE=Tt&&Tt.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Tt,"__esModule",{value:!0});var ME=wE(K()),DE=Ee(),PE=R(),em=it(),Fs=RE(Ht()),Yu=class extends PE.AbstractParserWithWordBoundaryChecking{innerPattern(e){return/(maintenant|aujourd'hui|demain|hier|cette\s*nuit|la\s*veille)(?=\W|$)/i}innerExtract(e,t){let n=ME.default(e.refDate),i=t[0].toLowerCase(),s=e.createParsingComponents();switch(i){case"maintenant":return Fs.now(e.reference);case"aujourd'hui":return Fs.today(e.reference);case"hier":return Fs.yesterday(e.reference);case"demain":return Fs.tomorrow(e.reference);default:i.match(/cette\s*nuit/)?(em.assignSimilarDate(s,n),s.imply("hour",22),s.imply("meridiem",DE.Meridiem.PM)):i.match(/la\s*veille/)&&(n=n.add(-1,"day"),em.assignSimilarDate(s,n),s.imply("hour",0))}return s}};Tt.default=Yu});var rm=h(ju=>{"use strict";Object.defineProperty(ju,"__esModule",{value:!0});var ri=Ee(),OE=R(),$u=class extends OE.AbstractParserWithWordBoundaryChecking{innerPattern(e){return/(cet?)?\s*(matin|soir|après-midi|aprem|a midi|à minuit)(?=\W|$)/i}innerExtract(e,t){let n=t[2].toLowerCase(),i=e.createParsingComponents();switch(n){case"apr\xE8s-midi":case"aprem":i.imply("hour",14),i.imply("minute",0),i.imply("meridiem",ri.Meridiem.PM);break;case"soir":i.imply("hour",18),i.imply("minute",0),i.imply("meridiem",ri.Meridiem.PM);break;case"matin":i.imply("hour",8),i.imply("minute",0),i.imply("meridiem",ri.Meridiem.AM);break;case"a midi":i.imply("hour",12),i.imply("minute",0),i.imply("meridiem",ri.Meridiem.AM);break;case"\xE0 minuit":i.imply("hour",0),i.imply("meridiem",ri.Meridiem.AM);break}return i}};ju.default=$u});var nm=h(Gu=>{"use strict";Object.defineProperty(Gu,"__esModule",{value:!0});var AE=Ur(),Bu=class extends AE.AbstractTimeExpressionParser{primaryPrefix(){return"(?:(?:[\xE0a])\\s*)?"}followingPhase(){return"\\s*(?:\\-|\\\u2013|\\~|\\\u301C|[\xE0a]|\\?)\\s*"}extractPrimaryTimeComponents(e,t){return t[0].match(/^\s*\d{4}\s*$/)?null:super.extractPrimaryTimeComponents(e,t)}};Gu.default=Bu});var im=h(ni=>{"use strict";var kE=ni&&ni.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ni,"__esModule",{value:!0});var NE=kE(jt()),Hu=class extends NE.default{patternBetween(){return new RegExp("^\\s*(T|\xE0|a|vers|de|,|-)?\\s*$")}};ni.default=Hu});var sm=h(ii=>{"use strict";var CE=ii&&ii.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ii,"__esModule",{value:!0});var xE=CE(At()),zu=class extends xE.default{patternBetween(){return/^\s*(à|a|-)\s*$/i}};ii.default=zu});var Tr=h(V=>{"use strict";Object.defineProperty(V,"__esModule",{value:!0});V.parseTimeUnits=V.TIME_UNITS_PATTERN=V.parseYear=V.YEAR_PATTERN=V.parseOrdinalNumberPattern=V.ORDINAL_NUMBER_PATTERN=V.parseNumberPattern=V.NUMBER_PATTERN=V.TIME_UNIT_DICTIONARY=V.INTEGER_WORD_DICTIONARY=V.MONTH_DICTIONARY=V.WEEKDAY_DICTIONARY=void 0;var Ku=Q();V.WEEKDAY_DICTIONARY={dimanche:0,dim:0,lundi:1,lun:1,mardi:2,mar:2,mercredi:3,mer:3,jeudi:4,jeu:4,vendredi:5,ven:5,samedi:6,sam:6};V.MONTH_DICTIONARY={janvier:1,jan:1,"jan.":1,f\u00E9vrier:2,f\u00E9v:2,"f\xE9v.":2,fevrier:2,fev:2,"fev.":2,mars:3,mar:3,"mar.":3,avril:4,avr:4,"avr.":4,mai:5,juin:6,jun:6,juillet:7,juil:7,jul:7,"jul.":7,ao\u00FBt:8,aout:8,septembre:9,sep:9,"sep.":9,sept:9,"sept.":9,octobre:10,oct:10,"oct.":10,novembre:11,nov:11,"nov.":11,d\u00E9cembre:12,decembre:12,dec:12,"dec.":12};V.INTEGER_WORD_DICTIONARY={un:1,deux:2,trois:3,quatre:4,cinq:5,six:6,sept:7,huit:8,neuf:9,dix:10,onze:11,douze:12,treize:13};V.TIME_UNIT_DICTIONARY={sec:"second",seconde:"second",secondes:"second",min:"minute",mins:"minute",minute:"minute",minutes:"minute",h:"hour",hr:"hour",hrs:"hour",heure:"hour",heures:"hour",jour:"d",jours:"d",semaine:"week",semaines:"week",mois:"month",trimestre:"quarter",trimestres:"quarter",ans:"year",ann\u00E9e:"year",ann\u00E9es:"year"};V.NUMBER_PATTERN=`(?:${Ku.matchAnyPattern(V.INTEGER_WORD_DICTIONARY)}|[0-9]+|[0-9]+\\.[0-9]+|une?\\b|quelques?|demi-?)`;function om(r){let e=r.toLowerCase();return V.INTEGER_WORD_DICTIONARY[e]!==void 0?V.INTEGER_WORD_DICTIONARY[e]:e==="une"||e==="un"?1:e.match(/quelques?/)?3:e.match(/demi-?/)?.5:parseFloat(e)}V.parseNumberPattern=om;V.ORDINAL_NUMBER_PATTERN="(?:[0-9]{1,2}(?:er)?)";function SE(r){let e=r.toLowerCase();return e=e.replace(/(?:er)$/i,""),parseInt(e)}V.parseOrdinalNumberPattern=SE;V.YEAR_PATTERN="(?:[1-9][0-9]{0,3}\\s*(?:AC|AD|p\\.\\s*C(?:hr?)?\\.\\s*n\\.)|[1-2][0-9]{3}|[5-9][0-9])";function IE(r){if(/AC/i.test(r))return r=r.replace(/BC/i,""),-parseInt(r);if(/AD/i.test(r)||/C/i.test(r))return r=r.replace(/[^\d]+/i,""),parseInt(r);let e=parseInt(r);return e<100&&(e>50?e=e+1900:e=e+2e3),e}V.parseYear=IE;var um=`(${V.NUMBER_PATTERN})\\s{0,5}(${Ku.matchAnyPattern(V.TIME_UNIT_DICTIONARY)})\\s{0,5}`,am=new RegExp(um,"i");V.TIME_UNITS_PATTERN=Ku.repeatedTimeunitPattern("",um);function UE(r){let e={},t=r,n=am.exec(t);for(;n;)FE(e,n),t=t.substring(n[0].length),n=am.exec(t);return e}V.parseTimeUnits=UE;function FE(r,e){let t=om(e[1]),n=V.TIME_UNIT_DICTIONARY[e[2].toLowerCase()];r[n]=t}});var cm=h(Zu=>{"use strict";Object.defineProperty(Zu,"__esModule",{value:!0});var lm=Tr(),qE=Q(),WE=R(),LE=qr(),YE=new RegExp(`(?:(?:\\,|\\(|\\\uFF08)\\s*)?(?:(?:ce)\\s*)?(${qE.matchAnyPattern(lm.WEEKDAY_DICTIONARY)})(?:\\s*(?:\\,|\\)|\\\uFF09))?(?:\\s*(dernier|prochain)\\s*)?(?=\\W|\\d|$)`,"i"),$E=1,jE=2,Vu=class extends WE.AbstractParserWithWordBoundaryChecking{innerPattern(){return YE}innerExtract(e,t){let n=t[$E].toLowerCase(),i=lm.WEEKDAY_DICTIONARY[n];if(i===void 0)return null;let s=t[jE];s=s||"",s=s.toLowerCase();let a=null;s=="dernier"?a="last":s=="prochain"&&(a="next");let o=LE.toDayJSWeekday(e.refDate,i,a);return e.createParsingComponents().assign("weekday",i).imply("day",o.date()).imply("month",o.month()+1).imply("year",o.year())}};Zu.default=Vu});var hm=h(Xu=>{"use strict";Object.defineProperty(Xu,"__esModule",{value:!0});var si=Ee(),BE=new RegExp("(^|\\s|T)(?:(?:[\xE0a])\\s*)?(\\d{1,2})(?:h|:)?(?:(\\d{1,2})(?:m|:)?)?(?:(\\d{1,2})(?:s|:)?)?(?:\\s*(A\\.M\\.|P\\.M\\.|AM?|PM?))?(?=\\W|$)","i"),GE=new RegExp("^\\s*(\\-|\\\u2013|\\~|\\\u301C|[\xE0a]|\\?)\\s*(\\d{1,2})(?:h|:)?(?:(\\d{1,2})(?:m|:)?)?(?:(\\d{1,2})(?:s|:)?)?(?:\\s*(A\\.M\\.|P\\.M\\.|AM?|PM?))?(?=\\W|$)","i"),HE=2,dm=3,fm=4,pm=5,hn=class{pattern(e){return BE}extract(e,t){let n=e.createParsingResult(t.index+t[1].length,t[0].substring(t[1].length));if(n.text.match(/^\d{4}$/)||(n.start=hn.extractTimeComponent(n.start.clone(),t),!n.start))return t.index+=t[0].length,null;let i=e.text.substring(t.index+t[0].length),s=GE.exec(i);return s&&(n.end=hn.extractTimeComponent(n.start.clone(),s),n.end&&(n.text+=s[0])),n}static extractTimeComponent(e,t){let n=0,i=0,s=null;if(n=parseInt(t[HE]),t[dm]!=null&&(i=parseInt(t[dm])),i>=60||n>24)return null;if(n>=12&&(s=si.Meridiem.PM),t[pm]!=null){if(n>12)return null;let a=t[pm][0].toLowerCase();a=="a"&&(s=si.Meridiem.AM,n==12&&(n=0)),a=="p"&&(s=si.Meridiem.PM,n!=12&&(n+=12))}if(e.assign("hour",n),e.assign("minute",i),s!==null?e.assign("meridiem",s):n<12?e.imply("meridiem",si.Meridiem.AM):e.imply("meridiem",si.Meridiem.PM),t[fm]!=null){let a=parseInt(t[fm]);if(a>=60)return null;e.assign("second",a)}return e}};Xu.default=hn});var bm=h(Ju=>{"use strict";Object.defineProperty(Ju,"__esModule",{value:!0});var zE=Se(),_m=Tr(),Tm=Tr(),qs=Tr(),KE=Q(),VE=R(),ZE=new RegExp(`(?:on\\s*?)?(${qs.ORDINAL_NUMBER_PATTERN})(?:\\s*(?:au|\\-|\\\u2013|jusqu'au?|\\s)\\s*(${qs.ORDINAL_NUMBER_PATTERN}))?(?:-|/|\\s*(?:de)?\\s*)(${KE.matchAnyPattern(_m.MONTH_DICTIONARY)})(?:(?:-|/|,?\\s*)(${Tm.YEAR_PATTERN}(?![^\\s]\\d)))?(?=\\W|$)`,"i"),mm=1,ym=2,XE=3,gm=4,Qu=class extends VE.AbstractParserWithWordBoundaryChecking{innerPattern(){return ZE}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=_m.MONTH_DICTIONARY[t[XE].toLowerCase()],s=qs.parseOrdinalNumberPattern(t[mm]);if(s>31)return t.index=t.index+t[mm].length,null;if(n.start.assign("month",i),n.start.assign("day",s),t[gm]){let a=Tm.parseYear(t[gm]);n.start.assign("year",a)}else{let a=zE.findYearClosestToRef(e.refDate,s,i);n.start.imply("year",a)}if(t[ym]){let a=qs.parseOrdinalNumberPattern(t[ym]);n.end=n.start.clone(),n.end.assign("day",a)}return n}};Ju.default=Qu});var Em=h(tl=>{"use strict";Object.defineProperty(tl,"__esModule",{value:!0});var vm=Tr(),QE=he(),JE=R(),e0=st(),el=class extends JE.AbstractParserWithWordBoundaryChecking{constructor(){super()}innerPattern(){return new RegExp(`il y a\\s*(${vm.TIME_UNITS_PATTERN})(?=(?:\\W|$))`,"i")}innerExtract(e,t){let n=vm.parseTimeUnits(t[1]),i=e0.reverseTimeUnits(n);return QE.ParsingComponents.createRelativeFromReference(e.reference,i)}};tl.default=el});var wm=h(nl=>{"use strict";Object.defineProperty(nl,"__esModule",{value:!0});var Rm=Tr(),t0=he(),r0=R(),rl=class extends r0.AbstractParserWithWordBoundaryChecking{innerPattern(){return new RegExp(`(?:dans|en|pour|pendant|de)\\s*(${Rm.TIME_UNITS_PATTERN})(?=\\W|$)`,"i")}innerExtract(e,t){let n=Rm.parseTimeUnits(t[1]);return t0.ParsingComponents.createRelativeFromReference(e.reference,n)}};nl.default=rl});var Mm=h(sl=>{"use strict";Object.defineProperty(sl,"__esModule",{value:!0});var Ws=Tr(),n0=he(),i0=R(),s0=st(),a0=Q(),il=class extends i0.AbstractParserWithWordBoundaryChecking{constructor(){super()}innerPattern(){return new RegExp(`(?:les?|la|l'|du|des?)\\s*(${Ws.NUMBER_PATTERN})?(?:\\s*(prochaine?s?|derni[e\xE8]re?s?|pass[\xE9e]e?s?|pr[\xE9e]c[\xE9e]dents?|suivante?s?))?\\s*(${a0.matchAnyPattern(Ws.TIME_UNIT_DICTIONARY)})(?:\\s*(prochaine?s?|derni[e\xE8]re?s?|pass[\xE9e]e?s?|pr[\xE9e]c[\xE9e]dents?|suivante?s?))?`,"i")}innerExtract(e,t){let n=t[1]?Ws.parseNumberPattern(t[1]):1,i=Ws.TIME_UNIT_DICTIONARY[t[3].toLowerCase()],s={};s[i]=n;let a=t[2]||t[4]||"";if(a=a.toLowerCase(),!!a)return(/derni[eè]re?s?/.test(a)||/pass[ée]e?s?/.test(a)||/pr[ée]c[ée]dents?/.test(a))&&(s=s0.reverseTimeUnits(s)),n0.ParsingComponents.createRelativeFromReference(e.reference,s)}};sl.default=il});var Om=h(De=>{"use strict";var at=De&&De.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(De,"__esModule",{value:!0});De.createConfiguration=De.createCasualConfiguration=De.parseDate=De.parse=De.strict=De.casual=void 0;var o0=Bt(),Dm=yt(),u0=at(tm()),l0=at(rm()),c0=at(Wr()),d0=at(nm()),f0=at(im()),p0=at(sm()),h0=at(cm()),m0=at(hm()),y0=at(bm()),g0=at(Em()),_0=at(wm()),T0=at(Mm());De.casual=new Dm.Chrono(Pm());De.strict=new Dm.Chrono(al(!0));function b0(r,e,t){return De.casual.parse(r,e,t)}De.parse=b0;function v0(r,e,t){return De.casual.parseDate(r,e,t)}De.parseDate=v0;function Pm(r=!0){let e=al(!1,r);return e.parsers.unshift(new u0.default),e.parsers.unshift(new l0.default),e.parsers.unshift(new T0.default),e}De.createCasualConfiguration=Pm;function al(r=!0,e=!0){return o0.includeCommonConfiguration({parsers:[new c0.default(e),new y0.default,new d0.default,new m0.default,new g0.default,new _0.default,new h0.default],refiners:[new f0.default,new p0.default]},r)}De.createConfiguration=al});var Am=h(Ls=>{"use strict";Object.defineProperty(Ls,"__esModule",{value:!0});Ls.toHankaku=void 0;function E0(r){return String(r).replace(/\u2019/g,"'").replace(/\u201D/g,'"').replace(/\u3000/g," ").replace(/\uFFE5/g,"\xA5").replace(/[\uFF01\uFF03-\uFF06\uFF08\uFF09\uFF0C-\uFF19\uFF1C-\uFF1F\uFF21-\uFF3B\uFF3D\uFF3F\uFF41-\uFF5B\uFF5D\uFF5E]/g,R0)}Ls.toHankaku=E0;function R0(r){return String.fromCharCode(r.charCodeAt(0)-65248)}});var Nm=h(ai=>{"use strict";var w0=ai&&ai.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ai,"__esModule",{value:!0});var ol=Am(),M0=Se(),D0=w0(K()),P0=/(?:(?:([同今本])|((昭和|平成|令和)?([0-90-9]{1,4}|元)))年\s*)?([0-90-9]{1,2})月\s*([0-90-9]{1,2})日/i,km=1,O0=2,ul=3,A0=4,k0=5,N0=6,ll=class{pattern(){return P0}extract(e,t){let n=parseInt(ol.toHankaku(t[k0])),i=parseInt(ol.toHankaku(t[N0])),s=e.createParsingComponents({day:i,month:n});if(t[km]&&t[km].match("\u540C|\u4ECA|\u672C")){let a=D0.default(e.refDate);s.assign("year",a.year())}if(t[O0]){let a=t[A0],o=a=="\u5143"?1:parseInt(ol.toHankaku(a));t[ul]=="\u4EE4\u548C"?o+=2018:t[ul]=="\u5E73\u6210"?o+=1988:t[ul]=="\u662D\u548C"&&(o+=1925),s.assign("year",o)}else{let a=M0.findYearClosestToRef(e.refDate,i,n);s.imply("year",a)}return s}};ai.default=ll});var Cm=h(oi=>{"use strict";var C0=oi&&oi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(oi,"__esModule",{value:!0});var x0=C0(At()),cl=class extends x0.default{patternBetween(){return/^\s*(から|ー|-)\s*$/i}};oi.default=cl});var Sm=h(bt=>{"use strict";var S0=bt&&bt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),I0=bt&&bt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),U0=bt&&bt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&S0(e,r,t);return I0(e,r),e},F0=bt&&bt.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(bt,"__esModule",{value:!0});var q0=F0(K()),xm=Ee(),dl=U0(Ht()),W0=/今日|当日|昨日|明日|今夜|今夕|今晩|今朝/i,fl=class{pattern(){return W0}extract(e,t){let n=t[0],i=q0.default(e.refDate),s=e.createParsingComponents();switch(n){case"\u6628\u65E5":return dl.yesterday(e.reference);case"\u660E\u65E5":return dl.tomorrow(e.reference);case"\u4ECA\u65E5":case"\u5F53\u65E5":return dl.today(e.reference)}return n=="\u4ECA\u591C"||n=="\u4ECA\u5915"||n=="\u4ECA\u6669"?(s.imply("hour",22),s.assign("meridiem",xm.Meridiem.PM)):n.match("\u4ECA\u671D")&&(s.imply("hour",6),s.assign("meridiem",xm.Meridiem.AM)),s.assign("day",i.date()),s.assign("month",i.month()+1),s.assign("year",i.year()),s}};bt.default=fl});var Fm=h(Pe=>{"use strict";var pl=Pe&&Pe.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Pe,"__esModule",{value:!0});Pe.createConfiguration=Pe.createCasualConfiguration=Pe.parseDate=Pe.parse=Pe.strict=Pe.casual=void 0;var L0=pl(Nm()),Y0=pl(Cm()),$0=pl(Sm()),Im=yt();Pe.casual=new Im.Chrono(Um());Pe.strict=new Im.Chrono(hl());function j0(r,e,t){return Pe.casual.parse(r,e,t)}Pe.parse=j0;function B0(r,e,t){return Pe.casual.parseDate(r,e,t)}Pe.parseDate=B0;function Um(){let r=hl();return r.parsers.unshift(new $0.default),r}Pe.createCasualConfiguration=Um;function hl(){return{parsers:[new L0.default],refiners:[new Y0.default]}}Pe.createConfiguration=hl});var Ys=h(Nt=>{"use strict";Object.defineProperty(Nt,"__esModule",{value:!0});Nt.parseYear=Nt.YEAR_PATTERN=Nt.MONTH_DICTIONARY=Nt.WEEKDAY_DICTIONARY=void 0;Nt.WEEKDAY_DICTIONARY={domingo:0,dom:0,segunda:1,"segunda-feira":1,seg:1,ter\u00E7a:2,"ter\xE7a-feira":2,ter:2,quarta:3,"quarta-feira":3,qua:3,quinta:4,"quinta-feira":4,qui:4,sexta:5,"sexta-feira":5,sex:5,s\u00E1bado:6,sabado:6,sab:6};Nt.MONTH_DICTIONARY={janeiro:1,jan:1,"jan.":1,fevereiro:2,fev:2,"fev.":2,mar\u00E7o:3,mar:3,"mar.":3,abril:4,abr:4,"abr.":4,maio:5,mai:5,"mai.":5,junho:6,jun:6,"jun.":6,julho:7,jul:7,"jul.":7,agosto:8,ago:8,"ago.":8,setembro:9,set:9,"set.":9,outubro:10,out:10,"out.":10,novembro:11,nov:11,"nov.":11,dezembro:12,dez:12,"dez.":12};Nt.YEAR_PATTERN="[0-9]{1,4}(?![^\\s]\\d)(?:\\s*[a|d]\\.?\\s*c\\.?|\\s*a\\.?\\s*d\\.?)?";function G0(r){if(r.match(/^[0-9]{1,4}$/)){let e=parseInt(r);return e<100&&(e>50?e=e+1900:e=e+2e3),e}return r.match(/a\.?\s*c\.?/i)?(r=r.replace(/a\.?\s*c\.?/i,""),-parseInt(r)):parseInt(r)}Nt.parseYear=G0});var Wm=h(yl=>{"use strict";Object.defineProperty(yl,"__esModule",{value:!0});var qm=Ys(),H0=Q(),z0=R(),K0=qr(),V0=new RegExp(`(?:(?:\\,|\\(|\\\uFF08)\\s*)?(?:(este|esta|passado|pr[o\xF3]ximo)\\s*)?(${H0.matchAnyPattern(qm.WEEKDAY_DICTIONARY)})(?:\\s*(?:\\,|\\)|\\\uFF09))?(?:\\s*(este|esta|passado|pr[\xF3o]ximo)\\s*semana)?(?=\\W|\\d|$)`,"i"),Z0=1,X0=2,Q0=3,ml=class extends z0.AbstractParserWithWordBoundaryChecking{innerPattern(){return V0}innerExtract(e,t){let n=t[X0].toLowerCase(),i=qm.WEEKDAY_DICTIONARY[n];if(i===void 0)return null;let s=t[Z0],a=t[Q0],o=s||a||"";o=o.toLowerCase();let u=null;o=="passado"?u="this":o=="pr\xF3ximo"||o=="proximo"?u="next":o=="este"&&(u="this");let l=K0.toDayJSWeekday(e.refDate,i,u);return e.createParsingComponents().assign("weekday",i).imply("day",l.date()).imply("month",l.month()+1).imply("year",l.year())}};yl.default=ml});var Lm=h(_l=>{"use strict";Object.defineProperty(_l,"__esModule",{value:!0});var J0=Ur(),gl=class extends J0.AbstractTimeExpressionParser{primaryPrefix(){return"(?:(?:ao?|\xE0s?|das|da|de|do)\\s*)?"}followingPhase(){return"\\s*(?:\\-|\\\u2013|\\~|\\\u301C|a(?:o)?|\\?)\\s*"}};_l.default=gl});var Ym=h(ui=>{"use strict";var eR=ui&&ui.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ui,"__esModule",{value:!0});var tR=eR(jt()),Tl=class extends tR.default{patternBetween(){return new RegExp("^\\s*(?:,|\xE0)?\\s*$")}};ui.default=Tl});var $m=h(li=>{"use strict";var rR=li&&li.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(li,"__esModule",{value:!0});var nR=rR(At()),bl=class extends nR.default{patternBetween(){return/^\s*(?:-)\s*$/i}};li.default=bl});var Km=h(El=>{"use strict";Object.defineProperty(El,"__esModule",{value:!0});var iR=Se(),Hm=Ys(),zm=Ys(),sR=Q(),aR=R(),oR=new RegExp(`([0-9]{1,2})(?:\xBA|\xAA|\xB0)?(?:\\s*(?:desde|de|\\-|\\\u2013|ao?|\\s)\\s*([0-9]{1,2})(?:\xBA|\xAA|\xB0)?)?\\s*(?:de)?\\s*(?:-|/|\\s*(?:de|,)?\\s*)(${sR.matchAnyPattern(Hm.MONTH_DICTIONARY)})(?:\\s*(?:de|,)?\\s*(${zm.YEAR_PATTERN}))?(?=\\W|$)`,"i"),jm=1,Bm=2,uR=3,Gm=4,vl=class extends aR.AbstractParserWithWordBoundaryChecking{innerPattern(){return oR}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=Hm.MONTH_DICTIONARY[t[uR].toLowerCase()],s=parseInt(t[jm]);if(s>31)return t.index=t.index+t[jm].length,null;if(n.start.assign("month",i),n.start.assign("day",s),t[Gm]){let a=zm.parseYear(t[Gm]);n.start.assign("year",a)}else{let a=iR.findYearClosestToRef(e.refDate,s,i);n.start.imply("year",a)}if(t[Bm]){let a=parseInt(t[Bm]);n.end=n.start.clone(),n.end.assign("day",a)}return n}};El.default=vl});var Vm=h(zt=>{"use strict";var lR=zt&&zt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),cR=zt&&zt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),dR=zt&&zt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&lR(e,r,t);return cR(e,r),e};Object.defineProperty(zt,"__esModule",{value:!0});var fR=R(),$s=dR(Ht()),Rl=class extends fR.AbstractParserWithWordBoundaryChecking{innerPattern(e){return/(agora|hoje|amanha|amanhã|ontem)(?=\W|$)/i}innerExtract(e,t){let n=t[0].toLowerCase(),i=e.createParsingComponents();switch(n){case"agora":return $s.now(e.reference);case"hoje":return $s.today(e.reference);case"amanha":case"amanh\xE3":return $s.tomorrow(e.reference);case"ontem":return $s.yesterday(e.reference)}return i}};zt.default=Rl});var Zm=h(ci=>{"use strict";var pR=ci&&ci.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ci,"__esModule",{value:!0});var js=Ee(),hR=R(),mR=it(),yR=pR(K()),wl=class extends hR.AbstractParserWithWordBoundaryChecking{innerPattern(){return/(?:esta\s*)?(manha|manhã|tarde|meia-noite|meio-dia|noite)(?=\W|$)/i}innerExtract(e,t){let n=yR.default(e.refDate),i=e.createParsingComponents();switch(t[1].toLowerCase()){case"tarde":i.imply("meridiem",js.Meridiem.PM),i.imply("hour",15);break;case"noite":i.imply("meridiem",js.Meridiem.PM),i.imply("hour",22);break;case"manha":case"manh\xE3":i.imply("meridiem",js.Meridiem.AM),i.imply("hour",6);break;case"meia-noite":mR.assignTheNextDay(i,n),i.imply("hour",0),i.imply("minute",0),i.imply("second",0);break;case"meio-dia":i.imply("meridiem",js.Meridiem.AM),i.imply("hour",12);break}return i}};ci.default=wl});var Jm=h(Oe=>{"use strict";var br=Oe&&Oe.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Oe,"__esModule",{value:!0});Oe.createConfiguration=Oe.createCasualConfiguration=Oe.parseDate=Oe.parse=Oe.strict=Oe.casual=void 0;var gR=Bt(),Xm=yt(),_R=br(Wr()),TR=br(Wm()),bR=br(Lm()),vR=br(Ym()),ER=br($m()),RR=br(Km()),wR=br(Vm()),MR=br(Zm());Oe.casual=new Xm.Chrono(Qm());Oe.strict=new Xm.Chrono(Ml(!0));function DR(r,e,t){return Oe.casual.parse(r,e,t)}Oe.parse=DR;function PR(r,e,t){return Oe.casual.parseDate(r,e,t)}Oe.parseDate=PR;function Qm(r=!0){let e=Ml(!1,r);return e.parsers.push(new wR.default),e.parsers.push(new MR.default),e}Oe.createCasualConfiguration=Qm;function Ml(r=!0,e=!0){return gR.includeCommonConfiguration({parsers:[new _R.default(e),new TR.default,new bR.default,new RR.default],refiners:[new vR.default,new ER.default]},r)}Oe.createConfiguration=Ml});var ey=h(di=>{"use strict";var OR=di&&di.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(di,"__esModule",{value:!0});var AR=OR(At()),Dl=class extends AR.default{patternBetween(){return/^\s*(tot|-)\s*$/i}};di.default=Dl});var ty=h(fi=>{"use strict";var kR=fi&&fi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(fi,"__esModule",{value:!0});var NR=kR(jt()),Pl=class extends NR.default{patternBetween(){return new RegExp("^\\s*(om|na|voor|in de|,|-)?\\s*$")}};fi.default=Pl});var ry=h(Kt=>{"use strict";var CR=Kt&&Kt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),xR=Kt&&Kt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),SR=Kt&&Kt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&CR(e,r,t);return xR(e,r),e};Object.defineProperty(Kt,"__esModule",{value:!0});var IR=R(),Bs=SR(Ht()),Ol=class extends IR.AbstractParserWithWordBoundaryChecking{innerPattern(e){return/(nu|vandaag|morgen|morgend|gisteren)(?=\W|$)/i}innerExtract(e,t){let n=t[0].toLowerCase(),i=e.createParsingComponents();switch(n){case"nu":return Bs.now(e.reference);case"vandaag":return Bs.today(e.reference);case"morgen":case"morgend":return Bs.tomorrow(e.reference);case"gisteren":return Bs.yesterday(e.reference)}return i}};Kt.default=Ol});var ny=h(pi=>{"use strict";var UR=pi&&pi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(pi,"__esModule",{value:!0});var Gs=Ee(),FR=R(),qR=UR(K()),WR=it(),LR=1,YR=2,Al=class extends FR.AbstractParserWithWordBoundaryChecking{innerPattern(){return/(deze)?\s*(namiddag|avond|middernacht|ochtend|middag|'s middags|'s avonds|'s ochtends)(?=\W|$)/i}innerExtract(e,t){let n=qR.default(e.refDate),i=e.createParsingComponents();switch(t[LR]==="deze"&&(i.assign("day",e.refDate.getDate()),i.assign("month",e.refDate.getMonth()+1),i.assign("year",e.refDate.getFullYear())),t[YR].toLowerCase()){case"namiddag":case"'s namiddags":i.imply("meridiem",Gs.Meridiem.PM),i.imply("hour",15);break;case"avond":case"'s avonds'":i.imply("meridiem",Gs.Meridiem.PM),i.imply("hour",20);break;case"middernacht":WR.assignTheNextDay(i,n),i.imply("hour",0),i.imply("minute",0),i.imply("second",0);break;case"ochtend":case"'s ochtends":i.imply("meridiem",Gs.Meridiem.AM),i.imply("hour",6);break;case"middag":case"'s middags":i.imply("meridiem",Gs.Meridiem.AM),i.imply("hour",12);break}return i}};pi.default=Al});var Qe=h(j=>{"use strict";Object.defineProperty(j,"__esModule",{value:!0});j.parseTimeUnits=j.TIME_UNITS_PATTERN=j.parseYear=j.YEAR_PATTERN=j.parseOrdinalNumberPattern=j.ORDINAL_NUMBER_PATTERN=j.parseNumberPattern=j.NUMBER_PATTERN=j.TIME_UNIT_DICTIONARY=j.ORDINAL_WORD_DICTIONARY=j.INTEGER_WORD_DICTIONARY=j.MONTH_DICTIONARY=j.WEEKDAY_DICTIONARY=void 0;var Hs=Q(),$R=Se();j.WEEKDAY_DICTIONARY={zondag:0,zon:0,"zon.":0,zo:0,"zo.":0,maandag:1,ma:1,"ma.":1,dinsdag:2,din:2,"din.":2,di:2,"di.":2,woensdag:3,woe:3,"woe.":3,wo:3,"wo.":3,donderdag:4,dond:4,"dond.":4,do:4,"do.":4,vrijdag:5,vrij:5,"vrij.":5,vr:5,"vr.":5,zaterdag:6,zat:6,"zat.":6,za:6,"za.":6};j.MONTH_DICTIONARY={januari:1,jan:1,"jan.":1,februari:2,feb:2,"feb.":2,maart:3,mar:3,"mar.":3,april:4,apr:4,"apr.":4,mei:5,juni:6,jun:6,"jun.":6,juli:7,jul:7,"jul.":7,augustus:8,aug:8,"aug.":8,september:9,sep:9,"sep.":9,sept:9,"sept.":9,oktober:10,okt:10,"okt.":10,november:11,nov:11,"nov.":11,december:12,dec:12,"dec.":12};j.INTEGER_WORD_DICTIONARY={een:1,twee:2,drie:3,vier:4,vijf:5,zes:6,zeven:7,acht:8,negen:9,tien:10,elf:11,twaalf:12};j.ORDINAL_WORD_DICTIONARY={eerste:1,tweede:2,derde:3,vierde:4,vijfde:5,zesde:6,zevende:7,achtste:8,negende:9,tiende:10,elfde:11,twaalfde:12,dertiende:13,veertiende:14,vijftiende:15,zestiende:16,zeventiende:17,achttiende:18,negentiende:19,twintigste:20,eenentwintigste:21,twee\u00EBntwintigste:22,drieentwintigste:23,vierentwintigste:24,vijfentwintigste:25,zesentwintigste:26,zevenentwintigste:27,achtentwintig:28,negenentwintig:29,dertigste:30,eenendertigste:31};j.TIME_UNIT_DICTIONARY={sec:"second",second:"second",seconden:"second",min:"minute",mins:"minute",minute:"minute",minuut:"minute",minuten:"minute",minuutje:"minute",h:"hour",hr:"hour",hrs:"hour",uur:"hour",u:"hour",uren:"hour",dag:"d",dagen:"d",week:"week",weken:"week",maand:"month",maanden:"month",jaar:"year",jr:"year",jaren:"year"};j.NUMBER_PATTERN=`(?:${Hs.matchAnyPattern(j.INTEGER_WORD_DICTIONARY)}|[0-9]+|[0-9]+[\\.,][0-9]+|halve?|half|paar)`;function sy(r){let e=r.toLowerCase();return j.INTEGER_WORD_DICTIONARY[e]!==void 0?j.INTEGER_WORD_DICTIONARY[e]:e==="paar"?2:e==="half"||e.match(/halve?/)?.5:parseFloat(e.replace(",","."))}j.parseNumberPattern=sy;j.ORDINAL_NUMBER_PATTERN=`(?:${Hs.matchAnyPattern(j.ORDINAL_WORD_DICTIONARY)}|[0-9]{1,2}(?:ste|de)?)`;function jR(r){let e=r.toLowerCase();return j.ORDINAL_WORD_DICTIONARY[e]!==void 0?j.ORDINAL_WORD_DICTIONARY[e]:(e=e.replace(/(?:ste|de)$/i,""),parseInt(e))}j.parseOrdinalNumberPattern=jR;j.YEAR_PATTERN="(?:[1-9][0-9]{0,3}\\s*(?:voor Christus|na Christus)|[1-2][0-9]{3}|[5-9][0-9])";function BR(r){if(/voor Christus/i.test(r))return r=r.replace(/voor Christus/i,""),-parseInt(r);if(/na Christus/i.test(r))return r=r.replace(/na Christus/i,""),parseInt(r);let e=parseInt(r);return $R.findMostLikelyADYear(e)}j.parseYear=BR;var ay=`(${j.NUMBER_PATTERN})\\s{0,5}(${Hs.matchAnyPattern(j.TIME_UNIT_DICTIONARY)})\\s{0,5}`,iy=new RegExp(ay,"i");j.TIME_UNITS_PATTERN=Hs.repeatedTimeunitPattern("(?:(?:binnen|in)\\s*)?",ay);function GR(r){let e={},t=r,n=iy.exec(t);for(;n;)HR(e,n),t=t.substring(n[0].length),n=iy.exec(t);return e}j.parseTimeUnits=GR;function HR(r,e){let t=sy(e[1]),n=j.TIME_UNIT_DICTIONARY[e[2].toLowerCase()];r[n]=t}});var uy=h(Nl=>{"use strict";Object.defineProperty(Nl,"__esModule",{value:!0});var oy=Qe(),zR=he(),KR=R(),kl=class extends KR.AbstractParserWithWordBoundaryChecking{innerPattern(){return new RegExp("(?:binnen|in|binnen de|voor)\\s*("+oy.TIME_UNITS_PATTERN+")(?=\\W|$)","i")}innerExtract(e,t){let n=oy.parseTimeUnits(t[1]);return zR.ParsingComponents.createRelativeFromReference(e.reference,n)}};Nl.default=kl});var cy=h(xl=>{"use strict";Object.defineProperty(xl,"__esModule",{value:!0});var ly=Qe(),VR=Q(),ZR=R(),XR=qr(),QR=new RegExp(`(?:(?:\\,|\\(|\\\uFF08)\\s*)?(?:op\\s*?)?(?:(deze|vorige|volgende)\\s*(?:week\\s*)?)?(${VR.matchAnyPattern(ly.WEEKDAY_DICTIONARY)})(?=\\W|$)`,"i"),JR=1,ew=2,tw=3,Cl=class extends ZR.AbstractParserWithWordBoundaryChecking{innerPattern(){return QR}innerExtract(e,t){let n=t[ew].toLowerCase(),i=ly.WEEKDAY_DICTIONARY[n],s=t[JR],a=t[tw],o=s||a;o=o||"",o=o.toLowerCase();let u=null;o=="vorige"?u="last":o=="volgende"?u="next":o=="deze"&&(u="this");let l=XR.toDayJSWeekday(e.refDate,i,u);return e.createParsingComponents().assign("weekday",i).imply("day",l.date()).imply("month",l.month()+1).imply("year",l.year())}};xl.default=Cl});var yy=h(Il=>{"use strict";Object.defineProperty(Il,"__esModule",{value:!0});var rw=Se(),hy=Qe(),zs=Qe(),my=Qe(),nw=Q(),iw=R(),sw=new RegExp(`(?:on\\s*?)?(${zs.ORDINAL_NUMBER_PATTERN})(?:\\s*(?:tot|\\-|\\\u2013|until|through|till|\\s)\\s*(${zs.ORDINAL_NUMBER_PATTERN}))?(?:-|/|\\s*(?:of)?\\s*)(`+nw.matchAnyPattern(hy.MONTH_DICTIONARY)+`)(?:(?:-|/|,?\\s*)(${my.YEAR_PATTERN}(?![^\\s]\\d)))?(?=\\W|$)`,"i"),aw=3,dy=1,fy=2,py=4,Sl=class extends iw.AbstractParserWithWordBoundaryChecking{innerPattern(){return sw}innerExtract(e,t){let n=hy.MONTH_DICTIONARY[t[aw].toLowerCase()],i=zs.parseOrdinalNumberPattern(t[dy]);if(i>31)return t.index=t.index+t[dy].length,null;let s=e.createParsingComponents({day:i,month:n});if(t[py]){let u=my.parseYear(t[py]);s.assign("year",u)}else{let u=rw.findYearClosestToRef(e.refDate,i,n);s.imply("year",u)}if(!t[fy])return s;let a=zs.parseOrdinalNumberPattern(t[fy]),o=e.createParsingResult(t.index,t[0]);return o.start=s,o.end=s.clone(),o.end.assign("day",a),o}};Il.default=Sl});var by=h(Fl=>{"use strict";Object.defineProperty(Fl,"__esModule",{value:!0});var _y=Qe(),ow=Se(),uw=Q(),Ty=Qe(),lw=R(),cw=new RegExp(`(${uw.matchAnyPattern(_y.MONTH_DICTIONARY)})\\s*(?:[,-]?\\s*(${Ty.YEAR_PATTERN})?)?(?=[^\\s\\w]|\\s+[^0-9]|\\s+$|$)`,"i"),dw=1,gy=2,Ul=class extends lw.AbstractParserWithWordBoundaryChecking{innerPattern(){return cw}innerExtract(e,t){let n=e.createParsingComponents();n.imply("day",1);let i=t[dw],s=_y.MONTH_DICTIONARY[i.toLowerCase()];if(n.assign("month",s),t[gy]){let a=Ty.parseYear(t[gy]);n.assign("year",a)}else{let a=ow.findYearClosestToRef(e.refDate,1,s);n.imply("year",a)}return n}};Fl.default=Ul});var vy=h(Wl=>{"use strict";Object.defineProperty(Wl,"__esModule",{value:!0});var fw=R(),pw=new RegExp("([0-9]|0[1-9]|1[012])/([0-9]{4})","i"),hw=1,mw=2,ql=class extends fw.AbstractParserWithWordBoundaryChecking{innerPattern(){return pw}innerExtract(e,t){let n=parseInt(t[mw]),i=parseInt(t[hw]);return e.createParsingComponents().imply("day",1).assign("month",i).assign("year",n)}};Wl.default=ql});var Ey=h(Yl=>{"use strict";Object.defineProperty(Yl,"__esModule",{value:!0});var yw=Ur(),Ll=class extends yw.AbstractTimeExpressionParser{primaryPrefix(){return"(?:(?:om)\\s*)?"}followingPhase(){return"\\s*(?:\\-|\\\u2013|\\~|\\\u301C|om|\\?)\\s*"}primarySuffix(){return"(?:\\s*(?:uur))?(?!/)(?=\\W|$)"}extractPrimaryTimeComponents(e,t){return t[0].match(/^\s*\d{4}\s*$/)?null:super.extractPrimaryTimeComponents(e,t)}};Yl.default=Ll});var My=h(jl=>{"use strict";Object.defineProperty(jl,"__esModule",{value:!0});var wy=Qe(),gw=Q(),_w=R(),Tw=new RegExp(`([0-9]{4})[\\.\\/\\s](?:(${gw.matchAnyPattern(wy.MONTH_DICTIONARY)})|([0-9]{1,2}))[\\.\\/\\s]([0-9]{1,2})(?=\\W|$)`,"i"),bw=1,vw=2,Ry=3,Ew=4,$l=class extends _w.AbstractParserWithWordBoundaryChecking{innerPattern(){return Tw}innerExtract(e,t){let n=t[Ry]?parseInt(t[Ry]):wy.MONTH_DICTIONARY[t[vw].toLowerCase()];if(n<1||n>12)return null;let i=parseInt(t[bw]);return{day:parseInt(t[Ew]),month:n,year:i}}};jl.default=$l});var Dy=h(hi=>{"use strict";var Rw=hi&&hi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(hi,"__esModule",{value:!0});var ww=R(),Ks=Ee(),Bl=it(),Mw=Rw(K()),Dw=1,Pw=2,Gl=class extends ww.AbstractParserWithWordBoundaryChecking{innerPattern(e){return/(gisteren|morgen|van)(ochtend|middag|namiddag|avond|nacht)(?=\W|$)/i}innerExtract(e,t){let n=t[Dw].toLowerCase(),i=t[Pw].toLowerCase(),s=e.createParsingComponents(),a=Mw.default(e.refDate);switch(n){case"gisteren":Bl.assignSimilarDate(s,a.add(-1,"day"));break;case"van":Bl.assignSimilarDate(s,a);break;case"morgen":Bl.assignTheNextDay(s,a);break}switch(i){case"ochtend":s.imply("meridiem",Ks.Meridiem.AM),s.imply("hour",6);break;case"middag":s.imply("meridiem",Ks.Meridiem.AM),s.imply("hour",12);break;case"namiddag":s.imply("meridiem",Ks.Meridiem.PM),s.imply("hour",15);break;case"avond":s.imply("meridiem",Ks.Meridiem.PM),s.imply("hour",20);break}return s}};hi.default=Gl});var Oy=h(zl=>{"use strict";Object.defineProperty(zl,"__esModule",{value:!0});var Py=Qe(),Ow=he(),Aw=R(),kw=st(),Nw=new RegExp(`(deze|vorige|afgelopen|komende|over|\\+|-)\\s*(${Py.TIME_UNITS_PATTERN})(?=\\W|$)`,"i"),Hl=class extends Aw.AbstractParserWithWordBoundaryChecking{innerPattern(){return Nw}innerExtract(e,t){let n=t[1].toLowerCase(),i=Py.parseTimeUnits(t[2]);switch(n){case"vorige":case"afgelopen":case"-":i=kw.reverseTimeUnits(i);break}return Ow.ParsingComponents.createRelativeFromReference(e.reference,i)}};zl.default=Hl});var Ny=h(mi=>{"use strict";var Cw=mi&&mi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(mi,"__esModule",{value:!0});var ky=Qe(),Ay=he(),xw=Cw(K()),Sw=R(),Iw=Q(),Uw=new RegExp(`(dit|deze|komende|volgend|volgende|afgelopen|vorige)\\s*(${Iw.matchAnyPattern(ky.TIME_UNIT_DICTIONARY)})(?=\\s*)(?=\\W|$)`,"i"),Fw=1,qw=2,Kl=class extends Sw.AbstractParserWithWordBoundaryChecking{innerPattern(){return Uw}innerExtract(e,t){let n=t[Fw].toLowerCase(),i=t[qw].toLowerCase(),s=ky.TIME_UNIT_DICTIONARY[i];if(n=="volgend"||n=="volgende"||n=="komende"){let u={};return u[s]=1,Ay.ParsingComponents.createRelativeFromReference(e.reference,u)}if(n=="afgelopen"||n=="vorige"){let u={};return u[s]=-1,Ay.ParsingComponents.createRelativeFromReference(e.reference,u)}let a=e.createParsingComponents(),o=xw.default(e.reference.instant);return i.match(/week/i)?(o=o.add(-o.get("d"),"d"),a.imply("day",o.date()),a.imply("month",o.month()+1),a.imply("year",o.year())):i.match(/maand/i)?(o=o.add(-o.date()+1,"d"),a.imply("day",o.date()),a.assign("year",o.year()),a.assign("month",o.month()+1)):i.match(/jaar/i)&&(o=o.add(-o.date()+1,"d"),o=o.add(-o.month(),"month"),a.imply("day",o.date()),a.imply("month",o.month()+1),a.assign("year",o.year())),a}};mi.default=Kl});var Cy=h(Xl=>{"use strict";Object.defineProperty(Xl,"__esModule",{value:!0});var Zl=Qe(),Ww=he(),Lw=R(),Yw=st(),$w=new RegExp("("+Zl.TIME_UNITS_PATTERN+")(?:geleden|voor|eerder)(?=(?:\\W|$))","i"),jw=new RegExp("("+Zl.TIME_UNITS_PATTERN+")geleden(?=(?:\\W|$))","i"),Vl=class extends Lw.AbstractParserWithWordBoundaryChecking{constructor(e){super(),this.strictMode=e}innerPattern(){return this.strictMode?jw:$w}innerExtract(e,t){let n=Zl.parseTimeUnits(t[1]),i=Yw.reverseTimeUnits(n);return Ww.ParsingComponents.createRelativeFromReference(e.reference,i)}};Xl.default=Vl});var xy=h(ec=>{"use strict";Object.defineProperty(ec,"__esModule",{value:!0});var Jl=Qe(),Bw=he(),Gw=R(),Hw=new RegExp("("+Jl.TIME_UNITS_PATTERN+")(later|na|vanaf nu|voortaan|vooruit|uit)(?=(?:\\W|$))","i"),zw=new RegExp("("+Jl.TIME_UNITS_PATTERN+")(later|vanaf nu)(?=(?:\\W|$))","i"),Kw=1,Ql=class extends Gw.AbstractParserWithWordBoundaryChecking{constructor(e){super(),this.strictMode=e}innerPattern(){return this.strictMode?zw:Hw}innerExtract(e,t){let n=Jl.parseTimeUnits(t[Kw]);return Bw.ParsingComponents.createRelativeFromReference(e.reference,n)}};ec.default=Ql});var Fy=h(Ae=>{"use strict";var Ue=Ae&&Ae.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ae,"__esModule",{value:!0});Ae.createConfiguration=Ae.createCasualConfiguration=Ae.parseDate=Ae.parse=Ae.strict=Ae.casual=void 0;var Vw=Bt(),Sy=yt(),Zw=Ue(ey()),Xw=Ue(ty()),Qw=Ue(ry()),Jw=Ue(ny()),eM=Ue(Wr()),tM=Ue(uy()),rM=Ue(cy()),nM=Ue(yy()),Iy=Ue(by()),iM=Ue(vy()),sM=Ue(Ey()),aM=Ue(My()),oM=Ue(Dy()),uM=Ue(Oy()),lM=Ue(Ny()),cM=Ue(Cy()),dM=Ue(xy());Ae.casual=new Sy.Chrono(Uy());Ae.strict=new Sy.Chrono(tc(!0));function fM(r,e,t){return Ae.casual.parse(r,e,t)}Ae.parse=fM;function pM(r,e,t){return Ae.casual.parseDate(r,e,t)}Ae.parseDate=pM;function Uy(r=!0){let e=tc(!1,r);return e.parsers.unshift(new Qw.default),e.parsers.unshift(new Jw.default),e.parsers.unshift(new oM.default),e.parsers.unshift(new Iy.default),e.parsers.unshift(new lM.default),e.parsers.unshift(new uM.default),e}Ae.createCasualConfiguration=Uy;function tc(r=!0,e=!0){return Vw.includeCommonConfiguration({parsers:[new eM.default(e),new tM.default,new nM.default,new Iy.default,new rM.default,new aM.default,new iM.default,new sM.default(r),new cM.default(r),new dM.default(r)],refiners:[new Xw.default,new Zw.default]},r)}Ae.createConfiguration=tc});var Yy=h(yi=>{"use strict";var hM=yi&&yi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(yi,"__esModule",{value:!0});var mM=hM(K()),yM=R(),gM=1,qy=2,_M=3,Wy=4,Ly=5,TM=6,rc=class extends yM.AbstractParserWithWordBoundaryChecking{innerPattern(e){return new RegExp("(\u800C\u5BB6|\u7ACB(?:\u523B|\u5373)|\u5373\u523B)|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u5F8C|\u5927\u5F8C|\u807D|\u6628|\u5C0B|\u7434)(\u65E9|\u671D|\u665A)|(\u4E0A(?:\u5348|\u665D)|\u671D(?:\u65E9)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348|\u665D)|\u664F(?:\u665D)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668))|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u5F8C|\u5927\u5F8C|\u807D|\u6628|\u5C0B|\u7434)(?:\u65E5|\u5929)(?:[\\s|,|\uFF0C]*)(?:(\u4E0A(?:\u5348|\u665D)|\u671D(?:\u65E9)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348|\u665D)|\u664F(?:\u665D)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668)))?","i")}innerExtract(e,t){let n=t.index,i=e.createParsingResult(n,t[0]),s=mM.default(e.refDate),a=s;if(t[gM])i.start.imply("hour",s.hour()),i.start.imply("minute",s.minute()),i.start.imply("second",s.second()),i.start.imply("millisecond",s.millisecond());else if(t[qy]){let o=t[qy],u=t[_M];o=="\u660E"||o=="\u807D"?s.hour()>1&&(a=a.add(1,"day")):o=="\u6628"||o=="\u5C0B"||o=="\u7434"?a=a.add(-1,"day"):o=="\u524D"?a=a.add(-2,"day"):o=="\u5927\u524D"?a=a.add(-3,"day"):o=="\u5F8C"?a=a.add(2,"day"):o=="\u5927\u5F8C"&&(a=a.add(3,"day")),u=="\u65E9"||u=="\u671D"?i.start.imply("hour",6):u=="\u665A"&&(i.start.imply("hour",22),i.start.imply("meridiem",1))}else if(t[Wy]){let u=t[Wy][0];u=="\u65E9"||u=="\u671D"||u=="\u4E0A"?i.start.imply("hour",6):u=="\u4E0B"||u=="\u664F"?(i.start.imply("hour",15),i.start.imply("meridiem",1)):u=="\u4E2D"?(i.start.imply("hour",12),i.start.imply("meridiem",1)):u=="\u591C"||u=="\u665A"?(i.start.imply("hour",22),i.start.imply("meridiem",1)):u=="\u51CC"&&i.start.imply("hour",0)}else if(t[Ly]){let o=t[Ly];o=="\u660E"||o=="\u807D"?s.hour()>1&&(a=a.add(1,"day")):o=="\u6628"||o=="\u5C0B"||o=="\u7434"?a=a.add(-1,"day"):o=="\u524D"?a=a.add(-2,"day"):o=="\u5927\u524D"?a=a.add(-3,"day"):o=="\u5F8C"?a=a.add(2,"day"):o=="\u5927\u5F8C"&&(a=a.add(3,"day"));let u=t[TM];if(u){let l=u[0];l=="\u65E9"||l=="\u671D"||l=="\u4E0A"?i.start.imply("hour",6):l=="\u4E0B"||l=="\u664F"?(i.start.imply("hour",15),i.start.imply("meridiem",1)):l=="\u4E2D"?(i.start.imply("hour",12),i.start.imply("meridiem",1)):l=="\u591C"||l=="\u665A"?(i.start.imply("hour",22),i.start.imply("meridiem",1)):l=="\u51CC"&&i.start.imply("hour",0)}}return i.start.assign("day",a.date()),i.start.assign("month",a.month()+1),i.start.assign("year",a.year()),i}};yi.default=rc});var mn=h(He=>{"use strict";Object.defineProperty(He,"__esModule",{value:!0});He.zhStringToYear=He.zhStringToNumber=He.WEEKDAY_OFFSET=He.NUMBER=void 0;He.NUMBER={\u96F6:0,\u4E00:1,\u4E8C:2,\u5169:2,\u4E09:3,\u56DB:4,\u4E94:5,\u516D:6,\u4E03:7,\u516B:8,\u4E5D:9,\u5341:10,\u5EFF:20,\u5345:30};He.WEEKDAY_OFFSET={\u5929:0,\u65E5:0,\u4E00:1,\u4E8C:2,\u4E09:3,\u56DB:4,\u4E94:5,\u516D:6};function bM(r){let e=0;for(let t=0;t{"use strict";var EM=gi&&gi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(gi,"__esModule",{value:!0});var RM=EM(K()),wM=R(),$r=mn(),nc=1,$y=2,ic=3,sc=class extends wM.AbstractParserWithWordBoundaryChecking{innerPattern(){return new RegExp("(\\d{2,4}|["+Object.keys($r.NUMBER).join("")+"]{4}|["+Object.keys($r.NUMBER).join("")+"]{2})?(?:\\s*)(?:\u5E74)?(?:[\\s|,|\uFF0C]*)(\\d{1,2}|["+Object.keys($r.NUMBER).join("")+"]{1,2})(?:\\s*)(?:\u6708)(?:\\s*)(\\d{1,2}|["+Object.keys($r.NUMBER).join("")+"]{1,2})?(?:\\s*)(?:\u65E5|\u865F)?")}innerExtract(e,t){let n=RM.default(e.refDate),i=e.createParsingResult(t.index,t[0]),s=parseInt(t[$y]);if(isNaN(s)&&(s=$r.zhStringToNumber(t[$y])),i.start.assign("month",s),t[ic]){let a=parseInt(t[ic]);isNaN(a)&&(a=$r.zhStringToNumber(t[ic])),i.start.assign("day",a)}else i.start.imply("day",n.date());if(t[nc]){let a=parseInt(t[nc]);isNaN(a)&&(a=$r.zhStringToYear(t[nc])),i.start.assign("year",a)}else i.start.imply("year",n.year());return i}};gi.default=sc});var Gy=h(_i=>{"use strict";var MM=_i&&_i.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(_i,"__esModule",{value:!0});var DM=MM(K()),PM=R(),By=mn(),OM=new RegExp("(\\d+|["+Object.keys(By.NUMBER).join("")+"]+|\u534A|\u5E7E)(?:\\s*)(?:\u500B)?(\u79D2(?:\u9418)?|\u5206\u9418|\u5C0F\u6642|\u9418|\u65E5|\u5929|\u661F\u671F|\u79AE\u62DC|\u6708|\u5E74)(?:(?:\u4E4B|\u904E)?\u5F8C|(?:\u4E4B)?\u5167)","i"),ac=1,AM=2,oc=class extends PM.AbstractParserWithWordBoundaryChecking{innerPattern(){return OM}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=parseInt(t[ac]);if(isNaN(i)&&(i=By.zhStringToNumber(t[ac])),isNaN(i)){let u=t[ac];if(u==="\u5E7E")i=3;else if(u==="\u534A")i=.5;else return null}let s=DM.default(e.refDate),o=t[AM][0];return o.match(/[日天星禮月年]/)?(o=="\u65E5"||o=="\u5929"?s=s.add(i,"d"):o=="\u661F"||o=="\u79AE"?s=s.add(i*7,"d"):o=="\u6708"?s=s.add(i,"month"):o=="\u5E74"&&(s=s.add(i,"year")),n.start.assign("year",s.year()),n.start.assign("month",s.month()+1),n.start.assign("day",s.date()),n):(o=="\u79D2"?s=s.add(i,"second"):o=="\u5206"?s=s.add(i,"minute"):(o=="\u5C0F"||o=="\u9418")&&(s=s.add(i,"hour")),n.start.imply("year",s.year()),n.start.imply("month",s.month()+1),n.start.imply("day",s.date()),n.start.assign("hour",s.hour()),n.start.assign("minute",s.minute()),n.start.assign("second",s.second()),n)}};_i.default=oc});var zy=h(Ti=>{"use strict";var kM=Ti&&Ti.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ti,"__esModule",{value:!0});var NM=kM(K()),CM=R(),Hy=mn(),xM=new RegExp("(?\u4E0A|\u4ECA|\u4E0B|\u9019|\u5462)(?:\u500B)?(?:\u661F\u671F|\u79AE\u62DC|\u9031)(?"+Object.keys(Hy.WEEKDAY_OFFSET).join("|")+")"),uc=class extends CM.AbstractParserWithWordBoundaryChecking{innerPattern(){return xM}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=t.groups.weekday,s=Hy.WEEKDAY_OFFSET[i];if(s===void 0)return null;let a=null,o=t.groups.prefix;o=="\u4E0A"?a="last":o=="\u4E0B"?a="next":(o=="\u4ECA"||o=="\u9019"||o=="\u5462")&&(a="this");let u=NM.default(e.refDate),l=!1,c=u.day();return a=="last"||a=="past"?(u=u.day(s-7),l=!0):a=="next"?(u=u.day(s+7),l=!0):a=="this"?u=u.day(s):Math.abs(s-7-c){"use strict";var SM=bi&&bi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(bi,"__esModule",{value:!0});var IM=SM(K()),UM=R(),ut=mn(),FM=new RegExp("(?:\u7531|\u5F9E|\u81EA)?(?:(\u4ECA|\u660E|\u524D|\u5927\u524D|\u5F8C|\u5927\u5F8C|\u807D|\u6628|\u5C0B|\u7434)(\u65E9|\u671D|\u665A)|(\u4E0A(?:\u5348|\u665D)|\u671D(?:\u65E9)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348|\u665D)|\u664F(?:\u665D)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668))|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u5F8C|\u5927\u5F8C|\u807D|\u6628|\u5C0B|\u7434)(?:\u65E5|\u5929)(?:[\\s,\uFF0C]*)(?:(\u4E0A(?:\u5348|\u665D)|\u671D(?:\u65E9)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348|\u665D)|\u664F(?:\u665D)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668)))?)?(?:[\\s,\uFF0C]*)(?:(\\d+|["+Object.keys(ut.NUMBER).join("")+"]+)(?:\\s*)(?:\u9EDE|\u6642|:|\uFF1A)(?:\\s*)(\\d+|\u534A|\u6B63|\u6574|["+Object.keys(ut.NUMBER).join("")+"]+)?(?:\\s*)(?:\u5206|:|\uFF1A)?(?:\\s*)(\\d+|["+Object.keys(ut.NUMBER).join("")+"]+)?(?:\\s*)(?:\u79D2)?)(?:\\s*(A.M.|P.M.|AM?|PM?))?","i"),qM=new RegExp("(?:^\\s*(?:\u5230|\u81F3|\\-|\\\u2013|\\~|\\\u301C)\\s*)(?:(\u4ECA|\u660E|\u524D|\u5927\u524D|\u5F8C|\u5927\u5F8C|\u807D|\u6628|\u5C0B|\u7434)(\u65E9|\u671D|\u665A)|(\u4E0A(?:\u5348|\u665D)|\u671D(?:\u65E9)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348|\u665D)|\u664F(?:\u665D)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668))|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u5F8C|\u5927\u5F8C|\u807D|\u6628|\u5C0B|\u7434)(?:\u65E5|\u5929)(?:[\\s,\uFF0C]*)(?:(\u4E0A(?:\u5348|\u665D)|\u671D(?:\u65E9)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348|\u665D)|\u664F(?:\u665D)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668)))?)?(?:[\\s,\uFF0C]*)(?:(\\d+|["+Object.keys(ut.NUMBER).join("")+"]+)(?:\\s*)(?:\u9EDE|\u6642|:|\uFF1A)(?:\\s*)(\\d+|\u534A|\u6B63|\u6574|["+Object.keys(ut.NUMBER).join("")+"]+)?(?:\\s*)(?:\u5206|:|\uFF1A)?(?:\\s*)(\\d+|["+Object.keys(ut.NUMBER).join("")+"]+)?(?:\\s*)(?:\u79D2)?)(?:\\s*(A.M.|P.M.|AM?|PM?))?","i"),Vs=1,Zs=2,Xs=3,Qs=4,Js=5,ea=6,ot=7,yn=8,ta=9,lc=class extends UM.AbstractParserWithWordBoundaryChecking{innerPattern(){return FM}innerExtract(e,t){if(t.index>0&&e.text[t.index-1].match(/\w/))return null;let n=IM.default(e.refDate),i=e.createParsingResult(t.index,t[0]),s=n.clone();if(t[Vs]){var a=t[Vs];a=="\u660E"||a=="\u807D"?n.hour()>1&&s.add(1,"day"):a=="\u6628"||a=="\u5C0B"||a=="\u7434"?s.add(-1,"day"):a=="\u524D"?s.add(-2,"day"):a=="\u5927\u524D"?s.add(-3,"day"):a=="\u5F8C"?s.add(2,"day"):a=="\u5927\u5F8C"&&s.add(3,"day"),i.start.assign("day",s.date()),i.start.assign("month",s.month()+1),i.start.assign("year",s.year())}else if(t[Qs]){var o=t[Qs];o=="\u660E"||o=="\u807D"?s.add(1,"day"):o=="\u6628"||o=="\u5C0B"||o=="\u7434"?s.add(-1,"day"):o=="\u524D"?s.add(-2,"day"):o=="\u5927\u524D"?s.add(-3,"day"):o=="\u5F8C"?s.add(2,"day"):o=="\u5927\u5F8C"&&s.add(3,"day"),i.start.assign("day",s.date()),i.start.assign("month",s.month()+1),i.start.assign("year",s.year())}else i.start.imply("day",s.date()),i.start.imply("month",s.month()+1),i.start.imply("year",s.year());let u=0,l=0,c=-1;if(t[yn]){var d=parseInt(t[yn]);if(isNaN(d)&&(d=ut.zhStringToNumber(t[yn])),d>=60)return null;i.start.assign("second",d)}if(u=parseInt(t[ea]),isNaN(u)&&(u=ut.zhStringToNumber(t[ea])),t[ot]?t[ot]=="\u534A"?l=30:t[ot]=="\u6B63"||t[ot]=="\u6574"?l=0:(l=parseInt(t[ot]),isNaN(l)&&(l=ut.zhStringToNumber(t[ot]))):u>100&&(l=u%100,u=Math.floor(u/100)),l>=60||u>24)return null;if(u>=12&&(c=1),t[ta]){if(u>12)return null;var f=t[ta][0].toLowerCase();f=="a"&&(c=0,u==12&&(u=0)),f=="p"&&(c=1,u!=12&&(u+=12))}else if(t[Zs]){var p=t[Zs],y=p[0];y=="\u671D"||y=="\u65E9"?(c=0,u==12&&(u=0)):y=="\u665A"&&(c=1,u!=12&&(u+=12))}else if(t[Xs]){var m=t[Xs],g=m[0];g=="\u4E0A"||g=="\u671D"||g=="\u65E9"||g=="\u51CC"?(c=0,u==12&&(u=0)):(g=="\u4E0B"||g=="\u664F"||g=="\u665A")&&(c=1,u!=12&&(u+=12))}else if(t[Js]){var A=t[Js],x=A[0];x=="\u4E0A"||x=="\u671D"||x=="\u65E9"||x=="\u51CC"?(c=0,u==12&&(u=0)):(x=="\u4E0B"||x=="\u664F"||x=="\u665A")&&(c=1,u!=12&&(u+=12))}if(i.start.assign("hour",u),i.start.assign("minute",l),c>=0?i.start.assign("meridiem",c):u<12?i.start.imply("meridiem",0):i.start.imply("meridiem",1),t=qM.exec(e.text.substring(i.index+i.text.length)),!t)return i.text.match(/^\d+$/)?null:i;let C=s.clone();if(i.end=e.createParsingComponents(),t[Vs]){var a=t[Vs];a=="\u660E"||a=="\u807D"?n.hour()>1&&C.add(1,"day"):a=="\u6628"||a=="\u5C0B"||a=="\u7434"?C.add(-1,"day"):a=="\u524D"?C.add(-2,"day"):a=="\u5927\u524D"?C.add(-3,"day"):a=="\u5F8C"?C.add(2,"day"):a=="\u5927\u5F8C"&&C.add(3,"day"),i.end.assign("day",C.date()),i.end.assign("month",C.month()+1),i.end.assign("year",C.year())}else if(t[Qs]){var o=t[Qs];o=="\u660E"||o=="\u807D"?C.add(1,"day"):o=="\u6628"||o=="\u5C0B"||o=="\u7434"?C.add(-1,"day"):o=="\u524D"?C.add(-2,"day"):o=="\u5927\u524D"?C.add(-3,"day"):o=="\u5F8C"?C.add(2,"day"):o=="\u5927\u5F8C"&&C.add(3,"day"),i.end.assign("day",C.date()),i.end.assign("month",C.month()+1),i.end.assign("year",C.year())}else i.end.imply("day",C.date()),i.end.imply("month",C.month()+1),i.end.imply("year",C.year());if(u=0,l=0,c=-1,t[yn]){var d=parseInt(t[yn]);if(isNaN(d)&&(d=ut.zhStringToNumber(t[yn])),d>=60)return null;i.end.assign("second",d)}if(u=parseInt(t[ea]),isNaN(u)&&(u=ut.zhStringToNumber(t[ea])),t[ot]?t[ot]=="\u534A"?l=30:t[ot]=="\u6B63"||t[ot]=="\u6574"?l=0:(l=parseInt(t[ot]),isNaN(l)&&(l=ut.zhStringToNumber(t[ot]))):u>100&&(l=u%100,u=Math.floor(u/100)),l>=60||u>24)return null;if(u>=12&&(c=1),t[ta]){if(u>12)return null;var f=t[ta][0].toLowerCase();f=="a"&&(c=0,u==12&&(u=0)),f=="p"&&(c=1,u!=12&&(u+=12)),i.start.isCertain("meridiem")||(c==0?(i.start.imply("meridiem",0),i.start.get("hour")==12&&i.start.assign("hour",0)):(i.start.imply("meridiem",1),i.start.get("hour")!=12&&i.start.assign("hour",i.start.get("hour")+12)))}else if(t[Zs]){var p=t[Zs],y=p[0];y=="\u671D"||y=="\u65E9"?(c=0,u==12&&(u=0)):y=="\u665A"&&(c=1,u!=12&&(u+=12))}else if(t[Xs]){var m=t[Xs],g=m[0];g=="\u4E0A"||g=="\u671D"||g=="\u65E9"||g=="\u51CC"?(c=0,u==12&&(u=0)):(g=="\u4E0B"||g=="\u664F"||g=="\u665A")&&(c=1,u!=12&&(u+=12))}else if(t[Js]){var A=t[Js],x=A[0];x=="\u4E0A"||x=="\u671D"||x=="\u65E9"||x=="\u51CC"?(c=0,u==12&&(u=0)):(x=="\u4E0B"||x=="\u664F"||x=="\u665A")&&(c=1,u!=12&&(u+=12))}return i.text=i.text+t[0],i.end.assign("hour",u),i.end.assign("minute",l),c>=0?i.end.assign("meridiem",c):i.start.isCertain("meridiem")&&i.start.get("meridiem")==1&&i.start.get("hour")>u?i.end.imply("meridiem",0):u>12&&i.end.imply("meridiem",1),i.end.date().getTime(){"use strict";var WM=vi&&vi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(vi,"__esModule",{value:!0});var LM=WM(K()),YM=R(),Vy=mn(),$M=new RegExp("(?:\u661F\u671F|\u79AE\u62DC|\u9031)(?"+Object.keys(Vy.WEEKDAY_OFFSET).join("|")+")"),cc=class extends YM.AbstractParserWithWordBoundaryChecking{innerPattern(){return $M}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=t.groups.weekday,s=Vy.WEEKDAY_OFFSET[i];if(s===void 0)return null;let a=LM.default(e.refDate),o=!1,u=a.day();return Math.abs(s-7-u){"use strict";var jM=Ei&&Ei.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ei,"__esModule",{value:!0});var BM=jM(At()),dc=class extends BM.default{patternBetween(){return/^\s*(至|到|\-|\~|~|-|ー)\s*$/i}};Ei.default=dc});var Qy=h(Ri=>{"use strict";var GM=Ri&&Ri.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ri,"__esModule",{value:!0});var HM=GM(jt()),fc=class extends HM.default{patternBetween(){return/^\s*$/i}};Ri.default=fc});var Jy=h(be=>{"use strict";var Vt=be&&be.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(be,"__esModule",{value:!0});be.createConfiguration=be.createCasualConfiguration=be.parseDate=be.parse=be.strict=be.casual=be.hant=void 0;var pc=yt(),zM=Vt(Ns()),KM=Bt(),VM=Vt(Yy()),ZM=Vt(jy()),XM=Vt(Gy()),QM=Vt(zy()),JM=Vt(Ky()),eD=Vt(Zy()),tD=Vt(Xy()),rD=Vt(Qy());be.hant=new pc.Chrono(hc());be.casual=new pc.Chrono(hc());be.strict=new pc.Chrono(mc());function nD(r,e,t){return be.casual.parse(r,e,t)}be.parse=nD;function iD(r,e,t){return be.casual.parseDate(r,e,t)}be.parseDate=iD;function hc(){let r=mc();return r.parsers.unshift(new VM.default),r}be.createCasualConfiguration=hc;function mc(){let r=KM.includeCommonConfiguration({parsers:[new ZM.default,new QM.default,new eD.default,new JM.default,new XM.default],refiners:[new tD.default,new rD.default]});return r.refiners=r.refiners.filter(e=>!(e instanceof zM.default)),r}be.createConfiguration=mc});var ng=h(wi=>{"use strict";var sD=wi&&wi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(wi,"__esModule",{value:!0});var aD=sD(K()),oD=R(),uD=1,eg=2,lD=3,tg=4,rg=5,cD=6,yc=class extends oD.AbstractParserWithWordBoundaryChecking{innerPattern(e){return new RegExp("(\u73B0\u5728|\u7ACB(?:\u523B|\u5373)|\u5373\u523B)|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u540E|\u5927\u540E|\u6628)(\u65E9|\u665A)|(\u4E0A(?:\u5348)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668))|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u540E|\u5927\u540E|\u6628)(?:\u65E5|\u5929)(?:[\\s|,|\uFF0C]*)(?:(\u4E0A(?:\u5348)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668)))?","i")}innerExtract(e,t){let n=t.index,i=e.createParsingResult(n,t[0]),s=aD.default(e.refDate),a=s;if(t[uD])i.start.imply("hour",s.hour()),i.start.imply("minute",s.minute()),i.start.imply("second",s.second()),i.start.imply("millisecond",s.millisecond());else if(t[eg]){let o=t[eg],u=t[lD];o=="\u660E"?s.hour()>1&&(a=a.add(1,"day")):o=="\u6628"?a=a.add(-1,"day"):o=="\u524D"?a=a.add(-2,"day"):o=="\u5927\u524D"?a=a.add(-3,"day"):o=="\u540E"?a=a.add(2,"day"):o=="\u5927\u540E"&&(a=a.add(3,"day")),u=="\u65E9"?i.start.imply("hour",6):u=="\u665A"&&(i.start.imply("hour",22),i.start.imply("meridiem",1))}else if(t[tg]){let u=t[tg][0];u=="\u65E9"||u=="\u4E0A"?i.start.imply("hour",6):u=="\u4E0B"?(i.start.imply("hour",15),i.start.imply("meridiem",1)):u=="\u4E2D"?(i.start.imply("hour",12),i.start.imply("meridiem",1)):u=="\u591C"||u=="\u665A"?(i.start.imply("hour",22),i.start.imply("meridiem",1)):u=="\u51CC"&&i.start.imply("hour",0)}else if(t[rg]){let o=t[rg];o=="\u660E"?s.hour()>1&&(a=a.add(1,"day")):o=="\u6628"?a=a.add(-1,"day"):o=="\u524D"?a=a.add(-2,"day"):o=="\u5927\u524D"?a=a.add(-3,"day"):o=="\u540E"?a=a.add(2,"day"):o=="\u5927\u540E"&&(a=a.add(3,"day"));let u=t[cD];if(u){let l=u[0];l=="\u65E9"||l=="\u4E0A"?i.start.imply("hour",6):l=="\u4E0B"?(i.start.imply("hour",15),i.start.imply("meridiem",1)):l=="\u4E2D"?(i.start.imply("hour",12),i.start.imply("meridiem",1)):l=="\u591C"||l=="\u665A"?(i.start.imply("hour",22),i.start.imply("meridiem",1)):l=="\u51CC"&&i.start.imply("hour",0)}}return i.start.assign("day",a.date()),i.start.assign("month",a.month()+1),i.start.assign("year",a.year()),i}};wi.default=yc});var gn=h(ze=>{"use strict";Object.defineProperty(ze,"__esModule",{value:!0});ze.zhStringToYear=ze.zhStringToNumber=ze.WEEKDAY_OFFSET=ze.NUMBER=void 0;ze.NUMBER={\u96F6:0,"\u3007":0,\u4E00:1,\u4E8C:2,\u4E24:2,\u4E09:3,\u56DB:4,\u4E94:5,\u516D:6,\u4E03:7,\u516B:8,\u4E5D:9,\u5341:10};ze.WEEKDAY_OFFSET={\u5929:0,\u65E5:0,\u4E00:1,\u4E8C:2,\u4E09:3,\u56DB:4,\u4E94:5,\u516D:6};function dD(r){let e=0;for(let t=0;t{"use strict";var pD=Mi&&Mi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Mi,"__esModule",{value:!0});var hD=pD(K()),mD=R(),jr=gn(),gc=1,ig=2,_c=3,Tc=class extends mD.AbstractParserWithWordBoundaryChecking{innerPattern(){return new RegExp("(\\d{2,4}|["+Object.keys(jr.NUMBER).join("")+"]{4}|["+Object.keys(jr.NUMBER).join("")+"]{2})?(?:\\s*)(?:\u5E74)?(?:[\\s|,|\uFF0C]*)(\\d{1,2}|["+Object.keys(jr.NUMBER).join("")+"]{1,3})(?:\\s*)(?:\u6708)(?:\\s*)(\\d{1,2}|["+Object.keys(jr.NUMBER).join("")+"]{1,3})?(?:\\s*)(?:\u65E5|\u53F7)?")}innerExtract(e,t){let n=hD.default(e.refDate),i=e.createParsingResult(t.index,t[0]),s=parseInt(t[ig]);if(isNaN(s)&&(s=jr.zhStringToNumber(t[ig])),i.start.assign("month",s),t[_c]){let a=parseInt(t[_c]);isNaN(a)&&(a=jr.zhStringToNumber(t[_c])),i.start.assign("day",a)}else i.start.imply("day",n.date());if(t[gc]){let a=parseInt(t[gc]);isNaN(a)&&(a=jr.zhStringToYear(t[gc])),i.start.assign("year",a)}else i.start.imply("year",n.year());return i}};Mi.default=Tc});var og=h(Di=>{"use strict";var yD=Di&&Di.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Di,"__esModule",{value:!0});var gD=yD(K()),_D=R(),ag=gn(),TD=new RegExp("(\\d+|["+Object.keys(ag.NUMBER).join("")+"]+|\u534A|\u51E0)(?:\\s*)(?:\u4E2A)?(\u79D2(?:\u949F)?|\u5206\u949F|\u5C0F\u65F6|\u949F|\u65E5|\u5929|\u661F\u671F|\u793C\u62DC|\u6708|\u5E74)(?:(?:\u4E4B|\u8FC7)?\u540E|(?:\u4E4B)?\u5185)","i"),bc=1,bD=2,vc=class extends _D.AbstractParserWithWordBoundaryChecking{innerPattern(){return TD}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=parseInt(t[bc]);if(isNaN(i)&&(i=ag.zhStringToNumber(t[bc])),isNaN(i)){let u=t[bc];if(u==="\u51E0")i=3;else if(u==="\u534A")i=.5;else return null}let s=gD.default(e.refDate),o=t[bD][0];return o.match(/[日天星礼月年]/)?(o=="\u65E5"||o=="\u5929"?s=s.add(i,"d"):o=="\u661F"||o=="\u793C"?s=s.add(i*7,"d"):o=="\u6708"?s=s.add(i,"month"):o=="\u5E74"&&(s=s.add(i,"year")),n.start.assign("year",s.year()),n.start.assign("month",s.month()+1),n.start.assign("day",s.date()),n):(o=="\u79D2"?s=s.add(i,"second"):o=="\u5206"?s=s.add(i,"minute"):(o=="\u5C0F"||o=="\u949F")&&(s=s.add(i,"hour")),n.start.imply("year",s.year()),n.start.imply("month",s.month()+1),n.start.imply("day",s.date()),n.start.assign("hour",s.hour()),n.start.assign("minute",s.minute()),n.start.assign("second",s.second()),n)}};Di.default=vc});var lg=h(Pi=>{"use strict";var vD=Pi&&Pi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Pi,"__esModule",{value:!0});var ED=vD(K()),RD=R(),ug=gn(),wD=new RegExp("(?\u4E0A|\u4E0B|\u8FD9)(?:\u4E2A)?(?:\u661F\u671F|\u793C\u62DC|\u5468)(?"+Object.keys(ug.WEEKDAY_OFFSET).join("|")+")"),Ec=class extends RD.AbstractParserWithWordBoundaryChecking{innerPattern(){return wD}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=t.groups.weekday,s=ug.WEEKDAY_OFFSET[i];if(s===void 0)return null;let a=null,o=t.groups.prefix;o=="\u4E0A"?a="last":o=="\u4E0B"?a="next":o=="\u8FD9"&&(a="this");let u=ED.default(e.refDate),l=!1,c=u.day();return a=="last"||a=="past"?(u=u.day(s-7),l=!0):a=="next"?(u=u.day(s+7),l=!0):a=="this"?u=u.day(s):Math.abs(s-7-c){"use strict";var MD=Oi&&Oi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Oi,"__esModule",{value:!0});var DD=MD(K()),PD=R(),ct=gn(),OD=new RegExp("(?:\u4ECE|\u81EA)?(?:(\u4ECA|\u660E|\u524D|\u5927\u524D|\u540E|\u5927\u540E|\u6628)(\u65E9|\u671D|\u665A)|(\u4E0A(?:\u5348)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668))|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u540E|\u5927\u540E|\u6628)(?:\u65E5|\u5929)(?:[\\s,\uFF0C]*)(?:(\u4E0A(?:\u5348)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668)))?)?(?:[\\s,\uFF0C]*)(?:(\\d+|["+Object.keys(ct.NUMBER).join("")+"]+)(?:\\s*)(?:\u70B9|\u65F6|:|\uFF1A)(?:\\s*)(\\d+|\u534A|\u6B63|\u6574|["+Object.keys(ct.NUMBER).join("")+"]+)?(?:\\s*)(?:\u5206|:|\uFF1A)?(?:\\s*)(\\d+|["+Object.keys(ct.NUMBER).join("")+"]+)?(?:\\s*)(?:\u79D2)?)(?:\\s*(A.M.|P.M.|AM?|PM?))?","i"),AD=new RegExp("(?:^\\s*(?:\u5230|\u81F3|\\-|\\\u2013|\\~|\\\u301C)\\s*)(?:(\u4ECA|\u660E|\u524D|\u5927\u524D|\u540E|\u5927\u540E|\u6628)(\u65E9|\u671D|\u665A)|(\u4E0A(?:\u5348)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668))|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u540E|\u5927\u540E|\u6628)(?:\u65E5|\u5929)(?:[\\s,\uFF0C]*)(?:(\u4E0A(?:\u5348)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668)))?)?(?:[\\s,\uFF0C]*)(?:(\\d+|["+Object.keys(ct.NUMBER).join("")+"]+)(?:\\s*)(?:\u70B9|\u65F6|:|\uFF1A)(?:\\s*)(\\d+|\u534A|\u6B63|\u6574|["+Object.keys(ct.NUMBER).join("")+"]+)?(?:\\s*)(?:\u5206|:|\uFF1A)?(?:\\s*)(\\d+|["+Object.keys(ct.NUMBER).join("")+"]+)?(?:\\s*)(?:\u79D2)?)(?:\\s*(A.M.|P.M.|AM?|PM?))?","i"),ra=1,na=2,ia=3,sa=4,aa=5,oa=6,lt=7,_n=8,ua=9,Rc=class extends PD.AbstractParserWithWordBoundaryChecking{innerPattern(){return OD}innerExtract(e,t){if(t.index>0&&e.text[t.index-1].match(/\w/))return null;let n=DD.default(e.refDate),i=e.createParsingResult(t.index,t[0]),s=n.clone();if(t[ra]){let c=t[ra];c=="\u660E"?n.hour()>1&&s.add(1,"day"):c=="\u6628"?s.add(-1,"day"):c=="\u524D"?s.add(-2,"day"):c=="\u5927\u524D"?s.add(-3,"day"):c=="\u540E"?s.add(2,"day"):c=="\u5927\u540E"&&s.add(3,"day"),i.start.assign("day",s.date()),i.start.assign("month",s.month()+1),i.start.assign("year",s.year())}else if(t[sa]){let c=t[sa];c=="\u660E"?s.add(1,"day"):c=="\u6628"?s.add(-1,"day"):c=="\u524D"?s.add(-2,"day"):c=="\u5927\u524D"?s.add(-3,"day"):c=="\u540E"?s.add(2,"day"):c=="\u5927\u540E"&&s.add(3,"day"),i.start.assign("day",s.date()),i.start.assign("month",s.month()+1),i.start.assign("year",s.year())}else i.start.imply("day",s.date()),i.start.imply("month",s.month()+1),i.start.imply("year",s.year());let a=0,o=0,u=-1;if(t[_n]){let c=parseInt(t[_n]);if(isNaN(c)&&(c=ct.zhStringToNumber(t[_n])),c>=60)return null;i.start.assign("second",c)}if(a=parseInt(t[oa]),isNaN(a)&&(a=ct.zhStringToNumber(t[oa])),t[lt]?t[lt]=="\u534A"?o=30:t[lt]=="\u6B63"||t[lt]=="\u6574"?o=0:(o=parseInt(t[lt]),isNaN(o)&&(o=ct.zhStringToNumber(t[lt]))):a>100&&(o=a%100,a=Math.floor(a/100)),o>=60||a>24)return null;if(a>=12&&(u=1),t[ua]){if(a>12)return null;let c=t[ua][0].toLowerCase();c=="a"&&(u=0,a==12&&(a=0)),c=="p"&&(u=1,a!=12&&(a+=12))}else if(t[na]){let d=t[na][0];d=="\u65E9"?(u=0,a==12&&(a=0)):d=="\u665A"&&(u=1,a!=12&&(a+=12))}else if(t[ia]){let d=t[ia][0];d=="\u4E0A"||d=="\u65E9"||d=="\u51CC"?(u=0,a==12&&(a=0)):(d=="\u4E0B"||d=="\u665A")&&(u=1,a!=12&&(a+=12))}else if(t[aa]){let d=t[aa][0];d=="\u4E0A"||d=="\u65E9"||d=="\u51CC"?(u=0,a==12&&(a=0)):(d=="\u4E0B"||d=="\u665A")&&(u=1,a!=12&&(a+=12))}if(i.start.assign("hour",a),i.start.assign("minute",o),u>=0?i.start.assign("meridiem",u):a<12?i.start.imply("meridiem",0):i.start.imply("meridiem",1),t=AD.exec(e.text.substring(i.index+i.text.length)),!t)return i.text.match(/^\d+$/)?null:i;let l=s.clone();if(i.end=e.createParsingComponents(),t[ra]){let c=t[ra];c=="\u660E"?n.hour()>1&&l.add(1,"day"):c=="\u6628"?l.add(-1,"day"):c=="\u524D"?l.add(-2,"day"):c=="\u5927\u524D"?l.add(-3,"day"):c=="\u540E"?l.add(2,"day"):c=="\u5927\u540E"&&l.add(3,"day"),i.end.assign("day",l.date()),i.end.assign("month",l.month()+1),i.end.assign("year",l.year())}else if(t[sa]){let c=t[sa];c=="\u660E"?l.add(1,"day"):c=="\u6628"?l.add(-1,"day"):c=="\u524D"?l.add(-2,"day"):c=="\u5927\u524D"?l.add(-3,"day"):c=="\u540E"?l.add(2,"day"):c=="\u5927\u540E"&&l.add(3,"day"),i.end.assign("day",l.date()),i.end.assign("month",l.month()+1),i.end.assign("year",l.year())}else i.end.imply("day",l.date()),i.end.imply("month",l.month()+1),i.end.imply("year",l.year());if(a=0,o=0,u=-1,t[_n]){let c=parseInt(t[_n]);if(isNaN(c)&&(c=ct.zhStringToNumber(t[_n])),c>=60)return null;i.end.assign("second",c)}if(a=parseInt(t[oa]),isNaN(a)&&(a=ct.zhStringToNumber(t[oa])),t[lt]?t[lt]=="\u534A"?o=30:t[lt]=="\u6B63"||t[lt]=="\u6574"?o=0:(o=parseInt(t[lt]),isNaN(o)&&(o=ct.zhStringToNumber(t[lt]))):a>100&&(o=a%100,a=Math.floor(a/100)),o>=60||a>24)return null;if(a>=12&&(u=1),t[ua]){if(a>12)return null;let c=t[ua][0].toLowerCase();c=="a"&&(u=0,a==12&&(a=0)),c=="p"&&(u=1,a!=12&&(a+=12)),i.start.isCertain("meridiem")||(u==0?(i.start.imply("meridiem",0),i.start.get("hour")==12&&i.start.assign("hour",0)):(i.start.imply("meridiem",1),i.start.get("hour")!=12&&i.start.assign("hour",i.start.get("hour")+12)))}else if(t[na]){let d=t[na][0];d=="\u65E9"?(u=0,a==12&&(a=0)):d=="\u665A"&&(u=1,a!=12&&(a+=12))}else if(t[ia]){let d=t[ia][0];d=="\u4E0A"||d=="\u65E9"||d=="\u51CC"?(u=0,a==12&&(a=0)):(d=="\u4E0B"||d=="\u665A")&&(u=1,a!=12&&(a+=12))}else if(t[aa]){let d=t[aa][0];d=="\u4E0A"||d=="\u65E9"||d=="\u51CC"?(u=0,a==12&&(a=0)):(d=="\u4E0B"||d=="\u665A")&&(u=1,a!=12&&(a+=12))}return i.text=i.text+t[0],i.end.assign("hour",a),i.end.assign("minute",o),u>=0?i.end.assign("meridiem",u):i.start.isCertain("meridiem")&&i.start.get("meridiem")==1&&i.start.get("hour")>a?i.end.imply("meridiem",0):a>12&&i.end.imply("meridiem",1),i.end.date().getTime(){"use strict";var kD=Ai&&Ai.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ai,"__esModule",{value:!0});var ND=kD(K()),CD=R(),dg=gn(),xD=new RegExp("(?:\u661F\u671F|\u793C\u62DC|\u5468)(?"+Object.keys(dg.WEEKDAY_OFFSET).join("|")+")"),wc=class extends CD.AbstractParserWithWordBoundaryChecking{innerPattern(){return xD}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=t.groups.weekday,s=dg.WEEKDAY_OFFSET[i];if(s===void 0)return null;let a=ND.default(e.refDate),o=!1,u=a.day();return Math.abs(s-7-u){"use strict";var SD=ki&&ki.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ki,"__esModule",{value:!0});var ID=SD(At()),Mc=class extends ID.default{patternBetween(){return/^\s*(至|到|-|~|~|-|ー)\s*$/i}};ki.default=Mc});var hg=h(Ni=>{"use strict";var UD=Ni&&Ni.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ni,"__esModule",{value:!0});var FD=UD(jt()),Dc=class extends FD.default{patternBetween(){return/^\s*$/i}};Ni.default=Dc});var mg=h(ve=>{"use strict";var Zt=ve&&ve.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ve,"__esModule",{value:!0});ve.createConfiguration=ve.createCasualConfiguration=ve.parseDate=ve.parse=ve.strict=ve.casual=ve.hans=void 0;var Pc=yt(),qD=Zt(Ns()),WD=Bt(),LD=Zt(ng()),YD=Zt(sg()),$D=Zt(og()),jD=Zt(lg()),BD=Zt(cg()),GD=Zt(fg()),HD=Zt(pg()),zD=Zt(hg());ve.hans=new Pc.Chrono(Oc());ve.casual=new Pc.Chrono(Oc());ve.strict=new Pc.Chrono(Ac());function KD(r,e,t){return ve.casual.parse(r,e,t)}ve.parse=KD;function VD(r,e,t){return ve.casual.parseDate(r,e,t)}ve.parseDate=VD;function Oc(){let r=Ac();return r.parsers.unshift(new LD.default),r}ve.createCasualConfiguration=Oc;function Ac(){let r=WD.includeCommonConfiguration({parsers:[new YD.default,new jD.default,new GD.default,new BD.default,new $D.default],refiners:[new HD.default,new zD.default]});return r.refiners=r.refiners.filter(e=>!(e instanceof qD.default)),r}ve.createConfiguration=Ac});var gg=h(Je=>{"use strict";var yg=Je&&Je.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),ZD=Je&&Je.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),XD=Je&&Je.__exportStar||function(r,e){for(var t in r)t!=="default"&&!Object.prototype.hasOwnProperty.call(e,t)&&yg(e,r,t)},QD=Je&&Je.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&yg(e,r,t);return ZD(e,r),e};Object.defineProperty(Je,"__esModule",{value:!0});Je.hans=void 0;XD(Jy(),Je);Je.hans=QD(mg())});var Ke=h(F=>{"use strict";Object.defineProperty(F,"__esModule",{value:!0});F.parseTimeUnits=F.TIME_UNITS_PATTERN=F.parseYear=F.YEAR_PATTERN=F.parseOrdinalNumberPattern=F.ORDINAL_NUMBER_PATTERN=F.parseNumberPattern=F.NUMBER_PATTERN=F.TIME_UNIT_DICTIONARY=F.ORDINAL_WORD_DICTIONARY=F.INTEGER_WORD_DICTIONARY=F.MONTH_DICTIONARY=F.FULL_MONTH_NAME_DICTIONARY=F.WEEKDAY_DICTIONARY=F.REGEX_PARTS=void 0;var la=Q(),JD=Se();F.REGEX_PARTS={leftBoundary:"([^\\p{L}\\p{N}_]|^)",rightBoundary:"(?=[^\\p{L}\\p{N}_]|$)",flags:"iu"};F.WEEKDAY_DICTIONARY={\u0432\u043E\u0441\u043A\u0440\u0435\u0441\u0435\u043D\u044C\u0435:0,\u0432\u043E\u0441\u043A\u0440\u0435\u0441\u0435\u043D\u044C\u044F:0,\u0432\u0441\u043A:0,"\u0432\u0441\u043A.":0,\u043F\u043E\u043D\u0435\u0434\u0435\u043B\u044C\u043D\u0438\u043A:1,\u043F\u043E\u043D\u0435\u0434\u0435\u043B\u044C\u043D\u0438\u043A\u0430:1,\u043F\u043D:1,"\u043F\u043D.":1,\u0432\u0442\u043E\u0440\u043D\u0438\u043A:2,\u0432\u0442\u043E\u0440\u043D\u0438\u043A\u0430:2,\u0432\u0442:2,"\u0432\u0442.":2,\u0441\u0440\u0435\u0434\u0430:3,\u0441\u0440\u0435\u0434\u044B:3,\u0441\u0440\u0435\u0434\u0443:3,\u0441\u0440:3,"\u0441\u0440.":3,\u0447\u0435\u0442\u0432\u0435\u0440\u0433:4,\u0447\u0435\u0442\u0432\u0435\u0440\u0433\u0430:4,\u0447\u0442:4,"\u0447\u0442.":4,\u043F\u044F\u0442\u043D\u0438\u0446\u0430:5,\u043F\u044F\u0442\u043D\u0438\u0446\u0443:5,\u043F\u044F\u0442\u043D\u0438\u0446\u044B:5,\u043F\u0442:5,"\u043F\u0442.":5,\u0441\u0443\u0431\u0431\u043E\u0442\u0430:6,\u0441\u0443\u0431\u0431\u043E\u0442\u0443:6,\u0441\u0443\u0431\u0431\u043E\u0442\u044B:6,\u0441\u0431:6,"\u0441\u0431.":6};F.FULL_MONTH_NAME_DICTIONARY={\u044F\u043D\u0432\u0430\u0440\u044C:1,\u044F\u043D\u0432\u0430\u0440\u044F:1,\u044F\u043D\u0432\u0430\u0440\u0435:1,\u0444\u0435\u0432\u0440\u044F\u043B\u044C:2,\u0444\u0435\u0432\u0440\u044F\u043B\u044F:2,\u0444\u0435\u0432\u0440\u044F\u043B\u0435:2,\u043C\u0430\u0440\u0442:3,\u043C\u0430\u0440\u0442\u0430:3,\u043C\u0430\u0440\u0442\u0435:3,\u0430\u043F\u0440\u0435\u043B\u044C:4,\u0430\u043F\u0440\u0435\u043B\u044F:4,\u0430\u043F\u0440\u0435\u043B\u0435:4,\u043C\u0430\u0439:5,\u043C\u0430\u044F:5,\u043C\u0430\u0435:5,\u0438\u044E\u043D\u044C:6,\u0438\u044E\u043D\u044F:6,\u0438\u044E\u043D\u0435:6,\u0438\u044E\u043B\u044C:7,\u0438\u044E\u043B\u044F:7,\u0438\u044E\u043B\u0435:7,\u0430\u0432\u0433\u0443\u0441\u0442:8,\u0430\u0432\u0433\u0443\u0441\u0442\u0430:8,\u0430\u0432\u0433\u0443\u0441\u0442\u0435:8,\u0441\u0435\u043D\u0442\u044F\u0431\u0440\u044C:9,\u0441\u0435\u043D\u0442\u044F\u0431\u0440\u044F:9,\u0441\u0435\u043D\u0442\u044F\u0431\u0440\u0435:9,\u043E\u043A\u0442\u044F\u0431\u0440\u044C:10,\u043E\u043A\u0442\u044F\u0431\u0440\u044F:10,\u043E\u043A\u0442\u044F\u0431\u0440\u0435:10,\u043D\u043E\u044F\u0431\u0440\u044C:11,\u043D\u043E\u044F\u0431\u0440\u044F:11,\u043D\u043E\u044F\u0431\u0440\u0435:11,\u0434\u0435\u043A\u0430\u0431\u0440\u044C:12,\u0434\u0435\u043A\u0430\u0431\u0440\u044F:12,\u0434\u0435\u043A\u0430\u0431\u0440\u0435:12};F.MONTH_DICTIONARY=Object.assign(Object.assign({},F.FULL_MONTH_NAME_DICTIONARY),{\u044F\u043D\u0432:1,"\u044F\u043D\u0432.":1,\u0444\u0435\u0432:2,"\u0444\u0435\u0432.":2,\u043C\u0430\u0440:3,"\u043C\u0430\u0440.":3,\u0430\u043F\u0440:4,"\u0430\u043F\u0440.":4,\u0430\u0432\u0433:8,"\u0430\u0432\u0433.":8,\u0441\u0435\u043D:9,"\u0441\u0435\u043D.":9,\u043E\u043A\u0442:10,"\u043E\u043A\u0442.":10,\u043D\u043E\u044F:11,"\u043D\u043E\u044F.":11,\u0434\u0435\u043A:12,"\u0434\u0435\u043A.":12});F.INTEGER_WORD_DICTIONARY={\u043E\u0434\u0438\u043D:1,\u043E\u0434\u043D\u0430:1,\u043E\u0434\u043D\u043E\u0439:1,\u043E\u0434\u043D\u0443:1,\u0434\u0432\u0435:2,\u0434\u0432\u0430:2,\u0434\u0432\u0443\u0445:2,\u0442\u0440\u0438:3,\u0442\u0440\u0435\u0445:3,\u0442\u0440\u0451\u0445:3,\u0447\u0435\u0442\u044B\u0440\u0435:4,\u0447\u0435\u0442\u044B\u0440\u0435\u0445:4,\u0447\u0435\u0442\u044B\u0440\u0451\u0445:4,\u043F\u044F\u0442\u044C:5,\u043F\u044F\u0442\u0438:5,\u0448\u0435\u0441\u0442\u044C:6,\u0448\u0435\u0441\u0442\u0438:6,\u0441\u0435\u043C\u044C:7,\u0441\u0435\u043C\u0438:7,\u0432\u043E\u0441\u0435\u043C\u044C:8,\u0432\u043E\u0441\u0435\u043C\u044C\u043C\u0438:8,\u0434\u0435\u0432\u044F\u0442\u044C:9,\u0434\u0435\u0432\u044F\u0442\u0438:9,\u0434\u0435\u0441\u044F\u0442\u044C:10,\u0434\u0435\u0441\u044F\u0442\u0438:10,\u043E\u0434\u0438\u043D\u043D\u0430\u0434\u0446\u0430\u0442\u044C:11,\u043E\u0434\u0438\u043D\u043D\u0430\u0434\u0446\u0430\u0442\u0438:11,\u0434\u0432\u0435\u043D\u0430\u0434\u0446\u0430\u0442\u044C:12,\u0434\u0432\u0435\u043D\u0430\u0434\u0446\u0430\u0442\u0438:12};F.ORDINAL_WORD_DICTIONARY={\u043F\u0435\u0440\u0432\u043E\u0435:1,\u043F\u0435\u0440\u0432\u043E\u0433\u043E:1,\u0432\u0442\u043E\u0440\u043E\u0435:2,\u0432\u0442\u043E\u0440\u043E\u0433\u043E:2,\u0442\u0440\u0435\u0442\u044C\u0435:3,\u0442\u0440\u0435\u0442\u044C\u0435\u0433\u043E:3,\u0447\u0435\u0442\u0432\u0435\u0440\u0442\u043E\u0435:4,\u0447\u0435\u0442\u0432\u0435\u0440\u0442\u043E\u0433\u043E:4,\u043F\u044F\u0442\u043E\u0435:5,\u043F\u044F\u0442\u043E\u0433\u043E:5,\u0448\u0435\u0441\u0442\u043E\u0435:6,\u0448\u0435\u0441\u0442\u043E\u0433\u043E:6,\u0441\u0435\u0434\u044C\u043C\u043E\u0435:7,\u0441\u0435\u0434\u044C\u043C\u043E\u0433\u043E:7,\u0432\u043E\u0441\u044C\u043C\u043E\u0435:8,\u0432\u043E\u0441\u044C\u043C\u043E\u0433\u043E:8,\u0434\u0435\u0432\u044F\u0442\u043E\u0435:9,\u0434\u0435\u0432\u044F\u0442\u043E\u0433\u043E:9,\u0434\u0435\u0441\u044F\u0442\u043E\u0435:10,\u0434\u0435\u0441\u044F\u0442\u043E\u0433\u043E:10,\u043E\u0434\u0438\u043D\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:11,\u043E\u0434\u0438\u043D\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:11,\u0434\u0432\u0435\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:12,\u0434\u0432\u0435\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:12,\u0442\u0440\u0438\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:13,\u0442\u0440\u0438\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:13,\u0447\u0435\u0442\u044B\u0440\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:14,\u0447\u0435\u0442\u044B\u0440\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:14,\u043F\u044F\u0442\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:15,\u043F\u044F\u0442\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:15,\u0448\u0435\u0441\u0442\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:16,\u0448\u0435\u0441\u0442\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:16,\u0441\u0435\u043C\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:17,\u0441\u0435\u043C\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:17,\u0432\u043E\u0441\u0435\u043C\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:18,\u0432\u043E\u0441\u0435\u043C\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:18,\u0434\u0435\u0432\u044F\u0442\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:19,\u0434\u0435\u0432\u044F\u0442\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:19,\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u043E\u0435:20,\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:20,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u043F\u0435\u0440\u0432\u043E\u0435":21,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u043F\u0435\u0440\u0432\u043E\u0433\u043E":21,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0432\u0442\u043E\u0440\u043E\u0435":22,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0432\u0442\u043E\u0440\u043E\u0433\u043E":22,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0442\u0440\u0435\u0442\u044C\u0435":23,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0442\u0440\u0435\u0442\u044C\u0435\u0433\u043E":23,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0447\u0435\u0442\u0432\u0435\u0440\u0442\u043E\u0435":24,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0447\u0435\u0442\u0432\u0435\u0440\u0442\u043E\u0433\u043E":24,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u043F\u044F\u0442\u043E\u0435":25,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u043F\u044F\u0442\u043E\u0433\u043E":25,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0448\u0435\u0441\u0442\u043E\u0435":26,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0448\u0435\u0441\u0442\u043E\u0433\u043E":26,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0441\u0435\u0434\u044C\u043C\u043E\u0435":27,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0441\u0435\u0434\u044C\u043C\u043E\u0433\u043E":27,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0432\u043E\u0441\u044C\u043C\u043E\u0435":28,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0432\u043E\u0441\u044C\u043C\u043E\u0433\u043E":28,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0434\u0435\u0432\u044F\u0442\u043E\u0435":29,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0434\u0435\u0432\u044F\u0442\u043E\u0433\u043E":29,\u0442\u0440\u0438\u0434\u0446\u0430\u0442\u043E\u0435:30,\u0442\u0440\u0438\u0434\u0446\u0430\u0442\u043E\u0433\u043E:30,"\u0442\u0440\u0438\u0434\u0446\u0430\u0442\u044C \u043F\u0435\u0440\u0432\u043E\u0435":31,"\u0442\u0440\u0438\u0434\u0446\u0430\u0442\u044C \u043F\u0435\u0440\u0432\u043E\u0433\u043E":31};F.TIME_UNIT_DICTIONARY={\u0441\u0435\u043A:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u0430:"second",\u0441\u0435\u043A\u0443\u043D\u0434:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u044B:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u0443:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u043E\u0447\u043A\u0430:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u043E\u0447\u043A\u0438:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u043E\u0447\u0435\u043A:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u043E\u0447\u043A\u0443:"second",\u043C\u0438\u043D:"minute",\u043C\u0438\u043D\u0443\u0442\u0430:"minute",\u043C\u0438\u043D\u0443\u0442:"minute",\u043C\u0438\u043D\u0443\u0442\u044B:"minute",\u043C\u0438\u043D\u0443\u0442\u0443:"minute",\u043C\u0438\u043D\u0443\u0442\u043E\u043A:"minute",\u043C\u0438\u043D\u0443\u0442\u043A\u0438:"minute",\u043C\u0438\u043D\u0443\u0442\u043A\u0443:"minute",\u0447\u0430\u0441:"hour",\u0447\u0430\u0441\u043E\u0432:"hour",\u0447\u0430\u0441\u0430:"hour",\u0447\u0430\u0441\u0443:"hour",\u0447\u0430\u0441\u0438\u043A\u043E\u0432:"hour",\u0447\u0430\u0441\u0438\u043A\u0430:"hour",\u0447\u0430\u0441\u0438\u043A\u0435:"hour",\u0447\u0430\u0441\u0438\u043A:"hour",\u0434\u0435\u043D\u044C:"d",\u0434\u043D\u044F:"d",\u0434\u043D\u0435\u0439:"d",\u0441\u0443\u0442\u043E\u043A:"d",\u0441\u0443\u0442\u043A\u0438:"d",\u043D\u0435\u0434\u0435\u043B\u044F:"week",\u043D\u0435\u0434\u0435\u043B\u0435:"week",\u043D\u0435\u0434\u0435\u043B\u0438:"week",\u043D\u0435\u0434\u0435\u043B\u044E:"week",\u043D\u0435\u0434\u0435\u043B\u044C:"week",\u043D\u0435\u0434\u0435\u043B\u044C\u043A\u0435:"week",\u043D\u0435\u0434\u0435\u043B\u044C\u043A\u0438:"week",\u043D\u0435\u0434\u0435\u043B\u0435\u043A:"week",\u043C\u0435\u0441\u044F\u0446:"month",\u043C\u0435\u0441\u044F\u0446\u0435:"month",\u043C\u0435\u0441\u044F\u0446\u0435\u0432:"month",\u043C\u0435\u0441\u044F\u0446\u0430:"month",\u043A\u0432\u0430\u0440\u0442\u0430\u043B:"quarter",\u043A\u0432\u0430\u0440\u0442\u0430\u043B\u0435:"quarter",\u043A\u0432\u0430\u0440\u0442\u0430\u043B\u043E\u0432:"quarter",\u0433\u043E\u0434:"year",\u0433\u043E\u0434\u0430:"year",\u0433\u043E\u0434\u0443:"year",\u0433\u043E\u0434\u043E\u0432:"year",\u043B\u0435\u0442:"year",\u0433\u043E\u0434\u0438\u043A:"year",\u0433\u043E\u0434\u0438\u043A\u0430:"year",\u0433\u043E\u0434\u0438\u043A\u043E\u0432:"year"};F.NUMBER_PATTERN=`(?:${la.matchAnyPattern(F.INTEGER_WORD_DICTIONARY)}|[0-9]+|[0-9]+\\.[0-9]+|\u043F\u043E\u043B|\u043D\u0435\u0441\u043A\u043E\u043B\u044C\u043A\u043E|\u043F\u0430\u0440(?:\u044B|\u0443)|\\s{0,3})`;function Tg(r){let e=r.toLowerCase();return F.INTEGER_WORD_DICTIONARY[e]!==void 0?F.INTEGER_WORD_DICTIONARY[e]:e.match(/несколько/)?3:e.match(/пол/)?.5:e.match(/пар/)?2:e===""?1:parseFloat(e)}F.parseNumberPattern=Tg;F.ORDINAL_NUMBER_PATTERN=`(?:${la.matchAnyPattern(F.ORDINAL_WORD_DICTIONARY)}|[0-9]{1,2}(?:\u0433\u043E|\u043E\u0433\u043E|\u0435|\u043E\u0435)?)`;function eP(r){let e=r.toLowerCase();return F.ORDINAL_WORD_DICTIONARY[e]!==void 0?F.ORDINAL_WORD_DICTIONARY[e]:(e=e.replace(/(?:st|nd|rd|th)$/i,""),parseInt(e))}F.parseOrdinalNumberPattern=eP;var kc="(?:\\s+(?:\u0433\u043E\u0434\u0443|\u0433\u043E\u0434\u0430|\u0433\u043E\u0434|\u0433|\u0433.))?";F.YEAR_PATTERN=`(?:[1-9][0-9]{0,3}${kc}\\s*(?:\u043D.\u044D.|\u0434\u043E \u043D.\u044D.|\u043D. \u044D.|\u0434\u043E \u043D. \u044D.)|[1-2][0-9]{3}${kc}|[5-9][0-9]${kc})`;function tP(r){if(/(год|года|г|г.)/i.test(r)&&(r=r.replace(/(год|года|г|г.)/i,"")),/(до н.э.|до н. э.)/i.test(r))return r=r.replace(/(до н.э.|до н. э.)/i,""),-parseInt(r);if(/(н. э.|н.э.)/i.test(r))return r=r.replace(/(н. э.|н.э.)/i,""),parseInt(r);let e=parseInt(r);return JD.findMostLikelyADYear(e)}F.parseYear=tP;var bg=`(${F.NUMBER_PATTERN})\\s{0,3}(${la.matchAnyPattern(F.TIME_UNIT_DICTIONARY)})`,_g=new RegExp(bg,"i");F.TIME_UNITS_PATTERN=la.repeatedTimeunitPattern("(?:(?:\u043E\u043A\u043E\u043B\u043E|\u043F\u0440\u0438\u043C\u0435\u0440\u043D\u043E)\\s{0,3})?",bg);function rP(r){let e={},t=r,n=_g.exec(t);for(;n;)nP(e,n),t=t.substring(n[0].length).trim(),n=_g.exec(t);return e}F.parseTimeUnits=rP;function nP(r,e){let t=Tg(e[1]),n=F.TIME_UNIT_DICTIONARY[e[2].toLowerCase()];r[n]=t}});var Eg=h(Cc=>{"use strict";Object.defineProperty(Cc,"__esModule",{value:!0});var Ci=Ke(),iP=he(),sP=R(),vg=`(?:(?:\u043E\u043A\u043E\u043B\u043E|\u043F\u0440\u0438\u043C\u0435\u0440\u043D\u043E)\\s*(?:~\\s*)?)?(${Ci.TIME_UNITS_PATTERN})${Ci.REGEX_PARTS.rightBoundary}`,aP=new RegExp(`(?:\u0432 \u0442\u0435\u0447\u0435\u043D\u0438\u0435|\u0432 \u0442\u0435\u0447\u0435\u043D\u0438\u0438)\\s*${vg}`,Ci.REGEX_PARTS.flags),oP=new RegExp(vg,"i"),Nc=class extends sP.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return Ci.REGEX_PARTS.leftBoundary}innerPattern(e){return e.option.forwardDate?oP:aP}innerExtract(e,t){let n=Ci.parseTimeUnits(t[1]);return iP.ParsingComponents.createRelativeFromReference(e.reference,n)}};Cc.default=Nc});var Pg=h(Sc=>{"use strict";Object.defineProperty(Sc,"__esModule",{value:!0});var uP=Se(),xi=Ke(),Dg=Ke(),ca=Ke(),lP=Q(),cP=R(),dP=new RegExp(`(?:\u0441)?\\s*(${ca.ORDINAL_NUMBER_PATTERN})(?:\\s{0,3}(?:\u043F\u043E|-|\u2013|\u0434\u043E)?\\s{0,3}(${ca.ORDINAL_NUMBER_PATTERN}))?(?:-|\\/|\\s{0,3}(?:of)?\\s{0,3})(${lP.matchAnyPattern(xi.MONTH_DICTIONARY)})(?:(?:-|\\/|,?\\s{0,3})(${Dg.YEAR_PATTERN}(?![^\\s]\\d)))?${xi.REGEX_PARTS.rightBoundary}`,xi.REGEX_PARTS.flags),Rg=1,wg=2,fP=3,Mg=4,xc=class extends cP.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return xi.REGEX_PARTS.leftBoundary}innerPattern(){return dP}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=xi.MONTH_DICTIONARY[t[fP].toLowerCase()],s=ca.parseOrdinalNumberPattern(t[Rg]);if(s>31)return t.index=t.index+t[Rg].length,null;if(n.start.assign("month",i),n.start.assign("day",s),t[Mg]){let a=Dg.parseYear(t[Mg]);n.start.assign("year",a)}else{let a=uP.findYearClosestToRef(e.refDate,s,i);n.start.imply("year",a)}if(t[wg]){let a=ca.parseOrdinalNumberPattern(t[wg]);n.end=n.start.clone(),n.end.assign("day",a)}return n}};Sc.default=xc});var kg=h(Uc=>{"use strict";Object.defineProperty(Uc,"__esModule",{value:!0});var Si=Ke(),pP=Se(),hP=Q(),Ag=Ke(),mP=R(),yP=new RegExp(`((?:\u0432)\\s*)?(${hP.matchAnyPattern(Si.MONTH_DICTIONARY)})\\s*(?:[,-]?\\s*(${Ag.YEAR_PATTERN})?)?(?=[^\\s\\w]|\\s+[^0-9]|\\s+$|$)`,Si.REGEX_PARTS.flags),gP=2,Og=3,Ic=class extends mP.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return Si.REGEX_PARTS.leftBoundary}innerPattern(){return yP}innerExtract(e,t){let n=t[gP].toLowerCase();if(t[0].length<=3&&!Si.FULL_MONTH_NAME_DICTIONARY[n])return null;let i=e.createParsingResult(t.index,t.index+t[0].length);i.start.imply("day",1);let s=Si.MONTH_DICTIONARY[n];if(i.start.assign("month",s),t[Og]){let a=Ag.parseYear(t[Og]);i.start.assign("year",a)}else{let a=pP.findYearClosestToRef(e.refDate,1,s);i.start.imply("year",a)}return i}};Uc.default=Ic});var Cg=h(qc=>{"use strict";Object.defineProperty(qc,"__esModule",{value:!0});var da=Ee(),_P=Ur(),Ng=Ke(),Fc=class extends _P.AbstractTimeExpressionParser{constructor(e){super(e)}patternFlags(){return Ng.REGEX_PARTS.flags}primaryPatternLeftBoundary(){return"(^|\\s|T|(?:[^\\p{L}\\p{N}_]))"}followingPhase(){return"\\s*(?:\\-|\\\u2013|\\~|\\\u301C|\u0434\u043E|\u0438|\u043F\u043E|\\?)\\s*"}primaryPrefix(){return"(?:(?:\u0432|\u0441)\\s*)??"}primarySuffix(){return`(?:\\s*(?:\u0443\u0442\u0440\u0430|\u0432\u0435\u0447\u0435\u0440\u0430|\u043F\u043E\u0441\u043B\u0435 \u043F\u043E\u043B\u0443\u0434\u043D\u044F))?(?!\\/)${Ng.REGEX_PARTS.rightBoundary}`}extractPrimaryTimeComponents(e,t){let n=super.extractPrimaryTimeComponents(e,t);if(n){if(t[0].endsWith("\u0432\u0435\u0447\u0435\u0440\u0430")){let i=n.get("hour");i>=6&&i<12?(n.assign("hour",n.get("hour")+12),n.assign("meridiem",da.Meridiem.PM)):i<6&&n.assign("meridiem",da.Meridiem.AM)}if(t[0].endsWith("\u043F\u043E\u0441\u043B\u0435 \u043F\u043E\u043B\u0443\u0434\u043D\u044F")){n.assign("meridiem",da.Meridiem.PM);let i=n.get("hour");i>=0&&i<=6&&n.assign("hour",n.get("hour")+12)}t[0].endsWith("\u0443\u0442\u0440\u0430")&&(n.assign("meridiem",da.Meridiem.AM),n.get("hour")<12&&n.assign("hour",n.get("hour")))}return n}};qc.default=Fc});var xg=h(Lc=>{"use strict";Object.defineProperty(Lc,"__esModule",{value:!0});var fa=Ke(),TP=he(),bP=R(),vP=st(),EP=new RegExp(`(${fa.TIME_UNITS_PATTERN})\\s{0,5}\u043D\u0430\u0437\u0430\u0434(?=(?:\\W|$))`,fa.REGEX_PARTS.flags),Wc=class extends bP.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return fa.REGEX_PARTS.leftBoundary}innerPattern(){return EP}innerExtract(e,t){let n=fa.parseTimeUnits(t[1]),i=vP.reverseTimeUnits(n);return TP.ParsingComponents.createRelativeFromReference(e.reference,i)}};Lc.default=Wc});var Sg=h(Ii=>{"use strict";var RP=Ii&&Ii.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ii,"__esModule",{value:!0});var wP=RP(At()),Yc=class extends wP.default{patternBetween(){return/^\s*(и до|и по|до|по|-)\s*$/i}};Ii.default=Yc});var Ig=h(Ui=>{"use strict";var MP=Ui&&Ui.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ui,"__esModule",{value:!0});var DP=MP(jt()),$c=class extends DP.default{patternBetween(){return new RegExp("^\\s*(T|\u0432|,|-)?\\s*$")}};Ui.default=$c});var Ug=h(Xt=>{"use strict";var PP=Xt&&Xt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),OP=Xt&&Xt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),AP=Xt&&Xt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&PP(e,r,t);return OP(e,r),e};Object.defineProperty(Xt,"__esModule",{value:!0});var kP=R(),Fi=AP(Ht()),jc=Ke(),NP=new RegExp(`(?:\u0441|\u0441\u043E)?\\s*(\u0441\u0435\u0433\u043E\u0434\u043D\u044F|\u0432\u0447\u0435\u0440\u0430|\u0437\u0430\u0432\u0442\u0440\u0430|\u043F\u043E\u0441\u043B\u0435\u0437\u0430\u0432\u0442\u0440\u0430|\u043F\u043E\u0437\u0430\u0432\u0447\u0435\u0440\u0430)${jc.REGEX_PARTS.rightBoundary}`,jc.REGEX_PARTS.flags),Bc=class extends kP.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return jc.REGEX_PARTS.leftBoundary}innerPattern(e){return NP}innerExtract(e,t){let n=t[1].toLowerCase(),i=e.createParsingComponents();switch(n){case"\u0441\u0435\u0433\u043E\u0434\u043D\u044F":return Fi.today(e.reference);case"\u0432\u0447\u0435\u0440\u0430":return Fi.yesterday(e.reference);case"\u0437\u0430\u0432\u0442\u0440\u0430":return Fi.tomorrow(e.reference);case"\u043F\u043E\u0441\u043B\u0435\u0437\u0430\u0432\u0442\u0440\u0430":return Fi.theDayAfter(e.reference,2);case"\u043F\u043E\u0437\u0430\u0432\u0447\u0435\u0440\u0430":return Fi.theDayBefore(e.reference,2)}return i}};Xt.default=Bc});var Fg=h(vt=>{"use strict";var CP=vt&&vt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),xP=vt&&vt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),SP=vt&&vt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&CP(e,r,t);return xP(e,r),e},IP=vt&&vt.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(vt,"__esModule",{value:!0});var UP=R(),Br=SP(Ht()),FP=it(),qP=IP(K()),Gc=Ke(),WP=new RegExp(`(\u0441\u0435\u0439\u0447\u0430\u0441|\u043F\u0440\u043E\u0448\u043B\u044B\u043C\\s*\u0432\u0435\u0447\u0435\u0440\u043E\u043C|\u043F\u0440\u043E\u0448\u043B\u043E\u0439\\s*\u043D\u043E\u0447\u044C\u044E|\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0439\\s*\u043D\u043E\u0447\u044C\u044E|\u0441\u0435\u0433\u043E\u0434\u043D\u044F\\s*\u043D\u043E\u0447\u044C\u044E|\u044D\u0442\u043E\u0439\\s*\u043D\u043E\u0447\u044C\u044E|\u043D\u043E\u0447\u044C\u044E|\u044D\u0442\u0438\u043C \u0443\u0442\u0440\u043E\u043C|\u0443\u0442\u0440\u043E\u043C|\u0443\u0442\u0440\u0430|\u0432\\s*\u043F\u043E\u043B\u0434\u0435\u043D\u044C|\u0432\u0435\u0447\u0435\u0440\u043E\u043C|\u0432\u0435\u0447\u0435\u0440\u0430|\u0432\\s*\u043F\u043E\u043B\u043D\u043E\u0447\u044C)${Gc.REGEX_PARTS.rightBoundary}`,Gc.REGEX_PARTS.flags),Hc=class extends UP.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return Gc.REGEX_PARTS.leftBoundary}innerPattern(){return WP}innerExtract(e,t){let n=qP.default(e.refDate),i=t[0].toLowerCase(),s=e.createParsingComponents();if(i==="\u0441\u0435\u0439\u0447\u0430\u0441")return Br.now(e.reference);if(i==="\u0432\u0435\u0447\u0435\u0440\u043E\u043C"||i==="\u0432\u0435\u0447\u0435\u0440\u0430")return Br.evening(e.reference);if(i.endsWith("\u0443\u0442\u0440\u043E\u043C")||i.endsWith("\u0443\u0442\u0440\u0430"))return Br.morning(e.reference);if(i.match(/в\s*полдень/))return Br.noon(e.reference);if(i.match(/прошлой\s*ночью/))return Br.lastNight(e.reference);if(i.match(/прошлым\s*вечером/))return Br.yesterdayEvening(e.reference);if(i.match(/следующей\s*ночью/)){let a=n.hour()<22?1:2;n=n.add(a,"day"),FP.assignSimilarDate(s,n),s.imply("hour",0)}return i.match(/в\s*полночь/)||i.endsWith("\u043D\u043E\u0447\u044C\u044E")?Br.midnight(e.reference):s}};vt.default=Hc});var qg=h(Kc=>{"use strict";Object.defineProperty(Kc,"__esModule",{value:!0});var qi=Ke(),LP=Q(),YP=R(),$P=qr(),jP=new RegExp(`(?:(?:,|\\(|\uFF08)\\s*)?(?:\u0432\\s*?)?(?:(\u044D\u0442\u0443|\u044D\u0442\u043E\u0442|\u043F\u0440\u043E\u0448\u043B\u044B\u0439|\u043F\u0440\u043E\u0448\u043B\u0443\u044E|\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0438\u0439|\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0443\u044E|\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0433\u043E)\\s*)?(${LP.matchAnyPattern(qi.WEEKDAY_DICTIONARY)})(?:\\s*(?:,|\\)|\uFF09))?(?:\\s*\u043D\u0430\\s*(\u044D\u0442\u043E\u0439|\u043F\u0440\u043E\u0448\u043B\u043E\u0439|\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0439)\\s*\u043D\u0435\u0434\u0435\u043B\u0435)?${qi.REGEX_PARTS.rightBoundary}`,qi.REGEX_PARTS.flags),BP=1,GP=2,HP=3,zc=class extends YP.AbstractParserWithWordBoundaryChecking{innerPattern(){return jP}patternLeftBoundary(){return qi.REGEX_PARTS.leftBoundary}innerExtract(e,t){let n=t[GP].toLowerCase(),i=qi.WEEKDAY_DICTIONARY[n],s=t[BP],a=t[HP],o=s||a;o=o||"",o=o.toLowerCase();let u=null;o=="\u043F\u0440\u043E\u0448\u043B\u044B\u0439"||o=="\u043F\u0440\u043E\u0448\u043B\u0443\u044E"||o=="\u043F\u0440\u043E\u0448\u043B\u043E\u0439"?u="last":o=="\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0438\u0439"||o=="\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0443\u044E"||o=="\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0439"||o=="\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0433\u043E"?u="next":(o=="\u044D\u0442\u043E\u0442"||o=="\u044D\u0442\u0443"||o=="\u044D\u0442\u043E\u0439")&&(u="this");let l=$P.toDayJSWeekday(e.refDate,i,u);return e.createParsingComponents().assign("weekday",i).imply("day",l.date()).imply("month",l.month()+1).imply("year",l.year())}};Kc.default=zc});var Lg=h(Li=>{"use strict";var zP=Li&&Li.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Li,"__esModule",{value:!0});var Wi=Ke(),Wg=he(),KP=zP(K()),VP=R(),ZP=Q(),XP=new RegExp(`(\u0432 \u043F\u0440\u043E\u0448\u043B\u043E\u043C|\u043D\u0430 \u043F\u0440\u043E\u0448\u043B\u043E\u0439|\u043D\u0430 \u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0439|\u0432 \u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u043C|\u043D\u0430 \u044D\u0442\u043E\u0439|\u0432 \u044D\u0442\u043E\u043C)\\s*(${ZP.matchAnyPattern(Wi.TIME_UNIT_DICTIONARY)})(?=\\s*)${Wi.REGEX_PARTS.rightBoundary}`,Wi.REGEX_PARTS.flags),QP=1,JP=2,Vc=class extends VP.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return Wi.REGEX_PARTS.leftBoundary}innerPattern(){return XP}innerExtract(e,t){let n=t[QP].toLowerCase(),i=t[JP].toLowerCase(),s=Wi.TIME_UNIT_DICTIONARY[i];if(n=="\u043D\u0430 \u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0439"||n=="\u0432 \u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u043C"){let u={};return u[s]=1,Wg.ParsingComponents.createRelativeFromReference(e.reference,u)}if(n=="\u0432 \u043F\u0440\u043E\u0448\u043B\u043E\u043C"||n=="\u043D\u0430 \u043F\u0440\u043E\u0448\u043B\u043E\u0439"){let u={};return u[s]=-1,Wg.ParsingComponents.createRelativeFromReference(e.reference,u)}let a=e.createParsingComponents(),o=KP.default(e.reference.instant);return s.match(/week/i)?(o=o.add(-o.get("d"),"d"),a.imply("day",o.date()),a.imply("month",o.month()+1),a.imply("year",o.year())):s.match(/month/i)?(o=o.add(-o.date()+1,"d"),a.imply("day",o.date()),a.assign("year",o.year()),a.assign("month",o.month()+1)):s.match(/year/i)&&(o=o.add(-o.date()+1,"d"),o=o.add(-o.month(),"month"),a.imply("day",o.date()),a.imply("month",o.month()+1),a.assign("year",o.year())),a}};Li.default=Vc});var Yg=h(Xc=>{"use strict";Object.defineProperty(Xc,"__esModule",{value:!0});var Yi=Ke(),eO=he(),tO=R(),rO=st(),nO=new RegExp(`(\u044D\u0442\u0438|\u043F\u043E\u0441\u043B\u0435\u0434\u043D\u0438\u0435|\u043F\u0440\u043E\u0448\u043B\u044B\u0435|\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0438\u0435|\u043F\u043E\u0441\u043B\u0435|\u0447\u0435\u0440\u0435\u0437|\\+|-)\\s*(${Yi.TIME_UNITS_PATTERN})${Yi.REGEX_PARTS.rightBoundary}`,Yi.REGEX_PARTS.flags),Zc=class extends tO.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return Yi.REGEX_PARTS.leftBoundary}innerPattern(){return nO}innerExtract(e,t){let n=t[1].toLowerCase(),i=Yi.parseTimeUnits(t[2]);switch(n){case"\u043F\u043E\u0441\u043B\u0435\u0434\u043D\u0438\u0435":case"\u043F\u0440\u043E\u0448\u043B\u044B\u0435":case"-":i=rO.reverseTimeUnits(i);break}return eO.ParsingComponents.createRelativeFromReference(e.reference,i)}};Xc.default=Zc});var Bg=h(ke=>{"use strict";var et=ke&&ke.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ke,"__esModule",{value:!0});ke.createConfiguration=ke.createCasualConfiguration=ke.parseDate=ke.parse=ke.strict=ke.casual=void 0;var iO=et(Eg()),sO=et(Pg()),aO=et(kg()),oO=et(Cg()),uO=et(xg()),lO=et(Sg()),cO=et(Ig()),dO=Bt(),fO=et(Ug()),pO=et(Fg()),hO=et(qg()),mO=et(Lg()),$g=yt(),yO=et(Wr()),gO=et(Yg());ke.casual=new $g.Chrono(jg());ke.strict=new $g.Chrono(Qc(!0));function _O(r,e,t){return ke.casual.parse(r,e,t)}ke.parse=_O;function TO(r,e,t){return ke.casual.parseDate(r,e,t)}ke.parseDate=TO;function jg(){let r=Qc(!1);return r.parsers.unshift(new fO.default),r.parsers.unshift(new pO.default),r.parsers.unshift(new aO.default),r.parsers.unshift(new mO.default),r.parsers.unshift(new gO.default),r}ke.createCasualConfiguration=jg;function Qc(r=!0){return dO.includeCommonConfiguration({parsers:[new yO.default(!0),new iO.default,new sO.default,new hO.default,new oO.default(r),new uO.default],refiners:[new cO.default,new lO.default]},r)}ke.createConfiguration=Qc});var Ee=h(L=>{"use strict";var bO=L&&L.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),vO=L&&L.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),vr=L&&L.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&bO(e,r,t);return vO(e,r),e};Object.defineProperty(L,"__esModule",{value:!0});L.parseDate=L.parse=L.casual=L.strict=L.ru=L.zh=L.nl=L.pt=L.ja=L.fr=L.de=L.Meridiem=L.Chrono=L.en=void 0;var Jc=vr(yu());L.en=Jc;var EO=yt();Object.defineProperty(L,"Chrono",{enumerable:!0,get:function(){return EO.Chrono}});var RO;(function(r){r[r.AM=0]="AM",r[r.PM=1]="PM"})(RO=L.Meridiem||(L.Meridiem={}));var wO=vr(Jh());L.de=wO;var MO=vr(Om());L.fr=MO;var DO=vr(Fm());L.ja=DO;var PO=vr(Jm());L.pt=PO;var OO=vr(Fy());L.nl=OO;var AO=vr(gg());L.zh=AO;var kO=vr(Bg());L.ru=kO;L.strict=Jc.strict;L.casual=Jc.casual;function NO(r,e,t){return L.casual.parse(r,e,t)}L.parse=NO;function CO(r,e,t){return L.casual.parseDate(r,e,t)}L.parseDate=CO});var xt=h(Dr=>{"use strict";Dr.__esModule=!0;var LO;(function(r){r.AND="AND",r.OR="OR",r.XOR="XOR",r.NOT="NOT"})(LO=Dr.Operators||(Dr.Operators={}));var YO;(function(r){r.OPEN_PARENTHESIS="(",r.CLOSE_PARENTHESIS=")"})(YO=Dr.StructuralCharacters||(Dr.StructuralCharacters={}));var $O;(function(r){r.IDENTIFIER="IDENTIFIER",r.OPERATOR="OPERATOR",r.STRUCTURAL_CHARACTER="STRUCTURAL_CHARACTER",r.EOF="EOF",r.COMMENT="COMMENT"})($O=Dr.Tokens||(Dr.Tokens={}))});var fd=h(Ca=>{"use strict";Ca.__esModule=!0;var me=xt();Ca.OPERATOR_PRECEDENCE={NOT:0,XOR:1,AND:2,OR:3};Ca.VALID_TOKENS={identifierOnly:[{name:me.Tokens.IDENTIFIER},{name:me.Tokens.STRUCTURAL_CHARACTER,value:me.StructuralCharacters.OPEN_PARENTHESIS}],identifierOrNot:[{name:me.Tokens.IDENTIFIER},{name:me.Tokens.STRUCTURAL_CHARACTER,value:me.StructuralCharacters.OPEN_PARENTHESIS},{name:me.Tokens.OPERATOR,value:me.Operators.NOT}],binaryOperator:[{name:me.Tokens.OPERATOR,value:me.Operators.AND},{name:me.Tokens.OPERATOR,value:me.Operators.OR},{name:me.Tokens.OPERATOR,value:me.Operators.XOR}],binaryOperatorOrClose:[{name:me.Tokens.OPERATOR,value:me.Operators.AND},{name:me.Tokens.OPERATOR,value:me.Operators.OR},{name:me.Tokens.OPERATOR,value:me.Operators.XOR},{name:me.Tokens.STRUCTURAL_CHARACTER,value:me.StructuralCharacters.CLOSE_PARENTHESIS}]}});var pd=h(tr=>{"use strict";tr.__esModule=!0;var En=xt();tr.STRUCTURAL_CHARACTERS={"(":En.StructuralCharacters.OPEN_PARENTHESIS,")":En.StructuralCharacters.CLOSE_PARENTHESIS};tr.OPERATORS={AND:En.Operators.AND,OR:En.Operators.OR,XOR:En.Operators.XOR,NOT:En.Operators.NOT};tr.SEPARATORS=new Set([32,9,10,13].map(function(r){return String.fromCodePoint(r)}));tr.QUOTED_IDENTIFIER_DELIMITER=String.fromCodePoint(34);tr.COMMENT_DELIMITER=String.fromCodePoint(35);tr.EOL=String.fromCodePoint(10);tr.ESCAPE_CHARACTER=String.fromCodePoint(92)});var t_=h(rr=>{"use strict";var hd=rr&&rr.__assign||function(){return hd=Object.assign||function(r){for(var e,t=1,n=arguments.length;t{"use strict";md.__esModule=!0;var Rn=xt(),tt=pd(),wn=t_();md.lex=function(r){for(var e=null,t=null,n=null,i=0;i{"use strict";var jO=nr&&nr.__spreadArrays||function(){for(var r=0,e=0,t=arguments.length;e{"use strict";var Dn=Vi&&Vi.__spreadArrays||function(){for(var r=0,e=0,t=arguments.length;e{"use strict";ir.__esModule=!0;var a_=xt();ir.andUtil=function(r,e){return r&&e};ir.orUtil=function(r,e){return r||e};ir.xorUtil=function(r,e){return r!==e};ir.notUtil=function(r){return!r};ir.isIdentifier=function(r){var e=r.name,t=r.value;return e===a_.Tokens.IDENTIFIER&&typeof t=="string"};ir.isOperator=function(r){var e=r.name,t=r.value;return e===a_.Tokens.OPERATOR&&typeof t=="string"};ir.throwInvalidExpression=function(r){throw new TypeError("Invalid postfix expression: "+r)}});var o_=h(vd=>{"use strict";var Zi;vd.__esModule=!0;var Td=xt(),bd=_d();vd.OPERATOR_MAP=(Zi={},Zi[Td.Operators.AND]=bd.andUtil,Zi[Td.Operators.OR]=bd.orUtil,Zi[Td.Operators.XOR]=bd.xorUtil,Zi)});var l_=h(zr=>{"use strict";var Ed=zr&&zr.__spreadArrays||function(){for(var r=0,e=0,t=arguments.length;e{"use strict";Xi.__esModule=!0;var c_=l_();Xi.getEvaluator=c_.getEvaluator;Xi.evaluate=c_.evaluate;var zO=gd();Xi.parse=zO.parse});var eA={};w_(eA,{default:()=>Ya});module.exports=M_(eA);var y_=require("obsidian");var ys=require("obsidian");var rA=new Error("timeout while waiting for mutex to become available"),nA=new Error("mutex already locked"),D_=new Error("request for lock canceled"),Kd=function(r,e,t,n){function i(s){return s instanceof t?s:new t(function(a){a(s)})}return new(t||(t=Promise))(function(s,a){function o(c){try{l(n.next(c))}catch(d){a(d)}}function u(c){try{l(n.throw(c))}catch(d){a(d)}}function l(c){c.done?s(c.value):i(c.value).then(o,u)}l((n=n.apply(r,e||[])).next())})},Ha=class{constructor(e,t=D_){if(this._maxConcurrency=e,this._cancelError=t,this._queue=[],this._waiters=[],e<=0)throw new Error("semaphore must be initialized to a positive value");this._value=e}acquire(){let e=this.isLocked(),t=new Promise((n,i)=>this._queue.push({resolve:n,reject:i}));return e||this._dispatch(),t}runExclusive(e){return Kd(this,void 0,void 0,function*(){let[t,n]=yield this.acquire();try{return yield e(t)}finally{n()}})}waitForUnlock(){return Kd(this,void 0,void 0,function*(){return this.isLocked()?new Promise(t=>this._waiters.push({resolve:t})):Promise.resolve()})}isLocked(){return this._value<=0}release(){if(this._maxConcurrency>1)throw new Error("this method is unavailable on semaphores with concurrency > 1; use the scoped release returned by acquire instead");if(this._currentReleaser){let e=this._currentReleaser;this._currentReleaser=void 0,e()}}cancel(){this._queue.forEach(e=>e.reject(this._cancelError)),this._queue=[]}_dispatch(){let e=this._queue.shift();if(!e)return;let t=!1;this._currentReleaser=()=>{t||(t=!0,this._value++,this._resolveWaiters(),this._dispatch())},e.resolve([this._value--,this._currentReleaser])}_resolveWaiters(){this._waiters.forEach(e=>e.resolve()),this._waiters=[]}},P_=function(r,e,t,n){function i(s){return s instanceof t?s:new t(function(a){a(s)})}return new(t||(t=Promise))(function(s,a){function o(c){try{l(n.next(c))}catch(d){a(d)}}function u(c){try{l(n.throw(c))}catch(d){a(d)}}function l(c){c.done?s(c.value):i(c.value).then(o,u)}l((n=n.apply(r,e||[])).next())})},os=class{constructor(e){this._semaphore=new Ha(1,e)}acquire(){return P_(this,void 0,void 0,function*(){let[,e]=yield this._semaphore.acquire();return e})}runExclusive(e){return this._semaphore.runExclusive(()=>e())}isLocked(){return this._semaphore.isLocked()}waitForUnlock(){return this._semaphore.waitForUnlock()}release(){this._semaphore.release()}cancel(){return this._semaphore.cancel()}};var rp=require("obsidian");var Vd=require("obsidian");var O_={globalFilter:"",removeGlobalFilter:!1,setDoneDate:!0,autoSuggestInEditor:!0,autoSuggestMinMatch:0,autoSuggestMaxItems:6},za=$e({},O_),ie=()=>$e({},za),Ft=r=>(za=$e($e({},za),r),ie());var Ka,Va,Zd=({metadataCache:r,vault:e})=>{Ka=r,Va=e},us=t=>ae(void 0,[t],function*({originalTask:r,newTasks:e}){if(Va===void 0||Ka===void 0){console.error("Tasks: cannot use File before initializing it.");return}Array.isArray(e)||(e=[e]),Xd({originalTask:r,newTasks:e,vault:Va,metadataCache:Ka,previousTries:0})}),Xd=s=>ae(void 0,[s],function*({originalTask:r,newTasks:e,vault:t,metadataCache:n,previousTries:i}){let a=()=>{if(i>10){console.error("Tasks: Too many retries. File update not possible ...");return}let g=Math.min(Math.pow(10,i),100);setTimeout(()=>{Xd({originalTask:r,newTasks:e,vault:t,metadataCache:n,previousTries:i+1})},g)},o=t.getAbstractFileByPath(r.path);if(!(o instanceof Vd.TFile))return console.warn(`Tasks: No file found for task ${r.description}. Retrying ...`),a();if(o.extension!=="md"){console.error("Tasks: Only supporting files with the .md file extension.");return}let u=n.getFileCache(o);if(u==null||u===null)return console.warn(`Tasks: No file cache found for file ${o.path}. Retrying ...`),a();let l=u.listItems;if(l===void 0||l.length===0)return console.warn(`Tasks: No list items found in file cache of ${o.path}. Retrying ...`),a();let d=(yield t.read(o)).split(` -`),{globalFilter:f}=ie(),p,y=0;for(let g of l){if(g.position.start.lineg.toFileLineString()),...d.slice(p.position.start.line+1)];yield t.modify(o,m.join(` -`))});var Zr=class{constructor(){this.hideTaskCount=!1;this.hideBacklinks=!1;this.hidePriority=!1;this.hideStartDate=!1;this.hideScheduledDate=!1;this.hideDoneDate=!1;this.hideDueDate=!1;this.hideRecurrenceRule=!1;this.hideEditButton=!1;this.shortMode=!1}};var ls=["MO","TU","WE","TH","FR","SA","SU"],_e=function(){function r(e,t){if(t===0)throw new Error("Can't create weekday with n == 0");this.weekday=e,this.n=t}return r.fromStr=function(e){return new r(ls.indexOf(e))},r.prototype.nth=function(e){return this.n===e?this:new r(this.weekday,e)},r.prototype.equals=function(e){return this.weekday===e.weekday&&this.n===e.n},r.prototype.toString=function(){var e=ls[this.weekday];return this.n&&(e=(this.n>0?"+":"")+String(this.n)+e),e},r.prototype.getJsWeekday=function(){return this.weekday===6?0:this.weekday+1},r}();var oe=function(r){return r!=null},Ze=function(r){return typeof r=="number"},Za=function(r){return typeof r=="string"&&ls.includes(r)},xe=Array.isArray,rt=function(r,e){e===void 0&&(e=r),arguments.length===1&&(e=r,r=0);for(var t=[],n=r;n>0,n.length>e?String(n):(e=e-n.length,e>t.length&&(t+=B(t,e/t.length)),t.slice(0,e)+String(n))}var Jd=function(r,e,t){var n=r.split(e);return t?n.slice(0,t).concat([n.slice(t).join(e)]):n},Fe=function(r,e){var t=r%e;return t*e<0?t+e:t},cs=function(r,e){return{div:Math.floor(r/e),mod:Fe(r,e)}},Xe=function(r){return!oe(r)||r.length===0},ye=function(r){return!Xe(r)},G=function(r,e){return ye(r)&&r.indexOf(e)!==-1};var cr;(function(r){r.MONTH_DAYS=[31,28,31,30,31,30,31,31,30,31,30,31],r.ONE_DAY=1e3*60*60*24,r.MAXYEAR=9999,r.ORDINAL_BASE=new Date(Date.UTC(1970,0,1)),r.PY_WEEKDAYS=[6,0,1,2,3,4,5],r.getYearDay=function(e){var t=new Date(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate());return Math.ceil((t.valueOf()-new Date(e.getUTCFullYear(),0,1).valueOf())/r.ONE_DAY)+1},r.isLeapYear=function(e){return e%4===0&&e%100!==0||e%400===0},r.isDate=function(e){return e instanceof Date},r.isValidDate=function(e){return r.isDate(e)&&!isNaN(e.getTime())},r.tzOffset=function(e){return e.getTimezoneOffset()*60*1e3},r.daysBetween=function(e,t){var n=e.getTime()-r.tzOffset(e),i=t.getTime()-r.tzOffset(t),s=n-i;return Math.round(s/r.ONE_DAY)},r.toOrdinal=function(e){return r.daysBetween(e,r.ORDINAL_BASE)},r.fromOrdinal=function(e){return new Date(r.ORDINAL_BASE.getTime()+e*r.ONE_DAY)},r.getMonthDays=function(e){var t=e.getUTCMonth();return t===1&&r.isLeapYear(e.getUTCFullYear())?29:r.MONTH_DAYS[t]},r.getWeekday=function(e){return r.PY_WEEKDAYS[e.getUTCDay()]},r.monthRange=function(e,t){var n=new Date(Date.UTC(e,t,1));return[r.getWeekday(n),r.getMonthDays(n)]},r.combine=function(e,t){return t=t||e,new Date(Date.UTC(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()))},r.clone=function(e){var t=new Date(e.getTime());return t},r.cloneDates=function(e){for(var t=[],n=0;nthis.maxDate;if(this.method==="between"){if(t)return!0;if(n)return!1}else if(this.method==="before"){if(n)return!1}else if(this.method==="after")return t?!0:(this.add(e),!1);return this.add(e)},r.prototype.add=function(e){return this._result.push(e),!0},r.prototype.getValue=function(){var e=this._result;switch(this.method){case"all":case"between":return e;case"before":case"after":default:return e.length?e[e.length-1]:null}},r.prototype.clone=function(){return new r(this.method,this.args)},r}(),qt=A_;var Rf=as(Ef(),1),{__extends:Qr,__assign:je,__rest:_A,__decorate:TA,__param:bA,__metadata:vA,__awaiter:EA,__generator:RA,__exportStar:wA,__createBinding:MA,__values:DA,__read:PA,__spread:OA,__spreadArrays:AA,__spreadArray:T,__await:kA,__asyncGenerator:NA,__asyncDelegator:CA,__asyncValues:xA,__makeTemplateObject:SA,__importStar:IA,__importDefault:UA,__classPrivateFieldGet:FA,__classPrivateFieldSet:qA,__classPrivateFieldIn:WA}=Rf.default;var k_=function(r){Qr(e,r);function e(t,n,i){var s=r.call(this,t,n)||this;return s.iterator=i,s}return e.prototype.add=function(t){return this.iterator(t,this._result.length)?(this._result.push(t),!0):!1},e}(qt),Qa=k_;var N_={dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],tokens:{SKIP:/^[ \r\n\t]+|^\.$/,number:/^[1-9][0-9]*/,numberAsText:/^(one|two|three)/i,every:/^every/i,"day(s)":/^days?/i,"weekday(s)":/^weekdays?/i,"week(s)":/^weeks?/i,"hour(s)":/^hours?/i,"minute(s)":/^minutes?/i,"month(s)":/^months?/i,"year(s)":/^years?/i,on:/^(on|in)/i,at:/^(at)/i,the:/^the/i,first:/^first/i,second:/^second/i,third:/^third/i,nth:/^([1-9][0-9]*)(\.|th|nd|rd|st)/i,last:/^last/i,for:/^for/i,"time(s)":/^times?/i,until:/^(un)?til/i,monday:/^mo(n(day)?)?/i,tuesday:/^tu(e(s(day)?)?)?/i,wednesday:/^we(d(n(esday)?)?)?/i,thursday:/^th(u(r(sday)?)?)?/i,friday:/^fr(i(day)?)?/i,saturday:/^sa(t(urday)?)?/i,sunday:/^su(n(day)?)?/i,january:/^jan(uary)?/i,february:/^feb(ruary)?/i,march:/^mar(ch)?/i,april:/^apr(il)?/i,may:/^may/i,june:/^june?/i,july:/^july?/i,august:/^aug(ust)?/i,september:/^sep(t(ember)?)?/i,october:/^oct(ober)?/i,november:/^nov(ember)?/i,december:/^dec(ember)?/i,comma:/^(,\s*|(and|or)\s*)+/i}},kr=N_;var wf=function(r,e){return r.indexOf(e)!==-1},C_=function(r){return r.toString()},x_=function(r,e,t){return"".concat(e," ").concat(t,", ").concat(r)},S_=function(){function r(e,t,n,i){if(t===void 0&&(t=C_),n===void 0&&(n=kr),i===void 0&&(i=x_),this.text=[],this.language=n||kr,this.gettext=t,this.dateFormatter=i,this.rrule=e,this.options=e.options,this.origOptions=e.origOptions,this.origOptions.bymonthday){var s=[].concat(this.options.bymonthday),a=[].concat(this.options.bynmonthday);s.sort(function(c,d){return c-d}),a.sort(function(c,d){return d-c}),this.bymonthday=s.concat(a),this.bymonthday.length||(this.bymonthday=null)}if(oe(this.origOptions.byweekday)){var o=xe(this.origOptions.byweekday)?this.origOptions.byweekday:[this.origOptions.byweekday],u=String(o);this.byweekday={allWeeks:o.filter(function(c){return!c.n}),someWeeks:o.filter(function(c){return Boolean(c.n)}),isWeekdays:u.indexOf("MO")!==-1&&u.indexOf("TU")!==-1&&u.indexOf("WE")!==-1&&u.indexOf("TH")!==-1&&u.indexOf("FR")!==-1&&u.indexOf("SA")===-1&&u.indexOf("SU")===-1,isEveryDay:u.indexOf("MO")!==-1&&u.indexOf("TU")!==-1&&u.indexOf("WE")!==-1&&u.indexOf("TH")!==-1&&u.indexOf("FR")!==-1&&u.indexOf("SA")!==-1&&u.indexOf("SU")!==-1};var l=function(c,d){return c.weekday-d.weekday};this.byweekday.allWeeks.sort(l),this.byweekday.someWeeks.sort(l),this.byweekday.allWeeks.length||(this.byweekday.allWeeks=null),this.byweekday.someWeeks.length||(this.byweekday.someWeeks=null)}else this.byweekday=null}return r.isFullyConvertible=function(e){var t=!0;if(!(e.options.freq in r.IMPLEMENTED)||e.origOptions.until&&e.origOptions.count)return!1;for(var n in e.origOptions){if(wf(["dtstart","wkst","freq"],n))return!0;if(!wf(r.IMPLEMENTED[e.options.freq],n))return!1}return t},r.prototype.isFullyConvertible=function(){return r.isFullyConvertible(this.rrule)},r.prototype.toString=function(){var e=this.gettext;if(!(this.options.freq in r.IMPLEMENTED))return e("RRule error: Unable to fully convert this rrule to text");if(this.text=[e("every")],this[w.FREQUENCIES[this.options.freq]](),this.options.until){this.add(e("until"));var t=this.options.until;this.add(this.dateFormatter(t.getUTCFullYear(),this.language.monthNames[t.getUTCMonth()],t.getUTCDate()))}else this.options.count&&this.add(e("for")).add(this.options.count.toString()).add(this.plural(this.options.count)?e("times"):e("time"));return this.isFullyConvertible()||this.add(e("(~ approximate)")),this.text.join("")},r.prototype.HOURLY=function(){var e=this.gettext;this.options.interval!==1&&this.add(this.options.interval.toString()),this.add(this.plural(this.options.interval)?e("hours"):e("hour"))},r.prototype.MINUTELY=function(){var e=this.gettext;this.options.interval!==1&&this.add(this.options.interval.toString()),this.add(this.plural(this.options.interval)?e("minutes"):e("minute"))},r.prototype.DAILY=function(){var e=this.gettext;this.options.interval!==1&&this.add(this.options.interval.toString()),this.byweekday&&this.byweekday.isWeekdays?this.add(this.plural(this.options.interval)?e("weekdays"):e("weekday")):this.add(this.plural(this.options.interval)?e("days"):e("day")),this.origOptions.bymonth&&(this.add(e("in")),this._bymonth()),this.bymonthday?this._bymonthday():this.byweekday?this._byweekday():this.origOptions.byhour&&this._byhour()},r.prototype.WEEKLY=function(){var e=this.gettext;this.options.interval!==1&&this.add(this.options.interval.toString()).add(this.plural(this.options.interval)?e("weeks"):e("week")),this.byweekday&&this.byweekday.isWeekdays?this.options.interval===1?this.add(this.plural(this.options.interval)?e("weekdays"):e("weekday")):this.add(e("on")).add(e("weekdays")):this.byweekday&&this.byweekday.isEveryDay?this.add(this.plural(this.options.interval)?e("days"):e("day")):(this.options.interval===1&&this.add(e("week")),this.origOptions.bymonth&&(this.add(e("in")),this._bymonth()),this.bymonthday?this._bymonthday():this.byweekday&&this._byweekday())},r.prototype.MONTHLY=function(){var e=this.gettext;this.origOptions.bymonth?(this.options.interval!==1&&(this.add(this.options.interval.toString()).add(e("months")),this.plural(this.options.interval)&&this.add(e("in"))),this._bymonth()):(this.options.interval!==1&&this.add(this.options.interval.toString()),this.add(this.plural(this.options.interval)?e("months"):e("month"))),this.bymonthday?this._bymonthday():this.byweekday&&this.byweekday.isWeekdays?this.add(e("on")).add(e("weekdays")):this.byweekday&&this._byweekday()},r.prototype.YEARLY=function(){var e=this.gettext;this.origOptions.bymonth?(this.options.interval!==1&&(this.add(this.options.interval.toString()),this.add(e("years"))),this._bymonth()):(this.options.interval!==1&&this.add(this.options.interval.toString()),this.add(this.plural(this.options.interval)?e("years"):e("year"))),this.bymonthday?this._bymonthday():this.byweekday&&this._byweekday(),this.options.byyearday&&this.add(e("on the")).add(this.list(this.options.byyearday,this.nth,e("and"))).add(e("day")),this.options.byweekno&&this.add(e("in")).add(this.plural(this.options.byweekno.length)?e("weeks"):e("week")).add(this.list(this.options.byweekno,void 0,e("and")))},r.prototype._bymonthday=function(){var e=this.gettext;this.byweekday&&this.byweekday.allWeeks?this.add(e("on")).add(this.list(this.byweekday.allWeeks,this.weekdaytext,e("or"))).add(e("the")).add(this.list(this.bymonthday,this.nth,e("or"))):this.add(e("on the")).add(this.list(this.bymonthday,this.nth,e("and")))},r.prototype._byweekday=function(){var e=this.gettext;this.byweekday.allWeeks&&!this.byweekday.isWeekdays&&this.add(e("on")).add(this.list(this.byweekday.allWeeks,this.weekdaytext)),this.byweekday.someWeeks&&(this.byweekday.allWeeks&&this.add(e("and")),this.add(e("on the")).add(this.list(this.byweekday.someWeeks,this.weekdaytext,e("and"))))},r.prototype._byhour=function(){var e=this.gettext;this.add(e("at")).add(this.list(this.origOptions.byhour,void 0,e("and")))},r.prototype._bymonth=function(){this.add(this.list(this.options.bymonth,this.monthtext,this.gettext("and")))},r.prototype.nth=function(e){e=parseInt(e.toString(),10);var t,n=this.gettext;if(e===-1)return n("last");var i=Math.abs(e);switch(i){case 1:case 21:case 31:t=i+n("st");break;case 2:case 22:t=i+n("nd");break;case 3:case 23:t=i+n("rd");break;default:t=i+n("th")}return e<0?t+" "+n("last"):t},r.prototype.monthtext=function(e){return this.language.monthNames[e-1]},r.prototype.weekdaytext=function(e){var t=Ze(e)?(e+1)%7:e.getJsWeekday();return(e.n?this.nth(e.n)+" ":"")+this.language.dayNames[t]},r.prototype.plural=function(e){return e%100!==1},r.prototype.add=function(e){return this.text.push(" "),this.text.push(e),this},r.prototype.list=function(e,t,n,i){var s=this;i===void 0&&(i=","),xe(e)||(e=[e]);var a=function(u,l,c){for(var d="",f=0;fe[0].length)&&(e=s,t=i)}if(e!=null&&(this.text=this.text.substr(e[0].length),this.text===""&&(this.done=!0)),e==null){this.done=!0,this.symbol=null,this.value=null;return}}while(t==="SKIP");return this.symbol=t,this.value=e,!0},r.prototype.accept=function(e){if(this.symbol===e){if(this.value){var t=this.value;return this.nextSymbol(),t}return this.nextSymbol(),!0}return!1},r.prototype.acceptNumber=function(){return this.accept("number")},r.prototype.expect=function(e){if(this.accept(e))return!0;throw new Error("expected "+e+" but found "+this.symbol)},r}();function Cn(r,e){e===void 0&&(e=kr);var t={},n=new I_(e.tokens);if(!n.start(r))return null;return i(),t;function i(){n.expect("every");var f=n.acceptNumber();if(f&&(t.interval=parseInt(f[0],10)),n.isDone())throw new Error("Unexpected end");switch(n.symbol){case"day(s)":t.freq=w.DAILY,n.nextSymbol()&&(a(),d());break;case"weekday(s)":t.freq=w.WEEKLY,t.byweekday=[w.MO,w.TU,w.WE,w.TH,w.FR],n.nextSymbol(),d();break;case"week(s)":t.freq=w.WEEKLY,n.nextSymbol()&&(s(),d());break;case"hour(s)":t.freq=w.HOURLY,n.nextSymbol()&&(s(),d());break;case"minute(s)":t.freq=w.MINUTELY,n.nextSymbol()&&(s(),d());break;case"month(s)":t.freq=w.MONTHLY,n.nextSymbol()&&(s(),d());break;case"year(s)":t.freq=w.YEARLY,n.nextSymbol()&&(s(),d());break;case"monday":case"tuesday":case"wednesday":case"thursday":case"friday":case"saturday":case"sunday":t.freq=w.WEEKLY;var p=n.symbol.substr(0,2).toUpperCase();if(t.byweekday=[w[p]],!n.nextSymbol())return;for(;n.accept("comma");){if(n.isDone())throw new Error("Unexpected end");var y=u();if(!y)throw new Error("Unexpected symbol "+n.symbol+", expected weekday");t.byweekday.push(w[y]),n.nextSymbol()}c(),d();break;case"january":case"february":case"march":case"april":case"may":case"june":case"july":case"august":case"september":case"october":case"november":case"december":if(t.freq=w.YEARLY,t.bymonth=[o()],!n.nextSymbol())return;for(;n.accept("comma");){if(n.isDone())throw new Error("Unexpected end");var m=o();if(!m)throw new Error("Unexpected symbol "+n.symbol+", expected month");t.bymonth.push(m),n.nextSymbol()}s(),d();break;default:throw new Error("Unknown symbol")}}function s(){var f=n.accept("on"),p=n.accept("the");if(!!(f||p))do{var y=l(),m=u(),g=o();if(y)m?(n.nextSymbol(),t.byweekday||(t.byweekday=[]),t.byweekday.push(w[m].nth(y))):(t.bymonthday||(t.bymonthday=[]),t.bymonthday.push(y),n.accept("day(s)"));else if(m)n.nextSymbol(),t.byweekday||(t.byweekday=[]),t.byweekday.push(w[m]);else if(n.symbol==="weekday(s)")n.nextSymbol(),t.byweekday||(t.byweekday=[w.MO,w.TU,w.WE,w.TH,w.FR]);else if(n.symbol==="week(s)"){n.nextSymbol();var A=n.acceptNumber();if(!A)throw new Error("Unexpected symbol "+n.symbol+", expected week number");for(t.byweekno=[parseInt(A[0],10)];n.accept("comma");){if(A=n.acceptNumber(),!A)throw new Error("Unexpected symbol "+n.symbol+"; expected monthday");t.byweekno.push(parseInt(A[0],10))}}else if(g)n.nextSymbol(),t.bymonth||(t.bymonth=[]),t.bymonth.push(g);else return}while(n.accept("comma")||n.accept("the")||n.accept("on"))}function a(){var f=n.accept("at");if(!!f)do{var p=n.acceptNumber();if(!p)throw new Error("Unexpected symbol "+n.symbol+", expected hour");for(t.byhour=[parseInt(p[0],10)];n.accept("comma");){if(p=n.acceptNumber(),!p)throw new Error("Unexpected symbol "+n.symbol+"; expected hour");t.byhour.push(parseInt(p[0],10))}}while(n.accept("comma")||n.accept("at"))}function o(){switch(n.symbol){case"january":return 1;case"february":return 2;case"march":return 3;case"april":return 4;case"may":return 5;case"june":return 6;case"july":return 7;case"august":return 8;case"september":return 9;case"october":return 10;case"november":return 11;case"december":return 12;default:return!1}}function u(){switch(n.symbol){case"monday":case"tuesday":case"wednesday":case"thursday":case"friday":case"saturday":case"sunday":return n.symbol.substr(0,2).toUpperCase();default:return!1}}function l(){switch(n.symbol){case"last":return n.nextSymbol(),-1;case"first":return n.nextSymbol(),1;case"second":return n.nextSymbol(),n.accept("last")?-2:2;case"third":return n.nextSymbol(),n.accept("last")?-3:3;case"nth":var f=parseInt(n.value[1],10);if(f<-366||f>366)throw new Error("Nth out of range: "+f);return n.nextSymbol(),n.accept("last")?-f:f;default:return!1}}function c(){n.accept("on"),n.accept("the");var f=l();if(!!f)for(t.bymonthday=[f],n.nextSymbol();n.accept("comma");){if(f=l(),!f)throw new Error("Unexpected symbol "+n.symbol+"; expected monthday");t.bymonthday.push(f),n.nextSymbol()}}function d(){if(n.symbol==="until"){var f=Date.parse(n.text);if(!f)throw new Error("Cannot parse until date:"+n.text);t.until=new Date(f)}else n.accept("for")&&(t.count=parseInt(n.value[0],10),n.expect("number"))}}var Y;(function(r){r[r.YEARLY=0]="YEARLY",r[r.MONTHLY=1]="MONTHLY",r[r.WEEKLY=2]="WEEKLY",r[r.DAILY=3]="DAILY",r[r.HOURLY=4]="HOURLY",r[r.MINUTELY=5]="MINUTELY",r[r.SECONDLY=6]="SECONDLY"})(Y||(Y={}));function xn(r){return r12){var n=Math.floor(this.month/12),i=Fe(this.month,12);this.month=i,this.year+=n,this.month===0&&(this.month=12,--this.year)}},e.prototype.addWeekly=function(t,n){n>this.getWeekday()?this.day+=-(this.getWeekday()+1+(6-n))+t*7:this.day+=-(this.getWeekday()-n)+t*7,this.fixDay()},e.prototype.addDaily=function(t){this.day+=t,this.fixDay()},e.prototype.addHours=function(t,n,i){for(n&&(this.hour+=Math.floor((23-this.hour)/t)*t);;){this.hour+=t;var s=cs(this.hour,24),a=s.div,o=s.mod;if(a&&(this.hour=o,this.addDaily(a)),Xe(i)||G(i,this.hour))break}},e.prototype.addMinutes=function(t,n,i,s){for(n&&(this.minute+=Math.floor((1439-(this.hour*60+this.minute))/t)*t);;){this.minute+=t;var a=cs(this.minute,60),o=a.div,u=a.mod;if(o&&(this.minute=u,this.addHours(o,!1,i)),(Xe(i)||G(i,this.hour))&&(Xe(s)||G(s,this.minute)))break}},e.prototype.addSeconds=function(t,n,i,s,a){for(n&&(this.second+=Math.floor((86399-(this.hour*3600+this.minute*60+this.second))/t)*t);;){this.second+=t;var o=cs(this.second,60),u=o.div,l=o.mod;if(u&&(this.second=l,this.addMinutes(u,!1,i,s)),(Xe(i)||G(i,this.hour))&&(Xe(s)||G(s,this.minute))&&(Xe(a)||G(a,this.second)))break}},e.prototype.fixDay=function(){if(!(this.day<=28)){var t=cr.monthRange(this.year,this.month-1)[1];if(!(this.day<=t))for(;this.day>t;){if(this.day-=t,++this.month,this.month===13&&(this.month=1,++this.year,this.year>cr.MAXYEAR))return;t=cr.monthRange(this.year,this.month-1)[1]}}},e.prototype.add=function(t,n){var i=t.freq,s=t.interval,a=t.wkst,o=t.byhour,u=t.byminute,l=t.bysecond;switch(i){case Y.YEARLY:return this.addYears(s);case Y.MONTHLY:return this.addMonths(s);case Y.WEEKLY:return this.addWeekly(s,a);case Y.DAILY:return this.addDaily(s);case Y.HOURLY:return this.addHours(s,n,o);case Y.MINUTELY:return this.addMinutes(s,n,o,u);case Y.SECONDLY:return this.addSeconds(s,n,o,u,l)}},e}(en);function Ja(r){for(var e=[],t=Object.keys(r),n=0,i=t;n=-366&&n<=366))throw new Error("bysetpos must be between 1 and 366, or between -366 and -1")}}if(!(Boolean(e.byweekno)||ye(e.byweekno)||ye(e.byyearday)||Boolean(e.bymonthday)||ye(e.bymonthday)||oe(e.byweekday)||oe(e.byeaster)))switch(e.freq){case w.YEARLY:e.bymonth||(e.bymonth=e.dtstart.getUTCMonth()+1),e.bymonthday=e.dtstart.getUTCDate();break;case w.MONTHLY:e.bymonthday=e.dtstart.getUTCDate();break;case w.WEEKLY:e.byweekday=[k.getWeekday(e.dtstart)];break}if(oe(e.bymonth)&&!xe(e.bymonth)&&(e.bymonth=[e.bymonth]),oe(e.byyearday)&&!xe(e.byyearday)&&Ze(e.byyearday)&&(e.byyearday=[e.byyearday]),!oe(e.bymonthday))e.bymonthday=[],e.bynmonthday=[];else if(xe(e.bymonthday)){for(var i=[],s=[],t=0;t0?i.push(n):n<0&&s.push(n)}e.bymonthday=i,e.bynmonthday=s}else e.bymonthday<0?(e.bynmonthday=[e.bymonthday],e.bymonthday=[]):(e.bynmonthday=[],e.bymonthday=[e.bymonthday]);if(oe(e.byweekno)&&!xe(e.byweekno)&&(e.byweekno=[e.byweekno]),!oe(e.byweekday))e.bynweekday=null;else if(Ze(e.byweekday))e.byweekday=[e.byweekday],e.bynweekday=null;else if(Za(e.byweekday))e.byweekday=[_e.fromStr(e.byweekday).weekday],e.bynweekday=null;else if(e.byweekday instanceof _e)!e.byweekday.n||e.freq>w.MONTHLY?(e.byweekday=[e.byweekday.weekday],e.bynweekday=null):(e.bynweekday=[[e.byweekday.weekday,e.byweekday.n]],e.byweekday=null);else{for(var a=[],o=[],t=0;tw.MONTHLY?a.push(u.weekday):o.push([u.weekday,u.n])}e.byweekday=ye(a)?a:null,e.bynweekday=ye(o)?o:null}return oe(e.byhour)?Ze(e.byhour)&&(e.byhour=[e.byhour]):e.byhour=e.freq=4?(c=0,l=o.yearlen+Fe(a-e.wkst,7)):l=n-c;for(var d=Math.floor(l/7),f=Fe(l,7),p=Math.floor(d+f/4),y=0;y0&&m<=p){var g=void 0;m>1?(g=c+(m-1)*7,c!==u&&(g-=7-u)):g=c;for(var A=0;A<7&&(o.wnomask[g]=1,g++,o.wdaymask[g]!==e.wkst);A++);}}if(G(e.byweekno,1)){var g=c+p*7;if(c!==u&&(g-=7-u),g=4?(z=0,fe=ne+Fe(C-e.wkst,7)):fe=n-c,x=Math.floor(52+Fe(fe,7)/4)}if(G(e.byweekno,x))for(var g=0;gs)return Wt(r);if(x>=t){var C=Kf(x,e);if(!r.accept(C)||o&&(--o,!o))return Wt(r)}}else for(var A=p;As)return Wt(r);if(x>=t){var C=Kf(x,e);if(!r.accept(C)||o&&(--o,!o))return Wt(r)}}}if(e.interval===0||(u.add(e,m),u.year>k.MAXYEAR))return Wt(r);xn(n)||(c=l.gettimeset(n)(u.hour,u.minute,u.second,0)),l.rebuild(u.year,u.month)}}function z_(r,e,t){var n=t.bymonth,i=t.byweekno,s=t.byweekday,a=t.byeaster,o=t.bymonthday,u=t.bynmonthday,l=t.byyearday;return ye(n)&&!G(n,r.mmask[e])||ye(i)&&!r.wnomask[e]||ye(s)&&!G(s,r.wdaymask[e])||ye(r.nwdaymask)&&!r.nwdaymask[e]||a!==null&&!G(r.eastermask,e)||(ye(o)||ye(u))&&!G(o,r.mdaymask[e])&&!G(u,r.nmdaymask[e])||ye(l)&&(e=r.yearlen&&!G(l,e+1-r.yearlen)&&!G(l,-r.nextyearlen+e-r.yearlen))}function Kf(r,e){return new Nr(r,e.tzid).rezonedDate()}function Wt(r){return r.getValue()}function K_(r,e,t,n,i){for(var s=!1,a=e;a=w.HOURLY&&ye(i)&&!G(i,e.hour)||n>=w.MINUTELY&&ye(s)&&!G(s,e.minute)||n>=w.SECONDLY&&ye(a)&&!G(a,e.second)?[]:r.gettimeset(n)(e.hour,e.minute,e.second,e.millisecond)}var nt={MO:new _e(0),TU:new _e(1),WE:new _e(2),TH:new _e(3),FR:new _e(4),SA:new _e(5),SU:new _e(6)},Sn={freq:Y.YEARLY,dtstart:null,interval:1,wkst:nt.MO,count:null,until:null,tzid:null,bysetpos:null,bymonth:null,bymonthday:null,bynmonthday:null,byyearday:null,byweekno:null,byweekday:null,bynweekday:null,byhour:null,byminute:null,bysecond:null,byeaster:null},Nf=Object.keys(Sn),w=function(){function r(e,t){e===void 0&&(e={}),t===void 0&&(t=!1),this._cache=t?null:new Sf,this.origOptions=Ja(e);var n=Af(e).parsedOptions;this.options=n}return r.parseText=function(e,t){return Cn(e,t)},r.fromText=function(e,t){return Mf(e,t)},r.fromString=function(e){return new r(r.parseString(e)||void 0)},r.prototype._iter=function(e){return hs(e,this.options)},r.prototype._cacheGet=function(e,t){return this._cache?this._cache._cacheGet(e,t):!1},r.prototype._cacheAdd=function(e,t,n){if(!!this._cache)return this._cache._cacheAdd(e,t,n)},r.prototype.all=function(e){if(e)return this._iter(new Qa("all",{},e));var t=this._cacheGet("all");return t===!1&&(t=this._iter(new qt("all",{})),this._cacheAdd("all",t)),t},r.prototype.between=function(e,t,n,i){if(n===void 0&&(n=!1),!k.isValidDate(e)||!k.isValidDate(t))throw new Error("Invalid date passed in to RRule.between");var s={before:t,after:e,inc:n};if(i)return this._iter(new Qa("between",s,i));var a=this._cacheGet("between",s);return a===!1&&(a=this._iter(new qt("between",s)),this._cacheAdd("between",a,s)),a},r.prototype.before=function(e,t){if(t===void 0&&(t=!1),!k.isValidDate(e))throw new Error("Invalid date passed in to RRule.before");var n={dt:e,inc:t},i=this._cacheGet("before",n);return i===!1&&(i=this._iter(new qt("before",n)),this._cacheAdd("before",i,n)),i},r.prototype.after=function(e,t){if(t===void 0&&(t=!1),!k.isValidDate(e))throw new Error("Invalid date passed in to RRule.after");var n={dt:e,inc:t},i=this._cacheGet("after",n);return i===!1&&(i=this._iter(new qt("after",n)),this._cacheAdd("after",i,n)),i},r.prototype.count=function(){return this.all().length},r.prototype.toString=function(){return Fn(this.origOptions)},r.prototype.toText=function(e,t,n){return Df(this,e,t,n)},r.prototype.isFullyConvertibleToText=function(){return Pf(this)},r.prototype.clone=function(){return new r(this.origOptions)},r.FREQUENCIES=["YEARLY","MONTHLY","WEEKLY","DAILY","HOURLY","MINUTELY","SECONDLY"],r.YEARLY=Y.YEARLY,r.MONTHLY=Y.MONTHLY,r.WEEKLY=Y.WEEKLY,r.DAILY=Y.DAILY,r.HOURLY=Y.HOURLY,r.MINUTELY=Y.MINUTELY,r.SECONDLY=Y.SECONDLY,r.MO=nt.MO,r.TU=nt.TU,r.WE=nt.WE,r.TH=nt.TH,r.FR=nt.FR,r.SA=nt.SA,r.SU=nt.SU,r.parseString=Un,r.optionsToString=Fn,r}();function Vf(r,e,t,n,i,s){var a={},o=r.accept;function u(f,p){t.forEach(function(y){y.between(f,p,!0).forEach(function(m){a[Number(m)]=!0})})}i.forEach(function(f){var p=new Nr(f,s).rezonedDate();a[Number(p)]=!0}),r.accept=function(f){var p=Number(f);return isNaN(p)?o.call(this,f):!a[p]&&(u(new Date(p-1),new Date(p+1)),!a[p])?(a[p]=!0,o.call(this,f)):!0},r.method==="between"&&(u(r.args.after,r.args.before),r.accept=function(f){var p=Number(f);return a[p]?!0:(a[p]=!0,o.call(this,f))});for(var l=0;l1||i.length||s.length||a.length){var c=new ro(l);return c.dtstart(o),c.tzid(u||void 0),n.forEach(function(f){c.rrule(new w(to(f,o,u),l))}),i.forEach(function(f){c.rdate(f)}),s.forEach(function(f){c.exrule(new w(to(f,o,u),l))}),a.forEach(function(f){c.exdate(f)}),e.compatible&&e.dtstart&&c.rdate(o),c}var d=n[0]||{};return new w(to(d,d.dtstart||e.dtstart||o,d.tzid||e.tzid||u),l)}function ms(r,e){return e===void 0&&(e={}),X_(r,Q_(e))}function to(r,e,t){return je(je({},r),{dtstart:e,tzid:t})}function Q_(r){var e=[],t=Object.keys(r),n=Object.keys(Zf);if(t.forEach(function(i){G(n,i)||e.push(i)}),e.length)throw new Error("Invalid options: "+e.join(", "));return je(je({},Zf),r)}function J_(r){if(r.indexOf(":")===-1)return{name:"RRULE",value:r};var e=Jd(r,":",1),t=e[0],n=e[1];return{name:t,value:n}}function eT(r){var e=J_(r),t=e.name,n=e.value,i=t.split(";");if(!i)throw new Error("empty property name");return{name:i[0].toUpperCase(),parms:i.slice(1),value:n}}function tT(r,e){if(e===void 0&&(e=!1),r=r&&r.trim(),!r)throw new Error("Invalid empty string");if(!e)return r.split(/\s/);for(var t=r.split(` -`),n=0;n0&&i[0]===" "?(t[n-1]+=i.slice(1),t.splice(n,1)):n+=1:t.splice(n,1)}return t}function rT(r){r.forEach(function(e){if(!/(VALUE=DATE(-TIME)?)|(TZID=)/.test(e))throw new Error("unsupported RDATE/EXDATE parm: "+e)})}function Xf(r,e){return rT(e),r.split(",").map(function(t){return k.untilStringToDate(t)})}function Qf(r){var e=this;return function(t){if(t!==void 0&&(e["_".concat(r)]=t),e["_".concat(r)]!==void 0)return e["_".concat(r)];for(var n=0;ne in r?Nn(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,$e=(r,e)=>{for(var t in e||(e={}))Kd.call(e,t)&&zd(r,t,e[t]);if(Hd)for(var t of Hd(e))M_.call(e,t)&&zd(r,t,e[t]);return r},Ft=(r,e)=>b_(r,E_(e));var h=(r,e)=>()=>(e||r((e={exports:{}}).exports,e),e.exports),D_=(r,e)=>{for(var t in e)Nn(r,t,{get:e[t],enumerable:!0})},Vd=(r,e,t,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of R_(e))!Kd.call(r,i)&&i!==t&&Nn(r,i,{get:()=>e[i],enumerable:!(n=v_(e,i))||n.enumerable});return r};var os=(r,e,t)=>(t=r!=null?T_(w_(r)):{},Vd(e||!r||!r.__esModule?Nn(t,"default",{value:r,enumerable:!0}):t,r)),P_=r=>Vd(Nn({},"__esModule",{value:!0}),r);var se=(r,e,t)=>new Promise((n,i)=>{var s=u=>{try{o(t.next(u))}catch(l){i(l)}},a=u=>{try{o(t.throw(u))}catch(l){i(l)}},o=u=>u.done?n(u.value):Promise.resolve(u.value).then(s,a);o((t=t.apply(r,e)).next())});var Mf=h((wA,hs)=>{var nf,sf,af,of,uf,lf,cf,df,ff,fs,Qa,pf,hf,mf,Qr,yf,gf,_f,Tf,bf,vf,Ef,Rf,wf,ps;(function(r){var e=typeof global=="object"?global:typeof self=="object"?self:typeof this=="object"?this:{};typeof define=="function"&&define.amd?define("tslib",["exports"],function(n){r(t(e,t(n)))}):typeof hs=="object"&&typeof hs.exports=="object"?r(t(e,t(hs.exports))):r(t(e));function t(n,i){return n!==e&&(typeof Object.create=="function"?Object.defineProperty(n,"__esModule",{value:!0}):n.__esModule=!0),function(s,a){return n[s]=i?i(s,a):a}}})(function(r){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var s in i)Object.prototype.hasOwnProperty.call(i,s)&&(n[s]=i[s])};nf=function(n,i){if(typeof i!="function"&&i!==null)throw new TypeError("Class extends value "+String(i)+" is not a constructor or null");e(n,i);function s(){this.constructor=n}n.prototype=i===null?Object.create(i):(s.prototype=i.prototype,new s)},sf=Object.assign||function(n){for(var i,s=1,a=arguments.length;s=0;c--)(l=n[c])&&(u=(o<3?l(u):o>3?l(i,s,u):l(i,s))||u);return o>3&&u&&Object.defineProperty(i,s,u),u},uf=function(n,i){return function(s,a){i(s,a,n)}},lf=function(n,i){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(n,i)},cf=function(n,i,s,a){function o(u){return u instanceof s?u:new s(function(l){l(u)})}return new(s||(s=Promise))(function(u,l){function c(p){try{f(a.next(p))}catch(y){l(y)}}function d(p){try{f(a.throw(p))}catch(y){l(y)}}function f(p){p.done?u(p.value):o(p.value).then(c,d)}f((a=a.apply(n,i||[])).next())})},df=function(n,i){var s={label:0,sent:function(){if(u[0]&1)throw u[1];return u[1]},trys:[],ops:[]},a,o,u,l;return l={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(l[Symbol.iterator]=function(){return this}),l;function c(f){return function(p){return d([f,p])}}function d(f){if(a)throw new TypeError("Generator is already executing.");for(;s;)try{if(a=1,o&&(u=f[0]&2?o.return:f[0]?o.throw||((u=o.return)&&u.call(o),0):o.next)&&!(u=u.call(o,f[1])).done)return u;switch(o=0,u&&(f=[f[0]&2,u.value]),f[0]){case 0:case 1:u=f;break;case 4:return s.label++,{value:f[1],done:!1};case 5:s.label++,o=f[1],f=[0];continue;case 7:f=s.ops.pop(),s.trys.pop();continue;default:if(u=s.trys,!(u=u.length>0&&u[u.length-1])&&(f[0]===6||f[0]===2)){s=0;continue}if(f[0]===3&&(!u||f[1]>u[0]&&f[1]=n.length&&(n=void 0),{value:n&&n[a++],done:!n}}};throw new TypeError(i?"Object is not iterable.":"Symbol.iterator is not defined.")},Qa=function(n,i){var s=typeof Symbol=="function"&&n[Symbol.iterator];if(!s)return n;var a=s.call(n),o,u=[],l;try{for(;(i===void 0||i-- >0)&&!(o=a.next()).done;)u.push(o.value)}catch(c){l={error:c}}finally{try{o&&!o.done&&(s=a.return)&&s.call(a)}finally{if(l)throw l.error}}return u},pf=function(){for(var n=[],i=0;i1||c(m,g)})})}function c(m,g){try{d(a[m](g))}catch(A){y(u[0][3],A)}}function d(m){m.value instanceof Qr?Promise.resolve(m.value.v).then(f,p):y(u[0][2],m)}function f(m){c("next",m)}function p(m){c("throw",m)}function y(m,g){m(g),u.shift(),u.length&&c(u[0][0],u[0][1])}},gf=function(n){var i,s;return i={},a("next"),a("throw",function(o){throw o}),a("return"),i[Symbol.iterator]=function(){return this},i;function a(o,u){i[o]=n[o]?function(l){return(s=!s)?{value:Qr(n[o](l)),done:o==="return"}:u?u(l):l}:u}},_f=function(n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var i=n[Symbol.asyncIterator],s;return i?i.call(n):(n=typeof fs=="function"?fs(n):n[Symbol.iterator](),s={},a("next"),a("throw"),a("return"),s[Symbol.asyncIterator]=function(){return this},s);function a(u){s[u]=n[u]&&function(l){return new Promise(function(c,d){l=n[u](l),o(c,d,l.done,l.value)})}}function o(u,l,c,d){Promise.resolve(d).then(function(f){u({value:f,done:c})},l)}},Tf=function(n,i){return Object.defineProperty?Object.defineProperty(n,"raw",{value:i}):n.raw=i,n};var t=Object.create?function(n,i){Object.defineProperty(n,"default",{enumerable:!0,value:i})}:function(n,i){n.default=i};bf=function(n){if(n&&n.__esModule)return n;var i={};if(n!=null)for(var s in n)s!=="default"&&Object.prototype.hasOwnProperty.call(n,s)&&ps(i,n,s);return t(i,n),i},vf=function(n){return n&&n.__esModule?n:{default:n}},Ef=function(n,i,s,a){if(s==="a"&&!a)throw new TypeError("Private accessor was defined without a getter");if(typeof i=="function"?n!==i||!a:!i.has(n))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?a:s==="a"?a.call(n):a?a.value:i.get(n)},Rf=function(n,i,s,a,o){if(a==="m")throw new TypeError("Private method is not writable");if(a==="a"&&!o)throw new TypeError("Private accessor was defined without a setter");if(typeof i=="function"?n!==i||!o:!i.has(n))throw new TypeError("Cannot write private member to an object whose class did not declare it");return a==="a"?o.call(n,s):o?o.value=s:i.set(n,s),s},wf=function(n,i){if(i===null||typeof i!="object"&&typeof i!="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof n=="function"?i===n:n.has(i)},r("__extends",nf),r("__assign",sf),r("__rest",af),r("__decorate",of),r("__param",uf),r("__metadata",lf),r("__awaiter",cf),r("__generator",df),r("__exportStar",ff),r("__createBinding",ps),r("__values",fs),r("__read",Qa),r("__spread",pf),r("__spreadArrays",hf),r("__spreadArray",mf),r("__await",Qr),r("__asyncGenerator",yf),r("__asyncDelegator",gf),r("__asyncValues",_f),r("__makeTemplateObject",Tf),r("__importStar",bf),r("__importDefault",vf),r("__classPrivateFieldGet",Ef),r("__classPrivateFieldSet",Rf),r("__classPrivateFieldIn",wf)})});var J=h(yr=>{"use strict";Object.defineProperty(yr,"__esModule",{value:!0});yr.matchAnyPattern=yr.extractTerms=yr.repeatedTimeunitPattern=void 0;function TT(r,e){let t=e.replace(/\((?!\?)/g,"(?:");return`${r}${t}\\s{0,5}(?:,?\\s{0,5}${t}){0,10}`}yr.repeatedTimeunitPattern=TT;function Tp(r){let e;return r instanceof Array?e=[...r]:r instanceof Map?e=Array.from(r.keys()):e=Object.keys(r),e}yr.extractTerms=Tp;function bT(r){return`(?:${Tp(r).sort((t,n)=>n.length-t.length).join("|").replace(/\./g,"\\.")})`}yr.matchAnyPattern=bT});var K=h((fo,po)=>{(function(r,e){typeof fo=="object"&&typeof po!="undefined"?po.exports=e():typeof define=="function"&&define.amd?define(e):(r=typeof globalThis!="undefined"?globalThis:r||self).dayjs=e()})(fo,function(){"use strict";var r=1e3,e=6e4,t=36e5,n="millisecond",i="second",s="minute",a="hour",o="day",u="week",l="month",c="quarter",d="year",f="date",p="Invalid Date",y=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,m=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,g={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_")},A=function(D,v,_){var P=String(D);return!P||P.length>=v?D:""+Array(v+1-P.length).join(_)+D},C={s:A,z:function(D){var v=-D.utcOffset(),_=Math.abs(v),P=Math.floor(_/60),E=_%60;return(v<=0?"+":"-")+A(P,2,"0")+":"+A(E,2,"0")},m:function D(v,_){if(v.date()<_.date())return-D(_,v);var P=12*(_.year()-v.year())+(_.month()-v.month()),E=v.clone().add(P,l),S=_-E<0,O=v.clone().add(P+(S?-1:1),l);return+(-(P+(_-E)/(S?E-O:O-E))||0)},a:function(D){return D<0?Math.ceil(D)||0:Math.floor(D)},p:function(D){return{M:l,y:d,w:u,d:o,D:f,h:a,m:s,s:i,ms:n,Q:c}[D]||String(D||"").toLowerCase().replace(/s$/,"")},u:function(D){return D===void 0}},x="en",z={};z[x]=g;var ie=function(D){return D instanceof ge},fe=function(D,v,_){var P;if(!D)return x;if(typeof D=="string")z[D]&&(P=D),v&&(z[D]=v,P=D);else{var E=D.name;z[E]=D,P=E}return!_&&P&&(x=P),P||!_&&x},te=function(D,v){if(ie(D))return D.clone();var _=typeof v=="object"?v:{};return _.date=D,_.args=arguments,new ge(_)},M=C;M.l=fe,M.i=ie,M.w=function(D,v){return te(D,{locale:v.$L,utc:v.$u,x:v.$x,$offset:v.$offset})};var ge=function(){function D(_){this.$L=fe(_.locale,null,!0),this.parse(_)}var v=D.prototype;return v.parse=function(_){this.$d=function(P){var E=P.date,S=P.utc;if(E===null)return new Date(NaN);if(M.u(E))return new Date;if(E instanceof Date)return new Date(E);if(typeof E=="string"&&!/Z$/i.test(E)){var O=E.match(y);if(O){var W=O[2]-1||0,re=(O[7]||"0").substring(0,3);return S?new Date(Date.UTC(O[1],W,O[3]||1,O[4]||0,O[5]||0,O[6]||0,re)):new Date(O[1],W,O[3]||1,O[4]||0,O[5]||0,O[6]||0,re)}}return new Date(E)}(_),this.$x=_.x||{},this.init()},v.init=function(){var _=this.$d;this.$y=_.getFullYear(),this.$M=_.getMonth(),this.$D=_.getDate(),this.$W=_.getDay(),this.$H=_.getHours(),this.$m=_.getMinutes(),this.$s=_.getSeconds(),this.$ms=_.getMilliseconds()},v.$utils=function(){return M},v.isValid=function(){return this.$d.toString()!==p},v.isSame=function(_,P){var E=te(_);return this.startOf(P)<=E&&E<=this.endOf(P)},v.isAfter=function(_,P){return te(_){"use strict";var vT=gr&&gr.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(gr,"__esModule",{value:!0});gr.findYearClosestToRef=gr.findMostLikelyADYear=void 0;var ET=vT(K());function RT(r){return r<100&&(r>50?r=r+1900:r=r+2e3),r}gr.findMostLikelyADYear=RT;function wT(r,e,t){let n=ET.default(r),i=n;i=i.month(t-1),i=i.date(e),i=i.year(n.year());let s=i.add(1,"y"),a=i.add(-1,"y");return Math.abs(s.diff(n)){"use strict";Object.defineProperty(q,"__esModule",{value:!0});q.parseTimeUnits=q.TIME_UNITS_PATTERN=q.parseYear=q.YEAR_PATTERN=q.parseOrdinalNumberPattern=q.ORDINAL_NUMBER_PATTERN=q.parseNumberPattern=q.NUMBER_PATTERN=q.TIME_UNIT_DICTIONARY=q.ORDINAL_WORD_DICTIONARY=q.INTEGER_WORD_DICTIONARY=q.MONTH_DICTIONARY=q.FULL_MONTH_NAME_DICTIONARY=q.WEEKDAY_DICTIONARY=void 0;var Rs=J(),MT=Se();q.WEEKDAY_DICTIONARY={sunday:0,sun:0,"sun.":0,monday:1,mon:1,"mon.":1,tuesday:2,tue:2,"tue.":2,wednesday:3,wed:3,"wed.":3,thursday:4,thurs:4,"thurs.":4,thur:4,"thur.":4,thu:4,"thu.":4,friday:5,fri:5,"fri.":5,saturday:6,sat:6,"sat.":6};q.FULL_MONTH_NAME_DICTIONARY={january:1,february:2,march:3,april:4,may:5,june:6,july:7,august:8,september:9,october:10,november:11,december:12};q.MONTH_DICTIONARY=Object.assign(Object.assign({},q.FULL_MONTH_NAME_DICTIONARY),{jan:1,"jan.":1,feb:2,"feb.":2,mar:3,"mar.":3,apr:4,"apr.":4,jun:6,"jun.":6,jul:7,"jul.":7,aug:8,"aug.":8,sep:9,"sep.":9,sept:9,"sept.":9,oct:10,"oct.":10,nov:11,"nov.":11,dec:12,"dec.":12});q.INTEGER_WORD_DICTIONARY={one:1,two:2,three:3,four:4,five:5,six:6,seven:7,eight:8,nine:9,ten:10,eleven:11,twelve:12};q.ORDINAL_WORD_DICTIONARY={first:1,second:2,third:3,fourth:4,fifth:5,sixth:6,seventh:7,eighth:8,ninth:9,tenth:10,eleventh:11,twelfth:12,thirteenth:13,fourteenth:14,fifteenth:15,sixteenth:16,seventeenth:17,eighteenth:18,nineteenth:19,twentieth:20,"twenty first":21,"twenty-first":21,"twenty second":22,"twenty-second":22,"twenty third":23,"twenty-third":23,"twenty fourth":24,"twenty-fourth":24,"twenty fifth":25,"twenty-fifth":25,"twenty sixth":26,"twenty-sixth":26,"twenty seventh":27,"twenty-seventh":27,"twenty eighth":28,"twenty-eighth":28,"twenty ninth":29,"twenty-ninth":29,thirtieth:30,"thirty first":31,"thirty-first":31};q.TIME_UNIT_DICTIONARY={sec:"second",second:"second",seconds:"second",min:"minute",mins:"minute",minute:"minute",minutes:"minute",h:"hour",hr:"hour",hrs:"hour",hour:"hour",hours:"hour",day:"d",days:"d",week:"week",weeks:"week",month:"month",months:"month",qtr:"quarter",quarter:"quarter",quarters:"quarter",y:"year",yr:"year",year:"year",years:"year"};q.NUMBER_PATTERN=`(?:${Rs.matchAnyPattern(q.INTEGER_WORD_DICTIONARY)}|[0-9]+|[0-9]+\\.[0-9]+|half(?:\\s{0,2}an?)?|an?\\b(?:\\s{0,2}few)?|few|several|a?\\s{0,2}couple\\s{0,2}(?:of)?)`;function vp(r){let e=r.toLowerCase();return q.INTEGER_WORD_DICTIONARY[e]!==void 0?q.INTEGER_WORD_DICTIONARY[e]:e==="a"||e==="an"?1:e.match(/few/)?3:e.match(/half/)?.5:e.match(/couple/)?2:e.match(/several/)?7:parseFloat(e)}q.parseNumberPattern=vp;q.ORDINAL_NUMBER_PATTERN=`(?:${Rs.matchAnyPattern(q.ORDINAL_WORD_DICTIONARY)}|[0-9]{1,2}(?:st|nd|rd|th)?)`;function DT(r){let e=r.toLowerCase();return q.ORDINAL_WORD_DICTIONARY[e]!==void 0?q.ORDINAL_WORD_DICTIONARY[e]:(e=e.replace(/(?:st|nd|rd|th)$/i,""),parseInt(e))}q.parseOrdinalNumberPattern=DT;q.YEAR_PATTERN="(?:[1-9][0-9]{0,3}\\s{0,2}(?:BE|AD|BC|BCE|CE)|[1-2][0-9]{3}|[5-9][0-9])";function PT(r){if(/BE/i.test(r))return r=r.replace(/BE/i,""),parseInt(r)-543;if(/BCE?/i.test(r))return r=r.replace(/BCE?/i,""),-parseInt(r);if(/(AD|CE)/i.test(r))return r=r.replace(/(AD|CE)/i,""),parseInt(r);let e=parseInt(r);return MT.findMostLikelyADYear(e)}q.parseYear=PT;var Ep=`(${q.NUMBER_PATTERN})\\s{0,3}(${Rs.matchAnyPattern(q.TIME_UNIT_DICTIONARY)})`,bp=new RegExp(Ep,"i");q.TIME_UNITS_PATTERN=Rs.repeatedTimeunitPattern("(?:(?:about|around)\\s{0,3})?",Ep);function OT(r){let e={},t=r,n=bp.exec(t);for(;n;)AT(e,n),t=t.substring(n[0].length).trim(),n=bp.exec(t);return e}q.parseTimeUnits=OT;function AT(r,e){let t=vp(e[1]),n=q.TIME_UNIT_DICTIONARY[e[2].toLowerCase()];r[n]=t}});var Rp=h((ho,mo)=>{(function(r,e){typeof ho=="object"&&typeof mo!="undefined"?mo.exports=e():typeof define=="function"&&define.amd?define(e):(r=typeof globalThis!="undefined"?globalThis:r||self).dayjs_plugin_quarterOfYear=e()})(ho,function(){"use strict";var r="month",e="quarter";return function(t,n){var i=n.prototype;i.quarter=function(o){return this.$utils().u(o)?Math.ceil((this.month()+1)/3):this.month(this.month()%3+3*(o-1))};var s=i.add;i.add=function(o,u){return o=Number(o),this.$utils().p(u)===e?this.add(3*o,r):s.bind(this)(o,u)};var a=i.startOf;i.startOf=function(o,u){var l=this.$utils(),c=!!l.u(u)||u;if(l.p(o)===e){var d=this.quarter()-1;return c?this.month(3*d).startOf(r).startOf("day"):this.month(3*d+2).endOf(r).endOf("day")}return a.bind(this)(o,u)}}})});var it=h(Ot=>{"use strict";Object.defineProperty(Ot,"__esModule",{value:!0});Ot.implySimilarTime=Ot.assignSimilarTime=Ot.assignSimilarDate=Ot.assignTheNextDay=void 0;var wp=Ee();function kT(r,e){e=e.add(1,"day"),Mp(r,e),Dp(r,e)}Ot.assignTheNextDay=kT;function Mp(r,e){r.assign("day",e.date()),r.assign("month",e.month()+1),r.assign("year",e.year())}Ot.assignSimilarDate=Mp;function NT(r,e){r.assign("hour",e.hour()),r.assign("minute",e.minute()),r.assign("second",e.second()),r.assign("millisecond",e.millisecond()),r.get("hour")<12?r.assign("meridiem",wp.Meridiem.AM):r.assign("meridiem",wp.Meridiem.PM)}Ot.assignSimilarTime=NT;function Dp(r,e){r.imply("hour",e.hour()),r.imply("minute",e.minute()),r.imply("second",e.second()),r.imply("millisecond",e.millisecond())}Ot.implySimilarTime=Dp});var Pp=h(Ir=>{"use strict";Object.defineProperty(Ir,"__esModule",{value:!0});Ir.toTimezoneOffset=Ir.TIMEZONE_ABBR_MAP=void 0;Ir.TIMEZONE_ABBR_MAP={ACDT:630,ACST:570,ADT:-180,AEDT:660,AEST:600,AFT:270,AKDT:-480,AKST:-540,ALMT:360,AMST:-180,AMT:-240,ANAST:720,ANAT:720,AQTT:300,ART:-180,AST:-240,AWDT:540,AWST:480,AZOST:0,AZOT:-60,AZST:300,AZT:240,BNT:480,BOT:-240,BRST:-120,BRT:-180,BST:60,BTT:360,CAST:480,CAT:120,CCT:390,CDT:-300,CEST:120,CET:60,CHADT:825,CHAST:765,CKT:-600,CLST:-180,CLT:-240,COT:-300,CST:-360,CVT:-60,CXT:420,ChST:600,DAVT:420,EASST:-300,EAST:-360,EAT:180,ECT:-300,EDT:-240,EEST:180,EET:120,EGST:0,EGT:-60,EST:-300,ET:-300,FJST:780,FJT:720,FKST:-180,FKT:-240,FNT:-120,GALT:-360,GAMT:-540,GET:240,GFT:-180,GILT:720,GMT:0,GST:240,GYT:-240,HAA:-180,HAC:-300,HADT:-540,HAE:-240,HAP:-420,HAR:-360,HAST:-600,HAT:-90,HAY:-480,HKT:480,HLV:-210,HNA:-240,HNC:-360,HNE:-300,HNP:-480,HNR:-420,HNT:-150,HNY:-540,HOVT:420,ICT:420,IDT:180,IOT:360,IRDT:270,IRKST:540,IRKT:540,IRST:210,IST:330,JST:540,KGT:360,KRAST:480,KRAT:480,KST:540,KUYT:240,LHDT:660,LHST:630,LINT:840,MAGST:720,MAGT:720,MART:-510,MAWT:300,MDT:-360,MESZ:120,MEZ:60,MHT:720,MMT:390,MSD:240,MSK:180,MST:-420,MUT:240,MVT:300,MYT:480,NCT:660,NDT:-90,NFT:690,NOVST:420,NOVT:360,NPT:345,NST:-150,NUT:-660,NZDT:780,NZST:720,OMSST:420,OMST:420,PDT:-420,PET:-300,PETST:720,PETT:720,PGT:600,PHOT:780,PHT:480,PKT:300,PMDT:-120,PMST:-180,PONT:660,PST:-480,PT:-480,PWT:540,PYST:-180,PYT:-240,RET:240,SAMT:240,SAST:120,SBT:660,SCT:240,SGT:480,SRT:-180,SST:-660,TAHT:-600,TFT:300,TJT:300,TKT:780,TLT:540,TMT:300,TVT:720,ULAT:480,UTC:0,UYST:-120,UYT:-180,UZT:300,VET:-210,VLAST:660,VLAT:660,VUT:660,WAST:120,WAT:60,WEST:60,WESZ:60,WET:0,WEZ:0,WFT:720,WGST:-120,WGT:-180,WIB:420,WIT:540,WITA:480,WST:780,WT:0,YAKST:600,YAKT:600,YAPT:600,YEKST:360,YEKT:360};function xT(r){var e;return r==null?null:typeof r=="number"?r:(e=Ir.TIMEZONE_ABBR_MAP[r])!==null&&e!==void 0?e:null}Ir.toTimezoneOffset=xT});var he=h(At=>{"use strict";var Op=At&&At.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(At,"__esModule",{value:!0});At.ParsingResult=At.ParsingComponents=At.ReferenceWithTimezone=void 0;var CT=Op(Rp()),ws=Op(K()),yo=it(),ST=Pp();ws.default.extend(CT.default);var go=class{constructor(e){var t;e=e!=null?e:new Date,e instanceof Date?this.instant=e:(this.instant=(t=e.instant)!==null&&t!==void 0?t:new Date,this.timezoneOffset=ST.toTimezoneOffset(e.timezone))}};At.ReferenceWithTimezone=go;var Ur=class{constructor(e,t){if(this.reference=e,this.knownValues={},this.impliedValues={},t)for(let i in t)this.knownValues[i]=t[i];let n=ws.default(e.instant);this.imply("day",n.date()),this.imply("month",n.month()+1),this.imply("year",n.year()),this.imply("hour",12),this.imply("minute",0),this.imply("second",0),this.imply("millisecond",0)}get(e){return e in this.knownValues?this.knownValues[e]:e in this.impliedValues?this.impliedValues[e]:null}isCertain(e){return e in this.knownValues}getCertainComponents(){return Object.keys(this.knownValues)}imply(e,t){return e in this.knownValues?this:(this.impliedValues[e]=t,this)}assign(e,t){return this.knownValues[e]=t,delete this.impliedValues[e],this}delete(e){delete this.knownValues[e],delete this.impliedValues[e]}clone(){let e=new Ur(this.reference);e.knownValues={},e.impliedValues={};for(let t in this.knownValues)e.knownValues[t]=this.knownValues[t];for(let t in this.impliedValues)e.impliedValues[t]=this.impliedValues[t];return e}isOnlyDate(){return!this.isCertain("hour")&&!this.isCertain("minute")&&!this.isCertain("second")}isOnlyTime(){return!this.isCertain("weekday")&&!this.isCertain("day")&&!this.isCertain("month")}isOnlyWeekdayComponent(){return this.isCertain("weekday")&&!this.isCertain("day")&&!this.isCertain("month")}isOnlyDayMonthComponent(){return this.isCertain("day")&&this.isCertain("month")&&!this.isCertain("year")}isValidDate(){let e=this.dateWithoutTimezoneAdjustment();return!(e.getFullYear()!==this.get("year")||e.getMonth()!==this.get("month")-1||e.getDate()!==this.get("day")||this.get("hour")!=null&&e.getHours()!=this.get("hour")||this.get("minute")!=null&&e.getMinutes()!=this.get("minute"))}toString(){return`[ParsingComponents {knownValues: ${JSON.stringify(this.knownValues)}, impliedValues: ${JSON.stringify(this.impliedValues)}}, reference: ${JSON.stringify(this.reference)}]`}dayjs(){return ws.default(this.date())}date(){let e=this.dateWithoutTimezoneAdjustment();return new Date(e.getTime()+this.getSystemTimezoneAdjustmentMinute(e)*6e4)}dateWithoutTimezoneAdjustment(){let e=new Date(this.get("year"),this.get("month")-1,this.get("day"),this.get("hour"),this.get("minute"),this.get("second"),this.get("millisecond"));return e.setFullYear(this.get("year")),e}getSystemTimezoneAdjustmentMinute(e){var t,n;(!e||e.getTime()<0)&&(e=new Date);let i=-e.getTimezoneOffset(),s=(n=(t=this.get("timezoneOffset"))!==null&&t!==void 0?t:this.reference.timezoneOffset)!==null&&n!==void 0?n:i;return i-s}static createRelativeFromReference(e,t){let n=ws.default(e.instant);for(let s in t)n=n.add(t[s],s);let i=new Ur(e);return t.hour||t.minute||t.second?(yo.assignSimilarTime(i,n),yo.assignSimilarDate(i,n),e.timezoneOffset!==null&&i.assign("timezoneOffset",-e.instant.getTimezoneOffset())):(yo.implySimilarTime(i,n),e.timezoneOffset!==null&&i.imply("timezoneOffset",-e.instant.getTimezoneOffset()),t.d?(i.assign("day",n.date()),i.assign("month",n.month()+1),i.assign("year",n.year())):(t.week&&i.imply("weekday",n.day()),i.imply("day",n.date()),t.month?(i.assign("month",n.month()+1),i.assign("year",n.year())):(i.imply("month",n.month()+1),t.year?i.assign("year",n.year()):i.imply("year",n.year())))),i}};At.ParsingComponents=Ur;var jn=class{constructor(e,t,n,i,s){this.reference=e,this.refDate=e.instant,this.index=t,this.text=n,this.start=i||new Ur(e),this.end=s}clone(){let e=new jn(this.reference,this.index,this.text);return e.start=this.start?this.start.clone():null,e.end=this.end?this.end.clone():null,e}date(){return this.start.date()}toString(){return`[ParsingResult {index: ${this.index}, text: '${this.text}', ...}]`}};At.ParsingResult=jn});var R=h(Ms=>{"use strict";Object.defineProperty(Ms,"__esModule",{value:!0});Ms.AbstractParserWithWordBoundaryChecking=void 0;var _o=class{constructor(){this.cachedInnerPattern=null,this.cachedPattern=null}patternLeftBoundary(){return"(\\W|^)"}pattern(e){let t=this.innerPattern(e);return t==this.cachedInnerPattern?this.cachedPattern:(this.cachedPattern=new RegExp(`${this.patternLeftBoundary()}${t.source}`,t.flags),this.cachedInnerPattern=t,this.cachedPattern)}extract(e,t){var n;let i=(n=t[1])!==null&&n!==void 0?n:"";t.index=t.index+i.length,t[0]=t[0].substring(i.length);for(let s=2;s{"use strict";Object.defineProperty(vo,"__esModule",{value:!0});var bo=Ie(),IT=he(),UT=R(),FT=new RegExp(`(?:within|in|for)\\s*(?:(?:about|around|roughly|approximately|just)\\s*(?:~\\s*)?)?(${bo.TIME_UNITS_PATTERN})(?=\\W|$)`,"i"),qT=new RegExp(`(?:(?:about|around|roughly|approximately|just)\\s*(?:~\\s*)?)?(${bo.TIME_UNITS_PATTERN})(?=\\W|$)`,"i"),To=class extends UT.AbstractParserWithWordBoundaryChecking{innerPattern(e){return e.option.forwardDate?qT:FT}innerExtract(e,t){let n=bo.parseTimeUnits(t[1]);return IT.ParsingComponents.createRelativeFromReference(e.reference,n)}};vo.default=To});var Ip=h(Ro=>{"use strict";Object.defineProperty(Ro,"__esModule",{value:!0});var WT=Se(),Cp=Ie(),Sp=Ie(),Ds=Ie(),LT=J(),YT=R(),$T=new RegExp(`(?:on\\s{0,3})?(${Ds.ORDINAL_NUMBER_PATTERN})(?:\\s{0,3}(?:to|\\-|\\\u2013|until|through|till)?\\s{0,3}(${Ds.ORDINAL_NUMBER_PATTERN}))?(?:-|/|\\s{0,3}(?:of)?\\s{0,3})(${LT.matchAnyPattern(Cp.MONTH_DICTIONARY)})(?:(?:-|/|,?\\s{0,3})(${Sp.YEAR_PATTERN}(?![^\\s]\\d)))?(?=\\W|$)`,"i"),kp=1,Np=2,jT=3,xp=4,Eo=class extends YT.AbstractParserWithWordBoundaryChecking{innerPattern(){return $T}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=Cp.MONTH_DICTIONARY[t[jT].toLowerCase()],s=Ds.parseOrdinalNumberPattern(t[kp]);if(s>31)return t.index=t.index+t[kp].length,null;if(n.start.assign("month",i),n.start.assign("day",s),t[xp]){let a=Sp.parseYear(t[xp]);n.start.assign("year",a)}else{let a=WT.findYearClosestToRef(e.refDate,s,i);n.start.imply("year",a)}if(t[Np]){let a=Ds.parseOrdinalNumberPattern(t[Np]);n.end=n.start.clone(),n.end.assign("day",a)}return n}};Ro.default=Eo});var Lp=h(Mo=>{"use strict";Object.defineProperty(Mo,"__esModule",{value:!0});var BT=Se(),qp=Ie(),Ps=Ie(),Wp=Ie(),GT=J(),HT=R(),zT=new RegExp(`(${GT.matchAnyPattern(qp.MONTH_DICTIONARY)})(?:-|/|\\s*,?\\s*)(${Ps.ORDINAL_NUMBER_PATTERN})(?!\\s*(?:am|pm))\\s*(?:(?:to|\\-)\\s*(${Ps.ORDINAL_NUMBER_PATTERN})\\s*)?(?:(?:-|/|\\s*,?\\s*)(${Wp.YEAR_PATTERN}))?(?=\\W|$)(?!\\:\\d)`,"i"),KT=1,VT=2,Up=3,Fp=4,wo=class extends HT.AbstractParserWithWordBoundaryChecking{innerPattern(){return zT}innerExtract(e,t){let n=qp.MONTH_DICTIONARY[t[KT].toLowerCase()],i=Ps.parseOrdinalNumberPattern(t[VT]);if(i>31)return null;let s=e.createParsingComponents({day:i,month:n});if(t[Fp]){let u=Wp.parseYear(t[Fp]);s.assign("year",u)}else{let u=BT.findYearClosestToRef(e.refDate,i,n);s.imply("year",u)}if(!t[Up])return s;let a=Ps.parseOrdinalNumberPattern(t[Up]),o=e.createParsingResult(t.index,t[0]);return o.start=s,o.end=s.clone(),o.end.assign("day",a),o}};Mo.default=wo});var jp=h(Oo=>{"use strict";Object.defineProperty(Oo,"__esModule",{value:!0});var Do=Ie(),ZT=Se(),XT=J(),$p=Ie(),QT=R(),JT=new RegExp(`((?:in)\\s*)?(${XT.matchAnyPattern(Do.MONTH_DICTIONARY)})\\s*(?:[,-]?\\s*(${$p.YEAR_PATTERN})?)?(?=[^\\s\\w]|\\s+[^0-9]|\\s+$|$)`,"i"),eb=1,tb=2,Yp=3,Po=class extends QT.AbstractParserWithWordBoundaryChecking{innerPattern(){return JT}innerExtract(e,t){let n=t[tb].toLowerCase();if(t[0].length<=3&&!Do.FULL_MONTH_NAME_DICTIONARY[n])return null;let i=e.createParsingResult(t.index+(t[eb]||"").length,t.index+t[0].length);i.start.imply("day",1);let s=Do.MONTH_DICTIONARY[n];if(i.start.assign("month",s),t[Yp]){let a=$p.parseYear(t[Yp]);i.start.assign("year",a)}else{let a=ZT.findYearClosestToRef(e.refDate,1,s);i.start.imply("year",a)}return i}};Oo.default=Po});var Hp=h(ko=>{"use strict";Object.defineProperty(ko,"__esModule",{value:!0});var Gp=Ie(),rb=J(),nb=R(),ib=new RegExp(`([0-9]{4})[\\.\\/\\s](?:(${rb.matchAnyPattern(Gp.MONTH_DICTIONARY)})|([0-9]{1,2}))[\\.\\/\\s]([0-9]{1,2})(?=\\W|$)`,"i"),sb=1,ab=2,Bp=3,ob=4,Ao=class extends nb.AbstractParserWithWordBoundaryChecking{innerPattern(){return ib}innerExtract(e,t){let n=t[Bp]?parseInt(t[Bp]):Gp.MONTH_DICTIONARY[t[ab].toLowerCase()];if(n<1||n>12)return null;let i=parseInt(t[sb]);return{day:parseInt(t[ob]),month:n,year:i}}};ko.default=Ao});var zp=h(xo=>{"use strict";Object.defineProperty(xo,"__esModule",{value:!0});var ub=R(),lb=new RegExp("([0-9]|0[1-9]|1[012])/([0-9]{4})","i"),cb=1,db=2,No=class extends ub.AbstractParserWithWordBoundaryChecking{innerPattern(){return lb}innerExtract(e,t){let n=parseInt(t[db]),i=parseInt(t[cb]);return e.createParsingComponents().imply("day",1).assign("month",i).assign("year",n)}};xo.default=No});var Fr=h(ks=>{"use strict";Object.defineProperty(ks,"__esModule",{value:!0});ks.AbstractTimeExpressionParser=void 0;var Be=Ee();function fb(r,e,t,n){return new RegExp(`${r}${e}(\\d{1,4})(?:(?:\\.|:|\uFF1A)(\\d{1,2})(?:(?::|\uFF1A)(\\d{2})(?:\\.(\\d{1,6}))?)?)?(?:\\s*(a\\.m\\.|p\\.m\\.|am?|pm?))?${t}`,n)}function pb(r,e){return new RegExp(`^(${r})(\\d{1,4})(?:(?:\\.|\\:|\\\uFF1A)(\\d{1,2})(?:(?:\\.|\\:|\\\uFF1A)(\\d{1,2})(?:\\.(\\d{1,6}))?)?)?(?:\\s*(a\\.m\\.|p\\.m\\.|am?|pm?))?${e}`,"i")}var Kp=2,nn=3,Os=4,As=5,Bn=6,Co=class{constructor(e=!1){this.cachedPrimaryPrefix=null,this.cachedPrimarySuffix=null,this.cachedPrimaryTimePattern=null,this.cachedFollowingPhase=null,this.cachedFollowingSuffix=null,this.cachedFollowingTimePatten=null,this.strictMode=e}patternFlags(){return"i"}primaryPatternLeftBoundary(){return"(^|\\s|T|\\b)"}primarySuffix(){return"(?=\\W|$)"}followingSuffix(){return"(?=\\W|$)"}pattern(e){return this.getPrimaryTimePatternThroughCache()}extract(e,t){let n=this.extractPrimaryTimeComponents(e,t);if(!n)return t.index+=t[0].length,null;let i=t.index+t[1].length,s=t[0].substring(t[1].length),a=e.createParsingResult(i,s,n);t.index+=t[0].length;let o=e.text.substring(t.index),l=this.getFollowingTimePatternThroughCache().exec(o);return s.match(/^\d{3,4}/)&&l&&l[0].match(/^\s*([+-])\s*\d{2,4}$/)?null:!l||l[0].match(/^\s*([+-])\s*\d{3,4}$/)?this.checkAndReturnWithoutFollowingPattern(a):(a.end=this.extractFollowingTimeComponents(e,l,a),a.end&&(a.text+=l[0]),this.checkAndReturnWithFollowingPattern(a))}extractPrimaryTimeComponents(e,t,n=!1){let i=e.createParsingComponents(),s=0,a=null,o=parseInt(t[Kp]);if(o>100){if(this.strictMode||t[nn]!=null)return null;s=o%100,o=Math.floor(o/100)}if(o>24)return null;if(t[nn]!=null){if(t[nn].length==1&&!t[Bn])return null;s=parseInt(t[nn])}if(s>=60)return null;if(o>12&&(a=Be.Meridiem.PM),t[Bn]!=null){if(o>12)return null;let u=t[Bn][0].toLowerCase();u=="a"&&(a=Be.Meridiem.AM,o==12&&(o=0)),u=="p"&&(a=Be.Meridiem.PM,o!=12&&(o+=12))}if(i.assign("hour",o),i.assign("minute",s),a!==null?i.assign("meridiem",a):o<12?i.imply("meridiem",Be.Meridiem.AM):i.imply("meridiem",Be.Meridiem.PM),t[As]!=null){let u=parseInt(t[As].substring(0,3));if(u>=1e3)return null;i.assign("millisecond",u)}if(t[Os]!=null){let u=parseInt(t[Os]);if(u>=60)return null;i.assign("second",u)}return i}extractFollowingTimeComponents(e,t,n){let i=e.createParsingComponents();if(t[As]!=null){let u=parseInt(t[As].substring(0,3));if(u>=1e3)return null;i.assign("millisecond",u)}if(t[Os]!=null){let u=parseInt(t[Os]);if(u>=60)return null;i.assign("second",u)}let s=parseInt(t[Kp]),a=0,o=-1;if(t[nn]!=null?a=parseInt(t[nn]):s>100&&(a=s%100,s=Math.floor(s/100)),a>=60||s>24)return null;if(s>=12&&(o=Be.Meridiem.PM),t[Bn]!=null){if(s>12)return null;let u=t[Bn][0].toLowerCase();u=="a"&&(o=Be.Meridiem.AM,s==12&&(s=0,i.isCertain("day")||i.imply("day",i.get("day")+1))),u=="p"&&(o=Be.Meridiem.PM,s!=12&&(s+=12)),n.start.isCertain("meridiem")||(o==Be.Meridiem.AM?(n.start.imply("meridiem",Be.Meridiem.AM),n.start.get("hour")==12&&n.start.assign("hour",0)):(n.start.imply("meridiem",Be.Meridiem.PM),n.start.get("hour")!=12&&n.start.assign("hour",n.start.get("hour")+12)))}return i.assign("hour",s),i.assign("minute",a),o>=0?i.assign("meridiem",o):n.start.isCertain("meridiem")&&n.start.get("hour")>12?n.start.get("hour")-12>s?i.imply("meridiem",Be.Meridiem.AM):s<=12&&(i.assign("hour",s+12),i.assign("meridiem",Be.Meridiem.PM)):s>12?i.imply("meridiem",Be.Meridiem.PM):s<=12&&i.imply("meridiem",Be.Meridiem.AM),i.date().getTime()24)return null}return e}checkAndReturnWithFollowingPattern(e){if(e.text.match(/^\d+-\d+$/))return null;let t=e.text.match(/[^\d:.](\d[\d.]+)\s*-\s*(\d[\d.]+)$/);if(t){if(this.strictMode)return null;let n=t[1],i=t[2];if(i.includes(".")&&!i.match(/\d(\.\d{2})+$/))return null;let s=parseInt(i),a=parseInt(n);if(s>24||a>24)return null}return e}getPrimaryTimePatternThroughCache(){let e=this.primaryPrefix(),t=this.primarySuffix();return this.cachedPrimaryPrefix===e&&this.cachedPrimarySuffix===t?this.cachedPrimaryTimePattern:(this.cachedPrimaryTimePattern=fb(this.primaryPatternLeftBoundary(),e,t,this.patternFlags()),this.cachedPrimaryPrefix=e,this.cachedPrimarySuffix=t,this.cachedPrimaryTimePattern)}getFollowingTimePatternThroughCache(){let e=this.followingPhase(),t=this.followingSuffix();return this.cachedFollowingPhase===e&&this.cachedFollowingSuffix===t?this.cachedFollowingTimePatten:(this.cachedFollowingTimePatten=pb(e,t),this.cachedFollowingPhase=e,this.cachedFollowingSuffix=t,this.cachedFollowingTimePatten)}};ks.AbstractTimeExpressionParser=Co});var Vp=h(Io=>{"use strict";Object.defineProperty(Io,"__esModule",{value:!0});var Ns=Ee(),hb=Fr(),So=class extends hb.AbstractTimeExpressionParser{constructor(e){super(e)}followingPhase(){return"\\s*(?:\\-|\\\u2013|\\~|\\\u301C|to|\\?)\\s*"}primaryPrefix(){return"(?:(?:at|from)\\s*)??"}primarySuffix(){return"(?:\\s*(?:o\\W*clock|at\\s*night|in\\s*the\\s*(?:morning|afternoon)))?(?!/)(?=\\W|$)"}extractPrimaryTimeComponents(e,t){let n=super.extractPrimaryTimeComponents(e,t);if(n){if(t[0].endsWith("night")){let i=n.get("hour");i>=6&&i<12?(n.assign("hour",n.get("hour")+12),n.assign("meridiem",Ns.Meridiem.PM)):i<6&&n.assign("meridiem",Ns.Meridiem.AM)}if(t[0].endsWith("afternoon")){n.assign("meridiem",Ns.Meridiem.PM);let i=n.get("hour");i>=0&&i<=6&&n.assign("hour",n.get("hour")+12)}t[0].endsWith("morning")&&(n.assign("meridiem",Ns.Meridiem.AM),n.get("hour")<12&&n.assign("hour",n.get("hour")))}return n}};Io.default=So});var st=h(sn=>{"use strict";Object.defineProperty(sn,"__esModule",{value:!0});sn.addImpliedTimeUnits=sn.reverseTimeUnits=void 0;function mb(r){let e={};for(let t in r)e[t]=-r[t];return e}sn.reverseTimeUnits=mb;function yb(r,e){let t=r.clone(),n=r.dayjs();for(let i in e)n=n.add(e[i],i);return("day"in e||"d"in e||"week"in e||"month"in e||"year"in e)&&(t.imply("day",n.date()),t.imply("month",n.month()+1),t.imply("year",n.year())),("second"in e||"minute"in e||"hour"in e)&&(t.imply("second",n.second()),t.imply("minute",n.minute()),t.imply("hour",n.hour())),t}sn.addImpliedTimeUnits=yb});var Zp=h(qo=>{"use strict";Object.defineProperty(qo,"__esModule",{value:!0});var Fo=Ie(),gb=he(),_b=R(),Tb=st(),bb=new RegExp(`(${Fo.TIME_UNITS_PATTERN})\\s{0,5}(?:ago|before|earlier)(?=(?:\\W|$))`,"i"),vb=new RegExp(`(${Fo.TIME_UNITS_PATTERN})\\s{0,5}ago(?=(?:\\W|$))`,"i"),Uo=class extends _b.AbstractParserWithWordBoundaryChecking{constructor(e){super(),this.strictMode=e}innerPattern(){return this.strictMode?vb:bb}innerExtract(e,t){let n=Fo.parseTimeUnits(t[1]),i=Tb.reverseTimeUnits(n);return gb.ParsingComponents.createRelativeFromReference(e.reference,i)}};qo.default=Uo});var Xp=h(Yo=>{"use strict";Object.defineProperty(Yo,"__esModule",{value:!0});var Lo=Ie(),Eb=he(),Rb=R(),wb=new RegExp(`(${Lo.TIME_UNITS_PATTERN})\\s{0,5}(?:later|after|from now|henceforth|forward|out)(?=(?:\\W|$))`,"i"),Mb=new RegExp("("+Lo.TIME_UNITS_PATTERN+")(later|from now)(?=(?:\\W|$))","i"),Db=1,Wo=class extends Rb.AbstractParserWithWordBoundaryChecking{constructor(e){super(),this.strictMode=e}innerPattern(){return this.strictMode?Mb:wb}innerExtract(e,t){let n=Lo.parseTimeUnits(t[Db]);return Eb.ParsingComponents.createRelativeFromReference(e.reference,n)}};Yo.default=Wo});var on=h(an=>{"use strict";Object.defineProperty(an,"__esModule",{value:!0});an.MergingRefiner=an.Filter=void 0;var $o=class{refine(e,t){return t.filter(n=>this.isValid(e,n))}};an.Filter=$o;var jo=class{refine(e,t){if(t.length<2)return t;let n=[],i=t[0],s=null;for(let a=1;a{console.log(`${this.constructor.name} merged ${u} and ${l} into ${c}`)}),i=c}}return i!=null&&n.push(i),n}};an.MergingRefiner=jo});var kt=h(Go=>{"use strict";Object.defineProperty(Go,"__esModule",{value:!0});var Pb=on(),Bo=class extends Pb.MergingRefiner{shouldMergeResults(e,t,n){return!t.end&&!n.end&&e.match(this.patternBetween())!=null}mergeResults(e,t,n){if(!t.start.isOnlyWeekdayComponent()&&!n.start.isOnlyWeekdayComponent()&&(n.start.getCertainComponents().forEach(s=>{t.start.isCertain(s)||t.start.assign(s,n.start.get(s))}),t.start.getCertainComponents().forEach(s=>{n.start.isCertain(s)||n.start.assign(s,t.start.get(s))})),t.start.date().getTime()>n.start.date().getTime()){let s=t.start.dayjs(),a=n.start.dayjs();t.start.isOnlyWeekdayComponent()&&s.add(-7,"days").isBefore(a)?(s=s.add(-7,"days"),t.start.imply("day",s.date()),t.start.imply("month",s.month()+1),t.start.imply("year",s.year())):n.start.isOnlyWeekdayComponent()&&a.add(7,"days").isAfter(s)?(a=a.add(7,"days"),n.start.imply("day",a.date()),n.start.imply("month",a.month()+1),n.start.imply("year",a.year())):[n,t]=[t,n]}let i=t.clone();return i.start=t.start,i.end=n.start,i.index=Math.min(t.index,n.index),t.index{"use strict";var Ob=Gn&&Gn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Gn,"__esModule",{value:!0});var Ab=Ob(kt()),Ho=class extends Ab.default{patternBetween(){return/^\s*(to|-)\s*$/i}};Gn.default=Ho});var Jp=h(un=>{"use strict";Object.defineProperty(un,"__esModule",{value:!0});un.mergeDateTimeComponent=un.mergeDateTimeResult=void 0;var kb=Ee();function Nb(r,e){let t=r.clone(),n=r.start,i=e.start;if(t.start=zo(n,i),r.end!=null||e.end!=null){let s=r.end==null?r.start:r.end,a=e.end==null?e.start:e.end,o=zo(s,a);r.end==null&&o.date().getTime(){"use strict";Object.defineProperty(Vo,"__esModule",{value:!0});var xb=on(),eh=Jp(),Ko=class extends xb.MergingRefiner{shouldMergeResults(e,t,n){return(t.start.isOnlyDate()&&n.start.isOnlyTime()||n.start.isOnlyDate()&&t.start.isOnlyTime())&&e.match(this.patternBetween())!=null}mergeResults(e,t,n){let i=t.start.isOnlyDate()?eh.mergeDateTimeResult(t,n):eh.mergeDateTimeResult(n,t);return i.index=t.index,i.text=t.text+e+n.text,i}};Vo.default=Ko});var th=h(Hn=>{"use strict";var Cb=Hn&&Hn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Hn,"__esModule",{value:!0});var Sb=Cb(Bt()),Zo=class extends Sb.default{patternBetween(){return new RegExp("^\\s*(T|at|after|before|on|of|,|-)?\\s*$")}};Hn.default=Zo});var rh=h(Qo=>{"use strict";Object.defineProperty(Qo,"__esModule",{value:!0});var Ib=new RegExp("^\\s*,?\\s*\\(?([A-Z]{2,4})\\)?(?=\\W|$)","i"),Ub={ACDT:630,ACST:570,ADT:-180,AEDT:660,AEST:600,AFT:270,AKDT:-480,AKST:-540,ALMT:360,AMST:-180,AMT:-240,ANAST:720,ANAT:720,AQTT:300,ART:-180,AST:-240,AWDT:540,AWST:480,AZOST:0,AZOT:-60,AZST:300,AZT:240,BNT:480,BOT:-240,BRST:-120,BRT:-180,BST:60,BTT:360,CAST:480,CAT:120,CCT:390,CDT:-300,CEST:120,CET:60,CHADT:825,CHAST:765,CKT:-600,CLST:-180,CLT:-240,COT:-300,CST:-360,CVT:-60,CXT:420,ChST:600,DAVT:420,EASST:-300,EAST:-360,EAT:180,ECT:-300,EDT:-240,EEST:180,EET:120,EGST:0,EGT:-60,EST:-300,ET:-300,FJST:780,FJT:720,FKST:-180,FKT:-240,FNT:-120,GALT:-360,GAMT:-540,GET:240,GFT:-180,GILT:720,GMT:0,GST:240,GYT:-240,HAA:-180,HAC:-300,HADT:-540,HAE:-240,HAP:-420,HAR:-360,HAST:-600,HAT:-90,HAY:-480,HKT:480,HLV:-210,HNA:-240,HNC:-360,HNE:-300,HNP:-480,HNR:-420,HNT:-150,HNY:-540,HOVT:420,ICT:420,IDT:180,IOT:360,IRDT:270,IRKST:540,IRKT:540,IRST:210,IST:330,JST:540,KGT:360,KRAST:480,KRAT:480,KST:540,KUYT:240,LHDT:660,LHST:630,LINT:840,MAGST:720,MAGT:720,MART:-510,MAWT:300,MDT:-360,MESZ:120,MEZ:60,MHT:720,MMT:390,MSD:240,MSK:240,MST:-420,MUT:240,MVT:300,MYT:480,NCT:660,NDT:-90,NFT:690,NOVST:420,NOVT:360,NPT:345,NST:-150,NUT:-660,NZDT:780,NZST:720,OMSST:420,OMST:420,PDT:-420,PET:-300,PETST:720,PETT:720,PGT:600,PHOT:780,PHT:480,PKT:300,PMDT:-120,PMST:-180,PONT:660,PST:-480,PT:-480,PWT:540,PYST:-180,PYT:-240,RET:240,SAMT:240,SAST:120,SBT:660,SCT:240,SGT:480,SRT:-180,SST:-660,TAHT:-600,TFT:300,TJT:300,TKT:780,TLT:540,TMT:300,TVT:720,ULAT:480,UTC:0,UYST:-120,UYT:-180,UZT:300,VET:-210,VLAST:660,VLAT:660,VUT:660,WAST:120,WAT:60,WEST:60,WESZ:60,WET:0,WEZ:0,WFT:720,WGST:-120,WGT:-180,WIB:420,WIT:540,WITA:480,WST:780,WT:0,YAKST:600,YAKT:600,YAPT:600,YEKST:360,YEKT:360},Xo=class{constructor(e){this.timezone=Object.assign(Object.assign({},Ub),e)}refine(e,t){var n;let i=(n=e.option.timezones)!==null&&n!==void 0?n:{};return t.forEach(s=>{var a,o;let u=e.text.substring(s.index+s.text.length),l=Ib.exec(u);if(!l)return;let c=l[1].toUpperCase(),d=(o=(a=i[c])!==null&&a!==void 0?a:this.timezone[c])!==null&&o!==void 0?o:null;if(d===null)return;e.debug(()=>{console.log(`Extracting timezone: '${c}' into: ${d} for: ${s.start}`)});let f=s.start.get("timezoneOffset");f!==null&&d!=f&&(s.start.isCertain("timezoneOffset")||c!=l[1])||s.start.isOnlyDate()&&c!=l[1]||(s.text+=l[0],s.start.isCertain("timezoneOffset")||s.start.assign("timezoneOffset",d),s.end!=null&&!s.end.isCertain("timezoneOffset")&&s.end.assign("timezoneOffset",d))}),t}};Qo.default=Xo});var xs=h(eu=>{"use strict";Object.defineProperty(eu,"__esModule",{value:!0});var Fb=new RegExp("^\\s*(?:\\(?(?:GMT|UTC)\\s?)?([+-])(\\d{1,2})(?::?(\\d{2}))?\\)?","i"),qb=1,Wb=2,Lb=3,Jo=class{refine(e,t){return t.forEach(function(n){if(n.start.isCertain("timezoneOffset"))return;let i=e.text.substring(n.index+n.text.length),s=Fb.exec(i);if(!s)return;e.debug(()=>{console.log(`Extracting timezone: '${s[0]}' into : ${n}`)});let a=parseInt(s[Wb]),o=parseInt(s[Lb]||"0"),u=a*60+o;u>14*60||(s[qb]==="-"&&(u=-u),n.end!=null&&n.end.assign("timezoneOffset",u),n.start.assign("timezoneOffset",u),n.text+=s[0])}),t}};eu.default=Jo});var nh=h(ru=>{"use strict";Object.defineProperty(ru,"__esModule",{value:!0});var tu=class{refine(e,t){if(t.length<2)return t;let n=[],i=t[0];for(let s=1;si.text.length&&(i=a):(n.push(i),i=a)}return i!=null&&n.push(i),n}};ru.default=tu});var ih=h(zn=>{"use strict";var Yb=zn&&zn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(zn,"__esModule",{value:!0});var $b=Yb(K()),nu=class{refine(e,t){return e.option.forwardDate&&t.forEach(function(n){let i=$b.default(e.refDate);if(n.start.isOnlyDayMonthComponent()&&i.isAfter(n.start.dayjs()))for(let s=0;s<3&&i.isAfter(n.start.dayjs());s++)n.start.imply("year",n.start.get("year")+1),e.debug(()=>{console.log(`Forward yearly adjusted for ${n} (${n.start})`)}),n.end&&!n.end.isCertain("year")&&(n.end.imply("year",n.end.get("year")+1),e.debug(()=>{console.log(`Forward yearly adjusted for ${n} (${n.end})`)}));n.start.isOnlyWeekdayComponent()&&i.isAfter(n.start.dayjs())&&(i.day()>=n.start.get("weekday")?i=i.day(n.start.get("weekday")+7):i=i.day(n.start.get("weekday")),n.start.imply("day",i.date()),n.start.imply("month",i.month()+1),n.start.imply("year",i.year()),e.debug(()=>{console.log(`Forward weekly adjusted for ${n} (${n.start})`)}),n.end&&n.end.isOnlyWeekdayComponent()&&(i.day()>n.end.get("weekday")?i=i.day(n.end.get("weekday")+7):i=i.day(n.end.get("weekday")),n.end.imply("day",i.date()),n.end.imply("month",i.month()+1),n.end.imply("year",i.year()),e.debug(()=>{console.log(`Forward weekly adjusted for ${n} (${n.end})`)})))}),t}};zn.default=nu});var sh=h(su=>{"use strict";Object.defineProperty(su,"__esModule",{value:!0});var jb=on(),iu=class extends jb.Filter{constructor(e){super(),this.strictMode=e}isValid(e,t){return t.text.replace(" ","").match(/^\d*(\.\d*)?$/)?(e.debug(()=>{console.log(`Removing unlikely result '${t.text}'`)}),!1):t.start.isValidDate()?t.end&&!t.end.isValidDate()?(e.debug(()=>{console.log(`Removing invalid result: ${t} (${t.end})`)}),!1):this.strictMode?this.isStrictModeValid(e,t):!0:(e.debug(()=>{console.log(`Removing invalid result: ${t} (${t.start})`)}),!1)}isStrictModeValid(e,t){return t.start.isOnlyWeekdayComponent()?(e.debug(()=>{console.log(`(Strict) Removing weekday only component: ${t} (${t.end})`)}),!1):t.start.isOnlyTime()&&(!t.start.isCertain("hour")||!t.start.isCertain("minute"))?(e.debug(()=>{console.log(`(Strict) Removing uncertain time component: ${t} (${t.end})`)}),!1):!0}};su.default=iu});var uu=h(ou=>{"use strict";Object.defineProperty(ou,"__esModule",{value:!0});var Bb=R(),Gb=new RegExp("([0-9]{4})\\-([0-9]{1,2})\\-([0-9]{1,2})(?:T([0-9]{1,2}):([0-9]{1,2})(?::([0-9]{1,2})(?:\\.(\\d{1,4}))?)?(?:Z|([+-]\\d{2}):?(\\d{2})?)?)?(?=\\W|$)","i"),Hb=1,zb=2,Kb=3,ah=4,Vb=5,oh=6,uh=7,lh=8,ch=9,au=class extends Bb.AbstractParserWithWordBoundaryChecking{innerPattern(){return Gb}innerExtract(e,t){let n={};if(n.year=parseInt(t[Hb]),n.month=parseInt(t[zb]),n.day=parseInt(t[Kb]),t[ah]!=null)if(n.hour=parseInt(t[ah]),n.minute=parseInt(t[Vb]),t[oh]!=null&&(n.second=parseInt(t[oh])),t[uh]!=null&&(n.millisecond=parseInt(t[uh])),t[lh]==null)n.timezoneOffset=0;else{let i=parseInt(t[lh]),s=0;t[ch]!=null&&(s=parseInt(t[ch]));let a=i*60;a<0?a-=s:a+=s,n.timezoneOffset=a}return n}};ou.default=au});var dh=h(cu=>{"use strict";Object.defineProperty(cu,"__esModule",{value:!0});var Zb=on(),lu=class extends Zb.MergingRefiner{mergeResults(e,t,n){let i=n.clone();return i.index=t.index,i.text=t.text+e+i.text,i.start.assign("weekday",t.start.get("weekday")),i.end&&i.end.assign("weekday",t.start.get("weekday")),i}shouldMergeResults(e,t,n){return t.start.isOnlyWeekdayComponent()&&!t.start.isCertain("hour")&&n.start.isCertain("day")&&e.match(/^,?\s*$/)!=null}};cu.default=lu});var Gt=h(ln=>{"use strict";var qr=ln&&ln.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ln,"__esModule",{value:!0});ln.includeCommonConfiguration=void 0;var Xb=qr(rh()),Qb=qr(xs()),fh=qr(nh()),Jb=qr(ih()),ev=qr(sh()),tv=qr(uu()),rv=qr(dh());function nv(r,e=!1){return r.parsers.unshift(new tv.default),r.refiners.unshift(new rv.default),r.refiners.unshift(new Xb.default),r.refiners.unshift(new Qb.default),r.refiners.unshift(new fh.default),r.refiners.push(new fh.default),r.refiners.push(new Jb.default),r.refiners.push(new ev.default(e)),r}ln.includeCommonConfiguration=nv});var zt=h(Q=>{"use strict";var iv=Q&&Q.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Q,"__esModule",{value:!0});Q.noon=Q.morning=Q.midnight=Q.yesterdayEvening=Q.evening=Q.lastNight=Q.tonight=Q.theDayAfter=Q.tomorrow=Q.theDayBefore=Q.yesterday=Q.today=Q.now=void 0;var Nt=he(),cn=iv(K()),Ht=it(),Kn=Ee();function sv(r){let e=cn.default(r.instant),t=new Nt.ParsingComponents(r,{});return Ht.assignSimilarDate(t,e),Ht.assignSimilarTime(t,e),r.timezoneOffset!==null&&t.assign("timezoneOffset",e.utcOffset()),t}Q.now=sv;function av(r){let e=cn.default(r.instant),t=new Nt.ParsingComponents(r,{});return Ht.assignSimilarDate(t,e),Ht.implySimilarTime(t,e),t}Q.today=av;function ov(r){return ph(r,1)}Q.yesterday=ov;function ph(r,e){return du(r,-e)}Q.theDayBefore=ph;function uv(r){return du(r,1)}Q.tomorrow=uv;function du(r,e){let t=cn.default(r.instant),n=new Nt.ParsingComponents(r,{});return t=t.add(e,"day"),Ht.assignSimilarDate(n,t),Ht.implySimilarTime(n,t),n}Q.theDayAfter=du;function lv(r,e=22){let t=cn.default(r.instant),n=new Nt.ParsingComponents(r,{});return n.imply("hour",e),n.imply("meridiem",Kn.Meridiem.PM),Ht.assignSimilarDate(n,t),n}Q.tonight=lv;function cv(r,e=0){let t=cn.default(r.instant),n=new Nt.ParsingComponents(r,{});return t.hour()<6&&(t=t.add(-1,"day")),Ht.assignSimilarDate(n,t),n.imply("hour",e),n}Q.lastNight=cv;function dv(r,e=20){let t=new Nt.ParsingComponents(r,{});return t.imply("meridiem",Kn.Meridiem.PM),t.imply("hour",e),t}Q.evening=dv;function fv(r,e=20){let t=cn.default(r.instant),n=new Nt.ParsingComponents(r,{});return t=t.add(-1,"day"),Ht.assignSimilarDate(n,t),n.imply("hour",e),n.imply("meridiem",Kn.Meridiem.PM),n}Q.yesterdayEvening=fv;function pv(r){let e=new Nt.ParsingComponents(r,{});return e.imply("hour",0),e.imply("minute",0),e.imply("second",0),e}Q.midnight=pv;function hv(r,e=6){let t=new Nt.ParsingComponents(r,{});return t.imply("meridiem",Kn.Meridiem.AM),t.imply("hour",e),t}Q.morning=hv;function mv(r){let e=new Nt.ParsingComponents(r,{});return e.imply("meridiem",Kn.Meridiem.AM),e.imply("hour",12),e}Q.noon=mv});var hh=h(mt=>{"use strict";var yv=mt&&mt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),gv=mt&&mt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),_v=mt&&mt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&yv(e,r,t);return gv(e,r),e},Tv=mt&&mt.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(mt,"__esModule",{value:!0});var bv=Tv(K()),vv=R(),Ev=it(),Vn=_v(zt()),Rv=/(now|today|tonight|tomorrow|tmr|tmrw|yesterday|last\s*night)(?=\W|$)/i,fu=class extends vv.AbstractParserWithWordBoundaryChecking{innerPattern(e){return Rv}innerExtract(e,t){let n=bv.default(e.refDate),i=t[0].toLowerCase(),s=e.createParsingComponents();switch(i){case"now":return Vn.now(e.reference);case"today":return Vn.today(e.reference);case"yesterday":return Vn.yesterday(e.reference);case"tomorrow":case"tmr":case"tmrw":return Vn.tomorrow(e.reference);case"tonight":return Vn.tonight(e.reference);default:i.match(/last\s*night/)&&(n.hour()>6&&(n=n.add(-1,"day")),Ev.assignSimilarDate(s,n),s.imply("hour",0));break}return s}};mt.default=fu});var mh=h(Zn=>{"use strict";var wv=Zn&&Zn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Zn,"__esModule",{value:!0});var Cs=Ee(),Mv=R(),Dv=wv(K()),Pv=it(),Ov=/(?:this)?\s{0,3}(morning|afternoon|evening|night|midnight|noon)(?=\W|$)/i,pu=class extends Mv.AbstractParserWithWordBoundaryChecking{innerPattern(){return Ov}innerExtract(e,t){let n=Dv.default(e.refDate),i=e.createParsingComponents();switch(t[1].toLowerCase()){case"afternoon":i.imply("meridiem",Cs.Meridiem.PM),i.imply("hour",15);break;case"evening":case"night":i.imply("meridiem",Cs.Meridiem.PM),i.imply("hour",20);break;case"midnight":Pv.assignTheNextDay(i,n),i.imply("hour",0),i.imply("minute",0),i.imply("second",0);break;case"morning":i.imply("meridiem",Cs.Meridiem.AM),i.imply("hour",6);break;case"noon":i.imply("meridiem",Cs.Meridiem.AM),i.imply("hour",12);break}return i}};Zn.default=pu});var Wr=h(_r=>{"use strict";var Av=_r&&_r.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(_r,"__esModule",{value:!0});_r.toDayJSClosestWeekday=_r.toDayJSWeekday=void 0;var yh=Av(K());function kv(r,e,t){if(!t)return gh(r,e);let n=yh.default(r);switch(t){case"this":n=n.day(e);break;case"next":n=n.day(e+7);break;case"last":n=n.day(e-7);break}return n}_r.toDayJSWeekday=kv;function gh(r,e){let t=yh.default(r),n=t.day();return Math.abs(e-7-n){"use strict";Object.defineProperty(mu,"__esModule",{value:!0});var _h=Ie(),Nv=J(),xv=R(),Cv=Wr(),Sv=new RegExp(`(?:(?:\\,|\\(|\\\uFF08)\\s*)?(?:on\\s*?)?(?:(this|last|past|next)\\s*)?(${Nv.matchAnyPattern(_h.WEEKDAY_DICTIONARY)})(?:\\s*(?:\\,|\\)|\\\uFF09))?(?:\\s*(this|last|past|next)\\s*week)?(?=\\W|$)`,"i"),Iv=1,Uv=2,Fv=3,hu=class extends xv.AbstractParserWithWordBoundaryChecking{innerPattern(){return Sv}innerExtract(e,t){let n=t[Uv].toLowerCase(),i=_h.WEEKDAY_DICTIONARY[n],s=t[Iv],a=t[Fv],o=s||a;o=o||"",o=o.toLowerCase();let u=null;o=="last"||o=="past"?u="last":o=="next"?u="next":o=="this"&&(u="this");let l=Cv.toDayJSWeekday(e.refDate,i,u);return e.createParsingComponents().assign("weekday",i).imply("day",l.date()).imply("month",l.month()+1).imply("year",l.year())}};mu.default=hu});var Eh=h(Xn=>{"use strict";var qv=Xn&&Xn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Xn,"__esModule",{value:!0});var vh=Ie(),bh=he(),Wv=qv(K()),Lv=R(),Yv=J(),$v=new RegExp(`(this|last|past|next|after\\s*this)\\s*(${Yv.matchAnyPattern(vh.TIME_UNIT_DICTIONARY)})(?=\\s*)(?=\\W|$)`,"i"),jv=1,Bv=2,yu=class extends Lv.AbstractParserWithWordBoundaryChecking{innerPattern(){return $v}innerExtract(e,t){let n=t[jv].toLowerCase(),i=t[Bv].toLowerCase(),s=vh.TIME_UNIT_DICTIONARY[i];if(n=="next"||n.startsWith("after")){let u={};return u[s]=1,bh.ParsingComponents.createRelativeFromReference(e.reference,u)}if(n=="last"||n=="past"){let u={};return u[s]=-1,bh.ParsingComponents.createRelativeFromReference(e.reference,u)}let a=e.createParsingComponents(),o=Wv.default(e.reference.instant);return i.match(/week/i)?(o=o.add(-o.get("d"),"d"),a.imply("day",o.date()),a.imply("month",o.month()+1),a.imply("year",o.year())):i.match(/month/i)?(o=o.add(-o.date()+1,"d"),a.imply("day",o.date()),a.assign("year",o.year()),a.assign("month",o.month()+1)):i.match(/year/i)&&(o=o.add(-o.date()+1,"d"),o=o.add(-o.month(),"month"),a.imply("day",o.date()),a.imply("month",o.month()+1),a.assign("year",o.year())),a}};Xn.default=yu});var yt=h(pn=>{"use strict";Object.defineProperty(pn,"__esModule",{value:!0});pn.ParsingContext=pn.Chrono=void 0;var dn=he(),Gv=gu(),fn=class{constructor(e){e=e||Gv.createCasualConfiguration(),this.parsers=[...e.parsers],this.refiners=[...e.refiners]}clone(){return new fn({parsers:[...this.parsers],refiners:[...this.refiners]})}parseDate(e,t,n){let i=this.parse(e,t,n);return i.length>0?i[0].start.date():null}parse(e,t,n){let i=new Ss(e,t,n),s=[];return this.parsers.forEach(a=>{let o=fn.executeParser(i,a);s=s.concat(o)}),s.sort((a,o)=>a.index-o.index),this.refiners.forEach(function(a){s=a.refine(i,s)}),s}static executeParser(e,t){let n=[],i=t.pattern(e),s=e.text,a=e.text,o=i.exec(a);for(;o;){let u=o.index+s.length-a.length;o.index=u;let l=t.extract(e,o);if(!l){a=s.substring(o.index+1),o=i.exec(a);continue}let c=null;l instanceof dn.ParsingResult?c=l:l instanceof dn.ParsingComponents?(c=e.createParsingResult(o.index,o[0]),c.start=l):c=e.createParsingResult(o.index,o[0],l),e.debug(()=>console.log(`${t.constructor.name} extracted result ${c}`)),n.push(c),a=s.substring(u+c.text.length),o=i.exec(a)}return n}};pn.Chrono=fn;var Ss=class{constructor(e,t,n){this.text=e,this.reference=new dn.ReferenceWithTimezone(t),this.option=n!=null?n:{},this.refDate=this.reference.instant}createParsingComponents(e){return e instanceof dn.ParsingComponents?e:new dn.ParsingComponents(this.reference,e)}createParsingResult(e,t,n,i){let s=typeof t=="string"?t:this.text.substring(e,t),a=n?this.createParsingComponents(n):null,o=i?this.createParsingComponents(i):null;return new dn.ParsingResult(this.reference,e,s,a,o)}debug(e){this.option.debug&&(this.option.debug instanceof Function?this.option.debug(e):this.option.debug.debug(e))}};pn.ParsingContext=Ss});var Lr=h(bu=>{"use strict";Object.defineProperty(bu,"__esModule",{value:!0});var Rh=Se(),Hv=new RegExp("([^\\d]|^)([0-3]{0,1}[0-9]{1})[\\/\\.\\-]([0-3]{0,1}[0-9]{1})(?:[\\/\\.\\-]([0-9]{4}|[0-9]{2}))?(\\W|$)","i"),Is=1,wh=5,Mh=2,Dh=3,_u=4,Tu=class{constructor(e){this.groupNumberMonth=e?Dh:Mh,this.groupNumberDay=e?Mh:Dh}pattern(){return Hv}extract(e,t){if(t[Is]=="/"||t[wh]=="/"){t.index+=t[0].length;return}let n=t.index+t[Is].length,i=t[0].substr(t[Is].length,t[0].length-t[Is].length-t[wh].length);if(i.match(/^\d\.\d$/)||i.match(/^\d\.\d{1,2}\.\d{1,2}\s*$/)||!t[_u]&&t[0].indexOf("/")<0)return;let s=e.createParsingResult(n,i),a=parseInt(t[this.groupNumberMonth]),o=parseInt(t[this.groupNumberDay]);if((a<1||a>12)&&a>12)if(o>=1&&o<=12&&a<=31)[o,a]=[a,o];else return null;if(o<1||o>31)return null;if(s.start.assign("day",o),s.start.assign("month",a),t[_u]){let u=parseInt(t[_u]),l=Rh.findMostLikelyADYear(u);s.start.assign("year",l)}else{let u=Rh.findYearClosestToRef(e.refDate,o,a);s.start.imply("year",u)}return s}};bu.default=Tu});var Oh=h(Eu=>{"use strict";Object.defineProperty(Eu,"__esModule",{value:!0});var Ph=Ie(),zv=he(),Kv=R(),Vv=st(),Zv=new RegExp(`(this|last|past|next|after|\\+|-)\\s*(${Ph.TIME_UNITS_PATTERN})(?=\\W|$)`,"i"),vu=class extends Kv.AbstractParserWithWordBoundaryChecking{innerPattern(){return Zv}innerExtract(e,t){let n=t[1].toLowerCase(),i=Ph.parseTimeUnits(t[2]);switch(n){case"last":case"past":case"-":i=Vv.reverseTimeUnits(i);break}return zv.ParsingComponents.createRelativeFromReference(e.reference,i)}};Eu.default=vu});var kh=h(Mu=>{"use strict";Object.defineProperty(Mu,"__esModule",{value:!0});var Xv=on(),Ru=he(),Qv=Ie(),Jv=st();function Ah(r){return r.text.match(/\s+(before|from)$/i)!=null}function e1(r){return r.text.match(/\s+(after|since)$/i)!=null}var wu=class extends Xv.MergingRefiner{patternBetween(){return/^\s*$/i}shouldMergeResults(e,t,n){return!e.match(this.patternBetween())||!Ah(t)&&!e1(t)?!1:!!n.start.get("day")&&!!n.start.get("month")&&!!n.start.get("year")}mergeResults(e,t,n){let i=Qv.parseTimeUnits(t.text);Ah(t)&&(i=Jv.reverseTimeUnits(i));let s=Ru.ParsingComponents.createRelativeFromReference(new Ru.ReferenceWithTimezone(n.start.date()),i);return new Ru.ParsingResult(n.reference,t.index,`${t.text}${e}${n.text}`,s)}};Mu.default=wu});var gu=h(Te=>{"use strict";var we=Te&&Te.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Te,"__esModule",{value:!0});Te.createConfiguration=Te.createCasualConfiguration=Te.parseDate=Te.parse=Te.GB=Te.strict=Te.casual=void 0;var t1=we(Ap()),r1=we(Ip()),n1=we(Lp()),i1=we(jp()),s1=we(Hp()),a1=we(zp()),o1=we(Vp()),u1=we(Zp()),l1=we(Xp()),c1=we(Qp()),d1=we(th()),f1=Gt(),p1=we(hh()),h1=we(mh()),m1=we(Th()),y1=we(Eh()),Du=yt(),g1=we(Lr()),_1=we(Oh()),T1=we(kh());Te.casual=new Du.Chrono(Nh(!1));Te.strict=new Du.Chrono(Us(!0,!1));Te.GB=new Du.Chrono(Us(!1,!0));function b1(r,e,t){return Te.casual.parse(r,e,t)}Te.parse=b1;function v1(r,e,t){return Te.casual.parseDate(r,e,t)}Te.parseDate=v1;function Nh(r=!1){let e=Us(!1,r);return e.parsers.unshift(new p1.default),e.parsers.unshift(new h1.default),e.parsers.unshift(new i1.default),e.parsers.unshift(new y1.default),e.parsers.unshift(new _1.default),e}Te.createCasualConfiguration=Nh;function Us(r=!0,e=!1){return f1.includeCommonConfiguration({parsers:[new g1.default(e),new t1.default,new r1.default,new n1.default,new m1.default,new s1.default,new a1.default,new o1.default(r),new u1.default(r),new l1.default(r)],refiners:[new T1.default,new d1.default,new c1.default]},r)}Te.createConfiguration=Us});var xh=h(Ou=>{"use strict";Object.defineProperty(Ou,"__esModule",{value:!0});var E1=Fr(),Pu=class extends E1.AbstractTimeExpressionParser{primaryPrefix(){return"(?:(?:um|von)\\s*)?"}followingPhase(){return"\\s*(?:\\-|\\\u2013|\\~|\\\u301C|bis)\\s*"}extractPrimaryTimeComponents(e,t){return t[0].match(/^\s*\d{4}\s*$/)?null:super.extractPrimaryTimeComponents(e,t)}};Ou.default=Pu});var Qn=h(ne=>{"use strict";Object.defineProperty(ne,"__esModule",{value:!0});ne.parseTimeUnits=ne.TIME_UNITS_PATTERN=ne.parseYear=ne.YEAR_PATTERN=ne.parseNumberPattern=ne.NUMBER_PATTERN=ne.TIME_UNIT_DICTIONARY=ne.INTEGER_WORD_DICTIONARY=ne.MONTH_DICTIONARY=ne.WEEKDAY_DICTIONARY=void 0;var Au=J(),R1=Se();ne.WEEKDAY_DICTIONARY={sonntag:0,so:0,montag:1,mo:1,dienstag:2,di:2,mittwoch:3,mi:3,donnerstag:4,do:4,freitag:5,fr:5,samstag:6,sa:6};ne.MONTH_DICTIONARY={januar:1,j\u00E4nner:1,janner:1,jan:1,"jan.":1,februar:2,feber:2,feb:2,"feb.":2,m\u00E4rz:3,maerz:3,m\u00E4r:3,"m\xE4r.":3,mrz:3,"mrz.":3,april:4,apr:4,"apr.":4,mai:5,juni:6,jun:6,"jun.":6,juli:7,jul:7,"jul.":7,august:8,aug:8,"aug.":8,september:9,sep:9,"sep.":9,sept:9,"sept.":9,oktober:10,okt:10,"okt.":10,november:11,nov:11,"nov.":11,dezember:12,dez:12,"dez.":12};ne.INTEGER_WORD_DICTIONARY={eins:1,eine:1,einem:1,einen:1,einer:1,zwei:2,drei:3,vier:4,f\u00FCnf:5,fuenf:5,sechs:6,sieben:7,acht:8,neun:9,zehn:10,elf:11,zw\u00F6lf:12,zwoelf:12};ne.TIME_UNIT_DICTIONARY={sek:"second",sekunde:"second",sekunden:"second",min:"minute",minute:"minute",minuten:"minute",h:"hour",std:"hour",stunde:"hour",stunden:"hour",tag:"d",tage:"d",tagen:"d",woche:"week",wochen:"week",monat:"month",monate:"month",monaten:"month",monats:"month",quartal:"quarter",quartals:"quarter",quartale:"quarter",quartalen:"quarter",a:"year",j:"year",jr:"year",jahr:"year",jahre:"year",jahren:"year",jahres:"year"};ne.NUMBER_PATTERN=`(?:${Au.matchAnyPattern(ne.INTEGER_WORD_DICTIONARY)}|[0-9]+|[0-9]+\\.[0-9]+|half(?:\\s*an?)?|an?\\b(?:\\s*few)?|few|several|a?\\s*couple\\s*(?:of)?)`;function Sh(r){let e=r.toLowerCase();return ne.INTEGER_WORD_DICTIONARY[e]!==void 0?ne.INTEGER_WORD_DICTIONARY[e]:e==="a"||e==="an"?1:e.match(/few/)?3:e.match(/half/)?.5:e.match(/couple/)?2:e.match(/several/)?7:parseFloat(e)}ne.parseNumberPattern=Sh;ne.YEAR_PATTERN="(?:[0-9]{1,4}(?:\\s*[vn]\\.?\\s*(?:C(?:hr)?|(?:u\\.?|d\\.?(?:\\s*g\\.?)?)?\\s*Z)\\.?|\\s*(?:u\\.?|d\\.?(?:\\s*g\\.)?)\\s*Z\\.?)?)";function w1(r){if(/v/i.test(r))return-parseInt(r.replace(/[^0-9]+/gi,""));if(/n/i.test(r))return parseInt(r.replace(/[^0-9]+/gi,""));if(/z/i.test(r))return parseInt(r.replace(/[^0-9]+/gi,""));let e=parseInt(r);return R1.findMostLikelyADYear(e)}ne.parseYear=w1;var Ih=`(${ne.NUMBER_PATTERN})\\s{0,5}(${Au.matchAnyPattern(ne.TIME_UNIT_DICTIONARY)})\\s{0,5}`,Ch=new RegExp(Ih,"i");ne.TIME_UNITS_PATTERN=Au.repeatedTimeunitPattern("",Ih);function M1(r){let e={},t=r,n=Ch.exec(t);for(;n;)D1(e,n),t=t.substring(n[0].length),n=Ch.exec(t);return e}ne.parseTimeUnits=M1;function D1(r,e){let t=Sh(e[1]),n=ne.TIME_UNIT_DICTIONARY[e[2].toLowerCase()];r[n]=t}});var Fh=h(Nu=>{"use strict";Object.defineProperty(Nu,"__esModule",{value:!0});var Uh=Qn(),P1=J(),O1=R(),A1=Wr(),k1=new RegExp(`(?:(?:\\,|\\(|\\\uFF08)\\s*)?(?:a[mn]\\s*?)?(?:(diese[mn]|letzte[mn]|n(?:\xE4|ae)chste[mn])\\s*)?(${P1.matchAnyPattern(Uh.WEEKDAY_DICTIONARY)})(?:\\s*(?:\\,|\\)|\\\uFF09))?(?:\\s*(diese|letzte|n(?:\xE4|ae)chste)\\s*woche)?(?=\\W|$)`,"i"),N1=1,x1=3,C1=2,ku=class extends O1.AbstractParserWithWordBoundaryChecking{innerPattern(){return k1}innerExtract(e,t){let n=t[C1].toLowerCase(),i=Uh.WEEKDAY_DICTIONARY[n],s=t[N1],a=t[x1],o=s||a;o=o||"",o=o.toLowerCase();let u=null;o.match(/letzte/)?u="last":o.match(/chste/)?u="next":o.match(/diese/)&&(u="this");let l=A1.toDayJSWeekday(e.refDate,i,u);return e.createParsingComponents().assign("weekday",i).imply("day",l.date()).imply("month",l.month()+1).imply("year",l.year())}};Nu.default=ku});var Yh=h(xu=>{"use strict";Object.defineProperty(xu,"__esModule",{value:!0});var Tr=Ee(),S1=new RegExp("(^|\\s|T)(?:(?:um|von)\\s*)?(\\d{1,2})(?:h|:)?(?:(\\d{1,2})(?:m|:)?)?(?:(\\d{1,2})(?:s)?)?(?:\\s*Uhr)?(?:\\s*(morgens|vormittags|nachmittags|abends|nachts|am\\s+(?:Morgen|Vormittag|Nachmittag|Abend)|in\\s+der\\s+Nacht))?(?=\\W|$)","i"),I1=new RegExp("^\\s*(\\-|\\\u2013|\\~|\\\u301C|bis(?:\\s+um)?|\\?)\\s*(\\d{1,2})(?:h|:)?(?:(\\d{1,2})(?:m|:)?)?(?:(\\d{1,2})(?:s)?)?(?:\\s*Uhr)?(?:\\s*(morgens|vormittags|nachmittags|abends|nachts|am\\s+(?:Morgen|Vormittag|Nachmittag|Abend)|in\\s+der\\s+Nacht))?(?=\\W|$)","i"),U1=2,qh=3,Wh=4,Lh=5,hn=class{pattern(e){return S1}extract(e,t){let n=e.createParsingResult(t.index+t[1].length,t[0].substring(t[1].length));if(n.text.match(/^\d{4}$/)||(n.start=hn.extractTimeComponent(n.start.clone(),t),!n.start))return t.index+=t[0].length,null;let i=e.text.substring(t.index+t[0].length),s=I1.exec(i);return s&&(n.end=hn.extractTimeComponent(n.start.clone(),s),n.end&&(n.text+=s[0])),n}static extractTimeComponent(e,t){let n=0,i=0,s=null;if(n=parseInt(t[U1]),t[qh]!=null&&(i=parseInt(t[qh])),i>=60||n>24)return null;if(n>=12&&(s=Tr.Meridiem.PM),t[Lh]!=null){if(n>12)return null;let a=t[Lh].toLowerCase();a.match(/morgen|vormittag/)&&(s=Tr.Meridiem.AM,n==12&&(n=0)),a.match(/nachmittag|abend/)&&(s=Tr.Meridiem.PM,n!=12&&(n+=12)),a.match(/nacht/)&&(n==12?(s=Tr.Meridiem.AM,n=0):n<6?s=Tr.Meridiem.AM:(s=Tr.Meridiem.PM,n+=12))}if(e.assign("hour",n),e.assign("minute",i),s!==null?e.assign("meridiem",s):n<12?e.imply("meridiem",Tr.Meridiem.AM):e.imply("meridiem",Tr.Meridiem.PM),t[Wh]!=null){let a=parseInt(t[Wh]);if(a>=60)return null;e.assign("second",a)}return e}};xu.default=hn});var $h=h(Jn=>{"use strict";var F1=Jn&&Jn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Jn,"__esModule",{value:!0});var q1=F1(kt()),Cu=class extends q1.default{patternBetween(){return/^\s*(bis(?:\s*(?:am|zum))?|-)\s*$/i}};Jn.default=Cu});var jh=h(ei=>{"use strict";var W1=ei&&ei.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ei,"__esModule",{value:!0});var L1=W1(Bt()),Su=class extends L1.default{patternBetween(){return new RegExp("^\\s*(T|um|am|,|-)?\\s*$")}};ei.default=Su});var Iu=h(ri=>{"use strict";var Y1=ri&&ri.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ri,"__esModule",{value:!0});var $1=Y1(K()),Yr=Ee(),j1=R(),B1=it(),G1=st(),ti=class extends j1.AbstractParserWithWordBoundaryChecking{innerPattern(e){return/(diesen)?\s*(morgen|vormittag|mittags?|nachmittag|abend|nacht|mitternacht)(?=\W|$)/i}innerExtract(e,t){let n=$1.default(e.refDate),i=t[2].toLowerCase(),s=e.createParsingComponents();return B1.implySimilarTime(s,n),ti.extractTimeComponents(s,i)}static extractTimeComponents(e,t){switch(t){case"morgen":e.imply("hour",6),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Yr.Meridiem.AM);break;case"vormittag":e.imply("hour",9),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Yr.Meridiem.AM);break;case"mittag":case"mittags":e.imply("hour",12),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Yr.Meridiem.AM);break;case"nachmittag":e.imply("hour",15),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Yr.Meridiem.PM);break;case"abend":e.imply("hour",18),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Yr.Meridiem.PM);break;case"nacht":e.imply("hour",22),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Yr.Meridiem.PM);break;case"mitternacht":e.get("hour")>1&&(e=G1.addImpliedTimeUnits(e,{day:1})),e.imply("hour",0),e.imply("minute",0),e.imply("second",0),e.imply("meridiem",Yr.Meridiem.AM);break}return e}};ri.default=ti});var Hh=h(gt=>{"use strict";var H1=gt&>.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),z1=gt&>.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),K1=gt&>.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&H1(e,r,t);return z1(e,r),e},Gh=gt&>.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(gt,"__esModule",{value:!0});var V1=Gh(K()),Z1=R(),$r=it(),X1=Gh(Iu()),Bh=K1(zt()),Q1=new RegExp("(jetzt|heute|morgen|\xFCbermorgen|uebermorgen|gestern|vorgestern|letzte\\s*nacht)(?:\\s*(morgen|vormittag|mittags?|nachmittag|abend|nacht|mitternacht))?(?=\\W|$)","i"),J1=1,eE=2,Uu=class extends Z1.AbstractParserWithWordBoundaryChecking{innerPattern(e){return Q1}innerExtract(e,t){let n=V1.default(e.refDate),i=(t[J1]||"").toLowerCase(),s=(t[eE]||"").toLowerCase(),a=e.createParsingComponents();switch(i){case"jetzt":a=Bh.now(e.reference);break;case"heute":a=Bh.today(e.reference);break;case"morgen":$r.assignTheNextDay(a,n);break;case"\xFCbermorgen":case"uebermorgen":n=n.add(1,"day"),$r.assignTheNextDay(a,n);break;case"gestern":n=n.add(-1,"day"),$r.assignSimilarDate(a,n),$r.implySimilarTime(a,n);break;case"vorgestern":n=n.add(-2,"day"),$r.assignSimilarDate(a,n),$r.implySimilarTime(a,n);break;default:i.match(/letzte\s*nacht/)&&(n.hour()>6&&(n=n.add(-1,"day")),$r.assignSimilarDate(a,n),a.imply("hour",0));break}return s&&(a=X1.default.extractTimeComponents(a,s)),a}};gt.default=Uu});var Qh=h(qu=>{"use strict";Object.defineProperty(qu,"__esModule",{value:!0});var tE=Se(),Zh=Qn(),Xh=Qn(),rE=J(),nE=R(),iE=new RegExp(`(?:am\\s*?)?(?:den\\s*?)?([0-9]{1,2})\\.(?:\\s*(?:bis(?:\\s*(?:am|zum))?|\\-|\\\u2013|\\s)\\s*([0-9]{1,2})\\.?)?\\s*(${rE.matchAnyPattern(Zh.MONTH_DICTIONARY)})(?:(?:-|/|,?\\s*)(${Xh.YEAR_PATTERN}(?![^\\s]\\d)))?(?=\\W|$)`,"i"),zh=1,Kh=2,sE=3,Vh=4,Fu=class extends nE.AbstractParserWithWordBoundaryChecking{innerPattern(){return iE}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=Zh.MONTH_DICTIONARY[t[sE].toLowerCase()],s=parseInt(t[zh]);if(s>31)return t.index=t.index+t[zh].length,null;if(n.start.assign("month",i),n.start.assign("day",s),t[Vh]){let a=Xh.parseYear(t[Vh]);n.start.assign("year",a)}else{let a=tE.findYearClosestToRef(e.refDate,s,i);n.start.imply("year",a)}if(t[Kh]){let a=parseInt(t[Kh]);n.end=n.start.clone(),n.end.assign("day",a)}return n}};qu.default=Fu});var Jh=h(Lu=>{"use strict";Object.defineProperty(Lu,"__esModule",{value:!0});var Fs=Qn(),aE=he(),oE=R(),uE=st(),lE=J(),Wu=class extends oE.AbstractParserWithWordBoundaryChecking{constructor(){super()}innerPattern(){return new RegExp(`(?:\\s*((?:n\xE4chste|kommende|folgende|letzte|vergangene|vorige|vor(?:her|an)gegangene)(?:s|n|m|r)?|vor|in)\\s*)?(${Fs.NUMBER_PATTERN})?(?:\\s*(n\xE4chste|kommende|folgende|letzte|vergangene|vorige|vor(?:her|an)gegangene)(?:s|n|m|r)?)?\\s*(${lE.matchAnyPattern(Fs.TIME_UNIT_DICTIONARY)})`,"i")}innerExtract(e,t){let n=t[2]?Fs.parseNumberPattern(t[2]):1,i=Fs.TIME_UNIT_DICTIONARY[t[4].toLowerCase()],s={};s[i]=n;let a=t[1]||t[3]||"";if(a=a.toLowerCase(),!!a)return(/vor/.test(a)||/letzte/.test(a)||/vergangen/.test(a))&&(s=uE.reverseTimeUnits(s)),aE.ParsingComponents.createRelativeFromReference(e.reference,s)}};Lu.default=Wu});var rm=h(Me=>{"use strict";var _t=Me&&Me.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Me,"__esModule",{value:!0});Me.createConfiguration=Me.createCasualConfiguration=Me.parseDate=Me.parse=Me.strict=Me.casual=void 0;var cE=Gt(),em=yt(),dE=_t(Lr()),fE=_t(uu()),pE=_t(xh()),hE=_t(Fh()),mE=_t(Yh()),yE=_t($h()),gE=_t(jh()),_E=_t(Hh()),TE=_t(Iu()),bE=_t(Qh()),vE=_t(Jh());Me.casual=new em.Chrono(tm());Me.strict=new em.Chrono(Yu(!0));function EE(r,e,t){return Me.casual.parse(r,e,t)}Me.parse=EE;function RE(r,e,t){return Me.casual.parseDate(r,e,t)}Me.parseDate=RE;function tm(r=!0){let e=Yu(!1,r);return e.parsers.unshift(new TE.default),e.parsers.unshift(new _E.default),e.parsers.unshift(new vE.default),e}Me.createCasualConfiguration=tm;function Yu(r=!0,e=!0){return cE.includeCommonConfiguration({parsers:[new fE.default,new dE.default(e),new pE.default,new mE.default,new bE.default,new hE.default],refiners:[new yE.default,new gE.default]},r)}Me.createConfiguration=Yu});var im=h(Tt=>{"use strict";var wE=Tt&&Tt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),ME=Tt&&Tt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),DE=Tt&&Tt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&wE(e,r,t);return ME(e,r),e},PE=Tt&&Tt.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Tt,"__esModule",{value:!0});var OE=PE(K()),AE=Ee(),kE=R(),nm=it(),qs=DE(zt()),$u=class extends kE.AbstractParserWithWordBoundaryChecking{innerPattern(e){return/(maintenant|aujourd'hui|demain|hier|cette\s*nuit|la\s*veille)(?=\W|$)/i}innerExtract(e,t){let n=OE.default(e.refDate),i=t[0].toLowerCase(),s=e.createParsingComponents();switch(i){case"maintenant":return qs.now(e.reference);case"aujourd'hui":return qs.today(e.reference);case"hier":return qs.yesterday(e.reference);case"demain":return qs.tomorrow(e.reference);default:i.match(/cette\s*nuit/)?(nm.assignSimilarDate(s,n),s.imply("hour",22),s.imply("meridiem",AE.Meridiem.PM)):i.match(/la\s*veille/)&&(n=n.add(-1,"day"),nm.assignSimilarDate(s,n),s.imply("hour",0))}return s}};Tt.default=$u});var sm=h(Bu=>{"use strict";Object.defineProperty(Bu,"__esModule",{value:!0});var ni=Ee(),NE=R(),ju=class extends NE.AbstractParserWithWordBoundaryChecking{innerPattern(e){return/(cet?)?\s*(matin|soir|après-midi|aprem|a midi|à minuit)(?=\W|$)/i}innerExtract(e,t){let n=t[2].toLowerCase(),i=e.createParsingComponents();switch(n){case"apr\xE8s-midi":case"aprem":i.imply("hour",14),i.imply("minute",0),i.imply("meridiem",ni.Meridiem.PM);break;case"soir":i.imply("hour",18),i.imply("minute",0),i.imply("meridiem",ni.Meridiem.PM);break;case"matin":i.imply("hour",8),i.imply("minute",0),i.imply("meridiem",ni.Meridiem.AM);break;case"a midi":i.imply("hour",12),i.imply("minute",0),i.imply("meridiem",ni.Meridiem.AM);break;case"\xE0 minuit":i.imply("hour",0),i.imply("meridiem",ni.Meridiem.AM);break}return i}};Bu.default=ju});var am=h(Hu=>{"use strict";Object.defineProperty(Hu,"__esModule",{value:!0});var xE=Fr(),Gu=class extends xE.AbstractTimeExpressionParser{primaryPrefix(){return"(?:(?:[\xE0a])\\s*)?"}followingPhase(){return"\\s*(?:\\-|\\\u2013|\\~|\\\u301C|[\xE0a]|\\?)\\s*"}extractPrimaryTimeComponents(e,t){return t[0].match(/^\s*\d{4}\s*$/)?null:super.extractPrimaryTimeComponents(e,t)}};Hu.default=Gu});var om=h(ii=>{"use strict";var CE=ii&&ii.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ii,"__esModule",{value:!0});var SE=CE(Bt()),zu=class extends SE.default{patternBetween(){return new RegExp("^\\s*(T|\xE0|a|vers|de|,|-)?\\s*$")}};ii.default=zu});var um=h(si=>{"use strict";var IE=si&&si.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(si,"__esModule",{value:!0});var UE=IE(kt()),Ku=class extends UE.default{patternBetween(){return/^\s*(à|a|-)\s*$/i}};si.default=Ku});var br=h(V=>{"use strict";Object.defineProperty(V,"__esModule",{value:!0});V.parseTimeUnits=V.TIME_UNITS_PATTERN=V.parseYear=V.YEAR_PATTERN=V.parseOrdinalNumberPattern=V.ORDINAL_NUMBER_PATTERN=V.parseNumberPattern=V.NUMBER_PATTERN=V.TIME_UNIT_DICTIONARY=V.INTEGER_WORD_DICTIONARY=V.MONTH_DICTIONARY=V.WEEKDAY_DICTIONARY=void 0;var Vu=J();V.WEEKDAY_DICTIONARY={dimanche:0,dim:0,lundi:1,lun:1,mardi:2,mar:2,mercredi:3,mer:3,jeudi:4,jeu:4,vendredi:5,ven:5,samedi:6,sam:6};V.MONTH_DICTIONARY={janvier:1,jan:1,"jan.":1,f\u00E9vrier:2,f\u00E9v:2,"f\xE9v.":2,fevrier:2,fev:2,"fev.":2,mars:3,mar:3,"mar.":3,avril:4,avr:4,"avr.":4,mai:5,juin:6,jun:6,juillet:7,juil:7,jul:7,"jul.":7,ao\u00FBt:8,aout:8,septembre:9,sep:9,"sep.":9,sept:9,"sept.":9,octobre:10,oct:10,"oct.":10,novembre:11,nov:11,"nov.":11,d\u00E9cembre:12,decembre:12,dec:12,"dec.":12};V.INTEGER_WORD_DICTIONARY={un:1,deux:2,trois:3,quatre:4,cinq:5,six:6,sept:7,huit:8,neuf:9,dix:10,onze:11,douze:12,treize:13};V.TIME_UNIT_DICTIONARY={sec:"second",seconde:"second",secondes:"second",min:"minute",mins:"minute",minute:"minute",minutes:"minute",h:"hour",hr:"hour",hrs:"hour",heure:"hour",heures:"hour",jour:"d",jours:"d",semaine:"week",semaines:"week",mois:"month",trimestre:"quarter",trimestres:"quarter",ans:"year",ann\u00E9e:"year",ann\u00E9es:"year"};V.NUMBER_PATTERN=`(?:${Vu.matchAnyPattern(V.INTEGER_WORD_DICTIONARY)}|[0-9]+|[0-9]+\\.[0-9]+|une?\\b|quelques?|demi-?)`;function cm(r){let e=r.toLowerCase();return V.INTEGER_WORD_DICTIONARY[e]!==void 0?V.INTEGER_WORD_DICTIONARY[e]:e==="une"||e==="un"?1:e.match(/quelques?/)?3:e.match(/demi-?/)?.5:parseFloat(e)}V.parseNumberPattern=cm;V.ORDINAL_NUMBER_PATTERN="(?:[0-9]{1,2}(?:er)?)";function FE(r){let e=r.toLowerCase();return e=e.replace(/(?:er)$/i,""),parseInt(e)}V.parseOrdinalNumberPattern=FE;V.YEAR_PATTERN="(?:[1-9][0-9]{0,3}\\s*(?:AC|AD|p\\.\\s*C(?:hr?)?\\.\\s*n\\.)|[1-2][0-9]{3}|[5-9][0-9])";function qE(r){if(/AC/i.test(r))return r=r.replace(/BC/i,""),-parseInt(r);if(/AD/i.test(r)||/C/i.test(r))return r=r.replace(/[^\d]+/i,""),parseInt(r);let e=parseInt(r);return e<100&&(e>50?e=e+1900:e=e+2e3),e}V.parseYear=qE;var dm=`(${V.NUMBER_PATTERN})\\s{0,5}(${Vu.matchAnyPattern(V.TIME_UNIT_DICTIONARY)})\\s{0,5}`,lm=new RegExp(dm,"i");V.TIME_UNITS_PATTERN=Vu.repeatedTimeunitPattern("",dm);function WE(r){let e={},t=r,n=lm.exec(t);for(;n;)LE(e,n),t=t.substring(n[0].length),n=lm.exec(t);return e}V.parseTimeUnits=WE;function LE(r,e){let t=cm(e[1]),n=V.TIME_UNIT_DICTIONARY[e[2].toLowerCase()];r[n]=t}});var pm=h(Xu=>{"use strict";Object.defineProperty(Xu,"__esModule",{value:!0});var fm=br(),YE=J(),$E=R(),jE=Wr(),BE=new RegExp(`(?:(?:\\,|\\(|\\\uFF08)\\s*)?(?:(?:ce)\\s*)?(${YE.matchAnyPattern(fm.WEEKDAY_DICTIONARY)})(?:\\s*(?:\\,|\\)|\\\uFF09))?(?:\\s*(dernier|prochain)\\s*)?(?=\\W|\\d|$)`,"i"),GE=1,HE=2,Zu=class extends $E.AbstractParserWithWordBoundaryChecking{innerPattern(){return BE}innerExtract(e,t){let n=t[GE].toLowerCase(),i=fm.WEEKDAY_DICTIONARY[n];if(i===void 0)return null;let s=t[HE];s=s||"",s=s.toLowerCase();let a=null;s=="dernier"?a="last":s=="prochain"&&(a="next");let o=jE.toDayJSWeekday(e.refDate,i,a);return e.createParsingComponents().assign("weekday",i).imply("day",o.date()).imply("month",o.month()+1).imply("year",o.year())}};Xu.default=Zu});var gm=h(Qu=>{"use strict";Object.defineProperty(Qu,"__esModule",{value:!0});var ai=Ee(),zE=new RegExp("(^|\\s|T)(?:(?:[\xE0a])\\s*)?(\\d{1,2})(?:h|:)?(?:(\\d{1,2})(?:m|:)?)?(?:(\\d{1,2})(?:s|:)?)?(?:\\s*(A\\.M\\.|P\\.M\\.|AM?|PM?))?(?=\\W|$)","i"),KE=new RegExp("^\\s*(\\-|\\\u2013|\\~|\\\u301C|[\xE0a]|\\?)\\s*(\\d{1,2})(?:h|:)?(?:(\\d{1,2})(?:m|:)?)?(?:(\\d{1,2})(?:s|:)?)?(?:\\s*(A\\.M\\.|P\\.M\\.|AM?|PM?))?(?=\\W|$)","i"),VE=2,hm=3,mm=4,ym=5,mn=class{pattern(e){return zE}extract(e,t){let n=e.createParsingResult(t.index+t[1].length,t[0].substring(t[1].length));if(n.text.match(/^\d{4}$/)||(n.start=mn.extractTimeComponent(n.start.clone(),t),!n.start))return t.index+=t[0].length,null;let i=e.text.substring(t.index+t[0].length),s=KE.exec(i);return s&&(n.end=mn.extractTimeComponent(n.start.clone(),s),n.end&&(n.text+=s[0])),n}static extractTimeComponent(e,t){let n=0,i=0,s=null;if(n=parseInt(t[VE]),t[hm]!=null&&(i=parseInt(t[hm])),i>=60||n>24)return null;if(n>=12&&(s=ai.Meridiem.PM),t[ym]!=null){if(n>12)return null;let a=t[ym][0].toLowerCase();a=="a"&&(s=ai.Meridiem.AM,n==12&&(n=0)),a=="p"&&(s=ai.Meridiem.PM,n!=12&&(n+=12))}if(e.assign("hour",n),e.assign("minute",i),s!==null?e.assign("meridiem",s):n<12?e.imply("meridiem",ai.Meridiem.AM):e.imply("meridiem",ai.Meridiem.PM),t[mm]!=null){let a=parseInt(t[mm]);if(a>=60)return null;e.assign("second",a)}return e}};Qu.default=mn});var Rm=h(el=>{"use strict";Object.defineProperty(el,"__esModule",{value:!0});var ZE=Se(),vm=br(),Em=br(),Ws=br(),XE=J(),QE=R(),JE=new RegExp(`(?:on\\s*?)?(${Ws.ORDINAL_NUMBER_PATTERN})(?:\\s*(?:au|\\-|\\\u2013|jusqu'au?|\\s)\\s*(${Ws.ORDINAL_NUMBER_PATTERN}))?(?:-|/|\\s*(?:de)?\\s*)(${XE.matchAnyPattern(vm.MONTH_DICTIONARY)})(?:(?:-|/|,?\\s*)(${Em.YEAR_PATTERN}(?![^\\s]\\d)))?(?=\\W|$)`,"i"),_m=1,Tm=2,e0=3,bm=4,Ju=class extends QE.AbstractParserWithWordBoundaryChecking{innerPattern(){return JE}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=vm.MONTH_DICTIONARY[t[e0].toLowerCase()],s=Ws.parseOrdinalNumberPattern(t[_m]);if(s>31)return t.index=t.index+t[_m].length,null;if(n.start.assign("month",i),n.start.assign("day",s),t[bm]){let a=Em.parseYear(t[bm]);n.start.assign("year",a)}else{let a=ZE.findYearClosestToRef(e.refDate,s,i);n.start.imply("year",a)}if(t[Tm]){let a=Ws.parseOrdinalNumberPattern(t[Tm]);n.end=n.start.clone(),n.end.assign("day",a)}return n}};el.default=Ju});var Mm=h(rl=>{"use strict";Object.defineProperty(rl,"__esModule",{value:!0});var wm=br(),t0=he(),r0=R(),n0=st(),tl=class extends r0.AbstractParserWithWordBoundaryChecking{constructor(){super()}innerPattern(){return new RegExp(`il y a\\s*(${wm.TIME_UNITS_PATTERN})(?=(?:\\W|$))`,"i")}innerExtract(e,t){let n=wm.parseTimeUnits(t[1]),i=n0.reverseTimeUnits(n);return t0.ParsingComponents.createRelativeFromReference(e.reference,i)}};rl.default=tl});var Pm=h(il=>{"use strict";Object.defineProperty(il,"__esModule",{value:!0});var Dm=br(),i0=he(),s0=R(),nl=class extends s0.AbstractParserWithWordBoundaryChecking{innerPattern(){return new RegExp(`(?:dans|en|pour|pendant|de)\\s*(${Dm.TIME_UNITS_PATTERN})(?=\\W|$)`,"i")}innerExtract(e,t){let n=Dm.parseTimeUnits(t[1]);return i0.ParsingComponents.createRelativeFromReference(e.reference,n)}};il.default=nl});var Om=h(al=>{"use strict";Object.defineProperty(al,"__esModule",{value:!0});var Ls=br(),a0=he(),o0=R(),u0=st(),l0=J(),sl=class extends o0.AbstractParserWithWordBoundaryChecking{constructor(){super()}innerPattern(){return new RegExp(`(?:les?|la|l'|du|des?)\\s*(${Ls.NUMBER_PATTERN})?(?:\\s*(prochaine?s?|derni[e\xE8]re?s?|pass[\xE9e]e?s?|pr[\xE9e]c[\xE9e]dents?|suivante?s?))?\\s*(${l0.matchAnyPattern(Ls.TIME_UNIT_DICTIONARY)})(?:\\s*(prochaine?s?|derni[e\xE8]re?s?|pass[\xE9e]e?s?|pr[\xE9e]c[\xE9e]dents?|suivante?s?))?`,"i")}innerExtract(e,t){let n=t[1]?Ls.parseNumberPattern(t[1]):1,i=Ls.TIME_UNIT_DICTIONARY[t[3].toLowerCase()],s={};s[i]=n;let a=t[2]||t[4]||"";if(a=a.toLowerCase(),!!a)return(/derni[eè]re?s?/.test(a)||/pass[ée]e?s?/.test(a)||/pr[ée]c[ée]dents?/.test(a))&&(s=u0.reverseTimeUnits(s)),a0.ParsingComponents.createRelativeFromReference(e.reference,s)}};al.default=sl});var Nm=h(De=>{"use strict";var at=De&&De.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(De,"__esModule",{value:!0});De.createConfiguration=De.createCasualConfiguration=De.parseDate=De.parse=De.strict=De.casual=void 0;var c0=Gt(),Am=yt(),d0=at(im()),f0=at(sm()),p0=at(Lr()),h0=at(am()),m0=at(om()),y0=at(um()),g0=at(pm()),_0=at(gm()),T0=at(Rm()),b0=at(Mm()),v0=at(Pm()),E0=at(Om());De.casual=new Am.Chrono(km());De.strict=new Am.Chrono(ol(!0));function R0(r,e,t){return De.casual.parse(r,e,t)}De.parse=R0;function w0(r,e,t){return De.casual.parseDate(r,e,t)}De.parseDate=w0;function km(r=!0){let e=ol(!1,r);return e.parsers.unshift(new d0.default),e.parsers.unshift(new f0.default),e.parsers.unshift(new E0.default),e}De.createCasualConfiguration=km;function ol(r=!0,e=!0){return c0.includeCommonConfiguration({parsers:[new p0.default(e),new T0.default,new h0.default,new _0.default,new b0.default,new v0.default,new g0.default],refiners:[new m0.default,new y0.default]},r)}De.createConfiguration=ol});var xm=h(Ys=>{"use strict";Object.defineProperty(Ys,"__esModule",{value:!0});Ys.toHankaku=void 0;function M0(r){return String(r).replace(/\u2019/g,"'").replace(/\u201D/g,'"').replace(/\u3000/g," ").replace(/\uFFE5/g,"\xA5").replace(/[\uFF01\uFF03-\uFF06\uFF08\uFF09\uFF0C-\uFF19\uFF1C-\uFF1F\uFF21-\uFF3B\uFF3D\uFF3F\uFF41-\uFF5B\uFF5D\uFF5E]/g,D0)}Ys.toHankaku=M0;function D0(r){return String.fromCharCode(r.charCodeAt(0)-65248)}});var Sm=h(oi=>{"use strict";var P0=oi&&oi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(oi,"__esModule",{value:!0});var ul=xm(),O0=Se(),A0=P0(K()),k0=/(?:(?:([同今本])|((昭和|平成|令和)?([0-90-9]{1,4}|元)))年\s*)?([0-90-9]{1,2})月\s*([0-90-9]{1,2})日/i,Cm=1,N0=2,ll=3,x0=4,C0=5,S0=6,cl=class{pattern(){return k0}extract(e,t){let n=parseInt(ul.toHankaku(t[C0])),i=parseInt(ul.toHankaku(t[S0])),s=e.createParsingComponents({day:i,month:n});if(t[Cm]&&t[Cm].match("\u540C|\u4ECA|\u672C")){let a=A0.default(e.refDate);s.assign("year",a.year())}if(t[N0]){let a=t[x0],o=a=="\u5143"?1:parseInt(ul.toHankaku(a));t[ll]=="\u4EE4\u548C"?o+=2018:t[ll]=="\u5E73\u6210"?o+=1988:t[ll]=="\u662D\u548C"&&(o+=1925),s.assign("year",o)}else{let a=O0.findYearClosestToRef(e.refDate,i,n);s.imply("year",a)}return s}};oi.default=cl});var Im=h(ui=>{"use strict";var I0=ui&&ui.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ui,"__esModule",{value:!0});var U0=I0(kt()),dl=class extends U0.default{patternBetween(){return/^\s*(から|ー|-)\s*$/i}};ui.default=dl});var Fm=h(bt=>{"use strict";var F0=bt&&bt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),q0=bt&&bt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),W0=bt&&bt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&F0(e,r,t);return q0(e,r),e},L0=bt&&bt.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(bt,"__esModule",{value:!0});var Y0=L0(K()),Um=Ee(),fl=W0(zt()),$0=/今日|当日|昨日|明日|今夜|今夕|今晩|今朝/i,pl=class{pattern(){return $0}extract(e,t){let n=t[0],i=Y0.default(e.refDate),s=e.createParsingComponents();switch(n){case"\u6628\u65E5":return fl.yesterday(e.reference);case"\u660E\u65E5":return fl.tomorrow(e.reference);case"\u4ECA\u65E5":case"\u5F53\u65E5":return fl.today(e.reference)}return n=="\u4ECA\u591C"||n=="\u4ECA\u5915"||n=="\u4ECA\u6669"?(s.imply("hour",22),s.assign("meridiem",Um.Meridiem.PM)):n.match("\u4ECA\u671D")&&(s.imply("hour",6),s.assign("meridiem",Um.Meridiem.AM)),s.assign("day",i.date()),s.assign("month",i.month()+1),s.assign("year",i.year()),s}};bt.default=pl});var Lm=h(Pe=>{"use strict";var hl=Pe&&Pe.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Pe,"__esModule",{value:!0});Pe.createConfiguration=Pe.createCasualConfiguration=Pe.parseDate=Pe.parse=Pe.strict=Pe.casual=void 0;var j0=hl(Sm()),B0=hl(Im()),G0=hl(Fm()),qm=yt();Pe.casual=new qm.Chrono(Wm());Pe.strict=new qm.Chrono(ml());function H0(r,e,t){return Pe.casual.parse(r,e,t)}Pe.parse=H0;function z0(r,e,t){return Pe.casual.parseDate(r,e,t)}Pe.parseDate=z0;function Wm(){let r=ml();return r.parsers.unshift(new G0.default),r}Pe.createCasualConfiguration=Wm;function ml(){return{parsers:[new j0.default],refiners:[new B0.default]}}Pe.createConfiguration=ml});var $s=h(xt=>{"use strict";Object.defineProperty(xt,"__esModule",{value:!0});xt.parseYear=xt.YEAR_PATTERN=xt.MONTH_DICTIONARY=xt.WEEKDAY_DICTIONARY=void 0;xt.WEEKDAY_DICTIONARY={domingo:0,dom:0,segunda:1,"segunda-feira":1,seg:1,ter\u00E7a:2,"ter\xE7a-feira":2,ter:2,quarta:3,"quarta-feira":3,qua:3,quinta:4,"quinta-feira":4,qui:4,sexta:5,"sexta-feira":5,sex:5,s\u00E1bado:6,sabado:6,sab:6};xt.MONTH_DICTIONARY={janeiro:1,jan:1,"jan.":1,fevereiro:2,fev:2,"fev.":2,mar\u00E7o:3,mar:3,"mar.":3,abril:4,abr:4,"abr.":4,maio:5,mai:5,"mai.":5,junho:6,jun:6,"jun.":6,julho:7,jul:7,"jul.":7,agosto:8,ago:8,"ago.":8,setembro:9,set:9,"set.":9,outubro:10,out:10,"out.":10,novembro:11,nov:11,"nov.":11,dezembro:12,dez:12,"dez.":12};xt.YEAR_PATTERN="[0-9]{1,4}(?![^\\s]\\d)(?:\\s*[a|d]\\.?\\s*c\\.?|\\s*a\\.?\\s*d\\.?)?";function K0(r){if(r.match(/^[0-9]{1,4}$/)){let e=parseInt(r);return e<100&&(e>50?e=e+1900:e=e+2e3),e}return r.match(/a\.?\s*c\.?/i)?(r=r.replace(/a\.?\s*c\.?/i,""),-parseInt(r)):parseInt(r)}xt.parseYear=K0});var $m=h(gl=>{"use strict";Object.defineProperty(gl,"__esModule",{value:!0});var Ym=$s(),V0=J(),Z0=R(),X0=Wr(),Q0=new RegExp(`(?:(?:\\,|\\(|\\\uFF08)\\s*)?(?:(este|esta|passado|pr[o\xF3]ximo)\\s*)?(${V0.matchAnyPattern(Ym.WEEKDAY_DICTIONARY)})(?:\\s*(?:\\,|\\)|\\\uFF09))?(?:\\s*(este|esta|passado|pr[\xF3o]ximo)\\s*semana)?(?=\\W|\\d|$)`,"i"),J0=1,eR=2,tR=3,yl=class extends Z0.AbstractParserWithWordBoundaryChecking{innerPattern(){return Q0}innerExtract(e,t){let n=t[eR].toLowerCase(),i=Ym.WEEKDAY_DICTIONARY[n];if(i===void 0)return null;let s=t[J0],a=t[tR],o=s||a||"";o=o.toLowerCase();let u=null;o=="passado"?u="this":o=="pr\xF3ximo"||o=="proximo"?u="next":o=="este"&&(u="this");let l=X0.toDayJSWeekday(e.refDate,i,u);return e.createParsingComponents().assign("weekday",i).imply("day",l.date()).imply("month",l.month()+1).imply("year",l.year())}};gl.default=yl});var jm=h(Tl=>{"use strict";Object.defineProperty(Tl,"__esModule",{value:!0});var rR=Fr(),_l=class extends rR.AbstractTimeExpressionParser{primaryPrefix(){return"(?:(?:ao?|\xE0s?|das|da|de|do)\\s*)?"}followingPhase(){return"\\s*(?:\\-|\\\u2013|\\~|\\\u301C|a(?:o)?|\\?)\\s*"}};Tl.default=_l});var Bm=h(li=>{"use strict";var nR=li&&li.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(li,"__esModule",{value:!0});var iR=nR(Bt()),bl=class extends iR.default{patternBetween(){return new RegExp("^\\s*(?:,|\xE0)?\\s*$")}};li.default=bl});var Gm=h(ci=>{"use strict";var sR=ci&&ci.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ci,"__esModule",{value:!0});var aR=sR(kt()),vl=class extends aR.default{patternBetween(){return/^\s*(?:-)\s*$/i}};ci.default=vl});var Xm=h(Rl=>{"use strict";Object.defineProperty(Rl,"__esModule",{value:!0});var oR=Se(),Vm=$s(),Zm=$s(),uR=J(),lR=R(),cR=new RegExp(`([0-9]{1,2})(?:\xBA|\xAA|\xB0)?(?:\\s*(?:desde|de|\\-|\\\u2013|ao?|\\s)\\s*([0-9]{1,2})(?:\xBA|\xAA|\xB0)?)?\\s*(?:de)?\\s*(?:-|/|\\s*(?:de|,)?\\s*)(${uR.matchAnyPattern(Vm.MONTH_DICTIONARY)})(?:\\s*(?:de|,)?\\s*(${Zm.YEAR_PATTERN}))?(?=\\W|$)`,"i"),Hm=1,zm=2,dR=3,Km=4,El=class extends lR.AbstractParserWithWordBoundaryChecking{innerPattern(){return cR}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=Vm.MONTH_DICTIONARY[t[dR].toLowerCase()],s=parseInt(t[Hm]);if(s>31)return t.index=t.index+t[Hm].length,null;if(n.start.assign("month",i),n.start.assign("day",s),t[Km]){let a=Zm.parseYear(t[Km]);n.start.assign("year",a)}else{let a=oR.findYearClosestToRef(e.refDate,s,i);n.start.imply("year",a)}if(t[zm]){let a=parseInt(t[zm]);n.end=n.start.clone(),n.end.assign("day",a)}return n}};Rl.default=El});var Qm=h(Kt=>{"use strict";var fR=Kt&&Kt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),pR=Kt&&Kt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),hR=Kt&&Kt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&fR(e,r,t);return pR(e,r),e};Object.defineProperty(Kt,"__esModule",{value:!0});var mR=R(),js=hR(zt()),wl=class extends mR.AbstractParserWithWordBoundaryChecking{innerPattern(e){return/(agora|hoje|amanha|amanhã|ontem)(?=\W|$)/i}innerExtract(e,t){let n=t[0].toLowerCase(),i=e.createParsingComponents();switch(n){case"agora":return js.now(e.reference);case"hoje":return js.today(e.reference);case"amanha":case"amanh\xE3":return js.tomorrow(e.reference);case"ontem":return js.yesterday(e.reference)}return i}};Kt.default=wl});var Jm=h(di=>{"use strict";var yR=di&&di.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(di,"__esModule",{value:!0});var Bs=Ee(),gR=R(),_R=it(),TR=yR(K()),Ml=class extends gR.AbstractParserWithWordBoundaryChecking{innerPattern(){return/(?:esta\s*)?(manha|manhã|tarde|meia-noite|meio-dia|noite)(?=\W|$)/i}innerExtract(e,t){let n=TR.default(e.refDate),i=e.createParsingComponents();switch(t[1].toLowerCase()){case"tarde":i.imply("meridiem",Bs.Meridiem.PM),i.imply("hour",15);break;case"noite":i.imply("meridiem",Bs.Meridiem.PM),i.imply("hour",22);break;case"manha":case"manh\xE3":i.imply("meridiem",Bs.Meridiem.AM),i.imply("hour",6);break;case"meia-noite":_R.assignTheNextDay(i,n),i.imply("hour",0),i.imply("minute",0),i.imply("second",0);break;case"meio-dia":i.imply("meridiem",Bs.Meridiem.AM),i.imply("hour",12);break}return i}};di.default=Ml});var ry=h(Oe=>{"use strict";var vr=Oe&&Oe.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Oe,"__esModule",{value:!0});Oe.createConfiguration=Oe.createCasualConfiguration=Oe.parseDate=Oe.parse=Oe.strict=Oe.casual=void 0;var bR=Gt(),ey=yt(),vR=vr(Lr()),ER=vr($m()),RR=vr(jm()),wR=vr(Bm()),MR=vr(Gm()),DR=vr(Xm()),PR=vr(Qm()),OR=vr(Jm());Oe.casual=new ey.Chrono(ty());Oe.strict=new ey.Chrono(Dl(!0));function AR(r,e,t){return Oe.casual.parse(r,e,t)}Oe.parse=AR;function kR(r,e,t){return Oe.casual.parseDate(r,e,t)}Oe.parseDate=kR;function ty(r=!0){let e=Dl(!1,r);return e.parsers.push(new PR.default),e.parsers.push(new OR.default),e}Oe.createCasualConfiguration=ty;function Dl(r=!0,e=!0){return bR.includeCommonConfiguration({parsers:[new vR.default(e),new ER.default,new RR.default,new DR.default],refiners:[new wR.default,new MR.default]},r)}Oe.createConfiguration=Dl});var ny=h(fi=>{"use strict";var NR=fi&&fi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(fi,"__esModule",{value:!0});var xR=NR(kt()),Pl=class extends xR.default{patternBetween(){return/^\s*(tot|-)\s*$/i}};fi.default=Pl});var iy=h(pi=>{"use strict";var CR=pi&&pi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(pi,"__esModule",{value:!0});var SR=CR(Bt()),Ol=class extends SR.default{patternBetween(){return new RegExp("^\\s*(om|na|voor|in de|,|-)?\\s*$")}};pi.default=Ol});var sy=h(Vt=>{"use strict";var IR=Vt&&Vt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),UR=Vt&&Vt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),FR=Vt&&Vt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&IR(e,r,t);return UR(e,r),e};Object.defineProperty(Vt,"__esModule",{value:!0});var qR=R(),Gs=FR(zt()),Al=class extends qR.AbstractParserWithWordBoundaryChecking{innerPattern(e){return/(nu|vandaag|morgen|morgend|gisteren)(?=\W|$)/i}innerExtract(e,t){let n=t[0].toLowerCase(),i=e.createParsingComponents();switch(n){case"nu":return Gs.now(e.reference);case"vandaag":return Gs.today(e.reference);case"morgen":case"morgend":return Gs.tomorrow(e.reference);case"gisteren":return Gs.yesterday(e.reference)}return i}};Vt.default=Al});var ay=h(hi=>{"use strict";var WR=hi&&hi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(hi,"__esModule",{value:!0});var Hs=Ee(),LR=R(),YR=WR(K()),$R=it(),jR=1,BR=2,kl=class extends LR.AbstractParserWithWordBoundaryChecking{innerPattern(){return/(deze)?\s*(namiddag|avond|middernacht|ochtend|middag|'s middags|'s avonds|'s ochtends)(?=\W|$)/i}innerExtract(e,t){let n=YR.default(e.refDate),i=e.createParsingComponents();switch(t[jR]==="deze"&&(i.assign("day",e.refDate.getDate()),i.assign("month",e.refDate.getMonth()+1),i.assign("year",e.refDate.getFullYear())),t[BR].toLowerCase()){case"namiddag":case"'s namiddags":i.imply("meridiem",Hs.Meridiem.PM),i.imply("hour",15);break;case"avond":case"'s avonds'":i.imply("meridiem",Hs.Meridiem.PM),i.imply("hour",20);break;case"middernacht":$R.assignTheNextDay(i,n),i.imply("hour",0),i.imply("minute",0),i.imply("second",0);break;case"ochtend":case"'s ochtends":i.imply("meridiem",Hs.Meridiem.AM),i.imply("hour",6);break;case"middag":case"'s middags":i.imply("meridiem",Hs.Meridiem.AM),i.imply("hour",12);break}return i}};hi.default=kl});var Qe=h(j=>{"use strict";Object.defineProperty(j,"__esModule",{value:!0});j.parseTimeUnits=j.TIME_UNITS_PATTERN=j.parseYear=j.YEAR_PATTERN=j.parseOrdinalNumberPattern=j.ORDINAL_NUMBER_PATTERN=j.parseNumberPattern=j.NUMBER_PATTERN=j.TIME_UNIT_DICTIONARY=j.ORDINAL_WORD_DICTIONARY=j.INTEGER_WORD_DICTIONARY=j.MONTH_DICTIONARY=j.WEEKDAY_DICTIONARY=void 0;var zs=J(),GR=Se();j.WEEKDAY_DICTIONARY={zondag:0,zon:0,"zon.":0,zo:0,"zo.":0,maandag:1,ma:1,"ma.":1,dinsdag:2,din:2,"din.":2,di:2,"di.":2,woensdag:3,woe:3,"woe.":3,wo:3,"wo.":3,donderdag:4,dond:4,"dond.":4,do:4,"do.":4,vrijdag:5,vrij:5,"vrij.":5,vr:5,"vr.":5,zaterdag:6,zat:6,"zat.":6,za:6,"za.":6};j.MONTH_DICTIONARY={januari:1,jan:1,"jan.":1,februari:2,feb:2,"feb.":2,maart:3,mar:3,"mar.":3,april:4,apr:4,"apr.":4,mei:5,juni:6,jun:6,"jun.":6,juli:7,jul:7,"jul.":7,augustus:8,aug:8,"aug.":8,september:9,sep:9,"sep.":9,sept:9,"sept.":9,oktober:10,okt:10,"okt.":10,november:11,nov:11,"nov.":11,december:12,dec:12,"dec.":12};j.INTEGER_WORD_DICTIONARY={een:1,twee:2,drie:3,vier:4,vijf:5,zes:6,zeven:7,acht:8,negen:9,tien:10,elf:11,twaalf:12};j.ORDINAL_WORD_DICTIONARY={eerste:1,tweede:2,derde:3,vierde:4,vijfde:5,zesde:6,zevende:7,achtste:8,negende:9,tiende:10,elfde:11,twaalfde:12,dertiende:13,veertiende:14,vijftiende:15,zestiende:16,zeventiende:17,achttiende:18,negentiende:19,twintigste:20,eenentwintigste:21,twee\u00EBntwintigste:22,drieentwintigste:23,vierentwintigste:24,vijfentwintigste:25,zesentwintigste:26,zevenentwintigste:27,achtentwintig:28,negenentwintig:29,dertigste:30,eenendertigste:31};j.TIME_UNIT_DICTIONARY={sec:"second",second:"second",seconden:"second",min:"minute",mins:"minute",minute:"minute",minuut:"minute",minuten:"minute",minuutje:"minute",h:"hour",hr:"hour",hrs:"hour",uur:"hour",u:"hour",uren:"hour",dag:"d",dagen:"d",week:"week",weken:"week",maand:"month",maanden:"month",jaar:"year",jr:"year",jaren:"year"};j.NUMBER_PATTERN=`(?:${zs.matchAnyPattern(j.INTEGER_WORD_DICTIONARY)}|[0-9]+|[0-9]+[\\.,][0-9]+|halve?|half|paar)`;function uy(r){let e=r.toLowerCase();return j.INTEGER_WORD_DICTIONARY[e]!==void 0?j.INTEGER_WORD_DICTIONARY[e]:e==="paar"?2:e==="half"||e.match(/halve?/)?.5:parseFloat(e.replace(",","."))}j.parseNumberPattern=uy;j.ORDINAL_NUMBER_PATTERN=`(?:${zs.matchAnyPattern(j.ORDINAL_WORD_DICTIONARY)}|[0-9]{1,2}(?:ste|de)?)`;function HR(r){let e=r.toLowerCase();return j.ORDINAL_WORD_DICTIONARY[e]!==void 0?j.ORDINAL_WORD_DICTIONARY[e]:(e=e.replace(/(?:ste|de)$/i,""),parseInt(e))}j.parseOrdinalNumberPattern=HR;j.YEAR_PATTERN="(?:[1-9][0-9]{0,3}\\s*(?:voor Christus|na Christus)|[1-2][0-9]{3}|[5-9][0-9])";function zR(r){if(/voor Christus/i.test(r))return r=r.replace(/voor Christus/i,""),-parseInt(r);if(/na Christus/i.test(r))return r=r.replace(/na Christus/i,""),parseInt(r);let e=parseInt(r);return GR.findMostLikelyADYear(e)}j.parseYear=zR;var ly=`(${j.NUMBER_PATTERN})\\s{0,5}(${zs.matchAnyPattern(j.TIME_UNIT_DICTIONARY)})\\s{0,5}`,oy=new RegExp(ly,"i");j.TIME_UNITS_PATTERN=zs.repeatedTimeunitPattern("(?:(?:binnen|in)\\s*)?",ly);function KR(r){let e={},t=r,n=oy.exec(t);for(;n;)VR(e,n),t=t.substring(n[0].length),n=oy.exec(t);return e}j.parseTimeUnits=KR;function VR(r,e){let t=uy(e[1]),n=j.TIME_UNIT_DICTIONARY[e[2].toLowerCase()];r[n]=t}});var dy=h(xl=>{"use strict";Object.defineProperty(xl,"__esModule",{value:!0});var cy=Qe(),ZR=he(),XR=R(),Nl=class extends XR.AbstractParserWithWordBoundaryChecking{innerPattern(){return new RegExp("(?:binnen|in|binnen de|voor)\\s*("+cy.TIME_UNITS_PATTERN+")(?=\\W|$)","i")}innerExtract(e,t){let n=cy.parseTimeUnits(t[1]);return ZR.ParsingComponents.createRelativeFromReference(e.reference,n)}};xl.default=Nl});var py=h(Sl=>{"use strict";Object.defineProperty(Sl,"__esModule",{value:!0});var fy=Qe(),QR=J(),JR=R(),ew=Wr(),tw=new RegExp(`(?:(?:\\,|\\(|\\\uFF08)\\s*)?(?:op\\s*?)?(?:(deze|vorige|volgende)\\s*(?:week\\s*)?)?(${QR.matchAnyPattern(fy.WEEKDAY_DICTIONARY)})(?=\\W|$)`,"i"),rw=1,nw=2,iw=3,Cl=class extends JR.AbstractParserWithWordBoundaryChecking{innerPattern(){return tw}innerExtract(e,t){let n=t[nw].toLowerCase(),i=fy.WEEKDAY_DICTIONARY[n],s=t[rw],a=t[iw],o=s||a;o=o||"",o=o.toLowerCase();let u=null;o=="vorige"?u="last":o=="volgende"?u="next":o=="deze"&&(u="this");let l=ew.toDayJSWeekday(e.refDate,i,u);return e.createParsingComponents().assign("weekday",i).imply("day",l.date()).imply("month",l.month()+1).imply("year",l.year())}};Sl.default=Cl});var Ty=h(Ul=>{"use strict";Object.defineProperty(Ul,"__esModule",{value:!0});var sw=Se(),gy=Qe(),Ks=Qe(),_y=Qe(),aw=J(),ow=R(),uw=new RegExp(`(?:on\\s*?)?(${Ks.ORDINAL_NUMBER_PATTERN})(?:\\s*(?:tot|\\-|\\\u2013|until|through|till|\\s)\\s*(${Ks.ORDINAL_NUMBER_PATTERN}))?(?:-|/|\\s*(?:of)?\\s*)(`+aw.matchAnyPattern(gy.MONTH_DICTIONARY)+`)(?:(?:-|/|,?\\s*)(${_y.YEAR_PATTERN}(?![^\\s]\\d)))?(?=\\W|$)`,"i"),lw=3,hy=1,my=2,yy=4,Il=class extends ow.AbstractParserWithWordBoundaryChecking{innerPattern(){return uw}innerExtract(e,t){let n=gy.MONTH_DICTIONARY[t[lw].toLowerCase()],i=Ks.parseOrdinalNumberPattern(t[hy]);if(i>31)return t.index=t.index+t[hy].length,null;let s=e.createParsingComponents({day:i,month:n});if(t[yy]){let u=_y.parseYear(t[yy]);s.assign("year",u)}else{let u=sw.findYearClosestToRef(e.refDate,i,n);s.imply("year",u)}if(!t[my])return s;let a=Ks.parseOrdinalNumberPattern(t[my]),o=e.createParsingResult(t.index,t[0]);return o.start=s,o.end=s.clone(),o.end.assign("day",a),o}};Ul.default=Il});var Ry=h(ql=>{"use strict";Object.defineProperty(ql,"__esModule",{value:!0});var vy=Qe(),cw=Se(),dw=J(),Ey=Qe(),fw=R(),pw=new RegExp(`(${dw.matchAnyPattern(vy.MONTH_DICTIONARY)})\\s*(?:[,-]?\\s*(${Ey.YEAR_PATTERN})?)?(?=[^\\s\\w]|\\s+[^0-9]|\\s+$|$)`,"i"),hw=1,by=2,Fl=class extends fw.AbstractParserWithWordBoundaryChecking{innerPattern(){return pw}innerExtract(e,t){let n=e.createParsingComponents();n.imply("day",1);let i=t[hw],s=vy.MONTH_DICTIONARY[i.toLowerCase()];if(n.assign("month",s),t[by]){let a=Ey.parseYear(t[by]);n.assign("year",a)}else{let a=cw.findYearClosestToRef(e.refDate,1,s);n.imply("year",a)}return n}};ql.default=Fl});var wy=h(Ll=>{"use strict";Object.defineProperty(Ll,"__esModule",{value:!0});var mw=R(),yw=new RegExp("([0-9]|0[1-9]|1[012])/([0-9]{4})","i"),gw=1,_w=2,Wl=class extends mw.AbstractParserWithWordBoundaryChecking{innerPattern(){return yw}innerExtract(e,t){let n=parseInt(t[_w]),i=parseInt(t[gw]);return e.createParsingComponents().imply("day",1).assign("month",i).assign("year",n)}};Ll.default=Wl});var My=h($l=>{"use strict";Object.defineProperty($l,"__esModule",{value:!0});var Tw=Fr(),Yl=class extends Tw.AbstractTimeExpressionParser{primaryPrefix(){return"(?:(?:om)\\s*)?"}followingPhase(){return"\\s*(?:\\-|\\\u2013|\\~|\\\u301C|om|\\?)\\s*"}primarySuffix(){return"(?:\\s*(?:uur))?(?!/)(?=\\W|$)"}extractPrimaryTimeComponents(e,t){return t[0].match(/^\s*\d{4}\s*$/)?null:super.extractPrimaryTimeComponents(e,t)}};$l.default=Yl});var Oy=h(Bl=>{"use strict";Object.defineProperty(Bl,"__esModule",{value:!0});var Py=Qe(),bw=J(),vw=R(),Ew=new RegExp(`([0-9]{4})[\\.\\/\\s](?:(${bw.matchAnyPattern(Py.MONTH_DICTIONARY)})|([0-9]{1,2}))[\\.\\/\\s]([0-9]{1,2})(?=\\W|$)`,"i"),Rw=1,ww=2,Dy=3,Mw=4,jl=class extends vw.AbstractParserWithWordBoundaryChecking{innerPattern(){return Ew}innerExtract(e,t){let n=t[Dy]?parseInt(t[Dy]):Py.MONTH_DICTIONARY[t[ww].toLowerCase()];if(n<1||n>12)return null;let i=parseInt(t[Rw]);return{day:parseInt(t[Mw]),month:n,year:i}}};Bl.default=jl});var Ay=h(mi=>{"use strict";var Dw=mi&&mi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(mi,"__esModule",{value:!0});var Pw=R(),Vs=Ee(),Gl=it(),Ow=Dw(K()),Aw=1,kw=2,Hl=class extends Pw.AbstractParserWithWordBoundaryChecking{innerPattern(e){return/(gisteren|morgen|van)(ochtend|middag|namiddag|avond|nacht)(?=\W|$)/i}innerExtract(e,t){let n=t[Aw].toLowerCase(),i=t[kw].toLowerCase(),s=e.createParsingComponents(),a=Ow.default(e.refDate);switch(n){case"gisteren":Gl.assignSimilarDate(s,a.add(-1,"day"));break;case"van":Gl.assignSimilarDate(s,a);break;case"morgen":Gl.assignTheNextDay(s,a);break}switch(i){case"ochtend":s.imply("meridiem",Vs.Meridiem.AM),s.imply("hour",6);break;case"middag":s.imply("meridiem",Vs.Meridiem.AM),s.imply("hour",12);break;case"namiddag":s.imply("meridiem",Vs.Meridiem.PM),s.imply("hour",15);break;case"avond":s.imply("meridiem",Vs.Meridiem.PM),s.imply("hour",20);break}return s}};mi.default=Hl});var Ny=h(Kl=>{"use strict";Object.defineProperty(Kl,"__esModule",{value:!0});var ky=Qe(),Nw=he(),xw=R(),Cw=st(),Sw=new RegExp(`(deze|vorige|afgelopen|komende|over|\\+|-)\\s*(${ky.TIME_UNITS_PATTERN})(?=\\W|$)`,"i"),zl=class extends xw.AbstractParserWithWordBoundaryChecking{innerPattern(){return Sw}innerExtract(e,t){let n=t[1].toLowerCase(),i=ky.parseTimeUnits(t[2]);switch(n){case"vorige":case"afgelopen":case"-":i=Cw.reverseTimeUnits(i);break}return Nw.ParsingComponents.createRelativeFromReference(e.reference,i)}};Kl.default=zl});var Sy=h(yi=>{"use strict";var Iw=yi&&yi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(yi,"__esModule",{value:!0});var Cy=Qe(),xy=he(),Uw=Iw(K()),Fw=R(),qw=J(),Ww=new RegExp(`(dit|deze|komende|volgend|volgende|afgelopen|vorige)\\s*(${qw.matchAnyPattern(Cy.TIME_UNIT_DICTIONARY)})(?=\\s*)(?=\\W|$)`,"i"),Lw=1,Yw=2,Vl=class extends Fw.AbstractParserWithWordBoundaryChecking{innerPattern(){return Ww}innerExtract(e,t){let n=t[Lw].toLowerCase(),i=t[Yw].toLowerCase(),s=Cy.TIME_UNIT_DICTIONARY[i];if(n=="volgend"||n=="volgende"||n=="komende"){let u={};return u[s]=1,xy.ParsingComponents.createRelativeFromReference(e.reference,u)}if(n=="afgelopen"||n=="vorige"){let u={};return u[s]=-1,xy.ParsingComponents.createRelativeFromReference(e.reference,u)}let a=e.createParsingComponents(),o=Uw.default(e.reference.instant);return i.match(/week/i)?(o=o.add(-o.get("d"),"d"),a.imply("day",o.date()),a.imply("month",o.month()+1),a.imply("year",o.year())):i.match(/maand/i)?(o=o.add(-o.date()+1,"d"),a.imply("day",o.date()),a.assign("year",o.year()),a.assign("month",o.month()+1)):i.match(/jaar/i)&&(o=o.add(-o.date()+1,"d"),o=o.add(-o.month(),"month"),a.imply("day",o.date()),a.imply("month",o.month()+1),a.assign("year",o.year())),a}};yi.default=Vl});var Iy=h(Ql=>{"use strict";Object.defineProperty(Ql,"__esModule",{value:!0});var Xl=Qe(),$w=he(),jw=R(),Bw=st(),Gw=new RegExp("("+Xl.TIME_UNITS_PATTERN+")(?:geleden|voor|eerder)(?=(?:\\W|$))","i"),Hw=new RegExp("("+Xl.TIME_UNITS_PATTERN+")geleden(?=(?:\\W|$))","i"),Zl=class extends jw.AbstractParserWithWordBoundaryChecking{constructor(e){super(),this.strictMode=e}innerPattern(){return this.strictMode?Hw:Gw}innerExtract(e,t){let n=Xl.parseTimeUnits(t[1]),i=Bw.reverseTimeUnits(n);return $w.ParsingComponents.createRelativeFromReference(e.reference,i)}};Ql.default=Zl});var Uy=h(tc=>{"use strict";Object.defineProperty(tc,"__esModule",{value:!0});var ec=Qe(),zw=he(),Kw=R(),Vw=new RegExp("("+ec.TIME_UNITS_PATTERN+")(later|na|vanaf nu|voortaan|vooruit|uit)(?=(?:\\W|$))","i"),Zw=new RegExp("("+ec.TIME_UNITS_PATTERN+")(later|vanaf nu)(?=(?:\\W|$))","i"),Xw=1,Jl=class extends Kw.AbstractParserWithWordBoundaryChecking{constructor(e){super(),this.strictMode=e}innerPattern(){return this.strictMode?Zw:Vw}innerExtract(e,t){let n=ec.parseTimeUnits(t[Xw]);return zw.ParsingComponents.createRelativeFromReference(e.reference,n)}};tc.default=Jl});var Ly=h(Ae=>{"use strict";var Ue=Ae&&Ae.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ae,"__esModule",{value:!0});Ae.createConfiguration=Ae.createCasualConfiguration=Ae.parseDate=Ae.parse=Ae.strict=Ae.casual=void 0;var Qw=Gt(),Fy=yt(),Jw=Ue(ny()),eM=Ue(iy()),tM=Ue(sy()),rM=Ue(ay()),nM=Ue(Lr()),iM=Ue(dy()),sM=Ue(py()),aM=Ue(Ty()),qy=Ue(Ry()),oM=Ue(wy()),uM=Ue(My()),lM=Ue(Oy()),cM=Ue(Ay()),dM=Ue(Ny()),fM=Ue(Sy()),pM=Ue(Iy()),hM=Ue(Uy());Ae.casual=new Fy.Chrono(Wy());Ae.strict=new Fy.Chrono(rc(!0));function mM(r,e,t){return Ae.casual.parse(r,e,t)}Ae.parse=mM;function yM(r,e,t){return Ae.casual.parseDate(r,e,t)}Ae.parseDate=yM;function Wy(r=!0){let e=rc(!1,r);return e.parsers.unshift(new tM.default),e.parsers.unshift(new rM.default),e.parsers.unshift(new cM.default),e.parsers.unshift(new qy.default),e.parsers.unshift(new fM.default),e.parsers.unshift(new dM.default),e}Ae.createCasualConfiguration=Wy;function rc(r=!0,e=!0){return Qw.includeCommonConfiguration({parsers:[new nM.default(e),new iM.default,new aM.default,new qy.default,new sM.default,new lM.default,new oM.default,new uM.default(r),new pM.default(r),new hM.default(r)],refiners:[new eM.default,new Jw.default]},r)}Ae.createConfiguration=rc});var By=h(gi=>{"use strict";var gM=gi&&gi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(gi,"__esModule",{value:!0});var _M=gM(K()),TM=R(),bM=1,Yy=2,vM=3,$y=4,jy=5,EM=6,nc=class extends TM.AbstractParserWithWordBoundaryChecking{innerPattern(e){return new RegExp("(\u800C\u5BB6|\u7ACB(?:\u523B|\u5373)|\u5373\u523B)|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u5F8C|\u5927\u5F8C|\u807D|\u6628|\u5C0B|\u7434)(\u65E9|\u671D|\u665A)|(\u4E0A(?:\u5348|\u665D)|\u671D(?:\u65E9)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348|\u665D)|\u664F(?:\u665D)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668))|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u5F8C|\u5927\u5F8C|\u807D|\u6628|\u5C0B|\u7434)(?:\u65E5|\u5929)(?:[\\s|,|\uFF0C]*)(?:(\u4E0A(?:\u5348|\u665D)|\u671D(?:\u65E9)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348|\u665D)|\u664F(?:\u665D)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668)))?","i")}innerExtract(e,t){let n=t.index,i=e.createParsingResult(n,t[0]),s=_M.default(e.refDate),a=s;if(t[bM])i.start.imply("hour",s.hour()),i.start.imply("minute",s.minute()),i.start.imply("second",s.second()),i.start.imply("millisecond",s.millisecond());else if(t[Yy]){let o=t[Yy],u=t[vM];o=="\u660E"||o=="\u807D"?s.hour()>1&&(a=a.add(1,"day")):o=="\u6628"||o=="\u5C0B"||o=="\u7434"?a=a.add(-1,"day"):o=="\u524D"?a=a.add(-2,"day"):o=="\u5927\u524D"?a=a.add(-3,"day"):o=="\u5F8C"?a=a.add(2,"day"):o=="\u5927\u5F8C"&&(a=a.add(3,"day")),u=="\u65E9"||u=="\u671D"?i.start.imply("hour",6):u=="\u665A"&&(i.start.imply("hour",22),i.start.imply("meridiem",1))}else if(t[$y]){let u=t[$y][0];u=="\u65E9"||u=="\u671D"||u=="\u4E0A"?i.start.imply("hour",6):u=="\u4E0B"||u=="\u664F"?(i.start.imply("hour",15),i.start.imply("meridiem",1)):u=="\u4E2D"?(i.start.imply("hour",12),i.start.imply("meridiem",1)):u=="\u591C"||u=="\u665A"?(i.start.imply("hour",22),i.start.imply("meridiem",1)):u=="\u51CC"&&i.start.imply("hour",0)}else if(t[jy]){let o=t[jy];o=="\u660E"||o=="\u807D"?s.hour()>1&&(a=a.add(1,"day")):o=="\u6628"||o=="\u5C0B"||o=="\u7434"?a=a.add(-1,"day"):o=="\u524D"?a=a.add(-2,"day"):o=="\u5927\u524D"?a=a.add(-3,"day"):o=="\u5F8C"?a=a.add(2,"day"):o=="\u5927\u5F8C"&&(a=a.add(3,"day"));let u=t[EM];if(u){let l=u[0];l=="\u65E9"||l=="\u671D"||l=="\u4E0A"?i.start.imply("hour",6):l=="\u4E0B"||l=="\u664F"?(i.start.imply("hour",15),i.start.imply("meridiem",1)):l=="\u4E2D"?(i.start.imply("hour",12),i.start.imply("meridiem",1)):l=="\u591C"||l=="\u665A"?(i.start.imply("hour",22),i.start.imply("meridiem",1)):l=="\u51CC"&&i.start.imply("hour",0)}}return i.start.assign("day",a.date()),i.start.assign("month",a.month()+1),i.start.assign("year",a.year()),i}};gi.default=nc});var yn=h(He=>{"use strict";Object.defineProperty(He,"__esModule",{value:!0});He.zhStringToYear=He.zhStringToNumber=He.WEEKDAY_OFFSET=He.NUMBER=void 0;He.NUMBER={\u96F6:0,\u4E00:1,\u4E8C:2,\u5169:2,\u4E09:3,\u56DB:4,\u4E94:5,\u516D:6,\u4E03:7,\u516B:8,\u4E5D:9,\u5341:10,\u5EFF:20,\u5345:30};He.WEEKDAY_OFFSET={\u5929:0,\u65E5:0,\u4E00:1,\u4E8C:2,\u4E09:3,\u56DB:4,\u4E94:5,\u516D:6};function RM(r){let e=0;for(let t=0;t{"use strict";var MM=_i&&_i.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(_i,"__esModule",{value:!0});var DM=MM(K()),PM=R(),jr=yn(),ic=1,Gy=2,sc=3,ac=class extends PM.AbstractParserWithWordBoundaryChecking{innerPattern(){return new RegExp("(\\d{2,4}|["+Object.keys(jr.NUMBER).join("")+"]{4}|["+Object.keys(jr.NUMBER).join("")+"]{2})?(?:\\s*)(?:\u5E74)?(?:[\\s|,|\uFF0C]*)(\\d{1,2}|["+Object.keys(jr.NUMBER).join("")+"]{1,2})(?:\\s*)(?:\u6708)(?:\\s*)(\\d{1,2}|["+Object.keys(jr.NUMBER).join("")+"]{1,2})?(?:\\s*)(?:\u65E5|\u865F)?")}innerExtract(e,t){let n=DM.default(e.refDate),i=e.createParsingResult(t.index,t[0]),s=parseInt(t[Gy]);if(isNaN(s)&&(s=jr.zhStringToNumber(t[Gy])),i.start.assign("month",s),t[sc]){let a=parseInt(t[sc]);isNaN(a)&&(a=jr.zhStringToNumber(t[sc])),i.start.assign("day",a)}else i.start.imply("day",n.date());if(t[ic]){let a=parseInt(t[ic]);isNaN(a)&&(a=jr.zhStringToYear(t[ic])),i.start.assign("year",a)}else i.start.imply("year",n.year());return i}};_i.default=ac});var Ky=h(Ti=>{"use strict";var OM=Ti&&Ti.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ti,"__esModule",{value:!0});var AM=OM(K()),kM=R(),zy=yn(),NM=new RegExp("(\\d+|["+Object.keys(zy.NUMBER).join("")+"]+|\u534A|\u5E7E)(?:\\s*)(?:\u500B)?(\u79D2(?:\u9418)?|\u5206\u9418|\u5C0F\u6642|\u9418|\u65E5|\u5929|\u661F\u671F|\u79AE\u62DC|\u6708|\u5E74)(?:(?:\u4E4B|\u904E)?\u5F8C|(?:\u4E4B)?\u5167)","i"),oc=1,xM=2,uc=class extends kM.AbstractParserWithWordBoundaryChecking{innerPattern(){return NM}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=parseInt(t[oc]);if(isNaN(i)&&(i=zy.zhStringToNumber(t[oc])),isNaN(i)){let u=t[oc];if(u==="\u5E7E")i=3;else if(u==="\u534A")i=.5;else return null}let s=AM.default(e.refDate),o=t[xM][0];return o.match(/[日天星禮月年]/)?(o=="\u65E5"||o=="\u5929"?s=s.add(i,"d"):o=="\u661F"||o=="\u79AE"?s=s.add(i*7,"d"):o=="\u6708"?s=s.add(i,"month"):o=="\u5E74"&&(s=s.add(i,"year")),n.start.assign("year",s.year()),n.start.assign("month",s.month()+1),n.start.assign("day",s.date()),n):(o=="\u79D2"?s=s.add(i,"second"):o=="\u5206"?s=s.add(i,"minute"):(o=="\u5C0F"||o=="\u9418")&&(s=s.add(i,"hour")),n.start.imply("year",s.year()),n.start.imply("month",s.month()+1),n.start.imply("day",s.date()),n.start.assign("hour",s.hour()),n.start.assign("minute",s.minute()),n.start.assign("second",s.second()),n)}};Ti.default=uc});var Zy=h(bi=>{"use strict";var CM=bi&&bi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(bi,"__esModule",{value:!0});var SM=CM(K()),IM=R(),Vy=yn(),UM=new RegExp("(?\u4E0A|\u4ECA|\u4E0B|\u9019|\u5462)(?:\u500B)?(?:\u661F\u671F|\u79AE\u62DC|\u9031)(?"+Object.keys(Vy.WEEKDAY_OFFSET).join("|")+")"),lc=class extends IM.AbstractParserWithWordBoundaryChecking{innerPattern(){return UM}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=t.groups.weekday,s=Vy.WEEKDAY_OFFSET[i];if(s===void 0)return null;let a=null,o=t.groups.prefix;o=="\u4E0A"?a="last":o=="\u4E0B"?a="next":(o=="\u4ECA"||o=="\u9019"||o=="\u5462")&&(a="this");let u=SM.default(e.refDate),l=!1,c=u.day();return a=="last"||a=="past"?(u=u.day(s-7),l=!0):a=="next"?(u=u.day(s+7),l=!0):a=="this"?u=u.day(s):Math.abs(s-7-c){"use strict";var FM=vi&&vi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(vi,"__esModule",{value:!0});var qM=FM(K()),WM=R(),ut=yn(),LM=new RegExp("(?:\u7531|\u5F9E|\u81EA)?(?:(\u4ECA|\u660E|\u524D|\u5927\u524D|\u5F8C|\u5927\u5F8C|\u807D|\u6628|\u5C0B|\u7434)(\u65E9|\u671D|\u665A)|(\u4E0A(?:\u5348|\u665D)|\u671D(?:\u65E9)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348|\u665D)|\u664F(?:\u665D)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668))|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u5F8C|\u5927\u5F8C|\u807D|\u6628|\u5C0B|\u7434)(?:\u65E5|\u5929)(?:[\\s,\uFF0C]*)(?:(\u4E0A(?:\u5348|\u665D)|\u671D(?:\u65E9)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348|\u665D)|\u664F(?:\u665D)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668)))?)?(?:[\\s,\uFF0C]*)(?:(\\d+|["+Object.keys(ut.NUMBER).join("")+"]+)(?:\\s*)(?:\u9EDE|\u6642|:|\uFF1A)(?:\\s*)(\\d+|\u534A|\u6B63|\u6574|["+Object.keys(ut.NUMBER).join("")+"]+)?(?:\\s*)(?:\u5206|:|\uFF1A)?(?:\\s*)(\\d+|["+Object.keys(ut.NUMBER).join("")+"]+)?(?:\\s*)(?:\u79D2)?)(?:\\s*(A.M.|P.M.|AM?|PM?))?","i"),YM=new RegExp("(?:^\\s*(?:\u5230|\u81F3|\\-|\\\u2013|\\~|\\\u301C)\\s*)(?:(\u4ECA|\u660E|\u524D|\u5927\u524D|\u5F8C|\u5927\u5F8C|\u807D|\u6628|\u5C0B|\u7434)(\u65E9|\u671D|\u665A)|(\u4E0A(?:\u5348|\u665D)|\u671D(?:\u65E9)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348|\u665D)|\u664F(?:\u665D)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668))|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u5F8C|\u5927\u5F8C|\u807D|\u6628|\u5C0B|\u7434)(?:\u65E5|\u5929)(?:[\\s,\uFF0C]*)(?:(\u4E0A(?:\u5348|\u665D)|\u671D(?:\u65E9)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348|\u665D)|\u664F(?:\u665D)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668)))?)?(?:[\\s,\uFF0C]*)(?:(\\d+|["+Object.keys(ut.NUMBER).join("")+"]+)(?:\\s*)(?:\u9EDE|\u6642|:|\uFF1A)(?:\\s*)(\\d+|\u534A|\u6B63|\u6574|["+Object.keys(ut.NUMBER).join("")+"]+)?(?:\\s*)(?:\u5206|:|\uFF1A)?(?:\\s*)(\\d+|["+Object.keys(ut.NUMBER).join("")+"]+)?(?:\\s*)(?:\u79D2)?)(?:\\s*(A.M.|P.M.|AM?|PM?))?","i"),Zs=1,Xs=2,Qs=3,Js=4,ea=5,ta=6,ot=7,gn=8,ra=9,cc=class extends WM.AbstractParserWithWordBoundaryChecking{innerPattern(){return LM}innerExtract(e,t){if(t.index>0&&e.text[t.index-1].match(/\w/))return null;let n=qM.default(e.refDate),i=e.createParsingResult(t.index,t[0]),s=n.clone();if(t[Zs]){var a=t[Zs];a=="\u660E"||a=="\u807D"?n.hour()>1&&s.add(1,"day"):a=="\u6628"||a=="\u5C0B"||a=="\u7434"?s.add(-1,"day"):a=="\u524D"?s.add(-2,"day"):a=="\u5927\u524D"?s.add(-3,"day"):a=="\u5F8C"?s.add(2,"day"):a=="\u5927\u5F8C"&&s.add(3,"day"),i.start.assign("day",s.date()),i.start.assign("month",s.month()+1),i.start.assign("year",s.year())}else if(t[Js]){var o=t[Js];o=="\u660E"||o=="\u807D"?s.add(1,"day"):o=="\u6628"||o=="\u5C0B"||o=="\u7434"?s.add(-1,"day"):o=="\u524D"?s.add(-2,"day"):o=="\u5927\u524D"?s.add(-3,"day"):o=="\u5F8C"?s.add(2,"day"):o=="\u5927\u5F8C"&&s.add(3,"day"),i.start.assign("day",s.date()),i.start.assign("month",s.month()+1),i.start.assign("year",s.year())}else i.start.imply("day",s.date()),i.start.imply("month",s.month()+1),i.start.imply("year",s.year());let u=0,l=0,c=-1;if(t[gn]){var d=parseInt(t[gn]);if(isNaN(d)&&(d=ut.zhStringToNumber(t[gn])),d>=60)return null;i.start.assign("second",d)}if(u=parseInt(t[ta]),isNaN(u)&&(u=ut.zhStringToNumber(t[ta])),t[ot]?t[ot]=="\u534A"?l=30:t[ot]=="\u6B63"||t[ot]=="\u6574"?l=0:(l=parseInt(t[ot]),isNaN(l)&&(l=ut.zhStringToNumber(t[ot]))):u>100&&(l=u%100,u=Math.floor(u/100)),l>=60||u>24)return null;if(u>=12&&(c=1),t[ra]){if(u>12)return null;var f=t[ra][0].toLowerCase();f=="a"&&(c=0,u==12&&(u=0)),f=="p"&&(c=1,u!=12&&(u+=12))}else if(t[Xs]){var p=t[Xs],y=p[0];y=="\u671D"||y=="\u65E9"?(c=0,u==12&&(u=0)):y=="\u665A"&&(c=1,u!=12&&(u+=12))}else if(t[Qs]){var m=t[Qs],g=m[0];g=="\u4E0A"||g=="\u671D"||g=="\u65E9"||g=="\u51CC"?(c=0,u==12&&(u=0)):(g=="\u4E0B"||g=="\u664F"||g=="\u665A")&&(c=1,u!=12&&(u+=12))}else if(t[ea]){var A=t[ea],C=A[0];C=="\u4E0A"||C=="\u671D"||C=="\u65E9"||C=="\u51CC"?(c=0,u==12&&(u=0)):(C=="\u4E0B"||C=="\u664F"||C=="\u665A")&&(c=1,u!=12&&(u+=12))}if(i.start.assign("hour",u),i.start.assign("minute",l),c>=0?i.start.assign("meridiem",c):u<12?i.start.imply("meridiem",0):i.start.imply("meridiem",1),t=YM.exec(e.text.substring(i.index+i.text.length)),!t)return i.text.match(/^\d+$/)?null:i;let x=s.clone();if(i.end=e.createParsingComponents(),t[Zs]){var a=t[Zs];a=="\u660E"||a=="\u807D"?n.hour()>1&&x.add(1,"day"):a=="\u6628"||a=="\u5C0B"||a=="\u7434"?x.add(-1,"day"):a=="\u524D"?x.add(-2,"day"):a=="\u5927\u524D"?x.add(-3,"day"):a=="\u5F8C"?x.add(2,"day"):a=="\u5927\u5F8C"&&x.add(3,"day"),i.end.assign("day",x.date()),i.end.assign("month",x.month()+1),i.end.assign("year",x.year())}else if(t[Js]){var o=t[Js];o=="\u660E"||o=="\u807D"?x.add(1,"day"):o=="\u6628"||o=="\u5C0B"||o=="\u7434"?x.add(-1,"day"):o=="\u524D"?x.add(-2,"day"):o=="\u5927\u524D"?x.add(-3,"day"):o=="\u5F8C"?x.add(2,"day"):o=="\u5927\u5F8C"&&x.add(3,"day"),i.end.assign("day",x.date()),i.end.assign("month",x.month()+1),i.end.assign("year",x.year())}else i.end.imply("day",x.date()),i.end.imply("month",x.month()+1),i.end.imply("year",x.year());if(u=0,l=0,c=-1,t[gn]){var d=parseInt(t[gn]);if(isNaN(d)&&(d=ut.zhStringToNumber(t[gn])),d>=60)return null;i.end.assign("second",d)}if(u=parseInt(t[ta]),isNaN(u)&&(u=ut.zhStringToNumber(t[ta])),t[ot]?t[ot]=="\u534A"?l=30:t[ot]=="\u6B63"||t[ot]=="\u6574"?l=0:(l=parseInt(t[ot]),isNaN(l)&&(l=ut.zhStringToNumber(t[ot]))):u>100&&(l=u%100,u=Math.floor(u/100)),l>=60||u>24)return null;if(u>=12&&(c=1),t[ra]){if(u>12)return null;var f=t[ra][0].toLowerCase();f=="a"&&(c=0,u==12&&(u=0)),f=="p"&&(c=1,u!=12&&(u+=12)),i.start.isCertain("meridiem")||(c==0?(i.start.imply("meridiem",0),i.start.get("hour")==12&&i.start.assign("hour",0)):(i.start.imply("meridiem",1),i.start.get("hour")!=12&&i.start.assign("hour",i.start.get("hour")+12)))}else if(t[Xs]){var p=t[Xs],y=p[0];y=="\u671D"||y=="\u65E9"?(c=0,u==12&&(u=0)):y=="\u665A"&&(c=1,u!=12&&(u+=12))}else if(t[Qs]){var m=t[Qs],g=m[0];g=="\u4E0A"||g=="\u671D"||g=="\u65E9"||g=="\u51CC"?(c=0,u==12&&(u=0)):(g=="\u4E0B"||g=="\u664F"||g=="\u665A")&&(c=1,u!=12&&(u+=12))}else if(t[ea]){var A=t[ea],C=A[0];C=="\u4E0A"||C=="\u671D"||C=="\u65E9"||C=="\u51CC"?(c=0,u==12&&(u=0)):(C=="\u4E0B"||C=="\u664F"||C=="\u665A")&&(c=1,u!=12&&(u+=12))}return i.text=i.text+t[0],i.end.assign("hour",u),i.end.assign("minute",l),c>=0?i.end.assign("meridiem",c):i.start.isCertain("meridiem")&&i.start.get("meridiem")==1&&i.start.get("hour")>u?i.end.imply("meridiem",0):u>12&&i.end.imply("meridiem",1),i.end.date().getTime(){"use strict";var $M=Ei&&Ei.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ei,"__esModule",{value:!0});var jM=$M(K()),BM=R(),Qy=yn(),GM=new RegExp("(?:\u661F\u671F|\u79AE\u62DC|\u9031)(?"+Object.keys(Qy.WEEKDAY_OFFSET).join("|")+")"),dc=class extends BM.AbstractParserWithWordBoundaryChecking{innerPattern(){return GM}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=t.groups.weekday,s=Qy.WEEKDAY_OFFSET[i];if(s===void 0)return null;let a=jM.default(e.refDate),o=!1,u=a.day();return Math.abs(s-7-u){"use strict";var HM=Ri&&Ri.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ri,"__esModule",{value:!0});var zM=HM(kt()),fc=class extends zM.default{patternBetween(){return/^\s*(至|到|\-|\~|~|-|ー)\s*$/i}};Ri.default=fc});var tg=h(wi=>{"use strict";var KM=wi&&wi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(wi,"__esModule",{value:!0});var VM=KM(Bt()),pc=class extends VM.default{patternBetween(){return/^\s*$/i}};wi.default=pc});var rg=h(be=>{"use strict";var Zt=be&&be.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(be,"__esModule",{value:!0});be.createConfiguration=be.createCasualConfiguration=be.parseDate=be.parse=be.strict=be.casual=be.hant=void 0;var hc=yt(),ZM=Zt(xs()),XM=Gt(),QM=Zt(By()),JM=Zt(Hy()),eD=Zt(Ky()),tD=Zt(Zy()),rD=Zt(Xy()),nD=Zt(Jy()),iD=Zt(eg()),sD=Zt(tg());be.hant=new hc.Chrono(mc());be.casual=new hc.Chrono(mc());be.strict=new hc.Chrono(yc());function aD(r,e,t){return be.casual.parse(r,e,t)}be.parse=aD;function oD(r,e,t){return be.casual.parseDate(r,e,t)}be.parseDate=oD;function mc(){let r=yc();return r.parsers.unshift(new QM.default),r}be.createCasualConfiguration=mc;function yc(){let r=XM.includeCommonConfiguration({parsers:[new JM.default,new tD.default,new nD.default,new rD.default,new eD.default],refiners:[new iD.default,new sD.default]});return r.refiners=r.refiners.filter(e=>!(e instanceof ZM.default)),r}be.createConfiguration=yc});var ag=h(Mi=>{"use strict";var uD=Mi&&Mi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Mi,"__esModule",{value:!0});var lD=uD(K()),cD=R(),dD=1,ng=2,fD=3,ig=4,sg=5,pD=6,gc=class extends cD.AbstractParserWithWordBoundaryChecking{innerPattern(e){return new RegExp("(\u73B0\u5728|\u7ACB(?:\u523B|\u5373)|\u5373\u523B)|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u540E|\u5927\u540E|\u6628)(\u65E9|\u665A)|(\u4E0A(?:\u5348)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668))|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u540E|\u5927\u540E|\u6628)(?:\u65E5|\u5929)(?:[\\s|,|\uFF0C]*)(?:(\u4E0A(?:\u5348)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668)))?","i")}innerExtract(e,t){let n=t.index,i=e.createParsingResult(n,t[0]),s=lD.default(e.refDate),a=s;if(t[dD])i.start.imply("hour",s.hour()),i.start.imply("minute",s.minute()),i.start.imply("second",s.second()),i.start.imply("millisecond",s.millisecond());else if(t[ng]){let o=t[ng],u=t[fD];o=="\u660E"?s.hour()>1&&(a=a.add(1,"day")):o=="\u6628"?a=a.add(-1,"day"):o=="\u524D"?a=a.add(-2,"day"):o=="\u5927\u524D"?a=a.add(-3,"day"):o=="\u540E"?a=a.add(2,"day"):o=="\u5927\u540E"&&(a=a.add(3,"day")),u=="\u65E9"?i.start.imply("hour",6):u=="\u665A"&&(i.start.imply("hour",22),i.start.imply("meridiem",1))}else if(t[ig]){let u=t[ig][0];u=="\u65E9"||u=="\u4E0A"?i.start.imply("hour",6):u=="\u4E0B"?(i.start.imply("hour",15),i.start.imply("meridiem",1)):u=="\u4E2D"?(i.start.imply("hour",12),i.start.imply("meridiem",1)):u=="\u591C"||u=="\u665A"?(i.start.imply("hour",22),i.start.imply("meridiem",1)):u=="\u51CC"&&i.start.imply("hour",0)}else if(t[sg]){let o=t[sg];o=="\u660E"?s.hour()>1&&(a=a.add(1,"day")):o=="\u6628"?a=a.add(-1,"day"):o=="\u524D"?a=a.add(-2,"day"):o=="\u5927\u524D"?a=a.add(-3,"day"):o=="\u540E"?a=a.add(2,"day"):o=="\u5927\u540E"&&(a=a.add(3,"day"));let u=t[pD];if(u){let l=u[0];l=="\u65E9"||l=="\u4E0A"?i.start.imply("hour",6):l=="\u4E0B"?(i.start.imply("hour",15),i.start.imply("meridiem",1)):l=="\u4E2D"?(i.start.imply("hour",12),i.start.imply("meridiem",1)):l=="\u591C"||l=="\u665A"?(i.start.imply("hour",22),i.start.imply("meridiem",1)):l=="\u51CC"&&i.start.imply("hour",0)}}return i.start.assign("day",a.date()),i.start.assign("month",a.month()+1),i.start.assign("year",a.year()),i}};Mi.default=gc});var _n=h(ze=>{"use strict";Object.defineProperty(ze,"__esModule",{value:!0});ze.zhStringToYear=ze.zhStringToNumber=ze.WEEKDAY_OFFSET=ze.NUMBER=void 0;ze.NUMBER={\u96F6:0,"\u3007":0,\u4E00:1,\u4E8C:2,\u4E24:2,\u4E09:3,\u56DB:4,\u4E94:5,\u516D:6,\u4E03:7,\u516B:8,\u4E5D:9,\u5341:10};ze.WEEKDAY_OFFSET={\u5929:0,\u65E5:0,\u4E00:1,\u4E8C:2,\u4E09:3,\u56DB:4,\u4E94:5,\u516D:6};function hD(r){let e=0;for(let t=0;t{"use strict";var yD=Di&&Di.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Di,"__esModule",{value:!0});var gD=yD(K()),_D=R(),Br=_n(),_c=1,og=2,Tc=3,bc=class extends _D.AbstractParserWithWordBoundaryChecking{innerPattern(){return new RegExp("(\\d{2,4}|["+Object.keys(Br.NUMBER).join("")+"]{4}|["+Object.keys(Br.NUMBER).join("")+"]{2})?(?:\\s*)(?:\u5E74)?(?:[\\s|,|\uFF0C]*)(\\d{1,2}|["+Object.keys(Br.NUMBER).join("")+"]{1,3})(?:\\s*)(?:\u6708)(?:\\s*)(\\d{1,2}|["+Object.keys(Br.NUMBER).join("")+"]{1,3})?(?:\\s*)(?:\u65E5|\u53F7)?")}innerExtract(e,t){let n=gD.default(e.refDate),i=e.createParsingResult(t.index,t[0]),s=parseInt(t[og]);if(isNaN(s)&&(s=Br.zhStringToNumber(t[og])),i.start.assign("month",s),t[Tc]){let a=parseInt(t[Tc]);isNaN(a)&&(a=Br.zhStringToNumber(t[Tc])),i.start.assign("day",a)}else i.start.imply("day",n.date());if(t[_c]){let a=parseInt(t[_c]);isNaN(a)&&(a=Br.zhStringToYear(t[_c])),i.start.assign("year",a)}else i.start.imply("year",n.year());return i}};Di.default=bc});var cg=h(Pi=>{"use strict";var TD=Pi&&Pi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Pi,"__esModule",{value:!0});var bD=TD(K()),vD=R(),lg=_n(),ED=new RegExp("(\\d+|["+Object.keys(lg.NUMBER).join("")+"]+|\u534A|\u51E0)(?:\\s*)(?:\u4E2A)?(\u79D2(?:\u949F)?|\u5206\u949F|\u5C0F\u65F6|\u949F|\u65E5|\u5929|\u661F\u671F|\u793C\u62DC|\u6708|\u5E74)(?:(?:\u4E4B|\u8FC7)?\u540E|(?:\u4E4B)?\u5185)","i"),vc=1,RD=2,Ec=class extends vD.AbstractParserWithWordBoundaryChecking{innerPattern(){return ED}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=parseInt(t[vc]);if(isNaN(i)&&(i=lg.zhStringToNumber(t[vc])),isNaN(i)){let u=t[vc];if(u==="\u51E0")i=3;else if(u==="\u534A")i=.5;else return null}let s=bD.default(e.refDate),o=t[RD][0];return o.match(/[日天星礼月年]/)?(o=="\u65E5"||o=="\u5929"?s=s.add(i,"d"):o=="\u661F"||o=="\u793C"?s=s.add(i*7,"d"):o=="\u6708"?s=s.add(i,"month"):o=="\u5E74"&&(s=s.add(i,"year")),n.start.assign("year",s.year()),n.start.assign("month",s.month()+1),n.start.assign("day",s.date()),n):(o=="\u79D2"?s=s.add(i,"second"):o=="\u5206"?s=s.add(i,"minute"):(o=="\u5C0F"||o=="\u949F")&&(s=s.add(i,"hour")),n.start.imply("year",s.year()),n.start.imply("month",s.month()+1),n.start.imply("day",s.date()),n.start.assign("hour",s.hour()),n.start.assign("minute",s.minute()),n.start.assign("second",s.second()),n)}};Pi.default=Ec});var fg=h(Oi=>{"use strict";var wD=Oi&&Oi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Oi,"__esModule",{value:!0});var MD=wD(K()),DD=R(),dg=_n(),PD=new RegExp("(?\u4E0A|\u4E0B|\u8FD9)(?:\u4E2A)?(?:\u661F\u671F|\u793C\u62DC|\u5468)(?"+Object.keys(dg.WEEKDAY_OFFSET).join("|")+")"),Rc=class extends DD.AbstractParserWithWordBoundaryChecking{innerPattern(){return PD}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=t.groups.weekday,s=dg.WEEKDAY_OFFSET[i];if(s===void 0)return null;let a=null,o=t.groups.prefix;o=="\u4E0A"?a="last":o=="\u4E0B"?a="next":o=="\u8FD9"&&(a="this");let u=MD.default(e.refDate),l=!1,c=u.day();return a=="last"||a=="past"?(u=u.day(s-7),l=!0):a=="next"?(u=u.day(s+7),l=!0):a=="this"?u=u.day(s):Math.abs(s-7-c){"use strict";var OD=Ai&&Ai.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ai,"__esModule",{value:!0});var AD=OD(K()),kD=R(),ct=_n(),ND=new RegExp("(?:\u4ECE|\u81EA)?(?:(\u4ECA|\u660E|\u524D|\u5927\u524D|\u540E|\u5927\u540E|\u6628)(\u65E9|\u671D|\u665A)|(\u4E0A(?:\u5348)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668))|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u540E|\u5927\u540E|\u6628)(?:\u65E5|\u5929)(?:[\\s,\uFF0C]*)(?:(\u4E0A(?:\u5348)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668)))?)?(?:[\\s,\uFF0C]*)(?:(\\d+|["+Object.keys(ct.NUMBER).join("")+"]+)(?:\\s*)(?:\u70B9|\u65F6|:|\uFF1A)(?:\\s*)(\\d+|\u534A|\u6B63|\u6574|["+Object.keys(ct.NUMBER).join("")+"]+)?(?:\\s*)(?:\u5206|:|\uFF1A)?(?:\\s*)(\\d+|["+Object.keys(ct.NUMBER).join("")+"]+)?(?:\\s*)(?:\u79D2)?)(?:\\s*(A.M.|P.M.|AM?|PM?))?","i"),xD=new RegExp("(?:^\\s*(?:\u5230|\u81F3|\\-|\\\u2013|\\~|\\\u301C)\\s*)(?:(\u4ECA|\u660E|\u524D|\u5927\u524D|\u540E|\u5927\u540E|\u6628)(\u65E9|\u671D|\u665A)|(\u4E0A(?:\u5348)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668))|(\u4ECA|\u660E|\u524D|\u5927\u524D|\u540E|\u5927\u540E|\u6628)(?:\u65E5|\u5929)(?:[\\s,\uFF0C]*)(?:(\u4E0A(?:\u5348)|\u65E9(?:\u4E0A)|\u4E0B(?:\u5348)|\u665A(?:\u4E0A)|\u591C(?:\u665A)?|\u4E2D(?:\u5348)|\u51CC(?:\u6668)))?)?(?:[\\s,\uFF0C]*)(?:(\\d+|["+Object.keys(ct.NUMBER).join("")+"]+)(?:\\s*)(?:\u70B9|\u65F6|:|\uFF1A)(?:\\s*)(\\d+|\u534A|\u6B63|\u6574|["+Object.keys(ct.NUMBER).join("")+"]+)?(?:\\s*)(?:\u5206|:|\uFF1A)?(?:\\s*)(\\d+|["+Object.keys(ct.NUMBER).join("")+"]+)?(?:\\s*)(?:\u79D2)?)(?:\\s*(A.M.|P.M.|AM?|PM?))?","i"),na=1,ia=2,sa=3,aa=4,oa=5,ua=6,lt=7,Tn=8,la=9,wc=class extends kD.AbstractParserWithWordBoundaryChecking{innerPattern(){return ND}innerExtract(e,t){if(t.index>0&&e.text[t.index-1].match(/\w/))return null;let n=AD.default(e.refDate),i=e.createParsingResult(t.index,t[0]),s=n.clone();if(t[na]){let c=t[na];c=="\u660E"?n.hour()>1&&s.add(1,"day"):c=="\u6628"?s.add(-1,"day"):c=="\u524D"?s.add(-2,"day"):c=="\u5927\u524D"?s.add(-3,"day"):c=="\u540E"?s.add(2,"day"):c=="\u5927\u540E"&&s.add(3,"day"),i.start.assign("day",s.date()),i.start.assign("month",s.month()+1),i.start.assign("year",s.year())}else if(t[aa]){let c=t[aa];c=="\u660E"?s.add(1,"day"):c=="\u6628"?s.add(-1,"day"):c=="\u524D"?s.add(-2,"day"):c=="\u5927\u524D"?s.add(-3,"day"):c=="\u540E"?s.add(2,"day"):c=="\u5927\u540E"&&s.add(3,"day"),i.start.assign("day",s.date()),i.start.assign("month",s.month()+1),i.start.assign("year",s.year())}else i.start.imply("day",s.date()),i.start.imply("month",s.month()+1),i.start.imply("year",s.year());let a=0,o=0,u=-1;if(t[Tn]){let c=parseInt(t[Tn]);if(isNaN(c)&&(c=ct.zhStringToNumber(t[Tn])),c>=60)return null;i.start.assign("second",c)}if(a=parseInt(t[ua]),isNaN(a)&&(a=ct.zhStringToNumber(t[ua])),t[lt]?t[lt]=="\u534A"?o=30:t[lt]=="\u6B63"||t[lt]=="\u6574"?o=0:(o=parseInt(t[lt]),isNaN(o)&&(o=ct.zhStringToNumber(t[lt]))):a>100&&(o=a%100,a=Math.floor(a/100)),o>=60||a>24)return null;if(a>=12&&(u=1),t[la]){if(a>12)return null;let c=t[la][0].toLowerCase();c=="a"&&(u=0,a==12&&(a=0)),c=="p"&&(u=1,a!=12&&(a+=12))}else if(t[ia]){let d=t[ia][0];d=="\u65E9"?(u=0,a==12&&(a=0)):d=="\u665A"&&(u=1,a!=12&&(a+=12))}else if(t[sa]){let d=t[sa][0];d=="\u4E0A"||d=="\u65E9"||d=="\u51CC"?(u=0,a==12&&(a=0)):(d=="\u4E0B"||d=="\u665A")&&(u=1,a!=12&&(a+=12))}else if(t[oa]){let d=t[oa][0];d=="\u4E0A"||d=="\u65E9"||d=="\u51CC"?(u=0,a==12&&(a=0)):(d=="\u4E0B"||d=="\u665A")&&(u=1,a!=12&&(a+=12))}if(i.start.assign("hour",a),i.start.assign("minute",o),u>=0?i.start.assign("meridiem",u):a<12?i.start.imply("meridiem",0):i.start.imply("meridiem",1),t=xD.exec(e.text.substring(i.index+i.text.length)),!t)return i.text.match(/^\d+$/)?null:i;let l=s.clone();if(i.end=e.createParsingComponents(),t[na]){let c=t[na];c=="\u660E"?n.hour()>1&&l.add(1,"day"):c=="\u6628"?l.add(-1,"day"):c=="\u524D"?l.add(-2,"day"):c=="\u5927\u524D"?l.add(-3,"day"):c=="\u540E"?l.add(2,"day"):c=="\u5927\u540E"&&l.add(3,"day"),i.end.assign("day",l.date()),i.end.assign("month",l.month()+1),i.end.assign("year",l.year())}else if(t[aa]){let c=t[aa];c=="\u660E"?l.add(1,"day"):c=="\u6628"?l.add(-1,"day"):c=="\u524D"?l.add(-2,"day"):c=="\u5927\u524D"?l.add(-3,"day"):c=="\u540E"?l.add(2,"day"):c=="\u5927\u540E"&&l.add(3,"day"),i.end.assign("day",l.date()),i.end.assign("month",l.month()+1),i.end.assign("year",l.year())}else i.end.imply("day",l.date()),i.end.imply("month",l.month()+1),i.end.imply("year",l.year());if(a=0,o=0,u=-1,t[Tn]){let c=parseInt(t[Tn]);if(isNaN(c)&&(c=ct.zhStringToNumber(t[Tn])),c>=60)return null;i.end.assign("second",c)}if(a=parseInt(t[ua]),isNaN(a)&&(a=ct.zhStringToNumber(t[ua])),t[lt]?t[lt]=="\u534A"?o=30:t[lt]=="\u6B63"||t[lt]=="\u6574"?o=0:(o=parseInt(t[lt]),isNaN(o)&&(o=ct.zhStringToNumber(t[lt]))):a>100&&(o=a%100,a=Math.floor(a/100)),o>=60||a>24)return null;if(a>=12&&(u=1),t[la]){if(a>12)return null;let c=t[la][0].toLowerCase();c=="a"&&(u=0,a==12&&(a=0)),c=="p"&&(u=1,a!=12&&(a+=12)),i.start.isCertain("meridiem")||(u==0?(i.start.imply("meridiem",0),i.start.get("hour")==12&&i.start.assign("hour",0)):(i.start.imply("meridiem",1),i.start.get("hour")!=12&&i.start.assign("hour",i.start.get("hour")+12)))}else if(t[ia]){let d=t[ia][0];d=="\u65E9"?(u=0,a==12&&(a=0)):d=="\u665A"&&(u=1,a!=12&&(a+=12))}else if(t[sa]){let d=t[sa][0];d=="\u4E0A"||d=="\u65E9"||d=="\u51CC"?(u=0,a==12&&(a=0)):(d=="\u4E0B"||d=="\u665A")&&(u=1,a!=12&&(a+=12))}else if(t[oa]){let d=t[oa][0];d=="\u4E0A"||d=="\u65E9"||d=="\u51CC"?(u=0,a==12&&(a=0)):(d=="\u4E0B"||d=="\u665A")&&(u=1,a!=12&&(a+=12))}return i.text=i.text+t[0],i.end.assign("hour",a),i.end.assign("minute",o),u>=0?i.end.assign("meridiem",u):i.start.isCertain("meridiem")&&i.start.get("meridiem")==1&&i.start.get("hour")>a?i.end.imply("meridiem",0):a>12&&i.end.imply("meridiem",1),i.end.date().getTime(){"use strict";var CD=ki&&ki.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ki,"__esModule",{value:!0});var SD=CD(K()),ID=R(),hg=_n(),UD=new RegExp("(?:\u661F\u671F|\u793C\u62DC|\u5468)(?"+Object.keys(hg.WEEKDAY_OFFSET).join("|")+")"),Mc=class extends ID.AbstractParserWithWordBoundaryChecking{innerPattern(){return UD}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=t.groups.weekday,s=hg.WEEKDAY_OFFSET[i];if(s===void 0)return null;let a=SD.default(e.refDate),o=!1,u=a.day();return Math.abs(s-7-u){"use strict";var FD=Ni&&Ni.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ni,"__esModule",{value:!0});var qD=FD(kt()),Dc=class extends qD.default{patternBetween(){return/^\s*(至|到|-|~|~|-|ー)\s*$/i}};Ni.default=Dc});var gg=h(xi=>{"use strict";var WD=xi&&xi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(xi,"__esModule",{value:!0});var LD=WD(Bt()),Pc=class extends LD.default{patternBetween(){return/^\s*$/i}};xi.default=Pc});var _g=h(ve=>{"use strict";var Xt=ve&&ve.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ve,"__esModule",{value:!0});ve.createConfiguration=ve.createCasualConfiguration=ve.parseDate=ve.parse=ve.strict=ve.casual=ve.hans=void 0;var Oc=yt(),YD=Xt(xs()),$D=Gt(),jD=Xt(ag()),BD=Xt(ug()),GD=Xt(cg()),HD=Xt(fg()),zD=Xt(pg()),KD=Xt(mg()),VD=Xt(yg()),ZD=Xt(gg());ve.hans=new Oc.Chrono(Ac());ve.casual=new Oc.Chrono(Ac());ve.strict=new Oc.Chrono(kc());function XD(r,e,t){return ve.casual.parse(r,e,t)}ve.parse=XD;function QD(r,e,t){return ve.casual.parseDate(r,e,t)}ve.parseDate=QD;function Ac(){let r=kc();return r.parsers.unshift(new jD.default),r}ve.createCasualConfiguration=Ac;function kc(){let r=$D.includeCommonConfiguration({parsers:[new BD.default,new HD.default,new KD.default,new zD.default,new GD.default],refiners:[new VD.default,new ZD.default]});return r.refiners=r.refiners.filter(e=>!(e instanceof YD.default)),r}ve.createConfiguration=kc});var bg=h(Je=>{"use strict";var Tg=Je&&Je.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),JD=Je&&Je.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),eP=Je&&Je.__exportStar||function(r,e){for(var t in r)t!=="default"&&!Object.prototype.hasOwnProperty.call(e,t)&&Tg(e,r,t)},tP=Je&&Je.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&Tg(e,r,t);return JD(e,r),e};Object.defineProperty(Je,"__esModule",{value:!0});Je.hans=void 0;eP(rg(),Je);Je.hans=tP(_g())});var Ke=h(F=>{"use strict";Object.defineProperty(F,"__esModule",{value:!0});F.parseTimeUnits=F.TIME_UNITS_PATTERN=F.parseYear=F.YEAR_PATTERN=F.parseOrdinalNumberPattern=F.ORDINAL_NUMBER_PATTERN=F.parseNumberPattern=F.NUMBER_PATTERN=F.TIME_UNIT_DICTIONARY=F.ORDINAL_WORD_DICTIONARY=F.INTEGER_WORD_DICTIONARY=F.MONTH_DICTIONARY=F.FULL_MONTH_NAME_DICTIONARY=F.WEEKDAY_DICTIONARY=F.REGEX_PARTS=void 0;var ca=J(),rP=Se();F.REGEX_PARTS={leftBoundary:"([^\\p{L}\\p{N}_]|^)",rightBoundary:"(?=[^\\p{L}\\p{N}_]|$)",flags:"iu"};F.WEEKDAY_DICTIONARY={\u0432\u043E\u0441\u043A\u0440\u0435\u0441\u0435\u043D\u044C\u0435:0,\u0432\u043E\u0441\u043A\u0440\u0435\u0441\u0435\u043D\u044C\u044F:0,\u0432\u0441\u043A:0,"\u0432\u0441\u043A.":0,\u043F\u043E\u043D\u0435\u0434\u0435\u043B\u044C\u043D\u0438\u043A:1,\u043F\u043E\u043D\u0435\u0434\u0435\u043B\u044C\u043D\u0438\u043A\u0430:1,\u043F\u043D:1,"\u043F\u043D.":1,\u0432\u0442\u043E\u0440\u043D\u0438\u043A:2,\u0432\u0442\u043E\u0440\u043D\u0438\u043A\u0430:2,\u0432\u0442:2,"\u0432\u0442.":2,\u0441\u0440\u0435\u0434\u0430:3,\u0441\u0440\u0435\u0434\u044B:3,\u0441\u0440\u0435\u0434\u0443:3,\u0441\u0440:3,"\u0441\u0440.":3,\u0447\u0435\u0442\u0432\u0435\u0440\u0433:4,\u0447\u0435\u0442\u0432\u0435\u0440\u0433\u0430:4,\u0447\u0442:4,"\u0447\u0442.":4,\u043F\u044F\u0442\u043D\u0438\u0446\u0430:5,\u043F\u044F\u0442\u043D\u0438\u0446\u0443:5,\u043F\u044F\u0442\u043D\u0438\u0446\u044B:5,\u043F\u0442:5,"\u043F\u0442.":5,\u0441\u0443\u0431\u0431\u043E\u0442\u0430:6,\u0441\u0443\u0431\u0431\u043E\u0442\u0443:6,\u0441\u0443\u0431\u0431\u043E\u0442\u044B:6,\u0441\u0431:6,"\u0441\u0431.":6};F.FULL_MONTH_NAME_DICTIONARY={\u044F\u043D\u0432\u0430\u0440\u044C:1,\u044F\u043D\u0432\u0430\u0440\u044F:1,\u044F\u043D\u0432\u0430\u0440\u0435:1,\u0444\u0435\u0432\u0440\u044F\u043B\u044C:2,\u0444\u0435\u0432\u0440\u044F\u043B\u044F:2,\u0444\u0435\u0432\u0440\u044F\u043B\u0435:2,\u043C\u0430\u0440\u0442:3,\u043C\u0430\u0440\u0442\u0430:3,\u043C\u0430\u0440\u0442\u0435:3,\u0430\u043F\u0440\u0435\u043B\u044C:4,\u0430\u043F\u0440\u0435\u043B\u044F:4,\u0430\u043F\u0440\u0435\u043B\u0435:4,\u043C\u0430\u0439:5,\u043C\u0430\u044F:5,\u043C\u0430\u0435:5,\u0438\u044E\u043D\u044C:6,\u0438\u044E\u043D\u044F:6,\u0438\u044E\u043D\u0435:6,\u0438\u044E\u043B\u044C:7,\u0438\u044E\u043B\u044F:7,\u0438\u044E\u043B\u0435:7,\u0430\u0432\u0433\u0443\u0441\u0442:8,\u0430\u0432\u0433\u0443\u0441\u0442\u0430:8,\u0430\u0432\u0433\u0443\u0441\u0442\u0435:8,\u0441\u0435\u043D\u0442\u044F\u0431\u0440\u044C:9,\u0441\u0435\u043D\u0442\u044F\u0431\u0440\u044F:9,\u0441\u0435\u043D\u0442\u044F\u0431\u0440\u0435:9,\u043E\u043A\u0442\u044F\u0431\u0440\u044C:10,\u043E\u043A\u0442\u044F\u0431\u0440\u044F:10,\u043E\u043A\u0442\u044F\u0431\u0440\u0435:10,\u043D\u043E\u044F\u0431\u0440\u044C:11,\u043D\u043E\u044F\u0431\u0440\u044F:11,\u043D\u043E\u044F\u0431\u0440\u0435:11,\u0434\u0435\u043A\u0430\u0431\u0440\u044C:12,\u0434\u0435\u043A\u0430\u0431\u0440\u044F:12,\u0434\u0435\u043A\u0430\u0431\u0440\u0435:12};F.MONTH_DICTIONARY=Object.assign(Object.assign({},F.FULL_MONTH_NAME_DICTIONARY),{\u044F\u043D\u0432:1,"\u044F\u043D\u0432.":1,\u0444\u0435\u0432:2,"\u0444\u0435\u0432.":2,\u043C\u0430\u0440:3,"\u043C\u0430\u0440.":3,\u0430\u043F\u0440:4,"\u0430\u043F\u0440.":4,\u0430\u0432\u0433:8,"\u0430\u0432\u0433.":8,\u0441\u0435\u043D:9,"\u0441\u0435\u043D.":9,\u043E\u043A\u0442:10,"\u043E\u043A\u0442.":10,\u043D\u043E\u044F:11,"\u043D\u043E\u044F.":11,\u0434\u0435\u043A:12,"\u0434\u0435\u043A.":12});F.INTEGER_WORD_DICTIONARY={\u043E\u0434\u0438\u043D:1,\u043E\u0434\u043D\u0430:1,\u043E\u0434\u043D\u043E\u0439:1,\u043E\u0434\u043D\u0443:1,\u0434\u0432\u0435:2,\u0434\u0432\u0430:2,\u0434\u0432\u0443\u0445:2,\u0442\u0440\u0438:3,\u0442\u0440\u0435\u0445:3,\u0442\u0440\u0451\u0445:3,\u0447\u0435\u0442\u044B\u0440\u0435:4,\u0447\u0435\u0442\u044B\u0440\u0435\u0445:4,\u0447\u0435\u0442\u044B\u0440\u0451\u0445:4,\u043F\u044F\u0442\u044C:5,\u043F\u044F\u0442\u0438:5,\u0448\u0435\u0441\u0442\u044C:6,\u0448\u0435\u0441\u0442\u0438:6,\u0441\u0435\u043C\u044C:7,\u0441\u0435\u043C\u0438:7,\u0432\u043E\u0441\u0435\u043C\u044C:8,\u0432\u043E\u0441\u0435\u043C\u044C\u043C\u0438:8,\u0434\u0435\u0432\u044F\u0442\u044C:9,\u0434\u0435\u0432\u044F\u0442\u0438:9,\u0434\u0435\u0441\u044F\u0442\u044C:10,\u0434\u0435\u0441\u044F\u0442\u0438:10,\u043E\u0434\u0438\u043D\u043D\u0430\u0434\u0446\u0430\u0442\u044C:11,\u043E\u0434\u0438\u043D\u043D\u0430\u0434\u0446\u0430\u0442\u0438:11,\u0434\u0432\u0435\u043D\u0430\u0434\u0446\u0430\u0442\u044C:12,\u0434\u0432\u0435\u043D\u0430\u0434\u0446\u0430\u0442\u0438:12};F.ORDINAL_WORD_DICTIONARY={\u043F\u0435\u0440\u0432\u043E\u0435:1,\u043F\u0435\u0440\u0432\u043E\u0433\u043E:1,\u0432\u0442\u043E\u0440\u043E\u0435:2,\u0432\u0442\u043E\u0440\u043E\u0433\u043E:2,\u0442\u0440\u0435\u0442\u044C\u0435:3,\u0442\u0440\u0435\u0442\u044C\u0435\u0433\u043E:3,\u0447\u0435\u0442\u0432\u0435\u0440\u0442\u043E\u0435:4,\u0447\u0435\u0442\u0432\u0435\u0440\u0442\u043E\u0433\u043E:4,\u043F\u044F\u0442\u043E\u0435:5,\u043F\u044F\u0442\u043E\u0433\u043E:5,\u0448\u0435\u0441\u0442\u043E\u0435:6,\u0448\u0435\u0441\u0442\u043E\u0433\u043E:6,\u0441\u0435\u0434\u044C\u043C\u043E\u0435:7,\u0441\u0435\u0434\u044C\u043C\u043E\u0433\u043E:7,\u0432\u043E\u0441\u044C\u043C\u043E\u0435:8,\u0432\u043E\u0441\u044C\u043C\u043E\u0433\u043E:8,\u0434\u0435\u0432\u044F\u0442\u043E\u0435:9,\u0434\u0435\u0432\u044F\u0442\u043E\u0433\u043E:9,\u0434\u0435\u0441\u044F\u0442\u043E\u0435:10,\u0434\u0435\u0441\u044F\u0442\u043E\u0433\u043E:10,\u043E\u0434\u0438\u043D\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:11,\u043E\u0434\u0438\u043D\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:11,\u0434\u0432\u0435\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:12,\u0434\u0432\u0435\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:12,\u0442\u0440\u0438\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:13,\u0442\u0440\u0438\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:13,\u0447\u0435\u0442\u044B\u0440\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:14,\u0447\u0435\u0442\u044B\u0440\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:14,\u043F\u044F\u0442\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:15,\u043F\u044F\u0442\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:15,\u0448\u0435\u0441\u0442\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:16,\u0448\u0435\u0441\u0442\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:16,\u0441\u0435\u043C\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:17,\u0441\u0435\u043C\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:17,\u0432\u043E\u0441\u0435\u043C\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:18,\u0432\u043E\u0441\u0435\u043C\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:18,\u0434\u0435\u0432\u044F\u0442\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0435:19,\u0434\u0435\u0432\u044F\u0442\u043D\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:19,\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u043E\u0435:20,\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u043E\u0433\u043E:20,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u043F\u0435\u0440\u0432\u043E\u0435":21,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u043F\u0435\u0440\u0432\u043E\u0433\u043E":21,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0432\u0442\u043E\u0440\u043E\u0435":22,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0432\u0442\u043E\u0440\u043E\u0433\u043E":22,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0442\u0440\u0435\u0442\u044C\u0435":23,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0442\u0440\u0435\u0442\u044C\u0435\u0433\u043E":23,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0447\u0435\u0442\u0432\u0435\u0440\u0442\u043E\u0435":24,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0447\u0435\u0442\u0432\u0435\u0440\u0442\u043E\u0433\u043E":24,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u043F\u044F\u0442\u043E\u0435":25,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u043F\u044F\u0442\u043E\u0433\u043E":25,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0448\u0435\u0441\u0442\u043E\u0435":26,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0448\u0435\u0441\u0442\u043E\u0433\u043E":26,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0441\u0435\u0434\u044C\u043C\u043E\u0435":27,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0441\u0435\u0434\u044C\u043C\u043E\u0433\u043E":27,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0432\u043E\u0441\u044C\u043C\u043E\u0435":28,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0432\u043E\u0441\u044C\u043C\u043E\u0433\u043E":28,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0434\u0435\u0432\u044F\u0442\u043E\u0435":29,"\u0434\u0432\u0430\u0434\u0446\u0430\u0442\u044C \u0434\u0435\u0432\u044F\u0442\u043E\u0433\u043E":29,\u0442\u0440\u0438\u0434\u0446\u0430\u0442\u043E\u0435:30,\u0442\u0440\u0438\u0434\u0446\u0430\u0442\u043E\u0433\u043E:30,"\u0442\u0440\u0438\u0434\u0446\u0430\u0442\u044C \u043F\u0435\u0440\u0432\u043E\u0435":31,"\u0442\u0440\u0438\u0434\u0446\u0430\u0442\u044C \u043F\u0435\u0440\u0432\u043E\u0433\u043E":31};F.TIME_UNIT_DICTIONARY={\u0441\u0435\u043A:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u0430:"second",\u0441\u0435\u043A\u0443\u043D\u0434:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u044B:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u0443:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u043E\u0447\u043A\u0430:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u043E\u0447\u043A\u0438:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u043E\u0447\u0435\u043A:"second",\u0441\u0435\u043A\u0443\u043D\u0434\u043E\u0447\u043A\u0443:"second",\u043C\u0438\u043D:"minute",\u043C\u0438\u043D\u0443\u0442\u0430:"minute",\u043C\u0438\u043D\u0443\u0442:"minute",\u043C\u0438\u043D\u0443\u0442\u044B:"minute",\u043C\u0438\u043D\u0443\u0442\u0443:"minute",\u043C\u0438\u043D\u0443\u0442\u043E\u043A:"minute",\u043C\u0438\u043D\u0443\u0442\u043A\u0438:"minute",\u043C\u0438\u043D\u0443\u0442\u043A\u0443:"minute",\u0447\u0430\u0441:"hour",\u0447\u0430\u0441\u043E\u0432:"hour",\u0447\u0430\u0441\u0430:"hour",\u0447\u0430\u0441\u0443:"hour",\u0447\u0430\u0441\u0438\u043A\u043E\u0432:"hour",\u0447\u0430\u0441\u0438\u043A\u0430:"hour",\u0447\u0430\u0441\u0438\u043A\u0435:"hour",\u0447\u0430\u0441\u0438\u043A:"hour",\u0434\u0435\u043D\u044C:"d",\u0434\u043D\u044F:"d",\u0434\u043D\u0435\u0439:"d",\u0441\u0443\u0442\u043E\u043A:"d",\u0441\u0443\u0442\u043A\u0438:"d",\u043D\u0435\u0434\u0435\u043B\u044F:"week",\u043D\u0435\u0434\u0435\u043B\u0435:"week",\u043D\u0435\u0434\u0435\u043B\u0438:"week",\u043D\u0435\u0434\u0435\u043B\u044E:"week",\u043D\u0435\u0434\u0435\u043B\u044C:"week",\u043D\u0435\u0434\u0435\u043B\u044C\u043A\u0435:"week",\u043D\u0435\u0434\u0435\u043B\u044C\u043A\u0438:"week",\u043D\u0435\u0434\u0435\u043B\u0435\u043A:"week",\u043C\u0435\u0441\u044F\u0446:"month",\u043C\u0435\u0441\u044F\u0446\u0435:"month",\u043C\u0435\u0441\u044F\u0446\u0435\u0432:"month",\u043C\u0435\u0441\u044F\u0446\u0430:"month",\u043A\u0432\u0430\u0440\u0442\u0430\u043B:"quarter",\u043A\u0432\u0430\u0440\u0442\u0430\u043B\u0435:"quarter",\u043A\u0432\u0430\u0440\u0442\u0430\u043B\u043E\u0432:"quarter",\u0433\u043E\u0434:"year",\u0433\u043E\u0434\u0430:"year",\u0433\u043E\u0434\u0443:"year",\u0433\u043E\u0434\u043E\u0432:"year",\u043B\u0435\u0442:"year",\u0433\u043E\u0434\u0438\u043A:"year",\u0433\u043E\u0434\u0438\u043A\u0430:"year",\u0433\u043E\u0434\u0438\u043A\u043E\u0432:"year"};F.NUMBER_PATTERN=`(?:${ca.matchAnyPattern(F.INTEGER_WORD_DICTIONARY)}|[0-9]+|[0-9]+\\.[0-9]+|\u043F\u043E\u043B|\u043D\u0435\u0441\u043A\u043E\u043B\u044C\u043A\u043E|\u043F\u0430\u0440(?:\u044B|\u0443)|\\s{0,3})`;function Eg(r){let e=r.toLowerCase();return F.INTEGER_WORD_DICTIONARY[e]!==void 0?F.INTEGER_WORD_DICTIONARY[e]:e.match(/несколько/)?3:e.match(/пол/)?.5:e.match(/пар/)?2:e===""?1:parseFloat(e)}F.parseNumberPattern=Eg;F.ORDINAL_NUMBER_PATTERN=`(?:${ca.matchAnyPattern(F.ORDINAL_WORD_DICTIONARY)}|[0-9]{1,2}(?:\u0433\u043E|\u043E\u0433\u043E|\u0435|\u043E\u0435)?)`;function nP(r){let e=r.toLowerCase();return F.ORDINAL_WORD_DICTIONARY[e]!==void 0?F.ORDINAL_WORD_DICTIONARY[e]:(e=e.replace(/(?:st|nd|rd|th)$/i,""),parseInt(e))}F.parseOrdinalNumberPattern=nP;var Nc="(?:\\s+(?:\u0433\u043E\u0434\u0443|\u0433\u043E\u0434\u0430|\u0433\u043E\u0434|\u0433|\u0433.))?";F.YEAR_PATTERN=`(?:[1-9][0-9]{0,3}${Nc}\\s*(?:\u043D.\u044D.|\u0434\u043E \u043D.\u044D.|\u043D. \u044D.|\u0434\u043E \u043D. \u044D.)|[1-2][0-9]{3}${Nc}|[5-9][0-9]${Nc})`;function iP(r){if(/(год|года|г|г.)/i.test(r)&&(r=r.replace(/(год|года|г|г.)/i,"")),/(до н.э.|до н. э.)/i.test(r))return r=r.replace(/(до н.э.|до н. э.)/i,""),-parseInt(r);if(/(н. э.|н.э.)/i.test(r))return r=r.replace(/(н. э.|н.э.)/i,""),parseInt(r);let e=parseInt(r);return rP.findMostLikelyADYear(e)}F.parseYear=iP;var Rg=`(${F.NUMBER_PATTERN})\\s{0,3}(${ca.matchAnyPattern(F.TIME_UNIT_DICTIONARY)})`,vg=new RegExp(Rg,"i");F.TIME_UNITS_PATTERN=ca.repeatedTimeunitPattern("(?:(?:\u043E\u043A\u043E\u043B\u043E|\u043F\u0440\u0438\u043C\u0435\u0440\u043D\u043E)\\s{0,3})?",Rg);function sP(r){let e={},t=r,n=vg.exec(t);for(;n;)aP(e,n),t=t.substring(n[0].length).trim(),n=vg.exec(t);return e}F.parseTimeUnits=sP;function aP(r,e){let t=Eg(e[1]),n=F.TIME_UNIT_DICTIONARY[e[2].toLowerCase()];r[n]=t}});var Mg=h(Cc=>{"use strict";Object.defineProperty(Cc,"__esModule",{value:!0});var Ci=Ke(),oP=he(),uP=R(),wg=`(?:(?:\u043E\u043A\u043E\u043B\u043E|\u043F\u0440\u0438\u043C\u0435\u0440\u043D\u043E)\\s*(?:~\\s*)?)?(${Ci.TIME_UNITS_PATTERN})${Ci.REGEX_PARTS.rightBoundary}`,lP=new RegExp(`(?:\u0432 \u0442\u0435\u0447\u0435\u043D\u0438\u0435|\u0432 \u0442\u0435\u0447\u0435\u043D\u0438\u0438)\\s*${wg}`,Ci.REGEX_PARTS.flags),cP=new RegExp(wg,"i"),xc=class extends uP.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return Ci.REGEX_PARTS.leftBoundary}innerPattern(e){return e.option.forwardDate?cP:lP}innerExtract(e,t){let n=Ci.parseTimeUnits(t[1]);return oP.ParsingComponents.createRelativeFromReference(e.reference,n)}};Cc.default=xc});var kg=h(Ic=>{"use strict";Object.defineProperty(Ic,"__esModule",{value:!0});var dP=Se(),Si=Ke(),Ag=Ke(),da=Ke(),fP=J(),pP=R(),hP=new RegExp(`(?:\u0441)?\\s*(${da.ORDINAL_NUMBER_PATTERN})(?:\\s{0,3}(?:\u043F\u043E|-|\u2013|\u0434\u043E)?\\s{0,3}(${da.ORDINAL_NUMBER_PATTERN}))?(?:-|\\/|\\s{0,3}(?:of)?\\s{0,3})(${fP.matchAnyPattern(Si.MONTH_DICTIONARY)})(?:(?:-|\\/|,?\\s{0,3})(${Ag.YEAR_PATTERN}(?![^\\s]\\d)))?${Si.REGEX_PARTS.rightBoundary}`,Si.REGEX_PARTS.flags),Dg=1,Pg=2,mP=3,Og=4,Sc=class extends pP.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return Si.REGEX_PARTS.leftBoundary}innerPattern(){return hP}innerExtract(e,t){let n=e.createParsingResult(t.index,t[0]),i=Si.MONTH_DICTIONARY[t[mP].toLowerCase()],s=da.parseOrdinalNumberPattern(t[Dg]);if(s>31)return t.index=t.index+t[Dg].length,null;if(n.start.assign("month",i),n.start.assign("day",s),t[Og]){let a=Ag.parseYear(t[Og]);n.start.assign("year",a)}else{let a=dP.findYearClosestToRef(e.refDate,s,i);n.start.imply("year",a)}if(t[Pg]){let a=da.parseOrdinalNumberPattern(t[Pg]);n.end=n.start.clone(),n.end.assign("day",a)}return n}};Ic.default=Sc});var Cg=h(Fc=>{"use strict";Object.defineProperty(Fc,"__esModule",{value:!0});var Ii=Ke(),yP=Se(),gP=J(),xg=Ke(),_P=R(),TP=new RegExp(`((?:\u0432)\\s*)?(${gP.matchAnyPattern(Ii.MONTH_DICTIONARY)})\\s*(?:[,-]?\\s*(${xg.YEAR_PATTERN})?)?(?=[^\\s\\w]|\\s+[^0-9]|\\s+$|$)`,Ii.REGEX_PARTS.flags),bP=2,Ng=3,Uc=class extends _P.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return Ii.REGEX_PARTS.leftBoundary}innerPattern(){return TP}innerExtract(e,t){let n=t[bP].toLowerCase();if(t[0].length<=3&&!Ii.FULL_MONTH_NAME_DICTIONARY[n])return null;let i=e.createParsingResult(t.index,t.index+t[0].length);i.start.imply("day",1);let s=Ii.MONTH_DICTIONARY[n];if(i.start.assign("month",s),t[Ng]){let a=xg.parseYear(t[Ng]);i.start.assign("year",a)}else{let a=yP.findYearClosestToRef(e.refDate,1,s);i.start.imply("year",a)}return i}};Fc.default=Uc});var Ig=h(Wc=>{"use strict";Object.defineProperty(Wc,"__esModule",{value:!0});var fa=Ee(),vP=Fr(),Sg=Ke(),qc=class extends vP.AbstractTimeExpressionParser{constructor(e){super(e)}patternFlags(){return Sg.REGEX_PARTS.flags}primaryPatternLeftBoundary(){return"(^|\\s|T|(?:[^\\p{L}\\p{N}_]))"}followingPhase(){return"\\s*(?:\\-|\\\u2013|\\~|\\\u301C|\u0434\u043E|\u0438|\u043F\u043E|\\?)\\s*"}primaryPrefix(){return"(?:(?:\u0432|\u0441)\\s*)??"}primarySuffix(){return`(?:\\s*(?:\u0443\u0442\u0440\u0430|\u0432\u0435\u0447\u0435\u0440\u0430|\u043F\u043E\u0441\u043B\u0435 \u043F\u043E\u043B\u0443\u0434\u043D\u044F))?(?!\\/)${Sg.REGEX_PARTS.rightBoundary}`}extractPrimaryTimeComponents(e,t){let n=super.extractPrimaryTimeComponents(e,t);if(n){if(t[0].endsWith("\u0432\u0435\u0447\u0435\u0440\u0430")){let i=n.get("hour");i>=6&&i<12?(n.assign("hour",n.get("hour")+12),n.assign("meridiem",fa.Meridiem.PM)):i<6&&n.assign("meridiem",fa.Meridiem.AM)}if(t[0].endsWith("\u043F\u043E\u0441\u043B\u0435 \u043F\u043E\u043B\u0443\u0434\u043D\u044F")){n.assign("meridiem",fa.Meridiem.PM);let i=n.get("hour");i>=0&&i<=6&&n.assign("hour",n.get("hour")+12)}t[0].endsWith("\u0443\u0442\u0440\u0430")&&(n.assign("meridiem",fa.Meridiem.AM),n.get("hour")<12&&n.assign("hour",n.get("hour")))}return n}};Wc.default=qc});var Ug=h(Yc=>{"use strict";Object.defineProperty(Yc,"__esModule",{value:!0});var pa=Ke(),EP=he(),RP=R(),wP=st(),MP=new RegExp(`(${pa.TIME_UNITS_PATTERN})\\s{0,5}\u043D\u0430\u0437\u0430\u0434(?=(?:\\W|$))`,pa.REGEX_PARTS.flags),Lc=class extends RP.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return pa.REGEX_PARTS.leftBoundary}innerPattern(){return MP}innerExtract(e,t){let n=pa.parseTimeUnits(t[1]),i=wP.reverseTimeUnits(n);return EP.ParsingComponents.createRelativeFromReference(e.reference,i)}};Yc.default=Lc});var Fg=h(Ui=>{"use strict";var DP=Ui&&Ui.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Ui,"__esModule",{value:!0});var PP=DP(kt()),$c=class extends PP.default{patternBetween(){return/^\s*(и до|и по|до|по|-)\s*$/i}};Ui.default=$c});var qg=h(Fi=>{"use strict";var OP=Fi&&Fi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Fi,"__esModule",{value:!0});var AP=OP(Bt()),jc=class extends AP.default{patternBetween(){return new RegExp("^\\s*(T|\u0432|,|-)?\\s*$")}};Fi.default=jc});var Wg=h(Qt=>{"use strict";var kP=Qt&&Qt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),NP=Qt&&Qt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),xP=Qt&&Qt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&kP(e,r,t);return NP(e,r),e};Object.defineProperty(Qt,"__esModule",{value:!0});var CP=R(),qi=xP(zt()),Bc=Ke(),SP=new RegExp(`(?:\u0441|\u0441\u043E)?\\s*(\u0441\u0435\u0433\u043E\u0434\u043D\u044F|\u0432\u0447\u0435\u0440\u0430|\u0437\u0430\u0432\u0442\u0440\u0430|\u043F\u043E\u0441\u043B\u0435\u0437\u0430\u0432\u0442\u0440\u0430|\u043F\u043E\u0437\u0430\u0432\u0447\u0435\u0440\u0430)${Bc.REGEX_PARTS.rightBoundary}`,Bc.REGEX_PARTS.flags),Gc=class extends CP.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return Bc.REGEX_PARTS.leftBoundary}innerPattern(e){return SP}innerExtract(e,t){let n=t[1].toLowerCase(),i=e.createParsingComponents();switch(n){case"\u0441\u0435\u0433\u043E\u0434\u043D\u044F":return qi.today(e.reference);case"\u0432\u0447\u0435\u0440\u0430":return qi.yesterday(e.reference);case"\u0437\u0430\u0432\u0442\u0440\u0430":return qi.tomorrow(e.reference);case"\u043F\u043E\u0441\u043B\u0435\u0437\u0430\u0432\u0442\u0440\u0430":return qi.theDayAfter(e.reference,2);case"\u043F\u043E\u0437\u0430\u0432\u0447\u0435\u0440\u0430":return qi.theDayBefore(e.reference,2)}return i}};Qt.default=Gc});var Lg=h(vt=>{"use strict";var IP=vt&&vt.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),UP=vt&&vt.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),FP=vt&&vt.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&IP(e,r,t);return UP(e,r),e},qP=vt&&vt.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(vt,"__esModule",{value:!0});var WP=R(),Gr=FP(zt()),LP=it(),YP=qP(K()),Hc=Ke(),$P=new RegExp(`(\u0441\u0435\u0439\u0447\u0430\u0441|\u043F\u0440\u043E\u0448\u043B\u044B\u043C\\s*\u0432\u0435\u0447\u0435\u0440\u043E\u043C|\u043F\u0440\u043E\u0448\u043B\u043E\u0439\\s*\u043D\u043E\u0447\u044C\u044E|\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0439\\s*\u043D\u043E\u0447\u044C\u044E|\u0441\u0435\u0433\u043E\u0434\u043D\u044F\\s*\u043D\u043E\u0447\u044C\u044E|\u044D\u0442\u043E\u0439\\s*\u043D\u043E\u0447\u044C\u044E|\u043D\u043E\u0447\u044C\u044E|\u044D\u0442\u0438\u043C \u0443\u0442\u0440\u043E\u043C|\u0443\u0442\u0440\u043E\u043C|\u0443\u0442\u0440\u0430|\u0432\\s*\u043F\u043E\u043B\u0434\u0435\u043D\u044C|\u0432\u0435\u0447\u0435\u0440\u043E\u043C|\u0432\u0435\u0447\u0435\u0440\u0430|\u0432\\s*\u043F\u043E\u043B\u043D\u043E\u0447\u044C)${Hc.REGEX_PARTS.rightBoundary}`,Hc.REGEX_PARTS.flags),zc=class extends WP.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return Hc.REGEX_PARTS.leftBoundary}innerPattern(){return $P}innerExtract(e,t){let n=YP.default(e.refDate),i=t[0].toLowerCase(),s=e.createParsingComponents();if(i==="\u0441\u0435\u0439\u0447\u0430\u0441")return Gr.now(e.reference);if(i==="\u0432\u0435\u0447\u0435\u0440\u043E\u043C"||i==="\u0432\u0435\u0447\u0435\u0440\u0430")return Gr.evening(e.reference);if(i.endsWith("\u0443\u0442\u0440\u043E\u043C")||i.endsWith("\u0443\u0442\u0440\u0430"))return Gr.morning(e.reference);if(i.match(/в\s*полдень/))return Gr.noon(e.reference);if(i.match(/прошлой\s*ночью/))return Gr.lastNight(e.reference);if(i.match(/прошлым\s*вечером/))return Gr.yesterdayEvening(e.reference);if(i.match(/следующей\s*ночью/)){let a=n.hour()<22?1:2;n=n.add(a,"day"),LP.assignSimilarDate(s,n),s.imply("hour",0)}return i.match(/в\s*полночь/)||i.endsWith("\u043D\u043E\u0447\u044C\u044E")?Gr.midnight(e.reference):s}};vt.default=zc});var Yg=h(Vc=>{"use strict";Object.defineProperty(Vc,"__esModule",{value:!0});var Wi=Ke(),jP=J(),BP=R(),GP=Wr(),HP=new RegExp(`(?:(?:,|\\(|\uFF08)\\s*)?(?:\u0432\\s*?)?(?:(\u044D\u0442\u0443|\u044D\u0442\u043E\u0442|\u043F\u0440\u043E\u0448\u043B\u044B\u0439|\u043F\u0440\u043E\u0448\u043B\u0443\u044E|\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0438\u0439|\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0443\u044E|\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0433\u043E)\\s*)?(${jP.matchAnyPattern(Wi.WEEKDAY_DICTIONARY)})(?:\\s*(?:,|\\)|\uFF09))?(?:\\s*\u043D\u0430\\s*(\u044D\u0442\u043E\u0439|\u043F\u0440\u043E\u0448\u043B\u043E\u0439|\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0439)\\s*\u043D\u0435\u0434\u0435\u043B\u0435)?${Wi.REGEX_PARTS.rightBoundary}`,Wi.REGEX_PARTS.flags),zP=1,KP=2,VP=3,Kc=class extends BP.AbstractParserWithWordBoundaryChecking{innerPattern(){return HP}patternLeftBoundary(){return Wi.REGEX_PARTS.leftBoundary}innerExtract(e,t){let n=t[KP].toLowerCase(),i=Wi.WEEKDAY_DICTIONARY[n],s=t[zP],a=t[VP],o=s||a;o=o||"",o=o.toLowerCase();let u=null;o=="\u043F\u0440\u043E\u0448\u043B\u044B\u0439"||o=="\u043F\u0440\u043E\u0448\u043B\u0443\u044E"||o=="\u043F\u0440\u043E\u0448\u043B\u043E\u0439"?u="last":o=="\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0438\u0439"||o=="\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0443\u044E"||o=="\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0439"||o=="\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0433\u043E"?u="next":(o=="\u044D\u0442\u043E\u0442"||o=="\u044D\u0442\u0443"||o=="\u044D\u0442\u043E\u0439")&&(u="this");let l=GP.toDayJSWeekday(e.refDate,i,u);return e.createParsingComponents().assign("weekday",i).imply("day",l.date()).imply("month",l.month()+1).imply("year",l.year())}};Vc.default=Kc});var jg=h(Yi=>{"use strict";var ZP=Yi&&Yi.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Yi,"__esModule",{value:!0});var Li=Ke(),$g=he(),XP=ZP(K()),QP=R(),JP=J(),eO=new RegExp(`(\u0432 \u043F\u0440\u043E\u0448\u043B\u043E\u043C|\u043D\u0430 \u043F\u0440\u043E\u0448\u043B\u043E\u0439|\u043D\u0430 \u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0439|\u0432 \u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u043C|\u043D\u0430 \u044D\u0442\u043E\u0439|\u0432 \u044D\u0442\u043E\u043C)\\s*(${JP.matchAnyPattern(Li.TIME_UNIT_DICTIONARY)})(?=\\s*)${Li.REGEX_PARTS.rightBoundary}`,Li.REGEX_PARTS.flags),tO=1,rO=2,Zc=class extends QP.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return Li.REGEX_PARTS.leftBoundary}innerPattern(){return eO}innerExtract(e,t){let n=t[tO].toLowerCase(),i=t[rO].toLowerCase(),s=Li.TIME_UNIT_DICTIONARY[i];if(n=="\u043D\u0430 \u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u0439"||n=="\u0432 \u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0435\u043C"){let u={};return u[s]=1,$g.ParsingComponents.createRelativeFromReference(e.reference,u)}if(n=="\u0432 \u043F\u0440\u043E\u0448\u043B\u043E\u043C"||n=="\u043D\u0430 \u043F\u0440\u043E\u0448\u043B\u043E\u0439"){let u={};return u[s]=-1,$g.ParsingComponents.createRelativeFromReference(e.reference,u)}let a=e.createParsingComponents(),o=XP.default(e.reference.instant);return s.match(/week/i)?(o=o.add(-o.get("d"),"d"),a.imply("day",o.date()),a.imply("month",o.month()+1),a.imply("year",o.year())):s.match(/month/i)?(o=o.add(-o.date()+1,"d"),a.imply("day",o.date()),a.assign("year",o.year()),a.assign("month",o.month()+1)):s.match(/year/i)&&(o=o.add(-o.date()+1,"d"),o=o.add(-o.month(),"month"),a.imply("day",o.date()),a.imply("month",o.month()+1),a.assign("year",o.year())),a}};Yi.default=Zc});var Bg=h(Qc=>{"use strict";Object.defineProperty(Qc,"__esModule",{value:!0});var $i=Ke(),nO=he(),iO=R(),sO=st(),aO=new RegExp(`(\u044D\u0442\u0438|\u043F\u043E\u0441\u043B\u0435\u0434\u043D\u0438\u0435|\u043F\u0440\u043E\u0448\u043B\u044B\u0435|\u0441\u043B\u0435\u0434\u0443\u044E\u0449\u0438\u0435|\u043F\u043E\u0441\u043B\u0435|\u0447\u0435\u0440\u0435\u0437|\\+|-)\\s*(${$i.TIME_UNITS_PATTERN})${$i.REGEX_PARTS.rightBoundary}`,$i.REGEX_PARTS.flags),Xc=class extends iO.AbstractParserWithWordBoundaryChecking{patternLeftBoundary(){return $i.REGEX_PARTS.leftBoundary}innerPattern(){return aO}innerExtract(e,t){let n=t[1].toLowerCase(),i=$i.parseTimeUnits(t[2]);switch(n){case"\u043F\u043E\u0441\u043B\u0435\u0434\u043D\u0438\u0435":case"\u043F\u0440\u043E\u0448\u043B\u044B\u0435":case"-":i=sO.reverseTimeUnits(i);break}return nO.ParsingComponents.createRelativeFromReference(e.reference,i)}};Qc.default=Xc});var zg=h(ke=>{"use strict";var et=ke&&ke.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(ke,"__esModule",{value:!0});ke.createConfiguration=ke.createCasualConfiguration=ke.parseDate=ke.parse=ke.strict=ke.casual=void 0;var oO=et(Mg()),uO=et(kg()),lO=et(Cg()),cO=et(Ig()),dO=et(Ug()),fO=et(Fg()),pO=et(qg()),hO=Gt(),mO=et(Wg()),yO=et(Lg()),gO=et(Yg()),_O=et(jg()),Gg=yt(),TO=et(Lr()),bO=et(Bg());ke.casual=new Gg.Chrono(Hg());ke.strict=new Gg.Chrono(Jc(!0));function vO(r,e,t){return ke.casual.parse(r,e,t)}ke.parse=vO;function EO(r,e,t){return ke.casual.parseDate(r,e,t)}ke.parseDate=EO;function Hg(){let r=Jc(!1);return r.parsers.unshift(new mO.default),r.parsers.unshift(new yO.default),r.parsers.unshift(new lO.default),r.parsers.unshift(new _O.default),r.parsers.unshift(new bO.default),r}ke.createCasualConfiguration=Hg;function Jc(r=!0){return hO.includeCommonConfiguration({parsers:[new TO.default(!0),new oO.default,new uO.default,new gO.default,new cO.default(r),new dO.default],refiners:[new pO.default,new fO.default]},r)}ke.createConfiguration=Jc});var Ee=h(L=>{"use strict";var RO=L&&L.__createBinding||(Object.create?function(r,e,t,n){n===void 0&&(n=t),Object.defineProperty(r,n,{enumerable:!0,get:function(){return e[t]}})}:function(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}),wO=L&&L.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),Er=L&&L.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)t!=="default"&&Object.prototype.hasOwnProperty.call(r,t)&&RO(e,r,t);return wO(e,r),e};Object.defineProperty(L,"__esModule",{value:!0});L.parseDate=L.parse=L.casual=L.strict=L.ru=L.zh=L.nl=L.pt=L.ja=L.fr=L.de=L.Meridiem=L.Chrono=L.en=void 0;var ed=Er(gu());L.en=ed;var MO=yt();Object.defineProperty(L,"Chrono",{enumerable:!0,get:function(){return MO.Chrono}});var DO;(function(r){r[r.AM=0]="AM",r[r.PM=1]="PM"})(DO=L.Meridiem||(L.Meridiem={}));var PO=Er(rm());L.de=PO;var OO=Er(Nm());L.fr=OO;var AO=Er(Lm());L.ja=AO;var kO=Er(ry());L.pt=kO;var NO=Er(Ly());L.nl=NO;var xO=Er(bg());L.zh=xO;var CO=Er(zg());L.ru=CO;L.strict=ed.strict;L.casual=ed.casual;function SO(r,e,t){return L.casual.parse(r,e,t)}L.parse=SO;function IO(r,e,t){return L.casual.parseDate(r,e,t)}L.parseDate=IO});var St=h(Pr=>{"use strict";Pr.__esModule=!0;var jO;(function(r){r.AND="AND",r.OR="OR",r.XOR="XOR",r.NOT="NOT"})(jO=Pr.Operators||(Pr.Operators={}));var BO;(function(r){r.OPEN_PARENTHESIS="(",r.CLOSE_PARENTHESIS=")"})(BO=Pr.StructuralCharacters||(Pr.StructuralCharacters={}));var GO;(function(r){r.IDENTIFIER="IDENTIFIER",r.OPERATOR="OPERATOR",r.STRUCTURAL_CHARACTER="STRUCTURAL_CHARACTER",r.EOF="EOF",r.COMMENT="COMMENT"})(GO=Pr.Tokens||(Pr.Tokens={}))});var pd=h(Ca=>{"use strict";Ca.__esModule=!0;var me=St();Ca.OPERATOR_PRECEDENCE={NOT:0,XOR:1,AND:2,OR:3};Ca.VALID_TOKENS={identifierOnly:[{name:me.Tokens.IDENTIFIER},{name:me.Tokens.STRUCTURAL_CHARACTER,value:me.StructuralCharacters.OPEN_PARENTHESIS}],identifierOrNot:[{name:me.Tokens.IDENTIFIER},{name:me.Tokens.STRUCTURAL_CHARACTER,value:me.StructuralCharacters.OPEN_PARENTHESIS},{name:me.Tokens.OPERATOR,value:me.Operators.NOT}],binaryOperator:[{name:me.Tokens.OPERATOR,value:me.Operators.AND},{name:me.Tokens.OPERATOR,value:me.Operators.OR},{name:me.Tokens.OPERATOR,value:me.Operators.XOR}],binaryOperatorOrClose:[{name:me.Tokens.OPERATOR,value:me.Operators.AND},{name:me.Tokens.OPERATOR,value:me.Operators.OR},{name:me.Tokens.OPERATOR,value:me.Operators.XOR},{name:me.Tokens.STRUCTURAL_CHARACTER,value:me.StructuralCharacters.CLOSE_PARENTHESIS}]}});var hd=h(rr=>{"use strict";rr.__esModule=!0;var Rn=St();rr.STRUCTURAL_CHARACTERS={"(":Rn.StructuralCharacters.OPEN_PARENTHESIS,")":Rn.StructuralCharacters.CLOSE_PARENTHESIS};rr.OPERATORS={AND:Rn.Operators.AND,OR:Rn.Operators.OR,XOR:Rn.Operators.XOR,NOT:Rn.Operators.NOT};rr.SEPARATORS=new Set([32,9,10,13].map(function(r){return String.fromCodePoint(r)}));rr.QUOTED_IDENTIFIER_DELIMITER=String.fromCodePoint(34);rr.COMMENT_DELIMITER=String.fromCodePoint(35);rr.EOL=String.fromCodePoint(10);rr.ESCAPE_CHARACTER=String.fromCodePoint(92)});var i_=h(nr=>{"use strict";var md=nr&&nr.__assign||function(){return md=Object.assign||function(r){for(var e,t=1,n=arguments.length;t{"use strict";yd.__esModule=!0;var wn=St(),tt=hd(),Mn=i_();yd.lex=function(r){for(var e=null,t=null,n=null,i=0;i{"use strict";var HO=ir&&ir.__spreadArrays||function(){for(var r=0,e=0,t=arguments.length;e{"use strict";var Pn=Zi&&Zi.__spreadArrays||function(){for(var r=0,e=0,t=arguments.length;e{"use strict";sr.__esModule=!0;var l_=St();sr.andUtil=function(r,e){return r&&e};sr.orUtil=function(r,e){return r||e};sr.xorUtil=function(r,e){return r!==e};sr.notUtil=function(r){return!r};sr.isIdentifier=function(r){var e=r.name,t=r.value;return e===l_.Tokens.IDENTIFIER&&typeof t=="string"};sr.isOperator=function(r){var e=r.name,t=r.value;return e===l_.Tokens.OPERATOR&&typeof t=="string"};sr.throwInvalidExpression=function(r){throw new TypeError("Invalid postfix expression: "+r)}});var c_=h(Ed=>{"use strict";var Xi;Ed.__esModule=!0;var bd=St(),vd=Td();Ed.OPERATOR_MAP=(Xi={},Xi[bd.Operators.AND]=vd.andUtil,Xi[bd.Operators.OR]=vd.orUtil,Xi[bd.Operators.XOR]=vd.xorUtil,Xi)});var f_=h(Kr=>{"use strict";var Rd=Kr&&Kr.__spreadArrays||function(){for(var r=0,e=0,t=arguments.length;e{"use strict";Qi.__esModule=!0;var p_=f_();Qi.getEvaluator=p_.getEvaluator;Qi.evaluate=p_.evaluate;var ZO=_d();Qi.parse=ZO.parse});var nA={};D_(nA,{default:()=>ja});module.exports=P_(nA);var __=require("obsidian");var gs=require("obsidian");var sA=new Error("timeout while waiting for mutex to become available"),aA=new Error("mutex already locked"),O_=new Error("request for lock canceled"),Zd=function(r,e,t,n){function i(s){return s instanceof t?s:new t(function(a){a(s)})}return new(t||(t=Promise))(function(s,a){function o(c){try{l(n.next(c))}catch(d){a(d)}}function u(c){try{l(n.throw(c))}catch(d){a(d)}}function l(c){c.done?s(c.value):i(c.value).then(o,u)}l((n=n.apply(r,e||[])).next())})},Ka=class{constructor(e,t=O_){if(this._maxConcurrency=e,this._cancelError=t,this._queue=[],this._waiters=[],e<=0)throw new Error("semaphore must be initialized to a positive value");this._value=e}acquire(){let e=this.isLocked(),t=new Promise((n,i)=>this._queue.push({resolve:n,reject:i}));return e||this._dispatch(),t}runExclusive(e){return Zd(this,void 0,void 0,function*(){let[t,n]=yield this.acquire();try{return yield e(t)}finally{n()}})}waitForUnlock(){return Zd(this,void 0,void 0,function*(){return this.isLocked()?new Promise(t=>this._waiters.push({resolve:t})):Promise.resolve()})}isLocked(){return this._value<=0}release(){if(this._maxConcurrency>1)throw new Error("this method is unavailable on semaphores with concurrency > 1; use the scoped release returned by acquire instead");if(this._currentReleaser){let e=this._currentReleaser;this._currentReleaser=void 0,e()}}cancel(){this._queue.forEach(e=>e.reject(this._cancelError)),this._queue=[]}_dispatch(){let e=this._queue.shift();if(!e)return;let t=!1;this._currentReleaser=()=>{t||(t=!0,this._value++,this._resolveWaiters(),this._dispatch())},e.resolve([this._value--,this._currentReleaser])}_resolveWaiters(){this._waiters.forEach(e=>e.resolve()),this._waiters=[]}},A_=function(r,e,t,n){function i(s){return s instanceof t?s:new t(function(a){a(s)})}return new(t||(t=Promise))(function(s,a){function o(c){try{l(n.next(c))}catch(d){a(d)}}function u(c){try{l(n.throw(c))}catch(d){a(d)}}function l(c){c.done?s(c.value):i(c.value).then(o,u)}l((n=n.apply(r,e||[])).next())})},us=class{constructor(e){this._semaphore=new Ka(1,e)}acquire(){return A_(this,void 0,void 0,function*(){let[,e]=yield this._semaphore.acquire();return e})}runExclusive(e){return this._semaphore.runExclusive(()=>e())}isLocked(){return this._semaphore.isLocked()}waitForUnlock(){return this._semaphore.waitForUnlock()}release(){this._semaphore.release()}cancel(){return this._semaphore.cancel()}};var sp=require("obsidian");var Qd=require("obsidian");var Xd=[{index:9999,internalName:"INTERNAL_TESTING_ENABLED_BY_DEFAULT",displayName:"Test Item. Used to validate the Feature Framework.",description:"Description",enabledByDefault:!0,stable:!1}];var Et=class{constructor(e,t,n,i,s,a){this.internalName=e;this.index=t;this.description=n;this.displayName=i;this.enabledByDefault=s;this.stable=a}static get values(){let e=[];return Xd.forEach(t=>{e=[...e,new Et(t.internalName,t.index,t.description,t.displayName,t.enabledByDefault,t.stable)]}),e}static get settingsFlags(){let e={};return Et.values.forEach(t=>{e[t.internalName]=t.enabledByDefault}),e}static fromString(e){for(let t of Et.values)if(e===t.internalName)return t;throw new RangeError(`Illegal argument passed to fromString(): ${e} does not correspond to any available Feature ${this.prototype.constructor.name}`)}};var N_={globalFilter:"",removeGlobalFilter:!1,setDoneDate:!0,autoSuggestInEditor:!0,autoSuggestMinMatch:0,autoSuggestMaxItems:6,features:Et.settingsFlags},xn=$e({},N_),ae=()=>{for(let r in Et.settingsFlags)xn.features[r]===void 0&&(xn.features[r]=Et.settingsFlags[r]);return $e({},xn)},qt=r=>(xn=$e($e({},xn),r),ae());var Va,Za,Jd=({metadataCache:r,vault:e})=>{Va=r,Za=e},ls=t=>se(void 0,[t],function*({originalTask:r,newTasks:e}){if(Za===void 0||Va===void 0){console.error("Tasks: cannot use File before initializing it.");return}Array.isArray(e)||(e=[e]),ef({originalTask:r,newTasks:e,vault:Za,metadataCache:Va,previousTries:0})}),ef=s=>se(void 0,[s],function*({originalTask:r,newTasks:e,vault:t,metadataCache:n,previousTries:i}){let a=()=>{if(i>10){console.error("Tasks: Too many retries. File update not possible ...");return}let g=Math.min(Math.pow(10,i),100);setTimeout(()=>{ef({originalTask:r,newTasks:e,vault:t,metadataCache:n,previousTries:i+1})},g)},o=t.getAbstractFileByPath(r.path);if(!(o instanceof Qd.TFile))return console.warn(`Tasks: No file found for task ${r.description}. Retrying ...`),a();if(o.extension!=="md"){console.error("Tasks: Only supporting files with the .md file extension.");return}let u=n.getFileCache(o);if(u==null||u===null)return console.warn(`Tasks: No file cache found for file ${o.path}. Retrying ...`),a();let l=u.listItems;if(l===void 0||l.length===0)return console.warn(`Tasks: No list items found in file cache of ${o.path}. Retrying ...`),a();let d=(yield t.read(o)).split(` +`),{globalFilter:f}=ae(),p,y=0;for(let g of l){if(g.position.start.lineg.toFileLineString()),...d.slice(p.position.start.line+1)];yield t.modify(o,m.join(` +`))});var Xr=class{constructor(){this.hideTaskCount=!1;this.hideBacklinks=!1;this.hidePriority=!1;this.hideStartDate=!1;this.hideScheduledDate=!1;this.hideDoneDate=!1;this.hideDueDate=!1;this.hideRecurrenceRule=!1;this.hideEditButton=!1;this.shortMode=!1}};var cs=["MO","TU","WE","TH","FR","SA","SU"],_e=function(){function r(e,t){if(t===0)throw new Error("Can't create weekday with n == 0");this.weekday=e,this.n=t}return r.fromStr=function(e){return new r(cs.indexOf(e))},r.prototype.nth=function(e){return this.n===e?this:new r(this.weekday,e)},r.prototype.equals=function(e){return this.weekday===e.weekday&&this.n===e.n},r.prototype.toString=function(){var e=cs[this.weekday];return this.n&&(e=(this.n>0?"+":"")+String(this.n)+e),e},r.prototype.getJsWeekday=function(){return this.weekday===6?0:this.weekday+1},r}();var ue=function(r){return r!=null},Ze=function(r){return typeof r=="number"},Xa=function(r){return typeof r=="string"&&cs.includes(r)},Ce=Array.isArray,rt=function(r,e){e===void 0&&(e=r),arguments.length===1&&(e=r,r=0);for(var t=[],n=r;n>0,n.length>e?String(n):(e=e-n.length,e>t.length&&(t+=B(t,e/t.length)),t.slice(0,e)+String(n))}var rf=function(r,e,t){var n=r.split(e);return t?n.slice(0,t).concat([n.slice(t).join(e)]):n},Fe=function(r,e){var t=r%e;return t*e<0?t+e:t},ds=function(r,e){return{div:Math.floor(r/e),mod:Fe(r,e)}},Xe=function(r){return!ue(r)||r.length===0},ye=function(r){return!Xe(r)},G=function(r,e){return ye(r)&&r.indexOf(e)!==-1};var dr;(function(r){r.MONTH_DAYS=[31,28,31,30,31,30,31,31,30,31,30,31],r.ONE_DAY=1e3*60*60*24,r.MAXYEAR=9999,r.ORDINAL_BASE=new Date(Date.UTC(1970,0,1)),r.PY_WEEKDAYS=[6,0,1,2,3,4,5],r.getYearDay=function(e){var t=new Date(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate());return Math.ceil((t.valueOf()-new Date(e.getUTCFullYear(),0,1).valueOf())/r.ONE_DAY)+1},r.isLeapYear=function(e){return e%4===0&&e%100!==0||e%400===0},r.isDate=function(e){return e instanceof Date},r.isValidDate=function(e){return r.isDate(e)&&!isNaN(e.getTime())},r.tzOffset=function(e){return e.getTimezoneOffset()*60*1e3},r.daysBetween=function(e,t){var n=e.getTime()-r.tzOffset(e),i=t.getTime()-r.tzOffset(t),s=n-i;return Math.round(s/r.ONE_DAY)},r.toOrdinal=function(e){return r.daysBetween(e,r.ORDINAL_BASE)},r.fromOrdinal=function(e){return new Date(r.ORDINAL_BASE.getTime()+e*r.ONE_DAY)},r.getMonthDays=function(e){var t=e.getUTCMonth();return t===1&&r.isLeapYear(e.getUTCFullYear())?29:r.MONTH_DAYS[t]},r.getWeekday=function(e){return r.PY_WEEKDAYS[e.getUTCDay()]},r.monthRange=function(e,t){var n=new Date(Date.UTC(e,t,1));return[r.getWeekday(n),r.getMonthDays(n)]},r.combine=function(e,t){return t=t||e,new Date(Date.UTC(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()))},r.clone=function(e){var t=new Date(e.getTime());return t},r.cloneDates=function(e){for(var t=[],n=0;nthis.maxDate;if(this.method==="between"){if(t)return!0;if(n)return!1}else if(this.method==="before"){if(n)return!1}else if(this.method==="after")return t?!0:(this.add(e),!1);return this.add(e)},r.prototype.add=function(e){return this._result.push(e),!0},r.prototype.getValue=function(){var e=this._result;switch(this.method){case"all":case"between":return e;case"before":case"after":default:return e.length?e[e.length-1]:null}},r.prototype.clone=function(){return new r(this.method,this.args)},r}(),Wt=x_;var Df=os(Mf(),1),{__extends:Jr,__assign:je,__rest:MA,__decorate:DA,__param:PA,__metadata:OA,__awaiter:AA,__generator:kA,__exportStar:NA,__createBinding:xA,__values:CA,__read:SA,__spread:IA,__spreadArrays:UA,__spreadArray:T,__await:FA,__asyncGenerator:qA,__asyncDelegator:WA,__asyncValues:LA,__makeTemplateObject:YA,__importStar:$A,__importDefault:jA,__classPrivateFieldGet:BA,__classPrivateFieldSet:GA,__classPrivateFieldIn:HA}=Df.default;var C_=function(r){Jr(e,r);function e(t,n,i){var s=r.call(this,t,n)||this;return s.iterator=i,s}return e.prototype.add=function(t){return this.iterator(t,this._result.length)?(this._result.push(t),!0):!1},e}(Wt),Ja=C_;var S_={dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],tokens:{SKIP:/^[ \r\n\t]+|^\.$/,number:/^[1-9][0-9]*/,numberAsText:/^(one|two|three)/i,every:/^every/i,"day(s)":/^days?/i,"weekday(s)":/^weekdays?/i,"week(s)":/^weeks?/i,"hour(s)":/^hours?/i,"minute(s)":/^minutes?/i,"month(s)":/^months?/i,"year(s)":/^years?/i,on:/^(on|in)/i,at:/^(at)/i,the:/^the/i,first:/^first/i,second:/^second/i,third:/^third/i,nth:/^([1-9][0-9]*)(\.|th|nd|rd|st)/i,last:/^last/i,for:/^for/i,"time(s)":/^times?/i,until:/^(un)?til/i,monday:/^mo(n(day)?)?/i,tuesday:/^tu(e(s(day)?)?)?/i,wednesday:/^we(d(n(esday)?)?)?/i,thursday:/^th(u(r(sday)?)?)?/i,friday:/^fr(i(day)?)?/i,saturday:/^sa(t(urday)?)?/i,sunday:/^su(n(day)?)?/i,january:/^jan(uary)?/i,february:/^feb(ruary)?/i,march:/^mar(ch)?/i,april:/^apr(il)?/i,may:/^may/i,june:/^june?/i,july:/^july?/i,august:/^aug(ust)?/i,september:/^sep(t(ember)?)?/i,october:/^oct(ober)?/i,november:/^nov(ember)?/i,december:/^dec(ember)?/i,comma:/^(,\s*|(and|or)\s*)+/i}},Nr=S_;var Pf=function(r,e){return r.indexOf(e)!==-1},I_=function(r){return r.toString()},U_=function(r,e,t){return"".concat(e," ").concat(t,", ").concat(r)},F_=function(){function r(e,t,n,i){if(t===void 0&&(t=I_),n===void 0&&(n=Nr),i===void 0&&(i=U_),this.text=[],this.language=n||Nr,this.gettext=t,this.dateFormatter=i,this.rrule=e,this.options=e.options,this.origOptions=e.origOptions,this.origOptions.bymonthday){var s=[].concat(this.options.bymonthday),a=[].concat(this.options.bynmonthday);s.sort(function(c,d){return c-d}),a.sort(function(c,d){return d-c}),this.bymonthday=s.concat(a),this.bymonthday.length||(this.bymonthday=null)}if(ue(this.origOptions.byweekday)){var o=Ce(this.origOptions.byweekday)?this.origOptions.byweekday:[this.origOptions.byweekday],u=String(o);this.byweekday={allWeeks:o.filter(function(c){return!c.n}),someWeeks:o.filter(function(c){return Boolean(c.n)}),isWeekdays:u.indexOf("MO")!==-1&&u.indexOf("TU")!==-1&&u.indexOf("WE")!==-1&&u.indexOf("TH")!==-1&&u.indexOf("FR")!==-1&&u.indexOf("SA")===-1&&u.indexOf("SU")===-1,isEveryDay:u.indexOf("MO")!==-1&&u.indexOf("TU")!==-1&&u.indexOf("WE")!==-1&&u.indexOf("TH")!==-1&&u.indexOf("FR")!==-1&&u.indexOf("SA")!==-1&&u.indexOf("SU")!==-1};var l=function(c,d){return c.weekday-d.weekday};this.byweekday.allWeeks.sort(l),this.byweekday.someWeeks.sort(l),this.byweekday.allWeeks.length||(this.byweekday.allWeeks=null),this.byweekday.someWeeks.length||(this.byweekday.someWeeks=null)}else this.byweekday=null}return r.isFullyConvertible=function(e){var t=!0;if(!(e.options.freq in r.IMPLEMENTED)||e.origOptions.until&&e.origOptions.count)return!1;for(var n in e.origOptions){if(Pf(["dtstart","wkst","freq"],n))return!0;if(!Pf(r.IMPLEMENTED[e.options.freq],n))return!1}return t},r.prototype.isFullyConvertible=function(){return r.isFullyConvertible(this.rrule)},r.prototype.toString=function(){var e=this.gettext;if(!(this.options.freq in r.IMPLEMENTED))return e("RRule error: Unable to fully convert this rrule to text");if(this.text=[e("every")],this[w.FREQUENCIES[this.options.freq]](),this.options.until){this.add(e("until"));var t=this.options.until;this.add(this.dateFormatter(t.getUTCFullYear(),this.language.monthNames[t.getUTCMonth()],t.getUTCDate()))}else this.options.count&&this.add(e("for")).add(this.options.count.toString()).add(this.plural(this.options.count)?e("times"):e("time"));return this.isFullyConvertible()||this.add(e("(~ approximate)")),this.text.join("")},r.prototype.HOURLY=function(){var e=this.gettext;this.options.interval!==1&&this.add(this.options.interval.toString()),this.add(this.plural(this.options.interval)?e("hours"):e("hour"))},r.prototype.MINUTELY=function(){var e=this.gettext;this.options.interval!==1&&this.add(this.options.interval.toString()),this.add(this.plural(this.options.interval)?e("minutes"):e("minute"))},r.prototype.DAILY=function(){var e=this.gettext;this.options.interval!==1&&this.add(this.options.interval.toString()),this.byweekday&&this.byweekday.isWeekdays?this.add(this.plural(this.options.interval)?e("weekdays"):e("weekday")):this.add(this.plural(this.options.interval)?e("days"):e("day")),this.origOptions.bymonth&&(this.add(e("in")),this._bymonth()),this.bymonthday?this._bymonthday():this.byweekday?this._byweekday():this.origOptions.byhour&&this._byhour()},r.prototype.WEEKLY=function(){var e=this.gettext;this.options.interval!==1&&this.add(this.options.interval.toString()).add(this.plural(this.options.interval)?e("weeks"):e("week")),this.byweekday&&this.byweekday.isWeekdays?this.options.interval===1?this.add(this.plural(this.options.interval)?e("weekdays"):e("weekday")):this.add(e("on")).add(e("weekdays")):this.byweekday&&this.byweekday.isEveryDay?this.add(this.plural(this.options.interval)?e("days"):e("day")):(this.options.interval===1&&this.add(e("week")),this.origOptions.bymonth&&(this.add(e("in")),this._bymonth()),this.bymonthday?this._bymonthday():this.byweekday&&this._byweekday())},r.prototype.MONTHLY=function(){var e=this.gettext;this.origOptions.bymonth?(this.options.interval!==1&&(this.add(this.options.interval.toString()).add(e("months")),this.plural(this.options.interval)&&this.add(e("in"))),this._bymonth()):(this.options.interval!==1&&this.add(this.options.interval.toString()),this.add(this.plural(this.options.interval)?e("months"):e("month"))),this.bymonthday?this._bymonthday():this.byweekday&&this.byweekday.isWeekdays?this.add(e("on")).add(e("weekdays")):this.byweekday&&this._byweekday()},r.prototype.YEARLY=function(){var e=this.gettext;this.origOptions.bymonth?(this.options.interval!==1&&(this.add(this.options.interval.toString()),this.add(e("years"))),this._bymonth()):(this.options.interval!==1&&this.add(this.options.interval.toString()),this.add(this.plural(this.options.interval)?e("years"):e("year"))),this.bymonthday?this._bymonthday():this.byweekday&&this._byweekday(),this.options.byyearday&&this.add(e("on the")).add(this.list(this.options.byyearday,this.nth,e("and"))).add(e("day")),this.options.byweekno&&this.add(e("in")).add(this.plural(this.options.byweekno.length)?e("weeks"):e("week")).add(this.list(this.options.byweekno,void 0,e("and")))},r.prototype._bymonthday=function(){var e=this.gettext;this.byweekday&&this.byweekday.allWeeks?this.add(e("on")).add(this.list(this.byweekday.allWeeks,this.weekdaytext,e("or"))).add(e("the")).add(this.list(this.bymonthday,this.nth,e("or"))):this.add(e("on the")).add(this.list(this.bymonthday,this.nth,e("and")))},r.prototype._byweekday=function(){var e=this.gettext;this.byweekday.allWeeks&&!this.byweekday.isWeekdays&&this.add(e("on")).add(this.list(this.byweekday.allWeeks,this.weekdaytext)),this.byweekday.someWeeks&&(this.byweekday.allWeeks&&this.add(e("and")),this.add(e("on the")).add(this.list(this.byweekday.someWeeks,this.weekdaytext,e("and"))))},r.prototype._byhour=function(){var e=this.gettext;this.add(e("at")).add(this.list(this.origOptions.byhour,void 0,e("and")))},r.prototype._bymonth=function(){this.add(this.list(this.options.bymonth,this.monthtext,this.gettext("and")))},r.prototype.nth=function(e){e=parseInt(e.toString(),10);var t,n=this.gettext;if(e===-1)return n("last");var i=Math.abs(e);switch(i){case 1:case 21:case 31:t=i+n("st");break;case 2:case 22:t=i+n("nd");break;case 3:case 23:t=i+n("rd");break;default:t=i+n("th")}return e<0?t+" "+n("last"):t},r.prototype.monthtext=function(e){return this.language.monthNames[e-1]},r.prototype.weekdaytext=function(e){var t=Ze(e)?(e+1)%7:e.getJsWeekday();return(e.n?this.nth(e.n)+" ":"")+this.language.dayNames[t]},r.prototype.plural=function(e){return e%100!==1},r.prototype.add=function(e){return this.text.push(" "),this.text.push(e),this},r.prototype.list=function(e,t,n,i){var s=this;i===void 0&&(i=","),Ce(e)||(e=[e]);var a=function(u,l,c){for(var d="",f=0;fe[0].length)&&(e=s,t=i)}if(e!=null&&(this.text=this.text.substr(e[0].length),this.text===""&&(this.done=!0)),e==null){this.done=!0,this.symbol=null,this.value=null;return}}while(t==="SKIP");return this.symbol=t,this.value=e,!0},r.prototype.accept=function(e){if(this.symbol===e){if(this.value){var t=this.value;return this.nextSymbol(),t}return this.nextSymbol(),!0}return!1},r.prototype.acceptNumber=function(){return this.accept("number")},r.prototype.expect=function(e){if(this.accept(e))return!0;throw new Error("expected "+e+" but found "+this.symbol)},r}();function Cn(r,e){e===void 0&&(e=Nr);var t={},n=new q_(e.tokens);if(!n.start(r))return null;return i(),t;function i(){n.expect("every");var f=n.acceptNumber();if(f&&(t.interval=parseInt(f[0],10)),n.isDone())throw new Error("Unexpected end");switch(n.symbol){case"day(s)":t.freq=w.DAILY,n.nextSymbol()&&(a(),d());break;case"weekday(s)":t.freq=w.WEEKLY,t.byweekday=[w.MO,w.TU,w.WE,w.TH,w.FR],n.nextSymbol(),d();break;case"week(s)":t.freq=w.WEEKLY,n.nextSymbol()&&(s(),d());break;case"hour(s)":t.freq=w.HOURLY,n.nextSymbol()&&(s(),d());break;case"minute(s)":t.freq=w.MINUTELY,n.nextSymbol()&&(s(),d());break;case"month(s)":t.freq=w.MONTHLY,n.nextSymbol()&&(s(),d());break;case"year(s)":t.freq=w.YEARLY,n.nextSymbol()&&(s(),d());break;case"monday":case"tuesday":case"wednesday":case"thursday":case"friday":case"saturday":case"sunday":t.freq=w.WEEKLY;var p=n.symbol.substr(0,2).toUpperCase();if(t.byweekday=[w[p]],!n.nextSymbol())return;for(;n.accept("comma");){if(n.isDone())throw new Error("Unexpected end");var y=u();if(!y)throw new Error("Unexpected symbol "+n.symbol+", expected weekday");t.byweekday.push(w[y]),n.nextSymbol()}c(),d();break;case"january":case"february":case"march":case"april":case"may":case"june":case"july":case"august":case"september":case"october":case"november":case"december":if(t.freq=w.YEARLY,t.bymonth=[o()],!n.nextSymbol())return;for(;n.accept("comma");){if(n.isDone())throw new Error("Unexpected end");var m=o();if(!m)throw new Error("Unexpected symbol "+n.symbol+", expected month");t.bymonth.push(m),n.nextSymbol()}s(),d();break;default:throw new Error("Unknown symbol")}}function s(){var f=n.accept("on"),p=n.accept("the");if(!!(f||p))do{var y=l(),m=u(),g=o();if(y)m?(n.nextSymbol(),t.byweekday||(t.byweekday=[]),t.byweekday.push(w[m].nth(y))):(t.bymonthday||(t.bymonthday=[]),t.bymonthday.push(y),n.accept("day(s)"));else if(m)n.nextSymbol(),t.byweekday||(t.byweekday=[]),t.byweekday.push(w[m]);else if(n.symbol==="weekday(s)")n.nextSymbol(),t.byweekday||(t.byweekday=[w.MO,w.TU,w.WE,w.TH,w.FR]);else if(n.symbol==="week(s)"){n.nextSymbol();var A=n.acceptNumber();if(!A)throw new Error("Unexpected symbol "+n.symbol+", expected week number");for(t.byweekno=[parseInt(A[0],10)];n.accept("comma");){if(A=n.acceptNumber(),!A)throw new Error("Unexpected symbol "+n.symbol+"; expected monthday");t.byweekno.push(parseInt(A[0],10))}}else if(g)n.nextSymbol(),t.bymonth||(t.bymonth=[]),t.bymonth.push(g);else return}while(n.accept("comma")||n.accept("the")||n.accept("on"))}function a(){var f=n.accept("at");if(!!f)do{var p=n.acceptNumber();if(!p)throw new Error("Unexpected symbol "+n.symbol+", expected hour");for(t.byhour=[parseInt(p[0],10)];n.accept("comma");){if(p=n.acceptNumber(),!p)throw new Error("Unexpected symbol "+n.symbol+"; expected hour");t.byhour.push(parseInt(p[0],10))}}while(n.accept("comma")||n.accept("at"))}function o(){switch(n.symbol){case"january":return 1;case"february":return 2;case"march":return 3;case"april":return 4;case"may":return 5;case"june":return 6;case"july":return 7;case"august":return 8;case"september":return 9;case"october":return 10;case"november":return 11;case"december":return 12;default:return!1}}function u(){switch(n.symbol){case"monday":case"tuesday":case"wednesday":case"thursday":case"friday":case"saturday":case"sunday":return n.symbol.substr(0,2).toUpperCase();default:return!1}}function l(){switch(n.symbol){case"last":return n.nextSymbol(),-1;case"first":return n.nextSymbol(),1;case"second":return n.nextSymbol(),n.accept("last")?-2:2;case"third":return n.nextSymbol(),n.accept("last")?-3:3;case"nth":var f=parseInt(n.value[1],10);if(f<-366||f>366)throw new Error("Nth out of range: "+f);return n.nextSymbol(),n.accept("last")?-f:f;default:return!1}}function c(){n.accept("on"),n.accept("the");var f=l();if(!!f)for(t.bymonthday=[f],n.nextSymbol();n.accept("comma");){if(f=l(),!f)throw new Error("Unexpected symbol "+n.symbol+"; expected monthday");t.bymonthday.push(f),n.nextSymbol()}}function d(){if(n.symbol==="until"){var f=Date.parse(n.text);if(!f)throw new Error("Cannot parse until date:"+n.text);t.until=new Date(f)}else n.accept("for")&&(t.count=parseInt(n.value[0],10),n.expect("number"))}}var Y;(function(r){r[r.YEARLY=0]="YEARLY",r[r.MONTHLY=1]="MONTHLY",r[r.WEEKLY=2]="WEEKLY",r[r.DAILY=3]="DAILY",r[r.HOURLY=4]="HOURLY",r[r.MINUTELY=5]="MINUTELY",r[r.SECONDLY=6]="SECONDLY"})(Y||(Y={}));function Sn(r){return r12){var n=Math.floor(this.month/12),i=Fe(this.month,12);this.month=i,this.year+=n,this.month===0&&(this.month=12,--this.year)}},e.prototype.addWeekly=function(t,n){n>this.getWeekday()?this.day+=-(this.getWeekday()+1+(6-n))+t*7:this.day+=-(this.getWeekday()-n)+t*7,this.fixDay()},e.prototype.addDaily=function(t){this.day+=t,this.fixDay()},e.prototype.addHours=function(t,n,i){for(n&&(this.hour+=Math.floor((23-this.hour)/t)*t);;){this.hour+=t;var s=ds(this.hour,24),a=s.div,o=s.mod;if(a&&(this.hour=o,this.addDaily(a)),Xe(i)||G(i,this.hour))break}},e.prototype.addMinutes=function(t,n,i,s){for(n&&(this.minute+=Math.floor((1439-(this.hour*60+this.minute))/t)*t);;){this.minute+=t;var a=ds(this.minute,60),o=a.div,u=a.mod;if(o&&(this.minute=u,this.addHours(o,!1,i)),(Xe(i)||G(i,this.hour))&&(Xe(s)||G(s,this.minute)))break}},e.prototype.addSeconds=function(t,n,i,s,a){for(n&&(this.second+=Math.floor((86399-(this.hour*3600+this.minute*60+this.second))/t)*t);;){this.second+=t;var o=ds(this.second,60),u=o.div,l=o.mod;if(u&&(this.second=l,this.addMinutes(u,!1,i,s)),(Xe(i)||G(i,this.hour))&&(Xe(s)||G(s,this.minute))&&(Xe(a)||G(a,this.second)))break}},e.prototype.fixDay=function(){if(!(this.day<=28)){var t=dr.monthRange(this.year,this.month-1)[1];if(!(this.day<=t))for(;this.day>t;){if(this.day-=t,++this.month,this.month===13&&(this.month=1,++this.year,this.year>dr.MAXYEAR))return;t=dr.monthRange(this.year,this.month-1)[1]}}},e.prototype.add=function(t,n){var i=t.freq,s=t.interval,a=t.wkst,o=t.byhour,u=t.byminute,l=t.bysecond;switch(i){case Y.YEARLY:return this.addYears(s);case Y.MONTHLY:return this.addMonths(s);case Y.WEEKLY:return this.addWeekly(s,a);case Y.DAILY:return this.addDaily(s);case Y.HOURLY:return this.addHours(s,n,o);case Y.MINUTELY:return this.addMinutes(s,n,o,u);case Y.SECONDLY:return this.addSeconds(s,n,o,u,l)}},e}(tn);function eo(r){for(var e=[],t=Object.keys(r),n=0,i=t;n=-366&&n<=366))throw new Error("bysetpos must be between 1 and 366, or between -366 and -1")}}if(!(Boolean(e.byweekno)||ye(e.byweekno)||ye(e.byyearday)||Boolean(e.bymonthday)||ye(e.bymonthday)||ue(e.byweekday)||ue(e.byeaster)))switch(e.freq){case w.YEARLY:e.bymonth||(e.bymonth=e.dtstart.getUTCMonth()+1),e.bymonthday=e.dtstart.getUTCDate();break;case w.MONTHLY:e.bymonthday=e.dtstart.getUTCDate();break;case w.WEEKLY:e.byweekday=[k.getWeekday(e.dtstart)];break}if(ue(e.bymonth)&&!Ce(e.bymonth)&&(e.bymonth=[e.bymonth]),ue(e.byyearday)&&!Ce(e.byyearday)&&Ze(e.byyearday)&&(e.byyearday=[e.byyearday]),!ue(e.bymonthday))e.bymonthday=[],e.bynmonthday=[];else if(Ce(e.bymonthday)){for(var i=[],s=[],t=0;t0?i.push(n):n<0&&s.push(n)}e.bymonthday=i,e.bynmonthday=s}else e.bymonthday<0?(e.bynmonthday=[e.bymonthday],e.bymonthday=[]):(e.bynmonthday=[],e.bymonthday=[e.bymonthday]);if(ue(e.byweekno)&&!Ce(e.byweekno)&&(e.byweekno=[e.byweekno]),!ue(e.byweekday))e.bynweekday=null;else if(Ze(e.byweekday))e.byweekday=[e.byweekday],e.bynweekday=null;else if(Xa(e.byweekday))e.byweekday=[_e.fromStr(e.byweekday).weekday],e.bynweekday=null;else if(e.byweekday instanceof _e)!e.byweekday.n||e.freq>w.MONTHLY?(e.byweekday=[e.byweekday.weekday],e.bynweekday=null):(e.bynweekday=[[e.byweekday.weekday,e.byweekday.n]],e.byweekday=null);else{for(var a=[],o=[],t=0;tw.MONTHLY?a.push(u.weekday):o.push([u.weekday,u.n])}e.byweekday=ye(a)?a:null,e.bynweekday=ye(o)?o:null}return ue(e.byhour)?Ze(e.byhour)&&(e.byhour=[e.byhour]):e.byhour=e.freq=4?(c=0,l=o.yearlen+Fe(a-e.wkst,7)):l=n-c;for(var d=Math.floor(l/7),f=Fe(l,7),p=Math.floor(d+f/4),y=0;y0&&m<=p){var g=void 0;m>1?(g=c+(m-1)*7,c!==u&&(g-=7-u)):g=c;for(var A=0;A<7&&(o.wnomask[g]=1,g++,o.wdaymask[g]!==e.wkst);A++);}}if(G(e.byweekno,1)){var g=c+p*7;if(c!==u&&(g-=7-u),g=4?(z=0,fe=ie+Fe(x-e.wkst,7)):fe=n-c,C=Math.floor(52+Fe(fe,7)/4)}if(G(e.byweekno,C))for(var g=0;gs)return Lt(r);if(C>=t){var x=Xf(C,e);if(!r.accept(x)||o&&(--o,!o))return Lt(r)}}else for(var A=p;As)return Lt(r);if(C>=t){var x=Xf(C,e);if(!r.accept(x)||o&&(--o,!o))return Lt(r)}}}if(e.interval===0||(u.add(e,m),u.year>k.MAXYEAR))return Lt(r);Sn(n)||(c=l.gettimeset(n)(u.hour,u.minute,u.second,0)),l.rebuild(u.year,u.month)}}function Z_(r,e,t){var n=t.bymonth,i=t.byweekno,s=t.byweekday,a=t.byeaster,o=t.bymonthday,u=t.bynmonthday,l=t.byyearday;return ye(n)&&!G(n,r.mmask[e])||ye(i)&&!r.wnomask[e]||ye(s)&&!G(s,r.wdaymask[e])||ye(r.nwdaymask)&&!r.nwdaymask[e]||a!==null&&!G(r.eastermask,e)||(ye(o)||ye(u))&&!G(o,r.mdaymask[e])&&!G(u,r.nmdaymask[e])||ye(l)&&(e=r.yearlen&&!G(l,e+1-r.yearlen)&&!G(l,-r.nextyearlen+e-r.yearlen))}function Xf(r,e){return new xr(r,e.tzid).rezonedDate()}function Lt(r){return r.getValue()}function X_(r,e,t,n,i){for(var s=!1,a=e;a=w.HOURLY&&ye(i)&&!G(i,e.hour)||n>=w.MINUTELY&&ye(s)&&!G(s,e.minute)||n>=w.SECONDLY&&ye(a)&&!G(a,e.second)?[]:r.gettimeset(n)(e.hour,e.minute,e.second,e.millisecond)}var nt={MO:new _e(0),TU:new _e(1),WE:new _e(2),TH:new _e(3),FR:new _e(4),SA:new _e(5),SU:new _e(6)},In={freq:Y.YEARLY,dtstart:null,interval:1,wkst:nt.MO,count:null,until:null,tzid:null,bysetpos:null,bymonth:null,bymonthday:null,bynmonthday:null,byyearday:null,byweekno:null,byweekday:null,bynweekday:null,byhour:null,byminute:null,bysecond:null,byeaster:null},Sf=Object.keys(In),w=function(){function r(e,t){e===void 0&&(e={}),t===void 0&&(t=!1),this._cache=t?null:new Ff,this.origOptions=eo(e);var n=xf(e).parsedOptions;this.options=n}return r.parseText=function(e,t){return Cn(e,t)},r.fromText=function(e,t){return Of(e,t)},r.fromString=function(e){return new r(r.parseString(e)||void 0)},r.prototype._iter=function(e){return ms(e,this.options)},r.prototype._cacheGet=function(e,t){return this._cache?this._cache._cacheGet(e,t):!1},r.prototype._cacheAdd=function(e,t,n){if(!!this._cache)return this._cache._cacheAdd(e,t,n)},r.prototype.all=function(e){if(e)return this._iter(new Ja("all",{},e));var t=this._cacheGet("all");return t===!1&&(t=this._iter(new Wt("all",{})),this._cacheAdd("all",t)),t},r.prototype.between=function(e,t,n,i){if(n===void 0&&(n=!1),!k.isValidDate(e)||!k.isValidDate(t))throw new Error("Invalid date passed in to RRule.between");var s={before:t,after:e,inc:n};if(i)return this._iter(new Ja("between",s,i));var a=this._cacheGet("between",s);return a===!1&&(a=this._iter(new Wt("between",s)),this._cacheAdd("between",a,s)),a},r.prototype.before=function(e,t){if(t===void 0&&(t=!1),!k.isValidDate(e))throw new Error("Invalid date passed in to RRule.before");var n={dt:e,inc:t},i=this._cacheGet("before",n);return i===!1&&(i=this._iter(new Wt("before",n)),this._cacheAdd("before",i,n)),i},r.prototype.after=function(e,t){if(t===void 0&&(t=!1),!k.isValidDate(e))throw new Error("Invalid date passed in to RRule.after");var n={dt:e,inc:t},i=this._cacheGet("after",n);return i===!1&&(i=this._iter(new Wt("after",n)),this._cacheAdd("after",i,n)),i},r.prototype.count=function(){return this.all().length},r.prototype.toString=function(){return qn(this.origOptions)},r.prototype.toText=function(e,t,n){return Af(this,e,t,n)},r.prototype.isFullyConvertibleToText=function(){return kf(this)},r.prototype.clone=function(){return new r(this.origOptions)},r.FREQUENCIES=["YEARLY","MONTHLY","WEEKLY","DAILY","HOURLY","MINUTELY","SECONDLY"],r.YEARLY=Y.YEARLY,r.MONTHLY=Y.MONTHLY,r.WEEKLY=Y.WEEKLY,r.DAILY=Y.DAILY,r.HOURLY=Y.HOURLY,r.MINUTELY=Y.MINUTELY,r.SECONDLY=Y.SECONDLY,r.MO=nt.MO,r.TU=nt.TU,r.WE=nt.WE,r.TH=nt.TH,r.FR=nt.FR,r.SA=nt.SA,r.SU=nt.SU,r.parseString=Fn,r.optionsToString=qn,r}();function Qf(r,e,t,n,i,s){var a={},o=r.accept;function u(f,p){t.forEach(function(y){y.between(f,p,!0).forEach(function(m){a[Number(m)]=!0})})}i.forEach(function(f){var p=new xr(f,s).rezonedDate();a[Number(p)]=!0}),r.accept=function(f){var p=Number(f);return isNaN(p)?o.call(this,f):!a[p]&&(u(new Date(p-1),new Date(p+1)),!a[p])?(a[p]=!0,o.call(this,f)):!0},r.method==="between"&&(u(r.args.after,r.args.before),r.accept=function(f){var p=Number(f);return a[p]?!0:(a[p]=!0,o.call(this,f))});for(var l=0;l1||i.length||s.length||a.length){var c=new no(l);return c.dtstart(o),c.tzid(u||void 0),n.forEach(function(f){c.rrule(new w(ro(f,o,u),l))}),i.forEach(function(f){c.rdate(f)}),s.forEach(function(f){c.exrule(new w(ro(f,o,u),l))}),a.forEach(function(f){c.exdate(f)}),e.compatible&&e.dtstart&&c.rdate(o),c}var d=n[0]||{};return new w(ro(d,d.dtstart||e.dtstart||o,d.tzid||e.tzid||u),l)}function ys(r,e){return e===void 0&&(e={}),eT(r,tT(e))}function ro(r,e,t){return je(je({},r),{dtstart:e,tzid:t})}function tT(r){var e=[],t=Object.keys(r),n=Object.keys(Jf);if(t.forEach(function(i){G(n,i)||e.push(i)}),e.length)throw new Error("Invalid options: "+e.join(", "));return je(je({},Jf),r)}function rT(r){if(r.indexOf(":")===-1)return{name:"RRULE",value:r};var e=rf(r,":",1),t=e[0],n=e[1];return{name:t,value:n}}function nT(r){var e=rT(r),t=e.name,n=e.value,i=t.split(";");if(!i)throw new Error("empty property name");return{name:i[0].toUpperCase(),parms:i.slice(1),value:n}}function iT(r,e){if(e===void 0&&(e=!1),r=r&&r.trim(),!r)throw new Error("Invalid empty string");if(!e)return r.split(/\s/);for(var t=r.split(` +`),n=0;n0&&i[0]===" "?(t[n-1]+=i.slice(1),t.splice(n,1)):n+=1:t.splice(n,1)}return t}function sT(r){r.forEach(function(e){if(!/(VALUE=DATE(-TIME)?)|(TZID=)/.test(e))throw new Error("unsupported RDATE/EXDATE parm: "+e)})}function ep(r,e){return sT(e),r.split(",").map(function(t){return k.untilStringToDate(t)})}function tp(r){var e=this;return function(t){if(t!==void 0&&(e["_".concat(r)]=t),e["_".concat(r)]!==void 0)return e["_".concat(r)];for(var n=0;ne(t,n)*-1}static makeCompositeComparator(e){return(t,n)=>{for(let i of e){let s=i(t,n);if(s!==0)return s}return 0}}static compareByUrgency(e,t){return t.urgency-e.urgency}static compareByStatus(e,t){return e.statust.status?-1:0}static compareByPriority(e,t){return e.priority.localeCompare(t.priority)}static compareByStartDate(e,t){return H.compareByDate(e.startDate,t.startDate)}static compareByScheduledDate(e,t){return H.compareByDate(e.scheduledDate,t.scheduledDate)}static compareByDueDate(e,t){return H.compareByDate(e.dueDate,t.dueDate)}static compareByDoneDate(e,t){return H.compareByDate(e.doneDate,t.doneDate)}static compareByTag(e,t){if(e.tags.length===0&&t.tags.length===0)return 0;if(e.tags.length===0)return 1;if(t.tags.length===0)return-1;let n=H.tagPropertyInstance-1;return e.tags.length=H.tagPropertyInstance?1:t.tags.length=H.tagPropertyInstance?-1:e.tags.lengtht.tags[n]?1:0}static compareByDate(e,t){return e!==null&&t===null?-1:e===null&&t!==null?1:e!==null&&t!==null?e.isAfter(t)?1:e.isBefore(t)?-1:0:0}static compareByPath(e,t){return e.patht.path?1:0}static compareByDescription(e,t){return H.cleanDescription(e.description).localeCompare(H.cleanDescription(t.description))}static cleanDescription(e){let t=ie().globalFilter;e=e.replace(t,"").trim();let n=/^\[\[?([^\]]*)\]/,i=e.match(n);if(i!==null){let l=i[1];e=l.substring(l.indexOf("|")+1)+e.replace(n,"")}let s=/^\*\*?([^*]*)\*/,a=e.match(s);a!==null&&(e=a[1]+e.replace(n,""));let o=/^==?([^=]*)==/,u=e.match(o);return u!==null&&(e=u[1]+e.replace(o,"")),e}},Ge=H;Ge.tagPropertyInstance=1,Ge.comparators={urgency:H.compareByUrgency,description:H.compareByDescription,priority:H.compareByPriority,start:H.compareByStartDate,scheduled:H.compareByScheduledDate,due:H.compareByDueDate,done:H.compareByDoneDate,path:H.compareByPath,status:H.compareByStatus,tag:H.compareByTag};var pt=class{constructor({rrule:e,baseOnToday:t,referenceDate:n,startDate:i,scheduledDate:s,dueDate:a}){this.rrule=e,this.baseOnToday=t,this.referenceDate=n,this.startDate=i,this.scheduledDate=s,this.dueDate=a}static fromText({recurrenceRuleText:e,startDate:t,scheduledDate:n,dueDate:i}){try{let s=e.match(/^([a-zA-Z0-9, !]+?)( when done)?$/i);if(s==null)return null;let a=s[1].trim(),o=s[2]!==void 0,u=w.parseText(a);if(u!==null){let l=null;i?l=window.moment(i):n?l=window.moment(n):t&&(l=window.moment(t)),!o&&l!==null?u.dtstart=window.moment(l).startOf("day").utc(!0).toDate():u.dtstart=window.moment().startOf("day").utc(!0).toDate();let c=new w(u);return new pt({rrule:c,baseOnToday:o,referenceDate:l,startDate:t,scheduledDate:n,dueDate:i})}}catch(s){}return null}toText(){let e=this.rrule.toText();return this.baseOnToday&&(e+=" when done"),e}next(){var t;let e;if(this.baseOnToday){let n=window.moment();e=new w(Ut($e({},this.rrule.origOptions),{dtstart:n.startOf("day").utc(!0).toDate()})).after(n.endOf("day").utc(!0).toDate())}else{let n=window.moment((t=this.referenceDate)!=null?t:void 0).endOf("day").utc(!0);e=this.rrule.after(n.toDate())}if(e!==null){let i=window.moment.utc(e).local(!0).startOf("day"),s=null,a=null,o=null;if(this.referenceDate){if(this.startDate){let u=window.moment.duration(this.startDate.diff(this.referenceDate));s=window.moment(i),s.add(Math.round(u.asDays()),"days")}if(this.scheduledDate){let u=window.moment.duration(this.scheduledDate.diff(this.referenceDate));a=window.moment(i),a.add(Math.round(u.asDays()),"days")}if(this.dueDate){let u=window.moment.duration(this.dueDate.diff(this.referenceDate));o=window.moment(i),o.add(Math.round(u.asDays()),"days")}}return{startDate:s,scheduledDate:a,dueDate:o}}return null}identicalTo(e){return this.baseOnToday!==e.baseOnToday||Ge.compareByDate(this.startDate,e.startDate)!==0||Ge.compareByDate(this.scheduledDate,e.scheduledDate)!==0||Ge.compareByDate(this.dueDate,e.dueDate)!==0?!1:this.toText()===e.toText()}};var Yt=class{static calculate(e){let t=0;if(e.dueDate!==null){let n=Math.round(window.moment().diff(e.dueDate)/Yt.milliSecondsPerDay),i;n>=7?i=1:n>=-14?i=(n+14)*.8/21+.2:i=.2,t+=i*Yt.dueCoefficient}switch(e.scheduledDate!==null&&window.moment().isSameOrAfter(e.scheduledDate)&&(t+=1*Yt.scheduledCoefficient),e.startDate!==null&&window.moment().isBefore(e.startDate)&&(t+=1*Yt.startedCoefficient),e.priority){case"1":t+=1*Yt.priorityCoefficient;break;case"2":t+=.65*Yt.priorityCoefficient;break;case"3":t+=.325*Yt.priorityCoefficient;break}return t}},Lt=Yt;Lt.dueCoefficient=12,Lt.scheduledCoefficient=5,Lt.startedCoefficient=-3,Lt.priorityCoefficient=6,Lt.milliSecondsPerDay=1e3*60*60*24;var Re={High:"\u23EB",Medium:"\u{1F53C}",Low:"\u{1F53D}",None:""},Rt="\u{1F501}",wt="\u{1F6EB}",Mt="\u23F3",Dt="\u{1F4C5}",no="\u2705",I=class{constructor({status:e,description:t,path:n,indentation:i,sectionStart:s,sectionIndex:a,originalStatusCharacter:o,precedingHeader:u,priority:l,startDate:c,scheduledDate:d,dueDate:f,doneDate:p,recurrence:y,blockLink:m,tags:g}){this._urgency=null;this.status=e,this.description=t,this.path=n,this.indentation=i,this.sectionStart=s,this.sectionIndex=a,this.originalStatusCharacter=o,this.precedingHeader=u,this.tags=g,this.priority=l,this.startDate=c,this.scheduledDate=d,this.dueDate=f,this.doneDate=p,this.recurrence=y,this.blockLink=m}static fromLine({line:e,path:t,sectionStart:n,sectionIndex:i,precedingHeader:s}){let a=e.match(I.taskRegex);if(a===null)return null;let o=a[3].trim(),{globalFilter:u}=ie();if(!o.includes(u))return null;let l=o,c=a[1],d=a[2].toLowerCase(),f;switch(d){case" ":f="Todo";break;default:f="Done"}let p=l.match(this.blockLinkRegex),y=p!==null?p[0]:"";y!==""&&(l=l.replace(this.blockLinkRegex,"").trim());let m,g="3",A=null,x=null,C=null,z=null,ne="",fe=null,ee=[],M="",ge=20,ce=0;do{m=!1;let v=l.match(I.priorityRegex);if(v!==null){switch(v[1]){case Re.Low:g="4";break;case Re.Medium:g="2";break;case Re.High:g="1";break}l=l.replace(I.priorityRegex,"").trim(),m=!0}let _=l.match(I.doneDateRegex);_!==null&&(z=window.moment(_[1],I.dateFormat),l=l.replace(I.doneDateRegex,"").trim(),m=!0);let P=l.match(I.dueDateRegex);P!==null&&(C=window.moment(P[1],I.dateFormat),l=l.replace(I.dueDateRegex,"").trim(),m=!0);let E=l.match(I.scheduledDateRegex);E!==null&&(x=window.moment(E[1],I.dateFormat),l=l.replace(I.scheduledDateRegex,"").trim(),m=!0);let S=l.match(I.startDateRegex);S!==null&&(A=window.moment(S[1],I.dateFormat),l=l.replace(I.startDateRegex,"").trim(),m=!0);let O=l.match(I.recurrenceRegex);O!==null&&(ne=O[1].trim(),l=l.replace(I.recurrenceRegex,"").trim(),m=!0);let W=l.match(I.hashTagsFromEnd);if(W!=null){l=l.replace(I.hashTagsFromEnd,"").trim(),m=!0;let te=W[0].trim();M=M.length>0?[te,M].join(" "):te}ce++}while(m&&ce<=ge);ne.length>0&&(fe=pt.fromText({recurrenceRuleText:ne,startDate:A,scheduledDate:x,dueDate:C})),M.length>0&&(l+=" "+M);let D=l.match(this.hashTags);return D!==null&&(ee=D.filter(v=>v!==u).map(v=>v.trim())),new I({status:f,description:l,path:t,indentation:c,sectionStart:n,sectionIndex:i,originalStatusCharacter:d,precedingHeader:s,priority:g,startDate:A,scheduledDate:x,dueDate:C,doneDate:z,recurrence:fe,blockLink:y,tags:ee})}toLi(s){return ae(this,arguments,function*({parentUlElement:e,listIndex:t,layoutOptions:n,isFilenameUnique:i}){let a=e.createEl("li");a.addClasses(["task-list-item","plugin-tasks-list-item"]);let o=this.toString(n),{globalFilter:u,removeGlobalFilter:l}=ie();l&&(o=o.replace(u,"").trim());let c=a.createSpan();c.addClass("tasks-list-text"),yield rp.MarkdownRenderer.renderMarkdown(o,c,this.path,null);let d=c.querySelector("blockquote"),f=d!=null?d:c,p=f.querySelector("p");if(p!==null){for(;p.firstChild;)f.insertBefore(p.firstChild,p);p.remove()}c.findAll("p").forEach(m=>{m.hasChildNodes()||m.remove()}),c.findAll(".footnotes").forEach(m=>{m.remove()});let y=a.createEl("input");return y.addClass("task-list-item-checkbox"),y.type="checkbox",this.status!=="Todo"&&(y.checked=!0,a.addClass("is-checked")),y.onClickEvent(m=>{m.preventDefault(),m.stopPropagation(),y.disabled=!0;let g=this.toggle();us({originalTask:this,newTasks:g})}),a.prepend(y),a.setAttr("data-task",this.originalStatusCharacter.trim()),a.setAttr("data-line",t),y.setAttr("data-line",t),n!=null&&n.shortMode&&this.addTooltip({element:c,isFilenameUnique:i}),a})}toString(e){var i;e=e!=null?e:new Zr;let t=this.description;if(!e.hidePriority){let s="";this.priority==="1"?s=" "+Re.High:this.priority==="2"?s=" "+Re.Medium:this.priority==="4"&&(s=" "+Re.Low),t+=s}return!e.hideRecurrenceRule&&this.recurrence&&(t+=e.shortMode?" "+Rt:` ${Rt} ${this.recurrence.toText()}`),!e.hideStartDate&&this.startDate&&(t+=e.shortMode?" "+wt:` ${wt} ${this.startDate.format(I.dateFormat)}`),!e.hideScheduledDate&&this.scheduledDate&&(t+=e.shortMode?" "+Mt:` ${Mt} ${this.scheduledDate.format(I.dateFormat)}`),!e.hideDueDate&&this.dueDate&&(t+=e.shortMode?" "+Dt:` ${Dt} ${this.dueDate.format(I.dateFormat)}`),!e.hideDoneDate&&this.doneDate&&(t+=e.shortMode?" "+no:` ${no} ${this.doneDate.format(I.dateFormat)}`),t+=(i=this.blockLink)!=null?i:"",t}toFileLineString(){return`${this.indentation}- [${this.originalStatusCharacter}] ${this.toString()}`}toggle(){let e=this.status==="Todo"?"Done":"Todo",t=null,n=null;if(e!=="Todo"){let{setDoneDate:a}=ie();a&&(t=window.moment()),this.recurrence!==null&&(n=this.recurrence.next())}let i=new I(Ut($e({},this),{status:e,doneDate:t,originalStatusCharacter:e==="Done"?"x":" "})),s=[];if(n!==null){let a=new I(Ut($e($e({},this),n),{blockLink:""}));s.push(a)}return s.push(i),s}get urgency(){return this._urgency===null&&(this._urgency=Lt.calculate(this)),this._urgency}get filename(){let e=this.path.match(/([^/]+)\.md$/);return e!==null?e[1]:null}getLinkText({isFilenameUnique:e}){let t;return e?t=this.filename:t="/"+this.path,t===null?null:(this.precedingHeader!==null&&this.precedingHeader!==t&&(t=t+" > "+this.precedingHeader),t)}static tasksListsIdentical(e,t){return e.length!==t.length?!1:e.every((n,i)=>n.identicalTo(t[i]))}identicalTo(e){let t=["status","description","path","indentation","sectionStart","sectionIndex","originalStatusCharacter","precedingHeader","priority","blockLink"];for(let s of t)if(this[s]!==e[s])return!1;if(this.tags.length!==e.tags.length||!this.tags.every(function(s,a){return s===e.tags[a]}))return!1;t=["startDate","scheduledDate","dueDate","doneDate"];for(let s of t){let a=this[s],o=e[s];if(Ge.compareByDate(a,o)!==0)return!1}let n=this.recurrence,i=e.recurrence;return n===null&&i!==null||n!==null&&i===null?!1:!(n&&i&&!n.identicalTo(i))}addTooltip({element:e,isFilenameUnique:t}){e.addEventListener("mouseenter",()=>{let n=e.createDiv();n.addClasses(["tooltip","mod-right"]),this.recurrence&&n.createDiv().setText(`${Rt} ${this.recurrence.toText()}`),this.startDate&&n.createDiv().setText(I.toTooltipDate({signifier:wt,date:this.startDate})),this.scheduledDate&&n.createDiv().setText(I.toTooltipDate({signifier:Mt,date:this.scheduledDate})),this.dueDate&&n.createDiv().setText(I.toTooltipDate({signifier:Dt,date:this.dueDate})),this.doneDate&&n.createDiv().setText(I.toTooltipDate({signifier:no,date:this.doneDate}));let i=this.getLinkText({isFilenameUnique:t});i&&n.createDiv().setText(`\u{1F517} ${i}`),e.addEventListener("mouseleave",()=>{n.remove()})})}static toTooltipDate({signifier:e,date:t}){return`${e} ${t.format(I.dateFormat)} (${t.from(window.moment().startOf("day"))})`}escapeRegExp(e){return e.replace(/([.*+?^${}()|[\]/\\])/g,"\\$1")}getDescriptionWithoutGlobalFilter(){let{globalFilter:e}=ie(),t=this.description;if(e.length===0)return t;let n=RegExp("(^|\\s)"+this.escapeRegExp(e)+"($|\\s)","ug");return this.description.search(n)>-1&&(t=t.replace(n,"$1$2").replace(" "," ").trim()),t}},N=I;N.dateFormat="YYYY-MM-DD",N.indentationRegex=/^([\s\t>]*)/,N.listMarkerRegex=/[-*]/,N.checkboxRegex=/\[(.)\]/u,N.afterCheckboxRegex=/ *(.*)/u,N.taskRegex=new RegExp(I.indentationRegex.source+I.listMarkerRegex.source+" +"+I.checkboxRegex.source+I.afterCheckboxRegex.source,"u"),N.nonTaskRegex=new RegExp(I.indentationRegex.source+I.listMarkerRegex.source+"? *("+I.checkboxRegex.source+")?"+I.afterCheckboxRegex.source,"u"),N.listItemRegex=new RegExp(I.indentationRegex.source+"("+I.listMarkerRegex.source+")"),N.blockLinkRegex=/ \^[a-zA-Z0-9-]+$/u,N.priorityRegex=/([⏫🔼🔽])$/u,N.startDateRegex=/🛫 *(\d{4}-\d{2}-\d{2})$/u,N.scheduledDateRegex=/[⏳⌛] *(\d{4}-\d{2}-\d{2})$/u,N.dueDateRegex=/[📅📆🗓] *(\d{4}-\d{2}-\d{2})$/u,N.doneDateRegex=/✅ *(\d{4}-\d{2}-\d{2})$/u,N.recurrenceRegex=/🔁 ?([a-zA-Z0-9, !]+)$/iu,N.hashTags=/(^|\s)#[^ !@#$%^&*(),.?":{}|<>]*/g,N.hashTagsFromEnd=new RegExp(I.hashTags.source+"$");var pr=class{constructor({metadataCache:e,vault:t,events:n}){this.metadataCache=e,this.metadataCacheEventReferences=[],this.vault=t,this.vaultEventReferences=[],this.events=n,this.eventsEventReferences=[],this.tasksMutex=new os,this.state="Cold",this.tasks=[],this.loadedAfterFirstResolve=!1,this.subscribeToCache(),this.subscribeToVault(),this.subscribeToEvents(),this.loadVault()}unload(){for(let e of this.metadataCacheEventReferences)this.metadataCache.offref(e);for(let e of this.vaultEventReferences)this.vault.offref(e);for(let e of this.eventsEventReferences)this.events.off(e)}getTasks(){return this.tasks}getState(){return this.state}notifySubscribers(){this.events.triggerCacheUpdate({tasks:this.tasks,state:this.state})}subscribeToCache(){let e=this.metadataCache.on("resolved",()=>ae(this,null,function*(){this.loadedAfterFirstResolve||(this.loadedAfterFirstResolve=!0,this.loadVault())}));this.metadataCacheEventReferences.push(e);let t=this.metadataCache.on("changed",n=>{this.tasksMutex.runExclusive(()=>{this.indexFile(n)})});this.metadataCacheEventReferences.push(t)}subscribeToVault(){let e=this.vault.on("create",i=>{i instanceof ys.TFile&&this.tasksMutex.runExclusive(()=>{this.indexFile(i)})});this.vaultEventReferences.push(e);let t=this.vault.on("delete",i=>{i instanceof ys.TFile&&this.tasksMutex.runExclusive(()=>{this.tasks=this.tasks.filter(s=>s.path!==i.path),this.notifySubscribers()})});this.vaultEventReferences.push(t);let n=this.vault.on("rename",(i,s)=>{i instanceof ys.TFile&&this.tasksMutex.runExclusive(()=>{this.tasks=this.tasks.map(a=>a.path===s?new N(Ut($e({},a),{path:i.path})):a),this.notifySubscribers()})});this.vaultEventReferences.push(n)}subscribeToEvents(){let e=this.events.onRequestCacheUpdate(t=>{t({tasks:this.tasks,state:this.state})});this.eventsEventReferences.push(e)}loadVault(){return this.tasksMutex.runExclusive(()=>ae(this,null,function*(){this.state="Initializing",yield Promise.all(this.vault.getMarkdownFiles().map(e=>this.indexFile(e))),this.state="Warm",this.notifySubscribers()}))}indexFile(e){return ae(this,null,function*(){let t=this.metadataCache.getFileCache(e);if(t==null)return;let n=this.tasks.filter(a=>a.path===e.path),i=t.listItems,s=[];if(i!==void 0){let a=yield this.vault.cachedRead(e);s=pr.getTasksFromFileContent(a,i,t,e)}N.tasksListsIdentical(n,s)||(this.getState()=="Warm"&&console.debug(`At least one task, its line number or its heading has changed in ${e.path}: triggering a refresh of all active Tasks blocks in Live Preview and Reading mode views.`),this.tasks=this.tasks.filter(a=>a.path!==e.path),this.tasks.push(...s),this.notifySubscribers())})}static getTasksFromFileContent(e,t,n,i){let s=[],a=e.split(` -`),o=null,u=0;for(let l of t)if(l.task!==void 0){if((o===null||o.position.end.line=e)return n;return null}static getPrecedingHeader(e,t){if(t===void 0)return null;let n=null;for(let i of t){if(i.position.start.line>e)return n;n=i.heading}return n}};var nd=require("obsidian");var zg=require("obsidian");function tn(){}function ao(r){return r()}function ip(){return Object.create(null)}function xr(r){r.forEach(ao)}function ap(r){return typeof r=="function"}function op(r,e){return r!=r?e==e:r!==e||r&&typeof r=="object"||typeof r=="function"}function up(r){return Object.keys(r).length===0}var lp=!1;function nT(){lp=!0}function iT(){lp=!1}function b(r,e){r.appendChild(e)}function oo(r,e,t){r.insertBefore(e,t||null)}function vs(r){r.parentNode.removeChild(r)}function U(r){return document.createElement(r)}function sT(r){return document.createElementNS("http://www.w3.org/2000/svg",r)}function $t(r){return document.createTextNode(r)}function Z(){return $t(" ")}function hr(r,e,t,n){return r.addEventListener(e,t,n),()=>r.removeEventListener(e,t,n)}function cp(r){return function(e){return e.preventDefault(),r.call(this,e)}}function $(r,e,t){t==null?r.removeAttribute(e):r.getAttribute(e)!==t&&r.setAttribute(e,t)}function aT(r){return Array.from(r.childNodes)}function dp(r,e){e=""+e,r.wholeText!==e&&(r.data=e)}function ht(r,e){r.value=e==null?"":e}function uo(r,e){for(let t=0;t{let u=s.map(ao).filter(ap);a?a.push(...u):xr(u),r.$$.on_mount=[]}),o.forEach(Yn)}function hp(r,e){let t=r.$$;t.fragment!==null&&(xr(t.on_destroy),t.fragment&&t.fragment.d(e),t.on_destroy=t.fragment=null,t.ctx=[])}function hT(r,e){r.$$.dirty[0]===-1&&(qn.push(r),lT(),r.$$.dirty.fill(0)),r.$$.dirty[e/31|0]|=1<{let y=p.length?p[0]:f;return l.ctx&&i(l.ctx[d],l.ctx[d]=y)&&(!l.skip_bound&&l.bound[d]&&l.bound[d](y),c&&hT(r,d)),f}):[],l.update(),c=!0,xr(l.before_update),l.fragment=n?n(l.ctx):!1,e.target){if(e.hydrate){nT();let d=aT(e.target);l.fragment&&l.fragment.l(d),d.forEach(vs)}else l.fragment&&l.fragment.c();e.intro&&fT(r.$$.fragment),pT(r,e.target,e.anchor,e.customElement),iT(),pp()}Wn(u)}var mT;typeof HTMLElement=="function"&&(mT=class extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"})}connectedCallback(){let{on_mount:r}=this.$$;this.$$.on_disconnect=r.map(ao).filter(ap);for(let e in this.$$.slotted)this.appendChild(this.$$.slotted[e])}attributeChangedCallback(r,e,t){this[r]=t}disconnectedCallback(){xr(this.$$.on_disconnect)}$destroy(){hp(this,1),this.$destroy=tn}$on(r,e){let t=this.$$.callbacks[r]||(this.$$.callbacks[r]=[]);return t.push(e),()=>{let n=t.indexOf(e);n!==-1&&t.splice(n,1)}}$set(r){this.$$set&&!up(r)&&(this.$$.skip_bound=!0,this.$$set(r),this.$$.skip_bound=!1)}});var bs=class{$destroy(){hp(this,1),this.$destroy=tn}$on(e,t){let n=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return n.push(t),()=>{let i=n.indexOf(t);i!==-1&&n.splice(i,1)}}$set(e){this.$$set&&!up(e)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}};var $i=as(Ee());var xO={td:"today",tm:"tomorrow",yd:"yesterday",tw:"this week",nw:"next week",weekend:"sat",we:"sat"};function Tn(r){for(let[e,t]of Object.entries(xO))r=r.replace(RegExp(`\\b${e}\\s`,"i"),t);return r}function SO(r){let e,t,n,i,s,a,o,u,l,c,d,f,p,y,m,g,A,x,C,z,ne,fe,ee,M,ge,ce,D,v,_,P,E,S,O,W,te,ue,se,dt,Le,ar,or,ft,Ne,Ce,ur,Pr,St,wd,An,Md,Dd,Qi,Pd,lr,Ji,Od,It,Ad,kn,kd,Nd,es,Cd,xd,Sd,Kr,Vr,Id,Or,ts,Ud,$a,rs=r[0].status+"",ja,Fd,ns,qd,is,Wd,Ld,Yd,Ba,$d,ss,Ga,jd;return{c(){e=U("div"),t=U("form"),n=U("div"),i=U("label"),i.textContent="Description",s=Z(),a=U("input"),o=Z(),u=U("hr"),l=Z(),c=U("div"),d=U("label"),d.textContent="Priority",f=Z(),p=U("select"),y=U("option"),y.textContent="None",m=U("option"),m.textContent=`${Re.High} High`,g=U("option"),g.textContent=`${Re.Medium} Medium`,A=U("option"),A.textContent=`${Re.Low} Low`,x=Z(),C=U("hr"),z=Z(),ne=U("div"),fe=U("label"),fe.textContent="Recurrence",ee=Z(),M=U("input"),ge=Z(),ce=U("code"),D=$t(Rt),v=Z(),_=new Cr(!1),P=Z(),E=U("hr"),S=Z(),O=U("div"),W=U("div"),te=U("label"),te.textContent="Due",ue=Z(),se=U("input"),dt=Z(),Le=U("code"),ar=$t(Dt),or=Z(),ft=new Cr(!1),Ne=Z(),Ce=U("div"),ur=U("label"),ur.textContent="Scheduled",Pr=Z(),St=U("input"),wd=Z(),An=U("code"),Md=$t(Mt),Dd=Z(),Qi=new Cr(!1),Pd=Z(),lr=U("div"),Ji=U("label"),Ji.textContent="Start",Od=Z(),It=U("input"),Ad=Z(),kn=U("code"),kd=$t(wt),Nd=Z(),es=new Cr(!1),Cd=Z(),xd=U("hr"),Sd=Z(),Kr=U("div"),Vr=U("div"),Id=$t(`Status: - `),Or=U("input"),Ud=Z(),$a=U("code"),ja=$t(rs),Fd=Z(),ns=U("div"),qd=$t(`Done on: - `),is=U("code"),Wd=Z(),Ld=U("hr"),Yd=Z(),Ba=U("div"),$d=Z(),ss=U("div"),ss.innerHTML='',$(i,"for","description"),$(a,"id","description"),$(a,"type","text"),$(a,"class","tasks-modal-description"),$(a,"placeholder","Take out the trash"),$(n,"class","tasks-modal-section"),$(d,"for","priority"),y.__value="none",y.value=y.__value,m.__value="high",m.value=m.__value,g.__value="medium",g.value=g.__value,A.__value="low",A.value=A.__value,$(p,"id","priority"),$(p,"class","dropdown"),r[0].priority===void 0&&Yn(()=>r[14].call(p)),$(c,"class","tasks-modal-section"),$(fe,"for","recurrence"),$(M,"id","description"),$(M,"type","text"),$(M,"placeholder","Try 'every 2 weeks on Thursday'."),_.a=null,$(ne,"class","tasks-modal-section"),$(te,"for","due"),$(se,"id","due"),$(se,"type","text"),$(se,"placeholder",ed),ft.a=null,$(W,"class","tasks-modal-date"),$(ur,"for","scheduled"),$(St,"id","scheduled"),$(St,"type","text"),$(St,"placeholder",ed),Qi.a=null,$(Ce,"class","tasks-modal-date"),$(Ji,"for","start"),$(It,"id","start"),$(It,"type","text"),$(It,"placeholder",ed),es.a=null,$(lr,"class","tasks-modal-date"),$(O,"class","tasks-modal-section"),$(Or,"type","checkbox"),$(Or,"class","task-list-item-checkbox tasks-modal-checkbox"),Or.checked=ts=r[0].status==="Done",Or.disabled=!0,$(Kr,"class","tasks-modal-section"),$(Ba,"class","tasks-modal-section"),$(ss,"class","tasks-modal-section"),$(e,"class","tasks-modal")},m(pe,Ye){oo(pe,e,Ye),b(e,t),b(t,n),b(n,i),b(n,s),b(n,a),ht(a,r[0].description),r[13](a),b(t,o),b(t,u),b(t,l),b(t,c),b(c,d),b(c,f),b(c,p),b(p,y),b(p,m),b(p,g),b(p,A),uo(p,r[0].priority),b(t,x),b(t,C),b(t,z),b(t,ne),b(ne,fe),b(ne,ee),b(ne,M),ht(M,r[0].recurrenceRule),b(ne,ge),b(ne,ce),b(ce,D),b(ce,v),_.m(r[5],ce),b(t,P),b(t,E),b(t,S),b(t,O),b(O,W),b(W,te),b(W,ue),b(W,se),ht(se,r[0].dueDate),b(W,dt),b(W,Le),b(Le,ar),b(Le,or),ft.m(r[4],Le),b(O,Ne),b(O,Ce),b(Ce,ur),b(Ce,Pr),b(Ce,St),ht(St,r[0].scheduledDate),b(Ce,wd),b(Ce,An),b(An,Md),b(An,Dd),Qi.m(r[3],An),b(O,Pd),b(O,lr),b(lr,Ji),b(lr,Od),b(lr,It),ht(It,r[0].startDate),b(lr,Ad),b(lr,kn),b(kn,kd),b(kn,Nd),es.m(r[2],kn),b(t,Cd),b(t,xd),b(t,Sd),b(t,Kr),b(Kr,Vr),b(Vr,Id),b(Vr,Or),b(Vr,Ud),b(Vr,$a),b($a,ja),b(Kr,Fd),b(Kr,ns),b(ns,qd),b(ns,is),is.innerHTML=r[6],b(t,Wd),b(t,Ld),b(t,Yd),b(t,Ba),b(t,$d),b(t,ss),Ga||(jd=[hr(a,"input",r[12]),hr(p,"change",r[14]),hr(M,"input",r[15]),hr(se,"input",r[16]),hr(St,"input",r[17]),hr(It,"input",r[18]),hr(t,"submit",cp(r[7]))],Ga=!0)},p(pe,[Ye]){Ye&1&&a.value!==pe[0].description&&ht(a,pe[0].description),Ye&1&&uo(p,pe[0].priority),Ye&1&&M.value!==pe[0].recurrenceRule&&ht(M,pe[0].recurrenceRule),Ye&32&&_.p(pe[5]),Ye&1&&se.value!==pe[0].dueDate&&ht(se,pe[0].dueDate),Ye&16&&ft.p(pe[4]),Ye&1&&St.value!==pe[0].scheduledDate&&ht(St,pe[0].scheduledDate),Ye&8&&Qi.p(pe[3]),Ye&1&&It.value!==pe[0].startDate&&ht(It,pe[0].startDate),Ye&4&&es.p(pe[2]),Ye&1&&ts!==(ts=pe[0].status==="Done")&&(Or.checked=ts),Ye&1&&rs!==(rs=pe[0].status+"")&&dp(ja,rs),Ye&64&&(is.innerHTML=pe[6])},i:tn,o:tn,d(pe){pe&&vs(e),r[13](null),Ga=!1,xr(jd)}}}var ed="Try 'Monday' or 'tomorrow', or [td|tm|yd|tw|nw|we] then space.";function IO(r,e,t){var n,i;let{task:s}=e,{onSubmit:a}=e,o,u={description:"",status:"Todo",priority:"none",recurrenceRule:"",startDate:"",scheduledDate:"",dueDate:"",doneDate:""},l="",c="",d="",f="",p="",y=!1;function m(M,ge,ce=void 0){if(!ge)return`no ${M} date`;let D=$i.parseDate(ge,ce,{forwardDate:ce!=null});return D!==null?window.moment(D).format("YYYY-MM-DD"):`invalid ${M} date`}lo(()=>{let{globalFilter:M}=ie(),ge=s.getDescriptionWithoutGlobalFilter();(ge!=s.description||ge.indexOf(M)==-1)&&(y=!0);let ce="none";s.priority==="4"?ce="low":s.priority==="2"?ce="medium":s.priority==="1"&&(ce="high"),t(0,u={description:ge,status:s.status,priority:ce,recurrenceRule:s.recurrence?s.recurrence.toText():"",startDate:s.startDate?s.startDate.format("YYYY-MM-DD"):"",scheduledDate:s.scheduledDate?s.scheduledDate.format("YYYY-MM-DD"):"",dueDate:s.dueDate?s.dueDate.format("YYYY-MM-DD"):"",doneDate:s.doneDate?s.doneDate.format("YYYY-MM-DD"):""}),setTimeout(()=>{o.focus()},10)});let g=()=>{let{globalFilter:M}=ie(),ge=u.description.trim();y&&(ge=M+" "+ge);let ce=null,D=$i.parseDate(u.startDate,new Date,{forwardDate:!0});D!==null&&(ce=window.moment(D));let v=null,_=$i.parseDate(u.scheduledDate,new Date,{forwardDate:!0});_!==null&&(v=window.moment(_));let P=null,E=$i.parseDate(u.dueDate,new Date,{forwardDate:!0});E!==null&&(P=window.moment(E));let S=null;u.recurrenceRule&&(S=pt.fromText({recurrenceRuleText:u.recurrenceRule,startDate:ce,scheduledDate:v,dueDate:P}));let O;switch(u.priority){case"low":O="4";break;case"medium":O="2";break;case"high":O="1";break;default:O="3"}let W=new N(Object.assign(Object.assign({},s),{description:ge,status:u.status,priority:O,recurrence:S,startDate:ce,scheduledDate:v,dueDate:P,doneDate:window.moment(u.doneDate,"YYYY-MM-DD").isValid()?window.moment(u.doneDate,"YYYY-MM-DD"):null}));a([W])};function A(){u.description=this.value,t(0,u)}function x(M){Ts[M?"unshift":"push"](()=>{o=M,t(1,o)})}function C(){u.priority=fp(this),t(0,u)}function z(){u.recurrenceRule=this.value,t(0,u)}function ne(){u.dueDate=this.value,t(0,u)}function fe(){u.scheduledDate=this.value,t(0,u)}function ee(){u.startDate=this.value,t(0,u)}return r.$$set=M=>{"task"in M&&t(8,s=M.task),"onSubmit"in M&&t(9,a=M.onSubmit)},r.$$.update=()=>{if(r.$$.dirty&1){e:t(0,u.startDate=Tn(u.startDate),u),t(2,l=m("start",u.startDate,new Date))}if(r.$$.dirty&1){e:t(0,u.scheduledDate=Tn(u.scheduledDate),u),t(3,c=m("scheduled",u.scheduledDate,new Date))}if(r.$$.dirty&1){e:t(0,u.dueDate=Tn(u.dueDate),u),t(4,d=m("due",u.dueDate,new Date))}if(r.$$.dirty&3073){e:u.recurrenceRule?t(5,f=t(11,i=t(10,n=pt.fromText({recurrenceRuleText:u.recurrenceRule,startDate:null,scheduledDate:null,dueDate:null}))===null||n===void 0?void 0:n.toText())!==null&&i!==void 0?i:"invalid recurrence rule"):t(5,f="not recurring")}if(r.$$.dirty&1){e:t(6,p=m("done",u.doneDate))}},[u,o,l,c,d,f,p,g,s,a,n,i,A,x,C,z,ne,fe,ee]}var td=class extends bs{constructor(e){super(),mp(this,e,IO,SO,op,{task:8,onSubmit:9})}},Hg=td;var bn=class extends zg.Modal{constructor({app:t,task:n,onSubmit:i}){super(t);this.task=n,this.onSubmit=s=>{i(s),this.close()}}onOpen(){this.titleEl.setText("Create or edit Task");let{contentEl:t}=this;new Hg({target:t,props:{task:this.task,onSubmit:this.onSubmit}})}onClose(){let{contentEl:t}=this;t.empty()}};var Kg=(r,e,t,n)=>{var d;if(r)return t instanceof nd.MarkdownView;if(!(t instanceof nd.MarkdownView))return;let i=(d=t.file)==null?void 0:d.path;if(i===void 0)return;let a=e.getCursor().line,o=e.getLine(a),u=UO({line:o,path:i}),l=f=>{let p=f.map(y=>y.toFileLineString()).join(` -`);e.setLine(a,p)};new bn({app:n,task:u,onSubmit:l}).open()},UO=({line:r,path:e})=>{var c;let t=N.fromLine({line:r,path:e,sectionStart:0,sectionIndex:0,precedingHeader:null});if(t!==null)return t;let n=r.match(N.nonTaskRegex);if(n===null)return console.error("Tasks: Cannot create task on line:",r),new N({status:"Todo",description:"",path:e,indentation:"",originalStatusCharacter:" ",priority:"3",startDate:null,scheduledDate:null,dueDate:null,doneDate:null,recurrence:null,sectionStart:0,sectionIndex:0,precedingHeader:null,blockLink:"",tags:[]});let i=n[1],s=(c=n[3])!=null?c:" ",a=s===" "?"Todo":"Done",o=n[4],u=r.match(N.blockLinkRegex),l=u!==null?u[0]:"";return l!==""&&(o=o.replace(N.blockLinkRegex,"")),new N({status:a,description:o,path:e,indentation:i,originalStatusCharacter:s,blockLink:l,priority:"3",startDate:null,scheduledDate:null,dueDate:null,doneDate:null,recurrence:null,sectionStart:0,sectionIndex:0,precedingHeader:null,tags:[]})};var id=require("obsidian");var Vg=(r,e,t)=>{var u;if(r)return t instanceof id.MarkdownView;if(!(t instanceof id.MarkdownView))return;let n=(u=t.file)==null?void 0:u.path;if(n===void 0)return;let i=e.getCursor(),s=i.line,a=e.getLine(s),o=FO({line:a,path:n});e.setLine(s,o),/[^ [\]*-]/.test(o)&&e.setCursor({line:i.line,ch:i.ch+o.length-a.length})},FO=({line:r,path:e})=>{let t=r,n=N.fromLine({line:r,path:e,sectionStart:0,sectionIndex:0,precedingHeader:null});if(n!==null)t=qO({task:n});else{let i=r.match(N.taskRegex);i!==null?t=WO({regexMatch:i}):N.listItemRegex.test(r)?t=r.replace(N.listItemRegex,"$1$2 [ ]"):t=r.replace(N.indentationRegex,"$1- ")}return t},qO=({task:r})=>r.toggle().map(n=>n.toFileLineString()).join(` -`),WO=({regexMatch:r})=>{let e=r[1],t=r[2].toLowerCase(),n=r[3];return`${e}- [${t===" "?"x":" "}] ${n}`};var pa=class{get app(){return this.plugin.app}constructor({plugin:e}){this.plugin=e,e.addCommand({id:"edit-task",name:"Create or edit task",icon:"pencil",editorCheckCallback:(t,n,i)=>Kg(t,n,i,this.app)}),e.addCommand({id:"toggle-done",name:"Toggle task done",icon:"check-in-circle",editorCheckCallback:Vg})}};var ha=class{constructor({obsidianEvents:e}){this.obsidianEvents=e}onCacheUpdate(e){return this.obsidianEvents.on("obsidian-tasks-plugin:cache-update",e)}triggerCacheUpdate(e){this.obsidianEvents.trigger("obsidian-tasks-plugin:cache-update",e)}onRequestCacheUpdate(e){return this.obsidianEvents.on("obsidian-tasks-plugin:request-cache-update",e)}triggerRequestCacheUpdate(e){this.obsidianEvents.trigger("obsidian-tasks-plugin:request-cache-update",e)}off(e){this.obsidianEvents.offref(e)}};var ma=class{constructor({plugin:e}){this.markdownPostProcessor=this._markdownPostProcessor.bind(this);e.registerMarkdownPostProcessor(this._markdownPostProcessor.bind(this))}_markdownPostProcessor(e,t){return ae(this,null,function*(){var c;let{globalFilter:n}=ie(),i=e.findAll(".task-list-item").filter(d=>{var y;let f=(y=d.textContent)==null?void 0:y.split(` +`).map(function(i){return i.replace(/^RRULE:/,"EXRULE:")}).filter(function(i){return!/^DTSTART/.test(i)}))}),this._rdate.length&&t.push(ip("RDATE",this._rdate,this.tzid())),this._exdate.length&&t.push(ip("EXDATE",this._exdate,this.tzid())),t},e.prototype.toString=function(){return this.valueOf().join(` +`)},e.prototype.clone=function(){var t=new e(!!this._cache);return this._rrule.forEach(function(n){return t.rrule(n.clone())}),this._exrule.forEach(function(n){return t.exrule(n.clone())}),this._rdate.forEach(function(n){return t.rdate(new Date(n.getTime()))}),this._exdate.forEach(function(n){return t.exdate(new Date(n.getTime()))}),t},e}(w);function rp(r,e){if(!(r instanceof w))throw new TypeError(String(r)+" is not RRule instance");G(e.map(String),String(r))||e.push(r)}function np(r,e){if(!(r instanceof Date))throw new TypeError(String(r)+" is not Date instance");G(e.map(Number),Number(r))||(e.push(r),k.sort(e))}function ip(r,e,t){var n=!t||t.toUpperCase()==="UTC",i=n?"".concat(r,":"):"".concat(r,";TZID=").concat(t,":"),s=e.map(function(a){return k.timeToUntilString(a.valueOf(),n)}).join(",");return"".concat(i).concat(s)}var H=class{static by(e,t){let n=[H.compareByUrgency,H.compareByStatus,H.compareByDueDate,H.compareByPriority,H.compareByPath],i=[];for(let{property:s,reverse:a,propertyInstance:o}of e.sorting){let u=H.comparators[s];i.push(a?H.makeReversedComparator(u):u),s==="tag"&&(H.tagPropertyInstance=o)}return t.sort(H.makeCompositeComparator([...i,...n]))}static makeReversedComparator(e){return(t,n)=>e(t,n)*-1}static makeCompositeComparator(e){return(t,n)=>{for(let i of e){let s=i(t,n);if(s!==0)return s}return 0}}static compareByUrgency(e,t){return t.urgency-e.urgency}static compareByStatus(e,t){return e.statust.status?-1:0}static compareByPriority(e,t){return e.priority.localeCompare(t.priority)}static compareByStartDate(e,t){return H.compareByDate(e.startDate,t.startDate)}static compareByScheduledDate(e,t){return H.compareByDate(e.scheduledDate,t.scheduledDate)}static compareByDueDate(e,t){return H.compareByDate(e.dueDate,t.dueDate)}static compareByDoneDate(e,t){return H.compareByDate(e.doneDate,t.doneDate)}static compareByTag(e,t){if(e.tags.length===0&&t.tags.length===0)return 0;if(e.tags.length===0)return 1;if(t.tags.length===0)return-1;let n=H.tagPropertyInstance-1;return e.tags.length=H.tagPropertyInstance?1:t.tags.length=H.tagPropertyInstance?-1:e.tags.lengtht.tags[n]?1:0}static compareByDate(e,t){return e!==null&&t===null?-1:e===null&&t!==null?1:e!==null&&t!==null?e.isAfter(t)?1:e.isBefore(t)?-1:0:0}static compareByPath(e,t){return e.patht.path?1:0}static compareByDescription(e,t){return H.cleanDescription(e.description).localeCompare(H.cleanDescription(t.description))}static cleanDescription(e){let t=ae().globalFilter;e=e.replace(t,"").trim();let n=/^\[\[?([^\]]*)\]/,i=e.match(n);if(i!==null){let l=i[1];e=l.substring(l.indexOf("|")+1)+e.replace(n,"")}let s=/^\*\*?([^*]*)\*/,a=e.match(s);a!==null&&(e=a[1]+e.replace(n,""));let o=/^==?([^=]*)==/,u=e.match(o);return u!==null&&(e=u[1]+e.replace(o,"")),e}},Ge=H;Ge.tagPropertyInstance=1,Ge.comparators={urgency:H.compareByUrgency,description:H.compareByDescription,priority:H.compareByPriority,start:H.compareByStartDate,scheduled:H.compareByScheduledDate,due:H.compareByDueDate,done:H.compareByDoneDate,path:H.compareByPath,status:H.compareByStatus,tag:H.compareByTag};var pt=class{constructor({rrule:e,baseOnToday:t,referenceDate:n,startDate:i,scheduledDate:s,dueDate:a}){this.rrule=e,this.baseOnToday=t,this.referenceDate=n,this.startDate=i,this.scheduledDate=s,this.dueDate=a}static fromText({recurrenceRuleText:e,startDate:t,scheduledDate:n,dueDate:i}){try{let s=e.match(/^([a-zA-Z0-9, !]+?)( when done)?$/i);if(s==null)return null;let a=s[1].trim(),o=s[2]!==void 0,u=w.parseText(a);if(u!==null){let l=null;i?l=window.moment(i):n?l=window.moment(n):t&&(l=window.moment(t)),!o&&l!==null?u.dtstart=window.moment(l).startOf("day").utc(!0).toDate():u.dtstart=window.moment().startOf("day").utc(!0).toDate();let c=new w(u);return new pt({rrule:c,baseOnToday:o,referenceDate:l,startDate:t,scheduledDate:n,dueDate:i})}}catch(s){}return null}toText(){let e=this.rrule.toText();return this.baseOnToday&&(e+=" when done"),e}next(){var t;let e;if(this.baseOnToday){let n=window.moment();e=new w(Ft($e({},this.rrule.origOptions),{dtstart:n.startOf("day").utc(!0).toDate()})).after(n.endOf("day").utc(!0).toDate())}else{let n=window.moment((t=this.referenceDate)!=null?t:void 0).endOf("day").utc(!0);e=this.rrule.after(n.toDate())}if(e!==null){let i=window.moment.utc(e).local(!0).startOf("day"),s=null,a=null,o=null;if(this.referenceDate){if(this.startDate){let u=window.moment.duration(this.startDate.diff(this.referenceDate));s=window.moment(i),s.add(Math.round(u.asDays()),"days")}if(this.scheduledDate){let u=window.moment.duration(this.scheduledDate.diff(this.referenceDate));a=window.moment(i),a.add(Math.round(u.asDays()),"days")}if(this.dueDate){let u=window.moment.duration(this.dueDate.diff(this.referenceDate));o=window.moment(i),o.add(Math.round(u.asDays()),"days")}}return{startDate:s,scheduledDate:a,dueDate:o}}return null}identicalTo(e){return this.baseOnToday!==e.baseOnToday||Ge.compareByDate(this.startDate,e.startDate)!==0||Ge.compareByDate(this.scheduledDate,e.scheduledDate)!==0||Ge.compareByDate(this.dueDate,e.dueDate)!==0?!1:this.toText()===e.toText()}};var $t=class{static calculate(e){let t=0;if(e.dueDate!==null){let n=Math.round(window.moment().diff(e.dueDate)/$t.milliSecondsPerDay),i;n>=7?i=1:n>=-14?i=(n+14)*.8/21+.2:i=.2,t+=i*$t.dueCoefficient}switch(e.scheduledDate!==null&&window.moment().isSameOrAfter(e.scheduledDate)&&(t+=1*$t.scheduledCoefficient),e.startDate!==null&&window.moment().isBefore(e.startDate)&&(t+=1*$t.startedCoefficient),e.priority){case"1":t+=1*$t.priorityCoefficient;break;case"2":t+=.65*$t.priorityCoefficient;break;case"3":t+=.325*$t.priorityCoefficient;break}return t}},Yt=$t;Yt.dueCoefficient=12,Yt.scheduledCoefficient=5,Yt.startedCoefficient=-3,Yt.priorityCoefficient=6,Yt.milliSecondsPerDay=1e3*60*60*24;var Re={High:"\u23EB",Medium:"\u{1F53C}",Low:"\u{1F53D}",None:""},wt="\u{1F501}",Mt="\u{1F6EB}",Dt="\u23F3",Pt="\u{1F4C5}",io="\u2705",I=class{constructor({status:e,description:t,path:n,indentation:i,sectionStart:s,sectionIndex:a,originalStatusCharacter:o,precedingHeader:u,priority:l,startDate:c,scheduledDate:d,dueDate:f,doneDate:p,recurrence:y,blockLink:m,tags:g}){this._urgency=null;this.status=e,this.description=t,this.path=n,this.indentation=i,this.sectionStart=s,this.sectionIndex=a,this.originalStatusCharacter=o,this.precedingHeader=u,this.tags=g,this.priority=l,this.startDate=c,this.scheduledDate=d,this.dueDate=f,this.doneDate=p,this.recurrence=y,this.blockLink=m}static fromLine({line:e,path:t,sectionStart:n,sectionIndex:i,precedingHeader:s}){let a=e.match(I.taskRegex);if(a===null)return null;let o=a[3].trim(),{globalFilter:u}=ae();if(!o.includes(u))return null;let l=o,c=a[1],d=a[2].toLowerCase(),f;switch(d){case" ":f="Todo";break;default:f="Done"}let p=l.match(this.blockLinkRegex),y=p!==null?p[0]:"";y!==""&&(l=l.replace(this.blockLinkRegex,"").trim());let m,g="3",A=null,C=null,x=null,z=null,ie="",fe=null,te=[],M="",ge=20,ce=0;do{m=!1;let v=l.match(I.priorityRegex);if(v!==null){switch(v[1]){case Re.Low:g="4";break;case Re.Medium:g="2";break;case Re.High:g="1";break}l=l.replace(I.priorityRegex,"").trim(),m=!0}let _=l.match(I.doneDateRegex);_!==null&&(z=window.moment(_[1],I.dateFormat),l=l.replace(I.doneDateRegex,"").trim(),m=!0);let P=l.match(I.dueDateRegex);P!==null&&(x=window.moment(P[1],I.dateFormat),l=l.replace(I.dueDateRegex,"").trim(),m=!0);let E=l.match(I.scheduledDateRegex);E!==null&&(C=window.moment(E[1],I.dateFormat),l=l.replace(I.scheduledDateRegex,"").trim(),m=!0);let S=l.match(I.startDateRegex);S!==null&&(A=window.moment(S[1],I.dateFormat),l=l.replace(I.startDateRegex,"").trim(),m=!0);let O=l.match(I.recurrenceRegex);O!==null&&(ie=O[1].trim(),l=l.replace(I.recurrenceRegex,"").trim(),m=!0);let W=l.match(I.hashTagsFromEnd);if(W!=null){l=l.replace(I.hashTagsFromEnd,"").trim(),m=!0;let re=W[0].trim();M=M.length>0?[re,M].join(" "):re}ce++}while(m&&ce<=ge);ie.length>0&&(fe=pt.fromText({recurrenceRuleText:ie,startDate:A,scheduledDate:C,dueDate:x})),M.length>0&&(l+=" "+M);let D=l.match(this.hashTags);return D!==null&&(te=D.filter(v=>v!==u).map(v=>v.trim())),new I({status:f,description:l,path:t,indentation:c,sectionStart:n,sectionIndex:i,originalStatusCharacter:d,precedingHeader:s,priority:g,startDate:A,scheduledDate:C,dueDate:x,doneDate:z,recurrence:fe,blockLink:y,tags:te})}toLi(s){return se(this,arguments,function*({parentUlElement:e,listIndex:t,layoutOptions:n,isFilenameUnique:i}){let a=e.createEl("li");a.addClasses(["task-list-item","plugin-tasks-list-item"]);let o=this.toString(n),{globalFilter:u,removeGlobalFilter:l}=ae();l&&(o=o.replace(u,"").trim());let c=a.createSpan();c.addClass("tasks-list-text"),yield sp.MarkdownRenderer.renderMarkdown(o,c,this.path,null);let d=c.querySelector("blockquote"),f=d!=null?d:c,p=f.querySelector("p");if(p!==null){for(;p.firstChild;)f.insertBefore(p.firstChild,p);p.remove()}c.findAll("p").forEach(m=>{m.hasChildNodes()||m.remove()}),c.findAll(".footnotes").forEach(m=>{m.remove()});let y=a.createEl("input");return y.addClass("task-list-item-checkbox"),y.type="checkbox",this.status!=="Todo"&&(y.checked=!0,a.addClass("is-checked")),y.onClickEvent(m=>{m.preventDefault(),m.stopPropagation(),y.disabled=!0;let g=this.toggle();ls({originalTask:this,newTasks:g})}),a.prepend(y),a.setAttr("data-task",this.originalStatusCharacter.trim()),a.setAttr("data-line",t),y.setAttr("data-line",t),n!=null&&n.shortMode&&this.addTooltip({element:c,isFilenameUnique:i}),a})}toString(e){var i;e=e!=null?e:new Xr;let t=this.description;if(!e.hidePriority){let s="";this.priority==="1"?s=" "+Re.High:this.priority==="2"?s=" "+Re.Medium:this.priority==="4"&&(s=" "+Re.Low),t+=s}return!e.hideRecurrenceRule&&this.recurrence&&(t+=e.shortMode?" "+wt:` ${wt} ${this.recurrence.toText()}`),!e.hideStartDate&&this.startDate&&(t+=e.shortMode?" "+Mt:` ${Mt} ${this.startDate.format(I.dateFormat)}`),!e.hideScheduledDate&&this.scheduledDate&&(t+=e.shortMode?" "+Dt:` ${Dt} ${this.scheduledDate.format(I.dateFormat)}`),!e.hideDueDate&&this.dueDate&&(t+=e.shortMode?" "+Pt:` ${Pt} ${this.dueDate.format(I.dateFormat)}`),!e.hideDoneDate&&this.doneDate&&(t+=e.shortMode?" "+io:` ${io} ${this.doneDate.format(I.dateFormat)}`),t+=(i=this.blockLink)!=null?i:"",t}toFileLineString(){return`${this.indentation}- [${this.originalStatusCharacter}] ${this.toString()}`}toggle(){let e=this.status==="Todo"?"Done":"Todo",t=null,n=null;if(e!=="Todo"){let{setDoneDate:a}=ae();a&&(t=window.moment()),this.recurrence!==null&&(n=this.recurrence.next())}let i=new I(Ft($e({},this),{status:e,doneDate:t,originalStatusCharacter:e==="Done"?"x":" "})),s=[];if(n!==null){let a=new I(Ft($e($e({},this),n),{blockLink:""}));s.push(a)}return s.push(i),s}get urgency(){return this._urgency===null&&(this._urgency=Yt.calculate(this)),this._urgency}get filename(){let e=this.path.match(/([^/]+)\.md$/);return e!==null?e[1]:null}getLinkText({isFilenameUnique:e}){let t;return e?t=this.filename:t="/"+this.path,t===null?null:(this.precedingHeader!==null&&this.precedingHeader!==t&&(t=t+" > "+this.precedingHeader),t)}static tasksListsIdentical(e,t){return e.length!==t.length?!1:e.every((n,i)=>n.identicalTo(t[i]))}identicalTo(e){let t=["status","description","path","indentation","sectionStart","sectionIndex","originalStatusCharacter","precedingHeader","priority","blockLink"];for(let s of t)if(this[s]!==e[s])return!1;if(this.tags.length!==e.tags.length||!this.tags.every(function(s,a){return s===e.tags[a]}))return!1;t=["startDate","scheduledDate","dueDate","doneDate"];for(let s of t){let a=this[s],o=e[s];if(Ge.compareByDate(a,o)!==0)return!1}let n=this.recurrence,i=e.recurrence;return n===null&&i!==null||n!==null&&i===null?!1:!(n&&i&&!n.identicalTo(i))}addTooltip({element:e,isFilenameUnique:t}){e.addEventListener("mouseenter",()=>{let n=e.createDiv();n.addClasses(["tooltip","mod-right"]),this.recurrence&&n.createDiv().setText(`${wt} ${this.recurrence.toText()}`),this.startDate&&n.createDiv().setText(I.toTooltipDate({signifier:Mt,date:this.startDate})),this.scheduledDate&&n.createDiv().setText(I.toTooltipDate({signifier:Dt,date:this.scheduledDate})),this.dueDate&&n.createDiv().setText(I.toTooltipDate({signifier:Pt,date:this.dueDate})),this.doneDate&&n.createDiv().setText(I.toTooltipDate({signifier:io,date:this.doneDate}));let i=this.getLinkText({isFilenameUnique:t});i&&n.createDiv().setText(`\u{1F517} ${i}`),e.addEventListener("mouseleave",()=>{n.remove()})})}static toTooltipDate({signifier:e,date:t}){return`${e} ${t.format(I.dateFormat)} (${t.from(window.moment().startOf("day"))})`}escapeRegExp(e){return e.replace(/([.*+?^${}()|[\]/\\])/g,"\\$1")}getDescriptionWithoutGlobalFilter(){let{globalFilter:e}=ae(),t=this.description;if(e.length===0)return t;let n=RegExp("(^|\\s)"+this.escapeRegExp(e)+"($|\\s)","ug");return this.description.search(n)>-1&&(t=t.replace(n,"$1$2").replace(" "," ").trim()),t}},N=I;N.dateFormat="YYYY-MM-DD",N.indentationRegex=/^([\s\t>]*)/,N.listMarkerRegex=/[-*]/,N.checkboxRegex=/\[(.)\]/u,N.afterCheckboxRegex=/ *(.*)/u,N.taskRegex=new RegExp(I.indentationRegex.source+I.listMarkerRegex.source+" +"+I.checkboxRegex.source+I.afterCheckboxRegex.source,"u"),N.nonTaskRegex=new RegExp(I.indentationRegex.source+I.listMarkerRegex.source+"? *("+I.checkboxRegex.source+")?"+I.afterCheckboxRegex.source,"u"),N.listItemRegex=new RegExp(I.indentationRegex.source+"("+I.listMarkerRegex.source+")"),N.blockLinkRegex=/ \^[a-zA-Z0-9-]+$/u,N.priorityRegex=/([⏫🔼🔽])$/u,N.startDateRegex=/🛫 *(\d{4}-\d{2}-\d{2})$/u,N.scheduledDateRegex=/[⏳⌛] *(\d{4}-\d{2}-\d{2})$/u,N.dueDateRegex=/[📅📆🗓] *(\d{4}-\d{2}-\d{2})$/u,N.doneDateRegex=/✅ *(\d{4}-\d{2}-\d{2})$/u,N.recurrenceRegex=/🔁 ?([a-zA-Z0-9, !]+)$/iu,N.hashTags=/(^|\s)#[^ !@#$%^&*(),.?":{}|<>]*/g,N.hashTagsFromEnd=new RegExp(I.hashTags.source+"$");var hr=class{constructor({metadataCache:e,vault:t,events:n}){this.metadataCache=e,this.metadataCacheEventReferences=[],this.vault=t,this.vaultEventReferences=[],this.events=n,this.eventsEventReferences=[],this.tasksMutex=new us,this.state="Cold",this.tasks=[],this.loadedAfterFirstResolve=!1,this.subscribeToCache(),this.subscribeToVault(),this.subscribeToEvents(),this.loadVault()}unload(){for(let e of this.metadataCacheEventReferences)this.metadataCache.offref(e);for(let e of this.vaultEventReferences)this.vault.offref(e);for(let e of this.eventsEventReferences)this.events.off(e)}getTasks(){return this.tasks}getState(){return this.state}notifySubscribers(){this.events.triggerCacheUpdate({tasks:this.tasks,state:this.state})}subscribeToCache(){let e=this.metadataCache.on("resolved",()=>se(this,null,function*(){this.loadedAfterFirstResolve||(this.loadedAfterFirstResolve=!0,this.loadVault())}));this.metadataCacheEventReferences.push(e);let t=this.metadataCache.on("changed",n=>{this.tasksMutex.runExclusive(()=>{this.indexFile(n)})});this.metadataCacheEventReferences.push(t)}subscribeToVault(){let e=this.vault.on("create",i=>{i instanceof gs.TFile&&this.tasksMutex.runExclusive(()=>{this.indexFile(i)})});this.vaultEventReferences.push(e);let t=this.vault.on("delete",i=>{i instanceof gs.TFile&&this.tasksMutex.runExclusive(()=>{this.tasks=this.tasks.filter(s=>s.path!==i.path),this.notifySubscribers()})});this.vaultEventReferences.push(t);let n=this.vault.on("rename",(i,s)=>{i instanceof gs.TFile&&this.tasksMutex.runExclusive(()=>{this.tasks=this.tasks.map(a=>a.path===s?new N(Ft($e({},a),{path:i.path})):a),this.notifySubscribers()})});this.vaultEventReferences.push(n)}subscribeToEvents(){let e=this.events.onRequestCacheUpdate(t=>{t({tasks:this.tasks,state:this.state})});this.eventsEventReferences.push(e)}loadVault(){return this.tasksMutex.runExclusive(()=>se(this,null,function*(){this.state="Initializing",yield Promise.all(this.vault.getMarkdownFiles().map(e=>this.indexFile(e))),this.state="Warm",this.notifySubscribers()}))}indexFile(e){return se(this,null,function*(){let t=this.metadataCache.getFileCache(e);if(t==null)return;let n=this.tasks.filter(a=>a.path===e.path),i=t.listItems,s=[];if(i!==void 0){let a=yield this.vault.cachedRead(e);s=hr.getTasksFromFileContent(a,i,t,e)}N.tasksListsIdentical(n,s)||(this.getState()=="Warm"&&console.debug(`At least one task, its line number or its heading has changed in ${e.path}: triggering a refresh of all active Tasks blocks in Live Preview and Reading mode views.`),this.tasks=this.tasks.filter(a=>a.path!==e.path),this.tasks.push(...s),this.notifySubscribers())})}static getTasksFromFileContent(e,t,n,i){let s=[],a=e.split(` +`),o=null,u=0;for(let l of t)if(l.task!==void 0){if((o===null||o.position.end.line=e)return n;return null}static getPrecedingHeader(e,t){if(t===void 0)return null;let n=null;for(let i of t){if(i.position.start.line>e)return n;n=i.heading}return n}};var id=require("obsidian");var Zg=require("obsidian");function rn(){}function oo(r){return r()}function op(){return Object.create(null)}function Sr(r){r.forEach(oo)}function lp(r){return typeof r=="function"}function cp(r,e){return r!=r?e==e:r!==e||r&&typeof r=="object"||typeof r=="function"}function dp(r){return Object.keys(r).length===0}var fp=!1;function aT(){fp=!0}function oT(){fp=!1}function b(r,e){r.appendChild(e)}function uo(r,e,t){r.insertBefore(e,t||null)}function Es(r){r.parentNode.removeChild(r)}function U(r){return document.createElement(r)}function uT(r){return document.createElementNS("http://www.w3.org/2000/svg",r)}function jt(r){return document.createTextNode(r)}function X(){return jt(" ")}function mr(r,e,t,n){return r.addEventListener(e,t,n),()=>r.removeEventListener(e,t,n)}function pp(r){return function(e){return e.preventDefault(),r.call(this,e)}}function $(r,e,t){t==null?r.removeAttribute(e):r.getAttribute(e)!==t&&r.setAttribute(e,t)}function lT(r){return Array.from(r.childNodes)}function hp(r,e){e=""+e,r.wholeText!==e&&(r.data=e)}function ht(r,e){r.value=e==null?"":e}function lo(r,e){for(let t=0;t{let u=s.map(oo).filter(lp);a?a.push(...u):Sr(u),r.$$.on_mount=[]}),o.forEach($n)}function gp(r,e){let t=r.$$;t.fragment!==null&&(Sr(t.on_destroy),t.fragment&&t.fragment.d(e),t.on_destroy=t.fragment=null,t.ctx=[])}function gT(r,e){r.$$.dirty[0]===-1&&(Wn.push(r),fT(),r.$$.dirty.fill(0)),r.$$.dirty[e/31|0]|=1<{let y=p.length?p[0]:f;return l.ctx&&i(l.ctx[d],l.ctx[d]=y)&&(!l.skip_bound&&l.bound[d]&&l.bound[d](y),c&&gT(r,d)),f}):[],l.update(),c=!0,Sr(l.before_update),l.fragment=n?n(l.ctx):!1,e.target){if(e.hydrate){aT();let d=lT(e.target);l.fragment&&l.fragment.l(d),d.forEach(Es)}else l.fragment&&l.fragment.c();e.intro&&mT(r.$$.fragment),yT(r,e.target,e.anchor,e.customElement),oT(),yp()}Ln(u)}var _T;typeof HTMLElement=="function"&&(_T=class extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"})}connectedCallback(){let{on_mount:r}=this.$$;this.$$.on_disconnect=r.map(oo).filter(lp);for(let e in this.$$.slotted)this.appendChild(this.$$.slotted[e])}attributeChangedCallback(r,e,t){this[r]=t}disconnectedCallback(){Sr(this.$$.on_disconnect)}$destroy(){gp(this,1),this.$destroy=rn}$on(r,e){let t=this.$$.callbacks[r]||(this.$$.callbacks[r]=[]);return t.push(e),()=>{let n=t.indexOf(e);n!==-1&&t.splice(n,1)}}$set(r){this.$$set&&!dp(r)&&(this.$$.skip_bound=!0,this.$$set(r),this.$$.skip_bound=!1)}});var vs=class{$destroy(){gp(this,1),this.$destroy=rn}$on(e,t){let n=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return n.push(t),()=>{let i=n.indexOf(t);i!==-1&&n.splice(i,1)}}$set(e){this.$$set&&!dp(e)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}};var ji=os(Ee());var UO={td:"today",tm:"tomorrow",yd:"yesterday",tw:"this week",nw:"next week",weekend:"sat",we:"sat"};function bn(r){for(let[e,t]of Object.entries(UO))r=r.replace(RegExp(`\\b${e}\\s`,"i"),t);return r}function FO(r){let e,t,n,i,s,a,o,u,l,c,d,f,p,y,m,g,A,C,x,z,ie,fe,te,M,ge,ce,D,v,_,P,E,S,O,W,re,le,oe,dt,Le,or,ur,ft,Ne,xe,lr,Or,It,Dd,An,Pd,Od,Ji,Ad,cr,es,kd,Ut,Nd,kn,xd,Cd,ts,Sd,Id,Ud,Vr,Zr,Fd,Ar,rs,qd,Ba,ns=r[0].status+"",Ga,Wd,is,Ld,ss,Yd,$d,jd,Ha,Bd,as,za,Gd;return{c(){e=U("div"),t=U("form"),n=U("div"),i=U("label"),i.textContent="Description",s=X(),a=U("input"),o=X(),u=U("hr"),l=X(),c=U("div"),d=U("label"),d.textContent="Priority",f=X(),p=U("select"),y=U("option"),y.textContent="None",m=U("option"),m.textContent=`${Re.High} High`,g=U("option"),g.textContent=`${Re.Medium} Medium`,A=U("option"),A.textContent=`${Re.Low} Low`,C=X(),x=U("hr"),z=X(),ie=U("div"),fe=U("label"),fe.textContent="Recurrence",te=X(),M=U("input"),ge=X(),ce=U("code"),D=jt(wt),v=X(),_=new Cr(!1),P=X(),E=U("hr"),S=X(),O=U("div"),W=U("div"),re=U("label"),re.textContent="Due",le=X(),oe=U("input"),dt=X(),Le=U("code"),or=jt(Pt),ur=X(),ft=new Cr(!1),Ne=X(),xe=U("div"),lr=U("label"),lr.textContent="Scheduled",Or=X(),It=U("input"),Dd=X(),An=U("code"),Pd=jt(Dt),Od=X(),Ji=new Cr(!1),Ad=X(),cr=U("div"),es=U("label"),es.textContent="Start",kd=X(),Ut=U("input"),Nd=X(),kn=U("code"),xd=jt(Mt),Cd=X(),ts=new Cr(!1),Sd=X(),Id=U("hr"),Ud=X(),Vr=U("div"),Zr=U("div"),Fd=jt(`Status: + `),Ar=U("input"),qd=X(),Ba=U("code"),Ga=jt(ns),Wd=X(),is=U("div"),Ld=jt(`Done on: + `),ss=U("code"),Yd=X(),$d=U("hr"),jd=X(),Ha=U("div"),Bd=X(),as=U("div"),as.innerHTML='',$(i,"for","description"),$(a,"id","description"),$(a,"type","text"),$(a,"class","tasks-modal-description"),$(a,"placeholder","Take out the trash"),$(n,"class","tasks-modal-section"),$(d,"for","priority"),y.__value="none",y.value=y.__value,m.__value="high",m.value=m.__value,g.__value="medium",g.value=g.__value,A.__value="low",A.value=A.__value,$(p,"id","priority"),$(p,"class","dropdown"),r[0].priority===void 0&&$n(()=>r[14].call(p)),$(c,"class","tasks-modal-section"),$(fe,"for","recurrence"),$(M,"id","description"),$(M,"type","text"),$(M,"placeholder","Try 'every 2 weeks on Thursday'."),_.a=null,$(ie,"class","tasks-modal-section"),$(re,"for","due"),$(oe,"id","due"),$(oe,"type","text"),$(oe,"placeholder",td),ft.a=null,$(W,"class","tasks-modal-date"),$(lr,"for","scheduled"),$(It,"id","scheduled"),$(It,"type","text"),$(It,"placeholder",td),Ji.a=null,$(xe,"class","tasks-modal-date"),$(es,"for","start"),$(Ut,"id","start"),$(Ut,"type","text"),$(Ut,"placeholder",td),ts.a=null,$(cr,"class","tasks-modal-date"),$(O,"class","tasks-modal-section"),$(Ar,"type","checkbox"),$(Ar,"class","task-list-item-checkbox tasks-modal-checkbox"),Ar.checked=rs=r[0].status==="Done",Ar.disabled=!0,$(Vr,"class","tasks-modal-section"),$(Ha,"class","tasks-modal-section"),$(as,"class","tasks-modal-section"),$(e,"class","tasks-modal")},m(pe,Ye){uo(pe,e,Ye),b(e,t),b(t,n),b(n,i),b(n,s),b(n,a),ht(a,r[0].description),r[13](a),b(t,o),b(t,u),b(t,l),b(t,c),b(c,d),b(c,f),b(c,p),b(p,y),b(p,m),b(p,g),b(p,A),lo(p,r[0].priority),b(t,C),b(t,x),b(t,z),b(t,ie),b(ie,fe),b(ie,te),b(ie,M),ht(M,r[0].recurrenceRule),b(ie,ge),b(ie,ce),b(ce,D),b(ce,v),_.m(r[5],ce),b(t,P),b(t,E),b(t,S),b(t,O),b(O,W),b(W,re),b(W,le),b(W,oe),ht(oe,r[0].dueDate),b(W,dt),b(W,Le),b(Le,or),b(Le,ur),ft.m(r[4],Le),b(O,Ne),b(O,xe),b(xe,lr),b(xe,Or),b(xe,It),ht(It,r[0].scheduledDate),b(xe,Dd),b(xe,An),b(An,Pd),b(An,Od),Ji.m(r[3],An),b(O,Ad),b(O,cr),b(cr,es),b(cr,kd),b(cr,Ut),ht(Ut,r[0].startDate),b(cr,Nd),b(cr,kn),b(kn,xd),b(kn,Cd),ts.m(r[2],kn),b(t,Sd),b(t,Id),b(t,Ud),b(t,Vr),b(Vr,Zr),b(Zr,Fd),b(Zr,Ar),b(Zr,qd),b(Zr,Ba),b(Ba,Ga),b(Vr,Wd),b(Vr,is),b(is,Ld),b(is,ss),ss.innerHTML=r[6],b(t,Yd),b(t,$d),b(t,jd),b(t,Ha),b(t,Bd),b(t,as),za||(Gd=[mr(a,"input",r[12]),mr(p,"change",r[14]),mr(M,"input",r[15]),mr(oe,"input",r[16]),mr(It,"input",r[17]),mr(Ut,"input",r[18]),mr(t,"submit",pp(r[7]))],za=!0)},p(pe,[Ye]){Ye&1&&a.value!==pe[0].description&&ht(a,pe[0].description),Ye&1&&lo(p,pe[0].priority),Ye&1&&M.value!==pe[0].recurrenceRule&&ht(M,pe[0].recurrenceRule),Ye&32&&_.p(pe[5]),Ye&1&&oe.value!==pe[0].dueDate&&ht(oe,pe[0].dueDate),Ye&16&&ft.p(pe[4]),Ye&1&&It.value!==pe[0].scheduledDate&&ht(It,pe[0].scheduledDate),Ye&8&&Ji.p(pe[3]),Ye&1&&Ut.value!==pe[0].startDate&&ht(Ut,pe[0].startDate),Ye&4&&ts.p(pe[2]),Ye&1&&rs!==(rs=pe[0].status==="Done")&&(Ar.checked=rs),Ye&1&&ns!==(ns=pe[0].status+"")&&hp(Ga,ns),Ye&64&&(ss.innerHTML=pe[6])},i:rn,o:rn,d(pe){pe&&Es(e),r[13](null),za=!1,Sr(Gd)}}}var td="Try 'Monday' or 'tomorrow', or [td|tm|yd|tw|nw|we] then space.";function qO(r,e,t){var n,i;let{task:s}=e,{onSubmit:a}=e,o,u={description:"",status:"Todo",priority:"none",recurrenceRule:"",startDate:"",scheduledDate:"",dueDate:"",doneDate:""},l="",c="",d="",f="",p="",y=!1;function m(M,ge,ce=void 0){if(!ge)return`no ${M} date`;let D=ji.parseDate(ge,ce,{forwardDate:ce!=null});return D!==null?window.moment(D).format("YYYY-MM-DD"):`invalid ${M} date`}co(()=>{let{globalFilter:M}=ae(),ge=s.getDescriptionWithoutGlobalFilter();(ge!=s.description||ge.indexOf(M)==-1)&&(y=!0);let ce="none";s.priority==="4"?ce="low":s.priority==="2"?ce="medium":s.priority==="1"&&(ce="high"),t(0,u={description:ge,status:s.status,priority:ce,recurrenceRule:s.recurrence?s.recurrence.toText():"",startDate:s.startDate?s.startDate.format("YYYY-MM-DD"):"",scheduledDate:s.scheduledDate?s.scheduledDate.format("YYYY-MM-DD"):"",dueDate:s.dueDate?s.dueDate.format("YYYY-MM-DD"):"",doneDate:s.doneDate?s.doneDate.format("YYYY-MM-DD"):""}),setTimeout(()=>{o.focus()},10)});let g=()=>{let{globalFilter:M}=ae(),ge=u.description.trim();y&&(ge=M+" "+ge);let ce=null,D=ji.parseDate(u.startDate,new Date,{forwardDate:!0});D!==null&&(ce=window.moment(D));let v=null,_=ji.parseDate(u.scheduledDate,new Date,{forwardDate:!0});_!==null&&(v=window.moment(_));let P=null,E=ji.parseDate(u.dueDate,new Date,{forwardDate:!0});E!==null&&(P=window.moment(E));let S=null;u.recurrenceRule&&(S=pt.fromText({recurrenceRuleText:u.recurrenceRule,startDate:ce,scheduledDate:v,dueDate:P}));let O;switch(u.priority){case"low":O="4";break;case"medium":O="2";break;case"high":O="1";break;default:O="3"}let W=new N(Object.assign(Object.assign({},s),{description:ge,status:u.status,priority:O,recurrence:S,startDate:ce,scheduledDate:v,dueDate:P,doneDate:window.moment(u.doneDate,"YYYY-MM-DD").isValid()?window.moment(u.doneDate,"YYYY-MM-DD"):null}));a([W])};function A(){u.description=this.value,t(0,u)}function C(M){bs[M?"unshift":"push"](()=>{o=M,t(1,o)})}function x(){u.priority=mp(this),t(0,u)}function z(){u.recurrenceRule=this.value,t(0,u)}function ie(){u.dueDate=this.value,t(0,u)}function fe(){u.scheduledDate=this.value,t(0,u)}function te(){u.startDate=this.value,t(0,u)}return r.$$set=M=>{"task"in M&&t(8,s=M.task),"onSubmit"in M&&t(9,a=M.onSubmit)},r.$$.update=()=>{if(r.$$.dirty&1){e:t(0,u.startDate=bn(u.startDate),u),t(2,l=m("start",u.startDate,new Date))}if(r.$$.dirty&1){e:t(0,u.scheduledDate=bn(u.scheduledDate),u),t(3,c=m("scheduled",u.scheduledDate,new Date))}if(r.$$.dirty&1){e:t(0,u.dueDate=bn(u.dueDate),u),t(4,d=m("due",u.dueDate,new Date))}if(r.$$.dirty&3073){e:u.recurrenceRule?t(5,f=t(11,i=t(10,n=pt.fromText({recurrenceRuleText:u.recurrenceRule,startDate:null,scheduledDate:null,dueDate:null}))===null||n===void 0?void 0:n.toText())!==null&&i!==void 0?i:"invalid recurrence rule"):t(5,f="not recurring")}if(r.$$.dirty&1){e:t(6,p=m("done",u.doneDate))}},[u,o,l,c,d,f,p,g,s,a,n,i,A,C,x,z,ie,fe,te]}var rd=class extends vs{constructor(e){super(),_p(this,e,qO,FO,cp,{task:8,onSubmit:9})}},Vg=rd;var vn=class extends Zg.Modal{constructor({app:t,task:n,onSubmit:i}){super(t);this.task=n,this.onSubmit=s=>{i(s),this.close()}}onOpen(){this.titleEl.setText("Create or edit Task");let{contentEl:t}=this;new Vg({target:t,props:{task:this.task,onSubmit:this.onSubmit}})}onClose(){let{contentEl:t}=this;t.empty()}};var Xg=(r,e,t,n)=>{var d;if(r)return t instanceof id.MarkdownView;if(!(t instanceof id.MarkdownView))return;let i=(d=t.file)==null?void 0:d.path;if(i===void 0)return;let a=e.getCursor().line,o=e.getLine(a),u=WO({line:o,path:i}),l=f=>{let p=f.map(y=>y.toFileLineString()).join(` +`);e.setLine(a,p)};new vn({app:n,task:u,onSubmit:l}).open()},WO=({line:r,path:e})=>{var c;let t=N.fromLine({line:r,path:e,sectionStart:0,sectionIndex:0,precedingHeader:null});if(t!==null)return t;let n=r.match(N.nonTaskRegex);if(n===null)return console.error("Tasks: Cannot create task on line:",r),new N({status:"Todo",description:"",path:e,indentation:"",originalStatusCharacter:" ",priority:"3",startDate:null,scheduledDate:null,dueDate:null,doneDate:null,recurrence:null,sectionStart:0,sectionIndex:0,precedingHeader:null,blockLink:"",tags:[]});let i=n[1],s=(c=n[3])!=null?c:" ",a=s===" "?"Todo":"Done",o=n[4],u=r.match(N.blockLinkRegex),l=u!==null?u[0]:"";return l!==""&&(o=o.replace(N.blockLinkRegex,"")),new N({status:a,description:o,path:e,indentation:i,originalStatusCharacter:s,blockLink:l,priority:"3",startDate:null,scheduledDate:null,dueDate:null,doneDate:null,recurrence:null,sectionStart:0,sectionIndex:0,precedingHeader:null,tags:[]})};var sd=require("obsidian");var Qg=(r,e,t)=>{var u;if(r)return t instanceof sd.MarkdownView;if(!(t instanceof sd.MarkdownView))return;let n=(u=t.file)==null?void 0:u.path;if(n===void 0)return;let i=e.getCursor(),s=i.line,a=e.getLine(s),o=LO(a,n);e.setLine(s,o),e.setCursor({line:i.line,ch:$O(i.ch,a,o)})},LO=(r,e)=>{let t=r,n=N.fromLine({line:r,path:e,sectionStart:0,sectionIndex:0,precedingHeader:null});if(n!==null)t=YO(n);else{let i=r.match(N.taskRegex);if(i!==null){let a=i[2].toLowerCase()===" "?"x":" ";t=r.replace(N.taskRegex,`$1- [${a}] $3`)}else N.listItemRegex.test(r)?t=r.replace(N.listItemRegex,"$1$2 [ ]"):t=r.replace(N.indentationRegex,"$1- ")}return t},YO=r=>r.toggle().map(n=>n.toFileLineString()).join(` +`),$O=(r,e,t)=>{let n=t.length;if(n<=e.length)return r>=t.length?n:r;let i=13;if(t.match(N.doneDateRegex)&&n-e.length>=i&&(n-=i),n>=2*e.length&&t.search(`.+ +.+`)!==-1)return r+n-e.length;let s=t.search(/[-*]/);return rXg(t,n,i,this.app)}),e.addCommand({id:"toggle-done",name:"Toggle task done",icon:"check-in-circle",editorCheckCallback:Qg})}};var ma=class{constructor({obsidianEvents:e}){this.obsidianEvents=e}onCacheUpdate(e){return this.obsidianEvents.on("obsidian-tasks-plugin:cache-update",e)}triggerCacheUpdate(e){this.obsidianEvents.trigger("obsidian-tasks-plugin:cache-update",e)}onRequestCacheUpdate(e){return this.obsidianEvents.on("obsidian-tasks-plugin:request-cache-update",e)}triggerRequestCacheUpdate(e){this.obsidianEvents.trigger("obsidian-tasks-plugin:request-cache-update",e)}off(e){this.obsidianEvents.offref(e)}};var ya=class{constructor({plugin:e}){this.markdownPostProcessor=this._markdownPostProcessor.bind(this);e.registerMarkdownPostProcessor(this._markdownPostProcessor.bind(this))}_markdownPostProcessor(e,t){return se(this,null,function*(){var c;let{globalFilter:n}=ae(),i=e.findAll(".task-list-item").filter(d=>{var y;let f=(y=d.textContent)==null?void 0:y.split(` `);if(f===void 0)return!1;let p=null;for(let m=0;mZg.ViewPlugin.fromClass(sd),sd=class{constructor(e){this.view=e,this.handleClickEvent=this.handleClickEvent.bind(this),this.view.dom.addEventListener("click",this.handleClickEvent)}destroy(){this.view.dom.removeEventListener("click",this.handleClickEvent)}handleClickEvent(e){let{target:t}=e;if(!t||!(t instanceof HTMLInputElement)||t.type!=="checkbox")return!1;let n=t.closest("ul.plugin-tasks-query-result, div.callout-content");if(n){if(n.matches("div.callout-content")){let f=`obsidian-tasks-plugin warning: Tasks cannot add or remove completion dates or make the next copy of a recurring task for tasks written inside a callout when you click their checkboxes in Live Preview. -If you wanted Tasks to do these things, please undo your change, then either click the line of the task and use the "Toggle Task Done" command, or switch to Reading View to click the checkbox.`;console.warn(f),new Xg.Notice(f,45e3)}return!1}let{state:i}=this.view,s=this.view.posAtDOM(t),a=i.doc.lineAt(s),o=N.fromLine({line:a.text,path:"",sectionStart:0,sectionIndex:0,precedingHeader:null});if(console.debug(`Live Preview Extension: toggle called. Position: ${s} Line: ${a.text}`),o===null)return!1;e.preventDefault();let l=o.toggle().map(f=>f.toFileLineString()).join(i.lineBreak),c=i.update({changes:{from:a.from,to:a.to,insert:l}});this.view.dispatch(c);let d=t.checked;return setTimeout(()=>{t.checked=d},1),!0}};var p_=require("obsidian");var ya=class{constructor(e,t){this.nestingLevel=e,this.name=t}};var ga=class{constructor(e){this.lastHeadingAtLevel=new Array;let n=e.keys().next().value.length;for(let i=0;it.set(o,a)),e.pop();return t}};var Ta=class extends Map{},ba=class extends _a{},va=class{constructor(e,t){this.groups=new Ta;let n=this.buildGroupingTree(e,t);this.groups=n.generateAllPaths(),this.groups=this.getSortedGroups()}buildGroupingTree(e,t){let n=new ba(t),i=[n];for(let s of e){let a=[];for(let o of i)for(let u of o.values){let l=Er.getGroupNamesForTask(s.property,u);for(let c of l){let d=o.children.get(c);d===void 0&&(d=new ba([]),o.children.set(c,d),a.push(d)),d.values.push(u)}}i=a}return n}getSortedGroups(){return new Ta([...this.groups.entries()].sort())}};var Ea=class{constructor(e,t,n){this.groups=e,this.groupHeadings=t,this.tasks=n}tasksAsStringOfLines(){let e="";for(let t of this.tasks)e+=t.toFileLineString()+` +`),u=0,l=[];for(let d=a.lineStart;d<=a.lineEnd;d++){let f=o[d];if(f===void 0)continue;let p=N.fromLine({line:f,path:s,sectionStart:a.lineStart,sectionIndex:u,precedingHeader:null});p!==null&&(l.push(p),u++)}for(let d=0;dJg.ViewPlugin.fromClass(ad),ad=class{constructor(e){this.view=e,this.handleClickEvent=this.handleClickEvent.bind(this),this.view.dom.addEventListener("click",this.handleClickEvent)}destroy(){this.view.dom.removeEventListener("click",this.handleClickEvent)}handleClickEvent(e){let{target:t}=e;if(!t||!(t instanceof HTMLInputElement)||t.type!=="checkbox")return!1;let n=t.closest("ul.plugin-tasks-query-result, div.callout-content");if(n){if(n.matches("div.callout-content")){let f=`obsidian-tasks-plugin warning: Tasks cannot add or remove completion dates or make the next copy of a recurring task for tasks written inside a callout when you click their checkboxes in Live Preview. +If you wanted Tasks to do these things, please undo your change, then either click the line of the task and use the "Toggle Task Done" command, or switch to Reading View to click the checkbox.`;console.warn(f),new e_.Notice(f,45e3)}return!1}let{state:i}=this.view,s=this.view.posAtDOM(t),a=i.doc.lineAt(s),o=N.fromLine({line:a.text,path:"",sectionStart:0,sectionIndex:0,precedingHeader:null});if(console.debug(`Live Preview Extension: toggle called. Position: ${s} Line: ${a.text}`),o===null)return!1;e.preventDefault();let l=o.toggle().map(f=>f.toFileLineString()).join(i.lineBreak),c=i.update({changes:{from:a.from,to:a.to,insert:l}});this.view.dispatch(c);let d=t.checked;return setTimeout(()=>{t.checked=d},1),!0}};var La=require("obsidian");var ga=class{constructor(e,t){this.nestingLevel=e,this.name=t}};var _a=class{constructor(e){this.lastHeadingAtLevel=new Array;let n=e.keys().next().value.length;for(let i=0;it.set(o,a)),e.pop();return t}};var ba=class extends Map{},va=class extends Ta{},Ea=class{constructor(e,t){this.groups=new ba;let n=this.buildGroupingTree(e,t);this.groups=n.generateAllPaths(),this.groups=this.getSortedGroups()}buildGroupingTree(e,t){let n=new va(t),i=[n];for(let s of e){let a=[];for(let o of i)for(let u of o.values){let l=Rr.getGroupNamesForTask(s.property,u);for(let c of l){let d=o.children.get(c);d===void 0&&(d=new va([]),o.children.set(c,d),a.push(d)),d.values.push(u)}}i=a}return n}getSortedGroups(){return new ba([...this.groups.entries()].sort())}};var Ra=class{constructor(e,t,n){this.groups=e,this.groupHeadings=t,this.tasks=n}tasksAsStringOfLines(){let e="";for(let t of this.tasks)e+=t.toFileLineString()+` `;return e}toString(){let e=` `;e+=`Group names: [${this.groups}] `;for(let t of this.groupHeadings)e+=`${"#".repeat(4+t.nestingLevel)} ${t.name} -`;return e+=this.tasksAsStringOfLines(),e}};var Ra=class{constructor(e,t){this._groups=new Array;this._totalTaskCount=0;this._totalTaskCount=t.length;let n=new va(e,t);this.addTasks(n)}get groups(){return this._groups}totalTasksCount(){return this._totalTaskCount}toString(){let e="";for(let n of this.groups)e+=n.toString(),e+=` +`;return e+=this.tasksAsStringOfLines(),e}};var wa=class{constructor(e,t){this._groups=new Array;this._totalTaskCount=0;this._totalTaskCount=t.length;let n=new Ea(e,t);this.addTasks(n)}get groups(){return this._groups}totalTasksCount(){return this._totalTaskCount}toString(){let e="";for(let n of this.groups)e+=n.toString(),e+=` --- `;return e+=` ${this.totalTasksCount()} tasks -`,e}addTasks(e){let t=new ga(e.groups);for(let[n,i]of e.groups){let s=t.getHeadingsForTaskGroup(n),a=new Ea(n,s,i);this.add(a)}}add(e){this._groups.push(e)}};var Jg=as(Ee()),Qt=class{static parseDate(e,t=!1){return window.moment(Jg.parseDate(e,void 0,{forwardDate:t})).startOf("day")}};var de=class{canCreateFilterForLine(e){return de.lineMatchesFilter(this.filterRegexp(),e)}static lineMatchesFilter(e,t){return e?e.test(t):!1}static getMatch(e,t){return e?t.match(e):null}};var J=class{static fromFilter(e){let t=new J;return t.filter=e,t}static fromError(e){let t=new J;return t.error=e,t}};var Rr=class extends de{canCreateFilterForLine(e){return e===Rr.instructionForFieldPresence||e===Rr.instructionForFieldAbsence?!0:super.canCreateFilterForLine(e)}createFilterOrErrorMessage(e){let t=new J;if(e===Rr.instructionForFieldPresence){let i=new J;return i.filter=s=>this.dates(s).some(a=>a!==null),i}if(e===Rr.instructionForFieldAbsence){let i=new J;return i.filter=s=>!this.dates(s).some(a=>a!==null),i}let n=de.getMatch(this.filterRegexp(),e);if(n!==null){let i=Qt.parseDate(n[2]);i.isValid()?n[1]==="before"?t.filter=s=>this.dates(s).some(a=>a&&a.isBefore(i)):n[1]==="after"?t.filter=s=>this.dates(s).some(a=>a&&a.isAfter(i)):t.filter=s=>this.dates(s).some(a=>a&&a.isSame(i)):t.error="do not understand happens date"}else t.error="do not understand query filter (happens date)";return t}earliestDate(e){return new Rr().dates(e).sort(Ge.compareByDate)[0]}filterRegexp(){return Rr.happensRegexp}dates(e){return Array.of(e.startDate,e.scheduledDate,e.dueDate)}fieldName(){return"happens"}},Jt=Rr;Jt.happensRegexp=/^happens (before|after|on)? ?(.*)/,Jt.instructionForFieldPresence="has happens date",Jt.instructionForFieldAbsence="no happens date";var le=class{static by(e,t){return new Ra(e,t)}static getGroupNamesForTask(e,t){let n=le.groupers[e];return n(t)}static groupByPriority(e){let t="ERROR";switch(e.priority){case"1":t="High";break;case"2":t="Medium";break;case"3":t="None";break;case"4":t="Low";break}return[`Priority ${e.priority}: ${t}`]}static groupByRecurrence(e){return e.recurrence!==null?[e.recurrence.toText()]:["None"]}static groupByRecurring(e){return e.recurrence!==null?["Recurring"]:["Not Recurring"]}static groupByStartDate(e){return[le.stringFromDate(e.startDate,"start")]}static groupByScheduledDate(e){return[le.stringFromDate(e.scheduledDate,"scheduled")]}static groupByDueDate(e){return[le.stringFromDate(e.dueDate,"due")]}static groupByDoneDate(e){return[le.stringFromDate(e.doneDate,"done")]}static groupByHappensDate(e){let t=new Jt().earliestDate(e);return[le.stringFromDate(t,"happens")]}static stringFromDate(e,t){return e===null?"No "+t+" date":e.format(le.groupDateFormat)}static groupByPath(e){return[e.path.replace(".md","")]}static groupByFolder(e){let t=e.path,n=e.filename+".md",i=t.substring(0,t.lastIndexOf(n));return i===""?["/"]:[i]}static groupByFileName(e){let t=e.filename;return t===null?["Unknown Location"]:[t]}static groupByRoot(e){let t=e.path.replace(/\\/g,"/"),n=t.indexOf("/");return n==-1?["/"]:[t.substring(0,n+1)]}static groupByBacklink(e){let t=e.getLinkText({isFilenameUnique:!0});return t===null?["Unknown Location"]:[t]}static groupByStatus(e){return[e.status]}static groupByHeading(e){return e.precedingHeader===null||e.precedingHeader.length===0?["(No heading)"]:[e.precedingHeader]}static groupByTags(e){return e.tags.length==0?["(No tags)"]:e.tags}},Er=le;Er.groupDateFormat="YYYY-MM-DD dddd",Er.groupers={backlink:le.groupByBacklink,done:le.groupByDoneDate,due:le.groupByDueDate,filename:le.groupByFileName,folder:le.groupByFolder,happens:le.groupByHappensDate,heading:le.groupByHeading,path:le.groupByPath,priority:le.groupByPriority,recurrence:le.groupByRecurrence,recurring:le.groupByRecurring,root:le.groupByRoot,scheduled:le.groupByScheduledDate,start:le.groupByStartDate,status:le.groupByStatus,tags:le.groupByTags};var vn=class{matchesAnyOf(e){return e.some(t=>this.matches(t))}};var er=class extends vn{constructor(t){super();this.stringToFind=t}matches(t){return er.stringIncludesCaseInsensitive(t,this.stringToFind)}static stringIncludesCaseInsensitive(t,n){return t.toLocaleLowerCase().includes(n.toLocaleLowerCase())}};var wr=class extends vn{constructor(t){super();this.regex=t}static validateAndConstruct(t){let n=/\/((?![*+?])(?:[^\r\n[/\\]|\\.|\[(?:[^\r\n\]\\]|\\.)*])+)\/((?:g(?:im?|mi?)?|i(?:gm?|mg?)?|m(?:gi?|ig?)?)?)/,i=t.match(n);if(i!==null){let s=new RegExp(i[1],i[2]);return new wr(s)}else return null}matches(t){return t.match(this.regex)!==null}};var Ve=class extends de{createFilterOrErrorMessage(e){let t=de.getMatch(this.filterRegexp(),e);if(t===null)return J.fromError(`do not understand query filter (${this.fieldName()})`);let n=t[1],i=t[2],s=null;if(["includes","does not include"].includes(n))s=new er(i);else if(["regex matches","regex does not match"].includes(n)&&(s=wr.validateAndConstruct(i),s===null))return J.fromError(`cannot parse regex (${this.fieldName()}); check your leading and trailing slashes for your query`);return s===null?J.fromError(`do not understand query filter (${this.fieldName()})`):J.fromFilter(a=>Ve.maybeNegate(s.matches(this.value(a)),n))}static stringIncludesCaseInsensitive(e,t){return er.stringIncludesCaseInsensitive(e,t)}filterRegexp(){return new RegExp(`^${this.fieldName()} (includes|does not include|regex matches|regex does not match) (.*)`)}static maybeNegate(e,t){return t.match(/not/)?!e:e}};var wa=class extends Ve{fieldName(){return"description"}value(e){let t=ie().globalFilter;return e.description.replace(t,"").trim()}};var Ct=class extends de{constructor(){super(...arguments);this.instructionForFieldPresence=`has ${this.fieldName()} date`;this.instructionForFieldAbsence=`no ${this.fieldName()} date`}canCreateFilterForLine(t){return t===this.instructionForFieldPresence||t===this.instructionForFieldAbsence?!0:super.canCreateFilterForLine(t)}createFilterOrErrorMessage(t){let n=new J;if(t===this.instructionForFieldPresence)return n.filter=s=>this.date(s)!==null,n;if(t===this.instructionForFieldAbsence)return n.filter=s=>this.date(s)===null,n;let i=de.getMatch(this.filterRegexp(),t);if(i!==null){let s=Qt.parseDate(i[2]);s.isValid()?i[1]==="before"?n.filter=a=>{let o=this.date(a);return o?o.isBefore(s):this.filterResultIfFieldMissing()}:i[1]==="after"?n.filter=a=>{let o=this.date(a);return o?o.isAfter(s):this.filterResultIfFieldMissing()}:n.filter=a=>{let o=this.date(a);return o?o.isSame(s):this.filterResultIfFieldMissing()}:n.error="do not understand "+this.fieldName()+" date"}else n.error="do not understand query filter ("+this.fieldName()+" date)";return n}};var ad=class extends Ct{filterRegexp(){return ad.doneRegexp}fieldName(){return"done"}date(e){return e.doneDate}filterResultIfFieldMissing(){return!1}},ji=ad;ji.doneRegexp=/^done (before|after|on)? ?(.*)/;var od=class extends Ct{filterRegexp(){return od.dueRegexp}fieldName(){return"due"}date(e){return e.dueDate}filterResultIfFieldMissing(){return!1}},Bi=od;Bi.dueRegexp=/^due (before|after|on)? ?(.*)/;var Ma=class{constructor(e,t){this._instruction=e,this._filter=t}canCreateFilterForLine(e){return e==this._instruction}createFilterOrErrorMessage(e){let t=new J;return e===this._instruction?(t.filter=this._filter,t):(t.error=`do not understand filter: ${e}`,t)}};var Da=class{constructor(){this._filters=[]}add(e,t){this._filters.push(new Ma(e,t))}canCreateFilterForLine(e){for(let t of this._filters)if(t.canCreateFilterForLine(e))return!0;return!1}createFilterOrErrorMessage(e){for(let n of this._filters){let i=n.createFilterOrErrorMessage(e);if(i.error===void 0)return i}let t=new J;return t.error=`do not understand filter: ${e}`,t}};var Mr=class extends de{constructor(){super(...arguments);this._filters=new Da}canCreateFilterForLine(t){return this._filters.canCreateFilterForLine(t)}createFilterOrErrorMessage(t){return this._filters.createFilterOrErrorMessage(t)}filterRegexp(){return null}};var Pa=class extends Mr{constructor(){super(),this._filters.add("exclude sub-items",e=>{if(e.indentation==="")return!0;let t=e.indentation.lastIndexOf(">");return t===-1?!1:/^ ?$/.test(e.indentation.slice(t+1))})}fieldName(){return"exclude"}};var Oa=class extends Ve{fieldName(){return"heading"}value(e){return e.precedingHeader?e.precedingHeader:""}};var Aa=class extends Ve{fieldName(){return"path"}value(e){return e.path}};var ud=class extends de{createFilterOrErrorMessage(e){let t=new J,n=de.getMatch(this.filterRegexp(),e);if(n!==null){let i=n[3],s=null;switch(i){case"low":s="4";break;case"none":s="3";break;case"medium":s="2";break;case"high":s="1";break}if(s===null)return t.error="do not understand priority",t;let a;n[2]==="above"?a=o=>o.priority?o.priority.localeCompare(s)<0:!1:n[2]==="below"?a=o=>o.priority?o.priority.localeCompare(s)>0:!1:a=o=>o.priority?o.priority===s:!1,t.filter=a}else t.error="do not understand query filter (priority)";return t}fieldName(){return"priority"}filterRegexp(){return ud.priorityRegexp}},Gi=ud;Gi.priorityRegexp=/^priority (is )?(above|below)? ?(low|none|medium|high)/;var ld=class extends Ct{filterRegexp(){return ld.scheduledRegexp}fieldName(){return"scheduled"}date(e){return e.scheduledDate}filterResultIfFieldMissing(){return!1}},Hi=ld;Hi.scheduledRegexp=/^scheduled (before|after|on)? ?(.*)/;var cd=class extends Ct{filterRegexp(){return cd.startRegexp}fieldName(){return"start"}date(e){return e.startDate}filterResultIfFieldMissing(){return!0}},zi=cd;zi.startRegexp=/^starts (before|after|on)? ?(.*)/;var ka=class extends Mr{constructor(){super(),this._filters.add("is recurring",e=>e.recurrence!==null),this._filters.add("is not recurring",e=>e.recurrence===null)}fieldName(){return"recurring"}};var Na=class extends Mr{constructor(){super(),this._filters.add("done",e=>e.status==="Done"),this._filters.add("not done",e=>e.status!=="Done")}fieldName(){return"status"}};var dd=class extends de{createFilterOrErrorMessage(e){let t=de.getMatch(this.filterRegexp(),e);if(t===null)return J.fromError(`do not understand query filter (${this.fieldName()})`);let n=t[2],i=t[3],s=null;if(n.includes("include"))s=new er(i);else if(n.includes("regex")&&(s=wr.validateAndConstruct(i),s===null))return J.fromError(`cannot parse regex (${this.fieldName()}); check your leading and trailing slashes for your query`);return s===null?J.fromError(`do not understand query filter (${this.fieldName()})`):J.fromFilter(a=>Ve.maybeNegate(s.matchesAnyOf(a.tags),n))}fieldName(){return"tag/tags"}filterRegexp(){return dd.tagRegexp}},Ki=dd;Ki.tagRegexp=/^(tag|tags) (includes|does not include|include|do not include|regex matches|regex does not match) (.*)/;var f_=as(d_());var Ia=class extends de{constructor(){super(...arguments);this.basicBooleanRegexp=/.*(AND|OR|XOR|NOT)\s*[("].*/g;this.supportedOperators=["AND","OR","XOR","NOT"];this.subFields={}}filterRegexp(){return this.basicBooleanRegexp}createFilterOrErrorMessage(t){return this.parseLine(t)}fieldName(){return"boolean query"}parseLine(t){let n=new J;if(t.length===0)return n.error="empty line",n;let i=this.preprocessExpression(t);try{let s=(0,f_.parse)(i);for(let a of s)if(a.name==="IDENTIFIER"&&a.value){let o=a.value.trim();if(!(o in this.subFields)){let u=Ua(o);if(u===null)return n.error=`couldn't parse sub-expression '${o}'`,n;if(u.error)return n.error=`couldn't parse sub-expression '${o}': ${u.error}`,n;u.filter&&(this.subFields[o]=u.filter)}}else if(a.name==="OPERATOR"){if(a.value==null)return n.error="empty operator in boolean query",n;if(!this.supportedOperators.includes(a.value))return n.error=`unknown boolean operator '${a.value}'`,n}return n.filter=a=>this.filterTaskWithParsedQuery(a,s),n}catch(s){let a=s instanceof Error?s.message:"unknown error type";return n.error=`malformed boolean query -- ${a} (check the documentation for guidelines)`,n}return n}preprocessExpression(t){return t.replace(/\(([^()]+)\)/g,'("$1")')}filterTaskWithParsedQuery(t,n){let i=o=>o==="true",s=o=>o?"true":"false",a=[];for(let o of n)if(o.name==="IDENTIFIER"){if(o.value==null)throw Error("null token value");let u=this.subFields[o.value.trim()],l=u(t);a.push(s(l))}else if(o.name==="OPERATOR")if(o.value==="NOT"){let u=i(a.pop());a.push(s(!u))}else if(o.value==="OR"){let u=i(a.pop()),l=i(a.pop());a.push(s(u||l))}else if(o.value==="AND"){let u=i(a.pop()),l=i(a.pop());a.push(s(u&&l))}else if(o.value==="XOR"){let u=i(a.pop()),l=i(a.pop());a.push(s(u&&!l||!u&&l))}else throw Error("Unsupported operator: "+o.value);else throw Error("Unsupported token type: "+o);return i(a[0])}};var Fa=class extends Ve{fieldName(){return"filename"}value(e){let t=e.filename;return t===null?"":t+".md"}};var KO=[()=>new Na,()=>new ka,()=>new Gi,()=>new Jt,()=>new zi,()=>new Hi,()=>new Bi,()=>new ji,()=>new Aa,()=>new wa,()=>new Ki,()=>new Oa,()=>new Pa,()=>new Ia,()=>new Fa];function Ua(r){for(let e of KO){let t=e();if(t.canCreateFilterForLine(r))return t.createFilterOrErrorMessage(r)}return null}var Pn=class{constructor({source:e}){this._limit=void 0;this._layoutOptions=new Zr;this._filters=[];this._error=void 0;this._sorting=[];this._grouping=[];this.sortByRegexp=/^sort by (urgency|status|priority|start|scheduled|due|done|path|description|tag)( reverse)?[\s]*(\d+)?/;this.groupByRegexp=/^group by (backlink|done|due|filename|folder|happens|heading|path|priority|recurrence|recurring|root|scheduled|start|status|tags)/;this.hideOptionsRegexp=/^hide (task count|backlink|priority|start date|scheduled date|done date|due date|recurrence rule|edit button)/;this.shortModeRegexp=/^short/;this.limitRegexp=/^limit (to )?(\d+)( tasks?)?/;this.commentRegexp=/^#.*/;this.source=e,e.split(` -`).map(t=>t.trim()).forEach(t=>{switch(!0){case t==="":break;case this.shortModeRegexp.test(t):this._layoutOptions.shortMode=!0;break;case this.limitRegexp.test(t):this.parseLimit({line:t});break;case this.sortByRegexp.test(t):this.parseSortBy({line:t});break;case this.groupByRegexp.test(t):this.parseGroupBy({line:t});break;case this.hideOptionsRegexp.test(t):this.parseHideOptions({line:t});break;case this.commentRegexp.test(t):break;case this.parseFilter(t):break;default:this._error=`do not understand query: ${t}`}})}get limit(){return this._limit}get layoutOptions(){return this._layoutOptions}get filters(){return this._filters}get sorting(){return this._sorting}get grouping(){return this._grouping}get error(){return this._error}applyQueryToTasks(e){this.filters.forEach(n=>{e=e.filter(n)});let t=Ge.by(this,e).slice(0,this.limit);return Er.by(this.grouping,t)}parseHideOptions({line:e}){let t=e.match(this.hideOptionsRegexp);if(t!==null)switch(t[1].trim().toLowerCase()){case"task count":this._layoutOptions.hideTaskCount=!0;break;case"backlink":this._layoutOptions.hideBacklinks=!0;break;case"priority":this._layoutOptions.hidePriority=!0;break;case"start date":this._layoutOptions.hideStartDate=!0;break;case"scheduled date":this._layoutOptions.hideScheduledDate=!0;break;case"due date":this._layoutOptions.hideDueDate=!0;break;case"done date":this._layoutOptions.hideDoneDate=!0;break;case"recurrence rule":this._layoutOptions.hideRecurrenceRule=!0;break;case"edit button":this._layoutOptions.hideEditButton=!0;break;default:this._error="do not understand hide option"}}parseFilter(e){let t=Ua(e);return t!=null?(t.filter?this._filters.push(t.filter):this._error=t.error,!0):!1}parseLimit({line:e}){let t=e.match(this.limitRegexp);t!==null?this._limit=Number.parseInt(t[2],10):this._error="do not understand query limit"}parseSortBy({line:e}){let t=e.match(this.sortByRegexp);t!==null?this._sorting.push({property:t[1],reverse:!!t[2],propertyInstance:isNaN(+t[3])?1:+t[3]}):this._error="do not understand query sorting"}parseGroupBy({line:e}){let t=e.match(this.groupByRegexp);t!==null?this._grouping.push({property:t[1]}):this._error="do not understand query grouping"}};var qa=class{constructor({plugin:e,events:t}){this.addQueryRenderChild=this._addQueryRenderChild.bind(this);this.app=e.app,this.events=t,e.registerMarkdownCodeBlockProcessor("tasks",this._addQueryRenderChild.bind(this))}_addQueryRenderChild(e,t,n){return ae(this,null,function*(){n.addChild(new On({app:this.app,events:this.events,container:t,source:e,filePath:n.sourcePath}))})}},On=class extends p_.MarkdownRenderChild{constructor({app:t,events:n,container:i,source:s,filePath:a}){super(i);switch(this.app=t,this.events=n,this.source=s,this.filePath=a,this.containerEl.className){case"block-language-tasks":this.query=new Pn({source:s}),this.queryType="tasks";break;default:this.query=new Pn({source:s}),this.queryType="tasks";break}}onload(){this.events.triggerRequestCacheUpdate(this.render.bind(this)),this.renderEventRef=this.events.onCacheUpdate(this.render.bind(this)),this.reloadQueryAtMidnight()}onunload(){this.renderEventRef!==void 0&&this.events.off(this.renderEventRef),this.queryReloadTimeout!==void 0&&clearTimeout(this.queryReloadTimeout)}reloadQueryAtMidnight(){let t=new Date;t.setHours(24,0,0,0);let n=new Date,i=t.getTime()-n.getTime();this.queryReloadTimeout=setTimeout(()=>{this.query=new Pn({source:this.source}),this.events.triggerRequestCacheUpdate(this.render.bind(this)),this.reloadQueryAtMidnight()},i+1e3)}render(i){return ae(this,arguments,function*({tasks:t,state:n}){var a;let s=this.containerEl.createEl("div");if(n==="Warm"&&this.query.error===void 0){console.debug(`Render ${this.queryType} called for a block in active file "${this.filePath}", to select from ${t.length} tasks: plugin state: ${n}`);let o=this.query.applyQueryToTasks(t);for(let l of o.groups){On.addGroupHeadings(s,l.groupHeadings);let{taskList:c}=yield this.createTasksList({tasks:l.tasks,content:s});s.appendChild(c)}let u=o.totalTasksCount();console.debug(`${u} of ${t.length} tasks displayed in a block in "${this.filePath}"`),this.addTaskCount(s,u)}else this.query.error!==void 0?s.setText(`Tasks query: ${this.query.error}`):s.setText("Loading Tasks ...");(a=this.containerEl.firstChild)==null||a.replaceWith(s)})}createTasksList(i){return ae(this,arguments,function*({tasks:t,content:n}){let s=t.length,a=n.createEl("ul");a.addClasses(["contains-task-list","plugin-tasks-query-result"]);for(let o=0;oy.remove());let f=c.createSpan(),p=this.query.layoutOptions.shortMode;this.query.layoutOptions.hideBacklinks||this.addBacklinks(f,u,p,l),this.query.layoutOptions.hideEditButton||this.addEditButton(f,u),a.appendChild(c)}return{taskList:a,tasksCount:s}})}addEditButton(t,n){t.createEl("a",{cls:"tasks-edit"}).onClickEvent(s=>{s.preventDefault();let a=u=>{us({originalTask:n,newTasks:u})};new bn({app:this.app,task:n,onSubmit:a}).open()})}static addGroupHeadings(t,n){for(let i of n)On.addGroupHeading(t,i)}static addGroupHeading(t,n){let i;n.nestingLevel===0?i=t.createEl("h4",{cls:"tasks-group-heading"}):n.nestingLevel===1?i=t.createEl("h5",{cls:"tasks-group-heading"}):i=t.createEl("h6",{cls:"tasks-group-heading"}),i.appendText(n.name)}addBacklinks(t,n,i,s){var u;t.addClass("tasks-backlink"),i||t.append(" (");let a=t.createEl("a");if(a.href=n.path,a.setAttribute("data-href",n.path),a.rel="noopener",a.target="_blank",a.addClass("internal-link"),i&&a.addClass("internal-link-short-mode"),n.precedingHeader!==null){let l=n.precedingHeader.replace(/#/g,"");a.href=a.href+"#"+l,a.setAttribute("data-href",a.getAttribute("data-href")+"#"+l)}let o;i?o=" \u{1F517}":o=(u=n.getLinkText({isFilenameUnique:s}))!=null?u:"",a.setText(o),i||t.append(")")}addTaskCount(t,n){this.query.layoutOptions.hideTaskCount||t.createDiv({text:`${n} task${n!==1?"s":""}`,cls:"tasks-count"})}isFilenameUnique({task:t}){let n=t.path.match(/([^/]*)\..+$/i);if(n===null)return;let i=n[1];return this.app.vault.getMarkdownFiles().filter(a=>{if(a.basename===i)return!0}).length<2}};var sr=require("obsidian");var Wa=class extends sr.PluginSettingTab{constructor({plugin:t}){super(t.app,t);this.plugin=t}display(){let{containerEl:t}=this;t.empty(),t.createEl("h2",{text:"Tasks Settings"}),t.createEl("p",{cls:"tasks-setting-important",text:"Changing any settings requires a restart of obsidian."}),new sr.Setting(t).setName("Global task filter").setDesc("The global filter will be applied to all checklist items.").addText(n=>{let i=ie();n.setPlaceholder("#task").setValue(i.globalFilter).onChange(s=>ae(this,null,function*(){Ft({globalFilter:s}),yield this.plugin.saveSettings()}))}),t.createEl("div",{cls:"setting-item-description",text:'The global filter will be applied to all checklist items to filter out "non-task" checklist items.\nA checklist item must include the specified string in its description in order to be considered a task.\nFor example, if you set the global filter to `#task`, the Tasks plugin will only handle checklist items tagged with `#task`.\nOther checklist items will remain normal checklist items and not appear in queries or get a done date set.\nLeave empty if you want all checklist items from your vault to be tasks managed by this plugin.'}),new sr.Setting(t).setName("Remove global filter from description").setDesc("Enabling this removes the string that you set as global filter from the task description when displaying a task.").addToggle(n=>{let i=ie();n.setValue(i.removeGlobalFilter).onChange(s=>ae(this,null,function*(){Ft({removeGlobalFilter:s}),yield this.plugin.saveSettings()}))}),new sr.Setting(t).setName("Set done date on every completed task").setDesc("Enabling this will add a timestamp \u2705 YYYY-MM-DD at the end when a task is toggled to done").addToggle(n=>{let i=ie();n.setValue(i.setDoneDate).onChange(s=>ae(this,null,function*(){Ft({setDoneDate:s}),yield this.plugin.saveSettings()}))}),new sr.Setting(t).setName("Auto-suggest task content").setDesc("Enabling this will open an intelligent suggest menu while typing inside a recognized task line.").addToggle(n=>{let i=ie();n.setValue(i.autoSuggestInEditor).onChange(s=>ae(this,null,function*(){Ft({autoSuggestInEditor:s}),yield this.plugin.saveSettings()}))}),new sr.Setting(t).setName("Minimum match length for auto-suggest").setDesc("If higher than 0, auto-suggest will be triggered only when the beginning of any supported keywords is recognized.").addSlider(n=>{let i=ie();n.setLimits(0,3,1).setValue(i.autoSuggestMinMatch).setDynamicTooltip().onChange(s=>ae(this,null,function*(){Ft({autoSuggestMinMatch:s}),yield this.plugin.saveSettings()}))}),new sr.Setting(t).setName("Maximum number of auto-suggestions to show").setDesc('How many suggestions should be shown when an auto-suggest menu pops up (including the "\u23CE" option).').addSlider(n=>{let i=ie();n.setLimits(3,12,1).setValue(i.autoSuggestMaxItems).setDynamicTooltip().onChange(s=>ae(this,null,function*(){Ft({autoSuggestMaxItems:s}),yield this.plugin.saveSettings()}))})}};var m_=require("obsidian");var VO=`${wt}${Mt}${Dt}`;function h_(r,e,t){let n=[];n=n.concat(QO(r,e,t)),n=n.concat(JO(r,e,t));let i=XO(r,t),s=Rd(r,/([a-zA-Z'_-]*)/g,e),a=!1;if(s&&s.length>0){let o=s[0];if(o.length>=Math.max(1,t.autoSuggestMinMatch)){let u=i.filter(l=>l.displayText.toLowerCase().includes(o.toLowerCase()));for(let l of u)n.push({suggestionType:"match",displayText:l.displayText,appendText:l.appendText,insertAt:s.index,insertSkip:o.length}),a=!0}}return!a&&t.autoSuggestMinMatch===0&&(n=n.concat(i)),n.length>0&&!n.some(o=>o.suggestionType==="match")&&n.unshift({suggestionType:"empty",displayText:"\u23CE",appendText:` -`}),n=n.slice(0,t.autoSuggestMaxItems),n}function ZO(r){if(Object.values(Re).some(e=>e.length>0&&r.includes(e)))return!0}function XO(r,e){let t=[];return r.includes(Dt)||t.push({displayText:`${Dt} due date`,appendText:`${Dt} `}),r.includes(wt)||t.push({displayText:`${wt} start date`,appendText:`${wt} `}),r.includes(Mt)||t.push({displayText:`${Mt} scheduled date`,appendText:`${Mt} `}),ZO(r)||(t.push({displayText:`${Re.High} high priority`,appendText:`${Re.High} `}),t.push({displayText:`${Re.Medium} medium priority`,appendText:`${Re.Medium} `}),t.push({displayText:`${Re.Low} low priority`,appendText:`${Re.Low} `})),r.includes(Rt)||t.push({displayText:`${Rt} recurring (repeat)`,appendText:`${Rt} `}),t}function QO(r,e,t){let n=["today","tomorrow","Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","next week","next month","next year"],i=[],s=new RegExp(`([${VO}])\\s*([0-9a-zA-Z ]*)`,"ug"),a=Rd(r,s,e);if(a&&a.length>=2){let o=a[1],u=a[2];if(u.length1?Qt.parseDate(Tn(u),!0):null;l&&l.isValid()&&i.push({displayText:`${l.format(N.dateFormat)}`,appendText:`${o} ${l.format(N.dateFormat)} `,insertAt:a.index,insertSkip:a[0].length});let c=1,d=5,f=n.filter(p=>u&&u.length>=c&&p.toLowerCase().includes(u.toLowerCase())).slice(0,d);f.length===0&&(f=n.slice(0,d));for(let p of f){let m=`${Qt.parseDate(p,!0).format(N.dateFormat)}`;i.push({suggestionType:"match",displayText:`${p} (${m})`,appendText:`${o} ${m} `,insertAt:a.index,insertSkip:a[0].length})}}return i}function JO(r,e,t){var o;let n=["every","every day","every week","every month","every month on the","every year","every week on Sunday","every week on Monday","every week on Tuesday","every week on Wednesday","every week on Thursday","every week on Friday","every week on Saturday"],i=[],s=new RegExp(`(${Rt})\\s*([0-9a-zA-Z ]*)`,"ug"),a=Rd(r,s,e);if(a&&a.length>=2){let u=a[1],l=a[2];if(l.length0){let p=(o=pt.fromText({recurrenceRuleText:l,startDate:null,scheduledDate:null,dueDate:null}))==null?void 0:o.toText();if(p){let y=`${u} ${p} `;if(i.push({suggestionType:"match",displayText:`\u2705 ${p}`,appendText:y,insertAt:a.index,insertSkip:a[0].length}),a[0]==y)return[]}}let c=1,d=t.autoSuggestMaxItems/2,f=n.filter(p=>l&&l.length>=c&&p.toLowerCase().includes(l.toLowerCase())).slice(0,d);f.length===0&&l.trim().length===0&&(f=n.slice(0,d));for(let p of f)i.push({suggestionType:"match",displayText:`${p}`,appendText:`${u} ${p} `,insertAt:a.index,insertSkip:a[0].length})}return i}function Rd(r,e,t){let n=r.matchAll(e);for(let i of n)if((i==null?void 0:i.index)&&i.index<=t&&t<=i.index+i[0].length)return i;return[]}var La=class extends m_.EditorSuggest{constructor(t,n){super(t);this.settings=n}onTrigger(t,n,i){if(!this.settings.autoSuggestInEditor)return null;let s=n.getLine(t.line);return s.contains(this.settings.globalFilter)&&s.match(N.taskRegex)?{start:{line:t.line,ch:0},end:{line:t.line,ch:s.length},query:s}:null}getSuggestions(t){let n=t.query,i=t.editor.getCursor(),s=h_(n,i.ch,this.settings),a=[];for(let o of s)a.push(Ut($e({},o),{context:t}));return a}renderSuggestion(t,n){n.setText(t.displayText)}selectSuggestion(t,n){var u,l,c;let i=t.context.editor;if(t.suggestionType==="empty"){this.close();let d=new KeyboardEvent("keydown",{code:"Enter",key:"Enter"});(l=(u=i==null?void 0:i.cm)==null?void 0:u.contentDOM)==null||l.dispatchEvent(d);return}let s=t.context.editor.getCursor(),a={line:s.line,ch:(c=t.insertAt)!=null?c:s.ch},o=t.insertSkip?{line:s.line,ch:a.ch+t.insertSkip}:void 0;t.context.editor.replaceRange(t.appendText,a,o),t.context.editor.setCursor({line:s.line,ch:a.ch+t.appendText.length})}};var Ya=class extends y_.Plugin{onload(){return ae(this,null,function*(){console.log('loading plugin "tasks"'),yield this.loadSettings(),this.addSettingTab(new Wa({plugin:this})),Zd({metadataCache:this.app.metadataCache,vault:this.app.vault});let t=new ha({obsidianEvents:this.app.workspace});this.cache=new pr({metadataCache:this.app.metadataCache,vault:this.app.vault,events:t}),this.inlineRenderer=new ma({plugin:this}),this.queryRenderer=new qa({plugin:this,events:t}),this.registerEditorExtension(Qg()),this.registerEditorSuggest(new La(this.app,ie())),new pa({plugin:this})})}onunload(){var t;console.log('unloading plugin "tasks"'),(t=this.cache)==null||t.unload()}loadSettings(){return ae(this,null,function*(){let t=yield this.loadData();Ft(t)})}saveSettings(){return ae(this,null,function*(){yield this.saveData(ie())})}}; +`,e}addTasks(e){let t=new _a(e.groups);for(let[n,i]of e.groups){let s=t.getHeadingsForTaskGroup(n),a=new Ra(n,s,i);this.add(a)}}add(e){this._groups.push(e)}};var r_=os(Ee()),Jt=class{static parseDate(e,t=!1){return window.moment(r_.parseDate(e,void 0,{forwardDate:t})).startOf("day")}};var de=class{canCreateFilterForLine(e){return de.lineMatchesFilter(this.filterRegexp(),e)}static lineMatchesFilter(e,t){return e?e.test(t):!1}static getMatch(e,t){return e?t.match(e):null}};var ee=class{static fromFilter(e){let t=new ee;return t.filter=e,t}static fromError(e){let t=new ee;return t.error=e,t}};var wr=class extends de{canCreateFilterForLine(e){return e===wr.instructionForFieldPresence||e===wr.instructionForFieldAbsence?!0:super.canCreateFilterForLine(e)}createFilterOrErrorMessage(e){let t=new ee;if(e===wr.instructionForFieldPresence){let i=new ee;return i.filter=s=>this.dates(s).some(a=>a!==null),i}if(e===wr.instructionForFieldAbsence){let i=new ee;return i.filter=s=>!this.dates(s).some(a=>a!==null),i}let n=de.getMatch(this.filterRegexp(),e);if(n!==null){let i=Jt.parseDate(n[2]);i.isValid()?n[1]==="before"?t.filter=s=>this.dates(s).some(a=>a&&a.isBefore(i)):n[1]==="after"?t.filter=s=>this.dates(s).some(a=>a&&a.isAfter(i)):t.filter=s=>this.dates(s).some(a=>a&&a.isSame(i)):t.error="do not understand happens date"}else t.error="do not understand query filter (happens date)";return t}earliestDate(e){return new wr().dates(e).sort(Ge.compareByDate)[0]}filterRegexp(){return wr.happensRegexp}dates(e){return Array.of(e.startDate,e.scheduledDate,e.dueDate)}fieldName(){return"happens"}},er=wr;er.happensRegexp=/^happens (before|after|on)? ?(.*)/,er.instructionForFieldPresence="has happens date",er.instructionForFieldAbsence="no happens date";var Z=class{static by(e,t){return new wa(e,t)}static getGroupNamesForTask(e,t){let n=Z.groupers[e];return n(t)}static escapeMarkdownCharacters(e){return e.replace(/\\/g,"\\\\").replace(/_/g,"\\_")}static groupByPriority(e){let t="ERROR";switch(e.priority){case"1":t="High";break;case"2":t="Medium";break;case"3":t="None";break;case"4":t="Low";break}return[`Priority ${e.priority}: ${t}`]}static groupByRecurrence(e){return e.recurrence!==null?[e.recurrence.toText()]:["None"]}static groupByRecurring(e){return e.recurrence!==null?["Recurring"]:["Not Recurring"]}static groupByStartDate(e){return[Z.stringFromDate(e.startDate,"start")]}static groupByScheduledDate(e){return[Z.stringFromDate(e.scheduledDate,"scheduled")]}static groupByDueDate(e){return[Z.stringFromDate(e.dueDate,"due")]}static groupByDoneDate(e){return[Z.stringFromDate(e.doneDate,"done")]}static groupByHappensDate(e){let t=new er().earliestDate(e);return[Z.stringFromDate(t,"happens")]}static stringFromDate(e,t){return e===null?"No "+t+" date":e.format(Z.groupDateFormat)}static groupByPath(e){return[Z.escapeMarkdownCharacters(e.path.replace(".md",""))]}static groupByFolder(e){let t=e.path,n=e.filename+".md",i=t.substring(0,t.lastIndexOf(n));return i===""?["/"]:[Z.escapeMarkdownCharacters(i)]}static groupByFileName(e){let t=e.filename;return t===null?["Unknown Location"]:[Z.escapeMarkdownCharacters(t)]}static groupByRoot(e){let t=e.path.replace(/\\/g,"/"),n=t.indexOf("/");return n==-1?["/"]:[Z.escapeMarkdownCharacters(t.substring(0,n+1))]}static groupByBacklink(e){if(e.getLinkText({isFilenameUnique:!0})===null)return["Unknown Location"];let n=Z.groupByFileName(e)[0];if(e.precedingHeader===null||e.precedingHeader.length===0)return[n];let i=Z.groupByHeading(e)[0];return n===i?[n]:[`${n} > ${i}`]}static groupByStatus(e){return[e.status]}static groupByHeading(e){return e.precedingHeader===null||e.precedingHeader.length===0?["(No heading)"]:[e.precedingHeader]}static groupByTags(e){return e.tags.length==0?["(No tags)"]:e.tags}},Rr=Z;Rr.groupDateFormat="YYYY-MM-DD dddd",Rr.groupers={backlink:Z.groupByBacklink,done:Z.groupByDoneDate,due:Z.groupByDueDate,filename:Z.groupByFileName,folder:Z.groupByFolder,happens:Z.groupByHappensDate,heading:Z.groupByHeading,path:Z.groupByPath,priority:Z.groupByPriority,recurrence:Z.groupByRecurrence,recurring:Z.groupByRecurring,root:Z.groupByRoot,scheduled:Z.groupByScheduledDate,start:Z.groupByStartDate,status:Z.groupByStatus,tags:Z.groupByTags};var En=class{matchesAnyOf(e){return e.some(t=>this.matches(t))}};var tr=class extends En{constructor(t){super();this.stringToFind=t}matches(t){return tr.stringIncludesCaseInsensitive(t,this.stringToFind)}static stringIncludesCaseInsensitive(t,n){return t.toLocaleLowerCase().includes(n.toLocaleLowerCase())}};var Mr=class extends En{constructor(t){super();this.regex=t}static validateAndConstruct(t){let n=/\/((?![*+?])(?:[^\r\n[/\\]|\\.|\[(?:[^\r\n\]\\]|\\.)*])+)\/((?:g(?:im?|mi?)?|i(?:gm?|mg?)?|m(?:gi?|ig?)?)?)/,i=t.match(n);if(i!==null){let s=new RegExp(i[1],i[2]);return new Mr(s)}else return null}matches(t){return t.match(this.regex)!==null}};var Ve=class extends de{createFilterOrErrorMessage(e){let t=de.getMatch(this.filterRegexp(),e);if(t===null)return ee.fromError(`do not understand query filter (${this.fieldName()})`);let n=t[1],i=t[2],s=null;if(["includes","does not include"].includes(n))s=new tr(i);else if(["regex matches","regex does not match"].includes(n)&&(s=Mr.validateAndConstruct(i),s===null))return ee.fromError(`cannot parse regex (${this.fieldName()}); check your leading and trailing slashes for your query`);return s===null?ee.fromError(`do not understand query filter (${this.fieldName()})`):ee.fromFilter(a=>Ve.maybeNegate(s.matches(this.value(a)),n))}static stringIncludesCaseInsensitive(e,t){return tr.stringIncludesCaseInsensitive(e,t)}filterRegexp(){return new RegExp(`^${this.fieldName()} (includes|does not include|regex matches|regex does not match) (.*)`)}static maybeNegate(e,t){return t.match(/not/)?!e:e}};var Ma=class extends Ve{fieldName(){return"description"}value(e){let t=ae().globalFilter;return e.description.replace(t,"").trim()}};var Ct=class extends de{constructor(){super(...arguments);this.instructionForFieldPresence=`has ${this.fieldName()} date`;this.instructionForFieldAbsence=`no ${this.fieldName()} date`}canCreateFilterForLine(t){return t===this.instructionForFieldPresence||t===this.instructionForFieldAbsence?!0:super.canCreateFilterForLine(t)}createFilterOrErrorMessage(t){let n=new ee;if(t===this.instructionForFieldPresence)return n.filter=s=>this.date(s)!==null,n;if(t===this.instructionForFieldAbsence)return n.filter=s=>this.date(s)===null,n;let i=de.getMatch(this.filterRegexp(),t);if(i!==null){let s=Jt.parseDate(i[2]);s.isValid()?i[1]==="before"?n.filter=a=>{let o=this.date(a);return o?o.isBefore(s):this.filterResultIfFieldMissing()}:i[1]==="after"?n.filter=a=>{let o=this.date(a);return o?o.isAfter(s):this.filterResultIfFieldMissing()}:n.filter=a=>{let o=this.date(a);return o?o.isSame(s):this.filterResultIfFieldMissing()}:n.error="do not understand "+this.fieldName()+" date"}else n.error="do not understand query filter ("+this.fieldName()+" date)";return n}};var od=class extends Ct{filterRegexp(){return od.doneRegexp}fieldName(){return"done"}date(e){return e.doneDate}filterResultIfFieldMissing(){return!1}},Bi=od;Bi.doneRegexp=/^done (before|after|on)? ?(.*)/;var ud=class extends Ct{filterRegexp(){return ud.dueRegexp}fieldName(){return"due"}date(e){return e.dueDate}filterResultIfFieldMissing(){return!1}},Gi=ud;Gi.dueRegexp=/^due (before|after|on)? ?(.*)/;var Da=class{constructor(e,t){this._instruction=e,this._filter=t}canCreateFilterForLine(e){return e==this._instruction}createFilterOrErrorMessage(e){let t=new ee;return e===this._instruction?(t.filter=this._filter,t):(t.error=`do not understand filter: ${e}`,t)}};var Pa=class{constructor(){this._filters=[]}add(e,t){this._filters.push(new Da(e,t))}canCreateFilterForLine(e){for(let t of this._filters)if(t.canCreateFilterForLine(e))return!0;return!1}createFilterOrErrorMessage(e){for(let n of this._filters){let i=n.createFilterOrErrorMessage(e);if(i.error===void 0)return i}let t=new ee;return t.error=`do not understand filter: ${e}`,t}};var Dr=class extends de{constructor(){super(...arguments);this._filters=new Pa}canCreateFilterForLine(t){return this._filters.canCreateFilterForLine(t)}createFilterOrErrorMessage(t){return this._filters.createFilterOrErrorMessage(t)}filterRegexp(){return null}};var Oa=class extends Dr{constructor(){super(),this._filters.add("exclude sub-items",e=>{if(e.indentation==="")return!0;let t=e.indentation.lastIndexOf(">");return t===-1?!1:/^ ?$/.test(e.indentation.slice(t+1))})}fieldName(){return"exclude"}};var Aa=class extends Ve{fieldName(){return"heading"}value(e){return e.precedingHeader?e.precedingHeader:""}};var ka=class extends Ve{fieldName(){return"path"}value(e){return e.path}};var ld=class extends de{createFilterOrErrorMessage(e){let t=new ee,n=de.getMatch(this.filterRegexp(),e);if(n!==null){let i=n[3],s=null;switch(i){case"low":s="4";break;case"none":s="3";break;case"medium":s="2";break;case"high":s="1";break}if(s===null)return t.error="do not understand priority",t;let a;n[2]==="above"?a=o=>o.priority?o.priority.localeCompare(s)<0:!1:n[2]==="below"?a=o=>o.priority?o.priority.localeCompare(s)>0:!1:a=o=>o.priority?o.priority===s:!1,t.filter=a}else t.error="do not understand query filter (priority)";return t}fieldName(){return"priority"}filterRegexp(){return ld.priorityRegexp}},Hi=ld;Hi.priorityRegexp=/^priority (is )?(above|below)? ?(low|none|medium|high)/;var cd=class extends Ct{filterRegexp(){return cd.scheduledRegexp}fieldName(){return"scheduled"}date(e){return e.scheduledDate}filterResultIfFieldMissing(){return!1}},zi=cd;zi.scheduledRegexp=/^scheduled (before|after|on)? ?(.*)/;var dd=class extends Ct{filterRegexp(){return dd.startRegexp}fieldName(){return"start"}date(e){return e.startDate}filterResultIfFieldMissing(){return!0}},Ki=dd;Ki.startRegexp=/^starts (before|after|on)? ?(.*)/;var Na=class extends Dr{constructor(){super(),this._filters.add("is recurring",e=>e.recurrence!==null),this._filters.add("is not recurring",e=>e.recurrence===null)}fieldName(){return"recurring"}};var xa=class extends Dr{constructor(){super(),this._filters.add("done",e=>e.status==="Done"),this._filters.add("not done",e=>e.status!=="Done")}fieldName(){return"status"}};var fd=class extends de{createFilterOrErrorMessage(e){let t=de.getMatch(this.filterRegexp(),e);if(t===null)return ee.fromError(`do not understand query filter (${this.fieldName()})`);let n=t[2],i=t[3],s=null;if(n.includes("include"))s=new tr(i);else if(n.includes("regex")&&(s=Mr.validateAndConstruct(i),s===null))return ee.fromError(`cannot parse regex (${this.fieldName()}); check your leading and trailing slashes for your query`);return s===null?ee.fromError(`do not understand query filter (${this.fieldName()})`):ee.fromFilter(a=>Ve.maybeNegate(s.matchesAnyOf(a.tags),n))}fieldName(){return"tag/tags"}filterRegexp(){return fd.tagRegexp}},Vi=fd;Vi.tagRegexp=/^(tag|tags) (includes|does not include|include|do not include|regex matches|regex does not match) (.*)/;var m_=os(h_());var Ua=class extends de{constructor(){super(...arguments);this.basicBooleanRegexp=/.*(AND|OR|XOR|NOT)\s*[("].*/g;this.supportedOperators=["AND","OR","XOR","NOT"];this.subFields={}}filterRegexp(){return this.basicBooleanRegexp}createFilterOrErrorMessage(t){return this.parseLine(t)}fieldName(){return"boolean query"}parseLine(t){let n=new ee;if(t.length===0)return n.error="empty line",n;let i=this.preprocessExpression(t);try{let s=(0,m_.parse)(i);for(let a of s)if(a.name==="IDENTIFIER"&&a.value){let o=a.value.trim();if(!(o in this.subFields)){let u=Fa(o);if(u===null)return n.error=`couldn't parse sub-expression '${o}'`,n;if(u.error)return n.error=`couldn't parse sub-expression '${o}': ${u.error}`,n;u.filter&&(this.subFields[o]=u.filter)}}else if(a.name==="OPERATOR"){if(a.value==null)return n.error="empty operator in boolean query",n;if(!this.supportedOperators.includes(a.value))return n.error=`unknown boolean operator '${a.value}'`,n}return n.filter=a=>this.filterTaskWithParsedQuery(a,s),n}catch(s){let a=s instanceof Error?s.message:"unknown error type";return n.error=`malformed boolean query -- ${a} (check the documentation for guidelines)`,n}return n}preprocessExpression(t){return t.replace(/\(([^()]+)\)/g,'("$1")')}filterTaskWithParsedQuery(t,n){let i=o=>o==="true",s=o=>o?"true":"false",a=[];for(let o of n)if(o.name==="IDENTIFIER"){if(o.value==null)throw Error("null token value");let u=this.subFields[o.value.trim()],l=u(t);a.push(s(l))}else if(o.name==="OPERATOR")if(o.value==="NOT"){let u=i(a.pop());a.push(s(!u))}else if(o.value==="OR"){let u=i(a.pop()),l=i(a.pop());a.push(s(u||l))}else if(o.value==="AND"){let u=i(a.pop()),l=i(a.pop());a.push(s(u&&l))}else if(o.value==="XOR"){let u=i(a.pop()),l=i(a.pop());a.push(s(u&&!l||!u&&l))}else throw Error("Unsupported operator: "+o.value);else throw Error("Unsupported token type: "+o);return i(a[0])}};var qa=class extends Ve{fieldName(){return"filename"}value(e){let t=e.filename;return t===null?"":t+".md"}};var XO=[()=>new xa,()=>new Na,()=>new Hi,()=>new er,()=>new Ki,()=>new zi,()=>new Gi,()=>new Bi,()=>new ka,()=>new Ma,()=>new Vi,()=>new Aa,()=>new Oa,()=>new Ua,()=>new qa];function Fa(r){for(let e of XO){let t=e();if(t.canCreateFilterForLine(r))return t.createFilterOrErrorMessage(r)}return null}var On=class{constructor({source:e}){this._limit=void 0;this._layoutOptions=new Xr;this._filters=[];this._error=void 0;this._sorting=[];this._grouping=[];this.sortByRegexp=/^sort by (urgency|status|priority|start|scheduled|due|done|path|description|tag)( reverse)?[\s]*(\d+)?/;this.groupByRegexp=/^group by (backlink|done|due|filename|folder|happens|heading|path|priority|recurrence|recurring|root|scheduled|start|status|tags)/;this.hideOptionsRegexp=/^hide (task count|backlink|priority|start date|scheduled date|done date|due date|recurrence rule|edit button)/;this.shortModeRegexp=/^short/;this.limitRegexp=/^limit (to )?(\d+)( tasks?)?/;this.commentRegexp=/^#.*/;this.source=e,e.split(` +`).map(t=>t.trim()).forEach(t=>{switch(!0){case t==="":break;case this.shortModeRegexp.test(t):this._layoutOptions.shortMode=!0;break;case this.limitRegexp.test(t):this.parseLimit({line:t});break;case this.sortByRegexp.test(t):this.parseSortBy({line:t});break;case this.groupByRegexp.test(t):this.parseGroupBy({line:t});break;case this.hideOptionsRegexp.test(t):this.parseHideOptions({line:t});break;case this.commentRegexp.test(t):break;case this.parseFilter(t):break;default:this._error=`do not understand query: ${t}`}})}get limit(){return this._limit}get layoutOptions(){return this._layoutOptions}get filters(){return this._filters}get sorting(){return this._sorting}get grouping(){return this._grouping}get error(){return this._error}applyQueryToTasks(e){this.filters.forEach(n=>{e=e.filter(n)});let t=Ge.by(this,e).slice(0,this.limit);return Rr.by(this.grouping,t)}parseHideOptions({line:e}){let t=e.match(this.hideOptionsRegexp);if(t!==null)switch(t[1].trim().toLowerCase()){case"task count":this._layoutOptions.hideTaskCount=!0;break;case"backlink":this._layoutOptions.hideBacklinks=!0;break;case"priority":this._layoutOptions.hidePriority=!0;break;case"start date":this._layoutOptions.hideStartDate=!0;break;case"scheduled date":this._layoutOptions.hideScheduledDate=!0;break;case"due date":this._layoutOptions.hideDueDate=!0;break;case"done date":this._layoutOptions.hideDoneDate=!0;break;case"recurrence rule":this._layoutOptions.hideRecurrenceRule=!0;break;case"edit button":this._layoutOptions.hideEditButton=!0;break;default:this._error="do not understand hide option"}}parseFilter(e){let t=Fa(e);return t!=null?(t.filter?this._filters.push(t.filter):this._error=t.error,!0):!1}parseLimit({line:e}){let t=e.match(this.limitRegexp);t!==null?this._limit=Number.parseInt(t[2],10):this._error="do not understand query limit"}parseSortBy({line:e}){let t=e.match(this.sortByRegexp);t!==null?this._sorting.push({property:t[1],reverse:!!t[2],propertyInstance:isNaN(+t[3])?1:+t[3]}):this._error="do not understand query sorting"}parseGroupBy({line:e}){let t=e.match(this.groupByRegexp);t!==null?this._grouping.push({property:t[1]}):this._error="do not understand query grouping"}};var Wa=class{constructor({plugin:e,events:t}){this.addQueryRenderChild=this._addQueryRenderChild.bind(this);this.app=e.app,this.events=t,e.registerMarkdownCodeBlockProcessor("tasks",this._addQueryRenderChild.bind(this))}_addQueryRenderChild(e,t,n){return se(this,null,function*(){n.addChild(new wd({app:this.app,events:this.events,container:t,source:e,filePath:n.sourcePath}))})}},wd=class extends La.MarkdownRenderChild{constructor({app:t,events:n,container:i,source:s,filePath:a}){super(i);switch(this.app=t,this.events=n,this.source=s,this.filePath=a,this.containerEl.className){case"block-language-tasks":this.query=new On({source:s}),this.queryType="tasks";break;default:this.query=new On({source:s}),this.queryType="tasks";break}}onload(){this.events.triggerRequestCacheUpdate(this.render.bind(this)),this.renderEventRef=this.events.onCacheUpdate(this.render.bind(this)),this.reloadQueryAtMidnight()}onunload(){this.renderEventRef!==void 0&&this.events.off(this.renderEventRef),this.queryReloadTimeout!==void 0&&clearTimeout(this.queryReloadTimeout)}reloadQueryAtMidnight(){let t=new Date;t.setHours(24,0,0,0);let n=new Date,i=t.getTime()-n.getTime();this.queryReloadTimeout=setTimeout(()=>{this.query=new On({source:this.source}),this.events.triggerRequestCacheUpdate(this.render.bind(this)),this.reloadQueryAtMidnight()},i+1e3)}render(i){return se(this,arguments,function*({tasks:t,state:n}){var a;let s=this.containerEl.createEl("div");if(n==="Warm"&&this.query.error===void 0){console.debug(`Render ${this.queryType} called for a block in active file "${this.filePath}", to select from ${t.length} tasks: plugin state: ${n}`);let o=this.query.applyQueryToTasks(t);for(let l of o.groups){this.addGroupHeadings(s,l.groupHeadings);let{taskList:c}=yield this.createTasksList({tasks:l.tasks,content:s});s.appendChild(c)}let u=o.totalTasksCount();console.debug(`${u} of ${t.length} tasks displayed in a block in "${this.filePath}"`),this.addTaskCount(s,u)}else this.query.error!==void 0?s.setText(`Tasks query: ${this.query.error}`):s.setText("Loading Tasks ...");(a=this.containerEl.firstChild)==null||a.replaceWith(s)})}createTasksList(i){return se(this,arguments,function*({tasks:t,content:n}){let s=t.length,a=n.createEl("ul");a.addClasses(["contains-task-list","plugin-tasks-query-result"]);for(let o=0;oy.remove());let f=c.createSpan(),p=this.query.layoutOptions.shortMode;this.query.layoutOptions.hideBacklinks||this.addBacklinks(f,u,p,l),this.query.layoutOptions.hideEditButton||this.addEditButton(f,u),a.appendChild(c)}return{taskList:a,tasksCount:s}})}addEditButton(t,n){t.createEl("a",{cls:"tasks-edit"}).onClickEvent(s=>{s.preventDefault();let a=u=>{ls({originalTask:n,newTasks:u})};new vn({app:this.app,task:n,onSubmit:a}).open()})}addGroupHeadings(t,n){for(let i of n)this.addGroupHeading(t,i)}addGroupHeading(t,n){return se(this,null,function*(){let i;n.nestingLevel===0?i=t.createEl("h4",{cls:"tasks-group-heading"}):n.nestingLevel===1?i=t.createEl("h5",{cls:"tasks-group-heading"}):i=t.createEl("h6",{cls:"tasks-group-heading"}),yield La.MarkdownRenderer.renderMarkdown(n.name,i,this.filePath,this)})}addBacklinks(t,n,i,s){var u;t.addClass("tasks-backlink"),i||t.append(" (");let a=t.createEl("a");if(a.href=n.path,a.setAttribute("data-href",n.path),a.rel="noopener",a.target="_blank",a.addClass("internal-link"),i&&a.addClass("internal-link-short-mode"),n.precedingHeader!==null){let l=n.precedingHeader.replace(/#/g,"");a.href=a.href+"#"+l,a.setAttribute("data-href",a.getAttribute("data-href")+"#"+l)}let o;i?o=" \u{1F517}":o=(u=n.getLinkText({isFilenameUnique:s}))!=null?u:"",a.setText(o),i||t.append(")")}addTaskCount(t,n){this.query.layoutOptions.hideTaskCount||t.createDiv({text:`${n} task${n!==1?"s":""}`,cls:"tasks-count"})}isFilenameUnique({task:t}){let n=t.path.match(/([^/]*)\..+$/i);if(n===null)return;let i=n[1];return this.app.vault.getMarkdownFiles().filter(a=>{if(a.basename===i)return!0}).length<2}};var ar=require("obsidian");var Ya=class extends ar.PluginSettingTab{constructor({plugin:t}){super(t.app,t);this.plugin=t}display(){let{containerEl:t}=this;t.empty(),t.createEl("h2",{text:"Tasks Settings"}),t.createEl("p",{cls:"tasks-setting-important",text:"Changing any settings requires a restart of obsidian."}),new ar.Setting(t).setName("Global task filter").setDesc("The global filter will be applied to all checklist items.").addText(n=>{let i=ae();n.setPlaceholder("#task").setValue(i.globalFilter).onChange(s=>se(this,null,function*(){qt({globalFilter:s}),yield this.plugin.saveSettings()}))}),t.createEl("div",{cls:"setting-item-description",text:'The global filter will be applied to all checklist items to filter out "non-task" checklist items.\nA checklist item must include the specified string in its description in order to be considered a task.\nFor example, if you set the global filter to `#task`, the Tasks plugin will only handle checklist items tagged with `#task`.\nOther checklist items will remain normal checklist items and not appear in queries or get a done date set.\nLeave empty if you want all checklist items from your vault to be tasks managed by this plugin.'}),new ar.Setting(t).setName("Remove global filter from description").setDesc("Enabling this removes the string that you set as global filter from the task description when displaying a task.").addToggle(n=>{let i=ae();n.setValue(i.removeGlobalFilter).onChange(s=>se(this,null,function*(){qt({removeGlobalFilter:s}),yield this.plugin.saveSettings()}))}),new ar.Setting(t).setName("Set done date on every completed task").setDesc("Enabling this will add a timestamp \u2705 YYYY-MM-DD at the end when a task is toggled to done").addToggle(n=>{let i=ae();n.setValue(i.setDoneDate).onChange(s=>se(this,null,function*(){qt({setDoneDate:s}),yield this.plugin.saveSettings()}))}),new ar.Setting(t).setName("Auto-suggest task content").setDesc("Enabling this will open an intelligent suggest menu while typing inside a recognized task line.").addToggle(n=>{let i=ae();n.setValue(i.autoSuggestInEditor).onChange(s=>se(this,null,function*(){qt({autoSuggestInEditor:s}),yield this.plugin.saveSettings()}))}),new ar.Setting(t).setName("Minimum match length for auto-suggest").setDesc("If higher than 0, auto-suggest will be triggered only when the beginning of any supported keywords is recognized.").addSlider(n=>{let i=ae();n.setLimits(0,3,1).setValue(i.autoSuggestMinMatch).setDynamicTooltip().onChange(s=>se(this,null,function*(){qt({autoSuggestMinMatch:s}),yield this.plugin.saveSettings()}))}),new ar.Setting(t).setName("Maximum number of auto-suggestions to show").setDesc('How many suggestions should be shown when an auto-suggest menu pops up (including the "\u23CE" option).').addSlider(n=>{let i=ae();n.setLimits(3,12,1).setValue(i.autoSuggestMaxItems).setDynamicTooltip().onChange(s=>se(this,null,function*(){qt({autoSuggestMaxItems:s}),yield this.plugin.saveSettings()}))})}};var g_=require("obsidian");var QO=`${Mt}${Dt}${Pt}`;function y_(r,e,t){let n=[];n=n.concat(tA(r,e,t)),n=n.concat(rA(r,e,t));let i=eA(r,t),s=Md(r,/([a-zA-Z'_-]*)/g,e),a=!1;if(s&&s.length>0){let o=s[0];if(o.length>=Math.max(1,t.autoSuggestMinMatch)){let u=i.filter(l=>l.displayText.toLowerCase().includes(o.toLowerCase()));for(let l of u)n.push({suggestionType:"match",displayText:l.displayText,appendText:l.appendText,insertAt:s.index,insertSkip:o.length}),a=!0}}return!a&&t.autoSuggestMinMatch===0&&(n=n.concat(i)),n.length>0&&!n.some(o=>o.suggestionType==="match")&&n.unshift({suggestionType:"empty",displayText:"\u23CE",appendText:` +`}),n=n.slice(0,t.autoSuggestMaxItems),n}function JO(r){if(Object.values(Re).some(e=>e.length>0&&r.includes(e)))return!0}function eA(r,e){let t=[];return r.includes(Pt)||t.push({displayText:`${Pt} due date`,appendText:`${Pt} `}),r.includes(Mt)||t.push({displayText:`${Mt} start date`,appendText:`${Mt} `}),r.includes(Dt)||t.push({displayText:`${Dt} scheduled date`,appendText:`${Dt} `}),JO(r)||(t.push({displayText:`${Re.High} high priority`,appendText:`${Re.High} `}),t.push({displayText:`${Re.Medium} medium priority`,appendText:`${Re.Medium} `}),t.push({displayText:`${Re.Low} low priority`,appendText:`${Re.Low} `})),r.includes(wt)||t.push({displayText:`${wt} recurring (repeat)`,appendText:`${wt} `}),t}function tA(r,e,t){let n=["today","tomorrow","Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","next week","next month","next year"],i=[],s=new RegExp(`([${QO}])\\s*([0-9a-zA-Z ]*)`,"ug"),a=Md(r,s,e);if(a&&a.length>=2){let o=a[1],u=a[2];if(u.length1?Jt.parseDate(bn(u),!0):null;l&&l.isValid()&&i.push({displayText:`${l.format(N.dateFormat)}`,appendText:`${o} ${l.format(N.dateFormat)} `,insertAt:a.index,insertSkip:a[0].length});let c=1,d=5,f=n.filter(p=>u&&u.length>=c&&p.toLowerCase().includes(u.toLowerCase())).slice(0,d);f.length===0&&(f=n.slice(0,d));for(let p of f){let m=`${Jt.parseDate(p,!0).format(N.dateFormat)}`;i.push({suggestionType:"match",displayText:`${p} (${m})`,appendText:`${o} ${m} `,insertAt:a.index,insertSkip:a[0].length})}}return i}function rA(r,e,t){var o;let n=["every","every day","every week","every month","every month on the","every year","every week on Sunday","every week on Monday","every week on Tuesday","every week on Wednesday","every week on Thursday","every week on Friday","every week on Saturday"],i=[],s=new RegExp(`(${wt})\\s*([0-9a-zA-Z ]*)`,"ug"),a=Md(r,s,e);if(a&&a.length>=2){let u=a[1],l=a[2];if(l.length0){let p=(o=pt.fromText({recurrenceRuleText:l,startDate:null,scheduledDate:null,dueDate:null}))==null?void 0:o.toText();if(p){let y=`${u} ${p} `;if(i.push({suggestionType:"match",displayText:`\u2705 ${p}`,appendText:y,insertAt:a.index,insertSkip:a[0].length}),a[0]==y)return[]}}let c=1,d=t.autoSuggestMaxItems/2,f=n.filter(p=>l&&l.length>=c&&p.toLowerCase().includes(l.toLowerCase())).slice(0,d);f.length===0&&l.trim().length===0&&(f=n.slice(0,d));for(let p of f)i.push({suggestionType:"match",displayText:`${p}`,appendText:`${u} ${p} `,insertAt:a.index,insertSkip:a[0].length})}return i}function Md(r,e,t){let n=r.matchAll(e);for(let i of n)if((i==null?void 0:i.index)&&i.index<=t&&t<=i.index+i[0].length)return i;return[]}var $a=class extends g_.EditorSuggest{constructor(t,n){super(t);this.settings=n}onTrigger(t,n,i){if(!this.settings.autoSuggestInEditor)return null;let s=n.getLine(t.line);return s.contains(this.settings.globalFilter)&&s.match(N.taskRegex)?{start:{line:t.line,ch:0},end:{line:t.line,ch:s.length},query:s}:null}getSuggestions(t){let n=t.query,i=t.editor.getCursor(),s=y_(n,i.ch,this.settings),a=[];for(let o of s)a.push(Ft($e({},o),{context:t}));return a}renderSuggestion(t,n){n.setText(t.displayText)}selectSuggestion(t,n){var u,l,c;let i=t.context.editor;if(t.suggestionType==="empty"){this.close();let d=new KeyboardEvent("keydown",{code:"Enter",key:"Enter"});(l=(u=i==null?void 0:i.cm)==null?void 0:u.contentDOM)==null||l.dispatchEvent(d);return}let s=t.context.editor.getCursor(),a={line:s.line,ch:(c=t.insertAt)!=null?c:s.ch},o=t.insertSkip?{line:s.line,ch:a.ch+t.insertSkip}:void 0;t.context.editor.replaceRange(t.appendText,a,o),t.context.editor.setCursor({line:s.line,ch:a.ch+t.appendText.length})}};var ja=class extends __.Plugin{onload(){return se(this,null,function*(){console.log('loading plugin "tasks"'),yield this.loadSettings(),this.addSettingTab(new Ya({plugin:this})),Jd({metadataCache:this.app.metadataCache,vault:this.app.vault});let t=new ma({obsidianEvents:this.app.workspace});this.cache=new hr({metadataCache:this.app.metadataCache,vault:this.app.vault,events:t}),this.inlineRenderer=new ya({plugin:this}),this.queryRenderer=new Wa({plugin:this,events:t}),this.registerEditorExtension(t_()),this.registerEditorSuggest(new $a(this.app,ae())),new ha({plugin:this})})}onunload(){var t;console.log('unloading plugin "tasks"'),(t=this.cache)==null||t.unload()}loadSettings(){return se(this,null,function*(){let t=yield this.loadData();qt(t)})}saveSettings(){return se(this,null,function*(){yield this.saveData(ae())})}}; diff --git a/.obsidian/plugins/obsidian-tasks-plugin/manifest.json b/.obsidian/plugins/obsidian-tasks-plugin/manifest.json index ef810d09..b7f9472e 100644 --- a/.obsidian/plugins/obsidian-tasks-plugin/manifest.json +++ b/.obsidian/plugins/obsidian-tasks-plugin/manifest.json @@ -1,7 +1,7 @@ { "id": "obsidian-tasks-plugin", "name": "Tasks", - "version": "1.13.0", + "version": "1.13.1", "minAppVersion": "0.14.6", "description": "Task management for Obsidian", "author": "Martin Schenck and Clare Macrae", diff --git a/.obsidian/plugins/obsidian-tasks-plugin/styles.css b/.obsidian/plugins/obsidian-tasks-plugin/styles.css index d0876bac..7ca54271 100644 --- a/.obsidian/plugins/obsidian-tasks-plugin/styles.css +++ b/.obsidian/plugins/obsidian-tasks-plugin/styles.css @@ -8,6 +8,7 @@ background-color: var(--text-faint); mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20aria-hidden%3D%22true%22%20focusable%3D%22false%22%20width%3D%221em%22%20height%3D%221em%22%20style%3D%22-ms-transform%3A%20rotate(360deg)%3B%20-webkit-transform%3A%20rotate(360deg)%3B%20transform%3A%20rotate(360deg)%3B%22%20preserveAspectRatio%3D%22xMidYMid%20meet%22%20viewBox%3D%220%200%201536%201536%22%3E%3Cpath%20d%3D%22M363%201408l91-91l-235-235l-91%2091v107h128v128h107zm523-928q0-22-22-22q-10%200-17%207l-542%20542q-7%207-7%2017q0%2022%2022%2022q10%200%2017-7l542-542q7-7%207-17zm-54-192l416%20416l-832%20832H0v-416zm683%2096q0%2053-37%2090l-166%20166l-416-416l166-165q36-38%2090-38q53%200%2091%2038l235%20234q37%2039%2037%2091z%22%20fill%3D%22%23626262%22%2F%3E%3C%2Fsvg%3E"); -webkit-mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20aria-hidden%3D%22true%22%20focusable%3D%22false%22%20width%3D%221em%22%20height%3D%221em%22%20style%3D%22-ms-transform%3A%20rotate(360deg)%3B%20-webkit-transform%3A%20rotate(360deg)%3B%20transform%3A%20rotate(360deg)%3B%22%20preserveAspectRatio%3D%22xMidYMid%20meet%22%20viewBox%3D%220%200%201536%201536%22%3E%3Cpath%20d%3D%22M363%201408l91-91l-235-235l-91%2091v107h128v128h107zm523-928q0-22-22-22q-10%200-17%207l-542%20542q-7%207-7%2017q0%2022%2022%2022q10%200%2017-7l542-542q7-7%207-17zm-54-192l416%20416l-832%20832H0v-416zm683%2096q0%2053-37%2090l-166%20166l-416-416l166-165q36-38%2090-38q53%200%2091%2038l235%20234q37%2039%2037%2091z%22%20fill%3D%22%23626262%22%2F%3E%3C%2Fsvg%3E"); + -webkit-mask-size: contain; display: inline-block; width: 1em; height: 1em; diff --git a/.obsidian/plugins/obsidian42-brat/data.json b/.obsidian/plugins/obsidian42-brat/data.json index ea6f2053..40185765 100644 --- a/.obsidian/plugins/obsidian42-brat/data.json +++ b/.obsidian/plugins/obsidian42-brat/data.json @@ -1,5 +1,6 @@ { "pluginList": [ + "GamerGirlandCo/obsidian-task-completer/", "joethei/obsidian-tagcloud", "Quorafind/Obsidian-Memos", "qawatake/obsidian-core-search-assistant-plugin", @@ -16,6 +17,7 @@ "kinabalu/obsidian-crypto-lookup", "joethei/obsidian-rss" ], + "pluginSubListFrozenVersion": [], "themesList": [], "updateAtStartup": false, "updateThemesAtStartup": false, @@ -23,5 +25,6 @@ "loggingEnabled": false, "loggingPath": "BRAT-log", "loggingVerboseEnabled": false, - "debuggingMode": true + "debuggingMode": true, + "notificationsEnabled": true } \ No newline at end of file diff --git a/.obsidian/plugins/podnotes/data.json b/.obsidian/plugins/podnotes/data.json index 47cf6eb5..f3112da8 100644 --- a/.obsidian/plugins/podnotes/data.json +++ b/.obsidian/plugins/podnotes/data.json @@ -120,9 +120,9 @@ "1989: sex, lies and videotape: Rob Lowe and James Spader (Erotic 80s Part 12)": { "title": "1989: sex, lies and videotape: Rob Lowe and James Spader (Erotic 80s Part 12)", "podcastName": "You Must Remember This", - "time": 0, - "duration": 0, - "finished": true + "time": 1.626825467999832, + "duration": 6255.8302040816325, + "finished": false }, "Is a Local Prosecutor Making the Strongest Case Against Trump?": { "title": "Is a Local Prosecutor Making the Strongest Case Against Trump?", @@ -130,6 +130,20 @@ "time": 1803.576, "duration": 1803.576, "finished": true + }, + "How Gorbachev Changed the World": { + "title": "How Gorbachev Changed the World", + "podcastName": "The Daily", + "time": 2577.552283083334, + "duration": 2577.552, + "finished": false + }, + "Vancouver’s Unconventional Approach to Its Fentanyl Crisis": { + "title": "Vancouver’s Unconventional Approach to Its Fentanyl Crisis", + "podcastName": "The Daily", + "time": 2030.4369913, + "duration": 2071.2, + "finished": false } }, "favorites": { @@ -145,6 +159,26 @@ "shouldEpisodeRemoveAfterPlay": true, "shouldRepeat": false, "episodes": [ + { + "title": "Vancouver’s Unconventional Approach to Its Fentanyl Crisis", + "streamUrl": "https://dts.podtrac.com/redirect.mp3/chrt.fm/track/8DB4DB/pdst.fm/e/nyt.simplecastaudio.com/03d8b493-87fc-4bd1-931f-8a8e9b945d8a/episodes/e741398a-8cb3-4f9e-921f-aadda6b25651/audio/128/default.mp3?aid=rss_feed&awCollectionId=03d8b493-87fc-4bd1-931f-8a8e9b945d8a&awEpisodeId=e741398a-8cb3-4f9e-921f-aadda6b25651&feed=54nAGcIl", + "url": "https://www.nytimes.com/the-daily", + "description": "

 An influx of Fentanyl, a highly lethal synthetic narcotic, has aggravated the opioid crisis in the United States and prompted communities to scramble for ways to lower the skyrocketing rates of overdose deaths.

In Vancouver, a Canadian city that has been at the forefront of innovative approaches to drug use, a novel and surprising tactic is being tried: It’s called “safer supply.”

Background reading: 

For more information on today’s episode, visit nytimes.com/thedaily. Transcripts of each episode will be made available by the next workday. 

\n", + "podcastName": "The Daily", + "artworkUrl": "https://is1-ssl.mzstatic.com/image/thumb/Podcasts115/v4/1c/ac/04/1cac0421-4483-ff09-4f80-19710d9feda4/mza_12421371692158516891.jpeg/100x100bb.jpg", + "episodeDate": "2022-09-02T09:50:00.000Z", + "feedUrl": "https://feeds.simplecast.com/54nAGcIl" + }, + { + "title": "1989: sex, lies and videotape: Rob Lowe and James Spader (Erotic 80s Part 12)", + "streamUrl": "https://chtbl.com/track/42D75/traffic.megaphone.fm/CAD5168357655.mp3?updated=1655755288", + "url": "https://feeds.megaphone.fm/YMRT7068253588", + "description": "American independent film is launched into the mainstream by Steven Soderbergh’s sex, lies and videotape, starring James Spader as an impotent man who gets off on filming women talking about sex. Videotape also plays a role in a Spader film released almost simultaneously, Bad Influence, in which he plays a meek yuppie at the mercy of alpha male Rob Lowe – who was trying to rehabilitate his career after a tape leaked shot by the actor and documenting his real-life threesomes — one with a 16 year-old girl. We close the first half of this season talking about Lowe, Spader and how camcorder mediation of sex changed pop culture forever.\nLearn more about your ad choices. Visit podcastchoices.com/adchoices", + "podcastName": "You Must Remember This", + "artworkUrl": "https://is5-ssl.mzstatic.com/image/thumb/Podcasts126/v4/75/40/a3/7540a383-f8d5-9ee0-90aa-79f64991324a/mza_2028421411620603108.jpg/100x100bb.jpg", + "episodeDate": "2022-06-21T04:00:00.000Z", + "feedUrl": "https://feeds.megaphone.fm/YMRT7068253588" + }, { "title": "242: I Had A Mean Streak", "streamUrl": "https://dts.podtrac.com/redirect.mp3/media.blubrry.com/mortified/dovetail.prxu.org/_/36/980a102a-a02a-4192-839e-d181e7b8c39c/Mean_Streak_Final_pt_1.mp3", @@ -189,14 +223,14 @@ "skipBackwardLength": 15, "skipForwardLength": 15, "currentEpisode": { - "title": "1989: sex, lies and videotape: Rob Lowe and James Spader (Erotic 80s Part 12)", - "streamUrl": "https://chtbl.com/track/42D75/traffic.megaphone.fm/CAD5168357655.mp3?updated=1655755288", - "url": "https://feeds.megaphone.fm/YMRT7068253588", - "description": "American independent film is launched into the mainstream by Steven Soderbergh’s sex, lies and videotape, starring James Spader as an impotent man who gets off on filming women talking about sex. Videotape also plays a role in a Spader film released almost simultaneously, Bad Influence, in which he plays a meek yuppie at the mercy of alpha male Rob Lowe – who was trying to rehabilitate his career after a tape leaked shot by the actor and documenting his real-life threesomes — one with a 16 year-old girl. We close the first half of this season talking about Lowe, Spader and how camcorder mediation of sex changed pop culture forever.\nLearn more about your ad choices. Visit podcastchoices.com/adchoices", - "podcastName": "You Must Remember This", - "artworkUrl": "https://is5-ssl.mzstatic.com/image/thumb/Podcasts126/v4/75/40/a3/7540a383-f8d5-9ee0-90aa-79f64991324a/mza_2028421411620603108.jpg/100x100bb.jpg", - "episodeDate": "2022-06-21T04:00:00.000Z", - "feedUrl": "https://feeds.megaphone.fm/YMRT7068253588" + "title": "How Gorbachev Changed the World", + "streamUrl": "https://dts.podtrac.com/redirect.mp3/chrt.fm/track/8DB4DB/pdst.fm/e/nyt.simplecastaudio.com/03d8b493-87fc-4bd1-931f-8a8e9b945d8a/episodes/6b905da7-6963-412d-ad83-e89ca2c124ec/audio/128/default.mp3?aid=rss_feed&awCollectionId=03d8b493-87fc-4bd1-931f-8a8e9b945d8a&awEpisodeId=6b905da7-6963-412d-ad83-e89ca2c124ec&feed=54nAGcIl", + "url": "https://www.nytimes.com/the-daily", + "description": "

Few leaders have had as profound an effect on their time as Mikhail S. Gorbachev, the last leader of the Soviet Union, who died this week at 91.

It was not Mr. Gorbachev’s intention to liquidate the Soviet empire when he came to power in 1985. But after little more than six tumultuous years, he had lifted the Iron Curtain and presided over the dissolution of the Union of Soviet Socialist Republics, ending the Cold War.

Guest: Serge Schmemann, a member of The New York Times’s editorial board.

Background reading: 

For more information on today’s episode, visit nytimes.com/thedaily. Transcripts of each episode will be made available by the next workday. 

\n", + "podcastName": "The Daily", + "artworkUrl": "https://is1-ssl.mzstatic.com/image/thumb/Podcasts115/v4/1c/ac/04/1cac0421-4483-ff09-4f80-19710d9feda4/mza_12421371692158516891.jpeg/100x100bb.jpg", + "episodeDate": "2022-09-01T09:55:00.000Z", + "feedUrl": "https://feeds.simplecast.com/54nAGcIl" }, "timestamp": { "template": "- {{linktime}} " diff --git a/.obsidian/plugins/templater-obsidian/data.json b/.obsidian/plugins/templater-obsidian/data.json index eacd769d..ae929a5b 100644 --- a/.obsidian/plugins/templater-obsidian/data.json +++ b/.obsidian/plugins/templater-obsidian/data.json @@ -16,7 +16,7 @@ "enable_system_commands": true, "shell_path": "", "user_scripts_folder": "00.01 Admin/Templater scripts", - "enable_folder_templates": true, + "enable_folder_templates": false, "folder_templates": [ { "folder": "", @@ -28,5 +28,6 @@ "" ], "startup_templates": [], + "enable_ribbon_icon": true, "template_folder": "Admin/Templates" } \ No newline at end of file diff --git a/.obsidian/workspace b/.obsidian/workspace index 28891e46..67302cba 100644 --- a/.obsidian/workspace +++ b/.obsidian/workspace @@ -4,15 +4,11 @@ "type": "split", "children": [ { - "id": "27892978a20f1007", + "id": "daf949238c6a8d13", "type": "leaf", "state": { - "type": "markdown", - "state": { - "file": "01.02 Home/@Main Dashboard.md", - "mode": "preview", - "source": false - } + "type": "empty", + "state": {} } } ], @@ -77,7 +73,6 @@ "state": { "type": "backlink", "state": { - "file": "01.02 Home/@Main Dashboard.md", "collapseAll": false, "extraContext": false, "sortOrder": "alphabetical", @@ -94,7 +89,6 @@ "state": { "type": "outgoing-link", "state": { - "file": "01.02 Home/@Main Dashboard.md", "linksCollapsed": false, "unlinkedCollapsed": false } @@ -159,17 +153,17 @@ ], "currentTab": 2 }, - "active": "27892978a20f1007", + "active": "daf949238c6a8d13", "lastOpenFiles": [ - "05.02 Networks/Server Cloud.md", + "Ytes.md", + "archive.md", + "05.02 Networks/VPS Console Dialogue.md", "01.02 Home/@Main Dashboard.md", + "00.01 Admin/Calendars/2022-09-05.md", + "00.01 Admin/Calendars/2022-09-06.md", "01.02 Home/Cinematheque.md", - "00.01 Admin/Calendars/2022-09-04.md", - "02.03 Zürich/@Restaurants Zürich.md", - "02.03 Zürich/Kiosk.md", - "02.03 Zürich/@Café Zürich.md", - "01.02 Home/League Tables.md", - "00.01 Admin/Templates/Template Person.md", - "02.02 Paris/Paris SG.md" + "01.02 Home/@Shopping list.md", + "03.04 Cinematheque/The Lord of the Rings - The Two Towers (2002).md", + "03.04 Cinematheque/The Lord of the Rings - The Return of the King (2003).md" ] } \ No newline at end of file diff --git a/00.01 Admin/Calendars/2022-09-04.md b/00.01 Admin/Calendars/2022-09-04.md index 7223a8fc..06091b8c 100644 --- a/00.01 Admin/Calendars/2022-09-04.md +++ b/00.01 Admin/Calendars/2022-09-04.md @@ -13,9 +13,9 @@ Stress: 25 FrontHeadBar: 5 EarHeadBar: 30 BackHeadBar: 20 -Water: 0.125 -Coffee: 3 -Steps: +Water: 5.125 +Coffee: 4 +Steps: 7523 Ski: Riding: 1 Racket: diff --git a/00.01 Admin/Calendars/2022-09-05.md b/00.01 Admin/Calendars/2022-09-05.md new file mode 100644 index 00000000..7752ee83 --- /dev/null +++ b/00.01 Admin/Calendars/2022-09-05.md @@ -0,0 +1,112 @@ +--- + +Date: 2022-09-05 +DocType: Note +Hierarchy: +TimeStamp: +location: +CollapseMetaTable: Yes +Sleep: 7.5 +Happiness: 90 +Gratefulness: 90 +Stress: 25 +FrontHeadBar: 5 +EarHeadBar: 30 +BackHeadBar: 20 +Water: 3.625 +Coffee: 4 +Steps: 13417 +Ski: +Riding: +Racket: +Football: +Swim: + +--- + +%% Parent:: [[@Life Admin]] %% + +--- + +[[2022-09-04|<< 🗓 Previous ]]       [[@Main Dashboard|Back]]       [[2022-09-06|🗓 Next >>]] + +--- + +  + +```button +name Record today's health +type command +action MetaEdit: Run MetaEdit +id EditMetaData +``` +^button-2022-09-05Edit + +```button +name Save +type command +action Save current file +id Save +``` +^button-2022-09-05NSave + +  + +# 2022-09-05 + +  + +> [!summary]+ +> Daily note for 2022-09-05 + +  + +```toc +style: number +``` + +  + +--- + +  + +### 📝 Memos + +  + +This section does serve for quick memos. + +  +- [ ] 17:44 :camera_flash: [[2022-09-05|Memo]], [[@Computer Set Up|Tech stack]]: find a solution to sync pictures from iphone to external hard drive 📆2022-09-09 + + +%% --- %% +  + +--- + +  + +### 🗒 Notes + +  + +Loret ipsum + +  + +--- + +  + +### :link: Linked activity + +  + +```dataview +Table from [[2022-09-05]] +``` + +  +  \ No newline at end of file diff --git a/00.01 Admin/Calendars/2022-09-06.md b/00.01 Admin/Calendars/2022-09-06.md new file mode 100644 index 00000000..70d2c8ab --- /dev/null +++ b/00.01 Admin/Calendars/2022-09-06.md @@ -0,0 +1,111 @@ +--- + +Date: 2022-09-06 +DocType: Note +Hierarchy: +TimeStamp: +location: +CollapseMetaTable: Yes +Sleep: 7 +Happiness: 90 +Gratefulness: 90 +Stress: 25 +FrontHeadBar: 5 +EarHeadBar: 30 +BackHeadBar: 20 +Water: +Coffee: +Steps: +Ski: +Riding: +Racket: +Football: +Swim: + +--- + +%% Parent:: [[@Life Admin]] %% + +--- + +[[2022-09-05|<< 🗓 Previous ]]       [[@Main Dashboard|Back]]       [[2022-09-07|🗓 Next >>]] + +--- + +  + +```button +name Record today's health +type command +action MetaEdit: Run MetaEdit +id EditMetaData +``` +^button-2022-09-06Edit + +```button +name Save +type command +action Save current file +id Save +``` +^button-2022-09-06NSave + +  + +# 2022-09-06 + +  + +> [!summary]+ +> Daily note for 2022-09-06 + +  + +```toc +style: number +``` + +  + +--- + +  + +### 📝 Memos + +  + +This section does serve for quick memos. + +  + + +%% --- %% +  + +--- + +  + +### 🗒 Notes + +  + +Loret ipsum + +  + +--- + +  + +### :link: Linked activity + +  + +```dataview +Table from [[2022-09-06]] +``` + +  +  \ No newline at end of file diff --git a/00.01 Admin/Test sheet.md b/00.01 Admin/Test sheet.md index 5a0d9462..ff07281d 100644 --- a/00.01 Admin/Test sheet.md +++ b/00.01 Admin/Test sheet.md @@ -274,99 +274,19 @@ players: Donnarumma,Bernat,Marquinhos,Kimpembe,Hakimi,Villeneuve,Verratti,St Hil - [ ] Habit_3 - [ ] Habit_4 -```dataviewjs -const habits = [] // Array of objects for each page's tasks. - -const defaultHeaders = ['Day'] - -const headers = new Set(defaultHeaders) // Set of task names to be used as table headers. - -const rows = [] - -const noteDay = dv.current().file.day - -if (!noteDay) - -throw { - -stack: - -'(If this note is your template, this error is expected.) Unable to get note\'s day. Note should be named in the "YYYY-MM-DD" format.', - -} - -const pages = dv - -.pages('"00.01 Admin/Calendars"') +- [ ] this is seq task 1 +^seqtask1 -.where((p) => p.file.day >= noteDay.minus({ days: 7 })) // Only include previous week in table. +- [ ] this is seq task 2 [[Test sheet#^seqtask1|🔗]] +^seqtask2 -.where((p) => p.file.day <= noteDay) // Don't include future notes. +- [ ] this is seq task 3 [[Test sheet#^seqtask2|🔗]] -.sort((p) => p.file.day, 'desc') // Sort table by most recent day. -for (const page of pages) { - -// Only include tasks under a header named "Habits". - -const pageHabits = page.file.tasks.filter((t) => t.header.subpath == 'Habits') - -const noteLink = page.file.link - -noteLink.display = page.file.day.weekdayLong // Set display name of the note link to the day of the week. - -const habitsObject = { noteLink } - -for (const habit of pageHabits) { - -let habitText = habit.text.split(' ✅')[0] // Remove completion text from Tasks plugin. - -// Remove tag text. - -for (const tag of habit.tags) { - -habitText = habitText.replace(tag, '') - -} - -habitText = habitText.trim() - -habitsObject[habitText] = habit.completed // Build habitsObject. Key is the task's text. Value is tasks's completion. - -headers.add(habitText) // Build headers set where each header is the task's text. - -} - -habits.push(habitsObject) - -} - -for (const habitsObject of habits) { - -const row = [habitsObject.noteLink] // Start building row data. Fill in first value (Day) with note link. - -for (const header of headers) { - -if (defaultHeaders.includes(header)) continue // Don't overwrite default headers. - -let habitStatus = '➖' // This emoji is seen if a corresponding task doesn't exist for a header (e.g. task didn't previously exist). - -if (habitsObject.hasOwnProperty(header)) - -// If task exists, we know it must be complete or incomplete. - -habitStatus = habitsObject[header] ? '✔' : '❌' - -row.push(habitStatus) - -} - -rows.push(row) - -} - -dv.table(headers, rows) -``` +- [x] tast test ✅ 2022-09-04 + - [ ] sub-task test + - [ ] Sub-task test 2 + - [ ] sub-task test 3 --- diff --git a/00.03 News/Was Vincent van Gogh Color Blind It Sure Looks Like It.md b/00.03 News/Was Vincent van Gogh Color Blind It Sure Looks Like It.md new file mode 100644 index 00000000..8a128339 --- /dev/null +++ b/00.03 News/Was Vincent van Gogh Color Blind It Sure Looks Like It.md @@ -0,0 +1,71 @@ +--- + +Tag: ["Art", "Painter", "VanGogh"] +Date: 2022-09-04 +DocType: "WebClipping" +Hierarchy: +TimeStamp: 2022-09-04 +Link: https://www.smithsonianmag.com/smart-news/was-vincent-van-gogh-color-blind-it-sure-looks-like-it-27576085/ +location: +CollapseMetaTable: Yes + +--- + +Parent:: [[@News|News]] +Read:: No + +--- + +  + +```button +name Save +type command +action Save current file +id Save +``` +^button-WasVincentvanGoghColorBlindItSureLooksLikeItNSave + +  + +# Was Vincent van Gogh Color Blind? It Sure Looks Like It + +[![](http://blogs.smithsonianmag.com/smartnews/files/2012/08/08_20_2012_color-vision-van-gogh.jpg "Van Gogh color blind")](http://blogs.smithsonianmag.com/smartnews/files/2012/08/08_20_2012_color-vision-van-gogh.jpg) + +Vincent van Gogh’s The Starry Night (left) filtered to simulate color blindness (right). Photo: [Kazunori Asada](http://asada0.tumblr.com/post/11517603099/the-day-i-saw-van-goghs-genius-in-a-new-light) + +Around [a tenth of all men are color blind or color deficient](http://www.ncbi.nlm.nih.gov/pubmedhealth/PMH0001997/), and as [Joe Hanson](https://twitter.com/jtotheizzoe) discusses on [*It’s Okay to Be Smart*](http://www.itsokaytobesmart.com/post/29661055021/van-gogh-colorblind), famed painter Vincent van Gogh may have been counted among them. + +Hanson references the work of [Kazunori Asada](http://asada.tukusi.ne.jp/), a researcher and designer who is concerned with color vision. Asada had [seen some of van Gogh’s work in what he calls a color vision experience room](http://asada0.tumblr.com/post/11517603099/the-day-i-saw-van-goghs-genius-in-a-new-light) – one where the lighting conditions are meant to simulate color blindness. + +> Under the filtered light, I found that these paintings looked different from the van Gogh which I had always seen. I love van Gogh’s paintings and have been fortunate to view a number of the originals in various art museums. This painter has a somewhat strange way to use color. Although the use of color is rich, lines of different colors run concurrently, or a point of different color suddenly appears. I’ve heard it conjectured that van Gogh had color vision deficiency. +> +> However, in the van Gogh images seen in the color vision experience room, to me the incongruity of color and roughness of line had quietly disappeared. And each picture had changed into one of brilliance with very delicate lines and shades. This was truly wonderful experience. + +To recreate his experience, Asada modified a [color-deficiency simulator](http://asada.tukusi.ne.jp/cvsconv/) he had previously designed to better mimic more subtle variations of color blindness. He has [a number of striking examples of the master painter’s works reimagined](http://asada0.tumblr.com/). The simulator is freely available, and allows you to simulate the experiences of the one-in-ten men (and fewer women) you may know with some form of color vision deficiency. + +Here, [Hanson filtered](http://www.itsokaytobesmart.com/post/29661606872/michele-banks-colorblind) the watercolor art of [Michele Banks](https://twitter.com/artologica) through [Asada’s tool](http://asada.tukusi.ne.jp/cvsconv/) to show normal vision, red-green color blindness (known as protanopia, top right), blue-yellow color blindness (tritanopia, bottom right), and red-green-yollow color blindness (deuteranopia, bottom left.) + +[![](http://blogs.smithsonianmag.com/smartnews/files/2012/08/08_20_2012_color-vision-banks.jpg "Color vision michelle banks")](http://blogs.smithsonianmag.com/smartnews/files/2012/08/08_20_2012_color-vision-banks.jpg) + +Cell division watercolor, filtered through Asada’s color-deficiency simulator. Painting: [Michele Banks](http://www.etsy.com/listing/106614640/cell-division-25-original-watercolor), Photo: [Joe Hanson](http://www.itsokaytobesmart.com/post/29661606872/michele-banks-colorblind) + +When turned on the natural world, the varying forms of color deficiency produce striking results. + +[![](http://blogs.smithsonianmag.com/smartnews/files/2012/08/08_20_2012_color-vision-budgie.jpg "Color deficiency budgie")](http://blogs.smithsonianmag.com/smartnews/files/2012/08/08_20_2012_color-vision-budgie.jpg) + +Clockwise from top left: normal vision, protonopia, tritanopia, and deuteranopia. Photo: Colin Schultz + +More from Smithsonian.com: + +[Letters from Vincent](http://www.smithsonianmag.com/arts-culture/vincent-200801.html)  + +[Arts](https://www.smithsonianmag.com/tag/arts/) [Cool Finds](https://www.smithsonianmag.com/tag/cool-finds/) [Fine Arts](https://www.smithsonianmag.com/tag/fine-arts/) [Photography](https://www.smithsonianmag.com/tag/photography/) + +Recommended Videos + +  +  + +--- +`$= dv.el('center', 'Source: ' + dv.current().Link + ', ' + dv.current().Date.toLocaleString("fr-FR"))` \ No newline at end of file diff --git a/01.02 Home/@Shopping list.md b/01.02 Home/@Shopping list.md index 94c38f08..4de2d027 100644 --- a/01.02 Home/@Shopping list.md +++ b/01.02 Home/@Shopping list.md @@ -63,16 +63,16 @@ style: number - [x] 🥯 Bread ✅ 2022-08-05 - [x] 🍯 Honey/Jam ✅ 2022-03-31 - [x] 🍫 Nutella ✅ 2022-02-15 -- [x] 🍐 Fruit ✅ 2022-08-05 -- [x] 🍌 Bananas ✅ 2022-03-31 -- [x] 🍅 vegetables ✅ 2022-08-05 +- [x] 🍐 Fruit ✅ 2022-09-05 +- [x] 🍌 Bananas ✅ 2022-09-05 +- [x] 🍅 vegetables ✅ 2022-09-05 - [x] 🧅 onions ✅ 2022-03-31 - [x] 🧄 garlic ✅ 2022-03-01 - [x] 🥚 Eggs ✅ 2022-07-30 - [x] 🧀 Fromage ✅ 2022-07-30 - [x] 🧀 Fromage rapé ✅ 2022-08-05 - [x] 🥩 Cured meat ✅ 2022-08-05 -- [x] 🍖 Fresh meat ✅ 2022-08-05 +- [x] 🍖 Fresh meat ✅ 2022-09-05 - [x] 🍝 Pasta ✅ 2022-08-05 - [x] 🍚 Rice ✅ 2022-03-31 - [x] 🥔 Potatoes ✅ 2022-08-05 @@ -86,7 +86,7 @@ style: number - [x] 🫒 Olive oil ✅ 2022-07-30 - [x] 🌭 Mustard ✅ 2022-02-07 - [x] 🥫 Sauces (Ketchup, bbq, etc..) ✅ 2022-03-14 -- [x] 🌶️ Tabasco ✅ 2022-03-14 +- [x] 🌶️ Tabasco ✅ 2022-09-05 - [x] 🌶️ Ketjap Manis ✅ 2022-03-14 - [x] 🌶️ Cayenne Pepper ✅ 2022-03-14 - [x] 🥢 Soy sauce ✅ 2022-03-14 diff --git a/01.02 Home/Cinematheque.md b/01.02 Home/Cinematheque.md index 82bc20a7..23ded761 100644 --- a/01.02 Home/Cinematheque.md +++ b/01.02 Home/Cinematheque.md @@ -12,7 +12,7 @@ CollapseMetaTable: Yes TVShow: Name: "Game of Thrones" Season: 3 - Episode: 3 + Episode: 6 Source: Internal --- diff --git a/01.02 Home/Household.md b/01.02 Home/Household.md index 605b459b..d78707fe 100644 --- a/01.02 Home/Household.md +++ b/01.02 Home/Household.md @@ -75,7 +75,8 @@ This section on different household obligations. - [ ] ♻ [[Household]]: *Paper* recycling collection %%done_del%% 🔁 every 2 weeks on Tuesday 📅 2022-09-13 - [x] ♻ [[Household]]: *Paper* recycling collection %%done_del%% 🔁 every 2 weeks on Tuesday 📅 2022-08-30 ✅ 2022-08-29 -- [ ] ♻ [[Household]]: *Cardboard* recycling collection %%done_del%% 🔁 every 2 weeks on Tuesday 📅 2022-09-06 +- [ ] ♻ [[Household]]: *Cardboard* recycling collection %%done_del%% 🔁 every 2 weeks on Tuesday 📅 2022-09-20 +- [x] ♻ [[Household]]: *Cardboard* recycling collection %%done_del%% 🔁 every 2 weeks on Tuesday 📅 2022-09-06 ✅ 2022-09-05   diff --git a/01.03 Family/Ophélie Bédier.md b/01.03 Family/Ophélie Bédier.md index d926ee3e..84cc838c 100644 --- a/01.03 Family/Ophélie Bédier.md +++ b/01.03 Family/Ophélie Bédier.md @@ -98,7 +98,8 @@ style: number   -- [ ] :birthday: **[[Ophélie Bédier|Ophélie]]** %%done_del%% 🔁 every year 📅 2022-09-05 +- [ ] :birthday: **[[Ophélie Bédier|Ophélie]]** %%done_del%% 🔁 every year 📅 2023-09-05 +- [x] :birthday: **[[Ophélie Bédier|Ophélie]]** %%done_del%% 🔁 every year 📅 2022-09-05 ✅ 2022-09-05     \ No newline at end of file diff --git a/03.03 Food & Wine/@@Recipes.md b/03.03 Food & Wine/@@Recipes.md index 5b325df7..f771d919 100644 --- a/03.03 Food & Wine/@@Recipes.md +++ b/03.03 Food & Wine/@@Recipes.md @@ -3,10 +3,10 @@ QueryCourse: "" QueryCategory: "" QueryCuisine: "" -QueryIngredient: "" -QueryTheme: Healthy +QueryIngredient: Celery +QueryTheme: QueryFavourite: -QueryRating: ">3" +QueryRating: "" QueryCookingTime: "" cssclass: cards Alias: ["Recipes"] diff --git a/03.03 Food & Wine/Hoppin' John.md b/03.03 Food & Wine/Hoppin' John.md index 94ab48c3..c8f4bfbe 100644 --- a/03.03 Food & Wine/Hoppin' John.md +++ b/03.03 Food & Wine/Hoppin' John.md @@ -10,7 +10,7 @@ location: CollapseMetaTable: Yes Meta: IsFavourite: False - Rating: + Rating: 3 Recipe: Courses: "Main dish" Categories: Stew diff --git a/03.03 Food & Wine/Lamb Siniyah.md b/03.03 Food & Wine/Lamb Siniyah.md index f90e3109..a36b8585 100644 --- a/03.03 Food & Wine/Lamb Siniyah.md +++ b/03.03 Food & Wine/Lamb Siniyah.md @@ -1,6 +1,6 @@ --- -ServingSize: 4 +ServingSize: 2 cssclass: recipeTable Tag: ["Hearty", "NYE", "NotYetTested"] Date: 2021-09-21 diff --git a/03.04 Cinematheque/Men in Black (1997).md b/03.04 Cinematheque/Men in Black (1997).md new file mode 100644 index 00000000..d194cc57 --- /dev/null +++ b/03.04 Cinematheque/Men in Black (1997).md @@ -0,0 +1,94 @@ +--- + +type: "movie" +title: "Men in Black" +englishTitle: "Men in Black" +year: "1997" +dataSource: "OMDbAPI" +url: "https://www.imdb.com/title/tt0119654/" +id: "tt0119654" +genres: + - "Action" + - "Adventure" + - "Comedy" +producer: "Barry Sonnenfeld" +duration: "98 min" +onlineRating: 7.3 +image: "https://m.media-amazon.com/images/M/MV5BOTlhYTVkMDktYzIyNC00NzlkLTlmN2ItOGEyMWQ4OTA2NDdmXkEyXkFqcGdeQXVyNTAyODkwOQ@@._V1_SX300.jpg" +released: true +premiere: "02/07/1997" +watched: true +lastWatched: "2022/04/01" +personalRating: 7 +tags: "#mediaDB/tv/movie" +CollapseMetaTable: yes + +--- + +Parent:: [[Cinematheque]] + +--- + +```dataviewjs +dv.paragraph(`> [!${dv.current().watched ? 'SUCCESS' : 'WARNING'}] ${dv.current().watched ? 'last watched on ' + dv.current().lastWatched : 'not yet watched'}`) +``` + +  + +# `$= dv.current().title` + +  + +`$= dv.current().watched ? '**Rating**: ' + dv.current().personalRating + ' out of 10' : ''` + +```toc +``` + +  + +### Details + +  + +**Genres**: +`$= dv.current().genres.length === 0 ? ' - none' : dv.list(dv.current().genres)` +`$= !dv.current().released ? '**Not released** The movie is not yet released.' : ''` + +  + +```dataview +list without id + "" + + + "" ++ + "" + + + "" + + + "" + + + "" + + + "" + + + "" + + + "" + + + "
Type" + this.type + "
Online Rating" + this.onlineRating + "
Duration" + this.duration + "
Premiered" + this.premiere + "
Producer" + this.producer + "
" +FROM "03.04 Cinematheque/Men in Black (1997)" +``` + +  + + +--- + +  + +### Poster + +  + +`$= '![Image|360](' + dv.current().image + ')'` \ No newline at end of file diff --git a/03.04 Cinematheque/Men in Black 3 (2012).md b/03.04 Cinematheque/Men in Black 3 (2012).md new file mode 100644 index 00000000..9ea2eb0f --- /dev/null +++ b/03.04 Cinematheque/Men in Black 3 (2012).md @@ -0,0 +1,94 @@ +--- + +type: "movie" +title: "Men in Black 3" +englishTitle: "Men in Black 3" +year: "2012" +dataSource: "OMDbAPI" +url: "https://www.imdb.com/title/tt1409024/" +id: "tt1409024" +genres: + - "Action" + - "Adventure" + - "Comedy" +producer: "Barry Sonnenfeld" +duration: "106 min" +onlineRating: 6.8 +image: "https://m.media-amazon.com/images/M/MV5BMTU2NTYxODcwMF5BMl5BanBnXkFtZTcwNDk1NDY0Nw@@._V1_SX300.jpg" +released: true +premiere: "25/05/2012" +watched: true +lastWatched: "2022/04/03" +personalRating: 6 +tags: "#mediaDB/tv/movie" +CollapseMetaTable: yes + +--- + +Parent:: [[Cinematheque]] + +--- + +```dataviewjs +dv.paragraph(`> [!${dv.current().watched ? 'SUCCESS' : 'WARNING'}] ${dv.current().watched ? 'last watched on ' + dv.current().lastWatched : 'not yet watched'}`) +``` + +  + +# `$= dv.current().title` + +  + +`$= dv.current().watched ? '**Rating**: ' + dv.current().personalRating + ' out of 10' : ''` + +```toc +``` + +  + +### Details + +  + +**Genres**: +`$= dv.current().genres.length === 0 ? ' - none' : dv.list(dv.current().genres)` + +`$= !dv.current().released ? '**Not released** The movie is not yet released.' : ''` + +  + +```dataview +list without id + "" + + + "" ++ + "" + + + "" + + + "" + + + "" + + + "" + + + "" + + + "" + + + "
Type" + this.type + "
Online Rating" + this.onlineRating + "
Duration" + this.duration + "
Premiered" + this.premiere + "
Producer" + this.producer + "
" +FROM "03.04 Cinematheque/Men in Black 3 (2012)" +``` + +  + +--- + +  + +### Poster + +  + +`$= '![Image|360](' + dv.current().image + ')'` \ No newline at end of file diff --git a/03.04 Cinematheque/Men in Black II (2002).md b/03.04 Cinematheque/Men in Black II (2002).md new file mode 100644 index 00000000..9a57ed73 --- /dev/null +++ b/03.04 Cinematheque/Men in Black II (2002).md @@ -0,0 +1,93 @@ +--- + +type: "movie" +title: "Men in Black II" +englishTitle: "Men in Black II" +year: "2002" +dataSource: "OMDbAPI" +url: "https://www.imdb.com/title/tt0120912/" +id: "tt0120912" +genres: + - "Action" + - "Adventure" + - "Comedy" +producer: "Barry Sonnenfeld" +duration: "88 min" +onlineRating: 6.1 +image: "https://m.media-amazon.com/images/M/MV5BMTMxNDA0NTMxMV5BMl5BanBnXkFtZTYwMDE2NzY2._V1_SX300.jpg" +released: true +premiere: "03/07/2002" +watched: true +lastWatched: "2022/04/02" +personalRating: 6 +tags: "#mediaDB/tv/movie" +CollapseMetaTable: yes +--- + +Parent:: [[Cinematheque]] + +--- + +```dataviewjs +dv.paragraph(`> [!${dv.current().watched ? 'SUCCESS' : 'WARNING'}] ${dv.current().watched ? 'last watched on ' + dv.current().lastWatched : 'not yet watched'}`) +``` + +  + +# `$= dv.current().title` + +  + +`$= dv.current().watched ? '**Rating**: ' + dv.current().personalRating + ' out of 10' : ''` + +```toc +``` + +  + +### Details + +  + +**Genres**: +`$= dv.current().genres.length === 0 ? ' - none' : dv.list(dv.current().genres)` + +`$= !dv.current().released ? '**Not released** The movie is not yet released.' : ''` + +  + +```dataview +list without id + "" + + + "" ++ + "" + + + "" + + + "" + + + "" + + + "" + + + "" + + + "" + + + "
Type" + this.type + "
Online Rating" + this.onlineRating + "
Duration" + this.duration + "
Premiered" + this.premiere + "
Producer" + this.producer + "
" +FROM "03.04 Cinematheque/Men in Black II (2002)" +``` + +  + +--- + +  + +### Poster + +  + +`$= '![Image|360](' + dv.current().image + ')'` \ No newline at end of file diff --git a/03.04 Cinematheque/The Lord of the Rings - The Fellowship of the Ring (2001).md b/03.04 Cinematheque/The Lord of the Rings - The Fellowship of the Ring (2001).md new file mode 100644 index 00000000..8c7bbe11 --- /dev/null +++ b/03.04 Cinematheque/The Lord of the Rings - The Fellowship of the Ring (2001).md @@ -0,0 +1,93 @@ +--- +type: "movie" +title: "The Lord of the Rings: The Fellowship of the Ring" +englishTitle: "The Lord of the Rings: The Fellowship of the Ring" +year: "2001" +dataSource: "OMDbAPI" +url: "https://www.imdb.com/title/tt0120737/" +id: "tt0120737" +genres: + - "Action" + - "Adventure" + - "Drama" +producer: "Peter Jackson" +duration: "178 min" +onlineRating: 8.8 +image: "https://m.media-amazon.com/images/M/MV5BN2EyZjM3NzUtNWUzMi00MTgxLWI0NTctMzY4M2VlOTdjZWRiXkEyXkFqcGdeQXVyNDUzOTQ5MjY@._V1_SX300.jpg" +released: true +premiere: "19/12/2001" +watched: true +lastWatched: "2002" +personalRating: 7.5 +tags: "#mediaDB/tv/movie" +CollapseMetaTable: yes + +--- + +Parent:: [[Cinematheque]] + +--- + +```dataviewjs +dv.paragraph(`> [!${dv.current().watched ? 'SUCCESS' : 'WARNING'}] ${dv.current().watched ? 'last watched on ' + dv.current().lastWatched : 'not yet watched'}`) +``` + +  + +# `$= dv.current().title` + +  + +`$= dv.current().watched ? '**Rating**: ' + dv.current().personalRating + ' out of 10' : ''` + +```toc +``` + +  + +### Details + +  + +**Genres**: +`$= dv.current().genres.length === 0 ? ' - none' : dv.list(dv.current().genres)` + +`$= !dv.current().released ? '**Not released** The movie is not yet released.' : ''` + +  + +```dataview +list without id + "" + + + "" ++ + "" + + + "" + + + "" + + + "" + + + "" + + + "" + + + "" + + + "
Type" + this.type + "
Online Rating" + this.onlineRating + "
Duration" + this.duration + "
Premiered" + this.premiere + "
Producer" + this.producer + "
" +FROM "03.04 Cinematheque/The Lord of the Rings - The Fellowship of the Ring (2001)" +``` + +  + +--- + +  + +### Poster + +  + +`$= '![Image|360](' + dv.current().image + ')'` \ No newline at end of file diff --git a/03.04 Cinematheque/The Lord of the Rings - The Return of the King (2003).md b/03.04 Cinematheque/The Lord of the Rings - The Return of the King (2003).md new file mode 100644 index 00000000..cd5bd24b --- /dev/null +++ b/03.04 Cinematheque/The Lord of the Rings - The Return of the King (2003).md @@ -0,0 +1,93 @@ +--- +type: "movie" +title: "The Lord of the Rings: The Return of the King" +englishTitle: "The Lord of the Rings: The Return of the King" +year: "2003" +dataSource: "OMDbAPI" +url: "https://www.imdb.com/title/tt0167260/" +id: "tt0167260" +genres: + - "Action" + - "Adventure" + - "Drama" +producer: "Peter Jackson" +duration: "201 min" +onlineRating: 9 +image: "https://m.media-amazon.com/images/M/MV5BNzA5ZDNlZWMtM2NhNS00NDJjLTk4NDItYTRmY2EwMWZlMTY3XkEyXkFqcGdeQXVyNzkwMjQ5NzM@._V1_SX300.jpg" +released: true +premiere: "17/12/2003" +watched: true +lastWatched: "2004" +personalRating: 7.5 +tags: "#mediaDB/tv/movie" +CollapseMetaTable: yes + +--- + +Parent:: [[Cinematheque]] + +--- + +```dataviewjs +dv.paragraph(`> [!${dv.current().watched ? 'SUCCESS' : 'WARNING'}] ${dv.current().watched ? 'last watched on ' + dv.current().lastWatched : 'not yet watched'}`) +``` + +  + +# `$= dv.current().title` + +  + +`$= dv.current().watched ? '**Rating**: ' + dv.current().personalRating + ' out of 10' : ''` + +```toc +``` + +  + +### Details + +  + +**Genres**: +`$= dv.current().genres.length === 0 ? ' - none' : dv.list(dv.current().genres)` + +`$= !dv.current().released ? '**Not released** The movie is not yet released.' : ''` + +  + +```dataview +list without id + "" + + + "" ++ + "" + + + "" + + + "" + + + "" + + + "" + + + "" + + + "" + + + "
Type" + this.type + "
Online Rating" + this.onlineRating + "
Duration" + this.duration + "
Premiered" + this.premiere + "
Producer" + this.producer + "
" +FROM "03.04 Cinematheque/The Lord of the Rings - The Return of the King (2003)" +``` + +  + +--- + +  + +### Poster + +  + +`$= '![Image|360](' + dv.current().image + ')'` \ No newline at end of file diff --git a/03.04 Cinematheque/The Lord of the Rings - The Two Towers (2002).md b/03.04 Cinematheque/The Lord of the Rings - The Two Towers (2002).md new file mode 100644 index 00000000..27d39728 --- /dev/null +++ b/03.04 Cinematheque/The Lord of the Rings - The Two Towers (2002).md @@ -0,0 +1,93 @@ +--- +type: "movie" +title: "The Lord of the Rings: The Two Towers" +englishTitle: "The Lord of the Rings: The Two Towers" +year: "2002" +dataSource: "OMDbAPI" +url: "https://www.imdb.com/title/tt0167261/" +id: "tt0167261" +genres: + - "Action" + - "Adventure" + - "Drama" +producer: "Peter Jackson" +duration: "179 min" +onlineRating: 8.8 +image: "https://m.media-amazon.com/images/M/MV5BZGMxZTdjZmYtMmE2Ni00ZTdkLWI5NTgtNjlmMjBiNzU2MmI5XkEyXkFqcGdeQXVyNjU0OTQ0OTY@._V1_SX300.jpg" +released: true +premiere: "18/12/2002" +watched: true +lastWatched: "2003" +personalRating: 7.5 +tags: "#mediaDB/tv/movie" +CollapseMetaTable: yes + +--- + +Parent:: [[Cinematheque]] + +--- + +```dataviewjs +dv.paragraph(`> [!${dv.current().watched ? 'SUCCESS' : 'WARNING'}] ${dv.current().watched ? 'last watched on ' + dv.current().lastWatched : 'not yet watched'}`) +``` + +  + +# `$= dv.current().title` + +  + +`$= dv.current().watched ? '**Rating**: ' + dv.current().personalRating + ' out of 10' : ''` + +```toc +``` + +  + +### Details + +  + +**Genres**: +`$= dv.current().genres.length === 0 ? ' - none' : dv.list(dv.current().genres)` + +`$= !dv.current().released ? '**Not released** The movie is not yet released.' : ''` + +  + +```dataview +list without id + "" + + + "" ++ + "" + + + "" + + + "" + + + "" + + + "" + + + "" + + + "" + + + "
Type" + this.type + "
Online Rating" + this.onlineRating + "
Duration" + this.duration + "
Premiered" + this.premiere + "
Producer" + this.producer + "
" +FROM "03.04 Cinematheque/The Lord of the Rings - The Two Towers (2002)" +``` + +  + +--- + +  + +### Poster + +  + +`$= '![Image|360](' + dv.current().image + ')'` \ No newline at end of file

Guest: Stephanie Nolen, a global health reporter for The New York Times.