|
|
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const N=require("obsidian"),Dx=require("@codemirror/language"),Nm=require("@codemirror/state"),is=require("@codemirror/view");function d$(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const o in r)if(o!=="default"&&!(o in e)){const i=Object.getOwnPropertyDescriptor(r,o);i&&Object.defineProperty(e,o,i.get?i:{enumerable:!0,get:()=>r[o]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}var xr=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function tt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var g8={exports:{}},Ep={},v8={exports:{}},Lt={},jP;function f$(){if(jP)return Lt;jP=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),a=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),u=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),h=Symbol.iterator;function p(Z){return Z===null||typeof Z!="object"?null:(Z=h&&Z[h]||Z["@@iterator"],typeof Z=="function"?Z:null)}var m={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},b=Object.assign,v={};function y(Z,q,$){this.props=Z,this.context=q,this.refs=v,this.updater=$||m}y.prototype.isReactComponent={},y.prototype.setState=function(Z,q){if(typeof Z!="object"&&typeof Z!="function"&&Z!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,Z,q,"setState")},y.prototype.forceUpdate=function(Z){this.updater.enqueueForceUpdate(this,Z,"forceUpdate")};function S(){}S.prototype=y.prototype;function x(Z,q,$){this.props=Z,this.context=q,this.refs=v,this.updater=$||m}var C=x.prototype=new S;C.constructor=x,b(C,y.prototype),C.isPureReactComponent=!0;var k=Array.isArray,M=Object.prototype.hasOwnProperty,I={current:null},O={key:!0,ref:!0,__self:!0,__source:!0};function R(Z,q,$){var re,le={},ie=null,fe=null;if(q!=null)for(re in q.ref!==void 0&&(fe=q.ref),q.key!==void 0&&(ie=""+q.key),q)M.call(q,re)&&!O.hasOwnProperty(re)&&(le[re]=q[re]);var ye=arguments.length-2;if(ye===1)le.children=$;else if(1<ye){for(var ge=Array(ye),me=0;me<ye;me++)ge[me]=arguments[me+2];le.children=ge}if(Z&&Z.defaultProps)for(re in ye=Z.defaultProps,ye)le[re]===void 0&&(le[re]=ye[re]);return{$$typeof:e,type:Z,key:ie,ref:fe,props:le,_owner:I.current}}function L(Z,q){return{$$typeof:e,type:Z.type,key:q,ref:Z.ref,props:Z.props,_owner:Z._owner}}function B(Z){return typeof Z=="object"&&Z!==null&&Z.$$typeof===e}function _(Z){var q={"=":"=0",":":"=2"};return"$"+Z.replace(/[=:]/g,function($){return q[$]})}var H=/\/+/g;function U(Z,q){return typeof Z=="object"&&Z!==null&&Z.key!=null?_(""+Z.key):q.toString(36)}function G(Z,q,$,re,le){var ie=typeof Z;(ie==="undefined"||ie==="boolean")&&(Z=null);var fe=!1;if(Z===null)fe=!0;else switch(ie){case"string":case"number":fe=!0;break;case"object":switch(Z.$$typeof){case e:case t:fe=!0}}if(fe)return fe=Z,le=le(fe),Z=re===""?"."+U(fe,0):re,k(le)?($="",Z!=null&&($=Z.replace(H,"$&/")+"/"),G(le,q,$,"",function(me){return me})):le!=null&&(B(le)&&(le=L(le,$+(!le.key||fe&&fe.key===le.key?"":(""+le.key).replace(H,"$&/")+"/")+Z)),q.push(le)),1;if(fe=0,re=re===""?".":re+":",k(Z))for(var ye=0;ye<Z.length;ye++){ie=Z[ye];var ge=re+U(ie,ye);fe+=G(ie,q,$,ge,le)}else if(ge=p(Z),typeof ge=="function")for(Z=ge.call(Z),ye=0;!(ie=Z.next()).done;)ie=ie.value,ge=re+U(ie,ye++),fe+=G(ie,q,$,ge,le);else if(ie==="object")throw q=String(Z),Error("Objects are not valid as a React child (found: "+(q==="[object Object]"?"object with keys {"+Object.keys(Z).join(", ")+"}":q)+"). If you meant to render a collection of children, use an array instead.");return fe}function K(Z,q,$){if(Z==null)return Z;var re=[],le=0;return G(Z,re,"","",function(ie){return q.call($,ie,le++)}),re}function z(Z){if(Z._status===-1){var q=Z._result;q=q(),q.then(function($){(Z._status===0||Z._status===-1)&&(Z._status=1,Z._result=$)},function($){(Z._status===0||Z._status===-1)&&(Z._status=2,Z._result=$)}),Z._status===-1&&(Z._status=0,Z._result=q)}if(Z._status===1)return Z._result.default;throw Z._result}var ne={current:null},J={transition:null},ee={ReactCurrentDispatcher:ne,ReactCurrentBatchConfig:J,ReactCurrentOwner:I};return Lt.Children={map:K,forEach:function(Z,q,$){K(Z,function(){q.apply(this,arguments)},$)},count:function(Z){var q=0;return K(Z,function(){q++}),q},toArray:function(Z){return K(Z,function(q){return q})||[]},only:function(Z){if(!B(Z))throw Error("React.Children.only expected to receive a single React element child.");return Z}},Lt.Component=y,Lt.Fragment=n,Lt.Profiler=o,Lt.PureComponent=x,Lt.StrictMode=r,Lt.Suspense=l,Lt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=ee,Lt.cloneElement=function(Z,q,$){if(Z==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+Z+".");var re=b({},Z.props),le=Z.key,ie=Z.ref,fe=Z._owner;if(q!=null){if(q.ref!==void 0&&(ie=q.ref,fe=I.current),q.key!==void 0&&(le=""+q.key),Z.type&&Z.type.defaultProps)var ye=Z.type.defaultProps;for(ge in q)M.call(q,ge)&&!O.hasOwnProperty(ge)&&(re[ge]=q[ge]===void 0&&ye!==void 0?ye[ge]:q[ge])}var ge=arguments.length-2;if(ge===1)re.children=$;else if(1<ge){ye=Array(ge);for(var me=0;me<ge;me++)ye[me]=arguments[me+2];re.children=ye}return{$$typeof:e,type:Z.type,key:le,ref:ie,props:re,_owner:fe}},Lt.createContext=function(Z){return Z={$$typeof:a,_currentValue:Z,_currentValue2:Z,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},Z.Provider={$$typeof:i,_context:Z},Z.Consumer=Z},Lt.createElement=R,Lt.createFactory=function(Z){var q=R.bind(null,Z);return q.type=Z,q},Lt.createRef=function(){return{current:null}},Lt.forwardRef=function(Z){return{$$typeof:s,render:Z}},Lt.isValidElement=B,Lt.lazy=function(Z){return{$$typeof:d,_payload:{_status:-1,_result:Z},_init:z}},Lt.memo=function(Z,q){return{$$typeof:u,type:Z,compare:q===void 0?null:q}},Lt.startTransition=function(Z){var q=J.transition;J.transition={};try{Z()}finally{J.transition=q}},Lt.unstable_act=function(){throw Error("act(...) is not supported in production builds of React.")},Lt.useCallback=function(Z,q){return ne.current.useCallback(Z,q)},Lt.useContext=function(Z){return ne.current.useContext(Z)},Lt.useDebugValue=function(){},Lt.useDeferredValue=function(Z){return ne.current.useDeferredValue(Z)},Lt.useEffect=function(Z,q){return ne.current.useEffect(Z,q)},Lt.useId=function(){return ne.current.useId()},Lt.useImperativeHandle=function(Z,q,$){return ne.current.useImperativeHandle(Z,q,$)},Lt.useInsertionEffect=function(Z,q){return ne.current.useInsertionEffect(Z,q)},Lt.useLayoutEffect=function(Z,q){return ne.current.useLayoutEffect(Z,q)},Lt.useMemo=function(Z,q){return ne.current.useMemo(Z,q)},Lt.useReducer=function(Z,q,$){return ne.current.useReducer(Z,q,$)},Lt.useRef=function(Z){return ne.current.useRef(Z)},Lt.useState=function(Z){return ne.current.useState(Z)},Lt.useSyncExternalStore=function(Z,q,$){return ne.current.useSyncExternalStore(Z,q,$)},Lt.useTransition=function(){return ne.current.useTransition()},Lt.version="18.2.0",Lt}v8.exports=f$();var D=v8.exports;const Y=tt(D),h$=d$({__proto__:null,default:Y},[D]);var LP;function p$(){if(LP)return Ep;LP=1;var e=D,t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,i={key:!0,ref:!0,__self:!0,__source:!0};function a(s,l,u){var d,h={},p=null,m=null;u!==void 0&&(p=""+u),l.key!==void 0&&(p=""+l.key),l.ref!==void 0&&(m=l.ref);for(d in l)r.call(l,d)&&!i.hasOwnProperty(d)&&(h[d]=l[d]);if(s&&s.defaultProps)for(d in l=s.defaultProps,l)h[d]===void 0&&(h[d]=l[d]);return{$$typeof:t,type:s,key:p,ref:m,props:h,_owner:o.current}}return Ep.Fragment=n,Ep.jsx=a,Ep.jsxs=a,Ep}g8.exports=p$();var w=g8.exports;const zi=e=>{const{children:t,store:n,context:r}=e,[o,i]=D.useState(n.getState());return D.useEffect(()=>{const a=n.subscribe(s=>{i(s)});return()=>{a()}},[]),w.jsx(r.Provider,{value:o,children:t})};function m$(e){const t=Object.keys(e),n={};for(const r of t)typeof e[r]=="function"&&(n[r]=e[r]);return(r={},o)=>{let i=!1;const a={};for(const s of t){const l=r[s],u=n[s](l,o);a[s]=u,i=i||u!==l}return i?a:r}}function g$(e,t){const n=[];let r=e;return{dispatch:s=>{const l=t(r,s),u=r;r=l;for(const d of n)d(r,u)},getState:()=>r,subscribe:s=>{let l=!0;return n.push(s),()=>{if(!l)return;const u=n.indexOf(s);n.splice(u,1),l=!1}}}}function v$(e,t){switch(t.type){case"SET_MARK_MEMO_ID":return t.payload.markMemoId===e.markMemoId?e:{...e,markMemoId:t.payload.markMemoId};case"SET_EDIT_MEMO_ID":return t.payload.editMemoId===e.editMemoId?e:{...e,editMemoId:t.payload.editMemoId};case"SET_GLOBAL_EDITOR_SHOWN":return t.payload.globalEditorShown===e.globalEditorShown?e:{...e,globalEditorShown:t.payload.globalEditorShown};case"SET_COMMENT_MEMO_ID":return t.payload.commentMemoId===e.commentMemoId?e:{...e,commentMemoId:t.payload.commentMemoId};case"SET_MOBILE_VIEW":return t.payload.isMobileView===e.isMobileView?e:{...e,isMobileView:t.payload.isMobileView};case"SET_CHANGED_BY_MEMOS":return t.payload.changedByMemos===e.changedByMemos?e:{...e,changedByMemos:t.payload.changedByMemos};case"SET_REFRESH":return t.payload.refresh===e.refresh?e:{...e,refresh:t.payload.refresh};case"SET_INSTANCE":return{...e,instanceList:e.instanceList.set(t.payload.id,t.payload.instance)};case"SET_SHOW_SIDEBAR_IN_MOBILE_VIEW":return t.payload.showSiderbarInMobileView===e.showSiderbarInMobileView?e:{...e,showSiderbarInMobileView:t.payload.showSiderbarInMobileView};case"SET_MEMO_LIST_VIEW":return t.payload.memoListView===e.memoListView?e:{...e,memoListView:t.payload.memoListView};case"SET_MEMO_PLUGIN_MANIFEST":return{...e,manifest:t.payload.manifest};case"SET_LOADED":return{...e,loaded:t.payload.loaded};case"SET_EXIT_STEPS":return{...e,exited:t.payload.exited};case"SET_LOCKED":return{...e,locked:t.payload.locked};case"SET_APP_SETTING":return{...e,...t.payload};default:return e}}const y$={markMemoId:"",editMemoId:"",commentMemoId:"",shouldSplitMemoWord:!0,shouldHideImageUrl:!0,shouldUseMarkdownParser:!0,useTinyUndoHistoryCache:!1,isMobileView:!1,showSiderbarInMobileView:!1,changedByMemos:!1,memoListView:null,manifest:null,refresh:!1,loaded:!1,globalEditorShown:!1,instanceList:new Map,locked:!1,exited:!1};function b$(e,t){switch(t.type){case"RELOAD":return y8;case"SET_LOCATION":return t.payload;case"SET_PATHNAME":return t.payload.pathname===e.pathname?e:{...e,pathname:t.payload.pathname};case"SET_HASH":return t.payload.hash===e.hash?e:{...e,hash:t.payload.hash};case"SET_QUERY":return{...e,query:{...t.payload}};case"SET_TAG_QUERY":return t.payload.tag===e.query.tag?e:{...e,query:{...e.query,tag:t.payload.tag}};case"SET_DURATION_QUERY":return t.payload.duration===e.query.duration?e:{...e,query:{...e.query,duration:{...e.query.duration,...t.payload.duration}}};case"SET_PATH_QUERY":return t.payload.path===e.query.path?e:{...e,query:{...e.query,path:t.payload.path}};case"SET_TYPE":return t.payload.type===e.query.type?e:{...e,query:{...e.query,type:t.payload.type}};case"SET_TEXT":return t.payload.text===e.query.text?e:{...e,query:{...e.query,text:t.payload.text}};case"SET_QUERY_FILTER":return t.payload===e.query.filter?e:{...e,query:{...e.query,filter:t.payload}};default:return e}}const y8={pathname:"/",hash:"",query:{tag:"",duration:null,type:"",path:"",metadata:{},text:"",filter:""}};var Rt={};Object.defineProperty(Rt,"__esModule",{value:!0});var Bn=N;const Wk="YYYY-MM-DD",Gk="gggg-[W]ww",b8="YYYY-MM",w8="YYYY-[Q]Q",S8="YYYY";function zg(e){const t=window.app.plugins.getPlugin("periodic-notes");return t&&t.settings?.[e]?.enabled}function Vg(){try{const{internalPlugins:e,plugins:t}=window.app;if(zg("daily")){const{format:i,folder:a,template:s}=t.getPlugin("periodic-notes")?.settings?.daily||{};return{format:i||Wk,folder:a?.trim()||"",template:s?.trim()||""}}const{folder:n,format:r,template:o}=e.getPluginById("daily-notes")?.instance?.options||{};return{format:r||Wk,folder:n?.trim()||"",template:o?.trim()||""}}catch{}}function Wg(){try{const e=window.app.plugins,t=e.getPlugin("calendar")?.options,n=e.getPlugin("periodic-notes")?.settings?.weekly;if(zg("weekly"))return{format:n.format||Gk,folder:n.folder?.trim()||"",template:n.template?.trim()||""};const r=t||{};return{format:r.weeklyNoteFormat||Gk,folder:r.weeklyNoteFolder?.trim()||"",template:r.weeklyNoteTemplate?.trim()||""}}catch{}}function Gg(){const e=window.app.plugins;try{const t=zg("monthly")&&e.getPlugin("periodic-notes")?.settings?.monthly||{};return{format:t.format||b8,folder:t.folder?.trim()||"",template:t.template?.trim()||""}}catch{}}function Zg(){const e=window.app.plugins;try{const t=zg("quarterly")&&e.getPlugin("periodic-notes")?.settings?.quarterly||{};return{format:t.format||w8,folder:t.folder?.trim()||"",template:t.template?.trim()||""}}catch{}}function $g(){const e=window.app.plugins;try{const t=zg("yearly")&&e.getPlugin("periodic-notes")?.settings?.yearly||{};return{format:t.format||S8,folder:t.folder?.trim()||"",template:t.template?.trim()||""}}catch{}}function T8(...e){let t=[];for(let r=0,o=e.length;r<o;r++)t=t.concat(e[r].split("/"));const n=[];for(let r=0,o=t.length;r<o;r++){const i=t[r];!i||i==="."||n.push(i)}return t[0]===""&&n.unshift(""),n.join("/")}function w$(e){let t=e.substring(e.lastIndexOf("/")+1);return t.lastIndexOf(".")!=-1&&(t=t.substring(0,t.lastIndexOf("."))),t}async function S$(e){const t=e.replace(/\\/g,"/").split("/");if(t.pop(),t.length){const n=T8(...t);window.app.vault.getAbstractFileByPath(n)||await window.app.vault.createFolder(n)}}async function qg(e,t){t.endsWith(".md")||(t+=".md");const n=Bn.normalizePath(T8(e,t));return await S$(n),n}async function uh(e){const{metadataCache:t,vault:n}=window.app,r=Bn.normalizePath(e);if(r==="/")return Promise.resolve(["",null]);try{const o=t.getFirstLinkpathDest(r,""),i=await n.cachedRead(o),a=window.app.foldManager.load(o);return[i,a]}catch(o){return console.error(`Failed to read the daily note template '${r}'`,o),new Bn.Notice("Failed to read the daily note template"),["",null]}}function Sa(e,t="day"){const n=e.clone().startOf(t).format();return`${t}-${n}`}function x8(e){return e.replace(/\[[^\]]*\]/g,"")}function T$(e,t){if(t==="week"){const n=x8(e);return/w{1,2}/i.test(n)&&(/M{1,4}/.test(n)||/D{1,4}/.test(n))}return!1}function dh(e,t){return I8(e.basename,t)}function x$(e,t){return I8(w$(e),t)}function I8(e,t){const r={day:Vg,week:Wg,month:Gg,quarter:Zg,year:$g}[t]().format.split("/").pop(),o=window.moment(e,r,!0);if(!o.isValid())return null;if(T$(r,t)&&t==="week"){const i=x8(r);if(/w{1,2}/i.test(i))return window.moment(e,r.replace(/M{1,4}/g,"").replace(/D{1,4}/g,""),!1)}return o}class I$ extends Error{}async function k8(e){const t=window.app,{vault:n}=t,r=window.moment,{template:o,format:i,folder:a}=Vg(),[s,l]=await uh(o),u=e.format(i),d=await qg(a,u);try{const h=await n.create(d,s.replace(/{{\s*date\s*}}/gi,u).replace(/{{\s*time\s*}}/gi,r().format("HH:mm")).replace(/{{\s*title\s*}}/gi,u).replace(/{{\s*(date|time)\s*(([+-]\d+)([yqmwdhs]))?\s*(:.+?)?}}/gi,(p,m,b,v,y,S)=>{const x=r(),C=e.clone().set({hour:x.get("hour"),minute:x.get("minute"),second:x.get("second")});return b&&C.add(parseInt(v,10),y),S?C.format(S.substring(1).trim()):C.format(i)}).replace(/{{\s*yesterday\s*}}/gi,e.clone().subtract(1,"day").format(i)).replace(/{{\s*tomorrow\s*}}/gi,e.clone().add(1,"d").format(i)));return t.foldManager.save(h,l),h}catch(h){console.error(`Failed to create file: '${d}'`,h),new Bn.Notice("Unable to create new file.")}}function k$(e,t){return t[Sa(e,"day")]??null}function E$(){const{vault:e}=window.app,{folder:t}=Vg(),n=e.getAbstractFileByPath(Bn.normalizePath(t));if(!n)throw new I$("Failed to find daily notes folder");const r={};return Bn.Vault.recurseChildren(n,o=>{if(o instanceof Bn.TFile){const i=dh(o,"day");if(i){const a=Sa(i,"day");r[a]=o}}}),r}class C$ extends Error{}function M$(){const{moment:e}=window;let t=e.localeData()._week.dow;const n=["sunday","monday","tuesday","wednesday","thursday","friday","saturday"];for(;t;)n.push(n.shift()),t--;return n}function D$(e){return M$().indexOf(e.toLowerCase())}async function E8(e){const{vault:t}=window.app,{template:n,format:r,folder:o}=Wg(),[i,a]=await uh(n),s=e.format(r),l=await qg(o,s);try{const u=await t.create(l,i.replace(/{{\s*(date|time)\s*(([+-]\d+)([yqmwdhs]))?\s*(:.+?)?}}/gi,(d,h,p,m,b,v)=>{const y=window.moment(),S=e.clone().set({hour:y.get("hour"),minute:y.get("minute"),second:y.get("second")});return p&&S.add(parseInt(m,10),b),v?S.format(v.substring(1).trim()):S.format(r)}).replace(/{{\s*title\s*}}/gi,s).replace(/{{\s*time\s*}}/gi,window.moment().format("HH:mm")).replace(/{{\s*(sunday|monday|tuesday|wednesday|thursday|friday|saturday)\s*:(.*?)}}/gi,(d,h,p)=>{const m=D$(h);return e.weekday(m).format(p.trim())}));return window.app.foldManager.save(u,a),u}catch(u){console.error(`Failed to create file: '${l}'`,u),new Bn.Notice("Unable to create new file.")}}function A$(e,t){return t[Sa(e,"week")]??null}function N$(){const e={};if(!M8())return e;const{vault:t}=window.app,{folder:n}=Wg(),r=t.getAbstractFileByPath(Bn.normalizePath(n));if(!r)throw new C$("Failed to find weekly notes folder");return Bn.Vault.recurseChildren(r,o=>{if(o instanceof Bn.TFile){const i=dh(o,"week");if(i){const a=Sa(i,"week");e[a]=o}}}),e}class O$ extends Error{}async function C8(e){const{vault:t}=window.app,{template:n,format:r,folder:o}=Gg(),[i,a]=await uh(n),s=e.format(r),l=await qg(o,s);try{const u=await t.create(l,i.replace(/{{\s*(date|time)\s*(([+-]\d+)([yqmwdhs]))?\s*(:.+?)?}}/gi,(d,h,p,m,b,v)=>{const y=window.moment(),S=e.clone().set({hour:y.get("hour"),minute:y.get("minute"),second:y.get("second")});return p&&S.add(parseInt(m,10),b),v?S.format(v.substring(1).trim()):S.format(r)}).replace(/{{\s*date\s*}}/gi,s).replace(/{{\s*time\s*}}/gi,window.moment().format("HH:mm")).replace(/{{\s*title\s*}}/gi,s));return window.app.foldManager.save(u,a),u}catch(u){console.error(`Failed to create file: '${l}'`,u),new Bn.Notice("Unable to create new file.")}}function P$(e,t){return t[Sa(e,"month")]??null}function j$(){const e={};if(!D8())return e;const{vault:t}=window.app,{folder:n}=Gg(),r=t.getAbstractFileByPath(Bn.normalizePath(n));if(!r)throw new O$("Failed to find monthly notes folder");return Bn.Vault.recurseChildren(r,o=>{if(o instanceof Bn.TFile){const i=dh(o,"month");if(i){const a=Sa(i,"month");e[a]=o}}}),e}class L$ extends Error{}async function R$(e){const{vault:t}=window.app,{template:n,format:r,folder:o}=Zg(),[i,a]=await uh(n),s=e.format(r),l=await qg(o,s);try{const u=await t.create(l,i.replace(/{{\s*(date|time)\s*(([+-]\d+)([yqmwdhs]))?\s*(:.+?)?}}/gi,(d,h,p,m,b,v)=>{const y=window.moment(),S=e.clone().set({hour:y.get("hour"),minute:y.get("minute"),second:y.get("second")});return p&&S.add(parseInt(m,10),b),v?S.format(v.substring(1).trim()):S.format(r)}).replace(/{{\s*date\s*}}/gi,s).replace(/{{\s*time\s*}}/gi,window.moment().format("HH:mm")).replace(/{{\s*title\s*}}/gi,s));return window.app.foldManager.save(u,a),u}catch(u){console.error(`Failed to create file: '${l}'`,u),new Bn.Notice("Unable to create new file.")}}function F$(e,t){return t[Sa(e,"quarter")]??null}function H$(){const e={};if(!A8())return e;const{vault:t}=window.app,{folder:n}=Zg(),r=t.getAbstractFileByPath(Bn.normalizePath(n));if(!r)throw new L$("Failed to find quarterly notes folder");return Bn.Vault.recurseChildren(r,o=>{if(o instanceof Bn.TFile){const i=dh(o,"quarter");if(i){const a=Sa(i,"quarter");e[a]=o}}}),e}class _$ extends Error{}async function B$(e){const{vault:t}=window.app,{template:n,format:r,folder:o}=$g(),[i,a]=await uh(n),s=e.format(r),l=await qg(o,s);try{const u=await t.create(l,i.replace(/{{\s*(date|time)\s*(([+-]\d+)([yqmwdhs]))?\s*(:.+?)?}}/gi,(d,h,p,m,b,v)=>{const y=window.moment(),S=e.clone().set({hour:y.get("hour"),minute:y.get("minute"),second:y.get("second")});return p&&S.add(parseInt(m,10),b),v?S.format(v.substring(1).trim()):S.format(r)}).replace(/{{\s*date\s*}}/gi,s).replace(/{{\s*time\s*}}/gi,window.moment().format("HH:mm")).replace(/{{\s*title\s*}}/gi,s));return window.app.foldManager.save(u,a),u}catch(u){console.error(`Failed to create file: '${l}'`,u),new Bn.Notice("Unable to create new file.")}}function Y$(e,t){return t[Sa(e,"year")]??null}function U$(){const e={};if(!N8())return e;const{vault:t}=window.app,{folder:n}=$g(),r=t.getAbstractFileByPath(Bn.normalizePath(n));if(!r)throw new _$("Failed to find yearly notes folder");return Bn.Vault.recurseChildren(r,o=>{if(o instanceof Bn.TFile){const i=dh(o,"year");if(i){const a=Sa(i,"year");e[a]=o}}}),e}function z$(){const{app:e}=window,t=e.internalPlugins.plugins["daily-notes"];if(t&&t.enabled)return!0;const n=e.plugins.getPlugin("periodic-notes");return n&&n.settings?.daily?.enabled}function M8(){const{app:e}=window;if(e.plugins.getPlugin("calendar"))return!0;const t=e.plugins.getPlugin("periodic-notes");return t&&t.settings?.weekly?.enabled}function D8(){const{app:e}=window,t=e.plugins.getPlugin("periodic-notes");return t&&t.settings?.monthly?.enabled}function A8(){const{app:e}=window,t=e.plugins.getPlugin("periodic-notes");return t&&t.settings?.quarterly?.enabled}function N8(){const{app:e}=window,t=e.plugins.getPlugin("periodic-notes");return t&&t.settings?.yearly?.enabled}function V$(e){const t={day:Vg,week:Wg,month:Gg,quarter:Zg,year:$g}[e];return t()}function W$(e,t){return{day:k8,month:C8,week:E8}[e](t)}Rt.DEFAULT_DAILY_NOTE_FORMAT=Wk;Rt.DEFAULT_MONTHLY_NOTE_FORMAT=b8;Rt.DEFAULT_QUARTERLY_NOTE_FORMAT=w8;Rt.DEFAULT_WEEKLY_NOTE_FORMAT=Gk;Rt.DEFAULT_YEARLY_NOTE_FORMAT=S8;var Om=Rt.appHasDailyNotesPluginLoaded=z$;Rt.appHasMonthlyNotesPluginLoaded=D8;Rt.appHasQuarterlyNotesPluginLoaded=A8;Rt.appHasWeeklyNotesPluginLoaded=M8;Rt.appHasYearlyNotesPluginLoaded=N8;var O8=Rt.createDailyNote=k8;Rt.createMonthlyNote=C8;Rt.createPeriodicNote=W$;Rt.createQuarterlyNote=R$;Rt.createWeeklyNote=E8;Rt.createYearlyNote=B$;var Il=Rt.getAllDailyNotes=E$;Rt.getAllMonthlyNotes=j$;Rt.getAllQuarterlyNotes=H$;Rt.getAllWeeklyNotes=N$;Rt.getAllYearlyNotes=U$;var lS=Rt.getDailyNote=k$,uc=Rt.getDailyNoteSettings=Vg,nf=Rt.getDateFromFile=dh;Rt.getDateFromPath=x$;Rt.getDateUID=Sa;Rt.getMonthlyNote=P$;Rt.getMonthlyNoteSettings=Gg;Rt.getPeriodicNoteSettings=V$;Rt.getQuarterlyNote=F$;Rt.getQuarterlyNoteSettings=Zg;Rt.getTemplateInfo=uh;Rt.getWeeklyNote=A$;Rt.getWeeklyNoteSettings=Wg;Rt.getYearlyNote=Y$;Rt.getYearlyNoteSettings=$g;const G$={},Z$={},$$={welcome:"Velkommen til Thino",ribbonIconTitle:"Thino",to:"til",months:["Januar","Februar","Marts","April","Maj","Juni","Juli","August","September","Oktober","November","December"],monthsShort:["Jan.","Feb.","Mar.","Apr.","Maj","Jun.","Jul.","Aug.","Sep.","Okt.","Nov.","Dec."],weekDays:["Søndag","Mandag","Tirsdag","Onsdag","Torsdag","Fredag","Lørdag"],weekDaysShort:["Søn","Man","Tir","Ons","Tor","Fre","Lør"],year:null,month:null,"Basic Options":"Grundlæggende indstillinger","User name":"Brugernavn","Set your user name here. 'Memos 😏' By default":"Indstil dit brugernavn her. 'Thino 😏' som standard",'You can set target heading like "# Heading" to control data location':'Du kan indstille målrubrik som "# Rubrik" for at kontrollere dataplacering',"Insert after heading":"Indsæt efter rubrik","If left blank, the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"Du bør indstille samme rubrik nedenfor, hvis du vil indsætte og behandle thino under samme rubrik.","Allows admonitions to be created using ":"Tillader at advarselsbokse oprettes ved hjælp af ","Process Memos below":"Behandl thino nedenfor","If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.":"Hvis tomt, vil Thino-grænsefladen vise alt thino-indhold; hvis en titel er angivet, vil Thino-grænsefladen kun vise indholdet under den titel, og indhold skrevet andetsteds vil ikke blive vist.","Save Memo button label":"Gem thino-knappens etiket","The text shown on the save Memo button in the UI. 'NOTEIT' by default.":"Teksten vist på gem thino-knappen i brugergrænsefladen. 'NOTEIT' som standard.","Focus on editor when open memos":"Fokuser på editor når thino åbnes","Focus on editor when open memos. Focus by default.":"Fokuser på editor når thino åbnes. Fokus som standard.","Open daily memos with open memos":"Åbn daglig thino med åben thino","Open daily memos with open memos. Open by default.":"Åbn daglig thino med åben thino. Åben som standard.","Open Memos when obsidian opens":"Åbn Thino når obsidian åbnes","When enable this, Memos will open when Obsidian opens. False by default.":"Når dette er aktiveret, vil Thino åbne når Obsidian åbnes. Deaktiveret som standard.","Hide done tasks in Memo list":"Skjul færdige opgaver i Thino-listen","Hide all done tasks in Memo list. Show done tasks by default.":"Skjul alle færdige opgaver i Thino-listen. Vis færdige opgaver som standard.","Advanced Options":"Avancerede indstillinger","UI language for date":"UI-sprog for dato","Translates the date UI language. Only 'en' and 'zh' are available.":"Oversætter dato UI-sproget. Kun 'en' og 'zh' er tilgængelige.","Default prefix when save thino":"Standard præfiks ved gem thino","Set the default prefix when create memo, 'List' by default.":"Indstil standard præfiks ved oprettelse af thino, 'Liste' som standard.","Default insert date format":"Standard indsæt datoformat","Set the default date format when insert date by @, 'Tasks' by default.":"Indstil standard datoformat ved indsættelse af dato med @, 'Opgaver' som standard.","Default editor position on mobile":"Standard editor position på mobil","Set the default editor position on Mobile, 'Top' by default.":"Indstil standard editor position på mobil, 'Top' som standard.","Use button to show editor on mobile":"Brug knap til at vise editor på mobil","Set a float button to call editor on mobile. Only when editor located at the bottom works.":"Indstil en flydende knap til at kalde editor på mobil. Virker kun når editor er placeret i bunden.","Show Time When Copy Results":"Vis tid ved kopiering af resultater","Show time when you copy results, like 12:00. Copy time by default.":"Vis tid når du kopierer resultater, som 12:00. Kopier tid som standard.","Show Date When Copy Results":"Vis dato ved kopiering af resultater","Show date when you copy results, like [[2022-01-01]]. Copy date by default.":"Vis dato når du kopierer resultater, som [[2022-01-01]]. Kopier dato som standard.","Add Blank Line Between Different Date":"Tilføj tom linje mellem forskellige datoer","Add blank line when copy result with date. No blank line by default.":"Tilføj tom linje når du kopierer resultat med dato. Ingen tom linje som standard.","Share Options":"Delingsindstillinger","Share Memos Image Footer Start":"Del Thino-billede fodtekst start","Set anything you want here, use {ThinoNum} to display Number of thino, {UsedDay} for days. '{ThinoNum} Thino {UsedDay} Days' By default":"Indstil hvad du vil her, brug {ThinoNum} for at vise antal thino, {UsedDay} for dage. '{ThinoNum} Thino {UsedDay} Dage' som standard","Share Memos Image Footer End":"Del Thino-billede fodtekst slut","Set anything you want here, use {UserName} as your username. '✍️ By {UserName}' By default":"Indstil hvad du vil her, brug {UserName} som dit brugernavn. '✍️ Af {UserName}' som standard","Save Shared Image To Folder For Mobile":"Gem delt billede til mappe for mobil","Save image to folder for mobile. False by Default":"Gem billede til mappe for mobil. Deaktiveret som standard","Say Thank You":"Sig tak",Donate:"Donér","If you like this plugin, consider donating to support continued development:":"Hvis du kan lide dette plugin, overvej at donere for at støtte fortsat udvikling:","File Name of Recycle Bin":"Filnavn på papirkurv","Set the filename for recycle bin. 'delete' By default":"Indstil filnavnet for papirkurven. 'slet' som standard","File Name of Query File":"Filnavn på forespørgselsfil","Set the filename for query file. 'query' By default":"Indstil filnavnet for forespørgselsfilen. 'forespørgsel' som standard","Use Tags In Vault":"Brug tags i boks","Use tags in vault rather than only in Memos. False by default.":"Brug tags i boks i stedet for kun i Thino. Deaktiveret som standard.","Ready to convert image into background":"Klar til at konvertere billede til baggrund",List:"Liste",Task:"Opgave",Top:"Top",Bottom:"Bund",TAG:"TAG",DAY:"DAG",QUERY:"FORESPØRGSEL",EDIT:"REDIGER",PIN:"FASTGØR",UNPIN:"FRIGØR",DELETE:"SLET","CONFIRM!":"BEKRÆFT!","CREATE FILTER":"OPRET FILTER","Comment it...":"Kommenter det...",Settings:"Indstillinger","Recycle bin":"Papirkurv","About Me":"Om mig","Fetching data...":"Henter data...","Here is No Memos.":"Her er ingen Thino.","Frequently Used Tags":"Hyppigt brugte tags","What do you think now...":"Hvad tænker du nu...",READ:"LÆS",MARK:"MARKÉR",SHARE:"DEL",SOURCE:"KILDE",RESTORE:"GENDAN",ARCHIVE:"Arkiv","Daily Review":"Daglig gennemgang","DELETE AT":"SLETTET DEN","Noooop!":"Neeej!","All Data is Loaded 🎉":"Alle data er indlæst 🎉","Quick filter":"Hurtig filter",TYPE:"TYPE",LINKED:"LINKET","NO TAGS":"INGEN TAGS","HAS LINKS":"HAR LINKS","HAS IMAGES":"HAR BILLEDER",INCLUDE:"INKLUDER",EXCLUDE:"EKSKLUDER",TEXT:"TEKST",IS:"ER",AND:"OG",OR:"ELLER",LIST:"LISTE",ISNOT:"ER IKKE",PATH:"STI",METADATA:"METADATA",SELECT:"VÆLG","ADD FILTER TERMS":"TILFØJ FILTERBETINGELSER",FILTER:"FILTER",Filter:"Filter",TITLE:"TITEL","CREATE QUERY":"OPRET FORESPØRGSEL","EDIT QUERY":"REDIGER FORESPØRGSEL",MATCH:"MATCH",TIMES:"GANGE","Share Memo Image":"Del Thino-billede","↗Click the button to save":"↗Klik på knappen for at gemme","Image is generating...":"Billede genereres...","Image is loading...":"Billede indlæses...","Loading...":"Indlæser...","😟 Cannot load image, image link maybe broken":"😟 Kan ikke indlæse billede, billedlink er måske brudt","Daily Memos":"Daglige Thino","CANCEL EDIT":"ANNULLER REDIGERING","LINK TO THE":"LINK TIL","Mobile Options":"Mobilindstillinger","Experimental Options":"Eksperimentelle indstillinger","Don't support web image yet, please input image path in vault":"Understøtter ikke webbilleder endnu, indtast venligst billedsti i boksen","Background Image in Dark Theme":"Baggrundsbillede i mørkt tema","Background Image in Light Theme":"Baggrundsbillede i lyst tema",'Set background image in dark theme. Set something like "Daily/one.png"':'Indstil baggrundsbillede i mørkt tema. Indstil noget som "Daglig/et.png"','Set background image in light theme. Set something like "Daily/one.png"':'Indstil baggrundsbillede i lyst tema. Indstil noget som "Daglig/et.png"','Set default memo composition, you should use {TIME} as "HH:mm" and {CONTENT} as content. "{TIME} {CONTENT}" by default':'Indstil standard thino-komposition, du bør bruge {TIME} som "TT:mm" og {CONTENT} som indhold. "{TIME} {CONTENT}" som standard',"Default Memo Composition":"[Forældet] Standard Thino-komposition","Show Tasks Label":"Vis opgaveetiket","Show tasks label near the time text. False by default":"Vis opgaveetiket nær tidsteksten. Deaktiveret som standard","Please Open Memos First":"Åbn venligst Thino først",DATE:"DATO",OBSIDIAN_NLDATES_PLUGIN_NOT_ENABLED:"OBSIDIAN_NLDATES_PLUGIN_IKKE_AKTIVERET",BEFORE:"FØR",AFTER:"EFTER","Allow Comments On Memos":"Tillad kommentarer på Thino","You can comment on memos. False by default":"Du kan kommentere på thino. Deaktiveret som standard",Import:"Importer","TITLE CANNOT BE NULL!":"TITEL KAN IKKE VÆRE TOM!","FILTER CANNOT BE NULL!":"FILTER KAN IKKE VÆRE TOMT!","Comments In Original DailyNotes/Notes":"Kommentarer i originale daglige noter/noter","You should install Dataview Plugin ver 0.5.9 or later to use this feature.":"Du bør installere Dataview Plugin ver 0.5.9 eller senere for at bruge denne funktion.","Open Memos Successfully":"Åbn Thino med succes","Fetch Memos Error":"😭 Hentningsfejl","Copied to clipboard Successfully":"Kopieret til udklipsholder med succes","Check if you opened Daily Notes Plugin Or Periodic Notes Plugin":"Kontroller om du har åbnet Daily Notes Plugin eller Periodic Notes Plugin","Please finish the last filter setting first":"Afslut venligst den sidste filterindstilling først","Close Memos Successfully":"Luk Thino med succes","Insert as Memo":"Indsæt som Thino","Insert file as memo content":"Indsæt fil som thino-indhold","Image load failed":"Billedindlæsning mislykkedes","Content cannot be empty":"Indhold kan ikke være tomt","Unable to create new file.":"Kan ikke oprette ny fil.","Failed to fetch deleted memos: ":"Kunne ikke hente slettede thino: ","RESTORE SUCCEED":"GENDANNELSE LYKKEDES","DELETE SUCCEED":"SLETNING LYKKEDES","Save Memo button icon":"Gem Thino-knappens ikon","The icon shown on the save Memo button in the UI.":"Ikonet vist på gem Thino-knappen i brugergrænsefladen.","Fetch Memos From Particular Notes":"Hent Thino fra bestemte noter",'You can set any Dataview Query for memos to fetch it. All memos in those notes will show on list. "#memo" by default':'Du kan indstille enhver Dataview-forespørgsel for thino for at hente det. Alle thino i disse noter vil blive vist på listen. "#memo" som standard',"Allow Memos to Fetch Memo from Notes":"Tillad Thino at hente Thino fra noter","Use Memos to manage all memos in your notes, not only in daily notes. False by default":"Brug Thino til at administrere alle thino i dine noter, ikke kun i daglige noter. Deaktiveret som standard","Always Show Memo Comments":"Vis altid Thino-kommentarer","Always show memo comments on memos. False by default":"Vis altid thino-kommentarer på thino. Deaktiveret som standard","You didn't set folder for daily notes in both periodic-notes and daily-notes plugins.":"Du har ikke indstillet mappe til daglige noter i hverken periodic-notes eller daily-notes plugins.","Please check your daily note plugin OR periodic notes plugin settings":"Kontroller venligst dine indstillinger for daily note plugin ELLER periodic notes plugin","Use which plugin's default configuration":"Brug hvilket plugins standardkonfiguration","Memos use the plugin's default configuration to fetch memos from daily, 'Daily' by default.":"Thino bruger pluginets standardkonfiguration til at hente thino fra daglig, 'Daglig' som standard.",Daily:"Daglig","Always Show Leaf Sidebar on PC":"Vis altid blad-sidepanel på PC","Show left sidebar on PC/Tablet even when the leaf width is less than 875px. False by default.":"Vis venstre sidepanel på PC/tablet selv når bladbredden er mindre end 875px. Deaktiveret som standard.","You didn't set format for daily notes in both periodic-notes and daily-notes plugins.":"Du har ikke indstillet format for daglige noter i hverken periodic-notes eller daily-notes plugins.","fetch more":"hent mere","Search all settings":"Søg i alle indstillinger",General:"Generelt",Theme:"Tema",Share:"Del",Advanced:"Avanceret",Thino:"Thino","Random Review":"Tilfældig gennemgang","ARCHIVED AT":"ARKIVERET DEN","Failed to get memos from daily notes":"Kunne ikke hente thino fra daglige noter","Failed to delete memo":"Kunne ikke slette thino","CTRL + ENTER to save":"CTRL + ENTER for at gemme","Started from":"Startet fra","Custom Background Image":"Tilpasset baggrundsbillede","Set custom background image.":"Indstil tilpasset baggrundsbillede.","Custom Memo Footer":"Tilpasset Thino-fodtekst","Set custom memo footer.":"Indstil tilpasset thino-fodtekst.","Heatmap Color Scheme":"Varmekort farveskema","Set different color scheme for heatmap.":"Indstil forskelligt farveskema for varmekort.","Enable Local Http Server":"Aktiver lokal Http-server","Memos Http Server Port":"Thino Http-server port","Set memos http server port to listen. '43999' by default":"Indstil thino http-server port til at lytte. '43999' som standard","Default Editor Mode":"Standard editor-tilstand","Live-Preview Mode OR Source Mode.":"Live-forhåndsvisning tilstand/Kildetilstand.","Save type for Thino":"Gem type for Thino",DAILY:"DAGLIG",MULTI:"MULTI",CANVAS:"LÆRRED",ALL:"ALLE",FILE:"FIL",TODO:"TODO",DONE:"FÆRDIG",JOURNAL:"JOURNAL",OTHER:"ANDET","Failed to create daily note, check if it exists.":"Kunne ikke oprette daglig note, kontroller om den eksisterer.","Failed to create daily note. Please check if you created a folder for daily notes.":"Kunne ikke oprette daglig note. Kontroller venligst om du har oprettet en mappe til daglige noter.","After you verify your account, please refresh this page.":"Efter du har verificeret din konto, opdater venligst denne side.",Verify:"Verificer","Oops! You forget to verify insider account":"Ups! Du glemte at verificere insider-konto","If you have any questions, please contact us.":"Hvis du har spørgsmål, kontakt os venligst.","Delete Thino Directly":"Slet Thino direkte","When delete thino directly, it will not be moved to trash. False by default.":"Når du sletter thino direkte, vil det ikke blive flyttet til papirkurven. Deaktiveret som standard.","Enable opening thino globally":"Aktiver åbning af thino globalt","Enable opening thino globally. False by default.":"Aktiver åbning af thino globalt. Deaktiveret som standard.","Key for opening thino globally":"Tast for at åbne thino globalt","Set key for opening thino globally. CTRL + SHIFT + T by default.":"Indstil tast for at åbne thino globalt. CTRL + SHIFT + T som standard.","Key for showing thino globally":"Tast for at vise thino globalt","Set key for showing thino globally. CTRL + SHIFT + E by default.":"Indstil tast for at vise thino globalt. CTRL + SHIFT + E som standard.","Get activation code":"Få aktiveringskode","Input activation code here":"Indtast aktiveringskode her","Copy Thino id":"Kopier Thino-id","Activate Pro Version":"Aktiver Pro-version","Please copy Thino id first":"Kopier venligst Thino-id først",'You can set folder name with file name like "folder/file"':'Du kan indstille mappenavn med filnavn som "mappe/fil"','You can set folder name like "folder1/folder2/folder3" to create sub-folder':'Du kan indstille mappenavn som "mappe1/mappe2/mappe3" for at oprette undermappe',"Default save type":"Standard gem placering",'Set the default save type for thino. "DAILY" by default':'Indstil standard gem type for thino. "DAGLIG" som standard',"Sync Thino via PKMer":"Synkroniser Thino via PKMer",Unlink:"Fjern link",Link:"Link","Connect to PKMer Sync, you can check it in ":"Forbind til PKMer Sync, du kan tjekke det i ","PKMer Sync":"PKMer Sync","Remove successfully":"Fjernet med succes",Deactivate:"Deaktiver",Remove:"Fjern","Confirm?":"Bekræft?","Sync Status":"Synkroniseringsstatus","Start or stop sync":"Start eller stop synkronisering","Stop sync successfully":"Stop synkronisering med succes","Start sync successfully":"Start synkronisering med succes",Stop:"Stop",Start:"Start","Show thino near mouse":"Vis thino nær mus","Query not found":"Forespørgsel ikke fundet","Send to clipboard successfully":"Sendt til udklipsholder med succes","Thino - Failed to start HTTP server, please check the port is available.":"Thino - Kunne ikke starte HTTP-server, kontroller venligst om porten er tilgængelig.","Thino - Started HTTP server on port":"Thino - Startede HTTP-server på port","Thino - Terminated HTTP server":"Thino - Afsluttede HTTP-server","File not exist":"Fil eksisterer ikke","Thino not found":"Thino ikke fundet","File not found for the given thino path, is creating a new file":"Fil ikke fundet for den angivne thino-sti, opretter en ny fil","Saved sync token successfully":"Gemte synkroniseringstoken med succes","Failed to find daily notes folder":"Kunne ikke finde mappe til daglige noter","Please install obsidian-hover-editor plugin first":"Installer venligst obsidian-hover-editor plugin først","Copied app id successfully":"Kopierede app-id med succes","Please input token first":"Indtast venligst token først","Please enable sync first":"Aktiver venligst synkronisering først","Init Failed":"Initialisering mislykkedes","Verify successfully":"Verificeret med succes","Failed to verify":"Kunne ikke verificere","Folder not found for the given thino path, is creating a new folder":"Mappe ikke fundet for den angivne thino-sti, opretter en ny mappe","File not found for the given thino path":"Fil ikke fundet for den angivne thino-sti","Failed to read current daily note, check if it exists.":"Kunne ikke læse aktuel daglig note, kontroller om den eksisterer.","Failed to save":"Kunne ikke gemme","Failed to login, please login again":"Kunne ikke logge ind, log venligst ind igen","COPY FAILED":"KOPIERING MISLYKKEDES","COPY SUCCEED":"KOPIERING LYKKEDES","Copy selected text":"Kopier valgt tekst","Copy thino":"Kopier thino",COPY:"KOPIER","This is a pro feature, please upgrade to pro version to use it.":"Dette er en pro-funktion, opgrader venligst til pro-versionen for at bruge den.","You can get pro version from: ":"Du kan få pro-versionen fra: ",Save:"Gem",Cancel:"Annuller","Thino Daily Target":"Thino dagligt mål",Input:"Input","#Tag":"#Tag","to create tag":"for at oprette tag","You have verified your account. Congrats!":"Du har verificeret din konto. Tillykke!","Pro features":"Pro-funktioner","Target Thino Count":"Målrettet Thino-antal",on:"på","Switch waterfall view":"Skift vandfald-visning","Switch view":"Skift visning","Switch list view":"Skift listevisning","Set daily target":"Indstil dagligt mål","Thino Save To: ":"Thino gem til: ","Enter fullscreen mode":"Gå til fuldskærmstilstand","Exit fullscreen mode":"Afslut fuldskærmstilstand",words:"ord",word:"ord","Return To Home Page":"Tilbage til hjemmesiden","No thinos to review!":"Ingen thinos at gennemgå!","Thinos to review":"Thinos til gennemgang","Start Review":"Start gennemgang",Hard:"Svær",Good:"God",Easy:"Let",Again:"Igen","Clear all review data":"Ryd alle gennemgangsdata","Daily Progress":"Daglig fremgang","Show stats":"Vis statistik","Hide stats":"Skjul statistik",Remaining:"Resterende","Total Reviews":"Samlede gennemgange","Today, you have reviewed all your thinos!":"I dag har du gennemgået alle dine thinos!","Daily review limit reached! Come back tomorrow.":"Daglig gennemgangsgrænse nået! Kom tilbage i morgen.","Open thino in center window":"Åbn thino i centervindue","Open thino in float window":"Åbn thino i flydende vindue","Open thino in right sidebar":"Åbn thino i højre sidepanel","Open thino in left sidebar":"Åbn thino i venstre sidepanel","Show thino editor":"Vis thino-editor","Toggle minimal mode":"Skift minimal tilstand","Focus on thino editor":"Fokuser på thino-editor","ReSync web thinos to local":"Gensynkroniser web-thinos til lokal","Sync local thinos to web":"Synkroniser lokale thinos til web","Show daily thino":"Vis daglig thino","Focus on search bar":"Fokuser på søgefelt","Show-thino in popover(Hover editor)":"Vis-thino i popover(Hover editor)","Center window":"Centervindue","You should set the same heading below if you want to insert and process thino below the same heading.":"Du bør indstille samme rubrik nedenfor, hvis du vil indsætte og behandle thino under samme rubrik.","Float window":"Flydende vindue","Right sidebar":"Højre sidepanel","Left sidebar":"Venstre sidepanel","Save thino type when sync local":"Gem thino-type når lokal synkronisering","Set the default save thino type when sync local, FILE by default.":"Indstil standard gem type for thino når lokal synkronisering, FILE som standard.","Sync service":"Synkroniseringsservice","Pro verification status":"Pro-verificering status","Live-preview":"Live-preview",Source:"Kilde","Global copy":"Global kopi","Set the folder name":"Indstil mappe-navn","Set the filename":"Indstil filnavn","Set the filename for current location file":"Indstil filnavn for aktuel sti","Switch calendar type":"Skift kalender-type",alphabetical:"alfabetisk",alphabeticalReverse:"alfabetiskReverse",byCount:"byCount",byCountReverse:"byCountReverse","Type here":"Type her",Today:"I dag",Yesterday:"I går","Last 7 days":"Sidste 7 dage","Last 30 days":"Sidste 30 dage","Last 90 days":"Sidste 90 dage","Last 180 days":"Sidste 180 dage","Last 365 days":"Sidste 365 dage",Found:"Fundet","Copy filtered thinos":"Kopier filtrerede thinos","Bulk delete":"Bulk slet","Bulk archive":"Bulk arkiver","Bulk tag operation":"Bulk tag operation","Bulk restore":"Bulk gendan","If you are disabling the daily note plugin, it would be possible that the thino will not be deleted or patched properly. Please enable the plugin and try again.":"Hvis du deaktiverer daglige notesplugin, kan det være, at thino ikke bliver slettet eller repareret korrekt. Aktiver plugin og prøv igen.",Preview:"Forhåndsvisning","Set and save":"Indstil og gem","Show day mark in thino list":"Vis dagmarke i thino-liste","Show day mark on the top of daily range thino. False by default.":"Vis dagmarke i toppen af daglige thino-rækker. False som standard.","Click to expand or fold, Cmd+Click to show all thinos of the day":"Klik for at udvide eller fold, Cmd+Klik for at vise alle thinos af dagen","You can buy a license from":"Du kan købe en licens fra","No thinos in range":"Ingen thinos i række",Month:"Måned",Week:"Uge",Day:"Dag",Agenda:"Agenda",Tomorrow:"I morgen",Previous:"Forrige",Next:"Næste","Search all columns...":"Søg i alle kolonner...","Basic Info":"Grundlæggende info","Additional Info":"Yderligere info","Created At":"Oprettet den",Content:"Indhold","Thino Type":"Thino-type","Source Type":"Kildetype","Row status":"Række status",Path:"Sti","Pinned Status":"Fastgjort status",Table:"Tabel",Chat:"Chat",Moments:"Øjeblikke",Waterfall:"Vandfald",Calendar:"Kalender","Go to page":"Gå til side",Page:"Side",Show:"Vis",rows:"rækker","Temp Filter":"Midlertidig filter","Open link directly in Thino view":"Åbn link direkte i Thino-visning","Day mark range":"Dagmærke-område","Set the range of day mark. Day by default.":"Indstil området for dagmærke. Dag som standard.","Thino is locked":"Thino er låst","Please unlock Thino by input password":"Lås venligst Thino op ved at indtaste adgangskode","Auto Download Image":"Auto-download billede","Auto download image when save to thino. 'false' by default":"Auto-download billede når der gemmes til thino. 'false' som standard","Thino Http IP Type":"Thino Http IP-type","Set Thino http server ip to listen. 'localhost' by default":"Indstil Thino http-server IP til at lytte. 'localhost' som standard","Password to lock Thino":"Adgangskode til at låse Thino",Unlock:"Lås op",Locked:"Låst","Password is incorrect":"Adgangskoden er forkert",Lock:"Lås","Need password to unlock Thino":"Adgangskode påkrævet for at låse Thino op","You have not set a password or enable this feature yet":"Du har ikke indstillet en adgangskode eller aktiveret denne funktion endnu",Password:"Adgangskode","Password for Thino":"Adgangskode til Thino","Please input your password to change password settings":"Indtast venligst din adgangskode for at ændre adgangskodeindstillinger","Please input your password":"Indtast venligst din adgangskode","Lock thino":"Lås thino",date:"dato",time:"tid",event:"begivenhed","Add tag position":"Tilføj tag-position","Set the position of the tag when adding tag automatically":"Indstil positionen af tagget når der tilføjes tag automatisk","Add tag automatically":"Tilføj tag automatisk","Add tag to the end or beginning of the thino content when creating a thino and filtering tags":"Tilføj tag til slutningen eller begyndelsen af thino-indholdet når der oprettes en thino og filtreres tags","Add tag with new line":"Tilføj tag med ny linje","Add tag with new line when adding tag automatically":"Tilføj tag med ny linje når der tilføjes tag automatisk","Input to select more tags":"Indtast for at vælge flere tags","Tag Bulk Edit":"Tag masseredigering","Tag Bulk Select":"Tag massevalg","Exist Tags":"Eksisterende tags","Selected Tags":"Valgte tags","Click to remove exist tag":"Klik for at fjerne eksisterende tag","Click to remove selected tag":"Klik for at fjerne valgt tag","Select tags":"Vælg tags","Input to select exist tag":"Indtast for at vælge eksisterende tag",Beginning:"Begyndelse",End:"Slutning","Set the heading for saving thino":"Indstil overskriften for at gemme thino","# Heading":"# Overskrift","Chat view style":"Chat-visningsstil","Set the style of chat view":"Indstil stilen for chat-visning","Background image for moments view":"Baggrundsbillede for øjeblikke-visning","Set the background image for moments view":"Indstil baggrundsbilledet for øjeblikke-visning","Icon for moments/chat view/share image":"Ikon for øjeblikke/chat-visning/delt billede","Set the icon for moments/chat view/share image":"Indstil ikonet for øjeblikke/chat-visning/delt billede","Quote for moments view/share image":"Citat for øjeblikke-visning/delt billede","Set the quote for moments view/share image":"Indstil citatet for øjeblikke-visning/delt billede","Theme for Thino":"Tema for Thino","Set the theme for Thino":"Indstil temaet for Thino","Interface Details":"Grænsefladedetaljer","Task amount":"Opgavemængde","Thino status":"Thino-status","Used tags":"Brugte tags","Used days":"Brugte dage","Most active day":"Mest aktive dag","Most active hour":"Mest aktive time","Thino amount":"Thino-mængde","No content to generate.":"Intet indhold at generere.","Image generated successfully.":"Billede genereret med succes.","Failed to generate image.":"Kunne ikke generere billede.","Share filtered thinos as image":"Del filtrerede thinos som billede","Latest version":"Seneste version","Previous version":"Tidligere version","Thino update info":"Thino opdateringsinfo","Debug info copied to clipboard":"Fejlfindingsinfo kopieret til udklipsholder","Copy debug info":"Kopier fejlfindingsinfo","Failed to load changelog":"Kunne ikke indlæse ændringslog","View online":"Se online",ChangeLog:"Ændringslog","Please open thino first":"Åbn venligst thino først","Insert editor":"Indsæt editor","Please set different save locations for multi-file settings in Thino. The diary folder overlaps with the multi-file save location, or there is a risk of it being read repeatedly.":"Indstil venligst forskellige gemmeplacering for multi-fil-indstillinger i Thino. Dagbogsmappen overlapper med multi-fil-gemmeplaceringen, eller der er risiko for at den bliver læst gentagne gange.","Default time prefix for thino in daily notes":"Standard tidspræfiks for thino i daglige noter","Set default time prefix for thino in daily notes.":"Indstil standard tidspræfiks for thino i daglige noter.","Save image successfully":"Gem billede med succes","User quote":"Brugercitat","Set user quote for thino":"Indstil brugercitat for thino","User icon":"Brugerikon","Set user icon for thino. You can input http/https link or file path in vault.":"Indstil brugerikon for thino. Du kan indtaste http/https-link eller filsti i boks.","User info":"Brugerinfo","Copy filtered results":"Kopier filtrerede resultater","Share image":"Del billede",Default:"Standard",Gray:"Grå",Grass:"Græs",Flame:"Flamme",Olive:"Oliven",Ice:"Is",Magenta:"Magenta","Daily notes":"Daglige noter",Editor:"Editor","Append/prepend text when share to Thino":"Tilføj/foranstil tekst når der deles til Thino","Append text when share to Thino":"Tilføj tekst når der deles til Thino","Prepend text when share to Thino":"Foranstil tekst når der deles til Thino","Add newline when append/prepend text":"Tilføj ny linje når der tilføjes/foranstilles tekst","Input anything here":"Indtast hvad som helst her",Prepend:"Foranstil",Append:"Tilføj",Both:"Begge",None:"Ingen","Hide pinned group":"Skjul fastgjort gruppe","Hide pinned group in thino list. False by default.":"Skjul fastgjort gruppe i thino-liste. Falsk som standard.","Set the heading for the task type of thino, by default the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"Indstil overskriften for opgavetypen af thino, som standard vil det registrerede thino-indhold blive indsat i slutningen af dagbogen; hvis en titel er angivet, vil alt registreret thino-indhold blive ensartet kategoriseret under den titel.","Different insert target for different type":"Forskelligt indsætningsmål for forskellige typer","Toggle this to set different insert target for different type of thino, like task or list type of thino":"Skift dette for at indstille forskellige indsætningsmål for forskellige typer af thino, som opgave- eller listetyper af thino","You can set whole diary or only part of it":"Du kan indstille hele dagbogen eller kun en del af den","Set process target":"Indstil procesmål",Custom:"Tilpasset","Whole diary":"Hele dagbogen","Set thino insert place":"Indstil thino indsætningssted","Set where to insert thino content":"Indstil hvor thino-indhold skal indsættes","End of the diary":"Slutningen af dagbogen","Custom location":"Tilpasset placering","Setting guide":"Indstillingsguide","Details settings":"Detaljerede indstillinger","Start Thino":"Start Thino","About Thino Pro":"Om Thino Pro",Enabled:"Aktiveret",Enable:"Aktiver","Daily notes folder":"Daglige noter-mappe","Set daily notes folder":"Indstil daglige noter-mappe","Daily note name format":"Daglig note navneformat","Set daily note name format":"Indstil daglig note navneformat","Daily note plugin":"Daglig note-plugin","Enable daily note plugin":"Aktiver daglig note-plugin",Selected:"Valgt",Select:"Vælg","A classic theme for Thino with a two-column layout":"Et klassisk tema for Thino med et to-kolonne layout",Classic:"Klassisk","A modern theme for Thino with a three-column layout and some unique features.":"Et moderne tema for Thino med et tre-kolonne layout og nogle unikke funktioner.",Modern:"Moderne","Go and enjoy Thino":"Gå og nyd Thino","Congrats! All settings done":"Tillykke! Alle indstillinger er færdige","Adjust settings that influence your user experience with Thino.":"Juster indstillinger der påvirker din brugeroplevelse med Thino.","Set preferences for using Thino":"Indstil præferencer for brug af Thino","If you are using the Thino basic version, enabling the daily note plugin is required. Configure its settings to work effectively with it.":"Hvis du bruger Thino basisversionen, er aktivering af daglig note-plugin påkrævet. Konfigurer dets indstillinger for at arbejde effektivt med det.","Go with daily note plugin":"Gå med daglig note-plugin","Choose a theme for Thino.":"Vælg et tema til Thino.","Set theme for Thino":"Indstil tema for Thino","Set up your user info for Thino.":"Opsæt din brugerinfo for Thino.","Get started with Thino":"Kom i gang med Thino","Skip and start Thino":"Spring over og start Thino","Next step":"Næste trin","Back to previous step":"Tilbage til forrige trin","Click to enable =>":"Klik for at aktivere =>","This is Thino's sidebar. Navigate to different path or select query filter.":"Dette er Thino's sidepanel. Naviger til forskellige stier eller vælg forespørgselsfilter.","Click here and go to settings page.":"Klik her og gå til indstillingssiden.","Click here and go to different path.":"Klik her og gå til forskellige stier.","Select or create query filter here.":"Vælg eller opret forespørgselsfilter her.","See the status of Thinos here.":"Se status for Thinos her.","Search your thino quickly here.":"Søg hurtigt efter din thino her.","Edit or create your thino here.":"Rediger eller opret din thino her.","See your thinos here.":"Se dine thinos her.","See your time status of thinos here.":"Se din tidsstatus for thinos her.","See your tags here. Tags will be shown when thino contains tags.":"Se dine tags her. Tags vil blive vist når thino indeholder tags.",Done:"Færdig","Thino is ready to use. ":"Thino er klar til brug. ","You can start using Thino now. If you want to know more about Thino Pro, click the button below.":"Du kan begynde at bruge Thino nu. Hvis du vil vide mere om Thino Pro, klik på knappen nedenfor.","Default time prefix":"Standard tidspræfiks","Append Text Action":"Tilføj tekst-handling","Prepend Text Action":"Foranstil tekst-handling",Preset:"Forudindstilling","Select Tags":"Vælg Tags","It is not available on small view":"Det er ikke tilgængeligt på lille visning","Append text":"Tilføj tekst","Prepend text":"Foranstil tekst","Your daily note folder is not set correctly, please check your settings":"Din daglige note-mappe er ikke indstillet korrekt, tjek venligst dine indstillinger","Default sharing style":"Standard delingsstil","Set the default style for sharing thino, 'Modern' by default.":'Indstil standardstilen for deling af thino, "Moderne" som standard.',Clean:"Ren",Minimal:"Minimal",Gradient:"Gradient","Thino share":"Thino-deling","Copy to clipboard failed":"Kopiering til udklipsholder mislykkedes","Copy to clipboard successfully":"Kopieret til udklipsholder med succes","Your content has been copied to clipboard, and inserted into the editor. Please try it again":"Dit indhold er blevet kopieret til udklipsholderen og indsat i editoren. Prøv venligst igen","Share thino":"Del thino","Set file name after create thino":"Indstil filnavn efter oprettelse af thino","You can set file name after create thino. A input box will show when you create thino.":"Du kan indstille filnavn efter oprettelse af thino. En inputboks vil blive vist, når du opretter thino.",SPLIT:"OPDEL","Split by Heading 1":"Opdel efter Overskrift 1","Split by Heading 2":"Opdel efter Overskrift 2","Split by Heading 3":"Opdel efter Overskrift 3","Insert task":"Indsæt opgave","All settings have been reset to default.":"Alle indstillinger er blevet nulstillet til standard.","Reset all Thino settings":"Nulstil alle Thino-indstillinger","Reset settings":"Nulstil indstillinger","Reset Thino settings to default settings.":"Nulstil Thino-indstillinger til standardindstillinger.","Task Management":"Opgavestyring","Append completed date when task done in thino":"Tilføj fuldført dato når opgave er udført i thino","Append completed date when task done in thino. False by default":"Tilføj fuldført dato når opgave er udført i thino. Falsk som standard","Set tag for single file that Thino indexes":"Indstil tag for enkelt fil som Thino indekserer","When you set a tag here, Thino will index this file contains this tag and show it in the list. Don't need to add `#`.":"Når du indstiller et tag her, vil Thino indeksere denne fil indeholder dette tag og vise det i listen. Behøver ikke at tilføje `#`.","Set tag for file type file":"Indstil tag for filtype-fil","Set tag for multi type file":"Indstil tag for multi-type fil","Please input the tag":"Indtast venligst tagget","Merge thinos in to thino share image":"Flet thinos ind i thino-delingsbillede","Custom height for Thino content":"Tilpasset højde for Thino-indhold","Set custom height for Thino content. Like 200px or 20rem":"Indstil tilpasset højde for Thino-indhold. Som 200px eller 20rem","Input height":"Indtast højde","Submit issue":"Indsend problem","Current version":"Nuværende version","Bug report":"Fejlrapport","Click the button to copy debug info and open the issue page":"Klik på knappen for at kopiere fejlfindingsinfo og åbne problemsiden","Copy and go":"Kopier og gå","Debug info copied":"Fejlfindingsinfo kopieret","Feature request":"Funktionsanmodning","Submit your feature request to the issue page":"Indsend din funktionsanmodning til problemsiden",Go:"Gå","Toggle query list visibility":"Skift synlighed for forespørgselsliste","Toggle tags visibility":"Skift synlighed for tags","Toggle sidebar visibility":"Skift synlighed for sidepanel",Collapse:"Sammenfold",Expand:"Udvid","Max height for collapse":"Maksimal højde for sammenfoldning","The max height for thino collapse, when set 0, thino would not collapse. 0 by default. (This is not lines count, it is height in px.)":"Den maksimale højde for thino-sammenfoldning, når indstillet til 0, vil thino ikke folde sammen. 0 som standard. (Dette er ikke linjeantal, det er højde i px.)","Render content":"Generer indhold","Optimize for Callout":"Optimer for Callout","Won't render content contains more than 3 callouts automatically. True by default":"Vil ikke automatisk gengive indhold, der indeholder mere end 3 callouts. Sand som standard","The value should be greater than":"Værdien skal være større end","Append Text":"Tilføj tekst","Prepend Text":"Foranstil tekst","Thino height when collapsed":"Thino-højde når sammenfoldet","The height for thino when it is collapsed, when set 0, thino would not collapse. 100 by default. (This is not lines count, it is height in px.)":"Højden for thino når den er sammenfoldet, når indstillet til 0, vil thino ikke folde sammen. 100 som standard. (Dette er ikke linjeantal, det er højde i px.)","This option will allow you use other views when leaf width is not enough. False by default.":"Denne mulighed vil tillade dig at bruge andre visninger, når bladbredden ikke er tilstrækkelig. Falsk som standard.","Can select other views when leaf width is not enough":"Kan vælge andre visninger, når bladbredden ikke er tilstrækkelig","TRASH BOX":"PAPIRKURV","Wait templater to finish parse before insert thino":"Vent på at skabelonbehandler færdiggør parsing før indsættelse af thino","This option will allow you to wait for templater to finish parse before insert thino, which may casue you need to confirm twice between insert thino. False by default.":"Denne mulighed vil tillade dig at vente på at skabelonbehandleren færdiggør parsing før indsættelse af thino, hvilket kan medføre at du skal bekræfte to gange mellem indsættelse af thino. Falsk som standard.","Get thino capture extension":"Få thino-optagelsesudvidelse","You can capture idea/text from chrome now.":"Du kan nu optage idé/tekst fra Chrome.","Open File":"Åbn fil","Exported CSV file":"Eksporteret CSV-fil","Updated At":"Opdateret den","Export to CSV":"Eksporter til CSV","Quick add button on mobile navbar":"Hurtig tilføj-knap på mobil navigationslinje","Always show status text":"Vis altid statustekst","Support filter by metadata from file":"Understøt filtrering efter metadata fra fil","When enable this, you can filter via metadata from file, like tags in file. But thinos from canvas is not supported. False by default.":"Når dette aktiveres, kan du filtrere via metadata fra fil, som tags i fil. Men thinos fra lærred understøttes ikke. Falsk som standard.","Show source near timestamp in thino":"Vis kilde nær tidsstempel i thino","When enable this, you can see the source near timestamp in thino. You can set title in metadata to overwrite this. False by default.":"Når dette aktiveres, kan du se kilden nær tidsstemplet i thino. Du kan indstille titel i metadata for at overskrive dette. Falsk som standard.","Show Update Message":"Vis opdateringsbesked","Show update message when Thino is updated. True by default":"Vis opdateringsbesked når Thino opdateres. Sand som standard","Sync manually":"Synkroniser manuelt","Show all scrollbars":"Vis alle rullebjælker","TIME RANGE":"TIDSINTERVAL",WITHIN:"INDEN FOR","7 days":"7 dage","14 days":"14 dage","30 days":"30 dage","3 months":"3 måneder","6 months":"6 måneder","1 year":"1 år","This week":"Denne uge","Last week":"Sidste uge","This month":"Denne måned","Last month":"Sidste måned","This year":"Dette år","Last year":"Sidste år","No history":"Ingen historik","Today Remaining":"Resterende i dag","Today Total":"I alt i dag","Historical Statistics":"Historisk statistik",byTime:"Efter tid",byTimeReverse:"Efter tid omvendt",Stat:"Statistik",Statistics:"Statistikker","Daily Thino Count":"Daglig Thino-antal",Total:"Total",thinos:"thinos","Thino Types":"Thino-typer","Distribution of thino types":"Fordeling af thino-typer","Thino Status":"Thino-status","Distribution of thino status":"Fordeling af thino-status","Popular Tags":"Populære tags","Top 10 most used tags":"Top 10 mest brugte tags","Thino Count":"Thino-antal","Hourly distribution":"Timefordeling","Current month":"Nuværende måned","Monthly distribution":"Månedlig fordeling","30 Days":"Sidste 30 dage",Year:"År","Time Distribution":"Tidsfordeling","When do you write thinos":"Hvornår skriver du thinos","Content Length":"Indholdslængde","Distribution of thino lengths":"Fordeling af thino-længder","Daily Thinos":"Daglige Thinos","Show Time Distribution":"Vis tidsfordeling","Hide date picker":"Skjul datoværktøj","Show date picker":"Vis datoværktøj","Clear filter":"Ryd filter","Copy link":"Kopier link","Copy embed link":"Kopier indlejringslink","Ctrl/Cmd + Enter to save thino":"Ctrl/Cmd + Enter for at gemme thino","Fixed strings for thinos":"Faste strenge for thinos","Use fixed strings for thinos":"Brug faste strenge for thinos","Enable to add fixed strings at the beginning or end of thinos.":"Aktiver for at tilføje faste strenge i begyndelsen eller slutningen af thinos.","Fixed prefix for thinos":"Fast præfiks for thinos","Add this string at the beginning of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"Tilføj denne streng i begyndelsen af hver thino. Understøtter pladsholdere som {{TIME|YYYYMMDDHHmmss}}.","Fixed suffix for thinos":"Fast suffiks for thinos","Add this string at the end of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"Tilføj denne streng i slutningen af hver thino. Understøtter pladsholdere som {{TIME|YYYYMMDDHHmmss}}.","Word count exceeded":"Ordantal overskredet","Word count feature":"Ordtællingsfunktion","Enable real-time word count display in the editor":"Aktiver realtids ordtælling i editoren","Maximum word count":"Maksimalt ordantal","Set a maximum word count for thino. Editor will display a warning when exceeded. Set to 0 for unlimited.":"Indstil et maksimalt ordantal for thino. Editoren vil vise en advarsel når det overskrides. Indstil til 0 for ubegrænset.","No linked thinos found":"Ingen linkede thinos fundet","Reference links group":"Referencelinks-gruppe","Enable reference links group in thino.":"Aktiver referencelinks-gruppe i thino.","No reference links found":"Ingen referencelinks fundet","Outgoing Links":"Udgående links","Incoming Links":"Indgående links","Error fetching reference links":"Fejl ved hentning af referencelinks","Double click behavior":"Dobbeltklik-adfærd","Set the behavior when double click on a thino.":"Indstil adfærden ved dobbeltklik på en thino.","Open thino":"Åbn thino","Edit thino":"Rediger thino","Go to source":"Gå til kilde","Do nothing":"Gør ingenting","Use default header in mobile view":"Brug standardoverskrift i mobilvisning","Use default header in mobile view of thino rather than custom header.":"Brug standardoverskrift i mobilvisning af thino i stedet for en custom overskrift."},q$={welcome:"Willkommen bei Thino",ribbonIconTitle:"Thino",to:"zu",months:["Januar","Februar","März","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"],monthsShort:["Jan.","Feb.","März","Apr.","Mai","Juni","Juli","Aug.","Sept.","Okt.","Nov.","Dez."],weekDays:["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"],weekDaysShort:["So","Mo","Di","Mi","Do","Fr","Sa"],year:null,month:null,"Basic Options":"Grundeinstellungen","User name":"Benutzername","Set your user name here. 'Memos 😏' By default":"Setze deinen Benutzernamen hier. 'Thino 😏' als Standard",'You can set target heading like "# Heading" to control data location':'Du kannst eine Zielüberschrift wie "# Überschrift" setzen, um den Datenspeicherort zu steuern',"Insert after heading":"Nach Überschrift einfügen","If left blank, the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"Wenn leer gelassen, wird der aufgezeichnete Thino-Inhalt am Ende des Tagebuchs eingefügt; wenn ein Titel angegeben wird, werden alle aufgezeichneten Thino-Inhalte einheitlich unter diesem Titel kategorisiert.","Allows admonitions to be created using ":"Erlaubt das Erstellen von Hinweisen mit ","Process Memos below":"Thinos unten verarbeiten","If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.":"Wenn leer gelassen, zeigt die Thino-Oberfläche alle Thino-Aufzeichnungen an; wenn ein Titel angegeben wird, zeigt die Thino-Oberfläche nur die Inhalte unter diesem Titel an, und anderswo geschriebene Inhalte werden nicht angezeigt.","Save Memo button label":"Beschriftung des Thino-Speichern-Buttons","The text shown on the save Memo button in the UI. 'NOTEIT' by default.":"Der Text, der auf dem Thino-Speichern-Button in der Benutzeroberfläche angezeigt wird. 'NOTEIT' als Standard.","Focus on editor when open memos":"Fokus auf Editor beim Öffnen von Thino","Focus on editor when open memos. Focus by default.":"Fokus auf Editor beim Öffnen von Thino. Standardmäßig fokussiert.","Open daily memos with open memos":"Tägliche Thinos beim Öffnen von Thino öffnen","Open daily memos with open memos. Open by default.":"Tägliche Thinos beim Öffnen von Thino öffnen. Standardmäßig geöffnet.","Open Memos when obsidian opens":"Thino beim Öffnen von Obsidian öffnen","When enable this, Memos will open when Obsidian opens. False by default.":"Wenn aktiviert, wird Thino beim Öffnen von Obsidian geöffnet. Standardmäßig deaktiviert.","Hide done tasks in Memo list":"Erledigte Aufgaben in der Thino-Liste ausblenden","Hide all done tasks in Memo list. Show done tasks by default.":"Alle erledigten Aufgaben in der Thino-Liste ausblenden. Standardmäßig werden erledigte Aufgaben angezeigt.","Advanced Options":"Erweiterte Einstellungen","UI language for date":"UI-Sprache für Datum","Translates the date UI language. Only 'en' and 'zh' are available.":"Übersetzt die Datums-UI-Sprache. Nur 'en' und 'zh' sind verfügbar.","Default prefix when save thino":"Standardpräfix beim Speichern von Thino","Set the default prefix when create memo, 'List' by default.":"Setze das Standardpräfix beim Erstellen von Thino, 'Liste' als Standard.","Default insert date format":"Standardformat für Datumseinfügung","Set the default date format when insert date by @, 'Tasks' by default.":"Setze das Standarddatumsformat beim Einfügen von Datum mit @, 'Aufgaben' als Standard.","Default editor position on mobile":"Standardposition des Editors auf Mobilgeräten","Set the default editor position on Mobile, 'Top' by default.":"Setze die Standardposition des Editors auf Mobilgeräten, 'Oben' als Standard.","Use button to show editor on mobile":"Button zum Anzeigen des Editors auf Mobilgeräten verwenden","Set a float button to call editor on mobile. Only when editor located at the bottom works.":"Setze einen schwebenden Button, um den Editor auf Mobilgeräten aufzurufen. Funktioniert nur, wenn der Editor unten positioniert ist.","Show Time When Copy Results":"Zeit beim Kopieren der Ergebnisse anzeigen","Show time when you copy results, like 12:00. Copy time by default.":"Zeit beim Kopieren der Ergebnisse anzeigen, wie 12:00. Standardmäßig wird die Zeit kopiert.","Show Date When Copy Results":"Datum beim Kopieren der Ergebnisse anzeigen","Show date when you copy results, like [[2022-01-01]]. Copy date by default.":"Datum beim Kopieren der Ergebnisse anzeigen, wie [[2022-01-01]]. Standardmäßig wird das Datum kopiert.","Add Blank Line Between Different Date":"Leerzeile zwischen verschiedenen Daten einfügen","Add blank line when copy result with date. No blank line by default.":"Leerzeile beim Kopieren von Ergebnissen mit Datum einfügen. Standardmäßig keine Leerzeile.","Share Options":"Freigabeoptionen","Share Memos Image Footer Start":"Start der Fußzeile beim Teilen von Thino-Bildern","Set anything you want here, use {ThinoNum} to display Number of thino, {UsedDay} for days. '{ThinoNum} Thino {UsedDay} Days' By default":"Setze hier beliebigen Text, verwende {ThinoNum} für die Anzahl der Thinos, {UsedDay} für Tage. '{ThinoNum} Thino {UsedDay} Tage' als Standard","Share Memos Image Footer End":"Ende der Fußzeile beim Teilen von Thino-Bildern","Set anything you want here, use {UserName} as your username. '✍️ By {UserName}' By default":"Setze hier beliebigen Text, verwende {UserName} als deinen Benutzernamen. '✍️ Von {UserName}' als Standard","Save Shared Image To Folder For Mobile":"Geteiltes Bild für Mobilgeräte in Ordner speichern","Save image to folder for mobile. False by Default":"Bild für Mobilgeräte in Ordner speichern. Standardmäßig deaktiviert","Say Thank You":"Danke sagen",Donate:"Spenden","If you like this plugin, consider donating to support continued development:":"Wenn dir dieses Plugin gefällt, erwäge eine Spende zur Unterstützung der weiteren Entwicklung:","File Name of Recycle Bin":"Dateiname des Papierkorbs","Set the filename for recycle bin. 'delete' By default":"Setze den Dateinamen für den Papierkorb. 'delete' als Standard","File Name of Query File":"Dateiname der Abfragedatei","Set the filename for query file. 'query' By default":"Setze den Dateinamen für die Abfragedatei. 'query' als Standard","Use Tags In Vault":"Tags im Vault verwenden","Use tags in vault rather than only in Memos. False by default.":"Tags im Vault anstatt nur in Thino verwenden. Standardmäßig deaktiviert.","Ready to convert image into background":"Bereit, Bild in Hintergrund umzuwandeln",List:"Liste",Task:"Aufgabe",Top:"Oben",Bottom:"Unten",TAG:"TAG",DAY:"TAG",QUERY:"ABFRAGE",EDIT:"BEARBEITEN",PIN:"ANHEFTEN",UNPIN:"LÖSEN",DELETE:"LÖSCHEN","CONFIRM!":"BESTÄTIGEN!","CREATE FILTER":"FILTER ERSTELLEN","Comment it...":"Kommentieren...",Settings:"Einstellungen","Recycle bin":"Papierkorb","About Me":"Über mich","Fetching data...":"Daten werden geladen...","Here is No Memos.":"Keine Thinos vorhanden.","Frequently Used Tags":"Häufig verwendete Tags","What do you think now...":"Was denkst du gerade...",READ:"LESEN",MARK:"MARKIEREN",SHARE:"TEILEN",SOURCE:"QUELLE",RESTORE:"WIEDERHERSTELLEN",ARCHIVE:"ARCHIVIEREN","Daily Review":"Tagesrückblick","DELETE AT":"GELÖSCHT AM","Noooop!":"Nööö!","All Data is Loaded 🎉":"Alle Daten geladen 🎉","Quick filter":"Schnellfilter",TYPE:"TYP",LINKED:"VERLINKT","NO TAGS":"KEINE TAGS","HAS LINKS":"HAT LINKS","HAS IMAGES":"HAT BILDER",INCLUDE:"EINSCHLIESSEN",EXCLUDE:"AUSSCHLIESSEN",TEXT:"TEXT",IS:"IST",AND:"UND",OR:"ODER",LIST:"LISTE",ISNOT:"IST NICHT",PATH:"PFAD",METADATA:"METADATEN",SELECT:"AUSWÄHLEN","ADD FILTER TERMS":"FILTERKRITERIEN HINZUFÜGEN",FILTER:"FILTER",Filter:"Filter",TITLE:"TITEL","CREATE QUERY":"ABFRAGE ERSTELLEN","EDIT QUERY":"ABFRAGE BEARBEITEN",MATCH:"ÜBEREINSTIMMUNG",TIMES:"ZEITEN","Share Memo Image":"Thino-Bild teilen","↗Click the button to save":"↗Klicke den Button zum Speichern","Image is generating...":"Bild wird generiert...","Image is loading...":"Bild wird geladen...","Loading...":"Lädt...","😟 Cannot load image, image link maybe broken":"😟 Bild kann nicht geladen werden, Link ist möglicherweise defekt","Daily Memos":"Tägliche Thinos","CANCEL EDIT":"BEARBEITUNG ABBRECHEN","LINK TO THE":"LINK ZUM","Mobile Options":"Mobile Optionen","Experimental Options":"Experimentelle Optionen","Don't support web image yet, please input image path in vault":"Webbilder werden noch nicht unterstützt, bitte Bildpfad im Vault eingeben","Background Image in Dark Theme":"Hintergrundbild im dunklen Theme","Background Image in Light Theme":"Hintergrundbild im hellen Theme",'Set background image in dark theme. Set something like "Daily/one.png"':'Setze Hintergrundbild im dunklen Theme. Setze etwas wie "Daily/one.png"','Set background image in light theme. Set something like "Daily/one.png"':'Setze Hintergrundbild im hellen Theme. Setze etwas wie "Daily/one.png"','Set default memo composition, you should use {TIME} as "HH:mm" and {CONTENT} as content. "{TIME} {CONTENT}" by default':'Setze Standard-Thino-Zusammensetzung, verwende {TIME} als "HH:mm" und {CONTENT} als Inhalt. "{TIME} {CONTENT}" als Standard',"Default Memo Composition":"[Veraltet] Standard-Thino-Zusammensetzung","Show Tasks Label":"Aufgaben-Label anzeigen","Show tasks label near the time text. False by default":"Aufgaben-Label neben dem Zeittext anzeigen. Standardmäßig deaktiviert","Please Open Memos First":"Bitte öffne zuerst Thino",DATE:"DATUM",OBSIDIAN_NLDATES_PLUGIN_NOT_ENABLED:"OBSIDIAN_NLDATES_PLUGIN_NICHT_AKTIVIERT",BEFORE:"VOR",AFTER:"NACH","Allow Comments On Memos":"Kommentare für Thinos erlauben","You can comment on memos. False by default":"Du kannst Thinos kommentieren. Standardmäßig deaktiviert",Import:"Importieren","TITLE CANNOT BE NULL!":"TITEL DARF NICHT LEER SEIN!","FILTER CANNOT BE NULL!":"FILTER DARF NICHT LEER SEIN!","Comments In Original DailyNotes/Notes":"Kommentare in Original-Tagesnotizen/Notizen","You should install Dataview Plugin ver 0.5.9 or later to use this feature.":"Du solltest das Dataview Plugin Ver. 0.5.9 oder höher installieren, um diese Funktion zu nutzen.","Open Memos Successfully":"Thino erfolgreich geöffnet","Fetch Memos Error":"😭 Fehler beim Laden","Copied to clipboard Successfully":"Erfolgreich in die Zwischenablage kopiert","Check if you opened Daily Notes Plugin Or Periodic Notes Plugin":"Prüfe, ob du das Daily Notes Plugin oder Periodic Notes Plugin geöffnet hast","Please finish the last filter setting first":"Bitte beende zuerst die letzte Filtereinstellung","Close Memos Successfully":"Thino erfolgreich geschlossen","Insert as Memo":"Als Thino einfügen","Insert file as memo content":"Datei als Thino-Inhalt einfügen","Image load failed":"Bildladung fehlgeschlagen","Content cannot be empty":"Inhalt darf nicht leer sein","Unable to create new file.":"Neue Datei konnte nicht erstellt werden.","Failed to fetch deleted memos: ":"Fehler beim Laden gelöschter Thinos: ","RESTORE SUCCEED":"WIEDERHERSTELLUNG ERFOLGREICH","DELETE SUCCEED":"LÖSCHEN ERFOLGREICH","Save Memo button icon":"Thino-Speichern-Button-Symbol","The icon shown on the save Memo button in the UI.":"Das Symbol auf dem Thino-Speichern-Button in der Benutzeroberfläche.","Fetch Memos From Particular Notes":"Thinos aus bestimmten Notizen laden",'You can set any Dataview Query for memos to fetch it. All memos in those notes will show on list. "#memo" by default':'Du kannst jede Dataview-Abfrage für Thinos setzen. Alle Thinos in diesen Notizen werden in der Liste angezeigt. "#memo" als Standard',"Allow Memos to Fetch Memo from Notes":"Thino erlauben, Thinos aus Notizen zu laden","Use Memos to manage all memos in your notes, not only in daily notes. False by default":"Verwende Thino, um alle Thinos in deinen Notizen zu verwalten, nicht nur in Tagesnotizen. Standardmäßig deaktiviert","Always Show Memo Comments":"Thino-Kommentare immer anzeigen","Always show memo comments on memos. False by default":"Thino-Kommentare immer bei Thinos anzeigen. Standardmäßig deaktiviert","You didn't set folder for daily notes in both periodic-notes and daily-notes plugins.":"Du hast keinen Ordner für Tagesnotizen in beiden Plugins (periodic-notes und daily-notes) festgelegt.","Please check your daily note plugin OR periodic notes plugin settings":"Bitte überprüfe deine Einstellungen für das Daily Note Plugin ODER Periodic Notes Plugin","Use which plugin's default configuration":"Welche Plugin-Standardkonfiguration verwenden","Memos use the plugin's default configuration to fetch memos from daily, 'Daily' by default.":"Thino verwendet die Plugin-Standardkonfiguration zum Laden von Thinos aus Tagesnotizen, 'Daily' als Standard.",Daily:"Täglich","Always Show Leaf Sidebar on PC":"Seitenleiste auf PC immer anzeigen","Show left sidebar on PC/Tablet even when the leaf width is less than 875px. False by default.":"Linke Seitenleiste auf PC/Tablet auch bei einer Blattbreite unter 875px anzeigen. Standardmäßig deaktiviert.","You didn't set format for daily notes in both periodic-notes and daily-notes plugins.":"Du hast kein Format für Tagesnotizen in beiden Plugins (periodic-notes und daily-notes) festgelegt.","fetch more":"mehr laden","Search all settings":"Alle Einstellungen durchsuchen",General:"Allgemein",Theme:"Theme",Share:"Teilen",Advanced:"Erweitert",Thino:"Thino","Random Review":"Zufällige Überprüfung","ARCHIVED AT":"ARCHIVIERT AM","Failed to get memos from daily notes":"Fehler beim Laden von Thinos aus Tagesnotizen","Failed to delete memo":"Fehler beim Löschen des Thinos","CTRL + ENTER to save":"STRG + ENTER zum Speichern","Started from":"Gestartet von","Custom Background Image":"Benutzerdefiniertes Hintergrundbild","Set custom background image.":"Benutzerdefiniertes Hintergrundbild festlegen.","Custom Memo Footer":"Benutzerdefinierte Thino-Fußzeile","Set custom memo footer.":"Benutzerdefinierte Thino-Fußzeile festlegen.","Heatmap Color Scheme":"Heatmap-Farbschema","Set different color scheme for heatmap.":"Verschiedene Farbschemata für die Heatmap festlegen.","Enable Local Http Server":"Lokalen HTTP-Server aktivieren","Memos Http Server Port":"Thino HTTP-Server-Port","Set memos http server port to listen. '43999' by default":"Port für den Thino HTTP-Server festlegen. '43999' als Standard","Default Editor Mode":"Standard-Editor-Modus","Live-Preview Mode OR Source Mode.":"Live-Vorschau-Modus ODER Quelltext-Modus.","Save type for Thino":"Speichertyp für Thino",DAILY:"TÄGLICH",MULTI:"MEHRFACH",CANVAS:"LEINWAND",ALL:"ALLE",FILE:"DATEI",TODO:"TODO",DONE:"ERLEDIGT",JOURNAL:"JOURNAL",OTHER:"ANDERE","Failed to create daily note, check if it exists.":"Fehler beim Erstellen der Tagesnotiz, prüfe ob sie existiert.","Failed to create daily note. Please check if you created a folder for daily notes.":"Fehler beim Erstellen der Tagesnotiz. Bitte prüfe, ob du einen Ordner für Tagesnotizen erstellt hast.","After you verify your account, please refresh this page.":"Nach der Verifizierung deines Kontos aktualisiere bitte diese Seite.",Verify:"Verifizieren","Oops! You forget to verify insider account":"Ups! Du hast vergessen, das Insider-Konto zu verifizieren","If you have any questions, please contact us.":"Bei Fragen kontaktiere uns bitte.","Delete Thino Directly":"Thino direkt löschen","When delete thino directly, it will not be moved to trash. False by default.":"Wenn Thino direkt gelöscht wird, wird es nicht in den Papierkorb verschoben. Standardmäßig deaktiviert.","Enable opening thino globally":"Globales Öffnen von Thino aktivieren","Enable opening thino globally. False by default.":"Globales Öffnen von Thino aktivieren. Standardmäßig deaktiviert.","Key for opening thino globally":"Tastenkombination für globales Öffnen von Thino","Set key for opening thino globally. CTRL + SHIFT + T by default.":"Tastenkombination für globales Öffnen von Thino festlegen. STRG + SHIFT + T als Standard.","Key for showing thino globally":"Tastenkombination für globales Anzeigen von Thino","Set key for showing thino globally. CTRL + SHIFT + E by default.":"Tastenkombination für globales Anzeigen von Thino festlegen. STRG + SHIFT + E als Standard.","Get activation code":"Aktivierungscode erhalten","Input activation code here":"Aktivierungscode hier eingeben","Copy Thino id":"Thino-ID kopieren","Activate Pro Version":"Pro-Version aktivieren","Please copy Thino id first":"Bitte kopiere zuerst die Thino-ID",'You can set folder name with file name like "folder/file"':'Du kannst den Ordnernamen mit Dateinamen wie "ordner/datei" festlegen','You can set folder name like "folder1/folder2/folder3" to create sub-folder':'Du kannst Ordnernamen wie "ordner1/ordner2/ordner3" festlegen, um Unterordner zu erstellen',"Default save type":"Standard-Speicherort",'Set the default save type for thino. "DAILY" by default':'Standard-Speichertyp für Thino festlegen. "DAILY" als Standard',"Sync Thino via PKMer":"Thino über PKMer synchronisieren",Unlink:"Verknüpfung aufheben",Link:"Verknüpfen","Connect to PKMer Sync, you can check it in ":"Mit PKMer Sync verbinden, du kannst es überprüfen in ","PKMer Sync":"PKMer Sync","Remove successfully":"Erfolgreich entfernt",Deactivate:"Deaktivieren",Remove:"Entfernen","Confirm?":"Bestätigen?","Sync Status":"Synchronisierungsstatus","Start or stop sync":"Synchronisierung starten oder stoppen","Stop sync successfully":"Synchronisierung erfolgreich gestoppt","Start sync successfully":"Synchronisierung erfolgreich gestartet",Stop:"Stopp",Start:"Start","Show thino near mouse":"Thino in Mausnähe anzeigen","Query not found":"Abfrage nicht gefunden","Send to clipboard successfully":"Erfolgreich in die Zwischenablage kopiert","Thino - Failed to start HTTP server, please check the port is available.":"Thino - HTTP-Server konnte nicht gestartet werden, bitte prüfe ob der Port verfügbar ist.","Thino - Started HTTP server on port":"Thino - HTTP-Server gestartet auf Port","Thino - Terminated HTTP server":"Thino - HTTP-Server beendet","File not exist":"Datei existiert nicht","Thino not found":"Thino nicht gefunden","File not found for the given thino path, is creating a new file":"Datei für den angegebenen Thino-Pfad nicht gefunden, erstelle neue Datei","Saved sync token successfully":"Sync-Token erfolgreich gespeichert","Failed to find daily notes folder":"Tagesnotizen-Ordner konnte nicht gefunden werden","Please install obsidian-hover-editor plugin first":"Bitte installiere zuerst das obsidian-hover-editor Plugin","Copied app id successfully":"App-ID erfolgreich kopiert","Please input token first":"Bitte gib zuerst den Token ein","Please enable sync first":"Bitte aktiviere zuerst die Synchronisierung","Init Failed":"Initialisierung fehlgeschlagen","Verify successfully":"Erfolgreich verifiziert","Failed to verify":"Verifizierung fehlgeschlagen","Folder not found for the given thino path, is creating a new folder":"Ordner für den angegebenen Thino-Pfad nicht gefunden, erstelle neuen Ordner","File not found for the given thino path":"Datei für den angegebenen Thino-Pfad nicht gefunden","Failed to read current daily note, check if it exists.":"Aktuelle Tagesnotiz konnte nicht gelesen werden, prüfe ob sie existiert.","Failed to save":"Speichern fehlgeschlagen","Failed to login, please login again":"Anmeldung fehlgeschlagen, bitte erneut anmelden","COPY FAILED":"KOPIEREN FEHLGESCHLAGEN","COPY SUCCEED":"KOPIEREN ERFOLGREICH","Copy selected text":"Ausgewählten Text kopieren","Copy thino":"Thino kopieren",COPY:"KOPIEREN","This is a pro feature, please upgrade to pro version to use it.":"Dies ist eine Pro-Funktion, bitte upgrade auf die Pro-Version um sie zu nutzen.","You can get pro version from: ":"Du kannst die Pro-Version hier erhalten: ",Save:"Speichern",Cancel:"Abbrechen","Thino Daily Target":"Thino Tagesziel",Input:"Eingabe","#Tag":"#Tag","to create tag":"um Tag zu erstellen","You have verified your account. Congrats!":"Du hast dein Konto verifiziert. Glückwunsch!","Pro features":"Pro-Funktionen","Target Thino Count":"Ziel-Thino-Anzahl",on:"am","Switch waterfall view":"Zur Wasserfall-Ansicht wechseln","Switch view":"Ansicht wechseln","Switch list view":"Zur Listen-Ansicht wechseln","Set daily target":"Tagesziel festlegen","Thino Save To: ":"Thino speichern unter: ","Enter fullscreen mode":"Vollbildmodus aktivieren","Exit fullscreen mode":"Vollbildmodus verlassen",words:"Wörter",word:"Wort","Return To Home Page":"Zur Startseite zurückkehren","No thinos to review!":"Keine Thinos zum Überprüfen!","Thinos to review":"Thinos zum Überprüfen","Start Review":"Überprüfen starten",Hard:"Schwer",Good:"Gut",Easy:"Leicht",Again:"Wiederholen","Clear all review data":"Alle Überprüfungsdaten löschen","Daily Progress":"Täglicher Fortschritt","Show stats":"Stats anzeigen","Hide stats":"Stats ausblenden",Remaining:"Verbleibend","Total Reviews":"Gesamte Überprüfungen","Today, you have reviewed all your thinos!":"Heute hast du alle deine Thinos überprüft!","Daily review limit reached! Come back tomorrow.":"Tägliche Überprüfungslimit erreicht! Komm morgen wieder.","Open thino in center window":"Thino im zentralen Fenster öffnen","Open thino in float window":"Thino im schwebenden Fenster öffnen","Open thino in right sidebar":"Thino in der rechten Seitenleiste öffnen","Open thino in left sidebar":"Thino in der linken Seitenleiste öffnen","Show thino editor":"Thino-Editor anzeigen","Toggle minimal mode":"Minimalen Modus umschalten","Focus on thino editor":"Fokus auf Thino-Editor","ReSync web thinos to local":"Web-Thinos mit lokalen synchronisieren","Sync local thinos to web":"Lokale Thinos mit Web synchronisieren","Show daily thino":"Tägliches Thino anzeigen","Focus on search bar":"Fokus auf Suchleiste","Show-thino in popover(Hover editor)":"Thino in Popover anzeigen (Hover-Editor)","Center window":"Zentrales Fenster","Float window":"Schwebendes Fenster","Right sidebar":"Rechte Seitenleiste","Left sidebar":"Linke Seitenleiste","Save thino type when sync local":"Thino-Typ beim lokalen Synchronisieren speichern","Set the default save thino type when sync local, FILE by default.":"Standardtyp zum Speichern von Thino beim lokalen Synchronisieren festlegen, standardmäßig DATEI.","Sync service":"Synchronisierungsdienst","Pro verification status":"Pro-Verifizierungsstatus","Live-preview":"Live-Vorschau",Source:"Quelle","Global copy":"Globales Kopieren","Set the folder name":"Ordnernamen festlegen","Set the filename":"Dateinamen festlegen","Set the filename for current location file":"Dateinamen für aktuelle Ortsdatei festlegen","Switch calendar type":"Kalendertyp wechseln",alphabetical:"alphabetisch",alphabeticalReverse:"alphabetisch rückwärts",byCount:"nach Anzahl",byCountReverse:"nach Anzahl rückwärts","Type here":"Hier tippen",Today:"Heute",Yesterday:"Gestern","Last 7 days":"Letzte 7 Tage","Last 30 days":"Letzte 30 Tage","Last 90 days":"Letzte 90 Tage","Last 180 days":"Letzte 180 Tage","Last 365 days":"Letzte 365 Tage",Found:"Gefunden","Copy filtered thinos":"Gefilterte Thinos kopieren","Bulk delete":"Massenweise löschen","Bulk archive":"Massenweise archivieren","Bulk tag operation":"Massenhafte Tag-Operation","Bulk restore":"Massenweise wiederherstellen","If you are disabling the daily note plugin, it would be possible that the thino will not be deleted or patched properly. Please enable the plugin and try again.":"Wenn du das tägliche Notizen-Plugin deaktivierst, könnte es sein, dass das Thino nicht richtig gelöscht oder aktualisiert wird. Bitte aktiviere das Plugin und versuche es erneut.",Preview:"Vorschau","Set and save":"Festlegen und speichern","Show day mark in thino list":"Tagesmarkierung in Thino-Liste anzeigen","Show day mark on the top of daily range thino. False by default.":"Tagesmarkierung oben auf dem täglichen Bereichs-Thino anzeigen. Standardmäßig deaktiviert.","Click to expand or fold, Cmd+Click to show all thinos of the day":"Klicken zum Erweitern oder Falten, Cmd+Klick um alle Thinos des Tages anzuzeigen","You can buy a license from":"Du kannst eine Lizenz kaufen von","No thinos in range":"Keine Thinos im Bereich",Month:"Monat",Week:"Woche",Day:"Tag",Agenda:"Agenda",Tomorrow:"Morgen",Previous:"Vorherige",Next:"Nächste","Search all columns...":"Alle Spalten durchsuchen...","Basic Info":"Grundinformationen","Additional Info":"Zusätzliche Informationen","Created At":"Erstellt am",Content:"Inhalt","Thino Type":"Thino-Typ","Source Type":"Quelltyp","Row status":"Zeilenstatus",Path:"Pfad","Pinned Status":"Angeheftet-Status",Table:"Tabelle",Chat:"Chat",Moments:"Momente",Waterfall:"Wasserfall",Calendar:"Kalender","Go to page":"Zur Seite gehen",Page:"Seite",Show:"Zeigen",rows:"Zeilen","Temp Filter":"Temporärer Filter","Open link directly in Thino view":"Link direkt in Thino-Ansicht öffnen","Day mark range":"Tagesmarkierungsbereich","Set the range of day mark. Day by default.":"Bereich der Tagesmarkierung festlegen. Standardmäßig Tag.","Thino is locked":"Thino ist gesperrt","Please unlock Thino by input password":"Bitte entsperre Thino durch Eingabe des Passworts","Auto Download Image":"Automatischer Bilddownload","Auto download image when save to thino. 'false' by default":"Automatischer Bilddownload beim Speichern in Thino. Standardmäßig 'false'","Thino Http IP Type":"Thino Http IP-Typ","Set Thino http server ip to listen. 'localhost' by default":"Thino-HTTP-Server-IP zum Abhören festlegen. Standardmäßig 'localhost'","Password to lock Thino":"Passwort zum Sperren von Thino",Unlock:"Entsperren",Locked:"Gesperrt","Password is incorrect":"Passwort ist falsch",Lock:"Sperren","Need password to unlock Thino":"Passwort zum Entsperren von Thino erforderlich","You have not set a password or enable this feature yet":"Du hast noch kein Passwort festgelegt oder diese Funktion aktiviert",Password:"Passwort","Password for Thino":"Passwort für Thino","Please input your password to change password settings":"Bitte gib dein Passwort ein, um die Passworteinstellungen zu ändern","Please input your password":"Bitte gib dein Passwort ein","Lock thino":"Thino sperren",date:"Datum",time:"Zeit",event:"Ereignis","Add tag position":"Tag-Position hinzufügen","Set the position of the tag when adding tag automatically":"Position des Tags festlegen, wenn Tags automatisch hinzugefügt werden","Add tag automatically":"Tag automatisch hinzufügen","Add tag to the end or beginning of the thino content when creating a thino and filtering tags":"Tag am Ende oder Anfang des Thino-Inhalts hinzufügen, wenn ein Thino erstellt und Tags gefiltert werden","Add tag with new line":"Tag mit neuer Zeile hinzufügen","Add tag with new line when adding tag automatically":"Tag mit neuer Zeile hinzufügen, wenn Tags automatisch hinzugefügt werden","Input to select more tags":"Eingabe, um weitere Tags auszuwählen","Tag Bulk Edit":"Tag-Massenbearbeitung","Tag Bulk Select":"Tag-Massenauswahl","Exist Tags":"Vorhandene Tags","Selected Tags":"Ausgewählte Tags","Click to remove exist tag":"Klicken, um vorhandenes Tag zu entfernen","Click to remove selected tag":"Klicken, um ausgewähltes Tag zu entfernen","Select tags":"Tags auswählen","Input to select exist tag":"Eingabe, um vorhandenes Tag auszuwählen",Beginning:"Anfang",End:"Ende","Set the heading for saving thino":"Überschrift zum Speichern von Thino festlegen","# Heading":"# Überschrift","Chat view style":"Chat-Ansichtsstil","Set the style of chat view":"Stil der Chat-Ansicht festlegen","Background image for moments view":"Hintergrundbild für Momente-Ansicht","Set the background image for moments view":"Hintergrundbild für Momente-Ansicht festlegen","Icon for moments/chat view/share image":"Symbol für Momente/Chat-Ansicht/Freigabebild","Set the icon for moments/chat view/share image":"Symbol für Momente/Chat-Ansicht/Freigabebild festlegen","Quote for moments view/share image":"Zitat für Momente-Ansicht/Freigabebild","Set the quote for moments view/share image":"Zitat für Momente-Ansicht/Freigabebild festlegen","Theme for Thino":"Thema für Thino","Set the theme for Thino":"Thema für Thino festlegen","Interface Details":"Schnittstellendetails","Task amount":"Aufgabenmenge","Thino status":"Thino-Status","Used tags":"Verwendete Tags","Used days":"Verwendete Tage","Most active day":"Aktivster Tag","Most active hour":"Aktivste Stunde","Thino amount":"Thino-Menge","No content to generate.":"Kein Inhalt zum Generieren.","Image generated successfully.":"Bild erfolgreich generiert.","Failed to generate image.":"Fehler beim Generieren des Bildes.","Share filtered thinos as image":"Gefilterte Thinos als Bild teilen","Latest version":"Neueste Version","Previous version":"Vorherige Version","Thino update info":"Thino-Update-Info","Debug info copied to clipboard":"Debug-Informationen in die Zwischenablage kopiert","Copy debug info":"Debug-Informationen kopieren","Failed to load changelog":"Fehler beim Laden des Changelogs","View online":"Online ansehen",ChangeLog:"Änderungsprotokoll","Please open thino first":"Bitte öffne zuerst Thino","Insert editor":"Editor einfügen","Please set different save locations for multi-file settings in Thino. The diary folder overlaps with the multi-file save location, or there is a risk of it being read repeatedly.":"Bitte lege unterschiedliche Speicherorte für Mehrfachdatei-Einstellungen in Thino fest. Der Tagebuchordner überschneidet sich mit dem Mehrfachdatei-Speicherort, oder es besteht die Gefahr, dass er wiederholt gelesen wird.","Default time prefix for thino in daily notes":"Standard-Zeitpräfix für Thino in täglichen Notizen","Set default time prefix for thino in daily notes.":"Standard-Zeitpräfix für Thino in täglichen Notizen festlegen.","Save image successfully":"Bild erfolgreich gespeichert","User quote":"Benutzerzitat","Set user quote for thino":"Benutzerzitat für Thino festlegen","User icon":"Benutzersymbol","Set user icon for thino. You can input http/https link or file path in vault.":"Benutzersymbol für Thino festlegen. Du kannst einen http/https-Link oder Dateipfad im Tresor eingeben.","User info":"Benutzerinfo","Copy filtered results":"Gefilterte Ergebnisse kopieren","Share image":"Bild teilen",Default:"Standard",Gray:"Grau",Grass:"Gras",Flame:"Flamme",Olive:"Olive",Ice:"Eis",Magenta:"Magenta","Daily notes":"Tägliche Notizen",Editor:"Editor","Append/prepend text when share to Thino":"Text anhängen/voranstellen beim Teilen zu Thino","Append text when share to Thino":"Text anhängen beim Teilen zu Thino","Prepend text when share to Thino":"Text voranstellen beim Teilen zu Thino","Add newline when append/prepend text":"Neue Zeile hinzufügen beim Anhängen/Voranstellen von Text","Input anything here":"Hier etwas eingeben",Prepend:"Voranstellen",Append:"Anhängen",Both:"Beides",None:"Keines","Hide pinned group":"Angeheftete Gruppe ausblenden","Hide pinned group in thino list. False by default.":"Angeheftete Gruppe in Thino-Liste ausblenden. Standardmäßig deaktiviert.","Set the heading for the task type of thino, by default the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"Überschrift für den Aufgabentyp von Thino festlegen. Standardmäßig wird der aufgezeichnete Thino-Inhalt am Ende des Tagebuchs eingefügt; wenn ein Titel angegeben wird, werden alle aufgezeichneten Thino-Inhalte einheitlich unter diesem Titel kategorisiert.","Different insert target for different type":"Unterschiedliches Einfügeziel für verschiedene Typen","Toggle this to set different insert target for different type of thino, like task or list type of thino":"Aktiviere dies, um unterschiedliche Einfügeziele für verschiedene Thino-Typen festzulegen, wie Aufgaben- oder Listentyp von Thino","You can set whole diary or only part of it":"Du kannst das gesamte Tagebuch oder nur einen Teil davon festlegen","Set process target":"Verarbeitungsziel festlegen",Custom:"Benutzerdefiniert","Whole diary":"Gesamtes Tagebuch","Set thino insert place":"Thino-Einfügeort festlegen","Set where to insert thino content":"Festlegen, wo Thino-Inhalt eingefügt werden soll","End of the diary":"Ende des Tagebuchs","Custom location":"Benutzerdefinierter Ort","Setting guide":"Einstellungsanleitung","Details settings":"Detaileinstellungen","Start Thino":"Thino starten","About Thino Pro":"Über Thino Pro",Enabled:"Aktiviert",Enable:"Aktivieren","Daily notes folder":"Ordner für tägliche Notizen","Set daily notes folder":"Ordner für tägliche Notizen festlegen","Daily note name format":"Namensformat für tägliche Notizen","Set daily note name format":"Namensformat für tägliche Notizen festlegen","Daily note plugin":"Plugin für tägliche Notizen","Enable daily note plugin":"Plugin für tägliche Notizen aktivieren",Selected:"Ausgewählt",Select:"Auswählen","A classic theme for Thino with a two-column layout":"Ein klassisches Thema für Thino mit zweispaltigem Layout",Classic:"Klassisch","A modern theme for Thino with a three-column layout and some unique features.":"Ein modernes Thema für Thino mit dreispaltigem Layout und einigen einzigartigen Funktionen.",Modern:"Modern","Go and enjoy Thino":"Los geht's, viel Spaß mit Thino","Congrats! All settings done":"Glückwunsch! Alle Einstellungen abgeschlossen","Adjust settings that influence your user experience with Thino.":"Passe Einstellungen an, die deine Benutzererfahrung mit Thino beeinflussen.","Set preferences for using Thino":"Präferenzen für die Verwendung von Thino festlegen","If you are using the Thino basic version, enabling the daily note plugin is required. Configure its settings to work effectively with it.":"Wenn du die Thino-Basisversion verwendest, ist die Aktivierung des Plugins für tägliche Notizen erforderlich. Konfiguriere seine Einstellungen, um effektiv damit zu arbeiten.","Go with daily note plugin":"Mit Plugin für tägliche Notizen fortfahren","Choose a theme for Thino.":"Wähle ein Thema für Thino.","Set theme for Thino":"Thema für Thino festlegen","Set up your user info for Thino.":"Richte deine Benutzerinformationen für Thino ein.","Get started with Thino":"Erste Schritte mit Thino","Skip and start Thino":"Überspringen und Thino starten","Next step":"Nächster Schritt","Back to previous step":"Zurück zum vorherigen Schritt","Click to enable =>":"Klicken zum Aktivieren =>","This is Thino's sidebar. Navigate to different path or select query filter.":"Dies ist Thinos Seitenleiste. Navigiere zu verschiedenen Pfaden oder wähle Abfragefilter.","Click here and go to settings page.":"Klicke hier und gehe zur Einstellungsseite.","Click here and go to different path.":"Klicke hier und gehe zu einem anderen Pfad.","Select or create query filter here.":"Wähle oder erstelle hier Abfragefilter.","See the status of Thinos here.":"Siehe hier den Status von Thinos.","Search your thino quickly here.":"Suche dein Thino schnell hier.","Edit or create your thino here.":"Bearbeite oder erstelle dein Thino hier.","See your thinos here.":"Siehe deine Thinos hier.","See your time status of thinos here.":"Siehe hier deinen Zeitstatus von Thinos.","See your tags here. Tags will be shown when thino contains tags.":"Siehe deine Tags hier. Tags werden angezeigt, wenn Thino Tags enthält.",Done:"Fertig","Thino is ready to use. ":"Thino ist einsatzbereit. ","You can start using Thino now. If you want to know more about Thino Pro, click the button below.":"Du kannst Thino jetzt verwenden. Wenn du mehr über Thino Pro erfahren möchtest, klicke auf die Schaltfläche unten.","Default time prefix":"Standard-Zeitpräfix","Append Text Action":"Text-Anhänge-Aktion","Prepend Text Action":"Text-Voranstell-Aktion",Preset:"Voreinstellung","Select Tags":"Tags auswählen","It is not available on small view":"Es ist nicht verfügbar in der kleinen Ansicht","Append text":"Text anhängen","Prepend text":"Text voranstellen","Your daily note folder is not set correctly, please check your settings":"Dein Ordner für tägliche Notizen ist nicht korrekt eingestellt, bitte überprüfe deine Einstellungen","Default sharing style":"Standard-Freigabestil","Set the default style for sharing thino, 'Modern' by default.":'Lege den Standardstil für die Freigabe von Thino fest, standardmäßig "Modern".',Clean:"Sauber",Minimal:"Minimal",Gradient:"Farbverlauf","Thino share":"Thino-Freigabe","Copy to clipboard failed":"Kopieren in die Zwischenablage fehlgeschlagen","Copy to clipboard successfully":"Erfolgreich in die Zwischenablage kopiert","Your content has been copied to clipboard, and inserted into the editor. Please try it again":"Dein Inhalt wurde in die Zwischenablage kopiert und in den Editor eingefügt. Bitte versuche es erneut","Share thino":"Thino teilen","Set file name after create thino":"Dateinamen nach Erstellung von Thino festlegen","You can set file name after create thino. A input box will show when you create thino.":"Du kannst den Dateinamen nach der Erstellung von Thino festlegen. Ein Eingabefeld wird angezeigt, wenn du Thino erstellst.",SPLIT:"TEILEN","Split by Heading 1":"Nach Überschrift 1 teilen","Split by Heading 2":"Nach Überschrift 2 teilen","Split by Heading 3":"Nach Überschrift 3 teilen","Insert task":"Aufgabe einfügen","All settings have been reset to default.":"Alle Einstellungen wurden auf die Standardwerte zurückgesetzt.","Reset all Thino settings":"Alle Thino-Einstellungen zurücksetzen","Reset settings":"Einstellungen zurücksetzen","Reset Thino settings to default settings.":"Thino-Einstellungen auf Standardeinstellungen zurücksetzen.","Task Management":"Aufgabenverwaltung","Append completed date when task done in thino":"Abschlussdatum anhängen, wenn Aufgabe in Thino erledigt ist","Append completed date when task done in thino. False by default":"Abschlussdatum anhängen, wenn Aufgabe in Thino erledigt ist. Standardmäßig deaktiviert","Set tag for single file that Thino indexes":"Tag für einzelne Datei festlegen, die Thino indiziert","When you set a tag here, Thino will index this file contains this tag and show it in the list. Don't need to add `#`.":"Wenn du hier ein Tag festlegst, wird Thino diese Datei indizieren, die dieses Tag enthält, und es in der Liste anzeigen. Du musst kein `#` hinzufügen.","Set tag for file type file":"Tag für Dateityp-Datei festlegen","Set tag for multi type file":"Tag für Mehrfachtyp-Datei festlegen","Please input the tag":"Bitte gib das Tag ein","Merge thinos in to thino share image":"Thinos in Thino-Freigabebild zusammenführen","Custom height for Thino content":"Benutzerdefinierte Höhe für Thino-Inhalt","Set custom height for Thino content. Like 200px or 20rem":"Benutzerdefinierte Höhe für Thino-Inhalt festlegen. Wie 200px oder 20rem","Input height":"Höhe eingeben","Submit issue":"Problem melden","Current version":"Aktuelle Version","Bug report":"Fehlerbericht","Click the button to copy debug info and open the issue page":"Klicke auf die Schaltfläche, um Debug-Informationen zu kopieren und die Problemseite zu öffnen","Copy and go":"Kopieren und los","Debug info copied":"Debug-Informationen kopiert","Feature request":"Funktionsanfrage","Submit your feature request to the issue page":"Reiche deine Funktionsanfrage auf der Problemseite ein",Go:"Los","Toggle query list visibility":"Abfragelistensichtbarkeit umschalten","Toggle tags visibility":"Tag-Sichtbarkeit umschalten","Toggle sidebar visibility":"Seitenleistensichtbarkeit umschalten",Collapse:"Einklappen",Expand:"Ausklappen","Max height for collapse":"Maximale Höhe für Einklappen","The max height for thino collapse, when set 0, thino would not collapse. 0 by default. (This is not lines count, it is height in px.)":"Die maximale Höhe für Thino-Einklappen, wenn auf 0 gesetzt, würde Thino nicht einklappen. Standardmäßig 0. (Dies ist keine Zeilenanzahl, sondern die Höhe in px.)","Render content":"Inhalt rendern","Optimize for Callout":"Für Callout optimieren","Won't render content contains more than 3 callouts automatically. True by default":"Rendert Inhalte mit mehr als 3 Callouts nicht automatisch. Standardmäßig aktiviert","The value should be greater than":"Der Wert sollte größer sein als","Append Text":"Text anhängen","Prepend Text":"Text voranstellen","Thino height when collapsed":"Thino-Höhe im eingeklappten Zustand","The height for thino when it is collapsed, when set 0, thino would not collapse. 100 by default. (This is not lines count, it is height in px.)":"Die Höhe für Thino im eingeklappten Zustand, wenn auf 0 gesetzt, würde Thino nicht einklappen. Standardmäßig 100. (Dies ist keine Zeilenanzahl, sondern die Höhe in px.)","This option will allow you use other views when leaf width is not enough. False by default.":"Diese Option ermöglicht es dir, andere Ansichten zu verwenden, wenn die Blattbreite nicht ausreicht. Standardmäßig deaktiviert.","Can select other views when leaf width is not enough":"Kann andere Ansichten auswählen, wenn Blattbreite nicht ausreicht","TRASH BOX":"PAPIERKORB","Wait templater to finish parse before insert thino":"Warte, bis Templater das Parsen beendet hat, bevor Thino eingefügt wird","This option will allow you to wait for templater to finish parse before insert thino, which may casue you need to confirm twice between insert thino. False by default.":"Diese Option ermöglicht es dir, zu warten, bis Templater das Parsen beendet hat, bevor Thino eingefügt wird, was dazu führen kann, dass du zwischen dem Einfügen von Thino zweimal bestätigen musst. Standardmäßig deaktiviert.","Get thino capture extension":"Thino-Erfassungserweiterung holen","You can capture idea/text from chrome now.":"Du kannst jetzt Ideen/Text aus Chrome erfassen.","Open File":"Datei öffnen","Exported CSV file":"Exportierte CSV-Datei","Updated At":"Aktualisiert am","Export to CSV":"Nach CSV exportieren","Quick add button on mobile navbar":"Schnellhinzufügen-Schaltfläche in der mobilen Navigationsleiste","Always show status text":"Statustext immer anzeigen","Support filter by metadata from file":"Filterung nach Metadaten aus Datei unterstützen","When enable this, you can filter via metadata from file, like tags in file. But thinos from canvas is not supported. False by default.":"Wenn du dies aktivierst, kannst du über Metadaten aus der Datei filtern, wie z.B. Tags in der Datei. Thinos aus Canvas werden jedoch nicht unterstützt. Standardmäßig deaktiviert.","Show source near timestamp in thino":"Quelle neben Zeitstempel in Thino anzeigen","When enable this, you can see the source near timestamp in thino. You can set title in metadata to overwrite this. False by default.":"Wenn du dies aktivierst, kannst du die Quelle neben dem Zeitstempel in Thino sehen. Du kannst den Titel in den Metadaten festlegen, um dies zu überschreiben. Standardmäßig deaktiviert.","Show Update Message":"Aktualisierungsnachricht anzeigen","Show update message when Thino is updated. True by default":"Aktualisierungsnachricht anzeigen, wenn Thino aktualisiert wird. Standardmäßig aktiviert","Sync manually":"Manuell synchronisieren","Show all scrollbars":"Alle Scrollbalken anzeigen","TIME RANGE":"ZEITRAUM",WITHIN:"INNERHALB","7 days":"7 Tage","14 days":"14 Tage","30 days":"30 Tage","3 months":"3 Monate","6 months":"6 Monate","1 year":"1 Jahr","This week":"Diese Woche","Last week":"Letzte Woche","This month":"Dieser Monat","Last month":"Letzter Monat","This year":"Dieses Jahr","Last year":"Letztes Jahr","No history":"Keine Historie","Today Remaining":"Heute verbleibend","Today Total":"Heute gesamt","Historical Statistics":"Historische Statistiken",byTime:"Nach Zeit",byTimeReverse:"Nach Zeit (umgekehrt)",Stat:"Statistik",Statistics:"Statistiken","Daily Thino Count":"Tägliche Thino-Anzahl",Total:"Gesamt",thinos:"Thinos","Thino Types":"Thino-Typen","Distribution of thino types":"Verteilung der Thino-Typen","Thino Status":"Thino-Status","Distribution of thino status":"Verteilung des Thino-Status","Popular Tags":"Beliebte Tags","Top 10 most used tags":"Top 10 der meistverwendeten Tags","Thino Count":"Thino-Anzahl","Hourly distribution":"Stündliche Verteilung","Current month":"Aktueller Monat","Monthly distribution":"Monatliche Verteilung","30 Days":"Letzte 30 Tage",Year:"Jahr","Time Distribution":"Zeitverteilung","When do you write thinos":"Wann schreibst du Thinos","Content Length":"Inhaltslänge","Distribution of thino lengths":"Verteilung der Thino-Längen","Daily Thinos":"Tägliche Thinos","Show Time Distribution":"Zeitverteilung anzeigen","Hide date picker":"Datumsauswahl ausblenden","Show date picker":"Datumsauswahl anzeigen","Clear filter":"Filter löschen","Copy link":"Link kopieren","Copy embed link":"Einbettungslink kopieren","Ctrl/Cmd + Enter to save thino":"Strg/Cmd + Enter zum Speichern des Thinos","Fixed strings for thinos":"Feste Zeichenketten für Thinos","Use fixed strings for thinos":"Feste Zeichenketten für Thinos verwenden","Enable to add fixed strings at the beginning or end of thinos.":"Aktivieren, um feste Zeichenketten am Anfang oder Ende von Thinos hinzuzufügen.","Fixed prefix for thinos":"Festes Präfix für Thinos","Add this string at the beginning of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"Füge diese Zeichenkette am Anfang jedes Thinos hinzu. Unterstützt Platzhalter wie {{TIME|YYYYMMDDHHmmss}}.","Fixed suffix for thinos":"Festes Suffix für Thinos","Add this string at the end of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"Füge diese Zeichenkette am Ende jedes Thinos hinzu. Unterstützt Platzhalter wie {{TIME|YYYYMMDDHHmmss}}.","Word count exceeded":"Wortzahl überschritten","Word count feature":"Wortzählfunktion","Enable real-time word count display in the editor":"Echtzeit-Wortzählanzeige im Editor aktivieren","Maximum word count":"Maximale Wortzahl","Set a maximum word count for thino. Editor will display a warning when exceeded. Set to 0 for unlimited.":"Lege eine maximale Wortzahl für Thino fest. Der Editor zeigt eine Warnung an, wenn diese überschritten wird. Setze auf 0 für unbegrenzt.","No linked thinos found":"Keine verknüpften Thinos gefunden","Reference links group":"Referenzlinks-Gruppe","Enable reference links group in thino.":"Referenzlinks-Gruppe in Thino aktivieren.","No reference links found":"Keine Referenzlinks gefunden","Outgoing Links":"Ausgehende Links","Incoming Links":"Eingehende Links","Error fetching reference links":"Fehler beim Abrufen von Referenzlinks","Double click behavior":"Doppelklick-Verhalten","Set the behavior when double click on a thino.":"Lege das Verhalten fest, wenn du auf ein Thino doppelklickst.","Open thino":"Thino öffnen","Edit thino":"Thino bearbeiten","Go to source":"Zur Quelle gehen","Do nothing":"Nichts tun","Use default header in mobile view":"Standardkopfzeile in der mobilen Ansicht verwenden","Use default header in mobile view of thino rather than custom header.":"Verwende die Standardkopfzeile in der mobilen Ansicht von Thino anstelle einer benutzerdefinierten Kopfzeile."},P8={welcome:"Welcome to Thino",ribbonIconTitle:"Thino",to:"to",months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan.","Feb.","Mar.","Apr.","May","June","July","Aug.","Sept.","Oct.","Nov.","Dec."],weekDays:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],weekDaysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],year:null,month:null,"Basic Options":"Basic options","User name":"User name","Set your user name here. 'Memos 😏' By default":"Set your user name here. 'Thino 😏' By default",'You can set target heading like "# Heading" to control data location':'You can set target heading like "# Heading" to control data location',"Insert after heading":"Insert after heading","If left blank, the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"You should set the same heading below if you want to insert and process thino below the same heading.","Allows admonitions to be created using ":"Allows admonitions to be created using ","Process Memos below":"Process thino below","If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.":"If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.","Save Memo button label":"Save thino button label","The text shown on the save Memo button in the UI. 'NOTEIT' by default.":"The text shown on the save Thino button in the UI. 'NOTEIT' by default.","Focus on editor when open memos":"Focus on editor when open thino","Focus on editor when open memos. Focus by default.":"Focus on editor when open thino. Focus by default.","Open daily memos with open memos":"Open daily thino with open thino","Open daily memos with open memos. Open by default.":"Open daily thino with open thino. Open by default.","Open Memos when obsidian opens":"Open Thino when obsidian opens","When enable this, Memos will open when Obsidian opens. False by default.":"When enable this, Thino will open when Obsidian opens. False by default.","Hide done tasks in Memo list":"Hide done tasks in Thino list","Hide all done tasks in Memo list. Show done tasks by default.":"Hide all done tasks in Thino list. Show done tasks by default.","Advanced Options":"Advanced Options","UI language for date":"UI language for date","Translates the date UI language. Only 'en' and 'zh' are available.":"Translates the date UI language. Only 'en' and 'zh' are available.","Default prefix when save thino":"Default prefix when save thino","Set the default prefix when create memo, 'List' by default.":"Set the default prefix when create thino, 'List' by default.","Default insert date format":"Default insert date format","Set the default date format when insert date by @, 'Tasks' by default.":"Set the default date format when insert date by @, 'Tasks' by default.","Default editor position on mobile":"Default editor position on mobile","Set the default editor position on Mobile, 'Top' by default.":"Set the default editor position on Mobile, 'Top' by default.","Use button to show editor on mobile":"Use button to show editor on mobile","Set a float button to call editor on mobile. Only when editor located at the bottom works.":"Set a float button to call editor on mobile. Only when editor located at the bottom works.","Show Time When Copy Results":"Show Time When Copy Results","Show time when you copy results, like 12:00. Copy time by default.":"Show time when you copy results, like 12:00. Copy time by default.","Show Date When Copy Results":"Show Date When Copy Results","Show date when you copy results, like [[2022-01-01]]. Copy date by default.":"Show date when you copy results, like [[2022-01-01]]. Copy date by default.","Add Blank Line Between Different Date":"Add Blank Line Between Different Date","Add blank line when copy result with date. No blank line by default.":"Add blank line when copy result with date. No blank line by default.","Share Options":"Share Options","Share Memos Image Footer Start":"Share Thino Image Footer Start","Set anything you want here, use {ThinoNum} to display Number of thino, {UsedDay} for days. '{ThinoNum} Thino {UsedDay} Days' By default":"Set anything you want here, use {ThinoNum} to display Number of thino, {UsedDay} for days. '{ThinoNum} Thino {UsedDay} Days' By default","Share Memos Image Footer End":"Share Thino Image Footer End","Set anything you want here, use {UserName} as your username. '✍️ By {UserName}' By default":"Set anything you want here, use {UserName} as your username. '✍️ By {UserName}' By default","Save Shared Image To Folder For Mobile":"Save Shared Image To Folder For Mobile","Save image to folder for mobile. False by Default":"Save image to folder for mobile. False by Default","Say Thank You":"Say Thank You",Donate:"Donate","If you like this plugin, consider donating to support continued development:":"If you like this plugin, consider donating to support continued development:","File Name of Recycle Bin":"File Name of Recycle Bin","Set the filename for recycle bin. 'delete' By default":"Set the filename for recycle bin. 'delete' By default","File Name of Query File":"File Name of Query File","Set the filename for query file. 'query' By default":"Set the filename for query file. 'query' By default","Use Tags In Vault":"Use Tags In Vault","Use tags in vault rather than only in Memos. False by default.":"Use tags in vault rather than only in Thino. False by default.","Ready to convert image into background":"Ready to convert image into background",List:"List",Task:"Task",Top:"Top",Bottom:"Bottom",TAG:"TAG",DAY:"DAY",QUERY:"Query",EDIT:"EDIT",PIN:"PIN",UNPIN:"UNPIN",DELETE:"DELETE","CONFIRM!":"CONFIRM!","CREATE FILTER":"CREATE FILTER","Comment it...":"Comment it...",Settings:"Settings","Recycle bin":"Recycle bin","About Me":"About Me","Fetching data...":"Fetching data...","Here is No Memos.":"Here is No Thino.","Frequently Used Tags":"Frequently Used Tags","What do you think now...":"What do you think now...",READ:"READ",MARK:"MARK",SHARE:"SHARE",SOURCE:"SOURCE",RESTORE:"RESTORE",ARCHIVE:"Archive","Daily Review":"Daily Review","DELETE AT":"DELETE AT","Noooop!":"Noooop!","All Data is Loaded 🎉":"All Data is Loaded 🎉","Quick filter":"Quick filter",TYPE:"TYPE",LINKED:"LINKED","NO TAGS":"NO TAGS","HAS LINKS":"HAS LINKS","HAS IMAGES":"HAS IMAGES",INCLUDE:"INCLUDE",EXCLUDE:"EXCLUDE",TEXT:"TEXT",IS:"IS",AND:"AND",OR:"OR",LIST:"LIST",ISNOT:"ISNOT",PATH:"PATH",METADATA:"METADATA",SELECT:"SELECT","ADD FILTER TERMS":"ADD FILTER TERMS",FILTER:"FILTER",Filter:"Filter",TITLE:"TITLE","CREATE QUERY":"CREATE QUERY","EDIT QUERY":"EDIT QUERY",MATCH:"MATCH",TIMES:"TIMES","Share Memo Image":"Share Thino Image","↗Click the button to save":"↗Click the button to save","Image is generating...":"Image is generating...","Image is loading...":"Image is loading...","Loading...":"Loading...","😟 Cannot load image, image link maybe broken":"😟 Cannot load image, image link maybe broken","Daily Memos":"Daily Thino","CANCEL EDIT":"CANCEL EDIT","LINK TO THE":"LINK TO THE","Mobile Options":"Mobile Options","Experimental Options":"Experimental Options","Don't support web image yet, please input image path in vault":"Don't support web image yet, please input image path in vault","Background Image in Dark Theme":"Background Image in Dark Theme","Background Image in Light Theme":"Background Image in Light Theme",'Set background image in dark theme. Set something like "Daily/one.png"':'Set background image in dark theme. Set something like "Daily/one.png"','Set background image in light theme. Set something like "Daily/one.png"':'Set background image in light theme. Set something like "Daily/one.png"','Set default memo composition, you should use {TIME} as "HH:mm" and {CONTENT} as content. "{TIME} {CONTENT}" by default':'Set default thino composition, you should use {TIME} as "HH:mm" and {CONTENT} as content. "{TIME} {CONTENT}" by default',"Default Memo Composition":"[Deprecated] Default Thino Composition","Show Tasks Label":"Show Tasks Label","Show tasks label near the time text. False by default":"Show tasks label near the time text. False by default","Please Open Memos First":"Please Open Thino First",DATE:"DATE",OBSIDIAN_NLDATES_PLUGIN_NOT_ENABLED:"OBSIDIAN_NLDATES_PLUGIN_NOT_ENABLED",BEFORE:"BEFORE",AFTER:"AFTER","Allow Comments On Memos":"Allow Comments On Thino","You can comment on memos. False by default":"You can comment on thino. False by default",Import:"Import","TITLE CANNOT BE NULL!":"TITLE CANNOT BE NULL!","FILTER CANNOT BE NULL!":"FILTER CANNOT BE NULL!","Comments In Original DailyNotes/Notes":"Comments In Original DailyNotes/Notes","You should install Dataview Plugin ver 0.5.9 or later to use this feature.":"You should install Dataview Plugin ver 0.5.9 or later to use this feature.","Open Memos Successfully":"Open Thino Successfully","Fetch Memos Error":"😭 Fetch Error","Copied to clipboard Successfully":"Copied to clipboard Successfully","Check if you opened Daily Notes Plugin Or Periodic Notes Plugin":"Check if you opened Daily Notes Plugin Or Periodic Notes Plugin","Please finish the last filter setting first":"Please finish the last filter setting first","Close Memos Successfully":"Close Thino Successfully","Insert as Memo":"Insert as Thino","Insert file as memo content":"Insert file as thino content","Image load failed":"Image load failed","Content cannot be empty":"Content cannot be empty","Unable to create new file.":"Unable to create new file.","Failed to fetch deleted memos: ":"Failed to fetch deleted thino: ","RESTORE SUCCEED":"RESTORE SUCCEED","DELETE SUCCEED":"DELETE SUCCEED","Save Memo button icon":"Save Thino button icon","The icon shown on the save Memo button in the UI.":"The icon shown on the save Thino button in the UI.","Fetch Memos From Particular Notes":"Fetch Thino From Particular Notes",'You can set any Dataview Query for memos to fetch it. All memos in those notes will show on list. "#memo" by default':'You can set any Dataview Query for thino to fetch it. All thino in those notes will show on list. "#memo" by default',"Allow Memos to Fetch Memo from Notes":"Allow Thino to Fetch Thino from Notes","Use Memos to manage all memos in your notes, not only in daily notes. False by default":"Use Thino to manage all thino in your notes, not only in daily notes. False by default","Always Show Memo Comments":"Always Show Thino Comments","Always show memo comments on memos. False by default":"Always show thino comments on thino. False by default","You didn't set folder for daily notes in both periodic-notes and daily-notes plugins.":"You didn't set folder for daily notes in both periodic-notes and daily-notes plugins.","Please check your daily note plugin OR periodic notes plugin settings":"Please check your daily note plugin OR periodic notes plugin settings","Use which plugin's default configuration":"Use which plugin's default configuration","Memos use the plugin's default configuration to fetch memos from daily, 'Daily' by default.":"Thino use the plugin's default configuration to fetch thino from daily, 'Daily' by default.",Daily:"Daily","Always Show Leaf Sidebar on PC":"Always Show Leaf Sidebar on PC","Show left sidebar on PC/Tablet even when the leaf width is less than 875px. False by default.":"Show left sidebar on PC/Tablet even when the leaf width is less than 875px. False by default.","You didn't set format for daily notes in both periodic-notes and daily-notes plugins.":"You didn't set format for daily notes in both periodic-notes and daily-notes plugins.","fetch more":"fetch more","Search all settings":"Search all settings",General:"General",Theme:"Theme",Share:"Share",Advanced:"Advanced",Thino:"Thino","Random Review":"Random Review","ARCHIVED AT":"ARCHIVED AT","Failed to get memos from daily notes":"Failed to get thino from daily notes","Failed to delete memo":"Failed to delete thino","CTRL + ENTER to save":"CTRL + ENTER to save","Started from":"Started from","Custom Background Image":"Custom Background Image","Set custom background image.":"Set custom background image.","Custom Memo Footer":"Custom Thino Footer","Set custom memo footer.":"Set custom thino footer.","Heatmap Color Scheme":"Heatmap Color Scheme","Set different color scheme for heatmap.":"Set different color scheme for heatmap.","Enable Local Http Server":"Enable Local Http Server","Memos Http Server Port":"Thino Http Server Port","Set memos http server port to listen. '43999' by default":"Set thino http server port to listen. '43999' by default","Default Editor Mode":"Default Editor Mode","Live-Preview Mode OR Source Mode.":"Live-Preview Mode/Source Mode.","Save type for Thino":"Save type for Thino",DAILY:"DAILY",MULTI:"MULTI",CANVAS:"CANVAS",ALL:"ALL",FILE:"FILE",TODO:"TODO",DONE:"DONE",JOURNAL:"JOURNAL",OTHER:"OTHER","Failed to create daily note, check if it exists.":"Failed to create daily note, check if it exists.","Failed to create daily note. Please check if you created a folder for daily notes.":"Failed to create daily note. Please check if you created a folder for daily notes.","After you verify your account, please refresh this page.":"After you verify your account, please refresh this page.",Verify:"Verify","Oops! You forget to verify insider account":"Oops! You forget to verify insider account","If you have any questions, please contact us.":"If you have any questions, please contact us.","Delete Thino Directly":"Delete Thino Directly","When delete thino directly, it will not be moved to trash. False by default.":"When delete thino directly, it will not be moved to trash. False by default.","Enable opening thino globally":"Enable opening thino globally","Enable opening thino globally. False by default.":"Enable opening thino globally. False by default.","Key for opening thino globally":"Key for opening thino globally","Set key for opening thino globally. CTRL + SHIFT + T by default.":"Set key for opening thino globally. CTRL + SHIFT + T by default.","Key for showing thino globally":"Key for showing thino globally","Set key for showing thino globally. CTRL + SHIFT + E by default.":"Set key for showing thino globally. CTRL + SHIFT + E by default.","Get activation code":"Get activation code","Input activation code here":"Input activation code here","Copy Thino id":"Copy Thino id","Activate Pro Version":"Activate Pro Version","Please copy Thino id first":"Please copy Thino id first",'You can set folder name with file name like "folder/file"':'You can set folder name with file name like "folder/file"','You can set folder name like "folder1/folder2/folder3" to create sub-folder':'You can set folder name like "folder1/folder2/folder3" to create sub-folder',"Default save type":"Default save location",'Set the default save type for thino. "DAILY" by default':'Set the default save type for thino. "DAILY" by default',"Sync Thino via PKMer":"Sync Thino via PKMer",Unlink:"Unlink",Link:"Link","Connect to PKMer Sync, you can check it in ":"Connect to PKMer Sync, you can check it in ","PKMer Sync":"PKMer Sync","Remove successfully":"Remove successfully",Deactivate:"Deactivate",Remove:"Remove","Confirm?":"Confirm?","Sync Status":"Sync Status","Start or stop sync":"Start or stop sync","Stop sync successfully":"Stop sync successfully","Start sync successfully":"Start sync successfully",Stop:"Stop",Start:"Start","Show thino near mouse":"Show thino near mouse","Query not found":"Query not found","Send to clipboard successfully":"Send to clipboard successfully","Thino - Failed to start HTTP server, please check the port is available.":"Thino - Failed to start HTTP server, please check the port is available.","Thino - Started HTTP server on port":"Thino - Started HTTP server on port","Thino - Terminated HTTP server":"Thino - Terminated HTTP server","File not exist":"File not exist","Thino not found":"Thino not found","File not found for the given thino path, is creating a new file":"File not found for the given thino path, is creating a new file","Saved sync token successfully":"Saved sync token successfully","Failed to find daily notes folder":"Failed to find daily notes folder","Please install obsidian-hover-editor plugin first":"Please install obsidian-hover-editor plugin first","Copied app id successfully":"Copied app id successfully","Please input token first":"Please input token first","Please enable sync first":"Please enable sync first","Init Failed":"Init Failed","Verify successfully":"Verify successfully","Failed to verify":"Failed to verify","Folder not found for the given thino path, is creating a new folder":"Folder not found for the given thino path, is creating a new folder","File not found for the given thino path":"File not found for the given thino path","Failed to read current daily note, check if it exists.":"Failed to read current daily note, check if it exists.","Failed to save":"Failed to save","Failed to login, please login again":"Failed to login, please login again","COPY FAILED":"COPY FAILED","COPY SUCCEED":"COPY SUCCEED","Copy selected text":"Copy selected text","Copy thino":"Copy thino",COPY:"COPY","This is a pro feature, please upgrade to pro version to use it.":"This is a pro feature, please upgrade to pro version to use it.","You can get pro version from: ":"You can get pro version from: ",Save:"Save",Cancel:"Cancel","Thino Daily Target":"Thino Daily Target",Input:"Input","#Tag":"#Tag","to create tag":"to create tag","You have verified your account. Congrats!":"You have verified your account. Congrats!","Pro features":"Pro features","Target Thino Count":"Target Thino Count",on:"on","Switch waterfall view":"Switch waterfall view","Switch view":"Switch view","Switch list view":"Switch list view","Set daily target":"Set daily target","Thino Save To: ":"Thino Save To: ","Enter fullscreen mode":"Enter fullscreen mode","Exit fullscreen mode":"Exit fullscreen mode",words:"words",word:"word","Return To Home Page":"Return To Home Page","No thinos to review!":"No thinos to review!","Thinos to review":"Thinos to review","Start Review":"Start Review",Hard:"Hard",Good:"Good",Easy:"Easy",Again:"Again","Clear all review data":"Clear all review data","Daily Progress":"Daily Progress","Show stats":"Show stats","Hide stats":"Hide stats",Remaining:"Remaining","Total Reviews":"Total Reviews","Today, you have reviewed all your thinos!":"Today, you have reviewed all your thinos!","Daily review limit reached! Come back tomorrow.":"Daily review limit reached! Come back tomorrow.","Open thino in center window":"Open thino in center window","Open thino in float window":"Open thino in float window","Open thino in right sidebar":"Open thino in right sidebar","Open thino in left sidebar":"Open thino in left sidebar","Show thino editor":"Show thino editor","Toggle minimal mode":"Toggle minimal mode","Focus on thino editor":"Focus on thino editor","ReSync web thinos to local":"ReSync web thinos to local","Sync local thinos to web":"Sync local thinos to web","Show daily thino":"Show daily thino","Focus on search bar":"Focus on search bar","Show-thino in popover(Hover editor)":"Show-thino in popover(Hover editor)","Center window":"Center window","Float window":"Float window","Right sidebar":"Right sidebar","Left sidebar":"Left sidebar","Save thino type when sync local":"Save thino type when sync local","Set the default save thino type when sync local, FILE by default.":"Set the default save thino type when sync local, FILE by default.","Sync service":"Sync service","Pro verification status":"Pro verification status","Live-preview":"Live-preview",Source:"Source","Global copy":"Global copy","Set the folder name":"Set the folder name","Set the filename":"Set the filename","Set the filename for current location file":"Set the filename for current location file","Switch calendar type":"Switch calendar type",alphabetical:"alphabetical",alphabeticalReverse:"alphabeticalReverse",byCount:"byCount",byCountReverse:"byCountReverse","Type here":"Type here",Today:"Today",Yesterday:"Yesterday","Last 7 days":"Last 7 days","Last 30 days":"Last 30 days","Last 90 days":"Last 90 days","Last 180 days":"Last 180 days","Last 365 days":"Last 365 days",Found:"Found","Copy filtered thinos":"Copy filtered thinos","Bulk delete":"Bulk delete","Bulk archive":"Bulk archive","Bulk tag operation":"Bulk tag operation","Bulk restore":"Bulk restore","If you are disabling the daily note plugin, it would be possible that the thino will not be deleted or patched properly. Please enable the plugin and try again.":"If you are disabling the daily note plugin, it would be possible that the thino will not be deleted or patched properly. Please enable the plugin and try again.",Preview:"Preview","Set and save":"Set and save","Show day mark in thino list":"Show day mark in thino list","Show day mark on the top of daily range thino. False by default.":"Show day mark on the top of daily range thino. False by default.","Click to expand or fold, Cmd+Click to show all thinos of the day":"Click to expand or fold, Cmd+Click to show all thinos of the day","You can buy a license from":"You can buy a license from","No thinos in range":"No thinos in range",Month:"Month",Week:"Week",Day:"Day",Agenda:"Agenda",Tomorrow:"Tomorrow",Previous:"Previous",Next:"Next","Search all columns...":"Search all columns...","Basic Info":"Basic Info","Additional Info":"Additional Info","Created At":"Created At",Content:"Content","Thino Type":"Thino Type","Source Type":"Source Type","Row status":"Row status",Path:"Path","Pinned Status":"Pinned Status",Table:"Table",Chat:"Chat",Moments:"Moments",Waterfall:"Waterfall",Calendar:"Calendar","Go to page":"Go to page",Page:"Page",Show:"Show",rows:"rows","Temp Filter":"Temp Filter","Open link directly in Thino view":"Open link directly in Thino view","Day mark range":"Day mark range","Set the range of day mark. Day by default.":"Set the range of day mark. Day by default.","Thino is locked":"Thino is locked","Please unlock Thino by input password":"Please unlock Thino by input password","Auto Download Image":"Auto Download Image","Auto download image when save to thino. 'false' by default":"Auto download image when save to thino. 'false' by default","Thino Http IP Type":"Thino Http IP Type","Set Thino http server ip to listen. 'localhost' by default":"Set Thino http server ip to listen. 'localhost' by default","Password to lock Thino":"Password to lock Thino",Unlock:"Unlock",Locked:"Locked","Password is incorrect":"Password is incorrect",Lock:"Lock","Need password to unlock Thino":"Need password to unlock Thino","You have not set a password or enable this feature yet":"You have not set a password or enable this feature yet",Password:"Password","Password for Thino":"Password for Thino","Please input your password to change password settings":"Please input your password to change password settings","Please input your password":"Please input your password","Lock thino":"Lock thino",date:"date",time:"time",event:"event","Add tag position":"Add tag position","Set the position of the tag when adding tag automatically":"Set the position of the tag when adding tag automatically","Add tag automatically":"Add tag automatically","Add tag to the end or beginning of the thino content when creating a thino and filtering tags":"Add tag to the end or beginning of the thino content when creating a thino and filtering tags","Add tag with new line":"Add tag with new line","Add tag with new line when adding tag automatically":"Add tag with new line when adding tag automatically","Input to select more tags":"Input to select more tags","Tag Bulk Edit":"Tag Bulk Edit","Tag Bulk Select":"Tag Bulk Select","Exist Tags":"Exist Tags","Selected Tags":"Selected Tags","Click to remove exist tag":"Click to remove exist tag","Click to remove selected tag":"Click to remove selected tag","Select tags":"Select tags","Input to select exist tag":"Input to select exist tag",Beginning:"Beginning",End:"End","Set the heading for saving thino":"Set the heading for saving thino","# Heading":"# Heading","Chat view style":"Chat view style","Set the style of chat view":"Set the style of chat view","Background image for moments view":"Background image for moments view","Set the background image for moments view":"Set the background image for moments view","Icon for moments/chat view/share image":"Icon for moments/chat view/share image","Set the icon for moments/chat view/share image":"Set the icon for moments/chat view/share image","Quote for moments view/share image":"Quote for moments view/share image","Set the quote for moments view/share image":"Set the quote for moments view/share image","Theme for Thino":"Theme for Thino","Set the theme for Thino":"Set the theme for Thino","Interface Details":"Interface Details","Task amount":"Task amount","Thino status":"Thino status","Used tags":"Used tags","Used days":"Used days","Most active day":"Most active day","Most active hour":"Most active hour","Thino amount":"Thino amount","No content to generate.":"No content to generate.","Image generated successfully.":"Image generated successfully.","Failed to generate image.":"Failed to generate image.","Share filtered thinos as image":"Share filtered thinos as image","Latest version":"Latest version","Previous version":"Previous version","Thino update info":"Thino update info","Debug info copied to clipboard":"Debug info copied to clipboard","Copy debug info":"Copy debug info","Failed to load changelog":"Failed to load changelog","View online":"View online",ChangeLog:"ChangeLog","Please open thino first":"Please open thino first","Insert editor":"Insert editor","Please set different save locations for multi-file settings in Thino. The diary folder overlaps with the multi-file save location, or there is a risk of it being read repeatedly.":"Please set different save locations for multi-file settings in Thino. The diary folder overlaps with the multi-file save location, or there is a risk of it being read repeatedly.","Default time prefix for thino in daily notes":"Default time prefix for thino in daily notes","Set default time prefix for thino in daily notes.":"Set default time prefix for thino in daily notes.","Save image successfully":"Save image successfully","User quote":"User quote","Set user quote for thino":"Set user quote for thino","User icon":"User icon","Set user icon for thino. You can input http/https link or file path in vault.":"Set user icon for thino. You can input http/https link or file path in vault.","User info":"User info","Copy filtered results":"Copy filtered results","Share image":"Share image",Default:"Default",Gray:"Gray",Grass:"Grass",Flame:"Flame",Olive:"Olive",Ice:"Ice",Magenta:"Magenta","Daily notes":"Daily notes",Editor:"Editor","Append/prepend text when share to Thino":"Append/prepend text when share to Thino","Append text when share to Thino":"Append text when share to Thino","Prepend text when share to Thino":"Prepend text when share to Thino","Add newline when append/prepend text":"Add newline when append/prepend text","Input anything here":"Input anything here",Prepend:"Prepend",Append:"Append",Both:"Both",None:"None","Hide pinned group":"Hide pinned group","Hide pinned group in thino list. False by default.":"Hide pinned group in thino list. False by default.","Set the heading for the task type of thino, by default the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"Set the heading for the task type of thino, by default the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.","Different insert target for different type":"Different insert target for different type","Toggle this to set different insert target for different type of thino, like task or list type of thino":"Toggle this to set different insert target for different type of thino, like task or list type of thino","You can set whole diary or only part of it":"You can set whole diary or only part of it","Set process target":"Set process target",Custom:"Custom","Whole diary":"Whole Diary","Set thino insert place":"Set thino insert place","Set where to insert thino content":"Set where to insert thino content","End of the diary":"End of the diary","Custom location":"Custom location","Setting guide":"User setting guide","Details settings":"Details settings","Start Thino":"Start Thino","About Thino Pro":"About Thino Pro",Enabled:"Enabled",Enable:"Enable","Daily notes folder":"Daily notes folder","Set daily notes folder":"Set daily notes folder","Daily note name format":"Daily note name format","Set daily note name format":"Set daily note name format","Daily note plugin":"Daily note plugin","Enable daily note plugin":"Enable daily note plugin",Selected:"Selected",Select:"Select","A classic theme for Thino with a two-column layout":"A classic theme for Thino with a two-column layout",Classic:"Classic","A modern theme for Thino with a three-column layout and some unique features.":"A modern theme for Thino with a three-column layout and some unique features.",Modern:"Modern","Go and enjoy Thino":"Go and enjoy Thino","Congrats! All settings done":"Congrats! All settings done","Adjust settings that influence your user experience with Thino.":"Adjust settings that influence your user experience with Thino.","Set preferences for using Thino":"Set preferences for using Thino","If you are using the Thino basic version, enabling the daily note plugin is required. Configure its settings to work effectively with it.":"If you are using the Thino basic version, enabling the daily note plugin is required. Configure its settings to work effectively with it.","Go with daily note plugin":"Go with daily note plugin","Choose a theme for Thino.":"Choose a theme for Thino.","Set theme for Thino":"Set theme for Thino","Set up your user info for Thino.":"Set up your user info for Thino.","Get started with Thino":"Get started with Thino","Skip and start Thino":"Skip and start Thino","Next step":"Next step","Back to previous step":"Back to previous step","Click to enable =>":"Click to enable =>","This is Thino's sidebar. Navigate to different path or select query filter.":"This is Thino's sidebar. Navigate to different path or select query filter.","Click here and go to settings page.":"Click here and go to settings page.","Click here and go to different path.":"Click here and go to different path.","Select or create query filter here.":"Select or create query filter here.","See the status of Thinos here.":"See the status of Thinos here.","Search your thino quickly here.":"Search your thino quickly here.","Edit or create your thino here.":"Edit or create your thino here.","See your thinos here.":"See your thinos here.","See your time status of thinos here.":"See your time status of thinos here.","See your tags here. Tags will be shown when thino contains tags.":"See your tags here. Tags will be shown when thino contains tags.",Done:"Done","Thino is ready to use. ":"Thino is ready to use. ","You can start using Thino now. If you want to know more about Thino Pro, click the button below.":"You can start using Thino now. If you want to know more about Thino Pro, click the button below.","Default time prefix":"Default time prefix","Append Text Action":"Append Text Action","Prepend Text Action":"Prepend Text Action",Preset:"Preset","Select Tags":"Select Tags","It is not available on small view":"It is not available on small view","Append text":"Append text","Prepend text":"Prepend text","Your daily note folder is not set correctly, please check your settings":"Your daily note folder is not set correctly, please check your settings","Default sharing style":"Default sharing style","Set the default style for sharing thino, 'Modern' by default.":'Set the default style for sharing thino, "Modern" by default.',Clean:"Clean",Minimal:"Minimal",Gradient:"Gradient","Thino share":"Thino share","Copy to clipboard failed":"Copy to clipboard failed","Copy to clipboard successfully":"Copy to clipboard successfully","Your content has been copied to clipboard, and inserted into the editor. Please try it again":"Your content has been copied to clipboard, and inserted into the editor. Please try it again","Share thino":"Share thino","Set file name after create thino":"Set file name after create thino","You can set file name after create thino. A input box will show when you create thino.":"You can set file name after create thino. A input box will show when you create thino.",SPLIT:"SPLIT","Split by Heading 1":"Split by Heading 1","Split by Heading 2":"Split by Heading 2","Split by Heading 3":"Split by Heading 3","Insert task":"Insert task","All settings have been reset to default.":"All settings have been reset to default.","Reset all Thino settings":"Reset all Thino settings","Reset settings":"Reset settings","Reset Thino settings to default settings.":"Reset Thino settings to default settings.","Task Management":"Task Management","Append completed date when task done in thino":"Append completed date when task done in thino","Append completed date when task done in thino. False by default":"Append completed date when task done in thino. False by default","Set tag for single file that Thino indexes":"Set tag for single file that Thino indexes","When you set a tag here, Thino will index this file contains this tag and show it in the list. Don't need to add `#`.":"When you set a tag here, Thino will index this file contains this tag and show it in the list. Don't need to add `#`.","Set tag for file type file":"Set tag for file type file","Set tag for multi type file":"Set tag for multi type file","Ignore folders for multi type":"Ignore folders for multi type","Set folders to ignore when using multi type. Separate multiple folders with comma (,).":"Set folders to ignore when using multi type. Separate multiple folders with comma (,).","folder1,folder2/subfolder":"folder1,folder2/subfolder",Interface:"Interface","Please input the tag":"Please input the tag","Merge thinos in to thino share image":"Merge thinos in to thino share image","Custom height for Thino content":"Custom height for Thino content","Set custom height for Thino content. Like 200px or 20rem":"Set custom height for Thino content. Like 200px or 20rem","Input height":"Input height","Submit issue":"Submit issue","Current version":"Current version","Bug report":"Bug report","Click the button to copy debug info and open the issue page":"Click the button to copy debug info and open the issue page","Copy and go":"Copy and go","Debug info copied":"Debug info copied","Feature request":"Feature request","Submit your feature request to the issue page":"Submit your feature request to the issue page",Go:"Go","Toggle query list visibility":"Toggle query list visibility","Toggle tags visibility":"Toggle tags visibility","Toggle sidebar visibility":"Toggle sidebar visibility",Collapse:"Collapse",Expand:"Expand","Max height for collapse":"Max height for collapse","The max height for thino collapse, when set 0, thino would not collapse. 0 by default. (This is not lines count, it is height in px.)":"The max height for thino collapse, when set 0, thino would not collapse. 0 by default. (This is not lines count, it is height in px.)","Render content":"Render content","Optimize for Callout":"Optimize for Callout","Won't render content contains more than 3 callouts automatically. True by default":"Won't render content contains more than 3 callouts automatically. True by default","The value should be greater than":"The value should be greater than","Append Text":"Append Text","Prepend Text":"Prepend Text","Thino height when collapsed":"Thino height when collapsed","The height for thino when it is collapsed, when set 0, thino would not collapse. 100 by default. (This is not lines count, it is height in px.)":"The height for thino when it is collapsed, when set 0, thino would not collapse . 100 by default. (This is not lines count, it is height in px.)","This option will allow you use other views when leaf width is not enough. False by default.":"This option will allow you use other views when leaf width is not enough. False by default.","Can select other views when leaf width is not enough":"Can select other views when leaf width is not enough","TRASH BOX":"TRASH BOX","Wait templater to finish parse before insert thino":"Wait templater to finish parse before insert thino","This option will allow you to wait for templater to finish parse before insert thino, which may casue you need to confirm twice between insert thino. False by default.":"This option will allow you to wait for templater to finish parse before insert thino, which may casue you need to confirm twice between insert thino. False by default.","Get thino capture extension":"Get thino capture extension","You can capture idea/text from chrome now.":"You can capture idea/text from chrome now.","Open File":"Open File","Exported CSV file":"Exported CSV file","Updated At":"Updated At","Export to CSV":"Export to CSV","Quick add button on mobile navbar":"Quick add button on mobile navbar","Always show status text":"Always show status text","Support filter by metadata from file":"Support filter by metadata from file","When enable this, you can filter via metadata from file, like tags in file. But thinos from canvas is not supported. False by default.":"When enable this, you can filter via metadata from file, like tags in file. But thinos from canvas is not supported. False by default.","Show source near timestamp in thino":"Show source near timestamp in thino","When enable this, you can see the source near timestamp in thino. You can set title in metadata to overwrite this. False by default.":"When enable this, you can see the source near timestamp in thino. You can set title in metadata to overwrite this. False by default.","Show Update Message":"Show Update Message","Show update message when Thino is updated. True by default":"Show update message when Thino is updated. True by default","Sync manually":"Sync manually","Show all scrollbars":"Show all scrollbars","TIME RANGE":"TIME RANGE",WITHIN:"WITHIN","7 days":"7 days","14 days":"14 days","30 days":"30 days","3 months":"3 months","6 months":"6 months","1 year":"1 year","This week":"This week","Last week":"Last week","This month":"This month","Last month":"Last month","This year":"This year","Last year":"Last year","No history":"No history","Today Remaining":"Today Remaining","Today Total":"Today Total","Historical Statistics":"Historical Statistics",byTime:"By Time",byTimeReverse:"By Time Reverse",Stat:"Stat",Statistics:"Statistics","Daily Thino Count":"Daily Thino Count",Total:"Total",thinos:"thinos","Thino Types":"Thino Types","Distribution of thino types":"Distribution of thino types","Thino Status":"Thino Status","Distribution of thino status":"Distribution of thino status","Popular Tags":"Popular Tags","Top 10 most used tags":"Top 10 most used tags","Thino Count":"Thino Count","Hourly distribution":"Hourly distribution","Current month":"Current month","Monthly distribution":"Monthly distribution","30 Days":"Last 30 days",Year:"Year","Time Distribution":"Time Distribution","When do you write thinos":"When do you write thinos","Content Length":"Content Length","Distribution of thino lengths":"Distribution of thino lengths","Daily Thinos":"Daily Thinos","Show Time Distribution":"Show Time Distribution","Hide date picker":"Hide date picker","Show date picker":"Show date picker","Clear filter":"Clear filter","Copy link":"Copy link","Copy embed link":"Copy embed link","Ctrl/Cmd + Enter to save thino":"Ctrl/Cmd + Enter to save thino","Fixed strings for thinos":"Fixed strings for thinos","Use fixed strings for thinos":"Use fixed strings for thinos","Enable to add fixed strings at the beginning or end of thinos.":"Enable to add fixed strings at the beginning or end of thinos.","Fixed prefix for thinos":"Fixed prefix for thinos","Add this string at the beginning of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"Add this string at the beginning of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.","Fixed suffix for thinos":"Fixed suffix for thinos","Add this string at the end of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"Add this string at the end of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.","Word count exceeded":"Word count exceeded","Word count feature":"Word count feature","Enable real-time word count display in the editor":"Enable real-time word count display in the editor","Maximum word count":"Maximum word count","Set a maximum word count for thino. Editor will display a warning when exceeded. Set to 0 for unlimited.":"Set a maximum word count for thino. Editor will display a warning when exceeded. Set to 0 for unlimited.","No linked thinos found":"No linked thinos found","Reference links group":"Reference links group","Enable reference links group in thino.":"Enable reference links group in thino.","No reference links found":"No reference links found","Outgoing Links":"Outgoing Links","Incoming Links":"Incoming Links","Error fetching reference links":"Error fetching reference links","Double click behavior":"Double click behavior","Set the behavior when double click on a thino.":"Set the behavior when double click on a thino.","Open thino":"Open thino","Edit thino":"Edit thino","Go to source":"Go to source","Do nothing":"Do nothing","Use default header in mobile view":"Use default header in mobile view","Use default header in mobile view of thino rather than custom header.":"Use default header in mobile view of thino rather than custom header.","Using block link when dragging a thino":"Using block link when dragging a thino","Using block link when dragging a thino for daily":"Using block link when dragging a thino for daily","Matched via tag in content":"Matched via tag in content","Matched via tag in file":"Matched via tag in file","Focus on editor when open":"Focus on editor when open","Focus on editor when open. True by default.":"Focus on editor when open. True by default.","Show scroll to top button":"Show scroll to top button","Show scroll to top button. True by default":"Show scroll to top button. True by default.","Zoom image by default":"Zoom image by default","Zoom image by default when viewing image.":"Zoom image by default when viewing image.","View archive in random review":"View archive in random review","View archived thinos in random review. True by default":"View archived thinos in random review. True by default.","Linked by":"Linked by",Linked:"Linked",DUPLICATE:"Duplicate","Show scrollbars in all thino views.":"Show scrollbars in all thino views.","Drag to paste content":"Drag to paste content","You will be able to paste content from other apps to thino by dragging rather than pasting the block link.":"You will be able to paste content from other apps to thino by dragging rather than pasting the block link.","Dragging behavior":"Dragging behavior","Control the behavior when dragging a thino. You will paste the block link by default. Block-link option only works with source type is Daily Note.":"Control the behavior when dragging a thino. You will paste the block link by default. Block-link option only works with source type is Daily Note.","Block link":"Block link",Text:"Text"},K$={welcome:"Welcome to Thino",ribbonIconTitle:"Thino",to:"to",months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan.","Feb.","Mar.","Apr.","May","June","July","Aug.","Sept.","Oct.","Nov.","Dec."],weekDays:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],weekDaysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],year:null,month:null,"Basic Options":"Basic Options","User name":"User Name","Set your user name here. 'Memos 😏' By default":"Set your user name here. 'Thino 😏' By default",'You can set target heading like "# Heading" to control data location':'You can set target heading like "# Heading" to control data location',"Insert after heading":"Insert After Heading","If left blank, the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorised under that title.":"If left blank, the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorised under that title.","Allows admonitions to be created using ":"Allows admonitions to be created using ","Process Memos below":"Process Thino Below","If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.":"If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.","Save Memo button label":"Save Thino Button Label","The text shown on the save Memo button in the UI. 'NOTEIT' by default.":"The text shown on the save Thino button in the UI. 'NOTEIT' by default.","Focus on editor when open memos":"Focus on Editor When Open Thino","Focus on editor when open memos. Focus by default.":"Focus on editor when open thino. Focus by default.","Open daily memos with open memos":"Open Daily Thino with Open Thino","Open daily memos with open memos. Open by default.":"Open daily thino with open thino. Open by default.","Open Memos when obsidian opens":"Open Thino When Obsidian Opens","When enable this, Memos will open when Obsidian opens. False by default.":"When enabled, Thino will open when Obsidian opens. False by default.","Hide done tasks in Memo list":"Hide Done Tasks in Thino List","Hide all done tasks in Memo list. Show done tasks by default.":"Hide all done tasks in Thino list. Show done tasks by default.","Advanced Options":"Advanced Options","UI language for date":"UI Language for Date","Translates the date UI language. Only 'en' and 'zh' are available.":"Translates the date UI language. Only 'en' and 'zh' are available.","Default prefix when save thino":"Default Prefix When Save Thino","Set the default prefix when create memo, 'List' by default.":"Set the default prefix when create thino, 'List' by default.","Default insert date format":"Default Insert Date Format","Set the default date format when insert date by @, 'Tasks' by default.":"Set the default date format when insert date by @, 'Tasks' by default.","Default editor position on mobile":"Default Editor Position on Mobile","Set the default editor position on Mobile, 'Top' by default.":"Set the default editor position on Mobile, 'Top' by default.","Use button to show editor on mobile":"Use Button to Show Editor on Mobile","Set a float button to call editor on mobile. Only when editor located at the bottom works.":"Set a float button to call editor on mobile. Only when editor located at the bottom works.","Show Time When Copy Results":"Show Time When Copy Results","Show time when you copy results, like 12:00. Copy time by default.":"Show time when you copy results, like 12:00. Copy time by default.","Show Date When Copy Results":"Show Date When Copy Results","Show date when you copy results, like [[2022-01-01]]. Copy date by default.":"Show date when you copy results, like [[2022-01-01]]. Copy date by default.","Add Blank Line Between Different Date":"Add Blank Line Between Different Date","Add blank line when copy result with date. No blank line by default.":"Add blank line when copy result with date. No blank line by default.","Share Options":"Share Options","Share Memos Image Footer Start":"Share Thino Image Footer Start","Set anything you want here, use {ThinoNum} to display Number of thino, {UsedDay} for days. '{ThinoNum} Thino {UsedDay} Days' By default":"Set anything you want here, use {ThinoNum} to display Number of thino, {UsedDay} for days. '{ThinoNum} Thino {UsedDay} Days' By default","Share Memos Image Footer End":"Share Thino Image Footer End","Set anything you want here, use {UserName} as your username. '✍️ By {UserName}' By default":"Set anything you want here, use {UserName} as your username. '✍️ By {UserName}' By default","Save Shared Image To Folder For Mobile":"Save Shared Image To Folder For Mobile","Save image to folder for mobile. False by Default":"Save image to folder for mobile. False by Default","Say Thank You":"Say Thank You",Donate:"Donate","If you like this plugin, consider donating to support continued development:":"If you like this plugin, consider donating to support continued development:","File Name of Recycle Bin":"File Name of Recycle Bin","Set the filename for recycle bin. 'delete' By default":"Set the filename for recycle bin. 'delete' By default","File Name of Query File":"File Name of Query File","Set the filename for query file. 'query' By default":"Set the filename for query file. 'query' By default","Use Tags In Vault":"Use Tags In Vault","Use tags in vault rather than only in Memos. False by default.":"Use tags in vault rather than only in Thino. False by default.","Ready to convert image into background":"Ready to convert image into background",List:"List",Task:"Task",Top:"Top",Bottom:"Bottom",TAG:"TAG",DAY:"DAY",QUERY:"Query",EDIT:"EDIT",PIN:"PIN",UNPIN:"UNPIN",DELETE:"DELETE","CONFIRM!":"CONFIRM!","CREATE FILTER":"CREATE FILTER","Comment it...":"Comment it...",Settings:"Settings","Recycle bin":"Recycle Bin","About Me":"About Me","Fetching data...":"Fetching data...","Here is No Memos.":"Here is No Thino.","Frequently Used Tags":"Frequently Used Tags","What do you think now...":"What do you think now...",READ:"READ",MARK:"MARK",SHARE:"SHARE",SOURCE:"SOURCE",RESTORE:"RESTORE",ARCHIVE:"Archive","Daily Review":"Daily Review","DELETE AT":"DELETE AT","Noooop!":"Noooop!","All Data is Loaded 🎉":"All Data is Loaded 🎉","Quick filter":"Quick Filter",TYPE:"TYPE",LINKED:"LINKED","NO TAGS":"NO TAGS","HAS LINKS":"HAS LINKS","HAS IMAGES":"HAS IMAGES",INCLUDE:"INCLUDE",EXCLUDE:"EXCLUDE",TEXT:"TEXT",IS:"IS",AND:"AND",OR:"OR",LIST:"LIST",ISNOT:"IS NOT",PATH:"PATH",METADATA:"METADATA",SELECT:"SELECT","ADD FILTER TERMS":"ADD FILTER TERMS",FILTER:"FILTER",Filter:"Filter",TITLE:"TITLE","CREATE QUERY":"CREATE QUERY","EDIT QUERY":"EDIT QUERY",MATCH:"MATCH",TIMES:"TIMES","Share Memo Image":"Share Thino Image","↗Click the button to save":"↗Click the button to save","Image is generating...":"Image is generating...","Image is loading...":"Image is loading...","Loading...":"Loading...","😟 Cannot load image, image link maybe broken":"😟 Cannot load image, image link may be broken","Daily Memos":"Daily Thino","CANCEL EDIT":"CANCEL EDIT","LINK TO THE":"LINK TO THE","Mobile Options":"Mobile Options","Experimental Options":"Experimental Options","Don't support web image yet, please input image path in vault":"Don't support web image yet, please input image path in vault","Background Image in Dark Theme":"Background Image in Dark Theme","Background Image in Light Theme":"Background Image in Light Theme",'Set background image in dark theme. Set something like "Daily/one.png"':'Set background image in dark theme. Set something like "Daily/one.png"','Set background image in light theme. Set something like "Daily/one.png"':'Set background image in light theme. Set something like "Daily/one.png"','Set default memo composition, you should use {TIME} as "HH:mm" and {CONTENT} as content. "{TIME} {CONTENT}" by default':'Set default thino composition, you should use {TIME} as "HH:mm" and {CONTENT} as content. "{TIME} {CONTENT}" by default',"Default Memo Composition":"[Deprecated] Default Thino Composition","Show Tasks Label":"Show Tasks Label","Show tasks label near the time text. False by default":"Show tasks label near the time text. False by default","Please Open Memos First":"Please Open Thino First",DATE:"DATE",OBSIDIAN_NLDATES_PLUGIN_NOT_ENABLED:"OBSIDIAN_NLDATES_PLUGIN_NOT_ENABLED",BEFORE:"BEFORE",AFTER:"AFTER","Allow Comments On Memos":"Allow Comments On Thino","You can comment on memos. False by default":"You can comment on thino. False by default",Import:"Import","TITLE CANNOT BE NULL!":"TITLE CANNOT BE NULL!","FILTER CANNOT BE NULL!":"FILTER CANNOT BE NULL!","Comments In Original DailyNotes/Notes":"Comments In Original DailyNotes/Notes","You should install Dataview Plugin ver 0.5.9 or later to use this feature.":"You should install Dataview Plugin ver 0.5.9 or later to use this feature.","Open Memos Successfully":"Open Thino Successfully","Fetch Memos Error":"😭 Fetch Error","Copied to clipboard Successfully":"Copied to clipboard Successfully","Check if you opened Daily Notes Plugin Or Periodic Notes Plugin":"Check if you opened Daily Notes Plugin Or Periodic Notes Plugin","Please finish the last filter setting first":"Please finish the last filter setting first","Close Memos Successfully":"Close Thino Successfully","Insert as Memo":"Insert as Thino","Insert file as memo content":"Insert file as thino content","Image load failed":"Image load failed","Content cannot be empty":"Content cannot be empty","Unable to create new file.":"Unable to create new file.","Failed to fetch deleted memos: ":"Failed to fetch deleted thino: ","RESTORE SUCCEED":"RESTORE SUCCEED","DELETE SUCCEED":"DELETE SUCCEED","Save Memo button icon":"Save Thino button icon","The icon shown on the save Memo button in the UI.":"The icon shown on the save Thino button in the UI.","Fetch Memos From Particular Notes":"Fetch Thino From Particular Notes",'You can set any Dataview Query for memos to fetch it. All memos in those notes will show on list. "#memo" by default':'You can set any Dataview Query for thino to fetch it. All thino in those notes will show on list. "#memo" by default',"Allow Memos to Fetch Memo from Notes":"Allow Thino to Fetch Thino from Notes","Use Memos to manage all memos in your notes, not only in daily notes. False by default":"Use Thino to manage all thino in your notes, not only in daily notes. False by default","Always Show Memo Comments":"Always Show Thino Comments","Always show memo comments on memos. False by default":"Always show thino comments on thino. False by default","You didn't set folder for daily notes in both periodic-notes and daily-notes plugins.":"You haven't set folder for daily notes in both periodic-notes and daily-notes plugins.","Please check your daily note plugin OR periodic notes plugin settings":"Please check your daily note plugin OR periodic notes plugin settings","Use which plugin's default configuration":"Use which plugin's default configuration","Memos use the plugin's default configuration to fetch memos from daily, 'Daily' by default.":"Thino use the plugin's default configuration to fetch thino from daily, 'Daily' by default.",Daily:"Daily","Always Show Leaf Sidebar on PC":"Always Show Leaf Sidebar on PC","Show left sidebar on PC/Tablet even when the leaf width is less than 875px. False by default.":"Show left sidebar on PC/Tablet even when the leaf width is less than 875px. False by default.","You didn't set format for daily notes in both periodic-notes and daily-notes plugins.":"You haven't set format for daily notes in both periodic-notes and daily-notes plugins.","fetch more":"fetch more","Search all settings":"Search all settings",General:"General",Theme:"Theme",Share:"Share",Advanced:"Advanced",Thino:"Thino","Random Review":"Random Review","ARCHIVED AT":"ARCHIVED AT","Failed to get memos from daily notes":"Failed to get thino from daily notes","Failed to delete memo":"Failed to delete thino","CTRL + ENTER to save":"CTRL + ENTER to save","Started from":"Started from","Custom Background Image":"Custom Background Image","Set custom background image.":"Set custom background image.","Custom Memo Footer":"Custom Thino Footer","Set custom memo footer.":"Set custom thino footer.","Heatmap Color Scheme":"Heatmap Colour Scheme","Set different color scheme for heatmap.":"Set different colour scheme for heatmap.","Enable Local Http Server":"Enable Local Http Server","Memos Http Server Port":"Thino Http Server Port","Set memos http server port to listen. '43999' by default":"Set thino http server port to listen. '43999' by default","Default Editor Mode":"Default Editor Mode","Live-Preview Mode OR Source Mode.":"Live-Preview Mode/Source Mode.","Save type for Thino":"Save type for Thino",DAILY:"DAILY",MULTI:"MULTI",CANVAS:"CANVAS",ALL:"ALL",FILE:"FILE",TODO:"TODO",DONE:"DONE",JOURNAL:"JOURNAL",OTHER:"OTHER","Failed to create daily note, check if it exists.":"Failed to create daily note, check if it exists.","Failed to create daily note. Please check if you created a folder for daily notes.":"Failed to create daily note. Please check if you created a folder for daily notes.","After you verify your account, please refresh this page.":"After you verify your account, please refresh this page.",Verify:"Verify","Oops! You forget to verify insider account":"Oops! You forgot to verify insider account","If you have any questions, please contact us.":"If you have any questions, please contact us.","Delete Thino Directly":"Delete Thino Directly","When delete thino directly, it will not be moved to trash. False by default.":"When delete thino directly, it will not be moved to bin. False by default.","Enable opening thino globally":"Enable opening thino globally","Enable opening thino globally. False by default.":"Enable opening thino globally. False by default.","Key for opening thino globally":"Key for opening thino globally","Set key for opening thino globally. CTRL + SHIFT + T by default.":"Set key for opening thino globally. CTRL + SHIFT + T by default.","Key for showing thino globally":"Key for showing thino globally","Set key for showing thino globally. CTRL + SHIFT + E by default.":"Set key for showing thino globally. CTRL + SHIFT + E by default.","Get activation code":"Get activation code","Input activation code here":"Input activation code here","Copy Thino id":"Copy Thino id","Activate Pro Version":"Activate Pro Version","Please copy Thino id first":"Please copy Thino id first",'You can set folder name with file name like "folder/file"':'You can set folder name with file name like "folder/file"','You can set folder name like "folder1/folder2/folder3" to create sub-folder':'You can set folder name like "folder1/folder2/folder3" to create sub-folder',"Default save type":"Default save location",'Set the default save type for thino. "DAILY" by default':'Set the default save type for thino. "DAILY" by default',"Sync Thino via PKMer":"Sync Thino via PKMer",Unlink:"Unlink",Link:"Link","Connect to PKMer Sync, you can check it in ":"Connect to PKMer Sync, you can check it in ","PKMer Sync":"PKMer Sync","Remove successfully":"Remove successfully",Deactivate:"Deactivate",Remove:"Remove","Confirm?":"Confirm?","Sync Status":"Sync Status","Start or stop sync":"Start or stop sync","Stop sync successfully":"Stop sync successfully","Start sync successfully":"Start sync successfully",Stop:"Stop",Start:"Start","Show thino near mouse":"Show thino near mouse","Query not found":"Query not found","Send to clipboard successfully":"Send to clipboard successfully","Thino - Failed to start HTTP server, please check the port is available.":"Thino - Failed to start HTTP server, please check the port is available.","Thino - Started HTTP server on port":"Thino - Started HTTP server on port","Thino - Terminated HTTP server":"Thino - Terminated HTTP server","File not exist":"File does not exist","Thino not found":"Thino not found","File not found for the given thino path, is creating a new file":"File not found for the given thino path, creating a new file","Saved sync token successfully":"Saved sync token successfully","Failed to find daily notes folder":"Failed to find daily notes folder","Please install obsidian-hover-editor plugin first":"Please install obsidian-hover-editor plugin first","Copied app id successfully":"Copied app id successfully","Please input token first":"Please input token first","Please enable sync first":"Please enable sync first","Init Failed":"Init Failed","Verify successfully":"Verify successfully","Failed to verify":"Failed to verify","Folder not found for the given thino path, is creating a new folder":"Folder not found for the given thino path, creating a new folder","File not found for the given thino path":"File not found for the given thino path","Failed to read current daily note, check if it exists.":"Failed to read current daily note, check if it exists.","Failed to save":"Failed to save","Failed to login, please login again":"Failed to login, please login again","COPY FAILED":"COPY FAILED","COPY SUCCEED":"COPY SUCCEED","Copy selected text":"Copy selected text","Copy thino":"Copy thino",COPY:"COPY","This is a pro feature, please upgrade to pro version to use it.":"This is a pro feature, please upgrade to pro version to use it.","You can get pro version from: ":"You can get pro version from: ",Save:"Save",Cancel:"Cancel","Thino Daily Target":"Thino Daily Target",Input:"Input","#Tag":"#Tag","to create tag":"to create tag","You have verified your account. Congrats!":"You have verified your account. Congrats!","Pro features":"Pro features","Target Thino Count":"Target Thino Count",on:"on","Switch waterfall view":"Switch waterfall view","Switch view":"Switch view","Switch list view":"Switch list view","Set daily target":"Set daily target","Thino Save To: ":"Thino Save To: ","Enter fullscreen mode":"Enter fullscreen mode","Exit fullscreen mode":"Exit fullscreen mode",words:"words",word:"word","Return To Home Page":"Return To Home Page","No thinos to review!":"No thinos to review!","Thinos to review":"Thinos to review","Start Review":"Start Review",Hard:"Hard",Good:"Good",Easy:"Easy",Again:"Again","Clear all review data":"Clear all review data","Daily Progress":"Daily Progress","Show stats":"Show stats","Hide stats":"Hide stats",Remaining:"Remaining","Total Reviews":"Total Reviews","Today, you have reviewed all your thinos!":"Today, you have reviewed all your thinos!","Daily review limit reached! Come back tomorrow.":"Daily review limit reached! Come back tomorrow.","Open thino in center window":"Open thino in centre window","Open thino in float window":"Open thino in float window","Open thino in right sidebar":"Open thino in right sidebar","Open thino in left sidebar":"Open thino in left sidebar","Show thino editor":"Show thino editor","Toggle minimal mode":"Toggle minimal mode","Focus on thino editor":"Focus on thino editor","ReSync web thinos to local":"ReSync web thinos to local","Sync local thinos to web":"Sync local thinos to web","Show daily thino":"Show daily thino","Focus on search bar":"Focus on search bar","Show-thino in popover(Hover editor)":"Show-thino in popover(Hover editor)","Center window":"Centre window","Float window":"Float window","Right sidebar":"Right sidebar","Left sidebar":"Left sidebar","Save thino type when sync local":"Save thino type when sync local","Set the default save thino type when sync local, FILE by default.":"Set the default save thino type when sync local, FILE by default.","Sync service":"Sync service","Pro verification status":"Pro verification status","Live-preview":"Live-preview",Source:"Source","Global copy":"Global copy","Set the folder name":"Set the folder name","Set the filename":"Set the filename","Set the filename for current location file":"Set the filename for current location file","Switch calendar type":"Switch calendar type",alphabetical:"alphabetical",alphabeticalReverse:"alphabeticalReverse",byCount:"byCount",byCountReverse:"byCountReverse","Type here":"Type here",Today:"Today",Yesterday:"Yesterday","Last 7 days":"Last 7 days","Last 30 days":"Last 30 days","Last 90 days":"Last 90 days","Last 180 days":"Last 180 days","Last 365 days":"Last 365 days",Found:"Found","Copy filtered thinos":"Copy filtered thinos","Bulk delete":"Bulk delete","Bulk archive":"Bulk archive","Bulk tag operation":"Bulk tag operation","Bulk restore":"Bulk restore","If you are disabling the daily note plugin, it would be possible that the thino will not be deleted or patched properly. Please enable the plugin and try again.":"If you are disabling the daily note plugin, it would be possible that the thino will not be deleted or patched properly. Please enable the plugin and try again.",Preview:"Preview","Set and save":"Set and save","Show day mark in thino list":"Show day mark in thino list","Show day mark on the top of daily range thino. False by default.":"Show day mark on the top of daily range thino. False by default.","Click to expand or fold, Cmd+Click to show all thinos of the day":"Click to expand or fold, Cmd+Click to show all thinos of the day","You can buy a license from":"You can buy a licence from","No thinos in range":"No thinos in range",Month:"Month",Week:"Week",Day:"Day",Agenda:"Agenda",Tomorrow:"Tomorrow",Previous:"Previous",Next:"Next","Search all columns...":"Search all columns...","Basic Info":"Basic Info","Additional Info":"Additional Info","Created At":"Created At",Content:"Content","Thino Type":"Thino Type","Source Type":"Source Type","Row status":"Row status",Path:"Path","Pinned Status":"Pinned Status",Table:"Table",Chat:"Chat",Moments:"Moments",Waterfall:"Waterfall",Calendar:"Calendar","Go to page":"Go to page",Page:"Page",Show:"Show",rows:"rows","Temp Filter":"Temp Filter","Open link directly in Thino view":"Open link directly in Thino view","Day mark range":"Day mark range","Set the range of day mark. Day by default.":"Set the range of day mark. Day by default.","Thino is locked":"Thino is locked","Please unlock Thino by input password":"Please unlock Thino by input password","Auto Download Image":"Auto Download Image","Auto download image when save to thino. 'false' by default":"Auto download image when save to thino. 'false' by default","Thino Http IP Type":"Thino Http IP Type","Set Thino http server ip to listen. 'localhost' by default":"Set Thino http server ip to listen. 'localhost' by default","Password to lock Thino":"Password to lock Thino",Unlock:"Unlock",Locked:"Locked","Password is incorrect":"Password is incorrect",Lock:"Lock","Need password to unlock Thino":"Need password to unlock Thino","You have not set a password or enable this feature yet":"You have not set a password or enabled this feature yet",Password:"Password","Password for Thino":"Password for Thino","Please input your password to change password settings":"Please input your password to change password settings","Please input your password":"Please input your password","Lock thino":"Lock thino",date:"date",time:"time",event:"event","Add tag position":"Add tag position","Set the position of the tag when adding tag automatically":"Set the position of the tag when adding tag automatically","Add tag automatically":"Add tag automatically","Add tag to the end or beginning of the thino content when creating a thino and filtering tags":"Add tag to the end or beginning of the thino content when creating a thino and filtering tags","Add tag with new line":"Add tag with new line","Add tag with new line when adding tag automatically":"Add tag with new line when adding tag automatically","Input to select more tags":"Input to select more tags","Tag Bulk Edit":"Tag Bulk Edit","Tag Bulk Select":"Tag Bulk Select","Exist Tags":"Exist Tags","Selected Tags":"Selected Tags","Click to remove exist tag":"Click to remove exist tag","Click to remove selected tag":"Click to remove selected tag","Select tags":"Select tags","Input to select exist tag":"Input to select exist tag",Beginning:"Beginning",End:"End","Set the heading for saving thino":"Set the heading for saving thino","# Heading":"# Heading","Chat view style":"Chat view style","Set the style of chat view":"Set the style of chat view","Background image for moments view":"Background image for moments view","Set the background image for moments view":"Set the background image for moments view","Icon for moments/chat view/share image":"Icon for moments/chat view/share image","Set the icon for moments/chat view/share image":"Set the icon for moments/chat view/share image","Quote for moments view/share image":"Quote for moments view/share image","Set the quote for moments view/share image":"Set the quote for moments view/share image","Theme for Thino":"Theme for Thino","Set the theme for Thino":"Set the theme for Thino","Interface Details":"Interface Details","Task amount":"Task amount","Thino status":"Thino status","Used tags":"Used tags","Used days":"Used days","Most active day":"Most active day","Most active hour":"Most active hour","Thino amount":"Thino amount","No content to generate.":"No content to generate.","Image generated successfully.":"Image generated successfully.","Failed to generate image.":"Failed to generate image.","Share filtered thinos as image":"Share filtered thinos as image","Latest version":"Latest version","Previous version":"Previous version","Thino update info":"Thino update info","Debug info copied to clipboard":"Debug info copied to clipboard","Copy debug info":"Copy debug info","Failed to load changelog":"Failed to load changelog","View online":"View online",ChangeLog:"ChangeLog","Please open thino first":"Please open thino first","Insert editor":"Insert editor","Please set different save locations for multi-file settings in Thino. The diary folder overlaps with the multi-file save location, or there is a risk of it being read repeatedly.":"Please set different save locations for multi-file settings in Thino. The diary folder overlaps with the multi-file save location, or there is a risk of it being read repeatedly.","Default time prefix for thino in daily notes":"Default time prefix for thino in daily notes","Set default time prefix for thino in daily notes.":"Set default time prefix for thino in daily notes.","Save image successfully":"Save image successfully","User quote":"User quote","Set user quote for thino":"Set user quote for thino","User icon":"User icon","Set user icon for thino. You can input http/https link or file path in vault.":"Set user icon for thino. You can input http/https link or file path in vault.","User info":"User info","Copy filtered results":"Copy filtered results","Share image":"Share image",Default:"Default",Gray:"Gray",Grass:"Grass",Flame:"Flame",Olive:"Olive",Ice:"Ice",Magenta:"Magenta","Daily notes":"Daily notes",Editor:"Editor","Append/prepend text when share to Thino":"Append/prepend text when share to Thino","Append text when share to Thino":"Append text when share to Thino","Prepend text when share to Thino":"Prepend text when share to Thino","Add newline when append/prepend text":"Add newline when append/prepend text","Input anything here":"Input anything here",Prepend:"Prepend",Append:"Append",Both:"Both",None:"None","Hide pinned group":"Hide pinned group","Hide pinned group in thino list. False by default.":"Hide pinned group in thino list. False by default.","Set the heading for the task type of thino, by default the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"Set the heading for the task type of thino, by default the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.","Different insert target for different type":"Different insert target for different type","Toggle this to set different insert target for different type of thino, like task or list type of thino":"Toggle this to set different insert target for different type of thino, like task or list type of thino","You can set whole diary or only part of it":"You can set whole diary or only part of it","Set process target":"Set process target",Custom:"Custom","Whole diary":"Whole Diary","Set thino insert place":"Set thino insert place","Set where to insert thino content":"Set where to insert thino content","End of the diary":"End of the diary","Custom location":"Custom location","Setting guide":"User setting guide","Details settings":"Details settings","Start Thino":"Start Thino","About Thino Pro":"About Thino Pro",Enabled:"Enabled",Enable:"Enable","Daily notes folder":"Daily notes folder","Set daily notes folder":"Set daily notes folder","Daily note name format":"Daily note name format","Set daily note name format":"Set daily note name format","Daily note plugin":"Daily note plugin","Enable daily note plugin":"Enable daily note plugin",Selected:"Selected",Select:"Select","A classic theme for Thino with a two-column layout":"A classic theme for Thino with a two-column layout",Classic:"Classic","A modern theme for Thino with a three-column layout and some unique features.":"A modern theme for Thino with a three-column layout and some unique features.",Modern:"Modern","Go and enjoy Thino":"Go and enjoy Thino","Congrats! All settings done":"Congrats! All settings done","Adjust settings that influence your user experience with Thino.":"Adjust settings that influence your user experience with Thino.","Set preferences for using Thino":"Set preferences for using Thino","If you are using the Thino basic version, enabling the daily note plugin is required. Configure its settings to work effectively with it.":"If you are using the Thino basic version, enabling the daily note plugin is required. Configure its settings to work effectively with it.","Go with daily note plugin":"Go with daily note plugin","Choose a theme for Thino.":"Choose a theme for Thino.","Set theme for Thino":"Set theme for Thino","Set up your user info for Thino.":"Set up your user info for Thino.","Get started with Thino":"Get started with Thino","Skip and start Thino":"Skip and start Thino","Next step":"Next step","Back to previous step":"Back to previous step","Click to enable =>":"Click to enable =>","This is Thino's sidebar. Navigate to different path or select query filter.":"This is Thino's sidebar. Navigate to different path or select query filter.","Click here and go to settings page.":"Click here and go to settings page.","Click here and go to different path.":"Click here and go to different path.","Select or create query filter here.":"Select or create query filter here.","See the status of Thinos here.":"See the status of Thinos here.","Search your thino quickly here.":"Search your thino quickly here.","Edit or create your thino here.":"Edit or create your thino here.","See your thinos here.":"See your thinos here.","See your time status of thinos here.":"See your time status of thinos here.","See your tags here. Tags will be shown when thino contains tags.":"See your tags here. Tags will be shown when thino contains tags.",Done:"Done","Thino is ready to use. ":"Thino is ready to use. ","You can start using Thino now. If you want to know more about Thino Pro, click the button below.":"You can start using Thino now. If you want to know more about Thino Pro, click the button below.","Default time prefix":"Default time prefix","Append Text Action":"Append Text Action","Prepend Text Action":"Prepend Text Action",Preset:"Preset","Select Tags":"Select Tags","It is not available on small view":"It is not available on small view","Append text":"Append text","Prepend text":"Prepend text","Your daily note folder is not set correctly, please check your settings":"Your daily note folder is not set correctly, please check your settings","Default sharing style":"Default sharing style","Set the default style for sharing thino, 'Modern' by default.":'Set the default style for sharing thino, "Modern" by default.',Clean:"Clean",Minimal:"Minimal",Gradient:"Gradient","Thino share":"Thino share","Copy to clipboard failed":"Copy to clipboard failed","Copy to clipboard successfully":"Copy to clipboard successfully","Your content has been copied to clipboard, and inserted into the editor. Please try it again":"Your content has been copied to clipboard, and inserted into the editor. Please try it again","Share thino":"Share thino","Set file name after create thino":"Set file name after create thino","You can set file name after create thino. A input box will show when you create thino.":"You can set file name after create thino. A input box will show when you create thino.",SPLIT:"SPLIT","Split by Heading 1":"Split by Heading 1","Split by Heading 2":"Split by Heading 2","Split by Heading 3":"Split by Heading 3","Insert task":"Insert task","All settings have been reset to default.":"All settings have been reset to default.","Reset all Thino settings":"Reset all Thino settings","Reset settings":"Reset settings","Reset Thino settings to default settings.":"Reset Thino settings to default settings.","Task Management":"Task Management","Append completed date when task done in thino":"Append completed date when task done in thino","Append completed date when task done in thino. False by default":"Append completed date when task done in thino. False by default","Set tag for single file that Thino indexes":"Set tag for single file that Thino indexes","When you set a tag here, Thino will index this file contains this tag and show it in the list. Don't need to add `#`.":"When you set a tag here, Thino will index this file contains this tag and show it in the list. Don't need to add `#`.","Set tag for file type file":"Set tag for file type file","Set tag for multi type file":"Set tag for multi type file","Please input the tag":"Please input the tag","Merge thinos in to thino share image":"Merge thinos in to thino share image","Custom height for Thino content":"Custom height for Thino content","Set custom height for Thino content. Like 200px or 20rem":"Set custom height for Thino content. Like 200px or 20rem","Input height":"Input height","Submit issue":"Submit issue","Current version":"Current version","Bug report":"Bug report","Click the button to copy debug info and open the issue page":"Click the button to copy debug info and open the issue page","Copy and go":"Copy and go","Debug info copied":"Debug info copied","Feature request":"Feature request","Submit your feature request to the issue page":"Submit your feature request to the issue page",Go:"Go","Toggle query list visibility":"Toggle query list visibility","Toggle tags visibility":"Toggle tags visibility","Toggle sidebar visibility":"Toggle sidebar visibility",Collapse:"Collapse",Expand:"Expand","Max height for collapse":"Max height for collapse","The max height for thino collapse, when set 0, thino would not collapse. 0 by default. (This is not lines count, it is height in px.)":"The max height for thino collapse, when set 0, thino would not collapse. 0 by default. (This is not lines count, it is height in px.)","Render content":"Render content","Optimize for Callout":"Optimize for Callout","Won't render content contains more than 3 callouts automatically. True by default":"Won't render content contains more than 3 callouts automatically. True by default","The value should be greater than":"The value should be greater than","Append Text":"Append Text","Prepend Text":"Prepend Text","Thino height when collapsed":"Thino height when collapsed","The height for thino when it is collapsed, when set 0, thino would not collapse. 100 by default. (This is not lines count, it is height in px.)":"The height for thino when it is collapsed, when set 0, thino would not collapse . 100 by default. (This is not lines count, it is height in px.)","This option will allow you use other views when leaf width is not enough. False by default.":"This option will allow you use other views when leaf width is not enough. False by default.","Can select other views when leaf width is not enough":"Can select other views when leaf width is not enough","TRASH BOX":"TRASH BOX","Wait templater to finish parse before insert thino":"Wait templater to finish parse before insert thino","This option will allow you to wait for templater to finish parse before insert thino, which may casue you need to confirm twice between insert thino. False by default.":"This option will allow you to wait for templater to finish parse before insert thino, which may casue you need to confirm twice between insert thino. False by default.","Get thino capture extension":"Get thino capture extension","You can capture idea/text from chrome now.":"You can capture idea/text from chrome now.","Open File":"Open File","Exported CSV file":"Exported CSV file","Updated At":"Updated At","Export to CSV":"Export to CSV","Quick add button on mobile navbar":"Quick add button on mobile navbar","Always show status text":"Always show status text","Support filter by metadata from file":"Support filter by metadata from file","When enable this, you can filter via metadata from file, like tags in file. But thinos from canvas is not supported. False by default.":"When enable this, you can filter via metadata from file, like tags in file. But thinos from canvas is not supported. False by default.","Show source near timestamp in thino":"Show source near timestamp in thino","When enable this, you can see the source near timestamp in thino. You can set title in metadata to overwrite this. False by default.":"When enable this, you can see the source near timestamp in thino. You can set title in metadata to overwrite this. False by default.","Show Update Message":"Show Update Message","Show update message when Thino is updated. True by default":"Show update message when Thino is updated. True by default","Sync manually":"Sync manually","Show all scrollbars":"Show all scrollbars","TIME RANGE":"TIME RANGE",WITHIN:"WITHIN","7 days":"7 days","14 days":"14 days","30 days":"30 days","3 months":"3 months","6 months":"6 months","1 year":"1 year","This week":"This week","Last week":"Last week","This month":"This month","Last month":"Last month","This year":"This year","Last year":"Last year","No history":"No history","Today Remaining":"Today Remaining","Today Total":"Today Total","Historical Statistics":"Historical Statistics",byTime:"By Time",byTimeReverse:"By Time Reverse",Stat:"Stat",Statistics:"Statistics","Daily Thino Count":"Daily Thino Count",Total:"Total",thinos:"thinos","Thino Types":"Thino Types","Distribution of thino types":"Distribution of thino types","Thino Status":"Thino Status","Distribution of thino status":"Distribution of thino status","Popular Tags":"Popular Tags","Top 10 most used tags":"Top 10 most used tags","Thino Count":"Thino Count","Hourly distribution":"Hourly distribution","Current month":"Current month","Monthly distribution":"Monthly distribution","30 Days":"Last 30 days",Year:"Year","Time Distribution":"Time Distribution","When do you write thinos":"When do you write thinos","Content Length":"Content Length","Distribution of thino lengths":"Distribution of thino lengths","Daily Thinos":"Daily Thinos","Show Time Distribution":"Show Time Distribution","Hide date picker":"Hide date picker","Show date picker":"Show date picker","Clear filter":"Clear filter","Copy link":"Copy link","Copy embed link":"Copy embed link","Ctrl/Cmd + Enter to save thino":"Ctrl/Cmd + Enter to save thino","Fixed strings for thinos":"Fixed strings for thinos","Use fixed strings for thinos":"Use fixed strings for thinos","Enable to add fixed strings at the beginning or end of thinos.":"Enable to add fixed strings at the beginning or end of thinos.","Fixed prefix for thinos":"Fixed prefix for thinos","Add this string at the beginning of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"Add this string at the beginning of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.","Fixed suffix for thinos":"Fixed suffix for thinos","Add this string at the end of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"Add this string at the end of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.","Word count exceeded":"Word count exceeded","Word count feature":"Word count feature","Enable real-time word count display in the editor":"Enable real-time word count display in the editor","Maximum word count":"Maximum word count","Set a maximum word count for thino. Editor will display a warning when exceeded. Set to 0 for unlimited.":"Set a maximum word count for thino. Editor will display a warning when exceeded. Set to 0 for unlimited.","No linked thinos found":"No linked thinos found","Reference links group":"Reference links group","Enable reference links group in thino.":"Enable reference links group in thino.","No reference links found":"No reference links found","Outgoing Links":"Outgoing Links","Incoming Links":"Incoming Links","Error fetching reference links":"Error fetching reference links","Double click behavior":"Double click behavior","Set the behavior when double click on a thino.":"Set the behavior when double click on a thino.","Open thino":"Open thino","Edit thino":"Edit thino","Go to source":"Go to source","Do nothing":"Do nothing","Use default header in mobile view":"Use default header in mobile view","Use default header in mobile view of thino rather than custom header.":"Use default header in mobile view of thino rather than custom header."},X$={welcome:"¡Bienvenido a Thino!",ribbonIconTitle:"Thino",to:"a",months:["Enero","Febrero","Marzo","Abril","Mayo","Junio","Julio","Agosto","Septiembre","Octubre","Noviembre","Diciembre"],monthsShort:["Ene.","Feb.","Mar.","Abr.","May.","Jun.","Jul.","Ago.","Sep.","Oct.","Nov.","Dic."],weekDays:["Domingo","Lunes","Martes","Miércoles","Jueves","Viernes","Sábado"],weekDaysShort:["Dom","Lun","Mar","Mié","Jue","Vie","Sáb"],year:null,month:null,"Basic Options":"Opciones básicas","User name":"Nombre de usuario","Set your user name here. 'Memos 😏' By default":"Establece tu nombre de usuario aquí. 'Thino 😏' por defecto",'You can set target heading like "# Heading" to control data location':'Puedes establecer un encabezado objetivo como "# Encabezado" para controlar la ubicación de los datos',"Insert after heading":"Insertar después del encabezado","If left blank, the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"Si se deja en blanco, el contenido thino registrado se insertará al final del diario; si se proporciona un título, todo el contenido thino registrado se categorizará uniformemente bajo ese título.","Allows admonitions to be created using ":"Permite crear advertencias usando ","Process Memos below":"Procesar thinos debajo","If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.":"Si se deja en blanco, la interfaz de Thino mostrará todos los contenidos de registros thino; si se proporciona un título, la interfaz de Thino solo mostrará los contenidos bajo ese título, y los contenidos escritos en otros lugares no se mostrarán.","Save Memo button label":"Etiqueta del botón Guardar thino","The text shown on the save Memo button in the UI. 'NOTEIT' by default.":"El texto mostrado en el botón guardar Thino en la interfaz. 'NOTEIT' por defecto.","Focus on editor when open memos":"Enfocar en el editor al abrir thinos","Focus on editor when open memos. Focus by default.":"Enfocar en el editor al abrir thinos. Enfocado por defecto.","Open daily memos with open memos":"Abrir thinos diarios al abrir thinos","Open daily memos with open memos. Open by default.":"Abrir thinos diarios al abrir thinos. Abierto por defecto.","Open Memos when obsidian opens":"Abrir Thino cuando se abre Obsidian","When enable this, Memos will open when Obsidian opens. False by default.":"Cuando esto está habilitado, Thino se abrirá cuando se abra Obsidian. Deshabilitado por defecto.","Hide done tasks in Memo list":"Ocultar tareas completadas en la lista de thinos","Hide all done tasks in Memo list. Show done tasks by default.":"Ocultar todas las tareas completadas en la lista de thinos. Mostrar tareas completadas por defecto.","Advanced Options":"Opciones avanzadas","UI language for date":"Idioma de la interfaz para fechas","Translates the date UI language. Only 'en' and 'zh' are available.":"Traduce el idioma de la interfaz de fechas. Solo 'en' y 'zh' están disponibles.","Default prefix when save thino":"Prefijo predeterminado al guardar thino","Set the default prefix when create memo, 'List' by default.":"Establece el prefijo predeterminado al crear thino, 'Lista' por defecto.","Default insert date format":"Formato de fecha de inserción predeterminado","Set the default date format when insert date by @, 'Tasks' by default.":"Establece el formato de fecha predeterminado al insertar fecha con @, 'Tareas' por defecto.","Default editor position on mobile":"Posición predeterminada del editor en móvil","Set the default editor position on Mobile, 'Top' by default.":"Establece la posición predeterminada del editor en móvil, 'Arriba' por defecto.","Use button to show editor on mobile":"Usar botón para mostrar editor en móvil","Set a float button to call editor on mobile. Only when editor located at the bottom works.":"Establece un botón flotante para llamar al editor en móvil. Solo funciona cuando el editor está ubicado en la parte inferior.","Show Time When Copy Results":"Mostrar hora al copiar resultados","Show time when you copy results, like 12:00. Copy time by default.":"Mostrar hora cuando copias resultados, como 12:00. Copiar hora por defecto.","Show Date When Copy Results":"Mostrar fecha al copiar resultados","Show date when you copy results, like [[2022-01-01]]. Copy date by default.":"Mostrar fecha cuando copias resultados, como [[2022-01-01]]. Copiar fecha por defecto.","Add Blank Line Between Different Date":"Agregar línea en blanco entre fechas diferentes","Add blank line when copy result with date. No blank line by default.":"Agregar línea en blanco al copiar resultado con fecha. Sin línea en blanco por defecto.","Share Options":"Opciones de compartir","Share Memos Image Footer Start":"Inicio del pie de imagen al compartir Thino","Set anything you want here, use {ThinoNum} to display Number of thino, {UsedDay} for days. '{ThinoNum} Thino {UsedDay} Days' By default":"Establece lo que quieras aquí, usa {ThinoNum} para mostrar el número de thino, {UsedDay} para días. '{ThinoNum} Thino {UsedDay} Días' por defecto","Share Memos Image Footer End":"Final del pie de imagen al compartir Thino","Set anything you want here, use {UserName} as your username. '✍️ By {UserName}' By default":"Establece lo que quieras aquí, usa {UserName} como tu nombre de usuario. '✍️ Por {UserName}' por defecto","Save Shared Image To Folder For Mobile":"Guardar imagen compartida en carpeta para móvil","Save image to folder for mobile. False by Default":"Guardar imagen en carpeta para móvil. Deshabilitado por defecto","Say Thank You":"Dar las gracias",Donate:"Donar","If you like this plugin, consider donating to support continued development:":"Si te gusta este plugin, considera donar para apoyar el desarrollo continuo:","File Name of Recycle Bin":"Nombre del archivo de la papelera de reciclaje","Set the filename for recycle bin. 'delete' By default":"Establece el nombre de archivo para la papelera. 'eliminar' por defecto","File Name of Query File":"Nombre del archivo de consulta","Set the filename for query file. 'query' By default":"Establece el nombre de archivo para consulta. 'consulta' por defecto","Use Tags In Vault":"Usar etiquetas en la bóveda","Use tags in vault rather than only in Memos. False by default.":"Usar etiquetas en la bóveda en lugar de solo en Thino. Deshabilitado por defecto.","Ready to convert image into background":"Listo para convertir imagen en fondo",List:"Lista",Task:"Tarea",Top:"Arriba",Bottom:"Abajo",TAG:"ETIQUETA",DAY:"DÍA",QUERY:"CONSULTA",EDIT:"EDITAR",PIN:"FIJAR",UNPIN:"DESFIJAR",DELETE:"ELIMINAR","CONFIRM!":"¡CONFIRMAR!","CREATE FILTER":"CREAR FILTRO","Comment it...":"Comentar...",Settings:"Ajustes","Recycle bin":"Papelera de reciclaje","About Me":"Sobre mí","Fetching data...":"Obteniendo datos...","Here is No Memos.":"No hay thinos aquí.","Frequently Used Tags":"Etiquetas frecuentes","What do you think now...":"¿Qué piensas ahora...?",READ:"LEER",MARK:"MARCAR",SHARE:"COMPARTIR",SOURCE:"FUENTE",RESTORE:"RESTAURAR",ARCHIVE:"Archivar","Daily Review":"Revisión diaria","DELETE AT":"ELIMINADO EL","Noooop!":"¡Noooop!","All Data is Loaded 🎉":"Todos los datos están cargados 🎉","Quick filter":"Filtro rápido",TYPE:"TIPO",LINKED:"ENLAZADO","NO TAGS":"SIN ETIQUETAS","HAS LINKS":"TIENE ENLACES","HAS IMAGES":"TIENE IMÁGENES",INCLUDE:"INCLUIR",EXCLUDE:"EXCLUIR",TEXT:"TEXTO",IS:"ES",AND:"Y",OR:"O",LIST:"LISTA",ISNOT:"NO ES",PATH:"RUTA",METADATA:"METADATOS",SELECT:"SELECCIONAR","ADD FILTER TERMS":"AGREGAR TÉRMINOS DE FILTRO",FILTER:"FILTRAR",Filter:"Filtro",TITLE:"TÍTULO","CREATE QUERY":"CREAR CONSULTA","EDIT QUERY":"EDITAR CONSULTA",MATCH:"COINCIDE",TIMES:"VECES","Share Memo Image":"Compartir imagen de Thino","↗Click the button to save":"↗Haz clic en el botón para guardar","Image is generating...":"Generando imagen...","Image is loading...":"Cargando imagen...","Loading...":"Cargando...","😟 Cannot load image, image link maybe broken":"😟 No se puede cargar la imagen, el enlace puede estar roto","Daily Memos":"Thinos diarios","CANCEL EDIT":"CANCELAR EDICIÓN","LINK TO THE":"ENLAZAR A","Mobile Options":"Opciones móviles","Experimental Options":"Opciones experimentales","Don't support web image yet, please input image path in vault":"Aún no se admiten imágenes web, por favor ingresa la ruta de la imagen en la bóveda","Background Image in Dark Theme":"Imagen de fondo en tema oscuro","Background Image in Light Theme":"Imagen de fondo en tema claro",'Set background image in dark theme. Set something like "Daily/one.png"':'Establece la imagen de fondo en tema oscuro. Establece algo como "Daily/one.png"','Set background image in light theme. Set something like "Daily/one.png"':'Establece la imagen de fondo en tema claro. Establece algo como "Daily/one.png"','Set default memo composition, you should use {TIME} as "HH:mm" and {CONTENT} as content. "{TIME} {CONTENT}" by default':'Establece la composición predeterminada de thino, debes usar {TIME} como "HH:mm" y {CONTENT} como contenido. "{TIME} {CONTENT}" por defecto',"Default Memo Composition":"[Obsoleto] Composición predeterminada de Thino","Show Tasks Label":"Mostrar etiqueta de tareas","Show tasks label near the time text. False by default":"Mostrar etiqueta de tareas cerca del texto de hora. Deshabilitado por defecto","Please Open Memos First":"Por favor abre Thino primero",DATE:"FECHA",OBSIDIAN_NLDATES_PLUGIN_NOT_ENABLED:"PLUGIN_NLDATES_DE_OBSIDIAN_NO_HABILITADO",BEFORE:"ANTES",AFTER:"DESPUÉS","Allow Comments On Memos":"Permitir comentarios en Thino","You can comment on memos. False by default":"Puedes comentar en thinos. Deshabilitado por defecto",Import:"Importar","TITLE CANNOT BE NULL!":"¡EL TÍTULO NO PUEDE ESTAR VACÍO!","FILTER CANNOT BE NULL!":"¡EL FILTRO NO PUEDE ESTAR VACÍO!","Comments In Original DailyNotes/Notes":"Comentarios en notas diarias/notas originales","You should install Dataview Plugin ver 0.5.9 or later to use this feature.":"Debes instalar el Plugin Dataview ver 0.5.9 o posterior para usar esta función.","Open Memos Successfully":"Thino abierto exitosamente","Fetch Memos Error":"😭 Error al obtener","Copied to clipboard Successfully":"Copiado al portapapeles exitosamente","Check if you opened Daily Notes Plugin Or Periodic Notes Plugin":"Verifica si abriste el Plugin de notas diarias o el Plugin de notas periódicas","Please finish the last filter setting first":"Por favor termina la última configuración de filtro primero","Close Memos Successfully":"Thino cerrado exitosamente","Insert as Memo":"Insertar como Thino","Insert file as memo content":"Insertar archivo como contenido de thino","Image load failed":"Error al cargar la imagen","Content cannot be empty":"El contenido no puede estar vacío","Unable to create new file.":"No se puede crear nuevo archivo.","Failed to fetch deleted memos: ":"Error al obtener thinos eliminados: ","RESTORE SUCCEED":"RESTAURACIÓN EXITOSA","DELETE SUCCEED":"ELIMINACIÓN EXITOSA","Save Memo button icon":"Icono del botón guardar Thino","The icon shown on the save Memo button in the UI.":"El icono mostrado en el botón guardar Thino en la interfaz.","Fetch Memos From Particular Notes":"Obtener Thinos de notas específicas",'You can set any Dataview Query for memos to fetch it. All memos in those notes will show on list. "#memo" by default':'Puedes establecer cualquier consulta Dataview para thinos para obtenerlos. Todos los thinos en esas notas se mostrarán en la lista. "#memo" por defecto',"Allow Memos to Fetch Memo from Notes":"Permitir a Thino obtener Thino de notas","Use Memos to manage all memos in your notes, not only in daily notes. False by default":"Usar Thino para administrar todos los thinos en tus notas, no solo en notas diarias. Deshabilitado por defecto","Always Show Memo Comments":"Mostrar siempre comentarios de Thino","Always show memo comments on memos. False by default":"Mostrar siempre comentarios de thino en thinos. Deshabilitado por defecto","You didn't set folder for daily notes in both periodic-notes and daily-notes plugins.":"No estableciste carpeta para notas diarias en los plugins de notas periódicas y notas diarias.","Please check your daily note plugin OR periodic notes plugin settings":"Por favor verifica la configuración de tu plugin de notas diarias O plugin de notas periódicas","Use which plugin's default configuration":"Usar la configuración predeterminada de qué plugin","Memos use the plugin's default configuration to fetch memos from daily, 'Daily' by default.":"Thino usa la configuración predeterminada del plugin para obtener thinos de diario, 'Diario' por defecto.",Daily:"Diario","Always Show Leaf Sidebar on PC":"Mostrar siempre barra lateral en PC","Show left sidebar on PC/Tablet even when the leaf width is less than 875px. False by default.":"Mostrar barra lateral izquierda en PC/Tablet incluso cuando el ancho de la hoja es menor a 875px. Deshabilitado por defecto.","You didn't set format for daily notes in both periodic-notes and daily-notes plugins.":"No estableciste formato para notas diarias en los plugins de notas periódicas y notas diarias.","fetch more":"cargar más","Search all settings":"Buscar todos los ajustes",General:"General",Theme:"Tema",Share:"Compartir",Advanced:"Avanzado",Thino:"Thino","Random Review":"Revisión aleatoria","ARCHIVED AT":"ARCHIVADO EL","Failed to get memos from daily notes":"Error al obtener thinos de notas diarias","Failed to delete memo":"Error al eliminar thino","CTRL + ENTER to save":"CTRL + ENTER para guardar","Started from":"Comenzado desde","Custom Background Image":"Imagen de fondo personalizada","Set custom background image.":"Establecer imagen de fondo personalizada.","Custom Memo Footer":"Pie de Thino personalizado","Set custom memo footer.":"Establecer pie de thino personalizado.","Heatmap Color Scheme":"Esquema de color del mapa de calor","Set different color scheme for heatmap.":"Establecer diferente esquema de color para el mapa de calor.","Enable Local Http Server":"Habilitar servidor Http local","Memos Http Server Port":"Puerto del servidor Http de Thino","Set memos http server port to listen. '43999' by default":"Establecer puerto del servidor http de thino para escuchar. '43999' por defecto","Default Editor Mode":"Modo de editor predeterminado","Live-Preview Mode OR Source Mode.":"Modo vista previa en vivo O modo fuente.","Save type for Thino":"Tipo de guardado para Thino",DAILY:"DIARIO",MULTI:"MÚLTIPLE",CANVAS:"LIENZO",ALL:"TODO",FILE:"ARCHIVO",TODO:"POR HACER",DONE:"HECHO",JOURNAL:"DIARIO",OTHER:"OTRO","Failed to create daily note, check if it exists.":"Error al crear nota diaria, verifica si existe.","Failed to create daily note. Please check if you created a folder for daily notes.":"Error al crear nota diaria. Por favor verifica si creaste una carpeta para notas diarias.","After you verify your account, please refresh this page.":"Después de verificar tu cuenta, por favor actualiza esta página.",Verify:"Verificar","Oops! You forget to verify insider account":"¡Ups! Olvidaste verificar la cuenta insider","If you have any questions, please contact us.":"Si tienes alguna pregunta, por favor contáctanos.","Delete Thino Directly":"Eliminar Thino directamente","When delete thino directly, it will not be moved to trash. False by default.":"Al eliminar thino directamente, no se moverá a la papelera. Deshabilitado por defecto.","Enable opening thino globally":"Habilitar apertura global de thino","Enable opening thino globally. False by default.":"Habilitar apertura global de thino. Deshabilitado por defecto.","Key for opening thino globally":"Tecla para abrir thino globalmente","Set key for opening thino globally. CTRL + SHIFT + T by default.":"Establecer tecla para abrir thino globalmente. CTRL + SHIFT + T por defecto.","Key for showing thino globally":"Tecla para mostrar thino globalmente","Set key for showing thino globally. CTRL + SHIFT + E by default.":"Establecer tecla para mostrar thino globalmente. CTRL + SHIFT + E por defecto.","Get activation code":"Obtener código de activación","Input activation code here":"Ingresa el código de activación aquí","Copy Thino id":"Copiar id de Thino","Activate Pro Version":"Activar versión Pro","Please copy Thino id first":"Por favor copia el id de Thino primero",'You can set folder name with file name like "folder/file"':'Puedes establecer nombre de carpeta con nombre de archivo como "carpeta/archivo"','You can set folder name like "folder1/folder2/folder3" to create sub-folder':'Puedes establecer nombre de carpeta como "carpeta1/carpeta2/carpeta3" para crear subcarpeta',"Default save type":"Ubicación de guardado predeterminada",'Set the default save type for thino. "DAILY" by default':'Establece el tipo de guardado predeterminado para thino. "DIARIO" por defecto',"Sync Thino via PKMer":"Sincronizar Thino vía PKMer",Unlink:"Desvincular",Link:"Vincular","Connect to PKMer Sync, you can check it in ":"Conectar a PKMer Sync, puedes verificarlo en ","PKMer Sync":"PKMer Sync","Remove successfully":"Eliminado exitosamente",Deactivate:"Desactivar",Remove:"Eliminar","Confirm?":"¿Confirmar?","Sync Status":"Estado de sincronización","Start or stop sync":"Iniciar o detener sincronización","Stop sync successfully":"Sincronización detenida exitosamente","Start sync successfully":"Sincronización iniciada exitosamente",Stop:"Detener",Start:"Iniciar","Show thino near mouse":"Mostrar thino cerca del mouse","Query not found":"Consulta no encontrada","Send to clipboard successfully":"Enviado al portapapeles exitosamente","Thino - Failed to start HTTP server, please check the port is available.":"Thino - Error al iniciar servidor HTTP, por favor verifica que el puerto esté disponible.","Thino - Started HTTP server on port":"Thino - Servidor HTTP iniciado en el puerto","Thino - Terminated HTTP server":"Thino - Servidor HTTP terminado","File not exist":"Archivo no existe","Thino not found":"Thino no encontrado","File not found for the given thino path, is creating a new file":"Archivo no encontrado para la ruta de thino dada, creando nuevo archivo","Saved sync token successfully":"Token de sincronización guardado exitosamente","Failed to find daily notes folder":"Error al encontrar carpeta de notas diarias","Please install obsidian-hover-editor plugin first":"Por favor instala primero el plugin obsidian-hover-editor","Copied app id successfully":"ID de aplicación copiado exitosamente","Please input token first":"Por favor ingresa el token primero","Please enable sync first":"Por favor habilita la sincronización primero","Init Failed":"Fallo de inicialización","Verify successfully":"Verificación exitosa","Failed to verify":"Error al verificar","Folder not found for the given thino path, is creating a new folder":"Carpeta no encontrada para la ruta de thino dada, creando nueva carpeta","File not found for the given thino path":"Archivo no encontrado para la ruta de thino dada","Failed to read current daily note, check if it exists.":"Error al leer nota diaria actual, verifica si existe.","Failed to save":"Error al guardar","Failed to login, please login again":"Error al iniciar sesión, por favor inicia sesión nuevamente","COPY FAILED":"ERROR AL COPIAR","COPY SUCCEED":"COPIADO EXITOSO","Copy selected text":"Copiar texto seleccionado","Copy thino":"Copiar thino",COPY:"COPIAR","This is a pro feature, please upgrade to pro version to use it.":"Esta es una función pro, por favor actualiza a la versión pro para usarla.","You can get pro version from: ":"Puedes obtener la versión pro desde: ",Save:"Guardar",Cancel:"Cancelar","Thino Daily Target":"Objetivo diario de Thino",Input:"Entrada","#Tag":"#Etiqueta","to create tag":"para crear etiqueta","You have verified your account. Congrats!":"¡Has verificado tu cuenta. ¡Felicitaciones!","Pro features":"Funciones pro","Target Thino Count":"Contador objetivo de Thino",on:"en","Switch waterfall view":"Cambiar a vista cascada","Switch view":"Cambiar vista","Switch list view":"Cambiar a vista lista","Set daily target":"Establecer objetivo diario","Thino Save To: ":"Guardar Thino en: ","Enter fullscreen mode":"Entrar en modo pantalla completa","Exit fullscreen mode":"Salir del modo pantalla completa",words:"palabras",word:"palabra","Return To Home Page":"Volver a la página principal","No thinos to review!":"¡No hay thinos para revisar!","Thinos to review":"Thinos para revisar","Start Review":"Comenzar revisión",Hard:"Difícil",Good:"Bueno",Easy:"Fácil",Again:"De nuevo","Clear all review data":"Borrar todos los datos de revisión","Daily Progress":"Progreso diario","Show stats":"Mostrar estadísticas","Hide stats":"Ocultar estadísticas",Remaining:"Restante","Total Reviews":"Total de revisiones","Today, you have reviewed all your thinos!":"¡Hoy has revisado todos tus thinos!","Daily review limit reached! Come back tomorrow.":"¡Límite de revisión diaria alcanzado! Vuelve mañana.","Open thino in center window":"Abrir thino en ventana central","Open thino in float window":"Abrir thino en ventana flotante","Open thino in right sidebar":"Abrir thino en barra lateral derecha","Open thino in left sidebar":"Abrir thino en barra lateral izquierda","Show thino editor":"Mostrar editor de thino","Toggle minimal mode":"Alternar modo mínimo","Focus on thino editor":"Enfocar en editor de thino","ReSync web thinos to local":"Resincronizar thinos web a local","Sync local thinos to web":"Sincronizar thinos locales a web","Show daily thino":"Mostrar thino diario","Focus on search bar":"Enfocar en barra de búsqueda","Show-thino in popover(Hover editor)":"Mostrar thino en ventana emergente (Editor flotante)","Center window":"Ventana central","Float window":"Ventana flotante","Right sidebar":"Barra lateral derecha","Left sidebar":"Barra lateral izquierda","Save thino type when sync local":"Guardar tipo de thino al sincronizar local","Set the default save thino type when sync local, FILE by default.":"Establecer el tipo de guardado predeterminado de thino al sincronizar local, ARCHIVO por defecto.","Sync service":"Servicio de sincronización","Pro verification status":"Estado de verificación Pro","Live-preview":"Vista previa en vivo",Source:"Fuente","Global copy":"Copia global","Set the folder name":"Establecer el nombre de la carpeta","Set the filename":"Establecer el nombre del archivo","Set the filename for current location file":"Establecer el nombre del archivo para la ubicación actual","Switch calendar type":"Cambiar tipo de calendario",alphabetical:"alfabético",alphabeticalReverse:"alfabético inverso",byCount:"por conteo",byCountReverse:"por conteo inverso","Type here":"Escribe aquí",Today:"Hoy",Yesterday:"Ayer","Last 7 days":"Últimos 7 días","Last 30 days":"Últimos 30 días","Last 90 days":"Últimos 90 días","Last 180 days":"Últimos 180 días","Last 365 days":"Últimos 365 días",Found:"Encontrado","Copy filtered thinos":"Copiar thinos filtrados","Bulk delete":"Eliminación masiva","Bulk archive":"Archivo masivo","Bulk tag operation":"Operación masiva de etiquetas","Bulk restore":"Restauración masiva","If you are disabling the daily note plugin, it would be possible that the thino will not be deleted or patched properly. Please enable the plugin and try again.":"Si estás desactivando el complemento de notas diarias, es posible que el thino no se elimine o actualice correctamente. Por favor, activa el complemento e inténtalo de nuevo.",Preview:"Vista previa","Set and save":"Establecer y guardar","Show day mark in thino list":"Mostrar marca de día en la lista de thinos","Show day mark on the top of daily range thino. False by default.":"Mostrar marca de día en la parte superior del rango diario de thino. Falso por defecto.","Click to expand or fold, Cmd+Click to show all thinos of the day":"Clic para expandir o plegar, Cmd+Clic para mostrar todos los thinos del día","You can buy a license from":"Puedes comprar una licencia desde","No thinos in range":"No hay thinos en el rango",Month:"Mes",Week:"Semana",Day:"Día",Agenda:"Agenda",Tomorrow:"Mañana",Previous:"Anterior",Next:"Siguiente","Search all columns...":"Buscar en todas las columnas...","Basic Info":"Información básica","Additional Info":"Información adicional","Created At":"Creado el",Content:"Contenido","Thino Type":"Tipo de Thino","Source Type":"Tipo de fuente","Row status":"Estado de la fila",Path:"Ruta","Pinned Status":"Estado fijado",Table:"Tabla",Chat:"Chat",Moments:"Momentos",Waterfall:"Cascada",Calendar:"Calendario","Go to page":"Ir a la página",Page:"Página",Show:"Mostrar",rows:"filas","Temp Filter":"Filtro temporal","Open link directly in Thino view":"Abrir enlace directamente en vista Thino","Day mark range":"Rango de marca de día","Set the range of day mark. Day by default.":"Establecer el rango de marca de día. Día por defecto.","Thino is locked":"Thino está bloqueado","Please unlock Thino by input password":"Por favor, desbloquea Thino introduciendo la contraseña","Auto Download Image":"Descarga automática de imagen","Auto download image when save to thino. 'false' by default":"Descargar imagen automáticamente al guardar en thino. 'falso' por defecto","Thino Http IP Type":"Tipo de IP Http de Thino","Set Thino http server ip to listen. 'localhost' by default":"Establecer IP del servidor http de Thino para escuchar. 'localhost' por defecto","Password to lock Thino":"Contraseña para bloquear Thino",Unlock:"Desbloquear",Locked:"Bloqueado","Password is incorrect":"La contraseña es incorrecta",Lock:"Bloquear","Need password to unlock Thino":"Se necesita contraseña para desbloquear Thino","You have not set a password or enable this feature yet":"No has establecido una contraseña o habilitado esta función aún",Password:"Contraseña","Password for Thino":"Contraseña para Thino","Please input your password to change password settings":"Por favor, introduce tu contraseña para cambiar la configuración de contraseña","Please input your password":"Por favor, introduce tu contraseña","Lock thino":"Bloquear thino",date:"fecha",time:"hora",event:"evento","Add tag position":"Agregar posición de etiqueta","Set the position of the tag when adding tag automatically":"Establecer la posición de la etiqueta al agregarla automáticamente","Add tag automatically":"Agregar etiqueta automáticamente","Add tag to the end or beginning of the thino content when creating a thino and filtering tags":"Agregar etiqueta al final o al principio del contenido del thino al crear un thino y filtrar etiquetas","Add tag with new line":"Agregar etiqueta con nueva línea","Add tag with new line when adding tag automatically":"Agregar etiqueta con nueva línea al agregar etiqueta automáticamente","Input to select more tags":"Ingresa para seleccionar más etiquetas","Tag Bulk Edit":"Edición masiva de etiquetas","Tag Bulk Select":"Selección masiva de etiquetas","Exist Tags":"Etiquetas existentes","Selected Tags":"Etiquetas seleccionadas","Click to remove exist tag":"Clic para eliminar etiqueta existente","Click to remove selected tag":"Clic para eliminar etiqueta seleccionada","Select tags":"Seleccionar etiquetas","Input to select exist tag":"Ingresa para seleccionar etiqueta existente",Beginning:"Inicio",End:"Fin","Set the heading for saving thino":"Establecer el encabezado para guardar thino","# Heading":"# Encabezado","Chat view style":"Estilo de vista de chat","Set the style of chat view":"Establecer el estilo de vista de chat","Background image for moments view":"Imagen de fondo para vista de momentos","Set the background image for moments view":"Establecer la imagen de fondo para vista de momentos","Icon for moments/chat view/share image":"Icono para vista de momentos/chat/imagen compartida","Set the icon for moments/chat view/share image":"Establecer el icono para vista de momentos/chat/imagen compartida","Quote for moments view/share image":"Cita para vista de momentos/imagen compartida","Set the quote for moments view/share image":"Establecer la cita para vista de momentos/imagen compartida","Theme for Thino":"Tema para Thino","Set the theme for Thino":"Establecer el tema para Thino","Interface Details":"Detalles de interfaz","Task amount":"Cantidad de tareas","Thino status":"Estado de Thino","Used tags":"Etiquetas usadas","Used days":"Días usados","Most active day":"Día más activo","Most active hour":"Hora más activa","Thino amount":"Cantidad de Thinos","No content to generate.":"No hay contenido para generar.","Image generated successfully.":"Imagen generada exitosamente.","Failed to generate image.":"Error al generar imagen.","Share filtered thinos as image":"Compartir thinos filtrados como imagen","Latest version":"Última versión","Previous version":"Versión anterior","Thino update info":"Información de actualización de Thino","Debug info copied to clipboard":"Información de depuración copiada al portapapeles","Copy debug info":"Copiar información de depuración","Failed to load changelog":"Error al cargar el registro de cambios","View online":"Ver en línea",ChangeLog:"Registro de cambios","Please open thino first":"Por favor, abre thino primero","Insert editor":"Insertar editor","Please set different save locations for multi-file settings in Thino. The diary folder overlaps with the multi-file save location, or there is a risk of it being read repeatedly.":"Por favor, establece diferentes ubicaciones de guardado para la configuración multi-archivo en Thino. La carpeta del diario se superpone con la ubicación de guardado multi-archivo, o hay riesgo de que se lea repetidamente.","Default time prefix for thino in daily notes":"Prefijo de tiempo predeterminado para thino en notas diarias","Set default time prefix for thino in daily notes.":"Establecer prefijo de tiempo predeterminado para thino en notas diarias.","Save image successfully":"Imagen guardada exitosamente","User quote":"Cita de usuario","Set user quote for thino":"Establecer cita de usuario para thino","User icon":"Icono de usuario","Set user icon for thino. You can input http/https link or file path in vault.":"Establecer icono de usuario para thino. Puedes ingresar enlace http/https o ruta de archivo en la bóveda.","User info":"Información de usuario","Copy filtered results":"Copiar resultados filtrados","Share image":"Compartir imagen",Default:"Predeterminado",Gray:"Gris",Grass:"Hierba",Flame:"Llama",Olive:"Oliva",Ice:"Hielo",Magenta:"Magenta","Daily notes":"Notas diarias",Editor:"Editor","Append/prepend text when share to Thino":"Agregar texto al principio/final al compartir en Thino","Append text when share to Thino":"Agregar texto al final al compartir en Thino","Prepend text when share to Thino":"Agregar texto al principio al compartir en Thino","Add newline when append/prepend text":"Agregar nueva línea al agregar texto al principio/final","Input anything here":"Ingresa cualquier cosa aquí",Prepend:"Agregar al principio",Append:"Agregar al final",Both:"Ambos",None:"Ninguno","Hide pinned group":"Ocultar grupo fijado","Hide pinned group in thino list. False by default.":"Ocultar grupo fijado en la lista de thino. Falso por defecto.","Set the heading for the task type of thino, by default the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"Establecer el encabezado para el tipo de tarea de thino, por defecto el contenido de thino grabado se insertará al final del diario; si se proporciona un título, todo el contenido de thino grabado se categorizará uniformemente bajo ese título.","Different insert target for different type":"Diferente objetivo de inserción para diferente tipo","Toggle this to set different insert target for different type of thino, like task or list type of thino":"Activa esto para establecer diferente objetivo de inserción para diferente tipo de thino, como tipo tarea o lista de thino","You can set whole diary or only part of it":"Puedes establecer todo el diario o solo una parte","Set process target":"Establecer objetivo de proceso",Custom:"Personalizado","Whole diary":"Diario completo","Set thino insert place":"Establecer lugar de inserción de thino","Set where to insert thino content":"Establecer dónde insertar contenido de thino","End of the diary":"Final del diario","Custom location":"Ubicación personalizada","Setting guide":"Guía de configuración","Details settings":"Configuraciones detalladas","Start Thino":"Iniciar Thino","About Thino Pro":"Acerca de Thino Pro",Enabled:"Habilitado",Enable:"Habilitar","Daily notes folder":"Carpeta de notas diarias","Set daily notes folder":"Establecer carpeta de notas diarias","Daily note name format":"Formato de nombre de nota diaria","Set daily note name format":"Establecer formato de nombre de nota diaria","Daily note plugin":"Complemento de nota diaria","Enable daily note plugin":"Habilitar complemento de nota diaria",Selected:"Seleccionado",Select:"Seleccionar","A classic theme for Thino with a two-column layout":"Un tema clásico para Thino con diseño de dos columnas",Classic:"Clásico","A modern theme for Thino with a three-column layout and some unique features.":"Un tema moderno para Thino con diseño de tres columnas y algunas características únicas.",Modern:"Moderno","Go and enjoy Thino":"Ve y disfruta Thino","Congrats! All settings done":"¡Felicitaciones! Todas las configuraciones completadas","Adjust settings that influence your user experience with Thino.":"Ajusta las configuraciones que influyen en tu experiencia de usuario con Thino.","Set preferences for using Thino":"Establecer preferencias para usar Thino","If you are using the Thino basic version, enabling the daily note plugin is required. Configure its settings to work effectively with it.":"Si estás usando la versión básica de Thino, se requiere habilitar el complemento de nota diaria. Configura sus ajustes para trabajar efectivamente con él.","Go with daily note plugin":"Ir con complemento de nota diaria","Choose a theme for Thino.":"Elige un tema para Thino.","Set theme for Thino":"Establecer tema para Thino","Set up your user info for Thino.":"Configura tu información de usuario para Thino.","Get started with Thino":"Comenzar con Thino","Skip and start Thino":"Saltar e iniciar Thino","Next step":"Siguiente paso","Back to previous step":"Volver al paso anterior","Click to enable =>":"Clic para habilitar =>","This is Thino's sidebar. Navigate to different path or select query filter.":"Esta es la barra lateral de Thino. Navega a diferentes rutas o selecciona filtro de consulta.","Click here and go to settings page.":"Haz clic aquí y ve a la página de configuración.","Click here and go to different path.":"Haz clic aquí y ve a una ruta diferente.","Select or create query filter here.":"Selecciona o crea filtro de consulta aquí.","See the status of Thinos here.":"Ve el estado de los Thinos aquí.","Search your thino quickly here.":"Busca tu thino rápidamente aquí.","Edit or create your thino here.":"Edita o crea tu thino aquí.","See your thinos here.":"Ve tus thinos aquí.","See your time status of thinos here.":"Ve tu estado de tiempo de thinos aquí.","See your tags here. Tags will be shown when thino contains tags.":"Ve tus etiquetas aquí. Las etiquetas se mostrarán cuando thino contenga etiquetas.",Done:"Hecho","Thino is ready to use. ":"Thino está listo para usar. ","You can start using Thino now. If you want to know more about Thino Pro, click the button below.":"Puedes comenzar a usar Thino ahora. Si quieres saber más sobre Thino Pro, haz clic en el botón de abajo.","Default time prefix":"Prefijo de tiempo predeterminado","Append Text Action":"Acción de agregar texto al final","Prepend Text Action":"Acción de agregar texto al principio",Preset:"Preestablecido","Select Tags":"Seleccionar etiquetas","It is not available on small view":"No está disponible en vista pequeña","Append text":"Agregar texto al final","Prepend text":"Agregar texto al principio","Your daily note folder is not set correctly, please check your settings":"Tu carpeta de notas diarias no está configurada correctamente, por favor revisa tu configuración","Default sharing style":"Estilo de compartir predeterminado","Set the default style for sharing thino, 'Modern' by default.":'Establecer el estilo predeterminado para compartir thino, "Moderno" por defecto.',Clean:"Limpio",Minimal:"Mínimo",Gradient:"Gradiente","Thino share":"Compartir Thino","Copy to clipboard failed":"Error al copiar al portapapeles","Copy to clipboard successfully":"Copiado al portapapeles exitosamente","Your content has been copied to clipboard, and inserted into the editor. Please try it again":"Tu contenido ha sido copiado al portapapeles e insertado en el editor. Por favor inténtalo de nuevo","Share thino":"Compartir thino","Set file name after create thino":"Establecer nombre de archivo después de crear thino","You can set file name after create thino. A input box will show when you create thino.":"Puedes establecer el nombre del archivo después de crear thino. Se mostrará una caja de entrada cuando crees thino.",SPLIT:"DIVIDIR","Split by Heading 1":"Dividir por Encabezado 1","Split by Heading 2":"Dividir por Encabezado 2","Split by Heading 3":"Dividir por Encabezado 3","Insert task":"Insertar tarea","All settings have been reset to default.":"Todas las configuraciones han sido restablecidas a los valores predeterminados.","Reset all Thino settings":"Restablecer todas las configuraciones de Thino","Reset settings":"Restablecer configuraciones","Reset Thino settings to default settings.":"Restablecer configuraciones de Thino a valores predeterminados.","Task Management":"Gestión de tareas","Append completed date when task done in thino":"Agregar fecha de completado cuando la tarea se complete en thino","Append completed date when task done in thino. False by default":"Agregar fecha de completado cuando la tarea se complete en thino. Falso por defecto","Set tag for single file that Thino indexes":"Establecer etiqueta para archivo único que Thino indexa","When you set a tag here, Thino will index this file contains this tag and show it in the list. Don't need to add `#`.":"Cuando estableces una etiqueta aquí, Thino indexará este archivo que contiene esta etiqueta y lo mostrará en la lista. No necesitas agregar `#`.","Set tag for file type file":"Establecer etiqueta para archivo tipo archivo","Set tag for multi type file":"Establecer etiqueta para archivo multi tipo","Please input the tag":"Por favor ingresa la etiqueta","Merge thinos in to thino share image":"Fusionar thinos en imagen compartida de thino","Custom height for Thino content":"Altura personalizada para contenido de Thino","Set custom height for Thino content. Like 200px or 20rem":"Establecer altura personalizada para contenido de Thino. Como 200px o 20rem","Input height":"Ingresar altura","Submit issue":"Enviar problema","Current version":"Versión actual","Bug report":"Reporte de error","Click the button to copy debug info and open the issue page":"Haz clic en el botón para copiar información de depuración y abrir la página de problemas","Copy and go":"Copiar e ir","Debug info copied":"Información de depuración copiada","Feature request":"Solicitud de función","Submit your feature request to the issue page":"Envía tu solicitud de función a la página de problemas",Go:"Ir","Toggle query list visibility":"Alternar visibilidad de lista de consultas","Toggle tags visibility":"Alternar visibilidad de etiquetas","Toggle sidebar visibility":"Alternar visibilidad de barra lateral",Collapse:"Colapsar",Expand:"Expandir","Max height for collapse":"Altura máxima para colapsar","The max height for thino collapse, when set 0, thino would not collapse. 0 by default. (This is not lines count, it is height in px.)":"La altura máxima para colapsar thino, cuando se establece en 0, thino no colapsará. 0 por defecto. (Esto no es conteo de líneas, es altura en px.)","Render content":"Renderizar contenido","Optimize for Callout":"Optimizar para Callout","Won't render content contains more than 3 callouts automatically. True by default":"No renderizará automáticamente contenido que contenga más de 3 callouts. Verdadero por defecto","The value should be greater than":"El valor debe ser mayor que","Append Text":"Agregar texto al final","Prepend Text":"Agregar texto al principio","Thino height when collapsed":"Altura de Thino cuando está colapsado","The height for thino when it is collapsed, when set 0, thino would not collapse . 100 by default. (This is not lines count, it is height in px.)":"La altura para thino cuando está colapsado, cuando se establece en 0, thino no colapsará. 100 por defecto. (Esto no es conteo de líneas, es altura en px.)","This option will allow you use other views when leaf width is not enough. False by default.":"Esta opción te permitirá usar otras vistas cuando el ancho de la hoja no sea suficiente. Falso por defecto.","Can select other views when leaf width is not enough":"Puede seleccionar otras vistas cuando el ancho de la hoja no es suficiente","TRASH BOX":"PAPELERA","Wait templater to finish parse before insert thino":"Esperar a que templater termine de analizar antes de insertar thino","This option will allow you to wait for templater to finish parse before insert thino, which may casue you need to confirm twice between insert thino. False by default.":"Esta opción te permitirá esperar a que templater termine de analizar antes de insertar thino, lo que puede hacer que necesites confirmar dos veces entre insertar thino. Falso por defecto.","Get thino capture extension":"Obtener extensión de captura de thino","You can capture idea/text from chrome now.":"Ahora puedes capturar idea/texto desde chrome.","Open File":"Abrir archivo","Exported CSV file":"Archivo CSV exportado","Updated At":"Actualizado el","Export to CSV":"Exportar a CSV","Quick add button on mobile navbar":"Botón de agregar rápido en barra de navegación móvil","Always show status text":"Siempre mostrar texto de estado","Support filter by metadata from file":"Soportar filtro por metadatos desde archivo","When enable this, you can filter via metadata from file, like tags in file. But thinos from canvas is not supported. False by default.":"Cuando habilites esto, podrás filtrar a través de metadatos desde archivo, como etiquetas en archivo. Pero los thinos desde canvas no están soportados. Falso por defecto.","Show source near timestamp in thino":"Mostrar fuente cerca de marca de tiempo en thino","When enable this, you can see the source near timestamp in thino. You can set title in metadata to overwrite this. False by default.":"Cuando habilites esto, podrás ver la fuente cerca de la marca de tiempo en thino. Puedes establecer título en metadatos para sobrescribir esto. Falso por defecto.","Show Update Message":"Mostrar mensaje de actualización","Show update message when Thino is updated. True by default":"Mostrar mensaje de actualización cuando Thino se actualiza. Verdadero por defecto","Sync manually":"Sincronizar manualmente","Show all scrollbars":"Mostrar todas las barras de desplazamiento","TIME RANGE":"RANGO DE TIEMPO",WITHIN:"DENTRO DE","7 days":"7 días","14 days":"14 días","30 days":"30 días","3 months":"3 meses","6 months":"6 meses","1 year":"1 año","This week":"Esta semana","Last week":"Semana pasada","This month":"Este mes","Last month":"Mes pasado","This year":"Este año","Last year":"Año pasado","No history":"Sin historial","Today Remaining":"Restante hoy","Today Total":"Total hoy","Historical Statistics":"Estadísticas históricas",byTime:"Por tiempo",byTimeReverse:"Por tiempo inverso",Stat:"Estadística",Statistics:"Estadísticas","Daily Thino Count":"Conteo diario de Thino",Total:"Total",thinos:"thinos","Thino Types":"Tipos de Thino","Distribution of thino types":"Distribución de tipos de thino","Thino Status":"Estado de Thino","Distribution of thino status":"Distribución de estado de thino","Popular Tags":"Etiquetas populares","Top 10 most used tags":"Top 10 etiquetas más usadas","Thino Count":"Conteo de Thino","Hourly distribution":"Distribución por hora","Current month":"Mes actual","Monthly distribution":"Distribución mensual","30 Days":"Últimos 30 días",Year:"Año","Time Distribution":"Distribución de tiempo","When do you write thinos":"Cuándo escribes thinos","Content Length":"Longitud de contenido","Distribution of thino lengths":"Distribución de longitudes de thino","Daily Thinos":"Thinos diarios","Show Time Distribution":"Mostrar distribución de tiempo","Hide date picker":"Ocultar selector de fecha","Show date picker":"Mostrar selector de fecha","Clear filter":"Limpiar filtro","Copy link":"Copiar enlace","Copy embed link":"Copiar enlace incrustado","Ctrl/Cmd + Enter to save thino":"Ctrl/Cmd + Enter para guardar thino","Fixed strings for thinos":"Cadenas fijas para thinos","Use fixed strings for thinos":"Usar cadenas fijas para thinos","Enable to add fixed strings at the beginning or end of thinos.":"Habilitar para agregar cadenas fijas al principio o final de los thinos.","Fixed prefix for thinos":"Prefijo fijo para thinos","Add this string at the beginning of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"Agregar esta cadena al principio de cada thino. Admite marcadores como {{TIME|YYYYMMDDHHmmss}}.","Fixed suffix for thinos":"Sufijo fijo para thinos","Add this string at the end of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"Agregar esta cadena al final de cada thino. Admite marcadores como {{TIME|YYYYMMDDHHmmss}}.","Word count exceeded":"Conteo de palabras excedido","Word count feature":"Función de conteo de palabras","Enable real-time word count display in the editor":"Habilitar visualización de conteo de palabras en tiempo real en el editor","Maximum word count":"Conteo máximo de palabras","Set a maximum word count for thino. Editor will display a warning when exceeded. Set to 0 for unlimited.":"Establecer un conteo máximo de palabras para thino. El editor mostrará una advertencia cuando se exceda. Establecer en 0 para ilimitado.","No linked thinos found":"No se encontraron thinos vinculados","Reference links group":"Grupo de enlaces de referencia","Enable reference links group in thino.":"Habilitar grupo de enlaces de referencia en thino.","No reference links found":"No se encontraron enlaces de referencia","Outgoing Links":"Enlaces salientes","Incoming Links":"Enlaces entrantes","Error fetching reference links":"Error al obtener enlaces de referencia","Double click behavior":"Comportamiento de doble clic","Set the behavior when double click on a thino.":"Establecer el comportamiento al hacer doble clic en un thino.","Open thino":"Abrir thino","Edit thino":"Editar thino","Go to source":"Ir a la fuente","Do nothing":"No hacer nada","Use default header in mobile view":"Usar encabezado predeterminado en vista móvil","Use default header in mobile view of thino rather than custom header.":"Usar encabezado predeterminado en vista móvil de thino en lugar de encabezado personalizado."},J$={welcome:"Bienvenue dans Mémo !",ribbonIconTitle:"Mémos",months:["Janvier","Février","Mars","Avril","Mai","Juin","Juillet","Aout","Septembre","Octobre","Novembre","Décembre"],monthsShort:["Jan.","Feb.","Mar.","Apr.","May","June","July","Aug.","Sept.","Oct.","Nov.","Dec."],weekDays:["Dimanche","Lundi","Mardi","Mercredi","Jeudi","Vendredi","Samedi"],weekDaysShort:["Dim","Lun","Mar","Mer","Jeu","Ven","Sam"],to:"à",year:null,month:null,"Basic Options":"Options basique","User name":"Username","Set your user name here. 'Memos 😏' By default":"Définissez votre username ici. Défaut : 'Memo 😏'","Insert after heading":"Insérer après le titre","If left blank, the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"Vous devez définir le même titre en-dessous si vous voulez insérer et traiter des mémos sous le même titre.","Allows admonitions to be created using ":"Permet de créer des admonitions en utilisant","Process Memos below":"Insérer Mémo sous","If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.":"Seulement les entrée sous cette section/phrase dans vos notes seront considérés. S'il n'existe pas, aucune notes ne sera traité pour ce fichier.","Save Memo button label":"Titre du bouton de sauvegarde","The text shown on the save Memo button in the UI. 'NOTEIT' by default.":"Le texte affiché sur le bouton de sauvegarde dans l'UI. Défaut : 'NOTEIT'","Focus on editor when open memos":"Focus sur l'éditeur lors de l'ouverture du mémo.","Focus on editor when open memos. Focus by default.":"Focus sur l'éditeur lors de l'ouverture du mémo. Focus par défaut.","Open daily memos with open memos":"Ouvrir les mémos quotidiens quand mémo est ouvert.","Open daily memos with open memos. Open by default.":"Ouvrir les mémos quotidiens quand mémo est ouvert.","Open Memos when obsidian opens":"Ouvrir Mémo quand Obsidian est ouvert.","When enable this, Memos will open when Obsidian opens. False by default.":"Quand activé, Memo sera ouvert quand Obsidian à l'ouverture d'Obsidian. Désactivé par défaut.","Hide done tasks in Memo list":"Masquer les tâches accomplies dans la liste des mémos.","Hide all done tasks in Memo list. Show done tasks by default.":"Masquer les tâches accomplies dans les mémos. Affiche les tâches accomplies par défaut.","Advanced Options":"Options avancées","UI language for date":"Langue de l'UI pour la date","Translates the date UI language. Only 'en' and 'zh' are available.":"Traduit la langue des dates dans l'UI. Seuls 'en', 'fr' et 'zh' sont disponibles. ","Default prefix":"Préfix par défaut.","Set the default prefix when create memo, 'List' by default.":"Définit le préfix par défaut lors de la création d'un mémo. Défault : 'Liste'","Default insert date format":"Format de la date insérée par défaut.","Default editor position on mobile":"Position par défaut de l'éditeur sur mobile.","Set the default date format when insert date by @, 'Tasks' by default.":"Définit le format de la date par défaut lors de l'insertion de la date par @. Défaut : 'Tâches'.","Set the default editor position on Mobile, 'Top' by default.":"Position par défaut de l'éditeur sur le mobile. Défaut : 'Haut'.","Use button to show editor on mobile":"Utilisation du bouton pour afficher l'éditeur sur le mobile.","Show Time When Copy Results":"Aficher l'heure quand les résultats sont copiés","Set a float button to call editor on mobile. Only when editor located at the bottom works.":"Place un bouton flottant pour appeler l'éditeur sur mobile. Fonctionne uniquement quand l'éditeur est placé en bas.","Show time when you copy results, like 12:00. Copy time by default.":"Affiche l'heure quand les résultats sont copiés, comme '12:00'. Copie l'heure par défaut","Show Date When Copy Results":"Affiche la date quand les résultats sont copiés","Show date when you copy results, like [[2022-01-01]]. Copy date by default.":"Affiche la date quand les résultats sont copiés, comme [[2022-01-01]]. Par défaut, copie la date.","Add Blank Line Between Different Date":"Ajoute une ligne entre les différentes dates.","Add blank line when copy result with date. No blank line by default.":"Ajoute une ligne lors de la copie du résultat avec la date. Pas de ligne par défaut.","Share Options":"Options de partage","Share Memos Image Footer Start":"Début du pied de page — Partage de mémo de mémos","Set anything you want here, use {ThinoNum} to display Number of thino, {UsedDay} for days. '{ThinoNum} Thino {UsedDay} Days' By default":"Définissez ce que vous voulez ici, utilisez {ThinoNum} pour afficher le nombre de thino, {UsedDay} pour les jours. Par défaut : '{ThinoNum} Thino {UsedDay} Days.","Share Memos Image Footer End":"Fin du pied de page — Partage de mémo","Set anything you want here, use {UserName} as your username. '✍️ By {UserName}' By default":"Définissez ce que vous voulez ici. Utilisez {UserName} comme username. Par défaut : '✍️ By {UserName}'","Save Shared Image To Folder For Mobile":"Sauvegarde des images partagés dans un dossier sur mobile.","Save image to folder for mobile. False by Default":"Sauvegarder les images dans un dossier sur mobile. Désactivé par défaut.","Say Thank You":"Dites Merci",Donate:"Faire un don","If you like this plugin, consider donating to support continued development:":"Si vous aimez ce plugin, envisagez de faire un don pour soutenir le développement continu :","File Name of Recycle Bin":"Nom de la corbeille","Set the filename for recycle bin. 'delete' By default":"Définition du nom de la poubelle. Défaut : 'Delete'","Set the filename for query file. 'query' By default":"Définit le nom de fichier pour les requête. Défaut : 'Query'","Use Tags In Vault":"Utiliser des tags dans le Coffre","Use tags in vault rather than only in Memos. False by default.":"Utiliser des tags du coffre plutôt que ceux que seulement dans Mémo. Désactivé par défaut.","Ready to convert image into background":"Prêt pour convertir des image en arrière-plan.",List:"Liste",Task:"Tâche",Top:"Haut",Bottom:"Bas",TAG:"TAG",DAY:"JOUR",QUERY:"RECHERCHE",EDIT:"EDITER",PIN:"PIN",UNPIN:"ÉPINGLER",DELETE:"DESÉPINGLER","CONFIRM!":"CONFIRMER !","CREATE FILTER":"CRÉER FILTRE",Settings:"Paramètres","Recycle bin":"Corbeille","About Me":"À propos de moi","Fetching data...":"Récupération des données...","Here is No Memos.":"Il n'y a pas de Memos.","Frequently Used Tags":"Tags fréquemment utilisés","What do you think now...":"Que pensez-vous maintenant...",READ:"LU",MARK:"MARQUER",SHARE:"PARTAGER",SOURCE:"SOURCE",RESTORE:"RESTAURER","DELETE AT":"SUPPRIMER","Noooop!":"Noooop!","All Data is Loaded 🎉":"Toutes les données sont chargées 🎉","Quick filter":"Filtre rapide",TYPE:"TYPE",LINKED:"LIEN","NO TAGS":"PAS DE TAGS","HAS LINKS":"A DES LIENS","HAS IMAGES":"A DES IMAGES",INCLUDE:"INCLUS",EXCLUDE:"EXCLUS",TEXT:"TEXTE",IS:"EST",ISNOT:"N'EST PAS",SELECT:"SELECTION","ADD FILTER TERMS":"AJOUTER DES TERMES FILTRÉ",FILTER:"FILTRE",TITLE:"TITRE","CREATE QUERY":"CRÉER UNE RECHERCHE","EDIT QUERY":"ÉDITER UNE RECHERCHE",MATCH:"MATCH",TIMES:"HEURE","Share Memo Image":"Partager un mémo image","↗Click the button to save":"↗Clique pour sauvegarder","Image is generating...":"Génération de l'image...","Image is loading...":"Image en chargement...","Loading...":"Chargement...","😟 Cannot load image, image link maybe broken":"😟 Impossible de charger l'image, le lien peut être brisé","Daily Memos":"Mémo quotidien","CANCEL EDIT":"ANNULER L'ÉDITION","LINK TO THE":"LIENS À","Mobile Options":"Options mobile","Don't support web image yet, please input image path in vault":"Ne supporte pas les images webs. Merci d'insérer le chemin de l'image depuis le coffre.","Background Image in Dark Theme":"Image de fond en thème sombre","Background Image in Light Theme":"Image de fond en thème clair",'Set background image in dark theme. Set something like "Daily/one.png"':"Définir l'image de fond en thème sombre. Définir 'Daily/one.png' par exemple.",'Set background image in light theme. Set something like "Daily/one.png"':"Définir l'image de fond en thème clair. Définir 'Daily/one.png' par exemple.",'Set default memo composition, you should use {TIME} as "HH:mm" and {CONTENT} as content. "{TIME} {CONTENT}" by default':'Définir la composition par défaut du mémo, vous devez utiliser {TIME} comme "HH:mm" et {CONTENT} comme contenu. "{TIME} {CONTENT}" par défaut',"Default Memo Composition":"Composition par défaut du mémo","Show Tasks Label":"Afficher les étiquettes des tâches","Show tasks label near the time text. False by default":"Afficher les étiquettes des tâches à côté du texte horaire. Désactivé par défaut.","Please Open Memos First":"Merci d'ouvrir les mémos en premier"},Q$={},eq={},tq={},nq={},rq={},oq={},iq={},aq={},sq={welcome:"Bem-vindo ao Thino!",ribbonIconTitle:"Thino",months:["Janeiro","Fevereiro","Março","Abril","Maio","Junho","Julho","Agosto","Setembro","Outubro","Novembro","Dezembro"],monthsShort:["Jan.","Fev.","Mar.","Abr.","Maio","Jun.","Jul.","Ago.","Set.","Out.","Nov.","Dez."],weekDays:["Domingo","Segunda","Terça","Quarta","Quinta","Sexta","Sábado"],weekDaysShort:["Dom","Seg","Ter","Qua","Qui","Sex","Sáb"],to:"para",year:null,month:null,"Basic Options":"Opções Básicas","User name":"Nome de Usuário","Set your user name here. 'Memos 😏' By default":"Defina o nome de usuário. Padrão: 'Thino 😏'.","Insert after heading":"Inserir após o cabeçalho","If left blank, the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"Deve definir o mesmo cabeçalho na configuração posterior se pretende inserir e processar memorandos abaixo do cabeçalho aqui definido.","Allows admonitions to be created using ":"Permitir que Admonitions sejam criadas usando ","Process Memos below":"Processar Memorandos abaixo do Cabeçalho","If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.":"Somente as entradas abaixo deste cabeçalho serão processadas nas suas notas. Se não configurar esta funcionalidade, nenhuma nota será processada para o ficheiro respetivo.","Save Memo button label":"Legenda do Botão de Guardar Memorandos","The text shown on the save Memo button in the UI. 'NOTEIT' by default.":'Define o texto apresentado na UI do botão guardar memorandos. Padrão: "NOTEIT".',"Focus on editor when open memos":"Focar no Editor ao iniciar o Thino","Focus on Editor when open memos. Focus by default.":'Focar no editor ao iniciar o Thino. Padrão: "Focar".',"Open daily memos with open memos":"Abrir memorandos diários ao iniciar o Thino","Open daily memos with open memos. Open by default.":'Abrir memorandos diários ao iniciar o Thino. Padrão: "Abrir".',"Open Memos when obsidian opens":"Abrir Thino quando o Obsidian inicia","When enable this, Memos will open when Obsidian opens. False by default.":'Quando esta opção está activa, o Memos abrirá quando o Obsidian inicia. Padrão: "Falso".',"Hide done tasks in Memo list":"Ocultar tarefas concluídas na lista de memorandos","Hide all done tasks in Memo list. Show done tasks by default.":'Ocultar todas as tarefas concluídas na lista de memorandos. Padrão: "Mostrar tarefas concluídas".',"Advanced Options":"Opções Avançadas","UI language for date":"Idioma na UI da Data ","Translates the date UI language. Only 'en' and 'zh' are available.":"Define o idioma na UI da Data. De momento, apenas 'en', 'fr', 'pt' e 'zh' estão disponíveis.","Default prefix when save thino":"Prefixo Padrão","Set the default prefix when create memo, 'List' by default.":"Define o prefixo padrão quando um memorando é criado. Padrão: 'Lista'.","Default insert date format":"Formato Padrão para Inserção de Data","Set the default date format when insert date by @, 'Tasks' by default.":"Define o formato de Data padrão ao inserir a data usando '@'. Padrão: 'Tarefas'.","Default editor position on mobile":"Posição Padrão do Editor de Memorandos na Versão Móvel","Set the default editor position on Mobile, 'Top' by default.":"Define a posição padrão do editor de memorandos na versão móvel. Padrão: 'Topo'.","Use button to show editor on mobile":"Usar Botão para Mostrar o Editor na Versão Móvel","Set a float button to call editor on mobile. Only when editor located at the bottom works.":"Define um botão flutuante para abrir o editor na versão móvel. Opção disponível somente quando a posição do editor está definida para 'Fundo'.","Show Time When Copy Results":"Mostrar a Hora ao Copiar os Resultados","Show time when you copy results, like 12:00. Copy time by default.":"Mostrar a Hora, no formato '12:00', ao copiar os resultados. Padrão: 'Copiar a hora'.","Show Date When Copy Results":"Mostrar a Data ao Copiar os Resultados","Show date when you copy results, like [[2022-01-01]]. Copy date by default.":'Mostrar a Data, no formato [[2022-01-01]], ao copiar os resultados. Padrão: "Copiar a hora".',"Add Blank Line Between Different Date":"Adicionar Linha em Branco entre Datas Diferentes.","Add blank line when copy result with date. No blank line by default.":'Adicionar linha em branco ao copiar resultados com Data. Padrão: "Não adicionar linha."',"Share Options":"Opções de Partilha","Share Memos Image Footer Start":"Partilhar a Imagem de um memorando - Início do Rodapé","Set anything you want here, use {ThinoNum} to display Number of thino, {UsedDay} for days. '{ThinoNum} Thino {UsedDay} Days' By default":"Defina como preferir, use {ThinoNum} para mostrar o número de thinorandos e use {UsedDay} para dias. 'Padrão: {ThinoNum} Thinorandos {UsedDay} Dias'.","Share Memos Image Footer End":"Partilhar a Imagem de um memorando - Fim do Rodapé","Set anything you want here, use {UserName} as your username. '✍️ By {UserName}' By default":"Defina como preferir, use {UserName} como o seu nome de usuário. Padrão: '✍️ Por {UserName}'.","Save Shared Image To Folder For Mobile":"Guardar a Imagem Partilhada para Pasta na Versão Móvel","Save image to folder for mobile. False by Default":'Guardar a imagem partilhada para pasta na versão móvel. Padrão: "Falso".',"Say Thank You":"Agradeça",Donate:"Doar","If you like this plugin, consider donating to support continued development:":"Se gosta deste plugin, considere doar para apoiar o seu desenvolvimento contínuo:","File Name of Recycle Bin":"Nome da Reciclagem","Set the filename for recycle bin. 'delete' By default":"Define o nome do ficheiro para a Reciclagem. Padrão: 'delete'.","File Name of Query File":"Nome do Ficheiro de Query","Set the filename for query file. 'query' By default":"Define o nome do ficheiro de Query. Padrão: 'Query'.","Use Tags In Vault":"Usar Tags no Vault","Use tags in vault rather than only in Memos. False by default.":'Usar as Tags do Vault e não somente dos memorandos. Padrão: "Falso".',"Ready to convert image into background":"Pronto para converter imagem em fundo",List:"Lista",Task:"Tarefa",Top:"Topo",Bottom:"Fundo",TAG:"TAG",DAY:"DIA",QUERY:"QUERY",EDIT:"EDITAR",PIN:"FIXAR",UNPIN:"DESAFIXAR",DELETE:"ELIMINAR","CONFIRM!":"CONFIRMAR!","CREATE FILTER":"CRIAR FILTRO",Settings:"Definições","Recycle bin":"Reciclagem","About Me":"Acerca de mim","Fetching data...":"A obter dados...","Here is No Memos.":"Não existem Thino.","Frequently Used Tags":"Tags Usadas Frequentemente","What do you think now...":"Em que está a pensar...",READ:"LER",MARK:"ASSINALAR",SHARE:"PARTILHAR",SOURCE:"ORIGEM",RESTORE:"RESTAURAR","DELETE AT":"ELIMINADO EM","Noooop!":"Noooop!","All Data is Loaded 🎉":"Todos os Dados foram Carregados 🎉","Quick filter":"Filtro rápido",TYPE:"TIPO",LINKED:"LINKED","NO TAGS":"SEM TAGS","HAS LINKS":"TEM LINKS","HAS IMAGES":"TEM IMAGENS",INCLUDE:"INCLUIR",EXCLUDE:"EXCLUIR",TEXT:"TEXTO",IS:"É",ISNOT:"NÃO É",SELECT:"SELECCIONAR","ADD FILTER TERMS":"ADICIONAR TERMOS DE FILTRAGEM",FILTER:"FILTRAR",TITLE:"TÍTULO","CREATE QUERY":"CRIAR QUERY","EDIT QUERY":"EDITAR QUERY",MATCH:"IGUALA",TIMES:"VEZES","Share Memo Image":"Partilhar Imagem de Memo","↗Click the button to save":"↗Clique no botão para guardar","Image is generating...":"A gerar Imagem..","Image is loading...":"A carregar Imagem...","Loading...":"Carregando...","😟 Cannot load image, image link maybe broken":"😟 Não é possível carregar a imagem, o link da imagem pode estar incorrecto","Daily Memos":"Thino Diários","CANCEL EDIT":"CANCELAR EDIÇÃO","LINK TO THE":"LINK PARA O","Mobile Options":"Opções Móveis","Don't support web image yet, please input image path in vault":"Ainda não existe suporte para imagens de web. Por favor, insira o link para uma imagem do vault","Experimental Options":"Opções Experimentais","Background Image in Dark Theme":"Imagem de Fundo no Tema Escuro","Background Image in Light Theme":"Imagem de Fundo no Tema Claro",'Set background image in dark theme. Set something like "Daily/one.png"':'Defina a imagem de fundo para o tema escuro. Defina da seguinte forma: "Daily/one.png".','Set background image in light theme. Set something like "Daily/one.png"':'Defina a imagem de fundo para o tema claro. Defina da seguinte forma: "Daily/one.png".','Set default memo composition, you should use {TIME} as "HH:mm" and {CONTENT} as content. "{TIME} {CONTENT}" by default':'Defina a composição padrão do memorando, deve usar {TIME} como "HH:mm" e {CONTENT} como conteúdo. Padrão: "{TIME} {CONTENT}".',"Default Memo Composition":"Composição Padrão de um Memorando","Show Tasks Label":"Mostrar Etiquetas de Tarefas","Show tasks label near the time text. False by default":'Mostrar etiquetas de tarefas próximas do texto de tempo. Padrão: "Falso".',"Please Open Memos First":"Por favor, abra o Thino primeiro",DATE:"DATA",OBSIDIAN_NLDATES_PLUGIN_NOT_ENABLED:"OBSIDIAN_NLDATES_PLUGIN_NOT_ENABLED",BEFORE:"ANTES",AFTER:"DEPOIS","Allow Comments On Memos":"Permitir Comentários nos Memorandos","You can comment on memos. False by default":'Permite que comente os memorandos. Padrão: "Falso".',Import:"Importar","TITLE CANNOT BE NULL!":"O TÍTULO NÃO PODE SER NULO!","FILTER CANNOT BE NULL!":"O FILTRO NÃO PODE SER NULO!","Comments In Original DailyNotes/Notes":"Comentários nas Notas/Notas Diárias Originais","You should install Dataview Plug-in ver 0.5.9 or later to use this feature.":"Deve instalar a versão 0.5.9 ou posterior do plugin Dataview para usar esta funcionalidade.","Open Memos Successfully":"Thino Iniciado com Sucesso","Fetch Memos Error":"😭 Erro de Fetch","Copied to clipboard Successfully":"Copiado para a área de transferência com sucesso","Check if you opened Daily Notes Plugin Or Periodic Notes Plugin":"Verifique se abriu o plugin de Notas Diárias ou de Notas Periódicas","Please finish the last filter setting first":"Por favor, termine primeiro a configuração do último filtro","Close Memos Successfully":"Thino Fechado com Sucesso","Insert as Memo":"Inserir como um Memorando","Insert file as memo content":"Inserir ficheiro como conteúdo de um memorando","Image load failed":"Falha no carregamento da imagem","Content cannot be empty":"O Conteúdo não pode estar vazio","Unable to create new file.":"Não foi possível criar um novo ficheiro.","Failed to fetch deleted memos: ":"Falha no fetch dos memorandos removidos: ","RESTORE SUCCEED":"RESTAURO BEM SUCEDIDO","Save Memo button icon":"Ícone do Botão para Guardar Memorandos","The icon shown on the save Memo button in the UI.":"O ícone exibido na UI do botão para guardar memorandos.","Fetch Memos From Particular Notes":"Obter Memorandos de Notas Específicas",'You can set any Dataview Query for memos to fetch it. All memos in those notes will show on list. "#memo" by default':'Pode definir qualquer Query de Dataview para o Memos procurar. Todos os memorandos nessas notas serão mostrados na lista. Padrão: "#memo".',"Allow Memos to Fetch Memo from Notes":"Permitir que o Thino Obtenha memorandos das Notas","Use Memos to manage all memos in your notes, not only in daily notes. False by default":'Use o Memos para gerir todos os memorandos nas suas notas e não apenas nas notas diárias. Padrão: "Falso".',"Always Show Memo Comments":"Mostrar Comentários dos Memorandos","Always show memo comments on memos. False by default":'Mostrar sempre os comentários dos memorandos. Padrão: "Falso".',"You didn't set folder for daily notes in both periodic-notes and daily-notes plugins.":"Não definiu a pasta para as notas diárias, quer no plugin the Notas Periódicas ou de Notas Diárias.","Please check your daily note plugin OR periodic notes plugin settings":"Por favor, verifique as configurações dos plugins de Notas Diárias OU de Notas Periódicas","Use Which Plugin's Default Configuration":"Usar a Configuração Padrão do Plugin","Memos use the plugin's default configuration to fetch memos from daily, 'Daily' by default.":"O Memos usa a configuração padrão do plugin seleccionado para obter memorandos diariamente. Padrão: 'Notas Diárias'.",Daily:"Diário"},lq={welcome:"Bem-vindo ao Memos!",ribbonIconTitle:"Thino",months:["Janeiro","Fevereiro","Março","Abril","Maio","Junho","Julho","Agosto","Setembro","Outubro","Novembro","Dezembro"],monthsShort:["Jan.","Fev.","Mar.","Abr.","Maio","Jun.","Jul.","Ago.","Set.","Out.","Nov.","Dez."],weekDays:["Domingo","Segunda","Terça","Quarta","Quinta","Sexta","Sábado"],weekDaysShort:["Dom","Seg","Ter","Qua","Qui","Sex","Sáb"],to:"para",year:null,month:null,"Basic Options":"Opções Básicas","User name":"Nome de Usuário","Set your user name here. 'Memos 😏' By default":"Defina o nome de usuário. Padrão: 'Thino 😏'.","Insert after heading":"Inserir após o cabeçalho","If left blank, the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"Deve definir o mesmo cabeçalho na configuração posterior se pretende inserir e processar memorandos abaixo do cabeçalho aqui definido.","Allows admonitions to be created using ":"Permitir que Admonitions sejam criadas usando ","Process Memos below":"Processar Memorandos abaixo do Cabeçalho","If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.":"Somente as entradas abaixo deste cabeçalho serão processadas nas suas notas. Se não configurar esta funcionalidade, nenhuma nota será processada para o ficheiro respetivo.","Save Memo button label":"Legenda do Botão de Guardar Memorandos","The text shown on the save Memo button in the UI. 'NOTEIT' by default.":'Define o texto apresentado na UI do botão guardar memorandos. Padrão: "NOTEIT".',"Focus on editor when open memos":"Focar no Editor ao iniciar o Thino","Focus on Editor when open memos. Focus by default.":'Focar no editor ao iniciar o Thino. Padrão: "Focar".',"Open daily memos with open memos":"Abrir memorandos diários ao iniciar o Thino","Open daily memos with open memos. Open by default.":'Abrir memorandos diários ao iniciar o Thino. Padrão: "Abrir".',"Open Memos when obsidian opens":"Abrir Thino quando o Obsidian inicia","When enable this, Memos will open when Obsidian opens. False by default.":'Quando esta opção está activa, o Memos abrirá quando o Obsidian inicia. Padrão: "Falso".',"Hide done tasks in Memo list":"Ocultar tarefas concluídas na lista de memorandos","Hide all done tasks in Memo list. Show done tasks by default.":'Ocultar todas as tarefas concluídas na lista de memorandos. Padrão: "Mostrar tarefas concluídas".',"Advanced Options":"Opções Avançadas","UI language for date":"Idioma na UI da Data ","Translates the date UI language. Only 'en' and 'zh' are available.":"Define o idioma na UI da Data. De momento, apenas 'en', 'fr', 'pt' e 'zh' estão disponíveis.","Default prefix when save thino":"Prefixo Padrão","Set the default prefix when create memo, 'List' by default.":"Define o prefixo padrão quando um memorando é criado. Padrão: 'Lista'.","Default insert date format":"Formato Padrão para Inserção de Data","Set the default date format when insert date by @, 'Tasks' by default.":"Define o formato de Data padrão ao inserir a data usando '@'. Padrão: 'Tarefas'.","Default editor position on mobile":"Posição Padrão do Editor de Memorandos na Versão Móvel","Set the default editor position on Mobile, 'Top' by default.":"Define a posição padrão do editor de memorandos na versão móvel. Padrão: 'Topo'.","Use button to show editor on mobile":"Usar Botão para Mostrar o Editor na Versão Móvel","Set a float button to call editor on mobile. Only when editor located at the bottom works.":"Define um botão flutuante para abrir o editor na versão móvel. Opção disponível somente quando a posição do editor está definida para 'Fundo'.","Show Time When Copy Results":"Mostrar a Hora ao Copiar os Resultados","Show time when you copy results, like 12:00. Copy time by default.":"Mostrar a Hora, no formato '12:00', ao copiar os resultados. Padrão: 'Copiar a hora'.","Show Date When Copy Results":"Mostrar a Data ao Copiar os Resultados","Show date when you copy results, like [[2022-01-01]]. Copy date by default.":'Mostrar a Data, no formato [[2022-01-01]], ao copiar os resultados. Padrão: "Copiar a hora".',"Add Blank Line Between Different Date":"Adicionar Linha em Branco entre Datas Diferentes.","Add blank line when copy result with date. No blank line by default.":'Adicionar linha em branco ao copiar resultados com Data. Padrão: "Não adicionar linha."',"Share Options":"Opções de Partilha","Share Memos Image Footer Start":"Partilhar a Imagem de um memorando - Início do Rodapé","Set anything you want here, use {ThinoNum} to display Number of memos, {UsedDay} for days. '{ThinoNum} Thino {UsedDay} Days' By default":"Defina como preferir, use {ThinoNum} para mostrar o número de thinorandos e use {UsedDay} para dias. 'Padrão: {ThinoNum} Thinorandos {UsedDay} Dias'.","Share Memos Image Footer End":"Partilhar a Imagem de um memorando - Fim do Rodapé","Set anything you want here, use {UserName} as your username. '✍️ By {UserName}' By default":"Defina como preferir, use {UserName} como o seu nome de usuário. Padrão: '✍️ Por {UserName}'.","Save Shared Image To Folder For Mobile":"Guardar a Imagem Partilhada para Pasta na Versão Móvel","Save image to folder for mobile. False by Default":'Guardar a imagem partilhada para pasta na versão móvel. Padrão: "Falso".',"Say Thank You":"Agradeça",Donate:"Doar","If you like this plugin, consider donating to support continued development:":"Se gosta deste plugin, considere doar para apoiar o seu desenvolvimento contínuo:","File Name of Recycle Bin":"Nome da Reciclagem","Set the filename for recycle bin. 'delete' By default":"Define o nome do ficheiro para a Reciclagem. Padrão: 'delete'.","File Name of Query File":"Nome do Ficheiro de Query","Set the filename for query file. 'query' By default":"Define o nome do ficheiro de Query. Padrão: 'Query'.","Use Tags In Vault":"Usar Tags no Vault","Use tags in vault rather than only in Memos. False by default.":'Usar as Tags do Vault e não somente dos memorandos. Padrão: "Falso".',"Ready to convert image into background":"Pronto para converter imagem em fundo",List:"Lista",Task:"Tarefa",Top:"Topo",Bottom:"Fundo",TAG:"TAG",DAY:"DIA",QUERY:"QUERY",EDIT:"EDITAR",PIN:"FIXAR",UNPIN:"DESAFIXAR",DELETE:"ELIMINAR","CONFIRM!":"CONFIRMAR!","CREATE FILTER":"CRIAR FILTRO",Settings:"Definições","Recycle bin":"Reciclagem","About Me":"Acerca de mim","Fetching data...":"A obter dados...","Here is No Memos.":"Não existem Thino.","Frequently Used Tags":"Tags Usadas Frequentemente","What do you think now...":"Em que está a pensar...",READ:"LER",MARK:"ASSINALAR",SHARE:"PARTILHAR",SOURCE:"ORIGEM",RESTORE:"RESTAURAR","DELETE AT":"ELIMINADO EM","Noooop!":"Noooop!","All Data is Loaded 🎉":"Todos os Dados foram Carregados 🎉","Quick filter":"Filtro rápido",TYPE:"TIPO",LINKED:"LINKED","NO TAGS":"SEM TAGS","HAS LINKS":"TEM LINKS","HAS IMAGES":"TEM IMAGENS",INCLUDE:"INCLUIR",EXCLUDE:"EXCLUIR",TEXT:"TEXTO",IS:"É",ISNOT:"NÃO É",SELECT:"SELECCIONAR","ADD FILTER TERMS":"ADICIONAR TERMOS DE FILTRAGEM",FILTER:"FILTRAR",TITLE:"TÍTULO","CREATE QUERY":"CRIAR QUERY","EDIT QUERY":"EDITAR QUERY",MATCH:"IGUALA",TIMES:"VEZES","Share Memo Image":"Partilhar Imagem de Memo","↗Click the button to save":"↗Clique no botão para guardar","Image is generating...":"A gerar Imagem..","Image is loading...":"A carregar Imagem...","Loading...":"Carregando...","😟 Cannot load image, image link maybe broken":"😟 Não é possível carregar a imagem, o link da imagem pode estar incorrecto","Daily Memos":"Thino Diários","CANCEL EDIT":"CANCELAR EDIÇÃO","LINK TO THE":"LINK PARA O","Mobile Options":"Opções Móveis","Don't support web image yet, please input image path in vault":"Ainda não existe suporte para imagens de web. Por favor, insira o link para uma imagem do vault","Experimental Options":"Opções Experimentais","Background Image in Dark Theme":"Imagem de Fundo no Tema Escuro","Background Image in Light Theme":"Imagem de Fundo no Tema Claro",'Set background image in dark theme. Set something like "Daily/one.png"':'Defina a imagem de fundo para o tema escuro. Defina da seguinte forma: "Daily/one.png".','Set background image in light theme. Set something like "Daily/one.png"':'Defina a imagem de fundo para o tema claro. Defina da seguinte forma: "Daily/one.png".','Set default memo composition, you should use {TIME} as "HH:mm" and {CONTENT} as content. "{TIME} {CONTENT}" by default':'Defina a composição padrão do memorando, deve usar {TIME} como "HH:mm" e {CONTENT} como conteúdo. Padrão: "{TIME} {CONTENT}".',"Default Memo Composition":"Composição Padrão de um Memorando","Show Tasks Label":"Mostrar Etiquetas de Tarefas","Show tasks label near the time text. False by default":'Mostrar etiquetas de tarefas próximas do texto de tempo. Padrão: "Falso".',"Please Open Memos First":"Por favor, abra o Thino primeiro",DATE:"DATA",OBSIDIAN_NLDATES_PLUGIN_NOT_ENABLED:"OBSIDIAN_NLDATES_PLUGIN_NOT_ENABLED",BEFORE:"ANTES",AFTER:"DEPOIS","Allow Comments On Memos":"Permitir Comentários nos Memorandos","You can comment on memos. False by default":'Permite que comente os memorandos. Padrão: "Falso".',Import:"Importar","TITLE CANNOT BE NULL!":"O TÍTULO NÃO PODE SER NULO!","FILTER CANNOT BE NULL!":"O FILTRO NÃO PODE SER NULO!","Comments In Original DailyNotes/Notes":"Comentários nas Notas/Notas Diárias Originais","You should install Dataview Plug-in ver 0.5.9 or later to use this feature.":"Deve instalar a versão 0.5.9 ou posterior do plugin Dataview para usar esta funcionalidade.","Open Memos Successfully":"Thino Iniciado com Sucesso","Fetch Memos Error":"😭 Erro de Fetch","Copied to clipboard Successfully":"Copiado para a área de transferência com sucesso","Check if you opened Daily Notes Plugin Or Periodic Notes Plugin":"Verifique se abriu o plugin de Notas Diárias ou de Notas Periódicas","Please finish the last filter setting first":"Por favor, termine primeiro a configuração do último filtro","Close Memos Successfully":"Thino Fechado com Sucesso","Insert as Memo":"Inserir como um Memorando","Insert file as memo content":"Inserir ficheiro como conteúdo de um memorando","Image load failed":"Falha no carregamento da imagem","Content cannot be empty":"O Conteúdo não pode estar vazio","Unable to create new file.":"Não foi possível criar um novo ficheiro.","Failed to fetch deleted memos: ":"Falha no fetch dos memorandos removidos: ","RESTORE SUCCEED":"RESTAURO BEM SUCEDIDO","Save Memo button icon":"Ícone do Botão para Guardar Memorandos","The icon shown on the save Memo button in the UI.":"O ícone exibido na UI do botão para guardar memorandos.","Fetch Memos From Particular Notes":"Obter Memorandos de Notas Específicas",'You can set any Dataview Query for memos to fetch it. All memos in those notes will show on list. "#memo" by default':'Pode definir qualquer Query de Dataview para o Memos procurar. Todos os memorandos nessas notas serão mostrados na lista. Padrão: "#memo".',"Allow Memos to Fetch Memo from Notes":"Permitir que o Thino Obtenha memorandos das Notas","Use Memos to manage all memos in your notes, not only in daily notes. False by default":'Use o Memos para gerir todos os memorandos nas suas notas e não apenas nas notas diárias. Padrão: "Falso".',"Always Show Memo Comments":"Mostrar Comentários dos Memorandos","Always show memo comments on memos. False by default":'Mostrar sempre os comentários dos memorandos. Padrão: "Falso".',"You didn't set folder for daily notes in both periodic-notes and daily-notes plugins.":"Não definiu a pasta para as notas diárias, quer no plugin the Notas Periódicas ou de Notas Diárias.","Please check your daily note plugin OR periodic notes plugin settings":"Por favor, verifique as configurações dos plugins de Notas Diárias OU de Notas Periódicas","Use Which Plugin's Default Configuration":"Usar a Configuração Padrão do Plugin","Memos use the plugin's default configuration to fetch memos from daily, 'Daily' by default.":"O Memos usa a configuração padrão do plugin seleccionado para obter memorandos diariamente. Padrão: 'Notas Diárias'.",Daily:"Diário"},cq={},uq={},dq={},fq={welcome:"欢迎使用 Thino ",ribbonIconTitle:"Thino",months:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthsShort:[null,null,null,null,null,null,null,null,null,null,null,null],weekDays:["周日","周一","周二","周三","周四","周五","周六"],weekDaysShort:["周日","周一","周二","周三","周四","周五","周六"],to:"至",year:"年",month:"月","Basic Options":"基础选项","User name":"用户名","Set your user name here. 'Memos 😏' By default":"在这里设置你喜欢的用户名。 默认为 'Thino 😏'",'You can set target heading like "# Heading" to control data location':'你可以设置目标标题,例如 "# Heading" 来控制数据的位置',"Insert after heading":"在指定标题后插入 Thino","If left blank, the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"若留空,则记录的 thino 内容在日记末尾插入,若填写标题,则记录的 thino 内容统一都记录在该标题下","Process Memos below":"解析指定标题后的 Thino","If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.":"若留空,则在Thino界面会显示所有thino记录内容,若填写标题,则Thino界面只显示该标题下的内容,写入其他位置的内容不显示","Save Memo button label":"保存按钮上的文本","The text shown on the save Memo button in the UI. 'NOTEIT' by default.":"在保存按钮上展示的文本。默认为 'NOTEIT'","Focus on editor when open memos":"自动聚焦到 Thino 输入框","Focus on editor when open memos. Focus by default.":"当打开 Thino 的时候自动聚焦到 Thino 输入框。默认开启","Open daily memos with open memos":"打开每日 Thino 的时候打开 Thino 界面","Open daily memos with open memos. Open by default.":"打开每日 Thino 的时候打开 Thino 界面。默认开启","Open Memos when obsidian opens":"当开启 Obsidian 的时候自动打开 Thino","When enable this, Memos will open when Obsidian opens. False by default.":"当开启该选项, Thino 会在 Obsidian 打开时自动打开。默认不开启。","Hide done tasks in Memo list":"在 Thino 列表中隐藏已完成 Thino","Hide all done tasks in Memo list. Show done tasks by default.":"在 Thino 列表中隐藏已完成 Thino。默认不开启","Advanced Options":"进阶选项","UI language for date":"针对日期展示的语言界面","Translates the date UI language. Only 'en' and 'zh' are available.":"对日期的不同翻译。目前只能选择 'en' 和 'zh'(未来会废置)","Default prefix when save thino":"保存 Thino 时的默认前缀","Set the default prefix when create memo, 'List' by default.":"设置默认的前缀样式。默认为列表","Default insert date format":"插入日期附带的样式","Set the default date format when insert date by @, 'Tasks' by default.":"当使用 @ 来快速插入日期时,插入日期附带的样式,默认为 'Tasks' 样式","Default editor position on mobile":"在移动端上的默认编辑器位置","Set the default editor position on Mobile, 'Top' by default.":"设置在移动端上的默认编辑器位置,默认在顶部。","Use button to show editor on mobile":"当编辑器位置在底部时,用按钮来唤出编辑器","Set a float button to call editor on mobile. Only when editor located at the bottom works.":"设置一个浮动按钮来唤出编辑器。当在移动端上启用该选项才会生效","Show Time When Copy Results":"当复制检索结果时附带时间","Show time when you copy results, like 12:00. Copy time by default.":"在复制检索结果时附带其时间,例如 12:00 。默认开启","Show Date When Copy Results":"当复制检索结果时附带日期","Show date when you copy results, like [[2022-01-01]]. Copy date by default.":"在复制检索结果时附带其日期,例如 [[2022-01-01]]。默认开启","Add Blank Line Between Different Date":"在复制日期的时候加上空行","Add blank line when copy result with date. No blank line by default.":"在复制日期的时候在相邻的日期之间加上空行。默认无空行","Share Options":"分享选项","Share Memos Image Footer Start":"分享 Thino 图片的左边页脚","Set anything you want here, use {ThinoNum} to display Number of thino, {UsedDay} for days. '{ThinoNum} Thino {UsedDay} Days' By default":"你可以在这里设置你想要的任意文本,用 {ThinoNum} 来展示你记录的 thino 数量,{UsedDay} 来展示使用日期。默认为'{ThinoNum} Thino {UsedDay} Days'","Share Memos Image Footer End":"分享 Thino 图片的右边页脚","Set anything you want here, use {UserName} as your username. '✍️ By {UserName}' By default":"你可以在这里设置你想要的任意文本,用 {UserName} 来展示你的用户名。默认为 '✍️ By {UserName}'","Save Shared Image To Folder For Mobile":"当在移动端上时保存图片到文件夹","Save image to folder for mobile. False by Default":"当在移动端上时,保存生成的图片到文件夹","Say Thank You":"感谢开发",Donate:"捐赠","If you like this plugin, consider donating to support continued development:":"如果你喜欢这个插件,而且也希望给我买鸡腿,那么可以考虑 Github 页面右边的 Sponsor~","File Name of Recycle Bin":"回收站的文件名","Set the filename for recycle bin. 'delete' By default":"给回收站设置一个文件名。默认为'delete'","File Name of Query File":"检索文件的文件名","Set the filename for query file. 'query' By default":"设置存放检索式的文件的文件名。默认为'query'","Use Tags In Vault":"使用在库内的所有标签","Use tags in vault rather than only in Memos. False by default.":"使用在库内的而不是 Thino 内的标签。默认关闭","Don't support web image yet, please input image path in vault":"暂不支持网络图片,请使用本地图片","Ready to convert image into background":"正在将图片转换为背景图",List:"列表",Task:"任务",Top:"顶部",Bottom:"底部",TAG:"标签",DAY:"天",QUERY:"检索式",EDIT:"编辑",PIN:"置顶",UNPIN:"取消置顶",DELETE:"删除","CONFIRM!":"确定删除","CREATE FILTER":"创建检索式",Filter:"筛选",Settings:"设置","Recycle bin":"回收站","About Me":"关于","Fetching data...":"获取数据中...","Here is No Memos.":"没有找到 Thino","Frequently Used Tags":"常用标签","What do you think now...":"你现在在想什么?",READ:"阅读",MARK:"引用",SHARE:"分享",SOURCE:"来源",RESTORE:"恢复",ARCHIVE:"归档","Daily Review":"每日回顾","DELETE AT":"删除于","Noooop!":"啥都没有!","All Data is Loaded 🎉":"所有数据都加载好啦 🎉","Quick filter":"快速筛选",TYPE:"类型",LINKED:"有链接","NO TAGS":"无标签","HAS LINKS":"有超链接","HAS IMAGES":"有图片",INCLUDE:"包括",EXCLUDE:"排除",TEXT:"文本",IS:"是",AND:"和",OR:"或",LIST:"状态",ISNOT:"不是",SELECT:"选择",PATH:"路径",METADATA:"元数据","ADD FILTER TERMS":"添加检索条件",FILTER:"筛选器",TITLE:"标题","CREATE QUERY":"创建检索式","EDIT QUERY":"编辑检索式",MATCH:"匹配",TIMES:"次","Share Memo Image":"分享 Thino 图片","↗Click the button to save":"↗点击右上角的按钮来保存","Image is generating...":"图片正在生成中...","Image is loading...":"图片正在加载中...","😟 Cannot load image, image link maybe broken":"😟 无法加载图片,图片链接也许不存在","Loading...":"努力加载中...","Daily Memos":"每日 Thino","CANCEL EDIT":"取消编辑","LINK TO THE":"链接到","Mobile Options":"移动端选项","Experimental Options":"实验性选项","Background Image in Dark Theme":"深色主题的背景图","Background Image in Light Theme":"浅色主题的背景图",'Set background image in dark theme. Set something like "Daily/one.png"':'设置深色主题的背景图。请设置类似"Daily/one.png"的路径','Set background image in light theme. Set something like "Daily/one.png"':'设置浅色主题的背景图。请设置类似"Daily/one.png"的路径','Set default memo composition, you should use {TIME} as "HH:mm" and {CONTENT} as content. "{TIME} {CONTENT}" by default':'设置默认 Thino 组成,你必须要使用 {TIME} 作为 "HH:mm" 而且要设置 {CONTENT} 作为内容识别。默认情况下, Thino 基于 "{TIME} {CONTENT}" 识别',"Default Memo Composition":"【已弃置】默认 Thino 组成","Show Tasks Label":"展示任务标签","Show tasks label near the time text. False by default":"在 Thino 的时间旁展示任务标签。默认情况下不展示","Please Open Memos First":"请先打开 Thino","Comment it...":"评论...",DATE:"日期",OBSIDIAN_NLDATES_PLUGIN_NOT_ENABLED:"Obsidian Natrual DATES language 插件没启动",BEFORE:"在之前",AFTER:"在之后","Allow Comments On Memos":"允许在 Thino 上评论","You can comment on memos. False by default":"你可以在 Thino 点击图标进行评论了。默认不开启",Import:"导入","TITLE CANNOT BE NULL!":"标题不可以为空!","FILTER CANNOT BE NULL!":"筛选器不可以为空!","Comments In Original DailyNotes/Notes":"在原文件中进行评论","You should install Dataview Plugin ver 0.5.9 or later to use this feature.":"你需要安装 0.5.9 版本以上的 Dataview 插件来使用该功能","Open Memos Successfully":"成功打开 Thino ","Fetch Memos Error":"😭 Thino 获取失败","Copied to clipboard Successfully":"复制成功","Check if you opened Daily Notes Plugin Or Periodic Notes Plugin":"请检查你有没有开启日记插件或者 Periodic Notes 插件且启用了日记模式","Please finish the last filter setting first":"先完善上一个过滤器吧","Close Memos Successfully":"成功关闭 Thino ","Insert as Memo":"插入内容为 Thino","Insert file as memo content":"插入文件为 Thino","Image load failed":"有个图片加载失败了😟","Content cannot be empty":"内容不能为空呀","Unable to create new file.":"无法新建文件","Failed to fetch deleted memos: ":"无法获取已删除的 Thino :","RESTORE SUCCEED":"成功恢复 Thino","DELETE SUCCEED":"删除成功","Save Memo button icon":"保存按钮上的图标","The icon shown on the save Memo button in the UI.":"你可以设置保存按钮上的图标","Fetch Memos From Particular Notes":"从指定的文件中获取 Thino",'You can set any Dataview Query for memos to fetch it. All memos in those notes will show on list. "#memo" by default':'你可以给笔记设置指定检索式来让 Memos 可以索引到它。默认为 "#memo" ',"Allow Memos to Fetch Memo from Notes":"允许 Thino 从笔记中获取 Thino","Use Memos to manage all memos in your notes, not only in daily notes. False by default":"使用 Memos 来管理你笔记中的 Memos,不单只 DailyNotes 中的内容。默认为关闭","Always Show Memo Comments":"评论将总是可见","Always show memo comments on memos. False by default":"当开启后评论总是会在 Thino 的下方展示。默认为关闭","You didn't set folder for daily notes in both periodic-notes and daily-notes plugins.":"你在 Periodic Notes 插件和日记插件都没设置日记的所在文件夹","Please check your daily note plugin OR periodic notes plugin settings":"请检查你的日记插件和/或 Periodic Notes 插件的设置","Use which plugin's default configuration":"使用哪个插件的默认日记配置","Memos use the plugin's default configuration to fetch memos from daily, 'Daily' by default.":"Thino 采用指定插件的默认配置来获取 Thino。默认为日记插件。",Daily:"日记插件","Always Show Leaf Sidebar on PC":"在 PC 上总是展示左侧栏","Show left sidebar on PC/Tablet even when the leaf width is less than 875px. False by default.":"在 PC 或平板上即使页面宽度小于 875px 时都展示左侧栏。默认为关闭","You didn't set format for daily notes in both periodic-notes and daily-notes plugins.":"你在 Periodic Notes 插件和日记插件都没设置日记的格式","fetch more":"加载更多","Search all settings":"搜索所有设置","Random Review":"随机回顾","ARCHIVED AT":"归档于","Failed to get memos from daily notes":"无法从日记中获取 Thino","Failed to delete memo":"无法删除 Thino","CTRL + ENTER to save":"CTRL + ENTER 保存","Started from":"开始于","Custom Background Image":"自定义背景图","Set custom background image.":"设置自定义背景图","Custom Memo Footer":"自定义 Thino 页脚","Set custom memo footer.":"设置自定义 Thino 页脚","Heatmap Color Scheme":"热力图颜色","Set different color scheme for heatmap.":"设置热力图的颜色","Enable Local Http Server":"启用本地 HTTP 服务器","Memos Http Server Port":"Thino HTTP 服务器端口","Set memos http server port to listen. '43999' by default":"设置 Thino HTTP 服务器端口。默认为 '43999'","Live-Preview Mode OR Source Mode.":"基于 Thino 的所见即所得模式(默认) 或者 源码模式,你可以自己选择适合自己的输入体验。","Default Editor Mode":"默认编辑器模式","Save type for Thino":"Thino 保存类型",DAILY:"日记",MULTI:"多文件",CANVAS:"画布",FILE:"单文件",ALL:"所有","Failed to create daily note, check if it exists.":"无法创建日记,请检查是否存在文件夹","Failed to create daily note. Please check if you created a folder for daily notes.":"无法创建日记,请检查是否存在日记文件夹","After you verify your account, please refresh this page.":"验证成功后,请刷新页面。",Verify:"去验证","Oops! You forget to verify insider account":"内测账户验证失败","If you have any questions, please contact us.":"如果你有任何问题,请联系我们。","Delete Thino Directly":"直接删除 Thino","When delete thino directly, it will not be moved to trash. False by default.":"当直接删除 Thino 时,不会移动到回收站。默认为关闭","Get activation code":"获取激活码","Input activation code here":"在这里输入激活码","Copy Thino id":"获取 Thino id","Activate Pro Version":"激活专业版","Please copy Thino id first":"请先获取 Thino id",'You can set folder name with file name like "folder/file"':'你可以设置例如 "folder/file" 的文件夹名+文件名的搭配来存放在指定文件夹','You can set folder name like "folder1/folder2/folder3" to create sub-folder':'你可以设置例如 "folder1/folder2/folder3" 的文件夹名来创建子文件夹',"Default save type":"默认保存类型",'Set the default save type for thino. "DAILY" by default':'设置 Thino 的默认保存类型。默认为 "日记"',"Enable opening thino globally":"全局唤醒 Thino","Enable opening thino globally. False by default.":"全局唤醒 Thino。默认为关闭","Key for opening thino globally":"全局唤醒 Thino 的快捷键","Set key for opening thino globally. CTRL + SHIFT + T by default.":"设置全局唤醒 Thino 的快捷键。默认为 CTRL + SHIFT + T","Sync Thino via PKMer":"通过 PKMer 同步 Thino",Unlink:"取消链接",Link:"链接","Connect to PKMer Sync, you can check it in ":"连接到 PKMer 同步,你可以在该链接中查看:","PKMer Sync":"PKMer 同步","Remove successfully":"移除成功",Deactivate:"取消激活",Remove:"移除","Confirm?":"确认?","Sync Status":"同步状态","Start or stop sync":"开始或停止同步","Stop sync successfully":"停止同步成功","Start sync successfully":"开始同步成功",Stop:"停止",Start:"开始","Show thino near mouse":"在鼠标附近展示 Thino","Query not found":"检索式未找到","Send to clipboard successfully":"发送到剪贴板成功","Thino - Failed to start HTTP server, please check the port is available.":"Thino - 启动 HTTP 服务器失败,请检查端口是否可用。","Thino - Started HTTP server on port":"Thino - 启动 HTTP 服务器成功,端口为","Thino - Terminated HTTP server":"Thino - 终止 HTTP 服务器","File not exist":"文件不存在","Thino not found":"Thino 未找到","File not found for the given thino path, is creating a new file":"未找到承载指定 Thino 的文件,正在创建新文件","Saved sync token successfully":"保存同步令牌成功","Failed to find daily notes folder":"未找到日记文件夹","Please install obsidian-hover-editor plugin first":"请先安装 obsidian-hover-editor 插件","Copied app id successfully":"复制 app id 成功","Please input token first":"请先输入 token","Please enable sync first":"请先启用同步","Init Failed":"初始化失败","Folder not found for the given thino path, is creating a new folder":"未找到承载指定 Thino 的文件夹,正在创建新文件夹","File not found for the given thino path":"未找到承载指定 Thino 的文件","Failed to read current daily note, check if it exists.":"无法读取日记文件,请检查是否存在","Verify successfully":"验证成功","Failed to verify":"验证失败","Failed to save":"保存失败","Failed to login, please login again":"登录已过期,请重新登录","COPY FAILED":"复制失败","COPY SUCCEED":"复制成功","Copy selected text":"复制选中文本","Copy thino":"复制",COPY:"复制","This is a pro feature, please upgrade to pro version to use it.":"这是专业版功能,请升级到专业版来使用它。","You can get pro version from: ":"你可以从这里获取专业版:",Save:"保存",Cancel:"取消","Thino Daily Target":"Thino 每日目标",Input:"输入","#Tag":"#标签","to create tag":"来创建标签","You have verified your account. Congrats!":"你已经验证了你的账户。恭喜!","Pro features":"专业版功能","Target Thino Count":"目标 Thino 数量",on:"在","Switch waterfall view":"切换瀑布流视图","Switch view":"切换视图","Switch list view":"切换列表视图","Set daily target":"设置每日目标","Thino Save To: ":"Thino 保存到:","Enter fullscreen mode":"进入全屏模式","Exit fullscreen mode":"退出全屏模式",words:"字词",word:"字","Return To Home Page":"返回首页","No thinos to review!":"没有 thino 需要回顾!","Thinos to review":"Thino 需要回顾","Start Review":"开始回顾",Hard:"困难",Good:"良好",Easy:"简单",Again:"重来","Daily Progress":"每日进度","Clear all review data":"清除所有回顾数据","Show stats":"显示统计","Hide stats":"隐藏统计",Remaining:"剩余","Total Reviews":"总回顾","Today, you have reviewed all your thinos!":"今天你已经回顾了所有 thino!","Daily review limit reached! Come back tomorrow.":"每日回顾上限已达到!明天再来吧。","Open thino in center window":"在中心窗口打开 thino","Open thino in float window":"在浮动窗口打开 thino","Open thino in right sidebar":"在右侧边栏打开 thino","Open thino in left sidebar":"在左侧边栏打开 thino","Show thino editor":"显示 thino 编辑器","Toggle minimal mode":"切换 Minimal 模式","Focus on thino editor":"聚焦到 thino 编辑器","ReSync web thinos to local":"重新同步 web 上的 thino 到本地","Sync local thinos to web":"同步本地的 thino 到 web","Show daily thino":"显示每日 thino 视图","Focus on search bar":"聚焦到搜索栏","Show-thino in popover(Hover editor)":"在弹出框中显示 thino","Center window":"中心窗口","Float window":"浮动窗口","Right sidebar":"右侧边栏","Left sidebar":"左侧边栏","Save thino type when sync local":"同步本地时保存的 thino 类型","Set the default save thino type when sync local, FILE by default.":"设置同步本地时保存的 thino 类型,默认为单文件。","Sync service":"同步服务","Pro verification status":"专业版激活状态","Live-preview":"所见即所得",Source:"源码",General:"通用",Thino:"Thino",Theme:"主题",Share:"分享",Interface:"界面",Advanced:"进阶","Global copy":"全局复制","Set the folder name":"设置文件夹名","Set the filename":"设置文件名","Set the filename for current location file":"设置当前位置文件的文件名","Switch calendar type":"切换日历类型",alphabetical:"按名称(A-Z)",alphabeticalReverse:"按名称(Z-A)",byCount:"按使用次数(从高到低)",byCountReverse:"按使用次数(从低到高)","Type here":"在这里输入",Today:"今天",Yesterday:"昨天","Last 7 days":"最近 7 天","Last 30 days":"最近 30 天","Last 90 days":"最近 90 天","Last 180 days":"最近 180 天","Last 365 days":"最近 365 天",Found:"被找到","Copy filtered thinos":"复制筛选的 thino","Bulk delete":"批量删除","Bulk archive":"批量归档","Bulk tag operation":"标签编辑","Bulk restore":"批量恢复","If you are disabling the daily note plugin, it would be possible that the thino will not be deleted or patched properly. Please enable the plugin and try again.":"如果你禁用了日记插件,可能会导致 thino 无法被正确删除。请启用插件后再试一次。",Preview:"预览","Set and save":"设置并保存","Show day mark in thino list":"在 Thino 列中展示日期标记","Show day mark on the top of daily range thino. False by default.":"在 Thino 列中展示日期标记。默认为关闭","Click to expand or fold, Cmd+Click to show all thinos of the day":"点击展开或折叠,Cmd+点击展示当天所有 thino","You can buy a license from":"你可以从这里购买许可证","No thinos in range":"该范围内没有 thino",Month:"月视图",Week:"周视图",Day:"日视图",Agenda:"日程视图",Tomorrow:"明天",Previous:"往前",Next:"往后","Search all columns...":"搜索所有的列...","Basic Info":"基础信息","Additional Info":"附加信息","Created At":"创建于",Content:"内容","Thino Type":"Thino 类型","Source Type":"来源类型","Row status":"归档状态",Path:"路径","Pinned Status":"置顶状态",Table:"表格",Chat:"聊天",Moments:"动态",Waterfall:"瀑布流",Calendar:"日历","Go to page":"跳转到页",Page:"页",Show:"展示",rows:"行","Temp Filter":"临时筛选器","Set the heading for saving thino":"设置保存 Thino 的标题","# Heading":"# 标题","Open link directly in Thino view":"Thino 视图内直接打开双链","Day mark range":"日期标记范围","Set the range of day mark. Day by default.":"设置日期标记的范围,默认为天","Thino is locked":"Thino 已锁定","Please unlock Thino by input password":"请输入密码来解锁 Thino","Auto Download Image":"自动下载图片","Auto download image when save to thino. 'false' by default":"当保存到 Thino 时自动下载图片。默认为 'false'","Thino Http IP Type":"Thino HTTP 服务器 IP 类型","Set Thino http server ip to listen. 'localhost' by default":"设置 Thino HTTP 服务器 IP。默认为 'localhost'","Password to lock Thino":"锁定 Thino 的密码",Unlock:"解锁",Locked:"已锁定","Password is incorrect":"密码错误",Lock:"锁定","Need password to unlock Thino":"需要密码来解锁 Thino","You have not set a password or enable this feature yet":"你还没有设置密码或者启用该功能",Password:"密码","Password for Thino":"Thino 的密码","Please input your password to change password settings":"请输入原来的密码来修改密码设置","Please input your password":"请输入密码","Lock thino":"锁定 Thino",date:"日期",time:"时间",event:"事件","Add tag position":"添加标签位置","Set the position of the tag when adding tag automatically":"设置自动添加标签的位置","Add tag automatically":"自动添加标签","Add tag to the end or beginning of the thino content when creating a thino and filtering tags":"在创建 Thino 和筛选标签时,将标签添加到 Thino 内容的末尾或开头","Add tag with new line":"添加标签时换行","Add tag with new line when adding tag automatically":"自动添加标签时换行","Input to select more tags":"输入来选择更多标签","Tag Bulk Edit":"标签批量编辑","Tag Bulk Select":"标签批量选择","Exist Tags":"已有标签","Selected Tags":"已选标签","Click to remove exist tag":"点击移除已有标签","Click to remove selected tag":"点击移除已选标签","Select tags":"选择标签","Input to select exist tag":"输入来选择已有标签",Beginning:"开头",End:"末尾","Chat view style":"聊天视图样式","Set the style of chat view":"设置聊天视图的样式","Background image for moments view":"动态视图的背景图","Set the background image for moments view":"设置动态视图的背景图","Icon for moments/chat view/share image":"动态/聊天视图/分享图的头像","Set the icon for moments/chat view/share image":"设置动态/聊天视图/分享图的头像","Quote for moments view/share image":"动态视图/分享图的个性签名","Set the quote for moments view/share image":"设置动态视图/分享图的个性签名","Theme for Thino":"Thino 主题","Set the theme for Thino":"设置 Thino 的主题","Interface Details":"界面详情","Task amount":"任务数量","Thino status":"Thino 状态","Used tags":"使用的标签","Used days":"使用的天数","Most active day":"最活跃的一天","Most active hour":"最活跃的一小时","Thino amount":"Thino 数量","No content to generate.":"没有内容可以生成。","Image generated successfully.":"图片生成成功。","Failed to generate image.":"图片生成失败。","Share filtered thinos as image":"分享筛选的 Thino 为图片","Latest version":"最新版本","Previous version":"之前版本","Thino update info":"Thino 更新信息","Debug info copied to clipboard":"调试信息已复制到剪贴板","Copy debug info":"复制调试信息","Failed to load changelog":"无法加载更新日志","View online":"在线查看",ChangeLog:"更新日志","Please open thino first":"请先打开 Thino","Insert editor":"插入编辑器","Please set different save locations for multi-file settings in Thino. The diary folder overlaps with the multi-file save location, or there is a risk of it being read repeatedly.":"请在 Thino 设置中为多文件设置不同的路径,日记文件夹与多文件保存路径重复,或者存在被重复读取可能","Default time prefix for thino in daily notes":"日记中 Thino 的默认时间前缀","Set default time prefix for thino in daily notes.":"设置日记中 Thino 的默认时间前缀","Save image successfully":"保存图片成功","User quote":"用户签名","Set user quote for thino":"设置用户签名","User icon":"用户头像","Set user icon for thino. You can input http/https link or file path in vault.":"设置用户头像。你可以设置 http/https 链接或者 vault 中的文件路径。","User info":"用户信息","Copy filtered results":"复制筛选结果","Share image":"分享图片",Default:"默认",Gray:"灰色",Grass:"草绿",Flame:"火焰",Olive:"橄榄",Ice:"冰",Magenta:"品红","Daily notes":"日记相关",Editor:"编辑器","Append/prepend text when share to Thino":"分享到 Thino 时添加/前置文本","Append text when share to Thino":"分享到 Thino 时添加文本","Prepend text when share to Thino":"分享到 Thino 时前置文本","Add newline when append/prepend text":"添加换行符",Prepend:"前置",Append:"后置",Both:"两者",None:"无","Hide pinned group":"隐藏置顶分组","Hide pinned group in thino list. False by default.":"隐藏置顶的 Thino 分组。默认为关闭","Set the heading for the task type of thino, by default the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"设置 Thino 任务类型的标题,如果提供了标题,所有记录的 Thino 内容将统一归类到该标题下。","Different insert target for different type":"不同类型的 Thino 有不同的插入目标","Toggle this to set different insert target for different type of thino, like task or list type of thino":"切换此选项以为不同类型的 Thino 设置不同的插入目标,例如任务或列表类型的 Thino","Set process target":"设置处理目标","You can set whole diary or only part of it":"你可以设置整个日记或者其中的一部分",Custom:"自定义","Whole diary":"整个日记","Set thino insert place":"设置 Thino 插入位置","Set where to insert thino content":"设置 Thino 内容插入位置","End of the diary":"日记的末尾","Custom location":"自定义位置","Setting guide":"设置流程","Details settings":"详细设置","Start Thino":"开始 Thino","About Thino Pro":"关于 Thino 专业版",Enabled:"已启用",Enable:"启用","Daily notes folder":"日记文件夹","Set daily notes folder":"设置日记文件夹","Daily note name format":"日记文件名格式","Set daily note name format":"设置日记文件名格式","Daily note plugin":"日记插件","Enable daily note plugin":"启用日记插件",Selected:"已选择",Select:"选择","A classic theme for Thino with a two-column layout":"Thino 的经典主题,采用两列布局",Classic:"经典","A modern theme for Thino with a three-column layout and some unique features.":"Thino 的现代主题,采用三列布局和一些独特的功能。",Modern:"现代","Go and enjoy Thino":"去享受 Thino 吧","Congrats! All settings done":"恭喜!所有设置已完成","Adjust settings that influence your user experience with Thino.":"调整影响你使用 Thino 的设置。","Set preferences for using Thino":"设置使用 Thino 的偏好","If you are using the Thino basic version, enabling the daily note plugin is required. Configure its settings to work effectively with it.":"如果你使用的是 Thino 基础版,启用日记插件是必须的。配置其设置以有效地使用它。","Go with daily note plugin":"使用日记插件","Choose a theme for Thino.":"选择 Thino 的主题。","Set theme for Thino":"设置 Thino 的主题","Set up your user info for Thino.":"设置你的用户信息。","Get started with Thino":"开始使用 Thino","Skip and start Thino":"跳过并开始 Thino","Next step":"下一步","Back to previous step":"返回上一步","Click to enable =>":"点击启用 =>","This is Thino's sidebar. Navigate to different path or select query filter.":"这是 Thino 的侧边栏。你可以导航到不同的路径或选择查询过滤器。","Click here and go to settings page.":"点击这里并转到设置页面。","Click here and go to different path.":"点击这里并转到不同的路径。","Select or create query filter here.":"在这里选择或创建查询过滤器。","See the status of Thinos here.":"在这里看到 Thino 的状态。","Search your thino quickly here.":"在这里快速搜索你的 Thino。","Edit or create your thino here.":"在这里编辑或创建你的 Thino。","See your thinos here.":"在这里看到你的 Thino。","See your time status of thinos here.":"在这里看到你的 Thino 时间状态。","See your tags here. Tags will be shown when thino contains tags.":"在这里看到你的标签。当 Thino 包含标签时,标签将显示。",Done:"完成","Thino is ready to use. ":"Thino 已准备好使用。","You can start using Thino now. If you want to know more about Thino Pro, click the button below.":"你现在可以开始使用 Thino 了。如果你想了解更多关于 Thino 专业版的信息,请点击下面的按钮。","Default time prefix":"默认时间前缀","Append Text Action":"分享到 Thino 时的后置文本动作","Prepend Text Action":"分享到 Thino 时的前置文本动作",Preset:"预设","Select Tags":"选择标签","It is not available on small view":"在窄的视图中不可用","Append text":"在末尾添加文本","Prepend text":"在开头添加文本","Your daily note folder is not set correctly, please check your settings":"你的日记文件夹设置不正确,请检查你的设置","Default sharing style":"默认分享样式","Set the default style for sharing thino, 'Modern' by default.":"设置 Thino 的默认分享样式,默认为“现代”。",Clean:"清爽",Minimal:"极简",Gradient:"渐变","Thino share":"Thino 分享","Copy to clipboard failed":"复制到剪贴板失败","Copy to clipboard successfully":"复制到剪贴板成功","Your content has been copied to clipboard, and inserted into the editor. Please try it again":"你的内容已经复制到剪贴板,并插入到编辑器中。请再试一次","Share thino":"分享 Thino","Set file name after create thino":"创建 Thino 后设置文件名","You can set file name after create thino. A input box will show when you create thino.":"你可以在创建 Thino 后设置文件名。当你创建 Thino 时,会显示一个输入框。",SPLIT:"分割","Split by Heading 1":"按一级标题分割","Split by Heading 2":"按二级标题分割","Split by Heading 3":"按三级标题分割","Insert task":"插入任务","All settings have been reset to default.":"所有设置已重置为默认值。","Reset all Thino settings":"重置所有 Thino 设置","Reset settings":"重置设置","Reset Thino settings to default settings.":"将 Thino 设置重置为默认设置。","Task Management":"任务管理","Append completed date when task done in thino":"在 Thino 中的任务完成时添加完成日期","Append completed date when task done in thino. False by default":"在 Thino 中的任务完成时添加完成日期。默认为关闭","Set tag for single file that Thino indexes":"Thino 会索引被设置标签的单文件","When you set a tag here, Thino will index this file contains this tag and show it in the list. Don't need to add `#`.":"当你在这里设置一个标签时,Thino 会索引包含这个标签的文件,并在列表中显示。不需要添加 `#`。","Set tag for file type file":"为单文件类型文件设置标签","Set tag for multi type file":"为多文件类型文件设置标签","Please input the tag":"请输入标签","Merge thinos in to thino share image":"合并 Thino 到 Thino 分享图片","Custom height for Thino content":"自定义 Thino 内容高度","Set custom height for Thino content. Like 200px or 20rem":"设置 Thino 内容的自定义高度。如 200px 或 20rem","Input height":"输入高度","Submit issue":"提交问题","Current version":"当前版本","Bug report":"Bug 报告","Click the button to copy debug info and open the issue page":"点击按钮复制调试信息并打开问题页面","Copy and go":"复制并前往","Debug info copied":"调试信息已复制","Feature request":"功能请求","Submit your feature request to the issue page":"提交你的功能请求到问题页面",Go:"前往","Toggle query list visibility":"切换 Query 列表可见性","Toggle tags visibility":"切换标签可见性","Toggle sidebar visibility":"切换侧边栏可见性",Collapse:"收起",Expand:"展开","Max height for collapse":"折叠的最大高度","The max height for thino collapse, when set 0, thino would not collapse. 0 by default. (This is not lines count, it is height in px.)":"Thino 折叠的最大高度,设置为 0 时,Thino 不会折叠。默认为 0。(这不是行数,而是像素高度值)","Render content":"渲染内容","Optimize for Callout":"优化 Callout 渲染性能问题","Won't render content contains more than 3 callouts automatically. True by default":"不会自动渲染包含超过 3 个 Callout 的内容。默认为开启","The value should be greater than":"值应大于","Append Text":"后置文本","Prepend Text":"前置文本","Thino height when collapsed":"Thino 折叠时的高度","The height for thino when it is collapsed, when set 0, thino would not collapse. 100 by default. (This is not lines count, it is height in px.)":"Thino 折叠时的高度,当设置为 0 时,完全折叠。默认为 100。(这不是行数,而是像素高度值)","This option will allow you use other views when leaf width is not enough. False by default.":"当页面宽度不够时,可以选择其他视图。默认为关闭。","Can select other views when leaf width is not enough":"当页面宽度不够时,可以选择其他视图","TRASH BOX":"回收站","Wait templater to finish parse before insert thino":"在插入 Thino 之前等待 Templater 完成解析","This option will allow you to wait for templater to finish parse before insert thino, which may casue you need to confirm twice between insert thino. False by default.":"此选项将允许您在插入 Thino 之前等待 Templater 完成解析,这可能会导致您在插入 Thino 之间需要确认两次。默认为关闭。","Get thino capture extension":"获取 Thino 剪裁扩展","You can capture idea/text from chrome now.":"你现在可以从 Chrome 中捕获想法/文本。","Open File":"打开文件","Exported CSV file":"导出的 CSV 文件","Updated At":"更新于","Export to CSV":"导出为 CSV","Quick add button on mobile navbar":"移动端导航栏的快速添加按钮","Always show status text":"始终显示状态文本","Support filter by metadata from file":"支持通过文件中的元数据进行筛选","When enable this, you can filter via metadata from file, like tags in file. But thinos from canvas is not supported. False by default.":"启用后,你可以通过文件中的元数据进行筛选,例如文件中的标签。但画布中的 Thino 不支持。默认为关闭。","Show source near timestamp in thino":"在 Thino 时间戳旁显示 Thino 的来源","When enable this, you can see the source near timestamp in thino. You can set title in metadata to overwrite this. False by default.":"启用后,你可以在 Thino 时间戳旁看到 Thino 的来源。你可以在元数据中设置 title 来覆盖文件名。默认为关闭。","Show Update Message":"显示更新消息","Show update message when Thino is updated. True by default":"Thino 更新时显示更新消息。默认为开启","Sync manually":"手动同步","Show all scrollbars":"显示所有滚动条","TIME RANGE":"时间范围",WITHIN:"在内","7 days":"7天","14 days":"14天","30 days":"30天","3 months":"3个月","6 months":"6个月","1 year":"1年","This week":"本周","Last week":"上周","This month":"本月","Last month":"上月","This year":"今年","Last year":"去年","No history":"没有历史记录","Today Remaining":"今日剩余","Today Total":"今日总计","Historical Statistics":"历史统计",byTime:"按时间",byTimeReverse:"按时间反序",Stat:"统计",Statistics:"统计","Daily Thino Count":"每日 Thino 数量",Total:"总计",thinos:"thinos","Thino Types":"Thino 类型","Distribution of thino types":"Thino 类型分布","Thino Status":"Thino 状态","Distribution of thino status":"Thino 状态分布","Popular Tags":"常用标签","Top 10 most used tags":"Top 10 常用标签","Thino Count":"Thino 数量","Hourly distribution":"每小时分布","Current month":"当前月份","Monthly distribution":"每月分布","30 Days":"过去 30 天",Year:"年份","Time Distribution":"时间分布","When do you write thinos":"你什么时候写 Thino","Content Length":"内容长度","Distribution of thino lengths":"Thino 长度分布","Daily Thinos":"每日 Thino","Show Time Distribution":"显示时间分布","Hide date picker":"隐藏日期选择器","Show date picker":"显示日期选择器","Clear filter":"清除筛选","Copy link":"复制链接","Copy embed link":"复制嵌入链接","Ctrl/Cmd + Enter to save thino":"Ctrl/Cmd + Enter 保存 Thino","Fixed strings for thinos":"固定字符串","Use fixed strings for thinos":"使用固定字符串","Enable to add fixed strings at the beginning or end of thinos.":"启用为每个 Thino 添加固定字符串。","Fixed prefix for thinos":"固定前缀","Add this string at the beginning of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"在每个 Thino 的开头添加此字符串。支持占位符,如 {{TIME|YYYYMMDDHHmmss}}。","Fixed suffix for thinos":"固定后缀","Add this string at the end of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"在每个 Thino 的末尾添加此字符串。支持占位符,如 {{TIME|YYYYMMDDHHmmss}}。","Word count exceeded":"字数超出限制","Word count feature":"字数统计","Enable real-time word count display in the editor":"启用实时字数显示","Maximum word count":"最大字数","Set a maximum word count for thino. Editor will display a warning when exceeded. Set to 0 for unlimited.":"设置 Thino 的最大字数。当超过时,编辑器将显示警告。设置为 0 时,没有限制。","No linked thinos found":"没有找到链接的 Thino","Reference links group":"链接组","Enable reference links group in thino.":"在 Thino 中启用链接组。","No reference links found":"没有找到链接","Error fetching reference links":"获取链接失败","Outgoing Links":"出链","Incoming Links":"入链","Double click behavior":"双击行为","Set the behavior when double click on a thino.":"设置双击 Thino 的行为。","Open thino":"打开 Thino","Edit thino":"编辑 Thino","Go to source":"前往来源","Do nothing":"什么都不做","Use default header in mobile view":"使用默认的移动端头部","Use default header in mobile view of thino rather than custom header.":"使用默认的移动端头部,而不是自定义的头部。","Ignore folders for multi type":"忽略多文件类型文件夹","Set folders to ignore when using multi type. Separate multiple folders with comma (,).":"设置多文件类型时忽略的文件夹。用逗号 (,) 分隔多个文件夹。","folder1,folder2/subfolder":"folder1,folder2/subfolder","Using block link when dragging a thino":"拖动 Thino 以插入连结","Using block link when dragging a thino for daily":"拖动 Thino 以插入连结到日记","Matched via tag in content":"通过内容中的标签匹配","Matched via tag in file":"通过文件中的标签匹配","Focus on editor when open":"打开时聚焦编辑器","Focus on editor when open. True by default.":"打开时聚焦编辑器。默认为开启","Show scroll to top button":"显示滚动到顶部按钮","Show scroll to top button. True by default":"显示滚动到顶部按钮。默认为开启","Zoom image by default":"默认缩放图片","Zoom image by default when viewing image.":"查看图片时默认缩放图片。","View archive in random review":"在随机回顾中查看归档的 Thino","View archived thinos in random review. True by default":"在随机回顾中查看归档的 Thino。默认为开启","Linked by":"链接自",Linked:"链接",DUPLICATE:"复制","Show scrollbars in all thino views.":"在所有 Thino 视图中显示滚动条。","Drag to paste content":"拖动粘贴内容","You will be able to paste content from other apps to thino by dragging rather than pasting the block link.":"你可以通过拖动而不是粘贴块链接来将内容从其他应用粘贴到 Thino 中。","Dragging behavior":"拖动行为","Control the behavior when dragging a thino. You will paste the block link by default. Block-link option only works with source type is Daily Note.":"控制拖动 Thino 的行为。默认粘贴块链接。块链接选项仅在源类型为日记时有效。","Block link":"块链接",Text:"文本"},hq={welcome:"歡迎使用 Thino",ribbonIconTitle:"Thino",to:"至",months:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthsShort:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],weekDays:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],weekDaysShort:["日","一","二","三","四","五","六"],year:null,month:null,"Basic Options":"基本選項","User name":"使用者名稱","Set your user name here. 'Memos 😏' By default":"設定您的使用者名稱。預設為 'Thino 😏'",'You can set target heading like "# Heading" to control data location':'您可以設定目標標題如 "# 標題" 來控制資料位置',"Insert after heading":"在標題後插入","If left blank, the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"如果留空,記錄的 thino 內容將插入日記末尾;如果提供標題,所有記錄的 thino 內容將統一歸類在該標題下。","Allows admonitions to be created using ":"允許使用以下方式創建提示 ","Process Memos below":"在以下處理 thino","If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.":"如果留空,Thino 介面將顯示所有 thino 記錄內容;如果提供標題,Thino 介面將只顯示該標題下的內容,其他地方寫的內容將不會顯示。","Save Memo button label":"儲存 thino 按鈕標籤","The text shown on the save Memo button in the UI. 'NOTEIT' by default.":"UI 中儲存 Thino 按鈕顯示的文字。預設為 'NOTEIT'。","Focus on editor when open memos":"開啟 thino 時聚焦編輯器","Focus on editor when open memos. Focus by default.":"開啟 thino 時聚焦編輯器。預設聚焦。","Open daily memos with open memos":"開啟 thino 時開啟每日 thino","Open daily memos with open memos. Open by default.":"開啟 thino 時開啟每日 thino。預設開啟。","Open Memos when obsidian opens":"Obsidian 開啟時開啟 Thino","When enable this, Memos will open when Obsidian opens. False by default.":"啟用此選項時,Obsidian 開啟時將開啟 Thino。預設為關閉。","Hide done tasks in Memo list":"在 Thino 列表中隱藏已完成的任務","Hide all done tasks in Memo list. Show done tasks by default.":"在 Thino 列表中隱藏所有已完成的任務。預設顯示已完成的任務。","Advanced Options":"進階選項","UI language for date":"日期 UI 語言","Translates the date UI language. Only 'en' and 'zh' are available.":"翻譯日期 UI 語言。僅支援 'en' 和 'zh'。","Default prefix when save thino":"儲存 thino 時的預設前綴","Set the default prefix when create memo, 'List' by default.":"創建 thino 時的預設前綴,預設為 'List'。","Default insert date format":"預設插入日期格式","Set the default date format when insert date by @, 'Tasks' by default.":"使用 @ 插入日期時的預設格式,預設為 'Tasks'。","Default editor position on mobile":"行動裝置上的預設編輯器位置","Set the default editor position on Mobile, 'Top' by default.":"設定行動裝置上的預設編輯器位置,預設為 'Top'。","Use button to show editor on mobile":"在行動裝置上使用按鈕顯示編輯器","Set a float button to call editor on mobile. Only when editor located at the bottom works.":"在行動裝置上設定浮動按鈕來呼叫編輯器。僅當編輯器位於底部時有效。","Show Time When Copy Results":"複製結果時顯示時間","Show time when you copy results, like 12:00. Copy time by default.":"複製結果時顯示時間,如 12:00。預設複製時間。","Show Date When Copy Results":"複製結果時顯示日期","Show date when you copy results, like [[2022-01-01]]. Copy date by default.":"複製結果時顯示日期,如 [[2022-01-01]]。預設複製日期。","Add Blank Line Between Different Date":"不同日期間添加空行","Add blank line when copy result with date. No blank line by default.":"複製帶日期的結果時添加空行。預設不添加空行。","Share Options":"分享選項","Share Memos Image Footer Start":"分享 Thino 圖片頁尾開始","Set anything you want here, use {ThinoNum} to display Number of thino, {UsedDay} for days. '{ThinoNum} Thino {UsedDay} Days' By default":"在此設定任何您想要的內容,使用 {ThinoNum} 顯示 thino 數量,{UsedDay} 顯示天數。預設為 '{ThinoNum} Thino {UsedDay} Days'","Share Memos Image Footer End":"分享 Thino 圖片頁尾結束","Set anything you want here, use {UserName} as your username. '✍️ By {UserName}' By default":"在此設定任何您想要的內容,使用 {UserName} 作為您的使用者名稱。預設為 '✍️ By {UserName}'","Save Shared Image To Folder For Mobile":"為行動裝置將分享的圖片儲存到資料夾","Save image to folder for mobile. False by Default":"為行動裝置將圖片儲存到資料夾。預設為關閉","Say Thank You":"說謝謝",Donate:"贊助","If you like this plugin, consider donating to support continued development:":"如果您喜歡這個外掛,請考慮贊助以支持持續開發:","File Name of Recycle Bin":"回收桶檔案名稱","Set the filename for recycle bin. 'delete' By default":"設定回收桶的檔案名稱。預設為 'delete'","File Name of Query File":"查詢檔案名稱","Set the filename for query file. 'query' By default":"設定查詢檔案的檔案名稱。預設為 'query'","Use Tags In Vault":"使用儲存庫中的標籤","Use tags in vault rather than only in Memos. False by default.":"使用儲存庫中的標籤而不是僅在 Thino 中使用。預設為關閉。","Ready to convert image into background":"準備將圖片轉換為背景",List:"列表",Task:"任務",Top:"頂部",Bottom:"底部",TAG:"標籤",DAY:"日",QUERY:"查詢",EDIT:"編輯",PIN:"釘選",UNPIN:"取消釘選",DELETE:"刪除","CONFIRM!":"確認!","CREATE FILTER":"創建過濾器","Comment it...":"添加評論...",Settings:"設定","Recycle bin":"回收桶","About Me":"關於我","Fetching data...":"獲取資料中...","Here is No Memos.":"這裡沒有 Thino。","Frequently Used Tags":"常用標籤","What do you think now...":"你現在在想什麼...",READ:"閱讀",MARK:"標記",SHARE:"分享",SOURCE:"來源",RESTORE:"還原",ARCHIVE:"封存","Daily Review":"每日回顧","DELETE AT":"刪除於","Noooop!":"不要!","All Data is Loaded 🎉":"所有資料已載入 🎉","Quick filter":"快速過濾",TYPE:"類型",LINKED:"已連結","NO TAGS":"無標籤","HAS LINKS":"有連結","HAS IMAGES":"有圖片",INCLUDE:"包含",EXCLUDE:"排除",TEXT:"文字",IS:"是",AND:"且",OR:"或",LIST:"列表",ISNOT:"不是",PATH:"路徑",METADATA:"元資料",SELECT:"選擇","ADD FILTER TERMS":"添加過濾條件",FILTER:"過濾",Filter:"過濾",TITLE:"標題","CREATE QUERY":"創建查詢","EDIT QUERY":"編輯查詢",MATCH:"匹配",TIMES:"次數","Share Memo Image":"分享 Thino 圖片","↗Click the button to save":"↗點擊按鈕儲存","Image is generating...":"圖片生成中...","Image is loading...":"圖片載入中...","Loading...":"載入中...","😟 Cannot load image, image link maybe broken":"😟 無法載入圖片,圖片連結可能已損壞","Daily Memos":"每日 Thino","CANCEL EDIT":"取消編輯","LINK TO THE":"連結到","Mobile Options":"行動裝置選項","Experimental Options":"實驗性選項","Don't support web image yet, please input image path in vault":"尚不支援網路圖片,請輸入儲存庫中的圖片路徑","Background Image in Dark Theme":"深色主題背景圖片","Background Image in Light Theme":"淺色主題背景圖片",'Set background image in dark theme. Set something like "Daily/one.png"':'設定深色主題的背景圖片。設定類似 "Daily/one.png" 的路徑','Set background image in light theme. Set something like "Daily/one.png"':'設定淺色主題的背景圖片。設定類似 "Daily/one.png" 的路徑','Set default memo composition, you should use {TIME} as "HH:mm" and {CONTENT} as content. "{TIME} {CONTENT}" by default':'設定預設 thino 組成,您應該使用 {TIME} 作為 "HH:mm" 和 {CONTENT} 作為內容。預設為 "{TIME} {CONTENT}"',"Default Memo Composition":"[已棄用] 預設 Thino 組成","Show Tasks Label":"顯示任務標籤","Show tasks label near the time text. False by default":"在時間文字旁顯示任務標籤。預設為關閉","Please Open Memos First":"請先開啟 Thino",DATE:"日期",OBSIDIAN_NLDATES_PLUGIN_NOT_ENABLED:"OBSIDIAN_NLDATES_PLUGIN_未啟用",BEFORE:"之前",AFTER:"之後","Allow Comments On Memos":"允許在 Thino 上評論","You can comment on memos. False by default":"您可以在 thino 上評論。預設為關閉",Import:"匯入","TITLE CANNOT BE NULL!":"標題不能為空!","FILTER CANNOT BE NULL!":"過濾器不能為空!","Comments In Original DailyNotes/Notes":"原始每日筆記/筆記中的評論","You should install Dataview Plugin ver 0.5.9 or later to use this feature.":"您需要安裝 Dataview 外掛 0.5.9 或更新版本才能使用此功能。","Open Memos Successfully":"成功開啟 Thino","Fetch Memos Error":"😭 獲取錯誤","Copied to clipboard Successfully":"成功複製到剪貼簿","Check if you opened Daily Notes Plugin Or Periodic Notes Plugin":"請檢查是否已開啟每日筆記外掛或定期筆記外掛","Please finish the last filter setting first":"請先完成上一個過濾器設定","Close Memos Successfully":"成功關閉 Thino","Insert as Memo":"插入為 Thino","Insert file as memo content":"將檔案插入為 thino 內容","Image load failed":"圖片載入失敗","Content cannot be empty":"內容不能為空","Unable to create new file.":"無法創建新檔案。","Failed to fetch deleted memos: ":"獲取已刪除的 thino 失敗:","RESTORE SUCCEED":"還原成功","DELETE SUCCEED":"刪除成功","Save Memo button icon":"儲存 Thino 按鈕圖示","The icon shown on the save Memo button in the UI.":"UI 中儲存 Thino 按鈕顯示的圖示。","Fetch Memos From Particular Notes":"從特定筆記獲取 Thino",'You can set any Dataview Query for memos to fetch it. All memos in those notes will show on list. "#memo" by default':'您可以為 thino 設定任何 Dataview 查詢來獲取它。這些筆記中的所有 thino 都會顯示在列表中。預設為 "#memo"',"Allow Memos to Fetch Memo from Notes":"允許 Thino 從筆記中獲取 Thino","Use Memos to manage all memos in your notes, not only in daily notes. False by default":"使用 Thino 管理您筆記中的所有 thino,而不僅僅是每日筆記中的。預設為關閉","Always Show Memo Comments":"始終顯示 Thino 評論","Always show memo comments on memos. False by default":"始終在 thino 上顯示評論。預設為關閉","You didn't set folder for daily notes in both periodic-notes and daily-notes plugins.":"您尚未在定期筆記和每日筆記外掛中設定每日筆記的資料夾。","Please check your daily note plugin OR periodic notes plugin settings":"請檢查您的每日筆記外掛或定期筆記外掛設定","Use which plugin's default configuration":"使用哪個外掛的預設配置","Memos use the plugin's default configuration to fetch memos from daily, 'Daily' by default.":"Thino 使用外掛的預設配置從每日筆記中獲取 thino,預設為 'Daily'。",Daily:"每日","Always Show Leaf Sidebar on PC":"在 PC 上始終顯示葉面側邊欄","Show left sidebar on PC/Tablet even when the leaf width is less than 875px. False by default.":"即使葉面寬度小於 875px,也在 PC/平板上顯示左側邊欄。預設為關閉。","You didn't set format for daily notes in both periodic-notes and daily-notes plugins.":"您尚未在定期筆記和每日筆記外掛中設定每日筆記的格式。","fetch more":"獲取更多","Search all settings":"搜尋所有設定",General:"一般",Theme:"主題",Share:"分享",Advanced:"進階",Interface:"介面",Thino:"Thino","Random Review":"隨機回顧","ARCHIVED AT":"封存於","Failed to get memos from daily notes":"從每日筆記獲取 thino 失敗","Failed to delete memo":"刪除 thino 失敗","CTRL + ENTER to save":"CTRL + ENTER 儲存","Started from":"開始於","Custom Background Image":"自訂背景圖片","Set custom background image.":"設定自訂背景圖片。","Custom Memo Footer":"自訂 Thino 頁尾","Set custom memo footer.":"設定自訂 thino 頁尾。","Heatmap Color Scheme":"熱圖顏色方案","Set different color scheme for heatmap.":"為熱圖設定不同的顏色方案。","Enable Local Http Server":"啟用本地 Http 伺服器","Memos Http Server Port":"Thino Http 伺服器埠","Set memos http server port to listen. '43999' by default":"設定 thino http 伺服器監聽埠。預設為 '43999'","Default Editor Mode":"預設編輯器模式","Live-Preview Mode OR Source Mode.":"即時預覽模式或原始碼模式。","Save type for Thino":"Thino 的儲存類型",DAILY:"每日",MULTI:"多個",CANVAS:"畫布",ALL:"全部",FILE:"檔案",TODO:"待辦",DONE:"已完成",JOURNAL:"日誌",OTHER:"其他","Failed to create daily note, check if it exists.":"創建每日筆記失敗,請檢查是否已存在。","Failed to create daily note. Please check if you created a folder for daily notes.":"創建每日筆記失敗。請檢查是否已創建每日筆記的資料夾。","After you verify your account, please refresh this page.":"驗證帳號後,請重新整理此頁面。",Verify:"驗證","Oops! You forget to verify insider account":"糟糕!您忘記驗證內部帳號","If you have any questions, please contact us.":"如果您有任何問題,請聯繫我們。","Delete Thino Directly":"直接刪除 Thino","When delete thino directly, it will not be moved to trash. False by default.":"直接刪除 thino 時,不會移至垃圾桶。預設為關閉。","Enable opening thino globally":"啟用全域開啟 thino","Enable opening thino globally. False by default.":"啟用全域開啟 thino。預設為關閉。","Key for opening thino globally":"全域開啟 thino 的快速鍵","Set key for opening thino globally. CTRL + SHIFT + T by default.":"設定全域開啟 thino 的快速鍵。預設為 CTRL + SHIFT + T。","Key for showing thino globally":"全域顯示 thino 的快速鍵","Set key for showing thino globally. CTRL + SHIFT + E by default.":"設定全域顯示 thino 的快速鍵。預設為 CTRL + SHIFT + E。","Get activation code":"獲取啟用碼","Input activation code here":"在此輸入啟用碼","Copy Thino id":"複製 Thino id","Activate Pro Version":"啟用專業版","Please copy Thino id first":"請先複製 Thino id",'You can set folder name with file name like "folder/file"':'您可以設定帶有檔案名稱的資料夾名稱,如 "folder/file"','You can set folder name like "folder1/folder2/folder3" to create sub-folder':'您可以設定如 "folder1/folder2/folder3" 的資料夾名稱來創建子資料夾',"Default save type":"預設儲存位置",'Set the default save type for thino. "DAILY" by default':'設定 thino 的預設儲存類型。預設為 "DAILY"',"Sync Thino via PKMer":"通過 PKMer 同步 Thino",Unlink:"取消連結",Link:"連結","Connect to PKMer Sync, you can check it in ":"連接到 PKMer 同步,您可以在此檢查 ","PKMer Sync":"PKMer 同步","Remove successfully":"移除成功",Deactivate:"停用",Remove:"移除","Confirm?":"確認?","Sync Status":"同步狀態","Start or stop sync":"開始或停止同步","Stop sync successfully":"成功停止同步","Start sync successfully":"成功開始同步",Stop:"停止",Start:"開始","Show thino near mouse":"在滑鼠附近顯示 thino","Query not found":"未找到查詢","Send to clipboard successfully":"成功發送到剪貼簿","Thino - Failed to start HTTP server, please check the port is available.":"Thino - 啟動 HTTP 伺服器失敗,請檢查埠是否可用。","Thino - Started HTTP server on port":"Thino - 在埠口啟動 HTTP 伺服器","Thino - Terminated HTTP server":"Thino - 終止 HTTP 伺服器","File not exist":"檔案不存在","Thino not found":"未找到 Thino","File not found for the given thino path, is creating a new file":"未找到給定 thino 路徑的檔案,正在創建新檔案","Saved sync token successfully":"成功儲存同步令牌","Failed to find daily notes folder":"找不到每日筆記資料夾","Please install obsidian-hover-editor plugin first":"請先安裝 obsidian-hover-editor 外掛","Copied app id successfully":"成功複製應用程式 id","Please input token first":"請先輸入令牌","Please enable sync first":"請先啟用同步","Init Failed":"初始化失敗","Verify successfully":"驗證成功","Failed to verify":"驗證失敗","Folder not found for the given thino path, is creating a new folder":"未找到給定 thino 路徑的資料夾,正在創建新資料夾","File not found for the given thino path":"未找到給定 thino 路徑的檔案","Failed to read current daily note, check if it exists.":"讀取當前每日筆記失敗,請檢查是否存在。","Failed to save":"儲存失敗","Failed to login, please login again":"登入失敗,請重新登入","COPY FAILED":"複製失敗","COPY SUCCEED":"複製成功","Copy selected text":"複製選定文字","Copy thino":"複製 thino",COPY:"複製","This is a pro feature, please upgrade to pro version to use it.":"這是專業版功能,請升級到專業版以使用。","You can get pro version from: ":"您可以從以下位置獲取專業版:",Save:"儲存",Cancel:"取消","Thino Daily Target":"Thino 每日目標",Input:"輸入","#Tag":"#標籤","to create tag":"創建標籤","You have verified your account. Congrats!":"您已驗證您的帳號。恭喜!","Pro features":"專業版功能","Target Thino Count":"目標 Thino 數量",on:"開啟","Switch waterfall view":"切換瀑布流視圖","Switch view":"切換視圖","Switch list view":"切換列表視圖","Set daily target":"設定每日目標","Thino Save To: ":"Thino 儲存至:","Enter fullscreen mode":"進入全螢幕模式","Exit fullscreen mode":"退出全螢幕模式",words:"字",word:"字","Return To Home Page":"返回首頁","No thinos to review!":"沒有要回顧的 thino!","Thinos to review":"要回顧的 thino","Start Review":"開始回顧",Hard:"困難",Good:"良好",Easy:"簡單",Again:"再次","Clear all review data":"清除所有回顧資料","Daily Progress":"每日進度","Show stats":"顯示統計","Hide stats":"隱藏統計",Remaining:"剩餘","Total Reviews":"總回顧次數","Today, you have reviewed all your thinos!":"今天,您已回顧完所有 thino!","Daily review limit reached! Come back tomorrow.":"已達到每日回顧限制!明天再來。","Open thino in center window":"在中央視窗開啟 thino","Open thino in float window":"在浮動視窗開啟 thino","Open thino in right sidebar":"在右側邊欄開啟 thino","Open thino in left sidebar":"在左側邊欄開啟 thino","Show thino editor":"顯示 thino 編輯器","Toggle minimal mode":"切換最小化模式","Focus on thino editor":"聚焦 thino 編輯器","ReSync web thinos to local":"重新同步網路 thino 到本地","Sync local thinos to web":"同步本地 thino 到網路","Show daily thino":"顯示每日 thino","Focus on search bar":"聚焦搜尋欄","Show-thino in popover(Hover editor)":"在彈出視窗中顯示 thino(懸停編輯器)","Center window":"中央視窗","Float window":"浮動視窗","Right sidebar":"右側邊欄","Left sidebar":"左側邊欄","Save thino type when sync local":"同步本地時儲存 thino 類型","Set the default save thino type when sync local, FILE by default.":"設定同步本地時的預設儲存 thino 類型,預設為檔案。","Sync service":"同步服務","Pro verification status":"專業版驗證狀態","Live-preview":"即時預覽",Source:"來源","Global copy":"全域複製","Set the folder name":"設定資料夾名稱","Set the filename":"設定檔案名稱","Set the filename for current location file":"設定目前位置檔案的檔案名稱","Switch calendar type":"切換日曆類型",alphabetical:"按字母順序",alphabeticalReverse:"按字母倒序",byCount:"按數量",byCountReverse:"按數量倒序","Type here":"在此輸入",Today:"今天",Yesterday:"昨天","Last 7 days":"最近 7 天","Last 30 days":"最近 30 天","Last 90 days":"最近 90 天","Last 180 days":"最近 180 天","Last 365 days":"最近 365 天",Found:"找到","Copy filtered thinos":"複製已篩選的 thinos","Bulk delete":"批量刪除","Bulk archive":"批量歸檔","Bulk tag operation":"批量標籤操作","Bulk restore":"批量還原","If you are disabling the daily note plugin, it would be possible that the thino will not be deleted or patched properly. Please enable the plugin and try again.":"如果您停用了每日筆記外掛程式,thino 可能無法正確刪除或修補。請啟用外掛程式後重試。",Preview:"預覽","Set and save":"設定並儲存","Show day mark in thino list":"在 thino 列表中顯示日期標記","Show day mark on the top of daily range thino. False by default.":"在每日範圍 thino 頂部顯示日期標記。預設為否。","Click to expand or fold, Cmd+Click to show all thinos of the day":"點擊展開或摺疊,Cmd+點擊顯示當天所有 thinos","You can buy a license from":"您可以從以下位置購買授權:","No thinos in range":"範圍內沒有 thinos",Month:"月",Week:"週",Day:"日",Agenda:"議程",Tomorrow:"明天",Previous:"上一個",Next:"下一個","Search all columns...":"搜尋所有欄位...","Basic Info":"基本資訊","Additional Info":"額外資訊","Created At":"建立時間",Content:"內容","Thino Type":"Thino 類型","Source Type":"來源類型","Row status":"行狀態",Path:"路徑","Pinned Status":"釘選狀態",Table:"表格",Chat:"聊天",Moments:"動態",Waterfall:"瀑布流",Calendar:"日曆","Go to page":"前往頁面",Page:"頁面",Show:"顯示",rows:"行","Temp Filter":"臨時篩選","Open link directly in Thino view":"在 Thino 視圖中直接開啟連結","Day mark range":"日期標記範圍","Set the range of day mark. Day by default.":"設定日期標記範圍。預設為日。","Thino is locked":"Thino 已鎖定","Please unlock Thino by input password":"請輸入密碼解鎖 Thino","Auto Download Image":"自動下載圖片","Auto download image when save to thino. 'false' by default":"儲存到 thino 時自動下載圖片。預設為否。","Thino Http IP Type":"Thino Http IP 類型","Set Thino http server ip to listen. 'localhost' by default":"設定 Thino http 伺服器監聽的 IP。預設為 localhost。","Password to lock Thino":"鎖定 Thino 的密碼",Unlock:"解鎖",Locked:"已鎖定","Password is incorrect":"密碼錯誤",Lock:"鎖定","Need password to unlock Thino":"需要密碼解鎖 Thino","You have not set a password or enable this feature yet":"您尚未設定密碼或啟用此功能",Password:"密碼","Password for Thino":"Thino 的密碼","Please input your password to change password settings":"請輸入密碼以更改密碼設定","Please input your password":"請輸入密碼","Lock thino":"鎖定 thino",date:"日期",time:"時間",event:"事件","Add tag position":"新增標籤位置","Set the position of the tag when adding tag automatically":"設定自動新增標籤時的位置","Add tag automatically":"自動新增標籤","Add tag to the end or beginning of the thino content when creating a thino and filtering tags":"建立 thino 和篩選標籤時,在 thino 內容的結尾或開頭新增標籤","Add tag with new line":"換行新增標籤","Add tag with new line when adding tag automatically":"自動新增標籤時換行","Input to select more tags":"輸入以選擇更多標籤","Tag Bulk Edit":"標籤批量編輯","Tag Bulk Select":"標籤批量選擇","Exist Tags":"現有標籤","Selected Tags":"已選標籤","Click to remove exist tag":"點擊移除現有標籤","Click to remove selected tag":"點擊移除已選標籤","Select tags":"選擇標籤","Input to select exist tag":"輸入以選擇現有標籤",Beginning:"開頭",End:"結尾","Set the heading for saving thino":"設定儲存 thino 的標題","# Heading":"# 標題","Chat view style":"聊天視圖樣式","Set the style of chat view":"設定聊天視圖的樣式","Background image for moments view":"動態視圖的背景圖片","Set the background image for moments view":"設定動態視圖的背景圖片","Icon for moments/chat view/share image":"動態/聊天視圖/分享圖片的圖示","Set the icon for moments/chat view/share image":"設定動態/聊天視圖/分享圖片的圖示","Quote for moments view/share image":"動態視圖/分享圖片的引言","Set the quote for moments view/share image":"設定動態視圖/分享圖片的引言","Theme for Thino":"Thino 主題","Set the theme for Thino":"設定 Thino 主題","Interface Details":"介面詳情","Task amount":"任務數量","Thino status":"Thino 狀態","Used tags":"已使用標籤","Used days":"已使用天數","Most active day":"最活躍日","Most active hour":"最活躍時段","Thino amount":"Thino 數量","No content to generate.":"沒有內容可生成。","Image generated successfully.":"圖片生成成功。","Failed to generate image.":"圖片生成失敗。","Share filtered thinos as image":"將已篩選的 thinos 分享為圖片","Latest version":"最新版本","Previous version":"上一版本","Thino update info":"Thino 更新資訊","Debug info copied to clipboard":"除錯資訊已複製到剪貼簿","Copy debug info":"複製除錯資訊","Failed to load changelog":"載入更新日誌失敗","View online":"線上檢視",ChangeLog:"更新日誌","Please open thino first":"請先開啟 thino","Insert editor":"插入編輯器","Please set different save locations for multi-file settings in Thino. The diary folder overlaps with the multi-file save location, or there is a risk of it being read repeatedly.":"請為 Thino 的多檔案設定設定不同的儲存位置。日記資料夾與多檔案儲存位置重疊,或有重複讀取的風險。","Default time prefix for thino in daily notes":"每日筆記中 thino 的預設時間前綴","Set default time prefix for thino in daily notes.":"設定每日筆記中 thino 的預設時間前綴。","Save image successfully":"圖片儲存成功","User quote":"使用者引言","Set user quote for thino":"設定 thino 的使用者引言","User icon":"使用者圖示","Set user icon for thino. You can input http/https link or file path in vault.":"設定 thino 的使用者圖示。您可以輸入 http/https 連結或儲存庫中的檔案路徑。","User info":"使用者資訊","Copy filtered results":"複製篩選結果","Share image":"分享圖片",Default:"預設",Gray:"灰色",Grass:"草綠",Flame:"火焰",Olive:"橄欖",Ice:"冰藍",Magenta:"洋紅","Daily notes":"每日筆記",Editor:"編輯器","Append/prepend text when share to Thino":"分享到 Thino 時附加/前置文字","Append text when share to Thino":"分享到 Thino 時附加文字","Prepend text when share to Thino":"分享到 Thino 時前置文字","Add newline when append/prepend text":"附加/前置文字時換行","Input anything here":"在此輸入任何內容",Prepend:"前置",Append:"附加",Both:"兩者",None:"無","Hide pinned group":"隱藏釘選群組","Hide pinned group in thino list. False by default.":"在 thino 列表中隱藏釘選群組。預設為否。","Set the heading for the task type of thino, by default the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.":"設定任務類型 thino 的標題,預設情況下,記錄的 thino 內容將插入日記末尾;如果提供標題,所有記錄的 thino 內容將統一歸類在該標題下。","Different insert target for different type":"不同類型的不同插入目標","Toggle this to set different insert target for different type of thino, like task or list type of thino":"切換此選項以為不同類型的 thino 設定不同的插入目標,如任務或列表類型的 thino","You can set whole diary or only part of it":"您可以設定整個日記或僅部分內容","Set process target":"設定處理目標",Custom:"自訂","Whole diary":"整個日記","Set thino insert place":"設定 thino 插入位置","Set where to insert thino content":"設定插入 thino 內容的位置","End of the diary":"日記末尾","Custom location":"自訂位置","Setting guide":"設定指南","Details settings":"詳細設定","Start Thino":"開始使用 Thino","About Thino Pro":"關於 Thino Pro",Enabled:"已啟用",Enable:"啟用","Daily notes folder":"每日筆記資料夾","Set daily notes folder":"設定每日筆記資料夾","Daily note name format":"每日筆記名稱格式","Set daily note name format":"設定每日筆記名稱格式","Daily note plugin":"每日筆記外掛程式","Enable daily note plugin":"啟用每日筆記外掛程式",Selected:"已選擇",Select:"選擇","A classic theme for Thino with a two-column layout":"具有雙欄佈局的 Thino 經典主題",Classic:"經典","A modern theme for Thino with a three-column layout and some unique features.":"具有三欄佈局和一些獨特功能的 Thino 現代主題。",Modern:"現代","Go and enjoy Thino":"開始使用並享受 Thino","Congrats! All settings done":"恭喜!所有設定已完成","Adjust settings that influence your user experience with Thino.":"調整影響您使用 Thino 體驗的設定。","Set preferences for using Thino":"設定使用 Thino 的偏好","If you are using the Thino basic version, enabling the daily note plugin is required. Configure its settings to work effectively with it.":"如果您使用的是 Thino 基本版,需要啟用每日筆記外掛程式。配置其設定以有效使用。","Go with daily note plugin":"使用每日筆記外掛程式","Choose a theme for Thino.":"為 Thino 選擇主題。","Set theme for Thino":"設定 Thino 主題","Set up your user info for Thino.":"設定您的 Thino 使用者資訊。","Get started with Thino":"開始使用 Thino","Skip and start Thino":"跳過並開始使用 Thino","Next step":"下一步","Back to previous step":"返回上一步","Click to enable =>":"點擊啟用 =>","This is Thino's sidebar. Navigate to different path or select query filter.":"這是 Thino 的側邊欄。導航到不同路徑或選擇查詢篩選器。","Click here and go to settings page.":"點擊此處前往設定頁面。","Click here and go to different path.":"點擊此處前往不同路徑。","Select or create query filter here.":"在此選擇或建立查詢篩選器。","See the status of Thinos here.":"在此查看 Thinos 的狀態。","Search your thino quickly here.":"在此快速搜尋您的 thino。","Edit or create your thino here.":"在此編輯或建立您的 thino。","See your thinos here.":"在此查看您的 thinos。","See your time status of thinos here.":"在此查看您的 thinos 時間狀態。","See your tags here. Tags will be shown when thino contains tags.":"在此查看您的標籤。當 thino 包含標籤時會顯示標籤。",Done:"完成","Thino is ready to use. ":"Thino 已準備就緒。","You can start using Thino now. If you want to know more about Thino Pro, click the button below.":"您現在可以開始使用 Thino。如果您想了解更多關於 Thino Pro 的資訊,請點擊下方按鈕。","Default time prefix":"預設時間前綴","Append Text Action":"附加文字動作","Prepend Text Action":"前置文字動作",Preset:"預設","Select Tags":"選擇標籤","It is not available on small view":"在小視圖中不可用","Append text":"附加文字","Prepend text":"前置文字","Your daily note folder is not set correctly, please check your settings":"您的每日筆記資料夾設定不正確,請檢查您的設定","Default sharing style":"預設分享樣式","Set the default style for sharing thino, 'Modern' by default.":"設定分享 thino 的預設樣式,預設為「現代」。",Clean:"簡潔",Minimal:"極簡",Gradient:"漸層","Thino share":"Thino 分享","Copy to clipboard failed":"複製到剪貼簿失敗","Copy to clipboard successfully":"成功複製到剪貼簿","Your content has been copied to clipboard, and inserted into the editor. Please try it again":"您的內容已複製到剪貼簿,並插入到編輯器中。請重試","Share thino":"分享 thino","Set file name after create thino":"建立 thino 後設定檔案名稱","You can set file name after create thino. A input box will show when you create thino.":"您可以在建立 thino 後設定檔案名稱。建立 thino 時會顯示輸入框。",SPLIT:"分割","Split by Heading 1":"按一級標題分割","Split by Heading 2":"按二級標題分割","Split by Heading 3":"按三級標題分割","Insert task":"插入任務","All settings have been reset to default.":"所有設定已重設為預設值。","Reset all Thino settings":"重設所有 Thino 設定","Reset settings":"重設設定","Reset Thino settings to default settings.":"將 Thino 設定重設為預設設定。","Task Management":"任務管理","Append completed date when task done in thino":"在 thino 中完成任務時附加完成日期","Append completed date when task done in thino. False by default":"在 thino 中完成任務時附加完成日期。預設為否","Set tag for single file that Thino indexes":"設定 Thino 索引的單一檔案的標籤","When you set a tag here, Thino will index this file contains this tag and show it in the list. Don't need to add `#`.":"當您在此設定標籤時,Thino 將索引包含此標籤的檔案並在列表中顯示。不需要加上 `#`。","Set tag for file type file":"設定檔案類型檔案的標籤","Set tag for multi type file":"設定多類型檔案的標籤","Please input the tag":"請輸入標籤","Merge thinos in to thino share image":"將 thinos 合併到 thino 分享圖片中","Custom height for Thino content":"自訂 Thino 內容高度","Set custom height for Thino content. Like 200px or 20rem":"設定 Thino 內容的自訂高度。如 200px 或 20rem","Input height":"輸入高度","Submit issue":"提交問題","Current version":"目前版本","Bug report":"錯誤回報","Click the button to copy debug info and open the issue page":"點擊按鈕複製除錯資訊並開啟問題頁面","Copy and go":"複製並前往","Debug info copied":"除錯資訊已複製","Feature request":"功能請求","Submit your feature request to the issue page":"將您的功能請求提交到問題頁面",Go:"前往","Toggle query list visibility":"切換查詢列表可見性","Toggle tags visibility":"切換標籤可見性","Toggle sidebar visibility":"切換側邊欄可見性",Collapse:"摺疊",Expand:"展開","Max height for collapse":"摺疊的最大高度","The max height for thino collapse, when set 0, thino would not collapse. 0 by default. (This is not lines count, it is height in px.)":"thino 摺疊的最大高度,設為 0 時 thino 不會摺疊。預設為 0。(這不是行數,而是以像素為單位的高度。)","Render content":"渲染內容","Optimize for Callout":"優化 Callout","Won't render content contains more than 3 callouts automatically. True by default":"不會自動渲染包含超過 3 個 callouts 的內容。預設為是","The value should be greater than":"值應大於","Append Text":"附加文字","Prepend Text":"前置文字","Thino height when collapsed":"Thino 摺疊時的高度","The height for thino when it is collapsed, when set 0, thino would not collapse. 100 by default. (This is not lines count, it is height in px.)":"thino 摺疊時的高度,設為 0 時 thino 不會摺疊。預設為 100。(這不是行數,而是以像素為單位的高度。)","This option will allow you use other views when leaf width is not enough. False by default.":"此選項將允許您在葉寬度不足時使用其他視圖。預設為否。","Can select other views when leaf width is not enough":"當葉寬度不足時可以選擇其他視圖","TRASH BOX":"垃圾箱","Wait templater to finish parse before insert thino":"在插入 thino 前等待模板解析完成","This option will allow you to wait for templater to finish parse before insert thino, which may casue you need to confirm twice between insert thino. False by default.":"此選項將允許您在插入 thino 前等待模板解析完成,這可能導致您需要在插入 thino 時確認兩次。預設為否。","Get thino capture extension":"獲取 thino 擷取擴充功能","You can capture idea/text from chrome now.":"您現在可以從 Chrome 擷取想法/文字。","Open File":"開啟檔案","Exported CSV file":"匯出的 CSV 檔案","Updated At":"更新時間","Export to CSV":"匯出為 CSV","Quick add button on mobile navbar":"行動導航欄上的快速新增按鈕","Always show status text":"始終顯示狀態文字","Support filter by metadata from file":"支援從檔案中的元資料進行篩選","When enable this, you can filter via metadata from file, like tags in file. But thinos from canvas is not supported. False by default.":"啟用此選項後,您可以通過檔案中的元資料進行篩選,如檔案中的標籤。但不支援來自畫布的 thinos。預設為否。","Show source near timestamp in thino":"在 thino 中的時間戳記附近顯示來源","When enable this, you can see the source near timestamp in thino. You can set title in metadata to overwrite this. False by default.":"啟用此選項後,您可以在 thino 中的時間戳記附近看到來源。您可以在元資料中設定標題來覆寫此設定。預設為否。","Show Update Message":"顯示更新訊息","Show update message when Thino is updated. True by default":"Thino 更新時顯示更新訊息。預設為是","Sync manually":"手動同步","Show all scrollbars":"顯示所有捲軸","TIME RANGE":"時間範圍",WITHIN:"在","7 days":"7 天","14 days":"14 天","30 days":"30 天","3 months":"3 個月","6 months":"6 個月","1 year":"1 年","This week":"本週","Last week":"上週","This month":"本月","Last month":"上月","This year":"今年","Last year":"去年","No history":"無歷史記錄","Today Remaining":"今日剩餘","Today Total":"今日總計","Historical Statistics":"歷史統計",byTime:"按時間",byTimeReverse:"按時間倒序",Stat:"統計",Statistics:"統計資料","Daily Thino Count":"每日 Thino 數量",Total:"總計",thinos:"thinos","Thino Types":"Thino 類型","Distribution of thino types":"Thino 類型分佈","Thino Status":"Thino 狀態","Distribution of thino status":"Thino 狀態分佈","Popular Tags":"熱門標籤","Top 10 most used tags":"前 10 個最常用標籤","Thino Count":"Thino 數量","Hourly distribution":"每小時分佈","Current month":"本月","Monthly distribution":"每月分佈","30 Days":"最近 30 天",Year:"年","Time Distribution":"時間分佈","When do you write thinos":"您何時寫 thinos","Content Length":"內容長度","Distribution of thino lengths":"Thino 長度分佈","Daily Thinos":"每日 Thinos","Show Time Distribution":"顯示時間分佈","Hide date picker":"隱藏日期選擇器","Show date picker":"顯示日期選擇器","Clear filter":"清除篩選","Copy link":"複製連結","Copy embed link":"複製嵌入連結","Ctrl/Cmd + Enter to save thino":"Ctrl/Cmd + Enter 儲存 thino","Fixed strings for thinos":"Thinos 的固定字串","Use fixed strings for thinos":"使用 thinos 的固定字串","Enable to add fixed strings at the beginning or end of thinos.":"啟用在 thinos 的開頭或結尾新增固定字串。","Fixed prefix for thinos":"Thinos 的固定前綴","Add this string at the beginning of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"在每個 thino 的開頭添加此字串。支援像 {{TIME|YYYYMMDDHHmmss}} 這樣的佔位符。","Fixed suffix for thinos":"Thinos 的固定後綴","Add this string at the end of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.":"在每個 thino 的結尾添加此字串。支援像 {{TIME|YYYYMMDDHHmmss}} 這樣的佔位符。","Word count exceeded":"字數超出限制","Word count feature":"字數統計功能","Enable real-time word count display in the editor":"在編輯器中啟用即時字數顯示","Maximum word count":"最大字數","Set a maximum word count for thino. Editor will display a warning when exceeded. Set to 0 for unlimited.":"為 thino 設定最大字數。超出時編輯器將顯示警告。設為 0 則無限制。","No linked thinos found":"未找到相關連結的 thinos","Reference links group":"參考連結群組","Enable reference links group in thino.":"在 thino 中啟用參考連結群組。","No reference links found":"未找到參考連結","Outgoing Links":"外部連結","Incoming Links":"內部連結","Error fetching reference links":"獲取參考連結時出錯","Double click behavior":"雙擊行為","Set the behavior when double click on a thino.":"設定在 thino 上雙擊時的行為。","Open thino":"開啟 thino","Edit thino":"編輯 thino","Go to source":"前往來源","Do nothing":"不做任何操作","Use default header in mobile view":"在行動裝置視圖中使用預設標頭","Use default header in mobile view of thino rather than custom header.":"在 thino 的行動裝置視圖中使用預設標頭而非自定義標頭。","Ignore folders for multi type":"忽略多文件類型文件夾","Set folders to ignore when using multi type. Separate multiple folders with comma (,).":"設置多文件類型時忽略的文件夾。用逗號 (,) 分隔多個文件夾。","folder1,folder2/subfolder":"folder1,folder2/subfolder","Using block link when dragging a thino":"拖動 thino 以插入連結","Using block link when dragging a thino for daily":"拖動 thino 以插入連結到日記","Matched via tag in content":"通過內容中的標籤匹配","Matched via tag in file":"通過文件中的標籤匹配","Focus on editor when open":"打開時聚焦編輯器","Focus on editor when open. True by default.":"打開時聚焦編輯器。默認為開啟","Show scroll to top button":"顯示滾動到頂部按鈕","Show scroll to top button. True by default":"顯示滾動到頂部按鈕。默認為開啟","Zoom image by default":"預設縮放圖片","Zoom image by default when viewing image.":"查看圖片時預設縮放圖片。","View archive in random review":"在隨機回顧中查看歸檔的 Thino","View archived thinos in random review. True by default":"在隨機回顧中查看歸檔的 Thino。默認為開啟","Linked by":"鏈接自",Linked:"鏈接",DUPLICATE:"複製","Show scrollbars in all thino views.":"在所有 Thino 視圖中顯示滾動條。","Drag to paste content":"拖動粘貼內容","You will be able to paste content from other apps to thino by dragging rather than pasting the block link.":"您將能夠通過拖動而不是粘貼塊鏈接來將內容從其他應用程序粘貼到 Thino 中。","Dragging behavior":"拖動行為","Control the behavior when dragging a thino. You will paste the block link by default. Block-link option only works with source type is Daily Note.":"控制拖動 Thino 的行為。默認粘貼塊鏈接。塊鏈接選項僅在源類型為日記時有效。","Block link":"塊鏈接",Text:"文本"},pq={ar:G$,cs:Z$,da:$$,de:q$,en:P8,"en-gb":K$,es:X$,fr:J$,hi:Q$,id:eq,it:tq,ja:nq,ko:rq,nl:oq,nn:iq,pl:aq,pt:sq,"pt-br":lq,ro:cq,ru:uq,tr:dq,"zh-cn":fq,"zh-tw":hq},RP=pq[N.moment.locale()];function E(e){const t=RP&&RP[e]||P8[e];return t===null?t:t||e}const mq=/```([\s\S]*?)```/g,gq=/\*\*(.+?)\*\*/g,vq=/\*(.+?)\*/g,yq=/\[ \] /g,bq=/\[.{1}\] /g,wq=/^[*-]/g,Sq=/(\d+)\. /g,FP=/\[\[([^\]]+)\]\]/g,Zk=/\[([^\]]+)\]\((([^\]]+).md)\)/g,Tq=(e,t)=>{const n=e.replace(mq,"<pre lang=''>$1</pre>").replace(wq,"<span class='counter-block'>•</span>").replace(Sq,"<span class='counter-block'>$1.</span>").replace(yq,"<span class='todo-block' data-type='todo'>⬜</span>").replace(bq,"<span class='todo-block' data-type='done'>✅</span>").replace(gq,"<strong>$1</strong>").replace(vq,"<em>$1</em>").replace(/<br>/g,"</p><p>").replace(/&/g,"&");let r=n;if(t){if(FP.test(n)){const o=n.match(FP);for(let i=0;i<o.length;i++)if(!/(jpeg|jpg|gif|png|svg|bmp|wepg)/g.test(o[i])){const a=xq(o[i]);if(/\|/g.test(a)){const[s,l]=a.split("|"),u=Ax(s,l);r=n.replace(o[i],u)}else{const u=Ax(a,"");r=r.replace(o[i],u)}}}if(Zk.test(n)){const o=n.match(Zk);for(let i=0;i<o.length;i++)if(!/(jpeg|jpg|gif|png|svg|bmp|wepg)/g.test(o[i])){const a=kq(o[i]),s=Iq(o[i]),l=Ax(a,s);r=n.replace(o[i],l)}}}return r},Ax=(e,t)=>{const{metadataCache:n}=ke.getState().dailyNotesState.app;return n.getFirstLinkpathDest(decodeURIComponent(e),"")instanceof N.TFile?t?`<a data-href="${e}" data-type="link" data-filepath="${e}" class="internal-link">${t}</a>`:`<a data-href="${e}" data-type="link" data-filepath="${e}" class="internal-link">${e}</a>`:t?`<a data-href="${e}" data-type="link" data-filepath="${e}" class="internal-link is-unresolved">${t}</a>`:`<a data-href="${e}" data-type="link" data-filepath="${e}" class="internal-link is-unresolved">${e}</a>`},xq=e=>/\[\[([^\]]+)\]\]/g.exec(e)?.[1],Iq=e=>Zk.exec(e)?.[1],kq=e=>/\[([^\]]+)\]\((([^\]]+).md)\)/g.exec(e)?.[3],d0=e=>{const t=document.createElement("div");return t.className="memo-content-text",t.innerHTML=e,t.innerText},Eq=e=>e.replace(/\n/g,"<br>"),Cq=e=>{const t=document.createElement("div");return t.textContent=e,t.innerHTML},HP="mobile-show-sidebar",j8=200,Uo=3600*24*1e3,Kg=/\s#([^\u2000-\u206F\u2E00-\u2E7F'!"#$%&()*+,.:;<=>?@^`{|}~\[\]\\\s]+)/g,cS=/(<p>|<br>)#([^\u2000-\u206F\u2E00-\u2E7F'!"#$%&()*+,.:;<=>?@^`{|}~\[\]\\\s]+)/g,UM=/^#([^\u2000-\u206F\u2E00-\u2E7F'!"#$%&()*+,.:;<=>?@^`{|}~\[\]\\\s]+)/gu,zM=/(\s|:|\(|>|^)((http|ftp|https):\/\/([\w_-]+(?:(?:\.[\w_-]+)+))([\w.,@?^=%&:/~+#-]*[\w@?^=%&/~+#-]))/g,Mq=/\[([\s\S]*?)\]\(([\s\S]*?)\)/gu,VM=/([^\s<\\*>'(]+\.(jpeg|jpg|gif|png|svg))(\]\])?(\))?/g,fh=/\[@(.+?)\]\((.+?)\)/g,Dq=/[#*"\/\\<>:|\[\]\?]/gim,Aq=/^(-|\*|\d\.)\s(\[.\]\s)?(\d{1,2}:\d{2}(:\d{2})?)(-\d{1,2}:\d{2}(:\d{2})?)?\s(.*)/g,Pm=[{title:"DAILY",icon:"list"},{title:"CANVAS",icon:"layout-dashboard"},{title:"MULTI",icon:"file-text"},{title:"FILE",icon:"edit"}];var $k;(e=>{function t(){return parseInt(N.moment().format("x"))}e.getNowTimeStamp=t;function n(R){const L=/'’A-Za-z\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B4\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC/.source,B=/\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u4E00-\u9FD5/.source,_=/[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u4E00-\u9FD5]{1}/.source,H=new RegExp([`(?:[0-9]+(?:(?:,|\\.)[0-9]+)*|[\\-${L}])+`,B,_].join("|"),"g");return(R.match(H)||[]).length}e.getWordCount=n;function r(R){Om()&&R?.EnabledLocationList.some(L=>L.value==="DAILY")&&R?.EnabledLocationList.some(L=>L.value==="MULTI")&&uS().contains(R?.MemoOtherSaveLocation.MemoDefaultMultiFilePath)&&new N.Notice(E("Please set different save locations for multi-file settings in Thino. The diary folder overlaps with the multi-file save location, or there is a risk of it being read repeatedly."),5e3)}e.checkDailyInMulti=r;function o(){const R=navigator.userAgent;let L="Unknown";return R.indexOf("Win")!=-1?L="Windows":R.indexOf("Mac")!=-1?L="MacOS":R.indexOf("Linux")!=-1&&(L="Linux"),L}e.getOSVersion=o;function i(R){return typeof R=="string"&&(R=R.replaceAll("-","/")),new Date(R).getTime()}e.getTimeStampByDate=i;function a(R){const L=new Date(i(R));return new Date(L.getFullYear(),L.getMonth(),L.getDate()).getTime()}e.getDateStampByDate=a;function s(R){const L=new Date(i(R)),B=L.getFullYear(),_=L.getMonth()+1,H=L.getDate();return`${B}/${_}/${H}`}e.getDateString=s;function l(R){const L=new Date(i(R)),B=L.getHours(),_=L.getMinutes(),H=B<10?"0"+B:B,U=_<10?"0"+_:_;return`${H}:${U}`}e.getTimeString=l;function u(R){const L=new Date(i(R)),B=L.getFullYear(),_=L.getMonth()+1,H=L.getDate(),U=L.getHours(),G=L.getMinutes(),K=L.getSeconds(),z=_<10?"0"+_:_,ne=H<10?"0"+H:H,J=U<10?"0"+U:U,ee=G<10?"0"+G:G,Z=K<10?"0"+K:K;return`${B}/${z}/${ne} ${J}:${ee}:${Z}`}e.getDateTimeString=u;function d(R){return Array.from(new Set(R))}e.dedupe=d;function h(R){const L=new Set,B=[];for(const _ of R)L.has(_.id)||(L.add(_.id),B.push(_));return B}e.dedupeObjectWithId=h;function p(R,L){let B=null;return()=>{B&&clearTimeout(B),B=setTimeout(R,L)}}e.debounce=p;function m(R,L,B=!1,_){let H=null,U=!1;function G(...K){if(H&&clearTimeout(H),B&&!U){const z=R.apply(this,K);_&&typeof _=="function"&&_(z),U=!0}else H=setTimeout(()=>{const z=R.apply(this,K);_&&typeof _=="function"&&_(z),U=!1,H=null},L)}return G.cancel=function(){H&&clearTimeout(H),H=null,U=!1},G}e.debouncePlus=m;function b(R,L){let B=!0;return()=>{if(!B)return!1;B=!1,setTimeout(()=>{R(),B=!0},L)}}e.throttle=b;function v(R){const L=[],B=Object.keys(R).sort();for(const _ of B){const H=R[_];H&&(typeof H=="object"?L.push(...v(H).split("&")):L.push(`${_}=${H}`))}return L.join("&")}e.transformObjectToParamsString=v;function y(R){const L={},B=R.split("&");for(const _ of B){const[H,U]=_.split("=");H&&U&&(L[H]=U)}return L}e.transformParamsStringToObject=y;function S(R){if(!R)return{};const L={},B=Object.keys(R).sort();for(const _ of B){const H=R[_];if(typeof H=="object"){const U=S(JSON.parse(JSON.stringify(H)));U&&Object.keys(U).length>0&&(L[_]=U)}else H&&(L[_]=H)}return L}e.filterObjectNullKeys=S;async function x(R){if(navigator.clipboard&&navigator.clipboard.writeText)try{await navigator.clipboard.writeText(R)}catch(L){console.warn("Copy to clipboard failed.",L)}else console.warn("Copy to clipboard failed, methods not supports.")}e.copyTextToClipboard=x;function C(R){return new Promise(L=>{const B=new Image;B.onload=()=>{const{width:_,height:H}=B;_>0&&H>0?L({width:_,height:H}):L({width:0,height:0})},B.onerror=()=>{L({width:0,height:0})},B.className="thino-hidden",B.src=R,document.body.appendChild(B),B.remove()})}e.getImageSize=C;async function k(R){let L;const _=app.plugins.getPlugin("obsidian-memos").settings.UseDailyOrPeriodic==="Daily";try{return!_&&window.app.plugins?.getPlugin("periodic-notes")?.calendarSetManager?.getActiveConfig("day")?.enabled?(L=await window.app.plugins.getPlugin("periodic-notes").createPeriodicNote("day",R),L):(L=await app.internalPlugins.getPluginById("daily-notes").instance.getDailyNote(R)||await O8(R),L)}catch(H){return console.error(H),new N.Notice(E("Failed to create daily note. Please check if you created a folder for daily notes.")),null}}e.createDailyNoteCheck=k;function M(R){const L=[];let B=0;for(;B<R;B++)L.push((16*Math.random()|0).toString(16));return L.join("")}e.randomId=M;function I(R){return R.replace(/[\p{P}\p{Z}\p{S}]/gu,"").length}e.countWords=I;async function O(R){try{const L=await N.requestUrl(R),B=new Uint8Array(L.arrayBuffer);return new Blob([B],{type:"image/png"})}catch(L){return console.error("error in grabImageFromUrl",R,L),new Blob}}e.grabImageFromUrl=O})($k||($k={}));const Le=$k;function Nq(){let e="";const t=app.plugins.getPlugin("obsidian-memos").settings;let n="";const r=window.app.plugins.getPlugin("periodic-notes")?.calendarSetManager?.getActiveConfig("day")?.folder,o=window.app.plugins.getPlugin("periodic-notes")?.settings?.daily?.format;switch(r===void 0?n=o:n=r,t?.UseDailyOrPeriodic||"Daily"){case"Daily":e=uc().format||"YYYY-MM-DD";break;case"Periodic":e=n||"YYYY-MM-DD";break;default:e=uc().format||"YYYY-MM-DD";break}return e===void 0&&new N.Notice(E("You didn't set format for daily notes in both periodic-notes and daily-notes plugins.")),e}function uS(){let e="";const t=app.plugins.getPlugin("obsidian-memos").settings;let n="";const r=window.app.plugins.getPlugin("periodic-notes")?.calendarSetManager?.getActiveConfig("day")?.folder,o=window.app.plugins.getPlugin("periodic-notes")?.settings?.daily?.folder;switch(r===void 0?n=o:n=r,t?.UseDailyOrPeriodic||"Daily"){case"Daily":e=uc().folder||"";break;case"Periodic":e=n||"";break;default:e=uc().folder||"";break}return e===void 0&&new N.Notice(E("You didn't set folder for daily notes in both periodic-notes and daily-notes plugins.")),e}function Oq(){const e=uS();return!(e!==void 0&&!app.vault.getFolderByPath(e))}function jm(e,t){e=Cq(e),e=Eq(e).split("<br>").map(r=>`<p>${r!==""?r:"<br>"}</p>`).join(""),e=Tq(e,t),e=e.replace(Kg,"<span class='tag-span'>#$1</span>").replace(cS,"<p><span class='tag-span'>#$2</span>").replace(zM,"$1<a class='link' target='_blank' rel='noreferrer' href='$2'>$2</a>").replace(Mq,"<a class='link' target='_blank' rel='noreferrer' href='$2'>$1</a>").replace(fh,"<span class='memo-link-text' data-value='$2'>$1</span>").replace(/\^\S{6}/g,"");const n=document.createElement("div");n.innerHTML=e;for(let r=0;r<n.children.length;r++){const o=n.children[r];if(o.tagName==="P"&&o.textContent===""&&o.firstElementChild?.tagName!=="BR"){o.remove(),r--;continue}}return n.innerHTML}const dS=(e,t)=>{const n=window.atob(e),r=new ArrayBuffer(n.length),o=new Uint8Array(r);for(let i=0;i<n.length;i++)o[i]=n.charCodeAt(i);return new Blob([r],{type:t})};function L8(e,t){return Object.keys(t).every(n=>typeof t[n]=="object"&&t[n]!==null&&typeof e[n]=="object"&&e[n]!==null?L8(e[n],t[n]):Object.prototype.hasOwnProperty.call(e,n)&&e[n]===t[n])}function Pq(e,t){switch(t.type){case"SET_MEMOS":{const n=t.payload.memos.sort((o,i)=>{const a=Le.getTimeStampByDate(o.createdAt),s=Le.getTimeStampByDate(i.createdAt);return a===s?i.id.localeCompare(o.id):Le.getTimeStampByDate(i.createdAt)-Le.getTimeStampByDate(o.createdAt)}),r=Le.dedupeObjectWithId(n);return{...e,memos:[...r]}}case"SET_COMMENT_MEMOS":{const n=Le.dedupeObjectWithId(t.payload.commentMemos.sort((r,o)=>Le.getTimeStampByDate(o.createdAt)-Le.getTimeStampByDate(r.createdAt)));return{...e,commentMemos:[...n]}}case"SET_TAGS":return{...e,tags:t.payload.tags,tagsNum:t.payload.tagsNum};case"INSERT_MEMO":{const n=Le.dedupeObjectWithId([t.payload.memo,...e.memos].sort((r,o)=>Le.getTimeStampByDate(o.createdAt)-Le.getTimeStampByDate(r.createdAt)));return{...e,memos:n}}case"INSERT_COMMENT_MEMO":{const n=Le.dedupeObjectWithId([t.payload.memo,...e.commentMemos].sort((r,o)=>Le.getTimeStampByDate(o.createdAt)-Le.getTimeStampByDate(r.createdAt)));return{...e,commentMemos:[...n]}}case"DELETE_MEMO_BY_ID":return{...e,memos:[...e.memos].filter(n=>n.id!==t.payload.id)};case"DELETE_MEMO_BY_ID_BATCH":{const n=[...e.memos];return t.payload.ids.forEach(r=>{n.splice(n.findIndex(o=>o.id===r),1)}),{...e,memos:[...n]}}case"REPLACE_MEMO_BY_ID":{const n=e.memos.map(r=>r.id===t.payload.id?t.payload.memo:r);return{...e,memos:[...n]}}case"REMOVE_PREPARE_UPDATE_THINO":return{...e,preparingUpdateMemo:[]};case"REMOVE_PARTICULAR_PREPARE_UPDATE_THINO":return{...e,preparingUpdateMemo:e.preparingUpdateMemo.filter(n=>n.id!==t.payload.id)};case"SET_WAITING_FOR_TEMPLATER":return{...e,preparingUpdateMemo:[...e.preparingUpdateMemo,{origin:t.payload.origin,date:t.payload.date,isList:t.payload.isList,id:t.payload.id,type:t.payload.type}]};case"CLEAR_MEMOS":return{...R8};case"EDIT_MEMO":{const n=e.memos.map(r=>r.id===t.payload.id?{...r,...t.payload}:r);return{...e,memos:[...n]}}case"EDIT_MEMO_PATH":{const n=e.memos.map(r=>r.path===t.payload.path?{...r,...t.payload}:r);return{...e,memos:[...n]}}case"UPDATE_MEMO_BATCH":{const n=e.memos.filter(o=>o.path!==t.payload.path),r=Le.dedupeObjectWithId([...t.payload.memos,...n].sort((o,i)=>Le.getTimeStampByDate(i.createdAt)-Le.getTimeStampByDate(o.createdAt)));return{...e,memos:[...r]}}case"ARCHIVE_MEMO_BY_ID":{const n=e.memos.map(r=>r.id===t.payload.id?{...r,...t.payload}:r);return{...e,memos:[...n]}}case"ARCHIVE_MEMO_BY_ID_BULK":{const n=e.memos.map(r=>t.payload.some(o=>o.id===r.id)?{...r,...t.payload.filter(o=>o.id===r.id)[0]}:r);return{...e,memos:[...n]}}case"UNARCHIVE_MEMO_BY_ID":{const n=e.memos.map(r=>r.id===t.payload.id?{...r,...t.payload}:r);return{...e,memos:[...n]}}case"PIN_MEMO":{const n=e.memos.map(r=>r.id===t.payload.id?{...r,pinned:t.payload.pinned}:r);return{...e,memos:[...n]}}case"EDIT_COMMENT_MEMO":{const n=e.commentMemos.map(r=>r.id===t.payload.id?{...r,...t.payload}:r);return{...e,commentMemos:[...n]}}default:return e}}const R8={memos:[],commentMemos:[],tags:[],tagsNum:{},preparingUpdateMemo:[]};function jq(e,t){switch(t.type){case"SIGN_IN":return{user:t.payload.user};case"SIGN_OUT":return{user:null};default:return e}}const Lq={user:null};function Rq(e,t){switch(t.type){case"SET_QUERIES":{const n=Le.dedupeObjectWithId(t.payload.queries.sort((r,o)=>Le.getTimeStampByDate(o.createdAt)-Le.getTimeStampByDate(r.createdAt)).sort((r,o)=>Le.getTimeStampByDate(o.pinnedAt??0)-Le.getTimeStampByDate(r.pinnedAt??0)));return{...e,queries:n}}case"INSERT_QUERY":{const n=Le.dedupeObjectWithId([t.payload.query,...e.queries].sort((r,o)=>Le.getTimeStampByDate(o.createdAt)-Le.getTimeStampByDate(r.createdAt)));return{...e,queries:n}}case"DELETE_QUERY_BY_ID":return{...e,queries:[...e.queries].filter(n=>n.id!==t.payload.id)};case"UPDATE_QUERY":{const n=e.queries.map(r=>r.id===t.payload.id?{...r,...t.payload}:r);return{...e,queries:n}}default:return e}}const Fq={queries:[]};function Hq(e,t){switch(t.type){case"SET_DAILY_NOTES":return{...e,dailyNotes:t.payload.dailyNotes};case"SET_APP":return e.app?{...e}:{...e,app:t.payload.app};case"SET_PLUGIN":return e.plugin?{...e}:{...e,plugin:t.payload.plugin};case"SET_EDITOR":return e.editor?{...e}:{...e,editor:t.payload.editor};case"SET_SETTINGS":return e.settings&&e.settings===t.payload.settings?{...e}:{...e,settings:t.payload.settings};case"SET_VIEW":return e.view&&e.view?.leaf?.id===t.payload.view?.leaf?.id?{...e}:{...e,view:t.payload.view};case"CLEAR_VIEW":return e.view&&e.view.unload(),{...e,view:null};case"CLEAR_FILES":return{...e,dailyNotes:null};case"SET_VERIFY_STATE":return{...e,verifyState:t.payload.verifyState};default:return e}}const _q={dailyNotes:null,app:null,view:null,settings:null,editor:null,plugin:null,verifyState:null},ke=g$({globalState:y$,locationState:y8,memoState:R8,userState:Lq,queryState:Fq,dailyNotesState:_q},m$({globalState:v$,locationState:b$,memoState:Pq,userState:jq,queryState:Rq,dailyNotesState:Hq})),ct=D.createContext(ke.getState());String.prototype.replaceAll||(String.prototype.replaceAll=function(e,t){return Object.prototype.toString.call(e).toLowerCase()==="[object regexp]"?this.replace(e,t):this.replace(new RegExp(e,"g"),t)});class Bq{initialized=!1;getState(){return ke.getState().dailyNotesState}setApp(t){return ke.dispatch({type:"SET_APP",payload:{app:t}}),t}setPlugin(t){return ke.dispatch({type:"SET_PLUGIN",payload:{plugin:t}}),t}setSettings(t){return ke.dispatch({type:"SET_SETTINGS",payload:{settings:t}}),this.initialized||(this.initialized=!0),t}setView(t){return ke.dispatch({type:"SET_VIEW",payload:{view:t}}),t}setEditor(t){return ke.dispatch({type:"SET_EDITOR",payload:{editor:t}}),t}async updateDailyNotes(t,n){const r=this.getState().dailyNotes,o=nf(t,"day");return n?delete r[`day-${o.format("YYYY-MM-DD")}T00:00:00+08:00}`]:r[`day-${o.format("YYYY-MM-DD")}T00:00:00+08:00}`]=t,ke.dispatch({type:"SET_DAILY_NOTES",payload:{dailyNotes:r}}),r}setVerifyState(t){return ke.dispatch({type:"SET_VERIFY_STATE",payload:{verifyState:t}}),t}async fechLocalDailyNotes(){try{const t=Il();return ke.dispatch({type:"SET_DAILY_NOTES",payload:{dailyNotes:t}}),t}catch(t){console.error(t)}}}const $e=new Bq;var ur;(e=>{function t(i){const a={};for(const s of i)try{const l=localStorage.getItem(s);if(l!==null){const u=JSON.parse(l);a[s]=u}}catch(l){console.error("Get storage failed in ",s,l)}return a}e.get=t;function n(i){for(const a in i)try{const s=JSON.stringify(i[a]);localStorage.setItem(a,s)}catch(s){console.error("Save storage failed in ",a,s)}}e.set=n;function r(i){for(const a of i)try{localStorage.removeItem(a)}catch(s){console.error("Remove storage failed in ",a,s)}}e.remove=r;function o(){const i=document.createElement("iframe");i.style.display="none",document.body.appendChild(i),i.contentWindow?.localStorage.setItem("t",Date.now().toString()),i.remove()}e.emitStorageChangedEvent=o})(ur||(ur={}));class Yq{constructor(){const t=ur.get(["shouldSplitMemoWord","shouldHideImageUrl","shouldUseMarkdownParser","useTinyUndoHistoryCache"]),n={shouldSplitMemoWord:t.shouldSplitMemoWord||!0,shouldHideImageUrl:t.shouldHideImageUrl||!0,shouldUseMarkdownParser:t.shouldUseMarkdownParser||!0,useTinyUndoHistoryCache:t.useTinyUndoHistoryCache||!1};this.setAppSetting(n)}getState=()=>ke.getState().globalState;setEditMemoId=t=>{ke.dispatch({type:"SET_EDIT_MEMO_ID",payload:{editMemoId:t}})};setRefresh=t=>{ke.dispatch({type:"SET_REFRESH",payload:{refresh:t}})};setCommentMemoId=t=>{ke.dispatch({type:"SET_COMMENT_MEMO_ID",payload:{commentMemoId:t}})};setMarkMemoId=t=>{ke.dispatch({type:"SET_MARK_MEMO_ID",payload:{markMemoId:t}})};setLoaded=t=>{ke.dispatch({type:"SET_LOADED",payload:{loaded:t}})};setGlobalEditorShown=t=>{ke.dispatch({type:"SET_GLOBAL_EDITOR_SHOWN",payload:{globalEditorShown:t}})};setIsMobileView=t=>{ke.dispatch({type:"SET_MOBILE_VIEW",payload:{isMobileView:t}})};setChangedByMemos=t=>{ke.dispatch({type:"SET_CHANGED_BY_MEMOS",payload:{changedByMemos:t}})};setShowSiderbarInMobileView=t=>{ke.dispatch({type:"SET_SHOW_SIDEBAR_IN_MOBILE_VIEW",payload:{showSiderbarInMobileView:t}})};setAppSetting=t=>{ke.dispatch({type:"SET_APP_SETTING",payload:t}),ur.set(t)};setMemoListView=t=>{ke.dispatch({type:"SET_MEMO_LIST_VIEW",payload:{memoListView:t}})};setInstance=(t,n)=>{ke.dispatch({type:"SET_INSTANCE",payload:{id:t,instance:n}})};setLocked=t=>{ke.dispatch({type:"SET_LOCKED",payload:{locked:t}})};setExitSteps=t=>{ke.dispatch({type:"SET_EXIT_STEPS",payload:{exited:t}})};setPluginManifest=t=>{ke.dispatch({type:"SET_MEMO_PLUGIN_MANIFEST",payload:{manifest:t}})}}const Ze=new Yq;class Uq{constructor(){this.updateStateWithLocation(),window.onpopstate=()=>{this.updateStateWithLocation()}}updateStateWithLocation=()=>{const{pathname:t,search:n,hash:r}=window.location,o=new URLSearchParams(n),i={pathname:"/",hash:"",query:{tag:"",duration:null,text:"",type:"",filter:"",path:"",metadata:{}}};i.query.tag=o.get("tag")||"",i.query.type=o.get("type")??"",i.query.text=o.get("text")??"",i.query.filter=o.get("filter")??"";const a=parseInt(o.get("from")??"0"),s=parseInt(o.get("to")??"0");s>a&&s!==0&&(i.query.duration={from:a,to:s}),i.hash=r,i.pathname=this.getValidPathname(t),ke.dispatch({type:"SET_LOCATION",payload:i})};getState=()=>ke.getState().locationState;clearQuery=()=>{ke.dispatch({type:"SET_QUERY",payload:{tag:"",duration:null,text:"",type:"",filter:"",path:"",metadata:{}}})};setQuery=t=>{ke.dispatch({type:"SET_QUERY",payload:t})};reloadApp=()=>{ke.dispatch({type:"RELOAD"})};setHash=t=>{ke.dispatch({type:"SET_HASH",payload:{hash:t}})};setPathname=t=>{ke.dispatch({type:"SET_PATHNAME",payload:{pathname:t}})};pushHistory=t=>{ke.dispatch({type:"SET_PATHNAME",payload:{pathname:t}})};replaceHistory=t=>{ke.dispatch({type:"SET_PATHNAME",payload:{pathname:t}})};setMemoTypeQuery=(t="")=>{ke.dispatch({type:"SET_TYPE",payload:{type:t}})};setMemoFilter=t=>{ke.dispatch({type:"SET_QUERY_FILTER",payload:t})};setTextQuery=t=>{ke.dispatch({type:"SET_TEXT",payload:{text:t}})};setTimeQuery=t=>{ke.dispatch({type:"SET_DURATION_QUERY",payload:{duration:t}})};setPathQuery=t=>{ke.dispatch({type:"SET_PATH_QUERY",payload:{path:t}})};setMetadataQuery=(t,n)=>{ke.dispatch({type:"SET_METADATA_QUERY",payload:{name:t,value:n}})};setTagQuery=t=>{ke.dispatch({type:"SET_TAG_QUERY",payload:{tag:t}})};setFromAndToQuery=(t,n)=>{ke.dispatch({type:"SET_DURATION_QUERY",payload:{duration:{from:t,to:n}}})};getValidPathname=t=>["/","/homeboard","/recycle","/setting"].includes(t)?t:"/"}const Ue=new Uq,Cu=e=>`${e.vault.configDir}/query.json`,F8=async(e,t)=>{try{return await e.vault.adapter.read(t),!0}catch(n){return console.error(n),!1}},hh=async e=>(await F8(e,Cu(e))||await H8(e),JSON.parse(await e.vault.adapter.read(Cu(e))).queries||[]),Xg=async(e,t)=>{await e.vault.adapter.write(Cu(e),JSON.stringify({queries:t},null,2))},H8=async e=>{const t=Ze.getState().manifest,n=e.plugins.getPlugin(t.id||"obsidian-memos").settings,r=e.metadataCache.getFirstLinkpathDest(n.QueryFileName,"");if(!r)await e.vault.adapter.write(Cu(e),JSON.stringify({queries:[]},null,2));else{const i=(await e.vault.read(r)).split(`
|
|
|
`);i.length===0&&await e.vault.adapter.write(Cu(e),JSON.stringify({queries:[]},null,2));const a=[];for(let s=0;s<i.length;s++){const l=s,u="Memos";let d="未命名";const h=i[s];let p=N.moment().format("YYYY/MM/DD HH:mm:ss"),m="[]";const b=h.match(/^\d{14,16}/);b&&(p=N.moment(b[0].slice(0,14),"YYYYMMDDHHmmss").format("YYYY/MM/DD HH:mm:ss"));const v=h.match(/\[\{(.+)\}\]/);v&&(m=v[0]);const y=h.match(/\s(.+)\s\[\{/);y&&(d=y[0].slice(1,-3)),a.push({id:l,pinnedAt:"",createdAt:p,updatedAt:p,title:d,querystring:m,userId:u})}await e.vault.adapter.write(Cu(e),JSON.stringify({queries:a},null,2))}},zq=async()=>{const{app:e}=ke.getState().dailyNotesState;return await F8(e,Cu(e))||await H8(e),await hh(e)||[]},Vq=(e,t)=>({createdAt:N.moment().format("YYYY/MM/DD HH:mm:ss"),id:e,pinnedAt:"",querystring:t,title:E("Temp Filter"),updatedAt:N.moment().format("YYYY/MM/DD HH:mm:ss"),userId:"Thino"}),Wq=async(e,t)=>{const n=await hh(ke.getState().dailyNotesState.app)||[],r={createdAt:N.moment().format("YYYY/MM/DD HH:mm:ss"),id:N.moment().format("YYYYMMDDHHmmss")+n.length,pinnedAt:"",querystring:t,title:e,updatedAt:N.moment().format("YYYY/MM/DD HH:mm:ss"),userId:"Thino"};return n.push(r),await Xg(ke.getState().dailyNotesState.app,n),r};var Gq=Object.prototype;function Zq(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||Gq;return e===n}var fS=Zq;function $q(e,t){return function(n){return e(t(n))}}var _8=$q,qq=_8,Kq=qq(Object.keys,Object),Xq=Kq,Jq=fS,Qq=Xq,eK=Object.prototype,tK=eK.hasOwnProperty;function nK(e){if(!Jq(e))return Qq(e);var t=[];for(var n in Object(e))tK.call(e,n)&&n!="constructor"&&t.push(n);return t}var B8=nK,rK=typeof xr=="object"&&xr&&xr.Object===Object&&xr,Y8=rK,oK=Y8,iK=typeof self=="object"&&self&&self.Object===Object&&self,aK=oK||iK||Function("return this")(),Ta=aK,sK=Ta,lK=sK.Symbol,ph=lK,_P=ph,U8=Object.prototype,cK=U8.hasOwnProperty,uK=U8.toString,Cp=_P?_P.toStringTag:void 0;function dK(e){var t=cK.call(e,Cp),n=e[Cp];try{e[Cp]=void 0;var r=!0}catch{}var o=uK.call(e);return r&&(t?e[Cp]=n:delete e[Cp]),o}var fK=dK,hK=Object.prototype,pK=hK.toString;function mK(e){return pK.call(e)}var gK=mK,BP=ph,vK=fK,yK=gK,bK="[object Null]",wK="[object Undefined]",YP=BP?BP.toStringTag:void 0;function SK(e){return e==null?e===void 0?wK:bK:YP&&YP in Object(e)?vK(e):yK(e)}var kl=SK;function TK(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Vi=TK;const mh=tt(Vi);var xK=kl,IK=Vi,kK="[object AsyncFunction]",EK="[object Function]",CK="[object GeneratorFunction]",MK="[object Proxy]";function DK(e){if(!IK(e))return!1;var t=xK(e);return t==EK||t==CK||t==kK||t==MK}var hS=DK;const Pt=tt(hS);var AK=Ta,NK=AK["__core-js_shared__"],OK=NK,Nx=OK,UP=function(){var e=/[^.]+$/.exec(Nx&&Nx.keys&&Nx.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function PK(e){return!!UP&&UP in e}var jK=PK,LK=Function.prototype,RK=LK.toString;function FK(e){if(e!=null){try{return RK.call(e)}catch{}try{return e+""}catch{}}return""}var z8=FK,HK=hS,_K=jK,BK=Vi,YK=z8,UK=/[\\^$.*+?()[\]{}|]/g,zK=/^\[object .+?Constructor\]$/,VK=Function.prototype,WK=Object.prototype,GK=VK.toString,ZK=WK.hasOwnProperty,$K=RegExp("^"+GK.call(ZK).replace(UK,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function qK(e){if(!BK(e)||_K(e))return!1;var t=HK(e)?$K:zK;return t.test(YK(e))}var KK=qK;function XK(e,t){return e?.[t]}var JK=XK,QK=KK,eX=JK;function tX(e,t){var n=eX(e,t);return QK(n)?n:void 0}var Ju=tX,nX=Ju,rX=Ta,oX=nX(rX,"DataView"),iX=oX,aX=Ju,sX=Ta,lX=aX(sX,"Map"),WM=lX,cX=Ju,uX=Ta,dX=cX(uX,"Promise"),fX=dX,hX=Ju,pX=Ta,mX=hX(pX,"Set"),V8=mX,gX=Ju,vX=Ta,yX=gX(vX,"WeakMap"),bX=yX,qk=iX,Kk=WM,Xk=fX,Jk=V8,Qk=bX,W8=kl,gh=z8,zP="[object Map]",wX="[object Object]",VP="[object Promise]",WP="[object Set]",GP="[object WeakMap]",ZP="[object DataView]",SX=gh(qk),TX=gh(Kk),xX=gh(Xk),IX=gh(Jk),kX=gh(Qk),hu=W8;(qk&&hu(new qk(new ArrayBuffer(1)))!=ZP||Kk&&hu(new Kk)!=zP||Xk&&hu(Xk.resolve())!=VP||Jk&&hu(new Jk)!=WP||Qk&&hu(new Qk)!=GP)&&(hu=function(e){var t=W8(e),n=t==wX?e.constructor:void 0,r=n?gh(n):"";if(r)switch(r){case SX:return ZP;case TX:return zP;case xX:return VP;case IX:return WP;case kX:return GP}return t});var Jg=hu;function EX(e){return e!=null&&typeof e=="object"}var xa=EX,CX=kl,MX=xa,DX="[object Arguments]";function AX(e){return MX(e)&&CX(e)==DX}var NX=AX,$P=NX,OX=xa,G8=Object.prototype,PX=G8.hasOwnProperty,jX=G8.propertyIsEnumerable,LX=$P(function(){return arguments}())?$P:function(e){return OX(e)&&PX.call(e,"callee")&&!jX.call(e,"callee")},pS=LX,RX=Array.isArray,Hr=RX,FX=9007199254740991;function HX(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=FX}var GM=HX,_X=hS,BX=GM;function YX(e){return e!=null&&BX(e.length)&&!_X(e)}var Qu=YX,f0={exports:{}};function UX(){return!1}var zX=UX;f0.exports;(function(e,t){var n=Ta,r=zX,o=t&&!t.nodeType&&t,i=o&&!0&&e&&!e.nodeType&&e,a=i&&i.exports===o,s=a?n.Buffer:void 0,l=s?s.isBuffer:void 0,u=l||r;e.exports=u})(f0,f0.exports);var Qg=f0.exports,VX=kl,WX=GM,GX=xa,ZX="[object Arguments]",$X="[object Array]",qX="[object Boolean]",KX="[object Date]",XX="[object Error]",JX="[object Function]",QX="[object Map]",eJ="[object Number]",tJ="[object Object]",nJ="[object RegExp]",rJ="[object Set]",oJ="[object String]",iJ="[object WeakMap]",aJ="[object ArrayBuffer]",sJ="[object DataView]",lJ="[object Float32Array]",cJ="[object Float64Array]",uJ="[object Int8Array]",dJ="[object Int16Array]",fJ="[object Int32Array]",hJ="[object Uint8Array]",pJ="[object Uint8ClampedArray]",mJ="[object Uint16Array]",gJ="[object Uint32Array]",En={};En[lJ]=En[cJ]=En[uJ]=En[dJ]=En[fJ]=En[hJ]=En[pJ]=En[mJ]=En[gJ]=!0;En[ZX]=En[$X]=En[aJ]=En[qX]=En[sJ]=En[KX]=En[XX]=En[JX]=En[QX]=En[eJ]=En[tJ]=En[nJ]=En[rJ]=En[oJ]=En[iJ]=!1;function vJ(e){return GX(e)&&WX(e.length)&&!!En[VX(e)]}var yJ=vJ;function bJ(e){return function(t){return e(t)}}var mS=bJ,h0={exports:{}};h0.exports;(function(e,t){var n=Y8,r=t&&!t.nodeType&&t,o=r&&!0&&e&&!e.nodeType&&e,i=o&&o.exports===r,a=i&&n.process,s=function(){try{var l=o&&o.require&&o.require("util").types;return l||a&&a.binding&&a.binding("util")}catch{}}();e.exports=s})(h0,h0.exports);var ZM=h0.exports,wJ=yJ,SJ=mS,qP=ZM,KP=qP&&qP.isTypedArray,TJ=KP?SJ(KP):wJ,gS=TJ,xJ=B8,IJ=Jg,kJ=pS,EJ=Hr,CJ=Qu,MJ=Qg,DJ=fS,AJ=gS,NJ="[object Map]",OJ="[object Set]",PJ=Object.prototype,jJ=PJ.hasOwnProperty;function LJ(e){if(e==null)return!0;if(CJ(e)&&(EJ(e)||typeof e=="string"||typeof e.splice=="function"||MJ(e)||AJ(e)||kJ(e)))return!e.length;var t=IJ(e);if(t==NJ||t==OJ)return!e.size;if(DJ(e))return!xJ(e).length;for(var n in e)if(jJ.call(e,n))return!1;return!0}var RJ=LJ;const FJ=tt(RJ);function Zy(e){const t=e.match(/^#+/);return t?t[0].length:0}function XP(e,t){const n=e.split(`
|
|
|
`);let r="",o=[],i=!1,a=1;for(let s=0;s<n.length;s++){const l=n[s];if(l.startsWith("#")&&/^#{1,6}\s/g.test(l)){if(i&&Zy(l)<=Zy(t))break;r=l,r===t?(i=!0,a=s+1):i&&Zy(l)>Zy(t)?o.push(l):(i=!1,o=[])}else i&&o.push(l)}return t?FJ(o)?{content:"",startLine:-1}:{content:o.join(`
|
|
|
`),startLine:a}:{content:e,startLine:0}}function $M(e){const t={};for(const n of e)n.parent&&n.parent>0&&(t[n.position.start.line]=n.parent);return t}function HJ(e,t,n){const r={},o=(p,m)=>{for(;p[m]!==void 0&&p[m]!==m;)m=p[m];return m},i=$e.getState().app,a=n.split(`
|
|
|
`),s=t+a.length-1,l=i.metadataCache.getFileCache(e)?.listItems,u={};if(!l)return[];const d=p=>{const m=/^(-|\*|\d\.)\s/,b=/(\[.\]\s)?/,v=/(\d{1,2}:\d{2}(:\d{2})?)(-\d{1,2}:\d{2}(:\d{2})?)?\s?/;return new RegExp(m.source+b.source+v.source).test(p)};return l.forEach(p=>{const m=p.position.start.line,b=p.position.end.line;if(m>=t&&b<=s){const v=m-t,y=b-t,S=a.slice(v,y+1),x=S.join(`
|
|
|
`);if(p.parent&&p.parent>0&&(r[p.position.start.line]=p.parent),p.parent&&u[p.parent]){if(m-p.parent===1){const k=a[v]?.match(/^(\s*)/);k&&(u[p.parent].indent=k[0])}const C=new RegExp("^"+u[p.parent].indent);u[p.parent].content+=`
|
|
|
`+x.split(`
|
|
|
`).map(k=>k?.replace(C,"")).join(`
|
|
|
`)}else if(p.parent&&u[o(r,p.parent)]){const C=new RegExp("^"+u[o(r,p.parent)].indent);u[o(r,p.parent)].content+=`
|
|
|
`+x.split(`
|
|
|
`).map(k=>k?.replace(C,"")).join(`
|
|
|
`)}else if(d(x)||new RegExp(Aq).test(x)){u[m]||(u[m]={content:"",blockId:"",indent:""});const C=S.length>1&&S[1]?.match(/^(\s*)/);C&&(u[m].indent=C[0]),u[m].content=x.split(`
|
|
|
`).map(k=>k?.replace(u[m].indent,"")).join(`
|
|
|
`),u[m].blockId=p.id}}}),Object.keys(u).map(p=>{const m=parseInt(p);return{line:u[m].content,blockId:u[m].blockId||"",index:m}})}async function _J(e,t){let n=t.vault.getAbstractFileByPath(e);return n||(new N.Notice(E("File not found for the given thino path, is creating a new file")),n=await t.vault.create(e,'{"nodes": [], "edges": []}'),Ze.setChangedByMemos(!0)),n}async function BJ(e,t){let n;try{n=await t.vault.read(e)}catch(o){console.error(o),n=await t.vault.cachedRead(e)}const r=t.metadataCache.getFileCache(e)?.frontmatterPosition;return r?n.slice(r.end.offset+1):n}function YJ(e){const t=e.split(/\r?\n/),n=[];let r=!1,o=[],i="";for(let a=0;a<t.length;a++){const s=t[a];s.startsWith("> [!thino]")?(r&&(n.push({metadata:i,content:o.join(`
|
|
|
`).trim()}),o=[]),r=!0,i=s.replace("> [!thino]","").trim()):r&&s.startsWith(">")?o.push(s.replace(/^> /,"")):r&&!s.startsWith(">")&&(r=!1,n.push({metadata:i,content:o.join(`
|
|
|
`).trim()}),o=[],i="")}return r&&n.push({metadata:i,content:o.join(`
|
|
|
`).trim()}),n}function UJ(e,t){const n=/%%(.*?)%%/,r=e.match(n);if(!r)return e;const o=r[1].trim(),i={};o.split(" ").forEach(s=>{const[l,u]=s.slice(1,-1).split("::");i[l]=u});for(const s of Object.keys(t))if(s!=="id"&&s!=="content"){if(s==="rowStatus"&&t.rowStatus==="ARCHIVED"){i.archived="true";continue}else if(s==="rowStatus"&&t.rowStatus==="NORMAL"){delete i.archived;continue}if(s==="deleted"&&t.deleted){const l=N.moment().format("YYYYMMDDHHmmss");i.deleted=l}else typeof t[s]=="boolean"?t[s]?i[s]="true":delete i[s]:t[s]&&(typeof t[s]=="string"||typeof t[s]=="boolean")&&(i[s]=t[s])}const a=Object.entries(i).map(([s,l])=>`[${s}::${l}]`).join(" ");return e.replace(n,`%% ${a} %%`)}async function aa(e,t){if(!e.sourceType||e.sourceType!=="MULTI")return e;const{vault:n,fileManager:r}=ke.getState().dailyNotesState.app,o=n.getAbstractFileByPath(e.path);if(!o)return e;const i=N.moment();if(await r.processFrontMatter(o,a=>{(t.pinned!==void 0||t.thinoType||t.rowStatus||t.visibility||t.deleted)&&Ze.setChangedByMemos(!0),t.id&&(a.id=t.id),t.thinoType&&(a.thinoType=t.thinoType),t.rowStatus&&(a.rowStatus=t.rowStatus),t.visibility&&(a.visibility=t.visibility),t.webId&&(a.webId=t.webId),t.pinned!==void 0&&(a.pinned=t.pinned),t.deleted!==void 0&&(a.deletedAt=t.deleted?i.format("YYYY/MM/DD HH:mm:ss"):""),a.createdAt||(a.createdAt=i.format("YYYY/MM/DD HH:mm:ss")),a.updatedAt=i.format("YYYY/MM/DD HH:mm:ss")}),t.content){const a=await n.read(o);let s=a;const l=t.content.replace(/\$/g,"$$$$");s=a.replace(e.content,l),await n.modify(o,s)}return Ze.setChangedByMemos(!0),{...e,id:t.id||e.id,thinoType:t.thinoType||e.thinoType,createdAt:e.createdAt||i.format("YYYY/MM/DD HH:mm:ss"),updatedAt:N.moment().format("YYYY/MM/DD HH:mm:ss"),content:t.content||e.content,rowStatus:t.rowStatus||e.rowStatus,visibility:t.visibility||e.visibility,pinned:t.pinned!==void 0?t.pinned:e.pinned,webId:t.webId||e.webId,deletedAt:t.deleted?i.format("YYYY/MM/DD HH:mm:ss"):t.deleted===!1?"":e.deletedAt?e.deletedAt:""}}async function Ka(e,t){if(!e.sourceType||e.sourceType!=="FILE")return e;const{vault:n}=ke.getState().dailyNotesState.app,r=n.getAbstractFileByPath(e.path);if(!r)return e;const o=N.moment();let i="";try{i=await n.read(r)}catch(S){console.error(S),i=await n.cachedRead(r)}const a=i.split(/\r?\n/),s=a.findIndex(S=>S.includes("id::"+e.id)||S.includes("Id::"+e.id)||e.webId&&S.includes(e.webId)),l=a[s];if(!l)return e;const u=UJ(l,t);if(!l)return e;const d=u+`
|
|
|
`,h=a.findIndex((S,x)=>x>s&&S.trim()==="");let p="";h===-1&&(p=a.slice(s+1).join(`
|
|
|
`)),h!==-1&&(p=a.slice(s+1,h).join(`
|
|
|
`));let m=p;t?.content&&(m=t.content.split(/\r?\n/).map(k=>"> "+k).join(`
|
|
|
`));const v=(d+m).split(/\r?\n/);a.splice(s,h!==-1?h-s:a.length-s,...v);const y=a.join(`
|
|
|
`);return await n.modify(r,y),Ze.setChangedByMemos(!0),{...e,id:t.id||e.id,thinoType:t.thinoType||e.thinoType,createdAt:e.createdAt||o.format("YYYY/MM/DD HH:mm:ss"),updatedAt:N.moment().format("YYYY/MM/DD HH:mm:ss"),content:t.content||e.content,rowStatus:t.rowStatus||e.rowStatus,visibility:t.visibility||e.visibility,pinned:t.pinned!==void 0?t.pinned:e.pinned,webId:t.webId||e.webId,deletedAt:t.deleted?o.format("YYYY/MM/DD HH:mm:ss"):t.deleted===!1?"":e.deletedAt?e.deletedAt:""}}async function Xa(e,t){if(!e.sourceType||e.sourceType!=="CANVAS")return e;const{vault:n}=ke.getState().dailyNotesState.app,r=n.getAbstractFileByPath(e.path);if(!r)return e;const o=await n.read(r),i=JSON.parse(o),a=i.nodes.find(u=>u.id===e.id);if(!a)return e;t.content&&(a.text=t.content),t.thinoType&&(a.thinoType=t.thinoType),t.rowStatus&&(a.rowStatus=t.rowStatus),t.visibility&&(a.visibility=t.visibility),t.pinned!==void 0&&(a.pinned=t.pinned),t.webId&&(a.webId=t.webId);const s=N.moment();t.deleted!==void 0&&(a.deletedAt=t.deleted?s.format("YYYY/MM/DD HH:mm:ss"):""),a.updatedAt=s.format("YYYY/MM/DD HH:mm:ss");const l=JSON.stringify(i,null,2);return await n.modify(r,l),Ze.setChangedByMemos(!0),{...e,thinoType:t.thinoType||e.thinoType,createdAt:e.createdAt,updatedAt:N.moment().format("YYYY/MM/DD HH:mm:ss"),content:t.content??e.content,rowStatus:t.rowStatus??e.rowStatus,visibility:t.visibility??e.visibility,pinned:t.pinned??e.pinned,webId:t.webId??e.webId,deletedAt:t.deleted?s.format("YYYY/MM/DD HH:mm:ss"):t.deleted===!1?"":e.deletedAt?e.deletedAt:""}}function Z8(e,t){const n=[];for(const r in t)t[r]===e&&n.push(parseInt(r),...Z8(parseInt(r),t));return n}async function si(e,t){$8()||new N.Notice(E("If you are disabling the daily note plugin, it would be possible that the thino will not be deleted or patched properly. Please enable the plugin and try again."));const{vault:n,metadataCache:r}=ke.getState().dailyNotesState.app,o=ke.getState().dailyNotesState.app,{settings:i}=ke.getState().dailyNotesState,a=e.id.toString().slice(0,14),s=N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss").isSame(N.moment(a,"YYYYMMDDHHmmss"))?N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss"):N.moment(a,"YYYYMMDDHHmmss"),l=N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss").isSame(s,"day"),u=e.path,d=n.getAbstractFileByPath(u)||n.getAbstractFileByPath(e.path);if(!d)return new N.Notice(E("Please check your daily note plugin OR periodic notes plugin settings")),e;const p=(await n.read(d)).split(`
|
|
|
`),b=r.getFileCache(d)?.listItems||[];if(b.length===0)return new N.Notice(E("Thino not found")),e;const v=parseInt(e.id.slice(14));let y=v;const S=$M(b),x=b.find(J=>J.position.start.line===v);if(!x)return new N.Notice(E("Thino not found")),e;const C=Z8(v,S);if(C.length>0){const J=C.map(ee=>{const Z=b.find(q=>q.position.start.line===ee);return Z?Z.position.end.line:-1});y=Math.max(...J,x.position.end.line)}else y=x.position.end.line;const k=p.slice(v,y+1),M=k.join(`
|
|
|
`);let I=M;const O=o.vault.getConfig("useTab")===void 0||app.vault.getConfig("useTab")===!0,R=O?1:o.vault.getConfig("tabSize"),L=(O?" ":" ").repeat(R),B=M.match(/\s\^([0-9a-zA-Z-]+)($|\s|\n)/),_=t.hasId!==void 0?t.hasId:B?B[1]:e.hasId||null,H=k[0]||"",U=ed(H);let G;U.fullTimeMatch?G=U.fullTimeMatch:G=l?N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss").format("HH:mm"):(parseInt(e.id.toString().slice(10,12))+24).toString()+":"+e.id.toString().slice(12,14);let K=G;!U.fullTimeMatch&&i.DefaultTimePrefix!=="HH:mm"&&(K=N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss").format(i.DefaultTimePrefix));const z={pinned:M.includes("[pinned::true]"),deleted:M.match(/\[deleted::([^\]]+)\]/)?.[1]||"",archived:M.includes("[archived::true]"),webId:M.match(/\[webId::([^\]]+)\]/)?.[1]||"",visibility:M.match(/\[visibility::"([^"]+)"\]/)?.[1]||""};if(M.match(/^(- \[.\] |- |(\*|\d{1,2}\.) )/)?.[0],t.content){const J=t.thinoType?t.thinoType==="TASK-TODO"?"- [ ] ":t.thinoType==="TASK-DONE"?"- [x] ":t.thinoType.startsWith("TASK")?`- [${t.thinoType.slice(5)}] `:"- ":e.thinoType==="TASK-TODO"?"- [ ] ":e.thinoType==="TASK-DONE"?"- [x] ":e.thinoType.startsWith("TASK")?`- [${e.thinoType.slice(5)}] `:"- ",ee=[];if((t.pinned!==void 0?t.pinned:z.pinned)&&ee.push("[pinned::true]"),t.deleted||t.deleted!==!1&&z.deleted){const re=t.deleted?N.moment().format("YYYYMMDDHHmmss"):z.deleted;ee.push(`[deleted::${re}]`)}(t.rowStatus==="ARCHIVED"||t.rowStatus!=="NORMAL"&&z.archived)&&ee.push("[archived::true]"),(t.webId!==void 0?t.webId:z.webId)&&ee.push(`[webId::${t.webId!==void 0?t.webId:z.webId}]`),(t.visibility||z.visibility)&&ee.push(`[visibility::"${t.visibility||z.visibility}"]`);const Z=_?`^${_}`:"",q=t.content.trim().split(`
|
|
|
`).length>1;/^((-|\*|\d\.|>)\s|```)/g.test(t.content);const $=t.content.trim().split(`
|
|
|
`);if(/(^(-|\*|\d\.|>)\s)/g.test($[$.length-1]),q){const re=$.map(ie=>L+ie);let le=!1;for(let ie=re.length-1;ie>=0;ie--)if(!/(^(-|\*|\d\.|>)\s)/g.test(re[ie].trim())){re[ie]=re[ie]+(_?` ${Z}`:""),le=!0;break}!le&&_&&(re[re.length-1]+=` ${Z}`),I=`${J}${K}
|
|
|
${re.join(`
|
|
|
`)} ${ee.join(" ")}`.trim()}else I=`${J}${K} ${t.content.trim()} ${ee.join(" ")}`.trim()+(Z?` ${Z}`:"")}else{if(t.thinoType){const J=t.thinoType==="TASK-TODO"?"- [ ] ":t.thinoType==="TASK-DONE"?"- [x] ":t.thinoType.startsWith("TASK")?`- [${t.thinoType.slice(5)}] `:"- ";I=I.replace(/^((- \[.\] )|((-|\*) ))/,J)}if(t.rowStatus&&(t.rowStatus==="ARCHIVED"?I.includes("[archived::")?I=I.replace(/\[archived::(true|false)\]/,"[archived::true]"):I+=(I.endsWith(" ")?"":" ")+"[archived::true]":t.rowStatus==="NORMAL"&&(I=I.replace(/\s?\[archived::(true|false)\]/,""))),t.visibility){const J=`[visibility::"${t.visibility}"]`;I.includes("[visibility::")?I=I.replace(/\[visibility::"(PUBLIC|PROTECTED)"\]/,J):I+=(I.endsWith(" ")?"":" ")+J}if(t.pinned!==void 0&&(t.pinned?I.includes("[pinned::")?I=I.replace(/\[pinned::(true|false)\]/,"[pinned::true]"):I+=(I.endsWith(" ")?"":" ")+"[pinned::true]":I=I.replace(/\s?\[pinned::(true|false)\]/,"")),t.webId!==void 0&&(I.includes("[webId::")?t.webId===""?I=I.replace(/\s?\[webId::([^\]]+)\]/,""):I=I.replace(/\[webId::([^\]]+)\]/,`[webId::${t.webId}]`):t.webId!==""&&(I+=(I.endsWith(" ")?"":" ")+`[webId::${t.webId}]`)),t.deleted!==void 0){const J=N.moment();if(t.deleted){const ee=`[deleted::${J.format("YYYYMMDDHHmmss")}]`;I.includes("[deleted::")?I=I.replace(/\[deleted::([^\]]+)\]/,ee):I+=(I.endsWith(" ")?"":" ")+ee}else I=I.replace(/\s?\[deleted::([^\]]+)\]/,"")}if(t.hasId!==void 0||_){const J=t.hasId!==void 0?t.hasId:_;I=I.replace(/\s\^([0-9a-zA-Z-]+)($|\s|\n)/g,""),J&&(I=I.trimEnd(),I+=` ^${J}`)}}if(I!==M){p.splice(v,y-v+1,I.trim()),await n.modify(d,p.join(`
|
|
|
`)),Ze.setChangedByMemos(!0);const J=N.moment();return{...e,thinoType:t.thinoType||e.thinoType,createdAt:e.createdAt,updatedAt:N.moment().format("YYYY/MM/DD HH:mm:ss"),content:t.content??e.content,rowStatus:t.rowStatus??e.rowStatus,visibility:t.visibility??e.visibility,pinned:t.pinned??e.pinned,webId:t.webId??e.webId,hasId:t.hasId??e.hasId,deletedAt:t.deleted?J.format("YYYY/MM/DD HH:mm:ss"):t.deleted===!1?"":e.deletedAt?e.deletedAt:""}}return e}async function zJ(e,t,n){const{vault:r,metadataCache:o}=ke.getState().dailyNotesState.app||window.app,i=r.getFileByPath(e);if(!i)return;const a=o.getFileCache(i)?.listItems||[],s=$M(a),l=[],u=r.getConfig("useTab")===void 0||app.vault.getConfig("useTab")===!0,d=u?1:r.getConfig("tabSize"),h=(u?" ":" ").repeat(d);function p(S,x){const C=[];for(const k in x)x[k]===S&&C.push(parseInt(k),...p(parseInt(k),x));return C}const m=N.moment(),b=t.map(S=>{const x=a.find(I=>I.position.start.line===parseInt(S.id.slice(14))),k=p(parseInt(S.id.slice(14)),s).map(I=>{const O=a.find(R=>R.position.start.line===I);return O?O.position.end.line:-1}),M=Math.max(...k,x.position.end.line);return{id:S.id,start:x.position.start.line,end:M}}),y=(await r.read(i)).split(`
|
|
|
`);return b.forEach(S=>{const C=y.slice(S.start,S.end+1).join(`
|
|
|
`),k=C.split(`
|
|
|
`),M=k.length-1,O=k[M].trim();let R=C;const L=/\[(pinned|archived|deleted|webId|visibility)::[^\]]*\]\s*$/.test(O),B=(_,H)=>_.split(`
|
|
|
`).length>1&&(/```/g.test(O)||!L)?_+`
|
|
|
`+h+H:_+(_.endsWith(" ")?"":" ")+H;if(n==="delete"){const _="[deleted::"+m.format("YYYYMMDDHHmmss")+"]";R=R.replace(/\[deleted::([^\]]+)\]/,""),R=B(R,_)}if(n==="restoreFromDelete"&&(R=R.replace(/ ?\[deleted::([^\]]+)\]/,"")),n==="archive"){const _="[archived::true]";R.includes("[archived::")?R=R.replace(/\[archived::(true|false)\]/,_):R=B(R,_)}n==="restoreFromArchive"&&(R=R.replace(/ ?\[archived::(true|false)\]/,"")),n==="deleteForever"?y.splice(S.start,S.end-S.start+1):y.splice(S.start,S.end-S.start+1,R),l.push({...t.find(_=>_.id===S.id),deletedAt:n==="delete"?m.format("YYYY/MM/DD HH:mm:ss"):"",rowStatus:n==="archive"?"ARCHIVED":"NORMAL"})}),await r.modify(i,y.join(`
|
|
|
`)),Ze.setChangedByMemos(!0),l}const VJ=e=>{switch(e?.sourceType){case"CANVAS":return Xa(e,{id:e.id,pinned:!0});case"DAILY":return si(e,{id:e.id,pinned:!0});case"MULTI":return aa(e,{id:e.id,pinned:!0});case"FILE":return Ka(e,{id:e.id,pinned:!0})}},WJ=e=>{switch(e?.sourceType){case"CANVAS":return Xa(e,{id:e.id,pinned:!1});case"DAILY":return si(e,{id:e.id,pinned:!1});case"MULTI":return aa(e,{id:e.id,pinned:!1});case"FILE":return Ka(e,{id:e.id,pinned:!1})}},GJ=e=>{let t;switch(e){case" ":t="TASK-TODO";break;case"x":case"X":t="TASK-DONE";break;default:t="TASK-"+e;break}return t};async function ZJ(e,t){if(!t)return 0;const{vault:n}=ke.getState().dailyNotesState.app,r=e?.DefaultMemoComposition,o=e?.ProcessEntriesBelow&&e?.ProcessContentTarget!=="whole"?e?.ProcessEntriesBelow:"",i=e?.ProcessContentTarget!=="whole"?e?.DifferentInsertTarget?e?.InsertAfterForTask?e?.InsertAfterForTask:"":o:"";let a;try{a=await n.read(t)}catch(b){console.error(b),a=await n.cachedRead(t)}let s;r!=""&&/{TIME}/g.test(r)&&/{CONTENT}/g.test(r)?s="(-|\\*) (\\[(.{1})\\]\\s)?"+r.replace(/{TIME}/g,"((\\<time\\>)?\\d{1,2}:\\d{2}(\\:\\d{2})?)?").replace(/ {CONTENT}/g,""):s="(-|\\*) (\\[(.{1})\\]\\s)?((\\<time\\>)?\\d{1,2}\\:\\d{2}(\\:\\d{2})?)?";const l=new RegExp(s,"g"),u=(a.match(l)||[]).length,d=new RegExp(o.replace(/([.?*+^$[\]\\(){}|-])/g,"\\$1"),"g"),h=new RegExp(i.replace(/([.?*+^$[\]\\(){}|-])/g,"\\$1"),"g"),p=(a.match(d)||[]).length,m=(a.match(h)||[]).length;return a=null,p||m?u:0}function JP(e,t,n,r,o){const i=ke.getState().dailyNotesState.app||window.app,a=nf(o,"day")||N.moment(o.stat.ctime),s=HJ(o,n,t),l=i?.metadataCache.getFileCache(o),u={frontmatter:l?.frontmatter||{},tags:l?.frontmatter?.tags||[]};for(const d of s){$J(a,d,e);const{rawText:h,memoType:p}=qJ(d),{content:m,pinned:b,archived:v,deleted:y,deletedAtStr:S,webId:x,visibility:C}=KJ(h,d),k=vS(m);r.push({id:a.format("YYYYMMDDHHmmss")+`${d.index}`,content:m.trim(),createdAt:a.format("YYYY/MM/DD HH:mm:ss"),updatedAt:a.format("YYYY/MM/DD HH:mm:ss"),thinoType:p,hasId:d.blockId?d.blockId:"",linkId:k,path:o.path,deletedAt:y?N.moment(S,"YYYYMMDDHHmmss").format("YYYY/MM/DD HH:mm:SS"):"",rowStatus:v?"ARCHIVED":"NORMAL",visibility:C,pinned:b,creatorName:"Thino",resourceList:[],sourceType:"DAILY",webId:x,fileInfo:u})}}function $J(e,t,n){const r=ed(t.line);if(r.startHour&&r.startMin)e.hours(parseInt(r.startHour)),e.minutes(parseInt(r.startMin)),r.startSec?e.seconds(parseInt(r.startSec)):e.seconds(0);else{const o=XJ(n.DefaultMemoComposition,t.line),i=JJ(n.DefaultMemoComposition,t.line),a=QJ(t.line);e.hours(parseInt(o)),e.minutes(parseInt(i)),a?e.seconds(parseInt(a)):e.seconds(0)}}function qJ(e){let t=tQ(e.line),n;if(/^\s*[-*]\s(\[(.)\])\s/g.test(e.line)){const r=eQ(e.line);t=nQ(e.line),n=GJ(r)}else n="JOURNAL";return{rawText:t,memoType:n}}function KJ(e,t){if(!e)return{content:"",pinned:!1,archived:!1,deleted:!1,deletedAtStr:"",webId:"",visibility:"PRIVATE"};let n=e.trim().replaceAll(/<br>/g,`
|
|
|
`);const r=new RegExp(/\[(pinned|PINNED)::true\]/,"g").test(e),o=new RegExp(/\[(archived|ARCHIVED)::true\]/,"g").test(e),i=new RegExp(/\[(deleted|DELETED)::([^\]]*)\]/,"g").test(e),a=new RegExp(/\[(deleted|DELETED)::([^\]]*)\]/,"g").exec(e)?.[2],s=new RegExp(/\[(webId|WEBID)::([^\]]*)\]/,"g").exec(e)?.[2],l=new RegExp(/\[(visibility|VISIBILITY)::("PROTECT"|"PUBLIC")\]/,"g").test(e)?"PUBLIC":"PRIVATE";return n=n.replace(/\s?\[pinned::[^\]]+\]/g,"").replace(/\s?\[visibility::[^\]]+\]/g,"").replace(/\s?\[archived::[^\]]+\]/g,"").replace(/\s?\[deleted::[^\]]+\]/g,"").replace(/\s?\[webId::[^\]]+\]/g,""),t.blockId&&(n=n.replace("^"+t.blockId,"")),{content:n,pinned:r,archived:o,deleted:i,deletedAtStr:a,webId:s,visibility:l}}function vS(e){const t=[],n=/(?:\[\[([^\]|]+)#\^([a-zA-Z0-9-]+)(?:\|[^\]]+)?\]\])|(?:\[.+?\]\(([^)]+)#\^([a-zA-Z0-9-]+)\))/g;let r;for(;(r=n.exec(e))!==null;)r[1]&&r[2]?t.push(`${r[1]}#^${r[2]}`):r[3]&&r[4]&&t.push(`${r[3]}#^${r[4]}`);return t}function ed(e){const t=/((\d{1,2}):(\d{2})(:(\d{2}))?)-(\d{1,2}):(\d{2})(:(\d{2}))?/,n=/(\d{1,2}):(\d{2})(:(\d{2}))?/,r=e.match(t);if(r)return{startHour:r[2],startMin:r[3],startSec:r[5],endHour:r[6],endMin:r[7],endSec:r[9],fullTimeMatch:r[0]};const o=e.match(n);return o?{startHour:o[1],startMin:o[2],startSec:o[4],fullTimeMatch:o[0]}:{startHour:"",startMin:"",fullTimeMatch:""}}const XJ=(e,t)=>{const n=ed(t);if(n.startHour)return n.startHour;let r;return e!=""&&/{TIME}/g.test(e)&&/{CONTENT}/g.test(e)?r="^\\s*(\\-|\\*|(\\d{1,}\\.))\\s(\\[(.{1})\\]\\s?)?"+e.replace(/{TIME}/g,"(\\<time\\>)?(\\d{1,2})\\:(\\d{2})(\\:\\d{2})?").replace(/{CONTENT}/g,"(.*)"):r="^\\s*(\\-|\\*|(\\d{1,}\\.))\\s(\\[(.{1})\\]\\s?)?(\\<time\\>)?(\\d{1,2})\\:(\\d{2})(.*)",new RegExp(r,"").exec(t)?.[6]},JJ=(e,t)=>{const n=ed(t);if(n.startMin)return n.startMin;let r;return e!=""&&/{TIME}/g.test(e)&&/{CONTENT}/g.test(e)?r="^\\s*(\\-|\\*|(\\d{1,}\\.))\\s(\\[(.{1})\\]\\s?)?"+e.replace(/{TIME}/g,"(\\<time\\>)?(\\d{1,2})\\:(\\d{2})(\\:\\d{2})?").replace(/{CONTENT}/g,"(.*)"):r="^\\s*(\\-|\\*|(\\d{1,}\\.))\\s(\\[(.{1})\\]\\s?)?(\\<time\\>)?(\\d{1,2})\\:(\\d{2})(.*)",new RegExp(r,"").exec(t)?.[7]},QJ=e=>{const t=ed(e);if(t.startSec)return t.startSec;const n="^\\s*(\\-|\\*|(\\d{1,}\\.))\\s(\\[(.{1})\\]\\s?)?(\\d{1,2})\\:(\\d{2})\\:(\\d{2})(.*)";return new RegExp(n,"").exec(e)?.[7]},eQ=e=>/^\s*[\-\*]\s(\[(.{1})\])\s(.*)/.exec(e)?.[2],$8=()=>Om()?!0:(new N.Notice(E("Check if you opened Daily Notes Plugin Or Periodic Notes Plugin")),!1);function tQ(e){const t=ed(e);return t.fullTimeMatch?e.replace(new RegExp(`^(-|\\*|\\d\\.) (${t.fullTimeMatch})\\s(.*)`),"$3"):e.replace(/^(-|\*|\d\.) (\d{1,2}:\d{2}(:\d{2})?)\s(.*)/g,"$4")}function nQ(e){return rQ(e)}const rQ=e=>{const t=ed(e);if(t.fullTimeMatch)return new RegExp(`^(-|\\*|\\d\\.)\\s+\\[.\\]\\s(${t.fullTimeMatch})\\s([\\w\\W]*)`).exec(e)?.[3];const n="^(-|\\*|\\d\\.)\\s+\\[.\\]\\s(\\d{1,2}:\\d{2}(:\\d{2})?)\\s([\\w\\W]*)";return new RegExp(n,"").exec(e)?.[4]};async function q8(e,t=!1){const n=ke.getState().dailyNotesState.app,r=n.vault.getFileByPath(e.path);if(r&&e.hasId)return t?"!"+n.fileManager.generateMarkdownLink(r,"","#^"+e.hasId,e.id):e.hasId?n.fileManager.generateMarkdownLink(r,"","#^"+e.hasId,e.id):`[@THINO](${e.id})`;const o=Le.randomId(6);return await si(e,{id:e.id,hasId:o}),r?t?"!"+n.fileManager.generateMarkdownLink(r,"","#^"+o,e.id):n.fileManager.generateMarkdownLink(r,"","#^"+o,e.id):`[@THINO](${e.id})`}async function K8(e,t){if(!e)return t;const n=ke.getState().dailyNotesState.app||window.app,r=ke.getState().dailyNotesState.settings,o=await BJ(e,n),i=r.IgnoreFolderForMultiType;if(new Set(i.filter(h=>h!=="")).has(e.parent?.path))return t;let l=N.moment(e.stat.ctime).format("YYYY/MM/DD HH:mm:ss");const u=n?.metadataCache.getFileCache(e),d={frontmatter:u?.frontmatter||{},tags:u?.frontmatter?.tags||[]};await n.fileManager.processFrontMatter(e,h=>{if(h.id||(h.id=Le.randomId(16)),h.createdAt?l=N.moment(h.createdAt,"YYYY/MM/DD HH:mm:ss").isValid()?h.createdAt:l:h.createdAt=l,!o.trim())return t;const p=!!h.pinned,m=h.rowStatus&&h.rowStatus==="ARCHIVED",b=!!h.deletedAt,v=h.deletedAt?h.deletedAt:"",y=h.visibility?h.visibility:"PRIVATE",S=h.thinoType?h.thinoType:"JOURNAL",x=h.webId?h.webId:"",C=h.id?h.id:"",k=h.hasId?h.hasId:"",M=h.linkId?h.linkId:"",I=e.path,O="Memo",R="MULTI",L=[];return t.push({id:C,content:o,createdAt:l,updatedAt:l,deletedAt:b?N.moment(v,"YYYYMMDDHHmmss").format("YYYY/MM/DD HH:mm:SS"):"",pinned:p,rowStatus:m?"ARCHIVED":"NORMAL",visibility:y,thinoType:S,hasId:k,linkId:M,path:I,creatorName:O,sourceType:R,resourceList:L,webId:x,fileInfo:d}),t})}async function eE(e,t){if(!e)return t;const{vault:n,metadataCache:r}=ke.getState().dailyNotesState.app||window.app;let o;try{o=await n.read(e)}catch(y){console.error(y),o=await n.cachedRead(e)}if(!o)return;const i=N.moment(e.stat.ctime).format("YYYY/MM/DD HH:mm:ss"),a=N.moment(e.stat.mtime).format("YYYY/MM/DD HH:mm:ss"),s=e.path,l="Thino",u="FILE",d="",h=[],p=[],m=r.getFileCache(e),b={frontmatter:m?.frontmatter||{},tags:m?.frontmatter?.tags||[]},v=YJ(o);for(const y of v){const S=y.metadata.match(/\d{4}\/\d{2}\/\d{2} \d{2}:\d{2}:\d{2}/g);if(!S)continue;const x=y.metadata.match(/id::([^\]]*)/g)?.[0]?.replace("id::","");if(!x)continue;const C=S?S[0]:i,k=S?S[0]:a,M=y.metadata.match(/webId::([^\]]*)/g)?y.metadata.match(/webId::([^\]]*)/g)?.[0]?.replace("webId::",""):"",I=y.metadata.contains("[pinned::true]"),O=y.metadata.contains("[archived::true]"),R=y.metadata.contains("[deleted::"),L=new RegExp(/\[(deleted|DELETED)::([^\]]*)\]/,"g").exec(y.metadata)?.[2],B=new RegExp(/\[(visibility|VISIBILITY)::("PROTECT"|"PUBLIC")\]/,"g").test(y.metadata)?"PUBLIC":"PRIVATE",_=new RegExp(/\[(thinoType|THINOTYPE)::([^\]]*)\]/,"g").exec(y.metadata)?.[2];t.push({id:x,content:y.content,createdAt:C,updatedAt:k,deletedAt:R?N.moment(L,"YYYYMMDDHHmmss").format("YYYY/MM/DD HH:mm:SS"):"",pinned:I,rowStatus:O?"ARCHIVED":"NORMAL",visibility:B,thinoType:_||"JOURNAL",hasId:d,linkId:h,path:s,creatorName:l,sourceType:u,resourceList:p,webId:M,fileInfo:b})}return t}async function X8(e,t){if(!e)return[];const n=ke.getState().dailyNotesState.settings,{vault:r}=ke.getState().dailyNotesState.app||window.app;if(await ZJ(n,e)===0)return;let i;try{i=await r.read(e)}catch(h){console.error(h),i=await r.cachedRead(e)}const{content:a,startLine:s}=XP(i,n?.ProcessContentTarget==="whole"?"":n.ProcessEntriesBelow);let l="",u=0;if(n.DifferentInsertTarget&&n?.ProcessContentTarget!=="whole"&&n.InsertAfterForTask&&!a.includes(n.InsertAfterForTask)){const{content:h,startLine:p}=XP(i,n.InsertAfterForTask);l=h,u=p}const d=[];JP(n,a,s,d,e),n.DifferentInsertTarget&&l&&JP(n,l,u,d,e),d.length!==0&&t.push(...d.sort((h,p)=>h.createdAt>p.createdAt?-1:1))}async function J8(e,t){const n=ke.getState().dailyNotesState.app||window.app;if(!(e instanceof N.TFile))return;let r;try{r=await n.vault.read(e)}catch(a){console.error(a),r=await n.vault.cachedRead(e)}if(!r)return;const i=JSON.parse(r)?.nodes;for(const a of i){if(a.type==="group"||a.createdAt===void 0||a.text.trim()==="")continue;const l=N.moment(a?.createdAt,"YYYYMMDDHHmmss").format("YYYY/MM/DD HH:mm:SS"),u=N.moment(a?.updatedAt,"YYYYMMDDHHmmss").format("YYYY/MM/DD HH:mm:SS"),d=a?.deletedAt?N.moment(a?.deletedAt,"YYYYMMDDHHmmss").format("YYYY/MM/DD HH:mm:SS"):"",h=!!a?.pinned,p=a?.archived?"ARCHIVED":"NORMAL",m=a?.visibility?a?.visibility:"PRIVATE",b=a?.thinoType?a?.thinoType:"JOURNAL",v=a?.text?a?.text:"",y=a?.id?a?.id:"",S=a?.hasId?a?.hasId:"",x=a?.linkId?a?.linkId:"",C=e.path,k="Memo",M="CANVAS",I=[],O=a?.webId?a?.webId:void 0;t.push({id:y,content:v,createdAt:l,updatedAt:u,deletedAt:d,pinned:h,rowStatus:p,visibility:m,thinoType:b,hasId:S,linkId:x,path:C,creatorName:k,sourceType:M,resourceList:I,webId:O,fileInfo:{frontmatter:{},tags:[]}})}}async function QP(e=[]){const t=[],n=[],r=ke.getState().dailyNotesState.app||app,{vault:o}=r,{settings:i}=ke.getState().dailyNotesState,a=r.loadLocalStorage("tokenForSync"),s=async(l,u)=>{for(const d of l)try{await u(d,t,i)}catch(h){console.error(h),new N.Notice(h)}};try{if(e.includes("CANVAS")){const l=oQ(o);await s(l,J8)}}catch(l){console.error(l)}try{if(e.includes("MULTI")){const l=iQ(o,r,i);await s(l,K8)}}catch(l){console.error(l)}try{if(e.includes("DAILY")){const l=await aQ(o);await s(l,X8)}}catch(l){console.error(l)}try{if(e.includes("FILE")||a){const l=sQ(o,r,i);await s(l,eE)}}catch(l){console.error(l)}return{memos:t,commentMemos:n}}function oQ(e){return e.getAllLoadedFiles().filter(t=>t instanceof N.TFile&&t.extension==="canvas"&&t.name.includes(".thino"))}function iQ(e,t,n){const r=e.getMarkdownFiles(),o=r.filter(a=>a.parent?.path.includes(n.MemoOtherSaveLocation.MemoDefaultMultiFilePath.trim())&&!a.path?.endsWith("thino.md")),i=n.TagForMultiTypeFiles?r.filter(a=>!(a.parent?.path.includes(n.MemoOtherSaveLocation.MemoDefaultMultiFilePath.trim())&&!a.path?.endsWith("thino.md"))&&N.getAllTags(t.metadataCache.getFileCache(a))?.contains("#"+n.TagForMultiTypeFiles.replace("#",""))):[];return[...o,...i]}async function aQ(e){const t=uS();t===void 0&&new N.Notice(E("Please check your daily note plugin OR periodic notes plugin settings")+"folder path is empty or undefined"),e.getAbstractFileByPath(N.normalizePath(t))||new N.Notice(E("Failed to find daily notes folder"));const r=Il();return Object.values(r).filter(o=>o instanceof N.TFile&&o.extension==="md")}function sQ(e,t,n){const r=e.getMarkdownFiles(),o=r.filter(a=>a.name.trim().includes("thino")),i=n.TagForFileTypeFiles?r.filter(a=>!a.name.trim().includes("thino")&&N.getAllTags(t.metadataCache.getFileCache(a))?.contains("#"+n.TagForFileTypeFiles.replace("#",""))):[];return[...o,...i]}const lQ=async(e,t,n)=>{const r=await hh(ke.getState().dailyNotesState.app)||[],o=r.find(s=>s.id===e),i={...o,title:t,querystring:n},a=r.findIndex(s=>s.id===e);return r[a]=i,await Xg(ke.getState().dailyNotesState.app,r),[o]},cQ="https://api.thino.pkmer.cn/test",vh=cQ,uQ="unknown",dQ=/!\[(?<content>[^\]]+)\]\((?<link>[^)]+)\)/g;function fQ(e){return e.substring(e.lastIndexOf(".")+1)}function hQ(e){return{id:e.id,createdAt:Date.now().toString(),filename:e.id,type:`${fQ(e.id)}`,size:e.size.toString()}}function pQ(e){const t=e?.matchAll(dQ);return t?Array.from(t).map(n=>hQ({url:n.groups?.link,id:uQ,size:0,mtime:""})).filter(n=>n.type!="html"):[]}function ev(e){return{id:e.id,createdAt:N.moment(e.ctime.toString(),"x").format("YYYY/MM/DD HH:mm:ss"),updatedAt:N.moment(e.mtime.toString(),"x").format("YYYY/MM/DD HH:mm:ss"),deletedAt:e.ttime?.toString()?N.moment(e.ttime.toString(),"x").format("YYYY-MM-DD HH:mm:ss"):"",rowStatus:e.rowStatus,content:e.content,pinned:e.pinned,resourceList:pQ(e.content),creatorName:"thino",sourceType:e?.thinoType||"FILE",visibility:"PUBLIC",localId:e.originalId,deleted:!!e.dtime,thinoType:e?.thinoStatus||"JOURNAL"}}async function mQ(e){const n={url:`${vh}/thino/getThinos${e?`?since=${e}&includeDeleted=true`:""}`,method:"GET",headers:{Authorization:`Bearer ${yh()}`}};return N.requestUrl(n).then(r=>{r.status>=400&&console.error(`Failed to fetch memos: ${r.status}`);try{return r.json.payload.map(i=>ev(i))}catch(o){console.error(`Error processing memo response: ${o}`)}}).catch(r=>(console.error(r),[]))}function yh(){return(ke.getState().dailyNotesState.app||app)?.loadLocalStorage("tokenForSync")||""}async function qM(e){const t=`${vh}/thino/createThino`,n={content:e.content,thinoType:e?.thinoType||"FILE",thinoStatus:e?.thinoStatus||"JOURNAL",pinned:!1,rowStatus:"NORMAL",encrypted:!1},r={url:t,method:"POST",contentType:"application/json",body:JSON.stringify(n),headers:{Authorization:`Bearer ${yh()}`}};return N.requestUrl(r).then(o=>{o.status>=400&&console.error(`Failed to create memo: ${o.status}`);try{const i=o.json;return ev(i.payload)}catch(i){console.error(`Error processing memo creation response: ${i}`)}}).catch(o=>(console.error(o),null))}function gQ(e){return{id:e.id,ctime:N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss").valueOf(),mtime:N.moment(e.updatedAt,"YYYY/MM/DD HH:mm:ss").valueOf(),ttime:e.deletedAt?N.moment(e.deletedAt,"YYYY/MM/DD HH:mm:ss").valueOf():void 0,rowStatus:e.rowStatus,content:e.content,pinned:e.pinned,encrypted:!1,thinoType:e.sourceType==="DAILY"?"DAILY":"FILE",thinoStatus:e.thinoType,tags:[]}}async function vQ(e){const t=`${vh}/thino/createThinosByData`,n=e.map(o=>gQ(o)),r={url:t,method:"POST",contentType:"application/json",body:JSON.stringify(n),headers:{Authorization:`Bearer ${yh()}`}};return N.requestUrl(r).then(o=>{o.status>=400&&console.error(`Failed to create thinos: ${o.status}`);try{return o.json.payload.map(s=>ev(s))}catch(i){console.error(`Error processing thinos creation response: ${i}`)}}).catch(o=>(console.error(o),[]))}async function Ox(e){const n={url:`${vh}/thino/updateThinoById/${e.id}`,method:"POST",contentType:"application/json",body:JSON.stringify(e),headers:{Authorization:`Bearer ${yh()}`}};return N.requestUrl(n).then(r=>{r.status>=400&&console.error(`Failed to update memo: ${r.status}`);try{const o=r.json;return ev(o.payload)}catch(o){console.error(`Error processing memo update response: ${o}`)}}).catch(r=>(console.error(r),null))}async function Lm(e){const n={url:`${vh}/thino/recoverThinoFromTrash/${e}`,method:"POST",headers:{Authorization:`Bearer ${yh()}`}};return N.requestUrl(n).then(r=>{r.status>=400&&console.error(`Failed to recover memo: ${r.status}`);try{const o=r.json;return ev(o.payload)}catch(o){console.error(`Error processing memo recovery response: ${o}`)}}).catch(r=>(console.error(r),null))}async function KM(e){const n={url:`${vh}/thino/deleteThinoById/${e}`,method:"DELETE",headers:{Authorization:`Bearer ${yh()}`}};return N.requestUrl(n).then(r=>{r.status>=400&&console.error(`Failed to delete memo: ${r.status}`)}).catch(r=>(console.error(r),null))}function yQ(e){return e?.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")||e}function p0(e,t){return e&&e.replace(/\{\{TIME\|(.*?)\}\}/g,(n,r)=>{try{return t.format(r)}catch(o){return console.error("Invalid time format:",r,o),n}})}function bQ(e){const t=[];let n=e;for(;n.contains(`
|
|
|
`);){const r=n.indexOf(`
|
|
|
`);t.push(n.slice(0,r)),n=n.slice(r+1)}return t.push(n),t}async function wQ({content:e,isList:t,name:n}){const r=ke.getState().dailyNotesState.settings,o=N.moment(),i=Le.randomId(16),a=r?.MemoOtherSaveLocation.MemoDefaultMultiFilePath||"Thino",s=n||`${o.format("YYYYMMDD")}-${i}`,l=`${a}/${s}.md`,u={id:i,content:e,deletedAt:"",path:l,createdAt:o.format("YYYY/MM/DD HH:mm:ss"),updatedAt:o.format("YYYY/MM/DD HH:mm:ss"),thinoType:t?"JOURNAL":"TASK-TODO",hasId:"",linkId:[],pinned:!1,visibility:"PUBLIC",rowStatus:"NORMAL",creatorName:"Thino",resourceList:[],sourceType:"MULTI",fileInfo:{tags:[],frontmatter:{}}},d=$e.getState().app||window.app,{vault:h,fileManager:p}=d,m=h.getAbstractFileByPath(a);(!m||!(m instanceof N.TFolder))&&(new N.Notice(E("Folder not found for the given thino path, is creating a new folder")),await h.createFolder(a)),Ze.setChangedByMemos(!0);let b;const v=d.vault.getFileByPath(l);v?b=await h.create(`${a}/${o.format("YYYYMMDD")}-${i}.md`,e):b=await h.create(l,e),await p.processFrontMatter(b,x=>{x.id=i,x.createdAt=o.format("YYYY/MM/DD HH:mm:ss"),x.updatedAt=o.format("YYYY/MM/DD HH:mm:ss"),x.thinoType=t?"JOURNAL":"TASK-TODO"}),(!n||v)&&r?.SetFileNameAfterCreate&&d.fileManager.promptForFileRename(b);const y=d.metadataCache.getFileCache(b),S={tags:y?.frontmatter?.tags||[],frontmatter:y?.frontmatter||{}};return{...u,fileInfo:S}}async function SQ({content:e,isList:t}){const n=ke.getState().dailyNotesState.settings,r=N.moment(),o=Le.randomId(16),i=n?.MemoOtherSaveLocation.MemoDefaultSingleFilePath||"basic.thino.md",a={id:o,content:e,deletedAt:"",path:i,createdAt:r.format("YYYY/MM/DD HH:mm:ss"),updatedAt:r.format("YYYY/MM/DD HH:mm:ss"),thinoType:t?"JOURNAL":"TASK-TODO",hasId:"",linkId:[],pinned:!1,visibility:"PUBLIC",rowStatus:"NORMAL",creatorName:"Thino",resourceList:[],sourceType:"FILE",fileInfo:{tags:[],frontmatter:{}}},s=$e.getState().app,{vault:l}=s;let u=l.getAbstractFileByPath(i);(!u||!(u instanceof N.TFile))&&(new N.Notice(E("File not found for the given thino path, is creating a new file")),u=await l.create(i,""));const d=s.metadataCache.getFileCache(u),h={tags:d?.frontmatter?.tags||[],frontmatter:d?.frontmatter||{}};let p="";try{p=await l.read(u)||await l.cachedRead(u)}catch(C){console.error(C),new N.Notice(E("Failed to read current daily note, check if it exists."))}const m=p.indexOf(`# ${r.format("YYYY-MM-DD")}`);let b=p.indexOf(`
|
|
|
#`,m+1);b===-1&&(b=p.length);const v=`> [!thino] ${r.format("YYYY/MM/DD HH:mm:ss")} %% [id::${o}] [thinoType::${t?"JOURNAL":"TASK-TODO"}] %%`,y=e.replace(/\n/g,`
|
|
|
> `),S=`
|
|
|
${v}
|
|
|
> ${y}
|
|
|
`;let x;if(m===-1){const C=`# ${r.format("YYYY-MM-DD")}`;x=`${p.substring(0,b)}
|
|
|
${C}${S}
|
|
|
${p.substring(b)}`}else x=`${p.substring(0,b)}${S}${p.substring(b)}`;return setTimeout(async()=>{Ze.setChangedByMemos(!0),await l.modify(u,x)},200),{...a,fileInfo:h}}async function e3(e){const t=ke.getState().dailyNotesState.settings,n=N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss"),r=e.id,o=t?.MemoOtherSaveLocation.MemoDefaultSingleFilePath||"basic.thino.md",i={id:r,content:e.content,deletedAt:e.deletedAt||"",path:o,createdAt:n.format("YYYY/MM/DD HH:mm:ss"),updatedAt:n.format("YYYY/MM/DD HH:mm:ss"),thinoType:e.thinoType||"JOURNAL",hasId:"",linkId:[],pinned:e.pinned,visibility:"PUBLIC",rowStatus:e.rowStatus||"NORMAL",creatorName:"Thino",resourceList:[],sourceType:"FILE",webId:e.id,fileInfo:e?.fileInfo},a=$e.getState().app,{vault:s}=a;let l=s.getAbstractFileByPath(o);(!l||!(l instanceof N.TFile))&&(new N.Notice(E("File not found for the given thino path, is creating a new file")),l=await s.create(o,""));let u="";try{u=await s.read(l)||await s.cachedRead(l)}catch(x){console.error(x),new N.Notice(E("Failed to read current daily note, check if it exists."))}const d=a.metadataCache.getFileCache(l),h={tags:d?.frontmatter?.tags||[],frontmatter:d?.frontmatter||{}},p=u.indexOf(`# ${n.format("YYYY-MM-DD")}`);let m=u.indexOf(`
|
|
|
#`,p+1);m===-1&&(m=u.length);const b=`> [!thino] ${n.format("YYYY/MM/DD HH:mm:ss")} %% [id::${r}] [thinoType::JOURNAL]${e.rowStatus==="ARCHIVED"?" [archived::true]":""}${e.pinned===!0?" [pinned::true]":""}${e.deletedAt?` [deleted::${e.deletedAt}]`:""}${e.id?` [webId::${e.id}]`:""} %%`,v=e.content.replace(/\n/g,`
|
|
|
> `),y=`
|
|
|
${b}
|
|
|
> ${v}
|
|
|
`;let S;if(p===-1){const x=`# ${n.format("YYYY-MM-DD")}`;S=`${u.substring(0,m)}
|
|
|
${x}${y}
|
|
|
${u.substring(m)}`}else S=`${u.substring(0,m)}${y}${u.substring(m)}`;return Ze.setChangedByMemos(!0),await s.modify(l,S),{...i,fileInfo:h}}async function TQ({content:e,isList:t}){const r=ke.getState().dailyNotesState.settings?.MemoOtherSaveLocation.MemoDefaultCanvasPath||"basic.thino.canvas",o=N.moment(),i=Le.randomId(16),a={id:i,content:e,deletedAt:"",path:r,createdAt:o.format("YYYY/MM/DD HH:mm:ss"),updatedAt:o.format("YYYY/MM/DD HH:mm:ss"),thinoType:t?"JOURNAL":"TASK-TODO",hasId:"",linkId:[],pinned:!1,visibility:"PUBLIC",rowStatus:"NORMAL",creatorName:"Thino",resourceList:[],sourceType:"CANVAS",fileInfo:{tags:[],frontmatter:{}}},s=$e.getState().app,{vault:l}=s,u=await _J(r,s);if(!u||!(u instanceof N.TFile)){new N.Notice(E("File not found for the given thino path, is creating a new file"));return}const d=await l.read(u),h=JSON.parse(d);if(h.nodes.find(y=>y.id===a.id))return;let m;h.nodes.length>0&&(m=[...h.nodes].reduce((y,S)=>{if(!y.createdAt)return S;const x=N.moment(y.createdAt,"YYYY/MM/DD HH:mm:ss"),C=N.moment(S.createdAt,"YYYY/MM/DD HH:mm:ss");return x.isAfter(C)?y:S}));const b=m?{x:m.x,y:m.y+100,width:m.width,height:m.height}:{x:0,y:0,width:200,height:100};h.nodes.push({...b,type:"text",id:i,text:e,deletedAt:"",createdAt:o.format("YYYY/MM/DD HH:mm:ss"),updatedAt:o.format("YYYY/MM/DD HH:mm:ss"),thinoType:t?"JOURNAL":"TASK-TODO",hasId:"",linkId:[],pinned:!1,visibility:"PUBLIC",rowStatus:"NORMAL",creatorName:"Thino",resourceList:[]}),Ze.setChangedByMemos(!0);const v=JSON.stringify(h,null,2);return await l.modify(u,v),a}async function Px(e,t,n,r){const{vault:o}=ke.getState().dailyNotesState.app||window.app,i=ke.getState().dailyNotesState.app||window.app,a=ke.getState().dailyNotesState.settings,s=i.vault.getConfig("useTab")===void 0||window.app.vault.getConfig("useTab")===!0,l=s?1:i.vault.getConfig("tabSize"),u=(s?" ":" ").repeat(l),d=e.split(`
|
|
|
`).join(`
|
|
|
`+u),h=n||N.moment(),{DifferentInsertTarget:p,InsertAfterForTask:m,InsertType:b}=a,v=h.format(a.DefaultTimePrefix||"HH:mm");let y="",S="";a.UseMemoFixedStrings&&(y=p0(a.MemoFixedPrefix||"",h),S=p0(a.MemoFixedSuffix||"",h));const x=b==="end"?"":t?a.InsertAfter:p&&m||a.InsertAfter,C=i?.loadLocalStorage("tokenForSync");let k="";try{!r&&e&&C&&a.startSync&&(k=(await qM({content:e,thinoType:"DAILY",thinoStatus:t?"JOURNAL":"TASK-TODO"})).id)}catch(Z){console.error(Z)}const M=y?y+(y.endsWith(" ")?"":" ")+d:d,I=S?M+(M.endsWith(" ")?"":" ")+S:M,O=t?"- ":"- [ ] ",R=a?.DefaultMemoComposition?`${O}${a?.DefaultMemoComposition?.replace(/{TIME}/g,v).replace(/{CONTENT}/g,(I.split(`
|
|
|
`).length>1||/^((-|\*|\d\.|>)\s|```)/g.test(I)?`
|
|
|
`+u:"")+I)}${I.split(`
|
|
|
`).length>1&&/((-|\*|\d\.|>)\s|```)/g.test(I.split(`
|
|
|
`)[I.split(`
|
|
|
`).length-1])&&k?`
|
|
|
`+u:" "}${k?`[webId::${k}]`:""}`:`${O}${v} ${I.split(`
|
|
|
`).length>1||/^((-|\*|\d\.|>)\s|```)/g.test(I)?`
|
|
|
`+u:""}${I}${I.split(`
|
|
|
`).length>1&&/((-|\*|\d\.|>)\s|```)/g.test(I.split(`
|
|
|
`)[I.split(`
|
|
|
`).length-1])&&k?`
|
|
|
`+u:" "}${k?`[webId::${k}]`:""}`,L=Il(),B=lS(h,L),_="fake"+Le.randomId(16);let H=!1;const U=i.plugins.getPlugin("templater-obsidian");let G;if(B?G=B:(U?.templater&&U?.settings.trigger_on_file_creation&&(de.setWaitingForTemplater({origin:e,date:h,isList:t,id:_,type:k?"web":"local"}),H=!0),G=await Le.createDailyNoteCheck(h)),!G){new N.Notice(E("Failed to create daily note, check if it exists."));return}if(B||await $e.fechLocalDailyNotes(),U&&U?.templater&&U?.settings.trigger_on_file_creation&&H)return Ze.setChangedByMemos(!0),{id:_,content:I,deletedAt:"",createdAt:h.format("YYYY/MM/DD HH:mm:ss"),updatedAt:h.format("YYYY/MM/DD HH:mm:ss"),thinoType:t?"JOURNAL":"TASK-TODO",path:G.path,hasId:"",linkId:[],webId:k,pinned:!1,visibility:"PUBLIC",rowStatus:"NORMAL",creatorName:"Thino",resourceList:[],sourceType:"DAILY",fileInfo:{tags:[],frontmatter:{}}};let K="";try{K=await o.read(G)||await o.cachedRead(G)}catch(Z){console.error(Z),new N.Notice(E("Failed to read current daily note, check if it exists."))}const z=i.metadataCache.getFileCache(G),ne={tags:z?.frontmatter?.tags||[],frontmatter:z?.frontmatter||{}},J=await Q8(x,R,K);await o.modify(G,J.content);const ee=J.posNum===-1?eH(J.content).length-(R.split(`
|
|
|
`).length-1)-1:J.posNum+1;return Ze.setChangedByMemos(!0),{id:h.format("YYYYMMDDHHmm")+"00"+ee,content:I,deletedAt:"",createdAt:h.format("YYYY/MM/DD HH:mm:ss"),updatedAt:h.format("YYYY/MM/DD HH:mm:ss"),thinoType:t?"JOURNAL":"TASK-TODO",path:G.path,hasId:"",linkId:[],webId:k,pinned:!1,visibility:"PUBLIC",rowStatus:"NORMAL",creatorName:"Thino",resourceList:[],sourceType:"DAILY",fileInfo:ne}}async function t3(e){const{vault:t}=ke.getState().dailyNotesState.app||window.app,n=ke.getState().dailyNotesState.app||window.app,{DefaultMemoComposition:r,InsertAfter:o,DefaultTimePrefix:i,DifferentInsertTarget:a,InsertAfterForTask:s,InsertType:l,UseMemoFixedStrings:u,MemoFixedPrefix:d,MemoFixedSuffix:h}=ke.getState().dailyNotesState.settings;let p=(e.pinned?" [pinned::true]":"")+(e.rowStatus==="ARCHIVED"?" [archived::true]":"")+(e.visibility==="PRIVATE"?' [visibility::"PRIVATE"]':"");if(e.id){const $=" [webId::"+e.id+"]";p+=$}const m=N.moment();if(e.deletedAt){const $=" [deleted::"+m.format("YYYYMMDDHHmmss")+"]";p+=$}const b=n.vault.getConfig("useTab")===void 0||n.vault.getConfig("useTab")===!0,v=b?1:n.vault.getConfig("tabSize"),y=(b?" ":" ").repeat(v),S=e.content.split(`
|
|
|
`).join(`
|
|
|
`+y),x=N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss");let C="",k="";u&&(C=p0(d||"",x),k=p0(h||"",x));const M=C?C+(C.endsWith(" ")?"":" ")+S:S,I=k?M+(M.endsWith(" ")?"":" ")+k:M,O=x.format(i||"HH:mm"),R=!e.thinoType||e.thinoType==="JOURNAL"?"- ":e.thinoType==="TASK-TODO"?"- [ ] ":"- [x] ",L=r?`${R}${r?.replace(/{TIME}/g,O).replace(/{CONTENT}/g,(I.split(`
|
|
|
`).length>1||/^((-|\*|\d\.|>)\s|```)/g.test(I)?`
|
|
|
`+y:"")+I)}${I.split(`
|
|
|
`).length>1&&/```/g.test(I.split(`
|
|
|
`)[I.split(`
|
|
|
`).length-1])&&p.trim()?`
|
|
|
`+y:" "}${p}`:`${R}${O} ${I.split(`
|
|
|
`).length>1||/^((-|\*|\d\.|>)\s|```)/g.test(I)?`
|
|
|
`+y:""}${I}${I.split(`
|
|
|
`).length>1&&/```/g.test(I.split(`
|
|
|
`)[I.split(`
|
|
|
`).length-1])&&p.trim()?`
|
|
|
`+y:" "}${p}`,B=Il(),_=lS(x,B),H="fake"+Le.randomId(16);let U=!1;const G=n.plugins.getPlugin("templater-obsidian");let K;if(_?K=_:(G?.templater&&G?.settings.trigger_on_file_creation&&(de.setWaitingForTemplater({origin:e.content,date:x,isList:e.thinoType&&e.thinoType==="JOURNAL",id:H,type:"local"}),U=!0),K=await Le.createDailyNoteCheck(x)),!K){new N.Notice(E("Failed to create daily note, check if it exists.")),new N.Notice(E("Your content has been copied to clipboard, and inserted into the editor. Please try it again")),await navigator.clipboard.writeText(e.content);const $=n.workspace.getLeavesOfType("thino_view").first();n.workspace.trigger("send-to-thino",e.content,$);return}if(_||await $e.fechLocalDailyNotes(),G&&G?.templater&&G?.settings.trigger_on_file_creation&&U)return Ze.setChangedByMemos(!0),{id:H,content:e.content,deletedAt:e.deletedAt??"",createdAt:x.format("YYYY/MM/DD HH:mm:ss"),updatedAt:x.format("YYYY/MM/DD HH:mm:ss"),thinoType:e.thinoType||"JOURNAL",path:K.path,hasId:"",linkId:[],pinned:e.pinned??!1,visibility:"PUBLIC",rowStatus:e.rowStatus??"NORMAL",webId:e.webId||e.id,creatorName:"Thino",resourceList:[],sourceType:"DAILY",fileInfo:e?.fileInfo||{tags:[],frontmatter:{}}};const z=n.metadataCache.getFileCache(K),ne={tags:z?.frontmatter?.tags||[],frontmatter:z?.frontmatter||{}};let J="";try{J=await t.read(K)||await t.cachedRead(K)}catch($){console.error($),new N.Notice(E("Failed to read current daily note, check if it exists."))}const ee=l==="end"?"":e.thinoType&&a&&s||o,Z=await Q8(ee,L,J);await t.modify(K,Z.content);const q=Z.posNum===-1?eH(Z.content).length-1:Z.posNum+1;return Ze.setChangedByMemos(!0),{id:x.format("YYYYMMDDHHmm")+"00"+q,content:e.content,deletedAt:e.deletedAt??"",createdAt:x.format("YYYY/MM/DD HH:mm:ss"),updatedAt:x.format("YYYY/MM/DD HH:mm:ss"),thinoType:e.thinoType||"JOURNAL",path:K.path,hasId:"",linkId:[],pinned:e.pinned??!1,visibility:"PUBLIC",rowStatus:e.rowStatus??"NORMAL",webId:e.id,creatorName:"Thino",resourceList:[],sourceType:"DAILY",fileInfo:ne}}async function Q8(e,t,n){const r=new RegExp(`(s*?)${await yQ(e)}(s*?)`),o=bQ(n),i=o.findIndex(u=>r.test(u)),a=e?.trim()===""?!0:i===-1,s=o.slice(i+1).findIndex(u=>/(^#+ |---|^\^[a-zA-Z0-9-]{2,}$)/.test(u)),l=s!==-1;if(l){let u;for(let d=s+i;d>i;d--)if(!/^[\s\n ]*$/.test(o[d])){u=d;break}return u||(u=i),await n3(t,n,a?-1:u,l)}else return await n3(t,n,o.length-1,l)}async function n3(e,t,n,r){if(n<-1)throw new Error("Invalid position");if(n===-1)return{content:`${t}
|
|
|
${e}`,posNum:-1};const o=t.split(`
|
|
|
`),i=o.slice(0,n+1).join(`
|
|
|
`),a=o.slice(n+1).join(`
|
|
|
`),s=a.trim().length>0;return{content:`${i}${!s&&!r||!i.endsWith(`
|
|
|
`)?`
|
|
|
`:""}${e}${(s||r?`
|
|
|
`:"")+a}`,posNum:n}}const eH=e=>e.split(/\r?\n/);async function xQ(e){const t=ke.getState().dailyNotesState.app,n=t.vault.getAbstractFileByPath(e.path);if(!(n instanceof N.TFile)){new N.Notice(E("File not found for the given thino path"));return}await t.vault.delete(n)}async function IQ(e){const t=ke.getState().dailyNotesState.app,n=t.vault.getAbstractFileByPath(e.path);if(!(n instanceof N.TFile)){new N.Notice(E("File not found for the given thino path"));return}const o=(await t.vault.read(n)).split(`
|
|
|
`),i=o.findIndex(l=>l.includes(e.id));if(i===-1){new N.Notice(E("Thino not found"));return}const a=o.findIndex((l,u)=>u>i&&l.trim()==="");a===-1?o.splice(i,o.length-i):o.splice(i,a-i);const s=o.join(`
|
|
|
`);if(!s){new N.Notice(E("Thino not found"));return}Ze.setChangedByMemos(!0),await t.vault.modify(n,s)}async function kQ(e){const t=ke.getState().dailyNotesState.app,n=t.metadataCache.getFirstLinkpathDest("",e.path);if(!n){new N.Notice(E("File not found for the given thino path"));return}const r=await t.vault.read(n),o=JSON.parse(r),i=o.nodes,a=i.findIndex(d=>d.id===e.id);if(a===-1){new N.Notice(E("Thino not found"));return}i.splice(a,1);const s=o.edges;s.filter(d=>d.fromNode===e.id||d.toNode===e.id).forEach(d=>{const h=s.findIndex(p=>p.id===d.id);h!==-1&&s.splice(h,1)}),Ze.setChangedByMemos(!0);const u=JSON.stringify(o,null,2);await t.vault.modify(n,u)}async function EQ(e){$8()||new N.Notice(E("If you are disabling the daily note plugin, it would be possible that the thino will not be deleted or patched properly. Please enable the plugin and try again."),5e3);const{vault:t,metadataCache:n}=ke.getState().dailyNotesState.app,r=e.path,o=t.getAbstractFileByPath(r);if(!o){new N.Notice(E("Please check your daily note plugin OR periodic notes plugin settings"));return}const i=await t.read(o),a=i.split(`
|
|
|
`),l=n.getFileCache(o)?.listItems||[],u=parseInt(e.id.slice(14));let d=u;function h(v,y){const S=[];for(const x in y)y[x]===v&&S.push(parseInt(x),...h(parseInt(x),y));return S}const p=$M(l),m=l.find(v=>v.position.start.line===u),b=h(u,p);if(b.length>0){const v=b.map(y=>{const S=l.find(x=>x.position.start.line===y);return S?S.position.end.line:-1});d=Math.max(...v,m.position.end.line)}else d=m.position.end.line;if(!i){new N.Notice(E("Thino not found"));return}Ze.setChangedByMemos(!0),a.splice(u,d-u+1),await t.modify(o,a.join(`
|
|
|
`))}async function CQ(){const{vault:e,metadataCache:t}=ke.getState().dailyNotesState.app,n=ke.getState().dailyNotesState.settings,o=uS()+"/"+n.DeleteFileName+".md",i=[],a=t.getFirstLinkpathDest("",o);if(a instanceof N.TFile){let s=await e.read(a),l=MQ(s);if(l.length===0)return i;for(let u=0;u<l.length;u++){const d=l[u];if(/- /.test(d)){const p=DQ(d).slice(0,13),m=N.moment(p,"YYYYMMDDHHmmss"),b=NQ(l[u]),v=N.moment(b.slice(0,13),"YYYYMMDDHHmmss"),y=AQ(l[u]);i.push({id:b,content:y,user_id:1,createdAt:m.format("YYYY/MM/DD HH:mm:SS"),updatedAt:m.format("YYYY/MM/DD HH:mm:SS"),deletedAt:v})}else continue}l=null,s=null}return i}const MQ=e=>e.split(/\r?\n/),DQ=e=>/^- (\d{14})(\d+)\s(.+)\s(deletedAt: )(.+)$/.exec(e)?.[1],AQ=e=>/^- (\d+)\s(.+)\s(deletedAt: )(.+)$/.exec(e)?.[2],NQ=e=>/^- (\d+)\s(.+)\s(deletedAt: )(.+)$/.exec(e)?.[4];async function OQ(e){const t=await hh(ke.getState().dailyNotesState.app)||[],n=t.findIndex(r=>r.id===e);t.splice(n,1),await Xg(ke.getState().dailyNotesState.app,t)}const PQ=async e=>{const{app:t}=ke.getState().dailyNotesState,n=await hh(t)||[],r=n.find(o=>o.id===e);if(r){const o=N.moment().format("YYYY/MM/DD HH:mm:ss");return r.pinnedAt=o,await Xg(t,n),o}else{new N.Notice(E("Query not found"));return}},jQ=async e=>{const{app:t}=ke.getState().dailyNotesState,n=await hh(t)||[],r=n.find(o=>o.id===e);if(r){r.pinnedAt="",await Xg(t,n);return}else{new N.Notice(E("Query not found"));return}};var tE;(e=>{async function t(v){return await QP(v)}e.getMyMemos=t;async function n(v){return await QP([v])}e.updateSpecificTypeMemo=n;function r(){return CQ()}e.getMyDeletedMemos=r;function o(v){const y=de.getMemoById(v);if(y)switch(y?.sourceType){case"DAILY":return si(y,{id:y.id,deleted:!1});case"CANVAS":return Xa(y,{id:y.id,deleted:!1});case"MULTI":return aa(y,{id:y.id,deleted:!1});case"FILE":return Ka(y,{id:y.id,deleted:!1})}}e.restoreMemo=o;function i(v){return IQ(v)}e.deleteMemoInSingleFile=i;function a(v){return xQ(v)}e.deleteMemoInMultiFiles=a;function s(v){return EQ(v)}e.deleteMemoInDailyNote=s;function l(v){return kQ(v)}e.deleteMemoInCanvas=l;function u(){return zq()}e.getMyQueries=u;async function d(v,y){return await Wq(v,y)}e.createQuery=d;function h(v,y,S){return lQ(v,y,S)}e.updateQuery=h;function p(v){return OQ(v)}e.deleteQueryById=p;function m(v){return PQ(v)}e.pinQuery=m;function b(v){return jQ(v)}e.unpinQuery=b})(tE||(tE={}));const Lo=tE;async function LQ(e,t,n,r,o){const{vault:i,metadataCache:a}=ke.getState().dailyNotesState.app===void 0?app:ke.getState().dailyNotesState.app;ke.getState().dailyNotesState.settings;const s=e.replace(/\n/g,"<br>");if(n===void 0)return;const l=a.getFirstLinkpathDest("",n),u=N.moment(),d=u.format("YYYYMMDDHHmmss");r.slice(14);const h=" ",p=d+" "+s.trim(),m=h+"- "+d+" "+s.trim();if(l){const b=await i.read(l),v=0,y=await RQ(m,b,v);if(await i.modify(l,y.content),t)return{id:d+(v+1),content:p,deletedAt:"",createdAt:u.format("YYYY/MM/DD HH:mm:ss"),updatedAt:N.moment().format("YYYY/MM/DD HH:mm:ss"),thinoType:"JOURNAL",path:l.path,hasId:"",linkId:[o]}}}async function RQ(e,t,n){if(n===-1)return{content:`${t}
|
|
|
${e}`,posNum:-1};const r=t.split(`
|
|
|
`),o=r.slice(0,n+1).join(`
|
|
|
`),i=r.slice(n+1).join(`
|
|
|
`);return/^\s*$/g.test(r[n+1])?{content:`${o}
|
|
|
${e}
|
|
|
${i}`,posNum:n}:{content:`${o}
|
|
|
${e}
|
|
|
${i}`,posNum:n}}function FQ(e,t,n){const r=t.workspace.getLeavesOfType("markdown");for(const o of r)if(o.view?.file?.path===e){t.workspace.revealLeaf(o);try{return o.view.setEphemeralState({line:n}),!0}catch(a){return console.error(a),!1}}return!1}const XM=async e=>{const t=$e.getState().app,n=t.workspace.getLeavesOfType("markdown");for(const i of n)if(i.view?.file?.path===e){t.workspace.revealLeaf(i);return}const r=t.metadataCache.getFirstLinkpathDest("",e);if(!r){new N.Notice(E("File not found for the given thino path"));return}await t.workspace.getLeaf(!0).openFile(r)},JM=async(e,t)=>{const{app:n}=$e.getState(),r=parseInt(e.slice(14));if(FQ(t,n,r))return;const o=n.metadataCache.getFirstLinkpathDest("",t);if(!N.Platform.isMobile)await n.workspace.getLeaf(!0).openFile(o,{eState:{line:r}});else{let i=n.workspace.activeLeaf;i===null&&(i=n.workspace.getLeaf(!0)),await i.openFile(o,{eState:{line:r}})}},QM=async(e,t)=>{const n=$e.getState().app,r=n.metadataCache.getFirstLinkpathDest("",t);if(!r){new N.Notice(E("File not found for the given thino path"));return}let o="";try{o=await n.vault.read(r)}catch(u){console.error(u),o=await n.vault.cachedRead(r)}const a=o.split(/\r?\n/).findIndex(u=>u.contains(e)),s=n.workspace.getLeavesOfType("markdown");for(const u of s)if(u.view?.file?.path===r.path){n.workspace.revealLeaf(u);try{u.view.editor?.setCursor({line:a,ch:1});return}catch(h){console.error(h)}}const l=n.workspace.getLeaf(!0);await l.openFile(r,{eState:{line:a}});try{l.view.editor?.setCursor({line:a,ch:1})}catch(u){console.error(u)}},eD=async(e,t)=>{const n=$e.getState().app,r=(s,l)=>{const u=Array.from(s.nodes.values())?.find(d=>d.id===l);return u?(s.selectOnly(u),s.zoomToSelection(),!0):!1},o=n.workspace.getLeavesOfType("canvas");for(const s of o){const l=s.view;if(l?.file?.path===t&&(n.workspace.revealLeaf(s),r(l.canvas,e)))return}const i=n.metadataCache.getFirstLinkpathDest("",t);if(!i){new N.Notice(E("File not found for the given thino path"));return}const a=n.workspace.getLeaf(!0);await a.openFile(i),setTimeout(()=>{r(a.view?.canvas,e)},10)};class HQ{initialized=!1;getState(){return ke.getState().memoState}async fetchAllMemos(){const t=$e.getState().settings;Le.checkDailyInMulti(t);const n=await Lo.getMyMemos(t.EnabledLocationList.map(i=>i.value)),r=[...n.memos],o=[...n.commentMemos];return ke.dispatch({type:"SET_MEMOS",payload:{memos:r}}),ke.dispatch({type:"SET_COMMENT_MEMOS",payload:{commentMemos:o}}),this.initialized||(this.initialized=!0,Ze.setLoaded(!0)),r}async updateTypeMemos(t){const n=await Lo.updateSpecificTypeMemo(t),r=this.getState().memos.filter(o=>o.sourceType!==t);ke.dispatch({type:"SET_MEMOS",payload:{memos:[...r,...n.memos]}})}async removeTypeMemos(t){const n=this.getState().memos.filter(r=>r.sourceType!==t);ke.dispatch({type:"SET_MEMOS",payload:{memos:[...n]}})}async fetchDeletedMemos(){const t=await Lo.getMyDeletedMemos();return t.sort((n,r)=>Le.getTimeStampByDate(r.deletedAt)-Le.getTimeStampByDate(n.deletedAt)),t}pushMemo(t){ke.dispatch({type:"INSERT_MEMO",payload:{memo:{...t}}})}pushCommentMemo(t){ke.dispatch({type:"INSERT_COMMENT_MEMO",payload:{memo:{...t}}})}getMemoById(t){for(const n of this.getState().memos)if(n.id===t)return n;return null}getCommentMemoById(t){for(const n of this.getState().commentMemos)if(n.id===t)return n;return null}getMemoByWebId(t){for(const n of this.getState().memos)if(n.webId===t||n.id===t)return n;return null}async finishWaitingForTemplaterThinos(){const t=this.getState().preparingUpdateMemo;if(t.length!==0)for(const n of t){const r=this.getMemoById(n.id),o=n.type==="local"?await Px(n.origin,n.isList,n.date,!0):await t3(r);await this.replaceOldThinoWithNewThino(n.id,o),ke.dispatch({type:"REMOVE_PARTICULAR_PREPARE_UPDATE_THINO",payload:{id:n.id}})}}async replaceOldThinoWithNewThino(t,n){this.getMemoById(t)&&ke.dispatch({type:"REPLACE_MEMO_BY_ID",payload:{id:t,memo:n}})}async updateMemoById(t,n,r){const o=this.getMemoByWebId(t);if(!o)return;let i=null;const a=r?{}:{content:n.content,rowStatus:n.rowStatus,pinned:n.pinned,deleted:!!n.deletedAt,thinoType:n.thinoType||"JOURNAL"};if(L8({...o,deleted:!!n.deletedAt},{...a,webId:n.id}))return o;switch(o.sourceType){case"DAILY":i=await si(o,{id:o.id,webId:n.id,...a});break;case"CANVAS":i=await Xa(o,{id:o.id,webId:n.id,...a});break;case"MULTI":i=await aa(o,{id:o.id,webId:n.id,...a});break;case"FILE":i=await Ka(o,{id:o.id,webId:n.id,...a});break}if(!i)return o;ke.dispatch({type:"EDIT_MEMO",payload:i})}async archiveThinoBulk(t){const n=[];for(const r of t){let o;switch(r.sourceType){case"DAILY":o=await si(r,{id:r.id,rowStatus:"ARCHIVED"}),n.push(o);break;case"CANVAS":o=await Xa(r,{id:r.id,rowStatus:"ARCHIVED"}),n.push(o);break;case"MULTI":o=await aa(r,{id:r.id,rowStatus:"ARCHIVED"}),n.push(o);break;case"FILE":o=await Ka(r,{id:r.id,rowStatus:"ARCHIVED"}),n.push(o);break}}return n.length>0?(ke.dispatch({type:"ARCHIVE_MEMO_BY_ID_BULK",payload:n}),n):t}async dealWithDailyThinoBulk(t,n,r){const o=await zJ(t,n,r);return r==="deleteForever"?await this.deleteThinosWithIdBulk(o.map(i=>i.id)):this.editMemoBulk(o),o}async deleteThinosWithIdBulk(t){for(const n of t)ke.dispatch({type:"DELETE_MEMO_BY_ID",payload:{id:n}})}async archiveMemo(t){let n=null;switch(t.sourceType){case"DAILY":n=await si(t,{id:t.id,rowStatus:"ARCHIVED"});break;case"CANVAS":n=await Xa(t,{id:t.id,rowStatus:"ARCHIVED"});break;case"MULTI":n=await aa(t,{id:t.id,rowStatus:"ARCHIVED"});break;case"FILE":n=await Ka(t,{id:t.id,rowStatus:"ARCHIVED"});break}return n?(ke.dispatch({type:"ARCHIVE_MEMO_BY_ID",payload:n}),n):t}async pushToUpdateList(t,n){ke.dispatch({type:"PREPARE_UPDATE_THINO",payload:{thino:t,originalId:n}})}async removePrepareUpdateThinoById(t){ke.dispatch({type:"REMOVE_PARTICULAR_PREPARE_UPDATE_THINO",payload:{id:t}})}async removePrepareUpdateThino(){ke.dispatch({type:"REMOVE_PREPARE_UPDATE_THINO",payload:null})}async unarchiveThinoBulk(t){const n=[];for(const r of t){let o;switch(r.sourceType){case"DAILY":o=await si(r,{id:r.id,rowStatus:"NORMAL"}),n.push(o);break;case"CANVAS":o=await Xa(r,{id:r.id,rowStatus:"NORMAL"}),n.push(o);break;case"MULTI":o=await aa(r,{id:r.id,rowStatus:"NORMAL"}),n.push(o);break;case"FILE":o=await Ka(r,{id:r.id,rowStatus:"NORMAL"}),n.push(o);break}}return n.length>0?(ke.dispatch({type:"ARCHIVE_MEMO_BY_ID_BULK",payload:n}),n):t}async unarchiveMemo(t){let n=null;switch(t.sourceType){case"DAILY":n=await si(t,{id:t.id,rowStatus:"NORMAL"});break;case"CANVAS":n=await Xa(t,{id:t.id,rowStatus:"NORMAL"});break;case"MULTI":n=await aa(t,{id:t.id,rowStatus:"NORMAL"});break;case"FILE":n=await Ka(t,{id:t.id,rowStatus:"NORMAL"});break}return ke.dispatch({type:"UNARCHIVE_MEMO_BY_ID",payload:n}),n}async hideMemoById(t){const n=this.getMemoById(t);if(!n)return n;let r=null;switch(n.sourceType){case"DAILY":r=await si(n,{id:n.id,deleted:!0});break;case"CANVAS":r=await Xa(n,{id:n.id,deleted:!0});break;case"MULTI":r=await aa(n,{id:n.id,deleted:!0});break;case"FILE":r=await Ka(n,{id:n.id,deleted:!0});break}if(!r)return n;if(r)return r}async restoreMemoById(t){return await Lo.restoreMemo(t)}async deleteMemoById(t,n){const r=this.getMemoById(t);try{switch(r.sourceType){case"DAILY":await Lo.deleteMemoInDailyNote(r);break;case"CANVAS":await Lo.deleteMemoInCanvas(r);break;case"MULTI":await Lo.deleteMemoInMultiFiles(r);break;case"FILE":await Lo.deleteMemoInSingleFile(r);break}ke.dispatch({type:"DELETE_MEMO_BY_ID",payload:{id:t}})}catch(s){console.error(s),new N.Notice(E("Failed to delete memo"))}if(n&&n==="local")return;const o=$e.getState().settings;!$e.getState().app?.loadLocalStorage("tokenForSync")||!o.startSync||r.webId&&await KM(r.webId)}async removeMemosInFile(t,n){const r=[];try{if(t.path.endsWith(".md")&&!t.path.contains(".thino")&&!n){const i=this.getState().memos.filter(a=>a.path.trim()===t.path.trim());r.push(...i)}else if(t.path.contains("thino.canvas")){const i=this.getState().memos.filter(a=>a.path.trim()===t.path.trim());r.push(...i)}else if(t?.parent?.path.contains(n)||!t?.parent&&!t?.parent?.path){const i=this.getState().memos.filter(a=>a.path.trim()===t.path.trim());i.length>0&&r.push(...i)}else t.path.endsWith(".md")&&t.path.contains(".thino")&&await eE(t,r);const o=r.map(i=>i.id);ke.dispatch({type:"DELETE_MEMO_BY_ID_BATCH",payload:{ids:o}})}catch(o){console.error(o)}}async removeThinosByPath(t){const r=this.getState().memos.filter(o=>o.path===t).map(o=>o.id);ke.dispatch({type:"DELETE_MEMO_BY_ID_BATCH",payload:{ids:r}})}async updateMemosInFile(t,n){const r=[],o=async()=>{if(t.path.endsWith(".md")&&!t.path.contains(".thino")&&!n){await X8(t,r);return}else if(t.path.contains("thino.canvas")){await J8(t,r);return}else if(t?.parent?.path.contains(n)&&!t.path.endsWith(".thino.md")){await K8(t,r);return}else if(t.path.endsWith(".thino.md")){await eE(t,r);return}};try{await o(),ke.dispatch({type:"UPDATE_MEMO_BATCH",payload:{memos:r,path:t.path}}),this.editMemoBulk(r)}catch(i){console.error(i)}}async updateMemoProperty(t){const n=Le.randomId(16),r=await aa(t,{id:n});ke.dispatch({type:"EDIT_MEMO_PATH",payload:r})}editMemo(t,n=!1){const r=t.webId;ke.dispatch({type:"EDIT_MEMO",payload:t});const o=$e.getState().plugin;o&&!n&&o.thinoWorkerManager.memoUpdated(t.id);const i=$e.getState().settings;if(!(!$e.getState().app?.loadLocalStorage("tokenForSync")||!i.startSync))try{t&&r&&Ox({id:r,content:t.content,rowStatus:t.rowStatus,pinned:t.pinned,ttime:t.deletedAt?N.moment(t.deletedAt,"YYYY/MM/DD HH:mm:ss").valueOf():0,thinoType:t.sourceType==="DAILY"?"DAILY":"FILE",thinoStatus:t.thinoType==="JOURNAL"?"JOURNAL":t.thinoType==="TASK-TODO"?"TASK-TODO":"TASK-DONE"})}catch(l){console.error(l)}}editMemoBulk(t){const n=$e.getState().plugin;n&&n.thinoWorkerManager.memosUpdated(t.map(r=>r.id));for(const r of t)this.editMemo(r,!0);this.updateTagsState()}editCommentMemo(t){ke.dispatch({type:"EDIT_COMMENT_MEMO",payload:t})}getThinoViaKeyword(t){const{memos:n}=this.getState();return n.filter(o=>o.content.toLowerCase().includes(t?.toLowerCase()))}updateTagsStateThrottled=Le.throttle(()=>{const{memos:t}=this.getState(),{plugin:n}=$e.getState();!n||!t||t.length===0||n.thinoWorkerManager.buildTagTree(t).then(({tagsSet:r,counts:o})=>{ke.dispatch({type:"SET_TAGS",payload:{tags:Array.from(r),tagsNum:o}})})},300);async throttleUpdateTagsState(){this.updateTagsStateThrottled()}updateTagsState(){this.updateTagsStateThrottled()}clearMemos(){ke.dispatch({type:"SET_MEMOS",payload:{memos:[]}})}async getLinkedMemos(t){const{memos:n}=this.getState();return n.filter(r=>r.content.includes(t))}async getLinkedMemoByBlockId(t,n){const{memos:r}=this.getState();return r.find(o=>o.hasId===t?n&&o.path?o.path.includes(n)||n.includes(o.path):!0:!1)}async getLinkedMemosByLinkId(t,n){const{memos:r}=this.getState(),o=`${n}#^${t}`;return r.filter(i=>i.linkId?i.linkId.some(a=>a===o||n&&a.endsWith(`#^${t}`)):!1)}async getCommentMemos(t){const{memos:n}=this.getState();return n.filter(r=>r.content.includes("comment: "+t))}async createMemoMultiFile({content:t,isList:n,name:r}){return await wQ({content:t,isList:n,name:r})}async createMemoSingleFile({content:t,isList:n}){return await SQ({content:t,isList:n})}async createOrPatchThinoFromWeb(t){const n=this.getState().memos;if(t.localId&&n?.some(i=>i.id===t.localId))return await this.updateMemoById(t.localId,t,!0),null;if(n?.some(i=>i.id===t.id)||n?.some(i=>i.webId===t.id))return await this.updateMemoById(t.id,t,!1),null;let r=t.sourceType;const o=$e.getState().settings;switch(o&&o?.saveThinoType&&(r=o.saveThinoType!=="FILE"?o.saveThinoType:t.sourceType),r){case"FILE":case"MULTI":case"CANVAS":return await e3(t);case"DAILY":return await t3(t);default:return await e3(t)}}async initSync(){const n=this.getState().memos.filter(o=>!o.webId),r=await vQ(n);for(const o of r)await this.createOrPatchThinoFromWeb(o)}async createMemoCanvas({text:t,isList:n}){return await TQ({content:t,isList:n})}async createMemoDaily(t,n){return await Px(t,n)}setWaitingForTemplater({origin:t,date:n,isList:r,id:o,type:i}){ke.dispatch({type:"SET_WAITING_FOR_TEMPLATER",payload:{origin:t,date:n,isList:r,id:o,type:i}})}async pinMemoById(t){const n=this.getMemoById(t),r=await VJ(n);ke.dispatch({type:"PIN_MEMO",payload:r});try{const o=$e.getState().settings;if($e.getState().app?.loadLocalStorage("tokenForSync")&&o.startSync){const s=await Ox({id:r.webId,pinned:!0});this.editMemo(s)}}catch(o){console.error(o)}}async unpinMemoById(t){const n=this.getMemoById(t),r=await WJ(n);ke.dispatch({type:"PIN_MEMO",payload:r});try{const o=$e.getState().settings;if($e.getState().app?.loadLocalStorage("tokenForSync")&&o.startSync){const s=await Ox({id:r.webId,pinned:!1});this.editMemo(s)}}catch(o){console.error(o)}}async createCommentMemo(t,n,r,o,i){return await LQ(t,n,r,o,i)}async importMemos(t,n,r){return await Px(t,n,r)}async createThino({content:t,isList:n,type:r,name:o}){let i=null;switch(r.toLowerCase()){case"canvas":i=await de.createMemoCanvas({text:t,isList:n});break;case"multi":i=await de.createMemoMultiFile({content:t,isList:n,name:o});break;case"daily":i=await de.createMemoDaily(t,n);break;case"file":i=await de.createMemoSingleFile({content:t,isList:n});break;default:i=await de.createMemoDaily(t,n);break}const a=$e.getState().settings,s=$e.getState().app,l=$e.getState().plugin;l&&l.thinoWorkerManager.memoUpdated(i.id);const u=s?.loadLocalStorage("tokenForSync");return i&&u&&a.startSync&&r!=="DAILY"&&setTimeout(async()=>{try{const d=await qM({content:t,thinoType:"FILE",thinoStatus:n?"JOURNAL":"TASK-TODO"});await this.updateMemoById(i.id,d,!0)}catch(d){console.error(d)}},200),i}async openThinoByID(t){const n=this.getMemoById(t);if(n)switch(n.sourceType){case"DAILY":await JM(n.id,n.path);break;case"CANVAS":await eD(n.id,n.path);break;case"MULTI":await XM(n.path);break;case"FILE":await QM(n.id,n.path);break}}async updateMemo(t,n,r){const o=this.getMemoById(t);if(o){let i=null;switch(o.sourceType){case"DAILY":i=await si(o,{id:o.id,content:n,thinoType:r||o.thinoType});break;case"CANVAS":i=await Xa(o,{id:o.id,content:n,thinoType:r||o.thinoType});break;case"MULTI":i=await aa(o,{id:o.id,content:n,thinoType:r||o.thinoType});break;case"FILE":i=await Ka(o,{id:o.id,content:n,thinoType:r||o.thinoType})}if(i)return i}return o}}const de=new HQ;class _Q{getState(){return ke.getState().queryState}async getMyAllQueries(){const t=Ue.getState().query.filter,n=this.getQueryById(t),r=await Lo.getMyQueries();return ke.dispatch({type:"SET_QUERIES",payload:{queries:[...r,...n?[n]:[]]}}),r}getQueryById(t){return this.getState().queries.find(n=>n.id===t)}pushQuery(t){ke.dispatch({type:"INSERT_QUERY",payload:{query:{...t}}})}editQuery(t){ke.dispatch({type:"UPDATE_QUERY",payload:t})}async deleteQuery(t){await Lo.deleteQueryById(t),ke.dispatch({type:"DELETE_QUERY_BY_ID",payload:{id:t}})}async createQuery(t,n){return await Lo.createQuery(t,n)}createTempQuery(t,n){return Vq(t,n)}async updateQuery(t,n,r){return await Lo.updateQuery(t,n,r)}async pinQuery(t){await Lo.pinQuery(t)}async unpinQuery(t){await Lo.unpinQuery(t)}}const Ct=new _Q;class BQ{async upload(t){const{vault:n,fileManager:r}=ke.getState().dailyNotesState.app,o=await t.arrayBuffer(),i=YQ(t.type),a=Il(),s=N.moment(),l=lS(s,a);let u;if(l)l instanceof N.TFile&&(u=await n.createBinary(await n.getAvailablePathForAttachments(`Pasted Image ${N.moment().format("YYYYMMDDHHmmss")}`,i,l),o));else{const d=await O8(s);u=await n.createBinary(await n.getAvailablePathForAttachments(`Pasted Image ${N.moment().format("YYYYMMDDHHmmss")}`,i,d),o)}return r.generateMarkdownLink(u,u.path,"","")}async parseHtml(t){const n=await t.text(),r=document.createElement("html");r.innerHTML=n;const o=Array.from(r.getElementsByClassName("memo"));for(const i of o){const a=i.getElementsByClassName("content")[0],s=N.htmlToMarkdown(a.innerHTML),l=await de.importMemos(s,!0,N.moment(i.getElementsByClassName("time")[0].innerHTML));de.pushMemo(l)}}}const YQ=e=>/^image\/(.+)$/.exec(e)?.[1],tD=new BQ;var Fi={},tH={exports:{}},jo={},jx={exports:{}},Lx={},r3;function UQ(){return r3||(r3=1,function(e){function t(J,ee){var Z=J.length;J.push(ee);e:for(;0<Z;){var q=Z-1>>>1,$=J[q];if(0<o($,ee))J[q]=ee,J[Z]=$,Z=q;else break e}}function n(J){return J.length===0?null:J[0]}function r(J){if(J.length===0)return null;var ee=J[0],Z=J.pop();if(Z!==ee){J[0]=Z;e:for(var q=0,$=J.length,re=$>>>1;q<re;){var le=2*(q+1)-1,ie=J[le],fe=le+1,ye=J[fe];if(0>o(ie,Z))fe<$&&0>o(ye,ie)?(J[q]=ye,J[fe]=Z,q=fe):(J[q]=ie,J[le]=Z,q=le);else if(fe<$&&0>o(ye,Z))J[q]=ye,J[fe]=Z,q=fe;else break e}}return ee}function o(J,ee){var Z=J.sortIndex-ee.sortIndex;return Z!==0?Z:J.id-ee.id}if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var a=Date,s=a.now();e.unstable_now=function(){return a.now()-s}}var l=[],u=[],d=1,h=null,p=3,m=!1,b=!1,v=!1,y=typeof setTimeout=="function"?setTimeout:null,S=typeof clearTimeout=="function"?clearTimeout:null,x=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function C(J){for(var ee=n(u);ee!==null;){if(ee.callback===null)r(u);else if(ee.startTime<=J)r(u),ee.sortIndex=ee.expirationTime,t(l,ee);else break;ee=n(u)}}function k(J){if(v=!1,C(J),!b)if(n(l)!==null)b=!0,z(M);else{var ee=n(u);ee!==null&&ne(k,ee.startTime-J)}}function M(J,ee){b=!1,v&&(v=!1,S(R),R=-1),m=!0;var Z=p;try{for(C(ee),h=n(l);h!==null&&(!(h.expirationTime>ee)||J&&!_());){var q=h.callback;if(typeof q=="function"){h.callback=null,p=h.priorityLevel;var $=q(h.expirationTime<=ee);ee=e.unstable_now(),typeof $=="function"?h.callback=$:h===n(l)&&r(l),C(ee)}else r(l);h=n(l)}if(h!==null)var re=!0;else{var le=n(u);le!==null&&ne(k,le.startTime-ee),re=!1}return re}finally{h=null,p=Z,m=!1}}var I=!1,O=null,R=-1,L=5,B=-1;function _(){return!(e.unstable_now()-B<L)}function H(){if(O!==null){var J=e.unstable_now();B=J;var ee=!0;try{ee=O(!0,J)}finally{ee?U():(I=!1,O=null)}}else I=!1}var U;if(typeof x=="function")U=function(){x(H)};else if(typeof MessageChannel<"u"){var G=new MessageChannel,K=G.port2;G.port1.onmessage=H,U=function(){K.postMessage(null)}}else U=function(){y(H,0)};function z(J){O=J,I||(I=!0,U())}function ne(J,ee){R=y(function(){J(e.unstable_now())},ee)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(J){J.callback=null},e.unstable_continueExecution=function(){b||m||(b=!0,z(M))},e.unstable_forceFrameRate=function(J){0>J||125<J?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):L=0<J?Math.floor(1e3/J):5},e.unstable_getCurrentPriorityLevel=function(){return p},e.unstable_getFirstCallbackNode=function(){return n(l)},e.unstable_next=function(J){switch(p){case 1:case 2:case 3:var ee=3;break;default:ee=p}var Z=p;p=ee;try{return J()}finally{p=Z}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(J,ee){switch(J){case 1:case 2:case 3:case 4:case 5:break;default:J=3}var Z=p;p=J;try{return ee()}finally{p=Z}},e.unstable_scheduleCallback=function(J,ee,Z){var q=e.unstable_now();switch(typeof Z=="object"&&Z!==null?(Z=Z.delay,Z=typeof Z=="number"&&0<Z?q+Z:q):Z=q,J){case 1:var $=-1;break;case 2:$=250;break;case 5:$=1073741823;break;case 4:$=1e4;break;default:$=5e3}return $=Z+$,J={id:d++,callback:ee,priorityLevel:J,startTime:Z,expirationTime:$,sortIndex:-1},Z>q?(J.sortIndex=Z,t(u,J),n(l)===null&&J===n(u)&&(v?(S(R),R=-1):v=!0,ne(k,Z-q))):(J.sortIndex=$,t(l,J),b||m||(b=!0,z(M))),J},e.unstable_shouldYield=_,e.unstable_wrapCallback=function(J){var ee=p;return function(){var Z=p;p=ee;try{return J.apply(this,arguments)}finally{p=Z}}}}(Lx)),Lx}var o3;function zQ(){return o3||(o3=1,jx.exports=UQ()),jx.exports}var i3;function VQ(){if(i3)return jo;i3=1;var e=D,t=zQ();function n(c){for(var f="https://reactjs.org/docs/error-decoder.html?invariant="+c,g=1;g<arguments.length;g++)f+="&args[]="+encodeURIComponent(arguments[g]);return"Minified React error #"+c+"; visit "+f+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var r=new Set,o={};function i(c,f){a(c,f),a(c+"Capture",f)}function a(c,f){for(o[c]=f,c=0;c<f.length;c++)r.add(f[c])}var s=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),l=Object.prototype.hasOwnProperty,u=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,d={},h={};function p(c){return l.call(h,c)?!0:l.call(d,c)?!1:u.test(c)?h[c]=!0:(d[c]=!0,!1)}function m(c,f,g,T){if(g!==null&&g.type===0)return!1;switch(typeof f){case"function":case"symbol":return!0;case"boolean":return T?!1:g!==null?!g.acceptsBooleans:(c=c.toLowerCase().slice(0,5),c!=="data-"&&c!=="aria-");default:return!1}}function b(c,f,g,T){if(f===null||typeof f>"u"||m(c,f,g,T))return!0;if(T)return!1;if(g!==null)switch(g.type){case 3:return!f;case 4:return f===!1;case 5:return isNaN(f);case 6:return isNaN(f)||1>f}return!1}function v(c,f,g,T,A,F,X){this.acceptsBooleans=f===2||f===3||f===4,this.attributeName=T,this.attributeNamespace=A,this.mustUseProperty=g,this.propertyName=c,this.type=f,this.sanitizeURL=F,this.removeEmptyString=X}var y={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(c){y[c]=new v(c,0,!1,c,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(c){var f=c[0];y[f]=new v(f,1,!1,c[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(c){y[c]=new v(c,2,!1,c.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(c){y[c]=new v(c,2,!1,c,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(c){y[c]=new v(c,3,!1,c.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(c){y[c]=new v(c,3,!0,c,null,!1,!1)}),["capture","download"].forEach(function(c){y[c]=new v(c,4,!1,c,null,!1,!1)}),["cols","rows","size","span"].forEach(function(c){y[c]=new v(c,6,!1,c,null,!1,!1)}),["rowSpan","start"].forEach(function(c){y[c]=new v(c,5,!1,c.toLowerCase(),null,!1,!1)});var S=/[\-:]([a-z])/g;function x(c){return c[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(c){var f=c.replace(S,x);y[f]=new v(f,1,!1,c,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(c){var f=c.replace(S,x);y[f]=new v(f,1,!1,c,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(c){var f=c.replace(S,x);y[f]=new v(f,1,!1,c,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(c){y[c]=new v(c,1,!1,c.toLowerCase(),null,!1,!1)}),y.xlinkHref=new v("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(c){y[c]=new v(c,1,!1,c.toLowerCase(),null,!0,!0)});function C(c,f,g,T){var A=y.hasOwnProperty(f)?y[f]:null;(A!==null?A.type!==0:T||!(2<f.length)||f[0]!=="o"&&f[0]!=="O"||f[1]!=="n"&&f[1]!=="N")&&(b(f,g,A,T)&&(g=null),T||A===null?p(f)&&(g===null?c.removeAttribute(f):c.setAttribute(f,""+g)):A.mustUseProperty?c[A.propertyName]=g===null?A.type===3?!1:"":g:(f=A.attributeName,T=A.attributeNamespace,g===null?c.removeAttribute(f):(A=A.type,g=A===3||A===4&&g===!0?"":""+g,T?c.setAttributeNS(T,f,g):c.setAttribute(f,g))))}var k=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,M=Symbol.for("react.element"),I=Symbol.for("react.portal"),O=Symbol.for("react.fragment"),R=Symbol.for("react.strict_mode"),L=Symbol.for("react.profiler"),B=Symbol.for("react.provider"),_=Symbol.for("react.context"),H=Symbol.for("react.forward_ref"),U=Symbol.for("react.suspense"),G=Symbol.for("react.suspense_list"),K=Symbol.for("react.memo"),z=Symbol.for("react.lazy"),ne=Symbol.for("react.offscreen"),J=Symbol.iterator;function ee(c){return c===null||typeof c!="object"?null:(c=J&&c[J]||c["@@iterator"],typeof c=="function"?c:null)}var Z=Object.assign,q;function $(c){if(q===void 0)try{throw Error()}catch(g){var f=g.stack.trim().match(/\n( *(at )?)/);q=f&&f[1]||""}return`
|
|
|
`+q+c}var re=!1;function le(c,f){if(!c||re)return"";re=!0;var g=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(f)if(f=function(){throw Error()},Object.defineProperty(f.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(f,[])}catch(Ee){var T=Ee}Reflect.construct(c,[],f)}else{try{f.call()}catch(Ee){T=Ee}c.call(f.prototype)}else{try{throw Error()}catch(Ee){T=Ee}c()}}catch(Ee){if(Ee&&T&&typeof Ee.stack=="string"){for(var A=Ee.stack.split(`
|
|
|
`),F=T.stack.split(`
|
|
|
`),X=A.length-1,se=F.length-1;1<=X&&0<=se&&A[X]!==F[se];)se--;for(;1<=X&&0<=se;X--,se--)if(A[X]!==F[se]){if(X!==1||se!==1)do if(X--,se--,0>se||A[X]!==F[se]){var ue=`
|
|
|
`+A[X].replace(" at new "," at ");return c.displayName&&ue.includes("<anonymous>")&&(ue=ue.replace("<anonymous>",c.displayName)),ue}while(1<=X&&0<=se);break}}}finally{re=!1,Error.prepareStackTrace=g}return(c=c?c.displayName||c.name:"")?$(c):""}function ie(c){switch(c.tag){case 5:return $(c.type);case 16:return $("Lazy");case 13:return $("Suspense");case 19:return $("SuspenseList");case 0:case 2:case 15:return c=le(c.type,!1),c;case 11:return c=le(c.type.render,!1),c;case 1:return c=le(c.type,!0),c;default:return""}}function fe(c){if(c==null)return null;if(typeof c=="function")return c.displayName||c.name||null;if(typeof c=="string")return c;switch(c){case O:return"Fragment";case I:return"Portal";case L:return"Profiler";case R:return"StrictMode";case U:return"Suspense";case G:return"SuspenseList"}if(typeof c=="object")switch(c.$$typeof){case _:return(c.displayName||"Context")+".Consumer";case B:return(c._context.displayName||"Context")+".Provider";case H:var f=c.render;return c=c.displayName,c||(c=f.displayName||f.name||"",c=c!==""?"ForwardRef("+c+")":"ForwardRef"),c;case K:return f=c.displayName||null,f!==null?f:fe(c.type)||"Memo";case z:f=c._payload,c=c._init;try{return fe(c(f))}catch{}}return null}function ye(c){var f=c.type;switch(c.tag){case 24:return"Cache";case 9:return(f.displayName||"Context")+".Consumer";case 10:return(f._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return c=f.render,c=c.displayName||c.name||"",f.displayName||(c!==""?"ForwardRef("+c+")":"ForwardRef");case 7:return"Fragment";case 5:return f;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return fe(f);case 8:return f===R?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof f=="function")return f.displayName||f.name||null;if(typeof f=="string")return f}return null}function ge(c){switch(typeof c){case"boolean":case"number":case"string":case"undefined":return c;case"object":return c;default:return""}}function me(c){var f=c.type;return(c=c.nodeName)&&c.toLowerCase()==="input"&&(f==="checkbox"||f==="radio")}function Ce(c){var f=me(c)?"checked":"value",g=Object.getOwnPropertyDescriptor(c.constructor.prototype,f),T=""+c[f];if(!c.hasOwnProperty(f)&&typeof g<"u"&&typeof g.get=="function"&&typeof g.set=="function"){var A=g.get,F=g.set;return Object.defineProperty(c,f,{configurable:!0,get:function(){return A.call(this)},set:function(X){T=""+X,F.call(this,X)}}),Object.defineProperty(c,f,{enumerable:g.enumerable}),{getValue:function(){return T},setValue:function(X){T=""+X},stopTracking:function(){c._valueTracker=null,delete c[f]}}}}function je(c){c._valueTracker||(c._valueTracker=Ce(c))}function Ie(c){if(!c)return!1;var f=c._valueTracker;if(!f)return!0;var g=f.getValue(),T="";return c&&(T=me(c)?c.checked?"true":"false":c.value),c=T,c!==g?(f.setValue(c),!0):!1}function Fe(c){if(c=c||(typeof document<"u"?document:void 0),typeof c>"u")return null;try{return c.activeElement||c.body}catch{return c.body}}function ce(c,f){var g=f.checked;return Z({},f,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:g??c._wrapperState.initialChecked})}function Ne(c,f){var g=f.defaultValue==null?"":f.defaultValue,T=f.checked!=null?f.checked:f.defaultChecked;g=ge(f.value!=null?f.value:g),c._wrapperState={initialChecked:T,initialValue:g,controlled:f.type==="checkbox"||f.type==="radio"?f.checked!=null:f.value!=null}}function Pe(c,f){f=f.checked,f!=null&&C(c,"checked",f,!1)}function _e(c,f){Pe(c,f);var g=ge(f.value),T=f.type;if(g!=null)T==="number"?(g===0&&c.value===""||c.value!=g)&&(c.value=""+g):c.value!==""+g&&(c.value=""+g);else if(T==="submit"||T==="reset"){c.removeAttribute("value");return}f.hasOwnProperty("value")?Xe(c,f.type,g):f.hasOwnProperty("defaultValue")&&Xe(c,f.type,ge(f.defaultValue)),f.checked==null&&f.defaultChecked!=null&&(c.defaultChecked=!!f.defaultChecked)}function qe(c,f,g){if(f.hasOwnProperty("value")||f.hasOwnProperty("defaultValue")){var T=f.type;if(!(T!=="submit"&&T!=="reset"||f.value!==void 0&&f.value!==null))return;f=""+c._wrapperState.initialValue,g||f===c.value||(c.value=f),c.defaultValue=f}g=c.name,g!==""&&(c.name=""),c.defaultChecked=!!c._wrapperState.initialChecked,g!==""&&(c.name=g)}function Xe(c,f,g){(f!=="number"||Fe(c.ownerDocument)!==c)&&(g==null?c.defaultValue=""+c._wrapperState.initialValue:c.defaultValue!==""+g&&(c.defaultValue=""+g))}var Qe=Array.isArray;function it(c,f,g,T){if(c=c.options,f){f={};for(var A=0;A<g.length;A++)f["$"+g[A]]=!0;for(g=0;g<c.length;g++)A=f.hasOwnProperty("$"+c[g].value),c[g].selected!==A&&(c[g].selected=A),A&&T&&(c[g].defaultSelected=!0)}else{for(g=""+ge(g),f=null,A=0;A<c.length;A++){if(c[A].value===g){c[A].selected=!0,T&&(c[A].defaultSelected=!0);return}f!==null||c[A].disabled||(f=c[A])}f!==null&&(f.selected=!0)}}function at(c,f){if(f.dangerouslySetInnerHTML!=null)throw Error(n(91));return Z({},f,{value:void 0,defaultValue:void 0,children:""+c._wrapperState.initialValue})}function vt(c,f){var g=f.value;if(g==null){if(g=f.children,f=f.defaultValue,g!=null){if(f!=null)throw Error(n(92));if(Qe(g)){if(1<g.length)throw Error(n(93));g=g[0]}f=g}f==null&&(f=""),g=f}c._wrapperState={initialValue:ge(g)}}function Mt(c,f){var g=ge(f.value),T=ge(f.defaultValue);g!=null&&(g=""+g,g!==c.value&&(c.value=g),f.defaultValue==null&&c.defaultValue!==g&&(c.defaultValue=g)),T!=null&&(c.defaultValue=""+T)}function Kt(c){var f=c.textContent;f===c._wrapperState.initialValue&&f!==""&&f!==null&&(c.value=f)}function gn(c){switch(c){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function Ge(c,f){return c==null||c==="http://www.w3.org/1999/xhtml"?gn(f):c==="http://www.w3.org/2000/svg"&&f==="foreignObject"?"http://www.w3.org/1999/xhtml":c}var ut,mt=function(c){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(f,g,T,A){MSApp.execUnsafeLocalFunction(function(){return c(f,g,T,A)})}:c}(function(c,f){if(c.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in c)c.innerHTML=f;else{for(ut=ut||document.createElement("div"),ut.innerHTML="<svg>"+f.valueOf().toString()+"</svg>",f=ut.firstChild;c.firstChild;)c.removeChild(c.firstChild);for(;f.firstChild;)c.appendChild(f.firstChild)}});function It(c,f){if(f){var g=c.firstChild;if(g&&g===c.lastChild&&g.nodeType===3){g.nodeValue=f;return}}c.textContent=f}var Ot={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Zn=["Webkit","ms","Moz","O"];Object.keys(Ot).forEach(function(c){Zn.forEach(function(f){f=f+c.charAt(0).toUpperCase()+c.substring(1),Ot[f]=Ot[c]})});function $n(c,f,g){return f==null||typeof f=="boolean"||f===""?"":g||typeof f!="number"||f===0||Ot.hasOwnProperty(c)&&Ot[c]?(""+f).trim():f+"px"}function io(c,f){c=c.style;for(var g in f)if(f.hasOwnProperty(g)){var T=g.indexOf("--")===0,A=$n(g,f[g],T);g==="float"&&(g="cssFloat"),T?c.setProperty(g,A):c[g]=A}}var Tn=Z({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Pn(c,f){if(f){if(Tn[c]&&(f.children!=null||f.dangerouslySetInnerHTML!=null))throw Error(n(137,c));if(f.dangerouslySetInnerHTML!=null){if(f.children!=null)throw Error(n(60));if(typeof f.dangerouslySetInnerHTML!="object"||!("__html"in f.dangerouslySetInnerHTML))throw Error(n(61))}if(f.style!=null&&typeof f.style!="object")throw Error(n(62))}}function er(c,f){if(c.indexOf("-")===-1)return typeof f.is=="string";switch(c){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var ir=null;function Gt(c){return c=c.target||c.srcElement||window,c.correspondingUseElement&&(c=c.correspondingUseElement),c.nodeType===3?c.parentNode:c}var gr=null,Un=null,Et=null;function Yr(c){if(c=dp(c)){if(typeof gr!="function")throw Error(n(280));var f=c.stateNode;f&&(f=ly(f),gr(c.stateNode,c.type,f))}}function Mr(c){Un?Et?Et.push(c):Et=[c]:Un=c}function wo(){if(Un){var c=Un,f=Et;if(Et=Un=null,Yr(c),f)for(c=0;c<f.length;c++)Yr(f[c])}}function jn(c,f){return c(f)}function ao(){}var qn=!1;function so(c,f,g){if(qn)return c(f,g);qn=!0;try{return jn(c,f,g)}finally{qn=!1,(Un!==null||Et!==null)&&(ao(),wo())}}function Ur(c,f){var g=c.stateNode;if(g===null)return null;var T=ly(g);if(T===null)return null;g=T[f];e:switch(f){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(T=!T.disabled)||(c=c.type,T=!(c==="button"||c==="input"||c==="select"||c==="textarea")),c=!T;break e;default:c=!1}if(c)return null;if(g&&typeof g!="function")throw Error(n(231,f,typeof g));return g}var So=!1;if(s)try{var wi={};Object.defineProperty(wi,"passive",{get:function(){So=!0}}),window.addEventListener("test",wi,wi),window.removeEventListener("test",wi,wi)}catch{So=!1}function Ms(c,f,g,T,A,F,X,se,ue){var Ee=Array.prototype.slice.call(arguments,3);try{f.apply(g,Ee)}catch(He){this.onError(He)}}var Ca=!1,Nl=null,Ol=!1,Ma=null,cd={onError:function(c){Ca=!0,Nl=c}};function Pl(c,f,g,T,A,F,X,se,ue){Ca=!1,Nl=null,Ms.apply(cd,arguments)}function Lc(c,f,g,T,A,F,X,se,ue){if(Pl.apply(this,arguments),Ca){if(Ca){var Ee=Nl;Ca=!1,Nl=null}else throw Error(n(198));Ol||(Ol=!0,Ma=Ee)}}function Zi(c){var f=c,g=c;if(c.alternate)for(;f.return;)f=f.return;else{c=f;do f=c,f.flags&4098&&(g=f.return),c=f.return;while(c)}return f.tag===3?g:null}function Da(c){if(c.tag===13){var f=c.memoizedState;if(f===null&&(c=c.alternate,c!==null&&(f=c.memoizedState)),f!==null)return f.dehydrated}return null}function ud(c){if(Zi(c)!==c)throw Error(n(188))}function Rc(c){var f=c.alternate;if(!f){if(f=Zi(c),f===null)throw Error(n(188));return f!==c?null:c}for(var g=c,T=f;;){var A=g.return;if(A===null)break;var F=A.alternate;if(F===null){if(T=A.return,T!==null){g=T;continue}break}if(A.child===F.child){for(F=A.child;F;){if(F===g)return ud(A),c;if(F===T)return ud(A),f;F=F.sibling}throw Error(n(188))}if(g.return!==T.return)g=A,T=F;else{for(var X=!1,se=A.child;se;){if(se===g){X=!0,g=A,T=F;break}if(se===T){X=!0,T=A,g=F;break}se=se.sibling}if(!X){for(se=F.child;se;){if(se===g){X=!0,g=F,T=A;break}if(se===T){X=!0,T=F,g=A;break}se=se.sibling}if(!X)throw Error(n(189))}}if(g.alternate!==T)throw Error(n(190))}if(g.tag!==3)throw Error(n(188));return g.stateNode.current===g?c:f}function Ds(c){return c=Rc(c),c!==null?Aa(c):null}function Aa(c){if(c.tag===5||c.tag===6)return c;for(c=c.child;c!==null;){var f=Aa(c);if(f!==null)return f;c=c.sibling}return null}var As=t.unstable_scheduleCallback,Fc=t.unstable_cancelCallback,dd=t.unstable_shouldYield,fd=t.unstable_requestPaint,fn=t.unstable_now,Dr=t.unstable_getCurrentPriorityLevel,jl=t.unstable_ImmediatePriority,Ll=t.unstable_UserBlockingPriority,Na=t.unstable_NormalPriority,hd=t.unstable_LowPriority,$i=t.unstable_IdlePriority,$o=null,lo=null;function Ns(c){if(lo&&typeof lo.onCommitFiberRoot=="function")try{lo.onCommitFiberRoot($o,c,void 0,(c.current.flags&128)===128)}catch{}}var ar=Math.clz32?Math.clz32:Bc,Hc=Math.log,_c=Math.LN2;function Bc(c){return c>>>=0,c===0?32:31-(Hc(c)/_c|0)|0}var qi=64,Os=4194304;function Oa(c){switch(c&-c){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return c&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return c&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return c}}function Pa(c,f){var g=c.pendingLanes;if(g===0)return 0;var T=0,A=c.suspendedLanes,F=c.pingedLanes,X=g&268435455;if(X!==0){var se=X&~A;se!==0?T=Oa(se):(F&=X,F!==0&&(T=Oa(F)))}else X=g&~A,X!==0?T=Oa(X):F!==0&&(T=Oa(F));if(T===0)return 0;if(f!==0&&f!==T&&!(f&A)&&(A=T&-T,F=f&-f,A>=F||A===16&&(F&4194240)!==0))return f;if(T&4&&(T|=g&16),f=c.entangledLanes,f!==0)for(c=c.entanglements,f&=T;0<f;)g=31-ar(f),A=1<<g,T|=c[g],f&=~A;return T}function P(c,f){switch(c){case 1:case 2:case 4:return f+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return f+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function W(c,f){for(var g=c.suspendedLanes,T=c.pingedLanes,A=c.expirationTimes,F=c.pendingLanes;0<F;){var X=31-ar(F),se=1<<X,ue=A[X];ue===-1?(!(se&g)||se&T)&&(A[X]=P(se,f)):ue<=f&&(c.expiredLanes|=se),F&=~se}}function te(c){return c=c.pendingLanes&-1073741825,c!==0?c:c&1073741824?1073741824:0}function ae(){var c=qi;return qi<<=1,!(qi&4194240)&&(qi=64),c}function Se(c){for(var f=[],g=0;31>g;g++)f.push(c);return f}function ve(c,f,g){c.pendingLanes|=f,f!==536870912&&(c.suspendedLanes=0,c.pingedLanes=0),c=c.eventTimes,f=31-ar(f),c[f]=g}function De(c,f){var g=c.pendingLanes&~f;c.pendingLanes=f,c.suspendedLanes=0,c.pingedLanes=0,c.expiredLanes&=f,c.mutableReadLanes&=f,c.entangledLanes&=f,f=c.entanglements;var T=c.eventTimes;for(c=c.expirationTimes;0<g;){var A=31-ar(g),F=1<<A;f[A]=0,T[A]=-1,c[A]=-1,g&=~F}}function Ve(c,f){var g=c.entangledLanes|=f;for(c=c.entanglements;g;){var T=31-ar(g),A=1<<T;A&f|c[T]&f&&(c[T]|=f),g&=~A}}var Ke=0;function yt(c){return c&=-c,1<c?4<c?c&268435455?16:536870912:4:1}var kt,ln,To,xo,zr,Ki=!1,Io=[],ko=null,Vr=null,qo=null,Eo=new Map,ja=new Map,La=[],s1="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function Zv(c,f){switch(c){case"focusin":case"focusout":ko=null;break;case"dragenter":case"dragleave":Vr=null;break;case"mouseover":case"mouseout":qo=null;break;case"pointerover":case"pointerout":Eo.delete(f.pointerId);break;case"gotpointercapture":case"lostpointercapture":ja.delete(f.pointerId)}}function Yc(c,f,g,T,A,F){return c===null||c.nativeEvent!==F?(c={blockedOn:f,domEventName:g,eventSystemFlags:T,nativeEvent:F,targetContainers:[A]},f!==null&&(f=dp(f),f!==null&&ln(f)),c):(c.eventSystemFlags|=T,f=c.targetContainers,A!==null&&f.indexOf(A)===-1&&f.push(A),c)}function l1(c,f,g,T,A){switch(f){case"focusin":return ko=Yc(ko,c,f,g,T,A),!0;case"dragenter":return Vr=Yc(Vr,c,f,g,T,A),!0;case"mouseover":return qo=Yc(qo,c,f,g,T,A),!0;case"pointerover":var F=A.pointerId;return Eo.set(F,Yc(Eo.get(F)||null,c,f,g,T,A)),!0;case"gotpointercapture":return F=A.pointerId,ja.set(F,Yc(ja.get(F)||null,c,f,g,T,A)),!0}return!1}function Si(c){var f=qc(c.target);if(f!==null){var g=Zi(f);if(g!==null){if(f=g.tag,f===13){if(f=Da(g),f!==null){c.blockedOn=f,zr(c.priority,function(){To(g)});return}}else if(f===3&&g.stateNode.current.memoizedState.isDehydrated){c.blockedOn=g.tag===3?g.stateNode.containerInfo:null;return}}}c.blockedOn=null}function Rl(c){if(c.blockedOn!==null)return!1;for(var f=c.targetContainers;0<f.length;){var g=zc(c.domEventName,c.eventSystemFlags,f[0],c.nativeEvent);if(g===null){g=c.nativeEvent;var T=new g.constructor(g.type,g);ir=T,g.target.dispatchEvent(T),ir=null}else return f=dp(g),f!==null&&ln(f),c.blockedOn=g,!1;f.shift()}return!0}function Uc(c,f,g){Rl(c)&&g.delete(f)}function cn(){Ki=!1,ko!==null&&Rl(ko)&&(ko=null),Vr!==null&&Rl(Vr)&&(Vr=null),qo!==null&&Rl(qo)&&(qo=null),Eo.forEach(Uc),ja.forEach(Uc)}function Xi(c,f){c.blockedOn===f&&(c.blockedOn=null,Ki||(Ki=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,cn)))}function Ra(c){function f(A){return Xi(A,c)}if(0<Io.length){Xi(Io[0],c);for(var g=1;g<Io.length;g++){var T=Io[g];T.blockedOn===c&&(T.blockedOn=null)}}for(ko!==null&&Xi(ko,c),Vr!==null&&Xi(Vr,c),qo!==null&&Xi(qo,c),Eo.forEach(f),ja.forEach(f),g=0;g<La.length;g++)T=La[g],T.blockedOn===c&&(T.blockedOn=null);for(;0<La.length&&(g=La[0],g.blockedOn===null);)Si(g),g.blockedOn===null&&La.shift()}var Ti=k.ReactCurrentBatchConfig,Ko=!0;function pd(c,f,g,T){var A=Ke,F=Ti.transition;Ti.transition=null;try{Ke=1,md(c,f,g,T)}finally{Ke=A,Ti.transition=F}}function Ps(c,f,g,T){var A=Ke,F=Ti.transition;Ti.transition=null;try{Ke=4,md(c,f,g,T)}finally{Ke=A,Ti.transition=F}}function md(c,f,g,T){if(Ko){var A=zc(c,f,g,T);if(A===null)b1(c,f,T,Fl,g),Zv(c,T);else if(l1(A,c,f,g,T))T.stopPropagation();else if(Zv(c,T),f&4&&-1<s1.indexOf(c)){for(;A!==null;){var F=dp(A);if(F!==null&&kt(F),F=zc(c,f,g,T),F===null&&b1(c,f,T,Fl,g),F===A)break;A=F}A!==null&&T.stopPropagation()}else b1(c,f,T,null,g)}}var Fl=null;function zc(c,f,g,T){if(Fl=null,c=Gt(T),c=qc(c),c!==null)if(f=Zi(c),f===null)c=null;else if(g=f.tag,g===13){if(c=Da(f),c!==null)return c;c=null}else if(g===3){if(f.stateNode.current.memoizedState.isDehydrated)return f.tag===3?f.stateNode.containerInfo:null;c=null}else f!==c&&(c=null);return Fl=c,null}function qh(c){switch(c){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(Dr()){case jl:return 1;case Ll:return 4;case Na:case hd:return 16;case $i:return 536870912;default:return 16}default:return 16}}var Ji=null,gd=null,vd=null;function $v(){if(vd)return vd;var c,f=gd,g=f.length,T,A="value"in Ji?Ji.value:Ji.textContent,F=A.length;for(c=0;c<g&&f[c]===A[c];c++);var X=g-c;for(T=1;T<=X&&f[g-T]===A[F-T];T++);return vd=A.slice(c,1<T?1-T:void 0)}function js(c){var f=c.keyCode;return"charCode"in c?(c=c.charCode,c===0&&f===13&&(c=13)):c=f,c===10&&(c=13),32<=c||c===13?c:0}function Vc(){return!0}function Wc(){return!1}function Ar(c){function f(g,T,A,F,X){this._reactName=g,this._targetInst=A,this.type=T,this.nativeEvent=F,this.target=X,this.currentTarget=null;for(var se in c)c.hasOwnProperty(se)&&(g=c[se],this[se]=g?g(F):F[se]);return this.isDefaultPrevented=(F.defaultPrevented!=null?F.defaultPrevented:F.returnValue===!1)?Vc:Wc,this.isPropagationStopped=Wc,this}return Z(f.prototype,{preventDefault:function(){this.defaultPrevented=!0;var g=this.nativeEvent;g&&(g.preventDefault?g.preventDefault():typeof g.returnValue!="unknown"&&(g.returnValue=!1),this.isDefaultPrevented=Vc)},stopPropagation:function(){var g=this.nativeEvent;g&&(g.stopPropagation?g.stopPropagation():typeof g.cancelBubble!="unknown"&&(g.cancelBubble=!0),this.isPropagationStopped=Vc)},persist:function(){},isPersistent:Vc}),f}var Hl={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(c){return c.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Ls=Ar(Hl),Gc=Z({},Hl,{view:0,detail:0}),Kh=Ar(Gc),_l,Rs,Fa,Zc=Z({},Gc,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Td,button:0,buttons:0,relatedTarget:function(c){return c.relatedTarget===void 0?c.fromElement===c.srcElement?c.toElement:c.fromElement:c.relatedTarget},movementX:function(c){return"movementX"in c?c.movementX:(c!==Fa&&(Fa&&c.type==="mousemove"?(_l=c.screenX-Fa.screenX,Rs=c.screenY-Fa.screenY):Rs=_l=0,Fa=c),_l)},movementY:function(c){return"movementY"in c?c.movementY:Rs}}),Xh=Ar(Zc),qv=Z({},Zc,{dataTransfer:0}),Jh=Ar(qv),co=Z({},Gc,{relatedTarget:0}),yd=Ar(co),Qh=Z({},Hl,{animationName:0,elapsedTime:0,pseudoElement:0}),c1=Ar(Qh),Kv=Z({},Hl,{clipboardData:function(c){return"clipboardData"in c?c.clipboardData:window.clipboardData}}),bd=Ar(Kv),Xv=Z({},Hl,{data:0}),ep=Ar(Xv),wd={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Sd={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Jv={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Qv(c){var f=this.nativeEvent;return f.getModifierState?f.getModifierState(c):(c=Jv[c])?!!f[c]:!1}function Td(){return Qv}var tp=Z({},Gc,{key:function(c){if(c.key){var f=wd[c.key]||c.key;if(f!=="Unidentified")return f}return c.type==="keypress"?(c=js(c),c===13?"Enter":String.fromCharCode(c)):c.type==="keydown"||c.type==="keyup"?Sd[c.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Td,charCode:function(c){return c.type==="keypress"?js(c):0},keyCode:function(c){return c.type==="keydown"||c.type==="keyup"?c.keyCode:0},which:function(c){return c.type==="keypress"?js(c):c.type==="keydown"||c.type==="keyup"?c.keyCode:0}}),ey=Ar(tp),j=Z({},Zc,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),V=Ar(j),Q=Z({},Gc,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Td}),oe=Ar(Q),xe=Z({},Hl,{propertyName:0,elapsedTime:0,pseudoElement:0}),we=Ar(xe),Ae=Z({},Zc,{deltaX:function(c){return"deltaX"in c?c.deltaX:"wheelDeltaX"in c?-c.wheelDeltaX:0},deltaY:function(c){return"deltaY"in c?c.deltaY:"wheelDeltaY"in c?-c.wheelDeltaY:"wheelDelta"in c?-c.wheelDelta:0},deltaZ:0,deltaMode:0}),ze=Ar(Ae),gt=[9,13,27,32],Dt=s&&"CompositionEvent"in window,Tt=null;s&&"documentMode"in document&&(Tt=document.documentMode);var hn=s&&"TextEvent"in window&&!Tt,Wr=s&&(!Dt||Tt&&8<Tt&&11>=Tt),Co=" ",Mo=!1;function $c(c,f){switch(c){case"keyup":return gt.indexOf(f.keyCode)!==-1;case"keydown":return f.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function np(c){return c=c.detail,typeof c=="object"&&"data"in c?c.data:null}var Ha=!1;function lZ(c,f){switch(c){case"compositionend":return np(f);case"keypress":return f.which!==32?null:(Mo=!0,Co);case"textInput":return c=f.data,c===Co&&Mo?null:c;default:return null}}function cZ(c,f){if(Ha)return c==="compositionend"||!Dt&&$c(c,f)?(c=$v(),vd=gd=Ji=null,Ha=!1,c):null;switch(c){case"paste":return null;case"keypress":if(!(f.ctrlKey||f.altKey||f.metaKey)||f.ctrlKey&&f.altKey){if(f.char&&1<f.char.length)return f.char;if(f.which)return String.fromCharCode(f.which)}return null;case"compositionend":return Wr&&f.locale!=="ko"?null:f.data;default:return null}}var uZ={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function AN(c){var f=c&&c.nodeName&&c.nodeName.toLowerCase();return f==="input"?!!uZ[c.type]:f==="textarea"}function NN(c,f,g,T){Mr(T),f=iy(f,"onChange"),0<f.length&&(g=new Ls("onChange","change",null,g,T),c.push({event:g,listeners:f}))}var rp=null,op=null;function dZ(c){qN(c,0)}function ty(c){var f=Cd(c);if(Ie(f))return c}function fZ(c,f){if(c==="change")return f}var ON=!1;if(s){var u1;if(s){var d1="oninput"in document;if(!d1){var PN=document.createElement("div");PN.setAttribute("oninput","return;"),d1=typeof PN.oninput=="function"}u1=d1}else u1=!1;ON=u1&&(!document.documentMode||9<document.documentMode)}function jN(){rp&&(rp.detachEvent("onpropertychange",LN),op=rp=null)}function LN(c){if(c.propertyName==="value"&&ty(op)){var f=[];NN(f,op,c,Gt(c)),so(dZ,f)}}function hZ(c,f,g){c==="focusin"?(jN(),rp=f,op=g,rp.attachEvent("onpropertychange",LN)):c==="focusout"&&jN()}function pZ(c){if(c==="selectionchange"||c==="keyup"||c==="keydown")return ty(op)}function mZ(c,f){if(c==="click")return ty(f)}function gZ(c,f){if(c==="input"||c==="change")return ty(f)}function vZ(c,f){return c===f&&(c!==0||1/c===1/f)||c!==c&&f!==f}var Qi=typeof Object.is=="function"?Object.is:vZ;function ip(c,f){if(Qi(c,f))return!0;if(typeof c!="object"||c===null||typeof f!="object"||f===null)return!1;var g=Object.keys(c),T=Object.keys(f);if(g.length!==T.length)return!1;for(T=0;T<g.length;T++){var A=g[T];if(!l.call(f,A)||!Qi(c[A],f[A]))return!1}return!0}function RN(c){for(;c&&c.firstChild;)c=c.firstChild;return c}function FN(c,f){var g=RN(c);c=0;for(var T;g;){if(g.nodeType===3){if(T=c+g.textContent.length,c<=f&&T>=f)return{node:g,offset:f-c};c=T}e:{for(;g;){if(g.nextSibling){g=g.nextSibling;break e}g=g.parentNode}g=void 0}g=RN(g)}}function HN(c,f){return c&&f?c===f?!0:c&&c.nodeType===3?!1:f&&f.nodeType===3?HN(c,f.parentNode):"contains"in c?c.contains(f):c.compareDocumentPosition?!!(c.compareDocumentPosition(f)&16):!1:!1}function _N(){for(var c=window,f=Fe();f instanceof c.HTMLIFrameElement;){try{var g=typeof f.contentWindow.location.href=="string"}catch{g=!1}if(g)c=f.contentWindow;else break;f=Fe(c.document)}return f}function f1(c){var f=c&&c.nodeName&&c.nodeName.toLowerCase();return f&&(f==="input"&&(c.type==="text"||c.type==="search"||c.type==="tel"||c.type==="url"||c.type==="password")||f==="textarea"||c.contentEditable==="true")}function yZ(c){var f=_N(),g=c.focusedElem,T=c.selectionRange;if(f!==g&&g&&g.ownerDocument&&HN(g.ownerDocument.documentElement,g)){if(T!==null&&f1(g)){if(f=T.start,c=T.end,c===void 0&&(c=f),"selectionStart"in g)g.selectionStart=f,g.selectionEnd=Math.min(c,g.value.length);else if(c=(f=g.ownerDocument||document)&&f.defaultView||window,c.getSelection){c=c.getSelection();var A=g.textContent.length,F=Math.min(T.start,A);T=T.end===void 0?F:Math.min(T.end,A),!c.extend&&F>T&&(A=T,T=F,F=A),A=FN(g,F);var X=FN(g,T);A&&X&&(c.rangeCount!==1||c.anchorNode!==A.node||c.anchorOffset!==A.offset||c.focusNode!==X.node||c.focusOffset!==X.offset)&&(f=f.createRange(),f.setStart(A.node,A.offset),c.removeAllRanges(),F>T?(c.addRange(f),c.extend(X.node,X.offset)):(f.setEnd(X.node,X.offset),c.addRange(f)))}}for(f=[],c=g;c=c.parentNode;)c.nodeType===1&&f.push({element:c,left:c.scrollLeft,top:c.scrollTop});for(typeof g.focus=="function"&&g.focus(),g=0;g<f.length;g++)c=f[g],c.element.scrollLeft=c.left,c.element.scrollTop=c.top}}var bZ=s&&"documentMode"in document&&11>=document.documentMode,xd=null,h1=null,ap=null,p1=!1;function BN(c,f,g){var T=g.window===g?g.document:g.nodeType===9?g:g.ownerDocument;p1||xd==null||xd!==Fe(T)||(T=xd,"selectionStart"in T&&f1(T)?T={start:T.selectionStart,end:T.selectionEnd}:(T=(T.ownerDocument&&T.ownerDocument.defaultView||window).getSelection(),T={anchorNode:T.anchorNode,anchorOffset:T.anchorOffset,focusNode:T.focusNode,focusOffset:T.focusOffset}),ap&&ip(ap,T)||(ap=T,T=iy(h1,"onSelect"),0<T.length&&(f=new Ls("onSelect","select",null,f,g),c.push({event:f,listeners:T}),f.target=xd)))}function ny(c,f){var g={};return g[c.toLowerCase()]=f.toLowerCase(),g["Webkit"+c]="webkit"+f,g["Moz"+c]="moz"+f,g}var Id={animationend:ny("Animation","AnimationEnd"),animationiteration:ny("Animation","AnimationIteration"),animationstart:ny("Animation","AnimationStart"),transitionend:ny("Transition","TransitionEnd")},m1={},YN={};s&&(YN=document.createElement("div").style,"AnimationEvent"in window||(delete Id.animationend.animation,delete Id.animationiteration.animation,delete Id.animationstart.animation),"TransitionEvent"in window||delete Id.transitionend.transition);function ry(c){if(m1[c])return m1[c];if(!Id[c])return c;var f=Id[c],g;for(g in f)if(f.hasOwnProperty(g)&&g in YN)return m1[c]=f[g];return c}var UN=ry("animationend"),zN=ry("animationiteration"),VN=ry("animationstart"),WN=ry("transitionend"),GN=new Map,ZN="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Bl(c,f){GN.set(c,f),i(f,[c])}for(var g1=0;g1<ZN.length;g1++){var v1=ZN[g1],wZ=v1.toLowerCase(),SZ=v1[0].toUpperCase()+v1.slice(1);Bl(wZ,"on"+SZ)}Bl(UN,"onAnimationEnd"),Bl(zN,"onAnimationIteration"),Bl(VN,"onAnimationStart"),Bl("dblclick","onDoubleClick"),Bl("focusin","onFocus"),Bl("focusout","onBlur"),Bl(WN,"onTransitionEnd"),a("onMouseEnter",["mouseout","mouseover"]),a("onMouseLeave",["mouseout","mouseover"]),a("onPointerEnter",["pointerout","pointerover"]),a("onPointerLeave",["pointerout","pointerover"]),i("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),i("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),i("onBeforeInput",["compositionend","keypress","textInput","paste"]),i("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),i("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),i("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var sp="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),TZ=new Set("cancel close invalid load scroll toggle".split(" ").concat(sp));function $N(c,f,g){var T=c.type||"unknown-event";c.currentTarget=g,Lc(T,f,void 0,c),c.currentTarget=null}function qN(c,f){f=(f&4)!==0;for(var g=0;g<c.length;g++){var T=c[g],A=T.event;T=T.listeners;e:{var F=void 0;if(f)for(var X=T.length-1;0<=X;X--){var se=T[X],ue=se.instance,Ee=se.currentTarget;if(se=se.listener,ue!==F&&A.isPropagationStopped())break e;$N(A,se,Ee),F=ue}else for(X=0;X<T.length;X++){if(se=T[X],ue=se.instance,Ee=se.currentTarget,se=se.listener,ue!==F&&A.isPropagationStopped())break e;$N(A,se,Ee),F=ue}}}if(Ol)throw c=Ma,Ol=!1,Ma=null,c}function xn(c,f){var g=f[k1];g===void 0&&(g=f[k1]=new Set);var T=c+"__bubble";g.has(T)||(KN(f,c,2,!1),g.add(T))}function y1(c,f,g){var T=0;f&&(T|=4),KN(g,c,T,f)}var oy="_reactListening"+Math.random().toString(36).slice(2);function lp(c){if(!c[oy]){c[oy]=!0,r.forEach(function(g){g!=="selectionchange"&&(TZ.has(g)||y1(g,!1,c),y1(g,!0,c))});var f=c.nodeType===9?c:c.ownerDocument;f===null||f[oy]||(f[oy]=!0,y1("selectionchange",!1,f))}}function KN(c,f,g,T){switch(qh(f)){case 1:var A=pd;break;case 4:A=Ps;break;default:A=md}g=A.bind(null,f,g,c),A=void 0,!So||f!=="touchstart"&&f!=="touchmove"&&f!=="wheel"||(A=!0),T?A!==void 0?c.addEventListener(f,g,{capture:!0,passive:A}):c.addEventListener(f,g,!0):A!==void 0?c.addEventListener(f,g,{passive:A}):c.addEventListener(f,g,!1)}function b1(c,f,g,T,A){var F=T;if(!(f&1)&&!(f&2)&&T!==null)e:for(;;){if(T===null)return;var X=T.tag;if(X===3||X===4){var se=T.stateNode.containerInfo;if(se===A||se.nodeType===8&&se.parentNode===A)break;if(X===4)for(X=T.return;X!==null;){var ue=X.tag;if((ue===3||ue===4)&&(ue=X.stateNode.containerInfo,ue===A||ue.nodeType===8&&ue.parentNode===A))return;X=X.return}for(;se!==null;){if(X=qc(se),X===null)return;if(ue=X.tag,ue===5||ue===6){T=F=X;continue e}se=se.parentNode}}T=T.return}so(function(){var Ee=F,He=Gt(g),Be=[];e:{var Re=GN.get(c);if(Re!==void 0){var et=Ls,ot=c;switch(c){case"keypress":if(js(g)===0)break e;case"keydown":case"keyup":et=ey;break;case"focusin":ot="focus",et=yd;break;case"focusout":ot="blur",et=yd;break;case"beforeblur":case"afterblur":et=yd;break;case"click":if(g.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":et=Xh;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":et=Jh;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":et=oe;break;case UN:case zN:case VN:et=c1;break;case WN:et=we;break;case"scroll":et=Kh;break;case"wheel":et=ze;break;case"copy":case"cut":case"paste":et=bd;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":et=V}var st=(f&4)!==0,Kn=!st&&c==="scroll",be=st?Re!==null?Re+"Capture":null:Re;st=[];for(var he=Ee,Te;he!==null;){Te=he;var We=Te.stateNode;if(Te.tag===5&&We!==null&&(Te=We,be!==null&&(We=Ur(he,be),We!=null&&st.push(cp(he,We,Te)))),Kn)break;he=he.return}0<st.length&&(Re=new et(Re,ot,null,g,He),Be.push({event:Re,listeners:st}))}}if(!(f&7)){e:{if(Re=c==="mouseover"||c==="pointerover",et=c==="mouseout"||c==="pointerout",Re&&g!==ir&&(ot=g.relatedTarget||g.fromElement)&&(qc(ot)||ot[Fs]))break e;if((et||Re)&&(Re=He.window===He?He:(Re=He.ownerDocument)?Re.defaultView||Re.parentWindow:window,et?(ot=g.relatedTarget||g.toElement,et=Ee,ot=ot?qc(ot):null,ot!==null&&(Kn=Zi(ot),ot!==Kn||ot.tag!==5&&ot.tag!==6)&&(ot=null)):(et=null,ot=Ee),et!==ot)){if(st=Xh,We="onMouseLeave",be="onMouseEnter",he="mouse",(c==="pointerout"||c==="pointerover")&&(st=V,We="onPointerLeave",be="onPointerEnter",he="pointer"),Kn=et==null?Re:Cd(et),Te=ot==null?Re:Cd(ot),Re=new st(We,he+"leave",et,g,He),Re.target=Kn,Re.relatedTarget=Te,We=null,qc(He)===Ee&&(st=new st(be,he+"enter",ot,g,He),st.target=Te,st.relatedTarget=Kn,We=st),Kn=We,et&&ot)t:{for(st=et,be=ot,he=0,Te=st;Te;Te=kd(Te))he++;for(Te=0,We=be;We;We=kd(We))Te++;for(;0<he-Te;)st=kd(st),he--;for(;0<Te-he;)be=kd(be),Te--;for(;he--;){if(st===be||be!==null&&st===be.alternate)break t;st=kd(st),be=kd(be)}st=null}else st=null;et!==null&&XN(Be,Re,et,st,!1),ot!==null&&Kn!==null&&XN(Be,Kn,ot,st,!0)}}e:{if(Re=Ee?Cd(Ee):window,et=Re.nodeName&&Re.nodeName.toLowerCase(),et==="select"||et==="input"&&Re.type==="file")var lt=fZ;else if(AN(Re))if(ON)lt=gZ;else{lt=pZ;var dt=hZ}else(et=Re.nodeName)&&et.toLowerCase()==="input"&&(Re.type==="checkbox"||Re.type==="radio")&&(lt=mZ);if(lt&&(lt=lt(c,Ee))){NN(Be,lt,g,He);break e}dt&&dt(c,Re,Ee),c==="focusout"&&(dt=Re._wrapperState)&&dt.controlled&&Re.type==="number"&&Xe(Re,"number",Re.value)}switch(dt=Ee?Cd(Ee):window,c){case"focusin":(AN(dt)||dt.contentEditable==="true")&&(xd=dt,h1=Ee,ap=null);break;case"focusout":ap=h1=xd=null;break;case"mousedown":p1=!0;break;case"contextmenu":case"mouseup":case"dragend":p1=!1,BN(Be,g,He);break;case"selectionchange":if(bZ)break;case"keydown":case"keyup":BN(Be,g,He)}var ft;if(Dt)e:{switch(c){case"compositionstart":var xt="onCompositionStart";break e;case"compositionend":xt="onCompositionEnd";break e;case"compositionupdate":xt="onCompositionUpdate";break e}xt=void 0}else Ha?$c(c,g)&&(xt="onCompositionEnd"):c==="keydown"&&g.keyCode===229&&(xt="onCompositionStart");xt&&(Wr&&g.locale!=="ko"&&(Ha||xt!=="onCompositionStart"?xt==="onCompositionEnd"&&Ha&&(ft=$v()):(Ji=He,gd="value"in Ji?Ji.value:Ji.textContent,Ha=!0)),dt=iy(Ee,xt),0<dt.length&&(xt=new ep(xt,c,null,g,He),Be.push({event:xt,listeners:dt}),ft?xt.data=ft:(ft=np(g),ft!==null&&(xt.data=ft)))),(ft=hn?lZ(c,g):cZ(c,g))&&(Ee=iy(Ee,"onBeforeInput"),0<Ee.length&&(He=new ep("onBeforeInput","beforeinput",null,g,He),Be.push({event:He,listeners:Ee}),He.data=ft))}qN(Be,f)})}function cp(c,f,g){return{instance:c,listener:f,currentTarget:g}}function iy(c,f){for(var g=f+"Capture",T=[];c!==null;){var A=c,F=A.stateNode;A.tag===5&&F!==null&&(A=F,F=Ur(c,g),F!=null&&T.unshift(cp(c,F,A)),F=Ur(c,f),F!=null&&T.push(cp(c,F,A))),c=c.return}return T}function kd(c){if(c===null)return null;do c=c.return;while(c&&c.tag!==5);return c||null}function XN(c,f,g,T,A){for(var F=f._reactName,X=[];g!==null&&g!==T;){var se=g,ue=se.alternate,Ee=se.stateNode;if(ue!==null&&ue===T)break;se.tag===5&&Ee!==null&&(se=Ee,A?(ue=Ur(g,F),ue!=null&&X.unshift(cp(g,ue,se))):A||(ue=Ur(g,F),ue!=null&&X.push(cp(g,ue,se)))),g=g.return}X.length!==0&&c.push({event:f,listeners:X})}var xZ=/\r\n?/g,IZ=/\u0000|\uFFFD/g;function JN(c){return(typeof c=="string"?c:""+c).replace(xZ,`
|
|
|
`).replace(IZ,"")}function ay(c,f,g){if(f=JN(f),JN(c)!==f&&g)throw Error(n(425))}function sy(){}var w1=null,S1=null;function T1(c,f){return c==="textarea"||c==="noscript"||typeof f.children=="string"||typeof f.children=="number"||typeof f.dangerouslySetInnerHTML=="object"&&f.dangerouslySetInnerHTML!==null&&f.dangerouslySetInnerHTML.__html!=null}var x1=typeof setTimeout=="function"?setTimeout:void 0,kZ=typeof clearTimeout=="function"?clearTimeout:void 0,QN=typeof Promise=="function"?Promise:void 0,EZ=typeof queueMicrotask=="function"?queueMicrotask:typeof QN<"u"?function(c){return QN.resolve(null).then(c).catch(CZ)}:x1;function CZ(c){setTimeout(function(){throw c})}function I1(c,f){var g=f,T=0;do{var A=g.nextSibling;if(c.removeChild(g),A&&A.nodeType===8)if(g=A.data,g==="/$"){if(T===0){c.removeChild(A),Ra(f);return}T--}else g!=="$"&&g!=="$?"&&g!=="$!"||T++;g=A}while(g);Ra(f)}function Yl(c){for(;c!=null;c=c.nextSibling){var f=c.nodeType;if(f===1||f===3)break;if(f===8){if(f=c.data,f==="$"||f==="$!"||f==="$?")break;if(f==="/$")return null}}return c}function eO(c){c=c.previousSibling;for(var f=0;c;){if(c.nodeType===8){var g=c.data;if(g==="$"||g==="$!"||g==="$?"){if(f===0)return c;f--}else g==="/$"&&f++}c=c.previousSibling}return null}var Ed=Math.random().toString(36).slice(2),_a="__reactFiber$"+Ed,up="__reactProps$"+Ed,Fs="__reactContainer$"+Ed,k1="__reactEvents$"+Ed,MZ="__reactListeners$"+Ed,DZ="__reactHandles$"+Ed;function qc(c){var f=c[_a];if(f)return f;for(var g=c.parentNode;g;){if(f=g[Fs]||g[_a]){if(g=f.alternate,f.child!==null||g!==null&&g.child!==null)for(c=eO(c);c!==null;){if(g=c[_a])return g;c=eO(c)}return f}c=g,g=c.parentNode}return null}function dp(c){return c=c[_a]||c[Fs],!c||c.tag!==5&&c.tag!==6&&c.tag!==13&&c.tag!==3?null:c}function Cd(c){if(c.tag===5||c.tag===6)return c.stateNode;throw Error(n(33))}function ly(c){return c[up]||null}var E1=[],Md=-1;function Ul(c){return{current:c}}function In(c){0>Md||(c.current=E1[Md],E1[Md]=null,Md--)}function vn(c,f){Md++,E1[Md]=c.current,c.current=f}var zl={},Gr=Ul(zl),Do=Ul(!1),Kc=zl;function Dd(c,f){var g=c.type.contextTypes;if(!g)return zl;var T=c.stateNode;if(T&&T.__reactInternalMemoizedUnmaskedChildContext===f)return T.__reactInternalMemoizedMaskedChildContext;var A={},F;for(F in g)A[F]=f[F];return T&&(c=c.stateNode,c.__reactInternalMemoizedUnmaskedChildContext=f,c.__reactInternalMemoizedMaskedChildContext=A),A}function Ao(c){return c=c.childContextTypes,c!=null}function cy(){In(Do),In(Gr)}function tO(c,f,g){if(Gr.current!==zl)throw Error(n(168));vn(Gr,f),vn(Do,g)}function nO(c,f,g){var T=c.stateNode;if(f=f.childContextTypes,typeof T.getChildContext!="function")return g;T=T.getChildContext();for(var A in T)if(!(A in f))throw Error(n(108,ye(c)||"Unknown",A));return Z({},g,T)}function uy(c){return c=(c=c.stateNode)&&c.__reactInternalMemoizedMergedChildContext||zl,Kc=Gr.current,vn(Gr,c),vn(Do,Do.current),!0}function rO(c,f,g){var T=c.stateNode;if(!T)throw Error(n(169));g?(c=nO(c,f,Kc),T.__reactInternalMemoizedMergedChildContext=c,In(Do),In(Gr),vn(Gr,c)):In(Do),vn(Do,g)}var Hs=null,dy=!1,C1=!1;function oO(c){Hs===null?Hs=[c]:Hs.push(c)}function AZ(c){dy=!0,oO(c)}function Vl(){if(!C1&&Hs!==null){C1=!0;var c=0,f=Ke;try{var g=Hs;for(Ke=1;c<g.length;c++){var T=g[c];do T=T(!0);while(T!==null)}Hs=null,dy=!1}catch(A){throw Hs!==null&&(Hs=Hs.slice(c+1)),As(jl,Vl),A}finally{Ke=f,C1=!1}}return null}var Ad=[],Nd=0,fy=null,hy=0,xi=[],Ii=0,Xc=null,_s=1,Bs="";function Jc(c,f){Ad[Nd++]=hy,Ad[Nd++]=fy,fy=c,hy=f}function iO(c,f,g){xi[Ii++]=_s,xi[Ii++]=Bs,xi[Ii++]=Xc,Xc=c;var T=_s;c=Bs;var A=32-ar(T)-1;T&=~(1<<A),g+=1;var F=32-ar(f)+A;if(30<F){var X=A-A%5;F=(T&(1<<X)-1).toString(32),T>>=X,A-=X,_s=1<<32-ar(f)+A|g<<A|T,Bs=F+c}else _s=1<<F|g<<A|T,Bs=c}function M1(c){c.return!==null&&(Jc(c,1),iO(c,1,0))}function D1(c){for(;c===fy;)fy=Ad[--Nd],Ad[Nd]=null,hy=Ad[--Nd],Ad[Nd]=null;for(;c===Xc;)Xc=xi[--Ii],xi[Ii]=null,Bs=xi[--Ii],xi[Ii]=null,_s=xi[--Ii],xi[Ii]=null}var Xo=null,Jo=null,Dn=!1,ea=null;function aO(c,f){var g=Mi(5,null,null,0);g.elementType="DELETED",g.stateNode=f,g.return=c,f=c.deletions,f===null?(c.deletions=[g],c.flags|=16):f.push(g)}function sO(c,f){switch(c.tag){case 5:var g=c.type;return f=f.nodeType!==1||g.toLowerCase()!==f.nodeName.toLowerCase()?null:f,f!==null?(c.stateNode=f,Xo=c,Jo=Yl(f.firstChild),!0):!1;case 6:return f=c.pendingProps===""||f.nodeType!==3?null:f,f!==null?(c.stateNode=f,Xo=c,Jo=null,!0):!1;case 13:return f=f.nodeType!==8?null:f,f!==null?(g=Xc!==null?{id:_s,overflow:Bs}:null,c.memoizedState={dehydrated:f,treeContext:g,retryLane:1073741824},g=Mi(18,null,null,0),g.stateNode=f,g.return=c,c.child=g,Xo=c,Jo=null,!0):!1;default:return!1}}function A1(c){return(c.mode&1)!==0&&(c.flags&128)===0}function N1(c){if(Dn){var f=Jo;if(f){var g=f;if(!sO(c,f)){if(A1(c))throw Error(n(418));f=Yl(g.nextSibling);var T=Xo;f&&sO(c,f)?aO(T,g):(c.flags=c.flags&-4097|2,Dn=!1,Xo=c)}}else{if(A1(c))throw Error(n(418));c.flags=c.flags&-4097|2,Dn=!1,Xo=c}}}function lO(c){for(c=c.return;c!==null&&c.tag!==5&&c.tag!==3&&c.tag!==13;)c=c.return;Xo=c}function py(c){if(c!==Xo)return!1;if(!Dn)return lO(c),Dn=!0,!1;var f;if((f=c.tag!==3)&&!(f=c.tag!==5)&&(f=c.type,f=f!=="head"&&f!=="body"&&!T1(c.type,c.memoizedProps)),f&&(f=Jo)){if(A1(c))throw cO(),Error(n(418));for(;f;)aO(c,f),f=Yl(f.nextSibling)}if(lO(c),c.tag===13){if(c=c.memoizedState,c=c!==null?c.dehydrated:null,!c)throw Error(n(317));e:{for(c=c.nextSibling,f=0;c;){if(c.nodeType===8){var g=c.data;if(g==="/$"){if(f===0){Jo=Yl(c.nextSibling);break e}f--}else g!=="$"&&g!=="$!"&&g!=="$?"||f++}c=c.nextSibling}Jo=null}}else Jo=Xo?Yl(c.stateNode.nextSibling):null;return!0}function cO(){for(var c=Jo;c;)c=Yl(c.nextSibling)}function Od(){Jo=Xo=null,Dn=!1}function O1(c){ea===null?ea=[c]:ea.push(c)}var NZ=k.ReactCurrentBatchConfig;function ta(c,f){if(c&&c.defaultProps){f=Z({},f),c=c.defaultProps;for(var g in c)f[g]===void 0&&(f[g]=c[g]);return f}return f}var my=Ul(null),gy=null,Pd=null,P1=null;function j1(){P1=Pd=gy=null}function L1(c){var f=my.current;In(my),c._currentValue=f}function R1(c,f,g){for(;c!==null;){var T=c.alternate;if((c.childLanes&f)!==f?(c.childLanes|=f,T!==null&&(T.childLanes|=f)):T!==null&&(T.childLanes&f)!==f&&(T.childLanes|=f),c===g)break;c=c.return}}function jd(c,f){gy=c,P1=Pd=null,c=c.dependencies,c!==null&&c.firstContext!==null&&(c.lanes&f&&(No=!0),c.firstContext=null)}function ki(c){var f=c._currentValue;if(P1!==c)if(c={context:c,memoizedValue:f,next:null},Pd===null){if(gy===null)throw Error(n(308));Pd=c,gy.dependencies={lanes:0,firstContext:c}}else Pd=Pd.next=c;return f}var Qc=null;function F1(c){Qc===null?Qc=[c]:Qc.push(c)}function uO(c,f,g,T){var A=f.interleaved;return A===null?(g.next=g,F1(f)):(g.next=A.next,A.next=g),f.interleaved=g,Ys(c,T)}function Ys(c,f){c.lanes|=f;var g=c.alternate;for(g!==null&&(g.lanes|=f),g=c,c=c.return;c!==null;)c.childLanes|=f,g=c.alternate,g!==null&&(g.childLanes|=f),g=c,c=c.return;return g.tag===3?g.stateNode:null}var Wl=!1;function H1(c){c.updateQueue={baseState:c.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function dO(c,f){c=c.updateQueue,f.updateQueue===c&&(f.updateQueue={baseState:c.baseState,firstBaseUpdate:c.firstBaseUpdate,lastBaseUpdate:c.lastBaseUpdate,shared:c.shared,effects:c.effects})}function Us(c,f){return{eventTime:c,lane:f,tag:0,payload:null,callback:null,next:null}}function Gl(c,f,g){var T=c.updateQueue;if(T===null)return null;if(T=T.shared,zt&2){var A=T.pending;return A===null?f.next=f:(f.next=A.next,A.next=f),T.pending=f,Ys(c,g)}return A=T.interleaved,A===null?(f.next=f,F1(T)):(f.next=A.next,A.next=f),T.interleaved=f,Ys(c,g)}function vy(c,f,g){if(f=f.updateQueue,f!==null&&(f=f.shared,(g&4194240)!==0)){var T=f.lanes;T&=c.pendingLanes,g|=T,f.lanes=g,Ve(c,g)}}function fO(c,f){var g=c.updateQueue,T=c.alternate;if(T!==null&&(T=T.updateQueue,g===T)){var A=null,F=null;if(g=g.firstBaseUpdate,g!==null){do{var X={eventTime:g.eventTime,lane:g.lane,tag:g.tag,payload:g.payload,callback:g.callback,next:null};F===null?A=F=X:F=F.next=X,g=g.next}while(g!==null);F===null?A=F=f:F=F.next=f}else A=F=f;g={baseState:T.baseState,firstBaseUpdate:A,lastBaseUpdate:F,shared:T.shared,effects:T.effects},c.updateQueue=g;return}c=g.lastBaseUpdate,c===null?g.firstBaseUpdate=f:c.next=f,g.lastBaseUpdate=f}function yy(c,f,g,T){var A=c.updateQueue;Wl=!1;var F=A.firstBaseUpdate,X=A.lastBaseUpdate,se=A.shared.pending;if(se!==null){A.shared.pending=null;var ue=se,Ee=ue.next;ue.next=null,X===null?F=Ee:X.next=Ee,X=ue;var He=c.alternate;He!==null&&(He=He.updateQueue,se=He.lastBaseUpdate,se!==X&&(se===null?He.firstBaseUpdate=Ee:se.next=Ee,He.lastBaseUpdate=ue))}if(F!==null){var Be=A.baseState;X=0,He=Ee=ue=null,se=F;do{var Re=se.lane,et=se.eventTime;if((T&Re)===Re){He!==null&&(He=He.next={eventTime:et,lane:0,tag:se.tag,payload:se.payload,callback:se.callback,next:null});e:{var ot=c,st=se;switch(Re=f,et=g,st.tag){case 1:if(ot=st.payload,typeof ot=="function"){Be=ot.call(et,Be,Re);break e}Be=ot;break e;case 3:ot.flags=ot.flags&-65537|128;case 0:if(ot=st.payload,Re=typeof ot=="function"?ot.call(et,Be,Re):ot,Re==null)break e;Be=Z({},Be,Re);break e;case 2:Wl=!0}}se.callback!==null&&se.lane!==0&&(c.flags|=64,Re=A.effects,Re===null?A.effects=[se]:Re.push(se))}else et={eventTime:et,lane:Re,tag:se.tag,payload:se.payload,callback:se.callback,next:null},He===null?(Ee=He=et,ue=Be):He=He.next=et,X|=Re;if(se=se.next,se===null){if(se=A.shared.pending,se===null)break;Re=se,se=Re.next,Re.next=null,A.lastBaseUpdate=Re,A.shared.pending=null}}while(!0);if(He===null&&(ue=Be),A.baseState=ue,A.firstBaseUpdate=Ee,A.lastBaseUpdate=He,f=A.shared.interleaved,f!==null){A=f;do X|=A.lane,A=A.next;while(A!==f)}else F===null&&(A.shared.lanes=0);nu|=X,c.lanes=X,c.memoizedState=Be}}function hO(c,f,g){if(c=f.effects,f.effects=null,c!==null)for(f=0;f<c.length;f++){var T=c[f],A=T.callback;if(A!==null){if(T.callback=null,T=g,typeof A!="function")throw Error(n(191,A));A.call(T)}}}var pO=new e.Component().refs;function _1(c,f,g,T){f=c.memoizedState,g=g(T,f),g=g==null?f:Z({},f,g),c.memoizedState=g,c.lanes===0&&(c.updateQueue.baseState=g)}var by={isMounted:function(c){return(c=c._reactInternals)?Zi(c)===c:!1},enqueueSetState:function(c,f,g){c=c._reactInternals;var T=fo(),A=Kl(c),F=Us(T,A);F.payload=f,g!=null&&(F.callback=g),f=Gl(c,F,A),f!==null&&(oa(f,c,A,T),vy(f,c,A))},enqueueReplaceState:function(c,f,g){c=c._reactInternals;var T=fo(),A=Kl(c),F=Us(T,A);F.tag=1,F.payload=f,g!=null&&(F.callback=g),f=Gl(c,F,A),f!==null&&(oa(f,c,A,T),vy(f,c,A))},enqueueForceUpdate:function(c,f){c=c._reactInternals;var g=fo(),T=Kl(c),A=Us(g,T);A.tag=2,f!=null&&(A.callback=f),f=Gl(c,A,T),f!==null&&(oa(f,c,T,g),vy(f,c,T))}};function mO(c,f,g,T,A,F,X){return c=c.stateNode,typeof c.shouldComponentUpdate=="function"?c.shouldComponentUpdate(T,F,X):f.prototype&&f.prototype.isPureReactComponent?!ip(g,T)||!ip(A,F):!0}function gO(c,f,g){var T=!1,A=zl,F=f.contextType;return typeof F=="object"&&F!==null?F=ki(F):(A=Ao(f)?Kc:Gr.current,T=f.contextTypes,F=(T=T!=null)?Dd(c,A):zl),f=new f(g,F),c.memoizedState=f.state!==null&&f.state!==void 0?f.state:null,f.updater=by,c.stateNode=f,f._reactInternals=c,T&&(c=c.stateNode,c.__reactInternalMemoizedUnmaskedChildContext=A,c.__reactInternalMemoizedMaskedChildContext=F),f}function vO(c,f,g,T){c=f.state,typeof f.componentWillReceiveProps=="function"&&f.componentWillReceiveProps(g,T),typeof f.UNSAFE_componentWillReceiveProps=="function"&&f.UNSAFE_componentWillReceiveProps(g,T),f.state!==c&&by.enqueueReplaceState(f,f.state,null)}function B1(c,f,g,T){var A=c.stateNode;A.props=g,A.state=c.memoizedState,A.refs=pO,H1(c);var F=f.contextType;typeof F=="object"&&F!==null?A.context=ki(F):(F=Ao(f)?Kc:Gr.current,A.context=Dd(c,F)),A.state=c.memoizedState,F=f.getDerivedStateFromProps,typeof F=="function"&&(_1(c,f,F,g),A.state=c.memoizedState),typeof f.getDerivedStateFromProps=="function"||typeof A.getSnapshotBeforeUpdate=="function"||typeof A.UNSAFE_componentWillMount!="function"&&typeof A.componentWillMount!="function"||(f=A.state,typeof A.componentWillMount=="function"&&A.componentWillMount(),typeof A.UNSAFE_componentWillMount=="function"&&A.UNSAFE_componentWillMount(),f!==A.state&&by.enqueueReplaceState(A,A.state,null),yy(c,g,A,T),A.state=c.memoizedState),typeof A.componentDidMount=="function"&&(c.flags|=4194308)}function fp(c,f,g){if(c=g.ref,c!==null&&typeof c!="function"&&typeof c!="object"){if(g._owner){if(g=g._owner,g){if(g.tag!==1)throw Error(n(309));var T=g.stateNode}if(!T)throw Error(n(147,c));var A=T,F=""+c;return f!==null&&f.ref!==null&&typeof f.ref=="function"&&f.ref._stringRef===F?f.ref:(f=function(X){var se=A.refs;se===pO&&(se=A.refs={}),X===null?delete se[F]:se[F]=X},f._stringRef=F,f)}if(typeof c!="string")throw Error(n(284));if(!g._owner)throw Error(n(290,c))}return c}function wy(c,f){throw c=Object.prototype.toString.call(f),Error(n(31,c==="[object Object]"?"object with keys {"+Object.keys(f).join(", ")+"}":c))}function yO(c){var f=c._init;return f(c._payload)}function bO(c){function f(be,he){if(c){var Te=be.deletions;Te===null?(be.deletions=[he],be.flags|=16):Te.push(he)}}function g(be,he){if(!c)return null;for(;he!==null;)f(be,he),he=he.sibling;return null}function T(be,he){for(be=new Map;he!==null;)he.key!==null?be.set(he.key,he):be.set(he.index,he),he=he.sibling;return be}function A(be,he){return be=Jl(be,he),be.index=0,be.sibling=null,be}function F(be,he,Te){return be.index=Te,c?(Te=be.alternate,Te!==null?(Te=Te.index,Te<he?(be.flags|=2,he):Te):(be.flags|=2,he)):(be.flags|=1048576,he)}function X(be){return c&&be.alternate===null&&(be.flags|=2),be}function se(be,he,Te,We){return he===null||he.tag!==6?(he=xx(Te,be.mode,We),he.return=be,he):(he=A(he,Te),he.return=be,he)}function ue(be,he,Te,We){var lt=Te.type;return lt===O?He(be,he,Te.props.children,We,Te.key):he!==null&&(he.elementType===lt||typeof lt=="object"&<!==null&<.$$typeof===z&&yO(lt)===he.type)?(We=A(he,Te.props),We.ref=fp(be,he,Te),We.return=be,We):(We=_y(Te.type,Te.key,Te.props,null,be.mode,We),We.ref=fp(be,he,Te),We.return=be,We)}function Ee(be,he,Te,We){return he===null||he.tag!==4||he.stateNode.containerInfo!==Te.containerInfo||he.stateNode.implementation!==Te.implementation?(he=Ix(Te,be.mode,We),he.return=be,he):(he=A(he,Te.children||[]),he.return=be,he)}function He(be,he,Te,We,lt){return he===null||he.tag!==7?(he=au(Te,be.mode,We,lt),he.return=be,he):(he=A(he,Te),he.return=be,he)}function Be(be,he,Te){if(typeof he=="string"&&he!==""||typeof he=="number")return he=xx(""+he,be.mode,Te),he.return=be,he;if(typeof he=="object"&&he!==null){switch(he.$$typeof){case M:return Te=_y(he.type,he.key,he.props,null,be.mode,Te),Te.ref=fp(be,null,he),Te.return=be,Te;case I:return he=Ix(he,be.mode,Te),he.return=be,he;case z:var We=he._init;return Be(be,We(he._payload),Te)}if(Qe(he)||ee(he))return he=au(he,be.mode,Te,null),he.return=be,he;wy(be,he)}return null}function Re(be,he,Te,We){var lt=he!==null?he.key:null;if(typeof Te=="string"&&Te!==""||typeof Te=="number")return lt!==null?null:se(be,he,""+Te,We);if(typeof Te=="object"&&Te!==null){switch(Te.$$typeof){case M:return Te.key===lt?ue(be,he,Te,We):null;case I:return Te.key===lt?Ee(be,he,Te,We):null;case z:return lt=Te._init,Re(be,he,lt(Te._payload),We)}if(Qe(Te)||ee(Te))return lt!==null?null:He(be,he,Te,We,null);wy(be,Te)}return null}function et(be,he,Te,We,lt){if(typeof We=="string"&&We!==""||typeof We=="number")return be=be.get(Te)||null,se(he,be,""+We,lt);if(typeof We=="object"&&We!==null){switch(We.$$typeof){case M:return be=be.get(We.key===null?Te:We.key)||null,ue(he,be,We,lt);case I:return be=be.get(We.key===null?Te:We.key)||null,Ee(he,be,We,lt);case z:var dt=We._init;return et(be,he,Te,dt(We._payload),lt)}if(Qe(We)||ee(We))return be=be.get(Te)||null,He(he,be,We,lt,null);wy(he,We)}return null}function ot(be,he,Te,We){for(var lt=null,dt=null,ft=he,xt=he=0,br=null;ft!==null&&xt<Te.length;xt++){ft.index>xt?(br=ft,ft=null):br=ft.sibling;var Zt=Re(be,ft,Te[xt],We);if(Zt===null){ft===null&&(ft=br);break}c&&ft&&Zt.alternate===null&&f(be,ft),he=F(Zt,he,xt),dt===null?lt=Zt:dt.sibling=Zt,dt=Zt,ft=br}if(xt===Te.length)return g(be,ft),Dn&&Jc(be,xt),lt;if(ft===null){for(;xt<Te.length;xt++)ft=Be(be,Te[xt],We),ft!==null&&(he=F(ft,he,xt),dt===null?lt=ft:dt.sibling=ft,dt=ft);return Dn&&Jc(be,xt),lt}for(ft=T(be,ft);xt<Te.length;xt++)br=et(ft,be,xt,Te[xt],We),br!==null&&(c&&br.alternate!==null&&ft.delete(br.key===null?xt:br.key),he=F(br,he,xt),dt===null?lt=br:dt.sibling=br,dt=br);return c&&ft.forEach(function(Ql){return f(be,Ql)}),Dn&&Jc(be,xt),lt}function st(be,he,Te,We){var lt=ee(Te);if(typeof lt!="function")throw Error(n(150));if(Te=lt.call(Te),Te==null)throw Error(n(151));for(var dt=lt=null,ft=he,xt=he=0,br=null,Zt=Te.next();ft!==null&&!Zt.done;xt++,Zt=Te.next()){ft.index>xt?(br=ft,ft=null):br=ft.sibling;var Ql=Re(be,ft,Zt.value,We);if(Ql===null){ft===null&&(ft=br);break}c&&ft&&Ql.alternate===null&&f(be,ft),he=F(Ql,he,xt),dt===null?lt=Ql:dt.sibling=Ql,dt=Ql,ft=br}if(Zt.done)return g(be,ft),Dn&&Jc(be,xt),lt;if(ft===null){for(;!Zt.done;xt++,Zt=Te.next())Zt=Be(be,Zt.value,We),Zt!==null&&(he=F(Zt,he,xt),dt===null?lt=Zt:dt.sibling=Zt,dt=Zt);return Dn&&Jc(be,xt),lt}for(ft=T(be,ft);!Zt.done;xt++,Zt=Te.next())Zt=et(ft,be,xt,Zt.value,We),Zt!==null&&(c&&Zt.alternate!==null&&ft.delete(Zt.key===null?xt:Zt.key),he=F(Zt,he,xt),dt===null?lt=Zt:dt.sibling=Zt,dt=Zt);return c&&ft.forEach(function(u$){return f(be,u$)}),Dn&&Jc(be,xt),lt}function Kn(be,he,Te,We){if(typeof Te=="object"&&Te!==null&&Te.type===O&&Te.key===null&&(Te=Te.props.children),typeof Te=="object"&&Te!==null){switch(Te.$$typeof){case M:e:{for(var lt=Te.key,dt=he;dt!==null;){if(dt.key===lt){if(lt=Te.type,lt===O){if(dt.tag===7){g(be,dt.sibling),he=A(dt,Te.props.children),he.return=be,be=he;break e}}else if(dt.elementType===lt||typeof lt=="object"&<!==null&<.$$typeof===z&&yO(lt)===dt.type){g(be,dt.sibling),he=A(dt,Te.props),he.ref=fp(be,dt,Te),he.return=be,be=he;break e}g(be,dt);break}else f(be,dt);dt=dt.sibling}Te.type===O?(he=au(Te.props.children,be.mode,We,Te.key),he.return=be,be=he):(We=_y(Te.type,Te.key,Te.props,null,be.mode,We),We.ref=fp(be,he,Te),We.return=be,be=We)}return X(be);case I:e:{for(dt=Te.key;he!==null;){if(he.key===dt)if(he.tag===4&&he.stateNode.containerInfo===Te.containerInfo&&he.stateNode.implementation===Te.implementation){g(be,he.sibling),he=A(he,Te.children||[]),he.return=be,be=he;break e}else{g(be,he);break}else f(be,he);he=he.sibling}he=Ix(Te,be.mode,We),he.return=be,be=he}return X(be);case z:return dt=Te._init,Kn(be,he,dt(Te._payload),We)}if(Qe(Te))return ot(be,he,Te,We);if(ee(Te))return st(be,he,Te,We);wy(be,Te)}return typeof Te=="string"&&Te!==""||typeof Te=="number"?(Te=""+Te,he!==null&&he.tag===6?(g(be,he.sibling),he=A(he,Te),he.return=be,be=he):(g(be,he),he=xx(Te,be.mode,We),he.return=be,be=he),X(be)):g(be,he)}return Kn}var Ld=bO(!0),wO=bO(!1),hp={},Ba=Ul(hp),pp=Ul(hp),mp=Ul(hp);function eu(c){if(c===hp)throw Error(n(174));return c}function Y1(c,f){switch(vn(mp,f),vn(pp,c),vn(Ba,hp),c=f.nodeType,c){case 9:case 11:f=(f=f.documentElement)?f.namespaceURI:Ge(null,"");break;default:c=c===8?f.parentNode:f,f=c.namespaceURI||null,c=c.tagName,f=Ge(f,c)}In(Ba),vn(Ba,f)}function Rd(){In(Ba),In(pp),In(mp)}function SO(c){eu(mp.current);var f=eu(Ba.current),g=Ge(f,c.type);f!==g&&(vn(pp,c),vn(Ba,g))}function U1(c){pp.current===c&&(In(Ba),In(pp))}var Ln=Ul(0);function Sy(c){for(var f=c;f!==null;){if(f.tag===13){var g=f.memoizedState;if(g!==null&&(g=g.dehydrated,g===null||g.data==="$?"||g.data==="$!"))return f}else if(f.tag===19&&f.memoizedProps.revealOrder!==void 0){if(f.flags&128)return f}else if(f.child!==null){f.child.return=f,f=f.child;continue}if(f===c)break;for(;f.sibling===null;){if(f.return===null||f.return===c)return null;f=f.return}f.sibling.return=f.return,f=f.sibling}return null}var z1=[];function V1(){for(var c=0;c<z1.length;c++)z1[c]._workInProgressVersionPrimary=null;z1.length=0}var Ty=k.ReactCurrentDispatcher,W1=k.ReactCurrentBatchConfig,tu=0,Rn=null,sr=null,vr=null,xy=!1,gp=!1,vp=0,OZ=0;function Zr(){throw Error(n(321))}function G1(c,f){if(f===null)return!1;for(var g=0;g<f.length&&g<c.length;g++)if(!Qi(c[g],f[g]))return!1;return!0}function Z1(c,f,g,T,A,F){if(tu=F,Rn=f,f.memoizedState=null,f.updateQueue=null,f.lanes=0,Ty.current=c===null||c.memoizedState===null?RZ:FZ,c=g(T,A),gp){F=0;do{if(gp=!1,vp=0,25<=F)throw Error(n(301));F+=1,vr=sr=null,f.updateQueue=null,Ty.current=HZ,c=g(T,A)}while(gp)}if(Ty.current=Ey,f=sr!==null&&sr.next!==null,tu=0,vr=sr=Rn=null,xy=!1,f)throw Error(n(300));return c}function $1(){var c=vp!==0;return vp=0,c}function Ya(){var c={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return vr===null?Rn.memoizedState=vr=c:vr=vr.next=c,vr}function Ei(){if(sr===null){var c=Rn.alternate;c=c!==null?c.memoizedState:null}else c=sr.next;var f=vr===null?Rn.memoizedState:vr.next;if(f!==null)vr=f,sr=c;else{if(c===null)throw Error(n(310));sr=c,c={memoizedState:sr.memoizedState,baseState:sr.baseState,baseQueue:sr.baseQueue,queue:sr.queue,next:null},vr===null?Rn.memoizedState=vr=c:vr=vr.next=c}return vr}function yp(c,f){return typeof f=="function"?f(c):f}function q1(c){var f=Ei(),g=f.queue;if(g===null)throw Error(n(311));g.lastRenderedReducer=c;var T=sr,A=T.baseQueue,F=g.pending;if(F!==null){if(A!==null){var X=A.next;A.next=F.next,F.next=X}T.baseQueue=A=F,g.pending=null}if(A!==null){F=A.next,T=T.baseState;var se=X=null,ue=null,Ee=F;do{var He=Ee.lane;if((tu&He)===He)ue!==null&&(ue=ue.next={lane:0,action:Ee.action,hasEagerState:Ee.hasEagerState,eagerState:Ee.eagerState,next:null}),T=Ee.hasEagerState?Ee.eagerState:c(T,Ee.action);else{var Be={lane:He,action:Ee.action,hasEagerState:Ee.hasEagerState,eagerState:Ee.eagerState,next:null};ue===null?(se=ue=Be,X=T):ue=ue.next=Be,Rn.lanes|=He,nu|=He}Ee=Ee.next}while(Ee!==null&&Ee!==F);ue===null?X=T:ue.next=se,Qi(T,f.memoizedState)||(No=!0),f.memoizedState=T,f.baseState=X,f.baseQueue=ue,g.lastRenderedState=T}if(c=g.interleaved,c!==null){A=c;do F=A.lane,Rn.lanes|=F,nu|=F,A=A.next;while(A!==c)}else A===null&&(g.lanes=0);return[f.memoizedState,g.dispatch]}function K1(c){var f=Ei(),g=f.queue;if(g===null)throw Error(n(311));g.lastRenderedReducer=c;var T=g.dispatch,A=g.pending,F=f.memoizedState;if(A!==null){g.pending=null;var X=A=A.next;do F=c(F,X.action),X=X.next;while(X!==A);Qi(F,f.memoizedState)||(No=!0),f.memoizedState=F,f.baseQueue===null&&(f.baseState=F),g.lastRenderedState=F}return[F,T]}function TO(){}function xO(c,f){var g=Rn,T=Ei(),A=f(),F=!Qi(T.memoizedState,A);if(F&&(T.memoizedState=A,No=!0),T=T.queue,X1(EO.bind(null,g,T,c),[c]),T.getSnapshot!==f||F||vr!==null&&vr.memoizedState.tag&1){if(g.flags|=2048,bp(9,kO.bind(null,g,T,A,f),void 0,null),yr===null)throw Error(n(349));tu&30||IO(g,f,A)}return A}function IO(c,f,g){c.flags|=16384,c={getSnapshot:f,value:g},f=Rn.updateQueue,f===null?(f={lastEffect:null,stores:null},Rn.updateQueue=f,f.stores=[c]):(g=f.stores,g===null?f.stores=[c]:g.push(c))}function kO(c,f,g,T){f.value=g,f.getSnapshot=T,CO(f)&&MO(c)}function EO(c,f,g){return g(function(){CO(f)&&MO(c)})}function CO(c){var f=c.getSnapshot;c=c.value;try{var g=f();return!Qi(c,g)}catch{return!0}}function MO(c){var f=Ys(c,1);f!==null&&oa(f,c,1,-1)}function DO(c){var f=Ya();return typeof c=="function"&&(c=c()),f.memoizedState=f.baseState=c,c={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:yp,lastRenderedState:c},f.queue=c,c=c.dispatch=LZ.bind(null,Rn,c),[f.memoizedState,c]}function bp(c,f,g,T){return c={tag:c,create:f,destroy:g,deps:T,next:null},f=Rn.updateQueue,f===null?(f={lastEffect:null,stores:null},Rn.updateQueue=f,f.lastEffect=c.next=c):(g=f.lastEffect,g===null?f.lastEffect=c.next=c:(T=g.next,g.next=c,c.next=T,f.lastEffect=c)),c}function AO(){return Ei().memoizedState}function Iy(c,f,g,T){var A=Ya();Rn.flags|=c,A.memoizedState=bp(1|f,g,void 0,T===void 0?null:T)}function ky(c,f,g,T){var A=Ei();T=T===void 0?null:T;var F=void 0;if(sr!==null){var X=sr.memoizedState;if(F=X.destroy,T!==null&&G1(T,X.deps)){A.memoizedState=bp(f,g,F,T);return}}Rn.flags|=c,A.memoizedState=bp(1|f,g,F,T)}function NO(c,f){return Iy(8390656,8,c,f)}function X1(c,f){return ky(2048,8,c,f)}function OO(c,f){return ky(4,2,c,f)}function PO(c,f){return ky(4,4,c,f)}function jO(c,f){if(typeof f=="function")return c=c(),f(c),function(){f(null)};if(f!=null)return c=c(),f.current=c,function(){f.current=null}}function LO(c,f,g){return g=g!=null?g.concat([c]):null,ky(4,4,jO.bind(null,f,c),g)}function J1(){}function RO(c,f){var g=Ei();f=f===void 0?null:f;var T=g.memoizedState;return T!==null&&f!==null&&G1(f,T[1])?T[0]:(g.memoizedState=[c,f],c)}function FO(c,f){var g=Ei();f=f===void 0?null:f;var T=g.memoizedState;return T!==null&&f!==null&&G1(f,T[1])?T[0]:(c=c(),g.memoizedState=[c,f],c)}function HO(c,f,g){return tu&21?(Qi(g,f)||(g=ae(),Rn.lanes|=g,nu|=g,c.baseState=!0),f):(c.baseState&&(c.baseState=!1,No=!0),c.memoizedState=g)}function PZ(c,f){var g=Ke;Ke=g!==0&&4>g?g:4,c(!0);var T=W1.transition;W1.transition={};try{c(!1),f()}finally{Ke=g,W1.transition=T}}function _O(){return Ei().memoizedState}function jZ(c,f,g){var T=Kl(c);if(g={lane:T,action:g,hasEagerState:!1,eagerState:null,next:null},BO(c))YO(f,g);else if(g=uO(c,f,g,T),g!==null){var A=fo();oa(g,c,T,A),UO(g,f,T)}}function LZ(c,f,g){var T=Kl(c),A={lane:T,action:g,hasEagerState:!1,eagerState:null,next:null};if(BO(c))YO(f,A);else{var F=c.alternate;if(c.lanes===0&&(F===null||F.lanes===0)&&(F=f.lastRenderedReducer,F!==null))try{var X=f.lastRenderedState,se=F(X,g);if(A.hasEagerState=!0,A.eagerState=se,Qi(se,X)){var ue=f.interleaved;ue===null?(A.next=A,F1(f)):(A.next=ue.next,ue.next=A),f.interleaved=A;return}}catch{}g=uO(c,f,A,T),g!==null&&(A=fo(),oa(g,c,T,A),UO(g,f,T))}}function BO(c){var f=c.alternate;return c===Rn||f!==null&&f===Rn}function YO(c,f){gp=xy=!0;var g=c.pending;g===null?f.next=f:(f.next=g.next,g.next=f),c.pending=f}function UO(c,f,g){if(g&4194240){var T=f.lanes;T&=c.pendingLanes,g|=T,f.lanes=g,Ve(c,g)}}var Ey={readContext:ki,useCallback:Zr,useContext:Zr,useEffect:Zr,useImperativeHandle:Zr,useInsertionEffect:Zr,useLayoutEffect:Zr,useMemo:Zr,useReducer:Zr,useRef:Zr,useState:Zr,useDebugValue:Zr,useDeferredValue:Zr,useTransition:Zr,useMutableSource:Zr,useSyncExternalStore:Zr,useId:Zr,unstable_isNewReconciler:!1},RZ={readContext:ki,useCallback:function(c,f){return Ya().memoizedState=[c,f===void 0?null:f],c},useContext:ki,useEffect:NO,useImperativeHandle:function(c,f,g){return g=g!=null?g.concat([c]):null,Iy(4194308,4,jO.bind(null,f,c),g)},useLayoutEffect:function(c,f){return Iy(4194308,4,c,f)},useInsertionEffect:function(c,f){return Iy(4,2,c,f)},useMemo:function(c,f){var g=Ya();return f=f===void 0?null:f,c=c(),g.memoizedState=[c,f],c},useReducer:function(c,f,g){var T=Ya();return f=g!==void 0?g(f):f,T.memoizedState=T.baseState=f,c={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:c,lastRenderedState:f},T.queue=c,c=c.dispatch=jZ.bind(null,Rn,c),[T.memoizedState,c]},useRef:function(c){var f=Ya();return c={current:c},f.memoizedState=c},useState:DO,useDebugValue:J1,useDeferredValue:function(c){return Ya().memoizedState=c},useTransition:function(){var c=DO(!1),f=c[0];return c=PZ.bind(null,c[1]),Ya().memoizedState=c,[f,c]},useMutableSource:function(){},useSyncExternalStore:function(c,f,g){var T=Rn,A=Ya();if(Dn){if(g===void 0)throw Error(n(407));g=g()}else{if(g=f(),yr===null)throw Error(n(349));tu&30||IO(T,f,g)}A.memoizedState=g;var F={value:g,getSnapshot:f};return A.queue=F,NO(EO.bind(null,T,F,c),[c]),T.flags|=2048,bp(9,kO.bind(null,T,F,g,f),void 0,null),g},useId:function(){var c=Ya(),f=yr.identifierPrefix;if(Dn){var g=Bs,T=_s;g=(T&~(1<<32-ar(T)-1)).toString(32)+g,f=":"+f+"R"+g,g=vp++,0<g&&(f+="H"+g.toString(32)),f+=":"}else g=OZ++,f=":"+f+"r"+g.toString(32)+":";return c.memoizedState=f},unstable_isNewReconciler:!1},FZ={readContext:ki,useCallback:RO,useContext:ki,useEffect:X1,useImperativeHandle:LO,useInsertionEffect:OO,useLayoutEffect:PO,useMemo:FO,useReducer:q1,useRef:AO,useState:function(){return q1(yp)},useDebugValue:J1,useDeferredValue:function(c){var f=Ei();return HO(f,sr.memoizedState,c)},useTransition:function(){var c=q1(yp)[0],f=Ei().memoizedState;return[c,f]},useMutableSource:TO,useSyncExternalStore:xO,useId:_O,unstable_isNewReconciler:!1},HZ={readContext:ki,useCallback:RO,useContext:ki,useEffect:X1,useImperativeHandle:LO,useInsertionEffect:OO,useLayoutEffect:PO,useMemo:FO,useReducer:K1,useRef:AO,useState:function(){return K1(yp)},useDebugValue:J1,useDeferredValue:function(c){var f=Ei();return sr===null?f.memoizedState=c:HO(f,sr.memoizedState,c)},useTransition:function(){var c=K1(yp)[0],f=Ei().memoizedState;return[c,f]},useMutableSource:TO,useSyncExternalStore:xO,useId:_O,unstable_isNewReconciler:!1};function Fd(c,f){try{var g="",T=f;do g+=ie(T),T=T.return;while(T);var A=g}catch(F){A=`
|
|
|
Error generating stack: `+F.message+`
|
|
|
`+F.stack}return{value:c,source:f,stack:A,digest:null}}function Q1(c,f,g){return{value:c,source:null,stack:g??null,digest:f??null}}function ex(c,f){try{console.error(f.value)}catch(g){setTimeout(function(){throw g})}}var _Z=typeof WeakMap=="function"?WeakMap:Map;function zO(c,f,g){g=Us(-1,g),g.tag=3,g.payload={element:null};var T=f.value;return g.callback=function(){Py||(Py=!0,mx=T),ex(c,f)},g}function VO(c,f,g){g=Us(-1,g),g.tag=3;var T=c.type.getDerivedStateFromError;if(typeof T=="function"){var A=f.value;g.payload=function(){return T(A)},g.callback=function(){ex(c,f)}}var F=c.stateNode;return F!==null&&typeof F.componentDidCatch=="function"&&(g.callback=function(){ex(c,f),typeof T!="function"&&($l===null?$l=new Set([this]):$l.add(this));var X=f.stack;this.componentDidCatch(f.value,{componentStack:X!==null?X:""})}),g}function WO(c,f,g){var T=c.pingCache;if(T===null){T=c.pingCache=new _Z;var A=new Set;T.set(f,A)}else A=T.get(f),A===void 0&&(A=new Set,T.set(f,A));A.has(g)||(A.add(g),c=QZ.bind(null,c,f,g),f.then(c,c))}function GO(c){do{var f;if((f=c.tag===13)&&(f=c.memoizedState,f=f!==null?f.dehydrated!==null:!0),f)return c;c=c.return}while(c!==null);return null}function ZO(c,f,g,T,A){return c.mode&1?(c.flags|=65536,c.lanes=A,c):(c===f?c.flags|=65536:(c.flags|=128,g.flags|=131072,g.flags&=-52805,g.tag===1&&(g.alternate===null?g.tag=17:(f=Us(-1,1),f.tag=2,Gl(g,f,1))),g.lanes|=1),c)}var BZ=k.ReactCurrentOwner,No=!1;function uo(c,f,g,T){f.child=c===null?wO(f,null,g,T):Ld(f,c.child,g,T)}function $O(c,f,g,T,A){g=g.render;var F=f.ref;return jd(f,A),T=Z1(c,f,g,T,F,A),g=$1(),c!==null&&!No?(f.updateQueue=c.updateQueue,f.flags&=-2053,c.lanes&=~A,zs(c,f,A)):(Dn&&g&&M1(f),f.flags|=1,uo(c,f,T,A),f.child)}function qO(c,f,g,T,A){if(c===null){var F=g.type;return typeof F=="function"&&!Tx(F)&&F.defaultProps===void 0&&g.compare===null&&g.defaultProps===void 0?(f.tag=15,f.type=F,KO(c,f,F,T,A)):(c=_y(g.type,null,T,f,f.mode,A),c.ref=f.ref,c.return=f,f.child=c)}if(F=c.child,!(c.lanes&A)){var X=F.memoizedProps;if(g=g.compare,g=g!==null?g:ip,g(X,T)&&c.ref===f.ref)return zs(c,f,A)}return f.flags|=1,c=Jl(F,T),c.ref=f.ref,c.return=f,f.child=c}function KO(c,f,g,T,A){if(c!==null){var F=c.memoizedProps;if(ip(F,T)&&c.ref===f.ref)if(No=!1,f.pendingProps=T=F,(c.lanes&A)!==0)c.flags&131072&&(No=!0);else return f.lanes=c.lanes,zs(c,f,A)}return tx(c,f,g,T,A)}function XO(c,f,g){var T=f.pendingProps,A=T.children,F=c!==null?c.memoizedState:null;if(T.mode==="hidden")if(!(f.mode&1))f.memoizedState={baseLanes:0,cachePool:null,transitions:null},vn(_d,Qo),Qo|=g;else{if(!(g&1073741824))return c=F!==null?F.baseLanes|g:g,f.lanes=f.childLanes=1073741824,f.memoizedState={baseLanes:c,cachePool:null,transitions:null},f.updateQueue=null,vn(_d,Qo),Qo|=c,null;f.memoizedState={baseLanes:0,cachePool:null,transitions:null},T=F!==null?F.baseLanes:g,vn(_d,Qo),Qo|=T}else F!==null?(T=F.baseLanes|g,f.memoizedState=null):T=g,vn(_d,Qo),Qo|=T;return uo(c,f,A,g),f.child}function JO(c,f){var g=f.ref;(c===null&&g!==null||c!==null&&c.ref!==g)&&(f.flags|=512,f.flags|=2097152)}function tx(c,f,g,T,A){var F=Ao(g)?Kc:Gr.current;return F=Dd(f,F),jd(f,A),g=Z1(c,f,g,T,F,A),T=$1(),c!==null&&!No?(f.updateQueue=c.updateQueue,f.flags&=-2053,c.lanes&=~A,zs(c,f,A)):(Dn&&T&&M1(f),f.flags|=1,uo(c,f,g,A),f.child)}function QO(c,f,g,T,A){if(Ao(g)){var F=!0;uy(f)}else F=!1;if(jd(f,A),f.stateNode===null)My(c,f),gO(f,g,T),B1(f,g,T,A),T=!0;else if(c===null){var X=f.stateNode,se=f.memoizedProps;X.props=se;var ue=X.context,Ee=g.contextType;typeof Ee=="object"&&Ee!==null?Ee=ki(Ee):(Ee=Ao(g)?Kc:Gr.current,Ee=Dd(f,Ee));var He=g.getDerivedStateFromProps,Be=typeof He=="function"||typeof X.getSnapshotBeforeUpdate=="function";Be||typeof X.UNSAFE_componentWillReceiveProps!="function"&&typeof X.componentWillReceiveProps!="function"||(se!==T||ue!==Ee)&&vO(f,X,T,Ee),Wl=!1;var Re=f.memoizedState;X.state=Re,yy(f,T,X,A),ue=f.memoizedState,se!==T||Re!==ue||Do.current||Wl?(typeof He=="function"&&(_1(f,g,He,T),ue=f.memoizedState),(se=Wl||mO(f,g,se,T,Re,ue,Ee))?(Be||typeof X.UNSAFE_componentWillMount!="function"&&typeof X.componentWillMount!="function"||(typeof X.componentWillMount=="function"&&X.componentWillMount(),typeof X.UNSAFE_componentWillMount=="function"&&X.UNSAFE_componentWillMount()),typeof X.componentDidMount=="function"&&(f.flags|=4194308)):(typeof X.componentDidMount=="function"&&(f.flags|=4194308),f.memoizedProps=T,f.memoizedState=ue),X.props=T,X.state=ue,X.context=Ee,T=se):(typeof X.componentDidMount=="function"&&(f.flags|=4194308),T=!1)}else{X=f.stateNode,dO(c,f),se=f.memoizedProps,Ee=f.type===f.elementType?se:ta(f.type,se),X.props=Ee,Be=f.pendingProps,Re=X.context,ue=g.contextType,typeof ue=="object"&&ue!==null?ue=ki(ue):(ue=Ao(g)?Kc:Gr.current,ue=Dd(f,ue));var et=g.getDerivedStateFromProps;(He=typeof et=="function"||typeof X.getSnapshotBeforeUpdate=="function")||typeof X.UNSAFE_componentWillReceiveProps!="function"&&typeof X.componentWillReceiveProps!="function"||(se!==Be||Re!==ue)&&vO(f,X,T,ue),Wl=!1,Re=f.memoizedState,X.state=Re,yy(f,T,X,A);var ot=f.memoizedState;se!==Be||Re!==ot||Do.current||Wl?(typeof et=="function"&&(_1(f,g,et,T),ot=f.memoizedState),(Ee=Wl||mO(f,g,Ee,T,Re,ot,ue)||!1)?(He||typeof X.UNSAFE_componentWillUpdate!="function"&&typeof X.componentWillUpdate!="function"||(typeof X.componentWillUpdate=="function"&&X.componentWillUpdate(T,ot,ue),typeof X.UNSAFE_componentWillUpdate=="function"&&X.UNSAFE_componentWillUpdate(T,ot,ue)),typeof X.componentDidUpdate=="function"&&(f.flags|=4),typeof X.getSnapshotBeforeUpdate=="function"&&(f.flags|=1024)):(typeof X.componentDidUpdate!="function"||se===c.memoizedProps&&Re===c.memoizedState||(f.flags|=4),typeof X.getSnapshotBeforeUpdate!="function"||se===c.memoizedProps&&Re===c.memoizedState||(f.flags|=1024),f.memoizedProps=T,f.memoizedState=ot),X.props=T,X.state=ot,X.context=ue,T=Ee):(typeof X.componentDidUpdate!="function"||se===c.memoizedProps&&Re===c.memoizedState||(f.flags|=4),typeof X.getSnapshotBeforeUpdate!="function"||se===c.memoizedProps&&Re===c.memoizedState||(f.flags|=1024),T=!1)}return nx(c,f,g,T,F,A)}function nx(c,f,g,T,A,F){JO(c,f);var X=(f.flags&128)!==0;if(!T&&!X)return A&&rO(f,g,!1),zs(c,f,F);T=f.stateNode,BZ.current=f;var se=X&&typeof g.getDerivedStateFromError!="function"?null:T.render();return f.flags|=1,c!==null&&X?(f.child=Ld(f,c.child,null,F),f.child=Ld(f,null,se,F)):uo(c,f,se,F),f.memoizedState=T.state,A&&rO(f,g,!0),f.child}function eP(c){var f=c.stateNode;f.pendingContext?tO(c,f.pendingContext,f.pendingContext!==f.context):f.context&&tO(c,f.context,!1),Y1(c,f.containerInfo)}function tP(c,f,g,T,A){return Od(),O1(A),f.flags|=256,uo(c,f,g,T),f.child}var rx={dehydrated:null,treeContext:null,retryLane:0};function ox(c){return{baseLanes:c,cachePool:null,transitions:null}}function nP(c,f,g){var T=f.pendingProps,A=Ln.current,F=!1,X=(f.flags&128)!==0,se;if((se=X)||(se=c!==null&&c.memoizedState===null?!1:(A&2)!==0),se?(F=!0,f.flags&=-129):(c===null||c.memoizedState!==null)&&(A|=1),vn(Ln,A&1),c===null)return N1(f),c=f.memoizedState,c!==null&&(c=c.dehydrated,c!==null)?(f.mode&1?c.data==="$!"?f.lanes=8:f.lanes=1073741824:f.lanes=1,null):(X=T.children,c=T.fallback,F?(T=f.mode,F=f.child,X={mode:"hidden",children:X},!(T&1)&&F!==null?(F.childLanes=0,F.pendingProps=X):F=By(X,T,0,null),c=au(c,T,g,null),F.return=f,c.return=f,F.sibling=c,f.child=F,f.child.memoizedState=ox(g),f.memoizedState=rx,c):ix(f,X));if(A=c.memoizedState,A!==null&&(se=A.dehydrated,se!==null))return YZ(c,f,X,T,se,A,g);if(F){F=T.fallback,X=f.mode,A=c.child,se=A.sibling;var ue={mode:"hidden",children:T.children};return!(X&1)&&f.child!==A?(T=f.child,T.childLanes=0,T.pendingProps=ue,f.deletions=null):(T=Jl(A,ue),T.subtreeFlags=A.subtreeFlags&14680064),se!==null?F=Jl(se,F):(F=au(F,X,g,null),F.flags|=2),F.return=f,T.return=f,T.sibling=F,f.child=T,T=F,F=f.child,X=c.child.memoizedState,X=X===null?ox(g):{baseLanes:X.baseLanes|g,cachePool:null,transitions:X.transitions},F.memoizedState=X,F.childLanes=c.childLanes&~g,f.memoizedState=rx,T}return F=c.child,c=F.sibling,T=Jl(F,{mode:"visible",children:T.children}),!(f.mode&1)&&(T.lanes=g),T.return=f,T.sibling=null,c!==null&&(g=f.deletions,g===null?(f.deletions=[c],f.flags|=16):g.push(c)),f.child=T,f.memoizedState=null,T}function ix(c,f){return f=By({mode:"visible",children:f},c.mode,0,null),f.return=c,c.child=f}function Cy(c,f,g,T){return T!==null&&O1(T),Ld(f,c.child,null,g),c=ix(f,f.pendingProps.children),c.flags|=2,f.memoizedState=null,c}function YZ(c,f,g,T,A,F,X){if(g)return f.flags&256?(f.flags&=-257,T=Q1(Error(n(422))),Cy(c,f,X,T)):f.memoizedState!==null?(f.child=c.child,f.flags|=128,null):(F=T.fallback,A=f.mode,T=By({mode:"visible",children:T.children},A,0,null),F=au(F,A,X,null),F.flags|=2,T.return=f,F.return=f,T.sibling=F,f.child=T,f.mode&1&&Ld(f,c.child,null,X),f.child.memoizedState=ox(X),f.memoizedState=rx,F);if(!(f.mode&1))return Cy(c,f,X,null);if(A.data==="$!"){if(T=A.nextSibling&&A.nextSibling.dataset,T)var se=T.dgst;return T=se,F=Error(n(419)),T=Q1(F,T,void 0),Cy(c,f,X,T)}if(se=(X&c.childLanes)!==0,No||se){if(T=yr,T!==null){switch(X&-X){case 4:A=2;break;case 16:A=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:A=32;break;case 536870912:A=268435456;break;default:A=0}A=A&(T.suspendedLanes|X)?0:A,A!==0&&A!==F.retryLane&&(F.retryLane=A,Ys(c,A),oa(T,c,A,-1))}return Sx(),T=Q1(Error(n(421))),Cy(c,f,X,T)}return A.data==="$?"?(f.flags|=128,f.child=c.child,f=e$.bind(null,c),A._reactRetry=f,null):(c=F.treeContext,Jo=Yl(A.nextSibling),Xo=f,Dn=!0,ea=null,c!==null&&(xi[Ii++]=_s,xi[Ii++]=Bs,xi[Ii++]=Xc,_s=c.id,Bs=c.overflow,Xc=f),f=ix(f,T.children),f.flags|=4096,f)}function rP(c,f,g){c.lanes|=f;var T=c.alternate;T!==null&&(T.lanes|=f),R1(c.return,f,g)}function ax(c,f,g,T,A){var F=c.memoizedState;F===null?c.memoizedState={isBackwards:f,rendering:null,renderingStartTime:0,last:T,tail:g,tailMode:A}:(F.isBackwards=f,F.rendering=null,F.renderingStartTime=0,F.last=T,F.tail=g,F.tailMode=A)}function oP(c,f,g){var T=f.pendingProps,A=T.revealOrder,F=T.tail;if(uo(c,f,T.children,g),T=Ln.current,T&2)T=T&1|2,f.flags|=128;else{if(c!==null&&c.flags&128)e:for(c=f.child;c!==null;){if(c.tag===13)c.memoizedState!==null&&rP(c,g,f);else if(c.tag===19)rP(c,g,f);else if(c.child!==null){c.child.return=c,c=c.child;continue}if(c===f)break e;for(;c.sibling===null;){if(c.return===null||c.return===f)break e;c=c.return}c.sibling.return=c.return,c=c.sibling}T&=1}if(vn(Ln,T),!(f.mode&1))f.memoizedState=null;else switch(A){case"forwards":for(g=f.child,A=null;g!==null;)c=g.alternate,c!==null&&Sy(c)===null&&(A=g),g=g.sibling;g=A,g===null?(A=f.child,f.child=null):(A=g.sibling,g.sibling=null),ax(f,!1,A,g,F);break;case"backwards":for(g=null,A=f.child,f.child=null;A!==null;){if(c=A.alternate,c!==null&&Sy(c)===null){f.child=A;break}c=A.sibling,A.sibling=g,g=A,A=c}ax(f,!0,g,null,F);break;case"together":ax(f,!1,null,null,void 0);break;default:f.memoizedState=null}return f.child}function My(c,f){!(f.mode&1)&&c!==null&&(c.alternate=null,f.alternate=null,f.flags|=2)}function zs(c,f,g){if(c!==null&&(f.dependencies=c.dependencies),nu|=f.lanes,!(g&f.childLanes))return null;if(c!==null&&f.child!==c.child)throw Error(n(153));if(f.child!==null){for(c=f.child,g=Jl(c,c.pendingProps),f.child=g,g.return=f;c.sibling!==null;)c=c.sibling,g=g.sibling=Jl(c,c.pendingProps),g.return=f;g.sibling=null}return f.child}function UZ(c,f,g){switch(f.tag){case 3:eP(f),Od();break;case 5:SO(f);break;case 1:Ao(f.type)&&uy(f);break;case 4:Y1(f,f.stateNode.containerInfo);break;case 10:var T=f.type._context,A=f.memoizedProps.value;vn(my,T._currentValue),T._currentValue=A;break;case 13:if(T=f.memoizedState,T!==null)return T.dehydrated!==null?(vn(Ln,Ln.current&1),f.flags|=128,null):g&f.child.childLanes?nP(c,f,g):(vn(Ln,Ln.current&1),c=zs(c,f,g),c!==null?c.sibling:null);vn(Ln,Ln.current&1);break;case 19:if(T=(g&f.childLanes)!==0,c.flags&128){if(T)return oP(c,f,g);f.flags|=128}if(A=f.memoizedState,A!==null&&(A.rendering=null,A.tail=null,A.lastEffect=null),vn(Ln,Ln.current),T)break;return null;case 22:case 23:return f.lanes=0,XO(c,f,g)}return zs(c,f,g)}var iP,sx,aP,sP;iP=function(c,f){for(var g=f.child;g!==null;){if(g.tag===5||g.tag===6)c.appendChild(g.stateNode);else if(g.tag!==4&&g.child!==null){g.child.return=g,g=g.child;continue}if(g===f)break;for(;g.sibling===null;){if(g.return===null||g.return===f)return;g=g.return}g.sibling.return=g.return,g=g.sibling}},sx=function(){},aP=function(c,f,g,T){var A=c.memoizedProps;if(A!==T){c=f.stateNode,eu(Ba.current);var F=null;switch(g){case"input":A=ce(c,A),T=ce(c,T),F=[];break;case"select":A=Z({},A,{value:void 0}),T=Z({},T,{value:void 0}),F=[];break;case"textarea":A=at(c,A),T=at(c,T),F=[];break;default:typeof A.onClick!="function"&&typeof T.onClick=="function"&&(c.onclick=sy)}Pn(g,T);var X;g=null;for(Ee in A)if(!T.hasOwnProperty(Ee)&&A.hasOwnProperty(Ee)&&A[Ee]!=null)if(Ee==="style"){var se=A[Ee];for(X in se)se.hasOwnProperty(X)&&(g||(g={}),g[X]="")}else Ee!=="dangerouslySetInnerHTML"&&Ee!=="children"&&Ee!=="suppressContentEditableWarning"&&Ee!=="suppressHydrationWarning"&&Ee!=="autoFocus"&&(o.hasOwnProperty(Ee)?F||(F=[]):(F=F||[]).push(Ee,null));for(Ee in T){var ue=T[Ee];if(se=A?.[Ee],T.hasOwnProperty(Ee)&&ue!==se&&(ue!=null||se!=null))if(Ee==="style")if(se){for(X in se)!se.hasOwnProperty(X)||ue&&ue.hasOwnProperty(X)||(g||(g={}),g[X]="");for(X in ue)ue.hasOwnProperty(X)&&se[X]!==ue[X]&&(g||(g={}),g[X]=ue[X])}else g||(F||(F=[]),F.push(Ee,g)),g=ue;else Ee==="dangerouslySetInnerHTML"?(ue=ue?ue.__html:void 0,se=se?se.__html:void 0,ue!=null&&se!==ue&&(F=F||[]).push(Ee,ue)):Ee==="children"?typeof ue!="string"&&typeof ue!="number"||(F=F||[]).push(Ee,""+ue):Ee!=="suppressContentEditableWarning"&&Ee!=="suppressHydrationWarning"&&(o.hasOwnProperty(Ee)?(ue!=null&&Ee==="onScroll"&&xn("scroll",c),F||se===ue||(F=[])):(F=F||[]).push(Ee,ue))}g&&(F=F||[]).push("style",g);var Ee=F;(f.updateQueue=Ee)&&(f.flags|=4)}},sP=function(c,f,g,T){g!==T&&(f.flags|=4)};function wp(c,f){if(!Dn)switch(c.tailMode){case"hidden":f=c.tail;for(var g=null;f!==null;)f.alternate!==null&&(g=f),f=f.sibling;g===null?c.tail=null:g.sibling=null;break;case"collapsed":g=c.tail;for(var T=null;g!==null;)g.alternate!==null&&(T=g),g=g.sibling;T===null?f||c.tail===null?c.tail=null:c.tail.sibling=null:T.sibling=null}}function $r(c){var f=c.alternate!==null&&c.alternate.child===c.child,g=0,T=0;if(f)for(var A=c.child;A!==null;)g|=A.lanes|A.childLanes,T|=A.subtreeFlags&14680064,T|=A.flags&14680064,A.return=c,A=A.sibling;else for(A=c.child;A!==null;)g|=A.lanes|A.childLanes,T|=A.subtreeFlags,T|=A.flags,A.return=c,A=A.sibling;return c.subtreeFlags|=T,c.childLanes=g,f}function zZ(c,f,g){var T=f.pendingProps;switch(D1(f),f.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return $r(f),null;case 1:return Ao(f.type)&&cy(),$r(f),null;case 3:return T=f.stateNode,Rd(),In(Do),In(Gr),V1(),T.pendingContext&&(T.context=T.pendingContext,T.pendingContext=null),(c===null||c.child===null)&&(py(f)?f.flags|=4:c===null||c.memoizedState.isDehydrated&&!(f.flags&256)||(f.flags|=1024,ea!==null&&(yx(ea),ea=null))),sx(c,f),$r(f),null;case 5:U1(f);var A=eu(mp.current);if(g=f.type,c!==null&&f.stateNode!=null)aP(c,f,g,T,A),c.ref!==f.ref&&(f.flags|=512,f.flags|=2097152);else{if(!T){if(f.stateNode===null)throw Error(n(166));return $r(f),null}if(c=eu(Ba.current),py(f)){T=f.stateNode,g=f.type;var F=f.memoizedProps;switch(T[_a]=f,T[up]=F,c=(f.mode&1)!==0,g){case"dialog":xn("cancel",T),xn("close",T);break;case"iframe":case"object":case"embed":xn("load",T);break;case"video":case"audio":for(A=0;A<sp.length;A++)xn(sp[A],T);break;case"source":xn("error",T);break;case"img":case"image":case"link":xn("error",T),xn("load",T);break;case"details":xn("toggle",T);break;case"input":Ne(T,F),xn("invalid",T);break;case"select":T._wrapperState={wasMultiple:!!F.multiple},xn("invalid",T);break;case"textarea":vt(T,F),xn("invalid",T)}Pn(g,F),A=null;for(var X in F)if(F.hasOwnProperty(X)){var se=F[X];X==="children"?typeof se=="string"?T.textContent!==se&&(F.suppressHydrationWarning!==!0&&ay(T.textContent,se,c),A=["children",se]):typeof se=="number"&&T.textContent!==""+se&&(F.suppressHydrationWarning!==!0&&ay(T.textContent,se,c),A=["children",""+se]):o.hasOwnProperty(X)&&se!=null&&X==="onScroll"&&xn("scroll",T)}switch(g){case"input":je(T),qe(T,F,!0);break;case"textarea":je(T),Kt(T);break;case"select":case"option":break;default:typeof F.onClick=="function"&&(T.onclick=sy)}T=A,f.updateQueue=T,T!==null&&(f.flags|=4)}else{X=A.nodeType===9?A:A.ownerDocument,c==="http://www.w3.org/1999/xhtml"&&(c=gn(g)),c==="http://www.w3.org/1999/xhtml"?g==="script"?(c=X.createElement("div"),c.innerHTML="<script><\/script>",c=c.removeChild(c.firstChild)):typeof T.is=="string"?c=X.createElement(g,{is:T.is}):(c=X.createElement(g),g==="select"&&(X=c,T.multiple?X.multiple=!0:T.size&&(X.size=T.size))):c=X.createElementNS(c,g),c[_a]=f,c[up]=T,iP(c,f,!1,!1),f.stateNode=c;e:{switch(X=er(g,T),g){case"dialog":xn("cancel",c),xn("close",c),A=T;break;case"iframe":case"object":case"embed":xn("load",c),A=T;break;case"video":case"audio":for(A=0;A<sp.length;A++)xn(sp[A],c);A=T;break;case"source":xn("error",c),A=T;break;case"img":case"image":case"link":xn("error",c),xn("load",c),A=T;break;case"details":xn("toggle",c),A=T;break;case"input":Ne(c,T),A=ce(c,T),xn("invalid",c);break;case"option":A=T;break;case"select":c._wrapperState={wasMultiple:!!T.multiple},A=Z({},T,{value:void 0}),xn("invalid",c);break;case"textarea":vt(c,T),A=at(c,T),xn("invalid",c);break;default:A=T}Pn(g,A),se=A;for(F in se)if(se.hasOwnProperty(F)){var ue=se[F];F==="style"?io(c,ue):F==="dangerouslySetInnerHTML"?(ue=ue?ue.__html:void 0,ue!=null&&mt(c,ue)):F==="children"?typeof ue=="string"?(g!=="textarea"||ue!=="")&&It(c,ue):typeof ue=="number"&&It(c,""+ue):F!=="suppressContentEditableWarning"&&F!=="suppressHydrationWarning"&&F!=="autoFocus"&&(o.hasOwnProperty(F)?ue!=null&&F==="onScroll"&&xn("scroll",c):ue!=null&&C(c,F,ue,X))}switch(g){case"input":je(c),qe(c,T,!1);break;case"textarea":je(c),Kt(c);break;case"option":T.value!=null&&c.setAttribute("value",""+ge(T.value));break;case"select":c.multiple=!!T.multiple,F=T.value,F!=null?it(c,!!T.multiple,F,!1):T.defaultValue!=null&&it(c,!!T.multiple,T.defaultValue,!0);break;default:typeof A.onClick=="function"&&(c.onclick=sy)}switch(g){case"button":case"input":case"select":case"textarea":T=!!T.autoFocus;break e;case"img":T=!0;break e;default:T=!1}}T&&(f.flags|=4)}f.ref!==null&&(f.flags|=512,f.flags|=2097152)}return $r(f),null;case 6:if(c&&f.stateNode!=null)sP(c,f,c.memoizedProps,T);else{if(typeof T!="string"&&f.stateNode===null)throw Error(n(166));if(g=eu(mp.current),eu(Ba.current),py(f)){if(T=f.stateNode,g=f.memoizedProps,T[_a]=f,(F=T.nodeValue!==g)&&(c=Xo,c!==null))switch(c.tag){case 3:ay(T.nodeValue,g,(c.mode&1)!==0);break;case 5:c.memoizedProps.suppressHydrationWarning!==!0&&ay(T.nodeValue,g,(c.mode&1)!==0)}F&&(f.flags|=4)}else T=(g.nodeType===9?g:g.ownerDocument).createTextNode(T),T[_a]=f,f.stateNode=T}return $r(f),null;case 13:if(In(Ln),T=f.memoizedState,c===null||c.memoizedState!==null&&c.memoizedState.dehydrated!==null){if(Dn&&Jo!==null&&f.mode&1&&!(f.flags&128))cO(),Od(),f.flags|=98560,F=!1;else if(F=py(f),T!==null&&T.dehydrated!==null){if(c===null){if(!F)throw Error(n(318));if(F=f.memoizedState,F=F!==null?F.dehydrated:null,!F)throw Error(n(317));F[_a]=f}else Od(),!(f.flags&128)&&(f.memoizedState=null),f.flags|=4;$r(f),F=!1}else ea!==null&&(yx(ea),ea=null),F=!0;if(!F)return f.flags&65536?f:null}return f.flags&128?(f.lanes=g,f):(T=T!==null,T!==(c!==null&&c.memoizedState!==null)&&T&&(f.child.flags|=8192,f.mode&1&&(c===null||Ln.current&1?lr===0&&(lr=3):Sx())),f.updateQueue!==null&&(f.flags|=4),$r(f),null);case 4:return Rd(),sx(c,f),c===null&&lp(f.stateNode.containerInfo),$r(f),null;case 10:return L1(f.type._context),$r(f),null;case 17:return Ao(f.type)&&cy(),$r(f),null;case 19:if(In(Ln),F=f.memoizedState,F===null)return $r(f),null;if(T=(f.flags&128)!==0,X=F.rendering,X===null)if(T)wp(F,!1);else{if(lr!==0||c!==null&&c.flags&128)for(c=f.child;c!==null;){if(X=Sy(c),X!==null){for(f.flags|=128,wp(F,!1),T=X.updateQueue,T!==null&&(f.updateQueue=T,f.flags|=4),f.subtreeFlags=0,T=g,g=f.child;g!==null;)F=g,c=T,F.flags&=14680066,X=F.alternate,X===null?(F.childLanes=0,F.lanes=c,F.child=null,F.subtreeFlags=0,F.memoizedProps=null,F.memoizedState=null,F.updateQueue=null,F.dependencies=null,F.stateNode=null):(F.childLanes=X.childLanes,F.lanes=X.lanes,F.child=X.child,F.subtreeFlags=0,F.deletions=null,F.memoizedProps=X.memoizedProps,F.memoizedState=X.memoizedState,F.updateQueue=X.updateQueue,F.type=X.type,c=X.dependencies,F.dependencies=c===null?null:{lanes:c.lanes,firstContext:c.firstContext}),g=g.sibling;return vn(Ln,Ln.current&1|2),f.child}c=c.sibling}F.tail!==null&&fn()>Bd&&(f.flags|=128,T=!0,wp(F,!1),f.lanes=4194304)}else{if(!T)if(c=Sy(X),c!==null){if(f.flags|=128,T=!0,g=c.updateQueue,g!==null&&(f.updateQueue=g,f.flags|=4),wp(F,!0),F.tail===null&&F.tailMode==="hidden"&&!X.alternate&&!Dn)return $r(f),null}else 2*fn()-F.renderingStartTime>Bd&&g!==1073741824&&(f.flags|=128,T=!0,wp(F,!1),f.lanes=4194304);F.isBackwards?(X.sibling=f.child,f.child=X):(g=F.last,g!==null?g.sibling=X:f.child=X,F.last=X)}return F.tail!==null?(f=F.tail,F.rendering=f,F.tail=f.sibling,F.renderingStartTime=fn(),f.sibling=null,g=Ln.current,vn(Ln,T?g&1|2:g&1),f):($r(f),null);case 22:case 23:return wx(),T=f.memoizedState!==null,c!==null&&c.memoizedState!==null!==T&&(f.flags|=8192),T&&f.mode&1?Qo&1073741824&&($r(f),f.subtreeFlags&6&&(f.flags|=8192)):$r(f),null;case 24:return null;case 25:return null}throw Error(n(156,f.tag))}function VZ(c,f){switch(D1(f),f.tag){case 1:return Ao(f.type)&&cy(),c=f.flags,c&65536?(f.flags=c&-65537|128,f):null;case 3:return Rd(),In(Do),In(Gr),V1(),c=f.flags,c&65536&&!(c&128)?(f.flags=c&-65537|128,f):null;case 5:return U1(f),null;case 13:if(In(Ln),c=f.memoizedState,c!==null&&c.dehydrated!==null){if(f.alternate===null)throw Error(n(340));Od()}return c=f.flags,c&65536?(f.flags=c&-65537|128,f):null;case 19:return In(Ln),null;case 4:return Rd(),null;case 10:return L1(f.type._context),null;case 22:case 23:return wx(),null;case 24:return null;default:return null}}var Dy=!1,qr=!1,WZ=typeof WeakSet=="function"?WeakSet:Set,nt=null;function Hd(c,f){var g=c.ref;if(g!==null)if(typeof g=="function")try{g(null)}catch(T){zn(c,f,T)}else g.current=null}function lx(c,f,g){try{g()}catch(T){zn(c,f,T)}}var lP=!1;function GZ(c,f){if(w1=Ko,c=_N(),f1(c)){if("selectionStart"in c)var g={start:c.selectionStart,end:c.selectionEnd};else e:{g=(g=c.ownerDocument)&&g.defaultView||window;var T=g.getSelection&&g.getSelection();if(T&&T.rangeCount!==0){g=T.anchorNode;var A=T.anchorOffset,F=T.focusNode;T=T.focusOffset;try{g.nodeType,F.nodeType}catch{g=null;break e}var X=0,se=-1,ue=-1,Ee=0,He=0,Be=c,Re=null;t:for(;;){for(var et;Be!==g||A!==0&&Be.nodeType!==3||(se=X+A),Be!==F||T!==0&&Be.nodeType!==3||(ue=X+T),Be.nodeType===3&&(X+=Be.nodeValue.length),(et=Be.firstChild)!==null;)Re=Be,Be=et;for(;;){if(Be===c)break t;if(Re===g&&++Ee===A&&(se=X),Re===F&&++He===T&&(ue=X),(et=Be.nextSibling)!==null)break;Be=Re,Re=Be.parentNode}Be=et}g=se===-1||ue===-1?null:{start:se,end:ue}}else g=null}g=g||{start:0,end:0}}else g=null;for(S1={focusedElem:c,selectionRange:g},Ko=!1,nt=f;nt!==null;)if(f=nt,c=f.child,(f.subtreeFlags&1028)!==0&&c!==null)c.return=f,nt=c;else for(;nt!==null;){f=nt;try{var ot=f.alternate;if(f.flags&1024)switch(f.tag){case 0:case 11:case 15:break;case 1:if(ot!==null){var st=ot.memoizedProps,Kn=ot.memoizedState,be=f.stateNode,he=be.getSnapshotBeforeUpdate(f.elementType===f.type?st:ta(f.type,st),Kn);be.__reactInternalSnapshotBeforeUpdate=he}break;case 3:var Te=f.stateNode.containerInfo;Te.nodeType===1?Te.textContent="":Te.nodeType===9&&Te.documentElement&&Te.removeChild(Te.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(We){zn(f,f.return,We)}if(c=f.sibling,c!==null){c.return=f.return,nt=c;break}nt=f.return}return ot=lP,lP=!1,ot}function Sp(c,f,g){var T=f.updateQueue;if(T=T!==null?T.lastEffect:null,T!==null){var A=T=T.next;do{if((A.tag&c)===c){var F=A.destroy;A.destroy=void 0,F!==void 0&&lx(f,g,F)}A=A.next}while(A!==T)}}function Ay(c,f){if(f=f.updateQueue,f=f!==null?f.lastEffect:null,f!==null){var g=f=f.next;do{if((g.tag&c)===c){var T=g.create;g.destroy=T()}g=g.next}while(g!==f)}}function cx(c){var f=c.ref;if(f!==null){var g=c.stateNode;switch(c.tag){case 5:c=g;break;default:c=g}typeof f=="function"?f(c):f.current=c}}function cP(c){var f=c.alternate;f!==null&&(c.alternate=null,cP(f)),c.child=null,c.deletions=null,c.sibling=null,c.tag===5&&(f=c.stateNode,f!==null&&(delete f[_a],delete f[up],delete f[k1],delete f[MZ],delete f[DZ])),c.stateNode=null,c.return=null,c.dependencies=null,c.memoizedProps=null,c.memoizedState=null,c.pendingProps=null,c.stateNode=null,c.updateQueue=null}function uP(c){return c.tag===5||c.tag===3||c.tag===4}function dP(c){e:for(;;){for(;c.sibling===null;){if(c.return===null||uP(c.return))return null;c=c.return}for(c.sibling.return=c.return,c=c.sibling;c.tag!==5&&c.tag!==6&&c.tag!==18;){if(c.flags&2||c.child===null||c.tag===4)continue e;c.child.return=c,c=c.child}if(!(c.flags&2))return c.stateNode}}function ux(c,f,g){var T=c.tag;if(T===5||T===6)c=c.stateNode,f?g.nodeType===8?g.parentNode.insertBefore(c,f):g.insertBefore(c,f):(g.nodeType===8?(f=g.parentNode,f.insertBefore(c,g)):(f=g,f.appendChild(c)),g=g._reactRootContainer,g!=null||f.onclick!==null||(f.onclick=sy));else if(T!==4&&(c=c.child,c!==null))for(ux(c,f,g),c=c.sibling;c!==null;)ux(c,f,g),c=c.sibling}function dx(c,f,g){var T=c.tag;if(T===5||T===6)c=c.stateNode,f?g.insertBefore(c,f):g.appendChild(c);else if(T!==4&&(c=c.child,c!==null))for(dx(c,f,g),c=c.sibling;c!==null;)dx(c,f,g),c=c.sibling}var Nr=null,na=!1;function Zl(c,f,g){for(g=g.child;g!==null;)fP(c,f,g),g=g.sibling}function fP(c,f,g){if(lo&&typeof lo.onCommitFiberUnmount=="function")try{lo.onCommitFiberUnmount($o,g)}catch{}switch(g.tag){case 5:qr||Hd(g,f);case 6:var T=Nr,A=na;Nr=null,Zl(c,f,g),Nr=T,na=A,Nr!==null&&(na?(c=Nr,g=g.stateNode,c.nodeType===8?c.parentNode.removeChild(g):c.removeChild(g)):Nr.removeChild(g.stateNode));break;case 18:Nr!==null&&(na?(c=Nr,g=g.stateNode,c.nodeType===8?I1(c.parentNode,g):c.nodeType===1&&I1(c,g),Ra(c)):I1(Nr,g.stateNode));break;case 4:T=Nr,A=na,Nr=g.stateNode.containerInfo,na=!0,Zl(c,f,g),Nr=T,na=A;break;case 0:case 11:case 14:case 15:if(!qr&&(T=g.updateQueue,T!==null&&(T=T.lastEffect,T!==null))){A=T=T.next;do{var F=A,X=F.destroy;F=F.tag,X!==void 0&&(F&2||F&4)&&lx(g,f,X),A=A.next}while(A!==T)}Zl(c,f,g);break;case 1:if(!qr&&(Hd(g,f),T=g.stateNode,typeof T.componentWillUnmount=="function"))try{T.props=g.memoizedProps,T.state=g.memoizedState,T.componentWillUnmount()}catch(se){zn(g,f,se)}Zl(c,f,g);break;case 21:Zl(c,f,g);break;case 22:g.mode&1?(qr=(T=qr)||g.memoizedState!==null,Zl(c,f,g),qr=T):Zl(c,f,g);break;default:Zl(c,f,g)}}function hP(c){var f=c.updateQueue;if(f!==null){c.updateQueue=null;var g=c.stateNode;g===null&&(g=c.stateNode=new WZ),f.forEach(function(T){var A=t$.bind(null,c,T);g.has(T)||(g.add(T),T.then(A,A))})}}function ra(c,f){var g=f.deletions;if(g!==null)for(var T=0;T<g.length;T++){var A=g[T];try{var F=c,X=f,se=X;e:for(;se!==null;){switch(se.tag){case 5:Nr=se.stateNode,na=!1;break e;case 3:Nr=se.stateNode.containerInfo,na=!0;break e;case 4:Nr=se.stateNode.containerInfo,na=!0;break e}se=se.return}if(Nr===null)throw Error(n(160));fP(F,X,A),Nr=null,na=!1;var ue=A.alternate;ue!==null&&(ue.return=null),A.return=null}catch(Ee){zn(A,f,Ee)}}if(f.subtreeFlags&12854)for(f=f.child;f!==null;)pP(f,c),f=f.sibling}function pP(c,f){var g=c.alternate,T=c.flags;switch(c.tag){case 0:case 11:case 14:case 15:if(ra(f,c),Ua(c),T&4){try{Sp(3,c,c.return),Ay(3,c)}catch(st){zn(c,c.return,st)}try{Sp(5,c,c.return)}catch(st){zn(c,c.return,st)}}break;case 1:ra(f,c),Ua(c),T&512&&g!==null&&Hd(g,g.return);break;case 5:if(ra(f,c),Ua(c),T&512&&g!==null&&Hd(g,g.return),c.flags&32){var A=c.stateNode;try{It(A,"")}catch(st){zn(c,c.return,st)}}if(T&4&&(A=c.stateNode,A!=null)){var F=c.memoizedProps,X=g!==null?g.memoizedProps:F,se=c.type,ue=c.updateQueue;if(c.updateQueue=null,ue!==null)try{se==="input"&&F.type==="radio"&&F.name!=null&&Pe(A,F),er(se,X);var Ee=er(se,F);for(X=0;X<ue.length;X+=2){var He=ue[X],Be=ue[X+1];He==="style"?io(A,Be):He==="dangerouslySetInnerHTML"?mt(A,Be):He==="children"?It(A,Be):C(A,He,Be,Ee)}switch(se){case"input":_e(A,F);break;case"textarea":Mt(A,F);break;case"select":var Re=A._wrapperState.wasMultiple;A._wrapperState.wasMultiple=!!F.multiple;var et=F.value;et!=null?it(A,!!F.multiple,et,!1):Re!==!!F.multiple&&(F.defaultValue!=null?it(A,!!F.multiple,F.defaultValue,!0):it(A,!!F.multiple,F.multiple?[]:"",!1))}A[up]=F}catch(st){zn(c,c.return,st)}}break;case 6:if(ra(f,c),Ua(c),T&4){if(c.stateNode===null)throw Error(n(162));A=c.stateNode,F=c.memoizedProps;try{A.nodeValue=F}catch(st){zn(c,c.return,st)}}break;case 3:if(ra(f,c),Ua(c),T&4&&g!==null&&g.memoizedState.isDehydrated)try{Ra(f.containerInfo)}catch(st){zn(c,c.return,st)}break;case 4:ra(f,c),Ua(c);break;case 13:ra(f,c),Ua(c),A=c.child,A.flags&8192&&(F=A.memoizedState!==null,A.stateNode.isHidden=F,!F||A.alternate!==null&&A.alternate.memoizedState!==null||(px=fn())),T&4&&hP(c);break;case 22:if(He=g!==null&&g.memoizedState!==null,c.mode&1?(qr=(Ee=qr)||He,ra(f,c),qr=Ee):ra(f,c),Ua(c),T&8192){if(Ee=c.memoizedState!==null,(c.stateNode.isHidden=Ee)&&!He&&c.mode&1)for(nt=c,He=c.child;He!==null;){for(Be=nt=He;nt!==null;){switch(Re=nt,et=Re.child,Re.tag){case 0:case 11:case 14:case 15:Sp(4,Re,Re.return);break;case 1:Hd(Re,Re.return);var ot=Re.stateNode;if(typeof ot.componentWillUnmount=="function"){T=Re,g=Re.return;try{f=T,ot.props=f.memoizedProps,ot.state=f.memoizedState,ot.componentWillUnmount()}catch(st){zn(T,g,st)}}break;case 5:Hd(Re,Re.return);break;case 22:if(Re.memoizedState!==null){vP(Be);continue}}et!==null?(et.return=Re,nt=et):vP(Be)}He=He.sibling}e:for(He=null,Be=c;;){if(Be.tag===5){if(He===null){He=Be;try{A=Be.stateNode,Ee?(F=A.style,typeof F.setProperty=="function"?F.setProperty("display","none","important"):F.display="none"):(se=Be.stateNode,ue=Be.memoizedProps.style,X=ue!=null&&ue.hasOwnProperty("display")?ue.display:null,se.style.display=$n("display",X))}catch(st){zn(c,c.return,st)}}}else if(Be.tag===6){if(He===null)try{Be.stateNode.nodeValue=Ee?"":Be.memoizedProps}catch(st){zn(c,c.return,st)}}else if((Be.tag!==22&&Be.tag!==23||Be.memoizedState===null||Be===c)&&Be.child!==null){Be.child.return=Be,Be=Be.child;continue}if(Be===c)break e;for(;Be.sibling===null;){if(Be.return===null||Be.return===c)break e;He===Be&&(He=null),Be=Be.return}He===Be&&(He=null),Be.sibling.return=Be.return,Be=Be.sibling}}break;case 19:ra(f,c),Ua(c),T&4&&hP(c);break;case 21:break;default:ra(f,c),Ua(c)}}function Ua(c){var f=c.flags;if(f&2){try{e:{for(var g=c.return;g!==null;){if(uP(g)){var T=g;break e}g=g.return}throw Error(n(160))}switch(T.tag){case 5:var A=T.stateNode;T.flags&32&&(It(A,""),T.flags&=-33);var F=dP(c);dx(c,F,A);break;case 3:case 4:var X=T.stateNode.containerInfo,se=dP(c);ux(c,se,X);break;default:throw Error(n(161))}}catch(ue){zn(c,c.return,ue)}c.flags&=-3}f&4096&&(c.flags&=-4097)}function ZZ(c,f,g){nt=c,mP(c)}function mP(c,f,g){for(var T=(c.mode&1)!==0;nt!==null;){var A=nt,F=A.child;if(A.tag===22&&T){var X=A.memoizedState!==null||Dy;if(!X){var se=A.alternate,ue=se!==null&&se.memoizedState!==null||qr;se=Dy;var Ee=qr;if(Dy=X,(qr=ue)&&!Ee)for(nt=A;nt!==null;)X=nt,ue=X.child,X.tag===22&&X.memoizedState!==null?yP(A):ue!==null?(ue.return=X,nt=ue):yP(A);for(;F!==null;)nt=F,mP(F),F=F.sibling;nt=A,Dy=se,qr=Ee}gP(c)}else A.subtreeFlags&8772&&F!==null?(F.return=A,nt=F):gP(c)}}function gP(c){for(;nt!==null;){var f=nt;if(f.flags&8772){var g=f.alternate;try{if(f.flags&8772)switch(f.tag){case 0:case 11:case 15:qr||Ay(5,f);break;case 1:var T=f.stateNode;if(f.flags&4&&!qr)if(g===null)T.componentDidMount();else{var A=f.elementType===f.type?g.memoizedProps:ta(f.type,g.memoizedProps);T.componentDidUpdate(A,g.memoizedState,T.__reactInternalSnapshotBeforeUpdate)}var F=f.updateQueue;F!==null&&hO(f,F,T);break;case 3:var X=f.updateQueue;if(X!==null){if(g=null,f.child!==null)switch(f.child.tag){case 5:g=f.child.stateNode;break;case 1:g=f.child.stateNode}hO(f,X,g)}break;case 5:var se=f.stateNode;if(g===null&&f.flags&4){g=se;var ue=f.memoizedProps;switch(f.type){case"button":case"input":case"select":case"textarea":ue.autoFocus&&g.focus();break;case"img":ue.src&&(g.src=ue.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(f.memoizedState===null){var Ee=f.alternate;if(Ee!==null){var He=Ee.memoizedState;if(He!==null){var Be=He.dehydrated;Be!==null&&Ra(Be)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}qr||f.flags&512&&cx(f)}catch(Re){zn(f,f.return,Re)}}if(f===c){nt=null;break}if(g=f.sibling,g!==null){g.return=f.return,nt=g;break}nt=f.return}}function vP(c){for(;nt!==null;){var f=nt;if(f===c){nt=null;break}var g=f.sibling;if(g!==null){g.return=f.return,nt=g;break}nt=f.return}}function yP(c){for(;nt!==null;){var f=nt;try{switch(f.tag){case 0:case 11:case 15:var g=f.return;try{Ay(4,f)}catch(ue){zn(f,g,ue)}break;case 1:var T=f.stateNode;if(typeof T.componentDidMount=="function"){var A=f.return;try{T.componentDidMount()}catch(ue){zn(f,A,ue)}}var F=f.return;try{cx(f)}catch(ue){zn(f,F,ue)}break;case 5:var X=f.return;try{cx(f)}catch(ue){zn(f,X,ue)}}}catch(ue){zn(f,f.return,ue)}if(f===c){nt=null;break}var se=f.sibling;if(se!==null){se.return=f.return,nt=se;break}nt=f.return}}var $Z=Math.ceil,Ny=k.ReactCurrentDispatcher,fx=k.ReactCurrentOwner,Ci=k.ReactCurrentBatchConfig,zt=0,yr=null,tr=null,Or=0,Qo=0,_d=Ul(0),lr=0,Tp=null,nu=0,Oy=0,hx=0,xp=null,Oo=null,px=0,Bd=1/0,Vs=null,Py=!1,mx=null,$l=null,jy=!1,ql=null,Ly=0,Ip=0,gx=null,Ry=-1,Fy=0;function fo(){return zt&6?fn():Ry!==-1?Ry:Ry=fn()}function Kl(c){return c.mode&1?zt&2&&Or!==0?Or&-Or:NZ.transition!==null?(Fy===0&&(Fy=ae()),Fy):(c=Ke,c!==0||(c=window.event,c=c===void 0?16:qh(c.type)),c):1}function oa(c,f,g,T){if(50<Ip)throw Ip=0,gx=null,Error(n(185));ve(c,g,T),(!(zt&2)||c!==yr)&&(c===yr&&(!(zt&2)&&(Oy|=g),lr===4&&Xl(c,Or)),Po(c,T),g===1&&zt===0&&!(f.mode&1)&&(Bd=fn()+500,dy&&Vl()))}function Po(c,f){var g=c.callbackNode;W(c,f);var T=Pa(c,c===yr?Or:0);if(T===0)g!==null&&Fc(g),c.callbackNode=null,c.callbackPriority=0;else if(f=T&-T,c.callbackPriority!==f){if(g!=null&&Fc(g),f===1)c.tag===0?AZ(wP.bind(null,c)):oO(wP.bind(null,c)),EZ(function(){!(zt&6)&&Vl()}),g=null;else{switch(yt(T)){case 1:g=jl;break;case 4:g=Ll;break;case 16:g=Na;break;case 536870912:g=$i;break;default:g=Na}g=MP(g,bP.bind(null,c))}c.callbackPriority=f,c.callbackNode=g}}function bP(c,f){if(Ry=-1,Fy=0,zt&6)throw Error(n(327));var g=c.callbackNode;if(Yd()&&c.callbackNode!==g)return null;var T=Pa(c,c===yr?Or:0);if(T===0)return null;if(T&30||T&c.expiredLanes||f)f=Hy(c,T);else{f=T;var A=zt;zt|=2;var F=TP();(yr!==c||Or!==f)&&(Vs=null,Bd=fn()+500,ou(c,f));do try{XZ();break}catch(se){SP(c,se)}while(!0);j1(),Ny.current=F,zt=A,tr!==null?f=0:(yr=null,Or=0,f=lr)}if(f!==0){if(f===2&&(A=te(c),A!==0&&(T=A,f=vx(c,A))),f===1)throw g=Tp,ou(c,0),Xl(c,T),Po(c,fn()),g;if(f===6)Xl(c,T);else{if(A=c.current.alternate,!(T&30)&&!qZ(A)&&(f=Hy(c,T),f===2&&(F=te(c),F!==0&&(T=F,f=vx(c,F))),f===1))throw g=Tp,ou(c,0),Xl(c,T),Po(c,fn()),g;switch(c.finishedWork=A,c.finishedLanes=T,f){case 0:case 1:throw Error(n(345));case 2:iu(c,Oo,Vs);break;case 3:if(Xl(c,T),(T&130023424)===T&&(f=px+500-fn(),10<f)){if(Pa(c,0)!==0)break;if(A=c.suspendedLanes,(A&T)!==T){fo(),c.pingedLanes|=c.suspendedLanes&A;break}c.timeoutHandle=x1(iu.bind(null,c,Oo,Vs),f);break}iu(c,Oo,Vs);break;case 4:if(Xl(c,T),(T&4194240)===T)break;for(f=c.eventTimes,A=-1;0<T;){var X=31-ar(T);F=1<<X,X=f[X],X>A&&(A=X),T&=~F}if(T=A,T=fn()-T,T=(120>T?120:480>T?480:1080>T?1080:1920>T?1920:3e3>T?3e3:4320>T?4320:1960*$Z(T/1960))-T,10<T){c.timeoutHandle=x1(iu.bind(null,c,Oo,Vs),T);break}iu(c,Oo,Vs);break;case 5:iu(c,Oo,Vs);break;default:throw Error(n(329))}}}return Po(c,fn()),c.callbackNode===g?bP.bind(null,c):null}function vx(c,f){var g=xp;return c.current.memoizedState.isDehydrated&&(ou(c,f).flags|=256),c=Hy(c,f),c!==2&&(f=Oo,Oo=g,f!==null&&yx(f)),c}function yx(c){Oo===null?Oo=c:Oo.push.apply(Oo,c)}function qZ(c){for(var f=c;;){if(f.flags&16384){var g=f.updateQueue;if(g!==null&&(g=g.stores,g!==null))for(var T=0;T<g.length;T++){var A=g[T],F=A.getSnapshot;A=A.value;try{if(!Qi(F(),A))return!1}catch{return!1}}}if(g=f.child,f.subtreeFlags&16384&&g!==null)g.return=f,f=g;else{if(f===c)break;for(;f.sibling===null;){if(f.return===null||f.return===c)return!0;f=f.return}f.sibling.return=f.return,f=f.sibling}}return!0}function Xl(c,f){for(f&=~hx,f&=~Oy,c.suspendedLanes|=f,c.pingedLanes&=~f,c=c.expirationTimes;0<f;){var g=31-ar(f),T=1<<g;c[g]=-1,f&=~T}}function wP(c){if(zt&6)throw Error(n(327));Yd();var f=Pa(c,0);if(!(f&1))return Po(c,fn()),null;var g=Hy(c,f);if(c.tag!==0&&g===2){var T=te(c);T!==0&&(f=T,g=vx(c,T))}if(g===1)throw g=Tp,ou(c,0),Xl(c,f),Po(c,fn()),g;if(g===6)throw Error(n(345));return c.finishedWork=c.current.alternate,c.finishedLanes=f,iu(c,Oo,Vs),Po(c,fn()),null}function bx(c,f){var g=zt;zt|=1;try{return c(f)}finally{zt=g,zt===0&&(Bd=fn()+500,dy&&Vl())}}function ru(c){ql!==null&&ql.tag===0&&!(zt&6)&&Yd();var f=zt;zt|=1;var g=Ci.transition,T=Ke;try{if(Ci.transition=null,Ke=1,c)return c()}finally{Ke=T,Ci.transition=g,zt=f,!(zt&6)&&Vl()}}function wx(){Qo=_d.current,In(_d)}function ou(c,f){c.finishedWork=null,c.finishedLanes=0;var g=c.timeoutHandle;if(g!==-1&&(c.timeoutHandle=-1,kZ(g)),tr!==null)for(g=tr.return;g!==null;){var T=g;switch(D1(T),T.tag){case 1:T=T.type.childContextTypes,T!=null&&cy();break;case 3:Rd(),In(Do),In(Gr),V1();break;case 5:U1(T);break;case 4:Rd();break;case 13:In(Ln);break;case 19:In(Ln);break;case 10:L1(T.type._context);break;case 22:case 23:wx()}g=g.return}if(yr=c,tr=c=Jl(c.current,null),Or=Qo=f,lr=0,Tp=null,hx=Oy=nu=0,Oo=xp=null,Qc!==null){for(f=0;f<Qc.length;f++)if(g=Qc[f],T=g.interleaved,T!==null){g.interleaved=null;var A=T.next,F=g.pending;if(F!==null){var X=F.next;F.next=A,T.next=X}g.pending=T}Qc=null}return c}function SP(c,f){do{var g=tr;try{if(j1(),Ty.current=Ey,xy){for(var T=Rn.memoizedState;T!==null;){var A=T.queue;A!==null&&(A.pending=null),T=T.next}xy=!1}if(tu=0,vr=sr=Rn=null,gp=!1,vp=0,fx.current=null,g===null||g.return===null){lr=1,Tp=f,tr=null;break}e:{var F=c,X=g.return,se=g,ue=f;if(f=Or,se.flags|=32768,ue!==null&&typeof ue=="object"&&typeof ue.then=="function"){var Ee=ue,He=se,Be=He.tag;if(!(He.mode&1)&&(Be===0||Be===11||Be===15)){var Re=He.alternate;Re?(He.updateQueue=Re.updateQueue,He.memoizedState=Re.memoizedState,He.lanes=Re.lanes):(He.updateQueue=null,He.memoizedState=null)}var et=GO(X);if(et!==null){et.flags&=-257,ZO(et,X,se,F,f),et.mode&1&&WO(F,Ee,f),f=et,ue=Ee;var ot=f.updateQueue;if(ot===null){var st=new Set;st.add(ue),f.updateQueue=st}else ot.add(ue);break e}else{if(!(f&1)){WO(F,Ee,f),Sx();break e}ue=Error(n(426))}}else if(Dn&&se.mode&1){var Kn=GO(X);if(Kn!==null){!(Kn.flags&65536)&&(Kn.flags|=256),ZO(Kn,X,se,F,f),O1(Fd(ue,se));break e}}F=ue=Fd(ue,se),lr!==4&&(lr=2),xp===null?xp=[F]:xp.push(F),F=X;do{switch(F.tag){case 3:F.flags|=65536,f&=-f,F.lanes|=f;var be=zO(F,ue,f);fO(F,be);break e;case 1:se=ue;var he=F.type,Te=F.stateNode;if(!(F.flags&128)&&(typeof he.getDerivedStateFromError=="function"||Te!==null&&typeof Te.componentDidCatch=="function"&&($l===null||!$l.has(Te)))){F.flags|=65536,f&=-f,F.lanes|=f;var We=VO(F,se,f);fO(F,We);break e}}F=F.return}while(F!==null)}IP(g)}catch(lt){f=lt,tr===g&&g!==null&&(tr=g=g.return);continue}break}while(!0)}function TP(){var c=Ny.current;return Ny.current=Ey,c===null?Ey:c}function Sx(){(lr===0||lr===3||lr===2)&&(lr=4),yr===null||!(nu&268435455)&&!(Oy&268435455)||Xl(yr,Or)}function Hy(c,f){var g=zt;zt|=2;var T=TP();(yr!==c||Or!==f)&&(Vs=null,ou(c,f));do try{KZ();break}catch(A){SP(c,A)}while(!0);if(j1(),zt=g,Ny.current=T,tr!==null)throw Error(n(261));return yr=null,Or=0,lr}function KZ(){for(;tr!==null;)xP(tr)}function XZ(){for(;tr!==null&&!dd();)xP(tr)}function xP(c){var f=CP(c.alternate,c,Qo);c.memoizedProps=c.pendingProps,f===null?IP(c):tr=f,fx.current=null}function IP(c){var f=c;do{var g=f.alternate;if(c=f.return,f.flags&32768){if(g=VZ(g,f),g!==null){g.flags&=32767,tr=g;return}if(c!==null)c.flags|=32768,c.subtreeFlags=0,c.deletions=null;else{lr=6,tr=null;return}}else if(g=zZ(g,f,Qo),g!==null){tr=g;return}if(f=f.sibling,f!==null){tr=f;return}tr=f=c}while(f!==null);lr===0&&(lr=5)}function iu(c,f,g){var T=Ke,A=Ci.transition;try{Ci.transition=null,Ke=1,JZ(c,f,g,T)}finally{Ci.transition=A,Ke=T}return null}function JZ(c,f,g,T){do Yd();while(ql!==null);if(zt&6)throw Error(n(327));g=c.finishedWork;var A=c.finishedLanes;if(g===null)return null;if(c.finishedWork=null,c.finishedLanes=0,g===c.current)throw Error(n(177));c.callbackNode=null,c.callbackPriority=0;var F=g.lanes|g.childLanes;if(De(c,F),c===yr&&(tr=yr=null,Or=0),!(g.subtreeFlags&2064)&&!(g.flags&2064)||jy||(jy=!0,MP(Na,function(){return Yd(),null})),F=(g.flags&15990)!==0,g.subtreeFlags&15990||F){F=Ci.transition,Ci.transition=null;var X=Ke;Ke=1;var se=zt;zt|=4,fx.current=null,GZ(c,g),pP(g,c),yZ(S1),Ko=!!w1,S1=w1=null,c.current=g,ZZ(g),fd(),zt=se,Ke=X,Ci.transition=F}else c.current=g;if(jy&&(jy=!1,ql=c,Ly=A),F=c.pendingLanes,F===0&&($l=null),Ns(g.stateNode),Po(c,fn()),f!==null)for(T=c.onRecoverableError,g=0;g<f.length;g++)A=f[g],T(A.value,{componentStack:A.stack,digest:A.digest});if(Py)throw Py=!1,c=mx,mx=null,c;return Ly&1&&c.tag!==0&&Yd(),F=c.pendingLanes,F&1?c===gx?Ip++:(Ip=0,gx=c):Ip=0,Vl(),null}function Yd(){if(ql!==null){var c=yt(Ly),f=Ci.transition,g=Ke;try{if(Ci.transition=null,Ke=16>c?16:c,ql===null)var T=!1;else{if(c=ql,ql=null,Ly=0,zt&6)throw Error(n(331));var A=zt;for(zt|=4,nt=c.current;nt!==null;){var F=nt,X=F.child;if(nt.flags&16){var se=F.deletions;if(se!==null){for(var ue=0;ue<se.length;ue++){var Ee=se[ue];for(nt=Ee;nt!==null;){var He=nt;switch(He.tag){case 0:case 11:case 15:Sp(8,He,F)}var Be=He.child;if(Be!==null)Be.return=He,nt=Be;else for(;nt!==null;){He=nt;var Re=He.sibling,et=He.return;if(cP(He),He===Ee){nt=null;break}if(Re!==null){Re.return=et,nt=Re;break}nt=et}}}var ot=F.alternate;if(ot!==null){var st=ot.child;if(st!==null){ot.child=null;do{var Kn=st.sibling;st.sibling=null,st=Kn}while(st!==null)}}nt=F}}if(F.subtreeFlags&2064&&X!==null)X.return=F,nt=X;else e:for(;nt!==null;){if(F=nt,F.flags&2048)switch(F.tag){case 0:case 11:case 15:Sp(9,F,F.return)}var be=F.sibling;if(be!==null){be.return=F.return,nt=be;break e}nt=F.return}}var he=c.current;for(nt=he;nt!==null;){X=nt;var Te=X.child;if(X.subtreeFlags&2064&&Te!==null)Te.return=X,nt=Te;else e:for(X=he;nt!==null;){if(se=nt,se.flags&2048)try{switch(se.tag){case 0:case 11:case 15:Ay(9,se)}}catch(lt){zn(se,se.return,lt)}if(se===X){nt=null;break e}var We=se.sibling;if(We!==null){We.return=se.return,nt=We;break e}nt=se.return}}if(zt=A,Vl(),lo&&typeof lo.onPostCommitFiberRoot=="function")try{lo.onPostCommitFiberRoot($o,c)}catch{}T=!0}return T}finally{Ke=g,Ci.transition=f}}return!1}function kP(c,f,g){f=Fd(g,f),f=zO(c,f,1),c=Gl(c,f,1),f=fo(),c!==null&&(ve(c,1,f),Po(c,f))}function zn(c,f,g){if(c.tag===3)kP(c,c,g);else for(;f!==null;){if(f.tag===3){kP(f,c,g);break}else if(f.tag===1){var T=f.stateNode;if(typeof f.type.getDerivedStateFromError=="function"||typeof T.componentDidCatch=="function"&&($l===null||!$l.has(T))){c=Fd(g,c),c=VO(f,c,1),f=Gl(f,c,1),c=fo(),f!==null&&(ve(f,1,c),Po(f,c));break}}f=f.return}}function QZ(c,f,g){var T=c.pingCache;T!==null&&T.delete(f),f=fo(),c.pingedLanes|=c.suspendedLanes&g,yr===c&&(Or&g)===g&&(lr===4||lr===3&&(Or&130023424)===Or&&500>fn()-px?ou(c,0):hx|=g),Po(c,f)}function EP(c,f){f===0&&(c.mode&1?(f=Os,Os<<=1,!(Os&130023424)&&(Os=4194304)):f=1);var g=fo();c=Ys(c,f),c!==null&&(ve(c,f,g),Po(c,g))}function e$(c){var f=c.memoizedState,g=0;f!==null&&(g=f.retryLane),EP(c,g)}function t$(c,f){var g=0;switch(c.tag){case 13:var T=c.stateNode,A=c.memoizedState;A!==null&&(g=A.retryLane);break;case 19:T=c.stateNode;break;default:throw Error(n(314))}T!==null&&T.delete(f),EP(c,g)}var CP;CP=function(c,f,g){if(c!==null)if(c.memoizedProps!==f.pendingProps||Do.current)No=!0;else{if(!(c.lanes&g)&&!(f.flags&128))return No=!1,UZ(c,f,g);No=!!(c.flags&131072)}else No=!1,Dn&&f.flags&1048576&&iO(f,hy,f.index);switch(f.lanes=0,f.tag){case 2:var T=f.type;My(c,f),c=f.pendingProps;var A=Dd(f,Gr.current);jd(f,g),A=Z1(null,f,T,c,A,g);var F=$1();return f.flags|=1,typeof A=="object"&&A!==null&&typeof A.render=="function"&&A.$$typeof===void 0?(f.tag=1,f.memoizedState=null,f.updateQueue=null,Ao(T)?(F=!0,uy(f)):F=!1,f.memoizedState=A.state!==null&&A.state!==void 0?A.state:null,H1(f),A.updater=by,f.stateNode=A,A._reactInternals=f,B1(f,T,c,g),f=nx(null,f,T,!0,F,g)):(f.tag=0,Dn&&F&&M1(f),uo(null,f,A,g),f=f.child),f;case 16:T=f.elementType;e:{switch(My(c,f),c=f.pendingProps,A=T._init,T=A(T._payload),f.type=T,A=f.tag=r$(T),c=ta(T,c),A){case 0:f=tx(null,f,T,c,g);break e;case 1:f=QO(null,f,T,c,g);break e;case 11:f=$O(null,f,T,c,g);break e;case 14:f=qO(null,f,T,ta(T.type,c),g);break e}throw Error(n(306,T,""))}return f;case 0:return T=f.type,A=f.pendingProps,A=f.elementType===T?A:ta(T,A),tx(c,f,T,A,g);case 1:return T=f.type,A=f.pendingProps,A=f.elementType===T?A:ta(T,A),QO(c,f,T,A,g);case 3:e:{if(eP(f),c===null)throw Error(n(387));T=f.pendingProps,F=f.memoizedState,A=F.element,dO(c,f),yy(f,T,null,g);var X=f.memoizedState;if(T=X.element,F.isDehydrated)if(F={element:T,isDehydrated:!1,cache:X.cache,pendingSuspenseBoundaries:X.pendingSuspenseBoundaries,transitions:X.transitions},f.updateQueue.baseState=F,f.memoizedState=F,f.flags&256){A=Fd(Error(n(423)),f),f=tP(c,f,T,g,A);break e}else if(T!==A){A=Fd(Error(n(424)),f),f=tP(c,f,T,g,A);break e}else for(Jo=Yl(f.stateNode.containerInfo.firstChild),Xo=f,Dn=!0,ea=null,g=wO(f,null,T,g),f.child=g;g;)g.flags=g.flags&-3|4096,g=g.sibling;else{if(Od(),T===A){f=zs(c,f,g);break e}uo(c,f,T,g)}f=f.child}return f;case 5:return SO(f),c===null&&N1(f),T=f.type,A=f.pendingProps,F=c!==null?c.memoizedProps:null,X=A.children,T1(T,A)?X=null:F!==null&&T1(T,F)&&(f.flags|=32),JO(c,f),uo(c,f,X,g),f.child;case 6:return c===null&&N1(f),null;case 13:return nP(c,f,g);case 4:return Y1(f,f.stateNode.containerInfo),T=f.pendingProps,c===null?f.child=Ld(f,null,T,g):uo(c,f,T,g),f.child;case 11:return T=f.type,A=f.pendingProps,A=f.elementType===T?A:ta(T,A),$O(c,f,T,A,g);case 7:return uo(c,f,f.pendingProps,g),f.child;case 8:return uo(c,f,f.pendingProps.children,g),f.child;case 12:return uo(c,f,f.pendingProps.children,g),f.child;case 10:e:{if(T=f.type._context,A=f.pendingProps,F=f.memoizedProps,X=A.value,vn(my,T._currentValue),T._currentValue=X,F!==null)if(Qi(F.value,X)){if(F.children===A.children&&!Do.current){f=zs(c,f,g);break e}}else for(F=f.child,F!==null&&(F.return=f);F!==null;){var se=F.dependencies;if(se!==null){X=F.child;for(var ue=se.firstContext;ue!==null;){if(ue.context===T){if(F.tag===1){ue=Us(-1,g&-g),ue.tag=2;var Ee=F.updateQueue;if(Ee!==null){Ee=Ee.shared;var He=Ee.pending;He===null?ue.next=ue:(ue.next=He.next,He.next=ue),Ee.pending=ue}}F.lanes|=g,ue=F.alternate,ue!==null&&(ue.lanes|=g),R1(F.return,g,f),se.lanes|=g;break}ue=ue.next}}else if(F.tag===10)X=F.type===f.type?null:F.child;else if(F.tag===18){if(X=F.return,X===null)throw Error(n(341));X.lanes|=g,se=X.alternate,se!==null&&(se.lanes|=g),R1(X,g,f),X=F.sibling}else X=F.child;if(X!==null)X.return=F;else for(X=F;X!==null;){if(X===f){X=null;break}if(F=X.sibling,F!==null){F.return=X.return,X=F;break}X=X.return}F=X}uo(c,f,A.children,g),f=f.child}return f;case 9:return A=f.type,T=f.pendingProps.children,jd(f,g),A=ki(A),T=T(A),f.flags|=1,uo(c,f,T,g),f.child;case 14:return T=f.type,A=ta(T,f.pendingProps),A=ta(T.type,A),qO(c,f,T,A,g);case 15:return KO(c,f,f.type,f.pendingProps,g);case 17:return T=f.type,A=f.pendingProps,A=f.elementType===T?A:ta(T,A),My(c,f),f.tag=1,Ao(T)?(c=!0,uy(f)):c=!1,jd(f,g),gO(f,T,A),B1(f,T,A,g),nx(null,f,T,!0,c,g);case 19:return oP(c,f,g);case 22:return XO(c,f,g)}throw Error(n(156,f.tag))};function MP(c,f){return As(c,f)}function n$(c,f,g,T){this.tag=c,this.key=g,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=f,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=T,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Mi(c,f,g,T){return new n$(c,f,g,T)}function Tx(c){return c=c.prototype,!(!c||!c.isReactComponent)}function r$(c){if(typeof c=="function")return Tx(c)?1:0;if(c!=null){if(c=c.$$typeof,c===H)return 11;if(c===K)return 14}return 2}function Jl(c,f){var g=c.alternate;return g===null?(g=Mi(c.tag,f,c.key,c.mode),g.elementType=c.elementType,g.type=c.type,g.stateNode=c.stateNode,g.alternate=c,c.alternate=g):(g.pendingProps=f,g.type=c.type,g.flags=0,g.subtreeFlags=0,g.deletions=null),g.flags=c.flags&14680064,g.childLanes=c.childLanes,g.lanes=c.lanes,g.child=c.child,g.memoizedProps=c.memoizedProps,g.memoizedState=c.memoizedState,g.updateQueue=c.updateQueue,f=c.dependencies,g.dependencies=f===null?null:{lanes:f.lanes,firstContext:f.firstContext},g.sibling=c.sibling,g.index=c.index,g.ref=c.ref,g}function _y(c,f,g,T,A,F){var X=2;if(T=c,typeof c=="function")Tx(c)&&(X=1);else if(typeof c=="string")X=5;else e:switch(c){case O:return au(g.children,A,F,f);case R:X=8,A|=8;break;case L:return c=Mi(12,g,f,A|2),c.elementType=L,c.lanes=F,c;case U:return c=Mi(13,g,f,A),c.elementType=U,c.lanes=F,c;case G:return c=Mi(19,g,f,A),c.elementType=G,c.lanes=F,c;case ne:return By(g,A,F,f);default:if(typeof c=="object"&&c!==null)switch(c.$$typeof){case B:X=10;break e;case _:X=9;break e;case H:X=11;break e;case K:X=14;break e;case z:X=16,T=null;break e}throw Error(n(130,c==null?c:typeof c,""))}return f=Mi(X,g,f,A),f.elementType=c,f.type=T,f.lanes=F,f}function au(c,f,g,T){return c=Mi(7,c,T,f),c.lanes=g,c}function By(c,f,g,T){return c=Mi(22,c,T,f),c.elementType=ne,c.lanes=g,c.stateNode={isHidden:!1},c}function xx(c,f,g){return c=Mi(6,c,null,f),c.lanes=g,c}function Ix(c,f,g){return f=Mi(4,c.children!==null?c.children:[],c.key,f),f.lanes=g,f.stateNode={containerInfo:c.containerInfo,pendingChildren:null,implementation:c.implementation},f}function o$(c,f,g,T,A){this.tag=f,this.containerInfo=c,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Se(0),this.expirationTimes=Se(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Se(0),this.identifierPrefix=T,this.onRecoverableError=A,this.mutableSourceEagerHydrationData=null}function kx(c,f,g,T,A,F,X,se,ue){return c=new o$(c,f,g,se,ue),f===1?(f=1,F===!0&&(f|=8)):f=0,F=Mi(3,null,null,f),c.current=F,F.stateNode=c,F.memoizedState={element:T,isDehydrated:g,cache:null,transitions:null,pendingSuspenseBoundaries:null},H1(F),c}function i$(c,f,g){var T=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:I,key:T==null?null:""+T,children:c,containerInfo:f,implementation:g}}function DP(c){if(!c)return zl;c=c._reactInternals;e:{if(Zi(c)!==c||c.tag!==1)throw Error(n(170));var f=c;do{switch(f.tag){case 3:f=f.stateNode.context;break e;case 1:if(Ao(f.type)){f=f.stateNode.__reactInternalMemoizedMergedChildContext;break e}}f=f.return}while(f!==null);throw Error(n(171))}if(c.tag===1){var g=c.type;if(Ao(g))return nO(c,g,f)}return f}function AP(c,f,g,T,A,F,X,se,ue){return c=kx(g,T,!0,c,A,F,X,se,ue),c.context=DP(null),g=c.current,T=fo(),A=Kl(g),F=Us(T,A),F.callback=f??null,Gl(g,F,A),c.current.lanes=A,ve(c,A,T),Po(c,T),c}function Yy(c,f,g,T){var A=f.current,F=fo(),X=Kl(A);return g=DP(g),f.context===null?f.context=g:f.pendingContext=g,f=Us(F,X),f.payload={element:c},T=T===void 0?null:T,T!==null&&(f.callback=T),c=Gl(A,f,X),c!==null&&(oa(c,A,X,F),vy(c,A,X)),X}function Uy(c){if(c=c.current,!c.child)return null;switch(c.child.tag){case 5:return c.child.stateNode;default:return c.child.stateNode}}function NP(c,f){if(c=c.memoizedState,c!==null&&c.dehydrated!==null){var g=c.retryLane;c.retryLane=g!==0&&g<f?g:f}}function Ex(c,f){NP(c,f),(c=c.alternate)&&NP(c,f)}function a$(){return null}var OP=typeof reportError=="function"?reportError:function(c){console.error(c)};function Cx(c){this._internalRoot=c}zy.prototype.render=Cx.prototype.render=function(c){var f=this._internalRoot;if(f===null)throw Error(n(409));Yy(c,f,null,null)},zy.prototype.unmount=Cx.prototype.unmount=function(){var c=this._internalRoot;if(c!==null){this._internalRoot=null;var f=c.containerInfo;ru(function(){Yy(null,c,null,null)}),f[Fs]=null}};function zy(c){this._internalRoot=c}zy.prototype.unstable_scheduleHydration=function(c){if(c){var f=xo();c={blockedOn:null,target:c,priority:f};for(var g=0;g<La.length&&f!==0&&f<La[g].priority;g++);La.splice(g,0,c),g===0&&Si(c)}};function Mx(c){return!(!c||c.nodeType!==1&&c.nodeType!==9&&c.nodeType!==11)}function Vy(c){return!(!c||c.nodeType!==1&&c.nodeType!==9&&c.nodeType!==11&&(c.nodeType!==8||c.nodeValue!==" react-mount-point-unstable "))}function PP(){}function s$(c,f,g,T,A){if(A){if(typeof T=="function"){var F=T;T=function(){var Ee=Uy(X);F.call(Ee)}}var X=AP(f,T,c,0,null,!1,!1,"",PP);return c._reactRootContainer=X,c[Fs]=X.current,lp(c.nodeType===8?c.parentNode:c),ru(),X}for(;A=c.lastChild;)c.removeChild(A);if(typeof T=="function"){var se=T;T=function(){var Ee=Uy(ue);se.call(Ee)}}var ue=kx(c,0,!1,null,null,!1,!1,"",PP);return c._reactRootContainer=ue,c[Fs]=ue.current,lp(c.nodeType===8?c.parentNode:c),ru(function(){Yy(f,ue,g,T)}),ue}function Wy(c,f,g,T,A){var F=g._reactRootContainer;if(F){var X=F;if(typeof A=="function"){var se=A;A=function(){var ue=Uy(X);se.call(ue)}}Yy(f,X,c,A)}else X=s$(g,f,c,A,T);return Uy(X)}kt=function(c){switch(c.tag){case 3:var f=c.stateNode;if(f.current.memoizedState.isDehydrated){var g=Oa(f.pendingLanes);g!==0&&(Ve(f,g|1),Po(f,fn()),!(zt&6)&&(Bd=fn()+500,Vl()))}break;case 13:ru(function(){var T=Ys(c,1);if(T!==null){var A=fo();oa(T,c,1,A)}}),Ex(c,1)}},ln=function(c){if(c.tag===13){var f=Ys(c,134217728);if(f!==null){var g=fo();oa(f,c,134217728,g)}Ex(c,134217728)}},To=function(c){if(c.tag===13){var f=Kl(c),g=Ys(c,f);if(g!==null){var T=fo();oa(g,c,f,T)}Ex(c,f)}},xo=function(){return Ke},zr=function(c,f){var g=Ke;try{return Ke=c,f()}finally{Ke=g}},gr=function(c,f,g){switch(f){case"input":if(_e(c,g),f=g.name,g.type==="radio"&&f!=null){for(g=c;g.parentNode;)g=g.parentNode;for(g=g.querySelectorAll("input[name="+JSON.stringify(""+f)+'][type="radio"]'),f=0;f<g.length;f++){var T=g[f];if(T!==c&&T.form===c.form){var A=ly(T);if(!A)throw Error(n(90));Ie(T),_e(T,A)}}}break;case"textarea":Mt(c,g);break;case"select":f=g.value,f!=null&&it(c,!!g.multiple,f,!1)}},jn=bx,ao=ru;var l$={usingClientEntryPoint:!1,Events:[dp,Cd,ly,Mr,wo,bx]},kp={findFiberByHostInstance:qc,bundleType:0,version:"18.2.0",rendererPackageName:"react-dom"},c$={bundleType:kp.bundleType,version:kp.version,rendererPackageName:kp.rendererPackageName,rendererConfig:kp.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:k.ReactCurrentDispatcher,findHostInstanceByFiber:function(c){return c=Ds(c),c===null?null:c.stateNode},findFiberByHostInstance:kp.findFiberByHostInstance||a$,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.2.0-next-9e3b772b8-20220608"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Gy=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Gy.isDisabled&&Gy.supportsFiber)try{$o=Gy.inject(c$),lo=Gy}catch{}}return jo.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=l$,jo.createPortal=function(c,f){var g=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Mx(f))throw Error(n(200));return i$(c,f,null,g)},jo.createRoot=function(c,f){if(!Mx(c))throw Error(n(299));var g=!1,T="",A=OP;return f!=null&&(f.unstable_strictMode===!0&&(g=!0),f.identifierPrefix!==void 0&&(T=f.identifierPrefix),f.onRecoverableError!==void 0&&(A=f.onRecoverableError)),f=kx(c,1,!1,null,null,g,!1,T,A),c[Fs]=f.current,lp(c.nodeType===8?c.parentNode:c),new Cx(f)},jo.findDOMNode=function(c){if(c==null)return null;if(c.nodeType===1)return c;var f=c._reactInternals;if(f===void 0)throw typeof c.render=="function"?Error(n(188)):(c=Object.keys(c).join(","),Error(n(268,c)));return c=Ds(f),c=c===null?null:c.stateNode,c},jo.flushSync=function(c){return ru(c)},jo.hydrate=function(c,f,g){if(!Vy(f))throw Error(n(200));return Wy(null,c,f,!0,g)},jo.hydrateRoot=function(c,f,g){if(!Mx(c))throw Error(n(405));var T=g!=null&&g.hydratedSources||null,A=!1,F="",X=OP;if(g!=null&&(g.unstable_strictMode===!0&&(A=!0),g.identifierPrefix!==void 0&&(F=g.identifierPrefix),g.onRecoverableError!==void 0&&(X=g.onRecoverableError)),f=AP(f,null,c,1,g??null,A,!1,F,X),c[Fs]=f.current,lp(c),T)for(c=0;c<T.length;c++)g=T[c],A=g._getVersion,A=A(g._source),f.mutableSourceEagerHydrationData==null?f.mutableSourceEagerHydrationData=[g,A]:f.mutableSourceEagerHydrationData.push(g,A);return new zy(f)},jo.render=function(c,f,g){if(!Vy(f))throw Error(n(200));return Wy(null,c,f,!1,g)},jo.unmountComponentAtNode=function(c){if(!Vy(c))throw Error(n(40));return c._reactRootContainer?(ru(function(){Wy(null,null,c,!1,function(){c._reactRootContainer=null,c[Fs]=null})}),!0):!1},jo.unstable_batchedUpdates=bx,jo.unstable_renderSubtreeIntoContainer=function(c,f,g,T){if(!Vy(g))throw Error(n(200));if(c==null||c._reactInternals===void 0)throw Error(n(38));return Wy(c,f,g,!1,T)},jo.version="18.2.0-next-9e3b772b8-20220608",jo}function nH(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(nH)}catch(e){console.error(e)}}nH();tH.exports=VQ();var nD=tH.exports;const rD=tt(nD);var tv,rH=nD;tv=Fi.createRoot=rH.createRoot;Fi.hydrateRoot=rH.hydrateRoot;const WQ=e=>{const{children:t,className:n,clickSpaceDestroy:r,destroy:o}=e,i=()=>{r&&o()},a=s=>{(s.key==="Escape"||(s.ctrlKey||s.metaKey)&&s.key.toLowerCase()==="w")&&o()};return w.jsx("div",{className:`dialog-wrapper ${n}`,onClick:i,onKeyDown:s=>a(s),children:w.jsx("div",{className:"dialog-container",onClick:s=>s.stopPropagation(),children:t})})};function yS(e,t,n){const r=document.createElement("div");document.body.append(r),setTimeout(()=>{r.firstElementChild?.classList.add("showup")},0);const o={destroy:()=>{r.firstElementChild?.classList.remove("showup"),r.firstElementChild?.classList.add("showoff"),setTimeout(()=>{r.detach(),s.unmount(),document.body.find(".domtoimage-thino")&&document.body.findAll(".domtoimage-thino").forEach(u=>{u.detach()})},j8)}},i={...n,destroy:o.destroy};let a=w.jsx(WQ,{destroy:o.destroy,clickSpaceDestroy:!0,...e,children:w.jsx(t,{...i})});a=w.jsx(zi,{store:ke,context:ct,children:a});const s=Fi.createRoot(r);return s.render(a),o}class GQ extends N.Modal{constructor(t,n,r){super(t),this.version=r,this.plugin=n}plugin;onOpen(){super.onOpen(),this.titleEl.setText(E("Submit issue")),new N.Setting(this.contentEl).setName(E("Current version")+": "+this.version),new N.Setting(this.contentEl).setName(E("Bug report")).setDesc(E("Click the button to copy debug info and open the issue page")).addButton(t=>{t.setButtonText(E("Copy and go")).onClick(async()=>{await MN(this.plugin),new N.Notice(E("Debug info copied")),setTimeout(()=>{window.open("https://github.com/Quorafind/Obsidian-Thino/issues/new/choose","_blank"),this.close()},100)})}),new N.Setting(this.contentEl).setName(E("Feature request")).setDesc(E("Submit your feature request to the issue page")).addButton(t=>{t.setButtonText(E("Go")).onClick(async()=>{window.open("https://github.com/Quorafind/Obsidian-Thino/issues/new/choose","_blank"),this.close()})})}}function oH(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=oH(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function tn(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=oH(e))&&(r&&(r+=" "),r+=t);return r}function an(e){const t=Object.prototype.toString.call(e);return e instanceof Date||typeof e=="object"&&t==="[object Date]"?new e.constructor(+e):typeof e=="number"||t==="[object Number]"||typeof e=="string"||t==="[object String]"?new Date(e):new Date(NaN)}function An(e,t){return e instanceof Date?new e.constructor(t):new Date(t)}function oD(e,t){const n=an(e);return isNaN(t)?An(e,NaN):(t&&n.setDate(n.getDate()+t),n)}function iH(e,t){const n=an(e);if(isNaN(t))return An(e,NaN);if(!t)return n;const r=n.getDate(),o=An(e,n.getTime());o.setMonth(n.getMonth()+t+1,0);const i=o.getDate();return r>=i?o:(n.setFullYear(o.getFullYear(),o.getMonth(),r),n)}const aH=6048e5,ZQ=864e5,$Q=6e4,qQ=36e5,KQ=1e3;let XQ={};function bh(){return XQ}function Hi(e,t){const n=bh(),r=t?.weekStartsOn??t?.locale?.options?.weekStartsOn??n.weekStartsOn??n.locale?.options?.weekStartsOn??0,o=an(e),i=o.getDay(),a=(i<r?7:0)+i-r;return o.setDate(o.getDate()-a),o.setHours(0,0,0,0),o}function xf(e){return Hi(e,{weekStartsOn:1})}function JQ(e){const t=an(e),n=t.getFullYear(),r=An(e,0);r.setFullYear(n+1,0,4),r.setHours(0,0,0,0);const o=xf(r),i=An(e,0);i.setFullYear(n,0,4),i.setHours(0,0,0,0);const a=xf(i);return t.getTime()>=o.getTime()?n+1:t.getTime()>=a.getTime()?n:n-1}function m0(e){const t=an(e);return t.setHours(0,0,0,0),t}function g0(e){const t=an(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function QQ(e,t){const n=m0(e),r=m0(t),o=+n-g0(n),i=+r-g0(r);return Math.round((o-i)/ZQ)}function eee(e){const t=JQ(e),n=An(e,0);return n.setFullYear(t,0,4),n.setHours(0,0,0,0),xf(n)}function tee(e,t){return iH(e,t*12)}function sH(e,t){const n=an(e),r=an(t),o=a3(n,r),i=Math.abs(QQ(n,r));n.setDate(n.getDate()-o*i);const a=+(a3(n,r)===-o),s=o*(i-a);return s===0?0:s}function a3(e,t){const n=e.getFullYear()-t.getFullYear()||e.getMonth()-t.getMonth()||e.getDate()-t.getDate()||e.getHours()-t.getHours()||e.getMinutes()-t.getMinutes()||e.getSeconds()-t.getSeconds()||e.getMilliseconds()-t.getMilliseconds();return n<0?-1:n>0?1:n}function nee(e){const t=an(e);return t.setHours(23,59,59,999),t}function v0(e){const t=an(e),n=t.getMonth();return t.setFullYear(t.getFullYear(),n+1,0),t.setHours(23,59,59,999),t}function y0(e){const t=an(e);return t.setDate(1),t.setHours(0,0,0,0),t}function b0(e){const t=an(e),n=t.getFullYear();return t.setFullYear(n+1,0,0),t.setHours(23,59,59,999),t}function w0(e){const t=an(e),n=An(e,0);return n.setFullYear(t.getFullYear(),0,1),n.setHours(0,0,0,0),n}function S0(e,t){const n=bh(),r=t?.weekStartsOn??t?.locale?.options?.weekStartsOn??n.weekStartsOn??n.locale?.options?.weekStartsOn??0,o=an(e),i=o.getDay(),a=(i<r?-7:0)+6-(i-r);return o.setDate(o.getDate()+a),o.setHours(23,59,59,999),o}const ree={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},oee=(e,t,n)=>{let r;const o=ree[e];return typeof o=="string"?r=o:t===1?r=o.one:r=o.other.replace("{{count}}",t.toString()),n?.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function Rx(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const iee={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},aee={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},see={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},lee={date:Rx({formats:iee,defaultWidth:"full"}),time:Rx({formats:aee,defaultWidth:"full"}),dateTime:Rx({formats:see,defaultWidth:"full"})},cee={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},uee=(e,t,n,r)=>cee[e];function Mp(e){return(t,n)=>{const r=n?.context?String(n.context):"standalone";let o;if(r==="formatting"&&e.formattingValues){const a=e.defaultFormattingWidth||e.defaultWidth,s=n?.width?String(n.width):a;o=e.formattingValues[s]||e.formattingValues[a]}else{const a=e.defaultWidth,s=n?.width?String(n.width):e.defaultWidth;o=e.values[s]||e.values[a]}const i=e.argumentCallback?e.argumentCallback(t):t;return o[i]}}const dee={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},fee={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},hee={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},pee={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},mee={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},gee={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},vee=(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},yee={ordinalNumber:vee,era:Mp({values:dee,defaultWidth:"wide"}),quarter:Mp({values:fee,defaultWidth:"wide",argumentCallback:e=>e-1}),month:Mp({values:hee,defaultWidth:"wide"}),day:Mp({values:pee,defaultWidth:"wide"}),dayPeriod:Mp({values:mee,defaultWidth:"wide",formattingValues:gee,defaultFormattingWidth:"wide"})};function Dp(e){return(t,n={})=>{const r=n.width,o=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],i=t.match(o);if(!i)return null;const a=i[0],s=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],l=Array.isArray(s)?wee(s,h=>h.test(a)):bee(s,h=>h.test(a));let u;u=e.valueCallback?e.valueCallback(l):l,u=n.valueCallback?n.valueCallback(u):u;const d=t.slice(a.length);return{value:u,rest:d}}}function bee(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function wee(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function See(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const o=r[0],i=t.match(e.parsePattern);if(!i)return null;let a=e.valueCallback?e.valueCallback(i[0]):i[0];a=n.valueCallback?n.valueCallback(a):a;const s=t.slice(o.length);return{value:a,rest:s}}}const Tee=/^(\d+)(th|st|nd|rd)?/i,xee=/\d+/i,Iee={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},kee={any:[/^b/i,/^(a|c)/i]},Eee={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},Cee={any:[/1/i,/2/i,/3/i,/4/i]},Mee={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},Dee={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},Aee={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},Nee={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},Oee={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},Pee={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},jee={ordinalNumber:See({matchPattern:Tee,parsePattern:xee,valueCallback:e=>parseInt(e,10)}),era:Dp({matchPatterns:Iee,defaultMatchWidth:"wide",parsePatterns:kee,defaultParseWidth:"any"}),quarter:Dp({matchPatterns:Eee,defaultMatchWidth:"wide",parsePatterns:Cee,defaultParseWidth:"any",valueCallback:e=>e+1}),month:Dp({matchPatterns:Mee,defaultMatchWidth:"wide",parsePatterns:Dee,defaultParseWidth:"any"}),day:Dp({matchPatterns:Aee,defaultMatchWidth:"wide",parsePatterns:Nee,defaultParseWidth:"any"}),dayPeriod:Dp({matchPatterns:Oee,defaultMatchWidth:"any",parsePatterns:Pee,defaultParseWidth:"any"})},Lee={code:"en-US",formatDistance:oee,formatLong:lee,formatRelative:uee,localize:yee,match:jee,options:{weekStartsOn:0,firstWeekContainsDate:1}};function Ree(e){const t=an(e),n=+xf(t)-+eee(t);return Math.round(n/aH)+1}function lH(e,t){const n=an(e),r=n.getFullYear(),o=bh(),i=t?.firstWeekContainsDate??t?.locale?.options?.firstWeekContainsDate??o.firstWeekContainsDate??o.locale?.options?.firstWeekContainsDate??1,a=An(e,0);a.setFullYear(r+1,0,i),a.setHours(0,0,0,0);const s=Hi(a,t),l=An(e,0);l.setFullYear(r,0,i),l.setHours(0,0,0,0);const u=Hi(l,t);return n.getTime()>=s.getTime()?r+1:n.getTime()>=u.getTime()?r:r-1}function Fee(e,t){const n=bh(),r=t?.firstWeekContainsDate??t?.locale?.options?.firstWeekContainsDate??n.firstWeekContainsDate??n.locale?.options?.firstWeekContainsDate??1,o=lH(e,t),i=An(e,0);return i.setFullYear(o,0,r),i.setHours(0,0,0,0),Hi(i,t)}function Hee(e,t){const n=an(e),r=+Hi(n,t)-+Fee(n,t);return Math.round(r/aH)+1}const s3=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},cH=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},_ee=(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],o=n[2];if(!o)return s3(e,t);let i;switch(r){case"P":i=t.dateTime({width:"short"});break;case"PP":i=t.dateTime({width:"medium"});break;case"PPP":i=t.dateTime({width:"long"});break;case"PPPP":default:i=t.dateTime({width:"full"});break}return i.replace("{{date}}",s3(r,t)).replace("{{time}}",cH(o,t))},l3={p:cH,P:_ee},Bee=/^D+$/,Yee=/^Y+$/,Uee=["D","DD","YY","YYYY"];function zee(e){return Bee.test(e)}function Vee(e){return Yee.test(e)}function c3(e,t,n){const r=Wee(e,t,n);if(console.warn(r),Uee.includes(e))throw new RangeError(r)}function Wee(e,t,n){const r=e[0]==="Y"?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${r} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}function Gee(){return Object.assign({},bh())}function Zee(e){let n=an(e).getDay();return n===0&&(n=7),n}function $ee(e,t){const n=an(e),r=an(t);return n.getTime()>r.getTime()}function qee(e,t){const n=t instanceof Date?An(t,0):new t(0);return n.setFullYear(e.getFullYear(),e.getMonth(),e.getDate()),n.setHours(e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()),n}const Kee=10;class uH{subPriority=0;validate(t,n){return!0}}class Xee extends uH{constructor(t,n,r,o,i){super(),this.value=t,this.validateValue=n,this.setValue=r,this.priority=o,i&&(this.subPriority=i)}validate(t,n){return this.validateValue(t,this.value,n)}set(t,n,r){return this.setValue(t,n,this.value,r)}}class Jee extends uH{priority=Kee;subPriority=-1;set(t,n){return n.timestampIsSet?t:An(t,qee(t,Date))}}class Qt{run(t,n,r,o){const i=this.parse(t,n,r,o);return i?{setter:new Xee(i.value,this.validate,this.set,this.priority,this.subPriority),rest:i.rest}:null}validate(t,n,r){return!0}}class Qee extends Qt{priority=140;parse(t,n,r){switch(n){case"G":case"GG":case"GGG":return r.era(t,{width:"abbreviated"})||r.era(t,{width:"narrow"});case"GGGGG":return r.era(t,{width:"narrow"});case"GGGG":default:return r.era(t,{width:"wide"})||r.era(t,{width:"abbreviated"})||r.era(t,{width:"narrow"})}}set(t,n,r){return n.era=r,t.setFullYear(r,0,1),t.setHours(0,0,0,0),t}incompatibleTokens=["R","u","t","T"]}const Jn={month:/^(1[0-2]|0?\d)/,date:/^(3[0-1]|[0-2]?\d)/,dayOfYear:/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,week:/^(5[0-3]|[0-4]?\d)/,hour23h:/^(2[0-3]|[0-1]?\d)/,hour24h:/^(2[0-4]|[0-1]?\d)/,hour11h:/^(1[0-1]|0?\d)/,hour12h:/^(1[0-2]|0?\d)/,minute:/^[0-5]?\d/,second:/^[0-5]?\d/,singleDigit:/^\d/,twoDigits:/^\d{1,2}/,threeDigits:/^\d{1,3}/,fourDigits:/^\d{1,4}/,anyDigitsSigned:/^-?\d+/,singleDigitSigned:/^-?\d/,twoDigitsSigned:/^-?\d{1,2}/,threeDigitsSigned:/^-?\d{1,3}/,fourDigitsSigned:/^-?\d{1,4}/},as={basicOptionalMinutes:/^([+-])(\d{2})(\d{2})?|Z/,basic:/^([+-])(\d{2})(\d{2})|Z/,basicOptionalSeconds:/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,extended:/^([+-])(\d{2}):(\d{2})|Z/,extendedOptionalSeconds:/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/};function Qn(e,t){return e&&{value:t(e.value),rest:e.rest}}function Hn(e,t){const n=t.match(e);return n?{value:parseInt(n[0],10),rest:t.slice(n[0].length)}:null}function ss(e,t){const n=t.match(e);if(!n)return null;if(n[0]==="Z")return{value:0,rest:t.slice(1)};const r=n[1]==="+"?1:-1,o=n[2]?parseInt(n[2],10):0,i=n[3]?parseInt(n[3],10):0,a=n[5]?parseInt(n[5],10):0;return{value:r*(o*qQ+i*$Q+a*KQ),rest:t.slice(n[0].length)}}function dH(e){return Hn(Jn.anyDigitsSigned,e)}function Gn(e,t){switch(e){case 1:return Hn(Jn.singleDigit,t);case 2:return Hn(Jn.twoDigits,t);case 3:return Hn(Jn.threeDigits,t);case 4:return Hn(Jn.fourDigits,t);default:return Hn(new RegExp("^\\d{1,"+e+"}"),t)}}function T0(e,t){switch(e){case 1:return Hn(Jn.singleDigitSigned,t);case 2:return Hn(Jn.twoDigitsSigned,t);case 3:return Hn(Jn.threeDigitsSigned,t);case 4:return Hn(Jn.fourDigitsSigned,t);default:return Hn(new RegExp("^-?\\d{1,"+e+"}"),t)}}function iD(e){switch(e){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function fH(e,t){const n=t>0,r=n?t:1-t;let o;if(r<=50)o=e||100;else{const i=r+50,a=Math.trunc(i/100)*100,s=e>=i%100;o=e+a-(s?100:0)}return n?o:1-o}function hH(e){return e%400===0||e%4===0&&e%100!==0}class ete extends Qt{priority=130;incompatibleTokens=["Y","R","u","w","I","i","e","c","t","T"];parse(t,n,r){const o=i=>({year:i,isTwoDigitYear:n==="yy"});switch(n){case"y":return Qn(Gn(4,t),o);case"yo":return Qn(r.ordinalNumber(t,{unit:"year"}),o);default:return Qn(Gn(n.length,t),o)}}validate(t,n){return n.isTwoDigitYear||n.year>0}set(t,n,r){const o=t.getFullYear();if(r.isTwoDigitYear){const a=fH(r.year,o);return t.setFullYear(a,0,1),t.setHours(0,0,0,0),t}const i=!("era"in n)||n.era===1?r.year:1-r.year;return t.setFullYear(i,0,1),t.setHours(0,0,0,0),t}}class tte extends Qt{priority=130;parse(t,n,r){const o=i=>({year:i,isTwoDigitYear:n==="YY"});switch(n){case"Y":return Qn(Gn(4,t),o);case"Yo":return Qn(r.ordinalNumber(t,{unit:"year"}),o);default:return Qn(Gn(n.length,t),o)}}validate(t,n){return n.isTwoDigitYear||n.year>0}set(t,n,r,o){const i=lH(t,o);if(r.isTwoDigitYear){const s=fH(r.year,i);return t.setFullYear(s,0,o.firstWeekContainsDate),t.setHours(0,0,0,0),Hi(t,o)}const a=!("era"in n)||n.era===1?r.year:1-r.year;return t.setFullYear(a,0,o.firstWeekContainsDate),t.setHours(0,0,0,0),Hi(t,o)}incompatibleTokens=["y","R","u","Q","q","M","L","I","d","D","i","t","T"]}class nte extends Qt{priority=130;parse(t,n){return T0(n==="R"?4:n.length,t)}set(t,n,r){const o=An(t,0);return o.setFullYear(r,0,4),o.setHours(0,0,0,0),xf(o)}incompatibleTokens=["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]}class rte extends Qt{priority=130;parse(t,n){return T0(n==="u"?4:n.length,t)}set(t,n,r){return t.setFullYear(r,0,1),t.setHours(0,0,0,0),t}incompatibleTokens=["G","y","Y","R","w","I","i","e","c","t","T"]}class ote extends Qt{priority=120;parse(t,n,r){switch(n){case"Q":case"QQ":return Gn(n.length,t);case"Qo":return r.ordinalNumber(t,{unit:"quarter"});case"QQQ":return r.quarter(t,{width:"abbreviated",context:"formatting"})||r.quarter(t,{width:"narrow",context:"formatting"});case"QQQQQ":return r.quarter(t,{width:"narrow",context:"formatting"});case"QQQQ":default:return r.quarter(t,{width:"wide",context:"formatting"})||r.quarter(t,{width:"abbreviated",context:"formatting"})||r.quarter(t,{width:"narrow",context:"formatting"})}}validate(t,n){return n>=1&&n<=4}set(t,n,r){return t.setMonth((r-1)*3,1),t.setHours(0,0,0,0),t}incompatibleTokens=["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]}class ite extends Qt{priority=120;parse(t,n,r){switch(n){case"q":case"qq":return Gn(n.length,t);case"qo":return r.ordinalNumber(t,{unit:"quarter"});case"qqq":return r.quarter(t,{width:"abbreviated",context:"standalone"})||r.quarter(t,{width:"narrow",context:"standalone"});case"qqqqq":return r.quarter(t,{width:"narrow",context:"standalone"});case"qqqq":default:return r.quarter(t,{width:"wide",context:"standalone"})||r.quarter(t,{width:"abbreviated",context:"standalone"})||r.quarter(t,{width:"narrow",context:"standalone"})}}validate(t,n){return n>=1&&n<=4}set(t,n,r){return t.setMonth((r-1)*3,1),t.setHours(0,0,0,0),t}incompatibleTokens=["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]}class ate extends Qt{incompatibleTokens=["Y","R","q","Q","L","w","I","D","i","e","c","t","T"];priority=110;parse(t,n,r){const o=i=>i-1;switch(n){case"M":return Qn(Hn(Jn.month,t),o);case"MM":return Qn(Gn(2,t),o);case"Mo":return Qn(r.ordinalNumber(t,{unit:"month"}),o);case"MMM":return r.month(t,{width:"abbreviated",context:"formatting"})||r.month(t,{width:"narrow",context:"formatting"});case"MMMMM":return r.month(t,{width:"narrow",context:"formatting"});case"MMMM":default:return r.month(t,{width:"wide",context:"formatting"})||r.month(t,{width:"abbreviated",context:"formatting"})||r.month(t,{width:"narrow",context:"formatting"})}}validate(t,n){return n>=0&&n<=11}set(t,n,r){return t.setMonth(r,1),t.setHours(0,0,0,0),t}}class ste extends Qt{priority=110;parse(t,n,r){const o=i=>i-1;switch(n){case"L":return Qn(Hn(Jn.month,t),o);case"LL":return Qn(Gn(2,t),o);case"Lo":return Qn(r.ordinalNumber(t,{unit:"month"}),o);case"LLL":return r.month(t,{width:"abbreviated",context:"standalone"})||r.month(t,{width:"narrow",context:"standalone"});case"LLLLL":return r.month(t,{width:"narrow",context:"standalone"});case"LLLL":default:return r.month(t,{width:"wide",context:"standalone"})||r.month(t,{width:"abbreviated",context:"standalone"})||r.month(t,{width:"narrow",context:"standalone"})}}validate(t,n){return n>=0&&n<=11}set(t,n,r){return t.setMonth(r,1),t.setHours(0,0,0,0),t}incompatibleTokens=["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]}function lte(e,t,n){const r=an(e),o=Hee(r,n)-t;return r.setDate(r.getDate()-o*7),r}class cte extends Qt{priority=100;parse(t,n,r){switch(n){case"w":return Hn(Jn.week,t);case"wo":return r.ordinalNumber(t,{unit:"week"});default:return Gn(n.length,t)}}validate(t,n){return n>=1&&n<=53}set(t,n,r,o){return Hi(lte(t,r,o),o)}incompatibleTokens=["y","R","u","q","Q","M","L","I","d","D","i","t","T"]}function ute(e,t){const n=an(e),r=Ree(n)-t;return n.setDate(n.getDate()-r*7),n}class dte extends Qt{priority=100;parse(t,n,r){switch(n){case"I":return Hn(Jn.week,t);case"Io":return r.ordinalNumber(t,{unit:"week"});default:return Gn(n.length,t)}}validate(t,n){return n>=1&&n<=53}set(t,n,r){return xf(ute(t,r))}incompatibleTokens=["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]}const fte=[31,28,31,30,31,30,31,31,30,31,30,31],hte=[31,29,31,30,31,30,31,31,30,31,30,31];class pte extends Qt{priority=90;subPriority=1;parse(t,n,r){switch(n){case"d":return Hn(Jn.date,t);case"do":return r.ordinalNumber(t,{unit:"date"});default:return Gn(n.length,t)}}validate(t,n){const r=t.getFullYear(),o=hH(r),i=t.getMonth();return o?n>=1&&n<=hte[i]:n>=1&&n<=fte[i]}set(t,n,r){return t.setDate(r),t.setHours(0,0,0,0),t}incompatibleTokens=["Y","R","q","Q","w","I","D","i","e","c","t","T"]}class mte extends Qt{priority=90;subpriority=1;parse(t,n,r){switch(n){case"D":case"DD":return Hn(Jn.dayOfYear,t);case"Do":return r.ordinalNumber(t,{unit:"date"});default:return Gn(n.length,t)}}validate(t,n){const r=t.getFullYear();return hH(r)?n>=1&&n<=366:n>=1&&n<=365}set(t,n,r){return t.setMonth(0,r),t.setHours(0,0,0,0),t}incompatibleTokens=["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]}function aD(e,t,n){const r=bh(),o=n?.weekStartsOn??n?.locale?.options?.weekStartsOn??r.weekStartsOn??r.locale?.options?.weekStartsOn??0,i=an(e),a=i.getDay(),l=(t%7+7)%7,u=7-o,d=t<0||t>6?t-(a+u)%7:(l+u)%7-(a+u)%7;return oD(i,d)}class gte extends Qt{priority=90;parse(t,n,r){switch(n){case"E":case"EE":case"EEE":return r.day(t,{width:"abbreviated",context:"formatting"})||r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"});case"EEEEE":return r.day(t,{width:"narrow",context:"formatting"});case"EEEEEE":return r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"});case"EEEE":default:return r.day(t,{width:"wide",context:"formatting"})||r.day(t,{width:"abbreviated",context:"formatting"})||r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"})}}validate(t,n){return n>=0&&n<=6}set(t,n,r,o){return t=aD(t,r,o),t.setHours(0,0,0,0),t}incompatibleTokens=["D","i","e","c","t","T"]}class vte extends Qt{priority=90;parse(t,n,r,o){const i=a=>{const s=Math.floor((a-1)/7)*7;return(a+o.weekStartsOn+6)%7+s};switch(n){case"e":case"ee":return Qn(Gn(n.length,t),i);case"eo":return Qn(r.ordinalNumber(t,{unit:"day"}),i);case"eee":return r.day(t,{width:"abbreviated",context:"formatting"})||r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"});case"eeeee":return r.day(t,{width:"narrow",context:"formatting"});case"eeeeee":return r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"});case"eeee":default:return r.day(t,{width:"wide",context:"formatting"})||r.day(t,{width:"abbreviated",context:"formatting"})||r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"})}}validate(t,n){return n>=0&&n<=6}set(t,n,r,o){return t=aD(t,r,o),t.setHours(0,0,0,0),t}incompatibleTokens=["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]}class yte extends Qt{priority=90;parse(t,n,r,o){const i=a=>{const s=Math.floor((a-1)/7)*7;return(a+o.weekStartsOn+6)%7+s};switch(n){case"c":case"cc":return Qn(Gn(n.length,t),i);case"co":return Qn(r.ordinalNumber(t,{unit:"day"}),i);case"ccc":return r.day(t,{width:"abbreviated",context:"standalone"})||r.day(t,{width:"short",context:"standalone"})||r.day(t,{width:"narrow",context:"standalone"});case"ccccc":return r.day(t,{width:"narrow",context:"standalone"});case"cccccc":return r.day(t,{width:"short",context:"standalone"})||r.day(t,{width:"narrow",context:"standalone"});case"cccc":default:return r.day(t,{width:"wide",context:"standalone"})||r.day(t,{width:"abbreviated",context:"standalone"})||r.day(t,{width:"short",context:"standalone"})||r.day(t,{width:"narrow",context:"standalone"})}}validate(t,n){return n>=0&&n<=6}set(t,n,r,o){return t=aD(t,r,o),t.setHours(0,0,0,0),t}incompatibleTokens=["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]}function bte(e,t){const n=an(e),r=Zee(n),o=t-r;return oD(n,o)}class wte extends Qt{priority=90;parse(t,n,r){const o=i=>i===0?7:i;switch(n){case"i":case"ii":return Gn(n.length,t);case"io":return r.ordinalNumber(t,{unit:"day"});case"iii":return Qn(r.day(t,{width:"abbreviated",context:"formatting"})||r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"}),o);case"iiiii":return Qn(r.day(t,{width:"narrow",context:"formatting"}),o);case"iiiiii":return Qn(r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"}),o);case"iiii":default:return Qn(r.day(t,{width:"wide",context:"formatting"})||r.day(t,{width:"abbreviated",context:"formatting"})||r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"}),o)}}validate(t,n){return n>=1&&n<=7}set(t,n,r){return t=bte(t,r),t.setHours(0,0,0,0),t}incompatibleTokens=["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]}class Ste extends Qt{priority=80;parse(t,n,r){switch(n){case"a":case"aa":case"aaa":return r.dayPeriod(t,{width:"abbreviated",context:"formatting"})||r.dayPeriod(t,{width:"narrow",context:"formatting"});case"aaaaa":return r.dayPeriod(t,{width:"narrow",context:"formatting"});case"aaaa":default:return r.dayPeriod(t,{width:"wide",context:"formatting"})||r.dayPeriod(t,{width:"abbreviated",context:"formatting"})||r.dayPeriod(t,{width:"narrow",context:"formatting"})}}set(t,n,r){return t.setHours(iD(r),0,0,0),t}incompatibleTokens=["b","B","H","k","t","T"]}class Tte extends Qt{priority=80;parse(t,n,r){switch(n){case"b":case"bb":case"bbb":return r.dayPeriod(t,{width:"abbreviated",context:"formatting"})||r.dayPeriod(t,{width:"narrow",context:"formatting"});case"bbbbb":return r.dayPeriod(t,{width:"narrow",context:"formatting"});case"bbbb":default:return r.dayPeriod(t,{width:"wide",context:"formatting"})||r.dayPeriod(t,{width:"abbreviated",context:"formatting"})||r.dayPeriod(t,{width:"narrow",context:"formatting"})}}set(t,n,r){return t.setHours(iD(r),0,0,0),t}incompatibleTokens=["a","B","H","k","t","T"]}class xte extends Qt{priority=80;parse(t,n,r){switch(n){case"B":case"BB":case"BBB":return r.dayPeriod(t,{width:"abbreviated",context:"formatting"})||r.dayPeriod(t,{width:"narrow",context:"formatting"});case"BBBBB":return r.dayPeriod(t,{width:"narrow",context:"formatting"});case"BBBB":default:return r.dayPeriod(t,{width:"wide",context:"formatting"})||r.dayPeriod(t,{width:"abbreviated",context:"formatting"})||r.dayPeriod(t,{width:"narrow",context:"formatting"})}}set(t,n,r){return t.setHours(iD(r),0,0,0),t}incompatibleTokens=["a","b","t","T"]}class Ite extends Qt{priority=70;parse(t,n,r){switch(n){case"h":return Hn(Jn.hour12h,t);case"ho":return r.ordinalNumber(t,{unit:"hour"});default:return Gn(n.length,t)}}validate(t,n){return n>=1&&n<=12}set(t,n,r){const o=t.getHours()>=12;return o&&r<12?t.setHours(r+12,0,0,0):!o&&r===12?t.setHours(0,0,0,0):t.setHours(r,0,0,0),t}incompatibleTokens=["H","K","k","t","T"]}class kte extends Qt{priority=70;parse(t,n,r){switch(n){case"H":return Hn(Jn.hour23h,t);case"Ho":return r.ordinalNumber(t,{unit:"hour"});default:return Gn(n.length,t)}}validate(t,n){return n>=0&&n<=23}set(t,n,r){return t.setHours(r,0,0,0),t}incompatibleTokens=["a","b","h","K","k","t","T"]}class Ete extends Qt{priority=70;parse(t,n,r){switch(n){case"K":return Hn(Jn.hour11h,t);case"Ko":return r.ordinalNumber(t,{unit:"hour"});default:return Gn(n.length,t)}}validate(t,n){return n>=0&&n<=11}set(t,n,r){return t.getHours()>=12&&r<12?t.setHours(r+12,0,0,0):t.setHours(r,0,0,0),t}incompatibleTokens=["h","H","k","t","T"]}class Cte extends Qt{priority=70;parse(t,n,r){switch(n){case"k":return Hn(Jn.hour24h,t);case"ko":return r.ordinalNumber(t,{unit:"hour"});default:return Gn(n.length,t)}}validate(t,n){return n>=1&&n<=24}set(t,n,r){const o=r<=24?r%24:r;return t.setHours(o,0,0,0),t}incompatibleTokens=["a","b","h","H","K","t","T"]}class Mte extends Qt{priority=60;parse(t,n,r){switch(n){case"m":return Hn(Jn.minute,t);case"mo":return r.ordinalNumber(t,{unit:"minute"});default:return Gn(n.length,t)}}validate(t,n){return n>=0&&n<=59}set(t,n,r){return t.setMinutes(r,0,0),t}incompatibleTokens=["t","T"]}class Dte extends Qt{priority=50;parse(t,n,r){switch(n){case"s":return Hn(Jn.second,t);case"so":return r.ordinalNumber(t,{unit:"second"});default:return Gn(n.length,t)}}validate(t,n){return n>=0&&n<=59}set(t,n,r){return t.setSeconds(r,0),t}incompatibleTokens=["t","T"]}class Ate extends Qt{priority=30;parse(t,n){const r=o=>Math.trunc(o*Math.pow(10,-n.length+3));return Qn(Gn(n.length,t),r)}set(t,n,r){return t.setMilliseconds(r),t}incompatibleTokens=["t","T"]}class Nte extends Qt{priority=10;parse(t,n){switch(n){case"X":return ss(as.basicOptionalMinutes,t);case"XX":return ss(as.basic,t);case"XXXX":return ss(as.basicOptionalSeconds,t);case"XXXXX":return ss(as.extendedOptionalSeconds,t);case"XXX":default:return ss(as.extended,t)}}set(t,n,r){return n.timestampIsSet?t:An(t,t.getTime()-g0(t)-r)}incompatibleTokens=["t","T","x"]}class Ote extends Qt{priority=10;parse(t,n){switch(n){case"x":return ss(as.basicOptionalMinutes,t);case"xx":return ss(as.basic,t);case"xxxx":return ss(as.basicOptionalSeconds,t);case"xxxxx":return ss(as.extendedOptionalSeconds,t);case"xxx":default:return ss(as.extended,t)}}set(t,n,r){return n.timestampIsSet?t:An(t,t.getTime()-g0(t)-r)}incompatibleTokens=["t","T","X"]}class Pte extends Qt{priority=40;parse(t){return dH(t)}set(t,n,r){return[An(t,r*1e3),{timestampIsSet:!0}]}incompatibleTokens="*"}class jte extends Qt{priority=20;parse(t){return dH(t)}set(t,n,r){return[An(t,r),{timestampIsSet:!0}]}incompatibleTokens="*"}const Lte={G:new Qee,y:new ete,Y:new tte,R:new nte,u:new rte,Q:new ote,q:new ite,M:new ate,L:new ste,w:new cte,I:new dte,d:new pte,D:new mte,E:new gte,e:new vte,c:new yte,i:new wte,a:new Ste,b:new Tte,B:new xte,h:new Ite,H:new kte,K:new Ete,k:new Cte,m:new Mte,s:new Dte,S:new Ate,X:new Nte,x:new Ote,t:new Pte,T:new jte},Rte=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Fte=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Hte=/^'([^]*?)'?$/,_te=/''/g,Bte=/\S/,Yte=/[a-zA-Z]/;function nE(e,t,n,r){const o=Gee(),i=r?.locale??o.locale??Lee,a=r?.firstWeekContainsDate??r?.locale?.options?.firstWeekContainsDate??o.firstWeekContainsDate??o.locale?.options?.firstWeekContainsDate??1,s=r?.weekStartsOn??r?.locale?.options?.weekStartsOn??o.weekStartsOn??o.locale?.options?.weekStartsOn??0;if(t==="")return e===""?an(n):An(n,NaN);const l={firstWeekContainsDate:a,weekStartsOn:s,locale:i},u=[new Jee],d=t.match(Fte).map(v=>{const y=v[0];if(y in l3){const S=l3[y];return S(v,i.formatLong)}return v}).join("").match(Rte),h=[];for(let v of d){!r?.useAdditionalWeekYearTokens&&Vee(v)&&c3(v,t,e),!r?.useAdditionalDayOfYearTokens&&zee(v)&&c3(v,t,e);const y=v[0],S=Lte[y];if(S){const{incompatibleTokens:x}=S;if(Array.isArray(x)){const k=h.find(M=>x.includes(M.token)||M.token===y);if(k)throw new RangeError(`The format string mustn't contain \`${k.fullToken}\` and \`${v}\` at the same time`)}else if(S.incompatibleTokens==="*"&&h.length>0)throw new RangeError(`The format string mustn't contain \`${v}\` and any other token at the same time`);h.push({token:y,fullToken:v});const C=S.run(e,v,i.match,l);if(!C)return An(n,NaN);u.push(C.setter),e=C.rest}else{if(y.match(Yte))throw new RangeError("Format string contains an unescaped latin alphabet character `"+y+"`");if(v==="''"?v="'":y==="'"&&(v=Ute(v)),e.indexOf(v)===0)e=e.slice(v.length);else return An(n,NaN)}}if(e.length>0&&Bte.test(e))return An(n,NaN);const p=u.map(v=>v.priority).sort((v,y)=>y-v).filter((v,y,S)=>S.indexOf(v)===y).map(v=>u.filter(y=>y.priority===v).sort((y,S)=>S.subPriority-y.subPriority)).map(v=>v[0]);let m=an(n);if(isNaN(m.getTime()))return An(n,NaN);const b={};for(const v of p){if(!v.validate(m,l))return An(n,NaN);const y=v.set(m,b,l);Array.isArray(y)?(m=y[0],Object.assign(b,y[1])):m=y}return An(n,m)}function Ute(e){return e.match(Hte)[1].replace(_te,"'")}function pH(e,t){const n=+an(e),[r,o]=[+an(t.start),+an(t.end)].sort((i,a)=>i-a);return n>=r&&n<=o}function Fo(e,t){return oD(e,-t)}function mH(e,t){return iH(e,-t)}function gH(e,t){return tee(e,-t)}const zte=(e,t,n)=>{console.warn("This function is deprecated, use ThinoWorkerManager.calculateStatsBanner() instead");const r={memosLength:0,tagsLength:0,createdDays:0,taskAmount:0,mostActiveDay:"",mostActiveHour:"",earliestMemo:null,lengthOverflow:!1};if(r.memosLength=e.filter(i=>!(i.deletedAt!==""&&i.deletedAt)).length,r.tagsLength=t.length,r.earliestMemo=e.length>0?e[e.length-1]:null,r.earliestMemo&&r.earliestMemo.createdAt){const i=nE(r.earliestMemo.createdAt,"yyyy/MM/dd HH:mm:ss",new Date);r.createdDays=sH(new Date,i)+1}const o=e.filter(i=>!i.deletedAt&&i.rowStatus!=="ARCHIVED");return r.taskAmount=o.filter(i=>i.thinoType?.startsWith("TASK")).length,r.mostActiveDay=Vte(e),r.mostActiveHour=Wte(e),r.lengthOverflow=r.memosLength>9999||r.tagsLength>999||r.createdDays>999,n&&yH(n)&&bH({tags:r.tagsLength,memos:r.memosLength,days:r.createdDays},n),r},Vte=e=>{const t={};return e.forEach(n=>{const r=n.createdAt.split(" ")[0];t[r]?t[r]++:t[r]=1}),Object.keys(t).sort((n,r)=>t[r]-t[n])[0]},Wte=e=>{const t={};return e.forEach(n=>{const r=n.createdAt.slice(11,13);t[r]?t[r]++:t[r]=1}),Object.keys(t).sort((n,r)=>t[r]-t[n])[0]};function u3(e,t,n){const r=D.useRef(),o=D.useRef();D.useEffect(()=>{const a=t-e,s=l=>{o.current||(o.current=l);const u=l-o.current;if(u<1e3){const d=u/1e3;n(e+a*d),r.current=requestAnimationFrame(s)}else n(t)};return r.current=requestAnimationFrame(s),()=>{r.current&&cancelAnimationFrame(r.current)}},[t,n,e])}const sD=({statusType:e})=>{const{memoState:{memos:t,tags:n},locationState:{pathname:r},dailyNotesState:{settings:o,app:i,plugin:a}}=D.useContext(ct);if(!de.initialized)return null;const[s,l]=D.useState(0),[u,d]=D.useState(0),[h,p]=D.useState(0),[m,b]=D.useState(null),[v,y]=D.useState(!1),S=Y.useRef(null),[x,C]=D.useState(0),[k,M]=D.useState(0),[I,O]=D.useState(0),[R,L]=D.useState(""),[B,_]=D.useState(""),[H,U]=D.useState(!1),[G,K]=D.useState(null);D.useEffect(()=>{if(e==="banner"||!a.thinoWorkerManager)return;(async()=>{try{const Z=await a.thinoWorkerManager.calculateStatsBanner(t,n);O(Z.taskAmount),L(Z.mostActiveDay),_(Z.mostActiveHour)}catch(Z){console.error("Failed to calculate stats banner:",Z)}})()},[t,n]),D.useLayoutEffect(()=>{if(!i)return;const{tags:ee,memos:Z,days:q}=yH(i);p(ee),l(Z),d(q)},[i]),D.useEffect(()=>{!o||!i||(y(s>9999||h>999||u>999),bH({tags:h,memos:s,days:u},i))},[s,h,u]),D.useEffect(()=>{!de.initialized||!a.thinoWorkerManager||t&&r==="/"&&(async()=>{try{const Z=await a.thinoWorkerManager.calculateStatsBanner(t,n);p(Math.max(Z.tagsLength,n.length)),l(Z.memosLength),b(Z.earliestMemo),y(Z.lengthOverflow),Z.earliestMemo&&Z.createdDays&&d(Z.createdDays)}catch(Z){console.error("Failed to calculate stats banner:",Z);const q=zte(t,n,a.app);p(q.tagsLength),l(q.memosLength),b(q.earliestMemo)}})()},[n,t,r]),D.useEffect(()=>{if(!de.initialized)return;if(!m){d(0);return}if(!S.current||!m?.createdAt)return;N.requireApiVersion("1.4.4")&&N.setTooltip(S.current,E("Started from")+" "+Le.getDateTimeString(m?.createdAt??""));const ee=nE(m.createdAt,"yyyy/MM/dd HH:mm:ss",new Date),Z=sH(new Date,ee)+1;d(t?Z:0)},[m]);const z=(ee,Z)=>{if(H&&Z===G){Ue.setMemoFilter(""),U(!1);return}const q=Ct.createTempQuery(`Filter [Temp] ${Math.random().toString(36).substring(7)}`,JSON.stringify([ee]));Ct.pushQuery(q),Ue.setMemoFilter(q.id),U(!0),K(Z)},ne=()=>{z({type:"LIST",value:{operator:"IS_NOT",value:"LIST"},relation:"AND"},"LIST")},J=()=>{z({type:"TYPE",value:{operator:"IS_NOT",value:"NOT_TAGGED"},relation:"AND"},"TYPE")};return u3(x,s,C),u3(k,u,M),w.jsx("div",{className:tn("status-text-container",v?"text-overflow":"",e),children:e==="banner"?w.jsxs(w.Fragment,{children:[w.jsxs("div",{className:"status-text memos-text",children:[w.jsx("span",{className:"amount-text",children:Math.round(x)}),w.jsx("span",{className:"type-text",children:"THINO"})]}),w.jsxs("div",{className:"status-text tags-text",children:[w.jsx("span",{className:"amount-text",children:h}),w.jsx("span",{className:"type-text",children:E("TAG")})]}),w.jsxs("div",{ref:S,className:"status-text duration-text",onClick:()=>{Ze.setShowSiderbarInMobileView(!1),Ue.setPathname("/daily")},children:[w.jsx("span",{className:"amount-text",children:Math.round(k)??0}),w.jsx("span",{className:"type-text",children:E("DAY")})]})]}):w.jsxs(w.Fragment,{children:[w.jsx("div",{className:"status-sidebar-header title-text",children:w.jsx("span",{className:"normal-text",children:E("Thino status")})}),w.jsxs("div",{className:"status-sidebar-wrapper",children:[w.jsxs("div",{className:"status-text memos-text",children:[w.jsx("span",{className:"type-text",children:E("Thino amount")}),w.jsx("span",{className:"amount-text",children:Math.round(x)})]}),w.jsxs("div",{className:"status-text memos-text",onClick:ne,children:[w.jsx("span",{className:"type-text",children:E("Task amount")}),w.jsx("span",{className:"amount-text",children:Math.round(I)??0})]}),w.jsxs("div",{className:"status-text tags-text",onClick:J,children:[w.jsx("span",{className:"type-text",children:E("Used tags")}),w.jsx("span",{className:"amount-text",children:h})]}),w.jsxs("div",{ref:S,className:"status-text duration-text",onClick:()=>{Ze.setShowSiderbarInMobileView(!1),Ue.setPathname("/daily")},children:[w.jsx("span",{className:"type-text",children:E("Used days")}),w.jsx("span",{className:"amount-text",children:Math.round(k)??0})]}),w.jsxs("div",{className:"status-text most-active-day-text",onClick:()=>{const ee=nE(R,"yyyy/MM/dd",new Date),Z=m0(ee).getTime(),q=nee(ee).getTime();Ue.setFromAndToQuery(Z,q)},children:[w.jsx("span",{className:"type-text",children:E("Most active day")}),w.jsx("span",{className:"amount-text",children:R})]}),w.jsxs("div",{className:"status-text most-active-hour-text",children:[w.jsx("span",{className:"type-text",children:E("Most active hour")}),w.jsx("span",{className:"amount-text",children:B})]})]})]})})};function vH(e){return`userBannerCache:${e}`}function yH(e){try{const t=vH(e?.appId),n=ur.get([t])[t];return n?JSON.parse(n):{tags:0,memos:0,days:0}}catch(t){return console.error(t),{tags:0,memos:0,days:0}}}function bH({tags:e,memos:t,days:n},r){try{const o={tags:e,memos:t,days:n},i=vH(r?.appId);ur.set({[i]:JSON.stringify(o)})}catch(o){console.error(o)}}const wH="KGZ1bmN0aW9uKCl7InVzZSBzdHJpY3QiO2Z1bmN0aW9uIEQoZSl7Y29uc3QgdD1PYmplY3QucHJvdG90eXBlLnRvU3RyaW5nLmNhbGwoZSk7cmV0dXJuIGUgaW5zdGFuY2VvZiBEYXRlfHx0eXBlb2YgZT09Im9iamVjdCImJnQ9PT0iW29iamVjdCBEYXRlXSI/bmV3IGUuY29uc3RydWN0b3IoK2UpOnR5cGVvZiBlPT0ibnVtYmVyInx8dD09PSJbb2JqZWN0IE51bWJlcl0ifHx0eXBlb2YgZT09InN0cmluZyJ8fHQ9PT0iW29iamVjdCBTdHJpbmddIj9uZXcgRGF0ZShlKTpuZXcgRGF0ZShOYU4pfWZ1bmN0aW9uIE4oZSx0KXtyZXR1cm4gZSBpbnN0YW5jZW9mIERhdGU/bmV3IGUuY29uc3RydWN0b3IodCk6bmV3IERhdGUodCl9ZnVuY3Rpb24gVShlLHQpe2NvbnN0IG49RChlKTtyZXR1cm4gaXNOYU4odCk/TihlLE5hTik6KHQmJm4uc2V0RGF0ZShuLmdldERhdGUoKSt0KSxuKX1mdW5jdGlvbiBNKGUsdCl7Y29uc3Qgbj1EKGUpO2lmKGlzTmFOKHQpKXJldHVybiBOKGUsTmFOKTtpZighdClyZXR1cm4gbjtjb25zdCBzPW4uZ2V0RGF0ZSgpLGk9TihlLG4uZ2V0VGltZSgpKTtpLnNldE1vbnRoKG4uZ2V0TW9udGgoKSt0KzEsMCk7Y29uc3Qgbz1pLmdldERhdGUoKTtyZXR1cm4gcz49bz9pOihuLnNldEZ1bGxZZWFyKGkuZ2V0RnVsbFllYXIoKSxpLmdldE1vbnRoKCkscyksbil9bGV0IFc9e307ZnVuY3Rpb24gRigpe3JldHVybiBXfWZ1bmN0aW9uIEwoZSx0KXtjb25zdCBuPUYoKSxzPXQ/LndlZWtTdGFydHNPbj8/dD8ubG9jYWxlPy5vcHRpb25zPy53ZWVrU3RhcnRzT24/P24ud2Vla1N0YXJ0c09uPz9uLmxvY2FsZT8ub3B0aW9ucz8ud2Vla1N0YXJ0c09uPz8wLGk9RChlKSxvPWkuZ2V0RGF5KCksYT0obzxzPzc6MCkrby1zO3JldHVybiBpLnNldERhdGUoaS5nZXREYXRlKCktYSksaS5zZXRIb3VycygwLDAsMCwwKSxpfWZ1bmN0aW9uIFYoZSx0KXtyZXR1cm4gTShlLHQqMTIpfWZ1bmN0aW9uIHYoZSl7Y29uc3QgdD1EKGUpLG49dC5nZXRNb250aCgpO3JldHVybiB0LnNldEZ1bGxZZWFyKHQuZ2V0RnVsbFllYXIoKSxuKzEsMCksdC5zZXRIb3VycygyMyw1OSw1OSw5OTkpLHR9ZnVuY3Rpb24gJChlKXtjb25zdCB0PUQoZSk7cmV0dXJuIHQuc2V0RGF0ZSgxKSx0LnNldEhvdXJzKDAsMCwwLDApLHR9ZnVuY3Rpb24gaihlKXtjb25zdCB0PUQoZSksbj10LmdldEZ1bGxZZWFyKCk7cmV0dXJuIHQuc2V0RnVsbFllYXIobisxLDAsMCksdC5zZXRIb3VycygyMyw1OSw1OSw5OTkpLHR9ZnVuY3Rpb24gSChlKXtjb25zdCB0PUQoZSksbj1OKGUsMCk7cmV0dXJuIG4uc2V0RnVsbFllYXIodC5nZXRGdWxsWWVhcigpLDAsMSksbi5zZXRIb3VycygwLDAsMCwwKSxufWZ1bmN0aW9uIFkoZSx0KXtjb25zdCBuPUYoKSxzPXQ/LndlZWtTdGFydHNPbj8/dD8ubG9jYWxlPy5vcHRpb25zPy53ZWVrU3RhcnRzT24/P24ud2Vla1N0YXJ0c09uPz9uLmxvY2FsZT8ub3B0aW9ucz8ud2Vla1N0YXJ0c09uPz8wLGk9RChlKSxvPWkuZ2V0RGF5KCksYT0obzxzPy03OjApKzYtKG8tcyk7cmV0dXJuIGkuc2V0RGF0ZShpLmdldERhdGUoKSthKSxpLnNldEhvdXJzKDIzLDU5LDU5LDk5OSksaX1mdW5jdGlvbiBQKGUsdCl7Y29uc3Qgbj0rRChlKSxbcyxpXT1bK0QodC5zdGFydCksK0QodC5lbmQpXS5zb3J0KChvLGEpPT5vLWEpO3JldHVybiBuPj1zJiZuPD1pfWZ1bmN0aW9uIE8oZSx0KXtyZXR1cm4gVShlLC10KX1mdW5jdGlvbiBxKGUsdCl7cmV0dXJuIE0oZSwtdCl9ZnVuY3Rpb24gSihlLHQpe3JldHVybiBWKGUsLXQpfWZ1bmN0aW9uIF8oZSl7cmV0dXJuWy8jKFteXHMjXSspL2csL1xuIyhbXlxzI10rKS9nLC9eIyhbXlxzI10rKS9nXS5yZWR1Y2UoKGksbyk9PigoZS5tYXRjaChvKXx8W10pLmZvckVhY2goYT0+e2NvbnN0IGM9YS5yZXBsYWNlKG8sIiQxIikudHJpbSgpLnNwbGl0KCIvIik7bGV0IGw9IiI7Yy5mb3JFYWNoKGc9PntsKz1nLGkuYWRkKGwpLGwrPSIvIn0pfSksaSksbmV3IFNldCl9ZnVuY3Rpb24gQihlKXtpZighQXJyYXkuaXNBcnJheShlKXx8ZS5sZW5ndGg9PT0wKXJldHVybiBuZXcgU2V0O2NvbnN0IHQ9ZS5maWx0ZXIocz0+ISFzKS5tYXAocz0+cy50b1N0cmluZygpLnRyaW0oKSk7aWYodC5sZW5ndGg9PT0wKXJldHVybiBuZXcgU2V0O2NvbnN0IG49bmV3IFNldDtyZXR1cm4gdC5mb3JFYWNoKHM9Pntjb25zdCBpPXMuc3BsaXQoIi8iKTtsZXQgbz0iIjtpLmZvckVhY2goKGEscik9PntvKz0ocj4wPyIvIjoiIikrYSxuLmFkZChvKX0pfSksbn1mdW5jdGlvbiBYKGUpe2NvbnN0IHQ9ZS50b0xvd2VyQ2FzZSgpO3JldHVybiBuPT5uLmluY2x1ZGVzKHQpfWZ1bmN0aW9uIHooZSx0LG4pe2NvbnN0e29ubHlGaWx0ZXJUeXBlOnMsZmlsdGVyQXJjaGl2ZWQ6aT0hMCxmaWx0ZXJEZWxldGVkOm89ITAsZmlsdGVyRG9uZVRhc2tzOmE9ITEsZmlsdGVyQ29tbWVudHM6cj0hMCxmaWx0ZXJUYWdzSW5GaWxlOmM9ITF9PW58fHt9LGw9LyMoW15ccyNdKykvZyxnPS9eIyhbXlxzI10rKS9nLHA9L1xuIyhbXlxzI10rKS9nLEU9L1xbKC4rPylcXVwoKC4rPylcKS9nLG09LyFcWyguKz8pXF1cKCguKz8pXCkvZyxoPS9cW1xbKC4rPylcXVxdL2c7bGV0IFM9ZTtpZihzJiZzIT09ImFsbCIpc3dpdGNoKHMpe2Nhc2UiYXJjaGl2ZWQiOlM9ZS5maWx0ZXIodT0+dS5yb3dTdGF0dXM9PT0iQVJDSElWRUQiJiYhdS5kZWxldGVkQXQpO2JyZWFrO2Nhc2UiZGVsZXRlZCI6Uz1lLmZpbHRlcih1PT51LmRlbGV0ZWRBdCE9PSIiJiZ1LmRlbGV0ZWRBdCk7YnJlYWs7Y2FzZSJkb25lVGFza3MiOlM9ZS5maWx0ZXIodT0+dS50aGlub1R5cGU9PT0iVEFTSy1ET05FIik7YnJlYWs7Y2FzZSJjb21tZW50cyI6Uz1lLmZpbHRlcih1PT51LmNvbnRlbnQuaW5jbHVkZXMoImNvbW1lbnQ6IikpO2JyZWFrfWVsc2UgUz1lLmZpbHRlcih1PT4hKGkmJnUucm93U3RhdHVzPT09IkFSQ0hJVkVEInx8byYmdS5kZWxldGVkQXR8fHImJnUuY29udGVudC5pbmNsdWRlcygiY29tbWVudDoiKXx8YSYmdS50aGlub1R5cGU9PT0iVEFTSy1ET05FIikpO2lmKFEodCkpcmV0dXJuIFM7Y29uc3R7dGFnOnksZHVyYXRpb246Zix0eXBlOmQsdGV4dDpULGZpbHRlcjp3LHBhdGg6YixtZXRhZGF0YTpJfT10LEM9VD8udG9Mb3dlckNhc2UoKXx8IiIsb3Q9IUl8fE9iamVjdC5rZXlzKEkpLmxlbmd0aD09PTAsRz1DP1goQyk6bnVsbDtyZXR1cm4gUy5maWx0ZXIodT0+e2lmKHcpdHJ5e2NvbnN0IEE9dC5maWx0ZXJDb250ZW50O2lmKEFycmF5LmlzQXJyYXkoQSkmJiF0dCh1LEEpKXJldHVybiExfWNhdGNoKEEpe2NvbnNvbGUuZXJyb3IoIkZhaWxlZCB0byBwYXJzZSBxdWVyeSBmaWx0ZXJzOiIsQSl9aWYoIW90JiZPYmplY3Qua2V5cyhJKS5zb21lKGs9PnUuZmlsZUluZm8/LmZyb250bWF0dGVyW2tdIT09SVtrXSl8fGImJnUucGF0aCYmIXUucGF0aC50b0xvd2VyQ2FzZSgpLmluY2x1ZGVzKGIudG9Mb3dlckNhc2UoKSkpcmV0dXJuITE7aWYoRyl7Y29uc3QgQT1HKHUuY29udGVudC50b0xvd2VyQ2FzZSgpKSxrPXUucGF0aD91LnBhdGgudG9Mb3dlckNhc2UoKS5pbmNsdWRlcyhDKTohMTtpZih1LnRoaW5vVHlwZT09PSJNVUxUSSImJnUucGF0aCl7aWYoIUEmJiFrKXJldHVybiExfWVsc2UgaWYoIUEpcmV0dXJuITF9aWYoeSl7Y29uc3QgQT1fKHUuY29udGVudCksaz1jP0IodS5maWxlSW5mbz8udGFnc3x8W10pOm5ldyBTZXQ7aWYoIUEuaGFzKHkpJiYhay5oYXMoeSkpcmV0dXJuITF9aWYoZiYmZi5mcm9tIT09MCYmZi50byE9PTApe2NvbnN0IEE9Wih1LmNyZWF0ZWRBdCk7aWYoQTxmLmZyb218fEE+Zi50bylyZXR1cm4hMX1pZihkKXN3aXRjaChkKXtjYXNlIk5PVF9UQUdHRUQiOmlmKHUuY29udGVudC5tYXRjaChsKXx8dS5jb250ZW50Lm1hdGNoKGcpfHx1LmNvbnRlbnQubWF0Y2gocCkpcmV0dXJuITE7YnJlYWs7Y2FzZSJMSU5LRUQiOmlmKCF1LmNvbnRlbnQubWF0Y2goRSkpcmV0dXJuITE7YnJlYWs7Y2FzZSJJTUFHRUQiOmlmKCF1LmNvbnRlbnQubWF0Y2gobSkpcmV0dXJuITE7YnJlYWs7Y2FzZSJDT05ORUNURUQiOmlmKCF1LmNvbnRlbnQubWF0Y2goaCkpcmV0dXJuITE7YnJlYWt9cmV0dXJuITB9KX1mdW5jdGlvbiBRKGUpe2lmKCFlKXJldHVybiEwO2NvbnN0e3RhZzp0LGR1cmF0aW9uOm4sdHlwZTpzLHRleHQ6aSxmaWx0ZXI6byxwYXRoOmEsbWV0YWRhdGE6cn09ZSxjPSFyfHxPYmplY3Qua2V5cyhyKS5sZW5ndGg9PT0wO3JldHVybiEodHx8biYmbi5mcm9tPG4udG98fHN8fGl8fG98fGF8fCFjKX1mdW5jdGlvbiBaKGUpe3JldHVybiBuZXcgRGF0ZShlKS5nZXRUaW1lKCl9ZnVuY3Rpb24gdHQoZSx0KXtyZXR1cm4hQXJyYXkuaXNBcnJheSh0KXx8dC5sZW5ndGg9PT0wPyEwOnQuZXZlcnkobj0+e2lmKCFufHx0eXBlb2YgbiE9Im9iamVjdCJ8fCFuLnR5cGV8fCFuLnZhbHVlfHx0eXBlb2Ygbi52YWx1ZSE9Im9iamVjdCIpcmV0dXJuITA7Y29uc3R7dHlwZTpzLHZhbHVlOml9PW4sbz1pLm9wZXJhdG9yLGE9aS52YWx1ZTtzd2l0Y2gocyl7Y2FzZSJUQUciOntjb25zdCByPXR5cGVvZiBhPT0ic3RyaW5nIj9hOiIiLGM9ZS5jb250ZW50LmluY2x1ZGVzKGAjJHtyfWApO3JldHVybiBvPT09IkNPTlRBSU4iP2M6IWN9Y2FzZSJURVhUIjp7Y29uc3Qgcj10eXBlb2YgYT09InN0cmluZyI/YS50b0xvd2VyQ2FzZSgpOiIiLGM9ZS5jb250ZW50LnRvTG93ZXJDYXNlKCkuaW5jbHVkZXMocik7cmV0dXJuIG89PT0iQ09OVEFJTiI/YzohY31jYXNlIlRZUEUiOnJldHVybiBvPT09IklTIj9lLnRoaW5vVHlwZT09PWE6ZS50aGlub1R5cGUhPT1hO2Nhc2UiREFURSI6e2NvbnN0IHI9dHlwZW9mIGE9PSJzdHJpbmciP25ldyBEYXRlKGEpOnR5cGVvZiBhPT0ib2JqZWN0IiYmYSE9PW51bGwmJiJ2YWx1ZSJpbiBhP25ldyBEYXRlKGEudmFsdWUpOm51bGw7aWYoIXIpcmV0dXJuITA7Y29uc3QgYz1uZXcgRGF0ZShlLmNyZWF0ZWRBdCk7cmV0dXJuIG89PT0iQ09OVEFJTiI/Yz49cjpjPHJ9Y2FzZSJMSVNUIjpzd2l0Y2goYSl7Y2FzZSJUT0RPIjp7Y29uc3Qgcj1lLnRoaW5vVHlwZT09PSJUQVNLLVRPRE8iO3JldHVybiBvPT09IklTIj9yOiFyfWNhc2UiRE9ORSI6e2NvbnN0IHI9ZS50aGlub1R5cGU9PT0iVEFTSy1ET05FIjtyZXR1cm4gbz09PSJJUyI/cjohcn1jYXNlIkxJU1QiOntjb25zdCByPWUudGhpbm9UeXBlPT09IkpPVVJOQUwiO3JldHVybiBvPT09IklTIj9yOiFyfWNhc2UiT1RIRVIiOntjb25zdCByPSFbIlRBU0stVE9ETyIsIlRBU0stRE9ORSIsIkpPVVJOQUwiXS5pbmNsdWRlcyhlLnRoaW5vVHlwZSk7cmV0dXJuIG89PT0iSVMiP3I6IXJ9ZGVmYXVsdDpyZXR1cm4hMH1jYXNlIlNPVVJDRSI6cmV0dXJuIG89PT0iSVMiP2UudGhpbm9UeXBlPT09YTplLnRoaW5vVHlwZSE9PWE7Y2FzZSJQQVRIIjp7aWYoIWUucGF0aClyZXR1cm4gbyE9PSJDT05UQUlOIjtjb25zdCByPXR5cGVvZiBhPT0ic3RyaW5nIj9hLnRvTG93ZXJDYXNlKCk6IiIsYz1lLnBhdGgudG9Mb3dlckNhc2UoKS5pbmNsdWRlcyhyKTtyZXR1cm4gbz09PSJDT05UQUlOIj9jOiFjfWNhc2UiTUVUQURBVEEiOntpZighZS5maWxlSW5mbz8uZnJvbnRtYXR0ZXIpcmV0dXJuIG8hPT0iQ09OVEFJTiI7Y29uc3Qgcj10eXBlb2YgYT09Im9iamVjdCImJmEhPT1udWxsP2E6e25hbWU6IiIsdmFsdWU6IiJ9LGM9Im5hbWUiaW4gcj9yLm5hbWU6IiIsbD0idmFsdWUiaW4gcj9yLnZhbHVlOiIiO2lmKCFjKXJldHVybiEwO2NvbnN0IGc9ZS5maWxlSW5mby5mcm9udG1hdHRlcltjXT09PWw7cmV0dXJuIG89PT0iQ09OVEFJTiI/ZzohZ31jYXNlIlRJTUVfUkFOR0UiOntjb25zdCByPW5ldyBEYXRlO2xldCBjLGw9cjtpZih0eXBlb2YgYSE9InN0cmluZyIpcmV0dXJuITA7c3dpdGNoKGEpe2Nhc2UiN2QiOmM9TyhyLDcpO2JyZWFrO2Nhc2UiMTRkIjpjPU8ociwxNCk7YnJlYWs7Y2FzZSIzMGQiOmM9TyhyLDMwKTticmVhaztjYXNlIjkwZCI6Yz1PKHIsOTApO2JyZWFrO2Nhc2UiMTgwZCI6Yz1PKHIsMTgwKTticmVhaztjYXNlIjM2NWQiOmM9TyhyLDM2NSk7YnJlYWs7Y2FzZSJ0aGlzV2VlayI6Yz1MKHIpLGw9WShyKTticmVhaztjYXNlInRoaXNNb250aCI6Yz0kKHIpLGw9dihyKTticmVhaztjYXNlInRoaXNZZWFyIjpjPUgociksbD1qKHIpO2JyZWFrO2Nhc2UibGFzdFdlZWsiOntjb25zdCBwPU8ociw3KTtjPUwocCksbD1ZKHApO2JyZWFrfWNhc2UibGFzdE1vbnRoIjp7Y29uc3QgcD1xKHIsMSk7Yz0kKHApLGw9dihwKTticmVha31jYXNlImxhc3RZZWFyIjp7Y29uc3QgcD1KKHIsMSk7Yz1IKHApLGw9aihwKTticmVha31kZWZhdWx0OnJldHVybiEwfWNvbnN0IGc9bmV3IERhdGUoZS5jcmVhdGVkQXQpO3JldHVybiBvPT09IldJVEhJTiI/UChnLHtzdGFydDpjLGVuZDpsfSk6bz09PSJCRUZPUkUiP2c8YzohMH1kZWZhdWx0OnJldHVybiEwfX0pfWNvbnN0IGV0PWU9Pntjb25zdCB0PXt9O3JldHVybiBlLmZvckVhY2gobj0+e2NvbnN0IHM9bi5jcmVhdGVkQXQuc3BsaXQoIiAiKVswXTt0W3NdP3Rbc10rKzp0W3NdPTF9KSxPYmplY3Qua2V5cyh0KS5zb3J0KChuLHMpPT50W3NdLXRbbl0pWzBdfHwiIn0sbnQ9ZT0+e2NvbnN0IHQ9e307cmV0dXJuIGUuZm9yRWFjaChuPT57Y29uc3Qgcz1uLmNyZWF0ZWRBdC5zbGljZSgxMSwxMyk7dFtzXT90W3NdKys6dFtzXT0xfSksT2JqZWN0LmtleXModCkuc29ydCgobixzKT0+dFtzXS10W25dKVswXXx8IiJ9LHJ0PShlLHQpPT57Y29uc3Qgcz1NYXRoLmFicyh0LmdldFRpbWUoKS1lLmdldFRpbWUoKSk7cmV0dXJuIE1hdGgucm91bmQocy84NjRlNSkrMX0seD0vXHMjKFteXHUyMDAwLVx1MjA2Rlx1MkUwMC1cdTJFN0YnISIjJCUmKCkqKywuOjs8PT4/QF5ge3x9flxbXF1cXFxzXSspL2csUj0vKDxwPnw8YnI+KSMoW15cdTIwMDAtXHUyMDZGXHUyRTAwLVx1MkU3RichIiMkJSYoKSorLC46Ozw9Pj9AXmB7fH1+XFtcXVxcXHNdKykvZyxLPS9eIyhbXlx1MjAwMC1cdTIwNkZcdTJFMDAtXHUyRTdGJyEiIyQlJigpKissLjo7PD0+P0BeYHt8fX5cW1xdXFxcc10rKS9ndTtmdW5jdGlvbiBzdChlLHQpe2NvbnN0IG49bmV3IFNldCxzPXt9LGk9bmV3IE1hcDtmb3IoY29uc3QgbyBvZiBlKXtpZihvLmRlbGV0ZWRBdCE9PSIiJiZvLmRlbGV0ZWRBdHx8by5yb3dTdGF0dXM9PT0iQVJDSElWRUQiKWNvbnRpbnVlO2NvbnN0IGE9W107aWYoIWkuaGFzKG8ucGF0aCkmJm8uc291cmNlVHlwZSE9PSJGSUxFIil7Y29uc3QgbD10LmZpbHRlclRhZ3NJbkZpbGU/QXJyYXkuaXNBcnJheShvPy5maWxlSW5mbz8udGFncyk/by5maWxlSW5mby50YWdzOltdOltdLGc9dC5maWx0ZXJUYWdzSW5GaWxlP2w6bC5maWx0ZXIocD0+cCkubWFwKHA9PnAudG9TdHJpbmcoKS50cmltKCkpO2kuc2V0KG8ucGF0aCxnKSxhLnB1c2goLi4uZyl9Y29uc3Qgcj1vLmNvbnRlbnQucmVwbGFjZSgvPFtePl0qPi9nLCIiKS5yZXBsYWNlKC9cYFxgXGAoLiopP1xuW1xzXFNdKj9cblxgXGBcYC9nbSwiIikucmVwbGFjZSgvXGAoW15cYF0uKj8pXGAvZywiIiksYz1bLi4uQXJyYXkuZnJvbShyLm1hdGNoKHgpfHxbXSksLi4uQXJyYXkuZnJvbShyLm1hdGNoKEspfHxbXSksLi4uQXJyYXkuZnJvbShyLm1hdGNoKFIpfHxbXSldO2EucHVzaCguLi5jKTtmb3IoY29uc3QgbCBvZiBhKXtpZighbHx8bD09PSJ1bmRlZmluZWQifHwhbCljb250aW51ZTtsZXQgZz1sO3R5cGVvZiBsIT0ic3RyaW5nIiYmKGc9bD8udG9TdHJpbmcoKSk7Y29uc3QgcD1nPy5yZXBsYWNlKHgsIiQxIik/LnJlcGxhY2UoSywiJDEiKT8ucmVwbGFjZShSLCIkMiIpPy50cmltKCk7L15cZCskLy50ZXN0KHApfHwobi5hZGQocCksc1twXT0oc1twXXx8MCkrMSl9fXJldHVybnt0YWdzU2V0Om4sY291bnRzOnN9fXNlbGYuYWRkRXZlbnRMaXN0ZW5lcigibWVzc2FnZSIsZT0+e1Byb21pc2UucmVzb2x2ZSgpLnRoZW4oYXN5bmMoKT0+e3RyeXtjb25zdHt0eXBlOnQsZGF0YTpufT1lLmRhdGE7aWYodD09PSJmaWx0ZXItbWVtb3MiKXtjb25zdHttZW1vczpzLHF1ZXJ5OmksZmlsdGVyT3B0aW9uczpvfT1uLGE9eihzLGksbyk7cG9zdE1lc3NhZ2Uoe3R5cGU6ImZpbHRlci1yZXN1bHQiLGRhdGE6YX0pfWVsc2UgaWYodD09PSJidWlsZC10YWctdHJlZSIpe2NvbnN0e21lbW9zOnMsZmlsdGVyT3B0aW9uczppfT1uLHt0YWdzU2V0Om8sY291bnRzOmF9PXN0KHMsaSk7cG9zdE1lc3NhZ2Uoe3R5cGU6ImJ1aWxkLXRhZy10cmVlLXJlc3VsdCIsZGF0YTp7dGFnc1NldDpvLGNvdW50czphfX0pfWVsc2UgaWYodD09PSJjYWxjdWxhdGUtc3RhdHMtYmFubmVyIil7Y29uc3R7bWVtb3M6cyx0YWdzOml9PW4sbz1zLmZpbHRlcihoPT4hKGguZGVsZXRlZEF0IT09IiImJmguZGVsZXRlZEF0KSkubGVuZ3RoLGE9aS5sZW5ndGgscj1zLmxlbmd0aD4wP3Nbcy5sZW5ndGgtMV06bnVsbDtsZXQgYz0wO2lmKHImJnIuY3JlYXRlZEF0KXtjb25zdCBoPXIuY3JlYXRlZEF0LnNwbGl0KCIgIilbMF0uc3BsaXQoIi8iKSxTPW5ldyBEYXRlKHBhcnNlSW50KGhbMF0pLHBhcnNlSW50KGhbMV0pLTEscGFyc2VJbnQoaFsyXSkpO2M9cnQoUyxuZXcgRGF0ZSl9Y29uc3QgZz1zLmZpbHRlcihoPT4haC5kZWxldGVkQXQmJmgucm93U3RhdHVzIT09IkFSQ0hJVkVEIikuZmlsdGVyKGg9PmgudGhpbm9UeXBlPy5zdGFydHNXaXRoKCJUQVNLIikpLmxlbmd0aCxwPWV0KHMpLEU9bnQocyksbT1vPjk5OTl8fGE+OTk5fHxjPjk5OTtwb3N0TWVzc2FnZSh7dHlwZToic3RhdHMtYmFubmVyLXJlc3VsdCIsZGF0YTp7bWVtb3NMZW5ndGg6byx0YWdzTGVuZ3RoOmEsY3JlYXRlZERheXM6Yyx0YXNrQW1vdW50OmcsbW9zdEFjdGl2ZURheTpwLG1vc3RBY3RpdmVIb3VyOkUsZWFybGllc3RNZW1vOnIsbGVuZ3RoT3ZlcmZsb3c6bX19KX1lbHNlIGlmKHQ9PT0iY2FsY3VsYXRlLXN0YXRzIil7Y29uc3R7bWVtb3M6c309bixpPW5ldyBEYXRlLG89bmV3IERhdGUoaSksYT1bLi4uQXJyYXkoMzApXS5tYXAoKHksZik9Pntjb25zdCBkPW5ldyBEYXRlKG8pO2Quc2V0RGF0ZShvLmdldERhdGUoKS0oMjktZikpO2NvbnN0IFQ9ZC50b0lTT1N0cmluZygpLnNwbGl0KCJUIilbMF0ucmVwbGFjZSgvLS9nLCIvIiksdz1zLmZpbHRlcihiPT5iLmNyZWF0ZWRBdC5zcGxpdCgiICIpWzBdPT09VCkubGVuZ3RoO3JldHVybntkYXRlOmAkeyhkLmdldE1vbnRoKCkrMSkudG9TdHJpbmcoKS5wYWRTdGFydCgyLCIwIil9LyR7ZC5nZXREYXRlKCkudG9TdHJpbmcoKS5wYWRTdGFydCgyLCIwIil9YCxjb3VudDp3fX0pLHI9aS5nZXRNb250aCgpLGM9aS5nZXRGdWxsWWVhcigpLGw9bmV3IERhdGUoYyxyKzEsMCkuZ2V0RGF0ZSgpLGc9Wy4uLkFycmF5KGwpXS5tYXAoKHksZik9Pntjb25zdCBkPW5ldyBEYXRlKGMscixmKzEpLFQ9ZC50b0lTT1N0cmluZygpLnNwbGl0KCJUIilbMF0ucmVwbGFjZSgvLS9nLCIvIiksdz1zLmZpbHRlcihiPT5iLmNyZWF0ZWRBdC5zcGxpdCgiICIpWzBdPT09VCkubGVuZ3RoO3JldHVybntkYXRlOmAkeyhkLmdldE1vbnRoKCkrMSkudG9TdHJpbmcoKS5wYWRTdGFydCgyLCIwIil9LyR7ZC5nZXREYXRlKCkudG9TdHJpbmcoKS5wYWRTdGFydCgyLCIwIil9YCxjb3VudDp3fX0pLHA9Wy4uLkFycmF5KDEyKV0ubWFwKCh5LGYpPT57Y29uc3QgZD1uZXcgRGF0ZShjLGYsMSksVD1kLnRvSVNPU3RyaW5nKCkuc2xpY2UoMCw3KS5yZXBsYWNlKC8tL2csIi8iKSx3PXMuZmlsdGVyKGI9PmIuY3JlYXRlZEF0LnNsaWNlKDAsNyk9PT1UKS5sZW5ndGg7cmV0dXJue2RhdGU6YCR7KGQuZ2V0TW9udGgoKSsxKS50b1N0cmluZygpLnBhZFN0YXJ0KDIsIjAiKX1gLGNvdW50Ond9fSksRT1bLi4uQXJyYXkoMjQpXS5tYXAoKHksZik9Pntjb25zdCBkPXMuZmlsdGVyKFQ9PnBhcnNlSW50KFQuY3JlYXRlZEF0LnNwbGl0KCIgIilbMV0uc3BsaXQoIjoiKVswXSk9PT1mKS5sZW5ndGg7cmV0dXJue2hvdXI6YCR7Zi50b1N0cmluZygpLnBhZFN0YXJ0KDIsIjAiKX06MDBgLGNvdW50OmR9fSksbT1be3BlcmlvZDoiMDA6MDAtMDM6MDAiLGNvdW50OjB9LHtwZXJpb2Q6IjAzOjAwLTA2OjAwIixjb3VudDowfSx7cGVyaW9kOiIwNjowMC0wOTowMCIsY291bnQ6MH0se3BlcmlvZDoiMDk6MDAtMTI6MDAiLGNvdW50OjB9LHtwZXJpb2Q6IjEyOjAwLTE1OjAwIixjb3VudDowfSx7cGVyaW9kOiIxNTowMC0xODowMCIsY291bnQ6MH0se3BlcmlvZDoiMTg6MDAtMjE6MDAiLGNvdW50OjB9LHtwZXJpb2Q6IjIxOjAwLTI0OjAwIixjb3VudDowfV07cy5mb3JFYWNoKHk9Pntjb25zdCBmPXBhcnNlSW50KHkuY3JlYXRlZEF0LnNwbGl0KCIgIilbMV0uc3BsaXQoIjoiKVswXSk7ZjwzP21bMF0uY291bnQrKzpmPDY/bVsxXS5jb3VudCsrOmY8OT9tWzJdLmNvdW50Kys6ZjwxMj9tWzNdLmNvdW50Kys6ZjwxNT9tWzRdLmNvdW50Kys6ZjwxOD9tWzVdLmNvdW50Kys6ZjwyMT9tWzZdLmNvdW50Kys6bVs3XS5jb3VudCsrfSk7Y29uc3QgUz1be21pbjowLG1heDoyNSxsYWJlbDoiMC0yNSJ9LHttaW46MjYsbWF4OjUwLGxhYmVsOiIyNi01MCJ9LHttaW46NTEsbWF4Ojc1LGxhYmVsOiI1MS03NSJ9LHttaW46NzYsbWF4OjEwMCxsYWJlbDoiNzYtMTAwIn0se21pbjoxMDEsbWF4OjIwMCxsYWJlbDoiMTAxLTIwMCJ9LHttaW46MjAxLG1heDo1MDAsbGFiZWw6IjIwMS01MDAifSx7bWluOjUwMSxtYXg6MS8wLGxhYmVsOiI1MDArIn1dLm1hcCh5PT4oe3JhbmdlOnkubGFiZWwsY291bnQ6cy5maWx0ZXIoZj0+e2NvbnN0IGQ9Zi5jb250ZW50Lmxlbmd0aDtyZXR1cm4gZD49eS5taW4mJmQ8PXkubWF4fSkubGVuZ3RofSkpO3Bvc3RNZXNzYWdlKHt0eXBlOiJzdGF0cy1yZXN1bHQiLGRhdGE6e2RhaWx5RGF0YTphLG1vbnRobHlEYXRhOmcseWVhcmx5RGF0YTpwLGhvdXJseURhdGE6RSx0aW1lRGlzdERhdGE6bSxsZW5ndGhEYXRhOlN9fSl9fWNhdGNoKHQpe2NvbnNvbGUuZXJyb3IoIldvcmtlciBmYWlsZWQgdG8gcHJvY2VzczoiLHQpLHBvc3RNZXNzYWdlKHt0eXBlOiJlcnJvciIsZXJyb3I6dC5tZXNzYWdlfHwiVW5rbm93biBlcnJvciBpbiB3b3JrZXIifSl9fSl9KX0pKCk7Cg==",d3=typeof window<"u"&&window.Blob&&new Blob([atob(wH)],{type:"text/javascript;charset=utf-8"});function Gte(e){let t;try{if(t=d3&&(window.URL||window.webkitURL).createObjectURL(d3),!t)throw"";const n=new Worker(t,{name:e?.name});return n.addEventListener("error",()=>{(window.URL||window.webkitURL).revokeObjectURL(t)}),n}catch{return new Worker("data:application/javascript;base64,"+wH,{name:e?.name})}finally{t&&(window.URL||window.webkitURL).revokeObjectURL(t)}}function Ap(){let e,t;const r=new Promise((o,i)=>{e=o,t=i});return r.resolve=e,r.reject=t,r}const f3={workers:8,utilization:.75,workerName:"Thino Parser Worker"},$y={BUILD_TAG_TREE:0,CALCULATE_STATS:0,CALCULATE_STATS_BANNER:0,FILTER_MEMOS:2},Zte=e=>{const t={...e};if(e.filter){const n=Ct.getQueryById(e.filter);n&&n.querystring&&(t.filterContent=JSON.parse(n.querystring))}return t};class SH extends N.Component{workers;nextWorkerId;shutdown;taskQueue;outstanding;throttle;cacheVersion=0;memoVersions=new Map;app;plugin;constructor(t,n,r,o){super(),this.workers=new Map,this.shutdown=!1,this.nextWorkerId=0,this.throttle=r??(()=>({...f3,workerName:o??f3.workerName})),this.taskQueue=[],this.outstanding=new Map,this.app=t,this.plugin=n}import(t){const n=t.map(i=>i.id).join(","),r=this.outstanding.get(n);if(r)return r;const o=Ap();return this.outstanding.set(n,o),this.addToQueue({type:"FILTER_MEMOS",memos:t,promise:o,priority:2,timestamp:Date.now()}),this.schedule(),o}addToQueue(t){this.taskQueue.push(t),this.taskQueue.sort((n,r)=>n.priority!==r.priority?n.priority-r.priority:n.timestamp-r.timestamp)}getNextTask(){if(this.taskQueue.length!==0)return this.taskQueue.shift()}unthrottle(){for(const t of this.workers.values())t.availableAt=Date.now()}async schedule(){if(this.taskQueue.length===0||this.shutdown)return;const t=this.availableWorker();if(!t)return;const n=this.getNextTask();if(n){t.active=[n.memos,n.promise,Date.now()];try{switch(n.type){case"CALCULATE_STATS":t.worker.postMessage({type:"calculate-stats",data:{memos:n.memos}});break;case"CALCULATE_STATS_BANNER":t.worker.postMessage({type:"calculate-stats-banner",data:{memos:n.memos,tags:n.tags||[]}});break;case"FILTER_MEMOS":t.worker.postMessage({type:"filter-memos",data:{memos:n.memos,query:Zte(n.query),filterOptions:n.filterOptions}});break;case"BUILD_TAG_TREE":t.worker.postMessage({type:"build-tag-tree",data:{memos:n.memos,filterOptions:n.filterOptions}});break}}catch{t.active=void 0,setTimeout(this.schedule.bind(this),0)}}}finish(t,n){if(!t.active)return;const[r,o,i]=t.active;"error"in n?o.reject(n.error):o.resolve(n);const a=r.map(s=>s.id).join(",");if(this.outstanding.delete(a),this.workers.size>this.throttle().workers)this.workers.delete(t.id),h3(t);else{const s=Date.now(),l=Math.max(.1,this.throttle().utilization)-1,u=(s-i)*l;t.active=void 0,u<=1e-10?(t.availableAt=s,this.schedule()):(t.availableAt=s+u,setTimeout(this.schedule.bind(this),u))}}availableWorker(){const t=Date.now();for(const n of this.workers.values())if(!n.active&&n.availableAt<=t)return n;if(this.workers.size<this.throttle().workers){const n=this.newWorker();return this.workers.set(n.id,n),n}}newWorker(){const t={id:this.nextWorkerId++,availableAt:Date.now(),worker:new Gte,name:this.throttle().workerName};return t.worker.onmessage=async n=>await this.handleWorkerMessage(t,n.data),t}onunload(){for(const t of this.workers.values())h3(t);for(;this.taskQueue.length>0;){const t=this.taskQueue.shift();t&&t.promise.reject("Terminated")}this.shutdown=!0}invalidateCache(t){if(!t||t.length===0){this.cacheVersion++;return}for(const r of t){const o=this.memoVersions.get(r)||0;this.memoVersions.set(r,o+1)}const n=[];this.outstanding.forEach((r,o)=>{const i=o.split("_");t.some(s=>i.includes(s))&&n.push(o)}),n.forEach(r=>this.outstanding.delete(r))}getVersionString(t){let n=`_v${this.cacheVersion}`;if(t&&t.length>0){const r=t.map(o=>`${o.id}:${this.memoVersions.get(o.id)||0}`).join(";");n+=`_m${r}`}return n}async calculateStats(t,n=!1){try{if(!t||t.length===0)return{};const r=n?`_force${Date.now()}`:this.getVersionString(t),o=t.map(s=>s.id).join(",")+"_stats"+r,i=this.outstanding.get(o);if(i&&!n)return i;const a=Ap();return this.outstanding.set(o,a),this.addToQueue({type:"CALCULATE_STATS",memos:t,promise:a,priority:$y.CALCULATE_STATS,timestamp:Date.now()}),this.schedule(),a}catch(r){return console.error("Obsidian-Thino: Failed to calculate stats. "+r),Promise.reject(r)}}async calculateStatsBanner(t,n,r=!1){try{if(!t||t.length===0)return{memosLength:0,tagsLength:n?.length||0,createdDays:0,taskAmount:0,mostActiveDay:"",mostActiveHour:"",earliestMemo:null,lengthOverflow:!1};const o=r?`_force${Date.now()}`:this.getVersionString(t),i=t.map(l=>l.id).join(",")+"_banner"+o,a=this.outstanding.get(i);if(a&&!r)return a;const s=Ap();return this.outstanding.set(i,s),this.addToQueue({type:"CALCULATE_STATS_BANNER",memos:t,tags:n,promise:s,priority:$y.CALCULATE_STATS_BANNER,timestamp:Date.now()}),this.schedule(),s}catch(o){return console.error("Obsidian-Thino: Failed to calculate banner stats. "+o),Promise.reject(o)}}async filterMemos(t,n,r={},o=!1){try{if(!t||t.length===0)return[];const i=JSON.stringify(n),a=JSON.stringify({...r,filterTagsInFile:this.plugin.settings.FilterByMetadata}),s=o?`_force${Date.now()}`:this.getVersionString(t),l=t.map(h=>h.id).join(",")+"_filter_"+i+"_"+a+s,u=this.outstanding.get(l);if(u&&!o)return u;const d=Ap();return this.outstanding.set(l,d),this.addToQueue({type:"FILTER_MEMOS",memos:t,promise:d,query:n,filterOptions:r,priority:$y.FILTER_MEMOS,timestamp:Date.now()}),this.schedule(),d}catch(i){return console.error("Obsidian-Thino: Failed to filter memos. "+i),Promise.reject(i)}}async buildTagTree(t,n=!1){try{if(!t||t.length===0)return{};const r={filterTagsInFile:this.plugin.settings.FilterByMetadata},o=n?`_force${Date.now()}`:this.getVersionString(t),i=t.map(l=>l.id).join(",")+"_tags_"+JSON.stringify(r)+o,a=this.outstanding.get(i);if(a&&!n)return a;const s=Ap();return this.outstanding.set(i,s),this.addToQueue({type:"BUILD_TAG_TREE",memos:t,promise:s,filterOptions:r,priority:$y.BUILD_TAG_TREE,timestamp:Date.now()}),this.schedule(),s}catch(r){return console.error("Obsidian-Thino: Failed to build tag tree. "+r),Promise.reject(r)}}async handleWorkerMessage(t,n){if(n.type==="stats-result"){t.active&&this.finish(t,n.data);return}if(n.type==="stats-banner-result"){t.active&&this.finish(t,n.data);return}if(n.type==="filter-result"){t.active&&this.finish(t,n.data);return}if(n.type==="build-tag-tree-result"){t.active&&this.finish(t,n.data);return}if(n.type==="error"){t.active&&this.finish(t,{error:n.error});return}}memoUpdated(t){const n=this.memoVersions.get(t)||0;this.memoVersions.set(t,n+1);const r=[];this.outstanding.forEach((o,i)=>{i.includes(t)&&r.push(i)}),r.forEach(o=>this.outstanding.delete(o))}memosUpdated(t){if(!t||t.length===0)return;for(const r of t){const o=this.memoVersions.get(r)||0;this.memoVersions.set(r,o+1)}const n=[];this.outstanding.forEach((r,o)=>{const i=o.split(",")[0].split("_");t.some(s=>i.includes(s))&&n.push(o)}),n.forEach(r=>this.outstanding.delete(r))}}function h3(e){e.worker.terminate(),e.active&&e.active[1].reject("Terminated"),e.active=void 0}function $te(e){return e.thinoWorkerManager||(e.thinoWorkerManager=new SH(e.app,e),e.addChild(e.thinoWorkerManager)),e.thinoWorkerManager}const hc=async({memos:e,query:t={},filterOptions:n={},plugin:r})=>{const o={onlyFilterType:"all",filterArchived:!0,filterDeleted:!0,filterDoneTasks:!!n.filterDoneTasks,filterComments:!0,...n},i={...t};try{return await $te(r).filterMemos(e,i,o)}catch(a){return console.error("Failed to filter memos using worker, falling back to synchronous filtering",a),qte(e,i,o)}};function qte(e,t,n){const{filterArchived:r=!0,filterDeleted:o=!0,filterDoneTasks:i=!1,filterComments:a=!0}=n,s=e.filter(x=>!(r&&x.rowStatus==="ARCHIVED"||o&&x.deletedAt||a&&x.content.includes("comment:")||i&&x.thinoType==="TASK-DONE"));if(Kte(t))return s;const{tag:l,duration:u,type:d,text:h,filter:p,path:m,metadata:b}=t,v=h?.toLowerCase()||"",y=!b||Object.keys(b).length===0,S=v?N.prepareSimpleSearch(v):null;return s.filter(x=>{if(p){const C=Ct.getQueryById(p);if(C){const k=JSON.parse(C.querystring);if(Array.isArray(k)&&!Jte(x,k))return!1}}if(!y&&Object.keys(b).some(k=>x.fileInfo?.frontmatter[k]!==b[k])||m&&x.path&&!x.path.toLowerCase().includes(m.toLowerCase()))return!1;if(S){const C=S(x.content.toLowerCase()),k=x.path?x.path.toLowerCase().includes(v):!1;if(x.thinoType==="MULTI"&&x.path){if(!C&&!k)return!1}else if(!C)return!1}if(l){const C=TH(x.content),k=x?.fileInfo?.tags?Xte(x.fileInfo.tags):new Set;if(!C.has(l)&&!k.has(l))return!1}if(u&&u.from!==0&&u.to!==0){const C=Le.getTimeStampByDate(x.createdAt);if(C<u.from||C>u.to)return!1}if(d)switch(d){case"NOT_TAGGED":if(x.content.match(Kg)||x.content.match(cS)||x.content.match(UM))return!1;break;case"LINKED":if(!x.content.match(zM))return!1;break;case"IMAGED":if(!x.content.match(VM))return!1;break;case"CONNECTED":if(!x.content.match(fh))return!1;break}return!0})}function Kte(e){if(!e)return!0;const{tag:t,duration:n,type:r,text:o,filter:i,path:a,metadata:s}=e,l=!s||Object.keys(s).length===0;return!(t||n&&n.from<n.to||r||o||i||a||!l)}function TH(e){return[Kg,UM,cS]?.reduce((n,r)=>((e.match(r)||[]).forEach(o=>{const a=(o?.replace(r,"$1").trim()).split("/");let s="";a.forEach(l=>{s+=l,n.add(s),s+="/"})}),n),new Set)}function Xte(e){if(!Array.isArray(e)||e.length===0)return new Set;const t=e.filter(r=>!!r).map(r=>r.toString().trim());if(t.length===0)return new Set;const n=new Set;return t.forEach(r=>{const o=r.split("/");let i="";o.forEach((a,s)=>{i+=(s>0?"/":"")+a,n.add(i)})}),n}function Jte(e,t){return!Array.isArray(t)||t.length===0?!0:t.every(n=>{if(!n||typeof n!="object"||!n.type||!n.value||typeof n.value!="object")return!0;const{type:r,value:o}=n,i=o.operator,a=o.value;switch(r){case"TAG":{const s=typeof a=="string"?a:"",l=e.content.includes(`#${s}`);return i==="CONTAIN"?l:!l}case"TEXT":{const s=typeof a=="string"?a.toLowerCase():"",l=e.content.toLowerCase().includes(s);return i==="CONTAIN"?l:!l}case"TYPE":return i==="IS"?e.thinoType===a:e.thinoType!==a;case"DATE":{const s=typeof a=="string"?new Date(a):typeof a=="object"&&a!==null&&"value"in a?new Date(a.value):null;if(!s)return!0;const l=new Date(e.createdAt);return i==="CONTAIN"?l>=s:l<s}case"LIST":switch(a){case"TODO":{const s=e.thinoType==="TASK-TODO";return i==="IS"?s:!s}case"DONE":{const s=e.thinoType==="TASK-DONE";return i==="IS"?s:!s}case"LIST":{const s=e.thinoType==="JOURNAL";return i==="IS"?s:!s}case"OTHER":{const s=!["TASK-TODO","TASK-DONE","JOURNAL"].includes(e.thinoType);return i==="IS"?s:!s}default:return!0}case"SOURCE":return i==="IS"?e.thinoType===a:e.thinoType!==a;case"PATH":{if(!e.path)return i!=="CONTAIN";const s=typeof a=="string"?a.toLowerCase():"",l=e.path.toLowerCase().includes(s);return i==="CONTAIN"?l:!l}case"METADATA":{if(!e.fileInfo?.frontmatter)return i!=="CONTAIN";const s=typeof a=="object"&&a!==null?a:{name:"",value:""},l="name"in s?s.name:"",u="value"in s?s.value:"";if(!l)return!0;const d=e.fileInfo.frontmatter[l]===u;return i==="CONTAIN"?d:!d}case"TIME_RANGE":{const s=new Date;let l,u=s;if(typeof a!="string")return!0;switch(a){case"7d":l=Fo(s,7);break;case"14d":l=Fo(s,14);break;case"30d":l=Fo(s,30);break;case"90d":l=Fo(s,90);break;case"180d":l=Fo(s,180);break;case"365d":l=Fo(s,365);break;case"thisWeek":l=Hi(s),u=S0(s);break;case"thisMonth":l=y0(s),u=v0(s);break;case"thisYear":l=w0(s),u=b0(s);break;case"lastWeek":{const h=Fo(s,7);l=Hi(h),u=S0(h);break}case"lastMonth":{const h=mH(s,1);l=y0(h),u=v0(h);break}case"lastYear":{const h=gH(s,1);l=w0(h),u=b0(h);break}default:return!0}const d=new Date(e.createdAt);return i==="WITHIN"?pH(d,{start:l,end:u}):i==="BEFORE"?d<l:!0}default:return!0}})}const Qte=[{text:E("AND"),value:"AND"},{text:E("OR"),value:"OR"}],Za={TAG:{value:"TAG",text:E("TAG"),operators:[{text:E("INCLUDE"),value:"CONTAIN"},{text:E("EXCLUDE"),value:"NOT_CONTAIN"}]},TYPE:{value:"TYPE",text:E("TYPE"),operators:[{value:"IS",text:E("IS")},{value:"IS_NOT",text:E("ISNOT")}],values:[{value:"CONNECTED",text:E("LINKED")},{value:"NOT_TAGGED",text:E("NO TAGS")},{value:"LINKED",text:E("HAS LINKS")},{value:"IMAGED",text:E("HAS IMAGES")}]},TEXT:{value:"TEXT",text:E("TEXT"),operators:[{value:"CONTAIN",text:E("INCLUDE")},{value:"NOT_CONTAIN",text:E("EXCLUDE")}]},DATE:{value:"DATE",text:E("DATE"),operators:[{value:"NOT_CONTAIN",text:E("BEFORE")},{value:"CONTAIN",text:E("AFTER")}]},LIST:{value:"LIST",text:E("LIST"),operators:[{value:"IS",text:E("IS")},{value:"IS_NOT",text:E("ISNOT")}],values:[{value:"TODO",text:E("TODO")},{value:"DONE",text:E("DONE")},{value:"LIST",text:E("JOURNAL")},{value:"OTHER",text:E("OTHER")}]},SOURCE:{value:"SOURCE",text:E("SOURCE"),operators:[{value:"IS",text:E("IS")},{value:"IS_NOT",text:E("ISNOT")}],values:[{value:"DAILY",text:E("DAILY")},{value:"MULTI",text:E("MULTI")},{value:"FILE",text:E("FILE")},{value:"CANVAS",text:E("CANVAS")}]},PATH:{value:"PATH",text:E("PATH"),operators:[{value:"CONTAIN",text:E("INCLUDE")},{value:"NOT_CONTAIN",text:E("EXCLUDE")}]},METADATA:{value:"METADATA",text:E("METADATA"),operators:[{value:"CONTAIN",text:E("INCLUDE")},{value:"NOT_CONTAIN",text:E("EXCLUDE")}]},TIME_RANGE:{value:"TIME_RANGE",text:E("TIME RANGE"),operators:[{value:"WITHIN",text:E("WITHIN")},{value:"BEFORE",text:E("BEFORE")}],values:[{value:"7d",text:E("7 days")},{value:"14d",text:E("14 days")},{value:"30d",text:E("30 days")},{value:"90d",text:E("3 months")},{value:"180d",text:E("6 months")},{value:"365d",text:E("1 year")},{value:"thisWeek",text:E("This week")},{value:"thisMonth",text:E("This month")},{value:"thisYear",text:E("This year")},{value:"lastWeek",text:E("Last week")},{value:"lastMonth",text:E("Last month")},{value:"lastYear",text:E("Last year")}]}},rE=Za.TYPE.values,ene=e=>{for(const t of rE)if(t.value===e)return t.text;return""},p3=()=>({type:"TAG",value:{operator:"CONTAIN",value:""},relation:"AND"}),tne=(e,t)=>{let n=!0;for(const r of t){const{relation:o}=r,i=nne(e,r);o==="OR"?n=n||i:n=n&&i}return n},nne=(e,t)=>{if(!t||typeof t!="object"||!t.type||!t.value||typeof t.value!="object")return!0;const{type:n,value:r}=t,o=r.operator,i=r.value;if(i===""&&n!=="TYPE"&&n!=="LIST")return!0;switch(n){case"TAG":{const a=TH(e.content),s=typeof i=="string"?i:"",l=a.has(s);return o==="CONTAIN"?l:!l}case"TEXT":{const a=typeof i=="string"?i.toLowerCase():"",l=N.prepareSimpleSearch(a)(e.content.toLowerCase());return o==="CONTAIN"?l:!l}case"TYPE":{let a=!1;return(i==="NOT_TAGGED"&&e.content.match(Kg)===null&&e.content.match(cS)===null||i==="LINKED"&&e.content.match(zM)!==null||i==="IMAGED"&&e.content.match(VM)!==null||i==="CONNECTED"&&e.content.match(fh)!==null)&&(a=!0),o==="IS"?a:!a}case"LIST":{const s=(e.thinoType==="JOURNAL"?"LIST":e.thinoType==="TASK-TODO"?"TODO":e.thinoType==="TASK-DONE"?"DONE":"OTHER")===i;return o==="IS"?s:!s}case"SOURCE":return o==="IS"?e.sourceType===i:e.sourceType!==i;case"PATH":{if(!e.path)return o!=="CONTAIN";const a=typeof i=="string"?i.toLowerCase():"",s=e.path.toLowerCase().includes(a);return o==="CONTAIN"?s:!s}case"METADATA":{if(!e.fileInfo?.frontmatter)return o!=="CONTAIN";const a=typeof i=="object"&&i!==null?i:{name:"",value:""},s="name"in a?a.name:"",l="value"in a?a.value:"";if(!s)return!0;const u=e.fileInfo.frontmatter,d=u[s]&&u[s]?.toString().includes(l);return o==="CONTAIN"?d:!d}case"TIME_RANGE":{const a=new Date;let s,l=a;if(typeof i!="string")return!0;switch(i){case"7d":s=Fo(a,7);break;case"14d":s=Fo(a,14);break;case"30d":s=Fo(a,30);break;case"90d":s=Fo(a,90);break;case"180d":s=Fo(a,180);break;case"365d":s=Fo(a,365);break;case"thisWeek":s=Hi(a),l=S0(a);break;case"thisMonth":s=y0(a),l=v0(a);break;case"thisYear":s=w0(a),l=b0(a);break;case"lastWeek":{const d=Fo(a,7);s=Hi(d),l=S0(d);break}case"lastMonth":{const d=mH(a,1);s=y0(d),l=v0(d);break}case"lastYear":{const d=gH(a,1);s=w0(d),l=b0(d);break}default:return!0}const u=new Date(e.createdAt);return o==="WITHIN"?pH(u,{start:s,end:l}):o==="BEFORE"?u<s:!0}case"DATE":{let a=null;if(typeof i=="string"){const u=new Date(i);if(!isNaN(u.getTime()))a=u;else{const d=app.plugins.enabledPlugins.has("nldates-obsidian")&&app.plugins.getPlugin("nldates-obsidian");if(d){const h=d.parseDate(i);if(h.date!==null)a=new Date(h.date);else return!0}else return!0}}else typeof i=="object"&&i!==null&&"value"in i&&(a=new Date(i.value));if(!a||isNaN(a.getTime()))return!0;const s=new Date(e.createdAt),l=$ee(s,m0(a));return o==="CONTAIN"?l:!l}default:return!0}};function wh(e){const[t,n]=D.useState(()=>!!e),r=D.useCallback(o=>{n(typeof o=="boolean"?o:i=>!i)},[]);return[t,r]}const nv=()=>{const{dailyNotesState:{app:e,view:t},locationState:{query:{type:n}}}=D.useContext(ct),r=Y.useRef(null),o=Y.useRef(null),[i,a]=wh(!1);D.useEffect(()=>{!r||!t||!e||(t.registerEvent(e.workspace.on("blur-on-memos",()=>{r.current?.blur()})),t.registerEvent(e.workspace.on("focus-on-searchBar",()=>{r.current?.focus()})))},[r,e,t]),D.useEffect(()=>{o&&N.setIcon(o.current,"search")},[o]);const s=h=>{const{type:p}=Ue.getState().query;h===p&&(h=""),Ue.setMemoTypeQuery(h)},l=h=>{const p=h.currentTarget.value;if(!p.contains(" -time: ")){Ue.setTextQuery(p);return}const m=p.split(" -time: ")[1],b=m.length>10?m.match(/\d{4}-\d{2}-\d{2}/g):null;if(b==null){Ue.setTextQuery(p.split(" -time: ")[0]);return}if(b.length===1){const v=N.moment(b[0]);Ue.setTimeQuery({from:v.startOf("day").valueOf(),to:v.endOf("day").valueOf()})}else if(b.length===2){const v=N.moment(b[0]),y=N.moment(b[1]);Ue.setTimeQuery({from:v.startOf("day").valueOf(),to:y.endOf("day").valueOf()})}Ue.setTextQuery(p.split(" -time: ")[0])},u=()=>{a(!0)},d=()=>{a(!1)};return w.jsxs("div",{className:"search-bar-container",children:[w.jsxs("div",{className:"search-bar-inputer",children:[w.jsx("span",{ref:o,className:"btn icon-img"}),w.jsx("input",{ref:r,className:"text-input",type:"text",onMouseOver:u,onMouseOut:d,placeholder:i?E("Type here"):"",onChange:l})]}),w.jsx("div",{className:"quickly-action-wrapper",children:w.jsxs("div",{className:"quickly-action-container",children:[w.jsx("span",{className:"title-text",children:E("Quick filter")}),w.jsxs("div",{className:"section-container types-container",children:[w.jsxs("span",{className:"section-text",children:[E("TYPE"),":"]}),w.jsx("div",{className:"values-container",children:rE.map((h,p)=>w.jsxs("div",{children:[w.jsx("span",{className:`type-item ${n===h.value?"selected":""}`,onClick:()=>{s(h.value)},children:h.text}),p+1<rE.length?w.jsx("span",{className:"split-text",children:"/"}):null]},h.value))})]})]})})]})},rne=e=>{const{children:t,when:n}=e;return n?w.jsx(w.Fragment,{children:t}):null},il=rne;function Nt(){const e=document.createDocumentFragment();e.createEl("div",{cls:"thino-info"}).createEl("div",{text:E("This is a pro feature, please upgrade to pro version to use it.")});const r=e.createEl("div",{cls:"thino-link"}).createEl("div",{text:E("You can get pro version from: ")}),o=localStorage.getItem("language");let i="https://pkmer.cn/products/UserProfile/";o&&o==="zh"?i="https://pkmer.cn/products/thino/":i="https://thino.pkmer.net/en/",r.createEl("a",{text:"PKMer",attr:{href:i}}),new N.Notice(e,5e3)}const{exec:one,execSync:yet}=N.Platform.isDesktop&&require("child_process"),{createHash:ine}=N.Platform.isDesktop&&require("crypto"),ane={native:"%windir%\\System32",mixed:"%windir%\\sysnative\\cmd.exe /c %windir%\\System32"},sne=N.Platform.isDesktop&&{darwin:"ioreg -rd1 -c IOPlatformExpertDevice",win32:`${ane[lne()]}\\REG.exe QUERY HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Cryptography /v MachineGuid`,linux:"( cat /var/lib/dbus/machine-id /etc/machine-id 2> /dev/null || hostname ) | head -n 1 || :",freebsd:"kenv -q smbios.system.uuid || sysctl -n kern.hostuuid"};function lne(){return process.platform!=="win32"?"":process.arch==="ia32"&&Object.hasOwnProperty.call(process.env,"PROCESSOR_ARCHITEW6432")?"mixed":"native"}function cne(e){return ine("sha256").update(e).digest("hex")}function une(e){switch(process.platform){case"darwin":return e.split("IOPlatformUUID")[1].split(`
|
|
|
`)[0].replace(/\=|\s+|\"/gi,"").toLowerCase();case"win32":return e.toString().split("REG_SZ")[1].replace(/\r+|\n+|\s+/gi,"").toLowerCase();case"linux":return e.toString().replace(/\r+|\n+|\s+/gi,"").toLowerCase();case"freebsd":return e.toString().replace(/\r+|\n+|\s+/gi,"").toLowerCase();default:throw new Error(`Unsupported platform: ${process.platform}`)}}function Sn(e=!1){return new Promise((t,n)=>{one(sne[process.platform],{},(r,o)=>{if(r)return n(new Error(`Error while obtaining machine id: ${r.stack}`));const i=une(o.toString());return t(e?i:cne(i))})})}const m3={list:"align-left",waterfall:"layout-grid",calendar:"calendar",minimal:"list",table:"table",chat:"message-square",moments:"chrome"},dne=e=>{const{dailyNotesState:{app:t,view:n,verifyState:r,settings:o},globalState:{manifest:i,isMobileView:a}}=D.useContext(ct),s=D.useRef(null),l=D.useRef(null),[u,d]=D.useState((window.app||t).loadLocalStorage("thinoListView")),[h,p]=D.useState(null);D.useEffect(()=>{if(!i||!t)return;const b=t?.plugins.getPlugin(i.id);p(b),d(b?.settings.MemoListView),Ze.setMemoListView(b?.settings.MemoListView)},[i,t]),D.useEffect(()=>{if(!t||!n||!h||!h.settings)return;const b=()=>{if(n.leaf.height===0)return;const v=h?.settings?.MemoListView;h?.settings?.SupportSelectOtherView||v==="chat"||v==="moments"||(n.leaf.width>950?(d(v),Ze.setMemoListView(v)):n.leaf.width<=950&&(Ze.setMemoListView("list"),d("list")))};b(),l.current||(l.current=t.workspace.on("resize",b),n.registerEvent(l.current))},[t,n,h]),D.useEffect(()=>{s&&(N.setIcon(s.current,m3[u||"list"]),Ze.setMemoListView(u),N.requireApiVersion("1.4.4")&&N.setTooltip(s.current,E("Switch view")))},[u]);const m=async b=>{const v=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),y=N.Platform.isDesktop?await Sn():v.identifier||v.uuid;if(!r||r?.appId!==y){Nt();return}const S=async k=>{Ze.setMemoListView(k),h&&(h.settings.MemoListView=k,await h.saveSettings()),d(k)},x=[{view:"list",title:E("List")},{view:"chat",title:E("Chat")},{view:"moments",title:E("Moments")}];(!a||o?.SupportSelectOtherView)&&x.push({view:"waterfall",title:E("Waterfall")},{view:"calendar",title:E("Calendar")},{view:"table",title:E("Table")});const C=new N.Menu;x.forEach(({view:k,title:M})=>{C.addItem(I=>{I.setChecked(u===k).setIcon(m3[k]).setTitle(M).onClick(()=>{u!==k&&S(k)})})}),C.showAtMouseEvent(b.nativeEvent)};return w.jsx("div",{className:`memos-view-switcher-wrapper ${e.className?e.className:""} pro`,ref:s,onClick:m})},fne=()=>{const e=D.useRef(null);return D.useEffect(()=>{e&&(N.setIcon(e.current,"calendar-check"),N.setTooltip&&N.setTooltip(e.current,E("Daily Memos")))},[e]),w.jsx("div",{className:"memos-review-entry-wrapper",ref:e,onClick:()=>{Ue.setPathname("/daily")}})},Fx=()=>({type:"initialText",value:"",timestamp:Date.now(),selectionStart:0,selectionEnd:0}),g3={initialValue:"",interval:300};class hne{constructor(t,n=g3){this.listeners=[],this.runUndo=()=>{const r=this.actions[this.currentIndex].selectionStart;this.currentIndex>0&&this.currentIndex--,this.element.value=this.actions[this.currentIndex].value,this.element.setSelectionRange(r,r),this.dispatchChange()},this.runRedo=()=>{this.currentIndex<this.actions.length-1&&this.currentIndex++;const r=this.actions[this.currentIndex].selectionEnd;this.element.value=this.actions[this.currentIndex].value,this.element.setSelectionRange(r,r),this.dispatchChange()},this.getActions=()=>this.actions,this.setState=(r,o)=>{this.actions=[...r],this.currentIndex=o<this.actions.length?o:this.actions.length-1,this.dispatchChange()},this.resetState=()=>{this.actions=[Fx()],this.currentIndex=0,this.dispatchChange()},this.destroy=()=>{this.rmEventListeners()},this.subscribe=r=>{this.listeners.push(r)},this.handleElementKeydown=r=>{const o=r;o.key==="z"&&!o.shiftKey&&(o.metaKey||o.ctrlKey)?(r.preventDefault(),this.runUndo()):(o.key==="z"&&o.shiftKey&&(o.metaKey||o.ctrlKey)||o.key==="y"&&(o.metaKey||o.ctrlKey))&&(r.preventDefault(),this.runRedo())},this.handleElementInput=r=>{const o=r,i=this.actions[this.currentIndex];this.pushNewAction({type:o.inputType,value:this.element.value,timestamp:Date.now(),selectionStart:this.element.selectionEnd-(this.element.value.length-i.value.length),selectionEnd:this.element.selectionEnd})},this.addEventListeners=()=>{this.element.addEventListener("keydown",this.handleElementKeydown),this.element.addEventListener("input",this.handleElementInput)},this.rmEventListeners=()=>{this.element.removeEventListener("keydown",this.handleElementKeydown),this.element.removeEventListener("input",this.handleElementInput)},this.pushNewAction=r=>{const o=this.actions[this.currentIndex];o&&o.type===r.type&&r.timestamp-o.timestamp<this.config.interval?this.actions[this.currentIndex]=Object.assign(Object.assign({},o),{value:r.value,selectionEnd:r.selectionEnd,timestamp:r.timestamp}):(this.config.maxSize&&this.currentIndex>=this.config.maxSize?(this.actions.shift(),this.actions[0]=Fx()):this.currentIndex++,this.actions[this.currentIndex]=r,this.actions=this.actions.slice(0,this.currentIndex+1)),this.dispatchChange()},this.dispatchChange=()=>{for(const r of this.listeners)r([...this.actions],this.currentIndex)},this.element=t,this.config=Object.assign(Object.assign({},g3),n),this.config.initialActions&&this.config.initialActions.length>0?(this.actions=this.config.initialActions,this.config.initialIndex!==void 0&&this.config.initialIndex<this.actions.length?this.currentIndex=this.config.initialIndex:this.currentIndex=this.actions.length-1):(this.actions=[Fx()],this.currentIndex=0,this.config.initialValue!==""&&(this.actions.push({type:"insertText",value:this.config.initialValue,timestamp:Date.now(),selectionStart:0,selectionEnd:this.config.initialValue.length}),this.currentIndex++)),this.element.value=this.actions[this.currentIndex].value,this.addEventListeners()}}function pne(){const[,e]=D.useState(!1);return D.useCallback(()=>{e(n=>!n)},[])}var xH={exports:{}};(function(e){(function(){var t=["direction","boxSizing","width","height","overflowX","overflowY","borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth","borderStyle","paddingTop","paddingRight","paddingBottom","paddingLeft","fontStyle","fontVariant","fontWeight","fontStretch","fontSize","fontSizeAdjust","lineHeight","fontFamily","textAlign","textTransform","textIndent","textDecoration","letterSpacing","wordSpacing","tabSize","MozTabSize"],n=typeof window<"u",r=n&&window.mozInnerScreenX!=null;function o(i,a,s){if(!n)throw new Error("textarea-caret-position#getCaretCoordinates should only be called in a browser");var l=s&&s.debug||!1;if(l){var u=document.querySelector("#input-textarea-caret-position-mirror-div");u&&u.parentNode.removeChild(u)}var d=document.createElement("div");d.id="input-textarea-caret-position-mirror-div",document.body.appendChild(d);var h=d.style,p=window.getComputedStyle?getComputedStyle(i):i.currentStyle;h.whiteSpace="pre-wrap",i.nodeName!=="INPUT"&&(h.wordWrap="break-word"),h.position="absolute",l||(h.visibility="hidden"),t.forEach(function(v){h[v]=p[v]}),r?i.scrollHeight>parseInt(p.height)&&(h.overflowY="scroll"):h.overflow="hidden",d.textContent=i.value.substring(0,a),i.nodeName==="INPUT"&&(d.textContent=d.textContent.replace(/\s/g," "));var m=document.createElement("span");m.textContent=i.value.substring(a)||".",d.appendChild(m);var b={top:m.offsetTop+parseInt(p.borderTopWidth),left:m.offsetLeft+parseInt(p.borderLeftWidth)};return l?m.style.backgroundColor="#aaa":document.body.removeChild(d),b}e.exports=o})()})(xH);var mne=xH.exports;const gne=tt(mne);var IH=xr.CustomEvent;function vne(){try{var e=new IH("cat",{detail:{foo:"bar"}});return e.type==="cat"&&e.detail.foo==="bar"}catch{}return!1}var yne=vne()?IH:typeof document<"u"&&typeof document.createEvent=="function"?function(t,n){var r=document.createEvent("CustomEvent");return n?r.initCustomEvent(t,n.bubbles,n.cancelable,n.detail):r.initCustomEvent(t,!1,!1,void 0),r}:function(t,n){var r=document.createEventObject();return r.type=t,n?(r.bubbles=!!n.bubbles,r.cancelable=!!n.cancelable,r.detail=n.detail):(r.bubbles=!1,r.cancelable=!1,r.detail=void 0),r};const bne=tt(yne);function wne(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Sne(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{},r=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),r.forEach(function(o){wne(e,o,n[o])})}return e}function rv(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function v3(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function bS(e,t,n){return t&&v3(e.prototype,t),n&&v3(e,n),e}function pf(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?pf=function(n){return typeof n}:pf=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},pf(e)}function Yb(e){return typeof Symbol=="function"&&pf(Symbol.iterator)==="symbol"?Yb=function(n){return pf(n)}:Yb=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":pf(n)},Yb(e)}function Tne(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function wS(e,t){return t&&(Yb(t)==="object"||typeof t=="function")?t:Tne(e)}function If(e){return If=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},If(e)}function oE(e,t){return oE=Object.setPrototypeOf||function(r,o){return r.__proto__=o,r},oE(e,t)}function SS(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&oE(e,t)}function xne(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t<e.length;t++)n[t]=e[t];return n}}function Ine(e){if(Symbol.iterator in Object(e)||Object.prototype.toString.call(e)==="[object Arguments]")return Array.from(e)}function kne(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function Ene(e){return xne(e)||Ine(e)||kne()}var oi={ESC:27,UP:38,DOWN:40,LEFT:37,RIGHT:39,ENTER:13,TAB:9},Cne=function e(){var t=this;rv(this,e),this.startListen=function(n){n&&n.addEventListener("keydown",t.f)},this.stopListen=function(n){n&&n.removeEventListener("keydown",t.f)},this.add=function(n,r){var o=n;return typeof o!="object"&&(o=[o]),t.listeners[t.index]={keyCode:o,fn:r},t.index++},this.remove=function(n){delete t.listeners[n]},this.removeAll=function(){t.listeners={},t.index=1},this.index=1,this.listeners={},this.f=function(n){if(n){var r=n.keyCode||n.which;Object.values(t.listeners).forEach(function(o){var i=o.keyCode,a=o.fn;i.includes(r)&&(n.stopPropagation(),n.preventDefault(),a(n))})}}},wu=new Cne,Mne=function(e){SS(t,e);function t(){var n,r;rv(this,t);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return r=wS(this,(n=If(t)).call.apply(n,[this].concat(i))),r.selectItem=function(){var s=r.props,l=s.item,u=s.onSelectHandler;u(l)},r}return bS(t,[{key:"shouldComponentUpdate",value:function(r){return this.props.item!==r.item||this.props.selected!==r.selected||this.props.style!==r.style||this.props.className!==r.className}},{key:"render",value:function(){var r=this,o=this.props,i=o.component,a=o.style,s=o.onClickHandler,l=o.item,u=o.selected,d=o.className,h=o.innerRef;return Y.createElement("li",{className:"rta__item ".concat(u===!0?"rta__item--selected":""," ").concat(d||""),style:a},Y.createElement("div",{className:"rta__entity ".concat(u===!0?"rta__entity--selected":""),role:"button",tabIndex:0,onClick:s,onFocus:this.selectItem,onMouseEnter:this.selectItem,onTouchStart:function(){r.clicked=!0,r.selectItem()},onTouchEnd:function(m){m.preventDefault(),r.clicked&&s(m)},onTouchMove:function(){r.clicked=!1},onTouchCancel:function(){r.clicked=!1},ref:h},Y.createElement(i,{selected:u,entity:l})))}}]),t}(Y.Component),Dne=function(e){SS(t,e);function t(){var n,r;rv(this,t);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return r=wS(this,(n=If(t)).call.apply(n,[this].concat(i))),r.state={selectedItem:null},r.cachedIdOfItems=new Map,r.onPressEnter=function(s){typeof s<"u"&&s.preventDefault();var l=r.props.values;r.modifyText(l[r.getPositionInList()])},r.getPositionInList=function(){var s=r.props.values,l=r.state.selectedItem;return l?s.findIndex(function(u){return r.getId(u)===r.getId(l)}):0},r.getId=function(s){if(r.cachedIdOfItems.has(s))return r.cachedIdOfItems.get(s);var l=r.props.getTextToReplace(s),u=function(){if(l){if(l.key)return l.key;if(typeof s=="string"||!s.key)return l.text}if(!s.key)throw new Error("Item ".concat(JSON.stringify(s),' has to have defined "key" property'));return s.key},d=u();return r.cachedIdOfItems.set(s,d),d},r.listeners=[],r.itemsRef={},r.modifyText=function(s){if(s){var l=r.props.onSelect;l(s)}},r.selectItem=function(s){var l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,u=r.props.onItemHighlighted;r.state.selectedItem!==s&&r.setState({selectedItem:s},function(){u(s),l&&r.props.dropdownScroll(r.itemsRef[r.getId(s)])})},r.scroll=function(s){s.preventDefault();var l=r.props.values,u=s.keyCode||s.which,d=r.getPositionInList(),h;switch(u){case oi.DOWN:h=d+1;break;case oi.UP:h=d-1;break;default:h=d;break}h=(h%l.length+l.length)%l.length,r.selectItem(l[h],[oi.DOWN,oi.UP].includes(u))},r.isSelected=function(s){var l=r.state.selectedItem;return l?r.getId(l)===r.getId(s):!1},r}return bS(t,[{key:"componentDidMount",value:function(){this.listeners.push(wu.add([oi.DOWN,oi.UP],this.scroll),wu.add([oi.ENTER,oi.TAB],this.onPressEnter));var r=this.props.values;r&&r[0]&&this.selectItem(r[0])}},{key:"componentDidUpdate",value:function(r){var o=this,i=r.values,a=this.props.values,s=i.map(function(u){return o.getId(u)}).join(""),l=a.map(function(u){return o.getId(u)}).join("");s!==l&&a&&a[0]&&this.selectItem(a[0])}},{key:"componentWillUnmount",value:function(){for(var r;this.listeners.length;)r=this.listeners.pop(),wu.remove(r)}},{key:"render",value:function(){var r=this,o=this.props,i=o.values,a=o.component,s=o.style,l=o.itemClassName,u=o.className,d=o.itemStyle;return Y.createElement("ul",{className:"rta__list ".concat(u||""),style:s},i.map(function(h){return Y.createElement(Mne,{key:r.getId(h),innerRef:function(m){r.itemsRef[r.getId(h)]=m},selected:r.isSelected(h),item:h,className:l,style:d,onClickHandler:r.onPressEnter,onSelectHandler:r.selectItem,component:a})}))}}]),t}(Y.Component);function Ane(e,t){var n=parseInt(getComputedStyle(t).getPropertyValue("height"),10),r=parseInt(getComputedStyle(e).getPropertyValue("height"),10)-n,o=t.offsetTop,i=e.scrollTop;o<i+r&&i<o||(e.scrollTop=o)}var y3="next",ec={X:{LEFT:"rta__autocomplete--left",RIGHT:"rta__autocomplete--right"},Y:{TOP:"rta__autocomplete--top",BOTTOM:"rta__autocomplete--bottom"}},b3=function(t){return console.error("RTA: dataProvider fails: ".concat(t,`
|
|
|
|
|
|
Check the documentation or create issue if you think it's bug. https://github.com/webscopeio/react-textarea-autocomplete/issues`))},Nne=[".","^","$","*","+","-","?","(",")","[","]","{","}","\\","|"],qy=function(t){return Ene(t).map(function(n){return Nne.includes(n)?"\\".concat(n):n}).join("")},One=function(e){SS(t,e);function t(){return rv(this,t),wS(this,If(t).apply(this,arguments))}return bS(t,[{key:"componentDidMount",value:function(){var r=this.props.boundariesElement;if(typeof r=="string"){var o=document.querySelector(r);if(!o)throw new Error("RTA: Invalid prop boundariesElement: it has to be string or HTMLElement.");this.containerElem=o}else if(r instanceof HTMLElement)this.containerElem=r;else throw new Error("RTA: Invalid prop boundariesElement: it has to be string or HTMLElement.");if(!this.containerElem||!this.containerElem.contains(this.ref))throw new Error("RTA: Invalid prop boundariesElement: it has to be one of the parents of the RTA.")}},{key:"componentDidUpdate",value:function(){var r,o,i=this.props.top||0,a=this.props.left||0,s=[],l=[],u=0,d=0,h=this.containerElem.getBoundingClientRect(),p=this.ref.getBoundingClientRect(),m=this.props.textareaRef.getBoundingClientRect(),b=window.getComputedStyle(this.ref),v=parseInt(b.getPropertyValue("margin-top"),10),y=parseInt(b.getPropertyValue("margin-bottom"),10),S=parseInt(b.getPropertyValue("margin-left"),10),x=parseInt(b.getPropertyValue("margin-right"),10),C=v+y+m.top+i+p.height,k=S+x+m.left+a+p.width;k>h.right&&m.left+a>p.width?(d=a-p.width,s.push(ec.X.LEFT),l.push(ec.X.RIGHT)):(d=a,s.push(ec.X.RIGHT),l.push(ec.X.LEFT)),C>h.bottom&&m.top+i>p.height?(u=i-p.height,s.push(ec.Y.TOP),l.push(ec.Y.BOTTOM)):(u=i,s.push(ec.Y.BOTTOM),l.push(ec.Y.TOP)),this.props.renderToBody&&(u+=m.top,d+=m.left),this.ref.style.top="".concat(u,"px"),this.ref.style.left="".concat(d,"px"),(r=this.ref.classList).remove.apply(r,l),(o=this.ref.classList).add.apply(o,s)}},{key:"render",value:function(){var r=this,o=this.props,i=o.style,a=o.className,s=o.innerRef,l=o.children,u=o.renderToBody,d=document.body,h=Y.createElement("div",{ref:function(m){r.ref=m,s(m)},className:"rta__autocomplete ".concat(a||""),style:i},l);return u&&d!==null?rD.createPortal(h,d):h}}]),t}(Y.Component),kH=function(e){SS(t,e);function t(n){var r;rv(this,t),r=wS(this,If(t).call(this,n)),r.state={top:null,left:null,currentTrigger:null,actualToken:"",data:null,value:"",dataLoading:!1,selectionEnd:0,component:null,textToReplace:null},r.escListenerInit=function(){r.escListener||(r.escListener=wu.add(oi.ESC,r._closeAutocomplete))},r.escListenerDestroy=function(){r.escListener&&(wu.remove(r.escListener),r.escListener=null)},r.getSelectionPosition=function(){return r.textareaRef?{selectionStart:r.textareaRef.selectionStart,selectionEnd:r.textareaRef.selectionEnd}:null},r.getSelectedText=function(){if(!r.textareaRef)return null;var l=r.textareaRef,u=l.selectionStart,d=l.selectionEnd;return u===d?null:r.state.value.substr(u,d-u)},r.setCaretPosition=function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;r.textareaRef&&(r.textareaRef.focus(),r.textareaRef.setSelectionRange(l,l))},r.getCaretPosition=function(){if(!r.textareaRef)return 0;var l=r.textareaRef.selectionEnd;return l},r._handleCaretChange=function(l){var u=function(){var p=r.getCaretPosition()-1;r.lastTrigger=r.lastTrigger?p:0};if(l.type==="keydown"){var d=l.keyCode||l.which;switch(d){case oi.UP:case oi.DOWN:r._isAutocompleteOpen()||u();break;case oi.LEFT:case oi.RIGHT:u();break}return}u()},r._onSelect=function(l){var u=r.state,d=u.selectionEnd,h=u.currentTrigger,p=u.value,m=r.props.onItemSelected;if(h){var b=r._getTextToReplace(h);if(!b){r._closeAutocomplete();return}var v=b(l);if(!v){r._closeAutocomplete();return}m&&m({currentTrigger:h,item:l});var y=function(B,_,H){switch(B){case"start":return H;case"next":case"end":return H+_.length;default:if(!Number.isInteger(B))throw new Error('RTA: caretPosition should be "start", "next", "end" or number.');return B}},S=p.slice(0,d),x=qy(h),C=S.length-S.lastIndexOf(h),k=S.search(new RegExp("(?!".concat(x,")$")))-C,M=v.caretPosition==="next"?"".concat(v.text," "):v.text,I=y(v.caretPosition,M,k),O=S.substring(0,k)+M,R=p.replace(S,O);r.setState({value:R,dataLoading:!1},function(){var L=r.tokenRegExpEnding.exec(M),B=L?L[0].length:1;r.lastTrigger=I&&I-B,r.textareaRef.value=R,r.textareaRef.selectionEnd=I,r._changeHandler();var _=r.textareaRef.scrollTop;r.setCaretPosition(I),window.chrome&&(r.textareaRef.scrollTop=_)})}},r._getTextToReplace=function(l){var u=r.props.trigger[l];if(!l||!u)return null;var d=u.output;return function(h){if(typeof h=="object"&&(!d||typeof d!="function"))throw new Error('Output functor is not defined! If you are using items as object you have to define "output" function. https://github.com/webscopeio/react-textarea-autocomplete#trigger-type');if(d){var p=d(h,l);if(p===void 0||typeof p=="number")throw new Error(`Output functor should return string or object in shape {text: string, caretPosition: string | number}.
|
|
|
Got "`.concat(String(p),'". Check the implementation for trigger "').concat(l,`"
|
|
|
|
|
|
See https://github.com/webscopeio/react-textarea-autocomplete#trigger-type for more information.
|
|
|
`));if(p===null)return null;if(typeof p=="string")return{text:p,caretPosition:y3};if(!p.text&&typeof p.text!="string")throw new Error('Output "text" is not defined! Object should has shape {text: string, caretPosition: string | number}. Check the implementation for trigger "'.concat(l,`"
|
|
|
`));if(!p.caretPosition)throw new Error('Output "caretPosition" is not defined! Object should has shape {text: string, caretPosition: string | number}. Check the implementation for trigger "'.concat(l,`"
|
|
|
`));return p}if(typeof h!="string")throw new Error(`Output item should be string
|
|
|
`);return{text:"".concat(l).concat(h).concat(l),caretPosition:y3}}},r._getCurrentTriggerSettings=function(){var l=r.state.currentTrigger;return l?r.props.trigger[l]:null},r._getValuesFromProvider=function(){var l=r.state,u=l.currentTrigger,d=l.actualToken,h=r._getCurrentTriggerSettings();if(!(!u||!h)){var p=h.dataProvider,m=h.component;if(typeof p!="function")throw new Error("Trigger provider has to be a function!");r.setState({dataLoading:!0});var b=p(d);b instanceof Promise||(b=Promise.resolve(b)),b.then(function(v){if(!Array.isArray(v))throw new Error("Trigger provider has to provide an array!");if(typeof m!="function")throw new Error("Component should be defined!");if(u===r.state.currentTrigger){if(!v.length){r._closeAutocomplete();return}r.setState({dataLoading:!1,data:v,component:m})}}).catch(function(v){return b3(v.message)})}},r._getSuggestions=function(){var l=r.state,u=l.currentTrigger,d=l.data;return!u||!d||d&&!d.length?null:d},r._createRegExp=function(){var l=r.props.trigger;r.tokenRegExp=new RegExp("(".concat(Object.keys(l).sort(function(u,d){return u<d?1:u>d?-1:0}).map(function(u){return qy(u)}).join("|"),")((?:(?!\\1)[^\\s])*$)")),r.tokenRegExpEnding=new RegExp("(".concat(Object.keys(l).sort(function(u,d){return u<d?1:u>d?-1:0}).map(function(u){return qy(u)}).join("|"),")$"))},r._closeAutocomplete=function(){var l=r.state.currentTrigger;r.escListenerDestroy(),r.setState({data:null,dataLoading:!1,currentTrigger:null},function(){l&&r._onItemHighlightedHandler(null)})},r._cleanUpProps=function(){var l=Sne({},r.props),u=["loadingComponent","boundariesElement","containerStyle","minChar","scrollToItem","ref","innerRef","onChange","onCaretPositionChange","className","value","trigger","listStyle","itemStyle","containerStyle","loaderStyle","className","containerClassName","listClassName","itemClassName","loaderClassName","dropdownStyle","dropdownClassName","movePopupAsYouType","textAreaComponent","renderToBody","onItemSelected","onItemHighlighted"];for(var d in l)u.includes(d)&&delete l[d];return l},r._changeHandler=function(l){var u=r.props,d=u.trigger,h=u.onChange,p=u.minChar,m=u.onCaretPositionChange,b=u.movePopupAsYouType,v=r.state,y=v.top,S=v.left,x=l;x||(x=new bne("change",{bubbles:!0}),r.textareaRef.dispatchEvent(x));var C=x.target||r.textareaRef,k=C.selectionEnd,M=C.value;if(r.lastValueBubbledEvent=M,h&&x&&(x.persist&&x.persist(),h(new Proxy(x,{get:function(Z,q,$){return q==="target"?C:Reflect.get(Z,q,$)}}))),m){var I=r.getCaretPosition();m(I)}r.setState({value:M});var O=function(){var Z=gne(C,k),q=Z.top,$=Z.left;r.setState({top:q-r.textareaRef.scrollTop||0,left:$})},R=function(Z){r.lastTrigger=k-Z,r._closeAutocomplete(),O()};if(k<=r.lastTrigger){var L=M.slice(0,k),B=r.tokenRegExp.exec(L);R(B?B[0].length:0)}var _=M.slice(r.lastTrigger,k),H=r.tokenRegExp.exec(_),U=H&&H[0],G=H&&H[1]||null,K=G?G.length-1:0,z=r.tokenRegExpEnding.exec(_);if(z?R(z[0].length):r._isAutocompleteOpen()||r._closeAutocomplete(),(!U||U.length<=p+K)&&(r.state.currentTrigger&&!d[r.state.currentTrigger].allowWhitespace||!r.state.currentTrigger)){r._closeAutocomplete();return}if(G&&d[G].afterWhitespace&&!/\s/.test(M[k-U.length-1])&&M[k-U.length-1]!==void 0){r._closeAutocomplete();return}if(r.state.currentTrigger&&d[r.state.currentTrigger].allowWhitespace){if(H=new RegExp("".concat(qy(r.state.currentTrigger),".*$")).exec(M.slice(0,k)),U=H&&H[0],!U){r._closeAutocomplete();return}G=Object.keys(d).find(function(ee){return ee.slice(0,K+1)===U.slice(0,K+1)})||null}var ne=U.slice(1);if(G){(b||y===null&&S===null||r.state.currentTrigger!==G)&&O(),r.escListenerInit();var J=r._getTextToReplace(G);r.setState({selectionEnd:k,currentTrigger:G,textToReplace:J,actualToken:ne},function(){try{r._getValuesFromProvider()}catch(ee){b3(ee.message)}})}},r._selectHandler=function(l){var u=r.props,d=u.onCaretPositionChange,h=u.onSelect;if(d){var p=r.getCaretPosition();d(p)}h&&(l.persist(),h(l))},r._shouldStayOpen=function(l){var u=l.relatedTarget;return u===null&&(u=document.activeElement),!!(r.dropdownRef&&u instanceof Node&&r.dropdownRef.contains(u))},r._onClick=function(l){var u=r.props.onClick;u&&(l.persist(),u(l)),!r._shouldStayOpen(l)&&r._closeAutocomplete()},r._onBlur=function(l){var u=r.props.onBlur;u&&(l.persist(),u(l)),!r._shouldStayOpen(l)&&r._closeAutocomplete()},r._onScrollHandler=function(){r._closeAutocomplete()},r._onItemHighlightedHandler=function(l){var u=r.props.onItemHighlighted,d=r.state.currentTrigger;if(u)if(typeof u=="function")u({currentTrigger:d,item:l});else throw new Error("`onItemHighlighted` has to be a function")},r._dropdownScroll=function(l){var u=r.props.scrollToItem;if(u){if(u===!0){Ane(r.dropdownRef,l);return}if(typeof u!="function"||u.length!==2)throw new Error("`scrollToItem` has to be boolean (true for default implementation) or function with two parameters: container, item.");u(r.dropdownRef,l)}},r._isAutocompleteOpen=function(){var l=r.state,u=l.dataLoading,d=l.currentTrigger,h=r._getSuggestions();return!!((u||h)&&d)},r._textareaRef=function(l){r.props.innerRef&&r.props.innerRef(l),r.textareaRef=l},r.lastTrigger=0,r.escListener=null;var o=r.props,i=o.loadingComponent,a=o.trigger,s=o.value;if(s&&(r.state.value=s),r._createRegExp(),!i)throw new Error("RTA: loadingComponent is not defined");if(!a)throw new Error("RTA: trigger is not defined");return r}return bS(t,[{key:"componentDidMount",value:function(){wu.startListen(this.textareaRef),this.textareaRef&&this.textareaRef.addEventListener("focus",this._handleCaretChange),this.textareaRef&&this.textareaRef.addEventListener("click",this._handleCaretChange),this.textareaRef&&this.textareaRef.addEventListener("keydown",this._handleCaretChange)}},{key:"componentDidUpdate",value:function(r){var o=r.trigger,i=r.value,a=this.props,s=a.trigger,l=a.value;Object.keys(s).join("")!==Object.keys(o).join("")&&this._createRegExp(),i!==l&&this.lastValueBubbledEvent!==l&&(this.lastTrigger=0,this._changeHandler())}},{key:"componentWillUnmount",value:function(){this.escListenerDestroy(),wu.stopListen(this.textareaRef),this.textareaRef&&this.textareaRef.removeEventListener("focus",this._handleCaretChange),this.textareaRef&&this.textareaRef.removeEventListener("click",this._handleCaretChange),this.textareaRef&&this.textareaRef.removeEventListener("keydown",this._handleCaretChange)}},{key:"render",value:function(){var r=this,o=this.props,i=o.loadingComponent,a=o.style,s=o.className,l=o.listStyle,u=o.itemStyle,d=o.boundariesElement,h=o.movePopupAsYouType,p=o.listClassName,m=o.itemClassName,b=o.dropdownClassName,v=o.dropdownStyle,y=o.containerStyle,S=o.containerClassName,x=o.loaderStyle,C=o.loaderClassName,k=o.textAreaComponent,M=o.renderToBody,I=this.state,O=I.left,R=I.top,L=I.dataLoading,B=I.component,_=I.value,H=I.textToReplace,U=this._isAutocompleteOpen(),G=this._getSuggestions(),K={},z;return k.component?(z=k.component,K[k.ref]=this._textareaRef):(z=k,K.ref=this._textareaRef),Y.createElement("div",{className:"rta ".concat(L===!0?"rta--loading":""," ").concat(S||""),style:y},Y.createElement(z,Object.assign({},this._cleanUpProps(),{className:"rta__textarea ".concat(s||""),onChange:this._changeHandler,onSelect:this._selectHandler,onScroll:this._onScrollHandler,onClick:this._onClick,onBlur:this._onBlur,value:_,style:a},K)),U&&Y.createElement(One,{innerRef:function(J){r.dropdownRef=J},top:R,left:O,style:v,className:b,movePopupAsYouType:h,boundariesElement:d,textareaRef:this.textareaRef,renderToBody:M},G&&B&&H&&Y.createElement(Dne,{values:G,component:B,style:l,className:p,itemClassName:m,itemStyle:u,getTextToReplace:H,onItemHighlighted:this._onItemHighlightedHandler,onSelect:this._onSelect,dropdownScroll:this._dropdownScroll}),L&&Y.createElement("div",{className:"rta__loader ".concat(G!==null?"rta__loader--suggestion-data":"rta__loader--empty-suggestion-data"," ").concat(C||""),style:x},Y.createElement(i,{data:G}))))}}],[{key:"getDerivedStateFromProps",value:function(r){var o=r.value;return o==null?null:{value:o}}}]),t}(Y.Component);kH.defaultProps={movePopupAsYouType:!1,value:null,minChar:1,boundariesElement:"body",scrollToItem:!0,textAreaComponent:"textarea",renderToBody:!1};const Pne=()=>{const{app:e}=$e.getState(),t=e.metadataCache.getTags();return[...Object.keys(t)].map(n=>n.split("#").pop())},jne=e=>{let t=[];const n=$e.getState().settings;if(n&&n?.UseVaultTags)t=Pne();else{const{tags:i}=de.getState();t=i}const r=e.toLowerCase(),o=[];return t.forEach(i=>{i&&i.toLowerCase().contains(r)&&o.push({name:i,char:i})}),o},Lne=e=>{const{app:t}=$e.getState(),n=t.vault.getAllLoadedFiles(),r=[];let o;return n.forEach(i=>{e==="["?o="":e.contains("[")&&(o=e.slice(1));const a=o.toLowerCase();i instanceof N.TFile&&["md","png","jpg","canvas","jpeg","gif"].contains(i.extension)&&i.path.toLowerCase().contains(a)&&r.push({name:i.basename,char:i.name,file:i})}),r};var Hx=D,Rne=function(e){return typeof e=="function"},Fne=function(e){var t=Hx.useState(e),n=t[0],r=t[1],o=Hx.useRef(n),i=Hx.useCallback(function(a){o.current=Rne(a)?a(o.current):a,r(o.current)},[]);return[n,i,o]},Hne=Fne;const Ho=tt(Hne);function td(e){return new Promise((t,n)=>{e.oncomplete=e.onsuccess=()=>t(e.result),e.onabort=e.onerror=()=>n(e.error)})}function TS(e,t){const n=indexedDB.open(e);n.onupgradeneeded=()=>n.result.createObjectStore(t);const r=td(n);return(o,i)=>r.then(a=>i(a.transaction(t,o).objectStore(t)))}let _x;function ov(){return _x||(_x=TS("keyval-store","keyval")),_x}function al(e,t=ov()){return t("readonly",n=>td(n.get(e)))}function hl(e,t,n=ov()){return n("readwrite",r=>(r.put(t,e),td(r.transaction)))}function EH(e,t=ov()){return t("readwrite",n=>(n.delete(e),td(n.transaction)))}function _ne(e=ov()){return e("readwrite",t=>(t.clear(),td(t.transaction)))}function Bne(e,t){return e.openCursor().onsuccess=function(){this.result&&(t(this.result),this.result.continue())},td(e.transaction)}function CH(e=ov()){return e("readonly",t=>{if(t.getAllKeys)return td(t.getAllKeys());const n=[];return Bne(t,r=>n.push(r.key)).then(()=>n)})}const x0=TS("editor-history-db","editor-history-store"),Yne=50;function lD(e,t){return`thinoEditorHistory:${e}:${t||"view"}`}async function Une(e,t,n){try{const r=lD(t?.appId,n),o=await al(r,x0)||[];if(o.some(l=>l.content===e))return;const s=[{content:e,timestamp:Date.now()},...o].slice(0,Yne);await hl(r,s,x0)}catch(r){console.error("Failed to save editor history:",r)}}const zne=N.debounce((e,t,n)=>{Une(e,t,n)},1e3);async function MH(e,t){try{const n=lD(e?.appId,t);return await al(n,x0)||[]}catch(n){return console.error("Failed to get editor history:",n),[]}}async function Vne(e,t){try{const n=lD(e?.appId,t);await EH(n,x0)}catch(n){console.error("Failed to clear editor history:",n)}}function Wne(e){return e.containerEl.matches(".memos-list-view")}function Bx(){}function Gne(e){const n=e.app.workspace.getLeavesOfType("thino_view")[0];return{app:e.app,showSearch:Bx,toggleMode:Bx,onMarkdownScroll:Bx,getMode:()=>"source",getViewType:()=>"thino_view",id:n?.id||Le.randomId(6),scroll:0,editMode:null,get file(){return n?.view?.file||null},get path(){return n?.view?.file?.path||""}}}const Zne=(e,t)=>{const{dailyNotesState:{app:n,plugin:r,view:o,dailyNotes:i}}=D.useContext(ct),[a,s]=D.useState(null),[l,u]=D.useState(!1),[d,h]=D.useState(""),[p,m]=D.useState(null),[b,v]=D.useState(!0),[y,S]=D.useState(!1),x=D.useRef(null),C=D.useRef(N.debounce(async(G,K,z)=>{w3(G,K,z),G.trim()&&!y&&await zne(G,K,z)},100)),k=D.useRef();D.useEffect(()=>{if(!p){if(!i&&!(n&&window.app)){const G=(n||window.app)?.vault.getMarkdownFiles();m(G[0]);return}for(const G in i)if(i[G]instanceof N.TFile){m(i[G]);break}}},[i]),D.useEffect(()=>{if(!r?.MarkdownEditor||!e)return;class G extends r.MarkdownEditor{updateBottomPadding(){}onUpdate(Z,q){super.onUpdate(Z,q),I&&I(this.get())}}const K=Gne(r),z=r.addChild(new G(n,e,K));z&&!t&&o&&Ze.setInstance(`${o.leaf?.id}`,z),K.editMode=z,z.owner.editor=z.editor;const ne=$ne(n,t?"modal":"view");z.set&&z.set(ne||"",!0),n.workspace.trigger("thino-editor-created",e,z.editor);const J=z.cm;return k.current=J,u(!0),s(z),()=>{u(!1),a?.destroy(),r.removeChild(z),k.current=null}},[e,r]),D.useEffect(()=>{!a||!n||(C.current(d,n,t?"modal":"view"),b&&v(!1),x.current&&x.current(d))},[d,n]);const M=()=>{a&&a.toggleSource()},I=N.debounce(G=>O(G),500,!0),O=G=>{h(G)};return{instance:a,value:d,set:G=>{try{a&&((a?.editor).replaceSelection(G),h(G))}catch(K){console.error(K)}},get:()=>a?a.get():"",append:(G,K)=>{if(!a||K&&K!==o?.leaf?.id)return;const ne=(a.get()||"")+G;(a?.editor).replaceSelection(G),h(ne)},clear:async(G=!1)=>{a&&(a.clear(),h(""),w3("",n,t?"modal":"view"),G&&await Vne(n,t?"modal":"view"))},toggleSource:M,getHistoryEntries:async()=>!a||!n?[]:await MH(n,t?"modal":"view"),setFullContent:(G,K=!1)=>{a&&(S(K),a.set(G),C.current(G,n,t?"modal":"view"),S(!1))}}};function DH(e,t){return`thinoEditorContentCache:${e}:${t||"view"}`}function $ne(e,t){try{const n=DH(e?.appId,t);return ur.get([n])[n]||""}catch(n){return console.error(n),""}}function w3(e,t,n){try{const r=DH(t?.appId,n);ur.set({[r]:e})}catch(r){console.error(r)}}const qne=D.memo(({value:e,maxCount:t=100})=>{const[n,r]=D.useState(0);D.useEffect(()=>{const i=e.replace(/```[^\S\r\n]*[a-z]*\n.*?\n```/g,""),a=Le.getWordCount(i);r(a)},[e]);const o=n>t&&t>0;return w.jsxs("div",{className:tn("thino-editor-word-count",o&&"exceeded"),children:[n," ",t>0&&w.jsxs("span",{children:[" / ",t]})," ",E("word")]})},(e,t)=>e.value===t.value&&e.maxCount===t.maxCount);function Kne(e,t){return{line:e.line,ch:e.ch+t}}const S3=({entity:{name:e,char:t,file:n}})=>w.jsx("div",{children:`${t}`}),Xne=({data:e})=>w.jsx("div",{children:"Loading"});let za;const Jne=D.forwardRef((e,t)=>{const{globalState:{useTinyUndoHistoryCache:n,globalEditorShown:r,memoListView:o},dailyNotesState:{settings:i,app:a}}=D.useContext(ct),{SaveMemoButtonLabel:s,SaveMemoButtonIcon:l}=i,{className:u,inputerType:d,initialContent:h,placeholder:p,showConfirmBtn:m,showCancelBtn:b,onConfirmBtnClick:v,onCancelBtnClick:y,onContentChange:S,onCheckCount:x}=e,C=D.useRef(null),k=D.useRef(null),M=D.useRef(null),I=pne(),{instance:O,value:R,set:L,get:B,append:_,clear:H,toggleSource:U,setFullContent:G}=Zne(k.current,e.modal),[,K,z]=Ho(0),[ne,J]=Ho(!1);D.useEffect(()=>{if(i&&i.FocusOnEditor)switch(d){case"minimal":case"memos":C.current?.focus();break;case"obsidian":O&&O.editor?.focus()}},[i,O]),D.useEffect(()=>{if(!a)return;const fe=a.workspace.getLeavesOfType(Qr);let ye,ge;fe.length>0?(ge=fe[0].view.containerEl,ye=ge.offsetHeight):(ge=document,ye=window.outerHeight),K(ye)},[a]),D.useEffect(()=>{!C.current||d==="obsidian"||h&&(C.current.value=h,I())},[]),D.useEffect(()=>{if(d!=="obsidian")if(n){if(!C.current)return;const{tinyUndoActionsCache:fe,tinyUndoIndexCache:ye}=ur.get(["tinyUndoActionsCache","tinyUndoIndexCache"]);return M.current=new hne(C.current,{interval:5e3,initialActions:fe,initialIndex:ye}),M.current.subscribe((ge,me)=>{ur.set({tinyUndoActionsCache:ge,tinyUndoIndexCache:me})}),()=>{M.current?.destroy()}}else M.current?.destroy(),M.current=null,ur.remove(["tinyUndoActionsCache","tinyUndoIndexCache"])},[n]),D.useEffect(()=>{C.current&&(C.current.style.height="auto",C.current.style.height=(C.current.scrollHeight??0)+"px")},[C.current?.value]),D.useImperativeHandle(t,()=>({element:C.current,blur:()=>{switch(d){case"minimal":case"memos":C.current?.blur();break;case"obsidian":O&&O.editor?.blur()}},focus:fe=>{switch(d){case"minimal":case"memos":C.current?.focus();break;case"obsidian":if(O){if(fe&&fe!==O?.owner?.view?.leaf?.id)return;O.editor?.focus()}}},insertTag:fe=>{switch(d){case"minimal":case"memos":{if(!C.current)return;const ye=C.current.value;C.current.value=ye.slice(0,C.current.selectionStart)+"# "+ye.slice(C.current.selectionStart),S(C.current.value),I();break}case"obsidian":if(fe&&fe!==O?.owner?.view?.leaf?.id)return;if(O){const ye=O.editor,ge=ye.getCursor("from");ye.replaceRange("#",ge),ye.setSelection(Kne(ge,1))}break}},insertText:(fe,ye)=>{switch(d){case"minimal":case"memos":{if(!C.current)return;const ge=C.current.value;C.current.value=ge.slice(0,C.current.selectionStart)+fe+ge.slice(C.current.selectionStart),S(C.current.value),I()}break;case"obsidian":O&&_(fe,ye);break}},setContent:fe=>{switch(d){case"minimal":case"memos":C.current&&(C.current.value=fe,S(C.current.value),I());break;case"obsidian":O&&L(fe);break}},updateContent:fe=>{switch(d){case"minimal":case"memos":C.current&&(C.current.value=fe);break;case"obsidian":O&&G(fe);break}},getContent:()=>{switch(d){case"minimal":case"memos":return C.current?C.current.value:"";case"obsidian":return B()}},toggleSource:()=>{switch(d){case"minimal":case"memos":break;case"obsidian":U();break}},clear:(fe=!1)=>{switch(d){case"minimal":case"memos":C.current&&(C.current.value="",S(C.current.value),I());break;case"obsidian":H(fe);break}}}),[O,d]);const ee=fe=>{if(!C.current)return;const{fileManager:ye}=ke.getState().dailyNotesState.app;if(fe.currentTrigger==="#"){const ge=C.current.value;let me;za!=null?me=za.length:me=0;let Ce=C.current.selectionStart;for(let je=0;je<ge.length;je++)/\s/g.test(ge[Ce])||Ce++;C.current.value=ge.slice(0,C.current.selectionStart-me)+fe.item.char+ge.slice(Ce),S(C.current.value),I()}else if(fe.currentTrigger==="[["){const ge=ye.generateMarkdownLink(fe.item.file,fe.item.file.path,"",""),me=C.current.value;let Ce;za!=null?ge.contains("[[")||fe.item.file.extension!=="md"?Ce=za.length+1:Ce=za.length+2:Ce=2;let je=C.current.selectionStart;for(let Ie=0;Ie<me.length;Ie++)/\s/g.test(me[je])||je++;C.current.value=me.slice(0,C.current.selectionStart-Ce)+ge+me.slice(je),S(C.current.value),I()}},Z=D.useCallback(()=>{S(C.current?.value||""),I()},[]),q=async()=>{switch(d){case"minimal":case"memos":if(!C.current)return;C.current.value=re(),v(C.current.value),C.current.value="",I(),M.current?.resetState();break;case"obsidian":await x(B())?(v(B()),H(!0),I()):new Notice(E("Word count exceeded"));break}},$=D.useCallback(()=>{switch(d){case"minimal":case"memos":C.current&&(C.current.value="",S(C.current.value),I());break;case"obsidian":H(!1);break}y()},[d,O,C]),re=()=>ur.get(["thinoEditorContentCache"]).thinoEditorContentCache||"",le=()=>{if(C.current)return C.current.value=re(),C.current.value},ie=fe=>{switch(fe){case"memos":return w.jsx(kH,{className:`common-editor-inputer scroll ${ne?" editing":""}`,loadingComponent:Xne,placeholder:p,movePopupAsYouType:!0,value:le(),innerRef:ye=>{C.current=ye},onFocus:()=>{J(!0)},onBlur:()=>{J(!1)},onInput:Z,style:{maxHeight:`${z.current>400?z.current-400:100}px`},dropdownStyle:{minWidth:180,maxHeight:250,overflowY:"auto"},minChar:0,onItemSelected:ee,scrollToItem:!0,trigger:{"#":{dataProvider:ye=>(za=ye,jne(ye).map(({name:ge,char:me})=>({name:ge,char:me}))),component:S3,afterWhitespace:!0,output:ye=>ye.char},"[[":{dataProvider:ye=>(za=ye,Lne(ye).slice(0,10).map(({name:ge,char:me,file:Ce})=>({name:ge,char:me,file:Ce}))),component:S3,afterWhitespace:!0,output:ye=>ye.char}}});case"minimal":return w.jsx("textarea",{style:{minHeight:48},className:"common-editor-inputer scroll",rows:1,placeholder:p,ref:C,onInput:Z});case"obsidian":return w.jsx("div",{className:"common-editor-inputer common-editor-mod-cm6",onClick:()=>{O?.editor?.focus()},ref:k});default:return w.jsx("div",{className:"common-editor-inputer common-editor-mod-cm6",ref:k})}};return w.jsxs("div",{className:"common-editor-wrapper "+u,children:[ie(d),w.jsxs("div",{className:"common-tools-wrapper",children:[w.jsx("div",{className:"common-tools-container",children:w.jsx(il,{when:e.tools!==void 0,children:e.tools})}),w.jsxs("div",{className:"btns-container",children:[i.enableWordCount&&w.jsx(qne,{value:R,maxCount:i.maxWordCount}),w.jsx(il,{when:b,children:w.jsx("button",{className:"action-btn cancel-btn",onClick:()=>{i&&i.DefaultEditorLocation==="Top"&&!r&&$()},onPointerDown:()=>{(i&&i.DefaultEditorLocation==="Bottom"||r)&&$()},children:Ue.getState().pathname==="/"&&o==="chat"&&(i?.chatViewStyle==="fluent"||i?.chatViewStyle==="inline")?"":E("CANCEL EDIT")})}),w.jsx(il,{when:m,children:w.jsxs("button",{"aria-label":E("Ctrl/Cmd + Enter to save thino"),className:"action-btn confirm-btn",onClick:async()=>{i&&i.DefaultEditorLocation==="Top"&&!r&&await q()},onPointerDown:async()=>{(i&&i.DefaultEditorLocation==="Bottom"||r)&&await q()},children:[o==="chat"&&(i?.chatViewStyle==="fluent"||i?.chatViewStyle==="inline")?"":s,w.jsx("span",{className:"icon-text",children:null})]})})]})]})]})}),Qne=typeof window<"u"?D.useLayoutEffect:D.useEffect;function ere(e,t,n,r){const o=D.useRef(t);Qne(()=>{o.current=t},[t]),D.useEffect(()=>{const i=n?.current||window;if(!(i&&i.addEventListener))return;const a=s=>{o.current(s)};return i.addEventListener(e,a,r),()=>{i.removeEventListener(e,a,r)}},[e,n,r])}function iv(e,t,n="mousedown"){ere(n,r=>{const o=r.target;if(!o||!o.isConnected||o.closest(".suggestion-container")||o.closest(".menu"))return;(Array.isArray(e)?e.every(a=>a.current&&!a.current.contains(o)):e.current&&!e.current.contains(o))&&t(r)})}const AH=e=>{const{year:t,handleYearChange:n}=e,[r,o]=D.useState([]),[i,a]=D.useState(t),s=D.useRef(null),l=D.useRef(null),[u,d]=Y.useState(!1),h=Y.useRef(null);iv(h,()=>{d(!1)}),D.useEffect(()=>{s.current&&N.setIcon(s.current,"chevron-left"),l.current&&N.setIcon(l.current,"chevron-right")},[s,l,u]),D.useEffect(()=>{m(i)},[t]);const m=b=>{const v=parseInt(b),y=v-v%10,S=[];for(let x=0;x<10;x++)S.push(`${y+x}`);o(S)};return w.jsxs(w.Fragment,{children:[w.jsxs("span",{className:"btn year-btn",onClick:()=>{d(!u)},children:[w.jsx("span",{children:t}),w.jsx("span",{children:E("year")})]}),u&&w.jsxs("div",{ref:h,className:"year-picker-wrapper",children:[w.jsxs("div",{className:"year-picker-header",children:[w.jsxs("div",{className:"year-picker-header-title",children:[i," "+(E("year")||"")]}),w.jsxs("div",{className:"year-picker-header-btns",children:[w.jsx("span",{className:"btn",ref:s,onClick:()=>{const b=parseInt(i)-10;a(b.toString()),m(b.toString())}}),w.jsx("span",{className:"btn",ref:l,onClick:()=>{const b=parseInt(i)+10;a(b.toString()),m(b.toString())}})]})]}),w.jsx("div",{className:"year-picker-body",children:w.jsx("div",{className:"year-picker-body-list",children:r.map(b=>w.jsx("div",{className:`year-picker-body-item ${b===i?"selected":""}`,onClick:()=>{a(b),n(b),d(!1)},children:b},b))})})]})]})},NH=e=>{const{month:t,handleMonthChange:n}=e,[r,o]=D.useState([]),[i,a]=D.useState((parseInt(t)+1).toString()),[s,l]=Y.useState(!1),u=Y.useRef(null);iv(u,()=>{l(!1)}),D.useEffect(()=>{h()},[t]);const h=()=>{const p=[];for(let m=1;m<=12;m++)p.push(`${m}`);o(p)};return w.jsxs(w.Fragment,{children:[w.jsxs("span",{className:"btn month-btn",onClick:()=>{l(!s)},children:[w.jsxs("span",{children:[E("monthsShort")[parseInt(t)]||parseInt(t)+1," "]}),w.jsx("span",{children:E("month")||""})]}),s&&w.jsxs("div",{ref:u,className:"month-picker-wrapper",children:[w.jsxs("div",{className:"month-picker-header",children:[w.jsxs("div",{className:"month-picker-header-title",children:[i," "+(E("month")||"")]}),w.jsx("div",{className:"month-picker-header-btns"})]}),w.jsx("div",{className:"month-picker-body",children:w.jsx("div",{className:"month-picker-body-list",children:r.map(p=>w.jsx("div",{className:`month-picker-body-item ${p===i?"selected":""}`,onClick:()=>{a(p),n(p),l(!1)},children:p},p))})})]})]})},xS=e=>{const{className:t,datestamp:n,handleDateStampChange:r}=e,[o,i]=D.useState(Np(n)),[a,s]=D.useState(n);D.useEffect(()=>{i(Np(n))},[n]);const l=new Date(o),u=l.getDay(),d=[];for(let b=0;b<u;b++)d.push({date:0,datestamp:l.getTime()-Uo*(7-b)});const h=tre(o);for(let b=1;b<=h;b++)d.push({date:b,datestamp:l.getTime()+Uo*(b-1)});const p=(b,v)=>{r(v,b.nativeEvent),s(v)},m=b=>{const v=l.getFullYear(),y=l.getMonth()+1;let S=0;y===1&&b===-1?S=new Date(`${v-1}/12/1`).getTime():y===12&&b===1?S=new Date(`${v+1}/1/1`).getTime():S=new Date(`${v}/${y+b}/1`).getTime(),i(Np(S))};return w.jsxs("div",{className:`date-picker-wrapper ${t}`,children:[w.jsxs("div",{className:"date-picker-header",children:[w.jsx("span",{ref:b=>{b&&N.setIcon(b,"chevron-left")},className:"btn btn-text",onClick:()=>m(-1)}),w.jsxs("span",{className:"normal-text",children:[w.jsx(AH,{year:l.getFullYear().toString(),handleYearChange:b=>{i(Np(new Date(`${b}/${l.getMonth()+1}/1`).getTime()))}}),w.jsx(NH,{month:l.getMonth().toString(),handleMonthChange:b=>{i(Np(new Date(`${l.getFullYear()}/${parseInt(b)}/1`).getTime()))}})]}),w.jsx("span",{ref:b=>{b&&N.setIcon(b,"chevron-right")},className:"btn btn-text",onClick:()=>m(1)})]}),w.jsxs("div",{className:"date-picker-day-container",children:[w.jsx("div",{className:"date-picker-day-header",children:E("weekDaysShort").map(b=>w.jsx("span",{className:"day-item",children:b},b))}),w.jsx("div",{className:"date-picker-day-content",children:d.map(b=>b.date===0?w.jsx("span",{className:"day-item null",children:""},b.datestamp):w.jsx("span",{className:`day-item ${b.datestamp===n?"current":""} ${b.datestamp===a?"selected":""}`,onClick:v=>p(v,b.datestamp),children:w.jsx("span",{className:"day-item-text",children:b.date})},b.datestamp))})]})]})};function tre(e){const t=new Date(e),n=new Date(`${t.getFullYear()}/${t.getMonth()+1}/1`);return((n.getMonth()===11?new Date(`${n.getFullYear()+1}/1/1`):new Date(`${n.getFullYear()}/${n.getMonth()+2}/1`)).getTime()-n.getTime())/Uo}function Np(e){const t=new Date(e);return new Date(`${t.getFullYear()}/${t.getMonth()+1}/1`).getTime()}var T3=function(t){return t.reduce(function(n,r){var o=r[0],i=r[1];return n[o]=i,n},{})},x3=typeof window<"u"&&window.document&&window.document.createElement?D.useLayoutEffect:D.useEffect,zo="top",_i="bottom",Bi="right",Vo="left",cD="auto",av=[zo,_i,Bi,Vo],kf="start",Rm="end",nre="clippingParents",OH="viewport",Op="popper",rre="reference",I3=av.reduce(function(e,t){return e.concat([t+"-"+kf,t+"-"+Rm])},[]),uD=[].concat(av,[cD]).reduce(function(e,t){return e.concat([t,t+"-"+kf,t+"-"+Rm])},[]),ore="beforeRead",ire="read",are="afterRead",sre="beforeMain",lre="main",cre="afterMain",ure="beforeWrite",dre="write",fre="afterWrite",hre=[ore,ire,are,sre,lre,cre,ure,dre,fre];function bs(e){return e?(e.nodeName||"").toLowerCase():null}function hi(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Ru(e){var t=hi(e).Element;return e instanceof t||e instanceof Element}function ji(e){var t=hi(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function dD(e){if(typeof ShadowRoot>"u")return!1;var t=hi(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function pre(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},i=t.elements[n];!ji(i)||!bs(i)||(Object.assign(i.style,r),Object.keys(o).forEach(function(a){var s=o[a];s===!1?i.removeAttribute(a):i.setAttribute(a,s===!0?"":s)}))})}function mre(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],i=t.attributes[r]||{},a=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),s=a.reduce(function(l,u){return l[u]="",l},{});!ji(o)||!bs(o)||(Object.assign(o.style,s),Object.keys(i).forEach(function(l){o.removeAttribute(l)}))})}}const gre={name:"applyStyles",enabled:!0,phase:"write",fn:pre,effect:mre,requires:["computeStyles"]};function ds(e){return e.split("-")[0]}var Mu=Math.max,I0=Math.min,Ef=Math.round;function iE(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function PH(){return!/^((?!chrome|android).)*safari/i.test(iE())}function Cf(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,i=1;t&&ji(e)&&(o=e.offsetWidth>0&&Ef(r.width)/e.offsetWidth||1,i=e.offsetHeight>0&&Ef(r.height)/e.offsetHeight||1);var a=Ru(e)?hi(e):window,s=a.visualViewport,l=!PH()&&n,u=(r.left+(l&&s?s.offsetLeft:0))/o,d=(r.top+(l&&s?s.offsetTop:0))/i,h=r.width/o,p=r.height/i;return{width:h,height:p,top:d,right:u+h,bottom:d+p,left:u,x:u,y:d}}function fD(e){var t=Cf(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function jH(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&dD(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function pl(e){return hi(e).getComputedStyle(e)}function vre(e){return["table","td","th"].indexOf(bs(e))>=0}function Ic(e){return((Ru(e)?e.ownerDocument:e.document)||window.document).documentElement}function IS(e){return bs(e)==="html"?e:e.assignedSlot||e.parentNode||(dD(e)?e.host:null)||Ic(e)}function k3(e){return!ji(e)||pl(e).position==="fixed"?null:e.offsetParent}function yre(e){var t=/firefox/i.test(iE()),n=/Trident/i.test(iE());if(n&&ji(e)){var r=pl(e);if(r.position==="fixed")return null}var o=IS(e);for(dD(o)&&(o=o.host);ji(o)&&["html","body"].indexOf(bs(o))<0;){var i=pl(o);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||t&&i.willChange==="filter"||t&&i.filter&&i.filter!=="none")return o;o=o.parentNode}return null}function sv(e){for(var t=hi(e),n=k3(e);n&&vre(n)&&pl(n).position==="static";)n=k3(n);return n&&(bs(n)==="html"||bs(n)==="body"&&pl(n).position==="static")?t:n||yre(e)||t}function hD(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function mm(e,t,n){return Mu(e,I0(t,n))}function bre(e,t,n){var r=mm(e,t,n);return r>n?n:r}function LH(){return{top:0,right:0,bottom:0,left:0}}function RH(e){return Object.assign({},LH(),e)}function FH(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var wre=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,RH(typeof t!="number"?t:FH(t,av))};function Sre(e){var t,n=e.state,r=e.name,o=e.options,i=n.elements.arrow,a=n.modifiersData.popperOffsets,s=ds(n.placement),l=hD(s),u=[Vo,Bi].indexOf(s)>=0,d=u?"height":"width";if(!(!i||!a)){var h=wre(o.padding,n),p=fD(i),m=l==="y"?zo:Vo,b=l==="y"?_i:Bi,v=n.rects.reference[d]+n.rects.reference[l]-a[l]-n.rects.popper[d],y=a[l]-n.rects.reference[l],S=sv(i),x=S?l==="y"?S.clientHeight||0:S.clientWidth||0:0,C=v/2-y/2,k=h[m],M=x-p[d]-h[b],I=x/2-p[d]/2+C,O=mm(k,I,M),R=l;n.modifiersData[r]=(t={},t[R]=O,t.centerOffset=O-I,t)}}function Tre(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||jH(t.elements.popper,o)&&(t.elements.arrow=o))}const HH={name:"arrow",enabled:!0,phase:"main",fn:Sre,effect:Tre,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Mf(e){return e.split("-")[1]}var xre={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Ire(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Ef(n*o)/o||0,y:Ef(r*o)/o||0}}function E3(e){var t,n=e.popper,r=e.popperRect,o=e.placement,i=e.variation,a=e.offsets,s=e.position,l=e.gpuAcceleration,u=e.adaptive,d=e.roundOffsets,h=e.isFixed,p=a.x,m=p===void 0?0:p,b=a.y,v=b===void 0?0:b,y=typeof d=="function"?d({x:m,y:v}):{x:m,y:v};m=y.x,v=y.y;var S=a.hasOwnProperty("x"),x=a.hasOwnProperty("y"),C=Vo,k=zo,M=window;if(u){var I=sv(n),O="clientHeight",R="clientWidth";if(I===hi(n)&&(I=Ic(n),pl(I).position!=="static"&&s==="absolute"&&(O="scrollHeight",R="scrollWidth")),o===zo||(o===Vo||o===Bi)&&i===Rm){k=_i;var L=h&&I===M&&M.visualViewport?M.visualViewport.height:I[O];v-=L-r.height,v*=l?1:-1}if(o===Vo||(o===zo||o===_i)&&i===Rm){C=Bi;var B=h&&I===M&&M.visualViewport?M.visualViewport.width:I[R];m-=B-r.width,m*=l?1:-1}}var _=Object.assign({position:s},u&&xre),H=d===!0?Ire({x:m,y:v},hi(n)):{x:m,y:v};if(m=H.x,v=H.y,l){var U;return Object.assign({},_,(U={},U[k]=x?"0":"",U[C]=S?"0":"",U.transform=(M.devicePixelRatio||1)<=1?"translate("+m+"px, "+v+"px)":"translate3d("+m+"px, "+v+"px, 0)",U))}return Object.assign({},_,(t={},t[k]=x?v+"px":"",t[C]=S?m+"px":"",t.transform="",t))}function kre(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,i=n.adaptive,a=i===void 0?!0:i,s=n.roundOffsets,l=s===void 0?!0:s,u={placement:ds(t.placement),variation:Mf(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,E3(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:a,roundOffsets:l})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,E3(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const _H={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:kre,data:{}};var Ky={passive:!0};function Ere(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,i=o===void 0?!0:o,a=r.resize,s=a===void 0?!0:a,l=hi(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return i&&u.forEach(function(d){d.addEventListener("scroll",n.update,Ky)}),s&&l.addEventListener("resize",n.update,Ky),function(){i&&u.forEach(function(d){d.removeEventListener("scroll",n.update,Ky)}),s&&l.removeEventListener("resize",n.update,Ky)}}const BH={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Ere,data:{}};var Cre={left:"right",right:"left",bottom:"top",top:"bottom"};function Ub(e){return e.replace(/left|right|bottom|top/g,function(t){return Cre[t]})}var Mre={start:"end",end:"start"};function C3(e){return e.replace(/start|end/g,function(t){return Mre[t]})}function pD(e){var t=hi(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function mD(e){return Cf(Ic(e)).left+pD(e).scrollLeft}function Dre(e,t){var n=hi(e),r=Ic(e),o=n.visualViewport,i=r.clientWidth,a=r.clientHeight,s=0,l=0;if(o){i=o.width,a=o.height;var u=PH();(u||!u&&t==="fixed")&&(s=o.offsetLeft,l=o.offsetTop)}return{width:i,height:a,x:s+mD(e),y:l}}function Are(e){var t,n=Ic(e),r=pD(e),o=(t=e.ownerDocument)==null?void 0:t.body,i=Mu(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),a=Mu(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),s=-r.scrollLeft+mD(e),l=-r.scrollTop;return pl(o||n).direction==="rtl"&&(s+=Mu(n.clientWidth,o?o.clientWidth:0)-i),{width:i,height:a,x:s,y:l}}function gD(e){var t=pl(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function YH(e){return["html","body","#document"].indexOf(bs(e))>=0?e.ownerDocument.body:ji(e)&&gD(e)?e:YH(IS(e))}function gm(e,t){var n;t===void 0&&(t=[]);var r=YH(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),i=hi(r),a=o?[i].concat(i.visualViewport||[],gD(r)?r:[]):r,s=t.concat(a);return o?s:s.concat(gm(IS(a)))}function aE(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Nre(e,t){var n=Cf(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function M3(e,t,n){return t===OH?aE(Dre(e,n)):Ru(t)?Nre(t,n):aE(Are(Ic(e)))}function Ore(e){var t=gm(IS(e)),n=["absolute","fixed"].indexOf(pl(e).position)>=0,r=n&&ji(e)?sv(e):e;return Ru(r)?t.filter(function(o){return Ru(o)&&jH(o,r)&&bs(o)!=="body"}):[]}function Pre(e,t,n,r){var o=t==="clippingParents"?Ore(e):[].concat(t),i=[].concat(o,[n]),a=i[0],s=i.reduce(function(l,u){var d=M3(e,u,r);return l.top=Mu(d.top,l.top),l.right=I0(d.right,l.right),l.bottom=I0(d.bottom,l.bottom),l.left=Mu(d.left,l.left),l},M3(e,a,r));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function UH(e){var t=e.reference,n=e.element,r=e.placement,o=r?ds(r):null,i=r?Mf(r):null,a=t.x+t.width/2-n.width/2,s=t.y+t.height/2-n.height/2,l;switch(o){case zo:l={x:a,y:t.y-n.height};break;case _i:l={x:a,y:t.y+t.height};break;case Bi:l={x:t.x+t.width,y:s};break;case Vo:l={x:t.x-n.width,y:s};break;default:l={x:t.x,y:t.y}}var u=o?hD(o):null;if(u!=null){var d=u==="y"?"height":"width";switch(i){case kf:l[u]=l[u]-(t[d]/2-n[d]/2);break;case Rm:l[u]=l[u]+(t[d]/2-n[d]/2);break}}return l}function Fm(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,i=n.strategy,a=i===void 0?e.strategy:i,s=n.boundary,l=s===void 0?nre:s,u=n.rootBoundary,d=u===void 0?OH:u,h=n.elementContext,p=h===void 0?Op:h,m=n.altBoundary,b=m===void 0?!1:m,v=n.padding,y=v===void 0?0:v,S=RH(typeof y!="number"?y:FH(y,av)),x=p===Op?rre:Op,C=e.rects.popper,k=e.elements[b?x:p],M=Pre(Ru(k)?k:k.contextElement||Ic(e.elements.popper),l,d,a),I=Cf(e.elements.reference),O=UH({reference:I,element:C,strategy:"absolute",placement:o}),R=aE(Object.assign({},C,O)),L=p===Op?R:I,B={top:M.top-L.top+S.top,bottom:L.bottom-M.bottom+S.bottom,left:M.left-L.left+S.left,right:L.right-M.right+S.right},_=e.modifiersData.offset;if(p===Op&&_){var H=_[o];Object.keys(B).forEach(function(U){var G=[Bi,_i].indexOf(U)>=0?1:-1,K=[zo,_i].indexOf(U)>=0?"y":"x";B[U]+=H[K]*G})}return B}function jre(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,i=n.rootBoundary,a=n.padding,s=n.flipVariations,l=n.allowedAutoPlacements,u=l===void 0?uD:l,d=Mf(r),h=d?s?I3:I3.filter(function(b){return Mf(b)===d}):av,p=h.filter(function(b){return u.indexOf(b)>=0});p.length===0&&(p=h);var m=p.reduce(function(b,v){return b[v]=Fm(e,{placement:v,boundary:o,rootBoundary:i,padding:a})[ds(v)],b},{});return Object.keys(m).sort(function(b,v){return m[b]-m[v]})}function Lre(e){if(ds(e)===cD)return[];var t=Ub(e);return[C3(e),t,C3(t)]}function Rre(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,i=o===void 0?!0:o,a=n.altAxis,s=a===void 0?!0:a,l=n.fallbackPlacements,u=n.padding,d=n.boundary,h=n.rootBoundary,p=n.altBoundary,m=n.flipVariations,b=m===void 0?!0:m,v=n.allowedAutoPlacements,y=t.options.placement,S=ds(y),x=S===y,C=l||(x||!b?[Ub(y)]:Lre(y)),k=[y].concat(C).reduce(function(le,ie){return le.concat(ds(ie)===cD?jre(t,{placement:ie,boundary:d,rootBoundary:h,padding:u,flipVariations:b,allowedAutoPlacements:v}):ie)},[]),M=t.rects.reference,I=t.rects.popper,O=new Map,R=!0,L=k[0],B=0;B<k.length;B++){var _=k[B],H=ds(_),U=Mf(_)===kf,G=[zo,_i].indexOf(H)>=0,K=G?"width":"height",z=Fm(t,{placement:_,boundary:d,rootBoundary:h,altBoundary:p,padding:u}),ne=G?U?Bi:Vo:U?_i:zo;M[K]>I[K]&&(ne=Ub(ne));var J=Ub(ne),ee=[];if(i&&ee.push(z[H]<=0),s&&ee.push(z[ne]<=0,z[J]<=0),ee.every(function(le){return le})){L=_,R=!1;break}O.set(_,ee)}if(R)for(var Z=b?3:1,q=function(ie){var fe=k.find(function(ye){var ge=O.get(ye);if(ge)return ge.slice(0,ie).every(function(me){return me})});if(fe)return L=fe,"break"},$=Z;$>0;$--){var re=q($);if(re==="break")break}t.placement!==L&&(t.modifiersData[r]._skip=!0,t.placement=L,t.reset=!0)}}const zH={name:"flip",enabled:!0,phase:"main",fn:Rre,requiresIfExists:["offset"],data:{_skip:!1}};function D3(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function A3(e){return[zo,Bi,_i,Vo].some(function(t){return e[t]>=0})}function Fre(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,i=t.modifiersData.preventOverflow,a=Fm(t,{elementContext:"reference"}),s=Fm(t,{altBoundary:!0}),l=D3(a,r),u=D3(s,o,i),d=A3(l),h=A3(u);t.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:u,isReferenceHidden:d,hasPopperEscaped:h},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":d,"data-popper-escaped":h})}const VH={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Fre};function Hre(e,t,n){var r=ds(e),o=[Vo,zo].indexOf(r)>=0?-1:1,i=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,a=i[0],s=i[1];return a=a||0,s=(s||0)*o,[Vo,Bi].indexOf(r)>=0?{x:s,y:a}:{x:a,y:s}}function _re(e){var t=e.state,n=e.options,r=e.name,o=n.offset,i=o===void 0?[0,0]:o,a=uD.reduce(function(d,h){return d[h]=Hre(h,t.rects,i),d},{}),s=a[t.placement],l=s.x,u=s.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=u),t.modifiersData[r]=a}const WH={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:_re};function Bre(e){var t=e.state,n=e.name;t.modifiersData[n]=UH({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const GH={name:"popperOffsets",enabled:!0,phase:"read",fn:Bre,data:{}};function Yre(e){return e==="x"?"y":"x"}function Ure(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,i=o===void 0?!0:o,a=n.altAxis,s=a===void 0?!1:a,l=n.boundary,u=n.rootBoundary,d=n.altBoundary,h=n.padding,p=n.tether,m=p===void 0?!0:p,b=n.tetherOffset,v=b===void 0?0:b,y=Fm(t,{boundary:l,rootBoundary:u,padding:h,altBoundary:d}),S=ds(t.placement),x=Mf(t.placement),C=!x,k=hD(S),M=Yre(k),I=t.modifiersData.popperOffsets,O=t.rects.reference,R=t.rects.popper,L=typeof v=="function"?v(Object.assign({},t.rects,{placement:t.placement})):v,B=typeof L=="number"?{mainAxis:L,altAxis:L}:Object.assign({mainAxis:0,altAxis:0},L),_=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,H={x:0,y:0};if(I){if(i){var U,G=k==="y"?zo:Vo,K=k==="y"?_i:Bi,z=k==="y"?"height":"width",ne=I[k],J=ne+y[G],ee=ne-y[K],Z=m?-R[z]/2:0,q=x===kf?O[z]:R[z],$=x===kf?-R[z]:-O[z],re=t.elements.arrow,le=m&&re?fD(re):{width:0,height:0},ie=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:LH(),fe=ie[G],ye=ie[K],ge=mm(0,O[z],le[z]),me=C?O[z]/2-Z-ge-fe-B.mainAxis:q-ge-fe-B.mainAxis,Ce=C?-O[z]/2+Z+ge+ye+B.mainAxis:$+ge+ye+B.mainAxis,je=t.elements.arrow&&sv(t.elements.arrow),Ie=je?k==="y"?je.clientTop||0:je.clientLeft||0:0,Fe=(U=_?.[k])!=null?U:0,ce=ne+me-Fe-Ie,Ne=ne+Ce-Fe,Pe=mm(m?I0(J,ce):J,ne,m?Mu(ee,Ne):ee);I[k]=Pe,H[k]=Pe-ne}if(s){var _e,qe=k==="x"?zo:Vo,Xe=k==="x"?_i:Bi,Qe=I[M],it=M==="y"?"height":"width",at=Qe+y[qe],vt=Qe-y[Xe],Mt=[zo,Vo].indexOf(S)!==-1,Kt=(_e=_?.[M])!=null?_e:0,gn=Mt?at:Qe-O[it]-R[it]-Kt+B.altAxis,Ge=Mt?Qe+O[it]+R[it]-Kt-B.altAxis:vt,ut=m&&Mt?bre(gn,Qe,Ge):mm(m?gn:at,Qe,m?Ge:vt);I[M]=ut,H[M]=ut-Qe}t.modifiersData[r]=H}}const ZH={name:"preventOverflow",enabled:!0,phase:"main",fn:Ure,requiresIfExists:["offset"]};function zre(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Vre(e){return e===hi(e)||!ji(e)?pD(e):zre(e)}function Wre(e){var t=e.getBoundingClientRect(),n=Ef(t.width)/e.offsetWidth||1,r=Ef(t.height)/e.offsetHeight||1;return n!==1||r!==1}function Gre(e,t,n){n===void 0&&(n=!1);var r=ji(t),o=ji(t)&&Wre(t),i=Ic(t),a=Cf(e,o,n),s={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(r||!r&&!n)&&((bs(t)!=="body"||gD(i))&&(s=Vre(t)),ji(t)?(l=Cf(t,!0),l.x+=t.clientLeft,l.y+=t.clientTop):i&&(l.x=mD(i))),{x:a.left+s.scrollLeft-l.x,y:a.top+s.scrollTop-l.y,width:a.width,height:a.height}}function Zre(e){var t=new Map,n=new Set,r=[];e.forEach(function(i){t.set(i.name,i)});function o(i){n.add(i.name);var a=[].concat(i.requires||[],i.requiresIfExists||[]);a.forEach(function(s){if(!n.has(s)){var l=t.get(s);l&&o(l)}}),r.push(i)}return e.forEach(function(i){n.has(i.name)||o(i)}),r}function $re(e){var t=Zre(e);return hre.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function qre(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function Kre(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var N3={placement:"bottom",modifiers:[],strategy:"absolute"};function O3(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some(function(r){return!(r&&typeof r.getBoundingClientRect=="function")})}function $H(e){e===void 0&&(e={});var t=e,n=t.defaultModifiers,r=n===void 0?[]:n,o=t.defaultOptions,i=o===void 0?N3:o;return function(s,l,u){u===void 0&&(u=i);var d={placement:"bottom",orderedModifiers:[],options:Object.assign({},N3,i),modifiersData:{},elements:{reference:s,popper:l},attributes:{},styles:{}},h=[],p=!1,m={state:d,setOptions:function(S){var x=typeof S=="function"?S(d.options):S;v(),d.options=Object.assign({},i,d.options,x),d.scrollParents={reference:Ru(s)?gm(s):s.contextElement?gm(s.contextElement):[],popper:gm(l)};var C=$re(Kre([].concat(r,d.options.modifiers)));return d.orderedModifiers=C.filter(function(k){return k.enabled}),b(),m.update()},forceUpdate:function(){if(!p){var S=d.elements,x=S.reference,C=S.popper;if(O3(x,C)){d.rects={reference:Gre(x,sv(C),d.options.strategy==="fixed"),popper:fD(C)},d.reset=!1,d.placement=d.options.placement,d.orderedModifiers.forEach(function(B){return d.modifiersData[B.name]=Object.assign({},B.data)});for(var k=0;k<d.orderedModifiers.length;k++){if(d.reset===!0){d.reset=!1,k=-1;continue}var M=d.orderedModifiers[k],I=M.fn,O=M.options,R=O===void 0?{}:O,L=M.name;typeof I=="function"&&(d=I({state:d,options:R,name:L,instance:m})||d)}}}},update:qre(function(){return new Promise(function(y){m.forceUpdate(),y(d)})}),destroy:function(){v(),p=!0}};if(!O3(s,l))return m;m.setOptions(u).then(function(y){!p&&u.onFirstUpdate&&u.onFirstUpdate(y)});function b(){d.orderedModifiers.forEach(function(y){var S=y.name,x=y.options,C=x===void 0?{}:x,k=y.effect;if(typeof k=="function"){var M=k({state:d,name:S,instance:m,options:C}),I=function(){};h.push(M||I)}})}function v(){h.forEach(function(y){return y()}),h=[]}return m}}var Xre=[BH,GH,_H,gre,WH,zH,ZH,HH,VH],qH=$H({defaultModifiers:Xre}),Jre=typeof Element<"u",Qre=typeof Map=="function",eoe=typeof Set=="function",toe=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function zb(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var n,r,o;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!zb(e[r],t[r]))return!1;return!0}var i;if(Qre&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(i=e.entries();!(r=i.next()).done;)if(!t.has(r.value[0]))return!1;for(i=e.entries();!(r=i.next()).done;)if(!zb(r.value[1],t.get(r.value[0])))return!1;return!0}if(eoe&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(i=e.entries();!(r=i.next()).done;)if(!t.has(r.value[0]))return!1;return!0}if(toe&&ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(e[r]!==t[r])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf&&typeof e.valueOf=="function"&&typeof t.valueOf=="function")return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString&&typeof e.toString=="function"&&typeof t.toString=="function")return e.toString()===t.toString();if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!Object.prototype.hasOwnProperty.call(t,o[r]))return!1;if(Jre&&e instanceof Element)return!1;for(r=n;r--!==0;)if(!((o[r]==="_owner"||o[r]==="__v"||o[r]==="__o")&&e.$$typeof)&&!zb(e[o[r]],t[o[r]]))return!1;return!0}return e!==e&&t!==t}var noe=function(t,n){try{return zb(t,n)}catch(r){if((r.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw r}};const roe=tt(noe);var ooe=[],kS=function(t,n,r){r===void 0&&(r={});var o=D.useRef(null),i={onFirstUpdate:r.onFirstUpdate,placement:r.placement||"bottom",strategy:r.strategy||"absolute",modifiers:r.modifiers||ooe},a=D.useState({styles:{popper:{position:i.strategy,left:"0",top:"0"},arrow:{position:"absolute"}},attributes:{}}),s=a[0],l=a[1],u=D.useMemo(function(){return{name:"updateState",enabled:!0,phase:"write",fn:function(m){var b=m.state,v=Object.keys(b.elements);nD.flushSync(function(){l({styles:T3(v.map(function(y){return[y,b.styles[y]||{}]})),attributes:T3(v.map(function(y){return[y,b.attributes[y]]}))})})},requires:["computeStyles"]}},[]),d=D.useMemo(function(){var p={onFirstUpdate:i.onFirstUpdate,placement:i.placement,strategy:i.strategy,modifiers:[].concat(i.modifiers,[u,{name:"applyStyles",enabled:!1}])};return roe(o.current,p)?o.current||p:(o.current=p,p)},[i.onFirstUpdate,i.placement,i.strategy,i.modifiers,u]),h=D.useRef();return x3(function(){h.current&&h.current.setOptions(d)},[d]),x3(function(){if(!(t==null||n==null)){var p=r.createPopper||qH,m=p(t,n,d);return h.current=m,function(){m.destroy(),h.current=null}}},[t,n,r.createPopper]),{state:h.current?h.current.state:null,styles:s.styles,attributes:s.attributes,update:h.current?h.current.update:null,forceUpdate:h.current?h.current.forceUpdate:null}},ioe=function(){},aoe=ioe;const soe=tt(aoe),loe=(e,t)=>({placement:e,modifiers:[{name:"flip",options:{allowedAutoPlacements:t,rootBoundary:"document"}},{name:"preventOverflow",options:{rootBoundary:"document"}}]}),coe=e=>{const n=D.useRef(null),[r,o]=D.useState(null),[i,a]=D.useState(0);let s,l;const u=()=>{if(N.Platform.isMobile){s="right-end",l=["bottom"];return}const h=window.innerWidth-i>280*1.2,p=window.innerWidth-i<280,m=window.innerWidth>280*1.5;if(e.DefaultEditorLocation!=="Bottom"){h?(s="right-end",l=["left-end"]):p&&m?(s="left-end",l=["right-end"]):(s="bottom",l=["bottom"]);return}h?(s="top-end",l=["top-start"]):p&&i>280?(s="top-start",l=["top-end"]):(s="top",l=["top"])};D.useEffect(()=>{e&&u()},[i,e?.DefaultEditorLocation]);const d=kS(n.current,r,loe(s,l));return{setPosX:a,popperRef:n,setPopperElement:o,popper:d}},uoe=()=>{const e=new Set,t=Ue.getState().query.filter,n=Ue.getState().query.tag,r=Ct.getQueryById(t||"");if(r&&r.querystring){const o=JSON.parse(r.querystring);if(Array.isArray(o))for(const i of o)i.type==="TAG"&&i.value&&i.value.operator==="CONTAIN"&&e.add(i.value.value)}return n&&e.add(n),Array.from(e)},doe=e=>{const{offsetLeft:t,offsetTop:n,offsetHeight:r,offsetWidth:o,selectionEnd:i}=e,a=document.createElement("div"),s=window.getComputedStyle(e);for(const v of s)a.style.setProperty(v,s.getPropertyValue(v));a.style.position="fixed",a.style.visibility="hidden",a.style.whiteSpace="pre-wrap";const u=e.tagName==="INPUT"?e.value.replace(/ /g,"."):e.value;a.textContent=u.substring(0,i||0),e.tagName==="TEXTAREA"&&(a.style.height="auto");const d=document.createElement("span");d.textContent=u.substring(i||0)||".",a.appendChild(d),document.body.appendChild(a);const{offsetLeft:h,offsetTop:p,offsetHeight:m,offsetWidth:b}=d;return document.body.removeChild(a),{x:t+h,y:n+p,h:r+m,w:o+b}},Du=({className:e,editorType:t,destroy:n,modal:r})=>{const{globalState:o,dailyNotesState:{app:i,settings:a,view:s,verifyState:l}}=D.useContext(ct),[u,d]=wh(!0),h=D.useRef(u),[p,m]=Ho(!0),b=D.useRef(null),v=D.useRef(null),y=D.useRef(o),[S,x]=Ho(!1),[C,k]=Ho(!1),{setPosX:M,popperRef:I,setPopperElement:O,popper:R}=coe(a),[L]=Ho(parseInt(N.moment().format("x"))),B=D.useRef(null),[_,H]=Ho(a?.EnabledLocationList.length===1?a?.EnabledLocationList[0].value:a?.MemoSaveLocation||"DAILY"),U=D.useRef(a.MemoSaveLocation||"DAILY");D.useEffect(()=>{h.current=u},[u]),D.useEffect(()=>{!v.current||!i||!s||(s.registerEvent(i.workspace.on("focus-on-textarea",ce=>{v.current?.focus(ce?.id)})),s.registerEvent(i.workspace.on("blur-on-memos",()=>{v.current?.blur()})),s.registerEvent(i.workspace.on("send-to-thino",async(ce,Ne)=>{if(typeof ce=="string")v.current?.insertText(ce+`
|
|
|
`,Ne.id);else{const Pe=ce.toPNG(),_e=new Blob([Pe],{type:"image/png"}),qe=new File([_e],"image.png",{type:"image/png",lastModified:Date.now()});if(!qe)return;const Xe=await ee(qe);Xe&&v.current?.insertText(Xe+`
|
|
|
`,Ne.id)}})))},[v,s,i]),D.useEffect(()=>{a&&d(a.DefaultPrefix==="List")},[a?.DefaultPrefix]),D.useEffect(()=>{if(a){if(a.EnabledLocationList.length===1){H(a.EnabledLocationList[0].value);return}H(a.MemoSaveLocation||"DAILY")}},[a?.MemoSaveLocation,a?.EnabledLocationList]),D.useEffect(()=>{if(!a||!B.current)return;const ce=Pm.find(Pe=>Pe.title===_)?.icon;N.setIcon(B.current,ce),N.requireApiVersion("1.4.4")&&N.setTooltip(B.current,E("Thino Save To: ")+_),U.current=_;const Ne=o.manifest;if(Ne){const Pe=i?.plugins.getPlugin(Ne.id);if(Pe){if(Pe.settings.MemoSaveLocation===_)return;Pe.settings.MemoSaveLocation=_,Pe.saveSettings()}}},[_,p]),D.useEffect(()=>{v.current&&a&&a.MemoSaveLocation&&H(a.MemoSaveLocation)},[B,a]),D.useEffect(()=>{if(!v.current||!a||N.Platform.isDesktop||o.globalEditorShown)return;const ce=a.UseButtonToShowEditor&&a.DefaultEditorLocation==="Bottom";if(N.Platform.isDesktop){m(!0);return}if(t&&t==="inline"){m(!0);return}if(m(N.Platform.isMobile&&!ce),!ce||o.memoListView==="chat")return;const Ne=document.body.find(".memolist-scrollview");Ne&&(Ne.onscroll=()=>{if(o.globalEditorShown)return;if(!o.memoListView&&Ze.getState().memoListView==="chat"){Ne.onscroll=null;return}const Pe=v.current.getContent();N.Platform.isMobile&&ce&&!Pe&&m(!1)})},[o.globalEditorShown,t,v]);const G=()=>{k(!1)};D.useEffect(()=>{if(i&&(o.markMemoId||o.editMemoId?.trim()&&o.editMemoId!==y.current.editMemoId)){const ce=i.workspace.getLeavesOfType("thino_view");ce.length>0&&i.workspace.revealLeaf(ce[0])}if(o.markMemoId){const ce=de.getMemoById(o.markMemoId);if(ce&&ce.sourceType==="DAILY")q8(ce).then(Ne=>{const Pe=`${E("MARK")}: ${Ne}`;v.current?.insertText(Pe),v.current?.focus(),Ze.setMarkMemoId("")});else{const Ne=`${E("MARK")}: [@THINO](${o.markMemoId})`;v.current?.insertText(Ne),v.current?.focus(),Ze.setMarkMemoId("")}return}if(o.editMemoId?.trim()&&o.editMemoId!==y.current.editMemoId){const ce=de.getMemoById(o.editMemoId);if(ce)switch(d(ce.thinoType==="JOURNAL"),a.EditorType){case"memos":v.current?.setContent(ce.content.replace(/ \^\S{6}$/,"")||""),v.current?.focus();break;case"obsidian":v.current?.clear(!1),v.current?.setContent(ce.content.replace(/ \^\S{6}$/,"")||""),v.current?.focus();break}}y.current=o},[o.markMemoId,o.editMemoId]),D.useEffect(()=>{!v.current||S||a.EditorType==="memos"&&(v.current?.element.addEventListener("paste",K),v.current?.element.addEventListener("drop",z),v.current?.element.addEventListener("click",ne),x(!0))},[v.current]);const K=async ce=>{if(ce.clipboardData&&ce.clipboardData.files.length>0){ce.preventDefault();const Ne=ce.clipboardData.files;for(const Pe of Ne){const _e=await ee(Pe);_e&&v.current?.insertText(_e)}}},z=async ce=>{if(ce.dataTransfer&&ce.dataTransfer.files.length>0){ce.preventDefault();const Ne=ce.dataTransfer.files;for(const Pe of Ne){const _e=await ee(Pe);_e&&v.current?.insertText(_e)}}},ne=()=>{re(v.current?.element.value||"")},J=async(ce,Ne)=>{const Pe=ce.ctrlKey||ce.metaKey,_e=ce.altKey;if(ce.key==="Escape"&&o.globalEditorShown&&(Ze.setGlobalEditorShown(!1),ce.preventDefault()),Pe&&ce.key==="Enter"){ce.preventDefault(),ce.stopPropagation(),Ne?(await q(v.current?.getContent()),v.current?.clear(!0)):await q(v.current?.element.value);return}if(_e)for(let qe=0;qe<a.EnabledLocationList.length;qe++)ce.key===(qe+1).toString()&&H(a.EnabledLocationList[qe].value);setTimeout(()=>{Ne||re(v.current?.element.value||"")})},ee=D.useCallback(async ce=>{const{type:Ne}=ce;if(Ne.startsWith("image"))try{return`${await tD.upload(ce)}`}catch(Pe){new N.Notice(Pe)}},[]),Z=D.useCallback(async ce=>{if(a.enableWordCount){const Ne=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),Pe=N.Platform.isDesktop?await Sn():Ne.identifier||Ne.uuid;if(!(l&&l?.appId===Pe))return Nt(),!1;const qe=ce.replace(/```[^\S\r\n]*[a-z]*\n.*?\n```/g,""),Xe=Le.getWordCount(qe),Qe=a.maxWordCount||1e3;return!(Xe>Qe&&Qe>0)}return!0},[a.enableWordCount,a.maxWordCount]),q=async ce=>{if(!ce||ce.trim()===""){new N.Notice(E("Content cannot be empty"));return}const Ne=$e.getState().settings,Pe=Ne?.addTagAutomatically,_e=Ne?.addTagWithNewline,qe=Ne?.addTagPosition,Qe=(uoe()||[]).filter(Mt=>!ce.includes(`#${Mt}`)),it=async(Mt,Kt)=>{Kt=Kt.replaceAll(" "," "),Xy("");try{if(!Mt){let Ge;switch(U.current){case"CANVAS":Ge=await de.createMemoCanvas({text:Kt,isList:h.current});break;case"MULTI":Ge=await de.createMemoMultiFile({content:Kt,isList:h.current});break;case"DAILY":Ge=await de.createMemoDaily(Kt,h.current);break;case"FILE":Ge=await de.createMemoSingleFile({content:Kt,isList:h.current});break}if(!Ge)return;de.pushMemo(Ge),(!Pe||Qe.length===0)&&Ue.clearQuery();const mt=(i||$e.getState().app)?.loadLocalStorage("tokenForSync");Ge&&mt&&a.startSync&&setTimeout(async()=>{try{if(U.current!=="DAILY"){const It=await qM({content:Kt,thinoType:"FILE",thinoStatus:Ge.thinoType==="JOURNAL"?"JOURNAL":Ge.thinoType==="TASK-TODO"?"TASK-TODO":"TASK-DONE"});await de.updateMemoById(Ge.id,It,!0)}}catch(It){console.error(It)}},200);return}const gn=de.getMemoById(Mt);if(gn&&(gn.content!==Kt||gn.thinoType!==(h.current?"JOURNAL":"TASK-TODO"))){const Ge=await de.updateMemo(gn.id,Kt,h.current?"JOURNAL":gn.thinoType.startsWith("TASK")?gn.thinoType:"TASK-TODO");Ge.updatedAt=Le.getDateTimeString(Date.now()),de.editMemo(Ge)}Ze.setEditMemoId("")}catch(gn){new N.Notice(gn.message)}};n&&n(),n&&v.current?.clear(!0);const{editMemoId:at}=Ze.getState(),vt=Qe&&Qe.length>0&&Pe&&!at?qe==="Beginning"?`${Qe.map(Mt=>`#${Mt}`).join(" ")} ${_e?`
|
|
|
`:""}${ce}`:`${ce} ${_e?`
|
|
|
`:""}${Qe.map(Mt=>`#${Mt}`).join(" ")}`:ce;await it(at,vt),Xy("")},$=D.useCallback(()=>{Ze.setEditMemoId(""),v.current?.setContent(""),Xy("")},[]),re=D.useCallback(ce=>{if(Xy(ce??""),!v.current)return;const Ne=v.current.getContent(),Pe=v.current.element.selectionStart,_e=Ne.slice(0,Pe),qe=Ne.slice(Pe);(_e.endsWith("@")||_e.endsWith("📆"))&&qe.startsWith(" ")||(_e.endsWith("@")||_e.endsWith("📆"))&&qe===""?(Ce(),k(!0)):k(!1),setTimeout(()=>{v.current?.focus()})},[a.EditorType]),le=ce=>{if(!v.current||!a)return;ce&&(G(),d(!1));const Ne=v.current.getContent(),Pe=v.current.element.selectionStart,_e=Ne.slice(0,Pe),qe=Ne.slice(Pe),Xe=N.moment(ce);if(_e.endsWith("@"))switch(a.InsertDateFormat){case"Dataview":v.current.element.value=Ne.slice(0,v.current.element.selectionStart-1)+"[due:: "+Xe.format("YYYY-MM-DD")+"]"+qe,v.current.element.setSelectionRange(Pe+17,Pe+17),v.current.focus(),re(v.current.element.value);break;case"Tasks":v.current.element.value=Ne.slice(0,v.current.element.selectionStart-1)+"📅 "+Xe.format("YYYY-MM-DD")+qe,v.current.element.setSelectionRange(Pe+11,Pe+11),v.current.focus(),re(v.current.element.value)}else{v.current.element.value=_e+Xe.format("YYYY-MM-DD")+qe,v.current.element.setSelectionRange(Pe+10,Pe+10),v.current.focus(),re(v.current.element.value);return}},ie=()=>{v.current&&d()},fe=async()=>{const ce=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),Ne=N.Platform.isDesktop?await Sn():ce.identifier||ce.uuid;return!l||l?.appId!==Ne?(Nt(),!1):!0},ye=async ce=>{if(!await fe())return;const Ne=new N.Menu;a.EnabledLocationList.forEach(Xe=>{Ne.addItem(Qe=>{Qe.setTitle(E(Xe.value)).setIcon(Pm.find(it=>it.title===Xe.value)?.icon??"file").setChecked(_===Xe.value).onClick(()=>{H(Xe.value)})})});let Pe=ce.target,_e=null;for(;!Pe.hasClass("location-wrapper")&&(_e=Pe.parentElement,_e);)Pe=_e;const qe=Pe.getBoundingClientRect();setTimeout(()=>{Ne.showAtPosition({x:qe.x,y:qe.bottom,width:qe.width,left:!1,overlap:!0})},200)},ge=D.useCallback(async ce=>{const Ne=await MH(i,r?"modal":"view"),Pe=new N.Menu;if(Pe.dom.addClass("history-menu"),Ne.length===0){Pe.addItem(_e=>{_e.setTitle(E("No history")),_e.setIcon("file-clock"),_e.setDisabled(!0)}),Pe.showAtMouseEvent(ce.nativeEvent);return}Ne.forEach(_e=>{Pe.addItem(qe=>{qe.titleEl.addClass("history-item"),qe.titleEl.createEl("span",{text:`${_e.content.length} chars`}),qe.titleEl.createEl("span",{text:N.moment(_e.timestamp).format("YYYY-MM-DD HH:mm:ss")}),qe.onClick(()=>{v.current?.updateContent(_e.content)}),qe.dom.onmouseover=Xe=>{const Qe=new N.HoverPopover(s,qe.dom,1e3);Qe.hoverEl.createEl("div",{text:"History content:",cls:"history-popover-title"}),Qe.hoverEl.createEl("div",{cls:"history-popover-content"},it=>{N.MarkdownRenderer.render(i,_e.content,it,"",s)}),Qe.hoverEl.addClass("history-popover"),Qe.load(),s.addChild(Qe),setTimeout(()=>{Qe.unload()},1e3)}})}),Pe.showAtMouseEvent(ce.nativeEvent)},[i]),me=D.useCallback(()=>{if(!(!v.current&&a.EditorType==="memos"))switch(a.EditorType){case"obsidian":v.current?.focus(),v.current?.insertTag();break;case"memos":{const ce=v.current.getContent(),Ne=v.current.element.selectionStart,Pe=ce.slice(0,Ne),_e=ce.slice(Ne);let qe=Pe+"# "+_e,Xe=Pe.length+1;Pe.endsWith("#")&&_e.startsWith(" ")&&(qe=Pe.slice(0,Pe.length-1)+_e.slice(1),Xe=Pe.length-1),v.current.element.value=qe,v.current.element.setSelectionRange(Xe,Xe),v.current.focus();const Qe=new Event("input",{bubbles:!0,cancelable:!0});v.current.element.dispatchEvent(Qe),re(v.current.element.value)}}},[i]),Ce=D.useCallback(()=>{if(!v.current||!I.current||!a||!i)return;const Pe=i.workspace.getLeavesOfType(Qr)[0].view.containerEl,_e=280,qe=Pe.clientWidth,{x:Xe,y:Qe}=doe(v.current.element);let it,at;N.Platform.isMobile?(window.innerWidth-Xe>_e?it=(Xe+_e+16>qe,Xe+18):window.innerWidth-Xe<_e?it=(Xe+_e+16>qe,Xe+34):it=v.current.element.clientWidth/2,a.DefaultEditorLocation==="Bottom"&&window.innerWidth>875?at=Qe+4:a.DefaultEditorLocation==="Bottom"&&window.innerWidth<=875?at=Qe+19:a.DefaultEditorLocation==="Top"&&window.innerWidth<=875&&(at=Qe+36)):(it=(Xe+_e+16>qe,Xe+18),at=Qe+34),M(Xe),I.current.style.left=`${it}px`,I.current.style.top=`${at}px`},[a,i]),je=D.useCallback(()=>{const ce=document.createElement("input");document.body.appendChild(ce),ce.type="file",ce.multiple=!1,ce.accept="image/png, image/gif, image/jpeg",ce.onchange=async()=>{if(!ce.files||ce.files.length===0)return;const Ne=ce.files[0],Pe=await ee(Ne);Pe&&v.current?.insertText(Pe),document.body.removeChild(ce)},ce.click()},[]),Ie=!!o.editMemoId,Fe=D.useMemo(()=>({className:"memo-editor",inputerType:a.EditorType||"obsidian",modal:r,initialContent:foe(),placeholder:E("What do you think now..."),showConfirmBtn:!0,showCancelBtn:Ie,showTools:!0,onConfirmBtnClick:q,onCancelBtnClick:$,onContentChange:re,onCheckCount:Z}),[Ie,a.EditorType]);return w.jsxs(w.Fragment,{children:[!o.globalEditorShown&&t==="block"&&w.jsx("div",{ref:ce=>{b.current=ce,ce&&N.setIcon&&N.setIcon(ce,"plus-circle")},className:`memo-show-editor-button ${p?"thino-hidden":""}`,onClick:()=>{b.current.firstElementChild?.toggleClass("rotate-hidden",!0),setTimeout(()=>{m(!0),b.current.firstElementChild.toggleClass("rotate-hidden",!1)},500),setTimeout(()=>{v.current?.focus()},600)}}),w.jsxs("div",{className:`memo-editor-wrapper ${e||""} ${Ie?"edit-ing":""} ${o.globalEditorShown?"fullscreen-editor":""} ${p?"":"thino-hidden"}`,onKeyDownCapture:ce=>J(ce,!0),children:[w.jsx("span",{className:`tip-text ${Ie?"":"thino-hidden"}`,children:"Modifying..."}),w.jsx(Jne,{ref:v,...Fe,tools:w.jsxs(w.Fragment,{children:[w.jsx("span",{ref:ce=>{ce&&N.setIcon(ce,"hash")},className:"btn action-btn add-tag",onClick:()=>{a&&a.DefaultEditorLocation==="Top"&&!o.globalEditorShown&&me()},onPointerDown:()=>{(a&&a.DefaultEditorLocation==="Bottom"||o.globalEditorShown)&&me()}}),w.jsx("span",{ref:ce=>{ce&&N.setIcon(ce,"paperclip")},className:"btn action-btn file-upload",onClick:()=>{a&&a.DefaultEditorLocation==="Top"&&!o.globalEditorShown&&je()},onPointerDown:()=>{(a&&a.DefaultEditorLocation==="Bottom"||o.globalEditorShown)&&je()}}),o.editMemoId===""&&w.jsx("span",{ref:ce=>{ce&&N.setIcon(ce,u?"layout-list":"check-square")},className:tn("btn action-btn list-or-task",u?"list":"task"),onClick:()=>{a&&a.DefaultEditorLocation==="Top"&&!o.globalEditorShown&&ie()},onPointerDown:()=>{(a&&a.DefaultEditorLocation==="Bottom"||o.globalEditorShown)&&ie()}}),w.jsx("div",{ref:ce=>{ce&&(N.setIcon&&N.setIcon(ce,o.globalEditorShown?"shrink":"expand"),N.setTooltip&&N.setTooltip(ce,o.globalEditorShown?E("Exit fullscreen mode"):E("Enter fullscreen mode")))},className:"action-btn show-editor pro",onPointerDown:async()=>{await fe()&&(m(!0),Ze.setGlobalEditorShown(!o.globalEditorShown))}}),w.jsx("div",{className:"action-btn split-line pro"}),w.jsx("div",{className:"action-btn location-wrapper pro",onClick:async ce=>{a&&a.DefaultEditorLocation==="Top"&&!o.globalEditorShown&&await ye(ce)},onPointerDown:async ce=>{(a&&a.DefaultEditorLocation==="Bottom"||o.globalEditorShown)&&await ye(ce)},children:w.jsx("div",{ref:B,className:"action-btn file-location-btn"})}),w.jsx("div",{className:"action-btn history-btn",onClick:ce=>{a&&a.DefaultEditorLocation==="Top"&&!o.globalEditorShown&&ge(ce)},onPointerDown:ce=>{(a&&a.DefaultEditorLocation==="Bottom"||o.globalEditorShown)&&ge(ce)},ref:ce=>{ce&&N.setIcon(ce,"file-clock")}})]})}),w.jsx("div",{ref:I,className:"date-picker",children:C&&w.jsx("div",{tabIndex:-1,style:R.styles.popper,...R.attributes.popper,ref:O,role:"dialog",children:w.jsx(xS,{className:`editor-date-picker ${C?"":"thino-hidden"}`,datestamp:L,handleDateStampChange:le})})})]})]})};function foe(){return ur.get(["thinoEditorContentCache"]).thinoEditorContentCache??""}function Xy(e){ur.set({thinoEditorContentCache:e})}const hoe=e=>{const t=[];return e.map(n=>{t.length==0?t.push({date:N.moment(n.createdAt,"YYYY/MM/DD HH:mm:ss").format("YYYY-MM-DD"),have:[n]}):t.some(o=>{if(o.date==N.moment(n.createdAt,"YYYY/MM/DD HH:mm:ss").format("YYYY-MM-DD"))return o.have.push(n),!0})||t.push({date:N.moment(n.createdAt,"YYYY/MM/DD HH:mm:ss").format("YYYY-MM-DD"),have:[n]})}),t},poe=e=>de.getState().commentMemos.filter(t=>t.linkId===e.hasId).sort((t,n)=>Le.getTimeStampByDate(t.createdAt)-Le.getTimeStampByDate(n.createdAt)).map(t=>({...t,createdAtStr:Le.getDateTimeString(t.createdAt),dateStr:Le.getDateString(t.createdAt)})),moe=e=>{const t=$e.getState().settings,n=Nq(),r=t?.ShowDate?" ":"",o="YYYY/MM/DD HH:mm:ss",i=/comment:(.*)$/g,a=/^\d{14}/g,s=(h,p,m)=>{const b=N.moment(h.createdAt,o).format("HH:mm");return m?m.replace(/{TIME}/g,b).replace(/{CONTENT}/g,p):`${b} ${p}`},l=h=>{const p=h.match(/TASK-(.*)?/g);return p?p[1]:""},u=h=>h==="TASK-TODO"?"- [ ] ":h==="TASK-DONE"?"- [x] ":h.match(/TASK-(.*)?/g)?`- [${l(h)}] `:"- ",d=h=>h.reduce((p,m)=>{const b=m.sourceType!=="MULTI"?`${m.content}`:`[[${m.path}]]`,v=t?.ShowTime?s(m,b,t?.DefaultMemoComposition):b,y=`${u(m.thinoType)}${v}`;let S="";return t.CommentOnMemos&&m.hasId!==void 0&&m.hasId!==""&&(S=poe(m).reduce((C,k)=>{const M=u(k.thinoType),I=k.content.replace(i,"").replace(a,""),O=t?.ShowDate?`${M}[[${N.moment(k.createdAt).format(n)}]] ${N.moment(k.createdAt).format("HH:mm")} ${I}`:`${M}${I}`;return C+r+" "+O+`
|
|
|
`},"")),p+r+y.replace(/ \^\S{6}/g,"")+`
|
|
|
`+S},"");return e.reduce((h,p)=>{const m=t?.ShowDate?`- [[${N.moment(p.date,"YYYY-MM-DD").format(n)}]]
|
|
|
`:"",b=d(p.have),v=t?.ShowDate&&t?.AddBlankLineWhenDate&&!t?.CommentOnMemos?`
|
|
|
`:"";return h+m+b+v},"").replace(/<br>/g,`
|
|
|
`)},goe=[{label:E("Today"),value:N.moment().format("YYYY-MM-DD")},{label:E("Yesterday"),value:N.moment().subtract(1,"days").format("YYYY-MM-DD")},{label:E("Last 7 days"),value:N.moment().subtract(7,"days").format("YYYY-MM-DD")},{label:E("Last 30 days"),value:N.moment().subtract(30,"days").format("YYYY-MM-DD")},{label:E("Last 90 days"),value:N.moment().subtract(90,"days").format("YYYY-MM-DD")},{label:E("Last 180 days"),value:N.moment().subtract(180,"days").format("YYYY-MM-DD")},{label:E("Last 365 days"),value:N.moment().subtract(365,"days").format("YYYY-MM-DD")}],KH=e=>{const{handleValueChange:t,setShownStatus:n}=e;return w.jsxs(w.Fragment,{children:[e.type==="icon"&&w.jsx("div",{className:"quick-date-btn-group",children:goe.map((r,o)=>w.jsx("div",{className:"btn action-btn quick-date-btn",onClick:()=>{t(r.value),n&&n(!1)},children:r.label},o))}),w.jsx(xS,{className:"calendar-date-picker",datestamp:e?.defaultValue||N.moment().startOf("day").valueOf(),handleDateStampChange:(r,o)=>{t(e.type==="icon"?N.moment(r).format("YYYY-MM-DD"):r.toString()),n&&n(!1)}})]})},k0=e=>{const{handleValueChange:t}=e,[n,r]=Y.useState(!1),o=Y.useRef(null),i=Y.useRef(null),a=kS(i.current,o.current,{placement:"bottom-start"});return iv(o,()=>{r(!1)}),w.jsxs(w.Fragment,{children:[w.jsx("span",{ref:l=>{i.current=l,l&&e.type==="icon"&&N.setIcon(l,"calendar")},className:`btn calendar-btn ${e.type==="icon"?"icon-btn":"text-btn"}`,onClick:()=>{!N.Platform.isMobile&&r(!n),!N.Platform.isMobile&&a?.update&&a?.update(),N.Platform.isMobile&&new XH($e.getState().app,e.type,t).open()},children:e.type==="text"&&e.defaultValue?e.defaultText?e.defaultText:N.moment(e.defaultValue,"x").subtract(e.startOrEnd==="end"?1:0,"days").format("YYYY/MM/DD"):""}),w.jsx("div",{className:`menu-btns-popup ${n?"":"thino-hidden"}`,ref:o,style:a.styles.popper,children:w.jsx(KH,{type:e.defaultText?"icon":e.type,handleValueChange:t,setShownStatus:r})})]})};class XH extends N.Modal{root;type;handleValueChange;constructor(t,n,r){super(t),this.type=n,this.handleValueChange=r}onOpen(){const{contentEl:t}=this;this.root=tv(t),this.root.render(w.jsx(KH,{type:this.type,handleValueChange:this.handleValueChange.bind(this),setShownStatus:n=>{!n&&this.close()}}))}onClose(){this.root?.unmount()}}const voe=(e,t)=>(e%t+t)%t;class yoe{owner;values;suggestions;selectedItem;containerEl;constructor(t,n,r){this.owner=t,this.containerEl=n,n.on("click",".suggestion-item",this.onSuggestionClick.bind(this)),n.on("mousemove",".suggestion-item",this.onSuggestionMouseover.bind(this)),r.register([],"ArrowUp",o=>{if(!o.isComposing)return this.setSelectedItem(this.selectedItem-1,!0),!1}),r.register([],"ArrowDown",o=>{if(!o.isComposing)return this.setSelectedItem(this.selectedItem+1,!0),!1}),r.register([],"Enter",o=>{if(!o.isComposing)return this.useSelectedItem(o),!1})}onSuggestionClick(t,n){t.preventDefault();const r=this.suggestions.indexOf(n);this.setSelectedItem(r,!1),this.useSelectedItem(t)}onSuggestionMouseover(t,n){const r=this.suggestions.indexOf(n);this.setSelectedItem(r,!1)}setSuggestions(t){this.containerEl.empty();const n=[];t.forEach(r=>{const o=this.containerEl.createDiv("suggestion-item");this.owner.renderSuggestion(r,o),n.push(o)}),this.values=t,this.suggestions=n,this.setSelectedItem(0,!1)}useSelectedItem(t){const n=this.values[this.selectedItem];n&&this.owner.selectSuggestion(n,t)}setSelectedItem(t,n){const r=voe(t,this.suggestions.length),o=this.suggestions[this.selectedItem],i=this.suggestions[r];o?.removeClass("is-selected"),i?.addClass("is-selected"),this.selectedItem=r,n&&i.scrollIntoView(!1)}}class JH{inputEl;popper;scope;suggestEl;suggest;cb;constructor(t,n){this.inputEl=t,this.scope=new N.Scope,this.cb=n,this.suggestEl=createDiv("suggestion-container");const r=this.suggestEl.createDiv("suggestion");this.suggest=new yoe(this,r,this.scope),this.scope.register([],"Escape",this.close.bind(this)),this.inputEl.addEventListener("input",this.onInputChanged.bind(this)),this.inputEl.addEventListener("focus",this.onInputChanged.bind(this)),this.inputEl.addEventListener("click",this.onInputChanged.bind(this)),this.inputEl.addEventListener("blur",this.close.bind(this)),this.suggestEl.on("mousedown",".suggestion-container",o=>{o.preventDefault()})}clearInput(){this.inputEl.value="",this.inputEl.trigger("blur"),this.inputEl.trigger("focus"),this.inputEl.trigger("input"),this.onInputChanged()}onInputChanged(){const t=this.inputEl.value,n=this.getSuggestions(t);if(!n){this.close();return}n.length>0?(this.suggest.setSuggestions(n),this.open(app.dom.appContainerEl,this.inputEl)):this.close()}open(t,n){app.keymap.pushScope(this.scope),t.appendChild(this.suggestEl),this.popper=qH(n,this.suggestEl,{placement:"bottom-start",modifiers:[{name:"sameWidth",enabled:!0,fn:({state:r,instance:o})=>{const i=`${r.rects.reference.width}px`;r.styles.popper.width!==i&&(r.styles.popper.width=i,o.update())},phase:"beforeWrite",requires:["computeStyles"]}]})}close(){app.keymap.popScope(this.scope),this.suggest.setSuggestions([]),this.popper&&this.popper.destroy(),this.suggestEl.detach()}destroy(){this.inputEl.removeEventListener("input",this.onInputChanged.bind(this)),this.inputEl.removeEventListener("focus",this.onInputChanged.bind(this)),this.inputEl.removeEventListener("blur",this.close.bind(this)),this.close()}updateCb(t){this.cb=t}}const boe=e=>{const t=e.metadataCache.getTags();return[...Object.keys(t)].map(n=>n.split("#").pop())};let Hm=class extends JH{fuzzySearchItemsOptimized(t,n){const r=N.prepareFuzzySearch(t);return n.map(o=>{const i=r(o);return i?{item:o,match:i,score:i.score}:null}).sort((o,i)=>i?.score-o?.score).filter(Boolean)}getSuggestions(t){const{settings:n,app:r}=$e.getState(),o=t.toLocaleLowerCase(),i=n.UseVaultTags?boe(r):de.getState().tags;return this.fuzzySearchItemsOptimized(o,i).map(a=>a.item)}renderSuggestion(t,n){n.toggleClass("thino-image-suggest-item",!0),n.createSpan({cls:"suggestion-name",text:t})}selectSuggestion(t){this.inputEl.value=t,this.cb&&this.cb(t),this.inputEl.dispatchEvent(new Event("change")),this.inputEl.trigger("change"),this.close()}};const woe=e=>{const t=new Set;return e.forEach(n=>{const r=new RegExp(Kg).exec(n.content),o=new RegExp(UM).exec(n.content);if(r)for(let i=1;i<r.length;i++)t.add(r[i]);if(o)for(let i=1;i<o.length;i++)t.add(o[i])}),Array.from(t)};class Soe extends N.Modal{root;cb;tags=[];constructor(t,n){super(t),this.cb=n}onOpen(){super.onOpen(),this.containerEl.toggleClass(["thino-bulk-action-dialog","tag-actions"],!0),this.root=Fi.createRoot(this.contentEl),this.root.render(w.jsx(zi,{store:ke,context:ct,children:w.jsx(Toe,{closeDialog:this.closeDialog.bind(this)})}))}closeDialog(t){this.tags=t,this.close()}onClose(){this.cb(this.tags),super.onClose(),this.root?.unmount()}}const Toe=({closeDialog:e})=>{const[t,n]=Y.useState([]),r=Y.useRef(null),o=Y.useRef(null);D.useEffect(()=>{if(o.current){if(r.current){r.current.updateCb(i);return}r.current=new Hm(o.current,i)}},[o.current,t]);const i=s=>{if(!s)return;const l=new Set(t);l.add(s),n(Array.from(l)),r.current.clearInput()},a=()=>{e(t)};return w.jsxs("div",{className:"thino-tag-operation",children:[w.jsx("div",{className:"tag-operation-title",children:E("Tag Bulk Select")}),w.jsxs("div",{className:"tag-operation-content",children:[w.jsxs("div",{className:"tag-operation-content-title selected-tags",children:[w.jsx("div",{className:"name",children:E("Selected Tags")}),w.jsx("div",{className:"desc",children:E("Click to remove selected tag")})]}),w.jsx("div",{className:"tag-operation-content-tags selected-tags",children:t.map(s=>w.jsx("div",{className:"tag-operation-content-tag",onClick:()=>{n(t.filter(l=>l!==s))},children:s},s))}),w.jsx("div",{className:"tag-operation-content-inputer",children:w.jsx("input",{placeholder:E("Input to select exist tag"),ref:o,onKeyDown:s=>{s.key==="Enter"&&i(o.current.value)}})}),w.jsxs("div",{className:"tag-operation-content-btn-group",children:[w.jsx("button",{className:"cancel-btn",onClick:()=>{e([])},children:E("Cancel")}),w.jsx("button",{className:"save-btn",onClick:a,children:E("Save")})]})]})]})},xoe=({app:e,thinos:t,closeDialog:n})=>{const[r,o]=Y.useState([]),[i,a]=Y.useState([]),[s,l]=Y.useState([]),u=Y.useRef(null),d=Y.useRef(null),h=Y.useRef(null),p=Y.useRef("End"),m=Y.useRef(!1),b=Y.useRef(null);D.useEffect(()=>{t&&t.length&&o(woe(t))},[t]),D.useEffect(()=>{!h.current||!d.current||(new N.Setting(d.current).setName(E("Add tag position")).addDropdown(x=>{x.addOption("End",E("End")),x.addOption("Beginning",E("Beginning")),x.setValue("End").onChange(async C=>{p.current=C})}),new N.Setting(h.current).setName(E("Add tag with new line")).addToggle(x=>{x.setValue(!1).onChange(async C=>{m.current=C})}))},[]);const v=x=>{if(!x)return;const C=new Set(i);C.add(x),a(Array.from(C)),u.current.clearInput()};D.useEffect(()=>{if(b.current){if(u.current){u.current.updateCb(v);return}u.current=new Hm(b.current,v)}},[b.current,i]);const y=()=>{n(),S({remove:s,add:i,targetThinos:t})},S=async({remove:x,add:C,targetThinos:k})=>{const M=m.current||!1,I=[];for(const O of k){let R=O.content;for(const L of x)R=R.replace(new RegExp(`#${L}`,"g"),"");if(R=R.trim(),C.length>0&&(R=p.current==="Beginning"?`${C.map(L=>`#${L}`).join(" ")} ${M?`
|
|
|
`:""}${R}`:`${R} ${M?`
|
|
|
`:""}${C.map(L=>`#${L}`).join(" ")}`),O&&O.content!==R){const L=await de.updateMemo(O.id,R?.trim());I.push(L)}}I.length>0&&de.editMemoBulk(I),I.length>0&&Ue.clearQuery()};return w.jsxs("div",{className:"thino-tag-operation",children:[w.jsx("div",{className:"tag-operation-title",children:E("Tag Bulk Edit")}),w.jsxs("div",{className:"tag-operation-content",children:[r.length>0&&w.jsxs(w.Fragment,{children:[w.jsxs("div",{className:"tag-operation-content-title exist-tags",children:[w.jsx("div",{className:"name",children:E("Exist Tags")}),w.jsx("div",{className:"desc",children:E("Click to remove exist tag")})]}),w.jsx("div",{className:"tag-operation-content-tags exist-tags",children:r.map(x=>w.jsx("div",{className:tn("tag-operation-content-tag",s.includes(x)&&"tag-operation-content-tag-removed"),onClick:()=>{s.includes(x)||l([...s,x]),s.includes(x)&&l(s.filter(C=>C!==x)),i.includes(x)&&a(i.filter(C=>C!==x))},children:x},x))})]}),w.jsxs("div",{className:"tag-operation-content-title selected-tags",children:[w.jsx("div",{className:"name",children:E("Selected Tags")}),w.jsx("div",{className:"desc",children:E("Click to remove selected tag")})]}),w.jsx("div",{className:"tag-operation-content-tags selected-tags",children:i.map(x=>w.jsx("div",{className:"tag-operation-content-tag",onClick:()=>{a(i.filter(C=>C!==x))},children:x},x))}),w.jsx("div",{className:"tag-operation-content-inputer",children:w.jsx("input",{placeholder:E("Input to select exist tag"),ref:b,onKeyDown:x=>{x.key==="Enter"&&v(b.current.value)}})}),w.jsxs("div",{className:"tag-operation-settings",children:[w.jsx("div",{ref:d}),w.jsx("div",{ref:h})]}),w.jsxs("div",{className:"tag-operation-content-btn-group",children:[w.jsx("button",{className:"cancel-btn",onClick:n,children:E("Cancel")}),w.jsx("button",{className:"save-btn",onClick:y,children:E("Save")})]})]})]})},sE=new Map,Fu=async(e,t=!0)=>{const{vault:n,metadataCache:r}=$e.getState().app;if(t&&sE.has(e))return Promise.resolve(sE.get(e));if(e.contains("data:image"))return e;let o;const i=await n.adapter.exists(N.normalizePath(e));let a="";try{if(!i&&!/(http|https)/g.test(e)&&!e.includes("data:image")){let s;if(e.startsWith("app://")){const l=N.normalizePath(decodeURIComponent(e).replace(N.Platform.resourcePathPrefix,"").replace(/\?(.*)$/,"").replace(N.normalizePath(app?.vault.adapter.basePath),""));a=N.normalizePath(decodeURIComponent(l))}else{if(s=r.getFirstLinkpathDest(e,""),!s){new N.Notice(E("File not exist"));return}a=s.path}}else a=e}catch(s){console.error(s)}if(a){if(/(http|https)/g.test(a))if(a.startsWith("http://localhost")){let s=a;s=s.replace("http://localhost/_capacitor_file_",""),s=decodeURIComponent(s).replace(/\?(.*)$/,"").replace(app?.vault.adapter.basePath,""),s=N.normalizePath(decodeURIComponent(s));const l=await n.adapter.readBinary(s),u=new Uint8Array(l);o=new Blob([u],{type:"image/png"})}else try{const s=await N.requestUrl(e),l=new Uint8Array(s.arrayBuffer);o=new Blob([l],{type:"image/png"})}catch{}else if(a){const s=await n.adapter.readBinary(a),l=new Uint8Array(s);o=new Blob([l],{type:"image/png"})}return o?await Ioe(o,e):""}},Ioe=(e,t)=>new Promise(n=>{const r=new FileReader;r.onloadend=()=>{const o=r.result;sE.set(t,o),n(o)},r.readAsDataURL(e)}),tm=async e=>{if(!e.style.backgroundImage.includes("url(")&&!e.style.backgroundImage.includes("http"))return;let t=e.style.backgroundImage.includes("url(")?e.style.backgroundImage.slice(5,-2):e.style.backgroundImage;return t?(t.startsWith("http://localhost")&&(t=t.replace("http://localhost/_capacitor_file_",""),t=decodeURIComponent(t).replace(/\?(.*)$/,"").replace(app?.vault.adapter.basePath,""),t=N.normalizePath(decodeURIComponent(t))),await Fu(t)):void 0},koe=async e=>e.getAttribute("src")?e?.src?.startsWith("http://localhost")?await Fu(e.getAttribute("path")||N.normalizePath(e?.parentElement.getAttribute("src"))):await Fu(e.getAttribute("src")):void 0,St=Loe(),E0=Roe(),QH=Foe(),e7=Hoe(),su={copyDefaultStyles:!0,imagePlaceholder:void 0,cacheBust:!1,useCredentials:!1,httpTimeout:3e4,styleCaching:"strict",corsImg:void 0},Ft={toSvg:t7,toPng:Moe,toJpeg:Doe,toBlob:Aoe,toPixelData:Coe,toCanvas:Noe,impl:{fontFaces:QH,images:e7,util:St,inliner:E0,urlCache:[],options:{}}},vD=(typeof Node<"u"?Node.ELEMENT_NODE:void 0)||1,Vb=(typeof global<"u"?global.getComputedStyle:void 0)||(typeof window<"u"?window.getComputedStyle:void 0)||globalThis.getComputedStyle,Eoe=(typeof global<"u"?global.atob:void 0)||(typeof window<"u"?window.atob:void 0)||globalThis.atob;function t7(e,t){Ft.impl.util.getWindow(e),t=t||{},Ooe(t);let n=[];return Promise.resolve(e).then(r).then(function(l){return n7(l,t,null)}).then(Poe).then(joe).then(a).then(s).then(o).then(i);function r(l){if(l.nodeType===vD)return l;const u=l,d=l.parentNode,h=document.createElement("span");return d.replaceChild(h,u),h.append(l),n.push({parent:d,child:u,wrapper:h}),h}function o(l){for(;n.length>0;){const u=n.pop();u.parent.replaceChild(u.child,u.wrapper)}return l}function i(l){return Ft.impl.urlCache=[],Voe(),l}function a(l){t.bgcolor&&(l.style.backgroundColor=t.bgcolor),t.width&&(l.style.width=`${t.width}px`),t.height&&(l.style.height=`${t.height}px`),t.style&&Object.keys(t.style).forEach(function(d){l.style[d]=t.style[d]});let u=null;return typeof t.onclone=="function"&&(u=t.onclone(l)),Promise.resolve(u).then(function(){return l})}function s(l){let u=t.width||St.width(l),d=t.height||St.height(l);return Promise.resolve(l).then(function(h){return h.setAttribute("xmlns","http://www.w3.org/1999/xhtml"),new XMLSerializer().serializeToString(h)}).then(St.escapeXhtml).then(function(h){const p=(St.isDimensionMissing(u)?' width="100%"':` width="${u}"`)+(St.isDimensionMissing(d)?' height="100%"':` height="${d}"`);return`<svg xmlns="http://www.w3.org/2000/svg"${(St.isDimensionMissing(u)?"":` width="${u}"`)+(St.isDimensionMissing(d)?"":` height="${d}"`)}><foreignObject${p}>${h}</foreignObject></svg>`}).then(function(h){return`data:image/svg+xml;charset=utf-8,${h}`})}}function Coe(e,t){return lv(e,t).then(function(n){return n.getContext("2d").getImageData(0,0,St.width(e),St.height(e)).data})}function Moe(e,t){return lv(e,t).then(function(n){return n.toDataURL()})}function Doe(e,t){return lv(e,t).then(function(n){return n.toDataURL("image/jpeg",(t?t.quality:void 0)||1)})}function Aoe(e,t){return lv(e,t).then(St.canvasToBlob)}function Noe(e,t){return lv(e,t)}function Ooe(e){typeof e.copyDefaultStyles>"u"?Ft.impl.options.copyDefaultStyles=su.copyDefaultStyles:Ft.impl.options.copyDefaultStyles=e.copyDefaultStyles,typeof e.imagePlaceholder>"u"?Ft.impl.options.imagePlaceholder=su.imagePlaceholder:Ft.impl.options.imagePlaceholder=e.imagePlaceholder,typeof e.cacheBust>"u"?Ft.impl.options.cacheBust=su.cacheBust:Ft.impl.options.cacheBust=e.cacheBust,typeof e.corsImg>"u"?Ft.impl.options.corsImg=su.corsImg:Ft.impl.options.corsImg=e.corsImg,typeof e.useCredentials>"u"?Ft.impl.options.useCredentials=su.useCredentials:Ft.impl.options.useCredentials=e.useCredentials,typeof e.httpTimeout>"u"?Ft.impl.options.httpTimeout=su.httpTimeout:Ft.impl.options.httpTimeout=e.httpTimeout,typeof e.styleCaching>"u"?Ft.impl.options.styleCaching=su.styleCaching:Ft.impl.options.styleCaching=e.styleCaching,Ft.impl.options.requestUrl=e.requestUrl,Ft.impl.options.type=e.type||"image/png"}function lv(e,t){return t=t||{},t7(e,t).then(St.makeImage).then(function(r){const o=typeof t.scale!="number"?1:t.scale,i=n(e,o),a=i.getContext("2d");return a.msImageSmoothingEnabled=!1,a.imageSmoothingEnabled=!1,r&&(a.scale(o,o),a.drawImage(r,0,0)),i});function n(r,o){let i=t.width||St.width(r),a=t.height||St.height(r);St.isDimensionMissing(i)&&(i=St.isDimensionMissing(a)?300:a*2),St.isDimensionMissing(a)&&(a=i/2);const s=document.createElement("canvas");if(s.width=i*o,s.height=a*o,t.bgcolor){const l=s.getContext("2d");l.fillStyle=t.bgcolor,l.fillRect(0,0,s.width,s.height)}return s}}let ri=null;function n7(e,t,n,r){const o=t.filter;if(e===ri||St.isHTMLScriptElement(e)||St.isHTMLStyleElement(e)||St.isHTMLLinkElement(e)||n!==null&&o&&!o(e))return Promise.resolve();return Promise.resolve(e).then(i).then(function(u){return s(u,a(e))}).then(function(u){return l(u,e)});function i(u){return St.isHTMLCanvasElement(u)?St.makeImage(u.toDataURL()):u.cloneNode(!1)}function a(u){return St.isElementHostForOpenShadowRoot(u)?u.shadowRoot:u}function s(u,d){const h=b(d);let p=Promise.resolve();if(h.length!==0){const v=Vb(m(d));St.asArray(h).forEach(function(y){p=p.then(function(){return n7(y,t,v).then(function(S){S&&u.appendChild(S)})})})}return p.then(function(){return u});function m(v){return St.isShadowRoot(v)?v.host:v}function b(v){return St.isShadowSlotElement(v)?v.assignedNodes():v.childNodes}}function l(u,d){if(!St.isElement(u)||St.isShadowSlotElement(d))return Promise.resolve(u);return Promise.resolve().then(h).then(p).then(m).then(b).then(function(){return u});function h(){y(d,u);function v(S,x){x.font=S.font,x.fontFamily=S.fontFamily,x.fontFeatureSettings=S.fontFeatureSettings,x.fontKerning=S.fontKerning,x.fontSize=S.fontSize,x.fontStretch=S.fontStretch,x.fontStyle=S.fontStyle,x.fontVariant=S.fontVariant,x.fontVariantCaps=S.fontVariantCaps,x.fontVariantEastAsian=S.fontVariantEastAsian,x.fontVariantLigatures=S.fontVariantLigatures,x.fontVariantNumeric=S.fontVariantNumeric,x.fontVariationSettings=S.fontVariationSettings,x.fontWeight=S.fontWeight}function y(S,x){const C=Vb(S);C.cssText?(x.style.cssText=C.cssText,v(C,x.style)):(Boe(t,S,C,n,x),n===null&&(["inset-block","inset-block-start","inset-block-end"].forEach(k=>x.style.removeProperty(k)),["left","right","top","bottom"].forEach(k=>{x.style.getPropertyValue(k)&&x.style.setProperty(k,"0px")})))}}function p(){const v=St.uid();[":before",":after"].forEach(function(S){y(S)});function y(S){const x=Vb(d,S),C=x.getPropertyValue("content");if(C===""||C==="none")return;const k=u.getAttribute("class")||"";u.setAttribute("class",`${k} ${v}`);const M=document.createElement("style");M.appendChild(I()),u.appendChild(M);function I(){const O=`.${v}:${S}`,R=x.cssText?L():B();return document.createTextNode(`${O}{${R}}`);function L(){return`${x.cssText} content: ${C};`}function B(){return`${St.asArray(x).map(H).join("; ")};`;function H(U){const G=x.getPropertyValue(U),K=x.getPropertyPriority(U)?" !important":"";return`${U}: ${G}${K}`}}}}}function m(){St.isHTMLTextAreaElement(d)&&(u.innerHTML=d.value),St.isHTMLInputElement(d)&&u.setAttribute("value",d.value)}function b(){St.isSVGElement(u)&&(u.setAttribute("xmlns","http://www.w3.org/2000/svg"),St.isSVGRectElement(u)&&["width","height"].forEach(function(v){const y=u.getAttribute(v);y&&u.style.setProperty(v,y)}))}}}function Poe(e){return QH.resolveAll().then(function(t){if(t!==""){const n=document.createElement("style");e.appendChild(n),n.appendChild(document.createTextNode(t))}return e})}function joe(e){return e7.inlineAll(e).then(function(){return e})}function Loe(){let e=0;return{escape:L,isDataUrl:S,canvasToBlob:k,resolveUrl:M,getAndEncode:R,uid:I,delay:B,asArray:_,escapeXhtml:H,makeImage:O,width:U,height:G,getWindow:t,isElement:i,isElementHostForOpenShadowRoot:n,isShadowRoot:r,isInShadowRoot:o,isHTMLElement:s,isHTMLCanvasElement:a,isHTMLInputElement:u,isHTMLImageElement:l,isHTMLLinkElement:d,isHTMLScriptElement:h,isHTMLStyleElement:p,isHTMLTextAreaElement:m,isShadowSlotElement:b,isSVGElement:v,isSVGRectElement:y,isDimensionMissing:x};function t(z){const ne=z?z.ownerDocument:void 0;return(ne?ne.defaultView:void 0)||global||window}function n(z){return i(z)&&z.shadowRoot!==null}function r(z){return z instanceof t(z).ShadowRoot}function o(z){return z!==null&&Object.prototype.hasOwnProperty.call(z,"getRootNode")&&r(z.getRootNode())}function i(z){return z instanceof t(z).Element}function a(z){return z instanceof t(z).HTMLCanvasElement}function s(z){return z instanceof t(z).HTMLElement}function l(z){return z instanceof t(z).HTMLImageElement}function u(z){return z instanceof t(z).HTMLInputElement}function d(z){return z instanceof t(z).HTMLLinkElement}function h(z){return z instanceof t(z).HTMLScriptElement}function p(z){return z instanceof t(z).HTMLStyleElement}function m(z){return z instanceof t(z).HTMLTextAreaElement}function b(z){return o(z)&&z instanceof t(z).HTMLSlotElement}function v(z){return z instanceof t(z).SVGElement}function y(z){return z instanceof t(z).SVGRectElement}function S(z){return z.search(/^(data:)/)!==-1}function x(z){return isNaN(z)||z<=0}function C(z){return new Promise(function(ne){const J=Eoe(z.toDataURL().split(",")[1]),ee=J.length,Z=new Uint8Array(ee);for(let q=0;q<ee;q++)Z[q]=J.charCodeAt(q);ne(new Blob([Z],{type:Ft.impl.options.type}))})}function k(z){return z.toBlob?new Promise(function(ne){z.toBlob(ne)}):C(z)}function M(z,ne){const J=document.implementation.createHTMLDocument(),ee=J.createElement("base");J.head.appendChild(ee);const Z=J.createElement("a");return J.body.appendChild(Z),ee.href=ne,Z.href=z,Z.href}function I(){return`u${z()}${e++}`;function z(){return`0000${(Math.random()*Math.pow(36,4)<<0).toString(36)}`.slice(-4)}}function O(z){return z==="data:,"?Promise.resolve():new Promise(function(ne,J){const ee=new Image;Ft.impl.options.useCredentials&&(ee.crossOrigin="use-credentials"),ee.onload=function(){window&&window.requestAnimationFrame?window.requestAnimationFrame(function(){ne(ee)}):ne(ee)},ee.onerror=J,ee.src=z})}function R(z){let ne=Ft.impl.urlCache.find(function(J){return J.url===z});return ne||(ne={url:z,promise:null},Ft.impl.urlCache.push(ne)),ne.promise===null&&(Ft.impl.options.cacheBust&&(z+=(/\?/.test(z)?"&":"?")+new Date().getTime()),Ft.impl.options.requestUrl&&/^http/.test(z)?ne.promise=Ft.impl.options.requestUrl({url:z,method:"GET"}).then(J=>new Promise(ee=>{const Z=new FileReader;Z.onload=function(q){ee(q.target.result)},Z.readAsDataURL(new Blob([J.arrayBuffer],{type:J.headers["content-type"]}))})).catch(J=>(console.error("cannot fetch resource: "+z+", error: "+J),"")):ne.promise=new Promise(function(J){const ee=Ft.impl.options.httpTimeout,Z=new XMLHttpRequest;if(Z.onreadystatechange=$,Z.ontimeout=re,Z.responseType="blob",Z.timeout=ee,Ft.impl.options.useCredentials&&(Z.withCredentials=!0),Ft.impl.options.corsImg&&z.indexOf("http")===0&&z.indexOf(window.location.origin)===-1){const fe=(Ft.impl.options.corsImg.method||"GET").toUpperCase()==="POST"?"POST":"GET";Z.open(fe,(Ft.impl.options.corsImg.url||"").replace("#{cors}",z),!0);let ye=!1;const ge=Ft.impl.options.corsImg.headers||{};Object.keys(ge).forEach(function(Ce){ge[Ce].indexOf("application/json")!==-1&&(ye=!0),Z.setRequestHeader(Ce,ge[Ce])});const me=le(Ft.impl.options.corsImg.data||"");Object.keys(me).forEach(function(Ce){typeof me[Ce]=="string"&&(me[Ce]=me[Ce].replace("#{cors}",z))}),Z.send(ye?JSON.stringify(me):me)}else Z.open("GET",z,!0),Z.send();let q;if(Ft.impl.options.imagePlaceholder){const fe=Ft.impl.options.imagePlaceholder.split(/,/);fe&&fe[1]&&(q=fe[1])}function $(){if(Z.readyState!==4)return;if(Z.status>=300){q?J(q):ie(`cannot fetch resource: ${z}, status: ${Z.status}`);return}const fe=new FileReader;fe.onloadend=function(){J(fe.result)},fe.readAsDataURL(Z.response)}function re(){q?J(q):ie(`timeout of ${ee}ms occured while fetching resource: ${z}`)}function le(fe){try{return JSON.parse(JSON.stringify(fe))}catch{ie("corsImg.data is missing or invalid");return}}function ie(fe){console.error(fe),J("")}})),ne.promise}function L(z){return z.replace(/([.*+?^${}()|[]\/\\])/g,"\\$1")}function B(z){return function(ne){return new Promise(function(J){setTimeout(function(){J(ne)},z)})}}function _(z){const ne=[],J=z.length;for(let ee=0;ee<J;ee++)ne.push(z[ee]);return ne}function H(z){return z.replace(/%/g,"%25").replace(/#/g,"%23").replace(/\n/g,"%0A")}function U(z){const ne=K(z,"width");if(!isNaN(ne))return ne;const J=K(z,"border-left-width"),ee=K(z,"border-right-width");return z.scrollWidth+J+ee}function G(z){const ne=K(z,"height");if(!isNaN(ne))return ne;const J=K(z,"border-top-width"),ee=K(z,"border-bottom-width");return z.scrollHeight+J+ee}function K(z,ne){if(z.nodeType===vD){let J=Vb(z).getPropertyValue(ne);if(J.slice(-2)==="px")return J=J.slice(0,-2),parseFloat(J)}return NaN}}function Roe(){const e=/url\(['"]?([^'"]+?)['"]?\)/g;return{inlineAll:o,shouldProcess:t,impl:{readUrls:n,inline:r}};function t(i){return i.search(e)!==-1}function n(i){const a=[];let s;for(;(s=e.exec(i))!==null;)a.push(s[1]);return a.filter(function(l){return!St.isDataUrl(l)})}function r(i,a,s,l){return Promise.resolve(a).then(function(d){return s?St.resolveUrl(d,s):d}).then(l||St.getAndEncode).then(function(d){return i.replace(u(a),`$1${d}$3`)});function u(d){return new RegExp(`(url\\(['"]?)(${St.escape(d)})(['"]?\\))`,"g")}}function o(i,a,s){if(l())return Promise.resolve(i);return Promise.resolve(i).then(n).then(function(u){let d=Promise.resolve(i);return u.forEach(function(h){d=d.then(function(p){return r(p,h,a,s)})}),d});function l(){return!t(i)}}}function Foe(){return{resolveAll:e,impl:{readAll:t}};function e(){return t().then(function(n){return Promise.all(n.map(function(r){return r.resolve()}))}).then(function(n){return n.join(`
|
|
|
`)})}function t(){return Promise.resolve(St.asArray(document.styleSheets)).then(r).then(n).then(function(i){return i.map(o)});function n(i){return i.filter(function(a){return a.type===CSSRule.FONT_FACE_RULE}).filter(function(a){return E0.shouldProcess(a.style.getPropertyValue("src"))})}function r(i){const a=[];return i.forEach(function(s){if(Object.prototype.hasOwnProperty.call(Object.getPrototypeOf(s),"cssRules"))try{St.asArray(s.cssRules||[]).forEach(a.push.bind(a))}catch(l){console.error(`domtoimage: Error while reading CSS rules from ${s.href}`,l.toString())}}),a}function o(i){return{resolve:function(){const s=(i.parentStyleSheet||{}).href;return E0.inlineAll(i.cssText,s)},src:function(){return i.style.getPropertyValue("src")}}}}}function Hoe(){return{inlineAll:t,impl:{newImage:e}};function e(n){return{inline:r};function r(o){return St.isDataUrl(n.src)?Promise.resolve():Promise.resolve(n.src).then(o||St.getAndEncode).then(function(i){return new Promise(function(a){n.onload=a,n.onerror=a,n.src=i})})}}function t(n){if(!St.isElement(n))return Promise.resolve(n);return r(n).then(function(){return St.isHTMLImageElement(n)?e(n).inline():Promise.all(St.asArray(n.childNodes).map(function(o){return t(o)}))});function r(o){const a=["background","background-image"].map(function(s){const l=o.style.getPropertyValue(s),u=o.style.getPropertyPriority(s);return l?E0.inlineAll(l).then(function(d){o.style.setProperty(s,d,u)}):Promise.resolve()});return Promise.all(a).then(function(){return o})}}}function _oe(e,t,n,r){const o=["background-clip"].indexOf(t)>=0;r?(e.setProperty(t,n,r),o&&e.setProperty(`-webkit-${t}`,n,r)):(e.setProperty(t,n),o&&e.setProperty(`-webkit-${t}`,n))}function Boe(e,t,n,r,o){const i=Ft.impl.options.copyDefaultStyles?Uoe(e,t):{},a=o.style;St.asArray(n).forEach(function(s){const l=n.getPropertyValue(s),u=i[s],d=r?r.getPropertyValue(s):void 0;if(l!==u||r&&l!==d){const h=n.getPropertyPriority(s);_oe(a,s,l,h)}})}let Jy=null,Wb={};const Yoe=["ADDRESS","ARTICLE","ASIDE","BLOCKQUOTE","DETAILS","DIALOG","DD","DIV","DL","DT","FIELDSET","FIGCAPTION","FIGURE","FOOTER","FORM","H1","H2","H3","H4","H5","H6","HEADER","HGROUP","HR","LI","MAIN","NAV","OL","P","PRE","SECTION","SVG","TABLE","UL","math","svg","BODY","HEAD","HTML"];function Uoe(e,t){const n=s(t),r=l(n);if(Wb[r])return Wb[r];const o=zoe(),i=u(o.document,n),a=d(o,i);return h(i),Wb[r]=a,a;function s(p){const m=[];do{if(p.nodeType===vD){const b=p.tagName;if(m.push(b),Yoe.includes(b))break}p=p.parentNode}while(p);return m}function l(p){return e.styleCaching==="relaxed"?p.filter((m,b,v)=>b===0||b===v.length-1).join(">"):p.join(">")}function u(p,m){let b=p.body;do{const v=m.pop(),y=p.createElement(v);b.appendChild(y),b=y}while(m.length>0);return b.textContent="",b}function d(p,m){const b={},v=p.getComputedStyle(m);return St.asArray(v).forEach(function(y){b[y]=y==="width"||y==="height"?"auto":v.getPropertyValue(y)}),b}function h(p){do{const m=p.parentElement;m!==null&&m.removeChild(p),p=m}while(p&&p.tagName!=="BODY")}}function zoe(){if(ri)return ri.contentWindow;const e=document.characterSet||"UTF-8",t=document.doctype,n=t?`<!DOCTYPE ${r(t.name)} ${r(t.publicId)} ${r(t.systemId)}`.trim()+">":"";return ri=document.createElement("iframe"),ri.id="domtoimage-sandbox-"+St.uid(),ri.className="domtoimage-thino",ri.style.visibility="hidden",ri.style.position="fixed",document.body.appendChild(ri),o(ri,n,e,"domtoimage-sandbox");function r(i){if(i){const a=document.createElement("div");return a.innerText=i,a.innerHTML}else return""}function o(i,a,s,l){try{return i.contentWindow.document.write(`${a}<html><head><meta charset='${s}'><title>${l}</title></head><body></body></html>`),i.contentWindow}catch{}const u=document.createElement("meta");u.setAttribute("charset",s);try{const d=document.implementation.createHTMLDocument(l);d.head.appendChild(u);const h=a+d.documentElement.outerHTML;return i.setAttribute("srcdoc",h),i.contentWindow}catch{}return i.contentDocument.head.appendChild(u),i.contentDocument.title=l,i.contentWindow}}function Voe(){ri&&(document.body.removeChild(ri),ri=null),Jy&&clearTimeout(Jy),Jy=setTimeout(()=>{Jy=null,Wb={}},20*1e3)}async function Woe(e,t,n){return await Ft.toCanvas(e,{width:e.clientWidth,height:e.clientHeight,quality:1,scale:t?2:1,requestUrl:N.requestUrl,type:n})}const ES=async(e,t)=>(await Woe(e,!0,"image/jpeg")).toDataURL(),P3=async e=>{e.startsWith("http")&&(e=await Fu(e));const t=e.split("base64,")[1],n=dS(t,"image/png");await r7(n),new N.Notice(E("Send to clipboard successfully"))},Goe=async(e,t)=>{const n=await e.vault.adapter.exists(t);let r="";if(n)r=t;else{const s=e.metadataCache.getFirstLinkpathDest(t,"");if(!s){new N.Notice(E("File not exist"));return}r=s.path}const o=await e.vault.adapter.readBinary(r),i=new Uint8Array(o),a=new Blob([i],{type:"image/png"});await r7(a)},r7=async e=>{const t=new ClipboardItem({"image/png":e});await window.navigator.clipboard.write([t])},j3=1.1,L3=300,R3=20,Zoe=({destroy:e,imgUrl:t,filepath:n,otherIMGEls:r,currentIndex:o})=>{const i=ke.getState().dailyNotesState.settings.ZoomImageWhenViewing,a=D.useRef(null),[s,l]=D.useState(-1),u=ke.getState().dailyNotesState.app,[d,h]=D.useState(o),[p,m]=D.useState(t),[b,v]=D.useState(!1),y={close:D.useRef(null),previous:D.useRef(null),next:D.useRef(null),decrease:D.useRef(null),increase:D.useRef(null),zoom:D.useRef(null),copy:D.useRef(null)};D.useEffect(()=>{!n&&!t||(N.setIcon(y.close.current,"x"),y.previous.current&&N.setIcon(y.previous.current,"arrow-left"),y.next.current&&N.setIcon(y.next.current,"arrow-right"),N.setIcon(y.decrease.current,"zoom-out"),N.setIcon(y.increase.current,"zoom-in"),N.setIcon(y.zoom.current,"circle"),N.setIcon(y.copy.current,"clipboard"))},[y]),D.useEffect(()=>{Le.getImageSize(p).then(({width:L})=>{L!==0?(l(40),i&&!b&&(l(80),v(!0))):l(0)})},[p,i,b]);const S=()=>{let L=d-1;L<0&&(L=r.length-1),h(L),m(r[L].src)},x=()=>{let L=d+1;L>=r.length&&(L=0),h(L),m(r[L].src)},C=()=>{e()},k=()=>{s>30&&l(s-10)},M=()=>{l(s+10)},I=L=>{L.target!==a.current&&L.target===a.current.parentElement&&C()},O=L=>{if(L.ctrlKey){L.preventDefault();const B=a.current,_=L.nativeEvent.offsetX,H=L.nativeEvent.offsetY,U=_/B.clientWidth,G=H/B.clientHeight;let K;L.deltaY>0?K=s/j3:K=s*j3,K>L3?K=L3:K<R3&&(K=R3);const z=s;l(K);const ne=L.currentTarget;ne.scrollLeft+=(K-z)*U,ne.scrollTop+=(K-z)*G}else L.deltaX!==0&&(L.currentTarget.scrollLeft+=L.deltaX)},R=async()=>{if(p&&!n)await P3(t);else if(n){const B=r[d].parentElement.getAttribute("src");if(!B){await P3(p);return}await Goe(u,B)}};return w.jsxs(w.Fragment,{children:[w.jsx("button",{ref:y.close,className:"btn close-btn",onClick:C}),w.jsxs("div",{className:"img-container internal-embed image-embed is-loaded",onClick:I,onWheel:O,children:[w.jsx("img",{className:s<=0?"thino-hidden":"",ref:a,height:s+"%",src:p}),w.jsx("span",{className:"loading-text "+(s===-1?"":"thino-hidden"),children:E("Image is loading...")}),w.jsx("span",{className:"loading-text "+(s===0?"":"thino-hidden"),children:E("😟 Cannot load image, image link maybe broken")})]}),w.jsxs("div",{className:"action-btns-container",children:[r&&r?.length>1&&w.jsxs(w.Fragment,{children:[w.jsx("button",{ref:y.previous,className:"btn",onClick:S}),w.jsx("button",{ref:y.next,className:"btn",onClick:x})]}),w.jsx("button",{ref:y.decrease,className:"btn",onClick:k}),w.jsx("button",{ref:y.increase,className:"btn",onClick:M}),w.jsx("button",{ref:y.zoom,className:"btn",onClick:()=>l(80)}),w.jsx("button",{ref:y.copy,className:"btn",onClick:R})]})]})};function CS({imgUrl:e,filepath:t,otherIMGEls:n,currentIndex:r}){yS({className:"preview-image-dialog"},Zoe,{...{imgUrl:e,otherIMGEls:n,currentIndex:r},filepath:t})}var $oe=class extends Error{constructor(e){super(`react-collapsed: ${e}`)}},C0=(...e)=>(e[0],`${e[1]}`,void 0);function o7(e){const t=D.useRef(e);return D.useEffect(()=>{t.current=e}),D.useCallback((...n)=>t.current?.(...n),[])}function qoe(e,t,n){const[r,o]=D.useState(t),i=D.useRef(typeof e<"u"),a=i.current?e:r,s=o7(n),l=D.useCallback(u=>{const h=typeof u=="function"?u(a):u;i.current||o(h),s?.(h)},[s,a]);return D.useEffect(()=>{C0(!(i.current&&e==null),"`isExpanded` state is changing from controlled to uncontrolled. useCollapse should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled collapse for the lifetime of the component. Check the `isExpanded` prop."),C0(!(!i.current&&e!=null),"`isExpanded` state is changing from uncontrolled to controlled. useCollapse should not switch from uncontrolled to controlled (or vice versa). Decide between using a controlled or uncontrolled collapse for the lifetime of the component. Check the `isExpanded` prop.")},[e]),[a,l]}var Koe="(prefers-reduced-motion: reduce)";function Xoe(){const[e,t]=D.useState(!1);return D.useEffect(()=>{if(typeof window>"u"||typeof window.matchMedia!="function")return;const n=window.matchMedia(Koe);t(n.matches);const r=o=>{t(o.matches)};if(n.addEventListener)return n.addEventListener("change",r),()=>{n.removeEventListener("change",r)};if(n.addListener)return n.addListener(r),()=>{n.removeListener(r)}},[]),e}var Joe=h$.useId||(()=>{});function Qoe(){return Joe()??""}var eie=typeof window<"u"?D.useLayoutEffect:D.useEffect,Yx=!1,tie=0,F3=()=>++tie;function nie(e){const t=e||(Yx?F3():null),[n,r]=D.useState(t);return eie(()=>{n===null&&r(F3())},[]),D.useEffect(()=>{Yx===!1&&(Yx=!0)},[]),n!=null?String(n):void 0}function rie(e){const t=Qoe(),n=nie(e);return typeof e=="string"?e:typeof t=="string"?t:n}function oie(e,t){const n=performance.now(),r={};function o(){r.id=requestAnimationFrame(i=>{i-n>t?e():o()})}return o(),r}function H3(e){e.id&&cancelAnimationFrame(e.id)}function _3(e){return e?.current?e.current.scrollHeight:(C0(!0,"Was not able to find a ref to the collapse element via `getCollapseProps`. Ensure that the element exposes its `ref` prop. If it exposes the ref prop under a different name (like `innerRef`), use the `refKey` property to change it. Example:\n\nconst collapseProps = getCollapseProps({refKey: 'innerRef'})"),0)}function iie(e){if(!e||typeof e=="string")return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function aie(e,t){if(e!=null)if(typeof e=="function")e(t);else try{e.current=t}catch{throw new $oe(`Cannot assign value "${t}" to ref "${e}"`)}}function B3(...e){return e.every(t=>t==null)?null:t=>{e.forEach(n=>{aie(n,t)})}}function sie(e){let t=n=>{};t=n=>{if(!n?.current)return;const{paddingTop:r,paddingBottom:o}=window.getComputedStyle(n.current);C0(!(r&&r!=="0px"||o&&o!=="0px"),`Padding applied to the collapse element will cause the animation to break and not perform as expected. To fix, apply equivalent padding to the direct descendent of the collapse element. Example:
|
|
|
|
|
|
Before: <div {...getCollapseProps({style: {padding: 10}})}>{children}</div>
|
|
|
|
|
|
After: <div {...getCollapseProps()}>
|
|
|
<div style={{padding: 10}}>
|
|
|
{children}
|
|
|
</div>
|
|
|
</div>`)},D.useEffect(()=>{t(e)},[e])}var lie=typeof window>"u"?D.useEffect:D.useLayoutEffect;function cie({duration:e,easing:t="cubic-bezier(0.4, 0, 0.2, 1)",onTransitionStateChange:n=()=>{},isExpanded:r,defaultExpanded:o=!1,hasDisabledAnimation:i,id:a,...s}={}){const l=o7(n),u=rie(a?`${a}`:void 0),[d,h]=qoe(r,o),p=D.useRef(d),[m,b]=D.useState(!1),v=Xoe(),y=i??v,S=D.useRef(),x=D.useRef(),C=D.useRef(null),[k,M]=D.useState(null);sie(C);const I=`${s.collapsedHeight||0}px`;function O(R){if(!C.current)return;const L=C.current;for(const B in R){const _=R[B];_?L.style[B]=_:L.style.removeProperty(B)}}return lie(()=>{if(!C.current||d===p.current)return;p.current=d;function L(H){return y?0:e??iie(H)}const B=H=>`height ${L(H)}ms ${t}`,_=H=>{function U(){d?(O({height:"",overflow:"",transition:"",display:""}),l("expandEnd")):(O({transition:""}),l("collapseEnd")),b(!1)}x.current&&H3(x.current),x.current=oie(U,H)};return b(!0),d?S.current=requestAnimationFrame(()=>{l("expandStart"),O({display:"block",overflow:"hidden",height:I}),S.current=requestAnimationFrame(()=>{l("expanding");const H=_3(C);_(L(H)),C.current&&(C.current.style.transition=B(H),C.current.style.height=`${H}px`)})}):S.current=requestAnimationFrame(()=>{l("collapseStart");const H=_3(C);_(L(H)),O({transition:B(H),height:`${H}px`}),S.current=requestAnimationFrame(()=>{l("collapsing"),O({height:I,overflow:"hidden"})})}),()=>{S.current&&cancelAnimationFrame(S.current),x.current&&H3(x.current)}},[d,I,y,e,t,l]),{isExpanded:d,setExpanded:h,getToggleProps(R){const{disabled:L,onClick:B,refKey:_,...H}={refKey:"ref",onClick(){},disabled:!1,...R},U=k?k.tagName==="BUTTON":void 0,G=R?.[_||"ref"],K={id:`react-collapsed-toggle-${u}`,"aria-controls":`react-collapsed-panel-${u}`,"aria-expanded":d,onClick(J){L||(B?.(J),h(ee=>!ee))},[_||"ref"]:B3(G,M)},z={type:"button",disabled:L?!0:void 0},ne={"aria-disabled":L?!0:void 0,role:"button",tabIndex:L?-1:0};return U===!1?{...K,...ne,...H}:U===!0?{...K,...z,...H}:{...K,...z,...ne,...H}},getCollapseProps(R){const{style:L,refKey:B}={refKey:"ref",style:{},...R},_=R?.[B||"ref"];return{id:`react-collapsed-panel-${u}`,"aria-hidden":!d,"aria-labelledby":`react-collapsed-toggle-${u}`,role:"region",...R,[B||"ref"]:B3(C,_),style:{boxSizing:"border-box",...!m&&!d?{display:I==="0px"?"none":"block",height:I,overflow:"hidden"}:{},...L}}}}}const i7=D.memo(({memoId:e,showOutgoingLinks:t=!0,showIncomingLinks:n=!0})=>{const[r,o]=D.useState([]),[i,a]=D.useState([]),[s,l]=D.useState(null),[u,d]=D.useState(!1),[h,p]=D.useState(!1),m=D.useRef(null);D.useEffect(()=>{!s&&!u&&!h&&(d(!0),(async()=>{const y=de.getMemoById(e);y&&l(y),d(!1)})())},[e,s,u,h]),D.useEffect(()=>{s&&!h&&!u&&(d(!0),(async()=>{try{if(t){const y=[],S=[...s.content.matchAll(fh)];for(const C of S)if(C&&C.length===3){const k=C[2],M=de.getMemoById(k);M&&y.push({...M,createdAtStr:Le.getDateTimeString(M.createdAt),dateStr:Le.getDateString(M.createdAt)})}const x=vS(s.content);for(const C of x){const[k,M]=C.split("#^"),I=M;if(k&&I){const O=await de.getLinkedMemoByBlockId(I,k);O&&(y.some(R=>R.id===O.id)||y.push({...O,createdAtStr:Le.getDateTimeString(O.createdAt),dateStr:Le.getDateString(O.createdAt)}))}}o([...y])}if(n){const y=await de.getLinkedMemos(s.id);let S=[];s.hasId&&s.path&&(S=await de.getLinkedMemosByLinkId(s.hasId,s.path));const x=[...y,...S],C=Array.from(new Map(x.map(k=>[k.id,k])).values());a(C.sort((k,M)=>Le.getTimeStampByDate(M.createdAt)-Le.getTimeStampByDate(k.createdAt)).map(k=>({...k,createdAtStr:Le.getDateTimeString(k.createdAt),dateStr:Le.getDateString(k.createdAt)})))}p(!0)}catch(y){console.error("Error fetching linked memos:",y)}d(!1)})())},[s,t,n,h,u]);const b=D.useCallback(v=>{pa(v)},[]);return w.jsxs("div",{className:tn("reference-links-group",u?"loading":"loaded"),ref:m,children:[u&&w.jsx("div",{className:"links-loading",children:w.jsx("span",{className:"loading-text",children:E("Loading...")})}),h&&w.jsxs(w.Fragment,{children:[t&&r.length>0&&w.jsx("div",{className:"links-section outgoing-links",children:w.jsx("div",{className:"links-list",children:r.map(v=>{const y=d0(jm(v.content)).replaceAll(`
|
|
|
`," ");return w.jsxs("div",{"aria-label":`${E("Linked")} ${v.content}`,className:"link-item",onClick:()=>b(v),children:[w.jsx("div",{className:"link-icon",ref:S=>S&&N.setIcon(S,"circle-dot")}),w.jsxs("div",{className:"link-date",children:[v.dateStr,":"]}),w.jsx("div",{className:"link-content",children:y})]},v.id)})})}),n&&i.length>0&&w.jsx("div",{className:"links-section incoming-links",children:w.jsx("div",{className:"links-list",children:i.map(v=>{const y=d0(jm(v.content)).replaceAll(`
|
|
|
`," ");return w.jsxs("div",{"aria-label":`${E("Linked by")} ${v.content}`,className:"link-item",onClick:()=>b(v),children:[w.jsx("div",{className:"link-icon",ref:S=>S&&N.setIcon(S,"circle-dot-dashed")}),w.jsxs("div",{className:"link-date",children:[v.dateStr,":"]}),w.jsx("div",{className:"link-content",children:y})]},v.id)})})}),h&&!u&&r.length===0&&i.length===0&&null]})]})},(e,t)=>e.memoId===t.memoId&&e.showIncomingLinks===t.showIncomingLinks&&e.showOutgoingLinks===t.showOutgoingLinks),uie=e=>{const{dailyNotesState:{app:t,view:n,settings:r},globalState:{memoListView:o}}=D.useContext(ct),{getCollapseProps:i,getToggleProps:a,isExpanded:s,setExpanded:l}=cie({defaultExpanded:!0,collapsedHeight:r?.ThinoCollapsedHeight??100}),{memo:u,handleMemoContentClick:d,handleMemoDoubleClick:h}=e,p=Y.useRef(null),[m,b]=Y.useState(""),v=Y.useRef(m),y=Y.useRef(0),[S,x]=Y.useState(!1),[C,k]=Y.useState(!1),M=N.debounce((O,R,L)=>{for(const B of O){const{height:_}=B.contentRect,H=R?.ThinoMaxHeight||340,U=_>H;x(U),l(!U),L.disconnect()}},500);D.useEffect(()=>{if(u.content!==v.current){if(r?.OptimizeForCallout&&u.content.split("> [!").length>3&&u.content.split(`
|
|
|
`).length>10&&!C){const O=p.current.createEl("button");O.setText(E("Render content")),O.onclick=async()=>{k(!0),await I()};const R=p.current.createEl("textarea");R.setText(u.content),R.disabled=!0,p.current?.toggleClass(["raw-content"],!0),l(!0),x(!1);return}I()}},[u.content]),D.useEffect(()=>{C&&y.current!==r?.ThinoMaxHeight&&(p?.current.hasChildNodes()&&k(!1),I())},[r?.ThinoMaxHeight]),D.useEffect(()=>{if(!C)return;const O=p.current;if(!O)return;if(!r?.ThinoMaxHeight){l(!0),x(!1);return}const R=new ResizeObserver(L=>{M(L,r,R)});return R.observe(O),()=>R.disconnect()},[C]);const I=async()=>{p.current&&n&&t&&u.content!==v.current&&(p.current.empty(),await N.MarkdownRenderer.render(t,u.content,p.current,u.path,n),p.current?.querySelectorAll(".internal-link")?.forEach(R=>{const L=R,B=L.getAttribute("data-href");if(!B)return;t.metadataCache.getFirstLinkpathDest(B,u.path)||R.classList.add("is-unresolved"),L.addEventListener("mouseover",H=>{H.stopPropagation(),t.workspace.trigger("hover-link",{event:H,source:"thino",hoverParent:n.containerEl,targetEl:L,linktext:B,sourcePath:L.href})})})),v.current=u.content,p.current?.toggleClass(["markdown-rendered"],!0),p.current?.toggleClass(["raw-content"],!1),k&&k(!0),y.current=r?.ThinoMaxHeight||340};return w.jsxs(w.Fragment,{children:[S&&o==="moments"&&w.jsxs(w.Fragment,{children:[w.jsx("button",{className:"thino-collapse-button",...a({style:{display:"block",marginTop:2}}),children:E(s?"Collapse":"Expand")}),!s&&r?.ThinoCollapsedHeight!==0&&w.jsx("div",{className:"thino-collapse-shadowOverlay",onDoubleClick:h})]}),w.jsx("div",{...i({style:{margin:0}}),ref:p,className:"memo-content-text",onClick:O=>d(O,u),onDoubleClick:h,onContextMenu:O=>{O.preventDefault()}}),o==="list"&&r?.enableReferenceLinksGroup&&w.jsx(i7,{memoId:u.id}),S&&o!=="moments"&&w.jsxs(w.Fragment,{children:[!s&&r?.ThinoCollapsedHeight!==0&&w.jsx("div",{className:"thino-collapse-shadowOverlay",onDoubleClick:h}),w.jsx("button",{className:"thino-collapse-button",...a({style:{display:"block",marginTop:2}}),children:E(s?"Collapse":"Expand")})]})]})},a7=D.memo(uie,(e,t)=>e.memo.content===t.memo.content),die=e=>{const[t,n]=D.useState({...e.memo,createdAtStr:Le.getDateTimeString(e.memo.createdAt)}),[r,o]=D.useState([]),[i,a]=D.useState([]);D.useEffect(()=>{(async()=>{try{const h=[],p=[...t.content.matchAll(fh)];for(const x of p)if(x&&x.length===3){const C=x[2],k=de.getMemoById(C);k&&h.push({...k,createdAtStr:Le.getDateTimeString(k.createdAt),dateStr:Le.getDateString(k.createdAt)})}const m=vS(t.content);for(const x of m){const[C,k]=x.split("#^"),M=k;if(C&&M){const I=await de.getLinkedMemoByBlockId(M,C);I&&(h.some(O=>O.id===I.id)||h.push({...I,createdAtStr:Le.getDateTimeString(I.createdAt),dateStr:Le.getDateString(I.createdAt)}))}}o([...h]);const b=await de.getLinkedMemos(t.id);let v=[];t.hasId&&t.path&&(v=await de.getLinkedMemosByLinkId(t.hasId,t.path));const y=[...b,...v],S=Array.from(new Map(y.map(x=>[x.id,x])).values());a(S.sort((x,C)=>Le.getTimeStampByDate(C.createdAt)-Le.getTimeStampByDate(x.createdAt)).map(x=>({...x,createdAtStr:Le.getDateTimeString(x.createdAt),dateStr:Le.getDateString(x.createdAt)})))}catch(h){console.error("Error fetching linked memos:",h)}})()},[t.id,t.hasId,t.path]);const s=D.useCallback(async d=>{const h=d.target;if(h.className==="memo-link-text"){const p=h.dataset?.value,m=de.getMemoById(p??"");if(m){const b={...m,createdAtStr:Le.getDateTimeString(m.createdAt)};o([]),a([]),n(b)}else new N.Notice(E("Thino not found")),h.classList.remove("memo-link-text")}},[]),l=D.useCallback(d=>{o([]),a([]),n({...d,createdAtStr:Le.getDateTimeString(d.createdAt)})},[t.id]),u=D.useCallback(()=>{e.destroy(),Ze.setEditMemoId(t.id)},[t.id]);return w.jsxs(w.Fragment,{children:[w.jsxs("div",{className:"memo-card-container",children:[w.jsxs("div",{className:"header-container",children:[w.jsx("span",{className:"time-text",children:t.createdAtStr}),w.jsxs("div",{className:"btns-container",children:[w.jsx("button",{ref:d=>{d&&N.setIcon(d,"edit")},className:"btn edit-btn",onClick:u}),w.jsx("button",{ref:d=>{d&&N.setIcon(d,"x")},className:"btn close-btn",onClick:e.destroy})]})]}),w.jsx("div",{className:"memo-container",children:w.jsx("div",{className:"memo-content-text",children:w.jsx(a7,{memo:t,handleMemoContentClick:s,handleMemoDoubleClick:()=>{}})})}),w.jsx("div",{className:"layer-container"})]}),r.length>0?w.jsxs("div",{className:"linked-memos-wrapper",children:[w.jsxs("span",{className:"normal-text",children:[E("LINKED")," ",r.length," THINO"," "]}),r.map(d=>{const h=d0(jm(d.content)).replaceAll(`
|
|
|
`," ");return w.jsxs("div",{className:"linked-memo-container",onClick:()=>l(d),children:[w.jsxs("span",{className:"time-text",children:[d.dateStr," "]}),h]},d.id)})]}):null,i.length>0?w.jsxs("div",{className:"linked-memos-wrapper",children:[w.jsxs("span",{className:"normal-text",children:[i.length," THINO ",E("LINK TO THE")," THINO"]}),i.map(d=>{const h=d0(jm(d.content)).replaceAll(`
|
|
|
`," ");return w.jsxs("div",{className:"linked-memo-container",onClick:()=>l(d),children:[w.jsxs("span",{className:"time-text",children:[d.dateStr," "]}),h]},d.id)})]}):null]})};function pa(e){yS({className:"memo-card-dialog"},die,{memo:e})}function fie({mouseEnterDelayMS:e=0,mouseLeaveDelayMS:t=0}={}){const[n,r]=D.useState(!1);let o,i;return[n,{onMouseEnter:()=>{clearTimeout(i),o=window.setTimeout(()=>r(!0),e)},onMouseLeave:()=>{clearTimeout(o),i=window.setTimeout(()=>r(!1),t)}}]}const hie=e=>{const{memo:t,memoListView:n,handlePinMemoClick:r,handleFixMemoClick:o,handleSourceMemoClick:i,handleShowMemoStoryDialog:a,handleCopyMemoClick:s,handleEditMemoClick:l,handleGenMemoImageBtnClick:u,handleMarkMemoClick:d,handleArchiveMemo:h,handleDeleteMemoClick:p,handleSplitMemoClick:m,handleCopyEmbedLink:b,handleReferenceLinksGroupClick:v}=e,y=Ue.getState().query.tag,S=ke.getState().dailyNotesState.settings,x=S.EnabledLocationList.find(U=>U.value==="MULTI"),[C,k]=wh(!1),M=D.useRef(null),I={pinRef:D.useRef(null),fixRef:D.useRef(null),typeRef:D.useRef(null),referenceLinksGroupRef:D.useRef(null),moreRef:D.useRef(null)},[O,R]=fie({mouseEnterDelayMS:500}),L=D.useRef();D.useEffect(()=>{if(!I.typeRef)return;const U=Pm.find(G=>G.title===t.sourceType);N.setIcon(I.typeRef.current,U.icon),N.requireApiVersion("1.4.4")&&N.setTooltip(I.typeRef.current,t.path),I.fixRef&&(N.setIcon(I.fixRef.current,"shield-alert"),N.requireApiVersion("1.4.4")&&N.setTooltip(I.fixRef.current,"Update Thino property")),I.referenceLinksGroupRef&&S?.enableReferenceLinksGroup&&(N.setIcon(I.referenceLinksGroupRef.current,"link"),N.requireApiVersion("1.4.4")&&N.setTooltip(I.referenceLinksGroupRef.current,"Reference links group"))},[I.typeRef,I.referenceLinksGroupRef]),D.useEffect(()=>{I.pinRef&&(t.pinned?(N.setIcon(I.pinRef.current,"pin-off"),N.requireApiVersion("1.4.4")&&N.setTooltip(I.pinRef.current,E("UNPIN"))):(N.setIcon(I.pinRef.current,"pin"),N.requireApiVersion("1.4.4")&&N.setTooltip(I.pinRef.current,E("PIN"))))},[I.pinRef,t.pinned]);const B=N.debounce(()=>{if(O&&I.moreRef.current){if(L.current&&L.current._loaded||L.current?.useNativeMenu||document.body.find(".more-action-btns-wrapper"))return;const U=_(),G=I.moreRef.current.getBoundingClientRect();U.showAtPosition({x:G.left,y:G.bottom})}},200);D.useEffect(()=>{B()},[O]);const _=()=>{const U=new N.Menu;return U.dom.toggleClass(["more-action-btns-wrapper"],!0),U.useNativeMenu?(U.setNoIcon(),U.addItem(G=>{G.setTitle(E("COPY")).onClick(s)}),U.addItem(G=>{G.setTitle(E("EDIT")).onClick(l)}),U.addItem(G=>{G.setTitle(E("SHARE")).onClick(u)})):U.addItem(G=>{const K=G.dom;G.dom.empty(),G.dom.toggleClass(["more-action-btn-group","more-action-menu-item"],!0);const z=K.createEl("span");new N.ExtraButtonComponent(z).setIcon("copy"),z.toggleClass(["menu-item-icon","more-action-item-icon"],!0),z.onclick=ee=>{ee.stopPropagation(),ee.preventDefault(),s(),U.close()};const ne=K.createEl("span");ne.toggleClass(["menu-item-icon","more-action-item-icon"],!0),ne.onclick=ee=>{ee.stopPropagation(),ee.preventDefault(),l(),U.close()},new N.ExtraButtonComponent(ne).setIcon("pencil");const J=K.createEl("span");J.toggleClass(["menu-item-icon","more-action-item-icon"],!0),J.onclick=ee=>{ee.stopPropagation(),ee.preventDefault(),u(),U.close()},new N.ExtraButtonComponent(J).setIcon("share-2")}),U.addSeparator(),t.sourceType==="DAILY"&&(U.addItem(G=>{G.setIcon("copy").setTitle(E("Copy embed link")).onClick(()=>{b(!0)})}),U.addItem(G=>{G.setIcon("copy").setTitle(E("Copy link")).onClick(()=>{b(!1)})}),U.addSeparator()),U.addItem(G=>{G.setIcon("book-open").setTitle(E("READ")).onClick(()=>a(new MouseEvent("click")))}),U.addItem(G=>{G.setIcon("bookmark").setTitle(E("MARK")).onClick(d)}),/(^|\n)#{1,6}\s/g.exec(t.content)?.length>1&&x&&U.addItem(G=>{G.setIcon("separator-horizontal").setTitle(E("SPLIT")).onClick(m)}),U.addItem(G=>{G.setIcon("home").setTitle(E("SOURCE")).onClick(()=>i(t))}),U.addSeparator(),U.addItem(G=>{G.setWarning(!0).setIcon("archive").setTitle(E("ARCHIVE").toUpperCase()).onClick(()=>h(t))}),U.addItem(G=>{G.setWarning(!0).setIcon("trash").setTitle(S.DeleteThinoDirectly?E("DELETE"):E("TRASH BOX").toUpperCase().toUpperCase()).onClick(K=>{if(U.useNativeMenu)p(),U.close();else if(K.stopPropagation(),K.preventDefault(),!C){k(!0),G.setTitle(E("CONFIRM!")).onClick(z=>{p(),U.close()});return}})}),U.addSeparator(),U.addItem(G=>{G.setDisabled(!0).setTitle(Le.getWordCount(t.content.replace(/```[^\S\r\n]*[a-z]*\n.*?\n```/g,""))+` ${E("words")}`)}),U.onHide(()=>{k(!1)}),L.current=U,U},H=U=>{_().showAtMouseEvent(U.nativeEvent)};return w.jsxs("div",{ref:M,className:"memo-top-right-wrapper",children:[y&&S.FilterByMetadata?t.content.includes(y)?w.jsx("span",{className:"tag-text tag-in-content",children:E("Matched via tag in content")}):t.fileInfo?.tags.includes(y)?w.jsx("span",{className:"tag-text tag-in-file",children:E("Matched via tag in file")}):null:null,w.jsxs("div",{className:"btns-container",children:[w.jsx("span",{ref:I.fixRef,className:`btn ${t.sourceType!=="MULTI"||t.id!==""?"thino-hidden":""} fix-memo-btn`,onClick:()=>o(t)}),S?.enableReferenceLinksGroup&&w.jsx("span",{ref:I.referenceLinksGroupRef,className:`btn ${n==="list"||n==="moments"?"thino-hidden":""} reference-links-group-btn`,onClick:v}),w.jsx("span",{ref:I.typeRef,className:`btn ${t.sourceType==="DAILY"?"thino-hidden":""} source-type-btn`,onClick:()=>i(t)}),w.jsx("span",{ref:I.pinRef,className:`btn ${e.memo.pinned?"pinned-btn":"unpinned-btn"} pro`,onClick:r}),w.jsx("span",{...R,ref:U=>{I.moreRef.current=U,U&&N.setIcon(U,"more-horizontal")},onClick:H,className:"btn more-action-btn"})]})]})},pie=e=>{const{memo:t,handleMemoTypeToggle:n,handleShowMemoStoryDialog:r,settings:o}=e,i=t.fileInfo?.frontmatter?.title||t.path.split("/").pop().split(".").shift();return w.jsxs("div",{className:"memo-top-left-wrapper",children:[e.children,w.jsx("span",{title:t.createdAt,className:"time-text",onClick:a=>r(a),children:t.createdAt}),w.jsx("div",{className:`btn memo-type-img ${o?.ShowTaskLabel?"":"thino-hidden"}`,onClick:n,children:t.thinoType!=="JOURNAL"&&w.jsx("input",{className:"task-list-item-checkbox",type:"checkbox",checked:t.thinoType!=="TASK-TODO","data-task":t.thinoType==="TASK-TODO"?"":t.thinoType==="TASK-DONE"?"x":t.thinoType?.slice(5)})}),o?.ShowSourcePath&&(t.sourceType==="FILE"||t.sourceType==="MULTI")&&w.jsx("span",{className:"time-text source-path","aria-label":i,onClick:()=>{Ue.setPathQuery(i)},children:i})]})};function mie(){this.__data__=[],this.size=0}var gie=mie;function vie(e,t){return e===t||e!==e&&t!==t}var cv=vie,yie=cv;function bie(e,t){for(var n=e.length;n--;)if(yie(e[n][0],t))return n;return-1}var MS=bie,wie=MS,Sie=Array.prototype,Tie=Sie.splice;function xie(e){var t=this.__data__,n=wie(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():Tie.call(t,n,1),--this.size,!0}var Iie=xie,kie=MS;function Eie(e){var t=this.__data__,n=kie(t,e);return n<0?void 0:t[n][1]}var Cie=Eie,Mie=MS;function Die(e){return Mie(this.__data__,e)>-1}var Aie=Die,Nie=MS;function Oie(e,t){var n=this.__data__,r=Nie(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}var Pie=Oie,jie=gie,Lie=Iie,Rie=Cie,Fie=Aie,Hie=Pie;function Sh(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Sh.prototype.clear=jie;Sh.prototype.delete=Lie;Sh.prototype.get=Rie;Sh.prototype.has=Fie;Sh.prototype.set=Hie;var DS=Sh,_ie=DS;function Bie(){this.__data__=new _ie,this.size=0}var Yie=Bie;function Uie(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}var zie=Uie;function Vie(e){return this.__data__.get(e)}var Wie=Vie;function Gie(e){return this.__data__.has(e)}var Zie=Gie,$ie=Ju,qie=$ie(Object,"create"),AS=qie,Y3=AS;function Kie(){this.__data__=Y3?Y3(null):{},this.size=0}var Xie=Kie;function Jie(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var Qie=Jie,eae=AS,tae="__lodash_hash_undefined__",nae=Object.prototype,rae=nae.hasOwnProperty;function oae(e){var t=this.__data__;if(eae){var n=t[e];return n===tae?void 0:n}return rae.call(t,e)?t[e]:void 0}var iae=oae,aae=AS,sae=Object.prototype,lae=sae.hasOwnProperty;function cae(e){var t=this.__data__;return aae?t[e]!==void 0:lae.call(t,e)}var uae=cae,dae=AS,fae="__lodash_hash_undefined__";function hae(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=dae&&t===void 0?fae:t,this}var pae=hae,mae=Xie,gae=Qie,vae=iae,yae=uae,bae=pae;function Th(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Th.prototype.clear=mae;Th.prototype.delete=gae;Th.prototype.get=vae;Th.prototype.has=yae;Th.prototype.set=bae;var wae=Th,U3=wae,Sae=DS,Tae=WM;function xae(){this.size=0,this.__data__={hash:new U3,map:new(Tae||Sae),string:new U3}}var Iae=xae;function kae(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var Eae=kae,Cae=Eae;function Mae(e,t){var n=e.__data__;return Cae(t)?n[typeof t=="string"?"string":"hash"]:n.map}var NS=Mae,Dae=NS;function Aae(e){var t=Dae(this,e).delete(e);return this.size-=t?1:0,t}var Nae=Aae,Oae=NS;function Pae(e){return Oae(this,e).get(e)}var jae=Pae,Lae=NS;function Rae(e){return Lae(this,e).has(e)}var Fae=Rae,Hae=NS;function _ae(e,t){var n=Hae(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}var Bae=_ae,Yae=Iae,Uae=Nae,zae=jae,Vae=Fae,Wae=Bae;function xh(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}xh.prototype.clear=Yae;xh.prototype.delete=Uae;xh.prototype.get=zae;xh.prototype.has=Vae;xh.prototype.set=Wae;var yD=xh,Gae=DS,Zae=WM,$ae=yD,qae=200;function Kae(e,t){var n=this.__data__;if(n instanceof Gae){var r=n.__data__;if(!Zae||r.length<qae-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new $ae(r)}return n.set(e,t),this.size=n.size,this}var Xae=Kae,Jae=DS,Qae=Yie,ese=zie,tse=Wie,nse=Zie,rse=Xae;function Ih(e){var t=this.__data__=new Jae(e);this.size=t.size}Ih.prototype.clear=Qae;Ih.prototype.delete=ese;Ih.prototype.get=tse;Ih.prototype.has=nse;Ih.prototype.set=rse;var bD=Ih,ose="__lodash_hash_undefined__";function ise(e){return this.__data__.set(e,ose),this}var ase=ise;function sse(e){return this.__data__.has(e)}var lse=sse,cse=yD,use=ase,dse=lse;function M0(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new cse;++t<n;)this.add(e[t])}M0.prototype.add=M0.prototype.push=use;M0.prototype.has=dse;var s7=M0;function fse(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}var l7=fse;function hse(e,t){return e.has(t)}var c7=hse,pse=s7,mse=l7,gse=c7,vse=1,yse=2;function bse(e,t,n,r,o,i){var a=n&vse,s=e.length,l=t.length;if(s!=l&&!(a&&l>s))return!1;var u=i.get(e),d=i.get(t);if(u&&d)return u==t&&d==e;var h=-1,p=!0,m=n&yse?new pse:void 0;for(i.set(e,t),i.set(t,e);++h<s;){var b=e[h],v=t[h];if(r)var y=a?r(v,b,h,t,e,i):r(b,v,h,e,t,i);if(y!==void 0){if(y)continue;p=!1;break}if(m){if(!mse(t,function(S,x){if(!gse(m,x)&&(b===S||o(b,S,n,r,i)))return m.push(x)})){p=!1;break}}else if(!(b===v||o(b,v,n,r,i))){p=!1;break}}return i.delete(e),i.delete(t),p}var u7=bse,wse=Ta,Sse=wse.Uint8Array,d7=Sse;function Tse(e){var t=-1,n=Array(e.size);return e.forEach(function(r,o){n[++t]=[o,r]}),n}var xse=Tse;function Ise(e){var t=-1,n=Array(e.size);return e.forEach(function(r){n[++t]=r}),n}var wD=Ise,z3=ph,V3=d7,kse=cv,Ese=u7,Cse=xse,Mse=wD,Dse=1,Ase=2,Nse="[object Boolean]",Ose="[object Date]",Pse="[object Error]",jse="[object Map]",Lse="[object Number]",Rse="[object RegExp]",Fse="[object Set]",Hse="[object String]",_se="[object Symbol]",Bse="[object ArrayBuffer]",Yse="[object DataView]",W3=z3?z3.prototype:void 0,Ux=W3?W3.valueOf:void 0;function Use(e,t,n,r,o,i,a){switch(n){case Yse:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case Bse:return!(e.byteLength!=t.byteLength||!i(new V3(e),new V3(t)));case Nse:case Ose:case Lse:return kse(+e,+t);case Pse:return e.name==t.name&&e.message==t.message;case Rse:case Hse:return e==t+"";case jse:var s=Cse;case Fse:var l=r&Dse;if(s||(s=Mse),e.size!=t.size&&!l)return!1;var u=a.get(e);if(u)return u==t;r|=Ase,a.set(e,t);var d=Ese(s(e),s(t),r,o,i,a);return a.delete(e),d;case _se:if(Ux)return Ux.call(e)==Ux.call(t)}return!1}var zse=Use;function Vse(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}var SD=Vse,Wse=SD,Gse=Hr;function Zse(e,t,n){var r=t(e);return Gse(e)?r:Wse(r,n(e))}var f7=Zse;function $se(e,t){for(var n=-1,r=e==null?0:e.length,o=0,i=[];++n<r;){var a=e[n];t(a,n,e)&&(i[o++]=a)}return i}var qse=$se;function Kse(){return[]}var h7=Kse,Xse=qse,Jse=h7,Qse=Object.prototype,ele=Qse.propertyIsEnumerable,G3=Object.getOwnPropertySymbols,tle=G3?function(e){return e==null?[]:(e=Object(e),Xse(G3(e),function(t){return ele.call(e,t)}))}:Jse,TD=tle;function nle(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}var rle=nle,ole=9007199254740991,ile=/^(?:0|[1-9]\d*)$/;function ale(e,t){var n=typeof e;return t=t??ole,!!t&&(n=="number"||n!="symbol"&&ile.test(e))&&e>-1&&e%1==0&&e<t}var xD=ale,sle=rle,lle=pS,cle=Hr,ule=Qg,dle=xD,fle=gS,hle=Object.prototype,ple=hle.hasOwnProperty;function mle(e,t){var n=cle(e),r=!n&&lle(e),o=!n&&!r&&ule(e),i=!n&&!r&&!o&&fle(e),a=n||r||o||i,s=a?sle(e.length,String):[],l=s.length;for(var u in e)(t||ple.call(e,u))&&!(a&&(u=="length"||o&&(u=="offset"||u=="parent")||i&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||dle(u,l)))&&s.push(u);return s}var p7=mle,gle=p7,vle=B8,yle=Qu;function ble(e){return yle(e)?gle(e):vle(e)}var kh=ble,wle=f7,Sle=TD,Tle=kh;function xle(e){return wle(e,Tle,Sle)}var m7=xle,Z3=m7,Ile=1,kle=Object.prototype,Ele=kle.hasOwnProperty;function Cle(e,t,n,r,o,i){var a=n&Ile,s=Z3(e),l=s.length,u=Z3(t),d=u.length;if(l!=d&&!a)return!1;for(var h=l;h--;){var p=s[h];if(!(a?p in t:Ele.call(t,p)))return!1}var m=i.get(e),b=i.get(t);if(m&&b)return m==t&&b==e;var v=!0;i.set(e,t),i.set(t,e);for(var y=a;++h<l;){p=s[h];var S=e[p],x=t[p];if(r)var C=a?r(x,S,p,t,e,i):r(S,x,p,e,t,i);if(!(C===void 0?S===x||o(S,x,n,r,i):C)){v=!1;break}y||(y=p=="constructor")}if(v&&!y){var k=e.constructor,M=t.constructor;k!=M&&"constructor"in e&&"constructor"in t&&!(typeof k=="function"&&k instanceof k&&typeof M=="function"&&M instanceof M)&&(v=!1)}return i.delete(e),i.delete(t),v}var Mle=Cle,zx=bD,Dle=u7,Ale=zse,Nle=Mle,$3=Jg,q3=Hr,K3=Qg,Ole=gS,Ple=1,X3="[object Arguments]",J3="[object Array]",Qy="[object Object]",jle=Object.prototype,Q3=jle.hasOwnProperty;function Lle(e,t,n,r,o,i){var a=q3(e),s=q3(t),l=a?J3:$3(e),u=s?J3:$3(t);l=l==X3?Qy:l,u=u==X3?Qy:u;var d=l==Qy,h=u==Qy,p=l==u;if(p&&K3(e)){if(!K3(t))return!1;a=!0,d=!1}if(p&&!d)return i||(i=new zx),a||Ole(e)?Dle(e,t,n,r,o,i):Ale(e,t,l,n,r,o,i);if(!(n&Ple)){var m=d&&Q3.call(e,"__wrapped__"),b=h&&Q3.call(t,"__wrapped__");if(m||b){var v=m?e.value():e,y=b?t.value():t;return i||(i=new zx),o(v,y,n,r,i)}}return p?(i||(i=new zx),Nle(e,t,n,r,o,i)):!1}var Rle=Lle,Fle=Rle,ej=xa;function g7(e,t,n,r,o){return e===t?!0:e==null||t==null||!ej(e)&&!ej(t)?e!==e&&t!==t:Fle(e,t,n,r,g7,o)}var ID=g7,Hle=ID;function _le(e,t){return Hle(e,t)}var Ble=_le;const ws=tt(Ble);class Yle extends N.SuggestModal{constructor(t,n){super(t),this.thino=n}sanitisedFileName(t){const n=Dq;return t.replace(n,"").trim().slice(0,255)}ensureUniqueFileNames(t){const n=[];return t.map(o=>{const i=this.sanitisedFileName(o[0]),a=n.filter(s=>s==i);return n.push(i),a.length>=1?`${i}${a.length+1}`:i})}contentSplitByHeading(t,n){const r=t.split(`
|
|
|
`),o=new Array(n).join("#")+" ",i=new Array(n+1).join("#")+" ",a=[];let s=[];return r.forEach((l,u)=>{l.startsWith(i)?(s.length>0&&(a.push(s),s=[]),s.push(l)):s.length>0&&!l.startsWith(o)?s.push(l):s.length>0&&(a.push(s),s=[]),u===r.length-1&&s.length>0&&a.push(s)}),a}onChooseSuggestion(t,n){this.selectSuggestion(t,n)}renderSuggestion(t,n){n.setText(t.title)}getSuggestions(){return[{id:"splitByHeading1",title:E("Split by Heading 1")},{id:"splitByHeading2",title:E("Split by Heading 2")},{id:"splitByHeading3",title:E("Split by Heading 3")}]}async selectSuggestion(t,n){let r=[];if(t.id==="splitByHeading1"?r=this.contentSplitByHeading(this.thino.content,1):t.id==="splitByHeading2"?r=this.contentSplitByHeading(this.thino.content,2):t.id==="splitByHeading3"&&(r=this.contentSplitByHeading(this.thino.content,3)),r.length===0){new N.Notice("No headings found"),this.close();return}const o=this.ensureUniqueFileNames(r);for(const s of r){const l=r.indexOf(s),u=await de.createThino({content:s.join(`
|
|
|
`),name:o[l],type:"MULTI",isList:!0});de.pushMemo(u)}let i=this.thino.content;r.forEach((s,l)=>{i=i.replace(s.join(`
|
|
|
`),`[[${o[l]}]]`)});const a=await de.updateMemo(this.thino.id,i);a&&de.editMemo(a),this.close()}}const Ule=async(e,t,n)=>{const r=n.getAttribute("href"),o=n.className;if(o.contains("tag"))zle(n.innerText.slice(1));else if(o.contains("internal-link")){const i=n.getAttribute("data-href"),a=de.getMemoById(i??"");a?pa(a):await e.workspace.openLinkText(i,i,!N.Platform.isMobile&&t.navigation!==!0)}else r&&window.open(r,"_blank")},zle=e=>{const t=Ue.getState().query.tag;Ue.setTagQuery(t.contains(",")?t.split(",").includes(e)?t.split(",").filter(n=>n!==e).join(","):t+","+e:t===e?"":e)},Vle=(e,t)=>{const n=t?.getAttribute("src"),r=t?.parentElement.getAttribute("src"),o=[...e?.querySelectorAll("img")||[]],i=o.indexOf(t);CS({imgUrl:n,filepath:n.startsWith("app")?r:void 0,otherIMGEls:o,currentIndex:i})},Wle=e=>{const t=e.dataset?.value,n=de.getMemoById(t??"");n?pa(n):(new N.Notice("Thino Not Found"),e.classList.remove("memo-link-text"))},Gle=async(e,t,n,r)=>{const o=e?.AppendDateWhenTaskDone?" ✅ "+N.moment().format("YYYY-MM-DD"):"",i=r.parentElement.dataset?.task==="x"?"DONE":"TODO",a=[...n?.querySelectorAll("li.task-list-item")||[]];for(const s of a)if(s===r||s===r.closest("li.task-list-item")){const l=a.indexOf(s),u=t.content.split(/\n/),d=[];for(let y=0;y<u.length;y++)/^\s*(-|\*|\d+\.)\s\[.\]\s/.test(u[y])&&d.push(y);const h=d[l],p=u[h],m=p.match(/^\s*(-|\*|\d+\.)\s\[.\]\s/)[0];let b=p.replace(/^\s*(-|\*|\d+\.)\s\[.\]\s/,m.replace(/\[.\]/,i==="TODO"?"[x]":"[ ]"))+(i==="TODO"?o:"");e.AppendDateWhenTaskDone&&i!=="TODO"&&(b=b.replace(/ ✅ \d{4}-\d{2}-\d{2}/g,"")),u[h]=b;const v=u.join(`
|
|
|
`).trim();if(t&&t.content!==v){const y=await de.updateMemo(t.id,v);de.editMemo(y)}}},Zle=e=>{const{globalState:{editMemoId:t,memoListView:n},dailyNotesState:{app:r,view:o,settings:i,verifyState:a},locationState:{pathname:s}}=D.useContext(ct),{memo:l,type:u="inline"}=e,d=D.useRef(null),h=D.useRef(null),[p,m]=D.useState(!1),b=D.useRef(null),[v,y]=D.useState(!1);D.useEffect(()=>{p&&setTimeout(()=>{Ze.setEditMemoId(l.id)},100)},[p]),D.useEffect(()=>{(s==="/review"||s==="/daily")&&t!==l.id&&p&&m(!1)},[t]),D.useEffect(()=>{b.current&&!v&&d.current&&(r.dragManager.handleDrag(b.current,$=>{r.dragManager.updateSource([d.current],"is-dragging");const re=de.getMemoById(l.id);if($.dataTransfer.setData("text/plain",l.content),$.dataTransfer.setData("text/uri-list",l.content),$.dataTransfer.setData("Text",l.content),i?.DraggingBehavior==="block-link")if(re?.sourceType==="DAILY"){const le=r.vault.getFileByPath(re.path);let ie=re.hasId;return re.hasId||(ie=Le.randomId(6),si(re,{id:re.id,hasId:ie})),{type:"link",icon:"lucide-link",title:le.basename,linktext:`${re.path}#^${ie}`,sourcePath:re.path,file:le,memo:re,blockId:ie,source:"thino-plugin"}}else return null;else if(i?.DraggingBehavior==="text")return null}),y(!0))},[b.current,d.current,i?.DraggingBehavior]);const S=$=>{if($.ctrlKey||$.metaKey){const re=N.moment(l.createdAt,"YYYY/MM/DD HH:mm:ss");Ue.setFromAndToQuery(re.startOf("day").valueOf(),re.endOf("day").valueOf());return}pa(l)},x=()=>{if(i?.UseButtonToShowEditor&&i?.DefaultEditorLocation==="Bottom"){const $=document.querySelector("div[data-type='thino_view'] .view-content .memo-show-editor-button:not(.thino-hidden)");$&&$.trigger("click")}Ze.setMarkMemoId(l.id)},C=async()=>{const $=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),re=N.Platform.isDesktop?await Sn():$.identifier||$.uuid;if(!a||a?.appId!==re){Nt();return}l.pinned?await de.unpinMemoById(l.id):await de.pinMemoById(l.id)},k=()=>{if(i?.UseButtonToShowEditor&&i?.DefaultEditorLocation==="Bottom"&&N.Platform.isMobile){const $=document.querySelector("div[data-type='thino_view'] .view-content .memo-show-editor-button:not(.thino-hidden)");$&&$.trigger("click")}(s==="/review"||s==="/daily")&&m(!0),s!=="/review"&&s!=="/daily"&&Ze.setEditMemoId(l.id)},M=async $=>{$.sourceType==="MULTI"&&$.id.trim()===""&&await de.updateMemoProperty($)},I=async $=>{await de.openThinoByID($.id)},O=async $=>{try{const re=await de.archiveMemo($);re&&de.editMemo(re)}catch(re){console.error(re),new N.Notice(re.message)}},R=async()=>{try{if(i.DeleteThinoDirectly)await de.deleteMemoById(l.id);else{const $=await de.hideMemoById(l.id);$&&de.editMemo($)}}catch($){new N.Notice($.message)}Ze.getState().editMemoId===l.id&&Ze.setEditMemoId("")},L=()=>{if(h.current&&!h.current.confirmStatus){h.current&&h.current.toggleConfirm(!1);return}},B=()=>{yu(l)},_=async()=>{const $=await de.updateMemo(l.id,l.content,l.thinoType==="TASK-TODO"?"TASK-DONE":"TASK-TODO");$&&de.editMemo($)},H=async()=>{navigator.clipboard.writeText(l.content).then(()=>{new N.Notice(E("COPY SUCCEED"))}).catch(()=>{new N.Notice(E("COPY FAILED"))})},U=async()=>{new Yle(r,l).open()},G=$=>{if(!$||$.target.tagName==="INPUT")return;switch(i?.doubleClickBehavior||"edit-thino"){case"open-thino":pa(l);break;case"edit-thino":k();break;case"go-to-source":I(l);break;case"do-nothing":break;default:k();break}},K=async($,re)=>{$.preventDefault(),$.stopPropagation();const le=$.target;if($.ctrlKey||$.metaKey){await I(re);return}if(le.tagName==="A"){await Ule(r,o,le);return}if(le.tagName==="IMG"){Vle(d.current,le);return}if(le.tagName==="A"&&le.getAttribute("href")){const ie=le.getAttribute("href");window.open(ie,"_blank");return}if(le.className==="memo-link-text"){Wle(le);return}if(le.tagName==="INPUT"&&le.hasClass("task-list-item-checkbox")){await Gle(i,re,d.current,le);return}},z=async $=>{const re=await q8(l,$);navigator.clipboard.writeText(re),new N.Notice(E("COPY SUCCEED"))},ne=$=>{const re=new N.Menu;re.dom.toggleClass("memo-context-menu",!0);const le=window.getSelection();le?.toString().length>0&&re.addItem(ie=>{ie.setIcon("copy").setTitle(E("Copy selected text")).onClick(()=>{navigator.clipboard.writeText(le.toString()).then(()=>{new N.Notice(E("COPY SUCCEED"))}).catch(()=>{new N.Notice(E("COPY FAILED"))})})}).addSeparator(),l.sourceType==="DAILY"&&(re.addItem(ie=>{ie.setIcon("link").setTitle(E("Copy embed link")).onClick(()=>{z(!0)})}),re.addItem(ie=>{ie.setIcon("link").setTitle(E("Copy link")).onClick(()=>{z(!1)})}),re.addSeparator()),i?.enableReferenceLinksGroup&&n!=="list"&&re.addItem(ie=>{ie.setIcon("link").setTitle(E("Reference links group")).onClick(()=>J($))}),re.addItem(ie=>{ie.setIcon("copy").setTitle(E("Copy thino").toLocaleUpperCase()).onClick(async()=>{await H(),re.close()})}).addItem(ie=>{ie.setIcon("book-open").setTitle(E("READ")).onClick(()=>S($))}).addItem(ie=>{ie.setIcon(l.pinned?"pin-off":"pin").setTitle(l.pinned?E("UNPIN"):E("PIN")).onClick(C)}).addItem(ie=>{ie.setIcon("bookmark").setTitle(E("MARK")).onClick(x)}).addItem(ie=>{ie.setIcon("share-2").setTitle(E("SHARE")).onClick(B)}).addItem(ie=>{ie.setIcon("pencil").setTitle(E("EDIT")).onClick(k)}).addItem(ie=>{ie.setIcon("home").setTitle(E("SOURCE")).onClick(()=>I(l))}).addSeparator().addItem(ie=>{ie.setIcon("archive").setWarning(!0).setTitle(E("ARCHIVE").toLocaleUpperCase()).onClick(()=>O(l))}).addItem(ie=>{ie.setIcon("trash").setWarning(!0).setTitle(E("DELETE")).onClick(async()=>{await R()})}),re.showAtMouseEvent($.nativeEvent)},J=$=>{$.stopPropagation(),$.preventDefault();const re=new N.Menu;(async()=>{try{const ie=[],fe=[],ye=[...l.content.matchAll(fh)];for(const Fe of ye)if(Fe&&Fe.length===3){const ce=Fe[2],Ne=de.getMemoById(ce);Ne&&ie.push({...Ne,createdAtStr:Le.getDateTimeString(Ne.createdAt),dateStr:Le.getDateString(Ne.createdAt)})}const ge=vS(l.content);for(const Fe of ge){const[ce,Ne]=Fe.split("#^"),Pe=Ne;if(ce&&Pe){const _e=await de.getLinkedMemoByBlockId(Pe,ce);_e&&(ie.some(qe=>qe.id===_e.id)||ie.push({..._e,createdAtStr:Le.getDateTimeString(_e.createdAt),dateStr:Le.getDateString(_e.createdAt)}))}}const me=await de.getLinkedMemos(l.id);let Ce=[];l.hasId&&l.path&&(Ce=await de.getLinkedMemosByLinkId(l.hasId,l.path));const je=[...me,...Ce];Array.from(new Map(je.map(Fe=>[Fe.id,Fe])).values()).sort((Fe,ce)=>Le.getTimeStampByDate(ce.createdAt)-Le.getTimeStampByDate(Fe.createdAt)).forEach(Fe=>{fe.push({...Fe,createdAtStr:Le.getDateTimeString(Fe.createdAt),dateStr:Le.getDateString(Fe.createdAt)})}),re.addSections(["Outgoing","Incoming"]),ie.length>0&&ie.forEach(Fe=>{re.addItem(ce=>{const Ne=Fe.content.length>10?Fe.content.substring(0,10)+"...":Fe.content;ce.setTitle(Ne).setIcon("arrow-right").onClick(()=>{pa(Fe)})})}),fe.length>0&&fe.forEach(Fe=>{re.addItem(ce=>{const Ne=Fe.content.length>10?Fe.content.substring(0,10)+"...":Fe.content;ce.setTitle(Ne).setSection("Incoming").setIcon("arrow-left").onClick(()=>{pa(Fe)})})}),ie.length===0&&fe.length===0&&re.addItem(Fe=>{Fe.setDisabled(!0).setTitle(E("No reference links found"))}),re.showAtMouseEvent($.nativeEvent)}catch(ie){console.error("Error fetching linked memos:",ie),new N.Notice(E("Error fetching reference links"))}})()},ee=D.useMemo(()=>({memo:l,memoListView:n,handlePinMemoClick:C,handleFixMemoClick:M,handleSourceMemoClick:I,handleArchiveMemo:O,handleDeleteMemoClick:R,handleGenMemoImageBtnClick:B,handleMarkMemoClick:x,handleEditMemoClick:k,handleCopyMemoClick:H,handleShowMemoStoryDialog:S,handleSplitMemoClick:U,handleCopyEmbedLink:z,handleReferenceLinksGroupClick:J}),[l]),Z=D.useMemo(()=>({memo:l,handleMemoTypeToggle:_,handleShowMemoStoryDialog:S,settings:i}),[l,i]),q=D.useMemo(()=>w.jsxs("div",{ref:d,className:`memo-wrapper ${l.pinned?"pinned":""}`,"data-source-type":l.sourceType,"data-thino-type":l.thinoType,"data-thino-id":l.id,onMouseLeave:L,onMouseOver:$=>{$.shiftKey&&($.stopPropagation(),r.workspace.trigger("hover-link",{event:$,source:"thino",hoverParent:o.containerEl,targetEl:d.current,linktext:l.path,sourcePath:l.path,state:{scroll:l.sourceType==="DAILY"?parseInt(l.id.slice(14)):0}}))},onContextMenu:ne,children:[p&&w.jsx(Du,{editorType:"inline"}),!p&&w.jsxs(w.Fragment,{children:[u==="inline"&&w.jsxs("div",{ref:b,className:"memo-top-wrapper",draggable:!0,children:[w.jsx(pie,{...Z}),w.jsx(hie,{...ee})]}),w.jsx(a7,{memo:l,handleMemoContentClick:K,handleMemoDoubleClick:G})]})]}),[l,p]);return w.jsx(w.Fragment,{children:q})},vo=D.memo(Zle,(e,t)=>ws(e.memo,t.memo));class Oe extends N.Setting{settingTab;name="";desc="";constructor(t,n){super(t),this.settingTab=n}setName(t){return super.setName(t),this.name=t,this}setDesc(t){return super.setDesc(t),this.desc=t,this}setTab(t){const n=typeof this.name=="string"?this.name:this.name.textContent||"",r=typeof this.desc=="string"?this.desc:this.desc.textContent||"";return this.settingTab.addSettingToMasterSettingsList(t,this.settingEl,n,r),this}}class $le extends N.Modal{plugin;settingTab;target=5;cb;constructor(t,n,r,o,i){super(t),this.app=t,this.settingTab=n,this.plugin=r,this.target=o,this.cb=i}onOpen(){const{contentEl:t}=this;t.parentElement?.classList.add("memo-save-location-modal"),t.createEl("h3",{text:E("Thino Daily Target")});const n=t.createDiv("modal-setting");new Oe(n,this.settingTab).setName(E("Target Thino Count")).addSlider(a=>{a.setDynamicTooltip().setValue(this.target).setLimits(1,30,1).onChange(async s=>{this.target=s})});const r=t.createDiv("button-group"),o=r.createEl("button",{text:E("Cancel")}),i=r.createEl("button",{text:E("Save")});i.onclick=async()=>{this.plugin.settings.MemoDailyTarget=this.target,this.settingTab.applySettingsUpdate(),this.cb(this.target),this.close()},o.onclick=async()=>{this.close()}}onClose(){const{contentEl:t}=this;t.empty()}}const qle=({allStat:e,todayTimeStamp:t,calendarType:n,handleCalendarTypeChange:r})=>{const{dailyNotesState:{app:o,settings:i},globalState:{manifest:a}}=D.useContext(ct),[s,l]=D.useState(),[u,d]=D.useState(5),[h,p]=D.useState(0),[m,b]=D.useState(0),[v,y]=D.useState(i.HeatmapColorScheme||"default"),S=D.useRef(null),x=D.useRef(null);D.useEffect(()=>{i.HeatmapColorScheme&&y(i.HeatmapColorScheme)},[i.HeatmapColorScheme]),D.useEffect(()=>{let k,M=5;a&&o&&(k=o?.plugins.getPlugin(a.id),M=k?.settings.MemoDailyTarget,l(k)),d(M)},[a,o]),D.useEffect(()=>{const k=e.find(O=>O.timestamp===t),M=k?k.count:0;b(M);const I=Math.min(100,M/u*100);p(I)},[e,u]),D.useEffect(()=>{N.requireApiVersion("1.4.4")&&(N.setTooltip(x.current,h.toFixed(2)+"%"),N.setTooltip(S.current,E("Set daily target")+` (${m}/${u})`))},[h,m]),D.useEffect(()=>{S.current&&(S.current.hasChildNodes()||N.setIcon(S.current,"crosshair"),N.requireApiVersion("1.4.4")&&N.setTooltip(x.current,h+"%"))},[S,u]);const C=D.useCallback(()=>{if(!s)return;new $le(o,s?.settingTab,s,u,M=>{d(M)}).open()},[s,u]);return w.jsx(w.Fragment,{children:w.jsxs("div",{className:`usage-daily-progress-wrapper heatmap-${v}`,children:[w.jsx("div",{ref:x,className:"daily-progress-bar",children:w.jsx("div",{className:"daily-progress-bar-inner",style:{width:`${h}%`}})}),w.jsx("div",{ref:S,className:"daily-progress-target",onClick:C}),w.jsx("div",{ref:k=>{k&&N.setIcon(k,n==="basic"?"layout-grid":"calendar"),k&&N.setTooltip&&N.setTooltip(k,E("Switch calendar type"))},className:"switch-calendar-type-btn",onClick:()=>r&&r(n==="basic"?"heatmap":"basic")})]})})},Kle=(e,t)=>{const n=[],r=Math.floor((e-t)/Uo);for(let o=0;o<=r;o++)n.push({timestamp:t+Uo*o,count:0,list:0});return n},Xle=e=>{const{className:t,view:n,datestamp:r,handleDateStampChange:o,handleDateItemClick:i,handleMonthChange:a,dailyStat:s}=e,l=N.moment().startOf("day").valueOf(),[u,d]=D.useState(Ud(r)),[h,p]=D.useState(null),[m,b]=D.useState(e.dailyStat);D.useEffect(()=>{d(Ud(r));const k=Kle(Qle(r),Ud(r)),M=e.thinos.filter(I=>!I.deletedAt&&I.rowStatus!=="ARCHIVED");for(const I of M){const R=N.moment(I.createdAt,"YYYY/MM/DD HH:mm:ss").startOf("day").diff(N.moment(u).startOf("day"),"days");R>=0&&R<k.length&&(k[R].count+=1,I.thinoType==="JOURNAL"&&(k[R].list+=1))}b(k)},[r,e.thinos]);const v=new Date(u),y=v.getDay(),S=[];for(let k=0;k<y;k++)S.push({date:0,datestamp:v.getTime()-Uo*(7-k)});const x=Jle(u);for(let k=1;k<=x;k++)S.push({date:k,datestamp:v.getTime()+Uo*(k-1)});const C=k=>{const M=v.getFullYear(),I=v.getMonth()+1;let O=0;I===1&&k===-1?O=new Date(`${M-1}/12/1`).getTime():I===12&&k===1?O=new Date(`${M+1}/1/1`).getTime():O=new Date(`${M}/${I+k}/1`).getTime(),d(Ud(O)),a&&a(O)};return w.jsxs("div",{className:`heatmap-date-picker-wrapper ${t}`,children:[w.jsxs("div",{className:"date-picker-header",children:[w.jsx("span",{ref:k=>{k&&N.setIcon(k,"chevron-left")},className:"btn btn-text",onClick:()=>C(-1)}),w.jsxs("span",{className:"normal-text",children:[w.jsx(AH,{year:v.getFullYear().toString(),handleYearChange:k=>{d(Ud(new Date(`${k}/${v.getMonth()+1}/1`).getTime()))}}),w.jsx(NH,{month:v.getMonth().toString(),handleMonthChange:k=>{d(Ud(new Date(`${v.getFullYear()}/${parseInt(k)}/1`).getTime()))}})]}),w.jsx("span",{ref:k=>{k&&N.setIcon(k,"chevron-right")},className:"btn btn-text",onClick:()=>C(1)})]}),w.jsxs("div",{className:"date-picker-day-container",children:[w.jsx("div",{className:"date-picker-day-header",children:E("weekDaysShort").map(k=>w.jsx("span",{className:"day-item",children:k},k))}),w.jsx("div",{className:"date-picker-day-content",children:S.map(k=>{if(k.date===0)return w.jsx("span",{className:"day-item null",children:""},k.datestamp);const M=m.find(R=>R.timestamp===k.datestamp)||{count:0,timestamp:k.datestamp,list:0},I=M.count-M.list,O=M.list;return w.jsxs("span",{className:`day-item ${k.datestamp===l?"current":""} ${k.datestamp===h?"selected":""} ${Vx(M.count)}`,onClick:R=>{o(r,R.nativeEvent),p(k.datestamp===h?null:k.datestamp),i&&i(R,M)},onMouseOver:R=>{if(!M||!M.count)return;const L=new N.HoverPopover(n,R.currentTarget,100);v7(L,{d:k,list:O,task:I})},children:[w.jsx("span",{className:"day-item-text",children:k.date}),w.jsx(w.Fragment,{children:M&&M.count!==0&&w.jsxs("span",{className:"day-item-dots",children:[I>0&&w.jsx("div",{className:`day-item-dot thino-task-dot ${Vx(I)}`}),O>0&&w.jsx("div",{className:`day-item-dot thino-list-dot ${Vx(O)}`})]})})]},k.datestamp)})})]})]})};function v7(e,{d:t,list:n,task:r}){e.hoverEl.toggleClass("thino-hover-popover",!0);const o=e.hoverEl.createDiv({cls:"thino-hover-popover-content"});o.createDiv({cls:"thino-date-item",text:`${N.moment(t.datestamp).format("YYYY-MM-DD")}`});const i=o.createDiv({cls:"thino-task-item"});i.createSpan({cls:"thino-task-item-title-text",text:`${E("Task")}: `}),i.createSpan({cls:"thino-task-item-title-count",text:`${r}`});const a=o.createDiv({cls:"thino-list-item"});a.createSpan({cls:"thino-list-item-title-text",text:`${E("List")}: `}),a.createSpan({cls:"thino-list-item-title-count",text:`${n}`})}function Jle(e){const t=new Date(e),n=new Date(`${t.getFullYear()}/${t.getMonth()+1}/1`);return((n.getMonth()===11?new Date(`${n.getFullYear()+1}/1/1`):new Date(`${n.getFullYear()}/${n.getMonth()+2}/1`)).getTime()-n.getTime())/Uo}function Ud(e){const t=new Date(e);return new Date(`${t.getFullYear()}/${t.getMonth()+1}/1`).getTime()}function Qle(e){const t=new Date(e),n=new Date(`${t.getFullYear()}/${t.getMonth()+1}/1`);return(n.getMonth()===11?new Date(`${n.getFullYear()+1}/1/1`):new Date(`${n.getFullYear()}/${n.getMonth()+2}/1`)).getTime()-Uo}function Vx(e){return e<=0?"":e<=1?"stat-day-L1-bg":e<=2?"stat-day-L2-bg":e<=4?"stat-day-L3-bg":"stat-day-L4-bg"}const tj={width:12,height:7},nj=(e,t)=>{const n=[];for(let r=0;r<=e;r++)n.push({timestamp:t+Uo*r,count:0,list:0});return n},_m=({initThinos:e,basicType:t})=>{const n=parseInt(N.moment().endOf("day").format("x"));new Date(n).getDay();const r=parseInt(N.moment().startOf("day").format("x")),o=new Array(6-new Date(n).getDay()).fill(0),i=tj.width*tj.height,a=parseInt(N.moment().startOf("day").subtract(i,"days").format("x")),s=N.moment().startOf("day").subtract(i,"days"),{memoState:{memos:l},dailyNotesState:{view:u,app:d,settings:h,verifyState:p}}=D.useContext(ct),[m,b]=Ho(t||tce(d||window.app)||"heatmap"),[v,y]=Ho(N.moment().startOf("day").valueOf()),[S,x]=Ho(h.HeatmapColorScheme||"default"),[C,k]=Ho(nj(i,a)),[M,I]=Ho(null),[O,R,L]=Ho(""),B=D.useRef(null);D.useEffect(()=>{const J=nj(i,a),ee=(e||l).filter(Z=>!Z.deletedAt&&Z.rowStatus!=="ARCHIVED");for(const Z of ee){const $=N.moment(Z.createdAt.replaceAll("/","-"),"YYYY-MM-DD HH:mm:ss").startOf("day").diff(s,"days");$>=0&&$<J.length&&(J[$].count+=1,Z.thinoType==="JOURNAL"&&(J[$].list+=1))}k([...J])},[l,e]),D.useEffect(()=>{h.HeatmapColorScheme&&x(h.HeatmapColorScheme)},[h.HeatmapColorScheme]);const _=D.useCallback((J,ee)=>{if(!ee||!ee.count)return;const Z=ee.count-ee.list,q=ee.list,$={date:ee.timestamp,datestamp:ee.timestamp},re=new N.HoverPopover(u,J.currentTarget,100);v7(re,{d:$,list:q,task:Z})},[]),H=()=>{b(m==="heatmap"?"basic":"heatmap"),ece(d,m==="heatmap"?"basic":"heatmap"),y(N.moment().startOf("day").valueOf())},U=D.useCallback(async(J,ee)=>{if(ee.count===0){z(ee);return}const Z=Ue.getState().query.duration,q=Z?.from,$=Z?.to,re=N.moment(q).diff($,"day")===0;if(q===ee.timestamp&&re){Ue.setFromAndToQuery(0,0),I(null),R(null);return}if(J.shiftKey){G(ee,q,$);return}if(J.ctrlKey||J.metaKey){await K(ee.timestamp);return}z(ee)},[]),G=(J,ee,Z,q)=>{const $=J.timestamp;if(ee===0){Ue.setFromAndToQuery($,parseInt(N.moment().endOf("day").format("x"))),R("from");return}const re=N.moment($).endOf("day").diff(Z,"day");N.moment(ee).isBefore($)?L.current==="to"?re<0?Ue.setFromAndToQuery($,Z):(Ue.setFromAndToQuery(parseInt(N.moment(Z).startOf("day").format("x")),parseInt(N.moment($).endOf("day").format("x"))),R("from")):L.current==="from"&&Ue.setFromAndToQuery(ee,parseInt(N.moment($).endOf("day").format("x"))):L.current==="to"?Ue.setFromAndToQuery($,Z):L.current==="from"&&(Ue.setFromAndToQuery($,parseInt(N.moment(ee).endOf("day").format("x"))),R("to"))},K=async J=>{const{app:ee,dailyNotes:Z}=$e.getState(),q=lS(N.moment(J),Z);if(q)if(!N.Platform.isMobile)await ee.workspace.getLeaf(!0).openFile(q);else{let $=ee.workspace.activeLeaf;$===null&&($=ee.workspace.getLeaf(!0)),$.openFile(q)}},z=J=>{["/","/recycle"].includes(Ue.getState().pathname)||Ue.setPathname("/"),Ue.setFromAndToQuery(J.timestamp,Le.getTimeStampByDate(N.moment(J.timestamp+Uo).subtract(1,"days").endOf("day").format("YYYY-MM-DD HH:mm:ss"))),I(J)},ne=D.useMemo(()=>w.jsx(Xle,{className:`heatmap-${S}`,view:u,datestamp:v,dailyStat:C,thinos:e||l,handleMonthChange:J=>{y(J)},handleDateStampChange:J=>{},handleDateItemClick:(J,ee)=>U(J,ee)}),[JSON.stringify(C),e,l,u,v,S]);return w.jsxs(w.Fragment,{children:[m==="basic"&&ne,m==="heatmap"&&w.jsxs("div",{className:`usage-heat-map-wrapper heatmap-${S}`,ref:B,children:[w.jsxs("div",{className:"day-tip-text-container",children:[w.jsx("span",{className:"tip-text",children:E("weekDaysShort")[0]}),w.jsx("span",{className:"tip-text"}),w.jsx("span",{className:"tip-text",children:E("weekDaysShort")[2]}),w.jsx("span",{className:"tip-text"}),w.jsx("span",{className:"tip-text",children:E("weekDaysShort")[4]}),w.jsx("span",{className:"tip-text"}),w.jsx("span",{className:"tip-text",children:E("weekDaysShort")[6]})]}),w.jsxs("div",{className:"usage-heat-map",children:[C.slice(C.length-84+o.length,C.length).map((J,ee)=>{const Z=J.count,q=Z<=0?"":Z<=1?"stat-day-L1-bg":Z<=2?"stat-day-L2-bg":Z<=4?"stat-day-L3-bg":"stat-day-L4-bg";return w.jsx("span",{"data-timestamp":J.timestamp,"data-count":J.count,"data-list-count":J.list,"data-task-count":J.count-J.list,className:`stat-container ${q} ${M===J?"current":""} ${r===J.timestamp?"today":""}`,onMouseOver:$=>_($,J),onClick:$=>U($,J)},ee)}),o.map((J,ee)=>w.jsx("span",{className:"stat-container null"},ee))]})]}),!t&&w.jsx(qle,{allStat:C,todayTimeStamp:r,calendarType:m,handleCalendarTypeChange:H})]})};function ece(e,t){try{e?.saveLocalStorage("calendarType",t)}catch(n){console.error(n)}}function tce(e){try{return e?.loadLocalStorage("calendarType")||"heatmap"}catch(t){return console.error(t),"heatmap"}}const y7=({type:e,timestamp:t})=>{const{memoState:{memos:n}}=D.useContext(ct),[r,o]=D.useState([]),i=Y.useRef(null);return D.useEffect(()=>{if(e==="daily"){if(t){const s=n.filter(l=>N.moment(l.createdAt,"YYYY/MM/DD HH:mm:ss").isSame(N.moment(t,"YYYY/MM/DD HH:mm:ss"),"day"));o(s);return}const a=n.filter(s=>N.moment(s.createdAt,"YYYY/MM/DD HH:mm:ss").isSame(N.moment(),"day"));o(a)}else if(e==="latest"){const a=n.filter(u=>!u.deletedAt&&u.rowStatus!=="ARCHIVED"),s=a.filter(u=>u.pinned),l=a.filter(u=>!u.pinned).slice(0,5);o([...s,...l])}},[n]),D.useEffect(()=>{i.current&&(i.current.scrollTop=0)},[n]),r.length>0?w.jsx("div",{ref:i,className:"thino-list-container",children:r.map(a=>w.jsx(vo,{memo:a}))}):w.jsx("div",{className:"tip-text-container",children:w.jsx("span",{className:"tip-text",children:E("Here is No Memos.")})})},nce=(e,t)=>{Fi.createRoot(e).render(w.jsx(Y.StrictMode,{children:w.jsx(zi,{store:ke,context:ct,children:w.jsx(rce,{plugin:t})})}))},rce=({plugin:e})=>w.jsxs(w.Fragment,{children:[w.jsx("div",{className:"thino-error-code-block",children:E("Please open thino first")}),w.jsx("button",{className:"thino-open-view",onClick:()=>e.openMemos("center"),children:E("Open thino in center window")})]}),oce=(e,t)=>{Fi.createRoot(e).render(w.jsx(Y.StrictMode,{children:w.jsx(zi,{store:ke,context:ct,children:w.jsx(ice,{yaml:t})})}))},ice=({yaml:e})=>{const t=Object.keys(e).filter(o=>e[o]),n=e.daily?e.daily:"",r=o=>{switch(o){case"editor":return rj;case"heatmap":return sce;case"calendar":return lce;case"daily":return uce;case"list":return dce;case"status":return cce;default:return rj}};return w.jsx(w.Fragment,{children:t.map(o=>w.jsx("div",{"data-embed-type":o,className:tn("thino-embed-container",o==="editor"?"thino-editor-modal":""),children:o==="daily"?r(o)(n):r(o)()}))})};function rj(){return w.jsx(Du,{editorType:"inline",modal:!0})}function ace(e,t,n){try{const r=Fi.createRoot(e);return r.render(w.jsx(Y.StrictMode,{children:w.jsx(zi,{store:ke,context:ct,children:w.jsx(Du,{editorType:"inline",destroy:t,modal:n})})})),r}catch(r){console.error(r)}}function sce(){return w.jsx(_m,{basicType:"heatmap"})}function lce(){return w.jsx(_m,{basicType:"basic"})}function cce(){return w.jsx(sD,{statusType:"banner"})}function uce(e){return w.jsx(y7,{type:"daily",timestamp:e})}function dce(){return w.jsx(y7,{type:"latest"})}class lE extends N.Modal{root;constructor(t){super(t)}getViewType(){return"thino_view"}onOpen(){const{contentEl:t,modalEl:n}=this;try{this.root=ace(t,this.close.bind(this),this),n.toggleClass("thino-editor-modal",!0),setTimeout(()=>{t.querySelector("textarea")?.focus(),this.app.workspace.trigger("focus-on-textarea")},10)}catch(r){console.error(r)}}onClose(){this.root.unmount(),this.containerEl&&this.containerEl.empty()}}function fce(e,t){if(e==null)return{};var n=hce(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function hce(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function D0(){return D0=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},D0.apply(this,arguments)}function oj(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Pp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?oj(Object(n),!0).forEach(function(r){pce(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):oj(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function pce(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const mce={breakpointCols:void 0,className:void 0,columnClassName:void 0,children:void 0,columnAttrs:void 0,column:void 0},Wx=2;class A0 extends Y.Component{constructor(t){super(t),this.reCalculateColumnCount=this.reCalculateColumnCount.bind(this),this.reCalculateColumnCountDebounce=this.reCalculateColumnCountDebounce.bind(this);let n;this.props.breakpointCols&&this.props.breakpointCols.default?n=this.props.breakpointCols.default:n=parseInt(this.props.breakpointCols)||Wx,this.state={columnCount:n}}componentDidMount(){this.reCalculateColumnCount(),window&&window.addEventListener("resize",this.reCalculateColumnCountDebounce)}componentDidUpdate(){this.reCalculateColumnCount()}componentWillUnmount(){window&&window.removeEventListener("resize",this.reCalculateColumnCountDebounce)}reCalculateColumnCountDebounce(){if(!window||!window.requestAnimationFrame){this.reCalculateColumnCount();return}window.cancelAnimationFrame&&window.cancelAnimationFrame(this._lastRecalculateAnimationFrame),this._lastRecalculateAnimationFrame=window.requestAnimationFrame(()=>{this.reCalculateColumnCount()})}reCalculateColumnCount(){const t=window&&window.innerWidth||1/0;let n=this.props.breakpointCols;typeof n!="object"&&(n={default:parseInt(n)||Wx});let r=1/0,o=n.default||Wx;for(let i in n){const a=parseInt(i);a>0&&t<=a&&a<r&&(r=a,o=n[i])}o=Math.max(1,parseInt(o)||1),this.state.columnCount!==o&&this.setState({columnCount:o})}itemsInColumns(){const t=this.state.columnCount,n=new Array(t),r=Y.Children.toArray(this.props.children);for(let o=0;o<r.length;o++){const i=o%t;n[i]||(n[i]=[]),n[i].push(r[o])}return n}renderColumns(){const{column:t,columnAttrs:n={},columnClassName:r}=this.props,o=this.itemsInColumns(),i=`${100/o.length}%`;let a=r;a&&typeof a!="string"&&(this.logDeprecated('The property "columnClassName" requires a string'),typeof a>"u"&&(a="my-masonry-grid_column"));const s=Pp(Pp(Pp({},t),n),{},{style:Pp(Pp({},n.style),{},{width:i}),className:a});return o.map((l,u)=>Y.createElement("div",D0({},s,{key:u}),l))}logDeprecated(t){console.error("[Masonry]",t)}render(){const t=this.props,{children:n,breakpointCols:r,columnClassName:o,columnAttrs:i,column:a,className:s}=t,l=fce(t,["children","breakpointCols","columnClassName","columnAttrs","column","className"]);let u=s;return typeof s!="string"&&(this.logDeprecated('The property "className" requires a string'),typeof s>"u"&&(u="my-masonry-grid")),Y.createElement("div",D0({},l,{className:u}),this.renderColumns())}}A0.defaultProps=mce;const cE=e=>{D.useContext(ct);const t=ke.getState().dailyNotesState.settings,{thinos:n,dayMark:r,dayMarkRange:o="day",thinoWrapper:i}=e,[a,s]=Y.useState(!(t?.hidePinnedGroup&&r==="PINNED")),l=Y.useRef(null);D.useEffect(()=>{l&&N.setTooltip&&N.setTooltip(l.current,E("Click to expand or fold, Cmd+Click to show all thinos of the day"))},[l]);const u=d=>{if(N.Keymap.isModifier(d.nativeEvent,"Mod")){const h={day:"YYYY-MM-DD",week:"YYYY-[W]WW",month:"YYYY-MM",quarter:"YYYY-[Q]Q",year:"YYYY"},p=N.moment(r,h[o]);Ue.setFromAndToQuery(p.startOf(o).valueOf(),p.endOf(o).valueOf());return}s(!a)};return w.jsx(w.Fragment,{children:e.type==="list"?w.jsxs(w.Fragment,{children:[w.jsx("div",{ref:l,className:`day-mark ${a?"":"folded"} PINNED`,onClick:u,children:w.jsxs("span",{className:"day-mark-text",children:[a?"▼ ":"▶ ",r==="PINNED"?r+" 📌":r]})},r),a&&n.map((d,h)=>i?w.jsx("div",{children:i({thino:d})},`${d.id}-${N.moment(d.createdAt,"YYYY/MM/DD HH:mm:ss").format("x")}-${h}`):w.jsx(vo,{memo:d},`${d.id}-${N.moment(d.createdAt,"YYYY/MM/DD HH:mm:ss").format("x")}-${h}`))]}):w.jsxs(w.Fragment,{children:[w.jsx("div",{ref:l,className:`day-mark ${a?"":"folded"}`,onClick:u,children:w.jsxs("span",{className:"day-mark-text",children:[a?"▼ ":"▶ ",r==="PINNED"?r+" 📌":r]})},r),w.jsx(A0,{breakpointCols:e.type==="waterfall"?3:1,className:`${e.type}-view masonry-memolist`,columnClassName:"masonry-memolist-grid_column",children:a&&n.map((d,h)=>i?w.jsx("div",{children:i({thino:d})},`${d.id}-${N.moment(d.updatedAt,"YYYY/MM/DD HH:mm:ss").format("x")}-${h}`):w.jsx(vo,{memo:d},`${d.id}-${N.moment(d.updatedAt,"YYYY/MM/DD HH:mm:ss").format("x")}-${h}`))})]})})};function ml(e){"@babel/helpers - typeof";return ml=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ml(e)}function gce(e,t){if(ml(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(ml(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function b7(e){var t=gce(e,"string");return ml(t)=="symbol"?t:String(t)}function vu(e,t,n){return t=b7(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ij(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function pn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ij(Object(n),!0).forEach(function(r){vu(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ij(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function OS(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function Ss(e,t){if(e==null)return{};var n=OS(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Ir(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function aj(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,b7(r.key),r)}}function kr(e,t,n){return t&&aj(e.prototype,t),n&&aj(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function N0(e){return N0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},N0(e)}function w7(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(w7=function(){return!!e})()}function S7(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function vce(e,t){if(t&&(ml(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return S7(e)}function yo(e,t,n){return t=N0(t),vce(e,w7()?Reflect.construct(t,n||[],N0(e).constructor):t.apply(e,n))}function O0(e,t){return O0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},O0(e,t)}function bo(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&O0(e,t)}function T7(e){if(Array.isArray(e))return e}function yce(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(d){u=!0,o=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}function uE(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function kD(e,t){if(e){if(typeof e=="string")return uE(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return uE(e,t)}}function x7(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Xs(e,t){return T7(e)||yce(e,t)||kD(e,t)||x7()}function Vn(){return Vn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Vn.apply(this,arguments)}var bce=function(e,t,n,r,o,i,a,s){if(!e){var l;if(t===void 0)l=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var u=[n,r,o,i,a,s],d=0;l=new Error(t.replace(/%s/g,function(){return u[d++]})),l.name="Invariant Violation"}throw l.framesToPop=1,l}},wce=bce;const Bm=tt(wce);var Sce=function(){};function Tce(e,t){var n={};return Object.keys(e).forEach(function(r){n[Gb(r)]=Sce}),n}function sj(e,t){return e[t]!==void 0}function Gb(e){return"default"+e.charAt(0).toUpperCase()+e.substr(1)}function xce(e){return!!e&&(typeof e!="function"||e.prototype&&e.prototype.isReactComponent)}function Ice(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,O0(e,t)}function I7(){var e=this.constructor.getDerivedStateFromProps(this.props,this.state);e!=null&&this.setState(e)}function k7(e){function t(n){var r=this.constructor.getDerivedStateFromProps(e,n);return r??null}this.setState(t.bind(this))}function E7(e,t){try{var n=this.props,r=this.state;this.props=e,this.state=t,this.__reactInternalSnapshotFlag=!0,this.__reactInternalSnapshot=this.getSnapshotBeforeUpdate(n,r)}finally{this.props=n,this.state=r}}I7.__suppressDeprecationWarning=!0;k7.__suppressDeprecationWarning=!0;E7.__suppressDeprecationWarning=!0;function kce(e){var t=e.prototype;if(!t||!t.isReactComponent)throw new Error("Can only polyfill class components");if(typeof e.getDerivedStateFromProps!="function"&&typeof t.getSnapshotBeforeUpdate!="function")return e;var n=null,r=null,o=null;if(typeof t.componentWillMount=="function"?n="componentWillMount":typeof t.UNSAFE_componentWillMount=="function"&&(n="UNSAFE_componentWillMount"),typeof t.componentWillReceiveProps=="function"?r="componentWillReceiveProps":typeof t.UNSAFE_componentWillReceiveProps=="function"&&(r="UNSAFE_componentWillReceiveProps"),typeof t.componentWillUpdate=="function"?o="componentWillUpdate":typeof t.UNSAFE_componentWillUpdate=="function"&&(o="UNSAFE_componentWillUpdate"),n!==null||r!==null||o!==null){var i=e.displayName||e.name,a=typeof e.getDerivedStateFromProps=="function"?"getDerivedStateFromProps()":"getSnapshotBeforeUpdate()";throw Error(`Unsafe legacy lifecycles will not be called for components using new component APIs.
|
|
|
|
|
|
`+i+" uses "+a+" but also contains the following legacy lifecycles:"+(n!==null?`
|
|
|
`+n:"")+(r!==null?`
|
|
|
`+r:"")+(o!==null?`
|
|
|
`+o:"")+`
|
|
|
|
|
|
The above lifecycles should be removed. Learn more about this warning here:
|
|
|
https://fb.me/react-async-component-lifecycle-hooks`)}if(typeof e.getDerivedStateFromProps=="function"&&(t.componentWillMount=I7,t.componentWillReceiveProps=k7),typeof t.getSnapshotBeforeUpdate=="function"){if(typeof t.componentDidUpdate!="function")throw new Error("Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype");t.componentWillUpdate=E7;var s=t.componentDidUpdate;t.componentDidUpdate=function(u,d,h){var p=this.__reactInternalSnapshotFlag?this.__reactInternalSnapshot:h;s.call(this,u,d,p)}}return e}var Ece="/Users/jquense/src/uncontrollable/src/uncontrollable.js";function C7(e,t,n){n===void 0&&(n=[]);var r=e.displayName||e.name||"Component",o=xce(e),i=Object.keys(t),a=i.map(Gb);o||!n.length||Bm(!1);var s=function(u){Ice(d,u);function d(){for(var p,m=arguments.length,b=new Array(m),v=0;v<m;v++)b[v]=arguments[v];p=u.call.apply(u,[this].concat(b))||this,p.handlers=Object.create(null),i.forEach(function(S){var x=t[S],C=function(M){if(p.props[x]){var I;p._notifying=!0;for(var O=arguments.length,R=new Array(O>1?O-1:0),L=1;L<O;L++)R[L-1]=arguments[L];(I=p.props)[x].apply(I,[M].concat(R)),p._notifying=!1}p.unmounted||p.setState(function(B){var _,H=B.values;return{values:Vn(Object.create(null),H,(_={},_[S]=M,_))}})};p.handlers[x]=C}),n.length&&(p.attachRef=function(S){p.inner=S});var y=Object.create(null);return i.forEach(function(S){y[S]=p.props[Gb(S)]}),p.state={values:y,prevProps:{}},p}var h=d.prototype;return h.shouldComponentUpdate=function(){return!this._notifying},d.getDerivedStateFromProps=function(m,b){var v=b.values,y=b.prevProps,S={values:Vn(Object.create(null),v),prevProps:{}};return i.forEach(function(x){S.prevProps[x]=m[x],!sj(m,x)&&sj(y,x)&&(S.values[x]=m[Gb(x)])}),S},h.componentWillUnmount=function(){this.unmounted=!0},h.render=function(){var m=this,b=this.props,v=b.innerRef,y=OS(b,["innerRef"]);a.forEach(function(x){delete y[x]});var S={};return i.forEach(function(x){var C=m.props[x];S[x]=C!==void 0?C:m.state.values[x]}),Y.createElement(e,Vn({},y,S,this.handlers,{ref:v||this.attachRef}))},d}(Y.Component);kce(s),s.displayName="Uncontrolled("+r+")",s.propTypes=Vn({innerRef:function(){}},Tce(t)),n.forEach(function(u){s.prototype[u]=function(){var h;return(h=this.inner)[u].apply(h,arguments)}});var l=s;return Y.forwardRef&&(l=Y.forwardRef(function(u,d){return Y.createElement(s,Vn({},u,{innerRef:d,__source:{fileName:Ece,lineNumber:128},__self:this}))}),l.propTypes=s.propTypes),l.ControlledComponent=e,l.deferControlTo=function(u,d,h){return d===void 0&&(d={}),C7(u,Vn({},t,d),h)},l}function M7(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=M7(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function fr(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=M7(e))&&(r&&(r+=" "),r+=t);return r}var D7={exports:{}},Gx,lj;function Cce(){if(lj)return Gx;lj=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return Gx=e,Gx}var Zx,cj;function Mce(){if(cj)return Zx;cj=1;var e=Cce();function t(){}function n(){}return n.resetWarningCache=t,Zx=function(){function r(a,s,l,u,d,h){if(h!==e){var p=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw p.name="Invariant Violation",p}}r.isRequired=r;function o(){return r}var i={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return i.PropTypes=i,i},Zx}D7.exports=Mce()();var Dce=D7.exports;const pe=tt(Dce);var P0="milliseconds",Ym="seconds",Um="minutes",zm="hours",Hu="day",Df="week",Vm="month",_u="year",Bu="decade",Yu="century",A7={milliseconds:1,seconds:1e3,minutes:60*1e3,hours:60*60*1e3,day:24*60*60*1e3,week:7*24*60*60*1e3},Ace={month:1,year:12,decade:10*12,century:100*12};function Nce(e){return[31,Oce(e),31,30,31,30,31,31,30,31,30,31]}function Oce(e){return e%4===0&&e%100!==0||e%400===0?29:28}function ba(e,t,n){switch(e=new Date(e),n){case P0:case Ym:case Um:case zm:case Hu:case Df:return Pce(e,t*A7[n]);case Vm:case _u:case Bu:case Yu:return jce(e,t*Ace[n])}throw new TypeError('Invalid units: "'+n+'"')}function Pce(e,t){var n=new Date(+e+t);return Lce(e,n)}function jce(e,t){var n=e.getFullYear(),r=e.getMonth(),o=e.getDate(),i=n*12+r+t,a=Math.trunc(i/12),s=i%12,l=Math.min(o,Nce(a)[s]),u=new Date(e);return u.setFullYear(a),u.setDate(1),u.setMonth(s),u.setDate(l),u}function Lce(e,t){var n=e.getTimezoneOffset(),r=t.getTimezoneOffset(),o=r-n;return new Date(+t+o*A7.minutes)}function Wm(e,t,n){return ba(e,-t,n)}function Fr(e,t,n){switch(e=new Date(e),t){case Yu:case Bu:case _u:e=L0(e,0);case Vm:e=L7(e,1);case Df:case Hu:e=$m(e,0);case zm:e=Af(e,0);case Um:e=Zm(e,0);case Ym:e=Gm(e,0)}return t===Bu&&(e=Wm(e,Uu(e)%10,"year")),t===Yu&&(e=Wm(e,Uu(e)%100,"year")),t===Df&&(e=R7(e,0,n)),e}function j0(e,t,n){switch(e=new Date(e),e=Fr(e,t,n),t){case Yu:case Bu:case _u:case Vm:case Df:e=ba(e,1,t),e=Wm(e,1,Hu),e.setHours(23,59,59,999);break;case Hu:e.setHours(23,59,59,999);break;case zm:case Um:case Ym:e=ba(e,1,t),e=Wm(e,1,P0)}return e}var uv=Ch(function(e,t){return e===t}),ED=Ch(function(e,t){return e!==t}),PS=Ch(function(e,t){return e>t}),dv=Ch(function(e,t){return e>=t}),CD=Ch(function(e,t){return e<t}),Eh=Ch(function(e,t){return e<=t});function N7(){return new Date(Math.min.apply(Math,arguments))}function O7(){return new Date(Math.max.apply(Math,arguments))}function P7(e,t,n,r){return r=r||"day",(!t||dv(e,t,r))&&(!n||Eh(e,n,r))}var Gm=kc("Milliseconds"),Zm=kc("Seconds"),Af=kc("Minutes"),$m=kc("Hours"),j7=kc("Day"),L7=kc("Date"),L0=kc("Month"),Uu=kc("FullYear");function Rce(e,t){return t===void 0?Uu(Fr(e,Bu)):ba(e,t+10,_u)}function Fce(e,t){return t===void 0?Uu(Fr(e,Yu)):ba(e,t+100,_u)}function R7(e,t,n){var r=(j7(e)+7-(n||0))%7;return t===void 0?r:ba(e,t-r,Hu)}function Hce(e,t,n,r){var o,i,a;switch(n){case P0:case Ym:case Um:case zm:case Hu:case Df:o=t.getTime()-e.getTime();break;case Vm:case _u:case Bu:case Yu:o=(Uu(t)-Uu(e))*12+L0(t)-L0(e);break;default:throw new TypeError('Invalid units: "'+n+'"')}switch(n){case P0:i=1;break;case Ym:i=1e3;break;case Um:i=1e3*60;break;case zm:i=1e3*60*60;break;case Hu:i=1e3*60*60*24;break;case Df:i=1e3*60*60*24*7;break;case Vm:i=1;break;case _u:i=12;break;case Bu:i=120;break;case Yu:i=1200;break;default:throw new TypeError('Invalid units: "'+n+'"')}return a=o/i,r?a:Math.round(a)}function kc(e){var t=function(n){switch(n){case"Milliseconds":return 36e5;case"Seconds":return 3600;case"Minutes":return 60;case"Hours":return 1;default:return null}}(e);return function(n,r){if(r===void 0)return n["get"+e]();var o=new Date(n);return o["set"+e](r),t&&o["get"+e]()!=r&&(e==="Hours"||r>=t&&o.getHours()-n.getHours()<Math.floor(r/t))&&o["set"+e](r+t),o}}function Ch(e){return function(t,n,r){return e(+Fr(t,r),+Fr(n,r))}}const uj=Object.freeze(Object.defineProperty({__proto__:null,add:ba,century:Fce,date:L7,day:j7,decade:Rce,diff:Hce,endOf:j0,eq:uv,gt:PS,gte:dv,hours:$m,inRange:P7,lt:CD,lte:Eh,max:O7,milliseconds:Gm,min:N7,minutes:Af,month:L0,neq:ED,seconds:Zm,startOf:Fr,subtract:Wm,weekday:R7,year:Uu},Symbol.toStringTag,{value:"Module"}));function _ce(e){if(Array.isArray(e))return uE(e)}function F7(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Bce(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Zb(e){return _ce(e)||F7(e)||kD(e)||Bce()}function Yce(e,t,n){var r=-1,o=e.length;t<0&&(t=-t>o?0:o+t),n=n>o?o:n,n<0&&(n+=o),o=t>n?0:n-t>>>0,t>>>=0;for(var i=Array(o);++r<o;)i[r]=e[r+t];return i}var MD=Yce,Uce=cv,zce=Qu,Vce=xD,Wce=Vi;function Gce(e,t,n){if(!Wce(n))return!1;var r=typeof t;return(r=="number"?zce(n)&&Vce(t,n.length):r=="string"&&t in n)?Uce(n[t],e):!1}var Mh=Gce,Zce=/\s/;function $ce(e){for(var t=e.length;t--&&Zce.test(e.charAt(t)););return t}var qce=$ce,Kce=qce,Xce=/^\s+/;function Jce(e){return e&&e.slice(0,Kce(e)+1).replace(Xce,"")}var Qce=Jce,eue=kl,tue=xa,nue="[object Symbol]";function rue(e){return typeof e=="symbol"||tue(e)&&eue(e)==nue}var Dh=rue,oue=Qce,dj=Vi,iue=Dh,fj=NaN,aue=/^[-+]0x[0-9a-f]+$/i,sue=/^0b[01]+$/i,lue=/^0o[0-7]+$/i,cue=parseInt;function uue(e){if(typeof e=="number")return e;if(iue(e))return fj;if(dj(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=dj(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=oue(e);var n=sue.test(e);return n||lue.test(e)?cue(e.slice(2),n?2:8):aue.test(e)?fj:+e}var H7=uue,due=H7,hj=1/0,fue=17976931348623157e292;function hue(e){if(!e)return e===0?e:0;if(e=due(e),e===hj||e===-hj){var t=e<0?-1:1;return t*fue}return e===e?e:0}var _7=hue,pue=_7;function mue(e){var t=pue(e),n=t%1;return t===t?n?t-n:t:0}var B7=mue,gue=MD,vue=Mh,yue=B7,bue=Math.ceil,wue=Math.max;function Sue(e,t,n){(n?vue(e,t,n):t===void 0)?t=1:t=wue(yue(t),0);var r=e==null?0:e.length;if(!r||t<1)return[];for(var o=0,i=0,a=Array(bue(r/t));o<r;)a[i++]=gue(e,o,o+=t);return a}var Tue=Sue;const xue=tt(Tue);function fv(e){return e&&e.ownerDocument||document}function Iue(e){var t=fv(e);return t&&t.defaultView||window}function kue(e,t){return Iue(e).getComputedStyle(e,t)}var Eue=/([A-Z])/g;function Cue(e){return e.replace(Eue,"-$1").toLowerCase()}var Mue=/^ms-/;function eb(e){return Cue(e).replace(Mue,"-ms-")}var Due=/^((translate|rotate|scale)(X|Y|Z|3d)?|matrix(3d)?|perspective|skew(X|Y)?)$/i;function Aue(e){return!!(e&&Due.test(e))}function ef(e,t){var n="",r="";if(typeof t=="string")return e.style.getPropertyValue(eb(t))||kue(e).getPropertyValue(eb(t));Object.keys(t).forEach(function(o){var i=t[o];!i&&i!==0?e.style.removeProperty(eb(o)):Aue(o)?r+=o+"("+i+") ":n+=eb(o)+": "+i+";"}),r&&(n+="transform: "+r+";"),e.style.cssText+=";"+n}function qm(e,t){if(e.contains)return e.contains(t);if(e.compareDocumentPosition)return e===t||!!(e.compareDocumentPosition(t)&16)}function Nue(e){return"nodeType"in e&&e.nodeType===document.DOCUMENT_NODE}function DD(e){return"window"in e&&e.window===e?e:Nue(e)&&e.defaultView||!1}function Y7(e){var t=e==="pageXOffset"?"scrollLeft":"scrollTop";function n(r,o){var i=DD(r);if(o===void 0)return i?i[e]:r[t];i?i.scrollTo(i[e],o):r[t]=o}return n}const U7=Y7("pageXOffset"),z7=Y7("pageYOffset");function Au(e){var t=fv(e),n={top:0,left:0,height:0,width:0},r=t&&t.documentElement;return!r||!qm(r,e)||(e.getBoundingClientRect!==void 0&&(n=e.getBoundingClientRect()),n={top:n.top+z7(r)-(r.clientTop||0),left:n.left+U7(r)-(r.clientLeft||0),width:n.width,height:n.height}),n}var Oue=function(t){return!!t&&"offsetParent"in t};function Pue(e){for(var t=fv(e),n=e&&e.offsetParent;Oue(n)&&n.nodeName!=="HTML"&&ef(n,"position")==="static";)n=n.offsetParent;return n||t.documentElement}var jue=function(t){return t.nodeName&&t.nodeName.toLowerCase()};function V7(e,t){var n={top:0,left:0},r;if(ef(e,"position")==="fixed")r=e.getBoundingClientRect();else{var o=t||Pue(e);r=Au(e),jue(o)!=="html"&&(n=Au(o));var i=String(ef(o,"borderTopWidth")||0);n.top+=parseInt(i,10)-z7(o)||0;var a=String(ef(o,"borderLeftWidth")||0);n.left+=parseInt(a,10)-U7(o)||0}var s=String(ef(e,"marginTop")||0),l=String(ef(e,"marginLeft")||0);return Vn({},r,{top:r.top-n.top-(parseInt(s,10)||0),left:r.left-n.left-(parseInt(l,10)||0)})}const AD=!!(typeof window<"u"&&window.document&&window.document.createElement);var pj=new Date().getTime();function Lue(e){var t=new Date().getTime(),n=Math.max(0,16-(t-pj)),r=setTimeout(e,n);return pj=t,r}var Rue=["","webkit","moz","o","ms"],dE="clearTimeout",fE=Lue,mj=function(t,n){return t+(t?n[0].toUpperCase()+n.substr(1):n)+"AnimationFrame"};AD&&Rue.some(function(e){var t=mj(e,"request");return t in window&&(dE=mj(e,"cancel"),fE=function(r){return window[t](r)}),!!fE});var gj=function(t){typeof window[dE]=="function"&&window[dE](t)},W7=fE,$x;function Fue(e,t){if(!$x){var n=document.body,r=n.matches||n.matchesSelector||n.webkitMatchesSelector||n.mozMatchesSelector||n.msMatchesSelector;$x=function(i,a){return r.call(i,a)}}return $x(e,t)}var Hue=Function.prototype.bind.call(Function.prototype.call,[].slice);function _ue(e,t){return Hue(e.querySelectorAll(t))}var hE=!1,pE=!1;try{var qx={get passive(){return hE=!0},get once(){return pE=hE=!0}};AD&&(window.addEventListener("test",qx,qx),window.removeEventListener("test",qx,!0))}catch{}function Bue(e,t,n,r){if(r&&typeof r!="boolean"&&!pE){var o=r.once,i=r.capture,a=n;!pE&&o&&(a=n.__once||function s(l){this.removeEventListener(t,s,i),n.call(this,l)},n.__once=a),e.addEventListener(t,a,hE?r:i)}e.addEventListener(t,n,r)}function Yue(e){const t=D.useRef(e);return D.useEffect(()=>{t.current=e},[e]),t}function vj(e){const t=Yue(e);return D.useCallback(function(...n){return t.current&&t.current(...n)},[t])}function yj(){return D.useState(null)}function Uue(){const e=D.useRef(!0),t=D.useRef(()=>e.current);return D.useEffect(()=>(e.current=!0,()=>{e.current=!1}),[]),t.current}function zue(e){const t=Uue();return[e[0],D.useCallback(n=>{if(t())return e[1](n)},[t,e[1]])]}var Vue=$H({defaultModifiers:[VH,GH,_H,BH,WH,zH,ZH,HH]}),bj=function(t){return{position:t,top:"0",left:"0",opacity:"0",pointerEvents:"none"}},Wue={name:"applyStyles",enabled:!1},Gue={name:"ariaDescribedBy",enabled:!0,phase:"afterWrite",effect:function(t){var n=t.state;return function(){var r=n.elements,o=r.reference,i=r.popper;if("removeAttribute"in o){var a=(o.getAttribute("aria-describedby")||"").split(",").filter(function(s){return s.trim()!==i.id});a.length?o.setAttribute("aria-describedby",a.join(",")):o.removeAttribute("aria-describedby")}}},fn:function(t){var n,r=t.state,o=r.elements,i=o.popper,a=o.reference,s=(n=i.getAttribute("role"))==null?void 0:n.toLowerCase();if(i.id&&s==="tooltip"&&"setAttribute"in a){var l=a.getAttribute("aria-describedby");if(l&&l.split(",").indexOf(i.id)!==-1)return;a.setAttribute("aria-describedby",l?l+","+i.id:i.id)}}},Zue=[];function $ue(e,t,n){var r=n===void 0?{}:n,o=r.enabled,i=o===void 0?!0:o,a=r.placement,s=a===void 0?"bottom":a,l=r.strategy,u=l===void 0?"absolute":l,d=r.modifiers,h=d===void 0?Zue:d,p=OS(r,["enabled","placement","strategy","modifiers"]),m=D.useRef(),b=D.useCallback(function(){var k;(k=m.current)==null||k.update()},[]),v=D.useCallback(function(){var k;(k=m.current)==null||k.forceUpdate()},[]),y=zue(D.useState({placement:s,update:b,forceUpdate:v,attributes:{},styles:{popper:bj(u),arrow:{}}})),S=y[0],x=y[1],C=D.useMemo(function(){return{name:"updateStateModifier",enabled:!0,phase:"write",requires:["computeStyles"],fn:function(M){var I=M.state,O={},R={};Object.keys(I.elements).forEach(function(L){O[L]=I.styles[L],R[L]=I.attributes[L]}),x({state:I,styles:O,attributes:R,update:b,forceUpdate:v,placement:I.placement})}}},[b,v,x]);return D.useEffect(function(){!m.current||!i||m.current.setOptions({placement:s,strategy:u,modifiers:[].concat(h,[C,Wue])})},[u,s,C,i]),D.useEffect(function(){if(!(!i||e==null||t==null))return m.current=Vue(e,t,Vn({},p,{placement:s,strategy:u,modifiers:[].concat(h,[Gue,C])})),function(){m.current!=null&&(m.current.destroy(),m.current=void 0,x(function(k){return Vn({},k,{attributes:{},styles:{popper:bj(u)}})}))}},[i,e,t]),S}function que(e,t,n,r){var o=r&&typeof r!="boolean"?r.capture:r;e.removeEventListener(t,n,o),n.__once&&e.removeEventListener(t,n.__once,o)}function nm(e,t,n,r){return Bue(e,t,n,r),function(){que(e,t,n,r)}}function Kue(e){return e&&"setState"in e?rD.findDOMNode(e):e??null}const Xue=function(e){return fv(Kue(e))};var Jue=27,wj=function(){};function Que(e){return e.button===0}function ede(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}var Sj=function(t){return t&&("current"in t?t.current:t)};function tde(e,t,n){var r=n===void 0?{}:n,o=r.disabled,i=r.clickTrigger,a=i===void 0?"click":i,s=D.useRef(!1),l=t||wj,u=D.useCallback(function(p){var m,b=Sj(e);soe(!!b,"RootClose captured a close event but does not have a ref to compare it to. useRootClose(), should be passed a ref that resolves to a DOM node"),s.current=!b||ede(p)||!Que(p)||!!qm(b,(m=p.composedPath==null?void 0:p.composedPath()[0])!=null?m:p.target)},[e]),d=vj(function(p){s.current||l(p)}),h=vj(function(p){p.keyCode===Jue&&l(p)});D.useEffect(function(){if(!(o||e==null)){var p=window.event,m=Xue(Sj(e)),b=nm(m,a,u,!0),v=nm(m,a,function(x){if(x===p){p=void 0;return}d(x)}),y=nm(m,"keyup",function(x){if(x===p){p=void 0;return}h(x)}),S=[];return"ontouchstart"in m.documentElement&&(S=[].slice.call(m.body.children).map(function(x){return nm(x,"mousemove",wj)})),function(){b(),v(),y(),S.forEach(function(x){return x()})}}},[e,o,a,u,d,h])}function nde(e){var t={};return Array.isArray(e)?(e?.forEach(function(n){t[n.name]=n}),t):e||t}function rde(e){return e===void 0&&(e={}),Array.isArray(e)?e:Object.keys(e).map(function(t){return e[t].name=t,e[t]})}function ode(e){var t,n,r,o,i=e.enabled,a=e.enableEvents,s=e.placement,l=e.flip,u=e.offset,d=e.fixed,h=e.containerPadding,p=e.arrowElement,m=e.popperConfig,b=m===void 0?{}:m,v=nde(b.modifiers);return Vn({},b,{placement:s,enabled:i,strategy:d?"fixed":b.strategy,modifiers:rde(Vn({},v,{eventListeners:{enabled:a},preventOverflow:Vn({},v.preventOverflow,{options:h?Vn({padding:h},(t=v.preventOverflow)==null?void 0:t.options):(n=v.preventOverflow)==null?void 0:n.options}),offset:{options:Vn({offset:u},(r=v.offset)==null?void 0:r.options)},arrow:Vn({},v.arrow,{enabled:!!p,options:Vn({},(o=v.arrow)==null?void 0:o.options,{element:p})}),flip:Vn({enabled:!!l},v.flip)}))})}function ide(e,t){return e.classList?!!t&&e.classList.contains(t):(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" ")!==-1}function ade(e,t){e.classList?e.classList.add(t):ide(e,t)||(typeof e.className=="string"?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))}function Tj(e,t){return e.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function sde(e,t){e.classList?e.classList.remove(t):typeof e.className=="string"?e.className=Tj(e.className,t):e.setAttribute("class",Tj(e.className&&e.className.baseVal||"",t))}var tb;function G7(e){if((!tb&&tb!==0||e)&&AD){var t=document.createElement("div");t.style.position="absolute",t.style.top="-9999px",t.style.width="50px",t.style.height="50px",t.style.overflow="scroll",document.body.appendChild(t),tb=t.offsetWidth-t.clientWidth,document.body.removeChild(t)}return tb}var Kx=function(t){var n;return typeof document>"u"?null:t==null?fv().body:(typeof t=="function"&&(t=t()),t&&"current"in t&&(t=t.current),(n=t)!=null&&n.nodeType&&t||null)};function xj(e,t){var n=D.useState(function(){return Kx(e)}),r=n[0],o=n[1];if(!r){var i=Kx(e);i&&o(i)}return D.useEffect(function(){t&&r&&t(r)},[t,r]),D.useEffect(function(){var a=Kx(e);a!==r&&o(a)},[e,r]),r}const Ij=e=>!e||typeof e=="function"?e:t=>{e.current=t};function lde(e,t){const n=Ij(e),r=Ij(t);return o=>{n&&n(o),r&&r(o)}}function cde(e,t){return D.useMemo(()=>lde(e,t),[e,t])}var ND=Y.forwardRef(function(e,t){var n=e.flip,r=e.offset,o=e.placement,i=e.containerPadding,a=i===void 0?5:i,s=e.popperConfig,l=s===void 0?{}:s,u=e.transition,d=yj(),h=d[0],p=d[1],m=yj(),b=m[0],v=m[1],y=cde(p,t),S=xj(e.container),x=xj(e.target),C=D.useState(!e.show),k=C[0],M=C[1],I=$ue(x,h,ode({placement:o,enableEvents:!!e.show,containerPadding:a||5,flip:n,offset:r,arrowElement:b,popperConfig:l})),O=I.styles,R=I.attributes,L=OS(I,["styles","attributes"]);e.show?k&&M(!1):!e.transition&&!k&&M(!0);var B=function(){M(!0),e.onExited&&e.onExited.apply(e,arguments)},_=e.show||u&&!k;if(tde(h,e.onHide,{disabled:!e.rootClose||e.rootCloseDisabled,clickTrigger:e.rootCloseEvent}),!_)return null;var H=e.children(Vn({},L,{show:!!e.show,props:Vn({},R.popper,{style:O.popper,ref:y}),arrowProps:Vn({},R.arrow,{style:O.arrow,ref:v})}));if(u){var U=e.onExit,G=e.onExiting,K=e.onEnter,z=e.onEntering,ne=e.onEntered;H=Y.createElement(u,{in:e.show,appear:!0,onExit:U,onExiting:G,onExited:B,onEnter:K,onEntering:z,onEntered:ne},H)}return S?rD.createPortal(H,S):null});ND.displayName="Overlay";ND.propTypes={show:pe.bool,placement:pe.oneOf(uD),target:pe.any,container:pe.any,flip:pe.bool,children:pe.func.isRequired,containerPadding:pe.number,popperConfig:pe.object,rootClose:pe.bool,rootCloseEvent:pe.oneOf(["click","mousedown"]),rootCloseDisabled:pe.bool,onHide:function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];if(t.rootClose){var i;return(i=pe.func).isRequired.apply(i,[t].concat(r))}return pe.func.apply(pe,[t].concat(r))},transition:pe.elementType,onEnter:pe.func,onEntering:pe.func,onEntered:pe.func,onExit:pe.func,onExiting:pe.func,onExited:pe.func};const ude=ND;function Xx(e,t){var n=DD(e);return n?n.innerHeight:t?e.clientHeight:Au(e).height}function Z7(e,t,n){e.closest&&!n&&e.closest(t);var r=e;do{if(Fue(r,t))return r;r=r.parentElement}while(r&&r!==n&&r.nodeType===document.ELEMENT_NODE);return null}function dde(e,t,n,r){for(var o=e.length,i=n+(r?1:-1);r?i--:++i<o;)if(t(e[i],i,e))return i;return-1}var $7=dde,fde=bD,hde=ID,pde=1,mde=2;function gde(e,t,n,r){var o=n.length,i=o,a=!r;if(e==null)return!i;for(e=Object(e);o--;){var s=n[o];if(a&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++o<i;){s=n[o];var l=s[0],u=e[l],d=s[1];if(a&&s[2]){if(u===void 0&&!(l in e))return!1}else{var h=new fde;if(r)var p=r(u,d,l,e,t,h);if(!(p===void 0?hde(d,u,pde|mde,r,h):p))return!1}}return!0}var vde=gde,yde=Vi;function bde(e){return e===e&&!yde(e)}var q7=bde,wde=q7,Sde=kh;function Tde(e){for(var t=Sde(e),n=t.length;n--;){var r=t[n],o=e[r];t[n]=[r,o,wde(o)]}return t}var xde=Tde;function Ide(e,t){return function(n){return n==null?!1:n[e]===t&&(t!==void 0||e in Object(n))}}var K7=Ide,kde=vde,Ede=xde,Cde=K7;function Mde(e){var t=Ede(e);return t.length==1&&t[0][2]?Cde(t[0][0],t[0][1]):function(n){return n===e||kde(n,e,t)}}var Dde=Mde,Ade=Hr,Nde=Dh,Ode=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Pde=/^\w*$/;function jde(e,t){if(Ade(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||Nde(e)?!0:Pde.test(e)||!Ode.test(e)||t!=null&&e in Object(t)}var OD=jde,X7=yD,Lde="Expected a function";function PD(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(Lde);var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=e.apply(this,r);return n.cache=i.set(o,a)||i,a};return n.cache=new(PD.Cache||X7),n}PD.Cache=X7;var J7=PD;const Rde=tt(J7);var Fde=J7,Hde=500;function _de(e){var t=Fde(e,function(r){return n.size===Hde&&n.clear(),r}),n=t.cache;return t}var Bde=_de,Yde=Bde,Ude=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,zde=/\\(\\)?/g,Vde=Yde(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(Ude,function(n,r,o,i){t.push(o?i.replace(zde,"$1"):r||n)}),t}),Wde=Vde;function Gde(e,t){for(var n=-1,r=e==null?0:e.length,o=Array(r);++n<r;)o[n]=t(e[n],n,e);return o}var jS=Gde,kj=ph,Zde=jS,$de=Hr,qde=Dh,Kde=1/0,Ej=kj?kj.prototype:void 0,Cj=Ej?Ej.toString:void 0;function Q7(e){if(typeof e=="string")return e;if($de(e))return Zde(e,Q7)+"";if(qde(e))return Cj?Cj.call(e):"";var t=e+"";return t=="0"&&1/e==-Kde?"-0":t}var Xde=Q7,Jde=Xde;function Qde(e){return e==null?"":Jde(e)}var e_=Qde,efe=Hr,tfe=OD,nfe=Wde,rfe=e_;function ofe(e,t){return efe(e)?e:tfe(e,t)?[e]:nfe(rfe(e))}var LS=ofe,ife=Dh,afe=1/0;function sfe(e){if(typeof e=="string"||ife(e))return e;var t=e+"";return t=="0"&&1/e==-afe?"-0":t}var hv=sfe,lfe=LS,cfe=hv;function ufe(e,t){t=lfe(t,e);for(var n=0,r=t.length;e!=null&&n<r;)e=e[cfe(t[n++])];return n&&n==r?e:void 0}var RS=ufe,dfe=RS;function ffe(e,t,n){var r=e==null?void 0:dfe(e,t);return r===void 0?n:r}var t_=ffe;const Li=tt(t_);function hfe(e,t){return e!=null&&t in Object(e)}var pfe=hfe,mfe=LS,gfe=pS,vfe=Hr,yfe=xD,bfe=GM,wfe=hv;function Sfe(e,t,n){t=mfe(t,e);for(var r=-1,o=t.length,i=!1;++r<o;){var a=wfe(t[r]);if(!(i=e!=null&&n(e,a)))break;e=e[a]}return i||++r!=o?i:(o=e==null?0:e.length,!!o&&bfe(o)&&yfe(a,o)&&(vfe(e)||gfe(e)))}var Tfe=Sfe,xfe=pfe,Ife=Tfe;function kfe(e,t){return e!=null&&Ife(e,t,xfe)}var Efe=kfe,Cfe=ID,Mfe=t_,Dfe=Efe,Afe=OD,Nfe=q7,Ofe=K7,Pfe=hv,jfe=1,Lfe=2;function Rfe(e,t){return Afe(e)&&Nfe(t)?Ofe(Pfe(e),t):function(n){var r=Mfe(n,e);return r===void 0&&r===t?Dfe(n,e):Cfe(t,r,jfe|Lfe)}}var Ffe=Rfe;function Hfe(e){return e}var Ah=Hfe;function _fe(e){return function(t){return t?.[e]}}var Bfe=_fe,Yfe=RS;function Ufe(e){return function(t){return Yfe(t,e)}}var zfe=Ufe,Vfe=Bfe,Wfe=zfe,Gfe=OD,Zfe=hv;function $fe(e){return Gfe(e)?Vfe(Zfe(e)):Wfe(e)}var qfe=$fe,Kfe=Dde,Xfe=Ffe,Jfe=Ah,Qfe=Hr,ehe=qfe;function the(e){return typeof e=="function"?e:e==null?Jfe:typeof e=="object"?Qfe(e)?Xfe(e[0],e[1]):Kfe(e):ehe(e)}var El=the,nhe=$7,rhe=El,ohe=B7,ihe=Math.max;function ahe(e,t,n){var r=e==null?0:e.length;if(!r)return-1;var o=n==null?0:ohe(n);return o<0&&(o=ihe(r+o,0)),nhe(e,rhe(t),o)}var n_=ahe;const she=tt(n_);var lhe=Math.ceil,che=Math.max;function uhe(e,t,n,r){for(var o=-1,i=che(lhe((t-e)/(n||1)),0),a=Array(i);i--;)a[r?i:++o]=e,e+=n;return a}var dhe=uhe,fhe=dhe,hhe=Mh,Jx=_7;function phe(e){return function(t,n,r){return r&&typeof r!="number"&&hhe(t,n,r)&&(n=r=void 0),t=Jx(t),n===void 0?(n=t,t=0):n=Jx(n),r=r===void 0?t<n?1:-1:Jx(r),fhe(t,n,r,e)}}var mhe=phe,ghe=mhe,vhe=ghe(),yhe=vhe;const Km=tt(yhe);var Mj=Number.isNaN||function(t){return typeof t=="number"&&t!==t};function bhe(e,t){return!!(e===t||Mj(e)&&Mj(t))}function whe(e,t){if(e.length!==t.length)return!1;for(var n=0;n<e.length;n++)if(!bhe(e[n],t[n]))return!1;return!0}function r_(e,t){t===void 0&&(t=whe);var n=null;function r(){for(var o=[],i=0;i<arguments.length;i++)o[i]=arguments[i];if(n&&n.lastThis===this&&t(o,n.lastArgs))return n.lastResult;var a=e.apply(this,o);return n={lastResult:a,lastArgs:o,lastThis:this},a}return r.clear=function(){n=null},r}var Dj=ph,She=pS,The=Hr,Aj=Dj?Dj.isConcatSpreadable:void 0;function xhe(e){return The(e)||She(e)||!!(Aj&&e&&e[Aj])}var Ihe=xhe,khe=SD,Ehe=Ihe;function o_(e,t,n,r,o){var i=-1,a=e.length;for(n||(n=Ehe),o||(o=[]);++i<a;){var s=e[i];t>0&&n(s)?t>1?o_(s,t-1,n,r,o):khe(o,s):r||(o[o.length]=s)}return o}var jD=o_;function Che(e){return function(t,n,r){for(var o=-1,i=Object(t),a=r(t),s=a.length;s--;){var l=a[e?s:++o];if(n(i[l],l,i)===!1)break}return t}}var Mhe=Che,Dhe=Mhe,Ahe=Dhe(),Nhe=Ahe,Ohe=Nhe,Phe=kh;function jhe(e,t){return e&&Ohe(e,t,Phe)}var LD=jhe,Lhe=Qu;function Rhe(e,t){return function(n,r){if(n==null)return n;if(!Lhe(n))return e(n,r);for(var o=n.length,i=t?o:-1,a=Object(n);(t?i--:++i<o)&&r(a[i],i,a)!==!1;);return n}}var Fhe=Rhe,Hhe=LD,_he=Fhe,Bhe=_he(Hhe),RD=Bhe,Yhe=RD,Uhe=Qu;function zhe(e,t){var n=-1,r=Uhe(e)?Array(e.length):[];return Yhe(e,function(o,i,a){r[++n]=t(o,i,a)}),r}var i_=zhe;function Vhe(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}var Whe=Vhe,Nj=Dh;function Ghe(e,t){if(e!==t){var n=e!==void 0,r=e===null,o=e===e,i=Nj(e),a=t!==void 0,s=t===null,l=t===t,u=Nj(t);if(!s&&!u&&!i&&e>t||i&&a&&l&&!s&&!u||r&&a&&l||!n&&l||!o)return 1;if(!r&&!i&&!u&&e<t||u&&n&&o&&!r&&!i||s&&n&&o||!a&&o||!l)return-1}return 0}var Zhe=Ghe,$he=Zhe;function qhe(e,t,n){for(var r=-1,o=e.criteria,i=t.criteria,a=o.length,s=n.length;++r<a;){var l=$he(o[r],i[r]);if(l){if(r>=s)return l;var u=n[r];return l*(u=="desc"?-1:1)}}return e.index-t.index}var Khe=qhe,Qx=jS,Xhe=RS,Jhe=El,Qhe=i_,epe=Whe,tpe=mS,npe=Khe,rpe=Ah,ope=Hr;function ipe(e,t,n){t.length?t=Qx(t,function(i){return ope(i)?function(a){return Xhe(a,i.length===1?i[0]:i)}:i}):t=[rpe];var r=-1;t=Qx(t,tpe(Jhe));var o=Qhe(e,function(i,a,s){var l=Qx(t,function(u){return u(i)});return{criteria:l,index:++r,value:i}});return epe(o,function(i,a){return npe(i,a,n)})}var ape=ipe;function spe(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}var lpe=spe,cpe=lpe,Oj=Math.max;function upe(e,t,n){return t=Oj(t===void 0?e.length-1:t,0),function(){for(var r=arguments,o=-1,i=Oj(r.length-t,0),a=Array(i);++o<i;)a[o]=r[t+o];o=-1;for(var s=Array(t+1);++o<t;)s[o]=r[o];return s[t]=n(a),cpe(e,this,s)}}var a_=upe;function dpe(e){return function(){return e}}var fpe=dpe,hpe=Ju,ppe=function(){try{var e=hpe(Object,"defineProperty");return e({},"",{}),e}catch{}}(),s_=ppe,mpe=fpe,Pj=s_,gpe=Ah,vpe=Pj?function(e,t){return Pj(e,"toString",{configurable:!0,enumerable:!1,value:mpe(t),writable:!0})}:gpe,ype=vpe,bpe=800,wpe=16,Spe=Date.now;function Tpe(e){var t=0,n=0;return function(){var r=Spe(),o=wpe-(r-n);if(n=r,o>0){if(++t>=bpe)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var xpe=Tpe,Ipe=ype,kpe=xpe,Epe=kpe(Ipe),l_=Epe,Cpe=Ah,Mpe=a_,Dpe=l_;function Ape(e,t){return Dpe(Mpe(e,t,Cpe),e+"")}var c_=Ape,Npe=jD,Ope=ape,Ppe=c_,jj=Mh,jpe=Ppe(function(e,t){if(e==null)return[];var n=t.length;return n>1&&jj(e,t[0],t[1])?t=[]:n>2&&jj(t[0],t[1],t[2])&&(t=[t[0]]),Ope(e,Npe(t,1),[])}),Lpe=jpe;const FS=tt(Lpe);function mE(e,t){var n=DD(e);return n?n.innerWidth:t?e.clientWidth:Au(e).width}function u_(e){return T7(e)||F7(e)||kD(e)||x7()}function Rpe(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}var d_=Rpe,Lj=s_;function Fpe(e,t,n){t=="__proto__"&&Lj?Lj(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}var FD=Fpe,Hpe=FD,_pe=cv,Bpe=Object.prototype,Ype=Bpe.hasOwnProperty;function Upe(e,t,n){var r=e[t];(!(Ype.call(e,t)&&_pe(r,n))||n===void 0&&!(t in e))&&Hpe(e,t,n)}var f_=Upe,zpe=f_,Vpe=FD;function Wpe(e,t,n,r){var o=!n;n||(n={});for(var i=-1,a=t.length;++i<a;){var s=t[i],l=r?r(n[s],e[s],s,n,e):void 0;l===void 0&&(l=e[s]),o?Vpe(n,s,l):zpe(n,s,l)}return n}var pv=Wpe,Gpe=pv,Zpe=kh;function $pe(e,t){return e&&Gpe(t,Zpe(t),e)}var qpe=$pe;function Kpe(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var Xpe=Kpe,Jpe=Vi,Qpe=fS,eme=Xpe,tme=Object.prototype,nme=tme.hasOwnProperty;function rme(e){if(!Jpe(e))return eme(e);var t=Qpe(e),n=[];for(var r in e)r=="constructor"&&(t||!nme.call(e,r))||n.push(r);return n}var ome=rme,ime=p7,ame=ome,sme=Qu;function lme(e){return sme(e)?ime(e,!0):ame(e)}var HS=lme,cme=pv,ume=HS;function dme(e,t){return e&&cme(t,ume(t),e)}var fme=dme,R0={exports:{}};R0.exports;(function(e,t){var n=Ta,r=t&&!t.nodeType&&t,o=r&&!0&&e&&!e.nodeType&&e,i=o&&o.exports===r,a=i?n.Buffer:void 0,s=a?a.allocUnsafe:void 0;function l(u,d){if(d)return u.slice();var h=u.length,p=s?s(h):new u.constructor(h);return u.copy(p),p}e.exports=l})(R0,R0.exports);var hme=R0.exports;function pme(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}var mme=pme,gme=pv,vme=TD;function yme(e,t){return gme(e,vme(e),t)}var bme=yme,wme=_8,Sme=wme(Object.getPrototypeOf,Object),_S=Sme,Tme=SD,xme=_S,Ime=TD,kme=h7,Eme=Object.getOwnPropertySymbols,Cme=Eme?function(e){for(var t=[];e;)Tme(t,Ime(e)),e=xme(e);return t}:kme,h_=Cme,Mme=pv,Dme=h_;function Ame(e,t){return Mme(e,Dme(e),t)}var Nme=Ame,Ome=f7,Pme=h_,jme=HS;function Lme(e){return Ome(e,jme,Pme)}var p_=Lme,Rme=Object.prototype,Fme=Rme.hasOwnProperty;function Hme(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]=="string"&&Fme.call(e,"index")&&(n.index=e.index,n.input=e.input),n}var _me=Hme,Rj=d7;function Bme(e){var t=new e.constructor(e.byteLength);return new Rj(t).set(new Rj(e)),t}var HD=Bme,Yme=HD;function Ume(e,t){var n=t?Yme(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var zme=Ume,Vme=/\w*$/;function Wme(e){var t=new e.constructor(e.source,Vme.exec(e));return t.lastIndex=e.lastIndex,t}var Gme=Wme,Fj=ph,Hj=Fj?Fj.prototype:void 0,_j=Hj?Hj.valueOf:void 0;function Zme(e){return _j?Object(_j.call(e)):{}}var $me=Zme,qme=HD;function Kme(e,t){var n=t?qme(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var Xme=Kme,Jme=HD,Qme=zme,ege=Gme,tge=$me,nge=Xme,rge="[object Boolean]",oge="[object Date]",ige="[object Map]",age="[object Number]",sge="[object RegExp]",lge="[object Set]",cge="[object String]",uge="[object Symbol]",dge="[object ArrayBuffer]",fge="[object DataView]",hge="[object Float32Array]",pge="[object Float64Array]",mge="[object Int8Array]",gge="[object Int16Array]",vge="[object Int32Array]",yge="[object Uint8Array]",bge="[object Uint8ClampedArray]",wge="[object Uint16Array]",Sge="[object Uint32Array]";function Tge(e,t,n){var r=e.constructor;switch(t){case dge:return Jme(e);case rge:case oge:return new r(+e);case fge:return Qme(e,n);case hge:case pge:case mge:case gge:case vge:case yge:case bge:case wge:case Sge:return nge(e,n);case ige:return new r;case age:case cge:return new r(e);case sge:return ege(e);case lge:return new r;case uge:return tge(e)}}var xge=Tge,Ige=Vi,Bj=Object.create,kge=function(){function e(){}return function(t){if(!Ige(t))return{};if(Bj)return Bj(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}(),m_=kge,Ege=m_,Cge=_S,Mge=fS;function Dge(e){return typeof e.constructor=="function"&&!Mge(e)?Ege(Cge(e)):{}}var Age=Dge,Nge=Jg,Oge=xa,Pge="[object Map]";function jge(e){return Oge(e)&&Nge(e)==Pge}var Lge=jge,Rge=Lge,Fge=mS,Yj=ZM,Uj=Yj&&Yj.isMap,Hge=Uj?Fge(Uj):Rge,_ge=Hge,Bge=Jg,Yge=xa,Uge="[object Set]";function zge(e){return Yge(e)&&Bge(e)==Uge}var Vge=zge,Wge=Vge,Gge=mS,zj=ZM,Vj=zj&&zj.isSet,Zge=Vj?Gge(Vj):Wge,$ge=Zge,qge=bD,Kge=d_,Xge=f_,Jge=qpe,Qge=fme,eve=hme,tve=mme,nve=bme,rve=Nme,ove=m7,ive=p_,ave=Jg,sve=_me,lve=xge,cve=Age,uve=Hr,dve=Qg,fve=_ge,hve=Vi,pve=$ge,mve=kh,gve=HS,vve=1,yve=2,bve=4,g_="[object Arguments]",wve="[object Array]",Sve="[object Boolean]",Tve="[object Date]",xve="[object Error]",v_="[object Function]",Ive="[object GeneratorFunction]",kve="[object Map]",Eve="[object Number]",y_="[object Object]",Cve="[object RegExp]",Mve="[object Set]",Dve="[object String]",Ave="[object Symbol]",Nve="[object WeakMap]",Ove="[object ArrayBuffer]",Pve="[object DataView]",jve="[object Float32Array]",Lve="[object Float64Array]",Rve="[object Int8Array]",Fve="[object Int16Array]",Hve="[object Int32Array]",_ve="[object Uint8Array]",Bve="[object Uint8ClampedArray]",Yve="[object Uint16Array]",Uve="[object Uint32Array]",yn={};yn[g_]=yn[wve]=yn[Ove]=yn[Pve]=yn[Sve]=yn[Tve]=yn[jve]=yn[Lve]=yn[Rve]=yn[Fve]=yn[Hve]=yn[kve]=yn[Eve]=yn[y_]=yn[Cve]=yn[Mve]=yn[Dve]=yn[Ave]=yn[_ve]=yn[Bve]=yn[Yve]=yn[Uve]=!0;yn[xve]=yn[v_]=yn[Nve]=!1;function $b(e,t,n,r,o,i){var a,s=t&vve,l=t&yve,u=t&bve;if(n&&(a=o?n(e,r,o,i):n(e)),a!==void 0)return a;if(!hve(e))return e;var d=uve(e);if(d){if(a=sve(e),!s)return tve(e,a)}else{var h=ave(e),p=h==v_||h==Ive;if(dve(e))return eve(e,s);if(h==y_||h==g_||p&&!o){if(a=l||p?{}:cve(e),!s)return l?rve(e,Qge(a,e)):nve(e,Jge(a,e))}else{if(!yn[h])return o?e:{};a=lve(e,h,s)}}i||(i=new qge);var m=i.get(e);if(m)return m;i.set(e,a),pve(e)?e.forEach(function(y){a.add($b(y,t,n,y,e,i))}):fve(e)&&e.forEach(function(y,S){a.set(S,$b(y,t,n,S,e,i))});var b=u?l?ive:ove:l?gve:mve,v=d?void 0:b(e);return Kge(v||e,function(y,S){v&&(S=y,y=e[S]),Xge(a,S,$b(y,t,n,S,e,i))}),a}var zve=$b;function Vve(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}var b_=Vve;const Wve=tt(b_);var Gve=RS,Zve=MD;function $ve(e,t){return t.length<2?e:Gve(e,Zve(t,0,-1))}var qve=$ve,Kve=LS,Xve=b_,Jve=qve,Qve=hv;function eye(e,t){return t=Kve(t,e),e=Jve(e,t),e==null||delete e[Qve(Xve(t))]}var tye=eye,nye=kl,rye=_S,oye=xa,iye="[object Object]",aye=Function.prototype,sye=Object.prototype,w_=aye.toString,lye=sye.hasOwnProperty,cye=w_.call(Object);function uye(e){if(!oye(e)||nye(e)!=iye)return!1;var t=rye(e);if(t===null)return!0;var n=lye.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&w_.call(n)==cye}var S_=uye;const dye=tt(S_);var fye=S_;function hye(e){return fye(e)?void 0:e}var pye=hye,mye=jD;function gye(e){var t=e==null?0:e.length;return t?mye(e,1):[]}var vye=gye,yye=vye,bye=a_,wye=l_;function Sye(e){return wye(bye(e,void 0,yye),e+"")}var Tye=Sye,xye=jS,Iye=zve,kye=tye,Eye=LS,Cye=pv,Mye=pye,Dye=Tye,Aye=p_,Nye=1,Oye=2,Pye=4,jye=Dye(function(e,t){var n={};if(e==null)return n;var r=!1;t=xye(t,function(i){return i=Eye(i,e),r||(r=i.length>1),i}),Cye(e,Aye(e),n),r&&(n=Iye(n,Nye|Oye|Pye,Mye));for(var o=t.length;o--;)kye(n,t[o]);return n}),Lye=jye;const Rye=tt(Lye);var Fye=c_,Hye=cv,_ye=Mh,Bye=HS,T_=Object.prototype,Yye=T_.hasOwnProperty,Uye=Fye(function(e,t){e=Object(e);var n=-1,r=t.length,o=r>2?t[2]:void 0;for(o&&_ye(t[0],t[1],o)&&(r=1);++n<r;)for(var i=t[n],a=Bye(i),s=-1,l=a.length;++s<l;){var u=a[s],d=e[u];(d===void 0||Hye(d,T_[u])&&!Yye.call(e,u))&&(e[u]=i[u])}return e}),zye=Uye;const Vye=tt(zye);var Wye=d_,Gye=m_,Zye=LD,$ye=El,qye=_S,Kye=Hr,Xye=Qg,Jye=hS,Qye=Vi,ebe=gS;function tbe(e,t,n){var r=Kye(e),o=r||Xye(e)||ebe(e);if(t=$ye(t),n==null){var i=e&&e.constructor;o?n=r?new i:[]:Qye(e)?n=Jye(i)?Gye(qye(e)):{}:n={}}return(o?Wye:Zye)(e,function(a,s,l){return t(n,a,s,l)}),n}var nbe=tbe;const rbe=tt(nbe);var obe=FD,ibe=LD,abe=El;function sbe(e,t){var n={};return t=abe(t),ibe(e,function(r,o,i){obe(n,o,t(r,o,i))}),n}var lbe=sbe;const x_=tt(lbe);var cbe={exports:{}};(function(e,t){(function(n,r){e.exports=r()})(xr,function(){return function(n,r,o){r.prototype.isBetween=function(i,a,s,l){var u=o(i),d=o(a),h=(l=l||"()")[0]==="(",p=l[1]===")";return(h?this.isAfter(u,s):!this.isBefore(u,s))&&(p?this.isBefore(d,s):!this.isAfter(d,s))||(h?this.isBefore(u,s):!this.isAfter(u,s))&&(p?this.isAfter(d,s):!this.isBefore(d,s))}}})})(cbe);var ube={exports:{}};(function(e,t){(function(n,r){e.exports=r()})(xr,function(){return function(n,r){r.prototype.isSameOrAfter=function(o,i){return this.isSame(o,i)||this.isAfter(o,i)}}})})(ube);var dbe={exports:{}};(function(e,t){(function(n,r){e.exports=r()})(xr,function(){return function(n,r){r.prototype.isSameOrBefore=function(o,i){return this.isSame(o,i)||this.isBefore(o,i)}}})})(dbe);var fbe={exports:{}};(function(e,t){(function(n,r){e.exports=r()})(xr,function(){return function(n,r,o){var i=r.prototype,a=function(h){return h&&(h.indexOf?h:h.s)},s=function(h,p,m,b,v){var y=h.name?h:h.$locale(),S=a(y[p]),x=a(y[m]),C=S||x.map(function(M){return M.slice(0,b)});if(!v)return C;var k=y.weekStart;return C.map(function(M,I){return C[(I+(k||0))%7]})},l=function(){return o.Ls[o.locale()]},u=function(h,p){return h.formats[p]||function(m){return m.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(b,v,y){return v||y.slice(1)})}(h.formats[p.toUpperCase()])},d=function(){var h=this;return{months:function(p){return p?p.format("MMMM"):s(h,"months")},monthsShort:function(p){return p?p.format("MMM"):s(h,"monthsShort","months",3)},firstDayOfWeek:function(){return h.$locale().weekStart||0},weekdays:function(p){return p?p.format("dddd"):s(h,"weekdays")},weekdaysMin:function(p){return p?p.format("dd"):s(h,"weekdaysMin","weekdays",2)},weekdaysShort:function(p){return p?p.format("ddd"):s(h,"weekdaysShort","weekdays",3)},longDateFormat:function(p){return u(h.$locale(),p)},meridiem:this.$locale().meridiem,ordinal:this.$locale().ordinal}};i.localeData=function(){return d.bind(this)()},o.localeData=function(){var h=l();return{firstDayOfWeek:function(){return h.weekStart||0},weekdays:function(){return o.weekdays()},weekdaysShort:function(){return o.weekdaysShort()},weekdaysMin:function(){return o.weekdaysMin()},months:function(){return o.months()},monthsShort:function(){return o.monthsShort()},longDateFormat:function(p){return u(h,p)},meridiem:h.meridiem,ordinal:h.ordinal}},o.months=function(){return s(l(),"months")},o.monthsShort=function(){return s(l(),"monthsShort","months",3)},o.weekdays=function(h){return s(l(),"weekdays",null,null,h)},o.weekdaysShort=function(h){return s(l(),"weekdaysShort","weekdays",3,h)},o.weekdaysMin=function(h){return s(l(),"weekdaysMin","weekdays",2,h)}}})})(fbe);var hbe={exports:{}};(function(e,t){(function(n,r){e.exports=r()})(xr,function(){var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(r,o,i){var a=o.prototype,s=a.format;i.en.formats=n,a.format=function(l){l===void 0&&(l="YYYY-MM-DDTHH:mm:ssZ");var u=this.$locale().formats,d=function(h,p){return h.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(m,b,v){var y=v&&v.toUpperCase();return b||p[v]||n[v]||p[y].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(S,x,C){return x||C.slice(1)})})}(l,u===void 0?{}:u);return s.call(this,d)}}})})(hbe);var pbe={exports:{}};(function(e,t){(function(n,r){e.exports=r()})(xr,function(){return function(n,r,o){var i=function(a,s){if(!s||!s.length||s.length===1&&!s[0]||s.length===1&&Array.isArray(s[0])&&!s[0].length)return null;var l;s.length===1&&s[0].length>0&&(s=s[0]),l=(s=s.filter(function(d){return d}))[0];for(var u=1;u<s.length;u+=1)s[u].isValid()&&!s[u][a](l)||(l=s[u]);return l};o.max=function(){var a=[].slice.call(arguments,0);return i("isAfter",a)},o.min=function(){var a=[].slice.call(arguments,0);return i("isBefore",a)}}})})(pbe);var mbe={exports:{}};(function(e,t){(function(n,r){e.exports=r()})(xr,function(){var n="minute",r=/[+-]\d\d(?::?\d\d)?/g,o=/([+-]|\d\d)/g;return function(i,a,s){var l=a.prototype;s.utc=function(v){var y={date:v,utc:!0,args:arguments};return new a(y)},l.utc=function(v){var y=s(this.toDate(),{locale:this.$L,utc:!0});return v?y.add(this.utcOffset(),n):y},l.local=function(){return s(this.toDate(),{locale:this.$L,utc:!1})};var u=l.parse;l.parse=function(v){v.utc&&(this.$u=!0),this.$utils().u(v.$offset)||(this.$offset=v.$offset),u.call(this,v)};var d=l.init;l.init=function(){if(this.$u){var v=this.$d;this.$y=v.getUTCFullYear(),this.$M=v.getUTCMonth(),this.$D=v.getUTCDate(),this.$W=v.getUTCDay(),this.$H=v.getUTCHours(),this.$m=v.getUTCMinutes(),this.$s=v.getUTCSeconds(),this.$ms=v.getUTCMilliseconds()}else d.call(this)};var h=l.utcOffset;l.utcOffset=function(v,y){var S=this.$utils().u;if(S(v))return this.$u?0:S(this.$offset)?h.call(this):this.$offset;if(typeof v=="string"&&(v=function(M){M===void 0&&(M="");var I=M.match(r);if(!I)return null;var O=(""+I[0]).match(o)||["-",0,0],R=O[0],L=60*+O[1]+ +O[2];return L===0?0:R==="+"?L:-L}(v),v===null))return this;var x=Math.abs(v)<=16?60*v:v,C=this;if(y)return C.$offset=x,C.$u=v===0,C;if(v!==0){var k=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(C=this.local().add(x+k,n)).$offset=x,C.$x.$localOffset=k}else C=this.utc();return C};var p=l.format;l.format=function(v){var y=v||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return p.call(this,y)},l.valueOf=function(){var v=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*v},l.isUTC=function(){return!!this.$u},l.toISOString=function(){return this.toDate().toISOString()},l.toString=function(){return this.toDate().toUTCString()};var m=l.toDate;l.toDate=function(v){return v==="s"&&this.$offset?s(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():m.call(this)};var b=l.diff;l.diff=function(v,y,S){if(v&&this.$u===v.$u)return b.call(this,v,y,S);var x=this.local(),C=s(v).local();return b.call(x,C,y,S)}}})})(mbe);function qs(e){return e.children}var Wo={PREVIOUS:"PREV",NEXT:"NEXT",TODAY:"TODAY",DATE:"DATE"},po={MONTH:"month",WEEK:"week",WORK_WEEK:"work_week",DAY:"day",AGENDA:"agenda"},Wj=Object.keys(po).map(function(e){return po[e]});pe.oneOfType([pe.string,pe.func]);pe.any;pe.func;pe.oneOfType([pe.arrayOf(pe.oneOf(Wj)),pe.objectOf(function(e,t){var n=Wj.indexOf(t)!==-1&&typeof e[t]=="boolean";if(n)return null;for(var r=arguments.length,o=new Array(r>2?r-2:0),i=2;i<r;i++)o[i-2]=arguments[i];return pe.elementType.apply(pe,[e,t].concat(o))})]);pe.oneOfType([pe.oneOf(["overlap","no-overlap"]),pe.func]);function Nn(e,t){e&&e.apply(null,[].concat(t))}var Gj={seconds:1e3,minutes:1e3*60,hours:1e3*60*60,day:1e3*60*60*24};function I_(e,t){var n=Fr(e,"month");return Fr(n,"week",t.startOfWeek())}function k_(e,t){var n=j0(e,"month");return j0(n,"week",t.startOfWeek())}function gbe(e,t){for(var n=I_(e,t),r=k_(e,t),o=[];Eh(n,r,"day");)o.push(n),n=ba(n,1,"day");return o}function vbe(e,t){var n=Fr(e,t);return uv(n,e)?n:ba(n,1,t)}function ybe(e,t){for(var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"day",r=e,o=[];Eh(r,t,n);)o.push(r),r=ba(r,1,n);return o}function bbe(e,t){return t==null&&e==null?null:(t==null&&(t=new Date),e==null&&(e=new Date),e=Fr(e,"day"),e=$m(e,$m(t)),e=Af(e,Af(t)),e=Zm(e,Zm(t)),Gm(e,Gm(t)))}function Zj(e){return $m(e)===0&&Af(e)===0&&Zm(e)===0&&Gm(e)===0}function wbe(e,t,n,r){return n==="day"&&(n="date"),Math.abs(uj[n](e,void 0,r)-uj[n](t,void 0,r))}function _D(e,t,n){return!n||n==="milliseconds"?Math.abs(+e-+t):Math.round(Math.abs(+Fr(e,n)/Gj[n]-+Fr(t,n)/Gj[n]))}var Sbe=pe.oneOfType([pe.string,pe.func]);function Tbe(e,t,n,r,o){var i=typeof r=="function"?r(n,o,e):t.call(e,n,r,o);return Bm(i==null||typeof i=="string","`localizer format(..)` must return a string, null, or undefined"),i}function xbe(e,t,n){return new Date(e.getFullYear(),e.getMonth(),e.getDate(),0,t+n,0,0)}function BD(e,t){return e.getTimezoneOffset()-t.getTimezoneOffset()}function Ibe(e,t){return _D(e,t,"minutes")+BD(e,t)}function kbe(e){var t=Fr(e,"day");return _D(t,e,"minutes")+BD(t,e)}function Ebe(e,t){return CD(e,t,"day")}function Cbe(e,t,n){var r=uv(e,t,"minutes");return r?dv(t,n,"minutes"):PS(t,n,"minutes")}function gE(e,t){return wbe(e,t,"day")}function Mbe(e){var t=e.evtA,n=t.start,r=t.end,o=t.allDay,i=e.evtB,a=i.start,s=i.end,l=i.allDay,u=+Fr(n,"day")-+Fr(a,"day"),d=gE(n,r),h=gE(a,s);return u||h-d||!!l-!!o||+n-+a||+r-+s}function Dbe(e){var t=e.event,n=t.start,r=t.end,o=e.range,i=o.start,a=o.end,s=Fr(n,"day"),l=Eh(s,a,"day"),u=ED(s,r,"minutes"),d=u?PS(r,i,"minutes"):dv(r,i,"minutes");return l&&d}function Abe(e,t){return uv(e,t,"day")}function Nbe(e,t){return Zj(e)&&Zj(t)}var Obe=kr(function e(t){var n=this;Ir(this,e),Bm(typeof t.format=="function","date localizer `format(..)` must be a function"),Bm(typeof t.firstOfWeek=="function","date localizer `firstOfWeek(..)` must be a function"),this.propType=t.propType||Sbe,this.formats=t.formats,this.format=function(){for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return Tbe.apply(void 0,[n,t.format].concat(o))},this.startOfWeek=t.firstOfWeek,this.merge=t.merge||bbe,this.inRange=t.inRange||P7,this.lt=t.lt||CD,this.lte=t.lte||Eh,this.gt=t.gt||PS,this.gte=t.gte||dv,this.eq=t.eq||uv,this.neq=t.neq||ED,this.startOf=t.startOf||Fr,this.endOf=t.endOf||j0,this.add=t.add||ba,this.range=t.range||ybe,this.diff=t.diff||_D,this.ceil=t.ceil||vbe,this.min=t.min||N7,this.max=t.max||O7,this.minutes=t.minutes||Af,this.daySpan=t.daySpan||gE,this.firstVisibleDay=t.firstVisibleDay||I_,this.lastVisibleDay=t.lastVisibleDay||k_,this.visibleDays=t.visibleDays||gbe,this.getSlotDate=t.getSlotDate||xbe,this.getTimezoneOffset=t.getTimezoneOffset||function(r){return r.getTimezoneOffset()},this.getDstOffset=t.getDstOffset||BD,this.getTotalMin=t.getTotalMin||Ibe,this.getMinutesFromMidnight=t.getMinutesFromMidnight||kbe,this.continuesPrior=t.continuesPrior||Ebe,this.continuesAfter=t.continuesAfter||Cbe,this.sortEvents=t.sortEvents||Mbe,this.inEventRange=t.inEventRange||Dbe,this.isSameDate=t.isSameDate||Abe,this.startAndEndAreDateOnly=t.startAndEndAreDateOnly||Nbe,this.segmentOffset=t.browserTZOffset?t.browserTZOffset():0});function Pbe(e,t,n,r){var o=pn(pn({},e.formats),n);return pn(pn({},e),{},{messages:r,startOfWeek:function(){return e.startOfWeek(t)},format:function(a,s){return e.format(a,o[s]||s,t)}})}var jbe={date:"Date",time:"Time",event:"Event",allDay:"All Day",week:"Week",work_week:"Work Week",day:"Day",month:"Month",previous:"Back",next:"Next",yesterday:"Yesterday",tomorrow:"Tomorrow",today:"Today",agenda:"Agenda",noEventsInRange:"There are no events in this range.",showMore:function(t){return"+".concat(t," more")}};function Lbe(e){return pn(pn({},jbe),e)}function Rbe(e){var t=e.ref,n=e.callback;D.useEffect(function(){var r=function(i){t.current&&!t.current.contains(i.target)&&n()};return document.addEventListener("mousedown",r),function(){document.removeEventListener("mousedown",r)}},[t,n])}var Fbe=["style","className","event","selected","isAllDay","onSelect","onDoubleClick","onKeyPress","localizer","continuesPrior","continuesAfter","accessors","getters","children","components","slotStart","slotEnd"],E_=function(e){bo(t,e);function t(){return Ir(this,t),yo(this,t,arguments)}return kr(t,[{key:"render",value:function(){var r=this.props,o=r.style,i=r.className,a=r.event,s=r.selected,l=r.isAllDay,u=r.onSelect,d=r.onDoubleClick,h=r.onKeyPress,p=r.localizer,m=r.continuesPrior,b=r.continuesAfter,v=r.accessors,y=r.getters,S=r.children,x=r.components,C=x.event,k=x.eventWrapper,M=r.slotStart,I=r.slotEnd,O=Ss(r,Fbe);delete O.resizable;var R=v.title(a),L=v.tooltip(a),B=v.end(a),_=v.start(a),H=v.allDay(a),U=l||H||p.diff(_,p.ceil(B,"day"),"day")>1,G=y.eventProp(a,_,B,s),K=Y.createElement("div",{className:"rbc-event-content",title:L||void 0},C?Y.createElement(C,{event:a,continuesPrior:m,continuesAfter:b,title:R,isAllDay:H,localizer:p,slotStart:M,slotEnd:I}):R);return Y.createElement(k,Object.assign({},this.props,{type:"date"}),Y.createElement("div",Object.assign({},O,{style:pn(pn({},G.style),o),className:fr("rbc-event",i,G.className,{"rbc-selected":s,"rbc-event-allday":U,"rbc-event-continues-prior":m,"rbc-event-continues-after":b}),onClick:function(ne){return u&&u(a,ne)},onDoubleClick:function(ne){return d&&d(a,ne)},onKeyDown:function(ne){return h&&h(a,ne)}}),typeof S=="function"?S(K):K))}}]),t}(Y.Component);function BS(e,t){return!e||t==null?!1:ws(e,t)}function C_(e,t){var n=e.right-e.left,r=n/t;return r}function M_(e,t,n,r){var o=C_(e,r);return n?r-1-Math.floor((t-e.left)/o):Math.floor((t-e.left)/o)}function Hbe(e,t){var n=t.x,r=t.y;return r>=e.top&&r<=e.bottom&&n>=e.left&&n<=e.right}function _be(e,t,n,r,o){var i=-1,a=-1,s=r-1,l=C_(t,r),u=M_(t,n.x,o,r),d=t.top<n.y&&t.bottom>n.y,h=t.top<e.y&&t.bottom>e.y,p=e.y>t.bottom,m=t.top>e.y,b=n.top<t.top&&n.bottom>t.bottom;return b&&(i=0,a=s),d&&(m?(i=0,a=u):p&&(i=u,a=s)),h&&(i=a=o?s-Math.floor((e.x-t.left)/l):Math.floor((e.x-t.left)/l),d?u<i?i=u:a=u:e.y<n.y?a=s:i=0),{startIdx:i,endIdx:a}}function Bbe(e){var t=e.target,n=e.offset,r=e.container,o=e.box,i=Au(t),a=i.top,s=i.left,l=i.width,u=i.height,d=Au(r),h=d.top,p=d.left,m=d.width,b=d.height,v=Au(o),y=v.width,S=v.height,x=h+b,C=p+m,k=a+S,M=s+y,I=n.x,O=n.y,R=k>x?a-S-O:a+O+u,L=M>C?s+I-y+l:s+I;return{topOffset:R,leftOffset:L}}function Ybe(e){var t=e.containerRef,n=e.accessors,r=e.getters,o=e.selected,i=e.components,a=e.localizer,s=e.position,l=e.show,u=e.events,d=e.slotStart,h=e.slotEnd,p=e.onSelect,m=e.onDoubleClick,b=e.onKeyPress,v=e.handleDragStart,y=e.popperRef,S=e.target,x=e.offset;Rbe({ref:y,callback:l}),D.useLayoutEffect(function(){var M=Bbe({target:S,offset:x,container:t.current,box:y.current}),I=M.topOffset,O=M.leftOffset;y.current.style.top="".concat(I,"px"),y.current.style.left="".concat(O,"px")},[x.x,x.y,S]);var C=s.width,k={minWidth:C+C/2};return Y.createElement("div",{style:k,className:"rbc-overlay",ref:y},Y.createElement("div",{className:"rbc-overlay-header"},a.format(d,"dayHeaderFormat")),u.map(function(M,I){return Y.createElement(E_,{key:I,type:"popup",localizer:a,event:M,getters:r,onSelect:p,accessors:n,components:i,onDoubleClick:m,onKeyPress:b,continuesPrior:a.lt(n.end(M),d,"day"),continuesAfter:a.gte(n.start(M),h,"day"),slotStart:d,slotEnd:h,selected:BS(M,o),draggable:!0,onDragStart:function(){return v(M)},onDragEnd:function(){return l()}})}))}var D_=Y.forwardRef(function(e,t){return Y.createElement(Ybe,Object.assign({},e,{popperRef:t}))});D_.propTypes={accessors:pe.object.isRequired,getters:pe.object.isRequired,selected:pe.object,components:pe.object.isRequired,localizer:pe.object.isRequired,position:pe.object.isRequired,show:pe.func.isRequired,events:pe.array.isRequired,slotStart:pe.instanceOf(Date).isRequired,slotEnd:pe.instanceOf(Date),onSelect:pe.func,onDoubleClick:pe.func,onKeyPress:pe.func,handleDragStart:pe.func,style:pe.object,offset:pe.shape({x:pe.number,y:pe.number})};function Ube(e){var t=e.containerRef,n=e.popupOffset,r=n===void 0?5:n,o=e.overlay,i=e.accessors,a=e.localizer,s=e.components,l=e.getters,u=e.selected,d=e.handleSelectEvent,h=e.handleDoubleClickEvent,p=e.handleKeyPressEvent,m=e.handleDragStart,b=e.onHide,v=e.overlayDisplay,y=D.useRef(null);if(!o.position)return null;var S=r;isNaN(r)||(S={x:r,y:r});var x=o.position,C=o.events,k=o.date,M=o.end;return Y.createElement(ude,{rootClose:!0,flip:!0,show:!0,placement:"bottom",onHide:b,target:o.target},function(I){var O=I.props;return Y.createElement(D_,Object.assign({},O,{containerRef:t,ref:y,target:o.target,offset:S,accessors:i,getters:l,selected:u,components:s,localizer:a,position:x,show:v,events:C,slotStart:k,slotEnd:M,onSelect:d,onDoubleClick:h,onKeyPress:p,handleDragStart:m}))})}var YD=Y.forwardRef(function(e,t){return Y.createElement(Ube,Object.assign({},e,{containerRef:t}))});YD.propTypes={popupOffset:pe.oneOfType([pe.number,pe.shape({x:pe.number,y:pe.number})]),overlay:pe.shape({position:pe.object,events:pe.array,date:pe.instanceOf(Date),end:pe.instanceOf(Date)}),accessors:pe.object.isRequired,localizer:pe.object.isRequired,components:pe.object.isRequired,getters:pe.object.isRequired,selected:pe.object,handleSelectEvent:pe.func,handleDoubleClickEvent:pe.func,handleKeyPressEvent:pe.func,handleDragStart:pe.func,onHide:pe.func,overlayDisplay:pe.func};function Kr(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:document;return nm(n,e,t,{passive:!1})}function zbe(e,t,n){return!e||qm(e,document.elementFromPoint(t,n))}function Vbe(e,t){var n=t.clientX,r=t.clientY,o=document.elementFromPoint(n,r);return Z7(o,".rbc-event",e)}function Wbe(e,t){var n=t.clientX,r=t.clientY,o=document.elementFromPoint(n,r);return Z7(o,".rbc-show-more",e)}function F0(e,t){return!!Vbe(e,t)}function Gbe(e,t){return!!Wbe(e,t)}function zd(e){var t=e;return e.touches&&e.touches.length&&(t=e.touches[0]),{clientX:t.clientX,clientY:t.clientY,pageX:t.pageX,pageY:t.pageY}}var $j=5,Zbe=250,A_=function(){function e(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.global,o=r===void 0?!1:r,i=n.longPressThreshold,a=i===void 0?250:i,s=n.validContainers,l=s===void 0?[]:s;Ir(this,e),this.isDetached=!1,this.container=t,this.globalMouse=!t||o,this.longPressThreshold=a,this.validContainers=l,this._listeners=Object.create(null),this._handleInitialEvent=this._handleInitialEvent.bind(this),this._handleMoveEvent=this._handleMoveEvent.bind(this),this._handleTerminatingEvent=this._handleTerminatingEvent.bind(this),this._keyListener=this._keyListener.bind(this),this._dropFromOutsideListener=this._dropFromOutsideListener.bind(this),this._dragOverFromOutsideListener=this._dragOverFromOutsideListener.bind(this),this._removeTouchMoveWindowListener=Kr("touchmove",function(){},window),this._removeKeyDownListener=Kr("keydown",this._keyListener),this._removeKeyUpListener=Kr("keyup",this._keyListener),this._removeDropFromOutsideListener=Kr("drop",this._dropFromOutsideListener),this._removeDragOverFromOutsideListener=Kr("dragover",this._dragOverFromOutsideListener),this._addInitialEventListener()}return kr(e,[{key:"on",value:function(n,r){var o=this._listeners[n]||(this._listeners[n]=[]);return o.push(r),{remove:function(){var a=o.indexOf(r);a!==-1&&o.splice(a,1)}}}},{key:"emit",value:function(n){for(var r=arguments.length,o=new Array(r>1?r-1:0),i=1;i<r;i++)o[i-1]=arguments[i];var a,s=this._listeners[n]||[];return s.forEach(function(l){a===void 0&&(a=l.apply(void 0,o))}),a}},{key:"teardown",value:function(){this.isDetached=!0,this._listeners=Object.create(null),this._removeTouchMoveWindowListener&&this._removeTouchMoveWindowListener(),this._removeInitialEventListener&&this._removeInitialEventListener(),this._removeEndListener&&this._removeEndListener(),this._onEscListener&&this._onEscListener(),this._removeMoveListener&&this._removeMoveListener(),this._removeKeyUpListener&&this._removeKeyUpListener(),this._removeKeyDownListener&&this._removeKeyDownListener(),this._removeDropFromOutsideListener&&this._removeDropFromOutsideListener(),this._removeDragOverFromOutsideListener&&this._removeDragOverFromOutsideListener()}},{key:"isSelected",value:function(n){var r=this._selectRect;return!r||!this.selecting?!1:qj(r,zu(n))}},{key:"filter",value:function(n){var r=this._selectRect;return!r||!this.selecting?[]:n.filter(this.isSelected,this)}},{key:"_addLongPressListener",value:function(n,r){var o=this,i=null,a=null,s=null,l=function(p){i=setTimeout(function(){d(),n(p)},o.longPressThreshold),a=Kr("touchmove",function(){return d()}),s=Kr("touchend",function(){return d()})},u=Kr("touchstart",l),d=function(){i&&clearTimeout(i),a&&a(),s&&s(),i=null,a=null,s=null};return r&&l(r),function(){d(),u()}}},{key:"_addInitialEventListener",value:function(){var n=this,r=Kr("mousedown",function(i){n._removeInitialEventListener(),n._handleInitialEvent(i),n._removeInitialEventListener=Kr("mousedown",n._handleInitialEvent)}),o=Kr("touchstart",function(i){n._removeInitialEventListener(),n._removeInitialEventListener=n._addLongPressListener(n._handleInitialEvent,i)});this._removeInitialEventListener=function(){r(),o()}}},{key:"_dropFromOutsideListener",value:function(n){var r=zd(n),o=r.pageX,i=r.pageY,a=r.clientX,s=r.clientY;this.emit("dropFromOutside",{x:o,y:i,clientX:a,clientY:s}),n.preventDefault()}},{key:"_dragOverFromOutsideListener",value:function(n){var r=zd(n),o=r.pageX,i=r.pageY,a=r.clientX,s=r.clientY;this.emit("dragOverFromOutside",{x:o,y:i,clientX:a,clientY:s}),n.preventDefault()}},{key:"_handleInitialEvent",value:function(n){if(!this.isDetached){var r=zd(n),o=r.clientX,i=r.clientY,a=r.pageX,s=r.pageY,l=this.container(),u,d;if(!(n.which===3||n.button===2||!zbe(l,o,i))){if(!this.globalMouse&&l&&!qm(l,n.target)){var h=$be(0),p=h.top,m=h.left,b=h.bottom,v=h.right;if(d=zu(l),u=qj({top:d.top-p,left:d.left-m,bottom:d.bottom+b,right:d.right+v},{top:s,left:a}),!u)return}var y=this.emit("beforeSelect",this._initialEventData={isTouch:/^touch/.test(n.type),x:a,y:s,clientX:o,clientY:i});if(y!==!1)switch(n.type){case"mousedown":this._removeEndListener=Kr("mouseup",this._handleTerminatingEvent),this._onEscListener=Kr("keydown",this._handleTerminatingEvent),this._removeMoveListener=Kr("mousemove",this._handleMoveEvent);break;case"touchstart":this._handleMoveEvent(n),this._removeEndListener=Kr("touchend",this._handleTerminatingEvent),this._removeMoveListener=Kr("touchmove",this._handleMoveEvent);break}}}}},{key:"_isWithinValidContainer",value:function(n){var r=n.target,o=this.validContainers;return!o||!o.length||!r?!0:o.some(function(i){return!!r.closest(i)})}},{key:"_handleTerminatingEvent",value:function(n){var r=zd(n),o=r.pageX,i=r.pageY;if(this.selecting=!1,this._removeEndListener&&this._removeEndListener(),this._removeMoveListener&&this._removeMoveListener(),!!this._initialEventData){var a=!this.container||qm(this.container(),n.target),s=this._isWithinValidContainer(n),l=this._selectRect,u=this.isClick(o,i);return this._initialEventData=null,n.key==="Escape"||!s?this.emit("reset"):u&&a?this._handleClickEvent(n):u?this.emit("reset"):this.emit("select",l)}}},{key:"_handleClickEvent",value:function(n){var r=zd(n),o=r.pageX,i=r.pageY,a=r.clientX,s=r.clientY,l=new Date().getTime();return this._lastClickData&&l-this._lastClickData.timestamp<Zbe?(this._lastClickData=null,this.emit("doubleClick",{x:o,y:i,clientX:a,clientY:s})):(this._lastClickData={timestamp:l},this.emit("click",{x:o,y:i,clientX:a,clientY:s}))}},{key:"_handleMoveEvent",value:function(n){if(!(this._initialEventData===null||this.isDetached)){var r=this._initialEventData,o=r.x,i=r.y,a=zd(n),s=a.pageX,l=a.pageY,u=Math.abs(o-s),d=Math.abs(i-l),h=Math.min(s,o),p=Math.min(l,i),m=this.selecting;this.isClick(s,l)&&!m&&!(u||d)||(this.selecting=!0,this._selectRect={top:p,left:h,x:s,y:l,right:h+u,bottom:p+d},m||this.emit("selectStart",this._initialEventData),this.isClick(s,l)||this.emit("selecting",this._selectRect),n.preventDefault())}}},{key:"_keyListener",value:function(n){this.ctrl=n.metaKey||n.ctrlKey}},{key:"isClick",value:function(n,r){var o=this._initialEventData,i=o.x,a=o.y,s=o.isTouch;return!s&&Math.abs(n-i)<=$j&&Math.abs(r-a)<=$j}}]),e}();function $be(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;return ml(e)!=="object"&&(e={top:e,left:e,right:e,bottom:e}),e}function qj(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,r=zu(e),o=r.top,i=r.left,a=r.right,s=a===void 0?i:a,l=r.bottom,u=l===void 0?o:l,d=zu(t),h=d.top,p=d.left,m=d.right,b=m===void 0?p:m,v=d.bottom,y=v===void 0?h:v;return!(u-n<h||o+n>y||s-n<p||i+n>b)}function zu(e){if(!e.getBoundingClientRect)return e;var t=e.getBoundingClientRect(),n=t.left+Kj("left"),r=t.top+Kj("top");return{top:r,left:n,right:(e.offsetWidth||0)+n,bottom:(e.offsetHeight||0)+r}}function Kj(e){if(e==="left")return window.pageXOffset||document.body.scrollLeft||0;if(e==="top")return window.pageYOffset||document.body.scrollTop||0}var qbe=function(e){bo(t,e);function t(n,r){var o;return Ir(this,t),o=yo(this,t,[n,r]),o.state={selecting:!1},o.containerRef=D.createRef(),o}return kr(t,[{key:"componentDidMount",value:function(){this.props.selectable&&this._selectable()}},{key:"componentWillUnmount",value:function(){this._teardownSelectable()}},{key:"componentDidUpdate",value:function(r){!r.selectable&&this.props.selectable&&this._selectable(),r.selectable&&!this.props.selectable&&this._teardownSelectable()}},{key:"render",value:function(){var r=this.props,o=r.range,i=r.getNow,a=r.getters,s=r.date,l=r.components.dateCellWrapper,u=r.localizer,d=this.state,h=d.selecting,p=d.startIdx,m=d.endIdx,b=i();return Y.createElement("div",{className:"rbc-row-bg",ref:this.containerRef},o.map(function(v,y){var S=h&&y>=p&&y<=m,x=a.dayProp(v),C=x.className,k=x.style;return Y.createElement(l,{key:y,value:v,range:o},Y.createElement("div",{style:k,className:fr("rbc-day-bg",C,S&&"rbc-selected-cell",u.isSameDate(v,b)&&"rbc-today",s&&u.neq(s,v,"month")&&"rbc-off-range-bg")}))}))}},{key:"_selectable",value:function(){var r=this,o=this.containerRef.current,i=this._selector=new A_(this.props.container,{longPressThreshold:this.props.longPressThreshold}),a=function(l,u){if(!F0(o,l)&&!Gbe(o,l)){var d=zu(o),h=r.props,p=h.range,m=h.rtl;if(Hbe(d,l)){var b=M_(d,l.x,m,p.length);r._selectSlot({startIdx:b,endIdx:b,action:u,box:l})}}r._initial={},r.setState({selecting:!1})};i.on("selecting",function(s){var l=r.props,u=l.range,d=l.rtl,h=-1,p=-1;if(r.state.selecting||(Nn(r.props.onSelectStart,[s]),r._initial={x:s.x,y:s.y}),i.isSelected(o)){var m=zu(o),b=_be(r._initial,m,s,u.length,d);h=b.startIdx,p=b.endIdx}r.setState({selecting:!0,startIdx:h,endIdx:p})}),i.on("beforeSelect",function(s){if(r.props.selectable==="ignoreEvents")return!F0(r.containerRef.current,s)}),i.on("click",function(s){return a(s,"click")}),i.on("doubleClick",function(s){return a(s,"doubleClick")}),i.on("select",function(s){r._selectSlot(pn(pn({},r.state),{},{action:"select",bounds:s})),r._initial={},r.setState({selecting:!1}),Nn(r.props.onSelectEnd,[r.state])})}},{key:"_teardownSelectable",value:function(){this._selector&&(this._selector.teardown(),this._selector=null)}},{key:"_selectSlot",value:function(r){var o=r.endIdx,i=r.startIdx,a=r.action,s=r.bounds,l=r.box;o!==-1&&i!==-1&&this.props.onSelectSlot&&this.props.onSelectSlot({start:i,end:o,action:a,bounds:s,box:l,resourceId:this.props.resourceId})}}]),t}(Y.Component),ls={propTypes:{slotMetrics:pe.object.isRequired,selected:pe.object,isAllDay:pe.bool,accessors:pe.object.isRequired,localizer:pe.object.isRequired,components:pe.object.isRequired,getters:pe.object.isRequired,onSelect:pe.func,onDoubleClick:pe.func,onKeyPress:pe.func},defaultProps:{segments:[],selected:{}},renderEvent:function(t,n){var r=t.selected;t.isAllDay;var o=t.accessors,i=t.getters,a=t.onSelect,s=t.onDoubleClick,l=t.onKeyPress,u=t.localizer,d=t.slotMetrics,h=t.components,p=t.resizable,m=d.continuesPrior(n),b=d.continuesAfter(n);return Y.createElement(E_,{event:n,getters:i,localizer:u,accessors:o,components:h,onSelect:a,onDoubleClick:s,onKeyPress:l,continuesPrior:m,continuesAfter:b,slotStart:d.first,slotEnd:d.last,selected:BS(n,r),resizable:p})},renderSpan:function(t,n,r){var o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:" ",i=Math.abs(n)/t*100+"%";return Y.createElement("div",{key:r,className:"rbc-row-segment",style:{WebkitFlexBasis:i,flexBasis:i,maxWidth:i}},o)}},N_=function(e){bo(t,e);function t(){return Ir(this,t),yo(this,t,arguments)}return kr(t,[{key:"render",value:function(){var r=this,o=this.props,i=o.segments,a=o.slotMetrics.slots,s=o.className,l=1;return Y.createElement("div",{className:fr(s,"rbc-row")},i.reduce(function(u,d,h){var p=d.event,m=d.left,b=d.right,v=d.span,y="_lvl_"+h,S=m-l,x=ls.renderEvent(r.props,p);return S&&u.push(ls.renderSpan(a,S,"".concat(y,"_gap"))),u.push(ls.renderSpan(a,v,y,x)),l=b+1,u},[]))}}]),t}(Y.Component);N_.defaultProps=pn({},ls.defaultProps);function O_(e){var t=e.dateRange,n=e.unit,r=n===void 0?"day":n,o=e.localizer;return{first:t[0],last:o.add(t[t.length-1],1,r)}}function Kbe(e,t,n,r){var o=O_({dateRange:t,localizer:r}),i=o.first,a=o.last,s=r.diff(i,a,"day"),l=r.max(r.startOf(n.start(e),"day"),i),u=r.min(r.ceil(n.end(e),"day"),a),d=she(t,function(p){return r.isSameDate(p,l)}),h=r.diff(l,u,"day");return h=Math.min(h,s),h=Math.max(h-r.segmentOffset,1),{event:e,span:h,left:d+1,right:Math.max(d+h,1)}}function P_(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1/0,n,r,o,i=[],a=[];for(n=0;n<e.length;n++){for(o=e[n],r=0;r<i.length&&Xbe(o,i[r]);r++);r>=t?a.push(o):(i[r]||(i[r]=[])).push(o)}for(n=0;n<i.length;n++)i[n].sort(function(s,l){return s.left-l.left});return{levels:i,extra:a}}function Xm(e,t,n,r,o){var i={start:r.start(e),end:r.end(e)},a={start:t,end:n};return o.inEventRange({event:i,range:a})}function Xbe(e,t){return t.some(function(n){return n.left<=e.right&&n.right>=e.left})}function Jbe(e,t,n){var r=Zb(e),o=[],i=[];r.forEach(function(l){var u=t.start(l),d=t.end(l);n.daySpan(u,d)>1?o.push(l):i.push(l)});var a=o.sort(function(l,u){return vE(l,u,t,n)}),s=i.sort(function(l,u){return vE(l,u,t,n)});return[].concat(Zb(a),Zb(s))}function vE(e,t,n,r){var o={start:n.start(e),end:n.end(e),allDay:n.allDay(e)},i={start:n.start(t),end:n.end(t),allDay:n.allDay(t)};return r.sortEvents({evtA:o,evtB:i})}var j_=function(t,n){return t.left<=n&&t.right>=n},Xj=function(t,n){return t.filter(function(r){return j_(r,n)}).map(function(r){return r.event})},L_=function(e){bo(t,e);function t(){return Ir(this,t),yo(this,t,arguments)}return kr(t,[{key:"render",value:function(){for(var r=this.props,o=r.segments,i=r.slotMetrics.slots,a=P_(o).levels[0],s=1,l=1,u=[];s<=i;){var d="_lvl_"+s,h=a.filter(function(x){return j_(x,s)})[0]||{},p=h.event,m=h.left,b=h.right,v=h.span;if(!p){s++;continue}var y=Math.max(0,m-l);if(this.canRenderSlotEvent(m,v)){var S=ls.renderEvent(this.props,p);y&&u.push(ls.renderSpan(i,y,d+"_gap")),u.push(ls.renderSpan(i,v,d,S)),l=s=b+1}else y&&u.push(ls.renderSpan(i,y,d+"_gap")),u.push(ls.renderSpan(i,1,d,this.renderShowMore(o,s))),l=s+=1}return Y.createElement("div",{className:"rbc-row"},u)}},{key:"canRenderSlotEvent",value:function(r,o){var i=this.props.segments;return Km(r,r+o).every(function(a){var s=Xj(i,a).length;return s===1})}},{key:"renderShowMore",value:function(r,o){var i=this,a=this.props,s=a.localizer,l=a.slotMetrics,u=l.getEventsForSlot(o),d=Xj(r,o),h=d.length;return h?Y.createElement("button",{type:"button",key:"sm_"+o,className:fr("rbc-button-link","rbc-show-more"),onClick:function(m){return i.showMore(o,m)}},s.messages.showMore(h,d,u)):!1}},{key:"showMore",value:function(r,o){o.preventDefault(),o.stopPropagation(),this.props.onShowMore(r,o.target)}}]),t}(Y.Component);L_.defaultProps=pn({},ls.defaultProps);var Qbe=function(t){var n=t.children;return Y.createElement("div",{className:"rbc-row-content-scroll-container"},n)},e0e=function(t,n){return t.left<=n&&t.right>=n},t0e=function(t,n){return t[0].range===n[0].range&&t[0].events===n[0].events};function R_(){return r_(function(e){for(var t=e.range,n=e.events,r=e.maxRows,o=e.minRows,i=e.accessors,a=e.localizer,s=O_({dateRange:t,localizer:a}),l=s.first,u=s.last,d=n.map(function(v){return Kbe(v,t,i,a)}),h=P_(d,Math.max(r-1,1)),p=h.levels,m=h.extra,b=m.length>0?o-1:o;p.length<b;)p.push([]);return{first:l,last:u,levels:p,extra:m,range:t,slots:t.length,clone:function(y){var S=R_();return S(pn(pn({},e),y))},getDateForSlot:function(y){return t[y]},getSlotForDate:function(y){return t.find(function(S){return a.isSameDate(S,y)})},getEventsForSlot:function(y){return d.filter(function(S){return e0e(S,y)}).map(function(S){return S.event})},continuesPrior:function(y){return a.continuesPrior(i.start(y),l)},continuesAfter:function(y){var S=i.start(y),x=i.end(y);return a.continuesAfter(S,x,u)}}},t0e)}var H0=function(e){bo(t,e);function t(){var n;Ir(this,t);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return n=yo(this,t,[].concat(o)),n.handleSelectSlot=function(a){var s=n.props,l=s.range,u=s.onSelectSlot;u(l.slice(a.start,a.end+1),a)},n.handleShowMore=function(a,s){var l=n.props,u=l.range,d=l.onShowMore,h=n.slotMetrics(n.props),p=_ue(n.containerRef.current,".rbc-row-bg")[0],m;p&&(m=p.children[a-1]);var b=h.getEventsForSlot(a);d(b,u[a-1],m,a,s)},n.getContainer=function(){var a=n.props.container;return a?a():n.containerRef.current},n.renderHeadingCell=function(a,s){var l=n.props,u=l.renderHeader,d=l.getNow,h=l.localizer;return u({date:a,key:"header_".concat(s),className:fr("rbc-date-cell",h.isSameDate(a,d())&&"rbc-now")})},n.renderDummy=function(){var a=n.props,s=a.className,l=a.range,u=a.renderHeader,d=a.showAllEvents;return Y.createElement("div",{className:s,ref:n.containerRef},Y.createElement("div",{className:fr("rbc-row-content",d&&"rbc-row-content-scrollable")},u&&Y.createElement("div",{className:"rbc-row",ref:n.headingRowRef},l.map(n.renderHeadingCell)),Y.createElement("div",{className:"rbc-row",ref:n.eventRowRef},Y.createElement("div",{className:"rbc-row-segment"},Y.createElement("div",{className:"rbc-event"},Y.createElement("div",{className:"rbc-event-content"}," "))))))},n.containerRef=D.createRef(),n.headingRowRef=D.createRef(),n.eventRowRef=D.createRef(),n.slotMetrics=R_(),n}return kr(t,[{key:"getRowLimit",value:function(){var r,o=Xx(this.eventRowRef.current),i=(r=this.headingRowRef)!==null&&r!==void 0&&r.current?Xx(this.headingRowRef.current):0,a=Xx(this.containerRef.current)-i;return Math.max(Math.floor(a/o),1)}},{key:"render",value:function(){var r=this.props,o=r.date,i=r.rtl,a=r.range,s=r.className,l=r.selected,u=r.selectable,d=r.renderForMeasure,h=r.accessors,p=r.getters,m=r.components,b=r.getNow,v=r.renderHeader,y=r.onSelect,S=r.localizer,x=r.onSelectStart,C=r.onSelectEnd,k=r.onDoubleClick,M=r.onKeyPress,I=r.resourceId,O=r.longPressThreshold,R=r.isAllDay,L=r.resizable,B=r.showAllEvents;if(d)return this.renderDummy();var _=this.slotMetrics(this.props),H=_.levels,U=_.extra,G=B?Qbe:qs,K=m.weekWrapper,z={selected:l,accessors:h,getters:p,localizer:S,components:m,onSelect:y,onDoubleClick:k,onKeyPress:M,resourceId:I,slotMetrics:_,resizable:L};return Y.createElement("div",{className:s,role:"rowgroup",ref:this.containerRef},Y.createElement(qbe,{localizer:S,date:o,getNow:b,rtl:i,range:a,selectable:u,container:this.getContainer,getters:p,onSelectStart:x,onSelectEnd:C,onSelectSlot:this.handleSelectSlot,components:m,longPressThreshold:O,resourceId:I}),Y.createElement("div",{className:fr("rbc-row-content",B&&"rbc-row-content-scrollable"),role:"row"},v&&Y.createElement("div",{className:"rbc-row ",ref:this.headingRowRef},a.map(this.renderHeadingCell)),Y.createElement(G,null,Y.createElement(K,Object.assign({isAllDay:R},z,{rtl:this.props.rtl}),H.map(function(ne,J){return Y.createElement(N_,Object.assign({key:J,segments:ne},z))}),!!U.length&&Y.createElement(L_,Object.assign({segments:U,onShowMore:this.handleShowMore},z))))))}}]),t}(Y.Component);H0.defaultProps={minRows:0,maxRows:1/0};var F_=function(t){var n=t.label;return Y.createElement("span",{role:"columnheader","aria-sort":"none"},n)},n0e=function(t){var n=t.label,r=t.drilldownView,o=t.onDrillDown;return r?Y.createElement("button",{type:"button",className:"rbc-button-link",onClick:o,role:"cell"},n):Y.createElement("span",null,n)},r0e=["date","className"],o0e=function(t,n,r,o,i){return t.filter(function(a){return Xm(a,n,r,o,i)})},YS=function(e){bo(t,e);function t(){var n;Ir(this,t);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return n=yo(this,t,[].concat(o)),n.getContainer=function(){return n.containerRef.current},n.renderWeek=function(a,s){var l=n.props,u=l.events,d=l.components,h=l.selectable,p=l.getNow,m=l.selected,b=l.date,v=l.localizer,y=l.longPressThreshold,S=l.accessors,x=l.getters,C=l.showAllEvents,k=n.state,M=k.needLimitMeasure,I=k.rowLimit,O=o0e(Zb(u),a[0],a[a.length-1],S,v),R=Jbe(O,S,v);return Y.createElement(H0,{key:s,ref:s===0?n.slotRowRef:void 0,container:n.getContainer,className:"rbc-month-row",getNow:p,date:b,range:a,events:R,maxRows:C?1/0:I,selected:m,selectable:h,components:d,accessors:S,getters:x,localizer:v,renderHeader:n.readerDateHeading,renderForMeasure:M,onShowMore:n.handleShowMore,onSelect:n.handleSelectEvent,onDoubleClick:n.handleDoubleClickEvent,onKeyPress:n.handleKeyPressEvent,onSelectSlot:n.handleSelectSlot,longPressThreshold:y,rtl:n.props.rtl,resizable:n.props.resizable,showAllEvents:C})},n.readerDateHeading=function(a){var s=a.date,l=a.className,u=Ss(a,r0e),d=n.props,h=d.date,p=d.getDrilldownView,m=d.localizer,b=m.neq(s,h,"month"),v=m.isSameDate(s,h),y=p(s),S=m.format(s,"dateFormat"),x=n.props.components.dateHeader||n0e;return Y.createElement("div",Object.assign({},u,{className:fr(l,b&&"rbc-off-range",v&&"rbc-current"),role:"cell"}),Y.createElement(x,{label:S,date:s,drilldownView:y,isOffRange:b,onDrillDown:function(k){return n.handleHeadingClick(s,y,k)}}))},n.handleSelectSlot=function(a,s){n._pendingSelection=n._pendingSelection.concat(a),clearTimeout(n._selectTimer),n._selectTimer=setTimeout(function(){return n.selectDates(s)})},n.handleHeadingClick=function(a,s,l){l.preventDefault(),n.clearSelection(),Nn(n.props.onDrillDown,[a,s])},n.handleSelectEvent=function(){n.clearSelection();for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];Nn(n.props.onSelectEvent,s)},n.handleDoubleClickEvent=function(){n.clearSelection();for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];Nn(n.props.onDoubleClickEvent,s)},n.handleKeyPressEvent=function(){n.clearSelection();for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];Nn(n.props.onKeyPressEvent,s)},n.handleShowMore=function(a,s,l,u,d){var h=n.props,p=h.popup,m=h.onDrillDown,b=h.onShowMore,v=h.getDrilldownView,y=h.doShowMoreDrillDown;if(n.clearSelection(),p){var S=V7(l,n.containerRef.current);n.setState({overlay:{date:s,events:a,position:S,target:d}})}else y&&Nn(m,[s,v(s)||po.DAY]);Nn(b,[a,s,u])},n.overlayDisplay=function(){n.setState({overlay:null})},n.state={rowLimit:5,needLimitMeasure:!0,date:null},n.containerRef=D.createRef(),n.slotRowRef=D.createRef(),n._bgRows=[],n._pendingSelection=[],n}return kr(t,[{key:"componentDidMount",value:function(){var r=this,o;this.state.needLimitMeasure&&this.measureRowLimit(this.props),window.addEventListener("resize",this._resizeListener=function(){o||W7(function(){o=!1,r.setState({needLimitMeasure:!0})})},!1)}},{key:"componentDidUpdate",value:function(){this.state.needLimitMeasure&&this.measureRowLimit(this.props)}},{key:"componentWillUnmount",value:function(){window.removeEventListener("resize",this._resizeListener,!1)}},{key:"render",value:function(){var r=this.props,o=r.date,i=r.localizer,a=r.className,s=i.visibleDays(o,i),l=xue(s,7);return this._weekCount=l.length,Y.createElement("div",{className:fr("rbc-month-view",a),role:"table","aria-label":"Month View",ref:this.containerRef},Y.createElement("div",{className:"rbc-row rbc-month-header",role:"row"},this.renderHeaders(l[0])),l.map(this.renderWeek),this.props.popup&&this.renderOverlay())}},{key:"renderHeaders",value:function(r){var o=this.props,i=o.localizer,a=o.components,s=r[0],l=r[r.length-1],u=a.header||F_;return i.range(s,l,"day").map(function(d,h){return Y.createElement("div",{key:"header_"+h,className:"rbc-header"},Y.createElement(u,{date:d,localizer:i,label:i.format(d,"weekdayFormat")}))})}},{key:"renderOverlay",value:function(){var r,o,i=this,a=(r=(o=this.state)===null||o===void 0?void 0:o.overlay)!==null&&r!==void 0?r:{},s=this.props,l=s.accessors,u=s.localizer,d=s.components,h=s.getters,p=s.selected,m=s.popupOffset,b=s.handleDragStart,v=function(){return i.setState({overlay:null})};return Y.createElement(YD,{overlay:a,accessors:l,localizer:u,components:d,getters:h,selected:p,popupOffset:m,ref:this.containerRef,handleKeyPressEvent:this.handleKeyPressEvent,handleSelectEvent:this.handleSelectEvent,handleDoubleClickEvent:this.handleDoubleClickEvent,handleDragStart:b,show:!!a.position,overlayDisplay:this.overlayDisplay,onHide:v})}},{key:"measureRowLimit",value:function(){this.setState({needLimitMeasure:!1,rowLimit:this.slotRowRef.current.getRowLimit()})}},{key:"selectDates",value:function(r){var o=this._pendingSelection.slice();this._pendingSelection=[],o.sort(function(s,l){return+s-+l});var i=new Date(o[0]),a=new Date(o[o.length-1]);a.setDate(o[o.length-1].getDate()+1),Nn(this.props.onSelectSlot,{slots:o,start:i,end:a,action:r.action,bounds:r.bounds,box:r.box})}},{key:"clearSelection",value:function(){clearTimeout(this._selectTimer),this._pendingSelection=[]}}],[{key:"getDerivedStateFromProps",value:function(r,o){var i=r.date,a=r.localizer;return{date:i,needLimitMeasure:a.neq(i,o.date,"month")}}}]),t}(Y.Component);YS.range=function(e,t){var n=t.localizer,r=n.firstVisibleDay(e,n),o=n.lastVisibleDay(e,n);return{start:r,end:o}};YS.navigate=function(e,t,n){var r=n.localizer;switch(t){case Wo.PREVIOUS:return r.add(e,-1,"month");case Wo.NEXT:return r.add(e,1,"month");default:return e}};YS.title=function(e,t){var n=t.localizer;return n.format(e,"monthHeaderFormat")};var Jj=function(t){var n=t.min,r=t.max,o=t.step,i=t.slots,a=t.localizer;return"".concat(+a.startOf(n,"minutes"))+"".concat(+a.startOf(r,"minutes"))+"".concat(o,"-").concat(i)};function UD(e){for(var t=e.min,n=e.max,r=e.step,o=e.timeslots,i=e.localizer,a=Jj({start:t,end:n,step:r,timeslots:o,localizer:i}),s=1+i.getTotalMin(t,n),l=i.getMinutesFromMidnight(t),u=Math.ceil((s-1)/(r*o)),d=u*o,h=new Array(u),p=new Array(d),m=0;m<u;m++){h[m]=new Array(o);for(var b=0;b<o;b++){var v=m*o+b,y=v*r;p[v]=h[m][b]=i.getSlotDate(t,l,y)}}var S=p.length*r;p.push(i.getSlotDate(t,l,S));function x(C){var k=i.diff(t,C,"minutes")+i.getDstOffset(t,C);return Math.min(k,s)}return{groups:h,update:function(k){return Jj(k)!==a?UD(k):this},dateIsInGroup:function(k,M){var I=h[M+1];return i.inRange(k,h[M][0],I?I[0]:n,"minutes")},nextSlot:function(k){var M=p[Math.min(p.indexOf(k)+1,p.length-1)];return M===k&&(M=i.add(k,r,"minutes")),M},closestSlotToPosition:function(k){var M=Math.min(p.length-1,Math.max(0,Math.floor(k*d)));return p[M]},closestSlotFromPoint:function(k,M){var I=Math.abs(M.top-M.bottom);return this.closestSlotToPosition((k.y-M.top)/I)},closestSlotFromDate:function(k){var M=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;if(i.lt(k,t,"minutes"))return p[0];if(i.gt(k,n,"minutes"))return p[p.length-1];var I=i.diff(t,k,"minutes");return p[(I-I%r)/r+M]},startsBeforeDay:function(k){return i.lt(k,t,"day")},startsAfterDay:function(k){return i.gt(k,n,"day")},startsBefore:function(k){return i.lt(i.merge(t,k),t,"minutes")},startsAfter:function(k){return i.gt(i.merge(n,k),n,"minutes")},getRange:function(k,M,I,O){I||(k=i.min(n,i.max(t,k))),O||(M=i.min(n,i.max(t,M)));var R=x(k),L=x(M),B=L>r*d&&!i.eq(n,M)?(R-r)/(r*d)*100:R/(r*d)*100;return{top:B,height:L/(r*d)*100-B,start:x(k),startDate:k,end:x(M),endDate:M}},getCurrentTimePosition:function(k){var M=x(k),I=M/(r*d)*100;return I}}}var i0e=function(){function e(t,n){var r=n.accessors,o=n.slotMetrics;Ir(this,e);var i=o.getRange(r.start(t),r.end(t)),a=i.start,s=i.startDate,l=i.end,u=i.endDate,d=i.top,h=i.height;this.start=a,this.end=l,this.startMs=+s,this.endMs=+u,this.top=d,this.height=h,this.data=t}return kr(e,[{key:"_width",get:function(){if(this.rows){var n=this.rows.reduce(function(o,i){return Math.max(o,i.leaves.length+1)},0)+1;return 100/n}if(this.leaves){var r=100-this.container._width;return r/(this.leaves.length+1)}return this.row._width}},{key:"width",get:function(){var n=this._width,r=Math.min(100,this._width*1.7);if(this.rows)return r;if(this.leaves)return this.leaves.length>0?r:n;var o=this.row.leaves,i=o.indexOf(this);return i===o.length-1?n:r}},{key:"xOffset",get:function(){if(this.rows)return 0;if(this.leaves)return this.container._width;var n=this.row,r=n.leaves,o=n.xOffset,i=n._width,a=r.indexOf(this)+1;return o+a*i}}]),e}();function a0e(e,t,n){return Math.abs(t.start-e.start)<n||t.start>e.start&&t.start<e.end}function s0e(e){for(var t=FS(e,["startMs",function(s){return-s.endMs}]),n=[];t.length>0;){var r=t.shift();n.push(r);for(var o=0;o<t.length;o++){var i=t[o];if(!(r.endMs>i.startMs)){if(o>0){var a=t.splice(o,1)[0];n.push(a)}break}}}return n}function H_(e){for(var t=e.events,n=e.minimumStartDifference,r=e.slotMetrics,o=e.accessors,i=t.map(function(d){return new i0e(d,{slotMetrics:r,accessors:o})}),a=s0e(i),s=[],l=function(){var h=a[u],p=s.find(function(v){return v.end>h.start||Math.abs(h.start-v.start)<n});if(!p)return h.rows=[],s.push(h),1;h.container=p;for(var m=null,b=p.rows.length-1;!m&&b>=0;b--)a0e(p.rows[b],h,n)&&(m=p.rows[b]);m?(m.leaves.push(h),h.row=m):(h.leaves=[],p.rows.push(h))},u=0;u<a.length;u++)l();return a.map(function(d){return{event:d.data,style:{top:d.top,height:d.height,width:d.width,xOffset:Math.max(0,d.xOffset)}}})}function __(e,t,n){for(var r=0;r<e.friends.length;++r)if(!(n.indexOf(e.friends[r])>-1)){t=t>e.friends[r].idx?t:e.friends[r].idx,n.push(e.friends[r]);var o=__(e.friends[r],t,n);t=t>o?t:o}return t}function l0e(e){var t=e.events,n=e.minimumStartDifference,r=e.slotMetrics,o=e.accessors,i=H_({events:t,minimumStartDifference:n,slotMetrics:r,accessors:o});i.sort(function(K,z){return K=K.style,z=z.style,K.top!==z.top?K.top>z.top?1:-1:K.height!==z.height?K.top+K.height<z.top+z.height?1:-1:0});for(var a=0;a<i.length;++a)i[a].friends=[],delete i[a].style.left,delete i[a].style.left,delete i[a].idx,delete i[a].size;for(var s=0;s<i.length-1;++s)for(var l=i[s],u=l.style.top,d=l.style.top+l.style.height,h=s+1;h<i.length;++h){var p=i[h],m=p.style.top,b=p.style.top+p.style.height;(m>=u&&b<=d||b>u&&b<=d||m>=u&&m<d)&&(l.friends.push(p),p.friends.push(l))}for(var v=0;v<i.length;++v){for(var y=i[v],S=[],x=0;x<100;++x)S.push(1);for(var C=0;C<y.friends.length;++C)y.friends[C].idx!==void 0&&(S[y.friends[C].idx]=0);y.idx=S.indexOf(1)}for(var k=0;k<i.length;++k){var M=0;if(!i[k].size){var I=[],O=__(i[k],0,I);M=100/(O+1),i[k].size=M;for(var R=0;R<I.length;++R)I[R].size=M}}for(var L=0;L<i.length;++L){var B=i[L];B.style.left=B.idx*B.size;for(var _=0,H=0;H<B.friends.length;++H){var U=B.friends[H].idx;_=_>U?_:U}_<=B.idx&&(B.size=100-B.idx*B.size);var G=B.idx===0?0:3;B.style.width="calc(".concat(B.size,"% - ").concat(G,"px)"),B.style.height="calc(".concat(B.style.height,"% - 2px)"),B.style.xOffset="calc(".concat(B.style.left,"% + ").concat(G,"px)")}return i}var Qj={overlap:H_,"no-overlap":l0e};function c0e(e){return!!(e&&e.constructor&&e.call&&e.apply)}function u0e(e){e.events,e.minimumStartDifference,e.slotMetrics,e.accessors;var t=e.dayLayoutAlgorithm,n=t;return t in Qj&&(n=Qj[t]),c0e(n)?n.apply(this,arguments):[]}var B_=function(e){bo(t,e);function t(){return Ir(this,t),yo(this,t,arguments)}return kr(t,[{key:"render",value:function(){var r=this.props,o=r.renderSlot,i=r.resource,a=r.group,s=r.getters,l=r.components,u=l===void 0?{}:l,d=u.timeSlotWrapper,h=d===void 0?qs:d,p=s?s.slotGroupProp(a):{};return Y.createElement("div",Object.assign({className:"rbc-timeslot-group"},p),a.map(function(m,b){var v=s?s.slotProp(m,i):{};return Y.createElement(h,{key:b,value:m,resource:i},Y.createElement("div",Object.assign({},v,{className:fr("rbc-time-slot",v.className)}),o&&o(m,b)))}))}}]),t}(D.Component);function nb(e){return typeof e=="string"?e:e+"%"}function d0e(e){var t=e.style,n=e.className,r=e.event,o=e.accessors,i=e.rtl,a=e.selected,s=e.label,l=e.continuesPrior,u=e.continuesAfter,d=e.getters,h=e.onClick,p=e.onDoubleClick,m=e.isBackgroundEvent,b=e.onKeyPress,v=e.components,y=v.event,S=v.eventWrapper,x=o.title(r),C=o.tooltip(r),k=o.end(r),M=o.start(r),I=d.eventProp(r,M,k,a),O=[Y.createElement("div",{key:"1",className:"rbc-event-label"},s),Y.createElement("div",{key:"2",className:"rbc-event-content"},y?Y.createElement(y,{event:r,title:x}):x)],R=t.height,L=t.top,B=t.width,_=t.xOffset,H=pn(pn({},I.style),{},vu({top:nb(L),height:nb(R),width:nb(B)},i?"right":"left",nb(_)));return Y.createElement(S,Object.assign({type:"time"},e),Y.createElement("div",{role:"button",tabIndex:0,onClick:h,onDoubleClick:p,style:H,onKeyDown:b,title:C?(typeof s=="string"?s+": ":"")+C:void 0,className:fr(m?"rbc-background-event":"rbc-event",n,I.className,{"rbc-selected":a,"rbc-event-continues-earlier":l,"rbc-event-continues-later":u})},O))}var f0e=function(t){var n=t.children,r=t.className,o=t.style,i=t.innerRef;return Y.createElement("div",{className:r,style:o,ref:i},n)},h0e=Y.forwardRef(function(e,t){return Y.createElement(f0e,Object.assign({},e,{innerRef:t}))}),p0e=["dayProp"],m0e=["eventContainerWrapper"],Y_=function(e){bo(t,e);function t(){var n;Ir(this,t);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return n=yo(this,t,[].concat(o)),n.state={selecting:!1,timeIndicatorPosition:null},n.intervalTriggered=!1,n.renderEvents=function(a){var s=a.events,l=a.isBackgroundEvent,u=n.props,d=u.rtl,h=u.selected,p=u.accessors,m=u.localizer,b=u.getters,v=u.components,y=u.step,S=u.timeslots,x=u.dayLayoutAlgorithm,C=u.resizable,k=S7(n),M=k.slotMetrics,I=m.messages,O=u0e({events:s,accessors:p,slotMetrics:M,minimumStartDifference:Math.ceil(y*S/2),dayLayoutAlgorithm:x});return O.map(function(R,L){var B=R.event,_=R.style,H=p.end(B),U=p.start(B),G="eventTimeRangeFormat",K,z=M.startsBeforeDay(U),ne=M.startsAfterDay(H);z?G="eventTimeRangeEndFormat":ne&&(G="eventTimeRangeStartFormat"),z&&ne?K=I.allDay:K=m.format({start:U,end:H},G);var J=z||M.startsBefore(U),ee=ne||M.startsAfter(H);return Y.createElement(d0e,{style:_,event:B,label:K,key:"evt_"+L,getters:b,rtl:d,components:v,continuesPrior:J,continuesAfter:ee,accessors:p,resource:n.props.resource,selected:BS(B,h),onClick:function(q){return n._select(pn(pn(pn({},B),n.props.resource&&{sourceResource:n.props.resource}),l&&{isBackgroundEvent:!0}),q)},onDoubleClick:function(q){return n._doubleClick(B,q)},isBackgroundEvent:l,onKeyPress:function(q){return n._keyPress(B,q)},resizable:C})})},n._selectable=function(){var a=n.containerRef.current,s=n.props,l=s.longPressThreshold,u=s.localizer,d=n._selector=new A_(function(){return a},{longPressThreshold:l}),h=function(v){var y=n.props.onSelecting,S=n.state||{},x=p(v),C=x.startDate,k=x.endDate;y&&(u.eq(S.startDate,C,"minutes")&&u.eq(S.endDate,k,"minutes")||y({start:C,end:k,resourceId:n.props.resource})===!1)||(n.state.start!==x.start||n.state.end!==x.end||n.state.selecting!==x.selecting)&&n.setState(x)},p=function(v){var y=n.slotMetrics.closestSlotFromPoint(v,zu(a));n.state.selecting||(n._initialSlot=y);var S=n._initialSlot;u.lte(S,y)?y=n.slotMetrics.nextSlot(y):u.gt(S,y)&&(S=n.slotMetrics.nextSlot(S));var x=n.slotMetrics.getRange(u.min(S,y),u.max(S,y));return pn(pn({},x),{},{selecting:!0,top:"".concat(x.top,"%"),height:"".concat(x.height,"%")})},m=function(v,y){if(!F0(n.containerRef.current,v)){var S=p(v),x=S.startDate,C=S.endDate;n._selectSlot({startDate:x,endDate:C,action:y,box:v})}n.setState({selecting:!1})};d.on("selecting",h),d.on("selectStart",h),d.on("beforeSelect",function(b){if(n.props.selectable==="ignoreEvents")return!F0(n.containerRef.current,b)}),d.on("click",function(b){return m(b,"click")}),d.on("doubleClick",function(b){return m(b,"doubleClick")}),d.on("select",function(b){n.state.selecting&&(n._selectSlot(pn(pn({},n.state),{},{action:"select",bounds:b})),n.setState({selecting:!1}))}),d.on("reset",function(){n.state.selecting&&n.setState({selecting:!1})})},n._teardownSelectable=function(){n._selector&&(n._selector.teardown(),n._selector=null)},n._selectSlot=function(a){for(var s=a.startDate,l=a.endDate,u=a.action,d=a.bounds,h=a.box,p=s,m=[];n.props.localizer.lte(p,l);)m.push(p),p=new Date(+p+n.props.step*60*1e3);Nn(n.props.onSelectSlot,{slots:m,start:s,end:l,resourceId:n.props.resource,action:u,bounds:d,box:h})},n._select=function(){for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];Nn(n.props.onSelectEvent,s)},n._doubleClick=function(){for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];Nn(n.props.onDoubleClickEvent,s)},n._keyPress=function(){for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];Nn(n.props.onKeyPressEvent,s)},n.slotMetrics=UD(n.props),n.containerRef=D.createRef(),n}return kr(t,[{key:"componentDidMount",value:function(){this.props.selectable&&this._selectable(),this.props.isNow&&this.setTimeIndicatorPositionUpdateInterval()}},{key:"componentWillUnmount",value:function(){this._teardownSelectable(),this.clearTimeIndicatorInterval()}},{key:"componentDidUpdate",value:function(r,o){this.props.selectable&&!r.selectable&&this._selectable(),!this.props.selectable&&r.selectable&&this._teardownSelectable(),this.slotMetrics=this.slotMetrics.update(this.props);var i=this.props,a=i.getNow,s=i.isNow,l=i.localizer,u=i.date,d=i.min,h=i.max,p=l.neq(r.getNow(),a(),"minutes");if(r.isNow!==s||p){if(this.clearTimeIndicatorInterval(),s){var m=!p&&l.eq(r.date,u,"minutes")&&o.timeIndicatorPosition===this.state.timeIndicatorPosition;this.setTimeIndicatorPositionUpdateInterval(m)}}else s&&(l.neq(r.min,d,"minutes")||l.neq(r.max,h,"minutes"))&&this.positionTimeIndicator()}},{key:"setTimeIndicatorPositionUpdateInterval",value:function(){var r=this,o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;!this.intervalTriggered&&!o&&this.positionTimeIndicator(),this._timeIndicatorTimeout=window.setTimeout(function(){r.intervalTriggered=!0,r.positionTimeIndicator(),r.setTimeIndicatorPositionUpdateInterval()},6e4)}},{key:"clearTimeIndicatorInterval",value:function(){this.intervalTriggered=!1,window.clearTimeout(this._timeIndicatorTimeout)}},{key:"positionTimeIndicator",value:function(){var r=this.props,o=r.min,i=r.max,a=r.getNow,s=a();if(s>=o&&s<=i){var l=this.slotMetrics.getCurrentTimePosition(s);this.intervalTriggered=!0,this.setState({timeIndicatorPosition:l})}else this.clearTimeIndicatorInterval()}},{key:"render",value:function(){var r=this.props,o=r.date,i=r.max,a=r.rtl,s=r.isNow,l=r.resource,u=r.accessors,d=r.localizer,h=r.getters,p=h.dayProp,m=Ss(h,p0e),b=r.components,v=b.eventContainerWrapper,y=Ss(b,m0e),S=this.slotMetrics,x=this.state,C=x.selecting,k=x.top,M=x.height,I=x.startDate,O=x.endDate,R={start:I,end:O},L=p(i),B=L.className,_=L.style,H=y.dayColumnWrapper||h0e;return Y.createElement(H,{ref:this.containerRef,date:o,style:_,className:fr(B,"rbc-day-slot","rbc-time-column",s&&"rbc-now",s&&"rbc-today",C&&"rbc-slot-selecting"),slotMetrics:S},S.groups.map(function(U,G){return Y.createElement(B_,{key:G,group:U,resource:l,getters:m,components:y})}),Y.createElement(v,{localizer:d,resource:l,accessors:u,getters:m,components:y,slotMetrics:S},Y.createElement("div",{className:fr("rbc-events-container",a&&"rtl")},this.renderEvents({events:this.props.backgroundEvents,isBackgroundEvent:!0}),this.renderEvents({events:this.props.events}))),C&&Y.createElement("div",{className:"rbc-slot-selection",style:{top:k,height:M}},Y.createElement("span",null,d.format(R,"selectRangeFormat"))),s&&this.intervalTriggered&&Y.createElement("div",{className:"rbc-current-time-indicator",style:{top:"".concat(this.state.timeIndicatorPosition,"%")}}))}}]),t}(Y.Component);Y_.defaultProps={dragThroughEvents:!0,timeslots:2};function g0e(e){var t=e.min,n=e.max,r=e.localizer;return r.getTimezoneOffset(t)!==r.getTimezoneOffset(n)?{start:r.add(t,-1,"day"),end:r.add(n,-1,"day")}:{start:t,end:n}}var v0e=function(t){var n=t.min,r=t.max,o=t.timeslots,i=t.step,a=t.localizer,s=t.getNow,l=t.resource,u=t.components,d=t.getters,h=t.gutterRef,p=u.timeGutterWrapper,m=D.useMemo(function(){return g0e({min:n,max:r,localizer:a})},[n?.toISOString(),r?.toISOString(),a]),b=m.start,v=m.end,y=D.useState(UD({min:b,max:v,timeslots:o,step:i,localizer:a})),S=Xs(y,2),x=S[0],C=S[1];D.useEffect(function(){x&&C(x.update({min:b,max:v,timeslots:o,step:i,localizer:a}))},[b?.toISOString(),v?.toISOString(),o,i]);var k=D.useCallback(function(M,I){if(I)return null;var O=x.dateIsInGroup(s(),I);return Y.createElement("span",{className:fr("rbc-label",O&&"rbc-now")},a.format(M,"timeGutterFormat"))},[x,a,s]);return Y.createElement(p,{slotMetrics:x},Y.createElement("div",{className:"rbc-time-gutter rbc-time-column",ref:h},x.groups.map(function(M,I){return Y.createElement(B_,{key:I,group:M,resource:l,components:u,renderSlot:k,getters:d})})))},y0e=Y.forwardRef(function(e,t){return Y.createElement(v0e,Object.assign({gutterRef:t},e))}),b0e=function(t){var n=t.label;return Y.createElement(Y.Fragment,null,n)},w0e=function(e){bo(t,e);function t(){var n;Ir(this,t);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return n=yo(this,t,[].concat(o)),n.handleHeaderClick=function(a,s,l){l.preventDefault(),Nn(n.props.onDrillDown,[a,s])},n.renderRow=function(a){var s=n.props,l=s.events,u=s.rtl,d=s.selectable,h=s.getNow,p=s.range,m=s.getters,b=s.localizer,v=s.accessors,y=s.components,S=s.resizable,x=v.resourceId(a),C=a?l.filter(function(k){return v.resource(k)===x}):l;return Y.createElement(H0,{isAllDay:!0,rtl:u,getNow:h,minRows:2,maxRows:n.props.allDayMaxRows+1,range:p,events:C,resourceId:x,className:"rbc-allday-cell",selectable:d,selected:n.props.selected,components:y,accessors:v,getters:m,localizer:b,onSelect:n.props.onSelectEvent,onShowMore:n.props.onShowMore,onDoubleClick:n.props.onDoubleClickEvent,onKeyPress:n.props.onKeyPressEvent,onSelectSlot:n.props.onSelectSlot,longPressThreshold:n.props.longPressThreshold,resizable:S})},n}return kr(t,[{key:"renderHeaderCells",value:function(r){var o=this,i=this.props,a=i.localizer,s=i.getDrilldownView,l=i.getNow,u=i.getters.dayProp,d=i.components.header,h=d===void 0?F_:d,p=l();return r.map(function(m,b){var v=s(m),y=a.format(m,"dayFormat"),S=u(m),x=S.className,C=S.style,k=Y.createElement(h,{date:m,label:y,localizer:a});return Y.createElement("div",{key:b,style:C,className:fr("rbc-header",x,a.isSameDate(m,p)&&"rbc-today")},v?Y.createElement("button",{type:"button",className:"rbc-button-link",onClick:function(I){return o.handleHeaderClick(m,v,I)}},k):Y.createElement("span",null,k))})}},{key:"render",value:function(){var r=this,o=this.props,i=o.width,a=o.rtl,s=o.resources,l=o.range,u=o.events,d=o.getNow,h=o.accessors,p=o.selectable,m=o.components,b=o.getters,v=o.scrollRef,y=o.localizer,S=o.isOverflowing,x=o.components,C=x.timeGutterHeader,k=x.resourceHeader,M=k===void 0?b0e:k,I=o.resizable,O={};S&&(O[a?"marginLeft":"marginRight"]="".concat(G7()-1,"px"));var R=s.groupEvents(u);return Y.createElement("div",{style:O,ref:v,className:fr("rbc-time-header",S&&"rbc-overflowing")},Y.createElement("div",{className:"rbc-label rbc-time-header-gutter",style:{width:i,minWidth:i,maxWidth:i}},C&&Y.createElement(C,null)),s.map(function(L,B){var _=Xs(L,2),H=_[0],U=_[1];return Y.createElement("div",{className:"rbc-time-header-content",key:H||B},U&&Y.createElement("div",{className:"rbc-row rbc-row-resource",key:"resource_".concat(B)},Y.createElement("div",{className:"rbc-header"},Y.createElement(M,{index:B,label:h.resourceTitle(U),resource:U}))),Y.createElement("div",{className:"rbc-row rbc-time-header-cell".concat(l.length<=1?" rbc-time-header-cell-single-day":"")},r.renderHeaderCells(l)),Y.createElement(H0,{isAllDay:!0,rtl:a,getNow:d,minRows:2,maxRows:r.props.allDayMaxRows+1,range:l,events:R.get(H)||[],resourceId:U&&H,className:"rbc-allday-cell",selectable:p,selected:r.props.selected,components:m,accessors:h,getters:b,localizer:y,onSelect:r.props.onSelectEvent,onShowMore:r.props.onShowMore,onDoubleClick:r.props.onDoubleClickEvent,onKeyDown:r.props.onKeyPressEvent,onSelectSlot:r.props.onSelectSlot,longPressThreshold:r.props.longPressThreshold,resizable:I}))}))}}]),t}(Y.Component),eI={};function S0e(e,t){return{map:function(r){return e?e.map(function(o,i){return r([t.resourceId(o),o],i)}):[r([eI,null],0)]},groupEvents:function(r){var o=new Map;return e?(r.forEach(function(i){var a=t.resource(i)||eI;if(Array.isArray(a))a.forEach(function(l){var u=o.get(l)||[];u.push(i),o.set(l,u)});else{var s=o.get(a)||[];s.push(i),o.set(a,s)}}),o):(o.set(eI,r),o)}}}var Nh=function(e){bo(t,e);function t(n){var r;return Ir(this,t),r=yo(this,t,[n]),r.handleScroll=function(o){r.scrollRef.current&&(r.scrollRef.current.scrollLeft=o.target.scrollLeft)},r.handleResize=function(){gj(r.rafHandle),r.rafHandle=W7(r.checkOverflow)},r.handleKeyPressEvent=function(){r.clearSelection();for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];Nn(r.props.onKeyPressEvent,i)},r.handleSelectEvent=function(){r.clearSelection();for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];Nn(r.props.onSelectEvent,i)},r.handleDoubleClickEvent=function(){r.clearSelection();for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];Nn(r.props.onDoubleClickEvent,i)},r.handleShowMore=function(o,i,a,s,l){var u=r.props,d=u.popup,h=u.onDrillDown,p=u.onShowMore,m=u.getDrilldownView,b=u.doShowMoreDrillDown;if(r.clearSelection(),d){var v=V7(a,r.containerRef.current);r.setState({overlay:{date:i,events:o,position:pn(pn({},v),{},{width:"200px"}),target:l}})}else b&&Nn(h,[i,m(i)||po.DAY]);Nn(p,[o,i,s])},r.handleSelectAllDaySlot=function(o,i){var a=r.props.onSelectSlot,s=new Date(o[0]),l=new Date(o[o.length-1]);l.setDate(o[o.length-1].getDate()+1),Nn(a,{slots:o,start:s,end:l,action:i.action,resourceId:i.resourceId})},r.overlayDisplay=function(){r.setState({overlay:null})},r.checkOverflow=function(){if(!r._updatingOverflow){var o=r.contentRef.current;if(o!=null&&o.scrollHeight){var i=o.scrollHeight>o.clientHeight;r.state.isOverflowing!==i&&(r._updatingOverflow=!0,r.setState({isOverflowing:i},function(){r._updatingOverflow=!1}))}}},r.memoizedResources=r_(function(o,i){return S0e(o,i)}),r.state={gutterWidth:void 0,isOverflowing:null},r.scrollRef=Y.createRef(),r.contentRef=Y.createRef(),r.containerRef=Y.createRef(),r._scrollRatio=null,r.gutterRef=D.createRef(),r}return kr(t,[{key:"getSnapshotBeforeUpdate",value:function(){return this.checkOverflow(),null}},{key:"componentDidMount",value:function(){this.props.width==null&&this.measureGutter(),this.calculateScroll(),this.applyScroll(),window.addEventListener("resize",this.handleResize)}},{key:"componentWillUnmount",value:function(){window.removeEventListener("resize",this.handleResize),gj(this.rafHandle),this.measureGutterAnimationFrameRequest&&window.cancelAnimationFrame(this.measureGutterAnimationFrameRequest)}},{key:"componentDidUpdate",value:function(){this.applyScroll()}},{key:"renderEvents",value:function(r,o,i,a){var s=this,l=this.props,u=l.min,d=l.max,h=l.components,p=l.accessors,m=l.localizer,b=l.dayLayoutAlgorithm,v=this.memoizedResources(this.props.resources,p),y=v.groupEvents(o),S=v.groupEvents(i);return v.map(function(x,C){var k=Xs(x,2),M=k[0],I=k[1];return r.map(function(O,R){var L=(y.get(M)||[]).filter(function(_){return m.inRange(O,p.start(_),p.end(_),"day")}),B=(S.get(M)||[]).filter(function(_){return m.inRange(O,p.start(_),p.end(_),"day")});return Y.createElement(Y_,Object.assign({},s.props,{localizer:m,min:m.merge(O,u),max:m.merge(O,d),resource:I&&M,components:h,isNow:m.isSameDate(O,a),key:C+"-"+R,date:O,events:L,backgroundEvents:B,dayLayoutAlgorithm:b}))})})}},{key:"render",value:function(){var r,o=this.props,i=o.events,a=o.backgroundEvents,s=o.range,l=o.width,u=o.rtl,d=o.selected,h=o.getNow,p=o.resources,m=o.components,b=o.accessors,v=o.getters,y=o.localizer,S=o.min,x=o.max,C=o.showMultiDayTimes,k=o.longPressThreshold,M=o.resizable;l=l||this.state.gutterWidth;var I=s[0],O=s[s.length-1];this.slots=s.length;var R=[],L=[],B=[];return i.forEach(function(_){if(Xm(_,I,O,b,y)){var H=b.start(_),U=b.end(_);b.allDay(_)||y.startAndEndAreDateOnly(H,U)||!C&&!y.isSameDate(H,U)?R.push(_):L.push(_)}}),a.forEach(function(_){Xm(_,I,O,b,y)&&B.push(_)}),R.sort(function(_,H){return vE(_,H,b,y)}),Y.createElement("div",{className:fr("rbc-time-view",p&&"rbc-time-view-resources"),ref:this.containerRef},Y.createElement(w0e,{range:s,events:R,width:l,rtl:u,getNow:h,localizer:y,selected:d,allDayMaxRows:this.props.showAllEvents?1/0:(r=this.props.allDayMaxRows)!==null&&r!==void 0?r:1/0,resources:this.memoizedResources(p,b),selectable:this.props.selectable,accessors:b,getters:v,components:m,scrollRef:this.scrollRef,isOverflowing:this.state.isOverflowing,longPressThreshold:k,onSelectSlot:this.handleSelectAllDaySlot,onSelectEvent:this.handleSelectEvent,onShowMore:this.handleShowMore,onDoubleClickEvent:this.props.onDoubleClickEvent,onKeyPressEvent:this.props.onKeyPressEvent,onDrillDown:this.props.onDrillDown,getDrilldownView:this.props.getDrilldownView,resizable:M}),this.props.popup&&this.renderOverlay(),Y.createElement("div",{ref:this.contentRef,className:"rbc-time-content",onScroll:this.handleScroll},Y.createElement(y0e,{date:I,ref:this.gutterRef,localizer:y,min:y.merge(I,S),max:y.merge(I,x),step:this.props.step,getNow:this.props.getNow,timeslots:this.props.timeslots,components:m,className:"rbc-time-gutter",getters:v}),this.renderEvents(s,L,B,h())))}},{key:"renderOverlay",value:function(){var r,o,i=this,a=(r=(o=this.state)===null||o===void 0?void 0:o.overlay)!==null&&r!==void 0?r:{},s=this.props,l=s.accessors,u=s.localizer,d=s.components,h=s.getters,p=s.selected,m=s.popupOffset,b=s.handleDragStart,v=function(){return i.setState({overlay:null})};return Y.createElement(YD,{overlay:a,accessors:l,localizer:u,components:d,getters:h,selected:p,popupOffset:m,ref:this.containerRef,handleKeyPressEvent:this.handleKeyPressEvent,handleSelectEvent:this.handleSelectEvent,handleDoubleClickEvent:this.handleDoubleClickEvent,handleDragStart:b,show:!!a.position,overlayDisplay:this.overlayDisplay,onHide:v})}},{key:"clearSelection",value:function(){clearTimeout(this._selectTimer),this._pendingSelection=[]}},{key:"measureGutter",value:function(){var r=this;this.measureGutterAnimationFrameRequest&&window.cancelAnimationFrame(this.measureGutterAnimationFrameRequest),this.measureGutterAnimationFrameRequest=window.requestAnimationFrame(function(){var o,i=(o=r.gutterRef)!==null&&o!==void 0&&o.current?mE(r.gutterRef.current):void 0;i&&r.state.gutterWidth!==i&&r.setState({gutterWidth:i})})}},{key:"applyScroll",value:function(){if(this._scrollRatio!=null&&this.props.enableAutoScroll===!0){var r=this.contentRef.current;r.scrollTop=r.scrollHeight*this._scrollRatio,this._scrollRatio=null}}},{key:"calculateScroll",value:function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.props,o=r.min,i=r.max,a=r.scrollToTime,s=r.localizer,l=s.diff(s.merge(a,o),a,"milliseconds"),u=s.diff(o,i,"milliseconds");this._scrollRatio=l/u}}]),t}(D.Component);Nh.defaultProps={step:30,timeslots:2};var T0e=["date","localizer","min","max","scrollToTime","enableAutoScroll"],US=function(e){bo(t,e);function t(){return Ir(this,t),yo(this,t,arguments)}return kr(t,[{key:"render",value:function(){var r=this.props,o=r.date,i=r.localizer,a=r.min,s=a===void 0?i.startOf(new Date,"day"):a,l=r.max,u=l===void 0?i.endOf(new Date,"day"):l,d=r.scrollToTime,h=d===void 0?i.startOf(new Date,"day"):d,p=r.enableAutoScroll,m=p===void 0?!0:p,b=Ss(r,T0e),v=t.range(o,{localizer:i});return Y.createElement(Nh,Object.assign({},b,{range:v,eventOffset:10,localizer:i,min:s,max:u,scrollToTime:h,enableAutoScroll:m}))}}]),t}(Y.Component);US.range=function(e,t){var n=t.localizer;return[n.startOf(e,"day")]};US.navigate=function(e,t,n){var r=n.localizer;switch(t){case Wo.PREVIOUS:return r.add(e,-1,"day");case Wo.NEXT:return r.add(e,1,"day");default:return e}};US.title=function(e,t){var n=t.localizer;return n.format(e,"dayHeaderFormat")};var x0e=["date","localizer","min","max","scrollToTime","enableAutoScroll"],wc=function(e){bo(t,e);function t(){return Ir(this,t),yo(this,t,arguments)}return kr(t,[{key:"render",value:function(){var r=this.props,o=r.date,i=r.localizer,a=r.min,s=a===void 0?i.startOf(new Date,"day"):a,l=r.max,u=l===void 0?i.endOf(new Date,"day"):l,d=r.scrollToTime,h=d===void 0?i.startOf(new Date,"day"):d,p=r.enableAutoScroll,m=p===void 0?!0:p,b=Ss(r,x0e),v=t.range(o,this.props);return Y.createElement(Nh,Object.assign({},b,{range:v,eventOffset:15,localizer:i,min:s,max:u,scrollToTime:h,enableAutoScroll:m}))}}]),t}(Y.Component);wc.defaultProps=Nh.defaultProps;wc.navigate=function(e,t,n){var r=n.localizer;switch(t){case Wo.PREVIOUS:return r.add(e,-1,"week");case Wo.NEXT:return r.add(e,1,"week");default:return e}};wc.range=function(e,t){var n=t.localizer,r=n.startOfWeek(),o=n.startOf(e,"week",r),i=n.endOf(e,"week",r);return n.range(o,i)};wc.title=function(e,t){var n=t.localizer,r=wc.range(e,{localizer:n}),o=u_(r),i=o[0],a=o.slice(1);return n.format({start:i,end:a.pop()},"dayRangeHeaderFormat")};var I0e=["date","localizer","min","max","scrollToTime","enableAutoScroll"];function zD(e,t){return wc.range(e,t).filter(function(n){return[6,0].indexOf(n.getDay())===-1})}var mv=function(e){bo(t,e);function t(){return Ir(this,t),yo(this,t,arguments)}return kr(t,[{key:"render",value:function(){var r=this.props,o=r.date,i=r.localizer,a=r.min,s=a===void 0?i.startOf(new Date,"day"):a,l=r.max,u=l===void 0?i.endOf(new Date,"day"):l,d=r.scrollToTime,h=d===void 0?i.startOf(new Date,"day"):d,p=r.enableAutoScroll,m=p===void 0?!0:p,b=Ss(r,I0e),v=zD(o,this.props);return Y.createElement(Nh,Object.assign({},b,{range:v,eventOffset:15,localizer:i,min:s,max:u,scrollToTime:h,enableAutoScroll:m}))}}]),t}(Y.Component);mv.defaultProps=Nh.defaultProps;mv.range=zD;mv.navigate=wc.navigate;mv.title=function(e,t){var n=t.localizer,r=zD(e,{localizer:n}),o=u_(r),i=o[0],a=o.slice(1);return n.format({start:i,end:a.pop()},"dayRangeHeaderFormat")};function Sc(e){var t=e.accessors,n=e.components,r=e.date,o=e.events,i=e.getters,a=e.length,s=e.localizer,l=e.onDoubleClickEvent,u=e.onSelectEvent,d=e.selected,h=D.useRef(null),p=D.useRef(null),m=D.useRef(null),b=D.useRef(null),v=D.useRef(null);D.useEffect(function(){x()});var y=function(O,R,L){var B=n.event,_=n.date;return R=R.filter(function(H){return Xm(H,s.startOf(O,"day"),s.endOf(O,"day"),t,s)}),R.map(function(H,U){var G=t.title(H),K=t.end(H),z=t.start(H),ne=i.eventProp(H,z,K,BS(H,d)),J=U===0&&s.format(O,"agendaDateFormat"),ee=U===0?Y.createElement("td",{rowSpan:R.length,className:"rbc-agenda-date-cell"},_?Y.createElement(_,{day:O,label:J}):J):!1;return Y.createElement("tr",{key:L+"_"+U,className:ne.className,style:ne.style},ee,Y.createElement("td",{className:"rbc-agenda-time-cell"},S(O,H)),Y.createElement("td",{className:"rbc-agenda-event-cell",onClick:function(q){return u&&u(H,q)},onDoubleClick:function(q){return l&&l(H,q)}},B?Y.createElement(B,{event:H,title:G}):G))},[])},S=function(O,R){var L="",B=n.time,_=s.messages.allDay,H=t.end(R),U=t.start(R);return t.allDay(R)||(s.eq(U,H)?_=s.format(U,"agendaTimeFormat"):s.isSameDate(U,H)?_=s.format({start:U,end:H},"agendaTimeRangeFormat"):s.isSameDate(O,U)?_=s.format(U,"agendaTimeFormat"):s.isSameDate(O,H)&&(_=s.format(H,"agendaTimeFormat"))),s.gt(O,U,"day")&&(L="rbc-continues-prior"),s.lt(O,H,"day")&&(L+=" rbc-continues-after"),Y.createElement("span",{className:L.trim()},B?Y.createElement(B,{event:R,day:O,label:_}):_)},x=function(){if(v.current){var O=h.current,R=v.current.firstChild;if(R){var L=b.current.scrollHeight>b.current.clientHeight,B=[],_=B;B=[mE(R.children[0]),mE(R.children[1])],(_[0]!==B[0]||_[1]!==B[1])&&(p.current.style.width=B[0]+"px",m.current.style.width=B[1]+"px"),L?(ade(O,"rbc-header-overflowing"),O.style.marginRight=G7()+"px"):sde(O,"rbc-header-overflowing")}}},C=s.messages,k=s.add(r,a,"day"),M=s.range(r,k,"day");return o=o.filter(function(I){return Xm(I,s.startOf(r,"day"),s.endOf(k,"day"),t,s)}),o.sort(function(I,O){return+t.start(I)-+t.start(O)}),Y.createElement("div",{className:"rbc-agenda-view"},o.length!==0?Y.createElement(Y.Fragment,null,Y.createElement("table",{ref:h,className:"rbc-agenda-table"},Y.createElement("thead",null,Y.createElement("tr",null,Y.createElement("th",{className:"rbc-header",ref:p},C.date),Y.createElement("th",{className:"rbc-header",ref:m},C.time),Y.createElement("th",{className:"rbc-header"},C.event)))),Y.createElement("div",{className:"rbc-agenda-content",ref:b},Y.createElement("table",{className:"rbc-agenda-table"},Y.createElement("tbody",{ref:v},M.map(function(I,O){return y(I,o,O)}))))):Y.createElement("span",{className:"rbc-agenda-empty"},C.noEventsInRange))}Sc.defaultProps={length:30};Sc.range=function(e,t){var n=t.length,r=n===void 0?Sc.defaultProps.length:n,o=t.localizer,i=o.add(e,r,"day");return{start:e,end:i}};Sc.navigate=function(e,t,n){var r=n.length,o=r===void 0?Sc.defaultProps.length:r,i=n.localizer;switch(t){case Wo.PREVIOUS:return i.add(e,-o,"day");case Wo.NEXT:return i.add(e,o,"day");default:return e}};Sc.title=function(e,t){var n=t.length,r=n===void 0?Sc.defaultProps.length:n,o=t.localizer,i=o.add(e,r,"day");return o.format({start:e,end:i},"agendaHeaderFormat")};var qb=vu(vu(vu(vu(vu({},po.MONTH,YS),po.WEEK,wc),po.WORK_WEEK,mv),po.DAY,US),po.AGENDA,Sc),k0e=["action","date","today"];function E0e(e,t){var n=t.action,r=t.date,o=t.today,i=Ss(t,k0e);switch(e=typeof e=="string"?qb[e]:e,n){case Wo.TODAY:r=o||new Date;break;case Wo.DATE:break;default:Bm(e&&typeof e.navigate=="function","Calendar View components must implement a static `.navigate(date, action)` method.s"),r=e.navigate(r,n,i)}return r}var C0e=function(e){bo(t,e);function t(){var n;Ir(this,t);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return n=yo(this,t,[].concat(o)),n.navigate=function(a){n.props.onNavigate(a)},n.view=function(a){n.props.onView(a)},n}return kr(t,[{key:"render",value:function(){var r=this.props,o=r.localizer.messages,i=r.label;return Y.createElement("div",{className:"rbc-toolbar"},Y.createElement("span",{className:"rbc-btn-group"},Y.createElement("button",{type:"button",onClick:this.navigate.bind(null,Wo.TODAY)},o.today),Y.createElement("button",{type:"button",onClick:this.navigate.bind(null,Wo.PREVIOUS)},o.previous),Y.createElement("button",{type:"button",onClick:this.navigate.bind(null,Wo.NEXT)},o.next)),Y.createElement("span",{className:"rbc-toolbar-label"},i),Y.createElement("span",{className:"rbc-btn-group"},this.viewNamesGroup(o)))}},{key:"viewNamesGroup",value:function(r){var o=this,i=this.props.views,a=this.props.view;if(i.length>1)return i.map(function(s){return Y.createElement("button",{type:"button",key:s,className:fr({"rbc-active":a===s}),onClick:o.view.bind(null,s)},r[s])})}}]),t}(Y.Component);function M0e(e,t){var n=null;return typeof t=="function"?n=t(e):typeof t=="string"&&ml(e)==="object"&&e!=null&&t in e&&(n=e[t]),n}var tc=function(t){return function(n){return M0e(n,t)}},D0e=["view","date","getNow","onNavigate"],A0e=["view","toolbar","events","backgroundEvents","style","className","elementProps","date","getNow","length","showMultiDayTimes","onShowMore","doShowMoreDrillDown","components","formats","messages","culture"];function U_(e){if(Array.isArray(e))return e;for(var t=[],n=0,r=Object.entries(e);n<r.length;n++){var o=Xs(r[n],2),i=o[0],a=o[1];a&&t.push(i)}return t}function N0e(e,t){var n=t.views,r=U_(n);return r.indexOf(e)!==-1}var z_=function(e){bo(t,e);function t(){var n;Ir(this,t);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return n=yo(this,t,[].concat(o)),n.getViews=function(){var a=n.props.views;return Array.isArray(a)?rbe(a,function(s,l){return s[l]=qb[l]},{}):ml(a)==="object"?x_(a,function(s,l){return s===!0?qb[l]:s}):qb},n.getView=function(){var a=n.getViews();return a[n.props.view]},n.getDrilldownView=function(a){var s=n.props,l=s.view,u=s.drilldownView,d=s.getDrilldownView;return d?d(a,l,Object.keys(n.getViews())):u},n.handleRangeChange=function(a,s,l){var u=n.props,d=u.onRangeChange,h=u.localizer;d&&s.range&&d(s.range(a,{localizer:h}),l)},n.handleNavigate=function(a,s){var l=n.props,u=l.view,d=l.date,h=l.getNow,p=l.onNavigate,m=Ss(l,D0e),b=n.getView(),v=h();d=E0e(b,pn(pn({},m),{},{action:a,date:s||d||v,today:v})),p(d,u,a),n.handleRangeChange(d,b)},n.handleViewChange=function(a){a!==n.props.view&&N0e(a,n.props)&&n.props.onView(a);var s=n.getViews();n.handleRangeChange(n.props.date||n.props.getNow(),s[a],a)},n.handleSelectEvent=function(){for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];Nn(n.props.onSelectEvent,s)},n.handleDoubleClickEvent=function(){for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];Nn(n.props.onDoubleClickEvent,s)},n.handleKeyPressEvent=function(){for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];Nn(n.props.onKeyPressEvent,s)},n.handleSelectSlot=function(a){Nn(n.props.onSelectSlot,a)},n.handleDrillDown=function(a,s){var l=n.props.onDrillDown;if(l){l(a,s,n.drilldownView);return}s&&n.handleViewChange(s),n.handleNavigate(Wo.DATE,a)},n.state={context:t.getContext(n.props)},n}return kr(t,[{key:"render",value:function(){var r=this.props,o=r.view,i=r.toolbar,a=r.events,s=r.backgroundEvents,l=r.style,u=r.className,d=r.elementProps,h=r.date,p=r.getNow,m=r.length,b=r.showMultiDayTimes,v=r.onShowMore,y=r.doShowMoreDrillDown;r.components,r.formats,r.messages,r.culture;var S=Ss(r,A0e);h=h||p();var x=this.getView(),C=this.state.context,k=C.accessors,M=C.components,I=C.getters,O=C.localizer,R=C.viewNames,L=M.toolbar||C0e,B=x.title(h,{localizer:O,length:m});return Y.createElement("div",Object.assign({},d,{className:fr(u,"rbc-calendar",S.rtl&&"rbc-rtl"),style:l}),i&&Y.createElement(L,{date:h,view:o,views:R,label:B,onView:this.handleViewChange,onNavigate:this.handleNavigate,localizer:O}),Y.createElement(x,Object.assign({},S,{events:a,backgroundEvents:s,date:h,getNow:p,length:m,localizer:O,getters:I,components:M,accessors:k,showMultiDayTimes:b,getDrilldownView:this.getDrilldownView,onNavigate:this.handleNavigate,onDrillDown:this.handleDrillDown,onSelectEvent:this.handleSelectEvent,onDoubleClickEvent:this.handleDoubleClickEvent,onKeyPressEvent:this.handleKeyPressEvent,onSelectSlot:this.handleSelectSlot,onShowMore:v,doShowMoreDrillDown:y})))}}],[{key:"getDerivedStateFromProps",value:function(r){return{context:t.getContext(r)}}},{key:"getContext",value:function(r){var o=r.startAccessor,i=r.endAccessor,a=r.allDayAccessor,s=r.tooltipAccessor,l=r.titleAccessor,u=r.resourceAccessor,d=r.resourceIdAccessor,h=r.resourceTitleAccessor,p=r.eventPropGetter,m=r.backgroundEventPropGetter,b=r.slotPropGetter,v=r.slotGroupPropGetter,y=r.dayPropGetter,S=r.view,x=r.views,C=r.localizer,k=r.culture,M=r.messages,I=M===void 0?{}:M,O=r.components,R=O===void 0?{}:O,L=r.formats,B=L===void 0?{}:L,_=U_(x),H=Lbe(I);return{viewNames:_,localizer:Pbe(C,k,B,H),getters:{eventProp:function(){return p&&p.apply(void 0,arguments)||{}},backgroundEventProp:function(){return m&&m.apply(void 0,arguments)||{}},slotProp:function(){return b&&b.apply(void 0,arguments)||{}},slotGroupProp:function(){return v&&v.apply(void 0,arguments)||{}},dayProp:function(){return y&&y.apply(void 0,arguments)||{}}},components:Vye(R[S]||{},Rye(R,_),{eventWrapper:qs,backgroundEventWrapper:qs,eventContainerWrapper:qs,dateCellWrapper:qs,weekWrapper:qs,timeSlotWrapper:qs,timeGutterWrapper:qs}),accessors:{start:tc(o),end:tc(i),allDay:tc(a),tooltip:tc(s),title:tc(l),resource:tc(u),resourceId:tc(d),resourceTitle:tc(h)}}}}]),t}(Y.Component);z_.defaultProps={events:[],backgroundEvents:[],elementProps:{},popup:!1,toolbar:!0,view:po.MONTH,views:[po.MONTH,po.WEEK,po.DAY,po.AGENDA],step:30,length:30,allDayMaxRows:1/0,doShowMoreDrillDown:!0,drilldownView:po.DAY,titleAccessor:"title",tooltipAccessor:"title",allDayAccessor:"allDay",startAccessor:"start",endAccessor:"end",resourceAccessor:"resourceId",resourceIdAccessor:"id",resourceTitleAccessor:"title",longPressThreshold:250,getNow:function(){return new Date},dayLayoutAlgorithm:"overlap"};var O0e=C7(z_,{view:"onView",date:"onNavigate",selected:"onSelectEvent"}),P0e=function(t,n,r){var o=t.start,i=t.end;return r.format(o,"MMMM DD",n)+" – "+r.format(i,r.eq(o,i,"month")?"DD":"MMMM DD",n)},j0e=function(t,n,r){var o=t.start,i=t.end;return r.format(o,"L",n)+" – "+r.format(i,"L",n)},tI=function(t,n,r){var o=t.start,i=t.end;return r.format(o,"LT",n)+" – "+r.format(i,"LT",n)},L0e=function(t,n,r){var o=t.start;return r.format(o,"LT",n)+" – "},R0e=function(t,n,r){var o=t.end;return" – "+r.format(o,"LT",n)},F0e={dateFormat:"DD",dayFormat:"DD ddd",weekdayFormat:"ddd",selectRangeFormat:tI,eventTimeRangeFormat:tI,eventTimeRangeStartFormat:L0e,eventTimeRangeEndFormat:R0e,timeGutterFormat:"LT",monthHeaderFormat:"MMMM YYYY",dayHeaderFormat:"dddd MMM DD",dayRangeHeaderFormat:P0e,agendaHeaderFormat:j0e,agendaDateFormat:"ddd MMM DD",agendaTimeFormat:"LT",agendaTimeRangeFormat:tI};function nc(e){var t=e&&e.toLowerCase();return t==="FullYear"?t="year":t||(t=void 0),t}function H0e(e){var t=function($,re){return re?$.locale(re):$};function n(q){return e(q).toDate().getTimezoneOffset()}function r(q,$){var re,le,ie=e(q).local(),fe=e($).local();if(!e.tz)return ie.toDate().getTimezoneOffset()-fe.toDate().getTimezoneOffset();var ye=(re=ie==null||(le=ie._z)===null||le===void 0?void 0:le.name)!==null&&re!==void 0?re:e.tz.guess(),ge=e.tz.zone(ye).utcOffset(+ie),me=e.tz.zone(ye).utcOffset(+fe);return ge-me}function o(q){var $=e(q).startOf("day");return r($,q)}function i(q,$,re){var le=nc(re),ie=le?e(q).startOf(le):e(q),fe=le?e($).startOf(le):e($);return[ie,fe,le]}function a(){var q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null,$=arguments.length>1?arguments[1]:void 0,re=nc($);return re?e(q).startOf(re).toDate():e(q).toDate()}function s(){var q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null,$=arguments.length>1?arguments[1]:void 0,re=nc($);return re?e(q).endOf(re).toDate():e(q).toDate()}function l(q,$,re){var le=i(q,$,re),ie=Xs(le,3),fe=ie[0],ye=ie[1],ge=ie[2];return fe.isSame(ye,ge)}function u(q,$,re){return!l(q,$,re)}function d(q,$,re){var le=i(q,$,re),ie=Xs(le,3),fe=ie[0],ye=ie[1],ge=ie[2];return fe.isAfter(ye,ge)}function h(q,$,re){var le=i(q,$,re),ie=Xs(le,3),fe=ie[0],ye=ie[1],ge=ie[2];return fe.isBefore(ye,ge)}function p(q,$,re){var le=i(q,$,re),ie=Xs(le,3),fe=ie[0],ye=ie[1],ge=ie[2];return fe.isSameOrBefore(ye,ge)}function m(q,$,re){var le=i(q,$,re),ie=Xs(le,3),fe=ie[0],ye=ie[1],ge=ie[2];return fe.isSameOrBefore(ye,ge)}function b(q,$,re){var le=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"day",ie=nc(le),fe=e(q),ye=e($),ge=e(re);return fe.isBetween(ye,ge,ie,"[]")}function v(q,$){var re=e(q),le=e($),ie=e.min(re,le);return ie.toDate()}function y(q,$){var re=e(q),le=e($),ie=e.max(re,le);return ie.toDate()}function S(q,$){if(!q&&!$)return null;var re=e($).format("HH:mm:ss"),le=e(q).startOf("day").format("MM/DD/YYYY");return e("".concat(le," ").concat(re),"MM/DD/YYYY HH:mm:ss").toDate()}function x(q,$,re){var le=nc(re);return e(q).add($,le).toDate()}function C(q,$){for(var re=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"day",le=nc(re),ie=e(q).toDate(),fe=[];m(ie,$);)fe.push(ie),ie=x(ie,1,le);return fe}function k(q,$){var re=nc($),le=a(q,re);return l(le,q)?le:x(le,1,re)}function M(q,$){var re=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"day",le=nc(re),ie=e(q),fe=e($);return fe.diff(ie,le)}function I(q){var $=e(q);return $.minutes()}function O(q){var $=q?e.localeData(q):e.localeData();return $?$.firstDayOfWeek():0}function R(q){return e(q).startOf("month").startOf("week").toDate()}function L(q){return e(q).endOf("month").endOf("week").toDate()}function B(q){for(var $=R(q),re=L(q),le=[];m($,re);)le.push($),$=x($,1,"d");return le}function _(q,$,re){return e(q).startOf("day").minute($+re).toDate()}function H(q,$){return M(q,$,"minutes")}function U(q){var $=e(q).startOf("day"),re=e(q);return re.diff($,"minutes")+o(q)}function G(q,$){var re=e(q),le=e($);return re.isBefore(le,"day")}function K(q,$,re){var le=e($),ie=e(re);return le.isSameOrAfter(ie,"minutes")}function z(q,$){var re=e(q),le=e($),ie=e.duration(le.diff(re));return ie.days()}function ne(q){var $=q.evtA,re=$.start,le=$.end,ie=$.allDay,fe=q.evtB,ye=fe.start,ge=fe.end,me=fe.allDay,Ce=+a(re,"day")-+a(ye,"day"),je=z(re,le),Ie=z(ye,ge);return Ce||Ie-je||!!me-!!ie||+re-+ye||+le-+ge}function J(q){var $=q.event,re=$.start,le=$.end,ie=q.range,fe=ie.start,ye=ie.end,ge=e(re).startOf("day"),me=e(le),Ce=e(fe),je=e(ye),Ie=ge.isSameOrBefore(je,"day"),Fe=!ge.isSame(me,"minutes"),ce=Fe?me.isAfter(Ce,"minutes"):me.isSameOrAfter(Ce,"minutes");return Ie&&ce}function ee(q,$){var re=e(q),le=e($);return re.isSame(le,"day")}function Z(){var q=new Date,$=/-/.test(q.toString())?"-":"",re=q.getTimezoneOffset(),le=Number("".concat($).concat(Math.abs(re))),ie=e().utcOffset();return ie>le?1:0}return new Obe({formats:F0e,firstOfWeek:O,firstVisibleDay:R,lastVisibleDay:L,visibleDays:B,format:function($,re,le){return t(e($),le).format(re)},lt:h,lte:m,gt:d,gte:p,eq:l,neq:u,merge:S,inRange:b,startOf:a,endOf:s,range:C,add:x,diff:M,ceil:k,min:v,max:y,minutes:I,getSlotDate:_,getTimezoneOffset:n,getDstOffset:r,getTotalMin:H,getMinutesFromMidnight:U,continuesPrior:G,continuesAfter:K,sortEvents:ne,inEventRange:J,isSameDate:ee,daySpan:z,browserTZOffset:Z})}function e4(e,t,n,r,o){const i={start:r.start(e),end:r.end(e)},a={start:t,end:n};return o.inEventRange({event:i,range:a})}function _0e(e,t){return!e||t==null?!1:ws(e,t)}const rf={PREVIOUS:"PREV",NEXT:"NEXT",TODAY:"TODAY",DATE:"DATE"};function gl({accessors:e,components:t,date:n,events:r,getters:o,length:i,localizer:a,onDoubleClickEvent:s,onSelectEvent:l,selected:u}){D.useRef(null);const d=D.useRef(null),h=D.useRef(null),p=D.useRef(null),m=D.useRef(null),[b,v]=D.useState(!1),[y,S]=D.useState(!1),x=(B,_,H)=>{const{event:U,date:G}=t;return _=_.filter(K=>e4(K,a.startOf(B,"day"),a.endOf(B,"day"),e,a)),_.map((K,z)=>{const ne=e.title(K),J=e.end(K),ee=e.start(K),Z=o.eventProp(K,ee,J,_0e(K,u)),q=z===0&&a.format(B,"agendaDateFormat"),$=z===0?w.jsx("td",{rowSpan:_.length,className:"rbc-agenda-date-cell",children:G?w.jsx(G,{day:B,label:q}):q}):!1;return w.jsxs("tr",{className:Z.className,style:Z.style,children:[$,w.jsx("td",{className:"rbc-agenda-time-cell",children:C(B,K)}),w.jsx("td",{className:"rbc-agenda-event-cell",onClick:re=>l&&l(K,re),onDoubleClick:re=>s&&s(K,re),children:U?w.jsx(U,{event:K,title:ne}):ne})]},H+"_"+z)},[])},C=(B,_)=>{const H=t.time;let U="",G=a.messages.allDay;const K=e.end(_),z=e.start(_);return e.allDay(_)||(a.eq(z,K)?G=a.format(z,"agendaTimeFormat"):a.isSameDate(z,K)?G=a.format({start:z,end:K},"agendaTimeRangeFormat"):a.isSameDate(B,z)?G=a.format(z,"agendaTimeFormat"):a.isSameDate(B,K)&&(G=a.format(K,"agendaTimeFormat"))),a.gt(B,z,"day")&&(U="rbc-continues-prior"),a.lt(B,K,"day")&&(U+=" rbc-continues-after"),w.jsx("span",{className:U.trim(),children:H?w.jsx(H,{event:_,day:B,label:G}):G})},{messages:k}=a,M=a.add(n,-i/2,"day"),I=a.add(n,i/2,"day"),O=a.range(M,I,"day");b&&O.reverse(),r=r.filter(B=>e4(B,a.startOf(M,"day"),a.endOf(I,"day"),e,a)),r.sort((B,_)=>+e.start(B)-+e.start(_)),y&&r.reverse();const R=D.useCallback(()=>setTimeout(()=>{m.current&&ES(m.current,{backgroundColor:"#ffffff",pixelRatio:window.devicePixelRatio*2}).then(B=>{new N.Notice(E("Image is generating..."));const _=$e.getState().settings.AutoSaveWhenOnMobile,H=$e.getState().app.vault;if(_&&N.Platform.isMobile){const U=B.split("base64,")[1];dS(U,"image/png").arrayBuffer().then(async K=>{let z;const ne="png",J=Il();for(const ee in J)if(J[ee]instanceof N.TFile){z=J[ee];break}z!==void 0&&await H.createBinary(await H.getAvailablePathForAttachments(`Pasted Image ${N.moment().format("YYYYMMDDHHmmss")}`,ne,z),K)})}CS({imgUrl:B})}).catch(B=>{console.error(B)})},0),[m.current,O]),L=D.useCallback(B=>{const _=new N.Menu;_.addItem(H=>{H.setIcon("share-2").setTitle(E("Share")).onClick(()=>{R()})}),_.showAtMouseEvent(B.nativeEvent)},[m.current,O,R]);return w.jsx("div",{className:"rbc-agenda-view",children:r.length!==0?w.jsx(Y.Fragment,{children:w.jsxs("table",{ref:m,className:"rbc-agenda-table",children:[w.jsx("thead",{onContextMenu:L,children:w.jsxs("tr",{children:[w.jsx("th",{className:"rbc-header",ref:d,onClick:()=>{v(!b)},children:k.date+(b?" 🔼":" 🔽")}),w.jsx("th",{className:"rbc-header",ref:h,onClick:()=>{S(!y)},children:k.time+(y?" 🔼":" 🔽")}),w.jsx("th",{className:"rbc-header",children:k.event})]})}),w.jsx("tbody",{ref:p,children:O.map((B,_)=>x(B,r,_))})]})}):w.jsx("span",{className:"rbc-agenda-empty",children:k.noEventsInRange})})}gl.propTypes={accessors:pe.object.isRequired,components:pe.object.isRequired,date:pe.instanceOf(Date),events:pe.array,getters:pe.object.isRequired,length:pe.number.isRequired,localizer:pe.object.isRequired,onSelectEvent:pe.func,onDoubleClickEvent:pe.func,selected:pe.object};gl.defaultProps={length:30};gl.range=(e,{length:t=gl.defaultProps.length,localizer:n})=>{const r=n.add(e,-t/2,"day"),o=n.add(e,t/2,"day");return{customStart:r,customEnd:o}};gl.navigate=(e,t,{length:n=gl.defaultProps.length,localizer:r})=>{switch(t){case rf.PREVIOUS:return r.add(e,-n,"day");case rf.NEXT:return r.add(e,n,"day");default:return e}};gl.title=(e,{length:t=gl.defaultProps.length,localizer:n})=>{const r=n.add(e,-t/2,"day"),o=n.add(e,t/2,"day");return n.format({start:r,end:o},"agendaHeaderFormat")};function B0e(e,t){e.hoverEl.toggleClass("thino-hover-popover",!0);const n=tv(e.hoverEl);return n.render(w.jsx(zi,{store:ke,context:ct,children:w.jsx(vo,{memo:t})})),n}function Y0e({event:e}){const t=e.resource,n=t.content.split(`
|
|
|
`)[0].slice(0,20),r=Y.useRef(null),o=Y.useRef(null),i=Y.useRef(null);D.useEffect(()=>{if(o.current)return N.setIcon(o.current,"calendar"),()=>{r.current&&(r.current=null)}},[r]);const a=D.useCallback(l=>{i.current&&(i.current.unmount(),i.current=null),i.current=l},[]),s=D.useCallback(l=>{if(!r.current||!N.Keymap.isModifier(l.nativeEvent,"Mod"))return;const u=new N.HoverPopover($e.getState().view,r.current,100),d=B0e(u,t);a(d)},[r.current]);return w.jsxs("span",{className:"rbc-event-renderer","data-source-type":t.sourceType,"data-thino-type":t.thinoType,"data-thino-id":t.id,ref:r,"aria-label":t.path,onMouseOver:s,children:[w.jsx(U0e,{event:e}),w.jsx("span",{children:n})]})}const U0e=({event:e})=>{const t=Y.useRef(null),n=e.resource;D.useEffect(()=>{t.current&&N.setIcon(t.current,n.thinoType==="JOURNAL"?"calendar":n.thinoType==="TASK-TODO"?"square":"check-square")},[n?.thinoType,t]);const r=D.useCallback(async o=>{o.stopPropagation(),o.preventDefault(),await(async()=>{const a=await de.updateMemo(n.id,n.content,n.thinoType==="TASK-TODO"?"TASK-DONE":"TASK-TODO");a&&de.editMemo(a)})()},[n?.thinoType,n?.id,n?.content]);return w.jsx(w.Fragment,{children:w.jsxs("span",{className:"rbc-event-icon-group",children:[w.jsx("span",{className:"rbc-event-icon",ref:t,onClick:r}),w.jsx("span",{className:tn("rbc-event-time","thino-hidden"),children:w.jsx("span",{className:"rbc-event-time-text",children:N.moment(e.start).format("HH:mm")})})]})})};function V_({views:e,view:t,messages:n,onView:r}){return e.map(o=>w.jsx("button",{type:"button",className:tn({"rbc-active":t===o}),onClick:()=>r(o),children:n[o]},o))}V_.propTypes={messages:pe.object,onView:pe.func,view:pe.string,views:pe.array};function W_({date:e,label:t,localizer:{messages:n},onNavigate:r,onView:o,view:i,views:a}){const s={previous:D.useRef(null),today:D.useRef(null),next:D.useRef(null)};D.useEffect(()=>{s&&(N.setIcon(s.previous.current,"chevron-left"),N.setIcon(s.today.current,"dot"),N.setIcon(s.next.current,"chevron-right"))},[s]);const l=D.useMemo(()=>w.jsxs(w.Fragment,{children:[w.jsx("button",{ref:s.previous,type:"button",onClick:()=>r(rf.PREVIOUS),"aria-label":n.previous,children:"<"}),w.jsx("button",{ref:s.today,type:"button",onClick:()=>r(rf.TODAY),"aria-label":n.today,children:"•"}),w.jsx("button",{ref:s.next,type:"button",onClick:()=>r(rf.NEXT),"aria-label":n.next,children:">"})]}),[n]);return w.jsxs("div",{className:"rbc-toolbar",children:[w.jsx("span",{className:tn("rbc-btn-group","thino-view-custom-toolbar"),children:l}),w.jsx("span",{className:"rbc-toolbar-label",children:w.jsx(k0,{type:"text",handleValueChange:u=>{r(rf.DATE,N.moment(u,"YYYY-MM-DD").format("YYYY-MM-DDTHH:mm:ssZ"))},defaultText:t+(i==="week"?N.moment(e.valueOf(),"x").format(" [W]WW"):""),defaultValue:N.moment(e.valueOf(),"x").valueOf()})}),w.jsx("span",{className:"rbc-btn-group",children:w.jsx(V_,{view:i,views:a,messages:n,onView:o})})]})}W_.propTypes={date:pe.instanceOf(Date),label:pe.string,localizer:pe.object,messages:pe.object,onNavigate:pe.func,onView:pe.func,view:pe.string,views:pe.array};function z0e({event:e,children:t,showPopup:n,callRender:r,...o}){const i=D.useRef(null),a=D.useRef(null),s=D.useCallback(l=>{if(!l.isTrusted){r();return}a.current=l.nativeEvent.target,a.current&&(a.current.hasClass("rbc-event")||(a.current=a.current.closest(".rbc-event")),i.current!==null?(window.clearTimeout(i.current),i.current=null):i.current=window.setTimeout(()=>{n(e,a.current),i.current=null},250))},[e,n]);return w.jsx(w.Fragment,{children:w.jsx("div",{className:"rbc-event-wrapper","aria-describedby":"thino",onClick:s,children:t})})}const V0e=H0e(N.moment),W0e=({event:e})=>{const t=e.resource;return w.jsx(w.Fragment,{children:w.jsx(vo,{memo:t})})},G0e=e=>{const{thinos:t}=e,[n,r]=Y.useState([]),[o,i]=Y.useState(app?.loadLocalStorage("thino-calendar-view")||"month"),[a,s]=Y.useState(null),l=Y.useRef(null),u=Y.useRef(null),[d,h]=Y.useState(!1),p=D.useRef(null),[m,b]=D.useState(new Date);D.useEffect(()=>()=>{l.current&&(l.current=null),u.current&&(u.current=null),p.current&&(p.current=null)},[]),D.useEffect(()=>{const H=t.map(U=>{const G=N.moment(U.createdAt,"YYYY/MM/DD HH:mm:ss"),K=G.clone().add(1,"minute");return{title:U.content,start:new Date(G.format("YYYY-MM-DDTHH:mm:ss")),end:new Date(K.format("YYYY-MM-DDTHH:mm:ss")),resource:U}});r(H)},[t]),D.useEffect(()=>{app?.saveLocalStorage("thino-calendar-view",o)},[o]),D.useEffect(()=>{a&&d&&s(t.find(H=>H.id===a.id))},[t,a,d]),D.useEffect(()=>{a&&p.current.update()},[a]),p.current=kS(l.current,u.current,{placement:"bottom-start",modifiers:[{name:"offset",options:{offset:[0,4]}}]});const v=D.useCallback(()=>{p.current.update(),p.current.update()},[]),y=D.useCallback((H,U)=>{s(null),k(),p.current.state.elements.reference=U,s(H.resource),M()},[]),S=D.useCallback(()=>{k(),s(null)},[]),x=D.useCallback((H,U,G)=>{if(C(H),U==="week"||U==="day"){const K=l.current.find(".rbc-event-wrapper");if(l.current.closest(".memolist-wrapper"),K){K.children[0]?.click();return}else{setTimeout(()=>{l.current.find(".rbc-event-wrapper")?.children?.[0]?.click()},0);return}}},[]),C=D.useCallback(H=>{b(H)},[b]);iv(u,S);const k=D.useCallback(()=>{h(!1)},[h]),M=D.useCallback(()=>{p.current.update(),h(!0)},[h]),I=D.useCallback(H=>{const U=H.resource;Ze.setEditMemoId(U.id)},[]),O=D.useCallback(H=>{i(H)},[i]),{components:R,views:L,messages:B}=D.useMemo(()=>({components:{toolbar:W_,eventWrapper:H=>w.jsx(z0e,{...H,callRender:v,showPopup:y}),agenda:{event:W0e},event:Y0e},views:{month:!0,agenda:gl,week:!0,day:!0},messages:{month:E("Month"),day:E("Day"),next:E("Next"),previous:E("Previous"),today:E("Today"),agenda:E("Agenda"),week:E("Week"),yesterday:E("Yesterday"),tomorrow:E("Tomorrow"),noEventsInRange:E("No thinos in range"),date:E("date"),time:E("time"),event:E("event")}}),[]),_=D.useMemo(()=>({timeGutterFormat:(H,U,G)=>G.format(H,"HH:mm",U),agendaTimeRangeFormat:({start:H,end:U},G,K)=>K.format(H,"HH:mm",G)+" — "+K.format(U,"HH:mm",G),agendaHeaderFormat:({start:H,end:U},G,K)=>K.format(H,"YYYY-MM-DD")+" — "+K.format(U,"YYYY-MM-DD")}),[]);return w.jsxs("div",{ref:l,className:"calendar-view",children:[w.jsx(O0e,{date:m,messages:B,components:R,localizer:V0e,events:n,views:L,onView:O,onDoubleClickEvent:I,onNavigate:x,formats:_,defaultView:o,tooltipAccessor:null,startAccessor:"start",endAccessor:"end"}),w.jsx("div",{ref:u,style:p.current?.styles.popper,className:tn("thino-popup-container",d?"":"thino-hidden"),children:a&&w.jsx(vo,{memo:a})})]})};function dc(e,t){return typeof e=="function"?e(t):e}function pi(e,t){return n=>{t.setState(r=>({...r,[e]:dc(n,r[e])}))}}function _0(e){return e instanceof Function}function Z0e(e){return Array.isArray(e)&&e.every(t=>typeof t=="number")}function $0e(e,t){const n=[],r=o=>{o.forEach(i=>{n.push(i);const a=t(i);a!=null&&a.length&&r(a)})};return r(e),n}function ht(e,t,n){let r=[],o;return i=>{let a;n.key&&n.debug&&(a=Date.now());const s=e(i);if(!(s.length!==r.length||s.some((d,h)=>r[h]!==d)))return o;r=s;let u;if(n.key&&n.debug&&(u=Date.now()),o=t(...s),n==null||n.onChange==null||n.onChange(o),n.key&&n.debug&&n!=null&&n.debug()){const d=Math.round((Date.now()-a)*100)/100,p=Math.round((Date.now()-u)*100)/100/16,m=(b,v)=>{for(b=String(b);b.length<v;)b=" "+b;return b}}return o}}function pt(e,t,n,r){return{debug:()=>{var o;return(o=e?.debugAll)!=null?o:e[t]},key:!1,onChange:r}}function q0e(e,t,n,r){var o,i;const s={...e._getDefaultColumnDef(),...t},l=s.accessorKey;let u=(o=(i=s.id)!=null?i:l?l.replace(".","_"):void 0)!=null?o:typeof s.header=="string"?s.header:void 0,d;if(s.accessorFn?d=s.accessorFn:l&&(l.includes(".")?d=p=>{let m=p;for(const v of l.split(".")){var b;m=(b=m)==null?void 0:b[v]}return m}:d=p=>p[s.accessorKey]),!u)throw new Error;let h={id:`${String(u)}`,accessorFn:d,parent:r,depth:n,columnDef:s,columns:[],getFlatColumns:ht(()=>[!0],()=>{var p;return[h,...(p=h.columns)==null?void 0:p.flatMap(m=>m.getFlatColumns())]},pt(e.options,"debugColumns")),getLeafColumns:ht(()=>[e._getOrderColumnsFn()],p=>{var m;if((m=h.columns)!=null&&m.length){let b=h.columns.flatMap(v=>v.getLeafColumns());return p(b)}return[h]},pt(e.options,"debugColumns"))};for(const p of e._features)p.createColumn==null||p.createColumn(h,e);return h}const Xr="debugHeaders";function t4(e,t,n){var r;let i={id:(r=n.id)!=null?r:t.id,column:t,index:n.index,isPlaceholder:!!n.isPlaceholder,placeholderId:n.placeholderId,depth:n.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const a=[],s=l=>{l.subHeaders&&l.subHeaders.length&&l.subHeaders.map(s),a.push(l)};return s(i),a},getContext:()=>({table:e,header:i,column:t})};return e._features.forEach(a=>{a.createHeader==null||a.createHeader(i,e)}),i}const K0e={createTable:e=>{e.getHeaderGroups=ht(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r,o)=>{var i,a;const s=(i=r?.map(h=>n.find(p=>p.id===h)).filter(Boolean))!=null?i:[],l=(a=o?.map(h=>n.find(p=>p.id===h)).filter(Boolean))!=null?a:[],u=n.filter(h=>!(r!=null&&r.includes(h.id))&&!(o!=null&&o.includes(h.id)));return rb(t,[...s,...u,...l],e)},pt(e.options,Xr)),e.getCenterHeaderGroups=ht(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r,o)=>(n=n.filter(i=>!(r!=null&&r.includes(i.id))&&!(o!=null&&o.includes(i.id))),rb(t,n,e,"center")),pt(e.options,Xr)),e.getLeftHeaderGroups=ht(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left],(t,n,r)=>{var o;const i=(o=r?.map(a=>n.find(s=>s.id===a)).filter(Boolean))!=null?o:[];return rb(t,i,e,"left")},pt(e.options,Xr)),e.getRightHeaderGroups=ht(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right],(t,n,r)=>{var o;const i=(o=r?.map(a=>n.find(s=>s.id===a)).filter(Boolean))!=null?o:[];return rb(t,i,e,"right")},pt(e.options,Xr)),e.getFooterGroups=ht(()=>[e.getHeaderGroups()],t=>[...t].reverse(),pt(e.options,Xr)),e.getLeftFooterGroups=ht(()=>[e.getLeftHeaderGroups()],t=>[...t].reverse(),pt(e.options,Xr)),e.getCenterFooterGroups=ht(()=>[e.getCenterHeaderGroups()],t=>[...t].reverse(),pt(e.options,Xr)),e.getRightFooterGroups=ht(()=>[e.getRightHeaderGroups()],t=>[...t].reverse(),pt(e.options,Xr)),e.getFlatHeaders=ht(()=>[e.getHeaderGroups()],t=>t.map(n=>n.headers).flat(),pt(e.options,Xr)),e.getLeftFlatHeaders=ht(()=>[e.getLeftHeaderGroups()],t=>t.map(n=>n.headers).flat(),pt(e.options,Xr)),e.getCenterFlatHeaders=ht(()=>[e.getCenterHeaderGroups()],t=>t.map(n=>n.headers).flat(),pt(e.options,Xr)),e.getRightFlatHeaders=ht(()=>[e.getRightHeaderGroups()],t=>t.map(n=>n.headers).flat(),pt(e.options,Xr)),e.getCenterLeafHeaders=ht(()=>[e.getCenterFlatHeaders()],t=>t.filter(n=>{var r;return!((r=n.subHeaders)!=null&&r.length)}),pt(e.options,Xr)),e.getLeftLeafHeaders=ht(()=>[e.getLeftFlatHeaders()],t=>t.filter(n=>{var r;return!((r=n.subHeaders)!=null&&r.length)}),pt(e.options,Xr)),e.getRightLeafHeaders=ht(()=>[e.getRightFlatHeaders()],t=>t.filter(n=>{var r;return!((r=n.subHeaders)!=null&&r.length)}),pt(e.options,Xr)),e.getLeafHeaders=ht(()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()],(t,n,r)=>{var o,i,a,s,l,u;return[...(o=(i=t[0])==null?void 0:i.headers)!=null?o:[],...(a=(s=n[0])==null?void 0:s.headers)!=null?a:[],...(l=(u=r[0])==null?void 0:u.headers)!=null?l:[]].map(d=>d.getLeafHeaders()).flat()},pt(e.options,Xr))}};function rb(e,t,n,r){var o,i;let a=0;const s=function(p,m){m===void 0&&(m=1),a=Math.max(a,m),p.filter(b=>b.getIsVisible()).forEach(b=>{var v;(v=b.columns)!=null&&v.length&&s(b.columns,m+1)},0)};s(e);let l=[];const u=(p,m)=>{const b={depth:m,id:[r,`${m}`].filter(Boolean).join("_"),headers:[]},v=[];p.forEach(y=>{const S=[...v].reverse()[0],x=y.column.depth===b.depth;let C,k=!1;if(x&&y.column.parent?C=y.column.parent:(C=y.column,k=!0),S&&S?.column===C)S.subHeaders.push(y);else{const M=t4(n,C,{id:[r,m,C.id,y?.id].filter(Boolean).join("_"),isPlaceholder:k,placeholderId:k?`${v.filter(I=>I.column===C).length}`:void 0,depth:m,index:v.length});M.subHeaders.push(y),v.push(M)}b.headers.push(y),y.headerGroup=b}),l.push(b),m>0&&u(v,m-1)},d=t.map((p,m)=>t4(n,p,{depth:a,index:m}));u(d,a-1),l.reverse();const h=p=>p.filter(b=>b.column.getIsVisible()).map(b=>{let v=0,y=0,S=[0];b.subHeaders&&b.subHeaders.length?(S=[],h(b.subHeaders).forEach(C=>{let{colSpan:k,rowSpan:M}=C;v+=k,S.push(M)})):v=1;const x=Math.min(...S);return y+=x,b.colSpan=v,b.rowSpan=y,{colSpan:v,rowSpan:y}});return h((o=(i=l[0])==null?void 0:i.headers)!=null?o:[]),l}const ob={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},nI=()=>({startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}),X0e={getDefaultColumnDef:()=>ob,getInitialState:e=>({columnSizing:{},columnSizingInfo:nI(),...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",columnResizeDirection:"ltr",onColumnSizingChange:pi("columnSizing",e),onColumnSizingInfoChange:pi("columnSizingInfo",e)}),createColumn:(e,t)=>{e.getSize=()=>{var n,r,o;const i=t.getState().columnSizing[e.id];return Math.min(Math.max((n=e.columnDef.minSize)!=null?n:ob.minSize,(r=i??e.columnDef.size)!=null?r:ob.size),(o=e.columnDef.maxSize)!=null?o:ob.maxSize)},e.getStart=ht(n=>[n,vm(t,n),t.getState().columnSizing],(n,r)=>r.slice(0,e.getIndex(n)).reduce((o,i)=>o+i.getSize(),0),pt(t.options,"debugColumns")),e.getAfter=ht(n=>[n,vm(t,n),t.getState().columnSizing],(n,r)=>r.slice(e.getIndex(n)+1).reduce((o,i)=>o+i.getSize(),0),pt(t.options,"debugColumns")),e.resetSize=()=>{t.setColumnSizing(n=>{let{[e.id]:r,...o}=n;return o})},e.getCanResize=()=>{var n,r;return((n=e.columnDef.enableResizing)!=null?n:!0)&&((r=t.options.enableColumnResizing)!=null?r:!0)},e.getIsResizing=()=>t.getState().columnSizingInfo.isResizingColumn===e.id},createHeader:(e,t)=>{e.getSize=()=>{let n=0;const r=o=>{if(o.subHeaders.length)o.subHeaders.forEach(r);else{var i;n+=(i=o.column.getSize())!=null?i:0}};return r(e),n},e.getStart=()=>{if(e.index>0){const n=e.headerGroup.headers[e.index-1];return n.getStart()+n.getSize()}return 0},e.getResizeHandler=n=>{const r=t.getColumn(e.column.id),o=r?.getCanResize();return i=>{if(!r||!o||(i.persist==null||i.persist(),rI(i)&&i.touches&&i.touches.length>1))return;const a=e.getSize(),s=e?e.getLeafHeaders().map(S=>[S.column.id,S.column.getSize()]):[[r.id,r.getSize()]],l=rI(i)?Math.round(i.touches[0].clientX):i.clientX,u={},d=(S,x)=>{typeof x=="number"&&(t.setColumnSizingInfo(C=>{var k,M;const I=t.options.columnResizeDirection==="rtl"?-1:1,O=(x-((k=C?.startOffset)!=null?k:0))*I,R=Math.max(O/((M=C?.startSize)!=null?M:0),-.999999);return C.columnSizingStart.forEach(L=>{let[B,_]=L;u[B]=Math.round(Math.max(_+_*R,0)*100)/100}),{...C,deltaOffset:O,deltaPercentage:R}}),(t.options.columnResizeMode==="onChange"||S==="end")&&t.setColumnSizing(C=>({...C,...u})))},h=S=>d("move",S),p=S=>{d("end",S),t.setColumnSizingInfo(x=>({...x,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]}))},m=n||typeof document<"u"?document:null,b={moveHandler:S=>h(S.clientX),upHandler:S=>{m?.removeEventListener("mousemove",b.moveHandler),m?.removeEventListener("mouseup",b.upHandler),p(S.clientX)}},v={moveHandler:S=>(S.cancelable&&(S.preventDefault(),S.stopPropagation()),h(S.touches[0].clientX),!1),upHandler:S=>{var x;m?.removeEventListener("touchmove",v.moveHandler),m?.removeEventListener("touchend",v.upHandler),S.cancelable&&(S.preventDefault(),S.stopPropagation()),p((x=S.touches[0])==null?void 0:x.clientX)}},y=J0e()?{passive:!1}:!1;rI(i)?(m?.addEventListener("touchmove",v.moveHandler,y),m?.addEventListener("touchend",v.upHandler,y)):(m?.addEventListener("mousemove",b.moveHandler,y),m?.addEventListener("mouseup",b.upHandler,y)),t.setColumnSizingInfo(S=>({...S,startOffset:l,startSize:a,deltaOffset:0,deltaPercentage:0,columnSizingStart:s,isResizingColumn:r.id}))}}},createTable:e=>{e.setColumnSizing=t=>e.options.onColumnSizingChange==null?void 0:e.options.onColumnSizingChange(t),e.setColumnSizingInfo=t=>e.options.onColumnSizingInfoChange==null?void 0:e.options.onColumnSizingInfoChange(t),e.resetColumnSizing=t=>{var n;e.setColumnSizing(t?{}:(n=e.initialState.columnSizing)!=null?n:{})},e.resetHeaderSizeInfo=t=>{var n;e.setColumnSizingInfo(t?nI():(n=e.initialState.columnSizingInfo)!=null?n:nI())},e.getTotalSize=()=>{var t,n;return(t=(n=e.getHeaderGroups()[0])==null?void 0:n.headers.reduce((r,o)=>r+o.getSize(),0))!=null?t:0},e.getLeftTotalSize=()=>{var t,n;return(t=(n=e.getLeftHeaderGroups()[0])==null?void 0:n.headers.reduce((r,o)=>r+o.getSize(),0))!=null?t:0},e.getCenterTotalSize=()=>{var t,n;return(t=(n=e.getCenterHeaderGroups()[0])==null?void 0:n.headers.reduce((r,o)=>r+o.getSize(),0))!=null?t:0},e.getRightTotalSize=()=>{var t,n;return(t=(n=e.getRightHeaderGroups()[0])==null?void 0:n.headers.reduce((r,o)=>r+o.getSize(),0))!=null?t:0}}};let ib=null;function J0e(){if(typeof ib=="boolean")return ib;let e=!1;try{const t={get passive(){return e=!0,!1}},n=()=>{};window.addEventListener("test",n,t),window.removeEventListener("test",n)}catch{e=!1}return ib=e,ib}function rI(e){return e.type==="touchstart"}const Q0e={getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:pi("expanded",e),paginateExpandedRows:!0}),createTable:e=>{let t=!1,n=!1;e._autoResetExpanded=()=>{var r,o;if(!t){e._queue(()=>{t=!0});return}if((r=(o=e.options.autoResetAll)!=null?o:e.options.autoResetExpanded)!=null?r:!e.options.manualExpanding){if(n)return;n=!0,e._queue(()=>{e.resetExpanded(),n=!1})}},e.setExpanded=r=>e.options.onExpandedChange==null?void 0:e.options.onExpandedChange(r),e.toggleAllRowsExpanded=r=>{r??!e.getIsAllRowsExpanded()?e.setExpanded(!0):e.setExpanded({})},e.resetExpanded=r=>{var o,i;e.setExpanded(r?{}:(o=(i=e.initialState)==null?void 0:i.expanded)!=null?o:{})},e.getCanSomeRowsExpand=()=>e.getPrePaginationRowModel().flatRows.some(r=>r.getCanExpand()),e.getToggleAllRowsExpandedHandler=()=>r=>{r.persist==null||r.persist(),e.toggleAllRowsExpanded()},e.getIsSomeRowsExpanded=()=>{const r=e.getState().expanded;return r===!0||Object.values(r).some(Boolean)},e.getIsAllRowsExpanded=()=>{const r=e.getState().expanded;return typeof r=="boolean"?r===!0:!(!Object.keys(r).length||e.getRowModel().flatRows.some(o=>!o.getIsExpanded()))},e.getExpandedDepth=()=>{let r=0;return(e.getState().expanded===!0?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach(i=>{const a=i.split(".");r=Math.max(r,a.length)}),r},e.getPreExpandedRowModel=()=>e.getSortedRowModel(),e.getExpandedRowModel=()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel())},createRow:(e,t)=>{e.toggleExpanded=n=>{t.setExpanded(r=>{var o;const i=r===!0?!0:!!(r!=null&&r[e.id]);let a={};if(r===!0?Object.keys(t.getRowModel().rowsById).forEach(s=>{a[s]=!0}):a=r,n=(o=n)!=null?o:!i,!i&&n)return{...a,[e.id]:!0};if(i&&!n){const{[e.id]:s,...l}=a;return l}return r})},e.getIsExpanded=()=>{var n;const r=t.getState().expanded;return!!((n=t.options.getIsRowExpanded==null?void 0:t.options.getIsRowExpanded(e))!=null?n:r===!0||r?.[e.id])},e.getCanExpand=()=>{var n,r,o;return(n=t.options.getRowCanExpand==null?void 0:t.options.getRowCanExpand(e))!=null?n:((r=t.options.enableExpanding)!=null?r:!0)&&!!((o=e.subRows)!=null&&o.length)},e.getIsAllParentsExpanded=()=>{let n=!0,r=e;for(;n&&r.parentId;)r=t.getRow(r.parentId,!0),n=r.getIsExpanded();return n},e.getToggleExpandedHandler=()=>{const n=e.getCanExpand();return()=>{n&&e.toggleExpanded()}}}},G_=(e,t,n)=>{var r;const o=n.toLowerCase();return!!(!((r=e.getValue(t))==null||(r=r.toString())==null||(r=r.toLowerCase())==null)&&r.includes(o))};G_.autoRemove=e=>va(e);const Z_=(e,t,n)=>{var r;return!!(!((r=e.getValue(t))==null||(r=r.toString())==null)&&r.includes(n))};Z_.autoRemove=e=>va(e);const $_=(e,t,n)=>{var r;return((r=e.getValue(t))==null||(r=r.toString())==null?void 0:r.toLowerCase())===n?.toLowerCase()};$_.autoRemove=e=>va(e);const q_=(e,t,n)=>{var r;return(r=e.getValue(t))==null?void 0:r.includes(n)};q_.autoRemove=e=>va(e)||!(e!=null&&e.length);const K_=(e,t,n)=>!n.some(r=>{var o;return!((o=e.getValue(t))!=null&&o.includes(r))});K_.autoRemove=e=>va(e)||!(e!=null&&e.length);const X_=(e,t,n)=>n.some(r=>{var o;return(o=e.getValue(t))==null?void 0:o.includes(r)});X_.autoRemove=e=>va(e)||!(e!=null&&e.length);const J_=(e,t,n)=>e.getValue(t)===n;J_.autoRemove=e=>va(e);const Q_=(e,t,n)=>e.getValue(t)==n;Q_.autoRemove=e=>va(e);const VD=(e,t,n)=>{let[r,o]=n;const i=e.getValue(t);return i>=r&&i<=o};VD.resolveFilterValue=e=>{let[t,n]=e,r=typeof t!="number"?parseFloat(t):t,o=typeof n!="number"?parseFloat(n):n,i=t===null||Number.isNaN(r)?-1/0:r,a=n===null||Number.isNaN(o)?1/0:o;if(i>a){const s=i;i=a,a=s}return[i,a]};VD.autoRemove=e=>va(e)||va(e[0])&&va(e[1]);const Ws={includesString:G_,includesStringSensitive:Z_,equalsString:$_,arrIncludes:q_,arrIncludesAll:K_,arrIncludesSome:X_,equals:J_,weakEquals:Q_,inNumberRange:VD};function va(e){return e==null||e===""}const ewe={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],globalFilter:void 0,...e}),getDefaultOptions:e=>({onColumnFiltersChange:pi("columnFilters",e),onGlobalFilterChange:pi("globalFilter",e),filterFromLeafRows:!1,maxLeafRowFilterDepth:100,globalFilterFn:"auto",getColumnCanGlobalFilter:t=>{var n;const r=(n=e.getCoreRowModel().flatRows[0])==null||(n=n._getAllCellsByColumnId()[t.id])==null?void 0:n.getValue();return typeof r=="string"||typeof r=="number"}}),createColumn:(e,t)=>{e.getAutoFilterFn=()=>{const n=t.getCoreRowModel().flatRows[0],r=n?.getValue(e.id);return typeof r=="string"?Ws.includesString:typeof r=="number"?Ws.inNumberRange:typeof r=="boolean"||r!==null&&typeof r=="object"?Ws.equals:Array.isArray(r)?Ws.arrIncludes:Ws.weakEquals},e.getFilterFn=()=>{var n,r;return _0(e.columnDef.filterFn)?e.columnDef.filterFn:e.columnDef.filterFn==="auto"?e.getAutoFilterFn():(n=(r=t.options.filterFns)==null?void 0:r[e.columnDef.filterFn])!=null?n:Ws[e.columnDef.filterFn]},e.getCanFilter=()=>{var n,r,o;return((n=e.columnDef.enableColumnFilter)!=null?n:!0)&&((r=t.options.enableColumnFilters)!=null?r:!0)&&((o=t.options.enableFilters)!=null?o:!0)&&!!e.accessorFn},e.getCanGlobalFilter=()=>{var n,r,o,i;return((n=e.columnDef.enableGlobalFilter)!=null?n:!0)&&((r=t.options.enableGlobalFilter)!=null?r:!0)&&((o=t.options.enableFilters)!=null?o:!0)&&((i=t.options.getColumnCanGlobalFilter==null?void 0:t.options.getColumnCanGlobalFilter(e))!=null?i:!0)&&!!e.accessorFn},e.getIsFiltered=()=>e.getFilterIndex()>-1,e.getFilterValue=()=>{var n;return(n=t.getState().columnFilters)==null||(n=n.find(r=>r.id===e.id))==null?void 0:n.value},e.getFilterIndex=()=>{var n,r;return(n=(r=t.getState().columnFilters)==null?void 0:r.findIndex(o=>o.id===e.id))!=null?n:-1},e.setFilterValue=n=>{t.setColumnFilters(r=>{const o=e.getFilterFn(),i=r?.find(d=>d.id===e.id),a=dc(n,i?i.value:void 0);if(n4(o,a,e)){var s;return(s=r?.filter(d=>d.id!==e.id))!=null?s:[]}const l={id:e.id,value:a};if(i){var u;return(u=r?.map(d=>d.id===e.id?l:d))!=null?u:[]}return r!=null&&r.length?[...r,l]:[l]})},e._getFacetedRowModel=t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,e.id),e.getFacetedRowModel=()=>e._getFacetedRowModel?e._getFacetedRowModel():t.getPreFilteredRowModel(),e._getFacetedUniqueValues=t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,e.id),e.getFacetedUniqueValues=()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,e._getFacetedMinMaxValues=t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,e.id),e.getFacetedMinMaxValues=()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}},createRow:(e,t)=>{e.columnFilters={},e.columnFiltersMeta={}},createTable:e=>{e.getGlobalAutoFilterFn=()=>Ws.includesString,e.getGlobalFilterFn=()=>{var t,n;const{globalFilterFn:r}=e.options;return _0(r)?r:r==="auto"?e.getGlobalAutoFilterFn():(t=(n=e.options.filterFns)==null?void 0:n[r])!=null?t:Ws[r]},e.setColumnFilters=t=>{const n=e.getAllLeafColumns(),r=o=>{var i;return(i=dc(t,o))==null?void 0:i.filter(a=>{const s=n.find(l=>l.id===a.id);if(s){const l=s.getFilterFn();if(n4(l,a.value,s))return!1}return!0})};e.options.onColumnFiltersChange==null||e.options.onColumnFiltersChange(r)},e.setGlobalFilter=t=>{e.options.onGlobalFilterChange==null||e.options.onGlobalFilterChange(t)},e.resetGlobalFilter=t=>{e.setGlobalFilter(t?void 0:e.initialState.globalFilter)},e.resetColumnFilters=t=>{var n,r;e.setColumnFilters(t?[]:(n=(r=e.initialState)==null?void 0:r.columnFilters)!=null?n:[])},e.getPreFilteredRowModel=()=>e.getCoreRowModel(),e.getFilteredRowModel=()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel()),e._getGlobalFacetedRowModel=e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),e.getGlobalFacetedRowModel=()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),e._getGlobalFacetedUniqueValues=e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),e.getGlobalFacetedUniqueValues=()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,e._getGlobalFacetedMinMaxValues=e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),e.getGlobalFacetedMinMaxValues=()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}}};function n4(e,t,n){return(e&&e.autoRemove?e.autoRemove(t,n):!1)||typeof t>"u"||typeof t=="string"&&!t}const twe=(e,t,n)=>n.reduce((r,o)=>{const i=o.getValue(e);return r+(typeof i=="number"?i:0)},0),nwe=(e,t,n)=>{let r;return n.forEach(o=>{const i=o.getValue(e);i!=null&&(r>i||r===void 0&&i>=i)&&(r=i)}),r},rwe=(e,t,n)=>{let r;return n.forEach(o=>{const i=o.getValue(e);i!=null&&(r<i||r===void 0&&i>=i)&&(r=i)}),r},owe=(e,t,n)=>{let r,o;return n.forEach(i=>{const a=i.getValue(e);a!=null&&(r===void 0?a>=a&&(r=o=a):(r>a&&(r=a),o<a&&(o=a)))}),[r,o]},iwe=(e,t)=>{let n=0,r=0;if(t.forEach(o=>{let i=o.getValue(e);i!=null&&(i=+i)>=i&&(++n,r+=i)}),n)return r/n},awe=(e,t)=>{if(!t.length)return;const n=t.map(i=>i.getValue(e));if(!Z0e(n))return;if(n.length===1)return n[0];const r=Math.floor(n.length/2),o=n.sort((i,a)=>i-a);return n.length%2!==0?o[r]:(o[r-1]+o[r])/2},swe=(e,t)=>Array.from(new Set(t.map(n=>n.getValue(e))).values()),lwe=(e,t)=>new Set(t.map(n=>n.getValue(e))).size,cwe=(e,t)=>t.length,oI={sum:twe,min:nwe,max:rwe,extent:owe,mean:iwe,median:awe,unique:swe,uniqueCount:lwe,count:cwe},uwe={getDefaultColumnDef:()=>({aggregatedCell:e=>{var t,n;return(t=(n=e.getValue())==null||n.toString==null?void 0:n.toString())!=null?t:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:pi("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,t)=>{e.toggleGrouping=()=>{t.setGrouping(n=>n!=null&&n.includes(e.id)?n.filter(r=>r!==e.id):[...n??[],e.id])},e.getCanGroup=()=>{var n,r,o,i;return(n=(r=(o=(i=e.columnDef.enableGrouping)!=null?i:!0)!=null?o:t.options.enableGrouping)!=null?r:!0)!=null?n:!!e.accessorFn},e.getIsGrouped=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.includes(e.id)},e.getGroupedIndex=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.indexOf(e.id)},e.getToggleGroupingHandler=()=>{const n=e.getCanGroup();return()=>{n&&e.toggleGrouping()}},e.getAutoAggregationFn=()=>{const n=t.getCoreRowModel().flatRows[0],r=n?.getValue(e.id);if(typeof r=="number")return oI.sum;if(Object.prototype.toString.call(r)==="[object Date]")return oI.extent},e.getAggregationFn=()=>{var n,r;if(!e)throw new Error;return _0(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:e.columnDef.aggregationFn==="auto"?e.getAutoAggregationFn():(n=(r=t.options.aggregationFns)==null?void 0:r[e.columnDef.aggregationFn])!=null?n:oI[e.columnDef.aggregationFn]}},createTable:e=>{e.setGrouping=t=>e.options.onGroupingChange==null?void 0:e.options.onGroupingChange(t),e.resetGrouping=t=>{var n,r;e.setGrouping(t?[]:(n=(r=e.initialState)==null?void 0:r.grouping)!=null?n:[])},e.getPreGroupedRowModel=()=>e.getFilteredRowModel(),e.getGroupedRowModel=()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel())},createRow:(e,t)=>{e.getIsGrouped=()=>!!e.groupingColumnId,e.getGroupingValue=n=>{if(e._groupingValuesCache.hasOwnProperty(n))return e._groupingValuesCache[n];const r=t.getColumn(n);return r!=null&&r.columnDef.getGroupingValue?(e._groupingValuesCache[n]=r.columnDef.getGroupingValue(e.original),e._groupingValuesCache[n]):e.getValue(n)},e._groupingValuesCache={}},createCell:(e,t,n,r)=>{e.getIsGrouped=()=>t.getIsGrouped()&&t.id===n.groupingColumnId,e.getIsPlaceholder=()=>!e.getIsGrouped()&&t.getIsGrouped(),e.getIsAggregated=()=>{var o;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!!((o=n.subRows)!=null&&o.length)}}};function dwe(e,t,n){if(!(t!=null&&t.length)||!n)return e;const r=e.filter(i=>!t.includes(i.id));return n==="remove"?r:[...t.map(i=>e.find(a=>a.id===i)).filter(Boolean),...r]}const fwe={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:pi("columnOrder",e)}),createColumn:(e,t)=>{e.getIndex=ht(n=>[vm(t,n)],n=>n.findIndex(r=>r.id===e.id),pt(t.options,"debugColumns")),e.getIsFirstColumn=n=>{var r;return((r=vm(t,n)[0])==null?void 0:r.id)===e.id},e.getIsLastColumn=n=>{var r;const o=vm(t,n);return((r=o[o.length-1])==null?void 0:r.id)===e.id}},createTable:e=>{e.setColumnOrder=t=>e.options.onColumnOrderChange==null?void 0:e.options.onColumnOrderChange(t),e.resetColumnOrder=t=>{var n;e.setColumnOrder(t?[]:(n=e.initialState.columnOrder)!=null?n:[])},e._getOrderColumnsFn=ht(()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode],(t,n,r)=>o=>{let i=[];if(!(t!=null&&t.length))i=o;else{const a=[...t],s=[...o];for(;s.length&&a.length;){const l=a.shift(),u=s.findIndex(d=>d.id===l);u>-1&&i.push(s.splice(u,1)[0])}i=[...i,...s]}return dwe(i,n,r)},pt(e.options,"debugTable"))}},yE=0,bE=10,iI=()=>({pageIndex:yE,pageSize:bE}),hwe={getInitialState:e=>({...e,pagination:{...iI(),...e?.pagination}}),getDefaultOptions:e=>({onPaginationChange:pi("pagination",e)}),createTable:e=>{let t=!1,n=!1;e._autoResetPageIndex=()=>{var r,o;if(!t){e._queue(()=>{t=!0});return}if((r=(o=e.options.autoResetAll)!=null?o:e.options.autoResetPageIndex)!=null?r:!e.options.manualPagination){if(n)return;n=!0,e._queue(()=>{e.resetPageIndex(),n=!1})}},e.setPagination=r=>{const o=i=>dc(r,i);return e.options.onPaginationChange==null?void 0:e.options.onPaginationChange(o)},e.resetPagination=r=>{var o;e.setPagination(r?iI():(o=e.initialState.pagination)!=null?o:iI())},e.setPageIndex=r=>{e.setPagination(o=>{let i=dc(r,o.pageIndex);const a=typeof e.options.pageCount>"u"||e.options.pageCount===-1?Number.MAX_SAFE_INTEGER:e.options.pageCount-1;return i=Math.max(0,Math.min(i,a)),{...o,pageIndex:i}})},e.resetPageIndex=r=>{var o,i;e.setPageIndex(r?yE:(o=(i=e.initialState)==null||(i=i.pagination)==null?void 0:i.pageIndex)!=null?o:yE)},e.resetPageSize=r=>{var o,i;e.setPageSize(r?bE:(o=(i=e.initialState)==null||(i=i.pagination)==null?void 0:i.pageSize)!=null?o:bE)},e.setPageSize=r=>{e.setPagination(o=>{const i=Math.max(1,dc(r,o.pageSize)),a=o.pageSize*o.pageIndex,s=Math.floor(a/i);return{...o,pageIndex:s,pageSize:i}})},e.setPageCount=r=>e.setPagination(o=>{var i;let a=dc(r,(i=e.options.pageCount)!=null?i:-1);return typeof a=="number"&&(a=Math.max(-1,a)),{...o,pageCount:a}}),e.getPageOptions=ht(()=>[e.getPageCount()],r=>{let o=[];return r&&r>0&&(o=[...new Array(r)].fill(null).map((i,a)=>a)),o},pt(e.options,"debugTable")),e.getCanPreviousPage=()=>e.getState().pagination.pageIndex>0,e.getCanNextPage=()=>{const{pageIndex:r}=e.getState().pagination,o=e.getPageCount();return o===-1?!0:o===0?!1:r<o-1},e.previousPage=()=>e.setPageIndex(r=>r-1),e.nextPage=()=>e.setPageIndex(r=>r+1),e.firstPage=()=>e.setPageIndex(0),e.lastPage=()=>e.setPageIndex(e.getPageCount()-1),e.getPrePaginationRowModel=()=>e.getExpandedRowModel(),e.getPaginationRowModel=()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),e.getPageCount=()=>{var r;return(r=e.options.pageCount)!=null?r:Math.ceil(e.getRowCount()/e.getState().pagination.pageSize)},e.getRowCount=()=>{var r;return(r=e.options.rowCount)!=null?r:e.getPrePaginationRowModel().rows.length}}},aI=()=>({left:[],right:[]}),sI=()=>({top:[],bottom:[]}),pwe={getInitialState:e=>({columnPinning:aI(),rowPinning:sI(),...e}),getDefaultOptions:e=>({onColumnPinningChange:pi("columnPinning",e),onRowPinningChange:pi("rowPinning",e)}),createColumn:(e,t)=>{e.pin=n=>{const r=e.getLeafColumns().map(o=>o.id).filter(Boolean);t.setColumnPinning(o=>{var i,a;if(n==="right"){var s,l;return{left:((s=o?.left)!=null?s:[]).filter(h=>!(r!=null&&r.includes(h))),right:[...((l=o?.right)!=null?l:[]).filter(h=>!(r!=null&&r.includes(h))),...r]}}if(n==="left"){var u,d;return{left:[...((u=o?.left)!=null?u:[]).filter(h=>!(r!=null&&r.includes(h))),...r],right:((d=o?.right)!=null?d:[]).filter(h=>!(r!=null&&r.includes(h)))}}return{left:((i=o?.left)!=null?i:[]).filter(h=>!(r!=null&&r.includes(h))),right:((a=o?.right)!=null?a:[]).filter(h=>!(r!=null&&r.includes(h)))}})},e.getCanPin=()=>e.getLeafColumns().some(r=>{var o,i,a;return((o=r.columnDef.enablePinning)!=null?o:!0)&&((i=(a=t.options.enableColumnPinning)!=null?a:t.options.enablePinning)!=null?i:!0)}),e.getIsPinned=()=>{const n=e.getLeafColumns().map(s=>s.id),{left:r,right:o}=t.getState().columnPinning,i=n.some(s=>r?.includes(s)),a=n.some(s=>o?.includes(s));return i?"left":a?"right":!1},e.getPinnedIndex=()=>{var n,r;const o=e.getIsPinned();return o?(n=(r=t.getState().columnPinning)==null||(r=r[o])==null?void 0:r.indexOf(e.id))!=null?n:-1:0}},createRow:(e,t)=>{e.pin=(n,r,o)=>{const i=r?e.getLeafRows().map(l=>{let{id:u}=l;return u}):[],a=o?e.getParentRows().map(l=>{let{id:u}=l;return u}):[],s=new Set([...a,e.id,...i]);t.setRowPinning(l=>{var u,d;if(n==="bottom"){var h,p;return{top:((h=l?.top)!=null?h:[]).filter(v=>!(s!=null&&s.has(v))),bottom:[...((p=l?.bottom)!=null?p:[]).filter(v=>!(s!=null&&s.has(v))),...Array.from(s)]}}if(n==="top"){var m,b;return{top:[...((m=l?.top)!=null?m:[]).filter(v=>!(s!=null&&s.has(v))),...Array.from(s)],bottom:((b=l?.bottom)!=null?b:[]).filter(v=>!(s!=null&&s.has(v)))}}return{top:((u=l?.top)!=null?u:[]).filter(v=>!(s!=null&&s.has(v))),bottom:((d=l?.bottom)!=null?d:[]).filter(v=>!(s!=null&&s.has(v)))}})},e.getCanPin=()=>{var n;const{enableRowPinning:r,enablePinning:o}=t.options;return typeof r=="function"?r(e):(n=r??o)!=null?n:!0},e.getIsPinned=()=>{const n=[e.id],{top:r,bottom:o}=t.getState().rowPinning,i=n.some(s=>r?.includes(s)),a=n.some(s=>o?.includes(s));return i?"top":a?"bottom":!1},e.getPinnedIndex=()=>{var n,r;const o=e.getIsPinned();if(!o)return-1;const i=(n=t._getPinnedRows(o))==null?void 0:n.map(a=>{let{id:s}=a;return s});return(r=i?.indexOf(e.id))!=null?r:-1},e.getCenterVisibleCells=ht(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,t.getState().columnPinning.right],(n,r,o)=>{const i=[...r??[],...o??[]];return n.filter(a=>!i.includes(a.column.id))},pt(t.options,"debugRows")),e.getLeftVisibleCells=ht(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left],(n,r)=>(r??[]).map(i=>n.find(a=>a.column.id===i)).filter(Boolean).map(i=>({...i,position:"left"})),pt(t.options,"debugRows")),e.getRightVisibleCells=ht(()=>[e._getAllVisibleCells(),t.getState().columnPinning.right],(n,r)=>(r??[]).map(i=>n.find(a=>a.column.id===i)).filter(Boolean).map(i=>({...i,position:"right"})),pt(t.options,"debugRows"))},createTable:e=>{e.setColumnPinning=t=>e.options.onColumnPinningChange==null?void 0:e.options.onColumnPinningChange(t),e.resetColumnPinning=t=>{var n,r;return e.setColumnPinning(t?aI():(n=(r=e.initialState)==null?void 0:r.columnPinning)!=null?n:aI())},e.getIsSomeColumnsPinned=t=>{var n;const r=e.getState().columnPinning;if(!t){var o,i;return!!((o=r.left)!=null&&o.length||(i=r.right)!=null&&i.length)}return!!((n=r[t])!=null&&n.length)},e.getLeftLeafColumns=ht(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left],(t,n)=>(n??[]).map(r=>t.find(o=>o.id===r)).filter(Boolean),pt(e.options,"debugColumns")),e.getRightLeafColumns=ht(()=>[e.getAllLeafColumns(),e.getState().columnPinning.right],(t,n)=>(n??[]).map(r=>t.find(o=>o.id===r)).filter(Boolean),pt(e.options,"debugColumns")),e.getCenterLeafColumns=ht(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r)=>{const o=[...n??[],...r??[]];return t.filter(i=>!o.includes(i.id))},pt(e.options,"debugColumns")),e.setRowPinning=t=>e.options.onRowPinningChange==null?void 0:e.options.onRowPinningChange(t),e.resetRowPinning=t=>{var n,r;return e.setRowPinning(t?sI():(n=(r=e.initialState)==null?void 0:r.rowPinning)!=null?n:sI())},e.getIsSomeRowsPinned=t=>{var n;const r=e.getState().rowPinning;if(!t){var o,i;return!!((o=r.top)!=null&&o.length||(i=r.bottom)!=null&&i.length)}return!!((n=r[t])!=null&&n.length)},e._getPinnedRows=ht(t=>[e.getRowModel().rows,e.getState().rowPinning[t],t],(t,n,r)=>{var o;return((o=e.options.keepPinnedRows)==null||o?(n??[]).map(a=>{const s=e.getRow(a,!0);return s.getIsAllParentsExpanded()?s:null}):(n??[]).map(a=>t.find(s=>s.id===a))).filter(Boolean).map(a=>({...a,position:r}))},pt(e.options,"debugRows")),e.getTopRows=()=>e._getPinnedRows("top"),e.getBottomRows=()=>e._getPinnedRows("bottom"),e.getCenterRows=ht(()=>[e.getRowModel().rows,e.getState().rowPinning.top,e.getState().rowPinning.bottom],(t,n,r)=>{const o=new Set([...n??[],...r??[]]);return t.filter(i=>!o.has(i.id))},pt(e.options,"debugRows"))}},mwe={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:pi("rowSelection",e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>{e.setRowSelection=t=>e.options.onRowSelectionChange==null?void 0:e.options.onRowSelectionChange(t),e.resetRowSelection=t=>{var n;return e.setRowSelection(t?{}:(n=e.initialState.rowSelection)!=null?n:{})},e.toggleAllRowsSelected=t=>{e.setRowSelection(n=>{t=typeof t<"u"?t:!e.getIsAllRowsSelected();const r={...n},o=e.getPreGroupedRowModel().flatRows;return t?o.forEach(i=>{i.getCanSelect()&&(r[i.id]=!0)}):o.forEach(i=>{delete r[i.id]}),r})},e.toggleAllPageRowsSelected=t=>e.setRowSelection(n=>{const r=typeof t<"u"?t:!e.getIsAllPageRowsSelected(),o={...n};return e.getRowModel().rows.forEach(i=>{wE(o,i.id,r,!0,e)}),o}),e.getPreSelectedRowModel=()=>e.getCoreRowModel(),e.getSelectedRowModel=ht(()=>[e.getState().rowSelection,e.getCoreRowModel()],(t,n)=>Object.keys(t).length?lI(e,n):{rows:[],flatRows:[],rowsById:{}},pt(e.options,"debugTable")),e.getFilteredSelectedRowModel=ht(()=>[e.getState().rowSelection,e.getFilteredRowModel()],(t,n)=>Object.keys(t).length?lI(e,n):{rows:[],flatRows:[],rowsById:{}},pt(e.options,"debugTable")),e.getGroupedSelectedRowModel=ht(()=>[e.getState().rowSelection,e.getSortedRowModel()],(t,n)=>Object.keys(t).length?lI(e,n):{rows:[],flatRows:[],rowsById:{}},pt(e.options,"debugTable")),e.getIsAllRowsSelected=()=>{const t=e.getFilteredRowModel().flatRows,{rowSelection:n}=e.getState();let r=!!(t.length&&Object.keys(n).length);return r&&t.some(o=>o.getCanSelect()&&!n[o.id])&&(r=!1),r},e.getIsAllPageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows.filter(o=>o.getCanSelect()),{rowSelection:n}=e.getState();let r=!!t.length;return r&&t.some(o=>!n[o.id])&&(r=!1),r},e.getIsSomeRowsSelected=()=>{var t;const n=Object.keys((t=e.getState().rowSelection)!=null?t:{}).length;return n>0&&n<e.getFilteredRowModel().flatRows.length},e.getIsSomePageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows;return e.getIsAllPageRowsSelected()?!1:t.filter(n=>n.getCanSelect()).some(n=>n.getIsSelected()||n.getIsSomeSelected())},e.getToggleAllRowsSelectedHandler=()=>t=>{e.toggleAllRowsSelected(t.target.checked)},e.getToggleAllPageRowsSelectedHandler=()=>t=>{e.toggleAllPageRowsSelected(t.target.checked)}},createRow:(e,t)=>{e.toggleSelected=(n,r)=>{const o=e.getIsSelected();t.setRowSelection(i=>{var a;if(n=typeof n<"u"?n:!o,e.getCanSelect()&&o===n)return i;const s={...i};return wE(s,e.id,n,(a=r?.selectChildren)!=null?a:!0,t),s})},e.getIsSelected=()=>{const{rowSelection:n}=t.getState();return WD(e,n)},e.getIsSomeSelected=()=>{const{rowSelection:n}=t.getState();return SE(e,n)==="some"},e.getIsAllSubRowsSelected=()=>{const{rowSelection:n}=t.getState();return SE(e,n)==="all"},e.getCanSelect=()=>{var n;return typeof t.options.enableRowSelection=="function"?t.options.enableRowSelection(e):(n=t.options.enableRowSelection)!=null?n:!0},e.getCanSelectSubRows=()=>{var n;return typeof t.options.enableSubRowSelection=="function"?t.options.enableSubRowSelection(e):(n=t.options.enableSubRowSelection)!=null?n:!0},e.getCanMultiSelect=()=>{var n;return typeof t.options.enableMultiRowSelection=="function"?t.options.enableMultiRowSelection(e):(n=t.options.enableMultiRowSelection)!=null?n:!0},e.getToggleSelectedHandler=()=>{const n=e.getCanSelect();return r=>{var o;n&&e.toggleSelected((o=r.target)==null?void 0:o.checked)}}}},wE=(e,t,n,r,o)=>{var i;const a=o.getRow(t,!0);n?(a.getCanMultiSelect()||Object.keys(e).forEach(s=>delete e[s]),a.getCanSelect()&&(e[t]=!0)):delete e[t],r&&(i=a.subRows)!=null&&i.length&&a.getCanSelectSubRows()&&a.subRows.forEach(s=>wE(e,s.id,n,r,o))};function lI(e,t){const n=e.getState().rowSelection,r=[],o={},i=function(a,s){return a.map(l=>{var u;const d=WD(l,n);if(d&&(r.push(l),o[l.id]=l),(u=l.subRows)!=null&&u.length&&(l={...l,subRows:i(l.subRows)}),d)return l}).filter(Boolean)};return{rows:i(t.rows),flatRows:r,rowsById:o}}function WD(e,t){var n;return(n=t[e.id])!=null?n:!1}function SE(e,t,n){var r;if(!((r=e.subRows)!=null&&r.length))return!1;let o=!0,i=!1;return e.subRows.forEach(a=>{if(!(i&&!o)&&(a.getCanSelect()&&(WD(a,t)?i=!0:o=!1),a.subRows&&a.subRows.length)){const s=SE(a,t);s==="all"?i=!0:(s==="some"&&(i=!0),o=!1)}}),o?"all":i?"some":!1}const TE=/([0-9]+)/gm,gwe=(e,t,n)=>eB(Tc(e.getValue(n)).toLowerCase(),Tc(t.getValue(n)).toLowerCase()),vwe=(e,t,n)=>eB(Tc(e.getValue(n)),Tc(t.getValue(n))),ywe=(e,t,n)=>GD(Tc(e.getValue(n)).toLowerCase(),Tc(t.getValue(n)).toLowerCase()),bwe=(e,t,n)=>GD(Tc(e.getValue(n)),Tc(t.getValue(n))),wwe=(e,t,n)=>{const r=e.getValue(n),o=t.getValue(n);return r>o?1:r<o?-1:0},Swe=(e,t,n)=>GD(e.getValue(n),t.getValue(n));function GD(e,t){return e===t?0:e>t?1:-1}function Tc(e){return typeof e=="number"?isNaN(e)||e===1/0||e===-1/0?"":String(e):typeof e=="string"?e:""}function eB(e,t){const n=e.split(TE).filter(Boolean),r=t.split(TE).filter(Boolean);for(;n.length&&r.length;){const o=n.shift(),i=r.shift(),a=parseInt(o,10),s=parseInt(i,10),l=[a,s].sort();if(isNaN(l[0])){if(o>i)return 1;if(i>o)return-1;continue}if(isNaN(l[1]))return isNaN(a)?-1:1;if(a>s)return 1;if(s>a)return-1}return n.length-r.length}const tf={alphanumeric:gwe,alphanumericCaseSensitive:vwe,text:ywe,textCaseSensitive:bwe,datetime:wwe,basic:Swe},Twe={getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto",sortUndefined:1}),getDefaultOptions:e=>({onSortingChange:pi("sorting",e),isMultiSortEvent:t=>t.shiftKey}),createColumn:(e,t)=>{e.getAutoSortingFn=()=>{const n=t.getFilteredRowModel().flatRows.slice(10);let r=!1;for(const o of n){const i=o?.getValue(e.id);if(Object.prototype.toString.call(i)==="[object Date]")return tf.datetime;if(typeof i=="string"&&(r=!0,i.split(TE).length>1))return tf.alphanumeric}return r?tf.text:tf.basic},e.getAutoSortDir=()=>{const n=t.getFilteredRowModel().flatRows[0];return typeof n?.getValue(e.id)=="string"?"asc":"desc"},e.getSortingFn=()=>{var n,r;if(!e)throw new Error;return _0(e.columnDef.sortingFn)?e.columnDef.sortingFn:e.columnDef.sortingFn==="auto"?e.getAutoSortingFn():(n=(r=t.options.sortingFns)==null?void 0:r[e.columnDef.sortingFn])!=null?n:tf[e.columnDef.sortingFn]},e.toggleSorting=(n,r)=>{const o=e.getNextSortingOrder(),i=typeof n<"u"&&n!==null;t.setSorting(a=>{const s=a?.find(m=>m.id===e.id),l=a?.findIndex(m=>m.id===e.id);let u=[],d,h=i?n:o==="desc";if(a!=null&&a.length&&e.getCanMultiSort()&&r?s?d="toggle":d="add":a!=null&&a.length&&l!==a.length-1?d="replace":s?d="toggle":d="replace",d==="toggle"&&(i||o||(d="remove")),d==="add"){var p;u=[...a,{id:e.id,desc:h}],u.splice(0,u.length-((p=t.options.maxMultiSortColCount)!=null?p:Number.MAX_SAFE_INTEGER))}else d==="toggle"?u=a.map(m=>m.id===e.id?{...m,desc:h}:m):d==="remove"?u=a.filter(m=>m.id!==e.id):u=[{id:e.id,desc:h}];return u})},e.getFirstSortDir=()=>{var n,r;return((n=(r=e.columnDef.sortDescFirst)!=null?r:t.options.sortDescFirst)!=null?n:e.getAutoSortDir()==="desc")?"desc":"asc"},e.getNextSortingOrder=n=>{var r,o;const i=e.getFirstSortDir(),a=e.getIsSorted();return a?a!==i&&((r=t.options.enableSortingRemoval)==null||r)&&(!(n&&(o=t.options.enableMultiRemove)!=null)||o)?!1:a==="desc"?"asc":"desc":i},e.getCanSort=()=>{var n,r;return((n=e.columnDef.enableSorting)!=null?n:!0)&&((r=t.options.enableSorting)!=null?r:!0)&&!!e.accessorFn},e.getCanMultiSort=()=>{var n,r;return(n=(r=e.columnDef.enableMultiSort)!=null?r:t.options.enableMultiSort)!=null?n:!!e.accessorFn},e.getIsSorted=()=>{var n;const r=(n=t.getState().sorting)==null?void 0:n.find(o=>o.id===e.id);return r?r.desc?"desc":"asc":!1},e.getSortIndex=()=>{var n,r;return(n=(r=t.getState().sorting)==null?void 0:r.findIndex(o=>o.id===e.id))!=null?n:-1},e.clearSorting=()=>{t.setSorting(n=>n!=null&&n.length?n.filter(r=>r.id!==e.id):[])},e.getToggleSortingHandler=()=>{const n=e.getCanSort();return r=>{n&&(r.persist==null||r.persist(),e.toggleSorting==null||e.toggleSorting(void 0,e.getCanMultiSort()?t.options.isMultiSortEvent==null?void 0:t.options.isMultiSortEvent(r):!1))}}},createTable:e=>{e.setSorting=t=>e.options.onSortingChange==null?void 0:e.options.onSortingChange(t),e.resetSorting=t=>{var n,r;e.setSorting(t?[]:(n=(r=e.initialState)==null?void 0:r.sorting)!=null?n:[])},e.getPreSortedRowModel=()=>e.getGroupedRowModel(),e.getSortedRowModel=()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel())}},xwe={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:pi("columnVisibility",e)}),createColumn:(e,t)=>{e.toggleVisibility=n=>{e.getCanHide()&&t.setColumnVisibility(r=>({...r,[e.id]:n??!e.getIsVisible()}))},e.getIsVisible=()=>{var n,r;const o=e.columns;return(n=o.length?o.some(i=>i.getIsVisible()):(r=t.getState().columnVisibility)==null?void 0:r[e.id])!=null?n:!0},e.getCanHide=()=>{var n,r;return((n=e.columnDef.enableHiding)!=null?n:!0)&&((r=t.options.enableHiding)!=null?r:!0)},e.getToggleVisibilityHandler=()=>n=>{e.toggleVisibility==null||e.toggleVisibility(n.target.checked)}},createRow:(e,t)=>{e._getAllVisibleCells=ht(()=>[e.getAllCells(),t.getState().columnVisibility],n=>n.filter(r=>r.column.getIsVisible()),pt(t.options,"debugRows")),e.getVisibleCells=ht(()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()],(n,r,o)=>[...n,...r,...o],pt(t.options,"debugRows"))},createTable:e=>{const t=(n,r)=>ht(()=>[r(),r().filter(o=>o.getIsVisible()).map(o=>o.id).join("_")],o=>o.filter(i=>i.getIsVisible==null?void 0:i.getIsVisible()),pt(e.options,"debugColumns"));e.getVisibleFlatColumns=t("getVisibleFlatColumns",()=>e.getAllFlatColumns()),e.getVisibleLeafColumns=t("getVisibleLeafColumns",()=>e.getAllLeafColumns()),e.getLeftVisibleLeafColumns=t("getLeftVisibleLeafColumns",()=>e.getLeftLeafColumns()),e.getRightVisibleLeafColumns=t("getRightVisibleLeafColumns",()=>e.getRightLeafColumns()),e.getCenterVisibleLeafColumns=t("getCenterVisibleLeafColumns",()=>e.getCenterLeafColumns()),e.setColumnVisibility=n=>e.options.onColumnVisibilityChange==null?void 0:e.options.onColumnVisibilityChange(n),e.resetColumnVisibility=n=>{var r;e.setColumnVisibility(n?{}:(r=e.initialState.columnVisibility)!=null?r:{})},e.toggleAllColumnsVisible=n=>{var r;n=(r=n)!=null?r:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce((o,i)=>({...o,[i.id]:n||!(i.getCanHide!=null&&i.getCanHide())}),{}))},e.getIsAllColumnsVisible=()=>!e.getAllLeafColumns().some(n=>!(n.getIsVisible!=null&&n.getIsVisible())),e.getIsSomeColumnsVisible=()=>e.getAllLeafColumns().some(n=>n.getIsVisible==null?void 0:n.getIsVisible()),e.getToggleAllColumnsVisibilityHandler=()=>n=>{var r;e.toggleAllColumnsVisible((r=n.target)==null?void 0:r.checked)}}};function vm(e,t){return t?t==="center"?e.getCenterVisibleLeafColumns():t==="left"?e.getLeftVisibleLeafColumns():e.getRightVisibleLeafColumns():e.getVisibleLeafColumns()}const r4=[K0e,xwe,fwe,pwe,ewe,Twe,uwe,Q0e,hwe,mwe,X0e];function Iwe(e){var t;e.debugAll||e.debugTable;let n={_features:r4};const r=n._features.reduce((d,h)=>Object.assign(d,h.getDefaultOptions==null?void 0:h.getDefaultOptions(n)),{}),o=d=>n.options.mergeOptions?n.options.mergeOptions(r,d):{...r,...d};let a={...{},...(t=e.initialState)!=null?t:{}};n._features.forEach(d=>{var h;a=(h=d.getInitialState==null?void 0:d.getInitialState(a))!=null?h:a});const s=[];let l=!1;const u={_features:r4,options:{...r,...e},initialState:a,_queue:d=>{s.push(d),l||(l=!0,Promise.resolve().then(()=>{for(;s.length;)s.shift()();l=!1}).catch(h=>setTimeout(()=>{throw h})))},reset:()=>{n.setState(n.initialState)},setOptions:d=>{const h=dc(d,n.options);n.options=o(h)},getState:()=>n.options.state,setState:d=>{n.options.onStateChange==null||n.options.onStateChange(d)},_getRowId:(d,h,p)=>{var m;return(m=n.options.getRowId==null?void 0:n.options.getRowId(d,h,p))!=null?m:`${p?[p.id,h].join("."):h}`},getCoreRowModel:()=>(n._getCoreRowModel||(n._getCoreRowModel=n.options.getCoreRowModel(n)),n._getCoreRowModel()),getRowModel:()=>n.getPaginationRowModel(),getRow:(d,h)=>{let p=(h?n.getPrePaginationRowModel():n.getRowModel()).rowsById[d];if(!p&&(p=n.getCoreRowModel().rowsById[d],!p))throw new Error;return p},_getDefaultColumnDef:ht(()=>[n.options.defaultColumn],d=>{var h;return d=(h=d)!=null?h:{},{header:p=>{const m=p.header.column.columnDef;return m.accessorKey?m.accessorKey:m.accessorFn?m.id:null},cell:p=>{var m,b;return(m=(b=p.renderValue())==null||b.toString==null?void 0:b.toString())!=null?m:null},...n._features.reduce((p,m)=>Object.assign(p,m.getDefaultColumnDef==null?void 0:m.getDefaultColumnDef()),{}),...d}},pt(e,"debugColumns")),_getColumnDefs:()=>n.options.columns,getAllColumns:ht(()=>[n._getColumnDefs()],d=>{const h=function(p,m,b){return b===void 0&&(b=0),p.map(v=>{const y=q0e(n,v,b,m),S=v;return y.columns=S.columns?h(S.columns,y,b+1):[],y})};return h(d)},pt(e,"debugColumns")),getAllFlatColumns:ht(()=>[n.getAllColumns()],d=>d.flatMap(h=>h.getFlatColumns()),pt(e,"debugColumns")),_getAllFlatColumnsById:ht(()=>[n.getAllFlatColumns()],d=>d.reduce((h,p)=>(h[p.id]=p,h),{}),pt(e,"debugColumns")),getAllLeafColumns:ht(()=>[n.getAllColumns(),n._getOrderColumnsFn()],(d,h)=>{let p=d.flatMap(m=>m.getLeafColumns());return h(p)},pt(e,"debugColumns")),getColumn:d=>n._getAllFlatColumnsById()[d]};Object.assign(n,u);for(let d=0;d<n._features.length;d++){const h=n._features[d];h==null||h.createTable==null||h.createTable(n)}return n}function kwe(e,t,n,r){const o=()=>{var a;return(a=i.getValue())!=null?a:e.options.renderFallbackValue},i={id:`${t.id}_${n.id}`,row:t,column:n,getValue:()=>t.getValue(r),renderValue:o,getContext:ht(()=>[e,n,t,i],(a,s,l,u)=>({table:a,column:s,row:l,cell:u,getValue:u.getValue,renderValue:u.renderValue}),pt(e.options,"debugCells"))};return e._features.forEach(a=>{a.createCell==null||a.createCell(i,n,t,e)},{}),i}const ZD=(e,t,n,r,o,i,a)=>{let s={id:t,index:r,original:n,depth:o,parentId:a,_valuesCache:{},_uniqueValuesCache:{},getValue:l=>{if(s._valuesCache.hasOwnProperty(l))return s._valuesCache[l];const u=e.getColumn(l);if(u!=null&&u.accessorFn)return s._valuesCache[l]=u.accessorFn(s.original,r),s._valuesCache[l]},getUniqueValues:l=>{if(s._uniqueValuesCache.hasOwnProperty(l))return s._uniqueValuesCache[l];const u=e.getColumn(l);if(u!=null&&u.accessorFn)return u.columnDef.getUniqueValues?(s._uniqueValuesCache[l]=u.columnDef.getUniqueValues(s.original,r),s._uniqueValuesCache[l]):(s._uniqueValuesCache[l]=[s.getValue(l)],s._uniqueValuesCache[l])},renderValue:l=>{var u;return(u=s.getValue(l))!=null?u:e.options.renderFallbackValue},subRows:i??[],getLeafRows:()=>$0e(s.subRows,l=>l.subRows),getParentRow:()=>s.parentId?e.getRow(s.parentId,!0):void 0,getParentRows:()=>{let l=[],u=s;for(;;){const d=u.getParentRow();if(!d)break;l.push(d),u=d}return l.reverse()},getAllCells:ht(()=>[e.getAllLeafColumns()],l=>l.map(u=>kwe(e,s,u,u.id)),pt(e.options,"debugRows")),_getAllCellsByColumnId:ht(()=>[s.getAllCells()],l=>l.reduce((u,d)=>(u[d.column.id]=d,u),{}),pt(e.options,"debugRows"))};for(let l=0;l<e._features.length;l++){const u=e._features[l];u==null||u.createRow==null||u.createRow(s,e)}return s};function Ewe(){return e=>ht(()=>[e.options.data],t=>{const n={rows:[],flatRows:[],rowsById:{}},r=function(o,i,a){i===void 0&&(i=0);const s=[];for(let u=0;u<o.length;u++){const d=ZD(e,e._getRowId(o[u],u,a),o[u],u,i,void 0,a?.id);if(n.flatRows.push(d),n.rowsById[d.id]=d,s.push(d),e.options.getSubRows){var l;d.originalSubRows=e.options.getSubRows(o[u],u),(l=d.originalSubRows)!=null&&l.length&&(d.subRows=r(d.originalSubRows,i+1,d))}}return s};return n.rows=r(t),n},pt(e.options,"debugTable","getRowModel",()=>e._autoResetPageIndex()))}function tB(e,t,n){return n.options.filterFromLeafRows?Cwe(e,t,n):Mwe(e,t,n)}function Cwe(e,t,n){var r;const o=[],i={},a=(r=n.options.maxLeafRowFilterDepth)!=null?r:100,s=function(l,u){u===void 0&&(u=0);const d=[];for(let p=0;p<l.length;p++){var h;let m=l[p];const b=ZD(n,m.id,m.original,m.index,m.depth,void 0,m.parentId);if(b.columnFilters=m.columnFilters,(h=m.subRows)!=null&&h.length&&u<a){if(b.subRows=s(m.subRows,u+1),m=b,t(m)&&!b.subRows.length){d.push(m),i[m.id]=m,o.push(m);continue}if(t(m)||b.subRows.length){d.push(m),i[m.id]=m,o.push(m);continue}}else m=b,t(m)&&(d.push(m),i[m.id]=m,o.push(m))}return d};return{rows:s(e),flatRows:o,rowsById:i}}function Mwe(e,t,n){var r;const o=[],i={},a=(r=n.options.maxLeafRowFilterDepth)!=null?r:100,s=function(l,u){u===void 0&&(u=0);const d=[];for(let p=0;p<l.length;p++){let m=l[p];if(t(m)){var h;if((h=m.subRows)!=null&&h.length&&u<a){const v=ZD(n,m.id,m.original,m.index,m.depth,void 0,m.parentId);v.subRows=s(m.subRows,u+1),m=v}d.push(m),o.push(m),i[m.id]=m}}return d};return{rows:s(e),flatRows:o,rowsById:i}}function Dwe(){return e=>ht(()=>[e.getPreFilteredRowModel(),e.getState().columnFilters,e.getState().globalFilter],(t,n,r)=>{if(!t.rows.length||!(n!=null&&n.length)&&!r){for(let p=0;p<t.flatRows.length;p++)t.flatRows[p].columnFilters={},t.flatRows[p].columnFiltersMeta={};return t}const o=[],i=[];(n??[]).forEach(p=>{var m;const b=e.getColumn(p.id);if(!b)return;const v=b.getFilterFn();v&&o.push({id:p.id,filterFn:v,resolvedValue:(m=v.resolveFilterValue==null?void 0:v.resolveFilterValue(p.value))!=null?m:p.value})});const a=n.map(p=>p.id),s=e.getGlobalFilterFn(),l=e.getAllLeafColumns().filter(p=>p.getCanGlobalFilter());r&&s&&l.length&&(a.push("__global__"),l.forEach(p=>{var m;i.push({id:p.id,filterFn:s,resolvedValue:(m=s.resolveFilterValue==null?void 0:s.resolveFilterValue(r))!=null?m:r})}));let u,d;for(let p=0;p<t.flatRows.length;p++){const m=t.flatRows[p];if(m.columnFilters={},o.length)for(let b=0;b<o.length;b++){u=o[b];const v=u.id;m.columnFilters[v]=u.filterFn(m,v,u.resolvedValue,y=>{m.columnFiltersMeta[v]=y})}if(i.length){for(let b=0;b<i.length;b++){d=i[b];const v=d.id;if(d.filterFn(m,v,d.resolvedValue,y=>{m.columnFiltersMeta[v]=y})){m.columnFilters.__global__=!0;break}}m.columnFilters.__global__!==!0&&(m.columnFilters.__global__=!1)}}const h=p=>{for(let m=0;m<a.length;m++)if(p.columnFilters[a[m]]===!1)return!1;return!0};return tB(t.rows,h,e)},pt(e.options,"debugTable","getFilteredRowModel",()=>e._autoResetPageIndex()))}function Awe(){return(e,t)=>ht(()=>[e.getPreFilteredRowModel(),e.getState().columnFilters,e.getState().globalFilter,e.getFilteredRowModel()],(n,r,o)=>{if(!n.rows.length||!(r!=null&&r.length)&&!o)return n;const i=[...r.map(s=>s.id).filter(s=>s!==t),o?"__global__":void 0].filter(Boolean),a=s=>{for(let l=0;l<i.length;l++)if(s.columnFilters[i[l]]===!1)return!1;return!0};return tB(n.rows,a,e)},pt(e.options,"debugTable"))}function Nwe(){return(e,t)=>ht(()=>{var n;return[(n=e.getColumn(t))==null?void 0:n.getFacetedRowModel()]},n=>{if(!n)return new Map;let r=new Map;for(let i=0;i<n.flatRows.length;i++){const a=n.flatRows[i].getUniqueValues(t);for(let s=0;s<a.length;s++){const l=a[s];if(r.has(l)){var o;r.set(l,((o=r.get(l))!=null?o:0)+1)}else r.set(l,1)}}return r},pt(e.options,"debugTable"))}function Owe(){return(e,t)=>ht(()=>{var n;return[(n=e.getColumn(t))==null?void 0:n.getFacetedRowModel()]},n=>{var r;if(!n)return;const o=(r=n.flatRows[0])==null?void 0:r.getUniqueValues(t);if(typeof o>"u")return;let i=[o,o];for(let a=0;a<n.flatRows.length;a++){const s=n.flatRows[a].getUniqueValues(t);for(let l=0;l<s.length;l++){const u=s[l];u<i[0]?i[0]=u:u>i[1]&&(i[1]=u)}}return i},pt(e.options,"debugTable"))}function Pwe(){return e=>ht(()=>[e.getState().sorting,e.getPreSortedRowModel()],(t,n)=>{if(!n.rows.length||!(t!=null&&t.length))return n;const r=e.getState().sorting,o=[],i=r.filter(l=>{var u;return(u=e.getColumn(l.id))==null?void 0:u.getCanSort()}),a={};i.forEach(l=>{const u=e.getColumn(l.id);u&&(a[l.id]={sortUndefined:u.columnDef.sortUndefined,invertSorting:u.columnDef.invertSorting,sortingFn:u.getSortingFn()})});const s=l=>{const u=l.map(d=>({...d}));return u.sort((d,h)=>{for(let m=0;m<i.length;m+=1){var p;const b=i[m],v=a[b.id],y=(p=b?.desc)!=null?p:!1;let S=0;if(v.sortUndefined){const x=d.getValue(b.id),C=h.getValue(b.id),k=x===void 0,M=C===void 0;(k||M)&&(S=k&&M?0:k?v.sortUndefined:-v.sortUndefined)}if(S===0&&(S=v.sortingFn(d,h,b.id)),S!==0)return y&&(S*=-1),v.invertSorting&&(S*=-1),S}return d.index-h.index}),u.forEach(d=>{var h;o.push(d),(h=d.subRows)!=null&&h.length&&(d.subRows=s(d.subRows))}),u};return{rows:s(n.rows),flatRows:o,rowsById:n.rowsById}},pt(e.options,"debugTable","getSortedRowModel",()=>e._autoResetPageIndex()))}function jwe(e){const t=[],n=r=>{var o;t.push(r),(o=r.subRows)!=null&&o.length&&r.getIsExpanded()&&r.subRows.forEach(n)};return e.rows.forEach(n),{rows:t,flatRows:e.flatRows,rowsById:e.rowsById}}function Lwe(e){return t=>ht(()=>[t.getState().pagination,t.getPrePaginationRowModel(),t.options.paginateExpandedRows?void 0:t.getState().expanded],(n,r)=>{if(!r.rows.length)return r;const{pageSize:o,pageIndex:i}=n;let{rows:a,flatRows:s,rowsById:l}=r;const u=o*i,d=u+o;a=a.slice(u,d);let h;t.options.paginateExpandedRows?h={rows:a,flatRows:s,rowsById:l}:h=jwe({rows:a,flatRows:s,rowsById:l}),h.flatRows=[];const p=m=>{h.flatRows.push(m),m.subRows.length&&m.subRows.forEach(p)};return h.rows.forEach(p),h},pt(t.options,"debugTable"))}function o4(e,t){return e?Rwe(e)?D.createElement(e,t):e:null}function Rwe(e){return Fwe(e)||typeof e=="function"||Hwe(e)}function Fwe(e){return typeof e=="function"&&(()=>{const t=Object.getPrototypeOf(e);return t.prototype&&t.prototype.isReactComponent})()}function Hwe(e){return typeof e=="object"&&typeof e.$$typeof=="symbol"&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}function _we(e){const t={state:{},onStateChange:()=>{},renderFallbackValue:null,...e},[n]=D.useState(()=>({current:Iwe(t)})),[r,o]=D.useState(()=>n.current.initialState);return n.current.setOptions(i=>({...i,...e,state:{...r,...e.state},onStateChange:a=>{o(a),e.onStateChange==null||e.onStateChange(a)}})),n.current}const nB={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",Ấ:"A",Ắ:"A",Ẳ:"A",Ẵ:"A",Ặ:"A",Æ:"AE",Ầ:"A",Ằ:"A",Ȃ:"A",Ç:"C",Ḉ:"C",È:"E",É:"E",Ê:"E",Ë:"E",Ế:"E",Ḗ:"E",Ề:"E",Ḕ:"E",Ḝ:"E",Ȇ:"E",Ì:"I",Í:"I",Î:"I",Ï:"I",Ḯ:"I",Ȋ:"I",Ð:"D",Ñ:"N",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",Ố:"O",Ṍ:"O",Ṓ:"O",Ȏ:"O",Ù:"U",Ú:"U",Û:"U",Ü:"U",Ý:"Y",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",ấ:"a",ắ:"a",ẳ:"a",ẵ:"a",ặ:"a",æ:"ae",ầ:"a",ằ:"a",ȃ:"a",ç:"c",ḉ:"c",è:"e",é:"e",ê:"e",ë:"e",ế:"e",ḗ:"e",ề:"e",ḕ:"e",ḝ:"e",ȇ:"e",ì:"i",í:"i",î:"i",ï:"i",ḯ:"i",ȋ:"i",ð:"d",ñ:"n",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",ố:"o",ṍ:"o",ṓ:"o",ȏ:"o",ù:"u",ú:"u",û:"u",ü:"u",ý:"y",ÿ:"y",Ā:"A",ā:"a",Ă:"A",ă:"a",Ą:"A",ą:"a",Ć:"C",ć:"c",Ĉ:"C",ĉ:"c",Ċ:"C",ċ:"c",Č:"C",č:"c",C̆:"C",c̆:"c",Ď:"D",ď:"d",Đ:"D",đ:"d",Ē:"E",ē:"e",Ĕ:"E",ĕ:"e",Ė:"E",ė:"e",Ę:"E",ę:"e",Ě:"E",ě:"e",Ĝ:"G",Ǵ:"G",ĝ:"g",ǵ:"g",Ğ:"G",ğ:"g",Ġ:"G",ġ:"g",Ģ:"G",ģ:"g",Ĥ:"H",ĥ:"h",Ħ:"H",ħ:"h",Ḫ:"H",ḫ:"h",Ĩ:"I",ĩ:"i",Ī:"I",ī:"i",Ĭ:"I",ĭ:"i",Į:"I",į:"i",İ:"I",ı:"i",IJ:"IJ",ij:"ij",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",Ḱ:"K",ḱ:"k",K̆:"K",k̆:"k",Ĺ:"L",ĺ:"l",Ļ:"L",ļ:"l",Ľ:"L",ľ:"l",Ŀ:"L",ŀ:"l",Ł:"l",ł:"l",Ḿ:"M",ḿ:"m",M̆:"M",m̆:"m",Ń:"N",ń:"n",Ņ:"N",ņ:"n",Ň:"N",ň:"n",ʼn:"n",N̆:"N",n̆:"n",Ō:"O",ō:"o",Ŏ:"O",ŏ:"o",Ő:"O",ő:"o",Œ:"OE",œ:"oe",P̆:"P",p̆:"p",Ŕ:"R",ŕ:"r",Ŗ:"R",ŗ:"r",Ř:"R",ř:"r",R̆:"R",r̆:"r",Ȓ:"R",ȓ:"r",Ś:"S",ś:"s",Ŝ:"S",ŝ:"s",Ş:"S",Ș:"S",ș:"s",ş:"s",Š:"S",š:"s",Ţ:"T",ţ:"t",ț:"t",Ț:"T",Ť:"T",ť:"t",Ŧ:"T",ŧ:"t",T̆:"T",t̆:"t",Ũ:"U",ũ:"u",Ū:"U",ū:"u",Ŭ:"U",ŭ:"u",Ů:"U",ů:"u",Ű:"U",ű:"u",Ų:"U",ų:"u",Ȗ:"U",ȗ:"u",V̆:"V",v̆:"v",Ŵ:"W",ŵ:"w",Ẃ:"W",ẃ:"w",X̆:"X",x̆:"x",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Y̆:"Y",y̆:"y",Ź:"Z",ź:"z",Ż:"Z",ż:"z",Ž:"Z",ž:"z",ſ:"s",ƒ:"f",Ơ:"O",ơ:"o",Ư:"U",ư:"u",Ǎ:"A",ǎ:"a",Ǐ:"I",ǐ:"i",Ǒ:"O",ǒ:"o",Ǔ:"U",ǔ:"u",Ǖ:"U",ǖ:"u",Ǘ:"U",ǘ:"u",Ǚ:"U",ǚ:"u",Ǜ:"U",ǜ:"u",Ứ:"U",ứ:"u",Ṹ:"U",ṹ:"u",Ǻ:"A",ǻ:"a",Ǽ:"AE",ǽ:"ae",Ǿ:"O",ǿ:"o",Þ:"TH",þ:"th",Ṕ:"P",ṕ:"p",Ṥ:"S",ṥ:"s",X́:"X",x́:"x",Ѓ:"Г",ѓ:"г",Ќ:"К",ќ:"к",A̋:"A",a̋:"a",E̋:"E",e̋:"e",I̋:"I",i̋:"i",Ǹ:"N",ǹ:"n",Ồ:"O",ồ:"o",Ṑ:"O",ṑ:"o",Ừ:"U",ừ:"u",Ẁ:"W",ẁ:"w",Ỳ:"Y",ỳ:"y",Ȁ:"A",ȁ:"a",Ȅ:"E",ȅ:"e",Ȉ:"I",ȉ:"i",Ȍ:"O",ȍ:"o",Ȑ:"R",ȑ:"r",Ȕ:"U",ȕ:"u",B̌:"B",b̌:"b",Č̣:"C",č̣:"c",Ê̌:"E",ê̌:"e",F̌:"F",f̌:"f",Ǧ:"G",ǧ:"g",Ȟ:"H",ȟ:"h",J̌:"J",ǰ:"j",Ǩ:"K",ǩ:"k",M̌:"M",m̌:"m",P̌:"P",p̌:"p",Q̌:"Q",q̌:"q",Ř̩:"R",ř̩:"r",Ṧ:"S",ṧ:"s",V̌:"V",v̌:"v",W̌:"W",w̌:"w",X̌:"X",x̌:"x",Y̌:"Y",y̌:"y",A̧:"A",a̧:"a",B̧:"B",b̧:"b",Ḑ:"D",ḑ:"d",Ȩ:"E",ȩ:"e",Ɛ̧:"E",ɛ̧:"e",Ḩ:"H",ḩ:"h",I̧:"I",i̧:"i",Ɨ̧:"I",ɨ̧:"i",M̧:"M",m̧:"m",O̧:"O",o̧:"o",Q̧:"Q",q̧:"q",U̧:"U",u̧:"u",X̧:"X",x̧:"x",Z̧:"Z",z̧:"z"},Bwe=Object.keys(nB).join("|"),Ywe=new RegExp(Bwe,"g");function Uwe(e){return e.replace(Ywe,t=>nB[t])}const Ro={CASE_SENSITIVE_EQUAL:7,EQUAL:6,STARTS_WITH:5,WORD_STARTS_WITH:4,CONTAINS:3,ACRONYM:2,MATCHES:1,NO_MATCH:0};function zwe(e,t,n){var r;if(n=n||{},n.threshold=(r=n.threshold)!=null?r:Ro.MATCHES,!n.accessors){const a=i4(e,t,n);return{rankedValue:e,rank:a,accessorIndex:-1,accessorThreshold:n.threshold,passed:a>=n.threshold}}const o=$we(e,n.accessors),i={rankedValue:e,rank:Ro.NO_MATCH,accessorIndex:-1,accessorThreshold:n.threshold,passed:!1};for(let a=0;a<o.length;a++){const s=o[a];let l=i4(s.itemValue,t,n);const{minRanking:u,maxRanking:d,threshold:h=n.threshold}=s.attributes;l<u&&l>=Ro.MATCHES?l=u:l>d&&(l=d),l=Math.min(l,d),l>=h&&l>i.rank&&(i.rank=l,i.passed=!0,i.accessorIndex=a,i.accessorThreshold=h,i.rankedValue=s.itemValue)}return i}function i4(e,t,n){return e=a4(e,n),t=a4(t,n),t.length>e.length?Ro.NO_MATCH:e===t?Ro.CASE_SENSITIVE_EQUAL:(e=e.toLowerCase(),t=t.toLowerCase(),e===t?Ro.EQUAL:e.startsWith(t)?Ro.STARTS_WITH:e.includes(` ${t}`)?Ro.WORD_STARTS_WITH:e.includes(t)?Ro.CONTAINS:t.length===1?Ro.NO_MATCH:Vwe(e).includes(t)?Ro.ACRONYM:Wwe(e,t))}function Vwe(e){let t="";return e.split(" ").forEach(r=>{r.split("-").forEach(i=>{t+=i.substr(0,1)})}),t}function Wwe(e,t){let n=0,r=0;function o(l,u,d){for(let h=d,p=u.length;h<p;h++)if(u[h]===l)return n+=1,h+1;return-1}function i(l){const u=1/l,d=n/t.length;return Ro.MATCHES+d*u}const a=o(t[0],e,0);if(a<0)return Ro.NO_MATCH;r=a;for(let l=1,u=t.length;l<u;l++){const d=t[l];if(r=o(d,e,r),!(r>-1))return Ro.NO_MATCH}const s=r-a;return i(s)}function Gwe(e,t){return e.rank===t.rank?0:e.rank>t.rank?-1:1}function a4(e,t){let{keepDiacritics:n}=t;return e=`${e}`,n||(e=Uwe(e)),e}function Zwe(e,t){let n=t;typeof t=="object"&&(n=t.accessor);const r=n(e);return r==null?[]:Array.isArray(r)?r:[String(r)]}function $we(e,t){const n=[];for(let r=0,o=t.length;r<o;r++){const i=t[r],a=qwe(i),s=Zwe(e,i);for(let l=0,u=s.length;l<u;l++)n.push({itemValue:s[l],attributes:a})}return n}const s4={maxRanking:1/0,minRanking:-1/0};function qwe(e){return typeof e=="function"?s4:{...s4,...e}}var Kwe={fieldSeparator:",",decimalSeparator:".",quoteStrings:!0,quoteCharacter:'"',showTitle:!1,title:"My Generated Report",filename:"generated",showColumnHeaders:!0,useTextFile:!1,useBom:!0,columnHeaders:[],useKeysAsHeaders:!1,boolDisplay:{true:"TRUE",false:"FALSE"},replaceUndefinedWith:""},Xwe=`\r
|
|
|
`,Jwe="\uFEFF",rB=e=>Object.assign({},Kwe,e);let Qwe=class extends Error{constructor(t){super(t),this.name="CsvGenerationError"}},eSe=class extends Error{constructor(t){super(t),this.name="EmptyHeadersError"}};var gv=e=>e,ya=e=>e,zS=gv,Nf=gv,l4=gv,c4=gv,tSe=function(e,t){return t=='"'&&e.indexOf('"')>-1?e.replace(/"/g,'""'):e},nSe=e=>l4(typeof e=="object"?e.key:e),rSe=e=>c4(typeof e=="object"?e.displayLabel:e),oSe=(e,...t)=>t.reduce((n,r)=>r(n),e),iSe=e=>t=>e.useBom?zS(ya(t)+Jwe):t,aSe=e=>t=>e.showTitle?$D(zS(ya(t)+e.title))(Nf("")):t,$D=e=>t=>zS(ya(e)+ya(t)+Xwe),oB=e=>(t,n)=>sSe(e)(Nf(t+n)),sSe=e=>t=>gv(ya(t)+e.fieldSeparator),lSe=(e,t)=>n=>{if(!e.showColumnHeaders)return n;if(t.length<1)throw new eSe("Option to show headers but none supplied. Make sure there are keys in your collection or that you've supplied headers through the config options.");let r=Nf("");for(let o=0;o<t.length;o++){const i=rSe(t[o]);r=oB(e)(r,iB(e,i))}return r=Nf(ya(r).slice(0,-1)),$D(n)(r)},cSe=(e,t,n)=>r=>{let o=r;for(var i=0;i<n.length;i++){let a=Nf("");for(let s=0;s<t.length;s++){const l=nSe(t[s]),u=typeof n[i][ya(l)]>"u"?e.replaceUndefinedWith:n[i][ya(l)];a=oB(e)(a,iB(e,u))}a=Nf(ya(a).slice(0,-1)),o=$D(o)(a)}return o},uSe=ya,u4=e=>+e===e&&(!isFinite(e)||!!(e%1)),iB=(e,t)=>{if(e.decimalSeparator==="locale"&&u4(t))return t.toLocaleString();if(e.decimalSeparator!=="."&&u4(t))return t.toString().replace(".",e.decimalSeparator);if(typeof t=="string"){let n=t;return(e.quoteStrings||e.fieldSeparator&&t.indexOf(e.fieldSeparator)>-1||e.quoteCharacter&&t.indexOf(e.quoteCharacter)>-1||t.indexOf(`
|
|
|
`)>-1||t.indexOf("\r")>-1)&&(n=e.quoteCharacter+tSe(t,e.quoteCharacter)+e.quoteCharacter),n}if(typeof t=="boolean"&&e.boolDisplay){const n=t?"true":"false";return e.boolDisplay[n]}return t},dSe=e=>t=>{const n=rB(e),r=n.useKeysAsHeaders?Object.keys(t[0]):n.columnHeaders;let o=oSe(zS(""),iSe(n),aSe(n),lSe(n,r),cSe(n,r,t));if(ya(o).length<1)throw new Qwe("Output is empty. Is your data formatted correctly?");return o};const fSe=({thino:e})=>{const t=D.useRef(null);D.useEffect(()=>(t.current&&N.setIcon(t.current,"pin"),()=>{t.current&&(t.current=null)}),[t]);const n=D.useCallback(async()=>{e.pinned?await de.unpinMemoById(e.id):await de.pinMemoById(e.id)},[e]);return w.jsx("span",{ref:t,className:tn("pinned-status",e.pinned?"pinned":"not-pinned"),onClick:n})},hSe=({thino:e})=>{const t=D.useRef(null);D.useEffect(()=>(t.current&&N.setIcon(t.current,e.thinoType==="JOURNAL"?"calendar":"check-square"),()=>{t.current&&(t.current=null)}),[t,e?.thinoType]);const n=D.useCallback(async()=>{if(e.thinoType==="JOURNAL")return;const r=await de.updateMemo(e.id,e.content,e.thinoType==="TASK-TODO"?"TASK-DONE":"TASK-TODO");r&&de.editMemo(r)},[e]);return w.jsx(w.Fragment,{children:e.thinoType!=="JOURNAL"?w.jsx("input",{className:tn("thino-type-status","task-list-item-checkbox"),type:"checkbox",checked:e.thinoType!=="TASK-TODO","data-task":e.thinoType==="TASK-TODO"?"":e.thinoType==="TASK-DONE"?"x":e.thinoType?.slice(5),onClick:n}):w.jsx("span",{ref:t,className:"thino-type-status"})})},pSe=({id:e,path:t})=>{const n=D.useRef(null);D.useEffect(()=>(n.current&&N.setIcon(n.current,"link"),()=>{n.current&&(n.current=null)}),[]);const r=D.useCallback(()=>{!e||!t||de.openThinoByID(e)},[e,t]);return w.jsxs("span",{className:"source-thino",onClick:r,children:[w.jsx("span",{children:t}),w.jsx("span",{ref:n,className:"source-thino-icon"})]})},mSe=({id:e,sourceType:t})=>{const n=D.useRef(null);D.useEffect(()=>(n.current&&N.setIcon(n.current,Pm.find(o=>o.title===t)?.icon||"list"),()=>{n.current&&(n.current=null)}),[]);const r=D.useCallback(async()=>{e&&await de.openThinoByID(e)},[e]);return w.jsx("span",{ref:n,className:"source-type-icon",onClick:r})},d4=(e,t,n,r)=>{const o=zwe(e.getValue(t),n);return r({itemRank:o}),o.passed},f4=(e,t,n)=>{let r=0;return e.columnFiltersMeta[n]&&(r=Gwe(e.columnFiltersMeta[n]?.itemRank,t.columnFiltersMeta[n]?.itemRank)),r===0?tf.alphanumeric(e,t,n):r},gSe=rB({fieldSeparator:",",decimalSeparator:".",useKeysAsHeaders:!0}),vSe=e=>e+`
|
|
|
`;function ySe({thinos:e,isFiltering:t}){Y.useReducer(()=>({}),{})[1];const[n,r]=Y.useState([]),[o,i]=Y.useState(""),a=Y.useMemo(()=>[{header:E("Basic Info"),footer:m=>m.column.id,columns:[{accessorKey:"createdAt",header:()=>w.jsx("span",{className:"create-at-header-cell",children:E("Created At")}),cell:m=>m.getValue(),footer:m=>m.column.id,enableColumnFilter:!1},{accessorFn:m=>m.content,id:"content",header:()=>w.jsx("span",{className:"thino-header-cell",children:E("Thino")}),cell:m=>w.jsx(vo,{memo:m.row.original,type:"table"}),footer:m=>m.column.id,filterFn:"fuzzy",sortingFn:f4},{accessorFn:m=>m.thinoType,id:"thinoType",cell:m=>w.jsx(hSe,{thino:m.row.original}),header:()=>w.jsx("span",{children:E("Thino Type")}),footer:m=>m.column.id},{accessorFn:m=>m.sourceType,id:"sourceType",cell:m=>w.jsx(mSe,{id:m.row.original.id,sourceType:m.getValue()}),header:()=>w.jsx("span",{children:E("Source Type")}),footer:m=>m.column.id}]},{header:E("Additional Info"),footer:m=>m.column.id,columns:[{accessorKey:"pinned",header:()=>w.jsx("span",{children:E("Pinned Status")}),cell:m=>w.jsx(fSe,{thino:m.row.original}),footer:m=>m.column.id,filterFn:"fuzzy",sortingFn:f4},{accessorKey:"rowStatus",header:()=>w.jsx("span",{children:E("Row status")}),cell:m=>w.jsx("span",{children:m.getValue()==="NORMAL"?"":m.getValue()}),footer:m=>m.column.id},{accessorKey:"path",header:()=>E("Path"),cell:m=>w.jsx(pSe,{id:m.row.original.id,path:m.getValue()}),footer:m=>m.column.id}]}],[]),[s,l]=Y.useState(()=>e),u=()=>l(m=>e);D.useEffect(()=>{u()},[e]);const d=_we({data:s,columns:a,filterFns:{fuzzy:d4},initialState:{pagination:{pageSize:20}},state:{columnFilters:n,globalFilter:o},onColumnFiltersChange:r,onGlobalFilterChange:i,globalFilterFn:d4,getCoreRowModel:Ewe(),getFilteredRowModel:Dwe(),getSortedRowModel:Pwe(),getPaginationRowModel:Lwe(),getFacetedRowModel:Awe(),getFacetedUniqueValues:Nwe(),getFacetedMinMaxValues:Owe(),debugTable:!1,debugHeaders:!1,debugColumns:!1});Y.useEffect(()=>{d.getState().columnFilters[0]?.id==="createdAt"&&d.getState().sorting[0]?.id!=="createdAt"&&d.setSorting([{id:"createdAt",desc:!1}])},[d.getState().columnFilters[0]?.id]);async function h(m,b){const v=E("Created At"),y=E("Updated At"),S=E("Content"),x=E("Path"),C=m.map(R=>({[v]:R.createdAt,[y]:R.updatedAt,[S]:R.content,Thino:`=hyperlink("obsidian://thino?openId=${R.id}","${R.id}")`,[x]:`=hyperlink("obsidian://open?path=${N.normalizePath(R.path)},"${R.path}")`})),k=dSe(gSe)(C),M=$e.getState().app||window.app,I=vSe(uSe(k));return{file:await M.vault.create(`${b}-${Le.randomId(6)}.csv`,I),app:M}}async function p(m){const{file:b,app:v}=await h(m.map(x=>x.original),"thino-export"),y=document.createDocumentFragment(),S=y.createEl("div",{cls:"export-file-btn-group"});y.createEl("div",{cls:"open-file-button"}),new N.Setting(S).setName(E("Exported CSV file")).addButton(x=>{x.setButtonText(E("Open File")).onClick(()=>{const C=N.normalizePath(b.path);v.openWithDefaultApp(C)})}),new N.Notice(y)}return w.jsxs("div",{className:"table-view",children:[w.jsxs("div",{children:[w.jsx(Kb,{value:o||"",onChange:m=>i(String(m)),className:"table-search-bar",placeholder:E("Search all columns...")}),N.Platform.isDesktop&&(o||n.length>0||t)&&w.jsx("button",{className:"mod-cta",disabled:d.getPrePaginationRowModel().rows.length===0,onClick:()=>p(d.getPrePaginationRowModel().rows),children:E("Export to CSV")})]}),w.jsxs("table",{className:"thino-table",children:[w.jsx("thead",{children:d.getHeaderGroups().map(m=>w.jsx("tr",{children:m.headers.map(b=>w.jsx("th",{colSpan:b.colSpan,children:b.isPlaceholder?null:w.jsxs(w.Fragment,{children:[w.jsxs("div",{className:tn(b.column.getCanSort()?"filter-header":"","table-header",b.column.id==="content"?"content-header":""),onClick:b.column.getToggleSortingHandler(),children:[o4(b.column.columnDef.header,b.getContext()),{asc:" 🔼",desc:" 🔽"}[b.column.getIsSorted()]??null]}),b.column.getCanFilter()?w.jsx(wSe,{column:b.column,table:d}):null]})},b.id))},m.id))}),w.jsx("tbody",{children:d.getRowModel().rows.map(m=>w.jsx("tr",{className:tn(m.getValue("pinned")?"pinned":""),children:m.getVisibleCells().map(b=>w.jsx("td",{children:o4(b.column.columnDef.cell,b.getContext())},b.id))},m.id))})]}),w.jsxs("div",{className:"table-nav-bar",children:[w.jsx("button",{className:"prev-start-btn",onClick:()=>d.setPageIndex(0),disabled:!d.getCanPreviousPage(),children:"<<"}),w.jsx("button",{className:"prev-btn",onClick:()=>d.previousPage(),disabled:!d.getCanPreviousPage(),children:"<"}),w.jsx("button",{className:"next-btn",onClick:()=>d.nextPage(),disabled:!d.getCanNextPage(),children:">"}),w.jsx("button",{className:"next-end-btn",onClick:()=>d.setPageIndex(d.getPageCount()-1),disabled:!d.getCanNextPage(),children:">>"}),w.jsxs("span",{className:"table-page-info",children:[w.jsx("div",{children:E("Page")}),w.jsxs("strong",{children:[d.getState().pagination.pageIndex+1," of ",d.getPageCount()]})]}),w.jsxs("span",{className:"table-page-jump",children:["| ",E("Go to page"),":",w.jsx("input",{type:"number",defaultValue:d.getState().pagination.pageIndex+1,onChange:m=>{const b=m.target.value?Number(m.target.value)-1:0;d.setPageIndex(b)},className:"jump-inputer"})]}),w.jsx("select",{value:d.getState().pagination.pageSize,onChange:m=>{d.setPageSize(Number(m.target.value))},children:[10,20,30,40,50].map(m=>w.jsxs("option",{value:m,children:[E("Show")," ",m," ",E("rows")]},m))})]})]})}const bSe=e=>e==="sourceType"?["ALL"]:["ALL","ALL-TASK"];function wSe({column:e,table:t}){const n=t.getPreFilteredRowModel().flatRows[0]?.getValue(e.id),r=e.getFilterValue(),o=Y.useMemo(()=>typeof n=="number"?[]:Array.from(e.getFacetedUniqueValues().keys()).sort(),[e.getFacetedUniqueValues()]);return typeof n=="number"?w.jsx("div",{children:w.jsxs("div",{className:"filter-input-group",children:[w.jsx(Kb,{type:"number",min:Number(e.getFacetedMinMaxValues()?.[0]??""),max:Number(e.getFacetedMinMaxValues()?.[1]??""),value:r?.[0]??"",onChange:i=>e.setFilterValue(a=>[i,a?.[1]]),placeholder:`Min ${e.getFacetedMinMaxValues()?.[0]?`(${e.getFacetedMinMaxValues()?.[0]})`:""}`,className:"filter-input-short"}),w.jsx(Kb,{type:"number",min:Number(e.getFacetedMinMaxValues()?.[0]??""),max:Number(e.getFacetedMinMaxValues()?.[1]??""),value:r?.[1]??"",onChange:i=>e.setFilterValue(a=>[a?.[0],i]),placeholder:`Max ${e.getFacetedMinMaxValues()?.[1]?`(${e.getFacetedMinMaxValues()?.[1]})`:""}`,className:"filter-input-short"})]})}):w.jsx(w.Fragment,{children:o.length>1?w.jsxs(w.Fragment,{children:[e.id!=="path"&&e.id!=="content"&&e.id!=="thinoType"&&e.id!=="sourceType"&&w.jsx("datalist",{id:e.id+"list",children:o.slice(0,5e3).map(i=>w.jsx("option",{value:i},i))}),e.id==="thinoType"||e.id==="sourceType"?w.jsx("select",{id:e.id,onChange:i=>e.setFilterValue(i.target.value==="ALL"?"":i.target.value==="ALL-TASK"?"TASK":i.target.value),children:[...bSe(e.id),...o].map(i=>w.jsx("option",{value:i,children:E(i)||i},i))}):"",e.id!=="thinoType"&&e.id!=="sourceType"?w.jsx(Kb,{type:"text",value:r??"",onChange:i=>e.setFilterValue(i),placeholder:`Search... (${e.getFacetedUniqueValues().size})`,className:"filter-input-long",list:e.id+"list"}):""]}):""})}function Kb({value:e,onChange:t,debounce:n=500,...r}){const[o,i]=Y.useState(e);return Y.useEffect(()=>{i(e)},[e]),Y.useEffect(()=>{const a=setTimeout(()=>{t(o)},n);return()=>clearTimeout(a)},[o]),w.jsx("input",{...r,value:o,onChange:a=>i(a.target.value)})}function SSe(e,t){try{var n=global,r=n.document;if(typeof r<"u"&&r.createElement&&r.head&&r.head.appendChild){var o=r.querySelector('html meta[name="'.concat(encodeURI(e),'"]'))||r.createElement("meta");o.setAttribute("name",e),o.setAttribute("content",t),r.head.appendChild(o)}}catch{}}function TSe(){SSe("react-scroll-to-bottom:version","4.2.0")}var jp=function(e){return e&&e.Math===Math&&e},_r=jp(typeof globalThis=="object"&&globalThis)||jp(typeof window=="object"&&window)||jp(typeof self=="object"&&self)||jp(typeof xr=="object"&&xr)||jp(typeof xr=="object"&&xr)||function(){return this}()||Function("return this")(),hr=function(e){try{return!!e()}catch{return!0}},xSe=hr,VS=!xSe(function(){var e=function(){}.bind();return typeof e!="function"||e.hasOwnProperty("prototype")}),ISe=VS,aB=Function.prototype,h4=aB.apply,p4=aB.call,qD=typeof Reflect=="object"&&Reflect.apply||(ISe?p4.bind(h4):function(){return p4.apply(h4,arguments)}),sB=VS,lB=Function.prototype,xE=lB.call,kSe=sB&&lB.bind.bind(xE,xE),pr=sB?kSe:function(e){return function(){return xE.apply(e,arguments)}},cB=pr,ESe=cB({}.toString),CSe=cB("".slice),Oh=function(e){return CSe(ESe(e),8,-1)},MSe=Oh,DSe=pr,KD=function(e){if(MSe(e)==="Function")return DSe(e)},cI=typeof document=="object"&&document.all,oo=typeof cI>"u"&&cI!==void 0?function(e){return typeof e=="function"||e===cI}:function(e){return typeof e=="function"},vv={},ASe=hr,Zo=!ASe(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7}),NSe=VS,ab=Function.prototype.call,Is=NSe?ab.bind(ab):function(){return ab.apply(ab,arguments)},XD={},uB={}.propertyIsEnumerable,dB=Object.getOwnPropertyDescriptor,OSe=dB&&!uB.call({1:2},1);XD.f=OSe?function(t){var n=dB(this,t);return!!n&&n.enumerable}:uB;var yv=function(e,t){return{enumerable:!(e&1),configurable:!(e&2),writable:!(e&4),value:t}},PSe=pr,jSe=hr,LSe=Oh,uI=Object,RSe=PSe("".split),fB=jSe(function(){return!uI("z").propertyIsEnumerable(0)})?function(e){return LSe(e)==="String"?RSe(e,""):uI(e)}:uI,JD=function(e){return e==null},FSe=JD,HSe=TypeError,QD=function(e){if(FSe(e))throw new HSe("Can't call method on "+e);return e},_Se=fB,BSe=QD,ks=function(e){return _Se(BSe(e))},YSe=oo,Cl=function(e){return typeof e=="object"?e!==null:YSe(e)},Br={},dI=Br,fI=_r,USe=oo,m4=function(e){return USe(e)?e:void 0},Es=function(e,t){return arguments.length<2?m4(dI[e])||m4(fI[e]):dI[e]&&dI[e][t]||fI[e]&&fI[e][t]},zSe=pr,Ml=zSe({}.isPrototypeOf),hB=typeof navigator<"u"&&String(navigator.userAgent)||"",pB=_r,hI=hB,g4=pB.process,v4=pB.Deno,y4=g4&&g4.versions||v4&&v4.version,b4=y4&&y4.v8,ua,B0;b4&&(ua=b4.split("."),B0=ua[0]>0&&ua[0]<4?1:+(ua[0]+ua[1]));!B0&&hI&&(ua=hI.match(/Edge\/(\d+)/),(!ua||ua[1]>=74)&&(ua=hI.match(/Chrome\/(\d+)/),ua&&(B0=+ua[1])));var e2=B0,w4=e2,VSe=hr,WSe=_r,GSe=WSe.String,Ph=!!Object.getOwnPropertySymbols&&!VSe(function(){var e=Symbol("symbol detection");return!GSe(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&w4&&w4<41}),ZSe=Ph,mB=ZSe&&!Symbol.sham&&typeof Symbol.iterator=="symbol",$Se=Es,qSe=oo,KSe=Ml,XSe=mB,JSe=Object,bv=XSe?function(e){return typeof e=="symbol"}:function(e){var t=$Se("Symbol");return qSe(t)&&KSe(t.prototype,JSe(e))},QSe=String,WS=function(e){try{return QSe(e)}catch{return"Object"}},eTe=oo,tTe=WS,nTe=TypeError,t2=function(e){if(eTe(e))return e;throw new nTe(tTe(e)+" is not a function")},rTe=t2,oTe=JD,n2=function(e,t){var n=e[t];return oTe(n)?void 0:rTe(n)},pI=Is,mI=oo,gI=Cl,iTe=TypeError,aTe=function(e,t){var n,r;if(t==="string"&&mI(n=e.toString)&&!gI(r=pI(n,e))||mI(n=e.valueOf)&&!gI(r=pI(n,e))||t!=="string"&&mI(n=e.toString)&&!gI(r=pI(n,e)))return r;throw new iTe("Can't convert object to primitive value")},gB={exports:{}},S4=_r,sTe=Object.defineProperty,lTe=function(e,t){try{sTe(S4,e,{value:t,configurable:!0,writable:!0})}catch{S4[e]=t}return t},cTe=_r,uTe=lTe,T4="__core-js_shared__",x4=gB.exports=cTe[T4]||uTe(T4,{});(x4.versions||(x4.versions=[])).push({version:"3.37.0",mode:"pure",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.37.0/LICENSE",source:"https://github.com/zloirock/core-js"});var r2=gB.exports,I4=r2,jh=function(e,t){return I4[e]||(I4[e]=t||{})},dTe=QD,fTe=Object,Dl=function(e){return fTe(dTe(e))},hTe=pr,pTe=Dl,mTe=hTe({}.hasOwnProperty),vi=Object.hasOwn||function(t,n){return mTe(pTe(t),n)},gTe=pr,vTe=0,yTe=Math.random(),bTe=gTe(1 .toString),o2=function(e){return"Symbol("+(e===void 0?"":e)+")_"+bTe(++vTe+yTe,36)},wTe=_r,STe=jh,k4=vi,TTe=o2,xTe=Ph,ITe=mB,of=wTe.Symbol,vI=STe("wks"),kTe=ITe?of.for||of:of&&of.withoutSetter||TTe,Er=function(e){return k4(vI,e)||(vI[e]=xTe&&k4(of,e)?of[e]:kTe("Symbol."+e)),vI[e]},ETe=Is,E4=Cl,C4=bv,CTe=n2,MTe=aTe,DTe=Er,ATe=TypeError,NTe=DTe("toPrimitive"),OTe=function(e,t){if(!E4(e)||C4(e))return e;var n=CTe(e,NTe),r;if(n){if(t===void 0&&(t="default"),r=ETe(n,e,t),!E4(r)||C4(r))return r;throw new ATe("Can't convert object to primitive value")}return t===void 0&&(t="number"),MTe(e,t)},PTe=OTe,jTe=bv,i2=function(e){var t=PTe(e,"string");return jTe(t)?t:t+""},LTe=_r,M4=Cl,IE=LTe.document,RTe=M4(IE)&&M4(IE.createElement),vB=function(e){return RTe?IE.createElement(e):{}},FTe=Zo,HTe=hr,_Te=vB,yB=!FTe&&!HTe(function(){return Object.defineProperty(_Te("div"),"a",{get:function(){return 7}}).a!==7}),BTe=Zo,YTe=Is,UTe=XD,zTe=yv,VTe=ks,WTe=i2,GTe=vi,ZTe=yB,D4=Object.getOwnPropertyDescriptor;vv.f=BTe?D4:function(t,n){if(t=VTe(t),n=WTe(n),ZTe)try{return D4(t,n)}catch{}if(GTe(t,n))return zTe(!YTe(UTe.f,t,n),t[n])};var $Te=hr,qTe=oo,KTe=/#|\.prototype\./,wv=function(e,t){var n=JTe[XTe(e)];return n===e1e?!0:n===QTe?!1:qTe(t)?$Te(t):!!t},XTe=wv.normalize=function(e){return String(e).replace(KTe,".").toLowerCase()},JTe=wv.data={},QTe=wv.NATIVE="N",e1e=wv.POLYFILL="P",t1e=wv,A4=KD,n1e=t2,r1e=VS,o1e=A4(A4.bind),a2=function(e,t){return n1e(e),t===void 0?e:r1e?o1e(e,t):function(){return e.apply(t,arguments)}},Ia={},i1e=Zo,a1e=hr,bB=i1e&&a1e(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42}),s1e=Cl,l1e=String,c1e=TypeError,Ec=function(e){if(s1e(e))return e;throw new c1e(l1e(e)+" is not an object")},u1e=Zo,d1e=yB,f1e=bB,sb=Ec,N4=i2,h1e=TypeError,yI=Object.defineProperty,p1e=Object.getOwnPropertyDescriptor,bI="enumerable",wI="configurable",SI="writable";Ia.f=u1e?f1e?function(t,n,r){if(sb(t),n=N4(n),sb(r),typeof t=="function"&&n==="prototype"&&"value"in r&&SI in r&&!r[SI]){var o=p1e(t,n);o&&o[SI]&&(t[n]=r.value,r={configurable:wI in r?r[wI]:o[wI],enumerable:bI in r?r[bI]:o[bI],writable:!1})}return yI(t,n,r)}:yI:function(t,n,r){if(sb(t),n=N4(n),sb(r),d1e)try{return yI(t,n,r)}catch{}if("get"in r||"set"in r)throw new h1e("Accessors not supported");return"value"in r&&(t[n]=r.value),t};var m1e=Zo,g1e=Ia,v1e=yv,GS=m1e?function(e,t,n){return g1e.f(e,t,v1e(1,n))}:function(e,t,n){return e[t]=n,e},Lp=_r,y1e=qD,b1e=KD,w1e=oo,S1e=vv.f,T1e=t1e,Vd=Br,x1e=a2,Wd=GS,O4=vi,I1e=function(e){var t=function(n,r,o){if(this instanceof t){switch(arguments.length){case 0:return new e;case 1:return new e(n);case 2:return new e(n,r)}return new e(n,r,o)}return y1e(e,this,arguments)};return t.prototype=e.prototype,t},dn=function(e,t){var n=e.target,r=e.global,o=e.stat,i=e.proto,a=r?Lp:o?Lp[n]:Lp[n]&&Lp[n].prototype,s=r?Vd:Vd[n]||Wd(Vd,n,{})[n],l=s.prototype,u,d,h,p,m,b,v,y,S;for(p in t)u=T1e(r?p:n+(o?".":"#")+p,e.forced),d=!u&&a&&O4(a,p),b=s[p],d&&(e.dontCallGetSet?(S=S1e(a,p),v=S&&S.value):v=a[p]),m=d&&v?v:t[p],!(!u&&!i&&typeof b==typeof m)&&(e.bind&&d?y=x1e(m,Lp):e.wrap&&d?y=I1e(m):i&&w1e(m)?y=b1e(m):y=m,(e.sham||m&&m.sham||b&&b.sham)&&Wd(y,"sham",!0),Wd(s,p,y),i&&(h=n+"Prototype",O4(Vd,h)||Wd(Vd,h,{}),Wd(Vd[h],p,m),e.real&&l&&(u||!l[p])&&Wd(l,p,m)))},k1e=Oh,Lh=Array.isArray||function(t){return k1e(t)==="Array"},E1e=dn,C1e=Lh;E1e({target:"Array",stat:!0},{isArray:C1e});var M1e=Br,D1e=M1e.Array.isArray,A1e=D1e,wB=A1e,N1e=wB,O1e=N1e,P1e=O1e,j1e=P1e,L1e=j1e;const SB=tt(L1e);function R1e(e){if(SB(e))return e}var F1e=Math.ceil,H1e=Math.floor,_1e=Math.trunc||function(t){var n=+t;return(n>0?H1e:F1e)(n)},B1e=_1e,ZS=function(e){var t=+e;return t!==t||t===0?0:B1e(t)},Y1e=ZS,U1e=Math.min,z1e=function(e){var t=Y1e(e);return t>0?U1e(t,9007199254740991):0},V1e=z1e,nd=function(e){return V1e(e.length)},W1e=TypeError,G1e=9007199254740991,s2=function(e){if(e>G1e)throw W1e("Maximum allowed index exceeded");return e},Z1e=Zo,$1e=Ia,q1e=yv,Sv=function(e,t,n){Z1e?$1e.f(e,t,q1e(0,n)):e[t]=n},K1e=Er,X1e=K1e("toStringTag"),TB={};TB[X1e]="z";var l2=String(TB)==="[object z]",J1e=l2,Q1e=oo,Xb=Oh,exe=Er,txe=exe("toStringTag"),nxe=Object,rxe=Xb(function(){return arguments}())==="Arguments",oxe=function(e,t){try{return e[t]}catch{}},Tv=J1e?Xb:function(e){var t,n,r;return e===void 0?"Undefined":e===null?"Null":typeof(n=oxe(t=nxe(e),txe))=="string"?n:rxe?Xb(t):(r=Xb(t))==="Object"&&Q1e(t.callee)?"Arguments":r},ixe=pr,axe=oo,kE=r2,sxe=ixe(Function.toString);axe(kE.inspectSource)||(kE.inspectSource=function(e){return sxe(e)});var lxe=kE.inspectSource,cxe=pr,uxe=hr,xB=oo,dxe=Tv,fxe=Es,hxe=lxe,IB=function(){},kB=fxe("Reflect","construct"),c2=/^\s*(?:class|function)\b/,pxe=cxe(c2.exec),mxe=!c2.test(IB),Rp=function(t){if(!xB(t))return!1;try{return kB(IB,[],t),!0}catch{return!1}},EB=function(t){if(!xB(t))return!1;switch(dxe(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return mxe||!!pxe(c2,hxe(t))}catch{return!0}};EB.sham=!0;var u2=!kB||uxe(function(){var e;return Rp(Rp.call)||!Rp(Object)||!Rp(function(){e=!0})||e})?EB:Rp,P4=Lh,gxe=u2,vxe=Cl,yxe=Er,bxe=yxe("species"),j4=Array,wxe=function(e){var t;return P4(e)&&(t=e.constructor,gxe(t)&&(t===j4||P4(t.prototype))?t=void 0:vxe(t)&&(t=t[bxe],t===null&&(t=void 0))),t===void 0?j4:t},Sxe=wxe,d2=function(e,t){return new(Sxe(e))(t===0?0:t)},Txe=hr,xxe=Er,Ixe=e2,kxe=xxe("species"),$S=function(e){return Ixe>=51||!Txe(function(){var t=[],n=t.constructor={};return n[kxe]=function(){return{foo:1}},t[e](Boolean).foo!==1})},Exe=dn,Cxe=hr,Mxe=Lh,Dxe=Cl,Axe=Dl,Nxe=nd,L4=s2,R4=Sv,Oxe=d2,Pxe=$S,jxe=Er,Lxe=e2,CB=jxe("isConcatSpreadable"),Rxe=Lxe>=51||!Cxe(function(){var e=[];return e[CB]=!1,e.concat()[0]!==e}),Fxe=function(e){if(!Dxe(e))return!1;var t=e[CB];return t!==void 0?!!t:Mxe(e)},Hxe=!Rxe||!Pxe("concat");Exe({target:"Array",proto:!0,arity:1,forced:Hxe},{concat:function(t){var n=Axe(this),r=Oxe(n,0),o=0,i,a,s,l,u;for(i=-1,s=arguments.length;i<s;i++)if(u=i===-1?n:arguments[i],Fxe(u))for(l=Nxe(u),L4(o+l),a=0;a<l;a++,o++)a in u&&R4(r,o,u[a]);else L4(o+1),R4(r,o++,u);return r.length=o,r}});var _xe=Tv,Bxe=String,xv=function(e){if(_xe(e)==="Symbol")throw new TypeError("Cannot convert a Symbol value to a string");return Bxe(e)},qS={},Yxe=ZS,Uxe=Math.max,zxe=Math.min,f2=function(e,t){var n=Yxe(e);return n<0?Uxe(n+t,0):zxe(n,t)},Vxe=ks,Wxe=f2,Gxe=nd,F4=function(e){return function(t,n,r){var o=Vxe(t),i=Gxe(o);if(i===0)return!e&&-1;var a=Wxe(r,i),s;if(e&&n!==n){for(;i>a;)if(s=o[a++],s!==s)return!0}else for(;i>a;a++)if((e||a in o)&&o[a]===n)return e||a||0;return!e&&-1}},MB={includes:F4(!0),indexOf:F4(!1)},KS={},Zxe=pr,TI=vi,$xe=ks,qxe=MB.indexOf,Kxe=KS,H4=Zxe([].push),DB=function(e,t){var n=$xe(e),r=0,o=[],i;for(i in n)!TI(Kxe,i)&&TI(n,i)&&H4(o,i);for(;t.length>r;)TI(n,i=t[r++])&&(~qxe(o,i)||H4(o,i));return o},h2=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],Xxe=DB,Jxe=h2,p2=Object.keys||function(t){return Xxe(t,Jxe)},Qxe=Zo,eIe=bB,tIe=Ia,nIe=Ec,rIe=ks,oIe=p2;qS.f=Qxe&&!eIe?Object.defineProperties:function(t,n){nIe(t);for(var r=rIe(n),o=oIe(n),i=o.length,a=0,s;i>a;)tIe.f(t,s=o[a++],r[s]);return t};var iIe=Es,aIe=iIe("document","documentElement"),sIe=jh,lIe=o2,_4=sIe("keys"),XS=function(e){return _4[e]||(_4[e]=lIe(e))},cIe=Ec,uIe=qS,B4=h2,dIe=KS,fIe=aIe,hIe=vB,pIe=XS,Y4=">",U4="<",EE="prototype",CE="script",AB=pIe("IE_PROTO"),xI=function(){},NB=function(e){return U4+CE+Y4+e+U4+"/"+CE+Y4},z4=function(e){e.write(NB("")),e.close();var t=e.parentWindow.Object;return e=null,t},mIe=function(){var e=hIe("iframe"),t="java"+CE+":",n;return e.style.display="none",fIe.appendChild(e),e.src=String(t),n=e.contentWindow.document,n.open(),n.write(NB("document.F=Object")),n.close(),n.F},lb,Jb=function(){try{lb=new ActiveXObject("htmlfile")}catch{}Jb=typeof document<"u"?document.domain&&lb?z4(lb):mIe():z4(lb);for(var e=B4.length;e--;)delete Jb[EE][B4[e]];return Jb()};dIe[AB]=!0;var m2=Object.create||function(t,n){var r;return t!==null?(xI[EE]=cIe(t),r=new xI,xI[EE]=null,r[AB]=t):r=Jb(),n===void 0?r:uIe.f(r,n)},JS={},gIe=DB,vIe=h2,yIe=vIe.concat("length","prototype");JS.f=Object.getOwnPropertyNames||function(t){return gIe(t,yIe)};var OB={},bIe=pr,QS=bIe([].slice),wIe=Oh,SIe=ks,PB=JS.f,TIe=QS,jB=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],xIe=function(e){try{return PB(e)}catch{return TIe(jB)}};OB.f=function(t){return jB&&wIe(t)==="Window"?xIe(t):PB(SIe(t))};var eT={};eT.f=Object.getOwnPropertySymbols;var IIe=GS,tT=function(e,t,n,r){return r&&r.enumerable?e[t]=n:IIe(e,t,n),e},kIe=Ia,EIe=function(e,t,n){return kIe.f(e,t,n)},Iv={},CIe=Er;Iv.f=CIe;var V4=Br,MIe=vi,DIe=Iv,AIe=Ia.f,Yn=function(e){var t=V4.Symbol||(V4.Symbol={});MIe(t,e)||AIe(t,e,{value:DIe.f(e)})},NIe=Is,OIe=Es,PIe=Er,jIe=tT,LB=function(){var e=OIe("Symbol"),t=e&&e.prototype,n=t&&t.valueOf,r=PIe("toPrimitive");t&&!t[r]&&jIe(t,r,function(o){return NIe(n,this)},{arity:1})},LIe=l2,RIe=Tv,FIe=LIe?{}.toString:function(){return"[object "+RIe(this)+"]"},HIe=l2,_Ie=Ia.f,BIe=GS,YIe=vi,UIe=FIe,zIe=Er,W4=zIe("toStringTag"),Rh=function(e,t,n,r){var o=n?e:e&&e.prototype;o&&(YIe(o,W4)||_Ie(o,W4,{configurable:!0,value:t}),r&&!HIe&&BIe(o,"toString",UIe))},VIe=_r,WIe=oo,G4=VIe.WeakMap,GIe=WIe(G4)&&/native code/.test(String(G4)),ZIe=GIe,RB=_r,$Ie=Cl,qIe=GS,II=vi,kI=r2,KIe=XS,XIe=KS,Z4="Object already initialized",ME=RB.TypeError,JIe=RB.WeakMap,Y0,Jm,U0,QIe=function(e){return U0(e)?Jm(e):Y0(e,{})},eke=function(e){return function(t){var n;if(!$Ie(t)||(n=Jm(t)).type!==e)throw new ME("Incompatible receiver, "+e+" required");return n}};if(ZIe||kI.state){var Va=kI.state||(kI.state=new JIe);Va.get=Va.get,Va.has=Va.has,Va.set=Va.set,Y0=function(e,t){if(Va.has(e))throw new ME(Z4);return t.facade=e,Va.set(e,t),t},Jm=function(e){return Va.get(e)||{}},U0=function(e){return Va.has(e)}}else{var Gd=KIe("state");XIe[Gd]=!0,Y0=function(e,t){if(II(e,Gd))throw new ME(Z4);return t.facade=e,qIe(e,Gd,t),t},Jm=function(e){return II(e,Gd)?e[Gd]:{}},U0=function(e){return II(e,Gd)}}var g2={set:Y0,get:Jm,has:U0,enforce:QIe,getterFor:eke},tke=a2,nke=pr,rke=fB,oke=Dl,ike=nd,ake=d2,$4=nke([].push),rc=function(e){var t=e===1,n=e===2,r=e===3,o=e===4,i=e===6,a=e===7,s=e===5||i;return function(l,u,d,h){for(var p=oke(l),m=rke(p),b=ike(m),v=tke(u,d),y=0,S=h||ake,x=t?S(l,b):n||a?S(l,0):void 0,C,k;b>y;y++)if((s||y in m)&&(C=m[y],k=v(C,y,p),e))if(t)x[y]=k;else if(k)switch(e){case 3:return!0;case 5:return C;case 6:return y;case 2:$4(x,C)}else switch(e){case 4:return!1;case 7:$4(x,C)}return i?-1:r||o?o:x}},v2={forEach:rc(0),map:rc(1),filter:rc(2),some:rc(3),every:rc(4),find:rc(5),findIndex:rc(6),filterReject:rc(7)},nT=dn,kv=_r,y2=Is,ske=pr,Of=Zo,Pf=Ph,lke=hr,Tr=vi,cke=Ml,DE=Ec,rT=ks,b2=i2,uke=xv,AE=yv,jf=m2,FB=p2,dke=JS,HB=OB,fke=eT,_B=vv,BB=Ia,hke=qS,YB=XD,q4=tT,pke=EIe,w2=jh,mke=XS,UB=KS,K4=o2,gke=Er,vke=Iv,yke=Yn,bke=LB,wke=Rh,zB=g2,oT=v2.forEach,_o=mke("hidden"),iT="Symbol",Qm="prototype",Ske=zB.set,X4=zB.getterFor(iT),ma=Object[Qm],Nu=kv.Symbol,rm=Nu&&Nu[Qm],Tke=kv.RangeError,xke=kv.TypeError,EI=kv.QObject,VB=_B.f,Ou=BB.f,WB=HB.f,Ike=YB.f,GB=ske([].push),vl=w2("symbols"),Ev=w2("op-symbols"),kke=w2("wks"),NE=!EI||!EI[Qm]||!EI[Qm].findChild,ZB=function(e,t,n){var r=VB(ma,t);r&&delete ma[t],Ou(e,t,n),r&&e!==ma&&Ou(ma,t,r)},OE=Of&&lke(function(){return jf(Ou({},"a",{get:function(){return Ou(this,"a",{value:7}).a}})).a!==7})?ZB:Ou,CI=function(e,t){var n=vl[e]=jf(rm);return Ske(n,{type:iT,tag:e,description:t}),Of||(n.description=t),n},aT=function(t,n,r){t===ma&&aT(Ev,n,r),DE(t);var o=b2(n);return DE(r),Tr(vl,o)?(r.enumerable?(Tr(t,_o)&&t[_o][o]&&(t[_o][o]=!1),r=jf(r,{enumerable:AE(0,!1)})):(Tr(t,_o)||Ou(t,_o,AE(1,jf(null))),t[_o][o]=!0),OE(t,o,r)):Ou(t,o,r)},S2=function(t,n){DE(t);var r=rT(n),o=FB(r).concat(XB(r));return oT(o,function(i){(!Of||y2($B,r,i))&&aT(t,i,r[i])}),t},Eke=function(t,n){return n===void 0?jf(t):S2(jf(t),n)},$B=function(t){var n=b2(t),r=y2(Ike,this,n);return this===ma&&Tr(vl,n)&&!Tr(Ev,n)?!1:r||!Tr(this,n)||!Tr(vl,n)||Tr(this,_o)&&this[_o][n]?r:!0},qB=function(t,n){var r=rT(t),o=b2(n);if(!(r===ma&&Tr(vl,o)&&!Tr(Ev,o))){var i=VB(r,o);return i&&Tr(vl,o)&&!(Tr(r,_o)&&r[_o][o])&&(i.enumerable=!0),i}},KB=function(t){var n=WB(rT(t)),r=[];return oT(n,function(o){!Tr(vl,o)&&!Tr(UB,o)&&GB(r,o)}),r},XB=function(e){var t=e===ma,n=WB(t?Ev:rT(e)),r=[];return oT(n,function(o){Tr(vl,o)&&(!t||Tr(ma,o))&&GB(r,vl[o])}),r};Pf||(Nu=function(){if(cke(rm,this))throw new xke("Symbol is not a constructor");var t=!arguments.length||arguments[0]===void 0?void 0:uke(arguments[0]),n=K4(t),r=function(o){var i=this===void 0?kv:this;i===ma&&y2(r,Ev,o),Tr(i,_o)&&Tr(i[_o],n)&&(i[_o][n]=!1);var a=AE(1,o);try{OE(i,n,a)}catch(s){if(!(s instanceof Tke))throw s;ZB(i,n,a)}};return Of&&NE&&OE(ma,n,{configurable:!0,set:r}),CI(n,t)},rm=Nu[Qm],q4(rm,"toString",function(){return X4(this).tag}),q4(Nu,"withoutSetter",function(e){return CI(K4(e),e)}),YB.f=$B,BB.f=aT,hke.f=S2,_B.f=qB,dke.f=HB.f=KB,fke.f=XB,vke.f=function(e){return CI(gke(e),e)},Of&&pke(rm,"description",{configurable:!0,get:function(){return X4(this).description}}));nT({global:!0,constructor:!0,wrap:!0,forced:!Pf,sham:!Pf},{Symbol:Nu});oT(FB(kke),function(e){yke(e)});nT({target:iT,stat:!0,forced:!Pf},{useSetter:function(){NE=!0},useSimple:function(){NE=!1}});nT({target:"Object",stat:!0,forced:!Pf,sham:!Of},{create:Eke,defineProperty:aT,defineProperties:S2,getOwnPropertyDescriptor:qB});nT({target:"Object",stat:!0,forced:!Pf},{getOwnPropertyNames:KB});bke();wke(Nu,iT);UB[_o]=!0;var Cke=Ph,JB=Cke&&!!Symbol.for&&!!Symbol.keyFor,Mke=dn,Dke=Es,Ake=vi,Nke=xv,QB=jh,Oke=JB,MI=QB("string-to-symbol-registry"),Pke=QB("symbol-to-string-registry");Mke({target:"Symbol",stat:!0,forced:!Oke},{for:function(e){var t=Nke(e);if(Ake(MI,t))return MI[t];var n=Dke("Symbol")(t);return MI[t]=n,Pke[n]=t,n}});var jke=dn,Lke=vi,Rke=bv,Fke=WS,Hke=jh,_ke=JB,J4=Hke("symbol-to-string-registry");jke({target:"Symbol",stat:!0,forced:!_ke},{keyFor:function(t){if(!Rke(t))throw new TypeError(Fke(t)+" is not a symbol");if(Lke(J4,t))return J4[t]}});var Bke=pr,Q4=Lh,Yke=oo,eL=Oh,Uke=xv,tL=Bke([].push),zke=function(e){if(Yke(e))return e;if(Q4(e)){for(var t=e.length,n=[],r=0;r<t;r++){var o=e[r];typeof o=="string"?tL(n,o):(typeof o=="number"||eL(o)==="Number"||eL(o)==="String")&&tL(n,Uke(o))}var i=n.length,a=!0;return function(s,l){if(a)return a=!1,l;if(Q4(this))return l;for(var u=0;u<i;u++)if(n[u]===s)return l}}},Vke=dn,eY=Es,tY=qD,Wke=Is,Cv=pr,nY=hr,nL=oo,rL=bv,rY=QS,Gke=zke,Zke=Ph,$ke=String,pc=eY("JSON","stringify"),cb=Cv(/./.exec),oL=Cv("".charAt),qke=Cv("".charCodeAt),Kke=Cv("".replace),Xke=Cv(1 .toString),Jke=/[\uD800-\uDFFF]/g,iL=/^[\uD800-\uDBFF]$/,aL=/^[\uDC00-\uDFFF]$/,sL=!Zke||nY(function(){var e=eY("Symbol")("stringify detection");return pc([e])!=="[null]"||pc({a:e})!=="{}"||pc(Object(e))!=="{}"}),lL=nY(function(){return pc("\uDF06\uD834")!=='"\\udf06\\ud834"'||pc("\uDEAD")!=='"\\udead"'}),Qke=function(e,t){var n=rY(arguments),r=Gke(t);if(!(!nL(r)&&(e===void 0||rL(e))))return n[1]=function(o,i){if(nL(r)&&(i=Wke(r,this,$ke(o),i)),!rL(i))return i},tY(pc,null,n)},eEe=function(e,t,n){var r=oL(n,t-1),o=oL(n,t+1);return cb(iL,e)&&!cb(aL,o)||cb(aL,e)&&!cb(iL,r)?"\\u"+Xke(qke(e,0),16):e};pc&&Vke({target:"JSON",stat:!0,arity:3,forced:sL||lL},{stringify:function(t,n,r){var o=rY(arguments),i=tY(sL?Qke:pc,null,o);return lL&&typeof i=="string"?Kke(i,Jke,eEe):i}});var tEe=dn,nEe=Ph,rEe=hr,oY=eT,oEe=Dl,iEe=!nEe||rEe(function(){oY.f(1)});tEe({target:"Object",stat:!0,forced:iEe},{getOwnPropertySymbols:function(t){var n=oY.f;return n?n(oEe(t)):[]}});var aEe=Yn;aEe("asyncIterator");var sEe=Yn;sEe("hasInstance");var lEe=Yn;lEe("isConcatSpreadable");var cEe=Yn;cEe("iterator");var uEe=Yn;uEe("match");var dEe=Yn;dEe("matchAll");var fEe=Yn;fEe("replace");var hEe=Yn;hEe("search");var pEe=Yn;pEe("species");var mEe=Yn;mEe("split");var gEe=Yn,vEe=LB;gEe("toPrimitive");vEe();var yEe=Es,bEe=Yn,wEe=Rh;bEe("toStringTag");wEe(yEe("Symbol"),"Symbol");var SEe=Yn;SEe("unscopables");var TEe=_r,xEe=Rh;xEe(TEe.JSON,"JSON",!0);var IEe=Br,kEe=IEe.Symbol,Fh={},PE=Zo,EEe=vi,iY=Function.prototype,CEe=PE&&Object.getOwnPropertyDescriptor,T2=EEe(iY,"name"),MEe=T2&&function(){}.name==="something",DEe=T2&&(!PE||PE&&CEe(iY,"name").configurable),AEe={EXISTS:T2,PROPER:MEe,CONFIGURABLE:DEe},NEe=hr,OEe=!NEe(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}),PEe=vi,jEe=oo,LEe=Dl,REe=XS,FEe=OEe,cL=REe("IE_PROTO"),jE=Object,HEe=jE.prototype,aY=FEe?jE.getPrototypeOf:function(e){var t=LEe(e);if(PEe(t,cL))return t[cL];var n=t.constructor;return jEe(n)&&t instanceof n?n.prototype:t instanceof jE?HEe:null},_Ee=hr,BEe=oo,YEe=Cl,UEe=m2,uL=aY,zEe=tT,VEe=Er,LE=VEe("iterator"),sY=!1,sl,DI,AI;[].keys&&(AI=[].keys(),"next"in AI?(DI=uL(uL(AI)),DI!==Object.prototype&&(sl=DI)):sY=!0);var WEe=!YEe(sl)||_Ee(function(){var e={};return sl[LE].call(e)!==e});WEe?sl={}:sl=UEe(sl);BEe(sl[LE])||zEe(sl,LE,function(){return this});var lY={IteratorPrototype:sl,BUGGY_SAFARI_ITERATORS:sY},GEe=lY.IteratorPrototype,ZEe=m2,$Ee=yv,qEe=Rh,KEe=Fh,XEe=function(){return this},JEe=function(e,t,n,r){var o=t+" Iterator";return e.prototype=ZEe(GEe,{next:$Ee(+!r,n)}),qEe(e,o,!1,!0),KEe[o]=XEe,e},QEe=dn,eCe=Is,cY=AEe,tCe=JEe,nCe=aY,rCe=Rh,dL=tT,oCe=Er,fL=Fh,uY=lY,iCe=cY.PROPER;cY.CONFIGURABLE;uY.IteratorPrototype;var ub=uY.BUGGY_SAFARI_ITERATORS,NI=oCe("iterator"),hL="keys",db="values",pL="entries",aCe=function(){return this},dY=function(e,t,n,r,o,i,a){tCe(n,t,r);var s=function(S){if(S===o&&p)return p;if(!ub&&S&&S in d)return d[S];switch(S){case hL:return function(){return new n(this,S)};case db:return function(){return new n(this,S)};case pL:return function(){return new n(this,S)}}return function(){return new n(this)}},l=t+" Iterator",u=!1,d=e.prototype,h=d[NI]||d["@@iterator"]||o&&d[o],p=!ub&&h||s(o),m=t==="Array"&&d.entries||h,b,v,y;if(m&&(b=nCe(m.call(new e)),b!==Object.prototype&&b.next&&(rCe(b,l,!0,!0),fL[l]=aCe)),iCe&&o===db&&h&&h.name!==db&&(u=!0,p=function(){return eCe(h,this)}),o)if(v={values:s(db),keys:i?p:s(hL),entries:s(pL)},a)for(y in v)(ub||u||!(y in d))&&dL(d,y,v[y]);else QEe({target:t,proto:!0,forced:ub||u},v);return a&&d[NI]!==p&&dL(d,NI,p,{name:o}),fL[t]=p,v},fY=function(e,t){return{value:e,done:t}},sCe=ks,mL=Fh,hY=g2;Ia.f;var lCe=dY,fb=fY,pY="Array Iterator",cCe=hY.set,uCe=hY.getterFor(pY);lCe(Array,"Array",function(e,t){cCe(this,{type:pY,target:sCe(e),index:0,kind:t})},function(){var e=uCe(this),t=e.target,n=e.index++;if(!t||n>=t.length)return e.target=void 0,fb(void 0,!0);switch(e.kind){case"keys":return fb(n,!1);case"values":return fb(t[n],!1)}return fb([n,t[n]],!1)},"values");mL.Arguments=mL.Array;var dCe={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0},fCe=dCe,hCe=_r,pCe=Rh,gL=Fh;for(var OI in fCe)pCe(hCe[OI],OI),gL[OI]=gL.Array;var mCe=kEe,gCe=mCe,vCe=Er,yCe=Ia.f,vL=vCe("metadata"),yL=Function.prototype;yL[vL]===void 0&&yCe(yL,vL,{value:null});var bCe=Yn;bCe("asyncDispose");var wCe=Yn;wCe("dispose");var SCe=Yn;SCe("metadata");var TCe=gCe,xCe=TCe,ICe=Es,kCe=pr,x2=ICe("Symbol"),ECe=x2.keyFor,CCe=kCe(x2.prototype.valueOf),mY=x2.isRegisteredSymbol||function(t){try{return ECe(CCe(t))!==void 0}catch{return!1}},MCe=dn,DCe=mY;MCe({target:"Symbol",stat:!0},{isRegisteredSymbol:DCe});var ACe=jh,gY=Es,NCe=pr,OCe=bv,PCe=Er,z0=gY("Symbol"),bL=z0.isWellKnownSymbol,vY=gY("Object","getOwnPropertyNames"),jCe=NCe(z0.prototype.valueOf),wL=ACe("wks");for(var PI=0,SL=vY(z0),LCe=SL.length;PI<LCe;PI++)try{var TL=SL[PI];OCe(z0[TL])&&PCe(TL)}catch{}var yY=function(t){if(bL&&bL(t))return!0;try{for(var n=jCe(t),r=0,o=vY(wL),i=o.length;r<i;r++)if(wL[o[r]]==n)return!0}catch{}return!1},RCe=dn,FCe=yY;RCe({target:"Symbol",stat:!0,forced:!0},{isWellKnownSymbol:FCe});var HCe=Yn;HCe("customMatcher");var _Ce=Yn;_Ce("observable");var BCe=dn,YCe=mY;BCe({target:"Symbol",stat:!0,name:"isRegisteredSymbol"},{isRegistered:YCe});var UCe=dn,zCe=yY;UCe({target:"Symbol",stat:!0,name:"isWellKnownSymbol",forced:!0},{isWellKnown:zCe});var VCe=Yn;VCe("matcher");var WCe=Yn;WCe("metadataKey");var GCe=Yn;GCe("patternMatch");var ZCe=Yn;ZCe("replaceAll");var $Ce=xCe,qCe=$Ce,KCe=qCe;const af=tt(KCe);var I2=pr,XCe=ZS,JCe=xv,QCe=QD,eMe=I2("".charAt),xL=I2("".charCodeAt),tMe=I2("".slice),IL=function(e){return function(t,n){var r=JCe(QCe(t)),o=XCe(n),i=r.length,a,s;return o<0||o>=i?e?"":void 0:(a=xL(r,o),a<55296||a>56319||o+1===i||(s=xL(r,o+1))<56320||s>57343?e?eMe(r,o):a:e?tMe(r,o,o+2):(a-55296<<10)+(s-56320)+65536)}},nMe={codeAt:IL(!1),charAt:IL(!0)},rMe=nMe.charAt,oMe=xv,bY=g2,iMe=dY,kL=fY,wY="String Iterator",aMe=bY.set,sMe=bY.getterFor(wY);iMe(String,"String",function(e){aMe(this,{type:wY,string:oMe(e),index:0})},function(){var t=sMe(this),n=t.string,r=t.index,o;return r>=n.length?kL(void 0,!0):(o=rMe(n,r),t.index+=o.length,kL(o,!1))});var lMe=Tv,EL=n2,cMe=JD,uMe=Fh,dMe=Er,fMe=dMe("iterator"),k2=function(e){if(!cMe(e))return EL(e,fMe)||EL(e,"@@iterator")||uMe[lMe(e)]},hMe=k2,pMe=hMe,mMe=pMe,gMe=mMe,vMe=gMe,yMe=vMe,bMe=yMe,wMe=bMe,SMe=wMe;const SY=tt(SMe);var TMe=Zo,xMe=Lh,IMe=TypeError,kMe=Object.getOwnPropertyDescriptor,EMe=TMe&&!function(){if(this!==void 0)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(e){return e instanceof TypeError}}(),TY=EMe?function(e,t){if(xMe(e)&&!kMe(e,"length").writable)throw new IMe("Cannot set read only .length");return e.length=t}:function(e,t){return e.length=t},CMe=dn,MMe=Dl,DMe=nd,AMe=TY,NMe=s2,OMe=hr,PMe=OMe(function(){return[].push.call({length:4294967296},1)!==4294967297}),jMe=function(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(e){return e instanceof TypeError}},LMe=PMe||!jMe();CMe({target:"Array",proto:!0,arity:1,forced:LMe},{push:function(t){var n=MMe(this),r=DMe(n),o=arguments.length;NMe(r+o);for(var i=0;i<o;i++)n[r]=arguments[i],r++;return AMe(n,r),r}});var RMe=_r,FMe=Br,rd=function(e,t){var n=FMe[e+"Prototype"],r=n&&n[t];if(r)return r;var o=RMe[e],i=o&&o.prototype;return i&&i[t]},HMe=rd,_Me=HMe("Array","push"),BMe=Ml,YMe=_Me,jI=Array.prototype,UMe=function(e){var t=e.push;return e===jI||BMe(jI,e)&&t===jI.push?YMe:t},zMe=UMe,VMe=zMe,WMe=VMe,GMe=WMe,ZMe=GMe,$Me=ZMe,qMe=$Me;const KMe=tt(qMe);function XMe(e,t){var n=e==null?null:typeof af<"u"&&SY(e)||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(KMe(s).call(s,r.value),s.length!==t);l=!0);}catch(d){u=!0,o=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}var JMe=dn,CL=Lh,QMe=u2,eDe=Cl,ML=f2,tDe=nd,nDe=ks,rDe=Sv,oDe=Er,iDe=$S,aDe=QS,sDe=iDe("slice"),lDe=oDe("species"),LI=Array,cDe=Math.max;JMe({target:"Array",proto:!0,forced:!sDe},{slice:function(t,n){var r=nDe(this),o=tDe(r),i=ML(t,o),a=ML(n===void 0?o:n,o),s,l,u;if(CL(r)&&(s=r.constructor,QMe(s)&&(s===LI||CL(s.prototype))?s=void 0:eDe(s)&&(s=s[lDe],s===null&&(s=void 0)),s===LI||s===void 0))return aDe(r,i,a);for(l=new(s===void 0?LI:s)(cDe(a-i,0)),u=0;i<a;i++,u++)i in r&&rDe(l,u,r[i]);return l.length=u,l}});var uDe=rd,dDe=uDe("Array","slice"),fDe=Ml,hDe=dDe,RI=Array.prototype,pDe=function(e){var t=e.slice;return e===RI||fDe(RI,e)&&t===RI.slice?hDe:t},mDe=pDe,gDe=mDe,vDe=gDe,yDe=vDe,bDe=yDe,wDe=bDe,SDe=wDe;const TDe=tt(SDe);var xDe=Is,DL=Ec,IDe=n2,kDe=function(e,t,n){var r,o;DL(e);try{if(r=IDe(e,"return"),!r){if(t==="throw")throw n;return n}r=xDe(r,e)}catch(i){o=!0,r=i}if(t==="throw")throw n;if(o)throw r;return DL(r),n},EDe=Ec,CDe=kDe,MDe=function(e,t,n,r){try{return r?t(EDe(n)[0],n[1]):t(n)}catch(o){CDe(e,"throw",o)}},DDe=Er,ADe=Fh,NDe=DDe("iterator"),ODe=Array.prototype,PDe=function(e){return e!==void 0&&(ADe.Array===e||ODe[NDe]===e)},jDe=Is,LDe=t2,RDe=Ec,FDe=WS,HDe=k2,_De=TypeError,BDe=function(e,t){var n=arguments.length<2?HDe(e):t;if(LDe(n))return RDe(jDe(n,e));throw new _De(FDe(e)+" is not iterable")},YDe=a2,UDe=Is,zDe=Dl,VDe=MDe,WDe=PDe,GDe=u2,ZDe=nd,AL=Sv,$De=BDe,qDe=k2,NL=Array,KDe=function(t){var n=zDe(t),r=GDe(this),o=arguments.length,i=o>1?arguments[1]:void 0,a=i!==void 0;a&&(i=YDe(i,o>2?arguments[2]:void 0));var s=qDe(n),l=0,u,d,h,p,m,b;if(s&&!(this===NL&&WDe(s)))for(d=r?new this:[],p=$De(n,s),m=p.next;!(h=UDe(m,p)).done;l++)b=a?VDe(p,i,[h.value,l],!0):h.value,AL(d,l,b);else for(u=ZDe(n),d=r?new this(u):NL(u);u>l;l++)b=a?i(n[l],l):n[l],AL(d,l,b);return d.length=l,d},XDe=Er,xY=XDe("iterator"),IY=!1;try{var JDe=0,OL={next:function(){return{done:!!JDe++}},return:function(){IY=!0}};OL[xY]=function(){return this},Array.from(OL,function(){throw 2})}catch{}var QDe=function(e,t){try{if(!t&&!IY)return!1}catch{return!1}var n=!1;try{var r={};r[xY]=function(){return{next:function(){return{done:n=!0}}}},e(r)}catch{}return n},e2e=dn,t2e=KDe,n2e=QDe,r2e=!n2e(function(e){Array.from(e)});e2e({target:"Array",stat:!0,forced:r2e},{from:t2e});var o2e=Br,i2e=o2e.Array.from,a2e=i2e,s2e=a2e,l2e=s2e,c2e=l2e,u2e=c2e,d2e=u2e,f2e=d2e;const kY=tt(f2e);function RE(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function EY(e,t){var n;if(e){if(typeof e=="string")return RE(e,t);var r=TDe(n=Object.prototype.toString.call(e)).call(n,8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return kY(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return RE(e,t)}}function h2e(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ja(e,t){return R1e(e)||XMe(e,t)||EY(e,t)||h2e()}var CY={exports:{}};(function(e){(function(){var t={}.hasOwnProperty;function n(){for(var r=[],o=0;o<arguments.length;o++){var i=arguments[o];if(i){var a=typeof i;if(a==="string"||a==="number")r.push(i);else if(Array.isArray(i)){if(i.length){var s=n.apply(null,i);s&&r.push(s)}}else if(a==="object")if(i.toString===Object.prototype.toString)for(var l in i)t.call(i,l)&&i[l]&&r.push(l);else r.push(i.toString())}}return r.join(" ")}e.exports?(n.default=n,e.exports=n):window.classNames=n})()})(CY);var p2e=CY.exports;const E2=tt(p2e);var MY={exports:{}},FI,PL;function m2e(){if(PL)return FI;PL=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return FI=e,FI}var HI,jL;function g2e(){if(jL)return HI;jL=1;var e=m2e();function t(){}function n(){}return n.resetWarningCache=t,HI=function(){function r(a,s,l,u,d,h){if(h!==e){var p=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw p.name="Invariant Violation",p}}r.isRequired=r;function o(){return r}var i={array:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return i.PropTypes=i,i},HI}MY.exports=g2e()();var v2e=MY.exports;const Vt=tt(v2e);var C2=Y.createContext({scrollTo:function(){return 0},scrollToBottom:function(){return 0},scrollToEnd:function(){return 0},scrollToStart:function(){return 0},scrollToTop:function(){return 0}});C2.displayName="ScrollToBottomFunctionContext";function sT(){return D.useContext(C2)}function y2e(){var e=sT(),t=e.scrollToEnd;return t}var M2=Y.createContext({atBottom:!0,atEnd:!0,atStart:!1,atTop:!0,mode:"bottom"});M2.displayName="ScrollToBottomState1Context";var D2=Y.createContext({animating:!1,animatingToEnd:!1,sticky:!0});D2.displayName="ScrollToBottomState2Context";var A2=Y.createContext({animating:!1,animatingToEnd:!1,atBottom:!0,atEnd:!0,atStart:!1,atTop:!0,mode:"bottom",sticky:!0});A2.displayName="ScrollToBottomStateContext";var LL=[A2,M2,D2];function b2e(e){return D.useContext(LL[e]||LL[0])}function w2e(){var e=b2e(2),t=e.sticky;return[t]}var lT=Y.createContext({offsetHeight:0,scrollHeight:0,setTarget:function(){return 0},styleToClassName:function(){return""}});lT.displayName="ScrollToBottomInternalContext";function S2e(){return D.useContext(lT)}function N2(){var e=S2e(),t=e.styleToClassName;return t}var T2e={backgroundColor:"rgba(0, 0, 0, .2)",borderRadius:10,borderWidth:0,bottom:5,cursor:"pointer",height:20,outline:0,position:"absolute",right:20,width:20,"&:hover":{backgroundColor:"rgba(0, 0, 0, .4)"},"&:active":{backgroundColor:"rgba(0, 0, 0, .6)"}},O2=function(t){var n=t.children,r=t.className,o=w2e(),i=Ja(o,1),a=i[0],s=N2()(T2e),l=y2e();return!a&&Y.createElement("button",{className:E2(s,(r||"")+""),onClick:l,type:"button"},n)};O2.defaultProps={children:void 0,className:""};O2.propTypes={children:Vt.any,className:Vt.string};var DY={exports:{}},x2e=dn,I2e=Zo,RL=Ia.f;x2e({target:"Object",stat:!0,forced:Object.defineProperty!==RL,sham:!I2e},{defineProperty:RL});var k2e=Br,AY=k2e.Object,E2e=DY.exports=function(t,n,r){return AY.defineProperty(t,n,r)};AY.defineProperty.sham&&(E2e.sham=!0);var C2e=DY.exports,M2e=C2e,NY=M2e,D2e=NY,A2e=D2e,N2e=A2e,O2e=N2e,P2e=O2e;const j2e=tt(P2e);var L2e=Iv,R2e=L2e.f("iterator"),F2e=R2e,H2e=F2e,_2e=H2e,B2e=_2e,Y2e=B2e,U2e=Y2e,z2e=U2e;const V2e=tt(z2e);function eg(e){"@babel/helpers - typeof";return eg=typeof af=="function"&&typeof V2e=="symbol"?function(t){return typeof t}:function(t){return t&&typeof af=="function"&&t.constructor===af&&t!==af.prototype?"symbol":typeof t},eg(e)}var W2e=Iv,G2e=W2e.f("toPrimitive"),Z2e=G2e,$2e=Z2e,q2e=$2e,K2e=q2e,X2e=K2e,J2e=X2e,Q2e=J2e;const eAe=tt(Q2e);function tAe(e,t){if(eg(e)!="object"||!e)return e;var n=e[eAe];if(n!==void 0){var r=n.call(e,t||"default");if(eg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function nAe(e){var t=tAe(e,"string");return eg(t)=="symbol"?t:t+""}function rAe(e,t,n){return t=nAe(t),t in e?j2e(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function oAe(e){if(SB(e))return RE(e)}function iAe(e){if(typeof af<"u"&&SY(e)!=null||e["@@iterator"]!=null)return kY(e)}function aAe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Bt(e){return oAe(e)||iAe(e)||EY(e)||aAe()}var hb=function(e){return e&&e.Math==Math&&e},yi=hb(typeof globalThis=="object"&&globalThis)||hb(typeof window=="object"&&window)||hb(typeof self=="object"&&self)||hb(typeof xr=="object"&&xr)||function(){return this}()||Function("return this")(),P2={},ka=function(e){try{return!!e()}catch{return!0}},sAe=ka,od=!sAe(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!=7}),OY={},PY={}.propertyIsEnumerable,jY=Object.getOwnPropertyDescriptor,lAe=jY&&!PY.call({1:2},1);OY.f=lAe?function(t){var n=jY(this,t);return!!n&&n.enumerable}:PY;var LY=function(e,t){return{enumerable:!(e&1),configurable:!(e&2),writable:!(e&4),value:t}},cAe={}.toString,j2=function(e){return cAe.call(e).slice(8,-1)},uAe=ka,dAe=j2,fAe="".split,hAe=uAe(function(){return!Object("z").propertyIsEnumerable(0)})?function(e){return dAe(e)=="String"?fAe.call(e,""):Object(e)}:Object,cT=function(e){if(e==null)throw TypeError("Can't call method on "+e);return e},pAe=hAe,mAe=cT,L2=function(e){return pAe(mAe(e))},Wi=function(e){return typeof e=="function"},gAe=Wi,Mv=function(e){return typeof e=="object"?e!==null:gAe(e)},_I=yi,vAe=Wi,yAe=function(e){return vAe(e)?e:void 0},uT=function(e,t){return arguments.length<2?yAe(_I[e]):_I[e]&&_I[e][t]},bAe=uT,wAe=bAe("navigator","userAgent")||"",RY=yi,BI=wAe,FL=RY.process,HL=RY.Deno,_L=FL&&FL.versions||HL&&HL.version,BL=_L&&_L.v8,Wa,V0;BL?(Wa=BL.split("."),V0=Wa[0]<4?1:Wa[0]+Wa[1]):BI&&(Wa=BI.match(/Edge\/(\d+)/),(!Wa||Wa[1]>=74)&&(Wa=BI.match(/Chrome\/(\d+)/),Wa&&(V0=Wa[1])));var SAe=V0&&+V0,YL=SAe,TAe=ka,FY=!!Object.getOwnPropertySymbols&&!TAe(function(){var e=Symbol();return!String(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&YL&&YL<41}),xAe=FY,HY=xAe&&!Symbol.sham&&typeof Symbol.iterator=="symbol",IAe=Wi,kAe=uT,EAe=HY,_Y=EAe?function(e){return typeof e=="symbol"}:function(e){var t=kAe("Symbol");return IAe(t)&&Object(e)instanceof t},CAe=function(e){try{return String(e)}catch{return"Object"}},MAe=Wi,DAe=CAe,AAe=function(e){if(MAe(e))return e;throw TypeError(DAe(e)+" is not a function")},NAe=AAe,BY=function(e,t){var n=e[t];return n==null?void 0:NAe(n)},YI=Wi,UI=Mv,OAe=function(e,t){var n,r;if(t==="string"&&YI(n=e.toString)&&!UI(r=n.call(e))||YI(n=e.valueOf)&&!UI(r=n.call(e))||t!=="string"&&YI(n=e.toString)&&!UI(r=n.call(e)))return r;throw TypeError("Can't convert object to primitive value")},YY={exports:{}},UL=yi,R2=function(e,t){try{Object.defineProperty(UL,e,{value:t,configurable:!0,writable:!0})}catch{UL[e]=t}return t},PAe=yi,jAe=R2,zL="__core-js_shared__",LAe=PAe[zL]||jAe(zL,{}),F2=LAe,VL=F2;(YY.exports=function(e,t){return VL[e]||(VL[e]=t!==void 0?t:{})})("versions",[]).push({version:"3.18.3",mode:"global",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"});var H2=YY.exports,RAe=cT,UY=function(e){return Object(RAe(e))},FAe=UY,HAe={}.hasOwnProperty,id=Object.hasOwn||function(t,n){return HAe.call(FAe(t),n)},_Ae=0,BAe=Math.random(),zY=function(e){return"Symbol("+String(e===void 0?"":e)+")_"+(++_Ae+BAe).toString(36)},YAe=yi,UAe=H2,WL=id,zAe=zY,GL=FY,VAe=HY,Fp=UAe("wks"),ym=YAe.Symbol,WAe=VAe?ym:ym&&ym.withoutSetter||zAe,Dv=function(e){return(!WL(Fp,e)||!(GL||typeof Fp[e]=="string"))&&(GL&&WL(ym,e)?Fp[e]=ym[e]:Fp[e]=WAe("Symbol."+e)),Fp[e]},ZL=Mv,$L=_Y,GAe=BY,ZAe=OAe,$Ae=Dv,qAe=$Ae("toPrimitive"),KAe=function(e,t){if(!ZL(e)||$L(e))return e;var n=GAe(e,qAe),r;if(n){if(t===void 0&&(t="default"),r=n.call(e,t),!ZL(r)||$L(r))return r;throw TypeError("Can't convert object to primitive value")}return t===void 0&&(t="number"),ZAe(e,t)},XAe=KAe,JAe=_Y,VY=function(e){var t=XAe(e,"string");return JAe(t)?t:String(t)},QAe=yi,qL=Mv,FE=QAe.document,eNe=qL(FE)&&qL(FE.createElement),WY=function(e){return eNe?FE.createElement(e):{}},tNe=od,nNe=ka,rNe=WY,GY=!tNe&&!nNe(function(){return Object.defineProperty(rNe("div"),"a",{get:function(){return 7}}).a!=7}),oNe=od,iNe=OY,aNe=LY,sNe=L2,lNe=VY,cNe=id,uNe=GY,KL=Object.getOwnPropertyDescriptor;P2.f=oNe?KL:function(t,n){if(t=sNe(t),n=lNe(n),uNe)try{return KL(t,n)}catch{}if(cNe(t,n))return aNe(!iNe.f.call(t,n),t[n])};var Av={},dNe=Mv,Cc=function(e){if(dNe(e))return e;throw TypeError(String(e)+" is not an object")},fNe=od,hNe=GY,XL=Cc,pNe=VY,JL=Object.defineProperty;Av.f=fNe?JL:function(t,n,r){if(XL(t),n=pNe(n),XL(r),hNe)try{return JL(t,n,r)}catch{}if("get"in r||"set"in r)throw TypeError("Accessors not supported");return"value"in r&&(t[n]=r.value),t};var mNe=od,gNe=Av,vNe=LY,dT=mNe?function(e,t,n){return gNe.f(e,t,vNe(1,n))}:function(e,t,n){return e[t]=n,e},ZY={exports:{}},yNe=Wi,HE=F2,bNe=Function.toString;yNe(HE.inspectSource)||(HE.inspectSource=function(e){return bNe.call(e)});var $Y=HE.inspectSource,wNe=yi,SNe=Wi,TNe=$Y,QL=wNe.WeakMap,xNe=SNe(QL)&&/native code/.test(TNe(QL)),INe=H2,kNe=zY,eR=INe("keys"),qY=function(e){return eR[e]||(eR[e]=kNe(e))},_2={},ENe=xNe,CNe=yi,MNe=Mv,DNe=dT,zI=id,VI=F2,ANe=qY,NNe=_2,tR="Object already initialized",ONe=CNe.WeakMap,W0,tg,G0,PNe=function(e){return G0(e)?tg(e):W0(e,{})},jNe=function(e){return function(t){var n;if(!MNe(t)||(n=tg(t)).type!==e)throw TypeError("Incompatible receiver, "+e+" required");return n}};if(ENe||VI.state){var lu=VI.state||(VI.state=new ONe),LNe=lu.get,nR=lu.has,RNe=lu.set;W0=function(e,t){if(nR.call(lu,e))throw new TypeError(tR);return t.facade=e,RNe.call(lu,e,t),t},tg=function(e){return LNe.call(lu,e)||{}},G0=function(e){return nR.call(lu,e)}}else{var Zd=ANe("state");NNe[Zd]=!0,W0=function(e,t){if(zI(e,Zd))throw new TypeError(tR);return t.facade=e,DNe(e,Zd,t),t},tg=function(e){return zI(e,Zd)?e[Zd]:{}},G0=function(e){return zI(e,Zd)}}var KY={set:W0,get:tg,has:G0,enforce:PNe,getterFor:jNe},_E=od,FNe=id,XY=Function.prototype,HNe=_E&&Object.getOwnPropertyDescriptor,B2=FNe(XY,"name"),_Ne=B2&&function(){}.name==="something",BNe=B2&&(!_E||_E&&HNe(XY,"name").configurable),Y2={EXISTS:B2,PROPER:_Ne,CONFIGURABLE:BNe},YNe=yi,rR=Wi,UNe=id,oR=dT,zNe=R2,VNe=$Y,JY=KY,WNe=Y2.CONFIGURABLE,GNe=JY.get,ZNe=JY.enforce,$Ne=String(String).split("String");(ZY.exports=function(e,t,n,r){var o=r?!!r.unsafe:!1,i=r?!!r.enumerable:!1,a=r?!!r.noTargetGet:!1,s=r&&r.name!==void 0?r.name:t,l;if(rR(n)&&(String(s).slice(0,7)==="Symbol("&&(s="["+String(s).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),(!UNe(n,"name")||WNe&&n.name!==s)&&oR(n,"name",s),l=ZNe(n),l.source||(l.source=$Ne.join(typeof s=="string"?s:""))),e===YNe){i?e[t]=n:zNe(t,n);return}else o?!a&&e[t]&&(i=!0):delete e[t];i?e[t]=n:oR(e,t,n)})(Function.prototype,"toString",function(){return rR(this)&&GNe(this).source||VNe(this)});var Nv=ZY.exports,QY={},qNe=Math.ceil,KNe=Math.floor,fT=function(e){var t=+e;return t!==t||t===0?0:(t>0?KNe:qNe)(t)},XNe=fT,JNe=Math.max,QNe=Math.min,eOe=function(e,t){var n=XNe(e);return n<0?JNe(n+t,0):QNe(n,t)},tOe=fT,nOe=Math.min,eU=function(e){return e>0?nOe(tOe(e),9007199254740991):0},rOe=eU,oOe=function(e){return rOe(e.length)},iOe=L2,aOe=eOe,sOe=oOe,iR=function(e){return function(t,n,r){var o=iOe(t),i=sOe(o),a=aOe(r,i),s;if(e&&n!=n){for(;i>a;)if(s=o[a++],s!=s)return!0}else for(;i>a;a++)if((e||a in o)&&o[a]===n)return e||a||0;return!e&&-1}},lOe={includes:iR(!0),indexOf:iR(!1)},WI=id,cOe=L2,uOe=lOe.indexOf,dOe=_2,tU=function(e,t){var n=cOe(e),r=0,o=[],i;for(i in n)!WI(dOe,i)&&WI(n,i)&&o.push(i);for(;t.length>r;)WI(n,i=t[r++])&&(~uOe(o,i)||o.push(i));return o},U2=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],fOe=tU,hOe=U2,pOe=hOe.concat("length","prototype");QY.f=Object.getOwnPropertyNames||function(t){return fOe(t,pOe)};var nU={};nU.f=Object.getOwnPropertySymbols;var mOe=uT,gOe=QY,vOe=nU,yOe=Cc,bOe=mOe("Reflect","ownKeys")||function(t){var n=gOe.f(yOe(t)),r=vOe.f;return r?n.concat(r(t)):n},wOe=id,SOe=bOe,TOe=P2,xOe=Av,IOe=function(e,t){for(var n=SOe(t),r=xOe.f,o=TOe.f,i=0;i<n.length;i++){var a=n[i];wOe(e,a)||r(e,a,o(t,a))}},kOe=ka,EOe=Wi,COe=/#|\.prototype\./,Ov=function(e,t){var n=DOe[MOe(e)];return n==NOe?!0:n==AOe?!1:EOe(t)?kOe(t):!!t},MOe=Ov.normalize=function(e){return String(e).replace(COe,".").toLowerCase()},DOe=Ov.data={},AOe=Ov.NATIVE="N",NOe=Ov.POLYFILL="P",OOe=Ov,GI=yi,POe=P2.f,jOe=dT,LOe=Nv,ROe=R2,FOe=IOe,HOe=OOe,_Oe=function(e,t){var n=e.target,r=e.global,o=e.stat,i,a,s,l,u,d;if(r?a=GI:o?a=GI[n]||ROe(n,{}):a=(GI[n]||{}).prototype,a)for(s in t){if(u=t[s],e.noTargetGet?(d=POe(a,s),l=d&&d.value):l=a[s],i=HOe(r?s:n+(o?".":"#")+s,e.forced),!i&&l!==void 0){if(typeof u==typeof l)continue;FOe(u,l)}(e.sham||l&&l.sham)&&jOe(u,"sham",!0),LOe(a,s,u,e)}},BOe=Dv,YOe=BOe("toStringTag"),rU={};rU[YOe]="z";var z2=String(rU)==="[object z]",UOe=z2,zOe=Wi,Qb=j2,VOe=Dv,WOe=VOe("toStringTag"),GOe=Qb(function(){return arguments}())=="Arguments",ZOe=function(e,t){try{return e[t]}catch{}},oU=UOe?Qb:function(e){var t,n,r;return e===void 0?"Undefined":e===null?"Null":typeof(n=ZOe(t=Object(e),WOe))=="string"?n:GOe?Qb(t):(r=Qb(t))=="Object"&&zOe(t.callee)?"Arguments":r},$Oe=oU,hT=function(e){if($Oe(e)==="Symbol")throw TypeError("Cannot convert a Symbol value to a string");return String(e)},qOe=Cc,iU=function(){var e=qOe(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.dotAll&&(t+="s"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t},V2={},aU=ka,KOe=yi,sU=KOe.RegExp;V2.UNSUPPORTED_Y=aU(function(){var e=sU("a","y");return e.lastIndex=2,e.exec("abcd")!=null});V2.BROKEN_CARET=aU(function(){var e=sU("^r","gy");return e.lastIndex=2,e.exec("str")!=null});var XOe=tU,JOe=U2,QOe=Object.keys||function(t){return XOe(t,JOe)},ePe=od,tPe=Av,nPe=Cc,rPe=QOe,oPe=ePe?Object.defineProperties:function(t,n){nPe(t);for(var r=rPe(n),o=r.length,i=0,a;o>i;)tPe.f(t,a=r[i++],n[a]);return t},iPe=uT,aPe=iPe("document","documentElement"),sPe=Cc,lPe=oPe,aR=U2,cPe=_2,uPe=aPe,dPe=WY,fPe=qY,sR=">",lR="<",BE="prototype",YE="script",lU=fPe("IE_PROTO"),ZI=function(){},cU=function(e){return lR+YE+sR+e+lR+"/"+YE+sR},cR=function(e){e.write(cU("")),e.close();var t=e.parentWindow.Object;return e=null,t},hPe=function(){var e=dPe("iframe"),t="java"+YE+":",n;return e.style.display="none",uPe.appendChild(e),e.src=String(t),n=e.contentWindow.document,n.open(),n.write(cU("document.F=Object")),n.close(),n.F},pb,e0=function(){try{pb=new ActiveXObject("htmlfile")}catch{}e0=typeof document<"u"?document.domain&&pb?cR(pb):hPe():cR(pb);for(var e=aR.length;e--;)delete e0[BE][aR[e]];return e0()};cPe[lU]=!0;var pPe=Object.create||function(t,n){var r;return t!==null?(ZI[BE]=sPe(t),r=new ZI,ZI[BE]=null,r[lU]=t):r=e0(),n===void 0?r:lPe(r,n)},mPe=ka,gPe=yi,vPe=gPe.RegExp,yPe=mPe(function(){var e=vPe(".","s");return!(e.dotAll&&e.exec(`
|
|
|
`)&&e.flags==="s")}),bPe=ka,wPe=yi,SPe=wPe.RegExp,TPe=bPe(function(){var e=SPe("(?<a>b)","g");return e.exec("b").groups.a!=="b"||"b".replace(e,"$<a>c")!=="bc"}),xPe=hT,IPe=iU,uR=V2,kPe=H2,EPe=pPe,CPe=KY.get,MPe=yPe,DPe=TPe,Z0=RegExp.prototype.exec,APe=kPe("native-string-replace",String.prototype.replace),UE=Z0,zE=function(){var e=/a/,t=/b*/g;return Z0.call(e,"a"),Z0.call(t,"a"),e.lastIndex!==0||t.lastIndex!==0}(),uU=uR.UNSUPPORTED_Y||uR.BROKEN_CARET,VE=/()??/.exec("")[1]!==void 0,NPe=zE||VE||uU||MPe||DPe;NPe&&(UE=function(t){var n=this,r=CPe(n),o=xPe(t),i=r.raw,a,s,l,u,d,h,p;if(i)return i.lastIndex=n.lastIndex,a=UE.call(i,o),n.lastIndex=i.lastIndex,a;var m=r.groups,b=uU&&n.sticky,v=IPe.call(n),y=n.source,S=0,x=o;if(b&&(v=v.replace("y",""),v.indexOf("g")===-1&&(v+="g"),x=o.slice(n.lastIndex),n.lastIndex>0&&(!n.multiline||n.multiline&&o.charAt(n.lastIndex-1)!==`
|
|
|
`)&&(y="(?: "+y+")",x=" "+x,S++),s=new RegExp("^(?:"+y+")",v)),VE&&(s=new RegExp("^"+y+"$(?!\\s)",v)),zE&&(l=n.lastIndex),u=Z0.call(b?s:n,x),b?u?(u.input=u.input.slice(S),u[0]=u[0].slice(S),u.index=n.lastIndex,n.lastIndex+=u[0].length):n.lastIndex=0:zE&&u&&(n.lastIndex=n.global?u.index+u[0].length:l),VE&&u&&u.length>1&&APe.call(u[0],s,function(){for(d=1;d<arguments.length-2;d++)arguments[d]===void 0&&(u[d]=void 0)}),u&&m)for(u.groups=h=EPe(null),d=0;d<m.length;d++)p=m[d],h[p[0]]=u[p[1]];return u});var W2=UE,OPe=_Oe,dR=W2;OPe({target:"RegExp",proto:!0,forced:/./.exec!==dR},{exec:dR});var fR=Nv,PPe=W2,hR=ka,dU=Dv,jPe=dT,LPe=dU("species"),$I=RegExp.prototype,RPe=function(e,t,n,r){var o=dU(e),i=!hR(function(){var u={};return u[o]=function(){return 7},""[e](u)!=7}),a=i&&!hR(function(){var u=!1,d=/a/;return e==="split"&&(d={},d.constructor={},d.constructor[LPe]=function(){return d},d.flags="",d[o]=/./[o]),d.exec=function(){return u=!0,null},d[o](""),!u});if(!i||!a||n){var s=/./[o],l=t(o,""[e],function(u,d,h,p,m){var b=d.exec;return b===PPe||b===$I.exec?i&&!m?{done:!0,value:s.call(d,h,p)}:{done:!0,value:u.call(h,d,p)}:{done:!1}});fR(String.prototype,e,l[0]),fR($I,o,l[1])}r&&jPe($I[o],"sham",!0)},FPe=fT,HPe=hT,_Pe=cT,pR=function(e){return function(t,n){var r=HPe(_Pe(t)),o=FPe(n),i=r.length,a,s;return o<0||o>=i?e?"":void 0:(a=r.charCodeAt(o),a<55296||a>56319||o+1===i||(s=r.charCodeAt(o+1))<56320||s>57343?e?r.charAt(o):a:e?r.slice(o,o+2):(a-55296<<10)+(s-56320)+65536)}},BPe={codeAt:pR(!1),charAt:pR(!0)},YPe=BPe.charAt,UPe=function(e,t,n){return t+(n?YPe(e,t).length:1)},zPe=UY,VPe=Math.floor,WPe="".replace,GPe=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,ZPe=/\$([$&'`]|\d{1,2})/g,$Pe=function(e,t,n,r,o,i){var a=n+e.length,s=r.length,l=ZPe;return o!==void 0&&(o=zPe(o),l=GPe),WPe.call(i,l,function(u,d){var h;switch(d.charAt(0)){case"$":return"$";case"&":return e;case"`":return t.slice(0,n);case"'":return t.slice(a);case"<":h=o[d.slice(1,-1)];break;default:var p=+d;if(p===0)return u;if(p>s){var m=VPe(p/10);return m===0?u:m<=s?r[m-1]===void 0?d.charAt(1):r[m-1]+d.charAt(1):u}h=r[p-1]}return h===void 0?"":h})},qPe=Cc,KPe=Wi,XPe=j2,JPe=W2,QPe=function(e,t){var n=e.exec;if(KPe(n)){var r=n.call(e,t);return r!==null&&qPe(r),r}if(XPe(e)==="RegExp")return JPe.call(e,t);throw TypeError("RegExp#exec called on incompatible receiver")},e3e=RPe,t3e=ka,n3e=Cc,r3e=Wi,o3e=fT,i3e=eU,$d=hT,a3e=cT,s3e=UPe,l3e=BY,c3e=$Pe,u3e=QPe,d3e=Dv,WE=d3e("replace"),f3e=Math.max,h3e=Math.min,p3e=function(e){return e===void 0?e:String(e)},m3e=function(){return"a".replace(/./,"$0")==="$0"}(),mR=function(){return/./[WE]?/./[WE]("a","$0")==="":!1}(),g3e=!t3e(function(){var e=/./;return e.exec=function(){var t=[];return t.groups={a:"7"},t},"".replace(e,"$<a>")!=="7"});e3e("replace",function(e,t,n){var r=mR?"$":"$0";return[function(i,a){var s=a3e(this),l=i==null?void 0:l3e(i,WE);return l?l.call(i,s,a):t.call($d(s),i,a)},function(o,i){var a=n3e(this),s=$d(o);if(typeof i=="string"&&i.indexOf(r)===-1&&i.indexOf("$<")===-1){var l=n(t,a,s,i);if(l.done)return l.value}var u=r3e(i);u||(i=$d(i));var d=a.global;if(d){var h=a.unicode;a.lastIndex=0}for(var p=[];;){var m=u3e(a,s);if(m===null||(p.push(m),!d))break;var b=$d(m[0]);b===""&&(a.lastIndex=s3e(s,i3e(a.lastIndex),h))}for(var v="",y=0,S=0;S<p.length;S++){m=p[S];for(var x=$d(m[0]),C=f3e(h3e(o3e(m.index),s.length),0),k=[],M=1;M<m.length;M++)k.push(p3e(m[M]));var I=m.groups;if(u){var O=[x].concat(k,C,s);I!==void 0&&O.push(I);var R=$d(i.apply(void 0,O))}else R=c3e(x,s,C,k,I,i);C>=y&&(v+=s.slice(y,C)+R,y=C+x.length)}return v+s.slice(y)}]},!g3e||!m3e||mR);var v3e=typeof Bun=="function"&&Bun&&typeof Bun.version=="string",y3e=TypeError,b3e=function(e,t){if(e<t)throw new y3e("Not enough arguments");return e},fU=_r,w3e=qD,S3e=oo,T3e=v3e,x3e=hB,I3e=QS,k3e=b3e,E3e=fU.Function,C3e=/MSIE .\./.test(x3e)||T3e&&function(){var e=fU.Bun.version.split(".");return e.length<3||e[0]==="0"&&(e[1]<3||e[1]==="3"&&e[2]==="0")}(),hU=function(e,t){var n=t?2:1;return C3e?function(r,o){var i=k3e(arguments.length,1)>n,a=S3e(r)?r:E3e(r),s=i?I3e(arguments,n):[],l=i?function(){w3e(a,this,s)}:a;return t?e(l,o):e(l)}:e},M3e=dn,pU=_r,D3e=hU,gR=D3e(pU.setInterval,!0);M3e({global:!0,bind:!0,forced:pU.setInterval!==gR},{setInterval:gR});var A3e=dn,mU=_r,N3e=hU,vR=N3e(mU.setTimeout,!0);A3e({global:!0,bind:!0,forced:mU.setTimeout!==vR},{setTimeout:vR});var O3e=Br,P3e=O3e.setInterval,j3e=P3e;const L3e=tt(j3e);var R3e=hr,gU=function(e,t){var n=[][e];return!!n&&R3e(function(){n.call(null,t||function(){return 1},1)})},F3e=dn,H3e=KD,_3e=MB.indexOf,B3e=gU,GE=H3e([].indexOf),vU=!!GE&&1/GE([1],1,-0)<0,Y3e=vU||!B3e("indexOf");F3e({target:"Array",proto:!0,forced:Y3e},{indexOf:function(t){var n=arguments.length>1?arguments[1]:void 0;return vU?GE(this,t,n)||0:_3e(this,t,n)}});var U3e=rd,z3e=U3e("Array","indexOf"),V3e=Ml,W3e=z3e,qI=Array.prototype,G3e=function(e){var t=e.indexOf;return e===qI||V3e(qI,e)&&t===qI.indexOf?W3e:t},Z3e=G3e,$3e=Z3e,q3e=$3e;const K3e=tt(q3e);var yR=WS,X3e=TypeError,J3e=function(e,t){if(!delete e[t])throw new X3e("Cannot delete property "+yR(t)+" of "+yR(e))},Q3e=dn,eje=Dl,tje=f2,nje=ZS,rje=nd,oje=TY,ije=s2,aje=d2,sje=Sv,KI=J3e,lje=$S,cje=lje("splice"),uje=Math.max,dje=Math.min;Q3e({target:"Array",proto:!0,forced:!cje},{splice:function(t,n){var r=eje(this),o=rje(r),i=tje(t,o),a=arguments.length,s,l,u,d,h,p;for(a===0?s=l=0:a===1?(s=0,l=o-i):(s=a-2,l=dje(uje(nje(n),0),o-i)),ije(o+s-l),u=aje(r,l),d=0;d<l;d++)h=i+d,h in r&&sje(u,d,r[h]);if(u.length=l,s<l){for(d=i;d<o-l;d++)h=d+l,p=d+s,h in r?r[p]=r[h]:KI(r,p);for(d=o;d>o-l+s;d--)KI(r,d-1)}else if(s>l)for(d=o-l;d>i;d--)h=d+l-1,p=d+s-1,h in r?r[p]=r[h]:KI(r,p);for(d=0;d<s;d++)r[d+i]=arguments[d+2];return oje(r,o-l+s),u}});var fje=rd,hje=fje("Array","splice"),pje=Ml,mje=hje,XI=Array.prototype,gje=function(e){var t=e.splice;return e===XI||pje(XI,e)&&t===XI.splice?mje:t},vje=gje,yje=vje,bje=yje;const wje=tt(bje);var Sje=rd,Tje=Sje("Array","concat"),xje=Ml,Ije=Tje,JI=Array.prototype,kje=function(e){var t=e.concat;return e===JI||xje(JI,e)&&t===JI.concat?Ije:t},Eje=kje,Cje=Eje,Mje=Cje;const Fn=tt(Mje);var Dje=dn,Aje=pr,yU=Date,Nje=Aje(yU.prototype.getTime);Dje({target:"Date",stat:!0},{now:function(){return Nje(new yU)}});var Oje=Br,Pje=Oje.Date.now,jje=Pje,Lje=jje,Rje=Lje;const mc=tt(Rje);var Fje=v2.forEach,Hje=gU,_je=Hje("forEach"),Bje=_je?[].forEach:function(t){return Fje(this,t,arguments.length>1?arguments[1]:void 0)},Yje=dn,bR=Bje;Yje({target:"Array",proto:!0,forced:[].forEach!==bR},{forEach:bR});var Uje=rd,zje=Uje("Array","forEach"),Vje=zje,Wje=Vje,Gje=Tv,Zje=vi,$je=Ml,qje=Wje,QI=Array.prototype,Kje={DOMTokenList:!0,NodeList:!0},Xje=function(e){var t=e.forEach;return e===QI||$je(QI,e)&&t===QI.forEach||Zje(Kje,Gje(e))?qje:t},Jje=Xje;const $0=tt(Jje);var Qje=dn,e4e=Dl,bU=p2,t4e=hr,n4e=t4e(function(){bU(1)});Qje({target:"Object",stat:!0,forced:n4e},{keys:function(t){return bU(e4e(t))}});var r4e=Br,o4e=r4e.Object.keys,i4e=o4e,a4e=i4e,s4e=a4e;const l4e=tt(s4e);var c4e=Br,u4e=c4e.Object.getOwnPropertySymbols,d4e=u4e,f4e=d4e,h4e=f4e;const wR=tt(h4e);var p4e=dn,m4e=v2.filter,g4e=$S,v4e=g4e("filter");p4e({target:"Array",proto:!0,forced:!v4e},{filter:function(t){return m4e(this,t,arguments.length>1?arguments[1]:void 0)}});var y4e=rd,b4e=y4e("Array","filter"),w4e=Ml,S4e=b4e,ek=Array.prototype,T4e=function(e){var t=e.filter;return e===ek||w4e(ek,e)&&t===ek.filter?S4e:t},x4e=T4e,I4e=x4e,k4e=I4e;const E4e=tt(k4e);var wU={exports:{}},C4e=dn,M4e=hr,D4e=ks,SU=vv.f,TU=Zo,A4e=!TU||M4e(function(){SU(1)});C4e({target:"Object",stat:!0,forced:A4e,sham:!TU},{getOwnPropertyDescriptor:function(t,n){return SU(D4e(t),n)}});var N4e=Br,xU=N4e.Object,O4e=wU.exports=function(t,n){return xU.getOwnPropertyDescriptor(t,n)};xU.getOwnPropertyDescriptor.sham&&(O4e.sham=!0);var P4e=wU.exports,j4e=P4e,L4e=j4e,R4e=L4e;const IU=tt(R4e);var F4e=Es,H4e=pr,_4e=JS,B4e=eT,Y4e=Ec,U4e=H4e([].concat),z4e=F4e("Reflect","ownKeys")||function(t){var n=_4e.f(Y4e(t)),r=B4e.f;return r?U4e(n,r(t)):n},V4e=dn,W4e=Zo,G4e=z4e,Z4e=ks,$4e=vv,q4e=Sv;V4e({target:"Object",stat:!0,sham:!W4e},{getOwnPropertyDescriptors:function(t){for(var n=Z4e(t),r=$4e.f,o=G4e(n),i={},a=0,s,l;o.length>a;)l=r(n,s=o[a++]),l!==void 0&&q4e(i,s,l);return i}});var K4e=Br,X4e=K4e.Object.getOwnPropertyDescriptors,J4e=X4e,Q4e=J4e,eLe=Q4e;const SR=tt(eLe);var kU={exports:{}},tLe=dn,nLe=Zo,TR=qS.f;tLe({target:"Object",stat:!0,forced:Object.defineProperties!==TR,sham:!nLe},{defineProperties:TR});var rLe=Br,EU=rLe.Object,oLe=kU.exports=function(t,n){return EU.defineProperties(t,n)};EU.defineProperties.sham&&(oLe.sham=!0);var iLe=kU.exports,aLe=iLe,sLe=aLe,lLe=sLe;const cLe=tt(lLe);var uLe=NY;const dLe=tt(uLe);function fLe(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function hLe(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var pLe=function(){function e(n){var r=this;this._insertTag=function(o){var i;r.tags.length===0?r.insertionPoint?i=r.insertionPoint.nextSibling:r.prepend?i=r.container.firstChild:i=r.before:i=r.tags[r.tags.length-1].nextSibling,r.container.insertBefore(o,i),r.tags.push(o)},this.isSpeedy=n.speedy===void 0?!0:n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.prepend=n.prepend,this.insertionPoint=n.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(r){r.forEach(this._insertTag)},t.insert=function(r){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(hLe(this));var o=this.tags[this.tags.length-1];if(this.isSpeedy){var i=fLe(o);try{i.insertRule(r,i.cssRules.length)}catch{}}else o.appendChild(document.createTextNode(r));this.ctr++},t.flush=function(){this.tags.forEach(function(r){return r.parentNode&&r.parentNode.removeChild(r)}),this.tags=[],this.ctr=0},e}(),Jr="-ms-",q0="-moz-",Xt="-webkit-",CU="comm",G2="rule",Z2="decl",mLe="@import",MU="@keyframes",gLe="@layer",vLe=Math.abs,pT=String.fromCharCode,yLe=Object.assign;function bLe(e,t){return Lr(e,0)^45?(((t<<2^Lr(e,0))<<2^Lr(e,1))<<2^Lr(e,2))<<2^Lr(e,3):0}function DU(e){return e.trim()}function wLe(e,t){return(e=t.exec(e))?e[0]:e}function Jt(e,t,n){return e.replace(t,n)}function ZE(e,t){return e.indexOf(t)}function Lr(e,t){return e.charCodeAt(t)|0}function ng(e,t,n){return e.slice(t,n)}function ts(e){return e.length}function $2(e){return e.length}function mb(e,t){return t.push(e),e}function SLe(e,t){return e.map(t).join("")}var mT=1,Lf=1,AU=0,Go=0,rr=0,Hh="";function gT(e,t,n,r,o,i,a){return{value:e,root:t,parent:n,type:r,props:o,children:i,line:mT,column:Lf,length:a,return:""}}function Hp(e,t){return yLe(gT("",null,null,"",null,null,0),e,{length:-e.length},t)}function TLe(){return rr}function xLe(){return rr=Go>0?Lr(Hh,--Go):0,Lf--,rr===10&&(Lf=1,mT--),rr}function di(){return rr=Go<AU?Lr(Hh,Go++):0,Lf++,rr===10&&(Lf=1,mT++),rr}function fs(){return Lr(Hh,Go)}function t0(){return Go}function Pv(e,t){return ng(Hh,e,t)}function rg(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function NU(e){return mT=Lf=1,AU=ts(Hh=e),Go=0,[]}function OU(e){return Hh="",e}function n0(e){return DU(Pv(Go-1,$E(e===91?e+2:e===40?e+1:e)))}function ILe(e){for(;(rr=fs())&&rr<33;)di();return rg(e)>2||rg(rr)>3?"":" "}function kLe(e,t){for(;--t&&di()&&!(rr<48||rr>102||rr>57&&rr<65||rr>70&&rr<97););return Pv(e,t0()+(t<6&&fs()==32&&di()==32))}function $E(e){for(;di();)switch(rr){case e:return Go;case 34:case 39:e!==34&&e!==39&&$E(rr);break;case 40:e===41&&$E(e);break;case 92:di();break}return Go}function ELe(e,t){for(;di()&&e+rr!==57;)if(e+rr===84&&fs()===47)break;return"/*"+Pv(t,Go-1)+"*"+pT(e===47?e:di())}function CLe(e){for(;!rg(fs());)di();return Pv(e,Go)}function MLe(e){return OU(r0("",null,null,null,[""],e=NU(e),0,[0],e))}function r0(e,t,n,r,o,i,a,s,l){for(var u=0,d=0,h=a,p=0,m=0,b=0,v=1,y=1,S=1,x=0,C="",k=o,M=i,I=r,O=C;y;)switch(b=x,x=di()){case 40:if(b!=108&&Lr(O,h-1)==58){ZE(O+=Jt(n0(x),"&","&\f"),"&\f")!=-1&&(S=-1);break}case 34:case 39:case 91:O+=n0(x);break;case 9:case 10:case 13:case 32:O+=ILe(b);break;case 92:O+=kLe(t0()-1,7);continue;case 47:switch(fs()){case 42:case 47:mb(DLe(ELe(di(),t0()),t,n),l);break;default:O+="/"}break;case 123*v:s[u++]=ts(O)*S;case 125*v:case 59:case 0:switch(x){case 0:case 125:y=0;case 59+d:S==-1&&(O=Jt(O,/\f/g,"")),m>0&&ts(O)-h&&mb(m>32?IR(O+";",r,n,h-1):IR(Jt(O," ","")+";",r,n,h-2),l);break;case 59:O+=";";default:if(mb(I=xR(O,t,n,u,d,o,s,C,k=[],M=[],h),i),x===123)if(d===0)r0(O,t,I,I,k,i,h,s,M);else switch(p===99&&Lr(O,3)===110?100:p){case 100:case 108:case 109:case 115:r0(e,I,I,r&&mb(xR(e,I,I,0,0,o,s,C,o,k=[],h),M),o,M,h,s,r?k:M);break;default:r0(O,I,I,I,[""],M,0,s,M)}}u=d=m=0,v=S=1,C=O="",h=a;break;case 58:h=1+ts(O),m=b;default:if(v<1){if(x==123)--v;else if(x==125&&v++==0&&xLe()==125)continue}switch(O+=pT(x),x*v){case 38:S=d>0?1:(O+="\f",-1);break;case 44:s[u++]=(ts(O)-1)*S,S=1;break;case 64:fs()===45&&(O+=n0(di())),p=fs(),d=h=ts(C=O+=CLe(t0())),x++;break;case 45:b===45&&ts(O)==2&&(v=0)}}return i}function xR(e,t,n,r,o,i,a,s,l,u,d){for(var h=o-1,p=o===0?i:[""],m=$2(p),b=0,v=0,y=0;b<r;++b)for(var S=0,x=ng(e,h+1,h=vLe(v=a[b])),C=e;S<m;++S)(C=DU(v>0?p[S]+" "+x:Jt(x,/&\f/g,p[S])))&&(l[y++]=C);return gT(e,t,n,o===0?G2:s,l,u,d)}function DLe(e,t,n){return gT(e,t,n,CU,pT(TLe()),ng(e,2,-2),0)}function IR(e,t,n,r){return gT(e,t,n,Z2,ng(e,0,r),ng(e,r+1,-1),r)}function mf(e,t){for(var n="",r=$2(e),o=0;o<r;o++)n+=t(e[o],o,e,t)||"";return n}function ALe(e,t,n,r){switch(e.type){case gLe:if(e.children.length)break;case mLe:case Z2:return e.return=e.return||e.value;case CU:return"";case MU:return e.return=e.value+"{"+mf(e.children,r)+"}";case G2:e.value=e.props.join(",")}return ts(n=mf(e.children,r))?e.return=e.value+"{"+n+"}":""}function NLe(e){var t=$2(e);return function(n,r,o,i){for(var a="",s=0;s<t;s++)a+=e[s](n,r,o,i)||"";return a}}function OLe(e){return function(t){t.root||(t=t.return)&&e(t)}}function PLe(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var jLe=function(t,n,r){for(var o=0,i=0;o=i,i=fs(),o===38&&i===12&&(n[r]=1),!rg(i);)di();return Pv(t,Go)},LLe=function(t,n){var r=-1,o=44;do switch(rg(o)){case 0:o===38&&fs()===12&&(n[r]=1),t[r]+=jLe(Go-1,n,r);break;case 2:t[r]+=n0(o);break;case 4:if(o===44){t[++r]=fs()===58?"&\f":"",n[r]=t[r].length;break}default:t[r]+=pT(o)}while(o=di());return t},RLe=function(t,n){return OU(LLe(NU(t),n))},kR=new WeakMap,FLe=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var n=t.value,r=t.parent,o=t.column===r.column&&t.line===r.line;r.type!=="rule";)if(r=r.parent,!r)return;if(!(t.props.length===1&&n.charCodeAt(0)!==58&&!kR.get(r))&&!o){kR.set(t,!0);for(var i=[],a=RLe(n,i),s=r.props,l=0,u=0;l<a.length;l++)for(var d=0;d<s.length;d++,u++)t.props[u]=i[l]?a[l].replace(/&\f/g,s[d]):s[d]+" "+a[l]}}},HLe=function(t){if(t.type==="decl"){var n=t.value;n.charCodeAt(0)===108&&n.charCodeAt(2)===98&&(t.return="",t.value="")}};function PU(e,t){switch(bLe(e,t)){case 5103:return Xt+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return Xt+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return Xt+e+q0+e+Jr+e+e;case 6828:case 4268:return Xt+e+Jr+e+e;case 6165:return Xt+e+Jr+"flex-"+e+e;case 5187:return Xt+e+Jt(e,/(\w+).+(:[^]+)/,Xt+"box-$1$2"+Jr+"flex-$1$2")+e;case 5443:return Xt+e+Jr+"flex-item-"+Jt(e,/flex-|-self/,"")+e;case 4675:return Xt+e+Jr+"flex-line-pack"+Jt(e,/align-content|flex-|-self/,"")+e;case 5548:return Xt+e+Jr+Jt(e,"shrink","negative")+e;case 5292:return Xt+e+Jr+Jt(e,"basis","preferred-size")+e;case 6060:return Xt+"box-"+Jt(e,"-grow","")+Xt+e+Jr+Jt(e,"grow","positive")+e;case 4554:return Xt+Jt(e,/([^-])(transform)/g,"$1"+Xt+"$2")+e;case 6187:return Jt(Jt(Jt(e,/(zoom-|grab)/,Xt+"$1"),/(image-set)/,Xt+"$1"),e,"")+e;case 5495:case 3959:return Jt(e,/(image-set\([^]*)/,Xt+"$1$`$1");case 4968:return Jt(Jt(e,/(.+:)(flex-)?(.*)/,Xt+"box-pack:$3"+Jr+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Xt+e+e;case 4095:case 3583:case 4068:case 2532:return Jt(e,/(.+)-inline(.+)/,Xt+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(ts(e)-1-t>6)switch(Lr(e,t+1)){case 109:if(Lr(e,t+4)!==45)break;case 102:return Jt(e,/(.+:)(.+)-([^]+)/,"$1"+Xt+"$2-$3$1"+q0+(Lr(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~ZE(e,"stretch")?PU(Jt(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Lr(e,t+1)!==115)break;case 6444:switch(Lr(e,ts(e)-3-(~ZE(e,"!important")&&10))){case 107:return Jt(e,":",":"+Xt)+e;case 101:return Jt(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Xt+(Lr(e,14)===45?"inline-":"")+"box$3$1"+Xt+"$2$3$1"+Jr+"$2box$3")+e}break;case 5936:switch(Lr(e,t+11)){case 114:return Xt+e+Jr+Jt(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return Xt+e+Jr+Jt(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return Xt+e+Jr+Jt(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return Xt+e+Jr+e+e}return e}var _Le=function(t,n,r,o){if(t.length>-1&&!t.return)switch(t.type){case Z2:t.return=PU(t.value,t.length);break;case MU:return mf([Hp(t,{value:Jt(t.value,"@","@"+Xt)})],o);case G2:if(t.length)return SLe(t.props,function(i){switch(wLe(i,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return mf([Hp(t,{props:[Jt(i,/:(read-\w+)/,":"+q0+"$1")]})],o);case"::placeholder":return mf([Hp(t,{props:[Jt(i,/:(plac\w+)/,":"+Xt+"input-$1")]}),Hp(t,{props:[Jt(i,/:(plac\w+)/,":"+q0+"$1")]}),Hp(t,{props:[Jt(i,/:(plac\w+)/,Jr+"input-$1")]})],o)}return""})}},BLe=[_Le],YLe=function(t){var n=t.key;if(n==="css"){var r=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(r,function(v){var y=v.getAttribute("data-emotion");y.indexOf(" ")!==-1&&(document.head.appendChild(v),v.setAttribute("data-s",""))})}var o=t.stylisPlugins||BLe,i={},a,s=[];a=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(v){for(var y=v.getAttribute("data-emotion").split(" "),S=1;S<y.length;S++)i[y[S]]=!0;s.push(v)});var l,u=[FLe,HLe],d,h=[ALe,OLe(function(v){d.insert(v)})],p=NLe(u.concat(o,h)),m=function(y){return mf(MLe(y),p)};l=function(y,S,x,C){d=x,m(y?y+"{"+S.styles+"}":S.styles),C&&(b.inserted[S.name]=!0)};var b={key:n,sheet:new pLe({key:n,container:a,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:i,registered:{},insert:l};return b.sheet.hydrate(s),b};function ULe(e){for(var t=0,n,r=0,o=e.length;o>=4;++r,o-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var zLe={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},VLe=/[A-Z]|^ms/g,WLe=/_EMO_([^_]+?)_([^]*?)_EMO_/g,jU=function(t){return t.charCodeAt(1)===45},ER=function(t){return t!=null&&typeof t!="boolean"},tk=PLe(function(e){return jU(e)?e:e.replace(VLe,"-$&").toLowerCase()}),CR=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(WLe,function(r,o,i){return ns={name:o,styles:i,next:ns},o})}return zLe[t]!==1&&!jU(t)&&typeof n=="number"&&n!==0?n+"px":n};function og(e,t,n){if(n==null)return"";if(n.__emotion_styles!==void 0)return n;switch(typeof n){case"boolean":return"";case"object":if(n.anim===1)return ns={name:n.name,styles:n.styles,next:ns},n.name;if(n.styles!==void 0){var r=n.next;if(r!==void 0)for(;r!==void 0;)ns={name:r.name,styles:r.styles,next:ns},r=r.next;var o=n.styles+";";return o}return GLe(e,t,n);case"function":if(e!==void 0){var i=ns,a=n(e);return ns=i,og(e,t,a)}break}if(t==null)return n;var s=t[n];return s!==void 0?s:n}function GLe(e,t,n){var r="";if(Array.isArray(n))for(var o=0;o<n.length;o++)r+=og(e,t,n[o])+";";else for(var i in n){var a=n[i];if(typeof a!="object")t!=null&&t[a]!==void 0?r+=i+"{"+t[a]+"}":ER(a)&&(r+=tk(i)+":"+CR(i,a)+";");else if(Array.isArray(a)&&typeof a[0]=="string"&&(t==null||t[a[0]]===void 0))for(var s=0;s<a.length;s++)ER(a[s])&&(r+=tk(i)+":"+CR(i,a[s])+";");else{var l=og(e,t,a);switch(i){case"animation":case"animationName":r+=tk(i)+":"+l+";";break;default:r+=i+"{"+l+"}"}}}return r}var MR=/label:\s*([^\s;\n{]+)\s*(;|$)/g,ns,nk=function(t,n,r){if(t.length===1&&typeof t[0]=="object"&&t[0]!==null&&t[0].styles!==void 0)return t[0];var o=!0,i="";ns=void 0;var a=t[0];a==null||a.raw===void 0?(o=!1,i+=og(r,n,a)):i+=a[0];for(var s=1;s<t.length;s++)i+=og(r,n,t[s]),o&&(i+=a[s]);MR.lastIndex=0;for(var l="",u;(u=MR.exec(i))!==null;)l+="-"+u[1];var d=ULe(i)+l;return{name:d,styles:i,next:ns}},ZLe=!0;function LU(e,t,n){var r="";return n.split(" ").forEach(function(o){e[o]!==void 0?t.push(e[o]+";"):r+=o+" "}),r}var $Le=function(t,n,r){var o=t.key+"-"+n.name;(r===!1||ZLe===!1)&&t.registered[o]===void 0&&(t.registered[o]=n.styles)},qLe=function(t,n,r){$Le(t,n,r);var o=t.key+"-"+n.name;if(t.inserted[n.name]===void 0){var i=n;do t.insert(n===i?"."+o:"",i,t.sheet,!0),i=i.next;while(i!==void 0)}};function DR(e,t){if(e.inserted[t.name]===void 0)return e.insert("",t,e.sheet,!0)}function AR(e,t,n){var r=[],o=LU(e,r,n);return r.length<2?n:o+t(r)}var KLe=function(t){var n=YLe(t);n.sheet.speedy=function(s){this.isSpeedy=s},n.compat=!0;var r=function(){for(var l=arguments.length,u=new Array(l),d=0;d<l;d++)u[d]=arguments[d];var h=nk(u,n.registered,void 0);return qLe(n,h,!1),n.key+"-"+h.name},o=function(){for(var l=arguments.length,u=new Array(l),d=0;d<l;d++)u[d]=arguments[d];var h=nk(u,n.registered),p="animation-"+h.name;return DR(n,{name:h.name,styles:"@keyframes "+p+"{"+h.styles+"}"}),p},i=function(){for(var l=arguments.length,u=new Array(l),d=0;d<l;d++)u[d]=arguments[d];var h=nk(u,n.registered);DR(n,h)},a=function(){for(var l=arguments.length,u=new Array(l),d=0;d<l;d++)u[d]=arguments[d];return AR(n.registered,r,XLe(u))};return{css:r,cx:a,injectGlobal:i,keyframes:o,hydrate:function(l){l.forEach(function(u){n.inserted[u]=!0})},flush:function(){n.registered={},n.inserted={},n.sheet.flush()},sheet:n.sheet,cache:n,getRegisteredStyles:LU.bind(null,n.registered),merge:AR.bind(null,n.registered,r)}},XLe=function e(t){for(var n="",r=0;r<t.length;r++){var o=t[r];if(o!=null){var i=void 0;switch(typeof o){case"boolean":break;case"object":if(Array.isArray(o))i=e(o);else{i="";for(var a in o)o[a]&&a&&(i&&(i+=" "),i+=a)}break;default:i=o}i&&(n&&(n+=" "),n+=i)}}return n},JLe=Nv,q2=Date.prototype,NR="Invalid Date",RU="toString",QLe=q2[RU],eRe=q2.getTime;String(new Date(NaN))!=NR&&JLe(q2,RU,function(){var t=eRe.call(this);return t===t?QLe.call(this):NR});var tRe=z2,nRe=oU,rRe=tRe?{}.toString:function(){return"[object "+nRe(this)+"]"},oRe=z2,iRe=Nv,aRe=rRe;oRe||iRe(Object.prototype,"toString",aRe,{unsafe:!0});var sRe=Y2.PROPER,lRe=Nv,cRe=Cc,OR=hT,uRe=ka,dRe=iU,K2="toString",FU=RegExp.prototype,HU=FU[K2],fRe=uRe(function(){return HU.call({source:"a",flags:"b"})!="/a/b"}),hRe=sRe&&HU.name!=K2;(fRe||hRe)&&lRe(RegExp.prototype,K2,function(){var t=cRe(this),n=OR(t.source),r=t.flags,o=OR(r===void 0&&t instanceof RegExp&&!("flags"in FU)?dRe.call(t):r);return"/"+n+"/"+o},{unsafe:!0});var PR=typeof window<"u"?window:self,pRe=PR.crypto||PR.msCrypto,mRe=function(e){if(!e)return Math.random;var t=Math.pow(2,32),n=new Uint32Array(1);return function(){return e.getRandomValues(n)[0]/t}}(pRe);const gRe=tt(mRe);function vRe(){return gRe().toString(26).substr(2,5).replace(/[0-9]/g,function(e){return String.fromCharCode(e.charCodeAt(0)+65)})}var yRe=wB;const jR=tt(yRe);function nn(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"white",n="background-color: ".concat(e,"; border-radius: 4px; padding: 2px 4px;");return t&&(n+=" color: ".concat(t,";")),[n,""]}function LR(e,t){for(var n,r,o=arguments.length,i=new Array(o>2?o-2:0),a=2;a<o;a++)i[a-2]=arguments[a];return Fn(n=[Fn(r="%c".concat(e,"%c ")).call(r,t)]).call(n,Bt(nn("green","white")),i)}function bRe(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.force,r=n===void 0?!1:n;return r?function(){for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];if(i.length){var s=i,l=Ja(s,1),u=l[0];typeof u=="function"&&(i=u());var d=jR(i[0])?i:[i],h=d.length===1;$0(d).call(d,function(p,m){if(h){var b,v;(b=console).log.apply(b,Bt(LR.apply(void 0,Fn(v=[e]).call(v,Bt(p)))))}else if(m){var y;(y=console).log.apply(y,Bt(jR(p)?p:[p]))}else{var S,x;(S=console).groupCollapsed.apply(S,Bt(LR.apply(void 0,Fn(x=[e]).call(x,Bt(p)))))}}),h||console.groupEnd()}}:function(){return 0}}var wRe=od,SRe=Y2.EXISTS,TRe=Av.f,_U=Function.prototype,xRe=_U.toString,IRe=/^\s*function ([^ (]*)/,kRe="name";wRe&&!SRe&&TRe(_U,kRe,{configurable:!0,get:function(){try{return xRe.call(this).match(IRe)[1]}catch{return""}}});var ERe=Br,CRe=ERe.setTimeout,MRe=CRe;const DRe=tt(MRe);function ARe(e,t){if(!t)return e;var n=0,r=null;return function(){for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];var s=mc();s-n>t?(e.apply(void 0,i),n=s):(clearTimeout(r),r=DRe(function(){e.apply(void 0,i),n=mc()},Math.max(0,t-s+n)))}}var BU=function(t){var n=t.debounce,r=t.name,o=t.onEvent,i=t.target,a=D.useRef();a.current=o;var s=D.useMemo(function(){return ARe(function(u){var d=a.current;d&&d(u)},n)},[n,a]),l=D.useCallback(function(u){u.timeStampLow=mc(),s(u)},[s]);return D.useLayoutEffect(function(){return i.addEventListener(r,l,{passive:!0}),l({target:i,type:r}),function(){return i.removeEventListener(r,l)}},[r,l,i]),!1};BU.defaultProps={debounce:200};var NRe=Math.sign||function(t){var n=+t;return n===0||n!==n?n:n<0?-1:1},ORe=dn,PRe=NRe;ORe({target:"Math",stat:!0},{sign:PRe});var jRe=Br,LRe=jRe.Math.sign,RRe=LRe,FRe=RRe,HRe=FRe;const _Re=tt(HRe);function BRe(e,t){var n=_Re(t-e),r=Math.sqrt(Math.abs(t-e)),o=e+r*n;return n>0?Math.min(t,o):Math.max(t,o)}function YRe(e,t,n,r){for(var o=e,i=0;i<r;i++)o=n(o,t);return o}var YU=function(t){var n=t.name,r=t.onEnd,o=t.target,i=t.value,a=D.useRef(),s=D.useCallback(function(u,d,h,p){var m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:mc();(h==="100%"||typeof h=="number")&&(cancelAnimationFrame(a.current),a.current=requestAnimationFrame(function(){if(o){var b=h==="100%"?o.scrollHeight-o.offsetHeight:h,v=YRe(d,b,BRe,(mc()-m)/5);Math.abs(b-v)<1.5&&(v=b),o[u]=v,b===v?r&&r(!0):s(u,d,h,p+1,m)}}))},[a,r,o]),l=D.useCallback(function(){cancelAnimationFrame(a.current),r&&r(!1)},[r]);return D.useLayoutEffect(function(){return s(n,o[n],i,1),o?(o.addEventListener("pointerdown",l,{passive:!0}),o.addEventListener("wheel",l,{passive:!0}),function(){o.removeEventListener("pointerdown",l),o.removeEventListener("wheel",l),cancelAnimationFrame(a.current)}):function(){return cancelAnimationFrame(a.current)}},[s,a,l,n,o,i]),!1};YU.propTypes={name:Vt.string.isRequired,onEnd:Vt.func,target:Vt.any.isRequired,value:Vt.oneOfType([Vt.number,Vt.oneOf(["100%"])]).isRequired};function rk(e){var t=D.useState(e),n=Ja(t,2),r=n[0],o=n[1],i=D.useRef(),a=D.useCallback(function(s){typeof s=="function"?a(function(l){return s=s(l),i.current=s,s}):(i.current=s,a(s))},[i]);return i.current=r,[r,o,i]}function RR(e,t){var n=l4e(e);if(wR){var r=wR(e);t&&(r=E4e(r).call(r,function(o){return IU(e,o).enumerable})),n.push.apply(n,r)}return n}function FR(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};if(t%2){var r;$0(r=RR(Object(n),!0)).call(r,function(i){rAe(e,i,n[i])})}else if(SR)cLe(e,SR(n));else{var o;$0(o=RR(Object(n))).call(o,function(i){dLe(e,i,IU(n,i))})}}return e}var URe=function(){return 1/0},HR=17,zRe="bottom",sa="top",_R=1,VRe=34,BR={};function WRe(e,t){return e(),L3e(e,t)}function YR(e){var t=e.mode,n=e.target,r=n.offsetHeight,o=n.scrollHeight,i=n.scrollTop,a=o-i-r<_R,s=i<_R,l=t===sa?s:a,u=t!==sa?s:a;return{atBottom:a,atEnd:l,atStart:u,atTop:s}}function _p(e,t){return e===(t===sa?0:"100%")}var X2=function(t){var n=t.checkInterval,r=t.children,o=t.debounce,i=t.debug,a=t.initialScrollBehavior,s=t.mode,l=t.nonce,u=t.scroller,d=D.useMemo(function(){return bRe("<ScrollToBottom>",{force:i})},[i]);s=s===sa?sa:zRe;var h=D.useRef(0),p=D.useRef(a),m=rk(s===sa?0:"100%"),b=Ja(m,3),v=b[0],y=b[1],S=b[2],x=rk(null),C=Ja(x,3),k=C[0],M=C[1],I=C[2],O=D.useRef(0),R=D.useRef(0),L=D.useRef(0),B=D.useState(!0),_=Ja(B,2),H=_[0],U=_[1],G=D.useState(!0),K=Ja(G,2),z=K[0],ne=K[1],J=D.useState(!0),ee=Ja(J,2),Z=ee[0],q=ee[1],$=D.useState(!1),re=Ja($,2),le=re[0],ie=re[1],fe=rk(!0),ye=Ja(fe,3),ge=ye[0],me=ye[1],Ce=ye[2],je=D.useRef([]),Ie=D.useCallback(function(Ge){var ut=I.current;return je.current.push(Ge),ut&&Ge({scrollTop:ut.scrollTop}),function(){var mt=je.current,It=K3e(mt).call(mt,Ge);~It&&wje(mt).call(mt,It,1)}},[je,I]),Fe=D.useCallback(function(){var Ge=S.current;d(function(){var ut;return Fn(ut=["%cSpineTo%c: %conEnd%c is fired."]).call(ut,Bt(nn("magenta")),Bt(nn("orange")),[{animateTo:Ge}])}),h.current=mc(),_p(Ge,s)||me(!1),y(null)},[S,d,h,s,y,me]),ce=D.useCallback(function(Ge){var ut=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},mt=ut.behavior,It=I.current;if(typeof Ge!="number"&&Ge!=="100%")return console.warn('react-scroll-to-bottom: Arguments passed to scrollTo() must be either number or "100%".');d(function(){var Ot;return[Fn(Ot=["%cscrollTo%c: Will scroll to %c".concat(typeof Ge=="number"?Ge+"px":Ge.replace(/%/g,"%%"),"%c")]).call(Ot,Bt(nn("lime","")),Bt(nn("purple"))),{behavior:mt,nextAnimateTo:Ge,target:It}]}),mt==="auto"?(Fe(),It&&(It.scrollTop=Ge==="100%"?It.scrollHeight-It.offsetHeight:Ge)):(mt!=="smooth"&&console.warn('react-scroll-to-bottom: Please set "behavior" when calling "scrollTo". In future versions, the default behavior will be changed from smooth scrolling to discrete scrolling to align with HTML Standard.'),y(Ge)),_p(Ge,s)&&(d(function(){var Ot;return[Fn(Ot=["%cscrollTo%c: Scrolling to end, will set sticky to %ctrue%c."]).call(Ot,Bt(nn("lime","")),Bt(nn("purple"))),[{mode:s,nextAnimateTo:Ge}]]}),me(!0))},[d,Fe,s,y,me,I]),Ne=D.useCallback(function(){var Ge=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},ut=Ge.behavior;d(function(){var mt;return Fn(mt=["%cscrollToBottom%c: Called"]).call(mt,Bt(nn("yellow","")))}),ut!=="smooth"&&console.warn('react-scroll-to-bottom: Please set "behavior" when calling "scrollToBottom". In future versions, the default behavior will be changed from smooth scrolling to discrete scrolling to align with HTML Standard.'),ce("100%",{behavior:ut||"smooth"})},[d,ce]),Pe=D.useCallback(function(){var Ge=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},ut=Ge.behavior;d(function(){var mt;return Fn(mt=["%cscrollToTop%c: Called"]).call(mt,Bt(nn("yellow","")))}),ut!=="smooth"&&console.warn('react-scroll-to-bottom: Please set "behavior" when calling "scrollToTop". In future versions, the default behavior will be changed from smooth scrolling to discrete scrolling to align with HTML Standard.'),ce(0,{behavior:ut||"smooth"})},[d,ce]),_e=D.useCallback(function(){var Ge=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},ut=Ge.behavior;d(function(){var It;return Fn(It=["%cscrollToEnd%c: Called"]).call(It,Bt(nn("yellow","")))}),ut!=="smooth"&&console.warn('react-scroll-to-bottom: Please set "behavior" when calling "scrollToEnd". In future versions, the default behavior will be changed from smooth scrolling to discrete scrolling to align with HTML Standard.');var mt={behavior:ut||"smooth"};s===sa?Pe(mt):Ne(mt)},[d,s,Ne,Pe]),qe=D.useCallback(function(){var Ge=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},ut=Ge.behavior;d(function(){var It;return Fn(It=["%cscrollToStart%c: Called"]).call(It,Bt(nn("yellow","")))}),ut!=="smooth"&&console.warn('react-scroll-to-bottom: Please set "behavior" when calling "scrollToStart". In future versions, the default behavior will be changed from smooth scrolling to discrete scrolling to align with HTML Standard.');var mt={behavior:ut||"smooth"};s===sa?Ne(mt):Pe(mt)},[d,s,Ne,Pe]),Xe=D.useCallback(function(){var Ge=I.current;if(Ge){if(p.current==="auto"){d(function(){var er;return Fn(er=["%ctarget changed%c: Initial scroll"]).call(er,Bt(nn("blue")))}),Ge.scrollTop=s===sa?0:Ge.scrollHeight-Ge.offsetHeight,p.current=!1;return}var ut=O.current,mt=Ge.offsetHeight,It=Ge.scrollHeight,Ot=Ge.scrollTop,Zn=s===sa?0:Math.max(0,It-mt-Ot),$n=Math.max(0,ut-Ot),io=u({maxValue:Zn,minValue:$n,offsetHeight:mt,scrollHeight:It,scrollTop:Ot}),Tn=Math.max(0,Math.min(Zn,io)),Pn;s===sa||Tn!==Zn?Pn=Ot+Tn:Pn="100%",d(function(){var er,ir,Gt;return[Fn(er=[Fn(ir=Fn(Gt="%cscrollToSticky%c: Will animate from %c".concat(ut,"px%c to %c")).call(Gt,typeof Pn=="number"?Pn+"px":Pn.replace(/%/g,"%%"),"%c (%c")).call(ir,(Pn==="100%"?Zn:Pn)+ut,"px%c)")]).call(er,Bt(nn("orange")),Bt(nn("purple")),Bt(nn("purple")),Bt(nn("purple"))),{animateFrom:ut,maxValue:Zn,minValue:$n,nextAnimateTo:Pn,nextValue:Tn,offsetHeight:mt,rawNextValue:io,scrollHeight:It,scrollTop:Ot}]}),ce(Pn,{behavior:"smooth"})}},[O,d,s,u,ce,I]),Qe=D.useCallback(function(Ge){var ut,mt=Ge.timeStampLow,It=S.current,Ot=I.current,Zn=It!==null;if(!(mt<=h.current||!Ot)){var $n=YR({mode:s,target:Ot}),io=$n.atBottom,Tn=$n.atEnd,Pn=$n.atStart,er=$n.atTop;U(io),ne(Tn),ie(Pn),q(er);var ir=Ot.offsetHeight,Gt=Ot.scrollHeight,gr=R.current,Un=L.current,Et=ir!==gr,Yr=Gt!==Un;if(Et&&(R.current=ir),Yr&&(L.current=Gt),!Et&&!Yr){var Mr=Zn&&_p(It,s)||Tn;Ce.current!==Mr&&(d(function(){var jn,ao,qn,so;return[Fn(jn=["%conScroll%c: %csetSticky%c(%c".concat(Mr,"%c)")]).call(jn,Bt(nn("red")),Bt(nn("red")),Bt(nn("purple"))),Fn(ao=[Fn(qn=Fn(so="(animating = %c".concat(Zn,"%c && isEnd = %c")).call(so,_p(It,s),"%c) || atEnd = %c")).call(qn,Tn,"%c")]).call(ao,Bt(nn("purple")),Bt(nn("purple")),Bt(nn("purple")),[{animating:Zn,animateTo:It,atEnd:Tn,mode:s,offsetHeight:Ot.offsetHeight,scrollHeight:Ot.scrollHeight,sticky:Ce.current,nextSticky:Mr}])]}),me(Mr))}else Ce.current&&(d(function(){var jn;return[Fn(jn=["%conScroll%c: Size changed while sticky, calling %cscrollToSticky()%c"]).call(jn,Bt(nn("red")),Bt(nn("orange")),[{offsetHeightChanged:Et,scrollHeightChanged:Yr}]),{nextOffsetHeight:ir,prevOffsetHeight:gr,nextScrollHeight:Gt,prevScrollHeight:Un}]}),Xe());var wo=Ot.scrollTop;$0(ut=je.current).call(ut,function(jn){return jn({scrollTop:wo})})}},[S,d,h,s,R,L,je,Xe,U,ne,ie,q,me,Ce,I]);D.useEffect(function(){if(k){var Ge=!1,ut=WRe(function(){var mt=I.current,It=S.current!==null;Ce.current?YR({mode:s,target:mt}).atEnd?Ge=!1:Ge?mc()-Ge>VRe&&(It||(O.current=mt.scrollTop,d(function(){var Ot;return Fn(Ot=["%cInterval check%c: Should sticky but not at end, calling %cscrollToSticky()%c to scroll"]).call(Ot,Bt(nn("navy")),Bt(nn("orange")))}),Xe()),Ge=!1):Ge=mc():mt.scrollHeight<=mt.offsetHeight&&!Ce.current&&(d(function(){var Ot;return[Fn(Ot=["%cInterval check%c: Container is emptied, setting sticky back to %ctrue%c"]).call(Ot,Bt(nn("navy")),Bt(nn("purple"))),[{offsetHeight:mt.offsetHeight,scrollHeight:mt.scrollHeight,sticky:Ce.current}]]}),me(!0))},Math.max(HR,n)||HR);return function(){return clearInterval(ut)}}},[S,n,d,s,Xe,me,Ce,k,I]);var it=D.useMemo(function(){var Ge=BR[l]||(BR[l]=KLe({key:"react-scroll-to-bottom--css-"+vRe(),nonce:l}));return function(ut){return Ge.css(ut)+""}},[l]),at=D.useMemo(function(){return{observeScrollPosition:Ie,setTarget:M,styleToClassName:it}},[Ie,M,it]),vt=D.useMemo(function(){return{atBottom:H,atEnd:z,atStart:le,atTop:Z,mode:s}},[H,z,le,Z,s]),Mt=D.useMemo(function(){var Ge=v!==null;return{animating:Ge,animatingToEnd:Ge&&_p(v,s),sticky:ge}},[v,s,ge]),Kt=D.useMemo(function(){return FR(FR({},vt),Mt)},[vt,Mt]),gn=D.useMemo(function(){return{scrollTo:ce,scrollToBottom:Ne,scrollToEnd:_e,scrollToStart:qe,scrollToTop:Pe}},[ce,Ne,_e,qe,Pe]);return D.useEffect(function(){if(k){var Ge=function(){L.current=k.scrollHeight};return k.addEventListener("focus",Ge,{capture:!0,passive:!0}),function(){return k.removeEventListener("focus",Ge)}}},[k]),d(function(){var Ge;return[Fn(Ge=["%cRender%c: Render"]).call(Ge,Bt(nn("cyan",""))),{animateTo:v,animating:v!==null,sticky:ge,target:k}]}),Y.createElement(lT.Provider,{value:at},Y.createElement(C2.Provider,{value:gn},Y.createElement(A2.Provider,{value:Kt},Y.createElement(M2.Provider,{value:vt},Y.createElement(D2.Provider,{value:Mt},r,k&&Y.createElement(BU,{debounce:o,name:"scroll",onEvent:Qe,target:k}),k&&v!==null&&Y.createElement(YU,{name:"scrollTop",onEnd:Fe,target:k,value:v}))))))};X2.defaultProps={checkInterval:100,children:void 0,debounce:17,debug:void 0,initialScrollBehavior:"smooth",mode:void 0,nonce:void 0,scroller:URe};X2.propTypes={checkInterval:Vt.number,children:Vt.any,debounce:Vt.number,debug:Vt.bool,initialScrollBehavior:Vt.oneOf(["auto","smooth"]),mode:Vt.oneOf(["bottom","top"]),nonce:Vt.string,scroller:Vt.func};var GRe={height:"100%",overflowY:"auto",width:"100%"},J2=function(t){var n=t.children,r=t.className,o=D.useContext(lT),i=o.setTarget,a=N2()(GRe);return Y.createElement("div",{className:E2(a,(r||"")+""),ref:i},n)};J2.defaultProps={children:void 0,className:void 0};J2.propTypes={children:Vt.any,className:Vt.string};var ZRe={position:"relative"},Q2=function(t){var n=t.children,r=t.className,o=t.followButtonClassName,i=t.scrollViewClassName,a=N2()(ZRe);return Y.createElement("div",{className:E2(a,(r||"")+"")},Y.createElement(J2,{className:(i||"")+""},n),Y.createElement(O2,{className:(o||"")+""}))};Q2.defaultProps={children:void 0,className:void 0,followButtonClassName:void 0,scrollViewClassName:void 0};Q2.propTypes={children:Vt.any,className:Vt.string,followButtonClassName:Vt.string,scrollViewClassName:Vt.string};var eA=function(t){var n=t.checkInterval,r=t.children,o=t.className,i=t.debounce,a=t.debug,s=t.followButtonClassName,l=t.initialScrollBehavior,u=t.mode,d=t.nonce,h=t.scroller,p=t.scrollViewClassName;return Y.createElement(X2,{checkInterval:n,debounce:i,debug:a,initialScrollBehavior:l,mode:u,nonce:d,scroller:h},Y.createElement(Q2,{className:o,followButtonClassName:s,scrollViewClassName:p},r))};eA.defaultProps={checkInterval:void 0,children:void 0,className:void 0,debounce:void 0,debug:void 0,followButtonClassName:void 0,initialScrollBehavior:"smooth",mode:void 0,nonce:void 0,scroller:void 0,scrollViewClassName:void 0};eA.propTypes={checkInterval:Vt.number,children:Vt.any,className:Vt.string,debounce:Vt.number,debug:Vt.bool,followButtonClassName:Vt.string,initialScrollBehavior:Vt.oneOf(["auto","smooth"]),mode:Vt.oneOf(["bottom","top"]),nonce:Vt.string,scroller:Vt.func,scrollViewClassName:Vt.string};function $Re(){var e=sT(),t=e.scrollToBottom;return t}function qRe(){var e=sT(),t=e.scrollToStart;return t}function KRe(){var e=sT(),t=e.scrollToTop;return t}TSe();const XRe=e=>{const{locationState:{query:t},globalState:{memoListView:n,manifest:r},dailyNotesState:{app:o,settings:i}}=D.useContext(ct),{thinos:a}=e,[s,l]=Y.useState(sg(a,"day")),u=Y.useRef(null),d=$Re(),h=D.useRef([]);D.useRef(0),D.useEffect(()=>{const b=sg(a,"day");ws(b,s)||l(b)},[a]),D.useEffect(()=>{if(ws(h.current,a))return;const b=a.filter(x=>x.pinned),v=a.filter(x=>!x.pinned),y=h.current.filter(x=>x.pinned)[0],S=h.current.filter(x=>!x.pinned)[0];(y&&y.id!==b[0]?.id||S&&S.id!==v[0]?.id)&&d()},[a]),D.useEffect(()=>{u.current&&d()},[t]);const p=D.useCallback(()=>{o.setting.open(),o.setting.openTabById(r.id||"obsidian-memos")},[o]),m=D.useMemo(()=>w.jsx(w.Fragment,{children:Object.keys(s).map((b,v)=>w.jsx(w.Fragment,{children:w.jsx(JRe,{thinos:s[b],dayMark:b,handleOpenSettings:p},b+v)}))}),[s]);return w.jsx("div",{ref:u,className:tn("chat-view",`${i?.chatViewStyle}-style`),children:m})},JRe=({thinos:e,dayMark:t,handleOpenSettings:n})=>{const{dailyNotesState:{settings:r,app:o}}=D.useContext(ct),[i,a]=Y.useState(!0),s=Y.useRef(null),[l,u]=Y.useState(r?.MomentsIcon);D.useEffect(()=>{if(!r?.MomentsIcon||!o)return;const m=o.vault.adapter.getResourcePath(N.normalizePath(r.MomentsIcon));m&&!r?.MomentsIcon.startsWith("http")?u(m):u(r?.MomentsIcon)},[r?.MomentsIcon]);const d=m=>{if(N.Keymap.isModifier(m.nativeEvent,"Mod")){const b=N.moment(t,"YYYY-MM-DD");Ue.setFromAndToQuery(b.startOf("day").valueOf(),b.endOf("day").valueOf());return}a(!i),s.current.scrollIntoView(!0)},h=m=>{pa(m)},p=D.useMemo(()=>e.map((m,b)=>w.jsxs("div",{className:"thino-bubble right",children:[w.jsx(QRe,{icon:l,handleOpenSettings:n}),w.jsx("div",{className:"wrap",children:w.jsx(e5e,{thino:m,handleClickTimeStamp:h},`${m.id}-${N.moment(m.createdAt,"YYYY/MM/DD HH:mm:ss").format("x")}-${b}`)})]},m.id+b)),[e,l]);return w.jsxs(w.Fragment,{children:[i&&p,w.jsx("div",{className:`thino-chat-day-mark day-mark ${i?"":"folded"}`,onClick:d,children:w.jsx("div",{className:"day-mark-bubble",children:(t==="PINNED"?t+" 📌":t)+(i?"":"...")})})]})},QRe=({icon:e,handleOpenSettings:t})=>w.jsx("div",{ref:n=>{if(e){n?.empty();return}e||n&&N.setIcon(n,"Memos")},className:"icon-img",style:{backgroundImage:`url("${e}")`}}),e5e=({thino:e,handleClickTimeStamp:t})=>{const n=D.useCallback(async()=>{if(e.thinoType==="JOURNAL")return;const i=await de.updateMemo(e.id,e.content,e.thinoType==="TASK-TODO"?"TASK-DONE":"TASK-TODO");i&&de.editMemo(i)},[e]),r=D.useMemo(()=>w.jsxs("div",{className:"content",children:[w.jsx("div",{className:"time-stamp","data-date":N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss").format("YYYY-MM-DD"),"data-time":N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss").format("HH:mm:ss"),onClick:()=>{t(e)},children:N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss").format("HH:mm:ss")}),w.jsx(vo,{memo:e})]}),[e.content]),o=D.useMemo(()=>w.jsxs("div",{className:"content task",children:[w.jsx("div",{className:"task-inputer",children:w.jsx("input",{className:tn("thino-type-status","task-list-item-checkbox"),type:"checkbox",checked:e.thinoType!=="TASK-TODO","data-task":e.thinoType==="TASK-TODO"?"":e.thinoType==="TASK-DONE"?"x":e.thinoType?.slice(5),onClick:n})}),w.jsx("div",{className:"time-stamp","data-date":N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss").format("YYYY-MM-DD"),"data-time":N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss").format("HH:mm:ss"),onClick:()=>{t(e)},children:N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss").format("HH:mm:ss")}),w.jsx(vo,{memo:e})]}),[e.content,e.thinoType]);return e.thinoType==="JOURNAL"?r:o};var t5e=Ta,n5e=function(){return t5e.Date.now()},r5e=n5e,o5e=Vi,ok=r5e,UR=H7,i5e="Expected a function",a5e=Math.max,s5e=Math.min;function l5e(e,t,n){var r,o,i,a,s,l,u=0,d=!1,h=!1,p=!0;if(typeof e!="function")throw new TypeError(i5e);t=UR(t)||0,o5e(n)&&(d=!!n.leading,h="maxWait"in n,i=h?a5e(UR(n.maxWait)||0,t):i,p="trailing"in n?!!n.trailing:p);function m(I){var O=r,R=o;return r=o=void 0,u=I,a=e.apply(R,O),a}function b(I){return u=I,s=setTimeout(S,t),d?m(I):a}function v(I){var O=I-l,R=I-u,L=t-O;return h?s5e(L,i-R):L}function y(I){var O=I-l,R=I-u;return l===void 0||O>=t||O<0||h&&R>=i}function S(){var I=ok();if(y(I))return x(I);s=setTimeout(S,v(I))}function x(I){return s=void 0,p&&r?m(I):(r=o=void 0,a)}function C(){s!==void 0&&clearTimeout(s),u=0,r=l=o=s=void 0}function k(){return s===void 0?a:x(ok())}function M(){var I=ok(),O=y(I);if(r=arguments,o=this,l=I,O){if(s===void 0)return b(l);if(h)return clearTimeout(s),s=setTimeout(S,t),m(l)}return s===void 0&&(s=setTimeout(S,t)),a}return M.cancel=C,M.flush=k,M}var c5e=l5e,u5e=c5e,d5e=Vi,f5e="Expected a function";function h5e(e,t,n){var r=!0,o=!0;if(typeof e!="function")throw new TypeError(f5e);return d5e(n)&&(r="leading"in n?!!n.leading:r,o="trailing"in n?!!n.trailing:o),u5e(e,t,{leading:r,maxWait:t,trailing:o})}var p5e=h5e;const tA=tt(p5e),m5e=3e3;function g5e({statusRef:e,isComplete:t,fetchMore:n,cachedMemos:r}){const o=D.useRef(!1),i=D.useCallback(tA(()=>{if(!(o.current||t)){o.current=!0;try{n()}finally{setTimeout(()=>{o.current=!1},500)}}},m5e,{trailing:!1,leading:!0}),[n,t]);D.useEffect(()=>{const a=e.current;if(!a)return;const s=new IntersectionObserver(([l])=>{l.isIntersecting&&!t&&!o.current&&i()});return s.observe(a),()=>{s.unobserve(a),i.cancel()}},[t,e,i]),D.useEffect(()=>{if(r.length<40&&!t&&!o.current){const a=setTimeout(()=>{i()},100);return()=>clearTimeout(a)}},[r.length,t,i])}const ii=(e,t)=>{const{o:n,i:r,u:o}=e;let i=n,a;const s=(d,h)=>{const p=i,m=d,b=h||(r?!r(p,m):p!==m);return(b||o)&&(i=m,a=p),[i,b,a]};return[t?d=>s(t(i,a),d):s,d=>[i,!!d,a]]},v5e=typeof window<"u"&&typeof HTMLElement<"u"&&!!window.document,Bo=v5e?window:{},K0=Math.max,y5e=Math.min,qE=Math.round,X0=Math.abs,zR=Math.sign,vT=Bo.cancelAnimationFrame,Rf=Bo.requestAnimationFrame,J0=Bo.setTimeout,KE=Bo.clearTimeout,yT=e=>typeof Bo[e]<"u"?Bo[e]:void 0,b5e=yT("MutationObserver"),VR=yT("IntersectionObserver"),sf=yT("ResizeObserver"),om=yT("ScrollTimeline"),nA=e=>e===void 0,bT=e=>e===null,hs=e=>typeof e=="number",jv=e=>typeof e=="string",wT=e=>typeof e=="boolean",mi=e=>typeof e=="function",Ts=e=>Array.isArray(e),Q0=e=>typeof e=="object"&&!Ts(e)&&!bT(e),rA=e=>{const t=!!e&&e.length,n=hs(t)&&t>-1&&t%1==0;return Ts(e)||!mi(e)&&n?t>0&&Q0(e)?t-1 in e:!0:!1},ew=e=>!!e&&e.constructor===Object,tw=e=>e instanceof HTMLElement,ST=e=>e instanceof Element,WR=()=>performance.now(),ik=(e,t,n,r,o)=>{let i=0;const a=WR(),s=K0(0,n),l=u=>{const d=WR(),p=d-a>=s,m=u?1:1-(K0(0,a+s-d)/s||0),b=(t-e)*(mi(o)?o(m,m*s,0,1,s):m)+e,v=p||m===1;r&&r(b,m,v),i=v?0:Rf(()=>l())};return l(),u=>{vT(i),u&&l(u)}};function sn(e,t){if(rA(e))for(let n=0;n<e.length&&t(e[n],n,e)!==!1;n++);else e&&sn(Object.keys(e),n=>t(e[n],n,e));return e}const UU=(e,t)=>e.indexOf(t)>=0,ig=(e,t)=>e.concat(t),_n=(e,t,n)=>(!jv(t)&&rA(t)?Array.prototype.push.apply(e,t):e.push(t),e),Mc=e=>Array.from(e||[]),oA=e=>Ts(e)?e:!jv(e)&&rA(e)?Mc(e):[e],XE=e=>!!e&&!e.length,JE=e=>Mc(new Set(e)),fi=(e,t,n)=>{sn(e,o=>o?o.apply(void 0,t||[]):!0),n||(e.length=0)},iA="paddingTop",bm="paddingRight",wm="paddingLeft",Sm="paddingBottom",Tm="marginLeft",xm="marginRight",lf="marginBottom",aA="overflowX",sA="overflowY",_h="width",Lv="height",lc="visible",Su="hidden",Vu="scroll",w5e=e=>{const t=String(e||"");return t?t[0].toUpperCase()+t.slice(1):""},TT=(e,t,n,r)=>{if(e&&t){let o=!0;return sn(n,i=>{const a=e[i],s=t[i];a!==s&&(o=!1)}),o}return!1},lA=(e,t)=>TT(e,t,["w","h"]),o0=(e,t)=>TT(e,t,["x","y"]),S5e=(e,t)=>TT(e,t,["t","r","b","l"]),ps=()=>{},wt=(e,...t)=>e.bind(0,...t),Tu=e=>{let t;const n=e?J0:Rf,r=e?KE:vT;return[o=>{r(t),t=n(()=>o(),mi(e)?e():e)},()=>r(t)]},nw=(e,t)=>{const{_:n,p:r,v:o,S:i}=t||{};let a,s,l,u,d=ps;const h=function(y){d(),KE(a),u=a=s=void 0,d=ps,e.apply(this,y)},p=v=>i&&s?i(s,v):v,m=()=>{d!==ps&&h(p(l)||l)},b=function(){const y=Mc(arguments),S=mi(n)?n():n;if(hs(S)&&S>=0){const C=mi(r)?r():r,k=hs(C)&&C>=0,M=S>0?J0:Rf,I=S>0?KE:vT,R=p(y)||y,L=h.bind(0,R);let B;d(),o&&!u?(L(),u=!0,B=M(()=>u=void 0,S)):(B=M(L,S),k&&!a&&(a=J0(m,C))),d=()=>I(B),s=l=R}else h(y)};return b.m=m,b},zU=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),Yi=e=>e?Object.keys(e):[],Ut=(e,t,n,r,o,i,a)=>{const s=[t,n,r,o,i,a];return(typeof e!="object"||bT(e))&&!mi(e)&&(e={}),sn(s,l=>{sn(l,(u,d)=>{const h=l[d];if(e===h)return!0;const p=Ts(h);if(h&&ew(h)){const m=e[d];let b=m;p&&!Ts(m)?b=[]:!p&&!ew(m)&&(b={}),e[d]=Ut(b,h)}else e[d]=p?h.slice():h})}),e},VU=(e,t)=>sn(Ut({},e),(n,r,o)=>{n===void 0?delete o[r]:n&&ew(n)&&(o[r]=VU(n))}),cA=e=>!Yi(e).length,WU=(e,t,n)=>K0(e,y5e(t,n)),Pu=e=>JE((Ts(e)?e:(e||"").split(" ")).filter(t=>t)),uA=(e,t)=>e&&e.getAttribute(t),GR=(e,t)=>e&&e.hasAttribute(t),Ks=(e,t,n)=>{sn(Pu(t),r=>{e&&e.setAttribute(r,String(n||""))})},$a=(e,t)=>{sn(Pu(t),n=>e&&e.removeAttribute(n))},xT=(e,t)=>{const n=Pu(uA(e,t)),r=wt(Ks,e,t),o=(i,a)=>{const s=new Set(n);return sn(Pu(i),l=>{s[a](l)}),Mc(s).join(" ")};return{O:i=>r(o(i,"delete")),$:i=>r(o(i,"add")),C:i=>{const a=Pu(i);return a.reduce((s,l)=>s&&n.includes(l),a.length>0)}}},dA=(e,t,n)=>(xT(e,t).O(n),wt(fA,e,t,n)),fA=(e,t,n)=>(xT(e,t).$(n),wt(dA,e,t,n)),rw=(e,t,n,r)=>(r?fA:dA)(e,t,n),hA=(e,t,n)=>xT(e,t).C(n),GU=e=>xT(e,"class"),ZU=(e,t)=>{GU(e).O(t)},IT=(e,t)=>(GU(e).$(t),wt(ZU,e,t)),$U=(e,t)=>{const n=t?ST(t)&&t:document;return n?Mc(n.querySelectorAll(e)):[]},T5e=(e,t)=>{const n=t?ST(t)&&t:document;return n&&n.querySelector(e)},QE=(e,t)=>ST(e)&&e.matches(t),qU=e=>QE(e,"body"),eC=e=>e?Mc(e.childNodes):[],ag=e=>e&&e.parentElement,cf=(e,t)=>ST(e)&&e.closest(t),tC=e=>document.activeElement,x5e=(e,t,n)=>{const r=cf(e,t),o=e&&T5e(n,r),i=cf(o,t)===r;return r&&o?r===e||o===e||i&&cf(cf(e,n),t)!==r:!1},Ff=e=>{sn(oA(e),t=>{const n=ag(t);t&&n&&n.removeChild(t)})},mo=(e,t)=>wt(Ff,e&&t&&sn(oA(t),n=>{n&&e.appendChild(n)}));let KU;const I5e=()=>KU,k5e=e=>{KU=e},gf=e=>{const t=document.createElement("div");return Ks(t,"class",e),t},pA=e=>{const t=gf(),n=I5e(),r=e.trim();return t.innerHTML=n?n.createHTML(r):r,sn(eC(t),o=>Ff(o))},ZR=(e,t)=>e.getPropertyValue(t)||e[t]||"",XU=e=>{const t=e||0;return isFinite(t)?t:0},gb=e=>XU(parseFloat(e||"")),nC=e=>Math.round(e*1e4)/1e4,JU=e=>`${nC(XU(e))}px`;function ll(e,t){e&&t&&sn(t,(n,r)=>{try{const o=e.style,i=bT(n)||wT(n)?"":hs(n)?JU(n):n;r.indexOf("--")===0?o.setProperty(r,i):o[r]=i}catch{}})}function wa(e,t,n){const r=jv(t);let o=r?"":{};if(e){const i=Bo.getComputedStyle(e,n)||e.style;o=r?ZR(i,t):Mc(t).reduce((a,s)=>(a[s]=ZR(i,s),a),o)}return o}const $R=(e,t,n)=>{const r=t?`${t}-`:"",o=n?`-${n}`:"",i=`${r}top${o}`,a=`${r}right${o}`,s=`${r}bottom${o}`,l=`${r}left${o}`,u=wa(e,[i,a,s,l]);return{t:gb(u[i]),r:gb(u[a]),b:gb(u[s]),l:gb(u[l])}},ak=(e,t)=>`translate${Q0(e)?`(${e.x},${e.y})`:`${t?"X":"Y"}(${e})`}`,E5e=e=>!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length),C5e={w:0,h:0},kT=(e,t)=>t?{w:t[`${e}Width`],h:t[`${e}Height`]}:C5e,M5e=e=>kT("inner",e||Bo),gc=wt(kT,"offset"),QU=wt(kT,"client"),ow=wt(kT,"scroll"),mA=e=>{const t=parseFloat(wa(e,_h))||0,n=parseFloat(wa(e,Lv))||0;return{w:t-qE(t),h:n-qE(n)}},sk=e=>e.getBoundingClientRect(),D5e=e=>!!e&&E5e(e),rC=e=>!!(e&&(e[Lv]||e[_h])),ez=(e,t)=>{const n=rC(e);return!rC(t)&&n},qR=(e,t,n,r)=>{sn(Pu(t),o=>{e&&e.removeEventListener(o,n,r)})},bn=(e,t,n,r)=>{var o;const i=(o=r&&r.H)!=null?o:!0,a=r&&r.I||!1,s=r&&r.A||!1,l={passive:i,capture:a};return wt(fi,Pu(t).map(u=>{const d=s?h=>{qR(e,u,d,a),n&&n(h)}:n;return e&&e.addEventListener(u,d,l),wt(qR,e,u,d,a)}))},gA=e=>e.stopPropagation(),oC=e=>e.preventDefault(),tz=e=>gA(e)||oC(e),Oi=(e,t)=>{const{x:n,y:r}=hs(t)?{x:t,y:t}:t||{};hs(n)&&(e.scrollLeft=n),hs(r)&&(e.scrollTop=r)},ci=e=>({x:e.scrollLeft,y:e.scrollTop}),nz=()=>({D:{x:0,y:0},M:{x:0,y:0}}),A5e=(e,t)=>{const{D:n,M:r}=e,{w:o,h:i}=t,a=(h,p,m)=>{let b=zR(h)*m,v=zR(p)*m;if(b===v){const y=X0(h),S=X0(p);v=y>S?0:v,b=y<S?0:b}return b=b===v?0:b,[b+0,v+0]},[s,l]=a(n.x,r.x,o),[u,d]=a(n.y,r.y,i);return{D:{x:s,y:u},M:{x:l,y:d}}},lk=({D:e,M:t})=>{const n=(r,o)=>r===0&&r<=o;return{x:n(e.x,t.x),y:n(e.y,t.y)}},KR=({D:e,M:t},n)=>{const r=(o,i,a)=>WU(0,1,(o-a)/(o-i)||0);return{x:r(e.x,t.x,n.x),y:r(e.y,t.y,n.y)}},iC=e=>{e&&e.focus&&e.focus({preventScroll:!0})},XR=(e,t)=>{sn(oA(t),e)},aC=e=>{const t=new Map,n=(i,a)=>{if(i){const s=t.get(i);XR(l=>{s&&s[l?"delete":"clear"](l)},a)}else t.forEach(s=>{s.clear()}),t.clear()},r=(i,a)=>{if(jv(i)){const u=t.get(i)||new Set;return t.set(i,u),XR(d=>{mi(d)&&u.add(d)},a),wt(n,i,a)}wT(a)&&a&&n();const s=Yi(i),l=[];return sn(s,u=>{const d=i[u];d&&_n(l,r(u,d))}),wt(fi,l)},o=(i,a)=>{sn(Mc(t.get(i)),s=>{a&&!XE(a)?s.apply(0,a):s()})};return r(e||{}),[r,n,o]},rz={},oz={},N5e=e=>{sn(e,t=>sn(t,(n,r)=>{rz[r]=t[r]}))},iz=(e,t,n)=>Yi(e).map(r=>{const{static:o,instance:i}=e[r],[a,s,l]=n||[],u=n?i:o;if(u){const d=n?u(a,s,t):u(t);return(l||oz)[r]=d}}),Rv=e=>oz[e],O5e="__osOptionsValidationPlugin",Bh="data-overlayscrollbars",i0="os-environment",vb=`${i0}-scrollbar-hidden`,ck=`${Bh}-initialize`,a0="noClipping",JR=`${Bh}-body`,vc=Bh,P5e="host",Qa=`${Bh}-viewport`,j5e=aA,L5e=sA,az="arrange",sz="measuring",R5e="scrolling",lz="scrollbarHidden",F5e="noContent",sC=`${Bh}-padding`,QR=`${Bh}-content`,vA="os-size-observer",H5e=`${vA}-appear`,yA=`${vA}-listener`,_5e=`${yA}-scroll`,s0=`${yA}-item`,e5=`${s0}-final`,B5e="os-trinsic-observer",Y5e="os-theme-none",bi="os-scrollbar",U5e=`${bi}-rtl`,z5e=`${bi}-horizontal`,V5e=`${bi}-vertical`,cz=`${bi}-track`,bA=`${bi}-handle`,W5e=`${bi}-visible`,G5e=`${bi}-cornerless`,t5=`${bi}-interaction`,n5=`${bi}-unusable`,lC=`${bi}-auto-hide`,r5=`${lC}-hidden`,o5=`${bi}-wheel`,Z5e=`${cz}-interactive`,$5e=`${bA}-interactive`,uz="__osSizeObserverPlugin",q5e={[uz]:{static:()=>(e,t,n)=>{const o="scroll",i=pA(`<div class="${s0}" dir="ltr"><div class="${s0}"><div class="${e5}"></div></div><div class="${s0}"><div class="${e5}" style="width: 200%; height: 200%"></div></div></div>`),a=i[0],s=a.lastChild,l=a.firstChild,u=l?.firstChild;let d=gc(a),h=d,p=!1,m;const b=()=>{Oi(l,3333333),Oi(s,3333333)},v=x=>{m=0,p&&(d=h,t(x===!0))},y=x=>{h=gc(a),p=!x||!lA(h,d),x?(gA(x),p&&!m&&(vT(m),m=Rf(v))):v(x===!1),b()},S=[mo(e,i),bn(l,o,y),bn(s,o,y)];return IT(e,_5e),ll(u,{[_h]:3333333,[Lv]:3333333}),Rf(b),[n?wt(y,!1):b,S]}}},dz=(e,t)=>{const{T:n}=t,[r,o]=e("showNativeOverlaidScrollbars");return[r&&n.x&&n.y,o]},Hf=e=>e.indexOf(lc)===0,K5e=(e,t)=>{const n=(o,i,a,s)=>{const l=o===lc?Su:o.replace(`${lc}-`,""),u=Hf(o),d=Hf(a);return!i&&!s?Su:u&&d?lc:u?i&&s?l:i?lc:Su:i?l:d&&s?lc:Su},r={x:n(t.x,e.x,t.y,e.y),y:n(t.y,e.y,t.x,e.x)};return{k:r,R:{x:r.x===Vu,y:r.y===Vu}}},wA="__osScrollbarsHidingPlugin",X5e={[wA]:{static:()=>({V:(e,t,n,r,o)=>{const{L:i,U:a}=e,{P:s,T:l,N:u}=r,d=!i&&!s&&(l.x||l.y),[h]=dz(o,r),p=()=>{const S=I=>{const O=wa(a,I);return[O,O===Vu]},[x,C]=S(aA),[k,M]=S(sA);return{k:{x,y:k},R:{x:C,y:M}}},m=S=>{const{R:x}=S,C=s||h?0:42,k=(L,B,_)=>[B&&!s?L?C:_:0,L&&!!C],[M,I]=k(l.x,x.x,u.x),[O,R]=k(l.y,x.y,u.y);return{q:{x:M,y:O},B:{x:I,y:R}}},b=(S,{F:x},C)=>{if(!i){const k=Ut({},{[xm]:0,[lf]:0,[Tm]:0}),{q:M,B:I}=m(S),{x:O,y:R}=I,{x:L,y:B}=M,{j:_}=t,H=x?Tm:xm,U=x?wm:bm,G=_[H],K=_[lf],z=_[U],ne=_[Sm];return k[_h]=`calc(100% + ${B+G*-1}px)`,k[H]=-B+G,k[lf]=-L+K,C&&(k[U]=z+(R?B:0),k[Sm]=ne+(O?L:0)),k}};return{X:m,Y:(S,x,C)=>{if(d){const{j:k}=t,{q:M,B:I}=m(S),{x:O,y:R}=I,{x:L,y:B}=M,{F:_}=n,U=k[_?bm:wm],G=k.paddingTop,K=x.w+C.w,z=x.h+C.h,ne={w:B&&R?`${B+K-U}px`:"",h:L&&O?`${L+z-G}px`:""};ll(a,{"--os-vaw":ne.w,"--os-vah":ne.h})}return d},W:S=>{if(d){const x=S||p(),{j:C}=t,{B:k}=m(x),{x:M,y:I}=k,O={},R=_=>sn(_,H=>{O[H]=C[H]});M&&R([lf,iA,Sm]),I&&R([Tm,xm,wm,bm]);const L=wa(a,Yi(O)),B=dA(a,Qa,az);return ll(a,O),[()=>{ll(a,Ut({},L,b(x,n,d))),B()},x]}return[ps]},J:b}}})}},fz="__osClickScrollPlugin",J5e={[fz]:{static:()=>(e,t,n,r)=>{let o=!1,i=ps;const a=133,s=222,[l,u]=Tu(a),d=Math.sign(t),h=n*d,p=h/2,m=S=>1-(1-S)*(1-S),b=(S,x)=>ik(S,x,s,e,m),v=(S,x)=>ik(S,t-h,a*x,(C,k,M)=>{e(C),M&&(i=b(C,t))}),y=ik(0,h,s,(S,x,C)=>{if(e(S),C&&(r(o),!o)){const k=t-S;Math.sign(k-p)===d&&l(()=>{const I=k-h;i=Math.sign(I)===d?v(S,Math.abs(I)/n):b(S,t)})}},m);return S=>{o=!0,S&&y(),u(),i()}}}},i5=e=>JSON.stringify(e,(t,n)=>{if(mi(n))throw 0;return n}),a5=(e,t)=>e?`${t}`.split(".").reduce((n,r)=>n&&zU(n,r)?n[r]:void 0,e):void 0,Q5e={paddingAbsolute:!1,showNativeOverlaidScrollbars:!1,update:{elementEvents:[["img","load"]],debounce:[0,33],attributes:null,ignoreMutation:null},overflow:{x:"scroll",y:"scroll"},scrollbars:{theme:"os-theme-dark",visibility:"auto",autoHide:"never",autoHideDelay:1300,autoHideSuspend:!1,dragScroll:!0,clickScroll:!1,pointers:["mouse","touch","pen"]}},hz=(e,t)=>{const n={},r=ig(Yi(t),Yi(e));return sn(r,o=>{const i=e[o],a=t[o];if(Q0(i)&&Q0(a))Ut(n[o]={},hz(i,a)),cA(n[o])&&delete n[o];else if(zU(t,o)&&a!==i){let s=!0;if(Ts(i)||Ts(a))try{i5(i)===i5(a)&&(s=!1)}catch{}s&&(n[o]=a)}}),n},s5=(e,t,n)=>r=>[a5(e,r),n||a5(t,r)!==void 0];let pz;const e9e=()=>pz,t9e=e=>{pz=e};let uk;const n9e=()=>{const e=(k,M,I)=>{mo(document.body,k),mo(document.body,k);const O=QU(k),R=gc(k),L=mA(M);return I&&Ff(k),{x:R.h-O.h+L.h,y:R.w-O.w+L.w}},t=k=>{let M=!1;const I=IT(k,vb);try{M=wa(k,"scrollbar-width")==="none"||wa(k,"display","::-webkit-scrollbar")==="none"}catch{}return I(),M},n=`.${i0}{scroll-behavior:auto!important;position:fixed;opacity:0;visibility:hidden;overflow:scroll;height:200px;width:200px;z-index:-1}.${i0} div{width:200%;height:200%;margin:10px 0}.${vb}{scrollbar-width:none!important}.${vb}::-webkit-scrollbar,.${vb}::-webkit-scrollbar-corner{appearance:none!important;display:none!important;width:0!important;height:0!important}`,o=pA(`<div class="${i0}"><div></div><style>${n}</style></div>`)[0],i=o.firstChild,a=o.lastChild,s=e9e();s&&(a.nonce=s);const[l,,u]=aC(),[d,h]=ii({o:e(o,i),i:o0},wt(e,o,i,!0)),[p]=h(),m=t(o),b={x:p.x===0,y:p.y===0},v={elements:{host:null,padding:!m,viewport:k=>m&&qU(k)&&k,content:!1},scrollbars:{slot:!0},cancel:{nativeScrollbarsOverlaid:!1,body:null}},y=Ut({},Q5e),S=wt(Ut,{},y),x=wt(Ut,{},v),C={N:p,T:b,P:m,G:!!om,K:wt(l,"r"),Z:x,tt:k=>Ut(v,k)&&x(),nt:S,ot:k=>Ut(y,k)&&S(),st:Ut({},v),et:Ut({},y)};if($a(o,"style"),Ff(o),bn(Bo,"resize",()=>{u("r",[])}),mi(Bo.matchMedia)&&!m&&(!b.x||!b.y)){const k=M=>{const I=Bo.matchMedia(`(resolution: ${Bo.devicePixelRatio}dppx)`);bn(I,"change",()=>{M(),k(M)},{A:!0})};k(()=>{const[M,I]=d();Ut(C.N,M),u("r",[I])})}return C},Cs=()=>(uk||(uk=n9e()),uk),r9e=(e,t,n)=>{let r=!1;const o=n?new WeakMap:!1,i=()=>{r=!0},a=s=>{if(o&&n){const l=n.map(u=>{const[d,h]=u||[];return[h&&d?(s||$U)(d,e):[],h]});sn(l,u=>sn(u[0],d=>{const h=u[1],p=o.get(d)||[];if(e.contains(d)&&h){const b=bn(d,h,v=>{r?(b(),o.delete(d)):t(v)});o.set(d,_n(p,b))}else fi(p),o.delete(d)}))}};return a(),[i,a]},l5=(e,t,n,r)=>{let o=!1;const{ct:i,rt:a,lt:s,it:l,ut:u,ft:d}=r||{},h=nw(()=>o&&n(!0),{_:33,p:99}),[p,m]=r9e(e,h,s),b=i||[],v=a||[],y=ig(b,v),S=(C,k)=>{if(!XE(k)){const M=u||ps,I=d||ps,O=[],R=[];let L=!1,B=!1;if(sn(k,_=>{const{attributeName:H,target:U,type:G,oldValue:K,addedNodes:z,removedNodes:ne}=_,J=G==="attributes",ee=G==="childList",Z=e===U,q=J&&H,$=q&&uA(U,H||""),re=jv($)?$:null,le=q&&K!==re,ie=UU(v,H)&≤if(t&&(ee||!Z)){const fe=J&&le,ye=fe&&l&&QE(U,l),me=(ye?!M(U,H,K,re):!J||fe)&&!I(_,!!ye,e,r);sn(z,Ce=>_n(O,Ce)),sn(ne,Ce=>_n(O,Ce)),B=B||me}!t&&Z&&le&&!M(U,H,K,re)&&(_n(R,H),L=L||ie)}),m(_=>JE(O).reduce((H,U)=>(_n(H,$U(_,U)),QE(U,_)?_n(H,U):H),[])),t)return!C&&B&&n(!1),[!1];if(!XE(R)||L){const _=[JE(R),L];return C||n.apply(0,_),_}}},x=new b5e(wt(S,!1));return[()=>(x.observe(e,{attributes:!0,attributeOldValue:!0,attributeFilter:y,subtree:t,childList:t,characterData:t}),o=!0,()=>{o&&(p(),x.disconnect(),o=!1)}),()=>{if(o)return h.m(),S(!0,x.takeRecords())}]};let cu=null;const mz=(e,t,n)=>{const{_t:r}=n||{},o=Rv(uz),[i]=ii({o:!1,u:!0});return()=>{const a=[],l=pA(`<div class="${vA}"><div class="${yA}"></div></div>`)[0],u=l.firstChild,d=h=>{const p=h instanceof ResizeObserverEntry;let m=!1,b=!1;if(p){const[v,,y]=i(h.contentRect),S=rC(v);b=ez(v,y),m=!b&&!S}else b=h===!0;m||t({dt:!0,_t:b})};if(sf){if(!wT(cu)){const b=new sf(ps);b.observe(e,{get box(){cu=!0}}),cu=cu||!1,b.disconnect()}const h=nw(d,{_:0,p:0}),p=b=>h(b.pop()),m=new sf(p);if(m.observe(cu?e:u),_n(a,[()=>m.disconnect(),!cu&&mo(e,l)]),cu){const b=new sf(p);b.observe(e,{box:"border-box"}),_n(a,()=>b.disconnect())}}else if(o){const[h,p]=o(u,d,r);_n(a,ig([IT(l,H5e),bn(l,"animationstart",h),mo(e,l)],p))}else return ps;return wt(fi,a)}},o9e=(e,t)=>{let n;const r=l=>l.h===0||l.isIntersecting||l.intersectionRatio>0,o=gf(B5e),[i]=ii({o:!1}),a=(l,u)=>{if(l){const d=i(r(l)),[,h]=d;return h&&!u&&t(d)&&[d]}},s=(l,u)=>a(u.pop(),l);return[()=>{const l=[];if(VR)n=new VR(wt(s,!1),{root:e}),n.observe(o),_n(l,()=>{n.disconnect()});else{const u=()=>{const d=gc(o);a(d)};_n(l,mz(o,u)()),u()}return wt(fi,_n(l,mo(e,o)))},()=>n&&s(!0,n.takeRecords())]},i9e=(e,t,n,r)=>{let o,i,a,s,l,u;const d=`[${vc}]`,h=`[${Qa}]`,p=["id","class","style","open","wrap","cols","rows"],{vt:m,ht:b,U:v,gt:y,bt:S,L:x,wt:C,yt:k,St:M,Ot:I}=e,O=ie=>wa(ie,"direction")==="rtl",R={$t:!1,F:O(m)},L=Cs(),B=Rv(wA),[_]=ii({i:lA,o:{w:0,h:0}},()=>{const ie=B&&B.V(e,t,R,L,n).W,ye=!(C&&x)&&hA(b,vc,a0),ge=!x&&k(az),me=ge&&ci(y),Ce=me&&I(),je=M(sz,ye),Ie=ge&&ie&&ie()[0],Fe=ow(v),ce=mA(v);return Ie&&Ie(),Oi(y,me),Ce&&Ce(),ye&&je(),{w:Fe.w+ce.w,h:Fe.h+ce.h}}),H=nw(r,{_:()=>o,p:()=>i,S(ie,fe){const[ye]=ie,[ge]=fe;return[ig(Yi(ye),Yi(ge)).reduce((me,Ce)=>(me[Ce]=ye[Ce]||ge[Ce],me),{})]}}),U=ie=>{const fe=O(m);Ut(ie,{Ct:u!==fe}),Ut(R,{F:fe}),u=fe},G=(ie,fe)=>{const[ye,ge]=ie,me={xt:ge};return Ut(R,{$t:ye}),fe||r(me),me},K=({dt:ie,_t:fe})=>{const ge=!(ie&&!fe)&&L.P?H:r,me={dt:ie||fe,_t:fe};U(me),ge(me)},z=(ie,fe)=>{const[,ye]=_(),ge={Ht:ye};return U(ge),ye&&!fe&&(ie?r:H)(ge),ge},ne=(ie,fe,ye)=>{const ge={Et:fe};return U(ge),fe&&!ye&&H(ge),ge},[J,ee]=S?o9e(b,G):[],Z=!x&&mz(b,K,{_t:!0}),[q,$]=l5(b,!1,ne,{rt:p,ct:p}),re=x&&sf&&new sf(ie=>{const fe=ie[ie.length-1].contentRect;K({dt:!0,_t:ez(fe,l)}),l=fe}),le=nw(()=>{const[,ie]=_();r({Ht:ie})},{_:222,v:!0});return[()=>{re&&re.observe(b);const ie=Z&&Z(),fe=J&&J(),ye=q(),ge=L.K(me=>{me?H({zt:me}):le()});return()=>{re&&re.disconnect(),ie&&ie(),fe&&fe(),s&&s(),ye(),ge()}},({It:ie,At:fe,Dt:ye})=>{const ge={},[me]=ie("update.ignoreMutation"),[Ce,je]=ie("update.attributes"),[Ie,Fe]=ie("update.elementEvents"),[ce,Ne]=ie("update.debounce"),Pe=Fe||je,_e=fe||ye,qe=Xe=>mi(me)&&me(Xe);if(Pe){a&&a(),s&&s();const[Xe,Qe]=l5(S||v,!0,z,{ct:ig(p,Ce||[]),lt:Ie,it:d,ft:(it,at)=>{const{target:vt,attributeName:Mt}=it;return(!at&&Mt&&!x?x5e(vt,d,h):!1)||!!cf(vt,`.${bi}`)||!!qe(it)}});s=Xe(),a=Qe}if(Ne)if(H.m(),Ts(ce)){const Xe=ce[0],Qe=ce[1];o=hs(Xe)&&Xe,i=hs(Qe)&&Qe}else hs(ce)?(o=ce,i=!1):(o=!1,i=!1);if(_e){const Xe=$(),Qe=ee&&ee(),it=a&&a();Xe&&Ut(ge,ne(Xe[0],Xe[1],_e)),Qe&&Ut(ge,G(Qe[0],_e)),it&&Ut(ge,z(it[0],_e))}return U(ge),ge},R]},gz=(e,t)=>mi(t)?t.apply(0,e):t,a9e=(e,t,n,r)=>{const o=nA(r)?n:r;return gz(e,o)||t.apply(0,e)},vz=(e,t,n,r)=>{const o=nA(r)?n:r,i=gz(e,o);return!!i&&(tw(i)?i:t.apply(0,e))},s9e=(e,t)=>{const{nativeScrollbarsOverlaid:n,body:r}=t||{},{T:o,P:i,Z:a}=Cs(),{nativeScrollbarsOverlaid:s,body:l}=a().cancel,u=n??s,d=nA(r)?l:r,h=(o.x||o.y)&&u,p=e&&(bT(d)?!i:d);return!!h||!!p},l9e=(e,t,n,r)=>{const o="--os-viewport-percent",i="--os-scroll-percent",a="--os-scroll-direction",{Z:s}=Cs(),{scrollbars:l}=s(),{slot:u}=l,{vt:d,ht:h,U:p,Mt:m,gt:b,wt:v,L:y}=t,{scrollbars:S}=m?{}:e,{slot:x}=S||{},C=[],k=[],M=[],I=vz([d,h,p],()=>y&&v?d:h,u,x),O=q=>{if(om){let $=null,re=[];const le=new om({source:b,axis:q}),ie=()=>{$&&$.cancel(),$=null};return{Rt:ye=>{const{Tt:ge}=n,me=lk(ge)[q],Ce=q==="x",je=[ak(0,Ce),ak(`calc(100cq${Ce?"w":"h"} + -100%)`,Ce)],Ie=me?je:je.reverse();return re[0]===Ie[0]&&re[1]===Ie[1]||(ie(),re=Ie,$=ye.kt.animate({clear:["left"],transform:Ie},{timeline:le})),ie}}}},R={x:O("x"),y:O("y")},L=()=>{const{Vt:q,Lt:$}=n,re=(le,ie)=>WU(0,1,le/(le+ie)||0);return{x:re($.x,q.x),y:re($.y,q.y)}},B=(q,$,re)=>{const le=re?IT:ZU;sn(q,ie=>{le(ie.Ut,$)})},_=(q,$)=>{sn(q,re=>{const[le,ie]=$(re);ll(le,ie)})},H=(q,$,re)=>{const le=wT(re),ie=le?re:!0,fe=le?!re:!0;ie&&B(k,q,$),fe&&B(M,q,$)},U=()=>{const q=L(),$=re=>le=>[le.Ut,{[o]:nC(re)+""}];_(k,$(q.x)),_(M,$(q.y))},G=()=>{if(!om){const{Tt:q}=n,$=KR(q,ci(b)),re=le=>ie=>[ie.Ut,{[i]:nC(le)+""}];_(k,re($.x)),_(M,re($.y))}},K=()=>{const{Tt:q}=n,$=lk(q),re=le=>ie=>[ie.Ut,{[a]:le?"0":"1"}];_(k,re($.x)),_(M,re($.y)),om&&(k.forEach(R.x.Rt),M.forEach(R.y.Rt))},z=()=>{if(y&&!v){const{Vt:q,Tt:$}=n,re=lk($),le=KR($,ci(b)),ie=fe=>{const{Ut:ye}=fe,ge=ag(ye)===p&&ye,me=(Ce,je,Ie)=>{const Fe=je*Ce;return JU(Ie?Fe:-Fe)};return[ge,ge&&{transform:ak({x:me(le.x,q.x,re.x),y:me(le.y,q.y,re.y)})}]};_(k,ie),_(M,ie)}},ne=q=>{const $=q?"x":"y",le=gf(`${bi} ${q?z5e:V5e}`),ie=gf(cz),fe=gf(bA),ye={Ut:le,Pt:ie,kt:fe},ge=R[$];return _n(q?k:M,ye),_n(C,[mo(le,ie),mo(ie,fe),wt(Ff,le),ge&&ge.Rt(ye),r(ye,H,q)]),ye},J=wt(ne,!0),ee=wt(ne,!1),Z=()=>(mo(I,k[0].Ut),mo(I,M[0].Ut),wt(fi,C));return J(),ee(),[{Nt:U,qt:G,Bt:K,Ft:z,jt:H,Xt:{Yt:k,Wt:J,Jt:wt(_,k)},Gt:{Yt:M,Wt:ee,Jt:wt(_,M)}},Z]},c9e=(e,t,n,r)=>(o,i,a)=>{const{ht:s,U:l,L:u,gt:d,Kt:h,Ot:p}=t,{Ut:m,Pt:b,kt:v}=o,[y,S]=Tu(333),[x,C]=Tu(444),k=O=>{mi(d.scrollBy)&&d.scrollBy({behavior:"smooth",left:O.x,top:O.y})},M=()=>{const O="pointerup pointercancel lostpointercapture",R=`client${a?"X":"Y"}`,L=a?_h:Lv,B=a?"left":"top",_=a?"w":"h",H=a?"x":"y",U=(K,z)=>ne=>{const{Vt:J}=n,ee=gc(b)[_]-gc(v)[_],q=z*ne/ee*J[H];Oi(d,{[H]:K+q})},G=[];return bn(b,"pointerdown",K=>{const z=cf(K.target,`.${bA}`)===v,ne=z?v:b,J=e.scrollbars,ee=J[z?"dragScroll":"clickScroll"],{button:Z,isPrimary:q,pointerType:$}=K,{pointers:re}=J;if(Z===0&&q&&ee&&(re||[]).includes($)){fi(G),C();const ie=!z&&(K.shiftKey||ee==="instant"),fe=wt(sk,v),ye=wt(sk,b),ge=(at,vt)=>(at||fe())[B]-(vt||ye())[B],me=qE(sk(d)[L])/gc(d)[_]||1,Ce=U(ci(d)[H],1/me),je=K[R],Ie=fe(),Fe=ye(),ce=Ie[L],Ne=ge(Ie,Fe)+ce/2,Pe=je-Fe[B],_e=z?0:Pe-Ne,qe=at=>{fi(it),ne.releasePointerCapture(at.pointerId)},Xe=z||ie,Qe=p(),it=[bn(h,O,qe),bn(h,"selectstart",at=>oC(at),{H:!1}),bn(b,O,qe),Xe&&bn(b,"pointermove",at=>Ce(_e+(at[R]-je))),Xe&&(()=>{const at=ci(d);Qe();const vt=ci(d),Mt={x:vt.x-at.x,y:vt.y-at.y};(X0(Mt.x)>3||X0(Mt.y)>3)&&(p(),Oi(d,at),k(Mt),x(Qe))})];if(ne.setPointerCapture(K.pointerId),ie)Ce(_e);else if(!z){const at=Rv(fz);if(at){const vt=at(Ce,_e,ce,Mt=>{Mt?Qe():_n(it,Qe)});_n(it,vt),_n(G,wt(vt,!0))}}}})};let I=!0;return wt(fi,[bn(v,"pointermove pointerleave",r),bn(m,"pointerenter",()=>{i(t5,!0)}),bn(m,"pointerleave pointercancel",()=>{i(t5,!1)}),!u&&bn(m,"mousedown",()=>{const O=tC();(GR(O,Qa)||GR(O,vc)||O===document.body)&&J0(wt(iC,l),25)}),bn(m,"wheel",O=>{const{deltaX:R,deltaY:L,deltaMode:B}=O;I&&B===0&&ag(m)===s&&k({x:R,y:L}),I=!1,i(o5,!0),y(()=>{I=!0,i(o5)}),oC(O)},{H:!1,I:!0}),bn(m,"pointerdown",wt(bn,h,"click",tz,{A:!0,I:!0,H:!1}),{I:!0}),M(),S,C])},u9e=(e,t,n,r,o,i)=>{let a,s,l,u,d,h=ps,p=0;const m=["mouse","pen"],b=$=>m.includes($.pointerType),[v,y]=Tu(),[S,x]=Tu(100),[C,k]=Tu(100),[M,I]=Tu(()=>p),[O,R]=l9e(e,o,r,c9e(t,o,r,$=>b($)&&J())),{ht:L,Qt:B,wt:_}=o,{jt:H,Nt:U,qt:G,Bt:K,Ft:z}=O,ne=($,re)=>{if(I(),$)H(r5);else{const le=wt(H,r5,!0);p>0&&!re?M(le):le()}},J=()=>{(l?!a:!u)&&(ne(!0),S(()=>{ne(!1)}))},ee=$=>{H(lC,$,!0),H(lC,$,!1)},Z=$=>{b($)&&(a=l,l&&ne(!0))},q=[I,x,k,y,()=>h(),bn(L,"pointerover",Z,{A:!0}),bn(L,"pointerenter",Z),bn(L,"pointerleave",$=>{b($)&&(a=!1,l&&ne(!1))}),bn(L,"pointermove",$=>{b($)&&s&&J()}),bn(B,"scroll",$=>{v(()=>{G(),J()}),i($),z()})];return[()=>wt(fi,_n(q,R())),({It:$,Dt:re,Zt:le,tn:ie})=>{const{nn:fe,sn:ye,en:ge,cn:me}=ie||{},{Ct:Ce,_t:je}=le||{},{F:Ie}=n,{T:Fe}=Cs(),{k:ce,rn:Ne}=r,[Pe,_e]=$("showNativeOverlaidScrollbars"),[qe,Xe]=$("scrollbars.theme"),[Qe,it]=$("scrollbars.visibility"),[at,vt]=$("scrollbars.autoHide"),[Mt,Kt]=$("scrollbars.autoHideSuspend"),[gn]=$("scrollbars.autoHideDelay"),[Ge,ut]=$("scrollbars.dragScroll"),[mt,It]=$("scrollbars.clickScroll"),[Ot,Zn]=$("overflow"),$n=je&&!re,io=Ne.x||Ne.y,Tn=fe||ye||me||Ce||re,Pn=ge||it||Zn,er=Pe&&Fe.x&&Fe.y,ir=(Gt,gr,Un)=>{const Et=Gt.includes(Vu)&&(Qe===lc||Qe==="auto"&&gr===Vu);return H(W5e,Et,Un),Et};if(p=gn,$n&&(Mt&&io?(ee(!1),h(),C(()=>{h=bn(B,"scroll",wt(ee,!0),{A:!0})})):ee(!0)),_e&&H(Y5e,er),Xe&&(H(d),H(qe,!0),d=qe),Kt&&!Mt&&ee(!0),vt&&(s=at==="move",l=at==="leave",u=at==="never",ne(u,!0)),ut&&H($5e,Ge),It&&H(Z5e,!!mt),Pn){const Gt=ir(Ot.x,ce.x,!0),gr=ir(Ot.y,ce.y,!1);H(G5e,!(Gt&&gr))}Tn&&(G(),U(),z(),me&&K(),H(n5,!Ne.x,!0),H(n5,!Ne.y,!1),H(U5e,Ie&&!_))},{},O]},d9e=e=>{const t=Cs(),{Z:n,P:r}=t,{elements:o}=n(),{padding:i,viewport:a,content:s}=o,l=tw(e),u=l?{}:e,{elements:d}=u,{padding:h,viewport:p,content:m}=d||{},b=l?e:u.target,v=qU(b),y=b.ownerDocument,S=y.documentElement,x=()=>y.defaultView||Bo,C=wt(a9e,[b]),k=wt(vz,[b]),M=wt(gf,""),I=wt(C,M,a),O=wt(k,M,s),R=ce=>{const Ne=gc(ce),Pe=ow(ce),_e=wa(ce,aA),qe=wa(ce,sA);return Pe.w-Ne.w>0&&!Hf(_e)||Pe.h-Ne.h>0&&!Hf(qe)},L=I(p),B=L===b,_=B&&v,H=!B&&O(m),U=!B&&L===H,G=_?S:L,K=_?G:b,z=!B&&k(M,i,h),ne=!U&&H,J=[ne,G,z,K].map(ce=>tw(ce)&&!ag(ce)&&ce),ee=ce=>ce&&UU(J,ce),Z=!ee(G)&&R(G)?G:b,q=_?S:G,re={vt:b,ht:K,U:G,ln:z,bt:ne,gt:q,Qt:_?y:G,an:v?S:Z,Kt:y,wt:v,Mt:l,L:B,un:x,yt:ce=>hA(G,Qa,ce),St:(ce,Ne)=>rw(G,Qa,ce,Ne),Ot:()=>rw(q,Qa,R5e,!0)},{vt:le,ht:ie,ln:fe,U:ye,bt:ge}=re,me=[()=>{$a(ie,[vc,ck]),$a(le,ck),v&&$a(S,[ck,vc])}];let Ce=eC([ge,ye,fe,ie,le].find(ce=>ce&&!ee(ce)));const je=_?le:ge||ye,Ie=wt(fi,me);return[re,()=>{const ce=x(),Ne=tC(),Pe=it=>{mo(ag(it),eC(it)),Ff(it)},_e=it=>bn(it,"focusin focusout focus blur",tz,{I:!0,H:!1}),qe="tabindex",Xe=uA(ye,qe),Qe=_e(Ne);return Ks(ie,vc,B?"":P5e),Ks(fe,sC,""),Ks(ye,Qa,""),Ks(ge,QR,""),B||(Ks(ye,qe,Xe||"-1"),v&&Ks(S,JR,"")),mo(je,Ce),mo(ie,fe),mo(fe||ie,!B&&ye),mo(ye,ge),_n(me,[Qe,()=>{const it=tC(),at=ee(ye),vt=at&&it===ye?le:it,Mt=_e(vt);$a(fe,sC),$a(ge,QR),$a(ye,Qa),v&&$a(S,JR),Xe?Ks(ye,qe,Xe):$a(ye,qe),ee(ge)&&Pe(ge),at&&Pe(ye),ee(fe)&&Pe(fe),iC(vt),Mt()}]),r&&!B&&(fA(ye,Qa,lz),_n(me,wt($a,ye,Qa))),iC(!B&&v&&Ne===le&&ce.top===ce?ye:Ne),Qe(),Ce=0,Ie},Ie]},f9e=({bt:e})=>({Zt:t,fn:n,Dt:r})=>{const{xt:o}=t||{},{$t:i}=n;e&&(o||r)&&ll(e,{[Lv]:i&&"100%"})},h9e=({ht:e,ln:t,U:n,L:r},o)=>{const[i,a]=ii({i:S5e,o:$R()},wt($R,e,"padding",""));return({It:s,Zt:l,fn:u,Dt:d})=>{let[h,p]=a(d);const{P:m}=Cs(),{dt:b,Ht:v,Ct:y}=l||{},{F:S}=u,[x,C]=s("paddingAbsolute");(b||p||(d||v))&&([h,p]=i(d));const M=!r&&(C||y||p);if(M){const I=!x||!t&&!m,O=h.r+h.l,R=h.t+h.b,L={[xm]:I&&!S?-O:0,[lf]:I?-R:0,[Tm]:I&&S?-O:0,top:I?-h.t:0,right:I?S?-h.r:"auto":0,left:I?S?"auto":-h.l:0,[_h]:I&&`calc(100% + ${O}px)`},B={[iA]:I?h.t:0,[bm]:I?h.r:0,[Sm]:I?h.b:0,[wm]:I?h.l:0};ll(t||n,L),ll(n,B),Ut(o,{ln:h,_n:!I,j:t?B:Ut({},L,B)})}return{dn:M}}},p9e=(e,t)=>{const n=Cs(),{ht:r,ln:o,U:i,L:a,Qt:s,gt:l,wt:u,St:d,un:h}=e,{P:p}=n,m=u&&a,b=wt(K0,0),v={display:()=>!1,direction:$=>$!=="ltr",flexDirection:$=>$.endsWith("-reverse"),writingMode:$=>$!=="horizontal-tb"},y=Yi(v),S={i:lA,o:{w:0,h:0}},x={i:o0,o:{}},C=$=>{d(sz,!m&&$)},k=$=>{if(!y.some(je=>{const Ie=$[je];return Ie&&v[je](Ie)}))return{D:{x:0,y:0},M:{x:1,y:1}};C(!0);const le=ci(l),ie=d(F5e,!0),fe=bn(s,Vu,je=>{const Ie=ci(l);je.isTrusted&&Ie.x===le.x&&Ie.y===le.y&&gA(je)},{I:!0,A:!0});Oi(l,{x:0,y:0}),ie();const ye=ci(l),ge=ow(l);Oi(l,{x:ge.w,y:ge.h});const me=ci(l);Oi(l,{x:me.x-ye.x<1&&-ge.w,y:me.y-ye.y<1&&-ge.h});const Ce=ci(l);return Oi(l,le),Rf(()=>fe()),{D:ye,M:Ce}},M=($,re)=>{const le=Bo.devicePixelRatio%1!==0?1:0,ie={w:b($.w-re.w),h:b($.h-re.h)};return{w:ie.w>le?ie.w:0,h:ie.h>le?ie.h:0}},[I,O]=ii(S,wt(mA,i)),[R,L]=ii(S,wt(ow,i)),[B,_]=ii(S),[H]=ii(x),[U,G]=ii(S),[K]=ii(x),[z]=ii({i:($,re)=>TT($,re,y),o:{}},()=>D5e(i)?wa(i,y):{}),[ne,J]=ii({i:($,re)=>o0($.D,re.D)&&o0($.M,re.M),o:nz()}),ee=Rv(wA),Z=($,re)=>`${re?j5e:L5e}${w5e($)}`,q=$=>{const re=ie=>[lc,Su,Vu].map(fe=>Z(fe,ie)),le=re(!0).concat(re()).join(" ");d(le),d(Yi($).map(ie=>Z($[ie],ie==="x")).join(" "),!0)};return({It:$,Zt:re,fn:le,Dt:ie},{dn:fe})=>{const{dt:ye,Ht:ge,Ct:me,_t:Ce,zt:je}=re||{},Ie=ee&&ee.V(e,t,le,n,$),{Y:Fe,W:ce,J:Ne}=Ie||{},[Pe,_e]=dz($,n),[qe,Xe]=$("overflow"),Qe=Hf(qe.x),it=Hf(qe.y),at=ye||fe||ge||me||je||_e;let vt=O(ie),Mt=L(ie),Kt=_(ie),gn=G(ie);if(_e&&p&&d(lz,!Pe),at){hA(r,vc,a0)&&C(!0);const[ao]=ce?ce():[],[qn]=vt=I(ie),[so]=Mt=R(ie),Ur=QU(i),So=m&&M5e(h()),wi={w:b(so.w+qn.w),h:b(so.h+qn.h)},Ms={w:b((So?So.w:Ur.w+b(Ur.w-so.w))+qn.w),h:b((So?So.h:Ur.h+b(Ur.h-so.h))+qn.h)};ao&&ao(),gn=U(Ms),Kt=B(M(wi,Ms),ie)}const[Ge,ut]=gn,[mt,It]=Kt,[Ot,Zn]=Mt,[$n,io]=vt,[Tn,Pn]=H({x:mt.w>0,y:mt.h>0}),er=Qe&&it&&(Tn.x||Tn.y)||Qe&&Tn.x&&!Tn.y||it&&Tn.y&&!Tn.x,ir=fe||me||je||io||Zn||ut||It||Xe||_e||at,Gt=K5e(Tn,qe),[gr,Un]=K(Gt.k),[Et,Yr]=z(ie),Mr=me||Ce||Yr||Pn||ie,[wo,jn]=Mr?ne(k(Et),ie):J();return ir&&(Un&&q(Gt.k),Ne&&Fe&&ll(i,Ne(Gt,le,Fe(Gt,Ot,$n)))),C(!1),rw(r,vc,a0,er),rw(o,sC,a0,er),Ut(t,{k:gr,Lt:{x:Ge.w,y:Ge.h},Vt:{x:mt.w,y:mt.h},rn:Tn,Tt:A5e(wo,mt)}),{en:Un,nn:ut,sn:It,cn:jn||It,pn:Mr}}},m9e=e=>{const[t,n,r]=d9e(e),o={ln:{t:0,r:0,b:0,l:0},_n:!1,j:{[xm]:0,[lf]:0,[Tm]:0,[iA]:0,[bm]:0,[Sm]:0,[wm]:0},Lt:{x:0,y:0},Vt:{x:0,y:0},k:{x:Su,y:Su},rn:{x:!1,y:!1},Tt:nz()},{vt:i,gt:a,L:s,Ot:l}=t,{P:u,T:d}=Cs(),h=!u&&(d.x||d.y),p=[f9e(t),h9e(t,o),p9e(t,o)];return[n,m=>{const b={},y=h&&ci(a),S=y&&l();return sn(p,x=>{Ut(b,x(m,b)||{})}),Oi(a,y),S&&S(),s||Oi(i,0),b},o,t,r]},g9e=(e,t,n,r,o)=>{let i=!1;const a=s5(t,{}),[s,l,u,d,h]=m9e(e),[p,m,b]=i9e(d,u,a,k=>{C({},k)}),[v,y,,S]=u9e(e,t,b,u,d,o),x=k=>Yi(k).some(M=>!!k[M]),C=(k,M)=>{if(n())return!1;const{vn:I,Dt:O,At:R,hn:L}=k,B=I||{},_=!!O||!i,H={It:s5(t,B,_),vn:B,Dt:_};if(L)return y(H),!1;const U=M||m(Ut({},H,{At:R})),G=l(Ut({},H,{fn:b,Zt:U}));y(Ut({},H,{Zt:U,tn:G}));const K=x(U),z=x(G),ne=K||z||!cA(B)||_;return i=!0,ne&&r(k,{Zt:U,tn:G}),ne};return[()=>{const{an:k,gt:M,Ot:I}=d,O=ci(k),R=[p(),s(),v()],L=I();return Oi(M,O),L(),wt(fi,R)},C,()=>({gn:b,bn:u}),{wn:d,yn:S},h]},SA=new WeakMap,v9e=(e,t)=>{SA.set(e,t)},y9e=e=>{SA.delete(e)},yz=e=>SA.get(e),yl=(e,t,n)=>{const{nt:r}=Cs(),o=tw(e),i=o?e:e.target,a=yz(i);if(t&&!a){let s=!1;const l=[],u={},d=B=>{const _=VU(B),H=Rv(O5e);return H?H(_,!0):_},h=Ut({},r(),d(t)),[p,m,b]=aC(),[v,y,S]=aC(n),x=(B,_)=>{S(B,_),b(B,_)},[C,k,M,I,O]=g9e(e,h,()=>s,({vn:B,Dt:_},{Zt:H,tn:U})=>{const{dt:G,Ct:K,xt:z,Ht:ne,Et:J,_t:ee}=H,{nn:Z,sn:q,en:$,cn:re}=U;x("updated",[L,{updateHints:{sizeChanged:!!G,directionChanged:!!K,heightIntrinsicChanged:!!z,overflowEdgeChanged:!!Z,overflowAmountChanged:!!q,overflowStyleChanged:!!$,scrollCoordinatesChanged:!!re,contentMutation:!!ne,hostMutation:!!J,appear:!!ee},changedOptions:B||{},force:!!_}])},B=>x("scroll",[L,B])),R=B=>{y9e(i),fi(l),s=!0,x("destroyed",[L,B]),m(),y()},L={options(B,_){if(B){const H=_?r():{},U=hz(h,Ut(H,d(B)));cA(U)||(Ut(h,U),k({vn:U}))}return Ut({},h)},on:v,off:(B,_)=>{B&&_&&y(B,_)},state(){const{gn:B,bn:_}=M(),{F:H}=B,{Lt:U,Vt:G,k:K,rn:z,ln:ne,_n:J,Tt:ee}=_;return Ut({},{overflowEdge:U,overflowAmount:G,overflowStyle:K,hasOverflow:z,scrollCoordinates:{start:ee.D,end:ee.M},padding:ne,paddingAbsolute:J,directionRTL:H,destroyed:s})},elements(){const{vt:B,ht:_,ln:H,U,bt:G,gt:K,Qt:z}=I.wn,{Xt:ne,Gt:J}=I.yn,ee=q=>{const{kt:$,Pt:re,Ut:le}=q;return{scrollbar:le,track:re,handle:$}},Z=q=>{const{Yt:$,Wt:re}=q,le=ee($[0]);return Ut({},le,{clone:()=>{const ie=ee(re());return k({hn:!0}),ie}})};return Ut({},{target:B,host:_,padding:H||U,viewport:U,content:G||U,scrollOffsetElement:K,scrollEventElement:z,scrollbarHorizontal:Z(ne),scrollbarVertical:Z(J)})},update:B=>k({Dt:B,At:!0}),destroy:wt(R,!1),plugin:B=>u[Yi(B)[0]]};return _n(l,[O]),v9e(i,L),iz(rz,yl,[L,p,u]),s9e(I.wn.wt,!o&&e.cancel)?(R(!0),L):(_n(l,C()),x("initialized",[L]),L.update(),L)}return a};yl.plugin=e=>{const t=Ts(e),n=t?e:[e],r=n.map(o=>iz(o,yl)[0]);return N5e(n),t?r:r[0]};yl.valid=e=>{const t=e&&e.elements,n=mi(t)&&t();return ew(n)&&!!yz(n.target)};yl.env=()=>{const{N:e,T:t,P:n,G:r,st:o,et:i,Z:a,tt:s,nt:l,ot:u}=Cs();return Ut({},{scrollbarsSize:e,scrollbarsOverlaid:t,scrollbarsHiding:n,scrollTimeline:r,staticDefaultInitialization:o,staticDefaultOptions:i,getDefaultInitialization:a,setDefaultInitialization:s,getDefaultOptions:l,setDefaultOptions:u})};yl.nonce=t9e;yl.trustedTypePolicy=k5e;yl.plugin([X5e,q5e,J5e]);const b9e=(e,t)=>{typeof t!="boolean"&&(t=!0);const n=D.useRef(null);return D.useEffect(()=>{if(e&&t)return n.current=yl(e.parentElement,{scrollbars:{theme:"os-theme-dark",autoHide:"scroll",clickScroll:!0},overflow:{x:"hidden",y:"scroll"}}),()=>{n.current&&(n.current.destroy(),n.current=null)}},[e,t]),n.current};function sg(e,t){const n={},r={day:"YYYY-MM-DD ddd",week:"YYYY-[W]WW",month:"YYYY-MM",quarter:"YYYY-[Q]Q",year:"YYYY"};return e.forEach(o=>{const i=o.pinned?"PINNED":N.moment(o.createdAt,"YYYY/MM/DD HH:mm:ss").format(r[t]);n[i]||(n[i]=[]),n[i].push(o)}),n}function w9e(e){return e.slice().sort((t,n)=>t.pinned!==n.pinned?t.pinned?-1:1:new Date(n.createdAt).getTime()-new Date(t.createdAt).getTime())}function S9e(e){const{tag:t,duration:n,type:r,text:o,filter:i,path:a,metadata:s}=e,l=Ct.getQueryById(i),u=!s||Object.keys(s).length===0;return!(!!(t||n&&n.from<n.to||r||o||!u||a||l?.id)||l)}const T9e=({updateThinos:e,listView:t})=>{const{locationState:{query:n},memoState:{memos:r},dailyNotesState:{app:o,settings:i,plugin:a}}=D.useContext(ct),[s,l]=D.useState([]),[u,d,h]=Ho([]),[p,m]=D.useState({isFetching:!1,isComplete:!1,batchSize:20,currentBatchIndex:0}),b=D.useRef(null),v=D.useRef(null),y=D.useRef(null);b9e(b.current,i?.ShowScrollbar);const[S,x]=D.useState({showDayMark:o?.loadLocalStorage("showDayMark")||!1,dayMarkRange:o?.loadLocalStorage("dayMarkRange")||"day",dayMarkThinos:{}}),C=KRe(),k=qRe(),M=D.useRef(!1);D.useEffect(()=>{k(),I()},[t]),D.useEffect(()=>()=>{v.current&&(v.current=null),y.current&&(y.current=null)},[]),D.useLayoutEffect(()=>{if(r.length!==0&&M.current===!0)return;const U=x9e(o||window.app);if(!U||U.length===0)return;d(U),l(U);const G=o?.loadLocalStorage("showDayMark")||!1;x(K=>({...K,showDayMark:G,dayMarkThinos:G?sg(U,o?.loadLocalStorage("dayMarkRange")||"day"):K.dayMarkThinos}))},[]),D.useEffect(()=>{if(r.length===0&&!de.initialized)return;m(G=>({...G,isFetching:!1,isComplete:!1,currentBatchIndex:0}));const U=w9e(r);return hc({memos:U,query:n,filterOptions:{filterDoneTasks:i?.HideDoneTasks||!1},plugin:a}).then(G=>(M.current=!0,e&&e(G),!ws(h.current,G)&&d(G),G)),()=>{M.current=!1}},[r,n,i?.HideDoneTasks]),D.useEffect(()=>{m(U=>({...U,isComplete:!1,currentBatchIndex:0})),I(),u.length>0&&u.length<=p.batchSize&&m(U=>({...U,isComplete:!0}))},[u]),D.useEffect(()=>{const U=s.length===u.length&&u.length>0;U!==p.isComplete&&m(z=>({...z,isComplete:U})),I9e(s||[],o);const G=i?.showDayMark||!1,K=i?.dayMarkRange||"day";o?.saveLocalStorage("showDayMark",G),o?.saveLocalStorage("dayMarkRange",K),x(z=>({showDayMark:G,dayMarkRange:K,dayMarkThinos:G?sg(s,K):z.dayMarkThinos}))},[s,i?.showDayMark,i?.dayMarkRange]),D.useEffect(()=>{C()},[n]);const I=()=>{const U=p.batchSize,G=u.slice(0,U);l(G),m(K=>({...K,currentBatchIndex:1,isComplete:G.length===u.length}))},O=D.useCallback(N.debounce(()=>{try{if(p.isFetching)return;const{batchSize:U,currentBatchIndex:G,isComplete:K}=p,z=h.current.length,ne=s.length;if(K&&ne>=z)return;K&&ne<z&&m(ee=>({...ee,isComplete:!1}));const J=G*U;if(J>=h.current.length){m(ee=>({...ee,isComplete:!0}));return}m(ee=>({...ee,isFetching:!0})),setTimeout(()=>{const ee=Math.min(J+U,h.current.length),Z=h.current.slice(0,ee);l(Z);const q=ee===h.current.length;m($=>({...$,isFetching:!1,isComplete:q,currentBatchIndex:$.currentBatchIndex+1}))},300)}catch(U){console.error(U),new N.Notice(U.response?.data?.message||U.message||"Failed to load more memos"),m(G=>({...G,isFetching:!1}))}},500),[p,s,h]);g5e({statusRef:v,isComplete:p.isComplete,fetchMore:O,cachedMemos:s});const R=()=>de.fetchAllMemos().then(()=>{}).catch(U=>{console.error("Failed to refresh memos:",U)}),L=D.useCallback(N.debounce(async()=>{if(!p.isFetching){m(U=>({...U,isFetching:!0,isComplete:!1,currentBatchIndex:0}));try{await R(),setTimeout(()=>{C(),setTimeout(()=>{m(U=>({...U,isFetching:!1}))},300)},100)}catch(U){console.error("Pull-to-refresh failed:",U),new N.Notice("Failed to refresh data"),m(G=>({...G,isFetching:!1}))}}},800),[p.isFetching,R,C]),B=D.useMemo(()=>w.jsx("div",{ref:v,className:tn("status-text-container",t==="calendar"||t==="table"?"visually-hidden":""),children:w.jsx("p",{className:"status-text",children:p.isFetching?w.jsx("span",{className:"fetching-indicator",children:E("Fetching data...")}):p.isComplete?w.jsx(w.Fragment,{children:u.length===0?E("Noooop!"):w.jsxs(w.Fragment,{children:[E("All Data is Loaded 🎉"),w.jsx("span",{className:"cursor-pointer hover:text-green-600 ml-2",onClick:L,title:"Refresh to check for new memos",children:"↻"})]})}):w.jsx(w.Fragment,{children:w.jsx("span",{ref:y,className:"cursor-pointer hover:text-green-600",onClick:()=>!p.isFetching&&O(),children:E("fetch more")})})})}),[t,O,u,p.isFetching,p.isComplete,L]),_=U=>{const{showDayMark:G,dayMarkRange:K,dayMarkThinos:z}=S;switch(U){case"list":return w.jsx(A0,{breakpointCols:1,className:`${t}-view masonry-memolist`,columnClassName:"masonry-memolist-grid_column",children:G?w.jsx(w.Fragment,{children:Object.keys(z).sort((ne,J)=>ne==="PINNED"?-1:J==="PINNED"?1:J.localeCompare(ne)).map(ne=>w.jsx(cE,{type:"list",thinos:z[ne],dayMark:ne,dayMarkRange:K},ne))}):s.map((ne,J)=>w.jsx(vo,{memo:ne},`${ne.id}-${J}`))});case"waterfall":return w.jsx(w.Fragment,{children:G&&Object.keys(z).length>0?Object.keys(z).sort((ne,J)=>ne==="PINNED"?-1:J==="PINNED"?1:J.localeCompare(ne)).map(ne=>w.jsx(cE,{type:"waterfall",thinos:z[ne],dayMark:ne,dayMarkRange:K},ne)):w.jsx(A0,{breakpointCols:3,className:`${t}-view masonry-memolist`,columnClassName:"masonry-memolist-grid_column",children:s.map((ne,J)=>w.jsx(vo,{memo:ne},`${ne.id}-${J}`))})});case"chat":return w.jsx(XRe,{thinos:s});case"calendar":return w.jsx(G0e,{thinos:u});case"table":return w.jsx(ySe,{thinos:u,isFiltering:!S9e(n)});case"moments":return w.jsx(E9e,{thinos:s})}},H=U=>{switch(U){case"top":return t==="chat"&&B;case"bottom":return t!=="table"&&t!=="calendar"&&B}};return w.jsxs(eA,{className:`memolist-wrapper ${p.isComplete?"completed":""} `,mode:t==="chat"?"bottom":"top",initialScrollBehavior:"auto",checkInterval:30,followButtonClassName:tn("scroll-to-bottom-button",t==="chat"?"to-bottom":"to-top",(t==="table"||t==="calendar")&&"thino-hidden",!i?.ShowScrollToTopButton&&"thino-hidden"),scrollViewClassName:"memolist-scrollview",children:[H("top"),w.jsx("div",{ref:b,className:"memolist-container",children:_(t)}),H("bottom")]})};function bz(e){return`memosListCache:${e}`}function x9e(e){try{const t=bz(e?.appId),n=ur.get([t])[t];return n?JSON.parse(n)?.memos||[]:[]}catch(t){return console.error(t),[]}}function I9e(e,t){try{if(!e)return;const n=e?.slice(0,100),r=bz(t?.appId);ur.set({[r]:JSON.stringify({memos:n})})}catch(n){console.error(n)}}const k9e=({userIcon:e})=>w.jsx("div",{className:"moments-view-user-icon",ref:t=>{if(e){t?.empty();return}e||t&&N.setIcon(t,"Memos")},style:{backgroundImage:`url("${e}")`}}),cC="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZlcnNpb249IjEuMSIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHhtbG5zOnN2Z2pzPSJodHRwOi8vc3ZnanMuZGV2L3N2Z2pzIiB3aWR0aD0iMTQ0MCIgaGVpZ2h0PSI1NjAiIHByZXNlcnZlQXNwZWN0UmF0aW89Im5vbmUiIHZpZXdCb3g9IjAgMCAxNDQwIDU2MCI+PGcgbWFzaz0idXJsKCZxdW90OyNTdmdqc01hc2sxMDgwJnF1b3Q7KSIgZmlsbD0ibm9uZSI+PHJlY3Qgd2lkdGg9IjE0NDAiIGhlaWdodD0iNTYwIiB4PSIwIiB5PSIwIiBmaWxsPSIjMGUyYTQ3Ij48L3JlY3Q+PHVzZSB4bGluazpocmVmPSIjU3ZnanNTeW1ib2wxMDg3IiB4PSIwIiB5PSIwIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1N5bWJvbDEwODciIHg9IjcyMCIgeT0iMCI+PC91c2U+PC9nPjxkZWZzPjxtYXNrIGlkPSJTdmdqc01hc2sxMDgwIj48cmVjdCB3aWR0aD0iMTQ0MCIgaGVpZ2h0PSI1NjAiIGZpbGw9IiNmZmZmZmYiPjwvcmVjdD48L21hc2s+PHBhdGggZD0iTS0xIDAgYTEgMSAwIDEgMCAyIDAgYTEgMSAwIDEgMCAtMiAweiIgaWQ9IlN2Z2pzUGF0aDEwODIiPjwvcGF0aD48cGF0aCBkPSJNLTMgMCBhMyAzIDAgMSAwIDYgMCBhMyAzIDAgMSAwIC02IDB6IiBpZD0iU3ZnanNQYXRoMTA4NiI+PC9wYXRoPjxwYXRoIGQ9Ik0tNSAwIGE1IDUgMCAxIDAgMTAgMCBhNSA1IDAgMSAwIC0xMCAweiIgaWQ9IlN2Z2pzUGF0aDEwODMiPjwvcGF0aD48cGF0aCBkPSJNMiAtMiBMLTIgMnoiIGlkPSJTdmdqc1BhdGgxMDg0Ij48L3BhdGg+PHBhdGggZD0iTTYgLTYgTC02IDZ6IiBpZD0iU3ZnanNQYXRoMTA4MSI+PC9wYXRoPjxwYXRoIGQ9Ik0zMCAtMzAgTC0zMCAzMHoiIGlkPSJTdmdqc1BhdGgxMDg1Ij48L3BhdGg+PC9kZWZzPjxzeW1ib2wgaWQ9IlN2Z2pzU3ltYm9sMTA4NyI+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMzAiIHk9IjMwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgyIiB4PSIzMCIgeT0iOTAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgyIiB4PSIzMCIgeT0iMTUwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSIzMCIgeT0iMjEwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSIzMCIgeT0iMjcwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSIzMCIgeT0iMzMwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSIzMCIgeT0iMzkwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSIzMCIgeT0iNDUwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MiIgeD0iMzAiIHk9IjUxMCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODMiIHg9IjMwIiB5PSI1NzAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODIiIHg9IjkwIiB5PSIzMCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjkwIiB5PSI5MCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjkwIiB5PSIxNTAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjkwIiB5PSIyMTAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgyIiB4PSI5MCIgeT0iMjcwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI5MCIgeT0iMzMwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iOTAiIHk9IjM5MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MiIgeD0iOTAiIHk9IjQ1MCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODMiIHg9IjkwIiB5PSI1MTAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSI5MCIgeT0iNTcwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSIxNTAiIHk9IjMwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSIxNTAiIHk9IjkwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSIxNTAiIHk9IjE1MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iMTUwIiB5PSIyMTAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODQiIHg9IjE1MCIgeT0iMjcwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iMTUwIiB5PSIzMzAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjE1MCIgeT0iMzkwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMTUwIiB5PSI0NTAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSIxNTAiIHk9IjUxMCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iMTUwIiB5PSI1NzAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODUiIHg9IjIxMCIgeT0iMzAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIiBzdHJva2Utd2lkdGg9IjMiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODQiIHg9IjIxMCIgeT0iOTAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSIyMTAiIHk9IjE1MCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODUiIHg9IjIxMCIgeT0iMjEwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSIgc3Ryb2tlLXdpZHRoPSIzIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgyIiB4PSIyMTAiIHk9IjI3MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NCIgeD0iMjEwIiB5PSIzMzAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSIyMTAiIHk9IjM5MCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjIxMCIgeT0iNDUwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMjEwIiB5PSI1MTAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg0IiB4PSIyMTAiIHk9IjU3MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iMjcwIiB5PSIzMCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMjcwIiB5PSI5MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NCIgeD0iMjcwIiB5PSIxNTAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSIyNzAiIHk9IjIxMCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iMjcwIiB5PSIyNzAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODMiIHg9IjI3MCIgeT0iMzMwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMjcwIiB5PSIzOTAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg1IiB4PSIyNzAiIHk9IjQ1MCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiIHN0cm9rZS13aWR0aD0iMyI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMjcwIiB5PSI1MTAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSIyNzAiIHk9IjU3MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMzMwIiB5PSIzMCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODYiIHg9IjMzMCIgeT0iOTAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODMiIHg9IjMzMCIgeT0iMTUwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMzMwIiB5PSIyMTAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSIzMzAiIHk9IjI3MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMzMwIiB5PSIzMzAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODUiIHg9IjMzMCIgeT0iMzkwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIiBzdHJva2Utd2lkdGg9IjMiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODQiIHg9IjMzMCIgeT0iNDUwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iMzMwIiB5PSI1MTAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODUiIHg9IjMzMCIgeT0iNTcwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIiBzdHJva2Utd2lkdGg9IjMiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODYiIHg9IjM5MCIgeT0iMzAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjM5MCIgeT0iOTAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSIzOTAiIHk9IjE1MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NCIgeD0iMzkwIiB5PSIyMTAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODMiIHg9IjM5MCIgeT0iMjcwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSIzOTAiIHk9IjMzMCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODUiIHg9IjM5MCIgeT0iMzkwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSIgc3Ryb2tlLXdpZHRoPSIzIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg1IiB4PSIzOTAiIHk9IjQ1MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSIgc3Ryb2tlLXdpZHRoPSIzIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSIzOTAiIHk9IjUxMCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjM5MCIgeT0iNTcwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iNDUwIiB5PSIzMCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NSIgeD0iNDUwIiB5PSI5MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSIgc3Ryb2tlLXdpZHRoPSIzIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSI0NTAiIHk9IjE1MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iNDUwIiB5PSIyMTAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjQ1MCIgeT0iMjcwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NSIgeD0iNDUwIiB5PSIzMzAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiIHN0cm9rZS13aWR0aD0iMyI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iNDUwIiB5PSIzOTAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODMiIHg9IjQ1MCIgeT0iNDUwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg1IiB4PSI0NTAiIHk9IjUxMCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiIHN0cm9rZS13aWR0aD0iMyI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iNDUwIiB5PSI1NzAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODMiIHg9IjUxMCIgeT0iMzAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSI1MTAiIHk9IjkwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI1MTAiIHk9IjE1MCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODMiIHg9IjUxMCIgeT0iMjEwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSI1MTAiIHk9IjI3MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iNTEwIiB5PSIzMzAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI1MTAiIHk9IjM5MCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODMiIHg9IjUxMCIgeT0iNDUwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iNTEwIiB5PSI1MTAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjUxMCIgeT0iNTcwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI1NzAiIHk9IjMwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iNTcwIiB5PSI5MCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODQiIHg9IjU3MCIgeT0iMTUwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg0IiB4PSI1NzAiIHk9IjIxMCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iNTcwIiB5PSIyNzAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODQiIHg9IjU3MCIgeT0iMzMwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI1NzAiIHk9IjM5MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MiIgeD0iNTcwIiB5PSI0NTAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODYiIHg9IjU3MCIgeT0iNTEwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MiIgeD0iNTcwIiB5PSI1NzAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjYzMCIgeT0iMzAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjYzMCIgeT0iOTAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODMiIHg9IjYzMCIgeT0iMTUwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSI2MzAiIHk9IjIxMCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MiIgeD0iNjMwIiB5PSIyNzAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODYiIHg9IjYzMCIgeT0iMzMwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSI2MzAiIHk9IjM5MCIgc3Ryb2tlPSJyZ2JhKDE5NywgOTAsIDk5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NCIgeD0iNjMwIiB5PSI0NTAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjYzMCIgeT0iNTEwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg1IiB4PSI2MzAiIHk9IjU3MCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiIHN0cm9rZS13aWR0aD0iMyI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iNjkwIiB5PSIzMCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjY5MCIgeT0iOTAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjY5MCIgeT0iMTUwIiBzdHJva2U9InJnYmEoMTk3LCA5MCwgOTksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg0IiB4PSI2OTAiIHk9IjIxMCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODQiIHg9IjY5MCIgeT0iMjcwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MiIgeD0iNjkwIiB5PSIzMzAiIHN0cm9rZT0icmdiYSgxOTcsIDkwLCA5OSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODMiIHg9IjY5MCIgeT0iMzkwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NiIgeD0iNjkwIiB5PSI0NTAiIHN0cm9rZT0icmdiYSg0NywgMTE0LCAxMzEsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSI2OTAiIHk9IjUxMCIgc3Ryb2tlPSJyZ2JhKDQ3LCAxMTQsIDEzMSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODUiIHg9IjY5MCIgeT0iNTcwIiBzdHJva2U9InJnYmEoNDcsIDExNCwgMTMxLCAxKSIgc3Ryb2tlLXdpZHRoPSIzIj48L3VzZT48L3N5bWJvbD48L3N2Zz4=",l0="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZlcnNpb249IjEuMSIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHhtbG5zOnN2Z2pzPSJodHRwOi8vc3ZnanMuZGV2L3N2Z2pzIiB3aWR0aD0iMTQ0MCIgaGVpZ2h0PSI1NjAiIHByZXNlcnZlQXNwZWN0UmF0aW89Im5vbmUiIHZpZXdCb3g9IjAgMCAxNDQwIDU2MCI+PGcgbWFzaz0idXJsKCZxdW90OyNTdmdqc01hc2sxMDgwJnF1b3Q7KSIgZmlsbD0ibm9uZSI+PHJlY3Qgd2lkdGg9IjE0NDAiIGhlaWdodD0iNTYwIiB4PSIwIiB5PSIwIiBmaWxsPSJyZ2JhKDIzMSwgMjM4LCAyNDUsIDEpIj48L3JlY3Q+PHVzZSB4bGluazpocmVmPSIjU3ZnanNTeW1ib2wxMDg3IiB4PSIwIiB5PSIwIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1N5bWJvbDEwODciIHg9IjcyMCIgeT0iMCI+PC91c2U+PC9nPjxkZWZzPjxtYXNrIGlkPSJTdmdqc01hc2sxMDgwIj48cmVjdCB3aWR0aD0iMTQ0MCIgaGVpZ2h0PSI1NjAiIGZpbGw9IiNmZmZmZmYiPjwvcmVjdD48L21hc2s+PHBhdGggZD0iTS0xIDAgYTEgMSAwIDEgMCAyIDAgYTEgMSAwIDEgMCAtMiAweiIgaWQ9IlN2Z2pzUGF0aDEwODUiPjwvcGF0aD48cGF0aCBkPSJNLTMgMCBhMyAzIDAgMSAwIDYgMCBhMyAzIDAgMSAwIC02IDB6IiBpZD0iU3ZnanNQYXRoMTA4MyI+PC9wYXRoPjxwYXRoIGQ9Ik0tNSAwIGE1IDUgMCAxIDAgMTAgMCBhNSA1IDAgMSAwIC0xMCAweiIgaWQ9IlN2Z2pzUGF0aDEwODYiPjwvcGF0aD48cGF0aCBkPSJNMiAtMiBMLTIgMnoiIGlkPSJTdmdqc1BhdGgxMDg0Ij48L3BhdGg+PHBhdGggZD0iTTYgLTYgTC02IDZ6IiBpZD0iU3ZnanNQYXRoMTA4MSI+PC9wYXRoPjxwYXRoIGQ9Ik0zMCAtMzAgTC0zMCAzMHoiIGlkPSJTdmdqc1BhdGgxMDgyIj48L3BhdGg+PC9kZWZzPjxzeW1ib2wgaWQ9IlN2Z2pzU3ltYm9sMTA4NyI+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMzAiIHk9IjMwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODIiIHg9IjMwIiB5PSI5MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIiBzdHJva2Utd2lkdGg9IjMiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODMiIHg9IjMwIiB5PSIxNTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMzAiIHk9IjIxMCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgyIiB4PSIzMCIgeT0iMjcwIiBzdHJva2U9InJnYmEoMjA4LCAyMTcsIDIwOSwgMSkiIHN0cm9rZS13aWR0aD0iMyI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iMzAiIHk9IjMzMCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg0IiB4PSIzMCIgeT0iMzkwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODUiIHg9IjMwIiB5PSI0NTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NCIgeD0iMzAiIHk9IjUxMCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSIzMCIgeT0iNTcwIiBzdHJva2U9InJnYmEoMjA4LCAyMTcsIDIwOSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODYiIHg9IjkwIiB5PSIzMCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSI5MCIgeT0iOTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NiIgeD0iOTAiIHk9IjE1MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI5MCIgeT0iMjEwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODQiIHg9IjkwIiB5PSIyNzAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NiIgeD0iOTAiIHk9IjMzMCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg0IiB4PSI5MCIgeT0iMzkwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODYiIHg9IjkwIiB5PSI0NTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iOTAiIHk9IjUxMCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSI5MCIgeT0iNTcwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODQiIHg9IjE1MCIgeT0iMzAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NiIgeD0iMTUwIiB5PSI5MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSIxNTAiIHk9IjE1MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSIxNTAiIHk9IjIxMCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSIxNTAiIHk9IjI3MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSIxNTAiIHk9IjMzMCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg0IiB4PSIxNTAiIHk9IjM5MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgyIiB4PSIxNTAiIHk9IjQ1MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIiBzdHJva2Utd2lkdGg9IjMiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODMiIHg9IjE1MCIgeT0iNTEwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODQiIHg9IjE1MCIgeT0iNTcwIiBzdHJva2U9InJnYmEoMjA4LCAyMTcsIDIwOSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjIxMCIgeT0iMzAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NiIgeD0iMjEwIiB5PSI5MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgyIiB4PSIyMTAiIHk9IjE1MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIiBzdHJva2Utd2lkdGg9IjMiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjIxMCIgeT0iMjEwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODIiIHg9IjIxMCIgeT0iMjcwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiIHN0cm9rZS13aWR0aD0iMyI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NSIgeD0iMjEwIiB5PSIzMzAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MiIgeD0iMjEwIiB5PSIzOTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSIgc3Ryb2tlLXdpZHRoPSIzIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSIyMTAiIHk9IjQ1MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg0IiB4PSIyMTAiIHk9IjUxMCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSIyMTAiIHk9IjU3MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg0IiB4PSIyNzAiIHk9IjMwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODQiIHg9IjI3MCIgeT0iOTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MiIgeD0iMjcwIiB5PSIxNTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSIgc3Ryb2tlLXdpZHRoPSIzIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg1IiB4PSIyNzAiIHk9IjIxMCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSIyNzAiIHk9IjI3MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg1IiB4PSIyNzAiIHk9IjMzMCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSIyNzAiIHk9IjM5MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSIyNzAiIHk9IjQ1MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSIyNzAiIHk9IjUxMCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg0IiB4PSIyNzAiIHk9IjU3MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSIzMzAiIHk9IjMwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODQiIHg9IjMzMCIgeT0iOTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iMzMwIiB5PSIxNTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NiIgeD0iMzMwIiB5PSIyMTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NiIgeD0iMzMwIiB5PSIyNzAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NCIgeD0iMzMwIiB5PSIzMzAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NiIgeD0iMzMwIiB5PSIzOTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MyIgeD0iMzMwIiB5PSI0NTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NSIgeD0iMzMwIiB5PSI1MTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMzMwIiB5PSI1NzAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NSIgeD0iMzkwIiB5PSIzMCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSIzOTAiIHk9IjkwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjM5MCIgeT0iMTUwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODEiIHg9IjM5MCIgeT0iMjEwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODYiIHg9IjM5MCIgeT0iMjcwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODUiIHg9IjM5MCIgeT0iMzMwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODIiIHg9IjM5MCIgeT0iMzkwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiIHN0cm9rZS13aWR0aD0iMyI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMzkwIiB5PSI0NTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NiIgeD0iMzkwIiB5PSI1MTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iMzkwIiB5PSI1NzAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iNDUwIiB5PSIzMCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgyIiB4PSI0NTAiIHk9IjkwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiIHN0cm9rZS13aWR0aD0iMyI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NiIgeD0iNDUwIiB5PSIxNTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MiIgeD0iNDUwIiB5PSIyMTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSIgc3Ryb2tlLXdpZHRoPSIzIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSI0NTAiIHk9IjI3MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI0NTAiIHk9IjMzMCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI0NTAiIHk9IjM5MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSI0NTAiIHk9IjQ1MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI0NTAiIHk9IjUxMCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSI0NTAiIHk9IjU3MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSI1MTAiIHk9IjMwIiBzdHJva2U9InJnYmEoMjA4LCAyMTcsIDIwOSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODQiIHg9IjUxMCIgeT0iOTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NCIgeD0iNTEwIiB5PSIxNTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NiIgeD0iNTEwIiB5PSIyMTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NiIgeD0iNTEwIiB5PSIyNzAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iNTEwIiB5PSIzMzAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NCIgeD0iNTEwIiB5PSIzOTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iNTEwIiB5PSI0NTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MiIgeD0iNTEwIiB5PSI1MTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSIgc3Ryb2tlLXdpZHRoPSIzIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSI1MTAiIHk9IjU3MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSI1NzAiIHk9IjMwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODYiIHg9IjU3MCIgeT0iOTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iNTcwIiB5PSIxNTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NiIgeD0iNTcwIiB5PSIyMTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MSIgeD0iNTcwIiB5PSIyNzAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4NCIgeD0iNTcwIiB5PSIzMzAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSI+PC91c2U+PHVzZSB4bGluazpocmVmPSIjU3ZnanNQYXRoMTA4MiIgeD0iNTcwIiB5PSIzOTAiIHN0cm9rZT0icmdiYSgyMDgsIDIxNywgMjA5LCAxKSIgc3Ryb2tlLXdpZHRoPSIzIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSI1NzAiIHk9IjQ1MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI1NzAiIHk9IjUxMCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg1IiB4PSI1NzAiIHk9IjU3MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI2MzAiIHk9IjMwIiBzdHJva2U9InJnYmEoMTYsIDUwLCA4MywgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODIiIHg9IjYzMCIgeT0iOTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSIgc3Ryb2tlLXdpZHRoPSIzIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI2MzAiIHk9IjE1MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI2MzAiIHk9IjIxMCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSI2MzAiIHk9IjI3MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSI2MzAiIHk9IjMzMCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI2MzAiIHk9IjM5MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI2MzAiIHk9IjQ1MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI2MzAiIHk9IjUxMCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI2MzAiIHk9IjU3MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg1IiB4PSI2OTAiIHk9IjMwIiBzdHJva2U9InJnYmEoMjA4LCAyMTcsIDIwOSwgMSkiPjwvdXNlPjx1c2UgeGxpbms6aHJlZj0iI1N2Z2pzUGF0aDEwODIiIHg9IjY5MCIgeT0iOTAiIHN0cm9rZT0icmdiYSgxNiwgNTAsIDgzLCAxKSIgc3Ryb2tlLXdpZHRoPSIzIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg1IiB4PSI2OTAiIHk9IjE1MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg1IiB4PSI2OTAiIHk9IjIxMCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI2OTAiIHk9IjI3MCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg1IiB4PSI2OTAiIHk9IjMzMCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgzIiB4PSI2OTAiIHk9IjM5MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg1IiB4PSI2OTAiIHk9IjQ1MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDgxIiB4PSI2OTAiIHk9IjUxMCIgc3Ryb2tlPSJyZ2JhKDIwOCwgMjE3LCAyMDksIDEpIj48L3VzZT48dXNlIHhsaW5rOmhyZWY9IiNTdmdqc1BhdGgxMDg2IiB4PSI2OTAiIHk9IjU3MCIgc3Ryb2tlPSJyZ2JhKDE2LCA1MCwgODMsIDEpIj48L3VzZT48L3N5bWJvbD48L3N2Zz4=",E9e=e=>{const{globalState:{memoListView:t,markMemoId:n,manifest:r,editMemoId:o},dailyNotesState:{app:i,settings:a}}=D.useContext(ct),{thinos:s}=e,l=Y.useRef(null),u=Y.useRef(null),[d,h]=Y.useState(!1),[p,m]=D.useState({}),[b,v]=D.useState(i?.loadLocalStorage("dayMarkRange")||"day"),[y,S]=Y.useState(a?.MomentsIcon);D.useEffect(()=>{if(!a?.MomentsIcon||!i)return;const C=i.vault.adapter.getResourcePath(N.normalizePath(a.MomentsIcon));C&&!a?.MomentsIcon.startsWith("http")?S(C):S(a?.MomentsIcon)},[a?.MomentsIcon,i]),D.useEffect(()=>{a?.showDayMark&&m(sg(s,i?.loadLocalStorage("dayMarkRange")||"day"))},[s]),D.useEffect(()=>{l.current.closest(".workspace-window")&&h(!0)},[l.current]),D.useEffect(()=>{n&&h(!0)},[n]),D.useEffect(()=>{o?(h(!0),setTimeout(()=>{i.workspace.trigger("focus-on-textarea")},200)):h(!1)},[o]),D.useEffect(()=>{u.current&&(!d&&N.setIcon(u.current,"camera"),d&&N.setIcon(u.current,"camera-off"))},[u.current,d]);const x=D.useCallback(()=>{i.setting.open(),i.setting.openTabById(r.id||"obsidian-memos")},[i]);return w.jsxs("div",{ref:l,className:tn("moments-view",d?"show-editor":""),children:[w.jsxs("div",{className:"moments-view-background-wrapper",children:[w.jsx(C9e,{}),w.jsx("div",{ref:u,className:"moments-show-editor-btn",onClick:()=>{o&&d||((d||o)&&h(!d),!d&&!o&&new lE(i).open())}}),w.jsxs("div",{className:"moments-view-background-overlay",children:[w.jsxs("div",{className:"moments-view-user-info",children:[w.jsx("div",{className:"moments-view-user-name",children:a?.UserName}),w.jsx(k9e,{userIcon:y})]}),w.jsx("div",{className:"moments-view-user-idea",children:a.MomentsQuote||" "})]})]}),a?.showDayMark?p&&Object.keys(p).length>0&&Object.keys(p).map((C,k)=>w.jsx(cE,{type:"list",thinos:p[C],dayMark:C,dayMarkRange:b,thinoWrapper:M=>w.jsx(c5,{thino:M.thino,handleOpenSettings:x},M.thino.createdAt+k)},C)):s.map((C,k)=>w.jsx(c5,{thino:C,handleOpenSettings:x},C.createdAt+k))]})},C9e=()=>{const{dailyNotesState:{app:e,view:t,settings:n}}=D.useContext(ct),[r,o]=D.useState(n?.MomentsBackgroundImage||l0);return D.useEffect(()=>{if(!n?.MomentsBackgroundImage||!e){o(document.body.hasClass("theme-dark")?cC:l0);return}const i=e.vault.adapter.getResourcePath(N.normalizePath(n.MomentsBackgroundImage));i&&!n?.MomentsBackgroundImage.startsWith("http")?o(i):o(n?.MomentsBackgroundImage)},[n?.MomentsBackgroundImage,e]),D.useEffect(()=>{t&&t.registerEvent(t.app.workspace.on("css-change",()=>{o(document.body.hasClass("theme-dark")&&!n?.MomentsBackgroundImage?cC:!document.body.hasClass("theme-dark")&&!n?.MomentsBackgroundImage?l0:n?.MomentsBackgroundImage)}))},[t]),w.jsx("div",{className:"moments-view-background",style:{backgroundImage:`url("${r}")`}})},M9e=e=>{const{icon:t}=e,n=D.useCallback(()=>{app.setting.open(),app.setting.openTabById(manifest.id||"obsidian-memos")},[]);return w.jsx("div",{className:"thino-moment-icon",ref:r=>{if(t){r?.empty();return}t||r&&N.setIcon(r,"Memos")},style:{backgroundImage:`url("${t}")`},onClick:n})},c5=e=>{const{dailyNotesState:{settings:t,app:n}}=D.useContext(ct),r=D.useRef(null),o=D.useRef(null),{thino:i}=e,[a,s]=D.useState("");return D.useEffect(()=>{if(!t?.MomentsIcon||!n)return;const l=n.vault.adapter.getResourcePath(N.normalizePath(t.MomentsIcon));l&&!t?.MomentsIcon.startsWith("http")?s(l):s(t?.MomentsIcon)},[t?.MomentsIcon,n]),D.useEffect(()=>{r.current&&N.setIcon(r.current,"more-horizontal")},[r.current]),w.jsxs("div",{className:"thino-moment-wrapper",children:[w.jsx(M9e,{icon:a}),w.jsxs("div",{ref:o,className:"thino-moment-container",children:[w.jsx("div",{className:"thino-moment-user-name",children:t?.UserName}),w.jsx("div",{className:"thino-moment-user-content",children:w.jsx(vo,{memo:i})}),t?.enableReferenceLinksGroup&&w.jsx(i7,{memoId:i.id})]})]})},D9e='<svg xmlns="http://www.w3.org/2000/svg" data-name="Layer 1" width="1146.31828" height="801.00361" viewBox="0 0 1146.31828 801.00361" xmlns:xlink="http://www.w3.org/1999/xlink"><path d="M1050.69918,514.5082a456.24913,456.24913,0,0,1-37.38013-261.87c3.6001-23.1,9.44006-46.85,24.43018-64.79,14.38989-17.23,39.34985-27.37,60.0299-19.29-13.56994-29.61-47.76-46.5-80.59-47.33-34.09-.86-66.92,12.5-97.25,28.1-30.33,15.6-59.65,33.81006-92.21,43.99-53.5,16.72-111.91,10.34-165.5-6.09-53.58-16.44-103.62-42.47-154.62-65.71-51.01-23.24-104.17-44.03-160.01-48.91-55.84-4.87-115.25,7.89-157.24,45.01s-61.87,101.28-38.27,152.11c14.25,30.7,42.22,54.32,52.04,86.7,12.32,40.65-7.08,83.96-30.41,119.45-23.34,35.49-51.8,69.58-60.47,111.16-8.01,38.38,2.72,78.02,24.05,111.38a197.34468,197.34468,0,0,0,35.74,41.61c43.09,37.91,98.77,58.15,154.17,73.13,200.27,54.17,416.13,49.29,613.75-13.88,34.99-11.18,69.95-24.43,99.32-46.48,19.16-14.38,35.83-33.02,46.39-54.35a114.10574,114.10574,0,0,0,11.13-36.18005C1104.43917,610.17819,1072.9692,562.05819,1050.69918,514.5082Z" transform="translate(-26.84086 -49.49819)" fill="#6c63ff"/><g opacity="0.17"><path d="M890.75032,246.45145c9.64171-4.20394-9.91163-6.65119-32.09585-7.45582s-49.02061-.76011-63.19756-3.04875c-13.71114-2.21343-12.7009-6.14907-13.85427-9.71489s-6.42446-7.222-27.81928-8.0147c-26.6607-.98774-70.62581,2.81434-90.75171.53173-18.78121-2.13011-7.61723-8.81182-35.00344-9.06755-15.63837-.146-35.7849,2.05682-53.18577,2.58844-16.33647.49909-28.42216-.53441-36.90357-1.924s-14.38875-3.15126-23.93413-4.37864c-25.06068-3.2224-74.09133-2.13925-117.853,1.99071s-81.27344,10.89816-102.42889,17.60175-27.00029,13.30376-22.07239,18.90071c3.14674,3.574,11.19915,6.91585,30.73235,8.352,36.53555,2.68621,101.58387-1.9375,139.33713.50645,21.0415,1.36213,30.3764,4.73924,48.83812,6.58716,19.83407,1.98528,48.86935,2.09051,77.39656,2.04341,59.39721-.09807,120.3137-.70829,182.42994-1.82747,25.94486-.46745,53.13-1.0752,80.73761-3.30289s55.76623-6.52591,61.59076-10.5553" transform="translate(-26.84086 -49.49819)" fill="#fff"/></g><path d="M1099.25911,172.04818c-.46-1.18-.96-2.35-1.48-3.49.84.33,1.68006.69,2.51,1.08Z" transform="translate(-26.84086 -49.49819)" fill="#6c63ff"/><path d="M648.74482,314.5843c-7.66935-12.68445-16.75721-26.22767-30.98955-30.36953-16.482-4.7965-33.41319,4.73193-47.77473,14.13453a1392.15692,1392.15692,0,0,0-123.89338,91.28311l.04331.49239q46.22556-3.18781,92.451-6.37555c22.26532-1.53546,45.29557-3.2827,64.97195-13.8156,7.46652-3.99683,14.74475-9.33579,23.20555-9.70782,10.51175-.46217,19.67733,6.87923,26.8802,14.54931,42.60732,45.371,54.937,114.7541,102.73817,154.61592A1516.99458,1516.99458,0,0,0,648.74482,314.5843Z" transform="translate(-26.84086 -49.49819)" fill="#f2f2f2"/><path d="M910.64576,699.4127c-4.71168-5.94958-6.63691-7.343-11.28457-13.34761Q842.5968,612.64872,792.65327,534.27272q-33.92353-53.23005-64.48275-108.50439-14.54863-26.27808-28.29961-52.96872-10.67043-20.6952-20.8646-41.63793c-1.94357-3.98781-3.83209-7.99393-5.71122-12.00922-4.42788-9.44232-8.7734-18.93047-13.43942-28.24449-5.31687-10.61571-11.78905-21.74485-21.55259-28.877a29.4049,29.4049,0,0,0-15.31855-5.89457c-7.948-.51337-15.28185,2.76854-22.17569,6.35294-50.43858,26.301-97.65921,59.27589-140.36959,96.79771A730.77781,730.77781,0,0,0,346.39748,485.87843c-1.008,1.43927-3.39163.06418-2.37419-1.38422q6.00935-8.49818,12.25681-16.81288A734.81742,734.81742,0,0,1,543.87972,292.6956q18.24825-11.82579,37.18269-22.54245c6.36206-3.60275,12.75188-7.15967,19.25136-10.49653,6.37147-3.27274,13.13684-6.21547,20.41563-6.32547,24.77011-.385,37.5954,27.667,46.40506,46.54248q4.15283,8.9106,8.40636,17.76626,16.07481,33.62106,33.38729,66.628,10.68453,20.379,21.83683,40.51955,34.7071,62.71816,73.77854,122.897c34.5059,53.1429,68.73651,100.08874,108.04586,149.78473C913.67124,698.84433,911.73706,700.80615,910.64576,699.4127Z" transform="translate(-26.84086 -49.49819)" fill="#e4e4e4"/><path d="M457.9912,345.4352c-1.43911-1.60428-2.86926-3.20856-4.31777-4.81284-11.42244-12.63259-23.6788-25.11847-39.3644-32.36067a57.11021,57.11021,0,0,0-23.92678-5.54622c-8.56213.02753-16.93178,2.27348-24.84307,5.41792-3.74034,1.49428-7.39831,3.19021-11.00078,4.99614-4.11634,2.07182-8.15927,4.28118-12.1834,6.50883q-11.33112,6.27044-22.36816,13.0909-21.9606,13.5722-42.54565,29.21623-10.67111,8.11311-20.90175,16.75788-9.51557,8.03052-18.64618,16.492c-1.30168,1.20091-3.24526-.74255-1.94358-1.94347,1.60428-1.49428,3.22692-2.97938,4.84955-4.44612q6.87549-6.21547,13.9712-12.19258,12.93921-10.91827,26.54851-20.99312,21.16295-15.67614,43.78289-29.2254,11.3036-6.76547,22.91829-12.9626c2.33793-1.24674,4.70317-2.466,7.09571-3.6211a113.11435,113.11435,0,0,1,16.86778-6.86631,60.00626,60.00626,0,0,1,25.476-2.50266,66.32725,66.32725,0,0,1,23.50512,8.1314c15.40091,8.60812,27.34573,21.919,38.97005,34.90916C461.10844,344.80265,459.17382,346.75529,457.9912,345.4352Z" transform="translate(-26.84086 -49.49819)" fill="#e4e4e4"/><path d="M773.55166,476.34216l36.90462-13.498,18.32327-6.70182c5.96758-2.18267,11.92082-4.66747,18.08989-6.23037a28.53868,28.53868,0,0,1,16.37355.20862,37.73731,37.73731,0,0,1,12.771,7.91667,103.63871,103.63871,0,0,1,10.47488,11.18642c3.98932,4.79426,7.9197,9.63878,11.86772,14.46706q24.44135,29.89093,48.56306,60.04134,24.12118,30.14991,47.91981,60.556,23.85681,30.48042,47.38548,61.21573,2.8823,3.76519,5.75967,7.53415c1.0598,1.38809,3.44948.01962,2.37471-1.38807q-23.70225-31.04441-47.73491-61.83464-24.09177-30.86383-48.51646-61.46586-24.42423-30.60142-49.17854-60.93744-6.167-7.5576-12.35444-15.09858c-3.47954-4.24072-6.91984-8.52718-10.73629-12.47426-7.00538-7.24516-15.75772-13.64794-26.23437-13.82167-6.15972-.10214-12.121,1.85248-17.844,3.92288-6.16967,2.232-12.32455,4.50571-18.48632,6.7594L782.11123,470.2921l-9.29068,3.39811c-1.64874.603-.9365,3.26189.73111,2.65195Z" transform="translate(-26.84086 -49.49819)" fill="#e4e4e4"/><path d="M409.45248,324.15733c-18.75411-9.63866-42.77137-7.75087-60.00507,4.29119A855.84532,855.84532,0,0,1,446.818,351.17434C433.53537,343.3904,423.14521,331.19475,409.45248,324.15733Z" transform="translate(-26.84086 -49.49819)" fill="#f2f2f2"/><path d="M349.26282,328.41534,345.6524,331.35c1.22123-1.02713,2.4908-1.99013,3.795-2.90144C349.3858,328.43789,349.32442,328.426,349.26282,328.41534Z" transform="translate(-26.84086 -49.49819)" fill="#f2f2f2"/><path d="M874.62436,476.477c-3.63279-4.42206-7.56046-9.05222-12.99421-10.84836l-5.07308.20009a575.43629,575.43629,0,0,0,153.26729,175.22056Q942.22437,558.76317,874.62436,476.477Z" transform="translate(-26.84086 -49.49819)" fill="#f2f2f2"/><path d="M1086.66915,698.4482c-10.56006,21.33-27.23,39.97-46.39,54.35-29.37,22.05-64.33,35.3-99.32,46.48-197.62,63.17-413.48,68.05-613.75,13.88-55.4-14.98-111.08-35.22-154.17-73.13a197.34468,197.34468,0,0,1-35.74-41.61c57.35-31.52,126.86-43.4,193.19-41.95,95.09,2.08,187.96,27.46,282.16,40.59a1102.669,1102.669,0,0,0,334.04-4.6c38.31994-6.43,77.98-14.84,115.49-4.66A95.14954,95.14954,0,0,1,1086.66915,698.4482Z" transform="translate(-26.84086 -49.49819)" fill="#3f3d56"/><circle cx="179.31828" cy="51" r="51" fill="#ccc"/><path d="M362.30892,97.84042C348.81185,83.6816,333.13643,70.765,314.57961,63.93948a76.71521,76.71521,0,0,0-15.98633-4.01734c-.04388-.006-.08545.00287-.12909-.00067a2.35576,2.35576,0,0,0-.26965-.05292,61.5388,61.5388,0,0,0-22.84131,1.379,63.10735,63.10735,0,0,0-10.63519,3.7049,93.00467,93.00467,0,0,0-9.97943,5.65557A64.90832,64.90832,0,0,1,232.6863,78.8348a74.1877,74.1877,0,0,1-11.84406,1.16248c-3.44714.06915-6.698.1889-9.964,1.43426a23.91573,23.91573,0,0,0-14.56494,15.77051,1.55078,1.55078,0,0,0,.68933,1.694c.88349.63275,1.74476,1.35065,2.673,1.91437a8.33922,8.33922,0,0,0,2.611.71209q2.21366.46711,4.43292.90693,8.17584,1.61992,16.41962,2.86792,16.681,2.5252,33.54217,3.55755a373.48132,373.48132,0,0,0,67.51026-2.029A374.77144,374.77144,0,0,0,361.647,100.3475,1.5139,1.5139,0,0,0,362.30892,97.84042Z" transform="translate(-26.84086 -49.49819)" fill="#f0f0f0"/><path d="M208.57961,131.93948a76.71521,76.71521,0,0,0-15.98633-4.01734c-.04388-.006-.08545.00287-.12909-.00067a2.35576,2.35576,0,0,0-.26965-.05292,61.5388,61.5388,0,0,0-22.84131,1.379,63.10735,63.10735,0,0,0-10.63519,3.7049,93.00467,93.00467,0,0,0-9.97943,5.65557,64.90832,64.90832,0,0,1-22.05231,8.22681,74.1877,74.1877,0,0,1-11.84406,1.16248c-3.44714.06915-6.698.1889-9.964,1.43426a23.91573,23.91573,0,0,0-14.56494,15.77051,1.55078,1.55078,0,0,0,.68933,1.694c.88349.63275,1.74476,1.35065,2.673,1.91437a8.33922,8.33922,0,0,0,2.611.71209q2.21366.46712,4.43292.90693,8.17584,1.61992,16.41962,2.86792,16.681,2.5252,33.54217,3.55755a373.48132,373.48132,0,0,0,67.51026-2.029A374.77144,374.77144,0,0,0,255.647,168.3475a1.5139,1.5139,0,0,0,.66193-2.50708C242.81185,151.6816,227.13643,138.765,208.57961,131.93948Z" transform="translate(-26.84086 -49.49819)" fill="#f0f0f0"/><polygon points="1047.411 588.142 1074.576 567.518 1087.816 580.759 1043.563 611.042 1047.411 588.142" fill="#2f2e41"/><path d="M1048.91635,694.42781H955.99269l3.25907-10.55987,0,0c20.1993-7.31227,8.85333-23.02957,28.06751-32.63666,46.9968-23.4984,65.19118-93.62006,58.30932-121.33935l30.798-1.30221S1118.95877,649.37476,1048.91635,694.42781Z" transform="translate(-26.84086 -49.49819)" fill="#2f2e41"/><path d="M1128.24653,644.78888a15.61893,15.61893,0,0,1-20.18272.37759l-.0604-.04961-.00207-.07767a14.96483,14.96483,0,0,0-.6-3.81936,10.69077,10.69077,0,0,1-.38818,2.64366l-.07784.28991-.20873-.21549c-.18027-.18589-.35474-.37472-.51859-.561a15.75088,15.75088,0,0,1-2.399-3.63269,45.91623,45.91623,0,0,0-12.74-15.87972,22.29237,22.29237,0,0,1-2.6727-2.57172,22.03415,22.03415,0,0,1,27.66955-33.56911l.13767.0806-.07148.1425a11.47756,11.47756,0,0,1-2.04788,2.954,14.96829,14.96829,0,0,0,3.15395-2.27865l.10006-.09436.11337.07818a22.12793,22.12793,0,0,1,4.0294,3.5867l.12844.14726a9.83643,9.83643,0,0,0,7.28375,3.36123,15.614,15.614,0,0,1,15.11947,18.29291l-.01769.10315-.10034.0304a13.39866,13.39866,0,0,1-5.45694.68088,15.22208,15.22208,0,0,0,4.86061,1.2174l.21654.01718-.06874.20619a15.6035,15.6035,0,0,1-4.50339,6.79l-.05928.05187-.06294.05509a15.3329,15.3329,0,0,0-5.297,10.64272A15.73345,15.73345,0,0,1,1128.24653,644.78888Z" transform="translate(-26.84086 -49.49819)" fill="#3f3d56"/><path d="M1131.089,639.76934a15.57418,15.57418,0,0,1-.1756,1.67894,15.78521,15.78521,0,0,0,2.53772-7.82047c.02071-.42637.06546-.8511.12549-1.27393A14.8141,14.8141,0,0,0,1131.089,639.76934Z" transform="translate(-26.84086 -49.49819)" opacity="0.15"/><path d="M1136.00331,620.789a15.19815,15.19815,0,0,0,3.88418,1.09822,15.63,15.63,0,0,0,1.42322-1.73647A13.24363,13.24363,0,0,1,1136.00331,620.789Z" transform="translate(-26.84086 -49.49819)" opacity="0.15"/><path d="M1141.72736,615.66082a15.70907,15.70907,0,0,1-.11112,4.05194,15.52908,15.52908,0,0,0,1.75758-3.62455l.06874-.2062-.21655-.01718A15.09472,15.09472,0,0,1,1141.72736,615.66082Z" transform="translate(-26.84086 -49.49819)" opacity="0.15"/><path d="M1140.28241,600.83967a15.65079,15.65079,0,0,0-11.46149-5.29958,9.83649,9.83649,0,0,1-7.28378-3.36124l-.12843-.14726a22.12785,22.12785,0,0,0-4.02939-3.58669l-.11338-.07817-.10005.09434a14.9676,14.9676,0,0,1-3.154,2.27865,11.47832,11.47832,0,0,0,2.04794-2.954l.07146-.1425-.13766-.08059a22.01777,22.01777,0,0,0-32.62113,14.2542,22.02182,22.02182,0,0,1,30.259-8.11268l.13765.08059-.07145.1425a11.47814,11.47814,0,0,1-2.04794,2.954,14.96754,14.96754,0,0,0,3.154-2.27865l.10006-.09434.11338.07817a22.12857,22.12857,0,0,1,4.02939,3.5867l.12843.14725a9.83643,9.83643,0,0,0,7.28377,3.36124,15.61675,15.61675,0,0,1,15.10347,12.83488,18.92714,18.92714,0,0,0,2.26005-.55l.10034-.03039.01776-.10314A15.554,15.554,0,0,0,1140.28241,600.83967Z" transform="translate(-26.84086 -49.49819)" opacity="0.15"/><path d="M1173.15913,536.54065a50.29141,50.29141,0,0,1-42.007,49.59965l-.2484.04053-.19219-.16016a48.18565,48.18565,0,0,0-10.51008-6.67159,34.42316,34.42316,0,0,1,5.5662,6.56047l.53537.80469-.96485.04641c-.8328.04053-1.66038.0608-2.45919.0608a50.71554,50.71554,0,0,1-13.88445-1.92513c-20.51748-5.83748-42.55022-6.83567-65.48571-2.96711a71.77856,71.77856,0,0,1-11.90147.993A70.94787,70.94787,0,0,1,1009.287,444.63723l.48765-.16146.19251.47589a36.95659,36.95659,0,0,1,2.787,11.23306,48.19635,48.19635,0,0,0,1.19789-12.47116l-.01536-.44255.43013-.10786a71.24939,71.24939,0,0,1,17.24051-2.1147l.62918.00262a31.67228,31.67228,0,0,0,23.616-10.46237,50.27568,50.27568,0,0,1,76.38016,2.34611l.2118.26213-.1399.30723c-2.93769,6.47484-6.13818,11.19189-9.95836,14.64143a49.01343,49.01343,0,0,0,13.27978-9.16282l.502-.487.35234.60466A50.24214,50.24214,0,0,1,1143.32,464.4278l-.00065.25363c-.00065.08956-.00065.17977-.00065.26932,0,13.61317,5.26419,26.51577,14.46689,35.43934A50.66021,50.66021,0,0,1,1173.15913,536.54065Z" transform="translate(-26.84086 -49.49819)" fill="#3f3d56"/><g opacity="0.15"><path d="M1111.68868,417.71713a35.519,35.519,0,0,1-6.33509,7.77159,48.88929,48.88929,0,0,0,9.89823-6.1865Q1113.50228,418.44038,1111.68868,417.71713Z" transform="translate(-26.84086 -49.49819)"/><path d="M1140.79293,477.73323a50.48191,50.48191,0,0,1,7.22981,8.80775,51.39288,51.39288,0,0,1-4.70405-21.59022c0-.08957,0-.17978.00065-.26932l.00064-.25364a50.24245,50.24245,0,0,0-6.83956-25.32735l-.35235-.60468-.50207.487a49.12616,49.12616,0,0,1-9.17043,6.983A48.97185,48.97185,0,0,0,1140.79293,477.73323Z" transform="translate(-26.84086 -49.49819)"/><path d="M1126.32733,441.77093l-.00065.25364c-.00064.08954-.00064.17975-.00064.26931,0,.49355.00894.98585.02272,1.47739a52.3648,52.3648,0,0,0,5.95587-10.26709l.13985-.30725-.21176-.26212a50.68811,50.68811,0,0,0-9.096-8.79733A50.35621,50.35621,0,0,1,1126.32733,441.77093Z" transform="translate(-26.84086 -49.49819)"/><path d="M1157.78559,500.3901a45.45934,45.45934,0,0,1-6.40838-7.79666,50.2297,50.2297,0,0,1-37.21772,70.89l-.24841.04054-.19217-.16016a48.188,48.188,0,0,0-10.5101-6.67159,34.42262,34.42262,0,0,1,5.56617,6.56046l.5354.80471-.96482.0464c-.83286.04054-1.66041.0608-2.4592.0608a50.71549,50.71549,0,0,1-13.88448-1.92514c-20.51749-5.83747-42.55022-6.83566-65.4857-2.9671a71.7793,71.7793,0,0,1-11.90145.993,70.62389,70.62389,0,0,1-47.12-17.969,71.01118,71.01118,0,0,0,64.1127,40.6259,71.77947,71.77947,0,0,0,11.90145-.99294c22.93547-3.86857,44.96821-2.87037,65.4857,2.96709a50.71543,50.71543,0,0,0,13.88448,1.92514c.79878,0,1.62634-.02026,2.45919-.0608l.96483-.0464-.5354-.80471a34.42263,34.42263,0,0,0-5.56618-6.56045,48.18774,48.18774,0,0,1,10.51011,6.67159l.19217.16016.24841-.04055a50.25392,50.25392,0,0,0,26.63344-85.75019Z" transform="translate(-26.84086 -49.49819)"/></g><polygon points="134.035 560.973 97.223 533.025 79.28 550.968 139.25 592.007 134.035 560.973" fill="#2f2e41"/><path d="M195.21,687.42781h125.9266L316.72,673.11747l0,0c-27.37332-9.9093-11.99769-31.20879-38.036-44.228-63.68827-31.84414-88.3446-126.87035-79.01856-164.43447l-41.73625-1.76471S100.29113,626.37364,195.21,687.42781Z" transform="translate(-26.84086 -49.49819)" fill="#2f2e41"/><path d="M80.55365,605.25219a20.7786,20.7786,0,0,0-7.17833-14.42261c-.0283-.02489-.05681-.05-.08529-.07465l-.08034-.0703a21.14539,21.14539,0,0,1-6.10283-9.20148l-.09315-.27942.29345-.02329a20.6283,20.6283,0,0,0,6.58691-1.64977,18.15726,18.15726,0,0,1-7.395-.9227l-.136-.0412-.024-.13979a21.15953,21.15953,0,0,1,20.48932-24.78985,13.32987,13.32987,0,0,0,9.87066-4.555l.17406-.19956a29.9868,29.9868,0,0,1,5.46049-4.86055l.15364-.106.13559.12786a20.2845,20.2845,0,0,0,4.27411,3.088,15.554,15.554,0,0,1-2.77519-4.00312l-.09688-.19312.18657-.10923A29.85984,29.85984,0,0,1,141.70818,588.318a30.209,30.209,0,0,1-3.62195,3.48511,62.224,62.224,0,0,0-17.26483,21.51959,21.34447,21.34447,0,0,1-3.251,4.92289c-.222.25244-.45848.50834-.70277.76026l-.28286.292-.10549-.39287a14.48742,14.48742,0,0,1-.526-3.58259,20.27961,20.27961,0,0,0-.813,5.17585l-.00281.10525-.08185.06724a21.15037,21.15037,0,0,1-34.50192-15.41853Z" transform="translate(-26.84086 -49.49819)" fill="#3f3d56"/><path d="M83.85266,613.35673a21.10374,21.10374,0,0,0,.238,2.27524,21.39156,21.39156,0,0,1-3.439-10.598c-.02806-.57781-.08871-1.15339-.17006-1.72639A20.07562,20.07562,0,0,1,83.85266,613.35673Z" transform="translate(-26.84086 -49.49819)" opacity="0.15"/><path d="M77.193,587.63524a20.59681,20.59681,0,0,1-5.2637,1.48826,21.18029,21.18029,0,0,1-1.92868-2.3532A17.94731,17.94731,0,0,0,77.193,587.63524Z" transform="translate(-26.84086 -49.49819)" opacity="0.15"/><path d="M69.436,580.68579a21.28893,21.28893,0,0,0,.1506,5.491,21.04389,21.04389,0,0,1-2.3818-4.91186l-.09316-.27943.29346-.02329A20.4517,20.4517,0,0,0,69.436,580.68579Z" transform="translate(-26.84086 -49.49819)" opacity="0.15"/><path d="M71.39415,560.60073a21.20931,21.20931,0,0,1,15.53218-7.18179,13.33,13.33,0,0,0,9.87069-4.555l.174-.19955a29.98717,29.98717,0,0,1,5.46048-4.86056l.15364-.10593.13559.12785a20.28377,20.28377,0,0,0,4.27415,3.08794,15.55474,15.55474,0,0,1-2.77529-4.00312l-.09683-.19312.18655-.10921A29.83764,29.83764,0,0,1,148.51627,561.925a29.84315,29.84315,0,0,0-41.00585-10.994l-.18655.10921.09683.19311a15.5548,15.5548,0,0,0,2.77529,4.00313,20.28412,20.28412,0,0,1-4.27415-3.08794l-.13559-.12786-.15364.10594a29.98711,29.98711,0,0,0-5.46048,4.86055l-.174.19956a13.33,13.33,0,0,1-9.87069,4.555A21.16316,21.16316,0,0,0,69.65975,579.135a25.64845,25.64845,0,0,1-3.06273-.74529l-.136-.04118-.02407-.13978A21.07824,21.07824,0,0,1,71.39415,560.60073Z" transform="translate(-26.84086 -49.49819)" opacity="0.15"/><path d="M47.67454,424.47529c12.47114-12.09289,19.605-29.578,19.605-48.026,0-.12136,0-.24361-.00089-.365l-.00088-.34372a68.08611,68.08611,0,0,1,9.26876-34.32266l.47748-.81942.68034.66a66.42122,66.42122,0,0,0,17.99625,12.41711c-5.177-4.67469-9.51414-11.06706-13.4952-19.8415l-.18957-.41636.287-.35523a68.13168,68.13168,0,0,1,103.50749-3.17935,42.9211,42.9211,0,0,0,32.00348,14.1782l.85264-.00355a96.55467,96.55467,0,0,1,23.36369,2.86576l.58289.14617-.02081.59973a65.31307,65.31307,0,0,0,1.62334,16.90044,50.08227,50.08227,0,0,1,3.77686-15.22262l.26089-.64491.66085.21881a96.14585,96.14585,0,0,1-30.24771,187.39848A97.27192,97.27192,0,0,1,202.538,534.974c-31.0813-5.24253-60.93923-3.88982-88.74374,4.02092a68.72787,68.72787,0,0,1-18.81567,2.60886c-1.08252,0-2.204-.02747-3.33261-.08239l-1.30753-.0629L91.064,540.368a46.64968,46.64968,0,0,1,7.5431-8.8905,65.29981,65.29981,0,0,0-14.24286,9.0411l-.26045.217-.33662-.05492A68.10219,68.10219,0,0,1,47.67454,424.47529Z" transform="translate(-26.84086 -49.49819)" fill="#3f3d56"/><g opacity="0.15"><path d="M110.14328,312.44a48.13438,48.13438,0,0,0,8.58508,10.53176,66.25283,66.25283,0,0,1-13.4137-8.38371Q107.68556,313.42016,110.14328,312.44Z" transform="translate(-26.84086 -49.49819)"/><path d="M70.70231,393.77157a68.411,68.411,0,0,0-9.79756,11.93592,69.64577,69.64577,0,0,0,6.37475-29.25825c0-.12137,0-.24362-.00088-.365l-.00087-.34372a68.08661,68.08661,0,0,1,9.26871-34.32266l.4775-.81944.68039.66a66.5738,66.5738,0,0,0,12.42741,9.46305C88.97194,367.31049,82.046,382.77189,70.70231,393.77157Z" transform="translate(-26.84086 -49.49819)"/><path d="M90.30555,345.03683l.00087.34372c.00088.12134.00088.24359.00088.365,0,.66884-.01212,1.336-.0308,2.0021A70.9624,70.9624,0,0,1,82.20534,333.834l-.18953-.41637.287-.35522a68.69044,68.69044,0,0,1,12.32659-11.92181A68.24086,68.24086,0,0,0,90.30555,345.03683Z" transform="translate(-26.84086 -49.49819)"/><path d="M47.67451,424.4753a61.60525,61.60525,0,0,0,8.6844-10.56575,68.06938,68.06938,0,0,0,50.436,96.06741l.33664.05494.26042-.217a65.30253,65.30253,0,0,1,14.24289-9.04108,46.64767,46.64767,0,0,0-7.54306,8.89047l-.72556,1.09052,1.3075.06287c1.12865.05494,2.25012.08239,3.33261.08239a68.72762,68.72762,0,0,0,18.81572-2.60886c27.80451-7.91072,57.66244-9.26344,88.74372-4.0209a97.27262,97.27262,0,0,0,16.12839,1.3456,95.7069,95.7069,0,0,0,63.8553-24.35094,96.23165,96.23165,0,0,1-86.88309,55.05467A97.27245,97.27245,0,0,1,202.538,534.974c-31.08129-5.24254-60.93922-3.88982-88.74373,4.0209a68.72763,68.72763,0,0,1-18.81572,2.60887c-1.08249,0-2.204-.02746-3.33261-.0824l-1.30749-.06287L91.064,540.368a46.64834,46.64834,0,0,1,7.54306-8.89047,65.30253,65.30253,0,0,0-14.24289,9.04108l-.26042.217-.33663-.05494A68.10219,68.10219,0,0,1,47.67451,424.4753Z" transform="translate(-26.84086 -49.49819)"/></g><circle cx="460.31828" cy="185" r="5" fill="#fff"/><circle cx="834.31828" cy="305" r="3" fill="#fff"/><circle cx="892.31828" cy="170" r="3" fill="#fff"/><circle cx="355.31828" cy="80" r="3" fill="#fff"/><circle cx="325.31828" cy="201" r="3" fill="#fff"/><circle cx="179.31828" cy="170" r="3" fill="#fff"/><circle cx="696.31828" cy="195" r="3" fill="#fff"/><circle cx="1003.31828" cy="98" r="3" fill="#fff"/><path d="M328.95929,413.56327c-3.79958-7.035-4.33-16.25537.33531-22.74859a36.83843,36.83843,0,0,0,14.67507,20.5993c2.77181,1.88719,6.05124,3.69758,6.99947,6.914a8.23488,8.23488,0,0,1-.85864,6.04445,24.4571,24.4571,0,0,1-3.79505,4.95494l-.13433.50325C339.30268,425.75443,332.75886,420.59829,328.95929,413.56327Z" transform="translate(-26.84086 -49.49819)" fill="#3f3d56"/><path d="M910.95929,612.56327c-3.79958-7.035-4.33-16.25537.33531-22.74859a36.83843,36.83843,0,0,0,14.67507,20.5993c2.77181,1.88719,6.05124,3.69758,6.99947,6.914a8.23488,8.23488,0,0,1-.85864,6.04445,24.4571,24.4571,0,0,1-3.795,4.95494l-.13433.50325C921.30268,624.75443,914.75886,619.59829,910.95929,612.56327Z" transform="translate(-26.84086 -49.49819)" fill="#3f3d56"/><path d="M591.95929,449.56327c-3.79958-7.035-4.33-16.25537.33531-22.74859a36.83843,36.83843,0,0,0,14.67507,20.5993c2.77181,1.88719,6.05124,3.69758,6.99947,6.914a8.23488,8.23488,0,0,1-.85864,6.04445,24.4571,24.4571,0,0,1-3.795,4.95494l-.13433.50325C602.30268,461.75443,595.75886,456.59829,591.95929,449.56327Z" transform="translate(-26.84086 -49.49819)" fill="#3f3d56"/><path d="M287.95929,565.56327c-3.79958-7.035-4.33-16.25537.33531-22.74859a36.83843,36.83843,0,0,0,14.67507,20.5993c2.77181,1.88719,6.05124,3.69758,6.99947,6.914a8.23488,8.23488,0,0,1-.85864,6.04445,24.4571,24.4571,0,0,1-3.79505,4.95494l-.13433.50325C298.30268,577.75443,291.75886,572.59829,287.95929,565.56327Z" transform="translate(-26.84086 -49.49819)" fill="#3f3d56"/><path d="M249.95929,651.56327c-3.79958-7.035-4.33-16.25537.33531-22.74859a36.83843,36.83843,0,0,0,14.67507,20.5993c2.77181,1.88719,6.05124,3.69758,6.99947,6.914a8.23488,8.23488,0,0,1-.85864,6.04445,24.4571,24.4571,0,0,1-3.79505,4.95494l-.13433.50325C260.30268,663.75443,253.75886,658.59829,249.95929,651.56327Z" transform="translate(-26.84086 -49.49819)" fill="#3f3d56"/><rect x="843.31828" y="68" width="11" height="589" fill="#3f3d56"/><rect x="813.31828" y="20" width="72" height="72" rx="35.99996" fill="#ff6582"/><path d="M418.64263,424.1385c0,11.47771,12.51572,21.67823,23.99344,21.67823s17.571-10.20052,17.571-21.67823a20.78224,20.78224,0,0,0-41.56448,0Z" transform="translate(-26.84086 -49.49819)" fill="#2f2e41"/><polygon points="398.471 484.489 437.067 483.005 439.294 442.925 394.76 442.925 398.471 484.489" fill="#ffb8b8"/><path d="M400.81364,561.4928a6.18231,6.18231,0,0,0-.36494-9.4728l7.00739-20.82235-11.03775,2.917-4.96213,19.32605a6.21581,6.21581,0,0,0,9.35743,8.05215Z" transform="translate(-26.84086 -49.49819)" fill="#ffb6b6"/><circle cx="415.75835" cy="381.62478" r="14.69804" fill="#ffb8b8"/><path d="M442.96047,429.64379l-10.73253-.28426a1.504,1.504,0,0,1-1.28014-.78738l-3.58787-6.65514a1.49783,1.49783,0,0,1,.39563-1.89138L441.79818,409.047a1.49679,1.49679,0,0,1,1.25618-.28037l11.34184,2.58422a1.499,1.499,0,0,1,1.1066,1.04314l4.4413,15.29492a1.49935,1.49935,0,0,1-1.51389,1.916l-5.5602-.27779a1.50724,1.50724,0,0,1-1.34747-1.0276l-.23052-.69867a.17342.17342,0,0,0-.338.05439,1.49974,1.49974,0,0,1-1.57346,1.4977l-1.84088-.09194a1.4954,1.4954,0,0,1-1.396-1.205l-.79385-3.99256a.1732.1732,0,0,0-.34188.01359l-.51866,4.442a1.492,1.492,0,0,1-1.48734,1.32546Z" transform="translate(-26.84086 -49.49819)" fill="#2f2e41"/><path d="M432.2515,449.58079l19.00323.25331,6.18481,7.85346,9.95684,2.3481,2.5878,14.95427c1.29375,7.47624-.07979,12.21089-3.88076,18.77751l0,0-.45522,12.91771.503.91426a2.09364,2.09364,0,0,1-.63119,2.72267h0a4.27726,4.27726,0,0,1,.11752,2.81491l-.24528.81046s-.70783,5.66261-40.83239-.29293a3.95632,3.95632,0,0,1-3.34345-3.3986h0a2.95406,2.95406,0,0,1-.547-3.4038l.08175-.16348-.412-.48529a3.177,3.177,0,0,1-.1608-3.90659h0l-5.76652-41.25217,11.91192-3.71Z" transform="translate(-26.84086 -49.49819)" fill="#2f2e41"/><path d="M419.16862,464.99288l-4.75684-3.94828s-4.22952,1.25013-7.18334,9.58077-13.08957,71.52656-13.08957,71.52656l11.87557-5.93778,16.8392-46.43085Z" transform="translate(-26.84086 -49.49819)" fill="#2f2e41"/><path d="M524.81946,532.274a6.18228,6.18228,0,0,1-7.09116-6.29147l-20.54147-7.79242,9.257-6.682,18.08733,8.42424a6.21581,6.21581,0,0,1,.28831,12.34162Z" transform="translate(-26.84086 -49.49819)" fill="#ffb6b6"/><path d="M461.88061,464.63253l3.22471-5.27425s4.40655-.18456,9.89528,6.74353c2.81373,3.55161,21.04874,34.01719,21.04874,34.01719l16.86311,14.05546-13.80628,4.93081-16.27169-6.90314-18.244-30.078Z" transform="translate(-26.84086 -49.49819)" fill="#2f2e41"/><polygon points="435.555 666.81 444.739 666.81 449.108 631.385 435.553 631.386 435.555 666.81" fill="#ffb6b6"/><polygon points="355.157 661.099 364.044 663.415 377.208 630.238 364.091 626.819 355.157 661.099" fill="#ffb6b6"/><path d="M460.11787,711.77763l14.51826-.86655v6.22026l13.80293,9.53279a3.88541,3.88541,0,0,1-2.20782,7.08274H468.9467l-2.97925-6.15279-1.16325,6.15279h-6.517Z" transform="translate(-26.84086 -49.49819)" fill="#2f2e41"/><path d="M380.13111,705.42858l14.2674,2.8235-1.569,6.01913,10.95211,12.70615a3.88541,3.88541,0,0,1-3.923,6.29683L383.133,728.91441l-1.331-6.70531-2.67759,5.66043-6.30624-1.64381Z" transform="translate(-26.84086 -49.49819)" fill="#2f2e41"/><path d="M383.1248,688.31931l26.92081-55.33021,2.11353-65.49091C406.33233,556.677,423.491,532.805,423.491,532.805v-9.24491l41.91852,7.90812v0a201.21489,201.21489,0,0,1,12.26151,73.06026L475.982,694.04734h.52987a3.31527,3.31527,0,1,1,0,6.63053H459.9355a3.31527,3.31527,0,1,1,0-6.63053h.4274L448.4631,580.16351l-13.83654,56.19881L401.189,688.1066a3.3069,3.3069,0,0,1-.26524,6.60379H384.34739a3.31182,3.31182,0,0,1-1.22259-6.39108Z" transform="translate(-26.84086 -49.49819)" fill="#2f2e41"/><path d="M382.75841,426.29647c6.19395-6.05935,10.09279-14.02773,15.22255-21.01108,5.1296-6.98327,12.35472-13.3824,21.01083-13.77026a13.03786,13.03786,0,0,1,8.16579,2.129,8.30541,8.30541,0,0,1,3.60455,7.36741c.9138-2.56674,4.99718-3.1453,6.588-.93331,1.59062,2.21191-.25722,5.89893-2.98115,5.94838l-.2671-1.05666a18.24877,18.24877,0,0,1-11.80141,7.83613,2.9783,2.9783,0,0,1-3.35526-3.85425C409.59087,410.80666,412.56052,428.25234,407,436s-21.45259,6.99551-30.82907,8.7353c-9.05466,1.68-17.85857-3.34756-25.69931-8.178A38.2715,38.2715,0,0,0,382.75841,426.29647Z" transform="translate(-26.84086 -49.49819)" fill="#2f2e41"/><path d="M732.68989,636.90373,704.47275,624.455V613.75265l10.0561-.05651a7.46918,7.46918,0,0,0,7.044-5.10714l7.06437-21.19305a7.46924,7.46924,0,0,0-7.086-9.83122H704.47275v-9.959H725.913a7.46925,7.46925,0,0,0,7.27937-5.79584l4.865-21.16286a7.46923,7.46923,0,0,0-7.27937-9.14265H704.47275v-2.48975a4.97949,4.97949,0,0,0-9.959,0v2.48975H518.1566v-2.48975a4.9795,4.9795,0,0,0-9.959,0v2.48975H487.2868a7.46923,7.46923,0,0,0-7.27937,9.14265l4.865,21.16286a7.46925,7.46925,0,0,0,7.27937,5.79584H508.1976v9.959H496.51328a7.46923,7.46923,0,0,0-7.10927,9.76l7.21041,22.37711a7.46925,7.46925,0,0,0,7.15123,5.17837l4.432-.0249V624.455l-22.82269,12.44874a7.46922,7.46922,0,0,0-7.46924,7.46922v0a7.46925,7.46925,0,0,0,7.46924,7.46925H508.1976v54.77446a4.9795,4.9795,0,0,0,9.959,0V651.84222H694.51376v54.77446a4.97949,4.97949,0,0,0,9.959,0V651.84222h28.21714a7.46925,7.46925,0,0,0,7.46925-7.46925v0A7.46922,7.46922,0,0,0,732.68989,636.90373Zm-214.53329-69.298H694.51376v9.959H518.1566Zm0,56.84925v-9.65563l176.35716-.99076V624.455Z" transform="translate(-26.84086 -49.49819)" fill="#3f3d56"/></svg>',A9e='<svg xmlns="http://www.w3.org/2000/svg" data-name="Layer 1" width="855.93958" height="630.06608" viewBox="0 0 855.93958 630.06608" xmlns:xlink="http://www.w3.org/1999/xlink"><path d="M935.43234,472.55767c-3.73,43.08-22.51,84.71-49.3,119.14q-1.68,2.16-3.4,4.28-3.87,4.77-7.94,9.36-4.98,5.655-10.25,11.05005-4.29,4.43994-8.78,8.68994-3.465,3.315-7.01,6.5c-28.43,25.69-61.09,46.89-94.74,65.43005-65.67,36.17-137.65,63.56995-212.52,67.56-74.86,3.98-153.01-17.46-207.91-68.52-73.99-68.81-94.63995-183.58-64.6-280.05,19.98-64.18,60.76-122.24,116.26-160.16,55.02-37.59,124.43-54.51,190.12-43.44995,52.44-31.87006,121.09-32.48,178.1-8.89,30.42,12.59,57.72,31.31,81.67,53.93a339.34337,339.34337,0,0,1,30.72,33.23q1.455,1.785,2.88,3.6,5.97,7.545,11.55,15.4,8.01,11.265,15.21,23.03c1.32,2.16,2.63,4.33,3.91,6.52.86,1.47,1.73,2.95,2.58,4.44a.29776.29776,0,0,1,.04.1c13.31,23.41,24.19,48.39,29.86005,74.5,1,4.62,1.84,9.26,2.49,13.94v.01q.855,5.955,1.29,11.97A176.97711,176.97711,0,0,1,935.43234,472.55767Z" transform="translate(-172.03021 -134.96696)" fill="#3f3d56"/><path d="M740.07386,537.68412,591.61233,414.00627,735.84027,542.638a3.44161,3.44161,0,1,0,4.23359-4.95386Z" transform="translate(-172.03021 -134.96696)" fill="#f0f0f0" opacity="0.3"/><circle cx="227.58212" cy="250.78071" r="89" fill="#f2f2f2"/><path d="M478.61233,379.74767a80.99369,80.99369,0,0,1-81,81,81.57161,81.57161,0,0,1-27.8-4.9,81.05489,81.05489,0,1,1,108.8-76.1Z" transform="translate(-172.03021 -134.96696)" fill="#fff"/><circle cx="211.58212" cy="217.78071" r="25" fill="#e4e4e4"/><path d="M475.45236,357.27764a25.00115,25.00115,0,0,1-27.6-41.08A81.05279,81.05279,0,0,1,475.45236,357.27764Z" transform="translate(-172.03021 -134.96696)" fill="#f2f2f2"/><circle cx="252.58212" cy="271.78071" r="9" fill="#e4e4e4"/><path d="M387.61233,457.74767a9.04581,9.04581,0,0,1-.31,2.34,79.52774,79.52774,0,0,1-17.49-4.24,9.00157,9.00157,0,0,1,17.8,1.9Z" transform="translate(-172.03021 -134.96696)" fill="#f2f2f2"/><path d="M334.61233,375.74767a18.002,18.002,0,0,1-16.8,17.96,81.54773,81.54773,0,0,1,1.76-35.71A18.00026,18.00026,0,0,1,334.61233,375.74767Z" transform="translate(-172.03021 -134.96696)" fill="#f2f2f2"/><circle cx="606.45653" cy="208.48305" r="3.70234" fill="#6c63ff"/><circle cx="572.30231" cy="119.94851" r="2.16307" fill="#f0f0f0"/><circle cx="225.30231" cy="543.94851" r="2.16307" fill="#f0f0f0"/><circle cx="584.58144" cy="331.59402" r="2.16307" fill="#f0f0f0"/><circle cx="305.45653" cy="350.48305" r="3.70234" fill="#6c63ff"/><circle cx="171.45653" cy="416.48305" r="17.48305" fill="#6c63ff"/><circle cx="267.30231" cy="435.94851" r="2.16307" fill="#f0f0f0"/><circle cx="487.30231" cy="97.94851" r="2.16307" fill="#f0f0f0"/><circle cx="358.30231" cy="558.94851" r="2.16307" fill="#f0f0f0"/><circle cx="326.30231" cy="117.94851" r="2.16307" fill="#f0f0f0"/><circle cx="382.30231" cy="222.94851" r="2.16307" fill="#f0f0f0"/><circle cx="296.58144" cy="480.59402" r="2.16307" fill="#f0f0f0"/><circle cx="549.58144" cy="494.59402" r="2.16307" fill="#f0f0f0"/><circle cx="437.58144" cy="368.59402" r="2.16307" fill="#f0f0f0"/><circle cx="494.58144" cy="222.59402" r="2.16307" fill="#f0f0f0"/><circle cx="598.21204" cy="292.65473" r="4.28889" fill="#ff6584"/><circle cx="424.21204" cy="150.65473" r="4.28889" fill="#ff6584"/><circle cx="424.21204" cy="445.65473" r="4.28889" fill="#ff6584"/><path d="M863.45236,605.33764a7.694,7.694,0,0,0-7.39,5.58,7.3896,7.3896,0,0,0-.3,2.12v12.04q4.485-4.24494,8.78-8.68994,5.265-5.40006,10.25-11.05005Z" transform="translate(-172.03021 -134.96696)" fill="#6c63ff"/><path d="M890.68118,667.89806q-19.36816,0-42.45654-1.46386c-79.61377-5.05567-182.7378-22.63282-290.376-49.49219-107.6377-26.85938-206.93018-59.79395-279.58545-92.73438-35.39258-16.04687-62.55615-31.23632-80.73535-45.14746-19.24707-14.72705-27.666-27.564-25.02393-38.15283,5.148-20.62891,50.731-25.14209,88.064-25.29541l.01269,3c-51.26806.21045-81.51367,8.38672-85.16552,23.022-4.65186,18.64014,33.28662,47.74073,104.08691,79.84131,72.49561,32.86817,171.60547,65.73926,279.07324,92.55664,107.46729,26.81641,210.40137,44.36328,289.83985,49.40821,77.57861,4.92773,124.74316-2.9375,129.39453-21.57813,3.86181-15.47656-21.59815-38.27539-71.68946-64.19824l1.37891-2.66406c36.397,18.83593,78.64551,45.85156,73.22168,67.58886-2.64258,10.58887-16.10547,17.96485-40.01514,21.92285C927.0762,666.7672,910.33548,667.89806,890.68118,667.89806Z" transform="translate(-172.03021 -134.96696)" fill="#6c63ff"/><circle cx="714.58212" cy="208.78071" r="100.5" fill="#fff"/><path d="M886.61233,241.74767a102,102,0,1,0,102,102A101.635,101.635,0,0,0,886.61233,241.74767Zm0,201a99,99,0,1,1,99-99A98.61767,98.61767,0,0,1,886.61233,442.74767Z" transform="translate(-172.03021 -134.96696)" fill="#2f2e41"/><path d="M798.417,367.81847a2.00078,2.00078,0,0,1-1.957-1.59765,97.66924,97.66924,0,0,1,22.34082-83.13526,2,2,0,0,1,2.98633,2.66114A93.59682,93.59682,0,0,0,800.378,365.41515a2.00228,2.00228,0,0,1-1.96094,2.40332Z" transform="translate(-172.03021 -134.96696)" fill="#2f2e41"/><circle cx="714.51924" cy="238.27373" r="63.87702" fill="#6c63ff"/><path d="M866.24805,397.35666c-4.14062-.115-9.29385-.25869-13.26384-3.15874a10.18618,10.18618,0,0,1-4.00806-7.60607,6.85213,6.85213,0,0,1,2.33007-5.62763c2.07352-1.75216,5.10139-2.16313,8.36441-1.2042l-3.38076-24.7061,2.48174-.34,3.97444,29.04518-2.07245-.951c-2.4027-1.10205-5.70088-1.66285-7.7504.06911a4.40263,4.40263,0,0,0-1.44375,3.62659,7.69887,7.69887,0,0,0,2.98246,5.67107c3.08949,2.25668,7.19708,2.54779,11.85585,2.678Z" transform="translate(-172.03021 -134.96696)" fill="#2f2e41"/><rect x="658.49493" y="222.21767" width="13.49133" height="2.50498" fill="#2f2e41"/><rect x="701.07961" y="222.21765" width="13.49133" height="2.50498" fill="#2f2e41"/><path d="M889.23233,452.90765h-57.9a8.14716,8.14716,0,0,0-8.13995,8.14v128.33a47.66955,47.66955,0,0,0,25.56,42.19995q3.555-3.18,7.01-6.5,4.485-4.24494,8.78-8.68994,5.265-5.40006,10.25-11.05005,4.08006-4.59,7.94-9.36,1.725-2.115,3.4-4.28c26.79-34.43,45.57-76.06,49.3-119.14A64.04854,64.04854,0,0,0,889.23233,452.90765Z" transform="translate(-172.03021 -134.96696)" fill="#2f2e41"/><path d="M891.34231,479.68767a14.61136,14.61136,0,0,0-10.43-4.17,14.465,14.465,0,0,0-9.16,3.36005,13.12263,13.12263,0,0,0-1.17,1.07l-47.38995,48.6-34.37,35.25a6.80061,6.80061,0,0,0-1.28,1.8,7.29573,7.29573,0,0,0-.77,3.32,7.16751,7.16751,0,0,0,2.18006,5.07l1.35,1.32,9.8,9.55.01-.01a7.29073,7.29073,0,0,0,4.66,1.63,7.167,7.167,0,0,0,5.07-2.18l1.59-1.62,11.38-11.67.38-.39,68.41-70.16a14.69128,14.69128,0,0,0-.26-20.77Z" transform="translate(-172.03021 -134.96696)" fill="#6c63ff"/><path d="M890.86152,343.44c2.1124-4.46658-.05349-9.23761-3.76378-12.09072-4.67557-3.59539-10.7221-3.00085-16.04008-1.29905-5.82238,1.8632-11.51366,5.21608-17.80383,5.02337a11.13058,11.13058,0,0,1-10.24407-7.27764c-3.3687-8.639.43561-18.29488,6.29971-24.84681a34.26766,34.26766,0,0,1,26.544-11.586,34.64989,34.64989,0,0,1,28.068,16.9026,1.54079,1.54079,0,0,0,2.05229.53813,36.88225,36.88225,0,0,1,28.39377-.71432,36.28984,36.28984,0,0,1,22.58042,34.49188c-.05,1.93122,2.95005,1.9301,3,0a39.89155,39.89155,0,0,0-10.59928-27.81249,38.71871,38.71871,0,0,0-27.56681-12.16772,39.33641,39.33641,0,0,0-17.32226,3.61223l2.05229.53813a37.69886,37.69886,0,0,0-25.0988-17.728,36.48542,36.48542,0,0,0-29.42384,7.32772c-7.70165,6.02707-13.53849,15.38016-13.17519,25.41071.15721,4.34047,1.44713,8.796,4.4606,12.03051,3.85981,4.14287,9.62229,4.85944,14.94631,3.798,7.07554-1.41071,13.53533-6.06449,20.91133-5.92113a10.21164,10.21164,0,0,1,7.6417,3.4453c1.62455,1.83335,2.6042,4.47042,1.49716,6.81122-.82094,1.73585,1.76463,3.26026,2.59041,1.51416Z" transform="translate(-172.03021 -134.96696)" fill="#2f2e41"/><path d="M412.09426,704.32287c-35.59912.001-68.69433-1.22071-98.32226-3.68555-38.72656-3.22266-69.41455-8.40332-91.21045-15.39648-23.07666-7.40528-35.31934-16.667-36.38818-27.52832-2.083-21.15821,39.334-40.72461,74.44531-53.41309l1.01953,2.82227c-48.2168,17.42382-73.957,35.28613-72.47949,50.29785,1.88183,19.11914,47.39209,33.78125,124.86181,40.22754,79.3252,6.60058,183.71729,4.26172,293.94727-6.58985,110.23-10.84863,213.07568-28.90625,289.59131-50.8457,74.72607-21.42578,116.50488-44.67969,114.623-63.79883-1.5625-15.874-33.20264-28.793-89.0918-36.3789l.40332-2.97266c40.60986,5.51172,89.47949,16.76172,91.67383,39.05762,1.06933,10.86132-9.1333,22.332-30.32276,34.09375-20.01465,11.10937-49.10351,22.17285-86.45849,32.88281-76.68506,21.98828-179.71973,40.08105-290.12451,50.94824C539.00247,700.86,472.01663,704.32287,412.09426,704.32287Z" transform="translate(-172.03021 -134.96696)" fill="#6c63ff"/><circle cx="838.45653" cy="434.48305" r="17.48305" fill="#6c63ff"/><circle cx="331.45653" cy="17.48305" r="17.48305" fill="#e6e6e6"/><circle cx="19.45653" cy="433.48305" r="17.48305" fill="#e6e6e6"/><circle cx="127.45653" cy="108.48305" r="10.70234" fill="#ff6584"/><circle cx="77.45653" cy="514.48305" r="10.70234" fill="#ff6584"/><circle cx="807.45653" cy="339.48305" r="10.70234" fill="#ff6584"/><circle cx="645.45653" cy="598.48305" r="17.48305" fill="#e6e6e6"/></svg>',u5=(e,t)=>{const n=window.atob(e),r=new ArrayBuffer(n.length),o=new Uint8Array(r);for(let i=0;i<n.length;i++)o[i]=n.charCodeAt(i);return new Blob([r],{type:t})},d5=async e=>{const{vault:t}=$e.getState().app,n=await t.adapter.readBinary(e),r=new Uint8Array(n),o=new Blob([r],{type:"image/png"});return new Promise(i=>{const a=new FileReader;a.onloadend=()=>{const s=a.result;i(s)},a.readAsDataURL(o)})},N9e=async e=>{const t=e.find(".thino-user-icon");if(!(t&&!/(http|app|base64)/.test(t?.style?.backgroundImage))&&t&&t?.style?.backgroundImage){const n=await tm(t);t.style.backgroundImage=`url("${n}")`}},TA=async e=>{const t=e.findAll("img");for(const n of t)if(n.src.startsWith("http://localhost")){const r=await Fu(n.getAttribute("path")||N.normalizePath(n?.parentElement.getAttribute("src")));n.src=r}else{const r=await koe(n);n.src=r}},O9e=async e=>{const{app:t,settings:n}=$e.getState();let r,o;const i=document.body.hasClass("theme-light"),a=i?e==="modern"?n?.DefaultLightBackgroundImage:n?.DefaultLightBackgroundImageForClean:e==="modern"?n?.DefaultDarkBackgroundImage:n?.DefaultDarkBackgroundImageForClean,s=await t.vault.adapter.exists(a)&&/\.(png|svg|jpg|jpeg)/g.test(a),l=a?.startsWith("http");switch(e){case"clean":s||l?(o=a,r=l?await Fu(a):await d5(o)):r=i?l0:cC;break;case"minimal":break;case"modern":default:s||l?(o=a,r=l?await Fu(a):await d5(o)):r="data:image/svg+xml;base64,"+btoa(i?D9e:A9e);break}switch(e){case"modern":{const u=document.querySelector(".dialog-wrapper .memo-background .property-image");u.style.backgroundImage="url('"+r+"')";break}case"clean":{const u=document.querySelector(".dialog-wrapper .memo-container.clean .memo-background .property-image");u&&(u.style.backgroundImage="url('"+r+"')");break}case"minimal":break;default:{const u=document.querySelector(".dialog-wrapper .memo-background .property-image");u.style.backgroundImage="url('"+r+"')"}}return r},P9e=e=>{const{memo:t,destroy:n}=e,{memos:r}=ke.getState().memoState,{view:o,app:i,settings:a}=ke.getState().dailyNotesState,s={...t,createdAtStr:Le.getDateTimeString(t.createdAt)},[l,u]=D.useState(!1),[d,h]=D.useState(s.content),[p,m]=D.useState(!1),b=D.useRef(null),v=D.useRef(null),y=D.useRef(null),[S,x]=D.useState(e.style||(i||window.app).loadLocalStorage("memoShareDialogStyle")||"clean"),[C,k]=D.useState(""),M=D.useRef(null),I=D.useRef(null),[O,R]=Y.useState(a?.MomentsIcon);D.useEffect(()=>{if(!a?.MomentsIcon||!i)return;const ne=i.vault.adapter.getResourcePath(N.normalizePath(a.MomentsIcon));ne&&!a?.MomentsIcon.startsWith("http")?R(ne):R(a?.MomentsIcon)},[a?.MomentsIcon,i]);let L,B;r.length&&(L=r.length>0?r[r.length-1]:null,L?B=r?Math.ceil((Date.now()-Le.getTimeStampByDate(L?.createdAt))/1e3/3600/24)+1:0:B=0),a?.ShareFooterEnd.replace("{UserName}",a?.UserName);const _=a?.ShareFooterStart.replace("{ThinoNum}",r.length.toString()).replace("{UsedDay}",B.toString());D.useEffect(()=>{!b.current||!v.current||(N.setIcon(b.current,"copy"),N.setIcon(v.current,"x"))},[b,v]),D.useEffect(()=>{y.current&&N.setIcon(y.current,"file-down")},[y]),D.useEffect(()=>{N.setIcon(b.current,p?"loader":"copy"),b.current.disabled=p,b.current.toggleClass("copying",p)},[p]),D.useEffect(()=>{if(!I.current||!o&&!e.view||l)return;h(t.content),I.current.hasChildNodes()&&I.current.empty();async function ne(){I.current?.toggleClass(["markdown-rendered"],!0),await N.MarkdownRenderer.render(i,t.content+`
|
|
|
`,I.current,t.path,o||e.view)}ne(),setTimeout(async()=>{await H()},j8)},[M,I,s,S]);const H=async()=>{M.current&&(await N9e(M.current),await TA(M.current),O9e(S).then(ne=>{ne&&setTimeout(()=>{ES(M.current,{pixelRatio:window.devicePixelRatio*2}).then(J=>{k(J),u(!0)}).catch(()=>{})},600)}))},U=()=>{n()},G=D.useCallback(ne=>{m(ne)},[p]),K=async()=>{const{vault:ne}=ke.getState().dailyNotesState.app,J=M.current.querySelector(".memo-shortcut-img");if(!J)return;const ee=J?.getAttribute("src").split("base64,")[1],Z=u5(ee,"image/png");let q;Z.arrayBuffer().then(async $=>{const re="png",le=Il();for(const ie in le)if(le[ie]instanceof N.TFile){q=le[ie];break}if(q!==void 0){const ie=await ne.getAvailablePathForAttachments(`Pasted Image ${N.moment().format("YYYYMMDDHHmmss")}`,re,q);await ne.createBinary(ie,$),new N.Notice(E("Save image successfully"))}})},z=async()=>{G(!0);const ne=M.current.querySelector(".memo-shortcut-img");if(!ne)return;const J=ne?.getAttribute("src").split("base64,")[1],ee=u5(J,"image/png");if(!ee){new N.Notice(E("Copy to clipboard failed"));return}const Z=new ClipboardItem({"image/png":ee});window.navigator.clipboard.write([Z]).then(()=>{setTimeout(()=>{G(!1)},500)}),new N.Notice(E("Copy to clipboard successfully"))};return w.jsxs(w.Fragment,{children:[w.jsxs("div",{className:tn("dialog-header-container"),children:[w.jsxs("p",{className:"title-text",children:[w.jsx("span",{className:"icon-text",children:"🥰"}),E("Share Memo Image")]}),w.jsxs("div",{className:"btn-group",children:[N.Platform.isMobile&&w.jsx("button",{ref:y,className:"btn download-btn",onClick:K}),w.jsx("button",{ref:b,className:"btn copy-btn",onClick:z}),w.jsx("button",{ref:v,className:"btn close-btn",onClick:U})]})]}),w.jsxs("div",{className:tn("dialog-content-container",S),children:[w.jsx("div",{className:`tip-words-container ${C?"finish":"loading"}`,children:w.jsx("p",{className:"tip-text",children:E(C?"↗Click the button to save":"Image is generating...")})}),w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("Default sharing style")}),w.jsx("div",{className:"setting-item-description",children:E("Set the default style for sharing thino, 'Modern' by default.")})]}),w.jsx("div",{className:"setting-item-control",children:w.jsxs("select",{className:"dropdown",defaultValue:S,onChange:async ne=>{ne.currentTarget.value!==S&&(u(!1),k(""),x(ne.currentTarget.value),(i||window.app).saveLocalStorage("memoShareDialogStyle",ne.currentTarget.value),await H())},children:[w.jsx("option",{value:"modern",children:E("Modern")}),w.jsx("option",{value:"clean",children:E("Clean")}),w.jsx("option",{value:"minimal",children:E("Minimal")}),w.jsx("option",{value:"gradient",children:E("Gradient")})]})})]}),w.jsxs("div",{className:tn("memo-container",S),ref:M,children:[w.jsx(il,{when:C!=="",children:w.jsx("img",{className:"memo-shortcut-img",onClick:z,src:C})}),w.jsxs("div",{className:"memo-background",children:[w.jsx("div",{className:"property-image",style:{backgroundSize:"cover",backgroundRepeat:"no-repeat",backgroundPosition:"center"}}),w.jsx("span",{className:"background-container"}),w.jsxs("div",{className:"thino-user-header",children:[w.jsx("div",{className:"thino-user-icon",ref:ne=>{if(a?.MomentsIcon){ne?.empty();return}a?.MomentsIcon||ne&&N.setIcon(ne,"Memos")},style:{backgroundImage:`url("${O}")`}}),w.jsxs("div",{className:"thino-user-info",children:[w.jsx("div",{className:"thino-user-name",children:a?.UserName}),a?.MomentsQuote&&w.jsx("div",{className:"thino-user-quote",children:a?.MomentsQuote})]})]}),w.jsx("div",{ref:I,className:"memo-content-text",style:{minHeight:a.MinHeightForShare||"200px"}}),w.jsx("div",{className:"thino-time-footer",children:s.createdAt}),w.jsxs("div",{className:"watermark-container",children:[w.jsxs("span",{className:"normal-text footer-start",children:[w.jsx("div",{className:"property-social-icons"}),w.jsx("span",{className:"name-text",children:_})]}),w.jsx("span",{className:"normal-text footer-end",children:w.jsx("span",{className:"name-text",children:"THINO"})})]})]})]})]})]})};function yu(e,t,n){yS({className:"share-memo-image-dialog no-twp"},P9e,{memo:e,style:t,view:n})}function Dc(e=!0){const[t,n]=D.useState({isLoading:e,isFailed:!1,isSucceed:!1,isPending:!1});return{...t,setLoading:()=>{n({...t,isLoading:!0,isFailed:!1,isPending:!1,isSucceed:!1})},setFinish:()=>{n({...t,isLoading:!1,isFailed:!1,isPending:!1,isSucceed:!0})},setError:()=>{n({...t,isLoading:!1,isFailed:!0,isPending:!1,isSucceed:!1})},setPending:()=>{n({...t,isLoading:!1,isFailed:!1,isPending:!0,isSucceed:!1})}}}const j9e=e=>{const{dailyNotesState:{app:t,settings:n,view:r}}=D.useContext(ct),{memo:o,handleUnarchivedMemoAction:i}=e,a=Y.useRef(null),s=Y.useRef(null),[l,u]=Y.useState(""),d={...o,createdAtStr:Le.getDateTimeString(o.createdAt),deletedAtStr:Le.getDateTimeString(o.deletedAt||o.createdAt)},h=D.useRef(null);D.useEffect(()=>{!s||!h.current||N.setIcon(h.current,"more-horizontal")},[s]),D.useEffect(()=>{if(!a.current||!s.current||a.current.hasChildNodes()&&o.content===l||!r)return;u(o.content),a.current.hasChildNodes()&&a.current.empty();async function y(){a.current?.toggleClass(["markdown-rendered"],!0),await N.MarkdownRenderer.render(t,o.content+`
|
|
|
`,a.current,o.path,r),a.current?.querySelectorAll(".internal-link")?.forEach(x=>{const C=x,k=C.getAttribute("data-href");if(!k)return;t.metadataCache.getFirstLinkpathDest(k,o.path)||x.classList.add("is-unresolved"),C.addEventListener("mouseover",I=>{I.stopPropagation(),t.workspace.trigger("hover-link",{event:I,source:"thino",hoverParent:r.containerEl,targetEl:C,linktext:k,sourcePath:C.href})})})}y()},[o.content,s]);const p=async()=>{switch(d.sourceType){case"DAILY":await JM(d.id,d.path);break;case"CANVAS":await eD(d.id,d.path);break;case"MULTI":await XM(d.path);break;case"FILE":await QM(d.id,d.path);break}},m=async()=>{try{if(n.DeleteThinoDirectly)await de.deleteMemoById(d.id);else{const y=await de.hideMemoById(d.id);y&&de.editMemo(y)}}catch(y){new N.Notice(y.message)}},b=async()=>{try{const y=await de.unarchiveMemo(d);y&&de.editMemo(y),i(d.id),new N.Notice(E("RESTORE SUCCEED"))}catch(y){new N.Notice(y.message)}},v=y=>{y.stopPropagation();const S=new N.Menu;S.addItem(x=>{x.setTitle(E("RESTORE")).setIcon("archive-restore").onClick(b)}),S.addItem(x=>{x.setTitle(E("SOURCE")).setIcon("home").onClick(p)}),S.addItem(x=>{x.setTitle(E("DELETE")).setIcon("trash").setWarning(!0).onClick(()=>{const C=new N.Menu;C.addItem(k=>{k.setTitle(E("CONFIRM!")).setIcon("trash").setWarning(!0).onClick(m)}),C.addItem(k=>{k.setTitle(E("Cancel")).setIcon("x").onClick(()=>{})}),C.showAtMouseEvent(y.nativeEvent)})}),S.showAtMouseEvent(y.nativeEvent)};return w.jsxs("div",{ref:s,className:`memo-wrapper ${"memos-"+d.id}`,children:[w.jsxs("div",{className:"memo-top-wrapper",children:[w.jsxs("span",{className:"time-text",children:[E("ARCHIVED AT")," ",d.updatedAt]}),w.jsx("div",{className:"btns-container",children:w.jsx("span",{ref:h,className:"btn more-action-btn",onClick:v})})]}),w.jsx("div",{ref:a,className:"memo-content-text"})]})},Yh=({title:e,showSidebar:t=!1,onShowSidebarClick:n,showHomeButton:r=!0,children:o,rightContent:i})=>{const a=D.useCallback(()=>{n?n():Ze.setShowSiderbarInMobileView(!0)},[n]),s=D.useCallback(()=>{Ue.clearQuery(),Ue.setPathname("/")},[]);return w.jsxs("div",{className:"section-header-container",children:[w.jsx("div",{className:"title-wrapper",children:w.jsx("div",{className:"title-btns-left-wrapper",children:w.jsxs("div",{className:"title-text",children:[t&&w.jsx(il,{when:!0,children:w.jsx("button",{ref:l=>{l&&N.setIcon(l,"menu")},className:"btn action-btn clickable-icon",onClick:a})}),e&&w.jsx("span",{className:"normal-text",children:e}),r&&w.jsxs("button",{className:"go-home-btn",onClick:s,children:["🏠 ",E("Return To Home Page")]}),o]})})}),i&&w.jsx("div",{className:"title-btns-right-wrapper",children:i})]})},Js=e=>{const t=new Map;for(const n of e){const r=n.path;t.has(r)||t.set(r,[]),t.get(r)?.push(n)}return Array.from(t).map(([n,r])=>({path:n,thinos:r}))},L9e=()=>{const{locationState:{query:e},globalState:{isMobileView:t},memoState:{memos:n},dailyNotesState:{plugin:r}}=D.useContext(ct),o=Dc(),[i,a]=D.useState([]),s=Y.useRef(null),l=Y.useRef(null);D.useEffect(()=>{l.current&&N.setIcon(l.current,"more-horizontal")},[l]),D.useEffect(()=>{hc({memos:n,query:e,filterOptions:{filterDoneTasks:!1,onlyFilterType:"archived"},plugin:r}).then(b=>{a(b)}),o.setFinish()},[n,s.current,e]);const u=D.useCallback(b=>{a(v=>v.filter(y=>y.id!==b))},[]),d=D.useCallback(b=>{a(v=>v.filter(y=>y.id!==b))},[]);D.useCallback(()=>{Ze.setShowSiderbarInMobileView(!0)},[]);const h=async()=>{if(!(i?.length>0))return;if(!await rs()){Nt();return}const b=[...i];try{const v=b.filter(C=>C.sourceType==="DAILY"),y=b.filter(C=>C.sourceType!=="DAILY"),S=await de.unarchiveThinoBulk(y);for(const C of S)C&&de.editMemo(C);const x=Js(v);for(const{path:C,thinos:k}of x)await de.dealWithDailyThinoBulk(C,k,"restoreFromArchive");new N.Notice(E("RESTORE SUCCEED")),Ue.clearQuery()}catch(v){console.error("error",v),new N.Notice(v.message)}},p=async()=>{if(!(i?.length>0))return;if(!await rs()){Nt();return}const b=[...i],v=$e.getState().settings.DeleteThinoDirectly;try{const y=b.filter(C=>C.sourceType==="DAILY"),S=b.filter(C=>C.sourceType!=="DAILY");for(const C of S)if(v)await de.deleteMemoById(C.id);else{const k=await de.hideMemoById(C.id);k&&de.editMemo(k)}const x=Js(y);for(const{path:C,thinos:k}of x)await de.dealWithDailyThinoBulk(C,k,v?"deleteForever":"delete");Ue.clearQuery()}catch(y){console.error("error",y),new N.Notice(y.message)}},m=b=>{const v=new N.Menu;v.addItem(y=>{y.setTitle(E("Bulk restore")).setIcon("archive").onClick(async()=>{new da(app,E("RESTORE"),async S=>{S==="confirm"&&await h()}).open()})}).addItem(y=>{y.setTitle(E("Bulk delete")).setIcon("trash").onClick(async()=>{new da(app,E("DELETE"),async S=>{S==="confirm"&&await p()}).open()})}),v.showAtMouseEvent(b.nativeEvent)};return w.jsxs("div",{className:"memo-trash-wrapper",ref:s,children:[w.jsx(Yh,{showSidebar:t,rightContent:w.jsx("div",{className:"header-right-section",children:w.jsx(nv,{})}),children:w.jsx("span",{ref:l,className:"menu-popup-btn",onClick:m})}),w.jsx(Fv,{thinosCount:i.length,thinos:i}),o.isLoading?w.jsx("div",{className:"tip-text-container",children:w.jsx("p",{className:"tip-text",children:E("Fetching data...")})}):i.length===0?w.jsx("div",{className:"tip-text-container",children:w.jsx("p",{className:"tip-text",children:E("Here is No Memos.")})}):w.jsx("div",{className:"deleted-memos-container",children:i.map(b=>w.jsx(j9e,{memo:b,handleUnarchivedMemoAction:d,handleDeletedMemoAction:u},`${b.id}-${b.updatedAt}`))})]})},rs=async()=>{const{verifyState:e}=$e.getState(),t=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),n=N.Platform.isDesktop?await Sn():t.identifier||t.uuid;return e&&e?.appId===n},R9e=async(e,t)=>{if(!(t!=="chat"&&t!=="moments")){if(t==="moments"){const n=e.querySelectorAll(".thino-moment-icon"),r=e.find(".moments-view-user-icon"),o=e.find(".moments-view-background");for(const i of n){const a=await tm(i);i.style.backgroundImage=`url(${a})`}if(r){const i=await tm(r);r.style.backgroundImage=`url(${i})`}if(o){const i=await tm(o);o.style.backgroundImage=`url(${i})`}}else if(t==="chat"){const n=e.querySelectorAll(".icon-img");for(const r of n){const o=await tm(r);r.style.backgroundImage=`url(${o})`}}}};class da extends N.Modal{constructor(t,n,r){super(t),this.title=n,this.cb=r}onOpen(){super.onOpen(),this.containerEl.toggleClass("thino-bulk-action-dialog",!0),this.titleEl.setText(this.title+" "+E("Confirm?")),this.contentEl.createEl("button",{cls:"mod-warning",text:E("Confirm?").replace(/\?|?/,"")}).onclick=()=>{this.cb("confirm"),this.close()},this.contentEl.createEl("button",{text:E("Cancel")}).onclick=()=>{this.cb("cancel"),this.close()}}onClose(){super.onClose()}}class F9e extends N.Modal{constructor(t,n){super(t),this.thinos=n}root;onOpen(){super.onOpen(),this.containerEl.toggleClass(["thino-bulk-action-dialog","tag-actions"],!0),this.root=Fi.createRoot(this.contentEl),this.root.render(w.jsx(zi,{store:ke,context:ct,children:w.jsx(xoe,{app:this.app,closeDialog:this.close.bind(this),thinos:this.thinos})}))}onClose(){super.onClose(),this.root?.unmount()}}const Fv=({thinosCount:e,thinos:t})=>{const{globalState:{memoListView:n},locationState:{query:r,pathname:o},dailyNotesState:{settings:i,app:a}}=D.useContext(ct),{tag:s,duration:l,type:u,text:d,filter:h,path:p}=r,m=Ct.getQueryById(h),b=!!(s||l&&l.from<l.to||u||d||m||p),v=D.useRef(null);D.useEffect(()=>{v&&N.setIcon(v.current,"more-horizontal")},[v]);const y=async()=>{if(!(t?.length>0))return;const L=hoe(t),B=moe(L);await Le.copyTextToClipboard(B),new N.Notice(E("Copied to clipboard Successfully"))},S=async()=>{if(!(t?.length>0))return;if(!await rs()){Nt();return}const L=[...t],B=i.DeleteThinoDirectly;try{const _=L.filter(G=>G.sourceType==="DAILY"),H=L.filter(G=>G.sourceType!=="DAILY");for(const G of H)if(B)await de.deleteMemoById(G.id);else{const K=await de.hideMemoById(G.id);K&&de.editMemo(K)}const U=Js(_);for(const{path:G,thinos:K}of U)await de.dealWithDailyThinoBulk(G,K,B?"deleteForever":"delete");de.updateTagsState(),Ue.clearQuery()}catch(_){console.error("error",_),new N.Notice(_.message)}},x=async()=>{if(!(t?.length>0))return;if(!await rs()){Nt();return}const L=[...t],B=$e.getState().settings.startSync,H=$e.getState().app?.loadLocalStorage("tokenForSync");try{const U=L.filter(z=>z.sourceType==="DAILY"),G=L.filter(z=>z.sourceType!=="DAILY");for(const z of G)await de.deleteMemoById(z.id);const K=Js(U);for(const{path:z,thinos:ne}of K){const J=await de.dealWithDailyThinoBulk(z,ne,"deleteForever");if(!(!H||!B))for(const ee of J)ee&&ee.webId&&await KM(ee.webId)}de.updateTagsState(),Ue.clearQuery(),new N.Notice(E("DELETE SUCCEED"))}catch(U){console.error("error",U),new N.Notice(U.message)}},C=async()=>{if(!(t?.length>0))return;if(!await rs()){Nt();return}const L=[...t];try{const B=L.filter(G=>G.sourceType==="DAILY"),_=L.filter(G=>G.sourceType!=="DAILY"),H=await de.unarchiveThinoBulk(_);for(const G of H)G&&de.editMemo(G);const U=Js(B);for(const{path:G,thinos:K}of U)await de.dealWithDailyThinoBulk(G,K,"restoreFromArchive");new N.Notice(E("RESTORE SUCCEED")),de.updateTagsState(),Ue.clearQuery()}catch(B){console.error("error",B),new N.Notice(B.message)}},k=async()=>{if(!(t?.length>0))return;if(!await rs()){Nt();return}const L=[...t],B=$e.getState().settings.startSync,H=$e.getState().app?.loadLocalStorage("tokenForSync");try{const U=L.filter(z=>z.sourceType==="DAILY"),G=L.filter(z=>z.sourceType!=="DAILY");for(const z of G){const ne=await de.restoreMemoById(z.id);ne&&ne.webId&&H&&B&&await Lm(ne.webId),ne&&de.editMemo(ne)}const K=Js(U);for(const{path:z,thinos:ne}of K){const J=await de.dealWithDailyThinoBulk(z,ne,"restoreFromDelete");for(const ee of J)ee&&ee.webId&&H&&B&&await Lm(ee.webId),ee&&de.editMemo(ee)}de.updateTagsState(),Ue.clearQuery(),new N.Notice(E("RESTORE SUCCEED"))}catch(U){new N.Notice(U.message)}},M=async()=>{if(!(t?.length>0))return;if(!await rs()){Nt();return}const L=[...t];try{const B=L.filter(G=>G.sourceType==="DAILY"),_=L.filter(G=>G.sourceType!=="DAILY"),H=await de.archiveThinoBulk(_);for(const G of H)G&&de.editMemo(G);const U=Js(B);for(const{path:G,thinos:K}of U)await de.dealWithDailyThinoBulk(G,K,"archive");de.updateTagsState(),Ue.clearQuery()}catch(B){console.error("error",B),new N.Notice(B.message)}},I=async()=>{if(t?.length>0){if(!await rs()){Nt();return}new F9e(a,t).open()}},O=async L=>{document.body.toggleClass("thino-share-page",!0),setTimeout(async()=>{if(new N.Notice(E("Image is generating...")),!L){new N.Notice(E("No content to generate."));return}await R9e(L,n),await TA(L);let B;document.body.hasClass("theme-dark")?B="#232323":B="#eaeaea",ES(L,{backgroundColor:B,pixelRatio:window.devicePixelRatio*2}).then(_=>{if(i?.AutoSaveWhenOnMobile&&N.Platform.isMobile){const H=_.split("base64,")[1];dS(H,"image/png").arrayBuffer().then(async G=>{let K;const z="png",ne=Il();for(const J in ne)if(ne[J]instanceof N.TFile){K=ne[J];break}K!==void 0&&await a.vault.createBinary(await vault.getAvailablePathForAttachments(`Pasted Image ${N.moment().format("YYYYMMDDHHmmss")}`,z,K),G)})}document.body.toggleClass("thino-share-page",!1),CS({imgUrl:_}),new N.Notice(E("Image generated successfully.")),L.hasClass("share-image")?L.toggleClass("share-image",!1):L.closest(".share-image").toggleClass("share-image",!1)}).catch(_=>{document.body.toggleClass("thino-share-page",!1),console.error(_)})},0)},R=L=>{const B=new N.Menu;switch(B.addItem(_=>{_.setTitle(E("Clear filter")).setIcon("x").onClick(async()=>{Ue.clearQuery()})}),B.addSeparator(),B.addItem(_=>{_.setTitle(E("Copy filtered thinos")).setIcon("copy").onClick(async()=>{await y()})}),B.addItem(_=>{_.setTitle(E("Share filtered thinos as image")).setIcon("image").onClick(async()=>{const H=document.querySelector(".memolist-container");H.toggleClass("share-image",!0);try{if(n==="calendar"){if(H.find(".rbc-agenda-table")){const U=H.find(".rbc-agenda-table");await O(U)}if(H.find(".rbc-month-view")){const U=H.find(".rbc-month-view");await O(U)}}else if(n==="table"){if(H.find(".thino-table")){const U=H.find(".thino-table");await O(U)}}else await O(H)}catch(U){console.error(U),new N.Notice(E("Failed to generate image.")),H.toggleClass("share-image",!1)}})}),B.addItem(_=>{_.setTitle(E("Merge thinos in to thino share image")).setIcon("image").onClick(async()=>{let H="";t.forEach((G,K)=>{H+=`> [!thino] ${G.createdAt}
|
|
|
${G.content.split(`
|
|
|
`).map(z=>z.trim()?`> ${z}
|
|
|
`:`>
|
|
|
`)}
|
|
|
|
|
|
`+(K===t.length-1?`
|
|
|
|
|
|
`:`
|
|
|
|
|
|
------
|
|
|
|
|
|
`)});const U={createdAt:N.moment().format("YYYY/MM/DD HH:mm:ss"),updatedAt:N.moment().format("YYYY/MM/DD HH:mm:ss"),content:H.replace(/(^|\n),>/g,`
|
|
|
>`),id:"temp-"+Math.random().toString(36).substr(2,9),thinoType:"JOURNAL",sourceType:"DAILY",rowStatus:"NORMAL",visibility:"PRIVATE",pinned:!1,creatorName:"thino",deletedAt:"",path:"",resourceList:[]};yu(U,"clean")})}),B.addSeparator(),o){case"/":B.addItem(_=>{_.setTitle(E("Bulk tag operation")).setIcon("hash").onClick(async()=>{await I()})}).addItem(_=>{_.setTitle(E("Bulk archive")).setIcon("archive").onClick(async()=>{new da(a,E("ARCHIVE"),async H=>{H==="confirm"&&await M()}).open()})}).addItem(_=>{_.setTitle(E("Bulk delete")).setIcon("trash").onClick(async()=>{new da(a,E("DELETE"),async H=>{H==="confirm"&&await S()}).open()})});break;case"/archive":B.addItem(_=>{_.setTitle(E("Bulk restore")).setIcon("archive").onClick(async()=>{new da(a,E("RESTORE"),async H=>{H==="confirm"&&await C()}).open()})}).addItem(_=>{_.setTitle(E("Bulk delete")).setIcon("trash").onClick(async()=>{new da(a,E("DELETE"),async H=>{H==="confirm"&&await S()}).open()})});break;case"/recycle":B.addItem(_=>{_.setTitle(E("Bulk restore")).setIcon("archive-restore").onClick(async()=>{new da(a,E("RESTORE"),async H=>{H==="confirm"&&await k()}).open()})}).addItem(_=>{_.setTitle(E("Bulk delete")).setIcon("trash").onClick(async()=>{new da(a,E("DELETE"),async H=>{H==="confirm"&&await x()}).open()})});break}B.showAtMouseEvent(L.nativeEvent)};return w.jsxs("div",{className:`filter-query-container ${b?"":"thino-hidden"}`,children:[w.jsxs("div",{className:"filter-query",children:[w.jsx("span",{className:"tip-text",children:E("FILTER")}),w.jsxs("div",{"data-filter-type":"query",className:"filter-item-container "+(m?"":"thino-hidden"),onClick:()=>{Ue.setMemoFilter("")},children:[w.jsx("span",{className:"icon-text",children:"🔖"})," ",m?.title]}),w.jsxs("div",{"data-filter-type":"tag",className:"filter-item-container "+(s?"":"thino-hidden"),onClick:()=>{Ue.setTagQuery("")},children:[w.jsx("span",{className:"icon-text",children:"🏷️"})," ",s]}),w.jsxs("div",{"data-filter-type":"type",className:"filter-item-container "+(u?"":"thino-hidden"),onClick:()=>{Ue.setMemoTypeQuery("")},children:[w.jsx("span",{className:"icon-text",children:"📦"})," ",ene(u)]}),l&&l.from<l.to&&w.jsxs("div",{"data-filter-type":"date",className:"filter-item-container",children:[w.jsxs("div",{className:"day-picker-component-group",children:[w.jsx("span",{className:"icon-text",children:"🗓️"})," ",w.jsx(k0,{type:"text",startOrEnd:"start",defaultValue:N.moment(l.from,"x").valueOf(),handleValueChange:L=>{const B=N.moment(l.to,"x"),_=N.moment(L,"x"),H=_.isAfter(B)||_.isSame(B);Ue.setFromAndToQuery(H?B.startOf("day").valueOf():N.moment(L,"x").startOf("day").valueOf(),l.to)}}),w.jsx("span",{children:E("to")}),w.jsx(k0,{type:"text",startOrEnd:"end",defaultValue:N.moment(l.to,"x").add(1,"days").valueOf(),handleValueChange:L=>{const B=N.moment(l.from,"x"),_=N.moment(L,"x"),H=_.isBefore(B)||_.isSame(B),U=N.moment(L,"x").endOf("day").valueOf();Ue.setFromAndToQuery(l.from,H?B.endOf("day").valueOf():U)}})]}),w.jsx("div",{ref:L=>L&&N.setIcon(L,"x"),className:"btn close-btn",onClick:()=>{Ue.setFromAndToQuery(0,0)}})]}),w.jsxs("div",{className:"filter-item-container "+(d?"":"thino-hidden"),onClick:()=>{Ue.setTextQuery("")},children:[w.jsx("span",{className:"icon-text",children:"🔍"})," ",d]}),w.jsxs("div",{className:"filter-item-container "+(p?"":"thino-hidden"),onClick:()=>{Ue.setPathQuery("")},children:[w.jsx("span",{className:"icon-text",children:"📦"})," ",w.jsx("span",{className:"path-text",children:p})]})]}),w.jsxs("div",{className:"thino-filter-items",children:[e&&w.jsx("div",{className:"thinos-count",children:`${e?`${e} Thinos `:""}`}),w.jsx("div",{ref:v,className:"btn memo-action-menu",onClick:R})]})]})},bu=async e=>{const{app:t,settings:n}=$e.getState();if(!n.startSync||!t?.loadLocalStorage("tokenForSync"))return;const r=await mQ(e);if(!r||r.length===0)return;r.sort((a,s)=>N.moment(a.createdAt,"YYYY/MM/DD HH:mm:ss").isAfter(N.moment(s.createdAt,"YYYY/MM/DD HH:mm:ss"))?1:-1);const o=r.filter(a=>!a.deleted),i=r.filter(a=>a.deleted);for(let a=0;a<o.length;a++){const s=o[a],l=await de.createOrPatchThinoFromWeb(s);l&&de.pushMemo(l)}for(let a=0;a<i.length;a++){const s=i[a],l=de.getMemoByWebId(s.id);l&&await de.deleteMemoById(l.id,"local")}de.updateTagsState(),B9e(t)};function H9e(){const{settings:e,app:t,view:n}=$e.getState(),{globalState:{loaded:r,memoListView:o}}=D.useContext(ct),i=N.Platform.isMobile&&e.DefaultEditorLocation==="Bottom",a=Y.useRef(null),[s,l]=Y.useState([]),[u,d]=Y.useState((window.app||t).loadLocalStorage("thinoListView"));D.useEffect(()=>{o===u||!o||(d(o),t&&t?.saveLocalStorage("thinoListView",o))},[o]),D.useEffect(()=>{if(e.SyncManually||!t||!r||!n||!t?.loadLocalStorage("tokenForSync")||!e.startSync)return;a.current=window.setInterval(async()=>{const b=uC(t);await bu(b)},3e4),n.registerInterval(a.current);const m=uC(t);return bu(m),()=>{a.current&&window.clearInterval(a.current)}},[n,t,r,e.startSync]);const h=[w.jsx(Fv,{thinosCount:s.length,thinos:s},"filter"),w.jsx(T9e,{listView:u,updateThinos:p=>{l(p)}},"list")];return w.jsx(w.Fragment,{children:o==="chat"?w.jsx(w.Fragment,{children:[w.jsx(c0,{syncThino:bu},"header"),...h.reverse(),w.jsx(Du,{className:"mod-editor-bottom",editorType:"inline"},"editor")]}):w.jsx(w.Fragment,{children:i?[w.jsx(c0,{syncThino:bu},"header"),...h,w.jsx(Du,{className:"mod-editor-bottom",editorType:"block"},"editor")]:[w.jsx(c0,{syncThino:bu},"header"),w.jsx(Du,{editorType:"block"},"editor"),...h]})})}function _9e(e){try{e?.saveLocalStorage&&e?.saveLocalStorage("thinoLastUpdated",N.moment("2000-01-01 00:01:00","YYYY-MM-DD HH:mm:ss").format("x"))}catch(t){console.error(t)}}function uC(e){try{const t=e?.loadLocalStorage&&e?.loadLocalStorage("thinoLastUpdated");return t||N.moment("2000-01-01 00:01:00","YYYY-MM-DD HH:mm:ss").format("x")}catch(t){return console.error(t),N.moment().format("x")}}function B9e(e){try{e?.saveLocalStorage&&e?.saveLocalStorage("thinoLastUpdated",N.moment().format("x"))}catch(t){console.error(t)}}const Y9e={text:E("SELECT"),value:""},U9e=e=>{const{className:t,dataSource:n,handleValueChanged:r,value:o}=e,[i,a]=wh(!1),s=D.useRef(null);let l=Y9e;for(const h of n)if(h.value===o){l=h;break}D.useEffect(()=>{if(i){const h=p=>{s.current?.contains(p.target)||a(!1)};window.addEventListener("click",h,{capture:!0,once:!0})}},[i]);const u=h=>{r&&r(h.value),a(!1)},d=h=>{h.stopPropagation(),a()};return w.jsxs("div",{className:`selector-wrapper ${t||""}`,ref:s,children:[w.jsxs("div",{className:`current-value-container ${i?"active":""}`,onClick:d,children:[w.jsx("span",{className:"value-text",children:l.text}),w.jsx("span",{ref:h=>{h&&N.setIcon(h,"chevron-right")},className:"btn arrow-text"})]}),w.jsx("div",{className:`items-wrapper ${i?"":"thino-hidden"}`,children:n.map(h=>w.jsx("div",{className:`item-container ${h.value===o?"selected":""}`,onClick:()=>{u(h)},children:h.text},h.value))})]})},uu=D.memo(U9e),xA=e=>{const{destroy:t,queryId:n,type:r="dialog"}=e,[o,i]=D.useState(""),[a,s]=D.useState(r!=="dialog"?[p3()]:[]),l=Dc(!1),[u,d]=D.useState(!1),[h,p]=wh(!1),m=de.getState().memos.filter(I=>!(I.deletedAt!==""&&I.deletedAt)).filter(I=>tne(I,a)).length;D.useEffect(()=>{b()},[n]);const b=()=>{const I=Ct.getQueryById(n??"");if(I){i(I.title);const O=JSON.parse(I.querystring);return Array.isArray(O)&&s(O),I}},v=I=>{const O=I.target.value;i(O)},y=async()=>{if(!o)return new N.Notice(E("TITLE CANNOT BE NULL!")),null;if(a.length===0)return new N.Notice(E("FILTER CANNOT BE NULL!")),null;if(a.length===1&&a[a.length-1].value.value==="")return new N.Notice(E("Please finish the last filter setting first")),null;let I;const O=Ct.getQueryById(n||"");try{n&&!n.startsWith("Filter [Temp] ")&&O.title===o?(I=await Ct.updateQuery(n,o,JSON.stringify(a)),Ct.editQuery(I),await Ct.getMyAllQueries()):(I=await Ct.createQuery(o,JSON.stringify(a)),Ct.pushQuery(I),await Ct.getMyAllQueries())}catch(R){new N.Notice(R.message)}return I},S=async()=>{switch(r){case"modal":case"inline":if(a.length===0){new N.Notice(E("FILTER CANNOT BE NULL!"));return}if(a.length===1&&a[a.length-1].value.value===""){new N.Notice(E("Please finish the last filter setting first"));return}try{const I=Ct.getQueryById(n??"");if(I&&JSON.stringify(a)===I.querystring){Ue.setMemoFilter(I.id),t();return}const O=Ct.createTempQuery(`Filter [Temp] ${Math.random().toString(36).substring(7)}`,JSON.stringify(a));Ct.pushQuery(O),Ue.setMemoFilter(O.id)}catch(I){new N.Notice(I.message)}t();break;case"dialog":try{if(!await y())return}catch(I){console.error(I),new N.Notice(I.message)}t();break}},x=()=>{if(a.length===0){new N.Notice(E("FILTER CANNOT BE NULL!"));return}if(u){Ue.setMemoFilter(""),d(!1);return}const I=Ct.getQueryById(n??"");if(I&&JSON.stringify(a)===I.querystring){Ue.setMemoFilter(I.id);return}const O=Ct.createTempQuery(`Filter [Temp] ${Math.random().toString(36).substring(7)}`,JSON.stringify(a));Ct.pushQuery(O),Ue.setMemoFilter(O.id),e.setPreview&&e.setPreview(O.id),d(!0)},C=()=>{if(a.length>0&&a[a.length-1].value.value===""){new N.Notice(E("Please finish the last filter setting first"));return}s([...a,p3()])},k=D.useCallback((I,O)=>{s(R=>{const L=[...R];return L[I]=O,L})},[]),M=D.useCallback(I=>{s(O=>O.filter((L,B)=>B!==I))},[]);return w.jsxs(w.Fragment,{children:[r==="dialog"&&w.jsxs("div",{className:"dialog-header-container",children:[w.jsxs("span",{className:"title-text",children:[w.jsx("span",{className:"icon-text",children:"🔖"}),E(n?"EDIT QUERY":"CREATE QUERY")]}),w.jsx("button",{ref:I=>{I&&N.setIcon(I,"x")},className:"btn close-btn",onClick:t})]}),w.jsxs("div",{className:"dialog-content-container",children:[(r==="dialog"||h)&&w.jsxs("div",{className:"form-item-container input-form-container",children:[w.jsx("span",{className:"normal-text",children:E("TITLE")}),w.jsx("input",{className:"title-input",type:"text",value:o,onChange:v})]}),w.jsxs("div",{className:"form-item-container filter-form-container",children:[w.jsx("span",{className:"normal-text",children:E("FILTER")}),w.jsxs("div",{className:"filters-wrapper",children:[a.map((I,O)=>w.jsx(V9e,{index:O,filter:I,handleFilterChange:k,handleFilterRemove:M},O)),w.jsx("div",{className:"create-filter-btn",onClick:C,children:E("ADD FILTER TERMS")})]})]})]}),w.jsx("div",{className:"dialog-footer-container",children:w.jsxs("div",{className:"btns-container",children:[(r==="inline"||r==="modal")&&w.jsx("button",{className:`btn ${h?"mod-cta":"save-btn"}`,onClick:async()=>{if(!h)p();else{const I=await y();p(!1),t(),I&&Ue.setMemoFilter(I.id)}},children:E(h?"Set and save":"Save")}),w.jsxs("div",{className:"btns-group-container",children:[w.jsxs("span",{className:`tip-text ${a.length===0&&"thino-hidden"}`,children:[E("MATCH")," Thino ",w.jsx("strong",{children:m})," ",E("TIMES")]}),w.jsx(w.Fragment,{children:r==="inline"&&w.jsx("button",{className:"btn mod-cta",onClick:x,children:E("Preview")})}),w.jsx("button",{className:`btn save-btn ${l.isLoading?"requesting":""}`,onClick:S,children:E(r==="inline"||r==="modal"?"Filter":n?"EDIT":"Save")})]})]})})]})},z9e=e=>{const{index:t,filter:n,handleFilterChange:r,handleFilterRemove:o}=e,{type:i}=n,a=D.useRef(null),s=D.useRef(null),l=D.useRef(n),u=D.useRef(i);D.useEffect(()=>{l.current=e.filter},[n]),D.useEffect(()=>{if(a.current)return i!=="TAG"&&s.current&&(s.current.destroy(),s.current=null,a.current.detach()),i==="TAG"&&!s.current&&(u.current=i,s.current=new Hm(a.current,m)),()=>{s.current&&(s.current.destroy(),s.current=null)}},[a,i]);const d=D.useCallback(y=>{["AND","OR"].includes(y)&&r(t,{...n,relation:y})},[n]),h=D.useCallback(async y=>{if(n.type!==y){const{verifyState:S}=$e.getState(),x=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),C=N.Platform.isDesktop?await Sn():x.identifier||x.uuid,k=S&&S?.appId===C;if((y==="SOURCE"||y==="PATH"||y==="METADATA"||y==="TIME_RANGE")&&!k){Nt();return}const M=Object.values(Za[y].operators);r(t,{...n,type:y,value:{operator:M[0].value,value:y==="METADATA"?{name:"",value:""}:y==="TIME_RANGE"?Za.TIME_RANGE.values[0].value:""}})}},[n]),p=D.useCallback(y=>{r(t,{...n,value:{...n.value,operator:y}})},[n]),m=D.useCallback((y,S="OTHERS")=>{if(S==="OTHERS")r(t,{...l.current,value:{...l.current.value,value:y}});else{const x={...l.current,value:{...l.current.value,value:{...l.current.value.value,[S==="METADATA_NAME"?"name":"value"]:y}}};r(t,x)}},[n]),b=()=>{o(t)},v={TYPE:w.jsx(uu,{className:"value-selector",dataSource:Za.TYPE.values,value:n.value.value,handleValueChanged:m}),LIST:w.jsx(uu,{className:"value-selector",dataSource:Za.LIST.values,value:n.value.value,handleValueChanged:m}),SOURCE:w.jsx(uu,{className:"value-selector",dataSource:Za.SOURCE.values,value:n.value.value,handleValueChanged:m}),PATH:w.jsx("input",{type:"text",className:"value-inputer",value:n.value.value,onChange:y=>{m(y.target.value)}}),METADATA:w.jsxs(w.Fragment,{children:[w.jsx("input",{type:"text",className:"value-inputer",value:n.value.value.name,onChange:y=>{m(y.target.value,"METADATA_NAME")}}),w.jsx("input",{type:"text",className:"value-inputer",value:n.value.value.value,onChange:y=>{m(y.target.value,"METADATA_VALUE")}})]}),TAG:w.jsx("input",{type:"text",id:Math.random().toString(36).substring(7),className:"value-inputer",ref:a,value:n.value.value,onChange:y=>{m(y.target.value)}}),TEXT:w.jsx("input",{type:"text",className:"value-inputer",value:n.value.value,onChange:y=>{m(y.target.value)}}),DATE:w.jsxs("div",{className:"date-inputer",children:[w.jsx(k0,{type:"icon",handleValueChange:m}),w.jsx("input",{type:"text",className:"value-inputer",value:n.value.value,onChange:y=>{m(y.target.value)}})]}),TIME_RANGE:w.jsx(uu,{className:"value-selector",dataSource:Za.TIME_RANGE.values,value:n.value.value,handleValueChanged:m})};return w.jsxs("div",{className:"memo-filter-input-wrapper",children:[t>0&&w.jsx(uu,{className:"relation-selector",dataSource:Qte,value:n.relation,handleValueChanged:d}),w.jsx(uu,{className:"type-selector",dataSource:Object.values(Za),value:n.type,handleValueChanged:h}),w.jsxs(w.Fragment,{children:[Object.keys(Za).includes(i)&&w.jsx(uu,{className:"operator-selector",dataSource:Object.values(Za[i].operators),value:n.value.operator,handleValueChanged:p}),v[i]]}),w.jsx("div",{ref:y=>{y&&N.setIcon(y,"x")},className:"btn remove-btn",onClick:b})]})},V9e=D.memo(z9e);function dC(e){yS({className:"create-query-dialog"},xA,{queryId:e})}const IA=e=>{const{dailyNotesState:{app:t,verifyState:n},locationState:{query:r}}=D.useContext(ct),o=Y.useRef(null),[i,a]=Y.useState(!1),s=Y.useRef(null),[l,u]=Y.useState(""),d=kS(o.current,s.current,{placement:"bottom-start",modifiers:[{name:"offset",options:{offset:[0,10]}}]});D.useEffect(()=>{i&&d.update&&d?.update()},[i]),D.useEffect(()=>{o&&N.setIcon(o.current,"filter")},[o]);const h=async()=>{const m=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),b=N.Platform.isDesktop?await Sn():m.identifier||m.uuid;return!n||n?.appId!==b?(Nt(),!1):!0};return iv(s,()=>{a(!1),l&&Ue.getState().query.filter===l&&Ue.setMemoFilter("")}),w.jsxs(w.Fragment,{children:[w.jsx("div",{className:"thino-inline-filter-wrapper pro",ref:o,onClick:async()=>{await h()&&(N.Platform.isDesktop?(a(!i),await d?.update()):new W9e($e.getState().app,r.filter,b=>{u(b)}).open())}}),w.jsx("div",{ref:s,className:`thino-inline-filter-container ${i?"":"thino-hidden"}`,style:d.styles.popper,children:i&&w.jsx(xA,{type:"inline",queryId:r.filter?.startsWith("Filter [Temp] ")&&!r.filter?.includes("Filter [Temp]")?"":r.filter,destroy:()=>{a(!1)},setPreview:m=>{u(m)}})})]})};class W9e extends N.Modal{constructor(t,n,r){super(t),this.filter=n,this.setPreview=r}root;setPreview;onOpen(){const{contentEl:t}=this;this.root=tv(t),this.root.render(w.jsx(zi,{store:ke,context:ct,children:w.jsx("div",{className:"thino-inline-filter-container",children:w.jsx(xA,{type:"modal",queryId:this.filter?.startsWith("Filter [Temp] ")&&!this.filter?.includes("Filter [Temp]")?"":this.filter,destroy:()=>{this.close()},setPreview:n=>{this.setPreview(n)}})})}))}onClose(){this.root?.unmount()}}const wz=()=>{const{dailyNotesState:{app:e},globalState:{isMobileView:t,showSiderbarInMobileView:n}}=D.useContext(ct),[r]=D.useState(Y.createRef());D.useEffect(()=>{if(!r.current)return;const i=r.current;N.setIcon(i,"refresh-cw")},[r.current]);const o=D.useCallback(async()=>{if(!(t&&n)){if(bu){const i=uC(e);await bu(i)}await de.fetchAllMemos()}},[]);return w.jsx("span",{className:"refresh-icon",ref:r,onClick:()=>{o(),r&&r.current.firstElementChild.toggleClass("rotate-hidden",!0),setTimeout(()=>{r&&r.current.firstElementChild.toggleClass("rotate-hidden",!1)},1e3)}})},c0=()=>{const{locationState:{query:{filter:e}},globalState:{isMobileView:t},queryState:{queries:n}}=D.useContext(ct),[r,o]=D.useState("THINO");D.useEffect(()=>{const a=Ct.getQueryById(e);o(a?a.title:"THINO")},[e,n]);const i=D.useCallback(a=>{a.stopPropagation(),Ze.setShowSiderbarInMobileView(!0)},[]);return w.jsxs("div",{className:"section-header-container memos-header-container",children:[w.jsxs("div",{className:"title-text",children:[w.jsx(il,{when:t,children:w.jsx("button",{ref:a=>{a&&N.setIcon(a,"menu")},className:"btn action-btn clickable-icon",onClick:i})}),w.jsx("span",{className:"normal-text",children:r}),w.jsx(wz,{})]}),w.jsxs("div",{className:"memos-header-search-section",children:[w.jsx(fne,{}),w.jsx(dne,{}),w.jsx(IA,{}),w.jsx(nv,{})]})]})},G9e=()=>{const{dailyNotesState:{settings:e,plugin:t,app:n,verifyState:r},globalState:{manifest:o,showSiderbarInMobileView:i,isMobileView:a}}=D.useContext(ct),[s,l]=D.useState("Memos"),[u,d]=D.useState("");D.useEffect(()=>{if(!e?.MomentsIcon||!n)return;const k=n.vault.adapter.getResourcePath(N.normalizePath(e.MomentsIcon));k&&!e?.MomentsIcon.startsWith("http")?d(k):d(e?.MomentsIcon)},[e?.MomentsIcon,n]),D.useEffect(()=>{e&&l(e.UserName)},[e]);const h=D.useCallback(()=>{Ue.pushHistory("/"),Ue.clearQuery()},[]),p=()=>{n.setting.open(),n.setting.openTabById(o.id||"obsidian-memos")},m=()=>{if(e?.needVerify){Ze.setLocked(!0);return}else new N.Notice(E("You have not set a password or enable this feature yet")),n.setting.open(),n.setting.openTabById(o.id||"obsidian-memos")},b=()=>{new DN(n,o.version).open()},v=()=>{Ze.setShowSiderbarInMobileView(!1),t.settingTab.updateSettings("FirstLoaded",!0)},y=()=>{new GQ(n,t,o.version).open()},S=D.useCallback(async k=>{const{type:M}=k;if(M.startsWith("text"))try{return`${await tD.parseHtml(k)}`}catch(I){new N.Notice(I)}},[]),x=D.useCallback(()=>{const k=document.createElement("input");document.body.appendChild(k),k.type="file",k.multiple=!1,k.accept="text/html",k.onchange=async()=>{if(!k.files||k.files.length===0)return;const M=k.files[0];await S(M),document.body.removeChild(k)},k.click()},[]),C=k=>{const M=new N.Menu;M.addItem(I=>{I.setIcon("user").setTitle(E("Settings")).onClick(p)}),e?.needVerify&&M.addItem(I=>{I.setIcon("lock").setTitle(E("Lock")).onClick(m)}),M.addItem(I=>{I.setIcon("import").setTitle(E("Import")).onClick(x)}),M.addSeparator(),M.addItem(I=>{I.setIcon("file-text").setTitle(E("ChangeLog")).onClick(b)}),M.addItem(I=>{I.setIcon("settings").setTitle(E("Setting guide")).onClick(v)}),M.addItem(I=>{I.setIcon("alert-circle").setTitle(E("Submit issue")).onClick(y)}),M.showAtMouseEvent(k.nativeEvent)};return w.jsxs("div",{className:"user-banner-container",children:[w.jsxs("div",{className:"userinfo-header-container",children:[w.jsxs("div",{className:"userinfo-container",onClick:()=>{n.setting.open(),n.setting.openTabById(o.id||"obsidian-memos")},children:[w.jsx("div",{ref:k=>{if(u){k?.empty();return}u||k&&N.setIcon(k,"Memos")},className:"thino-user-icon",style:{backgroundImage:`url("${u}")`}}),w.jsxs("div",{className:"thino-user-info",children:[w.jsxs("span",{className:"username-container",children:[w.jsx("span",{"aria-label":s==="MEMO 😉"?"THINO 😉":s||"THINO",className:"username-text",onClick:h,children:s==="MEMO 😉"?"THINO 😉":s||"THINO"}),w.jsx("span",{className:`user-pro-badge ${r?"activated":""}`,onClick:()=>{n.setting.open(),n.setting.openTabById(o.id||"obsidian-memos")},children:"PRO"})]}),e?.MomentsQuote&&w.jsx("span",{className:"thino-user-quote",children:e?.MomentsQuote})]})]}),w.jsxs("span",{className:"btn-group",children:[e?.DefaultThemeForThino==="modern"&&!a&&w.jsx(wz,{}),w.jsx("span",{ref:k=>{k&&k.hasChildNodes()||k&&N.setIcon(k,"more-horizontal")},className:"btn action-btn menu-popup-btn",onClick:C}),i&&w.jsx("span",{ref:k=>{k&&k.hasChildNodes()||k&&N.setIcon(k,"x")},className:"btn action-btn close-sidebar-btn",onClick:()=>{Ze.setShowSiderbarInMobileView(!1)}})]})]}),w.jsx(sD,{statusType:"banner"})]})},Z9e=D.memo(({query:e,className:t})=>{const{memoState:{memos:n},dailyNotesState:{plugin:r}}=D.useContext(ct),[o,i]=D.useState(null),[a,s]=D.useState(!1),[l,u]=D.useState(!1),d=D.useRef(null);return D.useEffect(()=>{e&&r&&r.thinoWorkerManager.filterMemos(n,{tag:"",duration:null,type:"",text:"",path:"",metadata:{},filter:e.id}).then(h=>{i(h.length),u(!0)}).catch(h=>{console.error("Error calculating query count:",h),i(0)}).finally(()=>{s(!1)})},[e,r,n]),w.jsx("div",{className:tn("query-count",a?"loading":"loaded",t),ref:d,children:l&&o!==null&&w.jsx("span",{className:"count-text",children:o.toString()||""})})},(e,t)=>e.query.id===t.query.id),f5=()=>{const{queryState:{queries:e},dailyNotesState:{app:t},locationState:{query:{filter:n}}}=D.useContext(ct),r=Dc(),[o,i]=D.useState([]),[a,s]=D.useState(t?.loadLocalStorage("thino-query-sort-order")||"byTime");D.useEffect(()=>{const d=e.filter(h=>!h.id?.toString().startsWith("Filter [Temp]")&&!h.id?.toString().includes("Filter [Temp]")).sort((h,p)=>{if(p.pinnedAt&&!h.pinnedAt)return 1;if(h.pinnedAt&&!p.pinnedAt)return-1;switch(a){case"alphabetical":return h.title.localeCompare(p.title);case"alphabeticalReverse":return p.title.localeCompare(h.title);case"byTime":return Le.getTimeStampByDate(p.createdAt)-Le.getTimeStampByDate(h.createdAt);case"byTimeReverse":return Le.getTimeStampByDate(h.createdAt)-Le.getTimeStampByDate(p.createdAt);default:return 0}});i(d)},[e,a]),D.useEffect(()=>{Ct.getMyAllQueries().catch(()=>{}).finally(()=>{r.setFinish()})},[t]);const l=u=>{u.stopPropagation();const d=new N.Menu;for(const h of["alphabetical","alphabeticalReverse","byTime","byTimeReverse"])d.addItem(p=>{p.setTitle(E(h)).onClick(()=>{s(h),t?.saveLocalStorage("thino-query-sort-order",h)}).setChecked(a===h)}),h==="alphabeticalReverse"&&d.addSeparator();d.showAtMouseEvent(u.nativeEvent)};return w.jsxs("div",{className:"queries-wrapper",children:[w.jsxs("div",{className:"title-text",children:[w.jsx("span",{className:"normal-text",children:E("QUERY")}),w.jsxs("div",{className:"sort-btn-container",children:[w.jsx("span",{ref:u=>{u&&N.setIcon(u,"arrow-down-narrow-wide")},className:"sort-btn",onClick:l}),w.jsx("span",{ref:u=>{u&&N.setIcon(u,"plus")},className:"btn create-query-btn",onClick:()=>dC()})]})]}),w.jsx(il,{when:r.isSucceed&&o.length===0,children:w.jsx("div",{className:"create-query-btn-container",children:w.jsx("span",{className:"btn",onClick:()=>dC(),children:E("CREATE FILTER")})})}),w.jsx("div",{className:"queries-container",children:o.map(u=>w.jsx($9e,{query:u,isActive:u.id===n},`${u.id}-${N.moment(u.createdAt,"YYYY/MM/DD HH:mm:ss").format("x")}`))})]})},$9e=e=>{const{query:t,isActive:n}=e,r=()=>{Ue.setMemoFilter(n?"":t.id)},o=i=>{i.stopPropagation();const a=new N.Menu;a.addItem(s=>{s.setTitle(t.pinnedAt?E("UNPIN"):E("PIN")).setIcon(t.pinnedAt?"pin-off":"pin").onClick(async()=>{try{t.pinnedAt?await Ct.unpinQuery(t.id):await Ct.pinQuery(t.id),Ct.editQuery({...t,pinnedAt:t.pinnedAt?"":Le.getDateTimeString(Date.now())})}catch(l){console.error(l)}})}),a.addItem(s=>{s.setTitle(E("EDIT")).setIcon("edit").onClick(()=>{dC(t.id)})}),a.addItem(s=>{s.setTitle(E("DUPLICATE")).setIcon("copy").onClick(async()=>{try{const l=Ct.getQueryById(t.id);if(l){const u=`${l.title} ${E("DUPLICATE")}`,d=await Ct.createQuery(u,l.querystring);Ct.pushQuery(d),await Ct.getMyAllQueries(),new N.Notice(`Query "${u}" created successfully`)}}catch(l){console.error(l),new N.Notice(`Failed to duplicate query: ${l.message}`)}})}),a.addItem(s=>{s.setTitle(E("DELETE")).setIcon("trash-2").setWarning(!0).onClick(()=>{const l=new N.Menu;l.addItem(u=>{u.setTitle(E("CONFIRM!")).setIcon("trash-2").setWarning(!0).onClick(async()=>{try{await Ct.deleteQuery(t.id)}catch(d){new N.Notice(d.message)}})}),l.addItem(u=>{u.setTitle(E("Cancel")).setIcon("x").onClick(()=>{})}),l.showAtMouseEvent(i.nativeEvent)})}),a.showAtMouseEvent(i.nativeEvent)};return w.jsx(w.Fragment,{children:w.jsxs("div",{className:`query-item-container ${n?"active":""}`,onClick:r,children:[w.jsxs("div",{className:"query-text-container",children:[w.jsx("span",{ref:i=>{i&&!i.hasChildNodes()&&N.setIcon(i,"filter")},className:"icon-text"}),w.jsxs("span",{className:"query-text",children:[t.title,t.pinnedAt&&" 📌"]})]}),w.jsxs("div",{className:"btns-container",children:[w.jsx(Z9e,{query:t}),w.jsx("span",{ref:i=>{i&&!i.hasChildNodes()&&N.setIcon(i,"more-horizontal")},className:"btn action-btn toggle-btn",onClick:o})]})]})})},h5=()=>{const{locationState:{query:{tag:e,filter:t}},dailyNotesState:{app:n},memoState:{tags:r,tagsNum:o,memos:i}}=D.useContext(ct),[a,s]=D.useState(!0),l=D.useMemo(()=>t&&t?.toString()?.startsWith("Filter [Temp] ")&&Ct.getQueryById(t),[t]),[u,d]=D.useState([]),[h,p]=D.useState((n||window.app)?.loadLocalStorage("thino-tag-sort-order")||"alphabetical");D.useEffect(()=>{s(!0);const y=(n||window.app)?.loadLocalStorage("thino-temp-tags");if(y?.tags?.length>0){const S=m(y.tags||[],y.tagsNum||{});d(S.subTags)}s(!1)},[]),D.useEffect(()=>{de.initialized&&de.updateTagsState()},[i]),D.useEffect(()=>{if(!r?.length)return;s(!0);const y=requestAnimationFrame(()=>{const S=m(r,o);d(S.subTags),(n||window.app)?.saveLocalStorage("thino-temp-tags",{tags:r,tagsNum:o}),s(!1)});return()=>cancelAnimationFrame(y)},[r,o]);const m=D.useCallback((y,S)=>{const x=Array.from(y).sort();if(x.length===0)return{key:"",text:"",count:0,subTags:[]};const C={key:"",text:"",count:0,subTags:[]},k=new Map;for(const M of x){const I=M.split("/");let O=C,R="";for(let L=0;L<I.length;L++){const B=I[L];R+=L===0?B:"/"+B;let _=k.get(R);if(_||(_=O.subTags.find(H=>H.text===R)),_||(_={key:B,text:R,count:S[R]||0,subTags:[],parent:O},O.subTags.push(_),k.set(R,_)),L===I.length-1){let H=_.parent;for(;H;)H.count||(H.count=0),H.count+=S[R]||0,H=H.parent}O=_}}return C},[]),b=y=>{y.stopPropagation();const S=new N.Menu;for(const x of["alphabetical","alphabeticalReverse","byCount","byCountReverse"])S.addItem(C=>{C.setTitle(E(x)).onClick(()=>{p(x),n?.saveLocalStorage("thino-tag-sort-order",x)}).setChecked(h===x)}),x==="alphabeticalReverse"&&S.addSeparator();S.showAtMouseEvent(y.nativeEvent)},v=D.useMemo(()=>[...u].sort(q9e(h)),[u,h]);return w.jsxs("div",{className:"tags-wrapper",children:[w.jsxs("div",{className:"tags-header title-text",children:[w.jsx("span",{className:"normal-text",children:E("Frequently Used Tags")}),w.jsx("span",{ref:y=>{y&&N.setIcon(y,"arrow-down-narrow-wide")},className:"tags-sort-btn",onClick:b})]}),w.jsx("div",{className:"tags-container",children:a?w.jsx("div",{className:"tag-loading",children:"Loading..."}):w.jsxs(w.Fragment,{children:[v.map((y,S)=>w.jsx(Sz,{tag:y,tagQuery:e,filterQuery:l},y.text+"-"+S)),w.jsx(il,{when:u.length<5&&de.initialized,children:w.jsxs("span",{className:"tag-tip-container",children:[E("Input")," ",w.jsxs("span",{className:"code-text",children:[E("#Tag")," "]}),E("to create tag"),"..."]})})]})})]})},Sz=Y.memo(e=>{const{tag:t,tagQuery:n,filterQuery:r}=e,o=D.useMemo(()=>n===t.text||r&&JSON.parse(r.querystring).find(d=>d.type==="TAG"&&d.value.value===t.text),[t.text,n,r]),i=t.subTags.length>0,[a,s]=wh(!1),l=async d=>{if(d.ctrlKey||d.metaKey){const{verifyState:h}=$e.getState(),p=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),m=N.Platform.isDesktop?await Sn():p.identifier||p.uuid;if(!(h&&h?.appId===m)){Nt();return}const v=Ue.getState().query.filter;if(v&&v?.startsWith("Filter [Temp] ")){const S=Ct.getQueryById(v).querystring,x=JSON.parse(S);let C;if(x.some(k=>k.type==="TAG"&&k.value.value===t.text)){if(C=x.filter(M=>M.value.value!==t.text),C.length===0){Ue.setMemoFilter("");return}const k=Ct.createTempQuery(`Filter [Temp] ${Math.random().toString(36).substring(7)}`,JSON.stringify([{...C[0],relation:"AND"},...C.slice(1)]));Ct.pushQuery(k),Ue.setMemoFilter(k.id)}else{C=[...x,{type:"TAG",value:{value:t.text,operator:"CONTAIN"},relation:"OR"}];const k=Ct.createTempQuery(`Filter [Temp] ${Math.random().toString(36).substring(7)}`,JSON.stringify(C));Ct.pushQuery(k),Ue.setMemoFilter(k.id)}}else if(n){Ue.setTagQuery("");const y=Ct.createTempQuery(`Filter [Temp] ${Math.random().toString(36).substring(7)}`,JSON.stringify([{type:"TAG",value:{value:n,operator:"CONTAIN"},relation:"AND"},{type:"TAG",value:{value:t.text,operator:"CONTAIN"},relation:"OR"}]));Ct.pushQuery(y),Ue.setMemoFilter(y.id)}else if(!n){const y=Ct.createTempQuery(`Filter [Temp] ${Math.random().toString(36).substring(7)}`,JSON.stringify([{type:"TAG",value:{value:t.text,operator:"CONTAIN"},relation:"AND"}]));Ct.pushQuery(y),Ue.setMemoFilter(y.id)}Le.copyTextToClipboard(`#${t.text} `),["/","/recycle","/archive","/daily"].includes(Ue.getState().pathname)||Ue.setPathname("/");return}if(o){if(Ue.setTagQuery(""),r){const p=JSON.parse(r.querystring).filter(b=>b.value.value!==t.text);if(p.length===0){Ue.setMemoFilter("");return}const m=Ct.createTempQuery(`Filter [Temp] ${Math.random().toString(36).substring(7)}`,JSON.stringify([{...p[0],relation:"AND"},...p.slice(1)]));Ct.pushQuery(m),Ue.setMemoFilter(m.id)}}else await Le.copyTextToClipboard(`#${t.text} `),["/","/recycle","/archive","/daily"].includes(Ue.getState().pathname)||Ue.setPathname("/"),Ue.setTagQuery(t.text)},u=d=>{d.stopPropagation(),s()};return w.jsxs(w.Fragment,{children:[w.jsxs("div",{className:`tag-item-container ${o?"active":""}`,onClick:l,children:[w.jsxs("div",{className:"tag-text-container",children:[w.jsx("span",{ref:d=>{d&&N.setIcon(d,"hash")},className:"btn tag-btn"}),w.jsx("span",{className:"tag-text",children:t.key})]}),w.jsxs("div",{className:"btns-container",children:[w.jsx("span",{className:"tag-count",children:t.count}),i?w.jsx("span",{ref:d=>{d&&N.setIcon(d,"chevron-right")},className:`btn action-btn toggle-btn ${a?"shown":""}`,onClick:u}):null]})]}),i&&a&&w.jsx("div",{className:"subtags-container",children:t.subTags.map((d,h)=>w.jsx(Sz,{tag:d,tagQuery:n,filterQuery:r},d.text+"-"+h))})]})}),p5=new Intl.Collator(void 0,{usage:"sort",sensitivity:"base",numeric:!0}).compare,dk={alphabetical:(e,t)=>p5(e.text,t.text),alphabeticalReverse:(e,t)=>-p5(e.text,t.text),byCount:(e,t)=>t.count-e.count,byCountReverse:(e,t)=>e.count-t.count},q9e=(e="byCount")=>dk.hasOwnProperty(e)?dk[e]:dk.alphabetical,m5=()=>{const{dailyNotesState:{app:e,settings:t,verifyState:n}}=D.useContext(ct),r=[{name:E("Random Review"),path:"/review",iconID:"star"},{name:E("Stat"),path:"/stat",iconID:"chart-bar"},{name:E("ARCHIVE"),path:"/archive",iconID:"archive"},{name:E("Recycle bin"),path:"/recycle",iconID:"recycle"}],o=D.useRef([]);return D.useEffect(()=>{o.current.forEach((i,a)=>{i&&N.setIcon(i,r[a].iconID)})},[t,o]),w.jsx(w.Fragment,{children:w.jsx("div",{className:"path-entry-wrapper",children:r.map((i,a)=>w.jsx(w.Fragment,{children:w.jsxs("div",{className:`path-entry-container ${Ue.getState().pathname===i.path?"active":""} ${t.DeleteThinoDirectly&&i.path==="/recycle"?"thino-hidden":""} ${i.path==="/review"||i.path==="/daily-review"||i.path==="/stat"?"pro":""}`,onClick:async()=>{const s=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),l=N.Platform.isDesktop?await Sn():s.identifier||s.uuid;if(!n&&n?.appId!==l&&(i.path==="/review"||i.path==="/daily-review"||i.path==="/stat")){Nt();return}if(Ue.setPathname(i.path),i.path==="/review"&&Ue.getState().pathname==="/review"){e.workspace.trigger("refresh-review-memos");return}Ue.clearQuery()},children:[w.jsx("span",{ref:s=>o.current[a]=s,className:"path-entry-icon"}),w.jsx("span",{className:"path-entry-text",children:i.name})]},a)}))})})},g5=e=>{const{dailyNotesState:{settings:t},locationState:n,globalState:{isMobileView:r,showSiderbarInMobileView:o}}=D.useContext(ct),i=D.useRef(null),a=D.useMemo(()=>s=>{const l=Ze.getState().showSiderbarInMobileView;if(!l){window.removeEventListener("click",a,{capture:!0});return}const u=s.target;!u.closest(".close-sidebar-btn")&&u.closest(".memos-sidebar-wrapper")||i.current?.contains(s.target)||i.current?.parentNode?.contains(s.target)&&(l&&s.stopPropagation(),Ze.setShowSiderbarInMobileView(!1),window.removeEventListener("click",a,{capture:!0}))},[]);return D.useEffect(()=>{Ze.setShowSiderbarInMobileView(!1)},[n]),D.useEffect(()=>{o?document.body.classList.add(HP):document.body.classList.remove(HP)},[o]),D.useEffect(()=>{r&&o&&window.addEventListener("click",a,{capture:!0})},[r,o]),w.jsxs("aside",{className:tn("memos-sidebar-wrapper",e.className),ref:i,children:[e.children,w.jsx(G9e,{}),t?.DefaultThemeForThino==="modern"&&!r?e?.sidebarPosition==="right"?w.jsx(_m,{}):null:w.jsx(_m,{}),t?.DefaultThemeForThino==="modern"&&!r?e?.sidebarPosition==="left"?w.jsxs(w.Fragment,{children:[w.jsx(m5,{}),w.jsx(f5,{}),w.jsx(sD,{statusType:"sidebar"})]}):null:w.jsxs(w.Fragment,{children:[w.jsx(m5,{}),w.jsx(f5,{})]}),t?.DefaultThemeForThino==="modern"&&!r?e?.sidebarPosition==="right"?w.jsx(w.Fragment,{children:w.jsx(h5,{})}):null:w.jsx(w.Fragment,{children:w.jsx(h5,{})})]})},K9e=()=>{const{dailyNotesState:{settings:e}}=D.useContext(ct),[t,n]=Y.useState(""),r=o=>{n(o.target.value)};return w.jsx("div",{className:"locked-screen-wrapper",children:w.jsxs("div",{className:"locked-screen-content",children:[w.jsx("div",{className:"locked-screen-header",children:w.jsx("div",{className:"locked-screen-header-title",children:E("Locked")})}),w.jsx("div",{className:"locked-screen-body",children:w.jsxs("div",{className:"locked-screen-body-content",children:[w.jsxs("div",{className:"locked-screen-body-content-text",children:[w.jsx("div",{className:"locked-screen-body-content-text-title",children:E("Thino is locked")}),w.jsx("div",{className:"locked-screen-body-content-text-desc",children:E("Please unlock Thino by input password")})]}),w.jsxs("div",{className:"locked-screen-body-content-inputer",children:[w.jsx("input",{onKeyDown:o=>{o.key==="Enter"&&(e?.password===t?Ze.setLocked(!1):new N.Notice(E("Password is incorrect")))},onChange:r,value:t,type:"password",className:"locked-screen-body-content-input"}),w.jsx("button",{className:"locked-screen-body-content-btn",onClick:()=>{e?.password===t?Ze.setLocked(!1):new N.Notice(E("Password is incorrect"))},children:E("Unlock")})]})]})})]})})};class pu extends JH{fuzzySearchItemsOptimized(t,n){const r=N.prepareFuzzySearch(t);return n.map(o=>{const i=r(o.path);return i?{item:o,match:i,score:i.score}:null}).sort((o,i)=>i?.score-o?.score).filter(Boolean)}getSuggestions(t){const r=app.vault.getFiles().filter(i=>["png","jpg","jpeg","gif"].includes(i.extension)),o=t.toLowerCase();return this.fuzzySearchItemsOptimized(o,r).map(i=>i.item)}renderSuggestion(t,n){const r=t.basename,o=t.parent?.path||"";n.toggleClass("thino-image-suggest-item",!0),n.createSpan({cls:"suggestion-name",text:r}),n.createSpan({cls:"suggestion-path",text:o})}selectSuggestion(t){this.inputEl.value=t.path,this.inputEl.trigger("input"),this.close()}}const X9e=e=>{const{dailyNotesState:{settings:t,app:n,plugin:r},globalState:{manifest:o}}=D.useContext(ct),[i,a]=Y.useState(0),[s,l]=Y.useState(""),u=Y.useRef(null),d=Y.useRef(null),[h,p]=Y.useState({enabled:!1,path:"",format:""});D.useEffect(()=>{if(i===2&&t?.EnabledLocationList.find(y=>y.value==="DAILY"))if(!Om())p({enabled:!1,path:"",format:""});else{const y=uc().folder,S=uc().format;p({enabled:!0,path:y,format:S})}},[i]),D.useEffect(()=>{if(!t?.MomentsIcon||!n){l("");return}const y=n.vault.adapter.getResourcePath(N.normalizePath(t.MomentsIcon));y&&!t?.MomentsIcon.startsWith("http")?l(y):l(t?.MomentsIcon)},[t?.MomentsIcon,n]),D.useEffect(()=>{d&&(d.current=null)},[i]),D.useEffect(()=>{u.current&&(d.current||(d.current=new pu(u.current)))},[u.current]);const m=(y,S)=>{let x=r;x||(x=n.plugins.getPlugin("obsidian-memos")),x.settingTab.updateSettings(y,S)},b=D.useMemo(()=>{switch(i){case 0:return w.jsxs(w.Fragment,{children:[w.jsx("h1",{children:E("Get started with Thino")}),w.jsx("p",{children:E("Set up your user info for Thino.")})]});case 1:return w.jsxs(w.Fragment,{children:[w.jsx("h1",{children:E("Set theme for Thino")}),w.jsx("p",{children:E("Choose a theme for Thino.")})]});case 2:return w.jsxs(w.Fragment,{children:[w.jsx("h1",{children:E("Go with daily note plugin")}),w.jsx("p",{children:E("If you are using the Thino basic version, enabling the daily note plugin is required. Configure its settings to work effectively with it.")})]});case 3:return w.jsxs(w.Fragment,{children:[w.jsx("h1",{children:E("Set preferences for using Thino")}),w.jsx("p",{children:E("Adjust settings that influence your user experience with Thino.")})]});case 4:return w.jsxs(w.Fragment,{children:[w.jsx("h1",{children:E("Congrats! All settings done")}),w.jsx("p",{children:E("Go and enjoy Thino")})]})}},[i]),v=()=>{switch(i){case 0:return w.jsxs(w.Fragment,{children:[w.jsx("div",{className:"thino-user-preview-wrapper",children:w.jsxs("div",{className:"userinfo-container",onClick:()=>{n.setting.open(),n.setting.openTabById(o.id||"obsidian-memos")},children:[w.jsx("div",{ref:y=>{if(t?.MomentsIcon){y?.empty();return}t?.MomentsIcon||y&&N.setIcon(y,"Memos")},className:"thino-user-icon",style:{backgroundImage:`url("${s}")`}}),w.jsxs("div",{className:"thino-user-info",children:[w.jsx("span",{className:"username-container",children:w.jsx("span",{"aria-label":t?.UserName==="MEMO 😉"?"THINO 😉":t?.UserName||"THINO",className:"username-text",children:t?.UserName==="MEMO 😉"?"THINO 😉":t?.UserName||"THINO"})}),t?.MomentsQuote&&w.jsx("span",{className:"thino-user-quote",children:t?.MomentsQuote})]})]})}),w.jsxs("div",{className:"thino-user-info-wrapper",children:[w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("User name")}),w.jsx("div",{className:"setting-item-description",children:E("Set your user name here. 'Memos 😏' By default")})]}),w.jsx("div",{className:"setting-item-control",children:w.jsx("input",{type:"text",placeholder:"Thino 😏",defaultValue:t?.UserName,onInput:y=>m("UserName",y.currentTarget.value)})})]}),w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("User quote")}),w.jsx("div",{className:"setting-item-description",children:E("Set user quote for thino")})]}),w.jsx("div",{className:"setting-item-control",children:w.jsx("input",{type:"text",placeholder:"Share thino with the world",defaultValue:t?.MomentsQuote,onInput:y=>m("MomentsQuote",y.currentTarget.value)})})]}),w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("User icon")}),w.jsx("div",{className:"setting-item-description",children:E("Set user icon for thino. You can input http/https link or file path in vault.")})]}),w.jsx("div",{className:"setting-item-control",children:w.jsx("input",{type:"text",ref:u,placeholder:"Input url or file path",defaultValue:t?.MomentsIcon,onInput:y=>m("MomentsIcon",y.currentTarget.value)})})]})]})]});case 1:return w.jsx(w.Fragment,{children:w.jsxs("div",{className:tn("theme-selector-group","selected"),children:[w.jsxs("div",{className:tn("theme-selector",t?.DefaultThemeForThino==="modern"?"selected":""),onClick:()=>m("DefaultThemeForThino","modern"),children:[w.jsxs("div",{className:"theme-selector-header-component",children:[w.jsx("div",{className:"theme-selector-header",children:E("Modern")}),w.jsx("div",{className:"theme-selector-description",children:E("A modern theme for Thino with a three-column layout and some unique features.")})]}),w.jsxs("div",{className:"theme-selector-content",children:[w.jsx("div",{className:"left-column column-component"}),w.jsx("div",{className:"center-column column-component"}),w.jsx("div",{className:"right-column column-component"})]}),w.jsx("div",{className:"theme-selector-footer",children:w.jsx("button",{className:"mod-cta",disabled:t?.DefaultThemeForThino==="modern",onClick:()=>m("DefaultThemeForThino","modern"),children:t?.DefaultThemeForThino==="modern"?E("Selected"):E("Select")})})]}),w.jsxs("div",{className:tn("theme-selector",t?.DefaultThemeForThino==="classic"?"selected":""),onClick:()=>m("DefaultThemeForThino","classic"),children:[w.jsxs("div",{className:"theme-selector-header-component",children:[w.jsx("div",{className:"theme-selector-header",children:E("Classic")}),w.jsx("div",{className:"theme-selector-description",children:E("A classic theme for Thino with a two-column layout")})]}),w.jsxs("div",{className:"theme-selector-content",children:[w.jsx("div",{className:"left-column column-component"}),w.jsx("div",{className:"center-column column-component"})]}),w.jsx("div",{className:"theme-selector-footer",children:w.jsx("button",{className:"mod-cta",disabled:t?.DefaultThemeForThino==="classic",onClick:()=>m("DefaultThemeForThino","classic"),children:t?.DefaultThemeForThino==="classic"?E("Selected"):E("Select")})})]})]})});case 2:return w.jsxs(w.Fragment,{children:[w.jsxs("div",{className:"daily-note-plugin-status",children:[w.jsxs("div",{className:"daily-note-plugin-status-header",children:[w.jsx("div",{className:"plugin-status-header",children:E("Daily note plugin")}),w.jsx("div",{className:"plugin-status-description",children:E("Enable daily note plugin")})]}),w.jsx("div",{className:"daily-note-plugin-status-content",children:h.enabled&&w.jsx(w.Fragment,{children:w.jsxs("div",{className:"daily-note-format",children:[w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("Daily note name format")}),w.jsx("div",{className:"setting-item-description",children:E("Set daily note name format")})]}),w.jsx("div",{className:"setting-item-control",children:w.jsx("input",{type:"text",placeholder:"YYYY-MM-DD",defaultValue:h.format,onInput:y=>{p({...h,format:y.currentTarget.value.trim()});try{const S=n.internalPlugins.getPluginById("daily-notes");S.instance.options={...S.instance.options,format:y.currentTarget.value.trim()},S.saveData({...S.instance.options,format:y.currentTarget.value.trim()})}catch(S){console.error(S)}}})})]}),w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("Daily notes folder")}),w.jsx("div",{className:"setting-item-description",children:E("Set daily notes folder")})]}),w.jsx("div",{className:"setting-item-control",children:w.jsx("input",{type:"text",placeholder:"YYYY-MM-DD",defaultValue:h.path,onInput:y=>{p({...h,path:y.currentTarget.value.trim()});try{const S=n.internalPlugins.getPluginById("daily-notes");S.instance.options={...S.instance.options,folder:y.currentTarget.value.trim()},S.saveData({...S.instance.options,folder:y.currentTarget.value.trim()})}catch(S){console.error(S)}}})})]})]})})}),w.jsxs("div",{className:"daily-note-plugin-status-footer",children:[!h.enabled&&w.jsx("div",{className:"notice-click",children:E("Click to enable =>")}),w.jsx("button",{className:"mod-cta",disabled:h.enabled,onClick:()=>{if(!h.enabled){n.internalPlugins.getPluginById("daily-notes").enable();const y=uc().folder,S=uc().format;p({enabled:!0,format:S,path:y})}},children:h.enabled?E("Enabled"):E("Enable")})]})]}),w.jsxs("div",{className:"thino-daily-settings-wrapper",children:[w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("Default time prefix")}),w.jsx("div",{className:"setting-item-description",children:E("Set default time prefix for thino in daily notes.")})]}),w.jsx("div",{className:"setting-item-control",children:w.jsxs("select",{className:"dropdown",defaultValue:t?.DefaultTimePrefix,onChange:y=>m("DefaultTimePrefix",y.currentTarget.value),children:[w.jsx("option",{value:"HH:mm",children:"HH:mm"}),w.jsx("option",{value:"HH:mm:ss",children:"HH:mm:ss"})]})})]}),w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("Set thino insert place")}),w.jsx("div",{className:"setting-item-description",children:E("Set where to insert thino content")})]}),w.jsx("div",{className:"setting-item-control",children:w.jsxs("select",{className:"dropdown",defaultValue:t?.InsertType,onChange:y=>m("InsertType",y.currentTarget.value),children:[w.jsx("option",{value:"end",children:E("End of the diary")}),w.jsx("option",{value:"custom",children:E("Custom location")})]})})]}),t?.InsertType==="custom"&&w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("Insert after heading")}),w.jsx("div",{className:"setting-item-description",children:E("If left blank, the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.")})]}),w.jsx("div",{className:"setting-item-control",children:w.jsx("input",{type:"text",placeholder:"# Heading",defaultValue:t?.InsertAfter,onInput:y=>m("InsertAfter",y.currentTarget.value)})})]}),w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("Set process target")}),w.jsx("div",{className:"setting-item-description",children:E("You can set whole diary or only part of it")})]}),w.jsx("div",{className:"setting-item-control",children:w.jsxs("select",{className:"dropdown",defaultValue:t?.ProcessContentTarget,onChange:y=>m("ProcessContentTarget",y.currentTarget.value),children:[w.jsx("option",{value:"custom",children:E("Custom")}),w.jsx("option",{value:"whole",children:E("Whole diary")})]})})]}),t?.ProcessContentTarget==="custom"&&w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("Process Memos below")}),w.jsx("div",{className:"setting-item-description",children:E("If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.")})]}),w.jsx("div",{className:"setting-item-control",children:w.jsx("input",{type:"text",placeholder:"# Heading",defaultValue:t?.ProcessEntriesBelow,onInput:y=>m("ProcessEntriesBelow",y.currentTarget.value)})})]})]})]});case 3:return w.jsx(w.Fragment,{children:w.jsxs("div",{className:"thino-custom-settings-wrapper",children:[w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("Default prefix when save thino")}),w.jsx("div",{className:"setting-item-description",children:E("Set the default prefix when create memo, 'List' by default.")})]}),w.jsx("div",{className:"setting-item-control",children:w.jsxs("select",{className:"dropdown",defaultValue:t?.DefaultPrefix,onChange:y=>m("DefaultPrefix",y.currentTarget.value),children:[w.jsx("option",{value:"List",children:E("List")}),w.jsx("option",{value:"Task",children:E("Task")})]})})]}),w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("Use Tags In Vault")}),w.jsx("div",{className:"setting-item-description",children:E("Use tags in vault rather than only in Memos. False by default.")})]}),w.jsx("div",{className:"setting-item-control",ref:y=>{y&&(y.hasChildNodes()||new N.ToggleComponent(y).setValue(t?.UseVaultTags===void 0?!1:t?.UseVaultTags).onChange(S=>{m("UseVaultTags",S)}))}})]}),w.jsxs("div",{className:"setting-item",children:[w.jsxs("div",{className:"setting-item-info",children:[w.jsx("div",{className:"setting-item-name",children:E("Delete Thino Directly")}),w.jsx("div",{className:"setting-item-description",children:E("When delete thino directly, it will not be moved to trash. False by default.")})]}),w.jsx("div",{className:"setting-item-control",ref:y=>{y&&(y.hasChildNodes()||new N.ToggleComponent(y).setValue(t?.DeleteThinoDirectly===void 0?!1:t?.DeleteThinoDirectly).onChange(S=>{m("DeleteThinoDirectly",S)}))}})]})]})});case 4:return w.jsx(w.Fragment,{children:w.jsxs("div",{className:"thino-congrats",children:[w.jsxs("div",{className:"final-congrats-text",children:[w.jsx("p",{className:"ready-use",children:E("Thino is ready to use. ")}),w.jsx("p",{className:"start-to-use",children:E("You can start using Thino now. If you want to know more about Thino Pro, click the button below.")})]}),w.jsxs("div",{className:"next-btns-group",children:[w.jsx("button",{onClick:()=>{const y=localStorage.getItem("language");y&&(y==="zh"||y==="zh-TW")?window.open("https://pkmer.cn/products/thino","_blank"):window.open("https://thino.pkmer.net/en/#price","_blank")},children:E("About Thino Pro")}),w.jsx("button",{className:"mod-cta",onClick:()=>{m("FirstLoaded",!1),Ze.getState().isMobileView?(setTimeout(()=>{Ze.setShowSiderbarInMobileView(!0)},500),setTimeout(()=>{Ze.setExitSteps(!0)},1e3)):setTimeout(()=>{Ze.setExitSteps(!0)},800)},children:E("Start Thino")})]})]})})}};return w.jsx(w.Fragment,{children:w.jsx("div",{className:"onboarding-view-container",children:w.jsx("div",{className:"onboarding-view-wrapper",children:w.jsxs("div",{"data-onboarding-step":i,className:"onboarding-view-content",children:[w.jsxs("div",{className:"onboarding-step-heading",children:[w.jsxs("div",{className:"onboarding-step-count",children:[i+1,"/5"]}),w.jsx("div",{className:"close-btn",children:w.jsx("button",{onClick:()=>{m("FirstLoaded",!1)},children:w.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:"lucide lucide-x",children:[w.jsx("path",{d:"M18 6 6 18"}),w.jsx("path",{d:"m6 6 12 12"})]})})})]}),w.jsxs("div",{className:"onboarding-view-details",children:[w.jsxs("div",{className:"details-content",children:[w.jsx("div",{className:"onboarding-header-group",children:b}),w.jsx(w.Fragment,{children:w.jsx("div",{className:"onboarding-form",children:v()})})]}),w.jsxs("div",{className:"details-footer",children:[w.jsx("div",{className:"skip-btn",children:i!==4&&w.jsx("button",{onClick:()=>{m("FirstLoaded",!1)},children:E("Skip and start Thino")})}),w.jsxs("div",{className:"navigate-btns-group",children:[i!==0&&w.jsx("button",{onClick:()=>a(i-1),children:E("Back to previous step")}),i!==4&&w.jsx("button",{className:"mod-cta",onClick:()=>a(i+1),children:E("Next step")}),i===4&&w.jsx("button",{className:"details-settings-btn",onClick:()=>{n.setting.open(),n.setting.openTabById(o.id||"obsidian-memos")},children:E("Details settings")})]})]})]})]})})})})};function iw(e){return iw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},iw(e)}function rn(e,t,n,r){return new(n||(n=Promise))(function(o,i){function a(u){try{l(r.next(u))}catch(d){i(d)}}function s(u){try{l(r.throw(u))}catch(d){i(d)}}function l(u){var d;u.done?o(u.value):(d=u.value,d instanceof n?d:new n(function(h){h(d)})).then(a,s)}l((r=r.apply(e,t||[])).next())})}function on(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(i[Symbol.iterator]=function(){return this}),i;function s(l){return function(u){return function(d){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,d[0]&&(a=0)),a;)try{if(n=1,r&&(o=2&d[0]?r.return:d[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,d[1])).done)return o;switch(r=0,o&&(d=[2&d[0],o.value]),d[0]){case 0:case 1:o=d;break;case 4:return a.label++,{value:d[1],done:!1};case 5:a.label++,r=d[1],d=[0];continue;case 7:d=a.ops.pop(),a.trys.pop();continue;default:if(o=a.trys,!((o=o.length>0&&o[o.length-1])||d[0]!==6&&d[0]!==2)){a=0;continue}if(d[0]===3&&(!o||d[1]>o[0]&&d[1]<o[3])){a.label=d[1];break}if(d[0]===6&&a.label<o[1]){a.label=o[1],o=d;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(d);break}o[2]&&a.ops.pop(),a.trys.pop();continue}d=t.call(e,a)}catch(h){d=[6,h],r=0}finally{n=o=0}if(5&d[0])throw d[1];return{value:d[0]?d[1]:void 0,done:!0}}([l,u])}}}function v5(e,t,n){var r,o=((r={})[e]=t,r.path="/",r.expires=void 0,r);if(n){var i=new Date;i.setTime(i.getTime()+24*n*60*60*1e3),o.expires=i.toUTCString()}var a=[];for(var s in o)a.push("".concat(s,"=").concat(o[s]));return document.cookie=a.join("; "),Tz(e)}function Tz(e){return(t={},document.cookie.split(";").forEach(function(n){var r=n.split("="),o=r[0],i=r[1];t[o.trim()]=i}),t)[e];var t}function J9e(e,t){t?v5(e._options.dontShowAgainCookie,"true",e._options.dontShowAgainCookieDays):v5(e._options.dontShowAgainCookie,"",-1)}var yb,fC=(yb={},function(e,t){return t===void 0&&(t="introjs-stamp"),yb[t]=yb[t]||0,e[t]===void 0&&(e[t]=yb[t]++),e[t]}),ms=new(function(){function e(){this.events_key="introjs_event"}return e.prototype._id=function(t,n,r){return t+fC(n)+(r?"_".concat(fC(r)):"")},e.prototype.on=function(t,n,r,o,i){var a=this._id(n,r,o),s=function(l){return r(o||t,l||window.event)};"addEventListener"in t?t.addEventListener(n,s,i):"attachEvent"in t&&t.attachEvent("on".concat(n),s),t[this.events_key]=t[this.events_key]||{},t[this.events_key][a]=s},e.prototype.off=function(t,n,r,o,i){var a=this._id(n,r,o),s=t[this.events_key]&&t[this.events_key][a];s&&("removeEventListener"in t?t.removeEventListener(n,s,i):"detachEvent"in t&&t.detachEvent("on".concat(n),s),t[this.events_key][a]=null)},e}()),Cn=function(e){return typeof e=="function"};function cs(e,t){if(e instanceof SVGElement){var n=e.getAttribute("class")||"";n.match(t)||e.setAttribute("class","".concat(n," ").concat(t))}else if(e.classList!==void 0)for(var r=0,o=t.split(" ");r<o.length;r++){var i=o[r];e.classList.add(i)}else e.className.match(t)||(e.className+=" ".concat(t))}function kA(e,t){var n="";return"currentStyle"in e?n=e.currentStyle[t]:document.defaultView&&document.defaultView.getComputedStyle&&(n=document.defaultView.getComputedStyle(e,null).getPropertyValue(t)),n&&n.toLowerCase?n.toLowerCase():n}function y5(e,t){if(e){var n=function(r){var o=window.getComputedStyle(r),i=o.position==="absolute",a=/(auto|scroll)/;if(o.position==="fixed")return document.body;for(var s=r;s=s.parentElement;)if(o=window.getComputedStyle(s),(!i||o.position!=="static")&&a.test(o.overflow+o.overflowY+o.overflowX))return s;return document.body}(t);n!==document.body&&(n.scrollTop=t.offsetTop-n.offsetTop)}}function EA(){if(window.innerWidth!==void 0)return{width:window.innerWidth,height:window.innerHeight};var e=document.documentElement;return{width:e.clientWidth,height:e.clientHeight}}function b5(e,t,n,r,o){var i;if(t!=="off"&&e&&(i=t==="tooltip"?o.getBoundingClientRect():r.getBoundingClientRect(),!function(s){var l=s.getBoundingClientRect();return l.top>=0&&l.left>=0&&l.bottom+80<=window.innerHeight&&l.right<=window.innerWidth}(r))){var a=EA().height;i.bottom-(i.bottom-i.top)<0||r.clientHeight>a?window.scrollBy(0,i.top-(a/2-i.height/2)-n):window.scrollBy(0,i.top-(a/2-i.height/2)+n)}}function Im(e){e.setAttribute("role","button"),e.tabIndex=0}function ET(e){var t=e.parentElement;return!(!t||t.nodeName==="HTML")&&(kA(e,"position")==="fixed"||ET(t))}function _f(e,t){var n=document.body,r=document.documentElement,o=window.pageYOffset||r.scrollTop||n.scrollTop,i=window.pageXOffset||r.scrollLeft||n.scrollLeft;t=t||n;var a=e.getBoundingClientRect(),s=t.getBoundingClientRect(),l=kA(t,"position"),u={width:a.width,height:a.height};return t.tagName.toLowerCase()!=="body"&&l==="relative"||l==="sticky"?Object.assign(u,{top:a.top-s.top,left:a.left-s.left}):ET(e)?Object.assign(u,{top:a.top,left:a.left}):Object.assign(u,{top:a.top+o,left:a.left+i})}function CA(e,t){if(e instanceof SVGElement){var n=e.getAttribute("class")||"";e.setAttribute("class",n.replace(t,"").replace(/^\s+|\s+$/g,""))}else e.className=e.className.replace(t,"").replace(/^\s+|\s+$/g,"")}function xc(e,t){var n="";if(e.style.cssText&&(n+=e.style.cssText),typeof t=="string")n+=t;else for(var r in t)n+="".concat(r,":").concat(t[r],";");e.style.cssText=n}function Qs(e,t,n){if(n&&t){var r=_f(t.element,e._targetElement),o=e._options.helperElementPadding;t.element instanceof Element&&ET(t.element)?cs(n,"introjs-fixedTooltip"):CA(n,"introjs-fixedTooltip"),t.position==="floating"&&(o=0),xc(n,{width:"".concat(r.width+o,"px"),height:"".concat(r.height+o,"px"),top:"".concat(r.top-o/2,"px"),left:"".concat(r.left-o/2,"px")})}}function bb(e,t,n,r,o){return e.left+t+n.width>r.width?(o.style.left="".concat(r.width-n.width-e.left,"px"),!1):(o.style.left="".concat(t,"px"),!0)}function wb(e,t,n,r){return e.left+e.width-t-n.width<0?(r.style.left="".concat(-e.left,"px"),!1):(r.style.right="".concat(t,"px"),!0)}function Ga(e,t){e.includes(t)&&e.splice(e.indexOf(t),1)}function Q9e(e,t,n,r){var o=e.slice(),i=EA(),a=_f(n).height+10,s=_f(n).width+20,l=t.getBoundingClientRect(),u="floating";if(l.bottom+a>i.height&&Ga(o,"bottom"),l.top-a<0&&Ga(o,"top"),l.right+s>i.width&&Ga(o,"right"),l.left-s<0&&Ga(o,"left"),r&&(r=r.split("-")[0]),o.length&&(u=o[0],o.includes(r)&&(u=r)),u==="top"||u==="bottom"){var d=void 0,h=[];u==="top"?(d="top-middle-aligned",h=["top-left-aligned","top-middle-aligned","top-right-aligned"]):(d="bottom-middle-aligned",h=["bottom-left-aligned","bottom-middle-aligned","bottom-right-aligned"]),u=function(p,m,b,v){var y=m/2,S=Math.min(b,window.screen.width);return S-p<m&&(Ga(v,"top-left-aligned"),Ga(v,"bottom-left-aligned")),(p<y||S-p<y)&&(Ga(v,"top-middle-aligned"),Ga(v,"bottom-middle-aligned")),p<m&&(Ga(v,"top-right-aligned"),Ga(v,"bottom-right-aligned")),v.length?v[0]:null}(l.left,s,i.width,h)||d}return u}function aw(e,t,n,r,o){if(o===void 0&&(o=!1),t){var i,a,s,l,u="";n.style.top="",n.style.right="",n.style.bottom="",n.style.left="",n.style.marginLeft="",n.style.marginTop="",r.style.display="inherit",u=typeof t.tooltipClass=="string"?t.tooltipClass:e._options.tooltipClass,n.className=["introjs-tooltip",u].filter(Boolean).join(" "),n.setAttribute("role","dialog"),(l=t.position)!=="floating"&&e._options.autoPosition&&(l=Q9e(e._options.positionPrecedence,t.element,n,l)),a=_f(t.element),i=_f(n),s=EA(),cs(n,"introjs-".concat(l));var d=a.width/2-i.width/2;switch(l){case"top-right-aligned":r.className="introjs-arrow bottom-right";var h=0;wb(a,h,i,n),n.style.bottom="".concat(a.height+20,"px");break;case"top-middle-aligned":r.className="introjs-arrow bottom-middle",o&&(d+=5),wb(a,d,i,n)&&(n.style.right="",bb(a,d,i,s,n)),n.style.bottom="".concat(a.height+20,"px");break;case"top-left-aligned":case"top":r.className="introjs-arrow bottom",bb(a,o?0:15,i,s,n),n.style.bottom="".concat(a.height+20,"px");break;case"right":n.style.left="".concat(a.width+20,"px"),a.top+i.height>s.height?(r.className="introjs-arrow left-bottom",n.style.top="-".concat(i.height-a.height-20,"px")):r.className="introjs-arrow left";break;case"left":o||e._options.showStepNumbers!==!0||(n.style.top="15px"),a.top+i.height>s.height?(n.style.top="-".concat(i.height-a.height-20,"px"),r.className="introjs-arrow right-bottom"):r.className="introjs-arrow right",n.style.right="".concat(a.width+20,"px");break;case"floating":r.style.display="none",n.style.left="50%",n.style.top="50%",n.style.marginLeft="-".concat(i.width/2,"px"),n.style.marginTop="-".concat(i.height/2,"px");break;case"bottom-right-aligned":r.className="introjs-arrow top-right",wb(a,h=0,i,n),n.style.top="".concat(a.height+20,"px");break;case"bottom-middle-aligned":r.className="introjs-arrow top-middle",o&&(d+=5),wb(a,d,i,n)&&(n.style.right="",bb(a,d,i,s,n)),n.style.top="".concat(a.height+20,"px");break;default:r.className="introjs-arrow top",bb(a,0,i,s,n),n.style.top="".concat(a.height+20,"px")}}}function xz(){for(var e=0,t=Array.from(document.querySelectorAll(".introjs-showElement"));e<t.length;e++)CA(t[e],/introjs-[a-zA-Z]+/g)}function Yt(e,t){var n=document.createElement(e);t=t||{};var r=/^(?:role|data-|aria-)/;for(var o in t){var i=t[o];o==="style"&&typeof i!="function"?xc(n,i):typeof i=="string"&&o.match(r)?n.setAttribute(o,i):n[o]=i}return n}function w5(e,t,n){if(n===void 0&&(n=!1),n){var r=t.style.opacity||"1";xc(t,{opacity:"0"}),window.setTimeout(function(){xc(t,{opacity:r})},10)}e.appendChild(t)}function Iz(e,t){return(e+1)/t*100}function kz(e,t){var n=Yt("div",{className:"introjs-bullets"});e._options.showBullets===!1&&(n.style.display="none");var r=Yt("ul");r.setAttribute("role","tablist");for(var o=function(){var u=this.getAttribute("data-step-number");u!=null&&e.goToStep(parseInt(u,10))},i=0;i<e._introItems.length;i++){var a=e._introItems[i].step,s=Yt("li"),l=Yt("a");s.setAttribute("role","presentation"),l.setAttribute("role","tab"),l.onclick=o,i===t.step-1&&(l.className="active"),Im(l),l.innerHTML=" ",l.setAttribute("data-step-number",a.toString()),s.appendChild(l),r.appendChild(s)}return n.appendChild(r),n}function Ez(e,t,n){var r=e.querySelector(".introjs-progress .introjs-progressbar");if(r){var o=Iz(t,n);r.style.cssText="width:".concat(o,"%;"),r.setAttribute("aria-valuenow",o.toString())}}function Cz(e,t){return rn(this,void 0,void 0,function(){var n,r,o,i,a,s,l,u,d,h,p,m,b,v,y,S,x,C,k,M,I,O,R,L,B=this;return on(this,function(_){switch(_.label){case 0:return Cn(e._introChangeCallback)?[4,e._introChangeCallback.call(e,t.element)]:[3,2];case 1:_.sent(),_.label=2;case 2:return n=document.querySelector(".introjs-helperLayer"),r=document.querySelector(".introjs-tooltipReferenceLayer"),o="introjs-helperLayer",typeof t.highlightClass=="string"&&(o+=" ".concat(t.highlightClass)),typeof e._options.highlightClass=="string"&&(o+=" ".concat(e._options.highlightClass)),n!==null&&r!==null?(l=r.querySelector(".introjs-helperNumberLayer"),u=r.querySelector(".introjs-tooltiptext"),d=r.querySelector(".introjs-tooltip-title"),h=r.querySelector(".introjs-arrow"),p=r.querySelector(".introjs-tooltip"),s=r.querySelector(".introjs-skipbutton"),a=r.querySelector(".introjs-prevbutton"),i=r.querySelector(".introjs-nextbutton"),n.className=o,p.style.opacity="0",p.style.display="none",y5(e._options.scrollToElement,t.element),Qs(e,t,n),Qs(e,t,r),xz(),e._lastShowElementTimer&&window.clearTimeout(e._lastShowElementTimer),e._lastShowElementTimer=window.setTimeout(function(){l!==null&&(l.innerHTML="".concat(t.step," ").concat(e._options.stepNumbersOfLabel," ").concat(e._introItems.length)),u.innerHTML=t.intro||"",d.innerHTML=t.title||"",p.style.display="block",aw(e,t,p,h),function(H,U,G){if(H){var K=U.querySelector(".introjs-bullets li > a.active"),z=U.querySelector('.introjs-bullets li > a[data-step-number="'.concat(G.step,'"]'));K&&z&&(K.className="",z.className="active")}}(e._options.showBullets,r,t),Ez(r,e._currentStep,e._introItems.length),p.style.opacity="1",(i!=null&&/introjs-donebutton/gi.test(i.className)||i!=null)&&i.focus(),b5(e._options.scrollToElement,t.scrollTo,e._options.scrollPadding,t.element,u)},350)):(m=Yt("div",{className:o}),b=Yt("div",{className:"introjs-tooltipReferenceLayer"}),v=Yt("div",{className:"introjs-arrow"}),y=Yt("div",{className:"introjs-tooltip"}),S=Yt("div",{className:"introjs-tooltiptext"}),x=Yt("div",{className:"introjs-tooltip-header"}),C=Yt("h1",{className:"introjs-tooltip-title"}),k=Yt("div"),xc(m,{"box-shadow":"0 0 1px 2px rgba(33, 33, 33, 0.8), rgba(33, 33, 33, ".concat(e._options.overlayOpacity.toString(),") 0 0 0 5000px")}),y5(e._options.scrollToElement,t.element),Qs(e,t,m),Qs(e,t,b),w5(e._targetElement,m,!0),w5(e._targetElement,b),S.innerHTML=t.intro,C.innerHTML=t.title,k.className="introjs-tooltipbuttons",e._options.showButtons===!1&&(k.style.display="none"),x.appendChild(C),y.appendChild(x),y.appendChild(S),e._options.dontShowAgain&&(M=Yt("div",{className:"introjs-dontShowAgain"}),(I=Yt("input",{type:"checkbox",id:"introjs-dontShowAgain",name:"introjs-dontShowAgain"})).onchange=function(H){e.setDontShowAgain(H.target.checked)},(O=Yt("label",{htmlFor:"introjs-dontShowAgain"})).innerText=e._options.dontShowAgainLabel,M.appendChild(I),M.appendChild(O),y.appendChild(M)),y.appendChild(kz(e,t)),y.appendChild(function(H){var U=Yt("div");U.className="introjs-progress",H._options.showProgress===!1&&(U.style.display="none");var G=Yt("div",{className:"introjs-progressbar"});H._options.progressBarAdditionalClass&&(G.className+=" "+H._options.progressBarAdditionalClass);var K=Iz(H._currentStep,H._introItems.length);return G.setAttribute("role","progress"),G.setAttribute("aria-valuemin","0"),G.setAttribute("aria-valuemax","100"),G.setAttribute("aria-valuenow",K.toString()),G.style.cssText="width:".concat(K,"%;"),U.appendChild(G),U}(e)),R=Yt("div"),e._options.showStepNumbers===!0&&(R.className="introjs-helperNumberLayer",R.innerHTML="".concat(t.step," ").concat(e._options.stepNumbersOfLabel," ").concat(e._introItems.length),y.appendChild(R)),y.appendChild(v),b.appendChild(y),(i=Yt("a")).onclick=function(){return rn(B,void 0,void 0,function(){return on(this,function(H){switch(H.label){case 0:return e._introItems.length-1===e._currentStep?[3,2]:[4,Wu(e)];case 1:return H.sent(),[3,6];case 2:return/introjs-donebutton/gi.test(i.className)?Cn(e._introCompleteCallback)?[4,e._introCompleteCallback.call(e,e._currentStep,"done")]:[3,4]:[3,6];case 3:H.sent(),H.label=4;case 4:return[4,Gu(e,e._targetElement)];case 5:H.sent(),H.label=6;case 6:return[2]}})})},Im(i),i.innerHTML=e._options.nextLabel,(a=Yt("a")).onclick=function(){return rn(B,void 0,void 0,function(){return on(this,function(H){switch(H.label){case 0:return e._currentStep>0?[4,sw(e)]:[3,2];case 1:H.sent(),H.label=2;case 2:return[2]}})})},Im(a),a.innerHTML=e._options.prevLabel,Im(s=Yt("a",{className:"introjs-skipbutton"})),s.innerHTML=e._options.skipLabel,s.onclick=function(){return rn(B,void 0,void 0,function(){return on(this,function(H){switch(H.label){case 0:return e._introItems.length-1===e._currentStep&&Cn(e._introCompleteCallback)?[4,e._introCompleteCallback.call(e,e._currentStep,"skip")]:[3,2];case 1:H.sent(),H.label=2;case 2:return Cn(e._introSkipCallback)?[4,e._introSkipCallback.call(e,e._currentStep)]:[3,4];case 3:H.sent(),H.label=4;case 4:return[4,Gu(e,e._targetElement)];case 5:return H.sent(),[2]}})})},x.appendChild(s),e._introItems.length>1&&k.appendChild(a),k.appendChild(i),y.appendChild(k),aw(e,t,y,v),b5(e._options.scrollToElement,t.scrollTo,e._options.scrollPadding,t.element,y)),(L=e._targetElement.querySelector(".introjs-disableInteraction"))&&L.parentNode&&L.parentNode.removeChild(L),t.disableInteraction&&function(H,U){var G=document.querySelector(".introjs-disableInteraction");G===null&&(G=Yt("div",{className:"introjs-disableInteraction"}),H._targetElement.appendChild(G)),Qs(H,U,G)}(e,t),e._currentStep===0&&e._introItems.length>1?(i!=null&&(i.className="".concat(e._options.buttonClass," introjs-nextbutton"),i.innerHTML=e._options.nextLabel),e._options.hidePrev===!0?(a!=null&&(a.className="".concat(e._options.buttonClass," introjs-prevbutton introjs-hidden")),i!=null&&cs(i,"introjs-fullbutton")):a!=null&&(a.className="".concat(e._options.buttonClass," introjs-prevbutton introjs-disabled"))):e._introItems.length-1===e._currentStep||e._introItems.length===1?(a!=null&&(a.className="".concat(e._options.buttonClass," introjs-prevbutton")),e._options.hideNext===!0?(i!=null&&(i.className="".concat(e._options.buttonClass," introjs-nextbutton introjs-hidden")),a!=null&&cs(a,"introjs-fullbutton")):i!=null&&(e._options.nextToDone===!0?(i.innerHTML=e._options.doneLabel,cs(i,"".concat(e._options.buttonClass," introjs-nextbutton introjs-donebutton"))):i.className="".concat(e._options.buttonClass," introjs-nextbutton introjs-disabled"))):(a!=null&&(a.className="".concat(e._options.buttonClass," introjs-prevbutton")),i!=null&&(i.className="".concat(e._options.buttonClass," introjs-nextbutton"),i.innerHTML=e._options.nextLabel)),a?.setAttribute("role","button"),i?.setAttribute("role","button"),s?.setAttribute("role","button"),i?.focus(),function(H){cs(H,"introjs-showElement");var U=kA(H,"position");U!=="absolute"&&U!=="relative"&&U!=="sticky"&&U!=="fixed"&&cs(H,"introjs-relativePosition")}(t.element),Cn(e._introAfterChangeCallback)?[4,e._introAfterChangeCallback.call(e,t.element)]:[3,4];case 3:_.sent(),_.label=4;case 4:return[2]}})})}function eFe(e,t){return rn(this,void 0,void 0,function(){return on(this,function(n){switch(n.label){case 0:return e._currentStep=t-2,e._introItems===void 0?[3,2]:[4,Wu(e)];case 1:n.sent(),n.label=2;case 2:return[2]}})})}function tFe(e,t){return rn(this,void 0,void 0,function(){return on(this,function(n){switch(n.label){case 0:return e._currentStepNumber=t,e._introItems===void 0?[3,2]:[4,Wu(e)];case 1:n.sent(),n.label=2;case 2:return[2]}})})}function Wu(e){return rn(this,void 0,void 0,function(){var t,n,r;return on(this,function(o){switch(o.label){case 0:if(e._direction="forward",e._currentStepNumber!==void 0)for(t=0;t<e._introItems.length;t++)e._introItems[t].step===e._currentStepNumber&&(e._currentStep=t-1,e._currentStepNumber=void 0);return e._currentStep===-1?e._currentStep=0:++e._currentStep,n=e._introItems[e._currentStep],r=!0,Cn(e._introBeforeChangeCallback)?[4,e._introBeforeChangeCallback.call(e,n&&n.element,e._currentStep,e._direction)]:[3,2];case 1:r=o.sent(),o.label=2;case 2:return r===!1?(--e._currentStep,[2,!1]):e._introItems.length<=e._currentStep?Cn(e._introCompleteCallback)?[4,e._introCompleteCallback.call(e,e._currentStep,"end")]:[3,4]:[3,6];case 3:o.sent(),o.label=4;case 4:return[4,Gu(e,e._targetElement)];case 5:return o.sent(),[2,!1];case 6:return[4,Cz(e,n)];case 7:return o.sent(),[2,!0]}})})}function sw(e){return rn(this,void 0,void 0,function(){var t,n;return on(this,function(r){switch(r.label){case 0:return e._direction="backward",e._currentStep<=0?[2,!1]:(--e._currentStep,t=e._introItems[e._currentStep],n=!0,Cn(e._introBeforeChangeCallback)?[4,e._introBeforeChangeCallback.call(e,t&&t.element,e._currentStep,e._direction)]:[3,2]);case 1:n=r.sent(),r.label=2;case 2:return n===!1?(++e._currentStep,[2,!1]):[4,Cz(e,t)];case 3:return r.sent(),[2,!0]}})})}function Mz(e,t){return rn(this,void 0,void 0,function(){var n,r;return on(this,function(o){switch(o.label){case 0:return(n=t.code===void 0?t.which:t.code)===null&&(n=t.charCode===null?t.keyCode:t.charCode),n!=="Escape"&&n!==27||e._options.exitOnEsc!==!0?[3,2]:[4,Gu(e,e._targetElement)];case 1:return o.sent(),[3,16];case 2:return n!=="ArrowLeft"&&n!==37?[3,4]:[4,sw(e)];case 3:return o.sent(),[3,16];case 4:return n!=="ArrowRight"&&n!==39?[3,6]:[4,Wu(e)];case 5:return o.sent(),[3,16];case 6:return n!=="Enter"&&n!=="NumpadEnter"&&n!==13?[3,16]:(r=t.target||t.srcElement)&&r.className.match("introjs-prevbutton")?[4,sw(e)]:[3,8];case 7:return o.sent(),[3,15];case 8:return r&&r.className.match("introjs-skipbutton")?e._introItems.length-1===e._currentStep&&Cn(e._introCompleteCallback)?[4,e._introCompleteCallback.call(e,e._currentStep,"skip")]:[3,10]:[3,12];case 9:o.sent(),o.label=10;case 10:return[4,Gu(e,e._targetElement)];case 11:return o.sent(),[3,15];case 12:return r&&r.getAttribute("data-step-number")?(r.click(),[3,15]):[3,13];case 13:return[4,Wu(e)];case 14:o.sent(),o.label=15;case 15:t.preventDefault?t.preventDefault():t.returnValue=!1,o.label=16;case 16:return[2]}})})}function MA(e){if(e===null||iw(e)!=="object"||"nodeType"in e)return e;var t={};for(var n in e)"jQuery"in window&&e[n]instanceof window.jQuery?t[n]=e[n]:t[n]=MA(e[n]);return t}function Uh(e){var t=document.querySelector(".introjs-hints");return t?Array.from(t.querySelectorAll(e)):[]}function DA(e,t){return rn(this,void 0,void 0,function(){var n;return on(this,function(r){switch(r.label){case 0:return n=Uh('.introjs-hint[data-step="'.concat(t,'"]'))[0],CT(),n&&cs(n,"introjs-hidehint"),Cn(e._hintCloseCallback)?[4,e._hintCloseCallback.call(e,t)]:[3,2];case 1:r.sent(),r.label=2;case 2:return[2]}})})}function nFe(e){return rn(this,void 0,void 0,function(){var t,n,r,o,i;return on(this,function(a){switch(a.label){case 0:t=Uh(".introjs-hint"),n=0,r=t,a.label=1;case 1:return n<r.length?(o=r[n],(i=o.getAttribute("data-step"))?[4,DA(e,parseInt(i,10))]:[3,3]):[3,4];case 2:a.sent(),a.label=3;case 3:return n++,[3,1];case 4:return[2]}})})}function rFe(e){return rn(this,void 0,void 0,function(){var t,n,r,o,i;return on(this,function(a){switch(a.label){case 0:if(!(t=Uh(".introjs-hint"))||!t.length)return[3,1];for(n=0,r=t;n<r.length;n++)o=r[n],(i=o.getAttribute("data-step"))&&Dz(parseInt(i,10));return[3,3];case 1:return[4,Oz(e,e._targetElement)];case 2:a.sent(),a.label=3;case 3:return[2]}})})}function Dz(e){var t=Uh('.introjs-hint[data-step="'.concat(e,'"]'))[0];t&&CA(t,/introjs-hidehint/g)}function S5(e){var t=Uh('.introjs-hint[data-step="'.concat(e,'"]'))[0];t&&t.parentNode&&t.parentNode.removeChild(t)}function oFe(e){return rn(this,void 0,void 0,function(){var t,n,r,o,i,a,s;return on(this,function(l){switch(l.label){case 0:for((t=document.querySelector(".introjs-hints"))===null&&(t=Yt("div",{className:"introjs-hints"})),n=function(p){return function(m){var b=m||window.event;b&&b.stopPropagation&&b.stopPropagation(),b&&b.cancelBubble!==null&&(b.cancelBubble=!0),Nz(e,p)}},r=0;r<e._hintItems.length;r++){if(o=e._hintItems[r],document.querySelector('.introjs-hint[data-step="'.concat(r,'"]')))return[2];Im(i=Yt("a",{className:"introjs-hint"})),i.onclick=n(r),o.hintAnimation||cs(i,"introjs-hint-no-anim"),ET(o.element)&&cs(i,"introjs-fixedhint"),a=Yt("div",{className:"introjs-hint-dot"}),s=Yt("div",{className:"introjs-hint-pulse"}),i.appendChild(a),i.appendChild(s),i.setAttribute("data-step",r.toString()),o.hintTargetElement=o.element,o.element=i,Az(o.hintPosition,i,o.hintTargetElement),t.appendChild(i)}return document.body.appendChild(t),Cn(e._hintsAddedCallback)?[4,e._hintsAddedCallback.call(e)]:[3,2];case 1:l.sent(),l.label=2;case 2:return e._options.hintAutoRefreshInterval>=0&&(e._hintsAutoRefreshFunction=(u=function(){return MT(e)},d=e._options.hintAutoRefreshInterval,function(){for(var p=[],m=0;m<arguments.length;m++)p[m]=arguments[m];window.clearTimeout(h),h=window.setTimeout(function(){u(p)},d)}),ms.on(window,"scroll",e._hintsAutoRefreshFunction,e,!0)),[2]}var u,d,h})})}function Az(e,t,n){if(n!==void 0){var r=_f(n),o=20,i=20;switch(e){default:case"top-left":t.style.left="".concat(r.left,"px"),t.style.top="".concat(r.top,"px");break;case"top-right":t.style.left="".concat(r.left+r.width-o,"px"),t.style.top="".concat(r.top,"px");break;case"bottom-left":t.style.left="".concat(r.left,"px"),t.style.top="".concat(r.top+r.height-i,"px");break;case"bottom-right":t.style.left="".concat(r.left+r.width-o,"px"),t.style.top="".concat(r.top+r.height-i,"px");break;case"middle-left":t.style.left="".concat(r.left,"px"),t.style.top="".concat(r.top+(r.height-i)/2,"px");break;case"middle-right":t.style.left="".concat(r.left+r.width-o,"px"),t.style.top="".concat(r.top+(r.height-i)/2,"px");break;case"middle-middle":t.style.left="".concat(r.left+(r.width-o)/2,"px"),t.style.top="".concat(r.top+(r.height-i)/2,"px");break;case"bottom-middle":t.style.left="".concat(r.left+(r.width-o)/2,"px"),t.style.top="".concat(r.top+r.height-i,"px");break;case"top-middle":t.style.left="".concat(r.left+(r.width-o)/2,"px"),t.style.top="".concat(r.top,"px")}}}function Nz(e,t){return rn(this,void 0,void 0,function(){var n,r,o,i,a,s,l,u,d,h,p;return on(this,function(m){switch(m.label){case 0:return n=document.querySelector('.introjs-hint[data-step="'.concat(t,'"]')),r=e._hintItems[t],Cn(e._hintClickCallback)?[4,e._hintClickCallback.call(e,n,r,t)]:[3,2];case 1:m.sent(),m.label=2;case 2:return(o=CT())!==void 0&&parseInt(o,10)===t||(i=Yt("div",{className:"introjs-tooltip"}),a=Yt("div"),s=Yt("div"),l=Yt("div"),i.onclick=function(b){b.stopPropagation?b.stopPropagation():b.cancelBubble=!0},a.className="introjs-tooltiptext",(u=Yt("p")).innerHTML=r.hint||"",a.appendChild(u),e._options.hintShowButton&&((d=Yt("a")).className=e._options.buttonClass,d.setAttribute("role","button"),d.innerHTML=e._options.hintButtonLabel,d.onclick=function(){return DA(e,t)},a.appendChild(d)),s.className="introjs-arrow",i.appendChild(s),i.appendChild(a),h=n.getAttribute("data-step")||"",e._currentStep=parseInt(h,10),p=e._hintItems[e._currentStep],l.className="introjs-tooltipReferenceLayer introjs-hintReference",l.setAttribute("data-step",h),Qs(e,p,l),l.appendChild(i),document.body.appendChild(l),aw(e,p,i,s,!0)),[2]}})})}function CT(){var e=document.querySelector(".introjs-hintReference");if(e&&e.parentNode){var t=e.getAttribute("data-step");return t?(e.parentNode.removeChild(e),t):void 0}}function Oz(e,t){return rn(this,void 0,void 0,function(){var n,r,o,i,a,s,l,u,d,h;return on(this,function(p){switch(p.label){case 0:if(e._hintItems=[],e._options.hints&&e._options.hints.length>0)for(n=0,r=e._options.hints;n<r.length;n++)o=r[n],typeof(i=MA(o)).element=="string"&&(i.element=document.querySelector(i.element)),i.hintPosition=i.hintPosition||e._options.hintPosition,i.hintAnimation=i.hintAnimation||e._options.hintAnimation,i.element!==null&&e._hintItems.push(i);else{if(!(a=Array.from(t.querySelectorAll("*[data-hint]")))||!a.length)return[2,!1];for(s=0,l=a;s<l.length;s++)u=l[s],d=u.getAttribute("data-hint-animation"),h=e._options.hintAnimation,d&&(h=d==="true"),e._hintItems.push({element:u,hint:u.getAttribute("data-hint")||"",hintPosition:u.getAttribute("data-hint-position")||e._options.hintPosition,hintAnimation:h,tooltipClass:u.getAttribute("data-tooltip-class")||void 0,position:u.getAttribute("data-position")||e._options.tooltipPosition})}return[4,oFe(e)];case 1:return p.sent(),ms.on(document,"click",CT,e,!1),ms.on(window,"resize",MT,e,!0),[2,!0]}})})}function MT(e){for(var t=0,n=e._hintItems;t<n.length;t++){var r=n[t],o=r.hintTargetElement;Az(r.hintPosition,r.element,o)}}function Pz(e,t){var n=Array.from(t.querySelectorAll("*[data-intro]")),r=[];if(e._options.steps&&e._options.steps.length)for(var o=0,i=e._options.steps;o<i.length;o++){var a=MA(p=i[o]);if(a.step=r.length+1,a.title=a.title||"",typeof a.element=="string"&&(a.element=document.querySelector(a.element)||void 0),a.element===void 0||a.element===null){var s=document.querySelector(".introjsFloatingElement");s===null&&(s=Yt("div",{className:"introjsFloatingElement"}),document.body.appendChild(s)),a.element=s,a.position="floating"}a.position=a.position||e._options.tooltipPosition,a.scrollTo=a.scrollTo||e._options.scrollTo,a.disableInteraction===void 0&&(a.disableInteraction=e._options.disableInteraction),a.element!==null&&r.push(a)}else{var l=void 0;if(n.length<1)return[];for(var u=0,d=n;u<d.length;u++){var h=d[u];if((!e._options.group||h.getAttribute("data-intro-group")===e._options.group)&&h.style.display!=="none"){var p=parseInt(h.getAttribute("data-step")||"",10);l=e._options.disableInteraction,h.hasAttribute("data-disable-interaction")&&(l=!!h.getAttribute("data-disable-interaction")),p>0&&(r[p-1]={step:p,element:h,title:h.getAttribute("data-title")||"",intro:h.getAttribute("data-intro")||"",tooltipClass:h.getAttribute("data-tooltip-class")||void 0,highlightClass:h.getAttribute("data-highlight-class")||void 0,position:h.getAttribute("data-position")||e._options.tooltipPosition,scrollTo:h.getAttribute("data-scroll-to")||e._options.scrollTo,disableInteraction:l})}}for(var m=0,b=0,v=n;b<v.length;b++)if(h=v[b],(!e._options.group||h.getAttribute("data-intro-group")===e._options.group)&&h.getAttribute("data-step")===null){for(;r[m]!==void 0;)m++;l=h.hasAttribute("data-disable-interaction")?!!h.getAttribute("data-disable-interaction"):e._options.disableInteraction,r[m]={element:h,title:h.getAttribute("data-title")||"",intro:h.getAttribute("data-intro")||"",step:m+1,tooltipClass:h.getAttribute("data-tooltip-class")||void 0,highlightClass:h.getAttribute("data-highlight-class")||void 0,position:h.getAttribute("data-position")||e._options.tooltipPosition,scrollTo:h.getAttribute("data-scroll-to")||e._options.scrollTo,disableInteraction:l}}}for(var y=[],S=0;S<r.length;S++)r[S]&&y.push(r[S]);return(r=y).sort(function(x,C){return x.step-C.step}),r}function jz(e,t){var n=e._currentStep;if(n!=null&&n!=-1){var r=e._introItems[n],o=document.querySelector(".introjs-tooltipReferenceLayer"),i=document.querySelector(".introjs-helperLayer"),a=document.querySelector(".introjs-disableInteraction");Qs(e,r,i),Qs(e,r,o),Qs(e,r,a),t&&(e._introItems=Pz(e,e._targetElement),function(u,d){if(u._options.showBullets){var h=document.querySelector(".introjs-bullets");h&&h.parentNode&&h.parentNode.replaceChild(kz(u,d),h)}}(e,r),Ez(o,n,e._introItems.length));var s=document.querySelector(".introjs-arrow"),l=document.querySelector(".introjs-tooltip");return l&&s&&aw(e,e._introItems[n],l,s),MT(e),e}}function Lz(e){jz(e)}function Bp(e,t){if(t===void 0&&(t=!1),e&&e.parentElement){var n=e.parentElement;t?(xc(e,{opacity:"0"}),window.setTimeout(function(){try{n.removeChild(e)}catch{}},500)):n.removeChild(e)}}function Gu(e,t,n){return n===void 0&&(n=!1),rn(this,void 0,void 0,function(){var r,o,i,a;return on(this,function(s){switch(s.label){case 0:return r=!0,e._introBeforeExitCallback===void 0?[3,2]:[4,e._introBeforeExitCallback.call(e,t)];case 1:r=s.sent(),s.label=2;case 2:if(!n&&r===!1)return[2];if((o=Array.from(t.querySelectorAll(".introjs-overlay")))&&o.length)for(i=0,a=o;i<a.length;i++)Bp(a[i]);return Bp(t.querySelector(".introjs-helperLayer"),!0),Bp(t.querySelector(".introjs-tooltipReferenceLayer")),Bp(t.querySelector(".introjs-disableInteraction")),Bp(document.querySelector(".introjsFloatingElement")),xz(),ms.off(window,"keydown",Mz,e,!0),ms.off(window,"resize",Lz,e,!0),Cn(e._introExitCallback)?[4,e._introExitCallback.call(e)]:[3,4];case 3:s.sent(),s.label=4;case 4:return e._currentStep=-1,[2]}})})}function iFe(e,t){return rn(this,void 0,void 0,function(){var n;return on(this,function(r){switch(r.label){case 0:return e.isActive()?Cn(e._introStartCallback)?[4,e._introStartCallback.call(e,t)]:[3,2]:[2,!1];case 1:r.sent(),r.label=2;case 2:return(n=Pz(e,t)).length===0?[2,!1]:(e._introItems=n,function(o,i){var a=this,s=Yt("div",{className:"introjs-overlay"});xc(s,{top:0,bottom:0,left:0,right:0,position:"fixed"}),i.appendChild(s),o._options.exitOnOverlayClick===!0&&(xc(s,{cursor:"pointer"}),s.onclick=function(){return rn(a,void 0,void 0,function(){return on(this,function(l){switch(l.label){case 0:return[4,Gu(o,i)];case 1:return l.sent(),[2]}})})})}(e,t),[4,Wu(e)]);case 3:r.sent(),t.addEventListener,e._options.keyboardNavigation&&ms.on(window,"keydown",Mz,e,!0),ms.on(window,"resize",Lz,e,!0),r.label=4;case 4:return[2,!1]}})})}function T5(e,t,n){return e[t]=n,e}var fk=function(){function e(t){this._currentStep=-1,this._introItems=[],this._hintItems=[],this._targetElement=t,this._options={steps:[],hints:[],isActive:!0,nextLabel:"Next",prevLabel:"Back",skipLabel:"×",doneLabel:"Done",hidePrev:!1,hideNext:!1,nextToDone:!0,tooltipPosition:"bottom",tooltipClass:"",group:"",highlightClass:"",exitOnEsc:!0,exitOnOverlayClick:!0,showStepNumbers:!1,stepNumbersOfLabel:"of",keyboardNavigation:!0,showButtons:!0,showBullets:!0,showProgress:!1,scrollToElement:!0,scrollTo:"element",scrollPadding:30,overlayOpacity:.5,autoPosition:!0,positionPrecedence:["bottom","top","right","left"],disableInteraction:!1,dontShowAgain:!1,dontShowAgainLabel:"Don't show this again",dontShowAgainCookie:"introjs-dontShowAgain",dontShowAgainCookieDays:365,helperElementPadding:10,hintPosition:"top-middle",hintButtonLabel:"Got it",hintShowButton:!0,hintAutoRefreshInterval:10,hintAnimation:!0,buttonClass:"introjs-button",progressBarAdditionalClass:!1}}return e.prototype.isActive=function(){return(!this._options.dontShowAgain||(t=Tz(this._options.dontShowAgainCookie))===""||t!=="true")&&this._options.isActive;var t},e.prototype.clone=function(){return new e(this._targetElement)},e.prototype.setOption=function(t,n){return this._options=T5(this._options,t,n),this},e.prototype.setOptions=function(t){return this._options=function(n,r){for(var o=0,i=Object.entries(r);o<i.length;o++){var a=i[o];n=T5(n,a[0],a[1])}return n}(this._options,t),this},e.prototype.start=function(){return rn(this,void 0,void 0,function(){return on(this,function(t){switch(t.label){case 0:return[4,iFe(this,this._targetElement)];case 1:return t.sent(),[2,this]}})})},e.prototype.goToStep=function(t){return rn(this,void 0,void 0,function(){return on(this,function(n){switch(n.label){case 0:return[4,eFe(this,t)];case 1:return n.sent(),[2,this]}})})},e.prototype.addStep=function(t){return this._options.steps||(this._options.steps=[]),this._options.steps.push(t),this},e.prototype.addSteps=function(t){if(!t.length)return this;for(var n=0;n<t.length;n++)this.addStep(t[n]);return this},e.prototype.goToStepNumber=function(t){return rn(this,void 0,void 0,function(){return on(this,function(n){switch(n.label){case 0:return[4,tFe(this,t)];case 1:return n.sent(),[2,this]}})})},e.prototype.nextStep=function(){return rn(this,void 0,void 0,function(){return on(this,function(t){switch(t.label){case 0:return[4,Wu(this)];case 1:return t.sent(),[2,this]}})})},e.prototype.previousStep=function(){return rn(this,void 0,void 0,function(){return on(this,function(t){switch(t.label){case 0:return[4,sw(this)];case 1:return t.sent(),[2,this]}})})},e.prototype.currentStep=function(){return this._currentStep},e.prototype.exit=function(t){return rn(this,void 0,void 0,function(){return on(this,function(n){switch(n.label){case 0:return[4,Gu(this,this._targetElement,t)];case 1:return n.sent(),[2,this]}})})},e.prototype.refresh=function(t){return jz(this,t),this},e.prototype.setDontShowAgain=function(t){return J9e(this,t),this},e.prototype.onbeforechange=function(t){if(!Cn(t))throw new Error("Provided callback for onbeforechange was not a function");return this._introBeforeChangeCallback=t,this},e.prototype.onchange=function(t){if(!Cn(t))throw new Error("Provided callback for onchange was not a function.");return this._introChangeCallback=t,this},e.prototype.onafterchange=function(t){if(!Cn(t))throw new Error("Provided callback for onafterchange was not a function");return this._introAfterChangeCallback=t,this},e.prototype.oncomplete=function(t){if(!Cn(t))throw new Error("Provided callback for oncomplete was not a function.");return this._introCompleteCallback=t,this},e.prototype.onhintsadded=function(t){if(!Cn(t))throw new Error("Provided callback for onhintsadded was not a function.");return this._hintsAddedCallback=t,this},e.prototype.onhintclick=function(t){if(!Cn(t))throw new Error("Provided callback for onhintclick was not a function.");return this._hintClickCallback=t,this},e.prototype.onhintclose=function(t){if(!Cn(t))throw new Error("Provided callback for onhintclose was not a function.");return this._hintCloseCallback=t,this},e.prototype.onstart=function(t){if(!Cn(t))throw new Error("Provided callback for onstart was not a function.");return this._introStartCallback=t,this},e.prototype.onexit=function(t){if(!Cn(t))throw new Error("Provided callback for onexit was not a function.");return this._introExitCallback=t,this},e.prototype.onskip=function(t){if(!Cn(t))throw new Error("Provided callback for onskip was not a function.");return this._introSkipCallback=t,this},e.prototype.onbeforeexit=function(t){if(!Cn(t))throw new Error("Provided callback for onbeforeexit was not a function.");return this._introBeforeExitCallback=t,this},e.prototype.addHints=function(){return rn(this,void 0,void 0,function(){return on(this,function(t){switch(t.label){case 0:return[4,Oz(this,this._targetElement)];case 1:return t.sent(),[2,this]}})})},e.prototype.hideHint=function(t){return rn(this,void 0,void 0,function(){return on(this,function(n){switch(n.label){case 0:return[4,DA(this,t)];case 1:return n.sent(),[2,this]}})})},e.prototype.hideHints=function(){return rn(this,void 0,void 0,function(){return on(this,function(t){switch(t.label){case 0:return[4,nFe(this)];case 1:return t.sent(),[2,this]}})})},e.prototype.showHint=function(t){return Dz(t),this},e.prototype.showHints=function(){return rn(this,void 0,void 0,function(){return on(this,function(t){switch(t.label){case 0:return[4,rFe(this)];case 1:return t.sent(),[2,this]}})})},e.prototype.removeHints=function(){return function(t){for(var n=0,r=Uh(".introjs-hint");n<r.length;n++){var o=r[n].getAttribute("data-step");o&&S5(parseInt(o,10))}ms.off(document,"click",CT,t,!1),ms.off(window,"resize",MT,t,!0),t._hintsAutoRefreshFunction&&ms.off(window,"scroll",t._hintsAutoRefreshFunction,t,!0)}(this),this},e.prototype.removeHint=function(t){return S5(t),this},e.prototype.showHintDialog=function(t){return rn(this,void 0,void 0,function(){return on(this,function(n){switch(n.label){case 0:return[4,Nz(this,t)];case 1:return n.sent(),[2,this]}})})},e}(),lw=function e(t){var n;if(iw(t)==="object")n=new fk(t);else if(typeof t=="string"){var r=document.querySelector(t);if(!r)throw new Error("There is no element with given selector.");n=new fk(r)}else n=new fk(document.body);return e.instances[fC(n,"introjs-instance")]=n,n};lw.version="7.2.0",lw.instances={};var du={},x5;function aFe(){if(x5)return du;x5=1;var e=D;function t(P){for(var W="https://reactjs.org/docs/error-decoder.html?invariant="+P,te=1;te<arguments.length;te++)W+="&args[]="+encodeURIComponent(arguments[te]);return"Minified React error #"+P+"; visit "+W+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var n=Object.prototype.hasOwnProperty,r=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,o={},i={};function a(P){return n.call(i,P)?!0:n.call(o,P)?!1:r.test(P)?i[P]=!0:(o[P]=!0,!1)}function s(P,W,te,ae,Se,ve,De){this.acceptsBooleans=W===2||W===3||W===4,this.attributeName=ae,this.attributeNamespace=Se,this.mustUseProperty=te,this.propertyName=P,this.type=W,this.sanitizeURL=ve,this.removeEmptyString=De}var l={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(P){l[P]=new s(P,0,!1,P,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(P){var W=P[0];l[W]=new s(W,1,!1,P[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(P){l[P]=new s(P,2,!1,P.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(P){l[P]=new s(P,2,!1,P,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(P){l[P]=new s(P,3,!1,P.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(P){l[P]=new s(P,3,!0,P,null,!1,!1)}),["capture","download"].forEach(function(P){l[P]=new s(P,4,!1,P,null,!1,!1)}),["cols","rows","size","span"].forEach(function(P){l[P]=new s(P,6,!1,P,null,!1,!1)}),["rowSpan","start"].forEach(function(P){l[P]=new s(P,5,!1,P.toLowerCase(),null,!1,!1)});var u=/[\-:]([a-z])/g;function d(P){return P[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(P){var W=P.replace(u,d);l[W]=new s(W,1,!1,P,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(P){var W=P.replace(u,d);l[W]=new s(W,1,!1,P,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(P){var W=P.replace(u,d);l[W]=new s(W,1,!1,P,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(P){l[P]=new s(P,1,!1,P.toLowerCase(),null,!1,!1)}),l.xlinkHref=new s("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(P){l[P]=new s(P,1,!1,P.toLowerCase(),null,!0,!0)});var h={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},p=["Webkit","ms","Moz","O"];Object.keys(h).forEach(function(P){p.forEach(function(W){W=W+P.charAt(0).toUpperCase()+P.substring(1),h[W]=h[P]})});var m=/["'&<>]/;function b(P){if(typeof P=="boolean"||typeof P=="number")return""+P;P=""+P;var W=m.exec(P);if(W){var te="",ae,Se=0;for(ae=W.index;ae<P.length;ae++){switch(P.charCodeAt(ae)){case 34:W=""";break;case 38:W="&";break;case 39:W="'";break;case 60:W="<";break;case 62:W=">";break;default:continue}Se!==ae&&(te+=P.substring(Se,ae)),Se=ae+1,te+=W}P=Se!==ae?te+P.substring(Se,ae):te}return P}var v=/([A-Z])/g,y=/^ms-/,S=Array.isArray;function x(P,W){return{insertionMode:P,selectedValue:W}}function C(P,W,te){switch(W){case"select":return x(1,te.value!=null?te.value:te.defaultValue);case"svg":return x(2,null);case"math":return x(3,null);case"foreignObject":return x(1,null);case"table":return x(4,null);case"thead":case"tbody":case"tfoot":return x(5,null);case"colgroup":return x(7,null);case"tr":return x(6,null)}return 4<=P.insertionMode||P.insertionMode===0?x(1,null):P}var k=new Map;function M(P,W,te){if(typeof te!="object")throw Error(t(62));W=!0;for(var ae in te)if(n.call(te,ae)){var Se=te[ae];if(Se!=null&&typeof Se!="boolean"&&Se!==""){if(ae.indexOf("--")===0){var ve=b(ae);Se=b((""+Se).trim())}else{ve=ae;var De=k.get(ve);De!==void 0||(De=b(ve.replace(v,"-$1").toLowerCase().replace(y,"-ms-")),k.set(ve,De)),ve=De,Se=typeof Se=="number"?Se===0||n.call(h,ae)?""+Se:Se+"px":b((""+Se).trim())}W?(W=!1,P.push(' style="',ve,":",Se)):P.push(";",ve,":",Se)}}W||P.push('"')}function I(P,W,te,ae){switch(te){case"style":M(P,W,ae);return;case"defaultValue":case"defaultChecked":case"innerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":return}if(!(2<te.length)||te[0]!=="o"&&te[0]!=="O"||te[1]!=="n"&&te[1]!=="N"){if(W=l.hasOwnProperty(te)?l[te]:null,W!==null){switch(typeof ae){case"function":case"symbol":return;case"boolean":if(!W.acceptsBooleans)return}switch(te=W.attributeName,W.type){case 3:ae&&P.push(" ",te,'=""');break;case 4:ae===!0?P.push(" ",te,'=""'):ae!==!1&&P.push(" ",te,'="',b(ae),'"');break;case 5:isNaN(ae)||P.push(" ",te,'="',b(ae),'"');break;case 6:!isNaN(ae)&&1<=ae&&P.push(" ",te,'="',b(ae),'"');break;default:W.sanitizeURL&&(ae=""+ae),P.push(" ",te,'="',b(ae),'"')}}else if(a(te)){switch(typeof ae){case"function":case"symbol":return;case"boolean":if(W=te.toLowerCase().slice(0,5),W!=="data-"&&W!=="aria-")return}P.push(" ",te,'="',b(ae),'"')}}}function O(P,W,te){if(W!=null){if(te!=null)throw Error(t(60));if(typeof W!="object"||!("__html"in W))throw Error(t(61));W=W.__html,W!=null&&P.push(""+W)}}function R(P){var W="";return e.Children.forEach(P,function(te){te!=null&&(W+=te)}),W}function L(P,W,te,ae){P.push(H(te));var Se=te=null,ve;for(ve in W)if(n.call(W,ve)){var De=W[ve];if(De!=null)switch(ve){case"children":te=De;break;case"dangerouslySetInnerHTML":Se=De;break;default:I(P,ae,ve,De)}}return P.push(">"),O(P,Se,te),typeof te=="string"?(P.push(b(te)),null):te}var B=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,_=new Map;function H(P){var W=_.get(P);if(W===void 0){if(!B.test(P))throw Error(t(65,P));W="<"+P,_.set(P,W)}return W}function U(P,W,te,ae,Se){switch(W){case"select":P.push(H("select"));var ve=null,De=null;for(kt in te)if(n.call(te,kt)){var Ve=te[kt];if(Ve!=null)switch(kt){case"children":ve=Ve;break;case"dangerouslySetInnerHTML":De=Ve;break;case"defaultValue":case"value":break;default:I(P,ae,kt,Ve)}}return P.push(">"),O(P,De,ve),ve;case"option":De=Se.selectedValue,P.push(H("option"));var Ke=Ve=null,yt=null,kt=null;for(ve in te)if(n.call(te,ve)){var ln=te[ve];if(ln!=null)switch(ve){case"children":Ve=ln;break;case"selected":yt=ln;break;case"dangerouslySetInnerHTML":kt=ln;break;case"value":Ke=ln;default:I(P,ae,ve,ln)}}if(De!=null)if(te=Ke!==null?""+Ke:R(Ve),S(De)){for(ae=0;ae<De.length;ae++)if(""+De[ae]===te){P.push(' selected=""');break}}else""+De===te&&P.push(' selected=""');else yt&&P.push(' selected=""');return P.push(">"),O(P,kt,Ve),Ve;case"textarea":P.push(H("textarea")),kt=De=ve=null;for(Ve in te)if(n.call(te,Ve)&&(Ke=te[Ve],Ke!=null))switch(Ve){case"children":kt=Ke;break;case"value":ve=Ke;break;case"defaultValue":De=Ke;break;case"dangerouslySetInnerHTML":throw Error(t(91));default:I(P,ae,Ve,Ke)}if(ve===null&&De!==null&&(ve=De),P.push(">"),kt!=null){if(ve!=null)throw Error(t(92));if(S(kt)&&1<kt.length)throw Error(t(93));ve=""+kt}return typeof ve=="string"&&ve[0]===`
|
|
|
`&&P.push(`
|
|
|
`),ve!==null&&P.push(b(""+ve)),null;case"input":P.push(H("input")),Ke=kt=Ve=ve=null;for(De in te)if(n.call(te,De)&&(yt=te[De],yt!=null))switch(De){case"children":case"dangerouslySetInnerHTML":throw Error(t(399,"input"));case"defaultChecked":Ke=yt;break;case"defaultValue":Ve=yt;break;case"checked":kt=yt;break;case"value":ve=yt;break;default:I(P,ae,De,yt)}return kt!==null?I(P,ae,"checked",kt):Ke!==null&&I(P,ae,"checked",Ke),ve!==null?I(P,ae,"value",ve):Ve!==null&&I(P,ae,"value",Ve),P.push("/>"),null;case"menuitem":P.push(H("menuitem"));for(var To in te)if(n.call(te,To)&&(ve=te[To],ve!=null))switch(To){case"children":case"dangerouslySetInnerHTML":throw Error(t(400));default:I(P,ae,To,ve)}return P.push(">"),null;case"title":P.push(H("title")),ve=null;for(ln in te)if(n.call(te,ln)&&(De=te[ln],De!=null))switch(ln){case"children":ve=De;break;case"dangerouslySetInnerHTML":throw Error(t(434));default:I(P,ae,ln,De)}return P.push(">"),ve;case"listing":case"pre":P.push(H(W)),De=ve=null;for(Ke in te)if(n.call(te,Ke)&&(Ve=te[Ke],Ve!=null))switch(Ke){case"children":ve=Ve;break;case"dangerouslySetInnerHTML":De=Ve;break;default:I(P,ae,Ke,Ve)}if(P.push(">"),De!=null){if(ve!=null)throw Error(t(60));if(typeof De!="object"||!("__html"in De))throw Error(t(61));te=De.__html,te!=null&&(typeof te=="string"&&0<te.length&&te[0]===`
|
|
|
`?P.push(`
|
|
|
`,te):P.push(""+te))}return typeof ve=="string"&&ve[0]===`
|
|
|
`&&P.push(`
|
|
|
`),ve;case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":P.push(H(W));for(var xo in te)if(n.call(te,xo)&&(ve=te[xo],ve!=null))switch(xo){case"children":case"dangerouslySetInnerHTML":throw Error(t(399,W));default:I(P,ae,xo,ve)}return P.push("/>"),null;case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return L(P,te,W,ae);case"html":return Se.insertionMode===0&&P.push("<!DOCTYPE html>"),L(P,te,W,ae);default:if(W.indexOf("-")===-1&&typeof te.is!="string")return L(P,te,W,ae);P.push(H(W)),De=ve=null;for(yt in te)if(n.call(te,yt)&&(Ve=te[yt],Ve!=null))switch(yt){case"children":ve=Ve;break;case"dangerouslySetInnerHTML":De=Ve;break;case"style":M(P,ae,Ve);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":break;default:a(yt)&&typeof Ve!="function"&&typeof Ve!="symbol"&&P.push(" ",yt,'="',b(Ve),'"')}return P.push(">"),O(P,De,ve),ve}}function G(P,W,te){if(P.push('<!--$?--><template id="'),te===null)throw Error(t(395));return P.push(te),P.push('"></template>')}function K(P,W,te,ae){switch(te.insertionMode){case 0:case 1:return P.push('<div hidden id="'),P.push(W.segmentPrefix),W=ae.toString(16),P.push(W),P.push('">');case 2:return P.push('<svg aria-hidden="true" style="display:none" id="'),P.push(W.segmentPrefix),W=ae.toString(16),P.push(W),P.push('">');case 3:return P.push('<math aria-hidden="true" style="display:none" id="'),P.push(W.segmentPrefix),W=ae.toString(16),P.push(W),P.push('">');case 4:return P.push('<table hidden id="'),P.push(W.segmentPrefix),W=ae.toString(16),P.push(W),P.push('">');case 5:return P.push('<table hidden><tbody id="'),P.push(W.segmentPrefix),W=ae.toString(16),P.push(W),P.push('">');case 6:return P.push('<table hidden><tr id="'),P.push(W.segmentPrefix),W=ae.toString(16),P.push(W),P.push('">');case 7:return P.push('<table hidden><colgroup id="'),P.push(W.segmentPrefix),W=ae.toString(16),P.push(W),P.push('">');default:throw Error(t(397))}}function z(P,W){switch(W.insertionMode){case 0:case 1:return P.push("</div>");case 2:return P.push("</svg>");case 3:return P.push("</math>");case 4:return P.push("</table>");case 5:return P.push("</tbody></table>");case 6:return P.push("</tr></table>");case 7:return P.push("</colgroup></table>");default:throw Error(t(397))}}var ne=/[<\u2028\u2029]/g;function J(P){return JSON.stringify(P).replace(ne,function(W){switch(W){case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSStringsForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}})}function ee(P,W){return W=W===void 0?"":W,{bootstrapChunks:[],startInlineScript:"<script>",placeholderPrefix:W+"P:",segmentPrefix:W+"S:",boundaryPrefix:W+"B:",idPrefix:W,nextSuspenseID:0,sentCompleteSegmentFunction:!1,sentCompleteBoundaryFunction:!1,sentClientRenderFunction:!1,generateStaticMarkup:P}}function Z(P,W,te,ae){return te.generateStaticMarkup?(P.push(b(W)),!1):(W===""?P=ae:(ae&&P.push("<!-- -->"),P.push(b(W)),P=!0),P)}var q=Object.assign,$=Symbol.for("react.element"),re=Symbol.for("react.portal"),le=Symbol.for("react.fragment"),ie=Symbol.for("react.strict_mode"),fe=Symbol.for("react.profiler"),ye=Symbol.for("react.provider"),ge=Symbol.for("react.context"),me=Symbol.for("react.forward_ref"),Ce=Symbol.for("react.suspense"),je=Symbol.for("react.suspense_list"),Ie=Symbol.for("react.memo"),Fe=Symbol.for("react.lazy"),ce=Symbol.for("react.scope"),Ne=Symbol.for("react.debug_trace_mode"),Pe=Symbol.for("react.legacy_hidden"),_e=Symbol.for("react.default_value"),qe=Symbol.iterator;function Xe(P){if(P==null)return null;if(typeof P=="function")return P.displayName||P.name||null;if(typeof P=="string")return P;switch(P){case le:return"Fragment";case re:return"Portal";case fe:return"Profiler";case ie:return"StrictMode";case Ce:return"Suspense";case je:return"SuspenseList"}if(typeof P=="object")switch(P.$$typeof){case ge:return(P.displayName||"Context")+".Consumer";case ye:return(P._context.displayName||"Context")+".Provider";case me:var W=P.render;return P=P.displayName,P||(P=W.displayName||W.name||"",P=P!==""?"ForwardRef("+P+")":"ForwardRef"),P;case Ie:return W=P.displayName||null,W!==null?W:Xe(P.type)||"Memo";case Fe:W=P._payload,P=P._init;try{return Xe(P(W))}catch{}}return null}var Qe={};function it(P,W){if(P=P.contextTypes,!P)return Qe;var te={},ae;for(ae in P)te[ae]=W[ae];return te}var at=null;function vt(P,W){if(P!==W){P.context._currentValue2=P.parentValue,P=P.parent;var te=W.parent;if(P===null){if(te!==null)throw Error(t(401))}else{if(te===null)throw Error(t(401));vt(P,te)}W.context._currentValue2=W.value}}function Mt(P){P.context._currentValue2=P.parentValue,P=P.parent,P!==null&&Mt(P)}function Kt(P){var W=P.parent;W!==null&&Kt(W),P.context._currentValue2=P.value}function gn(P,W){if(P.context._currentValue2=P.parentValue,P=P.parent,P===null)throw Error(t(402));P.depth===W.depth?vt(P,W):gn(P,W)}function Ge(P,W){var te=W.parent;if(te===null)throw Error(t(402));P.depth===te.depth?vt(P,te):Ge(P,te),W.context._currentValue2=W.value}function ut(P){var W=at;W!==P&&(W===null?Kt(P):P===null?Mt(W):W.depth===P.depth?vt(W,P):W.depth>P.depth?gn(W,P):Ge(W,P),at=P)}var mt={isMounted:function(){return!1},enqueueSetState:function(P,W){P=P._reactInternals,P.queue!==null&&P.queue.push(W)},enqueueReplaceState:function(P,W){P=P._reactInternals,P.replace=!0,P.queue=[W]},enqueueForceUpdate:function(){}};function It(P,W,te,ae){var Se=P.state!==void 0?P.state:null;P.updater=mt,P.props=te,P.state=Se;var ve={queue:[],replace:!1};P._reactInternals=ve;var De=W.contextType;if(P.context=typeof De=="object"&&De!==null?De._currentValue2:ae,De=W.getDerivedStateFromProps,typeof De=="function"&&(De=De(te,Se),Se=De==null?Se:q({},Se,De),P.state=Se),typeof W.getDerivedStateFromProps!="function"&&typeof P.getSnapshotBeforeUpdate!="function"&&(typeof P.UNSAFE_componentWillMount=="function"||typeof P.componentWillMount=="function"))if(W=P.state,typeof P.componentWillMount=="function"&&P.componentWillMount(),typeof P.UNSAFE_componentWillMount=="function"&&P.UNSAFE_componentWillMount(),W!==P.state&&mt.enqueueReplaceState(P,P.state,null),ve.queue!==null&&0<ve.queue.length)if(W=ve.queue,De=ve.replace,ve.queue=null,ve.replace=!1,De&&W.length===1)P.state=W[0];else{for(ve=De?W[0]:P.state,Se=!0,De=De?1:0;De<W.length;De++){var Ve=W[De];Ve=typeof Ve=="function"?Ve.call(P,ve,te,ae):Ve,Ve!=null&&(Se?(Se=!1,ve=q({},ve,Ve)):q(ve,Ve))}P.state=ve}else ve.queue=null}var Ot={id:1,overflow:""};function Zn(P,W,te){var ae=P.id;P=P.overflow;var Se=32-$n(ae)-1;ae&=~(1<<Se),te+=1;var ve=32-$n(W)+Se;if(30<ve){var De=Se-Se%5;return ve=(ae&(1<<De)-1).toString(32),ae>>=De,Se-=De,{id:1<<32-$n(W)+Se|te<<Se|ae,overflow:ve+P}}return{id:1<<ve|te<<Se|ae,overflow:P}}var $n=Math.clz32?Math.clz32:Pn,io=Math.log,Tn=Math.LN2;function Pn(P){return P>>>=0,P===0?32:31-(io(P)/Tn|0)|0}function er(P,W){return P===W&&(P!==0||1/P===1/W)||P!==P&&W!==W}var ir=typeof Object.is=="function"?Object.is:er,Gt=null,gr=null,Un=null,Et=null,Yr=!1,Mr=!1,wo=0,jn=null,ao=0;function qn(){if(Gt===null)throw Error(t(321));return Gt}function so(){if(0<ao)throw Error(t(312));return{memoizedState:null,queue:null,next:null}}function Ur(){return Et===null?Un===null?(Yr=!1,Un=Et=so()):(Yr=!0,Et=Un):Et.next===null?(Yr=!1,Et=Et.next=so()):(Yr=!0,Et=Et.next),Et}function So(){gr=Gt=null,Mr=!1,Un=null,ao=0,Et=jn=null}function wi(P,W){return typeof W=="function"?W(P):W}function Ms(P,W,te){if(Gt=qn(),Et=Ur(),Yr){var ae=Et.queue;if(W=ae.dispatch,jn!==null&&(te=jn.get(ae),te!==void 0)){jn.delete(ae),ae=Et.memoizedState;do ae=P(ae,te.action),te=te.next;while(te!==null);return Et.memoizedState=ae,[ae,W]}return[Et.memoizedState,W]}return P=P===wi?typeof W=="function"?W():W:te!==void 0?te(W):W,Et.memoizedState=P,P=Et.queue={last:null,dispatch:null},P=P.dispatch=Nl.bind(null,Gt,P),[Et.memoizedState,P]}function Ca(P,W){if(Gt=qn(),Et=Ur(),W=W===void 0?null:W,Et!==null){var te=Et.memoizedState;if(te!==null&&W!==null){var ae=te[1];e:if(ae===null)ae=!1;else{for(var Se=0;Se<ae.length&&Se<W.length;Se++)if(!ir(W[Se],ae[Se])){ae=!1;break e}ae=!0}if(ae)return te[0]}}return P=P(),Et.memoizedState=[P,W],P}function Nl(P,W,te){if(25<=ao)throw Error(t(301));if(P===Gt)if(Mr=!0,P={action:te,next:null},jn===null&&(jn=new Map),te=jn.get(W),te===void 0)jn.set(W,P);else{for(W=te;W.next!==null;)W=W.next;W.next=P}}function Ol(){throw Error(t(394))}function Ma(){}var cd={readContext:function(P){return P._currentValue2},useContext:function(P){return qn(),P._currentValue2},useMemo:Ca,useReducer:Ms,useRef:function(P){Gt=qn(),Et=Ur();var W=Et.memoizedState;return W===null?(P={current:P},Et.memoizedState=P):W},useState:function(P){return Ms(wi,P)},useInsertionEffect:Ma,useLayoutEffect:function(){},useCallback:function(P,W){return Ca(function(){return P},W)},useImperativeHandle:Ma,useEffect:Ma,useDebugValue:Ma,useDeferredValue:function(P){return qn(),P},useTransition:function(){return qn(),[!1,Ol]},useId:function(){var P=gr.treeContext,W=P.overflow;P=P.id,P=(P&~(1<<32-$n(P)-1)).toString(32)+W;var te=Pl;if(te===null)throw Error(t(404));return W=wo++,P=":"+te.idPrefix+"R"+P,0<W&&(P+="H"+W.toString(32)),P+":"},useMutableSource:function(P,W){return qn(),W(P._source)},useSyncExternalStore:function(P,W,te){if(te===void 0)throw Error(t(407));return te()}},Pl=null,Lc=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentDispatcher;function Zi(P){return console.error(P),null}function Da(){}function ud(P,W,te,ae,Se,ve,De,Ve,Ke){var yt=[],kt=new Set;return W={destination:null,responseState:W,progressiveChunkSize:ae===void 0?12800:ae,status:0,fatalError:null,nextSegmentId:0,allPendingTasks:0,pendingRootTasks:0,completedRootSegment:null,abortableTasks:kt,pingedTasks:yt,clientRenderedBoundaries:[],completedBoundaries:[],partialBoundaries:[],onError:Se===void 0?Zi:Se,onAllReady:ve===void 0?Da:ve,onShellReady:De===void 0?Da:De,onShellError:Ve===void 0?Da:Ve,onFatalError:Ke===void 0?Da:Ke},te=Ds(W,0,null,te,!1,!1),te.parentFlushed=!0,P=Rc(W,P,null,te,kt,Qe,null,Ot),yt.push(P),W}function Rc(P,W,te,ae,Se,ve,De,Ve){P.allPendingTasks++,te===null?P.pendingRootTasks++:te.pendingTasks++;var Ke={node:W,ping:function(){var yt=P.pingedTasks;yt.push(Ke),yt.length===1&&lo(P)},blockedBoundary:te,blockedSegment:ae,abortSet:Se,legacyContext:ve,context:De,treeContext:Ve};return Se.add(Ke),Ke}function Ds(P,W,te,ae,Se,ve){return{status:0,id:-1,index:W,parentFlushed:!1,chunks:[],children:[],formatContext:ae,boundary:te,lastPushedText:Se,textEmbedded:ve}}function Aa(P,W){if(P=P.onError(W),P!=null&&typeof P!="string")throw Error('onError returned something with a type other than "string". onError should return a string and may return null or undefined but must not return anything else. It received something of type "'+typeof P+'" instead');return P}function As(P,W){var te=P.onShellError;te(W),te=P.onFatalError,te(W),P.destination!==null?(P.status=2,P.destination.destroy(W)):(P.status=1,P.fatalError=W)}function Fc(P,W,te,ae,Se){for(Gt={},gr=W,wo=0,P=te(ae,Se);Mr;)Mr=!1,wo=0,ao+=1,Et=null,P=te(ae,Se);return So(),P}function dd(P,W,te,ae){var Se=te.render(),ve=ae.childContextTypes;if(ve!=null){var De=W.legacyContext;if(typeof te.getChildContext!="function")ae=De;else{te=te.getChildContext();for(var Ve in te)if(!(Ve in ve))throw Error(t(108,Xe(ae)||"Unknown",Ve));ae=q({},De,te)}W.legacyContext=ae,Dr(P,W,Se),W.legacyContext=De}else Dr(P,W,Se)}function fd(P,W){if(P&&P.defaultProps){W=q({},W),P=P.defaultProps;for(var te in P)W[te]===void 0&&(W[te]=P[te]);return W}return W}function fn(P,W,te,ae,Se){if(typeof te=="function")if(te.prototype&&te.prototype.isReactComponent){Se=it(te,W.legacyContext);var ve=te.contextType;ve=new te(ae,typeof ve=="object"&&ve!==null?ve._currentValue2:Se),It(ve,te,ae,Se),dd(P,W,ve,te)}else{ve=it(te,W.legacyContext),Se=Fc(P,W,te,ae,ve);var De=wo!==0;if(typeof Se=="object"&&Se!==null&&typeof Se.render=="function"&&Se.$$typeof===void 0)It(Se,te,ae,ve),dd(P,W,Se,te);else if(De){ae=W.treeContext,W.treeContext=Zn(ae,1,0);try{Dr(P,W,Se)}finally{W.treeContext=ae}}else Dr(P,W,Se)}else if(typeof te=="string"){switch(Se=W.blockedSegment,ve=U(Se.chunks,te,ae,P.responseState,Se.formatContext),Se.lastPushedText=!1,De=Se.formatContext,Se.formatContext=C(De,te,ae),Ll(P,W,ve),Se.formatContext=De,te){case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"input":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":break;default:Se.chunks.push("</",te,">")}Se.lastPushedText=!1}else{switch(te){case Pe:case Ne:case ie:case fe:case le:Dr(P,W,ae.children);return;case je:Dr(P,W,ae.children);return;case ce:throw Error(t(343));case Ce:e:{te=W.blockedBoundary,Se=W.blockedSegment,ve=ae.fallback,ae=ae.children,De=new Set;var Ve={id:null,rootSegmentID:-1,parentFlushed:!1,pendingTasks:0,forceClientRender:!1,completedSegments:[],byteSize:0,fallbackAbortableTasks:De,errorDigest:null},Ke=Ds(P,Se.chunks.length,Ve,Se.formatContext,!1,!1);Se.children.push(Ke),Se.lastPushedText=!1;var yt=Ds(P,0,null,Se.formatContext,!1,!1);yt.parentFlushed=!0,W.blockedBoundary=Ve,W.blockedSegment=yt;try{if(Ll(P,W,ae),P.responseState.generateStaticMarkup||yt.lastPushedText&&yt.textEmbedded&&yt.chunks.push("<!-- -->"),yt.status=1,$i(Ve,yt),Ve.pendingTasks===0)break e}catch(kt){yt.status=4,Ve.forceClientRender=!0,Ve.errorDigest=Aa(P,kt)}finally{W.blockedBoundary=te,W.blockedSegment=Se}W=Rc(P,ve,te,Ke,De,W.legacyContext,W.context,W.treeContext),P.pingedTasks.push(W)}return}if(typeof te=="object"&&te!==null)switch(te.$$typeof){case me:if(ae=Fc(P,W,te.render,ae,Se),wo!==0){te=W.treeContext,W.treeContext=Zn(te,1,0);try{Dr(P,W,ae)}finally{W.treeContext=te}}else Dr(P,W,ae);return;case Ie:te=te.type,ae=fd(te,ae),fn(P,W,te,ae,Se);return;case ye:if(Se=ae.children,te=te._context,ae=ae.value,ve=te._currentValue2,te._currentValue2=ae,De=at,at=ae={parent:De,depth:De===null?0:De.depth+1,context:te,parentValue:ve,value:ae},W.context=ae,Dr(P,W,Se),P=at,P===null)throw Error(t(403));ae=P.parentValue,P.context._currentValue2=ae===_e?P.context._defaultValue:ae,P=at=P.parent,W.context=P;return;case ge:ae=ae.children,ae=ae(te._currentValue2),Dr(P,W,ae);return;case Fe:Se=te._init,te=Se(te._payload),ae=fd(te,ae),fn(P,W,te,ae,void 0);return}throw Error(t(130,te==null?te:typeof te,""))}}function Dr(P,W,te){if(W.node=te,typeof te=="object"&&te!==null){switch(te.$$typeof){case $:fn(P,W,te.type,te.props,te.ref);return;case re:throw Error(t(257));case Fe:var ae=te._init;te=ae(te._payload),Dr(P,W,te);return}if(S(te)){jl(P,W,te);return}if(te===null||typeof te!="object"?ae=null:(ae=qe&&te[qe]||te["@@iterator"],ae=typeof ae=="function"?ae:null),ae&&(ae=ae.call(te))){if(te=ae.next(),!te.done){var Se=[];do Se.push(te.value),te=ae.next();while(!te.done);jl(P,W,Se)}return}throw P=Object.prototype.toString.call(te),Error(t(31,P==="[object Object]"?"object with keys {"+Object.keys(te).join(", ")+"}":P))}typeof te=="string"?(ae=W.blockedSegment,ae.lastPushedText=Z(W.blockedSegment.chunks,te,P.responseState,ae.lastPushedText)):typeof te=="number"&&(ae=W.blockedSegment,ae.lastPushedText=Z(W.blockedSegment.chunks,""+te,P.responseState,ae.lastPushedText))}function jl(P,W,te){for(var ae=te.length,Se=0;Se<ae;Se++){var ve=W.treeContext;W.treeContext=Zn(ve,ae,Se);try{Ll(P,W,te[Se])}finally{W.treeContext=ve}}}function Ll(P,W,te){var ae=W.blockedSegment.formatContext,Se=W.legacyContext,ve=W.context;try{return Dr(P,W,te)}catch(Ke){if(So(),typeof Ke=="object"&&Ke!==null&&typeof Ke.then=="function"){te=Ke;var De=W.blockedSegment,Ve=Ds(P,De.chunks.length,null,De.formatContext,De.lastPushedText,!0);De.children.push(Ve),De.lastPushedText=!1,P=Rc(P,W.node,W.blockedBoundary,Ve,W.abortSet,W.legacyContext,W.context,W.treeContext).ping,te.then(P,P),W.blockedSegment.formatContext=ae,W.legacyContext=Se,W.context=ve,ut(ve)}else throw W.blockedSegment.formatContext=ae,W.legacyContext=Se,W.context=ve,ut(ve),Ke}}function Na(P){var W=P.blockedBoundary;P=P.blockedSegment,P.status=3,$o(this,W,P)}function hd(P,W,te){var ae=P.blockedBoundary;P.blockedSegment.status=3,ae===null?(W.allPendingTasks--,W.status!==2&&(W.status=2,W.destination!==null&&W.destination.push(null))):(ae.pendingTasks--,ae.forceClientRender||(ae.forceClientRender=!0,P=te===void 0?Error(t(432)):te,ae.errorDigest=W.onError(P),ae.parentFlushed&&W.clientRenderedBoundaries.push(ae)),ae.fallbackAbortableTasks.forEach(function(Se){return hd(Se,W,te)}),ae.fallbackAbortableTasks.clear(),W.allPendingTasks--,W.allPendingTasks===0&&(ae=W.onAllReady,ae()))}function $i(P,W){if(W.chunks.length===0&&W.children.length===1&&W.children[0].boundary===null){var te=W.children[0];te.id=W.id,te.parentFlushed=!0,te.status===1&&$i(P,te)}else P.completedSegments.push(W)}function $o(P,W,te){if(W===null){if(te.parentFlushed){if(P.completedRootSegment!==null)throw Error(t(389));P.completedRootSegment=te}P.pendingRootTasks--,P.pendingRootTasks===0&&(P.onShellError=Da,W=P.onShellReady,W())}else W.pendingTasks--,W.forceClientRender||(W.pendingTasks===0?(te.parentFlushed&&te.status===1&&$i(W,te),W.parentFlushed&&P.completedBoundaries.push(W),W.fallbackAbortableTasks.forEach(Na,P),W.fallbackAbortableTasks.clear()):te.parentFlushed&&te.status===1&&($i(W,te),W.completedSegments.length===1&&W.parentFlushed&&P.partialBoundaries.push(W)));P.allPendingTasks--,P.allPendingTasks===0&&(P=P.onAllReady,P())}function lo(P){if(P.status!==2){var W=at,te=Lc.current;Lc.current=cd;var ae=Pl;Pl=P.responseState;try{var Se=P.pingedTasks,ve;for(ve=0;ve<Se.length;ve++){var De=Se[ve],Ve=P,Ke=De.blockedSegment;if(Ke.status===0){ut(De.context);try{Dr(Ve,De,De.node),Ve.responseState.generateStaticMarkup||Ke.lastPushedText&&Ke.textEmbedded&&Ke.chunks.push("<!-- -->"),De.abortSet.delete(De),Ke.status=1,$o(Ve,De.blockedBoundary,Ke)}catch(zr){if(So(),typeof zr=="object"&&zr!==null&&typeof zr.then=="function"){var yt=De.ping;zr.then(yt,yt)}else{De.abortSet.delete(De),Ke.status=4;var kt=De.blockedBoundary,ln=zr,To=Aa(Ve,ln);if(kt===null?As(Ve,ln):(kt.pendingTasks--,kt.forceClientRender||(kt.forceClientRender=!0,kt.errorDigest=To,kt.parentFlushed&&Ve.clientRenderedBoundaries.push(kt))),Ve.allPendingTasks--,Ve.allPendingTasks===0){var xo=Ve.onAllReady;xo()}}}}}Se.splice(0,ve),P.destination!==null&&qi(P,P.destination)}catch(zr){Aa(P,zr),As(P,zr)}finally{Pl=ae,Lc.current=te,te===cd&&ut(W)}}}function Ns(P,W,te){switch(te.parentFlushed=!0,te.status){case 0:var ae=te.id=P.nextSegmentId++;return te.lastPushedText=!1,te.textEmbedded=!1,P=P.responseState,W.push('<template id="'),W.push(P.placeholderPrefix),P=ae.toString(16),W.push(P),W.push('"></template>');case 1:te.status=2;var Se=!0;ae=te.chunks;var ve=0;te=te.children;for(var De=0;De<te.length;De++){for(Se=te[De];ve<Se.index;ve++)W.push(ae[ve]);Se=ar(P,W,Se)}for(;ve<ae.length-1;ve++)W.push(ae[ve]);return ve<ae.length&&(Se=W.push(ae[ve])),Se;default:throw Error(t(390))}}function ar(P,W,te){var ae=te.boundary;if(ae===null)return Ns(P,W,te);if(ae.parentFlushed=!0,ae.forceClientRender)return P.responseState.generateStaticMarkup||(ae=ae.errorDigest,W.push("<!--$!-->"),W.push("<template"),ae&&(W.push(' data-dgst="'),ae=b(ae),W.push(ae),W.push('"')),W.push("></template>")),Ns(P,W,te),P=P.responseState.generateStaticMarkup?!0:W.push("<!--/$-->"),P;if(0<ae.pendingTasks){ae.rootSegmentID=P.nextSegmentId++,0<ae.completedSegments.length&&P.partialBoundaries.push(ae);var Se=P.responseState,ve=Se.nextSuspenseID++;return Se=Se.boundaryPrefix+ve.toString(16),ae=ae.id=Se,G(W,P.responseState,ae),Ns(P,W,te),W.push("<!--/$-->")}if(ae.byteSize>P.progressiveChunkSize)return ae.rootSegmentID=P.nextSegmentId++,P.completedBoundaries.push(ae),G(W,P.responseState,ae.id),Ns(P,W,te),W.push("<!--/$-->");if(P.responseState.generateStaticMarkup||W.push("<!--$-->"),te=ae.completedSegments,te.length!==1)throw Error(t(391));return ar(P,W,te[0]),P=P.responseState.generateStaticMarkup?!0:W.push("<!--/$-->"),P}function Hc(P,W,te){return K(W,P.responseState,te.formatContext,te.id),ar(P,W,te),z(W,te.formatContext)}function _c(P,W,te){for(var ae=te.completedSegments,Se=0;Se<ae.length;Se++)Bc(P,W,te,ae[Se]);if(ae.length=0,P=P.responseState,ae=te.id,te=te.rootSegmentID,W.push(P.startInlineScript),P.sentCompleteBoundaryFunction?W.push('$RC("'):(P.sentCompleteBoundaryFunction=!0,W.push('function $RC(a,b){a=document.getElementById(a);b=document.getElementById(b);b.parentNode.removeChild(b);if(a){a=a.previousSibling;var f=a.parentNode,c=a.nextSibling,e=0;do{if(c&&8===c.nodeType){var d=c.data;if("/$"===d)if(0===e)break;else e--;else"$"!==d&&"$?"!==d&&"$!"!==d||e++}d=c.nextSibling;f.removeChild(c);c=d}while(c);for(;b.firstChild;)f.insertBefore(b.firstChild,c);a.data="$";a._reactRetry&&a._reactRetry()}};$RC("')),ae===null)throw Error(t(395));return te=te.toString(16),W.push(ae),W.push('","'),W.push(P.segmentPrefix),W.push(te),W.push('")<\/script>')}function Bc(P,W,te,ae){if(ae.status===2)return!0;var Se=ae.id;if(Se===-1){if((ae.id=te.rootSegmentID)===-1)throw Error(t(392));return Hc(P,W,ae)}return Hc(P,W,ae),P=P.responseState,W.push(P.startInlineScript),P.sentCompleteSegmentFunction?W.push('$RS("'):(P.sentCompleteSegmentFunction=!0,W.push('function $RS(a,b){a=document.getElementById(a);b=document.getElementById(b);for(a.parentNode.removeChild(a);a.firstChild;)b.parentNode.insertBefore(a.firstChild,b);b.parentNode.removeChild(b)};$RS("')),W.push(P.segmentPrefix),Se=Se.toString(16),W.push(Se),W.push('","'),W.push(P.placeholderPrefix),W.push(Se),W.push('")<\/script>')}function qi(P,W){try{var te=P.completedRootSegment;if(te!==null&&P.pendingRootTasks===0){ar(P,W,te),P.completedRootSegment=null;var ae=P.responseState.bootstrapChunks;for(te=0;te<ae.length-1;te++)W.push(ae[te]);te<ae.length&&W.push(ae[te])}var Se=P.clientRenderedBoundaries,ve;for(ve=0;ve<Se.length;ve++){var De=Se[ve];ae=W;var Ve=P.responseState,Ke=De.id,yt=De.errorDigest,kt=De.errorMessage,ln=De.errorComponentStack;if(ae.push(Ve.startInlineScript),Ve.sentClientRenderFunction?ae.push('$RX("'):(Ve.sentClientRenderFunction=!0,ae.push('function $RX(b,c,d,e){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),b._reactRetry&&b._reactRetry())};$RX("')),Ke===null)throw Error(t(395));if(ae.push(Ke),ae.push('"'),yt||kt||ln){ae.push(",");var To=J(yt||"");ae.push(To)}if(kt||ln){ae.push(",");var xo=J(kt||"");ae.push(xo)}if(ln){ae.push(",");var zr=J(ln);ae.push(zr)}if(!ae.push(")<\/script>")){P.destination=null,ve++,Se.splice(0,ve);return}}Se.splice(0,ve);var Ki=P.completedBoundaries;for(ve=0;ve<Ki.length;ve++)if(!_c(P,W,Ki[ve])){P.destination=null,ve++,Ki.splice(0,ve);return}Ki.splice(0,ve);var Io=P.partialBoundaries;for(ve=0;ve<Io.length;ve++){var ko=Io[ve];e:{Se=P,De=W;var Vr=ko.completedSegments;for(Ve=0;Ve<Vr.length;Ve++)if(!Bc(Se,De,ko,Vr[Ve])){Ve++,Vr.splice(0,Ve);var qo=!1;break e}Vr.splice(0,Ve),qo=!0}if(!qo){P.destination=null,ve++,Io.splice(0,ve);return}}Io.splice(0,ve);var Eo=P.completedBoundaries;for(ve=0;ve<Eo.length;ve++)if(!_c(P,W,Eo[ve])){P.destination=null,ve++,Eo.splice(0,ve);return}Eo.splice(0,ve)}finally{P.allPendingTasks===0&&P.pingedTasks.length===0&&P.clientRenderedBoundaries.length===0&&P.completedBoundaries.length===0&&W.push(null)}}function Os(P,W){try{var te=P.abortableTasks;te.forEach(function(ae){return hd(ae,P,W)}),te.clear(),P.destination!==null&&qi(P,P.destination)}catch(ae){Aa(P,ae),As(P,ae)}}function Oa(){}function Pa(P,W,te,ae){var Se=!1,ve=null,De="",Ve={push:function(yt){return yt!==null&&(De+=yt),!0},destroy:function(yt){Se=!0,ve=yt}},Ke=!1;if(P=ud(P,ee(te,W?W.identifierPrefix:void 0),{insertionMode:1,selectedValue:null},1/0,Oa,void 0,function(){Ke=!0},void 0,void 0),lo(P),Os(P,ae),P.status===1)P.status=2,Ve.destroy(P.fatalError);else if(P.status!==2&&P.destination===null){P.destination=Ve;try{qi(P,Ve)}catch(yt){Aa(P,yt),As(P,yt)}}if(Se)throw ve;if(!Ke)throw Error(t(426));return De}return du.renderToNodeStream=function(){throw Error(t(207))},du.renderToStaticMarkup=function(P,W){return Pa(P,W,!0,'The server used "renderToStaticMarkup" which does not support Suspense. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server')},du.renderToStaticNodeStream=function(){throw Error(t(208))},du.renderToString=function(P,W){return Pa(P,W,!1,'The server used "renderToString" which does not support Suspense. If you intended for this Suspense boundary to render the fallback content on the server consider throwing an Error somewhere within the Suspense boundary. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server')},du.version="18.2.0",du}var Sb={},I5;function sFe(){if(I5)return Sb;I5=1;var e=D;function t(j){for(var V="https://reactjs.org/docs/error-decoder.html?invariant="+j,Q=1;Q<arguments.length;Q++)V+="&args[]="+encodeURIComponent(arguments[Q]);return"Minified React error #"+j+"; visit "+V+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var n=null,r=0;function o(j,V){if(V.length!==0)if(512<V.length)0<r&&(j.enqueue(new Uint8Array(n.buffer,0,r)),n=new Uint8Array(512),r=0),j.enqueue(V);else{var Q=n.length-r;Q<V.length&&(Q===0?j.enqueue(n):(n.set(V.subarray(0,Q),r),j.enqueue(n),V=V.subarray(Q)),n=new Uint8Array(512),r=0),n.set(V,r),r+=V.length}}function i(j,V){return o(j,V),!0}function a(j){n&&0<r&&(j.enqueue(new Uint8Array(n.buffer,0,r)),n=null,r=0)}var s=new TextEncoder;function l(j){return s.encode(j)}function u(j){return s.encode(j)}function d(j,V){typeof j.error=="function"?j.error(V):j.close()}var h=Object.prototype.hasOwnProperty,p=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,m={},b={};function v(j){return h.call(b,j)?!0:h.call(m,j)?!1:p.test(j)?b[j]=!0:(m[j]=!0,!1)}function y(j,V,Q,oe,xe,we,Ae){this.acceptsBooleans=V===2||V===3||V===4,this.attributeName=oe,this.attributeNamespace=xe,this.mustUseProperty=Q,this.propertyName=j,this.type=V,this.sanitizeURL=we,this.removeEmptyString=Ae}var S={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(j){S[j]=new y(j,0,!1,j,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(j){var V=j[0];S[V]=new y(V,1,!1,j[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(j){S[j]=new y(j,2,!1,j.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(j){S[j]=new y(j,2,!1,j,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(j){S[j]=new y(j,3,!1,j.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(j){S[j]=new y(j,3,!0,j,null,!1,!1)}),["capture","download"].forEach(function(j){S[j]=new y(j,4,!1,j,null,!1,!1)}),["cols","rows","size","span"].forEach(function(j){S[j]=new y(j,6,!1,j,null,!1,!1)}),["rowSpan","start"].forEach(function(j){S[j]=new y(j,5,!1,j.toLowerCase(),null,!1,!1)});var x=/[\-:]([a-z])/g;function C(j){return j[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(j){var V=j.replace(x,C);S[V]=new y(V,1,!1,j,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(j){var V=j.replace(x,C);S[V]=new y(V,1,!1,j,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(j){var V=j.replace(x,C);S[V]=new y(V,1,!1,j,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(j){S[j]=new y(j,1,!1,j.toLowerCase(),null,!1,!1)}),S.xlinkHref=new y("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(j){S[j]=new y(j,1,!1,j.toLowerCase(),null,!0,!0)});var k={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},M=["Webkit","ms","Moz","O"];Object.keys(k).forEach(function(j){M.forEach(function(V){V=V+j.charAt(0).toUpperCase()+j.substring(1),k[V]=k[j]})});var I=/["'&<>]/;function O(j){if(typeof j=="boolean"||typeof j=="number")return""+j;j=""+j;var V=I.exec(j);if(V){var Q="",oe,xe=0;for(oe=V.index;oe<j.length;oe++){switch(j.charCodeAt(oe)){case 34:V=""";break;case 38:V="&";break;case 39:V="'";break;case 60:V="<";break;case 62:V=">";break;default:continue}xe!==oe&&(Q+=j.substring(xe,oe)),xe=oe+1,Q+=V}j=xe!==oe?Q+j.substring(xe,oe):Q}return j}var R=/([A-Z])/g,L=/^ms-/,B=Array.isArray,_=u("<script>"),H=u("<\/script>"),U=u('<script src="'),G=u('<script type="module" src="'),K=u('" async=""><\/script>'),z=/(<\/|<)(s)(cript)/gi;function ne(j,V,Q,oe){return V+(Q==="s"?"\\u0073":"\\u0053")+oe}function J(j,V,Q,oe,xe){j=j===void 0?"":j,V=V===void 0?_:u('<script nonce="'+O(V)+'">');var we=[];if(Q!==void 0&&we.push(V,l((""+Q).replace(z,ne)),H),oe!==void 0)for(Q=0;Q<oe.length;Q++)we.push(U,l(O(oe[Q])),K);if(xe!==void 0)for(oe=0;oe<xe.length;oe++)we.push(G,l(O(xe[oe])),K);return{bootstrapChunks:we,startInlineScript:V,placeholderPrefix:u(j+"P:"),segmentPrefix:u(j+"S:"),boundaryPrefix:j+"B:",idPrefix:j,nextSuspenseID:0,sentCompleteSegmentFunction:!1,sentCompleteBoundaryFunction:!1,sentClientRenderFunction:!1}}function ee(j,V){return{insertionMode:j,selectedValue:V}}function Z(j){return ee(j==="http://www.w3.org/2000/svg"?2:j==="http://www.w3.org/1998/Math/MathML"?3:0,null)}function q(j,V,Q){switch(V){case"select":return ee(1,Q.value!=null?Q.value:Q.defaultValue);case"svg":return ee(2,null);case"math":return ee(3,null);case"foreignObject":return ee(1,null);case"table":return ee(4,null);case"thead":case"tbody":case"tfoot":return ee(5,null);case"colgroup":return ee(7,null);case"tr":return ee(6,null)}return 4<=j.insertionMode||j.insertionMode===0?ee(1,null):j}var $=u("<!-- -->");function re(j,V,Q,oe){return V===""?oe:(oe&&j.push($),j.push(l(O(V))),!0)}var le=new Map,ie=u(' style="'),fe=u(":"),ye=u(";");function ge(j,V,Q){if(typeof Q!="object")throw Error(t(62));V=!0;for(var oe in Q)if(h.call(Q,oe)){var xe=Q[oe];if(xe!=null&&typeof xe!="boolean"&&xe!==""){if(oe.indexOf("--")===0){var we=l(O(oe));xe=l(O((""+xe).trim()))}else{we=oe;var Ae=le.get(we);Ae!==void 0||(Ae=u(O(we.replace(R,"-$1").toLowerCase().replace(L,"-ms-"))),le.set(we,Ae)),we=Ae,xe=typeof xe=="number"?xe===0||h.call(k,oe)?l(""+xe):l(xe+"px"):l(O((""+xe).trim()))}V?(V=!1,j.push(ie,we,fe,xe)):j.push(ye,we,fe,xe)}}V||j.push(je)}var me=u(" "),Ce=u('="'),je=u('"'),Ie=u('=""');function Fe(j,V,Q,oe){switch(Q){case"style":ge(j,V,oe);return;case"defaultValue":case"defaultChecked":case"innerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":return}if(!(2<Q.length)||Q[0]!=="o"&&Q[0]!=="O"||Q[1]!=="n"&&Q[1]!=="N"){if(V=S.hasOwnProperty(Q)?S[Q]:null,V!==null){switch(typeof oe){case"function":case"symbol":return;case"boolean":if(!V.acceptsBooleans)return}switch(Q=l(V.attributeName),V.type){case 3:oe&&j.push(me,Q,Ie);break;case 4:oe===!0?j.push(me,Q,Ie):oe!==!1&&j.push(me,Q,Ce,l(O(oe)),je);break;case 5:isNaN(oe)||j.push(me,Q,Ce,l(O(oe)),je);break;case 6:!isNaN(oe)&&1<=oe&&j.push(me,Q,Ce,l(O(oe)),je);break;default:V.sanitizeURL&&(oe=""+oe),j.push(me,Q,Ce,l(O(oe)),je)}}else if(v(Q)){switch(typeof oe){case"function":case"symbol":return;case"boolean":if(V=Q.toLowerCase().slice(0,5),V!=="data-"&&V!=="aria-")return}j.push(me,l(Q),Ce,l(O(oe)),je)}}}var ce=u(">"),Ne=u("/>");function Pe(j,V,Q){if(V!=null){if(Q!=null)throw Error(t(60));if(typeof V!="object"||!("__html"in V))throw Error(t(61));V=V.__html,V!=null&&j.push(l(""+V))}}function _e(j){var V="";return e.Children.forEach(j,function(Q){Q!=null&&(V+=Q)}),V}var qe=u(' selected=""');function Xe(j,V,Q,oe){j.push(vt(Q));var xe=Q=null,we;for(we in V)if(h.call(V,we)){var Ae=V[we];if(Ae!=null)switch(we){case"children":Q=Ae;break;case"dangerouslySetInnerHTML":xe=Ae;break;default:Fe(j,oe,we,Ae)}}return j.push(ce),Pe(j,xe,Q),typeof Q=="string"?(j.push(l(O(Q))),null):Q}var Qe=u(`
|
|
|
`),it=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,at=new Map;function vt(j){var V=at.get(j);if(V===void 0){if(!it.test(j))throw Error(t(65,j));V=u("<"+j),at.set(j,V)}return V}var Mt=u("<!DOCTYPE html>");function Kt(j,V,Q,oe,xe){switch(V){case"select":j.push(vt("select"));var we=null,Ae=null;for(Tt in Q)if(h.call(Q,Tt)){var ze=Q[Tt];if(ze!=null)switch(Tt){case"children":we=ze;break;case"dangerouslySetInnerHTML":Ae=ze;break;case"defaultValue":case"value":break;default:Fe(j,oe,Tt,ze)}}return j.push(ce),Pe(j,Ae,we),we;case"option":Ae=xe.selectedValue,j.push(vt("option"));var gt=ze=null,Dt=null,Tt=null;for(we in Q)if(h.call(Q,we)){var hn=Q[we];if(hn!=null)switch(we){case"children":ze=hn;break;case"selected":Dt=hn;break;case"dangerouslySetInnerHTML":Tt=hn;break;case"value":gt=hn;default:Fe(j,oe,we,hn)}}if(Ae!=null)if(Q=gt!==null?""+gt:_e(ze),B(Ae)){for(oe=0;oe<Ae.length;oe++)if(""+Ae[oe]===Q){j.push(qe);break}}else""+Ae===Q&&j.push(qe);else Dt&&j.push(qe);return j.push(ce),Pe(j,Tt,ze),ze;case"textarea":j.push(vt("textarea")),Tt=Ae=we=null;for(ze in Q)if(h.call(Q,ze)&&(gt=Q[ze],gt!=null))switch(ze){case"children":Tt=gt;break;case"value":we=gt;break;case"defaultValue":Ae=gt;break;case"dangerouslySetInnerHTML":throw Error(t(91));default:Fe(j,oe,ze,gt)}if(we===null&&Ae!==null&&(we=Ae),j.push(ce),Tt!=null){if(we!=null)throw Error(t(92));if(B(Tt)&&1<Tt.length)throw Error(t(93));we=""+Tt}return typeof we=="string"&&we[0]===`
|
|
|
`&&j.push(Qe),we!==null&&j.push(l(O(""+we))),null;case"input":j.push(vt("input")),gt=Tt=ze=we=null;for(Ae in Q)if(h.call(Q,Ae)&&(Dt=Q[Ae],Dt!=null))switch(Ae){case"children":case"dangerouslySetInnerHTML":throw Error(t(399,"input"));case"defaultChecked":gt=Dt;break;case"defaultValue":ze=Dt;break;case"checked":Tt=Dt;break;case"value":we=Dt;break;default:Fe(j,oe,Ae,Dt)}return Tt!==null?Fe(j,oe,"checked",Tt):gt!==null&&Fe(j,oe,"checked",gt),we!==null?Fe(j,oe,"value",we):ze!==null&&Fe(j,oe,"value",ze),j.push(Ne),null;case"menuitem":j.push(vt("menuitem"));for(var Wr in Q)if(h.call(Q,Wr)&&(we=Q[Wr],we!=null))switch(Wr){case"children":case"dangerouslySetInnerHTML":throw Error(t(400));default:Fe(j,oe,Wr,we)}return j.push(ce),null;case"title":j.push(vt("title")),we=null;for(hn in Q)if(h.call(Q,hn)&&(Ae=Q[hn],Ae!=null))switch(hn){case"children":we=Ae;break;case"dangerouslySetInnerHTML":throw Error(t(434));default:Fe(j,oe,hn,Ae)}return j.push(ce),we;case"listing":case"pre":j.push(vt(V)),Ae=we=null;for(gt in Q)if(h.call(Q,gt)&&(ze=Q[gt],ze!=null))switch(gt){case"children":we=ze;break;case"dangerouslySetInnerHTML":Ae=ze;break;default:Fe(j,oe,gt,ze)}if(j.push(ce),Ae!=null){if(we!=null)throw Error(t(60));if(typeof Ae!="object"||!("__html"in Ae))throw Error(t(61));Q=Ae.__html,Q!=null&&(typeof Q=="string"&&0<Q.length&&Q[0]===`
|
|
|
`?j.push(Qe,l(Q)):j.push(l(""+Q)))}return typeof we=="string"&&we[0]===`
|
|
|
`&&j.push(Qe),we;case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":j.push(vt(V));for(var Co in Q)if(h.call(Q,Co)&&(we=Q[Co],we!=null))switch(Co){case"children":case"dangerouslySetInnerHTML":throw Error(t(399,V));default:Fe(j,oe,Co,we)}return j.push(Ne),null;case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return Xe(j,Q,V,oe);case"html":return xe.insertionMode===0&&j.push(Mt),Xe(j,Q,V,oe);default:if(V.indexOf("-")===-1&&typeof Q.is!="string")return Xe(j,Q,V,oe);j.push(vt(V)),Ae=we=null;for(Dt in Q)if(h.call(Q,Dt)&&(ze=Q[Dt],ze!=null))switch(Dt){case"children":we=ze;break;case"dangerouslySetInnerHTML":Ae=ze;break;case"style":ge(j,oe,ze);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":break;default:v(Dt)&&typeof ze!="function"&&typeof ze!="symbol"&&j.push(me,l(Dt),Ce,l(O(ze)),je)}return j.push(ce),Pe(j,Ae,we),we}}var gn=u("</"),Ge=u(">"),ut=u('<template id="'),mt=u('"></template>'),It=u("<!--$-->"),Ot=u('<!--$?--><template id="'),Zn=u('"></template>'),$n=u("<!--$!-->"),io=u("<!--/$-->"),Tn=u("<template"),Pn=u('"'),er=u(' data-dgst="');u(' data-msg="'),u(' data-stck="');var ir=u("></template>");function Gt(j,V,Q){if(o(j,Ot),Q===null)throw Error(t(395));return o(j,Q),i(j,Zn)}var gr=u('<div hidden id="'),Un=u('">'),Et=u("</div>"),Yr=u('<svg aria-hidden="true" style="display:none" id="'),Mr=u('">'),wo=u("</svg>"),jn=u('<math aria-hidden="true" style="display:none" id="'),ao=u('">'),qn=u("</math>"),so=u('<table hidden id="'),Ur=u('">'),So=u("</table>"),wi=u('<table hidden><tbody id="'),Ms=u('">'),Ca=u("</tbody></table>"),Nl=u('<table hidden><tr id="'),Ol=u('">'),Ma=u("</tr></table>"),cd=u('<table hidden><colgroup id="'),Pl=u('">'),Lc=u("</colgroup></table>");function Zi(j,V,Q,oe){switch(Q.insertionMode){case 0:case 1:return o(j,gr),o(j,V.segmentPrefix),o(j,l(oe.toString(16))),i(j,Un);case 2:return o(j,Yr),o(j,V.segmentPrefix),o(j,l(oe.toString(16))),i(j,Mr);case 3:return o(j,jn),o(j,V.segmentPrefix),o(j,l(oe.toString(16))),i(j,ao);case 4:return o(j,so),o(j,V.segmentPrefix),o(j,l(oe.toString(16))),i(j,Ur);case 5:return o(j,wi),o(j,V.segmentPrefix),o(j,l(oe.toString(16))),i(j,Ms);case 6:return o(j,Nl),o(j,V.segmentPrefix),o(j,l(oe.toString(16))),i(j,Ol);case 7:return o(j,cd),o(j,V.segmentPrefix),o(j,l(oe.toString(16))),i(j,Pl);default:throw Error(t(397))}}function Da(j,V){switch(V.insertionMode){case 0:case 1:return i(j,Et);case 2:return i(j,wo);case 3:return i(j,qn);case 4:return i(j,So);case 5:return i(j,Ca);case 6:return i(j,Ma);case 7:return i(j,Lc);default:throw Error(t(397))}}var ud=u('function $RS(a,b){a=document.getElementById(a);b=document.getElementById(b);for(a.parentNode.removeChild(a);a.firstChild;)b.parentNode.insertBefore(a.firstChild,b);b.parentNode.removeChild(b)};$RS("'),Rc=u('$RS("'),Ds=u('","'),Aa=u('")<\/script>'),As=u('function $RC(a,b){a=document.getElementById(a);b=document.getElementById(b);b.parentNode.removeChild(b);if(a){a=a.previousSibling;var f=a.parentNode,c=a.nextSibling,e=0;do{if(c&&8===c.nodeType){var d=c.data;if("/$"===d)if(0===e)break;else e--;else"$"!==d&&"$?"!==d&&"$!"!==d||e++}d=c.nextSibling;f.removeChild(c);c=d}while(c);for(;b.firstChild;)f.insertBefore(b.firstChild,c);a.data="$";a._reactRetry&&a._reactRetry()}};$RC("'),Fc=u('$RC("'),dd=u('","'),fd=u('")<\/script>'),fn=u('function $RX(b,c,d,e){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),b._reactRetry&&b._reactRetry())};$RX("'),Dr=u('$RX("'),jl=u('"'),Ll=u(")<\/script>"),Na=u(","),hd=/[<\u2028\u2029]/g;function $i(j){return JSON.stringify(j).replace(hd,function(V){switch(V){case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSStringsForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}})}var $o=Object.assign,lo=Symbol.for("react.element"),Ns=Symbol.for("react.portal"),ar=Symbol.for("react.fragment"),Hc=Symbol.for("react.strict_mode"),_c=Symbol.for("react.profiler"),Bc=Symbol.for("react.provider"),qi=Symbol.for("react.context"),Os=Symbol.for("react.forward_ref"),Oa=Symbol.for("react.suspense"),Pa=Symbol.for("react.suspense_list"),P=Symbol.for("react.memo"),W=Symbol.for("react.lazy"),te=Symbol.for("react.scope"),ae=Symbol.for("react.debug_trace_mode"),Se=Symbol.for("react.legacy_hidden"),ve=Symbol.for("react.default_value"),De=Symbol.iterator;function Ve(j){if(j==null)return null;if(typeof j=="function")return j.displayName||j.name||null;if(typeof j=="string")return j;switch(j){case ar:return"Fragment";case Ns:return"Portal";case _c:return"Profiler";case Hc:return"StrictMode";case Oa:return"Suspense";case Pa:return"SuspenseList"}if(typeof j=="object")switch(j.$$typeof){case qi:return(j.displayName||"Context")+".Consumer";case Bc:return(j._context.displayName||"Context")+".Provider";case Os:var V=j.render;return j=j.displayName,j||(j=V.displayName||V.name||"",j=j!==""?"ForwardRef("+j+")":"ForwardRef"),j;case P:return V=j.displayName||null,V!==null?V:Ve(j.type)||"Memo";case W:V=j._payload,j=j._init;try{return Ve(j(V))}catch{}}return null}var Ke={};function yt(j,V){if(j=j.contextTypes,!j)return Ke;var Q={},oe;for(oe in j)Q[oe]=V[oe];return Q}var kt=null;function ln(j,V){if(j!==V){j.context._currentValue=j.parentValue,j=j.parent;var Q=V.parent;if(j===null){if(Q!==null)throw Error(t(401))}else{if(Q===null)throw Error(t(401));ln(j,Q)}V.context._currentValue=V.value}}function To(j){j.context._currentValue=j.parentValue,j=j.parent,j!==null&&To(j)}function xo(j){var V=j.parent;V!==null&&xo(V),j.context._currentValue=j.value}function zr(j,V){if(j.context._currentValue=j.parentValue,j=j.parent,j===null)throw Error(t(402));j.depth===V.depth?ln(j,V):zr(j,V)}function Ki(j,V){var Q=V.parent;if(Q===null)throw Error(t(402));j.depth===Q.depth?ln(j,Q):Ki(j,Q),V.context._currentValue=V.value}function Io(j){var V=kt;V!==j&&(V===null?xo(j):j===null?To(V):V.depth===j.depth?ln(V,j):V.depth>j.depth?zr(V,j):Ki(V,j),kt=j)}var ko={isMounted:function(){return!1},enqueueSetState:function(j,V){j=j._reactInternals,j.queue!==null&&j.queue.push(V)},enqueueReplaceState:function(j,V){j=j._reactInternals,j.replace=!0,j.queue=[V]},enqueueForceUpdate:function(){}};function Vr(j,V,Q,oe){var xe=j.state!==void 0?j.state:null;j.updater=ko,j.props=Q,j.state=xe;var we={queue:[],replace:!1};j._reactInternals=we;var Ae=V.contextType;if(j.context=typeof Ae=="object"&&Ae!==null?Ae._currentValue:oe,Ae=V.getDerivedStateFromProps,typeof Ae=="function"&&(Ae=Ae(Q,xe),xe=Ae==null?xe:$o({},xe,Ae),j.state=xe),typeof V.getDerivedStateFromProps!="function"&&typeof j.getSnapshotBeforeUpdate!="function"&&(typeof j.UNSAFE_componentWillMount=="function"||typeof j.componentWillMount=="function"))if(V=j.state,typeof j.componentWillMount=="function"&&j.componentWillMount(),typeof j.UNSAFE_componentWillMount=="function"&&j.UNSAFE_componentWillMount(),V!==j.state&&ko.enqueueReplaceState(j,j.state,null),we.queue!==null&&0<we.queue.length)if(V=we.queue,Ae=we.replace,we.queue=null,we.replace=!1,Ae&&V.length===1)j.state=V[0];else{for(we=Ae?V[0]:j.state,xe=!0,Ae=Ae?1:0;Ae<V.length;Ae++){var ze=V[Ae];ze=typeof ze=="function"?ze.call(j,we,Q,oe):ze,ze!=null&&(xe?(xe=!1,we=$o({},we,ze)):$o(we,ze))}j.state=we}else we.queue=null}var qo={id:1,overflow:""};function Eo(j,V,Q){var oe=j.id;j=j.overflow;var xe=32-ja(oe)-1;oe&=~(1<<xe),Q+=1;var we=32-ja(V)+xe;if(30<we){var Ae=xe-xe%5;return we=(oe&(1<<Ae)-1).toString(32),oe>>=Ae,xe-=Ae,{id:1<<32-ja(V)+xe|Q<<xe|oe,overflow:we+j}}return{id:1<<we|Q<<xe|oe,overflow:j}}var ja=Math.clz32?Math.clz32:Zv,La=Math.log,s1=Math.LN2;function Zv(j){return j>>>=0,j===0?32:31-(La(j)/s1|0)|0}function Yc(j,V){return j===V&&(j!==0||1/j===1/V)||j!==j&&V!==V}var l1=typeof Object.is=="function"?Object.is:Yc,Si=null,Rl=null,Uc=null,cn=null,Xi=!1,Ra=!1,Ti=0,Ko=null,pd=0;function Ps(){if(Si===null)throw Error(t(321));return Si}function md(){if(0<pd)throw Error(t(312));return{memoizedState:null,queue:null,next:null}}function Fl(){return cn===null?Uc===null?(Xi=!1,Uc=cn=md()):(Xi=!0,cn=Uc):cn.next===null?(Xi=!1,cn=cn.next=md()):(Xi=!0,cn=cn.next),cn}function zc(){Rl=Si=null,Ra=!1,Uc=null,pd=0,cn=Ko=null}function qh(j,V){return typeof V=="function"?V(j):V}function Ji(j,V,Q){if(Si=Ps(),cn=Fl(),Xi){var oe=cn.queue;if(V=oe.dispatch,Ko!==null&&(Q=Ko.get(oe),Q!==void 0)){Ko.delete(oe),oe=cn.memoizedState;do oe=j(oe,Q.action),Q=Q.next;while(Q!==null);return cn.memoizedState=oe,[oe,V]}return[cn.memoizedState,V]}return j=j===qh?typeof V=="function"?V():V:Q!==void 0?Q(V):V,cn.memoizedState=j,j=cn.queue={last:null,dispatch:null},j=j.dispatch=vd.bind(null,Si,j),[cn.memoizedState,j]}function gd(j,V){if(Si=Ps(),cn=Fl(),V=V===void 0?null:V,cn!==null){var Q=cn.memoizedState;if(Q!==null&&V!==null){var oe=Q[1];e:if(oe===null)oe=!1;else{for(var xe=0;xe<oe.length&&xe<V.length;xe++)if(!l1(V[xe],oe[xe])){oe=!1;break e}oe=!0}if(oe)return Q[0]}}return j=j(),cn.memoizedState=[j,V],j}function vd(j,V,Q){if(25<=pd)throw Error(t(301));if(j===Si)if(Ra=!0,j={action:Q,next:null},Ko===null&&(Ko=new Map),Q=Ko.get(V),Q===void 0)Ko.set(V,j);else{for(V=Q;V.next!==null;)V=V.next;V.next=j}}function $v(){throw Error(t(394))}function js(){}var Vc={readContext:function(j){return j._currentValue},useContext:function(j){return Ps(),j._currentValue},useMemo:gd,useReducer:Ji,useRef:function(j){Si=Ps(),cn=Fl();var V=cn.memoizedState;return V===null?(j={current:j},cn.memoizedState=j):V},useState:function(j){return Ji(qh,j)},useInsertionEffect:js,useLayoutEffect:function(){},useCallback:function(j,V){return gd(function(){return j},V)},useImperativeHandle:js,useEffect:js,useDebugValue:js,useDeferredValue:function(j){return Ps(),j},useTransition:function(){return Ps(),[!1,$v]},useId:function(){var j=Rl.treeContext,V=j.overflow;j=j.id,j=(j&~(1<<32-ja(j)-1)).toString(32)+V;var Q=Wc;if(Q===null)throw Error(t(404));return V=Ti++,j=":"+Q.idPrefix+"R"+j,0<V&&(j+="H"+V.toString(32)),j+":"},useMutableSource:function(j,V){return Ps(),V(j._source)},useSyncExternalStore:function(j,V,Q){if(Q===void 0)throw Error(t(407));return Q()}},Wc=null,Ar=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentDispatcher;function Hl(j){return console.error(j),null}function Ls(){}function Gc(j,V,Q,oe,xe,we,Ae,ze,gt){var Dt=[],Tt=new Set;return V={destination:null,responseState:V,progressiveChunkSize:oe===void 0?12800:oe,status:0,fatalError:null,nextSegmentId:0,allPendingTasks:0,pendingRootTasks:0,completedRootSegment:null,abortableTasks:Tt,pingedTasks:Dt,clientRenderedBoundaries:[],completedBoundaries:[],partialBoundaries:[],onError:xe===void 0?Hl:xe,onAllReady:we===void 0?Ls:we,onShellReady:Ae===void 0?Ls:Ae,onShellError:ze===void 0?Ls:ze,onFatalError:gt===void 0?Ls:gt},Q=_l(V,0,null,Q,!1,!1),Q.parentFlushed=!0,j=Kh(V,j,null,Q,Tt,Ke,null,qo),Dt.push(j),V}function Kh(j,V,Q,oe,xe,we,Ae,ze){j.allPendingTasks++,Q===null?j.pendingRootTasks++:Q.pendingTasks++;var gt={node:V,ping:function(){var Dt=j.pingedTasks;Dt.push(gt),Dt.length===1&&ep(j)},blockedBoundary:Q,blockedSegment:oe,abortSet:xe,legacyContext:we,context:Ae,treeContext:ze};return xe.add(gt),gt}function _l(j,V,Q,oe,xe,we){return{status:0,id:-1,index:V,parentFlushed:!1,chunks:[],children:[],formatContext:oe,boundary:Q,lastPushedText:xe,textEmbedded:we}}function Rs(j,V){if(j=j.onError(V),j!=null&&typeof j!="string")throw Error('onError returned something with a type other than "string". onError should return a string and may return null or undefined but must not return anything else. It received something of type "'+typeof j+'" instead');return j}function Fa(j,V){var Q=j.onShellError;Q(V),Q=j.onFatalError,Q(V),j.destination!==null?(j.status=2,d(j.destination,V)):(j.status=1,j.fatalError=V)}function Zc(j,V,Q,oe,xe){for(Si={},Rl=V,Ti=0,j=Q(oe,xe);Ra;)Ra=!1,Ti=0,pd+=1,cn=null,j=Q(oe,xe);return zc(),j}function Xh(j,V,Q,oe){var xe=Q.render(),we=oe.childContextTypes;if(we!=null){var Ae=V.legacyContext;if(typeof Q.getChildContext!="function")oe=Ae;else{Q=Q.getChildContext();for(var ze in Q)if(!(ze in we))throw Error(t(108,Ve(oe)||"Unknown",ze));oe=$o({},Ae,Q)}V.legacyContext=oe,co(j,V,xe),V.legacyContext=Ae}else co(j,V,xe)}function qv(j,V){if(j&&j.defaultProps){V=$o({},V),j=j.defaultProps;for(var Q in j)V[Q]===void 0&&(V[Q]=j[Q]);return V}return V}function Jh(j,V,Q,oe,xe){if(typeof Q=="function")if(Q.prototype&&Q.prototype.isReactComponent){xe=yt(Q,V.legacyContext);var we=Q.contextType;we=new Q(oe,typeof we=="object"&&we!==null?we._currentValue:xe),Vr(we,Q,oe,xe),Xh(j,V,we,Q)}else{we=yt(Q,V.legacyContext),xe=Zc(j,V,Q,oe,we);var Ae=Ti!==0;if(typeof xe=="object"&&xe!==null&&typeof xe.render=="function"&&xe.$$typeof===void 0)Vr(xe,Q,oe,we),Xh(j,V,xe,Q);else if(Ae){oe=V.treeContext,V.treeContext=Eo(oe,1,0);try{co(j,V,xe)}finally{V.treeContext=oe}}else co(j,V,xe)}else if(typeof Q=="string"){switch(xe=V.blockedSegment,we=Kt(xe.chunks,Q,oe,j.responseState,xe.formatContext),xe.lastPushedText=!1,Ae=xe.formatContext,xe.formatContext=q(Ae,Q,oe),Qh(j,V,we),xe.formatContext=Ae,Q){case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"input":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":break;default:xe.chunks.push(gn,l(Q),Ge)}xe.lastPushedText=!1}else{switch(Q){case Se:case ae:case Hc:case _c:case ar:co(j,V,oe.children);return;case Pa:co(j,V,oe.children);return;case te:throw Error(t(343));case Oa:e:{Q=V.blockedBoundary,xe=V.blockedSegment,we=oe.fallback,oe=oe.children,Ae=new Set;var ze={id:null,rootSegmentID:-1,parentFlushed:!1,pendingTasks:0,forceClientRender:!1,completedSegments:[],byteSize:0,fallbackAbortableTasks:Ae,errorDigest:null},gt=_l(j,xe.chunks.length,ze,xe.formatContext,!1,!1);xe.children.push(gt),xe.lastPushedText=!1;var Dt=_l(j,0,null,xe.formatContext,!1,!1);Dt.parentFlushed=!0,V.blockedBoundary=ze,V.blockedSegment=Dt;try{if(Qh(j,V,oe),Dt.lastPushedText&&Dt.textEmbedded&&Dt.chunks.push($),Dt.status=1,bd(ze,Dt),ze.pendingTasks===0)break e}catch(Tt){Dt.status=4,ze.forceClientRender=!0,ze.errorDigest=Rs(j,Tt)}finally{V.blockedBoundary=Q,V.blockedSegment=xe}V=Kh(j,we,Q,gt,Ae,V.legacyContext,V.context,V.treeContext),j.pingedTasks.push(V)}return}if(typeof Q=="object"&&Q!==null)switch(Q.$$typeof){case Os:if(oe=Zc(j,V,Q.render,oe,xe),Ti!==0){Q=V.treeContext,V.treeContext=Eo(Q,1,0);try{co(j,V,oe)}finally{V.treeContext=Q}}else co(j,V,oe);return;case P:Q=Q.type,oe=qv(Q,oe),Jh(j,V,Q,oe,xe);return;case Bc:if(xe=oe.children,Q=Q._context,oe=oe.value,we=Q._currentValue,Q._currentValue=oe,Ae=kt,kt=oe={parent:Ae,depth:Ae===null?0:Ae.depth+1,context:Q,parentValue:we,value:oe},V.context=oe,co(j,V,xe),j=kt,j===null)throw Error(t(403));oe=j.parentValue,j.context._currentValue=oe===ve?j.context._defaultValue:oe,j=kt=j.parent,V.context=j;return;case qi:oe=oe.children,oe=oe(Q._currentValue),co(j,V,oe);return;case W:xe=Q._init,Q=xe(Q._payload),oe=qv(Q,oe),Jh(j,V,Q,oe,void 0);return}throw Error(t(130,Q==null?Q:typeof Q,""))}}function co(j,V,Q){if(V.node=Q,typeof Q=="object"&&Q!==null){switch(Q.$$typeof){case lo:Jh(j,V,Q.type,Q.props,Q.ref);return;case Ns:throw Error(t(257));case W:var oe=Q._init;Q=oe(Q._payload),co(j,V,Q);return}if(B(Q)){yd(j,V,Q);return}if(Q===null||typeof Q!="object"?oe=null:(oe=De&&Q[De]||Q["@@iterator"],oe=typeof oe=="function"?oe:null),oe&&(oe=oe.call(Q))){if(Q=oe.next(),!Q.done){var xe=[];do xe.push(Q.value),Q=oe.next();while(!Q.done);yd(j,V,xe)}return}throw j=Object.prototype.toString.call(Q),Error(t(31,j==="[object Object]"?"object with keys {"+Object.keys(Q).join(", ")+"}":j))}typeof Q=="string"?(oe=V.blockedSegment,oe.lastPushedText=re(V.blockedSegment.chunks,Q,j.responseState,oe.lastPushedText)):typeof Q=="number"&&(oe=V.blockedSegment,oe.lastPushedText=re(V.blockedSegment.chunks,""+Q,j.responseState,oe.lastPushedText))}function yd(j,V,Q){for(var oe=Q.length,xe=0;xe<oe;xe++){var we=V.treeContext;V.treeContext=Eo(we,oe,xe);try{Qh(j,V,Q[xe])}finally{V.treeContext=we}}}function Qh(j,V,Q){var oe=V.blockedSegment.formatContext,xe=V.legacyContext,we=V.context;try{return co(j,V,Q)}catch(gt){if(zc(),typeof gt=="object"&>!==null&&typeof gt.then=="function"){Q=gt;var Ae=V.blockedSegment,ze=_l(j,Ae.chunks.length,null,Ae.formatContext,Ae.lastPushedText,!0);Ae.children.push(ze),Ae.lastPushedText=!1,j=Kh(j,V.node,V.blockedBoundary,ze,V.abortSet,V.legacyContext,V.context,V.treeContext).ping,Q.then(j,j),V.blockedSegment.formatContext=oe,V.legacyContext=xe,V.context=we,Io(we)}else throw V.blockedSegment.formatContext=oe,V.legacyContext=xe,V.context=we,Io(we),gt}}function c1(j){var V=j.blockedBoundary;j=j.blockedSegment,j.status=3,Xv(this,V,j)}function Kv(j,V,Q){var oe=j.blockedBoundary;j.blockedSegment.status=3,oe===null?(V.allPendingTasks--,V.status!==2&&(V.status=2,V.destination!==null&&V.destination.close())):(oe.pendingTasks--,oe.forceClientRender||(oe.forceClientRender=!0,j=Q===void 0?Error(t(432)):Q,oe.errorDigest=V.onError(j),oe.parentFlushed&&V.clientRenderedBoundaries.push(oe)),oe.fallbackAbortableTasks.forEach(function(xe){return Kv(xe,V,Q)}),oe.fallbackAbortableTasks.clear(),V.allPendingTasks--,V.allPendingTasks===0&&(oe=V.onAllReady,oe()))}function bd(j,V){if(V.chunks.length===0&&V.children.length===1&&V.children[0].boundary===null){var Q=V.children[0];Q.id=V.id,Q.parentFlushed=!0,Q.status===1&&bd(j,Q)}else j.completedSegments.push(V)}function Xv(j,V,Q){if(V===null){if(Q.parentFlushed){if(j.completedRootSegment!==null)throw Error(t(389));j.completedRootSegment=Q}j.pendingRootTasks--,j.pendingRootTasks===0&&(j.onShellError=Ls,V=j.onShellReady,V())}else V.pendingTasks--,V.forceClientRender||(V.pendingTasks===0?(Q.parentFlushed&&Q.status===1&&bd(V,Q),V.parentFlushed&&j.completedBoundaries.push(V),V.fallbackAbortableTasks.forEach(c1,j),V.fallbackAbortableTasks.clear()):Q.parentFlushed&&Q.status===1&&(bd(V,Q),V.completedSegments.length===1&&V.parentFlushed&&j.partialBoundaries.push(V)));j.allPendingTasks--,j.allPendingTasks===0&&(j=j.onAllReady,j())}function ep(j){if(j.status!==2){var V=kt,Q=Ar.current;Ar.current=Vc;var oe=Wc;Wc=j.responseState;try{var xe=j.pingedTasks,we;for(we=0;we<xe.length;we++){var Ae=xe[we],ze=j,gt=Ae.blockedSegment;if(gt.status===0){Io(Ae.context);try{co(ze,Ae,Ae.node),gt.lastPushedText&>.textEmbedded&>.chunks.push($),Ae.abortSet.delete(Ae),gt.status=1,Xv(ze,Ae.blockedBoundary,gt)}catch(Mo){if(zc(),typeof Mo=="object"&&Mo!==null&&typeof Mo.then=="function"){var Dt=Ae.ping;Mo.then(Dt,Dt)}else{Ae.abortSet.delete(Ae),gt.status=4;var Tt=Ae.blockedBoundary,hn=Mo,Wr=Rs(ze,hn);if(Tt===null?Fa(ze,hn):(Tt.pendingTasks--,Tt.forceClientRender||(Tt.forceClientRender=!0,Tt.errorDigest=Wr,Tt.parentFlushed&&ze.clientRenderedBoundaries.push(Tt))),ze.allPendingTasks--,ze.allPendingTasks===0){var Co=ze.onAllReady;Co()}}}}}xe.splice(0,we),j.destination!==null&&tp(j,j.destination)}catch(Mo){Rs(j,Mo),Fa(j,Mo)}finally{Wc=oe,Ar.current=Q,Q===Vc&&Io(V)}}}function wd(j,V,Q){switch(Q.parentFlushed=!0,Q.status){case 0:var oe=Q.id=j.nextSegmentId++;return Q.lastPushedText=!1,Q.textEmbedded=!1,j=j.responseState,o(V,ut),o(V,j.placeholderPrefix),j=l(oe.toString(16)),o(V,j),i(V,mt);case 1:Q.status=2;var xe=!0;oe=Q.chunks;var we=0;Q=Q.children;for(var Ae=0;Ae<Q.length;Ae++){for(xe=Q[Ae];we<xe.index;we++)o(V,oe[we]);xe=Sd(j,V,xe)}for(;we<oe.length-1;we++)o(V,oe[we]);return we<oe.length&&(xe=i(V,oe[we])),xe;default:throw Error(t(390))}}function Sd(j,V,Q){var oe=Q.boundary;if(oe===null)return wd(j,V,Q);if(oe.parentFlushed=!0,oe.forceClientRender)oe=oe.errorDigest,i(V,$n),o(V,Tn),oe&&(o(V,er),o(V,l(O(oe))),o(V,Pn)),i(V,ir),wd(j,V,Q);else if(0<oe.pendingTasks){oe.rootSegmentID=j.nextSegmentId++,0<oe.completedSegments.length&&j.partialBoundaries.push(oe);var xe=j.responseState,we=xe.nextSuspenseID++;xe=u(xe.boundaryPrefix+we.toString(16)),oe=oe.id=xe,Gt(V,j.responseState,oe),wd(j,V,Q)}else if(oe.byteSize>j.progressiveChunkSize)oe.rootSegmentID=j.nextSegmentId++,j.completedBoundaries.push(oe),Gt(V,j.responseState,oe.id),wd(j,V,Q);else{if(i(V,It),Q=oe.completedSegments,Q.length!==1)throw Error(t(391));Sd(j,V,Q[0])}return i(V,io)}function Jv(j,V,Q){return Zi(V,j.responseState,Q.formatContext,Q.id),Sd(j,V,Q),Da(V,Q.formatContext)}function Qv(j,V,Q){for(var oe=Q.completedSegments,xe=0;xe<oe.length;xe++)Td(j,V,Q,oe[xe]);if(oe.length=0,j=j.responseState,oe=Q.id,Q=Q.rootSegmentID,o(V,j.startInlineScript),j.sentCompleteBoundaryFunction?o(V,Fc):(j.sentCompleteBoundaryFunction=!0,o(V,As)),oe===null)throw Error(t(395));return Q=l(Q.toString(16)),o(V,oe),o(V,dd),o(V,j.segmentPrefix),o(V,Q),i(V,fd)}function Td(j,V,Q,oe){if(oe.status===2)return!0;var xe=oe.id;if(xe===-1){if((oe.id=Q.rootSegmentID)===-1)throw Error(t(392));return Jv(j,V,oe)}return Jv(j,V,oe),j=j.responseState,o(V,j.startInlineScript),j.sentCompleteSegmentFunction?o(V,Rc):(j.sentCompleteSegmentFunction=!0,o(V,ud)),o(V,j.segmentPrefix),xe=l(xe.toString(16)),o(V,xe),o(V,Ds),o(V,j.placeholderPrefix),o(V,xe),i(V,Aa)}function tp(j,V){n=new Uint8Array(512),r=0;try{var Q=j.completedRootSegment;if(Q!==null&&j.pendingRootTasks===0){Sd(j,V,Q),j.completedRootSegment=null;var oe=j.responseState.bootstrapChunks;for(Q=0;Q<oe.length-1;Q++)o(V,oe[Q]);Q<oe.length&&i(V,oe[Q])}var xe=j.clientRenderedBoundaries,we;for(we=0;we<xe.length;we++){var Ae=xe[we];oe=V;var ze=j.responseState,gt=Ae.id,Dt=Ae.errorDigest,Tt=Ae.errorMessage,hn=Ae.errorComponentStack;if(o(oe,ze.startInlineScript),ze.sentClientRenderFunction?o(oe,Dr):(ze.sentClientRenderFunction=!0,o(oe,fn)),gt===null)throw Error(t(395));o(oe,gt),o(oe,jl),(Dt||Tt||hn)&&(o(oe,Na),o(oe,l($i(Dt||"")))),(Tt||hn)&&(o(oe,Na),o(oe,l($i(Tt||"")))),hn&&(o(oe,Na),o(oe,l($i(hn)))),i(oe,Ll)}xe.splice(0,we);var Wr=j.completedBoundaries;for(we=0;we<Wr.length;we++)Qv(j,V,Wr[we]);Wr.splice(0,we),a(V),n=new Uint8Array(512),r=0;var Co=j.partialBoundaries;for(we=0;we<Co.length;we++){var Mo=Co[we];e:{xe=j,Ae=V;var $c=Mo.completedSegments;for(ze=0;ze<$c.length;ze++)if(!Td(xe,Ae,Mo,$c[ze])){ze++,$c.splice(0,ze);var np=!1;break e}$c.splice(0,ze),np=!0}if(!np){j.destination=null,we++,Co.splice(0,we);return}}Co.splice(0,we);var Ha=j.completedBoundaries;for(we=0;we<Ha.length;we++)Qv(j,V,Ha[we]);Ha.splice(0,we)}finally{a(V),j.allPendingTasks===0&&j.pingedTasks.length===0&&j.clientRenderedBoundaries.length===0&&j.completedBoundaries.length===0&&V.close()}}function ey(j,V){try{var Q=j.abortableTasks;Q.forEach(function(oe){return Kv(oe,j,V)}),Q.clear(),j.destination!==null&&tp(j,j.destination)}catch(oe){Rs(j,oe),Fa(j,oe)}}return Sb.renderToReadableStream=function(j,V){return new Promise(function(Q,oe){var xe,we,Ae=new Promise(function(Tt,hn){we=Tt,xe=hn}),ze=Gc(j,J(V?V.identifierPrefix:void 0,V?V.nonce:void 0,V?V.bootstrapScriptContent:void 0,V?V.bootstrapScripts:void 0,V?V.bootstrapModules:void 0),Z(V?V.namespaceURI:void 0),V?V.progressiveChunkSize:void 0,V?V.onError:void 0,we,function(){var Tt=new ReadableStream({type:"bytes",pull:function(hn){if(ze.status===1)ze.status=2,d(hn,ze.fatalError);else if(ze.status!==2&&ze.destination===null){ze.destination=hn;try{tp(ze,hn)}catch(Wr){Rs(ze,Wr),Fa(ze,Wr)}}},cancel:function(){ey(ze)}},{highWaterMark:0});Tt.allReady=Ae,Q(Tt)},function(Tt){Ae.catch(function(){}),oe(Tt)},xe);if(V&&V.signal){var gt=V.signal,Dt=function(){ey(ze,gt.reason),gt.removeEventListener("abort",Dt)};gt.addEventListener("abort",Dt)}ep(ze)})},Sb.version="18.2.0",Sb}var zh,Rz;zh=aFe();Rz=sFe();zh.version;zh.renderToString;var lFe=zh.renderToStaticMarkup;zh.renderToNodeStream;zh.renderToStaticNodeStream;Rz.renderToReadableStream;const Fz=pe.oneOf(["top","right","bottom","left","bottom-left-aligned","bottom-middle-aligned","bottom-right-aligned","top-left-aligned","top-middle-aligned","top-right-aligned","auto"]),Hz=pe.oneOf(["top-middle","top-left","top-right","bottom-left","bottom-right","bottom-middle","middle-left","middle-right","middle-middle"]),_z=pe.shape({nextLabel:pe.string,prevLabel:pe.string,skipLabel:pe.string,doneLabel:pe.string,hidePrev:pe.bool,hideNext:pe.bool,tooltipPosition:Fz,tooltipClass:pe.string,highlightClass:pe.string,exitOnEsc:pe.bool,exitOnOverlayClick:pe.bool,showStepNumbers:pe.bool,keyboardNavigation:pe.bool,showButtons:pe.bool,showBullets:pe.bool,showProgress:pe.bool,scrollToElement:pe.bool,overlayOpacity:pe.number,scrollPadding:pe.number,positionPrecedence:pe.arrayOf(pe.string),disableInteraction:pe.bool,hintPosition:Hz,hintButtonLabel:pe.string,hintAnimation:pe.bool}),Bz={hidePrev:!0,hideNext:!0};function Yz(){return typeof window>"u"}class cFe extends D.Component{static propTypes={enabled:pe.bool,initialStep:pe.number.isRequired,steps:pe.arrayOf(pe.shape({element:pe.oneOfType([pe.string,typeof Element>"u"?pe.any:pe.instanceOf(Element)]),intro:pe.node.isRequired,position:Fz,tooltipClass:pe.string,highlightClass:pe.string})).isRequired,onStart:pe.func,onExit:pe.func.isRequired,onBeforeExit:pe.func,onBeforeChange:pe.func,onAfterChange:pe.func,onChange:pe.func,onPreventChange:pe.func,onComplete:pe.func,options:_z};static defaultProps={enabled:!1,onStart:null,onBeforeExit:null,onBeforeChange:null,onAfterChange:null,onChange:null,onPreventChange:null,onComplete:null,options:Bz};constructor(t){super(t),this.introJs=null,this.isConfigured=!1,this.isVisible=!1,this.installIntroJs()}componentDidMount(){this.props.enabled&&(this.configureIntroJs(),this.renderSteps())}componentDidUpdate(t){const{enabled:n,steps:r,options:o}=this.props;(!this.isConfigured||t.steps!==r||t.options!==o)&&(this.configureIntroJs(),this.renderSteps()),t.enabled!==n&&this.renderSteps()}componentWillUnmount(){this.introJs.exit()}onExit=()=>{const{onExit:t}=this.props;this.isVisible=!1,t(this.introJs._currentStep)};onBeforeExit=()=>{const{onBeforeExit:t}=this.props;return t?t(this.introJs._currentStep):!0};onBeforeChange=t=>{if(!this.isVisible)return!0;const{onBeforeChange:n,onPreventChange:r}=this.props;if(n){const o=n(this.introJs._currentStep,t);return o===!1&&r&&setTimeout(()=>{r(this.introJs._currentStep)},0),o}return!0};onAfterChange=t=>{if(!this.isVisible)return;const{onAfterChange:n}=this.props;n&&n(this.introJs._currentStep,t)};onChange=t=>{if(!this.isVisible)return;const{onChange:n}=this.props;n&&n(this.introJs._currentStep,t)};onComplete=()=>{const{onComplete:t}=this.props;t&&t()};updateStepElement=t=>{const n=document.querySelector(this.introJs._options.steps[t].element);n&&(this.introJs._introItems[t].element=n,this.introJs._introItems[t].position=this.introJs._options.steps[t].position||"auto")};installIntroJs(){Yz()||(this.introJs=lw(),this.introJs.onexit(this.onExit),this.introJs.onbeforeexit(this.onBeforeExit),this.introJs.onbeforechange(this.onBeforeChange),this.introJs.onafterchange(this.onAfterChange),this.introJs.onchange(this.onChange),this.introJs.oncomplete(this.onComplete))}configureIntroJs(){const{options:t,steps:n}=this.props,r=n.map(o=>D.isValidElement(o.intro)?{...o,intro:lFe(o.intro)}:o);this.introJs.setOptions({...t,steps:r}),this.isConfigured=!0}renderSteps(){const{enabled:t,initialStep:n,steps:r,onStart:o}=this.props;t&&r.length>0&&!this.isVisible?(this.introJs.start(),this.isVisible=!0,this.introJs.goToStepNumber(n+1),o&&o(this.introJs._currentStep)):!t&&this.isVisible&&(this.isVisible=!1,this.introJs.exit())}render(){return null}}class xet extends D.Component{static propTypes={enabled:pe.bool,hints:pe.arrayOf(pe.shape({element:pe.string.isRequired,hint:pe.string.isRequired,hintPosition:Hz})).isRequired,onClick:pe.func,onClose:pe.func,options:_z};static defaultProps={enabled:!1,onClick:null,onClose:null,options:Bz};constructor(t){super(t),this.introJs=null,this.isConfigured=!1,this.installIntroJs()}componentDidMount(){this.props.enabled&&(this.configureIntroJs(),this.renderHints())}componentDidUpdate(t){const{enabled:n,hints:r,options:o}=this.props;(!this.isConfigured||t.hints!==r||t.options!==o)&&(this.configureIntroJs(),this.renderHints()),t.enabled!==n&&this.renderHints()}componentWillUnmount(){this.introJs.hideHints()}installIntroJs(){if(Yz())return;this.introJs=lw();const{onClick:t,onClose:n}=this.props;t&&this.introJs.onhintclick(t),n&&this.introJs.onhintclose(n)}configureIntroJs(){const{options:t,hints:n}=this.props;this.introJs.removeHints(),this.introJs.setOptions({...t,hints:n}),this.isConfigured=!0}renderHints(){const{enabled:t,hints:n}=this.props;t&&n.length>0?this.introJs.showHints():t||this.introJs.hideHints()}render(){return null}}const uFe=[{element:".left-sidebar",intro:E("This is Thino's sidebar. Navigate to different path or select query filter.")},{element:".user-banner-container",intro:E("Click here and go to settings page.")},{element:".path-entry-wrapper",intro:E("Click here and go to different path.")},{element:".queries-wrapper",intro:E("Select or create query filter here.")},{element:".status-text-container.sidebar",intro:E("See the status of Thinos here.")+E("It is not available on small view")},{element:".heatmap-default",intro:E("See your time status of thinos here.")},{element:".tags-wrapper",intro:E("See your tags here. Tags will be shown when thino contains tags.")},{element:".section-header-container.memos-header-container",intro:E("Search your thino quickly here.")},{element:".memo-editor-wrapper",intro:E("Edit or create your thino here.")},{element:".memolist-wrapper",intro:E("See your thinos here.")}],dFe=[{element:".memos-sidebar-wrapper.left-sidebar",intro:E("This is Thino's sidebar. Navigate to different path or select query filter.")},{element:".user-banner-container",intro:E("Click here and go to settings page.")},{element:".heatmap-default",intro:E("See your time status of thinos here.")},{element:".path-entry-wrapper",intro:E("Click here and go to different path.")},{element:".queries-wrapper",intro:E("Select or create query filter here.")},{element:".tags-wrapper",intro:E("See your tags here. Tags will be shown when thino contains tags.")},{element:".section-header-container.memos-header-container",intro:E("Search your thino quickly here.")},{element:".memo-editor-wrapper",intro:E("Edit or create your thino here.")},{element:".memolist-wrapper",intro:E("See your thinos here.")}],fFe={nextLabel:E("Next"),prevLabel:E("Previous"),doneLabel:E("Done"),hideNext:!1},hFe=(e,t)=>{D.useEffect(()=>{if(!e.needVerify){Ze.setLocked(!1);return}Ze.setLocked(!0)},[e?.needVerify]),D.useEffect(()=>{(async()=>{const r=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device?.getId(),o=N.Platform.isDesktop?await Sn():r?.identifier||r?.uuid;!t||t?.appId!==o?document.body.toggleClass("hide-pro",!0):document.body.toggleClass("hide-pro",!1)})()},[t])},pFe=({settings:e,exited:t,isMobileView:n})=>{const r=D.useRef(null),o=()=>{Ze.setExitSteps(!1)},i=a=>{n&&(e?.DefaultThemeForThino==="classic"&&a===6||e?.DefaultThemeForThino==="modern"&&a===7)&&Ze.setShowSiderbarInMobileView(!1)};return w.jsx(cFe,{ref:r,enabled:t,steps:e?.DefaultThemeForThino==="modern"?uFe:dFe,initialStep:0,onExit:o,options:fFe,onBeforeChange:i})},mFe=({settings:e,pathname:t,isMobileView:n,memoListView:r,sectionRef:o})=>{const i=e?.DefaultThemeForThino==="modern",a=`memos-${t==="/"?r:"list"}-view`,s=!i||n?"classic":"modern";return w.jsxs("section",{ref:o,id:"page-wrapper","data-path":t,className:tn(a,s),children:[w.jsx(g5,{sidebarPosition:"left",className:"left-sidebar"}),w.jsx("main",{className:"content-wrapper",children:dJe(t)}),i&&!n&&w.jsx(g5,{sidebarPosition:"right",className:"right-sidebar"})]})};function gFe(){const{dailyNotesState:{settings:e,verifyState:t},locationState:{pathname:n},globalState:{isMobileView:r,memoListView:o,globalEditorShown:i,locked:a,exited:s}}=D.useContext(ct),l=D.useRef(null),u=e?.FirstLoaded||app.plugins.getPlugin("obsidian-memos").settings?.FirstLoaded;return hFe(e,t),u?w.jsx(X9e,{}):w.jsxs(w.Fragment,{children:[w.jsx(pFe,{settings:e,exited:s,isMobileView:r}),a&&w.jsx(K9e,{}),!a&&i&&w.jsx(Du,{editorType:"block"}),!a&&!i&&w.jsx(mFe,{settings:e,pathname:n,isMobileView:r,memoListView:o,sectionRef:l})]})}const vFe={"*":w.jsx(gFe,{})},yFe=e=>{const{memo:t,handleDeletedMemoAction:n}=e,{dailyNotesState:r}=D.useContext(ct),o={...t,createdAtStr:Le.getDateTimeString(t.createdAt),deletedAtStr:Le.getDateTimeString(t.deletedAt||t.createdAt)},i=Y.useRef(null),a=Y.useRef(null),[s,l]=Y.useState(""),u=D.useRef(null);D.useEffect(()=>{!a||!u.current||N.setIcon(u.current,"more-horizontal")},[a]),D.useEffect(()=>{if(!i.current||!a.current||i.current.hasChildNodes()&&t.content===s||!r.view)return;const b=r.view;l(t.content),i.current.hasChildNodes()&&i.current.empty();async function v(){await N.MarkdownRenderer.render(r.app,t.content+`
|
|
|
`,i.current,t.path,b),i.current?.querySelectorAll(".internal-link")?.forEach(S=>{const x=S,C=x.getAttribute("data-href");if(!C)return;r.app.metadataCache.getFirstLinkpathDest(C,t.path)||S.classList.add("is-unresolved"),x.addEventListener("mouseover",M=>{M.stopPropagation(),r.app.workspace.trigger("hover-link",{event:M,source:"thino",hoverParent:b.containerEl,targetEl:x,linktext:C,sourcePath:x.href})})})}v()},[t.content,a]);const d=async()=>{try{await de.deleteMemoById(o.id),n(o.id)}catch(b){new N.Notice(b.message)}},h=async()=>{switch(o.sourceType){case"DAILY":await JM(o.id,o.path);break;case"CANVAS":await eD(o.id,o.path);break;case"MULTI":await XM(o.path);break;case"FILE":await QM(o.id,o.path);break}},p=async()=>{try{const b=await de.restoreMemoById(o.id),y=r.app?.loadLocalStorage("tokenForSync");b&&b.webId&&y&&r.settings.startSync&&await Lm(b.webId),b&&de.editMemo(b),n(o.id),new N.Notice(E("RESTORE SUCCEED"))}catch(b){new N.Notice(b.message)}},m=b=>{b.stopPropagation();const v=new N.Menu;v.addItem(y=>{y.setTitle(E("RESTORE")).setIcon("archive-restore").onClick(p)}),v.addItem(y=>{y.setTitle(E("SOURCE")).setIcon("home").onClick(h)}),v.addItem(y=>{y.setTitle(E("DELETE")).setIcon("trash").setWarning(!0).onClick(()=>{const S=new N.Menu;S.addItem(x=>{x.setTitle(E("CONFIRM!")).setIcon("trash").setWarning(!0).onClick(d)}),S.addItem(x=>{x.setTitle(E("Cancel")).setIcon("x").onClick(()=>{})}),S.showAtMouseEvent(b.nativeEvent)})}),v.showAtMouseEvent(b.nativeEvent)};return w.jsxs("div",{ref:a,className:`memo-wrapper ${"memos-"+o.id}`,children:[w.jsxs("div",{className:"memo-top-wrapper",children:[w.jsxs("span",{className:"time-text",children:[E("DELETE AT")," ",o.deletedAtStr]}),w.jsx("div",{className:"btns-container",children:w.jsx("span",{ref:u,className:"btn more-action-btn",onClick:m})})]}),w.jsx("div",{ref:i,className:"memo-content-text",onContextMenu:b=>{b.preventDefault(),b.stopPropagation()}})]})},AA=({isLoading:e,isEmpty:t,emptyMessage:n=E("Here is No Memos.")})=>e?w.jsx("div",{className:"tip-text-container",children:w.jsx("span",{className:"tip-text",children:E("Fetching data...")})}):t?w.jsx("div",{className:"tip-text-container",children:w.jsx("span",{className:"tip-text",children:n})}):null,bFe=()=>{const{locationState:{query:e},globalState:{isMobileView:t},memoState:{memos:n},dailyNotesState:{app:r,plugin:o}}=D.useContext(ct),i=Dc(),[a,s]=D.useState([]),l=Y.useRef(null),u=Y.useRef(null);D.useEffect(()=>{u.current&&N.setIcon(u.current,"more-horizontal")},[u]),D.useEffect(()=>{hc({memos:n,query:e,filterOptions:{filterDoneTasks:!1,onlyFilterType:"deleted"},plugin:o}).then(v=>{s(v)}),i.setFinish()},[n,l.current,e]);const d=D.useCallback(v=>{s(y=>y.filter(S=>S.id!==v))},[]),h=async()=>{if(!(a?.length>0))return;if(!await rs()){Nt();return}const v=[...a],y=$e.getState().settings.startSync,S=r?.loadLocalStorage("tokenForSync");try{const x=v.filter(M=>M.sourceType==="DAILY"),C=v.filter(M=>M.sourceType!=="DAILY");for(const M of C){const I=await de.restoreMemoById(M.id);I&&I.webId&&S&&y&&await Lm(I.webId),I&&de.editMemo(I)}const k=Js(x);for(const{path:M,thinos:I}of k){const O=await de.dealWithDailyThinoBulk(M,I,"restoreFromDelete");for(const R of O)R&&R.webId&&S&&y&&await Lm(R.webId)}Ue.clearQuery(),new N.Notice(E("RESTORE SUCCEED"))}catch(x){new N.Notice(x.message)}},p=async()=>{if(!(a?.length>0))return;if(!await rs()){Nt();return}const v=[...a],y=$e.getState().settings,S=r?.loadLocalStorage("tokenForSync");try{const x=v.filter(M=>M.sourceType==="DAILY"),C=v.filter(M=>M.sourceType!=="DAILY");for(const M of C)await de.deleteMemoById(M.id);const k=Js(x);for(const{path:M,thinos:I}of k){const O=await de.dealWithDailyThinoBulk(M,I,"deleteForever");if(!(!S||!y.startSync))for(const R of O)R&&R.webId&&await KM(R.webId)}Ue.clearQuery(),new N.Notice(E("DELETE SUCCEED"))}catch(x){console.error("error",x),new N.Notice(x.message)}},m=v=>{const y=new N.Menu;y.addItem(S=>{S.setTitle(E("Bulk restore")).setIcon("archive-restore").onClick(async()=>{new da(r,E("RESTORE"),async x=>{x==="confirm"&&await h()}).open()})}).addItem(S=>{S.setTitle(E("Bulk delete")).setIcon("trash").onClick(async()=>{new da(r,E("DELETE"),async x=>{x==="confirm"&&await p()}).open()})}),y.showAtMouseEvent(v.nativeEvent)},b=w.jsx(w.Fragment,{children:w.jsx("div",{className:"header-right-section",children:w.jsx(nv,{})})});return w.jsxs("div",{className:"memo-trash-wrapper",ref:l,children:[w.jsx(Yh,{showSidebar:t,rightContent:b,children:w.jsx("span",{ref:u,className:"menu-popup-btn",onClick:m})}),w.jsx(Fv,{thinosCount:a.length,thinos:a}),w.jsx(AA,{isLoading:i.isLoading,isEmpty:a.length===0}),!i.isLoading&&a.length>0&&w.jsx("div",{className:"deleted-memos-container",children:a.map(v=>w.jsx(yFe,{memo:v,handleDeletedMemoAction:d},`${v.id}-${v.updatedAt}`))})]})},wFe=()=>{const{globalState:e}=D.useContext(ct),{useTinyUndoHistoryCache:t,shouldHideImageUrl:n,shouldSplitMemoWord:r,shouldUseMarkdownParser:o}=e,i=`👋 你好呀~欢迎使用memos!
|
|
|
* ✨ **开源项目**;
|
|
|
* 😋 精美且细节的视觉样式;
|
|
|
* 📑 体验优良的交互逻辑;`,a=()=>{Ze.setAppSetting({useTinyUndoHistoryCache:!t})},s=()=>{Ze.setAppSetting({shouldSplitMemoWord:!r})},l=()=>{Ze.setAppSetting({shouldHideImageUrl:!n})},u=()=>{Ze.setAppSetting({shouldUseMarkdownParser:!o})},d=async()=>{const h=de.getState().memos.map(b=>({...b})),p=JSON.stringify(h),m=document.createElement("a");m.setAttribute("href","data:text/plain;charset=utf-8,"+encodeURIComponent(p)),m.setAttribute("download","data.json"),m.style.display="none",document.body.appendChild(m),m.click(),document.body.removeChild(m)};return w.jsxs(w.Fragment,{children:[w.jsxs("div",{className:"section-container preferences-section-container",children:[w.jsx("p",{className:"title-text",children:"Memo 显示相关"}),w.jsx("div",{className:"demo-content-container memo-content-text",dangerouslySetInnerHTML:{__html:jm(i)}}),w.jsx("label",{className:"form-label checkbox-form-label",onClick:s,children:w.jsx("span",{className:"normal-text",children:"中英文内容自动间隔"})}),w.jsx("label",{className:"form-label checkbox-form-label",onClick:u,children:w.jsx("span",{className:"normal-text",children:"部分 markdown 格式解析"})}),w.jsx("label",{className:"form-label checkbox-form-label",onClick:l,children:w.jsx("span",{className:"normal-text",children:"隐藏图片链接地址"})})]}),w.jsxs("div",{className:"section-container preferences-section-container",children:[w.jsx("p",{className:"title-text",children:"编辑器"}),w.jsxs("label",{className:"form-label checkbox-form-label",onClick:a,children:[w.jsxs("span",{className:"normal-text",children:["启用"," ",w.jsx("a",{target:"_blank",href:"https://github.com/boojack/tiny-undo",onClick:h=>h.stopPropagation(),rel:"noreferrer",children:"tiny-undo"})]}),w.jsx("img",{className:"icon-img",src:t?checkboxActive:checkbox})]})]}),w.jsxs("div",{className:"section-container thino-hidden",children:[w.jsx("p",{className:"title-text",children:"其他"}),w.jsx("div",{className:"btn-container",children:w.jsx("button",{className:"btn export-btn",onClick:d,children:"导出数据(JSON)"})})]})]})},SFe=()=>{const{globalState:{isMobileView:e}}=D.useContext(ct);D.useEffect(()=>{de.fetchAllMemos()},[]);const t=D.useCallback(()=>{Ze.setShowSiderbarInMobileView(!0)},[]);return w.jsxs("div",{className:"preference-wrapper",children:[w.jsx("div",{className:"section-header-container",children:w.jsxs("div",{className:"title-text",children:[w.jsx(il,{when:e,children:w.jsx("button",{className:"action-btn",onClick:t})}),w.jsx("span",{className:"normal-text",children:"账号与设置"})]})}),w.jsx("div",{className:"sections-wrapper",children:w.jsx(wFe,{})})]})},TFe=()=>{const{dailyNotesState:{app:e,plugin:t,settings:n},locationState:{query:r},globalState:{isMobileView:o,changedByMemos:i},memoState:{memos:a}}=D.useContext(ct),s=Dc(),[l,u]=D.useState([]),[d,h]=D.useState([]),p=Y.useRef(null),m=Y.useRef(null),[b,v]=D.useState(!1),[y,S]=D.useState([]),x=Y.useRef([]);D.useEffect(()=>{m.current&&(N.setIcon(m.current,"refresh-cw"),e.workspace.on("refresh-review-memos",C))},[m]),D.useEffect(()=>{if(!b)return;if(r){hc({memos:a,query:r,filterOptions:{filterDoneTasks:!1,filterArchived:!n.ViewArchiveInRandomReview},plugin:t}).then(M=>{const I=[...M].sort(()=>Math.random()-Math.random()).slice(0,10);u(I),v(!1)});return}const k=[...y].sort(()=>Math.random()-Math.random()).slice(0,10);u(k),v(!1)},[b,n.ViewArchiveInRandomReview]),D.useEffect(()=>{if(!(y.length>0))return;const k=[...y].sort(()=>Math.random()-Math.random()).slice(0,10);u(k),v(!1)},[y]),D.useEffect(()=>{p.current&&(hc({memos:a,query:r,filterOptions:{filterDoneTasks:!1,filterArchived:!n.ViewArchiveInRandomReview},plugin:t}).then(k=>{S(k.filter(M=>M.rowStatus!=="ARCHIVED"&&!(M.deletedAt!==""&&M.deletedAt)))}),s.setFinish(),Ue.clearQuery())},[a,p.current,n.ViewArchiveInRandomReview]),D.useEffect(()=>{if(i&&x.current.length>0){const k=y.filter(I=>x.current.includes(I.id)),M=x.current.map(I=>k.find(O=>O.id===I)).filter(I=>I!==void 0);h(M);return}x.current=l.map(k=>k.id),h(l)},[l]),D.useEffect(()=>{l.length!==0&&hc({memos:l,query:r,filterOptions:{filterDoneTasks:!1,filterArchived:!1},plugin:t}).then(k=>{h(k)})},[r]);const C=()=>{v(!0)};return w.jsxs("div",{className:"memo-review-wrapper",ref:p,children:[w.jsx(Yh,{showSidebar:o,children:w.jsx("span",{ref:m,onClick:C,className:"refresh-icon"})}),w.jsx(Fv,{}),w.jsx(AA,{isLoading:s.isLoading,isEmpty:a.length===0}),!s.isLoading&&a.length>0&&w.jsx("div",{className:"review-memos-container",children:d.map(k=>w.jsx(vo,{memo:k},`${k?.id}-${k.createdAt}`))})]})};function Uz(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=Uz(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function $t(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=Uz(e))&&(r&&(r+=" "),r+=t);return r}function xFe(e){return e==null}var IFe=xFe;const Ht=tt(IFe);var kFe=kl,EFe=Hr,CFe=xa,MFe="[object String]";function DFe(e){return typeof e=="string"||!EFe(e)&&CFe(e)&&kFe(e)==MFe}var AFe=DFe;const Hv=tt(AFe);var zz={exports:{}},en={},k5;function NFe(){if(k5)return en;k5=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),a=Symbol.for("react.context"),s=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),h=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),m=Symbol.for("react.offscreen"),b;b=Symbol.for("react.module.reference");function v(y){if(typeof y=="object"&&y!==null){var S=y.$$typeof;switch(S){case e:switch(y=y.type,y){case n:case o:case r:case u:case d:return y;default:switch(y=y&&y.$$typeof,y){case s:case a:case l:case p:case h:case i:return y;default:return S}}case t:return S}}}return en.ContextConsumer=a,en.ContextProvider=i,en.Element=e,en.ForwardRef=l,en.Fragment=n,en.Lazy=p,en.Memo=h,en.Portal=t,en.Profiler=o,en.StrictMode=r,en.Suspense=u,en.SuspenseList=d,en.isAsyncMode=function(){return!1},en.isConcurrentMode=function(){return!1},en.isContextConsumer=function(y){return v(y)===a},en.isContextProvider=function(y){return v(y)===i},en.isElement=function(y){return typeof y=="object"&&y!==null&&y.$$typeof===e},en.isForwardRef=function(y){return v(y)===l},en.isFragment=function(y){return v(y)===n},en.isLazy=function(y){return v(y)===p},en.isMemo=function(y){return v(y)===h},en.isPortal=function(y){return v(y)===t},en.isProfiler=function(y){return v(y)===o},en.isStrictMode=function(y){return v(y)===r},en.isSuspense=function(y){return v(y)===u},en.isSuspenseList=function(y){return v(y)===d},en.isValidElementType=function(y){return typeof y=="string"||typeof y=="function"||y===n||y===o||y===r||y===u||y===d||y===m||typeof y=="object"&&y!==null&&(y.$$typeof===p||y.$$typeof===h||y.$$typeof===i||y.$$typeof===a||y.$$typeof===l||y.$$typeof===b||y.getModuleId!==void 0)},en.typeOf=v,en}zz.exports=NFe();var OFe=zz.exports,PFe=kl,jFe=xa,LFe="[object Number]";function RFe(e){return typeof e=="number"||jFe(e)&&PFe(e)==LFe}var Vz=RFe;const FFe=tt(Vz);var HFe=Vz;function _Fe(e){return HFe(e)&&e!=+e}var BFe=_Fe;const _v=tt(BFe);var ga=function(t){return t===0?0:t>0?1:-1},xu=function(t){return Hv(t)&&t.indexOf("%")===t.length-1},Je=function(t){return FFe(t)&&!_v(t)},dr=function(t){return Je(t)||Hv(t)},YFe=0,Bv=function(t){var n=++YFe;return"".concat(t||"").concat(n)},Zu=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(!Je(t)&&!Hv(t))return r;var i;if(xu(t)){var a=t.indexOf("%");i=n*parseFloat(t.slice(0,a))/100}else i=+t;return _v(i)&&(i=r),o&&i>n&&(i=n),i},cc=function(t){if(!t)return null;var n=Object.keys(t);return n&&n.length?t[n[0]]:null},UFe=function(t){if(!Array.isArray(t))return!1;for(var n=t.length,r={},o=0;o<n;o++)if(!r[t[o]])r[t[o]]=!0;else return!0;return!1},fa=function(t,n){return Je(t)&&Je(n)?function(r){return t+r*(n-t)}:function(){return n}};function cw(e,t,n){return!e||!e.length?null:e.find(function(r){return r&&(typeof t=="function"?t(r):Li(r,t))===n})}function vf(e,t){for(var n in e)if({}.hasOwnProperty.call(e,n)&&(!{}.hasOwnProperty.call(t,n)||e[n]!==t[n]))return!1;for(var r in t)if({}.hasOwnProperty.call(t,r)&&!{}.hasOwnProperty.call(e,r))return!1;return!0}function hC(e){"@babel/helpers - typeof";return hC=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},hC(e)}var zFe=["viewBox","children"],VFe=["aria-activedescendant","aria-atomic","aria-autocomplete","aria-busy","aria-checked","aria-colcount","aria-colindex","aria-colspan","aria-controls","aria-current","aria-describedby","aria-details","aria-disabled","aria-errormessage","aria-expanded","aria-flowto","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-level","aria-live","aria-modal","aria-multiline","aria-multiselectable","aria-orientation","aria-owns","aria-placeholder","aria-posinset","aria-pressed","aria-readonly","aria-relevant","aria-required","aria-roledescription","aria-rowcount","aria-rowindex","aria-rowspan","aria-selected","aria-setsize","aria-sort","aria-valuemax","aria-valuemin","aria-valuenow","aria-valuetext","className","color","height","id","lang","max","media","method","min","name","style","target","width","role","tabIndex","accentHeight","accumulate","additive","alignmentBaseline","allowReorder","alphabetic","amplitude","arabicForm","ascent","attributeName","attributeType","autoReverse","azimuth","baseFrequency","baselineShift","baseProfile","bbox","begin","bias","by","calcMode","capHeight","clip","clipPath","clipPathUnits","clipRule","colorInterpolation","colorInterpolationFilters","colorProfile","colorRendering","contentScriptType","contentStyleType","cursor","cx","cy","d","decelerate","descent","diffuseConstant","direction","display","divisor","dominantBaseline","dur","dx","dy","edgeMode","elevation","enableBackground","end","exponent","externalResourcesRequired","fill","fillOpacity","fillRule","filter","filterRes","filterUnits","floodColor","floodOpacity","focusable","fontFamily","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontWeight","format","from","fx","fy","g1","g2","glyphName","glyphOrientationHorizontal","glyphOrientationVertical","glyphRef","gradientTransform","gradientUnits","hanging","horizAdvX","horizOriginX","href","ideographic","imageRendering","in2","in","intercept","k1","k2","k3","k4","k","kernelMatrix","kernelUnitLength","kerning","keyPoints","keySplines","keyTimes","lengthAdjust","letterSpacing","lightingColor","limitingConeAngle","local","markerEnd","markerHeight","markerMid","markerStart","markerUnits","markerWidth","mask","maskContentUnits","maskUnits","mathematical","mode","numOctaves","offset","opacity","operator","order","orient","orientation","origin","overflow","overlinePosition","overlineThickness","paintOrder","panose1","pathLength","patternContentUnits","patternTransform","patternUnits","pointerEvents","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","r","radius","refX","refY","renderingIntent","repeatCount","repeatDur","requiredExtensions","requiredFeatures","restart","result","rotate","rx","ry","seed","shapeRendering","slope","spacing","specularConstant","specularExponent","speed","spreadMethod","startOffset","stdDeviation","stemh","stemv","stitchTiles","stopColor","stopOpacity","strikethroughPosition","strikethroughThickness","string","stroke","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","strokeWidth","surfaceScale","systemLanguage","tableValues","targetX","targetY","textAnchor","textDecoration","textLength","textRendering","to","transform","u1","u2","underlinePosition","underlineThickness","unicode","unicodeBidi","unicodeRange","unitsPerEm","vAlphabetic","values","vectorEffect","version","vertAdvY","vertOriginX","vertOriginY","vHanging","vIdeographic","viewTarget","visibility","vMathematical","widths","wordSpacing","writingMode","x1","x2","x","xChannelSelector","xHeight","xlinkActuate","xlinkArcrole","xlinkHref","xlinkRole","xlinkShow","xlinkTitle","xlinkType","xmlBase","xmlLang","xmlns","xmlnsXlink","xmlSpace","y1","y2","y","yChannelSelector","z","zoomAndPan","ref","key","angle"],E5=["points","pathLength"],hk={svg:zFe,polygon:E5,polyline:E5},NA=["dangerouslySetInnerHTML","onCopy","onCopyCapture","onCut","onCutCapture","onPaste","onPasteCapture","onCompositionEnd","onCompositionEndCapture","onCompositionStart","onCompositionStartCapture","onCompositionUpdate","onCompositionUpdateCapture","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onChangeCapture","onBeforeInput","onBeforeInputCapture","onInput","onInputCapture","onReset","onResetCapture","onSubmit","onSubmitCapture","onInvalid","onInvalidCapture","onLoad","onLoadCapture","onError","onErrorCapture","onKeyDown","onKeyDownCapture","onKeyPress","onKeyPressCapture","onKeyUp","onKeyUpCapture","onAbort","onAbortCapture","onCanPlay","onCanPlayCapture","onCanPlayThrough","onCanPlayThroughCapture","onDurationChange","onDurationChangeCapture","onEmptied","onEmptiedCapture","onEncrypted","onEncryptedCapture","onEnded","onEndedCapture","onLoadedData","onLoadedDataCapture","onLoadedMetadata","onLoadedMetadataCapture","onLoadStart","onLoadStartCapture","onPause","onPauseCapture","onPlay","onPlayCapture","onPlaying","onPlayingCapture","onProgress","onProgressCapture","onRateChange","onRateChangeCapture","onSeeked","onSeekedCapture","onSeeking","onSeekingCapture","onStalled","onStalledCapture","onSuspend","onSuspendCapture","onTimeUpdate","onTimeUpdateCapture","onVolumeChange","onVolumeChangeCapture","onWaiting","onWaitingCapture","onAuxClick","onAuxClickCapture","onClick","onClickCapture","onContextMenu","onContextMenuCapture","onDoubleClick","onDoubleClickCapture","onDrag","onDragCapture","onDragEnd","onDragEndCapture","onDragEnter","onDragEnterCapture","onDragExit","onDragExitCapture","onDragLeave","onDragLeaveCapture","onDragOver","onDragOverCapture","onDragStart","onDragStartCapture","onDrop","onDropCapture","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseMoveCapture","onMouseOut","onMouseOutCapture","onMouseOver","onMouseOverCapture","onMouseUp","onMouseUpCapture","onSelect","onSelectCapture","onTouchCancel","onTouchCancelCapture","onTouchEnd","onTouchEndCapture","onTouchMove","onTouchMoveCapture","onTouchStart","onTouchStartCapture","onPointerDown","onPointerDownCapture","onPointerMove","onPointerMoveCapture","onPointerUp","onPointerUpCapture","onPointerCancel","onPointerCancelCapture","onPointerEnter","onPointerEnterCapture","onPointerLeave","onPointerLeaveCapture","onPointerOver","onPointerOverCapture","onPointerOut","onPointerOutCapture","onGotPointerCapture","onGotPointerCaptureCapture","onLostPointerCapture","onLostPointerCaptureCapture","onScroll","onScrollCapture","onWheel","onWheelCapture","onAnimationStart","onAnimationStartCapture","onAnimationEnd","onAnimationEndCapture","onAnimationIteration","onAnimationIterationCapture","onTransitionEnd","onTransitionEndCapture"],uw=function(t,n){if(!t||typeof t=="function"||typeof t=="boolean")return null;var r=t;if(D.isValidElement(t)&&(r=t.props),!mh(r))return null;var o={};return Object.keys(r).forEach(function(i){NA.includes(i)&&(o[i]=n||function(a){return r[i](r,a)})}),o},WFe=function(t,n,r){return function(o){return t(n,r,o),null}},dw=function(t,n,r){if(!mh(t)||hC(t)!=="object")return null;var o=null;return Object.keys(t).forEach(function(i){var a=t[i];NA.includes(i)&&typeof a=="function"&&(o||(o={}),o[i]=WFe(a,n,r))}),o},GFe=["children"],ZFe=["children"];function C5(e,t){if(e==null)return{};var n=$Fe(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function $Fe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function pC(e){"@babel/helpers - typeof";return pC=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},pC(e)}var M5={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart",contextmenu:"onContextMenu",dblclick:"onDoubleClick"},cl=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},D5=null,pk=null,OA=function e(t){if(t===D5&&Array.isArray(pk))return pk;var n=[];return D.Children.forEach(t,function(r){Ht(r)||(OFe.isFragment(r)?n=n.concat(e(r.props.children)):n.push(r))}),pk=n,D5=t,n};function Ri(e,t){var n=[],r=[];return Array.isArray(t)?r=t.map(function(o){return cl(o)}):r=[cl(t)],OA(e).forEach(function(o){var i=Li(o,"type.displayName")||Li(o,"type.name");r.indexOf(i)!==-1&&n.push(o)}),n}function ai(e,t){var n=Ri(e,t);return n&&n[0]}var A5=function(t){if(!t||!t.props)return!1;var n=t.props,r=n.width,o=n.height;return!(!Je(r)||r<=0||!Je(o)||o<=0)},qFe=["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColormatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-url","foreignObject","g","glyph","glyphRef","hkern","image","line","lineGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","svg","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"],KFe=function(t){return t&&t.type&&Hv(t.type)&&qFe.indexOf(t.type)>=0},XFe=function(t){return t&&pC(t)==="object"&&"clipDot"in t},JFe=function(t,n,r,o){var i,a=(i=hk?.[o])!==null&&i!==void 0?i:[];return!Pt(t)&&(o&&a.includes(n)||VFe.includes(n))||r&&NA.includes(n)},_t=function(t,n,r){if(!t||typeof t=="function"||typeof t=="boolean")return null;var o=t;if(D.isValidElement(t)&&(o=t.props),!mh(o))return null;var i={};return Object.keys(o).forEach(function(a){var s;JFe((s=o)===null||s===void 0?void 0:s[a],a,n,r)&&(i[a]=o[a])}),i},mC=function e(t,n){if(t===n)return!0;var r=D.Children.count(t);if(r!==D.Children.count(n))return!1;if(r===0)return!0;if(r===1)return N5(Array.isArray(t)?t[0]:t,Array.isArray(n)?n[0]:n);for(var o=0;o<r;o++){var i=t[o],a=n[o];if(Array.isArray(i)||Array.isArray(a)){if(!e(i,a))return!1}else if(!N5(i,a))return!1}return!0},N5=function(t,n){if(Ht(t)&&Ht(n))return!0;if(!Ht(t)&&!Ht(n)){var r=t.props||{},o=r.children,i=C5(r,GFe),a=n.props||{},s=a.children,l=C5(a,ZFe);return o&&s?vf(i,l)&&mC(o,s):!o&&!s?vf(i,l):!1}return!1},O5=function(t,n){var r=[],o={};return OA(t).forEach(function(i,a){if(KFe(i))r.push(i);else if(i){var s=cl(i.type),l=n[s]||{},u=l.handler,d=l.once;if(u&&(!d||!o[s])){var h=u(i,s,a);r.push(h),o[s]=!0}}}),r},QFe=function(t){var n=t&&t.type;return n&&M5[n]?M5[n]:null},e6e=function(t,n){return OA(n).indexOf(t)},t6e=["children","width","height","viewBox","className","style","title","desc"];function gC(){return gC=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},gC.apply(this,arguments)}function n6e(e,t){if(e==null)return{};var n=r6e(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function r6e(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function vC(e){var t=e.children,n=e.width,r=e.height,o=e.viewBox,i=e.className,a=e.style,s=e.title,l=e.desc,u=n6e(e,t6e),d=o||{width:n,height:r,x:0,y:0},h=$t("recharts-surface",i);return Y.createElement("svg",gC({},_t(u,!0,"svg"),{className:h,width:n,height:r,style:a,viewBox:"".concat(d.x," ").concat(d.y," ").concat(d.width," ").concat(d.height)}),Y.createElement("title",null,s),Y.createElement("desc",null,l),t)}var o6e=["children","className"];function yC(){return yC=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},yC.apply(this,arguments)}function i6e(e,t){if(e==null)return{};var n=a6e(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function a6e(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var Xn=Y.forwardRef(function(e,t){var n=e.children,r=e.className,o=i6e(e,o6e),i=$t("recharts-layer",r);return Y.createElement("g",yC({className:i},_t(o,!0),{ref:t}),n)}),ul=function(t,n){for(var r=arguments.length,o=new Array(r>2?r-2:0),i=2;i<r;i++)o[i-2]=arguments[i]},s6e=MD;function l6e(e,t,n){var r=e.length;return n=n===void 0?r:n,!t&&n>=r?e:s6e(e,t,n)}var c6e=l6e,u6e="\\ud800-\\udfff",d6e="\\u0300-\\u036f",f6e="\\ufe20-\\ufe2f",h6e="\\u20d0-\\u20ff",p6e=d6e+f6e+h6e,m6e="\\ufe0e\\ufe0f",g6e="\\u200d",v6e=RegExp("["+g6e+u6e+p6e+m6e+"]");function y6e(e){return v6e.test(e)}var Wz=y6e;function b6e(e){return e.split("")}var w6e=b6e,Gz="\\ud800-\\udfff",S6e="\\u0300-\\u036f",T6e="\\ufe20-\\ufe2f",x6e="\\u20d0-\\u20ff",I6e=S6e+T6e+x6e,k6e="\\ufe0e\\ufe0f",E6e="["+Gz+"]",bC="["+I6e+"]",wC="\\ud83c[\\udffb-\\udfff]",C6e="(?:"+bC+"|"+wC+")",Zz="[^"+Gz+"]",$z="(?:\\ud83c[\\udde6-\\uddff]){2}",qz="[\\ud800-\\udbff][\\udc00-\\udfff]",M6e="\\u200d",Kz=C6e+"?",Xz="["+k6e+"]?",D6e="(?:"+M6e+"(?:"+[Zz,$z,qz].join("|")+")"+Xz+Kz+")*",A6e=Xz+Kz+D6e,N6e="(?:"+[Zz+bC+"?",bC,$z,qz,E6e].join("|")+")",O6e=RegExp(wC+"(?="+wC+")|"+N6e+A6e,"g");function P6e(e){return e.match(O6e)||[]}var j6e=P6e,L6e=w6e,R6e=Wz,F6e=j6e;function H6e(e){return R6e(e)?F6e(e):L6e(e)}var _6e=H6e,B6e=c6e,Y6e=Wz,U6e=_6e,z6e=e_;function V6e(e){return function(t){t=z6e(t);var n=Y6e(t)?U6e(t):void 0,r=n?n[0]:t.charAt(0),o=n?B6e(n,1).join(""):t.slice(1);return r[e]()+o}}var W6e=V6e,G6e=W6e,Z6e=G6e("toUpperCase"),$6e=Z6e;const DT=tt($6e);function wn(e){return function(){return e}}const Jz=Math.cos,fw=Math.sin,Ea=Math.sqrt,hw=Math.PI,AT=2*hw,SC=Math.PI,TC=2*SC,mu=1e-6,q6e=TC-mu;function Qz(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function K6e(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return Qz;const n=10**t;return function(r){this._+=r[0];for(let o=1,i=r.length;o<i;++o)this._+=Math.round(arguments[o]*n)/n+r[o]}}class X6e{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?Qz:K6e(t)}moveTo(t,n){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,n){this._append`L${this._x1=+t},${this._y1=+n}`}quadraticCurveTo(t,n,r,o){this._append`Q${+t},${+n},${this._x1=+r},${this._y1=+o}`}bezierCurveTo(t,n,r,o,i,a){this._append`C${+t},${+n},${+r},${+o},${this._x1=+i},${this._y1=+a}`}arcTo(t,n,r,o,i){if(t=+t,n=+n,r=+r,o=+o,i=+i,i<0)throw new Error(`negative radius: ${i}`);let a=this._x1,s=this._y1,l=r-t,u=o-n,d=a-t,h=s-n,p=d*d+h*h;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(p>mu)if(!(Math.abs(h*l-u*d)>mu)||!i)this._append`L${this._x1=t},${this._y1=n}`;else{let m=r-a,b=o-s,v=l*l+u*u,y=m*m+b*b,S=Math.sqrt(v),x=Math.sqrt(p),C=i*Math.tan((SC-Math.acos((v+p-y)/(2*S*x)))/2),k=C/x,M=C/S;Math.abs(k-1)>mu&&this._append`L${t+k*d},${n+k*h}`,this._append`A${i},${i},0,0,${+(h*m>d*b)},${this._x1=t+M*l},${this._y1=n+M*u}`}}arc(t,n,r,o,i,a){if(t=+t,n=+n,r=+r,a=!!a,r<0)throw new Error(`negative radius: ${r}`);let s=r*Math.cos(o),l=r*Math.sin(o),u=t+s,d=n+l,h=1^a,p=a?o-i:i-o;this._x1===null?this._append`M${u},${d}`:(Math.abs(this._x1-u)>mu||Math.abs(this._y1-d)>mu)&&this._append`L${u},${d}`,r&&(p<0&&(p=p%TC+TC),p>q6e?this._append`A${r},${r},0,1,${h},${t-s},${n-l}A${r},${r},0,1,${h},${this._x1=u},${this._y1=d}`:p>mu&&this._append`A${r},${r},0,${+(p>=SC)},${h},${this._x1=t+r*Math.cos(i)},${this._y1=n+r*Math.sin(i)}`)}rect(t,n,r,o){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+o}h${-r}Z`}toString(){return this._}}function PA(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{const r=Math.floor(n);if(!(r>=0))throw new RangeError(`invalid digits: ${n}`);t=r}return e},()=>new X6e(t)}function jA(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function eV(e){this._context=e}eV.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function NT(e){return new eV(e)}function tV(e){return e[0]}function nV(e){return e[1]}function rV(e,t){var n=wn(!0),r=null,o=NT,i=null,a=PA(s);e=typeof e=="function"?e:e===void 0?tV:wn(e),t=typeof t=="function"?t:t===void 0?nV:wn(t);function s(l){var u,d=(l=jA(l)).length,h,p=!1,m;for(r==null&&(i=o(m=a())),u=0;u<=d;++u)!(u<d&&n(h=l[u],u,l))===p&&((p=!p)?i.lineStart():i.lineEnd()),p&&i.point(+e(h,u,l),+t(h,u,l));if(m)return i=null,m+""||null}return s.x=function(l){return arguments.length?(e=typeof l=="function"?l:wn(+l),s):e},s.y=function(l){return arguments.length?(t=typeof l=="function"?l:wn(+l),s):t},s.defined=function(l){return arguments.length?(n=typeof l=="function"?l:wn(!!l),s):n},s.curve=function(l){return arguments.length?(o=l,r!=null&&(i=o(r)),s):o},s.context=function(l){return arguments.length?(l==null?r=i=null:i=o(r=l),s):r},s}function Tb(e,t,n){var r=null,o=wn(!0),i=null,a=NT,s=null,l=PA(u);e=typeof e=="function"?e:e===void 0?tV:wn(+e),t=typeof t=="function"?t:wn(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?nV:wn(+n);function u(h){var p,m,b,v=(h=jA(h)).length,y,S=!1,x,C=new Array(v),k=new Array(v);for(i==null&&(s=a(x=l())),p=0;p<=v;++p){if(!(p<v&&o(y=h[p],p,h))===S)if(S=!S)m=p,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),b=p-1;b>=m;--b)s.point(C[b],k[b]);s.lineEnd(),s.areaEnd()}S&&(C[p]=+e(y,p,h),k[p]=+t(y,p,h),s.point(r?+r(y,p,h):C[p],n?+n(y,p,h):k[p]))}if(x)return s=null,x+""||null}function d(){return rV().defined(o).curve(a).context(i)}return u.x=function(h){return arguments.length?(e=typeof h=="function"?h:wn(+h),r=null,u):e},u.x0=function(h){return arguments.length?(e=typeof h=="function"?h:wn(+h),u):e},u.x1=function(h){return arguments.length?(r=h==null?null:typeof h=="function"?h:wn(+h),u):r},u.y=function(h){return arguments.length?(t=typeof h=="function"?h:wn(+h),n=null,u):t},u.y0=function(h){return arguments.length?(t=typeof h=="function"?h:wn(+h),u):t},u.y1=function(h){return arguments.length?(n=h==null?null:typeof h=="function"?h:wn(+h),u):n},u.lineX0=u.lineY0=function(){return d().x(e).y(t)},u.lineY1=function(){return d().x(e).y(n)},u.lineX1=function(){return d().x(r).y(t)},u.defined=function(h){return arguments.length?(o=typeof h=="function"?h:wn(!!h),u):o},u.curve=function(h){return arguments.length?(a=h,i!=null&&(s=a(i)),u):a},u.context=function(h){return arguments.length?(h==null?i=s=null:s=a(i=h),u):i},u}class oV{constructor(t,n){this._context=t,this._x=n}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(t,n){switch(t=+t,n=+n,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,n):this._context.moveTo(t,n);break;case 1:this._point=2;default:this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,n,t,n):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+n)/2,t,this._y0,t,n);break}this._x0=t,this._y0=n}}function J6e(e){return new oV(e,!0)}function Q6e(e){return new oV(e,!1)}const LA={draw(e,t){const n=Ea(t/hw);e.moveTo(n,0),e.arc(0,0,n,0,AT)}},e8e={draw(e,t){const n=Ea(t/5)/2;e.moveTo(-3*n,-n),e.lineTo(-n,-n),e.lineTo(-n,-3*n),e.lineTo(n,-3*n),e.lineTo(n,-n),e.lineTo(3*n,-n),e.lineTo(3*n,n),e.lineTo(n,n),e.lineTo(n,3*n),e.lineTo(-n,3*n),e.lineTo(-n,n),e.lineTo(-3*n,n),e.closePath()}},iV=Ea(1/3),t8e=iV*2,n8e={draw(e,t){const n=Ea(t/t8e),r=n*iV;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},r8e={draw(e,t){const n=Ea(t),r=-n/2;e.rect(r,r,n,n)}},o8e=.8908130915292852,aV=fw(hw/10)/fw(7*hw/10),i8e=fw(AT/10)*aV,a8e=-Jz(AT/10)*aV,s8e={draw(e,t){const n=Ea(t*o8e),r=i8e*n,o=a8e*n;e.moveTo(0,-n),e.lineTo(r,o);for(let i=1;i<5;++i){const a=AT*i/5,s=Jz(a),l=fw(a);e.lineTo(l*n,-s*n),e.lineTo(s*r-l*o,l*r+s*o)}e.closePath()}},mk=Ea(3),l8e={draw(e,t){const n=-Ea(t/(mk*3));e.moveTo(0,n*2),e.lineTo(-mk*n,-n),e.lineTo(mk*n,-n),e.closePath()}},Di=-.5,Ai=Ea(3)/2,xC=1/Ea(12),c8e=(xC/2+1)*3,u8e={draw(e,t){const n=Ea(t/c8e),r=n/2,o=n*xC,i=r,a=n*xC+n,s=-i,l=a;e.moveTo(r,o),e.lineTo(i,a),e.lineTo(s,l),e.lineTo(Di*r-Ai*o,Ai*r+Di*o),e.lineTo(Di*i-Ai*a,Ai*i+Di*a),e.lineTo(Di*s-Ai*l,Ai*s+Di*l),e.lineTo(Di*r+Ai*o,Di*o-Ai*r),e.lineTo(Di*i+Ai*a,Di*a-Ai*i),e.lineTo(Di*s+Ai*l,Di*l-Ai*s),e.closePath()}};function d8e(e,t){let n=null,r=PA(o);e=typeof e=="function"?e:wn(e||LA),t=typeof t=="function"?t:wn(t===void 0?64:+t);function o(){let i;if(n||(n=i=r()),e.apply(this,arguments).draw(n,+t.apply(this,arguments)),i)return n=null,i+""||null}return o.type=function(i){return arguments.length?(e=typeof i=="function"?i:wn(i),o):e},o.size=function(i){return arguments.length?(t=typeof i=="function"?i:wn(+i),o):t},o.context=function(i){return arguments.length?(n=i??null,o):n},o}function pw(){}function mw(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function sV(e){this._context=e}sV.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:mw(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:mw(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function f8e(e){return new sV(e)}function lV(e){this._context=e}lV.prototype={areaStart:pw,areaEnd:pw,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:mw(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function h8e(e){return new lV(e)}function cV(e){this._context=e}cV.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:mw(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function p8e(e){return new cV(e)}function uV(e){this._context=e}uV.prototype={areaStart:pw,areaEnd:pw,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function m8e(e){return new uV(e)}function P5(e){return e<0?-1:1}function j5(e,t,n){var r=e._x1-e._x0,o=t-e._x1,i=(e._y1-e._y0)/(r||o<0&&-0),a=(n-e._y1)/(o||r<0&&-0),s=(i*o+a*r)/(r+o);return(P5(i)+P5(a))*Math.min(Math.abs(i),Math.abs(a),.5*Math.abs(s))||0}function L5(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function gk(e,t,n){var r=e._x0,o=e._y0,i=e._x1,a=e._y1,s=(i-r)/3;e._context.bezierCurveTo(r+s,o+s*t,i-s,a-s*n,i,a)}function gw(e){this._context=e}gw.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:gk(this,this._t0,L5(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var n=NaN;if(e=+e,t=+t,!(e===this._x1&&t===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,gk(this,L5(this,n=j5(this,e,t)),n);break;default:gk(this,this._t0,n=j5(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function dV(e){this._context=new fV(e)}(dV.prototype=Object.create(gw.prototype)).point=function(e,t){gw.prototype.point.call(this,t,e)};function fV(e){this._context=e}fV.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,n,r,o,i){this._context.bezierCurveTo(t,e,r,n,i,o)}};function g8e(e){return new gw(e)}function v8e(e){return new dV(e)}function hV(e){this._context=e}hV.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,n=e.length;if(n)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),n===2)this._context.lineTo(e[1],t[1]);else for(var r=R5(e),o=R5(t),i=0,a=1;a<n;++i,++a)this._context.bezierCurveTo(r[0][i],o[0][i],r[1][i],o[1][i],e[a],t[a]);(this._line||this._line!==0&&n===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function R5(e){var t,n=e.length-1,r,o=new Array(n),i=new Array(n),a=new Array(n);for(o[0]=0,i[0]=2,a[0]=e[0]+2*e[1],t=1;t<n-1;++t)o[t]=1,i[t]=4,a[t]=4*e[t]+2*e[t+1];for(o[n-1]=2,i[n-1]=7,a[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=o[t]/i[t-1],i[t]-=r,a[t]-=r*a[t-1];for(o[n-1]=a[n-1]/i[n-1],t=n-2;t>=0;--t)o[t]=(a[t]-o[t+1])/i[t];for(i[n-1]=(e[n]+o[n-1])/2,t=0;t<n-1;++t)i[t]=2*e[t+1]-o[t+1];return[o,i]}function y8e(e){return new hV(e)}function OT(e,t){this._context=e,this._t=t}OT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}break}this._x=e,this._y=t}};function b8e(e){return new OT(e,.5)}function w8e(e){return new OT(e,0)}function S8e(e){return new OT(e,1)}function Bf(e,t){if((a=e.length)>1)for(var n=1,r,o,i=e[t[0]],a,s=i.length;n<a;++n)for(o=i,i=e[t[n]],r=0;r<s;++r)i[r][1]+=i[r][0]=isNaN(o[r][1])?o[r][0]:o[r][1]}function IC(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function T8e(e,t){return e[t]}function x8e(e){const t=[];return t.key=e,t}function I8e(){var e=wn([]),t=IC,n=Bf,r=T8e;function o(i){var a=Array.from(e.apply(this,arguments),x8e),s,l=a.length,u=-1,d;for(const h of i)for(s=0,++u;s<l;++s)(a[s][u]=[0,+r(h,a[s].key,u,i)]).data=h;for(s=0,d=jA(t(a));s<l;++s)a[d[s]].index=s;return n(a,d),a}return o.keys=function(i){return arguments.length?(e=typeof i=="function"?i:wn(Array.from(i)),o):e},o.value=function(i){return arguments.length?(r=typeof i=="function"?i:wn(+i),o):r},o.order=function(i){return arguments.length?(t=i==null?IC:typeof i=="function"?i:wn(Array.from(i)),o):t},o.offset=function(i){return arguments.length?(n=i??Bf,o):n},o}function k8e(e,t){if((r=e.length)>0){for(var n,r,o=0,i=e[0].length,a;o<i;++o){for(a=n=0;n<r;++n)a+=e[n][o][1]||0;if(a)for(n=0;n<r;++n)e[n][o][1]/=a}Bf(e,t)}}function E8e(e,t){if((o=e.length)>0){for(var n=0,r=e[t[0]],o,i=r.length;n<i;++n){for(var a=0,s=0;a<o;++a)s+=e[a][n][1]||0;r[n][1]+=r[n][0]=-s/2}Bf(e,t)}}function C8e(e,t){if(!(!((a=e.length)>0)||!((i=(o=e[t[0]]).length)>0))){for(var n=0,r=1,o,i,a;r<i;++r){for(var s=0,l=0,u=0;s<a;++s){for(var d=e[t[s]],h=d[r][1]||0,p=d[r-1][1]||0,m=(h-p)/2,b=0;b<s;++b){var v=e[t[b]],y=v[r][1]||0,S=v[r-1][1]||0;m+=y-S}l+=h,u+=m*h}o[r-1][1]+=o[r-1][0]=n,l&&(n-=u/l)}o[r-1][1]+=o[r-1][0]=n,Bf(e,t)}}function lg(e){"@babel/helpers - typeof";return lg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lg(e)}var M8e=["type","size","sizeType"];function kC(){return kC=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},kC.apply(this,arguments)}function F5(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function H5(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?F5(Object(n),!0).forEach(function(r){D8e(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):F5(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function D8e(e,t,n){return t=A8e(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function A8e(e){var t=N8e(e,"string");return lg(t)=="symbol"?t:t+""}function N8e(e,t){if(lg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(lg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function O8e(e,t){if(e==null)return{};var n=P8e(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function P8e(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var pV={symbolCircle:LA,symbolCross:e8e,symbolDiamond:n8e,symbolSquare:r8e,symbolStar:s8e,symbolTriangle:l8e,symbolWye:u8e},j8e=Math.PI/180,L8e=function(t){var n="symbol".concat(DT(t));return pV[n]||LA},R8e=function(t,n,r){if(n==="area")return t;switch(r){case"cross":return 5*t*t/9;case"diamond":return .5*t*t/Math.sqrt(3);case"square":return t*t;case"star":var o=18*j8e;return 1.25*t*t*(Math.tan(o)-Math.tan(o*2)*Math.pow(Math.tan(o),2));case"triangle":return Math.sqrt(3)*t*t/4;case"wye":return(21-10*Math.sqrt(3))*t*t/8;default:return Math.PI*t*t/4}},F8e=function(t,n){pV["symbol".concat(DT(t))]=n},RA=function(t){var n=t.type,r=n===void 0?"circle":n,o=t.size,i=o===void 0?64:o,a=t.sizeType,s=a===void 0?"area":a,l=O8e(t,M8e),u=H5(H5({},l),{},{type:r,size:i,sizeType:s}),d=function(){var y=L8e(r),S=d8e().type(y).size(R8e(i,s,r));return S()},h=u.className,p=u.cx,m=u.cy,b=_t(u,!0);return p===+p&&m===+m&&i===+i?Y.createElement("path",kC({},b,{className:$t("recharts-symbols",h),transform:"translate(".concat(p,", ").concat(m,")"),d:d()})):null};RA.registerSymbol=F8e;function Yf(e){"@babel/helpers - typeof";return Yf=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Yf(e)}function EC(){return EC=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},EC.apply(this,arguments)}function _5(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function H8e(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?_5(Object(n),!0).forEach(function(r){cg(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_5(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function _8e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function B5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,gV(r.key),r)}}function B8e(e,t,n){return t&&B5(e.prototype,t),n&&B5(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Y8e(e,t,n){return t=vw(t),U8e(e,mV()?Reflect.construct(t,n||[],vw(e).constructor):t.apply(e,n))}function U8e(e,t){if(t&&(Yf(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return z8e(e)}function z8e(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function mV(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(mV=function(){return!!e})()}function vw(e){return vw=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},vw(e)}function V8e(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&CC(e,t)}function CC(e,t){return CC=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},CC(e,t)}function cg(e,t,n){return t=gV(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function gV(e){var t=W8e(e,"string");return Yf(t)=="symbol"?t:t+""}function W8e(e,t){if(Yf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Yf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Ni=32,FA=function(e){function t(){return _8e(this,t),Y8e(this,t,arguments)}return V8e(t,e),B8e(t,[{key:"renderIcon",value:function(r){var o=this.props.inactiveColor,i=Ni/2,a=Ni/6,s=Ni/3,l=r.inactive?o:r.color;if(r.type==="plainline")return Y.createElement("line",{strokeWidth:4,fill:"none",stroke:l,strokeDasharray:r.payload.strokeDasharray,x1:0,y1:i,x2:Ni,y2:i,className:"recharts-legend-icon"});if(r.type==="line")return Y.createElement("path",{strokeWidth:4,fill:"none",stroke:l,d:"M0,".concat(i,"h").concat(s,`
|
|
|
A`).concat(a,",").concat(a,",0,1,1,").concat(2*s,",").concat(i,`
|
|
|
H`).concat(Ni,"M").concat(2*s,",").concat(i,`
|
|
|
A`).concat(a,",").concat(a,",0,1,1,").concat(s,",").concat(i),className:"recharts-legend-icon"});if(r.type==="rect")return Y.createElement("path",{stroke:"none",fill:l,d:"M0,".concat(Ni/8,"h").concat(Ni,"v").concat(Ni*3/4,"h").concat(-Ni,"z"),className:"recharts-legend-icon"});if(Y.isValidElement(r.legendIcon)){var u=H8e({},r);return delete u.legendIcon,Y.cloneElement(r.legendIcon,u)}return Y.createElement(RA,{fill:l,cx:i,cy:i,size:Ni,sizeType:"diameter",type:r.type})}},{key:"renderItems",value:function(){var r=this,o=this.props,i=o.payload,a=o.iconSize,s=o.layout,l=o.formatter,u=o.inactiveColor,d={x:0,y:0,width:Ni,height:Ni},h={display:s==="horizontal"?"inline-block":"block",marginRight:10},p={display:"inline-block",verticalAlign:"middle",marginRight:4};return i.map(function(m,b){var v=m.formatter||l,y=$t(cg(cg({"recharts-legend-item":!0},"legend-item-".concat(b),!0),"inactive",m.inactive));if(m.type==="none")return null;var S=Pt(m.value)?null:m.value;ul(!Pt(m.value),`The name property is also required when using a function for the dataKey of a chart's cartesian components. Ex: <Bar name="Name of my Data"/>`);var x=m.inactive?u:m.color;return Y.createElement("li",EC({className:y,style:h,key:"legend-item-".concat(b)},dw(r.props,m,b)),Y.createElement(vC,{width:a,height:a,viewBox:d,style:p},r.renderIcon(m)),Y.createElement("span",{className:"recharts-legend-item-text",style:{color:x}},v?v(S,m,b):S))})}},{key:"render",value:function(){var r=this.props,o=r.payload,i=r.layout,a=r.align;if(!o||!o.length)return null;var s={padding:0,margin:0,textAlign:i==="horizontal"?a:"left"};return Y.createElement("ul",{className:"recharts-default-legend",style:s},this.renderItems())}}])}(D.PureComponent);cg(FA,"displayName","Legend");cg(FA,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});function G8e(e){return e!==e}var Z8e=G8e;function $8e(e,t,n){for(var r=n-1,o=e.length;++r<o;)if(e[r]===t)return r;return-1}var q8e=$8e,K8e=$7,X8e=Z8e,J8e=q8e;function Q8e(e,t,n){return t===t?J8e(e,t,n):K8e(e,X8e,n)}var eHe=Q8e,tHe=eHe;function nHe(e,t){var n=e==null?0:e.length;return!!n&&tHe(e,t,0)>-1}var rHe=nHe;function oHe(e,t,n){for(var r=-1,o=e==null?0:e.length;++r<o;)if(n(t,e[r]))return!0;return!1}var iHe=oHe;function aHe(){}var sHe=aHe,vk=V8,lHe=sHe,cHe=wD,uHe=1/0,dHe=vk&&1/cHe(new vk([,-0]))[1]==uHe?function(e){return new vk(e)}:lHe,fHe=dHe,hHe=s7,pHe=rHe,mHe=iHe,gHe=c7,vHe=fHe,yHe=wD,bHe=200;function wHe(e,t,n){var r=-1,o=pHe,i=e.length,a=!0,s=[],l=s;if(n)a=!1,o=mHe;else if(i>=bHe){var u=t?null:vHe(e);if(u)return yHe(u);a=!1,o=gHe,l=new hHe}else l=t?[]:s;e:for(;++r<i;){var d=e[r],h=t?t(d):d;if(d=n||d!==0?d:0,a&&h===h){for(var p=l.length;p--;)if(l[p]===h)continue e;t&&l.push(h),s.push(d)}else o(l,h,n)||(l!==s&&l.push(h),s.push(d))}return s}var SHe=wHe,THe=El,xHe=SHe;function IHe(e,t){return e&&e.length?xHe(e,THe(t)):[]}var kHe=IHe;const Y5=tt(kHe);function vV(e,t,n){return t===!0?Y5(e,n):Pt(t)?Y5(e,t):e}function Uf(e){"@babel/helpers - typeof";return Uf=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Uf(e)}var EHe=["ref"];function U5(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Gs(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?U5(Object(n),!0).forEach(function(r){PT(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):U5(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function CHe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function z5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,bV(r.key),r)}}function MHe(e,t,n){return t&&z5(e.prototype,t),n&&z5(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function DHe(e,t,n){return t=yw(t),AHe(e,yV()?Reflect.construct(t,n||[],yw(e).constructor):t.apply(e,n))}function AHe(e,t){if(t&&(Uf(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return NHe(e)}function NHe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function yV(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(yV=function(){return!!e})()}function yw(e){return yw=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},yw(e)}function OHe(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&MC(e,t)}function MC(e,t){return MC=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},MC(e,t)}function PT(e,t,n){return t=bV(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bV(e){var t=PHe(e,"string");return Uf(t)=="symbol"?t:t+""}function PHe(e,t){if(Uf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Uf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function jHe(e,t){if(e==null)return{};var n=LHe(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function LHe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function RHe(e){return e.value}function FHe(e,t){if(Y.isValidElement(e))return Y.cloneElement(e,t);if(typeof e=="function")return Y.createElement(e,t);t.ref;var n=jHe(t,EHe);return Y.createElement(FA,n)}var V5=1,yf=function(e){function t(){var n;CHe(this,t);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return n=DHe(this,t,[].concat(o)),PT(n,"lastBoundingBox",{width:-1,height:-1}),n}return OHe(t,e),MHe(t,[{key:"componentDidMount",value:function(){this.updateBBox()}},{key:"componentDidUpdate",value:function(){this.updateBBox()}},{key:"getBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var r=this.wrapperNode.getBoundingClientRect();return r.height=this.wrapperNode.offsetHeight,r.width=this.wrapperNode.offsetWidth,r}return null}},{key:"updateBBox",value:function(){var r=this.props.onBBoxUpdate,o=this.getBBox();o?(Math.abs(o.width-this.lastBoundingBox.width)>V5||Math.abs(o.height-this.lastBoundingBox.height)>V5)&&(this.lastBoundingBox.width=o.width,this.lastBoundingBox.height=o.height,r&&r(o)):(this.lastBoundingBox.width!==-1||this.lastBoundingBox.height!==-1)&&(this.lastBoundingBox.width=-1,this.lastBoundingBox.height=-1,r&&r(null))}},{key:"getBBoxSnapshot",value:function(){return this.lastBoundingBox.width>=0&&this.lastBoundingBox.height>=0?Gs({},this.lastBoundingBox):{width:0,height:0}}},{key:"getDefaultPosition",value:function(r){var o=this.props,i=o.layout,a=o.align,s=o.verticalAlign,l=o.margin,u=o.chartWidth,d=o.chartHeight,h,p;if(!r||(r.left===void 0||r.left===null)&&(r.right===void 0||r.right===null))if(a==="center"&&i==="vertical"){var m=this.getBBoxSnapshot();h={left:((u||0)-m.width)/2}}else h=a==="right"?{right:l&&l.right||0}:{left:l&&l.left||0};if(!r||(r.top===void 0||r.top===null)&&(r.bottom===void 0||r.bottom===null))if(s==="middle"){var b=this.getBBoxSnapshot();p={top:((d||0)-b.height)/2}}else p=s==="bottom"?{bottom:l&&l.bottom||0}:{top:l&&l.top||0};return Gs(Gs({},h),p)}},{key:"render",value:function(){var r=this,o=this.props,i=o.content,a=o.width,s=o.height,l=o.wrapperStyle,u=o.payloadUniqBy,d=o.payload,h=Gs(Gs({position:"absolute",width:a||"auto",height:s||"auto"},this.getDefaultPosition(l)),l);return Y.createElement("div",{className:"recharts-legend-wrapper",style:h,ref:function(m){r.wrapperNode=m}},FHe(i,Gs(Gs({},this.props),{},{payload:vV(d,u,RHe)})))}}],[{key:"getWithHeight",value:function(r,o){var i=Gs(Gs({},this.defaultProps),r.props),a=i.layout;return a==="vertical"&&Je(r.props.height)?{height:r.props.height}:a==="horizontal"?{width:r.props.width||o}:null}}])}(D.PureComponent);PT(yf,"displayName","Legend");PT(yf,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});function ug(e){"@babel/helpers - typeof";return ug=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ug(e)}function DC(){return DC=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},DC.apply(this,arguments)}function HHe(e,t){return UHe(e)||YHe(e,t)||BHe(e,t)||_He()}function _He(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function BHe(e,t){if(e){if(typeof e=="string")return W5(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return W5(e,t)}}function W5(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function YHe(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(d){u=!0,o=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}function UHe(e){if(Array.isArray(e))return e}function G5(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function yk(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?G5(Object(n),!0).forEach(function(r){zHe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):G5(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function zHe(e,t,n){return t=VHe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function VHe(e){var t=WHe(e,"string");return ug(t)=="symbol"?t:t+""}function WHe(e,t){if(ug(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(ug(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function GHe(e){return Array.isArray(e)&&dr(e[0])&&dr(e[1])?e.join(" ~ "):e}var ZHe=function(t){var n=t.separator,r=n===void 0?" : ":n,o=t.contentStyle,i=o===void 0?{}:o,a=t.itemStyle,s=a===void 0?{}:a,l=t.labelStyle,u=l===void 0?{}:l,d=t.payload,h=t.formatter,p=t.itemSorter,m=t.wrapperClassName,b=t.labelClassName,v=t.label,y=t.labelFormatter,S=t.accessibilityLayer,x=S===void 0?!1:S,C=function(){if(d&&d.length){var H={padding:0,margin:0},U=(p?FS(d,p):d).map(function(G,K){if(G.type==="none")return null;var z=yk({display:"block",paddingTop:4,paddingBottom:4,color:G.color||"#000"},s),ne=G.formatter||h||GHe,J=G.value,ee=G.name,Z=J,q=ee;if(ne&&Z!=null&&q!=null){var $=ne(J,ee,G,K,d);if(Array.isArray($)){var re=HHe($,2);Z=re[0],q=re[1]}else Z=$}return Y.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(K),style:z},dr(q)?Y.createElement("span",{className:"recharts-tooltip-item-name"},q):null,dr(q)?Y.createElement("span",{className:"recharts-tooltip-item-separator"},r):null,Y.createElement("span",{className:"recharts-tooltip-item-value"},Z),Y.createElement("span",{className:"recharts-tooltip-item-unit"},G.unit||""))});return Y.createElement("ul",{className:"recharts-tooltip-item-list",style:H},U)}return null},k=yk({margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},i),M=yk({margin:0},u),I=!Ht(v),O=I?v:"",R=$t("recharts-default-tooltip",m),L=$t("recharts-tooltip-label",b);I&&y&&d!==void 0&&d!==null&&(O=y(v,d));var B=x?{role:"status","aria-live":"assertive"}:{};return Y.createElement("div",DC({className:R,style:k},B),Y.createElement("p",{className:L,style:M},Y.isValidElement(O)?O:"".concat(O)),C())};function dg(e){"@babel/helpers - typeof";return dg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},dg(e)}function xb(e,t,n){return t=$He(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $He(e){var t=qHe(e,"string");return dg(t)=="symbol"?t:t+""}function qHe(e,t){if(dg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(dg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Yp="recharts-tooltip-wrapper",KHe={visibility:"hidden"};function XHe(e){var t=e.coordinate,n=e.translateX,r=e.translateY;return $t(Yp,xb(xb(xb(xb({},"".concat(Yp,"-right"),Je(n)&&t&&Je(t.x)&&n>=t.x),"".concat(Yp,"-left"),Je(n)&&t&&Je(t.x)&&n<t.x),"".concat(Yp,"-bottom"),Je(r)&&t&&Je(t.y)&&r>=t.y),"".concat(Yp,"-top"),Je(r)&&t&&Je(t.y)&&r<t.y))}function Z5(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.key,o=e.offsetTopLeft,i=e.position,a=e.reverseDirection,s=e.tooltipDimension,l=e.viewBox,u=e.viewBoxDimension;if(i&&Je(i[r]))return i[r];var d=n[r]-s-o,h=n[r]+o;if(t[r])return a[r]?d:h;if(a[r]){var p=d,m=l[r];return p<m?Math.max(h,l[r]):Math.max(d,l[r])}var b=h+s,v=l[r]+u;return b>v?Math.max(d,l[r]):Math.max(h,l[r])}function JHe(e){var t=e.translateX,n=e.translateY,r=e.useTranslate3d;return{transform:r?"translate3d(".concat(t,"px, ").concat(n,"px, 0)"):"translate(".concat(t,"px, ").concat(n,"px)")}}function QHe(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.offsetTopLeft,o=e.position,i=e.reverseDirection,a=e.tooltipBox,s=e.useTranslate3d,l=e.viewBox,u,d,h;return a.height>0&&a.width>0&&n?(d=Z5({allowEscapeViewBox:t,coordinate:n,key:"x",offsetTopLeft:r,position:o,reverseDirection:i,tooltipDimension:a.width,viewBox:l,viewBoxDimension:l.width}),h=Z5({allowEscapeViewBox:t,coordinate:n,key:"y",offsetTopLeft:r,position:o,reverseDirection:i,tooltipDimension:a.height,viewBox:l,viewBoxDimension:l.height}),u=JHe({translateX:d,translateY:h,useTranslate3d:s})):u=KHe,{cssProperties:u,cssClasses:XHe({translateX:d,translateY:h,coordinate:n})}}function zf(e){"@babel/helpers - typeof";return zf=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},zf(e)}function $5(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function q5(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$5(Object(n),!0).forEach(function(r){NC(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$5(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function e7e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function K5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,SV(r.key),r)}}function t7e(e,t,n){return t&&K5(e.prototype,t),n&&K5(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function n7e(e,t,n){return t=bw(t),r7e(e,wV()?Reflect.construct(t,n||[],bw(e).constructor):t.apply(e,n))}function r7e(e,t){if(t&&(zf(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return o7e(e)}function o7e(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function wV(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(wV=function(){return!!e})()}function bw(e){return bw=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},bw(e)}function i7e(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&AC(e,t)}function AC(e,t){return AC=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},AC(e,t)}function NC(e,t,n){return t=SV(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function SV(e){var t=a7e(e,"string");return zf(t)=="symbol"?t:t+""}function a7e(e,t){if(zf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(zf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var X5=1,s7e=function(e){function t(){var n;e7e(this,t);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return n=n7e(this,t,[].concat(o)),NC(n,"state",{dismissed:!1,dismissedAtCoordinate:{x:0,y:0},lastBoundingBox:{width:-1,height:-1}}),NC(n,"handleKeyDown",function(a){if(a.key==="Escape"){var s,l,u,d;n.setState({dismissed:!0,dismissedAtCoordinate:{x:(s=(l=n.props.coordinate)===null||l===void 0?void 0:l.x)!==null&&s!==void 0?s:0,y:(u=(d=n.props.coordinate)===null||d===void 0?void 0:d.y)!==null&&u!==void 0?u:0}})}}),n}return i7e(t,e),t7e(t,[{key:"updateBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var r=this.wrapperNode.getBoundingClientRect();(Math.abs(r.width-this.state.lastBoundingBox.width)>X5||Math.abs(r.height-this.state.lastBoundingBox.height)>X5)&&this.setState({lastBoundingBox:{width:r.width,height:r.height}})}else(this.state.lastBoundingBox.width!==-1||this.state.lastBoundingBox.height!==-1)&&this.setState({lastBoundingBox:{width:-1,height:-1}})}},{key:"componentDidMount",value:function(){document.addEventListener("keydown",this.handleKeyDown),this.updateBBox()}},{key:"componentWillUnmount",value:function(){document.removeEventListener("keydown",this.handleKeyDown)}},{key:"componentDidUpdate",value:function(){var r,o;this.props.active&&this.updateBBox(),this.state.dismissed&&(((r=this.props.coordinate)===null||r===void 0?void 0:r.x)!==this.state.dismissedAtCoordinate.x||((o=this.props.coordinate)===null||o===void 0?void 0:o.y)!==this.state.dismissedAtCoordinate.y)&&(this.state.dismissed=!1)}},{key:"render",value:function(){var r=this,o=this.props,i=o.active,a=o.allowEscapeViewBox,s=o.animationDuration,l=o.animationEasing,u=o.children,d=o.coordinate,h=o.hasPayload,p=o.isAnimationActive,m=o.offset,b=o.position,v=o.reverseDirection,y=o.useTranslate3d,S=o.viewBox,x=o.wrapperStyle,C=QHe({allowEscapeViewBox:a,coordinate:d,offsetTopLeft:m,position:b,reverseDirection:v,tooltipBox:this.state.lastBoundingBox,useTranslate3d:y,viewBox:S}),k=C.cssClasses,M=C.cssProperties,I=q5(q5({transition:p&&i?"transform ".concat(s,"ms ").concat(l):void 0},M),{},{pointerEvents:"none",visibility:!this.state.dismissed&&i&&h?"visible":"hidden",position:"absolute",top:0,left:0},x);return Y.createElement("div",{tabIndex:-1,className:k,style:I,ref:function(R){r.wrapperNode=R}},u)}}])}(D.PureComponent),l7e=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},dl={isSsr:l7e(),get:function(t){return dl[t]},set:function(t,n){if(typeof t=="string")dl[t]=n;else{var r=Object.keys(t);r&&r.length&&r.forEach(function(o){dl[o]=t[o]})}}};function Vf(e){"@babel/helpers - typeof";return Vf=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Vf(e)}function J5(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Q5(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?J5(Object(n),!0).forEach(function(r){HA(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):J5(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function c7e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function e9(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,xV(r.key),r)}}function u7e(e,t,n){return t&&e9(e.prototype,t),n&&e9(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function d7e(e,t,n){return t=ww(t),f7e(e,TV()?Reflect.construct(t,n||[],ww(e).constructor):t.apply(e,n))}function f7e(e,t){if(t&&(Vf(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return h7e(e)}function h7e(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function TV(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(TV=function(){return!!e})()}function ww(e){return ww=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ww(e)}function p7e(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&OC(e,t)}function OC(e,t){return OC=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},OC(e,t)}function HA(e,t,n){return t=xV(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xV(e){var t=m7e(e,"string");return Vf(t)=="symbol"?t:t+""}function m7e(e,t){if(Vf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Vf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function g7e(e){return e.dataKey}function v7e(e,t){return Y.isValidElement(e)?Y.cloneElement(e,t):typeof e=="function"?Y.createElement(e,t):Y.createElement(ZHe,t)}var es=function(e){function t(){return c7e(this,t),d7e(this,t,arguments)}return p7e(t,e),u7e(t,[{key:"render",value:function(){var r=this,o=this.props,i=o.active,a=o.allowEscapeViewBox,s=o.animationDuration,l=o.animationEasing,u=o.content,d=o.coordinate,h=o.filterNull,p=o.isAnimationActive,m=o.offset,b=o.payload,v=o.payloadUniqBy,y=o.position,S=o.reverseDirection,x=o.useTranslate3d,C=o.viewBox,k=o.wrapperStyle,M=b??[];h&&M.length&&(M=vV(b.filter(function(O){return O.value!=null&&(O.hide!==!0||r.props.includeHidden)}),v,g7e));var I=M.length>0;return Y.createElement(s7e,{allowEscapeViewBox:a,animationDuration:s,animationEasing:l,isAnimationActive:p,active:i,coordinate:d,hasPayload:I,offset:m,position:y,reverseDirection:S,useTranslate3d:x,viewBox:C,wrapperStyle:k},v7e(u,Q5(Q5({},this.props),{},{payload:M})))}}])}(D.PureComponent);HA(es,"displayName","Tooltip");HA(es,"defaultProps",{accessibilityLayer:!1,allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!dl.isSsr,itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:" : ",trigger:"hover",useTranslate3d:!1,viewBox:{x:0,y:0,height:0,width:0},wrapperStyle:{}});function fg(e){"@babel/helpers - typeof";return fg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fg(e)}function t9(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Ib(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?t9(Object(n),!0).forEach(function(r){y7e(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):t9(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function y7e(e,t,n){return t=b7e(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function b7e(e){var t=w7e(e,"string");return fg(t)=="symbol"?t:t+""}function w7e(e,t){if(fg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(fg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function S7e(e,t){return k7e(e)||I7e(e,t)||x7e(e,t)||T7e()}function T7e(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function x7e(e,t){if(e){if(typeof e=="string")return n9(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return n9(e,t)}}function n9(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function I7e(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(d){u=!0,o=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}function k7e(e){if(Array.isArray(e))return e}var E7e=D.forwardRef(function(e,t){var n=e.aspect,r=e.initialDimension,o=r===void 0?{width:-1,height:-1}:r,i=e.width,a=i===void 0?"100%":i,s=e.height,l=s===void 0?"100%":s,u=e.minWidth,d=u===void 0?0:u,h=e.minHeight,p=e.maxHeight,m=e.children,b=e.debounce,v=b===void 0?0:b,y=e.id,S=e.className,x=e.onResize,C=e.style,k=C===void 0?{}:C,M=D.useRef(null),I=D.useRef();I.current=x,D.useImperativeHandle(t,function(){return Object.defineProperty(M.current,"current",{get:function(){return console.warn("The usage of ref.current.current is deprecated and will no longer be supported."),M.current},configurable:!0})});var O=D.useState({containerWidth:o.width,containerHeight:o.height}),R=S7e(O,2),L=R[0],B=R[1],_=D.useCallback(function(U,G){B(function(K){var z=Math.round(U),ne=Math.round(G);return K.containerWidth===z&&K.containerHeight===ne?K:{containerWidth:z,containerHeight:ne}})},[]);D.useEffect(function(){var U=function(ee){var Z,q=ee[0].contentRect,$=q.width,re=q.height;_($,re),(Z=I.current)===null||Z===void 0||Z.call(I,$,re)};v>0&&(U=tA(U,v,{trailing:!0,leading:!1}));var G=new ResizeObserver(U),K=M.current.getBoundingClientRect(),z=K.width,ne=K.height;return _(z,ne),G.observe(M.current),function(){G.disconnect()}},[_,v]);var H=D.useMemo(function(){var U=L.containerWidth,G=L.containerHeight;if(U<0||G<0)return null;ul(xu(a)||xu(l),`The width(%s) and height(%s) are both fixed numbers,
|
|
|
maybe you don't need to use a ResponsiveContainer.`,a,l),ul(!n||n>0,"The aspect(%s) must be greater than zero.",n);var K=xu(a)?U:a,z=xu(l)?G:l;n&&n>0&&(K?z=K/n:z&&(K=z*n),p&&z>p&&(z=p)),ul(K>0||z>0,`The width(%s) and height(%s) of chart should be greater than 0,
|
|
|
please check the style of container, or the props width(%s) and height(%s),
|
|
|
or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the
|
|
|
height and width.`,K,z,a,l,d,h,n);var ne=!Array.isArray(m)&&cl(m.type).endsWith("Chart");return Y.Children.map(m,function(J){return Y.isValidElement(J)?D.cloneElement(J,Ib({width:K,height:z},ne?{style:Ib({height:"100%",width:"100%",maxHeight:z,maxWidth:K},J.props.style)}:{})):J})},[n,m,l,p,h,d,L,a]);return Y.createElement("div",{id:y?"".concat(y):void 0,className:$t("recharts-responsive-container",S),style:Ib(Ib({},k),{},{width:a,height:l,minWidth:d,minHeight:h,maxHeight:p}),ref:M},H)}),IV=function(t){return null};IV.displayName="Cell";function hg(e){"@babel/helpers - typeof";return hg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},hg(e)}function r9(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function PC(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?r9(Object(n),!0).forEach(function(r){C7e(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r9(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function C7e(e,t,n){return t=M7e(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function M7e(e){var t=D7e(e,"string");return hg(t)=="symbol"?t:t+""}function D7e(e,t){if(hg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(hg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var qd={widthCache:{},cacheCount:0},A7e=2e3,N7e={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},o9="recharts_measurement_span";function O7e(e){var t=PC({},e);return Object.keys(t).forEach(function(n){t[n]||delete t[n]}),t}var km=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||dl.isSsr)return{width:0,height:0};var r=O7e(n),o=JSON.stringify({text:t,copyStyle:r});if(qd.widthCache[o])return qd.widthCache[o];try{var i=document.getElementById(o9);i||(i=document.createElement("span"),i.setAttribute("id",o9),i.setAttribute("aria-hidden","true"),document.body.appendChild(i));var a=PC(PC({},N7e),r);Object.assign(i.style,a),i.textContent="".concat(t);var s=i.getBoundingClientRect(),l={width:s.width,height:s.height};return qd.widthCache[o]=l,++qd.cacheCount>A7e&&(qd.cacheCount=0,qd.widthCache={}),l}catch{return{width:0,height:0}}},P7e=function(t){return{top:t.top+window.scrollY-document.documentElement.clientTop,left:t.left+window.scrollX-document.documentElement.clientLeft}};function pg(e){"@babel/helpers - typeof";return pg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},pg(e)}function Sw(e,t){return F7e(e)||R7e(e,t)||L7e(e,t)||j7e()}function j7e(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function L7e(e,t){if(e){if(typeof e=="string")return i9(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return i9(e,t)}}function i9(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function R7e(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(d){u=!0,o=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}function F7e(e){if(Array.isArray(e))return e}function H7e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a9(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,B7e(r.key),r)}}function _7e(e,t,n){return t&&a9(e.prototype,t),n&&a9(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function B7e(e){var t=Y7e(e,"string");return pg(t)=="symbol"?t:t+""}function Y7e(e,t){if(pg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(pg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var s9=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,l9=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,U7e=/^px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q$/,z7e=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,kV={cm:96/2.54,mm:96/25.4,pt:96/72,pc:96/6,in:96,Q:96/(2.54*40),px:1},V7e=Object.keys(kV),uf="NaN";function W7e(e,t){return e*kV[t]}var kb=function(){function e(t,n){H7e(this,e),this.num=t,this.unit=n,this.num=t,this.unit=n,Number.isNaN(t)&&(this.unit=""),n!==""&&!U7e.test(n)&&(this.num=NaN,this.unit=""),V7e.includes(n)&&(this.num=W7e(t,n),this.unit="px")}return _7e(e,[{key:"add",value:function(n){return this.unit!==n.unit?new e(NaN,""):new e(this.num+n.num,this.unit)}},{key:"subtract",value:function(n){return this.unit!==n.unit?new e(NaN,""):new e(this.num-n.num,this.unit)}},{key:"multiply",value:function(n){return this.unit!==""&&n.unit!==""&&this.unit!==n.unit?new e(NaN,""):new e(this.num*n.num,this.unit||n.unit)}},{key:"divide",value:function(n){return this.unit!==""&&n.unit!==""&&this.unit!==n.unit?new e(NaN,""):new e(this.num/n.num,this.unit||n.unit)}},{key:"toString",value:function(){return"".concat(this.num).concat(this.unit)}},{key:"isNaN",value:function(){return Number.isNaN(this.num)}}],[{key:"parse",value:function(n){var r,o=(r=z7e.exec(n))!==null&&r!==void 0?r:[],i=Sw(o,3),a=i[1],s=i[2];return new e(parseFloat(a),s??"")}}])}();function EV(e){if(e.includes(uf))return uf;for(var t=e;t.includes("*")||t.includes("/");){var n,r=(n=s9.exec(t))!==null&&n!==void 0?n:[],o=Sw(r,4),i=o[1],a=o[2],s=o[3],l=kb.parse(i??""),u=kb.parse(s??""),d=a==="*"?l.multiply(u):l.divide(u);if(d.isNaN())return uf;t=t.replace(s9,d.toString())}for(;t.includes("+")||/.-\d+(?:\.\d+)?/.test(t);){var h,p=(h=l9.exec(t))!==null&&h!==void 0?h:[],m=Sw(p,4),b=m[1],v=m[2],y=m[3],S=kb.parse(b??""),x=kb.parse(y??""),C=v==="+"?S.add(x):S.subtract(x);if(C.isNaN())return uf;t=t.replace(l9,C.toString())}return t}var c9=/\(([^()]*)\)/;function G7e(e){for(var t=e;t.includes("(");){var n=c9.exec(t),r=Sw(n,2),o=r[1];t=t.replace(c9,EV(o))}return t}function Z7e(e){var t=e.replace(/\s+/g,"");return t=G7e(t),t=EV(t),t}function $7e(e){try{return Z7e(e)}catch{return uf}}function bk(e){var t=$7e(e.slice(5,-1));return t===uf?"":t}var q7e=["x","y","lineHeight","capHeight","scaleToFit","textAnchor","verticalAnchor","fill"],K7e=["dx","dy","angle","className","breakAll"];function jC(){return jC=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},jC.apply(this,arguments)}function u9(e,t){if(e==null)return{};var n=X7e(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function X7e(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function d9(e,t){return t_e(e)||e_e(e,t)||Q7e(e,t)||J7e()}function J7e(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Q7e(e,t){if(e){if(typeof e=="string")return f9(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return f9(e,t)}}function f9(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function e_e(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(d){u=!0,o=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}function t_e(e){if(Array.isArray(e))return e}var CV=/[ \f\n\r\t\v\u2028\u2029]+/,MV=function(t){var n=t.children,r=t.breakAll,o=t.style;try{var i=[];Ht(n)||(r?i=n.toString().split(""):i=n.toString().split(CV));var a=i.map(function(l){return{word:l,width:km(l,o).width}}),s=r?0:km(" ",o).width;return{wordsWithComputedWidth:a,spaceWidth:s}}catch{return null}},n_e=function(t,n,r,o,i){var a=t.maxLines,s=t.children,l=t.style,u=t.breakAll,d=Je(a),h=s,p=function(){var K=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return K.reduce(function(z,ne){var J=ne.word,ee=ne.width,Z=z[z.length-1];if(Z&&(o==null||i||Z.width+ee+r<Number(o)))Z.words.push(J),Z.width+=ee+r;else{var q={words:[J],width:ee};z.push(q)}return z},[])},m=p(n),b=function(K){return K.reduce(function(z,ne){return z.width>ne.width?z:ne})};if(!d)return m;for(var v="…",y=function(K){var z=h.slice(0,K),ne=MV({breakAll:u,style:l,children:z+v}).wordsWithComputedWidth,J=p(ne),ee=J.length>a||b(J).width>Number(o);return[ee,J]},S=0,x=h.length-1,C=0,k;S<=x&&C<=h.length-1;){var M=Math.floor((S+x)/2),I=M-1,O=y(I),R=d9(O,2),L=R[0],B=R[1],_=y(M),H=d9(_,1),U=H[0];if(!L&&!U&&(S=M+1),L&&U&&(x=M-1),!L&&U){k=B;break}C++}return k||m},h9=function(t){var n=Ht(t)?[]:t.toString().split(CV);return[{words:n}]},r_e=function(t){var n=t.width,r=t.scaleToFit,o=t.children,i=t.style,a=t.breakAll,s=t.maxLines;if((n||r)&&!dl.isSsr){var l,u,d=MV({breakAll:a,children:o,style:i});if(d){var h=d.wordsWithComputedWidth,p=d.spaceWidth;l=h,u=p}else return h9(o);return n_e({breakAll:a,children:o,maxLines:s,style:i},l,u,n,r)}return h9(o)},p9="#808080",Tw=function(t){var n=t.x,r=n===void 0?0:n,o=t.y,i=o===void 0?0:o,a=t.lineHeight,s=a===void 0?"1em":a,l=t.capHeight,u=l===void 0?"0.71em":l,d=t.scaleToFit,h=d===void 0?!1:d,p=t.textAnchor,m=p===void 0?"start":p,b=t.verticalAnchor,v=b===void 0?"end":b,y=t.fill,S=y===void 0?p9:y,x=u9(t,q7e),C=D.useMemo(function(){return r_e({breakAll:x.breakAll,children:x.children,maxLines:x.maxLines,scaleToFit:h,style:x.style,width:x.width})},[x.breakAll,x.children,x.maxLines,h,x.style,x.width]),k=x.dx,M=x.dy,I=x.angle,O=x.className,R=x.breakAll,L=u9(x,K7e);if(!dr(r)||!dr(i))return null;var B=r+(Je(k)?k:0),_=i+(Je(M)?M:0),H;switch(v){case"start":H=bk("calc(".concat(u,")"));break;case"middle":H=bk("calc(".concat((C.length-1)/2," * -").concat(s," + (").concat(u," / 2))"));break;default:H=bk("calc(".concat(C.length-1," * -").concat(s,")"));break}var U=[];if(h){var G=C[0].width,K=x.width;U.push("scale(".concat((Je(K)?K/G:1)/G,")"))}return I&&U.push("rotate(".concat(I,", ").concat(B,", ").concat(_,")")),U.length&&(L.transform=U.join(" ")),Y.createElement("text",jC({},_t(L,!0),{x:B,y:_,className:$t("recharts-text",O),textAnchor:m,fill:S.includes("url")?p9:S}),C.map(function(z,ne){var J=z.words.join(R?"":" ");return Y.createElement("tspan",{x:B,dy:ne===0?H:s,key:"".concat(J,"-").concat(ne)},J)}))};function yc(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function o_e(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function _A(e){let t,n,r;e.length!==2?(t=yc,n=(s,l)=>yc(e(s),l),r=(s,l)=>e(s)-l):(t=e===yc||e===o_e?e:i_e,n=e,r=e);function o(s,l,u=0,d=s.length){if(u<d){if(t(l,l)!==0)return d;do{const h=u+d>>>1;n(s[h],l)<0?u=h+1:d=h}while(u<d)}return u}function i(s,l,u=0,d=s.length){if(u<d){if(t(l,l)!==0)return d;do{const h=u+d>>>1;n(s[h],l)<=0?u=h+1:d=h}while(u<d)}return u}function a(s,l,u=0,d=s.length){const h=o(s,l,u,d-1);return h>u&&r(s[h-1],l)>-r(s[h],l)?h-1:h}return{left:o,center:a,right:i}}function i_e(){return 0}function DV(e){return e===null?NaN:+e}function*a_e(e,t){if(t===void 0)for(let n of e)n!=null&&(n=+n)>=n&&(yield n);else{let n=-1;for(let r of e)(r=t(r,++n,e))!=null&&(r=+r)>=r&&(yield r)}}const s_e=_A(yc),Yv=s_e.right;_A(DV).center;class m9 extends Map{constructor(t,n=u_e){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[r,o]of t)this.set(r,o)}get(t){return super.get(g9(this,t))}has(t){return super.has(g9(this,t))}set(t,n){return super.set(l_e(this,t),n)}delete(t){return super.delete(c_e(this,t))}}function g9({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function l_e({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function c_e({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function u_e(e){return e!==null&&typeof e=="object"?e.valueOf():e}function d_e(e=yc){if(e===yc)return AV;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const r=e(t,n);return r||r===0?r:(e(n,n)===0)-(e(t,t)===0)}}function AV(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const f_e=Math.sqrt(50),h_e=Math.sqrt(10),p_e=Math.sqrt(2);function xw(e,t,n){const r=(t-e)/Math.max(0,n),o=Math.floor(Math.log10(r)),i=r/Math.pow(10,o),a=i>=f_e?10:i>=h_e?5:i>=p_e?2:1;let s,l,u;return o<0?(u=Math.pow(10,-o)/a,s=Math.round(e*u),l=Math.round(t*u),s/u<e&&++s,l/u>t&&--l,u=-u):(u=Math.pow(10,o)*a,s=Math.round(e/u),l=Math.round(t/u),s*u<e&&++s,l*u>t&&--l),l<s&&.5<=n&&n<2?xw(e,t,n*2):[s,l,u]}function LC(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[o,i,a]=r?xw(t,e,n):xw(e,t,n);if(!(i>=o))return[];const s=i-o+1,l=new Array(s);if(r)if(a<0)for(let u=0;u<s;++u)l[u]=(i-u)/-a;else for(let u=0;u<s;++u)l[u]=(i-u)*a;else if(a<0)for(let u=0;u<s;++u)l[u]=(o+u)/-a;else for(let u=0;u<s;++u)l[u]=(o+u)*a;return l}function RC(e,t,n){return t=+t,e=+e,n=+n,xw(e,t,n)[2]}function FC(e,t,n){t=+t,e=+e,n=+n;const r=t<e,o=r?RC(t,e,n):RC(e,t,n);return(r?-1:1)*(o<0?1/-o:o)}function v9(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let o of e)(o=t(o,++r,e))!=null&&(n<o||n===void 0&&o>=o)&&(n=o)}return n}function y9(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let o of e)(o=t(o,++r,e))!=null&&(n>o||n===void 0&&o>=o)&&(n=o)}return n}function NV(e,t,n=0,r=1/0,o){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(e.length-1,r)),!(n<=t&&t<=r))return e;for(o=o===void 0?AV:d_e(o);r>n;){if(r-n>600){const l=r-n+1,u=t-n+1,d=Math.log(l),h=.5*Math.exp(2*d/3),p=.5*Math.sqrt(d*h*(l-h)/l)*(u-l/2<0?-1:1),m=Math.max(n,Math.floor(t-u*h/l+p)),b=Math.min(r,Math.floor(t+(l-u)*h/l+p));NV(e,t,m,b,o)}const i=e[t];let a=n,s=r;for(Up(e,n,t),o(e[r],i)>0&&Up(e,n,r);a<s;){for(Up(e,a,s),++a,--s;o(e[a],i)<0;)++a;for(;o(e[s],i)>0;)--s}o(e[n],i)===0?Up(e,n,s):(++s,Up(e,s,r)),s<=t&&(n=s+1),t<=s&&(r=s-1)}return e}function Up(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function m_e(e,t,n){if(e=Float64Array.from(a_e(e,n)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return y9(e);if(t>=1)return v9(e);var r,o=(r-1)*t,i=Math.floor(o),a=v9(NV(e,i).subarray(0,i+1)),s=y9(e.subarray(i+1));return a+(s-a)*(o-i)}}function g_e(e,t,n=DV){if(!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return+n(e[0],0,e);if(t>=1)return+n(e[r-1],r-1,e);var r,o=(r-1)*t,i=Math.floor(o),a=+n(e[i],i,e),s=+n(e[i+1],i+1,e);return a+(s-a)*(o-i)}}function v_e(e,t,n){e=+e,t=+t,n=(o=arguments.length)<2?(t=e,e=0,1):o<3?1:+n;for(var r=-1,o=Math.max(0,Math.ceil((t-e)/n))|0,i=new Array(o);++r<o;)i[r]=e+r*n;return i}function Gi(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function Al(e,t){switch(arguments.length){case 0:break;case 1:typeof e=="function"?this.interpolator(e):this.range(e);break;default:this.domain(e),typeof t=="function"?this.interpolator(t):this.range(t);break}return this}const HC=Symbol("implicit");function BA(){var e=new m9,t=[],n=[],r=HC;function o(i){let a=e.get(i);if(a===void 0){if(r!==HC)return r;e.set(i,a=t.push(i)-1)}return n[a%n.length]}return o.domain=function(i){if(!arguments.length)return t.slice();t=[],e=new m9;for(const a of i)e.has(a)||e.set(a,t.push(a)-1);return o},o.range=function(i){return arguments.length?(n=Array.from(i),o):n.slice()},o.unknown=function(i){return arguments.length?(r=i,o):r},o.copy=function(){return BA(t,n).unknown(r)},Gi.apply(o,arguments),o}function mg(){var e=BA().unknown(void 0),t=e.domain,n=e.range,r=0,o=1,i,a,s=!1,l=0,u=0,d=.5;delete e.unknown;function h(){var p=t().length,m=o<r,b=m?o:r,v=m?r:o;i=(v-b)/Math.max(1,p-l+u*2),s&&(i=Math.floor(i)),b+=(v-b-i*(p-l))*d,a=i*(1-l),s&&(b=Math.round(b),a=Math.round(a));var y=v_e(p).map(function(S){return b+i*S});return n(m?y.reverse():y)}return e.domain=function(p){return arguments.length?(t(p),h()):t()},e.range=function(p){return arguments.length?([r,o]=p,r=+r,o=+o,h()):[r,o]},e.rangeRound=function(p){return[r,o]=p,r=+r,o=+o,s=!0,h()},e.bandwidth=function(){return a},e.step=function(){return i},e.round=function(p){return arguments.length?(s=!!p,h()):s},e.padding=function(p){return arguments.length?(l=Math.min(1,u=+p),h()):l},e.paddingInner=function(p){return arguments.length?(l=Math.min(1,p),h()):l},e.paddingOuter=function(p){return arguments.length?(u=+p,h()):u},e.align=function(p){return arguments.length?(d=Math.max(0,Math.min(1,p)),h()):d},e.copy=function(){return mg(t(),[r,o]).round(s).paddingInner(l).paddingOuter(u).align(d)},Gi.apply(h(),arguments)}function OV(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return OV(t())},e}function Em(){return OV(mg.apply(null,arguments).paddingInner(1))}function YA(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function PV(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function Uv(){}var gg=.7,Iw=1/gg,bf="\\s*([+-]?\\d+)\\s*",vg="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",gs="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",y_e=/^#([0-9a-f]{3,8})$/,b_e=new RegExp(`^rgb\\(${bf},${bf},${bf}\\)$`),w_e=new RegExp(`^rgb\\(${gs},${gs},${gs}\\)$`),S_e=new RegExp(`^rgba\\(${bf},${bf},${bf},${vg}\\)$`),T_e=new RegExp(`^rgba\\(${gs},${gs},${gs},${vg}\\)$`),x_e=new RegExp(`^hsl\\(${vg},${gs},${gs}\\)$`),I_e=new RegExp(`^hsla\\(${vg},${gs},${gs},${vg}\\)$`),b9={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};YA(Uv,yg,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:w9,formatHex:w9,formatHex8:k_e,formatHsl:E_e,formatRgb:S9,toString:S9});function w9(){return this.rgb().formatHex()}function k_e(){return this.rgb().formatHex8()}function E_e(){return jV(this).formatHsl()}function S9(){return this.rgb().formatRgb()}function yg(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=y_e.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?T9(t):n===3?new Yo(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?Eb(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?Eb(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=b_e.exec(e))?new Yo(t[1],t[2],t[3],1):(t=w_e.exec(e))?new Yo(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=S_e.exec(e))?Eb(t[1],t[2],t[3],t[4]):(t=T_e.exec(e))?Eb(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=x_e.exec(e))?k9(t[1],t[2]/100,t[3]/100,1):(t=I_e.exec(e))?k9(t[1],t[2]/100,t[3]/100,t[4]):b9.hasOwnProperty(e)?T9(b9[e]):e==="transparent"?new Yo(NaN,NaN,NaN,0):null}function T9(e){return new Yo(e>>16&255,e>>8&255,e&255,1)}function Eb(e,t,n,r){return r<=0&&(e=t=n=NaN),new Yo(e,t,n,r)}function C_e(e){return e instanceof Uv||(e=yg(e)),e?(e=e.rgb(),new Yo(e.r,e.g,e.b,e.opacity)):new Yo}function _C(e,t,n,r){return arguments.length===1?C_e(e):new Yo(e,t,n,r??1)}function Yo(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}YA(Yo,_C,PV(Uv,{brighter(e){return e=e==null?Iw:Math.pow(Iw,e),new Yo(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?gg:Math.pow(gg,e),new Yo(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Yo(ju(this.r),ju(this.g),ju(this.b),kw(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:x9,formatHex:x9,formatHex8:M_e,formatRgb:I9,toString:I9}));function x9(){return`#${Iu(this.r)}${Iu(this.g)}${Iu(this.b)}`}function M_e(){return`#${Iu(this.r)}${Iu(this.g)}${Iu(this.b)}${Iu((isNaN(this.opacity)?1:this.opacity)*255)}`}function I9(){const e=kw(this.opacity);return`${e===1?"rgb(":"rgba("}${ju(this.r)}, ${ju(this.g)}, ${ju(this.b)}${e===1?")":`, ${e})`}`}function kw(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function ju(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Iu(e){return e=ju(e),(e<16?"0":"")+e.toString(16)}function k9(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new ha(e,t,n,r)}function jV(e){if(e instanceof ha)return new ha(e.h,e.s,e.l,e.opacity);if(e instanceof Uv||(e=yg(e)),!e)return new ha;if(e instanceof ha)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,o=Math.min(t,n,r),i=Math.max(t,n,r),a=NaN,s=i-o,l=(i+o)/2;return s?(t===i?a=(n-r)/s+(n<r)*6:n===i?a=(r-t)/s+2:a=(t-n)/s+4,s/=l<.5?i+o:2-i-o,a*=60):s=l>0&&l<1?0:a,new ha(a,s,l,e.opacity)}function D_e(e,t,n,r){return arguments.length===1?jV(e):new ha(e,t,n,r??1)}function ha(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}YA(ha,D_e,PV(Uv,{brighter(e){return e=e==null?Iw:Math.pow(Iw,e),new ha(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?gg:Math.pow(gg,e),new ha(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,o=2*n-r;return new Yo(wk(e>=240?e-240:e+120,o,r),wk(e,o,r),wk(e<120?e+240:e-120,o,r),this.opacity)},clamp(){return new ha(E9(this.h),Cb(this.s),Cb(this.l),kw(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=kw(this.opacity);return`${e===1?"hsl(":"hsla("}${E9(this.h)}, ${Cb(this.s)*100}%, ${Cb(this.l)*100}%${e===1?")":`, ${e})`}`}}));function E9(e){return e=(e||0)%360,e<0?e+360:e}function Cb(e){return Math.max(0,Math.min(1,e||0))}function wk(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const UA=e=>()=>e;function A_e(e,t){return function(n){return e+n*t}}function N_e(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function O_e(e){return(e=+e)==1?LV:function(t,n){return n-t?N_e(t,n,e):UA(isNaN(t)?n:t)}}function LV(e,t){var n=t-e;return n?A_e(e,n):UA(isNaN(e)?t:e)}const C9=function e(t){var n=O_e(t);function r(o,i){var a=n((o=_C(o)).r,(i=_C(i)).r),s=n(o.g,i.g),l=n(o.b,i.b),u=LV(o.opacity,i.opacity);return function(d){return o.r=a(d),o.g=s(d),o.b=l(d),o.opacity=u(d),o+""}}return r.gamma=e,r}(1);function P_e(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),o;return function(i){for(o=0;o<n;++o)r[o]=e[o]*(1-i)+t[o]*i;return r}}function j_e(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function L_e(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,o=new Array(r),i=new Array(n),a;for(a=0;a<r;++a)o[a]=Vh(e[a],t[a]);for(;a<n;++a)i[a]=t[a];return function(s){for(a=0;a<r;++a)i[a]=o[a](s);return i}}function R_e(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function Ew(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function F_e(e,t){var n={},r={},o;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(o in t)o in e?n[o]=Vh(e[o],t[o]):r[o]=t[o];return function(i){for(o in n)r[o]=n[o](i);return r}}var BC=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Sk=new RegExp(BC.source,"g");function H_e(e){return function(){return e}}function __e(e){return function(t){return e(t)+""}}function B_e(e,t){var n=BC.lastIndex=Sk.lastIndex=0,r,o,i,a=-1,s=[],l=[];for(e+="",t+="";(r=BC.exec(e))&&(o=Sk.exec(t));)(i=o.index)>n&&(i=t.slice(n,i),s[a]?s[a]+=i:s[++a]=i),(r=r[0])===(o=o[0])?s[a]?s[a]+=o:s[++a]=o:(s[++a]=null,l.push({i:a,x:Ew(r,o)})),n=Sk.lastIndex;return n<t.length&&(i=t.slice(n),s[a]?s[a]+=i:s[++a]=i),s.length<2?l[0]?__e(l[0].x):H_e(t):(t=l.length,function(u){for(var d=0,h;d<t;++d)s[(h=l[d]).i]=h.x(u);return s.join("")})}function Vh(e,t){var n=typeof t,r;return t==null||n==="boolean"?UA(t):(n==="number"?Ew:n==="string"?(r=yg(t))?(t=r,C9):B_e:t instanceof yg?C9:t instanceof Date?R_e:j_e(t)?P_e:Array.isArray(t)?L_e:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?F_e:Ew)(e,t)}function zA(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function Y_e(e,t){t===void 0&&(t=e,e=Vh);for(var n=0,r=t.length-1,o=t[0],i=new Array(r<0?0:r);n<r;)i[n]=e(o,o=t[++n]);return function(a){var s=Math.max(0,Math.min(r-1,Math.floor(a*=r)));return i[s](a-s)}}function U_e(e){return function(){return e}}function Cw(e){return+e}var M9=[0,1];function go(e){return e}function YC(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:U_e(isNaN(t)?NaN:.5)}function z_e(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function V_e(e,t,n){var r=e[0],o=e[1],i=t[0],a=t[1];return o<r?(r=YC(o,r),i=n(a,i)):(r=YC(r,o),i=n(i,a)),function(s){return i(r(s))}}function W_e(e,t,n){var r=Math.min(e.length,t.length)-1,o=new Array(r),i=new Array(r),a=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++a<r;)o[a]=YC(e[a],e[a+1]),i[a]=n(t[a],t[a+1]);return function(s){var l=Yv(e,s,1,r)-1;return i[l](o[l](s))}}function zv(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function jT(){var e=M9,t=M9,n=Vh,r,o,i,a=go,s,l,u;function d(){var p=Math.min(e.length,t.length);return a!==go&&(a=z_e(e[0],e[p-1])),s=p>2?W_e:V_e,l=u=null,h}function h(p){return p==null||isNaN(p=+p)?i:(l||(l=s(e.map(r),t,n)))(r(a(p)))}return h.invert=function(p){return a(o((u||(u=s(t,e.map(r),Ew)))(p)))},h.domain=function(p){return arguments.length?(e=Array.from(p,Cw),d()):e.slice()},h.range=function(p){return arguments.length?(t=Array.from(p),d()):t.slice()},h.rangeRound=function(p){return t=Array.from(p),n=zA,d()},h.clamp=function(p){return arguments.length?(a=p?!0:go,d()):a!==go},h.interpolate=function(p){return arguments.length?(n=p,d()):n},h.unknown=function(p){return arguments.length?(i=p,h):i},function(p,m){return r=p,o=m,d()}}function VA(){return jT()(go,go)}function G_e(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Mw(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function Wf(e){return e=Mw(Math.abs(e)),e?e[1]:NaN}function Z_e(e,t){return function(n,r){for(var o=n.length,i=[],a=0,s=e[0],l=0;o>0&&s>0&&(l+s+1>r&&(s=Math.max(1,r-l)),i.push(n.substring(o-=s,o+s)),!((l+=s+1)>r));)s=e[a=(a+1)%e.length];return i.reverse().join(t)}}function $_e(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var q_e=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function bg(e){if(!(t=q_e.exec(e)))throw new Error("invalid format: "+e);var t;return new WA({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}bg.prototype=WA.prototype;function WA(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}WA.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function K_e(e){e:for(var t=e.length,n=1,r=-1,o;n<t;++n)switch(e[n]){case".":r=o=n;break;case"0":r===0&&(r=n),o=n;break;default:if(!+e[n])break e;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(o+1):e}var RV;function X_e(e,t){var n=Mw(e,t);if(!n)return e+"";var r=n[0],o=n[1],i=o-(RV=Math.max(-8,Math.min(8,Math.floor(o/3)))*3)+1,a=r.length;return i===a?r:i>a?r+new Array(i-a+1).join("0"):i>0?r.slice(0,i)+"."+r.slice(i):"0."+new Array(1-i).join("0")+Mw(e,Math.max(0,t+i-1))[0]}function D9(e,t){var n=Mw(e,t);if(!n)return e+"";var r=n[0],o=n[1];return o<0?"0."+new Array(-o).join("0")+r:r.length>o+1?r.slice(0,o+1)+"."+r.slice(o+1):r+new Array(o-r.length+2).join("0")}const A9={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:G_e,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>D9(e*100,t),r:D9,s:X_e,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function N9(e){return e}var O9=Array.prototype.map,P9=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function J_e(e){var t=e.grouping===void 0||e.thousands===void 0?N9:Z_e(O9.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",o=e.decimal===void 0?".":e.decimal+"",i=e.numerals===void 0?N9:$_e(O9.call(e.numerals,String)),a=e.percent===void 0?"%":e.percent+"",s=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function u(h){h=bg(h);var p=h.fill,m=h.align,b=h.sign,v=h.symbol,y=h.zero,S=h.width,x=h.comma,C=h.precision,k=h.trim,M=h.type;M==="n"?(x=!0,M="g"):A9[M]||(C===void 0&&(C=12),k=!0,M="g"),(y||p==="0"&&m==="=")&&(y=!0,p="0",m="=");var I=v==="$"?n:v==="#"&&/[boxX]/.test(M)?"0"+M.toLowerCase():"",O=v==="$"?r:/[%p]/.test(M)?a:"",R=A9[M],L=/[defgprs%]/.test(M);C=C===void 0?6:/[gprs]/.test(M)?Math.max(1,Math.min(21,C)):Math.max(0,Math.min(20,C));function B(_){var H=I,U=O,G,K,z;if(M==="c")U=R(_)+U,_="";else{_=+_;var ne=_<0||1/_<0;if(_=isNaN(_)?l:R(Math.abs(_),C),k&&(_=K_e(_)),ne&&+_==0&&b!=="+"&&(ne=!1),H=(ne?b==="("?b:s:b==="-"||b==="("?"":b)+H,U=(M==="s"?P9[8+RV/3]:"")+U+(ne&&b==="("?")":""),L){for(G=-1,K=_.length;++G<K;)if(z=_.charCodeAt(G),48>z||z>57){U=(z===46?o+_.slice(G+1):_.slice(G))+U,_=_.slice(0,G);break}}}x&&!y&&(_=t(_,1/0));var J=H.length+_.length+U.length,ee=J<S?new Array(S-J+1).join(p):"";switch(x&&y&&(_=t(ee+_,ee.length?S-U.length:1/0),ee=""),m){case"<":_=H+_+U+ee;break;case"=":_=H+ee+_+U;break;case"^":_=ee.slice(0,J=ee.length>>1)+H+_+U+ee.slice(J);break;default:_=ee+H+_+U;break}return i(_)}return B.toString=function(){return h+""},B}function d(h,p){var m=u((h=bg(h),h.type="f",h)),b=Math.max(-8,Math.min(8,Math.floor(Wf(p)/3)))*3,v=Math.pow(10,-b),y=P9[8+b/3];return function(S){return m(v*S)+y}}return{format:u,formatPrefix:d}}var Mb,GA,FV;Q_e({thousands:",",grouping:[3],currency:["$",""]});function Q_e(e){return Mb=J_e(e),GA=Mb.format,FV=Mb.formatPrefix,Mb}function eBe(e){return Math.max(0,-Wf(Math.abs(e)))}function tBe(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Wf(t)/3)))*3-Wf(Math.abs(e)))}function nBe(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Wf(t)-Wf(e))+1}function HV(e,t,n,r){var o=FC(e,t,n),i;switch(r=bg(r??",f"),r.type){case"s":var a=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(i=tBe(o,a))&&(r.precision=i),FV(r,a);case"":case"e":case"g":case"p":case"r":r.precision==null&&!isNaN(i=nBe(o,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=i-(r.type==="e"));break;case"f":case"%":r.precision==null&&!isNaN(i=eBe(o))&&(r.precision=i-(r.type==="%")*2);break}return GA(r)}function Ac(e){var t=e.domain;return e.ticks=function(n){var r=t();return LC(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var o=t();return HV(o[0],o[o.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),o=0,i=r.length-1,a=r[o],s=r[i],l,u,d=10;for(s<a&&(u=a,a=s,s=u,u=o,o=i,i=u);d-- >0;){if(u=RC(a,s,n),u===l)return r[o]=a,r[i]=s,t(r);if(u>0)a=Math.floor(a/u)*u,s=Math.ceil(s/u)*u;else if(u<0)a=Math.ceil(a*u)/u,s=Math.floor(s*u)/u;else break;l=u}return e},e}function Dw(){var e=VA();return e.copy=function(){return zv(e,Dw())},Gi.apply(e,arguments),Ac(e)}function _V(e){var t;function n(r){return r==null||isNaN(r=+r)?t:r}return n.invert=n,n.domain=n.range=function(r){return arguments.length?(e=Array.from(r,Cw),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return _V(e).unknown(t)},e=arguments.length?Array.from(e,Cw):[0,1],Ac(n)}function BV(e,t){e=e.slice();var n=0,r=e.length-1,o=e[n],i=e[r],a;return i<o&&(a=n,n=r,r=a,a=o,o=i,i=a),e[n]=t.floor(o),e[r]=t.ceil(i),e}function j9(e){return Math.log(e)}function L9(e){return Math.exp(e)}function rBe(e){return-Math.log(-e)}function oBe(e){return-Math.exp(-e)}function iBe(e){return isFinite(e)?+("1e"+e):e<0?0:e}function aBe(e){return e===10?iBe:e===Math.E?Math.exp:t=>Math.pow(e,t)}function sBe(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function R9(e){return(t,n)=>-e(-t,n)}function ZA(e){const t=e(j9,L9),n=t.domain;let r=10,o,i;function a(){return o=sBe(r),i=aBe(r),n()[0]<0?(o=R9(o),i=R9(i),e(rBe,oBe)):e(j9,L9),t}return t.base=function(s){return arguments.length?(r=+s,a()):r},t.domain=function(s){return arguments.length?(n(s),a()):n()},t.ticks=s=>{const l=n();let u=l[0],d=l[l.length-1];const h=d<u;h&&([u,d]=[d,u]);let p=o(u),m=o(d),b,v;const y=s==null?10:+s;let S=[];if(!(r%1)&&m-p<y){if(p=Math.floor(p),m=Math.ceil(m),u>0){for(;p<=m;++p)for(b=1;b<r;++b)if(v=p<0?b/i(-p):b*i(p),!(v<u)){if(v>d)break;S.push(v)}}else for(;p<=m;++p)for(b=r-1;b>=1;--b)if(v=p>0?b/i(-p):b*i(p),!(v<u)){if(v>d)break;S.push(v)}S.length*2<y&&(S=LC(u,d,y))}else S=LC(p,m,Math.min(m-p,y)).map(i);return h?S.reverse():S},t.tickFormat=(s,l)=>{if(s==null&&(s=10),l==null&&(l=r===10?"s":","),typeof l!="function"&&(!(r%1)&&(l=bg(l)).precision==null&&(l.trim=!0),l=GA(l)),s===1/0)return l;const u=Math.max(1,r*s/t.ticks().length);return d=>{let h=d/i(Math.round(o(d)));return h*r<r-.5&&(h*=r),h<=u?l(d):""}},t.nice=()=>n(BV(n(),{floor:s=>i(Math.floor(o(s))),ceil:s=>i(Math.ceil(o(s)))})),t}function YV(){const e=ZA(jT()).domain([1,10]);return e.copy=()=>zv(e,YV()).base(e.base()),Gi.apply(e,arguments),e}function F9(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function H9(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function $A(e){var t=1,n=e(F9(t),H9(t));return n.constant=function(r){return arguments.length?e(F9(t=+r),H9(t)):t},Ac(n)}function UV(){var e=$A(jT());return e.copy=function(){return zv(e,UV()).constant(e.constant())},Gi.apply(e,arguments)}function _9(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function lBe(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function cBe(e){return e<0?-e*e:e*e}function qA(e){var t=e(go,go),n=1;function r(){return n===1?e(go,go):n===.5?e(lBe,cBe):e(_9(n),_9(1/n))}return t.exponent=function(o){return arguments.length?(n=+o,r()):n},Ac(t)}function KA(){var e=qA(jT());return e.copy=function(){return zv(e,KA()).exponent(e.exponent())},Gi.apply(e,arguments),e}function uBe(){return KA.apply(null,arguments).exponent(.5)}function B9(e){return Math.sign(e)*e*e}function dBe(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function zV(){var e=VA(),t=[0,1],n=!1,r;function o(i){var a=dBe(e(i));return isNaN(a)?r:n?Math.round(a):a}return o.invert=function(i){return e.invert(B9(i))},o.domain=function(i){return arguments.length?(e.domain(i),o):e.domain()},o.range=function(i){return arguments.length?(e.range((t=Array.from(i,Cw)).map(B9)),o):t.slice()},o.rangeRound=function(i){return o.range(i).round(!0)},o.round=function(i){return arguments.length?(n=!!i,o):n},o.clamp=function(i){return arguments.length?(e.clamp(i),o):e.clamp()},o.unknown=function(i){return arguments.length?(r=i,o):r},o.copy=function(){return zV(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},Gi.apply(o,arguments),Ac(o)}function VV(){var e=[],t=[],n=[],r;function o(){var a=0,s=Math.max(1,t.length);for(n=new Array(s-1);++a<s;)n[a-1]=g_e(e,a/s);return i}function i(a){return a==null||isNaN(a=+a)?r:t[Yv(n,a)]}return i.invertExtent=function(a){var s=t.indexOf(a);return s<0?[NaN,NaN]:[s>0?n[s-1]:e[0],s<n.length?n[s]:e[e.length-1]]},i.domain=function(a){if(!arguments.length)return e.slice();e=[];for(let s of a)s!=null&&!isNaN(s=+s)&&e.push(s);return e.sort(yc),o()},i.range=function(a){return arguments.length?(t=Array.from(a),o()):t.slice()},i.unknown=function(a){return arguments.length?(r=a,i):r},i.quantiles=function(){return n.slice()},i.copy=function(){return VV().domain(e).range(t).unknown(r)},Gi.apply(i,arguments)}function WV(){var e=0,t=1,n=1,r=[.5],o=[0,1],i;function a(l){return l!=null&&l<=l?o[Yv(r,l,0,n)]:i}function s(){var l=-1;for(r=new Array(n);++l<n;)r[l]=((l+1)*t-(l-n)*e)/(n+1);return a}return a.domain=function(l){return arguments.length?([e,t]=l,e=+e,t=+t,s()):[e,t]},a.range=function(l){return arguments.length?(n=(o=Array.from(l)).length-1,s()):o.slice()},a.invertExtent=function(l){var u=o.indexOf(l);return u<0?[NaN,NaN]:u<1?[e,r[0]]:u>=n?[r[n-1],t]:[r[u-1],r[u]]},a.unknown=function(l){return arguments.length&&(i=l),a},a.thresholds=function(){return r.slice()},a.copy=function(){return WV().domain([e,t]).range(o).unknown(i)},Gi.apply(Ac(a),arguments)}function GV(){var e=[.5],t=[0,1],n,r=1;function o(i){return i!=null&&i<=i?t[Yv(e,i,0,r)]:n}return o.domain=function(i){return arguments.length?(e=Array.from(i),r=Math.min(e.length,t.length-1),o):e.slice()},o.range=function(i){return arguments.length?(t=Array.from(i),r=Math.min(e.length,t.length-1),o):t.slice()},o.invertExtent=function(i){var a=t.indexOf(i);return[e[a-1],e[a]]},o.unknown=function(i){return arguments.length?(n=i,o):n},o.copy=function(){return GV().domain(e).range(t).unknown(n)},Gi.apply(o,arguments)}const Tk=new Date,xk=new Date;function mr(e,t,n,r){function o(i){return e(i=arguments.length===0?new Date:new Date(+i)),i}return o.floor=i=>(e(i=new Date(+i)),i),o.ceil=i=>(e(i=new Date(i-1)),t(i,1),e(i),i),o.round=i=>{const a=o(i),s=o.ceil(i);return i-a<s-i?a:s},o.offset=(i,a)=>(t(i=new Date(+i),a==null?1:Math.floor(a)),i),o.range=(i,a,s)=>{const l=[];if(i=o.ceil(i),s=s==null?1:Math.floor(s),!(i<a)||!(s>0))return l;let u;do l.push(u=new Date(+i)),t(i,s),e(i);while(u<i&&i<a);return l},o.filter=i=>mr(a=>{if(a>=a)for(;e(a),!i(a);)a.setTime(a-1)},(a,s)=>{if(a>=a)if(s<0)for(;++s<=0;)for(;t(a,-1),!i(a););else for(;--s>=0;)for(;t(a,1),!i(a););}),n&&(o.count=(i,a)=>(Tk.setTime(+i),xk.setTime(+a),e(Tk),e(xk),Math.floor(n(Tk,xk))),o.every=i=>(i=Math.floor(i),!isFinite(i)||!(i>0)?null:i>1?o.filter(r?a=>r(a)%i===0:a=>o.count(0,a)%i===0):o)),o}const Aw=mr(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Aw.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?mr(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):Aw);Aw.range;const el=1e3,Pi=el*60,tl=Pi*60,bl=tl*24,XA=bl*7,Y9=bl*30,Ik=bl*365,ku=mr(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*el)},(e,t)=>(t-e)/el,e=>e.getUTCSeconds());ku.range;const JA=mr(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*el)},(e,t)=>{e.setTime(+e+t*Pi)},(e,t)=>(t-e)/Pi,e=>e.getMinutes());JA.range;const QA=mr(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Pi)},(e,t)=>(t-e)/Pi,e=>e.getUTCMinutes());QA.range;const eN=mr(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*el-e.getMinutes()*Pi)},(e,t)=>{e.setTime(+e+t*tl)},(e,t)=>(t-e)/tl,e=>e.getHours());eN.range;const tN=mr(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*tl)},(e,t)=>(t-e)/tl,e=>e.getUTCHours());tN.range;const Vv=mr(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Pi)/bl,e=>e.getDate()-1);Vv.range;const LT=mr(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/bl,e=>e.getUTCDate()-1);LT.range;const ZV=mr(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/bl,e=>Math.floor(e/bl));ZV.range;function ad(e){return mr(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*Pi)/XA)}const RT=ad(0),Nw=ad(1),fBe=ad(2),hBe=ad(3),Gf=ad(4),pBe=ad(5),mBe=ad(6);RT.range;Nw.range;fBe.range;hBe.range;Gf.range;pBe.range;mBe.range;function sd(e){return mr(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/XA)}const FT=sd(0),Ow=sd(1),gBe=sd(2),vBe=sd(3),Zf=sd(4),yBe=sd(5),bBe=sd(6);FT.range;Ow.range;gBe.range;vBe.range;Zf.range;yBe.range;bBe.range;const nN=mr(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());nN.range;const rN=mr(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());rN.range;const wl=mr(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());wl.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:mr(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)});wl.range;const Sl=mr(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());Sl.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:mr(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)});Sl.range;function $V(e,t,n,r,o,i){const a=[[ku,1,el],[ku,5,5*el],[ku,15,15*el],[ku,30,30*el],[i,1,Pi],[i,5,5*Pi],[i,15,15*Pi],[i,30,30*Pi],[o,1,tl],[o,3,3*tl],[o,6,6*tl],[o,12,12*tl],[r,1,bl],[r,2,2*bl],[n,1,XA],[t,1,Y9],[t,3,3*Y9],[e,1,Ik]];function s(u,d,h){const p=d<u;p&&([u,d]=[d,u]);const m=h&&typeof h.range=="function"?h:l(u,d,h),b=m?m.range(u,+d+1):[];return p?b.reverse():b}function l(u,d,h){const p=Math.abs(d-u)/h,m=_A(([,,y])=>y).right(a,p);if(m===a.length)return e.every(FC(u/Ik,d/Ik,h));if(m===0)return Aw.every(Math.max(FC(u,d,h),1));const[b,v]=a[p/a[m-1][2]<a[m][2]/p?m-1:m];return b.every(v)}return[s,l]}const[wBe,SBe]=$V(Sl,rN,FT,ZV,tN,QA),[TBe,xBe]=$V(wl,nN,RT,Vv,eN,JA);function kk(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function Ek(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function zp(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function IBe(e){var t=e.dateTime,n=e.date,r=e.time,o=e.periods,i=e.days,a=e.shortDays,s=e.months,l=e.shortMonths,u=Vp(o),d=Wp(o),h=Vp(i),p=Wp(i),m=Vp(a),b=Wp(a),v=Vp(s),y=Wp(s),S=Vp(l),x=Wp(l),C={a:ne,A:J,b:ee,B:Z,c:null,d:Z9,e:Z9,f:ZBe,g:rYe,G:iYe,H:VBe,I:WBe,j:GBe,L:qV,m:$Be,M:qBe,p:q,q:$,Q:K9,s:X9,S:KBe,u:XBe,U:JBe,V:QBe,w:eYe,W:tYe,x:null,X:null,y:nYe,Y:oYe,Z:aYe,"%":q9},k={a:re,A:le,b:ie,B:fe,c:null,d:$9,e:$9,f:uYe,g:wYe,G:TYe,H:sYe,I:lYe,j:cYe,L:XV,m:dYe,M:fYe,p:ye,q:ge,Q:K9,s:X9,S:hYe,u:pYe,U:mYe,V:gYe,w:vYe,W:yYe,x:null,X:null,y:bYe,Y:SYe,Z:xYe,"%":q9},M={a:B,A:_,b:H,B:U,c:G,d:W9,e:W9,f:BBe,g:V9,G:z9,H:G9,I:G9,j:RBe,L:_Be,m:LBe,M:FBe,p:L,q:jBe,Q:UBe,s:zBe,S:HBe,u:DBe,U:ABe,V:NBe,w:MBe,W:OBe,x:K,X:z,y:V9,Y:z9,Z:PBe,"%":YBe};C.x=I(n,C),C.X=I(r,C),C.c=I(t,C),k.x=I(n,k),k.X=I(r,k),k.c=I(t,k);function I(me,Ce){return function(je){var Ie=[],Fe=-1,ce=0,Ne=me.length,Pe,_e,qe;for(je instanceof Date||(je=new Date(+je));++Fe<Ne;)me.charCodeAt(Fe)===37&&(Ie.push(me.slice(ce,Fe)),(_e=U9[Pe=me.charAt(++Fe)])!=null?Pe=me.charAt(++Fe):_e=Pe==="e"?" ":"0",(qe=Ce[Pe])&&(Pe=qe(je,_e)),Ie.push(Pe),ce=Fe+1);return Ie.push(me.slice(ce,Fe)),Ie.join("")}}function O(me,Ce){return function(je){var Ie=zp(1900,void 0,1),Fe=R(Ie,me,je+="",0),ce,Ne;if(Fe!=je.length)return null;if("Q"in Ie)return new Date(Ie.Q);if("s"in Ie)return new Date(Ie.s*1e3+("L"in Ie?Ie.L:0));if(Ce&&!("Z"in Ie)&&(Ie.Z=0),"p"in Ie&&(Ie.H=Ie.H%12+Ie.p*12),Ie.m===void 0&&(Ie.m="q"in Ie?Ie.q:0),"V"in Ie){if(Ie.V<1||Ie.V>53)return null;"w"in Ie||(Ie.w=1),"Z"in Ie?(ce=Ek(zp(Ie.y,0,1)),Ne=ce.getUTCDay(),ce=Ne>4||Ne===0?Ow.ceil(ce):Ow(ce),ce=LT.offset(ce,(Ie.V-1)*7),Ie.y=ce.getUTCFullYear(),Ie.m=ce.getUTCMonth(),Ie.d=ce.getUTCDate()+(Ie.w+6)%7):(ce=kk(zp(Ie.y,0,1)),Ne=ce.getDay(),ce=Ne>4||Ne===0?Nw.ceil(ce):Nw(ce),ce=Vv.offset(ce,(Ie.V-1)*7),Ie.y=ce.getFullYear(),Ie.m=ce.getMonth(),Ie.d=ce.getDate()+(Ie.w+6)%7)}else("W"in Ie||"U"in Ie)&&("w"in Ie||(Ie.w="u"in Ie?Ie.u%7:"W"in Ie?1:0),Ne="Z"in Ie?Ek(zp(Ie.y,0,1)).getUTCDay():kk(zp(Ie.y,0,1)).getDay(),Ie.m=0,Ie.d="W"in Ie?(Ie.w+6)%7+Ie.W*7-(Ne+5)%7:Ie.w+Ie.U*7-(Ne+6)%7);return"Z"in Ie?(Ie.H+=Ie.Z/100|0,Ie.M+=Ie.Z%100,Ek(Ie)):kk(Ie)}}function R(me,Ce,je,Ie){for(var Fe=0,ce=Ce.length,Ne=je.length,Pe,_e;Fe<ce;){if(Ie>=Ne)return-1;if(Pe=Ce.charCodeAt(Fe++),Pe===37){if(Pe=Ce.charAt(Fe++),_e=M[Pe in U9?Ce.charAt(Fe++):Pe],!_e||(Ie=_e(me,je,Ie))<0)return-1}else if(Pe!=je.charCodeAt(Ie++))return-1}return Ie}function L(me,Ce,je){var Ie=u.exec(Ce.slice(je));return Ie?(me.p=d.get(Ie[0].toLowerCase()),je+Ie[0].length):-1}function B(me,Ce,je){var Ie=m.exec(Ce.slice(je));return Ie?(me.w=b.get(Ie[0].toLowerCase()),je+Ie[0].length):-1}function _(me,Ce,je){var Ie=h.exec(Ce.slice(je));return Ie?(me.w=p.get(Ie[0].toLowerCase()),je+Ie[0].length):-1}function H(me,Ce,je){var Ie=S.exec(Ce.slice(je));return Ie?(me.m=x.get(Ie[0].toLowerCase()),je+Ie[0].length):-1}function U(me,Ce,je){var Ie=v.exec(Ce.slice(je));return Ie?(me.m=y.get(Ie[0].toLowerCase()),je+Ie[0].length):-1}function G(me,Ce,je){return R(me,t,Ce,je)}function K(me,Ce,je){return R(me,n,Ce,je)}function z(me,Ce,je){return R(me,r,Ce,je)}function ne(me){return a[me.getDay()]}function J(me){return i[me.getDay()]}function ee(me){return l[me.getMonth()]}function Z(me){return s[me.getMonth()]}function q(me){return o[+(me.getHours()>=12)]}function $(me){return 1+~~(me.getMonth()/3)}function re(me){return a[me.getUTCDay()]}function le(me){return i[me.getUTCDay()]}function ie(me){return l[me.getUTCMonth()]}function fe(me){return s[me.getUTCMonth()]}function ye(me){return o[+(me.getUTCHours()>=12)]}function ge(me){return 1+~~(me.getUTCMonth()/3)}return{format:function(me){var Ce=I(me+="",C);return Ce.toString=function(){return me},Ce},parse:function(me){var Ce=O(me+="",!1);return Ce.toString=function(){return me},Ce},utcFormat:function(me){var Ce=I(me+="",k);return Ce.toString=function(){return me},Ce},utcParse:function(me){var Ce=O(me+="",!0);return Ce.toString=function(){return me},Ce}}}var U9={"-":"",_:" ",0:"0"},Cr=/^\s*\d+/,kBe=/^%/,EBe=/[\\^$*+?|[\]().{}]/g;function qt(e,t,n){var r=e<0?"-":"",o=(r?-e:e)+"",i=o.length;return r+(i<n?new Array(n-i+1).join(t)+o:o)}function CBe(e){return e.replace(EBe,"\\$&")}function Vp(e){return new RegExp("^(?:"+e.map(CBe).join("|")+")","i")}function Wp(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function MBe(e,t,n){var r=Cr.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function DBe(e,t,n){var r=Cr.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function ABe(e,t,n){var r=Cr.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function NBe(e,t,n){var r=Cr.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function OBe(e,t,n){var r=Cr.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function z9(e,t,n){var r=Cr.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function V9(e,t,n){var r=Cr.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function PBe(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function jBe(e,t,n){var r=Cr.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function LBe(e,t,n){var r=Cr.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function W9(e,t,n){var r=Cr.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function RBe(e,t,n){var r=Cr.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function G9(e,t,n){var r=Cr.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function FBe(e,t,n){var r=Cr.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function HBe(e,t,n){var r=Cr.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function _Be(e,t,n){var r=Cr.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function BBe(e,t,n){var r=Cr.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function YBe(e,t,n){var r=kBe.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function UBe(e,t,n){var r=Cr.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function zBe(e,t,n){var r=Cr.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function Z9(e,t){return qt(e.getDate(),t,2)}function VBe(e,t){return qt(e.getHours(),t,2)}function WBe(e,t){return qt(e.getHours()%12||12,t,2)}function GBe(e,t){return qt(1+Vv.count(wl(e),e),t,3)}function qV(e,t){return qt(e.getMilliseconds(),t,3)}function ZBe(e,t){return qV(e,t)+"000"}function $Be(e,t){return qt(e.getMonth()+1,t,2)}function qBe(e,t){return qt(e.getMinutes(),t,2)}function KBe(e,t){return qt(e.getSeconds(),t,2)}function XBe(e){var t=e.getDay();return t===0?7:t}function JBe(e,t){return qt(RT.count(wl(e)-1,e),t,2)}function KV(e){var t=e.getDay();return t>=4||t===0?Gf(e):Gf.ceil(e)}function QBe(e,t){return e=KV(e),qt(Gf.count(wl(e),e)+(wl(e).getDay()===4),t,2)}function eYe(e){return e.getDay()}function tYe(e,t){return qt(Nw.count(wl(e)-1,e),t,2)}function nYe(e,t){return qt(e.getFullYear()%100,t,2)}function rYe(e,t){return e=KV(e),qt(e.getFullYear()%100,t,2)}function oYe(e,t){return qt(e.getFullYear()%1e4,t,4)}function iYe(e,t){var n=e.getDay();return e=n>=4||n===0?Gf(e):Gf.ceil(e),qt(e.getFullYear()%1e4,t,4)}function aYe(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+qt(t/60|0,"0",2)+qt(t%60,"0",2)}function $9(e,t){return qt(e.getUTCDate(),t,2)}function sYe(e,t){return qt(e.getUTCHours(),t,2)}function lYe(e,t){return qt(e.getUTCHours()%12||12,t,2)}function cYe(e,t){return qt(1+LT.count(Sl(e),e),t,3)}function XV(e,t){return qt(e.getUTCMilliseconds(),t,3)}function uYe(e,t){return XV(e,t)+"000"}function dYe(e,t){return qt(e.getUTCMonth()+1,t,2)}function fYe(e,t){return qt(e.getUTCMinutes(),t,2)}function hYe(e,t){return qt(e.getUTCSeconds(),t,2)}function pYe(e){var t=e.getUTCDay();return t===0?7:t}function mYe(e,t){return qt(FT.count(Sl(e)-1,e),t,2)}function JV(e){var t=e.getUTCDay();return t>=4||t===0?Zf(e):Zf.ceil(e)}function gYe(e,t){return e=JV(e),qt(Zf.count(Sl(e),e)+(Sl(e).getUTCDay()===4),t,2)}function vYe(e){return e.getUTCDay()}function yYe(e,t){return qt(Ow.count(Sl(e)-1,e),t,2)}function bYe(e,t){return qt(e.getUTCFullYear()%100,t,2)}function wYe(e,t){return e=JV(e),qt(e.getUTCFullYear()%100,t,2)}function SYe(e,t){return qt(e.getUTCFullYear()%1e4,t,4)}function TYe(e,t){var n=e.getUTCDay();return e=n>=4||n===0?Zf(e):Zf.ceil(e),qt(e.getUTCFullYear()%1e4,t,4)}function xYe(){return"+0000"}function q9(){return"%"}function K9(e){return+e}function X9(e){return Math.floor(+e/1e3)}var Kd,QV,eW;IYe({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function IYe(e){return Kd=IBe(e),QV=Kd.format,Kd.parse,eW=Kd.utcFormat,Kd.utcParse,Kd}function kYe(e){return new Date(e)}function EYe(e){return e instanceof Date?+e:+new Date(+e)}function oN(e,t,n,r,o,i,a,s,l,u){var d=VA(),h=d.invert,p=d.domain,m=u(".%L"),b=u(":%S"),v=u("%I:%M"),y=u("%I %p"),S=u("%a %d"),x=u("%b %d"),C=u("%B"),k=u("%Y");function M(I){return(l(I)<I?m:s(I)<I?b:a(I)<I?v:i(I)<I?y:r(I)<I?o(I)<I?S:x:n(I)<I?C:k)(I)}return d.invert=function(I){return new Date(h(I))},d.domain=function(I){return arguments.length?p(Array.from(I,EYe)):p().map(kYe)},d.ticks=function(I){var O=p();return e(O[0],O[O.length-1],I??10)},d.tickFormat=function(I,O){return O==null?M:u(O)},d.nice=function(I){var O=p();return(!I||typeof I.range!="function")&&(I=t(O[0],O[O.length-1],I??10)),I?p(BV(O,I)):d},d.copy=function(){return zv(d,oN(e,t,n,r,o,i,a,s,l,u))},d}function CYe(){return Gi.apply(oN(TBe,xBe,wl,nN,RT,Vv,eN,JA,ku,QV).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function MYe(){return Gi.apply(oN(wBe,SBe,Sl,rN,FT,LT,tN,QA,ku,eW).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function HT(){var e=0,t=1,n,r,o,i,a=go,s=!1,l;function u(h){return h==null||isNaN(h=+h)?l:a(o===0?.5:(h=(i(h)-n)*o,s?Math.max(0,Math.min(1,h)):h))}u.domain=function(h){return arguments.length?([e,t]=h,n=i(e=+e),r=i(t=+t),o=n===r?0:1/(r-n),u):[e,t]},u.clamp=function(h){return arguments.length?(s=!!h,u):s},u.interpolator=function(h){return arguments.length?(a=h,u):a};function d(h){return function(p){var m,b;return arguments.length?([m,b]=p,a=h(m,b),u):[a(0),a(1)]}}return u.range=d(Vh),u.rangeRound=d(zA),u.unknown=function(h){return arguments.length?(l=h,u):l},function(h){return i=h,n=h(e),r=h(t),o=n===r?0:1/(r-n),u}}function Nc(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function tW(){var e=Ac(HT()(go));return e.copy=function(){return Nc(e,tW())},Al.apply(e,arguments)}function nW(){var e=ZA(HT()).domain([1,10]);return e.copy=function(){return Nc(e,nW()).base(e.base())},Al.apply(e,arguments)}function rW(){var e=$A(HT());return e.copy=function(){return Nc(e,rW()).constant(e.constant())},Al.apply(e,arguments)}function iN(){var e=qA(HT());return e.copy=function(){return Nc(e,iN()).exponent(e.exponent())},Al.apply(e,arguments)}function DYe(){return iN.apply(null,arguments).exponent(.5)}function oW(){var e=[],t=go;function n(r){if(r!=null&&!isNaN(r=+r))return t((Yv(e,r,1)-1)/(e.length-1))}return n.domain=function(r){if(!arguments.length)return e.slice();e=[];for(let o of r)o!=null&&!isNaN(o=+o)&&e.push(o);return e.sort(yc),n},n.interpolator=function(r){return arguments.length?(t=r,n):t},n.range=function(){return e.map((r,o)=>t(o/(e.length-1)))},n.quantiles=function(r){return Array.from({length:r+1},(o,i)=>m_e(e,i/r))},n.copy=function(){return oW(t).domain(e)},Al.apply(n,arguments)}function _T(){var e=0,t=.5,n=1,r=1,o,i,a,s,l,u=go,d,h=!1,p;function m(v){return isNaN(v=+v)?p:(v=.5+((v=+d(v))-i)*(r*v<r*i?s:l),u(h?Math.max(0,Math.min(1,v)):v))}m.domain=function(v){return arguments.length?([e,t,n]=v,o=d(e=+e),i=d(t=+t),a=d(n=+n),s=o===i?0:.5/(i-o),l=i===a?0:.5/(a-i),r=i<o?-1:1,m):[e,t,n]},m.clamp=function(v){return arguments.length?(h=!!v,m):h},m.interpolator=function(v){return arguments.length?(u=v,m):u};function b(v){return function(y){var S,x,C;return arguments.length?([S,x,C]=y,u=Y_e(v,[S,x,C]),m):[u(0),u(.5),u(1)]}}return m.range=b(Vh),m.rangeRound=b(zA),m.unknown=function(v){return arguments.length?(p=v,m):p},function(v){return d=v,o=v(e),i=v(t),a=v(n),s=o===i?0:.5/(i-o),l=i===a?0:.5/(a-i),r=i<o?-1:1,m}}function iW(){var e=Ac(_T()(go));return e.copy=function(){return Nc(e,iW())},Al.apply(e,arguments)}function aW(){var e=ZA(_T()).domain([.1,1,10]);return e.copy=function(){return Nc(e,aW()).base(e.base())},Al.apply(e,arguments)}function sW(){var e=$A(_T());return e.copy=function(){return Nc(e,sW()).constant(e.constant())},Al.apply(e,arguments)}function aN(){var e=qA(_T());return e.copy=function(){return Nc(e,aN()).exponent(e.exponent())},Al.apply(e,arguments)}function AYe(){return aN.apply(null,arguments).exponent(.5)}const J9=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:mg,scaleDiverging:iW,scaleDivergingLog:aW,scaleDivergingPow:aN,scaleDivergingSqrt:AYe,scaleDivergingSymlog:sW,scaleIdentity:_V,scaleImplicit:HC,scaleLinear:Dw,scaleLog:YV,scaleOrdinal:BA,scalePoint:Em,scalePow:KA,scaleQuantile:VV,scaleQuantize:WV,scaleRadial:zV,scaleSequential:tW,scaleSequentialLog:nW,scaleSequentialPow:iN,scaleSequentialQuantile:oW,scaleSequentialSqrt:DYe,scaleSequentialSymlog:rW,scaleSqrt:uBe,scaleSymlog:UV,scaleThreshold:GV,scaleTime:CYe,scaleUtc:MYe,tickFormat:HV},Symbol.toStringTag,{value:"Module"}));var NYe=Dh;function OYe(e,t,n){for(var r=-1,o=e.length;++r<o;){var i=e[r],a=t(i);if(a!=null&&(s===void 0?a===a&&!NYe(a):n(a,s)))var s=a,l=i}return l}var lW=OYe;function PYe(e,t){return e>t}var jYe=PYe,LYe=lW,RYe=jYe,FYe=Ah;function HYe(e){return e&&e.length?LYe(e,FYe,RYe):void 0}var _Ye=HYe;const BT=tt(_Ye);function BYe(e,t){return e<t}var YYe=BYe,UYe=lW,zYe=YYe,VYe=Ah;function WYe(e){return e&&e.length?UYe(e,VYe,zYe):void 0}var GYe=WYe;const YT=tt(GYe);var ZYe=jS,$Ye=El,qYe=i_,KYe=Hr;function XYe(e,t){var n=KYe(e)?ZYe:qYe;return n(e,$Ye(t))}var JYe=XYe,QYe=jD,eUe=JYe;function tUe(e,t){return QYe(eUe(e,t),1)}var nUe=tUe;const rUe=tt(nUe);var Wh=1e9,oUe={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},lN,On=!0,Ui="[DecimalError] ",Lu=Ui+"Invalid argument: ",sN=Ui+"Exponent out of range: ",Gh=Math.floor,gu=Math.pow,iUe=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,ui,wr=1e7,Mn=7,cW=9007199254740991,Pw=Gh(cW/Mn),rt={};rt.absoluteValue=rt.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e};rt.comparedTo=rt.cmp=function(e){var t,n,r,o,i=this;if(e=new i.constructor(e),i.s!==e.s)return i.s||-e.s;if(i.e!==e.e)return i.e>e.e^i.s<0?1:-1;for(r=i.d.length,o=e.d.length,t=0,n=r<o?r:o;t<n;++t)if(i.d[t]!==e.d[t])return i.d[t]>e.d[t]^i.s<0?1:-1;return r===o?0:r>o^i.s<0?1:-1};rt.decimalPlaces=rt.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*Mn;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n};rt.dividedBy=rt.div=function(e){return fl(this,new this.constructor(e))};rt.dividedToIntegerBy=rt.idiv=function(e){var t=this,n=t.constructor;return mn(fl(t,new n(e),0,1),n.precision)};rt.equals=rt.eq=function(e){return!this.cmp(e)};rt.exponent=function(){return or(this)};rt.greaterThan=rt.gt=function(e){return this.cmp(e)>0};rt.greaterThanOrEqualTo=rt.gte=function(e){return this.cmp(e)>=0};rt.isInteger=rt.isint=function(){return this.e>this.d.length-2};rt.isNegative=rt.isneg=function(){return this.s<0};rt.isPositive=rt.ispos=function(){return this.s>0};rt.isZero=function(){return this.s===0};rt.lessThan=rt.lt=function(e){return this.cmp(e)<0};rt.lessThanOrEqualTo=rt.lte=function(e){return this.cmp(e)<1};rt.logarithm=rt.log=function(e){var t,n=this,r=n.constructor,o=r.precision,i=o+5;if(e===void 0)e=new r(10);else if(e=new r(e),e.s<1||e.eq(ui))throw Error(Ui+"NaN");if(n.s<1)throw Error(Ui+(n.s?"NaN":"-Infinity"));return n.eq(ui)?new r(0):(On=!1,t=fl(wg(n,i),wg(e,i),i),On=!0,mn(t,o))};rt.minus=rt.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?fW(t,e):uW(t,(e.s=-e.s,e))};rt.modulo=rt.mod=function(e){var t,n=this,r=n.constructor,o=r.precision;if(e=new r(e),!e.s)throw Error(Ui+"NaN");return n.s?(On=!1,t=fl(n,e,0,1).times(e),On=!0,n.minus(t)):mn(new r(n),o)};rt.naturalExponential=rt.exp=function(){return dW(this)};rt.naturalLogarithm=rt.ln=function(){return wg(this)};rt.negated=rt.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};rt.plus=rt.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?uW(t,e):fW(t,(e.s=-e.s,e))};rt.precision=rt.sd=function(e){var t,n,r,o=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(Lu+e);if(t=or(o)+1,r=o.d.length-1,n=r*Mn+1,r=o.d[r],r){for(;r%10==0;r/=10)n--;for(r=o.d[0];r>=10;r/=10)n++}return e&&t>n?t:n};rt.squareRoot=rt.sqrt=function(){var e,t,n,r,o,i,a,s=this,l=s.constructor;if(s.s<1){if(!s.s)return new l(0);throw Error(Ui+"NaN")}for(e=or(s),On=!1,o=Math.sqrt(+s),o==0||o==1/0?(t=us(s.d),(t.length+e)%2==0&&(t+="0"),o=Math.sqrt(t),e=Gh((e+1)/2)-(e<0||e%2),o==1/0?t="5e"+e:(t=o.toExponential(),t=t.slice(0,t.indexOf("e")+1)+e),r=new l(t)):r=new l(o.toString()),n=l.precision,o=a=n+3;;)if(i=r,r=i.plus(fl(s,i,a+2)).times(.5),us(i.d).slice(0,a)===(t=us(r.d)).slice(0,a)){if(t=t.slice(a-3,a+1),o==a&&t=="4999"){if(mn(i,n+1,0),i.times(i).eq(s)){r=i;break}}else if(t!="9999")break;a+=4}return On=!0,mn(r,n)};rt.times=rt.mul=function(e){var t,n,r,o,i,a,s,l,u,d=this,h=d.constructor,p=d.d,m=(e=new h(e)).d;if(!d.s||!e.s)return new h(0);for(e.s*=d.s,n=d.e+e.e,l=p.length,u=m.length,l<u&&(i=p,p=m,m=i,a=l,l=u,u=a),i=[],a=l+u,r=a;r--;)i.push(0);for(r=u;--r>=0;){for(t=0,o=l+r;o>r;)s=i[o]+m[r]*p[o-r-1]+t,i[o--]=s%wr|0,t=s/wr|0;i[o]=(i[o]+t)%wr|0}for(;!i[--a];)i.pop();return t?++n:i.shift(),e.d=i,e.e=n,On?mn(e,h.precision):e};rt.toDecimalPlaces=rt.todp=function(e,t){var n=this,r=n.constructor;return n=new r(n),e===void 0?n:(xs(e,0,Wh),t===void 0?t=r.rounding:xs(t,0,8),mn(n,e+or(n)+1,t))};rt.toExponential=function(e,t){var n,r=this,o=r.constructor;return e===void 0?n=$u(r,!0):(xs(e,0,Wh),t===void 0?t=o.rounding:xs(t,0,8),r=mn(new o(r),e+1,t),n=$u(r,!0,e+1)),n};rt.toFixed=function(e,t){var n,r,o=this,i=o.constructor;return e===void 0?$u(o):(xs(e,0,Wh),t===void 0?t=i.rounding:xs(t,0,8),r=mn(new i(o),e+or(o)+1,t),n=$u(r.abs(),!1,e+or(r)+1),o.isneg()&&!o.isZero()?"-"+n:n)};rt.toInteger=rt.toint=function(){var e=this,t=e.constructor;return mn(new t(e),or(e)+1,t.rounding)};rt.toNumber=function(){return+this};rt.toPower=rt.pow=function(e){var t,n,r,o,i,a,s=this,l=s.constructor,u=12,d=+(e=new l(e));if(!e.s)return new l(ui);if(s=new l(s),!s.s){if(e.s<1)throw Error(Ui+"Infinity");return s}if(s.eq(ui))return s;if(r=l.precision,e.eq(ui))return mn(s,r);if(t=e.e,n=e.d.length-1,a=t>=n,i=s.s,a){if((n=d<0?-d:d)<=cW){for(o=new l(ui),t=Math.ceil(r/Mn+4),On=!1;n%2&&(o=o.times(s),eF(o.d,t)),n=Gh(n/2),n!==0;)s=s.times(s),eF(s.d,t);return On=!0,e.s<0?new l(ui).div(o):mn(o,r)}}else if(i<0)throw Error(Ui+"NaN");return i=i<0&&e.d[Math.max(t,n)]&1?-1:1,s.s=1,On=!1,o=e.times(wg(s,r+u)),On=!0,o=dW(o),o.s=i,o};rt.toPrecision=function(e,t){var n,r,o=this,i=o.constructor;return e===void 0?(n=or(o),r=$u(o,n<=i.toExpNeg||n>=i.toExpPos)):(xs(e,1,Wh),t===void 0?t=i.rounding:xs(t,0,8),o=mn(new i(o),e,t),n=or(o),r=$u(o,e<=n||n<=i.toExpNeg,e)),r};rt.toSignificantDigits=rt.tosd=function(e,t){var n=this,r=n.constructor;return e===void 0?(e=r.precision,t=r.rounding):(xs(e,1,Wh),t===void 0?t=r.rounding:xs(t,0,8)),mn(new r(n),e,t)};rt.toString=rt.valueOf=rt.val=rt.toJSON=rt[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=or(e),n=e.constructor;return $u(e,t<=n.toExpNeg||t>=n.toExpPos)};function uW(e,t){var n,r,o,i,a,s,l,u,d=e.constructor,h=d.precision;if(!e.s||!t.s)return t.s||(t=new d(e)),On?mn(t,h):t;if(l=e.d,u=t.d,a=e.e,o=t.e,l=l.slice(),i=a-o,i){for(i<0?(r=l,i=-i,s=u.length):(r=u,o=a,s=l.length),a=Math.ceil(h/Mn),s=a>s?a+1:s+1,i>s&&(i=s,r.length=1),r.reverse();i--;)r.push(0);r.reverse()}for(s=l.length,i=u.length,s-i<0&&(i=s,r=u,u=l,l=r),n=0;i;)n=(l[--i]=l[i]+u[i]+n)/wr|0,l[i]%=wr;for(n&&(l.unshift(n),++o),s=l.length;l[--s]==0;)l.pop();return t.d=l,t.e=o,On?mn(t,h):t}function xs(e,t,n){if(e!==~~e||e<t||e>n)throw Error(Lu+e)}function us(e){var t,n,r,o=e.length-1,i="",a=e[0];if(o>0){for(i+=a,t=1;t<o;t++)r=e[t]+"",n=Mn-r.length,n&&(i+=sc(n)),i+=r;a=e[t],r=a+"",n=Mn-r.length,n&&(i+=sc(n))}else if(a===0)return"0";for(;a%10===0;)a/=10;return i+a}var fl=function(){function e(r,o){var i,a=0,s=r.length;for(r=r.slice();s--;)i=r[s]*o+a,r[s]=i%wr|0,a=i/wr|0;return a&&r.unshift(a),r}function t(r,o,i,a){var s,l;if(i!=a)l=i>a?1:-1;else for(s=l=0;s<i;s++)if(r[s]!=o[s]){l=r[s]>o[s]?1:-1;break}return l}function n(r,o,i){for(var a=0;i--;)r[i]-=a,a=r[i]<o[i]?1:0,r[i]=a*wr+r[i]-o[i];for(;!r[0]&&r.length>1;)r.shift()}return function(r,o,i,a){var s,l,u,d,h,p,m,b,v,y,S,x,C,k,M,I,O,R,L=r.constructor,B=r.s==o.s?1:-1,_=r.d,H=o.d;if(!r.s)return new L(r);if(!o.s)throw Error(Ui+"Division by zero");for(l=r.e-o.e,O=H.length,M=_.length,m=new L(B),b=m.d=[],u=0;H[u]==(_[u]||0);)++u;if(H[u]>(_[u]||0)&&--l,i==null?x=i=L.precision:a?x=i+(or(r)-or(o))+1:x=i,x<0)return new L(0);if(x=x/Mn+2|0,u=0,O==1)for(d=0,H=H[0],x++;(u<M||d)&&x--;u++)C=d*wr+(_[u]||0),b[u]=C/H|0,d=C%H|0;else{for(d=wr/(H[0]+1)|0,d>1&&(H=e(H,d),_=e(_,d),O=H.length,M=_.length),k=O,v=_.slice(0,O),y=v.length;y<O;)v[y++]=0;R=H.slice(),R.unshift(0),I=H[0],H[1]>=wr/2&&++I;do d=0,s=t(H,v,O,y),s<0?(S=v[0],O!=y&&(S=S*wr+(v[1]||0)),d=S/I|0,d>1?(d>=wr&&(d=wr-1),h=e(H,d),p=h.length,y=v.length,s=t(h,v,p,y),s==1&&(d--,n(h,O<p?R:H,p))):(d==0&&(s=d=1),h=H.slice()),p=h.length,p<y&&h.unshift(0),n(v,h,y),s==-1&&(y=v.length,s=t(H,v,O,y),s<1&&(d++,n(v,O<y?R:H,y))),y=v.length):s===0&&(d++,v=[0]),b[u++]=d,s&&v[0]?v[y++]=_[k]||0:(v=[_[k]],y=1);while((k++<M||v[0]!==void 0)&&x--)}return b[0]||b.shift(),m.e=l,mn(m,a?i+or(m)+1:i)}}();function dW(e,t){var n,r,o,i,a,s,l=0,u=0,d=e.constructor,h=d.precision;if(or(e)>16)throw Error(sN+or(e));if(!e.s)return new d(ui);for(t==null?(On=!1,s=h):s=t,a=new d(.03125);e.abs().gte(.1);)e=e.times(a),u+=5;for(r=Math.log(gu(2,u))/Math.LN10*2+5|0,s+=r,n=o=i=new d(ui),d.precision=s;;){if(o=mn(o.times(e),s),n=n.times(++l),a=i.plus(fl(o,n,s)),us(a.d).slice(0,s)===us(i.d).slice(0,s)){for(;u--;)i=mn(i.times(i),s);return d.precision=h,t==null?(On=!0,mn(i,h)):i}i=a}}function or(e){for(var t=e.e*Mn,n=e.d[0];n>=10;n/=10)t++;return t}function Ck(e,t,n){if(t>e.LN10.sd())throw On=!0,n&&(e.precision=n),Error(Ui+"LN10 precision limit exceeded");return mn(new e(e.LN10),t)}function sc(e){for(var t="";e--;)t+="0";return t}function wg(e,t){var n,r,o,i,a,s,l,u,d,h=1,p=10,m=e,b=m.d,v=m.constructor,y=v.precision;if(m.s<1)throw Error(Ui+(m.s?"NaN":"-Infinity"));if(m.eq(ui))return new v(0);if(t==null?(On=!1,u=y):u=t,m.eq(10))return t==null&&(On=!0),Ck(v,u);if(u+=p,v.precision=u,n=us(b),r=n.charAt(0),i=or(m),Math.abs(i)<15e14){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)m=m.times(e),n=us(m.d),r=n.charAt(0),h++;i=or(m),r>1?(m=new v("0."+n),i++):m=new v(r+"."+n.slice(1))}else return l=Ck(v,u+2,y).times(i+""),m=wg(new v(r+"."+n.slice(1)),u-p).plus(l),v.precision=y,t==null?(On=!0,mn(m,y)):m;for(s=a=m=fl(m.minus(ui),m.plus(ui),u),d=mn(m.times(m),u),o=3;;){if(a=mn(a.times(d),u),l=s.plus(fl(a,new v(o),u)),us(l.d).slice(0,u)===us(s.d).slice(0,u))return s=s.times(2),i!==0&&(s=s.plus(Ck(v,u+2,y).times(i+""))),s=fl(s,new v(h),u),v.precision=y,t==null?(On=!0,mn(s,y)):s;s=l,o+=2}}function Q9(e,t){var n,r,o;for((n=t.indexOf("."))>-1&&(t=t.replace(".","")),(r=t.search(/e/i))>0?(n<0&&(n=r),n+=+t.slice(r+1),t=t.substring(0,r)):n<0&&(n=t.length),r=0;t.charCodeAt(r)===48;)++r;for(o=t.length;t.charCodeAt(o-1)===48;)--o;if(t=t.slice(r,o),t){if(o-=r,n=n-r-1,e.e=Gh(n/Mn),e.d=[],r=(n+1)%Mn,n<0&&(r+=Mn),r<o){for(r&&e.d.push(+t.slice(0,r)),o-=Mn;r<o;)e.d.push(+t.slice(r,r+=Mn));t=t.slice(r),r=Mn-t.length}else r-=o;for(;r--;)t+="0";if(e.d.push(+t),On&&(e.e>Pw||e.e<-Pw))throw Error(sN+n)}else e.s=0,e.e=0,e.d=[0];return e}function mn(e,t,n){var r,o,i,a,s,l,u,d,h=e.d;for(a=1,i=h[0];i>=10;i/=10)a++;if(r=t-a,r<0)r+=Mn,o=t,u=h[d=0];else{if(d=Math.ceil((r+1)/Mn),i=h.length,d>=i)return e;for(u=i=h[d],a=1;i>=10;i/=10)a++;r%=Mn,o=r-Mn+a}if(n!==void 0&&(i=gu(10,a-o-1),s=u/i%10|0,l=t<0||h[d+1]!==void 0||u%i,l=n<4?(s||l)&&(n==0||n==(e.s<0?3:2)):s>5||s==5&&(n==4||l||n==6&&(r>0?o>0?u/gu(10,a-o):0:h[d-1])%10&1||n==(e.s<0?8:7))),t<1||!h[0])return l?(i=or(e),h.length=1,t=t-i-1,h[0]=gu(10,(Mn-t%Mn)%Mn),e.e=Gh(-t/Mn)||0):(h.length=1,h[0]=e.e=e.s=0),e;if(r==0?(h.length=d,i=1,d--):(h.length=d+1,i=gu(10,Mn-r),h[d]=o>0?(u/gu(10,a-o)%gu(10,o)|0)*i:0),l)for(;;)if(d==0){(h[0]+=i)==wr&&(h[0]=1,++e.e);break}else{if(h[d]+=i,h[d]!=wr)break;h[d--]=0,i=1}for(r=h.length;h[--r]===0;)h.pop();if(On&&(e.e>Pw||e.e<-Pw))throw Error(sN+or(e));return e}function fW(e,t){var n,r,o,i,a,s,l,u,d,h,p=e.constructor,m=p.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new p(e),On?mn(t,m):t;if(l=e.d,h=t.d,r=t.e,u=e.e,l=l.slice(),a=u-r,a){for(d=a<0,d?(n=l,a=-a,s=h.length):(n=h,r=u,s=l.length),o=Math.max(Math.ceil(m/Mn),s)+2,a>o&&(a=o,n.length=1),n.reverse(),o=a;o--;)n.push(0);n.reverse()}else{for(o=l.length,s=h.length,d=o<s,d&&(s=o),o=0;o<s;o++)if(l[o]!=h[o]){d=l[o]<h[o];break}a=0}for(d&&(n=l,l=h,h=n,t.s=-t.s),s=l.length,o=h.length-s;o>0;--o)l[s++]=0;for(o=h.length;o>a;){if(l[--o]<h[o]){for(i=o;i&&l[--i]===0;)l[i]=wr-1;--l[i],l[o]+=wr}l[o]-=h[o]}for(;l[--s]===0;)l.pop();for(;l[0]===0;l.shift())--r;return l[0]?(t.d=l,t.e=r,On?mn(t,m):t):new p(0)}function $u(e,t,n){var r,o=or(e),i=us(e.d),a=i.length;return t?(n&&(r=n-a)>0?i=i.charAt(0)+"."+i.slice(1)+sc(r):a>1&&(i=i.charAt(0)+"."+i.slice(1)),i=i+(o<0?"e":"e+")+o):o<0?(i="0."+sc(-o-1)+i,n&&(r=n-a)>0&&(i+=sc(r))):o>=a?(i+=sc(o+1-a),n&&(r=n-o-1)>0&&(i=i+"."+sc(r))):((r=o+1)<a&&(i=i.slice(0,r)+"."+i.slice(r)),n&&(r=n-a)>0&&(o+1===a&&(i+="."),i+=sc(r))),e.s<0?"-"+i:i}function eF(e,t){if(e.length>t)return e.length=t,!0}function hW(e){var t,n,r;function o(i){var a=this;if(!(a instanceof o))return new o(i);if(a.constructor=o,i instanceof o){a.s=i.s,a.e=i.e,a.d=(i=i.d)?i.slice():i;return}if(typeof i=="number"){if(i*0!==0)throw Error(Lu+i);if(i>0)a.s=1;else if(i<0)i=-i,a.s=-1;else{a.s=0,a.e=0,a.d=[0];return}if(i===~~i&&i<1e7){a.e=0,a.d=[i];return}return Q9(a,i.toString())}else if(typeof i!="string")throw Error(Lu+i);if(i.charCodeAt(0)===45?(i=i.slice(1),a.s=-1):a.s=1,iUe.test(i))Q9(a,i);else throw Error(Lu+i)}if(o.prototype=rt,o.ROUND_UP=0,o.ROUND_DOWN=1,o.ROUND_CEIL=2,o.ROUND_FLOOR=3,o.ROUND_HALF_UP=4,o.ROUND_HALF_DOWN=5,o.ROUND_HALF_EVEN=6,o.ROUND_HALF_CEIL=7,o.ROUND_HALF_FLOOR=8,o.clone=hW,o.config=o.set=aUe,e===void 0&&(e={}),e)for(r=["precision","rounding","toExpNeg","toExpPos","LN10"],t=0;t<r.length;)e.hasOwnProperty(n=r[t++])||(e[n]=this[n]);return o.config(e),o}function aUe(e){if(!e||typeof e!="object")throw Error(Ui+"Object expected");var t,n,r,o=["precision",1,Wh,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t<o.length;t+=3)if((r=e[n=o[t]])!==void 0)if(Gh(r)===r&&r>=o[t+1]&&r<=o[t+2])this[n]=r;else throw Error(Lu+n+": "+r);if((r=e[n="LN10"])!==void 0)if(r==Math.LN10)this[n]=new this(r);else throw Error(Lu+n+": "+r);return this}var lN=hW(oUe);ui=new lN(1);const un=lN;function sUe(e){return dUe(e)||uUe(e)||cUe(e)||lUe()}function lUe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function cUe(e,t){if(e){if(typeof e=="string")return UC(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return UC(e,t)}}function uUe(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function dUe(e){if(Array.isArray(e))return UC(e)}function UC(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var fUe=function(t){return t},pW={"@@functional/placeholder":!0},mW=function(t){return t===pW},tF=function(t){return function n(){return arguments.length===0||arguments.length===1&&mW(arguments.length<=0?void 0:arguments[0])?n:t.apply(void 0,arguments)}},hUe=function e(t,n){return t===1?n:tF(function(){for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];var a=o.filter(function(s){return s!==pW}).length;return a>=t?n.apply(void 0,o):e(t-a,tF(function(){for(var s=arguments.length,l=new Array(s),u=0;u<s;u++)l[u]=arguments[u];var d=o.map(function(h){return mW(h)?l.shift():h});return n.apply(void 0,sUe(d).concat(l))}))})},UT=function(t){return hUe(t.length,t)},zC=function(t,n){for(var r=[],o=t;o<n;++o)r[o-t]=o;return r},pUe=UT(function(e,t){return Array.isArray(t)?t.map(e):Object.keys(t).map(function(n){return t[n]}).map(e)}),mUe=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(!n.length)return fUe;var o=n.reverse(),i=o[0],a=o.slice(1);return function(){return a.reduce(function(s,l){return l(s)},i.apply(void 0,arguments))}},VC=function(t){return Array.isArray(t)?t.reverse():t.split("").reverse.join("")},gW=function(t){var n=null,r=null;return function(){for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return n&&i.every(function(s,l){return s===n[l]})||(n=i,r=t.apply(void 0,i)),r}};function gUe(e){var t;return e===0?t=1:t=Math.floor(new un(e).abs().log(10).toNumber())+1,t}function vUe(e,t,n){for(var r=new un(e),o=0,i=[];r.lt(t)&&o<1e5;)i.push(r.toNumber()),r=r.add(n),o++;return i}var yUe=UT(function(e,t,n){var r=+e,o=+t;return r+n*(o-r)}),bUe=UT(function(e,t,n){var r=t-+e;return r=r||1/0,(n-e)/r}),wUe=UT(function(e,t,n){var r=t-+e;return r=r||1/0,Math.max(0,Math.min(1,(n-e)/r))});const zT={rangeStep:vUe,getDigitCount:gUe,interpolateNumber:yUe,uninterpolateNumber:bUe,uninterpolateTruncation:wUe};function WC(e){return xUe(e)||TUe(e)||vW(e)||SUe()}function SUe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function TUe(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function xUe(e){if(Array.isArray(e))return GC(e)}function Sg(e,t){return EUe(e)||kUe(e,t)||vW(e,t)||IUe()}function IUe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function vW(e,t){if(e){if(typeof e=="string")return GC(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return GC(e,t)}}function GC(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function kUe(e,t){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(e)))){var n=[],r=!0,o=!1,i=void 0;try{for(var a=e[Symbol.iterator](),s;!(r=(s=a.next()).done)&&(n.push(s.value),!(t&&n.length===t));r=!0);}catch(l){o=!0,i=l}finally{try{!r&&a.return!=null&&a.return()}finally{if(o)throw i}}return n}}function EUe(e){if(Array.isArray(e))return e}function yW(e){var t=Sg(e,2),n=t[0],r=t[1],o=n,i=r;return n>r&&(o=r,i=n),[o,i]}function bW(e,t,n){if(e.lte(0))return new un(0);var r=zT.getDigitCount(e.toNumber()),o=new un(10).pow(r),i=e.div(o),a=r!==1?.05:.1,s=new un(Math.ceil(i.div(a).toNumber())).add(n).mul(a),l=s.mul(o);return t?l:new un(Math.ceil(l))}function CUe(e,t,n){var r=1,o=new un(e);if(!o.isint()&&n){var i=Math.abs(e);i<1?(r=new un(10).pow(zT.getDigitCount(e)-1),o=new un(Math.floor(o.div(r).toNumber())).mul(r)):i>1&&(o=new un(Math.floor(e)))}else e===0?o=new un(Math.floor((t-1)/2)):n||(o=new un(Math.floor(e)));var a=Math.floor((t-1)/2),s=mUe(pUe(function(l){return o.add(new un(l-a).mul(r)).toNumber()}),zC);return s(0,t)}function wW(e,t,n,r){var o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(!Number.isFinite((t-e)/(n-1)))return{step:new un(0),tickMin:new un(0),tickMax:new un(0)};var i=bW(new un(t).sub(e).div(n-1),r,o),a;e<=0&&t>=0?a=new un(0):(a=new un(e).add(t).div(2),a=a.sub(new un(a).mod(i)));var s=Math.ceil(a.sub(e).div(i).toNumber()),l=Math.ceil(new un(t).sub(a).div(i).toNumber()),u=s+l+1;return u>n?wW(e,t,n,r,o+1):(u<n&&(l=t>0?l+(n-u):l,s=t>0?s:s+(n-u)),{step:i,tickMin:a.sub(new un(s).mul(i)),tickMax:a.add(new un(l).mul(i))})}function MUe(e){var t=Sg(e,2),n=t[0],r=t[1],o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,a=Math.max(o,2),s=yW([n,r]),l=Sg(s,2),u=l[0],d=l[1];if(u===-1/0||d===1/0){var h=d===1/0?[u].concat(WC(zC(0,o-1).map(function(){return 1/0}))):[].concat(WC(zC(0,o-1).map(function(){return-1/0})),[d]);return n>r?VC(h):h}if(u===d)return CUe(u,o,i);var p=wW(u,d,a,i),m=p.step,b=p.tickMin,v=p.tickMax,y=zT.rangeStep(b,v.add(new un(.1).mul(m)),m);return n>r?VC(y):y}function DUe(e,t){var n=Sg(e,2),r=n[0],o=n[1],i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,a=yW([r,o]),s=Sg(a,2),l=s[0],u=s[1];if(l===-1/0||u===1/0)return[r,o];if(l===u)return[l];var d=Math.max(t,2),h=bW(new un(u).sub(l).div(d-1),i,0),p=[].concat(WC(zT.rangeStep(new un(l),new un(u).sub(new un(.99).mul(h)),h)),[u]);return r>o?VC(p):p}var AUe=gW(MUe),NUe=gW(DUe),OUe="Invariant failed";function qu(e,t){if(!e)throw new Error(OUe)}var PUe=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];function $f(e){"@babel/helpers - typeof";return $f=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},$f(e)}function jw(){return jw=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},jw.apply(this,arguments)}function jUe(e,t){return HUe(e)||FUe(e,t)||RUe(e,t)||LUe()}function LUe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function RUe(e,t){if(e){if(typeof e=="string")return nF(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return nF(e,t)}}function nF(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function FUe(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(d){u=!0,o=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}function HUe(e){if(Array.isArray(e))return e}function _Ue(e,t){if(e==null)return{};var n=BUe(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function BUe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function YUe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function rF(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,xW(r.key),r)}}function UUe(e,t,n){return t&&rF(e.prototype,t),n&&rF(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function zUe(e,t,n){return t=Lw(t),VUe(e,SW()?Reflect.construct(t,n||[],Lw(e).constructor):t.apply(e,n))}function VUe(e,t){if(t&&($f(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return WUe(e)}function WUe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function SW(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(SW=function(){return!!e})()}function Lw(e){return Lw=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Lw(e)}function GUe(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ZC(e,t)}function ZC(e,t){return ZC=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},ZC(e,t)}function TW(e,t,n){return t=xW(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xW(e){var t=ZUe(e,"string");return $f(t)=="symbol"?t:t+""}function ZUe(e,t){if($f(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if($f(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Wv=function(e){function t(){return YUe(this,t),zUe(this,t,arguments)}return GUe(t,e),UUe(t,[{key:"render",value:function(){var r=this.props,o=r.offset,i=r.layout,a=r.width,s=r.dataKey,l=r.data,u=r.dataPointFormatter,d=r.xAxis,h=r.yAxis,p=_Ue(r,PUe),m=_t(p,!1);this.props.direction==="x"&&d.type!=="number"&&qu(!1);var b=l.map(function(v){var y=u(v,s),S=y.x,x=y.y,C=y.value,k=y.errorVal;if(!k)return null;var M=[],I,O;if(Array.isArray(k)){var R=jUe(k,2);I=R[0],O=R[1]}else I=O=k;if(i==="vertical"){var L=d.scale,B=x+o,_=B+a,H=B-a,U=L(C-I),G=L(C+O);M.push({x1:G,y1:_,x2:G,y2:H}),M.push({x1:U,y1:B,x2:G,y2:B}),M.push({x1:U,y1:_,x2:U,y2:H})}else if(i==="horizontal"){var K=h.scale,z=S+o,ne=z-a,J=z+a,ee=K(C-I),Z=K(C+O);M.push({x1:ne,y1:Z,x2:J,y2:Z}),M.push({x1:z,y1:ee,x2:z,y2:Z}),M.push({x1:ne,y1:ee,x2:J,y2:ee})}return Y.createElement(Xn,jw({className:"recharts-errorBar",key:"bar-".concat(M.map(function(q){return"".concat(q.x1,"-").concat(q.x2,"-").concat(q.y1,"-").concat(q.y2)}))},m),M.map(function(q){return Y.createElement("line",jw({},q,{key:"line-".concat(q.x1,"-").concat(q.x2,"-").concat(q.y1,"-").concat(q.y2)}))}))});return Y.createElement(Xn,{className:"recharts-errorBars"},b)}}])}(Y.Component);TW(Wv,"defaultProps",{stroke:"black",strokeWidth:1.5,width:5,offset:0,layout:"horizontal"});TW(Wv,"displayName","ErrorBar");function Tg(e){"@babel/helpers - typeof";return Tg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Tg(e)}function oF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function fu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?oF(Object(n),!0).forEach(function(r){$Ue(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):oF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function $Ue(e,t,n){return t=qUe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function qUe(e){var t=KUe(e,"string");return Tg(t)=="symbol"?t:t+""}function KUe(e,t){if(Tg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Tg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var IW=function(t){var n=t.children,r=t.formattedGraphicalItems,o=t.legendWidth,i=t.legendContent,a=ai(n,yf);if(!a)return null;var s=yf.defaultProps,l=s!==void 0?fu(fu({},s),a.props):{},u;return a.props&&a.props.payload?u=a.props&&a.props.payload:i==="children"?u=(r||[]).reduce(function(d,h){var p=h.item,m=h.props,b=m.sectors||m.data||[];return d.concat(b.map(function(v){return{type:a.props.iconType||p.props.legendType,value:v.name,color:v.fill,payload:v}}))},[]):u=(r||[]).map(function(d){var h=d.item,p=h.type.defaultProps,m=p!==void 0?fu(fu({},p),h.props):{},b=m.dataKey,v=m.name,y=m.legendType,S=m.hide;return{inactive:S,dataKey:b,type:l.iconType||y||"square",color:cN(h),value:v||b,payload:m}}),fu(fu(fu({},l),yf.getWithHeight(a,o)),{},{payload:u,item:a})};function xg(e){"@babel/helpers - typeof";return xg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},xg(e)}function iF(e){return eze(e)||QUe(e)||JUe(e)||XUe()}function XUe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function JUe(e,t){if(e){if(typeof e=="string")return $C(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return $C(e,t)}}function QUe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function eze(e){if(Array.isArray(e))return $C(e)}function $C(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function aF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Wn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?aF(Object(n),!0).forEach(function(r){wf(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):aF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function wf(e,t,n){return t=tze(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function tze(e){var t=nze(e,"string");return xg(t)=="symbol"?t:t+""}function nze(e,t){if(xg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(xg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function gi(e,t,n){return Ht(e)||Ht(t)?n:dr(t)?Li(e,t,n):Pt(t)?t(e):n}function Cm(e,t,n,r){var o=rUe(e,function(s){return gi(s,t)});if(n==="number"){var i=o.filter(function(s){return Je(s)||parseFloat(s)});return i.length?[YT(i),BT(i)]:[1/0,-1/0]}var a=r?o.filter(function(s){return!Ht(s)}):o;return a.map(function(s){return dr(s)||s instanceof Date?s:""})}var rze=function(t){var n,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],o=arguments.length>2?arguments[2]:void 0,i=arguments.length>3?arguments[3]:void 0,a=-1,s=(n=r?.length)!==null&&n!==void 0?n:0;if(s<=1)return 0;if(i&&i.axisType==="angleAxis"&&Math.abs(Math.abs(i.range[1]-i.range[0])-360)<=1e-6)for(var l=i.range,u=0;u<s;u++){var d=u>0?o[u-1].coordinate:o[s-1].coordinate,h=o[u].coordinate,p=u>=s-1?o[0].coordinate:o[u+1].coordinate,m=void 0;if(ga(h-d)!==ga(p-h)){var b=[];if(ga(p-h)===ga(l[1]-l[0])){m=p;var v=h+l[1]-l[0];b[0]=Math.min(v,(v+d)/2),b[1]=Math.max(v,(v+d)/2)}else{m=d;var y=p+l[1]-l[0];b[0]=Math.min(h,(y+h)/2),b[1]=Math.max(h,(y+h)/2)}var S=[Math.min(h,(m+h)/2),Math.max(h,(m+h)/2)];if(t>S[0]&&t<=S[1]||t>=b[0]&&t<=b[1]){a=o[u].index;break}}else{var x=Math.min(d,p),C=Math.max(d,p);if(t>(x+h)/2&&t<=(C+h)/2){a=o[u].index;break}}}else for(var k=0;k<s;k++)if(k===0&&t<=(r[k].coordinate+r[k+1].coordinate)/2||k>0&&k<s-1&&t>(r[k].coordinate+r[k-1].coordinate)/2&&t<=(r[k].coordinate+r[k+1].coordinate)/2||k===s-1&&t>(r[k].coordinate+r[k-1].coordinate)/2){a=r[k].index;break}return a},cN=function(t){var n,r=t,o=r.type.displayName,i=(n=t.type)!==null&&n!==void 0&&n.defaultProps?Wn(Wn({},t.type.defaultProps),t.props):t.props,a=i.stroke,s=i.fill,l;switch(o){case"Line":l=a;break;case"Area":case"Radar":l=a&&a!=="none"?a:s;break;default:l=s;break}return l},oze=function(t){var n=t.barSize,r=t.totalSize,o=t.stackGroups,i=o===void 0?{}:o;if(!i)return{};for(var a={},s=Object.keys(i),l=0,u=s.length;l<u;l++)for(var d=i[s[l]].stackGroups,h=Object.keys(d),p=0,m=h.length;p<m;p++){var b=d[h[p]],v=b.items,y=b.cateAxisId,S=v.filter(function(O){return cl(O.type).indexOf("Bar")>=0});if(S&&S.length){var x=S[0].type.defaultProps,C=x!==void 0?Wn(Wn({},x),S[0].props):S[0].props,k=C.barSize,M=C[y];a[M]||(a[M]=[]);var I=Ht(k)?n:k;a[M].push({item:S[0],stackList:S.slice(1),barSize:Ht(I)?void 0:Zu(I,r,0)})}}return a},ize=function(t){var n=t.barGap,r=t.barCategoryGap,o=t.bandSize,i=t.sizeList,a=i===void 0?[]:i,s=t.maxBarSize,l=a.length;if(l<1)return null;var u=Zu(n,o,0,!0),d,h=[];if(a[0].barSize===+a[0].barSize){var p=!1,m=o/l,b=a.reduce(function(k,M){return k+M.barSize||0},0);b+=(l-1)*u,b>=o&&(b-=(l-1)*u,u=0),b>=o&&m>0&&(p=!0,m*=.9,b=l*m);var v=(o-b)/2>>0,y={offset:v-u,size:0};d=a.reduce(function(k,M){var I={item:M.item,position:{offset:y.offset+y.size+u,size:p?m:M.barSize}},O=[].concat(iF(k),[I]);return y=O[O.length-1].position,M.stackList&&M.stackList.length&&M.stackList.forEach(function(R){O.push({item:R,position:y})}),O},h)}else{var S=Zu(r,o,0,!0);o-2*S-(l-1)*u<=0&&(u=0);var x=(o-2*S-(l-1)*u)/l;x>1&&(x>>=0);var C=s===+s?Math.min(x,s):x;d=a.reduce(function(k,M,I){var O=[].concat(iF(k),[{item:M.item,position:{offset:S+(x+u)*I+(x-C)/2,size:C}}]);return M.stackList&&M.stackList.length&&M.stackList.forEach(function(R){O.push({item:R,position:O[O.length-1].position})}),O},h)}return d},aze=function(t,n,r,o){var i=r.children,a=r.width,s=r.margin,l=a-(s.left||0)-(s.right||0),u=IW({children:i,legendWidth:l});if(u){var d=o||{},h=d.width,p=d.height,m=u.align,b=u.verticalAlign,v=u.layout;if((v==="vertical"||v==="horizontal"&&b==="middle")&&m!=="center"&&Je(t[m]))return Wn(Wn({},t),{},wf({},m,t[m]+(h||0)));if((v==="horizontal"||v==="vertical"&&m==="center")&&b!=="middle"&&Je(t[b]))return Wn(Wn({},t),{},wf({},b,t[b]+(p||0)))}return t},sze=function(t,n,r){return Ht(n)?!0:t==="horizontal"?n==="yAxis":t==="vertical"||r==="x"?n==="xAxis":r==="y"?n==="yAxis":!0},kW=function(t,n,r,o,i){var a=n.props.children,s=Ri(a,Wv).filter(function(u){return sze(o,i,u.props.direction)});if(s&&s.length){var l=s.map(function(u){return u.props.dataKey});return t.reduce(function(u,d){var h=gi(d,r);if(Ht(h))return u;var p=Array.isArray(h)?[YT(h),BT(h)]:[h,h],m=l.reduce(function(b,v){var y=gi(d,v,0),S=p[0]-Math.abs(Array.isArray(y)?y[0]:y),x=p[1]+Math.abs(Array.isArray(y)?y[1]:y);return[Math.min(S,b[0]),Math.max(x,b[1])]},[1/0,-1/0]);return[Math.min(m[0],u[0]),Math.max(m[1],u[1])]},[1/0,-1/0])}return null},lze=function(t,n,r,o,i){var a=n.map(function(s){return kW(t,s,r,i,o)}).filter(function(s){return!Ht(s)});return a&&a.length?a.reduce(function(s,l){return[Math.min(s[0],l[0]),Math.max(s[1],l[1])]},[1/0,-1/0]):null},EW=function(t,n,r,o,i){var a=n.map(function(l){var u=l.props.dataKey;return r==="number"&&u&&kW(t,l,u,o)||Cm(t,u,r,i)});if(r==="number")return a.reduce(function(l,u){return[Math.min(l[0],u[0]),Math.max(l[1],u[1])]},[1/0,-1/0]);var s={};return a.reduce(function(l,u){for(var d=0,h=u.length;d<h;d++)s[u[d]]||(s[u[d]]=!0,l.push(u[d]));return l},[])},CW=function(t,n){return t==="horizontal"&&n==="xAxis"||t==="vertical"&&n==="yAxis"||t==="centric"&&n==="angleAxis"||t==="radial"&&n==="radiusAxis"},MW=function(t,n,r,o){if(o)return t.map(function(l){return l.coordinate});var i,a,s=t.map(function(l){return l.coordinate===n&&(i=!0),l.coordinate===r&&(a=!0),l.coordinate});return i||s.push(n),a||s.push(r),s},nl=function(t,n,r){if(!t)return null;var o=t.scale,i=t.duplicateDomain,a=t.type,s=t.range,l=t.realScaleType==="scaleBand"?o.bandwidth()/2:2,u=(n||r)&&a==="category"&&o.bandwidth?o.bandwidth()/l:0;if(u=t.axisType==="angleAxis"&&s?.length>=2?ga(s[0]-s[1])*2*u:u,n&&(t.ticks||t.niceTicks)){var d=(t.ticks||t.niceTicks).map(function(h){var p=i?i.indexOf(h):h;return{coordinate:o(p)+u,value:h,offset:u}});return d.filter(function(h){return!_v(h.coordinate)})}return t.isCategorical&&t.categoricalDomain?t.categoricalDomain.map(function(h,p){return{coordinate:o(h)+u,value:h,index:p,offset:u}}):o.ticks&&!r?o.ticks(t.tickCount).map(function(h){return{coordinate:o(h)+u,value:h,offset:u}}):o.domain().map(function(h,p){return{coordinate:o(h)+u,value:i?i[h]:h,index:p,offset:u}})},Mk=new WeakMap,Db=function(t,n){if(typeof n!="function")return t;Mk.has(t)||Mk.set(t,new WeakMap);var r=Mk.get(t);if(r.has(n))return r.get(n);var o=function(){t.apply(void 0,arguments),n.apply(void 0,arguments)};return r.set(n,o),o},cze=function(t,n,r){var o=t.scale,i=t.type,a=t.layout,s=t.axisType;if(o==="auto")return a==="radial"&&s==="radiusAxis"?{scale:mg(),realScaleType:"band"}:a==="radial"&&s==="angleAxis"?{scale:Dw(),realScaleType:"linear"}:i==="category"&&n&&(n.indexOf("LineChart")>=0||n.indexOf("AreaChart")>=0||n.indexOf("ComposedChart")>=0&&!r)?{scale:Em(),realScaleType:"point"}:i==="category"?{scale:mg(),realScaleType:"band"}:{scale:Dw(),realScaleType:"linear"};if(Hv(o)){var l="scale".concat(DT(o));return{scale:(J9[l]||Em)(),realScaleType:J9[l]?l:"point"}}return Pt(o)?{scale:o}:{scale:Em(),realScaleType:"point"}},sF=1e-4,uze=function(t){var n=t.domain();if(!(!n||n.length<=2)){var r=n.length,o=t.range(),i=Math.min(o[0],o[1])-sF,a=Math.max(o[0],o[1])+sF,s=t(n[0]),l=t(n[r-1]);(s<i||s>a||l<i||l>a)&&t.domain([n[0],n[r-1]])}},dze=function(t,n){if(!t)return null;for(var r=0,o=t.length;r<o;r++)if(t[r].item===n)return t[r].position;return null},fze=function(t,n){if(!n||n.length!==2||!Je(n[0])||!Je(n[1]))return t;var r=Math.min(n[0],n[1]),o=Math.max(n[0],n[1]),i=[t[0],t[1]];return(!Je(t[0])||t[0]<r)&&(i[0]=r),(!Je(t[1])||t[1]>o)&&(i[1]=o),i[0]>o&&(i[0]=o),i[1]<r&&(i[1]=r),i},hze=function(t){var n=t.length;if(!(n<=0))for(var r=0,o=t[0].length;r<o;++r)for(var i=0,a=0,s=0;s<n;++s){var l=_v(t[s][r][1])?t[s][r][0]:t[s][r][1];l>=0?(t[s][r][0]=i,t[s][r][1]=i+l,i=t[s][r][1]):(t[s][r][0]=a,t[s][r][1]=a+l,a=t[s][r][1])}},pze=function(t){var n=t.length;if(!(n<=0))for(var r=0,o=t[0].length;r<o;++r)for(var i=0,a=0;a<n;++a){var s=_v(t[a][r][1])?t[a][r][0]:t[a][r][1];s>=0?(t[a][r][0]=i,t[a][r][1]=i+s,i=t[a][r][1]):(t[a][r][0]=0,t[a][r][1]=0)}},mze={sign:hze,expand:k8e,none:Bf,silhouette:E8e,wiggle:C8e,positive:pze},gze=function(t,n,r){var o=n.map(function(s){return s.props.dataKey}),i=mze[r],a=I8e().keys(o).value(function(s,l){return+gi(s,l,0)}).order(IC).offset(i);return a(t)},vze=function(t,n,r,o,i,a){if(!t)return null;var s=a?n.reverse():n,l={},u=s.reduce(function(h,p){var m,b=(m=p.type)!==null&&m!==void 0&&m.defaultProps?Wn(Wn({},p.type.defaultProps),p.props):p.props,v=b.stackId,y=b.hide;if(y)return h;var S=b[r],x=h[S]||{hasStack:!1,stackGroups:{}};if(dr(v)){var C=x.stackGroups[v]||{numericAxisId:r,cateAxisId:o,items:[]};C.items.push(p),x.hasStack=!0,x.stackGroups[v]=C}else x.stackGroups[Bv("_stackId_")]={numericAxisId:r,cateAxisId:o,items:[p]};return Wn(Wn({},h),{},wf({},S,x))},l),d={};return Object.keys(u).reduce(function(h,p){var m=u[p];if(m.hasStack){var b={};m.stackGroups=Object.keys(m.stackGroups).reduce(function(v,y){var S=m.stackGroups[y];return Wn(Wn({},v),{},wf({},y,{numericAxisId:r,cateAxisId:o,items:S.items,stackedData:gze(t,S.items,i)}))},b)}return Wn(Wn({},h),{},wf({},p,m))},d)},yze=function(t,n){var r=n.realScaleType,o=n.type,i=n.tickCount,a=n.originalDomain,s=n.allowDecimals,l=r||n.scale;if(l!=="auto"&&l!=="linear")return null;if(i&&o==="number"&&a&&(a[0]==="auto"||a[1]==="auto")){var u=t.domain();if(!u.length)return null;var d=AUe(u,i,s);return t.domain([YT(d),BT(d)]),{niceTicks:d}}if(i&&o==="number"){var h=t.domain(),p=NUe(h,i,s);return{niceTicks:p}}return null};function lF(e){var t=e.axis,n=e.ticks,r=e.bandSize,o=e.entry,i=e.index,a=e.dataKey;if(t.type==="category"){if(!t.allowDuplicatedCategory&&t.dataKey&&!Ht(o[t.dataKey])){var s=cw(n,"value",o[t.dataKey]);if(s)return s.coordinate+r/2}return n[i]?n[i].coordinate+r/2:null}var l=gi(o,Ht(a)?t.dataKey:a);return Ht(l)?null:t.scale(l)}var cF=function(t){var n=t.axis,r=t.ticks,o=t.offset,i=t.bandSize,a=t.entry,s=t.index;if(n.type==="category")return r[s]?r[s].coordinate+o:null;var l=gi(a,n.dataKey,n.domain[s]);return Ht(l)?null:n.scale(l)-i/2+o},bze=function(t){var n=t.numericAxis,r=n.scale.domain();if(n.type==="number"){var o=Math.min(r[0],r[1]),i=Math.max(r[0],r[1]);return o<=0&&i>=0?0:i<0?i:o}return r[0]},wze=function(t,n){var r,o=(r=t.type)!==null&&r!==void 0&&r.defaultProps?Wn(Wn({},t.type.defaultProps),t.props):t.props,i=o.stackId;if(dr(i)){var a=n[i];if(a){var s=a.items.indexOf(t);return s>=0?a.stackedData[s]:null}}return null},Sze=function(t){return t.reduce(function(n,r){return[YT(r.concat([n[0]]).filter(Je)),BT(r.concat([n[1]]).filter(Je))]},[1/0,-1/0])},DW=function(t,n,r){return Object.keys(t).reduce(function(o,i){var a=t[i],s=a.stackedData,l=s.reduce(function(u,d){var h=Sze(d.slice(n,r+1));return[Math.min(u[0],h[0]),Math.max(u[1],h[1])]},[1/0,-1/0]);return[Math.min(l[0],o[0]),Math.max(l[1],o[1])]},[1/0,-1/0]).map(function(o){return o===1/0||o===-1/0?0:o})},uF=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,dF=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,qC=function(t,n,r){if(Pt(t))return t(n,r);if(!Array.isArray(t))return n;var o=[];if(Je(t[0]))o[0]=r?t[0]:Math.min(t[0],n[0]);else if(uF.test(t[0])){var i=+uF.exec(t[0])[1];o[0]=n[0]-i}else Pt(t[0])?o[0]=t[0](n[0]):o[0]=n[0];if(Je(t[1]))o[1]=r?t[1]:Math.max(t[1],n[1]);else if(dF.test(t[1])){var a=+dF.exec(t[1])[1];o[1]=n[1]+a}else Pt(t[1])?o[1]=t[1](n[1]):o[1]=n[1];return o},Rw=function(t,n,r){if(t&&t.scale&&t.scale.bandwidth){var o=t.scale.bandwidth();if(!r||o>0)return o}if(t&&n&&n.length>=2){for(var i=FS(n,function(h){return h.coordinate}),a=1/0,s=1,l=i.length;s<l;s++){var u=i[s],d=i[s-1];a=Math.min((u.coordinate||0)-(d.coordinate||0),a)}return a===1/0?0:a}return r?void 0:0},fF=function(t,n,r){return!t||!t.length||ws(t,Li(r,"type.defaultProps.domain"))?n:t},AW=function(t,n){var r=t.type.defaultProps?Wn(Wn({},t.type.defaultProps),t.props):t.props,o=r.dataKey,i=r.name,a=r.unit,s=r.formatter,l=r.tooltipType,u=r.chartType,d=r.hide;return Wn(Wn({},_t(t,!1)),{},{dataKey:o,unit:a,formatter:s,name:i||o,color:cN(t),value:gi(n,o),type:l,payload:n,chartType:u,hide:d})};function Ig(e){"@babel/helpers - typeof";return Ig=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ig(e)}function hF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function pF(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?hF(Object(n),!0).forEach(function(r){Tze(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):hF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Tze(e,t,n){return t=xze(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xze(e){var t=Ize(e,"string");return Ig(t)=="symbol"?t:t+""}function Ize(e,t){if(Ig(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Ig(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Fw=Math.PI/180,kze=function(t){return t*180/Math.PI},Rr=function(t,n,r,o){return{x:t+Math.cos(-Fw*o)*r,y:n+Math.sin(-Fw*o)*r}},Eze=function(t,n){var r=t.x,o=t.y,i=n.x,a=n.y;return Math.sqrt(Math.pow(r-i,2)+Math.pow(o-a,2))},Cze=function(t,n){var r=t.x,o=t.y,i=n.cx,a=n.cy,s=Eze({x:r,y:o},{x:i,y:a});if(s<=0)return{radius:s};var l=(r-i)/s,u=Math.acos(l);return o>a&&(u=2*Math.PI-u),{radius:s,angle:kze(u),angleInRadian:u}},Mze=function(t){var n=t.startAngle,r=t.endAngle,o=Math.floor(n/360),i=Math.floor(r/360),a=Math.min(o,i);return{startAngle:n-a*360,endAngle:r-a*360}},Dze=function(t,n){var r=n.startAngle,o=n.endAngle,i=Math.floor(r/360),a=Math.floor(o/360),s=Math.min(i,a);return t+s*360},mF=function(t,n){var r=t.x,o=t.y,i=Cze({x:r,y:o},n),a=i.radius,s=i.angle,l=n.innerRadius,u=n.outerRadius;if(a<l||a>u)return!1;if(a===0)return!0;var d=Mze(n),h=d.startAngle,p=d.endAngle,m=s,b;if(h<=p){for(;m>p;)m-=360;for(;m<h;)m+=360;b=m>=h&&m<=p}else{for(;m>h;)m-=360;for(;m<p;)m+=360;b=m>=p&&m<=h}return b?pF(pF({},n),{},{radius:a,angle:Dze(m,n)}):null};function kg(e){"@babel/helpers - typeof";return kg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},kg(e)}var Aze=["offset"];function Nze(e){return Lze(e)||jze(e)||Pze(e)||Oze()}function Oze(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Pze(e,t){if(e){if(typeof e=="string")return KC(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return KC(e,t)}}function jze(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Lze(e){if(Array.isArray(e))return KC(e)}function KC(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Rze(e,t){if(e==null)return{};var n=Fze(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Fze(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function gF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function cr(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?gF(Object(n),!0).forEach(function(r){Hze(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):gF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Hze(e,t,n){return t=_ze(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function _ze(e){var t=Bze(e,"string");return kg(t)=="symbol"?t:t+""}function Bze(e,t){if(kg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(kg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Eg(){return Eg=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Eg.apply(this,arguments)}var Yze=function(t){var n=t.value,r=t.formatter,o=Ht(t.children)?n:t.children;return Pt(r)?r(o):o},Uze=function(t,n){var r=ga(n-t),o=Math.min(Math.abs(n-t),360);return r*o},zze=function(t,n,r){var o=t.position,i=t.viewBox,a=t.offset,s=t.className,l=i,u=l.cx,d=l.cy,h=l.innerRadius,p=l.outerRadius,m=l.startAngle,b=l.endAngle,v=l.clockWise,y=(h+p)/2,S=Uze(m,b),x=S>=0?1:-1,C,k;o==="insideStart"?(C=m+x*a,k=v):o==="insideEnd"?(C=b-x*a,k=!v):o==="end"&&(C=b+x*a,k=v),k=S<=0?k:!k;var M=Rr(u,d,y,C),I=Rr(u,d,y,C+(k?1:-1)*359),O="M".concat(M.x,",").concat(M.y,`
|
|
|
A`).concat(y,",").concat(y,",0,1,").concat(k?0:1,`,
|
|
|
`).concat(I.x,",").concat(I.y),R=Ht(t.id)?Bv("recharts-radial-line-"):t.id;return Y.createElement("text",Eg({},r,{dominantBaseline:"central",className:$t("recharts-radial-bar-label",s)}),Y.createElement("defs",null,Y.createElement("path",{id:R,d:O})),Y.createElement("textPath",{xlinkHref:"#".concat(R)},n))},Vze=function(t){var n=t.viewBox,r=t.offset,o=t.position,i=n,a=i.cx,s=i.cy,l=i.innerRadius,u=i.outerRadius,d=i.startAngle,h=i.endAngle,p=(d+h)/2;if(o==="outside"){var m=Rr(a,s,u+r,p),b=m.x,v=m.y;return{x:b,y:v,textAnchor:b>=a?"start":"end",verticalAnchor:"middle"}}if(o==="center")return{x:a,y:s,textAnchor:"middle",verticalAnchor:"middle"};if(o==="centerTop")return{x:a,y:s,textAnchor:"middle",verticalAnchor:"start"};if(o==="centerBottom")return{x:a,y:s,textAnchor:"middle",verticalAnchor:"end"};var y=(l+u)/2,S=Rr(a,s,y,p),x=S.x,C=S.y;return{x,y:C,textAnchor:"middle",verticalAnchor:"middle"}},Wze=function(t){var n=t.viewBox,r=t.parentViewBox,o=t.offset,i=t.position,a=n,s=a.x,l=a.y,u=a.width,d=a.height,h=d>=0?1:-1,p=h*o,m=h>0?"end":"start",b=h>0?"start":"end",v=u>=0?1:-1,y=v*o,S=v>0?"end":"start",x=v>0?"start":"end";if(i==="top"){var C={x:s+u/2,y:l-h*o,textAnchor:"middle",verticalAnchor:m};return cr(cr({},C),r?{height:Math.max(l-r.y,0),width:u}:{})}if(i==="bottom"){var k={x:s+u/2,y:l+d+p,textAnchor:"middle",verticalAnchor:b};return cr(cr({},k),r?{height:Math.max(r.y+r.height-(l+d),0),width:u}:{})}if(i==="left"){var M={x:s-y,y:l+d/2,textAnchor:S,verticalAnchor:"middle"};return cr(cr({},M),r?{width:Math.max(M.x-r.x,0),height:d}:{})}if(i==="right"){var I={x:s+u+y,y:l+d/2,textAnchor:x,verticalAnchor:"middle"};return cr(cr({},I),r?{width:Math.max(r.x+r.width-I.x,0),height:d}:{})}var O=r?{width:u,height:d}:{};return i==="insideLeft"?cr({x:s+y,y:l+d/2,textAnchor:x,verticalAnchor:"middle"},O):i==="insideRight"?cr({x:s+u-y,y:l+d/2,textAnchor:S,verticalAnchor:"middle"},O):i==="insideTop"?cr({x:s+u/2,y:l+p,textAnchor:"middle",verticalAnchor:b},O):i==="insideBottom"?cr({x:s+u/2,y:l+d-p,textAnchor:"middle",verticalAnchor:m},O):i==="insideTopLeft"?cr({x:s+y,y:l+p,textAnchor:x,verticalAnchor:b},O):i==="insideTopRight"?cr({x:s+u-y,y:l+p,textAnchor:S,verticalAnchor:b},O):i==="insideBottomLeft"?cr({x:s+y,y:l+d-p,textAnchor:x,verticalAnchor:m},O):i==="insideBottomRight"?cr({x:s+u-y,y:l+d-p,textAnchor:S,verticalAnchor:m},O):mh(i)&&(Je(i.x)||xu(i.x))&&(Je(i.y)||xu(i.y))?cr({x:s+Zu(i.x,u),y:l+Zu(i.y,d),textAnchor:"end",verticalAnchor:"end"},O):cr({x:s+u/2,y:l+d/2,textAnchor:"middle",verticalAnchor:"middle"},O)},Gze=function(t){return"cx"in t&&Je(t.cx)};function no(e){var t=e.offset,n=t===void 0?5:t,r=Rze(e,Aze),o=cr({offset:n},r),i=o.viewBox,a=o.position,s=o.value,l=o.children,u=o.content,d=o.className,h=d===void 0?"":d,p=o.textBreakAll;if(!i||Ht(s)&&Ht(l)&&!D.isValidElement(u)&&!Pt(u))return null;if(D.isValidElement(u))return D.cloneElement(u,o);var m;if(Pt(u)){if(m=D.createElement(u,o),D.isValidElement(m))return m}else m=Yze(o);var b=Gze(i),v=_t(o,!0);if(b&&(a==="insideStart"||a==="insideEnd"||a==="end"))return zze(o,m,v);var y=b?Vze(o):Wze(o);return Y.createElement(Tw,Eg({className:$t("recharts-label",h)},v,y,{breakAll:p}),m)}no.displayName="Label";var NW=function(t){var n=t.cx,r=t.cy,o=t.angle,i=t.startAngle,a=t.endAngle,s=t.r,l=t.radius,u=t.innerRadius,d=t.outerRadius,h=t.x,p=t.y,m=t.top,b=t.left,v=t.width,y=t.height,S=t.clockWise,x=t.labelViewBox;if(x)return x;if(Je(v)&&Je(y)){if(Je(h)&&Je(p))return{x:h,y:p,width:v,height:y};if(Je(m)&&Je(b))return{x:m,y:b,width:v,height:y}}return Je(h)&&Je(p)?{x:h,y:p,width:0,height:0}:Je(n)&&Je(r)?{cx:n,cy:r,startAngle:i||o||0,endAngle:a||o||0,innerRadius:u||0,outerRadius:d||l||s||0,clockWise:S}:t.viewBox?t.viewBox:{}},Zze=function(t,n){return t?t===!0?Y.createElement(no,{key:"label-implicit",viewBox:n}):dr(t)?Y.createElement(no,{key:"label-implicit",viewBox:n,value:t}):D.isValidElement(t)?t.type===no?D.cloneElement(t,{key:"label-implicit",viewBox:n}):Y.createElement(no,{key:"label-implicit",content:t,viewBox:n}):Pt(t)?Y.createElement(no,{key:"label-implicit",content:t,viewBox:n}):mh(t)?Y.createElement(no,Eg({viewBox:n},t,{key:"label-implicit"})):null:null},$ze=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!t||!t.children&&r&&!t.label)return null;var o=t.children,i=NW(t),a=Ri(o,no).map(function(l,u){return D.cloneElement(l,{viewBox:n||i,key:"label-".concat(u)})});if(!r)return a;var s=Zze(t.label,n||i);return[s].concat(Nze(a))};no.parseViewBox=NW;no.renderCallByParent=$ze;function Cg(e){"@babel/helpers - typeof";return Cg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Cg(e)}var qze=["valueAccessor"],Kze=["data","dataKey","clockWise","id","textBreakAll"];function Xze(e){return tVe(e)||eVe(e)||Qze(e)||Jze()}function Jze(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Qze(e,t){if(e){if(typeof e=="string")return XC(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return XC(e,t)}}function eVe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function tVe(e){if(Array.isArray(e))return XC(e)}function XC(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Hw(){return Hw=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Hw.apply(this,arguments)}function vF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function yF(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?vF(Object(n),!0).forEach(function(r){nVe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):vF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function nVe(e,t,n){return t=rVe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function rVe(e){var t=oVe(e,"string");return Cg(t)=="symbol"?t:t+""}function oVe(e,t){if(Cg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Cg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function bF(e,t){if(e==null)return{};var n=iVe(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function iVe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var aVe=function(t){return Array.isArray(t.value)?Wve(t.value):t.value};function bc(e){var t=e.valueAccessor,n=t===void 0?aVe:t,r=bF(e,qze),o=r.data,i=r.dataKey,a=r.clockWise,s=r.id,l=r.textBreakAll,u=bF(r,Kze);return!o||!o.length?null:Y.createElement(Xn,{className:"recharts-label-list"},o.map(function(d,h){var p=Ht(i)?n(d,h):gi(d&&d.payload,i),m=Ht(s)?{}:{id:"".concat(s,"-").concat(h)};return Y.createElement(no,Hw({},_t(d,!0),u,m,{parentViewBox:d.parentViewBox,value:p,textBreakAll:l,viewBox:no.parseViewBox(Ht(a)?d:yF(yF({},d),{},{clockWise:a})),key:"label-".concat(h),index:h}))}))}bc.displayName="LabelList";function sVe(e,t){return e?e===!0?Y.createElement(bc,{key:"labelList-implicit",data:t}):Y.isValidElement(e)||Pt(e)?Y.createElement(bc,{key:"labelList-implicit",data:t,content:e}):mh(e)?Y.createElement(bc,Hw({data:t},e,{key:"labelList-implicit"})):null:null}function lVe(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!e||!e.children&&n&&!e.label)return null;var r=e.children,o=Ri(r,bc).map(function(a,s){return D.cloneElement(a,{data:t,key:"labelList-".concat(s)})});if(!n)return o;var i=sVe(e.label,t);return[i].concat(Xze(o))}bc.renderCallByParent=lVe;function Mg(e){"@babel/helpers - typeof";return Mg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Mg(e)}function JC(){return JC=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},JC.apply(this,arguments)}function wF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function SF(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?wF(Object(n),!0).forEach(function(r){cVe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function cVe(e,t,n){return t=uVe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function uVe(e){var t=dVe(e,"string");return Mg(t)=="symbol"?t:t+""}function dVe(e,t){if(Mg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Mg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var fVe=function(t,n){var r=ga(n-t),o=Math.min(Math.abs(n-t),359.999);return r*o},Ab=function(t){var n=t.cx,r=t.cy,o=t.radius,i=t.angle,a=t.sign,s=t.isExternal,l=t.cornerRadius,u=t.cornerIsExternal,d=l*(s?1:-1)+o,h=Math.asin(l/d)/Fw,p=u?i:i+a*h,m=Rr(n,r,d,p),b=Rr(n,r,o,p),v=u?i-a*h:i,y=Rr(n,r,d*Math.cos(h*Fw),v);return{center:m,circleTangency:b,lineTangency:y,theta:h}},OW=function(t){var n=t.cx,r=t.cy,o=t.innerRadius,i=t.outerRadius,a=t.startAngle,s=t.endAngle,l=fVe(a,s),u=a+l,d=Rr(n,r,i,a),h=Rr(n,r,i,u),p="M ".concat(d.x,",").concat(d.y,`
|
|
|
A `).concat(i,",").concat(i,`,0,
|
|
|
`).concat(+(Math.abs(l)>180),",").concat(+(a>u),`,
|
|
|
`).concat(h.x,",").concat(h.y,`
|
|
|
`);if(o>0){var m=Rr(n,r,o,a),b=Rr(n,r,o,u);p+="L ".concat(b.x,",").concat(b.y,`
|
|
|
A `).concat(o,",").concat(o,`,0,
|
|
|
`).concat(+(Math.abs(l)>180),",").concat(+(a<=u),`,
|
|
|
`).concat(m.x,",").concat(m.y," Z")}else p+="L ".concat(n,",").concat(r," Z");return p},hVe=function(t){var n=t.cx,r=t.cy,o=t.innerRadius,i=t.outerRadius,a=t.cornerRadius,s=t.forceCornerRadius,l=t.cornerIsExternal,u=t.startAngle,d=t.endAngle,h=ga(d-u),p=Ab({cx:n,cy:r,radius:i,angle:u,sign:h,cornerRadius:a,cornerIsExternal:l}),m=p.circleTangency,b=p.lineTangency,v=p.theta,y=Ab({cx:n,cy:r,radius:i,angle:d,sign:-h,cornerRadius:a,cornerIsExternal:l}),S=y.circleTangency,x=y.lineTangency,C=y.theta,k=l?Math.abs(u-d):Math.abs(u-d)-v-C;if(k<0)return s?"M ".concat(b.x,",").concat(b.y,`
|
|
|
a`).concat(a,",").concat(a,",0,0,1,").concat(a*2,`,0
|
|
|
a`).concat(a,",").concat(a,",0,0,1,").concat(-a*2,`,0
|
|
|
`):OW({cx:n,cy:r,innerRadius:o,outerRadius:i,startAngle:u,endAngle:d});var M="M ".concat(b.x,",").concat(b.y,`
|
|
|
A`).concat(a,",").concat(a,",0,0,").concat(+(h<0),",").concat(m.x,",").concat(m.y,`
|
|
|
A`).concat(i,",").concat(i,",0,").concat(+(k>180),",").concat(+(h<0),",").concat(S.x,",").concat(S.y,`
|
|
|
A`).concat(a,",").concat(a,",0,0,").concat(+(h<0),",").concat(x.x,",").concat(x.y,`
|
|
|
`);if(o>0){var I=Ab({cx:n,cy:r,radius:o,angle:u,sign:h,isExternal:!0,cornerRadius:a,cornerIsExternal:l}),O=I.circleTangency,R=I.lineTangency,L=I.theta,B=Ab({cx:n,cy:r,radius:o,angle:d,sign:-h,isExternal:!0,cornerRadius:a,cornerIsExternal:l}),_=B.circleTangency,H=B.lineTangency,U=B.theta,G=l?Math.abs(u-d):Math.abs(u-d)-L-U;if(G<0&&a===0)return"".concat(M,"L").concat(n,",").concat(r,"Z");M+="L".concat(H.x,",").concat(H.y,`
|
|
|
A`).concat(a,",").concat(a,",0,0,").concat(+(h<0),",").concat(_.x,",").concat(_.y,`
|
|
|
A`).concat(o,",").concat(o,",0,").concat(+(G>180),",").concat(+(h>0),",").concat(O.x,",").concat(O.y,`
|
|
|
A`).concat(a,",").concat(a,",0,0,").concat(+(h<0),",").concat(R.x,",").concat(R.y,"Z")}else M+="L".concat(n,",").concat(r,"Z");return M},pVe={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},PW=function(t){var n=SF(SF({},pVe),t),r=n.cx,o=n.cy,i=n.innerRadius,a=n.outerRadius,s=n.cornerRadius,l=n.forceCornerRadius,u=n.cornerIsExternal,d=n.startAngle,h=n.endAngle,p=n.className;if(a<i||d===h)return null;var m=$t("recharts-sector",p),b=a-i,v=Zu(s,b,0,!0),y;return v>0&&Math.abs(d-h)<360?y=hVe({cx:r,cy:o,innerRadius:i,outerRadius:a,cornerRadius:Math.min(v,b/2),forceCornerRadius:l,cornerIsExternal:u,startAngle:d,endAngle:h}):y=OW({cx:r,cy:o,innerRadius:i,outerRadius:a,startAngle:d,endAngle:h}),Y.createElement("path",JC({},_t(n,!0),{className:m,d:y,role:"img"}))};function Dg(e){"@babel/helpers - typeof";return Dg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Dg(e)}function QC(){return QC=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},QC.apply(this,arguments)}function TF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function xF(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?TF(Object(n),!0).forEach(function(r){mVe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):TF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function mVe(e,t,n){return t=gVe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function gVe(e){var t=vVe(e,"string");return Dg(t)=="symbol"?t:t+""}function vVe(e,t){if(Dg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Dg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var IF={curveBasisClosed:h8e,curveBasisOpen:p8e,curveBasis:f8e,curveBumpX:J6e,curveBumpY:Q6e,curveLinearClosed:m8e,curveLinear:NT,curveMonotoneX:g8e,curveMonotoneY:v8e,curveNatural:y8e,curveStep:b8e,curveStepAfter:S8e,curveStepBefore:w8e},Nb=function(t){return t.x===+t.x&&t.y===+t.y},Gp=function(t){return t.x},Zp=function(t){return t.y},yVe=function(t,n){if(Pt(t))return t;var r="curve".concat(DT(t));return(r==="curveMonotone"||r==="curveBump")&&n?IF["".concat(r).concat(n==="vertical"?"Y":"X")]:IF[r]||NT},bVe=function(t){var n=t.type,r=n===void 0?"linear":n,o=t.points,i=o===void 0?[]:o,a=t.baseLine,s=t.layout,l=t.connectNulls,u=l===void 0?!1:l,d=yVe(r,s),h=u?i.filter(function(v){return Nb(v)}):i,p;if(Array.isArray(a)){var m=u?a.filter(function(v){return Nb(v)}):a,b=h.map(function(v,y){return xF(xF({},v),{},{base:m[y]})});return s==="vertical"?p=Tb().y(Zp).x1(Gp).x0(function(v){return v.base.x}):p=Tb().x(Gp).y1(Zp).y0(function(v){return v.base.y}),p.defined(Nb).curve(d),p(b)}return s==="vertical"&&Je(a)?p=Tb().y(Zp).x1(Gp).x0(a):Je(a)?p=Tb().x(Gp).y1(Zp).y0(a):p=rV().x(Gp).y(Zp),p.defined(Nb).curve(d),p(h)},eM=function(t){var n=t.className,r=t.points,o=t.path,i=t.pathRef;if((!r||!r.length)&&!o)return null;var a=r&&r.length?bVe(t):o;return Y.createElement("path",QC({},_t(t,!1),uw(t),{className:$t("recharts-curve",n),d:a,ref:i}))},wVe=Object.getOwnPropertyNames,SVe=Object.getOwnPropertySymbols,TVe=Object.prototype.hasOwnProperty;function kF(e,t){return function(r,o,i){return e(r,o,i)&&t(r,o,i)}}function Ob(e){return function(n,r,o){if(!n||!r||typeof n!="object"||typeof r!="object")return e(n,r,o);var i=o.cache,a=i.get(n),s=i.get(r);if(a&&s)return a===r&&s===n;i.set(n,r),i.set(r,n);var l=e(n,r,o);return i.delete(n),i.delete(r),l}}function EF(e){return wVe(e).concat(SVe(e))}var jW=Object.hasOwn||function(e,t){return TVe.call(e,t)};function ld(e,t){return e===t||!e&&!t&&e!==e&&t!==t}var LW="_owner",CF=Object.getOwnPropertyDescriptor,MF=Object.keys;function xVe(e,t,n){var r=e.length;if(t.length!==r)return!1;for(;r-- >0;)if(!n.equals(e[r],t[r],r,r,e,t,n))return!1;return!0}function IVe(e,t){return ld(e.getTime(),t.getTime())}function kVe(e,t){return e.name===t.name&&e.message===t.message&&e.cause===t.cause&&e.stack===t.stack}function EVe(e,t){return e===t}function DF(e,t,n){var r=e.size;if(r!==t.size)return!1;if(!r)return!0;for(var o=new Array(r),i=e.entries(),a,s,l=0;(a=i.next())&&!a.done;){for(var u=t.entries(),d=!1,h=0;(s=u.next())&&!s.done;){if(o[h]){h++;continue}var p=a.value,m=s.value;if(n.equals(p[0],m[0],l,h,e,t,n)&&n.equals(p[1],m[1],p[0],m[0],e,t,n)){d=o[h]=!0;break}h++}if(!d)return!1;l++}return!0}var CVe=ld;function MVe(e,t,n){var r=MF(e),o=r.length;if(MF(t).length!==o)return!1;for(var i;o-- >0;)if(i=r[o],i===LW&&(e.$$typeof||t.$$typeof)&&e.$$typeof!==t.$$typeof||!jW(t,i)||!n.equals(e[i],t[i],i,i,e,t,n))return!1;return!0}function $p(e,t,n){var r=EF(e),o=r.length;if(EF(t).length!==o)return!1;for(var i,a,s;o-- >0;)if(i=r[o],i===LW&&(e.$$typeof||t.$$typeof)&&e.$$typeof!==t.$$typeof||!jW(t,i)||!n.equals(e[i],t[i],i,i,e,t,n)||(a=CF(e,i),s=CF(t,i),(a||s)&&(!a||!s||a.configurable!==s.configurable||a.enumerable!==s.enumerable||a.writable!==s.writable)))return!1;return!0}function DVe(e,t){return ld(e.valueOf(),t.valueOf())}function AVe(e,t){return e.source===t.source&&e.flags===t.flags}function AF(e,t,n){var r=e.size;if(r!==t.size)return!1;if(!r)return!0;for(var o=new Array(r),i=e.values(),a,s;(a=i.next())&&!a.done;){for(var l=t.values(),u=!1,d=0;(s=l.next())&&!s.done;){if(!o[d]&&n.equals(a.value,s.value,a.value,s.value,e,t,n)){u=o[d]=!0;break}d++}if(!u)return!1}return!0}function NVe(e,t){var n=e.length;if(t.length!==n)return!1;for(;n-- >0;)if(e[n]!==t[n])return!1;return!0}function OVe(e,t){return e.hostname===t.hostname&&e.pathname===t.pathname&&e.protocol===t.protocol&&e.port===t.port&&e.hash===t.hash&&e.username===t.username&&e.password===t.password}var PVe="[object Arguments]",jVe="[object Boolean]",LVe="[object Date]",RVe="[object Error]",FVe="[object Map]",HVe="[object Number]",_Ve="[object Object]",BVe="[object RegExp]",YVe="[object Set]",UVe="[object String]",zVe="[object URL]",VVe=Array.isArray,NF=typeof ArrayBuffer=="function"&&ArrayBuffer.isView?ArrayBuffer.isView:null,OF=Object.assign,WVe=Object.prototype.toString.call.bind(Object.prototype.toString);function GVe(e){var t=e.areArraysEqual,n=e.areDatesEqual,r=e.areErrorsEqual,o=e.areFunctionsEqual,i=e.areMapsEqual,a=e.areNumbersEqual,s=e.areObjectsEqual,l=e.arePrimitiveWrappersEqual,u=e.areRegExpsEqual,d=e.areSetsEqual,h=e.areTypedArraysEqual,p=e.areUrlsEqual;return function(b,v,y){if(b===v)return!0;if(b==null||v==null)return!1;var S=typeof b;if(S!==typeof v)return!1;if(S!=="object")return S==="number"?a(b,v,y):S==="function"?o(b,v,y):!1;var x=b.constructor;if(x!==v.constructor)return!1;if(x===Object)return s(b,v,y);if(VVe(b))return t(b,v,y);if(NF!=null&&NF(b))return h(b,v,y);if(x===Date)return n(b,v,y);if(x===RegExp)return u(b,v,y);if(x===Map)return i(b,v,y);if(x===Set)return d(b,v,y);var C=WVe(b);return C===LVe?n(b,v,y):C===BVe?u(b,v,y):C===FVe?i(b,v,y):C===YVe?d(b,v,y):C===_Ve?typeof b.then!="function"&&typeof v.then!="function"&&s(b,v,y):C===zVe?p(b,v,y):C===RVe?r(b,v,y):C===PVe?s(b,v,y):C===jVe||C===HVe||C===UVe?l(b,v,y):!1}}function ZVe(e){var t=e.circular,n=e.createCustomConfig,r=e.strict,o={areArraysEqual:r?$p:xVe,areDatesEqual:IVe,areErrorsEqual:kVe,areFunctionsEqual:EVe,areMapsEqual:r?kF(DF,$p):DF,areNumbersEqual:CVe,areObjectsEqual:r?$p:MVe,arePrimitiveWrappersEqual:DVe,areRegExpsEqual:AVe,areSetsEqual:r?kF(AF,$p):AF,areTypedArraysEqual:r?$p:NVe,areUrlsEqual:OVe};if(n&&(o=OF({},o,n(o))),t){var i=Ob(o.areArraysEqual),a=Ob(o.areMapsEqual),s=Ob(o.areObjectsEqual),l=Ob(o.areSetsEqual);o=OF({},o,{areArraysEqual:i,areMapsEqual:a,areObjectsEqual:s,areSetsEqual:l})}return o}function $Ve(e){return function(t,n,r,o,i,a,s){return e(t,n,s)}}function qVe(e){var t=e.circular,n=e.comparator,r=e.createState,o=e.equals,i=e.strict;if(r)return function(l,u){var d=r(),h=d.cache,p=h===void 0?t?new WeakMap:void 0:h,m=d.meta;return n(l,u,{cache:p,equals:o,meta:m,strict:i})};if(t)return function(l,u){return n(l,u,{cache:new WeakMap,equals:o,meta:void 0,strict:i})};var a={cache:void 0,equals:o,meta:void 0,strict:i};return function(l,u){return n(l,u,a)}}var KVe=Oc();Oc({strict:!0});Oc({circular:!0});Oc({circular:!0,strict:!0});Oc({createInternalComparator:function(){return ld}});Oc({strict:!0,createInternalComparator:function(){return ld}});Oc({circular:!0,createInternalComparator:function(){return ld}});Oc({circular:!0,createInternalComparator:function(){return ld},strict:!0});function Oc(e){e===void 0&&(e={});var t=e.circular,n=t===void 0?!1:t,r=e.createInternalComparator,o=e.createState,i=e.strict,a=i===void 0?!1:i,s=ZVe(e),l=GVe(s),u=r?r(l):$Ve(l);return qVe({circular:n,comparator:l,createState:o,equals:u,strict:a})}function XVe(e){typeof requestAnimationFrame<"u"&&requestAnimationFrame(e)}function PF(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=-1,r=function o(i){n<0&&(n=i),i-n>t?(e(i),n=-1):XVe(o)};requestAnimationFrame(r)}function tM(e){"@babel/helpers - typeof";return tM=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},tM(e)}function JVe(e){return nWe(e)||tWe(e)||eWe(e)||QVe()}function QVe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function eWe(e,t){if(e){if(typeof e=="string")return jF(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return jF(e,t)}}function jF(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function tWe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function nWe(e){if(Array.isArray(e))return e}function rWe(){var e={},t=function(){return null},n=!1,r=function o(i){if(!n){if(Array.isArray(i)){if(!i.length)return;var a=i,s=JVe(a),l=s[0],u=s.slice(1);if(typeof l=="number"){PF(o.bind(null,u),l);return}o(l),PF(o.bind(null,u));return}tM(i)==="object"&&(e=i,t(e)),typeof i=="function"&&i()}};return{stop:function(){n=!0},start:function(i){n=!1,r(i)},subscribe:function(i){return t=i,function(){t=function(){return null}}}}}function Ag(e){"@babel/helpers - typeof";return Ag=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ag(e)}function LF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function RF(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?LF(Object(n),!0).forEach(function(r){RW(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):LF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function RW(e,t,n){return t=oWe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function oWe(e){var t=iWe(e,"string");return Ag(t)==="symbol"?t:String(t)}function iWe(e,t){if(Ag(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Ag(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var aWe=function(t,n){return[Object.keys(t),Object.keys(n)].reduce(function(r,o){return r.filter(function(i){return o.includes(i)})})},sWe=function(t){return t},lWe=function(t){return t.replace(/([A-Z])/g,function(n){return"-".concat(n.toLowerCase())})},Mm=function(t,n){return Object.keys(n).reduce(function(r,o){return RF(RF({},r),{},RW({},o,t(o,n[o])))},{})},FF=function(t,n,r){return t.map(function(o){return"".concat(lWe(o)," ").concat(n,"ms ").concat(r)}).join(",")};function cWe(e,t){return fWe(e)||dWe(e,t)||FW(e,t)||uWe()}function uWe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function dWe(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(d){u=!0,o=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}function fWe(e){if(Array.isArray(e))return e}function hWe(e){return gWe(e)||mWe(e)||FW(e)||pWe()}function pWe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function FW(e,t){if(e){if(typeof e=="string")return nM(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return nM(e,t)}}function mWe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function gWe(e){if(Array.isArray(e))return nM(e)}function nM(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var _w=1e-4,HW=function(t,n){return[0,3*t,3*n-6*t,3*t-3*n+1]},_W=function(t,n){return t.map(function(r,o){return r*Math.pow(n,o)}).reduce(function(r,o){return r+o})},HF=function(t,n){return function(r){var o=HW(t,n);return _W(o,r)}},vWe=function(t,n){return function(r){var o=HW(t,n),i=[].concat(hWe(o.map(function(a,s){return a*s}).slice(1)),[0]);return _W(i,r)}},_F=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=n[0],i=n[1],a=n[2],s=n[3];if(n.length===1)switch(n[0]){case"linear":o=0,i=0,a=1,s=1;break;case"ease":o=.25,i=.1,a=.25,s=1;break;case"ease-in":o=.42,i=0,a=1,s=1;break;case"ease-out":o=.42,i=0,a=.58,s=1;break;case"ease-in-out":o=0,i=0,a=.58,s=1;break;default:var l=n[0].split("(");if(l[0]==="cubic-bezier"&&l[1].split(")")[0].split(",").length===4){var u=l[1].split(")")[0].split(",").map(function(y){return parseFloat(y)}),d=cWe(u,4);o=d[0],i=d[1],a=d[2],s=d[3]}}var h=HF(o,a),p=HF(i,s),m=vWe(o,a),b=function(S){return S>1?1:S<0?0:S},v=function(S){for(var x=S>1?1:S,C=x,k=0;k<8;++k){var M=h(C)-x,I=m(C);if(Math.abs(M-x)<_w||I<_w)return p(C);C=b(C-M/I)}return p(C)};return v.isStepper=!1,v},yWe=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.stiff,r=n===void 0?100:n,o=t.damping,i=o===void 0?8:o,a=t.dt,s=a===void 0?17:a,l=function(d,h,p){var m=-(d-h)*r,b=p*i,v=p+(m-b)*s/1e3,y=p*s/1e3+d;return Math.abs(y-h)<_w&&Math.abs(v)<_w?[h,0]:[y,v]};return l.isStepper=!0,l.dt=s,l},bWe=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=n[0];if(typeof o=="string")switch(o){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return _F(o);case"spring":return yWe();default:if(o.split("(")[0]==="cubic-bezier")return _F(o)}return typeof o=="function"?o:null};function Ng(e){"@babel/helpers - typeof";return Ng=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ng(e)}function BF(e){return TWe(e)||SWe(e)||BW(e)||wWe()}function wWe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function SWe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function TWe(e){if(Array.isArray(e))return oM(e)}function YF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function jr(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?YF(Object(n),!0).forEach(function(r){rM(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):YF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function rM(e,t,n){return t=xWe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xWe(e){var t=IWe(e,"string");return Ng(t)==="symbol"?t:String(t)}function IWe(e,t){if(Ng(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Ng(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function kWe(e,t){return MWe(e)||CWe(e,t)||BW(e,t)||EWe()}function EWe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function BW(e,t){if(e){if(typeof e=="string")return oM(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return oM(e,t)}}function oM(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function CWe(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(d){u=!0,o=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}function MWe(e){if(Array.isArray(e))return e}var Bw=function(t,n,r){return t+(n-t)*r},iM=function(t){var n=t.from,r=t.to;return n!==r},DWe=function e(t,n,r){var o=Mm(function(i,a){if(iM(a)){var s=t(a.from,a.to,a.velocity),l=kWe(s,2),u=l[0],d=l[1];return jr(jr({},a),{},{from:u,velocity:d})}return a},n);return r<1?Mm(function(i,a){return iM(a)?jr(jr({},a),{},{velocity:Bw(a.velocity,o[i].velocity,r),from:Bw(a.from,o[i].from,r)}):a},n):e(t,o,r-1)};const AWe=function(e,t,n,r,o){var i=aWe(e,t),a=i.reduce(function(y,S){return jr(jr({},y),{},rM({},S,[e[S],t[S]]))},{}),s=i.reduce(function(y,S){return jr(jr({},y),{},rM({},S,{from:e[S],velocity:0,to:t[S]}))},{}),l=-1,u,d,h=function(){return null},p=function(){return Mm(function(S,x){return x.from},s)},m=function(){return!Object.values(s).filter(iM).length},b=function(S){u||(u=S);var x=S-u,C=x/n.dt;s=DWe(n,s,C),o(jr(jr(jr({},e),t),p())),u=S,m()||(l=requestAnimationFrame(h))},v=function(S){d||(d=S);var x=(S-d)/r,C=Mm(function(M,I){return Bw.apply(void 0,BF(I).concat([n(x)]))},a);if(o(jr(jr(jr({},e),t),C)),x<1)l=requestAnimationFrame(h);else{var k=Mm(function(M,I){return Bw.apply(void 0,BF(I).concat([n(1)]))},a);o(jr(jr(jr({},e),t),k))}};return h=n.isStepper?b:v,function(){return requestAnimationFrame(h),function(){cancelAnimationFrame(l)}}};function qf(e){"@babel/helpers - typeof";return qf=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},qf(e)}var NWe=["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"];function OWe(e,t){if(e==null)return{};var n=PWe(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function PWe(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function Dk(e){return FWe(e)||RWe(e)||LWe(e)||jWe()}function jWe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function LWe(e,t){if(e){if(typeof e=="string")return aM(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return aM(e,t)}}function RWe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function FWe(e){if(Array.isArray(e))return aM(e)}function aM(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function UF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function ia(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?UF(Object(n),!0).forEach(function(r){im(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):UF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function im(e,t,n){return t=YW(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function HWe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function zF(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,YW(r.key),r)}}function _We(e,t,n){return t&&zF(e.prototype,t),n&&zF(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function YW(e){var t=BWe(e,"string");return qf(t)==="symbol"?t:String(t)}function BWe(e,t){if(qf(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(qf(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function YWe(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&sM(e,t)}function sM(e,t){return sM=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},sM(e,t)}function UWe(e){var t=zWe();return function(){var r=Yw(e),o;if(t){var i=Yw(this).constructor;o=Reflect.construct(r,arguments,i)}else o=r.apply(this,arguments);return lM(this,o)}}function lM(e,t){if(t&&(qf(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return cM(e)}function cM(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function zWe(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Yw(e){return Yw=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Yw(e)}var VT=function(e){YWe(n,e);var t=UWe(n);function n(r,o){var i;HWe(this,n),i=t.call(this,r,o);var a=i.props,s=a.isActive,l=a.attributeName,u=a.from,d=a.to,h=a.steps,p=a.children,m=a.duration;if(i.handleStyleChange=i.handleStyleChange.bind(cM(i)),i.changeStyle=i.changeStyle.bind(cM(i)),!s||m<=0)return i.state={style:{}},typeof p=="function"&&(i.state={style:d}),lM(i);if(h&&h.length)i.state={style:h[0].style};else if(u){if(typeof p=="function")return i.state={style:u},lM(i);i.state={style:l?im({},l,u):u}}else i.state={style:{}};return i}return _We(n,[{key:"componentDidMount",value:function(){var o=this.props,i=o.isActive,a=o.canBegin;this.mounted=!0,!(!i||!a)&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(o){var i=this.props,a=i.isActive,s=i.canBegin,l=i.attributeName,u=i.shouldReAnimate,d=i.to,h=i.from,p=this.state.style;if(s){if(!a){var m={style:l?im({},l,d):d};this.state&&p&&(l&&p[l]!==d||!l&&p!==d)&&this.setState(m);return}if(!(KVe(o.to,d)&&o.canBegin&&o.isActive)){var b=!o.canBegin||!o.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var v=b||u?h:o.to;if(this.state&&p){var y={style:l?im({},l,v):v};(l&&p[l]!==v||!l&&p!==v)&&this.setState(y)}this.runAnimation(ia(ia({},this.props),{},{from:v,begin:0}))}}}},{key:"componentWillUnmount",value:function(){this.mounted=!1;var o=this.props.onAnimationEnd;this.unSubscribe&&this.unSubscribe(),this.manager&&(this.manager.stop(),this.manager=null),this.stopJSAnimation&&this.stopJSAnimation(),o&&o()}},{key:"handleStyleChange",value:function(o){this.changeStyle(o)}},{key:"changeStyle",value:function(o){this.mounted&&this.setState({style:o})}},{key:"runJSAnimation",value:function(o){var i=this,a=o.from,s=o.to,l=o.duration,u=o.easing,d=o.begin,h=o.onAnimationEnd,p=o.onAnimationStart,m=AWe(a,s,bWe(u),l,this.changeStyle),b=function(){i.stopJSAnimation=m()};this.manager.start([p,d,b,l,h])}},{key:"runStepAnimation",value:function(o){var i=this,a=o.steps,s=o.begin,l=o.onAnimationStart,u=a[0],d=u.style,h=u.duration,p=h===void 0?0:h,m=function(v,y,S){if(S===0)return v;var x=y.duration,C=y.easing,k=C===void 0?"ease":C,M=y.style,I=y.properties,O=y.onAnimationEnd,R=S>0?a[S-1]:y,L=I||Object.keys(M);if(typeof k=="function"||k==="spring")return[].concat(Dk(v),[i.runJSAnimation.bind(i,{from:R.style,to:M,duration:x,easing:k}),x]);var B=FF(L,x,k),_=ia(ia(ia({},R.style),M),{},{transition:B});return[].concat(Dk(v),[_,x,O]).filter(sWe)};return this.manager.start([l].concat(Dk(a.reduce(m,[d,Math.max(p,s)])),[o.onAnimationEnd]))}},{key:"runAnimation",value:function(o){this.manager||(this.manager=rWe());var i=o.begin,a=o.duration,s=o.attributeName,l=o.to,u=o.easing,d=o.onAnimationStart,h=o.onAnimationEnd,p=o.steps,m=o.children,b=this.manager;if(this.unSubscribe=b.subscribe(this.handleStyleChange),typeof u=="function"||typeof m=="function"||u==="spring"){this.runJSAnimation(o);return}if(p.length>1){this.runStepAnimation(o);return}var v=s?im({},s,l):l,y=FF(Object.keys(v),a,u);b.start([d,i,ia(ia({},v),{},{transition:y}),a,h])}},{key:"render",value:function(){var o=this.props,i=o.children;o.begin;var a=o.duration;o.attributeName,o.easing;var s=o.isActive;o.steps,o.from,o.to,o.canBegin,o.onAnimationEnd,o.shouldReAnimate,o.onAnimationReStart;var l=OWe(o,NWe),u=D.Children.count(i),d=this.state.style;if(typeof i=="function")return i(d);if(!s||u===0||a<=0)return i;var h=function(m){var b=m.props,v=b.style,y=v===void 0?{}:v,S=b.className,x=D.cloneElement(m,ia(ia({},l),{},{style:ia(ia({},y),d),className:S}));return x};return u===1?h(D.Children.only(i)):Y.createElement("div",null,D.Children.map(i,function(p){return h(p)}))}}]),n}(D.PureComponent);VT.displayName="Animate";VT.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}};VT.propTypes={from:pe.oneOfType([pe.object,pe.string]),to:pe.oneOfType([pe.object,pe.string]),attributeName:pe.string,duration:pe.number,begin:pe.number,easing:pe.oneOfType([pe.string,pe.func]),steps:pe.arrayOf(pe.shape({duration:pe.number.isRequired,style:pe.object.isRequired,easing:pe.oneOfType([pe.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),pe.func]),properties:pe.arrayOf("string"),onAnimationEnd:pe.func})),children:pe.oneOfType([pe.node,pe.func]),isActive:pe.bool,canBegin:pe.bool,onAnimationEnd:pe.func,shouldReAnimate:pe.bool,onAnimationStart:pe.func,onAnimationReStart:pe.func};const Kf=VT;function Og(e){"@babel/helpers - typeof";return Og=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Og(e)}function Uw(){return Uw=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Uw.apply(this,arguments)}function VWe(e,t){return $We(e)||ZWe(e,t)||GWe(e,t)||WWe()}function WWe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function GWe(e,t){if(e){if(typeof e=="string")return VF(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return VF(e,t)}}function VF(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function ZWe(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(d){u=!0,o=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}function $We(e){if(Array.isArray(e))return e}function WF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function GF(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?WF(Object(n),!0).forEach(function(r){qWe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):WF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function qWe(e,t,n){return t=KWe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function KWe(e){var t=XWe(e,"string");return Og(t)=="symbol"?t:t+""}function XWe(e,t){if(Og(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Og(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var ZF=function(t,n,r,o,i){var a=Math.min(Math.abs(r)/2,Math.abs(o)/2),s=o>=0?1:-1,l=r>=0?1:-1,u=o>=0&&r>=0||o<0&&r<0?1:0,d;if(a>0&&i instanceof Array){for(var h=[0,0,0,0],p=0,m=4;p<m;p++)h[p]=i[p]>a?a:i[p];d="M".concat(t,",").concat(n+s*h[0]),h[0]>0&&(d+="A ".concat(h[0],",").concat(h[0],",0,0,").concat(u,",").concat(t+l*h[0],",").concat(n)),d+="L ".concat(t+r-l*h[1],",").concat(n),h[1]>0&&(d+="A ".concat(h[1],",").concat(h[1],",0,0,").concat(u,`,
|
|
|
`).concat(t+r,",").concat(n+s*h[1])),d+="L ".concat(t+r,",").concat(n+o-s*h[2]),h[2]>0&&(d+="A ".concat(h[2],",").concat(h[2],",0,0,").concat(u,`,
|
|
|
`).concat(t+r-l*h[2],",").concat(n+o)),d+="L ".concat(t+l*h[3],",").concat(n+o),h[3]>0&&(d+="A ".concat(h[3],",").concat(h[3],",0,0,").concat(u,`,
|
|
|
`).concat(t,",").concat(n+o-s*h[3])),d+="Z"}else if(a>0&&i===+i&&i>0){var b=Math.min(a,i);d="M ".concat(t,",").concat(n+s*b,`
|
|
|
A `).concat(b,",").concat(b,",0,0,").concat(u,",").concat(t+l*b,",").concat(n,`
|
|
|
L `).concat(t+r-l*b,",").concat(n,`
|
|
|
A `).concat(b,",").concat(b,",0,0,").concat(u,",").concat(t+r,",").concat(n+s*b,`
|
|
|
L `).concat(t+r,",").concat(n+o-s*b,`
|
|
|
A `).concat(b,",").concat(b,",0,0,").concat(u,",").concat(t+r-l*b,",").concat(n+o,`
|
|
|
L `).concat(t+l*b,",").concat(n+o,`
|
|
|
A `).concat(b,",").concat(b,",0,0,").concat(u,",").concat(t,",").concat(n+o-s*b," Z")}else d="M ".concat(t,",").concat(n," h ").concat(r," v ").concat(o," h ").concat(-r," Z");return d},JWe=function(t,n){if(!t||!n)return!1;var r=t.x,o=t.y,i=n.x,a=n.y,s=n.width,l=n.height;if(Math.abs(s)>0&&Math.abs(l)>0){var u=Math.min(i,i+s),d=Math.max(i,i+s),h=Math.min(a,a+l),p=Math.max(a,a+l);return r>=u&&r<=d&&o>=h&&o<=p}return!1},QWe={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},uN=function(t){var n=GF(GF({},QWe),t),r=D.useRef(),o=D.useState(-1),i=VWe(o,2),a=i[0],s=i[1];D.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var k=r.current.getTotalLength();k&&s(k)}catch{}},[]);var l=n.x,u=n.y,d=n.width,h=n.height,p=n.radius,m=n.className,b=n.animationEasing,v=n.animationDuration,y=n.animationBegin,S=n.isAnimationActive,x=n.isUpdateAnimationActive;if(l!==+l||u!==+u||d!==+d||h!==+h||d===0||h===0)return null;var C=$t("recharts-rectangle",m);return x?Y.createElement(Kf,{canBegin:a>0,from:{width:d,height:h,x:l,y:u},to:{width:d,height:h,x:l,y:u},duration:v,animationEasing:b,isActive:x},function(k){var M=k.width,I=k.height,O=k.x,R=k.y;return Y.createElement(Kf,{canBegin:a>0,from:"0px ".concat(a===-1?1:a,"px"),to:"".concat(a,"px 0px"),attributeName:"strokeDasharray",begin:y,duration:v,isActive:S,easing:b},Y.createElement("path",Uw({},_t(n,!0),{className:C,d:ZF(O,R,M,I,p),ref:r})))}):Y.createElement("path",Uw({},_t(n,!0),{className:C,d:ZF(l,u,d,h,p)}))};function uM(){return uM=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},uM.apply(this,arguments)}var dN=function(t){var n=t.cx,r=t.cy,o=t.r,i=t.className,a=$t("recharts-dot",i);return n===+n&&r===+r&&o===+o?Y.createElement("circle",uM({},_t(t,!1),uw(t),{className:a,cx:n,cy:r,r:o})):null};function Pg(e){"@babel/helpers - typeof";return Pg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Pg(e)}var eGe=["x","y","top","left","width","height","className"];function dM(){return dM=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},dM.apply(this,arguments)}function $F(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function tGe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$F(Object(n),!0).forEach(function(r){nGe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$F(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function nGe(e,t,n){return t=rGe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function rGe(e){var t=oGe(e,"string");return Pg(t)=="symbol"?t:t+""}function oGe(e,t){if(Pg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Pg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function iGe(e,t){if(e==null)return{};var n=aGe(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function aGe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var sGe=function(t,n,r,o,i,a){return"M".concat(t,",").concat(i,"v").concat(o,"M").concat(a,",").concat(n,"h").concat(r)},lGe=function(t){var n=t.x,r=n===void 0?0:n,o=t.y,i=o===void 0?0:o,a=t.top,s=a===void 0?0:a,l=t.left,u=l===void 0?0:l,d=t.width,h=d===void 0?0:d,p=t.height,m=p===void 0?0:p,b=t.className,v=iGe(t,eGe),y=tGe({x:r,y:i,top:s,left:u,width:h,height:m},v);return!Je(r)||!Je(i)||!Je(h)||!Je(m)||!Je(s)||!Je(u)?null:Y.createElement("path",dM({},_t(y,!0),{className:$t("recharts-cross",b),d:sGe(r,i,h,m,s,u)}))},cGe=kl,uGe=xa,dGe="[object Boolean]";function fGe(e){return e===!0||e===!1||uGe(e)&&cGe(e)==dGe}var hGe=fGe;const pGe=tt(hGe);function jg(e){"@babel/helpers - typeof";return jg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},jg(e)}function zw(){return zw=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},zw.apply(this,arguments)}function mGe(e,t){return bGe(e)||yGe(e,t)||vGe(e,t)||gGe()}function gGe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function vGe(e,t){if(e){if(typeof e=="string")return qF(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return qF(e,t)}}function qF(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function yGe(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(d){u=!0,o=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}function bGe(e){if(Array.isArray(e))return e}function KF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function XF(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?KF(Object(n),!0).forEach(function(r){wGe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):KF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function wGe(e,t,n){return t=SGe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function SGe(e){var t=TGe(e,"string");return jg(t)=="symbol"?t:t+""}function TGe(e,t){if(jg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(jg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var JF=function(t,n,r,o,i){var a=r-o,s;return s="M ".concat(t,",").concat(n),s+="L ".concat(t+r,",").concat(n),s+="L ".concat(t+r-a/2,",").concat(n+i),s+="L ".concat(t+r-a/2-o,",").concat(n+i),s+="L ".concat(t,",").concat(n," Z"),s},xGe={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},IGe=function(t){var n=XF(XF({},xGe),t),r=D.useRef(),o=D.useState(-1),i=mGe(o,2),a=i[0],s=i[1];D.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var C=r.current.getTotalLength();C&&s(C)}catch{}},[]);var l=n.x,u=n.y,d=n.upperWidth,h=n.lowerWidth,p=n.height,m=n.className,b=n.animationEasing,v=n.animationDuration,y=n.animationBegin,S=n.isUpdateAnimationActive;if(l!==+l||u!==+u||d!==+d||h!==+h||p!==+p||d===0&&h===0||p===0)return null;var x=$t("recharts-trapezoid",m);return S?Y.createElement(Kf,{canBegin:a>0,from:{upperWidth:0,lowerWidth:0,height:p,x:l,y:u},to:{upperWidth:d,lowerWidth:h,height:p,x:l,y:u},duration:v,animationEasing:b,isActive:S},function(C){var k=C.upperWidth,M=C.lowerWidth,I=C.height,O=C.x,R=C.y;return Y.createElement(Kf,{canBegin:a>0,from:"0px ".concat(a===-1?1:a,"px"),to:"".concat(a,"px 0px"),attributeName:"strokeDasharray",begin:y,duration:v,easing:b},Y.createElement("path",zw({},_t(n,!0),{className:x,d:JF(O,R,k,M,I),ref:r})))}):Y.createElement("g",null,Y.createElement("path",zw({},_t(n,!0),{className:x,d:JF(l,u,d,h,p)})))},kGe=["option","shapeType","propTransformer","activeClassName","isActive"];function Lg(e){"@babel/helpers - typeof";return Lg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Lg(e)}function EGe(e,t){if(e==null)return{};var n=CGe(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function CGe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function QF(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Vw(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?QF(Object(n),!0).forEach(function(r){MGe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):QF(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function MGe(e,t,n){return t=DGe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function DGe(e){var t=AGe(e,"string");return Lg(t)=="symbol"?t:t+""}function AGe(e,t){if(Lg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Lg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function NGe(e,t){return Vw(Vw({},t),e)}function OGe(e,t){return e==="symbols"}function e6(e){var t=e.shapeType,n=e.elementProps;switch(t){case"rectangle":return Y.createElement(uN,n);case"trapezoid":return Y.createElement(IGe,n);case"sector":return Y.createElement(PW,n);case"symbols":if(OGe(t))return Y.createElement(RA,n);break;default:return null}}function PGe(e){return D.isValidElement(e)?e.props:e}function jGe(e){var t=e.option,n=e.shapeType,r=e.propTransformer,o=r===void 0?NGe:r,i=e.activeClassName,a=i===void 0?"recharts-active-shape":i,s=e.isActive,l=EGe(e,kGe),u;if(D.isValidElement(t))u=D.cloneElement(t,Vw(Vw({},l),PGe(t)));else if(Pt(t))u=t(l);else if(dye(t)&&!pGe(t)){var d=o(t,l);u=Y.createElement(e6,{shapeType:n,elementProps:d})}else{var h=l;u=Y.createElement(e6,{shapeType:n,elementProps:h})}return s?Y.createElement(Xn,{className:a},u):u}function WT(e,t){return t!=null&&"trapezoids"in e.props}function GT(e,t){return t!=null&&"sectors"in e.props}function Rg(e,t){return t!=null&&"points"in e.props}function LGe(e,t){var n,r,o=e.x===(t==null||(n=t.labelViewBox)===null||n===void 0?void 0:n.x)||e.x===t.x,i=e.y===(t==null||(r=t.labelViewBox)===null||r===void 0?void 0:r.y)||e.y===t.y;return o&&i}function RGe(e,t){var n=e.endAngle===t.endAngle,r=e.startAngle===t.startAngle;return n&&r}function FGe(e,t){var n=e.x===t.x,r=e.y===t.y,o=e.z===t.z;return n&&r&&o}function HGe(e,t){var n;return WT(e,t)?n=LGe:GT(e,t)?n=RGe:Rg(e,t)&&(n=FGe),n}function _Ge(e,t){var n;return WT(e,t)?n="trapezoids":GT(e,t)?n="sectors":Rg(e,t)&&(n="points"),n}function BGe(e,t){if(WT(e,t)){var n;return(n=t.tooltipPayload)===null||n===void 0||(n=n[0])===null||n===void 0||(n=n.payload)===null||n===void 0?void 0:n.payload}if(GT(e,t)){var r;return(r=t.tooltipPayload)===null||r===void 0||(r=r[0])===null||r===void 0||(r=r.payload)===null||r===void 0?void 0:r.payload}return Rg(e,t)?t.payload:{}}function YGe(e){var t=e.activeTooltipItem,n=e.graphicalItem,r=e.itemData,o=_Ge(n,t),i=BGe(n,t),a=r.filter(function(l,u){var d=ws(i,l),h=n.props[o].filter(function(b){var v=HGe(n,t);return v(b,t)}),p=n.props[o].indexOf(h[h.length-1]),m=u===p;return d&&m}),s=r.indexOf(a[a.length-1]);return s}function Fg(e){"@babel/helpers - typeof";return Fg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Fg(e)}function t6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function n6(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?t6(Object(n),!0).forEach(function(r){UW(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):t6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function UW(e,t,n){return t=UGe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function UGe(e){var t=zGe(e,"string");return Fg(t)=="symbol"?t:t+""}function zGe(e,t){if(Fg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Fg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var VGe=["Webkit","Moz","O","ms"],WGe=function(t,n){if(!t)return null;var r=t.replace(/(\w)/,function(i){return i.toUpperCase()}),o=VGe.reduce(function(i,a){return n6(n6({},i),{},UW({},a+r,n))},{});return o[t]=n,o};function Xf(e){"@babel/helpers - typeof";return Xf=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Xf(e)}function Ww(){return Ww=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ww.apply(this,arguments)}function r6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Ak(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?r6(Object(n),!0).forEach(function(r){ni(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function GGe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o6(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,VW(r.key),r)}}function ZGe(e,t,n){return t&&o6(e.prototype,t),n&&o6(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function $Ge(e,t,n){return t=Gw(t),qGe(e,zW()?Reflect.construct(t,n||[],Gw(e).constructor):t.apply(e,n))}function qGe(e,t){if(t&&(Xf(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return KGe(e)}function KGe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function zW(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(zW=function(){return!!e})()}function Gw(e){return Gw=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Gw(e)}function XGe(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&fM(e,t)}function fM(e,t){return fM=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},fM(e,t)}function ni(e,t,n){return t=VW(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function VW(e){var t=JGe(e,"string");return Xf(t)=="symbol"?t:t+""}function JGe(e,t){if(Xf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Xf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var QGe=function(t){var n=t.data,r=t.startIndex,o=t.endIndex,i=t.x,a=t.width,s=t.travellerWidth;if(!n||!n.length)return{};var l=n.length,u=Em().domain(Km(0,l)).range([i,i+a-s]),d=u.domain().map(function(h){return u(h)});return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:u(r),endX:u(o),scale:u,scaleValues:d}},i6=function(t){return t.changedTouches&&!!t.changedTouches.length},Jf=function(e){function t(n){var r;return GGe(this,t),r=$Ge(this,t,[n]),ni(r,"handleDrag",function(o){r.leaveTimer&&(clearTimeout(r.leaveTimer),r.leaveTimer=null),r.state.isTravellerMoving?r.handleTravellerMove(o):r.state.isSlideMoving&&r.handleSlideDrag(o)}),ni(r,"handleTouchMove",function(o){o.changedTouches!=null&&o.changedTouches.length>0&&r.handleDrag(o.changedTouches[0])}),ni(r,"handleDragEnd",function(){r.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var o=r.props,i=o.endIndex,a=o.onDragEnd,s=o.startIndex;a?.({endIndex:i,startIndex:s})}),r.detachDragEndListener()}),ni(r,"handleLeaveWrapper",function(){(r.state.isTravellerMoving||r.state.isSlideMoving)&&(r.leaveTimer=window.setTimeout(r.handleDragEnd,r.props.leaveTimeOut))}),ni(r,"handleEnterSlideOrTraveller",function(){r.setState({isTextActive:!0})}),ni(r,"handleLeaveSlideOrTraveller",function(){r.setState({isTextActive:!1})}),ni(r,"handleSlideDragStart",function(o){var i=i6(o)?o.changedTouches[0]:o;r.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:i.pageX}),r.attachDragEndListener()}),r.travellerDragStartHandlers={startX:r.handleTravellerDragStart.bind(r,"startX"),endX:r.handleTravellerDragStart.bind(r,"endX")},r.state={},r}return XGe(t,e),ZGe(t,[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(r){var o=r.startX,i=r.endX,a=this.state.scaleValues,s=this.props,l=s.gap,u=s.data,d=u.length-1,h=Math.min(o,i),p=Math.max(o,i),m=t.getIndexInRange(a,h),b=t.getIndexInRange(a,p);return{startIndex:m-m%l,endIndex:b===d?d:b-b%l}}},{key:"getTextOfTick",value:function(r){var o=this.props,i=o.data,a=o.tickFormatter,s=o.dataKey,l=gi(i[r],s,r);return Pt(a)?a(l,r):l}},{key:"attachDragEndListener",value:function(){window.addEventListener("mouseup",this.handleDragEnd,!0),window.addEventListener("touchend",this.handleDragEnd,!0),window.addEventListener("mousemove",this.handleDrag,!0)}},{key:"detachDragEndListener",value:function(){window.removeEventListener("mouseup",this.handleDragEnd,!0),window.removeEventListener("touchend",this.handleDragEnd,!0),window.removeEventListener("mousemove",this.handleDrag,!0)}},{key:"handleSlideDrag",value:function(r){var o=this.state,i=o.slideMoveStartX,a=o.startX,s=o.endX,l=this.props,u=l.x,d=l.width,h=l.travellerWidth,p=l.startIndex,m=l.endIndex,b=l.onChange,v=r.pageX-i;v>0?v=Math.min(v,u+d-h-s,u+d-h-a):v<0&&(v=Math.max(v,u-a,u-s));var y=this.getIndex({startX:a+v,endX:s+v});(y.startIndex!==p||y.endIndex!==m)&&b&&b(y),this.setState({startX:a+v,endX:s+v,slideMoveStartX:r.pageX})}},{key:"handleTravellerDragStart",value:function(r,o){var i=i6(o)?o.changedTouches[0]:o;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:r,brushMoveStartX:i.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(r){var o=this.state,i=o.brushMoveStartX,a=o.movingTravellerId,s=o.endX,l=o.startX,u=this.state[a],d=this.props,h=d.x,p=d.width,m=d.travellerWidth,b=d.onChange,v=d.gap,y=d.data,S={startX:this.state.startX,endX:this.state.endX},x=r.pageX-i;x>0?x=Math.min(x,h+p-m-u):x<0&&(x=Math.max(x,h-u)),S[a]=u+x;var C=this.getIndex(S),k=C.startIndex,M=C.endIndex,I=function(){var R=y.length-1;return a==="startX"&&(s>l?k%v===0:M%v===0)||s<l&&M===R||a==="endX"&&(s>l?M%v===0:k%v===0)||s>l&&M===R};this.setState(ni(ni({},a,u+x),"brushMoveStartX",r.pageX),function(){b&&I()&&b(C)})}},{key:"handleTravellerMoveKeyboard",value:function(r,o){var i=this,a=this.state,s=a.scaleValues,l=a.startX,u=a.endX,d=this.state[o],h=s.indexOf(d);if(h!==-1){var p=h+r;if(!(p===-1||p>=s.length)){var m=s[p];o==="startX"&&m>=u||o==="endX"&&m<=l||this.setState(ni({},o,m),function(){i.props.onChange(i.getIndex({startX:i.state.startX,endX:i.state.endX}))})}}}},{key:"renderBackground",value:function(){var r=this.props,o=r.x,i=r.y,a=r.width,s=r.height,l=r.fill,u=r.stroke;return Y.createElement("rect",{stroke:u,fill:l,x:o,y:i,width:a,height:s})}},{key:"renderPanorama",value:function(){var r=this.props,o=r.x,i=r.y,a=r.width,s=r.height,l=r.data,u=r.children,d=r.padding,h=D.Children.only(u);return h?Y.cloneElement(h,{x:o,y:i,width:a,height:s,margin:d,compact:!0,data:l}):null}},{key:"renderTravellerLayer",value:function(r,o){var i,a,s=this,l=this.props,u=l.y,d=l.travellerWidth,h=l.height,p=l.traveller,m=l.ariaLabel,b=l.data,v=l.startIndex,y=l.endIndex,S=Math.max(r,this.props.x),x=Ak(Ak({},_t(this.props,!1)),{},{x:S,y:u,width:d,height:h}),C=m||"Min value: ".concat((i=b[v])===null||i===void 0?void 0:i.name,", Max value: ").concat((a=b[y])===null||a===void 0?void 0:a.name);return Y.createElement(Xn,{tabIndex:0,role:"slider","aria-label":C,"aria-valuenow":r,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[o],onTouchStart:this.travellerDragStartHandlers[o],onKeyDown:function(M){["ArrowLeft","ArrowRight"].includes(M.key)&&(M.preventDefault(),M.stopPropagation(),s.handleTravellerMoveKeyboard(M.key==="ArrowRight"?1:-1,o))},onFocus:function(){s.setState({isTravellerFocused:!0})},onBlur:function(){s.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},t.renderTraveller(p,x))}},{key:"renderSlide",value:function(r,o){var i=this.props,a=i.y,s=i.height,l=i.stroke,u=i.travellerWidth,d=Math.min(r,o)+u,h=Math.max(Math.abs(o-r)-u,0);return Y.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:l,fillOpacity:.2,x:d,y:a,width:h,height:s})}},{key:"renderText",value:function(){var r=this.props,o=r.startIndex,i=r.endIndex,a=r.y,s=r.height,l=r.travellerWidth,u=r.stroke,d=this.state,h=d.startX,p=d.endX,m=5,b={pointerEvents:"none",fill:u};return Y.createElement(Xn,{className:"recharts-brush-texts"},Y.createElement(Tw,Ww({textAnchor:"end",verticalAnchor:"middle",x:Math.min(h,p)-m,y:a+s/2},b),this.getTextOfTick(o)),Y.createElement(Tw,Ww({textAnchor:"start",verticalAnchor:"middle",x:Math.max(h,p)+l+m,y:a+s/2},b),this.getTextOfTick(i)))}},{key:"render",value:function(){var r=this.props,o=r.data,i=r.className,a=r.children,s=r.x,l=r.y,u=r.width,d=r.height,h=r.alwaysShowText,p=this.state,m=p.startX,b=p.endX,v=p.isTextActive,y=p.isSlideMoving,S=p.isTravellerMoving,x=p.isTravellerFocused;if(!o||!o.length||!Je(s)||!Je(l)||!Je(u)||!Je(d)||u<=0||d<=0)return null;var C=$t("recharts-brush",i),k=Y.Children.count(a)===1,M=WGe("userSelect","none");return Y.createElement(Xn,{className:C,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:M},this.renderBackground(),k&&this.renderPanorama(),this.renderSlide(m,b),this.renderTravellerLayer(m,"startX"),this.renderTravellerLayer(b,"endX"),(v||y||S||x||h)&&this.renderText())}}],[{key:"renderDefaultTraveller",value:function(r){var o=r.x,i=r.y,a=r.width,s=r.height,l=r.stroke,u=Math.floor(i+s/2)-1;return Y.createElement(Y.Fragment,null,Y.createElement("rect",{x:o,y:i,width:a,height:s,fill:l,stroke:"none"}),Y.createElement("line",{x1:o+1,y1:u,x2:o+a-1,y2:u,fill:"none",stroke:"#fff"}),Y.createElement("line",{x1:o+1,y1:u+2,x2:o+a-1,y2:u+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(r,o){var i;return Y.isValidElement(r)?i=Y.cloneElement(r,o):Pt(r)?i=r(o):i=t.renderDefaultTraveller(o),i}},{key:"getDerivedStateFromProps",value:function(r,o){var i=r.data,a=r.width,s=r.x,l=r.travellerWidth,u=r.updateId,d=r.startIndex,h=r.endIndex;if(i!==o.prevData||u!==o.prevUpdateId)return Ak({prevData:i,prevTravellerWidth:l,prevUpdateId:u,prevX:s,prevWidth:a},i&&i.length?QGe({data:i,width:a,x:s,travellerWidth:l,startIndex:d,endIndex:h}):{scale:null,scaleValues:null});if(o.scale&&(a!==o.prevWidth||s!==o.prevX||l!==o.prevTravellerWidth)){o.scale.range([s,s+a-l]);var p=o.scale.domain().map(function(m){return o.scale(m)});return{prevData:i,prevTravellerWidth:l,prevUpdateId:u,prevX:s,prevWidth:a,startX:o.scale(r.startIndex),endX:o.scale(r.endIndex),scaleValues:p}}return null}},{key:"getIndexInRange",value:function(r,o){for(var i=r.length,a=0,s=i-1;s-a>1;){var l=Math.floor((a+s)/2);r[l]>o?s=l:a=l}return o>=r[s]?s:a}}])}(D.PureComponent);ni(Jf,"displayName","Brush");ni(Jf,"defaultProps",{height:40,travellerWidth:5,gap:1,fill:"#fff",stroke:"#666",padding:{top:1,right:1,bottom:1,left:1},leaveTimeOut:1e3,alwaysShowText:!1});var eZe=RD;function tZe(e,t){var n;return eZe(e,function(r,o,i){return n=t(r,o,i),!n}),!!n}var nZe=tZe,rZe=l7,oZe=El,iZe=nZe,aZe=Hr,sZe=Mh;function lZe(e,t,n){var r=aZe(e)?rZe:iZe;return n&&sZe(e,t,n)&&(t=void 0),r(e,oZe(t))}var cZe=lZe;const uZe=tt(cZe);var vs=function(t,n){var r=t.alwaysShow,o=t.ifOverflow;return r&&(o="extendDomain"),o===n};function dZe(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0}var fZe=dZe,hZe=RD;function pZe(e,t){var n=!0;return hZe(e,function(r,o,i){return n=!!t(r,o,i),n}),n}var mZe=pZe,gZe=fZe,vZe=mZe,yZe=El,bZe=Hr,wZe=Mh;function SZe(e,t,n){var r=bZe(e)?gZe:vZe;return n&&wZe(e,t,n)&&(t=void 0),r(e,yZe(t))}var TZe=SZe;const WW=tt(TZe);var xZe=["x","y"];function Hg(e){"@babel/helpers - typeof";return Hg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Hg(e)}function hM(){return hM=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},hM.apply(this,arguments)}function a6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function qp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?a6(Object(n),!0).forEach(function(r){IZe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function IZe(e,t,n){return t=kZe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function kZe(e){var t=EZe(e,"string");return Hg(t)=="symbol"?t:t+""}function EZe(e,t){if(Hg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Hg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function CZe(e,t){if(e==null)return{};var n=MZe(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function MZe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function DZe(e,t){var n=e.x,r=e.y,o=CZe(e,xZe),i="".concat(n),a=parseInt(i,10),s="".concat(r),l=parseInt(s,10),u="".concat(t.height||o.height),d=parseInt(u,10),h="".concat(t.width||o.width),p=parseInt(h,10);return qp(qp(qp(qp(qp({},t),o),a?{x:a}:{}),l?{y:l}:{}),{},{height:d,width:p,name:t.name,radius:t.radius})}function s6(e){return Y.createElement(jGe,hM({shapeType:"rectangle",propTransformer:DZe,activeClassName:"recharts-active-bar"},e))}var AZe=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return function(r,o){if(typeof t=="number")return t;var i=typeof r=="number";return i?t(r,o):(i||qu(!1),n)}},NZe=["value","background"],GW;function Qf(e){"@babel/helpers - typeof";return Qf=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Qf(e)}function OZe(e,t){if(e==null)return{};var n=PZe(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function PZe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Zw(){return Zw=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Zw.apply(this,arguments)}function l6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function nr(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?l6(Object(n),!0).forEach(function(r){fc(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function jZe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c6(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,$W(r.key),r)}}function LZe(e,t,n){return t&&c6(e.prototype,t),n&&c6(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function RZe(e,t,n){return t=$w(t),FZe(e,ZW()?Reflect.construct(t,n||[],$w(e).constructor):t.apply(e,n))}function FZe(e,t){if(t&&(Qf(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return HZe(e)}function HZe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ZW(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(ZW=function(){return!!e})()}function $w(e){return $w=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},$w(e)}function _Ze(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&pM(e,t)}function pM(e,t){return pM=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},pM(e,t)}function fc(e,t,n){return t=$W(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $W(e){var t=BZe(e,"string");return Qf(t)=="symbol"?t:t+""}function BZe(e,t){if(Qf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Qf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var ys=function(e){function t(){var n;jZe(this,t);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return n=RZe(this,t,[].concat(o)),fc(n,"state",{isAnimationFinished:!1}),fc(n,"id",Bv("recharts-bar-")),fc(n,"handleAnimationEnd",function(){var a=n.props.onAnimationEnd;n.setState({isAnimationFinished:!0}),a&&a()}),fc(n,"handleAnimationStart",function(){var a=n.props.onAnimationStart;n.setState({isAnimationFinished:!1}),a&&a()}),n}return _Ze(t,e),LZe(t,[{key:"renderRectanglesStatically",value:function(r){var o=this,i=this.props,a=i.shape,s=i.dataKey,l=i.activeIndex,u=i.activeBar,d=_t(this.props,!1);return r&&r.map(function(h,p){var m=p===l,b=m?u:a,v=nr(nr(nr({},d),h),{},{isActive:m,option:b,index:p,dataKey:s,onAnimationStart:o.handleAnimationStart,onAnimationEnd:o.handleAnimationEnd});return Y.createElement(Xn,Zw({className:"recharts-bar-rectangle"},dw(o.props,h,p),{key:"rectangle-".concat(h?.x,"-").concat(h?.y,"-").concat(h?.value)}),Y.createElement(s6,v))})}},{key:"renderRectanglesWithAnimation",value:function(){var r=this,o=this.props,i=o.data,a=o.layout,s=o.isAnimationActive,l=o.animationBegin,u=o.animationDuration,d=o.animationEasing,h=o.animationId,p=this.state.prevData;return Y.createElement(Kf,{begin:l,duration:u,isActive:s,easing:d,from:{t:0},to:{t:1},key:"bar-".concat(h),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(m){var b=m.t,v=i.map(function(y,S){var x=p&&p[S];if(x){var C=fa(x.x,y.x),k=fa(x.y,y.y),M=fa(x.width,y.width),I=fa(x.height,y.height);return nr(nr({},y),{},{x:C(b),y:k(b),width:M(b),height:I(b)})}if(a==="horizontal"){var O=fa(0,y.height),R=O(b);return nr(nr({},y),{},{y:y.y+y.height-R,height:R})}var L=fa(0,y.width),B=L(b);return nr(nr({},y),{},{width:B})});return Y.createElement(Xn,null,r.renderRectanglesStatically(v))})}},{key:"renderRectangles",value:function(){var r=this.props,o=r.data,i=r.isAnimationActive,a=this.state.prevData;return i&&o&&o.length&&(!a||!ws(a,o))?this.renderRectanglesWithAnimation():this.renderRectanglesStatically(o)}},{key:"renderBackground",value:function(){var r=this,o=this.props,i=o.data,a=o.dataKey,s=o.activeIndex,l=_t(this.props.background,!1);return i.map(function(u,d){u.value;var h=u.background,p=OZe(u,NZe);if(!h)return null;var m=nr(nr(nr(nr(nr({},p),{},{fill:"#eee"},h),l),dw(r.props,u,d)),{},{onAnimationStart:r.handleAnimationStart,onAnimationEnd:r.handleAnimationEnd,dataKey:a,index:d,className:"recharts-bar-background-rectangle"});return Y.createElement(s6,Zw({key:"background-bar-".concat(d),option:r.props.background,isActive:d===s},m))})}},{key:"renderErrorBar",value:function(r,o){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var i=this.props,a=i.data,s=i.xAxis,l=i.yAxis,u=i.layout,d=i.children,h=Ri(d,Wv);if(!h)return null;var p=u==="vertical"?a[0].height/2:a[0].width/2,m=function(y,S){var x=Array.isArray(y.value)?y.value[1]:y.value;return{x:y.x,y:y.y,value:x,errorVal:gi(y,S)}},b={clipPath:r?"url(#clipPath-".concat(o,")"):null};return Y.createElement(Xn,b,h.map(function(v){return Y.cloneElement(v,{key:"error-bar-".concat(o,"-").concat(v.props.dataKey),data:a,xAxis:s,yAxis:l,layout:u,offset:p,dataPointFormatter:m})}))}},{key:"render",value:function(){var r=this.props,o=r.hide,i=r.data,a=r.className,s=r.xAxis,l=r.yAxis,u=r.left,d=r.top,h=r.width,p=r.height,m=r.isAnimationActive,b=r.background,v=r.id;if(o||!i||!i.length)return null;var y=this.state.isAnimationFinished,S=$t("recharts-bar",a),x=s&&s.allowDataOverflow,C=l&&l.allowDataOverflow,k=x||C,M=Ht(v)?this.id:v;return Y.createElement(Xn,{className:S},x||C?Y.createElement("defs",null,Y.createElement("clipPath",{id:"clipPath-".concat(M)},Y.createElement("rect",{x:x?u:u-h/2,y:C?d:d-p/2,width:x?h:h*2,height:C?p:p*2}))):null,Y.createElement(Xn,{className:"recharts-bar-rectangles",clipPath:k?"url(#clipPath-".concat(M,")"):null},b?this.renderBackground():null,this.renderRectangles()),this.renderErrorBar(k,M),(!m||y)&&bc.renderCallByParent(this.props,i))}}],[{key:"getDerivedStateFromProps",value:function(r,o){return r.animationId!==o.prevAnimationId?{prevAnimationId:r.animationId,curData:r.data,prevData:o.curData}:r.data!==o.curData?{curData:r.data}:null}}])}(D.PureComponent);GW=ys;fc(ys,"displayName","Bar");fc(ys,"defaultProps",{xAxisId:0,yAxisId:0,legendType:"rect",minPointSize:0,hide:!1,data:[],layout:"vertical",activeBar:!1,isAnimationActive:!dl.isSsr,animationBegin:0,animationDuration:400,animationEasing:"ease"});fc(ys,"getComposedData",function(e){var t=e.props,n=e.item,r=e.barPosition,o=e.bandSize,i=e.xAxis,a=e.yAxis,s=e.xAxisTicks,l=e.yAxisTicks,u=e.stackedData,d=e.dataStartIndex,h=e.displayedData,p=e.offset,m=dze(r,n);if(!m)return null;var b=t.layout,v=n.type.defaultProps,y=v!==void 0?nr(nr({},v),n.props):n.props,S=y.dataKey,x=y.children,C=y.minPointSize,k=b==="horizontal"?a:i,M=u?k.scale.domain():null,I=bze({numericAxis:k}),O=Ri(x,IV),R=h.map(function(L,B){var _,H,U,G,K,z;u?_=fze(u[d+B],M):(_=gi(L,S),Array.isArray(_)||(_=[I,_]));var ne=AZe(C,GW.defaultProps.minPointSize)(_[1],B);if(b==="horizontal"){var J,ee=[a.scale(_[0]),a.scale(_[1])],Z=ee[0],q=ee[1];H=cF({axis:i,ticks:s,bandSize:o,offset:m.offset,entry:L,index:B}),U=(J=q??Z)!==null&&J!==void 0?J:void 0,G=m.size;var $=Z-q;if(K=Number.isNaN($)?0:$,z={x:H,y:a.y,width:G,height:a.height},Math.abs(ne)>0&&Math.abs(K)<Math.abs(ne)){var re=ga(K||ne)*(Math.abs(ne)-Math.abs(K));U-=re,K+=re}}else{var le=[i.scale(_[0]),i.scale(_[1])],ie=le[0],fe=le[1];if(H=ie,U=cF({axis:a,ticks:l,bandSize:o,offset:m.offset,entry:L,index:B}),G=fe-ie,K=m.size,z={x:i.x,y:U,width:i.width,height:K},Math.abs(ne)>0&&Math.abs(G)<Math.abs(ne)){var ye=ga(G||ne)*(Math.abs(ne)-Math.abs(G));G+=ye}}return nr(nr(nr({},L),{},{x:H,y:U,width:G,height:K,value:u?_:_[1],payload:L,background:z},O&&O[B]&&O[B].props),{},{tooltipPayload:[AW(n,L)],tooltipPosition:{x:H+G/2,y:U+K/2}})});return nr({data:R,layout:b},p)});function _g(e){"@babel/helpers - typeof";return _g=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_g(e)}function YZe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u6(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,qW(r.key),r)}}function UZe(e,t,n){return t&&u6(e.prototype,t),n&&u6(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function d6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function la(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?d6(Object(n),!0).forEach(function(r){ZT(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):d6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ZT(e,t,n){return t=qW(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function qW(e){var t=zZe(e,"string");return _g(t)=="symbol"?t:t+""}function zZe(e,t){if(_g(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(_g(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var KW=function(t,n,r,o,i){var a=t.width,s=t.height,l=t.layout,u=t.children,d=Object.keys(n),h={left:r.left,leftMirror:r.left,right:a-r.right,rightMirror:a-r.right,top:r.top,topMirror:r.top,bottom:s-r.bottom,bottomMirror:s-r.bottom},p=!!ai(u,ys);return d.reduce(function(m,b){var v=n[b],y=v.orientation,S=v.domain,x=v.padding,C=x===void 0?{}:x,k=v.mirror,M=v.reversed,I="".concat(y).concat(k?"Mirror":""),O,R,L,B,_;if(v.type==="number"&&(v.padding==="gap"||v.padding==="no-gap")){var H=S[1]-S[0],U=1/0,G=v.categoricalDomain.sort();if(G.forEach(function(le,ie){ie>0&&(U=Math.min((le||0)-(G[ie-1]||0),U))}),Number.isFinite(U)){var K=U/H,z=v.layout==="vertical"?r.height:r.width;if(v.padding==="gap"&&(O=K*z/2),v.padding==="no-gap"){var ne=Zu(t.barCategoryGap,K*z),J=K*z/2;O=J-ne-(J-ne)/z*ne}}}o==="xAxis"?R=[r.left+(C.left||0)+(O||0),r.left+r.width-(C.right||0)-(O||0)]:o==="yAxis"?R=l==="horizontal"?[r.top+r.height-(C.bottom||0),r.top+(C.top||0)]:[r.top+(C.top||0)+(O||0),r.top+r.height-(C.bottom||0)-(O||0)]:R=v.range,M&&(R=[R[1],R[0]]);var ee=cze(v,i,p),Z=ee.scale,q=ee.realScaleType;Z.domain(S).range(R),uze(Z);var $=yze(Z,la(la({},v),{},{realScaleType:q}));o==="xAxis"?(_=y==="top"&&!k||y==="bottom"&&k,L=r.left,B=h[I]-_*v.height):o==="yAxis"&&(_=y==="left"&&!k||y==="right"&&k,L=h[I]-_*v.width,B=r.top);var re=la(la(la({},v),$),{},{realScaleType:q,x:L,y:B,scale:Z,width:o==="xAxis"?r.width:v.width,height:o==="yAxis"?r.height:v.height});return re.bandSize=Rw(re,$),!v.hide&&o==="xAxis"?h[I]+=(_?-1:1)*re.height:v.hide||(h[I]+=(_?-1:1)*re.width),la(la({},m),{},ZT({},b,re))},{})},XW=function(t,n){var r=t.x,o=t.y,i=n.x,a=n.y;return{x:Math.min(r,i),y:Math.min(o,a),width:Math.abs(i-r),height:Math.abs(a-o)}},VZe=function(t){var n=t.x1,r=t.y1,o=t.x2,i=t.y2;return XW({x:n,y:r},{x:o,y:i})},JW=function(){function e(t){YZe(this,e),this.scale=t}return UZe(e,[{key:"domain",get:function(){return this.scale.domain}},{key:"range",get:function(){return this.scale.range}},{key:"rangeMin",get:function(){return this.range()[0]}},{key:"rangeMax",get:function(){return this.range()[1]}},{key:"bandwidth",get:function(){return this.scale.bandwidth}},{key:"apply",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=r.bandAware,i=r.position;if(n!==void 0){if(i)switch(i){case"start":return this.scale(n);case"middle":var a=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+a;case"end":var s=this.bandwidth?this.bandwidth():0;return this.scale(n)+s;default:return this.scale(n)}if(o){var l=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+l}return this.scale(n)}}},{key:"isInRange",value:function(n){var r=this.range(),o=r[0],i=r[r.length-1];return o<=i?n>=o&&n<=i:n>=i&&n<=o}}],[{key:"create",value:function(n){return new e(n)}}])}();ZT(JW,"EPS",1e-4);var fN=function(t){var n=Object.keys(t).reduce(function(r,o){return la(la({},r),{},ZT({},o,JW.create(t[o])))},{});return la(la({},n),{},{apply:function(o){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=i.bandAware,s=i.position;return x_(o,function(l,u){return n[u].apply(l,{bandAware:a,position:s})})},isInRange:function(o){return WW(o,function(i,a){return n[a].isInRange(i)})}})};function WZe(e){return(e%180+180)%180}var GZe=function(t){var n=t.width,r=t.height,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,i=WZe(o),a=i*Math.PI/180,s=Math.atan(r/n),l=a>s&&a<Math.PI-s?r/Math.sin(a):n/Math.cos(a);return Math.abs(l)},ZZe=El,$Ze=Qu,qZe=kh;function KZe(e){return function(t,n,r){var o=Object(t);if(!$Ze(t)){var i=ZZe(n);t=qZe(t),n=function(s){return i(o[s],s,o)}}var a=e(t,n,r);return a>-1?o[i?t[a]:a]:void 0}}var XZe=KZe,JZe=XZe,QZe=n_,e$e=JZe(QZe),t$e=e$e;const n$e=tt(t$e);var r$e=Rde(function(e){return{x:e.left,y:e.top,width:e.width,height:e.height}},function(e){return["l",e.left,"t",e.top,"w",e.width,"h",e.height].join("")}),hN=D.createContext(void 0),pN=D.createContext(void 0),QW=D.createContext(void 0),eG=D.createContext({}),tG=D.createContext(void 0),nG=D.createContext(0),rG=D.createContext(0),f6=function(t){var n=t.state,r=n.xAxisMap,o=n.yAxisMap,i=n.offset,a=t.clipPathId,s=t.children,l=t.width,u=t.height,d=r$e(i);return Y.createElement(hN.Provider,{value:r},Y.createElement(pN.Provider,{value:o},Y.createElement(eG.Provider,{value:i},Y.createElement(QW.Provider,{value:d},Y.createElement(tG.Provider,{value:a},Y.createElement(nG.Provider,{value:u},Y.createElement(rG.Provider,{value:l},s)))))))},o$e=function(){return D.useContext(tG)},oG=function(t){var n=D.useContext(hN);n==null&&qu(!1);var r=n[t];return r==null&&qu(!1),r},i$e=function(){var t=D.useContext(hN);return cc(t)},a$e=function(){var t=D.useContext(pN),n=n$e(t,function(r){return WW(r.domain,Number.isFinite)});return n||cc(t)},iG=function(t){var n=D.useContext(pN);n==null&&qu(!1);var r=n[t];return r==null&&qu(!1),r},s$e=function(){var t=D.useContext(QW);return t},l$e=function(){return D.useContext(eG)},mN=function(){return D.useContext(rG)},gN=function(){return D.useContext(nG)};function eh(e){"@babel/helpers - typeof";return eh=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},eh(e)}function c$e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function h6(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,sG(r.key),r)}}function u$e(e,t,n){return t&&h6(e.prototype,t),n&&h6(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function d$e(e,t,n){return t=qw(t),f$e(e,aG()?Reflect.construct(t,n||[],qw(e).constructor):t.apply(e,n))}function f$e(e,t){if(t&&(eh(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return h$e(e)}function h$e(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function aG(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(aG=function(){return!!e})()}function qw(e){return qw=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},qw(e)}function p$e(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&mM(e,t)}function mM(e,t){return mM=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},mM(e,t)}function p6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function m6(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?p6(Object(n),!0).forEach(function(r){vN(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function vN(e,t,n){return t=sG(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function sG(e){var t=m$e(e,"string");return eh(t)=="symbol"?t:t+""}function m$e(e,t){if(eh(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(eh(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function g$e(e,t){return w$e(e)||b$e(e,t)||y$e(e,t)||v$e()}function v$e(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function y$e(e,t){if(e){if(typeof e=="string")return g6(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return g6(e,t)}}function g6(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function b$e(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(d){u=!0,o=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}function w$e(e){if(Array.isArray(e))return e}function gM(){return gM=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},gM.apply(this,arguments)}var S$e=function(t,n){var r;return Y.isValidElement(t)?r=Y.cloneElement(t,n):Pt(t)?r=t(n):r=Y.createElement("line",gM({},n,{className:"recharts-reference-line-line"})),r},T$e=function(t,n,r,o,i,a,s,l,u){var d=i.x,h=i.y,p=i.width,m=i.height;if(r){var b=u.y,v=t.y.apply(b,{position:a});if(vs(u,"discard")&&!t.y.isInRange(v))return null;var y=[{x:d+p,y:v},{x:d,y:v}];return l==="left"?y.reverse():y}if(n){var S=u.x,x=t.x.apply(S,{position:a});if(vs(u,"discard")&&!t.x.isInRange(x))return null;var C=[{x,y:h+m},{x,y:h}];return s==="top"?C.reverse():C}if(o){var k=u.segment,M=k.map(function(I){return t.apply(I,{position:a})});return vs(u,"discard")&&uZe(M,function(I){return!t.isInRange(I)})?null:M}return null};function x$e(e){var t=e.x,n=e.y,r=e.segment,o=e.xAxisId,i=e.yAxisId,a=e.shape,s=e.className,l=e.alwaysShow,u=o$e(),d=oG(o),h=iG(i),p=s$e();if(!u||!p)return null;ul(l===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var m=fN({x:d.scale,y:h.scale}),b=dr(t),v=dr(n),y=r&&r.length===2,S=T$e(m,b,v,y,p,e.position,d.orientation,h.orientation,e);if(!S)return null;var x=g$e(S,2),C=x[0],k=C.x,M=C.y,I=x[1],O=I.x,R=I.y,L=vs(e,"hidden")?"url(#".concat(u,")"):void 0,B=m6(m6({clipPath:L},_t(e,!0)),{},{x1:k,y1:M,x2:O,y2:R});return Y.createElement(Xn,{className:$t("recharts-reference-line",s)},S$e(a,B),no.renderCallByParent(e,VZe({x1:k,y1:M,x2:O,y2:R})))}var yN=function(e){function t(){return c$e(this,t),d$e(this,t,arguments)}return p$e(t,e),u$e(t,[{key:"render",value:function(){return Y.createElement(x$e,this.props)}}])}(Y.Component);vN(yN,"displayName","ReferenceLine");vN(yN,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,fill:"none",stroke:"#ccc",fillOpacity:1,strokeWidth:1,position:"middle"});function vM(){return vM=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},vM.apply(this,arguments)}function th(e){"@babel/helpers - typeof";return th=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},th(e)}function v6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function y6(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?v6(Object(n),!0).forEach(function(r){$T(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):v6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function I$e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function b6(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,cG(r.key),r)}}function k$e(e,t,n){return t&&b6(e.prototype,t),n&&b6(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function E$e(e,t,n){return t=Kw(t),C$e(e,lG()?Reflect.construct(t,n||[],Kw(e).constructor):t.apply(e,n))}function C$e(e,t){if(t&&(th(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return M$e(e)}function M$e(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function lG(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(lG=function(){return!!e})()}function Kw(e){return Kw=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Kw(e)}function D$e(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&yM(e,t)}function yM(e,t){return yM=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},yM(e,t)}function $T(e,t,n){return t=cG(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cG(e){var t=A$e(e,"string");return th(t)=="symbol"?t:t+""}function A$e(e,t){if(th(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(th(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var N$e=function(t){var n=t.x,r=t.y,o=t.xAxis,i=t.yAxis,a=fN({x:o.scale,y:i.scale}),s=a.apply({x:n,y:r},{bandAware:!0});return vs(t,"discard")&&!a.isInRange(s)?null:s},qT=function(e){function t(){return I$e(this,t),E$e(this,t,arguments)}return D$e(t,e),k$e(t,[{key:"render",value:function(){var r=this.props,o=r.x,i=r.y,a=r.r,s=r.alwaysShow,l=r.clipPathId,u=dr(o),d=dr(i);if(ul(s===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.'),!u||!d)return null;var h=N$e(this.props);if(!h)return null;var p=h.x,m=h.y,b=this.props,v=b.shape,y=b.className,S=vs(this.props,"hidden")?"url(#".concat(l,")"):void 0,x=y6(y6({clipPath:S},_t(this.props,!0)),{},{cx:p,cy:m});return Y.createElement(Xn,{className:$t("recharts-reference-dot",y)},t.renderDot(v,x),no.renderCallByParent(this.props,{x:p-a,y:m-a,width:2*a,height:2*a}))}}])}(Y.Component);$T(qT,"displayName","ReferenceDot");$T(qT,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#fff",stroke:"#ccc",fillOpacity:1,strokeWidth:1});$T(qT,"renderDot",function(e,t){var n;return Y.isValidElement(e)?n=Y.cloneElement(e,t):Pt(e)?n=e(t):n=Y.createElement(dN,vM({},t,{cx:t.cx,cy:t.cy,className:"recharts-reference-dot-dot"})),n});function bM(){return bM=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},bM.apply(this,arguments)}function nh(e){"@babel/helpers - typeof";return nh=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},nh(e)}function w6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function S6(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?w6(Object(n),!0).forEach(function(r){KT(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function O$e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function T6(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,dG(r.key),r)}}function P$e(e,t,n){return t&&T6(e.prototype,t),n&&T6(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function j$e(e,t,n){return t=Xw(t),L$e(e,uG()?Reflect.construct(t,n||[],Xw(e).constructor):t.apply(e,n))}function L$e(e,t){if(t&&(nh(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return R$e(e)}function R$e(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function uG(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(uG=function(){return!!e})()}function Xw(e){return Xw=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Xw(e)}function F$e(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&wM(e,t)}function wM(e,t){return wM=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},wM(e,t)}function KT(e,t,n){return t=dG(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function dG(e){var t=H$e(e,"string");return nh(t)=="symbol"?t:t+""}function H$e(e,t){if(nh(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(nh(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var _$e=function(t,n,r,o,i){var a=i.x1,s=i.x2,l=i.y1,u=i.y2,d=i.xAxis,h=i.yAxis;if(!d||!h)return null;var p=fN({x:d.scale,y:h.scale}),m={x:t?p.x.apply(a,{position:"start"}):p.x.rangeMin,y:r?p.y.apply(l,{position:"start"}):p.y.rangeMin},b={x:n?p.x.apply(s,{position:"end"}):p.x.rangeMax,y:o?p.y.apply(u,{position:"end"}):p.y.rangeMax};return vs(i,"discard")&&(!p.isInRange(m)||!p.isInRange(b))?null:XW(m,b)},XT=function(e){function t(){return O$e(this,t),j$e(this,t,arguments)}return F$e(t,e),P$e(t,[{key:"render",value:function(){var r=this.props,o=r.x1,i=r.x2,a=r.y1,s=r.y2,l=r.className,u=r.alwaysShow,d=r.clipPathId;ul(u===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var h=dr(o),p=dr(i),m=dr(a),b=dr(s),v=this.props.shape;if(!h&&!p&&!m&&!b&&!v)return null;var y=_$e(h,p,m,b,this.props);if(!y&&!v)return null;var S=vs(this.props,"hidden")?"url(#".concat(d,")"):void 0;return Y.createElement(Xn,{className:$t("recharts-reference-area",l)},t.renderRect(v,S6(S6({clipPath:S},_t(this.props,!0)),y)),no.renderCallByParent(this.props,y))}}])}(Y.Component);KT(XT,"displayName","ReferenceArea");KT(XT,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#ccc",fillOpacity:.5,stroke:"none",strokeWidth:1});KT(XT,"renderRect",function(e,t){var n;return Y.isValidElement(e)?n=Y.cloneElement(e,t):Pt(e)?n=e(t):n=Y.createElement(uN,bM({},t,{className:"recharts-reference-area-rect"})),n});function fG(e,t,n){if(t<1)return[];if(t===1&&n===void 0)return e;for(var r=[],o=0;o<e.length;o+=t)if(n===void 0||n(e[o])===!0)r.push(e[o]);else return;return r}function B$e(e,t,n){var r={width:e.width+t.width,height:e.height+t.height};return GZe(r,n)}function Y$e(e,t,n){var r=n==="width",o=e.x,i=e.y,a=e.width,s=e.height;return t===1?{start:r?o:i,end:r?o+a:i+s}:{start:r?o+a:i+s,end:r?o:i}}function Jw(e,t,n,r,o){if(e*t<e*r||e*t>e*o)return!1;var i=n();return e*(t-e*i/2-r)>=0&&e*(t+e*i/2-o)<=0}function U$e(e,t){return fG(e,t+1)}function z$e(e,t,n,r,o){for(var i=(r||[]).slice(),a=t.start,s=t.end,l=0,u=1,d=a,h=function(){var b=r?.[l];if(b===void 0)return{v:fG(r,u)};var v=l,y,S=function(){return y===void 0&&(y=n(b,v)),y},x=b.coordinate,C=l===0||Jw(e,x,S,d,s);C||(l=0,d=a,u+=1),C&&(d=x+e*(S()/2+o),l+=u)},p;u<=i.length;)if(p=h(),p)return p.v;return[]}function Bg(e){"@babel/helpers - typeof";return Bg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Bg(e)}function x6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function to(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?x6(Object(n),!0).forEach(function(r){V$e(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):x6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function V$e(e,t,n){return t=W$e(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function W$e(e){var t=G$e(e,"string");return Bg(t)=="symbol"?t:t+""}function G$e(e,t){if(Bg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Bg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Z$e(e,t,n,r,o){for(var i=(r||[]).slice(),a=i.length,s=t.start,l=t.end,u=function(p){var m=i[p],b,v=function(){return b===void 0&&(b=n(m,p)),b};if(p===a-1){var y=e*(m.coordinate+e*v()/2-l);i[p]=m=to(to({},m),{},{tickCoord:y>0?m.coordinate-y*e:m.coordinate})}else i[p]=m=to(to({},m),{},{tickCoord:m.coordinate});var S=Jw(e,m.tickCoord,v,s,l);S&&(l=m.tickCoord-e*(v()/2+o),i[p]=to(to({},m),{},{isShow:!0}))},d=a-1;d>=0;d--)u(d);return i}function $$e(e,t,n,r,o,i){var a=(r||[]).slice(),s=a.length,l=t.start,u=t.end;if(i){var d=r[s-1],h=n(d,s-1),p=e*(d.coordinate+e*h/2-u);a[s-1]=d=to(to({},d),{},{tickCoord:p>0?d.coordinate-p*e:d.coordinate});var m=Jw(e,d.tickCoord,function(){return h},l,u);m&&(u=d.tickCoord-e*(h/2+o),a[s-1]=to(to({},d),{},{isShow:!0}))}for(var b=i?s-1:s,v=function(x){var C=a[x],k,M=function(){return k===void 0&&(k=n(C,x)),k};if(x===0){var I=e*(C.coordinate-e*M()/2-l);a[x]=C=to(to({},C),{},{tickCoord:I<0?C.coordinate-I*e:C.coordinate})}else a[x]=C=to(to({},C),{},{tickCoord:C.coordinate});var O=Jw(e,C.tickCoord,M,l,u);O&&(l=C.tickCoord+e*(M()/2+o),a[x]=to(to({},C),{},{isShow:!0}))},y=0;y<b;y++)v(y);return a}function bN(e,t,n){var r=e.tick,o=e.ticks,i=e.viewBox,a=e.minTickGap,s=e.orientation,l=e.interval,u=e.tickFormatter,d=e.unit,h=e.angle;if(!o||!o.length||!r)return[];if(Je(l)||dl.isSsr)return U$e(o,typeof l=="number"&&Je(l)?l:0);var p=[],m=s==="top"||s==="bottom"?"width":"height",b=d&&m==="width"?km(d,{fontSize:t,letterSpacing:n}):{width:0,height:0},v=function(C,k){var M=Pt(u)?u(C.value,k):C.value;return m==="width"?B$e(km(M,{fontSize:t,letterSpacing:n}),b,h):km(M,{fontSize:t,letterSpacing:n})[m]},y=o.length>=2?ga(o[1].coordinate-o[0].coordinate):1,S=Y$e(i,y,m);return l==="equidistantPreserveStart"?z$e(y,S,v,o,a):(l==="preserveStart"||l==="preserveStartEnd"?p=$$e(y,S,v,o,a,l==="preserveStartEnd"):p=Z$e(y,S,v,o,a),p.filter(function(x){return x.isShow}))}var q$e=["viewBox"],K$e=["viewBox"],X$e=["ticks"];function rh(e){"@babel/helpers - typeof";return rh=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},rh(e)}function df(){return df=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},df.apply(this,arguments)}function I6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function ho(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?I6(Object(n),!0).forEach(function(r){wN(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):I6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Nk(e,t){if(e==null)return{};var n=J$e(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function J$e(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Q$e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function k6(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,pG(r.key),r)}}function eqe(e,t,n){return t&&k6(e.prototype,t),n&&k6(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function tqe(e,t,n){return t=Qw(t),nqe(e,hG()?Reflect.construct(t,n||[],Qw(e).constructor):t.apply(e,n))}function nqe(e,t){if(t&&(rh(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return rqe(e)}function rqe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function hG(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(hG=function(){return!!e})()}function Qw(e){return Qw=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Qw(e)}function oqe(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&SM(e,t)}function SM(e,t){return SM=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},SM(e,t)}function wN(e,t,n){return t=pG(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pG(e){var t=iqe(e,"string");return rh(t)=="symbol"?t:t+""}function iqe(e,t){if(rh(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(rh(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Zh=function(e){function t(n){var r;return Q$e(this,t),r=tqe(this,t,[n]),r.state={fontSize:"",letterSpacing:""},r}return oqe(t,e),eqe(t,[{key:"shouldComponentUpdate",value:function(r,o){var i=r.viewBox,a=Nk(r,q$e),s=this.props,l=s.viewBox,u=Nk(s,K$e);return!vf(i,l)||!vf(a,u)||!vf(o,this.state)}},{key:"componentDidMount",value:function(){var r=this.layerReference;if(r){var o=r.getElementsByClassName("recharts-cartesian-axis-tick-value")[0];o&&this.setState({fontSize:window.getComputedStyle(o).fontSize,letterSpacing:window.getComputedStyle(o).letterSpacing})}}},{key:"getTickLineCoord",value:function(r){var o=this.props,i=o.x,a=o.y,s=o.width,l=o.height,u=o.orientation,d=o.tickSize,h=o.mirror,p=o.tickMargin,m,b,v,y,S,x,C=h?-1:1,k=r.tickSize||d,M=Je(r.tickCoord)?r.tickCoord:r.coordinate;switch(u){case"top":m=b=r.coordinate,y=a+ +!h*l,v=y-C*k,x=v-C*p,S=M;break;case"left":v=y=r.coordinate,b=i+ +!h*s,m=b-C*k,S=m-C*p,x=M;break;case"right":v=y=r.coordinate,b=i+ +h*s,m=b+C*k,S=m+C*p,x=M;break;default:m=b=r.coordinate,y=a+ +h*l,v=y+C*k,x=v+C*p,S=M;break}return{line:{x1:m,y1:v,x2:b,y2:y},tick:{x:S,y:x}}}},{key:"getTickTextAnchor",value:function(){var r=this.props,o=r.orientation,i=r.mirror,a;switch(o){case"left":a=i?"start":"end";break;case"right":a=i?"end":"start";break;default:a="middle";break}return a}},{key:"getTickVerticalAnchor",value:function(){var r=this.props,o=r.orientation,i=r.mirror,a="end";switch(o){case"left":case"right":a="middle";break;case"top":a=i?"start":"end";break;default:a=i?"end":"start";break}return a}},{key:"renderAxisLine",value:function(){var r=this.props,o=r.x,i=r.y,a=r.width,s=r.height,l=r.orientation,u=r.mirror,d=r.axisLine,h=ho(ho(ho({},_t(this.props,!1)),_t(d,!1)),{},{fill:"none"});if(l==="top"||l==="bottom"){var p=+(l==="top"&&!u||l==="bottom"&&u);h=ho(ho({},h),{},{x1:o,y1:i+p*s,x2:o+a,y2:i+p*s})}else{var m=+(l==="left"&&!u||l==="right"&&u);h=ho(ho({},h),{},{x1:o+m*a,y1:i,x2:o+m*a,y2:i+s})}return Y.createElement("line",df({},h,{className:$t("recharts-cartesian-axis-line",Li(d,"className"))}))}},{key:"renderTicks",value:function(r,o,i){var a=this,s=this.props,l=s.tickLine,u=s.stroke,d=s.tick,h=s.tickFormatter,p=s.unit,m=bN(ho(ho({},this.props),{},{ticks:r}),o,i),b=this.getTickTextAnchor(),v=this.getTickVerticalAnchor(),y=_t(this.props,!1),S=_t(d,!1),x=ho(ho({},y),{},{fill:"none"},_t(l,!1)),C=m.map(function(k,M){var I=a.getTickLineCoord(k),O=I.line,R=I.tick,L=ho(ho(ho(ho({textAnchor:b,verticalAnchor:v},y),{},{stroke:"none",fill:u},S),R),{},{index:M,payload:k,visibleTicksCount:m.length,tickFormatter:h});return Y.createElement(Xn,df({className:"recharts-cartesian-axis-tick",key:"tick-".concat(k.value,"-").concat(k.coordinate,"-").concat(k.tickCoord)},dw(a.props,k,M)),l&&Y.createElement("line",df({},x,O,{className:$t("recharts-cartesian-axis-tick-line",Li(l,"className"))})),d&&t.renderTickItem(d,L,"".concat(Pt(h)?h(k.value,M):k.value).concat(p||"")))});return Y.createElement("g",{className:"recharts-cartesian-axis-ticks"},C)}},{key:"render",value:function(){var r=this,o=this.props,i=o.axisLine,a=o.width,s=o.height,l=o.ticksGenerator,u=o.className,d=o.hide;if(d)return null;var h=this.props,p=h.ticks,m=Nk(h,X$e),b=p;return Pt(l)&&(b=p&&p.length>0?l(this.props):l(m)),a<=0||s<=0||!b||!b.length?null:Y.createElement(Xn,{className:$t("recharts-cartesian-axis",u),ref:function(y){r.layerReference=y}},i&&this.renderAxisLine(),this.renderTicks(b,this.state.fontSize,this.state.letterSpacing),no.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(r,o,i){var a;return Y.isValidElement(r)?a=Y.cloneElement(r,o):Pt(r)?a=r(o):a=Y.createElement(Tw,df({},o,{className:"recharts-cartesian-axis-tick-value"}),i),a}}])}(D.Component);wN(Zh,"displayName","CartesianAxis");wN(Zh,"defaultProps",{x:0,y:0,width:0,height:0,viewBox:{x:0,y:0,width:0,height:0},orientation:"bottom",ticks:[],stroke:"#666",tickLine:!0,axisLine:!0,tick:!0,mirror:!1,minTickGap:5,tickSize:6,tickMargin:2,interval:"preserveEnd"});var aqe=["x1","y1","x2","y2","key"],sqe=["offset"];function Ku(e){"@babel/helpers - typeof";return Ku=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ku(e)}function E6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function ro(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?E6(Object(n),!0).forEach(function(r){lqe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):E6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function lqe(e,t,n){return t=cqe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cqe(e){var t=uqe(e,"string");return Ku(t)=="symbol"?t:t+""}function uqe(e,t){if(Ku(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Ku(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Eu(){return Eu=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Eu.apply(this,arguments)}function C6(e,t){if(e==null)return{};var n=dqe(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function dqe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var fqe=function(t){var n=t.fill;if(!n||n==="none")return null;var r=t.fillOpacity,o=t.x,i=t.y,a=t.width,s=t.height,l=t.ry;return Y.createElement("rect",{x:o,y:i,ry:l,width:a,height:s,stroke:"none",fill:n,fillOpacity:r,className:"recharts-cartesian-grid-bg"})};function mG(e,t){var n;if(Y.isValidElement(e))n=Y.cloneElement(e,t);else if(Pt(e))n=e(t);else{var r=t.x1,o=t.y1,i=t.x2,a=t.y2,s=t.key,l=C6(t,aqe),u=_t(l,!1);u.offset;var d=C6(u,sqe);n=Y.createElement("line",Eu({},d,{x1:r,y1:o,x2:i,y2:a,fill:"none",key:s}))}return n}function hqe(e){var t=e.x,n=e.width,r=e.horizontal,o=r===void 0?!0:r,i=e.horizontalPoints;if(!o||!i||!i.length)return null;var a=i.map(function(s,l){var u=ro(ro({},e),{},{x1:t,y1:s,x2:t+n,y2:s,key:"line-".concat(l),index:l});return mG(o,u)});return Y.createElement("g",{className:"recharts-cartesian-grid-horizontal"},a)}function pqe(e){var t=e.y,n=e.height,r=e.vertical,o=r===void 0?!0:r,i=e.verticalPoints;if(!o||!i||!i.length)return null;var a=i.map(function(s,l){var u=ro(ro({},e),{},{x1:s,y1:t,x2:s,y2:t+n,key:"line-".concat(l),index:l});return mG(o,u)});return Y.createElement("g",{className:"recharts-cartesian-grid-vertical"},a)}function mqe(e){var t=e.horizontalFill,n=e.fillOpacity,r=e.x,o=e.y,i=e.width,a=e.height,s=e.horizontalPoints,l=e.horizontal,u=l===void 0?!0:l;if(!u||!t||!t.length)return null;var d=s.map(function(p){return Math.round(p+o-o)}).sort(function(p,m){return p-m});o!==d[0]&&d.unshift(0);var h=d.map(function(p,m){var b=!d[m+1],v=b?o+a-p:d[m+1]-p;if(v<=0)return null;var y=m%t.length;return Y.createElement("rect",{key:"react-".concat(m),y:p,x:r,height:v,width:i,stroke:"none",fill:t[y],fillOpacity:n,className:"recharts-cartesian-grid-bg"})});return Y.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},h)}function gqe(e){var t=e.vertical,n=t===void 0?!0:t,r=e.verticalFill,o=e.fillOpacity,i=e.x,a=e.y,s=e.width,l=e.height,u=e.verticalPoints;if(!n||!r||!r.length)return null;var d=u.map(function(p){return Math.round(p+i-i)}).sort(function(p,m){return p-m});i!==d[0]&&d.unshift(0);var h=d.map(function(p,m){var b=!d[m+1],v=b?i+s-p:d[m+1]-p;if(v<=0)return null;var y=m%r.length;return Y.createElement("rect",{key:"react-".concat(m),x:p,y:a,width:v,height:l,stroke:"none",fill:r[y],fillOpacity:o,className:"recharts-cartesian-grid-bg"})});return Y.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},h)}var vqe=function(t,n){var r=t.xAxis,o=t.width,i=t.height,a=t.offset;return MW(bN(ro(ro(ro({},Zh.defaultProps),r),{},{ticks:nl(r,!0),viewBox:{x:0,y:0,width:o,height:i}})),a.left,a.left+a.width,n)},yqe=function(t,n){var r=t.yAxis,o=t.width,i=t.height,a=t.offset;return MW(bN(ro(ro(ro({},Zh.defaultProps),r),{},{ticks:nl(r,!0),viewBox:{x:0,y:0,width:o,height:i}})),a.top,a.top+a.height,n)},Xd={horizontal:!0,vertical:!0,horizontalPoints:[],verticalPoints:[],stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[]};function ff(e){var t,n,r,o,i,a,s=mN(),l=gN(),u=l$e(),d=ro(ro({},e),{},{stroke:(t=e.stroke)!==null&&t!==void 0?t:Xd.stroke,fill:(n=e.fill)!==null&&n!==void 0?n:Xd.fill,horizontal:(r=e.horizontal)!==null&&r!==void 0?r:Xd.horizontal,horizontalFill:(o=e.horizontalFill)!==null&&o!==void 0?o:Xd.horizontalFill,vertical:(i=e.vertical)!==null&&i!==void 0?i:Xd.vertical,verticalFill:(a=e.verticalFill)!==null&&a!==void 0?a:Xd.verticalFill,x:Je(e.x)?e.x:u.left,y:Je(e.y)?e.y:u.top,width:Je(e.width)?e.width:u.width,height:Je(e.height)?e.height:u.height}),h=d.x,p=d.y,m=d.width,b=d.height,v=d.syncWithTicks,y=d.horizontalValues,S=d.verticalValues,x=i$e(),C=a$e();if(!Je(m)||m<=0||!Je(b)||b<=0||!Je(h)||h!==+h||!Je(p)||p!==+p)return null;var k=d.verticalCoordinatesGenerator||vqe,M=d.horizontalCoordinatesGenerator||yqe,I=d.horizontalPoints,O=d.verticalPoints;if((!I||!I.length)&&Pt(M)){var R=y&&y.length,L=M({yAxis:C?ro(ro({},C),{},{ticks:R?y:C.ticks}):void 0,width:s,height:l,offset:u},R?!0:v);ul(Array.isArray(L),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(Ku(L),"]")),Array.isArray(L)&&(I=L)}if((!O||!O.length)&&Pt(k)){var B=S&&S.length,_=k({xAxis:x?ro(ro({},x),{},{ticks:B?S:x.ticks}):void 0,width:s,height:l,offset:u},B?!0:v);ul(Array.isArray(_),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(Ku(_),"]")),Array.isArray(_)&&(O=_)}return Y.createElement("g",{className:"recharts-cartesian-grid"},Y.createElement(fqe,{fill:d.fill,fillOpacity:d.fillOpacity,x:d.x,y:d.y,width:d.width,height:d.height,ry:d.ry}),Y.createElement(hqe,Eu({},d,{offset:u,horizontalPoints:I,xAxis:x,yAxis:C})),Y.createElement(pqe,Eu({},d,{offset:u,verticalPoints:O,xAxis:x,yAxis:C})),Y.createElement(mqe,Eu({},d,{horizontalPoints:I})),Y.createElement(gqe,Eu({},d,{verticalPoints:O})))}ff.displayName="CartesianGrid";var bqe=["type","layout","connectNulls","ref"],wqe=["key"];function oh(e){"@babel/helpers - typeof";return oh=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},oh(e)}function M6(e,t){if(e==null)return{};var n=Sqe(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Sqe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Dm(){return Dm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Dm.apply(this,arguments)}function D6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function ei(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?D6(Object(n),!0).forEach(function(r){ca(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):D6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Jd(e){return kqe(e)||Iqe(e)||xqe(e)||Tqe()}function Tqe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function xqe(e,t){if(e){if(typeof e=="string")return TM(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return TM(e,t)}}function Iqe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function kqe(e){if(Array.isArray(e))return TM(e)}function TM(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Eqe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function A6(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,vG(r.key),r)}}function Cqe(e,t,n){return t&&A6(e.prototype,t),n&&A6(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Mqe(e,t,n){return t=eS(t),Dqe(e,gG()?Reflect.construct(t,n||[],eS(e).constructor):t.apply(e,n))}function Dqe(e,t){if(t&&(oh(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Aqe(e)}function Aqe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function gG(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(gG=function(){return!!e})()}function eS(e){return eS=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},eS(e)}function Nqe(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&xM(e,t)}function xM(e,t){return xM=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},xM(e,t)}function ca(e,t,n){return t=vG(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function vG(e){var t=Oqe(e,"string");return oh(t)=="symbol"?t:t+""}function Oqe(e,t){if(oh(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(oh(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Gv=function(e){function t(){var n;Eqe(this,t);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return n=Mqe(this,t,[].concat(o)),ca(n,"state",{isAnimationFinished:!0,totalLength:0}),ca(n,"generateSimpleStrokeDasharray",function(a,s){return"".concat(s,"px ").concat(a-s,"px")}),ca(n,"getStrokeDasharray",function(a,s,l){var u=l.reduce(function(S,x){return S+x});if(!u)return n.generateSimpleStrokeDasharray(s,a);for(var d=Math.floor(a/u),h=a%u,p=s-a,m=[],b=0,v=0;b<l.length;v+=l[b],++b)if(v+l[b]>h){m=[].concat(Jd(l.slice(0,b)),[h-v]);break}var y=m.length%2===0?[0,p]:[p];return[].concat(Jd(t.repeat(l,d)),Jd(m),y).map(function(S){return"".concat(S,"px")}).join(", ")}),ca(n,"id",Bv("recharts-line-")),ca(n,"pathRef",function(a){n.mainCurve=a}),ca(n,"handleAnimationEnd",function(){n.setState({isAnimationFinished:!0}),n.props.onAnimationEnd&&n.props.onAnimationEnd()}),ca(n,"handleAnimationStart",function(){n.setState({isAnimationFinished:!1}),n.props.onAnimationStart&&n.props.onAnimationStart()}),n}return Nqe(t,e),Cqe(t,[{key:"componentDidMount",value:function(){if(this.props.isAnimationActive){var r=this.getTotalLength();this.setState({totalLength:r})}}},{key:"componentDidUpdate",value:function(){if(this.props.isAnimationActive){var r=this.getTotalLength();r!==this.state.totalLength&&this.setState({totalLength:r})}}},{key:"getTotalLength",value:function(){var r=this.mainCurve;try{return r&&r.getTotalLength&&r.getTotalLength()||0}catch{return 0}}},{key:"renderErrorBar",value:function(r,o){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var i=this.props,a=i.points,s=i.xAxis,l=i.yAxis,u=i.layout,d=i.children,h=Ri(d,Wv);if(!h)return null;var p=function(v,y){return{x:v.x,y:v.y,value:v.value,errorVal:gi(v.payload,y)}},m={clipPath:r?"url(#clipPath-".concat(o,")"):null};return Y.createElement(Xn,m,h.map(function(b){return Y.cloneElement(b,{key:"bar-".concat(b.props.dataKey),data:a,xAxis:s,yAxis:l,layout:u,dataPointFormatter:p})}))}},{key:"renderDots",value:function(r,o,i){var a=this.props.isAnimationActive;if(a&&!this.state.isAnimationFinished)return null;var s=this.props,l=s.dot,u=s.points,d=s.dataKey,h=_t(this.props,!1),p=_t(l,!0),m=u.map(function(v,y){var S=ei(ei(ei({key:"dot-".concat(y),r:3},h),p),{},{value:v.value,dataKey:d,cx:v.x,cy:v.y,index:y,payload:v.payload});return t.renderDotItem(l,S)}),b={clipPath:r?"url(#clipPath-".concat(o?"":"dots-").concat(i,")"):null};return Y.createElement(Xn,Dm({className:"recharts-line-dots",key:"dots"},b),m)}},{key:"renderCurveStatically",value:function(r,o,i,a){var s=this.props,l=s.type,u=s.layout,d=s.connectNulls;s.ref;var h=M6(s,bqe),p=ei(ei(ei({},_t(h,!0)),{},{fill:"none",className:"recharts-line-curve",clipPath:o?"url(#clipPath-".concat(i,")"):null,points:r},a),{},{type:l,layout:u,connectNulls:d});return Y.createElement(eM,Dm({},p,{pathRef:this.pathRef}))}},{key:"renderCurveWithAnimation",value:function(r,o){var i=this,a=this.props,s=a.points,l=a.strokeDasharray,u=a.isAnimationActive,d=a.animationBegin,h=a.animationDuration,p=a.animationEasing,m=a.animationId,b=a.animateNewValues,v=a.width,y=a.height,S=this.state,x=S.prevPoints,C=S.totalLength;return Y.createElement(Kf,{begin:d,duration:h,isActive:u,easing:p,from:{t:0},to:{t:1},key:"line-".concat(m),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(k){var M=k.t;if(x){var I=x.length/s.length,O=s.map(function(H,U){var G=Math.floor(U*I);if(x[G]){var K=x[G],z=fa(K.x,H.x),ne=fa(K.y,H.y);return ei(ei({},H),{},{x:z(M),y:ne(M)})}if(b){var J=fa(v*2,H.x),ee=fa(y/2,H.y);return ei(ei({},H),{},{x:J(M),y:ee(M)})}return ei(ei({},H),{},{x:H.x,y:H.y})});return i.renderCurveStatically(O,r,o)}var R=fa(0,C),L=R(M),B;if(l){var _="".concat(l).split(/[,\s]+/gim).map(function(H){return parseFloat(H)});B=i.getStrokeDasharray(L,C,_)}else B=i.generateSimpleStrokeDasharray(C,L);return i.renderCurveStatically(s,r,o,{strokeDasharray:B})})}},{key:"renderCurve",value:function(r,o){var i=this.props,a=i.points,s=i.isAnimationActive,l=this.state,u=l.prevPoints,d=l.totalLength;return s&&a&&a.length&&(!u&&d>0||!ws(u,a))?this.renderCurveWithAnimation(r,o):this.renderCurveStatically(a,r,o)}},{key:"render",value:function(){var r,o=this.props,i=o.hide,a=o.dot,s=o.points,l=o.className,u=o.xAxis,d=o.yAxis,h=o.top,p=o.left,m=o.width,b=o.height,v=o.isAnimationActive,y=o.id;if(i||!s||!s.length)return null;var S=this.state.isAnimationFinished,x=s.length===1,C=$t("recharts-line",l),k=u&&u.allowDataOverflow,M=d&&d.allowDataOverflow,I=k||M,O=Ht(y)?this.id:y,R=(r=_t(a,!1))!==null&&r!==void 0?r:{r:3,strokeWidth:2},L=R.r,B=L===void 0?3:L,_=R.strokeWidth,H=_===void 0?2:_,U=XFe(a)?a:{},G=U.clipDot,K=G===void 0?!0:G,z=B*2+H;return Y.createElement(Xn,{className:C},k||M?Y.createElement("defs",null,Y.createElement("clipPath",{id:"clipPath-".concat(O)},Y.createElement("rect",{x:k?p:p-m/2,y:M?h:h-b/2,width:k?m:m*2,height:M?b:b*2})),!K&&Y.createElement("clipPath",{id:"clipPath-dots-".concat(O)},Y.createElement("rect",{x:p-z/2,y:h-z/2,width:m+z,height:b+z}))):null,!x&&this.renderCurve(I,O),this.renderErrorBar(I,O),(x||a)&&this.renderDots(I,K,O),(!v||S)&&bc.renderCallByParent(this.props,s))}}],[{key:"getDerivedStateFromProps",value:function(r,o){return r.animationId!==o.prevAnimationId?{prevAnimationId:r.animationId,curPoints:r.points,prevPoints:o.curPoints}:r.points!==o.curPoints?{curPoints:r.points}:null}},{key:"repeat",value:function(r,o){for(var i=r.length%2!==0?[].concat(Jd(r),[0]):r,a=[],s=0;s<o;++s)a=[].concat(Jd(a),Jd(i));return a}},{key:"renderDotItem",value:function(r,o){var i;if(Y.isValidElement(r))i=Y.cloneElement(r,o);else if(Pt(r))i=r(o);else{var a=o.key,s=M6(o,wqe),l=$t("recharts-line-dot",typeof r!="boolean"?r.className:"");i=Y.createElement(dN,Dm({key:a},s,{className:l}))}return i}}])}(D.PureComponent);ca(Gv,"displayName","Line");ca(Gv,"defaultProps",{xAxisId:0,yAxisId:0,connectNulls:!1,activeDot:!0,dot:!0,legendType:"line",stroke:"#3182bd",strokeWidth:1,fill:"#fff",points:[],isAnimationActive:!dl.isSsr,animateNewValues:!0,animationBegin:0,animationDuration:1500,animationEasing:"ease",hide:!1,label:!1});ca(Gv,"getComposedData",function(e){var t=e.props,n=e.xAxis,r=e.yAxis,o=e.xAxisTicks,i=e.yAxisTicks,a=e.dataKey,s=e.bandSize,l=e.displayedData,u=e.offset,d=t.layout,h=l.map(function(p,m){var b=gi(p,a);return d==="horizontal"?{x:lF({axis:n,ticks:o,bandSize:s,entry:p,index:m}),y:Ht(b)?null:r.scale(b),value:b,payload:p}:{x:Ht(b)?null:n.scale(b),y:lF({axis:r,ticks:i,bandSize:s,entry:p,index:m}),value:b,payload:p}});return ei({points:h,layout:d},u)});function ih(e){"@babel/helpers - typeof";return ih=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ih(e)}function Pqe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function N6(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,wG(r.key),r)}}function jqe(e,t,n){return t&&N6(e.prototype,t),n&&N6(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Lqe(e,t,n){return t=tS(t),Rqe(e,yG()?Reflect.construct(t,n||[],tS(e).constructor):t.apply(e,n))}function Rqe(e,t){if(t&&(ih(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Fqe(e)}function Fqe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function yG(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(yG=function(){return!!e})()}function tS(e){return tS=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},tS(e)}function Hqe(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&IM(e,t)}function IM(e,t){return IM=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},IM(e,t)}function bG(e,t,n){return t=wG(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function wG(e){var t=_qe(e,"string");return ih(t)=="symbol"?t:t+""}function _qe(e,t){if(ih(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(ih(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function kM(){return kM=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},kM.apply(this,arguments)}function Bqe(e){var t=e.xAxisId,n=mN(),r=gN(),o=oG(t);return o==null?null:Y.createElement(Zh,kM({},o,{className:$t("recharts-".concat(o.axisType," ").concat(o.axisType),o.className),viewBox:{x:0,y:0,width:n,height:r},ticksGenerator:function(a){return nl(a,!0)}}))}var rl=function(e){function t(){return Pqe(this,t),Lqe(this,t,arguments)}return Hqe(t,e),jqe(t,[{key:"render",value:function(){return Y.createElement(Bqe,this.props)}}])}(Y.Component);bG(rl,"displayName","XAxis");bG(rl,"defaultProps",{allowDecimals:!0,hide:!1,orientation:"bottom",width:0,height:30,mirror:!1,xAxisId:0,tickCount:5,type:"category",padding:{left:0,right:0},allowDataOverflow:!1,scale:"auto",reversed:!1,allowDuplicatedCategory:!0});function ah(e){"@babel/helpers - typeof";return ah=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ah(e)}function Yqe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function O6(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,xG(r.key),r)}}function Uqe(e,t,n){return t&&O6(e.prototype,t),n&&O6(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function zqe(e,t,n){return t=nS(t),Vqe(e,SG()?Reflect.construct(t,n||[],nS(e).constructor):t.apply(e,n))}function Vqe(e,t){if(t&&(ah(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Wqe(e)}function Wqe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function SG(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(SG=function(){return!!e})()}function nS(e){return nS=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},nS(e)}function Gqe(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&EM(e,t)}function EM(e,t){return EM=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},EM(e,t)}function TG(e,t,n){return t=xG(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xG(e){var t=Zqe(e,"string");return ah(t)=="symbol"?t:t+""}function Zqe(e,t){if(ah(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(ah(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function CM(){return CM=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},CM.apply(this,arguments)}var $qe=function(t){var n=t.yAxisId,r=mN(),o=gN(),i=iG(n);return i==null?null:Y.createElement(Zh,CM({},i,{className:$t("recharts-".concat(i.axisType," ").concat(i.axisType),i.className),viewBox:{x:0,y:0,width:r,height:o},ticksGenerator:function(s){return nl(s,!0)}}))},ol=function(e){function t(){return Yqe(this,t),zqe(this,t,arguments)}return Gqe(t,e),Uqe(t,[{key:"render",value:function(){return Y.createElement($qe,this.props)}}])}(Y.Component);TG(ol,"displayName","YAxis");TG(ol,"defaultProps",{allowDuplicatedCategory:!0,allowDecimals:!0,hide:!1,orientation:"left",width:60,height:0,mirror:!1,yAxisId:0,tickCount:5,type:"number",padding:{top:0,bottom:0},allowDataOverflow:!1,scale:"auto",reversed:!1});function P6(e){return Jqe(e)||Xqe(e)||Kqe(e)||qqe()}function qqe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Kqe(e,t){if(e){if(typeof e=="string")return MM(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return MM(e,t)}}function Xqe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Jqe(e){if(Array.isArray(e))return MM(e)}function MM(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var DM=function(t,n,r,o,i){var a=Ri(t,yN),s=Ri(t,qT),l=[].concat(P6(a),P6(s)),u=Ri(t,XT),d="".concat(o,"Id"),h=o[0],p=n;if(l.length&&(p=l.reduce(function(v,y){if(y.props[d]===r&&vs(y.props,"extendDomain")&&Je(y.props[h])){var S=y.props[h];return[Math.min(v[0],S),Math.max(v[1],S)]}return v},p)),u.length){var m="".concat(h,"1"),b="".concat(h,"2");p=u.reduce(function(v,y){if(y.props[d]===r&&vs(y.props,"extendDomain")&&Je(y.props[m])&&Je(y.props[b])){var S=y.props[m],x=y.props[b];return[Math.min(v[0],S,x),Math.max(v[1],S,x)]}return v},p)}return i&&i.length&&(p=i.reduce(function(v,y){return Je(y)?[Math.min(v[0],y),Math.max(v[1],y)]:v},p)),p},IG={exports:{}};(function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(n=!1));function o(l,u,d){this.fn=l,this.context=u,this.once=d||!1}function i(l,u,d,h,p){if(typeof d!="function")throw new TypeError("The listener must be a function");var m=new o(d,h||l,p),b=n?n+u:u;return l._events[b]?l._events[b].fn?l._events[b]=[l._events[b],m]:l._events[b].push(m):(l._events[b]=m,l._eventsCount++),l}function a(l,u){--l._eventsCount===0?l._events=new r:delete l._events[u]}function s(){this._events=new r,this._eventsCount=0}s.prototype.eventNames=function(){var u=[],d,h;if(this._eventsCount===0)return u;for(h in d=this._events)t.call(d,h)&&u.push(n?h.slice(1):h);return Object.getOwnPropertySymbols?u.concat(Object.getOwnPropertySymbols(d)):u},s.prototype.listeners=function(u){var d=n?n+u:u,h=this._events[d];if(!h)return[];if(h.fn)return[h.fn];for(var p=0,m=h.length,b=new Array(m);p<m;p++)b[p]=h[p].fn;return b},s.prototype.listenerCount=function(u){var d=n?n+u:u,h=this._events[d];return h?h.fn?1:h.length:0},s.prototype.emit=function(u,d,h,p,m,b){var v=n?n+u:u;if(!this._events[v])return!1;var y=this._events[v],S=arguments.length,x,C;if(y.fn){switch(y.once&&this.removeListener(u,y.fn,void 0,!0),S){case 1:return y.fn.call(y.context),!0;case 2:return y.fn.call(y.context,d),!0;case 3:return y.fn.call(y.context,d,h),!0;case 4:return y.fn.call(y.context,d,h,p),!0;case 5:return y.fn.call(y.context,d,h,p,m),!0;case 6:return y.fn.call(y.context,d,h,p,m,b),!0}for(C=1,x=new Array(S-1);C<S;C++)x[C-1]=arguments[C];y.fn.apply(y.context,x)}else{var k=y.length,M;for(C=0;C<k;C++)switch(y[C].once&&this.removeListener(u,y[C].fn,void 0,!0),S){case 1:y[C].fn.call(y[C].context);break;case 2:y[C].fn.call(y[C].context,d);break;case 3:y[C].fn.call(y[C].context,d,h);break;case 4:y[C].fn.call(y[C].context,d,h,p);break;default:if(!x)for(M=1,x=new Array(S-1);M<S;M++)x[M-1]=arguments[M];y[C].fn.apply(y[C].context,x)}}return!0},s.prototype.on=function(u,d,h){return i(this,u,d,h,!1)},s.prototype.once=function(u,d,h){return i(this,u,d,h,!0)},s.prototype.removeListener=function(u,d,h,p){var m=n?n+u:u;if(!this._events[m])return this;if(!d)return a(this,m),this;var b=this._events[m];if(b.fn)b.fn===d&&(!p||b.once)&&(!h||b.context===h)&&a(this,m);else{for(var v=0,y=[],S=b.length;v<S;v++)(b[v].fn!==d||p&&!b[v].once||h&&b[v].context!==h)&&y.push(b[v]);y.length?this._events[m]=y.length===1?y[0]:y:a(this,m)}return this},s.prototype.removeAllListeners=function(u){var d;return u?(d=n?n+u:u,this._events[d]&&a(this,d)):(this._events=new r,this._eventsCount=0),this},s.prototype.off=s.prototype.removeListener,s.prototype.addListener=s.prototype.on,s.prefixed=n,s.EventEmitter=s,e.exports=s})(IG);var Qqe=IG.exports;const eKe=tt(Qqe);var Ok=new eKe,Pk="recharts.syncMouseEvents";function Yg(e){"@babel/helpers - typeof";return Yg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Yg(e)}function tKe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function j6(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,kG(r.key),r)}}function nKe(e,t,n){return t&&j6(e.prototype,t),n&&j6(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function jk(e,t,n){return t=kG(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function kG(e){var t=rKe(e,"string");return Yg(t)=="symbol"?t:t+""}function rKe(e,t){if(Yg(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Yg(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var oKe=function(){function e(){tKe(this,e),jk(this,"activeIndex",0),jk(this,"coordinateList",[]),jk(this,"layout","horizontal")}return nKe(e,[{key:"setDetails",value:function(n){var r,o=n.coordinateList,i=o===void 0?null:o,a=n.container,s=a===void 0?null:a,l=n.layout,u=l===void 0?null:l,d=n.offset,h=d===void 0?null:d,p=n.mouseHandlerCallback,m=p===void 0?null:p;this.coordinateList=(r=i??this.coordinateList)!==null&&r!==void 0?r:[],this.container=s??this.container,this.layout=u??this.layout,this.offset=h??this.offset,this.mouseHandlerCallback=m??this.mouseHandlerCallback,this.activeIndex=Math.min(Math.max(this.activeIndex,0),this.coordinateList.length-1)}},{key:"focus",value:function(){this.spoofMouse()}},{key:"keyboardEvent",value:function(n){if(this.coordinateList.length!==0)switch(n.key){case"ArrowRight":if(this.layout!=="horizontal")return;this.activeIndex=Math.min(this.activeIndex+1,this.coordinateList.length-1),this.spoofMouse();break;case"ArrowLeft":if(this.layout!=="horizontal")return;this.activeIndex=Math.max(this.activeIndex-1,0),this.spoofMouse();break}}},{key:"setIndex",value:function(n){this.activeIndex=n}},{key:"spoofMouse",value:function(){var n,r;if(this.layout==="horizontal"&&this.coordinateList.length!==0){var o=this.container.getBoundingClientRect(),i=o.x,a=o.y,s=o.height,l=this.coordinateList[this.activeIndex].coordinate,u=((n=window)===null||n===void 0?void 0:n.scrollX)||0,d=((r=window)===null||r===void 0?void 0:r.scrollY)||0,h=i+l+u,p=a+this.offset.top+s/2+d;this.mouseHandlerCallback({pageX:h,pageY:p})}}}])}();function iKe(e,t,n){if(n==="number"&&t===!0&&Array.isArray(e)){var r=e?.[0],o=e?.[1];if(r&&o&&Je(r)&&Je(o))return!0}return!1}function aKe(e,t,n,r){var o=r/2;return{stroke:"none",fill:"#ccc",x:e==="horizontal"?t.x-o:n.left+.5,y:e==="horizontal"?n.top+.5:t.y-o,width:e==="horizontal"?r:n.width-1,height:e==="horizontal"?n.height-1:r}}function EG(e){var t=e.cx,n=e.cy,r=e.radius,o=e.startAngle,i=e.endAngle,a=Rr(t,n,r,o),s=Rr(t,n,r,i);return{points:[a,s],cx:t,cy:n,radius:r,startAngle:o,endAngle:i}}function sKe(e,t,n){var r,o,i,a;if(e==="horizontal")r=t.x,i=r,o=n.top,a=n.top+n.height;else if(e==="vertical")o=t.y,a=o,r=n.left,i=n.left+n.width;else if(t.cx!=null&&t.cy!=null)if(e==="centric"){var s=t.cx,l=t.cy,u=t.innerRadius,d=t.outerRadius,h=t.angle,p=Rr(s,l,u,h),m=Rr(s,l,d,h);r=p.x,o=p.y,i=m.x,a=m.y}else return EG(t);return[{x:r,y:o},{x:i,y:a}]}function Ug(e){"@babel/helpers - typeof";return Ug=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ug(e)}function L6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Pb(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?L6(Object(n),!0).forEach(function(r){lKe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):L6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function lKe(e,t,n){return t=cKe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cKe(e){var t=uKe(e,"string");return Ug(t)=="symbol"?t:t+""}function uKe(e,t){if(Ug(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Ug(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function dKe(e){var t,n,r=e.element,o=e.tooltipEventType,i=e.isActive,a=e.activeCoordinate,s=e.activePayload,l=e.offset,u=e.activeTooltipIndex,d=e.tooltipAxisBandSize,h=e.layout,p=e.chartName,m=(t=r.props.cursor)!==null&&t!==void 0?t:(n=r.type.defaultProps)===null||n===void 0?void 0:n.cursor;if(!r||!m||!i||!a||p!=="ScatterChart"&&o!=="axis")return null;var b,v=eM;if(p==="ScatterChart")b=a,v=lGe;else if(p==="BarChart")b=aKe(h,a,l,d),v=uN;else if(h==="radial"){var y=EG(a),S=y.cx,x=y.cy,C=y.radius,k=y.startAngle,M=y.endAngle;b={cx:S,cy:x,startAngle:k,endAngle:M,innerRadius:C,outerRadius:C},v=PW}else b={points:sKe(h,a,l)},v=eM;var I=Pb(Pb(Pb(Pb({stroke:"#ccc",pointerEvents:"none"},l),b),_t(m,!1)),{},{payload:s,payloadIndex:u,className:$t("recharts-tooltip-cursor",m.className)});return D.isValidElement(m)?D.cloneElement(m,I):D.createElement(v,I)}var fKe=["item"],hKe=["children","className","width","height","style","compact","title","desc"];function sh(e){"@babel/helpers - typeof";return sh=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},sh(e)}function hf(){return hf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},hf.apply(this,arguments)}function R6(e,t){return gKe(e)||mKe(e,t)||MG(e,t)||pKe()}function pKe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function mKe(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,s=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(d){u=!0,o=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}function gKe(e){if(Array.isArray(e))return e}function F6(e,t){if(e==null)return{};var n=vKe(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function vKe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function yKe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function H6(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,DG(r.key),r)}}function bKe(e,t,n){return t&&H6(e.prototype,t),n&&H6(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function wKe(e,t,n){return t=rS(t),SKe(e,CG()?Reflect.construct(t,n||[],rS(e).constructor):t.apply(e,n))}function SKe(e,t){if(t&&(sh(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return TKe(e)}function TKe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function CG(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(CG=function(){return!!e})()}function rS(e){return rS=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},rS(e)}function xKe(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&AM(e,t)}function AM(e,t){return AM=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},AM(e,t)}function lh(e){return EKe(e)||kKe(e)||MG(e)||IKe()}function IKe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function MG(e,t){if(e){if(typeof e=="string")return NM(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return NM(e,t)}}function kKe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function EKe(e){if(Array.isArray(e))return NM(e)}function NM(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function _6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Me(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?_6(Object(n),!0).forEach(function(r){bt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function bt(e,t,n){return t=DG(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function DG(e){var t=CKe(e,"string");return sh(t)=="symbol"?t:t+""}function CKe(e,t){if(sh(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(sh(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var MKe={xAxis:["bottom","top"],yAxis:["left","right"]},DKe={width:"100%",height:"100%"},AG={x:0,y:0};function jb(e){return e}var AKe=function(t,n){return n==="horizontal"?t.x:n==="vertical"?t.y:n==="centric"?t.angle:t.radius},NKe=function(t,n,r,o){var i=n.find(function(d){return d&&d.index===r});if(i){if(t==="horizontal")return{x:i.coordinate,y:o.y};if(t==="vertical")return{x:o.x,y:i.coordinate};if(t==="centric"){var a=i.coordinate,s=o.radius;return Me(Me(Me({},o),Rr(o.cx,o.cy,s,a)),{},{angle:a,radius:s})}var l=i.coordinate,u=o.angle;return Me(Me(Me({},o),Rr(o.cx,o.cy,l,u)),{},{angle:u,radius:l})}return AG},JT=function(t,n){var r=n.graphicalItems,o=n.dataStartIndex,i=n.dataEndIndex,a=(r??[]).reduce(function(s,l){var u=l.props.data;return u&&u.length?[].concat(lh(s),lh(u)):s},[]);return a.length>0?a:t&&t.length&&Je(o)&&Je(i)?t.slice(o,i+1):[]};function NG(e){return e==="number"?[0,"auto"]:void 0}var OM=function(t,n,r,o){var i=t.graphicalItems,a=t.tooltipAxis,s=JT(n,t);return r<0||!i||!i.length||r>=s.length?null:i.reduce(function(l,u){var d,h=(d=u.props.data)!==null&&d!==void 0?d:n;h&&t.dataStartIndex+t.dataEndIndex!==0&&t.dataEndIndex-t.dataStartIndex>=r&&(h=h.slice(t.dataStartIndex,t.dataEndIndex+1));var p;if(a.dataKey&&!a.allowDuplicatedCategory){var m=h===void 0?s:h;p=cw(m,a.dataKey,o)}else p=h&&h[r]||s[r];return p?[].concat(lh(l),[AW(u,p)]):l},[])},B6=function(t,n,r,o){var i=o||{x:t.chartX,y:t.chartY},a=AKe(i,r),s=t.orderedTooltipTicks,l=t.tooltipAxis,u=t.tooltipTicks,d=rze(a,s,u,l);if(d>=0&&u){var h=u[d]&&u[d].value,p=OM(t,n,d,h),m=NKe(r,s,d,i);return{activeTooltipIndex:d,activeLabel:h,activePayload:p,activeCoordinate:m}}return null},OKe=function(t,n){var r=n.axes,o=n.graphicalItems,i=n.axisType,a=n.axisIdKey,s=n.stackGroups,l=n.dataStartIndex,u=n.dataEndIndex,d=t.layout,h=t.children,p=t.stackOffset,m=CW(d,i);return r.reduce(function(b,v){var y,S=v.type.defaultProps!==void 0?Me(Me({},v.type.defaultProps),v.props):v.props,x=S.type,C=S.dataKey,k=S.allowDataOverflow,M=S.allowDuplicatedCategory,I=S.scale,O=S.ticks,R=S.includeHidden,L=S[a];if(b[L])return b;var B=JT(t.data,{graphicalItems:o.filter(function($){var re,le=a in $.props?$.props[a]:(re=$.type.defaultProps)===null||re===void 0?void 0:re[a];return le===L}),dataStartIndex:l,dataEndIndex:u}),_=B.length,H,U,G;iKe(S.domain,k,x)&&(H=qC(S.domain,null,k),m&&(x==="number"||I!=="auto")&&(G=Cm(B,C,"category")));var K=NG(x);if(!H||H.length===0){var z,ne=(z=S.domain)!==null&&z!==void 0?z:K;if(C){if(H=Cm(B,C,x),x==="category"&&m){var J=UFe(H);M&&J?(U=H,H=Km(0,_)):M||(H=fF(ne,H,v).reduce(function($,re){return $.indexOf(re)>=0?$:[].concat(lh($),[re])},[]))}else if(x==="category")M?H=H.filter(function($){return $!==""&&!Ht($)}):H=fF(ne,H,v).reduce(function($,re){return $.indexOf(re)>=0||re===""||Ht(re)?$:[].concat(lh($),[re])},[]);else if(x==="number"){var ee=lze(B,o.filter(function($){var re,le,ie=a in $.props?$.props[a]:(re=$.type.defaultProps)===null||re===void 0?void 0:re[a],fe="hide"in $.props?$.props.hide:(le=$.type.defaultProps)===null||le===void 0?void 0:le.hide;return ie===L&&(R||!fe)}),C,i,d);ee&&(H=ee)}m&&(x==="number"||I!=="auto")&&(G=Cm(B,C,"category"))}else m?H=Km(0,_):s&&s[L]&&s[L].hasStack&&x==="number"?H=p==="expand"?[0,1]:DW(s[L].stackGroups,l,u):H=EW(B,o.filter(function($){var re=a in $.props?$.props[a]:$.type.defaultProps[a],le="hide"in $.props?$.props.hide:$.type.defaultProps.hide;return re===L&&(R||!le)}),x,d,!0);if(x==="number")H=DM(h,H,L,i,O),ne&&(H=qC(ne,H,k));else if(x==="category"&&ne){var Z=ne,q=H.every(function($){return Z.indexOf($)>=0});q&&(H=Z)}}return Me(Me({},b),{},bt({},L,Me(Me({},S),{},{axisType:i,domain:H,categoricalDomain:G,duplicateDomain:U,originalDomain:(y=S.domain)!==null&&y!==void 0?y:K,isCategorical:m,layout:d})))},{})},PKe=function(t,n){var r=n.graphicalItems,o=n.Axis,i=n.axisType,a=n.axisIdKey,s=n.stackGroups,l=n.dataStartIndex,u=n.dataEndIndex,d=t.layout,h=t.children,p=JT(t.data,{graphicalItems:r,dataStartIndex:l,dataEndIndex:u}),m=p.length,b=CW(d,i),v=-1;return r.reduce(function(y,S){var x=S.type.defaultProps!==void 0?Me(Me({},S.type.defaultProps),S.props):S.props,C=x[a],k=NG("number");if(!y[C]){v++;var M;return b?M=Km(0,m):s&&s[C]&&s[C].hasStack?(M=DW(s[C].stackGroups,l,u),M=DM(h,M,C,i)):(M=qC(k,EW(p,r.filter(function(I){var O,R,L=a in I.props?I.props[a]:(O=I.type.defaultProps)===null||O===void 0?void 0:O[a],B="hide"in I.props?I.props.hide:(R=I.type.defaultProps)===null||R===void 0?void 0:R.hide;return L===C&&!B}),"number",d),o.defaultProps.allowDataOverflow),M=DM(h,M,C,i)),Me(Me({},y),{},bt({},C,Me(Me({axisType:i},o.defaultProps),{},{hide:!0,orientation:Li(MKe,"".concat(i,".").concat(v%2),null),domain:M,originalDomain:k,isCategorical:b,layout:d})))}return y},{})},jKe=function(t,n){var r=n.axisType,o=r===void 0?"xAxis":r,i=n.AxisComp,a=n.graphicalItems,s=n.stackGroups,l=n.dataStartIndex,u=n.dataEndIndex,d=t.children,h="".concat(o,"Id"),p=Ri(d,i),m={};return p&&p.length?m=OKe(t,{axes:p,graphicalItems:a,axisType:o,axisIdKey:h,stackGroups:s,dataStartIndex:l,dataEndIndex:u}):a&&a.length&&(m=PKe(t,{Axis:i,graphicalItems:a,axisType:o,axisIdKey:h,stackGroups:s,dataStartIndex:l,dataEndIndex:u})),m},LKe=function(t){var n=cc(t),r=nl(n,!1,!0);return{tooltipTicks:r,orderedTooltipTicks:FS(r,function(o){return o.coordinate}),tooltipAxis:n,tooltipAxisBandSize:Rw(n,r)}},Y6=function(t){var n=t.children,r=t.defaultShowTooltip,o=ai(n,Jf),i=0,a=0;return t.data&&t.data.length!==0&&(a=t.data.length-1),o&&o.props&&(o.props.startIndex>=0&&(i=o.props.startIndex),o.props.endIndex>=0&&(a=o.props.endIndex)),{chartX:0,chartY:0,dataStartIndex:i,dataEndIndex:a,activeTooltipIndex:-1,isTooltipActive:!!r}},RKe=function(t){return!t||!t.length?!1:t.some(function(n){var r=cl(n&&n.type);return r&&r.indexOf("Bar")>=0})},U6=function(t){return t==="horizontal"?{numericAxisName:"yAxis",cateAxisName:"xAxis"}:t==="vertical"?{numericAxisName:"xAxis",cateAxisName:"yAxis"}:t==="centric"?{numericAxisName:"radiusAxis",cateAxisName:"angleAxis"}:{numericAxisName:"angleAxis",cateAxisName:"radiusAxis"}},FKe=function(t,n){var r=t.props,o=t.graphicalItems,i=t.xAxisMap,a=i===void 0?{}:i,s=t.yAxisMap,l=s===void 0?{}:s,u=r.width,d=r.height,h=r.children,p=r.margin||{},m=ai(h,Jf),b=ai(h,yf),v=Object.keys(l).reduce(function(M,I){var O=l[I],R=O.orientation;return!O.mirror&&!O.hide?Me(Me({},M),{},bt({},R,M[R]+O.width)):M},{left:p.left||0,right:p.right||0}),y=Object.keys(a).reduce(function(M,I){var O=a[I],R=O.orientation;return!O.mirror&&!O.hide?Me(Me({},M),{},bt({},R,Li(M,"".concat(R))+O.height)):M},{top:p.top||0,bottom:p.bottom||0}),S=Me(Me({},y),v),x=S.bottom;m&&(S.bottom+=m.props.height||Jf.defaultProps.height),b&&n&&(S=aze(S,o,r,n));var C=u-S.left-S.right,k=d-S.top-S.bottom;return Me(Me({brushBottom:x},S),{},{width:Math.max(C,0),height:Math.max(k,0)})},HKe=function(t,n){if(n==="xAxis")return t[n].width;if(n==="yAxis")return t[n].height},OG=function(t){var n=t.chartName,r=t.GraphicalChild,o=t.defaultTooltipEventType,i=o===void 0?"axis":o,a=t.validateTooltipEventTypes,s=a===void 0?["axis"]:a,l=t.axisComponents,u=t.legendContent,d=t.formatAxisMap,h=t.defaultProps,p=function(S,x){var C=x.graphicalItems,k=x.stackGroups,M=x.offset,I=x.updateId,O=x.dataStartIndex,R=x.dataEndIndex,L=S.barSize,B=S.layout,_=S.barGap,H=S.barCategoryGap,U=S.maxBarSize,G=U6(B),K=G.numericAxisName,z=G.cateAxisName,ne=RKe(C),J=[];return C.forEach(function(ee,Z){var q=JT(S.data,{graphicalItems:[ee],dataStartIndex:O,dataEndIndex:R}),$=ee.type.defaultProps!==void 0?Me(Me({},ee.type.defaultProps),ee.props):ee.props,re=$.dataKey,le=$.maxBarSize,ie=$["".concat(K,"Id")],fe=$["".concat(z,"Id")],ye={},ge=l.reduce(function(it,at){var vt=x["".concat(at.axisType,"Map")],Mt=$["".concat(at.axisType,"Id")];vt&&vt[Mt]||at.axisType==="zAxis"||qu(!1);var Kt=vt[Mt];return Me(Me({},it),{},bt(bt({},at.axisType,Kt),"".concat(at.axisType,"Ticks"),nl(Kt)))},ye),me=ge[z],Ce=ge["".concat(z,"Ticks")],je=k&&k[ie]&&k[ie].hasStack&&wze(ee,k[ie].stackGroups),Ie=cl(ee.type).indexOf("Bar")>=0,Fe=Rw(me,Ce),ce=[],Ne=ne&&oze({barSize:L,stackGroups:k,totalSize:HKe(ge,z)});if(Ie){var Pe,_e,qe=Ht(le)?U:le,Xe=(Pe=(_e=Rw(me,Ce,!0))!==null&&_e!==void 0?_e:qe)!==null&&Pe!==void 0?Pe:0;ce=ize({barGap:_,barCategoryGap:H,bandSize:Xe!==Fe?Xe:Fe,sizeList:Ne[fe],maxBarSize:qe}),Xe!==Fe&&(ce=ce.map(function(it){return Me(Me({},it),{},{position:Me(Me({},it.position),{},{offset:it.position.offset-Xe/2})})}))}var Qe=ee&&ee.type&&ee.type.getComposedData;Qe&&J.push({props:Me(Me({},Qe(Me(Me({},ge),{},{displayedData:q,props:S,dataKey:re,item:ee,bandSize:Fe,barPosition:ce,offset:M,stackedData:je,layout:B,dataStartIndex:O,dataEndIndex:R}))),{},bt(bt(bt({key:ee.key||"item-".concat(Z)},K,ge[K]),z,ge[z]),"animationId",I)),childIndex:e6e(ee,S.children),item:ee})}),J},m=function(S,x){var C=S.props,k=S.dataStartIndex,M=S.dataEndIndex,I=S.updateId;if(!A5({props:C}))return null;var O=C.children,R=C.layout,L=C.stackOffset,B=C.data,_=C.reverseStackOrder,H=U6(R),U=H.numericAxisName,G=H.cateAxisName,K=Ri(O,r),z=vze(B,K,"".concat(U,"Id"),"".concat(G,"Id"),L,_),ne=l.reduce(function($,re){var le="".concat(re.axisType,"Map");return Me(Me({},$),{},bt({},le,jKe(C,Me(Me({},re),{},{graphicalItems:K,stackGroups:re.axisType===U&&z,dataStartIndex:k,dataEndIndex:M}))))},{}),J=FKe(Me(Me({},ne),{},{props:C,graphicalItems:K}),x?.legendBBox);Object.keys(ne).forEach(function($){ne[$]=d(C,ne[$],J,$.replace("Map",""),n)});var ee=ne["".concat(G,"Map")],Z=LKe(ee),q=p(C,Me(Me({},ne),{},{dataStartIndex:k,dataEndIndex:M,updateId:I,graphicalItems:K,stackGroups:z,offset:J}));return Me(Me({formattedGraphicalItems:q,graphicalItems:K,offset:J,stackGroups:z},Z),ne)},b=function(y){function S(x){var C,k,M;return yKe(this,S),M=wKe(this,S,[x]),bt(M,"eventEmitterSymbol",Symbol("rechartsEventEmitter")),bt(M,"accessibilityManager",new oKe),bt(M,"handleLegendBBoxUpdate",function(I){if(I){var O=M.state,R=O.dataStartIndex,L=O.dataEndIndex,B=O.updateId;M.setState(Me({legendBBox:I},m({props:M.props,dataStartIndex:R,dataEndIndex:L,updateId:B},Me(Me({},M.state),{},{legendBBox:I}))))}}),bt(M,"handleReceiveSyncEvent",function(I,O,R){if(M.props.syncId===I){if(R===M.eventEmitterSymbol&&typeof M.props.syncMethod!="function")return;M.applySyncEvent(O)}}),bt(M,"handleBrushChange",function(I){var O=I.startIndex,R=I.endIndex;if(O!==M.state.dataStartIndex||R!==M.state.dataEndIndex){var L=M.state.updateId;M.setState(function(){return Me({dataStartIndex:O,dataEndIndex:R},m({props:M.props,dataStartIndex:O,dataEndIndex:R,updateId:L},M.state))}),M.triggerSyncEvent({dataStartIndex:O,dataEndIndex:R})}}),bt(M,"handleMouseEnter",function(I){var O=M.getMouseInfo(I);if(O){var R=Me(Me({},O),{},{isTooltipActive:!0});M.setState(R),M.triggerSyncEvent(R);var L=M.props.onMouseEnter;Pt(L)&&L(R,I)}}),bt(M,"triggeredAfterMouseMove",function(I){var O=M.getMouseInfo(I),R=O?Me(Me({},O),{},{isTooltipActive:!0}):{isTooltipActive:!1};M.setState(R),M.triggerSyncEvent(R);var L=M.props.onMouseMove;Pt(L)&&L(R,I)}),bt(M,"handleItemMouseEnter",function(I){M.setState(function(){return{isTooltipActive:!0,activeItem:I,activePayload:I.tooltipPayload,activeCoordinate:I.tooltipPosition||{x:I.cx,y:I.cy}}})}),bt(M,"handleItemMouseLeave",function(){M.setState(function(){return{isTooltipActive:!1}})}),bt(M,"handleMouseMove",function(I){I.persist(),M.throttleTriggeredAfterMouseMove(I)}),bt(M,"handleMouseLeave",function(I){M.throttleTriggeredAfterMouseMove.cancel();var O={isTooltipActive:!1};M.setState(O),M.triggerSyncEvent(O);var R=M.props.onMouseLeave;Pt(R)&&R(O,I)}),bt(M,"handleOuterEvent",function(I){var O=QFe(I),R=Li(M.props,"".concat(O));if(O&&Pt(R)){var L,B;/.*touch.*/i.test(O)?B=M.getMouseInfo(I.changedTouches[0]):B=M.getMouseInfo(I),R((L=B)!==null&&L!==void 0?L:{},I)}}),bt(M,"handleClick",function(I){var O=M.getMouseInfo(I);if(O){var R=Me(Me({},O),{},{isTooltipActive:!0});M.setState(R),M.triggerSyncEvent(R);var L=M.props.onClick;Pt(L)&&L(R,I)}}),bt(M,"handleMouseDown",function(I){var O=M.props.onMouseDown;if(Pt(O)){var R=M.getMouseInfo(I);O(R,I)}}),bt(M,"handleMouseUp",function(I){var O=M.props.onMouseUp;if(Pt(O)){var R=M.getMouseInfo(I);O(R,I)}}),bt(M,"handleTouchMove",function(I){I.changedTouches!=null&&I.changedTouches.length>0&&M.throttleTriggeredAfterMouseMove(I.changedTouches[0])}),bt(M,"handleTouchStart",function(I){I.changedTouches!=null&&I.changedTouches.length>0&&M.handleMouseDown(I.changedTouches[0])}),bt(M,"handleTouchEnd",function(I){I.changedTouches!=null&&I.changedTouches.length>0&&M.handleMouseUp(I.changedTouches[0])}),bt(M,"handleDoubleClick",function(I){var O=M.props.onDoubleClick;if(Pt(O)){var R=M.getMouseInfo(I);O(R,I)}}),bt(M,"handleContextMenu",function(I){var O=M.props.onContextMenu;if(Pt(O)){var R=M.getMouseInfo(I);O(R,I)}}),bt(M,"triggerSyncEvent",function(I){M.props.syncId!==void 0&&Ok.emit(Pk,M.props.syncId,I,M.eventEmitterSymbol)}),bt(M,"applySyncEvent",function(I){var O=M.props,R=O.layout,L=O.syncMethod,B=M.state.updateId,_=I.dataStartIndex,H=I.dataEndIndex;if(I.dataStartIndex!==void 0||I.dataEndIndex!==void 0)M.setState(Me({dataStartIndex:_,dataEndIndex:H},m({props:M.props,dataStartIndex:_,dataEndIndex:H,updateId:B},M.state)));else if(I.activeTooltipIndex!==void 0){var U=I.chartX,G=I.chartY,K=I.activeTooltipIndex,z=M.state,ne=z.offset,J=z.tooltipTicks;if(!ne)return;if(typeof L=="function")K=L(J,I);else if(L==="value"){K=-1;for(var ee=0;ee<J.length;ee++)if(J[ee].value===I.activeLabel){K=ee;break}}var Z=Me(Me({},ne),{},{x:ne.left,y:ne.top}),q=Math.min(U,Z.x+Z.width),$=Math.min(G,Z.y+Z.height),re=J[K]&&J[K].value,le=OM(M.state,M.props.data,K),ie=J[K]?{x:R==="horizontal"?J[K].coordinate:q,y:R==="horizontal"?$:J[K].coordinate}:AG;M.setState(Me(Me({},I),{},{activeLabel:re,activeCoordinate:ie,activePayload:le,activeTooltipIndex:K}))}else M.setState(I)}),bt(M,"renderCursor",function(I){var O,R=M.state,L=R.isTooltipActive,B=R.activeCoordinate,_=R.activePayload,H=R.offset,U=R.activeTooltipIndex,G=R.tooltipAxisBandSize,K=M.getTooltipEventType(),z=(O=I.props.active)!==null&&O!==void 0?O:L,ne=M.props.layout,J=I.key||"_recharts-cursor";return Y.createElement(dKe,{key:J,activeCoordinate:B,activePayload:_,activeTooltipIndex:U,chartName:n,element:I,isActive:z,layout:ne,offset:H,tooltipAxisBandSize:G,tooltipEventType:K})}),bt(M,"renderPolarAxis",function(I,O,R){var L=Li(I,"type.axisType"),B=Li(M.state,"".concat(L,"Map")),_=I.type.defaultProps,H=_!==void 0?Me(Me({},_),I.props):I.props,U=B&&B[H["".concat(L,"Id")]];return D.cloneElement(I,Me(Me({},U),{},{className:$t(L,U.className),key:I.key||"".concat(O,"-").concat(R),ticks:nl(U,!0)}))}),bt(M,"renderPolarGrid",function(I){var O=I.props,R=O.radialLines,L=O.polarAngles,B=O.polarRadius,_=M.state,H=_.radiusAxisMap,U=_.angleAxisMap,G=cc(H),K=cc(U),z=K.cx,ne=K.cy,J=K.innerRadius,ee=K.outerRadius;return D.cloneElement(I,{polarAngles:Array.isArray(L)?L:nl(K,!0).map(function(Z){return Z.coordinate}),polarRadius:Array.isArray(B)?B:nl(G,!0).map(function(Z){return Z.coordinate}),cx:z,cy:ne,innerRadius:J,outerRadius:ee,key:I.key||"polar-grid",radialLines:R})}),bt(M,"renderLegend",function(){var I=M.state.formattedGraphicalItems,O=M.props,R=O.children,L=O.width,B=O.height,_=M.props.margin||{},H=L-(_.left||0)-(_.right||0),U=IW({children:R,formattedGraphicalItems:I,legendWidth:H,legendContent:u});if(!U)return null;var G=U.item,K=F6(U,fKe);return D.cloneElement(G,Me(Me({},K),{},{chartWidth:L,chartHeight:B,margin:_,onBBoxUpdate:M.handleLegendBBoxUpdate}))}),bt(M,"renderTooltip",function(){var I,O=M.props,R=O.children,L=O.accessibilityLayer,B=ai(R,es);if(!B)return null;var _=M.state,H=_.isTooltipActive,U=_.activeCoordinate,G=_.activePayload,K=_.activeLabel,z=_.offset,ne=(I=B.props.active)!==null&&I!==void 0?I:H;return D.cloneElement(B,{viewBox:Me(Me({},z),{},{x:z.left,y:z.top}),active:ne,label:K,payload:ne?G:[],coordinate:U,accessibilityLayer:L})}),bt(M,"renderBrush",function(I){var O=M.props,R=O.margin,L=O.data,B=M.state,_=B.offset,H=B.dataStartIndex,U=B.dataEndIndex,G=B.updateId;return D.cloneElement(I,{key:I.key||"_recharts-brush",onChange:Db(M.handleBrushChange,I.props.onChange),data:L,x:Je(I.props.x)?I.props.x:_.left,y:Je(I.props.y)?I.props.y:_.top+_.height+_.brushBottom-(R.bottom||0),width:Je(I.props.width)?I.props.width:_.width,startIndex:H,endIndex:U,updateId:"brush-".concat(G)})}),bt(M,"renderReferenceElement",function(I,O,R){if(!I)return null;var L=M,B=L.clipPathId,_=M.state,H=_.xAxisMap,U=_.yAxisMap,G=_.offset,K=I.type.defaultProps||{},z=I.props,ne=z.xAxisId,J=ne===void 0?K.xAxisId:ne,ee=z.yAxisId,Z=ee===void 0?K.yAxisId:ee;return D.cloneElement(I,{key:I.key||"".concat(O,"-").concat(R),xAxis:H[J],yAxis:U[Z],viewBox:{x:G.left,y:G.top,width:G.width,height:G.height},clipPathId:B})}),bt(M,"renderActivePoints",function(I){var O=I.item,R=I.activePoint,L=I.basePoint,B=I.childIndex,_=I.isRange,H=[],U=O.props.key,G=O.item.type.defaultProps!==void 0?Me(Me({},O.item.type.defaultProps),O.item.props):O.item.props,K=G.activeDot,z=G.dataKey,ne=Me(Me({index:B,dataKey:z,cx:R.x,cy:R.y,r:4,fill:cN(O.item),strokeWidth:2,stroke:"#fff",payload:R.payload,value:R.value},_t(K,!1)),uw(K));return H.push(S.renderActiveDot(K,ne,"".concat(U,"-activePoint-").concat(B))),L?H.push(S.renderActiveDot(K,Me(Me({},ne),{},{cx:L.x,cy:L.y}),"".concat(U,"-basePoint-").concat(B))):_&&H.push(null),H}),bt(M,"renderGraphicChild",function(I,O,R){var L=M.filterFormatItem(I,O,R);if(!L)return null;var B=M.getTooltipEventType(),_=M.state,H=_.isTooltipActive,U=_.tooltipAxis,G=_.activeTooltipIndex,K=_.activeLabel,z=M.props.children,ne=ai(z,es),J=L.props,ee=J.points,Z=J.isRange,q=J.baseLine,$=L.item.type.defaultProps!==void 0?Me(Me({},L.item.type.defaultProps),L.item.props):L.item.props,re=$.activeDot,le=$.hide,ie=$.activeBar,fe=$.activeShape,ye=!!(!le&&H&&ne&&(re||ie||fe)),ge={};B!=="axis"&&ne&&ne.props.trigger==="click"?ge={onClick:Db(M.handleItemMouseEnter,I.props.onClick)}:B!=="axis"&&(ge={onMouseLeave:Db(M.handleItemMouseLeave,I.props.onMouseLeave),onMouseEnter:Db(M.handleItemMouseEnter,I.props.onMouseEnter)});var me=D.cloneElement(I,Me(Me({},L.props),ge));function Ce(at){return typeof U.dataKey=="function"?U.dataKey(at.payload):null}if(ye)if(G>=0){var je,Ie;if(U.dataKey&&!U.allowDuplicatedCategory){var Fe=typeof U.dataKey=="function"?Ce:"payload.".concat(U.dataKey.toString());je=cw(ee,Fe,K),Ie=Z&&q&&cw(q,Fe,K)}else je=ee?.[G],Ie=Z&&q&&q[G];if(fe||ie){var ce=I.props.activeIndex!==void 0?I.props.activeIndex:G;return[D.cloneElement(I,Me(Me(Me({},L.props),ge),{},{activeIndex:ce})),null,null]}if(!Ht(je))return[me].concat(lh(M.renderActivePoints({item:L,activePoint:je,basePoint:Ie,childIndex:G,isRange:Z})))}else{var Ne,Pe=(Ne=M.getItemByXY(M.state.activeCoordinate))!==null&&Ne!==void 0?Ne:{graphicalItem:me},_e=Pe.graphicalItem,qe=_e.item,Xe=qe===void 0?I:qe,Qe=_e.childIndex,it=Me(Me(Me({},L.props),ge),{},{activeIndex:Qe});return[D.cloneElement(Xe,it),null,null]}return Z?[me,null,null]:[me,null]}),bt(M,"renderCustomized",function(I,O,R){return D.cloneElement(I,Me(Me({key:"recharts-customized-".concat(R)},M.props),M.state))}),bt(M,"renderMap",{CartesianGrid:{handler:jb,once:!0},ReferenceArea:{handler:M.renderReferenceElement},ReferenceLine:{handler:jb},ReferenceDot:{handler:M.renderReferenceElement},XAxis:{handler:jb},YAxis:{handler:jb},Brush:{handler:M.renderBrush,once:!0},Bar:{handler:M.renderGraphicChild},Line:{handler:M.renderGraphicChild},Area:{handler:M.renderGraphicChild},Radar:{handler:M.renderGraphicChild},RadialBar:{handler:M.renderGraphicChild},Scatter:{handler:M.renderGraphicChild},Pie:{handler:M.renderGraphicChild},Funnel:{handler:M.renderGraphicChild},Tooltip:{handler:M.renderCursor,once:!0},PolarGrid:{handler:M.renderPolarGrid,once:!0},PolarAngleAxis:{handler:M.renderPolarAxis},PolarRadiusAxis:{handler:M.renderPolarAxis},Customized:{handler:M.renderCustomized}}),M.clipPathId="".concat((C=x.id)!==null&&C!==void 0?C:Bv("recharts"),"-clip"),M.throttleTriggeredAfterMouseMove=tA(M.triggeredAfterMouseMove,(k=x.throttleDelay)!==null&&k!==void 0?k:1e3/60),M.state={},M}return xKe(S,y),bKe(S,[{key:"componentDidMount",value:function(){var C,k;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:(C=this.props.margin.left)!==null&&C!==void 0?C:0,top:(k=this.props.margin.top)!==null&&k!==void 0?k:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:"displayDefaultTooltip",value:function(){var C=this.props,k=C.children,M=C.data,I=C.height,O=C.layout,R=ai(k,es);if(R){var L=R.props.defaultIndex;if(!(typeof L!="number"||L<0||L>this.state.tooltipTicks.length-1)){var B=this.state.tooltipTicks[L]&&this.state.tooltipTicks[L].value,_=OM(this.state,M,L,B),H=this.state.tooltipTicks[L].coordinate,U=(this.state.offset.top+I)/2,G=O==="horizontal",K=G?{x:H,y:U}:{y:H,x:U},z=this.state.formattedGraphicalItems.find(function(J){var ee=J.item;return ee.type.name==="Scatter"});z&&(K=Me(Me({},K),z.props.points[L].tooltipPosition),_=z.props.points[L].tooltipPayload);var ne={activeTooltipIndex:L,isTooltipActive:!0,activeLabel:B,activePayload:_,activeCoordinate:K};this.setState(ne),this.renderCursor(R),this.accessibilityManager.setIndex(L)}}}},{key:"getSnapshotBeforeUpdate",value:function(C,k){if(!this.props.accessibilityLayer)return null;if(this.state.tooltipTicks!==k.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==C.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==C.margin){var M,I;this.accessibilityManager.setDetails({offset:{left:(M=this.props.margin.left)!==null&&M!==void 0?M:0,top:(I=this.props.margin.top)!==null&&I!==void 0?I:0}})}return null}},{key:"componentDidUpdate",value:function(C){mC([ai(C.children,es)],[ai(this.props.children,es)])||this.displayDefaultTooltip()}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var C=ai(this.props.children,es);if(C&&typeof C.props.shared=="boolean"){var k=C.props.shared?"axis":"item";return s.indexOf(k)>=0?k:i}return i}},{key:"getMouseInfo",value:function(C){if(!this.container)return null;var k=this.container,M=k.getBoundingClientRect(),I=P7e(M),O={chartX:Math.round(C.pageX-I.left),chartY:Math.round(C.pageY-I.top)},R=M.width/k.offsetWidth||1,L=this.inRange(O.chartX,O.chartY,R);if(!L)return null;var B=this.state,_=B.xAxisMap,H=B.yAxisMap,U=this.getTooltipEventType();if(U!=="axis"&&_&&H){var G=cc(_).scale,K=cc(H).scale,z=G&&G.invert?G.invert(O.chartX):null,ne=K&&K.invert?K.invert(O.chartY):null;return Me(Me({},O),{},{xValue:z,yValue:ne})}var J=B6(this.state,this.props.data,this.props.layout,L);return J?Me(Me({},O),J):null}},{key:"inRange",value:function(C,k){var M=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,I=this.props.layout,O=C/M,R=k/M;if(I==="horizontal"||I==="vertical"){var L=this.state.offset,B=O>=L.left&&O<=L.left+L.width&&R>=L.top&&R<=L.top+L.height;return B?{x:O,y:R}:null}var _=this.state,H=_.angleAxisMap,U=_.radiusAxisMap;if(H&&U){var G=cc(H);return mF({x:O,y:R},G)}return null}},{key:"parseEventsOfWrapper",value:function(){var C=this.props.children,k=this.getTooltipEventType(),M=ai(C,es),I={};M&&k==="axis"&&(M.props.trigger==="click"?I={onClick:this.handleClick}:I={onMouseEnter:this.handleMouseEnter,onDoubleClick:this.handleDoubleClick,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd,onContextMenu:this.handleContextMenu});var O=uw(this.props,this.handleOuterEvent);return Me(Me({},O),I)}},{key:"addListener",value:function(){Ok.on(Pk,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){Ok.removeListener(Pk,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(C,k,M){for(var I=this.state.formattedGraphicalItems,O=0,R=I.length;O<R;O++){var L=I[O];if(L.item===C||L.props.key===C.key||k===cl(L.item.type)&&M===L.childIndex)return L}return null}},{key:"renderClipPath",value:function(){var C=this.clipPathId,k=this.state.offset,M=k.left,I=k.top,O=k.height,R=k.width;return Y.createElement("defs",null,Y.createElement("clipPath",{id:C},Y.createElement("rect",{x:M,y:I,height:O,width:R})))}},{key:"getXScales",value:function(){var C=this.state.xAxisMap;return C?Object.entries(C).reduce(function(k,M){var I=R6(M,2),O=I[0],R=I[1];return Me(Me({},k),{},bt({},O,R.scale))},{}):null}},{key:"getYScales",value:function(){var C=this.state.yAxisMap;return C?Object.entries(C).reduce(function(k,M){var I=R6(M,2),O=I[0],R=I[1];return Me(Me({},k),{},bt({},O,R.scale))},{}):null}},{key:"getXScaleByAxisId",value:function(C){var k;return(k=this.state.xAxisMap)===null||k===void 0||(k=k[C])===null||k===void 0?void 0:k.scale}},{key:"getYScaleByAxisId",value:function(C){var k;return(k=this.state.yAxisMap)===null||k===void 0||(k=k[C])===null||k===void 0?void 0:k.scale}},{key:"getItemByXY",value:function(C){var k=this.state,M=k.formattedGraphicalItems,I=k.activeItem;if(M&&M.length)for(var O=0,R=M.length;O<R;O++){var L=M[O],B=L.props,_=L.item,H=_.type.defaultProps!==void 0?Me(Me({},_.type.defaultProps),_.props):_.props,U=cl(_.type);if(U==="Bar"){var G=(B.data||[]).find(function(J){return JWe(C,J)});if(G)return{graphicalItem:L,payload:G}}else if(U==="RadialBar"){var K=(B.data||[]).find(function(J){return mF(C,J)});if(K)return{graphicalItem:L,payload:K}}else if(WT(L,I)||GT(L,I)||Rg(L,I)){var z=YGe({graphicalItem:L,activeTooltipItem:I,itemData:H.data}),ne=H.activeIndex===void 0?z:H.activeIndex;return{graphicalItem:Me(Me({},L),{},{childIndex:ne}),payload:Rg(L,I)?H.data[z]:L.props.data[z]}}}return null}},{key:"render",value:function(){var C=this;if(!A5(this))return null;var k=this.props,M=k.children,I=k.className,O=k.width,R=k.height,L=k.style,B=k.compact,_=k.title,H=k.desc,U=F6(k,hKe),G=_t(U,!1);if(B)return Y.createElement(f6,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},Y.createElement(vC,hf({},G,{width:O,height:R,title:_,desc:H}),this.renderClipPath(),O5(M,this.renderMap)));if(this.props.accessibilityLayer){var K,z;G.tabIndex=(K=this.props.tabIndex)!==null&&K!==void 0?K:0,G.role=(z=this.props.role)!==null&&z!==void 0?z:"application",G.onKeyDown=function(J){C.accessibilityManager.keyboardEvent(J)},G.onFocus=function(){C.accessibilityManager.focus()}}var ne=this.parseEventsOfWrapper();return Y.createElement(f6,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},Y.createElement("div",hf({className:$t("recharts-wrapper",I),style:Me({position:"relative",cursor:"default",width:O,height:R},L)},ne,{ref:function(ee){C.container=ee}}),Y.createElement(vC,hf({},G,{width:O,height:R,title:_,desc:H,style:DKe}),this.renderClipPath(),O5(M,this.renderMap)),this.renderLegend(),this.renderTooltip()))}}])}(D.Component);bt(b,"displayName",n),bt(b,"defaultProps",Me({layout:"horizontal",stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:{top:5,right:5,bottom:5,left:5},reverseStackOrder:!1,syncMethod:"index"},h)),bt(b,"getDerivedStateFromProps",function(y,S){var x=y.dataKey,C=y.data,k=y.children,M=y.width,I=y.height,O=y.layout,R=y.stackOffset,L=y.margin,B=S.dataStartIndex,_=S.dataEndIndex;if(S.updateId===void 0){var H=Y6(y);return Me(Me(Me({},H),{},{updateId:0},m(Me(Me({props:y},H),{},{updateId:0}),S)),{},{prevDataKey:x,prevData:C,prevWidth:M,prevHeight:I,prevLayout:O,prevStackOffset:R,prevMargin:L,prevChildren:k})}if(x!==S.prevDataKey||C!==S.prevData||M!==S.prevWidth||I!==S.prevHeight||O!==S.prevLayout||R!==S.prevStackOffset||!vf(L,S.prevMargin)){var U=Y6(y),G={chartX:S.chartX,chartY:S.chartY,isTooltipActive:S.isTooltipActive},K=Me(Me({},B6(S,C,O)),{},{updateId:S.updateId+1}),z=Me(Me(Me({},U),G),K);return Me(Me(Me({},z),m(Me({props:y},z),S)),{},{prevDataKey:x,prevData:C,prevWidth:M,prevHeight:I,prevLayout:O,prevStackOffset:R,prevMargin:L,prevChildren:k})}if(!mC(k,S.prevChildren)){var ne,J,ee,Z,q=ai(k,Jf),$=q&&(ne=(J=q.props)===null||J===void 0?void 0:J.startIndex)!==null&&ne!==void 0?ne:B,re=q&&(ee=(Z=q.props)===null||Z===void 0?void 0:Z.endIndex)!==null&&ee!==void 0?ee:_,le=$!==B||re!==_,ie=!Ht(C),fe=ie&&!le?S.updateId:S.updateId+1;return Me(Me({updateId:fe},m(Me(Me({props:y},S),{},{updateId:fe,dataStartIndex:$,dataEndIndex:re}),S)),{},{prevChildren:k,dataStartIndex:$,dataEndIndex:re})}return null}),bt(b,"renderActiveDot",function(y,S,x){var C;return D.isValidElement(y)?C=D.cloneElement(y,S):Pt(y)?C=y(S):C=Y.createElement(dN,S),Y.createElement(Xn,{className:"recharts-active-dot",key:x},C)});var v=D.forwardRef(function(S,x){return Y.createElement(b,hf({},S,{ref:x}))});return v.displayName=b.displayName,v},_Ke=OG({chartName:"LineChart",GraphicalChild:Gv,axisComponents:[{axisType:"xAxis",AxisComp:rl},{axisType:"yAxis",AxisComp:ol}],formatAxisMap:KW}),u0=OG({chartName:"BarChart",GraphicalChild:ys,defaultTooltipEventType:"axis",validateTooltipEventTypes:["axis","item"],axisComponents:[{axisType:"xAxis",AxisComp:rl},{axisType:"yAxis",AxisComp:ol}],formatAxisMap:KW});const SN="-",BKe=e=>{const t=UKe(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:a=>{const s=a.split(SN);return s[0]===""&&s.length!==1&&s.shift(),PG(s,t)||YKe(a)},getConflictingClassGroupIds:(a,s)=>{const l=n[a]||[];return s&&r[a]?[...l,...r[a]]:l}}},PG=(e,t)=>{if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),o=r?PG(e.slice(1),r):void 0;if(o)return o;if(t.validators.length===0)return;const i=e.join(SN);return t.validators.find(({validator:a})=>a(i))?.classGroupId},z6=/^\[(.+)\]$/,YKe=e=>{if(z6.test(e)){const t=z6.exec(e)[1],n=t?.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},UKe=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return VKe(Object.entries(e.classGroups),n).forEach(([i,a])=>{PM(a,r,i,t)}),r},PM=(e,t,n,r)=>{e.forEach(o=>{if(typeof o=="string"){const i=o===""?t:V6(t,o);i.classGroupId=n;return}if(typeof o=="function"){if(zKe(o)){PM(o(r),t,n,r);return}t.validators.push({validator:o,classGroupId:n});return}Object.entries(o).forEach(([i,a])=>{PM(a,V6(t,i),n,r)})})},V6=(e,t)=>{let n=e;return t.split(SN).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},zKe=e=>e.isThemeGetter,VKe=(e,t)=>t?e.map(([n,r])=>{const o=r.map(i=>typeof i=="string"?t+i:typeof i=="object"?Object.fromEntries(Object.entries(i).map(([a,s])=>[t+a,s])):i);return[n,o]}):e,WKe=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const o=(i,a)=>{n.set(i,a),t++,t>e&&(t=0,r=n,n=new Map)};return{get(i){let a=n.get(i);if(a!==void 0)return a;if((a=r.get(i))!==void 0)return o(i,a),a},set(i,a){n.has(i)?n.set(i,a):o(i,a)}}},jG="!",GKe=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,o=t[0],i=t.length,a=s=>{const l=[];let u=0,d=0,h;for(let y=0;y<s.length;y++){let S=s[y];if(u===0){if(S===o&&(r||s.slice(y,y+i)===t)){l.push(s.slice(d,y)),d=y+i;continue}if(S==="/"){h=y;continue}}S==="["?u++:S==="]"&&u--}const p=l.length===0?s:s.substring(d),m=p.startsWith(jG),b=m?p.substring(1):p,v=h&&h>d?h-d:void 0;return{modifiers:l,hasImportantModifier:m,baseClassName:b,maybePostfixModifierPosition:v}};return n?s=>n({className:s,parseClassName:a}):a},ZKe=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach(r=>{r[0]==="["?(t.push(...n.sort(),r),n=[]):n.push(r)}),t.push(...n.sort()),t},$Ke=e=>({cache:WKe(e.cacheSize),parseClassName:GKe(e),...BKe(e)}),qKe=/\s+/,KKe=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o}=t,i=[],a=e.trim().split(qKe);let s="";for(let l=a.length-1;l>=0;l-=1){const u=a[l],{modifiers:d,hasImportantModifier:h,baseClassName:p,maybePostfixModifierPosition:m}=n(u);let b=!!m,v=r(b?p.substring(0,m):p);if(!v){if(!b){s=u+(s.length>0?" "+s:s);continue}if(v=r(p),!v){s=u+(s.length>0?" "+s:s);continue}b=!1}const y=ZKe(d).join(":"),S=h?y+jG:y,x=S+v;if(i.includes(x))continue;i.push(x);const C=o(v,b);for(let k=0;k<C.length;++k){const M=C[k];i.push(S+M)}s=u+(s.length>0?" "+s:s)}return s};function XKe(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=LG(t))&&(r&&(r+=" "),r+=n);return r}const LG=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=LG(e[r]))&&(n&&(n+=" "),n+=t);return n};function JKe(e,...t){let n,r,o,i=a;function a(l){const u=t.reduce((d,h)=>h(d),e());return n=$Ke(u),r=n.cache.get,o=n.cache.set,i=s,s(l)}function s(l){const u=r(l);if(u)return u;const d=KKe(l,n);return o(l,d),d}return function(){return i(XKe.apply(null,arguments))}}const kn=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},RG=/^\[(?:([a-z-]+):)?(.+)\]$/i,QKe=/^\d+\/\d+$/,eXe=new Set(["px","full","screen"]),tXe=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,nXe=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,rXe=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,oXe=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,iXe=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Zs=e=>Sf(e)||eXe.has(e)||QKe.test(e),oc=e=>$h(e,"length",hXe),Sf=e=>!!e&&!Number.isNaN(Number(e)),Lk=e=>$h(e,"number",Sf),Kp=e=>!!e&&Number.isInteger(Number(e)),aXe=e=>e.endsWith("%")&&Sf(e.slice(0,-1)),At=e=>RG.test(e),ic=e=>tXe.test(e),sXe=new Set(["length","size","percentage"]),lXe=e=>$h(e,sXe,FG),cXe=e=>$h(e,"position",FG),uXe=new Set(["image","url"]),dXe=e=>$h(e,uXe,mXe),fXe=e=>$h(e,"",pXe),Xp=()=>!0,$h=(e,t,n)=>{const r=RG.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},hXe=e=>nXe.test(e)&&!rXe.test(e),FG=()=>!1,pXe=e=>oXe.test(e),mXe=e=>iXe.test(e),gXe=()=>{const e=kn("colors"),t=kn("spacing"),n=kn("blur"),r=kn("brightness"),o=kn("borderColor"),i=kn("borderRadius"),a=kn("borderSpacing"),s=kn("borderWidth"),l=kn("contrast"),u=kn("grayscale"),d=kn("hueRotate"),h=kn("invert"),p=kn("gap"),m=kn("gradientColorStops"),b=kn("gradientColorStopPositions"),v=kn("inset"),y=kn("margin"),S=kn("opacity"),x=kn("padding"),C=kn("saturate"),k=kn("scale"),M=kn("sepia"),I=kn("skew"),O=kn("space"),R=kn("translate"),L=()=>["auto","contain","none"],B=()=>["auto","hidden","clip","visible","scroll"],_=()=>["auto",At,t],H=()=>[At,t],U=()=>["",Zs,oc],G=()=>["auto",Sf,At],K=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],z=()=>["solid","dashed","dotted","double","none"],ne=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],J=()=>["start","end","center","between","around","evenly","stretch"],ee=()=>["","0",At],Z=()=>["auto","avoid","all","avoid-page","page","left","right","column"],q=()=>[Sf,At];return{cacheSize:500,separator:":",theme:{colors:[Xp],spacing:[Zs,oc],blur:["none","",ic,At],brightness:q(),borderColor:[e],borderRadius:["none","","full",ic,At],borderSpacing:H(),borderWidth:U(),contrast:q(),grayscale:ee(),hueRotate:q(),invert:ee(),gap:H(),gradientColorStops:[e],gradientColorStopPositions:[aXe,oc],inset:_(),margin:_(),opacity:q(),padding:H(),saturate:q(),scale:q(),sepia:ee(),skew:q(),space:H(),translate:H()},classGroups:{aspect:[{aspect:["auto","square","video",At]}],container:["container"],columns:[{columns:[ic]}],"break-after":[{"break-after":Z()}],"break-before":[{"break-before":Z()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...K(),At]}],overflow:[{overflow:B()}],"overflow-x":[{"overflow-x":B()}],"overflow-y":[{"overflow-y":B()}],overscroll:[{overscroll:L()}],"overscroll-x":[{"overscroll-x":L()}],"overscroll-y":[{"overscroll-y":L()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[v]}],"inset-x":[{"inset-x":[v]}],"inset-y":[{"inset-y":[v]}],start:[{start:[v]}],end:[{end:[v]}],top:[{top:[v]}],right:[{right:[v]}],bottom:[{bottom:[v]}],left:[{left:[v]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Kp,At]}],basis:[{basis:_()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",At]}],grow:[{grow:ee()}],shrink:[{shrink:ee()}],order:[{order:["first","last","none",Kp,At]}],"grid-cols":[{"grid-cols":[Xp]}],"col-start-end":[{col:["auto",{span:["full",Kp,At]},At]}],"col-start":[{"col-start":G()}],"col-end":[{"col-end":G()}],"grid-rows":[{"grid-rows":[Xp]}],"row-start-end":[{row:["auto",{span:[Kp,At]},At]}],"row-start":[{"row-start":G()}],"row-end":[{"row-end":G()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",At]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",At]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal",...J()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...J(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...J(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[x]}],px:[{px:[x]}],py:[{py:[x]}],ps:[{ps:[x]}],pe:[{pe:[x]}],pt:[{pt:[x]}],pr:[{pr:[x]}],pb:[{pb:[x]}],pl:[{pl:[x]}],m:[{m:[y]}],mx:[{mx:[y]}],my:[{my:[y]}],ms:[{ms:[y]}],me:[{me:[y]}],mt:[{mt:[y]}],mr:[{mr:[y]}],mb:[{mb:[y]}],ml:[{ml:[y]}],"space-x":[{"space-x":[O]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[O]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",At,t]}],"min-w":[{"min-w":[At,t,"min","max","fit"]}],"max-w":[{"max-w":[At,t,"none","full","min","max","fit","prose",{screen:[ic]},ic]}],h:[{h:[At,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[At,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[At,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[At,t,"auto","min","max","fit"]}],"font-size":[{text:["base",ic,oc]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Lk]}],"font-family":[{font:[Xp]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",At]}],"line-clamp":[{"line-clamp":["none",Sf,Lk]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Zs,At]}],"list-image":[{"list-image":["none",At]}],"list-style-type":[{list:["none","disc","decimal",At]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[S]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[S]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...z(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Zs,oc]}],"underline-offset":[{"underline-offset":["auto",Zs,At]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:H()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",At]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",At]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[S]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...K(),cXe]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",lXe]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},dXe]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[b]}],"gradient-via-pos":[{via:[b]}],"gradient-to-pos":[{to:[b]}],"gradient-from":[{from:[m]}],"gradient-via":[{via:[m]}],"gradient-to":[{to:[m]}],rounded:[{rounded:[i]}],"rounded-s":[{"rounded-s":[i]}],"rounded-e":[{"rounded-e":[i]}],"rounded-t":[{"rounded-t":[i]}],"rounded-r":[{"rounded-r":[i]}],"rounded-b":[{"rounded-b":[i]}],"rounded-l":[{"rounded-l":[i]}],"rounded-ss":[{"rounded-ss":[i]}],"rounded-se":[{"rounded-se":[i]}],"rounded-ee":[{"rounded-ee":[i]}],"rounded-es":[{"rounded-es":[i]}],"rounded-tl":[{"rounded-tl":[i]}],"rounded-tr":[{"rounded-tr":[i]}],"rounded-br":[{"rounded-br":[i]}],"rounded-bl":[{"rounded-bl":[i]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[S]}],"border-style":[{border:[...z(),"hidden"]}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[S]}],"divide-style":[{divide:z()}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-s":[{"border-s":[o]}],"border-color-e":[{"border-e":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:["",...z()]}],"outline-offset":[{"outline-offset":[Zs,At]}],"outline-w":[{outline:[Zs,oc]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:U()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[S]}],"ring-offset-w":[{"ring-offset":[Zs,oc]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",ic,fXe]}],"shadow-color":[{shadow:[Xp]}],opacity:[{opacity:[S]}],"mix-blend":[{"mix-blend":[...ne(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":ne()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",ic,At]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[h]}],saturate:[{saturate:[C]}],sepia:[{sepia:[M]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[h]}],"backdrop-opacity":[{"backdrop-opacity":[S]}],"backdrop-saturate":[{"backdrop-saturate":[C]}],"backdrop-sepia":[{"backdrop-sepia":[M]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[a]}],"border-spacing-x":[{"border-spacing-x":[a]}],"border-spacing-y":[{"border-spacing-y":[a]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",At]}],duration:[{duration:q()}],ease:[{ease:["linear","in","out","in-out",At]}],delay:[{delay:q()}],animate:[{animate:["none","spin","ping","pulse","bounce",At]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[k]}],"scale-x":[{"scale-x":[k]}],"scale-y":[{"scale-y":[k]}],rotate:[{rotate:[Kp,At]}],"translate-x":[{"translate-x":[R]}],"translate-y":[{"translate-y":[R]}],"skew-x":[{"skew-x":[I]}],"skew-y":[{"skew-y":[I]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",At]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",At]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":H()}],"scroll-mx":[{"scroll-mx":H()}],"scroll-my":[{"scroll-my":H()}],"scroll-ms":[{"scroll-ms":H()}],"scroll-me":[{"scroll-me":H()}],"scroll-mt":[{"scroll-mt":H()}],"scroll-mr":[{"scroll-mr":H()}],"scroll-mb":[{"scroll-mb":H()}],"scroll-ml":[{"scroll-ml":H()}],"scroll-p":[{"scroll-p":H()}],"scroll-px":[{"scroll-px":H()}],"scroll-py":[{"scroll-py":H()}],"scroll-ps":[{"scroll-ps":H()}],"scroll-pe":[{"scroll-pe":H()}],"scroll-pt":[{"scroll-pt":H()}],"scroll-pr":[{"scroll-pr":H()}],"scroll-pb":[{"scroll-pb":H()}],"scroll-pl":[{"scroll-pl":H()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",At]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Zs,oc,Lk]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},vXe=JKe(gXe);function li(...e){return vXe(tn(e))}function am({className:e,...t}){return w.jsx("div",{"data-slot":"card",className:li("th:bg-card th:text-card-foreground th:flex th:flex-col th:gap-6 th:rounded-xl th:border th:border-border th:py-6 th:shadow-sm",e),...t})}function sm({className:e,...t}){return w.jsx("div",{"data-slot":"card-header",className:li("th:@container/card-header th:grid th:auto-rows-min th:grid-rows-[auto_auto] th:items-start th:gap-1.5 th:px-6 has-[data-slot=card-action]:th:grid-cols-[1fr_auto] [.border-b]:th:pb-6",e),...t})}function lm({className:e,...t}){return w.jsx("div",{"data-slot":"card-title",className:li("th:leading-none th:font-semibold",e),...t})}function cm({className:e,...t}){return w.jsx("div",{"data-slot":"card-description",className:li("th:text-muted-foreground th:text-sm",e),...t})}function um({className:e,...t}){return w.jsx("div",{"data-slot":"card-content",className:li("th:px-6",e),...t})}function yXe({className:e,...t}){return w.jsx("div",{"data-slot":"card-footer",className:li("th:flex th:items-center th:px-6 [.border-t]:th:pt-6",e),...t})}const bXe={light:"",dark:".dark"},HG=D.createContext(null);function wXe(){const e=D.useContext(HG);if(!e)throw new Error("useChart must be used within a <ChartContainer />");return e}function dm({id:e,className:t,children:n,config:r,...o}){const i=D.useId(),a=`chart-${e||i.replace(/:/g,"")}`;return w.jsx(HG.Provider,{value:{config:r},children:w.jsxs("div",{"data-slot":"chart","data-chart":a,className:li("[&_.recharts-cartesian-axis-tick_text]:th:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke=#ccc]]:th:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:th:stroke-border [&_.recharts-polar-grid_[stroke=#ccc]]:th:stroke-border [&_.recharts-radial-bar-background-sector]:th:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:th:fill-muted [&_.recharts-reference-line_[stroke=#ccc]]:th:stroke-border th:flex th:aspect-video th:justify-center th:text-xs [&_.recharts-dot[stroke=#fff]]:th:stroke-transparent [&_.recharts-layer]:th:outline-hidden [&_.recharts-sector]:th:outline-hidden [&_.recharts-sector[stroke=#fff]]:th:stroke-transparent [&_.recharts-surface]:th:outline-hidden",t),...o,children:[w.jsx(SXe,{id:a,config:r}),w.jsx(E7e,{children:n})]})})}const SXe=({id:e,config:t})=>{const n=Object.entries(t).filter(([,r])=>r.theme||r.color);return n.length?w.jsx("style",{dangerouslySetInnerHTML:{__html:Object.entries(bXe).map(([r,o])=>`
|
|
|
${o} [data-chart=${e}] {
|
|
|
${n.map(([i,a])=>{const s=a.theme?.[r]||a.color;return s?` --color-${i}: ${s};`:null}).join(`
|
|
|
`)}
|
|
|
}
|
|
|
`).join(`
|
|
|
`)}}):null},fm=es;function Lb({active:e,payload:t,className:n,indicator:r="dot",hideLabel:o=!1,hideIndicator:i=!1,label:a,labelFormatter:s,labelClassName:l,formatter:u,color:d,nameKey:h,labelKey:p}){const{config:m}=wXe(),b=D.useMemo(()=>{if(o||!t?.length)return null;const[y]=t,S=`${p||y?.dataKey||y?.name||"value"}`,x=W6(m,y,S),C=!p&&typeof a=="string"?m[a]?.label||a:x?.label;return s?w.jsx("div",{className:li("th:font-medium",l),children:s(C,t)}):C?w.jsx("div",{className:li("th:font-medium",l),children:C}):null},[a,s,t,o,l,m,p]);if(!e||!t?.length)return null;const v=t.length===1&&r!=="dot";return w.jsxs("div",{className:li("th:border-border/50 th:bg-background th:grid th:min-w-[8rem] th:items-start th:gap-1.5 th:rounded-lg th:border th:px-2.5 th:py-1.5 th:text-xs th:shadow-xl",n),children:[v?null:b,w.jsx("div",{className:"th:grid th:gap-1.5",children:t.map((y,S)=>{const x=`${h||y.name||y.dataKey||"value"}`,C=W6(m,y,x),k=d||y.payload.fill||y.color;return w.jsx("div",{className:li("[&>svg]:th:text-muted-foreground th:flex th:w-full th:flex-wrap th:items-stretch th:gap-2 [&>svg]:th:h-2.5 [&>svg]:th:w-2.5",r==="dot"&&"th:items-center"),children:u&&y?.value!==void 0&&y.name?u(y.value,y.name,y,S,y.payload):w.jsxs(w.Fragment,{children:[C?.icon?w.jsx(C.icon,{}):!i&&w.jsx("div",{className:li("th:shrink-0 th:rounded-[2px] th:border-(--color-border) th:bg-(--color-bg)",{"h-2.5 w-2.5":r==="dot","w-1":r==="line","w-0 border-[1.5px] border-dashed bg-transparent":r==="dashed","my-0.5":v&&r==="dashed"}),style:{"--color-bg":k,"--color-border":k}}),w.jsxs("div",{className:li("th:flex th:flex-1 th:justify-between th:leading-none",v?"th:items-end":"th:items-center"),children:[w.jsxs("div",{className:"th:grid th:gap-1.5",children:[v?b:null,w.jsx("span",{className:"th:text-muted-foreground",children:C?.label||y.name})]}),y.value&&w.jsx("span",{className:"th:text-foreground th:font-mono th:font-medium th:tabular-nums",children:y.value.toLocaleString()})]})]})},y.dataKey)})})]})}function W6(e,t,n){if(typeof t!="object"||t===null)return;const r="payload"in t&&typeof t.payload=="object"&&t.payload!==null?t.payload:void 0;let o=n;return n in t&&typeof t[n]=="string"?o=t[n]:r&&n in r&&typeof r[n]=="string"&&(o=r[n]),o in e?e[o]:e[n]}const TXe={item:{label:"Item",color:"var(--chart-3)"}};function xXe({memos:e}){const[t,n]=D.useState([]);D.useEffect(()=>{const o=[{period:"00:00-03:00",count:0},{period:"03:00-06:00",count:0},{period:"06:00-09:00",count:0},{period:"09:00-12:00",count:0},{period:"12:00-15:00",count:0},{period:"15:00-18:00",count:0},{period:"18:00-21:00",count:0},{period:"21:00-24:00",count:0}];e.forEach(i=>{const a=new Date(i.createdAt).getHours();a<3?o[0].count++:a<6?o[1].count++:a<9?o[2].count++:a<12?o[3].count++:a<15?o[4].count++:a<18?o[5].count++:a<21?o[6].count++:o[7].count++}),n(o)},[e]);const r=D.useMemo(()=>{if(t.length===0)return[0,0];const o=Math.max(...t.map(i=>i.count));return[0,Math.ceil(o)]},[t]);return w.jsx("div",{className:"twp",children:w.jsxs(am,{className:"th:w-full th:h-full th:flex th:flex-col th:rounded th:mb-4",children:[w.jsx(sm,{className:"th:flex th:flex-row th:flex-wrap th:gap-2 th:py-2 sm:th:gap-0 th:justify-between th:border-border th:border-b",children:w.jsxs("div",{className:"th:flex th:flex-col th:gap-1",children:[w.jsx(lm,{children:E("Time Distribution")}),w.jsx(cm,{children:E("When do you write thinos")})]})}),w.jsx(um,{className:"th:w-full th:h-full th:my-4 th:h-96",children:w.jsx(dm,{config:TXe,className:"th:aspect-auto th:h-full th:w-full",children:w.jsxs(u0,{data:t,margin:{top:20,right:10,left:0,bottom:10},children:[w.jsx(ff,{strokeDasharray:"3 3"}),w.jsx(rl,{dataKey:"period",tickLine:!1,tickMargin:10,axisLine:!1}),w.jsx(ol,{domain:r,allowDecimals:!1}),w.jsx(fm,{content:w.jsx(IXe,{})}),w.jsx(ys,{dataKey:"count",fill:"var(--chart-2)",radius:[4,4,0,0]})]})})})]})})}const IXe=({active:e,payload:t})=>{if(e&&t&&t.length){const n=t[0].payload;return w.jsxs("div",{className:"th:p-2 th:border th:border-border th:bg-secondary th:rounded th:shadow",children:[w.jsx("p",{className:"th:font-bold",children:n.period}),w.jsxs("p",{children:[n.count," thinos"]})]})}return null},kXe=D.forwardRef((e,t)=>{const{currentDate:n,setCurrentDateStamp:r,showTimeDistributionChart:o}=e,[i,a]=D.useState(!1),s=Le.getDateStampByDate(Le.getDateString(n)),l=D.useRef(null);D.useEffect(()=>{l.current&&N.setIcon(l.current,"more-horizontal")},[l.current]);const u=d=>{r(d)};return D.useImperativeHandle(t,()=>({closeDatePicker:()=>{a(!1)}})),w.jsxs(w.Fragment,{children:[w.jsxs("div",{className:"date-card-container",children:[w.jsxs("div",{className:"date-container-details",children:[w.jsxs("div",{className:"details-text",children:[N.moment(s,"x").format("dddd"),w.jsx("div",{className:"date-text",children:N.moment(s,"x").format("MMM")+N.moment(s,"x").format("DD")})]}),w.jsx("div",{className:"details-logo-text",children:E("Daily Memos")})]}),w.jsxs("div",{className:"date-container-info",children:[w.jsxs("div",{className:"date-container-info-text",children:["Week ",w.jsx("div",{className:"week-text",children:N.moment(s,"x").format("ww")}),"of ",w.jsx("div",{className:"year-text",children:N.moment(s,"x").format("YYYY")})]}),w.jsx("div",{ref:l,onClick:d=>{const h=new N.Menu;h.addItem(p=>{p.setTitle(E("Show Time Distribution")),p.setIcon("chart-bar"),p.onClick(()=>{o()})}),h.addItem(p=>{p.setTitle(E(i?"Hide date picker":"Show date picker")),p.setIcon("calendar"),p.onClick(()=>{a(!i)})}),h.showAtMouseEvent(d.nativeEvent)}})]})]}),w.jsx(xS,{className:`date-picker ${i?"":"thino-hidden"}`,datestamp:s,handleDateStampChange:u})]})}),EXe=({thino:e})=>{const t=D.useCallback(()=>{pa(e)},[]);return w.jsxs("div",{className:"daily-thino-wrapper",children:[w.jsx("div",{className:"time-wrapper",onClick:t,children:w.jsx("span",{className:"normal-text",children:N.moment(e.createdAt,"YYYY/MM/DD HH:mm:ss").format("HH:mm")})}),w.jsx("div",{className:"daily-thino-container",children:w.jsx(vo,{memo:e})})]})},CXe=()=>{const{locationState:{query:e},memoState:{memos:t},dailyNotesState:{settings:n,app:r,plugin:o}}=D.useContext(ct),i=Dc(),[a,s]=D.useState([]),[l,u]=D.useState(Le.getDateStampByDate(Le.getDateString(N.moment().format("YYYY-MM-DD HH:mm:ss")))),[d,h]=D.useState(!1),p=D.useRef(),m=D.useRef(null),b=Y.useRef(null),v=D.useRef(null),[y,S]=D.useState(!1);D.useEffect(()=>{e.duration&&e.duration.from&&e.duration.to&&u(e.duration.from)},[e.duration]),D.useEffect(()=>{v.current&&(N.setIcon&&v&&!y&&N.setIcon(v.current,"share"),N.setIcon&&v&&y&&N.setIcon(v.current,"chrome"))},[v.current,y]),D.useEffect(()=>{hc({memos:t,query:e,filterOptions:{filterDoneTasks:!1},plugin:o}).then(k=>{const M=k.filter(I=>Le.getTimeStampByDate(I.createdAt)>=l&&Le.getTimeStampByDate(I.createdAt)<l+Uo).filter(I=>I.deletedAt==="").sort((I,O)=>Le.getTimeStampByDate(I.createdAt)-Le.getTimeStampByDate(O.createdAt));s(M.slice(0,40)),i.setFinish()})},[t,l,b.current,e]);const x=async()=>{p.current&&p?.current?.closeDatePicker(),S(!0),document.body.toggleClass("thino-share-page",!0),setTimeout(async()=>{if(!m.current){S(!1);return}await TA(m.current),ES(m.current,{pixelRatio:window.devicePixelRatio*2}).then(k=>{if(n?.AutoSaveWhenOnMobile&&N.Platform.isMobile){const M=k.split("base64,")[1];dS(M,"image/png").arrayBuffer().then(async O=>{let R;const L="png",B=Il();for(const _ in B)if(B[_]instanceof N.TFile){R=B[_];break}R!==void 0&&await r.vault.createBinary(await vault.getAvailablePathForAttachments(`Pasted Image ${N.moment().format("YYYYMMDDHHmmss")}`,L,R),O)})}document.body.toggleClass("thino-share-page",!1),CS({imgUrl:k}),S(!1)}).catch(()=>{document.body.toggleClass("thino-share-page",!1),S(!1)})},0)},C=w.jsxs("div",{className:"header-right-section",children:[w.jsxs("div",{className:"btns-container",children:[w.jsx("span",{ref:k=>{N.setIcon&&k&&N.setIcon(k,"chevron-left")},className:"btn btn-text",onClick:()=>u(k=>k-Uo)}),w.jsx("span",{ref:k=>{N.setIcon&&k&&N.setIcon(k,"chevron-right")},className:"btn btn-text",onClick:()=>u(k=>k+Uo)}),w.jsx("span",{ref:v,className:tn("btn btn-text share-btn",y?"generating":""),onClick:x})]}),w.jsx(IA,{}),w.jsx(nv,{})]});return w.jsxs("div",{className:"daily-thinos-list-wrapper",ref:b,children:[w.jsx(Yh,{rightContent:C}),w.jsx(Fv,{thinosCount:a.length,thinos:a}),w.jsx("div",{className:"daily-thinos-view-wrapper thino-stat",children:w.jsxs("div",{ref:m,className:"daily-thinos-view-container",children:[w.jsx(kXe,{ref:p,currentDate:new Date(l),setCurrentDateStamp:u,showTimeDistributionChart:()=>h(!d)}),d&&w.jsx(xXe,{memos:a}),w.jsx(AA,{isLoading:i.isLoading,isEmpty:a.length===0,emptyMessage:E("Noooop!")}),!i.isLoading&&a.length>0&&w.jsx("div",{className:"daily-thinos-list-container",children:a.map(k=>w.jsx(EXe,{thino:k},`${k.id}-${k.updatedAt}`))})]})})]})};var Wt=(e=>(e[e.New=0]="New",e[e.Learning=1]="Learning",e[e.Review=2]="Review",e[e.Relearning=3]="Relearning",e))(Wt||{}),Ye=(e=>(e[e.Manual=0]="Manual",e[e.Again=1]="Again",e[e.Hard=2]="Hard",e[e.Good=3]="Good",e[e.Easy=4]="Easy",e))(Ye||{});class jt{static card(t){return{...t,state:jt.state(t.state),due:jt.time(t.due),last_review:t.last_review?jt.time(t.last_review):void 0}}static rating(t){if(typeof t=="string"){const n=t.charAt(0).toUpperCase(),r=t.slice(1).toLowerCase(),o=Ye[`${n}${r}`];if(o===void 0)throw new Error(`Invalid rating:[${t}]`);return o}else if(typeof t=="number")return t;throw new Error(`Invalid rating:[${t}]`)}static state(t){if(typeof t=="string"){const n=t.charAt(0).toUpperCase(),r=t.slice(1).toLowerCase(),o=Wt[`${n}${r}`];if(o===void 0)throw new Error(`Invalid state:[${t}]`);return o}else if(typeof t=="number")return t;throw new Error(`Invalid state:[${t}]`)}static time(t){if(typeof t=="object"&&t instanceof Date)return t;if(typeof t=="string"){const n=Date.parse(t);if(isNaN(n))throw new Error(`Invalid date:[${t}]`);return new Date(n)}else if(typeof t=="number")return new Date(t);throw new Error(`Invalid date:[${t}]`)}static review_log(t){return{...t,due:jt.time(t.due),rating:jt.rating(t.rating),state:jt.state(t.state),review:jt.time(t.review)}}}const MXe=.9,DXe=36500,AXe=[.40255,1.18385,3.173,15.69105,7.1949,.5345,1.4604,.0046,1.54575,.1192,1.01925,1.9395,.11,.29605,2.2698,.2315,2.9898,.51655,.6621],NXe=!1,OXe=!0,jM=e=>{let t=AXe;return e?.w&&(e.w.length===19?t=e?.w:e.w.length===17&&(t=e?.w.concat([0,0]),t[4]=+(t[5]*2+t[4]).toFixed(8),t[5]=+(Math.log(t[5]*3+1)/3).toFixed(8),t[6]=+(t[6]+.5).toFixed(8),console.debug("[FSRS V5]auto fill w to 19 length"))),{request_retention:e?.request_retention||MXe,maximum_interval:e?.maximum_interval||DXe,w:t,enable_fuzz:e?.enable_fuzz??NXe,enable_short_term:e?.enable_short_term??OXe}};function oS(e,t){const n={due:e?jt.time(e):new Date,stability:0,difficulty:0,elapsed_days:0,scheduled_days:0,reps:0,lapses:0,state:Wt.New,last_review:void 0};return t&&typeof t=="function"?t(n):n}Date.prototype.scheduler=function(e,t){return PXe(this,e,t)},Date.prototype.diff=function(e,t){return jXe(this,e,t)},Date.prototype.format=function(){return LXe(this)},Date.prototype.dueFormat=function(e,t,n){return RXe(this,e,t,n)};function PXe(e,t,n){return new Date(n?Xu(e).getTime()+t*24*60*60*1e3:Xu(e).getTime()+t*60*1e3)}function jXe(e,t,n){if(!e||!t)throw new Error("Invalid date");const r=Xu(e).getTime()-Xu(t).getTime();let o=0;switch(n){case"days":o=Math.floor(r/(24*60*60*1e3));break;case"minutes":o=Math.floor(r/(60*1e3));break}return o}function LXe(e){const t=Xu(e),n=t.getFullYear(),r=t.getMonth()+1,o=t.getDate(),i=t.getHours(),a=t.getMinutes(),s=t.getSeconds();return`${n}-${Jp(r)}-${Jp(o)} ${Jp(i)}:${Jp(a)}:${Jp(s)}`}function Jp(e){return e<10?`0${e}`:`${e}`}const Rk=[60,60,24,31,12],Fk=["second","min","hour","day","month","year"];function RXe(e,t,n,r=Fk){e=Xu(e),t=Xu(t),r.length!==Fk.length&&(r=Fk);let o=e.getTime()-t.getTime(),i;for(o/=1e3,i=0;i<Rk.length&&!(o<Rk[i]);i++)o/=Rk[i];return`${Math.floor(o)}${n?r[i]:""}`}function Xu(e){return jt.time(e)}const FXe=[Ye.Again,Ye.Hard,Ye.Good,Ye.Easy],HXe=[{start:2.5,end:7,factor:.15},{start:7,end:20,factor:.1},{start:20,end:1/0,factor:.05}];function _Xe(e,t,n){let r=1;for(const a of HXe)r+=a.factor*Math.max(Math.min(e,a.end)-a.start,0);e=Math.min(e,n);let o=Math.max(2,Math.round(e-r));const i=Math.min(Math.round(e+r),n);return e>t&&(o=Math.max(o,t+1)),o=Math.min(o,i),{min_ivl:o,max_ivl:i}}function Hk(e,t,n){return Math.min(Math.max(e,t),n)}class BXe{c;s0;s1;s2;constructor(t){const n=YXe();this.c=1,this.s0=n(" "),this.s1=n(" "),this.s2=n(" "),t==null&&(t=+new Date),this.s0-=n(t),this.s0<0&&(this.s0+=1),this.s1-=n(t),this.s1<0&&(this.s1+=1),this.s2-=n(t),this.s2<0&&(this.s2+=1)}next(){const t=2091639*this.s0+this.c*23283064365386963e-26;return this.s0=this.s1,this.s1=this.s2,this.s2=t-(this.c=t|0),this.s2}set state(t){this.c=t.c,this.s0=t.s0,this.s1=t.s1,this.s2=t.s2}get state(){return{c:this.c,s0:this.s0,s1:this.s1,s2:this.s2}}}function YXe(){let e=4022871197;return function(t){t=String(t);for(let n=0;n<t.length;n++){e+=t.charCodeAt(n);let r=.02519603282416938*e;e=r>>>0,r-=e,r*=e,e=r>>>0,r-=e,e+=r*4294967296}return(e>>>0)*23283064365386963e-26}}function UXe(e){const t=new BXe(e),n=()=>t.next();return n.int32=()=>t.next()*4294967296|0,n.double=()=>n()+(n()*2097152|0)*11102230246251565e-32,n.state=()=>t.state,n.importState=r=>(t.state=r,n),n}const G6=-.5,Z6=19/81;class zXe{param;intervalModifier;_seed;constructor(t){this.param=new Proxy(jM(t),this.params_handler_proxy()),this.intervalModifier=this.calculate_interval_modifier(this.param.request_retention)}get interval_modifier(){return this.intervalModifier}set seed(t){this._seed=t}calculate_interval_modifier(t){if(t<=0||t>1)throw new Error("Requested retention rate should be in the range (0,1]");return+((Math.pow(t,1/G6)-1)/Z6).toFixed(8)}get parameters(){return this.param}set parameters(t){this.update_parameters(t)}params_handler_proxy(){const t=this;return{set:function(n,r,o){return r==="request_retention"&&Number.isFinite(o)&&(t.intervalModifier=t.calculate_interval_modifier(Number(o))),Reflect.set(n,r,o),!0}}}update_parameters(t){const n=jM(t);for(const r in n)if(r in this.param){const o=r;this.param[o]=n[o]}}init_stability(t){return Math.max(this.param.w[t-1],.1)}init_difficulty(t){return this.constrain_difficulty(this.param.w[4]-Math.exp((t-1)*this.param.w[5])+1)}apply_fuzz(t,n){if(!this.param.enable_fuzz||t<2.5)return Math.round(t);const r=UXe(this._seed)(),{min_ivl:o,max_ivl:i}=_Xe(t,n,this.param.maximum_interval);return Math.floor(r*(i-o+1)+o)}next_interval(t,n){const r=Math.min(Math.max(1,Math.round(t*this.intervalModifier)),this.param.maximum_interval);return this.apply_fuzz(r,n)}linear_damping(t,n){return+(t*(10-n)/9).toFixed(8)}next_difficulty(t,n){const r=-this.param.w[6]*(n-3),o=t+this.linear_damping(r,t);return this.constrain_difficulty(this.mean_reversion(this.init_difficulty(Ye.Easy),o))}constrain_difficulty(t){return Math.min(Math.max(+t.toFixed(8),1),10)}mean_reversion(t,n){return+(this.param.w[7]*t+(1-this.param.w[7])*n).toFixed(8)}next_recall_stability(t,n,r,o){const i=Ye.Hard===o?this.param.w[15]:1,a=Ye.Easy===o?this.param.w[16]:1;return+Hk(n*(1+Math.exp(this.param.w[8])*(11-t)*Math.pow(n,-this.param.w[9])*(Math.exp((1-r)*this.param.w[10])-1)*i*a),.01,36500).toFixed(8)}next_forget_stability(t,n,r){return+Hk(this.param.w[11]*Math.pow(t,-this.param.w[12])*(Math.pow(n+1,this.param.w[13])-1)*Math.exp((1-r)*this.param.w[14]),.01,36500).toFixed(8)}next_short_term_stability(t,n){return+Hk(t*Math.exp(this.param.w[17]*(n-3+this.param.w[18])),.01,36500).toFixed(8)}forgetting_curve(t,n){return+Math.pow(1+Z6*t/n,G6).toFixed(8)}}function _G(){const e=this.review_time.getTime(),t=this.current.reps,n=this.current.difficulty*this.current.stability;return`${e}_${t}_${n}`}var LM=(e=>(e.SCHEDULER="Scheduler",e.SEED="Seed",e))(LM||{});class BG{last;current;review_time;next=new Map;algorithm;initSeedStrategy;constructor(t,n,r,o={seed:_G}){this.algorithm=r,this.initSeedStrategy=o.seed.bind(this),this.last=jt.card(t),this.current=jt.card(t),this.review_time=jt.time(n),this.init()}init(){const{state:t,last_review:n}=this.current;let r=0;t!==Wt.New&&n&&(r=this.review_time.diff(n,"days")),this.current.last_review=this.review_time,this.current.elapsed_days=r,this.current.reps+=1,this.algorithm.seed=this.initSeedStrategy()}preview(){return{[Ye.Again]:this.review(Ye.Again),[Ye.Hard]:this.review(Ye.Hard),[Ye.Good]:this.review(Ye.Good),[Ye.Easy]:this.review(Ye.Easy),[Symbol.iterator]:this.previewIterator.bind(this)}}*previewIterator(){for(const t of FXe)yield this.review(t)}review(t){const{state:n}=this.last;let r;switch(n){case Wt.New:r=this.newState(t);break;case Wt.Learning:case Wt.Relearning:r=this.learningState(t);break;case Wt.Review:r=this.reviewState(t);break}if(r)return r;throw new Error("Invalid grade")}buildLog(t){const{last_review:n,due:r,elapsed_days:o}=this.last;return{rating:t,state:this.current.state,due:n||r,stability:this.current.stability,difficulty:this.current.difficulty,elapsed_days:this.current.elapsed_days,last_elapsed_days:o,scheduled_days:this.current.scheduled_days,review:this.review_time}}}class $6 extends BG{newState(t){const n=this.next.get(t);if(n)return n;const r=jt.card(this.current);switch(r.difficulty=this.algorithm.init_difficulty(t),r.stability=this.algorithm.init_stability(t),t){case Ye.Again:r.scheduled_days=0,r.due=this.review_time.scheduler(1),r.state=Wt.Learning;break;case Ye.Hard:r.scheduled_days=0,r.due=this.review_time.scheduler(5),r.state=Wt.Learning;break;case Ye.Good:r.scheduled_days=0,r.due=this.review_time.scheduler(10),r.state=Wt.Learning;break;case Ye.Easy:{const i=this.algorithm.next_interval(r.stability,this.current.elapsed_days);r.scheduled_days=i,r.due=this.review_time.scheduler(i,!0),r.state=Wt.Review;break}default:throw new Error("Invalid grade")}const o={card:r,log:this.buildLog(t)};return this.next.set(t,o),o}learningState(t){const n=this.next.get(t);if(n)return n;const{state:r,difficulty:o,stability:i}=this.last,a=jt.card(this.current),s=this.current.elapsed_days;switch(a.difficulty=this.algorithm.next_difficulty(o,t),a.stability=this.algorithm.next_short_term_stability(i,t),t){case Ye.Again:a.scheduled_days=0,a.due=this.review_time.scheduler(5,!1),a.state=r;break;case Ye.Hard:a.scheduled_days=0,a.due=this.review_time.scheduler(10),a.state=r;break;case Ye.Good:{const u=this.algorithm.next_interval(a.stability,s);a.scheduled_days=u,a.due=this.review_time.scheduler(u,!0),a.state=Wt.Review;break}case Ye.Easy:{const u=this.algorithm.next_short_term_stability(i,Ye.Good),d=this.algorithm.next_interval(u,s),h=Math.max(this.algorithm.next_interval(a.stability,s),d+1);a.scheduled_days=h,a.due=this.review_time.scheduler(h,!0),a.state=Wt.Review;break}default:throw new Error("Invalid grade")}const l={card:a,log:this.buildLog(t)};return this.next.set(t,l),l}reviewState(t){const n=this.next.get(t);if(n)return n;const r=this.current.elapsed_days,{difficulty:o,stability:i}=this.last,a=this.algorithm.forgetting_curve(r,i),s=jt.card(this.current),l=jt.card(this.current),u=jt.card(this.current),d=jt.card(this.current);this.next_ds(s,l,u,d,o,i,a),this.next_interval(s,l,u,d,r),this.next_state(s,l,u,d),s.lapses+=1;const h={card:s,log:this.buildLog(Ye.Again)},p={card:l,log:super.buildLog(Ye.Hard)},m={card:u,log:super.buildLog(Ye.Good)},b={card:d,log:super.buildLog(Ye.Easy)};return this.next.set(Ye.Again,h),this.next.set(Ye.Hard,p),this.next.set(Ye.Good,m),this.next.set(Ye.Easy,b),this.next.get(t)}next_ds(t,n,r,o,i,a,s){t.difficulty=this.algorithm.next_difficulty(i,Ye.Again);const l=a/Math.exp(this.algorithm.parameters.w[17]*this.algorithm.parameters.w[18]);t.stability=Math.min(+l.toFixed(8),this.algorithm.next_forget_stability(i,a,s)),n.difficulty=this.algorithm.next_difficulty(i,Ye.Hard),n.stability=this.algorithm.next_recall_stability(i,a,s,Ye.Hard),r.difficulty=this.algorithm.next_difficulty(i,Ye.Good),r.stability=this.algorithm.next_recall_stability(i,a,s,Ye.Good),o.difficulty=this.algorithm.next_difficulty(i,Ye.Easy),o.stability=this.algorithm.next_recall_stability(i,a,s,Ye.Easy)}next_interval(t,n,r,o,i){let a,s;a=this.algorithm.next_interval(n.stability,i),s=this.algorithm.next_interval(r.stability,i),a=Math.min(a,s),s=Math.max(s,a+1);const l=Math.max(this.algorithm.next_interval(o.stability,i),s+1);t.scheduled_days=0,t.due=this.review_time.scheduler(5),n.scheduled_days=a,n.due=this.review_time.scheduler(a,!0),r.scheduled_days=s,r.due=this.review_time.scheduler(s,!0),o.scheduled_days=l,o.due=this.review_time.scheduler(l,!0)}next_state(t,n,r,o){t.state=Wt.Relearning,n.state=Wt.Review,r.state=Wt.Review,o.state=Wt.Review}}class q6 extends BG{newState(t){const n=this.next.get(t);if(n)return n;this.current.scheduled_days=0,this.current.elapsed_days=0;const r=jt.card(this.current),o=jt.card(this.current),i=jt.card(this.current),a=jt.card(this.current);return this.init_ds(r,o,i,a),this.next_interval(r,o,i,a,0),this.next_state(r,o,i,a),this.update_next(r,o,i,a),this.next.get(t)}init_ds(t,n,r,o){t.difficulty=this.algorithm.init_difficulty(Ye.Again),t.stability=this.algorithm.init_stability(Ye.Again),n.difficulty=this.algorithm.init_difficulty(Ye.Hard),n.stability=this.algorithm.init_stability(Ye.Hard),r.difficulty=this.algorithm.init_difficulty(Ye.Good),r.stability=this.algorithm.init_stability(Ye.Good),o.difficulty=this.algorithm.init_difficulty(Ye.Easy),o.stability=this.algorithm.init_stability(Ye.Easy)}learningState(t){return this.reviewState(t)}reviewState(t){const n=this.next.get(t);if(n)return n;const r=this.current.elapsed_days,{difficulty:o,stability:i}=this.last,a=this.algorithm.forgetting_curve(r,i),s=jt.card(this.current),l=jt.card(this.current),u=jt.card(this.current),d=jt.card(this.current);return this.next_ds(s,l,u,d,o,i,a),this.next_interval(s,l,u,d,r),this.next_state(s,l,u,d),s.lapses+=1,this.update_next(s,l,u,d),this.next.get(t)}next_ds(t,n,r,o,i,a,s){t.difficulty=this.algorithm.next_difficulty(i,Ye.Again),t.stability=Math.min(a,this.algorithm.next_forget_stability(i,a,s)),n.difficulty=this.algorithm.next_difficulty(i,Ye.Hard),n.stability=this.algorithm.next_recall_stability(i,a,s,Ye.Hard),r.difficulty=this.algorithm.next_difficulty(i,Ye.Good),r.stability=this.algorithm.next_recall_stability(i,a,s,Ye.Good),o.difficulty=this.algorithm.next_difficulty(i,Ye.Easy),o.stability=this.algorithm.next_recall_stability(i,a,s,Ye.Easy)}next_interval(t,n,r,o,i){let a,s,l,u;a=this.algorithm.next_interval(t.stability,i),s=this.algorithm.next_interval(n.stability,i),l=this.algorithm.next_interval(r.stability,i),u=this.algorithm.next_interval(o.stability,i),a=Math.min(a,s),s=Math.max(s,a+1),l=Math.max(l,s+1),u=Math.max(u,l+1),t.scheduled_days=a,t.due=this.review_time.scheduler(a,!0),n.scheduled_days=s,n.due=this.review_time.scheduler(s,!0),r.scheduled_days=l,r.due=this.review_time.scheduler(l,!0),o.scheduled_days=u,o.due=this.review_time.scheduler(u,!0)}next_state(t,n,r,o){t.state=Wt.Review,n.state=Wt.Review,r.state=Wt.Review,o.state=Wt.Review}update_next(t,n,r,o){const i={card:t,log:this.buildLog(Ye.Again)},a={card:n,log:super.buildLog(Ye.Hard)},s={card:r,log:super.buildLog(Ye.Good)},l={card:o,log:super.buildLog(Ye.Easy)};this.next.set(Ye.Again,i),this.next.set(Ye.Hard,a),this.next.set(Ye.Good,s),this.next.set(Ye.Easy,l)}}class VXe{fsrs;constructor(t){this.fsrs=t}replay(t,n,r){return this.fsrs.next(t,n,r)}handleManualRating(t,n,r,o,i,a,s){if(typeof n>"u")throw new Error("reschedule: state is required for manual rating");let l,u;if(n===Wt.New)l={rating:Ye.Manual,state:n,due:s??r,stability:t.stability,difficulty:t.difficulty,elapsed_days:o,last_elapsed_days:t.elapsed_days,scheduled_days:t.scheduled_days,review:r},u=oS(r),u.last_review=r;else{if(typeof s>"u")throw new Error("reschedule: due is required for manual rating");const d=s.diff(r,"days");l={rating:Ye.Manual,state:t.state,due:t.last_review||t.due,stability:t.stability,difficulty:t.difficulty,elapsed_days:o,last_elapsed_days:t.elapsed_days,scheduled_days:t.scheduled_days,review:r},u={...t,state:n,due:s,last_review:r,stability:i||t.stability,difficulty:a||t.difficulty,elapsed_days:o,scheduled_days:d,reps:t.reps+1}}return{card:u,log:l}}reschedule(t,n){const r=[];let o=oS(t.due);for(const i of n){let a;if(i.review=jt.time(i.review),i.rating===Ye.Manual){let s=0;o.state!==Wt.New&&o.last_review&&(s=i.review.diff(o.last_review,"days")),a=this.handleManualRating(o,i.state,i.review,s,i.stability,i.difficulty,i.due?jt.time(i.due):void 0)}else a=this.replay(o,i.review,i.rating);r.push(a),o=a.card}return r}calculateManualRecord(t,n,r,o){if(!r)return null;const{card:i,log:a}=r,s=jt.card(t);return s.due.getTime()===i.due.getTime()?null:(s.scheduled_days=i.due.diff(s.due,"days"),this.handleManualRating(s,i.state,jt.time(n),a.elapsed_days,o?i.stability:void 0,o?i.difficulty:void 0,i.due))}}class WXe extends zXe{strategyHandler=new Map;Scheduler;constructor(t){super(t);const{enable_short_term:n}=this.parameters;this.Scheduler=n?$6:q6}params_handler_proxy(){const t=this;return{set:function(n,r,o){return r==="request_retention"&&Number.isFinite(o)?t.intervalModifier=t.calculate_interval_modifier(Number(o)):r==="enable_short_term"&&(t.Scheduler=o===!0?$6:q6),Reflect.set(n,r,o),!0}}}useStrategy(t,n){return this.strategyHandler.set(t,n),this}clearStrategy(t){return t?this.strategyHandler.delete(t):this.strategyHandler.clear(),this}getScheduler(t,n){const r=this.strategyHandler.get(LM.SEED),o=this.strategyHandler.get(LM.SCHEDULER)||this.Scheduler,i=r||_G;return new o(t,n,this,{seed:i})}repeat(t,n,r){const o=this.getScheduler(t,n).preview();return r&&typeof r=="function"?r(o):o}next(t,n,r,o){const i=this.getScheduler(t,n),a=jt.rating(r);if(a===Ye.Manual)throw new Error("Cannot review a manual rating");const s=i.review(a);return o&&typeof o=="function"?o(s):s}get_retrievability(t,n,r=!0){const o=jt.card(t);n=n?jt.time(n):new Date;const i=o.state!==Wt.New?Math.max(n.diff(o.last_review,"days"),0):0,a=o.state!==Wt.New?this.forgetting_curve(i,+o.stability.toFixed(8)):0;return r?`${(a*100).toFixed(2)}%`:a}rollback(t,n,r){const o=jt.card(t),i=jt.review_log(n);if(i.rating===Ye.Manual)throw new Error("Cannot rollback a manual rating");let a,s,l;switch(i.state){case Wt.New:a=i.due,s=void 0,l=0;break;case Wt.Learning:case Wt.Relearning:case Wt.Review:a=i.review,s=i.due,l=o.lapses-(i.rating===Ye.Again&&i.state===Wt.Review?1:0);break}const u={...o,due:a,stability:i.stability,difficulty:i.difficulty,elapsed_days:i.last_elapsed_days,scheduled_days:i.scheduled_days,reps:Math.max(0,o.reps-1),lapses:Math.max(0,l),state:i.state,last_review:s};return r&&typeof r=="function"?r(u):u}forget(t,n,r=!1,o){const i=jt.card(t);n=jt.time(n);const a=i.state===Wt.New?0:n.diff(i.last_review,"days"),s={rating:Ye.Manual,state:i.state,due:i.due,stability:i.stability,difficulty:i.difficulty,elapsed_days:0,last_elapsed_days:i.elapsed_days,scheduled_days:a,review:n},l={card:{...i,due:n,stability:0,difficulty:0,elapsed_days:0,scheduled_days:0,reps:r?0:i.reps,lapses:r?0:i.lapses,state:Wt.New,last_review:i.last_review},log:s};return o&&typeof o=="function"?o(l):l}reschedule(t,n=[],r={}){const{recordLogHandler:o,reviewsOrderBy:i,skipManual:a=!0,now:s=new Date,update_memory_state:l=!1}=r;i&&typeof i=="function"&&n.sort(i),a&&(n=n.filter(b=>b.rating!==Ye.Manual));const u=new VXe(this),d=u.reschedule(r.first_card||oS(),n),h=d.length,p=jt.card(t),m=u.calculateManualRecord(p,s,h?d[h-1]:void 0,l);return o&&typeof o=="function"?{collections:d.map(o),reschedule_item:m?o(m):null}:{collections:d,reschedule_item:m}}}const GXe=new WXe(jM({maximum_interval:36500,request_retention:.9,enable_fuzz:!0,enable_short_term:!0,w:[.40255,1.18385,3.173,15.69105,7.1949,.5345,1.4604,.0046,1.54575,.1192,1.01925,1.9395,.11,.29605,2.2698,.2315,2.9898,.51655,.6621]})),ZXe=()=>({totalReviews:0,hardCount:0,goodCount:0,easyCount:0,againCount:0,lastReviewDate:Date.now(),reviewHistory:[]}),YG=e=>({...oS(),memoId:e}),$Xe=e=>GXe.repeat(e,new Date),qXe=(e,t)=>{const n=$Xe(e);let r;switch(t){case Ye.Again:r=n[Ye.Again].card;break;case Ye.Hard:r=n[Ye.Hard].card;break;case Ye.Good:r=n[Ye.Good].card;break;case Ye.Easy:r=n[Ye.Easy].card;break;default:throw new Error("Invalid rating")}return{...r,memoId:e.memoId}},Sr=TS("memos-review-db","review-store"),KXe=async()=>{await al("historical_stats",Sr)||await hl("historical_stats",{totalReviews:0,againCount:0,hardCount:0,goodCount:0,easyCount:0,reviewHistory:[]},Sr)},RM=async()=>await al("historical_stats",Sr)||{totalReviews:0,againCount:0,hardCount:0,goodCount:0,easyCount:0,reviewHistory:[]},XXe=async e=>{const t=await RM();switch(t.totalReviews++,e){case Ye.Again:t.againCount++;break;case Ye.Hard:t.hardCount++;break;case Ye.Good:t.goodCount++;break;case Ye.Easy:t.easyCount++;break}t.reviewHistory.push({date:Date.now(),rating:e}),await hl("historical_stats",t,Sr)},JXe=async()=>{try{await hl("test-key","test-value",Sr),await al("test-key",Sr),await EH("test-key",Sr),await KXe();const e=new Date().toISOString().split("T")[0],t=await al("dailyLimit",Sr);if(!t||t.date!==e){const r=(await CH(Sr)).filter(a=>a.startsWith("review_")),i=(await Promise.all(r.map(async a=>{const s=await al(a,Sr);if(!s)return!1;const l=Date.now();return s.card?.due&&s.card.due.getTime()<=l}))).filter(Boolean).length;await hl("dailyLimit",{date:e,reviewed:0,totalCards:i},Sr)}return!0}catch(e){return console.error("Error initializing database:",e),!1}};let _k=!1;const QT=async()=>(_k||(_k=await JXe()),_k),FM=async()=>{if(!await QT())return{date:new Date().toISOString().split("T")[0],reviewed:0,totalCards:0};try{const e=new Date().toISOString().split("T")[0],t=await al("dailyLimit",Sr),r=(await CH(Sr)).filter(i=>i.startsWith("review_")),o=new Set(r).size;if(!t||t.date!==e){const i={date:e,reviewed:0,totalCards:o};return await hl("dailyLimit",i,Sr),i}if(t.totalCards!==o){const i={...t,totalCards:o};return await hl("dailyLimit",i,Sr),i}return t}catch(e){return console.error("Error getting daily limit:",e),{date:new Date().toISOString().split("T")[0],reviewed:0,totalCards:0}}},QXe=async()=>{if(await QT())try{const e=await FM();e.reviewed+=1,await hl("dailyLimit",e,Sr)}catch(e){console.error("Error updating daily limit:",e)}},UG=async e=>{if(await QT())try{const t=`review_${e}`,n=await al(t,Sr);if(n&&"sm2Data"in n&&!n.card){const r={memoId:e,card:YG(e),stats:{totalReviews:n.stats.totalReviews,hardCount:n.stats.hardCount||0,goodCount:n.stats.goodCount||0,easyCount:n.stats.easyCount||0,againCount:0,lastReviewDate:n.stats.lastReviewDate,reviewHistory:n.stats.reviewHistory.map(o=>({date:o.date,rating:zG(o.quality)}))},sm2Data:n.sm2Data};return await TN(e,r),r}return n}catch(t){console.error("Error getting review data:",t);return}},TN=async(e,t)=>{if(await QT())try{const n=`review_${e}`;await hl(n,t,Sr)}catch(n){console.error("Error setting review data:",n)}},eJe=async e=>{const t={memoId:e,card:YG(e),stats:ZXe()};return await TN(e,t),t},zG=e=>{switch(e){case 1:return Ye.Again;case 2:return Ye.Hard;case 3:case 4:return Ye.Good;case 5:return Ye.Easy;default:return Ye.Good}},tJe=async(e,t)=>{try{let n=await UG(e);n||(n=await eJe(e));const r=zG(t),o=qXe(n.card,r),i={...n.stats,totalReviews:n.stats.totalReviews+1,lastReviewDate:Date.now(),reviewHistory:[...n.stats.reviewHistory,{date:Date.now(),rating:r}]};switch(r){case Ye.Again:i.againCount++;break;case Ye.Hard:i.hardCount++;break;case Ye.Good:i.goodCount++;break;case Ye.Easy:i.easyCount++;break}const a={...n,card:o,stats:i};return await TN(e,a),await QXe(),await XXe(r),a}catch(n){throw console.error("Error updating review:",n),n}},nJe=()=>{const{dailyNotesState:{app:e,plugin:t},memoState:{memos:n},globalState:{isMobileView:r}}=D.useContext(ct),o=Dc(),[i,a]=D.useState(0),[s,l]=D.useState([]),[u,d]=D.useState(!1),[h,p]=D.useState(!1),[m,b]=D.useState({total:0,reviewed:0,remaining:0,againCount:0,hardCount:0,goodCount:0,easyCount:0,dailyLimit:100,dailyReviewed:0}),[v]=D.useState(new Map),[y,S]=D.useState({totalReviews:0,againCount:0,hardCount:0,goodCount:0,easyCount:0,reviewHistory:[]});D.useEffect(()=>{(async()=>{try{const I=await FM();if(I.totalCards>=100){l([]),b(K=>({...K,dailyReviewed:I.reviewed,remaining:0,total:I.totalCards})),d(!1),o.setFinish();return}const O=n.filter(K=>K.rowStatus!=="ARCHIVED"&&!(K.deletedAt!==""&&K.deletedAt)),R=[];let L=0,B=0,_=0,H=0;const U=Date.now();v.clear();for(const K of O)try{const z=await UG(K.id);z&&v.set(K.id,z),(!z||z.card?.due&&z.card.due.getTime()<=U||z.sm2Data?.dueDate&&z.sm2Data.dueDate<=U)&&(R.push(K),z?.stats&&(L+=z.stats.againCount||0,B+=z.stats.hardCount||0,_+=z.stats.goodCount||0,H+=z.stats.easyCount||0))}catch(z){console.error("Error fetching review data for memo:",K.id,z);continue}R.sort((K,z)=>{const ne=v.get(K.id),J=v.get(z.id),ee=ne?.card?.due?.getTime()||ne?.sm2Data?.dueDate||0,Z=J?.card?.due?.getTime()||J?.sm2Data?.dueDate||0;return ee-Z});const G=Math.min(R.length,100-I.reviewed);l(R.slice(0,G)),b({total:I.totalCards,reviewed:0,remaining:G,againCount:L,hardCount:B,goodCount:_,easyCount:H,dailyLimit:100,dailyReviewed:I.reviewed})}catch(I){console.error("Error in fetchReviewableMemos:",I)}finally{o.setFinish()}})()},[n]),D.useEffect(()=>{t.addCommand({id:"clear-review-data",name:E("Clear all review data"),callback:async()=>{try{const M=TS("memos-review-db","review-store");await _ne(M),b({total:0,reviewed:0,remaining:0,againCount:0,hardCount:0,goodCount:0,easyCount:0,dailyLimit:100,dailyReviewed:0}),l([]),d(!1),a(0),v.clear()}catch(M){console.error("Error clearing review data:",M)}}})},[]),D.useEffect(()=>{(async()=>{const I=await RM();S(I)})()},[]),D.useCallback(()=>{Ze.setShowSiderbarInMobileView(!0)},[]);const x=async M=>{const I=s[i];if(!I)return;const O=await tJe(I.id,M),R=await FM(),L=await RM();S(L);const B=s.filter((_,H)=>H!==i);if(M===1||M===2){const _=B.findIndex(H=>(v.get(H.id)?.card.due.getTime()||0)>O.card.due.getTime());_===-1?B.push(I):B.splice(_,0,I)}l(B),b(_=>({..._,reviewed:_.reviewed+1,remaining:B.length,dailyReviewed:_.dailyReviewed+1,total:R.totalCards,...M===1?{againCount:_.againCount+1}:M===2?{hardCount:_.hardCount+1}:M===3||M===4?{goodCount:_.goodCount+1}:{easyCount:_.easyCount+1}})),B.length>0?i>=B.length&&a(0):d(!1)},C=()=>{s.length>0&&(d(!0),a(0))},k=s[i];return w.jsxs("div",{className:"daily-review-wrapper",children:[w.jsx(Yh,{showSidebar:r,rightContent:w.jsx("div",{className:"header-right-section",children:w.jsx("button",{className:"show-stats-btn",onClick:()=>p(!h),children:E(h?"Hide stats":"Show stats")})})}),h&&w.jsxs("div",{className:"review-stats-banner",children:[w.jsxs("div",{className:"stats-wrapper",children:[w.jsxs("div",{className:"stats-item",children:[w.jsxs("span",{className:"label",children:[E("Daily Progress"),":"]}),w.jsx("span",{className:"value",children:m.dailyReviewed})]}),w.jsxs("div",{className:"stats-item",children:[w.jsxs("span",{className:"label",children:[E("Today Remaining"),":"]}),w.jsx("span",{className:"value",children:m.remaining})]}),w.jsxs("div",{className:"stats-item",children:[w.jsxs("span",{className:"label",children:[E("Today Total"),":"]}),w.jsx("span",{className:"value",children:m.total})]})]}),w.jsx("div",{className:"stats-breakdown-wrapper",children:w.jsx("div",{className:"stats-breakdown",children:w.jsxs("div",{className:"historical-stats",children:[w.jsx("h4",{children:E("Historical Statistics")}),w.jsxs("span",{className:"total",children:[E("Total Reviews"),": ",y.totalReviews]}),w.jsxs("span",{className:"again",children:[E("Again"),": ",y.againCount]}),w.jsxs("span",{className:"hard",children:[E("Hard"),": ",y.hardCount]}),w.jsxs("span",{className:"good",children:[E("Good"),": ",y.goodCount]}),w.jsxs("span",{className:"easy",children:[E("Easy"),": ",y.easyCount]})]})})})]}),w.jsx("div",{className:"review-container",children:o.isLoading?w.jsx("div",{className:"tip-text-container",children:w.jsx("span",{className:"tip-text",children:E("Fetching data...")})}):s.length===0?w.jsx("div",{className:"tip-text-container",children:w.jsx("span",{className:"tip-text",children:E("Today, you have reviewed all your thinos!")})}):u?w.jsxs(w.Fragment,{children:[w.jsxs("div",{className:"review-card",children:[w.jsx(vo,{memo:k}),w.jsxs("div",{className:"review-buttons",children:[w.jsx("button",{className:"again",onClick:()=>x(1),children:E("Again")}),w.jsx("button",{className:"hard",onClick:()=>x(2),children:E("Hard")}),w.jsx("button",{className:"good",onClick:()=>x(3),children:E("Good")}),w.jsx("button",{className:"easy",onClick:()=>x(5),children:E("Easy")})]})]}),s.length>3?w.jsxs(w.Fragment,{children:[w.jsx("div",{className:"review-card stacked-card left-stacked"}),w.jsx("div",{className:"review-card stacked-card right-stacked"})]}):s.length===2?w.jsx("div",{className:"review-card stacked-card left-stacked"}):null]}):w.jsx("div",{className:"review-stats",children:w.jsxs("div",{className:"stats-content",children:[w.jsxs("span",{children:[E("Thinos to review"),": ",m.remaining]}),w.jsx("button",{className:"start-review-btn",onClick:C,children:E("Start Review")})]})})})]})},rJe=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),VG=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();var oJe={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const iJe=D.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:i,iconNode:a,...s},l)=>D.createElement("svg",{ref:l,...oJe,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:VG("lucide",o),...s},[...a.map(([u,d])=>D.createElement(u,d)),...Array.isArray(i)?i:[i]])),aJe=(e,t)=>{const n=D.forwardRef(({className:r,...o},i)=>D.createElement(iJe,{ref:i,iconNode:t,className:VG(`lucide-${rJe(e)}`,r),...o}));return n.displayName=`${e}`,n},sJe=aJe("TrendingUp",[["polyline",{points:"22 7 13.5 15.5 8.5 10.5 2 17",key:"126l90"}],["polyline",{points:"16 7 22 7 22 13",key:"kwv8wd"}]]),Rb={daily:{label:"Daily",color:"var(--chart-1)"},time:{label:"Time",color:"var(--chart-2)"},length:{label:"Length",color:"var(--chart-3)"},journal:{label:"Journal",color:"var(--chart-4)"}},lJe=()=>{const{memoState:{tags:e,tagsNum:t,memos:n},globalState:{isMobileView:r},dailyNotesState:{plugin:o}}=D.useContext(ct),i=Dc(),[a,s]=D.useState([]),[l,u]=D.useState([]),[d,h]=D.useState([]),[p,m]=D.useState([]),[b,v]=D.useState([]),[y,S]=D.useState([]),[x,C]=D.useState("30days"),[k,M]=D.useState([]);D.useEffect(()=>{if(!n||n.length===0)return;(async()=>{i.setLoading();try{const L=await o.thinoWorkerManager.calculateStats(n);s(L.dailyData),u(L.monthlyData),h(L.yearlyData),m(L.hourlyData),v(L.timeDistData),S(L.lengthData),M(Object.entries(t).map(([B,_])=>({tag:B,count:_})).sort((B,_)=>_.count-B.count).slice(0,10))}catch(L){console.error("Error loading stats:",L)}finally{i.setFinish()}})()},[n]);const I=D.useMemo(()=>{switch(x){case"day":return p;case"month":return l;case"year":return d;default:return a}},[x,p,l,d,a]);D.useCallback(()=>{Ze.setShowSiderbarInMobileView(!0)},[]);const O=D.useCallback(R=>{const L=new N.Menu;L.addItem(B=>{B.setTitle(E("Hourly distribution")).setChecked(x==="day").onClick(()=>C("day"))}),L.addItem(B=>{B.setTitle(E("Month")).setChecked(x==="month").onClick(()=>C("month"))}),L.addItem(B=>{B.setTitle(E("30 Days")).setChecked(x==="30days").onClick(()=>C("30days"))}),L.addItem(B=>{B.setTitle(E("Year")).setChecked(x==="year").onClick(()=>C("year"))}),L.showAtMouseEvent(R.nativeEvent)},[E,x]);return w.jsxs("div",{className:"thino-stat",children:[w.jsx(Yh,{showSidebar:r,title:E("Statistics")}),i.isLoading?w.jsx("div",{className:"tip-text-container",children:w.jsx("span",{className:"tip-text",children:E("Fetching data...")})}):w.jsxs("div",{className:"twp stats-container th:grid th:grid-cols-1 th:md:grid-cols-2 th:gap-4 th:overflow-y-auto th:max-h-[calc(100vh-240px)]",children:[w.jsxs(am,{className:"stat-card th:w-full th:h-fit th:bg-background th:border th:border-border/50 th:rounded-lg th:shadow-sm",children:[w.jsx(sm,{children:w.jsxs("div",{className:"th:flex th:justify-between th:items-center",children:[w.jsxs("div",{children:[w.jsx(lm,{children:E("Thino Count")}),w.jsxs(cm,{children:[x==="day"&&E("Hourly distribution"),x==="month"&&E("Current month"),x==="30days"&&E("Last 30 days"),x==="year"&&E("Monthly distribution")]})]}),w.jsx("div",{className:"th:flex th:gap-2",children:w.jsx("button",{className:`th:px-2 th:py-1 th:text-sm th:rounded ${x==="day"?"!th:bg-secondary th:text-secondary-foreground":"th:bg-muted"}`,onClick:R=>O(R),children:"Switch view"})})]})}),w.jsx(um,{children:w.jsx(dm,{config:Rb,children:w.jsxs(_Ke,{data:I,children:[w.jsx(ff,{strokeDasharray:"3 3"}),w.jsx(rl,{dataKey:x==="day"?"hour":"date",tickLine:!1,tickMargin:10,axisLine:!1}),w.jsx(ol,{}),w.jsx(fm,{content:w.jsx(Lb,{})}),w.jsx(Gv,{type:"monotone",dataKey:"count",stroke:"var(--color-daily)",strokeWidth:2,dot:!1})]})})}),w.jsx(yXe,{children:w.jsxs("div",{className:"total-count th:flex th:items-center th:justify-center th:text-sm th:text-muted-foreground",children:[E("Total"),": ",n.length," ",E("thinos"),w.jsx(sJe,{className:"trend-icon th:h-4 th:w-4"})]})})]}),w.jsxs(am,{className:"stat-card th:w-full th:h-fit th:bg-background th:border th:border-border/50 th:rounded-lg th:shadow-sm",children:[w.jsxs(sm,{children:[w.jsx(lm,{children:E("Time Distribution")}),w.jsx(cm,{children:E("When do you write thinos")})]}),w.jsx(um,{children:w.jsx(dm,{config:Rb,children:w.jsxs(u0,{data:b,children:[w.jsx(ff,{strokeDasharray:"3 3"}),w.jsx(rl,{dataKey:"period",tickLine:!1,tickMargin:10,axisLine:!1}),w.jsx(ol,{}),w.jsx(fm,{content:w.jsx(Lb,{})}),w.jsx(ys,{dataKey:"count",fill:"var(--color-time)",radius:[4,4,0,0]})]})})})]}),w.jsxs(am,{className:"stat-card th:w-full th:h-fit th:bg-background th:border th:border-border/50 th:rounded-lg th:shadow-sm",children:[w.jsxs(sm,{children:[w.jsx(lm,{children:E("Content Length")}),w.jsx(cm,{children:E("Distribution of thino lengths")})]}),w.jsx(um,{children:w.jsx(dm,{config:Rb,children:w.jsxs(u0,{data:y,children:[w.jsx(ff,{strokeDasharray:"3 3"}),w.jsx(rl,{dataKey:"range",tickLine:!1,tickMargin:10,axisLine:!1}),w.jsx(ol,{}),w.jsx(fm,{content:w.jsx(Lb,{})}),w.jsx(ys,{dataKey:"count",fill:"var(--color-length)",radius:[4,4,0,0]})]})})})]}),w.jsxs(am,{className:"stat-card th:w-full th:h-fit th:bg-background th:border th:border-border/50 th:rounded-lg th:shadow-sm",children:[w.jsxs(sm,{children:[w.jsx(lm,{children:E("Popular Tags")}),w.jsx(cm,{children:E("Top 10 most used tags")})]}),w.jsx(um,{children:w.jsx(dm,{config:Rb,children:w.jsxs(u0,{data:k,children:[w.jsx(ff,{strokeDasharray:"3 3"}),w.jsx(rl,{dataKey:"tag",tickLine:!1,tickMargin:10,axisLine:!1}),w.jsx(ol,{}),w.jsx(fm,{content:w.jsx(Lb,{})}),w.jsx(ys,{dataKey:"count",fill:"var(--color-journal)",radius:[4,4,0,0]})]})})})]})]})]})},cJe={"/recycle":w.jsx(bFe,{}),"/setting":w.jsx(SFe,{}),"/archive":w.jsx(L9e,{}),"/review":w.jsx(TFe,{}),"/stat":w.jsx(lJe,{}),"/daily-review":w.jsx(nJe,{}),"/daily":w.jsx(CXe,{}),"*":w.jsx(H9e,{})},WG=e=>t=>{for(const n of Object.keys(e))if(n===t)return e[n];return e["*"]},uJe=WG(vFe),dJe=WG(cJe);function fJe({app:e}){const{locationState:{pathname:t},dailyNotesState:{settings:n}}=D.useContext(ct);return D.useEffect(()=>{de.fetchAllMemos()},[]),!Om()&&!e.plugins.getPlugin("periodic-notes")&&n?.EnabledLocationList.find(r=>r.value==="DAILY")&&new N.Notice(E("Check if you opened Daily Notes Plugin Or Periodic Notes Plugin")),!Om()&&n?.EnabledLocationList.find(r=>r.value==="DAILY")&&!Oq()&&new N.Notice(E("Your daily note folder is not set correctly, please check your settings")),w.jsx(zi,{store:ke,context:ct,children:uJe(t)})}function hJe(e){const t=e.view.canvas,n=$e.getState().settings.EnabledLocationList.find(a=>a.value==="CANVAS");if(!t||!e.view.file.path.endsWith(".thino.canvas")||t.thinoBtn||!n)return;const r=t.wrapperEl.createDiv({cls:"thino-canvas-menu-btn"}),o=tv(r);o.render(w.jsx(Y.StrictMode,{children:w.jsx(zi,{store:ke,context:ct,children:w.jsx(pJe,{leaf:e})})})),t.thinoBtn=o,$e.getState().view.appendRoot({root:o,canvas:t})}function pJe({leaf:e}){const{memoState:{memos:t},locationState:{query:n},dailyNotesState:{plugin:r}}=D.useContext(ct),o=Y.useRef(null),i=Y.useRef(null),[a,s]=Y.useState(!1),[l,u]=Y.useState([]),[d,h]=Y.useState([]),{tag:p,duration:m,type:b,text:v,filter:y}=n,S=Ct.getQueryById(y),x=!!(p||m&&m.from<m.to||b||v||S);return D.useEffect(()=>{i.current&&N.setIcon(i.current,"eraser")},[i.current]),D.useEffect(()=>{o.current&&N.setIcon(o.current,"Memos")},[o.current]),D.useEffect(()=>{const C=e.view.file.path,k=t.filter(M=>M.sourceType==="CANVAS"&&M.path===C);u(k)},[t,a]),D.useEffect(()=>{if(l.length!==0){if(!n||!x){h(l);return}hc({memos:l,query:n,filterOptions:{filterDoneTasks:!1},plugin:r}).then(C=>{h(C)})}},[n,l]),D.useEffect(()=>{if(!n||!x&&d.length===0)return;const C=new Set(d.map(M=>M.id)),k=Array.from(e.view.canvas.nodes.values());k.forEach(M=>{M.nodeEl.toggleVisibility(!0),e.view.canvas.getEdgesForNode(M).forEach(I=>{I.lineGroupEl?.toggleClass("thino-hidden",!1),I.lineStartGroupEl?.toggleClass("thino-hidden",!1),I.lineEndGroupEl?.toggleClass("thino-hidden",!1)})}),k.filter(M=>!C.has(M.id)).forEach(M=>{M.nodeEl.toggleVisibility(!1),e.view.canvas.getEdgesForNode(M).forEach(I=>{I.lineGroupEl?.toggleClass("thino-hidden",!0),I.lineStartGroupEl?.toggleClass("thino-hidden",!0),I.lineEndGroupEl?.toggleClass("thino-hidden",!0)})})},[d]),w.jsxs(w.Fragment,{children:[w.jsx("div",{ref:o,className:"btn-container",onClick:()=>s(!a)}),a&&w.jsxs("div",{className:"thino-canvas-menu",children:[w.jsxs("div",{className:"thino-canvas-filter-group",children:[w.jsx(IA,{}),w.jsx(nv,{}),x&&w.jsx("div",{ref:i,className:"clear-query",onClick:()=>{Ue.clearQuery()}})]}),w.jsx(_m,{initThinos:d})]})]})}function hm(e,t){const n=Object.keys(t).map(r=>mJe(e,r,t[r]));return n.length===1?n[0]:function(){n.forEach(r=>r())}}function mJe(e,t,n){const r=e[t],o=e.hasOwnProperty(t);let i=n(r);return r&&Object.setPrototypeOf(i,r),Object.setPrototypeOf(a,i),e[t]=a,s;function a(...l){return i===r&&e[t]===a&&s(),i.apply(this,l)}function s(){e[t]===a&&(o?e[t]=r:delete e[t]),i!==r&&(i=r,Object.setPrototypeOf(a,r||Function))}}const Qr="thino_view";class gJe{static[Symbol.hasInstance](t){return t instanceof N.TFile}path="/fake-file-that-generated-for-thino.png";basename="fake-file-that-generated-for-thino";extension="png";deleted=!1;name="fake-file-that-generated-for-thino.png";parent=null;stat;vault=null;constructor(){}setPath(t){}getNewPathAfterRename(t){}getShortName(){}cache(t){}updateCacheLimit(){}}class Tf extends N.ItemView{scope=new N.Scope(this.app.scope);root;mobileHeaderRoot;plugin;memosComponent;rootList=[];editor=null;navigation=!1;file=this.app.vault.getMarkdownFiles()[0]||new gJe;constructor(t,n){super(t),this.plugin=n,this.registerScope()}getDisplayText(){return"Thino"}getIcon(){return"Memos"}getViewType(){return Qr}getMode(){return"source"}canToggleBacklinks(){return!1}registerScope(){const{scope:t}=this;t.register(["Mod"],"Enter",()=>{}),t.register([],"i",n=>{const r=n.target;r.tagName==="INPUT"||r.tagName==="TEXTAREA"||r.hasClass("cm-line")||r.hasClass("cm-content")||(n.preventDefault(),this.plugin.app.workspace.trigger("focus-on-textarea"))}),t.register(["Mod"],"f",n=>{const r=n.target;r.tagName==="INPUT"||r.tagName==="TEXTAREA"||r.hasClass("cm-line")||r.hasClass("cm-content")||(n.preventDefault(),this.plugin.app.workspace.trigger("focus-on-searchBar"))}),t.register([],"o",n=>{const r=n.target;r.tagName==="INPUT"||r.tagName==="TEXTAREA"||r.hasClass("cm-line")||r.hasClass("cm-content")||(n.preventDefault(),this.plugin.app.workspace.trigger("focus-on-searchBar"))}),t.register([],"Escape",()=>{this.plugin.app.vault.config?.vimMode===!0||setTimeout(()=>{this.plugin.app.workspace.trigger("blur-on-memos")},20)})}handleUpdateInstance=t=>{this.editor=t.editor};async onFileDeleted(t){const n=nf(t,"day"),r=t.path.contains(".thino")&&t.path.contains(".canvas"),o=t.path.contains(".thino")&&t.path.contains(".md"),i=this.plugin.settings?.MemoOtherSaveLocation.MemoDefaultMultiFilePath||"Thino",a=(t.parent?.path||t.path)?.contains(i?.trim());(n||r&&this.plugin.settings.EnabledLocationList.find(u=>u.value==="CANVAS"))&&(await de.removeMemosInFile(t),de.updateTagsState()),a&&this.plugin.settings.EnabledLocationList.find(u=>u.value==="MULTI")&&(await de.removeMemosInFile(t,i),de.updateTagsState()),o&&this.plugin.settings.EnabledLocationList.find(u=>u.value==="FILE")&&(await de.removeMemosInFile(t),de.updateTagsState());const s=N.getAllTags(this.app.metadataCache.getFileCache(t))?.contains(this.plugin.settings.TagForMultiTypeFiles),l=N.getAllTags(this.app.metadataCache.getFileCache(t))?.contains(this.plugin.settings.TagForFileTypeFiles);!a&&s&&(await de.updateMemosInFile(t,i),de.updateTagsState()),!o&&l&&(await de.updateMemosInFile(t),de.updateTagsState())}async onFileModified(t){if(Ze.getState().changedByMemos){Ze.setChangedByMemos(!1);return}const n=nf(t,"day"),r=t.path.contains(".thino")&&t.path.contains(".canvas"),o=t.path.contains(".thino")&&t.path.contains(".md"),i=this.plugin.settings?.MemoOtherSaveLocation.MemoDefaultMultiFilePath||"Thino",a=t.parent.path.contains(i?.trim()),s=de.getState().preparingUpdateMemo&&de.getState().preparingUpdateMemo.length>0;if((n||r&&this.plugin.settings.EnabledLocationList.find(d=>d.value==="CANVAS"))&&!s){await de.updateMemosInFile(t),de.updateTagsState();return}a&&this.plugin.settings.EnabledLocationList.find(d=>d.value==="MULTI")&&(await de.updateMemosInFile(t,i),de.updateTagsState()),o&&this.plugin.settings.EnabledLocationList.find(d=>d.value==="FILE")&&(await de.updateMemosInFile(t),de.updateTagsState());const l=N.getAllTags(this.app.metadataCache.getFileCache(t))?.contains(this.plugin.settings.TagForMultiTypeFiles),u=N.getAllTags(this.app.metadataCache.getFileCache(t))?.contains(this.plugin.settings.TagForFileTypeFiles);!a&&l&&(await de.updateMemosInFile(t,i),de.updateTagsState()),!o&&u&&(await de.updateMemosInFile(t),de.updateTagsState())}async onFileCreated(t){if(this.app.workspace.layoutReady&&this.root){const n=nf(t,"day"),r=t.path.contains(".thino")&&t.path.contains(".canvas"),o=t.path.contains(".thino")&&t.path.contains(".md"),i=this.plugin.settings?.MemoOtherSaveLocation.MemoDefaultMultiFilePath||"Thino",a=t.parent.path.contains(i?.trim()),s=de.getState().preparingUpdateMemo&&de.getState().preparingUpdateMemo.length>0;if(n&&!s){await $e.updateDailyNotes(t,!1),await de.updateMemosInFile(t),de.updateTagsState();return}if(r&&this.plugin.settings.EnabledLocationList.find(d=>d.value==="CANVAS")){await de.updateMemosInFile(t),de.updateTagsState();return}a&&this.plugin.settings.EnabledLocationList.find(d=>d.value==="MULTI")&&(await de.updateMemosInFile(t,i),de.updateTagsState()),o&&this.plugin.settings.EnabledLocationList.find(d=>d.value==="FILE")&&(await de.updateMemosInFile(t),de.updateTagsState());const l=N.getAllTags(this.app.metadataCache.getFileCache(t))?.contains(this.plugin.settings.TagForMultiTypeFiles),u=N.getAllTags(this.app.metadataCache.getFileCache(t))?.contains(this.plugin.settings.TagForFileTypeFiles);!a&&l&&(await de.updateMemosInFile(t,i),de.updateTagsState()),!o&&u&&(await de.updateMemosInFile(t),de.updateTagsState())}}async onFileRenamed(t,n){t instanceof N.TFile&&(await de.removeThinosByPath(n),await this.onFileCreated(t))}async onResize(){super.onResize();const t=this.leaf;if(t&&t.height!==0){if(t.view.containerEl.toggleClass("tiny-view",t.width<600),t.view.containerEl.toggleClass("waterfall-small-group",t.width<1300),t.width>1100){t.view.containerEl.classList.toggle("mobile-view",!1),Ze.setIsMobileView(t.width<=1100);return}if(this.plugin.settings?.ShowLeftSideBar&&!N.Platform.isMobile)return;t.view.containerEl.classList.toggle("mobile-view",!0),Ze.setIsMobileView(t.width<=1100)}}appendToHeader(){if(this.plugin.settings.useMobileViewDefaultHeader){this.containerEl.toggleClass("using-default-header",!0);return}const t=this.leaf.view.titleContainerEl;t&&(this.mobileHeaderRoot=Fi.createRoot(t),this.mobileHeaderRoot.render(w.jsx(Y.StrictMode,{children:w.jsx(zi,{store:ke,context:ct,children:w.jsx(c0,{})})})))}appendRoot({root:t,canvas:n}){this.rootList.push({root:t,canvas:n})}updateCacheDebounced=N.debounce(async t=>{this.app.vault.getFileByPath(t.path)&&await de.updateMemosInFile(t)},1e3);registerPatchWorkspaceLeaf(){const t=this;this.register(hm(N.Workspace.prototype,{getActiveViewOfType:n=>function(r){const o=n.call(this,r);if(!o&&r?.VIEW_TYPE==="markdown"){const i=this.activeLeaf;if(i?.view instanceof Tf)return i.view}return o},setActiveLeaf:n=>function(r,o){if(Wne(r)&&(n.call(this,r,o),r.activeTime=17e11),n.call(this,r,o),r.view instanceof Tf){const i=Ze.getState().instanceList.get(r.id);if(!i)return;t.app.workspace.activeEditor=i.owner,r.view.editor=i.editor}},getActiveFile:n=>function(){const r=n.call(this);return this.activeLeaf?.view instanceof Tf&&t.file||r}}))}debounceTemplateExecution=N.debounce(async()=>{this.app.workspace.trigger("templater:all-templates-executed")},1e3);async registerEventList(){await this.onResize(),this.onFileCreated=this.onFileCreated.bind(this),this.onFileDeleted=this.onFileDeleted.bind(this),this.onFileModified=this.onFileModified.bind(this),this.registerEvent(this.app.vault.on("create",this.onFileCreated)),this.registerEvent(this.app.vault.on("delete",this.onFileDeleted)),this.registerEvent(this.app.vault.on("modify",N.debounce(this.onFileModified,2e3,!0))),this.registerEvent(this.app.vault.on("rename",this.onFileRenamed.bind(this))),this.registerEvent(this.app.workspace.on("active-leaf-change",t=>{t?.view?.getViewType()==="canvas"&&hJe(t)})),this.registerEvent(this.app.metadataCache.on("changed",(t,n,r)=>{if(de.getState().preparingUpdateMemo&&de.getState().preparingUpdateMemo.length>0){this.debounceTemplateExecution();return}if(!de.initialized)return;nf(t,"day")&&this.updateCacheDebounced(t)})),this.registerEvent(this.app.workspace.on("templater:all-templates-executed",async()=>{await de.finishWaitingForTemplaterThinos()}))}async onOpen(){this.navigation=this.plugin.settings.navigation,N.Platform.isTablet&&document.body.toggleClass("is-tablet",!0),N.Platform.isMobile&&!N.Platform.isTablet&&this.appendToHeader(),await this.registerEventList(),this.registerPatchWorkspaceLeaf();try{this.root=Fi.createRoot(N.Platform.isDesktop?this.containerEl:this.contentEl),$e.setView(this),this.root.render(w.jsx(Y.StrictMode,{children:w.jsx(fJe,{app:this.plugin.app})}))}catch(t){console.error(t)}}onunload(){super.onunload(),this.root.unmount(),this.mobileHeaderRoot?.unmount(),this.rootList.forEach(t=>{t?.root?.unmount(),t?.canvas?.thinoBtn&&(t.canvas.thinoBtn=void 0),t?.canvas?.wrapperEl.find(".thino-canvas-menu-btn")&&t.canvas.wrapperEl.find(".thino-canvas-menu-btn").detach()})}}class vJe extends N.EditorSuggest{root;editor;cursor;plugin;memos=[];constructor(t,n){super(t),this.plugin=n,this.memos=de.getState().memos.filter(r=>!r.deletedAt&&r.rowStatus!=="ARCHIVED")}checkInMemosView(t){const n=t.containerEl;return n&&n.parentElement?.parentElement?.classList.contains("common-editor-inputer")||!1}fuzzySearchItemsOptimized(t,n){const r=N.prepareFuzzySearch(t);return n.map(o=>{const i=r(o.content);return i?{item:o,match:i}:null}).filter(Boolean)}onTrigger(t,n){if(!this.checkInMemosView(n))return null;const o=n.getLine(t.line).slice(0,t.ch);if(o.lastIndexOf("~")===-1)return null;const i=o.slice(o.lastIndexOf("~")+1,t.ch);if(o[o.lastIndexOf("~")-1]!==" "&&o.lastIndexOf("~")!==0)return null;const a=i.trim();return this.memos=de.getState().memos.filter(s=>!s.deletedAt&&s.rowStatus!=="ARCHIVED"),{start:{line:t.line,ch:t.ch-a.length},end:t,query:a}}getSuggestions(t){return t.query?this.fuzzySearchItemsOptimized(t.query,this.memos).sort((r,o)=>o.match.score-r.match.score).map(r=>r.item).map(r=>({time:r.createdAt,id:r.id,content:r.content})):this.memos.map(r=>({time:r.createdAt,id:r.id,content:r.content}))}renderSuggestion(t,n){n.toggleClass("thino-suggestion",!0),n.createEl("div",{cls:"thino-suggestion-time",text:t.time}),n.createEl("div",{cls:"thino-suggestion-container"}).createEl("div",{cls:"thino-suggestion-content",text:t.content})}async addBlockRefToMemo(t,n){await si(t,{id:t.id,hasId:n})}selectSuggestion(t){const n=de.getMemoById(t.id);if(!n){this.context.editor.replaceRange("MARK: [@THINO]("+t.id+")",{line:this.context.end.line,ch:this.context.start.ch-1},this.context.end);return}n.sourceType==="DAILY"&&n.path?(this.context.editor.replaceRange("MARK: [@THINO]("+t.id+")",{line:this.context.end.line,ch:this.context.start.ch-1},this.context.end),this.handleDailyNoteMemo(n,t)):this.context.editor.replaceRange("MARK: [@THINO]("+t.id+")",{line:this.context.end.line,ch:this.context.start.ch-1},this.context.end)}async handleDailyNoteMemo(t,n){if(!t.path)return;const r=this.app,o=r.vault.getAbstractFileByPath(t.path);if(!(o instanceof N.TFile))return;let i=t.hasId;i||(i=Le.randomId(6),await this.addBlockRefToMemo(t,i));const a=this.context.editor,s=a.getLine(this.context.end.line),l=`MARK: [@THINO](${n.id})`;if(s.includes(l)){const u=s.indexOf(l),d=r.fileManager.generateMarkdownLink(o,"","#^"+i,n.id);a.replaceRange(`MARK: ${d}`,{line:this.context.end.line,ch:u},{line:this.context.end.line,ch:u+l.length})}}}class yJe extends N.EditorSuggest{root;editor;cursor;plugin;constructor(t,n){super(t),this.plugin=n,this.suggestEl.toggleClass("thino-date-selector",!0)}checkInMemosView(t){const n=t.containerEl;return n&&n.parentElement?.parentElement?.classList.contains("common-editor-inputer")||!1}onTrigger(t,n){const o=n.getLine(t.line)[t.ch-1];return this.checkInMemosView(n)&&o==="@"?(this.cursor=t,this.editor=n,N.Platform.isMobile?(new XH(this.app,"text",i=>{this.selectSuggestion(parseInt(i),new MouseEvent("click"))}).open(),null):{start:{line:t.line,ch:t.ch-1},end:t,query:""}):null}getSuggestions(){return[parseInt(N.moment().startOf("day").format("x"))]}renderSuggestion(t,n){n.empty(),this.root=Fi.createRoot(n),this.root.render(w.jsx(Y.StrictMode,{children:w.jsx(xS,{className:"editor-date-picker",datestamp:t,handleDateStampChange:this.selectSuggestion.bind(this)})}))}selectSuggestion(t,n){if(n instanceof KeyboardEvent||n instanceof PointerEvent&&!n.target.closest(".day-item"))return;this.app.workspace.getLeavesOfType("thino_view")[0]?.view?.contentEl.find(".action-btn.list-or-task.list")?.click();let o="",i="";switch(this.plugin.settings.InsertDateFormat){case"Dataview":o="[due:: ",i="]";break;case"Tasks":o="📅 ";break}this.editor.replaceRange(o+N.moment(t).format("YYYY-MM-DD")+i,{line:this.cursor.line,ch:this.cursor.ch-1},this.cursor),this.root?.unmount(),this.close()}}const K6={Memos:'<svg t="1641348507339" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2120" width="100" height="100"><path d="M126.692653 478.099639l-90.757281 0c-19.019408 0-34.437336 15.423923-34.437336 34.417356 0 18.992434 15.416929 34.477297 34.437336 34.477297l90.757281 0c19.013414 0 34.42335-15.484863 34.42335-34.477297C161.116003 493.523561 145.706067 478.099639 126.692653 478.099639zM244.662333 243.526943c13.742566-13.110184 14.310011-34.948836 1.185841-48.706388l-62.644762-65.668806c-13.128167-13.762547-34.974811-14.229091-48.717377-1.118906s-14.261059 34.911872-1.132893 48.674419l62.644762 65.668806C209.123074 256.13262 230.919767 256.637127 244.662333 243.526943zM543.066631 957.422083l-60.603757 0c-18.654764 0-33.794964 15.147193-33.794964 33.862898 0 18.661757 15.1402 32.71502 33.794964 32.71502l60.603757 0c18.654764 0 33.794964-14.053262 33.794964-32.71502C576.861595 972.568277 561.721395 957.422083 543.066631 957.422083zM988.076617 479.050709l-90.757281 0c-19.019408 0-34.437336 15.423923-34.437336 34.417356s15.416929 34.477297 34.437336 34.477297l90.757281 0c19.013414 0 34.42335-15.484863 34.42335-34.477297S1007.09003 479.050709 988.076617 479.050709zM512.268737 192.765564c-172.737143 0-312.75527 150.079292-312.75527 322.746503 0 125.630192 74.080583 233.957298 180.936128 283.703669l0 84.51838c0 16.762614 15.410935 31.35435 34.42335 31.35435 0.598415 0 1.193833-0.014985 1.785255-0.042958 0.618395 0.026974 1.239788 0.042958 1.867175 0.042958l187.479731 0c5.905227 0 11.455802-1.220807 16.288078-3.477601 12.231044-4.657447 20.795671-15.383962 20.795671-27.87575l0-84.052835c107.391021-49.534578 181.935151-158.147405 181.935151-284.168214C825.024007 342.843857 684.997888 192.765564 512.268737 192.765564zM574.863548 742.713968l0 80.17063c0 3.159911-0.221783 5.976158-0.642372 8.496694l0 19.092336-124.910895 0 0-17.71768c-0.423586-2.856208-0.642372-6.123015-0.642372-9.870351l0-80.443363c-99.204024-27.75387-171.970892-118.821847-171.970892-226.930167 0-130.094827 105.4689-245.507007 235.571719-245.507007s235.563727 115.41218 235.563727 245.507007C747.832465 623.984031 674.578074 715.293772 574.863548 742.713968zM895.407204 129.328576c-13.429872-13.429872-35.233558-13.439862-48.677416 0.004995l-64.174267 64.175266c-13.448853 13.448853-13.443858 35.257534-0.013986 48.687406 13.429872 13.429872 35.281511 13.477825 48.730364 0.028972l64.175266-64.175266C908.889025 164.605092 908.837076 142.758448 895.407204 129.328576zM511.796199 159.617967c18.992434 0 34.417356-15.410935 34.417356-34.42335l0-90.757281c0-19.019408-15.423923-34.437336-34.417356-34.437336-18.992434 0-34.477297 15.416929-34.477297 34.437336l0 90.757281C477.317903 144.208031 492.802766 159.617967 511.796199 159.617967z" fill="currentColor" p-id="2121"></path></svg>'};function bJe(){Object.keys(K6).forEach(e=>{N.addIcon(e,K6[e])})}const xN=typeof Buffer=="function";typeof TextDecoder=="function"&&new TextDecoder;const X6=typeof TextEncoder=="function"?new TextEncoder:void 0,wJe="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",pm=Array.prototype.slice.call(wJe);(e=>{let t={};return e.forEach((n,r)=>t[n]=r),t})(pm);const qa=String.fromCharCode.bind(String);typeof Uint8Array.from=="function"&&Uint8Array.from.bind(Uint8Array);const SJe=e=>e.replace(/=/g,"").replace(/[+\/]/g,t=>t=="+"?"-":"_"),TJe=e=>{let t,n,r,o,i="";const a=e.length%3;for(let s=0;s<e.length;){if((n=e.charCodeAt(s++))>255||(r=e.charCodeAt(s++))>255||(o=e.charCodeAt(s++))>255)throw new TypeError("invalid character found");t=n<<16|r<<8|o,i+=pm[t>>18&63]+pm[t>>12&63]+pm[t>>6&63]+pm[t&63]}return a?i.slice(0,a-3)+"===".substring(a):i},GG=typeof btoa=="function"?e=>btoa(e):xN?e=>Buffer.from(e,"binary").toString("base64"):TJe,xJe=xN?e=>Buffer.from(e).toString("base64"):e=>{let n=[];for(let r=0,o=e.length;r<o;r+=4096)n.push(qa.apply(null,e.subarray(r,r+4096)));return GG(n.join(""))},IJe=e=>{if(e.length<2){var t=e.charCodeAt(0);return t<128?e:t<2048?qa(192|t>>>6)+qa(128|t&63):qa(224|t>>>12&15)+qa(128|t>>>6&63)+qa(128|t&63)}else{var t=65536+(e.charCodeAt(0)-55296)*1024+(e.charCodeAt(1)-56320);return qa(240|t>>>18&7)+qa(128|t>>>12&63)+qa(128|t>>>6&63)+qa(128|t&63)}},kJe=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,EJe=e=>e.replace(kJe,IJe),J6=xN?e=>Buffer.from(e,"utf8").toString("base64"):X6?e=>xJe(X6.encode(e)):e=>GG(EJe(e)),CJe=(e,t=!1)=>t?SJe(J6(e)):J6(e);class MJe extends N.Modal{plugin;settingTab;LocationList;target="";insertTarget="";verified;constructor(t,n,r,o,i){super(t),this.verified=i,this.app=t,this.settingTab=n,this.plugin=r,this.LocationList=o,this.target=o.target!=="ProcessEntriesBelow"?r.settings.MemoOtherSaveLocation[o.target]:r.settings[o.target],this.insertTarget=r.settings.InsertAfter}updateValue=N.debounce(t=>{this.LocationList.value!=="DAILY"&&this.LocationList.value!=="MULTI"?this.target=t.trim()===""?"basic":t.trim():this.target=t.trim()===""&&this.LocationList.value==="MULTI"?"Memos":t.trim()},400,!0);onOpen(){this.display()}debounceDisplay=N.debounce(()=>this.display(),400,!0);async display(){const{contentEl:t}=this;this.contentEl.empty(),t.parentElement?.classList.add("memo-save-location-modal"),this.titleEl.toggleClass("modal-title",!0),this.titleEl.setText(E("Save type for Thino")+` [${E(this.LocationList.value)}]`),(this.LocationList.value==="FILE"||this.LocationList.value==="CANVAS")&&t.createDiv("modal-desc",s=>{s.setText(E('You can set folder name with file name like "folder/file"'))}),this.LocationList.value==="MULTI"&&t.createDiv("modal-desc",s=>{s.setText(E('You can set folder name like "folder1/folder2/folder3" to create sub-folder'))}),this.LocationList.value==="DAILY"&&t.createDiv("modal-desc",s=>{s.setText(E('You can set target heading like "# Heading" to control data location'))});const n=t.createDiv("modal-setting"),r=this.LocationList.value==="DAILY"?E("Process Memos below"):this.LocationList.value==="MULTI"?E("Set the folder name"):E("Set the filename");if(this.LocationList.value==="DAILY"&&(new Oe(n,this.settingTab).setName(E("Set thino insert place")).setDesc(E("Set where to insert thino content")).addDropdown(async s=>{s.addOption("end",E("End of the diary")),s.addOption("custom",E("Custom location")),s.setValue(this.plugin.settings.InsertType).onChange(async l=>{this.plugin.settings.InsertType=l,this.settingTab.applySettingsUpdate(),this.debounceDisplay()})}),this.plugin.settings.InsertType==="custom"&&await this.addDailySettings(n),new Oe(n,this.settingTab).setName(E("Set process target")).setDesc(E("You can set whole diary or only part of it")).addDropdown(async s=>{s.addOption("custom",E("Custom")),s.addOption("whole",E("Whole diary")),s.setValue(this.plugin.settings.ProcessContentTarget).onChange(async l=>{this.plugin.settings.ProcessContentTarget=l,this.settingTab.applySettingsUpdate(),this.debounceDisplay()})})),this.LocationList.value!=="DAILY"||this.plugin.settings.ProcessContentTarget!=="whole"){const s=new Oe(n,this.settingTab).setName(r).addText(l=>l.setPlaceholder(this.LocationList.value==="DAILY"?E("# Heading"):E("Set the filename for current location file")).setValue(this.LocationList.value!=="DAILY"&&this.LocationList.value!=="MULTI"?this.target.replace(/\.thino\.(canvas|md)/g,""):this.target).onChange(async u=>{const d=this.LocationList.value==="CANVAS"?".thino.canvas":this.LocationList.value==="FILE"?".thino.md":"";this.updateValue(u.replace(/\.thino\.(canvas|md)/g,"")+d)}));this.LocationList.value==="DAILY"&&s.setDesc(E("If left blank, the Thino interface will display all thino record contents; if a title is provided, the Thino interface will only display the contents under that title, and contents written elsewhere will not be shown.")),this.LocationList.value!=="DAILY"&&this.LocationList.value!=="MULTI"&&s.controlEl.createEl("span",{text:`${this.LocationList.value==="FILE"?".thino.md":".thino.canvas"}`})}this.LocationList.value==="MULTI"&&new Oe(n,this.settingTab).setName(E("Set file name after create thino")).setDesc(E("You can set file name after create thino. A input box will show when you create thino.")).addToggle(s=>{s.setValue(this.plugin.settings.SetFileNameAfterCreate).onChange(async l=>{this.plugin.settings.SetFileNameAfterCreate=l,this.settingTab.debounceApplySettingsUpdate()})}),this.LocationList.value==="FILE"&&new Oe(n,this.settingTab).setName(E("Set tag for file type file")).setDesc(E("When you set a tag here, Thino will index this file contains this tag and show it in the list. Don't need to add `#`.")).addText(s=>{new Hm(s.inputEl,l=>{this.plugin.settings.TagForFileTypeFiles=l.trim(),this.settingTab.debounceApplySettingsUpdate()}),s.setPlaceholder(E("Please input the tag")).setValue(this.plugin.settings.TagForFileTypeFiles).onChange(async l=>{this.plugin.settings.TagForFileTypeFiles=l.trim(),this.settingTab.debounceApplySettingsUpdate()})}),this.LocationList.value==="MULTI"&&(new Oe(n,this.settingTab).setName(E("Set tag for multi type file")).setDesc(E("When you set a tag here, Thino will index this file contains this tag and show it in the list. Don't need to add `#`.")).addText(s=>{new Hm(s.inputEl,l=>{this.plugin.settings.TagForMultiTypeFiles=l.trim(),this.settingTab.debounceApplySettingsUpdate()}),s.setPlaceholder(E("Please input the tag")).setValue(this.plugin.settings.TagForMultiTypeFiles).onChange(async l=>{this.plugin.settings.TagForMultiTypeFiles=l.trim(),this.settingTab.debounceApplySettingsUpdate()})}),new Oe(n,this.settingTab).setName(E("Ignore folders for multi type")).setDesc(E("Set folders to ignore when using multi type. Separate multiple folders with comma (,).")).addText(s=>{s.setPlaceholder(E("folder1,folder2/subfolder")).setValue(this.plugin.settings.IgnoreFolderForMultiType.join(",")).onChange(async l=>{this.plugin.settings.IgnoreFolderForMultiType=l.split(",").map(u=>u.trim()).filter(u=>u!==""),this.settingTab.debounceApplySettingsUpdate()})}));const o=t.createDiv("button-group"),i=o.createEl("button",{text:E("Cancel")}),a=o.createEl("button",{text:E("Save")});a.onclick=async()=>{if(!this.verified&&this.LocationList.value!=="DAILY"){this.close(),Nt();return}this.LocationList.target!=="ProcessEntriesBelow"?this.plugin.settings.MemoOtherSaveLocation[this.LocationList.target]=this.target:this.plugin.settings[this.LocationList.target]=this.target,this.LocationList.value==="MULTI"&&Le.checkDailyInMulti(this.plugin.settings),this.LocationList.target==="ProcessEntriesBelow"&&(this.plugin.settings.InsertAfter=this.insertTarget),this.settingTab.applySettingsUpdate(),setTimeout(()=>{de.updateTypeMemos(this.LocationList.value)},1e3),this.close()},i.onclick=async()=>{this.close()}}async addDailySettings(t){const n=$e.getState().verifyState,r=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),o=N.Platform.isDesktop?await Sn():r.identifier||r.uuid,i=n&&n?.appId===o,a=(this.plugin.settings?.DifferentInsertTarget?`[${E("List")}] `:"")+E("Insert after heading");new Oe(t,this.settingTab).setName(a).setDesc(E("If left blank, the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.")).addText(s=>s.setPlaceholder(E("# Heading")).setValue(this.insertTarget).onChange(async l=>{this.insertTarget=l})),this.plugin.settings?.DifferentInsertTarget&&new Oe(t,this.settingTab).setName((this.plugin.settings?.DifferentInsertTarget?`[${E("Task")}] `:"")+E("Insert after heading")).setDesc(E("Set the heading for the task type of thino, by default the recorded thino content will be inserted at the end of the diary; if a title is provided, all recorded thino content will be uniformly categorized under that title.")).addText(s=>{s.setPlaceholder(E("# Heading")).setValue(this.plugin.settings.InsertAfterForTask).onChange(async l=>{this.plugin.settings.InsertAfterForTask=l,this.settingTab.applySettingsUpdate()})}),new Oe(t,this.settingTab).setName(E("Different insert target for different type")).setDesc(E("Toggle this to set different insert target for different type of thino, like task or list type of thino")).addToggle(s=>s.setValue(this.plugin.settings.DifferentInsertTarget).onChange(async l=>{if(!i){Nt();return}this.plugin.settings.DifferentInsertTarget=l,this.settingTab.applySettingsUpdate(),this.debounceDisplay()}))}onClose(){const{contentEl:t}=this;t.empty()}}const Bk=N.Platform.isDesktop&&require("os"),ZG=async()=>{let e="";if(N.Platform.isDesktop)e=await Sn();else{const r=await window.Capacitor?.Plugins.Device.getId();e=r.identifier||r.uuid}let t;if(Bk)t=JSON.stringify({hostname:Bk.hostname(),platform:Bk.platform(),machineid:e});else{const r=await window.Capacitor?.Plugins.Device.getInfo(),o=r?.model,i=r?.platform;t=JSON.stringify({hostname:o||("mobile"+N.Platform.isMobile?Math.random().toString(36).substring(7):""),platform:i||"mobile",machineid:e})}return CJe(t)},DJe=async()=>{let e="";if(N.Platform.isDesktop)e=await Sn();else{const t=await window.Capacitor?.Plugins.Device.getId();e=t.identifier||t.uuid}return e},AJe={General:"chef-hat",Thino:"Memos",Interface:"brush",Share:"share-2",Advanced:"cog"},NJe=[{value:"DAILY",target:"ProcessEntriesBelow",insert:"InsertAfter"},{value:"CANVAS",target:"MemoDefaultCanvasPath"},{value:"MULTI",target:"MemoDefaultMultiFilePath"},{value:"FILE",target:"MemoDefaultSingleFilePath"}],ti={FirstLoaded:!0,StartDate:"Sunday",InsertAfter:"",UserName:"THINO 😉",ProcessEntriesBelow:"",Language:"en",SaveMemoButtonLabel:"NOTE",SaveMemoButtonIcon:"",ShareFooterStart:"{ThinoNum} Thino {UsedDay} Day",ShareFooterEnd:"✍️ by {UserName}",DefaultPrefix:"List",DefaultTimePrefix:"HH:mm",UseDailyOrPeriodic:"Daily",InsertDateFormat:"Tasks",DefaultEditorLocation:"Top",UseButtonToShowEditor:!1,FocusOnEditor:!0,OpenDailyMemosWithMemos:!0,HideDoneTasks:!1,ShowTaskLabel:!0,AppendDateWhenTaskDone:!1,MobileAndDesktop:"All",OpenMemosAutomatically:!1,ShowScrollbar:!1,ShowTime:!0,ShowDate:!0,AddBlankLineWhenDate:!1,AutoSaveWhenOnMobile:!1,DeleteFileName:"delete",QueryFileName:"query",UseVaultTags:!1,SetCustomBackgroundImage:!1,SetCustomMemoFooter:!1,DefaultLightBackgroundImage:"",DefaultDarkBackgroundImage:"",DefaultLightBackgroundImageForClean:"",DefaultDarkBackgroundImageForClean:"",DefaultMemoComposition:"{TIME} {CONTENT}",CommentOnMemos:!1,CommentsInOriginalNotes:!1,FetchMemosMark:"#memo",FetchMemosFromNote:!1,ShowCommentOnMemos:!1,ShowLeftSideBar:!1,MemoListView:"list",MemoSaveLocation:"DAILY",MemoOtherSaveLocation:{MemoDefaultCanvasPath:"basic.thino.canvas",MemoDefaultMultiFilePath:"Thino",MemoDefaultSingleFilePath:"basic.thino.md"},MemoDailyTarget:5,HeatmapColorScheme:"default",EnabledHttpApi:!1,HttpApiIpType:"127.0.0.1",HttpApiPort:"43999",AutoDownloadImage:!1,EditorType:"obsidian",EnabledLocationList:[{value:"DAILY",target:"ProcessEntriesBelow",insert:"InsertAfter"}],DeleteThinoDirectly:!1,CaptureKey:{EnableCaptureKey:!1,OpenThinoGlobally:"CommandOrControl+Shift+T",ShowNearMouse:!1},startSync:!1,tokenForVerify:{},saveThinoType:"FILE",showDayMark:!1,dayMarkRange:"day",navigation:!1,password:"",needVerify:!1,addTagAutomatically:!1,addTagPosition:"End",addTagWithNewline:!1,chatViewStyle:"default",MomentsBackgroundImage:"https://images.pexels.com/photos/531767/pexels-photo-531767.jpeg",MomentsIcon:"https://images.pexels.com/photos/256514/pexels-photo-256514.jpeg",MomentsQuote:"Share your thino with the world",DefaultThemeForThino:"modern",LastUpdatedVersion:"0.0.0",ShareToThinoWithText:!1,ShareToThinoWithTextAppend:"",ShareToThinoWithTextPrepend:"",ShareToThinoWithTextNewline:"none",hidePinnedGroup:!1,DifferentInsertTarget:!1,InsertAfterForTask:"",ProcessContentTarget:"custom",InsertType:"custom",ShareAppendType:"preset",SharePrependType:"preset",SetFileNameAfterCreate:!1,TagForFileTypeFiles:"thino/file",TagForMultiTypeFiles:"thino/multi",MinHeightForShare:"200px",ThinoMaxHeight:0,ThinoCollapsedHeight:100,OptimizeForCallout:!0,AppendOrPrependTextViaServer:!1,AppendViaServer:"",PrependViaServer:"",WithNewLineViaServer:"none",SupportSelectOtherView:!1,WaitTemplaterToFinishParse:!1,NavbarButton:!1,AlwaysShowStatusText:!1,FilterByMetadata:!1,ShowSourcePath:!1,ShowUpdateMessage:!0,SyncManually:!1,MemoFixedPrefix:"",MemoFixedSuffix:"",UseMemoFixedStrings:!1,enableWordCount:!1,maxWordCount:0,enableReferenceLinksGroup:!1,doubleClickBehavior:"edit-thino",useMobileViewDefaultHeader:!1,IgnoreFolderForMultiType:[],UseBlockLinkWhenDragging:!1,ShowScrollToTopButton:!0,ZoomImageWhenViewing:!1,ViewArchiveInRandomReview:!1,DraggingBehavior:"block-link"};function OJe({plugin:e}){const{dailyNotesState:{verifyState:t}}=D.useContext(ct),[n,r]=D.useState(!1),[o,i]=D.useState(!1),[a,s]=D.useState(""),[l,u]=D.useState("");D.useEffect(()=>{DJe().then(p=>{u(p)})},[]);const d=async()=>{const p=a,m=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),b=N.Platform.isDesktop?await Sn():m.identifier||m.uuid;p&&(e.settingTab.updateSettings("tokenForVerify",{...e.settings.tokenForVerify,[b]:p}),e.verify().then(v=>{v&&(r(!0),Ze.setRefresh(!0),setTimeout(()=>{e.settingTab.display()},200),e.registerToolbarCheck()),new N.Notice(E(v?"Verify successfully":"Failed to verify"))}).catch(v=>{new N.Notice(E("Failed to verify"))}))},h=async p=>{s(p)};return w.jsx("div",{className:"thino-verify-component",children:t?w.jsxs("div",{className:"thino-verify-content verified",children:[w.jsx("div",{className:"thino-verified-text",children:E("You have verified your account. Congrats!")}),w.jsx("div",{className:"thino-description-link",children:w.jsxs("p",{children:[E("If you have any questions, please contact us."),w.jsx("span",{className:"thino-url",onClick:()=>{const p=localStorage.getItem("language");p&&(p==="zh"||p==="zh-TW")?window.open("https://pkmer.cn","_blank"):window.open("https://thino.pkmer.net/en/","_blank")},children:"@ PKMer"})]})})]}):w.jsxs("div",{className:"thino-verify-content",children:[w.jsxs("div",{className:"thino-description-link",children:[E("You can buy a license from")+"->",w.jsxs("span",{className:"thino-url",onClick:()=>{const p=localStorage.getItem("language");p&&(p==="zh"||p==="zh-TW")?window.open("https://pkmer.cn/products/thino","_blank"):window.open("https://thino.pkmer.net/en/#price","_blank")},children:[" ","PKMer"]})]}),w.jsx("textarea",{className:"thino-verify-textarea",value:a,onChange:p=>h(p.target.value),placeholder:E("Input activation code here")}),w.jsxs("div",{className:"thino-button-container",children:[w.jsxs("div",{className:"thino-button-group",children:[!a&&w.jsxs(w.Fragment,{children:[w.jsx("button",{onClick:async()=>{try{const p=await ZG();await navigator.clipboard.writeText(p),i(!0)}catch(p){console.error(p),new N.Notice("Failed to copy id");return}new N.Notice(E("Copied to clipboard Successfully"))},children:E("Copy Thino id")}),w.jsx("button",{onClick:()=>{if(!o){new N.Notice(E("Please copy Thino id first"));return}const p=localStorage.getItem("language");p&&(p==="zh"||p==="zh-TW")?window.open("https://pkmer.cn/products/UserProfile/#tab-21&getCode","_blank"):window.open("https://pkmer.net/en/userprofile/#tab-21&getCode","_blank"),r(!0)},children:E("Get activation code")})]}),a&&w.jsx("button",{onClick:async()=>{await d()},children:E("Verify")})]}),n?w.jsx("p",{children:E("After you verify your account, please refresh this page.")}):""]}),w.jsxs("div",{className:"thino-description-link",children:[E("If you have any questions, please contact us."),w.jsx("span",{className:"thino-url",onClick:()=>{const p=localStorage.getItem("language");p&&(p==="zh"||p==="zh-TW")?window.open("https://pkmer.cn","_blank"):window.open("https://thino.pkmer.net/en/","_blank")},children:"@ PKMer"})]})]})})}class PJe extends N.PluginSettingTab{plugin;applyDebounceTimer=0;tabContent=new Map;selectedTab="General";search;searchSettingInfo=new Map;searchZeroState;navigateEl;passwordMatched=!1;root;constructor(t,n){super(t,n),this.plugin=n}updateSettings(t,n){this.plugin.settings={...this.plugin.settings,[t]:n},this.applySettingsUpdate()}debounceApplySettingsUpdate=N.debounce(async()=>{await this.plugin.saveSettings()},100,!0);debounceDisplay=N.debounce(async()=>{await this.display()},300,!0);applySettingsUpdate(){this.debounceApplySettingsUpdate(),de.updateTagsState()}async hide(){this.root?.unmount(),this.passwordMatched=!1}async display(){await this.plugin.loadSettings(),this.root&&this.root?.unmount(),this.containerEl.empty(),this.containerEl.toggleClass("memos-settings",!0),N.Platform.isMobile&&this.containerEl.toggleClass("memos-mobile",!0),this.generateSettingsTitle(),this.addTabHeader()}generateSettingsTitle(){const t=this.containerEl.createDiv("memos-setting-title");t.createEl("h2",{text:"Thino"}),this.generateSearchBar(t)}addTabHeader(){const t=this.containerEl.createEl("nav",{cls:"memos-setting-header"});this.navigateEl=t.createDiv("memos-setting-tab-group");const n=this.containerEl.createDiv("memos-setting-content");this.updateOldData(),this.createTabAndContent("General",this.navigateEl,n,(r,o)=>this.generateGeneralSettings(o,r)),this.createTabAndContent("Thino",this.navigateEl,n,(r,o)=>this.generateMemosSettings(o,r)),this.createTabAndContent("Interface",this.navigateEl,n,(r,o)=>this.generateThemeSettings(o,r)),this.createTabAndContent("Share",this.navigateEl,n,(r,o)=>this.generateShareSettings(o,r)),this.createTabAndContent("Advanced",this.navigateEl,n,(r,o)=>this.generateAdvancedSettings(o,r)),this.createSearchZeroState(n)}updateOldData(){this.plugin.settings.UserName.startsWith("MEMO ")&&(this.plugin.settings.UserName="THINO 😉"),this.plugin.settings.ShareFooterStart.contains("{Memo")&&(this.plugin.settings.ShareFooterStart=this.plugin.settings.ShareFooterStart.replace("{MemosNum}","{ThinoNum}").replace("memos","thino")),this.applySettingsUpdate()}generateSearchBar(t){const n=new N.Setting(t);n.settingEl.style.border="none",n.addSearch(r=>{this.search=r}),this.search.setPlaceholder(E("Search all settings")),this.search.inputEl.oninput=()=>{for(const r of this.tabContent){const o=r[1];o.navButton.removeClass("memos-navigation-item-selected"),o.content.show(),o.heading.show();const i=this.search.getValue();this.selectedTab==""&&i.trim()!=""&&this.searchSettings(i.toLowerCase()),this.selectedTab=""}this.navigateEl.addClass("memos-setting-searching")},this.search.inputEl.onblur=()=>{this.navigateEl.removeClass("memos-setting-searching")},this.search.onChange(r=>{if(r===""){this.triggerTabChange(this.tabContent.get("General")?.navButton,"General");return}this.searchSettings(r.toLowerCase())})}triggerTabChange(t,n){if(this.selectedTab==n)return;if(t.toggleClass("memos-navigation-item-selected",!0),(this.tabContent.get(n)?.content).show(),this.selectedTab!=""){const o=this.tabContent.get(this.selectedTab);o?.navButton.removeClass("memos-navigation-item-selected"),(o?.content).hide()}else{this.searchZeroState.hide();for(const o of this.searchSettingInfo)for(const i of o[1])i.containerEl.show();for(const o of this.tabContent){const i=o[1];i.heading.hide(),n!==o[0]&&i.content.hide()}}this.selectedTab=n}createTabAndContent(t,n,r,o){const i=this.selectedTab===t,a=n.createDiv("memos-navigation-item");a.toggleClass("memos-desktop",!0),N.setIcon(a.createEl("div",{cls:"memos-navigation-item-icon"}),AJe[t]),a.createSpan({text:E(t)}),a.onclick=()=>{this.triggerTabChange(a,t)};const s=r.createDiv("memos-tab-settings"),l=s.createEl("h2",{cls:"memos-setting-heading",text:t+" Settings"});l.hide(),s.id=t.toLowerCase().replace(" ","-"),i?a.addClass("memos-navigation-item-selected"):s.hide(),o&&o(s,t),this.tabContent.set(t,{content:s,heading:l,navButton:a})}searchSettings(t){const n=new Set,r=(o,i)=>{o.show(),n.has(i)||n.add(i)};for(const o of this.searchSettingInfo){const i=o[0],a=o[1];for(const s of a)if(t.trim()===""||s.alias?.includes(t)||s.description.includes(t)||s.name.includes(t))r(s.containerEl,i);else if(s.options&&s.options.length>0)for(const l of s.options){if(l.description.toLowerCase().includes(t)||l.name.toLowerCase().includes(t)){r(s.containerEl,i);break}else if(l.options){for(const u of l.options)if(u.description.toLowerCase().includes(t)||u.value.toLowerCase().includes(t)){r(s.containerEl,i);break}}s.containerEl.hide()}else s.containerEl.hide()}for(const o of this.tabContent)n.has(o[0])?o[1].heading.show():o[1].heading.hide();n.size===0?this.searchZeroState.show():this.searchZeroState.hide()}addSettingToMasterSettingsList(t,n,r="",o="",i=[],a=""){const s={containerEl:n,name:r.toLowerCase(),description:o.toLowerCase(),options:i,alias:a};this.searchSettingInfo.has(t)?this.searchSettingInfo.get(t)?.push(s):this.searchSettingInfo.set(t,[s])}createSearchZeroState(t){this.searchZeroState=t.createDiv(),this.searchZeroState.hide(),this.searchZeroState.createEl(N.Platform.isMobile?"h3":"h2",{text:"No settings match search"}).style.textAlign="center"}generateGeneralSettings(t,n){this.customHeading(t,n)}async generateThemeSettings(t,n){const r=$e.getState().verifyState,o=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),i=N.Platform.isDesktop?await Sn():o.identifier||o.uuid,a=r&&r?.appId===i;await this.customNameAndTheme(t,n,a)}async generateMemosSettings(t,n){const r=$e.getState().verifyState,o=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),i=N.Platform.isDesktop?await Sn():o.identifier||o.uuid,a=r&&r?.appId===i;this.setPasswordSettings(t,n),this.addMemoSettings(t,n),this.addTaskRelatedSettings(t,n),this.customFileNameSettings(t,n,a),this.addScrollToTopSettings(t,n),this.addRememberImageSettings(t,n),this.addViewArchiveInRandomReviewSettings(t,n),this.addThinoProSettings(t,n,a)}async generateShareSettings(t,n){const r=$e.getState().verifyState,o=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),i=N.Platform.isDesktop?await Sn():o.identifier||o.uuid,a=r&&r?.appId===i;new Oe(n,this).setHeading().setTab(t).setName("📄 "+E("Copy filtered results")),this.copyMemosSettings(t,n),new Oe(n,this).setHeading().setTab(t).setName("🖼 "+E("Share image")),this.shareMemosSettings(t,n),N.Platform.isMobile&&this.shareToThinosSettings(t,n,a)}async generateAdvancedSettings(t,n){this.addDoubleClickBehaviorSettings(t,n),this.addDraggingBehaviorSettings(t,n),this.addUseMobileViewDefaultHeaderSettings(t,n),this.saveDataSettings(t,n),this.fetchDataSettings(t,n),this.navigationSettings(t,n),this.optimizeForCalloutSettings(t,n),this.addUpdateMessageSettings(t,n),this.clearConfigSettings(t,n);const r=$e.getState().verifyState,o=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),i=N.Platform.isDesktop?await Sn():o.identifier||o.uuid,a=r&&r?.appId===i;this.setGlobalSettings(t,n,a)}addDoubleClickBehaviorSettings(t,n){new Oe(n,this).setName(E("Double click behavior")).setDesc(E("Set the behavior when double click on a thino.")).setTab(t).addDropdown(async r=>{r.addOption("open-thino",E("Open thino")),r.addOption("edit-thino",E("Edit thino")),r.addOption("go-to-source",E("Go to source")),r.addOption("do-nothing",E("Do nothing")),r.setValue(this.plugin.settings.doubleClickBehavior).onChange(async o=>{this.plugin.settings.doubleClickBehavior=o,this.applySettingsUpdate()})})}addDraggingBehaviorSettings(t,n){new Oe(n,this).setName(E("Dragging behavior")).setDesc(E("Control the behavior when dragging a thino. You will paste the block link by default. Block-link option only works with source type is Daily Note.")).setTab(t).addDropdown(async r=>{r.addOption("block-link",E("Block link")),r.addOption("text",E("Text")),r.setValue(this.plugin.settings.DraggingBehavior).onChange(async o=>{this.plugin.settings.DraggingBehavior=o,this.applySettingsUpdate()})})}addUseMobileViewDefaultHeaderSettings(t,n){new Oe(n,this).setName(E("Use default header in mobile view")).setDesc(E("Use default header in mobile view of thino rather than custom header.")).setTab(t).addToggle(r=>{r.setValue(this.plugin.settings.useMobileViewDefaultHeader).onChange(async o=>{this.plugin.settings.useMobileViewDefaultHeader=o,this.applySettingsUpdate()})})}async customNameAndTheme(t,n,r){new Oe(n,this).setName(E("Theme for Thino")).setDesc(E("Set the theme for Thino")).setTab(t).addDropdown(async i=>{i.addOption("modern","Modern"),i.addOption("classic","Classic"),i.setValue(this.plugin.settings.DefaultThemeForThino).onChange(async a=>{this.plugin.settings.DefaultThemeForThino=a,this.applySettingsUpdate()})}),new Oe(n,this).setTab(t).setHeading().setName("🎨 "+E("Interface Details"));let o;new Oe(n,this).setName(E("Heatmap Color Scheme")).setDesc(E("Set different color scheme for heatmap.")).setTab(t).addDropdown(async i=>{o=i,o.addOption("default",E("Default")),o.addOption("gray",E("Gray")),o.addOption("grass",E("Grass")),o.addOption("flame",E("Flame")),o.addOption("olive",E("Olive")),o.addOption("ice",E("Ice")),o.addOption("magenta",E("Magenta")),o.setValue(this.plugin.settings.HeatmapColorScheme).onChange(async a=>{this.plugin.settings.HeatmapColorScheme=a,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Show all scrollbars")).setDesc(E("Show scrollbars in all thino views.")).setTab(t).addToggle(i=>{i.setValue(this.plugin.settings.ShowScrollbar).onChange(async a=>{this.plugin.settings.ShowScrollbar=a,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Save Memo button label")).setDesc(E("The text shown on the save Memo button in the UI. 'NOTEIT' by default.")).setTab(t).addText(i=>i.setPlaceholder(ti.SaveMemoButtonLabel).setValue(this.plugin.settings.SaveMemoButtonLabel).onChange(async a=>{this.plugin.settings.SaveMemoButtonLabel=a,this.applySettingsUpdate()})),!N.Platform.isMobile&&new Oe(n,this).setName(E("Always Show Leaf Sidebar on PC")).setDesc(E("Show left sidebar on PC/Tablet even when the leaf width is less than 875px. False by default.")).setTab(t).addToggle(i=>i.setValue(this.plugin.settings.ShowLeftSideBar).onChange(async a=>{this.plugin.settings.ShowLeftSideBar=a,this.applySettingsUpdate()})),new Oe(n,this).setName(E("Max height for collapse")).setDesc(E("The max height for thino collapse, when set 0, thino would not collapse. 0 by default. (This is not lines count, it is height in px.)")).setTab(t).addText(i=>i.setPlaceholder(ti.ThinoMaxHeight.toString()).setValue(this.plugin.settings.ThinoMaxHeight.toString()).onChange(async a=>{if(Number(a)<80&&Number(a)!==0){new N.Notice(E("The value should be greater than")+"80");return}this.plugin.settings.ThinoMaxHeight=Number(a),this.debounceApplySettingsUpdate()})),new Oe(n,this).setName(E("Thino height when collapsed")).setDesc(E("The height for thino when it is collapsed, when set 0, thino would not collapse. 100 by default. (This is not lines count, it is height in px.)")).setTab(t).addText(i=>i.setPlaceholder(ti.ThinoCollapsedHeight.toString()).setValue(this.plugin.settings.ThinoCollapsedHeight.toString()).onChange(async a=>{if(Number(a)<40&&Number(a)!==0){new N.Notice(E("The value should be greater than")+"40");return}this.plugin.settings.ThinoCollapsedHeight=Number(a),this.debounceApplySettingsUpdate()})),await this.getEditorLocation(n,t),new Oe(n,this).setHeading().setTab(t).setName("💎 "+E("Pro features")),new Oe(n,this).setName(E("Reference links group")).setDesc(E("Enable reference links group in thino.")).setTab(t).addToggle(i=>{i.setValue(this.plugin.settings.enableReferenceLinksGroup).onChange(async a=>{if(!r){Nt();return}this.plugin.settings.enableReferenceLinksGroup=a,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Word count feature")).setDesc(E("Enable real-time word count display in the editor")).addToggle(i=>{i.setValue(this.plugin.settings.enableWordCount).onChange(async a=>{if(!r){Nt();return}this.plugin.settings.enableWordCount=a,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Maximum word count")).setDesc(E("Set a maximum word count for thino. Editor will display a warning when exceeded. Set to 0 for unlimited.")).setDisabled(!r||!this.plugin.settings.enableWordCount).addText(i=>{i.inputEl.type="number",i.setValue(this.plugin.settings.maxWordCount.toString()).onChange(async a=>{const s=parseInt(a);!isNaN(s)&&s>=0&&(this.plugin.settings.maxWordCount=s,this.applySettingsUpdate())})}),new Oe(n,this).setName(E("Always show status text")).addToggle(i=>i.setValue(this.plugin.settings.AlwaysShowStatusText).onChange(async a=>{this.plugin.settings.AlwaysShowStatusText=a,document.body.toggleClass("thino-show-status",a),this.applySettingsUpdate()})),N.Platform.isMobile&&new Oe(n,this).setName(E("Quick add button on mobile navbar")).setTab(t).addToggle(i=>{i.setValue(this.plugin.settings.NavbarButton).onChange(async a=>{if(!r){Nt();return}this.plugin.settings.NavbarButton=a,this.applySettingsUpdate()})}),this.addThinoDailyMarkSettings(t,n,r),new Oe(n,this).setName(E("Chat view style")).setDesc(E("Set the style of chat view")).setTab(t).addDropdown(async i=>{o=i,o.addOption("default","Default"),o.addOption("fluent","Fluent"),o.addOption("inline","Inline"),o.setValue(this.plugin.settings.chatViewStyle).onChange(async a=>{if(!r){Nt();return}this.plugin.settings.chatViewStyle=a,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Can select other views when leaf width is not enough")).setDesc(E("This option will allow you use other views when leaf width is not enough. False by default.")).setTab(t).addToggle(i=>{i.setValue(this.plugin.settings.SupportSelectOtherView).onChange(async a=>{if(!r){Nt();return}this.plugin.settings.SupportSelectOtherView=a,this.applySettingsUpdate()})}),this.addThinoMomentsSettings(t,n,r)}addThinoDailyMarkSettings(t,n,r){let o;new Oe(n,this).setName(E("Show day mark in thino list")).setDesc(E("Show day mark on the top of daily range thino. False by default.")).setTab(t).addToggle(i=>i.setValue(this.plugin.settings.showDayMark).onChange(async a=>{if(!r){Nt();return}this.plugin.settings.showDayMark=a,this.applySettingsUpdate(),this.debounceDisplay()})),this.plugin.settings.showDayMark&&(new Oe(n,this).setName(E("Day mark range")).setDesc(E("Set the range of day mark. Day by default.")).setTab(t).addDropdown(async i=>{o=i,o.addOption("day","day"),o.addOption("week","week"),o.addOption("month","month"),o.addOption("quarter","quarter"),o.addOption("year","year"),o.setValue(this.plugin.settings.dayMarkRange).onChange(async a=>{this.plugin.settings.dayMarkRange=a,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Hide pinned group")).setDesc(E("Hide pinned group in thino list. False by default.")).setTab(t).addToggle(i=>i.setValue(this.plugin.settings.hidePinnedGroup).onChange(async a=>{if(!r){Nt();return}this.plugin.settings.hidePinnedGroup=a,this.applySettingsUpdate()})))}addThinoMomentsSettings(t,n,r){new Oe(n,this).setTab(t).setName(E("Background image for moments view")).setDesc(E("Set the background image for moments view")).addText(o=>{new pu(o.inputEl),o.setPlaceholder("URL").setValue(this.plugin.settings.MomentsBackgroundImage).onChange(async i=>{r&&(this.plugin.settings.MomentsBackgroundImage=i,this.applySettingsUpdate())})})}async getEditorLocation(t,n){let r;N.Platform.isMobile&&(new Oe(t,this).setName(E("Default editor position on mobile")).setDesc(E("Set the default editor position on Mobile, 'Top' by default.")).setTab(n).addDropdown(async o=>{r=o,r.addOption("Top",E("Top")),r.addOption("Bottom",E("Bottom")),r.setValue(this.plugin.settings.DefaultEditorLocation).onChange(async i=>{this.plugin.settings.DefaultEditorLocation=i,this.applySettingsUpdate(),setTimeout(()=>{this.display()},200)})}),this.plugin.settings.DefaultEditorLocation!=="Top"&&new Oe(t,this).setName(E("Use button to show editor on mobile")).setDesc(E("Set a float button to call editor on mobile. Only when editor located at the bottom works.")).setTab(n).addToggle(o=>o.setValue(this.plugin.settings.UseButtonToShowEditor).onChange(async i=>{this.plugin.settings.UseButtonToShowEditor=i,this.applySettingsUpdate()})))}customHeading(t,n){new Oe(n,this).setHeading().setName("👤 "+E("User info")).setTab(t),new Oe(n,this).setName(E("User name")).setDesc(E("Set your user name here. 'Memos 😏' By default")).setTab(t).addText(h=>h.setPlaceholder(ti.UserName).setValue(this.plugin.settings.UserName).onChange(async p=>{this.plugin.settings.UserName=p,this.applySettingsUpdate()})),new Oe(n,this).setTab(t).setName(E("User icon")).setDesc(E("Set user icon for thino. You can input http/https link or file path in vault.")).addText(h=>{new pu(h.inputEl),h.setPlaceholder("URL").setValue(this.plugin.settings.MomentsIcon).onChange(async p=>{this.plugin.settings.MomentsIcon=p,this.applySettingsUpdate()})}),new Oe(n,this).setTab(t).setName(E("User quote")).setDesc(E("Set user quote for thino")).addText(h=>h.setPlaceholder("Input anything here").setValue(this.plugin.settings.MomentsQuote).onChange(async p=>{this.plugin.settings.MomentsQuote=p,this.applySettingsUpdate()}));let r=!1;const o=document.createDocumentFragment();o.createEl("span",{text:E("Connect to PKMer Sync, you can check it in ")});const i=localStorage.getItem("language");let a;i&&i==="zh"?a="https://pkmer.cn/products/UserProfile/#tab-21&activateSync":a="https://thino.pkmer.net/en/",o.createEl("a",{text:E("PKMer Sync"),attr:{href:a}}),new Oe(n,this).setHeading().setName("🏆 "+E("Pro verification status")).setTab(t);const s=document.createDocumentFragment(),l=s.createEl("div",{cls:"thino-activation"}),u=new Oe(n,this).setName(E("Activate Pro Version")).setDesc(s).setTab(t);u.settingEl.toggleClass("thino-activation-setting",!0),u.nameEl.toggleClass("thino-activation-title",!0),this.root=Fi.createRoot(l),this.root.render(w.jsx(zi,{store:ke,context:ct,children:w.jsx(OJe,{plugin:this.plugin})}));let d=!1;new Oe(n,this).setName(E("Deactivate")).setTab(t).addButton(h=>{h.setWarning().setButtonText(E("Remove")).onClick(async()=>{if(!d){h.setButtonText(E("Confirm?")),d=!0;return}d=!1;const p=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),m=N.Platform.isDesktop?await Sn():p.identifier||p.uuid;this.plugin.settings.tokenForVerify[m]&&(delete this.plugin.settings.tokenForVerify[m],await this.plugin.saveSettings(),new N.Notice(E("Remove successfully"))),await this.plugin.verify(),Ze.setRefresh(!0),setTimeout(()=>{this.display()},20)})}),(i==="zh"||i==="zh-TW")&&new Oe(n,this).setHeading().setName("☁ "+E("Sync service")).setTab(t),(i==="zh"||i==="zh-TW")&&new Oe(n,this).setName(E("Sync Thino via PKMer")).setDesc(o).setTab(t).addButton(h=>{const p=this.plugin.app?.loadLocalStorage("tokenForSync");h.setButtonText(E(p?"Unlink":"Link")).onClick(async()=>{if(!p){const m=localStorage.getItem("language");m&&(m==="zh"||m==="zh-TW")?window.open("https://pkmer.cn/products/UserProfile/#tab-21&activateSync","_blank"):window.open("https://thino.pkmer.net/en/","_blank");return}if(!r){h.setButtonText(E("Confirm?")),r=!0;return}r=!1,p&&(this.plugin.app?.saveLocalStorage("tokenForSync",""),new N.Notice(E("Remove successfully"))),Ze.setRefresh(!0),setTimeout(()=>{this.display()},20)})}),(i==="zh"||i==="zh-TW")&&this.showSyncStatus(n,t)}showSyncStatus(t,n){this.plugin.app?.loadLocalStorage("tokenForSync")&&(new Oe(t,this).setName(E("Save thino type when sync local")).setDesc(E("Set the default save thino type when sync local, FILE by default.")).setTab(n).addDropdown(async o=>{o.addOption("DAILY",E("DAILY")),o.addOption("FILE",E("FILE")),o.setValue(this.plugin.settings.saveThinoType).onChange(async i=>{this.plugin.settings.saveThinoType=i,this.applySettingsUpdate()})}),new Oe(t,this).setName(E("Sync Status")).setDesc(E("Start or stop sync")).setTab(n).addButton(o=>{o.setButtonText(this.plugin.settings.startSync?E("Stop"):E("Start")).onClick(async()=>{this.plugin.settings.startSync=!this.plugin.settings.startSync,await this.plugin.saveSettings(),Ze.setRefresh(!0),new N.Notice(this.plugin.settings.startSync?E("Start sync successfully"):E("Stop sync successfully")),setTimeout(()=>{this.display()},200)})}),new Oe(t,this).setName(E("Sync manually")).setTab(n).addToggle(o=>{o.setValue(this.plugin.settings.SyncManually).onChange(async i=>{this.plugin.settings.SyncManually=i,this.applySettingsUpdate()})}))}addMemoSettings(t,n){new Oe(n,this).setName(E("Open Memos when obsidian opens")).setDesc(E("When enable this, Memos will open when Obsidian opens. False by default.")).setTab(t).addDropdown(o=>{o.addOption("Desktop","Desktop"),o.addOption("Mobile","Mobile"),o.addOption("All","All"),o.setValue(this.plugin.settings.MobileAndDesktop).onChange(async i=>{this.plugin.settings.MobileAndDesktop=i,this.applySettingsUpdate()})}).addToggle(o=>o.setValue(this.plugin.settings.OpenMemosAutomatically).onChange(async i=>{this.plugin.settings.OpenMemosAutomatically=i,this.applySettingsUpdate()})),new Oe(n,this).setHeading().setTab(t).setName("📝 "+E("Editor")),new Oe(n,this).setName(E("Use Tags In Vault")).setDesc(E("Use tags in vault rather than only in Memos. False by default.")).setTab(t).addToggle(o=>o.setValue(this.plugin.settings.UseVaultTags).onChange(async i=>{this.plugin.settings.UseVaultTags=i,this.applySettingsUpdate()}));let r;new Oe(n,this).setName(E("Default insert date format")).setDesc(E("Set the default date format when insert date by @, 'Tasks' by default.")).setTab(t).addDropdown(async o=>{r=o,r.addOption("Tasks","Tasks"),r.addOption("Dataview","Dataview"),r.setValue(this.plugin.settings.InsertDateFormat).onChange(async i=>{this.plugin.settings.InsertDateFormat=i,this.applySettingsUpdate()})}),new Oe(n,this).setHeading().setTab(t).setName("📅 "+E("Daily notes")),new Oe(n,this).setName(E("Default prefix when save thino")).setDesc(E("Set the default prefix when create memo, 'List' by default.")).setTab(t).addDropdown(async o=>{r=o,r.addOption("List",E("List")),r.addOption("Task",E("Task")),r.setValue(this.plugin.settings.DefaultPrefix).onChange(async i=>{this.plugin.settings.DefaultPrefix=i,this.applySettingsUpdate()})}),this.plugin.settings.EnabledLocationList.some(o=>o.value==="DAILY")&&new Oe(n,this).setName(E("Default time prefix for thino in daily notes")).setDesc(E("Set default time prefix for thino in daily notes.")).setTab(t).addDropdown(async o=>{r=o,r.addOption("HH:mm","HH:mm"),r.addOption("HH:mm:ss","HH:mm:ss"),r.setValue(this.plugin.settings.DefaultTimePrefix).onChange(async i=>{this.plugin.settings.DefaultTimePrefix=i,this.applySettingsUpdate()})}),new Oe(n,this).setHeading().setTab(t).setName(E("Fixed strings for thinos")),new Oe(n,this).setName(E("Use fixed strings for thinos")).setDesc(E("Enable to add fixed strings at the beginning or end of thinos.")).setTab(t).addToggle(o=>o.setValue(this.plugin.settings.UseMemoFixedStrings).onChange(async i=>{this.plugin.settings.UseMemoFixedStrings=i,this.applySettingsUpdate()})),new Oe(n,this).setName(E("Fixed prefix for thinos")).setDesc(E("Add this string at the beginning of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.")).setTab(t).addText(o=>o.setValue(this.plugin.settings.MemoFixedPrefix).onChange(async i=>{this.plugin.settings.MemoFixedPrefix=i,this.applySettingsUpdate()})),new Oe(n,this).setName(E("Fixed suffix for thinos")).setDesc(E("Add this string at the end of each thino. Supports placeholders like {{TIME|YYYYMMDDHHmmss}}.")).setTab(t).addText(o=>o.setValue(this.plugin.settings.MemoFixedSuffix).onChange(async i=>{this.plugin.settings.MemoFixedSuffix=i,this.applySettingsUpdate()}))}addThinoProSettings(t,n,r){new Oe(n,this).setHeading().setTab(t).setName("💎 "+E("Pro features")),new Oe(n,this).setName(E("Default save type")).setDesc(E('Set the default save type for thino. "DAILY" by default')).setTab(t).addDropdown(async o=>{for(const i of this.plugin.settings.EnabledLocationList)o.addOption(i.value,E(i.value));o.setValue(this.plugin.settings.MemoSaveLocation||this.plugin.settings.EnabledLocationList[0].value).onChange(async i=>{if(!r){Nt();return}this.plugin.settings.MemoSaveLocation=i,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Support filter by metadata from file")).setDesc(E("When enable this, you can filter via metadata from file, like tags in file. But thinos from canvas is not supported. False by default.")).addToggle(o=>{o.setValue(this.plugin.settings.FilterByMetadata).onChange(async i=>{if(!r){Nt();return}this.plugin.settings.FilterByMetadata=i,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Show source near timestamp in thino")).setDesc(E("When enable this, you can see the source near timestamp in thino. You can set title in metadata to overwrite this. False by default.")).addToggle(o=>{o.setValue(this.plugin.settings.ShowSourcePath).onChange(async i=>{if(!r){Nt();return}this.plugin.settings.ShowSourcePath=i,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Add tag automatically")).setDesc(E("Add tag to the end or beginning of the thino content when creating a thino and filtering tags")).setTab(t).addToggle(o=>o.setValue(this.plugin.settings.addTagAutomatically).onChange(async i=>{if(!r){Nt();return}this.plugin.settings.addTagAutomatically=i,this.applySettingsUpdate(),this.debounceDisplay()})),this.plugin.settings.addTagAutomatically&&(new Oe(n,this).setName(E("Add tag position")).setDesc(E("Set the position of the tag when adding tag automatically")).setTab(t).addDropdown(async o=>{o.addOption("End",E("End")),o.addOption("Beginning",E("Beginning")),o.setValue(this.plugin.settings.addTagPosition).onChange(async i=>{this.plugin.settings.addTagPosition=i,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Add tag with new line")).setDesc(E("Add tag with new line when adding tag automatically")).setTab(t).addToggle(o=>o.setValue(this.plugin.settings.addTagWithNewline).onChange(async i=>{this.plugin.settings.addTagWithNewline=i,this.applySettingsUpdate()})))}memosCommentSettings(t,n){new Oe(n,this).setName(E("Allow Comments On Memos")).setDesc(E("You can comment on memos. False by default")).setTab(t).addToggle(r=>r.setValue(this.plugin.settings.CommentOnMemos).onChange(async o=>{this.plugin.settings.CommentOnMemos=o,this.applySettingsUpdate(),this.display()})),this.plugin.settings.CommentOnMemos&&(new Oe(n,this).setName(E("Always Show Memo Comments")).setDesc(E("Always show memo comments on memos. False by default")).setTab(t).addToggle(r=>r.setValue(this.plugin.settings.ShowCommentOnMemos).onChange(async o=>{this.plugin.settings.ShowCommentOnMemos=o,this.applySettingsUpdate()})),new Oe(n,this).setName(E("Comments In Original DailyNotes/Notes")).setDesc(E("You should install Dataview Plugin ver 0.5.9 or later to use this feature.")).setTab(t).addToggle(r=>r.setValue(this.plugin.settings.CommentsInOriginalNotes).onChange(async o=>{this.plugin.settings.CommentsInOriginalNotes=o,this.applySettingsUpdate()})))}shareToThinosSettings(t,n,r){new Oe(n,this).setHeading().setTab(t).setName("💎 "+E("Pro features")),new Oe(n,this).setTab(t).setName(E("Append/prepend text when share to Thino")).addToggle(o=>{o.setValue(this.plugin.settings.ShareToThinoWithText).onChange(async i=>{if(!r){Nt();return}this.plugin.settings.ShareToThinoWithText=i,this.applySettingsUpdate(),this.debounceDisplay()})}),this.plugin.settings.ShareToThinoWithText&&(new Oe(n,this).setTab(t).setName(E("Prepend Text Action")).addDropdown(o=>{o.addOption("none",E("None")),o.addOption("preset",E("Preset")),o.addOption("input",E("Input")),o.addOption("selectTags",E("Select Tags")),o.setValue(this.plugin.settings.SharePrependType).onChange(async i=>{this.plugin.settings.SharePrependType=i,this.applySettingsUpdate(),this.debounceDisplay()})}),this.plugin.settings.SharePrependType==="preset"&&new Oe(n,this).setTab(t).setName(E("Prepend text when share to Thino")).addText(o=>{o.setPlaceholder(E("Input anything here")).setValue(this.plugin.settings.ShareToThinoWithTextPrepend).onChange(async i=>{this.plugin.settings.ShareToThinoWithTextPrepend=i,this.applySettingsUpdate()})}),new Oe(n,this).setTab(t).setName(E("Append Text Action")).addDropdown(o=>{o.addOption("none",E("None")),o.addOption("preset",E("Preset")),o.addOption("input",E("Input")),o.addOption("selectTags",E("Select Tags")),o.setValue(this.plugin.settings.ShareAppendType).onChange(async i=>{this.plugin.settings.ShareAppendType=i,this.applySettingsUpdate(),this.debounceDisplay()})}),this.plugin.settings.ShareAppendType==="preset"&&new Oe(n,this).setTab(t).setName(E("Append text when share to Thino")).addText(o=>{o.setPlaceholder(E("Input anything here")).setValue(this.plugin.settings.ShareToThinoWithTextAppend).onChange(async i=>{this.plugin.settings.ShareToThinoWithTextAppend=i,this.applySettingsUpdate()})}),new Oe(n,this).setTab(t).setName(E("Add newline when append/prepend text")).addDropdown(async o=>{o.addOption("prepend",E("Prepend")),o.addOption("append",E("Append")),o.addOption("both",E("Both")),o.addOption("none",E("None")),o.setValue(this.plugin.settings.ShareToThinoWithTextNewline).onChange(async i=>{this.plugin.settings.ShareToThinoWithTextNewline=i,this.applySettingsUpdate()})}))}copyMemosSettings(t,n){new Oe(n,this).setName(E("Show Time When Copy Results")).setDesc(E("Show time when you copy results, like 12:00. Copy time by default.")).setTab(t).addToggle(r=>r.setValue(this.plugin.settings.ShowTime).onChange(async o=>{this.plugin.settings.ShowTime=o,this.applySettingsUpdate()})),new Oe(n,this).setName(E("Show Date When Copy Results")).setDesc(E("Show date when you copy results, like [[2022-01-01]]. Copy date by default.")).setTab(t).addToggle(r=>r.setValue(this.plugin.settings.ShowDate).onChange(async o=>{this.plugin.settings.ShowDate=o,this.applySettingsUpdate(),this.debounceDisplay()})),this.plugin.settings.ShowDate&&new Oe(n,this).setName(E("Add Blank Line Between Different Date")).setDesc(E("Add blank line when copy result with date. No blank line by default.")).setTab(t).addToggle(r=>r.setValue(this.plugin.settings.AddBlankLineWhenDate).onChange(async o=>{this.plugin.settings.AddBlankLineWhenDate=o,this.applySettingsUpdate()}))}shareMemosSettings(t,n){new Oe(n,this).setName(E("Custom height for Thino content")).setDesc(E("Set custom height for Thino content. Like 200px or 20rem")).setTab(t).addText(r=>r.setPlaceholder(E("Input height")).setValue(this.plugin.settings.MinHeightForShare).onChange(async o=>{this.plugin.settings.MinHeightForShare=o,this.debounceApplySettingsUpdate()})),this.customMemoFooter(t,n),new Oe(n,this).setName(E("Custom Background Image")).setDesc(E("Set custom background image.")).setTab(t).addToggle(r=>r.setValue(this.plugin.settings.SetCustomBackgroundImage).onChange(async o=>{this.plugin.settings.SetCustomBackgroundImage=o,this.applySettingsUpdate(),setTimeout(()=>{this.display()},100)})),this.plugin.settings.SetCustomBackgroundImage&&(new Oe(n,this).setName(E("Background Image in Light Theme")+` [${E("Modern")}]`).setDesc(E('Set background image in light theme. Set something like "Daily/one.png"')).setTab(t).addText(r=>{new pu(r.inputEl),r.setPlaceholder(ti.DefaultLightBackgroundImage).setValue(this.plugin.settings.DefaultLightBackgroundImage).onChange(async o=>{this.plugin.settings.DefaultLightBackgroundImage=o,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Background Image in Dark Theme")+` [${E("Modern")}]`).setDesc(E('Set background image in dark theme. Set something like "Daily/one.png"')).setTab(t).addText(r=>{new pu(r.inputEl),r.setPlaceholder(ti.DefaultDarkBackgroundImage).setValue(this.plugin.settings.DefaultDarkBackgroundImage).onChange(async o=>{this.plugin.settings.DefaultDarkBackgroundImage=o,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Background Image in Light Theme")+` [${E("Clean")}]`).setDesc(E('Set background image in light theme. Set something like "Daily/one.png"')).setTab(t).addText(r=>{new pu(r.inputEl),r.setPlaceholder(ti.DefaultLightBackgroundImageForClean).setValue(this.plugin.settings.DefaultLightBackgroundImageForClean).onChange(async o=>{this.plugin.settings.DefaultLightBackgroundImageForClean=o,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Background Image in Dark Theme")+` [${E("Clean")}]`).setDesc(E('Set background image in dark theme. Set something like "Daily/one.png"')).setTab(t).addText(r=>{new pu(r.inputEl),r.setPlaceholder(ti.DefaultDarkBackgroundImageForClean).setValue(this.plugin.settings.DefaultDarkBackgroundImageForClean).onChange(async o=>{this.plugin.settings.DefaultDarkBackgroundImageForClean=o,this.applySettingsUpdate()})}))}customMemoFooter(t,n){new Oe(n,this).setName(E("Custom Memo Footer")).setDesc(E("Set custom memo footer.")).setTab(t).addToggle(r=>r.setValue(this.plugin.settings.SetCustomMemoFooter).onChange(async o=>{this.plugin.settings.SetCustomMemoFooter=o,this.applySettingsUpdate(),setTimeout(()=>{this.display()},100)})),this.plugin.settings.SetCustomMemoFooter&&new Oe(n,this).setName(E("Share Memos Image Footer Start")).setDesc(E("Set anything you want here, use {ThinoNum} to display Number of thino, {UsedDay} for days. '{ThinoNum} Thino {UsedDay} Days' By default")).setTab(t).addText(r=>r.setPlaceholder(ti.ShareFooterStart).setValue(this.plugin.settings.ShareFooterStart).onChange(async o=>{this.plugin.settings.ShareFooterStart=o,this.applySettingsUpdate()}))}saveDataSettings(t,n){let r;new Oe(n,this).setName(E("Focus on editor when open")).setDesc(E("Focus on editor when open. True by default.")).setTab(t).addToggle(o=>{o.setValue(this.plugin.settings.FocusOnEditor).onChange(async i=>{this.plugin.settings.FocusOnEditor=i,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Default Editor Mode")).setDesc(E("Live-Preview Mode OR Source Mode.")).setTab(t).addDropdown(async o=>{r=o,r.addOption("obsidian",E("Live-preview")),r.addOption("memos",E("Source")),r.setValue(this.plugin.settings.EditorType).onChange(async i=>{this.plugin.settings.EditorType=i,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Delete Thino Directly")).setDesc(E("When delete thino directly, it will not be moved to trash. False by default.")).setTab(t).addToggle(o=>{o.setValue(this.plugin.settings.DeleteThinoDirectly).onChange(async i=>{this.plugin.settings.DeleteThinoDirectly=i,this.applySettingsUpdate()})})}async initHttpServer(t,n){const r=$e.getState().verifyState,o=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device.getId(),i=N.Platform.isDesktop?await Sn():o.identifier||o.uuid,a=r&&r?.appId===i;new Oe(t,this).setName(E("Enable Local Http Server")).setTab(n).setDisabled(!a).addToggle(s=>s.setValue(this.plugin.settings.EnabledHttpApi).onChange(async l=>{if(!a){Nt();return}this.plugin.settings.EnabledHttpApi=l,this.applySettingsUpdate(),setTimeout(()=>{this.plugin.settings.EnabledHttpApi?this.plugin.initServer():this.plugin.stopServer(),this.display()},100)})),this.plugin.settings.EnabledHttpApi&&(new Oe(t,this).setName(E("Get thino capture extension")).setDesc(E("You can capture idea/text from chrome now.")).setTab(n).addButton(s=>{s.setButtonText("GitHub").onClick(()=>{window.open("https://github.com/quorafind/thino-capture-releases","_blank")})}).addButton(s=>{s.setButtonText("Chrome Web Store").onClick(()=>{window.open("https://chromewebstore.google.com/detail/thino-capture/oppagjehiimpjpjmgbfmanlnbpbcecff","_blank")})}),new Oe(t,this).setName(E("Memos Http Server Port")).setDesc(E("Set memos http server port to listen. '43999' by default")).setTab(n).addText(s=>s.setPlaceholder(ti.HttpApiPort).setValue(this.plugin.settings.HttpApiPort).onChange(async l=>{if(!a){Nt();return}this.plugin.settings.HttpApiPort=l,this.applySettingsUpdate(),setTimeout(()=>{this.plugin.stopServer(),this.plugin.initServer()},1e3)})),new Oe(t,this).setName(E("Auto Download Image")).setDesc(E("Auto download image when save to thino. 'false' by default")).setTab(n).setDisabled(!a).addToggle(s=>{s.setValue(this.plugin.settings.AutoDownloadImage).onChange(async l=>{if(!a){Nt();return}this.plugin.settings.AutoDownloadImage=l,this.applySettingsUpdate(),setTimeout(()=>{this.plugin.stopServer(),this.plugin.initServer()},1e3)})}),new Oe(t,this).setName(E("Thino Http IP Type")).setDesc(E("Set Thino http server ip to listen. 'localhost' by default")).setTab(n).addDropdown(s=>{s.addOption("localhost","localhost"),s.addOption("127.0.0.1","127.0.0.1"),s.setValue(this.plugin.settings.HttpApiIpType).onChange(async l=>{if(!r||r?.appId!==i){Nt();return}this.plugin.settings.HttpApiIpType=l,this.applySettingsUpdate(),setTimeout(()=>{this.plugin.stopServer(),this.plugin.initServer()},1e3)})}),this.appendOrPrependTextSettings(n,t,a))}appendOrPrependTextSettings(t,n,r){new Oe(n,this).setTab(t).setName(E("Append/prepend text when share to Thino")).addToggle(o=>{o.setValue(this.plugin.settings.AppendOrPrependTextViaServer).onChange(async i=>{if(!r){Nt();return}this.plugin.settings.AppendOrPrependTextViaServer=i,this.applySettingsUpdate(),this.debounceDisplay()})}),this.plugin.settings.AppendOrPrependTextViaServer&&(new Oe(n,this).setName(E("Prepend Text")).setTab(t).addText(o=>{o.setPlaceholder(E("Input anything here")).setValue(this.plugin.settings.PrependViaServer).onChange(async i=>{this.plugin.settings.PrependViaServer=i,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Append Text")).setTab(t).addText(o=>{o.setPlaceholder(E("Input anything here")).setValue(this.plugin.settings.AppendViaServer).onChange(async i=>{this.plugin.settings.AppendViaServer=i,this.applySettingsUpdate()})}),new Oe(n,this).setName(E("Add newline when append/prepend text")).addDropdown(async o=>{o.addOption("prepend",E("Prepend")),o.addOption("append",E("Append")),o.addOption("both",E("Both")),o.addOption("none",E("None")),o.setValue(this.plugin.settings.WithNewLineViaServer).onChange(async i=>{this.plugin.settings.WithNewLineViaServer=i,this.applySettingsUpdate()})}))}fetchDataSettings(t,n){let r;new Oe(n,this).setName(E("Use which plugin's default configuration")).setDesc(E("Memos use the plugin's default configuration to fetch memos from daily, 'Daily' by default.")).setTab(t).addDropdown(async o=>{r=o,r.addOption("Daily",E("Daily")),r.addOption("Periodic","Periodic").setDisabled(!this.app.plugins.getPlugin("periodic-notes")),r.setValue(this.plugin.settings.UseDailyOrPeriodic).onChange(async i=>{this.plugin.settings.UseDailyOrPeriodic=i,this.applySettingsUpdate()})}).addExtraButton(o=>{o.setIcon("settings").onClick(()=>{if(this.plugin.settings.UseDailyOrPeriodic==="Daily"){if(!this.app.internalPlugins.plugins["daily-notes"]||!this.app.internalPlugins.plugins["daily-notes"].enabled){new N.Notice("Daily Notes plugin is not installed");return}this.app.setting.open(),this.app.setting.openTabById("daily-notes")}else{if(!this.app.plugins.getPlugin("periodic-notes")||!this.app.plugins.getPlugin("periodic-notes")._loaded){new N.Notice("Periodic Notes plugin is not installed");return}this.app.setting.open(),this.app.setting.openTabById("periodic-notes")}})})}navigationSettings(t,n){new Oe(n,this).setName(E("Open link directly in Thino view")).setTab(t).addToggle(r=>r.setValue(this.plugin.settings.navigation).onChange(async o=>{this.plugin.settings.navigation=o,this.applySettingsUpdate()}))}optimizeForCalloutSettings(t,n){new Oe(n,this).setName(E("Optimize for Callout")).setDesc(E("Won't render content contains more than 3 callouts automatically. True by default")).setTab(t).addToggle(r=>r.setValue(this.plugin.settings.OptimizeForCallout).onChange(async o=>{this.plugin.settings.OptimizeForCallout=o,this.applySettingsUpdate()}))}addUpdateMessageSettings(t,n){new Oe(n,this).setName(E("Show Update Message")).setDesc(E("Show update message when Thino is updated. True by default")).setTab(t).addToggle(r=>r.setValue(this.plugin.settings.ShowUpdateMessage).onChange(async o=>{this.plugin.settings.ShowUpdateMessage=o,this.applySettingsUpdate()}))}clearConfigSettings(t,n){new Oe(n,this).setName(E("Reset all Thino settings")).setDesc(E("Reset Thino settings to default settings.")).setTab(t).addButton(r=>{r.setWarning().setButtonText(E("Reset settings")).onClick(async()=>{new da(this.app,E("Reset all Thino settings"),async()=>{this.plugin.settings={...ti,tokenForVerify:this.plugin.settings.tokenForVerify,password:this.plugin.settings.password,needVerify:this.plugin.settings.needVerify},this.debounceApplySettingsUpdate(),await de.fetchAllMemos(),de.updateTagsState(),this.plugin.app?.saveLocalStorage("tokenForSync",""),Ze.setRefresh(!0),Ze.setMemoListView("list"),new N.Notice(E("All settings have been reset to default.")),this.debounceDisplay()}).open()})})}setPasswordSettings(t,n){new Oe(n,this).setName(E("Need password to unlock Thino")).setTab(t).addToggle(r=>{this.plugin.settings.needVerify&&this.plugin.settings.password&&!this.passwordMatched&&(r.toggleEl.onclick=o=>{this.passwordMatched||(o.preventDefault(),new Q6(this.app,this,this.plugin,i=>{r.setDisabled(!i),this.passwordMatched=i,this.debounceDisplay()}).open(),new N.Notice(E("Please input your password to change password settings")))}),r.setDisabled(this.plugin.settings.needVerify&&this.plugin.settings.password&&!this.passwordMatched).setValue(this.plugin.settings.needVerify).onChange(async o=>{this.plugin.settings.needVerify=o,o&&(this.passwordMatched=!1),this.applySettingsUpdate(),this.debounceDisplay()})}),this.plugin.settings.needVerify&&new Oe(n,this).setName(E("Password to lock Thino")).setTab(t).addText(r=>{this.plugin.settings.needVerify&&this.plugin.settings.password&&!this.passwordMatched&&(r.inputEl.onclick=o=>{this.passwordMatched||(o.preventDefault(),new Q6(this.app,this,this.plugin,i=>{r.inputEl.readOnly=!i,this.passwordMatched=i,this.debounceDisplay()}).open(),new N.Notice(E("Please input your password to change password settings")))}),r.inputEl.readOnly=this.plugin.settings.password&&this.plugin.settings.needVerify&&!this.passwordMatched,r.inputEl.oncopy=()=>!1,r.inputEl.type="password",r.setValue(this.plugin.settings.password).onChange(async o=>{this.plugin.settings.password=o,this.applySettingsUpdate()})})}setGlobalSettings(t,n,r){new Oe(n,this).setHeading().setTab(t).setName("💎 "+E("Pro features")),this.initHttpServer(n,t),new Oe(n,this).setName(E("Enable opening thino globally")).setDesc(E("Enable opening thino globally. False by default.")).setTab(t).addToggle(o=>o.setValue(this.plugin.settings.CaptureKey.EnableCaptureKey).onChange(async i=>{if(!r){Nt();return}this.plugin.settings.CaptureKey.EnableCaptureKey=i,this.applySettingsUpdate(),setTimeout(()=>{this.display()},100)})),this.plugin.settings.CaptureKey.EnableCaptureKey&&(new Oe(n,this).setName(E("Key for opening thino globally")).setDesc(E("Set key for opening thino globally. CTRL + SHIFT + T by default.")).setTab(t).addText(o=>o.setPlaceholder(ti.CaptureKey.OpenThinoGlobally).setValue(this.plugin.settings.CaptureKey.OpenThinoGlobally).onChange(async i=>{if(!r){Nt();return}this.plugin.settings.CaptureKey.OpenThinoGlobally=i,this.applySettingsUpdate()})),new Oe(n,this).setName(E("Show thino near mouse")).setTab(t).addToggle(o=>o.setValue(this.plugin.settings.CaptureKey.ShowNearMouse).onChange(async i=>{if(!r){Nt();return}this.plugin.settings.CaptureKey.ShowNearMouse=i,this.applySettingsUpdate()})))}checkInList(t){return this.plugin.settings.EnabledLocationList.find(n=>n.value===t)!==void 0}customFileNameSettings(t,n,r){const o=document.createDocumentFragment(),i=o.createEl("div",{cls:"memo-save-location-desc"});for(const s of NJe){const l=i.createEl("div",{cls:`memo-save-location-desc-item ${s.value}`}),u=l.createEl("span",{cls:"memo-save-location-desc-item-icon"});N.setIcon(u,Pm.find(b=>b.title===s.value)?.icon||""),l.createEl("span",{cls:"memo-save-location-desc-item-desc",text:`${E(s.value)}`});const d=l.createEl("span",{cls:"memo-save-location-desc-item-toggle"}),h=l.createEl("span",{cls:"memo-save-location-desc-item-setting"});s.value!=="DAILY"&&l.createEl("span",{cls:["memo-save-location-desc-item-pro","user-pro-badge"],text:"PRO"}),new N.ToggleComponent(d).setValue(this.checkInList(s.value)).onChange(async b=>{if(!r){Nt();return}b?(await de.updateTypeMemos(s.value),this.plugin.settings.EnabledLocationList=[...this.plugin.settings.EnabledLocationList,s]):(await de.removeTypeMemos(s.value),this.plugin.settings.EnabledLocationList=this.plugin.settings.EnabledLocationList.filter(v=>v.value!==s.value)),this.plugin.settings.EnabledLocationList.length===1&&(this.plugin.settings.MemoSaveLocation=s.value),this.applySettingsUpdate(),setTimeout(()=>{this.display()},500)}).setDisabled(this.plugin.settings.EnabledLocationList.length===1&&this.checkInList(s.value)),new N.ExtraButtonComponent(h).setIcon("settings").onClick(()=>{new MJe(this.app,this,this.plugin,s,r).open()})}const a=new Oe(n,this).setName(E("Save type for Thino")).setDesc(o).setTab(t);a.settingEl.toggleClass("memo-save-location-setting",!0),a.nameEl.toggleClass("memo-save-location-title",!0)}addScrollToTopSettings(t,n){new Oe(n,this).setName(E("Show scroll to top button")).setDesc(E("Show scroll to top button. True by default")).setTab(t).addToggle(r=>{r.setValue(this.plugin.settings.ShowScrollToTopButton).onChange(async o=>{this.plugin.settings.ShowScrollToTopButton=o,this.applySettingsUpdate()})})}addRememberImageSettings(t,n){new Oe(n,this).setName(E("Zoom image by default")).setDesc(E("Zoom image by default when viewing image.")).setTab(t).addToggle(r=>{r.setValue(this.plugin.settings.ZoomImageWhenViewing).onChange(async o=>{this.plugin.settings.ZoomImageWhenViewing=o,this.applySettingsUpdate()})})}addViewArchiveInRandomReviewSettings(t,n){new Oe(n,this).setName(E("View archive in random review")).setDesc(E("View archived thinos in random review. True by default")).setTab(t).addToggle(r=>{r.setValue(this.plugin.settings.ViewArchiveInRandomReview).onChange(async o=>{this.plugin.settings.ViewArchiveInRandomReview=o,this.applySettingsUpdate()})})}addTaskRelatedSettings(t,n){new Oe(n,this).setHeading().setName("📃 "+E("Task Management")),new Oe(n,this).setName(E("Show Tasks Label")).setDesc(E("Show tasks label near the time text. False by default")).setTab(t).addToggle(r=>r.setValue(this.plugin.settings.ShowTaskLabel).onChange(async o=>{this.plugin.settings.ShowTaskLabel=o,this.applySettingsUpdate()})),new Oe(n,this).setName(E("Append completed date when task done in thino")).setDesc(E("Append completed date when task done in thino. False by default")).setTab(t).addToggle(r=>r.setValue(this.plugin.settings.AppendDateWhenTaskDone).onChange(async o=>{this.plugin.settings.AppendDateWhenTaskDone=o,this.applySettingsUpdate()}))}}class Q6 extends N.Modal{constructor(t,n,r,o){super(t),this.cb=o,this.app=t,this.settingTab=n,this.plugin=r}plugin;settingTab;onOpen(){const{contentEl:t}=this;t.parentElement?.classList.add("memo-save-location-modal"),this.titleEl.toggleClass("modal-title",!0),this.titleEl.setText(E("Password for Thino")),t.createDiv("modal-desc",s=>{s.setText(E("Please input your password to change password settings"))});const n=t.createDiv("modal-setting"),r=new Oe(n,this.settingTab).setName(E("Password")).addText(s=>{s.setPlaceholder(E("Please input your password")).inputEl.type="password"}),o=t.createDiv("button-group"),i=o.createEl("button",{text:E("Cancel")}),a=o.createEl("button",{cls:"thino-password-confirm-btn",text:E("Confirm?").replace(/(\?|?)/g,"")});a.onclick=async()=>{r.controlEl.querySelector("input").value===this.plugin.settings.password?(this.cb?.(!0),this.close()):new N.Notice(E("Password is incorrect"))},i.onclick=async()=>{this.close()}}onClose(){const{contentEl:t}=this;t.empty()}}function e1(e){return e.split("-")[0]}function $G(e){return e.split("-")[1]}function IN(e){return["top","bottom"].includes(e1(e))?"x":"y"}function qG(e){return e==="y"?"height":"width"}function e8(e){let{reference:t,floating:n,placement:r}=e;const o=t.x+t.width/2-n.width/2,i=t.y+t.height/2-n.height/2;let a;switch(e1(r)){case"top":a={x:o,y:t.y-n.height};break;case"bottom":a={x:o,y:t.y+t.height};break;case"right":a={x:t.x+t.width,y:i};break;case"left":a={x:t.x-n.width,y:i};break;default:a={x:t.x,y:t.y}}const s=IN(r),l=qG(s);switch($G(r)){case"start":a[s]=a[s]-(t[l]/2-n[l]/2);break;case"end":a[s]=a[s]+(t[l]/2-n[l]/2);break}return a}const jJe=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:a}=n;let s=await a.getElementRects({reference:e,floating:t,strategy:o}),{x:l,y:u}=e8({...s,placement:r}),d=r,h={};for(let p=0;p<i.length;p++){const{name:m,fn:b}=i[p],{x:v,y,data:S,reset:x}=await b({x:l,y:u,initialPlacement:r,placement:d,strategy:o,middlewareData:h,rects:s,platform:a,elements:{reference:e,floating:t}});if(l=v??l,u=y??u,h={...h,[m]:S??{}},x){typeof x=="object"&&(x.placement&&(d=x.placement),x.rects&&(s=x.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:o}):x.rects),{x:l,y:u}=e8({...s,placement:d})),p=-1;continue}}return{x:l,y:u,placement:d,strategy:o,middlewareData:h}};function LJe(e){return{top:0,right:0,bottom:0,left:0,...e}}function RJe(e){return typeof e!="number"?LJe(e):{top:e,right:e,bottom:e,left:e}}function HM(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}async function _M(e,t){t===void 0&&(t={});const{x:n,y:r,platform:o,rects:i,elements:a,strategy:s}=e,{boundary:l="clippingParents",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:h=!1,padding:p=0}=t,m=RJe(p),v=a[h?d==="floating"?"reference":"floating":d],y=await o.getClippingClientRect({element:await o.isElement(v)?v:v.contextElement||await o.getDocumentElement({element:a.floating}),boundary:l,rootBoundary:u}),S=HM(await o.convertOffsetParentRelativeRectToViewportRelativeRect({rect:d==="floating"?{...i.floating,x:n,y:r}:i.reference,offsetParent:await o.getOffsetParent({element:a.floating}),strategy:s}));return{top:y.top-S.top+m.top,bottom:S.bottom-y.bottom+m.bottom,left:y.left-S.left+m.left,right:S.right-y.right+m.right}}const FJe={left:"right",right:"left",bottom:"top",top:"bottom"};function iS(e){return e.replace(/left|right|bottom|top/g,t=>FJe[t])}function HJe(e,t){const n=$G(e)==="start",r=IN(e),o=qG(r);let i=r==="x"?n?"right":"left":n?"bottom":"top";return t.reference[o]>t.floating[o]&&(i=iS(i)),{main:i,cross:iS(i)}}const _Je={start:"end",end:"start"};function t8(e){return e.replace(/start|end/g,t=>_Je[t])}function BJe(e){const t=iS(e);return[t8(e),t,t8(t)]}const YJe=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:i,rects:a,initialPlacement:s}=t;if((n=i.flip)!=null&&n.skip)return{};const{mainAxis:l=!0,crossAxis:u=!0,fallbackPlacements:d,fallbackStrategy:h="bestFit",flipAlignment:p=!0,...m}=e,b=e1(o),y=d||(b===s||!p?[iS(s)]:BJe(s)),S=[s,...y],x=await _M(t,m),C=[];let k=((r=i.flip)==null?void 0:r.overflows)||[];if(l&&C.push(x[b]),u){const{main:R,cross:L}=HJe(o,a);C.push(x[R],x[L])}if(k=[...k,{placement:o,overflows:C}],!C.every(R=>R<=0)){var M,I;const R=((M=(I=i.flip)==null?void 0:I.index)!=null?M:0)+1,L=S[R];if(L)return{data:{index:R,overflows:k},reset:{placement:L}};let B="bottom";switch(h){case"bestFit":{var O;const _=(O=k.slice().sort((H,U)=>H.overflows.filter(G=>G>0).reduce((G,K)=>G+K,0)-U.overflows.filter(G=>G>0).reduce((G,K)=>G+K,0))[0])==null?void 0:O.placement;_&&(B=_);break}case"initialPlacement":B=s;break}return{data:{skip:!0},reset:{placement:B}}}return{}}}};function UJe(e){let{placement:t,rects:n,value:r}=e;const o=e1(t),i=["left","top"].includes(o)?-1:1,a=typeof r=="function"?r({...n,placement:t}):r,{mainAxis:s,crossAxis:l}=typeof a=="number"?{mainAxis:a,crossAxis:0}:{mainAxis:0,crossAxis:0,...a};return IN(o)==="x"?{x:l,y:s*i}:{x:s*i,y:l}}const zJe=function(e){return e===void 0&&(e=0),{name:"offset",options:e,fn(t){const{x:n,y:r,placement:o,rects:i}=t,a=UJe({placement:o,rects:i,value:e});return{x:n+a.x,y:r+a.y,data:a}}}};function kN(e){return e?.toString()==="[object Window]"}function Pc(e){if(e==null)return window;if(!kN(e)){const t=e.ownerDocument;return t&&t.defaultView||window}return e}function t1(e){return Pc(e).getComputedStyle(e)}function Tl(e){return kN(e)?"":e?(e.nodeName||"").toLowerCase():""}function xl(e){return e instanceof Pc(e).HTMLElement}function aS(e){return e instanceof Pc(e).Element}function VJe(e){return e instanceof Pc(e).Node}function KG(e){const t=Pc(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function n1(e){const{overflow:t,overflowX:n,overflowY:r}=t1(e);return/auto|scroll|overlay|hidden/.test(t+r+n)}function WJe(e){return["table","td","th"].includes(Tl(e))}function XG(e){const t=navigator.userAgent.toLowerCase().includes("firefox"),n=t1(e);return n.transform!=="none"||n.perspective!=="none"||n.contain==="paint"||["transform","perspective"].includes(n.willChange)||t&&n.willChange==="filter"||t&&(n.filter?n.filter!=="none":!1)}const n8=Math.min,Am=Math.max,sS=Math.round;function ch(e,t){t===void 0&&(t=!1);const n=e.getBoundingClientRect();let r=1,o=1;return t&&xl(e)&&(r=e.offsetWidth>0&&sS(n.width)/e.offsetWidth||1,o=e.offsetHeight>0&&sS(n.height)/e.offsetHeight||1),{width:n.width/r,height:n.height/o,top:n.top/o,right:n.right/r,bottom:n.bottom/o,left:n.left/r,x:n.left/r,y:n.top/o}}function jc(e){return((VJe(e)?e.ownerDocument:e.document)||window.document).documentElement}function r1(e){return kN(e)?{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}:{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function JG(e){return ch(jc(e)).left+r1(e).scrollLeft}function GJe(e){const t=ch(e);return sS(t.width)!==e.offsetWidth||sS(t.height)!==e.offsetHeight}function ZJe(e,t,n){const r=xl(t),o=jc(t),i=ch(e,r&&GJe(t));let a={scrollLeft:0,scrollTop:0};const s={x:0,y:0};if(r||!r&&n!=="fixed")if((Tl(t)!=="body"||n1(o))&&(a=r1(t)),xl(t)){const l=ch(t,!0);s.x=l.x+t.clientLeft,s.y=l.y+t.clientTop}else o&&(s.x=JG(o));return{x:i.left+a.scrollLeft-s.x,y:i.top+a.scrollTop-s.y,width:i.width,height:i.height}}function o1(e){return Tl(e)==="html"?e:e.assignedSlot||e.parentNode||(KG(e)?e.host:null)||jc(e)}function r8(e){return!xl(e)||getComputedStyle(e).position==="fixed"?null:e.offsetParent}function $Je(e){let t=o1(e);for(;xl(t)&&!["html","body"].includes(Tl(t));){if(XG(t))return t;t=t.parentNode}return null}function BM(e){const t=Pc(e);let n=r8(e);for(;n&&WJe(n)&&getComputedStyle(n).position==="static";)n=r8(n);return n&&(Tl(n)==="html"||Tl(n)==="body"&&getComputedStyle(n).position==="static"&&!XG(n))?t:n||$Je(e)||t}function o8(e){return{width:e.offsetWidth,height:e.offsetHeight}}function qJe(e){let{rect:t,offsetParent:n,strategy:r}=e;const o=xl(n),i=jc(n);if(n===i)return t;let a={scrollLeft:0,scrollTop:0};const s={x:0,y:0};if((o||!o&&r!=="fixed")&&((Tl(n)!=="body"||n1(i))&&(a=r1(n)),xl(n))){const l=ch(n,!0);s.x=l.x+n.clientLeft,s.y=l.y+n.clientTop}return{...t,x:t.x-a.scrollLeft+s.x,y:t.y-a.scrollTop+s.y}}function KJe(e){const t=Pc(e),n=jc(e),r=t.visualViewport;let o=n.clientWidth,i=n.clientHeight,a=0,s=0;return r&&(o=r.width,i=r.height,Math.abs(t.innerWidth/r.scale-r.width)<.01&&(a=r.offsetLeft,s=r.offsetTop)),{width:o,height:i,x:a,y:s}}function XJe(e){var t;const n=jc(e),r=r1(e),o=(t=e.ownerDocument)==null?void 0:t.body,i=Am(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),a=Am(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0);let s=-r.scrollLeft+JG(e);const l=-r.scrollTop;return t1(o||n).direction==="rtl"&&(s+=Am(n.clientWidth,o?o.clientWidth:0)-i),{width:i,height:a,x:s,y:l}}function QG(e){return["html","body","#document"].includes(Tl(e))?e.ownerDocument.body:xl(e)&&n1(e)?e:QG(o1(e))}function eZ(e,t){var n;t===void 0&&(t=[]);const r=QG(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),i=Pc(r),a=o?[i].concat(i.visualViewport||[],n1(r)?r:[]):r,s=t.concat(a);return o?s:s.concat(eZ(o1(a)))}function JJe(e,t){const n=t.getRootNode==null?void 0:t.getRootNode();if(e.contains(t))return!0;if(n&&KG(n)){let r=t;do{if(r&&e===r)return!0;r=r.parentNode||r.host}while(r)}return!1}function QJe(e){const t=ch(e),n=t.top+e.clientTop,r=t.left+e.clientLeft;return{top:n,left:r,x:r,y:n,right:r+e.clientWidth,bottom:n+e.clientHeight,width:e.clientWidth,height:e.clientHeight}}function i8(e,t){return t==="viewport"?HM(KJe(e)):aS(t)?QJe(t):HM(XJe(jc(e)))}function eQe(e){const t=eZ(o1(e)),r=["absolute","fixed"].includes(t1(e).position)&&xl(e)?BM(e):e;return aS(r)?t.filter(o=>aS(o)&&JJe(o,r)&&Tl(o)!=="body"):[]}function tQe(e){let{element:t,boundary:n,rootBoundary:r}=e;const i=[...n==="clippingParents"?eQe(t):[].concat(n),r],a=i[0],s=i.reduce((l,u)=>{const d=i8(t,u);return l.top=Am(d.top,l.top),l.right=n8(d.right,l.right),l.bottom=n8(d.bottom,l.bottom),l.left=Am(d.left,l.left),l},i8(t,a));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}const nQe={getElementRects:e=>{let{reference:t,floating:n,strategy:r}=e;return{reference:ZJe(t,BM(n),r),floating:{...o8(n),x:0,y:0}}},convertOffsetParentRelativeRectToViewportRelativeRect:e=>qJe(e),getOffsetParent:e=>{let{element:t}=e;return BM(t)},isElement:e=>aS(e),getDocumentElement:e=>{let{element:t}=e;return jc(t)},getClippingClientRect:e=>tQe(e),getDimensions:e=>{let{element:t}=e;return o8(t)},getClientRects:e=>{let{element:t}=e;return t.getClientRects()}},rQe=(e,t,n)=>jJe(e,t,{platform:nQe,...n});var oQe=function e(t,n){if(t===n)return!0;if(t&&n&&typeof t=="object"&&typeof n=="object"){if(t.constructor!==n.constructor)return!1;var r,o,i;if(Array.isArray(t)){if(r=t.length,r!=n.length)return!1;for(o=r;o--!==0;)if(!e(t[o],n[o]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if(i=Object.keys(t),r=i.length,r!==Object.keys(n).length)return!1;for(o=r;o--!==0;)if(!Object.prototype.hasOwnProperty.call(n,i[o]))return!1;for(o=r;o--!==0;){var a=i[o];if(!e(t[a],n[a]))return!1}return!0}return t!==t&&n!==n};const iQe=tt(oQe),Yk=Nm.Facet.define({combine:e=>({defaultPlacement:e.find(t=>t.defaultPlacement)?.defaultPlacement||"top",padding:e.find(t=>t.padding)?.padding||8})}),tZ=e=>e.split("-")[0],aQe=e=>e==="x"?"y":"x",sQe=e=>["top","bottom"].includes(tZ(e))?"x":"y",Qp=(e,t,n)=>Math.max(e,Math.min(t,n)),lQe=(e,t)=>Object.fromEntries(Object.entries(e).map(([n,r],o)=>[n,t(r,n,o)])),cQe=e=>e===void 0?e:typeof e=="number"?-e:lQe(e,t=>t!==void 0?-t:t),uQe=(e={})=>({name:"shift",fn:async t=>{const{x:n,y:r,placement:o}=t,{mainAxis:i=!0,crossAxis:a=!1,limiter:s=({x:y,y:S})=>({x:y,y:S}),editorMenu:l,...u}=e,d={x:n,y:r},h=await _M(t,u),p=sQe(tZ(o)),m=aQe(p);let b=d[p],v=d[m];if(i){const y=p==="y"?"top":"left",S=p==="y"?"bottom":"right",x=b+h[y],C=b-h[S];if(l){const k=await _M(t,{...u,boundary:l.dom,padding:cQe(u.padding)});if((m==="y"?["top","bottom"]:["left","right"]).every(I=>k[I]<=0)){const I=t.rects.floating.width,O=b+k[y]-I,R=b-k[S]+I,L=Math.abs(h[y]-k[y]),B=Math.abs(h[S]-k[S]);L>=I||B<L?b=Qp(x,b,O):b=Qp(R,b,C)}else b=Qp(x,b,C)}else b=Qp(x,b,C)}if(a){const y=m==="y"?"top":"left",S=m==="y"?"bottom":"right",x=v+h[y],C=v-h[S];v=Qp(x,v,C)}return s({...t,[p]:b,[m]:v})}}),dQe="thino-mini-toolbar",fQe=(e=0,t=0)=>({width:0,height:0,top:t,left:e,bottom:t,right:e,x:e,y:t}),hQe=(e,t)=>{if(!e)return null;const n=Math.min(e.left,t?.left??e.left),r=Math.max(e.right,t?.right??e.right),o=Math.max(e.bottom,t?.bottom??e.bottom)-Math.min(e.top,t?.top??e.top),i=Math.min(e.top,t?.top??e.top),a=i+o,s={left:n,right:r,top:i,bottom:a,width:0,height:o,x:i,y:n};return t&&(s.width=Math.abs(r-n)),s},pQe=fQe();class mQe{constructor(t){this.view=t,this.containerEl=this.view.dom.parentElement,this.defaultPlacement=this.view.state.facet(Yk).defaultPlacement,this.tooltipInfo=t.state.facet(YM),this.virtualEl={rect:pQe,getBoundingClientRect(){return this.rect}},this.maybeMeasure(),this.editorMenu={currMenu:null,evtRef:t.state.field(N.editorInfoField)},this.isThinoView=this.checkThinoView()}containerEl;virtualEl;toolbar=null;isThinoView;get workspace(){return this.view.state.field(N.editorInfoField).app.workspace}tooltipInfo;inView=!0;defaultPlacement;editorMenu;checkThinoView(){return this.view.state.field(N.editorInfoField)?this.view.state.field(N.editorInfoField)&&this.view.state.field(N.editorInfoField)?.getViewType?.()==="thino_view":!1}shouldRemoveToolbar(t){return!((t??this.tooltipInfo)?.end||this.editorMenu.currMenu)}onEditorMenuOpen(t){this.editorMenu.currMenu||(this.editorMenu.currMenu=t,this.cachedRefRect?this.computePosition(this.cachedRefRect):this.maybeMeasure(),!N.Platform.isMacOS&&this.tooltipInfo&&(this.createToolbar(),this.maybeMeasure()))}onEditorMenuClose(t){this.editorMenu.currMenu===t&&(this.editorMenu.currMenu=null),!N.Platform.isMacOS&&this.toolbar&&this.shouldRemoveToolbar()&&this.removeToolbar()}createToolbar(t){const n=t??this.tooltipInfo;if(!n)return;this.removeToolbar();const r=n.create(this.containerEl),o=this.view.state.field(N.editorInfoField);if(!o||!o?.editor)return;const i=o.editor.offsetToPos(n.start),a=n.end?o.editor.offsetToPos(n.end):i;this.workspace.trigger(dQe,r,{from:i,to:a},o.editor,o),this.toolbar=r}removeToolbar(){this.toolbar&&(this.toolbar.hide(),this.toolbar=null)}update(t){if(!this.isThinoView)return;const n=t.state.facet(YM),r=n!==this.tooltipInfo&&!iQe(n,this.tooltipInfo);r&&(this.tooltipInfo=n,this.shouldRemoveToolbar()?this.removeToolbar():n&&!this.toolbar&&this.createToolbar(n));const o=r||t.geometryChanged,i=t.state.facet(Yk);i.defaultPlacement!=this.defaultPlacement&&(i.defaultPlacement=this.defaultPlacement),o&&this.maybeMeasure()}destroy(){this.editorMenu.currMenu=null,this.removeToolbar(),this.toolbar=null,this.view.state.field(N.editorInfoField).app.workspace.offref(this.editorMenu.evtRef)}cachedRefRect=null;readFromDOM=()=>{if(this.tooltipInfo){const{start:t}=this.tooltipInfo;let{end:n}=this.tooltipInfo;n&&t===n&&(n=void 0);const r=this.view.coordsAtPos(t);let o=n?this.view.coordsAtPos(n):null;if(r&&o&&r.top!==o.top){const a=this.view.contentDOM.getBoundingClientRect();o={left:a.right,right:a.right,top:r.top,bottom:r.bottom}}const i=hQe(r,o);i&&(this.cachedRefRect=i,this.computePosition(i))}};async computePosition(t){if(!this.toolbar)return;this.virtualEl.rect=t;const{padding:n}=this.view.state.facet(Yk),{x:r,y:o}=await rQe(this.virtualEl,this.toolbar.dom,{placement:this.defaultPlacement,middleware:[zJe({mainAxis:5}),YJe({padding:n,boundary:this.view.scrollDOM}),uQe({padding:n,boundary:this.view.scrollDOM,editorMenu:this.editorMenu.currMenu})]});Object.assign(this.toolbar.dom.style,{top:"0",left:"0",transform:`translate(${Math.round(r)}px,${Math.round(o)}px)`})}maybeMeasure(){this.view.inView&&this.toolbar&&this.view.requestMeasure({read:this.readFromDOM}),this.inView!=this.view.inView&&(this.inView=this.view.inView,this.inView||this.removeToolbar())}}const gQe=is.ViewPlugin.fromClass(mQe,{eventHandlers:{scroll(){this.maybeMeasure()}}}),YM=Nm.Facet.define({enables:[gQe],combine:e=>e.filter(t=>t!=null).first()??null}),vQe=e=>{const t=TQe(e);t&&window.navigator.clipboard.writeText(t?.getSelection())},yQe=e=>{e.commands.executeCommandById("editor:toggle-bold",e)},bQe=e=>{e.commands.executeCommandById("editor:toggle-strikethrough",e)},wQe=e=>{e.commands.executeCommandById("editor:toggle-highlight",e)},SQe=e=>{e.commands.executeCommandById("editor:toggle-italics",e)},TQe=e=>{const{editor:t}=e.field(N.editorInfoField);return t},a8=(e,t)=>{const n=e.selection.ranges[0];if(!n)return null;const{anchor:r,head:o,empty:i}=n,[a,s]=[r,o].sort();return{start:a,end:i?void 0:s,create:u=>new EQe(u).addSmallButton(h=>h.setClass("clickable-icon").setIcon("copy").onClick(()=>vQe(e))).addSmallButton(h=>h.setClass("clickable-icon").setIcon("bold").onClick(()=>yQe(t))).addSmallButton(h=>h.setClass("clickable-icon").setIcon("italic").onClick(()=>SQe(t))).addSmallButton(h=>h.setClass("clickable-icon").setIcon("strikethrough").onClick(()=>bQe(t))).addSmallButton(h=>h.setClass("clickable-icon").setIcon("highlighter").onClick(()=>wQe(t)))}},xQe=e=>Nm.StateField.define({create:t=>a8(t,e),update:(t,n)=>!n.docChanged&&!n.selection?t:a8(n.state,e),provide:t=>YM.from(t)}),IQe=e=>[xQe(e)];class kQe extends N.BaseComponent{button;disabled=!1;dropdownOptions=[];menu;menuOpened=!1;constructor(t){super(),this.button=new N.ButtonComponent(t)}setDisabled(t){return this.button.setDisabled(t),this.disabled=t,this}setIcon(t){return this.button.setIcon(t),this}setClass(t){return this.button.setClass(t),this}setDropdownText(t){const n=this.button.buttonEl.createDiv("mini-toolbar-text"),r=this.button.buttonEl.createDiv("mini-toolbar-icon-with-text");N.setIcon(r,"chevron-down");const o=t.doc.lineAt(t.selection.ranges[0].from)?.from,i=Dx.syntaxTree(t).resolveInner(o+1),a=i.type.prop(Dx.tokenClassNodeProp);return n.setText(this.detectFormat(a,i)||"Text"),this}setDropdownIcon(){const t=this.button.buttonEl.createDiv("mini-toolbar-highlight-icon"),n=this.button.buttonEl.createDiv("mini-toolbar-icon-with-icon");return N.setIcon(t,"highlighter"),N.setIcon(n,"chevron-down"),this}detectFormat(t,n){if(!t)return"Text";if(t.includes("strong"))return"Bold";if(t.includes("em"))return"Italic";if(t.includes("strikethrough"))return"Strike";if(t.contains("hmd-codeblock"))return"CodeBlock";if(t.contains("hmd-inline-code"))return"Code";if(t.contains("formatting-header")){const r=t.match(/header-\d{1,}/);if(r)return"Heading "+r[0].slice(-1)}if(t.contains("formatting-list")||t.contains("hmd-list-indent")){if(n?.parent&&n.parent?.type.prop(Dx.lineClassNodeProp)?.contains("HyperMD-task-line"))return"To-do list";if(t.contains("formatting-list-ol"))return"Numbered list";if(t.contains("formatting-list-ul"))return"Bulleted list"}}setTooltip(t){return this.button.setTooltip(t),this}setOptionsList(t){return this.dropdownOptions=t,this}onClick(t){return this.dropdownOptions.length>0?(this.button.onClick(n=>this.showEditMenu(n)),this):(this.button.onClick(t),this)}showEditMenu(t){if(this.menuOpened=!this.menuOpened,!this.menuOpened)return;this.menu=new N.Menu,this.menu.onHide(()=>{this.menuOpened=!1});const n=t.currentTarget,r=t.currentTarget?.getBoundingClientRect(),o={x:r.left-6,y:r.bottom+6};for(let i=0;i<this.dropdownOptions?.length;i++)this.menu.addItem(a=>{a.setIcon("zap").setTitle(this.dropdownOptions[i]).onClick(()=>{})});this.menu.setParentElement(n).showAtPosition(o)}then(t){return t(this),this}}class EQe extends N.Component{dom;smallBtnContainer;constructor(t){super();const n=t?.closest(".memo-editor-wrapper");this.dom=n.createDiv({cls:"cm-mini-toolbar"},r=>r.style.position="absolute"),this.smallBtnContainer=this.dom}addSmallButton(t){return t(new kQe(this.smallBtnContainer)),this}unloading=!1;hide(){return this.unload(),this.unloading?this:(this.unloading=!0,this.dom.detach(),this.unloading=!1,this)}}const CQe=is.Decoration.line({attributes:{"data-ph":E("What do you think now...")},class:"thino-editor-placeholder"}),MQe=Nm.StateField.define({create(){return is.Decoration.none},update(e,t){const n=t.state.field(N.editorInfoField);if(!n||n.getViewType&&n.getViewType()!=="thino_view")return e;const r=new Nm.RangeSetBuilder,o=t.state.doc.toString(),i=t.state.doc.lineAt(0);return o?.length==0&&r.add(i.from,i.from,CQe),r.finish()},provide:e=>is.EditorView.decorations.from(e)});function nZ(e){return`userId:${e}`}function DQe(e,t){return`expiryDate:${t}:${e}`}function AQe(e){try{const t=nZ(e?.appId);return ur.get([t])[t]||""}catch(t){return console.error(t),""}}function NQe(e,t){try{const n=nZ(t?.appId);return ur.set({[n]:e}),{userId:e,key:n}}catch(n){console.error(n)}}function OQe(e,t){try{const n=DQe(AQe(t),t?.appId);ur.set({[n]:e})}catch(n){console.error(n)}}const PQe=Le.grabImageFromUrl,jQe=require("http"),LQe=require("url");function RQe(e){const t=e.indexOf(";base64,"),n=e.substring(5,t),r=e.substr(t+8),o=atob(r),i=new ArrayBuffer(o.length),a=new Uint8Array(i);for(let l=0;l<o.length;l++)a[l]=o.charCodeAt(l);return new Blob([i],{type:n})}const s8=async e=>{const{type:t}=e;if(t.startsWith("image"))try{return`${await tD.upload(e)}`}catch(n){new N.Notice(n)}};function FQe(e,t){const n=jQe.createServer(async function(r,o){o.setHeader("Access-Control-Allow-Origin","*"),o.setHeader("Access-Control-Allow-Methods","GET, HEAD, POST, OPTIONS, PUT, PATCH, DELETE"),o.setHeader("Access-Control-Allow-Headers","Access-Control-Allow-Headers, Origin, Authorization,Accept,x-client-id, X-Requested-With, Content-Type, Access-Control-Request-Method, Access-Control-Request-Headers, hypothesis-client-version"),o.setHeader("Access-Control-Allow-Credentials","true");try{if(r.url){const i=LQe.parse(r.url,!0);switch(i.pathname){case"/create":{if(r.method!=="POST"){o.statusCode=404,o.end();break}let a="";r.on("data",s=>{a+=s}),r.on("end",async()=>{const s=JSON.parse(a),{text:l,isList:u,type:d,imageList:h,sourceLink:p}=s;let m=l;if(!m){o.statusCode=200,o.setHeader("Content-Type","application/json"),o.end(JSON.stringify({status:"success",thino:null,link:null}));return}new RegExp(/<[a-z/][\s\S]*>/g).test(l)&&(m=N.htmlToMarkdown(l)),p&&(m+=` [source](<${decodeURIComponent(p)}>)`);let v=[];const y=[];if(t.AutoDownloadImage){const C=m.match(VM)||[];if(C.length>0){for(const k of C)try{const M=await PQe(k);if(M.size===0)continue;const I=new File([M],"image.png",{type:"image/png"}),O=await s8(I);y.push({oldUrl:k,newUrl:O})}catch(M){console.error(M)}y.forEach(k=>{m=m.replace(k.oldUrl,k.newUrl)}),h&&h.length>0&&(v=await Promise.all(h.map(async k=>{const M=RQe(k);return new File([M],"image.png",{type:"image/png"})})));for(const k of v){const M=await s8(k);m+=`
|
|
|
${M}`}}}let S=d;S||(S=t.MemoSaveLocation),e.settings?.AppendOrPrependTextViaServer&&(m=`${t?.PrependViaServer}${t?.WithNewLineViaServer==="prepend"||t?.WithNewLineViaServer==="both"?`
|
|
|
`:""}${m}${t?.WithNewLineViaServer==="append"||t?.WithNewLineViaServer==="both"?`
|
|
|
`:""}${t?.AppendViaServer}`);const x=await de.createThino({content:m,isList:u,type:S});x&&(de.pushMemo(x),Ue.clearQuery()),o.statusCode=200,o.setHeader("Content-Type","application/json"),o.end(JSON.stringify({status:"success",thino:x,link:`obsidian://thino?openId=${x.id}`}))});break}case"/search":{if(r.method!=="GET"){o.statusCode=404,o.end();break}const a=i.query,{keyword:s}=a,l=de.getThinoViaKeyword(s);o.statusCode=200,o.setHeader("Content-Type","application/json");const u=JSON.stringify({status:"success",thinos:l});o.end(u);break}case"/list":{if(r.method!=="GET"){o.statusCode=404,o.end();break}const{count:a}=i.query,s=de.getState().memos.slice(0,parseInt(a));o.statusCode=200,o.setHeader("Content-Type","application/json"),o.end(JSON.stringify({status:"success",thinos:s}));break}case"/info":{if(r.method!=="GET"){o.statusCode=404,o.end();break}const{getSettings:a}=i.query;if(!a){o.statusCode=404,o.end();break}const s=$e.getState().settings;o.statusCode=200,o.setHeader("Content-Type","application/json");const l=JSON.stringify({status:"success",infoSettings:s});o.end(l);break}default:o.statusCode=404,o.end();break}}}catch(i){console.error(i),o.statusCode=500,o.end({status:"error",message:i.message})}});return{listen(r,o){try{n.listen({port:parseInt(o),host:r})}catch(i){console.error(i),new N.Notice(E("Thino - Failed to start HTTP server, please check the port is available."))}new N.Notice(`${E("Thino - Started HTTP server on port")} ${o}`)},close(){n.close(),new N.Notice(E("Thino - Terminated HTTP server"))}}}const{clipboard:eo}=N.Platform.isDesktop?require("electron"):"";class HQe{eventListeners;constructor(){this.eventListeners={}}on(t,n){this.eventListeners[t]=this.eventListeners[t]||[],this.eventListeners[t].push(n)}once(t,n){n.$emitOnce=!0,this.on(t,n)}removeListener(t,n){if(this.eventListeners[t]){const r=this.eventListeners[t].findIndex(o=>o===n);r>=0&&this.eventListeners[t].splice(r,1)}}removeAllListeners(t){this.eventListeners[t]&&(this.eventListeners[t].length=0)}emit(t,...n){this.eventListeners[t]&&this.eventListeners[t].forEach(r=>{r.call(this,...n),r.$emitOnce&&this.removeListener(t,r)})}}const Qd=new HQe;let em=null,l8=eo?.readText(),c8=eo?.readImage();eo&&(eo.on=(e,t)=>(Qd.on(e,t),eo),eo.once=(e,t)=>(Qd.once(e,t),eo),eo.off=(e,t)=>(t?Qd.removeListener(e,t):Qd.removeAllListeners(e),eo),eo.startWatching=()=>(em||(em=setInterval(()=>{_Qe(l8,l8=eo?.readText())&&Qd.emit("text-changed"),BQe(c8,c8=eo?.readImage())&&Qd.emit("image-changed")},500)),eo),eo.stopWatching=()=>(em&&clearInterval(em),em=null,eo));function _Qe(e,t){return t&&e!==t}function BQe(e,t){return!t.isEmpty()&&e.toDataURL()!==t.toDataURL()}const Uk=require("electron")?.remote,u8=require("electron")?.remote?.screen;class YQe{constructor(t,n){this.app=t,this.plugin=n,this.isRegisted=!1,this.leaf=null,this.clipboard=eo}isRegisted;leaf;clipboard;isScreenTop=!1;currentSplitWindow;intervalNum;allowsCopy=!1;plugin;actionEl=null;async onload(){N.Platform.isDesktop&&(this.initGlobalCopyEvents(),await this.registerAllShortcuts(),this.registerEvents())}registerEvents(){this.plugin.registerEvent(this.app.workspace.on("quit",()=>{Uk.globalShortcut.unregister(this.plugin.settings.CaptureKey.OpenThinoGlobally)}))}initGlobalCopyEvents(){this.plugin.addCommand({id:"init-global-copy-events",name:E("Global copy"),callback:()=>{this.allowsCopy=!this.allowsCopy,!this.allowsCopy&&this.clipboard.stopWatching(),this.allowsCopy&&this.clipboard.startWatching(),this.leaf&&this.allowsCopy&&(this.actionEl=this.leaf.view.addAction("clipboard-x","Stop global copying",()=>{this.allowsCopy=!1,this.clipboard.stopWatching(),this.actionEl?.remove()}))}})}onunload(){this.isRegisted&&(Uk.globalShortcut.unregister(this.plugin.settings.CaptureKey.OpenThinoGlobally),this.clipboard.off("text-changed"),this.clipboard.off("image-changed"),this.clipboard.stopWatching(),this.leaf&&this.leaf.detach())}getCurrentLeaf(){return this.leaf?this.app.workspace.getLeavesOfType("thino_view").length>0&&!!this.app.workspace.getLeafById(this.leaf.id)?!0:(this.leaf?.detach(),this.currentSplitWindow.close(),this.currentSplitWindow=null,this.leaf=null,this.isScreenTop=!1,!1):!1}async registerAllShortcuts(){Uk?.globalShortcut?.register(this.plugin.settings.CaptureKey.OpenThinoGlobally,()=>{this.getCurrentLeaf()?this.showThinoView():this.openThinoView()}),this.isRegisted=!0}showThinoView(){const t=u8.getCursorScreenPoint(),n=this.leaf?.parent?.parent?.win?.electronWindow;if(n){if(n.setAlwaysOnTop(!this.isScreenTop,"screen"),this.leaf.setPinned(!this.isScreenTop),this.leaf.view.containerEl.toggleClass("thino-float-window",!0),n.isMinimized()&&n.restore(),n.focus(),this.plugin.settings.CaptureKey.ShowNearMouse){const{width:r,height:o}=n.getBounds();n.setBounds({x:t.x,y:t.y,width:r,height:o})}if(this.app.workspace.trigger("focus-on-textarea"),this.isScreenTop){this.isScreenTop=!1,setTimeout(()=>{n.setAlwaysOnTop(!1,"screen")},200);return}this.isScreenTop=!0}}openThinoView(){this.leaf=this.app.workspace.openPopoutLeaf({size:{width:400,height:400}});const t=this.leaf;this.leaf.view.containerEl.toggleClass("thino-float-window",!0),this.leaf.setViewState({type:"thino_view"}),setTimeout(()=>{t.view.containerEl.classList.toggle("mobile-view",!0)},0),this.currentSplitWindow=this.leaf?.parent?.parent;const n=this.leaf?.parent?.parent?.win.electronWindow;if(!n)return;n.setAlwaysOnTop(!this.isScreenTop,"screen"),this.leaf.setPinned(!this.isScreenTop),this.isScreenTop=!0;const r=this.app,o=i=>{const a=u8.getCursorScreenPoint(),s=t?.parent?.parent?.win?.electronWindow;if(s){if(s.isMinimized()&&s.restore(),!this.isScreenTop&&this.plugin.settings.CaptureKey.ShowNearMouse){const{width:l,height:u}=s.getBounds();s.setBounds({x:a.x,y:a.y-200,width:l,height:u})}s.setAlwaysOnTop(!0,"screen"),r.workspace.trigger("focus-on-textarea"),r.workspace.trigger("send-to-thino",i,t)}};this.clipboard.on("text-changed",()=>{const i=this.clipboard.readText();o(i)}).on("image-changed",()=>{const i=this.clipboard.readImage();o(i)})}}class d8 extends N.EditorSuggest{root;editor;cursor;plugin;tags;type="customTag";HASHTAG_REGEX=/(^|\s)#[^\u2000-\u206F\u2E00-\u2E7F'!"#$%&()*+,.:;<=>?@^`{|}~\[\]\\\s]*$/g;constructor(t,n){super(t),this.plugin=n}checkSettings(){return this.plugin.settings.UseVaultTags}checkInMemosView(t){const n=t.containerEl;return n&&n.parentElement?.parentElement?.classList.contains("common-editor-inputer")||!1}fuzzySearchItemsOptimized(t,n){const r=N.prepareFuzzySearch(t);return n.map(i=>{const a=r(i);return a?{item:i,match:a}:null}).filter(Boolean)}onTrigger(t,n){if(!this.checkInMemosView(n)||this.checkSettings())return null;this.tags=de.getState().tags,this.cursor=t,this.editor=n;const r=t.line,o=n.getLine(r),i=o.substr(0,t.ch);if(i.match(this.HASHTAG_REGEX)&&o.substr(t.ch,1)!=="#"){const a=i.lastIndexOf("#"),s=i.substr(a+1);return{start:{line:r,ch:a},end:{line:r,ch:t.ch},query:s}}return null}getSuggestions(t){return this.fuzzySearchItemsOptimized(t.query,this.tags).map(n=>n.item).sort((n,r)=>n.localeCompare(r))||[]}renderSuggestion(t,n){n.setText(t)}selectSuggestion(t){if(this.context){const n=this.context.editor,r=this.context.start,o=this.context.end;n.transaction({changes:[{from:r,to:o,text:"#"+t+" "}]}),setTimeout(function(){return n.focus()})}this.close()}}const EN=crypto,rZ=e=>e instanceof CryptoKey,Fb=new TextEncoder,CN=new TextDecoder;function UQe(...e){const t=e.reduce((o,{length:i})=>o+i,0),n=new Uint8Array(t);let r=0;for(const o of e)n.set(o,r),r+=o.length;return n}const zQe=e=>{const t=atob(e),n=new Uint8Array(t.length);for(let r=0;r<t.length;r++)n[r]=t.charCodeAt(r);return n},zk=e=>{let t=e;t instanceof Uint8Array&&(t=CN.decode(t)),t=t.replace(/-/g,"+").replace(/_/g,"/").replace(/\s/g,"");try{return zQe(t)}catch{throw new TypeError("The input to be decoded is not correctly encoded.")}};class i1 extends Error{static get code(){return"ERR_JOSE_GENERIC"}constructor(t){super(t),this.code="ERR_JOSE_GENERIC",this.name=this.constructor.name,Error.captureStackTrace?.(this,this.constructor)}}class VQe extends i1{constructor(){super(...arguments),this.code="ERR_JOSE_ALG_NOT_ALLOWED"}static get code(){return"ERR_JOSE_ALG_NOT_ALLOWED"}}class a1 extends i1{constructor(){super(...arguments),this.code="ERR_JOSE_NOT_SUPPORTED"}static get code(){return"ERR_JOSE_NOT_SUPPORTED"}}class Pr extends i1{constructor(){super(...arguments),this.code="ERR_JWS_INVALID"}static get code(){return"ERR_JWS_INVALID"}}class WQe extends i1{constructor(){super(...arguments),this.code="ERR_JWS_SIGNATURE_VERIFICATION_FAILED",this.message="signature verification failed"}static get code(){return"ERR_JWS_SIGNATURE_VERIFICATION_FAILED"}}function $s(e,t="algorithm.name"){return new TypeError(`CryptoKey does not support this operation, its ${t} must be ${e}`)}function Hb(e,t){return e.name===t}function Vk(e){return parseInt(e.name.slice(4),10)}function GQe(e){switch(e){case"ES256":return"P-256";case"ES384":return"P-384";case"ES512":return"P-521";default:throw new Error("unreachable")}}function ZQe(e,t){if(t.length&&!t.some(n=>e.usages.includes(n))){let n="CryptoKey does not support this operation, its usages must include ";if(t.length>2){const r=t.pop();n+=`one of ${t.join(", ")}, or ${r}.`}else t.length===2?n+=`one of ${t[0]} or ${t[1]}.`:n+=`${t[0]}.`;throw new TypeError(n)}}function $Qe(e,t,...n){switch(t){case"HS256":case"HS384":case"HS512":{if(!Hb(e.algorithm,"HMAC"))throw $s("HMAC");const r=parseInt(t.slice(2),10);if(Vk(e.algorithm.hash)!==r)throw $s(`SHA-${r}`,"algorithm.hash");break}case"RS256":case"RS384":case"RS512":{if(!Hb(e.algorithm,"RSASSA-PKCS1-v1_5"))throw $s("RSASSA-PKCS1-v1_5");const r=parseInt(t.slice(2),10);if(Vk(e.algorithm.hash)!==r)throw $s(`SHA-${r}`,"algorithm.hash");break}case"PS256":case"PS384":case"PS512":{if(!Hb(e.algorithm,"RSA-PSS"))throw $s("RSA-PSS");const r=parseInt(t.slice(2),10);if(Vk(e.algorithm.hash)!==r)throw $s(`SHA-${r}`,"algorithm.hash");break}case"EdDSA":if(e.algorithm.name!=="Ed25519"&&e.algorithm.name!=="Ed448")throw $s("Ed25519 or Ed448");break;case"ES256":case"ES384":case"ES512":{if(!Hb(e.algorithm,"ECDSA"))throw $s("ECDSA");const r=GQe(t);if(e.algorithm.namedCurve!==r)throw $s(r,"algorithm.namedCurve");break}default:throw new TypeError("CryptoKey does not support this operation")}ZQe(e,n)}function oZ(e,t,...n){if(n.length>2){const r=n.pop();e+=`one of type ${n.join(", ")}, or ${r}.`}else n.length===2?e+=`one of type ${n[0]} or ${n[1]}.`:e+=`of type ${n[0]}.`;return t==null?e+=` Received ${t}`:typeof t=="function"&&t.name?e+=` Received function ${t.name}`:typeof t=="object"&&t!=null&&t.constructor?.name&&(e+=` Received an instance of ${t.constructor.name}`),e}const f8=(e,...t)=>oZ("Key must be ",e,...t);function iZ(e,t,...n){return oZ(`Key for the ${e} algorithm must be `,t,...n)}const aZ=e=>rZ(e),os=["CryptoKey"],qQe=(...e)=>{const t=e.filter(Boolean);if(t.length===0||t.length===1)return!0;let n;for(const r of t){const o=Object.keys(r);if(!n||n.size===0){n=new Set(o);continue}for(const i of o){if(n.has(i))return!1;n.add(i)}}return!0};function KQe(e){return typeof e=="object"&&e!==null}function h8(e){if(!KQe(e)||Object.prototype.toString.call(e)!=="[object Object]")return!1;if(Object.getPrototypeOf(e)===null)return!0;let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}const XQe=(e,t)=>{if(e.startsWith("RS")||e.startsWith("PS")){const{modulusLength:n}=t.algorithm;if(typeof n!="number"||n<2048)throw new TypeError(`${e} requires key modulusLength to be 2048 bits or larger`)}},ac=(e,t,n=0)=>{n===0&&(t.unshift(t.length),t.unshift(6));const r=e.indexOf(t[0],n);if(r===-1)return!1;const o=e.subarray(r,r+t.length);return o.length!==t.length?!1:o.every((i,a)=>i===t[a])||ac(e,t,r+1)},p8=e=>{switch(!0){case ac(e,[42,134,72,206,61,3,1,7]):return"P-256";case ac(e,[43,129,4,0,34]):return"P-384";case ac(e,[43,129,4,0,35]):return"P-521";case ac(e,[43,101,110]):return"X25519";case ac(e,[43,101,111]):return"X448";case ac(e,[43,101,112]):return"Ed25519";case ac(e,[43,101,113]):return"Ed448";default:throw new a1("Invalid or unsupported EC Key Curve or OKP Key Sub Type")}},JQe=async(e,t,n,r,o)=>{let i,a;const s=new Uint8Array(atob(n.replace(e,"")).split("").map(u=>u.charCodeAt(0))),l=t==="spki";switch(r){case"PS256":case"PS384":case"PS512":i={name:"RSA-PSS",hash:`SHA-${r.slice(-3)}`},a=l?["verify"]:["sign"];break;case"RS256":case"RS384":case"RS512":i={name:"RSASSA-PKCS1-v1_5",hash:`SHA-${r.slice(-3)}`},a=l?["verify"]:["sign"];break;case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":i={name:"RSA-OAEP",hash:`SHA-${parseInt(r.slice(-3),10)||1}`},a=l?["encrypt","wrapKey"]:["decrypt","unwrapKey"];break;case"ES256":i={name:"ECDSA",namedCurve:"P-256"},a=l?["verify"]:["sign"];break;case"ES384":i={name:"ECDSA",namedCurve:"P-384"},a=l?["verify"]:["sign"];break;case"ES512":i={name:"ECDSA",namedCurve:"P-521"},a=l?["verify"]:["sign"];break;case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":{const u=p8(s);i=u.startsWith("P-")?{name:"ECDH",namedCurve:u}:{name:u},a=l?[]:["deriveBits"];break}case"EdDSA":i={name:p8(s)},a=l?["verify"]:["sign"];break;default:throw new a1('Invalid or unsupported "alg" (Algorithm) value')}return EN.subtle.importKey(t,s,i,o?.extractable??!1,a)},QQe=(e,t,n)=>JQe(/(?:-----(?:BEGIN|END) PUBLIC KEY-----|\s)/g,"spki",e,t,n);async function eet(e,t,n){if(typeof e!="string"||e.indexOf("-----BEGIN PUBLIC KEY-----")!==0)throw new TypeError('"spki" must be SPKI formatted string');return QQe(e,t,n)}const tet=(e,t)=>{if(!(t instanceof Uint8Array)){if(!aZ(t))throw new TypeError(iZ(e,t,...os,"Uint8Array"));if(t.type!=="secret")throw new TypeError(`${os.join(" or ")} instances for symmetric algorithms must be of type "secret"`)}},net=(e,t,n)=>{if(!aZ(t))throw new TypeError(iZ(e,t,...os));if(t.type==="secret")throw new TypeError(`${os.join(" or ")} instances for asymmetric algorithms must not be of type "secret"`);if(n==="sign"&&t.type==="public")throw new TypeError(`${os.join(" or ")} instances for asymmetric algorithm signing must be of type "private"`);if(n==="decrypt"&&t.type==="public")throw new TypeError(`${os.join(" or ")} instances for asymmetric algorithm decryption must be of type "private"`);if(t.algorithm&&n==="verify"&&t.type==="private")throw new TypeError(`${os.join(" or ")} instances for asymmetric algorithm verifying must be of type "public"`);if(t.algorithm&&n==="encrypt"&&t.type==="private")throw new TypeError(`${os.join(" or ")} instances for asymmetric algorithm encryption must be of type "public"`)},ret=(e,t,n)=>{e.startsWith("HS")||e==="dir"||e.startsWith("PBES2")||/^A\d{3}(?:GCM)?KW$/.test(e)?tet(e,t):net(e,t,n)};function oet(e,t,n,r,o){if(o.crit!==void 0&&r.crit===void 0)throw new e('"crit" (Critical) Header Parameter MUST be integrity protected');if(!r||r.crit===void 0)return new Set;if(!Array.isArray(r.crit)||r.crit.length===0||r.crit.some(a=>typeof a!="string"||a.length===0))throw new e('"crit" (Critical) Header Parameter MUST be an array of non-empty strings when present');let i;n!==void 0?i=new Map([...Object.entries(n),...t.entries()]):i=t;for(const a of r.crit){if(!i.has(a))throw new a1(`Extension Header Parameter "${a}" is not recognized`);if(o[a]===void 0)throw new e(`Extension Header Parameter "${a}" is missing`);if(i.get(a)&&r[a]===void 0)throw new e(`Extension Header Parameter "${a}" MUST be integrity protected`)}return new Set(r.crit)}const iet=(e,t)=>{if(t!==void 0&&(!Array.isArray(t)||t.some(n=>typeof n!="string")))throw new TypeError(`"${e}" option must be an array of strings`);if(t)return new Set(t)};function aet(e,t){const n=`SHA-${e.slice(-3)}`;switch(e){case"HS256":case"HS384":case"HS512":return{hash:n,name:"HMAC"};case"PS256":case"PS384":case"PS512":return{hash:n,name:"RSA-PSS",saltLength:e.slice(-3)>>3};case"RS256":case"RS384":case"RS512":return{hash:n,name:"RSASSA-PKCS1-v1_5"};case"ES256":case"ES384":case"ES512":return{hash:n,name:"ECDSA",namedCurve:t.namedCurve};case"EdDSA":return{name:t.name};default:throw new a1(`alg ${e} is not supported either by JOSE or your javascript runtime`)}}function set(e,t,n){if(rZ(t))return $Qe(t,e,n),t;if(t instanceof Uint8Array){if(!e.startsWith("HS"))throw new TypeError(f8(t,...os));return EN.subtle.importKey("raw",t,{hash:`SHA-${e.slice(-3)}`,name:"HMAC"},!1,[n])}throw new TypeError(f8(t,...os,"Uint8Array"))}const cet=async(e,t,n,r)=>{const o=await set(e,t,"verify");XQe(e,o);const i=aet(e,o.algorithm);try{return await EN.subtle.verify(i,o,n,r)}catch{return!1}};async function uet(e,t,n){if(!h8(e))throw new Pr("Flattened JWS must be an object");if(e.protected===void 0&&e.header===void 0)throw new Pr('Flattened JWS must have either of the "protected" or "header" members');if(e.protected!==void 0&&typeof e.protected!="string")throw new Pr("JWS Protected Header incorrect type");if(e.payload===void 0)throw new Pr("JWS Payload missing");if(typeof e.signature!="string")throw new Pr("JWS Signature missing or incorrect type");if(e.header!==void 0&&!h8(e.header))throw new Pr("JWS Unprotected Header incorrect type");let r={};if(e.protected)try{const v=zk(e.protected);r=JSON.parse(CN.decode(v))}catch{throw new Pr("JWS Protected Header is invalid")}if(!qQe(r,e.header))throw new Pr("JWS Protected and JWS Unprotected Header Parameter names must be disjoint");const o={...r,...e.header},i=oet(Pr,new Map([["b64",!0]]),n?.crit,r,o);let a=!0;if(i.has("b64")&&(a=r.b64,typeof a!="boolean"))throw new Pr('The "b64" (base64url-encode payload) Header Parameter must be a boolean');const{alg:s}=o;if(typeof s!="string"||!s)throw new Pr('JWS "alg" (Algorithm) Header Parameter missing or invalid');const l=n&&iet("algorithms",n.algorithms);if(l&&!l.has(s))throw new VQe('"alg" (Algorithm) Header Parameter value not allowed');if(a){if(typeof e.payload!="string")throw new Pr("JWS Payload must be a string")}else if(typeof e.payload!="string"&&!(e.payload instanceof Uint8Array))throw new Pr("JWS Payload must be a string or an Uint8Array instance");let u=!1;typeof t=="function"&&(t=await t(r,e),u=!0),ret(s,t,"verify");const d=UQe(Fb.encode(e.protected??""),Fb.encode("."),typeof e.payload=="string"?Fb.encode(e.payload):e.payload);let h;try{h=zk(e.signature)}catch{throw new Pr("Failed to base64url decode the signature")}if(!await cet(s,t,h,d))throw new WQe;let m;if(a)try{m=zk(e.payload)}catch{throw new Pr("Failed to base64url decode the payload")}else typeof e.payload=="string"?m=Fb.encode(e.payload):m=e.payload;const b={payload:m};return e.protected!==void 0&&(b.protectedHeader=r),e.header!==void 0&&(b.unprotectedHeader=e.header),u?{...b,key:t}:b}async function det(e,t,n){if(e instanceof Uint8Array&&(e=CN.decode(e)),typeof e!="string")throw new Pr("Compact JWS must be a string or Uint8Array");const{0:r,1:o,2:i,length:a}=e.split(".");if(a!==3)throw new Pr("Invalid Compact JWS");const s=await uet({payload:o,protected:r,signature:i},t,n),l={payload:s.payload,protectedHeader:s.protectedHeader};return typeof t=="function"?{...l,key:s.key}:l}const fet={webId:"globe-2",pinned:"pin",archived:"archive",visibility:"eye",deleted:"trash"};class het extends is.WidgetType{constructor(t,n,r,o,i){super(),this.view=t,this.plugin=n,this.target=r,this.type=o,this.to=i}error=!1;eq(t){return this.target===t.target}toDOM(){const t=createSpan();return t.toggleClass("thino-inline-widget",!0),N.setIcon(t,fet[this.type]||"help-circle"),N.setTooltip&&N.setTooltip(t,this.target),t}}function pet(e){class t{view;match=new is.MatchDecorator({regexp:/\[(webId|pinned|archived|visibility|deleted)::([^\]]+)\]/g,decorate:(o,i,a,s,l)=>{this.shouldRender(l,i,a)&&o(i,a,is.Decoration.replace({widget:new het(l,e,s[0],s[1],a)}))}});decorations=is.Decoration.none;constructor(o){this.view=o,this.updateDecorations(o)}update(o){this.updateDecorations(o.view,o)}destroy(){this.decorations=is.Decoration.none}updateDecorations(o,i){!i||this.decorations.size===0?this.decorations=this.match.createDeco(o):this.decorations=this.match.updateDeco(i,this.decorations)}isLivePreview(o){return o.field(N.editorLivePreviewField)}shouldRender(o,i,a){return!o.state.selection.ranges.some(l=>l.from<=i?l.to>=i:l.from<=a)&&this.isLivePreview(o.state)}}const n={decorations:r=>r.decorations.update({filter:(o,i,a)=>{const s=a.spec.widget;return s&&s.error?!1:o===i||!r.view.state.selection.ranges.filter(l=>{const u=l.from,d=l.to;return u<=o?d>=o:u<=i}).length}})};return is.ViewPlugin.fromClass(t,n)}const met=e=>e.ctrlKey!==void 0||e.metaKey!==void 0||e.shiftKey!==void 0||e.altKey!==void 0,_b=()=>{new N.Notice(E("Open Memos Successfully"))},Bb=[{id:"open-thino-in-left-sidebar",shortName:E("Left sidebar"),name:E("Open thino in left sidebar"),icon:"arrow-left",location:"left",cb:_b,modKeys:"shift"},{id:"open-thino-in-right-sidebar",shortName:E("Right sidebar"),name:E("Open thino in right sidebar"),icon:"arrow-right",location:"right",cb:_b,modKeys:["ctrl","meta"]},{id:"open-thino-in-float",shortName:E("Float window"),name:E("Open thino in float window"),icon:"layout",location:"float",cb:_b,modKeys:"alt"},{id:"open-thino-in-center",shortName:E("Center window"),name:E("Open thino in center window"),icon:"tv-2",location:"center",cb:_b,modKeys:void 0}];function m8(e,t,n){return new Promise((r,o)=>{let i="",a="";const s=l=>new Promise((u,d)=>{const h=t.ShareToThinoWithTextNewline===l||t.ShareToThinoWithTextNewline==="both"?`
|
|
|
`:" ";switch(t[l==="prepend"?"SharePrependType":"ShareAppendType"]){case"none":u();break;case"preset":t.ShareToThinoWithText&&(l==="prepend"?i=t.ShareToThinoWithTextPrepend+h:a=h+t.ShareToThinoWithTextAppend),u();break;case"input":{const p="Thino "+E(l==="prepend"?"Prepend text":"Append text");new sZ(e,p,m=>{l==="prepend"?i=m.trim()+(m.trim()?h:""):a=(m.trim()?h:"")+m,u()}).open();break}case"selectTags":new Soe(e,p=>{const m=p.length>0?p.map(b=>"#"+b).join(" "):"";l==="prepend"?i=m.trim()+(m.trim()?h:""):a=(m.trim()?h:"")+m.trim(),u()}).open();break;default:d(new Error("Invalid configuration type."))}});Promise.all([s("append"),s("prepend")]).then(()=>n(i,a)).then(()=>r()).catch(o)})}const get=e=>{const t=e.embedRegistry;if(!t)return!1;const n=t.embedByExtension.md,r=n({app:e,containerEl:createDiv()},null,null);return r.editable=!0,r.set(""),r.showEditor(),Object.getPrototypeOf(Object.getPrototypeOf(r.editMode)).constructor};async function MN(e){try{const t=e.app.internalPlugins.plugins["daily-notes"];let n;n={settings:{...e.settings,tokenForVerify:"***"},plugins:Object.keys(e.app.plugins.plugins),manifest:e.manifest,platform:N.Platform.resourcePathPrefix},t&&(n={...n,dailyNotePluginInfo:{options:t.instance.options}}),await navigator.clipboard.writeText(`\`\`\`json
|
|
|
${JSON.stringify(n,null,2)}
|
|
|
\`\`\``),new N.Notice(E("Debug info copied to clipboard"))}catch(t){console.error(t)}}class vet extends N.Plugin{settings;settingTab;thinoWorkerManager;triggerBySelf=!1;updatedID="";debounceTimer=0;apiHttpServer=null;captureService=null;loaded=!1;MarkdownEditor;async onload(){this.MarkdownEditor=get(this.app),$e.setPlugin(this),await this.loadSettings(),bJe(),this.registerRibbon(),await this.verify();try{this.settings.ShowUpdateMessage&&await this.checkVersionAndShowChangeLog()}catch(t){console.error(t)}this.settingTab=new PJe(this.app,this),this.addSettingTab(this.settingTab),this.initApp(),this.initEditor(),this.initURIHandler(),this.registerMobileEvent(),this.registerCommands(),this.registerCanvasNodeMemos(),this.registerHoverEvent(),this.registerLinkOpen(),this.registerCodeBlocks(),N.Platform.isMobile&&this.registerMobileNavbar(),this.updateLayoutSettings(),this.registerEditorContextMenu(),this.registerEditorSuggest(new yJe(this.app,this)),this.registerEditorExtension([MQe]),this.app.workspace.onLayoutReady(this.onLayoutReady.bind(this)),this.registerView(Qr,t=>new Tf(t,this)),this.thinoWorkerManager=new SH(this.app,this),this.addChild(this.thinoWorkerManager)}async loadSettings(){this.settings=Object.assign({},ti,await this.loadData()),$e.setSettings(this.settings)}async saveSettings(){await this.saveData(this.settings),$e.setSettings(this.settings)}onunload(){this.app.workspace.detachLeavesOfType(Qr),de.clearMemos(),ke.dispatch({type:"CLEAR_MEMOS",payload:null}),ke.dispatch({type:"CLEAR_FILES",payload:null}),ke.dispatch({type:"CLEAR_VIEW",payload:null});const t=document.body.find(".dialog-wrapper");if(t&&t.parentElement?.detach(),this.apiHttpServer&&(this.apiHttpServer.close(),this.apiHttpServer=null),this.captureService&&this.captureService.onunload(),N.Platform.isMobile){const n=this.app.mobileNavbar;n&&n.showThinoBtnEl&&this.settings?.NavbarButton&&(n.showThinoBtnEl.detach(),n.showThinoBtnEl=null)}new N.Notice(E("Close Memos Successfully"))}initEditor(){this.register(hm(N.MetadataCache.prototype,{getFileCache:n=>function(r){return!r?.path&&!r?null:n.call(this,r)}})),(n=>{const r=n.app.embedRegistry.embedByExtension.md({app:n.app,containerEl:document.createElement("div")},null,"");r.editable=!0,r.showEditor();const o=Object.getPrototypeOf(Object.getPrototypeOf(r.editMode)),i=hm(o.constructor.prototype,{triggerClickableToken:a=>async function(...s){if(s[0].type==="internal-link"){if(this.editorEl.closest(".memo-editor-wrapper")){const l=de.getMemoById(s[0].text??"");if(l){pa(l);return}return a.apply(this,s)}return a.apply(this,s)}return a.apply(this,s)}});this.register(i),r.unload()})(this)}initApp(){$e.setApp(this.app)}initURIHandler(){this.registerObsidianProtocolHandler("thino",async t=>{if(!t)return;if(t.openSettings&&(this.app.setting.open(),this.app.setting.openTabById(this.manifest.id||"obsidian-memos")),t.userid)try{const i=t.userid;NQe(i,this.app),OQe(N.moment().add(30,"days").valueOf(),this.app),Ze.setRefresh(!0)}catch(i){console.error(i),new N.Notice(E("Failed to verify"))}if(t.token)try{const i=t.token;this.app?.saveLocalStorage("tokenForSync",i),setTimeout(()=>{this.app.setting.open(),this.app.setting.openTabById(this.manifest.id||"obsidian-memos"),this.settingTab.display()},200),new N.Notice(E("Saved sync token successfully"))}catch(i){console.error(i),new N.Notice(E("Failed to save"))}if(t.copyToken){this.app.setting.open(),this.app.setting.openTabById(this.manifest.id??"obsidian-memos");const i=await ZG();await navigator.clipboard.writeText(i),new N.Notice(E("Copied app id successfully"))}const n=$e.getState()?.verifyState,r=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device?.getId(),o=N.Platform.isDesktop?await Sn():r?.identifier||r?.uuid;if(!(!n||n?.appId!==o)){if(t.content){const i=t.type,a=decodeURI(t.content)!==t.content?decodeURI(t.content):t.content,s=t.task,l=await de.createThino({content:a,type:i,isList:!!s});if(!l)return;de.pushMemo(l),Ue.clearQuery()}t.openId&&await de.openThinoByID(t.openId)}})}initGlobalManifest(){Ze.setPluginManifest(this.manifest)}stopServer(){this.apiHttpServer&&(this.apiHttpServer.close(),this.apiHttpServer=null)}async stopEnableList(){const t=$e.getState()?.verifyState,n=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device?.getId(),r=N.Platform.isDesktop?await Sn():n?.identifier||n?.uuid;if(!t||t?.appId!==r){this.settings.EnabledLocationList=[{value:"DAILY",target:"ProcessEntriesBelow",insert:"InsertAfter"}],this.settingTab.debounceApplySettingsUpdate();return}}async initServer(){if(N.Platform.isMobile||!this.settings.EnabledHttpApi)return;const t=$e.getState()?.verifyState,n=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device?.getId(),r=N.Platform.isDesktop?await Sn():n?.identifier||n?.uuid;!t||t?.appId!==r||(this.apiHttpServer=FQe(this,this.settings),this.initServerPort())}initServerPort(){this.apiHttpServer&&this.settings.EnabledHttpApi&&this.apiHttpServer.listen(this.settings.HttpApiIpType,this.settings.HttpApiPort)}async initCaptureService(){if(N.Platform.isMobile||!this.settings.CaptureKey.EnableCaptureKey)return;const t=$e.getState()?.verifyState,n=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device?.getId(),r=N.Platform.isDesktop?await Sn():n?.identifier||n?.uuid;!t||t?.appId!==r||(this.captureService=new YQe(this.app,this),await this.captureService.onload())}registerMobileEvent(){N.Platform.isMobile&&(this.registerEvent(this.app.workspace.on("receive-text-menu",(t,n)=>{t.addItem(r=>{r.setSection("options").setIcon("popup-open").setTitle(E("Insert as Memo")).onClick(async()=>{let o=n;try{await m8(this.app,this.settings,async(i,a)=>{o=i+o+a;const s=await de.createThino({content:o,type:this.settings.MemoSaveLocation||"DAILY",isList:!0});de.pushMemo(s)})}catch(i){console.error("Configuration failed:",i);return}})})})),this.registerEvent(this.app.workspace.on("receive-files-menu",(t,n)=>{t.addItem(r=>{r.setIcon("popup-open").setTitle(E("Insert file as memo content")).onClick(async()=>{let i=n.map(a=>this.app.fileManager.generateMarkdownLink(a,a.path)).join(`
|
|
|
`);try{await m8(this.app,this.settings,async(a,s)=>{i=a+i+s;const l=await de.createThino({content:i,type:this.settings.MemoSaveLocation||"DAILY",isList:!0});de.pushMemo(l)})}catch(a){console.error("Configuration failed:",a);return}})})})))}registerCommands(){Bb.forEach(t=>{this.addCommand({id:t.id,name:t.name,callback:()=>this.openMemos(t.location,t.cb),hotkeys:[]})}),["Modern","Clean","Minimal","Gradient"].forEach(t=>{this.addCommand({id:`share-thino-via-${t.toLowerCase()}`,name:E("Share thino")+` [${E(t)}]`,editorCallback:(n,r)=>{const o=n.getSelection();if(o.length===0)return;const i={id:`temp-${Date.now()}`,content:o,createdAt:N.moment().format("YYYY-MM-DD HH:mm:ss"),updatedAt:N.moment().format("YYYY-MM-DD HH:mm:ss"),deletedAt:"",pinned:!1,visibility:"PUBLIC",rowStatus:"NORMAL",thinoType:"JOURNAL",hasId:"",linkId:[],resourceList:[],creatorName:"thino",sourceType:"DAILY",path:r.file.path,fileInfo:{tags:[],frontmatter:{}}};yu(i,t.toLowerCase(),r)}})}),this.addCommand({id:"focus-mode",name:"Focus mode",callback:()=>{const t=document.body.hasClass("thino-focus");document.body.toggleClass("thino-focus",!t)}}),this.addCommand({id:"hide-side-bar",name:E("Toggle sidebar visibility"),callback:()=>{const t=Ze.getState().isMobileView,n=document.body.hasClass("thino-hide-side-bar");document.body.toggleClass("thino-hide-side-bar",t?!1:!n)}}),this.addCommand({id:"hide-tags",name:E("Toggle tags visibility"),callback:()=>{const t=document.body.hasClass("thino-hide-tags");document.body.toggleClass("thino-hide-tags",!t)}}),this.addCommand({id:"hide-query-list",name:E("Toggle query list visibility"),callback:()=>{const t=document.body.hasClass("thino-hide-query-list");document.body.toggleClass("thino-hide-query-list",!t)}}),this.addCommand({id:"insert-task",name:E("Insert task"),checkCallback:t=>{const n=this.app.plugins.getPlugin("obsidian-tasks-plugin"),r=this.app.workspace.getLeavesOfType("thino_view").first();if(n&&r)return t||this.app.plugins.plugins["obsidian-tasks-plugin"].apiV1.createTaskLineModal().then(i=>{const a=this.app.workspace.activeEditor;a&&a.editor?.insertText(i)}),!0}}),this.addCommand({id:"show-thino-editor",name:E("Show thino editor"),checkCallback:t=>{if(de.initialized&&$e.initialized){if(!t){if(!$e.getState().view){new N.Notice(E("Please open thino first"));return}new lE(this.app).open()}return!0}}}),this.addCommand({id:"lock-thino",name:E("Lock thino"),checkCallback:t=>{if(this.app.workspace.getActiveViewOfType(Tf)&&this.settings.needVerify)return t||Ze.setLocked(!0),!0}}),this.addCommand({id:"copy-debug-info",name:E("Copy debug info"),callback:async()=>{await MN(this)}}),this.addCommand({id:"insert-editor",name:E("Insert editor"),checkCallback:t=>{const n=this.app.workspace.getActiveViewOfType(N.MarkdownView);if(n&&n?.getViewType()==="markdown")return t||n.editor.replaceSelection("\n```thino\n{\n editor: false\n}\n```\n"),!0}}),this.addCommand({id:"toggle-minimal-thino",name:E("Toggle minimal mode"),callback:()=>{const t=document.body.hasClass("minimal-thino");document.body.toggleClass("minimal-thino",!t)}}),this.addCommand({id:"focus-on-thino-editor",name:E("Focus on thino editor"),callback:()=>this.focusOnEditor(),hotkeys:[]}),this.addCommand({id:"reinit-thino-sync",name:E("ReSync web thinos to local"),callback:()=>{_9e(this.app)}}),this.addCommand({id:"init-thino-sync",name:E("Sync local thinos to web"),callback:async()=>{if(!this.app?.loadLocalStorage("tokenForSync")){new N.Notice(E("Please input token first"));return}if(!this.settings.startSync){new N.Notice(E("Please enable sync first"));return}try{await de.initSync()}catch(n){console.error(n),new N.Notice(E("Init Failed"))}}}),this.addCommand({id:"show-daily-thino",name:E("Show daily thino"),callback:()=>this.openDailyMemo(),hotkeys:[]}),this.addCommand({id:"focus-on-search-bar",name:E("Focus on search bar"),callback:()=>this.searchIt(),hotkeys:[]}),this.addCommand({id:"show-thino-in-popover",name:E("Show-thino in popover(Hover editor)"),callback:()=>this.showInPopover(),hotkeys:[]})}async onLayoutReady(){await this.stopEnableList(),await this.initServer(),this.initGlobalManifest(),await this.initMemos(),this.autoOpenMemos(),this.registerThinoWidget(),await this.registerToolbarCheck(),await this.initCaptureService();const t=this.app.workspace.editorSuggest.suggests.findIndex(n=>n.type==="customTag");t!==-1?(this.app.workspace.editorSuggest.suggests.splice(t,1),this.app.workspace.editorSuggest.suggests.unshift(new d8(this.app,this))):this.app.workspace.editorSuggest.suggests.unshift(new d8(this.app,this))}async initMemos(){try{await this.initDailyNotes()}catch(t){console.error(t)}$e.getState(),de.getState(),await de.fetchAllMemos()}async initDailyNotes(){this.settings.EnabledLocationList.find(t=>t.value==="DAILY")&&await $e.fechLocalDailyNotes()}registerCanvasNodeMemos(){if(!N.requireApiVersion("1.2.0")||!this.settings.EnabledLocationList.find(o=>o.value==="CANVAS"))return;const t=o=>{clearTimeout(this.debounceTimer),this.debounceTimer=window.setTimeout(()=>{setTimeout(async()=>{const i=o.canvas.getData(),a=i.nodes.find(s=>s.id===o.id);if(a&&(n(a),o.canvas.setData(i),de.getMemoById(o.id))){const l=await de.updateMemo(o.id,a.text,a.thinoType);de.editMemo(l)}o.canvas.requestSave(!0)},0)},800)},n=o=>{o.createdAt||(o.createdAt=N.moment().format("YYYY-MM-DD HH:mm:ss")),o.updatedAt=N.moment().format("YYYY-MM-DD HH:mm:ss"),o.deletedAt=o.deletedAt?o.deletedAt:"",o.pinned=o.pinned?o.pinned:!1,o.visibility=o.visibility?o.visibility:"PUBLIC",o.rowStatus=o.rowStatus?o.rowStatus:"NORMAL",o.thinoType=o.thinoType?o.thinoType:"JOURNAL",o.hasId=o.hasId?o.hasId:"",o.linkId=o.linkId?o.linkId:"",o.resourceList=[]},r=()=>{const o=this.app.workspace.getLeavesOfType("canvas").first()?.view;if(!o||!o?.canvas)return!1;const a=(this.app.workspace.getLeavesOfType("canvas").first()?.view).canvas.nodes.values(),l=Array.from(a).filter(h=>h.text!==void 0);if(!l||l.length===0)return!1;const u=l[0].child;if(!u)return!1;const d=hm(u.constructor.prototype,{save:h=>function(...p){h.call(this,...p),this.node.isEditing&&t(this.node)}});return this.register(d),!0};this.app.workspace.onLayoutReady(()=>{if(!r()){const o=this.app.workspace.on("layout-change",()=>{r()&&this.app.workspace.offref(o)});this.registerEvent(o)}})}registerLinkOpen(){hm(N.Workspace.prototype,{openLinkText:t=>async function(...n){const r=de.getState().memos;if(r.find(o=>o.id===n[0]||o.id===n[1])){const o=r.find(i=>i.id===n[0]||i.id===n[1]);if(o){pa(o);return}}await t.call(this,...n)}})}registerHoverEvent(){this.registerHoverLinkSource("thino",{defaultMod:!0,display:"Thino"})}registerCodeBlocks(){this.registerMarkdownCodeBlockProcessor("thino",async(t,n)=>{if(t){if(!this.app.workspace.getLeavesOfType("thino_view")?.length){n.toggleClass(["thino-editor-codeblock","view-error"],!0),nce(n,this);return}if(t){const r=N.parseYaml(t);oce(n,r)}}})}registerMobileNavbar(){if(!this.settings?.NavbarButton)return;const t=this.app.mobileNavbar;if(!t||t.showThinoBtnEl)return;const r=t.containerEl.find(".mobile-navbar-actions").createEl("div",{cls:"mobile-navbar-action mod-tappable"});new N.ExtraButtonComponent(r).setIcon("Memos").onClick(()=>{document.body.find(".thino-editor-modal")||new lE(this.app).open()}),t.showThinoBtnEl=r}updateLayoutSettings(){document.body.toggleClass("thino-show-status",!!this.settings.AlwaysShowStatusText)}registerEditorContextMenu(){this.registerEvent(this.app.workspace.on("editor-menu",(t,n,r)=>{const o=n.getSelection();if(o.length===0)return;const i={id:`temp-${Date.now()}`,content:o,createdAt:N.moment().format("YYYY-MM-DD HH:mm:ss"),updatedAt:N.moment().format("YYYY-MM-DD HH:mm:ss"),deletedAt:"",pinned:!1,visibility:"PUBLIC",rowStatus:"NORMAL",thinoType:"JOURNAL",hasId:"",linkId:[],resourceList:[],creatorName:"thino",sourceType:"DAILY",path:r.file.path,fileInfo:{tags:[],frontmatter:{}}},a=(s,l)=>{s.addItem(u=>{u.setSection("selection").setTitle(l+E("Modern")).setIcon("palette").onClick(async()=>{yu(i,"modern",r)})}).addItem(u=>{u.setSection("selection").setTitle(l+E("Clean")).setIcon("palette").onClick(async()=>{yu(i,"clean",r)})}).addItem(u=>{u.setSection("selection").setTitle(l+E("Minimal")).setIcon("palette").onClick(async()=>{yu(i,"minimal",r)})}).addItem(u=>{u.setSection("selection").setTitle(E("Gradient")).setIcon("palette").onClick(async()=>{yu(i,"gradient",r)})})};N.Platform.isDesktop&&t.addItem(s=>{const l=s.setIcon("Memos").setSection("selection").setTitle(E("Thino share")).setSubmenu();a(l,"")}),N.Platform.isMobile&&a(t,E("Thino share")+" ")}))}registerRibbon(){this.addRibbonIcon("Memos",E("ribbonIconTitle"),async t=>{if(t.button===2){t.preventDefault();const n=new N.Menu;Bb.forEach(r=>{n.addItem(o=>{o.setTitle(r.shortName).setIcon(r.icon).onClick(async()=>{await this.openMemos(r.location,r.cb)})})}),n.showAtMouseEvent(t);return}for(let n=0;n<Bb.length;n++){const r=Bb[n];if(!r.modKeys){await this.openMemos(r.location,r.cb);break}if(!met(t))continue;const o=i=>t[`${i}Key`];if(typeof r.modKeys=="string"&&o(r.modKeys)||Array.isArray(r.modKeys)&&r.modKeys.some(o)){await this.openMemos(r.location,r.cb);break}}})}registerThinoWidget(){this.registerEditorExtension([pet(this)])}async registerToolbarCheck(){if(this.loaded)return;const t=$e.getState()?.verifyState,n=!N.Platform.isDesktop&&await window.Capacitor?.Plugins.Device?.getId(),r=N.Platform.isDesktop?await Sn():n?.identifier||n?.uuid;!t||t?.appId!==r||(this.registerEditorExtension([IQe(this.app)]),this.registerEditorSuggest(new vJe(this.app,this)),this.loaded=!0)}async verify(){let t="";if(N.Platform.isDesktop)t=await Sn();else{const r=await window.Capacitor.Plugins.Device?.getId();if(!r)return;t=r?.identifier||r?.uuid}async function n(r){if(!r)return $e.setVerifyState(null),!1;const a=await eet(`-----BEGIN PUBLIC KEY-----
|
|
|
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAr+i4MLzI40gGFHl7gdRH
|
|
|
UL1mH0NcWEs1/IBYDDbc9ALbvUGwDaUcVIKke+b+F4T7qISexyGd5qV0s1vNYeCk
|
|
|
iCTq4w3+CFDurIFYAgQYTcV6K5pL8Bpb79FEclsTnAcKgiuzKBxPZ1djKxbgnmFj
|
|
|
+PE+EcmX+JJK9hG1O8X+YFJoPJWl225eCoysONickiI7Ndwu9YLR8pIUb1VMyJSy
|
|
|
cMR87z466Nc5Hx2QhwyuiiQYL3Ru4WkNF3AVWgqeOlhBDybFFwDaV7OOMTiYtH46
|
|
|
3iKx6azEVS8W/gYfrW+hKp2VziPPw3oxouP/wCes/4qRlXkwyjSwtfLtpE4Rsa4+
|
|
|
swIDAQAB
|
|
|
-----END PUBLIC KEY-----`,"RS256");try{const{payload:s}=await det(r,a),l=JSON.parse(new TextDecoder().decode(s));return!l||l.iss!=="pkmer"||l.type!=="thino"||l.appId!==t?!1:($e.setVerifyState(l),!0)}catch(s){console.error(s)}}return await n(this.settings.tokenForVerify[t])}async checkVersionAndShowChangeLog(){const t=this.manifest.version,n=this.settings.LastUpdatedVersion;t!==n&&(this.settings.LastUpdatedVersion=t,await this.saveSettings(),this.showChangeLog())}showChangeLog(){new DN(this.app,this.manifest.version).open()}autoOpenMemos(){this.app.workspace.getLeavesOfType(Qr).length>0||this.settings.MobileAndDesktop==="Mobile"&&N.Platform.isDesktop||this.settings.MobileAndDesktop==="Desktop"&&N.Platform.isMobile||this.settings.OpenMemosAutomatically&&this.openMemos()}async openDailyMemo(){if(this.app.workspace.getLeavesOfType(Qr).length>0){Ue.setPathname("/daily");return}await this.openMemos(),Ue.setPathname("/daily")}async openMemos(t="center",n){const r=this.app.workspace;if(r.getLeavesOfType(Qr).length>0){const a=r.getLeavesOfType(Qr)[0];return r.setActiveLeaf(a),r.revealLeaf(a),a}r.detachLeavesOfType(Qr);let o;switch(t){case"left":o=r.getLeftLeaf(!1);break;case"right":o=r.getRightLeaf(!1);break;case"float":o=r.getLeaf("window");break;default:o=r.getLeaf(!0);break}if(o)return await o.setViewState({type:Qr}),r.revealLeaf(o),o;const i=o.view.containerEl.querySelector("textarea");return i?(i.focus(),o):(n?.(),o)}async searchIt(){const t=this.app.workspace,n=t.getLeavesOfType(Qr);if(!(n.length>0)){const o=await this.openMemos();setTimeout(()=>{o.view.containerEl.find(".search-bar-inputer .text-input").focus(),this.app.workspace.trigger("focus-on-searchbar")},300);return}const r=n[0];t.revealLeaf(r),setTimeout(()=>{r.view.containerEl.find(".search-bar-inputer .text-input").focus(),this.app.workspace.trigger("focus-on-searchbar")},300)}async focusOnEditor(){if(!(this.app.workspace.getLeavesOfType(Qr).length>0)){await this.openMemos();return}this.app.workspace.trigger("focus-on-textarea")}changeStatus(){const t=this.app.workspace,n=t.getLeavesOfType(Qr);if(!(n.length>0)){new N.Notice(E("Please Open Memos First"));return}const r=n[0];t.setActiveLeaf(r),r.view.containerEl.querySelector(".list-or-task").click()}async showInPopover(){const t=this.app.workspace;if(t.detachLeavesOfType(Qr),!this.app.plugins.getPlugin("obsidian-hover-editor")){new N.Notice(E("Please install obsidian-hover-editor plugin first"));return}const r=await this.app.plugins.getPlugin("obsidian-hover-editor")?.spawnPopover();r&&(await r.setViewState({type:Qr}),t.revealLeaf(r),r.view.containerEl.classList.add("mobile-view"),this.settings?.FocusOnEditor&&r.view.containerEl.querySelector("textarea")!==void 0&&r.view.containerEl.querySelector("textarea")?.focus())}}class DN extends N.Modal{constructor(t,n){super(t),this.version=n}component;async onOpen(){const{contentEl:t}=this;this.containerEl.toggleClass("thino-changelog-modal",!0),t.createEl("h2",{text:E("Thino update info"),cls:"thino-changelog-title"}).createDiv({cls:"thino-changelog-version",text:`${this.version}`});try{t.createEl("h3",{text:E("Latest version")});const r=t.createDiv("current-change-log");t.createEl("hr"),t.createEl("h3",{text:E("Previous version")});const o=t.createDiv("prev-change-log"),a=await N.requestUrl("https://raw.githubusercontent.com/Quorafind/Obsidian-Thino/main/CHANGELOG.md");this.component=new N.Component;const[s,l]=this.getLatestVersionContent(a.text);let u=s,d=l;try{const h=localStorage.getItem("language"),p=h&&(h==="zh"||h==="zh-TW");u=p?s.replaceAll("> [!tips]+","> [!tips]-").replaceAll("> [!note]-","> [!note]+"):s,d=p?l.replaceAll("> [!tips]+","> [!tips]-").replaceAll("> [!note]-","> [!note]+"):l}catch(h){console.error(h)}await N.MarkdownRenderer.render(this.app,u,r,"",this.component),await N.MarkdownRenderer.render(this.app,d,o,"",this.component)}catch(r){console.error(r),t.createEl("p",{text:E("Failed to load changelog")}),t.createEl("a",{text:E("View online"),attr:{href:"https://raw.githubusercontent.com/Quorafind/Obsidian-Thino/main/CHANGELOG.md",target:"_blank"}})}}getLatestVersionContent(t){const n=/^# .+/gm,r=[...t.matchAll(n)];if(r.length===0)return[t,""];const o=r[0].index||0;let i=t.length;r.length>1&&(i=r[1].index||t.length);const a=t.substring(o,i).trim(),s=t.substring(i).trim();return[a,s]}onClose(){const{contentEl:t}=this;t.empty(),this.component?.unload()}}class sZ extends N.Modal{constructor(t,n,r){super(t),this.title=n,this.callback=r}inputEl;callback;onOpen(){const{contentEl:t}=this;this.setTitle(this.title),this.containerEl.toggleClass(["thino-input-dialog","thino-bulk-action-dialog","tag-actions"],!0),this.inputEl=t.createEl("input",{attr:{type:"text"}}),this.inputEl.focus(),new N.Setting(t).addButton(n=>{n.setButtonText(E("OK")).onClick(()=>{this.close()})})}onClose(){this.contentEl.empty(),this.callback(this.inputEl.value)}}exports.ChangeLogModal=DN;exports.InputModal=sZ;exports.default=vet;exports.getCurrentDebugInfo=MN;
|
|
|
|
|
|
/* nosourcemap */ |