vault backup: 2024-05-15 19:12:54

This commit is contained in:
matthias committed 2024-05-15 19:12:54 +02:00
commit f51d8fdd2f
119 files changed
+154202

No files matched your search

+10
View File
@@ -0,0 +1,10 @@
{
"shouldConfirmBeforeCreate": true,
"weekStart": "locale",
"wordsPerDot": 250,
"showWeeklyNote": true,
"weeklyNoteFormat": "",
"weeklyNoteTemplate": "",
"weeklyNoteFolder": "",
"localeOverride": "system-default"
}
+4457
View File
File diff suppressed because it is too large. Load diff
+10
View File
@@ -0,0 +1,10 @@
{
"id": "calendar",
"name": "Calendar",
"description": "Calendar view of your daily notes",
"version": "1.5.10",
"author": "Liam Cain",
"authorUrl": "https://github.com/liamcain/",
"isDesktopOnly": false,
"minAppVersion": "0.9.11"
}
+20404
View File
File diff suppressed because it is too large. Load diff
+10
View File
@@ -0,0 +1,10 @@
{
"id": "dataview",
"name": "Dataview",
"version": "0.5.64",
"minAppVersion": "0.13.11",
"description": "Complex data views for the data-obsessed.",
"author": "Michael Brenan <blacksmithgu@gmail.com>",
"authorUrl": "https://github.com/blacksmithgu",
"isDesktopOnly": false
}
+146
View File
@@ -0,0 +1,146 @@
/** Live Preview padding fixes, specifically for DataviewJS custom HTML elements. */
.is-live-preview .block-language-dataviewjs > p, .is-live-preview .block-language-dataviewjs > span {
line-height: 1.0;
}
.block-language-dataview {
overflow-y: auto;
}
/*****************/
/** Table Views **/
/*****************/
/* List View Default Styling; rendered internally as a table. */
.table-view-table {
width: 100%;
}
.table-view-table > thead > tr, .table-view-table > tbody > tr {
margin-top: 1em;
margin-bottom: 1em;
text-align: left;
}
.table-view-table > tbody > tr:hover {
background-color: var(--table-row-background-hover);
}
.table-view-table > thead > tr > th {
font-weight: 700;
font-size: larger;
border-top: none;
border-left: none;
border-right: none;
border-bottom: solid;
max-width: 100%;
}
.table-view-table > tbody > tr > td {
text-align: left;
border: none;
font-weight: 400;
max-width: 100%;
}
.table-view-table ul, .table-view-table ol {
margin-block-start: 0.2em !important;
margin-block-end: 0.2em !important;
}
/** Rendered value styling for any view. */
.dataview-result-list-root-ul {
padding: 0em !important;
margin: 0em !important;
}
.dataview-result-list-ul {
margin-block-start: 0.2em !important;
margin-block-end: 0.2em !important;
}
/** Generic grouping styling. */
.dataview.result-group {
padding-left: 8px;
}
/*******************/
/** Inline Fields **/
/*******************/
.dataview.inline-field-key {
padding-left: 8px;
padding-right: 8px;
font-family: var(--font-monospace);
background-color: var(--background-primary-alt);
color: var(--text-nav-selected);
}
.dataview.inline-field-value {
padding-left: 8px;
padding-right: 8px;
font-family: var(--font-monospace);
background-color: var(--background-secondary-alt);
color: var(--text-nav-selected);
}
.dataview.inline-field-standalone-value {
padding-left: 8px;
padding-right: 8px;
font-family: var(--font-monospace);
background-color: var(--background-secondary-alt);
color: var(--text-nav-selected);
}
/***************/
/** Task View **/
/***************/
.dataview.task-list-item, .dataview.task-list-basic-item {
margin-top: 3px;
margin-bottom: 3px;
transition: 0.4s;
}
.dataview.task-list-item:hover, .dataview.task-list-basic-item:hover {
background-color: var(--text-selection);
box-shadow: -40px 0 0 var(--text-selection);
cursor: pointer;
}
/*****************/
/** Error Views **/
/*****************/
div.dataview-error-box {
width: 100%;
min-height: 150px;
display: flex;
align-items: center;
justify-content: center;
border: 4px dashed var(--background-secondary);
}
.dataview-error-message {
color: var(--text-muted);
text-align: center;
}
/*************************/
/** Additional Metadata **/
/*************************/
.dataview.small-text {
font-size: smaller;
color: var(--text-muted);
margin-left: 3px;
}
.dataview.small-text::before {
content: "(";
}
.dataview.small-text::after {
content: ")";
}
+239
View File
@@ -0,0 +1,239 @@
{
"compactView": false,
"excalibrainFilepath": "excalibrain.md",
"indexUpdateInterval": 5000,
"hierarchy": {
"exclusions": [
"excalidraw-border-color",
"excalidraw-css",
"excalidraw-default-mode",
"excalidraw-export-dark",
"excalidraw-export-pngscale",
"excalidraw-export-svgpadding",
"excalidraw-export-transparent",
"excalidraw-font",
"excalidraw-font-color",
"excalidraw-link-brackets",
"excalidraw-link-prefix",
"excalidraw-linkbutton-opacity",
"excalidraw-onload-script",
"excalidraw-plugin",
"excalidraw-url-prefix",
"kanban-plugin"
],
"parents": [
"inception",
"North",
"origin",
"Parent",
"Parents",
"parnet domain",
"source",
"u",
"up"
],
"children": [
"Child",
"Children",
"contributes to",
"d",
"down",
"leads to",
"nurtures",
"South"
],
"leftFriends": [
"advantages",
"alternatives",
"Friend",
"Friends",
"j",
"Jump",
"Jumps",
"pros",
"similar",
"supports"
],
"rightFriends": [
"cons",
"disadvantages",
"missing",
"opposes"
],
"previous": [
"Before",
"Prev",
"Previous",
"w",
"West"
],
"next": [
"After",
"e",
"East",
"n",
"Next"
]
},
"inferAllLinksAsFriends": false,
"inverseInfer": false,
"renderAlias": true,
"nodeTitleScript": "",
"backgroundColor": "#0c3e6aff",
"excludeFilepaths": [],
"showInferredNodes": true,
"showAttachments": true,
"showURLNodes": true,
"showVirtualNodes": true,
"showFolderNodes": false,
"showTagNodes": false,
"showPageNodes": true,
"showNeighborCount": true,
"showFullTagName": false,
"maxItemCount": 30,
"renderSiblings": true,
"baseNodeStyle": {
"prefix": "",
"backgroundColor": "#00000066",
"fillStyle": "solid",
"textColor": "#ffffffff",
"borderColor": "#00000000",
"fontSize": 20,
"fontFamily": 3,
"maxLabelLength": 30,
"roughness": 0,
"strokeShaprness": "round",
"strokeWidth": 1,
"strokeStyle": "solid",
"padding": 10,
"gateRadius": 5,
"gateOffset": 15,
"gateStrokeColor": "#ffffffff",
"gateBackgroundColor": "#ffffffff",
"gateFillStyle": "solid"
},
"centralNodeStyle": {
"fontSize": 30,
"backgroundColor": "#B5B5B5",
"textColor": "#000000ff"
},
"inferredNodeStyle": {
"backgroundColor": "#000005b3",
"textColor": "#95c7f3ff"
},
"urlNodeStyle": {
"prefix": "🌐 "
},
"virtualNodeStyle": {
"backgroundColor": "#ff000066",
"fillStyle": "hachure",
"textColor": "#ffffffff"
},
"siblingNodeStyle": {
"fontSize": 15
},
"attachmentNodeStyle": {
"prefix": "📎 "
},
"folderNodeStyle": {
"prefix": "📂 ",
"strokeShaprness": "sharp",
"borderColor": "#ffd700ff",
"textColor": "#ffd700ff"
},
"tagNodeStyle": {
"prefix": "#",
"strokeShaprness": "sharp",
"borderColor": "#4682b4ff",
"textColor": "#4682b4ff"
},
"tagNodeStyles": {},
"tagStyleList": [],
"baseLinkStyle": {
"strokeColor": "#696969FF",
"strokeWidth": 1,
"strokeStyle": "solid",
"roughness": 0,
"startArrowHead": "none",
"endArrowHead": "none",
"showLabel": false,
"fontSize": 10,
"fontFamily": 3,
"textColor": "#ffffffff"
},
"inferredLinkStyle": {
"strokeStyle": "dashed"
},
"folderLinkStyle": {
"strokeColor": "#ffd700ff"
},
"tagLinkStyle": {
"strokeColor": "#4682b4ff"
},
"hierarchyLinkStyles": {
"inception": {},
"North": {},
"origin": {},
"Parent": {},
"Parents": {},
"parnet domain": {},
"source": {},
"u": {},
"up": {},
"Child": {},
"Children": {},
"contributes to": {},
"d": {},
"down": {},
"leads to": {},
"nurtures": {},
"South": {},
"advantages": {},
"alternatives": {},
"Friend": {},
"Friends": {},
"j": {},
"Jump": {},
"Jumps": {},
"pros": {},
"similar": {},
"supports": {},
"cons": {},
"disadvantages": {},
"missing": {},
"opposes": {},
"Before": {},
"Prev": {},
"Previous": {},
"w": {},
"West": {},
"After": {},
"e": {},
"East": {},
"n": {},
"Next": {}
},
"navigationHistory": [
"ToDo's/ToDo's.md",
"Excalidraw/ExcaliBrain Snapshot - ExcaliBrain Snapshot - Drawing 2023-08-03 02.50.47.excalidraw.excalidraw.excalidraw.md",
"Excalidraw/ExcaliBrain Snapshot - Drawing 2023-08-03 02.50.47.excalidraw.excalidraw.md",
"Programmieren/Label Creator/Drawing 2023-08-03 02.50.47.excalidraw.md"
],
"allowOntologySuggester": true,
"ontologySuggesterParentTrigger": "::p",
"ontologySuggesterChildTrigger": "::c",
"ontologySuggesterLeftFriendTrigger": "::l",
"ontologySuggesterRightFriendTrigger": "::r",
"ontologySuggesterPreviousTrigger": "::e",
"ontologySuggesterNextTrigger": "::n",
"ontologySuggesterTrigger": ":::",
"ontologySuggesterMidSentenceTrigger": "(",
"boldFields": false,
"allowAutozoom": true,
"maxZoom": 1,
"allowAutofocuOnSearch": true,
"defaultAlwaysOnTop": false,
"embedCentralNode": false,
"centerEmbedWidth": 550,
"centerEmbedHeight": 700
}
+3
View File
@@ -0,0 +1,3 @@
"use strict";var e,t,i,n=require("obsidian");!function(e){e[e.DEFINED=1]="DEFINED",e[e.INFERRED=2]="INFERRED"}(e||(e={})),function(e){e[e.PARENT=0]="PARENT",e[e.CHILD=1]="CHILD",e[e.LEFT=2]="LEFT",e[e.RIGHT=3]="RIGHT"}(t||(t={})),function(e){e[e.TO=1]="TO",e[e.FROM=2]="FROM",e[e.BOTH=3]="BOTH"}(i||(i={}));const s=/(?:\[([^[\]]+)\]\()((?:(?:ftp|https?|sftp|shttp|tftp):(?:\/{1,3}|[a-z0-9%])|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}\/)(?:[^\s()<>"']|\([^\s()<>]*\))+(?:\([^\s()<>]*\)|[^\s`*!()\[\]{};:'".,<>?«»“”‘’]))\)|\b()((?:(?:ftp|https?|sftp|shttp|tftp):(?:\/{1,3}|[a-z0-9%])|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}\/)(?:[^\s()<>"']|\([^\s()<>]*\))+(?:\([^\s()<>]*\)|[^\s`*!()\[\]{};:'".,<>?«»“”‘’]))\b/gi;class r{constructor(e){this.plugin=e,this.fileToUrlMap=new Map,this.fileUrlInverseMap=new Map,this.hosts=[],this.initalized=!1,this.app=e.app}async init(){const e=Date.now(),t=this.app.vault.getMarkdownFiles();for(const e of t)await this.parseFileURLs(e);this.registerFileEvents(),this.initalized=!0,console.log(`ExcaliBrain indexed ${this.fileUrlInverseMap.size} URLs from ${this.hosts.length} unique hosts in ${this.fileToUrlMap.size} of ${t.length} markdown files in ${((Date.now()-e)/1e3).toFixed(1)} seconds`)}getOrigin(e,t){try{return new URL(e).origin}catch(i){return console.log(`ExcaliBrain URLParser: Invalid URL ${e} in file ${t.path}`),":Unknown Origin:"}}async parseFileURLs(e){var t,i,r,a;if(!(e&&e instanceof n.TFile))return;let u="";try{u=await this.app.vault.cachedRead(e)}catch(t){return void console.log(`ExcaliBrain URLParser: Failed to read file ${e.path}`,t)}const o=new Map;let l;for(;null!==(l=s.exec(u));){const n=null!==(i=null!==(t=l[1])&&void 0!==t?t:l[3])&&void 0!==i?i:"";let s=null!==(a=null!==(r=l[2])&&void 0!==r?r:l[4])&&void 0!==a?a:"";if(s.match(/^(?:ftp|https?|sftp|shttp|tftp):/)||(s="https://"+s),o.has(s)){if(""!==n){const e=o.get(s);""===e.alias&&o.set(s,Object.assign(Object.assign({},e),{alias:n}))}}else{const t=this.getOrigin(s,e);o.set(s,{url:s,alias:n,origin:t}),this.updateInverseMap(s,e,t)}}const D=Array.from(o.values());D.length>0&&this.fileToUrlMap.set(e,D)}updateInverseMap(e,t,i){this.fileUrlInverseMap.has(e)||this.fileUrlInverseMap.set(e,{files:[],origin:i});const n=this.fileUrlInverseMap.get(e);n&&(n.files.includes(t)||n.files.push(t),this.hosts.includes(n.origin)||this.hosts.push(n.origin))}registerFileEvents(){const e=e=>{t(e),this.parseFileURLs(e)},t=e=>{const t=this.fileToUrlMap.get(e);this.fileToUrlMap.delete(e),t&&t.forEach((t=>{const i=this.fileUrlInverseMap.get(t.url);if(i){if(i.files=i.files.filter((t=>t!==e)),0===i.files.length)return this.fileUrlInverseMap.delete(t.url),void(this.hosts=this.hosts.filter((e=>e!==i.origin)));this.fileUrlInverseMap.set(t.url,i)}}))};this.plugin.registerEvent(this.app.vault.on("create",e)),this.plugin.registerEvent(this.app.vault.on("modify",e)),this.plugin.registerEvent(this.app.vault.on("delete",t))}}const a=(e,t,i)=>{const n=e.metadataCache.getFirstLinkpathDest(t,i);return n?n.path:t},u=(e,t)=>{var i,n,r,u,o;const l=new Set,D=e.matchAll(/[^[]*\[\[(?<wikiLink>[^#\]\|]*)[^\]]*]]|\[[^\]]*]\((?<mdLink>[^)]*)\)/g);let d,h;for(;!(d=D.next()).done;){if(null===(n=null===(i=null==d?void 0:d.value)||void 0===i?void 0:i.groups)||void 0===n?void 0:n.wikiLink){const e=a(app,d.value.groups.wikiLink,t.path);e&&l.add(e)}if(null===(u=null===(r=null==d?void 0:d.value)||void 0===r?void 0:r.groups)||void 0===u?void 0:u.mdLink){const e=a(app,decodeURIComponent(d.value.groups.mdLink),t.path);e&&l.add(e)}}for(;null!==(h=s.exec(e));)l.add(null!==(o=h[2])&&void 0!==o?o:h[4]);return Array.from(l)},o=(e,t,i)=>{var n;const s=new Set;if(t.values){const r=Array.from(t.values());r.filter((e=>(null==e?void 0:e.type)&&("file"===e.type||"header"===e.type||"block"==e.type))).forEach((t=>{const n=a(e,t.path,i.path);n&&s.add(n)})),r.filter((e=>Boolean(null==e?void 0:e.values))).forEach((t=>{const n=Array.from(t.values());o(e,n,i).forEach((e=>s.add(e)))}));const l=u(r.filter((e=>"string"==typeof e)).join(" "),i),D=null===(n=r.filter((e=>(null==e?void 0:e.values)&&"object"==typeof e&&"string"==typeof e.values[0])))||void 0===n?void 0:n.map((t=>a(e,t.values[0],i.path)));
//! currently there is an issue with case sensitivity. DataView retains case sensitivity of links for the front matter, but not the others
return D||console.log({error:"objectLinks is undefined which is unexpected",errorLocation:"readDVField",field:t,file:i}),Array.from(s).concat(l).concat(null!=D?D:[])}if(t.path){const n=a(e,t.path,i.path);return n?[n]:[]}return"string"==typeof t?u(t,i):[]},l=(e,t,i)=>{const n=[],s=new Set;return i.forEach((i=>{const r=t[i];r&&!s.has(i)&&(s.add(i),o(e.app,r,t.file).forEach((e=>n.push({link:e,field:i}))))})),n},D=(e,t)=>{var i;const n=d(e,t);if(!n)return[null,null];if(e[t.primaryTagFieldLowerCase]){const s=null===(i=e[t.primaryTagFieldLowerCase].match(/#([^\s\])$"'\\]*)(?:$|\s)/g))||void 0===i?void 0:i.map((e=>e.trim())).filter((e=>t.tagStyleList.some((t=>e.startsWith(t))))),r=s&&s.length>0?s[0]:n[0];return[r,n.filter((e=>e!=r))]}return[n[0],n.slice(1)]},d=(e,t)=>{var i,n,s;return e?(null!==(s=null===(n=null===(i=e.file)||void 0===i?void 0:i.tags)||void 0===n?void 0:n.values)&&void 0!==s?s:[]).filter((e=>t.tagStyleList.some((t=>e.startsWith(t))))):null},h=(e,t)=>{const[i,n]=e;if(!i)return{};const s=t.tagNodeStyles[t.tagStyleList.filter((e=>i.startsWith(e)))[0]];if(s&&t.displayAllStylePrefixes){const e=Object.keys(t.tagNodeStyles).filter((e=>n.includes(e))),i=new Set;s.prefix&&i.add(s.prefix),null==e||e.map((e=>t.tagNodeStyles[e].prefix)).filter((e=>Boolean(e))).forEach((e=>i.add(e)));const r=Array.from(i).join("");return Object.assign(Object.assign({},s),{prefix:r})}return s},c=e=>{console.error(Object.assign({plugin:"ExcaliBrain"},e))};console.log.bind(window.console),console.log.bind(window.console);const g=e=>`data:image/svg+xml;base64,${btoa(unescape(encodeURIComponent(e.replaceAll("&nbsp;"," "))))}`,E=(e,t)=>{if(!e.DEVICE.isDesktop)return;let i=!0;if(!t){const n=e.targetView;if(!n)return;i=app.workspace.activeLeaf===n.leaf,t=n.ownerWindow}i&&(t.electronWindow.isAlwaysOnTop()||(t.electronWindow.setAlwaysOnTop(!0),setTimeout((()=>{t.electronWindow.setAlwaysOnTop(!1)}),500)))};function p(e){const t=e.lastIndexOf("/"),i=-1==t?e:e.substring(t+1);return{folderpath:n.normalizePath(e.substring(0,t)),filename:i,basename:i.replace(/\.[^/.]+$/,"")}}function f(e,t){return!!e&&["pdf","mp4","mp3","webm","md"].includes(e.extension)&&!t.isExcalidrawFile(e)}class F{constructor(e){this.pages=new Map,this.forEach=this.pages.forEach.bind(this.pages),this.app=e.app,this.plugin=e}add(e,t){this.pages.set(e,t)}has(e){return this.pages.has(e)}get(e){return this.pages.get(e)}getPages(){return Array.from(this.pages.values())}get size(){return this.pages.size}delete(e){const t=this.pages.get(e);t&&(t.neighbours.forEach(((t,i)=>{const n=this.pages.get(i);n&&(n.unlinkNeighbour(e),n.file||0!==n.neighbours.size||this.pages.delete(i))})),this.pages.delete(e))}addInferredParentChild(t,n){this.plugin.settings.inferAllLinksAsFriends?(n.addLeftFriend(t,e.INFERRED,i.TO),t.addLeftFriend(n,e.INFERRED,i.FROM)):this.plugin.settings.inverseInfer?(n.addChild(t,e.INFERRED,i.TO),t.addParent(n,e.INFERRED,i.FROM)):(n.addParent(t,e.INFERRED,i.TO),t.addChild(n,e.INFERRED,i.FROM))}addResolvedLinks(e){const t=this.app.metadataCache.resolvedLinks;Object.keys(t).forEach((i=>{if(e&&e.path!==i)return;const n=this.pages.get(i);Object.keys(t[i]).forEach((e=>{let t=this.pages.get(e);t||(t=this.pages.get(this.plugin.lowercasePathMap.get(e.toLowerCase()))),this.addInferredParentChild(n,t)}))}))}addPageURLs(){this.plugin.urlParser.fileToUrlMap.forEach(((t,n)=>{const s=this.get(n.path);s&&t.forEach((t=>{let n=this.get(t.url);n||(n=new A(this,t.url,null,this.plugin,!1,!1,t.alias,t.url),this.add(t.url,n)),""===t.alias||""!==n.name&&n.name!==t.url||(n.name=t.alias),this.addInferredParentChild(s,n);const r=this.get(t.origin);r&&(n.addParent(r,e.INFERRED,i.FROM),r.addChild(n,e.INFERRED,i.TO))}))}))}addUnresolvedLinks(e){if(e&&(e.isFolder||e.isTag))return;const t=this.app.metadataCache.unresolvedLinks;Object.keys(t).forEach((i=>{if(e&&e.path!==i)return;let n=this.pages.get(i);n&&i!==this.plugin.settings.excalibrainFilepath&&Object.keys(t[i]).forEach((e=>m(e,n,this.plugin,this)))}))}}const m=(t,n,s,r)=>{var a;const u=null!==(a=r.get(t))&&void 0!==a?a:new A(r,t,null,s);return s.settings.inferAllLinksAsFriends?(u.addLeftFriend(n,e.INFERRED,i.TO),n.addLeftFriend(u,e.INFERRED,i.FROM)):s.settings.inverseInfer?(u.addChild(n,e.INFERRED,i.TO),n.addParent(u,e.INFERRED,i.FROM)):(u.addParent(n,e.INFERRED,i.TO),n.addChild(u,e.INFERRED,i.FROM)),r.add(t,u),u},C={target:null,isParent:!1,isChild:!1,isLeftFriend:!1,isRightFriend:!1,isNextFriend:!1,isPreviousFriend:!1,direction:null},y=(e,t)=>e&&t?e+", "+t:e||t,S=(e,t)=>e?e===i.BOTH||e===t?e:i.BOTH:t,b=(t,i)=>t===e.DEFINED?e.DEFINED:t===e.INFERRED?i===e.DEFINED?e.DEFINED:e.INFERRED:i;class A{constructor(e,t,i,n,s=!1,r=!1,a,u=null){this.pages=e,this.path=t,this.file=i,this.plugin=n,this.isFolder=s,this.isTag=r,this.name=a,this.url=u,this.dvIndexReady=!1,a||(this.name=i?"md"===i.extension?i.basename:i.name:Boolean(u)?u:(e=>{const t=e.endsWith(".md"),i=e.substring(e.lastIndexOf("/")+1);return t?i.slice(0,-3):i})(t)),this.mtime=i?i.stat.mtime:nLine truncated
+10
View File
@@ -0,0 +1,10 @@
{
"id": "excalibrain",
"name": "ExcaliBrain",
"version": "0.2.11",
"minAppVersion": "1.1.6",
"description": "A clean, intuitive and editable graph view for Obsidian",
"author": "Zsolt Viczian",
"authorUrl": "https://zsolt.blog",
"isDesktopOnly": false
}
+349
View File
@@ -0,0 +1,349 @@
/* Sets all the text color to red! */
.excalibrain-warning {
background-color: var(--text-highlight-bg);
color: var(--text-normal);
}
.excalibrain-prompt-center {
text-align: center;
}
.excalibrain-contentEl div.Island,
.excalibrain-contentEl button.help-icon {
display:none;
}
.excalibrain-contentEl {
overflow: hidden !important;
position: relative;
}
/* -----------
TOOLS PANEL
------------ */
.excalibrain-toolspanel-wrapper {
z-index: 3;
position: absolute;
top: 0.6em;
padding-left: 0.6em;
/* Set width to auto to fit its content */
width: 100%;
padding-right: 0.6em;
pointer-events: none;
display: flex;
flex-wrap: wrap;
justify-content: space-between;
}
.excalibrain-dropdown-wrapper,
.excalibrain-buttons {
pointer-events: none;
margin-top: 0.3em;
max-width: 37em;
justify-content: space-between;
}
.excalibrain-searchinput {
width: 26em;
vertical-align: middle;
pointer-events: all;
}
.excalibrain-buttons {
margin-left: -0.3em;
display: flex;
float: right;
flex: 1 0 30em;
}
.excalibrain-toolspanel-divider {
width: 0.15em;
background-color: var(--default-border-color);
margin-left: 0.5em;
margin-right: 0.2em;
}
.excalibrain-button {
pointer-events: all;
vertical-align: middle;
padding-left: 0.3em;
padding-right: 0.3em;
margin-left: 0.3em !important;
margin-right: 0px !important;
width: 2.4em !important;
justify-content: center !important;
box-shadow: none;
transition: box-shadow 0.3s ease;
}
.excalibrain-button.off {
background-color: var(--island-bg-color);
}
.excalibrain-button.on {
background-color: var(--color-primary-darker);
}
.excalibrain-button:hover {
box-shadow: 0 3px 6px rgba(0, 0, 0, 0.4);
}
.excalibrain-button:active {
box-shadow: 0 6px 12px rgba(0, 0, 0, 0.6);
}
.excalibrain-button.disabled {
background-color: var(--island-bg-color);
pointer-events: none;
opacity: 0.5;
cursor: not-allowed;
}
/* -----------
HISTORY
------------ */
.excalibrain-history-wrapper {
z-index: 3;
position: absolute;
bottom: 0px;
padding-left: 7rem;
padding-bottom: 10px;
width: 100%;
padding-right: 10px;
overflow: hidden;
}
.excalibrain-history-container {
overflow-y: hidden;
display: -webkit-box;
overflow-x: scroll;
padding-left: 0.5em;
background-color: #00000030;
}
.excalibrain-history-divider {
color: gold;
margin-left: 5px;
margin-right: 5px;
font-size: smaller;
}
.excalibrain-history-item {
cursor: pointer;
color: silver;
font-size: smaller;
}
/* -----------
SETTINGS
------------ */
.excalibrain-settings-folding-L1 {
font-size: large;
font-weight: bold;
color: var(--text-title-h3);
}
.excalibrain-settings-h1 {
color: var(--text-title-h1);
}
.excalibrain-setting-style-section {
padding-left: 30px;
border-left: 10px solid var(--background-modifier-border);
}
.excalibrain-settings-demoimg {
max-width: 400px;
}
.excalibrain-setting-nameEl {
min-width: 10em;
max-width: 20em;
}
.excalibrain-setting-descEl {
min-width: 10em;
max-width: 20em;
}
.excalibrain-setting-controlEl {
width: 90%;
}
.excalibrain-settings-colorlabel {
padding-right: 5px;
min-width: 3em;
}
.excalibrain-settings-colorpicker {
max-width: 32px;
min-width: 32px;
width: 32px !important;
}
.excalibrain-settings-opacitylabel {
padding-right: 5px;
padding-left: 10px;
min-width: 5em;
}
.excalibrain-settings-sliderlabel {
min-width: 2em;
text-align: right;
}
.excalibrain-settings-toggle {
min-width: 2em;
margin-right: 5px;
}
.excalibrain-dropdown-wrapper {
display: inline-flex;
}
/* -----------
MULTISELECT
------------ */
.multiselect-container {
padding-left: 0.3em;
width:14.2em;
pointer-events: all;
}
.multiselect-container * {
box-sizing:border-box;
}
.multiselect-container .multiselect-header {
width:100%;
margin-bottom:6px;
}
.multiselect-container .multiselect-wrapper {
position:relative;
width:100%;
height:30px;
background: var(--island-bg-color); /*var(--background-modifier-form-field);*/
border:1px solid var(--background-modifier-border);
display:flex;
align-items:center;
padding:0 8px;
cursor:pointer
}
.multiselect-container .multiselect-wrapper:after {
content:"";
position:absolute;
width:8px;
height:8px;
right:12px;
top:8px;
border-right:2px solid var(--text-normal);
border-top:2px solid var(--text-normal);
transform:rotate(135deg);
transform-origin:center center;
transition:all .2s ease-in-out;
}
.multiselect-container .multiselect-wrapper .selected-value {
padding-right:30px;
text-overflow:ellipsis;
overflow:hidden;
white-space:nowrap;
}
.multiselect-container .multiselect-wrapper .options-wrapper {
position:absolute;
top:100%;
left:0;
width:100%;
max-height:300px;
overflow:auto;
background-color:var(--background-secondary);
border:1px solid var(--background-modifier-border);
display:none;
flex-direction:column;
}
.multiselect-container .multiselect-wrapper .option:hover {
cursor:pointer;
background-color:rgba(0,0,0,0.1);
}
.multiselect-container .multiselect-wrapper .option-text {
display:none;
padding:6px 12px;
}
.multiselect-container .multiselect-wrapper .checkbox-wrapper {
display:flex;
align-items:center;min-height:19px;
position:relative;
padding:6px 12px 6px 36px;
cursor:pointer;
-webkit-user-select:none;
-moz-user-select:none;
-ms-user-select:none;
user-select:none;
}
.multiselect-container .multiselect-wrapper .checkbox-wrapper .checkbox-checkmark {
position:absolute;
top:6px;
left:6px;
height:19px;
width:19px;
background-color:#eee;
border-radius:4px;
border:1px solid #000;
}
.multiselect-container .multiselect-wrapper .checkbox-wrapper .checkbox-checkmark:after {
content:'';
position:absolute;display:none;
left:6px;
top:2px;
width:4px;
height:8px;
border:solid white;
border-width:0 2px 2px 0;
transform:rotate(45deg);
}
.multiselect-container .multiselect-wrapper .checkbox-wrapper input {
position:absolute;
opacity:0;
cursor:pointer;
height:0;
width:0;
}
.multiselect-container .multiselect-wrapper .checkbox-wrapper input:checked ~ .checkbox-checkmark {
background-color:#2196F3;
}
.multiselect-container .multiselect-wrapper .checkbox-wrapper input:checked ~ .checkbox-checkmark:after {
display:block;
}
.multiselect-container .multiselect-wrapper.single-select .checkbox-wrapper {
display:none;
}
.multiselect-container .multiselect-wrapper.single-select .option-text {
display:block;
}
.multiselect-container .multiselect-wrapper.single-select .option-text.selected {
background-color:#2196F3;
}
.multiselect-container .multiselect-wrapper.opened:after {
top:12px;
transform:rotate(315deg);
}
.multiselect-container .multiselect-wrapper.opened .options-wrapper {
display:flex;
}
+213
View File
@@ -0,0 +1,213 @@
/*
THIS IS A GENERATED/BUNDLED FILE BY ESBUILD
if you want to view the source visit the plugins github repository (https://github.com/phibr0/obsidian-dictionary)
*/
var ob=Object.create;var Hi=Object.defineProperty,ab=Object.defineProperties,lb=Object.getOwnPropertyDescriptor,cb=Object.getOwnPropertyDescriptors,hb=Object.getOwnPropertyNames,Us=Object.getOwnPropertySymbols,ub=Object.getPrototypeOf,Yo=Object.prototype.hasOwnProperty,Vc=Object.prototype.propertyIsEnumerable;var Yc=(n,t,e)=>t in n?Hi(n,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[t]=e,Nn=(n,t)=>{for(var e in t||(t={}))Yo.call(t,e)&&Yc(n,e,t[e]);if(Us)for(var e of Us(t))Vc.call(t,e)&&Yc(n,e,t[e]);return n},_i=(n,t)=>ab(n,cb(t)),Xc=n=>Hi(n,"__esModule",{value:!0});var qc=(n,t)=>{var e={};for(var i in n)Yo.call(n,i)&&t.indexOf(i)<0&&(e[i]=n[i]);if(n!=null&&Us)for(var i of Us(n))t.indexOf(i)<0&&Vc.call(n,i)&&(e[i]=n[i]);return e};var Xo=(n,t)=>()=>(t||n((t={exports:{}}).exports,t),t.exports),fb=(n,t)=>{Xc(n);for(var e in t)Hi(n,e,{get:t[e],enumerable:!0})},db=(n,t,e)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of hb(t))!Yo.call(n,i)&&i!=="default"&&Hi(n,i,{get:()=>t[i],enumerable:!(e=lb(t,i))||e.enumerable});return n},ze=n=>db(Xc(Hi(n!=null?ob(ub(n)):{},"default",n&&n.__esModule&&"default"in n?{get:()=>n.default,enumerable:!0}:{value:n,enumerable:!0})),n);var Ku=Xo((qa,Ga)=>{(function(n,t){typeof qa=="object"&&typeof Ga!="undefined"?Ga.exports=t():typeof define=="function"&&define.amd?define(t):(n=typeof globalThis!="undefined"?globalThis:n||self,n.chroma=t())})(qa,function(){"use strict";for(var n=function(u,d,b){return d===void 0&&(d=0),b===void 0&&(b=1),u<d?d:u>b?b:u},t=n,e=function(u){u._clipped=!1,u._unclipped=u.slice(0);for(var d=0;d<=3;d++)d<3?((u[d]<0||u[d]>255)&&(u._clipped=!0),u[d]=t(u[d],0,255)):d===3&&(u[d]=t(u[d],0,1));return u},i={},s=0,r=["Boolean","Number","String","Function","Array","Date","RegExp","Undefined","Null"];s<r.length;s+=1){var o=r[s];i["[object "+o+"]"]=o.toLowerCase()}var a=function(u){return i[Object.prototype.toString.call(u)]||"object"},l=a,c=function(u,d){return d===void 0&&(d=null),u.length>=3?Array.prototype.slice.call(u):l(u[0])=="object"&&d?d.split("").filter(function(b){return u[0][b]!==void 0}).map(function(b){return u[0][b]}):u[0]},h=a,f=function(u){if(u.length<2)return null;var d=u.length-1;return h(u[d])=="string"?u[d].toLowerCase():null},g=Math.PI,p={clip_rgb:e,limit:n,type:a,unpack:c,last:f,PI:g,TWOPI:g*2,PITHIRD:g/3,DEG2RAD:g/180,RAD2DEG:180/g},m={format:{},autodetect:[]},y=p.last,S=p.clip_rgb,M=p.type,C=m,F=function(){for(var d=[],b=arguments.length;b--;)d[b]=arguments[b];var _=this;if(M(d[0])==="object"&&d[0].constructor&&d[0].constructor===this.constructor)return d[0];var P=y(d),T=!1;if(!P){T=!0,C.sorted||(C.autodetect=C.autodetect.sort(function(B,q){return q.p-B.p}),C.sorted=!0);for(var w=0,A=C.autodetect;w<A.length;w+=1){var L=A[w];if(P=L.test.apply(L,d),P)break}}if(C.format[P]){var j=C.format[P].apply(null,T?d:d.slice(0,-1));_._rgb=S(j)}else throw new Error("unknown format: "+d);_._rgb.length===3&&_._rgb.push(1)};F.prototype.toString=function(){return M(this.hex)=="function"?this.hex():"["+this._rgb.join(",")+"]"};var D=F,I=function(){for(var u=[],d=arguments.length;d--;)u[d]=arguments[d];return new(Function.prototype.bind.apply(I.Color,[null].concat(u)))};I.Color=D,I.version="2.4.2";var $=I,N=p.unpack,G=Math.max,U=function(){for(var u=[],d=arguments.length;d--;)u[d]=arguments[d];var b=N(u,"rgb"),_=b[0],P=b[1],T=b[2];_=_/255,P=P/255,T=T/255;var w=1-G(_,G(P,T)),A=w<1?1/(1-w):0,L=(1-_-w)*A,j=(1-P-w)*A,B=(1-T-w)*A;return[L,j,B,w]},it=U,lt=p.unpack,rt=function(){for(var u=[],d=arguments.length;d--;)u[d]=arguments[d];u=lt(u,"cmyk");var b=u[0],_=u[1],P=u[2],T=u[3],w=u.length>4?u[4]:1;return T===1?[0,0,0,w]:[b>=1?0:255*(1-b)*(1-T),_>=1?0:255*(1-_)*(1-T),P>=1?0:255*(1-P)*(1-T),w]},Pt=rt,zt=$,et=D,Et=m,St=p.unpack,re=p.type,ye=it;et.prototype.cmyk=function(){return ye(this._rgb)},zt.cmyk=function(){for(var u=[],d=arguments.length;d--;)u[d]=arguments[d];return new(Function.prototype.bind.apply(et,[null].concat(u,["cmyk"])))},Et.format.cmyk=Pt,Et.autodetect.push({p:2,test:function(){for(var u=[],d=arguments.length;d--;)u[d]=arguments[d];if(u=St(u,"cmyk"),re(u)==="array"&&u.length===4)return"cmyk"}});var ot=p.unpack,Lt=p.last,Bt=function(u){return Math.round(u*100)/100},Ut=function(){for(var u=[],d=arguments.length;d--;)u[d]=arguments[d];var b=ot(u,"hsla"),_=Lt(u)||"lsa";return b[0]=Bt(b[0]||0),b[1]=Bt(b[1]*100)+"%",b[2]=Bt(b[2]*100)+"%",_==="hsla"||b.length>3&&b[3]<1?(b[3]=b.length>3?b[3]:1,_="hsla"):b.length=3,_+"("+b.join(",")+")"},Qt=Ut,k=p.unpack,v=function(){for(var u=[],d=arguments.length;d--;)u[d]=arguments[d];u=k(u,"rgba");var b=u[0],_=u[1],P=u[2];b/=255,_/=255,P/=255;var T=Math.min(b,_,P),w=Math.max(b,_,P),A=(w+T)/2,L,j;return w===T?(L=0,j=Number.NaN):L=A<.5?(w-T)/(w+T):(w-T)/(2-w-T),b==w?j=(_-P)/(w-T):_==w?j=2+(P-b)/(w-T):P==w&&(j=4+(b-_)/(w-T)),j*=60,j<0&&(j+=360),u.length>3&&u[3]!==void 0?[j,L,A,u[3]]:[j,L,A]},x=v,R=p.unpack,E=p.last,O=Qt,Z=x,V=Math.round,J=function(){for(var u=[],d=arguments.length;d--;)u[d]=arguments[d];var b=R(Line truncated
<pre><code>`+Z+`
</code></pre>
`;var V=this.options.langPrefix+this.options.escape(x,!0);return`
<pre><code class="`+V+'">'+Z+`
</code></pre>
`},k.prototype.blockquote=function(v){return`<blockquote>
`+v+`</blockquote>
`},k.prototype.html=function(v){return v},k.prototype.heading=function(v,x,R){var E=this.options.headerPrefix+R.toLowerCase().replace(/[^\w]+/g,"-");return"<h"+x+' id="'+E+'">'+v+"</h"+x+`>
`},k.prototype.hr=function(){return this.options.xhtml?`<hr/>
`:`<hr>
`},k.prototype.list=function(v,x){var R=x?"ol":"ul";return`
<`+R+`>
`+v+"</"+R+`>
`},k.prototype.listitem=function(v){return"<li>"+v+`</li>
`},k.prototype.paragraph=function(v){return"<p>"+v+`</p>
`},k.prototype.table=function(v,x){return`
<table>
<thead>
`+v+`</thead>
<tbody>
`+x+`</tbody>
</table>
`},k.prototype.tablerow=function(v){return`<tr>
`+v+`</tr>
`},k.prototype.tablecell=function(v,x){var R=x.header?"th":"td",E=x.align?"<"+R+' style="text-align:'+x.align+'">':"<"+R+">";return E+v+"</"+R+`>
`},k.prototype.strong=function(v){return"<strong>"+v+"</strong>"},k.prototype.em=function(v){return"<em>"+v+"</em>"},k.prototype.codespan=function(v){return"<code>"+v+"</code>"},k.prototype.br=function(){return this.options.xhtml?"<br/>":"<br>"},k.prototype.del=function(v){return"<del>"+v+"</del>"},k.prototype.link=function(v,x,R){if(this.options.sanitize){var E=void 0;try{E=decodeURIComponent(this.options.unescape(v)).replace(/[^\w:]/g,"").toLowerCase()}catch(Z){return R}if(E.indexOf("javascript:")===0||E.indexOf("vbscript:")===0||E.indexOf("data:")===0)return R}var O='<a href="'+v+'"';return x&&(O+=' title="'+x+'"'),O+=">"+R+"</a>",O},k.prototype.image=function(v,x,R){var E='<img src="'+v+'" alt="'+R+'"';return x&&(E+=' title="'+x+'"'),E+=this.options.xhtml?"/>":">",E},k.prototype.text=function(v){return v},k}();var Lt=function(){function k(v,x,R,E){if(R===void 0&&(R=Ut.options),this.staticThis=v,this.links=x,this.options=R,this.renderer=E||this.options.renderer||new ot(this.options),!this.links)throw new Error("InlineLexer requires 'links' parameter.");this.setRules()}return k.output=function(v,x,R){var E=new this(this,x,R);return E.output(v)},k.getRulesBase=function(){if(this.rulesBase)return this.rulesBase;var v={escape:/^\\([\\`*{}\[\]()#+\-.!_>])/,autolink:/^<([^ <>]+(@|:\/)[^ <>]+)>/,tag:/^<!--[\s\S]*?-->|^<\/?\w+(?:"[^"]*"|'[^']*'|[^<'">])*?>/,link:/^!?\[(inside)\]\(href\)/,reflink:/^!?\[(inside)\]\s*\[([^\]]*)\]/,nolink:/^!?\[((?:\[[^\]]*\]|[^\[\]])*)\]/,strong:/^__([\s\S]+?)__(?!_)|^\*\*([\s\S]+?)\*\*(?!\*)/,em:/^\b_((?:[^_]|__)+?)_\b|^\*((?:\*\*|[\s\S])+?)\*(?!\*)/,code:/^(`+)([\s\S]*?[^`])\1(?!`)/,br:/^ {2,}\n(?!\s*$)/,text:/^[\s\S]+?(?=[\\<!\[_*`]| {2,}\n|$)/,_inside:/(?:\[[^\]]*\]|[^\[\]]|\](?=[^\[]*\]))*/,_href:/\s*<?([\s\S]*?)>?(?:\s+['"]([\s\S]*?)['"])?\s*/};return v.link=new t(v.link).setGroup("inside",v._inside).setGroup("href",v._href).getRegexp(),v.reflink=new t(v.reflink).setGroup("inside",v._inside).getRegexp(),this.rulesBase=v},k.getRulesPedantic=function(){return this.rulesPedantic?this.rulesPedantic:this.rulesPedantic=Object.assign(Object.assign({},this.getRulesBase()),{strong:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,em:/^_(?=\S)([\s\S]*?\S)_(?!_)|^\*(?=\S)([\s\S]*?\S)\*(?!\*)/})},k.getRulesGfm=function(){if(this.rulesGfm)return this.rulesGfm;var v=this.getRulesBase(),x=new t(v.escape).setGroup("])","~|])").getRegexp(),R=new t(v.text).setGroup("]|","~]|").setGroup("|","|https?://|").getRegexp();return this.rulesGfm=Object.assign(Object.assign({},v),{escape:x,url:/^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/,del:/^~~(?=\S)([\s\S]*?\S)~~/,text:R})},k.getRulesBreaks=function(){if(this.rulesBreaks)return this.rulesBreaks;var v=this.getRulesGfm(),x=this.getRulesGfm();return this.rulesBreaks=Object.assign(Object.assign({},x),{br:new t(v.br).setGroup("{2,}","*").getRegexp(),text:new t(x.text).setGroup("{2,}","*").getRegexp()})},k.prototype.setRules=function(){this.options.gfm?this.options.breaks?this.rules=this.staticThis.getRulesBreaks():this.rules=this.staticThis.getRulesGfm():this.options.pedantic?this.rules=this.staticThis.getRulesPedantic():this.rules=this.staticThis.getRulesBase(),this.hasRulesGfm=this.rules.url!==void 0},k.prototype.output=function(v){v=v;for(var x,R="";v;){if(x=this.rules.escape.exec(v)){v=v.substring(x[0].length),R+=x[1];continue}if(x=this.rules.autolink.exec(v)){var E=void 0,O=void 0;v=v.substring(x[0].length),x[2]==="@"?(E=this.options.escape(x[1].charAt(6)===":"?this.mangle(x[1].substring(7)):this.mangle(x[1])),O=this.mangle("mailto:")+E):(E=this.options.escape(x[1]),O=E),R+=this.renderer.link(O,null,E);continue}if(!this.inLink&&this.hasRulesGfm&&(x=this.rules.url.exec(v))){var E=void 0,O=void 0;v=v.substring(x[0].length),E=this.options.escape(x[1]),O=E,R+=this.renderer.link(O,null,E);continue}if(x=this.rules.tag.exec(v)){!this.inLink&&/^<a /i.test(x[0])?this.inLink=!0:this.inLink&&/^<\/a>/i.test(x[0])&&(this.inLink=!1),v=v.substring(x[0].length),R+=this.options.sanitize?this.options.sanitizer?this.options.sanitizer(x[0]):this.options.escape(x[0]):x[0];continue}if(x=this.rules.link.exec(v)){v=v.substring(x[0].length),this.inLink=!0,R+=this.outputLink(x,{href:x[2],title:x[3]}),this.inLink=!1;continue}if((x=this.rules.reflink.exec(v))||(x=this.rules.nolink.exec(v))){v=v.substring(x[0].length);var Z=(x[2]||x[1]).replace(/\s+/g," "),V=this.links[Z.toLowerCase()];if(!V||!V.href){R+=x[0].charAt(0),v=x[0].substring(1)+v;continue}this.inLink=!0,R+=this.outputLink(x,V),this.inLink=!1;continue}if(x=this.rules.strong.exec(v)){v=v.substring(x[0].length),R+=this.renderer.strong(this.output(x[2]||x[1]));continue}if(x=this.rules.em.exec(v)){v=v.substring(x[0].length),R+=this.renderer.em(this.output(x[2]||x[1]));continue}if(x=this.rules.code.exec(v)){v=v.substring(x[0].length),R+=this.renderer.codespan(this.options.escape(x[2].trim(),!0));continue}if(x=this.rules.br.exec(v)){v=v.substring(x[0].length),R+=this.renderer.br();continue}if(this.hasRulesGfm&&(x=tLine truncated
`).length-1,R+=E}return R},k.prototype.next=function(){return this.token=this.tokens.pop()},k.prototype.getNextElement=function(){return this.tokens[this.tokens.length-1]},k.prototype.parseText=function(){for(var v=this.token.text,x;(x=this.getNextElement())&&x.type==n.TokenType.text;)v+=`
`+this.next().text;return this.inlineLexer.output(v)},k.prototype.tok=function(){var v,x;switch(this.token.type){case n.TokenType.space:return"";case n.TokenType.paragraph:return this.renderer.paragraph(this.inlineLexer.output(this.token.text));case n.TokenType.text:return this.options.isNoP?this.parseText():this.renderer.paragraph(this.parseText());case n.TokenType.heading:return this.renderer.heading(this.inlineLexer.output(this.token.text),this.token.depth,this.token.text);case n.TokenType.listStart:{for(var R="",E=this.token.ordered;this.next().type!=n.TokenType.listEnd;)R+=this.tok();return this.renderer.list(R,E)}case n.TokenType.listItemStart:{for(var R="";this.next().type!=n.TokenType.listItemEnd;)R+=this.token.type==n.TokenType.text?this.parseText():this.tok();return this.renderer.listitem(R)}case n.TokenType.looseItemStart:{for(var R="";this.next().type!=n.TokenType.listItemEnd;)R+=this.tok();return this.renderer.listitem(R)}case n.TokenType.code:return this.renderer.code(this.token.text,this.token.lang,this.token.escaped,this.token.meta);case n.TokenType.table:{var O="",R="",Z=void 0;Z="";for(var V=0;V<this.token.header.length;V++){var J={header:!0,align:this.token.align[V]},tt=this.inlineLexer.output(this.token.header[V]);Z+=this.renderer.tablecell(tt,J)}O+=this.renderer.tablerow(Z);try{for(var xt=I(this.token.cells),Ht=xt.next();!Ht.done;Ht=xt.next()){var Ot=Ht.value;Z="";for(var Yt=0;Yt<Ot.length;Yt++)Z+=this.renderer.tablecell(this.inlineLexer.output(Ot[Yt]),{header:!1,align:this.token.align[Yt]});R+=this.renderer.tablerow(Z)}}catch(xe){v={error:xe}}finally{try{Ht&&!Ht.done&&(x=xt.return)&&x.call(xt)}finally{if(v)throw v.error}}return this.renderer.table(O,R)}case n.TokenType.blockquoteStart:{for(var R="";this.next().type!=n.TokenType.blockquoteEnd;)R+=this.tok();return this.renderer.blockquote(R)}case n.TokenType.hr:return this.renderer.hr();case n.TokenType.html:{var Xt=!this.token.pre&&!this.options.pedantic?this.inlineLexer.output(this.token.text):this.token.text;return this.renderer.html(Xt)}default:{if(this.simpleRenderers.length){for(var V=0;V<this.simpleRenderers.length;V++)if(this.token.type=="simpleRule"+(V+1))return this.simpleRenderers[V].call(this.renderer,this.token.execArr)}var ue='Token with "'+this.token.type+'" type was not found.';if(this.options.silent)console.log(ue);else throw new Error(ue)}}},k}();var Ut=function(){function k(){}return k.setOptions=function(v){return Object.assign(this.options,v),this},k.setBlockRule=function(v,x){return x===void 0&&(x=function(){return""}),Qt.simpleRules.push(v),this.simpleRenderers.push(x),this},k.parse=function(v,x){x===void 0&&(x=this.options);try{var R=this.callBlockLexer(v,x),E=R.tokens,O=R.links;return this.callParser(E,O,x)}catch(Z){return this.callMe(Z)}},k.debug=function(v,x){x===void 0&&(x=this.options);var R=this.callBlockLexer(v,x),E=R.tokens,O=R.links,Z=E.slice(),V=new Bt(x);V.simpleRenderers=this.simpleRenderers;var J=V.debug(O,E);return Z=Z.map(function(tt){tt.type=n.TokenType[tt.type]||tt.type;var xt=tt.line;return delete tt.line,xt?Object.assign({line:xt},tt):tt}),{tokens:Z,links:O,result:J}},k.callBlockLexer=function(v,x){if(v===void 0&&(v=""),typeof v!="string")throw new Error("Expected that the 'src' parameter would have a 'string' type, got '"+typeof v+"'");return v=v.replace(/\r\n|\r/g,`
`).replace(/\t/g," ").replace(/\u00a0/g," ").replace(/\u2424/g,`
`).replace(/^ +$/gm,""),Qt.lex(v,x,!0)},k.callParser=function(v,x,R){if(this.simpleRenderers.length){var E=new Bt(R);return E.simpleRenderers=this.simpleRenderers,E.parse(x,v)}else return Bt.parse(v,x,R)},k.callMe=function(v){if(v.message+=`
Please report this to https://github.com/ts-stack/markdown`,this.options.silent)return"<p>An error occured:</p><pre>"+this.options.escape(v.message+"",!0)+"</pre>";throw v},k}();Ut.options=new c,Ut.simpleRenderers=[];var Qt=function(){function k(v,x){this.staticThis=v,this.links={},this.tokens=[],this.options=x||Ut.options,this.setRules()}return k.lex=function(v,x,R,E){var O=new this(this,x);return O.getTokens(v,R,E)},k.getRulesBase=function(){if(this.rulesBase)return this.rulesBase;var v={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,hr:/^( *[-*_]){3,} *(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *#* *(?:\n+|$)/,lheading:/^([^\n]+)\n *(=|-){2,} *(?:\n+|$)/,blockquote:/^( *>[^\n]+(\n[^\n]+)*\n*)+/,list:/^( *)(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,html:/^ *(?:comment *(?:\n|\s*$)|closed *(?:\n{2,}|\s*$)|closing *(?:\n{2,}|\s*$))/,def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +["(]([^\n]+)[")])? *(?:\n+|$)/,paragraph:/^((?:[^\n]+\n?(?!hr|heading|lheading|blockquote|tag|def))+)\n*/,text:/^[^\n]+/,bullet:/(?:[*+-]|\d+\.)/,item:/^( *)(bull) [^\n]*(?:\n(?!\1bull )[^\n]*)*/};v.item=new t(v.item,"gm").setGroup(/bull/g,v.bullet).getRegexp(),v.list=new t(v.list).setGroup(/bull/g,v.bullet).setGroup("hr","\\n+(?=\\1?(?:[-*_] *){3,}(?:\\n+|$))").setGroup("def","\\n+(?="+v.def.source+")").getRegexp();var x="(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:/|[^\\w\\s@]*@)\\b";return v.html=new t(v.html).setGroup("comment",/<!--[\s\S]*?-->/).setGroup("closed",/<(tag)[\s\S]+?<\/\1>/).setGroup("closing",/<tag(?:"[^"]*"|'[^']*'|[^'">])*?>/).setGroup(/tag/g,x).getRegexp(),v.paragraph=new t(v.paragraph).setGroup("hr",v.hr).setGroup("heading",v.heading).setGroup("lheading",v.lheading).setGroup("blockquote",v.blockquote).setGroup("tag","<"+x).setGroup("def",v.def).getRegexp(),this.rulesBase=v},k.getRulesGfm=function(){if(this.rulesGfm)return this.rulesGfm;var v=this.getRulesBase(),x=Object.assign(Object.assign({},v),{fences:/^ *(`{3,}|~{3,})[ \.]*((\S+)? *[^\n]*)\n([\s\S]*?)\s*\1 *(?:\n+|$)/,paragraph:/^/,heading:/^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/}),R=x.fences.source.replace("\\1","\\2"),E=v.list.source.replace("\\1","\\3");return x.paragraph=new t(v.paragraph).setGroup("(?!","(?!"+R+"|"+E+"|").getRegexp(),this.rulesGfm=x},k.getRulesTable=function(){return this.rulesTables?this.rulesTables:this.rulesTables=Object.assign(Object.assign({},this.getRulesGfm()),{nptable:/^ *(\S.*\|.*)\n *([-:]+ *\|[-| :]*)\n((?:.*\|.*(?:\n|$))*)\n*/,table:/^ *\|(.+)\n *\|( *[-:]+[-| :]*)\n((?: *\|.*(?:\n|$))*)\n*/})},k.prototype.setRules=function(){this.options.gfm?this.options.tables?this.rules=this.staticThis.getRulesTable():this.rules=this.staticThis.getRulesGfm():this.rules=this.staticThis.getRulesBase(),this.hasRulesGfm=this.rules.fences!==void 0,this.hasRulesTables=this.rules.table!==void 0},k.prototype.getTokens=function(v,x,R){var E=v,O;t:for(;E;){if((O=this.rules.newline.exec(E))&&(E=E.substring(O[0].length),O[0].length>1&&this.tokens.push({type:n.TokenType.space})),O=this.rules.code.exec(E)){E=E.substring(O[0].length);var Z=O[0].replace(/^ {4}/gm,"");this.tokens.push({type:n.TokenType.code,text:this.options.pedantic?Z:Z.replace(/\n+$/,"")});continue}if(this.hasRulesGfm&&(O=this.rules.fences.exec(E))){E=E.substring(O[0].length),this.tokens.push({type:n.TokenType.code,meta:O[2],lang:O[3],text:O[4]||""});continue}if(O=this.rules.heading.exec(E)){E=E.substring(O[0].length),this.tokens.push({type:n.TokenType.heading,depth:O[1].length,text:O[2]});continue}if(x&&this.hasRulesTables&&(O=this.rules.nptable.exec(E))){E=E.substring(O[0].length);for(var V={type:n.TokenType.table,header:O[1].replace(/^ *| *\| *$/g,"").split(/ *\| */),align:O[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:[]},J=0;J<V.align.length;J++)/^ *-+: *$/.test(V.align[J])?V.align[J]="right":/^ *:-+: *$/.test(V.align[J])?V.align[J]="center":/^ *:-+ *$/.test(V.align[J])?V.align[J]="left":V.align[J]=null;for(var tt=O[3].replace(/\n$/,"").split(`
`),J=0;J<tt.length;J++)V.cells[J]=tt[J].split(/ *\| */);this.tokens.push(V);continue}if(O=this.rules.lheading.exec(E)){E=E.substring(O[0].length),this.tokens.push({type:n.TokenType.heading,depth:O[2]==="="?1:2,text:O[1]});continue}if(O=this.rules.hr.exec(E)){E=E.substring(O[0].length),this.tokens.push({type:n.TokenType.hr});continue}if(O=this.rules.blockquote.exec(E)){E=E.substring(O[0].length),this.tokens.push({type:n.TokenType.blockquoteStart});var xt=O[0].replace(/^ *> ?/gm,"");this.getTokens(xt),this.tokens.push({type:n.TokenType.blockquoteEnd});continue}if(O=this.rules.list.exec(E)){E=E.substring(O[0].length);var Ht=O[2];this.tokens.push({type:n.TokenType.listStart,ordered:Ht.length>1});for(var xt=O[0].match(this.rules.item),Ot=xt.length,Yt=!1,Xt=void 0,ue=void 0,ke=void 0,J=0;J<Ot;J++){var V=xt[J];Xt=V.length,V=V.replace(/^ *([*+-]|\d+\.) +/,""),V.indexOf(`
`)!==-1&&(Xt-=V.length,V=this.options.pedantic?V.replace(/^ {1,4}/gm,""):V.replace(new RegExp("^ {1,"+Xt+"}","gm"),"")),this.options.smartLists&&J!==Ot-1&&(ue=this.staticThis.getRulesBase().bullet.exec(xt[J+1])[0],Ht!==ue&&!(Ht.length>1&&ue.length>1)&&(E=xt.slice(J+1).join(`
`)+E,J=Ot-1)),ke=Yt||/\n\n(?!\s*$)/.test(V),J!==Ot-1&&(Yt=V.charAt(V.length-1)===`
`,ke||(ke=Yt)),this.tokens.push({type:ke?n.TokenType.looseItemStart:n.TokenType.listItemStart}),this.getTokens(V,!1,R),this.tokens.push({type:n.TokenType.listItemEnd})}this.tokens.push({type:n.TokenType.listEnd});continue}if(O=this.rules.html.exec(E)){E=E.substring(O[0].length);var xe=O[1],Rn=xe==="pre"||xe==="script"||xe==="style";this.tokens.push({type:this.options.sanitize?n.TokenType.paragraph:n.TokenType.html,pre:!this.options.sanitizer&&Rn,text:O[0]});continue}if(x&&(O=this.rules.def.exec(E))){E=E.substring(O[0].length),this.links[O[1].toLowerCase()]={href:O[2],title:O[3]};continue}if(x&&this.hasRulesTables&&(O=this.rules.table.exec(E))){E=E.substring(O[0].length);for(var V={type:n.TokenType.table,header:O[1].replace(/^ *| *\| *$/g,"").split(/ *\| */),align:O[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:[]},J=0;J<V.align.length;J++)/^ *-+: *$/.test(V.align[J])?V.align[J]="right":/^ *:-+: *$/.test(V.align[J])?V.align[J]="center":/^ *:-+ *$/.test(V.align[J])?V.align[J]="left":V.align[J]=null;for(var tt=O[3].replace(/(?: *\| *)?\n$/,"").split(`
`),J=0;J<tt.length;J++)V.cells[J]=tt[J].replace(/^ *\| *| *\| *$/g,"").split(/ *\| */);this.tokens.push(V);continue}if(this.staticThis.simpleRules.length){for(var un=this.staticThis.simpleRules,J=0;J<un.length;J++)if(O=un[J].exec(E)){E=E.substring(O[0].length);var Ln="simpleRule"+(J+1);this.tokens.push({type:Ln,execArr:O});continue t}}if(x&&(O=this.rules.paragraph.exec(E))){E=E.substring(O[0].length),O[1].slice(-1)===`
`?this.tokens.push({type:n.TokenType.paragraph,text:O[1].slice(0,-1)}):this.tokens.push({type:this.tokens.length>0?n.TokenType.paragraph:n.TokenType.text,text:O[1]});continue}if(O=this.rules.text.exec(E)){E=E.substring(O[0].length),this.tokens.push({type:n.TokenType.text,text:O[0]});continue}if(E)throw new Error("Infinite loop on byte: "+E.charCodeAt(0)+(", near text '"+E.slice(0,30)+"...'"))}return{tokens:this.tokens,links:this.links}},k}();Qt.simpleRules=[],Qt.rulesBase=null,Qt.rulesGfm=null,Qt.rulesTables=null,n.BlockLexer=Qt,n.ExtendRegexp=t,n.InlineLexer=Lt,n.Marked=Ut,n.MarkedOptions=c,n.Parser=Bt,n.Renderer=ot,n.escape=a,n.unescape=l,Object.defineProperty(n,"__esModule",{value:!0})})});var ef=Xo(Ei=>{"use strict";var Dy=Ei&&Ei.__extends||function(){var n=function(t,e){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,s){i.__proto__=s}||function(i,s){for(var r in s)s.hasOwnProperty(r)&&(i[r]=s[r])},n(t,e)};return function(t,e){n(t,e);function i(){this.constructor=t}t.prototype=e===null?Object.create(e):(i.prototype=e.prototype,new i)}}();Object.defineProperty(Ei,"__esModule",{value:!0});Ei.Extractor=void 0;var Ua=tf(),Ey=function(n){Dy(t,n);function t(e,i){var s=n.call(this)||this;return s.lowercaseKeys=i??!1,s.reset(e),s}return Object.defineProperty(t.prototype,"tables",{get:function(){return this.extractedTables},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"objects",{get:function(){var e=this;return this.extractedTables.map(function(i){return t.tableToObject(i,e.lowercaseKeys)})},enumerable:!1,configurable:!0}),t.prototype.reset=function(e){e===void 0&&(e="rows"),this.mode=e,this.currentRow=[],this.currentTable=[],this.extractedTables=[]},t.prototype.table=function(e,i){return this.extractedTables.push(this.mode==="rows"?this.currentTable:t.transposeTable(this.currentTable)),this.currentTable=[],n.prototype.table.call(this,e,i)},t.prototype.tablerow=function(e){return this.currentTable.push(this.currentRow),this.currentRow=[],n.prototype.tablerow.call(this,e)},t.prototype.tablecell=function(e,i){return this.currentRow.push(e),n.prototype.tablecell.call(this,e,i)},t.transposeTable=function(e){for(var i=[],s=e.length,r=e[0].length,o=0;o<r;o++){i.push([]);for(var a=0;a<s;a++)i[o].push(e[a][o])}return i},t.tableToObject=function(e,i){var s=e.shift().slice(1),r={};return e.forEach(function(o){var a=o.shift(),l={};o.forEach(function(c,h){l[i?s[h].toLowerCase():s[h]]=c}),r[i?a.toLowerCase():a]=l}),r},t.createExtractor=function(e,i,s){var r=new t(i,s);return Ua.Marked.setOptions({renderer:r}),Ua.Marked.parse(e),r},t.extractObject=function(e,i,s){var r=t.extractAllObjects(e,i,s);return r.length>0?r[0]:null},t.extractAllObjects=function(e,i,s){var r=t.createExtractor(e,i,s);return r.objects},t.extractTable=function(e,i,s){var r=t.extractAllTables(e,i,s);return r.length>0?r[0]:null},t.extractAllTables=function(e,i,s){var r=t.createExtractor(e,i,s);return r.tables},t.extract=function(e,i,s){var r=t.createExtractor(e,i,s);return r.objects.length>0?JSON.stringify(r.objects[0]):null},t.extractAll=function(e,i,s){var r=t.createExtractor(e,i,s);return r.objects.map(function(o){return JSON.stringify(o)})},t}(Ua.Renderer);Ei.Extractor=Ey});fb(exports,{default:()=>Ol});var $e=ze(require("obsidian"));function Ee(){}var qo=function(){let n=0;return function(){return n++}}();function ut(n){return n===null||typeof n=="undefined"}function pt(n){if(Array.isArray&&Array.isArray(n))return!0;let t=Object.prototype.toString.call(n);return t.slice(0,7)==="[object"&&t.slice(-6)==="Array]"}function at(n){return n!==null&&Object.prototype.toString.call(n)==="[object Object]"}var jt=n=>(typeof n=="number"||n instanceof Number)&&isFinite(+n);function me(n,t){return jt(n)?n:t}function nt(n,t){return typeof n=="undefined"?t:n}var Go=(n,t)=>typeof n=="string"&&n.endsWith("%")?parseFloat(n)/100:n/t,Ks=(n,t)=>typeof n=="string"&&n.endsWith("%")?parseFloat(n)/100*t:+n;function wt(n,t,e){if(n&&typeof n.call=="function")return n.apply(e,t)}function Ct(n,t,e,i){let s,r,o;if(pt(n))if(r=n.length,i)for(s=r-1;s>=0;s--)t.call(e,n[s],s);else for(s=0;s<r;s++)t.call(e,n[s],s);else if(at(n))for(o=Object.keys(n),r=o.length,s=0;s<r;s++)t.call(e,n[o[s]],o[s])}function yi(n,t){let e,i,s,r;if(!n||!t||n.length!==t.length)return!1;for(e=0,i=n.length;e<i;++e)if(s=n[e],r=t[e],s.datasetIndex!==r.datasetIndex||s.index!==r.index)return!1;return!0}function Wi(n){if(pt(n))return n.map(Wi);if(at(n)){let t=Object.create(null),e=Object.keys(n),i=e.length,s=0;for(;s<i;++s)t[e[s]]=Wi(n[e[s]]);return t}return n}function Gc(n){return["__proto__","prototype","constructor"].indexOf(n)===-1}function Uc(n,t,e,i){if(!Gc(n))return;let s=t[n],r=e[n];at(s)&&at(r)?Hn(s,r,i):t[n]=Wi(r)}function Hn(n,t,e){let i=pt(t)?t:[t],s=i.length;if(!at(n))return n;e=e||{};let r=e.merger||Uc;for(let o=0;o<s;++o){if(t=i[o],!at(t))continue;let a=Object.keys(t);for(let l=0,c=a.length;l<c;++l)r(a[l],n,t,e)}return n}function Wn(n,t){return Hn(n,t,{merger Line truncated
`)>-1?n.split(`
`):n}function z_(n,t){let{element:e,datasetIndex:i,index:s}=t,r=n.getDatasetMeta(i).controller,{label:o,value:a}=r.getLabelAndValue(s);return{chart:n,label:o,parsed:r.getParsed(s),raw:n.data.datasets[i].data[s],formattedValue:a,dataset:r.getDataset(),dataIndex:s,datasetIndex:i,element:e}}function Ru(n,t){let e=n.chart.ctx,{body:i,footer:s,title:r}=n,{boxWidth:o,boxHeight:a}=t,l=Ft(t.bodyFont),c=Ft(t.titleFont),h=Ft(t.footerFont),f=r.length,g=s.length,p=i.length,m=Vt(t.padding),y=m.height,S=0,M=i.reduce((D,I)=>D+I.before.length+I.lines.length+I.after.length,0);if(M+=n.beforeBody.length+n.afterBody.length,f&&(y+=f*c.lineHeight+(f-1)*t.titleSpacing+t.titleMarginBottom),M){let D=t.displayColors?Math.max(a,l.lineHeight):l.lineHeight;y+=p*D+(M-p)*l.lineHeight+(M-1)*t.bodySpacing}g&&(y+=t.footerMarginTop+g*h.lineHeight+(g-1)*t.footerSpacing);let C=0,F=function(D){S=Math.max(S,e.measureText(D).width+C)};return e.save(),e.font=c.string,Ct(n.title,F),e.font=l.string,Ct(n.beforeBody.concat(n.afterBody),F),C=t.displayColors?o+2+t.boxPadding:0,Ct(i,D=>{Ct(D.before,F),Ct(D.lines,F),Ct(D.after,F)}),C=0,e.font=h.string,Ct(n.footer,F),e.restore(),S+=m.width,{width:S,height:y}}function B_(n,t){let{y:e,height:i}=t;return e<i/2?"top":e>n.height-i/2?"bottom":"center"}function N_(n,t,e,i){let{x:s,width:r}=i,o=e.caretSize+e.caretPadding;if(n==="left"&&s+r+o>t.width||n==="right"&&s-r-o<0)return!0}function H_(n,t,e,i){let{x:s,width:r}=e,{width:o,chartArea:{left:a,right:l}}=n,c="center";return i==="center"?c=s<=(a+l)/2?"left":"right":s<=r/2?c="left":s>=o-r/2&&(c="right"),N_(c,n,t,e)&&(c="center"),c}function Lu(n,t,e){let i=e.yAlign||t.yAlign||B_(n,e);return{xAlign:e.xAlign||t.xAlign||H_(n,t,e,i),yAlign:i}}function W_(n,t){let{x:e,width:i}=n;return t==="right"?e-=i:t==="center"&&(e-=i/2),e}function V_(n,t,e){let{y:i,height:s}=n;return t==="top"?i+=e:t==="bottom"?i-=s+e:i-=s/2,i}function Fu(n,t,e,i){let{caretSize:s,caretPadding:r,cornerRadius:o}=n,{xAlign:a,yAlign:l}=e,c=s+r,{topLeft:h,topRight:f,bottomLeft:g,bottomRight:p}=Le(o),m=W_(t,a),y=V_(t,l,c);return l==="center"?a==="left"?m+=c:a==="right"&&(m-=c):a==="left"?m-=Math.max(h,g)+s:a==="right"&&(m+=Math.max(f,p)+s),{x:Zt(m,0,i.width-t.width),y:Zt(y,0,i.height-t.height)}}function zr(n,t,e){let i=Vt(e.padding);return t==="center"?n.x+n.width/2:t==="right"?n.x+n.width-i.right:n.x+i.left}function Iu(n){return We([],an(n))}function Y_(n,t,e){return Ne(n,{tooltip:t,tooltipItems:e,type:"tooltip"})}function $u(n,t){let e=t&&t.dataset&&t.dataset.tooltip&&t.dataset.tooltip.callbacks;return e?n.override(e):n}var Br=class extends qt{constructor(t){super();this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=t.chart||t._chart,this._chart=this.chart,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){let t=this._cachedAnimations;if(t)return t;let e=this.chart,i=this.options.setContext(this.getContext()),s=i.enabled&&e.options.animation&&i.animations,r=new is(this.chart,s);return s._cacheable&&(this._cachedAnimations=Object.freeze(r)),r}getContext(){return this.$context||(this.$context=Y_(this.chart.getContext(),this,this._tooltipItems))}getTitle(t,e){let{callbacks:i}=e,s=i.beforeTitle.apply(this,[t]),r=i.title.apply(this,[t]),o=i.afterTitle.apply(this,[t]),a=[];return a=We(a,an(s)),a=We(a,an(r)),a=We(a,an(o)),a}getBeforeBody(t,e){return Iu(e.callbacks.beforeBody.apply(this,[t]))}getBody(t,e){let{callbacks:i}=e,s=[];return Ct(t,r=>{let o={before:[],lines:[],after:[]},a=$u(i,r);We(o.before,an(a.beforeLabel.call(this,r))),We(o.lines,a.label.call(this,r)),We(o.after,an(a.afterLabel.call(this,r))),s.push(o)}),s}getAfterBody(t,e){return Iu(e.callbacks.afterBody.apply(this,[t]))}getFooter(t,e){let{callbacks:i}=e,s=i.beforeFooter.apply(this,[t]),r=i.footer.apply(this,[t]),o=i.afterFooter.apply(this,[t]),a=[];return a=We(a,an(s)),a=We(a,an(r)),a=We(a,an(o)),a}_createItems(t){let e=this._active,i=this.chart.data,s=[],r=[],o=[],a=[],l,c;for(l=0,c=e.length;l<c;++l)a.push(z_(this.chart,e[l]));return t.filter&&(a=a.filter((h,f,g)=>t.filter(h,f,g,i))),t.itemSort&&(a=a.sort((h,f)=>t.itemSort(h,f,i))),Ct(a,h=>{let f=$u(t.callbacks,h);s.push(f.labelColor.call(this,h)),r.push(f.labelPointStyle.call(this,h)),o.push(f.labelTextColor.call(this,h))}),this.labelColors=s,this.labelPointStyles=r,this.labelTextColors=o,this.dataPoints=a,a}update(t,e){let i=this.options.setContext(this.getContext()),s=this._active,r,o=[];if(!s.length)this.opacity!==0&&(r={opacity:0});else{let a=ws[i.p Line truncated
`)):Array.isArray(i)?e.push.apply(e,i):ut(e)||t.unshift(""+i)}return t}function Va(n){return!n||["min","max"].indexOf(n)===-1?"max":n}var Tn=n=>n!==void 0;function gy(n,t){let e=new Set(t.map(o=>o.to)),i=new Set(t.map(o=>o.from)),s=new Set([...n.keys()]),r=0;for(;s.size;){let o=my([...s],e);for(let a of o){let l=n.get(a);Tn(l.x)||(l.x=r),s.delete(a)}s.size&&(e.clear(),t.filter(a=>s.has(a.from)).forEach(a=>e.add(a.to)),r++)}return[...n.keys()].filter(o=>!i.has(o)).forEach(o=>{let a=n.get(o);a.column||(a.x=r)}),r}function my(n,t){let e=n.filter(i=>!t.has(i));return e.length?e:n.slice(0,1)}var by=(n,t)=>n.x!==t.x?n.x-t.x:n.y-t.y,Xr=-1;function vy(){return Xr=Xr<100?Xr+1:0,Xr}function Ya(n,t,e=vy()){let i=0;for(let s of n)s.node._visited!==e&&(s.node._visited=e,i+=s.node[t].length+Ya(s.node[t],t,e));return i}var qu=n=>(t,e)=>Ya(t.node[n],n)-Ya(e.node[n],n)||t.node[n].length-e.node[n].length;function Xa(n,t){n.from.sort(qu("from"));for(let e of n.from){let i=e.node;Tn(i.y)||(i.y=t,Xa(i,t)),t=Math.max(i.y+i.out,t)}return t}function ei(n,t){n.to.sort(qu("to"));for(let e of n.to){let i=e.node;Tn(i.y)||(i.y=t,ei(i,t)),t=Math.max(i.y+i.in,t)}return t}function Ms(n,t){return Tn(n.y)?n.y:(n.y=t,t)}function _y(n,t){let e=n.filter(h=>h.x===0),i=n.filter(h=>h.x===t),s=e.filter(h=>!Tn(h.y)),r=i.filter(h=>!Tn(h.y)),o=n.filter(h=>h.x>0&&h.x<t&&!Tn(h.y)),a=e.reduce((h,f)=>Math.max(h,f.y+f.out||0),0),l=i.reduce((h,f)=>Math.max(h,f.y+f.in||0),0),c=0;return a>=l?(s.forEach(h=>{a=Ms(h,a),a=Math.max(a+h.out,ei(h,a))}),r.forEach(h=>{l=Ms(h,l),l=Math.max(l+h.in,ei(h,l))})):(r.forEach(h=>{l=Ms(h,l),l=Math.max(l+h.in,ei(h,l))}),s.forEach(h=>{a=Ms(h,a),a=Math.max(a+h.out,ei(h,a))})),o.forEach(h=>{let f=n.filter(g=>g.x===h.x&&Tn(g.y)).reduce((g,p)=>Math.max(g,p.y+Math.max(p.in,p.out)),0);f=Ms(h,f),f=Math.max(f+h.in,Xa(h,f)),f=Math.max(f+h.out,ei(h,f)),c=Math.max(c,f)}),Math.max(a,l,c)}function yy(n,t){n.sort((o,a)=>Math.max(a.in,a.out)-Math.max(o.in,o.out));let e=n[0];e.y=0;let i=Xa(e,0),s=ei(e,0),r=_y(n,t);return Math.max(i,s,r)}function xy(n,t){let e=0,i=0;for(let s=0;s<=t;s++){let r=i,o=n.filter(a=>a.x===s).sort((a,l)=>a.priority-l.priority);i=o[0].to.filter(a=>a.node.x>s+1).reduce((a,l)=>a+l.flow,0)||0;for(let a of o)a.y=r,r+=Math.max(a.out,a.in);e=Math.max(r,e)}return e}function wy(n,t){let e=1,i=0,s=0,r=0,o=[];n.sort(by);for(let a of n){if(a.y){if(a.x===0)o.push(a.y);else{for(i!==a.x&&(i=a.x,s=0),e=s+1;e<o.length&&!(o[e]>a.y);e++);s=e}a.y+=e*t,e++}r=Math.max(r,a.y+Math.max(a.in,a.out))}return r}function ky(n,t){n.forEach(e=>{let i=Math[t](e.in||e.out,e.out||e.in),s=i<e.in,r=i<e.out,o=0,a=e.from.length;e.from.sort((l,c)=>l.node.y+l.node.out/2-(c.node.y+c.node.out/2)).forEach((l,c)=>{s?l.addY=c*(i-l.flow)/(a-1):(l.addY=o,o+=l.flow)}),o=0,a=e.to.length,e.to.sort((l,c)=>l.node.y+l.node.in/2-(c.node.y+c.node.in/2)).forEach((l,c)=>{r?l.addY=c*(i-l.flow)/(a-1):(l.addY=o,o+=l.flow)})})}function Sy(n,t,e,i){let s=[...n.values()],r=gy(n,t),a=(e?xy(s,r):yy(s,r))*.03,l=wy(s,a);return ky(s,i),{maxX:r,maxY:l}}function My(n){let t=new Map;for(let i=0;i<n.length;i++){let{from:s,to:r,flow:o}=n[i];if(!t.has(s))t.set(s,{key:s,in:0,out:o,from:[],to:[{key:r,flow:o,index:i}]});else{let a=t.get(s);a.out+=o,a.to.push({key:r,flow:o,index:i})}if(!t.has(r))t.set(r,{key:r,in:o,out:0,from:[{key:s,flow:o,index:i}],to:[]});else{let a=t.get(r);a.in+=o,a.from.push({key:s,flow:o,index:i})}}let e=(i,s)=>s.flow-i.flow;return[...t.values()].forEach(i=>{i.from=i.from.sort(e),i.from.forEach(s=>{s.node=t.get(s.key)}),i.to=i.to.sort(e),i.to.forEach(s=>{s.node=t.get(s.key)})}),t}function Gu(n,t,e){for(let i of n)if(i.key===t&&i.index===e)return i.addY;return 0}var Ti=class extends ve{parseObjectData(t,e,i,s){let{from:r="from",to:o="to",flow:a="flow"}=this.options.parsing,l=e.map(({[r]:C,[o]:F,[a]:D})=>({from:C,to:F,flow:D})),{xScale:c,yScale:h}=t,f=[],g=this._nodes=My(l),{column:p,priority:m,size:y}=this.getDataset();if(m)for(let C of g.values())C.key in m&&(C.priority=m[C.key]);if(p)for(let C of g.values())C.key in p&&(C.column=!0,C.x=p[C.key]);let{maxX:S,maxY:M}=Sy(g,l,!!m,Va(y));this._maxX=S,this._maxY=M;for(let C=0,F=l.length;C<F;++C){let D=l[C],I=g.get(D.from),$=g.get(D.to),N=I.y+Gu(I.to,D.to,C),G=$.y+Gu($.from,D.from,C);f.push({x:c.parse(I.x,C),y:h.parse(N,C),_custom:{from:I,to:$,x:c.parse($.x,C),y:h.parse(G,C),height:h.parse(D.flow,C)}})}return f.slice(i,i+s)}getMinMax(t){return{min:0,max:t===this._cachedMeta.xScale?this._maxX:this._maxY}}update(t){let{data:e}=this._cachedMeta;this.updateElements(e,0,e.length,t)}updateElements(t,e,i,s){let{xScale:r,yScale:o}=this._cachedMeta,a=this.resolveDataElementOptions(e,s),l=this.getSharedOptions(s,t[e],a),c=this.getDataset(),h=nt(c.borderWidth,1)/2+.5,f=nt(c.nodeWidth,10);for(let g=e;g<e+i;g++){let p=this.getParsed(g),m=p._custom,y=o.getPixelForValue(p.y);this.updateElement(t[g],g,{x:r.getPixelForValue(p.x)+f+h,y,x2:r.getPixelForValue(m.x)-h,y2:o.getPixelForValue(m.y),from:m.from,to:m.to,progress:s==="reset"?0:1,height:Math Line truncated
type: bar
labels: [${e}]
series:
${i.map(r=>` - title: ${r.dataTitle}
data: [${r.data}]`).join(`
`)}
width: 80%
beginAtZero: true
\`\`\``;n.replaceSelection(s)}function Za(n,t,e){let i;try{i=sf.Extractor.extractObject(n,t,!1)}catch(o){throw new nf.Notice("Table malformed"),o}let s=Object.keys(Object.values(i)[0]),r=Object.keys(i).map(o=>({dataTitle:o,data:Object.values(i[o])}));return e&&(r=r.filter(o=>e.contains(o.dataTitle))),{labels:s,dataFields:r}}var rf={modes:{point(n,t){return Gr(n,t,{intersect:!0})},nearest(n,t,e){return Ry(n,t,e)},x(n,t,e){return Gr(n,t,{intersect:e.intersect,axis:"x"})},y(n,t,e){return Gr(n,t,{intersect:e.intersect,axis:"y"})}}};function Ja(n,t,e){return(rf.modes[e.mode]||rf.modes.nearest)(n,t,e)}function Oy(n,t,e){return e!=="x"&&e!=="y"?n.inRange(t.x,t.y,"x",!0)||n.inRange(t.x,t.y,"y",!0):n.inRange(t.x,t.y,e,!0)}function Ay(n,t,e){return e==="x"?{x:n.x,y:t.y}:e==="y"?{x:t.x,y:n.y}:t}function Gr(n,t,e){return n.visibleElements.filter(i=>e.intersect?i.inRange(t.x,t.y):Oy(i,t,e.axis))}function Ry(n,t,e){let i=Number.POSITIVE_INFINITY;return Gr(n,t,e).reduce((s,r)=>{let o=r.getCenterPoint(),a=Ay(t,o,e.axis),l=Ke(t,a);return l<i?(s=[r],i=l):l===i&&s.push(r),s},[]).sort((s,r)=>s._index-r._index).slice(0,1)}var Ly=(n,t)=>t>n||n.length>t.length&&n.slice(0,t.length)===t,ni=.001,Ur=(n,t,e)=>Math.min(e,Math.max(t,n));function Fy(n,t,e){for(let i of Object.keys(n))n[i]=Ur(n[i],t,e);return n}function Iy(n,t,e,i){if(!n||!t||e<=0)return!1;let s=i/2;return Math.pow(n.x-t.x,2)+Math.pow(n.y-t.y,2)<=Math.pow(e+s,2)}function of(n,{x:t,y:e,x2:i,y2:s},r,o){let a=o/2,l=n.x>=t-a-ni&&n.x<=i+a+ni,c=n.y>=e-a-ni&&n.y<=s+a+ni;return r==="x"?l:(r==="y"||l)&&c}function Oi(n,t){let{centerX:e,centerY:i}=n.getProps(["centerX","centerY"],t);return{x:e,y:i}}function $y(n,t,e,i=!0){let s=e.split("."),r=0;for(let o of t.split(".")){let a=s[r++];if(parseInt(o,10)<parseInt(a,10))break;if(Ly(a,o)){if(i)throw new Error(`${n} v${e} is not supported. v${t} or newer is required.`);return!1}}return!0}var af=n=>typeof n=="string"&&n.endsWith("%"),lf=n=>parseFloat(n)/100,cf=n=>Ur(lf(n),0,1);function Qa(n,t){return t==="start"?0:t==="end"?n:af(t)?cf(t)*n:n/2}function Dn(n,t,e=!0){return typeof t=="number"?t:af(t)?(e?cf(t):lf(t))*n:n}function jy(n,t){let{x:e,width:i}=n,s=t.textAlign;return s==="center"?e+i/2:s==="end"||s==="right"?e+i:e}function tl(n,t="center"){return at(n)?{x:nt(n.x,t),y:nt(n.y,t)}:(n=nt(n,t),{x:n,y:n})}function hf(n){return n&&(Nt(n.xValue)||Nt(n.yValue))}function Ps(n,t,e,i=!1){let s=e.init;if(s){if(s===!0)return ff(t,i)}else return;return zy(t,i,wt(s,[{chart:n,properties:t,options:e}]))}function uf(n,t,e){let i=!1;return t.forEach(s=>{le(n[s])?(i=!0,e[s]=n[s]):Nt(e[s])&&delete e[s]}),i}function ff({centerX:n,centerY:t},e){return e?{centerX:n,centerY:t,radius:0,width:0,height:0}:{x:n,y:t,x2:n,y2:t,width:0,height:0}}function zy(n,t,e){if(e===!0)return ff(n,t);if(at(e))return e}var el=new Map,By=n=>isNaN(n)||n<=0,Ny=n=>n.reduce(function(t,e){return t+=e.string,t},"");function Kr(n){if(n&&typeof n=="object"){let t=n.toString();return t==="[object HTMLImageElement]"||t==="[object HTMLCanvasElement]"}}function nl(n,{x:t,y:e},i){i&&(n.translate(t,e),n.rotate(Wt(i)),n.translate(-t,-e))}function En(n,t){if(t&&t.borderWidth)return n.lineCap=t.borderCapStyle,n.setLineDash(t.borderDash),n.lineDashOffset=t.borderDashOffset,n.lineJoin=t.borderJoinStyle,n.lineWidth=t.borderWidth,n.strokeStyle=t.borderColor,!0}function Ai(n,t){n.shadowColor=t.backgroundShadowColor,n.shadowBlur=t.shadowBlur,n.shadowOffsetX=t.shadowOffsetX,n.shadowOffsetY=t.shadowOffsetY}function il(n,t){let e=t.content;if(Kr(e))return{width:Dn(e.width,t.width),height:Dn(e.height,t.height)};let i=t.font,s=pt(i)?i.map(l=>Ft(l)):[Ft(i)],r=t.textStrokeWidth,o=pt(e)?e:[e],a=o.join()+Ny(s)+r+(n._measureText?"-spriting":"");return el.has(a)||el.set(a,Xy(n,o,s,r)),el.get(a)}function df(n,t,e){let{x:i,y:s,width:r,height:o}=t;n.save(),Ai(n,e);let a=En(n,e);n.fillStyle=e.backgroundColor,n.beginPath(),en(n,{x:i,y:s,w:r,h:o,radius:Fy(Le(e.borderRadius),0,Math.min(r,o)/2)}),n.closePath(),n.fill(),a&&(n.shadowColor=e.borderShadowColor,n.stroke()),n.restore()}function Hy(n,t,e){let i=e.content;if(Kr(i)){n.save(),n.globalAlpha=Uy(e.opacity,i.style.opacity),n.drawImage(i,t.x,t.y,t.width,t.height),n.restore();return}let s=pt(i)?i:[i],r=e.font,o=pt(r)?r.map(f=>Ft(f)):[Ft(r)],a=e.color,l=pt(a)?a:[a],c=jy(t,e),h=t.y+e.textStrokeWidth/2;n.save(),n.textBaseline="middle",n.textAlign=e.textAlign,Wy(n,e)&&qy(n,{x:c,y:h},s,o),Gy(n,{x:c,y:h},s,{fonts:o,colors:l}),n.restore()}function Wy(n,t){if(t.textStrokeWidth>0)return n.lineJoin="round",n.miterLimit=2,n.lineWidth=t.textStrokeWidth,n.strokeStyle=t.textStrokeColor,!0}function Vy(n,t,e,i){let{radius:s,options:r}=t,o=r.pointStyle,a=r.rotation,l=(a||0)*Xi;if(Kr(o)){n.save(),n.translate(e,i),n.rotate(l),n.drawImage(o,-o.width/2,-o.height/2,o.width,o.height),n.restore();return}By(s)||Yy(n,{x:e,y:i,radius:s,rotation:a,style:o,rad:l})}function Yy(n,{x:t,y:e,radius:i,rotation:s,style:r,rad:o}){let a,l,c,h;switch(n.beginPath(),r){default:n.arc(t,e,i,0,kt),n.closePath()Line truncated
linear-gradient(45deg, lightgrey 25%, white 25%, white 75%, lightgrey 75%) 1em 1em / 2em 2em`,i1=360,Yf="keydown",io="mousedown",vl="focusin";function Ve(n,t){return(t||document).querySelector(n)}function Xf(n){n.preventDefault(),n.stopPropagation()}function _l(n,t,e,i,s){n.add(t,Yf,function(r){e.indexOf(r.key)>=0&&(s&&Xf(r),i(r))})}var yl=function(){function n(t){gl(this,n),this.settings={popup:"right",layout:"default",alpha:!0,editor:!0,editorFormat:"hex",cancelButton:!1,defaultColor:"#0cf"},this._events=new t1,this.onChange=null,this.onDone=null,this.onOpen=null,this.onClose=null,this.setOptions(t)}return ml(n,[{key:"setOptions",value:function(e){var i=this;if(!e)return;var s=this.settings;function r(c,h,f){for(var g in c)f&&f.indexOf(g)>=0||(h[g]=c[g])}if(e instanceof HTMLElement)s.parent=e;else{s.parent&&e.parent&&s.parent!==e.parent&&(this._events.remove(s.parent),this._popupInited=!1),r(e,s),e.onChange&&(this.onChange=e.onChange),e.onDone&&(this.onDone=e.onDone),e.onOpen&&(this.onOpen=e.onOpen),e.onClose&&(this.onClose=e.onClose);var o=e.color||e.colour;o&&this._setColor(o)}var a=s.parent;if(a&&s.popup&&!this._popupInited){var l=function(h){return i.openHandler(h)};this._events.add(a,"click",l),_l(this._events,a,[" ","Spacebar","Enter"],l),this._popupInited=!0}else e.parent&&!s.popup&&this.show()}},{key:"openHandler",value:function(e){if(this.show()){e&&e.preventDefault(),this.settings.parent.style.pointerEvents="none";var i=e&&e.type===Yf?this._domEdit:this.domElement;setTimeout(function(){return i.focus()},100),this.onOpen&&this.onOpen(this.colour)}}},{key:"closeHandler",value:function(e){var i=e&&e.type,s=!1;if(!e)s=!0;else if(i===io||i===vl){var r=(this.__containedEvent||0)+100;e.timeStamp>r&&(s=!0)}else Xf(e),s=!0;s&&this.hide()&&(this.settings.parent.style.pointerEvents="",i!==io&&this.settings.parent.focus(),this.onClose&&this.onClose(this.colour))}},{key:"movePopup",value:function(e,i){this.closeHandler(),this.setOptions(e),i&&this.openHandler()}},{key:"setColor",value:function(e,i){this._setColor(e,{silent:i})}},{key:"_setColor",value:function(e,i){if(typeof e=="string"&&(e=e.trim()),!!e){i=i||{};var s=void 0;try{s=new Qx(e)}catch(o){if(i.failSilently)return;throw o}if(!this.settings.alpha){var r=s.hsla;r[3]=1,s.hsla=r}this.colour=this.color=s,this._setHSLA(null,null,null,null,i)}}},{key:"setColour",value:function(e,i){this.setColor(e,i)}},{key:"show",value:function(){var e=this.settings.parent;if(!e)return!1;if(this.domElement){var i=this._toggleDOM(!0);return this._setPosition(),i}var s=this.settings.template||'<div class="picker_wrapper" tabindex="-1"><div class="picker_arrow"></div><div class="picker_hue picker_slider"><div class="picker_selector"></div></div><div class="picker_sl"><div class="picker_selector"></div></div><div class="picker_alpha picker_slider"><div class="picker_selector"></div></div><div class="picker_editor"><input aria-label="Type a color name or hex value"/></div><div class="picker_sample"></div><div class="picker_done"><button>Ok</button></div><div class="picker_cancel"><button>Cancel</button></div></div>',r=e1(s);return this.domElement=r,this._domH=Ve(".picker_hue",r),this._domSL=Ve(".picker_sl",r),this._domA=Ve(".picker_alpha",r),this._domEdit=Ve(".picker_editor input",r),this._domSample=Ve(".picker_sample",r),this._domOkay=Ve(".picker_done button",r),this._domCancel=Ve(".picker_cancel button",r),r.classList.add("layout_"+this.settings.layout),this.settings.alpha||r.classList.add("no_alpha"),this.settings.editor||r.classList.add("no_editor"),this.settings.cancelButton||r.classList.add("no_cancel"),this._ifPopup(function(){return r.classList.add("popup")}),this._setPosition(),this.colour?this._updateUI():this._setColor(this.settings.defaultColor),this._bindEvents(),!0}},{key:"hide",value:function(){return this._toggleDOM(!1)}},{key:"destroy",value:function(){this._events.destroy(),this.domElement&&this.settings.parent.removeChild(this.domElement)}},{key:"_bindEvents",value:function(){var e=this,i=this,s=this.domElement,r=this._events;function o(c,h,f){r.add(c,h,f)}o(s,"click",function(c){return c.preventDefault()}),bl(r,this._domH,function(c,h){return i._setHSLA(c)}),bl(r,this._domSL,function(c,h){return i._setHSLA(null,c,1-h)}),this.settings.alpha&&bl(r,this._domA,function(c,h){return i._setHSLA(null,null,null,1-h)});var a=this._domEdit;o(a,"input",function(c){i._setColor(this.value,{fromEditor:!0,failSilently:!0})}),o(a,"focus",function(c){var h=this;h.selectionStart===h.selectionEnd&&h.select()}),this._ifPopup(function(){var c=function(g){return e.closeHandler(g)};o(window,io,c),o(window,vl,c),_l(r,s,["Esc","Escape"],c);var h=function(g){e.__containedEvent=g.timeStamp};o(s,io,h),o(s,vl,h),o(e._domCancel,"click",c)});var l=function(h){e._ifPopup(function(){return e.closeHandler(h)}),e.onDone&&e.onDone(e.colour)};o(this._domOkay,"click",l),_l(r,s,["Enter"],l)}},{key:"_setPosition",value:function(){var e=this.settings.parent,i=this. Line truncated
<p class="subDesc svelte-1tlkntj">Set Data Fields (Comma seperated)</p>`,i=It(),s=Y("td"),r=Y("input"),o=It(),a=Y("br"),l=It(),c=Y("input"),X(e,"class","desc svelte-1tlkntj"),X(r,"type","text"),X(r,"placeholder","Name"),X(c,"type","text"),X(c,"placeholder","1, -2, 11, 5"),Gt(c,"margin-top","3px"),X(s,"class","controlElement svelte-1tlkntj")},m(m,y){Xe(m,t,y),z(t,e),z(t,i),z(t,s),z(s,r),de(r,n[33].dataTitle),z(s,o),z(s,a),z(s,l),z(s,c),de(c,n[33].data),h||(f=[Jt(r,"input",g),Jt(c,"input",p)],h=!0)},p(m,y){n=m,y[0]&1024&&r.value!==n[33].dataTitle&&de(r,n[33].dataTitle),y[0]&1024&&c.value!==n[33].data&&de(c,n[33].data)},d(m){m&&Ie(t),h=!1,hn(f)}}}function w1(n){let t,e,i,s,r,o,a,l,c,h,f,g,p,m,y,S,M,C,F,D,I;return{c(){t=Y("hr"),e=It(),i=Y("table"),s=Y("tr"),r=Y("td"),r.innerHTML=`<p class="mainDesc svelte-1tlkntj">Line of Best Fit</p>
<p class="subDesc svelte-1tlkntj">Create a line of best fit</p>`,o=Y("td"),a=Y("input"),l=It(),c=Y("tr"),h=Y("td"),h.innerHTML=`<p class="mainDesc svelte-1tlkntj">Best Fit Line ID</p>
<p class="subDesc svelte-1tlkntj">The line ID used to create the line of best fit</p>`,f=Y("td"),g=Y("input"),p=Y("br"),m=It(),y=Y("tr"),S=Y("td"),S.innerHTML=`<p class="mainDesc svelte-1tlkntj">Line of Best Fit Title</p>
<p class="subDesc svelte-1tlkntj">The title for the line of best fit</p>`,M=Y("td"),C=Y("input"),F=Y("br"),X(r,"class","desc svelte-1tlkntj"),X(a,"type","checkbox"),X(a,"class","task-list-item-checkbox"),Gt(a,"width","16px"),Gt(a,"height","16px"),X(o,"class","controlElement svelte-1tlkntj"),X(h,"class","desc svelte-1tlkntj"),X(g,"type","text"),X(g,"placeholder","0"),Gt(g,"width","26px"),Gt(g,"height","32px"),X(f,"class","controlElement svelte-1tlkntj"),X(S,"class","desc svelte-1tlkntj"),X(C,"type","text"),X(C,"placeholder","Line of Best Fit"),Gt(C,"width","96px"),Gt(C,"height","32px"),X(M,"class","controlElement svelte-1tlkntj"),Gt(i,"width","100%"),X(i,"class","svelte-1tlkntj")},m($,N){Xe($,t,N),Xe($,e,N),Xe($,i,N),z(i,s),z(s,r),z(s,o),z(o,a),a.checked=n[6],z(i,l),z(i,c),z(c,h),z(c,f),z(f,g),de(g,n[8]),z(f,p),z(i,m),z(i,y),z(y,S),z(y,M),z(M,C),de(C,n[7]),z(M,F),D||(I=[Jt(a,"change",n[26]),Jt(g,"input",n[27]),Jt(C,"input",n[28])],D=!0)},p($,N){N[0]&64&&(a.checked=$[6]),N[0]&256&&g.value!==$[8]&&de(g,$[8]),N[0]&128&&C.value!==$[7]&&de(C,$[7])},d($){$&&Ie(t),$&&Ie(e),$&&Ie(i),D=!1,hn(I)}}}function k1(n){let t,e,i,s,r,o,a,l,c,h,f,g,p,m,y,S,M,C,F,D,I,$,N,G,U,it,lt,rt,Pt,zt,et,Et,St,re,ye,ot,Lt,Bt,Ut,Qt,k,v,x,R,E,O,Z,V,J,tt,xt,Ht,Ot,Yt,Xt,ue,ke,xe,Rn,un,Ln,je,$i,Fn,oi,$s,ji,ai,qe,In,$n,li,js,fn=n[10],ce=[];for(let bt=0;bt<fn.length;bt+=1)ce[bt]=ud(hd(n,fn,bt));return je=new cd({props:{headerText:"Line of Best Fit (Line chart only)",$$slots:{default:[w1]},$$scope:{ctx:n}}}),{c(){t=Y("div"),e=Y("h3"),e.textContent="Create a new Chart",i=It(),s=Y("div"),r=Y("div"),o=Y("table"),a=Y("tr"),l=Y("td"),l.innerHTML=`<p class="mainDesc svelte-1tlkntj">Chart Type</p>
<p class="subDesc svelte-1tlkntj">Choose a Chart Type</p>`,c=Y("td"),h=Y("select"),f=Y("option"),f.textContent="Bar",g=Y("option"),g.textContent="Line",p=Y("option"),p.textContent="Pie",m=Y("option"),m.textContent="Doughnut",y=Y("option"),y.textContent="Radar",S=Y("option"),S.textContent="Polar Area",M=It(),C=Y("tr"),F=Y("td"),F.innerHTML=`<p class="mainDesc svelte-1tlkntj">Smoothness</p>
<p class="subDesc svelte-1tlkntj">Changes the smoothness of the Chart</p>`,D=Y("td"),I=Y("input"),$=It(),N=Y("tr"),G=Y("td"),G.innerHTML=`<p class="mainDesc svelte-1tlkntj">Width</p>
<p class="subDesc svelte-1tlkntj">Changes the horizontal width</p>`,U=Y("td"),it=Y("input"),lt=It(),rt=Y("tr"),Pt=Y("td"),Pt.innerHTML=`<p class="mainDesc svelte-1tlkntj">Fill</p>
<p class="subDesc svelte-1tlkntj">Fill the underside of the Chart</p>`,zt=Y("td"),et=Y("input"),Et=It(),St=Y("tr"),re=Y("td"),re.innerHTML=`<p class="mainDesc svelte-1tlkntj">Distinct Colors</p>
<p class="subDesc svelte-1tlkntj">Use distinct Colors for each Label</p>`,ye=Y("td"),ot=Y("input"),Lt=It(),Bt=Y("tr"),Ut=Y("td"),Ut.innerHTML=`<p class="mainDesc svelte-1tlkntj">Start at Zero</p>
<p class="subDesc svelte-1tlkntj">Don&#39;t cut the graph at the bottom</p>`,Qt=Y("td"),k=Y("input"),v=It(),x=Y("hr"),R=It(),E=Y("table"),O=Y("tr"),Z=Y("td"),Z.innerHTML=`<p class="mainDesc svelte-1tlkntj">X Axis</p>
<p class="subDesc svelte-1tlkntj">Set Labels (Comma seperated)</p>`,V=It(),J=Y("td"),tt=Y("input"),xt=Y("br"),Ht=It(),Ot=Y("hr"),Yt=It(),Xt=Y("table");for(let bt=0;bt<ce.length;bt+=1)ce[bt].c();ue=It(),ke=Y("div"),xe=Y("button"),xe.textContent="Add more",Rn=It(),un=Y("hr"),Ln=It(),ad(je.$$.fragment),$i=It(),Fn=Y("div"),oi=Y("div"),$s=It(),ji=Y("hr"),ai=It(),qe=Y("div"),In=Y("button"),In.textContent="Insert Chart",X(l,"class","desc svelte-1tlkntj"),f.__value="bar",f.value=f.__value,g.__value="line",g.value=g.__value,p.__value="pie",p.value=p.__value,m.__value="doughnut",m.value=m.__value,y.__value="radar",y.value=y.__value,S.__value="polarArea",S.value=S.__value,X(h,"name","Chart Types"),X(h,"id","chart-types"),X(h,"class","dropdown"),n[0]===void 0&&Ls(()=>n[16].call(h)),X(c,"class","controlElement svelte-1tlkntj"),X(F,"class","desc svelte-1tlkntj"),X(I,"type","range"),X(I,"min","0"),X(I,"max","100"),X(I,"class","slider"),X(D,"class","controlElement svelte-1tlkntj"),X(G,"class","desc svelte-1tlkntj"),X(it,"type","range"),X(it,"min","20"),X(it,"max","100"),X(it,"class","slider"),X(U,"class","controlElement svelte-1tlkntj"),X(Pt,"class","desc svelte-1tlkntj"),X(et,"type","checkbox"),X(et,"class","task-list-item-checkbox"),Gt(et,"width","16px"),Gt(et,"height","16px"),X(zt,"class","controlElement svelte-1tlkntj"),X(re,"class","desc svelte-1tlkntj"),X(ot,"type","checkbox"),X(ot,"class","task-list-item-checkbox"),Gt(ot,"width","16px"),Gt(ot,"height","16px"),X(ye,"class","controlElement svelte-1tlkntj"),X(Ut,"class","desc svelte-1tlkntj"),X(k,"type","checkbox"),X(k,"class","task-list-item-checkbox"),Gt(k,"width","16px"),Gt(k,"height","16px"),X(Qt,"class","controlElement svelte-1tlkntj"),Gt(o,"width","100%"),X(o,"class","svelte-1tlkntj"),X(Z,"class","desc svelte-1tlkntj"),X(tt,"type","text"),X(tt,"placeholder","Monday, Tuesday, ..."),X(J,"class","controlElement svelte-1tlkntj"),Gt(E,"width","100%"),X(E,"class","svelte-1tlkntj"),X(ke,"class","addMoreButtonContainer svelte-1tlkntj"),Gt(Xt,"width","100%"),X(Xt,"class","svelte-1tlkntj"),X(oi,"id","preview"),X(Fn,"class","chartPreview svelte-1tlkntj"),X(s,"class","modalColumn svelte-1tlkntj"),X(t,"class","chart-modal svelte-1tlkntj"),X(In,"class","mod-cta"),Gt(qe,"display","flex"),Gt(qe,"justify-content","center"),Gt(qe,"align-items","center")},m(bt,te){Xe(bt,t,te),z(t,e),z(t,i),z(t,s),z(s,r),z(r,o),z(o,a),z(a,l),z(a,c),z(c,h),z(h,f),z(h,g),z(h,p),z(h,m),z(h,y),z(h,S),Cl(h,n[0]),z(o,M),z(o,C),z(C,F),z(C,D),z(D,I),de(I,n[1]),z(o,$),z(o,N),z(N,G),z(N,U),z(U,it),de(it,n[2]),z(o,lt),z(o,rt),z(rt,Pt),z(rt,zt),z(zt,et),et.checked=n[3],z(o,Et),z(o,St),z(St,re),z(St,ye),z(ye,ot),ot.checked=n[4],z(o,Lt),z(o,Bt),z(Bt,Ut),z(Bt,Qt),z(Qt,k),k.checked=n[5],z(r,v),z(r,x),z(r,R),z(r,E),z(E,O),z(O,Z),z(O,V),z(O,J),z(J,tt),de(tt,n[9]),z(J,xt),z(r,Ht),z(r,Ot),z(r,Yt),z(r,Xt);for(let dn=0;dn<ce.length;dn+=1)ce[dn].m(Xt,null);z(Xt,ue),z(Xt,ke),z(ke,xe),z(r,Rn),z(r,un),z(r,Ln),El(je,r,null),z(s,$i),z(s,Fn),z(Fn,oi),n[29](oi),z(t,$s),z(t,ji),Xe(bt,ai,te),Xe(bt,qe,te),z(qe,In),$n=!0,li||(js=[Jt(h,"change",n[16]),Jt(I,"change",n[17]),Jt(I,"input",n[17]),Jt(it,"change",n[18]),Jt(it,"input",n[18]),Jt(et,"change",n[19]),Jt(ot,"change",n[20]),Jt(k,"change",n[21]),Jt(tt,"input",n[22]),Jt(xe,"click",n[25]),Jt(In,"click",n[12])],li=!0)},p(bt,te){if(te[0]&1&&Cl(h,bt[0]),te[0]&2&&de(I,bt[1]),te[0]&4&&de(it,bt[2]),te[0]&8&&(et.checked=bt[3]),te[0]&16&&(ot.checked=bt[4]),te[0]&32&&(k.checked=bt[5]),te[0]&512&&tt.value!==bt[9]&&de(tt,bt[9]),te[0]&1024){fn=bt[10];let pe;for(pe=0;pe<fn.length;pe+=1){let zs=hd(bt,fn,pe);ce[pe]?ce[pe].p(zs,te):(ce[pe]=ud(zs),ce[pe].c(),ce[pe].m(Xt,ue))}for(;pe<ce.length;pe+=1)ce[pe].d(1);ce.length=fn.length}let dn={};te[0]&448|te[1]&32&&(dn.$$scope={dirty:te,ctx:bt}),je.$set(dn)},i(bt){$n||(Fs(je.$$.fragment,bt),$n=!0)},o(bt){fo(je.$$.fragment,bt),$n=!1},d(bt){bt&&Ie(t),nd(ce,bt),po(je),n[29](null),bt&&Ie(ai),bt&&Ie(qe),li=!1,hn(js)}}}function S1(n,t,e){let{editor:i}=t,{renderer:s}=t,r=Pl(),o="bar",a=null,l=20,c=80,h=!1,f=!1,g=!1,p=!1,m,y="0",S="",M=[{dataTitle:"",data:""}],C,F=null,D=(0,mo.debounce)(async(ot,Lt)=>{var Bt;a&&a.destroy(),(Bt=F.lastElementChild)===null||Bt===void 0||Bt.remove(),a=s.renderRaw(await s.datasetPrep((0,mo.parseYaml)(ot),Lt),Lt)},500,!0);function I(){let ot=i.getDoc(),Lt=ot.getCursor();a.destroy(),ot.replaceRange("```chart\n"+C+"\n```",Lt),r("close")}function $(){o=sd(this),e(0,o)}function N(){l=Ml(this.value),e(1,l)}function G(){c=Ml(this.value),e(2,c)}function U(){h=this.checked,e(3,h)}function it(){f=this.checked,e(4,f)}function lt(){g=this.checked,e(5,g)}function rt(){S=this.value,e(9,S)}function Pt(ot,Lt){ot[Lt].dataTitle=this.value,e(10,M)}function zt(ot,Lt){ot[Lt].data=this.value,e(10,M)}let et=()=>e(10,M=[...M,{data:"",dataTitle:""}]);function Et(){p=this.checked,e(6,p)}function St(){y=this.value,e(8,y)}function re(){m=this.value,e(7,m)}function ye(ot){lo[ot?"unshift":"push"](()=>{F=ot,e(11,F)})}return n.$$set=ot=>{"editor"in ot&&eLine truncated
labels: [${S}]
series:
${M.map(ot=>` - title: ${ot.dataTitle}
data: [${ot.data}]`).join(`
`)}
tension: ${l/100}
width: ${c}%
labelColors: ${f}
fill: ${h}
beginAtZero: ${g}
bestFit: ${p}
bestFitTitle: ${m}
bestFitNumber: ${y}`)}if(n.$$.dirty[0]&34816){t:if(F)try{D(C,F)}catch(ot){cn(ot,F)}}},[o,l,c,h,f,g,p,m,y,S,M,F,I,i,s,C,$,N,G,U,it,lt,rt,Pt,zt,et,Et,St,re,ye]}var fd=class extends Is{constructor(t){super();go(this,t,S1,k1,ro,{editor:13,renderer:14},x1,[-1,-1])}},dd=fd;var bo=class extends pd.Modal{constructor(t,e,i,s){super(t);this.settings=i,this.view=e,this.renderer=s}onOpen(){let{contentEl:t,view:e,settings:i,renderer:s}=this;t.empty(),new dd({target:t,props:{editor:e.editor,renderer:s}}).$on("close",()=>this.close())}onClose(){let{contentEl:t}=this;t.empty()}};var gd=ze(require("obsidian")),md={chart:'<svg xmlns="http://www.w3.org/2000/svg" fill-opacity="0.0" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-pie-chart"><path d="M21.21 15.89A10 10 0 1 1 8 2.83"></path><path d="M22 12A10 10 0 0 0 12 2v10z"></path></svg>'},bd=()=>{Object.keys(md).forEach(n=>{(0,gd.addIcon)(n,md[n])})};var Ol=class extends $e.Plugin{constructor(){super(...arguments);this.postprocessor=async(t,e,i)=>{let s;try{s=await(0,$e.parseYaml)(t.replace(/ /g," "))}catch(a){cn(a,e);return}if(!s.id&&(!s||!s.type||!s.labels||!s.series)){cn("Missing type, labels or series",e);return}if(s.bestFit===!0&&s.type==="line"){if(s.bestFitNumber!=null)var r=s.series[Number(s.bestFitNumber)].data;else var r=s.series[0].data;let a=s.labels,l=0,c=0,h=0,f=0;for(let y=0;y<r.length;++y)l=l+r[y],c=c+a[y],h=h+r[y]*r[y],f=f+r[y]*a[y];let g=(r.length*f-c*l)/(r.length*h-l*l),p=(c-g*l)/r.length,m=[];for(let y=0;y<a.length;++y)m.push((a[y]-p)/g);if(s.bestFitTitle!=null&&s.bestFitTitle!="undefined")var o=String(s.bestFitTitle);else var o="Line of Best Fit";s.series.push({title:o,data:m})}await this.renderer.renderFromYaml(s,e,i)}}async loadSettings(){this.settings=Object.assign({},eo,await this.loadData())}async saveSettings(){await this.saveData(this.settings)}async onload(){console.log("loading plugin: Obsidian Charts"),await this.loadSettings(),bd(),this.renderer=new to(this),window.renderChart=this.renderer.renderRaw,this.addSettingTab(new xl(this.app,this)),this.addCommand({id:"creation-helper",name:"Insert new Chart",checkCallback:t=>{let e=this.app.workspace.activeLeaf;return e.view instanceof $e.MarkdownView?(t||new bo(this.app,e.view,this.settings,this.renderer).open(),!0):!1}}),this.addCommand({id:"chart-from-table-column",name:"Create Chart from Table (Column oriented Layout)",editorCheckCallback:(t,e,i)=>{let s=e.getSelection();return i instanceof $e.MarkdownView&&s.split(`
`).length>=3&&s.split("|").length>=2?(t||Ka(e,"columns"),!0):!1}}),this.addCommand({id:"chart-from-table-row",name:"Create Chart from Table (Row oriented Layout)",editorCheckCallback:(t,e,i)=>i instanceof $e.MarkdownView&&e.getSelection().split(`
`).length>=3&&e.getSelection().split("|").length>=2?(t||Ka(e,"rows"),!0):!1}),this.addCommand({id:"chart-to-svg",name:"Create Image from Chart",editorCheckCallback:(t,e,i)=>i instanceof $e.MarkdownView&&e.getSelection().startsWith("```chart")&&e.getSelection().endsWith("```")?(t||(new $e.Notice("Rendering Chart..."),Ju(e,this.app,this.renderer,i.file,this.settings)),!0):!1}),this.registerMarkdownCodeBlockProcessor("chart",this.postprocessor),this.registerMarkdownCodeBlockProcessor("advanced-chart",async(t,e)=>this.renderer.renderRaw(await JSON.parse(t),e)),this.registerEvent(this.app.workspace.on("editor-menu",(t,e,i)=>{i&&this.settings.contextMenu&&t.addItem(s=>{s.setTitle("Insert Chart").setIcon("chart").onClick(r=>{new bo(this.app,i,this.settings,this.renderer).open()})})}))}onunload(){console.log("unloading plugin: Obsidian Charts")}};
/*
* @license
*
* Copyright (c) 2011-2014, Christopher Jeffrey. (MIT Licensed)
* https://github.com/chjj/marked
*
* Copyright (c) 2018-2021, Костя Третяк. (MIT Licensed)
* https://github.com/ts-stack/markdown
*/
/*!
* chartjs-adapter-moment v1.0.0
* https://www.chartjs.org
* (c) 2021 chartjs-adapter-moment Contributors
* Released under the MIT license
*/
/*!
* @kurkle/color v0.2.1
* https://github.com/kurkle/color#readme
* (c) 2022 Jukka Kurkela
* Released under the MIT License
*/
/*!
* Chart.js v3.9.1
* https://www.chartjs.org
* (c) 2022 Chart.js Contributors
* Released under the MIT License
*/
/*!
* chartjs-chart-sankey v0.12.0
* https://github.com/kurkle/chartjs-chart-sankey#readme
* (c) 2022 Jukka Kurkela
* Released under the MIT license
*/
/*!
* vanilla-picker v2.12.1
* https://vanilla-picker.js.org
*
* Copyright 2017-2021 Andreas Borgen (https://github.com/Sphinxxxx), Adam Brooks (https://github.com/dissimulate)
* Released under the ISC license.
*/
/*!
* chartjs-plugin-annotation v2.2.1
* https://www.chartjs.org/chartjs-plugin-annotation/index
* (c) 2023 chartjs-plugin-annotation Contributors
* Released under the MIT License
*/
/*! *****************************************************************************
Copyright (c) Microsoft Corporation.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */
/**
* @license
*
* Copyright (c) 2011-2014, Christopher Jeffrey. (MIT Licensed)
* https://github.com/chjj/marked
*
* Copyright (c) 2018-2021, Костя Третяк. (MIT Licensed)
* https://github.com/ts-stack/markdown
*/
/**
* @license
*
* Copyright (c) 2018-2021, Костя Третяк. (MIT Licensed)
* https://github.com/ts-stack/markdown
*/
/**
* chroma.js - JavaScript library for color conversions
*
* Copyright (c) 2011-2019, Gregor Aisch
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice, this
* list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. The name Gregor Aisch may not be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL GREGOR AISCH OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
* OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
* EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* -------------------------------------------------------
*
* chroma.js includes colors from colorbrewer2.org, which are released under
* the following license:
*
* Copyright (c) 2002 Cynthia Brewer, Mark Harrower,
* and The Pennsylvania State University.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
* either express or implied. See the License for the specific
* language governing permissions and limitations under the License.
*
* ------------------------------------------------------
*
* Named colors are taken from X11 Color Names.
* http://www.w3.org/TR/css3-color/#svg-color
*
* @preserve
*/
+11
View File
@@ -0,0 +1,11 @@
{
"id": "obsidian-charts",
"name": "Obsidian Charts",
"version": "3.8.2",
"minAppVersion": "0.12.7",
"description": "This Plugin lets you create Charts within Obsidian",
"author": "phibr0",
"authorUrl": "https://github.com/phibr0",
"isDesktopOnly": false,
"fundingUrl": "https://ko-fi.com/phibr0"
}
+30
View File
@@ -0,0 +1,30 @@
.picker_wrapper.popup,
.picker_wrapper.popup .picker_arrow::before,
.picker_wrapper.popup .picker_arrow::after,
.picker_editor > input {
background-color: var(--background-primary);
}
.picker_editor > input {
color: var(--text-normal);
}
div.chart-error {
padding: 1rem;
border-radius: 1rem;
background-color: var(--background-secondary);
}
div.chart-error pre > code {
color: crimson !important;
}
.print .block-language-chart {
/* Hardcoded with for printed Charts, see #41 */
width: 500px !important;
}
a[href="https://ko-fi.com/phibr0"] > img
{
height: 3em;
}
+729
View File
@@ -0,0 +1,729 @@
{
"folder": "Excalidraw",
"embedUseExcalidrawFolder": false,
"templateFilePath": "Excalidraw/Template.excalidraw",
"scriptFolderPath": "Excalidraw/Scripts",
"compress": false,
"autosave": true,
"autosaveInterval": 15000,
"autosaveIntervalDesktop": 15000,
"autosaveIntervalMobile": 10000,
"drawingFilenamePrefix": "Drawing ",
"drawingEmbedPrefixWithFilename": true,
"drawingFilnameEmbedPostfix": " ",
"drawingFilenameDateTime": "YYYY-MM-DD HH.mm.ss",
"useExcalidrawExtension": true,
"displaySVGInPreview": true,
"previewImageType": "SVGIMG",
"allowImageCache": true,
"displayExportedImageIfAvailable": false,
"previewMatchObsidianTheme": false,
"width": "400",
"dynamicStyling": "colorful",
"isLeftHanded": false,
"iframeMatchExcalidrawTheme": true,
"matchTheme": false,
"matchThemeAlways": false,
"matchThemeTrigger": false,
"defaultMode": "normal",
"defaultPenMode": "never",
"allowPinchZoom": false,
"allowWheelZoom": false,
"zoomToFitOnOpen": true,
"zoomToFitOnResize": true,
"zoomToFitMaxLevel": 2,
"linkPrefix": "📍",
"urlPrefix": "🌐",
"parseTODO": false,
"todo": "☐",
"done": "🗹",
"hoverPreviewWithoutCTRL": false,
"linkOpacity": 1,
"openInAdjacentPane": false,
"openInMainWorkspace": true,
"showLinkBrackets": true,
"allowCtrlClick": true,
"forceWrap": false,
"pageTransclusionCharLimit": 200,
"wordWrappingDefault": 0,
"removeTransclusionQuoteSigns": true,
"iframelyAllowed": true,
"pngExportScale": 1,
"exportWithTheme": true,
"exportWithBackground": true,
"exportPaddingSVG": 10,
"keepInSync": false,
"autoexportSVG": false,
"autoexportPNG": false,
"autoExportLightAndDark": false,
"autoexportExcalidraw": false,
"embedType": "excalidraw",
"embedMarkdownCommentLinks": true,
"embedWikiLink": true,
"syncExcalidraw": false,
"experimentalFileType": false,
"experimentalFileTag": "✏️",
"experimentalLivePreview": true,
"experimentalEnableFourthFont": false,
"experimantalFourthFont": "Virgil",
"fieldSuggester": true,
"compatibilityMode": false,
"drawingOpenCount": 0,
"library": "deprecated",
"library2": {
"type": "excalidrawlib",
"version": 2,
"source": "https://github.com/zsviczian/obsidian-excalidraw-plugin/releases/tag/2.0.13",
"libraryItems": []
},
"imageElementNotice": true,
"mdSVGwidth": 500,
"mdSVGmaxHeight": 800,
"mdFont": "Virgil",
"mdFontColor": "Black",
"mdBorderColor": "Black",
"mdCSS": "",
"scriptEngineSettings": {},
"defaultTrayMode": false,
"previousRelease": "2.0.13",
"showReleaseNotes": true,
"showNewVersionNotification": true,
"latexBoilerplate": "\\color{blue}",
"taskboneEnabled": false,
"taskboneAPIkey": "",
"pinnedScripts": [],
"customPens": [
{
"type": "default",
"freedrawOnly": false,
"strokeColor": "#000000",
"backgroundColor": "transparent",
"fillStyle": "hachure",
"strokeWidth": 0,
"roughness": 0,
"penOptions": {
"highlighter": false,
"constantPressure": false,
"hasOutline": false,
"outlineWidth": 1,
"options": {
"thinning": 0.6,
"smoothing": 0.5,
"streamline": 0.5,
"easing": "easeOutSine",
"start": {
"cap": true,
"taper": 0,
"easing": "linear"
},
"end": {
"cap": true,
"taper": 0,
"easing": "linear"
}
}
}
},
{
"type": "highlighter",
"freedrawOnly": true,
"strokeColor": "#FFC47C",
"backgroundColor": "#FFC47C",
"fillStyle": "solid",
"strokeWidth": 2,
"roughness": null,
"penOptions": {
"highlighter": true,
"constantPressure": true,
"hasOutline": true,
"outlineWidth": 4,
"options": {
"thinning": 1,
"smoothing": 0.5,
"streamline": 0.5,
"easing": "linear",
"start": {
"taper": 0,
"cap": true,
"easing": "linear"
},
"end": {
"taper": 0,
"cap": true,
"easing": "linear"
}
}
}
},
{
"type": "finetip",
"freedrawOnly": false,
"strokeColor": "#3E6F8D",
"backgroundColor": "transparent",
"fillStyle": "hachure",
"strokeWidth": 0.5,
"roughness": 0,
"penOptions": {
"highlighter": false,
"hasOutline": false,
"outlineWidth": 1,
"constantPressure": true,
"options": {
"smoothing": 0.4,
"thinning": -0.5,
"streamline": 0.4,
"easing": "linear",
"start": {
"taper": 5,
"cap": false,
"easing": "linear"
},
"end": {
"taper": 5,
"cap": false,
"easing": "linear"
}
}
}
},
{
"type": "fountain",
"freedrawOnly": false,
"strokeColor": "#000000",
"backgroundColor": "transparent",
"fillStyle": "hachure",
"strokeWidth": 2,
"roughness": 0,
"penOptions": {
"highlighter": false,
"constantPressure": false,
"hasOutline": false,
"outlineWidth": 1,
"options": {
"smoothing": 0.2,
"thinning": 0.6,
"streamline": 0.2,
"easing": "easeInOutSine",
"start": {
"taper": 150,
"cap": true,
"easing": "linear"
},
"end": {
"taper": 1,
"cap": true,
"easing": "linear"
}
}
}
},
{
"type": "marker",
"freedrawOnly": true,
"strokeColor": "#B83E3E",
"backgroundColor": "#FF7C7C",
"fillStyle": "dashed",
"strokeWidth": 2,
"roughness": 3,
"penOptions": {
"highlighter": false,
"constantPressure": true,
"hasOutline": true,
"outlineWidth": 4,
"options": {
"thinning": 1,
"smoothing": 0.5,
"streamline": 0.5,
"easing": "linear",
"start": {
"taper": 0,
"cap": true,
"easing": "linear"
},
"end": {
"taper": 0,
"cap": true,
"easing": "linear"
}
}
}
},
{
"type": "thick-thin",
"freedrawOnly": true,
"strokeColor": "#CECDCC",
"backgroundColor": "transparent",
"fillStyle": "hachure",
"strokeWidth": 0,
"roughness": null,
"penOptions": {
"highlighter": true,
"constantPressure": true,
"hasOutline": false,
"outlineWidth": 1,
"options": {
"thinning": 1,
"smoothing": 0.5,
"streamline": 0.5,
"easing": "linear",
"start": {
"taper": 0,
"cap": true,
"easing": "linear"
},
"end": {
"cap": true,
"taper": true,
"easing": "linear"
}
}
}
},
{
"type": "thin-thick-thin",
"freedrawOnly": true,
"strokeColor": "#CECDCC",
"backgroundColor": "transparent",
"fillStyle": "hachure",
"strokeWidth": 0,
"roughness": null,
"penOptions": {
"highlighter": true,
"constantPressure": true,
"hasOutline": false,
"outlineWidth": 1,
"options": {
"thinning": 1,
"smoothing": 0.5,
"streamline": 0.5,
"easing": "linear",
"start": {
"cap": true,
"taper": true,
"easing": "linear"
},
"end": {
"cap": true,
"taper": true,
"easing": "linear"
}
}
}
},
{
"type": "default",
"freedrawOnly": false,
"strokeColor": "#000000",
"backgroundColor": "transparent",
"fillStyle": "hachure",
"strokeWidth": 0,
"roughness": 0,
"penOptions": {
"highlighter": false,
"constantPressure": false,
"hasOutline": false,
"outlineWidth": 1,
"options": {
"thinning": 0.6,
"smoothing": 0.5,
"streamline": 0.5,
"easing": "easeOutSine",
"start": {
"cap": true,
"taper": 0,
"easing": "linear"
},
"end": {
"cap": true,
"taper": 0,
"easing": "linear"
}
}
}
},
{
"type": "default",
"freedrawOnly": false,
"strokeColor": "#000000",
"backgroundColor": "transparent",
"fillStyle": "hachure",
"strokeWidth": 0,
"roughness": 0,
"penOptions": {
"highlighter": false,
"constantPressure": false,
"hasOutline": false,
"outlineWidth": 1,
"options": {
"thinning": 0.6,
"smoothing": 0.5,
"streamline": 0.5,
"easing": "easeOutSine",
"start": {
"cap": true,
"taper": 0,
"easing": "linear"
},
"end": {
"cap": true,
"taper": 0,
"easing": "linear"
}
}
}
},
{
"type": "default",
"freedrawOnly": false,
"strokeColor": "#000000",
"backgroundColor": "transparent",
"fillStyle": "hachure",
"strokeWidth": 0,
"roughness": 0,
"penOptions": {
"highlighter": false,
"constantPressure": false,
"hasOutline": false,
"outlineWidth": 1,
"options": {
"thinning": 0.6,
"smoothing": 0.5,
"streamline": 0.5,
"easing": "easeOutSine",
"start": {
"cap": true,
"taper": 0,
"easing": "linear"
},
"end": {
"cap": true,
"taper": 0,
"easing": "linear"
}
}
}
}
],
"numberOfCustomPens": 0,
"pdfScale": 4,
"pdfBorderBox": true,
"pdfGapSize": 20,
"pdfGroupPages": false,
"pdfLockAfterImport": true,
"pdfNumColumns": 1,
"pdfNumRows": 1,
"pdfDirection": "right",
"pdfImportScale": 0.3,
"laserSettings": {
"DECAY_LENGTH": 50,
"DECAY_TIME": 1000,
"COLOR": "#ff0000"
},
"embeddableMarkdownDefaults": {
"useObsidianDefaults": false,
"backgroundMatchCanvas": false,
"backgroundMatchElement": true,
"backgroundColor": "#fff",
"backgroundOpacity": 60,
"borderMatchElement": true,
"borderColor": "#fff",
"borderOpacity": 0,
"filenameVisible": false
},
"canvasImmersiveEmbed": true,
"startupScriptPath": "",
"openAIAPIToken": "",
"openAIDefaultTextModel": "gpt-3.5-turbo-1106",
"openAIDefaultVisionModel": "gpt-4-vision-preview",
"openAIDefaultImageGenerationModel": "dall-e-3",
"openAIURL": "https://api.openai.com/v1/chat/completions",
"openAIImageGenerationURL": "https://api.openai.com/v1/images/generations",
"openAIImageEditsURL": "https://api.openai.com/v1/images/edits",
"openAIImageVariationURL": "https://api.openai.com/v1/images/variations",
"modifierKeyConfig": {
"Mac": {
"LocalFileDragAction": {
"defaultAction": "image-import",
"rules": [
{
"shift": false,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "image-import"
},
{
"shift": true,
"ctrl_cmd": false,
"alt_opt": true,
"meta_ctrl": false,
"result": "link"
},
{
"shift": true,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "image-url"
},
{
"shift": false,
"ctrl_cmd": false,
"alt_opt": true,
"meta_ctrl": false,
"result": "embeddable"
}
]
},
"WebBrowserDragAction": {
"defaultAction": "image-url",
"rules": [
{
"shift": false,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "image-url"
},
{
"shift": true,
"ctrl_cmd": false,
"alt_opt": true,
"meta_ctrl": false,
"result": "link"
},
{
"shift": false,
"ctrl_cmd": false,
"alt_opt": true,
"meta_ctrl": false,
"result": "embeddable"
},
{
"shift": true,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "image-import"
}
]
},
"InternalDragAction": {
"defaultAction": "link",
"rules": [
{
"shift": false,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "link"
},
{
"shift": false,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": true,
"result": "embeddable"
},
{
"shift": true,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "image"
},
{
"shift": true,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": true,
"result": "image-fullsize"
}
]
},
"LinkClickAction": {
"defaultAction": "new-tab",
"rules": [
{
"shift": false,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "active-pane"
},
{
"shift": false,
"ctrl_cmd": true,
"alt_opt": false,
"meta_ctrl": false,
"result": "new-tab"
},
{
"shift": false,
"ctrl_cmd": true,
"alt_opt": true,
"meta_ctrl": false,
"result": "new-pane"
},
{
"shift": true,
"ctrl_cmd": true,
"alt_opt": true,
"meta_ctrl": false,
"result": "popout-window"
},
{
"shift": false,
"ctrl_cmd": true,
"alt_opt": false,
"meta_ctrl": true,
"result": "md-properties"
}
]
}
},
"Win": {
"LocalFileDragAction": {
"defaultAction": "image-import",
"rules": [
{
"shift": false,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "image-import"
},
{
"shift": false,
"ctrl_cmd": true,
"alt_opt": false,
"meta_ctrl": false,
"result": "link"
},
{
"shift": true,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "image-url"
},
{
"shift": true,
"ctrl_cmd": true,
"alt_opt": false,
"meta_ctrl": false,
"result": "embeddable"
}
]
},
"WebBrowserDragAction": {
"defaultAction": "image-url",
"rules": [
{
"shift": false,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "image-url"
},
{
"shift": false,
"ctrl_cmd": true,
"alt_opt": false,
"meta_ctrl": false,
"result": "link"
},
{
"shift": true,
"ctrl_cmd": true,
"alt_opt": false,
"meta_ctrl": false,
"result": "embeddable"
},
{
"shift": true,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "image-import"
}
]
},
"InternalDragAction": {
"defaultAction": "link",
"rules": [
{
"shift": false,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "link"
},
{
"shift": true,
"ctrl_cmd": true,
"alt_opt": false,
"meta_ctrl": false,
"result": "embeddable"
},
{
"shift": true,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "image"
},
{
"shift": false,
"ctrl_cmd": true,
"alt_opt": true,
"meta_ctrl": false,
"result": "image-fullsize"
}
]
},
"LinkClickAction": {
"defaultAction": "new-tab",
"rules": [
{
"shift": false,
"ctrl_cmd": false,
"alt_opt": false,
"meta_ctrl": false,
"result": "active-pane"
},
{
"shift": false,
"ctrl_cmd": true,
"alt_opt": false,
"meta_ctrl": false,
"result": "new-tab"
},
{
"shift": false,
"ctrl_cmd": true,
"alt_opt": true,
"meta_ctrl": false,
"result": "new-pane"
},
{
"shift": true,
"ctrl_cmd": true,
"alt_opt": true,
"meta_ctrl": false,
"result": "popout-window"
},
{
"shift": false,
"ctrl_cmd": true,
"alt_opt": false,
"meta_ctrl": true,
"result": "md-properties"
}
]
}
}
},
"slidingPanesSupport": false,
"mathjaxSourceURL": "https://cdn.jsdelivr.net/npm/mathjax@3.2.1/es5/tex-svg.js"
}
+96
View File
@@ -0,0 +1,96 @@
"use strict";var obsidian_module=require("obsidian");var LZString=function(){var r=String.fromCharCode,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$",e={};function t(r,o){if(!e[r]){e[r]={};for(var n=0;n<r.length;n++)e[r][r.charAt(n)]=n}return e[r][o]}var i={compressToBase64:function(r){if(null==r)return"";var n=i._compress(r,6,function(r){return o.charAt(r)});switch(n.length%4){default:case 0:return n;case 1:return n+"===";case 2:return n+"==";case 3:return n+"="}},decompressFromBase64:function(r){return null==r?"":""==r?null:i._decompress(r.length,32,function(n){return t(o,r.charAt(n))})},compressToUTF16:function(o){return null==o?"":i._compress(o,15,function(o){return r(o+32)})+" "},decompressFromUTF16:function(r){return null==r?"":""==r?null:i._decompress(r.length,16384,function(o){return r.charCodeAt(o)-32})},compressToUint8Array:function(r){for(var o=i.compress(r),n=new Uint8Array(2*o.length),e=0,t=o.length;e<t;e++){var s=o.charCodeAt(e);n[2*e]=s>>>8,n[2*e+1]=s%256}return n},decompressFromUint8Array:function(o){if(null==o)return i.decompress(o);for(var n=new Array(o.length/2),e=0,t=n.length;e<t;e++)n[e]=256*o[2*e]+o[2*e+1];var s=[];return n.forEach(function(o){s.push(r(o))}),i.decompress(s.join(""))},compressToEncodedURIComponent:function(r){return null==r?"":i._compress(r,6,function(r){return n.charAt(r)})},decompressFromEncodedURIComponent:function(r){return null==r?"":""==r?null:(r=r.replace(/ /g,"+"),i._decompress(r.length,32,function(o){return t(n,r.charAt(o))}))},compress:function(o){return i._compress(o,16,function(o){return r(o)})},_compress:function(r,o,n){if(null==r)return"";var e,t,i,s={},u={},a="",p="",c="",l=2,f=3,h=2,d=[],m=0,v=0;for(i=0;i<r.length;i+=1)if(a=r.charAt(i),Object.prototype.hasOwnProperty.call(s,a)||(s[a]=f++,u[a]=!0),p=c+a,Object.prototype.hasOwnProperty.call(s,p))c=p;else{if(Object.prototype.hasOwnProperty.call(u,c)){if(c.charCodeAt(0)<256){for(e=0;e<h;e++)m<<=1,v==o-1?(v=0,d.push(n(m)),m=0):v++;for(t=c.charCodeAt(0),e=0;e<8;e++)m=m<<1|1&t,v==o-1?(v=0,d.push(n(m)),m=0):v++,t>>=1}else{for(t=1,e=0;e<h;e++)m=m<<1|t,v==o-1?(v=0,d.push(n(m)),m=0):v++,t=0;for(t=c.charCodeAt(0),e=0;e<16;e++)m=m<<1|1&t,v==o-1?(v=0,d.push(n(m)),m=0):v++,t>>=1}0==--l&&(l=Math.pow(2,h),h++),delete u[c]}else for(t=s[c],e=0;e<h;e++)m=m<<1|1&t,v==o-1?(v=0,d.push(n(m)),m=0):v++,t>>=1;0==--l&&(l=Math.pow(2,h),h++),s[p]=f++,c=String(a)}if(""!==c){if(Object.prototype.hasOwnProperty.call(u,c)){if(c.charCodeAt(0)<256){for(e=0;e<h;e++)m<<=1,v==o-1?(v=0,d.push(n(m)),m=0):v++;for(t=c.charCodeAt(0),e=0;e<8;e++)m=m<<1|1&t,v==o-1?(v=0,d.push(n(m)),m=0):v++,t>>=1}else{for(t=1,e=0;e<h;e++)m=m<<1|t,v==o-1?(v=0,d.push(n(m)),m=0):v++,t=0;for(t=c.charCodeAt(0),e=0;e<16;e++)m=m<<1|1&t,v==o-1?(v=0,d.push(n(m)),m=0):v++,t>>=1}0==--l&&(l=Math.pow(2,h),h++),delete u[c]}else for(t=s[c],e=0;e<h;e++)m=m<<1|1&t,v==o-1?(v=0,d.push(n(m)),m=0):v++,t>>=1;0==--l&&(l=Math.pow(2,h),h++)}for(t=2,e=0;e<h;e++)m=m<<1|1&t,v==o-1?(v=0,d.push(n(m)),m=0):v++,t>>=1;for(;;){if(m<<=1,v==o-1){d.push(n(m));break}v++}return d.join("")},decompress:function(r){return null==r?"":""==r?null:i._decompress(r.length,32768,function(o){return r.charCodeAt(o)})},_decompress:function(o,n,e){var t,i,s,u,a,p,c,l=[],f=4,h=4,d=3,m="",v=[],g={val:e(0),position:n,index:1};for(t=0;t<3;t+=1)l[t]=t;for(s=0,a=Math.pow(2,2),p=1;p!=a;)u=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=e(g.index++)),s|=(u>0?1:0)*p,p<<=1;switch(s){case 0:for(s=0,a=Math.pow(2,8),p=1;p!=a;)u=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=e(g.index++)),s|=(u>0?1:0)*p,p<<=1;c=r(s);break;case 1:for(s=0,a=Math.pow(2,16),p=1;p!=a;)u=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=e(g.index++)),s|=(u>0?1:0)*p,p<<=1;c=r(s);break;case 2:return""}for(l[3]=c,i=c,v.push(c);;){if(g.index>o)return"";for(s=0,a=Math.pow(2,d),p=1;p!=a;)u=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=e(g.index++)),s|=(u>0?1:0)*p,p<<=1;switch(c=s){case 0:for(s=0,a=Math.pow(2,8),p=1;p!=a;)u=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=e(g.index++)),s|=(u>0?1:0)*p,p<<=1;l[h++]=r(s),c=h-1,f--;break;case 1:for(s=0,a=Math.pow(2,16),p=1;p!=a;)u=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=e(g.index++)),s|=(u>0?1:0)*p,p<<=1;l[h++]=r(s),c=h-1,f--;break;case 2:return v.join("")}if(0==f&&(f=Math.pow(2,d),d++),l[c])m=l[c];else{if(c!==h)return null;m=i+i.charAt(0)}v.push(m),l[h++]=i+m.charAt(0),i=m,0==--f&&(f=Math.pow(2,d),d++)}}};return i}();"function"==typeof define&&define.amd?define(function(){return LZString}):"undefined"!=typeof module&&null!=module?module.exports=LZString:"undefined"!=typeof angular&&null!=angular&&angular.module("LZString",[]).factory("LZString",function(){return LZString});const EXCALIDRAW_PACKAGES = "PQKhCgAIUgBAbAlgYwKYDsDOrICVUCGyALlDAE6EkB0ADuQPYAmAriYg+tQLaJcBWmMmUgBhBrQCe5RAHMAFsUgAKZAEpIAMSKoARgwLine truncated
/*!
*************************************************************************
*
* mhchemParser.ts
* 4.2.1
*
* Parser for the \ce command and \pu command for MathJax and Co.
*
* mhchem's \ce is a tool for writing beautiful chemical equations easily.
* mhchem's \pu is a tool for writing physical units easily.
*
* ----------------------------------------------------------------------
*
* Copyright (c) 2015-2023 Martin Hensel
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
* ----------------------------------------------------------------------
*
* https://github.com/mhchem/mhchemParser
*
*/
Object.defineProperty(mhchemParser$1,"__esModule",{value:!0}),mhchemParser$1.mhchemParser=void 0;var mhchemParser=function(){function e(){}return e.toTex=function(e,t){return _mhchemTexify.go(_mhchemParser.go(e,t),"tex"!==t)},e}();function _mhchemCreateTransitions(e){var t,n,r={};for(t in e)for(n in e[t]){var i=n.split("|");e[t][n].stateArray=i;for(var o=0;o<i.length;o++)r[i[o]]=[]}for(t in e)for(n in e[t])for(i=e[t][n].stateArray||[],o=0;o<i.length;o++){var a=e[t][n];a.action_=[].concat(a.action_);for(var s=0;s<a.action_.length;s++)"string"==typeof a.action_[s]&&(a.action_[s]={type_:a.action_[s]});for(var l=t.split("|"),c=0;c<l.length;c++)if("*"===i[o]){var T=void 0;for(T in r)r[T].push({pattern:l[c],task:a})}else r[i[o]].push({pattern:l[c],task:a})}return r}mhchemParser$1.mhchemParser=mhchemParser;var _mhchemParser={go:function(e,t){if(!e)return[];void 0===t&&(t="ce");var n,r="0",i={parenthesisLevel:0};e=(e=(e=e.replace(/\n/g," ")).replace(/[\u2212\u2013\u2014\u2010]/g,"-")).replace(/[\u2026]/g,"...");for(var o=10,a=[];;){n!==e?(o=10,n=e):o--;var s=_mhchemParser.stateMachines[t],l=s.transitions[r]||s.transitions["*"];e:for(var c=0;c<l.length;c++){var T=_mhchemParser.patterns.match_(l[c].pattern,e);if(T){for(var Q=l[c].task,d=0;d<Q.action_.length;d++){var u=void 0;if(s.actions[Q.action_[d].type_])u=s.actions[Q.action_[d].type_](i,T.match_,Q.action_[d].option);else{if(!_mhchemParser.actions[Q.action_[d].type_])throw["MhchemBugA","mhchem bug A. Please report. ("+Q.action_[d].type_+")"];u=_mhchemParser.actions[Q.action_[d].type_](i,T.match_,Q.action_[d].option)}_mhchemParser.concatArray(a,u)}if(r=Q.nextState||r,!(e.length>0))return a;if(Q.revisit||(e=T.remainder),!Q.toContinue)break e}}if(o<=0)throw["MhchemBugU","mhchem bug U. Please report."]}},concatArray:function(e,t){if(t)if(Array.isArray(t))for(var n=0;n<t.length;n++)e.push(t[n]);else e.push(t)},patterns:{patterns:{empty:/^$/,else:/^./,else2:/^./,space:/^\s/,"space A":/^\s(?=[A-Z\\$])/,space$:/^\s$/,"a-z":/^[a-z]/,x:/^x/,x$:/^x$/,i$:/^i$/,letters:/^(?:[a-zA-Z\u03B1-\u03C9\u0391-\u03A9?@]|(?:\\(?:alpha|beta|gamma|delta|epsilon|zeta|eta|theta|iota|kappa|lambda|mu|nu|xi|omicron|pi|rho|sigma|tau|upsilon|phi|chi|psi|omega|Gamma|Delta|Theta|Lambda|Xi|Pi|Sigma|Upsilon|Phi|Psi|Omega)(?:\s+|\{\}|(?![a-zA-Z]))))+/,"\\greek":/^\\(?:alpha|beta|gamma|delta|epsilon|zeta|eta|theta|iota|kappa|lambda|mu|nu|xi|omicron|pi|rho|sigma|tau|upsilon|phi|chi|psi|omega|Gamma|Delta|Theta|Lambda|Xi|Pi|Sigma|Upsilon|Phi|Psi|Omega)(?:\s+|\{\}|(?![a-zA-Z]))/,"one lowercase latin letter $":/^(?:([a-z])(?:$|[^a-zA-Z]))$/,"$one lowercase latin letter$ $":/^\$(?:([a-z])(?:$|[^a-zA-Z]))\$$/,"one lowercase greek letter $":/^(?:\$?[\u03B1-\u03C9]\$?|\$?\\(?:alpha|beta|gamma|delta|epsilon|zeta|eta|theta|iota|kappa|lambda|mu|nu|xi|omicron|pi|rho|sigma|tau|upsilon|phi|chi|psi|omega)\s*\$?)(?:\s+|\{\}|(?![a-zA-Z]))$/,digits:/^[0-9]+/,"-9.,9":/^[+\-]?(?:[0-9]+(?:[,.][0-9]+)?|[0-9]*(?:\.[0-9]+))/,"-9.,9 no missing 0":/^[+\-]?[0-9]+(?:[.,][0-9]+)?/,"(-)(9.,9)(e)(99)":function(e){var t=e.match(/^(\+\-|\+\/\-|\+|\-|\\pm\s?)?([0-9]+(?:[,.][0-9]+)?|[0-9]*(?:\.[0-9]+))?(\((?:[0-9]+(?:[,.][0-9]+)?|[0-9]*(?:\.[0-9]+))\))?(?:(?:([eE])|\s*(\*|x|\\times|\u00D7)\s*10\^)([+\-]?[0-9]+|\{[+\-]?[0-9]+\}))?/);return t&&t[0]?{match_:t.slice(1),remainder:e.substr(t[0].length)}:null},"(-)(9)^(-9)":/^(\+\-|\+\/\-|\+|\-|\\pm\s?)?([0-9]+(?:[,.][0-9]+)?|[0-9]*(?:\.[0-9]+)?)\^([+\-]?[0-9]+|\{[+\-]?[0-9]+\})/,"state of aggregation $":function(e){var t=_mhchemParser.patterns.findObserveGroups(e,"",/^\([a-z]{1,3}(?=[\),])/,")","");if(t&&t.remainder.match(/^($|[\s,;\)\]\}])/))return t;var n=e.match(/^(?:\((?:\\ca\s?)?\$[amothc]\$\))/);return n?{match_:n[0],remainder:e.substr(n[0].length)}:null},"_{(state of aggregation)}$":/^_\{(\([a-z]{1,3}\))\}/,"{[(":/^(?:\\\{|\[|\()/,")]}":/^(?:\)|\]|\\\})/,", ":/^[,;]\s*/,",":/^[,;]/,".":/^[.]/,". __* ":/^([.\u22C5\u00B7\u2022]|[*])\s*/,"...":/^\.\.\.(?=$|[^.])/,"^{(...)}":function(e){return _mhchemParser.patterns.findObserveGroups(e,"^{","","","}")},"^($...$)":function(e){return _mhchemParser.patterns.findObserveGroups(e,"^","$","$","")},"^a":/^\^([0-9]+|[^\\_])/,"^\\x{}{}":function(e){return _mhchemParser.patterns.findObserveGroups(e,"^",/^\\[a-zA-Z]+\{/,"}","","","{","}","",!0)},"^\\x{}":function(e){return _mhchemParser.patterns.findObserveGroups(e,"^",/^\\[a-zA-Z]+\{/,"}","")},"^\\x":/^\^(\\[a-zA-Z]+)\s*/,"^(-1)":/^\^(-?\d+)/,"'":/^'/,"_{(...)}":function(e){return _mhchemParser.patterns.findObserveGroups(e,"_{","","","}")},"_($...$)":function(e){return _mhchemParser.patterns.findObserveGroups(e,"_","$","$","")},_9:/^_([+\-]?[0-9]+|[^\\])/,"_\\x{}{}":function(e){return _mhchemParser.patterns.findObserveGroups(e,"_",/^\\[a-zA-Z]+\{/,"}","","","{","}","",!0)},"_\\x{}":function(e){return _mhchemParser.patterns.findObserveGroups(e,"_",/^\\[a-zA-Z]+\{/,"}","")},"_\\x":/^_(\\[a-zA-Z]+)\s*/,"^_":/^(?:\^(?=_)|\_(?=\^)|[\^_]$)/,"{}^":/^\{\}(?=\^)/,"{}":/^\{\}/,"{...}":function(e){return _mhcheLine truncated
//![[link|alias]] [alias](link){num}
EXPR:/(!)?(\[\[([^|\]]+)\|?([^\]]+)?]]|\[([^\]]*)]\(([^)]*)\))(\{(\d+)\})?/g,getResList:e=>{const t=e.matchAll(REGEX_LINK.EXPR);let n;const r=[];for(;!(n=t.next()).done;)r.push(n);return r},getRes:e=>e.matchAll(REGEX_LINK.EXPR),isTransclusion:e=>!!e.value[1],getLink:e=>e.value[3]?e.value[3]:e.value[6],isWikiLink:e=>!!e.value[3],getAliasOrLink:e=>REGEX_LINK.isWikiLink(e)?e.value[4]?e.value[4]:e.value[3]:e.value[5]?e.value[5]:e.value[6],getWrapLength:(e,t)=>{const n=parseInt(e.value[8]);return isNaN(n)?t>0?t:null:n}},DRAWING_REG=/\n# Drawing\n[^`]*(```json\n)([\s\S]*?)```\n/gm,DRAWING_REG_FALLBACK=/\n# Drawing\n(```json\n)?(.*)(```)?(%%)?/gm,DRAWING_COMPRESSED_REG=/(\n# Drawing\n[^`]*(?:```compressed\-json\n))([\s\S]*?)(```\n)/gm,DRAWING_COMPRESSED_REG_FALLBACK=/(\n# Drawing\n(?:```compressed\-json\n)?)(.*)((```)?(%%)?)/gm,REG_LINKINDEX_HYPERLINK=/^\w+:\/\//,isCompressedMD=e=>null!==e.match(/```compressed\-json\n/gm),getDecompressedScene=e=>{let t,n=e.matchAll(DRAWING_COMPRESSED_REG);return t=n.next(),t.done&&(n=e.matchAll(DRAWING_COMPRESSED_REG_FALLBACK),t=n.next()),t.value&&t.value.length>1?[decompress(t.value[2]),t]:[null,t]},changeThemeOfExcalidrawMD=e=>{const t=isCompressedMD(e);let n=t?getDecompressedScene(e)[0]:e;return n?(isObsidianThemeDark?1===(n.match(/"theme"\s*:\s*"light"\s*,/g)||[]).length&&(n=n.replace(/"theme"\s*:\s*"light"\s*,/,'"theme": "dark",')):1===(n.match(/"theme"\s*:\s*"dark"\s*,/g)||[]).length&&(n=n.replace(/"theme"\s*:\s*"dark"\s*,/,'"theme": "light",')),t?e.replace(DRAWING_COMPRESSED_REG,`$1${compress(n)}$3`):n):e};function getJSON(e){let t,n;if(isCompressedMD(e)){const[t,n]=getDecompressedScene(e);return t?{scene:t.substring(0,t.lastIndexOf("}")+1),pos:n.value.index}:{scene:e,pos:n.value?n.value.index:0}}if(t=e.matchAll(DRAWING_REG),n=t.next(),n.done&&(t=e.matchAll(DRAWING_REG_FALLBACK),n=t.next()),n.value&&n.value.length>1){const e=n.value[2];return{scene:e.substr(0,e.lastIndexOf("}")+1),pos:n.value.index}}return{scene:e,pos:n.value?n.value.index:0}}function getMarkdownDrawingSection(e,t){return t?`%%\n# Drawing\n\`\`\`compressed-json\n${compress(e)}\n\`\`\`\n%%`:`%%\n# Drawing\n\`\`\`json\n${e}\n\`\`\`\n%%`}const estimateMaxLineLen=(e,t)=>{if(!t||!e)return null;if(e===t)return null;let n=0;const r=e.split("\n");if(1===r.length)return null;for(const e of r){const t=e.trim();t.length>n&&(n=t.length)}return n},wrap=(e,t)=>t?wrapTextAtCharLength(e,t,!1,0):e,getExcalidrawMarkdownHeaderSection=(e,t)=>{let n=e.search(/(^%%\n)?# Text Elements\n/m);if(-1==n&&(n=e.search(/(%%\n)?# Drawing\n/)),-1==n)return e;let r=updateFrontmatterInString(e.substring(0,n),t);const i=/(^---[\w\W]*?---\n)(!\[\[.*?]]\n(%%\n)?)/m;return r.match(i)&&(r=r.replace(i,"$1")),r};class ExcalidrawData{constructor(e){this.plugin=e,this.textElements=null,this.elementLinks=null,this.scene=null,this.deletedElements=[],this.file=null,this.embeddableTheme="auto",this.autoexportPreference=AutoexportPreference.inherit,this.textMode=TextMode.raw,this.loaded=!1,this.files=null,this.equations=null,this.mermaids=null,this.compatibilityMode=!1,this.selectedElementIds={},this.disableCompression=!1,this.app=e.app,this.files=new Map,this.equations=new Map,this.mermaids=new Map}initializeNonInitializedFields(){var e,t,n;if(!this.scene||!this.scene.elements)return;const r=null!==(e=this.scene.source.split("https://github.com/zsviczian/obsidian-excalidraw-plugin/releases/tag/")[1])&&void 0!==e?e:"1.8.16",i=this.scene.elements;for(const e of i){if("iframe"!==e.type||e.customData||(e.type="embeddable"),e.boundElements){const t=new Map;let n=!1;e.boundElements.forEach((e=>{"text"===e.type?n?i.find((t=>t.id===e.id)).containerId=null:(t.set(e.id,e.type),n=!0):t.set(e.id,e.type)}));const r=Array.from(t,(([e,t])=>({id:e,type:t})));r.length!==e.boundElements.length&&(e.boundElements=r)}e.boundElementIds&&(e.boundElements||(e.boundElements=[]),e.boundElements=e.boundElements.concat(e.boundElementIds.map((e=>({type:"arrow",id:e})))),delete e.boundElementIds),"text"!==e.type||e.containerId||(e.containerId=null),null===e.x&&(e.x=0),null===e.y&&(e.y=0),null===(null===(t=e.startBinding)||void 0===t?void 0:t.focus)&&(e.startBinding.focus=0),null===(null===(n=e.endBinding)||void 0===n?void 0:n.focus)&&(e.endBinding.focus=0),null===e.fontSize&&(e.fontSize=20)}try{i.filter((e=>"text"===e.type&&e.containerId&&i.some((t=>t.id===e.containerId&&t.boundElements.length>0&&t.boundElements.some((t=>"text"===t.type&&t.id!==e.id&&t.id.length>8)))))).forEach((e=>{try{const t=i.filter((t=>t.id===e.containerId))[0],n=t.boundElements.filter((e=>!("text"===e.type&&!i.some((t=>t.id===e.id)))));t.boundElements=[{id:e.id,type:"text"}].concat(n)}catch(e){}}));const e=!isVersionNewerThanOther(r,"1.8.16");i.filter((e=>e.boundElements&&e.boundElements.length>0)).forEach((t=>{var n;e&&!(null===(n=t.customData)||void 0===n?void 0:n.legacyTextWrap)&&addAppendUpdateCustomData(t,{legacyTextWrap:!0});const r=t.boundElements.filter((e=>i.some((t=>t.id===e.id))));r.length!==t.boundLine truncated
/**
* chroma.js - JavaScript library for color conversions
*
* Copyright (c) 2011-2019, Gregor Aisch
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice, this
* list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. The name Gregor Aisch may not be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL GREGOR AISCH OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
* OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
* EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* -------------------------------------------------------
*
* chroma.js includes colors from colorbrewer2.org, which are released under
* the following license:
*
* Copyright (c) 2002 Cynthia Brewer, Mark Harrower,
* and The Pennsylvania State University.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
* either express or implied. See the License for the specific
* language governing permissions and limitations under the License.
*
* ------------------------------------------------------
*
* Named colors are taken from X11 Color Names.
* http://www.w3.org/TR/css3-color/#svg-color
*
* @preserve
*/chroma$1.exports,function(e,t){e.exports=function(){for(var e=function(e,t,n){return void 0===t&&(t=0),void 0===n&&(n=1),e<t?t:e>n?n:e},t=e,n={},r=0,i=["Boolean","Number","String","Function","Array","Date","RegExp","Undefined","Null"];r<i.length;r+=1){var o=i[r];n["[object "+o+"]"]=o.toLowerCase()}var a=function(e){return n[Object.prototype.toString.call(e)]||"object"},s=a,l=a,c=Math.PI,T={clip_rgb:function(e){e._clipped=!1,e._unclipped=e.slice(0);for(var n=0;n<=3;n++)n<3?((e[n]<0||e[n]>255)&&(e._clipped=!0),e[n]=t(e[n],0,255)):3===n&&(e[n]=t(e[n],0,1));return e},limit:e,type:a,unpack:function(e,t){return void 0===t&&(t=null),e.length>=3?Array.prototype.slice.call(e):"object"==s(e[0])&&t?t.split("").filter((function(t){return void 0!==e[0][t]})).map((function(t){return e[0][t]})):e[0]},last:function(e){if(e.length<2)return null;var t=e.length-1;return"string"==l(e[t])?e[t].toLowerCase():null},PI:c,TWOPI:2*c,PITHIRD:c/3,DEG2RAD:c/180,RAD2DEG:180/c},Q={format:{},autodetect:[]},d=T.last,u=T.clip_rgb,p=T.type,h=Q,m=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];var n=this;if("object"===p(e[0])&&e[0].constructor&&e[0].constructor===this.constructor)return e[0];var r=d(e),i=!1;if(!r){i=!0,h.sorted||(h.autodetect=h.autodetect.sort((function(e,t){return t.p-e.p})),h.sorted=!0);for(var o=0,a=h.autodetect;o<a.length;o+=1){var s=a[o];if(r=s.test.apply(s,e))break}}if(!h.format[r])throw new Error("unknown format: "+e);var l=h.format[r].apply(null,i?e:e.slice(0,-1));n._rgb=u(l),3===n._rgb.length&&n._rgb.push(1)};m.prototype.toString=function(){return"function"==p(this.hex)?this.hex():"["+this._rgb.join(",")+"]"};var f=m,g=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];return new(Function.prototype.bind.apply(g.Color,[null].concat(e)))};g.Color=f,g.version="2.4.2";var b=g,y=T.unpack,L=Math.max,v=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];var n=y(e,"rgb"),r=n[0],i=n[1],o=n[2],a=1-L(r/=255,L(i/=255,o/=255)),s=a<1?1/(1-a):0;return[(1-r-a)*s,(1-i-a)*s,(1-o-a)*s,a]},w=T.unpack,E=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];var n=(e=w(e,"cmyk"))[0],r=e[1],i=e[2],o=e[3],a=e.length>4?e[4]:1;return 1===o?[0,0,0,a]:[n>=1?0:255*(1-n)*(1-o),r>=1?0:255*(1-r)*(1-o),i>=1?0:255*(1-i)*(1-o),a]},_=b,M=f,H=Q,x=T.unpack,S=T.type,A=v;M.prototype.cmyk=function(){return A(this._rgb)},_.cmyk=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];return new(Function.prototype.bind.apply(M,[null].concat(e,["cmyk"])))},H.format.cmyk=E,H.autodetect.push({p:2,test:function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];if(e=x(e,"cmyk"),"array"===S(e)&&4===e.length)return"cmyk"}});var C=T.unpack,O=T.last,V=function(e){return Math.round(100*e)/100},I=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];var n=C(e,"hsla"),r=O(e)||"lsa";return n[0]=V(n[0]||0),n[1]=V(100*n[1])+"%",n[2]=V(100*n[2])+"%","hsla"===r||n.length>3&&n[3]<1?(n[3]=n.length>3?n[3]:1,r="hsla"):n.length=3,r+"("+n.join(",")+")"},k=T.unpack,N=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];var n=(e=k(e,"rgba"))[0],r=e[1],i=e[2];n/=255,r/=255,i/=255;var o,a,s=Math.min(n,r,i),l=Math.max(n,r,i),c=(l+s)/2;return l===s?(o=0,a=Number.NaN):o=c<.5?(l-s)/(l+s):(l-s)/(2-l-s),n==l?a=(r-i)/(l-s):r==l?a=2+(i-n)/(l-s):i==l&&(a=4+(n-r)/(l-s)),(a*=60)<0&&(a+=360),e.length>3&&void 0!==e[3]?[a,o,c,e[3]]:[a,o,c]},P=T.unpack,R=T.last,j=I,D=N,B=Math.round,F=function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];var n=P(e,"rgba"),r=R(e)||"rgb";return"hsl"==r.substr(0,3)?j(D(n),r):(n[0]=B(n[0]),n[1]=B(n[1]),n[2]=B(n[2]),("rgba"===r||n.length>3&&n[3]<1)&&(n[3]=n.length>3?n[3]:1,r="rgba"),r+"("+n.slice(0,"rgb"===r?3:4).join(",")+")")},G=T.unpack,W=Math.round,U=function(){for(var e,t=[],n=arguments.length;n--;)t[n]=arguments[n];var r,i,o,a=(t=G(t,"hsl"))[0],s=t[1],l=t[2];if(0===s)r=i=o=255*l;else{var c=[0,0,0],T=[0,0,0],Q=l<.5?l*(1+s):l+s-l*s,d=2*l-Q,u=a/360;c[0]=u+1/3,c[1]=u,c[2]=u-1/3;for(var p=0;p<3;p++)c[p]<0&&(c[p]+=1),c[p]>1&&(c[p]-=1),6*c[p]<1?T[p]=d+6*(Q-d)*c[p]:2*c[p]<1?T[p]=Q:3*c[p]<2?T[p]=d+(Q-d)*(2/3-c[p])*6:T[p]=d;r=(e=[W(255*T[0]),W(255*T[1]),W(255*T[2])])[0],i=e[1],o=e[2]}return t.length>3?[r,i,o,t[3]]:[r,i,o,1]},Z=U,$=Q,z=/^rgb\(\s*(-?\d+),\s*(-?\d+)\s*,\s*(-?\d+)\s*\)$/,q=/^rgba\(\s*(-?\d+),\s*(-?\d+)\s*,\s*(-?\d+)\s*,\s*([01]|[01]?\.\d+)\)$/,X=/^rgb\(\s*(-?\d+(?:\.\d+)?)%,\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*\)$/,Y=/^rgba\(\s*(-?\d+(?:\.\d+)?)%,\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)$/,K=/^hsl\(\s*(-?\d+(?:\.\d+)?),\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*\)$/,J=/^hsla\(\s*(-?\d+(?:\.\d+)?),\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)$/,ee=Math.round,te=function(e){var t;if(e=e.toLowerCase().trim(),$.format.named)try{return $.format.named(e)}catch(e){}if(t=e.match(z)){for(var n=t.slice(1,4),r=0;r<3;r++)n[r]=+n[r];return n[3]=1,n}if(t=e.match(q)){for(var i=t.slice(1,5),oLine truncated
//! onauxclick: (e: any) => {e.preventDefault()},
,renderTopRightUI:(e,t)=>this.obsidianMenu.renderButton(e,t),renderEmbeddableMenu:e=>this.embeddableMenu.renderButtons(e),onPaste:(e,t)=>this.onPaste(e,t),onThemeChange:async e=>this.onThemeChange(e),ownerDocument:this.ownerDocument,ownerWindow:this.ownerWindow,onDrop:e=>this.onDrop(e),onBeforeTextEdit:e=>this.onBeforeTextEdit(e),onBeforeTextSubmit:(e,t,n,r)=>this.onBeforeTextSubmit(e,t,n,r),onLinkOpen:(e,t)=>this.onLinkOpen(e,t),onLinkHover:(e,t)=>this.onLinkHover(e,t),onContextMenu:T,onViewModeChange:e=>this.onViewModeChange(e),validateEmbeddable:!0,renderWebview:DEVICE.isDesktop,renderEmbeddable:(e,t)=>Q(e,t),renderMermaid:shouldRenderMermaid(),obsidianHostPlugin:this.plugin},d(),t.createElement(a,{},t.createElement(a.Center,{},t.createElement(a.Center.Logo,{},t.createElement(LogoWrapper,{},ICONS.ExcalidrawSword)),t.createElement(a.Center.Heading,{},'Type "Excalidraw" in the Command Palette',t.createElement("br"),"Explore the Obsidian Menu in the top right",t.createElement("br"),"Visit the Script Library",t.createElement("br"),"Find help in the hamburger-menu"),t.createElement(a.Center.Menu,{},t.createElement(a.Center.MenuItemLink,{icon:ICONS.YouTube,href:"https://www.youtube.com/@VisualPKM",shortcut:null,"aria-label":"Visual PKM YouTube Channel"}," Check out the Visual PKM YouTube channel."),t.createElement(a.Center.MenuItemLink,{icon:ICONS.Discord,href:"https://discord.gg/DyfAXFwUHc",shortcut:null,"aria-label":"Join the Visual Thinking Discord Server"}," Join the Visual Thinking Discord Server"),t.createElement(a.Center.MenuItemLink,{icon:ICONS.twitter,href:"https://twitter.com/zsviczian",shortcut:null,"aria-label":"Follow me on Twitter"}," Follow me on Twitter"),t.createElement(a.Center.MenuItemLink,{icon:ICONS.heart,href:"https://ko-fi.com/zsolt",shortcut:null,"aria-label":"Donate to support Excalidraw-Obsidian"},' Say "Thank You" & support the plugin.')))),t.createElement(l,{onTextSubmit:async e=>{var t,n,r,i,o,a;try{const s=await postOpenAI({systemPrompt:"The user will provide you with a text prompt. Your task is to generate a mermaid diagram based on the prompt. Use the graph, sequenceDiagram, flowchart or classDiagram types based on what best fits the request. Return a single message containing only the mermaid diagram in a codeblock. Avoid the use of `()` parenthesis in the mermaid script.",text:e,instruction:"Return a single message containing only the mermaid diagram in a codeblock."});if(!s)return{error:new Error("Request failed")};const l=s.json;if(null==l?void 0:l.error)return console.log(s),{error:new Error(l.error.message)};if(!(null===(r=null===(n=null===(t=null==l?void 0:l.choices)||void 0===t?void 0:t[0])||void 0===n?void 0:n.message)||void 0===r?void 0:r.content))return console.log(s),{error:new Error("Generation failed... see console log for details")};let c=null===(a=extractCodeBlocks(null===(o=null===(i=l.choices[0])||void 0===i?void 0:i.message)||void 0===o?void 0:o.content)[0])||void 0===a?void 0:a.data;return c?(c.startsWith("mermaid")&&(c=c.replace(/^mermaid/,"").trim()),{generatedResponse:c,rateLimit:100,rateLimitRemaining:100}):(console.log(s),{error:new Error("Generation failed... see console log for details")})}catch(e){throw new Error("Request failed")}}}),t.createElement(s,{})),u());return t.createElement(t.Fragment,null,g)}));n.createRoot(this.contentEl).render(p)}updateContainerSize(e,t=!1){const n=this.excalidrawAPI;if(!n)return;const r=()=>{const t=e?n.getSceneElements().filter((t=>t.id===e&&"arrow"!==t.type)):n.getSceneElements().filter(isContainer);t.length>0&&(this.initialContainerSizeUpdate&&(this.semaphores.justLoaded=!0),n.updateContainerSize(t)),this.initialContainerSizeUpdate=!1};t?setTimeout((()=>r()),50):r()}zoomToFit(e=!0,t=!1){if(document.body.querySelector("div.modal-container"))return;const n=this.excalidrawAPI;if(!n||this.semaphores.isEditingText||this.semaphores.preventAutozoom)return;const r=this.plugin.settings.zoomToFitMaxLevel,i=n.getSceneElements().filter((e=>e.width<1e4&&e.height<1e4));app.isMobile&&i.length>1e3||i.length>2500?t&&n.scrollToContent():e?setTimeout((()=>n.zoomToFit(i,r,this.isFullscreen()?0:.05)),100):n.zoomToFit(i,r,this.isFullscreen()?0:.05)}updatePinnedScripts(){const e=this.excalidrawAPI;if(!e)return!1;e.updateScene({appState:{pinnedScripts:this.plugin.settings.pinnedScripts}})}updatePinnedCustomPens(){const e=this.excalidrawAPI;if(!e)return!1;e.updateScene({appState:{customPens:this.plugin.settings.customPens.slice(0,this.plugin.settings.numberOfCustomPens)}})}updatePinchZoom(){const e=this.excalidrawAPI;if(!e)return!1;e.updateScene({appState:{allowPinchZoom:this.plugin.settings.allowPinchZoom}})}updateWheelZoom(){const e=this.excalidrawAPI;if(!e)return!1;e.updateScene({appState:{allowWheelZoom:this.plugin.settings.allowWheelZoom}})}async toggleTrayMode(){const e=this.excalidrawAPI;if(!e)return!1;const t=e.getAppState();e.updateScene({appState:{trayModeEnabled:!t.trayModeEnabled}}),await this.plugin.loadSettings(),this.plugin.Line truncated
//!Temporary hack
if(e.activeExcalidrawView=i,i?(e.addModalContainerObserver(),e.lastActiveExcalidrawFilePath=null===(n=i.file)||void 0===n?void 0:n.path):e.removeModalContainerObserver(),this.app.isMobile&&i&&!r){const e=document.querySelector("body>.app-container>.mobile-navbar");e&&e instanceof HTMLDivElement&&(e.style.position="relative")}if(this.app.isMobile&&!i&&r){const e=document.querySelector("body>.app-container>.mobile-navbar");e&&e instanceof HTMLDivElement&&(e.style.position="")}if(r&&r!==i&&(r.leaf!==t&&r.semaphores.dirty&&!r.semaphores.viewunload&&await r.save(!0),r.file&&e.triggerEmbedUpdates(r.file.path)),i&&(!r||r.leaf!==t)){const e=i.file;i.file&&setTimeout((()=>{var t;i&&i._loaded&&(null===(t=i.file)||void 0===t?void 0:t.path)===(null==e?void 0:e.path)&&(i.activeLoader||i.loadSceneFiles())}),2e3)}if(i&&i._loaded&&i.isLoaded&&i.excalidrawAPI&&e.ea.onCanvasColorChangeHook&&e.ea.onCanvasColorChangeHook(e.ea,i,i.excalidrawAPI.getAppState().viewBackgroundColor),e.popScope&&(e.popScope(),e.popScope=null),i){const t=e.app.keymap.getRootScope(),n=t.register(["Mod"],"Enter",(()=>!0));t.keys.unshift(t.keys.pop());const r=t.register(["Mod"],"k",(()=>!0));t.keys.unshift(t.keys.pop());const i=t.register(["Mod"],"f",(()=>{const e=this.app.workspace.getActiveViewOfType(ExcalidrawView);return!!e&&(search(e),!0)}));t.keys.unshift(t.keys.pop());const o=e.forceSaveCommand&&"s"===e.forceSaveCommand.hotkeys[0].key&&e.forceSaveCommand.hotkeys[0].modifiers.includes("Ctrl")?t.register(["Ctrl"],"s",(()=>e.forceSaveActiveView(!1))):void 0;o&&t.keys.unshift(t.keys.pop()),e.popScope=()=>{t.unregister(n),t.unregister(r),t.unregister(i),Boolean(o)&&t.unregister(o)}}}))),e.addFileSaveTriggerEventHandlers();const t=app.metadataCache;t.getCachedFiles().forEach((n=>{var r;const i=null===(r=t.getCache(n))||void 0===r?void 0:r.frontmatter;(i&&void 0!==i[FRONTMATTER_KEY]||n.match(/\.excalidraw$/))&&e.updateFileCache(app.vault.getAbstractFileByPath(n),i)})),this.registerEvent(t.on("changed",((e,t,n)=>this.updateFileCache(e,null==n?void 0:n.frontmatter))))}))}addFileSaveTriggerEventHandlers(){const e=e=>{this.activeExcalidrawView&&this.activeExcalidrawView.semaphores.dirty&&(!e.target||"excalidraw__canvas"!==e.target.className&&!getParentOfClass(e.target,"excalidraw-wrapper"))&&this.activeExcalidrawView.save()};this.app.workspace.containerEl.addEventListener("click",e),this.removeEventLisnters.push((()=>{this.app.workspace.containerEl.removeEventListener("click",e)})),this.registerEvent(this.app.workspace.on("file-menu",(()=>{this.activeExcalidrawView&&this.activeExcalidrawView.semaphores.dirty&&this.activeExcalidrawView.save()}))),this.addModalContainerObserver();const t=document.querySelector(".workspace-drawer.mod-left"),n=document.querySelector(".workspace-drawer.mod-right");if(t||n){const e=async e=>{"display: none;"===e[0].oldValue&&this.activeExcalidrawView&&this.activeExcalidrawView.semaphores.dirty&&this.activeExcalidrawView.save()},r={attributeOldValue:!0,attributeFilter:["style"]};t&&(this.workspaceDrawerLeftObserver=new MutationObserver(e),this.workspaceDrawerLeftObserver.observe(t,r)),n&&(this.workspaceDrawerRightObserver=new MutationObserver(e),this.workspaceDrawerRightObserver.observe(n,r))}}addModalContainerObserver(){if(this.activeExcalidrawView){if(this.modalContainerObserver){if(this.activeViewDoc===this.activeExcalidrawView.ownerDocument)return;this.removeModalContainerObserver()}this.modalContainerObserver=new MutationObserver((async e=>{1===e.length&&"childList"===e[0].type&&1===e[0].addedNodes.length&&this.activeExcalidrawView&&this.activeExcalidrawView.semaphores.dirty&&this.activeExcalidrawView.save()})),this.activeViewDoc=this.activeExcalidrawView.ownerDocument,this.modalContainerObserver.observe(this.activeViewDoc.body,{childList:!0})}}removeModalContainerObserver(){this.modalContainerObserver&&(this.modalContainerObserver.disconnect(),this.activeViewDoc=null,this.modalContainerObserver=null)}updateFileCache(e,t,n=!1){t&&void 0!==t[FRONTMATTER_KEY]?this.excalidrawFiles.add(e):n||"excalidraw"!==e.extension?this.excalidrawFiles.delete(e):this.excalidrawFiles.add(e)}onunload(){document.body.removeChild(this.textMeasureDiv),this.stylesManager.unload(),this.removeFonts(),this.removeEventLisnters.forEach((e=>e())),destroyExcalidrawAutomate(),this.popScope&&(this.popScope(),this.popScope=null),this.legacyExcalidrawPopoverObserver&&this.legacyExcalidrawPopoverObserver.disconnect(),this.removeThemeObserver(),this.removeModalContainerObserver(),this.workspaceDrawerLeftObserver&&this.workspaceDrawerLeftObserver.disconnect(),this.workspaceDrawerRightObserver&&this.workspaceDrawerRightObserver.disconnect(),this.fileExplorerObserver&&this.fileExplorerObserver.disconnect(),this.app.workspace.getLeavesOfType("excalidraw").forEach((e=>{this.setMarkdownView(e)})),Object.values(this.packageMap).forEach((e=>{delete e.excalidrawLib,delete e.reactDOM,delete e.react}))}async embedDrawing(e){const t=this.app.workspace.getActiveViewOfType(oLine truncated
@@ -0,0 +1,12 @@
{
"id": "obsidian-excalidraw-plugin",
"name": "Excalidraw",
"version": "2.0.13",
"minAppVersion": "1.1.6",
"description": "An Obsidian plugin to edit and view Excalidraw drawings",
"author": "Zsolt Viczian",
"authorUrl": "https://zsolt.blog",
"fundingUrl": "https://ko-fi.com/zsolt",
"helpUrl": "https://github.com/zsviczian/obsidian-excalidraw-plugin#readme",
"isDesktopOnly": false
}
@@ -0,0 +1 @@
.App{font-family:sans-serif;text-align:center}.excalidraw-wrapper{background-color:#fff;height:100%;margin:0}.context-menu-option__shortcut{background-color:transparent!important}.block-language-excalidraw{text-align:center}.excalidraw .github-corner{display:none}.excalidraw-embedded-img{width:100%}.excalidraw-svg-right-wrap{float:right;margin:0 0 20px 20px;width:100%}.excalidraw-svg-left-wrap{float:left;margin:0 35px 20px 0;width:100%}.excalidraw-svg-right{float:right}.excalidraw-svg-center{margin:auto;text-align:center;width:100%}.excalidraw-svg-left{float:left}div.excalidraw-svg-left,div.excalidraw-svg-right{display:table;width:100%}button.ToolIcon_type_button[title=Export]{display:none}.excalidraw-prompt-div{display:flex;max-width:800px}.excalidraw-prompt-form{display:flex;flex-grow:1}.excalidraw-prompt-input{flex-grow:1}.excalidraw-prompt-button{width:9em}.excalidraw-prompt-buttons-div{display:flex;flex-direction:row;flex-wrap:nowrap;justify-content:space-evenly}li[data-testid]{border:0!important;margin:0!important;padding:0!important;width:100%!important}.excalidraw .context-menu-option-separator{margin:4px!important}.excalidraw .popover{background-color:transparent!important;border:0!important;box-shadow:0!important;padding:0!important;position:fixed!important}.disable-zen-mode--visible{color:var(--text-primary-color)}.disable-zen-mode{width:9em!important}.ex-coffee-div{margin-bottom:10px;text-align:center}.excalidraw-scriptengine-install td>img{max-width:800px;width:100%}.excalidraw-scriptengine-install img.coffee{width:130px}.excalidraw-scriptengine-install tr{vertical-align:top}.excalidraw-scriptengine-install table{max-width:130ch}.excalidraw-scriptengine-install td.label{font-weight:700;min-width:11ch;padding-right:5px}.excalidraw-scriptengine-install td.data{width:100%}.excalidraw-scriptengine-install .modal-content{max-width:130ch;user-select:text}.excalidraw-scriptengine-install .modal{max-height:90%;width:auto}.excalidraw-prompt-center{text-align:center!important}.excalidraw-prompt-center button{margin:0 10px}.excalidraw-prompt-center.filepath{font-weight:700;margin-bottom:2em;text-align:center}.excalidraw-dirty{color:red}.workspace-leaf-content .excalidraw-view{overflow:hidden;padding:0 1px}.excalidraw-videoWrapper{max-width:600px}.excalidraw-videoWrapper.settings{max-width:340px}.excalidraw-videoWrapper div{height:0;margin:0 auto;padding-bottom:56.25%;position:relative}.excalidraw-videoWrapper.settings iframe{margin-bottom:1rem;position:relative}.excalidraw-videoWrapper iframe{height:100%;left:0;position:absolute;top:0;width:100%}.excalidraw-release .modal-content{margin-right:-5px;padding-right:5px;user-select:text}.excalidraw-release .modal{max-height:80%;max-width:42em}.excalidraw .Island .scrollbar{--scrollbar-thumb-bg:silver}.excalidraw .ToolIcon__icon img{height:1em}.excalidraw-scriptengine-install tbody>tr>td>div>img{background-color:silver;height:20px;padding:2px}.excalidraw-scriptengine-install tbody>tr>td>div{display:inline-block;width:50px}.excalidraw-release p>a>img{width:100%}.excalidraw .context-menu-option{box-shadow:none}textarea.excalidraw-wysiwyg{border:none;border-radius:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;outline:none}.is-mobile .excalidraw button,.is-tablet .excalidraw button{height:1.8rem;padding:initial}.ToolIcon button,.excalidraw button{box-shadow:none;justify-content:normal}.excalidraw{--default-button-size:2rem!important;--default-icon-size:1rem!important;--lg-button-size:1.8rem!important;--lg-icon-size:1rem!important}.excalidraw .tray-zoom{padding-bottom:.05rem;padding-top:.05rem;pointer-events:auto}.excalidraw-container.theme--dark{background-color:#121212;color:#fff}.color-picker-content{max-height:10rem;overflow-y:auto}.excalidraw .FixedSideContainer_side_top{top:.3rem}.excalidraw .ToolIcon__keybinding{font-size:.45rem!important}.Island>.Stack>.Stack{padding:.2rem}label.color-input-container>input{max-width:5rem}.excalidraw .FixedSideContainer_side_top{bottom:10px!important;left:10px!important;right:10px!important;top:10px!important}.excalidraw-hidden{display:none!important}.excalidraw .panelColumn .buttonList{max-width:13rem}.excalidraw button{width:auto}.excalidraw input[type=color]{height:1.65rem;width:1.65rem}.excalidraw input[type=color]::-webkit-color-swatch{height:1.65rem}.excalidraw input[type=color]::-webkit-color-swatch-wrapper{padding:0}.excalidraw-settings input:not([type=color]){min-width:10em}div.excalidraw-draginfo{background:var(--color-base-40);border-radius:5px;color:var(--text-normal);display:block;padding:3px;position:absolute;z-index:1000}.excalidraw [data-radix-popper-content-wrapper]{position:absolute!important}.excalidraw__embeddable-container .view-header{display:none!important}.excalidraw__embeddable-container input{background:initial}.excalidraw .embeddable-menu{display:block;height:fit-content;position:absolute;width:fit-content;z-index:var(--zIndex-layerUI)}.excalidraw .welcome-screen-center__logo svg{wLine truncated
+58
View File
@@ -0,0 +1,58 @@
{
"commitMessage": "vault backup: {{date}}",
"commitDateFormat": "YYYY-MM-DD HH:mm:ss",
"autoSaveInterval": 60,
"autoPushInterval": 0,
"autoPullInterval": 0,
"autoPullOnBoot": false,
"disablePush": false,
"pullBeforePush": true,
"disablePopups": false,
"disablePopupsForNoChanges": false,
"listChangedFilesInMessageBody": false,
"showStatusBar": true,
"updateSubmodules": false,
"syncMethod": "merge",
"customMessageOnAutoBackup": false,
"autoBackupAfterFileChange": false,
"treeStructure": false,
"refreshSourceControl": true,
"basePath": "",
"differentIntervalCommitAndPush": false,
"changedFilesInStatusBar": false,
"showedMobileNotice": true,
"refreshSourceControlTimer": 7000,
"showBranchStatusBar": true,
"setLastSaveToLastCommit": false,
"submoduleRecurseCheckout": false,
"gitDir": "",
"showFileMenu": true,
"authorInHistoryView": "hide",
"dateInHistoryView": false,
"lineAuthor": {
"show": false,
"followMovement": "inactive",
"authorDisplay": "initials",
"showCommitHash": false,
"dateTimeFormatOptions": "date",
"dateTimeFormatCustomString": "YYYY-MM-DD HH:mm",
"dateTimeTimezone": "viewer-local",
"coloringMaxAge": "1y",
"colorNew": {
"r": 255,
"g": 150,
"b": 150
},
"colorOld": {
"r": 120,
"g": 160,
"b": 255
},
"textColorCss": "var(--text-muted)",
"ignoreWhitespace": false,
"gutterSpacingFallbackLength": 5,
"lastShownAuthorDisplay": "initials",
"lastShownDateTimeFormatOptions": "date"
},
"autoCommitMessage": "vault backup: {{date}}"
}
File diff suppressed because it is too large. Load diff
+9
View File
@@ -0,0 +1,9 @@
{
"id": "obsidian-git",
"name": "Git",
"description": "Backup your vault with Git.",
"isDesktopOnly": false,
"fundingUrl": "https://ko-fi.com/vinzent",
"js": "main.js",
"version": "2.24.1"
}
+551
View File
@@ -0,0 +1,551 @@
@keyframes loading {
0% {
transform: rotate(0deg);
}
100% {
transform: rotate(360deg);
}
}
.workspace-leaf-content[data-type="git-view"] .button-border {
border: 2px solid var(--interactive-accent);
border-radius: var(--radius-s);
}
.workspace-leaf-content[data-type="git-view"] .view-content {
padding: 0;
}
.workspace-leaf-content[data-type="git-history-view"] .view-content {
padding: 0;
}
.loading > svg {
animation: 2s linear infinite loading;
transform-origin: 50% 50%;
display: inline-block;
}
.obsidian-git-center {
margin: auto;
text-align: center;
width: 50%;
}
.obsidian-git-textarea {
display: block;
margin-left: auto;
margin-right: auto;
}
.obsidian-git-center-button {
display: block;
margin: 20px auto;
}
.tooltip.mod-left {
overflow-wrap: break-word;
}
.tooltip.mod-right {
overflow-wrap: break-word;
}
.git-tools {
display: flex;
margin-left: auto;
}
.git-tools .type {
padding-left: var(--size-2-1);
display: flex;
align-items: center;
justify-content: center;
width: 11px;
}
.git-tools .type[data-type="M"] {
color: orange;
}
.git-tools .type[data-type="D"] {
color: red;
}
.git-tools .buttons {
display: flex;
}
.git-tools .buttons > * {
padding: 0 0;
height: auto;
}
.git-author {
color: var(--text-accent);
}
.git-date {
color: var(--text-accent);
}
.git-ref {
color: var(--text-accent);
}
.workspace-leaf-content[data-type="diff-view"] .d2h-d-none {
display: none;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-wrapper {
text-align: left;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-header {
background-color: var(--background-primary);
border-bottom: 1px solid var(--interactive-accent);
font-family: var(--font-monospace);
height: 35px;
padding: 5px 10px;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-header,
.workspace-leaf-content[data-type="diff-view"] .d2h-file-stats {
display: -webkit-box;
display: -ms-flexbox;
display: flex;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-stats {
font-size: 14px;
margin-left: auto;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-lines-added {
border: 1px solid #b4e2b4;
border-radius: 5px 0 0 5px;
color: #399839;
padding: 2px;
text-align: right;
vertical-align: middle;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-lines-deleted {
border: 1px solid #e9aeae;
border-radius: 0 5px 5px 0;
color: #c33;
margin-left: 1px;
padding: 2px;
text-align: left;
vertical-align: middle;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-name-wrapper {
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
font-size: 15px;
width: 100%;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-name {
overflow-x: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-wrapper {
border: 1px solid var(--background-modifier-border);
border-radius: 3px;
margin-bottom: 1em;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-collapse {
-webkit-box-pack: end;
-ms-flex-pack: end;
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
border: 1px solid var(--background-modifier-border);
border-radius: 3px;
cursor: pointer;
display: none;
font-size: 12px;
justify-content: flex-end;
padding: 4px 8px;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-collapse.d2h-selected {
background-color: #c8e1ff;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-collapse-input {
margin: 0 4px 0 0;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-diff-table {
border-collapse: collapse;
font-family: Menlo, Consolas, monospace;
font-size: 13px;
width: 100%;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-files-diff {
width: 100%;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-diff {
overflow-y: hidden;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-side-diff {
display: inline-block;
margin-bottom: -8px;
margin-right: -4px;
overflow-x: scroll;
overflow-y: hidden;
width: 50%;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-code-line {
padding: 0 8em;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-code-line,
.workspace-leaf-content[data-type="diff-view"] .d2h-code-side-line {
display: inline-block;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
white-space: nowrap;
width: 100%;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-code-side-line {
padding: 0 4.5em;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-code-line-ctn {
word-wrap: normal;
background: none;
display: inline-block;
padding: 0;
-webkit-user-select: text;
-moz-user-select: text;
-ms-user-select: text;
user-select: text;
vertical-align: middle;
white-space: pre;
width: 100%;
}
.theme-light .workspace-leaf-content[data-type="diff-view"] .d2h-code-line del,
.theme-light
.workspace-leaf-content[data-type="diff-view"]
.d2h-code-side-line
del {
background-color: #ffb6ba;
}
.theme-dark .workspace-leaf-content[data-type="diff-view"] .d2h-code-line del,
.theme-dark
.workspace-leaf-content[data-type="diff-view"]
.d2h-code-side-line
del {
background-color: #8d232881;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-code-line del,
.workspace-leaf-content[data-type="diff-view"] .d2h-code-line ins,
.workspace-leaf-content[data-type="diff-view"] .d2h-code-side-line del,
.workspace-leaf-content[data-type="diff-view"] .d2h-code-side-line ins {
border-radius: 0.2em;
display: inline-block;
margin-top: -1px;
text-decoration: none;
vertical-align: middle;
}
.theme-light .workspace-leaf-content[data-type="diff-view"] .d2h-code-line ins,
.theme-light
.workspace-leaf-content[data-type="diff-view"]
.d2h-code-side-line
ins {
background-color: #97f295;
text-align: left;
}
.theme-dark .workspace-leaf-content[data-type="diff-view"] .d2h-code-line ins,
.theme-dark
.workspace-leaf-content[data-type="diff-view"]
.d2h-code-side-line
ins {
background-color: #1d921996;
text-align: left;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-code-line-prefix {
word-wrap: normal;
background: none;
display: inline;
padding: 0;
white-space: pre;
}
.workspace-leaf-content[data-type="diff-view"] .line-num1 {
float: left;
}
.workspace-leaf-content[data-type="diff-view"] .line-num1,
.workspace-leaf-content[data-type="diff-view"] .line-num2 {
-webkit-box-sizing: border-box;
box-sizing: border-box;
overflow: hidden;
padding: 0 0.5em;
text-overflow: ellipsis;
width: 3.5em;
}
.workspace-leaf-content[data-type="diff-view"] .line-num2 {
float: right;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-code-linenumber {
background-color: var(--background-primary);
border: solid var(--background-modifier-border);
border-width: 0 1px;
-webkit-box-sizing: border-box;
box-sizing: border-box;
color: var(--text-muted);
cursor: pointer;
display: inline-block;
position: absolute;
text-align: right;
width: 7.5em;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-code-linenumber:after {
content: "\200b";
}
.workspace-leaf-content[data-type="diff-view"] .d2h-code-side-linenumber {
background-color: var(--background-primary);
border: solid var(--background-modifier-border);
border-width: 0 1px;
-webkit-box-sizing: border-box;
box-sizing: border-box;
color: var(--text-muted);
cursor: pointer;
display: inline-block;
overflow: hidden;
padding: 0 0.5em;
position: absolute;
text-align: right;
text-overflow: ellipsis;
width: 4em;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-diff-tbody tr {
position: relative;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-code-side-linenumber:after {
content: "\200b";
}
.workspace-leaf-content[data-type="diff-view"] .d2h-code-side-emptyplaceholder,
.workspace-leaf-content[data-type="diff-view"] .d2h-emptyplaceholder {
background-color: var(--background-primary);
border-color: var(--background-modifier-border);
}
.workspace-leaf-content[data-type="diff-view"] .d2h-code-line-prefix,
.workspace-leaf-content[data-type="diff-view"] .d2h-code-linenumber,
.workspace-leaf-content[data-type="diff-view"] .d2h-code-side-linenumber,
.workspace-leaf-content[data-type="diff-view"] .d2h-emptyplaceholder {
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-code-linenumber,
.workspace-leaf-content[data-type="diff-view"] .d2h-code-side-linenumber {
direction: rtl;
}
.theme-light .workspace-leaf-content[data-type="diff-view"] .d2h-del {
background-color: #fee8e9;
border-color: #e9aeae;
}
.theme-light .workspace-leaf-content[data-type="diff-view"] .d2h-ins {
background-color: #dfd;
border-color: #b4e2b4;
}
.theme-dark .workspace-leaf-content[data-type="diff-view"] .d2h-del {
background-color: #521b1d83;
border-color: #691d1d73;
}
.theme-dark .workspace-leaf-content[data-type="diff-view"] .d2h-ins {
background-color: rgba(30, 71, 30, 0.5);
border-color: #13501381;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-info {
background-color: var(--background-primary);
border-color: var(--background-modifier-border);
color: var(--text-normal);
}
.theme-light
.workspace-leaf-content[data-type="diff-view"]
.d2h-file-diff
.d2h-del.d2h-change {
background-color: #fdf2d0;
}
.theme-dark
.workspace-leaf-content[data-type="diff-view"]
.d2h-file-diff
.d2h-del.d2h-change {
background-color: #55492480;
}
.theme-light
.workspace-leaf-content[data-type="diff-view"]
.d2h-file-diff
.d2h-ins.d2h-change {
background-color: #ded;
}
.theme-dark
.workspace-leaf-content[data-type="diff-view"]
.d2h-file-diff
.d2h-ins.d2h-change {
background-color: rgba(37, 78, 37, 0.418);
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-list-wrapper {
margin-bottom: 10px;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-list-wrapper a {
color: #3572b0;
text-decoration: none;
}
.workspace-leaf-content[data-type="diff-view"]
.d2h-file-list-wrapper
a:visited {
color: #3572b0;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-list-header {
text-align: left;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-list-title {
font-weight: 700;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-list-line {
display: -webkit-box;
display: -ms-flexbox;
display: flex;
text-align: left;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-list {
display: block;
list-style: none;
margin: 0;
padding: 0;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-list > li {
border-bottom: 1px solid var(--background-modifier-border);
margin: 0;
padding: 5px 10px;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-list > li:last-child {
border-bottom: none;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-file-switch {
cursor: pointer;
display: none;
font-size: 10px;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-icon {
fill: currentColor;
margin-right: 10px;
vertical-align: middle;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-deleted {
color: #c33;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-added {
color: #399839;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-changed {
color: #d0b44c;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-moved {
color: #3572b0;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-tag {
background-color: var(--background-primary);
display: -webkit-box;
display: -ms-flexbox;
display: flex;
font-size: 10px;
margin-left: 5px;
padding: 0 2px;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-deleted-tag {
border: 2px solid #c33;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-added-tag {
border: 1px solid #399839;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-changed-tag {
border: 1px solid #d0b44c;
}
.workspace-leaf-content[data-type="diff-view"] .d2h-moved-tag {
border: 1px solid #3572b0;
}
/* ====================== Line Authoring Information ====================== */
.cm-gutterElement.obs-git-blame-gutter {
/* Add background color to spacing inbetween and around the gutter for better aesthetics */
border-width: 0px 2px 0.2px 2px;
border-style: solid;
border-color: var(--background-secondary);
background-color: var(--background-secondary);
}
.cm-gutterElement.obs-git-blame-gutter > div,
.line-author-settings-preview {
/* delegate text color to settings */
color: var(--obs-git-gutter-text);
font-family: monospace;
height: 100%; /* ensure, that age-based background color occupies entire parent */
text-align: right;
padding: 0px 6px 0px 6px;
white-space: pre; /* Keep spaces and do not collapse them. */
}
+61
View File
@@ -0,0 +1,61 @@
{
"globalQuery": "",
"globalFilter": "",
"removeGlobalFilter": false,
"taskFormat": "tasksPluginEmoji",
"setCreatedDate": false,
"setDoneDate": true,
"autoSuggestInEditor": true,
"autoSuggestMinMatch": 0,
"autoSuggestMaxItems": 6,
"provideAccessKeys": true,
"useFilenameAsScheduledDate": false,
"filenameAsDateFolders": [],
"recurrenceOnNextLine": false,
"statusSettings": {
"coreStatuses": [
{
"symbol": " ",
"name": "Todo",
"nextStatusSymbol": "x",
"availableAsCommand": true,
"type": "TODO"
},
{
"symbol": "x",
"name": "Done",
"nextStatusSymbol": " ",
"availableAsCommand": true,
"type": "DONE"
}
],
"customStatuses": [
{
"symbol": "/",
"name": "In Progress",
"nextStatusSymbol": "x",
"availableAsCommand": true,
"type": "IN_PROGRESS"
},
{
"symbol": "-",
"name": "Cancelled",
"nextStatusSymbol": " ",
"availableAsCommand": true,
"type": "CANCELLED"
}
]
},
"features": {
"INTERNAL_TESTING_ENABLED_BY_DEFAULT": true
},
"generalSettings": {},
"headingOpened": {
"Core Statuses": true,
"Custom Statuses": true
},
"debugSettings": {
"ignoreSortInstructions": false,
"showTaskHiddenData": false
}
}
+347
View File
@@ -0,0 +1,347 @@
/*
THIS IS A GENERATED/BUNDLED FILE BY ESBUILD
if you want to view the source visit the plugins github repository
*/
/*
License obsidian-tasks:
MIT License
Copyright (c) 2021 Martin Schenck and Clare Macrae
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
*/
/*
License rrule (included library):
rrule.js: Library for working with recurrence rules for calendar dates.
=======================================================================
Copyright 2010, Jakub Roztocil <jakub@roztocil.name> and Lars Schöning
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
3. Neither the name of The author nor the names of its contributors may
be used to endorse or promote products derived from this software
without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE AUTHOR AND CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
./rrule.js and ./test/tests.js is based on python-dateutil. LICENCE:
python-dateutil - Extensions to the standard Python datetime module.
====================================================================
Copyright (c) 2003-2011 - Gustavo Niemeyer <gustavo@niemeyer.net>
Copyright (c) 2012 - Tomi Pieviläinen <tomi.pievilainen@iki.fi>
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
* Neither the name of the copyright holder nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
/*
License chrono-node (included library):
The MIT License
Copyright (c) 2014, Wanasit Tanakitrungruang
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
"use strict";var uv=Object.create;var os=Object.defineProperty,lv=Object.defineProperties,cv=Object.getOwnPropertyDescriptor,dv=Object.getOwnPropertyDescriptors,fv=Object.getOwnPropertyNames,rh=Object.getOwnPropertySymbols,pv=Object.getPrototypeOf,ih=Object.prototype.hasOwnProperty,hv=Object.prototype.propertyIsEnumerable;var nh=(r,e,t)=>e in r?os(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,we=(r,e)=>{for(var t in e||(e={}))ih.call(e,t)&&nh(r,t,e[t]);if(rh)for(var t of rh(e))hv.call(e,t)&&nh(r,t,e[t]);return r},it=(r,e)=>lv(r,dv(e));var _=(r,e)=>()=>(e||r((e={exports:{}}).exports,e),e.exports),mv=(r,e)=>{for(var t in e)os(r,t,{get:e[t],enumerable:!0})},sh=(r,e,t,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of fv(e))!ih.call(r,i)&&i!==t&&os(r,i,{get:()=>e[i],enumerable:!(n=cv(e,i))||n.enumerable});return r};var us=(r,e,t)=>(t=r!=null?uv(pv(r)):{},sh(e||!r||!r.__esModule?os(t,"default",{value:r,enumerable:!0}):t,r)),gv=r=>sh(os({},"__esModule",{value:!0}),r);var F=(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 Ee=_(rn=>{"use strict";Object.defineProperty(rn,"__esModule",{value:!0});rn.matchAnyPattern=rn.extractTerms=rn.repeatedTimeunitPattern=void 0;function _v(r,e){let t=e.replace(/\((?!\?)/g,"(?:");return`${r}${t}\\s{0,5}(?:,?\\s{0,5}${t}){0,10}`}rn.repeatedTimeunitPattern=_v;function ah(r){let e;return r instanceof Array?e=[...r]:r instanceof Map?e=Array.from(r.keys()):e=Object.keys(r),e}rn.extractTerms=ah;function vv(r){return`(?:${ah(r).sort((t,n)=>n.length-t.length).join("|").replace(/\./g,"\\.")})`}rn.matchAnyPattern=vv});var ye=_((Qu,Xu)=>{(function(r,e){typeof Qu=="object"&&typeof Xu!="undefined"?Xu.exports=e():typeof define=="function"&&define.amd?define(e):(r=typeof globalThis!="undefined"?globalThis:r||self).dayjs=e()})(Qu,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",f="year",h="date",T="Invalid Date",y=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,w=/\[([^\]]+)]|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,D={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("_")},C=function(B,A,E){var H=String(B);return!H||H.length>=A?B:""+Array(A+1-H.length).join(E)+B},N={s:C,z:function(B){var A=-B.utcOffset(),E=Math.abs(A),H=Math.floor(E/60),P=E%60;return(A<=0?"+":"-")+C(H,2,"0")+":"+C(P,2,"0")},m:function B(A,E){if(A.date()<E.date())return-B(E,A);var H=12*(E.year()-A.year())+(E.month()-A.month()),P=A.clone().add(H,l),Z=E-P<0,d=A.clone().add(H+(Z?-1:1),l);return+(-(H+(E-P)/(Z?P-d:d-P))||0)},a:function(B){return B<0?Math.ceil(B)||0:Math.floor(B)},p:function(B){return{M:l,y:f,w:u,d:o,D:h,h:a,m:s,s:i,ms:n,Q:c}[B]||String(B||"").toLowerCase().replace(/s$/,"")},u:function(B){return B===void 0}},L="en",oe={};oe[L]=D;var z=function(B){return B instanceof Ne},ie=function(B,A,E){var H;if(!B)return L;if(typeof B=="string")oe[B]&&(H=B),A&&(oe[B]=A,H=B);else{var P=B.name;oe[P]=B,H=P}return!E&&H&&(L=H),H||!E&&L},G=function(B,A){if(z(B))return B.clone();var E=typeof A=="object"?A:{};return E.date=B,E.args=arguments,new Ne(E)},j=N;j.l=ie,j.i=z,j.w=function(B,A){return G(B,{locale:A.$L,utc:A.$u,x:A.$x,$offset:A.$offset})};var Ne=function(){function B(E){this.$L=ie(E.locale,null,!0),this.parse(E)}var A=B.prototype;return A.parse=function(E){this.$d=function(H){var P=H.date,Z=H.utc;if(P===null)return new Date(NaN);if(j.u(P))return new Date;if(P instanceof Date)return new Date(P);if(typeof P=="string"&&!/Z$/i.test(P)){var d=P.match(y);if(d){var p=d[2]-1||0,m=(d[7]||"0").substring(0,3);return Z?new Date(Date.UTC(d[1],p,d[3]||1,d[4]||0,d[5]||0,d[6]||0,m)):new Date(d[1],p,d[3]||1,d[4]||0,d[5]||0,d[6]||0,m)}}return new Date(P)}(E),this.$x=E.x||{},this.init()},A.init=function(){var E=this.$d;this.$y=E.getFullYear(),this.$M=E.getMonth(),this.$D=E.getDate(),this.$W=E.getDay(),this.$H=E.getHours(),this.$m=E.getMinutes(),this.$s=E.getSeconds(),this.$ms=E.getMilliseconds()},A.$utils=function(){return j},A.isValid=function(){return this.$d.toString()!==T},A.isSame=function(E,H){var P=G(E);return this.startOf(H)<=P&&P<=this.endOf(H)},A.isAfter=function(E,H){return G(E)<this.startOf(H)},A.isBefore=function(E,H){return this.endOf(H)<G(E)},A.$g=function(E,H,P){return j.u(E)?this[H]:this.set(P,E)},A.unix=function(){return Math.floor(this.valueOf()/1e3)},A.valueOf=function(){return this.$d.getTime()},A.startOf=function(E,H){var P=this,Z=!!j.u(H)||H,d=j.p(E),p=function(O,I){var me=j.w(P.$u?Date.UTC(P.$y,I,O):new Date(P.$y,I,O),P);return Z?me:me.endOf(o)},m=function(O,I){return j.w(P.toDate()[O].apply(P.toDate("s"),(Z?[0,0,0,0]:[23,59,59,999]).slice(I)),P)},g=Line truncated
`).map(KM).filter(function(t){return t!==null});return lt(lt({},e[0]),e[1])}function ha(r){var e={},t=/DTSTART(?:;TZID=([^:=]+?))?(?::|=)([^;\s]+)/i.exec(r);if(!t)return e;var n=t[1],i=t[2];return n&&(e.tzid=n),e.dtstart=ca(i),e}function KM(r){if(r=r.replace(/^\s+|\s+$/,""),!r.length)return null;var e=/^([A-Z]+?)[:;]/.exec(r.toUpperCase());if(!e)return QT(r);var t=e[1];switch(t.toUpperCase()){case"RRULE":case"EXRULE":return QT(r);case"DTSTART":return ha(r);default:throw new Error("Unsupported RFC prop ".concat(t," in ").concat(r))}}function QT(r){var e=r.replace(/^RRULE:/i,""),t=ha(e),n=r.replace(/^(?:RRULE|EXRULE):/i,"").split(";");return n.forEach(function(i){var s=i.split("="),a=s[0],o=s[1];switch(a.toUpperCase()){case"FREQ":t.freq=ae[o.toUpperCase()];break;case"WKST":t.wkst=Zt[o.toUpperCase()];break;case"COUNT":case"INTERVAL":case"BYSETPOS":case"BYMONTH":case"BYMONTHDAY":case"BYYEARDAY":case"BYWEEKNO":case"BYHOUR":case"BYMINUTE":case"BYSECOND":var u=QM(o),l=a.toLowerCase();t[l]=u;break;case"BYWEEKDAY":case"BYDAY":t.byweekday=XM(o);break;case"DTSTART":case"TZID":var c=ha(r);t.tzid=c.tzid,t.dtstart=c.dtstart;break;case"UNTIL":t.until=ca(o);break;case"BYEASTER":t.byeaster=Number(o);break;default:throw new Error("Unknown RRULE property '"+a+"'")}}),t}function QM(r){if(r.indexOf(",")!==-1){var e=r.split(",");return e.map(XT)}return XT(r)}function XT(r){return/^[+-]?\d+$/.test(r)?Number(r):r}function XM(r){var e=r.split(",");return e.map(function(t){if(t.length===2)return Zt[t];var n=t.match(/^([+-]?\d{1,2})([A-Z]{2})$/);if(!n||n.length<3)throw new SyntaxError("Invalid weekday string: ".concat(t));var i=Number(n[1]),s=n[2],a=Zt[s].weekday;return new je(a,i)})}var Wn=function(){function r(e,t){if(isNaN(e.getTime()))throw new RangeError("Invalid date passed to DateWithZone");this.date=e,this.tzid=t}return Object.defineProperty(r.prototype,"isUTC",{get:function(){return!this.tzid||this.tzid.toUpperCase()==="UTC"},enumerable:!1,configurable:!0}),r.prototype.toString=function(){var e=Di(this.date.getTime(),this.isUTC);return this.isUTC?":".concat(e):";TZID=".concat(this.tzid,":").concat(e)},r.prototype.getTime=function(){return this.date.getTime()},r.prototype.rezonedDate=function(){return this.isUTC?this.date:$T(this.date,this.tzid)},r}();function ga(r){for(var e=[],t="",n=Object.keys(r),i=Object.keys(pa),s=0;s<n.length;s++)if(n[s]!=="tzid"&&!!fe(i,n[s])){var a=n[s].toUpperCase(),o=r[n[s]],u="";if(!(!xe(o)||ut(o)&&!o.length)){switch(a){case"FREQ":u=$.FREQUENCIES[r.freq];break;case"WKST":It(o)?u=new je(o).toString():u=o.toString();break;case"BYWEEKDAY":a="BYDAY",u=IT(o).map(function(T){return T instanceof je?T:ut(T)?new je(T[0],T[1]):new je(T)}).toString();break;case"DTSTART":t=ZM(o,r.tzid);break;case"UNTIL":u=Di(o,!r.tzid);break;default:if(ut(o)){for(var l=[],c=0;c<o.length;c++)l[c]=String(o[c]);u=l.toString()}else u=String(o)}u&&e.push([a,u])}}var f=e.map(function(T){var y=T[0],w=T[1];return"".concat(y,"=").concat(w.toString())}).join(";"),h="";return f!==""&&(h="RRULE:".concat(f)),[t,h].filter(function(T){return!!T}).join(`
`)}function ZM(r,e){return r?"DTSTART"+new Wn(new Date(r),e).toString():""}function JM(r,e){return Array.isArray(r)?!Array.isArray(e)||r.length!==e.length?!1:r.every(function(t,n){return t.getTime()===e[n].getTime()}):r instanceof Date?e instanceof Date&&r.getTime()===e.getTime():r===e}var ZT=function(){function r(){this.all=!1,this.before=[],this.after=[],this.between=[]}return r.prototype._cacheAdd=function(e,t,n){t&&(t=t instanceof Date?Wo(t):Gf(t)),e==="all"?this.all=t:(n._value=t,this[e].push(n))},r.prototype._cacheGet=function(e,t){var n=!1,i=t?Object.keys(t):[],s=function(c){for(var f=0;f<i.length;f++){var h=i[f];if(!JM(t[h],c[h]))return!0}return!1},a=this[e];if(e==="all")n=this.all;else if(ut(a))for(var o=0;o<a.length;o++){var u=a[o];if(!(i.length&&s(u))){n=u._value;break}}if(!n&&this.all){for(var l=new Yr(e,t),o=0;o<this.all.length&&l.accept(this.all[o]);o++);n=l.getValue(),this._cacheAdd(e,n,t)}return ut(n)?Gf(n):n instanceof Date?Wo(n):n},r}();var JT=M(M(M(M(M(M(M(M(M(M(M(M(M([],ce(1,31),!0),ce(2,28),!0),ce(3,31),!0),ce(4,30),!0),ce(5,31),!0),ce(6,30),!0),ce(7,31),!0),ce(8,31),!0),ce(9,30),!0),ce(10,31),!0),ce(11,30),!0),ce(12,31),!0),ce(1,7),!0),eb=M(M(M(M(M(M(M(M(M(M(M(M(M([],ce(1,31),!0),ce(2,29),!0),ce(3,31),!0),ce(4,30),!0),ce(5,31),!0),ce(6,30),!0),ce(7,31),!0),ce(8,31),!0),ce(9,30),!0),ce(10,31),!0),ce(11,30),!0),ce(12,31),!0),ce(1,7),!0),eC=Xt(1,29),tC=Xt(1,30),cn=Xt(1,31),ft=Xt(1,32),tb=M(M(M(M(M(M(M(M(M(M(M(M(M([],ft,!0),tC,!0),ft,!0),cn,!0),ft,!0),cn,!0),ft,!0),ft,!0),cn,!0),ft,!0),cn,!0),ft,!0),ft.slice(0,7),!0),rb=M(M(M(M(M(M(M(M(M(M(M(M(M([],ft,!0),eC,!0),ft,!0),cn,!0),ft,!0),cn,!0),ft,!0),ft,!0),cn,!0),ft,!0),cn,!0),ft,!0),ft.slice(0,7),!0),rC=Xt(-28,0),nC=Xt(-29,0),dn=Xt(-30,0),pt=Xt(-31,0),nb=M(M(M(M(M(M(M(M(M(M(M(M(M([],pt,!0),nC,!0),pt,!0),dn,!0),pt,!0),dn,!0),pt,!0),pt,!0),dn,!0),pt,!0),dn,!0),pt,!0),pt.slice(0,7),!0),ib=M(M(M(M(M(M(M(M(M(M(M(M(M([],pt,!0),rC,!0),pt,!0),dn,!0),pt,!0),dn,!0),pt,!0),pt,!0),dn,!0),pt,!0),dn,!0),pt,!0),pt.slice(0,7),!0),sb=[0,31,60,91,121,152,182,213,244,274,305,335,366],ab=[0,31,59,90,120,151,181,212,243,273,304,334,365],zf=function(){for(var r=[],e=0;e<55;e++)r=r.concat(Xt(7));return r}();function ob(r,e){var t=vr(r,1,1),n=Oi(r)?366:365,i=Oi(r+1)?366:365,s=la(t),a=Wr(t),o=lt(lt({yearlen:n,nextyearlen:i,yearordinal:s,yearweekday:a},iC(r)),{wnomask:null});if(Ft(e.byweekno))return o;o.wnomask=ce(0,n+7);var u,l,c=u=dt(7-a+e.wkst,7);c>=4?(c=0,l=o.yearlen+dt(a-e.wkst,7)):l=n-c;for(var f=Math.floor(l/7),h=dt(l,7),T=Math.floor(f+h/4),y=0;y<e.byweekno.length;y++){var w=e.byweekno[y];if(w<0&&(w+=T+1),w>0&&w<=T){var D=void 0;w>1?(D=c+(w-1)*7,c!==u&&(D-=7-u)):D=c;for(var C=0;C<7&&(o.wnomask[D]=1,D++,o.wdaymask[D]!==e.wkst);C++);}}if(fe(e.byweekno,1)){var D=c+T*7;if(c!==u&&(D-=7-u),D<n)for(var y=0;y<7&&(o.wnomask[D]=1,D+=1,o.wdaymask[D]!==e.wkst);y++);}if(c){var N=void 0;if(fe(e.byweekno,-1))N=-1;else{var L=Wr(vr(r-1,1,1)),oe=dt(7-L.valueOf()+e.wkst,7),z=Oi(r-1)?366:365,ie=void 0;oe>=4?(oe=0,ie=z+dt(L-e.wkst,7)):ie=n-c,N=Math.floor(52+dt(ie,7)/4)}if(fe(e.byweekno,N))for(var D=0;D<c;D++)o.wnomask[D]=1}return o}function iC(r){var e=Oi(r)?366:365,t=vr(r,1,1),n=Wr(t);return e===365?{mmask:JT,mdaymask:rb,nmdaymask:ib,wdaymask:zf.slice(n),mrange:ab}:{mmask:eb,mdaymask:tb,nmdaymask:nb,wdaymask:zf.slice(n),mrange:sb}}function ub(r,e,t,n,i,s){var a={lastyear:r,lastmonth:e,nwdaymask:[]},o=[];if(s.freq===$.YEARLY)if(Ft(s.bymonth))o=[[0,t]];else for(var u=0;u<s.bymonth.length;u++)e=s.bymonth[u],o.push(n.slice(e-1,e+1));else s.freq===$.MONTHLY&&(o=[n.slice(e-1,e+1)]);if(Ft(o))return a;a.nwdaymask=ce(0,t);for(var u=0;u<o.length;u++)for(var l=o[u],c=l[0],f=l[1]-1,h=0;h<s.bynweekday.length;h++){var T=void 0,y=s.bynweekday[h],w=y[0],D=y[1];D<0?(T=f+(D+1)*7,T-=dt(i[T]-w,7)):(T=c+(D-1)*7,T+=dt(7-i[T]+w,7)),c<=T&&T<=f&&(a.nwdaymask[T]=1)}return a}function lb(r,e){e===void 0&&(e=0);var t=r%19,n=Math.floor(r/100),i=r%100,s=Math.floor(n/4),a=n%4,o=Math.floor((n+8)/25),u=Math.floor((n-o+1)/3),l=Math.floor(19*t+n-s-u+15)%30,c=Math.floor(i/4),f=i%4,h=Math.floor(32+2*a+2*c-l-f)%7,T=Math.floor((t+11*l+22*h)/451),y=Math.floor((l+h-7*T+114)/31),w=(l+h-7*T+114)%31+1,D=Date.UTC(r,y-1,w+e),C=Date.UTC(r,0,1);return[Math.ceil((D-C)/(1e3*60*60*24))]}var sC=function(){function r(e){this.options=e}return r.prototype.rebuild=function(e,t){var n=this.options;if(e!==this.lastyear&&(this.yearinfo=ob(e,n)),qe(n.bynweekday)&&(t!==this.lastmonth||e!==this.lastyear)){var i=this.yearinfo,s=i.yearlen,a=i.mrange,o=i.wdaymask;this.monthinfo=ub(e,t,s,a,o,n)}xe(n.byeaster)&&(this.eastermask=lb(e,n.byeaster))},Object.defineProperty(r.prototype,"lastyear",{get:function(){return this.monthinfo?this.monthinfo.lastyear:null},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"lastmonth",{get:function(){return this.monthinfo?this.monthinfo.lastmonth:null},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"yearlen",{get:function(){return this.yearinfo.yearlen},enumerable:!1,configurab Line truncated
`),n=0;n<t.length;){var i=t[n]=t[n].replace(/\s+$/g,"");i?n>0&&i[0]===" "?(t[n-1]+=i.slice(1),t.splice(n,1)):n+=1:t.splice(n,1)}return t}function mC(r){r.forEach(function(e){if(!/(VALUE=DATE(-TIME)?)|(TZID=)/.test(e))throw new Error("unsupported RDATE/EXDATE parm: "+e)})}function mb(r,e){return mC(e),r.split(",").map(function(t){return ca(t)})}function gb(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;n<e._rrule.length;n++){var i=e._rrule[n].origOptions[r];if(i)return i}}}var Kf=function(r){xi(e,r);function e(t){t===void 0&&(t=!1);var n=r.call(this,{},t)||this;return n.dtstart=gb.apply(n,["dtstart"]),n.tzid=gb.apply(n,["tzid"]),n._rrule=[],n._rdate=[],n._exrule=[],n._exdate=[],n}return e.prototype._iter=function(t){return pb(t,this._rrule,this._exrule,this._rdate,this._exdate,this.tzid())},e.prototype.rrule=function(t){yb(t,this._rrule)},e.prototype.exrule=function(t){yb(t,this._exrule)},e.prototype.rdate=function(t){Tb(t,this._rdate)},e.prototype.exdate=function(t){Tb(t,this._exdate)},e.prototype.rrules=function(){return this._rrule.map(function(t){return Yo(t.toString())})},e.prototype.exrules=function(){return this._exrule.map(function(t){return Yo(t.toString())})},e.prototype.rdates=function(){return this._rdate.map(function(t){return new Date(t.getTime())})},e.prototype.exdates=function(){return this._exdate.map(function(t){return new Date(t.getTime())})},e.prototype.valueOf=function(){var t=[];return!this._rrule.length&&this._dtstart&&(t=t.concat(ga({dtstart:this._dtstart}))),this._rrule.forEach(function(n){t=t.concat(n.toString().split(`
`))}),this._exrule.forEach(function(n){t=t.concat(n.toString().split(`
`).map(function(i){return i.replace(/^RRULE:/,"EXRULE:")}).filter(function(i){return!/^DTSTART/.test(i)}))}),this._rdate.length&&t.push(bb("RDATE",this._rdate,this.tzid())),this._exdate.length&&t.push(bb("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}($);function yb(r,e){if(!(r instanceof $))throw new TypeError(String(r)+" is not RRule instance");fe(e.map(String),String(r))||e.push(r)}function Tb(r,e){if(!(r instanceof Date))throw new TypeError(String(r)+" is not Date instance");fe(e.map(Number),Number(r))||(e.push(r),$r(e))}function bb(r,e,t){var n=!t||t.toUpperCase()==="UTC",i=n?"".concat(r,":"):"".concat(r,";TZID=").concat(t,":"),s=e.map(function(a){return Di(a.valueOf(),n)}).join(",");return"".concat(i).concat(s)}function jr(r,e){return r!==null&&e===null?-1:r===null&&e!==null?1:r!==null&&e!==null?r.isValid()&&!e.isValid()?-1:!r.isValid()&&e.isValid()||r.isAfter(e)?1:r.isBefore(e)?-1:0:0}var et=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=$.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 $(u);return new et({rrule:c,baseOnToday:o,referenceDate:l,startDate:t,scheduledDate:n,dueDate:i})}}catch(s){s instanceof Error&&console.log(s.message)}return null}toText(){let e=this.rrule.toText();return this.baseOnToday&&(e+=" when done"),e}next(){let e=this.nextReferenceDate();if(e!==null){let t=null,n=null,i=null;if(this.referenceDate){if(this.startDate){let s=window.moment.duration(this.startDate.diff(this.referenceDate));t=window.moment(e),t.add(Math.round(s.asDays()),"days")}if(this.scheduledDate){let s=window.moment.duration(this.scheduledDate.diff(this.referenceDate));n=window.moment(e),n.add(Math.round(s.asDays()),"days")}if(this.dueDate){let s=window.moment.duration(this.dueDate.diff(this.referenceDate));i=window.moment(e),i.add(Math.round(s.asDays()),"days")}}return{startDate:t,scheduledDate:n,dueDate:i}}return null}identicalTo(e){return this.baseOnToday!==e.baseOnToday||jr(this.startDate,e.startDate)!==0||jr(this.scheduledDate,e.scheduledDate)!==0||jr(this.dueDate,e.dueDate)!==0?!1:this.toText()===e.toText()}nextReferenceDate(){if(this.baseOnToday){let e=window.moment();return this.nextReferenceDateFromToday(e).toDate()}else return this.nextReferenceDateFromOriginalReferenceDate().toDate()}nextReferenceDateFromToday(e){let t=new $(it(we({},this.rrule.origOptions),{dtstart:e.startOf("day").utc(!0).toDate()}));return this.nextAfter(e.endOf("day"),t)}nextReferenceDateFromOriginalReferenceDate(){var t;let e=window.moment((t=this.referenceDate)!=null?t:void 0).endOf("day");return this.nextAfter(e,this.rrule)}nextAfter(e,t){e.utc(!0);let n=window.moment(t.after(e.toDate())),i=this.toText(),s=i.match(/every( \d+)? month(s)?(.*)?/);s!==null&&(i.includes(" on ")||(n=et.nextAfterMonths(e,n,t,s[1])));let a=i.match(/every( \d+)? year(s)?(.*)?/);return a!==null&&(n=et.nextAfterYears(e,n,t,a[1])),et.addTimezone(n)}static nextAfterMonths(e,t,n,i){let s=1;for(i!==void 0&&(s=Number.parseInt(i.trim(),10));et.isSkippingTooManyMonths(e,t,s);)t=et.fromOneDayEarlier(e,n);return t}static isSkippingTooManyMonths(e,t,n){let i=t.month()-e.month();return i+=(t.year()-e.year())*12,i>n}static nextAfterYears(e,t,n,i){let s=1;for(i!==void 0&&(s=Number.parseInt(i.trim(),10));et.isSkippingTooManyYears(e,t,s);)t=et.fromOneDayEarlier(e,n);return t}static isSkippingTooManyYears(e,t,n){return t.year()-e.year()>n}static fromOneDayEarlier(e,t){e.subtract(1,"days").endOf("day");let n=t.origOptions;return n.dtstart=e.startOf("day").toDate(),t=new $(n),window.moment(t.after(e.toDate()))}static addTimezone(e){return window.moment.utc(e).local(!0).startOf("day")}};function Go(r){return r.replace(/([.*+?^${}()|[\]/\\])/g,"\\$1")}var fn=class{constructor(){this._globalFilter="";this._removeGlobalFilter=!1}static getInstance(){return fn.instance||(fn.instance=new fn),fn.instance}get(){return this._globalFilter}set(e){this._globalFilter=e}reset(){this.set(fn.empty)}isEmpty(){return this.get()===fn.empty}equals(e){return this.get()===e}includedIn(e){let t=this.get();return e.includes(t)}prependTo(e){return this.get()+" "+e}removeAsWordFromDependingOnSettings(e){return this.getRemoveGlobalFilter()?this.removeAsWordFrom(e):e}getRemoveGlobalFilter(){return this._removeGlobalFilter}setRemoveGlobalFilter(e){this._removeGlobalFilter=e}removeAsWordFrom(e){if(this.isEmpty())return e;let t=RegExp("(^|\\s)"+Go(this.get())+"($|\\s)","ug");ret Line truncated
`}),a=a.slice(0,s.autoSuggestMaxItems),a}}function gC(r,e,t,n){let i=u=>Object.values(n.prioritySymbols).some(l=>l.length>0&&u.includes(l)),s=[];if(r.includes(n.dueDateSymbol)||s.push({displayText:`${n.dueDateSymbol} due date`,appendText:`${n.dueDateSymbol} `}),r.includes(n.startDateSymbol)||s.push({displayText:`${n.startDateSymbol} start date`,appendText:`${n.startDateSymbol} `}),r.includes(n.scheduledDateSymbol)||s.push({displayText:`${n.scheduledDateSymbol} scheduled date`,appendText:`${n.scheduledDateSymbol} `}),i(r)||(s.push({displayText:`${n.prioritySymbols.High} high priority`,appendText:`${n.prioritySymbols.High} `}),s.push({displayText:`${n.prioritySymbols.Medium} medium priority`,appendText:`${n.prioritySymbols.Medium} `}),s.push({displayText:`${n.prioritySymbols.Low} low priority`,appendText:`${n.prioritySymbols.Low} `}),s.push({displayText:`${n.prioritySymbols.Highest} highest priority`,appendText:`${n.prioritySymbols.Highest} `}),s.push({displayText:`${n.prioritySymbols.Lowest} lowest priority`,appendText:`${n.prioritySymbols.Lowest} `})),r.includes(n.recurrenceSymbol)||s.push({displayText:`${n.recurrenceSymbol} recurring (repeat)`,appendText:`${n.recurrenceSymbol} `}),!r.includes(n.createdDateSymbol)){let l=Nt.parseDate("today",!0).format(V.dateFormat);s.push({textToMatch:`${n.createdDateSymbol} created`,displayText:`${n.createdDateSymbol} created today (${l})`,appendText:`${n.createdDateSymbol} ${l} `})}let a=Zf(r,/([a-zA-Z'_-]*)/g,e),o=[];if(a&&a.length>0){let u=a[0];if(u.length>=Math.max(1,t.autoSuggestMinMatch)){let l=s.filter(c=>(c.textToMatch||c.displayText).toLowerCase().includes(u.toLowerCase()));for(let c of l)o.push({suggestionType:"match",displayText:c.displayText,appendText:c.appendText,insertAt:a.index,insertSkip:u.length})}}return o.length===0&&t.autoSuggestMinMatch===0?s:o}function yC(r,e,t,n,i){let s=["today","tomorrow","Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","next week","next month","next year"],a=[],o=new RegExp(`(${n})\\s*([0-9a-zA-Z ]*)`,"ug"),u=Zf(r,o,e);if(u&&u.length>=2){let l=u[1],c=u[2];if(c.length<t.autoSuggestMinMatch)return[];let f=c&&c.length>1?Nt.parseDate(Si(c),!0):null;f&&f.isValid()&&a.push({displayText:`${f.format(V.dateFormat)}`,appendText:`${l} ${f.format(V.dateFormat)} `,insertAt:u.index,insertSkip:u[0].length});let h=1,T=s.filter(y=>c&&c.length>=h&&y.toLowerCase().includes(c.toLowerCase())).slice(0,i);T.length===0&&(T=s.slice(0,i));for(let y of T){let D=`${Nt.parseDate(y,!0).format(V.dateFormat)}`;a.push({suggestionType:"match",displayText:`${y} (${D})`,appendText:`${l} ${D} `,insertAt:u.index,insertSkip:u[0].length})}}return a}function TC(r,e,t,n){var u;let i=["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"],s=[],a=new RegExp(`(${n})\\s*([0-9a-zA-Z ]*)`,"ug"),o=Zf(r,a,e);if(o&&o.length>=2){let l=o[1],c=o[2];if(c.length<t.autoSuggestMinMatch)return[];if(c.length>0){let y=(u=et.fromText({recurrenceRuleText:c,startDate:null,scheduledDate:null,dueDate:null}))==null?void 0:u.toText();if(y){let w=`${l} ${y} `;if(s.push({suggestionType:"match",displayText:`\u2705 ${y}`,appendText:w,insertAt:o.index,insertSkip:o[0].length}),o[0]==w)return[]}}let f=1,h=t.autoSuggestMaxItems/2,T=i.filter(y=>c&&c.length>=f&&y.toLowerCase().includes(c.toLowerCase())).slice(0,h);T.length===0&&c.trim().length===0&&(T=i.slice(0,h));for(let y of T)s.push({suggestionType:"match",displayText:`${y}`,appendText:`${l} ${y} `,insertAt:o.index,insertSkip:o[0].length})}return s}function Zf(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}function bC(r,e){if(e.length===0)return!1;let t=Object.fromEntries(e.map(([i,s])=>[i,0])),n=Object.fromEntries(e.map(([i,s])=>[s,i]));for(let i of r)i in t?t[i]++:i in n&&(t[n[i]]=Math.max(0,t[n[i]]-1));return Object.values(t).some(i=>i>0)}function vb(r,e){return(t,n,i)=>bC(t.slice(0,n),e)?r(t,n,i):[]}function wb(r,e){return ge.getInstance().includedIn(r)&&_C(r,e)}function _C(r,e){if(r.length===0)return!1;let t=le.extractTaskComponents(r);if(!t)return!1;let n=t.indentation+t.listMarker+" ["+t.status.symbol+"] ";return e>=n.length}var pn=class{constructor(){this.hidePostponeButton=!1;this.hideTaskCount=!1;this.hideBacklinks=!1;this.hideEditButton=!1;this.hideUrgency=!0;this.shortMode=!1;this.explainQuery=!1}};var $n=class{constructor(){this.hidePriority=!1;this.hideCreatedDate=!1;this.hideStartDate=!1;this.hideScheduledDate=!1;this.hideDoneDate=!1;this.hideDueDate=!1;this.hideRecurrenceRule=!1;this.hideTags=!1}},hn=class{constructor(e,t){this.defaultLayout=["description","priority","recurrenceRule","createdDate","startDate","scheduledDate","dueDate","doneDate","blockLink"];this.hiddenTaskLayoutComponents=[];this.taskListHiddenClasses=[];e?this.options=e:this.options=ne Line truncated
\`\`\`${n}
flowchart LR
classDef TODO stroke:#f33,stroke-width:3px;
classDef DONE stroke:#0c0,stroke-width:3px;
classDef IN_PROGRESS stroke:#fa0,stroke-width:3px;
classDef CANCELLED stroke:#ddd,stroke-width:3px;
classDef NON_TASK stroke:#99e,stroke-width:3px;
${i.join(`
`)}
${s.join(`
`)}
linkStyle default stroke:gray
\`\`\`
`}addEdgeIfNotToInternal(e,t,n,i,s){let a=e.findIndex(l=>l.symbol===t.symbol),o=a!==-1,u=t.type!=="EMPTY";if(o&&u){let l;s?l='-. "\u{1F501}" .-> ':l=" --> ";let c=`${i+1}${l}${a+1}`;n.push(c)}}getMermaidNodeLabel(e,t){let n=Db(e.name),i=e.type;if(t){let s=Ho(e.symbol),a=Ho(e.nextStatusSymbol),o=`[${s}] -> [${a}]`,u=`'${n}'`,l=`(${i})`;return`["${u}<br>${o}<br>${l}"]:::${i}`}else return`["${n}"]:::${i}`}};var lr=class{static calculate(e){let t=0;if(e.dueDate!==null){let n=window.moment().startOf("day"),i=Math.round(n.diff(e.dueDate)/lr.milliSecondsPerDay),s;i>=7?s=1:i>=-14?s=(i+14)*.8/21+.2:s=.2,t+=s*lr.dueCoefficient}switch(e.scheduledDate!==null&&window.moment().isSameOrAfter(e.scheduledDate)&&(t+=1*lr.scheduledCoefficient),e.startDate!==null&&window.moment().isBefore(e.startDate)&&(t+=1*lr.startedCoefficient),e.priority){case"0":t+=1.5*lr.priorityCoefficient;break;case"1":t+=1*lr.priorityCoefficient;break;case"2":t+=.65*lr.priorityCoefficient;break;case"3":t+=.325*lr.priorityCoefficient;break;case"5":t-=.3*lr.priorityCoefficient;break}return t}},zr=lr;zr.dueCoefficient=12,zr.scheduledCoefficient=5,zr.startedCoefficient=-3,zr.priorityCoefficient=6,zr.milliSecondsPerDay=1e3*60*60*24;var ht=class{static fromPath(e){let{useFilenameAsScheduledDate:t,filenameAsDateFolders:n}=Q();return!t||!this.matchesAnyFolder(n,e)?null:this.extractDateFromPath(e)}static matchesAnyFolder(e,t){return e.length===0?!0:e.some(n=>t.startsWith(n+"/"))}static extractDateFromPath(e){let t=Math.max(0,e.lastIndexOf("/")+1),n=e.lastIndexOf("."),i=e.substring(t,n),s=/(\d{4})-(\d{2})-(\d{2})/.exec(i);if(s||(s=/(\d{4})(\d{2})(\d{2})/.exec(i)),s){let a=window.moment([parseInt(s[1]),parseInt(s[2])-1,parseInt(s[3])]);if(a.isValid())return a}return null}static canApplyFallback({startDate:e,scheduledDate:t,dueDate:n}){return e===null&&n===null&&t===null}static updateTaskPath(e,t,n){let i=e.scheduledDate,s=e.scheduledDateIsInferred;return n===null?s&&(s=!1,i=null):s?i=n:this.canApplyFallback(e)&&(i=n,s=!0),new le(it(we({},e),{taskLocation:e.taskLocation.fromRenamedFile(t),scheduledDate:i,scheduledDateIsInferred:s}))}static removeInferredStatusIfNeeded(e,t){let n=e.scheduledDateIsInferred?e.scheduledDate:null;return t.map(i=>(n!==null&&!n.isSame(i.scheduledDate,"day")&&(i=new le(it(we({},i),{scheduledDateIsInferred:!1}))),i))}};var xb=require("obsidian");var Vr=class{constructor(e,t){this.name=e,this.sortOrder=t}get groupText(){return this.name!==""?`%%${this.sortOrder}%% ${this.name}`:""}};var rt=class{constructor(e){this._date=null;this._date=e}get moment(){return this._date}formatAsDate(e=""){return this.format(V.dateFormat,e)}formatAsDateAndTime(e=""){return this.format(V.dateTimeFormat,e)}format(e,t=""){return this._date?this._date.format(e):t}toISOString(e){return this._date?this._date.toISOString(e):""}get category(){let e=window.moment(),t=this.moment;return t?t.isBefore(e,"day")?new Vr("Overdue",1):t.isSame(e,"day")?new Vr("Today",2):new Vr("Future",3):new Vr("Undated",4)}get fromNow(){let e=this.moment;if(!e)return new Vr("",0);let t=this.fromNowOrder(e);return new Vr(e.fromNow(),t)}fromNowOrder(e){let t=window.moment(),n=e.isSameOrBefore(t,"day"),i=this.fromNowStartDateOfGroup(e,n,t);return Number((n?1:3)+i.format("YYYYMMDD"))}fromNowStartDateOfGroup(e,t,n){let i=e.fromNow(!0).split(" "),s,a=Number(i[0]);isNaN(a)?s=1:s=a;let o=i[1];return t?n.subtract(s,o):n.add(s,o)}postpone(e="days",t=1){if(!this._date)throw new xb.Notice("Cannot postpone a null date");let n=window.moment().startOf("day");return this._date.isSameOrAfter(n,"day")?this._date.clone().add(t,e):n.add(t,e)}};var Ci=class{constructor(e){this._path=e}get path(){return this._path}get pathWithoutExtension(){return this.withoutExtension(this.path)}withoutExtension(e){return e.replace(/\.md$/,"")}get root(){let e=this.path.replace(/\\/g,"/");e.charAt(0)==="/"&&(e=e.substring(1));let t=e.indexOf("/");return t==-1?"/":e.substring(0,t+1)}get folder(){let e=this.path,t=this.filename,n=e.substring(0,e.lastIndexOf(t));return n===""?"/":n}get filename(){let e=this.path.match(/([^/]+)$/);return e!==null?e[1]:""}get filenameWithoutExtension(){return this.withoutExtension(this.filename)}};var Kr=class{static priorityNameUsingNone(e){let t="ERROR";switch(e){case"1":t="High";break;case"0":t="Highest";break;case"2":t="Medium";break;case"3":t="None";break;case"4":t="Low";break;case"5":t="Lowest";break}return t}static priorityNameUsingNormal(e){return Kr.priorityNameUsingNone(e).replace("None","Normal")}};var wC=require("obsidian"),Ab=us(Cb());var tp=class extends Ab.EventEmitter2{constructor(){super(...arguments);this.options={minLevels:{"":"info",tasks:"info"}};this.consoleLoggerRegistered=!1;this.arrAvg=t=>t.reduce((n,i)=>n+i,0)/t.length}configure(t){return this.options=Object.assign({},this.options,t),this}getLogger(t){let n="none",i="";for(let s in this.options.minLevels)t.startsWith(s)&&s.length>=i.length&&(n=this.options.minLevels[s],i=s);return new rp(this,t,n)}onLogEntry(t){return thi Line truncated
`),o=a.length,u=new ba(()=>ht.fromPath(i.path)),l=null,c=0;for(let f of t)if(f.task!==void 0){let h=f.position.start.line;if(h>=o)return this.logger.debug(`${i.path} Obsidian gave us a line number ${h} past the end of the file. ${o}.`),s;if((l===null||l.position.end.line<h)&&(l=Bn.getSection(h,n.sections),c=0),l===null)continue;let T=a[h];if(T===void 0){this.logger.debug(`${i.path}: line ${h} - ignoring 'undefined' line.`);continue}let y;try{y=le.fromLine({line:T,taskLocation:new ct(i.path,h,l.position.start.line,c,Bn.getPrecedingHeader(h,n.headings)),fallbackDate:u.value})}catch(w){this.reportTaskParsingErrorToUser(w,i,f,T);continue}y!==null&&(c++,s.push(y))}return s}reportTaskParsingErrorToUser(e,t,n,i){let s=`There was an error reading one of the tasks in this vault.
The following task has been ignored, to prevent Tasks queries getting stuck with 'Loading Tasks ...'
Error: ${e}
File: ${t.path}
Line number: ${n.position.start.line}
Task line: ${i}
Please create a bug report for this message at
https://github.com/obsidian-tasks-group/obsidian-tasks/issues/new/choose
to help us find and fix the underlying issue.
Include:
- either a screenshot of the error popup, or copy the text from the console, if on a desktop machine.
- the output from running the Obsidian command 'Show debug info'
The error popup will only be shown when Tasks is starting up, but if the error persists,
it will be shown in the console every time this file is edited during the Obsidian
session.
`;this.logger.error(s),e instanceof Error&&this.logger.error(e.stack?e.stack:"Cannot determine stack"),this.state==="Initializing"&&new Ai.Notice(s,1e4)}static getSection(e,t){if(t===void 0)return null;for(let n of t)if(n.position.start.line<=e&&n.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 hp=require("obsidian");var Qb=require("obsidian");function Qr(){}function ap(r){return r()}function Pb(){return Object.create(null)}function zn(r){r.forEach(ap)}function Ko(r){return typeof r=="function"}function Ib(r,e){return r!=r?e==e:r!==e||r&&typeof r=="object"||typeof r=="function"}function Fb(r){return Object.keys(r).length===0}var Lb=typeof window!="undefined"?window:typeof globalThis!="undefined"?globalThis:global,va=class{constructor(e){this.options=e,this._listeners="WeakMap"in Lb?new WeakMap:void 0}observe(e,t){return this._listeners.set(e,t),this._getObserver().observe(e,this.options),()=>{this._listeners.delete(e),this._observer.unobserve(e)}}_getObserver(){var e;return(e=this._observer)!==null&&e!==void 0?e:this._observer=new ResizeObserver(t=>{var n;for(let i of t)va.entries.set(i.target,i),(n=this._listeners.get(i.target))===null||n===void 0||n(i)})}};va.entries="WeakMap"in Lb?new WeakMap:void 0;var Ub=!1;function kC(){Ub=!0}function SC(){Ub=!1}function R(r,e){r.appendChild(e)}function Fi(r,e,t){r.insertBefore(e,t||null)}function Vn(r){r.parentNode&&r.parentNode.removeChild(r)}function op(r,e){for(let t=0;t<r.length;t+=1)r[t]&&r[t].d(e)}function K(r){return document.createElement(r)}function OC(r){return document.createElementNS("http://www.w3.org/2000/svg",r)}function mt(r){return document.createTextNode(r)}function pe(){return mt(" ")}function Ot(r,e,t,n){return r.addEventListener(e,t,n),()=>r.removeEventListener(e,t,n)}function qb(r){return function(e){return e.preventDefault(),r.call(this,e)}}function U(r,e,t){t==null?r.removeAttribute(e):r.getAttribute(e)!==t&&r.setAttribute(e,t)}function Wb(r){let e;return{p(...t){e=t,e.forEach(n=>r.push(n))},r(){e.forEach(t=>r.splice(r.indexOf(t),1))}}}function DC(r){return Array.from(r.childNodes)}function up(r,e){e=""+e,r.data!==e&&(r.data=e)}function cr(r,e){r.value=e==null?"":e}function lp(r,e,t){for(let n=0;n<r.options.length;n+=1){let i=r.options[n];if(i.__value===e){i.selected=!0;return}}(!t||e!==void 0)&&(r.selectedIndex=-1)}function $b(r){let e=r.querySelector(":checked");return e&&e.__value}function dr(r,e,t){r.classList[t?"add":"remove"](e)}var Hn=class{constructor(e=!1){this.is_svg=!1,this.is_svg=e,this.e=this.n=null}c(e){this.h(e)}m(e,t,n=null){this.e||(this.is_svg?this.e=OC(t.nodeName):this.e=K(t.nodeType===11?"TEMPLATE":t.nodeName),this.t=t.tagName!=="TEMPLATE"?t:t.content,this.c(e)),this.i(n)}h(e){this.e.innerHTML=e,this.n=Array.from(this.e.nodeName==="TEMPLATE"?this.e.content.childNodes:this.e.childNodes)}i(e){for(let t=0;t<this.n.length;t+=1)Fi(this.t,this.n[t],e)}p(e){this.d(),this.h(e),this.i(this.a)}d(){this.n.forEach(Vn)}};var wa;function _a(r){wa=r}function xC(){if(!wa)throw new Error("Function called outside component initialization");return wa}function cp(r){xC().$$.on_mount.push(r)}var Ni=[];var Qo=[],Ii=[],Nb=[],RC=Promise.resolve(),sp=!1;function MC(){sp||(sp=!0,RC.then(Yb))}function Ea(r){Ii.push(r)}var ip=new Set,Pi=0;function Yb(){if(Pi!==0)return;let r=wa;do{try{for(;Pi<Ni.length;){let e=Ni[Pi];Pi++,_a(e),CC(e.$$)}}catch(e){throw Ni.length=0,Pi=0,e}for(_a(null),Ni.length=0,Pi=0;Qo.length;)Qo.pop()();for(let e=0;e<Ii.length;e+=1){let t=Ii[e];ip.has(t)||(ip.add(t),t())}Ii.length=0}while(Ni.length);for(;Nb.length;)Nb.pop()();sp=!1,ip.clear(),_a(r)}function CC(r){if(r.fragment!==null){r.update(),zn(r.before_update);let e=r.dirty;r.dirty=[-1],r.fragment&&r.fragment.p(r.ctx,e),r.after_update.forEach(Ea)}}function AC(r){let e=[],t=[];Ii.forEach(n=>r.indexOf(n)===-1?e.push(n):t.push(n)),t.forEach(n=>n()),Ii=e}var PC=new Set;function NC(r,e){r&&r.i&&(PC.delete(r),r.i(e))}var IC=["allowfullscreen","allowpaymentrequest","async","autofocus","autoplay","checked","controls","default","defer","disabled","formnovalidate","hidden","inert","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","selected"],UU=new Set([...IC]);function FC(r,e,t,n){let{fragment:i,after_update:s}=r.$$;i&&i.m(e,t),n||Ea(()=>{let a=r.$$.on_mount.map(ap).filter(Ko);r.$$.on_destroy?r.$$.on_destroy.push(...a):zn(a),r.$$.on_mount=[]}),s.forEach(Ea)}function Gb(r,e){let t=r.$$;t.fragment!==null&&(AC(t.after_update),zn(t.on_destroy),t.fragment&&t.fragment.d(e),t.on_destroy=t.fragment=null,t.ctx=[])}function LC(r,e){r.$$.dirty[0]===-1&&(Ni.push(r),MC(),r.$$.dirty.fill(0)),r.$$.dirty[e/31|0]|=1<<e%31}function jb(r,e,t,n,i,s,a,o=[-1]){let u=wa;_a(r);let l=r.$$={fragment:null,ctx:[],props:s,update:Qr,not_equal:i,bound:Pb(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],a Line truncated
<span class="accesskey-first">future</span> dates:`,Gp=pe(),mr=K("input"),jp=pe(),si=K("div"),Na=K("label"),Na.innerHTML='Stat<span class="accesskey">u</span>s',Bp=pe(),Gt=K("select");for(let Y=0;Y<vt.length;Y+=1)vt[Y].c();Hp=pe(),en=K("div"),rs=K("div"),Fa=K("label"),Fa.textContent="Completed:",zp=pe(),tn=K("input"),Vp=pe(),ns=K("div"),Hu=K("span"),Hu.textContent="Created on:",Kp=pe(),Ua=K("code"),Qp=pe(),is=K("div"),zu=K("span"),zu.textContent="Done on:",Xp=pe(),qa=K("code"),Zp=pe(),ai=K("div"),Sn=K("button"),Jp=mt("Apply"),eh=pe(),ss=K("button"),ss.textContent="Cancel",U(i,"for","description"),U(a,"id","description"),U(a,"class","tasks-modal-description"),U(a,"placeholder","Take out the trash"),U(a,"accesskey",o=r[15]("t")),U(n,"class","tasks-modal-section"),U(c,"for",h="priority-"+r[1].priority),U(l,"class","tasks-modal-section tasks-modal-priorities"),U(D,"for","recurrence"),U(D,"class","accesskey-first"),U(N,"id","recurrence"),U(N,"type","text"),U(N,"placeholder","Try 'every 2 weeks on Thursday'."),U(N,"accesskey",L=r[15]("r")),dr(N,"tasks-modal-error",!r[8]),j.a=null,U(Le,"for","due"),U(Le,"class","accesskey-first"),U(A,"id","due"),U(A,"type","text"),U(A,"placeholder",dp),U(A,"accesskey",E=r[15]("d")),dr(A,"tasks-modal-error",!r[7]),p.a=null,U(g,"for","scheduled"),U(g,"class","accesskey-first"),U(v,"id","scheduled"),U(v,"type","text"),U(v,"placeholder",dp),U(v,"accesskey",k=r[15]("s")),dr(v,"tasks-modal-error",!r[5]),me.a=null,U(te,"for","start"),U(q,"id","start"),U(q,"type","text"),U(q,"placeholder",dp),U(q,"accesskey",Re=r[15]("a")),dr(q,"tasks-modal-error",!r[3]),Ue.a=null,U(Aa,"for","forwardOnly"),U(mr,"id","forwardOnly"),U(mr,"type","checkbox"),U(mr,"class","task-list-item-checkbox tasks-modal-checkbox"),U(mr,"accesskey",Pa=r[15]("f")),U(w,"class","tasks-modal-section tasks-modal-dates"),U(Na,"for","status"),U(Gt,"id","status-type"),U(Gt,"class","dropdown"),U(Gt,"accesskey",Ia=r[15]("u")),r[1].status===void 0&&Ea(()=>r[39].call(Gt)),U(si,"class","tasks-modal-section"),U(Fa,"for","status"),U(tn,"id","status"),U(tn,"type","checkbox"),U(tn,"class","task-list-item-checkbox tasks-modal-checkbox"),tn.checked=La=r[1].status.isCompleted(),tn.disabled=!0,U(en,"class","tasks-modal-section tasks-modal-status"),Sn.disabled=Wa=!r[14],U(Sn,"type","submit"),U(Sn,"class","mod-cta"),U(ss,"type","button"),U(ai,"class","tasks-modal-section tasks-modal-buttons"),dr(t,"with-accesskeys",r[9]),U(e,"class","tasks-modal")},m(Y,he){Fi(Y,e,he),R(e,t),R(t,n),R(n,i),R(n,s),R(n,a),cr(a,r[1].description),r[31](a),R(t,u),R(t,l),R(l,c),R(c,f),R(l,T);for(let de=0;de<_t.length;de+=1)_t[de]&&_t[de].m(l,null);R(t,y),R(t,w),R(w,D),R(w,C),R(w,N),cr(N,r[1].recurrenceRule),R(w,oe),R(w,z),R(z,ie),R(z,G),j.m(r[12],z),R(w,Ne),R(w,Le),R(w,B),R(w,A),cr(A,r[1].dueDate),R(w,H),R(w,P),R(P,Z),R(P,d),p.m(r[6],P),R(w,m),R(w,g),R(w,b),R(w,v),cr(v,r[1].scheduledDate),R(w,x),R(w,S),R(S,O),R(S,I),me.m(r[4],S),R(w,se),R(w,te),R(w,De),R(w,q),cr(q,r[1].startDate),R(w,Ae),R(w,nt),R(nt,Mr),R(nt,We),Ue.m(r[2],nt),R(w,Yp),R(w,ts),R(ts,Aa),R(ts,Gp),R(ts,mr),mr.checked=r[1].forwardOnly,R(t,jp),R(t,si),R(si,Na),R(si,Bp),R(si,Gt);for(let de=0;de<vt.length;de+=1)vt[de]&&vt[de].m(Gt,null);lp(Gt,r[1].status,!0),R(t,Hp),R(t,en),R(en,rs),R(rs,Fa),R(rs,zp),R(rs,tn),R(en,Vp),R(en,ns),R(ns,Hu),R(ns,Kp),R(ns,Ua),Ua.innerHTML=r[11],R(en,Qp),R(en,is),R(is,zu),R(is,Xp),R(is,qa),qa.innerHTML=r[13],R(t,Zp),R(t,ai),R(ai,Sn),R(Sn,Jp),R(ai,eh),R(ai,ss),Vu||(th=[Ot(a,"input",r[30]),Ot(a,"keydown",r[23]),Ot(a,"paste",r[24]),Ot(a,"drop",r[24]),Ot(l,"keyup",r[21]),Ot(N,"input",r[34]),Ot(A,"input",r[35]),Ot(v,"input",r[36]),Ot(q,"input",r[37]),Ot(mr,"change",r[38]),Ot(Gt,"change",r[39]),Ot(ss,"click",r[22]),Ot(t,"submit",qb(r[25]))],Vu=!0)},p(Y,he){if(he[0]&32768&&o!==(o=Y[15]("t"))&&U(a,"accesskey",o),he[0]&3&&cr(a,Y[1].description),he[0]&3&&h!==(h="priority-"+Y[1].priority)&&U(c,"for",h),he[0]&1081346){oi=Y[20];let de;for(de=0;de<oi.length;de+=1){let as=Hb(Y,oi,de);_t[de]?_t[de].p(as,he):(_t[de]=zb(as),_t[de].c(),_t[de].m(l,null))}for(;de<_t.length;de+=1)_t[de].d(1);_t.length=oi.length}if(he[0]&32768&&L!==(L=Y[15]("r"))&&U(N,"accesskey",L),he[0]&3&&N.value!==Y[1].recurrenceRule&&cr(N,Y[1].recurrenceRule),he[0]&256&&dr(N,"tasks-modal-error",!Y[8]),he[0]&4096&&j.p(Y[12]),he[0]&32768&&E!==(E=Y[15]("d"))&&U(A,"accesskey",E),he[0]&3&&A.value!==Y[1].dueDate&&cr(A,Y[1].dueDate),he[0]&128&&dr(A,"tasks-modal-error",!Y[7]),he[0]&64&&p.p(Y[6]),he[0]&32768&&k!==(k=Y[15]("s"))&&U(v,"accesskey",k),he[0]&3&&v.value!==Y[1].scheduledDate&&cr(v,Y[1].scheduledDate),he[0]&32&&dr(v,"tasks-modal-error",!Y[5]),he[0]&16&&me.p(Y[4]),he[0]&32768&&Re!==(Re=Y[15]("a"))&&U(q,"accesskey",Re),he[0]&3&&q.value!==Y[1].startDate&&cr(q,Y[1].startDate),he[0]&8&&dr(q,"tasks-modal-error",!Y[3]),he[0]&4&&Ue.p(Y[2]),he[0]&32768&&Pa!==(Pa=Y[15]("f"))&&U(mr,"accesskey",Pa),he[0]&3&&(mr.checked=Y[1].forwardOnly),he[0]&1){ui=Y[0];let de;for(de=0;de<ui.length;de+=1){let as=Bb(Y,ui,de);vt[de]?vt[de].p(as,Line truncated
`);e.setLine(a,T)};new gn({app:n,task:u,onSubmit:l}).open()};var mp=require("obsidian");var Zb=(r,e,t)=>{var u;if(r)return t instanceof mp.MarkdownView;if(!(t instanceof mp.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=jC(a,n);e.setLine(s,o.text),e.setCursor(BC(i,o))},jC=(r,e)=>{let t=le.fromLine({line:r,taskLocation:ct.fromUnknownPosition(e),fallbackDate:null});if(t!==null){let n=t.toggleWithRecurrenceInUsersOrder().map(i=>i.toFileLineString());return{text:n.join(`
`),moveTo:{line:n.length-1}}}else{let n=r.match(V.taskRegex);if(n!==null){let i=n[3],a=ve.getInstance().bySymbol(i).nextStatusSymbol;return{text:r.replace(V.taskRegex,`$1- [${a}] $4`)}}else if(V.listItemRegex.test(r)){let i=r.replace(V.listItemRegex,"$1$2 [ ]");return{text:i,moveTo:{ch:i.length}}}else{let i=r.replace(V.indentationRegex,"$1- ");return{text:i,moveTo:{ch:i.length}}}}},BC=(r,e)=>{var s;let t={line:0,ch:r.ch},n=we(we({},t),(s=e.moveTo)!=null?s:{}),i=e.text.split(`
`)[n.line].length;return{line:r.line+n.line,ch:Math.min(n.ch,i)}};var Jo=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)=>Xb(t,n,i,this.app)}),e.addCommand({id:"toggle-done",name:"Toggle task done",icon:"check-in-circle",editorCheckCallback:Zb})}};var HC=Object.prototype.toString,Ui=Array.isArray||function(e){return HC.call(e)==="[object Array]"};function yp(r){return typeof r=="function"}function zC(r){return Ui(r)?"array":typeof r}function gp(r){return r.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function Jb(r,e){return r!=null&&typeof r=="object"&&e in r}function VC(r,e){return r!=null&&typeof r!="object"&&r.hasOwnProperty&&r.hasOwnProperty(e)}var KC=RegExp.prototype.test;function QC(r,e){return KC.call(r,e)}var XC=/\S/;function ZC(r){return!QC(XC,r)}var JC={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;","`":"&#x60;","=":"&#x3D;"};function eA(r){return String(r).replace(/[&<>"'`=\/]/g,function(t){return JC[t]})}var tA=/\s*/,rA=/\s+/,e_=/\s*=/,nA=/\s*\}/,iA=/#|\^|\/|>|\{|&|=|!/;function sA(r,e){if(!r)return[];var t=!1,n=[],i=[],s=[],a=!1,o=!1,u="",l=0;function c(){if(a&&!o)for(;s.length;)delete i[s.pop()];else s=[];a=!1,o=!1}var f,h,T;function y(j){if(typeof j=="string"&&(j=j.split(rA,2)),!Ui(j)||j.length!==2)throw new Error("Invalid tags: "+j);f=new RegExp(gp(j[0])+"\\s*"),h=new RegExp("\\s*"+gp(j[1])),T=new RegExp("\\s*"+gp("}"+j[1]))}y(e||Jt.tags);for(var w=new Sa(r),D,C,N,L,oe,z;!w.eos();){if(D=w.pos,N=w.scanUntil(f),N)for(var ie=0,G=N.length;ie<G;++ie)L=N.charAt(ie),ZC(L)?(s.push(i.length),u+=L):(o=!0,t=!0,u+=" "),i.push(["text",L,D,D+1]),D+=1,L===`
`&&(c(),u="",l=0,t=!1);if(!w.scan(f))break;if(a=!0,C=w.scan(iA)||"name",w.scan(tA),C==="="?(N=w.scanUntil(e_),w.scan(e_),w.scanUntil(h)):C==="{"?(N=w.scanUntil(T),w.scan(nA),w.scanUntil(h),C="&"):N=w.scanUntil(h),!w.scan(h))throw new Error("Unclosed tag at "+w.pos);if(C==">"?oe=[C,N,D,w.pos,u,l,t]:oe=[C,N,D,w.pos],l++,i.push(oe),C==="#"||C==="^")n.push(oe);else if(C==="/"){if(z=n.pop(),!z)throw new Error('Unopened section "'+N+'" at '+D);if(z[1]!==N)throw new Error('Unclosed section "'+z[1]+'" at '+D)}else C==="name"||C==="{"||C==="&"?o=!0:C==="="&&y(N)}if(c(),z=n.pop(),z)throw new Error('Unclosed section "'+z[1]+'" at '+w.pos);return oA(aA(i))}function aA(r){for(var e=[],t,n,i=0,s=r.length;i<s;++i)t=r[i],t&&(t[0]==="text"&&n&&n[0]==="text"?(n[1]+=t[1],n[3]=t[3]):(e.push(t),n=t));return e}function oA(r){for(var e=[],t=e,n=[],i,s,a=0,o=r.length;a<o;++a)switch(i=r[a],i[0]){case"#":case"^":t.push(i),n.push(i),t=i[4]=[];break;case"/":s=n.pop(),s[5]=i[2],t=n.length>0?n[n.length-1][4]:e;break;default:t.push(i)}return e}function Sa(r){this.string=r,this.tail=r,this.pos=0}Sa.prototype.eos=function(){return this.tail===""};Sa.prototype.scan=function(e){var t=this.tail.match(e);if(!t||t.index!==0)return"";var n=t[0];return this.tail=this.tail.substring(n.length),this.pos+=n.length,n};Sa.prototype.scanUntil=function(e){var t=this.tail.search(e),n;switch(t){case-1:n=this.tail,this.tail="";break;case 0:n="";break;default:n=this.tail.substring(0,t),this.tail=this.tail.substring(t)}return this.pos+=n.length,n};function Li(r,e){this.view=r,this.cache={".":this.view},this.parent=e}Li.prototype.push=function(e){return new Li(e,this)};Li.prototype.lookup=function(e){var t=this.cache,n;if(t.hasOwnProperty(e))n=t[e];else{for(var i=this,s,a,o,u=!1;i;){if(e.indexOf(".")>0)for(s=i.view,a=e.split("."),o=0;s!=null&&o<a.length;)o===a.length-1&&(u=Jb(s,a[o])||VC(s,a[o])),s=s[a[o++]];else s=i.view[e],u=Jb(i.view,e);if(u){n=s;break}i=i.parent}t[e]=n}return yp(n)&&(n=n.call(this.view)),n};function Dt(){this.templateCache={_cache:{},set:function(e,t){this._cache[e]=t},get:function(e){return this._cache[e]},clear:function(){this._cache={}}}}Dt.prototype.clearCache=function(){typeof this.templateCache!="undefined"&&this.templateCache.clear()};Dt.prototype.parse=function(e,t){var n=this.templateCache,i=e+":"+(t||Jt.tags).join(":"),s=typeof n!="undefined",a=s?n.get(i):void 0;return a==null&&(a=sA(e,t),s&&n.set(i,a)),a};Dt.prototype.render=function(e,t,n,i){var s=this.getConfigTags(i),a=this.parse(e,s),o=t instanceof Li?t:new Li(t,void 0);return this.renderTokens(a,o,n,e,i)};Dt.prototype.renderTokens=function(e,t,n,i,s){for(var a="",o,u,l,c=0,f=e.length;c<f;++c)l=void 0,o=e[c],u=o[0],u==="#"?l=this.renderSection(o,t,n,i,s):u==="^"?l=this.renderInverted(o,t,n,i,s):u===">"?l=this.renderPartial(o,t,n,s):u==="&"?l=this.unescapedValue(o,t):u==="name"?l=this.escapedValue(o,t,s):u==="text"&&(l=this.rawValue(o)),l!==void 0&&(a+=l);return a};Dt.prototype.renderSection=function(e,t,n,i,s){var a=this,o="",u=t.lookup(e[1]);function l(h){return a.render(h,t,n,s)}if(!!u){if(Ui(u))for(var c=0,f=u.length;c<f;++c)o+=this.renderTokens(e[4],t.push(u[c]),n,i,s);else if(typeof u=="object"||typeof u=="string"||typeof u=="number")o+=this.renderTokens(e[4],t.push(u),n,i,s);else if(yp(u)){if(typeof i!="string")throw new Error("Cannot use higher-order sections without the original template");u=u.call(t.view,i.slice(e[3],e[5]),l),u!=null&&(o+=u)}else o+=this.renderTokens(e[4],t,n,i,s);return o}};Dt.prototype.renderInverted=function(e,t,n,i,s){var a=t.lookup(e[1]);if(!a||Ui(a)&&a.length===0)return this.renderTokens(e[4],t,n,i,s)};Dt.prototype.indentPartial=function(e,t,n){for(var i=t.replace(/[^ \t]/g,""),s=e.split(`
`),a=0;a<s.length;a++)s[a].length&&(a>0||!n)&&(s[a]=i+s[a]);return s.join(`
`)};Dt.prototype.renderPartial=function(e,t,n,i){if(!!n){var s=this.getConfigTags(i),a=yp(n)?n(e[1]):n[e[1]];if(a!=null){var o=e[6],u=e[5],l=e[4],c=a;u==0&&l&&(c=this.indentPartial(a,l,o));var f=this.parse(c,s);return this.renderTokens(f,t,n,c,i)}}};Dt.prototype.unescapedValue=function(e,t){var n=t.lookup(e[1]);if(n!=null)return n};Dt.prototype.escapedValue=function(e,t,n){var i=this.getConfigEscape(n)||Jt.escape,s=t.lookup(e[1]);if(s!=null)return typeof s=="number"&&i===Jt.escape?String(s):i(s)};Dt.prototype.rawValue=function(e){return e[1]};Dt.prototype.getConfigTags=function(e){return Ui(e)?e:e&&typeof e=="object"?e.tags:void 0};Dt.prototype.getConfigEscape=function(e){if(e&&typeof e=="object"&&!Ui(e))return e.escape};var Jt={name:"mustache.js",version:"4.2.0",tags:["{{","}}"],clearCache:void 0,escape:void 0,parse:void 0,render:void 0,Scanner:void 0,Context:void 0,Writer:void 0,set templateCache(r){ka.templateCache=r},get templateCache(){return ka.templateCache}},ka=new Dt;Jt.clearCache=function(){return ka.clearCache()};Jt.parse=function(e,t){return ka.parse(e,t)};Jt.render=function(e,t,n,i){if(typeof e!="string")throw new TypeError('Invalid template! Template should be a "string" but "'+zC(e)+'" was given as the first argument for mustache#render(template, view, partials)');return ka.render(e,t,n,i)};Jt.escape=eA;Jt.Scanner=Sa;Jt.Context=Li;Jt.Writer=Dt;var Tp=Jt;var s_=us(i_());function a_(r,e){Tp.escape=function(t){return t};try{return Tp.render(r,(0,s_.default)(e))}catch(t){let n="";throw t instanceof Error?n=`There was an error expanding one or more placeholders.
The error message was:
${t.message.replace(/ > /g,".").replace("Missing Mustache data property","Unknown property")}`:n="Unknown error expanding placeholders.",n+=`
The problem is in:
${r}`,Error(n)}}function eu(r){return{query:{file:new Ci(r)}}}function Kn(r,e){let t=`Error: ${r}.
The error message was:
`,n="";return e instanceof Error?n+=e:n+="Unknown error",`${t}"${n}"`}var Xr=class{constructor(e,t,n,i){this.instruction=e,this.property=t,this.comparator=Xr.maybeReverse(i,n)}static maybeReverse(e,t){return e?Xr.makeReversedComparator(t):t}static makeReversedComparator(e){return(t,n)=>e(t,n)*-1}};var yn=class{constructor(e,t,n,i){this.instruction=e,this.property=t,this.grouper=n,this.reverse=i}};var ke=class{canCreateFilterForLine(e){return ke.lineMatchesFilter(this.filterRegExp(),e)}static lineMatchesFilter(e,t){return e?e.test(t):!1}static getMatch(e,t){return e?t.match(e):null}fieldNameSingular(){return this.fieldName()}fieldNameSingularEscaped(){return Go(this.fieldNameSingular())}supportsSorting(){return!1}createSorterFromLine(e){if(!this.supportsSorting())return null;let t=ke.getMatch(this.sorterRegExp(),e);if(t===null)return null;let n=!!t[1];return this.createSorter(n)}sorterRegExp(){if(!this.supportsSorting())throw Error(`sorterRegExp() unimplemented for ${this.fieldNameSingular()}`);return new RegExp(`^sort by ${this.fieldNameSingularEscaped()}( reverse)?`,"i")}sorterInstruction(e){let t=`sort by ${this.fieldNameSingular()}`;return e&&(t+=" reverse"),t}comparator(){throw Error(`comparator() unimplemented for ${this.fieldNameSingular()}`)}createSorter(e){return new Xr(this.sorterInstruction(e),this.fieldNameSingular(),this.comparator(),e)}createNormalSorter(){return this.createSorter(!1)}createReverseSorter(){return this.createSorter(!0)}supportsGrouping(){return!1}createGrouperFromLine(e){if(!this.supportsGrouping())return null;let t=ke.getMatch(this.grouperRegExp(),e);if(t===null)return null;let n=!!t[1];return this.createGrouper(n)}grouperRegExp(){if(!this.supportsGrouping())throw Error(`grouperRegExp() unimplemented for ${this.fieldNameSingular()}`);return new RegExp(`^group by ${this.fieldNameSingularEscaped()}( reverse)?$`,"i")}grouperInstruction(e){let t=`group by ${this.fieldNameSingular()}`;return e&&(t+=" reverse"),t}grouper(){throw Error(`grouper() unimplemented for ${this.fieldNameSingular()}`)}createGrouper(e){return new yn(this.grouperInstruction(e),this.fieldNameSingular(),this.grouper(),e)}createNormalGrouper(){return this.createGrouper(!1)}createReverseGrouper(){return this.createGrouper(!0)}};var Se=class{constructor(e,t=[],n=""){this.description=e,this.symbol=n,this.children=t}static booleanAnd(e){return this.combineOrCreateExplanation("All of",e,"AND")}static booleanOr(e){return this.combineOrCreateExplanation("At least one of",e,"OR")}static booleanNot(e){return new Se("None of",e,"NOT")}static booleanXor(e){return new Se("Exactly one of",e,"XOR")}asString(e=""){if(this.children.length==0)return e+this.description;let t=e;this.symbol===""?t+=this.description:(t+=this.symbol,this.children.length>1&&(t+=` (${this.description})`),t+=":");let n=e+" ";for(let i=0;i<this.children.length;i++)t+=`
${this.children[i].asString(n)}`;return t}static combineOrCreateExplanation(e,t,n){if(t.length===2){let i=t[0],s=t[1];if(i.symbol===n&&s.symbol==="")return i.children.push(s),i}return new Se(e,t,n)}};var gt=class{constructor(e,t,n){this.instruction=e,this.explanation=n,this.filterFunction=t}explainFilterIndented(e){let t=this.explanation;return t.asString()===this.instruction?`${e}${this.instruction}
`:`${e}${this.instruction} =>
${t.asString(e+" ")}
`}};var Er=class{constructor(e){this.instruction=e}get queryComponent(){return this._queryComponent}set queryComponent(e){this._queryComponent=e}get error(){return this._error}set error(e){this._error=e}static fromObject(e,t){let n=new Er(e);return n._queryComponent=t,n}static fromError(e,t){let n=new Er(e);return n._error=t,n}};var J=class{constructor(e){this.object=e}get instruction(){return this.object.instruction}get filter(){return this.object.queryComponent}get error(){return this.object.error}get filterFunction(){if(this.filter)return this.filter.filterFunction}static fromFilter(e){return new J(Er.fromObject(e.instruction,e))}static fromError(e,t){return new J(Er.fromError(e,t))}};var tu=class{constructor(e,t){this._instruction=e,this._filter=t}canCreateFilterForLine(e){return e.toLocaleLowerCase()===this._instruction.toLocaleLowerCase()}createFilterOrErrorMessage(e){return this.canCreateFilterForLine(e)?J.fromFilter(new gt(e,this._filter,new Se(e))):J.fromError(e,`do not understand filter: ${e}`)}};var kr=class{constructor(){this._filters=[]}add(e,t){this._filters.push(new tu(e,t))}canCreateFilterForLine(e){for(let t of this._filters)if(t.canCreateFilterForLine(e))return!0;return!1}createFilterOrErrorMessage(e){for(let t of this._filters){let n=t.createFilterOrErrorMessage(e);if(n.error===void 0)return n}return J.fromError(e,`do not understand filter: ${e}`)}};var Tn=class extends ke{constructor(){super(...arguments);this._filters=new kr}canCreateFilterForLine(t){return this._filters.canCreateFilterForLine(t)}createFilterOrErrorMessage(t){return this._filters.createFilterOrErrorMessage(t)}filterRegExp(){return null}};var Sr=class extends Tn{constructor(){super(),this._filters.add("done",e=>e.isDone),this._filters.add("not done",e=>!e.isDone)}fieldName(){return"status"}supportsSorting(){return!0}comparator(){return(e,t)=>{let n=Sr.oldStatusName(e),i=Sr.oldStatusName(t);return n<i?1:n>i?-1:0}}static oldStatusName(e){return e.status.symbol===" "?"Todo":"Done"}supportsGrouping(){return!0}grouper(){return e=>[Sr.oldStatusName(e)]}};var ru=class{findUnexpandedDateText(e){let t=["<%","YYYY-MM-DD"];for(let n of t)if(e.includes(n))return this.unexpandedDateTextMessage(n);return null}unexpandedDateTextMessage(e){return`Instruction contains unexpanded template text: "${e}" - and cannot be interpreted.
Possible causes:
- The query is an a template file, and is not intended to be searched.
- A command such as "Replace templates in the active file" needs to be run.
- The core "Daily notes" plugin is in use, and the template contained
date calculations that it does not support.
- Some sample template text was accidentally pasted in to a tasks query,
instead of in to a template file.
See: https://publish.obsidian.md/tasks/Advanced/Instruction+contains+unexpanded+template+text
`}};var yt=class extends ke{constructor(t=null){super();t!==null?this.filterInstructions=t:(this.filterInstructions=new kr,this.filterInstructions.add(`has ${this.fieldName()} date`,n=>this.date(n)!==null),this.filterInstructions.add(`no ${this.fieldName()} date`,n=>this.date(n)===null),this.filterInstructions.add(`${this.fieldName()} date is invalid`,n=>{let i=this.date(n);return i!==null&&!i.isValid()}))}canCreateFilterForLine(t){return this.filterInstructions.canCreateFilterForLine(t)?!0:super.canCreateFilterForLine(t)}createFilterOrErrorMessage(t){var h;let n=this.checkForUnexpandedTemplateText(t);if(n)return J.fromError(t,n);let i=this.filterInstructions.createFilterOrErrorMessage(t);if(i.filter!==void 0)return i;let s=ke.getMatch(this.filterRegExp(),t);if(s===null)return J.fromError(t,"do not understand query filter ("+this.fieldName()+" date)");let a=s[1],o=(h=s[2])==null?void 0:h.toLowerCase(),u=s[3],l=Nt.parseDateRange(u);if(!l.isValid()){let T=Nt.parseDate(a);T.isValid()&&(l=new Et(T,T))}if(!l.isValid())return J.fromError(t,"do not understand "+this.fieldName()+" date");let c=this.buildFilterFunction(o,l),f=yt.buildExplanation(this.fieldNameForExplanation(),o,this.filterResultIfFieldMissing(),l);return J.fromFilter(new gt(t,c,f))}buildFilterFunction(t,n){let i;switch(t){case"before":i=s=>s?s.isBefore(n.start):this.filterResultIfFieldMissing();break;case"after":i=s=>s?s.isAfter(n.end):this.filterResultIfFieldMissing();break;case"on or before":case"in or before":i=s=>s?s.isSameOrBefore(n.end):this.filterResultIfFieldMissing();break;case"on or after":case"in or after":i=s=>s?s.isSameOrAfter(n.start):this.filterResultIfFieldMissing();break;default:i=s=>s?s.isSameOrAfter(n.start)&&s.isSameOrBefore(n.end):this.filterResultIfFieldMissing()}return this.getFilter(i)}getFilter(t){return n=>t(this.date(n))}filterRegExp(){return new RegExp(`^${this.fieldNameForFilterInstruction()} (((?:on|in) or before|before|(?:on|in) or after|after|on|in)? ?(.*))`,"i")}fieldNameForFilterInstruction(){return this.fieldName()}static buildExplanation(t,n,i,s){let a=n,o="YYYY-MM-DD (dddd Do MMMM YYYY)",u;switch(n){case"before":case"on or after":u=s.start.format(o);break;case"after":case"on or before":u=s.end.format(o);break;case"in or before":a="on or before",u=s.end.format(o);break;case"in or after":a="on or after",u=s.start.format(o);break;default:if(!s.start.isSame(s.end)){let c=`${t} date is between:`,f=[new Se(`${s.start.format(o)} and`),new Se(`${s.end.format(o)} inclusive`)];return i&&f.push(new Se(`OR no ${t} date`)),new Se(c,f)}a="on",u=s.start.format(o);break}let l=`${t} date is ${a} ${u}`;return i&&(l+=` OR no ${t} date`),new Se(l)}fieldNameForExplanation(){return this.fieldName()}supportsSorting(){return!0}comparator(){return(t,n)=>jr(this.date(t),this.date(n))}supportsGrouping(){return!0}grouper(){return t=>{let n=this.date(t);return n===null?["No "+this.fieldName()+" date"]:[n.format("YYYY-MM-DD dddd")]}}checkForUnexpandedTemplateText(t){return new ru().findUnexpandedDateText(t)}};var qi=class extends yt{fieldName(){return"due"}date(e){return e.dueDate}filterResultIfFieldMissing(){return!1}};var _p=class extends ke{createFilterOrErrorMessage(e){var n;let t=ke.getMatch(this.filterRegExp(),e);if(t!==null){let i=t[5],s=null;switch(i.toLowerCase()){case"lowest":s="5";break;case"low":s="4";break;case"none":s="3";break;case"medium":s="2";break;case"high":s="1";break;case"highest":s="0";break}if(s===null)return J.fromError(e,"do not understand priority");let a=e,o;switch((n=t[3])==null?void 0:n.toLowerCase()){case"above":o=u=>u.priority.localeCompare(s)<0;break;case"below":o=u=>u.priority.localeCompare(s)>0;break;case"not":o=u=>u.priority!==s;break;default:o=u=>u.priority===s,a=`${this.fieldName()} is ${i}`}return J.fromFilter(new gt(e,o,new Se(a)))}else return J.fromError(e,"do not understand query filter (priority)")}fieldName(){return"priority"}filterRegExp(){return _p.priorityRegexp}supportsSorting(){return!0}comparator(){return(e,t)=>e.priority.localeCompare(t.priority)}supportsGrouping(){return!0}grouper(){return e=>[e.priorityNameGroupText]}},Qn=_p;Qn.priorityRegexp=/^priority(\s+is)?(\s+(above|below|not))?(\s+(lowest|low|none|medium|high|highest))$/i;var Wi=class{matchesAnyOf(e){return e.some(t=>this.matches(t))}};var $i=class extends Wi{constructor(t){super();this.stringToFind=t}matches(t){return $i.stringIncludesCaseInsensitive(t,this.stringToFind)}static stringIncludesCaseInsensitive(t,n){return t.toLocaleLowerCase().includes(n.toLocaleLowerCase())}explanation(t){return new Se(t)}};var bn=class extends Wi{constructor(t){super();this.regex=t}static validateAndConstruct(t){let n=/^\/(.+)\/([^/]*)$/,i=t.match(n);if(i!==null){let s=new RegExp(i[1],i[2]);return new bn(s)}else return null}matches(t){return t.match(this.regex)!==null}static helpMessage(){return String.raw`See https://publish.obsidian.md/tasks/Queries/Regular+Expressions
Regular expressions must look like this:
/pattern/
or this:
/pattern/flags
Where:
- pattern: The 'regular expression' pattern to search for.
- flags: Optional characters that modify the search.
i => make the search case-insensitive
u => add Unicode support
Examples: /^Log/
/^Log/i
/File Name\.md/
/waiting|waits|waited/i
/\d\d:\d\d/
The following characters have special meaning in the pattern:
to find them literally, you must add a \ before them:
[\^$.|?*+()
CAUTION! Regular expression (or 'regex') searching is a powerful
but advanced feature that requires thorough knowledge in order to
use successfully, and not miss intended search results.
`}explanation(t){let i=uA(t,"using regex: ",this.regexAsString());return new Se(i)}regexAsString(){let t=`'${this.regex.source}' with `;switch(this.regex.flags.length){case 0:t+="no flags";break;case 1:t+=`flag '${this.regex.flags}'`;break;default:t+=`flags '${this.regex.flags}'`;break}return t}};function uA(r,e,t){var o;let n=r.match(/\//);if(!n)return"Error explaining instruction. Could not find a slash character";let i=2,s=((o=n.index)!=null?o:i)-i;return`${e.padEnd(s)}${t}`}var Me=class extends ke{createFilterOrErrorMessage(e){let t=ke.getMatch(this.filterRegExp(),e);if(t===null)return J.fromError(e,`do not understand query filter (${this.fieldName()})`);let n=t[1].toLowerCase(),i=t[2],s=null;if(n.includes("include"))s=new $i(i);else if(n.includes("regex")){try{s=bn.validateAndConstruct(i)}catch(u){let l=Kn("Parsing regular expression",u)+`
${bn.helpMessage()}`;return J.fromError(e,l)}if(s===null)return J.fromError(e,`Invalid instruction: '${e}'
${bn.helpMessage()}`)}if(s===null)return J.fromError(e,`do not understand query filter (${this.fieldName()})`);let a=n.match(/not/)!==null,o=new gt(e,this.getFilter(s,a),s.explanation(e));return J.fromFilter(o)}fieldPattern(){return this.fieldNameSingularEscaped()}filterOperatorPattern(){return"includes|does not include|regex matches|regex does not match"}filterRegExp(){return new RegExp(`^(?:${this.fieldPattern()}) (${this.filterOperatorPattern()}) (.*)`,"i")}getFilter(e,t){return n=>{let i=e.matches(this.value(n));return t?!i:i}}comparator(){return(e,t)=>this.value(e).localeCompare(this.value(t),void 0,{numeric:!0})}grouper(){return e=>[this.value(e)]}static escapeMarkdownCharacters(e){return e.replace(/\\/g,"\\\\").replace(/_/g,"\\_")}};var Yi=class extends Me{fieldName(){return"path"}value(e){return e.path}supportsSorting(){return!0}supportsGrouping(){return!0}grouper(){return e=>[Me.escapeMarkdownCharacters(e.path.replace(".md",""))]}};var Gi=class extends ke{canCreateFilterForLine(e){return!1}createFilterOrErrorMessage(e){return J.fromError(e,"Filtering by urgency is not yet supported")}fieldName(){return"urgency"}filterRegExp(){throw Error(`filterRegExp() unimplemented for ${this.fieldName()}`)}supportsSorting(){return!0}comparator(){return(e,t)=>t.urgency-e.urgency}supportsGrouping(){return!0}grouper(){return e=>[`${e.urgency.toFixed(2)}`]}createGrouper(e){return super.createGrouper(!e)}grouperInstruction(e){return super.grouperInstruction(!e)}};var ji=class{static by(e,t){let n=[new Gi().comparator(),new Sr().comparator(),new qi().comparator(),new Qn().comparator(),new Yi().comparator()],i=[];for(let s of e)i.push(s.comparator);return t.sort(ji.makeCompositeComparator([...i,...n]))}static makeCompositeComparator(e){return(t,n)=>{for(let i of e){let s=i(t,n);if(s!==0)return s}return 0}}};var nu=class{constructor(e,t,n){this.nestingLevel=e,this.displayName=t,this.property=n}};var iu=class{constructor(e,t){this.lastHeadingAtLevel=new Array;this.groupers=t;let i=e.keys().next().value.length;for(let s=0;s<i;s++)this.lastHeadingAtLevel.push("")}getHeadingsForTaskGroup(e){let t=new Array;for(let n=0;n<e.length;n++){let i=e[n];if(i!=this.lastHeadingAtLevel[n]){t.push(new nu(n,i,this.groupers[n].property));for(let s=n;s<e.length;s++)this.lastHeadingAtLevel[s]="";this.lastHeadingAtLevel[n]=i}}return t}};var su=class{constructor(e){this.children=new Map;this.values=[];this.values=e}generateAllPaths(e=[]){let t=new Map;if(this.children.size==0)return t.set([...e],this.values),t;for(let[n,i]of this.children)e.push(n),i.generateAllPaths(e).forEach((a,o)=>t.set(o,a)),e.pop();return t}};var au=class extends su{},ou=class{constructor(e,t,n){this.root=new au(t),this.buildGroupingTree(e,n)}buildGroupingTree(e,t){let n=[this.root];for(let i of e){let s=[];for(let a of n)for(let o of a.values){let u=i.grouper(o,t);u.length===0&&u.push("");for(let l of u){let c=a.children.get(l);c===void 0&&(c=new au([]),a.children.set(l,c),s.push(c)),c.values.push(o)}}n=s}}generateTaskTreeStorage(){return this.root.generateAllPaths()}};var uu=class{constructor(e,t){this.groups=e,this.groupHeadings=[],this.tasks=t}setGroupHeadings(e){for(let t of e)this.groupHeadings.push(t)}applyTaskLimit(e){this.tasks=this.tasks.slice(0,e)}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.property}] ${t.displayName}
`;return e+=this.tasksAsStringOfLines(),e}};var Bi=class{constructor(e,t,n){this._groups=new Array;this._totalTaskCount=0;this._totalTaskCount=t.length,this._groupers=e;let s=new ou(e,t,n).generateTaskTreeStorage();this.addTaskGroups(s),this.sortTaskGroups(),this.setGroupsHeadings(s)}get groupers(){return this._groupers}get groups(){return this._groups}totalTasksCount(){return this._totalTaskCount}toString(){let e="";e+=`Groupers (if any):
`;for(let n of this._groupers){let i=n.reverse?" reverse":"";e+=`- ${n.property}${i}
`}for(let n of this.groups)e+=n.toString(),e+=`
---
`;return e+=`
${this.totalTasksCount()} tasks
`,e}addTaskGroups(e){for(let[t,n]of e){let i=new uu(t,n);this.addTaskGroup(i)}}addTaskGroup(e){this._groups.push(e)}sortTaskGroups(){let e=(t,n)=>{let i=t.groups,s=n.groups;for(let a=0;a<i.length;a++){let o=this._groupers[a],u=i[a].localeCompare(s[a],void 0,{numeric:!0});if(u!==0)return o.reverse?-u:u}return 0};this._groups.sort(e)}setGroupsHeadings(e){let t=new iu(e,this._groupers);for(let n of this._groups)n.setGroupHeadings(t.getHeadingsForTaskGroup(n.groups))}applyTaskLimit(e){this._groupers.length!==0&&(this._groups.forEach(t=>{t.applyTaskLimit(e)}),this.recalculateTotalTaskCount())}recalculateTotalTaskCount(){let e=[];this._groups.forEach(n=>{e=[...e,...n.tasks]});let t=[...new Set(e)];this._totalTaskCount=t.length}};var Xn=class extends Me{fieldName(){return"description"}value(e){return ge.getInstance().removeAsSubstringFrom(e.description)}supportsSorting(){return!0}comparator(){return(e,t)=>{let n=Xn.cleanDescription(e.description),i=Xn.cleanDescription(t.description);return n.localeCompare(i,void 0,{numeric:!0})}}static cleanDescription(e){e=ge.getInstance().removeAsSubstringFrom(e);let t=/^\[\[?([^\]]*)]]?/,n=e.match(t);if(n!==null){let i=n[1];e=i.substring(i.indexOf("|")+1)+e.replace(t,"")}return e=this.replaceFormatting(e,/^\*\*([^*]+)\*\*/),e=this.replaceFormatting(e,/^\*([^*]+)\*/),e=this.replaceFormatting(e,/^==([^=]+)==/),e=this.replaceFormatting(e,/^__([^_]+)__/),e=this.replaceFormatting(e,/^_([^_]+)_/),e}static replaceFormatting(e,t){let n=e.match(t);return n!==null&&(e=n[1]+e.replace(t,"")),e}};var lu=class extends yt{fieldName(){return"created"}date(e){return e.createdDate}filterResultIfFieldMissing(){return!1}};var cu=class extends yt{fieldName(){return"done"}date(e){return e.doneDate}filterResultIfFieldMissing(){return!1}};var du=class extends Tn{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 Er{};function vp(r,e){let t=r.map(([n])=>n);try{let n=e.includes("return")?e:`return ${e}`,i=e&&new Function(...t,n);return i instanceof Function?Oa.fromObject(e,i):Oa.fromError(e,"Error parsing group function")}catch(n){return Oa.fromError(e,Kn(`Failed parsing expression "${e}"`,n))}}function wp(r,e){let t=e.map(([n,i])=>i);return r(...t)}function Ep(r,e,t){try{return wp(r,e)}catch(n){return Kn(`Failed calculating expression "${t}"`,n)}}function fu(r,e){return[["task",r],["query",e?e.query:null]]}function o_(r,e,t){let n=fu(r,t||null),i=vp(n,e);return i.error?i.error:Ep(i.queryComponent,n,e)}var pu=class{constructor(e){this.line=e,this.functionOrError=vp(fu(null,null),e)}isValid(){return this.functionOrError.error===void 0}get parseError(){return this.functionOrError.error}evaluate(e,t){if(!this.isValid())throw Error(`Error: Cannot evaluate an expression which is not valid: "${this.line}" gave error: "${this.parseError}"`);return wp(this.functionOrError.queryComponent,fu(e,t||null))}evaluateOrCatch(e,t){return this.isValid()?Ep(this.functionOrError.queryComponent,fu(e,t),this.line):`Error: Cannot evaluate an expression which is not valid: "${this.line}" gave error: "${this.parseError}"`}};var hu=class extends ke{createFilterOrErrorMessage(e){let t=ke.getMatch(this.filterRegExp(),e);if(t===null)return J.fromError(e,"Unable to parse line");let n=t[1],i=new pu(n);return i.isValid()?J.fromFilter(new gt(e,lA(i),new Se(e))):J.fromError(e,i.parseError)}fieldName(){return"function"}filterRegExp(){return new RegExp(`^filter by ${this.fieldNameSingularEscaped()} (.*)`,"i")}supportsGrouping(){return!0}createGrouperFromLine(e){let t=ke.getMatch(this.grouperRegExp(),e);if(t===null)return null;let n=!!t[1],i=t[2];return new yn(e,"function",dA(i),n)}grouperRegExp(){return new RegExp(`^group by ${this.fieldNameSingularEscaped()}( reverse)? (.*)`,"i")}grouper(){throw Error("grouper() function not valid for FunctionField. Use createGrouperFromLine() instead.")}};function lA(r){return(e,t)=>{let n=t.queryContext();return cA(r,e,n)}}function cA(r,e,t){let n=r.evaluate(e,t);if(typeof n=="boolean")return n;throw Error(`filtering function must return true or false. This returned "${n}".`)}function dA(r){return(e,t)=>{let n=t.queryContext();return fA(e,r,n)}}function fA(r,e,t){try{let n=o_(r,e,t);return Array.isArray(n)?n.map(s=>s.toString()):n===null?[]:[n.toString()]}catch(n){let i=`Error: Failed calculating expression "${e}". The error message was: `;return n instanceof Error?[i+n.message]:[i+"Unknown error"]}}var mu=class extends Me{fieldName(){return"heading"}value(e){return e.precedingHeader?e.precedingHeader:""}supportsSorting(){return!0}supportsGrouping(){return!0}grouper(){return e=>e.precedingHeader===null||e.precedingHeader.length===0?["(No heading)"]:[e.precedingHeader]}};var gu=class extends yt{fieldName(){return"scheduled"}date(e){return e.scheduledDate}filterResultIfFieldMissing(){return!1}};var yu=class extends yt Line truncated
Allowed options: 'is' and 'is not' (without quotes).
Allowed values: ${t}
Note: values are case-insensitive,
so 'in_progress' works too, for example.
Example: ${this.fieldNameSingular()} is not NON_TASK`;return J.fromError(e,n)}fieldName(){return"status.type"}value(e){return e.status.type}supportsSorting(){return!0}comparator(){return(e,t)=>{let n=_n.groupName(e),i=_n.groupName(t);return n.localeCompare(i,void 0,{numeric:!0})}}supportsGrouping(){return!0}grouper(){return e=>[_n.groupName(e)]}static groupName(e){return e.status.typeGroupText}};var Ru=class extends Me{fieldName(){return"recurrence"}value(e){return e.recurrence!==null?e.recurrence.toText():""}supportsGrouping(){return!0}grouper(){return e=>e.recurrence!==null?[e.recurrence.toText()]:["None"]}};var Mu=class extends Me{fieldName(){return"folder"}value(e){return e.file.folder}supportsGrouping(){return!0}grouper(){return e=>[Me.escapeMarkdownCharacters(this.value(e))]}};var Cu=class extends Me{fieldName(){return"root"}value(e){return e.file.root}supportsGrouping(){return!0}grouper(){return e=>[Me.escapeMarkdownCharacters(this.value(e))]}};var Au=class extends Me{fieldName(){return"backlink"}value(e){let t=e.getLinkText({isFilenameUnique:!0});return t===null?"Unknown Location":t}createFilterOrErrorMessage(e){return J.fromError(e,"backlink field does not support filtering")}canCreateFilterForLine(e){return!1}supportsGrouping(){return!0}grouper(){return e=>{let t=e.filename;if(t===null)return["Unknown Location"];let n=e.precedingHeader;return n===null?["[["+t+"]]"]:[`[[${t}#${n}|${t} > ${n}]]`]}}};var Pp=[()=>new xu,()=>new _n,()=>new Sr,()=>new bu,()=>new Qn,()=>new Tu,()=>new lu,()=>new yu,()=>new gu,()=>new qi,()=>new cu,()=>new Yi,()=>new Mu,()=>new Cu,()=>new Au,()=>new Xn,()=>new Zn,()=>new mu,()=>new du,()=>new Du,()=>new Gi,()=>new Ru,()=>new hu,()=>new Su];function Ou(r){for(let e of Pp){let t=e();if(t.canCreateFilterForLine(r))return t.createFilterOrErrorMessage(r)}return null}function w_(r){let e=/^sort by /i;if(r.match(e)===null)return null;for(let t of Pp){let i=t().createSorterFromLine(r);if(i)return i}return null}function E_(r){let e=/^group by /i;if(r.match(e)===null)return null;for(let t of Pp){let i=t().createGrouperFromLine(r);if(i)return i}return null}var vn=class{constructor(e,t){this.queryPath=e,this.allTasks=[...t]}static fromAllTasks(e){return new vn(void 0,e)}queryContext(){return this.queryPath?eu(this.queryPath):void 0}};function k_(r){return`task${r!==1?"s":""}`}var ti=class{constructor(e,t){this.totalTasksCountBeforeLimit=0;this._searchErrorMessage=void 0;this.taskGroups=e,this.totalTasksCountBeforeLimit=t}get searchErrorMessage(){return this._searchErrorMessage}set searchErrorMessage(e){this._searchErrorMessage=e}get totalTasksCount(){return this.taskGroups.totalTasksCount()}totalTasksCountDisplayText(){let e=this.totalTasksCount,t=this.totalTasksCountBeforeLimit;return e===t?`${e} ${k_(e)}`:`${e} of ${t} ${k_(t)}`}get groups(){return this.taskGroups.groups}static fromError(e){let t=new ti(new Bi([],[],vn.fromAllTasks([])),0);return t._searchErrorMessage=e,t}};function S_(r){return r.endsWith("\\")}function O_(r){return r.endsWith("\\\\")}function qA(r){return r.replace(/^[ \t]*/,"")}function WA(r){return r.replace(/[ \t]*\\$/,"")}function $A(r,e){let t=r;return e&&(t=qA(r)),O_(t)?t=t.slice(0,-1):S_(r)&&(t=WA(t)),t}function YA(r,e,t){e?r[r.length-1]+=" "+t:r.push(t)}function GA(r){let e=[],t=!1;for(let n of r.split(`
`)){let i=$A(n,t);YA(e,t,i),O_(n)?t=!1:t=S_(n)}return e.join(`
`)}function D_(r){return GA(r).split(`
`).map(e=>e.trim()).filter(e=>e!=="")}var Ji=class{constructor(e=""){this.indentation=e}explainQuery(e){if(e.error!==void 0)return this.explainError(e);let t=[];return t.push(this.explainFilters(e)),t.push(this.explainGroups(e)),t.push(this.explainSorters(e)),t.push(this.explainQueryLimits(e)),t.push(this.explainDebugSettings()),t.filter(n=>n!=="").join(`
`)}explainError(e){let t="";return t+=`Query has an error:
`,t+=e.error+`
`,t}explainFilters(e){return e.filters.length===0?this.indent(`No filters supplied. All tasks will match the query.
`):e.filters.map(n=>n.explainFilterIndented(this.indentation)).join(`
`)}explainGroups(e){let t=e.grouping.length;if(t===0)return this.indent(`No grouping instructions supplied.
`);let n="";for(let i=0;i<t;i++)n+=this.indentation+e.grouping[i].instruction+`
`;return n}explainSorters(e){let t=e.sorting.length;if(t===0)return this.indent(`No sorting instructions supplied.
`);let n="";for(let i=0;i<t;i++)n+=this.indentation+e.sorting[i].instruction+`
`;return n}explainQueryLimits(e){function t(i){let s=`At most ${i} task`;return i!==1&&(s+="s"),s}let n=[];if(e.limit!==void 0){let i=t(e.limit)+`.
`;n.push(this.indent(i))}if(e.taskGroupLimit!==void 0){let i=t(e.taskGroupLimit)+` per group (if any "group by" options are supplied).
`;n.push(this.indent(i))}return n.join(`
`)}explainDebugSettings(){let e="",{debugSettings:t}=Q();return t.ignoreSortInstructions&&(e+=this.indent(`NOTE: All sort instructions, including default sort order, are disabled, due to 'ignoreSortInstructions' setting.
`)),e}indent(e){return this.indentation+e}};var Jr=class{constructor(e,t=void 0){this._limit=void 0;this._taskGroupLimit=void 0;this._layoutOptions=new $n;this._queryLayoutOptions=new pn;this._filters=[];this._error=void 0;this._sorting=[];this._grouping=[];this._ignoreGlobalQuery=!1;this.hideOptionsRegexp=/^(hide|show) (task count|backlink|priority|created date|start date|scheduled date|done date|due date|recurrence rule|edit button|postpone button|urgency|tags)/i;this.shortModeRegexp=/^short/i;this.fullModeRegexp=/^full/i;this.explainQueryRegexp=/^explain/i;this.ignoreGlobalQueryRegexp=/^ignore global query/i;this.logger=St.getLogger("tasks.Query");this._queryId="";this.limitRegexp=/^limit (groups )?(to )?(\d+)( tasks?)?/i;this.commentRegexp=/^#.*/;this._queryId=this.generateQueryId(10),this.source=e,this.filePath=t,this.debug(`Creating query: ${this.formatQueryForLogging()}`),D_(e).forEach(n=>{let i=this.expandPlaceholders(n,t);if(this.error===void 0)switch(!0){case this.shortModeRegexp.test(i):this._queryLayoutOptions.shortMode=!0;break;case this.fullModeRegexp.test(i):this._queryLayoutOptions.shortMode=!1;break;case this.explainQueryRegexp.test(i):this._queryLayoutOptions.explainQuery=!0;break;case this.ignoreGlobalQueryRegexp.test(i):this._ignoreGlobalQuery=!0;break;case this.limitRegexp.test(i):this.parseLimit(i);break;case this.parseSortBy(i):break;case this.parseGroupBy(i):break;case this.hideOptionsRegexp.test(i):this.parseHideOptions(i);break;case this.commentRegexp.test(i):break;case this.parseFilter(i):break;default:this.setError("do not understand query",i)}})}formatQueryForLogging(){return`[${this.source.split(`
`).join(" ; ")}]`}expandPlaceholders(e,t){if(e.includes("{{")&&e.includes("}}")&&this.filePath===void 0)return this._error=`The query looks like it contains a placeholder, with "{{" and "}}"
but no file path has been supplied, so cannot expand placeholder values.
The query is:
${e}`,e;let n=e;if(t){let i=eu(t);try{n=a_(e,i)}catch(s){return s instanceof Error?this._error=s.message:this._error="Internal error. expandPlaceholders() threw something other than Error.",e}}return n}append(e){return this.source===""?e:e.source===""?this:new Jr(`${this.source}
${e.source}`,this.filePath)}explainQuery(){return new Ji().explainQuery(this)}get limit(){return this._limit}get taskGroupLimit(){return this._taskGroupLimit}get layoutOptions(){return this._layoutOptions}get queryLayoutOptions(){return this._queryLayoutOptions}get filters(){return this._filters}addFilter(e){this._filters.push(e)}get sorting(){return this._sorting}get grouping(){return this._grouping}get error(){return this._error}setError(e,t){this._error=`${e}
Problem line: "${t}"`}get ignoreGlobalQuery(){return this._ignoreGlobalQuery}applyQueryToTasks(e){this.debug(`Executing query: ${this.formatQueryForLogging()}`);let t=new vn(this.filePath,e);try{this.filters.forEach(o=>{e=e.filter(u=>o.filterFunction(u,t))});let{debugSettings:n}=Q(),i=n.ignoreSortInstructions?e:ji.by(this.sorting,e),s=i.slice(0,this.limit),a=new Bi(this.grouping,s,t);return this._taskGroupLimit!==void 0&&a.applyTaskLimit(this._taskGroupLimit),new ti(a,i.length)}catch(n){let i="Search failed";return ti.fromError(Kn(i,n))}}parseHideOptions(e){let t=e.match(this.hideOptionsRegexp);if(t!==null){let n=t[1].toLowerCase()==="hide";switch(t[2].toLowerCase()){case"task count":this._queryLayoutOptions.hideTaskCount=n;break;case"backlink":this._queryLayoutOptions.hideBacklinks=n;break;case"postpone button":this._queryLayoutOptions.hidePostponeButton=n;break;case"priority":this._layoutOptions.hidePriority=n;break;case"created date":this._layoutOptions.hideCreatedDate=n;break;case"start date":this._layoutOptions.hideStartDate=n;break;case"scheduled date":this._layoutOptions.hideScheduledDate=n;break;case"due date":this._layoutOptions.hideDueDate=n;break;case"done date":this._layoutOptions.hideDoneDate=n;break;case"recurrence rule":this._layoutOptions.hideRecurrenceRule=n;break;case"edit button":this._queryLayoutOptions.hideEditButton=n;break;case"urgency":this._queryLayoutOptions.hideUrgency=n;break;case"tags":this._layoutOptions.hideTags=n;break;default:this.setError("do not understand hide/show option",e)}}}parseFilter(e){var n;let t=Ou(e);return t!=null?(t.filter?this._filters.push(t.filter):this.setError((n=t.error)!=null?n:"Unknown error",e),!0):!1}parseLimit(e){let t=e.match(this.limitRegexp);if(t===null){this.setError("do not understand query limit",e);return}let n=Number.parseInt(t[3],10);t[1]!==void 0?this._taskGroupLimit=n:this._limit=n}parseSortBy(e){let t=w_(e);return t?(this._sorting.push(t),!0):!1}parseGroupBy(e){let t=E_(e);return t?(this._grouping.push(t),!0):!1}generateQueryId(e){let t="AaBbCcDdEeFfGgHhIiJjKkLlMmNnOoPpQqRrSsTtUuVvWwXxYyZz1234567890";return Array.from({length:e},()=>t[Math.floor(Math.random()*t.length)]).join("")}debug(e,t){this.logger.debugWithId(this._queryId,`"${this.filePath}": ${e}`,t)}};var wn=class{constructor(e=wn.empty){this._source=e}static getInstance(){return wn.instance||(wn.instance=new wn),wn.instance}set(e){this._source=e}query(e=void 0){return new Jr(this._source,e)}hasInstructions(){return this._source.trim()!==wn.empty}},tr=wn;tr.empty="";var Pu=class{constructor({obsidianEvents:e}){this.logger=St.getLogger("tasks.Events");this.obsidianEvents=e}onCacheUpdate(e){return this.logger.debug("TasksEvents.onCacheUpdate()"),this.obsidianEvents.on("obsidian-tasks-plugin:cache-update",e)}triggerCacheUpdate(e){this.logger.debug("TasksEvents.triggerCacheUpdate()"),this.obsidianEvents.trigger("obsidian-tasks-plugin:cache-update",e)}onRequestCacheUpdate(e){return this.logger.debug("TasksEvents.onRequestCacheUpdate()"),this.obsidianEvents.on("obsidian-tasks-plugin:request-cache-update",e)}triggerRequestCacheUpdate(e){this.logger.debug("TasksEvents.triggerRequestCacheUpdate()"),this.obsidianEvents.trigger("obsidian-tasks-plugin:request-cache-update",e)}off(e){this.logger.debug("TasksEvents.off()"),this.obsidianEvents.offref(e)}};var Ra=require("obsidian");var xa,Np,Ip,jA=["md"];function Fu(){return St.getLogger("tasks.File")}var x_=({metadataCache:r,vault:e,workspace:t})=>{xa=r,Np=e,Ip=t},ri=t=>F(void 0,[t],function*({originalTask:r,newTasks:e}){if(Np===void 0||xa===void 0||Ip===void 0){Nu("Tasks: cannot use File before initializing it.");return}Array.isArray(e)||(e=[e]);let n=Fu(),i="replaceTaskWithTasks()";zo(n,i,r),Vo(n,i,e),M_({originalTask:r,newTasks:e,vault:Np,metadataCache:xa,workspace:Ip,previousTries:0})});function Nu(r){console.error(r),new Ra.Notice(r,15e3)}function R_(r){console.warn(r),new Ra.Notice(r,1e4)}function BA(r){Fu().debug(r)}var En=class extends Error{},Iu=class extends Error{},M_=a=>F(void 0,[a],function*({originalTask:r,newTasks:e,vault:t,metadataCache:n,workspace:i,previousTries:s}){let o=Fu();o.debug(`tryRepetitive after ${s} previous tries`);let u=()=>{if(s>10){let c=`Tasks: Could not find the correct task line to update.
The task line not updated is:
${r.originalMarkdown}
In this markdown file:
"${r.taskLocation.path}"
Note: further clicks on this checkbox will usually now be ignored until the file is opened (or certain, specific edits are made - it's complicated).
Recommendations:
1. Close all panes that have the above file open, and then re-open the file.
2. Check for exactly identical copies of the task line, in this file, and see if you can make them different.
`;Nu(c);return}let l=Math.min(Math.pow(10,s),100);o.debug(`timeout = ${l}`),setTimeout(()=>{M_({originalTask:r,newTasks:e,vault:t,metadataCache:n,workspace:i,previousTries:s+1})},l)};try{let[l,c,f]=yield C_(r,t),h=[...f.slice(0,l),...e.map(T=>T.toFileLineString()),...f.slice(l+1)];yield t.modify(c,h.join(`
`))}catch(l){if(l instanceof En)return l.message&&R_(l.message),u();if(l instanceof Iu)return u();l instanceof Error&&Nu(l.message)}});function C_(r,e){return F(this,null,function*(){if(xa===void 0)throw new En;let t=e.getAbstractFileByPath(r.path);if(!(t instanceof Ra.TFile))throw new En(`Tasks: No file found for task ${r.description}. Retrying ...`);if(!jA.includes(t.extension))throw new Error(`Tasks: Does not support files with the ${t.extension} file extension.`);let n=xa.getFileCache(t);if(n==null||n===null)throw new En(`Tasks: No file cache found for file ${t.path}. Retrying ...`);let i=n.listItems;if(i===void 0||i.length===0)throw new En(`Tasks: No list items found in file cache of ${t.path}. Retrying ...`);let a=(yield e.read(t)).split(`
`),o=HA(r,a,i,BA);if(o===void 0)throw new Iu;return[o,t,a]})}function Fp(r,e){return F(this,null,function*(){try{let[t,n,i]=yield C_(r,e);return[t,n]}catch(t){t instanceof En?t.message&&R_(t.message):t instanceof Error&&Nu(t.message)}})}function A_(r,e){return r<e.length}function HA(r,e,t,n){let i=zA(r,e);return i!==void 0||(i=VA(r,e),i!==void 0)?i:KA(r,e,t,n)}function zA(r,e){let t=r.taskLocation.lineNumber;if(A_(t,e)&&e[t]===r.originalMarkdown)return Fu().debug(`Found original markdown at original line number ${t}`),t}function VA(r,e){let t=[];for(let n=0;n<e.length;n++)e[n]===r.originalMarkdown&&t.push(n);if(t.length===1)return t[0]}function KA(r,e,t,n){let i,s=0;for(let a of t){let o=a.position.start.line;if(!A_(o,e))return;if(o<r.taskLocation.sectionStart||a.task===void 0)continue;let u=e[o];if(ge.getInstance().includedIn(u)){if(s===r.taskLocation.sectionIndex){if(u===r.originalMarkdown)i=o;else{n(`Tasks: Unable to find task in file ${r.taskLocation.path}.
Expected task:
${r.originalMarkdown}
Found task:
${u}`);return}break}s++}}return i}var F_=require("obsidian");var I_=require("obsidian");var Lu=class{constructor(){this.data=QA}addDataAttribute(e,t,n){this.data[n].addDataAttribute(e,t,n)}className(e){return this.data[e].className}},Lp=class{constructor(e,t,n){if(e==="")throw Error("Developer note: CSS class cannot be an empty string, please specify one.");this.className=e,this.attributeName=t,this.attributeValueCalculator=n}addDataAttribute(e,t,n){this.attributeName!==Lp.noAttributeName&&(e.dataset[this.attributeName]=this.attributeValueCalculator(n,t))}},Ce=Lp;Ce.noAttributeName="",Ce.noAttributeValueCalculator=()=>"",Ce.dateAttributeCalculator=(e,t)=>{let i="far";function s(o){let u=window.moment().startOf("day"),l="",c=u.diff(o,"days");return isNaN(c)?null:c===0?"today":(c>0?l+="past-":c<0&&(l+="future-"),Math.abs(c)<=7?l+=Math.abs(c).toString()+"d":l+=i,l)}let a=t[e];if(a instanceof window.moment){let o=s(a);if(o)return o}return""};var QA={createdDate:new Ce("task-created","taskCreated",Ce.dateAttributeCalculator),dueDate:new Ce("task-due","taskDue",Ce.dateAttributeCalculator),startDate:new Ce("task-start","taskStart",Ce.dateAttributeCalculator),scheduledDate:new Ce("task-scheduled","taskScheduled",Ce.dateAttributeCalculator),doneDate:new Ce("task-done","taskDone",Ce.dateAttributeCalculator),description:new Ce("task-description",Ce.noAttributeName,Ce.noAttributeValueCalculator),recurrenceRule:new Ce("task-recurring",Ce.noAttributeName,Ce.noAttributeValueCalculator),priority:new Ce("task-priority","taskPriority",(r,e)=>Kr.priorityNameUsingNormal(e.priority).toLocaleLowerCase()),blockLink:new Ce("task-block-link",Ce.noAttributeName,Ce.noAttributeValueCalculator)};var P_=require("obsidian");function N_(r,e){return F(this,null,function*(){yield ri({originalTask:r,newTasks:e})})}var Uu=class extends P_.Menu{constructor(t){super();this.taskSaver=t}};var qu=class extends Uu{constructor(t,n,i=N_){super(i);this.statusRegistry=t;let s="Change status to:",a=(u,l,c,f)=>{let h=`${s} [${f}] ${c}`;l.setTitle(h).setChecked(f===u.status.symbol).onClick(()=>F(this,null,function*(){if(f!==u.status.symbol){let T=this.statusRegistry.bySymbol(f),y=u.handleNewStatusWithRecurrenceInUsersOrder(T);yield this.taskSaver(u,y)}}))},o=new Pe().coreStatuses.map(u=>u.symbol);for(let u of[!0,!1])for(let l of t.registeredStatuses)o.includes(l.symbol)===u&&this.addItem(c=>a(n,c,l.name,l.symbol))}};var Ma=new Lu,kn=class{static obsidianMarkdownRenderer(e,t,n,i){return F(this,null,function*(){if(!i)throw new Error("Must call the Obsidian renderer with an Obsidian Component object");yield I_.MarkdownRenderer.renderMarkdown(e,t,n,i)})}constructor({textRenderer:e=kn.obsidianMarkdownRenderer,obsidianComponent:t,parentUlElement:n,layoutOptions:i,queryLayoutOptions:s}){this.textRenderer=e,this.obsidianComponent=t,this.parentUlElement=n,this.layoutOptions=i,this.queryLayoutOptions=s}renderTaskLine(e,t,n){return F(this,null,function*(){let i=document.createElement("li");this.parentUlElement.appendChild(i),i.classList.add("task-list-item","plugin-tasks-list-item");let s=document.createElement("span");i.appendChild(s),s.classList.add("tasks-list-text"),yield this.taskToHtml(e,s,i);let a=document.createElement("input");return i.appendChild(a),a.classList.add("task-list-item-checkbox"),a.type="checkbox",e.status.symbol!==" "&&(a.checked=!0,i.classList.add("is-checked")),a.addEventListener("click",o=>{o.preventDefault(),o.stopPropagation(),a.disabled=!0;let u=e.toggleWithRecurrenceInUsersOrder();ri({originalTask:e,newTasks:u})}),a.addEventListener("contextmenu",o=>{new qu(ve.getInstance(),e).showAtPosition({x:o.clientX,y:o.clientY})}),a.setAttribute("title","Right-click for options"),i.prepend(a),i.setAttribute("data-task",e.status.symbol.trim()),i.setAttribute("data-line",t.toString()),i.setAttribute("data-task-status-name",e.status.name),i.setAttribute("data-task-status-type",e.status.type),a.setAttribute("data-line",t.toString()),this.queryLayoutOptions.shortMode&&this.addTooltip(e,s,n),i})}taskToHtml(e,t,n){return F(this,null,function*(){let i=new hn(this.layoutOptions,this.queryLayoutOptions),s=Hr.tasksPluginEmoji.taskSerializer;for(let a of i.shownTaskLayoutComponents){let o=s.componentToString(e,i.queryLayoutOptions.shortMode,a);if(o){let u=document.createElement("span");t.appendChild(u);let l=document.createElement("span");u.appendChild(l),yield this.renderComponentText(l,o,a,e),this.addInternalClasses(a,l);let c=Ma.className(a);u.classList.add(c),Ma.addDataAttribute(u,e,a),Ma.addDataAttribute(n,e,a)}}for(let a of i.hiddenTaskLayoutComponents)Ma.addDataAttribute(n,e,a);n.dataset.taskPriority===void 0&&Ma.addDataAttribute(n,e,"priority")})}renderComponentText(e,t,n,i){return F(this,null,function*(){if(n==="description"){t=ge.getInstance().removeAsWordFromDependingOnSettings(t);let{debugSettings:s}=Q();s.showTaskHiddenData&&(t+=`<br>\u{1F41B} <b>${i.lineNumber}</b> . ${i.sectionStart} . ${i.sectionIndex} . '<code>${i.originalMarkdown}</code>'<bLine truncated
`);if(T===void 0)return!1;let y=null;for(let D=0;D<T.length;D=D+1)if(T[D]!==""){y=T[D];break}return y===null?!1:ge.getInstance().includedIn(y)});if(i.length===0)return;let s=t.sourcePath,a=t.getSectionInfo(e);if(a===null)return;let o=a.text.split(`
`),u=0,l=[];for(let h=a.lineStart;h<=a.lineEnd;h++){let T=o[h];if(T===void 0)continue;let y=null,w=le.fromLine({line:T,taskLocation:new ct(s,h,a.lineStart,u,y),fallbackDate:null});w!==null&&(l.push(w),u++)}let c=new kn({obsidianComponent:n,parentUlElement:e,layoutOptions:new $n,queryLayoutOptions:new pn});for(let h=0;h<i.length;h++){let T=l[h],y=i[h];if(T===void 0||y===void 0)continue;let w=(f=y.getAttr("data-line"))!=null?f:"0",D=Number.parseInt(w,10),C=yield c.renderTaskLine(T,D),N=y.childNodes;for(let z=0;z<N.length;z=z+1){let ie=N[z];ie.nodeName.toLowerCase()==="div"?C.prepend(ie):ie.nodeName.toLowerCase()==="ul"&&C.append(ie)}let L=y.querySelectorAll("[data-footnote-id]"),oe=C.querySelectorAll("[data-footnote-id]");if(L.length===oe.length)for(let z=0;z<L.length;z++)oe[z].replaceWith(L[z]);y.replaceWith(C)}})}};var L_=require("@codemirror/view"),U_=require("obsidian");var q_=()=>L_.ViewPlugin.fromClass(Up),Up=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 h=`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(h),new U_.Notice(h,45e3)}return!1}let{state:i}=this.view,s=this.view.posAtDOM(t),a=i.doc.lineAt(s),o=le.fromLine({line:a.text,taskLocation:ct.fromUnknownPosition(""),fallbackDate:null});if(o===null)return!1;e.preventDefault();let l=o.toggleWithRecurrenceInUsersOrder().map(h=>h.toFileLineString()).join(i.lineBreak),c=i.update({changes:{from:a.from,to:a.to,insert:l}});this.view.dispatch(c);let f=t.checked;return setTimeout(()=>{t.checked=f},1),!0}};var pr=require("obsidian");function W_(r,e,t,n=void 0){let i="";e.isEmpty()||(i+=`Only tasks containing the global filter '${e.get()}'.
`);let s=new Ji(" "),a=new Jr(r,n);if(!a.ignoreGlobalQuery&&t.hasInstructions()){let o=t.query(n);i+=`Explanation of the global query:
${s.explainQuery(o)}
`}return i+=`Explanation of this Tasks code block query:
${s.explainQuery(a)}`,i}function $u(r,e,t){let n=new Jr(r,t);return n.ignoreGlobalQuery?n:e.query(t).append(n)}function $_(r){for(let t of le.allDateFields()){let n=r[t];if(n&&!n.isValid())return!1}let e=r.happensDates.some(t=>!!(t!=null&&t.isValid()));return!r.isDone&&e}function qp(r){return r.dueDate?"dueDate":r.scheduledDate?"scheduledDate":r.startDate?"startDate":null}function Y_(r,e,t,n){let i=r[e],s=new rt(i).postpone(t,n),a=ht.removeInferredStatusIfNeeded(r,[new le(it(we({},r),{[e]:s}))])[0];return{postponedDate:s,postponedTask:a}}function G_(r,e){let t=r==null?void 0:r.format("DD MMM YYYY");return`Task's ${e} postponed until ${t}`}function j_(r,e,t){return`\u2139\uFE0F ${Wp(r,e,t)} (right-click for more options)`}function Wp(r,e,t){function n(l){return l.charAt(0).toUpperCase()+l.slice(1)}let i=qp(r),s=r[i],o=new rt(s).postpone(t,e).format("ddd Do MMM"),u=e>1?e:"a";return s.isSameOrBefore(window.moment(),"day")?`${n(i.replace("Date",""))} in ${u} ${t}, on ${o}`:`Postpone ${i.replace("Date"," date")} by ${u} ${t}, to ${o}`}var Yu=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 F(this,null,function*(){n.addChild(new $p({app:this.app,events:this.events,container:t,source:e,filePath:n.sourcePath}))})}},$p=class extends pr.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=$u(this.source,tr.getInstance(),this.filePath),this.queryType="tasks";break;default:this.query=$u(this.source,tr.getInstance(),this.filePath),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=$u(this.source,tr.getInstance(),this.filePath),this.events.triggerRequestCacheUpdate(this.render.bind(this)),this.reloadQueryAtMidnight()},i+1e3)}render(i){return F(this,arguments,function*({tasks:t,state:n}){var a;let s=this.containerEl.createEl("div");n==="Warm"&&this.query.error===void 0?yield this.renderQuerySearchResults(t,n,s):this.query.error!==void 0?this.renderErrorMessage(s,this.query.error):this.renderLoadingMessage(s),(a=this.containerEl.firstChild)==null||a.replaceWith(s)})}renderQuerySearchResults(t,n,i){return F(this,null,function*(){this.query.debug(`[render] Render called: plugin state: ${n}; searching ${t.length} tasks`),this.query.queryLayoutOptions.explainQuery&&this.createExplanation(i);let s=this.query.applyQueryToTasks(t);if(s.searchErrorMessage!==void 0){this.renderErrorMessage(i,s.searchErrorMessage);return}yield this.addAllTaskGroups(s.taskGroups,i);let a=s.totalTasksCount;this.addTaskCount(i,s),this.query.debug(`[render] ${a} tasks displayed`)})}renderErrorMessage(t,n){t.createDiv().innerHTML=`<pre>Tasks query: ${n.replace(/\n/g,"<br>")}</pre>`}renderLoadingMessage(t){t.setText("Loading Tasks ...")}createExplanation(t){let n=W_(this.source,ge.getInstance(),tr.getInstance(),this.filePath),i=t.createEl("pre");i.addClasses(["plugin-tasks-query-explanation"]),i.setText(n),t.appendChild(i)}createTaskList(t,n){return F(this,null,function*(){let i=new hn(this.query.layoutOptions,this.query.queryLayoutOptions),s=n.createEl("ul");s.addClasses(["contains-task-list","plugin-tasks-query-result"]),s.addClasses(i.taskListHiddenClasses);let a=this.getGroupingAttribute();a&&a.length>0&&(s.dataset.taskGroupBy=a);let o=new kn({obsidianComponent:this,parentUlElement:s,layoutOptions:this.query.layoutOptions,queryLayoutOptions:this.query.queryLayoutOptions});for(let[u,l]of t.entries()){let c=this.isFilenameUnique({task:l}),f=yield o.renderTaskLine(l,u,c);f.querySelectorAll("[data-footnote-id]").forEach(w=>w.remove());let T=f.createSpan("task-extras");this.query.queryLayoutOptions.hideUrgency||this.addUrgency(T,l);let y=this.query.queryLayoutOptions.shortMode;this.query.queryLayoutOptions.hideBacklinks||this.addBacklinks(T,l,y,c),this.query.queryLayoutOptions.hideEditButton||this.addEditButton(T,l),!this.query.queryLayoutOptions.hidePostponeButton&&$_(l)&&this.addPostponeButton(T,l,y),s.appendChild(f)}n.appendChild(s)})}addEditButton(t,n){t.createEl("a",{cls:"tasks-edit"}).onClickEvent(s=>{s.preventDefault();let a=u=>F(this,null,function*(){yield ri({originalTask:n,newTasks:ht.removeInferredStatusIfNeeded(n,u)})});new gn({app:this.app,task:n,onSubmit:a}).open()})}addUrgency(t,n){let i=new Intl.NumberFormat().format(n.urgency);t.createSpaLine truncated
`,this._markdown+=`${t}
`}addRow(e){let t=this.makeRowText(e);this._markdown+=`${t}
`}addRowIfNew(e){let t=this.makeRowText(e);this._markdown.includes(t)||(this._markdown+=`${t}
`)}makeRowText(e){let t="|";return e.forEach(n=>{t+=` ${n} |`}),t}};function B_(r,e){return r.findIndex(t=>t.symbol===e)}function XA(r,e){let t=X.getTypeForUnknownSymbol(r.symbol);r.type!==t&&(t==="TODO"&&r.symbol!==" "||e.push(`For information, the conventional type for status symbol ${Rr(r.symbol)} is ${Rr(t)}: you may wish to review this type.`))}function ZA(r,e,t){let n=B_(r,e.nextStatusSymbol);if(n===-1){t.push(`Next symbol ${Rr(e.nextStatusSymbol)} is unknown: create a status with symbol ${Rr(e.nextStatusSymbol)}.`);return}if(e.type!=="DONE")return;let i=r[n];if(i){if(i.type!=="TODO"&&i.type!=="IN_PROGRESS"){let s="https://publish.obsidian.md/tasks/Getting+Started/Statuses/Recurring+Tasks+and+Custom+Statuses",a=[`This \`DONE\` status is followed by ${Rr(i.type)}, not \`TODO\` or \`IN_PROGRESS\`.`,"If used to complete a recurring task, it will instead be followed by `TODO` or `IN_PROGRESS`, to ensure the next task matches the `not done` filter.",`See [Recurring Tasks and Custom Statuses](${s}).`].join("<br>");t.push(a)}}else t.push("Unexpected failure to find the next status.")}function JA(r,e,t){let n=[];return e.symbol===X.EMPTY.symbol?(n.push("Empty symbol: this status will be ignored."),n):B_(r,e.symbol)!=t?(n.push(`Duplicate symbol '${Rr(e.symbol)}': this status will be ignored.`),n):(XA(e,n),ZA(r,e,n),n)}function H_(r){let e=new Gu(["Status Symbol","Next Status Symbol","Status Name","Status Type","Problems (if any)"]),t=Pe.allStatuses(r);return t.forEach((n,i)=>{e.addRow([Rr(n.symbol),Rr(n.nextStatusSymbol),n.name,Rr(n.type),JA(t,n,i).join("<br>")])}),e.markdown}function z_(r,e,t,n){let s=H_(r),a=e.mermaidDiagram(!0);return`# ${t}
## About this file
This file was created by the Obsidian Tasks plugin (version ${n}) to help visualise the task statuses in this vault.
If you change the Tasks status settings, you can get an updated report by:
- Going to \`Settings\` -> \`Tasks\`.
- Clicking on \`Review and check your Statuses\`.
You can delete this file any time.
## Status Settings
<!--
Switch to Live Preview or Reading Mode to see the table.
If there are any Markdown formatting characters in status names, such as '*' or '_',
Obsidian may only render the table correctly in Reading Mode.
-->
These are the status values in the Core and Custom statuses sections.
${s}
## Loaded Settings
<!-- Switch to Live Preview or Reading Mode to see the diagram. -->
These are the settings actually used by Tasks.
${a}`}function Rr(r){return r===""?r:"`"+(r!==" "?r:"space")+"`"}function V_(){return[[" ","Unchecked","x","TODO"],["x","Checked"," ","DONE"],[">","Rescheduled","x","TODO"],["<","Scheduled","x","TODO"],["!","Important","x","TODO"],["-","Cancelled"," ","CANCELLED"],["/","In Progress","x","IN_PROGRESS"],["?","Question","x","TODO"],["*","Star","x","TODO"],["n","Note","x","TODO"],["l","Location","x","TODO"],["i","Information","x","TODO"],["I","Idea","x","TODO"],["S","Amount","x","TODO"],["p","Pro","x","TODO"],["c","Con","x","TODO"],["b","Bookmark","x","TODO"],['"',"Quote","x","TODO"],["0","Speech bubble 0","0","NON_TASK"],["1","Speech bubble 1","1","NON_TASK"],["2","Speech bubble 2","2","NON_TASK"],["3","Speech bubble 3","3","NON_TASK"],["4","Speech bubble 4","4","NON_TASK"],["5","Speech bubble 5","5","NON_TASK"],["6","Speech bubble 6","6","NON_TASK"],["7","Speech bubble 7","7","NON_TASK"],["8","Speech bubble 8","8","NON_TASK"],["9","Speech bubble 9","9","NON_TASK"]]}function K_(){return[[" ","incomplete","x","TODO"],["x","complete / done"," ","DONE"],["-","cancelled"," ","CANCELLED"],[">","deferred","x","TODO"],["/","in progress, or half-done","x","IN_PROGRESS"],["!","Important","x","TODO"],["?","question","x","TODO"],["R","review","x","TODO"],["+","Inbox / task that should be processed later","x","TODO"],["b","bookmark","x","TODO"],["B","brainstorm","x","TODO"],["D","deferred or scheduled","x","TODO"],["I","Info","x","TODO"],["i","idea","x","TODO"],["N","note","x","TODO"],["Q","quote","x","TODO"],["W","win / success / reward","x","TODO"],["P","pro","x","TODO"],["C","con","x","TODO"]]}function Q_(){return[[" ","Unchecked","x","TODO"],["x","Checked"," ","DONE"],["-","Cancelled"," ","CANCELLED"],["/","In Progress","x","IN_PROGRESS"],[">","Deferred","x","TODO"],["!","Important","x","TODO"],["?","Question","x","TODO"],["r","Review","x","TODO"]]}function X_(){return[[" ","Unchecked","x","TODO"],["x","Regular"," ","DONE"],["X","Checked"," ","DONE"],["-","Dropped"," ","CANCELLED"],[">","Forward","x","TODO"],["D","Date","x","TODO"],["?","Question","x","TODO"],["/","Half Done","x","IN_PROGRESS"],["+","Add","x","TODO"],["R","Research","x","TODO"],["!","Important","x","TODO"],["i","Idea","x","TODO"],["B","Brainstorm","x","TODO"],["P","Pro","x","TODO"],["C","Con","x","TODO"],["Q","Quote","x","TODO"],["N","Note","x","TODO"],["b","Bookmark","x","TODO"],["I","Information","x","TODO"],["p","Paraphrase","x","TODO"],["L","Location","x","TODO"],["E","Example","x","TODO"],["A","Answer","x","TODO"],["r","Reward","x","TODO"],["c","Choice","x","TODO"],["d","Doing","x","IN_PROGRESS"],["T","Time","x","TODO"],["@","Character / Person","x","TODO"],["t","Talk","x","TODO"],["O","Outline / Plot","x","TODO"],["~","Conflict","x","TODO"],["W","World","x","TODO"],["f","Clue / Find","x","TODO"],["F","Foreshadow","x","TODO"],["H","Favorite / Health","x","TODO"],["&","Symbolism","x","TODO"],["s","Secret","x","TODO"]]}function Z_(){return[[" ","Unchecked","x","TODO"],["x","Checked"," ","DONE"],[">","Rescheduled","x","TODO"],["<","Scheduled","x","TODO"],["!","Important","x","TODO"],["-","Cancelled"," ","CANCELLED"],["/","In Progress","x","IN_PROGRESS"],["?","Question","x","TODO"],["*","Star","x","TODO"],["n","Note","x","TODO"],["l","Location","x","TODO"],["i","Information","x","TODO"],["I","Idea","x","TODO"],["S","Amount","x","TODO"],["p","Pro","x","TODO"],["c","Con","x","TODO"],["b","Bookmark","x","TODO"],["f","Fire","x","TODO"],["k","Key","x","TODO"],["w","Win","x","TODO"],["u","Up","x","TODO"],["d","Down","x","TODO"]]}function J_(){return[[" ","to-do","x","TODO"],["/","incomplete","x","IN_PROGRESS"],["x","done"," ","DONE"],["-","canceled"," ","CANCELLED"],[">","forwarded","x","TODO"],["<","scheduling","x","TODO"],["?","question","x","TODO"],["!","important","x","TODO"],["*","star","x","TODO"],['"',"quote","x","TODO"],["l","location","x","TODO"],["b","bookmark","x","TODO"],["i","information","x","TODO"],["S","savings","x","TODO"],["I","idea","x","TODO"],["p","pros","x","TODO"],["c","cons","x","TODO"],["f","fire","x","TODO"],["k","key","x","TODO"],["w","win","x","TODO"],["u","up","x","TODO"],["d","down","x","TODO"]]}function ev(){return[[" ","to-do","x","TODO"],["/","incomplete","x","IN_PROGRESS"],["x","done"," ","DONE"],["-","canceled"," ","CANCELLED"],[">","forwarded","x","TODO"],["<","scheduling","x","TODO"],["?","question","x","TODO"],["!","important","x","TODO"],["*","star","x","TODO"],['"',"quote","x","TODO"],["l","location","x","TODO"],["b","bookmark","x","TODO"],["i","information","x","TODO"],["S","savings","x","TODO"],["I","idea","x","TODO"],["p","pros","x","TODO"],["c","cons","x","TODO"],["f","fire","x","TODO"],["k","key","x","TODO"],["w","win","x","TODO"],["u","up","x","TODO"],["d","down","x","TODO"]]}var tv=[{text:"Core Statuses",level:"h3",class:"",open:!0,notice:{class:"setting-item-description",text:null,html:"<p>These are the core statuses that Tasks supports natively, with no need for custom CSS styling or theming.</p><p>You can Line truncated
`)+`
Fix errors before saving.`;new hr.Notice(f);return}this.saved=!0,this.close()})),l)),u.addExtraButton(l=>(l.setIcon("cross").setTooltip("Cancel").onClick(()=>{this.saved=!1,this.close()}),l))})}onOpen(){this.display()}static setValidationError(t){t.inputEl.addClass("tasks-settings-is-invalid")}static removeValidationError(t){t.inputEl.removeClass("tasks-settings-is-invalid")}static setValid(t,n){n.length===0?$t.removeValidationError(t):$t.setValidationError(t)}};var Yt=class extends be.PluginSettingTab{constructor({plugin:t}){super(t.app,t);this.customFunctions={insertTaskCoreStatusSettings:this.insertTaskCoreStatusSettings.bind(this),insertCustomTaskStatusSettings:this.insertCustomTaskStatusSettings.bind(this)};this.plugin=t}saveSettings(t){return F(this,null,function*(){yield this.plugin.saveSettings(),t&&this.display()})}display(){let{containerEl:t}=this;t.empty(),this.containerEl.addClass("tasks-settings"),t.createEl("h3",{text:"Tasks Settings"}),t.createEl("p",{cls:"tasks-setting-important",text:"Changing any settings requires a restart of obsidian."}),t.createEl("h4",{text:"Task Format Settings"}),new be.Setting(t).setName("Task Format").setDesc(Yt.createFragmentWithHTML('<p>The format that Tasks uses to read and write tasks.</p><p><b>Important:</b> Tasks currently only supports one format at a time. Selecting Dataview will currently <b>stop Tasks reading its own emoji signifiers</b>.</p><p>See the <a href="https://publish.obsidian.md/tasks/Reference/Task+Formats/About+Task+Formats">documentation</a>.</p>')).addDropdown(i=>{for(let s of Object.keys(Hr))i.addOption(s,Hr[s].displayName);i.setValue(Q().taskFormat).onChange(s=>F(this,null,function*(){tt({taskFormat:s}),yield this.plugin.saveSettings()}))}),t.createEl("h4",{text:"Global filter Settings"}),new be.Setting(t).setName("Global task filter").setDesc(Yt.createFragmentWithHTML('<p><b>Recommended: Leave empty if you want all checklist items in your vault to be tasks managed by this plugin.</b></p><p>Use a global filter if you want Tasks to only act on a subset of your "<code>- [ ]</code>" checklist items, so that a checklist item must include the specified string in its description in order to be considered a task.<p><p>For example, if you set the global filter to <code>#task</code>, the Tasks plugin will only handle checklist items tagged with <code>#task</code>.</br>Other checklist items will remain normal checklist items and not appear in queries or get a done date set.</p><p>See the <a href="https://publish.obsidian.md/tasks/Getting+Started/Global+Filter">documentation</a>.</p>')).addText(i=>{i.setPlaceholder("e.g. #task or TODO").setValue(ge.getInstance().get()).onChange(s=>F(this,null,function*(){tt({globalFilter:s}),ge.getInstance().set(s),yield this.plugin.saveSettings()}))}),new be.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(i=>{let s=Q();i.setValue(s.removeGlobalFilter).onChange(a=>F(this,null,function*(){tt({removeGlobalFilter:a}),ge.getInstance().setRemoveGlobalFilter(a),yield this.plugin.saveSettings()}))}),t.createEl("h4",{text:"Global Query"}),nP(new be.Setting(t).setDesc(Yt.createFragmentWithHTML('<p>A query that is automatically included at the start of every Tasks block in the vault. Useful for adding default filters, or layout options.</p><p>See the <a href="https://publish.obsidian.md/tasks/Queries/Global+Query">documentation</a>.</p>')).addTextArea(i=>{let s=Q();i.inputEl.rows=4,i.setPlaceholder(`# For example...
path does not include _templates/
limit 300
show urgency`).setValue(s.globalQuery).onChange(a=>F(this,null,function*(){tt({globalQuery:a}),tr.getInstance().set(a),yield this.plugin.saveSettings()}))})),t.createEl("h4",{text:"Task Statuses"});let{headingOpened:n}=Q();tv.forEach(i=>{this.addOneSettingsBlock(t,i,n)}),t.createEl("h4",{text:"Date Settings"}),new be.Setting(t).setName("Set created date on every added task").setDesc(Yt.createFragmentWithHTML(`Enabling this will add a timestamp \u2795 YYYY-MM-DD before other date values, when a task is created with 'Create or edit task', or by completing a recurring task.</br><p>See the <a href="https://publish.obsidian.md/tasks/Getting+Started/Dates#Created+date">documentation</a>.</p>`)).addToggle(i=>{let s=Q();i.setValue(s.setCreatedDate).onChange(a=>F(this,null,function*(){tt({setCreatedDate:a}),yield this.plugin.saveSettings()}))}),new be.Setting(t).setName("Set done date on every completed task").setDesc(Yt.createFragmentWithHTML('Enabling this will add a timestamp \u2705 YYYY-MM-DD at the end when a task is toggled to done.</br><p>See the <a href="https://publish.obsidian.md/tasks/Getting+Started/Dates#Done+date">documentation</a>.</p>')).addToggle(i=>{let s=Q();i.setValue(s.setDoneDate).onChange(a=>F(this,null,function*(){tt({setDoneDate:a}),yield this.plugin.saveSettings()}))}),new be.Setting(t).setName("Use filename as Scheduled date for undated tasks").setDesc(Yt.createFragmentWithHTML('Save time entering Scheduled (\u23F3) dates.</br>If this option is enabled, any undated tasks will be given a default Scheduled date extracted from their file name.</br>The date in the file name must be in one of <code>YYYY-MM-DD</code> or <code>YYYYMMDD</code> formats.</br>Undated tasks have none of Due (\u{1F4C5} ), Scheduled (\u23F3) and Start (\u{1F6EB}) dates.</br><p>See the <a href="https://publish.obsidian.md/tasks/Getting+Started/Use+Filename+as+Default+Date">documentation</a>.</p>')).addToggle(i=>{let s=Q();i.setValue(s.useFilenameAsScheduledDate).onChange(a=>F(this,null,function*(){tt({useFilenameAsScheduledDate:a}),yield this.plugin.saveSettings()}))}),new be.Setting(t).setName("Folders with default Scheduled dates").setDesc("Leave empty if you want to use default Scheduled dates everywhere, or enter a comma-separated list of folders.").addText(i=>F(this,null,function*(){let s=Q();yield this.plugin.saveSettings(),i.setValue(Yt.renderFolderArray(s.filenameAsDateFolders)).onChange(a=>F(this,null,function*(){let o=Yt.parseCommaSeparatedFolders(a);tt({filenameAsDateFolders:o}),yield this.plugin.saveSettings()}))})),t.createEl("h4",{text:"Recurring task Settings"}),new be.Setting(t).setName("Next recurrence appears on the line below").setDesc(Yt.createFragmentWithHTML('Enabling this will make the next recurrence of a task appear on the line below the completed task. Otherwise the next recurrence will appear before the completed one.</br><p>See the <a href="https://publish.obsidian.md/tasks/Getting+Started/Recurring+Tasks">documentation</a>.</p>')).addToggle(i=>{let{recurrenceOnNextLine:s}=Q();i.setValue(s).onChange(a=>F(this,null,function*(){tt({recurrenceOnNextLine:a}),yield this.plugin.saveSettings()}))}),t.createEl("h4",{text:"Auto-suggest Settings"}),new be.Setting(t).setName("Auto-suggest task content").setDesc(Yt.createFragmentWithHTML('Enabling this will open an intelligent suggest menu while typing inside a recognized task line.</br><p>See the <a href="https://publish.obsidian.md/tasks/Getting+Started/Auto-Suggest">documentation</a>.</p>')).addToggle(i=>{let s=Q();i.setValue(s.autoSuggestInEditor).onChange(a=>F(this,null,function*(){tt({autoSuggestInEditor:a}),yield this.plugin.saveSettings()}))}),new be.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(i=>{let s=Q();i.setLimits(0,3,1).setValue(s.autoSuggestMinMatch).setDynamicTooltip().onChange(a=>F(this,null,function*(){tt({autoSuggestMinMatch:a}),yield this.plugin.saveSettings()}))}),new be.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(i=>{let s=Q();i.setLimits(3,12,1).setValue(s.autoSuggestMaxItems).setDynamicTooltip().onChange(a=>F(this,null,function*(){tt({autoSuggestMaxItems:a}),yield this.plugin.saveSettings()}))}),t.createEl("h4",{text:"Dialog Settings"}),new be.Setting(t).setName("Provide access keys in dialogs").setDesc(Yt.createFragmentWithHTML('If the access keys (keyboard shortcuts) for various controls in dialog boxes conflict with system keyboard shortcuts or assistive technology functionality that is important for you, you may want to deactivate them here.</br><p>See the <a href="https://publish.obsidian.md/tasks/Getting+Started/Create+or+edit+Task#Keyboard+shortcuts">documentation</a>.</p>')).addToggle(i=>{let s=Q();i.setValue(s.provideAccessKeys).o Line truncated
`);t(o)}).open(),n};var sv=(r,e)=>{let t=Zo({line:"",path:""});return new gn({app:r,task:t,onSubmit:e})};var av=r=>({createTaskLineModal:()=>iv(r,sv)});var Bu=class extends ov.Plugin{get apiV1(){return av(app)}onload(){return F(this,null,function*(){St.registerConsoleLogger(),np("info",`loading plugin "${this.manifest.name}" v${this.manifest.version}`),yield this.loadSettings();let{loggingOptions:t}=Q();St.configure(t),this.addSettingTab(new Ca({plugin:this})),x_({metadataCache:this.app.metadataCache,vault:this.app.vault,workspace:this.app.workspace}),yield this.loadTaskStatuses();let n=new Pu({obsidianEvents:this.app.workspace});this.cache=new Bn({metadataCache:this.app.metadataCache,vault:this.app.vault,events:n}),this.inlineRenderer=new Wu({plugin:this}),this.queryRenderer=new Yu({plugin:this,events:n}),this.registerEditorExtension(q_()),this.registerEditorSuggest(new ju(this.app,Q())),new Jo({plugin:this})})}loadTaskStatuses(){return F(this,null,function*(){let{statusSettings:t}=Q();Pe.applyToStatusRegistry(t,ve.getInstance())})}onunload(){var t;np("info",`unloading plugin "${this.manifest.name}" v${this.manifest.version}`),(t=this.cache)==null||t.unload()}loadSettings(){return F(this,null,function*(){let t=yield this.loadData();tt(t),t=Q(),ge.getInstance().set(t.globalFilter),ge.getInstance().setRemoveGlobalFilter(t.removeGlobalFilter),tr.getInstance().set(t.globalQuery),yield this.loadTaskStatuses()})}saveSettings(){return F(this,null,function*(){yield this.saveData(Q())})}getTasks(){var t;return(t=this.cache)==null?void 0:t.getTasks()}};
/*!
* EventEmitter2
* https://github.com/hij1nx/EventEmitter2
*
* Copyright (c) 2013 hij1nx
* Licensed under the MIT license.
*/
/*!
* mustache.js - Logic-less {{mustache}} templates with JavaScript
* http://github.com/janl/mustache.js
*/
+12
View File
@@ -0,0 +1,12 @@
{
"id": "obsidian-tasks-plugin",
"name": "Tasks",
"version": "5.4.0",
"minAppVersion": "1.1.1",
"description": "Task management for Obsidian",
"helpUrl": "https://publish.obsidian.md/tasks/",
"author": "Martin Schenck and Clare Macrae",
"authorUrl": "https://github.com/obsidian-tasks-group",
"fundingUrl": "https://github.com/sponsors/claremacrae",
"isDesktopOnly": false
}
+356
View File
@@ -0,0 +1,356 @@
:root {
--tasks-details-icon: url("data:image/svg+xml;charset=utf-8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M8.59 16.58L13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.42z'/></svg>");
}
/* Fix indentation of wrapped task lines in Tasks search results, when in Live Preview. */
ul.contains-task-list .task-list-item-checkbox {
margin-inline-start: calc(var(--checkbox-size) * -1.5) !important;
}
.plugin-tasks-query-explanation{
/* Prevent long explanation lines wrapping, so they are more readable,
especially on small screens.
A horizontal scroll bar will be displayed, if the explanation
is too wide to fit.
*/
--code-white-space: pre;
}
.tasks-count {
color: var(--text-faint);
padding-left: 20px;
}
/* Tooltip pop up above the description in short mode */
.tooltip.pop-up {
animation: pop-up-animation 200ms forwards ease-in-out;
}
@keyframes pop-up-animation {
0% {
opacity: 0;
transform: translateY(-100%) scale(1);
}
20% {
opacity: 0.7;
transform: translateY(-100%) scale(1.02);
}
40% {
opacity: 1;
transform: translateY(-100%) scale(1.05);
}
100% {
opacity: 1;
transform: translateY(-100%) scale(1);
}
}
/* Pencil icon. */
.tasks-edit {
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");
mask-size: contain;
-webkit-mask-size: contain;
display: inline-block;
width: 1em;
height: 1em;
vertical-align: middle;
margin-left: 0.5em;
cursor: pointer;
}
/* Urgency score */
.tasks-urgency {
font-size: var(--font-ui-smaller);
font-family: var(--font-interface);
padding: 2px 6px;
border-radius: var(--radius-s);
color: var(--text-normal);
background-color: var(--background-secondary);
margin-left: 0.5em;
line-height: 1;
}
.internal-link.internal-link-short-mode {
text-decoration: none;
}
/* Postpone icon. */
.tasks-postpone {
background-color: transparent;
padding: 0;
font-size: var(--font-text-size);
background-color: transparent;
display: contents;
cursor: pointer;
}
.tasks-list-text {
position: relative;
}
.tasks-list-text .tooltip {
position: absolute;
top: 0px;
left: 0px;
white-space: nowrap;
}
/* Hide tags that Obsidian recognises, if `hide tags` instruction was used. */
.tasks-layout-hide-tags .task-description a.tag {
display: none;
}
/* Workaround for issue #2073: Enabling the plugin causes blockIds to be not hidden in reading view
https://github.com/obsidian-tasks-group/obsidian-tasks/issues/2073 */
.task-list-item .task-block-link{
display: none;
}
.tasks-setting-important {
color: red;
font-weight: bold;
}
/**------------------------------------------------------------------------
** MODAL
*------------------------------------------------------------------------**/
.tasks-modal-section + .tasks-modal-section {
margin-top: 16px;
}
.tasks-modal-section label {
display: inline-block;
margin-bottom: 4px;
}
.tasks-modal-section label > span {
display: inline-block;
}
.tasks-modal .with-accesskeys .accesskey-first::first-letter,
.tasks-modal .with-accesskeys .accesskey {
text-decoration: underline;
text-underline-offset: 1pt;
}
.tasks-modal-buttons {
display: grid;
grid-template-columns: 3fr 1fr;
column-gap: .5em;
}
.tasks-modal label + input[type="checkbox"] {
margin-left: 0.67em;
top: 2px;
}
.tasks-modal input[type="text"] {
width: 100%;
}
.tasks-modal textarea {
width: 100%;
min-height: calc(var(--input-height) * 2);
resize: vertical;
}
.tasks-modal-priorities {
display: grid;
grid-template-columns: 4em 8em 8em 8em;
grid-column-gap: 1.33em;
}
.tasks-modal-priorities span {
line-height: 1.41;
white-space: nowrap;
}
.tasks-modal-priorities label {
border-radius: var(--input-radius);
padding: 2px 3px;
grid-column: 1;
grid-row-start: 1;
grid-row-end: 7;
}
.tasks-modal-priorities input:focus + label {
box-shadow: 0 0 0 2px var(--background-modifier-border-focus);
border-color: var(--background-modifier-border-focus);
}
.tasks-modal-priorities input:checked + label > span {
font-weight: bold;
}
.tasks-modal-priorities input:not(:checked) + label > span:nth-child(4) {
filter: grayscale(100%) opacity(60%);
}
.tasks-modal-dates {
display: grid;
grid-template-columns: 5.5em auto;
column-gap: .5em;
row-gap: 5px;
}
.tasks-modal-dates > label {
grid-column: 1;
margin-top: 6px;
}
.tasks-modal-dates > input, .tasks-modal-dates > code {
grid-column: 2;
align-items: stretch;
}
.tasks-modal-dates > code {
margin-bottom: 5px;
}
.tasks-modal-dates > div {
grid-column-start: 1;
grid-column-end: 3;
}
.tasks-modal-status {
display: flex;
justify-content: space-between;
}
.tasks-modal-error {
border: 1px solid red !important;
}
.tasks-modal button:disabled {
pointer-events: none !important;
opacity: 0.3 !important;
}
@media (max-width: 649px) {
.tasks-modal-priorities {
grid-template-columns: 4em 7.5em 5em;
margin-bottom: -10px;
}
.tasks-modal-priorities > label {
grid-row: 1 / span 7;
}
.tasks-modal-dates {
grid-template-columns: 1fr;
}
.tasks-modal-dates > label {
margin: 0;
}
.tasks-modal-dates > input, .tasks-modal-dates > code {
grid-column: 1;
}
.tasks-modal-dates > div {
grid-column-end: 1;
}
.tasks-modal-status {
display: block;
}
}
@media (max-width: 399px) {
.tasks-modal-priorities {
grid-template-columns: 4em auto;
}
.tasks-modal-priorities > label {
grid-row: 1 / span 7;
}
}
@media (max-width: 259px) {
.tasks-modal-priorities {
grid-template-columns: 1fr;
margin-bottom: 0;
}
.tasks-modal-priorities > label {
grid-row: 1;
}
}
/**------------------------------------------------------------------------
** SETTINGS
*------------------------------------------------------------------------**/
.tasks-settings-is-invalid {
/* Dark red text on pale background*/
color: var(--text-error) !important;
background-color: rgba(var(--background-modifier-error-rgb), 0.2) !important;
}
.tasks-settings .additional {
margin: 6px 12px;
}
.tasks-settings .additional > .setting-item {
border-top: 0;
padding-top: 9px;
}
.tasks-settings details > summary {
outline: none;
display: block !important;
list-style: none !important;
list-style-type: none !important;
min-height: 1rem;
border-top-left-radius: 0.1rem;
border-top-right-radius: 0.1rem;
cursor: pointer;
position: relative;
}
.tasks-settings details > summary::-webkit-details-marker,
.tasks-settings details > summary::marker {
display: none !important;
}
.tasks-settings details > summary > .collapser {
position: absolute;
top: 50%;
right: 8px;
transform: translateY(-50%);
content: "";
}
.tasks-settings details > summary > .collapser > .handle {
transform: rotate(0deg);
transition: transform 0.25s;
background-color: currentColor;
-webkit-mask-repeat: no-repeat;
mask-repeat: no-repeat;
-webkit-mask-size: contain;
mask-size: contain;
-webkit-mask-image: var(--tasks-details-icon);
mask-image: var(--tasks-details-icon);
width: 20px;
height: 20px;
}
.tasks-settings details[open] > summary > .collapser > .handle {
transform: rotate(90deg);
}
.tasks-nested-settings .setting-item {
border: 0px;
padding-bottom: 0;
}
.tasks-nested-settings {
padding-bottom: 18px;
}
.tasks-nested-settings[open] .setting-item-heading,
.tasks-nested-settings:not(details) .setting-item-heading {
border-top: 0px;
border-bottom: 1px solid var(--background-modifier-border);
}
.tasks-settings .row-for-status {
margin-top: 0px;
margin-bottom: 0px;
}
+6
View File
@@ -0,0 +1,6 @@
{
"formatType": "normal",
"showRibbonIcon": true,
"bindEnter": true,
"bindTab": true
}
File diff suppressed because it is too large. Load diff
+17
View File
@@ -0,0 +1,17 @@
{
"id": "table-editor-obsidian",
"name": "Advanced Tables",
"author": "Tony Grosinger",
"authorUrl": "https://grosinger.net",
"description": "Improved table navigation, formatting, manipulation, and formulas",
"isDesktopOnly": false,
"minAppVersion": "1.0.0",
"version": "0.20.0",
"js": "main.js",
"fundingUrl": {
"Github Sponsor": "https://github.com/sponsors/tgrosinger",
"Buy me a Coffee": "https://buymeacoffee.com/tgrosinger",
"Paypal": "https://paypal.me/tgrosinger"
},
"donation": "https://buymeacoffee.com/tgrosinger"
}
+78
View File
@@ -0,0 +1,78 @@
:root {
--advanced-tables-helper-size: 28px;
}
.HyperMD-table-row span.cm-inline-code {
font-size: 100%;
padding: 0px;
}
.advanced-tables-buttons>div>.title {
font-weight: var(--font-medium);
font-size: var(--nav-item-size);
color: var(--nav-item-color);
text-decoration: underline;
}
[data-type="advanced-tables-toolbar"] .nav-buttons-container {
column-gap: 0.2rem;
margin: 0.2rem 0 0.2rem 0;
justify-content: start;
}
[data-type="advanced-tables-toolbar"] .nav-buttons-container::before {
min-width: 2.6rem;
line-height: var(--advanced-tables-helper-size);
font-size: var(--nav-item-size);
font-weight: var(--nav-item-weight);
color: var(--nav-item-color);
}
[data-type="advanced-tables-toolbar"] .nav-buttons-container>* {
height: var(--advanced-tables-helper-size);
line-height: var(--advanced-tables-helper-size);
}
[data-type="advanced-tables-toolbar"] .nav-buttons-container .nav-action-button {
width: var(--advanced-tables-helper-size);
height: var(--advanced-tables-helper-size);
display: flex;
justify-content: center;
align-items: center;
border-radius: var(--radius-s);
}
[data-type="advanced-tables-toolbar"] .nav-buttons-container .nav-action-button:hover {
background-color: var(--nav-item-background-hover);
color: var(--nav-item-color-hover);
font-weight: var(--nav-item-weight-hover);
}
.advanced-tables-row-label {
width: 50px;
}
.widget-icon {
width: 20px;
height: 20px;
fill: var(--text-muted);
}
.widget-icon:hover {
fill: var(--text-normal);
}
.advanced-tables-csv-export textarea {
height: 200px;
width: 100%;
}
.advanced-tables-donation {
width: 70%;
margin: 0 auto;
text-align: center;
}
.advanced-tables-donate-button {
margin: 10px;
}