PageSourceSearch

https://app.termina.ai/_next/static/chunks/3808-a1e876c8d7d21b96.js

js termina.ai collected 2026-09-28 10:16:52 UTC 442,517 bytes, 2 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3808],{87728:function(e){"use strict";e.exports=function(e,t,n,r){var i=-1,s=null==e?0:e.length;for(r&&s&&(n=e[++i]);++i<s;)n=t(n,e[i],i,e);return n}},62098:function(e){"use strict";e.exports=function(e){return e.split("")}},2880:function(e){"use strict";var t=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;e.exports=function(e){return e.match(t)||[]}},66352:function(e){"use strict";e.exports=function(e){return function(t){return null==e?void 0:e[t]}}},18795:function(e){"use strict";e.exports=function(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),(n=n>i?i:n)<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var s=Array(i);++r<i;)s[r]=e[r+t];return s}},29974:function(e,t,n){"use strict";var r=n(87929),i=n(29354),s=n(9251),o=n(71844),l=1/0,a=r?r.prototype:void 0,u=a?a.toString:void 0;e.exports=function e(t){if("string"==typeof t)return t;if(s(t))return i(t,e)+"";if(o(t))return u?u.call(t):"";var n=t+"";return"0"==n&&1/t==-l?"-0":n}},67768:function(e,t,n){"use strict";var r=n(18795);e.exports=function(e,t,n){var i=e.length;return n=void 0===n?i:n,!t&&n>=i?e:r(e,t,n)}},55823:function(e,t,n){"use strict";var r=n(67768),i=n(27417),s=n(70598),o=n(74422);e.exports=function(e){return function(t){var n=i(t=o(t))?s(t):void 0,l=n?n[0]:t.charAt(0),a=n?r(n,1).join(""):t.slice(1);return l[e]()+a}}},54523:function(e,t,n){"use strict";var r=n(87728),i=n(47806),s=n(36418),o=RegExp("['’]","g");e.exports=function(e){return function(t){return r(s(i(t).replace(o,"")),e,"")}}},12268:function(e,t,n){"use strict";var r=n(66352)({À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"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",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"});e.exports=r},27417:function(e){"use strict";var t=RegExp("[\\u200d\ud800-\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");e.exports=function(e){return t.test(e)}},13119:function(e){"use strict";var t=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;e.exports=function(e){return t.test(e)}},70598:function(e,t,n){"use strict";var r=n(62098),i=n(27417),s=n(66491);e.exports=function(e){return i(e)?s(e):r(e)}},66491:function(e){"use strict";var t="\ud800-\udfff",n="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",r="\ud83c[\udffb-\udfff]",i="[^"+t+"]",s="(?:\ud83c[\udde6-\uddff]){2}",o="[\ud800-\udbff][\udc00-\udfff]",l="(?:"+n+"|"+r+")?",a="[\\ufe0e\\ufe0f]?",u="(?:\\u200d(?:"+[i,s,o].join("|")+")"+a+l+")*",c=RegExp(r+"(?="+r+")|(?:"+[i+n+"?",n,s,o,"["+t+"]"].join("|")+")"+(a+l+u),"g");e.exports=function(e){return e.match(c)||[]}},48681:function(e){"use strict";var t="\ud800-\udfff",n="\\u2700-\\u27bf",r="a-z\\xdf-\\xf6\\xf8-\\xff",i="A-Z\\xc0-\\xd6\\xd8-\\xde",s="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",o="['’]",l="["+s+"]",a="["+r+"]",u="[^"+t+s+"\\d+"+n+r+i+"]",c="(?:\ud83c[\udde6-\uddff]){2}",d="[\ud800-\udbff][\udc00-\udfff]",h="["+i+"]",f="(?:"+a+"|"+u+")",p="(?:"+o+"(?:d|ll|m|re|s|t|ve))?",g="(?:"+o+"(?:D|LL|M|RE|S|T|VE))?",m="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\ud83c[\udffb-\udfff])?",y="[\\ufe0e\\ufe0f]?",v="(?:\\u200d(?:"+["[^"+t+"]",c,d].join("|")+")"+y+m+")*",_="(?:"+["["+n+"]",c,d].join("|")+")"+(y+m+v),b=RegExp([h+"?"+a+"+"+p+"(?="+[l,h,"$"].join("|")+")","(?:"+h+"|"+u+")+"+g+"(?="+[l,h+f,"$"].join("|")+")",h+"?"+f+"+"+p,h+"+"+g,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])","\\d+",_].join("|"),"g");e.exports=function(e){return e.match(b)||[]}},47806:function(e,t,n){"use strict";var r=n(12268),i=n(74422),s=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u01
17f]/g,o=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");e.exports=function(e){return(e=i(e))&&e.replace(s,r).replace(o,"")}},89211:function(e,t,n){"use strict";var r=n(54523),i=n(86528),s=r(function(e,t,n){return e+(n?" ":"")+i(t)});e.exports=s},74422:function(e,t,n){"use strict";var r=n(29974);e.exports=function(e){return null==e?"":r(e)}},86528:function(e,t,n){"use strict";var r=n(55823)("toUpperCase");e.exports=r},36418:function(e,t,n){"use strict";var r=n(2880),i=n(13119),s=n(74422),o=n(48681);e.exports=function(e,t,n){return(e=s(e),void 0===(t=n?void 0:t))?i(e)?o(e):r(e):e.match(t)||[]}},44184:function(){Prism.languages.c=Prism.languages.extend("clike",{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),Prism.languages.insertBefore("c","string",{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),Prism.languages.insertBefore("c","string",{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},Prism.languages.c.string],char:Prism.languages.c.char,comment:Prism.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:"function"}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:"keyword"},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:Prism.languages.c}}}}),Prism.languages.insertBefore("c","function",{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete Prism.languages.c.boolean},93109:function(){Prism.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/}},3793:function(){var e,t,n;e=Prism,t=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,n=/\b(?!<keyword>)\w+(?:\s*\.\s*\w+)*\b/.source.replace(/<keyword>/g,function(){return t.source}),e.languages.cpp=e.languages.extend("c",{"class-name":[{pattern:RegExp(/(\b(?:class|concept|enum|struct|typename)\s+)(?!<keyword>)\w+/.source.replace(/<keyword>/g,function(){return t.source})),lookbehind:!0}
vendor: 4,156 bytes, line 1
1,/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:t,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),e.languages.insertBefore("cpp","string",{module:{pattern:RegExp(/(\b(?:import|module)\s+)/.source+"(?:"+/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source+"|"+/<mod-name>(?:\s*:\s*<mod-name>)?|:\s*<mod-name>/.source.replace(/<mod-name>/g,function(){return n})+")"),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:"string",greedy:!0}}),e.languages.insertBefore("cpp","keyword",{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:e.languages.cpp}}}}),e.languages.insertBefore("cpp","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}}),e.languages.insertBefore("cpp","class-name",{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:e.languages.extend("cpp",{})}}),e.languages.insertBefore("inside","double-colon",{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},e.languages.cpp["base-clause"])},96912:function(){var e,t,n;t=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/,(e=Prism).languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+t.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+t.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+t.source+"$"),alias:"url"}}},selector:{pattern:RegExp("(^|[{}\\s])[^{}\\s](?:[^{};\"'\\s]|\\s+(?![\\s{])|"+t.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:t,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},e.languages.css.atrule.inside.rest=e.languages.css,(n=e.languages.markup)&&(n.tag.addInlined("style","css"),n.tag.addAttribute("style","css"))},12829:function(){var e,t,n,r;e=Prism,t=/\b(?:abstract|assert|boolean|break|byte|case|catch|char|class|const|continue|default|do|double|else|enum|exports|extends|final|finally|float|for|goto|if|implements|import|instanceof|int|interface|long|module|native|new|non-sealed|null|open|opens|package|permits|private|protected|provides|public|record(?!\s*[(){}[\]<>=%~.:,;?+\-*/&|^])|requires|return|sealed|short|static|strictfp|super|switch|synchronized|this|throw|throws|to|transient|transitive|try|uses|var|void|volatile|while|with|yield)\b/,n=/(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source,r={pattern:RegExp(/(^|[^\w.])/.source+n+/[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),lookbehind:!0,inside:{namespace:{pattern:/^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,inside:{punctuation:/\./}},punctuation:/\./}},e.languages.java=e.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"/,lookbehind:!0,greedy:!0},"class-name":[r,{pattern:RegExp(/(^|[^\w.])/.source+n+/[A-Z]\w*(?=\s+\w+\s*[;,=()]|\s*(?:\[[\s,]*\]\s*)?::\s*new\b)/.source),lookbehind:!0,inside:r.inside},{pattern:RegExp(/(\b(?:class|enum|extends|implements|instanceof|interface|new|record|throws)\s+)/.source+n+/[A-Z]\w*\b/.source),lookbehind:!0,inside:r.inside}],keyword:t,function:[e.languages.clike.function,{pattern:/(::\s*)[a-z_]\w
1*/,lookbehind:!0}],number:/\b0b[01][01_]*L?\b|\b0x(?:\.[\da-f_p+-]+|[\da-f_]+(?:\.[\da-f_p+-]+)?)\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfl]?/i,operator:{pattern:/(^|[^.])(?:<<=?|>>>?=?|->|--|\+\+|&&|\|\||::|[?:~]|[-+*/%&|^!=<>]=?)/m,lookbehind:!0},constant:/\b[A-Z][A-Z_\d]+\b/}),e.languages.insertBefore("java","string",{"triple-quoted-string":{pattern:/"""[ \t]*[\r\n](?:(?:"|"")?(?:\\.|[^"\\]))*"""/,greedy:!0,alias:"string"},char:{pattern:/'(?:\\.|[^'\\\r\n]){1,6}'/,greedy:!0}}),e.languages.insertBefore("java","class-name",{annotation:{pattern:/(^|[^.])@\w+(?:\s*\.\s*\w+)*/,lookbehind:!0,alias:"punctuation"},generics:{pattern:/<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&))*>)*>)*>)*>/,inside:{"class-name":r,keyword:t,punctuation:/[<>(),.:]/,operator:/[?&|]/}},import:[{pattern:RegExp(/(\bimport\s+)/.source+n+/(?:[A-Z]\w*|\*)(?=\s*;)/.source),lookbehind:!0,inside:{namespace:r.inside.namespace,punctuation:/\./,operator:/\*/,"class-name":/\w+/}},{pattern:RegExp(/(\bimport\s+static\s+)/.source+n+/(?:\w+|\*)(?=\s*;)/.source),lookbehind:!0,alias:"static",inside:{namespace:r.inside.namespace,static:/\b\w+$/,punctuation:/\./,operator:/\*/,"class-name":/\w+/}}],namespace:{pattern:RegExp(/(\b(?:exports|import(?:\s+static)?|module|open|opens|package|provides|requires|to|transitive|uses|with)\s+)(?!<keyword>)[a-z]\w*(?:\.[a-z]\w*)*\.?/.source.replace(/<keyword>/g,function(){return t.source})),lookbehind:!0,inside:{punctuation:/\./}}})},96090:function(){Prism.languages.javascript=Prism.languages.extend("clike",{"class-name":[Prism.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+(/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|")+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),Prism.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,Prism.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:Prism.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:Prism.languages.javascript}
vendor: 4,978 bytes, line 1
1,{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:Prism.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),Prism.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:Prism.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),Prism.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),Prism.languages.markup&&(Prism.languages.markup.tag.addInlined("script","javascript"),Prism.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),Prism.languages.js=Prism.languages.javascript},44643:function(){!function(e){var t=/(?:\\.|[^\\\n\r]|(?:\n|\r\n?)(?![\r\n]))/.source;function n(e){return e=e.replace(/<inner>/g,function(){return t}),RegExp(/((?:^|[^\\])(?:\\{2})*)/.source+"(?:"+e+")")}var r=/(?:\\.|``(?:[^`\r\n]|`(?!`))+``|`[^`\r\n]+`|[^\\|\r\n`])+/.source,i=/\|?__(?:\|__)+\|?(?:(?:\n|\r\n?)|(?![\s\S]))/.source.replace(/__/g,function(){return r}),s=/\|?[ \t]*:?-{3,}:?[ \t]*(?:\|[ \t]*:?-{3,}:?[ \t]*)+\|?(?:\n|\r\n?)/.source;e.languages.markdown=e.languages.extend("markup",{}),e.languages.insertBefore("markdown","prolog",{"front-matter-block":{pattern:/(^(?:\s*[\r\n])?)---(?!.)[\s\S]*?[\r\n]---(?!.)/,lookbehind:!0,greedy:!0,inside:{punctuation:/^---|---$/,"front-matter":{pattern:/\S+(?:\s+\S+)*/,alias:["yaml","language-yaml"],inside:e.languages.yaml}}},blockquote:{pattern:/^>(?:[\t ]*>)*/m,alias:"punctuation"},table:{pattern:RegExp("^"+i+s+"(?:"+i+")*","m"),inside:{"table-data-rows":{pattern:RegExp("^("+i+s+")(?:"+i+")*$"),lookbehind:!0,inside:{"table-data":{pattern:RegExp(r),inside:e.languages.markdown},punctuation:/\|/}},"table-line":{pattern:RegExp("^("+i+")"+s+"$"),lookbehind:!0,inside:{punctuation:/\||:?-{3,}:?/}},"table-header-row":{pattern:RegExp("^"+i+"$"),inside:{"table-header":{pattern:RegExp(r),alias:"important",inside:e.languages.markdown},punctuation:/\|/}}}},code:[{pattern:/((?:^|\n)[ \t]*\n|(?:^|\r\n?)[ \t]*\r\n?)(?: {4}|\t).+(?:(?:\n|\r\n?)(?: {4}|\t).+)*/,lookbehind:!0,alias:"keyword"},{pattern:/^```[\s\S]*?^```$/m,greedy:!0,inside:{"code-block":{pattern:/^(```.*(?:\n|\r\n?))[\s\S]+?(?=(?:\n|\r\n?)^```$)/m,lookbehind:!0},"code-language":{pattern:/^(```).+/,lookbehind:!0},punctuation:/```/}}],title:[{pattern:/\S.*(?:\n|\r\n?)(?:==+|--+)(?=[ \t]*$)/m,alias:"important",inside:{punctuation:/==+$|--+$/}},{pattern:/(^\s*)#.+/m,lookbehind:!0,alias:"important",inside:{punctuation:/^#+|#+$/}}],hr:{pattern:/(^\s*)([*-])(?:[\t ]*\2){2,}(?=\s*$)/m,lookbehind:!0,alias:"punctuation"},list:{pattern:/(^\s*)(?:[*+-]|\d+\.)(?=[\t ].)/m,lookbehind:!0,alias:"punctuation"},"url-reference":{pattern:/!?\[[^\]]+\]:[\t ]+(?:\S+|<(?:\\.|[^>\\])+>)(?:[\t ]+(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\)))?/,inside:{variable:{pattern:/^(!?\[)[^\]]+/,lookbehind:!0},string:/(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\))$/,punctuation:/^[\[\]!:]|[<>]/},alias:"url"},bold:{pattern:n(/\b__(?:(?!_)<inner>|_(?:(?!_)<inner>)+_)+__\b|\*\*(?:(?!\*)<inner>|\*(?:(?!\*)<inner>)+\*)+\*\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^..)[\s\S]+(?=..$)/,lookbehind:!0,inside:{}},punctuation:/\*\*|__/}},italic:{pattern:n(/\b_(?:(?!_)<inner>|__(?:(?!_)<inner>)+__)+_\b|\*(?:(?!\*)<inner>|\*\*(?:(?!\*)<inner>)+\*\*)+\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^.)[\s\S]+(?=.$)/,lookbehind:!0,inside:{}},punctuation:/[*_]/}},strike:{pattern:n(/(~~?)(?:(?!~)<inner>)+\2/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^~~?)[\s\S]+(?=\1$)/,lookbehind:!0,inside:{}},punctuation:/~~?/}}
1,"code-snippet":{pattern:/(^|[^\\`])(?:``[^`\r\n]+(?:`[^`\r\n]+)*``(?!`)|`[^`\r\n]+`(?!`))/,lookbehind:!0,greedy:!0,alias:["code","keyword"]},url:{pattern:n(/!?\[(?:(?!\])<inner>)+\](?:\([^\s)]+(?:[\t ]+"(?:\\.|[^"\\])*")?\)|[ \t]?\[(?:(?!\])<inner>)+\])/.source),lookbehind:!0,greedy:!0,inside:{operator:/^!/,content:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0,inside:{}},variable:{pattern:/(^\][ \t]?\[)[^\]]+(?=\]$)/,lookbehind:!0},url:{pattern:/(^\]\()[^\s)]+/,lookbehind:!0},string:{pattern:/(^[ \t]+)"(?:\\.|[^"\\])*"(?=\)$)/,lookbehind:!0}}}}),["url","bold","italic","strike"].forEach(function(t){["url","bold","italic","strike","code-snippet"].forEach(function(n){t!==n&&(e.languages.markdown[t].inside.content.inside[n]=e.languages.markdown[n])})}),e.hooks.add("after-tokenize",function(e){("markdown"===e.language||"md"===e.language)&&function e(t){if(t&&"string"!=typeof t)for(var n=0,r=t.length;n<r;n++){var i=t[n];if("code"!==i.type){e(i.content);continue}var s=i.content[1],o=i.content[3];if(s&&o&&"code-language"===s.type&&"code-block"===o.type&&"string"==typeof s.content){var l=s.content.replace(/\b#/g,"sharp").replace(/\b\+\+/g,"pp"),a="language-"+(l=(/[a-z][\w-]*/i.exec(l)||[""])[0].toLowerCase());o.alias?"string"==typeof o.alias?o.alias=[o.alias,a]:o.alias.push(a):o.alias=[a]}}}(e.tokens)}),e.hooks.add("wrap",function(t){if("code-block"===t.type){for(var n,r="",i=0,s=t.classes.length;i<s;i++){var u=t.classes[i],c=/language-(.+)/.exec(u);if(c){r=c[1];break}}var d=e.languages[r];if(d)t.content=e.highlight(t.content.replace(o,"").replace(/&(\w{1,8}|#x?[\da-f]{1,8});/gi,function(e,t){return"#"===(t=t.toLowerCase())[0]?a("x"===t[1]?parseInt(t.slice(2),16):Number(t.slice(1))):l[t]||e}),d,r);else if(r&&"none"!==r&&e.plugins.autoloader){var h="md-"+new Date().valueOf()+"-"+Math.floor(1e16*Math.random());t.attributes.id=h,e.plugins.autoloader.loadLanguages(r,function(){var t=document.getElementById(h);t&&(t.innerHTML=e.highlight(t.textContent,e.languages[r],r))})}}});var o=RegExp(e.languages.markup.tag.pattern.source,"gi"),l={amp:"&",lt:"<",gt:">",quot:'"'},a=String.fromCodePoint||String.fromCharCode;e.languages.md=e.languages.markdown}(Prism)},20397:function(){Prism.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},Prism.languages.markup.tag.inside["attr-value"].inside.entity=Prism.languages.markup.entity,Prism.languages.markup.doctype.inside["internal-subset"].inside=Prism.languages.markup,Prism.hooks.add("wrap",function(e){"entity"===e.type&&(e.attributes.title=e.content.replace(/&amp;/,"&"))}),Object.defineProperty(Prism.languages.markup.tag,"addInlined",{value:function(e,t){var n={};n["language-"+t]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:Prism.languages[t]},n.cdata=/^<!\[CDATA\[|\]\]>$/i;var r={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:n}};r["language-"+t]={pattern:/[\s\S]+/,inside:Prism.languages[t]};var i={};i[e]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return e}),"i"),lookbehind:!0,greedy:!0,inside:r},Prism.languages.insertBefore("markup","cdata",i)}}),Object.defineProperty(Prism.languages.markup.tag,"addAttribute",{value:function(e,t){Prism.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+e+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\
1s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[t,"language-"+t],inside:Prism.languages[t]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),Prism.languages.html=Prism.languages.markup,Prism.languages.mathml=Prism.languages.markup,Prism.languages.svg=Prism.languages.markup,Prism.languages.xml=Prism.languages.extend("markup",{}),Prism.languages.ssml=Prism.languages.xml,Prism.languages.atom=Prism.languages.xml,Prism.languages.rss=Prism.languages.xml},78131:function(){Prism.languages.objectivec=Prism.languages.extend("c",{string:{pattern:/@?"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},keyword:/\b(?:asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|in|inline|int|long|register|return|self|short|signed|sizeof|static|struct|super|switch|typedef|typeof|union|unsigned|void|volatile|while)\b|(?:@interface|@end|@implementation|@protocol|@class|@public|@protected|@private|@property|@try|@catch|@finally|@throw|@synthesize|@dynamic|@selector)\b/,operator:/-[->]?|\+\+?|!=?|<<?=?|>>?=?|==?|&&?|\|\|?|[~^%?*\/@]/}),delete Prism.languages.objectivec["class-name"],Prism.languages.objc=Prism.languages.objectivec},5731:function(){var e;(e=Prism.languages.powershell={comment:[{pattern:/(^|[^`])<#[\s\S]*?#>/,lookbehind:!0},{pattern:/(^|[^`])#.*/,lookbehind:!0}],string:[{pattern:/"(?:`[\s\S]|[^`"])*"/,greedy:!0,inside:null},{pattern:/'(?:[^']|'')*'/,greedy:!0}],namespace:/\[[a-z](?:\[(?:\[[^\]]*\]|[^\[\]])*\]|[^\[\]])*\]/i,boolean:/\$(?:false|true)\b/i,variable:/\$\w+\b/,function:[/\b(?:Add|Approve|Assert|Backup|Block|Checkpoint|Clear|Close|Compare|Complete|Compress|Confirm|Connect|Convert|ConvertFrom|ConvertTo|Copy|Debug|Deny|Disable|Disconnect|Dismount|Edit|Enable|Enter|Exit|Expand|Export|Find|ForEach|Format|Get|Grant|Group|Hide|Import|Initialize|Install|Invoke|Join|Limit|Lock|Measure|Merge|Move|New|Open|Optimize|Out|Ping|Pop|Protect|Publish|Push|Read|Receive|Redo|Register|Remove|Rename|Repair|Request|Reset|Resize|Resolve|Restart|Restore|Resume|Revoke|Save|Search|Select|Send|Set|Show|Skip|Sort|Split|Start|Step|Stop|Submit|Suspend|Switch|Sync|Tee|Test|Trace|Unblock|Undo|Uninstall|Unlock|Unprotect|Unpublish|Unregister|Update|Use|Wait|Watch|Where|Write)-[a-z]+\b/i,/\b(?:ac|cat|chdir|clc|cli|clp|clv|compare|copy|cp|cpi|cpp|cvpa|dbp|del|diff|dir|ebp|echo|epal|epcsv|epsn|erase|fc|fl|ft|fw|gal|gbp|gc|gci|gcs|gdr|gi|gl|gm|gp|gps|group|gsv|gu|gv|gwmi|iex|ii|ipal|ipcsv|ipsn|irm|iwmi|iwr|kill|lp|ls|measure|mi|mount|move|mp|mv|nal|ndr|ni|nv|ogv|popd|ps|pushd|pwd|rbp|rd|rdr|ren|ri|rm|rmdir|rni|rnp|rp|rv|rvpa|rwmi|sal|saps|sasv|sbp|sc|select|set|shcm|si|sl|sleep|sls|sort|sp|spps|spsv|start|sv|swmi|tee|trcm|type|write)\b/i],keyword:/\b(?:Begin|Break|Catch|Class|Continue|Data|Define|Do|DynamicParam|Else|ElseIf|End|Exit|Filter|Finally|For|ForEach|From|Function|If|InlineScript|Parallel|Param|Process|Return|Sequence|Switch|Throw|Trap|Try|Until|Using|Var|While|Workflow)\b/i,operator:{pattern:/(^|\W)(?:!|-(?:b?(?:and|x?or)|as|(?:Not)?(?:Contains|In|Like|Match)|eq|ge|gt|is(?:Not)?|Join|le|lt|ne|not|Replace|sh[lr])\b|-[-=]?|\+[+=]?|[*\/%]=?)/i,lookbehind:!0},punctuation:/[|{}[\];(),.]/}).string[0].inside={function:{pattern:/(^|[^`])\$\((?:\$\([^\r\n()]*\)|(?!\$\()[^\r\n)])*\)/,lookbehind:!0,inside:e},boolean:e.boolean,variable:e.variable}},23975:function(){Prism.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01
1])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},Prism.languages.python["string-interpolation"].inside.interpolation.inside.rest=Prism.languages.python,Prism.languages.py=Prism.languages.python},7968:function(){!function(e){for(var t=/\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|<self>)*\*\//.source,n=0;n<2;n++)t=t.replace(/<self>/g,function(){return t});t=t.replace(/<self>/g,function(){return/[^\s\S]/.source}),e.languages.rust={comment:[{pattern:RegExp(/(^|[^\\])/.source+t),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:"attr-name",inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:"punctuation"},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:"symbol"},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:"punctuation"},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:"function"},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:"class-name"},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:"namespace"},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:"namespace",inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:"property"},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?=?|[@?]/},e.languages.rust["closure-params"].inside.rest=e.languages.rust,e.languages.rust.attribute.inside.string=e.languages.rust.string}(Prism)},67145:function(){Prism.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ER
1RLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/}},83557:function(){Prism.languages.swift={comment:{pattern:/(^|[^\\:])(?:\/\/.*|\/\*(?:[^/*]|\/(?!\*)|\*(?!\/)|\/\*(?:[^*]|\*(?!\/))*\*\/)*\*\/)/,lookbehind:!0,greedy:!0},"string-literal":[{pattern:RegExp(/(^|[^"#])/.source+"(?:"+/"(?:\\(?:\((?:[^()]|\([^()]*\))*\)|\r\n|[^(])|[^\\\r\n"])*"/.source+"|"+/"""(?:\\(?:\((?:[^()]|\([^()]*\))*\)|[^(])|[^\\"]|"(?!""))*"""/.source+")"+/(?!["#])/.source),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\\($/,alias:"punctuation"},punctuation:/\\(?=[\r\n])/,string:/[\s\S]+/}},{pattern:RegExp(/(^|[^"#])(#+)/.source+"(?:"+/"(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|\r\n|[^#])|[^\\\r\n])*?"/.source+"|"+/"""(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|[^#])|[^\\])*?"""/.source+")\\2"),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\#+\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\#+\($/,alias:"punctuation"},string:/[\s\S]+/}}],directive:{pattern:RegExp(/#/.source+"(?:"+/(?:elseif|if)\b/.source+"(?:[ 	]*"+/(?:![ \t]*)?(?:\b\w+\b(?:[ \t]*\((?:[^()]|\([^()]*\))*\))?|\((?:[^()]|\([^()]*\))*\))(?:[ \t]*(?:&&|\|\|))?/.source+")+|"+/(?:else|endif)\b/.source+")"),alias:"property",inside:{"directive-name":/^#\w+/,boolean:/\b(?:false|true)\b/,number:/\b\d+(?:\.\d+)*\b/,operator:/!|&&|\|\||[<>]=?/,punctuation:/[(),]/}},literal:{pattern:/#(?:colorLiteral|column|dsohandle|file(?:ID|Literal|Path)?|function|imageLiteral|line)\b/,alias:"constant"},"other-directive":{pattern:/#\w+\b/,alias:"property"},attribute:{pattern:/@\w+/,alias:"atrule"},"function-definition":{pattern:/(\bfunc\s+)\w+/,lookbehind:!0,alias:"function"},label:{pattern:/\b(break|continue)\s+\w+|\b[a-zA-Z_]\w*(?=\s*:\s*(?:for|repeat|while)\b)/,lookbehind:!0,alias:"important"},keyword:/\b(?:Any|Protocol|Self|Type|actor|as|assignment|associatedtype|associativity|async|await|break|case|catch|class|continue|convenience|default|defer|deinit|didSet|do|dynamic|else|enum|extension|fallthrough|fileprivate|final|for|func|get|guard|higherThan|if|import|in|indirect|infix|init|inout|internal|is|isolated|lazy|left|let|lowerThan|mutating|none|nonisolated|nonmutating|open|operator|optional|override|postfix|precedencegroup|prefix|private|protocol|public|repeat|required|rethrows|return|right|safe|self|set|some|static|struct|subscript|super|switch|throw|throws|try|typealias|unowned|unsafe|var|weak|where|while|willSet)\b/,boolean:/\b(?:false|true)\b/,nil:{pattern:/\bnil\b/,alias:"constant"},"short-argument":/\$\d+\b/,omit:{pattern:/\b_\b/,alias:"keyword"},number:/\b(?:[\d_]+(?:\.[\de_]+)?|0x[a-f0-9_]+(?:\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i,"class-name":/\b[A-Z](?:[A-Z_\d]*[a-z]\w*)?\b/,function:/\b[a-z_]\w*(?=\s*\()/i,constant:/\b(?:[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/,operator:/[-+*/%=!<>&|^~?]+|\.[.\-+*/%=!<>&|^~?]+/,punctuation:/[{}[\]();,.:\\]/},Prism.languages.swift["string-literal"].forEach(function(e){e.inside.interpolation.inside=Prism.languages.swift})},31699:function(){var e,t;(e=Prism).languages.typescript=e.languages.extend("javascript",{"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),e.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete e.languages.typescript.parameter,delete e.languages.typescript["literal-property"],t=e.languages.extend("typescript",{}),delete t["class-name"],e.languages.typescript["class-name"].inside=t,e.languages.insertBefore("typescript","function",{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:"operator"},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:t}}}}),e.languages.ts=e.languages.typescript},25708:function(e,t,n){var r,i,s=function(e){var t=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,n=0,r={},i={manual:e.Prism&&e.Prism.manual,disableWorkerMessageHandler:e.Prism&&e.Prism.disableWorkerMessageHandler,util:{encode:function e(t){return t instanceof s?new s(t.type,e(t.content),t.alias):Array.isArray(t)?t.map(e):t.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/\u00a0/g," ")},type:function(e){return Object.prototype.toString.call(e).slice(8,-1)},objId:function(e){return e.__id||Object.defineProperty(e,"__id",{value:++n}),e.__id},clone:function e(t,n){var r,s;switch(n=n||{},i.util.type(t)){case"Object":if(n[s=i.util.objId(t)])return n[s];for(var o in r={},n[s]=r,t)t.hasOwnProperty(o)&&(r[o]=e(t[o],n));return r;case"Array":if(n[s=i.util.objId(t)])return n[s];return r=[],n[s]=r,t.forEach(function(t,i){r[i]=e(t,n)}),r;default:return t}},getLanguage:function(e){for(;e;){var n=t.exec(e.className);if(n)return n[1].toLowerCase();e=e.parentElement}return"none"},setLanguage:function(e,n){e.className=e.className.replace(RegExp(t,"gi"),""),e.classList.add("language-"+n)},currentScript:function(){if("undefined"==typeof document)return null;if(document.currentScript&&"SCRIPT"===document.currentScript.tagName)return document.currentScript;try{throw Error()}catch(r){var e=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(r.stack)||[])[1];if(e){var t=document.getElementsByTagName("script");for(var n in t)if(t[n].src==e)return t[n]}return null}},isActive:function(e,t,n){for(var r="no-"+t;e;){var i=e.classList;if(i.contains(t))return!0;
vendor: 6,451 bytes, line 1
1if(i.contains(r))return!1;e=e.parentElement}return!!n}},languages:{plain:r,plaintext:r,text:r,txt:r,extend:function(e,t){var n=i.util.clone(i.languages[e]);for(var r in t)n[r]=t[r];return n},insertBefore:function(e,t,n,r){var s=(r=r||i.languages)[e],o={};for(var l in s)if(s.hasOwnProperty(l)){if(l==t)for(var a in n)n.hasOwnProperty(a)&&(o[a]=n[a]);n.hasOwnProperty(l)||(o[l]=s[l])}var u=r[e];return r[e]=o,i.languages.DFS(i.languages,function(t,n){n===u&&t!=e&&(this[t]=o)}),o},DFS:function e(t,n,r,s){s=s||{};var o=i.util.objId;for(var l in t)if(t.hasOwnProperty(l)){n.call(t,l,t[l],r||l);var a=t[l],u=i.util.type(a);"Object"!==u||s[o(a)]?"Array"!==u||s[o(a)]||(s[o(a)]=!0,e(a,n,l,s)):(s[o(a)]=!0,e(a,n,null,s))}}},plugins:{},highlightAll:function(e,t){i.highlightAllUnder(document,e,t)},highlightAllUnder:function(e,t,n){var r={callback:n,container:e,selector:'code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'};i.hooks.run("before-highlightall",r),r.elements=Array.prototype.slice.apply(r.container.querySelectorAll(r.selector)),i.hooks.run("before-all-elements-highlight",r);for(var s,o=0;s=r.elements[o++];)i.highlightElement(s,!0===t,r.callback)},highlightElement:function(t,n,r){var s=i.util.getLanguage(t),o=i.languages[s];i.util.setLanguage(t,s);var l=t.parentElement;l&&"pre"===l.nodeName.toLowerCase()&&i.util.setLanguage(l,s);var a=t.textContent,u={element:t,language:s,grammar:o,code:a};function c(e){u.highlightedCode=e,i.hooks.run("before-insert",u),u.element.innerHTML=u.highlightedCode,i.hooks.run("after-highlight",u),i.hooks.run("complete",u),r&&r.call(u.element)}if(i.hooks.run("before-sanity-check",u),(l=u.element.parentElement)&&"pre"===l.nodeName.toLowerCase()&&!l.hasAttribute("tabindex")&&l.setAttribute("tabindex","0"),!u.code){i.hooks.run("complete",u),r&&r.call(u.element);return}if(i.hooks.run("before-highlight",u),!u.grammar){c(i.util.encode(u.code));return}if(n&&e.Worker){var d=new Worker(i.filename);d.onmessage=function(e){c(e.data)},d.postMessage(JSON.stringify({language:u.language,code:u.code,immediateClose:!0}))}else c(i.highlight(u.code,u.grammar,u.language))},highlight:function(e,t,n){var r={code:e,grammar:t,language:n};if(i.hooks.run("before-tokenize",r),!r.grammar)throw Error('The language "'+r.language+'" has no grammar.');return r.tokens=i.tokenize(r.code,r.grammar),i.hooks.run("after-tokenize",r),s.stringify(i.util.encode(r.tokens),r.language)},tokenize:function(e,t){var n=t.rest;if(n){for(var r in n)t[r]=n[r];delete t.rest}var u=new l;return a(u,u.head,e),function e(t,n,r,l,u,c){for(var d in r)if(r.hasOwnProperty(d)&&r[d]){var h=r[d];h=Array.isArray(h)?h:[h];for(var f=0;f<h.length;++f){if(c&&c.cause==d+","+f)return;var p=h[f],g=p.inside,m=!!p.lookbehind,y=!!p.greedy,v=p.alias;if(y&&!p.pattern.global){var _=p.pattern.toString().match(/[imsuy]*$/)[0];p.pattern=RegExp(p.pattern.source,_+"g")}for(var b=p.pattern||p,x=l.next,S=u;x!==n.tail&&(!c||!(S>=c.reach));S+=x.value.length,x=x.next){var w,E=x.value;if(n.length>t.length)return;if(!(E instanceof s)){var T=1;if(y){if(!(w=o(b,S,t,m))||w.index>=t.length)break;var C=w.index,k=w.index+w[0].length,A=S;for(A+=x.value.length;C>=A;)A+=(x=x.next).value.length;if(A-=x.value.length,S=A,x.value instanceof s)continue;for(var P=x;P!==n.tail&&(A<k||"string"==typeof P.value);P=P.next)T++,A+=P.value.length;T--,E=t.slice(S,A),w.index-=S}else if(!(w=o(b,0,E,m)))continue;var C=w.index,N=w[0],F=E.slice(0,C),O=E.slice(C+N.length),D=S+E.length;c&&D>c.reach&&(c.reach=D);var L=x.prev;if(F&&(L=a(n,L,F),S+=F.length),function(e,t,n){for(var r=t.next,i=0;i<n&&r!==e.tail;i++)r=r.next;t.next=r,r.prev=t,e.length-=i}(n,L,T),x=a(n,L,new s(d,g?i.tokenize(N,g):N,v,N)),O&&a(n,x,O),T>1){var I={cause:d+","+f,reach:D};e(t,n,r,x.prev,S,I),c&&I.reach>c.reach&&(c.reach=I.reach)}}}}}}(e,u,t,u.head,0),function(e){for(var t=[],n=e.head.next;n!==e.tail;)t.push(n.value),n=n.next;return t}(u)},hooks:{all:{},add:function(e,t){var n=i.hooks.all;n[e]=n[e]||[],n[e].push(t)},run:function(e,t){var n=i.hooks.all[e];if(n&&n.length)for(var r,s=0;r=n[s++];)r(t)}},Token:s};function s(e,t,n,r){this.type=e,this.content=t,this.alias=n,this.length=0|(r||"").length}function o(e,t,n,r){e.lastIndex=t;var i=e.exec(n);if(i&&r&&i[1]){var s=i[1].length;i.index+=s,i[0]=i[0].slice(s)}return i}function l(){var e={value:null,prev:null,next:null},t={value:null,prev:e,next:null};e.next=t,this.head=e,this.tail=t,this.length=0}function a(e,t,n){var r=t.next,i={value:n,prev:t,next:r};return t.next=i,r.prev=i,e.length++,i}if(e.Prism=i,s.stringify=function e(t,n){if("string"==typeof t)return t;if(Array.isArray(t)){var r="";return t.forEach(function(t){r+=e(t,n)}),r}var s={type:t.type,content:e(t.content,n),tag:"span",classes:["token",t.type],attributes:{},language:n},o=t.alias;o&&(Array.isArray(o)?Array.prototype.push.apply(s.classes,o):s.classes.push(o)),i.hooks.run("wrap",s);var l="";for(var a in s.attributes)l+=" "+a+'="'+(s.attributes[a]||"").replace(/"/g,"&quot;")+'"';return"<"+s.tag+' class="'+s.classes.join(" ")+'"'+l+">"+s.content+"</"+s.tag+">"},!e.document)return e.addEventListener&&(i.disableWorkerMessageHandler||e.addEventListener("message",function(t){var n=JSON.parse(t.data),r=n.language,s=n.code,o=n.immediateClose;e.postMessage(i.highlight(s,i.languages[r],r)),o&&e.close()},!1)),i;var u=i.util.currentScript();function c(){i.manual||i.highlightAll()}if(u&&(i.filename=u.src,u.hasAttribute("data-manual")&&(i.manual=!0)),!i.manual){var d=document.readyState;"loading"===d||"interactive"===d&&u&&u.defer?document.addEventListener("DOMContentLoaded",c):window.requestAnimationFrame?window.requestAnimationFrame(c):window.setTimeout(c,16)}return i}("undefined"!=typeof window?window:"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope?self:{});e.exports&&(e.exports=s),void 0!==n.g&&(n.g.Prism=s),s.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>
1\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},s.languages.markup.tag.inside["attr-value"].inside.entity=s.languages.markup.entity,s.languages.markup.doctype.inside["internal-subset"].inside=s.languages.markup,s.hooks.add("wrap",function(e){"entity"===e.type&&(e.attributes.title=e.content.replace(/&amp;/,"&"))}),Object.defineProperty(s.languages.markup.tag,"addInlined",{value:function(e,t){var n={};n["language-"+t]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:s.languages[t]},n.cdata=/^<!\[CDATA\[|\]\]>$/i;var r={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:n}};r["language-"+t]={pattern:/[\s\S]+/,inside:s.languages[t]};var i={};i[e]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return e}),"i"),lookbehind:!0,greedy:!0,inside:r},s.languages.insertBefore("markup","cdata",i)}}),Object.defineProperty(s.languages.markup.tag,"addAttribute",{value:function(e,t){s.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+e+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[t,"language-"+t],inside:s.languages[t]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),s.languages.html=s.languages.markup,s.languages.mathml=s.languages.markup,s.languages.svg=s.languages.markup,s.languages.xml=s.languages.extend("markup",{}),s.languages.ssml=s.languages.xml,s.languages.atom=s.languages.xml,s.languages.rss=s.languages.xml,r=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/,s.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+r.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+r.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+r.source+"$"),alias:"url"}}},selector:{pattern:RegExp("(^|[{}\\s])[^{}\\s](?:[^{};\"'\\s]|\\s+(?![\\s{])|"+r.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:r,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},s.languages.css.atrule.inside.rest=s.languages.css,(i=s.languages.markup)&&(i.tag.addInlined("style","css"),i.tag.addAttribute("style","css")),s.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},s.languages.javascript=s.languages.extend("clike",{"class-name":[s.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+(/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|")+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?
1:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),s.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,s.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:s.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:s.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:s.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:s.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:s.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),s.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:s.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),s.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),s.languages.markup&&(s.languages.markup.tag.addInlined("script","javascript"),s.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),s.languages.js=s.languages.javascript,function(){if(void 0!==s&&"undefined"!=typeof document){Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var e={js:"javascript",py:"python",rb:"ruby",ps1:"powershell",psm1:"powershell",sh:"bash",bat:"batch",h:"c",tex:"latex"},t="data-src-status",n="loading",r="loaded",i="pre[data-src]:not(["+t+'="'+r+'"]):not(['+t+'="'+n+'"])';s.hooks.add("before-highlightall",function(e){e.selector+=", "+i}),s.hooks.add("before-sanity-check",function(o){var l=o.element;if(l.matches(i)){o.code="",l.setAttribute(t,n);var a,u,c,d=l.appendChild(document.createElement("CODE"));d.textContent="Loading…";var h=l.getAttribute("data-src"),f=o.language;if("none"===f){var p=(/\.(\w+)$/.exec(h)||[,"none"])[1];f=e[p]||p}s.util.setLanguage(d,f),s.util.setLanguage(l,f);var g=s.plugins.autoloader;g&&g.loadLanguages(f),a=function(e){l.setAttribute(t,r);var n=function(e){var t=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(e||"");if(t){var n=Number(t[1]),r=t[2],i=t[3];return r?i?[n,Number(i)]:[n,void 0]:[n,n]}}(l.getAttribute("data-range"));if(n){var i=e.split(/\r\n?|\n/g),o=n[0],a=null==n[1]?i.length:n[1];o<0&&(o+=i.length),o=Math.max(0,Math.min(o-1,i.length)),a<0&&(a+=i.length),a=Math.max(0,Math.min(a,i.length)),e=i.slice(o,a).join("\n"),l.hasAttribute("data-start")||l.setAttribute("data-start",String(o+1))}d.textContent=e,s.highlightElement(d)},u=function(e){l.setAttribute(t,"failed"),d.textContent=e},(c=new XMLHttpRequest).open("GET",h,!0),c.onreadystatechange=function(){4==c.readyState&&(c.status<400&&c.responseText?a(c.responseText):c.status>=400?u("✖ Error "+c.status+" while fetching file: "+c.statusText):u("✖ Error: File does not exist or is empty"))},c.send(null)}}),s.plugins.fileHighlight={highlight:function(e){for(var t,n=(e||document).querySelectorAll(i),r=0;t=n[r++];)s.highlightElement(t)}};var o=!1;s.fileHighlight=function(){o||(console.warn("Prism.fileHighlight is deprecated. Use `Prism.plugins.fileHighlight.highlight` instead."),o=!0),s.plugins.fileHighlight.highlight.apply(this,arguments)}}}()},50371:function(e,t,n){"use strict";n.d(t,{B:function(){return r}});let r={Actual:"actual",Projected:"projected"}},54886:function(e,t,n){"use strict";n.d(t,{D:function(){return r}});let r={M:"M",Q:"Q",Sa:"SA",A:"A"}},50835:function(e,t,n){"use strict";n.d(t,{Ol:function(){return d},Pe:function(){return h},wg:function(){return c}});var r,i=n(18193),s=n(30913);n(25708),n(93109),n(96090),n(20397),n(44643),n(44184),n(96912),n(78131),n(67145),n(5731),n(23975),n(7968),n(83557),n(31699),n(12829),n(3793),"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self,(r=function(e){let t=new URLSearchParams;t.append("code",e);for(let e=1;e<arguments.length;e++)t.append("v",arguments[e]);throw Error(`Minified Lexical error #${e}; visit https://lexical.dev/docs/error?${t} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}).__esModule&&Object.prototype.hasOwnProperty.call(r,"default")&&r.default;let o=globalThis.Prism||window.Prism,l=e=>{try{return!!e&&o.languages.hasOwnProperty(e)}catch(e){return!1}},a="data-language",u="data-highlight-language";class c extends i.HX{static getType(){return"code"}static clone(e){return new c(e.__language,e.__key)}constructor(e,t){super(t),this.__language=e||void 0,this.__isSyntaxHighlightSupported=l(e)}createDOM(e){let t=document.createElement("code");
1(0,s.Yo)(t,e.theme.code),t.setAttribute("spellcheck","false");let n=this.getLanguage();return n&&(t.setAttribute(a,n),this.getIsSyntaxHighlightSupported()&&t.setAttribute(u,n)),t}updateDOM(e,t,n){let r=this.__language,i=e.__language;return r?r!==i&&(t.setAttribute(a,r),this.__isSyntaxHighlightSupported&&t.setAttribute(u,r)):i&&(t.removeAttribute(a),e.__isSyntaxHighlightSupported&&t.removeAttribute(u)),!1}exportDOM(e){let t=document.createElement("pre");(0,s.Yo)(t,e._config.theme.code),t.setAttribute("spellcheck","false");let n=this.getLanguage();return n&&(t.setAttribute(a,n),this.getIsSyntaxHighlightSupported()&&t.setAttribute(u,n)),{element:t}}static importDOM(){return{code:e=>null!=e.textContent&&(/\r?\n/.test(e.textContent)||function e(t,n){for(let r of t.childNodes){if((0,i.Re)(r)&&r.tagName===n)return!0;e(r,n)}return!1}(e,"BR"))?{conversion:f,priority:1}:null,div:()=>({conversion:p,priority:1}),pre:()=>({conversion:f,priority:0}),table:e=>v(e)?{conversion:g,priority:3}:null,td:e=>{let t=e.closest("table");return e.classList.contains("js-file-line")||t&&v(t)?{conversion:m,priority:3}:null},tr:e=>{let t=e.closest("table");return t&&v(t)?{conversion:m,priority:3}:null}}}static importJSON(e){return d().updateFromJSON(e)}updateFromJSON(e){return super.updateFromJSON(e).setLanguage(e.language)}exportJSON(){return{...super.exportJSON(),language:this.getLanguage()}}insertNewAfter(e,t=!0){let n=this.getChildren(),r=n.length;if(r>=2&&"\n"===n[r-1].getTextContent()&&"\n"===n[r-2].getTextContent()&&e.isCollapsed()&&e.anchor.key===this.__key&&e.anchor.offset===r){n[r-1].remove(),n[r-2].remove();let e=(0,i.BE)();return this.insertAfter(e,t),e}let{anchor:s,focus:o}=e,l=(s.isBefore(o)?s:o).getNode();if((0,i.Gg)(l)){let e=function(e){let t=e,n=e;for(;S(n)||(0,i.rc)(n);)t=n,n=n.getPreviousSibling();return t}(l),t=[];for(;;)if((0,i.rc)(e))t.push((0,i.S3)()),e=e.getNextSibling();else{if(!S(e))break;{let n=0,r=e.getTextContent(),i=e.getTextContentSize();for(;n<i&&" "===r[n];)n++;if(0!==n&&t.push(x(" ".repeat(n))),n!==i)break;e=e.getNextSibling()}}let n=l.splitText(s.offset)[0],r=0===s.offset?0:1,o=n.getIndexWithinParent()+r,a=l.getParentOrThrow(),u=[(0,i.T)(),...t];a.splice(o,0,u);let c=t[t.length-1];c?c.select():0===s.offset?n.selectPrevious():n.getNextSibling().selectNext(0,0)}if(h(l)){let{offset:t}=e.anchor;l.splice(t,0,[(0,i.T)()]),l.select(t+1,t+1)}return null}canIndent(){return!1}collapseAtStart(){let e=(0,i.BE)();
1return this.getChildren().forEach(t=>e.append(t)),this.replace(e),!0}setLanguage(e){let t=this.getWritable();return t.__language=e||void 0,t.__isSyntaxHighlightSupported=l(e),t}getLanguage(){return this.getLatest().__language}getIsSyntaxHighlightSupported(){return this.getLatest().__isSyntaxHighlightSupported}}function d(e){return(0,i.U2)(new c(e))}function h(e){return e instanceof c}function f(e){return{node:d(e.getAttribute(a))}}function p(e){let t=y(e);return t||function(e){let t=e.parentElement;for(;null!==t;){if(y(t))return!0;t=t.parentElement}return!1}(e)?{node:t?d():null}:{node:null}}function g(){return{node:d()}}function m(){return{node:null}}function y(e){return null!==e.style.fontFamily.match("monospace")}function v(e){return e.classList.contains("js-file-line-container")}class _ extends i.R2{constructor(e="",t,n){super(e,n),this.__highlightType=t}static getType(){return"code-highlight"}static clone(e){return new _(e.__text,e.__highlightType||void 0,e.__key)}getHighlightType(){return this.getLatest().__highlightType}setHighlightType(e){let t=this.getWritable();return t.__highlightType=e||void 0,t}canHaveFormat(){return!1}createDOM(e){let t=super.createDOM(e),n=b(e.theme,this.__highlightType);return(0,s.Yo)(t,n),t}updateDOM(e,t,n){let r=super.updateDOM(e,t,n),i=b(n.theme,e.__highlightType),o=b(n.theme,this.__highlightType);return i!==o&&(i&&(0,s.PS)(t,i),o&&(0,s.Yo)(t,o)),r}static importJSON(e){return x().updateFromJSON(e)}updateFromJSON(e){return super.updateFromJSON(e).setHighlightType(e.highlightType)}exportJSON(){return{...super.exportJSON(),highlightType:this.getHighlightType()}}setFormat(e){return this}isParentRequired(){return!0}createParentElementNode(){return d()}}function b(e,t){return t&&e&&e.codeHighlight&&e.codeHighlight[t]}function x(e="",t){return(0,i.U2)(new _(e,t))}function S(e){return e instanceof _}},74753:function(e,t,n){"use strict";n.d(t,{GR:function(){return a},Pq:function(){return d},Rf:function(){return y},k0:function(){return g},zV:function(){return c}});var r,i=n(30913),s=n(18193),o=(r=function(e){let t=new URLSearchParams;t.append("code",e);for(let e=1;e<arguments.length;e++)t.append("v",arguments[e]);throw Error(`Minified Lexical error #${e}; visit https://lexical.dev/docs/error?${t} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}).__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r;let l=new Set(["http:","https:","mailto:","sms:","tel:"]);class a extends s.HX{static getType(){return"link"}static clone(e){return new a(e.__url,{rel:e.__rel,target:e.__target,title:e.__title},e.__key)}constructor(e="",t={},n){super(n);let{target:r=null,rel:i=null,title:s=null}=t;this.__url=e,this.__target=r,this.__rel=i,this.__title=s}createDOM(e){let t=document.createElement("a");return t.href=this.sanitizeUrl(this.__url),null!==this.__target&&(t.target=this.__target),null!==this.__rel&&(t.rel=this.__rel),null!==this.__title&&(t.title=this.__title),(0,i.Yo)(t,e.theme.link),t}updateDOM(e,t,n){if((0,s.bg)(t)){let n=this.__url,r=this.__target,i=this.__rel,s=this.__title;n!==e.__url&&(t.href=n),r!==e.__target&&(r?t.target=r:t.removeAttribute("target")),i!==e.__rel&&(i?t.rel=i:t.removeAttribute("rel")),s!==e.__title&&(s?t.title=s:t.removeAttribute("title"))}return!1}static importDOM(){return{a:e=>({conversion:u,priority:1})}}static importJSON(e){return c().updateFromJSON(e)}updateFromJSON(e){return super.updateFromJSON(e).setURL(e.url).setRel(e.rel||null).setTarget(e.target||null).setTitle(e.title||null)}sanitizeUrl(e){try{let t=new URL(e);if(!l.has(t.protocol))return"about:blank"}catch(e){}return e}exportJSON(){return{...super.exportJSON(),rel:this.getRel(),target:this.getTarget(),title:this.getTitle(),url:this.getURL()}}getURL(){return this.getLatest().__url}setURL(e){let t=this.getWritable();return t.__url=e,t}getTarget(){return this.getLatest().__target}setTarget(e){let t=this.getWritable();return t.__target=e,t}getRel(){return this.getLatest().__rel}setRel(e){let t=this.getWritable();return t.__rel=e,t}getTitle(){return this.getLatest().__title}setTitle(e){let t=this.getWritable();return t.__title=e,t}insertNewAfter(e,t=!0){let n=c(this.__url,{rel:this.__rel,target:this.__target,title:this.__title});return this.insertAfter(n,t),n}canInsertTextBefore(){return!1}canInsertTextAfter(){return!1}canBeEmpty(){return!1}isInline(){return!0}extractWithChild(e,t,n){if(!(0,s.OP)(t))return!1;let r=t.anchor.getNode(),i=t.focus.getNode();return this.isParentOf(r)&&this.isParentOf(i)&&t.getTextContent().length>0}isEmailURI(){return this.__url.startsWith("mailto:")}isWebSiteURI(){return this.__url.startsWith("https://")||this.__url.startsWith("http://")}}function u(e){let t=null;if((0,s.bg)(e)){let n=e.textContent;(null!==n&&""!==n||e.children.length>0)&&(t=c(e.getAttribute("href")||"",{rel:e.getAttribute("rel"),target:e.getAttribute("target"),title:e.getAttribute("title")}))}return{node:t}}function c(e="",t){return(0,s.U2)(new a(e,t))}function d(e){return e instanceof a}class h extends a{constructor(e="",t={},n){super(e,t,n),this.__isUnlinked=void 0!==t.isUnlinked&&null!==t.isUnlinked&&t.isUnlinked}static getType(){return"autolink"}static clone(e){return new h(e.__url,{isUnlinked:e.__isUnlinked,rel:e.__rel,target:e.__target,title:e.__title},e.__key)}getIsUnlinked(){return this.__isUnlinked}setIsUnlinked(e){let t=this.getWritable();return t.__isUnlinked=e,t}createDOM(e){return this.__isUnlinked?document.createElement("span"):super.createDOM(e)}updateDOM(e,t,n){return super.updateDOM(e,t,n)||e.__isUnlinked!==this.__isUnlinked}static importJSON(e){return f().updateFromJSON(e)}updateFromJSON(e){return super.updateFromJSON(e).setIsUnlinked(e.isUnlinked||!1)}static importDOM(){return null}exportJSON(){return{...super.exportJSON(),isUnlinked:this.__isUnlinked}}insertNewAfter(e,t=!0){let n=this.getParentOrThrow().insertNewAfter(e,t);if((0,s.F7)(n)){let e=f(this.__url,{isUnlinked:this.__isUnlinked,rel:this.__rel,target:this.__target,title:this.__title});return n.append(e),e}return null}}function f(e="",t){return(0,s.U2)(new h(e,t))}function p(e){return e instanceof h}let g=(0,s.fA)("TOGGLE_LINK_COMMAND");function m(e,t){if("element"===e.type){let n=e.getNode();return(0,s.F7)(n)||o(252),n.getChildren()[e.offset+t]||null}return null}function y(e,t={}){let{target:n,title:r}=t,o=void 0===t.rel?"noreferrer":t.rel,l=(0,s.dL)();if(!(0,s.OP)(l))return;let a=l.extract();
1if(null===e)return void a.forEach(e=>{let t=(0,i.$s)(e,e=>!p(e)&&d(e));if(t){let e=t.getChildren();for(let n=0;n<e.length;n++)t.insertBefore(e[n]);t.remove()}});let u=new Set,h=t=>{u.has(t.getKey())||(u.add(t.getKey()),t.setURL(e),void 0!==n&&t.setTarget(n),void 0!==o&&t.setRel(o),void 0!==r&&t.setTitle(r))};if(1===a.length){let e=v(a[0],d);if(null!==e)return h(e)}!function(e){let t=(0,s.dL)();if(!(0,s.OP)(t))return e();let n=(0,s.S9)(t),r=n.isBackward(),i=m(n.anchor,r?-1:0),o=m(n.focus,r?0:-1);if(e(),i||o){let e=(0,s.dL)();if((0,s.OP)(e)){let t=e.clone();if(i){let e=i.getParent();e&&t.anchor.set(e.getKey(),i.getIndexWithinParent()+(r?1:0),"element")}if(o){let e=o.getParent();e&&t.focus.set(e.getKey(),o.getIndexWithinParent()+(r?0:1),"element")}(0,s.oq)((0,s.S9)(t))}}}(()=>{let t=null;for(let i of a){if(!i.isAttached())continue;let l=v(i,d);if(l){h(l);continue}if((0,s.F7)(i)){if(!i.isInline())continue;if(d(i)){if(!(p(i)||null!==t&&t.getParentOrThrow().isParentOf(i))){h(i),t=i;continue}for(let e of i.getChildren())i.insertBefore(e);i.remove();continue}}let a=i.getPreviousSibling();d(a)&&a.is(t)?a.append(i):(t=c(e,{rel:o,target:n,title:r}),i.insertAfter(t),t.append(i))}})}function v(e,t){let n=e;for(;null!==n&&null!==n.getParent()&&!t(n);)n=n.getParentOrThrow();return t(n)?n:null}},11387:function(e,t,n){"use strict";n.d(t,{EG:function(){return S},FH:function(){return k},I3:function(){return A},NK:function(){return m},QG:function(){return x},dA:function(){return O},oU:function(){return b}});var r,i=n(30913),s=n(18193),o=(r=function(e){let t=new URLSearchParams;t.append("code",e);for(let e=1;e<arguments.length;e++)t.append("v",arguments[e]);throw Error(`Minified Lexical error #${e}; visit https://lexical.dev/docs/error?${t} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}).__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r;function l(e){let t=e.getParent();A(t)||o(40);let n=t;for(;null!==n;)A(n=n.getParent())&&(t=n);return t}function a(e){return x(e)&&A(e.getFirstChild())}function u(e){return b().append(e)}function c(e,t){return x(e)&&(0===t.length||1===t.length&&e.is(t[0])&&0===e.getChildrenSize())}function d(e){let t=(0,s.dL)();if(null!==t){let n=t.getNodes();if((0,s.OP)(t)){let r=t.getStartEndPoints();null===r&&o(143);let[i]=r,l=i.getNode(),a=l.getParent();if((0,s._v)(l)){let e=l.getFirstChild();if(e)n=e.selectStart().getNodes();else{let e=(0,s.BE)();l.append(e),n=e.select().getNodes()}}else if(c(l,n)){let t=k(e);if((0,s._v)(a)){l.replace(t);let e=b();(0,s.F7)(l)&&(e.setFormat(l.getFormatType()),e.setIndent(l.getIndent())),t.append(e)}else if(x(l)){let e=l.getParentOrThrow();h(t,e.getChildren()),e.replace(t)}return}}let r=new Set;for(let t=0;t<n.length;t++){let i=n[t];if(!(0,s.F7)(i)||!i.isEmpty()||x(i)||r.has(i.getKey())){if((0,s.H2)(i)){let t=i.getParent();for(;null!=t;){let n=t.getKey();if(A(t)){if(!r.has(n)){let i=k(e);h(i,t.getChildren()),t.replace(i),r.add(n)}break}{let i=t.getParent();if((0,s._v)(i)&&!r.has(n)){r.add(n),f(t,e);break}t=i}}}}else f(i,e)}}}function h(e,t){e.splice(e.getChildrenSize(),0,t)}function f(e,t){let n;if(A(e))return e;let r=e.getPreviousSibling(),i=e.getNextSibling(),s=b();
1if(h(s,e.getChildren()),A(r)&&t===r.getListType())r.append(s),A(i)&&t===i.getListType()&&(h(r,i.getChildren()),i.remove()),n=r;else if(A(i)&&t===i.getListType())i.getFirstChildOrThrow().insertBefore(s),n=i;else{let r=k(t);r.append(s),e.replace(r),n=r}return s.setFormat(e.getFormatType()),s.setIndent(e.getIndent()),e.remove(),n}function p(e,t){let n=e.getLastChild(),r=t.getFirstChild();n&&r&&a(n)&&a(r)&&(p(n.getFirstChild(),r.getFirstChild()),r.remove());let i=t.getChildren();i.length>0&&e.append(...i),t.remove()}function g(...e){let t=[];for(let n of e)if(n&&"string"==typeof n)for(let[e]of n.matchAll(/\S+/g))t.push(e);return t}class m extends s.HX{static getType(){return"listitem"}static clone(e){return new m(e.__value,e.__checked,e.__key)}constructor(e,t,n){super(n),this.__value=void 0===e?1:e,this.__checked=t}createDOM(e){let t=document.createElement("li"),n=this.getParent();return A(n)&&"check"===n.getListType()&&v(t,this,null),t.value=this.__value,y(t,e.theme,this),t}updateDOM(e,t,n){let r=this.getParent();return A(r)&&"check"===r.getListType()&&v(t,this,e),t.value=this.__value,y(t,n.theme,this),!1}static transform(){return e=>{if(x(e)||o(144),null==e.__checked)return;let t=e.getParent();A(t)&&"check"!==t.getListType()&&null!=e.getChecked()&&e.setChecked(void 0)}}static importDOM(){return{li:()=>({conversion:_,priority:0})}}static importJSON(e){return b().updateFromJSON(e)}updateFromJSON(e){return super.updateFromJSON(e).setValue(e.value).setChecked(e.checked)}exportDOM(e){let t=this.createDOM(e._config);return t.style.textAlign=this.getFormatType(),{element:t}}exportJSON(){return{...super.exportJSON(),checked:this.getChecked(),value:this.getValue()}}append(...e){for(let t=0;t<e.length;t++){let n=e[t];if((0,s.F7)(n)&&this.canMergeWith(n)){let e=n.getChildren();this.append(...e),n.remove()}else super.append(n)}return this}replace(e,t){if(x(e))return super.replace(e);this.setIndent(0);let n=this.getParentOrThrow();if(!A(n))return e;if(n.__first===this.getKey())n.insertBefore(e);else if(n.__last===this.getKey())n.insertAfter(e);else{let t=k(n.getListType()),r=this.getNextSibling();for(;r;){let e=r;r=r.getNextSibling(),t.append(e)}n.insertAfter(e),e.insertAfter(t)}
1return t&&((0,s.F7)(e)||o(139),this.getChildren().forEach(t=>{e.append(t)})),this.remove(),0===n.getChildrenSize()&&n.remove(),e}insertAfter(e,t=!0){let n=this.getParentOrThrow();if(A(n)||o(39),x(e))return super.insertAfter(e,t);let r=this.getNextSiblings();if(n.insertAfter(e,t),0!==r.length){let i=k(n.getListType());r.forEach(e=>i.append(e)),e.insertAfter(i,t)}return e}remove(e){let t=this.getPreviousSibling(),n=this.getNextSibling();super.remove(e),t&&n&&a(t)&&a(n)&&(p(t.getFirstChild(),n.getFirstChild()),n.remove())}insertNewAfter(e,t=!0){let n=b().updateFromJSON(this.exportJSON()).setChecked(!this.getChecked()&&void 0);return this.insertAfter(n,t),n}collapseAtStart(e){let t=(0,s.BE)();this.getChildren().forEach(e=>t.append(e));let n=this.getParentOrThrow(),r=n.getParentOrThrow(),i=x(r);if(1===n.getChildrenSize()){if(i)n.remove(),r.select();else{n.insertBefore(t),n.remove();let r=e.anchor,i=e.focus,s=t.getKey();"element"===r.type&&r.getNode().is(this)&&r.set(s,r.offset,"element"),"element"===i.type&&i.getNode().is(this)&&i.set(s,i.offset,"element")}}else n.insertBefore(t),this.remove();return!0}getValue(){return this.getLatest().__value}setValue(e){let t=this.getWritable();return t.__value=e,t}getChecked(){let e;let t=this.getLatest(),n=this.getParent();return A(n)&&(e=n.getListType()),"check"===e?!!t.__checked:void 0}setChecked(e){let t=this.getWritable();return t.__checked=e,t}toggleChecked(){let e=this.getWritable();return e.setChecked(!e.__checked)}getIndent(){let e=this.getParent();if(null===e||!this.isAttached())return this.getLatest().__indent;let t=e.getParentOrThrow(),n=0;for(;x(t);)t=t.getParentOrThrow().getParentOrThrow(),n++;return n}setIndent(e){"number"!=typeof e&&o(117),(e=Math.floor(e))>=0||o(199);let t=this.getIndent();for(;t!==e;)t<e?(function(e){let t=new Set;if(a(e)||t.has(e.getKey()))return;let n=e.getParent(),r=e.getNextSibling(),i=e.getPreviousSibling();if(a(r)&&a(i)){let n=i.getFirstChild();if(A(n)){n.append(e);let i=r.getFirstChild();A(i)&&(h(n,i.getChildren()),r.remove(),t.add(r.getKey()))}}else if(a(r)){let t=r.getFirstChild();if(A(t)){let n=t.getFirstChild();null!==n&&n.insertBefore(e)}}else if(a(i)){let t=i.getFirstChild();A(t)&&t.append(e)}else if(A(n)){let t=b(),s=k(n.getListType());t.append(s),s.append(e),i?i.insertAfter(t):r?r.insertBefore(t):n.append(t)}}(this),t++):(function(e){if(a(e))return;let t=e.getParent(),n=t?t.getParent():void 0;if(A(n?n.getParent():void 0)&&x(n)&&A(t)){let r=t?t.getFirstChild():void 0,i=t?t.getLastChild():void 0;if(e.is(r))n.insertBefore(e),t.isEmpty()&&n.remove();else if(e.is(i))n.insertAfter(e),t.isEmpty()&&n.remove();else{let r=t.getListType(),i=b(),s=k(r);
1i.append(s),e.getPreviousSiblings().forEach(e=>s.append(e));let o=b(),l=k(r);o.append(l),h(l,e.getNextSiblings()),n.insertBefore(i),n.insertAfter(o),n.replace(e)}}}(this),t--);return this}canInsertAfter(e){return x(e)}canReplaceWith(e){return x(e)}canMergeWith(e){return x(e)||(0,s.Rl)(e)}extractWithChild(e,t){if(!(0,s.OP)(t))return!1;let n=t.anchor.getNode(),r=t.focus.getNode();return this.isParentOf(n)&&this.isParentOf(r)&&this.getTextContent().length===t.getTextContent().length}isParentRequired(){return!0}createParentElementNode(){return k("bullet")}canMergeWhenEmpty(){return!0}}function y(e,t,n){let r;let s=[],o=[],l=t.list,a=l?l.listitem:void 0;if(l&&l.nested&&(r=l.nested.listitem),void 0!==a&&s.push(...g(a)),l){let e=n.getParent(),t=A(e)&&"check"===e.getListType(),r=n.getChecked();t&&!r||o.push(l.listitemUnchecked),t&&r||o.push(l.listitemChecked),t&&s.push(r?l.listitemChecked:l.listitemUnchecked)}if(void 0!==r){let e=g(r);n.getChildren().some(e=>A(e))?s.push(...e):o.push(...e)}o.length>0&&(0,i.PS)(e,...o),s.length>0&&(0,i.Yo)(e,...s)}function v(e,t,n,r){A(t.getFirstChild())?(e.removeAttribute("role"),e.removeAttribute("tabIndex"),e.removeAttribute("aria-checked")):(e.setAttribute("role","checkbox"),e.setAttribute("tabIndex","-1"),n&&t.__checked===n.__checked||e.setAttribute("aria-checked",t.getChecked()?"true":"false"))}function _(e){if(e.classList.contains("task-list-item")){for(let t of e.children)if("INPUT"===t.tagName)return"checkbox"!==t.getAttribute("type")?{node:null}:{node:b(t.hasAttribute("checked"))}}let t=e.getAttribute("aria-checked");return{node:b("true"===t||"false"!==t&&void 0)}}function b(e){return(0,s.U2)(new m(void 0,e))}function x(e){return e instanceof m}class S extends s.HX{static getType(){return"list"}static clone(e){return new S(e.__listType||C[e.__tag],e.__start,e.__key)}constructor(e="number",t=1,n){super(n);let r=C[e]||e;this.__listType=r,this.__tag="number"===r?"ol":"ul",this.__start=t}getTag(){return this.__tag}setListType(e){let t=this.getWritable();return t.__listType=e,t.__tag="number"===e?"ol":"ul",t}getListType(){return this.__listType}getStart(){return this.__start}setStart(e){let t=this.getWritable();return t.__start=e,t}createDOM(e,t){let n=this.__tag,r=document.createElement(n);return 1!==this.__start&&r.setAttribute("start",String(this.__start)),r.__lexicalListType=this.__listType,w(r,e.theme,this),r}updateDOM(e,t,n){return e.__tag!==this.__tag||(w(t,n.theme,this),!1)}static transform(){return e=>{A(e)||o(163),function(e){let t=e.getNextSibling();A(t)&&e.getListType()===t.getListType()&&p(e,t)}(e),function(e){let t="check"!==e.getListType(),n=e.getStart();for(let r of e.getChildren())x(r)&&(r.getValue()!==n&&r.setValue(n),t&&null!=r.getLatest().__checked&&r.setChecked(void 0),A(r.getFirstChild())||n++)}(e)}}static importDOM(){return{ol:()=>({conversion:T,priority:0}),ul:()=>({conversion:T,priority:0})}}static importJSON(e){return k().updateFromJSON(e)}updateFromJSON(e){return super.updateFromJSON(e).setListType(e.listType).setStart(e.start)}exportDOM(e){let t=this.createDOM(e._config,e);return(0,s.Re)(t)&&(1!==this.__start&&t.setAttribute("start",String(this.__start)),"check"===this.__listType&&t.setAttribute("__lexicalListType","check")),{element:t}}exportJSON(){return{...super.exportJSON(),listType:this.getListType(),start:this.getStart(),tag:this.getTag()}}canBeEmpty(){return!1}canIndent(){return!1}append(...e){for(let t=0;t<e.length;t++){let n=e[t];if(x(n))super.append(n);else{let e=b();if(A(n))e.append(n);else if((0,s.F7)(n)){if(n.isInline())e.append(n);else{let t=(0,s.MX)(n.getTextContent());e.append(t)}}else e.append(n);super.append(e)}}return this}extractWithChild(e){return x(e)}}function w(e,t,n){let r=[],s=[],l=t.list;if(void 0!==l){let e;let t=l[`${n.__tag}Depth`]||[],i=function(e){let t=1,n=e.getParent();for(;null!=n;){if(x(n)){let e=n.getParent();if(A(e)){t++,n=e.getParent();continue}o(40)}break}return t}(n)-1,a=i%t.length,u=t[a],c=l[n.__tag],d=l.nested,h=l.checklist;if(void 0!==d&&d.list&&(e=d.list),void 0!==c&&r.push(c),void 0!==h&&"check"===n.__listType&&r.push(h),void 0!==u){r.push(...g(u));for(let e=0;e<t.length;e++)e!==a&&s.push(n.__tag+e)}if(void 0!==e){let t=g(e);i>1?r.push(...t):s.push(...t)}}s.length>0&&(0,i.PS)(e,...s),r.length>0&&(0,i.Yo)(e,...r)}function E(e){let t=[];for(let n=0;n<e.length;n++){let r=e[n];if(x(r)){t.push(r);let e=r.getChildren();e.length>
11&&e.forEach(e=>{A(e)&&t.push(u(e))})}else t.push(u(r))}return t}function T(e){let t=e.nodeName.toLowerCase(),n=null;return"ol"===t?n=k("number",e.start):"ul"===t&&(n=!function(e){if("check"===e.getAttribute("__lexicallisttype")||e.classList.contains("contains-task-list"))return!0;for(let t of e.childNodes)if((0,s.Re)(t)&&t.hasAttribute("aria-checked"))return!0;return!1}(e)?k("bullet"):k("check")),{after:E,node:n}}let C={ol:"number",ul:"bullet"};function k(e="number",t=1){return(0,s.U2)(new S(e,t))}function A(e){return e instanceof S}let P=(0,s.fA)("INSERT_UNORDERED_LIST_COMMAND"),N=(0,s.fA)("INSERT_ORDERED_LIST_COMMAND"),F=((0,s.fA)("INSERT_CHECK_LIST_COMMAND"),(0,s.fA)("REMOVE_LIST_COMMAND"));function O(e){return(0,i.qV)(e.registerCommand(N,()=>(d("number"),!0),s.KB),e.registerCommand(P,()=>(d("bullet"),!0),s.KB),e.registerCommand(F,()=>((function(){let e=(0,s.dL)();if((0,s.OP)(e)){let t=new Set,n=e.getNodes(),r=e.anchor.getNode();if(c(r,n))t.add(l(r));else for(let e=0;e<n.length;e++){let r=n[e];if((0,s.H2)(r)){let e=(0,i.yD)(r,m);null!=e&&t.add(l(e))}}for(let n of t){let t=n;for(let r of function e(t){let n=[],r=t.getChildren().filter(x);for(let t=0;t<r.length;t++){let i=r[t],s=i.getFirstChild();A(s)?n=n.concat(e(s)):n.push(i)}return n}(n)){let n=(0,s.BE)();h(n,r.getChildren()),t.insertAfter(n),t=n,r.__key===e.anchor.key&&e.anchor.set(n.getKey(),0,"element"),r.__key===e.focus.key&&e.focus.set(n.getKey(),0,"element"),r.remove()}n.remove()}}})(),!0),s.KB),e.registerCommand(s.K0,()=>!!function(){let e;let t=(0,s.dL)();if(!(0,s.OP)(t)||!t.isCollapsed())return!1;let n=t.anchor.getNode();if(!x(n)||0!==n.getChildrenSize())return!1;let r=l(n),i=n.getParent();A(i)||o(40);let a=i.getParent();if((0,s._v)(a))(e=(0,s.BE)()).setTextStyle(t.style),e.setTextFormat(t.format),r.insertAfter(e);else{if(!x(a))return!1;e=b(),a.insertAfter(e)}e.select();let u=n.getNextSiblings();if(u.length>0){let t=k(i.getListType());if(x(e)){let n=b();n.append(t),e.insertAfter(n)}else e.insertAfter(t);t.append(...u)}return function(e){let t=e;for(;null==t.getNextSibling()&&null==t.getPreviousSibling();){let e=t.getParent();if(null==e||!x(t)&&!A(t))break;t=e}t.remove()}(n),!0}(),s.KB))}},2369:function(e,t,n){"use strict";n.d(t,{AB:function(){return m},XC:function(){return w}});var r,i=n(18193),s=n(11387),o=n(53938),l=n(50835),a=n(74753);function u(e,t){let n={};for(let r of e){let e=t(r);e&&(n[e]?n[e].push(r):n[e]=[r])}return n}let c=/[!-/:-@[-`{-~\s]/,d="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement,h=d&&"documentMode"in document?document.documentMode:null;d&&"InputEvent"in window&&!h&&new window.InputEvent("input"),d&&/Version\/[\d.]+.*Safari/.test(navigator.userAgent),d&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&window.MSStream,d&&/^(?=.*Chrome).*/i.test(navigator.userAgent),d&&/AppleWebKit\/[\d.]+/.test(navigator.userAgent);var f=(r=function(e){let t=new URLSearchParams;t.append("code",e);for(let e=1;e<arguments.length;e++)t.append("v",arguments[e]);throw Error(`Minified Lexical error #${e}; visit https://lexical.dev/docs/error?${t} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}).__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r;function p(e,t,n){let r=n.length;for(let i=t;i>=r;i--){let t=i-r;if(g(e,t,n,0,r)&&" "!==e[t+r])return t}return -1}function g(e,t,n,r,i){for(let s=0;s<i;s++)if(e[t+s]!==n[r+s])return!1;return!0}function m(e,t=w){let n=function(e){let t=u(e,e=>e.type);return{element:t.element||[],multilineElement:t["multiline-element"]||[],textFormat:t["text-format"]||[],textMatch:t["text-match"]||[]}}(t),r=u(n.textFormat,({tag:e})=>e[e.length-1]),s=u(n.textMatch,({trigger:e})=>e);for(let n of t){let t=n.type;if("element"===t||"text-match"===t||"multiline-element"===t)for(let t of n.dependencies)e.hasNode(t)||f(173,t.getType())}let o=(e,t,o)=>{(function(e,t,n,r){let s=e.getParent();if(!(0,i._v)(s)||e.getFirstChild()!==t)return!1;let o=t.getTextContent();if(" "!==o[n-1])return!1;for(let{regExp:i,replace:s}of r){let r=o.match(i);if(r&&r[0].length===(r[0].endsWith(" ")?n:n-1)){let i=t.getNextSiblings(),[o,l]=t.splitText(n);if(o.remove(),!1!==s(e,l?[l,...i]:i,r,!1))return!0}}return!1})(e,t,o,n.element)||function(e,t,n,r){let s=e.getParent();if(!(0,i._v)(s)||e.getFirstChild()!==t)return!1;let o=t.getTextContent();if(" "!==o[n-1])return!1;for(let{regExpStart:i,replace:s,regExpEnd:l}of r){if(l&&!("optional"in l)||l&&"optional"in l&&!l.optional)continue;let r=o.match(i);if(r&&r[0].length===(r[0].endsWith(" ")?n:n-1)){let i=t.getNextSiblings(),[o,l]=t.splitText(n);if(o.remove(),!1!==s(e,l?[l,...i]:i,r,null,null,!1))return!0}}return!1}(e,t,o,n.multilineElement)||function(e,t,n){let r=e.getTextContent(),i=n[r[t-1]];if(null==i)return!1;for(let n of(t<r.length&&(r=r.slice(0,t)),i)){let t;if(!n.replace||!n.regExp)continue;let i=r.match(n.regExp);if(null===i)continue;let s=i.index||0,o=s+i[0].length;return 0===s?[t]=e.splitText(o):[,t]=e.splitText(s,o),t.selectNext(0,0),n.replace(t,i),!0}return!1}(t,o,s)||function(e,t,n){let r=e.getTextContent(),s=t-1,o=r[s],l=n[o];if(l)for(let t of l){let{tag:n}=t,l=n.length,a=s-l+1;
1if(l>1&&!g(r,a,n,0,l)||" "===r[a-1])continue;let u=r[s+1];if(!1===t.intraword&&u&&!c.test(u))continue;let d=e,h=p(r,a,n),f=d;for(;h<0&&(f=f.getPreviousSibling())&&!(0,i.A3)(f);)if((0,i.Gg)(f)){let e=f.getTextContent();d=f,h=p(e,e.length,n)}if(h<0||d===e&&h+l===a)continue;let m=d.getTextContent();if(h>0&&m[h-1]===o)continue;let y=m[h-1];if(!1===t.intraword&&y&&!c.test(y))continue;let v=e.getTextContent(),_=v.slice(0,a)+v.slice(s+1);e.setTextContent(_);let b=d===e?_:m;d.setTextContent(b.slice(0,h)+b.slice(h+l));let x=(0,i.dL)(),S=(0,i.vN)();(0,i.oq)(S);let w=s-l*(d===e?2:1)+1;for(let n of(S.anchor.set(d.__key,h,"text"),S.focus.set(e.__key,w,"text"),t.format))S.hasFormat(n)||S.formatText(n);for(let e of(S.anchor.set(S.focus.key,S.focus.offset,S.focus.type),t.format))S.hasFormat(e)&&S.toggleFormat(e);return(0,i.OP)(x)&&(S.format=x.format),!0}}(t,o,r)};return e.registerUpdateListener(({tags:t,dirtyLeaves:n,editorState:r,prevEditorState:s})=>{if(t.has("collaboration")||t.has("historic")||e.isComposing())return;let a=r.read(i.dL),u=s.read(i.dL);if(!(0,i.OP)(u)||!(0,i.OP)(a)||!a.isCollapsed()||a.is(u))return;let c=a.anchor.key,d=a.anchor.offset,h=r._nodeMap.get(c);(0,i.Gg)(h)&&n.has(c)&&(1===d||!(d>u.anchor.offset+1))&&e.update(()=>{if(!(0,i.Gg)(h)||h.hasFormat("code"))return;let e=h.getParent();null===e||(0,l.Pe)(e)||o(e,h,a.anchor.offset)})})}let y=e=>(t,n,r)=>{let i=e(r);i.append(...n),t.replace(i),i.select(0,0)},v=e=>(t,n,r)=>{let i=t.getPreviousSibling(),o=t.getNextSibling(),l=(0,s.oU)("check"===e?"x"===r[3]:void 0);if((0,s.I3)(o)&&o.getListType()===e){let e=o.getFirstChild();null!==e?e.insertBefore(l):o.append(l),t.remove()}else if((0,s.I3)(i)&&i.getListType()===e)i.append(l),t.remove();else{let n=(0,s.FH)(e,"number"===e?Number(r[2]):void 0);n.append(l),t.replace(n)}l.append(...n),l.select(0,0);let a=function(e){let t=e.match(/\t/g),n=e.match(/ /g),r=0;return t&&(r+=t.length),n&&(r+=Math.floor(n.length/4)),r}(r[1]);a&&l.setIndent(a)},_=(e,t,n)=>{let r=[],i=e.getChildren(),o=0;for(let l of i)if((0,s.QG)(l)){if(1===l.getChildrenSize()){let e=l.getFirstChild();if((0,s.I3)(e)){r.push(_(e,t,n+1));continue}}let i=" ".repeat(4*n),a=e.getListType(),u="number"===a?`${e.getStart()+o}. `:"check"===a?`- [${l.getChecked()?"x":" "}] `:"- ";r.push(i+u+t(l)),o++}return r.join("\n")},b={dependencies:[o.c2],export:(e,t)=>{if(!(0,o.rc)(e))return null;let n=Number(e.getTag().slice(1));return"#".repeat(n)+" "+t(e)},regExp:/^(#{1,6})\s/,replace:y(e=>{let t="h"+e[1].length;return(0,o.V1)(t)}),type:"element"},x={dependencies:[o.rT],export:(e,t)=>{if(!(0,o.O)(e))return null;let n=t(e).split("\n"),r=[];for(let e of n)r.push("> "+e);return r.join("\n")},regExp:/^>\s/,replace:(e,t,n,r)=>{if(r){let n=e.getPreviousSibling();if((0,o.O)(n))return n.splice(n.getChildrenSize(),0,[(0,i.T)(),...t]),n.select(0,0),void e.remove()}let s=(0,o.Z1)();s.append(...t),e.replace(s),s.select(0,0)},type:"element"},S={dependencies:[l.wg],export:e=>{if(!(0,l.Pe)(e))return null;let t=e.getTextContent();return"```"+(e.getLanguage()||"")+(t?"\n"+t:"")+"\n```"},regExpEnd:{optional:!0,regExp:/[ \t]*```$/},regExpStart:/^[ \t]*```(\w+)?/,replace:(e,t,n,r,s,o)=>{let a,u;if(!t&&s){if(1===s.length)r?(a=(0,l.Ol)(),u=n[1]+s[0]):(a=(0,l.Ol)(n[1]),u=s[0].startsWith(" ")?s[0].slice(1):s[0]);else{if(a=(0,l.Ol)(n[1]),0===s[0].trim().length)for(;s.length>0&&!s[0].length;)s.shift();else s[0]=s[0].startsWith(" ")?s[0].slice(1):s[0];for(;s.length>0&&!s[s.length-1].length;)s.pop();u=s.join("\n")}let t=(0,i.MX)(u);a.append(t),e.append(a)}else t&&y(e=>(0,l.Ol)(e?e[1]:void 0))(e,t,n,o)},type:"multiline-element"},w=[b,x,{dependencies:[s.EG,s.NK],export:(e,t)=>(0,s.I3)(e)?_(e,t,0):null,regExp:/^(\s*)[-*+]\s/,replace:v("bullet"),type:"element"},(s.EG,s.NK,v("check"),{dependencies:[s.EG,s.NK],export:(e,t)=>(0,s.I3)(e)?_(e,t,0):null,regExp:/^(\s*)(\d{1,})\.\s/,replace:v("number"),type:"element"}),S,{format:["code"],tag:"`",type:"text-format"},{format:["bold","italic"],tag:"***",type:"text-format"},{format:["bold","italic"],intraword:!1,tag:"___",type:"text-format"},{format:["bold"],tag:"**",type:"text-format"},{format:["bold"],intraword:!1,tag:"__",type:"text-format"},{format:["highlight"],tag:"==",type:"text-format"},{format:["italic"],tag:"*",type:"text-format"},{format:["italic"],intraword:!1,tag:"_",type:"text-format"},{format:["strikethrough"],tag:"~~",type:"text-format"},{dependencies:[a.GR],export:(e,t,n)=>{if(!(0,a.Pq)(e))return null;let r=e.getTitle(),i=t(e);return r?`[${i}](${e.getURL()} "${r}")`:`[${i}](${e.getURL()})`},importRegExp:/(?:\[([^[]+)\])(?:\((?:([^()\s]+)(?:\s"((?:[^"]*\\")*[^"]*)"\s*)?)\))/,regExp:/(?:\[([^[]+)\])(?:\((?:([^()\s]+)(?:\s"((?:[^"]*\\")*[^"]*)"\s*)?)\))$/,replace:(e,t)=>{let[,n,r,s]=t,o=(0,a.zV)(r,{title:s}),l=(0,i.MX)(n);return l.setFormat(e.getFormat()),o.append(l),e.replace(o),l},trigger:")",type:"text-match"}]},79565:function(e,t,n){"use strict";n.d(t,{R:function(){return c}});var r=n(88332),i=n(18193),s=n(71100),o=n(44825);let l="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement,a=l?s.useLayoutEffect:s.useEffect,u={tag:"history-merge"};function c({initialConfig:e,children:t}){let n=(0,s.useMemo)(()=>{let{theme:t,namespace:n,nodes:s,onError:o,editorState:a,html:c}=e,d=(0,r.LI)(null,t),h=(0,i.Jh)({editable:e.editable,html:c,namespace:n,nodes:s,onError:e=>o(e,h),theme:t});return function(e,t){if(null!==t){if(void 0===t)e.update(()=>{let t=(0,i.Gv)();if(t.isEmpty()){let n=(0,i.BE)();t.append(n);let r=l?document.activeElement:null;(null!==(0,i.dL)()||null!==r&&r===e.getRootElement())&&n.select()}},u);else if(null!==t)switch(typeof t){case"string":{let n=e.parseEditorState(t);e.setEditorState(n,u);break}case"object":e.setEditorState(t,u);break;case"function":e.update(()=>{(0,i.Gv)().isEmpty()&&t(e)},u)}}}(h,a),[h,d]},[]);return a(()=>{let t=e.editable,[r]=n;r.setEditable(void 0===t||t)},[]),(0,o.jsx)(r.YK.Provider,{value:n,children:t})}},88332:function(e,t,n){"use strict";n.d(t,{LI:function(){return l},YK:function(){return o},g:function(){return a}});var r,i=n(71100),s=(r=function(e){let t=new URLSearchParams;t.append("code",e);for(let e=1;e<arguments.length;e++)t.append("v",arguments[e]);throw Error(`Minified Lexical error #${e}; visit https://lexical.dev/docs/error?${t} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}).__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r;let o=(0,i.createContext)(null);function l(e,t){let n=null;return null!=e&&(n=e[1]),{getTheme:function(){return null!=t?t:null!=n?n.getTheme():null}}}function a(){let e=(0,i.useContext)(o);return null==e&&s(8),e}},13268:function(e,t,n){"use strict";n.d(t,{f:function(){return d}});var r=n(88332),i=n(71100),s=n(44825),o=n(40400),l=n(30913);let a="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement?i.useLayoutEffect:i.useEffect,u=(0,i.forwardRef)(function({editor:e,ariaActiveDescendant:t,ariaAutoComplete:n,ariaControl
1s:r,ariaDescribedBy:o,ariaErrorMessage:l,ariaExpanded:u,ariaInvalid:c,ariaLabel:d,ariaLabelledBy:h,ariaMultiline:f,ariaOwns:p,ariaRequired:g,autoCapitalize:m,className:y,id:v,role:_="textbox",spellCheck:b=!0,style:x,tabIndex:S,"data-testid":w,...E},T){let[C,k]=(0,i.useState)(e.isEditable()),A=(0,i.useCallback)(t=>{t&&t.ownerDocument&&t.ownerDocument.defaultView?e.setRootElement(t):e.setRootElement(null)},[e]),P=(0,i.useMemo)(()=>(function(...e){return t=>{e.forEach(e=>{"function"==typeof e?e(t):null!=e&&(e.current=t)})}})(T,A),[A,T]);return a(()=>(k(e.isEditable()),e.registerEditableListener(e=>{k(e)})),[e]),(0,s.jsx)("div",{"aria-activedescendant":C?t:void 0,"aria-autocomplete":C?n:"none","aria-controls":C?r:void 0,"aria-describedby":o,...null!=l?{"aria-errormessage":l}:{},"aria-expanded":C&&"combobox"===_?!!u:void 0,...null!=c?{"aria-invalid":c}:{},"aria-label":d,"aria-labelledby":h,"aria-multiline":f,"aria-owns":C?p:void 0,"aria-readonly":!C||void 0,"aria-required":g,autoCapitalize:m,className:y,contentEditable:C,"data-testid":w,id:v,ref:P,role:C?_:void 0,spellCheck:b,style:x,tabIndex:S,...E})});function c(e){return e.getEditorState().read((0,o.yL)(e.isComposing()))}let d=(0,i.forwardRef)(function(e,t){let{placeholder:n,...i}=e,[o]=(0,r.g)();return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(u,{editor:o,...i,ref:t}),null!=n&&(0,s.jsx)(h,{editor:o,content:n})]})});function h({content:e,editor:t}){let n=function(e){let[t,n]=(0,i.useState)(()=>c(e));return a(()=>{function t(){n(c(e))}return t(),(0,l.qV)(e.registerUpdateListener(()=>{t()}),e.registerEditableListener(()=>{t()}))},[e]),t}(t),[r,o]=(0,i.useState)(t.isEditable());if((0,i.useLayoutEffect)(()=>(o(t.isEditable()),t.registerEditableListener(e=>{o(e)})),[t]),!n)return null;let u=null;return"function"==typeof e?u=e(r):null!==e&&(u=e),null===u?null:(0,s.jsx)("div",{"aria-hidden":!0,children:u})}},71454:function(e,t,n){"use strict";n.d(t,{g:function(){return a}});var r=n(71100),i=n(44825);function s(e,t){return(s=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}var o={error:null},l=function(e){function t(){for(var t,n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];return(t=e.call.apply(e,[this].concat(r))||this).state=o,t.resetErrorBoundary=function(){for(var e,n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];null==t.props.onReset||(e=t.props).onReset.apply(e,r),t.reset()},t}t.prototype=Object.create(e.prototype),t.prototype.constructor=t,s(t,e),t.getDerivedStateFromError=function(e){return{error:e}};var n=t.prototype;return n.reset=function(){this.setState(o)},n.componentDidCatch=function(e,t){var n,r;null==(n=(r=this.props).onError)||n.call(r,e,t)},n.componentDidUpdate=function(e,t){var n,r,i,s,o=this.state.error,l=this.props.resetKeys;null!==o&&null!==t.error&&(void 0===(i=e.resetKeys)&&(i=[]),void 0===(s=l)&&(s=[]),i.length!==s.length||i.some(function(e,t){return!Object.is(e,s[t])}))&&(null==(n=(r=this.props).onResetKeysChange)||n.call(r,e.resetKeys,l),this.reset())},n.render=function(){var e=this.state.error,t=this.props,n=t.fallbackRender,i=t.FallbackComponent,s=t.fallback;if(null!==e){var o={error:e,resetErrorBoundary:this.resetErrorBoundary};if(r.isValidElement(s))return s;if("function"==typeof n)return n(o);if(i)return r.createElement(i,o);throw Error("react-error-boundary requires either a fallback, fallbackRender, or FallbackComponent prop")}return this.props.children},t}(r.Component);function a({children:e,onError:t}){return(0,i.jsx)(l,{fallback:(0,i.jsx)("div",{style:{border:"1px solid #f00",color:"#f00",padding:"8px"},children:"An error was thrown."}),onError:t,children:e})}},25994:function(e,t,n){"use strict";n.d(t,{Dq:function(){return h},HY:function(){return c},fs:function(){return f}});var r=n(88332),i=n(66518),s=n(30913),o=n(18193),l=n(71100),a=n(44825);function u({nodeKey:e}){let[t]=(0,r.g)(),[n,a,u]=(0,i.y)(e),c=(0,l.useCallback)(e=>{let t=(0,o.dL)();return n&&(0,o.iO)(t)&&(e.preventDefault(),t.getNodes().forEach(e=>{f(e)&&e.remove()})),!1},[n]);return(0,l.useEffect)(()=>(0,s.qV)(t.registerCommand(o.Kr,r=>{let i=t.getElementByKey(e);return r.target===i&&(r.shiftKey||u(),a(!n),!0)},o.KB),t.registerCommand(o.MK,c,o.KB),t.registerCommand(o.aR,c,o.KB)),[u,t,n,e,c,a]),(0,l.useEffect)(()=>{let r=t.getElementByKey(e),i="selected";null!==r&&(n?(0,s.Yo)(r,i):(0,s.PS)(r,i))},[t,n,e]),null}(0,o.fA)("INSERT_HORIZONTAL_RULE_COMMAND");class c extends o.Ij{static getType(){return"horizontalrule"}static clone(e){return new c(e.__key)}static importJSON(e){return h().updateFromJSON(e)}static importDOM(){return{hr:()=>({conversion:d,priority:0})}}exportDOM(){return{element:document.createElement("hr")}}createDOM(e){let t=document.createElement("hr");return(0,s.Yo)(t,e.theme.hr),t}getTextContent(){return"\n"}isInline(){return!1}updateDOM(){return!1}decorate(){return(0,a.jsx)(u,{nodeKey:this.__key})}}function d(){return{node:h()}}function h(){return(0,o.U2)(new c)}function f(e){return e instanceof c}},24537:function(e,t,n){"use strict";n.d(t,{H:function(){return a}});var r=n(74753),i=n(88332),s=n(30913),o=n(18193),l=n(71100);function a({validateUrl:e,attributes:t}){let[n]=(0,i.g)();return(0,l.useEffect)(()=>
1{if(!n.hasNodes([r.GR]))throw Error("LinkPlugin: LinkNode not registered on editor");return(0,s.qV)(n.registerCommand(r.k0,n=>{if(null===n)return(0,r.Rf)(n),!0;if("string"==typeof n)return!(void 0!==e&&!e(n))&&((0,r.Rf)(n,t),!0);{let{url:e,target:i,rel:s,title:o}=n;return(0,r.Rf)(e,{...t,rel:s,target:i,title:o}),!0}},o.KB),void 0!==e?n.registerCommand(o.A1,i=>{let l=(0,o.dL)();if(!(0,o.OP)(l)||l.isCollapsed()||!(0,s.nh)(i,ClipboardEvent)||null===i.clipboardData)return!1;let a=i.clipboardData.getData("text");return!!e(a)&&!l.getNodes().some(e=>(0,o.F7)(e))&&(n.dispatchCommand(r.k0,{...t,url:a}),i.preventDefault(),!0)},o.KB):()=>{})},[n,e,t]),null}},80772:function(e,t,n){"use strict";n.d(t,{B:function(){return o}});var r=n(11387),i=n(88332),s=n(71100);function o(){let[e]=(0,i.g)();return(0,s.useEffect)(()=>{if(!e.hasNodes([r.EG,r.NK]))throw Error("ListPlugin: ListNode and/or ListItemNode not registered on editor")},[e]),(0,s.useEffect)(()=>(0,r.dA)(e),[e]),null}},72381:function(e,t,n){"use strict";n.d(t,{r:function(){return a}});var r=n(2369),i=n(88332),s=n(25994),o=n(71100);let l=[{dependencies:[s.HY],export:e=>(0,s.fs)(e)?"***":null,regExp:/^(---|\*\*\*|___)\s?$/,replace:(e,t,n,r)=>{let i=(0,s.Dq)();r||null!=e.getNextSibling()?e.replace(i):e.insertBefore(i),i.selectNext()},type:"element"},...r.XC];function a({transformers:e=l}){let[t]=(0,i.g)();return(0,o.useEffect)(()=>(0,r.AB)(t,e),[t,e]),null}},74680:function(e,t,n){"use strict";n.d(t,{B:function(){return g}});var r=n(88332),i=n(71100);let s="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement?i.useLayoutEffect:i.useEffect;function o(e){return{initialValueFn:()=>e.isEditable(),subscribe:t=>e.registerEditableListener(t)}}var l=n(40400),a=n(30913),u=n(34589),c=n(44825),d=n(18193),h=n(53938);let f="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement?i.useLayoutEffect:i.useEffect;function p(e){return e.getEditorState().read((0,l.yL)(e.isComposing()))}function g({contentEditable:e,placeholder:t=null,ErrorBoundary:n}){var s;let[o]=(0,r.g)(),l=function(e,t){let[n,r]=(0,i.useState)(()=>e.getDecorators());return f(()=>e.registerDecoratorListener(e=>{(0,u.flushSync)(()=>{r(e)})}),[e]),(0,i.useEffect)(()=>{r(e.getDecorators())},[e]),(0,i.useMemo)(()=>{let r=[],s=Object.keys(n);for(let o=0;o<s.length;o++){let l=s[o],a=(0,c.jsx)(t,{onError:t=>e._onError(t),children:(0,c.jsx)(i.Suspense,{fallback:null,children:n[l]})}),d=e.getElementByKey(l);null!==d&&r.push((0,u.createPortal)(a,d,l))}return r},[t,n,e])}(o,n);return f(()=>(0,a.qV)((0,h.ML)(s),function(e){let t=window.location.origin,n=n=>{if(n.origin!==t)return;let r=e.getRootElement();if(document.activeElement!==r)return;let i=n.data;if("string"==typeof i){let t;try{t=JSON.parse(i)}catch(e){return}if(t&&"nuanria_messaging"===t.protocol&&"request"===t.type){let r=t.payload;if(r&&"makeChanges"===r.functionId){let t=r.args;if(t){let[r,i,s,o,l,a]=t;e.update(()=>{let e=(0,d.dL)();if((0,d.OP)(e)){let t=e.anchor,a=t.getNode(),u=0,c=0;if((0,d.Gg)(a)&&r>=0&&i>=0&&(u=r,c=r+i,e.setTextNodeRange(a,u,a,c)),u===c&&""===s||(e.insertRawText(s),a=t.getNode()),(0,d.Gg)(a)){u=o,c=o+l;let t=a.getTextContentSize();u=u>t?t:u,c=c>t?t:c,e.setTextNodeRange(a,u,a,c)}n.stopImmediatePropagation()}})}}}}};return window.addEventListener("message",n,!0),()=>{window.removeEventListener("message",n,!0)}}(s)),[s=o]),(0,c.jsxs)(c.Fragment,{children:[e,(0,c.jsx)(m,{content:t}),l]})}function m({content:e}){let[t]=(0,r.g)(),n=function(e){let[t,n]=(0,i.useState)(()=>p(e));return f(()=>{function t(){n(p(e))}return t(),(0,a.qV)(e.registerUpdateListener(()=>{t()}),e.registerEditableListener(()=>{t()}))},[e]),t}(t),l=function(e){let[t]=(0,r.g)(),n=(0,i.useMemo)(()=>e(t),[t,e]),[o,l]=(0,i.useState)(()=>n.initialValueFn()),a=(0,i.useRef)(o);return s(()=>{let{initialValueFn:e,subscribe:t}=n,r=e();return a.current!==r&&(a.current=r,l(r)),t(e=>{a.current=e,l(e)})},[n,e]),o}(o);return n?"function"==typeof e?e(l):e:null}},66518:function(e,t,n){"use strict";n.d(t,{y:function(){return l}});var r=n(88332),i=n(18193),s=n(71100);function o(e,t){return e.getEditorState().read(()=>{let e=(0,i.gI)(t);return null!==e&&e.isSelected()})}
1function l(e){let[t]=(0,r.g)(),[n,l]=(0,s.useState)(()=>o(t,e));return(0,s.useEffect)(()=>{let n=!0,r=t.registerUpdateListener(()=>{n&&l(o(t,e))});return()=>{n=!1,r()}},[t,e]),[n,(0,s.useCallback)(n=>{t.update(()=>{let t=(0,i.dL)();(0,i.iO)(t)||(t=(0,i.h5)(),(0,i.oq)(t)),(0,i.iO)(t)&&(n?t.add(e):t.delete(e))})},[t,e]),(0,s.useCallback)(()=>{t.update(()=>{let e=(0,i.dL)();(0,i.iO)(e)&&e.clear()})},[t])]}},53938:function(e,t,n){"use strict";n.d(t,{V1:function(){return F},Z1:function(){return T},rc:function(){return O},O:function(){return C},c2:function(){return k},rT:function(){return E},UW:function(){return D},ML:function(){return R}});var r,i=n(63759),s=n(18193);let o=new Set(["STYLE","SCRIPT"]);var l=n(30913),a=(r=function(e){let t=new URLSearchParams;t.append("code",e);for(let e=1;e<arguments.length;e++)t.append("v",arguments[e]);throw Error(`Minified Lexical error #${e}; visit https://lexical.dev/docs/error?${t} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}).__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r;function u(e,t,n){let r=e.getData("application/x-lexical-editor");if(r)try{let e=JSON.parse(r);if(e.namespace===n._config.namespace&&Array.isArray(e.nodes))return c(n,function(e){let t=[];for(let n=0;n<e.length;n++){let r=e[n],o=(0,s.oC)(r);(0,s.Gg)(o)&&(0,i.vV)(o),t.push(o)}return t}(e.nodes),t)}catch(e){}let l=e.getData("text/html"),a=e.getData("text/plain");if(l&&a!==l)try{let e=(new DOMParser).parseFromString(window.trustedTypes&&window.trustedTypes.createPolicy?window.trustedTypes.createPolicy("lexical",{createHTML:e=>e}).createHTML(l):l,"text/html");return c(n,function(e,t){let n=t.body?t.body.childNodes:[],r=[],i=[];for(let t=0;t<n.length;t++){let l=n[t];if(!o.has(l.nodeName)){let t=function e(t,n,r,i,l=new Map,a){let u=[];if(o.has(t.nodeName))return u;let c=null,d=function(e,t){let{nodeName:n}=e,r=t._htmlConversions.get(n.toLowerCase()),i=null;if(void 0!==r)for(let t of r){let n=t(e);null!==n&&(null===i||(i.priority||0)<=(n.priority||0))&&(i=n)}return null!==i?i.conversion:null}(t,n),h=d?d(t):null,f=null;if(null!==h){f=h.after;let e=h.node;if(null!==(c=Array.isArray(e)?e[e.length-1]:e)){for(let[,e]of l)if(!(c=e(c,a)))break;c&&u.push(...Array.isArray(e)?e:[c])}null!=h.forChild&&l.set(t.nodeName,h.forChild)}let p=t.childNodes,g=[],m=(null==c||!(0,s._v)(c))&&(null!=c&&(0,s.ek)(c)||i);for(let t=0;t<p.length;t++)g.push(...e(p[t],n,r,m,new Map(l),c));return null!=f&&(g=f(g)),(0,s.lv)(t)&&(g=function(e,t,n){let r=e.style.textAlign,i=[],o=[];for(let e=0;e<t.length;e++){let l=t[e];if((0,s.ek)(l))r&&!l.getFormat()&&l.setFormat(r),i.push(l);else if(o.push(l),e===t.length-1||e<t.length-1&&(0,s.ek)(t[e+1])){let e=n();e.setFormat(r),e.append(...o),i.push(e),o=[]}}return i}(t,g,m?()=>{let e=new s.RG;return r.push(e),e}:s.BE)),null==c?g.length>0?u=u.concat(g):(0,s.lv)(t)&&null!=t.nextSibling&&null!=t.previousSibling&&(0,s.u8)(t.nextSibling)&&(0,s.u8)(t.previousSibling)&&(u=u.concat((0,s.T)())):(0,s.F7)(c)&&c.append(...g),u}(l,e,i,!1);null!==t&&(r=r.concat(t))}}return function(e){for(let t of e)t.getNextSibling() instanceof s.RG&&t.insertAfter((0,s.T)());for(let t of e){for(let e of t.getChildren())t.insertBefore(e);t.remove()}}(i),r}(n,e),t)}catch(e){}let u=a||e.getData("text/uri-list");if(null!=u){if((0,s.OP)(t)){let e=u.split(/(\r?\n|\t)/);""===e[e.length-1]&&e.pop();for(let t=0;t<e.length;t++){let n=(0,s.dL)();if((0,s.OP)(n)){let r=e[t];"\n"===r||"\r\n"===r?n.insertParagraph():"	"===r?n.insertNodes([(0,s.S3)()]):n.insertText(r)}}}else t.insertRawText(u)}}function c(e,t,n){e.dispatchCommand(s.zr,{nodes:t,selection:n})||n.insertNodes(t)}let d=null;async function h(e,t,n){if(null!==d)return!1;if(null!==t)return new Promise((r,i)=>{e.update(()=>{r(f(e,t,n))})});let r=e.getRootElement(),i=e._window||window,o=window.document,a=(0,s.In)(i);if(null===r||null===a)return!1;let u=o.createElement("span");u.style.cssText="position: fixed; top: -1000px;",u.append(o.createTextNode("#")),r.append(u);let c=new Range;return c.setStart(u,0),c.setEnd(u,1),a.removeAllRanges(),a.addRange(c),new Promise((t,r)=>{let i=e.registerCommand(s.LV,r=>((0,l.nh)(r,ClipboardEvent)&&(i(),null!==d&&(window.clearTimeout(d),d=null),t(f(e,r,n))),!0),s.jw);d=window.setTimeout(()=>{i(),d=null,t(!1)},50),o.execCommand("copy"),u.remove()})}function f(e,t,n){if(void 0===n){let t=(0,s.In)(e._window);if(!t)return!1;let r=t.anchorNode,i=t.focusNode;if(null!==r&&null!==i&&!(0,s.af)(e,r,i))return!1;let o=(0,s.dL)();if(null===o)return!1;n=function(e=(0,s.dL)()){let t={"text/plain":e?e.getTextContent():""};if(e){let n=(0,s.mJ)();for(let[r,i]of p){let s=i(n,e);null!==s&&(t[r]=s)}}return t}(o)}t.preventDefault();let r=t.clipboardData;return null!==r&&(function(e,t){for(let n in t){let r=t[n];void 0!==r&&e.setData(n,r)}}(r,n),!0)}let p=[["text/html",function(e,t=(0,s.dL)()){return null==t&&a(166),(0,s.OP)(t)&&t.isCollapsed()||0===t.getNodes().length?"":function(e,t){if("undefined"==typeof document||"undefined"==typeof window&&void 0===global.window)throw Error("To use $generateHtmlFromNodes in headless mode please initialize a headless browser implementation such as JSDom before calling this function.");let n=document.createElement("div"),r=(0,s.Gv)().getChildren();for(let o=0;o<r.length;o++)(function e(t,n,r,o=null){let l=null===o||n.isSelected(o),a=(0,s.F7)(n)&&n.excludeFromCopy("html"),u=n;if(null!==o){let e=(0,s.B3)(n);u=e=(0,s.Gg)(e)&&null!==o?(0,i.bA)(o,e):e}let c=(0,s.F7)(u)?u.getChildren():[],d=t._nodes.get(u.getType()),{element:h,after:f}=d&&void 0!==d.exportDOM?d.exportDOM(t,u):u.exportDOM(t);
1if(!h)return!1;let p=document.createDocumentFragment();for(let r=0;r<c.length;r++){let i=c[r],a=e(t,i,p,o);!l&&(0,s.F7)(n)&&a&&n.extractWithChild(i,o,"html")&&(l=!0)}if(l&&!a){if(((0,s.Re)(h)||(0,s.fn)(h))&&h.append(p),r.append(h),f){let e=f.call(u,h);e&&((0,s.fn)(h)?h.replaceChildren(e):h.replaceWith(e))}}else r.append(p);return l})(e,r[o],n,t);return n.innerHTML}(e,t)}],["application/x-lexical-editor",function(e,t=(0,s.dL)()){return null==t&&a(166),(0,s.OP)(t)&&t.isCollapsed()||0===t.getNodes().length?null:JSON.stringify(function(e,t){let n=[],r=(0,s.Gv)().getChildren();for(let o=0;o<r.length;o++)!function e(t,n,r,o=[]){let l=null===n||r.isSelected(n),u=(0,s.F7)(r)&&r.excludeFromCopy("html"),c=r;if(null!==n){let e=(0,s.B3)(r);c=e=(0,s.Gg)(e)&&null!==n?(0,i.bA)(n,e):e}let d=(0,s.F7)(c)?c.getChildren():[],h=function(e){let t=e.exportJSON(),n=e.constructor;return t.type!==n.getType()&&a(58,n.name),(0,s.F7)(e)&&(Array.isArray(t.children)||a(59,n.name)),t}(c);if((0,s.Gg)(c)){let e=c.__text;e.length>0?h.text=e:l=!1}for(let i=0;i<d.length;i++){let o=d[i],a=e(t,n,o,h.children);!l&&(0,s.F7)(r)&&a&&r.extractWithChild(o,n,"clone")&&(l=!0)}if(l&&!u)o.push(h);else if(Array.isArray(h.children))for(let e=0;e<h.children.length;e++){let t=h.children[e];o.push(t)}return l}(e,t,r[o],n);return{namespace:e._config.namespace,nodes:n}}(e,t))}]];function g(e,t){if(void 0!==document.caretRangeFromPoint){let n=document.caretRangeFromPoint(e,t);return null===n?null:{node:n.startContainer,offset:n.startOffset}}if("undefined"!==document.caretPositionFromPoint){let n=document.caretPositionFromPoint(e,t);return null===n?null:{node:n.offsetNode,offset:n.offset}}return null}let m="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement,y=m&&"documentMode"in document?document.documentMode:null,v=!(!m||!("InputEvent"in window)||y)&&"getTargetRanges"in new window.InputEvent("input"),_=m&&/Version\/[\d.]+.*Safari/.test(navigator.userAgent),b=m&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream,x=m&&/^(?=.*Chrome).*/i.test(navigator.userAgent),S=m&&/AppleWebKit\/[\d.]+/.test(navigator.userAgent)&&!x,w=(0,s.fA)("DRAG_DROP_PASTE_FILE");class E extends s.HX{static getType(){return"quote"}static clone(e){return new E(e.__key)}createDOM(e){let t=document.createElement("blockquote");return(0,l.Yo)(t,e.theme.quote),t}updateDOM(e,t){return!1}static importDOM(){return{blockquote:e=>({conversion:N,priority:0})}}exportDOM(e){let{element:t}=super.exportDOM(e);if((0,s.Re)(t)){this.isEmpty()&&t.append(document.createElement("br"));let e=this.getFormatType();t.style.textAlign=e;let n=this.getDirection();n&&(t.dir=n)}return{element:t}}static importJSON(e){return T().updateFromJSON(e)}insertNewAfter(e,t){let n=(0,s.BE)(),r=this.getDirection();return n.setDirection(r),this.insertAfter(n,t),n}collapseAtStart(){let e=(0,s.BE)();
1return this.getChildren().forEach(t=>e.append(t)),this.replace(e),!0}canMergeWhenEmpty(){return!0}}function T(){return(0,s.U2)(new E)}function C(e){return e instanceof E}class k extends s.HX{static getType(){return"heading"}static clone(e){return new k(e.__tag,e.__key)}constructor(e,t){super(t),this.__tag=e}getTag(){return this.__tag}setTag(e){let t=this.getWritable();return this.__tag=e,t}createDOM(e){let t=this.__tag,n=document.createElement(t),r=e.theme.heading;if(void 0!==r){let e=r[t];(0,l.Yo)(n,e)}return n}updateDOM(e,t,n){return e.__tag!==this.__tag}static importDOM(){return{h1:e=>({conversion:P,priority:0}),h2:e=>({conversion:P,priority:0}),h3:e=>({conversion:P,priority:0}),h4:e=>({conversion:P,priority:0}),h5:e=>({conversion:P,priority:0}),h6:e=>({conversion:P,priority:0}),p:e=>{let t=e.firstChild;return null!==t&&A(t)?{conversion:()=>({node:null}),priority:3}:null},span:e=>A(e)?{conversion:e=>({node:F("h1")}),priority:3}:null}}exportDOM(e){let{element:t}=super.exportDOM(e);if((0,s.Re)(t)){this.isEmpty()&&t.append(document.createElement("br"));let e=this.getFormatType();t.style.textAlign=e;let n=this.getDirection();n&&(t.dir=n)}return{element:t}}static importJSON(e){return F(e.tag).updateFromJSON(e)}updateFromJSON(e){return super.updateFromJSON(e).setTag(e.tag)}exportJSON(){return{...super.exportJSON(),tag:this.getTag()}}insertNewAfter(e,t=!0){let n=e?e.anchor.offset:0,r=this.getLastDescendant(),i=r&&(!e||e.anchor.key!==r.getKey()||n!==r.getTextContentSize())&&e?F(this.getTag()):(0,s.BE)(),o=this.getDirection();if(i.setDirection(o),this.insertAfter(i,t),0===n&&!this.isEmpty()&&e){let e=(0,s.BE)();e.select(),this.replace(e,!0)}return i}collapseAtStart(){let e=this.isEmpty()?(0,s.BE)():F(this.getTag());
1return this.getChildren().forEach(t=>e.append(t)),this.replace(e),!0}extractWithChild(){return!0}}function A(e){return"span"===e.nodeName.toLowerCase()&&"26pt"===e.style.fontSize}function P(e){let t=e.nodeName.toLowerCase(),n=null;return"h1"!==t&&"h2"!==t&&"h3"!==t&&"h4"!==t&&"h5"!==t&&"h6"!==t||(n=F(t),null!==e.style&&((0,s.WA)(e,n),n.setFormat(e.style.textAlign))),{node:n}}function N(e){let t=T();return null!==e.style&&(t.setFormat(e.style.textAlign),(0,s.WA)(e,t)),{node:t}}function F(e="h1"){return(0,s.U2)(new k(e))}function O(e){return e instanceof k}function D(e){let t=null;if((0,l.nh)(e,DragEvent)?t=e.dataTransfer:(0,l.nh)(e,ClipboardEvent)&&(t=e.clipboardData),null===t)return[!1,[],!1];let n=t.types,r=n.includes("Files"),i=n.includes("text/html")||n.includes("text/plain");return[r,Array.from(t.files),i]}function L(e){let t=(0,s.dL)();if(!(0,s.OP)(t))return!1;let n=new Set,r=t.getNodes();for(let t=0;t<r.length;t++){let i=r[t],o=i.getKey();if(n.has(o))continue;let a=(0,l.$s)(i,e=>(0,s.F7)(e)&&!e.isInline());if(null===a)continue;let u=a.getKey();a.canIndent()&&!n.has(u)&&(n.add(u),e(a))}return n.size>0}function I(e){let t=(0,s.Xo)(e);return(0,s.k$)(t)}function M(e){for(let t of["lowercase","uppercase","capitalize"])e.hasFormat(t)&&e.toggleFormat(t)}function R(e){return(0,l.qV)(e.registerCommand(s.Kr,e=>{let t=(0,s.dL)();return!!(0,s.iO)(t)&&(t.clear(),!0)},0),e.registerCommand(s.Mt,e=>{let t=(0,s.dL)();return!!(0,s.OP)(t)&&(t.deleteCharacter(e),!0)},s.VN),e.registerCommand(s.cj,e=>{let t=(0,s.dL)();return!!(0,s.OP)(t)&&(t.deleteWord(e),!0)},s.VN),e.registerCommand(s.n2,e=>{let t=(0,s.dL)();return!!(0,s.OP)(t)&&(t.deleteLine(e),!0)},s.VN),e.registerCommand(s.yF,t=>{let n=(0,s.dL)();if("string"==typeof t)null!==n&&n.insertText(t);else{if(null===n)return!1;let r=t.dataTransfer;if(null!=r)u(r,n,e);else if((0,s.OP)(n)){let e=t.data;return e&&n.insertText(e),!0}}return!0},s.VN),e.registerCommand(s.RJ,()=>{let e=(0,s.dL)();return!!(0,s.OP)(e)&&(e.removeText(),!0)},s.VN),e.registerCommand(s.Ew,e=>{let t=(0,s.dL)();return!!(0,s.OP)(t)&&(t.formatText(e),!0)},s.VN),e.registerCommand(s.RO,e=>{let t=(0,s.dL)();if(!(0,s.OP)(t)&&!(0,s.iO)(t))return!1;for(let n of t.getNodes()){let t=(0,l.$s)(n,e=>(0,s.F7)(e)&&!e.isInline());null!==t&&t.setFormat(e)}return!0},s.VN),e.registerCommand(s.WH,e=>{let t=(0,s.dL)();return!!(0,s.OP)(t)&&(t.insertLineBreak(e),!0)},s.VN),e.registerCommand(s.K0,()=>{let e=(0,s.dL)();return!!(0,s.OP)(e)&&(e.insertParagraph(),!0)},s.VN),e.registerCommand(s.cA,()=>((0,s.od)([(0,s.S3)()]),!0),s.VN),e.registerCommand(s.PU,()=>L(e=>{let t=e.getIndent();e.setIndent(t+1)}),s.VN),e.registerCommand(s.cz,()=>L(e=>{let t=e.getIndent();t>0&&e.setIndent(t-1)}),s.VN),e.registerCommand(s._0,e=>{let t=(0,s.dL)();if((0,s.iO)(t)&&!I(e.target)){let e=t.getNodes();if(e.length>0)return e[0].selectPrevious(),!0}else if((0,s.OP)(t)){let n=(0,s.fL)(t.focus,!0);if(!e.shiftKey&&(0,s.k$)(n)&&!n.isIsolated()&&!n.isInline())return n.selectPrevious(),e.preventDefault(),!0}return!1},s.VN),e.registerCommand(s.Zb,e=>{let t=(0,s.dL)();if((0,s.iO)(t)){let e=t.getNodes();if(e.length>0)return e[0].selectNext(0,0),!0}else if((0,s.OP)(t)){if(function(e){let t=e.focus;return"root"===t.key&&t.offset===(0,s.Gv)().getChildrenSize()}(t))return e.preventDefault(),!0;let n=(0,s.fL)(t.focus,!1);if(!e.shiftKey&&(0,s.k$)(n)&&!n.isIsolated()&&!n.isInline())return n.selectNext(),e.preventDefault(),!0}return!1},s.VN),e.registerCommand(s.u$,e=>{let t=(0,s.dL)();if((0,s.iO)(t)){let n=t.getNodes();if(n.length>0)return e.preventDefault(),n[0].selectPrevious(),!0}if(!(0,s.OP)(t))return!1;if((0,i.pi)(t,!0)){let n=e.shiftKey;return e.preventDefault(),(0,i.i0)(t,n,!0),!0}return!1},s.VN),e.registerCommand(s.Nm,e=>{let t=(0,s.dL)();if((0,s.iO)(t)&&!I(e.target)){let n=t.getNodes();if(n.length>0)return e.preventDefault(),n[0].selectNext(0,0),!0}if(!(0,s.OP)(t))return!1;let n=e.shiftKey;return!!(0,i.pi)(t,!1)&&(e.preventDefault(),(0,i.i0)(t,n,!1),!0)},s.VN),e.registerCommand(s.aR,t=>{if(I(t.target))return!1;let n=(0,s.dL)();if(!(0,s.OP)(n))return!1;let{anchor:r}=n,i=r.getNode();return n.isCollapsed()&&0===r.offset&&!(0,s.wd)(i)&&(0,l.f8)(i).getIndent()>0?(t.preventDefault(),e.dispatchCommand(s.cz,void 0)):(!b||"ko-KR"!==navigator.language)&&(t.preventDefault(),e.dispatchCommand(s.Mt,!0))},s.VN),e.registerCommand(s.MK,t=>{if(I(t.target))return!1;let n=(0,s.dL)();return!!(0,s.OP)(n)&&(t.preventDefault(),e.dispatchCommand(s.Mt,!1))},s.VN),e.registerCommand(s.XN,t=>{let n=(0,s.dL)();if(!(0,s.OP)(n))return!1;if(M(n),null!==t){if((b||_||S)&&v)return!1;if(t.preventDefault(),t.shiftKey)return e.dispatchCommand(s.WH,!1)}return e.dispatchCommand(s.K0,void 0)},s.VN),e.registerCommand(s.Zq,()=>{let t=(0,s.dL)();return!!(0,s.OP)(t)&&(e.blur(),!0)},s.VN),e.registerCommand(s.zD,t=>{let[,n]=D(t);if(n.length>0){let r=g(t.clientX,t.clientY);if(null!==r){let{offset:t,node:i}=r,o=(0,s.Xo)(i);if(null!==o){let e=(0,s.vN)();if((0,s.Gg)(o))e.anchor.set(o.getKey(),t,"text"),e.focus.set(o.getKey(),t,"text");else{let t=o.getParentOrThrow().getKey(),n=o.getIndexWithinParent()+1;e.anchor.set(t,n,"element"),e.focus.set(t,n,"element")}let n=(0,s.S9)(e);(0,s.oq)(n)}e.dispatchCommand(w,n)}return t.preventDefault(),!0}let r=(0,s.dL)();return!!(0,s.OP)(r)},s.VN),e.registerCommand(s.XI,e=>{let[t]=D(e),n=(0,s.dL)();return!(t&&!(0,s.OP)(n))},s.VN),e.registerCommand(s.kE,e=>{let[t]=D(e),n=(0,s.dL)();if(t&&!(0,s.OP)(n))return!1;let r=g(e.clientX,e.clientY);if(null!==r){let t=(0,s.Xo)(r.node);(0,s.k$)(t)&&e.preventDefault()}return!0},s.VN),e.registerCommand(s.Hr,()=>((0,s.UL)(),!0),s.VN),e.registerCommand(s.LV,t=>(h(e,(0,l.nh)(t,ClipboardEvent)?t:null),!0),s.VN),e.registerCommand(s.dR,t=>((async function(e,t){await h(t,(0,l.nh)(e,ClipboardEvent)?e:null),t.update(()=>{let e=(0,s.dL)();
1(0,s.OP)(e)?e.removeText():(0,s.iO)(e)&&e.getNodes().forEach(e=>e.remove())})})(t,e),!0),s.VN),e.registerCommand(s.A1,t=>{let[,n,r]=D(t);return n.length>0&&!r?(e.dispatchCommand(w,n),!0):!((0,s.uF)(t.target)&&(0,s.GA)(t.target))&&null!==(0,s.dL)()&&(t.preventDefault(),e.update(()=>{let n=(0,s.dL)(),r=(0,l.nh)(t,InputEvent)||(0,l.nh)(t,KeyboardEvent)?null:t.clipboardData;null!=r&&null!==n&&u(r,n,e)},{tag:"paste"}),!0)},s.VN),e.registerCommand(s.Y7,e=>{let t=(0,s.dL)();return(0,s.OP)(t)&&M(t),!1},s.VN),e.registerCommand(s.dB,e=>{let t=(0,s.dL)();return(0,s.OP)(t)&&M(t),!1},s.VN))}},63759:function(e,t,n){"use strict";n.d(t,{FN:function(){return u},Hz:function(){return h},XM:function(){return a},bA:function(){return c},i0:function(){return p},pi:function(){return f},vV:function(){return d}});var r,i=n(18193);(r=function(e){let t=new URLSearchParams;t.append("code",e);for(let e=1;e<arguments.length;e++)t.append("v",arguments[e]);throw Error(`Minified Lexical error #${e}; visit https://lexical.dev/docs/error?${t} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}).__esModule&&Object.prototype.hasOwnProperty.call(r,"default")&&r.default;let s=new Map;function o(e){let t=e;for(;null!=t;){if(t.nodeType===Node.TEXT_NODE)return t;t=t.firstChild}return null}function l(e){let t=e.parentNode;if(null==t)throw Error("Should never happen");return[t,Array.from(t.childNodes).indexOf(e)]}function a(e,t,n,r,s){let a=t.getKey(),u=r.getKey(),c=document.createRange(),d=e.getElementByKey(a),h=e.getElementByKey(u),f=n,p=s;if((0,i.Gg)(t)&&(d=o(d)),(0,i.Gg)(r)&&(h=o(h)),void 0===t||void 0===r||null===d||null===h)return null;"BR"===d.nodeName&&([d,f]=l(d)),"BR"===h.nodeName&&([h,p]=l(h));let g=d.firstChild;d===h&&null!=g&&"BR"===g.nodeName&&0===f&&0===p&&(p=1);try{c.setStart(d,f),c.setEnd(h,p)}catch(e){return null}return c.collapsed&&(f!==p||a!==u)&&(c.setStart(h,p),c.setEnd(d,f)),c}function u(e,t){let n=e.getRootElement();if(null===n)return[];let r=n.getBoundingClientRect(),i=getComputedStyle(n),s=parseFloat(i.paddingLeft)+parseFloat(i.paddingRight),o=Array.from(t.getClientRects()),l,a=o.length;o.sort((e,t)=>{let n=e.top-t.top;return 3>=Math.abs(n)?e.left-t.left:n});for(let e=0;e<a;e++){let t=o[e],n=l&&l.top<=t.top&&l.top+l.height>t.top&&l.left+l.width>t.left,i=t.width+s===r.width;n||i?(o.splice(e--,1),a--):l=t}return o}function c(e,t){let n=e.getStartEndPoints();if(t.isSelected(e)&&!t.isSegmented()&&!t.isToken()&&null!==n){let[r,s]=n,o=e.isBackward(),l=r.getNode(),a=s.getNode(),u=t.is(l),c=t.is(a);if(u||c){let[n,r]=(0,i.cs)(e),s=l.is(a),u=t.is(o?a:l),c=t.is(o?l:a),d,h=0;return s?(h=n>r?r:n,d=n>r?n:r):u?(h=o?r:n,d=void 0):c&&(h=0,d=o?n:r),t.__text=t.__text.slice(h,d),t}}return t}function d(e){let t=e.getStyle(),n=function(e){let t={};if(!e)return t;for(let n of e.split(";"))if(""!==n){let[e,r]=n.split(/:([^]+)/);e&&r&&(t[e.trim()]=r.trim())}return t}(t);s.set(t,n)}function h(e,t){if(null===e)return;let n=e.getStartEndPoints(),r=n?n[0]:null,s=e.is((0,i.dL)())&&e.isCollapsed();if(null!==r&&"root"===r.key){let e=t(),n=(0,i.Gv)(),r=n.getFirstChild();return r?r.replace(e,!0):n.append(e),void(s&&e.select())}let o=e.getNodes().filter(i.kk).filter(i.F7),l=r?function(e,t){let n=e;for(;null!==n&&null!==n.getParent()&&!t(n);)n=n.getParentOrThrow();return t(n)?n:null}(r.getNode(),i.kk):null;for(let e of((0,i.F7)(l)&&!o.find(e=>e.is(l))&&o.push(l),o)){let n=t();n.setFormat(e.getFormatType()),n.setIndent(e.getIndent()),e.replace(n,!0),e.is(l)&&s&&n.select()}}function f(e,t){let n=(0,i.fL)(e.focus,t);return(0,i.k$)(n)&&!n.isIsolated()||(0,i.F7)(n)&&!n.isInline()&&!n.canBeEmpty()}function p(e,t,n){let r=function(e){let t=e.anchor.getNode();return"rtl"===((0,i.wd)(t)?t:t.getParentOrThrow()).getDirection()}(e);!function(e,t,n,r){e.modify(t?"extend":"move",n,r)}(e,t,n?!r:r,"character")}},40400:function(e,t,n){"use strict";n.d(t,{yL:function(){return s}});var r,i=n(18193);function s(e){return()=>(function(e){if(!function(e,t=!0){if(e)return!1;let n=(0,i.Gv)().getTextContent();return t&&(n=n.trim()),""===n}(e,!1))return!1;let t=(0,i.Gv)().getChildren(),n=t.length;if(n>1)return!1;for(let e=0;e<n;e++){let n=t[e];if((0,i.k$)(n))return!1;if((0,i.F7)(n)){if(!(0,i.Rl)(n)||0!==n.__indent)return!1;let t=n.getChildren(),r=t.length;for(let n=0;n<r;n++){let n=t[e];if(!(0,i.Gg)(n))return!1}}}return!0})(e)}(r=function(e){let t=new URLSearchParams;t.append("code",e);for(let e=1;e<arguments.length;e++)t.append("v",arguments[e]);throw Error(`Minified Lexical error #${e}; visit https://lexical.dev/docs/error?${t} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}).__esModule&&Object.prototype.hasOwnProperty.call(r,"default")&&r.default},30913:function(e,t,n){"use strict";n.d(t,{$s:function(){return v},Ho:function(){return _},MZ:function(){return S},PS:function(){return h},Yo:function(){return d},f8:function(){return y},nh:function(){return b},qV:function(){return c},ss:function(){return f},yD:function(){return m}});var r,i=n(18193),s=(r=function(e){let t=new URLSearchParams;t.append("code",e);for(let e=1;e<arguments.length;e++)t.append("v",arguments[e]);throw Error(`Minified Lexical error #${e}; visit https://lexical.dev/docs/error?${t} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}).__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r;let o="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement,l=o&&"documentMode"in document?document.documentMode:null,a=(o&&/Mac|iPod|iPhone|iPad/.test(navigator.platform),o&&/^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent));function u(...e){let t=[];for(let n of e)if(n&&"string"==typeof n)for(let[e]of n.matchAll(/\S+/g))t.push(e);return t}function c(...e){return()=>{for(let t=e.length-1;t>=0;t--)e[t]();e.length=0}}function d(e,...t){let n=u(...t);n.length>0&&e.classList.add(...n)}function h(e,...t){let n=u(...t);n.length>0&&e.classList.remove(...n)}function f(e,t){return Array.from(function(e,t){let n=(e||(0,i.Gv)()).getLatest(),r=function(e){let t=e,n=0;for(;null!==(t=t.getParent());)n++;return n}(n),s=n,o=r,l=!0,a={next(){if(null===s)return p;if(l)return l=!1,g({depth:o,node:s});if(s===t)return p;if((0,i.F7)(s)&&s.getChildrenSize()>0)s=s.getFirstChild(),o++;else{let e;[s,e]=function(e){let t=e,n=null,r=0;for(;null===n&&null!==t;)null===(n=t.getNextSibling())?(t=t.getParent(),r--):t=n;return null===t?null:[t,r]}(s)||[null,0],o+=e,null==t&&o<=r&&(s=null)}return null===s?p:g({depth:o,node:s})},[Symbol.iterator]:()=>a};return a}(e,t))}o&&"InputEvent"in window&&!l&&new window.InputEvent("input"),o&&/Version\/[\d.]+.*Safari/.test(navigator.userAgent),o&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&window.MSStream,o&&/Android/.test(navigator.userAgent),o&&/^(?=.*Chrome).*/i.test(navigator.userAgent),o&&/AppleWeb
1Kit\/[\d.]+/.test(navigator.userAgent);let p={done:!0,value:void 0},g=e=>({done:!1,value:e});function m(e,t){let n=e;for(;null!=n;){if(n instanceof t)return n;n=n.getParent()}return null}function y(e){let t=v(e,e=>(0,i.F7)(e)&&!e.isInline());return(0,i.F7)(t)||s(4,e.__key),t}let v=(e,t)=>{let n=e;for(;n!==(0,i.Gv)()&&null!=n;){if(t(n))return n;n=n.getParent()}return null};function _(e,t,n,r){let i=e=>e instanceof t;return e.registerNodeTransform(t,e=>{let t=(e=>{let t=e.getChildren();for(let e=0;e<t.length;e++)if(i(t[e]))return null;let n=e,r=e;for(;null!==n;)if(r=n,i(n=n.getParent()))return{child:r,parent:n};return null})(e);if(null!==t){let{child:i,parent:s}=t;if(i.is(e)){r(s,e);let t=i.getNextSiblings(),o=t.length;if(s.insertAfter(i),0!==o){let e=n(s);i.insertAfter(e);for(let n=0;n<o;n++)e.append(t[n])}s.canBeEmpty()||0!==s.getChildrenSize()||s.remove()}}})}function b(e,t){return null!==e&&Object.getPrototypeOf(e).constructor.name===t.name}let x=!(a||!o)&&void 0;function S(e){let t=1;if(function(){if(void 0===x){let e=document.createElement("div");e.style.cssText="position: absolute; opacity: 0; width: 100px; left: -1000px;",document.body.appendChild(e);let t=e.getBoundingClientRect();e.style.setProperty("zoom","2"),x=e.getBoundingClientRect().width===t.width,document.body.removeChild(e)}return x}())for(;e;)t*=Number(window.getComputedStyle(e).getPropertyValue("zoom")),e=e.parentElement;return t}},50015:function(e,t,n){"use strict";n.d(t,{Y:function(){return p},i:function(){return g}});var r=n(44825),i=n(88332),s=n(78738),o=n(88587),l=n(19554),a=n(96369),u=n(18193),c=n(71100),d=n(53947),h=n(33956),f=n(43307);function p(e,t){let n=e.compareDocumentPosition(t);return n&Node.DOCUMENT_POSITION_FOLLOWING?-1:n&Node.DOCUMENT_POSITION_PRECEDING?1:0}function g({threads:e,components:t,className:n,style:u,...h}){let[f]=(0,i.g)(),g=(0,l.U)(t?.Thread,o.j),_=(0,c.useRef)(null),b=v(),x=y(),S=(0,c.useCallback)(()=>e.filter(e=>!1===e.resolved).map(e=>{let t=x.get(e.id);if(void 0===t||0===t.size)return null;let n=Array.from(t.values()).map(e=>f.getElementByKey(e)).filter(Boolean);return 0===n.length?null:{thread:e,element:n.sort(p)[0]}}).filter(e=>null!==e).sort((e,t)=>p(e.element,t.element)),[f,e,x]),w=(0,c.useMemo)(S,[S]),[E,T]=(0,c.useState)(new Map),[C,k]=(0,c.useState)(new Map),A=(0,c.useCallback)((e,t)=>{T(n=>new Map(n).set(e,t))},[]),P=(0,c.useCallback)(e=>{T(t=>{let n=new Map(t);return n.delete(e),n})},[]),N=(0,c.useCallback)(()=>{let e=_.current;if(null===e)return;let t=S(),n=function(){if(0===b.length)return t;let e=t.filter(({thread:e})=>b.includes(e.id)),n=t.filter(({thread:t,element:n})=>!b.includes(t.id)&&e.some(({element:e})=>-1===p(e,n)));return e.concat(n)}(),r=t.filter(e=>!n.includes(e)),i=new Map;for(let{thread:t,element:r}of n){let n=r.getBoundingClientRect().top-e.getBoundingClientRect().top;for(let[e,t]of i){let r=E.get(e);void 0!==r&&n>=t&&n<=t+r.getBoundingClientRect().height&&(n=t+r.getBoundingClientRect().height)}i.set(t.id,n)}for(let{thread:t,element:n}of r.reverse()){let r=n.getBoundingClientRect(),s=E.get(t.id);if(void 0===s)continue;let o=r.top-e.getBoundingClientRect().top;for(let[,e]of i)o>=e-s.getBoundingClientRect().height&&(o=e-s.getBoundingClientRect().height);i.set(t.id,o)}k(i)},[S,b,E]);(0,s.bt)(()=>{N()},[N]),(0,c.useEffect)(()=>f.registerUpdateListener(()=>{N()}),[f,N]),(0,c.useEffect)(()=>{let e=new ResizeObserver(N);for(let t of E.values())e.observe(t);return()=>e.disconnect()},[E,N]);let F=(0,d.s)();return((0,c.useEffect)(()=>{if(null===F)return;let e=new ResizeObserver(N);return e.observe(F),()=>e.disconnect()},[F,N]),0===w.length)?null:(0,r.jsx)("div",{...h,className:(0,a.cn)(n,"lb-root lb-lexical-anchored-threads"),ref:_,style:{position:"relative",...u},children:w.map(({thread:e,element:t})=>{let n=t.getBoundingClientRect(),i=null!==F?F.getBoundingClientRect().top:0,s=n.top-i;C.has(e.id)&&(s=C.get(e.id));let o=b.includes(e.id);return(0,r.jsx)(m,{Thread:g,thread:e,onItemAdd:A,onItemRemove:P,style:{position:"absolute",transform:`translate3d(${o?"var(--lb-lexical-anchored-threads-active-thread-offset, -12px)":0}, ${s}px, 0)`,insetInlineStart:0,inlineSize:"100%",paddingBlockEnd:"var(--lb-lexical-anchored-threads-gap, 20px)"}},e.id)})})}function m({onItemAdd:e,onItemRemove:t,thread:n,Thread:o,className:l,...d}){let[h]=(0,i.g)(),p=y(),g=(0,c.useRef)(null),m=v(),_=m.includes(n.id
1);return(0,s.bt)(()=>{let r=g.current;if(null!==r)return e(n.id,r),()=>{t(n.id)}},[n.id,e,t]),(0,r.jsx)("div",{ref:g,className:(0,a.cn)("lb-lexical-anchored-threads-thread-container",l),...d,children:(0,r.jsx)(o,{thread:n,"data-state":_?"active":"inactive",onClick:function(){let e=p.get(n.id);void 0!==e&&0!==e.size&&(m.includes(n.id)||h.update(()=>{let[t]=e,n=(0,u.gI)(t);(0,f.Ui)(n)&&n.selectStart()}))},className:"lb-lexical-anchored-threads-thread",showComposer:!!_})})}function y(){let e=(0,c.useContext)(h.Oh);if(null===e)throw Error("AnchoredThreads component must be used within a LiveblocksPlugin component.");return e}function v(){let e=(0,c.useContext)(h.Bx);if(null===e)throw Error("AnchoredThreads component must be used within LiveblocksPlugin.");return e}},33956:function(e,t,n){"use strict";n.d(t,{Bx:function(){return h},oW:function(){return g},Oh:function(){return p}});var r=n(44825),i=n(88332),s=n(30913),o=n(95054),l=n(9776),a=n(18193),u=n(71100),c=n(43307);let d=(0,u.createContext)(null),h=(0,u.createContext)(null),f=(0,u.createContext)(null),p=(0,u.createContext)(null);function g({children:e}){let[t,n]=(0,i.g)(),[g,m]=(0,u.useState)(new Map),[y,v]=(0,u.useState)([]),_=(0,l.m8)(),b=(0,l.kB)(),x=(0,u.useCallback)(e=>y.includes(e),[y]),S=(0,u.useCallback)(e=>{t.update(()=>{let t=g.get(e);if(void 0!==t)for(let n of t){let t=(0,a.gI)(n);(0,c.Ui)(t)&&(t.deleteID(e),0===t.getIDs().length&&function(e){let t=e.getChildren(),n=null;for(let r=0;r<t.length;r++){let i=t[r];null===n?e.insertBefore(i):n.insertAfter(i),n=i}e.remove()}(t))}})},[t,g]);(0,l.Nb)(e=>{"CREATE_THREAD_ERROR"===e.context.type&&e.context.roomId===b.id&&S(e.context.threadId)});let w=(0,l.UW)(_),E=b.id,T=(0,l.qs)(w.outputs.threads,(0,u.useCallback)(e=>e.findMany(E,{resolved:!1},"asc",void 0).map(e=>e.id),[E]),o.Xd);return(0,u.useEffect)(()=>{let e=function(){let e=new Set;for(let n of T){let r=g.get(n);if(void 0!==r)for(let n of r){let r=t.getElementByKey(n);null!==r&&e.add(r)}}return e}(),r=n.getTheme(),i=["lb-root","lb-lexical-thread-mark"];return r&&r.liveblocks&&"threadMark"in r.liveblocks&&i.push(r.liveblocks.threadMark),e.forEach(e=>{(0,s.Yo)(e,...i)}),()=>{e.forEach(e=>{(0,s.PS)(e,...i)})}},[n,t,g,T]),(0,u.useEffect)(()=>t.registerMutationListener(c.lz,function(e){let n=t.getEditorState();m(t=>{let r=new Map(t);return n.read(()=>{for(let[t,n]of e)if("destroyed"===n)for(let[,e]of r)e.delete(t);else if("created"===n||"updated"===n){let e=(0,a.gI)(t);if(!(0,c.Ui)(e))continue;for(let n of e.getIDs()){let e=r.get(n)??new Set;e.add(t),r.set(n,e)}}}),r})}),[t]),(0,u.useEffect)(()=>{function e(){v((function(e){if(null===e||!(0,a.OP)(e))return[];let t=e.anchor.getNode();return(0,a.Gg)(t)?function(e,t){let n=e;for(;null!==n;){if((0,c.Ui)(n))return n.getIDs();if((0,a.Gg)(n)&&t===n.getTextContentSize()){let e=n.getNextSibling();if((0,c.Ui)(e))return e.getIDs()}n=n.getParent()}return null}(t,e.anchor.offset)??[]:[]})((0,a.dL)()).filter(e=>w.outputs.threads.get().findMany(E,{resolved:!1},"asc",void 0).some(t=>t.id===e)))}let n=w.outputs.threads.subscribe(()=>{t.getEditorState().read(e)}),r=t.registerUpdateListener(({editorState:t})=>{t.read(e)});return()=>{r(),n()}},[t,_,E,w]),(0,u.useEffect)(()=>{let e=function(){let e=new Set;for(let n of y){let r=g.get(n);if(void 0!==r)for(let n of r){let r=t.getElementByKey(n);null!==r&&e.add(r)}}return e}();return e.forEach(e=>{e.setAttribute("data-state","active")}),()=>{e.forEach(e=>{e.removeAttribute("data-state")})}},[y,t,g]),(0,u.useEffect)(()=>(0,s.Ho)(t,c.lz,e=>(0,c.H7)(e.getIDs()),(e,t)=>{e.getIDs().forEach(e=>{t.addID(e)})}),[t]),(0,r.jsx)(d.Provider,{value:S,children:(0,r.jsx)(h.Provider,{value:y,children:(0,r.jsx)(f.Provider,{value:x,children:(0,r.jsx)(p.Provider,{value:g,children:e})})})})}},32487:function(e,t,n){"use strict";n.d(t,{Rr:function(){return b},us:function(){return v}});var r=n(44825),i=n(20089),s=n(58388),o=n(88332),l=n(9776),a=n(78738),u=n(3662),c=n(19554),d=n(17076),h=n(18193),f=n(71100);function p(e){let t=e;for(;null!==t;){if(t.nodeType===Node.TEXT_NODE)return t;t=t.firstChild}return null}function g(e){let t=e.parentNode;if(null===t)throw Error("Should never happen");return[t,Array.from(t.childNodes).indexOf(e)]}function m(e,t,n,r,i){let s=t.getKey(),o=r.getKey(),l=document.createRange(),a=e.getElementByKey(s),u=e.getElementByKey(o),c=n,d=i;if((0,h.Gg)(t)&&(a=p(a)),(0,h.Gg)(r)&&(u=p(u)),void 0===t||void 0===r||null===a||null===u)return null;"BR"===a.nodeName&&([a,c]=g(a)),"BR"===u.nodeName&&([u,d]=g(u));let f=a.firstChild;a===u&&null!==f&&"BR"===f.nodeName&&0===c&&0===d&&(d=1);try{l.setStart(a,c),l.setEnd(u,d)}catch(e){return null}return l.collapsed&&(c!==d||s!==o)&&(l.setStart(u,d),l.setEnd(a,c)),l}var y=n(43307);let v=(0,h.fA)("OPEN_FLOATING_COMPOSER_COMMAND"),_=(0,h.fA)("ATTACH_THREAD_COMMAND"),b=(0,f.forwardRef)(function(e,t){let[n,i]=(0,f.useState)(null),[s]=(0,o.g)();return((0,f.useEffect)(()=>s.registerCommand(v,()=>{let e=(0,h.dL)();if(!(0,h.OP)(e)||e.isCollapsed())return!1;let{anchor:t,focus:n}=e;return i(m(s,t.getNode(),t.offset,n.getNode(),n.offset)),!0},h.VN),[s]),null===n)?null:(0,r.jsx)(x,{ref:t,...e,range:n,onRangeChange:i})}),x=(0,f.forwardRef)(function(e,t){let{range:n,onRangeChange:i,onKeyDown:s,onComposerSubmit:a,components:d,...p}=e,g=(0,c.U)(d?.Composer,u.ad),[v]=(0,o.g)(),b=(0,l.LL)(),x=(0,f.useCallback)(()=>{let e=(0,h.dL)();if(!(0,h.OP)(e)||e.isCollapsed())return null;let{anchor:t,focus:n}=e;return m(v,t.getNode(),t.offset,n.getNode(),n.offset)},[v]);(0,f.useEffect)(()=>v.registerUpdateListener(({editorState:e,tags:t})=>{if(!t.has("collaboration")){i(null);return}i(e.read(()=>x()))}),[v,n,i,x]),(0,f.useEffect)(()=>v.registerCommand(_,e=>{let t=(0,h.dL)();if(!(0,h.OP)(t)||t.isCollapsed())return!1;let n=t.isBackward();return function(e,t,n,r){let i,s;let o=e.getNodes(),l=e.anchor.offset,a=e.focus.offset,u=o.length,c=t?a:l,d=t?l:a;for(let e=0;e<u;
1e++){let t=o[e];if((0,h.F7)(s)&&s.isParentOf(t))continue;let r=0===e,l=e===u-1,a=null;if((0,h.Gg)(t)){let e=t.getTextContentSize(),n=r?c:0,i=l?d:e;if(0===n&&0===i)continue;let s=t.splitText(n,i);a=s.length>1&&(3===s.length||r&&!l||i===e)?s[1]:s[0]}else{if((0,y.Ui)(t))continue;(0,h.F7)(t)&&t.isInline()&&(a=t)}if(null!==a){if(a&&a.is(i))continue;let e=a.getParent();null!==e&&e.is(i)||(s=void 0),i=e,void 0===s&&(s=(0,y.H7)([n]),a.insertBefore(s)),s.append(a)}else i=void 0,s=void 0}(0,h.F7)(s)&&(t?s.selectStart():s.selectEnd())}(t,n,e),(0,h.oq)(null),!0},h.VN),[v]);let E=(0,f.useCallback)((t,n)=>{if(a?.(t,n),n.defaultPrevented)return;n.preventDefault();let r=b({body:t.body,attachments:t.attachments,metadata:e.metadata??{}});v.dispatchCommand(_,r.id)},[a,e.metadata,b,v]);return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(S,{range:n}),(0,r.jsx)(w,{range:n,children:(0,r.jsx)(g,{autoFocus:!0,...p,onKeyDown:function(e){s?.(e),e.isDefaultPrevented()||"Escape"!==e.key||(i(null),v.focus())},onComposerSubmit:E,ref:t})})]})});function S({range:e}){let{refs:{setReference:t,setFloating:n},strategy:l,x:u,y:c}=(0,i.YF)({strategy:"fixed",placement:"bottom",middleware:[(0,i.cv)(-e.getBoundingClientRect().height)],whileElementsMounted:(...e)=>(0,s.Me)(...e,{animationFrame:!0})});(0,a.bt)(()=>{t(e)},[t,e]);let[h]=(0,o.g)(),f=function(e,t){let n;let r=e.getRootElement();if(null===r)return[];let i=r.getBoundingClientRect(),s=getComputedStyle(r),o=parseFloat(s.paddingLeft)+parseFloat(s.paddingRight),l=Array.from(t.getClientRects()),a=l.length;l.sort((e,t)=>{let n=e.top-t.top;return 3>=Math.abs(n)?e.left-t.left:n});for(let e=0;e<a;e++){let t=l[e],r=n&&n.top<=t.top&&n.top+n.height>t.top&&n.left+n.width>t.left,s=t.width+o===i.width;if(r||s){l.splice(e--,1),a--;continue}n=t}return l}(h,e);return(0,r.jsx)(d.h,{asChild:!0,children:(0,r.jsx)("span",{ref:n,style:{position:l,top:0,left:0,transform:`translate3d(${Math.round(u)}px, ${Math.round(c)}px, 0)`,minWidth:"max-content",width:e.getBoundingClientRect().width,height:e.getBoundingClientRect().height,pointerEvents:"none"},className:"lb-root lb-portal",children:f.map(t=>(0,r.jsx)("span",{style:{position:"absolute",top:t.top-e.getBoundingClientRect().top,left:t.left-e.getBoundingClientRect().left,width:t.width,height:t.height,backgroundColor:"var(--lb-selection, rgba(0, 0, 255, 0.2))",pointerEvents:"none"},className:"lb-selection lb-lexical-active-selection"},JSON.stringify(t)))})})}function w({range:e,children:t}){let{refs:{setReference:n,setFloating:o},strategy:l,x:u,y:c}=(0,i.YF)({strategy:"fixed",placement:"bottom",middleware:[(0,i.Qo)({padding:10}),(0,i.RR)({padding:10,crossAxis:!1}),(0,i.cv)(10),(0,i.Cp)({padding:10}),(0,i.uY)({padding:10,limiter:(0,i.dr)()}),(0,i.dp)({padding:10})],whileElementsMounted:(...e)=>(0,s.Me)(...e,{animationFrame:!0})});return(0,a.bt)(()=>{n(e)},[e,n]),(0,r.jsx)(d.h,{asChild:!0,children:(0,r.jsx)("div",{ref:o,style:{position:l,top:0,left:0,transform:`translate3d(${Math.round(u)}px, ${Math.round(c)}px, 0)`,minWidth:"max-content"},className:"lb-root lb-portal lb-elevation lb-lexical-floating lb-lexical-floating-composer",children:t})})}},44984:function(e,t,n){"use strict";n.d(t,{N:function(){return m}});var r=n(44825),i=n(20089),s=n(58388),o=n(88332),l=n(78738),a=n(88587),u=n(19554),c=n(17076),d=n(96369),h=n(18193),f=n(71100),p=n(
150015),g=n(33956);function m({threads:e,components:t,...n}){let i=function(){let e=(0,f.useContext)(g.Bx);if(null===e)throw Error("FloatingThreads component must be used within LiveblocksPlugin.");return e}(),s=(0,u.U)(t?.Thread,a.j),[l]=(0,o.g)(),c=function(){let e=(0,f.useContext)(g.Oh);if(null===e)throw Error("FloatingThreads component must be used within a LiveblocksPlugin component.");return e}(),[d,m]=(0,f.useState)(null),_=(0,f.useCallback)(()=>{let t=(e??[]).filter(e=>i.includes(e.id)),n=function(){let e=Array.from(function(){let e=new Set;for(let t of i){let n=c.get(t);if(void 0!==n)for(let t of n){let n=l.getElementByKey(t);null!==n&&e.add(n)}}return e}()).sort(p.Y);if(0===e.length)return null;let t=document.createRange();return t.setStartBefore(e[0]),t.setEndAfter(e[e.length-1]),t}();if(null===n){m(null);return}m({range:n,threads:t})},[i,c,l,e]);(0,f.useEffect)(()=>{_()},[_]),(0,f.useEffect)(()=>l.registerUpdateListener(_),[l,_]);let b=(0,f.useCallback)(()=>null!==d&&(m(null),!0),[d]);(0,f.useEffect)(()=>l.registerCommand(h.Zq,b,h.Eo),[l,b]);let x=function(){let[e]=(0,o.g)(),t=(0,f.useCallback)(t=>e.registerUpdateListener(t),[e]),n=(0,f.useCallback)(()=>e.getEditorState().read(()=>{let e=(0,h.dL)();return null===e?null:e.isCollapsed()}),[e]);return(0,f.useSyncExternalStore)(t,n,n)}();return null!==d&&null!==x&&x?(0,r.jsx)(y,{range:d.range,...n,children:d.threads.map(e=>(0,r.jsx)(v,{thread:e,Thread:s,onEscapeKeydown:b,className:"lb-lexical-floating-threads-thread"},e.id))}):null}function y({range:e,children:t,className:n,style:o,...a}){let{refs:{setReference:u,setFloating:h},strategy:f,x:p,y:g}=(0,i.YF)({strategy:"absolute",placement:"bottom",middleware:[(0,i.RR)({padding:10,crossAxis:!1}),(0,i.cv)(10),(0,i.Cp)({padding:10}),(0,i.uY)({padding:10,limiter:(0,i.dr)()}),(0,i.dp)({padding:10,apply({availableWidth:e,availableHeight:t,elements:n}){n.floating.style.setProperty("--lb-lexical-floating-threads-available-width",`${e}px`),n.floating.style.setProperty("--lb-lexical-floating-threads-available-height",`${t}px`)}})],whileElementsMounted:(...e)=>(0,s.Me)(...e,{animationFrame:!0})});return(0,l.bt)(()=>{u({getBoundingClientRect:()=>e.getBoundingClientRect()})},[u,e]),(0,r.jsx)(c.h,{asChild:!0,children:(0,r.jsx)("div",{ref:h,...a,style:{...o,position:f,top:0,left:0,transform:`translate3d(${Math.round(p)}px, ${Math.round(g)}px, 0)`,minWidth:"max-content"},className:(0,d.cn)("lb-root lb-portal lb-elevation lb-lexical-floating lb-lexical-floating-threads",n),children:t})})}function v({thread:e,Thread:t,onEscapeKeydown:n,onKeyDown:i,...s}){let o=(0,f.useCallback)(e=>{i?.(e),"Escape"===e.key&&n()},[n,i]);return(0,r.jsx)(t,{thread:e,onKeyDown:o,...s})}},43307:function(e,t,n){"use strict";n.d(t,{H7:function(){return s},Ui:function(){return o},lz:function(){return i}});var r=n(18193);class i extends r.HX{__ids;static getType(){return"lb-thread-mark"}static clone(e){return new i(Array.from(e.__ids),e.__key)}static importDOM(){return null}static importJSON(e){let t=s(e.ids);return t.setFormat(e.format),t.setIndent(e.indent),t.setDirection(e.direction),t}exportJSON(){return{...super.exportJSON(),ids:this.getIDs(),type:"lb-thread-mark",version:1}}constructor(e,t){super(t),this.__ids=e||[]}createDOM(){return document.createElement("span")}updateDOM(){return!1}hasID(e){let t=this.getIDs();for(let n=0;n<t.length;n++)if(e===t[n])return!0;return!1}getIDs(){let e=this.getLatest();return o(e)?e.__ids:[]}addID(e){let t=this.getWritable();if(o(t)){let n=t.__ids;t.__ids=n;for(let t=0;t<n.length;t++)if(e===n[t])return;n.push(e)}}deleteID(e){let t=this.getWritable();if(o(t)){let n=t.__ids;t.__ids=n;for(let t=0;t<n.length;t++)if(e===n[t]){n.splice(t,1);return}}}insertNewAfter(e,t=!0){let n=s(this.__ids);return this.insertAfter(n,t),n}canInsertTextBefore(){return!1}canInsertTextAfter(){return!1}canBeEmpty(){return!1}isInline(){return!0}extractWithChild(e,t,n){if(!(0,r.OP)(t)||"html"===n)return!1;let i=t.anchor,s=t.focus,o=i.getNode(),l=s.getNode(),a=t.isBackward()?i.offset-s.offset:s.offset-i.offset;return this.isParentOf(o)&&this.isParentOf(l)&&this.getTextContent().length===a}excludeFromCopy(e){return"clone"!==e}}function s(e){return(0,r.U2)(new i(e))}function o(e){return e instanceof i}},74163:function(e,t,n){"use strict";n.d(t,{S:function(){return o}});var r=n(43307),i=n(82263),s=n(61816);function o(e){let t=[...e.nodes??[]];return t.push(r.lz,s.AV,i.qS),{...e,nodes:t,editorState:null}}},84986:function(e,t,n){"use strict";n.d(t,{U:function(){return eD},S:function(){return eO}});var r,i,s=n(44825),o=n(20089),l=n(58388),a=n(71100);let u=[["Cat","rgb(125, 50, 0)"],["Dog","rgb(100, 0, 0)"],["Rabbit","rgb(150, 0, 0)"],["Frog","rgb(200, 0, 0)"],["Fox","rgb(200, 75, 0)"],["Hedgehog","rgb(0, 75, 0)"],["Pigeon","rgb(0, 125, 0)"],["Squirrel","rgb(75, 100, 0)"],["Bear","rgb(125, 100, 0)"],["Tiger","rgb(0, 0, 150)"],["Leopard","rgb(0, 0, 200)"],["Zebra","rgb(0, 0, 250)"],["Wolf","rgb(0, 100, 150)"],["Owl","rgb(0, 100, 100)"],["Gull","rgb(100, 0, 100)"],["Squid","rgb(150, 0, 150)"]],c=u[Math.floor(Math.random()*u.length)],d=(0,a.createContext)({clientID:0,color:c[1],isCollabActive:!1,name:c[0],yjsDocMap:new Map});var h=n(88332),f=n(18193),p=n(11006),g=(r=function(e){let t=new URLSearchParams;t.append("code",e);for(let e=1;e<arguments.length;e++)t.append("v",arguments[e]);throw Error(`Minified Lexical error #${e}; visit https://lexical.dev/docs/error?${t} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}).__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r;function m(e,t){let n=[],r=e.__first;for(;null!==r;){let e=null===t?(0,f.gI)(r):t.get(r);null==e&&g(174),n.push(r),r=e.__next}return n}var y=n(63759),v=(i=function(e){let t=new URLSearchParams;t.append("code",e);for(let e=1;e<arguments.length;e++)t.append("v",arguments[e]);throw Error(`Minified Lexical error #${e}; visit https://lexical.dev/docs/error?${t} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}).__esModule&&Object.prototype.hasOwnProperty.call(i,"default")?i.default:i;class _{constructor(e,t){this._key="",this._map=e,this._parent=t,this._type="linebreak"}getNode(){let e=(0,f.gI)(this._key);return(0,f.A3)(e)?e:null}getKey(){return this._key}getSharedType(){return this._map}getType(){return this._type}getSize(){return 1}getOffset(){return this._parent.getChildOffset(this)}destroy(e){e.collabNodeMap.delete(this._key)}}function b(e,t){let n=new _(e,t);return e._collabNode=n,n}class x{constructor(e,t,n,r){this._key="",this._map=e,this._parent=n,this._text=t,this._type=r,this._normalized=!1}getPrevNode(e){if(null===e)return null;let t=e.get(this._key);return(0,f.Gg)(t)?t:null}getNode(){let e=(0,f.gI)(this._key);return(0,f.Gg)(e)?e:null}getSharedType(){return this._map}getType(){return this._type}getKey(){return this._key}getSize(){return this._text.length+(this._normalized?0:1)}getOffset(){return this._parent.getChildOffset(this)}spliceText(e,t,n){let r=this._parent._xmlText,i=this.getOffset()+1+e;0!==t&&r.delete(i,t),""!==n&&r.insert(i,n)}syncPropertiesAndTextFromLexical(e,t,n){let r=this.getPrevNode(n),i=t.__text;if(O(e,this._map,r,t),null!==r){let e=r.__text;e!==i&&(!function(e,t,n,r){let i=(0,f.dL)(),s=r.length;
1if((0,f.OP)(i)&&i.isCollapsed()){let e=i.anchor;e.key===t&&(s=e.offset)}let o=function(e,t,n){let r=e.length,i=t.length,s=0,o=0;for(;s<r&&s<i&&e[s]===t[s]&&s<n;)s++;for(;o+s<r&&o+s<i&&e[r-o-1]===t[i-o-1];)o++;for(;o+s<r&&o+s<i&&e[s]===t[s];)s++;return{index:s,insert:t.slice(s,i-o),remove:r-s-o}}(n,r,s);e.spliceText(o.index,o.remove,o.insert)}(this,t.__key,e,i),this._text=i)}}syncPropertiesAndTextFromYjs(e,t){let n=this.getNode();null===n&&v(84),F(e,this._map,n,t);let r=this._text;n.__text!==r&&(n.getWritable().__text=r)}destroy(e){e.collabNodeMap.delete(this._key)}}function S(e,t,n,r){let i=new x(e,t,n,r);return e._collabNode=i,i}let w=new Set(["__key","__parent","__next","__prev"]),E=new Set(["__first","__last","__size"]),T=new Set(["__cachedText"]),C=new Set(["__text"]);function k(e,t,n){if(w.has(e))return!0;if((0,f.Gg)(t)){if(C.has(e))return!0}else if((0,f.F7)(t)&&(E.has(e)||(0,f.wd)(t)&&T.has(e)))return!0;let r=t.constructor,i=n.excludedProperties.get(r);return null!=i&&i.has(e)}function A(e){let t=(0,f.gI)(e);return null===t&&v(85),t}function P(e,t,n){let r;let i=t.__type;if((0,f.F7)(t))(r=U(new p.eI,n,i)).syncPropertiesFromLexical(e,t,null),r.syncChildrenFromLexical(e,t,null,null,null);else if((0,f.Gg)(t))(r=S(new p.D5,t.__text,n,i)).syncPropertiesAndTextFromLexical(e,t,null);else if((0,f.A3)(t)){let e=new p.D5;e.set("__type","linebreak"),r=b(e,n)}else(0,f.k$)(t)?(r=B(new p.lt,n,i)).syncPropertiesFromLexical(e,t,null):v(86);return r._key=t.__key,r}function N(e,t,n){let r=t._collabNode;if(void 0===r){let r=e.editor._nodes,i=function(e){let t=e instanceof p.D5?e.get("__type"):e.getAttribute("__type");return null==t&&v(87),t}(t);void 0===r.get(i)&&v(88,i);let s=t.parent,o=void 0===n&&null!==s?N(e,s):n||null;if(o instanceof j||v(89),t instanceof p.eI)return U(t,o,i);if(t instanceof p.D5)return"linebreak"===i?b(t,o):S(t,"",o,i);if(t instanceof p.lt)return B(t,o,i)}return r}function F(e,t,n,r){let i;let s=null===r?t instanceof p.D5?Array.from(t.keys()):Object.keys(t.getAttributes()):Array.from(r);for(let r=0;r<s.length;r++){let o=s[r];if(k(o,n,e))continue;let l=n[o],a=t instanceof p.D5?t.get(o):t.getAttribute(o);if(l!==a){if(a instanceof p.QW){let t=e.docMap;l instanceof p.QW&&t.delete(l.guid);let n=(0,f.Jh)(),r=a.guid;n._key=r,t.set(r,a),a=n}void 0===i&&(i=n.getWritable()),i[o]=a}}}function O(e,t,n,r){let i=r.__type,s=e.nodeProperties,o=s.get(i);void 0===o&&(o=Object.keys(r).filter(t=>!k(t,r,e)),s.set(i,o));let l=e.editor.constructor;for(let i=0;i<o.length;i++){let s=o[i],a=null===n?void 0:n[s],u=r[s];if(a!==u){if(u instanceof l){let t;let n=e.docMap;if(a instanceof l){let e=a._key;t=n.get(e),n.delete(e)}let i=t||new p.QW,s=i.guid;u._key=s,n.set(s,i),u=i,e.editor.update(()=>{r.markDirty()})}t instanceof p.D5?t.set(s,u):t.setAttribute(s,u)}}}function D(e,t,n,r){return e.slice(0,t)+r+e.slice(t+n)}function L(e,t,n){let r=0,i=0,s=e._children,o=s.length;for(;i<o;i++){let e=s[i],l=r;if(r+=e.getSize(),(n?r>=t:r>t)&&e instanceof x){let n=t-l-1;return n<0&&(n=0),{length:r-t,node:e,nodeIndex:i,offset:n}}if(r>t)return{length:0,node:e,nodeIndex:i,offset:l};if(i===o-1)return{length:0,node:null,nodeIndex:i+1,offset:l+1}}return{length:0,node:null,nodeIndex:0,offset:0}}function I(e){let t=e.anchor,n=e.focus,r=!1;try{let e=t.getNode(),i=n.getNode();(!e.isAttached()||!i.isAttached()||(0,f.Gg)(e)&&t.offset>e.getTextContentSize()||(0,f.Gg)(i)&&n.offset>i.getTextContentSize())&&(r=!0)}catch(e){r=!0}return r}function M(e){let t=e.getParent();if(null!==t){let n=e.getWritable(),r=t.getWritable(),i=e.getPreviousSibling(),s=e.getNextSibling();if(null===i){if(null!==s){let e=s.getWritable();r.__first=s.__key,e.__prev=null}else r.__first=null}else{let e=i.getWritable();if(null!==s){let t=s.getWritable();t.__prev=e.__key,e.__next=t.__key}else e.__next=null;n.__prev=null}if(null===s){if(null!==i){let e=i.getWritable();r.__last=i.__key,e.__next=null}else r.__last=null}else{let e=s.getWritable();if(null!==i){let t=i.getWritable();t.__next=e.__key,e.__prev=t.__key}else e.__prev=null;n.__next=null}r.__size--,n.__parent=null}}class R{constructor(e,t,n){this._key="",this._xmlElem=e,this._parent=t,this._type=n}getPrevNode(e){if(null===e)return null;let t=e.get(this._key);return(0,f.k$)(t)?t:null}getNode(){let e=(0,f.gI)(this._key);return(0,f.k$)(e)?e:null}getSharedType(){return this._xmlElem}getType(){return this._type}getKey(){return this._key}getSize(){return 1}getOffset(){return this._parent.getChildOffset(this)}syncPropertiesFromLexical(e,t,n){let r=this.getPrevNode(n);O(e,this._xmlElem,r,t)}syncPropertiesFromYjs(e,t){let n=this.getNode();null===n&&v(83),F(e,this._xmlElem,n,t)}destroy(e){e.collabNodeMap.delete(this._key)}}function B(e,t,n){let r=new R(e,t,n);return e._collabNode=r,r}class j{constructor(e,t,n){this._key="",this._children=[],this._xmlText=e,this._type=n,this._parent=t}getPrevNode(e){if(null===e)return null;let t=e.get(this._key);return(0,f.F7)(t)?t:null}getNode(){let e=(0,f.gI)(this._key);return(0,f.F7)(e)?e:null}getSharedType(){return this._xmlText}getType(){return this._type}getKey(){return this._key}isEmpty(){return 0===this._children.length}getSize(){return 1}getOffset(){let e=this._parent;return null===e&&v(90),e.getChildOffset(this)}syncPropertiesFromYjs(e,t){let n=this.getNode();null===n&&v(91),F(e,this._xmlText,n,t)}
1applyChildrenYjsDelta(e,t){let n=this._children,r=0,i=null;for(let s=0;s<t.length;s++){let o=t[s],l=o.insert,a=o.delete;if(null!=o.retain)r+=o.retain;else if("number"==typeof a){let e=a;for(;e>0;){let{node:t,nodeIndex:i,offset:s,length:o}=L(this,r,!1);if(t instanceof j||t instanceof _||t instanceof R)n.splice(i,1),e-=1;else{if(!(t instanceof x))break;{let r=Math.min(e,o),l=0!==i?n[i-1]:null,a=t.getSize();if(0===s&&o===a){n.splice(i,1);let e=D(t._text,s,r-1,"");e.length>0&&(l instanceof x?l._text+=e:this._xmlText.delete(s,e.length))}else t._text=D(t._text,s,r,"");e-=r}}}}else{if(null==l)throw Error("Unexpected delta format");if("string"==typeof l){let{node:e,offset:t}=L(this,r,!0);e instanceof x?e._text=D(e._text,t,0,l):this._xmlText.delete(t,l.length),r+=l.length}else{let{node:t,nodeIndex:s,length:o}=L(this,r,!1),a=N(e,l,this);if(t instanceof x&&o>0&&o<t._text.length){let e=t._text,r=e.length-o;t._text=D(e,r,o,""),n.splice(s+1,0,a),i=D(e,0,r,"")}else n.splice(s,0,a);null!==i&&a instanceof x&&(a._text=i+a._text,i=null),r+=1}}}}syncChildrenFromYjs(e){let t=this.getNode();null===t&&v(92);let n=t.__key,r=m(t,null),i=r.length,s=this._children,o=s.length,l=e.collabNodeMap,a=new Set,u,c,d=0,h=null;o!==i&&(c=t.getWritable());for(let i=0;i<o;i++){let p=r[d],g=s[i],m=g.getNode(),y=g._key;if(null!==m&&p===y){let t=(0,f.Gg)(m);if(a.add(p),t){if(g._key=p,g instanceof j){let t=g._xmlText;g.syncPropertiesFromYjs(e,null),g.applyChildrenYjsDelta(e,t.toDelta()),g.syncChildrenFromYjs(e)}else g instanceof x?g.syncPropertiesAndTextFromYjs(e,null):g instanceof R?g.syncPropertiesFromYjs(e,null):g instanceof _||v(93)}h=m,d++}else{if(void 0===u){u=new Set;for(let e=0;e<o;e++){let t=s[e]._key;""!==t&&u.add(t)}}if(null!==m&&void 0!==p&&!u.has(p)){M(A(p)),i--,d++;continue}c=t.getWritable();let r=function(e,t,n){let r=t.getType(),i=e.editor._nodes.get(r);void 0===i&&v(88,r);let s=new i.klass;if(s.__parent=n,t._key=s.__key,t instanceof j){let n=t._xmlText;t.syncPropertiesFromYjs(e,null),t.applyChildrenYjsDelta(e,n.toDelta()),t.syncChildrenFromYjs(e)}else t instanceof x?t.syncPropertiesAndTextFromYjs(e,null):t instanceof R&&t.syncPropertiesFromYjs(e,null);return e.collabNodeMap.set(s.__key,t),s}(e,g,n),a=r.__key;if(l.set(a,g),null===h){let e=c.getFirstChild();if(c.__first=a,null!==e){let t=e.getWritable();t.__prev=a,r.__next=t.__key}}else{let e=h.getWritable(),t=h.getNextSibling();if(e.__next=a,r.__prev=h.__key,null!==t){let e=t.getWritable();e.__prev=a,r.__next=e.__key}}i===o-1&&(c.__last=a),c.__size++,h=r}}for(let t=0;t<i;t++){let n=r[t];if(!a.has(n)){let t=A(n),r=e.collabNodeMap.get(n);void 0!==r&&r.destroy(e),M(t)}}}syncPropertiesFromLexical(e,t,n){O(e,this._xmlText,this.getPrevNode(n),t)}_syncChildFromLexical(e,t,n,r,i,s){let o=this._children[t],l=A(n);o instanceof j&&(0,f.F7)(l)?(o.syncPropertiesFromLexical(e,l,r),o.syncChildrenFromLexical(e,l,r,i,s)):o instanceof x&&(0,f.Gg)(l)?o.syncPropertiesAndTextFromLexical(e,l,r):o instanceof R&&(0,f.k$)(l)&&o.syncPropertiesFromLexical(e,l,r)}syncChildrenFromLexical(e,t,n,r,i){let s=this.getPrevNode(n),o=null===s?[]:m(s,n),l=m(t,null),a=o.length-1,u=l.length-1,c=e.collabNodeMap,d,h,f=0,p=0;for(;f<=a&&p<=u;){let t=o[f],s=l[p];if(t===s)this._syncChildFromLexical(e,p,s,n,r,i),f++,p++;else{void 0===d&&(d=new Set(o)),void 0===h&&(h=new Set(l));let n=h.has(t),r=d.has(s);if(n){let t=P(e,A(s),this);c.set(s,t),r?(this.splice(e,p,1,t),f++):this.splice(e,p,0,t),p++}else this.splice(e,p,1),f++}}let g=f>a,y=p>u;if(g&&!y)for(;p<=u;++p){let t=l[p],n=P(e,A(t),this);this.append(n),c.set(t,n)}else if(y&&!g)for(let t=this._children.length-1;t>=p;t--)this.splice(e,t,1)}append(e){let t=this._xmlText,n=this._children,r=n[n.length-1],i=void 0!==r?r.getOffset()+r.getSize():0;if(e instanceof j)t.insertEmbed(i,e._xmlText);else if(e instanceof x){let n=e._map;null===n.parent&&t.insertEmbed(i,n),t.insert(i+1,e._text)}else e instanceof _?t.insertEmbed(i,e._map):e instanceof R&&t.insertEmbed(i,e._xmlElem);this._children.push(e)}splice(e,t,n,r){let i=this._children,s=i[t];if(void 0===s)return void 0===r&&v(94),void this.append(r);let o=s.getOffset();-1===o&&v(95);let l=this._xmlText;if(0!==n&&l.delete(o,s.getSize()),r instanceof j)l.insertEmbed(o,r._xmlText);else if(r instanceof x){let e=r._map;null===e.parent&&l.insertEmbed(o,e),l.insert(o+1,r._text)}else r instanceof _?l.insertEmbed(o,r._map):r instanceof R&&l.insertEmbed(o,r._xmlElem);
1if(0!==n){let r=i.slice(t,t+n);for(let t=0;t<r.length;t++)r[t].destroy(e)}void 0!==r?i.splice(t,n,r):i.splice(t,n)}getChildOffset(e){let t=0,n=this._children;for(let r=0;r<n.length;r++){let i=n[r];if(i===e)return t;t+=i.getSize()}return -1}destroy(e){let t=e.collabNodeMap,n=this._children;for(let t=0;t<n.length;t++)n[t].destroy(e);t.delete(this._key)}}function U(e,t,n){let r=new j(e,t,n);return e._collabNode=r,r}function V(e,t){let n=t.collabNodeMap.get(e.key);if(void 0===n)return null;let r=e.offset,i=n.getSharedType();if(n instanceof x){i=n._parent._xmlText;let e=n.getOffset();if(-1===e)return null;r=e+1+r}else if(n instanceof j&&"element"===e.type){let t=e.getNode();(0,f.F7)(t)||v(184);let n=0,i=0,s=t.getFirstChild();for(;null!==s&&i++<r;)(0,f.Gg)(s)?n+=s.getTextContentSize()+1:n++,s=s.getNextSibling();r=n}return(0,p.w$)(i,r)}function z(e,t){return(0,p.or)(e,t.doc)}function $(e,t){if(null==e){if(null!=t)return!0}else if(null==t||!(0,p.Uq)(e,t))return!0;return!1}function W(e,t){let n=e.cursorsContainer;if(null!==n){let e=t.selections,r=e.length;for(let t=0;t<r;t++)n.removeChild(e[t])}}function K(e,t){let{anchorPos:n,focusPos:r}=t,i=null,s=0,o=null,l=0;if(null!==n&&null!==r){let t=z(n,e),a=z(r,e);null!==t&&null!==a&&([i,s]=Y(t.type,t.index),[o,l]=Y(a.type,a.index))}return{anchorCollabNode:i,anchorOffset:s,focusCollabNode:o,focusOffset:l}}
1function H(e,t){let n=t.awareness.getLocalState();if(null===n)return;let{anchorCollabNode:r,anchorOffset:i,focusCollabNode:s,focusOffset:o}=K(e,n);if(null!==r&&null!==s){let e=r.getKey(),t=s.getKey(),n=(0,f.dL)();if(!(0,f.OP)(n))return;G(n.anchor,e,i),G(n.focus,t,o)}}function G(e,t,n){if(e.key!==t||e.offset!==n){let r=(0,f.gI)(t);if(null!==r&&!(0,f.F7)(r)&&!(0,f.Gg)(r)){let e=r.getParentOrThrow();t=e.getKey(),n=r.getIndexWithinParent(),r=e}e.set(t,n,(0,f.F7)(r)?"element":"text")}}function Y(e,t){let n=e._collabNode;if(void 0===n)return[null,0];if(n instanceof j){let{node:e,offset:r}=L(n,t,!0);return null===e?[n,0]:[e,r]}return[null,0]}function q(e,t){let n=Array.from(t.awareness.getStates()),r=e.clientID,i=e.cursors,s=e.editor._editorState._nodeMap,o=new Set;for(let t=0;t<n.length;t++){let[l,a]=n[t];if(l!==r){o.add(l);let{name:t,color:n,focusing:r}=a,u=null,c=i.get(l);if(void 0===c&&(c={color:n,name:t,selection:null},i.set(l,c)),r){let{anchorCollabNode:t,anchorOffset:n,focusCollabNode:r,focusOffset:i}=K(e,a);if(null!==t&&null!==r){let e=t.getKey(),s=r.getKey();if(null===(u=c.selection))u=function(e,t,n,r,i){let s=e.color,o=document.createElement("span");o.style.cssText=`position:absolute;top:0;bottom:0;right:-1px;width:1px;background-color:${s};z-index:10;`;let l=document.createElement("span");return l.textContent=e.name,l.style.cssText=`position:absolute;left:-2px;top:-16px;background-color:${s};color:#fff;line-height:12px;font-size:12px;padding:2px;font-family:Arial;font-weight:bold;white-space:nowrap;`,o.appendChild(l),{anchor:{key:t,offset:n},caret:o,color:s,focus:{key:r,offset:i},name:l,selections:[]}}(c,e,n,s,i);else{let t=u.anchor,r=u.focus;t.key=e,t.offset=n,r.key=s,r.offset=i}}}!function(e,t,n,r){let i;let s=e.editor,o=s.getRootElement(),l=e.cursorsContainer;if(null===l||null===o)return;let a=l.offsetParent;if(null===a)return;let u=a.getBoundingClientRect(),c=t.selection;if(null===n)return null===c?void 0:(t.selection=null,void W(e,c));t.selection=n;let d=n.caret,h=n.color,p=n.selections,g=n.anchor,m=n.focus,v=g.key,_=m.key,b=r.get(v),x=r.get(_);if(null==b||null==x)return;if(b===x&&(0,f.A3)(b))i=[s.getElementByKey(v).getBoundingClientRect()];else{let e=(0,y.XM)(s,b,g.offset,x,m.offset);if(null===e)return;i=(0,y.FN)(s,e)}let S=p.length,w=i.length;for(let e=0;e<w;e++){let t=i[e],n=p[e];if(void 0===n){n=document.createElement("span"),p[e]=n;let t=document.createElement("span");n.appendChild(t),l.appendChild(n)}let r=`position:absolute;top:${t.top-u.top}px;left:${t.left-u.left}px;height:${t.height}px;width:${t.width}px;pointer-events:none;z-index:5;`;n.style.cssText=r,n.firstChild.style.cssText=`${r}left:0;top:0;background-color:${h};opacity:0.3;`,e===w-1&&d.parentNode!==n&&n.appendChild(d)}for(let e=S-1;e>=w;e--){let t=p[e];l.removeChild(t),p.pop()}}(e,c,u,s)}}let l=Array.from(i.keys());for(let t=0;t<l.length;t++){let n=l[t];if(!o.has(n)){let t=i.get(n);void 0!==t&&(function(e,t){let n=t.selection;null!==n&&W(e,n)}(e,t),i.delete(n))}}}function J(e,t,n,r){let i=t.awareness,s=i.getLocalState();if(null===s)return;let{anchorPos:o,focusPos:l,name:a,color:u,focusing:c,awarenessData:d}=s,h=null,p=null;(null!==r&&(null===o||r.is(n))||null!==n)&&((0,f.OP)(r)&&(h=V(r.anchor,e),p=V(r.focus,e)),($(o,h)||$(l,p))&&i.setLocalState({...s,anchorPos:
1h,awarenessData:d,color:u,focusPos:p,focusing:c,name:a}))}let Z=(0,f.fA)("CONNECTED_COMMAND"),X=(0,f.fA)("TOGGLE_CONNECT_COMMAND");function Q(e,t,n,r,i){let{awareness:s}=e,o=s.getLocalState();null===o&&(o={anchorPos:null,awarenessData:i,color:n,focusPos:null,focusing:r,name:t}),o.focusing=r,s.setLocalState(o)}var ee=n(30913),et=n(34589);function en({id:e,providerFactory:t,shouldBootstrap:n,username:r,cursorColor:i,cursorsContainerRef:o,initialEditorState:l,excludedProperties:u,awarenessData:c}){let f=(0,a.useRef)(!1),g=(0,a.useRef)(!1),m=function(e,t){let n=(0,a.useContext)(d);return null!=e&&(n.name=e),null!=t&&(n.color=t),n}(r,i),{yjsDocMap:y,name:_,color:b}=m,[x]=(0,h.g)();(0,a.useEffect)(()=>(m.isCollabActive=!0,()=>{null==x._parentEditor&&(m.isCollabActive=!1)}),[m,x]);let[S,w]=(0,a.useState)();(0,a.useEffect)(()=>{if(g.current)return;g.current=!0;let n=t(e,y);return w(n),()=>{n.disconnect()}},[e,t,y]);let[E,T]=(0,a.useState)(y.get(e)),[C,k]=(0,a.useState)();return(0,a.useEffect)(()=>{if(!S||f.current)return;f.current=!0;let t=function(e,t,n,r,i,s){null==r&&v(81);let o=U(r.get("root",p.eI),null,"root");return o._key="root",{clientID:r.clientID,collabNodeMap:new Map,cursors:new Map,cursorsContainer:null,doc:r,docMap:i,editor:e,excludedProperties:s||new Map,id:n,nodeProperties:new Map,root:o}}(x,0,e,E||y.get(e),y,u);return k(t),()=>{t.root.destroy(t)}},[x,S,e,y,E,u]),S&&C?(0,s.jsx)(er,{awarenessData:c,binding:C,collabContext:m,color:b,cursorsContainerRef:o,editor:x,id:e,initialEditorState:l,name:_,provider:S,setDoc:T,shouldBootstrap:n,yjsDocMap:y}):(0,s.jsx)(s.Fragment,{})}function er({editor:e,id:t,provider:n,yjsDocMap:r,name:i,color:o,shouldBootstrap:l,cursorsContainerRef:u,initialEditorState:c,awarenessData:d,collabContext:h,binding:g,setDoc:m}){let y=function(e,t,n,r,i,o,l,u,c,d,h,g,m=q){let y=(0,a.useRef)(!1),_=(0,a.useCallback)(()=>n.connect(),[n]),b=(0,a.useCallback)(()=>{try{n.disconnect()}catch(e){}},[n]);(0,a.useEffect)(()=>{let{root:s}=u,{awareness:a}=n,d=({status:t})=>{e.dispatchCommand(Z,"connected"===t)},S=t=>{l&&t&&s.isEmpty()&&0===s._xmlText._length&&!1===y.current&&function(e,t){e.update(()=>{let n=(0,f.Gv)();if(n.isEmpty()){if(t)switch(typeof t){case"string":{let n=e.parseEditorState(t);e.setEditorState(n,{tag:"history-merge"});break}case"object":e.setEditorState(t,{tag:"history-merge"});break;case"function":e.update(()=>{(0,f.Gv)().isEmpty()&&t(e)},{tag:"history-merge"})}else{let t=(0,f.BE)();n.append(t);let{activeElement:r}=document;(null!==(0,f.dL)()||null!==r&&r===e.getRootElement())&&t.select()}}},{tag:"history-merge"})}(e,h),y.current=!1},w=()=>{m(u,n)},E=(e,t)=>{let r=t.origin;r!==u&&function(e,t,n,r,i=q){let s=e.editor,o=s._editorState;n.forEach(e=>e.delta),s.update(()=>{for(let t=0;t<n.length;t++)(function(e,t){let{target:n}=t,r=N(e,n);if(r instanceof j&&t instanceof p.bT){let{keysChanged:n,childListChanged:i,delta:s}=t;n.size>0&&r.syncPropertiesFromYjs(e,n),i&&(r.applyChildrenYjsDelta(e,s),r.syncChildrenFromYjs(e))}else if(r instanceof x&&t instanceof p.Yh){let{keysChanged:n}=t;n.size>0&&r.syncPropertiesAndTextFromYjs(e,n)}else if(r instanceof R&&t instanceof p.yU){let{attributesChanged:n}=t;n.size>0&&r.syncPropertiesFromYjs(e,n)}else v(82)})(e,n[t]);let r=(0,f.dL)();if((0,f.OP)(r)){if(I(r)){let n=o._selection;(0,f.OP)(n)&&(H(e,t),I(r))&&function e(t,n){let r=n._nodeMap.get(t);if(!r)return void(0,f.Gv)().selectStart();let i=r.__prev,s=null;i&&(s=(0,f.gI)(i)),null===s&&null!==r.__parent&&(s=(0,f.gI)(r.__parent)),null!==s?null!==s&&s.isAttached()?s.selectEnd():e(s.__key,n):(0,f.Gv)().selectStart()}(r.anchor.key,o),J(e,t,n,(0,f.dL)())}else H(e,t)}},{onUpdate:()=>{i(e,t),s.update(()=>{0===(0,f.Gv)().getChildrenSize()&&(0,f.Gv)().append((0,f.BE)())})},skipTransforms:!0,tag:r?"historic":"collaboration"})}(u,n,e,r instanceof p.H6,m)};!function(e,t,n,r,i){e.awareness.setLocalState({anchorPos:null,awarenessData:i,color:n,focusPos:null,focusing:r,name:t})}(n,i,o,document.activeElement===e.getRootElement(),g||{});let T=n=>{!function(e,t){if(e.update(()=>{let e=(0,f.Gv)();e.clear(),e.select()},{tag:"skip-collab"}),null==t.cursors)return;let n=t.cursors;if(null==n)return;let r=t.cursorsContainer;if(null==r)return;let i=Array.from(n.values());for(let e=0;e<i.length;e++){let t=i[e].selection;if(t&&null!=t.selections){let n=t.selections;for(let t=0;t<n.length;t++)r.removeChild(n[e])}}}(e,u),c(n),r.set(t,n),y.current=!0};n.on("reload",T),n.on("status",d),n.on("sync",S),a.on("update",w),s.getSharedType().observeDeep(E);let C=e.registerUpdateListener(({prevEditorState:e,editorState:t,dirtyLeaves:r,dirtyElements:i,normalizedNodes:s,tags:o})=>{!1===o.has("skip-collab")&&function(e,t){e.doc.transact(t,e)}(u,()=>{t.read(()=>
1{if(o.has("collaboration")||o.has("historic"))return void(s.size>0&&function(e,t){let n=Array.from(t),r=e.collabNodeMap,i=[];for(let e=0;e<n.length;e++){let t=n[e],s=(0,f.gI)(t),o=r.get(t);if(o instanceof x){if((0,f.Gg)(s))i.push([o,s.__text]);else{let e=o.getOffset();if(-1===e)continue;let n=o._parent;o._normalized=!0,n._xmlText.delete(e,1),r.delete(t);let i=n._children,s=i.indexOf(o);i.splice(s,1)}}}for(let e=0;e<i.length;e++){let[t,n]=i[e];t instanceof x&&"string"==typeof n&&(t._text=n)}}(u,s));if(i.has("root")){let t=e._nodeMap,n=(0,f.Gv)(),s=u.root;s.syncPropertiesFromLexical(u,n,t),s.syncChildrenFromLexical(u,n,t,i,r)}let t=(0,f.dL)();J(u,n,e._selection,t)})})}),k=_();return()=>{!1===y.current&&(k?k.then(b):b()),n.off("sync",S),n.off("status",d),n.off("reload",T),a.off("update",w),s.getSharedType().unobserveDeep(E),r.delete(t),C()}},[u,o,_,b,r,e,t,h,i,n,l,g,c,m]);let S=(0,a.useMemo)(()=>(0,et.createPortal)((0,s.jsx)("div",{ref:e=>{u.cursorsContainer=e}}),d&&d.current||document.body),[u,d]);return(0,a.useEffect)(()=>e.registerCommand(X,e=>(e?(console.log("Collaboration connected!"),_()):(console.log("Collaboration disconnected!"),b()),!0),f.VN),[_,b,e]),S}(e,t,n,r,i,o,l,g,m,u,c,d);return h.clientID=g.clientID,function(e,t){let n=(0,a.useMemo)(()=>{var e;return e=t.root.getSharedType(),new p.H6(e,{trackedOrigins:new Set([t,null])})},[t]);(0,a.useEffect)(()=>(0,ee.qV)(e.registerCommand(f.$l,()=>(n.undo(),!0),f.VN),e.registerCommand(f.zq,()=>(n.redo(),!0),f.VN))),(0,a.useCallback)(()=>{n.clear()},[n]),a.useEffect(()=>{let t=()=>{e.dispatchCommand(f.yn,n.undoStack.length>0),e.dispatchCommand(f.r0,n.redoStack.length>0)};return n.on("stack-item-added",t),n.on("stack-item-popped",t),n.on("stack-cleared",t),()=>{n.off("stack-item-added",t),n.off("stack-item-popped",t),n.off("stack-cleared",t)}},[e,n])}(e,g),(0,a.useEffect)(()=>(0,ee.qV)(e.registerCommand(f.m$,()=>(Q(n,i,o,!0,d||{}),!1),f.VN),e.registerCommand(f.Gq,()=>(Q(n,i,o,!1,d||{}),!1),f.VN)),[o,e,i,n,d]),y}var ei=n(95054),es=n(9776),eo=n(78738),el=n(76577),ea=n(33956),eu=n(43307),ec=n(82263),ed=n(61816),eh=n(66593),ef=n(35926),ep=n(48990),eg=n(55800),em=n(66997),ey=n(17076);let ev=(0,a.createContext)(null),e_=(0,a.createContext)(null),eb=(0,a.createContext)(null),ex=(0,a.createContext)(null),eS=(0,a.forwardRef)(function(e,t){let{children:n,...r}=e,[i]=(0,h.g)(),[o,l]=(0,a.useState)(0),u=eE(),c=eT(),d=function(){let e=(0,a.useContext)(eb);if(null===e)throw Error("useOnResetMatchCallback: OnResetMatchContext not found");return e}();return(0,a.useEffect)(()=>i.registerCommand(f.Zb,function(e){return 0===u.length||null===o||(l(o===u.length-1?0:o+1),e.preventDefault(),e.stopImmediatePropagation(),!0)},f.KB),[i,o,u]),(0,a.useEffect)(()=>i.registerCommand(f._0,function(e){return 0===u.length||null===o||(l(0===o?u.length-1:o-1),e.preventDefault(),e.stopImmediatePropagation(),!0)},f.KB),[i,o,u]),(0,a.useEffect)(()=>i.registerCommand(f.Zq,function(e){return e.preventDefault(),e.stopImmediatePropagation(),d(),!0}
1,f.KB),[i,d]),(0,a.useEffect)(()=>i.registerCommand(f.XN,function(e){return 0===u.length||(c(u[o]),null===e||(e.preventDefault(),e.stopImmediatePropagation(),!0))},f.KB),[i,c,o,u]),(0,a.useEffect)(()=>{let e=i.getRootElement();if(null!==e)return e.setAttribute("aria-activedescendant",`typeahead-item-${o}`),()=>{e.removeAttribute("aria-activedescendant")}},[i,o]),(0,s.jsx)(ex.Provider,{value:[o,l],children:(0,s.jsx)("div",{role:"listbox",...r,ref:t,children:n})})}),ew=(0,a.forwardRef)(function(e,t){let{children:n,value:r,onMouseEnter:i,onClick:o,...l}=e,u=(0,a.useRef)(null),[c,d]=function(){let e=(0,a.useContext)(ex);if(null===e)throw Error("useHighlightedIndex must be used within a HighlightedIndexProvider");return e}(),h=eE(),f=eT(),p=h[c].id===r;return(0,a.useImperativeHandle)(t,()=>u.current),(0,a.useEffect)(()=>{if(!p)return;let e=u.current;null!==e&&e.scrollIntoView({block:"nearest"})},[p]),(0,s.jsx)("div",{role:"option","data-highlighted":p||void 0,onMouseEnter:function(e){if(i?.(e),e.isDefaultPrevented())return;let t=h.findIndex(e=>e.id===r);-1!==t&&d(t)},onClick:function(e){o?.(e),e.isDefaultPrevented()||f(h[c])},...l,ref:u,children:n})});function eE(){let e=(0,a.useContext)(ev);if(null===e)throw Error("useSuggestions: SuggestionsContext not found");return e}function eT(){let e=(0,a.useContext)(e_);if(null===e)throw Error("useOnSuggestionSelectCallback: OnSuggestionSelectContext not found");return e}let eC="\\.,\\+\\*\\?\\$\\@\\|#{}\\(\\)\\^\\-\\[\\]\\\\/!%'\"~=<>_:;",ek="[^"+ei.$S+eC+"\\s]",eA=RegExp("(^|\\s|\\()(["+ei.$S+"]((?:"+ek+"(?:\\.[ |$]| |["+eC+"]|)){0,75}))$");function eP(){let[e]=(0,h.g)(),t=(0,es.kB)(),[n,r]=(0,a.useState)(null),i=n?.[3],o=(0,eo.qN)(t.id,i),l=(0,es.GG)(),u=(0,es.bD)();(0,a.useEffect)(()=>{let t=e.registerMutationListener(ed.AV,(t,n)=>{n.updateTags.has("collaboration")||n.updateTags.has("history-merge")||function(t,{prevEditorState:n}){for(let[r,i]of t)"created"===i?e.getEditorState().read(()=>{let e=(0,f.gI)(r);null!==e&&(0,ed.kz)(e)&&l(e.getId(),{kind:"user",id:e.getUserId()})}):"destroyed"===i&&n.read(()=>{let e=(0,f.gI)(r);null!==e&&(0,ed.kz)(e)&&u(e.getId())})}(t,n)}),n=e.registerMutationListener(ec.qS,(t,n)=>{n.updateTags.has("collaboration")||n.updateTags.has("history-merge")||function(t,{prevEditorState:n}){for(let[r,i]of t)"created"===i?e.getEditorState().read(()=>{let e=(0,f.gI)(r);null!==e&&(0,ec.VL)(e)&&l(e.getId(),{kind:"group",id:e.getGroupId(),userIds:e.getUserIds()})}):"destroyed"===i&&n.read(()=>{let e=(0,f.gI)(r);null!==e&&(0,ec.VL)(e)&&u(e.getId())})}(t,n)});return()=>{t(),n()}},[e,l,u]),(0,a.useEffect)(()=>{function t(){let e=function(){let e=(0,f.dL)();if(!(0,f.OP)(e))return null;let t=e.anchor;if("text"!==t.type)return null;let n=t.getNode();if(!n.isSimpleText())return null;let r=t.offset;return n.getTextContent().slice(0,r)}();if(null===e){r(null);return}r(eA.exec(e))}return e.registerUpdateListener(({editorState:e})=>{e.read(t)})},[e]),(0,a.useEffect)(()=>e.registerCommand(f.aR,function(e){let t=(0,f.dL)();if(null===t)return!1;if((0,f.iO)(t)){let n=t.getNodes();if(1!==n.length)return!1;let r=n[0];if(!(0,ed.kz)(r)&&!(0,ec.VL)(r))return!1;let i=(0,f.MX)("@");r.replace(i);let s=(0,f.vN)();return s.setTextNodeRange(i,1,i,1),(0,f.oq)(s),e.preventDefault(),!0}if((0,f.OP)(t)){if(!t.isCollapsed())return!1;let n=t.anchor.getNode(),r=n.getPreviousSibling();if(0===t.anchor.offset&&((0,ed.kz)(r)||(0,ec.VL)(r))){let t=(0,f.MX)("@");r.replace(t);let n=(0,f.vN)();return n.setTextNodeRange(t,1,t,1),(0,f.oq)(n),e.preventDefault(),!0}if((0,f.F7)(n)){let r=n.getChildAtIndex(t.anchor.offset-1);if(!(0,ed.kz)(r)&&!(0,ec.VL)(r))return!1;let i=(0,f.MX)("@");r.replace(i);let s=(0,f.vN)();return s.setTextNodeRange(i,1,i,1),(0,f.oq)(s),e.preventDefault(),!0}}return!1},f.KB),[e]);let c=(0,a.useCallback)(t=>{e.update(function(){let e;if(null===n)return;r(null);let i=(0,f.dL)();if(!(0,f.OP)(i)||!i.isCollapsed())return;let s=i.anchor;if("text"!==s.type)return;let o=s.getNode();if(!o.isSimpleText())return;let l=s.offset,a=o.getTextContent().slice(0,l),u=n[2].length,c=l-function(e,t,n){let r=n;for(let n=r;n<=t.length;n++)e.substr(-n)===t.substr(0,n)&&(r=n);return r}(a,n[2],u);if(!(c<0)){switch(t.kind){case"user":e=(0,ed.IY)(t.id);break;case"group":e=(0,ec.PJ)(t.id,t.userIds);break;default:return(0,ei.vE)(t,"Unhandled mention kind")}if(0===c){let[t]=o.splitText(l);t.replace(e)}else{let[,t]=o.splitText(c,l);t.replace(e)}}})},[e,n]);if(null===n||void 0===i||void 0===o||0===o.length)return null;let d=e.getEditorState().read(()=>(function(e){let t=e.index+e[1].length;if(function(e){if(0!==e)return!1;let t=(0,f.dL)();if(!(0,f.OP)(t))return!1;let n=t.anchor.getNode().getPreviousSibling();return!!((0,f.Gg)(n)&&n.isTextEntity())}(t))return null;let n=window.getSelection();if(null===n||!n.isCollapsed)return null;let r=n.anchorNode;if(null===r)return null;let i=n.anchorOffset;if(null===i)return null;let s=document.createRange();try{return s.setStart(r,t),s.setEnd(r,i),s}catch(e){return null}})(n));return null===d?null:(0,s.jsx)(ev.Provider,{value:o,children:(0,s.jsx)(e_.Provider,{value:c,children:(0,s.jsx)(eb.Provider,{value:()=>r(null),children:(0,s.jsx)(eN,{range:d,children:(0,s.jsx)(eS,{className:"lb-lexical-suggestions-list lb-lexical-mention-suggestions-list",children:o.map(e=>(0,s.jsx)(ew,{value:e.id,className:"lb-lexical-suggestions-list-item lb-lexical-mention-suggestion",children:"user"===e.kind?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(eh.q,{userId:e.id,className:"lb-lexical-mention-suggestion-avatar"}),(0,s.jsx)(ef.n,{userId:e.id,className:"lb-lexical-mention-suggestion-user"})]}):"group"===e.kind?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(eh.q,{groupId:e.id,className:"lb-lexical-mention-suggestion-avatar",icon:(0,s.jsx)(ep.o,{})}),(0,s.jsx)(eg.Z,{groupId:e.id,className:"lb-lexical-mention-suggestion-group",children:(0,s.jsx)(em.m,{groupId:e.id,className:"lb-lexical-mention-suggestion-group-description"})})]}):(0,ei.vE)(e,"Unhandled mention kind")},e.id))})},i)})})})}function eN({children:e,range:t}){let{refs:{setReference:n,setFloating:r},strategy:i,x:a,y:u}=(0,o.YF)({strategy:"fixed",placement:"top-start",middleware:[(0,o.RR)({padding:10,
1crossAxis:!1}),(0,o.cv)(10),(0,o.Cp)({padding:10}),(0,o.uY)({padding:10,limiter:(0,o.dr)()}),(0,o.dp)({padding:10})],whileElementsMounted:(...e)=>(0,l.Me)(...e,{animationFrame:!0})});return(0,eo.bt)(()=>{n({getBoundingClientRect:()=>t.getBoundingClientRect()})},[n,t]),(0,s.jsx)(ey.h,{asChild:!0,children:(0,s.jsx)("div",{ref:r,style:{position:i,top:0,left:0,transform:`translate3d(${Math.round(a)}px, ${Math.round(u)}px, 0)`,minWidth:"max-content"},className:"lb-root lb-portal lb-elevation lb-lexical-suggestions lb-lexical-mention-suggestions",children:e})})}var eF=n(53947);function eO(){let e=(0,es.X5)(),t=(0,a.useCallback)(()=>{let t=e?.getStatus();return"synchronizing"===t||"synchronized"===t},[e]),n=(0,a.useCallback)(t=>void 0===e?()=>{}:(e.on("status",t),()=>{e.off("status",t)}),[e]);return(0,a.useSyncExternalStore)(n,t,t)}let eD=({children:e})=>{let t=void 0!==(0,es.G4)(),[n]=(0,h.g)(),r=(0,es.kB)();if(!n.hasNodes([eu.lz,ed.AV,ec.qS]))throw Error("LiveblocksPlugin requires Lexical configuration to be wrapped in the `liveblocksConfig(options)` function. For more information: https://liveblocks.io/docs/api-reference/liveblocks-react-lexical#liveblocksConfig");let[i,u]=(0,a.useState)(void 0),{refs:{setReference:c,setFloating:d},strategy:f,x:p,y:g}=(0,o.YF)({strategy:"fixed",placement:"bottom",whileElementsMounted:(...e)=>(0,l.Me)(...e,{animationFrame:!0})});(0,a.useEffect)(()=>{},[]),(0,es.Pg)(ei.KS.Lexical,"root");let m=(0,es.f8)(),y=(0,a.useCallback)((e,t)=>{let n=(0,el.D)(r,{},!0);return t.set(e,n.getYDoc()),n},[r]),v=(0,eF.s)();(0,eo.bt)(()=>{null!==v&&c({getBoundingClientRect:()=>v.getBoundingClientRect()})},[c,v]);let _=(0,a.useCallback)(e=>{d(e),u({current:e})},[d,u]);return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{ref:_,className:"lb-root lb-lexical-cursors",style:{position:f,top:0,left:0,transform:`translate3d(${Math.round(p)}px, ${Math.round(g)}px, 0)`,minWidth:"max-content"}}),m&&(0,s.jsx)(en,{id:r.id,providerFactory:y,username:m.info?.name??"",cursorColor:m.info?.color,cursorsContainerRef:i,shouldBootstrap:!0},r.id),t&&(0,s.jsx)(eP,{}),(0,s.jsx)(ea.oW,{children:e})]})}},82263:function(e,t,n){"use strict";n.d(t,{PJ:function(){return d},VL:function(){return c},qS:function(){return u}});var r=n(44825),i=n(95054),s=n(55800),o=n(18193),l=n(27389);function a({mention:e,nodeKey:t}){return(0,r.jsxs)(l.p,{nodeKey:t,children:[i.$S,(0,r.jsx)(s.Z,{groupId:e.id})]})}class u extends o.Ij{__id;__groupId;__userIds;constructor(e,t,n,r){super(r),this.__id=e,this.__groupId=t,this.__userIds=n}static getType(){return"lb-group-mention"}static clone(e){return new u(e.__id,e.__groupId,e.__userIds,e.__key)}createDOM(){let e=document.createElement("span");return e.style.display="inline-block",e.style.userSelect="none",e}updateDOM(){return!1}static importDOM(){return{span:()=>({conversion:e=>{let t;let n=e.getAttribute("data-lexical-lb-group-mention");if(!n)return null;let r=e.getAttribute("data-lexical-lb-user-ids");if(r)try{let e=JSON.parse(r);Array.isArray(e)&&(t=e)}catch{}return{node:d(n,t)}},priority:1})}}exportDOM(){let e=document.createElement("span");return e.setAttribute("data-lexical-lb-group-mention",this.getGroupId()),e.setAttribute("data-lexical-lb-group-mention-users",JSON.stringify(this.getUserIds())),e.textContent=this.getTextContent(),{element:e}}static importJSON(e){return d(e.groupId,e.userIds)}exportJSON(){return{groupId:this.__groupId,userIds:this.__userIds,type:"lb-group-mention",version:1}}getGroupId(){return this.getLatest().__groupId}getId(){return this.getLatest().__id}getUserIds(){return this.getLatest().__userIds}
1decorate(){let e={id:this.getGroupId(),kind:"group",userIds:this.getUserIds()};return(0,r.jsx)(a,{mention:e,nodeKey:this.getKey()})}}function c(e){return e instanceof u}function d(e,t){let n=new u((0,i.TK)(),e,t);return(0,o.U2)(n)}},27389:function(e,t,n){"use strict";n.d(t,{p:function(){return a}});var r=n(44825),i=n(88332),s=n(96369),o=n(18193),l=n(71100);let a=(0,l.forwardRef)(({nodeKey:e,children:t,className:n,...a},u)=>{let[c]=(0,i.g)(),d=function(e){let[t]=(0,i.g)(),n=(0,l.useCallback)(e=>t.registerUpdateListener(e),[t]),r=(0,l.useCallback)(()=>t.getEditorState().read(()=>(function(e){let t=(0,o.gI)(e);return null!==t&&t.isSelected()})(e)),[t,e]);return(0,l.useSyncExternalStore)(n,r,r)}(e),h=(0,l.useCallback)(t=>{c.update(()=>{t.stopPropagation(),t.preventDefault();let n=(0,o.h5)();n.add(e),(0,o.oq)(n)})},[c,e]);return(0,r.jsx)("span",{onClick:h,"data-selected":d?"":void 0,className:(0,s.cn)("lb-root lb-mention lb-lexical-mention",n),ref:u,...a,children:t})})},61816:function(e,t,n){"use strict";n.d(t,{AV:function(){return a},IY:function(){return c},kz:function(){return u}});var r=n(44825),i=n(95054),s=n(35926),o=n(18193),l=n(27389);class a extends o.Ij{__id;__userId;constructor(e,t,n){super(n),this.__id=e,this.__userId=t}static getType(){return"lb-mention"}static clone(e){return new a(e.__id,e.__userId,e.__key)}createDOM(){let e=document.createElement("span");return e.style.display="inline-block",e.style.userSelect="none",e}updateDOM(){return!1}static importDOM(){return{span:()=>({conversion:e=>{let t=e.getAttribute("data-lexical-lb-mention");return t?{node:c(t)}:null},priority:1})}}exportDOM(){let e=document.createElement("span");return e.setAttribute("data-lexical-lb-mention",this.getUserId()),e.textContent=this.getUserId(),{element:e}}static importJSON(e){return c(e.userId)}exportJSON(){return{userId:this.__userId,type:"lb-mention",version:1}}getUserId(){return this.getLatest().__userId}getId(){return this.getLatest().__id}decorate(){return(0,r.jsxs)(l.p,{nodeKey:this.getKey(),children:[(0,r.jsx)("span",{className:"lb-mention-symbol",children:i.$S}),(0,r.jsx)(s.n,{userId:this.getUserId()})]})}getTextContent(){return i.$S+this.getUserId()}}function u(e){return e instanceof a}function c(e){let t=new a((0,i.TK)(),e);return(0,o.U2)(t)}},53947:function(e,t,n){"use strict";n.d(t,{s:function(){return s}});var r=n(88332),i=n(71100);function s(){let[e]=(0,r.g)(),t=(0,i.useCallback)(t=>e.registerRootListener(t),[e]),n=(0,i.useCallback)(()=>e.getRootElement(),[e]);return(0,i.useSyncExternalStore)(t,n,n)}},88587:function(e,t,n){"use strict";n.d(t,{j:function(){return C}});var r=n(44825),i=n(95054),s=n(9776),o=n(95254),l=n(71100),a=n(41679);function u(e){return(0,r.jsx)(a.JO,{...e,children:(0,r.jsx)("path",{d:"M10 4v12m6-6-6 6-6-6"})})}var c=n(92871),d=n(21469);function h(e){return(0,r.jsxs)(a.JO,{...e,children:[(0,r.jsx)("circle",{cx:10,cy:10,r:7}),(0,r.jsx)("path",{d:"m13 8-4 4-2-2"})]})}function f(e){return(0,r.jsxs)(a.JO,{...e,children:[(0,r.jsx)("circle",{cx:10,cy:10,r:7,fill:"currentColor"}),(0,r.jsx)("path",{d:"m13 8-4 4-2-2",stroke:"var(--lb-icon-background)"})]})}var p=n(31168),g=n(96369),m=n(19554),y=n(31550);function v(e){return window.addEventListener("blur",e),window.addEventListener("focus",e),()=>{window.removeEventListener("blur",e),window.removeEventListener("focus",e)}}function _(){return document.hasFocus()}function b(){return!0}var x=n(55805),S=n(3662),w=n(91989),E=n(81544);function T(e){let{thread:t}=e,{id:n,roomId:i}=t,o=(0,l.useRef)(null),a=(0,s.VD)(i),u=(0,l.useSyncExternalStore)(v,_,b);return(0,y.D)(o,e=>{e&&a(n)},{enabled:u}),(0,r.jsx)("div",{ref:o,style:{height:0},"aria-hidden":!0,"data-mark-as-read-marker":""})}let C=(0,l.forwardRef)((e,t)=>{let{thread:n,indentCommentContent:a=!0,showActions:y="hover",showDeletedComments:v,showResolveAction:_=!0,showReactions:b=!0,showComposer:C="collapsed",showAttachments:k=!0,showComposerFormattingControls:A=!0,maxVisibleComments:P,commentDropdownItems:N,onResolvedChange:F,onCommentEdit:O,onCommentDelete:D,onThreadDelete:L,onAuthorClick:I,onMentionClick:M,onAttachmentClick:R,onComposerSubmit:B,blurComposerOnSubmit:j,autoFocus:U,overrides:V,components:z,className:$,...W}=e,K=(0,m.U)(null==z?void 0:z.Comment,x.sv),H=(0,s.rh)(n.roomId),G=(0,s.ld)(n.roomId),Y=(0,p.QG)(V),[q,J]=(0,l.useState)(!1),Z=(0,l.useMemo)(()=>v?0:n.comments.findIndex(e=>e.body),[v,n.comments]),X=(0,l.useMemo)(()=>v?n.comments.length-1:(0,i.qr)(n.comments,e=>!!e.body),[v,n.comments]),Q=(0,l.useMemo)(()=>v?n.comments.length:n.comments.filter(e=>e.body).length,[v,n.comments]),ee=(0,l.useMemo)(()=>{var e,t,r,i,s;let o="number"==typeof P?P:null==P?void 0:P.max,l=null!==(e="object"==typeof P?null==P?void 0:P.show:void 0)&&void 0!==e?e:"newest";if(q||void 0===o)return;let a=n.comments.map((e,t)=>({comment:e,index:t})).filter(e=>{let{comment:t}=e;return v||t.body});if(a.length<=Math.max(o,2))return;let u=a[0],c=a[a.length-1];if(o<=2)return{firstIndex:null!==(i=null===(t=a[1])||void 0===t?void 0:t.index)&&void 0!==i?i:u.index,lastIndex:null!==(s=null===(r=a[a.length-2])||void 0===r?void 0:r.index)&&void 0!==s?s:c.index,count:a.slice(1,a.length-1).length};let d=o-2,h=a[1+("oldest"===l?d:"newest"===l?0:Math.floor(d/2))],f=a[a.length-2-("oldest"===l?0:"newest"===l?d:Math.ceil(d/2))];if(h&&f&&!(h.index>f.index))return{firstIndex:h.index,lastIndex:f.index,count:n.comments.slice(h.index,f.index+1).filter(e=>v||e.body).length}},[P,q,v,n.comments]),{status:et,unreadSince:en,subscribe:er,unsubscribe:ei}=(0,s.Fv)(n.roomId,n.id),es=(0,l.useMemo)(()=>
1{if("subscribed"!==et)return;if(null===en)return Z;let e=n.comments.findIndex(e=>(!!v||e.body)&&e.createdAt>en);return e>=0&&e<n.comments.length?e:void 0},[Z,v,et,n.comments,en]),[eo,el]=(0,l.useState)(),ea=void 0===eo?es:eo;(0,l.useEffect)(()=>{es&&el(e=>Math.min(null!=e?e:1/0,es))},[es]);let eu=(0,s.B9)(n.roomId),ec=!(eu.size>0)||eu.has(i.y3.CommentsWrite)||eu.has(i.y3.Write),ed=(0,l.useCallback)(e=>{e.stopPropagation()},[]),eh=(0,l.useCallback)(e=>{null==F||F(e),e?H(n.id):G(n.id)},[H,G,F,n.id]),ef=(0,l.useCallback)(e=>{null==D||D(e),n.comments.filter(e=>e.body).length<=1&&(null==L||L(n))},[D,L,n]),ep=(0,l.useCallback)(()=>{"subscribed"===et?ei():er()},[et,er,ei]),eg=0;return(0,r.jsx)(E.pn,{children:(0,r.jsxs)("div",{className:(0,g.cn)("lb-root lb-thread","hover"===y&&"lb-thread:show-actions-hover",$),"data-resolved":n.resolved?"":void 0,"data-unread":void 0!==es?"":void 0,dir:Y.dir,...W,ref:t,children:[(0,r.jsx)("div",{className:"lb-thread-comments",role:"feed",children:n.comments.map((e,t)=>{let i=v||e.body,s=t===Z,p=void 0!==es&&t>=es,g=ee&&t>=ee.firstIndex&&t<=ee.lastIndex,m=!v&&!e.body;if(g&&t===ee.firstIndex)return(0,r.jsx)("div",{className:"lb-thread-show-more",children:(0,r.jsx)(w.zx,{variant:"ghost",className:"lb-thread-show-more-button",onClick:()=>J(!0),children:Y.THREAD_SHOW_MORE_COMMENTS(ee.count)})},"".concat(e.id,":show-more"));if(g||m)return null;i&&eg++;let S=(0,r.jsx)(K,{tabIndex:0,"aria-posinset":eg,"aria-setsize":Q,overrides:V,className:"lb-thread-comment","data-unread":p?"":void 0,comment:e,indentContent:a,showDeleted:v,showActions:y,showReactions:b,showAttachments:k,showComposerFormattingControls:A,onCommentEdit:O,onCommentDelete:ef,onAuthorClick:I,onMentionClick:M,onAttachmentClick:R,components:z,actionsClassName:s?"lb-thread-actions":void 0,actions:s&&_?(0,r.jsx)(E.u,{content:n.resolved?Y.THREAD_UNRESOLVE:Y.THREAD_RESOLVE,children:(0,r.jsx)(o.f,{pressed:n.resolved,onPressedCh
1ange:eh,asChild:!0,children:(0,r.jsx)(w.zx,{className:"lb-comment-action",onClick:ed,"aria-label":n.resolved?Y.THREAD_UNRESOLVE:Y.THREAD_RESOLVE,icon:n.resolved?(0,r.jsx)(f,{}):(0,r.jsx)(h,{}),disabled:!ec})})}):null,internalDropdownItems:s?(0,r.jsx)(x.sv.DropdownItem,{onSelect:ep,icon:"subscribed"===et?(0,r.jsx)(d.y,{}):(0,r.jsx)(c.D,{}),children:"subscribed"===et?Y.THREAD_UNSUBSCRIBE:Y.THREAD_SUBSCRIBE}):void 0,dropdownItems:N},e.id);return t===ea&&ea!==Z&&ea<=X?(0,r.jsxs)(l.Fragment,{children:[(0,r.jsx)("div",{className:"lb-thread-new-indicator","aria-label":Y.THREAD_NEW_INDICATOR_DESCRIPTION,children:(0,r.jsxs)("span",{className:"lb-thread-new-indicator-label",children:[(0,r.jsx)(u,{className:"lb-thread-new-indicator-label-icon"}),Y.THREAD_NEW_INDICATOR]})}),S]},e.id):S})}),void 0!==es&&(0,r.jsx)(T,{thread:n}),C&&(0,r.jsx)(S.ad,{className:"lb-thread-composer",threadId:n.id,defaultCollapsed:"collapsed"===C||void 0,showAttachments:k,showFormattingControls:A,onComposerSubmit:B,blurOnSubmit:j,overrides:{COMPOSER_PLACEHOLDER:Y.THREAD_COMPOSER_PLACEHOLDER,COMPOSER_SEND:Y.THREAD_COMPOSER_SEND,...V},roomId:n.roomId,autoFocus:U})]})})})},19554:function(e,t,n){"use strict";n.d(t,{U:function(){return s}});var r=n(44825),i=n(71100);function s(e,t){let n=(0,i.useRef)(e);return n.current=e,(0,i.useMemo)(()=>e=>{let i=n.current;return i?i.prototype&&"isReactComponent"in i.prototype?(0,r.jsx)(i,{...e}):i(e):(0,r.jsx)(t,{...e})},[t])}},76577:function(e,t,n){"use strict";let r;n.d(t,{D:function(){return eN}});var i=n(95054),s=n(53094).Buffer;let o="function"==typeof s,l="function"==typeof TextDecoder?new TextDecoder:void 0,a="function"==typeof TextEncoder?new TextEncoder:void 0,u=Array.prototype.slice.call("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="),c=(r={},u.forEach((e,t)=>r[e]=t),r),d=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,h=String.fromCharCode.bind(String),f="function"==typeof Uint8Array.from?Uint8Array.from.bind(Uint8Array):e=>new Uint8Array(Array.prototype.slice.call(e,0)),p=e=>e.replace(/=/g,"").replace(/[+\/]/g,e=>"+"==e?"-":"_"),g=e=>e.replace(/[^A-Za-z0-9\+\/]/g,""),m="function"==typeof btoa?e=>btoa(e):o?e=>s.from(e,"binary").toString("base64"):e=>{let t,n,r,i,s="",o=e.length%3;for(let o=0;o<e.length;){if((n=e.charCodeAt(o++))>255||(r=e.charCodeAt(o++))>255||(i=e.charCodeAt(o++))>255)throw TypeError("invalid character found");s+=u[(t=n<<16|r<<8|i)>>18&63]+u[t>>12&63]+u[t>>6&63]+u[63&t]}return o?s.slice(0,o-3)+"===".substring(o):s},y=o?e=>s.from(e).toString("base64"):e=>{let t=[];for(let n=0,r=e.length;n<r;n+=4096)t.push(h.apply(null,e.subarray(n,n+4096)));return m(t.join(""))},v=e=>{if(e.length<2){var t=e.charCodeAt(0);return t<128?e:t<2048?h(192|t>>>6)+h(128|63&t):h(224|t>>>12&15)+h(128|t>>>6&63)+h(128|63&t)}var t=65536+(e.charCodeAt(0)-55296)*1024+(e.charCodeAt(1)-56320);return h(240|t>>>18&7)+h(128|t>>>12&63)+h(128|t>>>6&63)+h(128|63&t)},_=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,b=e=>e.replace(_,v),x=o?e=>s.from(e,"utf8").toString("base64"):a?e=>y(a.encode(e)):e=>m(b(e)),S=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,w=e=>{switch(e.length){case 4:var t=((7&e.charCodeAt(0))<<18|(63&e.charCodeAt(1))<<12|(63&e.charCodeAt(2))<<6|63&e.charCodeAt(3))-65536;return h((t>>>10)+55296)+h((1023&t)+56320);case 3:return h((15&e.charCodeAt(0))<<12|(63&e.charCodeAt(1))<<6|63&e.charCodeAt(2));default:return h((31&e.charCodeAt(0))<<6|63&e.charCodeAt(1))}},E=e=>e.replace(S,w),T="function"==typeof atob?e=>atob(g(e)):o?e=>s.from(e,"base64").toString("binary"):e=>{let t,n,r;if(e=e.replace(/\s+/g,""),!d.test(e))throw TypeError("malformed base64.");e+="==".slice(2-(3&e.length));let i=[];for(let s=0;s<e.length;)t=c[e.charAt(s++)]<<18|c[e.charAt(s++)]<<12|(n=c[e.charAt(s++)])<<6|(r=c[e.charAt(s++)]),64===n?i.push(h(t>>16&255)):64===r?i.push(h(t>>16&255,t>>8&255)):i.push(h(t>>16&255,t>>8&255,255&t));return i.join("")},C=o?e=>f(s.from(e,"base64")):e=>f(T(e).split("").map(e=>e.charCodeAt(0))),k=o?e=>s.from(e,"base64").toString("utf8"):l?e=>l.decode(C(e)):e=>E(T(e)),A=e=>g(e.replace(/[-_]/g,e=>"-"==e?"+":"/")),P={fromUint8Array:(e,t=!1)=>t?p(y(e)):y(e),toUint8Array:e=>C(A(e))};var N=n(11006),F=n(50345),O=n(81362);let D=e=>F.Ue((t,n)=>{e.onerror=e=>n(Error(e.target.error)),e.onsuccess=e=>t(e.target.result)}),L=(e,t)=>F.Ue((n,r)=>{let i=indexedDB.open(e);i.onupgradeneeded=e=>t(e.target.result),i.onerror=e=>r(O.Ue(e.target.error)),i.onsuccess=e=>{let t=e.target.result;t.onversionchange=()=>{t.close()},n(t)}}),I=e=>D(indexedDB.deleteDatabase(e)),M=(e,t)=>t.forEach(t=>e.createObjectStore.apply(e,t)),R=(e,t,n="readwrite")=>{let r=e.transaction(t,n);return t.map(e=>Y(r,e))},B=(e,t)=>D(e.count(t)),j=(e,t)=>D(e.get(t)),U=(e,t)=>D(e.delete(t)),V=(e,t,n)=>D(e.put(t,n)),z=(e,t)=>D(e.add(t)),$=(e,t,n)=>D(e.getAll(t,n)),W=(e,t,n)=>{let r=null;return G(e,t,e=>(r=e,!1),n).then(()=>r)},K=(e,t=null)=>W(e,t,"prev"),H=(e,t)=>F.Ue((n,r)=>{e.onerror=r,e.onsuccess=async e=>{let r=e.target.result;if(null===r||await t(r)===!1)return n();r.continue()}}),G=(e,t,n,r="next")=>H(e.openKeyCursor(t,r),e=>n(e.key)),Y=(e,t)=>
1e.objectStore(t),q=(e,t)=>IDBKeyRange.upperBound(e,t),J=(e,t)=>IDBKeyRange.lowerBound(e,t);var Z=n(9027);let X="custom",Q="updates",ee=(e,t=()=>{},n=()=>{})=>{let[r]=R(e.db,[Q]);return $(r,J(e._dbref,!1)).then(i=>{e._destroyed||(t(r),N.ay(e.doc,()=>{i.forEach(t=>N.NG(e.doc,t))},e,!1),n(r))}).then(()=>K(r).then(t=>{e._dbref=t+1})).then(()=>B(r).then(t=>{e._dbsize=t})).then(()=>r)},et=(e,t=!0)=>ee(e).then(n=>{(t||e._dbsize>=500)&&z(n,N.D$(e.doc)).then(()=>U(n,q(e._dbref,!0))).then(()=>B(n).then(t=>{e._dbsize=t}))});class en extends Z.y{constructor(e,t){super(),this.doc=t,this.name=e,this._dbref=0,this._dbsize=0,this._destroyed=!1,this.db=null,this.synced=!1,this._db=L(e,e=>M(e,[["updates",{autoIncrement:!0}],["custom"]])),this.whenSynced=F.Ue(e=>this.on("synced",()=>e(this))),this._db.then(e=>{this.db=e,ee(this,e=>z(e,N.D$(t)),()=>{if(this._destroyed)return this;this.synced=!0,this.emit("synced",[this])})}),this._storeTimeout=1e3,this._storeTimeoutId=null,this._storeUpdate=(e,t)=>{if(this.db&&t!==this){let[t]=R(this.db,[Q]);z(t,e),++this._dbsize>=500&&(null!==this._storeTimeoutId&&clearTimeout(this._storeTimeoutId),this._storeTimeoutId=setTimeout(()=>{et(this,!1),this._storeTimeoutId=null},this._storeTimeout))}},t.on("update",this._storeUpdate),this.destroy=this.destroy.bind(this),t.on("destroy",this.destroy)}destroy(){return this._storeTimeoutId&&clearTimeout(this._storeTimeoutId),this.doc.off("update",this._storeUpdate),this.doc.off("destroy",this.destroy),this._destroyed=!0,this._db.then(e=>{e.close()})}clearData(){return this.destroy().then(()=>{I(this.name)})}get(e){return this._db.then(t=>{let[n]=R(t,[X],"readonly");return j(n,e)})}set(e,t){return this._db.then(n=>{let[r]=R(n,[X]);return V(r,t,e)})}del(e){return this._db.then(t=>{let[n]=R(t,[X]);return U(n,e)})}}function er(e,...t){if(!(e instanceof Uint8Array||ArrayBuffer.isView(e)&&"Uint8Array"===e.constructor.name))throw Error("Uint8Array expected");if(t.length>0&&!t.includes(e.length))throw Error("Uint8Array expected of length "+t+", got length="+e.length)}function ei(e,t=!0){if(e.destroyed)throw Error("Hash instance has been destroyed");if(t&&e.finished)throw Error("Hash#digest() has already been called")}function es(...e){for(let t=0;t<e.length;t++)e[t].fill(0)}function eo(e){return new DataView(e.buffer,e.byteOffset,e.byteLength)}function el(e,t){return e<<32-t|e>>>t}function ea(e){return"string"==typeof e&&(e=function(e){if("string"!=typeof e)throw Error("string expected");return new Uint8Array(new TextEncoder().encode(e))}(e)),er(e),e}class eu{}class ec extends eu{constructor(e,t,n,r){super(),this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.blockLen=e,this.outputLen=t,this.padOffset=n,this.isLE=r,this.buffer=new Uint8Array(e),this.view=eo(this.buffer)}update(e){ei(this),er(e=ea(e));let{view:t,buffer:n,blockLen:r}=this,i=e.length;for(let s=0;s<i;){let o=Math.min(r-this.pos,i-s);if(o===r){let t=eo(e);for(;r<=i-s;s+=r)this.process(t,s);continue}n.set(e.subarray(s,s+o),this.pos),this.pos+=o,s+=o,this.pos===r&&(this.process(t,0),this.pos=0)}return this.length+=e.length,this.roundClean(),this}digestInto(e){ei(this),function(e,t){er(e);let n=t.outputLen;if(e.length<n)throw Error("digestInto() expects output buffer of length at least "+n)}(e,this),this.finished=!0;let{buffer:t,view:n,blockLen:r,isLE:i}=this,{pos:s}=this;t[s++]=128,es(this.buffer.subarray(s)),this.padOffset>r-s&&(this.process(n,0),s=0);for(let e=s;e<r;e++)t[e]=0;!function(e,t,n,r){if("function"==typeof e.setBigUint64)return e.setBigUint64(t,n,r);let i=BigInt(32),s=BigInt(4294967295),o=Number(n>>i&s),l=Number(n&s),a=r?4:0,u=r?0:4;e.setUint32(t+a,o,r),e.setUint32(t+u,l,r)}(n,r-8,BigInt(8*this.length),i),this.process(n,0);let o=eo(e),l=this.outputLen;if(l%4)throw Error("_sha2: outputLen should be aligned to 32bit");let a=l/4,u=this.get();if(a>u.length)throw Error("_sha2: outputLen bigger than state");for(let e=0;e<a;e++)o.setUint32(4*e,u[e],i)}digest(){let{buffer:e,outputLen:t}=this;this.digestInto(e);let n=e.slice(0,t);return this.destroy(),n}_cloneInto(e){e||(e=new this.constructor),e.set(...this.get());let{blockLen:t,buffer:n,length:r,finished:i,destroyed:s,pos:o}=this;return e.destroyed=s,e.finished=i,e.length=r,e.pos=o,r%t&&e.buffer.set(n),e}clone(){return this._cloneInto()}}let ed=Uint32Array.from([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),eh=BigInt(4294967296-1),ef=BigInt(32),ep=Uint32Array.from([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756
1734187,3204031479,3329325298]),eg=new Uint32Array(64);class em extends ec{constructor(e=32){super(64,e,8,!1),this.A=0|ed[0],this.B=0|ed[1],this.C=0|ed[2],this.D=0|ed[3],this.E=0|ed[4],this.F=0|ed[5],this.G=0|ed[6],this.H=0|ed[7]}get(){let{A:e,B:t,C:n,D:r,E:i,F:s,G:o,H:l}=this;return[e,t,n,r,i,s,o,l]}set(e,t,n,r,i,s,o,l){this.A=0|e,this.B=0|t,this.C=0|n,this.D=0|r,this.E=0|i,this.F=0|s,this.G=0|o,this.H=0|l}process(e,t){for(let n=0;n<16;n++,t+=4)eg[n]=e.getUint32(t,!1);for(let e=16;e<64;e++){let t=eg[e-15],n=eg[e-2],r=el(t,7)^el(t,18)^t>>>3,i=el(n,17)^el(n,19)^n>>>10;eg[e]=i+eg[e-7]+r+eg[e-16]|0}let{A:n,B:r,C:i,D:s,E:o,F:l,G:a,H:u}=this;for(let e=0;e<64;e++){var c,d,h,f;let t=u+(el(o,6)^el(o,11)^el(o,25))+((c=o)&l^~c&a)+ep[e]+eg[e]|0,p=(el(n,2)^el(n,13)^el(n,22))+((d=n)&(h=r)^d&(f=i)^h&f)|0;u=a,a=l,l=o,o=s+t|0,s=i,i=r,r=n,n=t+p|0}n=n+this.A|0,r=r+this.B|0,i=i+this.C|0,s=s+this.D|0,o=o+this.E|0,l=l+this.F|0,a=a+this.G|0,u=u+this.H|0,this.set(n,r,i,s,o,l,a,u)}roundClean(){es(eg)}destroy(){this.set(0,0,0,0,0,0,0,0),es(this.buffer)}}let ey=function(e,t=!1){let n=e.length,r=new Uint32Array(n),i=new Uint32Array(n);for(let s=0;s<n;s++){let{h:n,l:o}=function(e,t=!1){return t?{h:Number(e&eh),l:Number(e>>ef&eh)}:{h:0|Number(e>>ef&eh),l:0|Number(e&eh)}}(e[s],t);[r[s],i[s]]=[n,o]}return[r,i]}(["0x428a2f98d728ae22","0x7137449123ef65cd","0xb5c0fbcfec4d3b2f","0xe9b5dba58189dbbc","0x3956c25bf348b538","0x59f111f1b605d019","0x923f82a4af194f9b","0xab1c5ed5da6d8118","0xd807aa98a3030242","0x12835b0145706fbe","0x243185be4ee4b28c","0x550c7dc3d5ffb4e2","0x72be5d74f27b896f","0x80deb1fe3b1696b1","0x9bdc06a725c71235","0xc19bf174cf692694","0xe49b69c19ef14ad2","0xefbe4786384f25e3","0x0fc19dc68b8cd5b5","0x240ca1cc77ac9c65","0x2de92c6f592b0275","0x4a7484aa6ea6e483","0x5cb0a9dcbd41fbd4","0x76f988da831153b5","0x983e5152ee66dfab","0xa831c66d2db43210","0xb00327c898fb213f","0xbf597fc7beef0ee4","0xc6e00bf33da88fc2","0xd5a79147930aa725","0x06ca6351e003826f","0x142929670a0e6e70","0x27b70a8546d22ffc","0x2e1b21385c26c926","0x4d2c6dfc5ac42aed","0x53380d139d95b3df","0x650a73548baf63de","0x766a0abb3c77b2a8","0x81c2c92e47edaee6","0x92722c851482353b","0xa2bfe8a14cf10364","0xa81a664bbc423001","0xc24b8b70d0f89791","0xc76c51a30654be30","0xd192e819d6ef5218","0xd69906245565a910","0xf40e3585
15771202a","0x106aa07032bbd1b8","0x19a4c116b8d2d0c8","0x1e376c085141ab53","0x2748774cdf8eeb99","0x34b0bcb5e19b48a8","0x391c0cb3c5c95a63","0x4ed8aa4ae3418acb","0x5b9cca4f7763e373","0x682e6ff3d6b2b8a3","0x748f82ee5defb2fc","0x78a5636f43172f60","0x84c87814a1f0ab72","0x8cc702081a6439ec","0x90befffa23631e28","0xa4506cebde82bde9","0xbef9a3f7b2c67915","0xc67178f2e372532b","0xca273eceea26619c","0xd186b8c721c0c207","0xeada7dd6cde0eb1e","0xf57d4f7fee6ed178","0x06f067aa72176fba","0x0a637dc5a2c898a6","0x113f9804bef90dae","0x1b710b35131c471b","0x28db77f523047d84","0x32caab7b40c72493","0x3c9ebe0a15c9bebc","0x431d67c49c100d4c","0x4cc5d4becb3e42b6","0x597f299cfc657e2a","0x5fcb6fab3ad6faec","0x6c44198c4a475817"].map(e=>BigInt(e)));ey[0],ey[1];let ev=function(e){let t=t=>e().update(ea(t)).digest(),n=e();return t.outputLen=n.outputLen,t.blockLen=n.blockLen,t.create=()=>e(),t}(()=>new em);var e_=()=>new Map,eb=(e,t,n)=>{let r=e.get(t);return void 0===r&&e.set(t,r=n()),r},ex=()=>new Set,eS=Array.from,ew=class{constructor(){this._observers=e_()}on(e,t){eb(this._observers,e,ex).add(t)}once(e,t){let n=(...r)=>{this.off(e,n),t(...r)};this.on(e,n)}off(e,t){let n=this._observers.get(e);void 0!==n&&(n.delete(t),0===n.size&&this._observers.delete(e))}emit(e,t){return eS((this._observers.get(e)||e_()).values()).forEach(e=>e(...t))}destroy(){this._observers=e_()}},eE="__yjs",eT="__yjs_clientid",eC=class extends ew{room;doc;states=new Map;actorToClientMap=new Map;meta=new Map;_checkInterval=0;othersUnsub;constructor(e,t){super(),this.doc=e,this.room=t,this.room.updatePresence({[eT]:this.doc.clientID}),this.othersUnsub=this.room.events.others.subscribe(e=>{let t;if("leave"===e.type){let n=this.actorToClientMap.get(e.user.connectionId);void 0!==n&&(t={added:[],updated:[],removed:[n]}),this.rebuildActorToClientMap(e.others)}if("enter"===e.type||"update"===e.type){this.rebuildActorToClientMap(e.others);let n=this.actorToClientMap.get(e.user.connectionId);void 0!==n&&(t={added:"enter"===e.type?[n]:[],updated:"update"===e.type?[n]:[],removed:[]})}"reset"===e.type&&this.rebuildActorToClientMap(e.others),void 0!==t&&(this.emit
1("change",[t,"presence"]),this.emit("update",[t,"presence"]))})}rebuildActorToClientMap(e){this.actorToClientMap.clear(),e.forEach(e=>{void 0!==e.presence[eT]&&this.actorToClientMap.set(e.connectionId,e.presence[eT])})}destroy(){this.emit("destroy",[this]),this.othersUnsub(),this.setLocalState(null),super.destroy()}getLocalState(){let e=this.room.getPresence();return 0===Object.keys(e).length||void 0===e[eE]?null:e[eE]}setLocalState(e){let t=this.room.getSelf()?.presence;if(null===e){if(void 0===t)return;this.room.updatePresence({...t,[eE]:null}),this.emit("update",[{added:[],updated:[],removed:[this.doc.clientID]},"local"]);return}let n=t?.[eE],r=void 0===n?[this.doc.clientID]:[],i=void 0===n?[]:[this.doc.clientID];this.room.updatePresence({[eE]:{...n||{},...e||{}}}),this.emit("update",[{added:r,updated:i,removed:[]},"local"])}setLocalStateField(e,t){let n=this.room.getSelf()?.presence[eE];this.room.updatePresence({[eE]:{...n||{},[e]:t}})}getStates(){let e=this.room.getOthers().reduce((e,t)=>{let n=t.presence[eE],r=t.presence[eT];return void 0!==n&&void 0!==r&&e.set(r,n||{}),e},new Map),t=this.room.getSelf()?.presence[eE];return void 0!==t&&e.set(this.doc.clientID,t),e}},ek=class e extends ew{unsubscribers=[];_synced=!1;doc;updateRoomDoc;fetchRoomDoc;useV2Encoding;localSnapshotHashΣ;remoteSnapshotHashΣ;hasEverSyncedΣ;debounceTimer=null;static DEBOUNCE_INTERVAL_MS=200;isLocalAndRemoteSnapshotEqualΣ;constructor({doc:e,isRoot:t,updateDoc:n,fetchDoc:r,useV2Encoding:s}){super(),this.doc=e,this.useV2Encoding=s,this.doc.on(s?"updateV2":"update",this.updateHandler),this.updateRoomDoc=e=>{n(e,t?void 0:this.doc.guid)},this.fetchRoomDoc=e=>{r(e,t?void 0:this.doc.guid)},this.syncDoc();let o=this.useV2Encoding?N.ip(N.CO(this.doc)):N.w5(N.CO(this.doc));this.localSnapshotHashΣ=new i.MZ(P.fromUint8Array(ev(o))),this.remoteSnapshotHashΣ=new i.MZ(null),this.hasEverSyncedΣ=new i.MZ(!1),this.isLocalAndRemoteSnapshotEqualΣ=i.mU.from(()=>{let e=this.remoteSnapshotHashΣ.get();return null!==e&&this.localSnapshotHashΣ.get()===e})}handleServerUpdate=({update:e,stateVector:t,readOnly:n,v2:r,remoteSnapshotHash:i})=>{if((r?N.cp:N.NG)(this.doc,e,"backend"),t){if(!n)try{let e=(this.useV2Encoding?N.ir:N.D$)(this.doc,P.toUint8Array(t));this.updateRoomDoc(e)}catch(e){console.warn(e)}this.synced=!0,this.hasEverSyncedΣ.set(!0)}this.remoteSnapshotHashΣ.set(i)};syncDoc=()=>{this.synced=!1;let e=P.fromUint8Array(N.gJ(this.doc));this.fetchRoomDoc(e)};get synced(){return this._synced}set synced(e){this._synced!==e&&(this._synced=e,this.emit("synced",[e]),this.emit("sync",[e]))}debounced_updateLocalSnapshot(){this.debounceTimer&&clearTimeout(this.debounceTimer),this.debounceTimer=setTimeout(()=>{let e=this.useV2Encoding?N.ip(N.CO(this.doc)):N.w5(N.CO(this.doc));this.localSnapshotHashΣ.set(P.fromUint8Array(ev(e))),this.debounceTimer=null},e.DEBOUNCE_INTERVAL_MS)}updateHandler=(e,t)=>{this.debounced_updateLocalSnapshot(),"backend"===t||t instanceof en||this.updateRoomDoc(e)};experimental_getSyncStatus(){return this.hasEverSyncedΣ.get()?this.isLocalAndRemoteSnapshotEqualΣ.get()?"synchronized":"synchronizing":"loading"}destroy(){this.debounceTimer&&clearTimeout(this.debounceTimer),this.doc.off("update",this.updateHandler),this.unsubscribers.forEach(e=>e()),this._observers=new Map,this.doc.destroy()}},eA=class extends ew{room;rootDoc;options;indexeddbProvider=null;isPaused=!1;unsubscribers=[];awareness;rootDocHandler;subdocHandlersΣ=new i.ll(new Map);syncStatusΣ;permanentUserData;constructor(e,t,n={}){super(),this.rootDoc=t,this.room=e,this.options=n,this.rootDocHandler=new ek({doc:t,isRoot:!0,updateDoc:this.updateDoc,fetchDoc:this.fetchDoc,useV2Encoding:this.options.useV2Encoding_experimental??!1}),this.options.enablePermanentUserData&&(this.permanentUserData=new N.OP(t)),e[i.W_].setYjsProvider(this),this.awareness=new eC(this.rootDoc,this.room),this.unsubscribers.push(this.room.events.status.subscribe(e=>{"connected"===e?this.rootDocHandler.syncDoc():this.rootDocHandler.synced=!1})),this.unsubscribers.push(this.room.events.ydoc.subscribe(e=>{let{type:t}=e;if(t===i.Ze.UPDATE_YDOC)return;let{stateVector:n,update:r,guid:s,v2:o,remoteSnapshotHash:l}=e,a=this.room.getSelf()?.canWrite??!0,u=P.toUint8Array(r);void 0!==s?this.subdocHandlersΣ.get().get(s)?.handleServerUpdate({update:u,stateVector:n,readOnly:!a,v2:o,remoteSnapshotHash:l}):this.rootDocHandler.handleServerUpdate({update:u,stateVector:n,readOnly:!a,v2:o,remoteSnapshotHash:l})})),n.offlineSupport_experimental&&this.setupOfflineSupport(),this.rootDocHandler.on("synced",()=>{let e=this.rootDocHandler.synced;for(let[e,t]of this.subdocHandlersΣ.get())t.syncDoc();
1this.emit("synced",[e]),this.emit("sync",[e])}),this.rootDoc.on("subdocs",this.handleSubdocs),this.syncDoc(),this.syncStatusΣ=i.mU.from(()=>{let e=this.rootDocHandler.experimental_getSyncStatus();return"loading"===e||"synchronizing"===e?e:Array.from(this.subdocHandlersΣ.get().values()).map(e=>e.experimental_getSyncStatus()).some(e=>"synchronized"!==e)?"synchronizing":"synchronized"}),this.emit("status",[this.getStatus()]),this.unsubscribers.push(this.syncStatusΣ.subscribe(()=>{this.emit("status",[this.getStatus()])}))}setupOfflineSupport=()=>{this.indexeddbProvider=new en(this.room.id,this.rootDoc);let e=()=>{this.rootDocHandler.synced=!0};this.indexeddbProvider.on("synced",e),this.unsubscribers.push(()=>{this.indexeddbProvider?.off("synced",e)})};handleSubdocs=({loaded:e,removed:t,added:n})=>{e.forEach(this.createSubdocHandler);let r=this.subdocHandlersΣ.get();if(this.options.autoloadSubdocs)for(let e of n)r.has(e.guid)||e.load();for(let e of t)r.has(e.guid)&&(r.get(e.guid)?.destroy(),r.delete(e.guid))};updateDoc=(e,t)=>{(this.room.getSelf()?.canWrite??!0)&&!this.isPaused&&this.room.updateYDoc(P.fromUint8Array(e),t,this.useV2Encoding)};fetchDoc=(e,t)=>{this.room.fetchYDoc(e,t,this.useV2Encoding)};createSubdocHandler=e=>{let t=this.subdocHandlersΣ.get();if(t.has(e.guid)){t.get(e.guid)?.syncDoc();return}let n=new ek({doc:e,isRoot:!1,updateDoc:this.updateDoc,fetchDoc:this.fetchDoc,useV2Encoding:this.options.useV2Encoding_experimental??!1});t.set(e.guid,n)};loadSubdoc=e=>{for(let t of this.rootDoc.subdocs)if(t.guid===e)return t.load(),!0;return!1};syncDoc=()=>{for(let[e,t]of(this.rootDocHandler.syncDoc(),this.subdocHandlersΣ.get()))t.syncDoc()};get useV2Encoding(){return this.options.useV2Encoding_experimental??!1}get synced(){return this.rootDocHandler.synced}async pause(){await this.indexeddbProvider?.destroy(),this.indexeddbProvider=null,this.isPaused=!0}unpause(){this.isPaused=!1,this.options.offlineSupport_experimental&&this.setupOfflineSupport(),this.rootDocHandler.syncDoc()}getStatus(){return this.syncStatusΣ.get()}destroy(){for(let[e,t]of(this.unsubscribers.forEach(e=>e()),this.awareness.destroy(),this.rootDocHandler.destroy(),this._observers=new Map,this.subdocHandlersΣ.get()))t.destroy();this.subdocHandlersΣ.get().clear(),super.destroy()}async clearOfflineData(){if(this.indexeddbProvider)return this.indexeddbProvider.clearData()}getYDoc(){return this.rootDoc}disconnect(){}connect(){}get subdocHandlers(){return this.subdocHandlersΣ.get()}set subdocHandlers(e){this.subdocHandlersΣ.mutate(t=>{for(let[n,r]of(t.clear(),e))t.set(n,r)})}},eP=new WeakMap,eN=(e,t={},n=!1)=>{let r=eP.get(e);if(void 0!==r){if(!n)return r;r.destroy(),eP.delete(e)}let i=new eA(e,new N.QW,t);return e.events.roomWillDestroy.subscribeOnce(()=>{i.destroy()}),eP.set(e,i),i};(0,i.l8)("@liveblocks/yjs","3.15.1","esm")},76038:function(e,t,n){"use strict";n.d(t,{bU:function(){return w},fC:function(){return S}});var r=n(71100),i=n(85044),s=n(70566),o=n(77053),l=n(65403),a=n(51774),u=n(49787),c=n(97050),d=n(44825),h="Switch",[f,p]=(0,o.b)(h),[g,m]=f(h),y=r.forwardRef((e,t)=>{let{__scopeSwitch:n,name:o,checked:a,defaultChecked:u,required:f,disabled:p,value:m="on",onCheckedChange:y,form:v,..._}=e,[S,w]=r.useState(null),E=(0,s.e)(t,e=>w(e)),T=r.useRef(!1),C=!S||v||!!S.closest("form"),[k,A]=(0,l.T)({prop:a,defaultProp:null!=u&&u,onChange:y,caller:h});return(0,d.jsxs)(g,{scope:n,checked:k,disabled:p,children:[(0,d.jsx)(c.WV.button,{type:"button",role:"switch","aria-checked":k,"aria-required":f,"data-state":x(k),"data-disabled":p?"":void 0,disabled:p,value:m,..._,ref:E,onClick:(0,i.Mj)(e.onClick,e=>{A(e=>!e),C&&(T.current=e.isPropagationStopped(),T.current||e.stopPropagation())})}),C&&(0,d.jsx)(b,{control:S,bubbles:!T.current,name:o,value:m,checked:k,required:f,disabled:p,form:v,style:{transform:"translateX(-100%)"}})]})});y.displayName=h;var v="SwitchThumb",_=r.forwardRef((e,t)=>{let{__scopeSwitch:n,...r}=e,i=m(v,n);return(0,d.jsx)(c.WV.span,{"data-state":x(i.checked),"data-disabled":i.disabled?"":void 0,...r,ref:t})});_.displayName=v;var b=r.forwardRef((e,t)=>
1{let{__scopeSwitch:n,control:i,checked:o,bubbles:l=!0,...c}=e,h=r.useRef(null),f=(0,s.e)(h,t),p=(0,a.D)(o),g=(0,u.t)(i);return r.useEffect(()=>{let e=h.current;if(!e)return;let t=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"checked").set;if(p!==o&&t){let n=new Event("click",{bubbles:l});t.call(e,o),e.dispatchEvent(n)}},[p,o,l]),(0,d.jsx)("input",{type:"checkbox","aria-hidden":!0,defaultChecked:o,...c,tabIndex:-1,ref:f,style:{...c.style,...g,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});function x(e){return e?"checked":"unchecked"}b.displayName="SwitchBubbleInput";var S=y,w=_},56069:function(e,t,n){"use strict";n.d(t,{VY:function(){return F},aV:function(){return P},fC:function(){return A},xz:function(){return N}});var r=n(71100),i=n(85044),s=n(77053),o=n(27916),l=n(19917),a=n(97050),u=n(67175),c=n(65403),d=n(42148),h=n(44825),f="Tabs",[p,g]=(0,s.b)(f,[o.Pc]),m=(0,o.Pc)(),[y,v]=p(f),_=r.forwardRef((e,t)=>{let{__scopeTabs:n,value:r,onValueChange:i,defaultValue:s,orientation:o="horizontal",dir:l,activationMode:p="automatic",...g}=e,m=(0,u.gm)(l),[v,_]=(0,c.T)({prop:r,onChange:i,defaultProp:null!=s?s:"",caller:f});return(0,h.jsx)(y,{scope:n,baseId:(0,d.M)(),value:v,onValueChange:_,orientation:o,dir:m,activationMode:p,children:(0,h.jsx)(a.WV.div,{dir:m,"data-orientation":o,...g,ref:t})})});_.displayName=f;var b="TabsList",x=r.forwardRef((e,t)=>{let{__scopeTabs:n,loop:r=!0,...i}=e,s=v(b,n),l=m(n);return(0,h.jsx)(o.fC,{asChild:!0,...l,orientation:s.orientation,dir:s.dir,loop:r,children:(0,h.jsx)(a.WV.div,{role:"tablist","aria-orientation":s.orientation,...i,ref:t})})});x.displayName=b;var S="TabsTrigger",w=r.forwardRef((e,t)=>{let{__scopeTabs:n,value:r,disabled:s=!1,...l}=e,u=v(S,n),c=m(n),d=C(u.baseId,r),f=k(u.baseId,r),p=r===u.value;return(0,h.jsx)(o.ck,{asChild:!0,...c,focusable:!s,active:p,children:(0,h.jsx)(a.WV.button,{type:"button",role:"tab","aria-selected":p,"aria-controls":f,"data-state":p?"active":"inactive","data-disabled":s?"":void 0,disabled:s,id:d,...l,ref:t,onMouseDown:(0,i.Mj)(e.onMouseDown,e=>{s||0!==e.button||!1!==e.ctrlKey?e.preventDefault():u.onValueChange(r)}),onKeyDown:(0,i.Mj)(e.onKeyDown,e=>{[" ","Enter"].includes(e.key)&&u.onValueChange(r)}),onFocus:(0,i.Mj)(e.onFocus,()=>{let e="manual"!==u.activationMode;p||s||!e||u.onValueChange(r)})})})});w.displayName=S;var E="TabsContent",T=r.forwardRef((e,t)=>{let{__scopeTabs:n,value:i,forceMount:s,children:o,...u}=e,c=v(E,n),d=C(c.baseId,i),f=k(c.baseId,i),p=i===c.value,g=r.useRef(p);return r.useEffect(()=>{let e=requestAnimationFrame(()=>g.current=!1);return()=>cancelAnimationFrame(e)},[]),(0,h.jsx)(l.z,{present:s||p,children:n=>{let{present:r}=n;return(0,h.jsx)(a.WV.div,{"data-state":p?"active":"inactive","data-orientation":c.orientation,role:"tabpanel","aria-labelledby":d,hidden:!r,id:f,tabIndex:0,...u,ref:t,style:{...e.style,animationDuration:g.current?"0s":void 0},children:r&&o})}})});function C(e,t){return"".concat(e,"-trigger-").concat(t)}function k(e,t){return"".concat(e,"-content-").concat(t)}T.displayName=E;var A=_,P=x,N=w,F=T},9871:function(e,t,n){"use strict";let r;function i(e){return null!==e&&"object"==typeof e&&"function"==typeof e.start}n.d(t,{E:function(){return sp}});let s=e=>Array.isArray(e);function o(e,t){if(!Array.isArray(t))return!1;let n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}function l(e){return"string"==typeof e||Array.isArray(e)}function a(e){let t=[{},{}];return null==e||e.values.forEach((e,n)=>{t[0][n]=e.get(),t[1][n]=e.getVelocity()}),t}function u(e,t,n,r){if("function"==typeof t){let[i,s]=a(r);t=t(void 0!==n?n:e.custom,i,s)}if("string"==typeof t&&(t=e.variants&&e.variants[t]),"function"==typeof t){let[i,s]=a(r);t=t(void 0!==n?n:e.custom,i,s)}return t}function c(e,t,n){let r=e.getProps();return u(r,t,void 0!==n?n:r.custom,e)}let d=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],h=["initial",...d];function f(e){let t;return()=>(void 0===t&&(t=e()),t)}let p=f(()=>void 0!==window.ScrollTimeline);class g{constructor(e){this.stop=()=>this.runAll("stop"),this.animations=e.filter(Boolean)}get finished(){return Promise.all(this.animations.map(e=>"finished"in e?e.finished:e))}getAll(e){return this.animations[0][e]}setAll(e,t){for(let n=0;n<this.animations.length;n++)this.animations[n][e]=t}attachTimeline(e,t){let n=this.animations.map(n=>p()&&n.attachTimeline?n.attachTimeline(e):"function"==typeof t?t(n):void 0);return()=>
1{n.forEach((e,t)=>{e&&e(),this.animations[t].stop()})}}get time(){return this.getAll("time")}set time(e){this.setAll("time",e)}get speed(){return this.getAll("speed")}set speed(e){this.setAll("speed",e)}get startTime(){return this.getAll("startTime")}get duration(){let e=0;for(let t=0;t<this.animations.length;t++)e=Math.max(e,this.animations[t].duration);return e}runAll(e){this.animations.forEach(t=>t[e]())}flatten(){this.runAll("flatten")}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}class m extends g{then(e,t){return Promise.all(this.animations).then(e).catch(t)}}function y(e,t){return e?e[t]||e.default||e:void 0}function v(e){let t=0,n=e.next(t);for(;!n.done&&t<2e4;)t+=50,n=e.next(t);return t>=2e4?1/0:t}function _(e){return"function"==typeof e}function b(e,t){e.timeline=t,e.onfinish=null}let x=e=>Array.isArray(e)&&"number"==typeof e[0],S={linearEasing:void 0},w=function(e,t){let n=f(e);return()=>{var e;return null!==(e=S[t])&&void 0!==e?e:n()}}(()=>{try{document.createElement("div").animate({opacity:0}
1,{easing:"linear(0, 1)"})}catch(e){return!1}return!0},"linearEasing"),E=(e,t,n)=>{let r=t-e;return 0===r?1:(n-e)/r},T=(e,t,n=10)=>{let r="",i=Math.max(Math.round(t/n),2);for(let t=0;t<i;t++)r+=e(E(0,i-1,t))+", ";return`linear(${r.substring(0,r.length-2)})`},C=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,k={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:C([0,.65,.55,1]),circOut:C([.55,0,1,.45]),backIn:C([.31,.01,.66,-.59]),backOut:C([.33,1.53,.69,.99])},A={x:!1,y:!1};function P(e,t){let n=function(e,t,n){if(e instanceof Element)return[e];if("string"==typeof e){let t=document.querySelectorAll(e);return t?Array.from(t):[]}return Array.from(e)}(e),r=new AbortController;return[n,{passive:!0,...t,signal:r.signal},()=>r.abort()]}function N(e){return t=>{"touch"===t.pointerType||A.x||A.y||e(t)}}let F=(e,t)=>!!t&&(e===t||F(e,t.parentElement)),O=e=>"mouse"===e.pointerType?"number"!=typeof e.button||e.button<=0:!1!==e.isPrimary,D=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]),L=new WeakSet;function I(e){return t=>{"Enter"===t.key&&e(t)}}function M(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}let R=(e,t)=>{let n=e.currentTarget;if(!n)return;let r=I(()=>{if(L.has(n))return;M(n,"down");let e=I(()=>{M(n,"up")});n.addEventListener("keyup",e,t),n.addEventListener("blur",()=>M(n,"cancel"),t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function B(e){return O(e)&&!(A.x||A.y)}let j=e=>1e3*e,U=e=>e/1e3,V=e=>e,z=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],$=new Set(z),W=new Set(["width","height","top","left","right","bottom",...z]),K=e=>!!(e&&"object"==typeof e&&e.mix&&e.toValue),H=e=>s(e)?e[e.length-1]||0:e,G={skipAnimations:!1,useManualTiming:!1},Y=["read","resolveKeyframes","update","preRender","render","postRender"];function q(e,t){let n=!1,r=!0,i={delta:0,timestamp:0,isProcessing:!1},s=()=>n=!0,o=Y.reduce((e,t)=>(e[t]=function(e){let t=new Set,n=new Set,r=!1,i=!1,s=new WeakSet,o={delta:0,timestamp:0,isProcessing:!1};function l(t){s.has(t)&&(a.schedule(t),e()),t(o)}let a={schedule:(e,i=!1,o=!1)=>{let l=o&&r?t:n;return i&&s.add(e),l.has(e)||l.add(e),e},cancel:e=>{n.delete(e),s.delete(e)},process:e=>{if(o=e,r){i=!0;return}r=!0,[t,n]=[n,t],t.forEach(l),t.clear(),r=!1,i&&(i=!1,a.process(e))}};return a}(s),e),{}),{read:l,resolveKeyframes:a,update:u,preRender:c,render:d,postRender:h}=o,f=()=>{let s=G.useManualTiming?i.timestamp:performance.now();n=!1,i.delta=r?1e3/60:Math.max(Math.min(s-i.timestamp,40),1),i.timestamp=s,i.isProcessing=!0,l.process(i),a.process(i),u.process(i),c.process(i),d.process(i),h.process(i),i.isProcessing=!1,n&&t&&(r=!1,e(f))},p=()=>{n=!0,r=!0,i.isProcessing||e(f)};return{schedule:Y.reduce((e,t)=>{let r=o[t];return e[t]=(e,t=!1,i=!1)=>(n||p(),r.schedule(e,t,i)),e},{}),cancel:e=>{for(let t=0;t<Y.length;t++)o[Y[t]].cancel(e)},state:i,steps:o}}let{schedule:J,cancel:Z,state:X,steps:Q}=q("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:V,!0);function ee(){r=void 0}let et={now:()=>(void 0===r&&et.set(X.isProcessing||G.useManualTiming?X.timestamp:performance.now()),r),set:e=>{r=e,queueMicrotask(ee)}};function en(e,t){-1===e.indexOf(t)&&e.push(t)}function er(e,t){let n=e.indexOf(t);n>-1&&e.splice(n,1)}class ei{constructor(){this.subscriptions=[]}add(e){return en(this.subscriptions,e),()=>er(this.subscriptions,e)}notify(e,t,n){let r=this.subscriptions.length;if(r){if(1===r)this.subscriptions[0](e,t,n);else for(let i=0;i<r;i++){let r=this.subscriptions[i];r&&r(e,t,n)}}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}let es=e=>!isNaN(parseFloat(e)),eo={current:void 0};class el{constructor(e,t={}){this.version="11.18.2",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(e,t=!0)=>{let n=et.now();this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(e),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),t&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(e),this.owner=t.owner}setCurrent(e){this.current=e,this.updatedAt=et.now(),null===this.canTrackVelocity&&void 0!==e&&(this.canTrackVelocity=es(this.current))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return this.on("change",e)}on(e,t){this.events[e]||(this.events[e]=new ei);let n=this.events[e].add(t);return"change"===e?()=>{n(),J.read(()=>{this.events.change.getSize()||this.stop()})}:n}clearListeners(){for(let e in this.events)this.events[e].clear()}attach(e,t){this.passiveEffect=e,this.stopPassiveEffect=t}set(e,t=!0){t&&this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e,t)}
1setWithVelocity(e,t,n){this.set(t),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-n}jump(e,t=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,t&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return eo.current&&eo.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){var e;let t=et.now();if(!this.canTrackVelocity||void 0===this.prevFrameValue||t-this.updatedAt>30)return 0;let n=Math.min(this.updatedAt-this.prevUpdatedAt,30);return e=parseFloat(this.current)-parseFloat(this.prevFrameValue),n?1e3/n*e:0}start(e){return this.stop(),new Promise(t=>{this.hasAnimated=!0,this.animation=e(t),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function ea(e,t){return new el(e,t)}let eu=e=>!!(e&&e.getVelocity);function ec(e,t){let n=e.getValue("willChange");if(eu(n)&&n.add)return n.add(t)}let ed=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),eh="data-"+ed("framerAppearId"),ef={current:!1},ep=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e;function eg(e,t,n,r){if(e===t&&n===r)return V;let i=t=>(function(e,t,n,r,i){let s,o;let l=0;do(s=ep(o=t+(n-t)/2,r,i)-e)>0?n=o:t=o;while(Math.abs(s)>1e-7&&++l<12);return o})(t,0,1,e,n);return e=>0===e||1===e?e:ep(i(e),t,r)}let em=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,ey=e=>t=>1-e(1-t),ev=eg(.33,1.53,.69,.99),e_=ey(ev),eb=em(e_),ex=e=>(e*=2)<1?.5*e_(e):.5*(2-Math.pow(2,-10*(e-1))),eS=e=>1-Math.sin(Math.acos(e)),ew=ey(eS),eE=em(eS),eT=e=>/^0[^.\s]+$/u.test(e),eC=(e,t,n)=>n>t?t:n<e?e:n,ek={test:e=>"number"==typeof e,parse:parseFloat,transform:e=>e},eA={...ek,transform:e=>eC(0,1,e)},eP={...ek,default:1},eN=e=>Math.round(1e5*e)/1e5,eF=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu,eO=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,eD=(e,t)=>n=>!!("string"==typeof n&&eO.test(n)&&n.startsWith(e)||t&&null!=n&&Object.prototype.hasOwnProperty.call(n,t)),eL=(e,t,n)=>r=>{if("string"!=typeof r)return r;let[i,s,o,l]=r.match(eF);return{[e]:parseFloat(i),[t]:parseFloat(s),[n]:parseFloat(o),alpha:void 0!==l?parseFloat(l):1}},eI=e=>eC(0,255,e),eM={...ek,transform:e=>Math.round(eI(e))},eR={test:eD("rgb","red"),parse:eL("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+eM.transform(e)+", "+eM.transform(t)+", "+eM.transform(n)+", "+eN(eA.transform(r))+")"},eB={test:eD("#"),parse:function(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}},transform:eR.transform},ej=e=>({test:t=>"string"==typeof t&&t.endsWith(e)&&1===t.split(" ").length,parse:parseFloat,transform:t=>`${t}${e}`}),eU=ej("deg"),eV=ej("%"),ez=ej("px"),e$=ej("vh"),eW=ej("vw"),eK={...eV,parse:e=>eV.parse(e)/100,transform:e=>eV.transform(100*e)},eH={test:eD("hsl","hue"),parse:eL("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+eV.transform(eN(t))+", "+eV.transform(eN(n))+", "+eN(eA.transform(r))+")"},eG={test:e=>eR.test(e)||eB.test(e)||eH.test(e),parse:e=>eR.test(e)?eR.parse(e):eH.test(e)?eH.parse(e):eB.parse(e),transform:e=>"string"==typeof e?e:e.hasOwnProperty("red")?eR.transform(e):eH.transform(e)},eY=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu,eq="number",eJ="color",eZ=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function eX(e){let t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[],s=0,o=t.replace(eZ,e=>(eG.test(e)?(r.color.push(s),i.push(eJ),n.push(eG.parse(e))):e.startsWith("var(")?(r.var.push(s),i.push("var"),n.push(e)):(r.number.push(s),i.push(eq),n.push(parseFloat(e))),++s,"${}")).split("${}");return{values:n,split:o,indexes:r,types:i}}function eQ(e){return eX(e).values}function e0(e){let{split:t,types:n}=eX(e),r=t.length;return e=>{let i="";for(let s=0;s<r;s++)if(i+=t[s],void 0!==e[s]){let t=n[s];t===eq?i+=eN(e[s]):t===eJ?i+=eG.transform(e[s]):i+=e[s]}return i}}let e1=e=>"number"==typeof e?0:e,e2={test:function(e){var t,n;return isNaN(e)&&"string"==typeof e&&((null===(t=e.match(eF))||void 0===t?void 0:t.length)||0)+((null===(n=e.match(eY))||void 0===n?void 0:n.length)||0)>0},parse:eQ,createTransformer:e0,getAnimatableNone:function(e){let t=eQ(e);return e0(e)(t.map(e1))}},e3=new Set(["brightness","contrast","saturate","opacity"]);function e8(e){let[t,n]=e.slice(0,-1).split("(");if("drop-shadow"===t)return e;let[r]=n.match(eF)||[];
1if(!r)return e;let i=n.replace(r,""),s=e3.has(t)?1:0;return r!==n&&(s*=100),t+"("+s+i+")"}let e5=/\b([a-z-]*)\(.*?\)/gu,e7={...e2,getAnimatableNone:e=>{let t=e.match(e5);return t?t.map(e8).join(" "):e}},e4={...ek,transform:Math.round},e9={borderWidth:ez,borderTopWidth:ez,borderRightWidth:ez,borderBottomWidth:ez,borderLeftWidth:ez,borderRadius:ez,radius:ez,borderTopLeftRadius:ez,borderTopRightRadius:ez,borderBottomRightRadius:ez,borderBottomLeftRadius:ez,width:ez,maxWidth:ez,height:ez,maxHeight:ez,top:ez,right:ez,bottom:ez,left:ez,padding:ez,paddingTop:ez,paddingRight:ez,paddingBottom:ez,paddingLeft:ez,margin:ez,marginTop:ez,marginRight:ez,marginBottom:ez,marginLeft:ez,backgroundPositionX:ez,backgroundPositionY:ez,rotate:eU,rotateX:eU,rotateY:eU,rotateZ:eU,scale:eP,scaleX:eP,scaleY:eP,scaleZ:eP,skew:eU,skewX:eU,skewY:eU,distance:ez,translateX:ez,translateY:ez,translateZ:ez,x:ez,y:ez,z:ez,perspective:ez,transformPerspective:ez,opacity:eA,originX:eK,originY:eK,originZ:ez,zIndex:e4,size:ez,fillOpacity:eA,strokeOpacity:eA,numOctaves:e4},e6={...e9,color:eG,backgroundColor:eG,outlineColor:eG,fill:eG,stroke:eG,borderColor:eG,borderTopColor:eG,borderRightColor:eG,borderBottomColor:eG,borderLeftColor:eG,filter:e7,WebkitFilter:e7},te=e=>e6[e];function tt(e,t){let n=te(e);return n!==e7&&(n=e2),n.getAnimatableNone?n.getAnimatableNone(t):void 0}let tn=new Set(["auto","none","0"]),tr=e=>e===ek||e===ez,ti=(e,t)=>parseFloat(e.split(", ")[t]),ts=(e,t)=>(n,{transform:r})=>{if("none"===r||!r)return 0;let i=r.match(/^matrix3d\((.+)\)$/u);if(i)return ti(i[1],t);{let t=r.match(/^matrix\((.+)\)$/u);return t?ti(t[1],e):0}},to=new Set(["x","y","z"]),tl=z.filter(e=>!to.has(e)),ta={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:ts(4,13),y:ts(5,14)};ta.translateX=ta.x,ta.translateY=ta.y;let tu=new Set,tc=!1,td=!1;function th(){if(td){let e=Array.from(tu).filter(e=>e.needsMeasurement),t=new Set(e.map(e=>e.element)),n=new Map;t.forEach(e=>{let t=function(e){let t=[];return tl.forEach(n=>{let r=e.getValue(n);void 0!==r&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}(e);t.length&&(n.set(e,t),e.render())}),e.forEach(e=>e.measureInitialState()),t.forEach(e=>{e.render();let t=n.get(e);t&&t.forEach(([t,n])=>{var r;null===(r=e.getValue(t))||void 0===r||r.set(n)})}),e.forEach(e=>e.measureEndState()),e.forEach(e=>{void 0!==e.suspendedScrollY&&window.scrollTo(0,e.suspendedScrollY)})}td=!1,tc=!1,tu.forEach(e=>e.complete()),tu.clear()}function tf(){tu.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(td=!0)})}class tp{constructor(e,t,n,r,i,s=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...e],this.onComplete=t,this.name=n,this.motionValue=r,this.element=i,this.isAsync=s}scheduleResolve(){this.isScheduled=!0,this.isAsync?(tu.add(this),tc||(tc=!0,J.read(tf),J.resolveKeyframes(th))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:e,name:t,element:n,motionValue:r}=this;for(let i=0;i<e.length;i++)if(null===e[i]){if(0===i){let i=null==r?void 0:r.get(),s=e[e.length-1];if(void 0!==i)e[0]=i;else if(n&&t){let r=n.readValue(t,s);null!=r&&(e[0]=r)}void 0===e[0]&&(e[0]=s),r&&void 0===i&&r.set(e[0])}else e[i]=e[i-1]}}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),tu.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,tu.delete(this))}resume(){this.isComplete||this.scheduleResolve()}}let tg=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),tm=e=>t=>"string"==typeof t&&t.startsWith(e),ty=tm("--"),tv=tm("var(--"),t_=e=>!!tv(e)&&tb.test(e.split("/*")[0].trim()),tb=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,tx=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u,tS=e=>t=>t.test(e),tw=[ek,ez,eV,eU,eW,e$,{test:e=>"auto"===e,parse:e=>e}],tE=e=>tw.find(tS(e));class tT extends tp{constructor(e,t,n,r,i){super(e,t,n,r,i,!0)}readKeyframes(){let{unresolvedKeyframes:e,element:t,name:n}=this;if(!t||!t.current)return;super.readKeyframes();for(let n=0;n<e.length;n++){let r=e[n];if("string"==typeof r&&t_(r=r.trim())){let i=function e(t,n,r=1){V(r<=4,`Max CSS variable fallback depth detected in property "${t}". This may indicate a circular fallback dependency.`);let[i,s]=function(e){let t=tx.exec(e);if(!t)return[,];let[,n,r,i]=t;return[`--${null!=n?n:r}`,i]}(t);if(!i)return;let o=window.getComputedStyle(n).getPropertyValue(i);if(o){let e=o.trim();return tg(e)?parseFloat(e):e}return t_(s)?e(s,n,r+1):s}(r,t.current);void 0!==i&&(e[n]=i),n===e.length-1&&(this.finalKeyframe=r)}}if(this.resolveNoneKeyframes(),!W.has(n)||2!==e.length)return;let[r,i]=e,s=tE(r),o=tE(i);if(s!==o){if(tr(s)&&tr(o))for(let t=0;t<e.length;t++){let n=e[t];"string"==typeof n&&(e[t]=parseFloat(n))}else this.needsMeasurement=!0}}resolveNoneKeyframes(){let{unresolvedKeyframes:e,name:t}=this,n=[];for(let t=0;t<e.length;t++){var r;("number"==typeof(r=e[t])?0===r:null===r||"none"===r||"0"===r||eT(r))&&n.push(t)}n.length&&function(e,t,n){let r,i=0;for(;i<e.length&&!r;){let t=e[i];"string"==typeof t&&!tn.has(t)&&eX(t).values.length&&(r=e[i]),i++}if(r&&n)for(let i of t)e[i]=tt(n,r)}(e,n,t)}measureInitialState(){let{element:e,unresolvedKeyframes:t,name:n}=this;if(!e||!e.current)return;"height"===n&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=ta[n](e.measureViewportBox(),window.getComputedStyle(e.current)),t[0]=this.measuredOrigin;let r=t[t.length-1];void 0!==r&&e.getValue(n,r).jump(r,!1)}measureEndState(){var e;let{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;let i=t.getValue(n);i&&i.jump(this.measuredOrigin,!1);let s=r.length-1,o=r[s];r[s]=ta[n](t.measureViewportBox(),window.getComputedStyle(t.current)),null!==o&&void 0===this.finalKeyframe&&(this.finalKeyframe=o),(null===(e=this.removedTransforms)||void 0===e?void 0:e.length)&&this.removedTransforms.forEac
1h(([e,n])=>{t.getValue(e).set(n)}),this.resolveNoneKeyframes()}}let tC=(e,t)=>"zIndex"!==t&&!!("number"==typeof e||Array.isArray(e)||"string"==typeof e&&(e2.test(e)||"0"===e)&&!e.startsWith("url(")),tk=e=>null!==e;function tA(e,{repeat:t,repeatType:n="loop"},r){let i=e.filter(tk),s=t&&"loop"!==n&&t%2==1?0:i.length-1;return s&&void 0!==r?r:i[s]}class tP{constructor({autoplay:e=!0,delay:t=0,type:n="keyframes",repeat:r=0,repeatDelay:i=0,repeatType:s="loop",...o}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=et.now(),this.options={autoplay:e,delay:t,type:n,repeat:r,repeatDelay:i,repeatType:s,...o},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt&&this.resolvedAt-this.createdAt>40?this.resolvedAt:this.createdAt}get resolved(){return this._resolved||this.hasAttemptedResolve||(tf(),th()),this._resolved}onKeyframesResolved(e,t){this.resolvedAt=et.now(),this.hasAttemptedResolve=!0;let{name:n,type:r,velocity:i,delay:s,onComplete:o,onUpdate:l,isGenerator:a}=this.options;if(!a&&!function(e,t,n,r){let i=e[0];if(null===i)return!1;if("display"===t||"visibility"===t)return!0;let s=e[e.length-1],o=tC(i,t),l=tC(s,t);return V(o===l,`You are trying to animate ${t} from "${i}" to "${s}". ${i} is not an animatable value - to enable this animation set ${i} to a value animatable to ${s} via the \`style\` property.`),!!o&&!!l&&(function(e){let t=e[0];if(1===e.length)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}(e)||("spring"===n||_(n))&&r)}(e,n,r,i)){if(ef.current||!s){l&&l(tA(e,this.options,t)),o&&o(),this.resolveFinishedPromise();return}this.options.duration=0}let u=this.initPlayback(e,t);!1!==u&&(this._resolved={keyframes:e,finalKeyframe:t,...u},this.onPostResolved())}onPostResolved(){}then(e,t){return this.currentFinishedPromise.then(e,t)}flatten(){this.options.type="keyframes",this.options.ease="linear"}updateFinishedPromise(){this.currentFinishedPromise=new Promise(e=>{this.resolveFinishedPromise=e})}}let tN=(e,t,n)=>e+(t-e)*n;function tF(e,t,n){return(n<0&&(n+=1),n>1&&(n-=1),n<1/6)?e+(t-e)*6*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function tO(e,t){return n=>n>0?t:e}let tD=(e,t,n)=>{let r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},tL=[eB,eR,eH],tI=e=>tL.find(t=>t.test(e));function tM(e){let t=tI(e);if(V(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`),!t)return!1;let n=t.parse(e);return t===eH&&(n=function({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,n/=100;let i=0,s=0,o=0;if(t/=100){let r=n<.5?n*(1+t):n+t-n*t,l=2*n-r;i=tF(l,r,e+1/3),s=tF(l,r,e),o=tF(l,r,e-1/3)}else i=s=o=n;return{red:Math.round(255*i),green:Math.round(255*s),blue:Math.round(255*o),alpha:r}}(n)),n}let tR=(e,t)=>{let n=tM(e),r=tM(t);if(!n||!r)return tO(e,t);let i={...n};return e=>(i.red=tD(n.red,r.red,e),i.green=tD(n.green,r.green,e),i.blue=tD(n.blue,r.blue,e),i.alpha=tN(n.alpha,r.alpha,e),eR.transform(i))},tB=(e,t)=>n=>t(e(n)),tj=(...e)=>e.reduce(tB),tU=new Set(["none","hidden"]);function tV(e,t){return n=>tN(e,t,n)}function tz(e){return"number"==typeof e?tV:"string"==typeof e?t_(e)?tO:eG.test(e)?tR:tK:Array.isArray(e)?t$:"object"==typeof e?eG.test(e)?tR:tW:tO}function t$(e,t){let n=[...e],r=n.length,i=e.map((e,n)=>tz(e)(e,t[n]));return e=>{for(let t=0;t<r;t++)n[t]=i[t](e);return n}}function tW(e,t){let n={...e,...t},r={};for(let i in n)void 0!==e[i]&&void 0!==t[i]&&(r[i]=tz(e[i])(e[i],t[i]));return e=>{for(let t in r)n[t]=r[t](e);return n}}let tK=(e,t)=>{let n=e2.createTransformer(t),r=eX(e),i=eX(t);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?tU.has(e)&&!i.values.length||tU.has(t)&&!r.values.length?tU.has(e)?n=>n<=0?e:t:n=>n>=1?t:e:tj(t$(function(e,t){var n;let r=[],i={color:0,var:0,number:0};for(let s=0;s<t.values.length;s++){let o=t.types[s],l=e.indexes[o][i[o]],a=null!==(n=e.values[l])&&void 0!==n?n:0;r[s]=a,i[o]++}return r}(r,i),i.values),n):(V(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`),tO(e,t))};function tH(e,t,n){return"number"==typeof e&&"number"==typeof t&&"number"==typeof n?tN(e,t,n):tz(e)(e,t)}function tG(e,t,n){var r,i;let s=Math.max(t-5,0);return r=n-e(s),(i=t-s)?1e3/i*r:0}let tY={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};function tq(e,t){return e*Math.sqrt(1-t*t)}let tJ=["duration","bounce"],tZ=["stiffness","damping","mass"];function tX(e,t){return t.some(t=>void 0!==e[t])}function tQ(e=tY.visualDuration,t=tY.bounce){let n;let r="object"!=typeof e?{visualDuration:e,keyframes:[0,1],bounce:t}:e,{restSpeed:i,restDelta:s}=r,o=r.keyframes[0],l=r.keyframes[r.keyframes.length-1],a={done:!1,value:o},{stiffness:u,damping:c,mass:d,duration:h,velocity:f,isResolvedFromDuration:p}=function(e){let t={velocity:tY.velocity,stiffness:tY.stiffness,damping:tY.damping,mass:tY.mass,isResolvedFromDuration:!1,...e};if(!tX(e,tZ)&&tX(e,tJ)){if(e.visualDuration){let n=2*Math.PI/(1.2*e.visualDuration),r=n*n,i=2*eC(.05,1,1-(e.bounce||0))*Math.sqrt(r);t={...t,mass:tY.mass,stiffness:r,damping:i}}else{let n=function({duration:e=tY.duration,bounce:t=tY.bounce,velocity:n=tY.velocity,mass:r=tY.mass}){let i,s;V(e<=j(tY.maxDuration),"Spring duration must be 10 seconds or less");let o=1-t;o=eC(tY.minDamping,tY.maxDamping,o),e=eC(tY.minDuration,tY.maxDuration,U(e)),o<1?(i=t=>{let r=t*o,i=r*e;return .001-(r-n)/tq(t,o)*Math.exp(-i)},s=t=>{let r=t*o*e,s=Math.pow(o,2)*Math.pow(t,2)*e,l=tq(Math.pow(t,2),o);return(r*n+n-s)*Math.exp(-r)*(-i(t)+.001>0?-1:1)/l}):(i=t=>-.001+Math.exp(-t*e)*((t-n)*e+1),s=t=>e*e*(n-t)*Math.exp(-t*e));let l=function(e,t,n){let r=n;for(let n=1;n<12;n++)r-=e(r)/t(r);return r}(i,s,5/e);if(e=j(e),isNaN(l))return{stiffness:tY.stiffness,damping:tY.damping,duration:e};{let t=Math.pow(l,2)*r;return{stiffness:t,damping:2*o*Math.sqrt(r*t),duration:e}}}(e);(t={...t,...n,mass:tY.mass}).isResolvedFromDuration=!0}}return t}({...r,velocity:-U(r.velocity||0)}),g=f||0,m=c/(2*Math.sqrt(u*d)),y=l-o,_=U(Math.sqrt(u/d)),b=5>Math.abs(y);if(i||(i=b?tY.restSpeed.granular:tY.restSpeed.default),s||(s=b?tY.restDelta.granular:tY.restDelta.default),m<1){let e=tq(_,m);n=t=>l-Math.exp(-m*_*t)*((g+m*_*y)/e*Math.sin(e*t)+y*Math.cos(e*t))}else if(1===m)n=e=>l-Math.exp(-_*e)*(y+(g+_*y)*e);else{let e=_*Math.sqrt(m*m-1);n=t=>{let n=Math.exp(-m*_*t),r=Math.min(e*t,300);return l-n*((g+m*_*y)*Math.sinh(r)+e*y*Math.cosh(r))/e}}
1let x={calculatedDuration:p&&h||null,next:e=>{let t=n(e);if(p)a.done=e>=h;else{let r=0;m<1&&(r=0===e?j(g):tG(n,e,t));let o=Math.abs(r)<=i,u=Math.abs(l-t)<=s;a.done=o&&u}return a.value=a.done?l:t,a},toString:()=>{let e=Math.min(v(x),2e4),t=T(t=>x.next(e*t).value,e,30);return e+"ms "+t}};return x}function t0({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:s=500,modifyTarget:o,min:l,max:a,restDelta:u=.5,restSpeed:c}){let d,h;let f=e[0],p={done:!1,value:f},g=e=>void 0!==l&&e<l||void 0!==a&&e>a,m=e=>void 0===l?a:void 0===a?l:Math.abs(l-e)<Math.abs(a-e)?l:a,y=n*t,v=f+y,_=void 0===o?v:o(v);_!==v&&(y=_-f);let b=e=>-y*Math.exp(-e/r),x=e=>_+b(e),S=e=>{let t=b(e),n=x(e);p.done=Math.abs(t)<=u,p.value=p.done?_:n},w=e=>{g(p.value)&&(d=e,h=tQ({keyframes:[p.value,m(p.value)],velocity:tG(x,e,p.value),damping:i,stiffness:s,restDelta:u,restSpeed:c}))};return w(0),{calculatedDuration:null,next:e=>{let t=!1;return(h||void 0!==d||(t=!0,S(e),w(e)),void 0!==d&&e>=d)?h.next(e-d):(t||S(e),p)}}}let t1=eg(.42,0,1,1),t2=eg(0,0,.58,1),t3=eg(.42,0,.58,1),t8=e=>Array.isArray(e)&&"number"!=typeof e[0],t5={linear:V,easeIn:t1,easeInOut:t3,easeOut:t2,circIn:eS,circInOut:eE,circOut:ew,backIn:e_,backInOut:eb,backOut:ev,anticipate:ex},t7=e=>{if(x(e)){V(4===e.length,"Cubic bezier arrays must contain four numerical values.");let[t,n,r,i]=e;return eg(t,n,r,i)}return"string"==typeof e?(V(void 0!==t5[e],`Invalid easing type '${e}'`),t5[e]):e};function t4({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){let i=t8(r)?r.map(t7):t7(r),s={done:!1,value:t[0]},o=function(e,t,{clamp:n=!0,ease:r,mixer:i}={}){let s=e.length;if(V(s===t.length,"Both input and output ranges must be the same length"),1===s)return()=>t[0];if(2===s&&t[0]===t[1])return()=>t[1];let o=e[0]===e[1];e[0]>e[s-1]&&(e=[...e].reverse(),t=[...t].reverse());let l=function(e,t,n){let r=[],i=n||tH,s=e.length-1;for(let n=0;n<s;n++){let s=i(e[n],e[n+1]);t&&(s=tj(Array.isArray(t)?t[n]||V:t,s)),r.push(s)}return r}(t,r,i),a=l.length,u=n=>{if(o&&n<e[0])return t[0];let r=0;if(a>1)for(;r<e.length-2&&!(n<e[r+1]);r++);let i=E(e[r],e[r+1],n);return l[r](i)};return n?t=>u(eC(e[0],e[s-1],t)):u}((n&&n.length===t.length?n:function(e){let t=[0];return function(e,t){let n=e[e.length-1];for(let r=1;r<=t;r++){let i=E(0,t,r);e.push(tN(n,1,i))}}(t,e.length-1),t}(t)).map(t=>t*e),t,{ease:Array.isArray(i)?i:t.map(()=>i||t3).splice(0,t.length-1)});return{calculatedDuration:e,next:t=>(s.value=o(t),s.done=t>=e,s)}}let t9=e=>{let t=({timestamp:t})=>e(t);return{start:()=>J.update(t,!0),stop:()=>Z(t),now:()=>X.isProcessing?X.timestamp:et.now()}},t6={decay:t0,inertia:t0,tween:t4,keyframes:t4,spring:tQ},ne=e=>e/100;class nt extends tP{constructor(e){super(e),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.teardown();let{onStop:e}=this.options;e&&e()};let{name:t,motionValue:n,element:r,keyframes:i}=this.options,s=(null==r?void 0:r.KeyframeResolver)||tp;this.resolver=new s(i,(e,t)=>this.onKeyframesResolved(e,t),t,n,r),this.resolver.scheduleResolve()}flatten(){super.flatten(),this._resolved&&Object.assign(this._resolved,this.initPlayback(this._resolved.keyframes))}initPlayback(e){let t,n;let{type:r="keyframes",repeat:i=0,repeatDelay:s=0,repeatType:o,velocity:l=0}=this.options,a=_(r)?r:t6[r]||t4;a!==t4&&"number"!=typeof e[0]&&(t=tj(ne,tH(e[0],e[1])),e=[0,100]);let u=a({...this.options,keyframes:e});"mirror"===o&&(n=a({...this.options,keyframes:[...e].reverse(),velocity:-l})),null===u.calculatedDuration&&(u.calculatedDuration=v(u));let{calculatedDuration:c}=u,d=c+s;return{generator:u,mirroredGenerator:n,mapPercentToKeyframes:t,calculatedDuration:c,resolvedDuration:d,totalDuration:d*(i+1)-s}}onPostResolved(){let{autoplay:e=!0}=this.options;this.play(),"paused"!==this.pendingPlayState&&e?this.state=this.pendingPlayState:this.pause()}tick(e,t=!1){let{resolved:n}=this;if(!n){let{keyframes:e}=this.options;return{done:!0,value:e[e.length-1]}}let{finalKeyframe:r,generator:i,mirroredGenerator:s,mapPercentToKeyframes:o,keyframes:l,calculatedDuration:a,totalDuration:u,resolvedDuration:c}=n;if(null===this.startTime)return i.next(0);let{delay:d,repeat:h,repeatType:f,repeatDelay:p,onUpdate:g}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-u/this.speed,this.startTime)),t?this.currentTime=e:null!==this.holdTime?this.currentTime=this.holdTime:this.currentTime=Math.round(e-this.startTime)*this.speed;let m=this.currentTime-d*(this.speed>=0?1:-1),y=this.speed>=0?m<0:m>u;this.currentTime=Math.max(m,0),"finished"===this.state&&null===this.holdTime&&(this.currentTime=u);let v=this.currentTime,_=i;if(h){let e=Math.min(this.currentTime,u)/c,t=Math.floor(e),n=e%1;!n&&e>=1&&(n=1),1===n&&t--,(t=Math.min(t,h+1))%2&&("reverse"===f?(n=1-n,p&&(n-=p/c)):"mirror"===f&&(_=s)),v=eC(0,1,n)*c}let b=y?{done:!1,value:l[0]}:_.next(v);o&&(b.value=o(b.value));let{done:x}=b;y||null===a||(x=this.speed>=0?this.currentTime>=u:this.currentTime<=0);let S=null===this.holdTime&&("finished"===this.state||"running"===this.state&&x);return S&&void 0!==r&&(b.value=tA(l,this.options,r)),g&&g(b.value),S&&this.finish(),b}get duration(){let{resolved:e}=this;return e?U(e.calculatedDuration):0}
1get time(){return U(this.currentTime)}set time(e){e=j(e),this.currentTime=e,null!==this.holdTime||0===this.speed?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.speed)}get speed(){return this.playbackSpeed}set speed(e){let t=this.playbackSpeed!==e;this.playbackSpeed=e,t&&(this.time=U(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;let{driver:e=t9,onPlay:t,startTime:n}=this.options;this.driver||(this.driver=e(e=>this.tick(e))),t&&t();let r=this.driver.now();null!==this.holdTime?this.startTime=r-this.holdTime:this.startTime?"finished"===this.state&&(this.startTime=r):this.startTime=null!=n?n:this.calcStartTime(),"finished"===this.state&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var e;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=null!==(e=this.currentTime)&&void 0!==e?e:0}complete(){"running"!==this.state&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";let{onComplete:e}=this.options;e&&e()}cancel(){null!==this.cancelTime&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}}let nn=new Set(["opacity","clipPath","filter","transform"]),nr=f(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),ni={anticipate:ex,backInOut:eb,circInOut:eE};class ns extends tP{constructor(e){super(e);let{name:t,motionValue:n,element:r,keyframes:i}=this.options;this.resolver=new tT(i,(e,t)=>this.onKeyframesResolved(e,t),t,n,r),this.resolver.scheduleResolve()}initPlayback(e,t){var n;let{duration:r=300,times:i,ease:s,type:o,motionValue:l,name:a,startTime:u}=this.options;if(!l.owner||!l.owner.current)return!1;if("string"==typeof s&&w()&&s in ni&&(s=ni[s]),_((n=this.options).type)||"spring"===n.type||!function e(t){return!!("function"==typeof t&&w()||!t||"string"==typeof t&&(t in k||w())||x(t)||Array.isArray(t)&&t.every(e))}(n.ease)){let{onComplete:t,onUpdate:n,motionValue:l,element:a,...u}=this.options,c=function(e,t){let n=new nt({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0}),r={done:!1,value:e[0]},i=[],s=0;for(;!r.done&&s<2e4;)i.push((r=n.sample(s)).value),s+=10;return{times:void 0,keyframes:i,duration:s-10,ease:"linear"}}(e,u);1===(e=c.keyframes).length&&(e[1]=e[0]),r=c.duration,i=c.times,s=c.ease,o="keyframes"}let c=function(e,t,n,{delay:r=0,duration:i=300,repeat:s=0,repeatType:o="loop",ease:l="easeInOut",times:a}={}){let u={[t]:n};a&&(u.offset=a);let c=function e(t,n){if(t)return"function"==typeof t&&w()?T(t,n):x(t)?C(t):Array.isArray(t)?t.map(t=>e(t,n)||k.easeOut):k[t]}(l,i);return Array.isArray(c)&&(u.easing=c),e.animate(u,{delay:r,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:s+1,direction:"reverse"===o?"alternate":"normal"})}(l.owner.current,a,e,{...this.options,duration:r,times:i,ease:s});return c.startTime=null!=u?u:this.calcStartTime(),this.pendingTimeline?(b(c,this.pendingTimeline),this.pendingTimeline=void 0):c.onfinish=()=>{let{onComplete:n}=this.options;l.set(tA(e,this.options,t)),n&&n(),this.cancel(),this.resolveFinishedPromise()},{animation:c,duration:r,times:i,type:o,ease:s,keyframes:e}}get duration(){let{resolved:e}=this;if(!e)return 0;let{duration:t}=e;return U(t)}get time(){let{resolved:e}=this;if(!e)return 0;let{animation:t}=e;return U(t.currentTime||0)}set time(e){let{resolved:t}=this;if(!t)return;let{animation:n}=t;n.currentTime=j(e)}get speed(){let{resolved:e}=this;if(!e)return 1;let{animation:t}=e;return t.playbackRate}set speed(e){let{resolved:t}=this;if(!t)return;let{animation:n}=t;n.playbackRate=e}get state(){let{resolved:e}=this;if(!e)return"idle";let{animation:t}=e;return t.playState}get startTime(){let{resolved:e}=this;if(!e)return null;let{animation:t}=e;return t.startTime}attachTimeline(e){if(this._resolved){let{resolved:t}=this;if(!t)return V;let{animation:n}=t;b(n,e)}else this.pendingTimeline=e;return V}play(){if(this.isStopped)return;let{resolved:e}=this;if(!e)return;let{animation:t}=e;
1"finished"===t.playState&&this.updateFinishedPromise(),t.play()}pause(){let{resolved:e}=this;if(!e)return;let{animation:t}=e;t.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.resolveFinishedPromise(),this.updateFinishedPromise();let{resolved:e}=this;if(!e)return;let{animation:t,keyframes:n,duration:r,type:i,ease:s,times:o}=e;if("idle"===t.playState||"finished"===t.playState)return;if(this.time){let{motionValue:e,onUpdate:t,onComplete:l,element:a,...u}=this.options,c=new nt({...u,keyframes:n,duration:r,type:i,ease:s,times:o,isGenerator:!0}),d=j(this.time);e.setWithVelocity(c.sample(d-10).value,c.sample(d).value,10)}let{onStop:l}=this.options;l&&l(),this.cancel()}complete(){let{resolved:e}=this;e&&e.animation.finish()}cancel(){let{resolved:e}=this;e&&e.animation.cancel()}static supports(e){let{motionValue:t,name:n,repeatDelay:r,repeatType:i,damping:s,type:o}=e;if(!t||!t.owner||!(t.owner.current instanceof HTMLElement))return!1;let{onUpdate:l,transformTemplate:a}=t.owner.getProps();return nr()&&n&&nn.has(n)&&!l&&!a&&!r&&"mirror"!==i&&0!==s&&"inertia"!==o}}let no={type:"spring",stiffness:500,damping:25,restSpeed:10},nl=e=>({type:"spring",stiffness:550,damping:0===e?2*Math.sqrt(550):30,restSpeed:10}),na={type:"keyframes",duration:.8},nu={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},nc=(e,{keyframes:t})=>t.length>2?na:$.has(e)?e.startsWith("scale")?nl(t[1]):no:nu,nd=(e,t,n,r={},i,s)=>o=>{let l=y(r,e)||{},a=l.delay||r.delay||0,{elapsed:u=0}=r;u-=j(a);let c={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...l,delay:-u,onUpdate:e=>{t.set(e),l.onUpdate&&l.onUpdate(e)},onComplete:()=>{o(),l.onComplete&&l.onComplete()},name:e,motionValue:t,element:s?void 0:i};!function({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:s,repeatType:o,repeatDelay:l,from:a,elapsed:u,...c}){return!!Object.keys(c).length}(l)&&(c={...c,...nc(e,c)}),c.duration&&(c.duration=j(c.duration)),c.repeatDelay&&(c.repeatDelay=j(c.repeatDelay)),void 0!==c.from&&(c.keyframes[0]=c.from);let d=!1;if(!1!==c.type&&(0!==c.duration||c.repeatDelay)||(c.duration=0,0!==c.delay||(d=!0)),(ef.current||G.skipAnimations)&&(d=!0,c.duration=0,c.delay=0),d&&!s&&void 0!==t.get()){let e=tA(c.keyframes,l);if(void 0!==e)return J.update(()=>{c.onUpdate(e),c.onComplete()}),new m([])}return!s&&ns.supports(c)?new ns(c):new nt(c)};function nh(e,t,{delay:n=0,transitionOverride:r,type:i}={}){var s;let{transition:o=e.getDefaultTransition(),transitionEnd:l,...a}=t;r&&(o=r);let u=[],d=i&&e.animationState&&e.animationState.getState()[i];for(let t in a){let r=e.getValue(t,null!==(s=e.latestValues[t])&&void 0!==s?s:null),i=a[t];if(void 0===i||d&&function({protectedKeys:e,needsAnimating:t},n){let r=e.hasOwnProperty(n)&&!0!==t[n];return t[n]=!1,r}(d,t))continue;let l={delay:n,...y(o||{},t)},c=!1;if(window.MotionHandoffAnimation){let n=e.props[eh];if(n){let e=window.MotionHandoffAnimation(n,t,J);null!==e&&(l.startTime=e,c=!0)}}ec(e,t),r.start(nd(t,r,i,e.shouldReduceMotion&&W.has(t)?{type:!1}:l,e,c));let h=r.animation;h&&u.push(h)}return l&&Promise.all(u).then(()=>{J.update(()=>{l&&function(e,t){let{transitionEnd:n={},transition:r={},...i}=c(e,t)||{};for(let t in i={...i,...n}){let n=H(i[t]);e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,ea(n))}}(e,l)})}),u}function nf(e,t,n={}){var r;let i=c(e,t,"exit"===n.type?null===(r=e.presenceContext)||void 0===r?void 0:r.custom:void 0),{transition:s=e.getDefaultTransition()||{}}=i||{};n.transitionOverride&&(s=n.transitionOverride);let o=i?()=>Promise.all(nh(e,i,n)):()=>Promise.resolve(),l=e.variantChildren&&e.variantChildren.size?(r=0)=>{let{delayChildren:i=0,staggerChildren:o,staggerDirection:l}=s;return function(e,t,n=0,r=0,i=1,s){let o=[],l=(e.variantChildren.size-1)*r,a=1===i?(e=0)=>e*r:(e=0)=>l-e*r;return Array.from(e.variantChildren).sort(np).forEach((e,r)=>{e.notify("AnimationStart",t),o.push(nf(e,t,{...s,delay:n+a(r)}).then(()=>e.notify("AnimationComplete",t)))}),Promise.all(o)}(e,t,i+r,o,l,n)}:()=>Promise.resolve(),{when:a}=s;if(!a)return Promise.all([o(),l(n.delay)]);{let[e,t]="beforeChildren"===a?[o,l]:[l,o];return e().then(()=>t())}}function np(e,t){return e.sortNodePosition(t)}let ng=h.length,nm=[...d].reverse(),ny=d.length;function nv(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function n_(){return{animate:nv(!0),whileInView:nv(),whileHover:nv(),whileTap:nv(),whileDrag:nv(),whileFocus:nv(),exit:nv()}}class nb{constructor(e){this.isMounted=!1,this.node=e}update(){}}class nx extends nb{constructor(e){super(e),e.animationState||(e.animationState=function(e){let t=t=>Promise.all(t.map(({animation:t,options:n})=>(function(e,t,n={}){let r;if(e.notify("AnimationStart",t),Array.isArray(t))r=Promise.all(t.map(t=>nf(e,t,n)));else if("string"==typeof t)r=nf(e,t,n);else{let i="function"==typeof t?c(e,t,n.custom):t;r=Promise.all(nh(e,i,n))}return r.then(()=>
1{e.notify("AnimationComplete",t)})})(e,t,n))),n=n_(),r=!0,a=t=>(n,r)=>{var i;let s=c(e,r,"exit"===t?null===(i=e.presenceContext)||void 0===i?void 0:i.custom:void 0);if(s){let{transition:e,transitionEnd:t,...r}=s;n={...n,...r,...t}}return n};function u(u){let{props:c}=e,d=function e(t){if(!t)return;if(!t.isControllingVariants){let n=t.parent&&e(t.parent)||{};return void 0!==t.props.initial&&(n.initial=t.props.initial),n}let n={};for(let e=0;e<ng;e++){let r=h[e],i=t.props[r];(l(i)||!1===i)&&(n[r]=i)}return n}(e.parent)||{},f=[],p=new Set,g={},m=1/0;for(let t=0;t<ny;t++){var y;let h=nm[t],v=n[h],_=void 0!==c[h]?c[h]:d[h],b=l(_),x=h===u?v.isActive:null;!1===x&&(m=t);let S=_===d[h]&&_!==c[h]&&b;if(S&&r&&e.manuallyAnimateOnMount&&(S=!1),v.protectedKeys={...g},!v.isActive&&null===x||!_&&!v.prevProp||i(_)||"boolean"==typeof _)continue;let w=(y=v.prevProp,"string"==typeof _?_!==y:!!Array.isArray(_)&&!o(_,y)),E=w||h===u&&v.isActive&&!S&&b||t>m&&b,T=!1,C=Array.isArray(_)?_:[_],k=C.reduce(a(h),{});!1===x&&(k={});let{prevResolvedValues:A={}}=v,P={...A,...k},N=t=>{E=!0,p.has(t)&&(T=!0,p.delete(t)),v.needsAnimating[t]=!0;let n=e.getValue(t);n&&(n.liveStyle=!1)};for(let e in P){let t=k[e],n=A[e];if(!g.hasOwnProperty(e))(s(t)&&s(n)?o(t,n):t===n)?void 0!==t&&p.has(e)?N(e):v.protectedKeys[e]=!0:null!=t?N(e):p.add(e)}v.prevProp=_,v.prevResolvedValues=k,v.isActive&&(g={...g,...k}),r&&e.blockInitialAnimation&&(E=!1);let F=!(S&&w)||T;E&&F&&f.push(...C.map(e=>({animation:e,options:{type:h}})))}if(p.size){let t={};p.forEach(n=>{let r=e.getBaseTarget(n),i=e.getValue(n);i&&(i.liveStyle=!0),t[n]=null!=r?r:null}),f.push({animation:t})}let v=!!f.length;return r&&(!1===c.initial||c.initial===c.animate)&&!e.manuallyAnimateOnMount&&(v=!1),r=!1,v?t(f):Prom
1ise.resolve()}return{animateChanges:u,setActive:function(t,r){var i;if(n[t].isActive===r)return Promise.resolve();null===(i=e.variantChildren)||void 0===i||i.forEach(e=>{var n;return null===(n=e.animationState)||void 0===n?void 0:n.setActive(t,r)}),n[t].isActive=r;let s=u(t);for(let e in n)n[e].protectedKeys={};return s},setAnimateFunction:function(n){t=n(e)},getState:()=>n,reset:()=>{n=n_(),r=!0}}}(e))}updateAnimationControlsSubscription(){let{animate:e}=this.node.getProps();i(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){let{animate:e}=this.node.getProps(),{animate:t}=this.node.prevProps||{};e!==t&&this.updateAnimationControlsSubscription()}unmount(){var e;this.node.animationState.reset(),null===(e=this.unmountControls)||void 0===e||e.call(this)}}let nS=0;class nw extends nb{constructor(){super(...arguments),this.id=nS++}update(){if(!this.node.presenceContext)return;let{isPresent:e,onExitComplete:t}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===n)return;let r=this.node.animationState.setActive("exit",!e);t&&!e&&r.then(()=>t(this.id))}mount(){let{register:e}=this.node.presenceContext||{};e&&(this.unmount=e(this.id))}unmount(){}}function nE(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function nT(e){return{point:{x:e.pageX,y:e.pageY}}}let nC=e=>t=>O(t)&&e(t,nT(t));function nk(e,t,n,r){return nE(e,t,nC(n),r)}let nA=(e,t)=>Math.abs(e-t);class nP{constructor(e,t,{transformPagePoint:n,contextWindow:r,dragSnapToOrigin:i=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{var e,t;if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let n=nO(this.lastMoveEventInfo,this.history),r=null!==this.startEvent,i=(e=n.offset,t={x:0,y:0},Math.sqrt(nA(e.x,t.x)**2+nA(e.y,t.y)**2)>=3);if(!r&&!i)return;let{point:s}=n,{timestamp:o}=X;this.history.push({...s,timestamp:o});let{onStart:l,onMove:a}=this.handlers;r||(l&&l(this.lastMoveEvent,n),this.startEvent=this.lastMoveEvent),a&&a(this.lastMoveEvent,n)},this.handlePointerMove=(e,t)=>{this.lastMoveEvent=e,this.lastMoveEventInfo=nN(t,this.transformPagePoint),J.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{this.end();let{onEnd:n,onSessionEnd:r,resumeAnimation:i}=this.handlers;if(this.dragSnapToOrigin&&i&&i(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let s=nO("pointercancel"===e.type?this.lastMoveEventInfo:nN(t,this.transformPagePoint),this.history);this.startEvent&&n&&n(e,s),r&&r(e,s)},!O(e))return;this.dragSnapToOrigin=i,this.handlers=t,this.transformPagePoint=n,this.contextWindow=r||window;let s=nN(nT(e),this.transformPagePoint),{point:o}=s,{timestamp:l}=X;this.history=[{...o,timestamp:l}];let{onSessionStart:a}=t;a&&a(e,nO(s,this.history)),this.removeListeners=tj(nk(this.contextWindow,"pointermove",this.handlePointerMove),nk(this.contextWindow,"pointerup",this.handlePointerUp),nk(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),Z(this.updatePoint)}}function nN(e,t){return t?{point:t(e.point)}:e}function nF(e,t){return{x:e.x-t.x,y:e.y-t.y}}function nO({point:e},t){return{point:e,delta:nF(e,nD(t)),offset:nF(e,t[0]),velocity:function(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null,i=nD(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>j(.1)));)n--;if(!r)return{x:0,y:0};let s=U(i.timestamp-r.timestamp);if(0===s)return{x:0,y:0};let o={x:(i.x-r.x)/s,y:(i.y-r.y)/s};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}(t,0)}}function nD(e){return e[e.length-1]}function nL(e){return e&&"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"current")}function nI(e){return e.max-e.min}function nM(e,t,n,r=.5){e.origin=r,e.originPoint=tN(t.min,t.max,e.origin),e.scale=nI(n)/nI(t),e.translate=tN(n.min,n.max,e.origin)-e.originPoint,(e.scale>=.9999&&e.scale<=1.0001||isNaN(e.scale))&&(e.scale=1),(e.translate>=-.01&&e.translate<=.01||isNaN(e.translate))&&(e.translate=0)}function nR(e,t,n,r){nM(e.x,t.x,n.x,r?r.originX:void 0),nM(e.y,t.y,n.y,r?r.originY:void 0)}function nB(e,t,n){e.min=n.min+t.min,e.max=e.min+nI(t)}function nj(e,t,n){e.min=t.min-n.min,e.max=e.min+nI(t)}function nU(e,t,n){nj(e.x,t.x,n.x),nj(e.y,t.y,n.y)}function nV(e,t,n){return{min:void 0!==t?e.min+t:void 0,max:void 0!==n?e.max+n-(e.max-e.min):void 0}}function nz(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function n$(e,t,n){return{min:nW(e,t),max:nW(e,n)}}function nW(e,t){return"number"==typeof e?e:e[t]||0}let nK=()=>({translate:0,scale:1,origin:0,originPoint:0}),nH=()=>({x:nK(),y:nK()}),nG=()=>({min:0,max:0}),nY=()=>({x:nG(),y:nG()});function nq(e){return[e("x"),e("y")]}
1function nJ({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function nZ(e){return void 0===e||1===e}function nX({scale:e,scaleX:t,scaleY:n}){return!nZ(e)||!nZ(t)||!nZ(n)}function nQ(e){return nX(e)||n0(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function n0(e){var t,n;return(t=e.x)&&"0%"!==t||(n=e.y)&&"0%"!==n}function n1(e,t,n,r,i){return void 0!==i&&(e=r+i*(e-r)),r+n*(e-r)+t}function n2(e,t=0,n=1,r,i){e.min=n1(e.min,t,n,r,i),e.max=n1(e.max,t,n,r,i)}function n3(e,{x:t,y:n}){n2(e.x,t.translate,t.scale,t.originPoint),n2(e.y,n.translate,n.scale,n.originPoint)}function n8(e,t){e.min=e.min+t,e.max=e.max+t}function n5(e,t,n,r,i=.5){let s=tN(e.min,e.max,i);n2(e,t,n,s,r)}function n7(e,t){n5(e.x,t.x,t.scaleX,t.scale,t.originX),n5(e.y,t.y,t.scaleY,t.scale,t.originY)}function n4(e,t){return nJ(function(e,t){if(!t)return e;let n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}(e.getBoundingClientRect(),t))}let n9=({current:e})=>e?e.ownerDocument.defaultView:null,n6=new WeakMap;class re{constructor(e){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=nY(),this.visualElement=e}start(e,{snapToCursor:t=!1}={}){let{presenceContext:n}=this.visualElement;if(n&&!1===n.isPresent)return;let{dragSnapToOrigin:r}=this.getProps();this.panSession=new nP(e,{onSessionStart:e=>{let{dragSnapToOrigin:n}=this.getProps();n?this.pauseAnimation():this.stopAnimation(),t&&this.snapToCursor(nT(e).point)},onStart:(e,t)=>{let{drag:n,dragPropagation:r,onDragStart:i}=this.getProps();if(n&&!r&&(this.openDragLock&&this.openDragLock(),this.openDragLock="x"===n||"y"===n?A[n]?null:(A[n]=!0,()=>{A[n]=!1}):A.x||A.y?null:(A.x=A.y=!0,()=>{A.x=A.y=!1}),!this.openDragLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),nq(e=>{let t=this.getAxisMotionValue(e).get()||0;if(eV.test(t)){let{projection:n}=this.visualElement;if(n&&n.layout){let r=n.layout.layoutBox[e];if(r){let e=nI(r);t=parseFloat(t)/100*e}}}this.originPoint[e]=t}),i&&J.postRender(()=>i(e,t)),ec(this.visualElement,"transform");let{animationState:s}=this.visualElement;s&&s.setActive("whileDrag",!0)},onMove:(e,t)=>{let{dragPropagation:n,dragDirectionLock:r,onDirectionLock:i,onDrag:s}=this.getProps();if(!n&&!this.openDragLock)return;let{offset:o}=t;if(r&&null===this.currentDirection){this.currentDirection=function(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}(o),null!==this.currentDirection&&i&&i(this.currentDirection);return}this.updateAxis("x",t.point,o),this.updateAxis("y",t.point,o),this.visualElement.render(),s&&s(e,t)},onSessionEnd:(e,t)=>this.stop(e,t),resumeAnimation:()=>nq(e=>{var t;return"paused"===this.getAnimationState(e)&&(null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.play())})},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:r,contextWindow:n9(this.visualElement)})}stop(e,t){let n=this.isDragging;if(this.cancel(),!n)return;let{velocity:r}=t;this.startAnimation(r);let{onDragEnd:i}=this.getProps();i&&J.postRender(()=>i(e,t))}cancel(){this.isDragging=!1;let{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;let{dragPropagation:n}=this.getProps();!n&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),t&&t.setActive("whileDrag",!1)}updateAxis(e,t,n){let{drag:r}=this.getProps();if(!n||!rt(e,r,this.currentDirection))return;let i=this.getAxisMotionValue(e),s=this.originPoint[e]+n[e];this.constraints&&this.constraints[e]&&(s=function(e,{min:t,max:n},r){return void 0!==t&&e<t?e=r?tN(t,e,r.min):Math.max(e,t):void 0!==n&&e>n&&(e=r?tN(n,e,r.max):Math.min(e,n)),e}(s,this.constraints[e],this.elastic[e])),i.set(s)}resolveConstraints(){var e;let{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):null===(e=this.visualElement.projection)||void 0===e?void 0:e.layout,i=this.constraints;t&&nL(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=function(e,{top:t,left:n,bottom:r,right:i}){return{x:nV(e.x,n,i),y:nV(e.y,t,r)}}(r.layoutBox,t):this.constraints=!1,this.elastic=function(e=.35){return!1===e?e=0:!0===e&&(e=.35),{x:n$(e,"left","right"),y:n$(e,"top","bottom")}}(n),i!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&nq(e=>{!1!==this.constraints&&this.getAxisMotionValue(e)&&(this.constraints[e]=function(e,t){let n={};return void 0!==t.min&&(n.min=t.min-e.min),void 0!==t.max&&(n.max=t.max-e.min),n}(r.layoutBox[e],this.constraints[e]))})}resolveRefConstraints(){var e;let{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!nL(t))return!1;let r=t.current;V(null!==r,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");let{projection:i}=this.visualElement;if(!i||!i.layout)return!1;let s=function(e,t,n){let r=n4(e,n),{scroll:i}=t;return i&&(n8(r.x,i.offset.x),n8(r.y,i.offset.y)),r}(r,i.root,this.visualElement.getTransformPagePoint()),o={x:nz((e=i.layout.layoutBox).x,s.x),y:nz(e.y,s.y)};if(n){let e=n(function({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}(o));this.hasMutatedConstraints=!!e,e&&(o=nJ(e))}return o}startAnimation(e){let{drag:t,dragMomentum:n,dragElastic:r,dragTransition:i,dragSnapToOrigin:s,onDragTransitionEnd:o}=this.getProps(),l=this.constraints||{};return Promise.all(nq(o=>{if(!rt(o,t,this.currentDirection))return;let a=l&&l[o]||{};s&&(a={min:0,max:0});let u={type:"inertia",velocity:n?e[o]:0,bounceStiffness:r?200:1e6,bounceDamping:r?40:1e7,timeConstant:750,restDelta:1,restSpeed:10,...i,...a};return this.startAxisValueAnimation(o,u)})).then(o)}startAxisValueAnimation(e,t){let n=this.getAxisMotionValue(e);return ec(this.visualElement,e),n.start(nd(e,n,0,t,this.visualElement,!1))}stopAnimation(){nq(e=>this.getAxisMotionValue(e).stop())}pauseAnimation(){nq(e=>{var t;return null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.pause()})}getAnimationState(e){var t;return null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.state}getAxisMotionValue(e){let t=`_drag${e.toUpperCase()}`,n=this.visualElement.getProps();return n[t]||this.visualElement.getValue(e,(n.initial?n.initial[e]:void 0)||0)}snapToCursor(e){nq(t=>{let{drag:n}=this.getProps();if(!rt(t,n,this.currentDirection))return;let{projection:r}=this.visualElement,i=this.getAxisMotionValue(t);if(r&&r.layout){let{min:n,max:s}=r.layout.layoutBox[t];i.set(e[t]-tN(n,s,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!nL(t)||!n||!this.constraints)return;this.stopAnimation();let r={x:0,y:0};nq(e=>{let t=this.getAxisMotionValue(e);if(t&&!1!==this.constraints){let n=t.get();r[e]=function(e,t){let n=.5,r=nI(e),i=nI(t);return i>r?n=E(t.min,t.max-r,e.min):r>
1i&&(n=E(e.min,e.max-i,t.min)),eC(0,1,n)}({min:n,max:n},this.constraints[e])}});let{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),nq(t=>{if(!rt(t,e,null))return;let n=this.getAxisMotionValue(t),{min:i,max:s}=this.constraints[t];n.set(tN(i,s,r[t]))})}addListeners(){if(!this.visualElement.current)return;n6.set(this.visualElement,this);let e=nk(this.visualElement.current,"pointerdown",e=>{let{drag:t,dragListener:n=!0}=this.getProps();t&&n&&this.start(e)}),t=()=>{let{dragConstraints:e}=this.getProps();nL(e)&&e.current&&(this.constraints=this.resolveRefConstraints())},{projection:n}=this.visualElement,r=n.addEventListener("measure",t);n&&!n.layout&&(n.root&&n.root.updateScroll(),n.updateLayout()),J.read(t);let i=nE(window,"resize",()=>this.scalePositionWithinConstraints()),s=n.addEventListener("didUpdate",({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(nq(t=>{let n=this.getAxisMotionValue(t);n&&(this.originPoint[t]+=e[t].translate,n.set(n.get()+e[t].translate))}),this.visualElement.render())});return()=>{i(),e(),r(),s&&s()}}getProps(){let e=this.visualElement.getProps(),{drag:t=!1,dragDirectionLock:n=!1,dragPropagation:r=!1,dragConstraints:i=!1,dragElastic:s=.35,dragMomentum:o=!0}=e;return{...e,drag:t,dragDirectionLock:n,dragPropagation:r,dragConstraints:i,dragElastic:s,dragMomentum:o}}}function rt(e,t,n){return(!0===t||t===e)&&(null===n||n===e)}class rn extends nb{constructor(e){super(e),this.removeGroupControls=V,this.removeListeners=V,this.controls=new re(e)}mount(){let{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||V}unmount(){this.removeGroupControls(),this.removeListeners()}}let rr=e=>(t,n)=>{e&&J.postRender(()=>e(t,n))};class ri extends nb{constructor(){super(...arguments),this.removePointerDownListener=V}onPointerDown(e){this.session=new nP(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:n9(this.node)})}createPanHandlers(){let{onPanSessionStart:e,onPanStart:t,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:rr(e),onStart:rr(t),onMove:n,onEnd:(e,t)=>{delete this.session,r&&J.postRender(()=>r(e,t))}}}mount(){this.removePointerDownListener=nk(this.node.current,"pointerdown",e=>this.onPointerDown(e))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}var rs,ro,rl,ra=n(44825),ru=n(71100);let rc=(0,ru.createContext)(null),rd=(0,ru.createContext)({}),rh=(0,ru.createContext)({}),rf={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function rp(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}let rg={correct:(e,t)=>{if(!t.target)return e;if("string"==typeof e){if(!ez.test(e))return e;e=parseFloat(e)}let n=rp(e,t.target.x),r=rp(e,t.target.y);return`${n}% ${r}%`}},rm={},{schedule:ry,cancel:rv}=q(queueMicrotask,!1);class r_ extends ru.Component{componentDidMount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n,layoutId:r}=this.props,{projection:i}=e;Object.assign(rm,rx),i&&(t.group&&t.group.add(i),n&&n.register&&r&&n.register(i),i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove()}),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),rf.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){let{layoutDependency:t,visualElement:n,drag:r,isPresent:i}=this.props,s=n.projection;return s&&(s.isPresent=i,r||e.layoutDependency!==t||void 0===t?s.willUpdate():this.safeToRemove(),e.isPresent===i||(i?s.promote():s.relegate()||J.postRender(()=>{let e=s.getStack();e&&e.members.length||this.safeToRemove()}))),null}componentDidUpdate(){let{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),ry.postRender(()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:r}=e;r&&(r.scheduleCheckAfterUnmount(),t&&t.group&&t.group.remove(r),n&&n.deregister&&n.deregister(r))}safeToRemove(){let{safeToRemove:e}=this.props;e&&e()}render(){return null}}function rb(e){let[t,n]=function(e=!0){let t=(0,ru.useContext)(rc);if(null===t)return[!0,null];let{isPresent:n,onExitComplete:r,register:i}=t,s=(0,ru.useId)();(0,ru.useEffect)(()=>{e&&i(s)},[e]);let o=(0,ru.useCallback)(()=>e&&r&&r(s),[s,r,e]);return!n&&r?[!1,o]:[!0]}(),r=(0,ru.useContext)(rd);return(0,ra.jsx)(r_,{...e,layoutGroup:r,switchLayoutGroup:(0,ru.useContext)(rh),isPresent:t,safeToRemove:n})}let rx={borderRadius:{...rg,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:rg,borderTopRightRadius:rg,borderBottomLeftRadius:rg,borderBottomRightRadius:rg,boxShadow:{correct:(e,{treeScale:t,projectionDelta:n})=>{let r=e2.parse(e);if(r.length>5)return e;let i=e2.createTransformer(e),s="number"!=typeof r[0]?1:0,o=n.x.scale*t.x,l=n.y.scale*t.y;r[0+s]/=o,r[1+s]/=l;let a=tN(o,l,.5);return"number"==typeof r[2+s]&&(r[2+s]/=a),"number"==typeof r[3+s]&&(r[3+s]/=a),i(r)}}},rS=(e,t)=>e.depth-t.depth;class rw{constructor(){this.children=[],this.isDirty=!1}add(e){en(this.children,e),this.isDirty=!0}remove(e){er(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(rS),this.isDirty=!1,this.children.forEac
1h(e)}}function rE(e){let t=eu(e)?e.get():e;return K(t)?t.toValue():t}let rT=["TopLeft","TopRight","BottomLeft","BottomRight"],rC=rT.length,rk=e=>"string"==typeof e?parseFloat(e):e,rA=e=>"number"==typeof e||ez.test(e);function rP(e,t){return void 0!==e[t]?e[t]:e.borderRadius}let rN=rO(0,.5,ew),rF=rO(.5,.95,V);function rO(e,t,n){return r=>r<e?0:r>t?1:n(E(e,t,r))}function rD(e,t){e.min=t.min,e.max=t.max}function rL(e,t){rD(e.x,t.x),rD(e.y,t.y)}function rI(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function rM(e,t,n,r,i){return e-=t,e=r+1/n*(e-r),void 0!==i&&(e=r+1/i*(e-r)),e}function rR(e,t,[n,r,i],s,o){!function(e,t=0,n=1,r=.5,i,s=e,o=e){if(eV.test(t)&&(t=parseFloat(t),t=tN(o.min,o.max,t/100)-o.min),"number"!=typeof t)return;let l=tN(s.min,s.max,r);e===s&&(l-=t),e.min=rM(e.min,t,n,l,i),e.max=rM(e.max,t,n,l,i)}(e,t[n],t[r],t[i],t.scale,s,o)}let rB=["x","scaleX","originX"],rj=["y","scaleY","originY"];function rU(e,t,n,r){rR(e.x,t,rB,n?n.x:void 0,r?r.x:void 0),rR(e.y,t,rj,n?n.y:void 0,r?r.y:void 0)}function rV(e){return 0===e.translate&&1===e.scale}function rz(e){return rV(e.x)&&rV(e.y)}function r$(e,t){return e.min===t.min&&e.max===t.max}function rW(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function rK(e,t){return rW(e.x,t.x)&&rW(e.y,t.y)}function rH(e){return nI(e.x)/nI(e.y)}function rG(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class rY{constructor(){this.members=[]}add(e){en(this.members,e),e.scheduleRender()}remove(e){if(er(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){let e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){let t;let n=this.members.findIndex(t=>e===t);if(0===n)return!1;for(let e=n;e>=0;e--){let n=this.members[e];if(!1!==n.isPresent){t=n;break}}return!!t&&(this.promote(t),!0)}promote(e,t){let n=this.lead;if(e!==n&&(this.prevLead=n,this.lead=e,e.show(),n)){n.instance&&n.scheduleRender(),e.scheduleRender(),e.resumeFrom=n,t&&(e.resumeFrom.preserveOpacity=!0),n.snapshot&&(e.snapshot=n.snapshot,e.snapshot.latestValues=n.animationValues||n.latestValues),e.root&&e.root.isUpdating&&(e.isLayoutDirty=!0);let{crossfade:r}=e.options;!1===r&&n.hide()}}exitAnimationComplete(){this.members.forEach(e=>{let{options:t,resumingFrom:n}=e;t.onExitComplete&&t.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()})}scheduleRender(){this.members.forEach(e=>{e.instance&&e.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}let rq={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},rJ="undefined"!=typeof window&&void 0!==window.MotionDebug,rZ=["","X","Y","Z"],rX={visibility:"hidden"},rQ=0;function r0(e,t,n,r){let{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function r1({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(e={},n=null==t?void 0:t()){this.id=rQ++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,rJ&&(rq.totalNodes=rq.resolvedTargetDeltas=rq.recalculatedProjection=0),this.nodes.forEach(r8),this.nodes.forEach(it),this.nodes.forEach(ir),this.nodes.forEach(r5),rJ&&window.MotionDebug.record(rq)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=e,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let e=0;e<this.path.length;e++)this.path[e].shouldResetTransform=!0;this.root===this&&(this.nodes=new rw)}addEventListener(e,t){return this.eventHandlers.has(e)||this.eventHandlers.set(e,new ei),this.eventHandlers.get(e).add(t)}notifyListeners(e,...t){let n=this.eventHandlers.get(e);n&&n.notify(...t)}hasListeners(e){return this.eventHandlers.has(e)}mount(t,n=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=t instanceof SVGElement&&"svg"!==t.tagName,this.instance=t;let{layoutId:r,layout:i,visualElement:s}=this.options;if(s&&!s.current&&s.mount(t),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),n&&(i||r)&&(this.isLayoutDirty=!0),e){let n;let r=()=>this.root.updateBlockedByResize=!1;e(t,()=>{this.root.updateBlockedByResize=!0,n&&n(),n=function(e,t){let n=et.now(),r=({timestamp:t})=>{let i=t-n;i>=250&&(Z(r),e(i-250))};return J.read(r,!0),()=>Z(r)}(r,0),rf.hasAnimatedSinceResize&&(rf.hasAnimatedSinceResize=!1,this.nodes.forEac
vendor: 7,053 bytes, line 1
1h(ie))})}r&&this.root.registerSharedNode(r,this),!1!==this.options.animate&&s&&(r||i)&&this.addEventListener("didUpdate",({delta:e,hasLayoutChanged:t,hasRelativeTargetChanged:n,layout:r})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let i=this.options.transition||s.getDefaultTransition()||iu,{onLayoutAnimationStart:o,onLayoutAnimationComplete:l}=s.getProps(),a=!this.targetLayout||!rK(this.targetLayout,r)||n,u=!t&&n;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||u||t&&(a||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(e,u);let t={...y(i,"layout"),onPlay:o,onComplete:l};(s.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t)}else t||ie(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=r})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);let e=this.getStack();e&&e.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,Z(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){!this.isUpdateBlocked()&&(this.isUpdating=!0,this.nodes&&this.nodes.forEach(ii),this.animationId++)}getTransformTemplate(){let{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&function e(t){if(t.hasCheckedOptimisedAppear=!0,t.root===t)return;let{visualElement:n}=t.options;if(!n)return;let r=n.props[eh];if(window.MotionHasOptimisedAnimation(r,"transform")){let{layout:e,layoutId:n}=t.options;window.MotionCancelOptimisedAnimation(r,"transform",J,!(e||n))}let{parent:i}=t;i&&!i.hasCheckedOptimisedAppear&&e(i)}(this),this.root.isUpdating||this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let e=0;e<this.path.length;e++){let t=this.path[e];t.shouldResetTransform=!0,t.updateScroll("snapshot"),t.options.layoutRoot&&t.willUpdate(!1)}let{layoutId:t,layout:n}=this.options;if(void 0===t&&!n)return;let r=this.getTransformTemplate();this.prevTransformTemplateValue=r?r(this.latestValues,""):void 0,this.updateSnapshot(),e&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(r4);return}this.isUpdating||this.nodes.forEach(r9),this.isUpdating=!1,this.nodes.forEach(r6),this.nodes.forEach(r2),this.nodes.forEach(r3),this.clearAllSnapshots();let e=et.now();X.delta=eC(0,1e3/60,e-X.timestamp),X.timestamp=e,X.isProcessing=!0,Q.update.process(X),Q.preRender.process(X),Q.render.process(X),X.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,ry.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(r7),this.sharedNodes.forEach(is)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,J.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){J.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){!this.snapshot&&this.instance&&(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let e=0;e<this.path.length;e++)this.path[e].updateScroll();let e=this.layout;this.layout=this.measure(!1),this.layoutCorrected=nY(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);let{visualElement:t}=this.options;t&&t.notify("LayoutMeasure",this.layout.layoutBox,e?e.layoutBox:void 0)}updateScroll(e="measure"){let t=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===e&&(t=!1),t){let t=r(this.instance);this.scroll={animationId:this.root.animationId,phase:e,isRoot:t,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:t}}}resetTransform(){if(!i)return;let e=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,t=this.projectionDelta&&!rz(this.projectionDelta),n=this.getTransformTemplate(),r=n?n(this.latestValues,""):void 0,s=r!==this.prevTransformTemplateValue;e&&(t||nQ(this.latestValues)||s)&&(i(this.instance,r),this.shouldResetTransform=!1,this.scheduleRender())}measure(e=!0){var t;let n=this.measurePageBox(),r=this.removeElementScroll(n);return e&&(r=this.removeTransform(r)),ih((t=r).x),ih(t.y),{animationId:this.root.animationId,measuredBox:n,layoutBox:r,latestValues:{},source:this.id}}measurePageBox(){var e;let{visualElement:t}=this.options;if(!t)return nY();let n=t.measureViewportBox();if(!((null===(e=this.scroll)||void 0===e?void 0:e.wasRoot)||this.path.some(ig))){let{scroll:e}=this.root;e&&(n8(n.x,e.offset.x),n8(n.y,e.offset.y))}return n}removeElementScroll(e){var t;let n=nY();if(rL(n,e),null===(t=this.scroll)||void 0===t?void 0:t.wasRoot)return n;for(let t=0;t<this.path.length;t++){let r=this.path[t],{scroll:i,options:s}=r;r!==this.root&&i&&s.layoutScroll&&(i.wasRoot&&rL(n,e),n8(n.x,i.offset.x),n8(n.y,i.offset.y))}return n}applyTransform(e,t=!1){let n=nY();rL(n,e);for(let e=0;e<this.path.length;e++){let r=this.path[e];!t&&r.options.layoutScroll&&r.scroll&&r!==r.root&&n7(n,{x:-r.scroll.offset.x,y:-r.scroll.offset.y}),nQ(r.latestValues)&&n7(n,r.latestValues)}return nQ(this.latestValues)&&n7(n,this.latestValues),n}removeTransform(e){let t=nY();rL(t,e);for(let e=0;e<this.path.length;e++){let n=this.path[e];if(!n.instance||!nQ(n.latestValues))continue;nX(n.latestValues)&&n.updateSnapshot();let r=nY();rL(r,n.measurePageBox()),rU(t,n.latestValues,n.snapshot?n.snapshot.layoutBox:void 0,r)}return nQ(this.latestValues)&&rU(t,this.latestValues),t}setTargetDelta(e){this.targetDelta=e,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(e){this.options={...this.options,...e,crossfade:void 0===e.crossfade||e.crossfade}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==X.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(e=!1){var t,n,r,i;let s=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=s.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=s.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=s.isS
1haredProjectionDirty);let o=!!this.resumingFrom||this!==s;if(!(e||o&&this.isSharedProjectionDirty||this.isProjectionDirty||(null===(t=this.parent)||void 0===t?void 0:t.isProjectionDirty)||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:l,layoutId:a}=this.options;if(this.layout&&(l||a)){if(this.resolvedRelativeTargetAt=X.timestamp,!this.targetDelta&&!this.relativeTarget){let e=this.getClosestProjectingParent();e&&e.layout&&1!==this.animationProgress?(this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget=nY(),this.relativeTargetOrigin=nY(),nU(this.relativeTargetOrigin,this.layout.layoutBox,e.layout.layoutBox),rL(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(this.relativeTarget||this.targetDelta){if((this.target||(this.target=nY(),this.targetWithTransforms=nY()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target)?(this.forceRelativeParentToResolveTarget(),n=this.target,r=this.relativeTarget,i=this.relativeParent.target,nB(n.x,r.x,i.x),nB(n.y,r.y,i.y)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):rL(this.target,this.layout.layoutBox),n3(this.target,this.targetDelta)):rL(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;let e=this.getClosestProjectingParent();e&&!!e.resumingFrom==!!this.resumingFrom&&!e.options.layoutScroll&&e.target&&1!==this.animationProgress?(this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget=nY(),this.relativeTargetOrigin=nY(),nU(this.relativeTargetOrigin,this.target,e.target),rL(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}rJ&&rq.resolvedTargetDeltas++}}}getClosestProjectingParent(){return!this.parent||nX(this.parent.latestValues)||n0(this.parent.latestValues)?void 0:this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var e;let t=this.getLead(),n=!!this.resumingFrom||this!==t,r=!0;if((this.isProjectionDirty||(null===(e=this.parent)||void 0===e?void 0:e.isProjectionDirty))&&(r=!1),n&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(r=!1),this.resolvedRelativeTargetAt===X.timestamp&&(r=!1),r)return;let{layout:i,layoutId:s}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(i||s))return;rL(this.layoutCorrected,this.layout.layoutBox);let o=this.treeScale.x,l=this.treeScale.y;!function(e,t,n,r=!1){let i,s;let o=n.length;if(o){t.x=t.y=1;for(let l=0;l<o;l++){s=(i=n[l]).projectionDelta;let{visualElement:o}=i.options;(!o||!o.props.style||"contents"!==o.props.style.display)&&(r&&i.options.layoutScroll&&i.scroll&&i!==i.root&&n7(e,{x:-i.scroll.offset.x,y:-i.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,n3(e,s)),r&&nQ(i.latestValues)&&n7(e,i.latestValues))}t.x<1.0000000000001&&t.x>.999999999999&&(t.x=1),t.y<1.0000000000001&&t.y>.999999999999&&(t.y=1)}}(this.layoutCorrected,this.treeScale,this.path,n),t.layout&&!t.target&&(1!==this.treeScale.x||1!==this.treeScale.y)&&(t.target=t.layout.layoutBox,t.targetWithTransforms=nY());let{target:a}=t;if(!a){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}this.projectionDelta&&this.prevProjectionDelta?(rI(this.prevProjectionDelta.x,this.projectionDelta.x),rI(this.prevProjectionDelta.y,this.projectionDelta.y)):this.createProjectionDeltas(),nR(this.projectionDelta,this.layoutCorrected,a,this.latestValues),this.treeScale.x===o&&this.treeScale.y===l&&rG(this.projectionDelta.x,this.prevProjectionDelta.x)&&rG(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",a)),rJ&&rq.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(e=!0){var t;if(null===(t=this.options.visualElement)||void 0===t||t.scheduleRender(),e){let e=this.getStack();e&&e.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=nH(),this.projectionDelta=nH(),this.projectionDeltaWithTransform=nH()}setAnimationOrigin(e,t=!1){let n;let r=this.snapshot,i=r?r.latestValues:{},s={...this.latestValues},o=nH();this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!t;let l=nY(),a=(r?r.source:void 0)!==(this.layout?this.layout.source:void 0),u=this.getStack(),c=!u||u.members.length<=1,d=!!(a&&
1!c&&!0===this.options.crossfade&&!this.path.some(ia));this.animationProgress=0,this.mixTargetDelta=t=>{let r=t/1e3;if(io(o.x,e.x,r),io(o.y,e.y,r),this.setTargetDelta(o),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout){var u,h,f,p;nU(l,this.layout.layoutBox,this.relativeParent.layout.layoutBox),f=this.relativeTarget,p=this.relativeTargetOrigin,il(f.x,p.x,l.x,r),il(f.y,p.y,l.y,r),n&&(u=this.relativeTarget,h=n,r$(u.x,h.x)&&r$(u.y,h.y))&&(this.isProjectionDirty=!1),n||(n=nY()),rL(n,this.relativeTarget)}a&&(this.animationValues=s,function(e,t,n,r,i,s){i?(e.opacity=tN(0,void 0!==n.opacity?n.opacity:1,rN(r)),e.opacityExit=tN(void 0!==t.opacity?t.opacity:1,0,rF(r))):s&&(e.opacity=tN(void 0!==t.opacity?t.opacity:1,void 0!==n.opacity?n.opacity:1,r));for(let i=0;i<rC;i++){let s=`border${rT[i]}Radius`,o=rP(t,s),l=rP(n,s);(void 0!==o||void 0!==l)&&(o||(o=0),l||(l=0),0===o||0===l||rA(o)===rA(l)?(e[s]=Math.max(tN(rk(o),rk(l),r),0),(eV.test(l)||eV.test(o))&&(e[s]+="%")):e[s]=l)}(t.rotate||n.rotate)&&(e.rotate=tN(t.rotate||0,n.rotate||0,r))}(s,i,this.latestValues,r,d,c)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=r},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(e){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(Z(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=J.update(()=>{rf.hasAnimatedSinceResize=!0,this.currentAnimation=function(e,t,n){let r=eu(0)?0:ea(0);return r.start(nd("",r,1e3,n)),r.animation}(0,0,{...e,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onComplete:()=>{e.onComplete&&e.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);let e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(1e3),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let e=this.getLead(),{targetWithTransforms:t,target:n,layout:r,latestValues:i}=e;if(t&&n&&r){if(this!==e&&this.layout&&r&&ip(this.options.animationType,this.layout.layoutBox,r.layoutBox)){n=this.target||nY();let t=nI(this.layout.layoutBox.x);n.x.min=e.target.x.min,n.x.max=n.x.min+t;let r=nI(this.layout.layoutBox.y);n.y.min=e.target.y.min,n.y.max=n.y.min+r}rL(t,n),n7(t,i),nR(this.projectionDeltaWithTransform,this.layoutCorrected,t,i)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new rY),this.sharedNodes.get(e).add(t);let n=t.options.initialPromotionConfig;t.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(t):void 0})}isLead(){let e=this.getStack();return!e||e.lead===this}getLead(){var e;let{layoutId:t}=this.options;return t&&(null===(e=this.getStack())||void 0===e?void 0:e.lead)||this}getPrevLead(){var e;let{layoutId:t}=this.options;return t?null===(e=this.getStack())||void 0===e?void 0:e.prevLead:void 0}getStack(){let{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:n}={}){let r=this.getStack();r&&r.promote(this,n),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){let e=this.getStack();return!!e&&e.relegate(this)}resetSkewAndRotation(){let{visualElement:e}=this.options;if(!e)return;let t=!1,{latestValues:n}=e;if((n.z||n.rotate||n.rotateX||n.rotateY||n.rotateZ||n.skewX||n.skewY)&&(t=!0),!t)return;let r={};n.z&&r0("z",e,r,this.animationValues);for(let t=0;t<rZ.length;t++)r0(`rotate${rZ[t]}`,e,r,this.animationValues),r0(`skew${rZ[t]}`,e,r,this.animationValues);for(let t in e.render(),r)e.setStaticValue(t,r[t]),this.animationValues&&(this.animationValues[t]=r[t]);e.scheduleRender()}getProjectionStyles(e){var t,n;if(!this.instance||this.isSVG)return;if(!this.isVisible)return rX;let r={visibility:""},i=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,r.opacity="",r.pointerEvents=rE(null==e?void 0:e.pointerEvents)||"",r.transform=i?i(this.latestValues,""):"none",r;let s=this.getLead();if(!this.projectionDelta||!this.layout||!s.target){let t={};return this.options.layoutId&&(t.opacity=void 0!==this.latestValues.opacity?this.latestValues.opacity:1,t.pointerEvents=rE(null==e?void 0:e.pointerEvents)||""),this.hasProjected&&!nQ(this.latestValues)&&(t.transform=i?i({},""):"none",this.hasProjected=!1),t}let o=s.animationValues||s.latestValues;this.applyTransformsToTarget(),r.transform=function(e,t,n){let r="",i=e.x.translate/t.x,s=e.y.translate/t.y,o=(null==n?void 0:n.z)||0;if((i||s||o)&&(r=`translate3d(${i}px, ${s}px, ${o}px) `),(1!==t.x||1!==t.y)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){let{transformPerspective:e,rotate:t,rotateX:i,rotateY:s,skewX:o,skewY:l}=n;e&&(r=`perspective(${e}px) ${r}`),t&&(r+=`rotate(${t}deg) `),i&&(r+=`rotateX(${i}deg) `),s&&(r+=`rotateY(${s}deg) `),o&&(r+=`skewX(${o}deg) `),l&&(r+=`skewY(${l}deg) `)}let l=e.x.scale*t.x,a=e.y.scale*t.y;return(1!==l||1!==a)&&(r+=`scale(${l}, ${a}
1)`),r||"none"}(this.projectionDeltaWithTransform,this.treeScale,o),i&&(r.transform=i(o,r.transform));let{x:l,y:a}=this.projectionDelta;for(let e in r.transformOrigin=`${100*l.origin}% ${100*a.origin}% 0`,s.animationValues?r.opacity=s===this?null!==(n=null!==(t=o.opacity)&&void 0!==t?t:this.latestValues.opacity)&&void 0!==n?n:1:this.preserveOpacity?this.latestValues.opacity:o.opacityExit:r.opacity=s===this?void 0!==o.opacity?o.opacity:"":void 0!==o.opacityExit?o.opacityExit:0,rm){if(void 0===o[e])continue;let{correct:t,applyTo:n}=rm[e],i="none"===r.transform?o[e]:t(o[e],s);if(n){let e=n.length;for(let t=0;t<e;t++)r[n[t]]=i}else r[e]=i}return this.options.layoutId&&(r.pointerEvents=s===this?rE(null==e?void 0:e.pointerEvents)||"":"none"),r}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(e=>{var t;return null===(t=e.currentAnimation)||void 0===t?void 0:t.stop()}),this.root.nodes.forEach(r4),this.root.sharedNodes.clear()}}}function r2(e){e.updateLayout()}function r3(e){var t;let n=(null===(t=e.resumeFrom)||void 0===t?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){let{layoutBox:t,measuredBox:r}=e.layout,{animationType:i}=e.options,s=n.source!==e.layout.source;"size"===i?nq(e=>{let r=s?n.measuredBox[e]:n.layoutBox[e],i=nI(r);r.min=t[e].min,r.max=r.min+i}):ip(i,n.layoutBox,t)&&nq(r=>{let i=s?n.measuredBox[r]:n.layoutBox[r],o=nI(t[r]);i.max=i.min+o,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[r].max=e.relativeTarget[r].min+o)});let o=nH();nR(o,t,n.layoutBox);let l=nH();s?nR(l,e.applyTransform(r,!0),n.measuredBox):nR(l,t,n.layoutBox);let a=!rz(o),u=!1;if(!e.resumeFrom){let r=e.getClosestProjectingParent();if(r&&!r.resumeFrom){let{snapshot:i,layout:s}=r;if(i&&s){let o=nY();nU(o,n.layoutBox,i.layoutBox);let l=nY();nU(l,t,s.layoutBox),rK(o,l)||(u=!0),r.options.layoutRoot&&(e.relativeTarget=l,e.relativeTargetOrigin=o,e.relativeParent=r)}}}e.notifyListeners("didUpdate",{layout:t,snapshot:n,delta:l,layoutDelta:o,hasLayoutChanged:a,hasRelativeTargetChanged:u})}else if(e.isLead()){let{onExitComplete:t}=e.options;t&&t()}e.options.transition=void 0}function r8(e){rJ&&rq.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function r5(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function r7(e){e.clearSnapshot()}function r4(e){e.clearMeasurements()}function r9(e){e.isLayoutDirty=!1}function r6(e){let{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function ie(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function it(e){e.resolveTargetDelta()}function ir(e){e.calcProjection()}function ii(e){e.resetSkewAndRotation()}function is(e){e.removeLeadSnapshot()}function io(e,t,n){e.translate=tN(t.translate,0,n),e.scale=tN(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function il(e,t,n,r){e.min=tN(t.min,n.min,r),e.max=tN(t.max,n.max,r)}function ia(e){return e.animationValues&&void 0!==e.animationValues.opacityExit}let iu={duration:.45,ease:[.4,0,.1,1]},ic=e=>"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),id=ic("applewebkit/")&&!ic("chrome/")?Math.round:V;function ih(e){e.min=id(e.min),e.max=id(e.max)}function ip(e,t,n){return"position"===e||"preserve-aspect"===e&&!(.2>=Math.abs(rH(t)-rH(n)))}function ig(e){var t;return e!==e.root&&(null===(t=e.scroll)||void 0===t?void 0:t.wasRoot)}let im=r1({attachResizeListener:(e,t)=>nE(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),iy={current:void 0},iv=r1({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!iy.current){let e=new im({});e.mount(window),e.setOptions({layoutScroll:!0}),iy.current=e}return iy.current},resetTransform:(e,t)=>
1{e.style.transform=void 0!==t?t:"none"},checkIsScrollRoot:e=>"fixed"===window.getComputedStyle(e).position});function i_(e,t,n){let{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover","Start"===n);let i=r["onHover"+n];i&&J.postRender(()=>i(t,nT(t)))}class ib extends nb{mount(){let{current:e}=this.node;e&&(this.unmount=function(e,t,n={}){let[r,i,s]=P(e,n),o=N(e=>{let{target:n}=e,r=t(e);if("function"!=typeof r||!n)return;let s=N(e=>{r(e),n.removeEventListener("pointerleave",s)});n.addEventListener("pointerleave",s,i)});return r.forEach(e=>{e.addEventListener("pointerenter",o,i)}),s}(e,e=>(i_(this.node,e,"Start"),e=>i_(this.node,e,"End"))))}unmount(){}}class ix extends nb{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch(t){e=!0}e&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){this.isActive&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=tj(nE(this.node.current,"focus",()=>this.onFocus()),nE(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function iS(e,t,n){let{props:r}=e;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap","Start"===n);let i=r["onTap"+("End"===n?"":n)];i&&J.postRender(()=>i(t,nT(t)))}class iw extends nb{mount(){let{current:e}=this.node;e&&(this.unmount=function(e,t,n={}){let[r,i,s]=P(e,n),o=e=>{let r=e.currentTarget;if(!B(e)||L.has(r))return;L.add(r);let s=t(e),o=(e,t)=>{window.removeEventListener("pointerup",l),window.removeEventListener("pointercancel",a),B(e)&&L.has(r)&&(L.delete(r),"function"==typeof s&&s(e,{success:t}))},l=e=>{o(e,n.useGlobalTarget||F(r,e.target))},a=e=>{o(e,!1)};window.addEventListener("pointerup",l,i),window.addEventListener("pointercancel",a,i)};return r.forEach(e=>{D.has(e.tagName)||-1!==e.tabIndex||null!==e.getAttribute("tabindex")||(e.tabIndex=0),(n.useGlobalTarget?window:e).addEventListener("pointerdown",o,i),e.addEventListener("focus",e=>R(e,i),i)}),s}(e,e=>(iS(this.node,e,"Start"),(e,{success:t})=>iS(this.node,e,t?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}let iE=new WeakMap,iT=new WeakMap,iC=e=>{let t=iE.get(e.target);t&&t(e)},ik=e=>{e.forEach(iC)},iA={some:0,all:1};class iP extends nb{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();let{viewport:e={}}=this.node.getProps(),{root:t,margin:n,amount:r="some",once:i}=e,s={root:t?t.current:void 0,rootMargin:n,threshold:"number"==typeof r?r:iA[r]};return function(e,t,n){let r=function({root:e,...t}){let n=e||document;iT.has(n)||iT.set(n,{});let r=iT.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(ik,{root:e,...t})),r[i]}(t);return iE.set(e,n),r.observe(e),()=>{iE.delete(e),r.unobserve(e)}}(this.node.current,s,e=>{let{isIntersecting:t}=e;if(this.isInView===t||(this.isInView=t,i&&!t&&this.hasEnteredView))return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",t);let{onViewportEnter:n,onViewportLeave:r}=this.node.getProps(),s=t?n:r;s&&s(e)})}mount(){this.startObserver()}update(){if("undefined"==typeof IntersectionObserver)return;let{props:e,prevProps:t}=this.node;["amount","margin","root"].some(function({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}(e,t))&&this.startObserver()}unmount(){}}let iN=(0,ru.createContext)({strict:!1}),iF=(0,ru.createContext)({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"}),iO=(0,ru.createContext)({});function iD(e){return i(e.animate)||h.some(t=>l(e[t]))}function iL(e){return!!(iD(e)||e.variants)}function iI(e){return Array.isArray(e)?e.join(" "):e}let iM="undefined"!=typeof window,iR={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},iB={};for(let e in iR)iB[e]={isEnabled:t=>iR[e].some(e=>!!t[e])};let ij=Symbol.for("motionComponentSymbol"),iU=iM?ru.useLayoutEffect:ru.useEffect,iV=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function iz(e){if("string"!=typeof e||e.includes("-"));else if(iV.indexOf(e)>-1||/[A-Z]/u.test(e))return!0;return!1}let i$=e=>(t,n)=>{let r=(0,ru.useContext)(iO),s=(0,ru.useContext)(rc),o=()=>(function({scrapeMotionValuesFromProps:e,createRenderState:t,onUpdate:n},r,s,o){let l={latestValues:function(e,t,n,r){let s={},o=r(e,{});for(let e in o)s[e]=rE(o[e]);let{initial:l,animate:a}=e,c=iD(e),d=iL(e);t&&d&&!c&&!1!==e.inherit&&(void 0===l&&(l=t.initial),void 0===a&&(a=t.animate));
1let h=!!n&&!1===n.initial,f=(h=h||!1===l)?a:l;if(f&&"boolean"!=typeof f&&!i(f)){let t=Array.isArray(f)?f:[f];for(let n=0;n<t.length;n++){let r=u(e,t[n]);if(r){let{transitionEnd:e,transition:t,...n}=r;for(let e in n){let t=n[e];if(Array.isArray(t)){let e=h?t.length-1:0;t=t[e]}null!==t&&(s[e]=t)}for(let t in e)s[t]=e[t]}}}return s}(r,s,o,e),renderState:t()};return n&&(l.onMount=e=>n({props:r,current:e,...l}),l.onUpdate=e=>n(e)),l})(e,t,r,s);return n?o():function(e){let t=(0,ru.useRef)(null);return null===t.current&&(t.current=e()),t.current}(o)},iW=(e,t)=>t&&"number"==typeof e?t.transform(e):e,iK={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},iH=z.length;function iG(e,t,n){let{style:r,vars:i,transformOrigin:s}=e,o=!1,l=!1;for(let e in t){let n=t[e];if($.has(e)){o=!0;continue}if(ty(e)){i[e]=n;continue}{let t=iW(n,e9[e]);e.startsWith("origin")?(l=!0,s[e]=t):r[e]=t}}if(!t.transform&&(o||n?r.transform=function(e,t,n){let r="",i=!0;for(let s=0;s<iH;s++){let o=z[s],l=e[o];if(void 0===l)continue;let a=!0;if(!(a="number"==typeof l?l===(o.startsWith("scale")?1:0):0===parseFloat(l))||n){let e=iW(l,e9[o]);if(!a){i=!1;let t=iK[o]||o;r+=`${t}(${e}) `}n&&(t[o]=e)}}return r=r.trim(),n?r=n(t,i?"":r):i&&(r="none"),r}(t,e.transform,n):r.transform&&(r.transform="none")),l){let{originX:e="50%",originY:t="50%",originZ:n=0}=s;r.transformOrigin=`${e} ${t} ${n}`}}let iY={offset:"stroke-dashoffset",array:"stroke-dasharray"},iq={offset:"strokeDashoffset",array:"strokeDasharray"};function iJ(e,t,n){return"string"==typeof e?e:ez.transform(t+n*e)}function iZ(e,{attrX:t,attrY:n,attrScale:r,originX:i,originY:s,pathLength:o,pathSpacing:l=1,pathOffset:a=0,...u},c,d){if(iG(e,u,d),c){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};let{attrs:h,style:f,dimensions:p}=e;h.transform&&(p&&(f.transform=h.transform),delete h.transform),p&&(void 0!==i||void 0!==s||f.transform)&&(f.transformOrigin=function(e,t,n){let r=iJ(t,e.x,e.width),i=iJ(n,e.y,e.height);return`${r} ${i}`}(p,void 0!==i?i:.5,void 0!==s?s:.5)),void 0!==t&&(h.x=t),void 0!==n&&(h.y=n),void 0!==r&&(h.scale=r),void 0!==o&&function(e,t,n=1,r=0,i=!0){e.pathLength=1;let s=i?iY:iq;e[s.offset]=ez.transform(-r);let o=ez.transform(t),l=ez.transform(n);e[s.array]=`${o} ${l}`}(h,o,l,a,!1)}let iX=()=>({style:{},transform:{},transformOrigin:{},vars:{}}),iQ=()=>({...iX(),attrs:{}}),i0=e=>"string"==typeof e&&"svg"===e.toLowerCase();function i1(e,{style:t,vars:n},r,i){for(let s in Object.assign(e.style,t,i&&i.getProjectionStyles(r)),n)e.style.setProperty(s,n[s])}let i2=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function i3(e,t,n,r){for(let n in i1(e,t,void 0,r),t.attrs)e.setAttribute(i2.has(n)?n:ed(n),t.attrs[n])}function i8(e,{layout:t,layoutId:n}){return $.has(e)||e.startsWith("origin")||(t||void 0!==n)&&(!!rm[e]||"opacity"===e)}function i5(e,t,n){var r;let{style:i}=e,s={};for(let o in i)(eu(i[o])||t.style&&eu(t.style[o])||i8(o,e)||(null===(r=null==n?void 0:n.getValue(o))||void 0===r?void 0:r.liveStyle)!==void 0)&&(s[o]=i[o]);return s}function i7(e,t,n){let r=i5(e,t,n);for(let n in e)(eu(e[n])||eu(t[n]))&&(r[-1!==z.indexOf(n)?"attr"+n.charAt(0).toUpperCase()+n.substring(1):n]=e[n]);return r}let i4=["x","y","width","height","cx","cy","r"],i9={useVisualState:i$({scrapeMotionValuesFromProps:i7,createRenderState:iQ,onUpdate:({props:e,prevProps:t,current:n,renderState:r,latestValues:i})=>{if(!n)return;let s=!!e.drag;if(!s){for(let e in i)if($.has(e)){s=!0;break}}if(!s)return;let o=!t;if(t)for(let n=0;n<i4.length;n++){let r=i4[n];e[r]!==t[r]&&(o=!0)}o&&J.read(()=>{!function(e,t){try{t.dimensions="function"==typeof e.getBBox?e.getBBox():e.getBoundingClientRect()}catch(e){t.dimensions={x:0,y:0,width:0,height:0}}}(n,r),J.render(()=>{iZ(r,i,i0(n.tagName),e.transformTemplate),i3(n,r)})})}})},i6={useVisualState:i$({scrapeMotionValuesFromProps:i5,createRenderState:iX})};function se(e,t,n){for(let r in t)eu(t[r])||i8(r,n)||(e[r]=t[r])}
1let st=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function sn(e){return e.startsWith("while")||e.startsWith("drag")&&"draggable"!==e||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||st.has(e)}let sr=e=>!sn(e);try{(rs=require("@emotion/is-prop-valid").default)&&(sr=e=>e.startsWith("on")?!sn(e):rs(e))}catch(e){}let si={current:null},ss={current:!1},so=[...tw,eG,e2],sl=e=>so.find(tS(e)),sa=new WeakMap,su=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class sc{scrapeMotionValuesFromProps(e,t,n){return{}}constructor({parent:e,props:t,presenceContext:n,reducedMotionConfig:r,blockInitialAnimation:i,visualState:s},o={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=tp,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{let e=et.now();this.renderScheduledAt<e&&(this.renderScheduledAt=e,J.render(this.render,!1,!0))};let{latestValues:l,renderState:a,onUpdate:u}=s;this.onUpdate=u,this.latestValues=l,this.baseTarget={...l},this.initialValues=t.initial?{...l}:{},this.renderState=a,this.parent=e,this.props=t,this.presenceContext=n,this.depth=e?e.depth+1:0,this.reducedMotionConfig=r,this.options=o,this.blockInitialAnimation=!!i,this.isControllingVariants=iD(t),this.isVariantNode=iL(t),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(e&&e.current);let{willChange:c,...d}=this.scrapeMotionValuesFromProps(t,{},this);for(let e in d){let t=d[e];void 0!==l[e]&&eu(t)&&t.set(l[e],!1)}}mount(e){this.current=e,sa.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((e,t)=>this.bindToMotionValue(t,e)),ss.current||function(){if(ss.current=!0,iM){if(window.matchMedia){let e=window.matchMedia("(prefers-reduced-motion)"),t=()=>si.current=e.matches;e.addListener(t),t()}else si.current=!1}}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||si.current),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){for(let e in sa.delete(this.current),this.projection&&this.projection.unmount(),Z(this.notifyUpdate),Z(this.render),this.valueSubscriptions.forEach(e=>e()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this),this.events)this.events[e].clear();for(let e in this.features){let t=this.features[e];t&&(t.unmount(),t.isMounted=!1)}this.current=null}bindToMotionValue(e,t){let n;this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)();let r=$.has(e),i=t.on("change",t=>{this.latestValues[e]=t,this.props.onUpdate&&J.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0)}),s=t.on("renderRequest",this.scheduleRender);window.MotionCheckAppearSync&&(n=window.MotionCheckAppearSync(this,e,t)),this.valueSubscriptions.set(e,()=>{i(),s(),n&&n(),t.owner&&t.stop()})}sortNodePosition(e){return this.current&&this.sortInstanceNodePosition&&this.type===e.type?this.sortInstanceNodePosition(this.current,e.current):0}updateFeatures(){let e="animation";for(e in iB){let t=iB[e];if(!t)continue;let{isEnabled:n,Feature:r}=t;if(!this.features[e]&&r&&n(this.props)&&(this.features[e]=new r(this)),this.features[e]){let t=this.features[e];
1t.isMounted?t.update():(t.mount(),t.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):nY()}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,t){this.latestValues[e]=t}update(e,t){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=t;for(let t=0;t<su.length;t++){let n=su[t];this.propEventSubscriptions[n]&&(this.propEventSubscriptions[n](),delete this.propEventSubscriptions[n]);let r=e["on"+n];r&&(this.propEventSubscriptions[n]=this.on(n,r))}this.prevMotionValues=function(e,t,n){for(let r in t){let i=t[r],s=n[r];if(eu(i))e.addValue(r,i);else if(eu(s))e.addValue(r,ea(i,{owner:e}));else if(s!==i){if(e.hasValue(r)){let t=e.getValue(r);!0===t.liveStyle?t.jump(i):t.hasAnimated||t.set(i)}else{let t=e.getStaticValue(r);e.addValue(r,ea(void 0!==t?t:i,{owner:e}))}}}for(let r in n)void 0===t[r]&&e.removeValue(r);return t}(this,this.scrapeMotionValuesFromProps(e,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue(),this.onUpdate&&this.onUpdate(this)}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(e){let t=this.getClosestVariantNode();if(t)return t.variantChildren&&t.variantChildren.add(e),()=>t.variantChildren.delete(e)}addValue(e,t){let n=this.values.get(e);t!==n&&(n&&this.removeValue(e),this.bindToMotionValue(e,t),this.values.set(e,t),this.latestValues[e]=t.get())}removeValue(e){this.values.delete(e);let t=this.valueSubscriptions.get(e);t&&(t(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,t){if(this.props.values&&this.props.values[e])return this.props.values[e];let n=this.values.get(e);return void 0===n&&void 0!==t&&(n=ea(null===t?void 0:t,{owner:this}),this.addValue(e,n)),n}readValue(e,t){var n;let r=void 0===this.latestValues[e]&&this.current?null!==(n=this.getBaseTargetFromProps(this.props,e))&&void 0!==n?n:this.readValueFromInstance(this.current,e,this.options):this.latestValues[e];return null!=r&&("string"==typeof r&&(tg(r)||eT(r))?r=parseFloat(r):!sl(r)&&e2.test(t)&&(r=tt(e,t)),this.setBaseTarget(e,eu(r)?r.get():r)),eu(r)?r.get():r}setBaseTarget(e,t){this.baseTarget[e]=t}getBaseTarget(e){var t;let n;let{initial:r}=this.props;if("string"==typeof r||"object"==typeof r){let i=u(this.props,r,null===(t=this.presenceContext)||void 0===t?void 0:t.custom);i&&(n=i[e])}if(r&&void 0!==n)return n;let i=this.getBaseTargetFromProps(this.props,e);return void 0===i||eu(i)?void 0!==this.initialValues[e]&&void 0===n?void 0:this.baseTarget[e]:i}on(e,t){return this.events[e]||(this.events[e]=new ei),this.events[e].add(t)}notify(e,...t){this.events[e]&&this.events[e].notify(...t)}}class sd extends sc{constructor(){super(...arguments),this.KeyframeResolver=tT}sortInstanceNodePosition(e,t){return 2&e.compareDocumentPosition(t)?1:-1}getBaseTargetFromProps(e,t){return e.style?e.style[t]:void 0}removeValueFromRenderState(e,{vars:t,style:n}){delete t[e],delete n[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:e}=this.props;eu(e)&&(this.childSubscription=e.on("change",e=>{this.current&&(this.current.textContent=`${e}`)}))}}class sh extends sd{constructor(){super(...arguments),this.type="html",this.renderInstance=i1}readValueFromInstance(e,t){if($.has(t)){let e=te(t);return e&&e.default||0}{let n=window.getComputedStyle(e),r=(ty(t)?n.getPropertyValue(t):n[t])||0;return"string"==typeof r?r.trim():r}}measureInstanceViewportBox(e,{transformPagePoint:t}){return n4(e,t)}build(e,t,n){iG(e,t,n.transformTemplate)}
1scrapeMotionValuesFromProps(e,t,n){return i5(e,t,n)}}class sf extends sd{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=nY}getBaseTargetFromProps(e,t){return e[t]}readValueFromInstance(e,t){if($.has(t)){let e=te(t);return e&&e.default||0}return t=i2.has(t)?t:ed(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,n){return i7(e,t,n)}build(e,t,n){iZ(e,t,this.isSVGTag,n.transformTemplate)}renderInstance(e,t,n,r){i3(e,t,n,r)}mount(e){this.isSVGTag=i0(e.tagName),super.mount(e)}}let sp=function(e){if("undefined"==typeof Proxy)return e;let t=new Map;return new Proxy((...t)=>e(...t),{get:(n,r)=>"create"===r?e:(t.has(r)||t.set(r,e(r)),t.get(r))})}((ro={animation:{Feature:nx},exit:{Feature:nw},inView:{Feature:iP},tap:{Feature:iw},focus:{Feature:ix},hover:{Feature:ib},pan:{Feature:ri},drag:{Feature:rn,ProjectionNode:iv,MeasureLayout:rb},layout:{ProjectionNode:iv,MeasureLayout:rb}},rl=(e,t)=>iz(e)?new sf(t):new sh(t,{allowProjection:e!==ru.Fragment}),function(e,{forwardMotionProps:t}={forwardMotionProps:!1}){return function(e){var t,n;let{preloadedFeatures:r,createVisualElement:i,useRender:s,useVisualState:o,Component:a}=e;function u(e,t){var n;let r;let u={...(0,ru.useContext)(iF),...e,layoutId:function(e){let{layoutId:t}=e,n=(0,ru.useContext)(rd).id;return n&&void 0!==t?n+"-"+t:t}(e)},{isStatic:c}=u,d=function(e){let{initial:t,animate:n}=function(e,t){if(iD(e)){let{initial:t,animate:n}=e;return{initial:!1===t||l(t)?t:void 0,animate:l(n)?n:void 0}}return!1!==e.inherit?t:{}}(e,(0,ru.useContext)(iO));return(0,ru.useMemo)(()=>({initial:t,animate:n}),[iI(t),iI(n)])}(e),h=o(e,c);if(!c&&iM){(0,ru.useContext)(iN).strict;let e=function(e){let{drag:t,layout:n}=iB;if(!t&&!n)return{};let r={...t,...n};return{MeasureLayout:(null==t?void 0:t.isEnabled(e))||(null==n?void 0:n.isEnabled(e))?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}(u);r=e.MeasureLayout,d.visualElement=function(e,t,n,r,i){var s,o;let{visualElement:l}=(0,ru.useContext)(iO),a=(0,ru.useContext)(iN),u=(0,ru.useContext)(rc),c=(0,ru.useContext)(iF).reducedMotion,d=(0,ru.useRef)(null);r=r||a.renderer,!d.current&&r&&(d.current=r(e,{visualState:t,parent:l,props:n,presenceContext:u,blockInitialAnimation:!!u&&!1===u.initial,reducedMotionConfig:c}));let h=d.current,f=(0,ru.useContext)(rh);h&&!h.projection&&i&&("html"===h.type||"svg"===h.type)&&function(e,t,n,r){let{layoutId:i,layout:s,drag:o,dragConstraints:l,layoutScroll:a,layoutRoot:u}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:function e(t){if(t)return!1!==t.options.allowProjection?t.projection:e(t.parent)}(e.parent)),e.projection.setOptions({layoutId:i,layout:s,alwaysMeasureLayout:!!o||l&&nL(l),visualElement:e,animationType:"string"==typeof s?s:"both",initialPromotionConfig:r,layoutScroll:a,layoutRoot:u})}(d.current,n,i,f);let p=(0,ru.useRef)(!1);(0,ru.useInsertionEffect)(()=>{h&&p.current&&h.update(n,u)});let g=n[eh],m=(0,ru.useRef)(!!g&&!(null===(s=window.MotionHandoffIsComplete)||void 0===s?void 0:s.call(window,g))&&(null===(o=window.MotionHasOptimisedAnimation)||void 0===o?void 0:o.call(window,g)));return iU(()=>{h&&(p.current=!0,window.MotionIsMounted=!0,h.updateFeatures(),ry.render(h.render),m.current&&h.animationState&&h.animationState.animateChanges())}),(0,ru.useEffect)(()=>{h&&(!m.current&&h.animationState&&h.animationState.animateChanges(),m.current&&(queueMicrotask(()=>{var e;null===(e=window.MotionHandoffMarkAsComplete)||void 0===e||e.call(window,g)}),m.current=!1))}),h}(a,h,u,i,e.ProjectionNode)}return(0,ra.jsxs)(iO.Provider,{value:d,children:[r&&d.visualElement?(0,ra.jsx)(r,{visualElement:d.visualElement,...u}):null,s(a,e,(n=d.visualElement,(0,ru.useCallback)(e=>{e&&h.onMount&&h.onMount(e),n&&(e?n.mount(e):n.unmount()),t&&("function"==typeof t?t(e):nL(t)&&(t.current=e))},[n])),h,c,d.visualElement)]})}r&&function(e){for(let t in e)iB[t]={...iB[t],...e[t]}}(r),u.displayName="motion.".concat("string"==typeof a?a:"create(".concat(null!==(n=null!==(t=a.displayName)&&void 0!==t?t:a.name)&&void 0!==n?n:"",")"));let c=(0,ru.forwardRef)(u);return c[ij]=a,c}({...iz(e)?i9:i6,preloadedFeatures:ro,useRender:function(e=!1){return(t,n,r,{latestValues:i},s)=>{let o=(iz(t)?function(e,t,n,r){let i=(0,ru.useMemo)(()=>{let n=iQ();return iZ(n,t,i0(r),e.transformTemplate),{...n.attrs,style:{...n.style}}},[t]);if(e.style){let t={};se(t,e.style,e),i.style={...t,...i.style}}return i}:function(e,t){let n={},r=function(e,t){let n=e.style||{},r={};return se(r,n,e),Object.assign(r,function({transformTemplate:e},t){return(0,ru.useMemo)(()=>{let n=iX();return iG(n,t,e),Object.assign({},n.vars,n.style)},[t])}(e,t)),r}(e,t);return e.drag&&!1!==e.dragListener&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=!0===e.drag?"none":`pan-${"x"===e.drag?"y":"x"}
1`),void 0===e.tabIndex&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n})(n,i,s,t),l=function(e,t,n){let r={};for(let i in e)("values"!==i||"object"!=typeof e.values)&&(sr(i)||!0===n&&sn(i)||!t&&!sn(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}(n,"string"==typeof t,e),a=t!==ru.Fragment?{...l,...o,ref:r}:{},{children:u}=n,c=(0,ru.useMemo)(()=>eu(u)?u.get():u,[u]);return(0,ru.createElement)(t,{...a,children:c})}}(t),createVisualElement:rl,Component:e})}))},18193:function(e,t,n){"use strict";function r(e){return{}}n.d(t,{$l:function(){return m},A1:function(){return d},A3:function(){return nM},B3:function(){return tR},BE:function(){return r4},Eo:function(){return it},Ew:function(){return g},F7:function(){return rq},GA:function(){return eL},Gg:function(){return nQ},Gq:function(){return K},Gv:function(){return e0},H2:function(){return e$},HX:function(){return rY},Hr:function(){return V},Ij:function(){return rZ},In:function(){return tE},Jh:function(){return is},K0:function(){return u},KB:function(){return ie},Kr:function(){return o},LV:function(){return j},MK:function(){return P},MX:function(){return nX},Mt:function(){return l},Nm:function(){return _},OP:function(){return n6},PU:function(){return O},R2:function(){return nW},RG:function(){return r8},RJ:function(){return h},RO:function(){return I},Re:function(){return tC},Rl:function(){return r9},S3:function(){return n2},S9:function(){return eP},T:function(){return nI},U2:function(){return tb},UL:function(){return to},VN:function(){return r6},WA:function(){return tB},WH:function(){return a},XI:function(){return M},XN:function(){return T},Xo:function(){return eZ},Y7:function(){return C},Zb:function(){return E},Zq:function(){return A},_0:function(){return w},_v:function(){return t_},aR:function(){return k},af:function(){return eI},bg:function(){return tT},cA:function(){return F},cj:function(){return f},cs:function(){return rr},cz:function(){return D},dB:function(){return N},dL:function(){return rp},dR:function(){return U},ek:function(){return ru},fA:function(){return r},fL:function(){return tc},fn:function(){return tA},gI:function(){return eY},gg:function(){return eO},h5:function(){return rh},iO:function(){return rt},jw:function(){return ir},k$:function(){return rX},kE:function(){return R},kk:function(){return tF},lv:function(){return tN},m$:function(){return W},mJ:function(){return tD},n2:function(){return p},oC:function(){return rR},od:function(){return rb},oj:function(){return i},oq:function(){return e2},r0:function(){return z},rc:function(){return n3},u$:function(){return x},u8:function(){return tP},uF:function(){return tk},vN:function(){return rd},wd:function(){return r0},yF:function(){return c},yb:function(){return H},yn:function(){return $},zD:function(){return L},zq:function(){return y},zr:function(){return s}});let i={},s={},o={},l={},a={},u={},c={},d={},h={},f={},p={},g={},m={},y={},v={},_={},b={},x={},S={},w={},E={},T={},C={},k={},A={},P={},N={},F={},O={},D={},L={},I={},M={},R={},B={},j={},U={},V={},z={},$={},W={},K={},H={},G="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement,Y=G&&"documentMode"in document?document.documentMode:null,q=G&&/Mac|iPod|iPhone|iPad/.test(navigator.platform),J=G&&/^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent),Z=!(!G||!("InputEvent"in window)||Y)&&"getTargetRanges"in new window.InputEvent("input"),X=G&&/Version\/[\d.]+.*Safari/.test(navigator.userAgent),Q=G&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream,ee=G&&/Android/.test(navigator.userAgent),et=G&&/^(?=.*Chrome).*/i.test(navigator.userAgent),en=G&&ee&&et,er=G&&/AppleWebKit\/[\d.]+/.test(navigator.userAgent)&&!et,ei=X||Q||er?"\xa0":"​",es=J?"\xa0":ei,eo="֑-߿יִ-﷽ﹰ-ﻼ",el="A-Za-z\xc0-\xd6\xd8-\xf6\xf8-ʸ̀-֐ࠀ-῿‎Ⰰ-﬜︀-﹯﻽-￿",ea=RegExp("^[^"+el+"]*["+eo+"]"),eu=RegExp("^[^"+eo+"]*["+el+"]"),ec={bold:1,capitalize:1024,code:16,highlight:128,italic:2,lowercase:256,strikethrough:4,subscript:32,superscript:64,underline:8,uppercase:512},ed={directionless:1,unmergeable:2},eh={center:2,end:6,justify:4,left:1,right:3,start:5},ef={2:"center",6:"end",4:"justify",1:"left",3:"right",5:"start"},ep={normal:0,segmented:2,token:1},eg={0:"normal",2:"segmented",1:"token"};var em,ey=(em=function(e){let t=new URLSearchParams;t.append("code",e);for(let e=1;e<arguments.length;e++)t.append("v",arguments[e]);throw Error(`Minified Lexical error #${e}; visit https://lexical.dev/docs/error?${t} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`)}).__esModule&&Object.prototype.hasOwnProperty.call(em,"default")?em.default:em;function ev(...e){let t=[];for(let n of e)if(n&&"string"==typeof n)for(let[e]of n.matchAll(/\S+/g))t.push(e);return t}let e_=!1,eb=0;function ex(e){eb=e.timeStamp}
1function eS(e,t,n){let r="BR"===e.nodeName,i=t.__lexicalLineBreak;return i&&(e===i||r&&e.previousSibling===i)||r&&void 0!==eJ(e,n)}function ew(e,t,n){e_=!0;let r=performance.now()-eb>100;try{rK(e,()=>{let i=rp()||e.getEditorState().read(()=>{let e=rp();return null!==e?e.clone():null}),s=new Map,o=e.getRootElement(),l=e._editorState,a=e._blockCursorElement,u=!1,c="";for(let n=0;n<t.length;n++){let d=t[n],h=d.type,f=d.target,p=function(e,t,n,r){var i;for(let s=e;s&&(i=s,!0!==i.__lexicalUnmanaged);s=tp(s)){let e=eJ(s,t);if(void 0!==e){let t=eY(e,n);if(t)return rX(t)||!tC(s)?void 0:[s,t]}else if(s===r)return[r,e1(n)]}}(f,e,l,o);if(!p)continue;let[g,m]=p;if("characterData"===h)r&&nQ(m)&&eU(f)&&function(e,t,n){if(n6(e)){let t=e.anchor.getNode();if(t.is(n)&&e.format!==t.getFormat())return!1}return eU(t)&&n.isAttached()}(i,f,m)&&function(e,t,n){let r=tE(tv(n)),i=null,s=null;null!==r&&r.anchorNode===e&&(i=r.anchorOffset,s=r.focusOffset);let o=e.nodeValue;null!==o&&te(t,o,i,s,!1)}(f,m,e);else if("childList"===h){u=!0;let t=d.addedNodes;for(let n=0;n<t.length;n++){let r=t[n],i=eq(r),s=r.parentNode;if(null!=s&&r!==a&&null===i&&!eS(r,s,e)){if(J){let e=(tC(r)?r.innerText:null)||r.nodeValue;e&&(c+=e)}s.removeChild(r)}}let n=d.removedNodes,r=n.length;if(r>0){let t=0;for(let i=0;i<r;i++){let r=n[i];(eS(r,f,e)||a===r)&&(f.appendChild(r),t++)}r!==t&&s.set(g,m)}}}if(s.size>0)for(let[t,n]of s)n.reconcileObservedMutation(t,e);let d=n.takeRecords();if(d.length>0){for(let t=0;t<d.length;t++){let n=d[t],r=n.addedNodes,i=n.target;for(let t=0;t<r.length;t++){let n=r[t],s=n.parentNode;null==s||"BR"!==n.nodeName||eS(n,i,e)||s.removeChild(n)}}n.takeRecords()}null!==i&&(u&&e2(i),J&&td(e)&&i.insertRawText(c))})}finally{e_=!1}}function eE(e){let t=e._observer;null!==t&&ew(e,t.takeRecords(),t)}function eT(e){0===eb&&tv(e).addEventListener("textInput",ex,!0),e._observer=new MutationObserver((t,n)=>{ew(e,t,n)})}function eC(e,t){let n=e.__mode,r=e.__format,i=e.__style,s=t.__mode,o=t.__format,l=t.__style;return!(null!==n&&n!==s||null!==r&&r!==o||null!==i&&i!==l)}function ek(e,t){let n=e.mergeWithSibling(t),r=rO()._normalizedNodes;return r.add(e.__key),r.add(t.__key),n}function eA(e){let t,n,r=e;if(""!==r.__text||!r.isSimpleText()||r.isUnmergeable()){for(;null!==(t=r.getPreviousSibling())&&nQ(t)&&t.isSimpleText()&&!t.isUnmergeable();){if(""!==t.__text){eC(t,r)&&(r=ek(t,r));break}t.remove()}for(;null!==(n=r.getNextSibling())&&nQ(n)&&n.isSimpleText()&&!n.isUnmergeable();){if(""!==n.__text){eC(r,n)&&(r=ek(r,n));break}n.remove()}}else r.remove()}function eP(e){return eN(e.anchor),eN(e.focus),e}function eN(e){for(;"element"===e.type;){let t,n;let r=e.getNode(),i=e.offset;if(i===r.getChildrenSize()?(t=r.getChildAtIndex(i-1),n=!0):(t=r.getChildAtIndex(i),n=!1),nQ(t)){e.set(t.__key,n?t.getTextContentSize():0,"text",!0);break}if(!rq(t))break;e.set(t.__key,n?t.getChildrenSize():0,"element",!0)}}let eF=1;function eO(){eF=1}let eD="function"==typeof queueMicrotask?queueMicrotask:e=>{Promise.resolve().then(e)};function eL(e){let t=document.activeElement;if(!tC(t))return!1;let n=t.nodeName;return rX(eZ(e))&&("INPUT"===n||"TEXTAREA"===n||"true"===t.contentEditable&&null==eB(t))}function eI(e,t,n){let r=e.getRootElement();try{return null!==r&&r.contains(t)&&r.contains(n)&&null!==t&&!eL(t)&&eR(t)===e}catch(e){return!1}}function eM(e){return e instanceof io}function eR(e){let t=e;for(;null!=t;){let e=eB(t);if(eM(e))return e;t=tp(t)}return null}function eB(e){return e?e.__lexicalEditor:null}function ej(e){return e.isToken()||e.isSegmented()}function eU(e){return tk(e)&&3===e.nodeType}function eV(e){let t=e;for(;null!=t;){if(eU(t))return t;t=t.firstChild}return null}function ez(e,t,n){let r=ec[t];if(null!==n&&(e&r)==(n&r))return e;let i=e^r;return"subscript"===t?i&=~ec.superscript:"superscript"===t?i&=~ec.subscript:"lowercase"===t?(i&=~ec.uppercase,i&=~ec.capitalize):"uppercase"===t?(i&=~ec.lowercase,i&=~ec.capitalize):"capitalize"===t&&(i&=~ec.lowercase,i&=~ec.uppercase),i}function e$(e){return nQ(e)||nM(e)||rX(e)}function eW(e){let t=e.getParent();if(null!==t){let n=e.getWritable(),r=t.getWritable(),i=e.getPreviousSibling(),s=e.getNextSibling();
1if(null===i){if(null!==s){let e=s.getWritable();r.__first=s.__key,e.__prev=null}else r.__first=null}else{let e=i.getWritable();if(null!==s){let t=s.getWritable();t.__prev=e.__key,e.__next=t.__key}else e.__next=null;n.__prev=null}if(null===s){if(null!==i){let e=i.getWritable();r.__last=i.__key,e.__next=null}else r.__last=null}else{let e=s.getWritable();if(null!==i){let t=i.getWritable();t.__next=e.__key,e.__prev=t.__key}else e.__prev=null;n.__next=null}r.__size--,n.__parent=null}}function eK(e){rN();let t=e.getLatest(),n=t.__parent,r=rF(),i=rO(),s=r._nodeMap,o=i._dirtyElements;null!==n&&function(e,t,n){let r=e;for(;null!==r;){if(n.has(r))return;let e=t.get(r);if(void 0===e)break;n.set(r,!1),r=e.__parent}}(n,s,o);let l=t.__key;i._dirtyType=1,rq(e)?o.set(l,!0):i._dirtyLeaves.add(l)}function eH(e){rP();let t=rO(),n=t._compositionKey;if(e!==n){if(t._compositionKey=e,null!==n){let e=eY(n);null!==e&&e.getWritable()}if(null!==e){let t=eY(e);null!==t&&t.getWritable()}}}function eG(){return rA()?null:rO()._compositionKey}function eY(e,t){let n=(t||rF())._nodeMap.get(e);return void 0===n?null:n}function eq(e,t){let n=eJ(e,rO());return void 0!==n?eY(n,t):null}function eJ(e,t){return e[`__lexicalKey_${t._key}`]}function eZ(e,t){let n=e;for(;null!=n;){let e=eq(n,t);if(null!==e)return e;n=tp(n)}return null}function eX(e){let t=Object.assign({},e._decorators);return e._pendingDecorators=t,t}function eQ(e){return e.read(()=>e0().getTextContent())}function e0(){return e1(rF())}function e1(e){return e._nodeMap.get("root")}function e2(e){rP();let t=rF();null!==e&&(e.dirty=!0,e.setCachedNodes(null)),t._selection=e}function e3(e){let t=rO(),n=function(e,t){let n=e;for(;null!=n;){let e=eJ(n,t);if(void 0!==e)return e;n=tp(n)}return null}(e,t);return null===n?e===t.getRootElement()?eY("root"):null:eY(n)}function e8(e,t){return t?e.getTextContentSize():0}function e5(e){return/[\uD800-\uDBFF][\uDC00-\uDFFF]/g.test(e)}function e7(e){let t=[],n=e;for(;null!==n;)t.push(n),n=n._parentEditor;return t}function e4(){return Math.random().toString(36).replace(/[^a-z]+/g,"").substr(0,5)}function e9(e){return eU(e)?e.nodeValue:null}function e6(e,t,n){let r=tE(tv(t));if(null===r)return;let i=r.anchorNode,{anchorOffset:s,focusOffset:o}=r;if(null!==i){let t=e9(i),r=eZ(i);if(null!==t&&nQ(r)){if(t===ei&&n){let e=n.length;t=n,s=e,o=e}null!==t&&te(r,t,s,o,e)}}}function te(e,t,n,r,i){let s=e;if(s.isAttached()&&(i||!s.isDirty())){let o=s.isComposing(),l=t;(o||i)&&t[t.length-1]===ei&&(l=t.slice(0,-1));let a=s.getTextContent();if(i||l!==a){if(""===l){if(eH(null),X||Q||er)s.remove();else{let e=rO();setTimeout(()=>{e.update(()=>{s.isAttached()&&s.remove()})},20)}return}let t=s.getParent(),i=rg(),a=s.getTextContentSize(),u=eG(),c=s.getKey();if(s.isToken()||null!==u&&c===u&&!o||n6(i)&&(null!==t&&!t.canInsertTextBefore()&&0===i.anchor.offset||i.anchor.key===e.__key&&0===i.anchor.offset&&!s.canInsertTextBefore()&&!o||i.focus.key===e.__key&&i.focus.offset===a&&!s.canInsertTextAfter()&&!o))return void s.markDirty();let d=rp();if(!n6(d)||null===n||null===r)return void s.setTextContent(l);if(d.setTextNodeRange(s,n,s,r),s.isSegmented()){let e=nX(s.getTextContent());s.replace(e),s=e}s.setTextContent(l)}}}function tt(e){return"ArrowLeft"===e}function tn(e){return"ArrowRight"===e}function tr(e){return"Backspace"===e}function ti(e){return"Delete"===e}function ts(e,t,n){return"a"===e.toLowerCase()&&(q?t:n)}function to(e){let t=e0();if(n6(e)){let t=e.anchor,n=e.focus,r=t.getNode().getTopLevelElementOrThrow().getParentOrThrow();return t.set(r.getKey(),0,"element"),n.set(r.getKey(),r.getChildrenSize(),"element"),eP(e),e}{let e=t.select(0,t.getChildrenSize());return e2(eP(e)),e}}function tl(e,t){void 0===e.__lexicalClassNameCache&&(e.__lexicalClassNameCache={});let n=e.__lexicalClassNameCache,r=n[t];if(void 0!==r)return r;let i=e[t];if("string"==typeof i){let e=ev(i);return n[t]=e,e}return i}function ta(e,t,n,r,i){if(0===n.size)return;let s=r.__type,o=r.__key,l=t.get(s);void 0===l&&ey(33,s);let a=l.klass,u=e.get(a);void 0===u&&(u=new Map,e.set(a,u));let c=u.get(o),d="destroyed"===c&&"created"===i;(void 0===c||d)&&u.set(o,d?"updated":i)}function tu(e,t,n){let r=e.getParent(),i=n,s=e;return null!==r&&(t&&0===n?(i=s.getIndexWithinParent(),s=r):t||n!==s.getChildrenSize()||(i=s.getIndexWithinParent()+1,s=r)),s.getChildAtIndex(t?i-1:i)}function tc(e,t){let n=e.offset;if("element"===e.type)return tu(e.getNode(),t,n);{let r=e.getNode();if(t&&0===n||!t&&n===r.getTextContentSize()){let e=t?r.getPreviousSibling():r.getNextSibling();return null===e?tu(r.getParentOrThrow(),t,r.getIndexWithinParent()+(t?0:1)):e}}return null}function td(e){let t=tv(e).event,n=t&&t.inputType;return"insertFromPaste"===n||"insertFromPasteAsQuotation"===n}function th(e){return!r0(e)&&!e.isLastChild()&&!e.isInline()}function tf(e,t){let n=e._keyToDOMMap.get(t);return void 0===n&&ey(75,t),n}function tp(e){let t=e.assignedSlot||e.parentElement;return tA(t)?t.host:t}function tg(e){return tk(e)&&9===e.nodeType?e:tC(e)?e.ownerDocument:null}function tm(e,t){let n=e.getParent();for(;null!==n;){if(n.is(t))return!0;n=n.getParent()}return!1}function ty(e){let t=tg(e);return t?t.defaultView:null}function tv(e){let t=e._window;return null===t&&ey(78),t}function t_(e){return r0(e)||rq(e)&&e.isShadowRoot()}function tb(e){let t=rO(),n=e.constructor.getType(),r=t._nodes.get(n);void 0===r&&ey(200,e.constructor.name,n);let{replace:i,replaceWithKlass:s}=r;if(null!==i){let t=i(e),r=t.constructor;return null!==s?t instanceof s||ey(201,s.name,s.getType(),r.name,r.getType(),e.constructor.name,n):t instanceof e.constructor&&r!==e.constructor||ey(202,r.name,r.getType(),e.constructor.name,n),t.__key===e.__key&&ey(203,e.constructor.name,n,r.name,r.getType()),t}return e}function tx(e,t){!r0(e.getParent())||rq(t)||rX(t)||ey(99)}function tS(e){return(rX(e)||rq(e)&&!e.canBeEmpty())&&!e.isInline()}function tw(e,t,n){n.style.removeProperty("caret-color"),t._blockCursorElement=null;let r=e.parentElement;null!==r&&r.removeChild(e)}function tE(e){return G?(e||window).getSelection():null}function tT(e){return tC(e)&&"A"===e.tagName}function tC(e){return tk(e)&&1===e.nodeType}
1function tk(e){return"object"==typeof e&&null!==e&&"nodeType"in e&&"number"==typeof e.nodeType}function tA(e){return tk(e)&&11===e.nodeType}function tP(e){let t=RegExp(/^(a|abbr|acronym|b|cite|code|del|em|i|ins|kbd|label|output|q|ruby|s|samp|span|strong|sub|sup|time|u|tt|var|#text)$/,"i");return null!==e.nodeName.match(t)}function tN(e){let t=RegExp(/^(address|article|aside|blockquote|canvas|dd|div|dl|dt|fieldset|figcaption|figure|footer|form|h1|h2|h3|h4|h5|h6|header|hr|li|main|nav|noscript|ol|p|pre|section|table|td|tfoot|ul|video)$/,"i");return null!==e.nodeName.match(t)}function tF(e){if(rX(e)&&!e.isInline())return!0;if(!rq(e)||t_(e))return!1;let t=e.getFirstChild(),n=null===t||nM(t)||nQ(t)||t.isInline();return!e.isInline()&&!1!==e.canBeEmpty()&&n}function tO(e,t){let n=e;for(;null!==n&&null!==n.getParent()&&!t(n);)n=n.getParentOrThrow();return t(n)?n:null}function tD(){return rO()}let tL=new WeakMap,tI=new Map;function tM(e){if(!e._readOnly&&e.isEmpty())return tI;e._readOnly||ey(192);let t=tL.get(e);return t||(t=function(e){let t=new Map;for(let[n,r]of e._nodeMap){let e=r.__type,i=t.get(e);i||(i=new Map,t.set(e,i)),i.set(n,r)}return t}(e),tL.set(e,t)),t}function tR(e){let t=e.constructor.clone(e);return t.afterCloneFrom(e),t}function tB(e,t){let n=(parseInt(e.style.paddingInlineStart,10)||0)/40;t.setIndent(n)}let tj,tU,tV,tz,t$,tW,tK,tH,tG,tY,tq="",tJ="",tZ=null,tX="",tQ="",t0=!1,t1=!1,t2=null;function t3(e,t){let n=tK.get(e);if(null!==t){let n=no(e);n.parentNode===t&&t.removeChild(n)}if(tH.has(e)||tU._keyToDOMMap.delete(e),rq(n)){let e=nr(n,tK);t8(e,0,e.length-1,null)}void 0!==n&&ta(tY,tV,tz,n,"destroyed")}function t8(e,t,n,r){let i=t;for(;i<=n;++i){let t=e[i];void 0!==t&&t3(t,r)}}function t5(e,t){e.setProperty("text-align",t)}function t7(e,t){let n=tj.theme.indent;if("string"==typeof n){let r=e.classList.contains(n);t>0&&!r?e.classList.add(n):t<1&&r&&e.classList.remove(n)}let r=getComputedStyle(e).getPropertyValue("--lexical-indent-base-value")||"40px";e.style.setProperty("padding-inline-start",0===t?"":`calc(${t} * ${r})`)}function t4(e,t){let n=e.style;0===t?t5(n,""):1===t?t5(n,"left"):2===t?t5(n,"center"):3===t?t5(n,"right"):4===t?t5(n,"justify"):5===t?t5(n,"start"):6===t&&t5(n,"end")}function t9(e,t){let n=tH.get(e);void 0===n&&ey(60);let r=n.createDOM(tj,tU);if(function(e,t,n){let r=n._keyToDOMMap;t[`__lexicalKey_${n._key}`]=e,r.set(e,t)}(e,r,tU),nQ(n)?r.setAttribute("data-lexical-text","true"):rX(n)&&r.setAttribute("data-lexical-decorator","true"),rq(n)){let e=n.__indent,t=n.__size;0!==e&&t7(r,e),0!==t&&function(e,t,n,r){let i=tJ;tJ="",t6(e,n,0,t,n.getDOMSlot(r)),nn(n,r),tJ=i}(nr(n,tH),t-1,n,r);let i=n.__format;0!==i&&t4(r,i),n.isInline()||nt(null,n,r),th(n)&&(tq+="\n\n",tQ+="\n\n")}else{let t=n.getTextContent();if(rX(n)){let t=n.decorate(tU,tj);null!==t&&ni(e,t),r.contentEditable="false"}else nQ(n)&&(n.isDirectionless()||(tJ+=t));tq+=t,tQ+=t}return null!==t&&t.insertChild(r),ta(tY,tV,tz,n,"created"),r}function t6(e,t,n,r,i){let s=tq;tq="";let o=n;for(;o<=r;++o){t9(e[o],i);let t=tH.get(e[o]);null!==t&&nQ(t)&&(null===tZ&&(tZ=t.getFormat()),""===tX&&(tX=t.getStyle()))}th(t)&&(tq+="\n\n"),i.element.__lexicalTextContent=tq,tq=s+tq}function ne(e,t){if(e){let n=e.__last;if(n){let e=t.get(n);if(e)return nM(e)?"line-break":rX(e)&&e.isInline()?"decorator":null}return"empty"}return null}function nt(e,t,n){let r=ne(e,tK),i=ne(t,tH);r!==i&&t.getDOMSlot(n).setManagedLineBreak(i)}function nn(e,t){var n;let r=t.__lexicalDirTextContent||"",i=t.__lexicalDir||"";if(r!==tJ||i!==t2){let r=""===tJ,s=r?t2:(n=tJ,ea.test(n)?"rtl":eu.test(n)?"ltr":null);if(s!==i){let n=t.classList,o=tj.theme,l=null!==i?o[i]:void 0,a=null!==s?o[s]:void 0;if(void 0!==l){if("string"==typeof l){let e=ev(l);l=o[i]=e}n.remove(...l)}if(null===s||r&&"ltr"===s)t.removeAttribute("dir");else{if(void 0!==a){if("string"==typeof a){let e=ev(a);a=o[s]=e}void 0!==a&&n.add(...a)}t.dir=s}t1||(e.getWritable().__dir=s)}t2=s,t.__lexicalDirTextContent=tJ,t.__lexicalDir=s}}function nr(e,t){let n=[],r=e.__first;for(;null!==r;){let e=t.get(r);void 0===e&&ey(101),n.push(r),r=e.__next}return n}function ni(e,t){let n=tU._pendingDecorators,r=tU._decorators;if(null===n){if(r[e]===t)return;n=eX(tU)}n[e]=t}function ns(e){let t=e.nextSibling;return null!==t&&t===tU._blockCursorElement&&(t=t.nextSibling),t}function no(e){let t=tG.get(e);return void 0===t&&ey(75,e),t}let nl=Object.freeze({}),na=[["keydown",function(e,t){if(nu=e.timeStamp,nc=e.key,t.isComposing())return;let{key:n,shiftKey:r,ctrlKey:i,metaKey:s,altKey:o}=e;if(!rz(t,v,e)&&null!=n){if(nv&&tr(nc))return rK(t,()=>{nT(t,n_)}),nv=!1,void(n_="");
1if(!tn(n)||i||s||o){if(tn(n)&&!o&&!r&&(i||s))rz(t,b,e);else if(!tt(n)||i||s||o){if(tt(n)&&!o&&!r&&(i||s))rz(t,S,e);else if("ArrowUp"!==n||i||s){if("ArrowDown"!==n||i||s){if("Enter"===n&&r)nm=!0,rz(t,T,e);else if(" "===n)rz(t,C,e);else if(q&&i&&"o"===n.toLowerCase())e.preventDefault(),nm=!0,rz(t,a,!0);else if("Enter"!==n||r){if(q?!o&&!s&&(tr(n)||"h"===n.toLowerCase()&&i):!(i||o||s)&&tr(n))tr(n)?rz(t,k,e):(e.preventDefault(),rz(t,l,!0));else if("Escape"===n)rz(t,A,e);else if(q?!(r||o||s)&&(ti(n)||"d"===n.toLowerCase()&&i):!(i||o||s)&&ti(n))ti(n)?rz(t,P,e):(e.preventDefault(),rz(t,l,!1));else if(tr(n)&&(q?o:i))e.preventDefault(),rz(t,f,!0);else if(ti(n)&&(q?o:i))e.preventDefault(),rz(t,f,!1);else if(q&&s&&tr(n))e.preventDefault(),rz(t,p,!0);else if(q&&s&&ti(n))e.preventDefault(),rz(t,p,!1);else if("b"===n.toLowerCase()&&!o&&(q?s:i))e.preventDefault(),rz(t,g,"bold");else if("u"===n.toLowerCase()&&!o&&(q?s:i))e.preventDefault(),rz(t,g,"underline");else if("i"===n.toLowerCase()&&!o&&(q?s:i))e.preventDefault(),rz(t,g,"italic");else if("Tab"!==n||o||i||s){if("z"===n.toLowerCase()&&!r&&(q?s:i))e.preventDefault(),rz(t,m,void 0);else if(q?"z"===n.toLowerCase()&&s&&r:"y"===n.toLowerCase()&&i||"z"===n.toLowerCase()&&i&&r)e.preventDefault(),rz(t,y,void 0);else{let o=t._editorState._selection;null===o||n6(o)?!J&&ts(n,s,i)&&(e.preventDefault(),rz(t,V,e)):!r&&"c"===n.toLowerCase()&&(q?s:i)?(e.preventDefault(),rz(t,j,e)):!r&&"x"===n.toLowerCase()&&(q?s:i)?(e.preventDefault(),rz(t,U,e)):ts(n,s,i)&&(e.preventDefault(),rz(t,V,e))}}else rz(t,N,e)}else nm=!1,rz(t,T,e)}else rz(t,E,e)}else rz(t,w,e)}else rz(t,x,e)}else rz(t,_,e);(i||r||o||s)&&rz(t,H,e)}}],["pointerdown",function(e,t){let n=e.target,r=e.pointerType;tk(n)&&"touch"!==r&&0===e.button&&rK(t,()=>{rX(eZ(n))||(ng=!0)})}],["compositionstart",function(e,t){rK(t,()=>{let n=rp();if(n6(n)&&!t.isComposing()){let r=n.anchor,i=n.anchor.getNode();eH(r.key),(e.timeStamp<nu+30||"element"===r.type||!n.isCollapsed()||i.getFormat()!==n.format||nQ(i)&&i.getStyle()!==n.style)&&rz(t,c,es)}})}],["compositionend",function(e,t){J?ny=!0:!Q&&(X||er)?(nv=!0,n_=e.data):rK(t,()=>{nT(t,e.data)})}],["input",function(e,t){e.stopPropagation(),rK(t,()=>{let n=rp(),r=e.data,i=nE(e);if(null!=r&&n6(n)&&nx(n,i,r,e.timeStamp,!1)){ny&&(nT(t,r),ny=!1);let i=n.anchor.getNode(),s=tE(tv(t));if(null===s)return;let o=n.isBackward(),l=o?n.anchor.offset:n.focus.offset,a=o?n.focus.offset:n.anchor.offset;Z&&!n.isCollapsed()&&nQ(i)&&null!==s.anchorNode&&i.getTextContent().slice(0,l)+r+i.getTextContent().slice(l+a)===e9(s.anchorNode)||rz(t,c,r);let u=r.length;J&&u>1&&"insertCompositionText"===e.inputType&&!t.isComposing()&&(n.anchor.offset-=u),X||Q||er||!t.isComposing()||(nu=0,eH(null))}else e6(!1,t,null!==r?r:void 0),ny&&(nT(t,r||void 0),ny=!1);rP(),eE(rO())},{event:e}),nh=null}],["click",function(e,t){rK(t,()=>{let n=rp(),r=tE(tv(t)),i=rg();if(r){if(n6(n)){let t=n.anchor,s=t.getNode();if("element"===t.type&&0===t.offset&&n.isCollapsed()&&!r0(s)&&1===e0().getChildrenSize()&&s.getTopLevelElementOrThrow().isEmpty()&&null!==i&&n.is(i))r.removeAllRanges(),n.dirty=!0;else if(3===e.detail&&!n.isCollapsed()&&s!==n.focus.getNode()){let e=function(e,t){let n=e;for(;n!==e0()&&null!=n;){if(t(n))return n;n=n.getParent()}return null}(s,e=>rq(e)&&!e.isInline());rq(e)&&e.select(0)}}else if("touch"===e.pointerType){let n=r.anchorNode;(tC(n)||eU(n))&&e2(rf(i,r,t,e))}}rz(t,o,e)})}],["cut",nl],["copy",nl],["dragstart",nl],["dragover",nl],["dragend",nl],["paste",nl],["focus",nl],["blur",nl],["drop",nl]];Z&&na.push(["beforeinput",(e,t)=>(function(e,t){let n=e.inputType,r=nE(e);"deleteCompositionText"===n||J&&td(t)||"insertCompositionText"===n||rK(t,()=>{var i;let s=rp();if("deleteContentBackward"===n){if(null===s){let e=rg();if(!n6(e))return;e2(e.clone())}if(n6(s)){let n=s.anchor.key===s.focus.key;if(i=e.timeStamp,"MediaLast"===nc&&i<nu+30&&t.isComposing()&&n){if(eH(null),nu=0,setTimeout(()=>{rK(t,()=>{eH(null)})},30),n6(s)){let e=s.anchor.getNode();e.markDirty(),s.format=e.getFormat(),nQ(e)||ey(142),s.style=e.getStyle()}}else{eH(null),e.preventDefault();let r=s.anchor.getNode(),i=r.getTextContent(),o=r.canInsertTextAfter(),a=0===s.anchor.offset&&s.focus.offset===i.length,u=en&&n&&!a&&o;u&&s.isCollapsed()&&(u=!rX(tc(s.anchor,!0))),u||rz(t,l,!0)}return}}if(!n6(s))return;let o=e.data;null!==nh&&e6(!1,t,nh),s.dirty&&null===nh||!s.isCollapsed()||r0(s.anchor.getNode())||null===r||s.applyDOMRange(r),nh=null;
1let v=s.anchor,_=s.focus,b=v.getNode(),x=_.getNode();if("insertText"!==n&&"insertTranspose"!==n)switch(e.preventDefault(),n){case"insertFromYank":case"insertFromDrop":case"insertReplacementText":rz(t,c,e);break;case"insertFromComposition":eH(null),rz(t,c,e);break;case"insertLineBreak":eH(null),rz(t,a,!1);break;case"insertParagraph":eH(null),nm&&!Q?(nm=!1,rz(t,a,!1)):rz(t,u,void 0);break;case"insertFromPaste":case"insertFromPasteAsQuotation":rz(t,d,e);break;case"deleteByComposition":(b!==x||rq(b)||rq(x)||!b.isToken()||!x.isToken())&&rz(t,h,e);break;case"deleteByDrag":case"deleteByCut":rz(t,h,e);break;case"deleteContent":rz(t,l,!1);break;case"deleteWordBackward":rz(t,f,!0);break;case"deleteWordForward":rz(t,f,!1);break;case"deleteHardLineBackward":case"deleteSoftLineBackward":rz(t,p,!0);break;case"deleteContentForward":case"deleteHardLineForward":case"deleteSoftLineForward":rz(t,p,!1);break;case"formatStrikeThrough":rz(t,g,"strikethrough");break;case"formatBold":rz(t,g,"bold");break;case"formatItalic":rz(t,g,"italic");break;case"formatUnderline":rz(t,g,"underline");break;case"historyUndo":rz(t,m,void 0);break;case"historyRedo":rz(t,y,void 0)}else{if("\n"===o)e.preventDefault(),rz(t,a,!1);else if("\n\n"===o)e.preventDefault(),rz(t,u,void 0);else if(null==o&&e.dataTransfer){let t=e.dataTransfer.getData("text/plain");e.preventDefault(),s.insertRawText(t)}else null!=o&&nx(s,r,o,e.timeStamp,!0)?(e.preventDefault(),rz(t,c,o)):nh=o;nd=e.timeStamp}})})(e,t)]);let nu=0,nc=null,nd=0,nh=null,nf=new WeakMap,np=!1,ng=!1,nm=!1,ny=!1,nv=!1,n_="",nb=[0,"",0,"root",0];function nx(e,t,n,r,i){let s=e.anchor,o=e.focus,l=s.getNode(),a=rO(),u=tE(tv(a)),c=null!==u?u.anchorNode:null,d=s.key,h=a.getElementByKey(d),f=n.length;return d!==o.key||!nQ(l)||(!i&&(!Z||nd<r+50)||l.isDirty()&&f<2||e5(n))&&s.offset!==o.offset&&!l.isComposing()||ej(l)||l.isDirty()&&f>1||(i||!Z)&&null!==h&&!l.isComposing()&&c!==eV(h)||null!==u&&null!==t&&(!t.collapsed||t.startContainer!==u.anchorNode||t.startOffset!==u.anchorOffset)||l.getFormat()!==e.format||l.getStyle()!==e.style||function(e,t){if(t.isSegmented())return!0;if(!e.isCollapsed())return!1;let n=e.anchor.offset,r=t.getParentOrThrow(),i=t.isToken();return 0===n?!t.canInsertTextBefore()||!r.canInsertTextBefore()&&!t.isComposing()||i||function(e){let t=e.getPreviousSibling();return(nQ(t)||rq(t)&&t.isInline())&&!t.canInsertTextAfter()}(t):n===t.getTextContentSize()&&(!t.canInsertTextAfter()||!r.canInsertTextAfter()&&!t.isComposing()||i)}(e,l)}function nS(e,t){return eU(e)&&null!==e.nodeValue&&0!==t&&t!==e.nodeValue.length}function nw(e,t,n){let{anchorNode:r,anchorOffset:s,focusNode:o,focusOffset:l}=e;np&&(np=!1,nS(r,s)&&nS(o,l))||rK(t,()=>{if(!n)return void e2(null);if(!eI(t,r,o))return;let a=rp();if(n6(a)){let n=a.anchor,r=n.getNode();if(a.isCollapsed()){"Range"===e.type&&e.anchorNode===e.focusNode&&(a.dirty=!0);let i=tv(t).event,s=i?i.timeStamp:performance.now(),[o,l,u,c,d]=nb,h=e0(),f=!1===t.isComposing()&&""===h.getTextContent();if(s<d+200&&n.offset===u&&n.key===c)a.format=o,a.style=l;else if("text"===n.type)nQ(r)||ey(141),a.format=r.getFormat(),a.style=r.getStyle();else if("element"===n.type&&!f){rq(r)||ey(259);let e=n.getNode();a.style="",e.isEmpty()?(a.format=e.getTextFormat(),a.style=e.getTextStyle()):a.format=0}}else{let e=n.key,t=a.focus.key,r=a.getNodes(),i=r.length,o=a.isBackward(),u=o?l:s,c=o?s:l,d=o?t:e,h=o?e:t,f=2047,p=!1;for(let e=0;e<i;e++){let t=r[e],n=t.getTextContentSize();if(nQ(t)&&0!==n&&!(0===e&&t.__key===d&&u===n||e===i-1&&t.__key===h&&0===c)&&(p=!0,0==(f&=t.getFormat())))break}a.format=p?f:0}}rz(t,i,void 0)})}function nE(e){if(!e.getTargetRanges)return null;let t=e.getTargetRanges();return 0===t.length?null:t[0]}function nT(e,t){let n=e._compositionKey;if(eH(null),null!==n&&null!=t){if(""===t){let t=eY(n),r=eV(e.getElementByKey(n));return void(null!==r&&null!==r.nodeValue&&nQ(t)&&te(t,r.nodeValue,null,null,!0))}if("\n"===t[t.length-1]){let t=rp();if(n6(t)){let n=t.focus;return t.anchor.set(n.key,n.offset,n.type),void rz(e,T,null)}}}e6(!0,e,t)}function nC(e){let t=e.__lexicalEventHandles;return void 0===t&&(t=[],e.__lexicalEventHandles=t),t}let nk=new Map;function nA(e){let t=function(e){let t=ty(e);return t?t.getSelection():null}(e.target);if(null===t)return;let n=eR(t.anchorNode);
1if(null===n)return;ng&&(ng=!1,rK(n,()=>{let r=rg(),i=t.anchorNode;(tC(i)||eU(i))&&e2(rf(r,t,n,e))}));let r=e7(n),i=r[r.length-1],s=i._key,o=nk.get(s),l=o||i;l!==n&&nw(t,l,!1),nw(t,n,!0),n!==i?nk.set(s,n):o&&nk.delete(s)}function nP(e){e._lexicalHandled=!0}function nN(e){return!0===e._lexicalHandled}function nF(e,t,n){rP();let r=e.__key,i=e.getParent();if(null===i)return;let s=function(e){let t=rp();if(!n6(t)||!rq(e))return t;let{anchor:n,focus:r}=t,i=n.getNode(),s=r.getNode();return tm(i,e)&&n.set(e.__key,0,"element"),tm(s,e)&&r.set(e.__key,0,"element"),t}(e),o=!1;if(n6(s)&&t){let t=s.anchor,n=s.focus;t.key===r&&(rv(t,e,i,e.getPreviousSibling(),e.getNextSibling()),o=!0),n.key===r&&(rv(n,e,i,e.getPreviousSibling(),e.getNextSibling()),o=!0)}else rt(s)&&t&&e.isSelected()&&e.selectPrevious();if(n6(s)&&t&&!o){let t=e.getIndexWithinParent();eW(e),rm(s,i,t,-1)}else eW(e);n||t_(i)||i.canBeEmpty()||!i.isEmpty()||nF(i,t),t&&r0(i)&&i.isEmpty()&&i.selectEnd()}class nO{static getType(){ey(64,this.name)}static clone(e){ey(65,this.name)}afterCloneFrom(e){this.__parent=e.__parent,this.__next=e.__next,this.__prev=e.__prev}constructor(e){this.__type=this.constructor.getType(),this.__parent=null,this.__prev=null,this.__next=null,function(e,t){if(null!=t)return void(e.__key=t);rP(),rN();let n=rO(),r=rF(),i=""+eF++;r._nodeMap.set(i,e),rq(e)?n._dirtyElements.set(i,!0):n._dirtyLeaves.add(i),n._cloneNotNeeded.add(i),n._dirtyType=1,e.__key=i}(this,e)}getType(){return this.__type}isInline(){ey(137,this.constructor.name)}isAttached(){let e=this.__key;for(;null!==e;){if("root"===e)return!0;let t=eY(e);if(null===t)break;e=t.__parent}return!1}isSelected(e){let t=e||rp();if(null==t)return!1;let n=t.getNodes().some(e=>e.__key===this.__key);if(nQ(this))return n;if(n6(t)&&"element"===t.anchor.type&&"element"===t.focus.type){if(t.isCollapsed())return!1;let e=this.getParent();if(rX(this)&&this.isInline()&&e){let n=t.isBackward()?t.focus:t.anchor,r=n.getNode();if(n.offset===r.getChildrenSize()&&r.is(e)&&r.getLastChildOrThrow().is(this))return!1}}return n}getKey(){return this.__key}getIndexWithinParent(){let e=this.getParent();if(null===e)return -1;let t=e.getFirstChild(),n=0;for(;null!==t;){if(this.is(t))return n;n++,t=t.getNextSibling()}return -1}getParent(){let e=this.getLatest().__parent;return null===e?null:eY(e)}getParentOrThrow(){let e=this.getParent();return null===e&&ey(66,this.__key),e}getTopLevelElement(){let e=this;for(;null!==e;){let t=e.getParent();if(t_(t))return rq(e)||e===this&&rX(e)||ey(194),e;e=t}return null}getTopLevelElementOrThrow(){let e=this.getTopLevelElement();return null===e&&ey(67,this.__key),e}getParents(){let e=[],t=this.getParent();for(;null!==t;)e.push(t),t=t.getParent();return e}getParentKeys(){let e=[],t=this.getParent();for(;null!==t;)e.push(t.__key),t=t.getParent();return e}getPreviousSibling(){let e=this.getLatest().__prev;return null===e?null:eY(e)}getPreviousSiblings(){let e=[],t=this.getParent();if(null===t)return e;let n=t.getFirstChild();for(;null!==n&&!n.is(this);)e.push(n),n=n.getNextSibling();return e}getNextSibling(){let e=this.getLatest().__next;return null===e?null:eY(e)}getNextSiblings(){let e=[],t=this.getNextSibling();for(;null!==t;)e.push(t),t=t.getNextSibling();return e}getCommonAncestor(e){let t=this.getParents(),n=e.getParents();rq(this)&&t.unshift(this),rq(e)&&n.unshift(e);let r=t.length,i=n.length;if(0===r||0===i||t[r-1]!==n[i-1])return null;let s=new Set(n);for(let e=0;e<r;e++){let n=t[e];if(s.has(n))return n}return null}is(e){return null!=e&&this.__key===e.__key}isBefore(e){if(this===e)return!1;if(e.isParentOf(this))return!0;if(this.isParentOf(e))return!1;let t=this.getCommonAncestor(e),n=0,r=0,i=this;for(;;){let e=i.getParentOrThrow();if(e===t){n=i.getIndexWithinParent();break}i=e}for(i=e;;){let e=i.getParentOrThrow();if(e===t){r=i.getIndexWithinParent();break}i=e}return n<r}isParentOf(e){let t=this.__key;if(t===e.__key)return!1;let n=e;for(;null!==n;){if(n.__key===t)return!0;n=n.getParent()}return!1}getNodesBetween(e){let t=this.isBefore(e),n=[],r=new Set,i=this;for(;null!==i;){let s=i.__key;if(r.has(s)||(r.add(s),n.push(i)),i===e)break;let o=rq(i)?t?i.getFirstChild():i.getLastChild():null;if(null!==o){i=o;continue}let l=t?i.getNextSibling():i.getPreviousSibling();if(null!==l){i=l;continue}let a=i.getParentOrThrow();if(r.has(a.__key)||n.push(a),a===e)break;let u=null,c=a;do{if(null===c&&ey(68),u=t?c.getNextSibling():c.getPreviousSibling(),null===(c=c.getParent()))break;null!==u||r.has(c.__key)||n.push(c)}while(null===u);i=u}return t||n.reverse(),n}isDirty(){let e=rO()._dirtyLeaves;return null!==e&&e.has(this.__key)}getLatest(){let e=eY(this.__key);return null===e&&ey(113),e}getWritable(){rP();let e=rF(),t=rO(),n=e._nodeMap,r=this.__key,i=this.getLatest(),s=t._cloneNotNeeded,o=rp();if(null!==o&&o.setCachedNodes(null),s.has(r))return eK(i),i;let l=tR(i);return s.add(r),eK(l),n.set(r,l),l}getTextContent(){return""}getTextContentSize(){return this.getTextContent().length}createDOM(e,t){ey(70)}updateDOM(e,t,n){ey(71)}exportDOM(e){return{element:this.createDOM(e._config,e)}}exportJSON(){return{type:this.__type,version:1}}static importJSON(e){ey(18,this.name)}updateFromJSON(e){return this}static transform(){return null}remove(e){nF(this,!0,e)}replace(e,t){rP();let n=rp();null!==n&&(n=n.clone()),tx(this,e);let r=this.getLatest(),i=this.__key,s=e.__key,o=e.getWritable(),l=this.getParentOrThrow().getWritable(),a=l.__size;eW(o);let u=r.getPreviousSibling(),c=r.getNextSibling(),d=r.__prev,h=r.__next,f=r.__parent;if((nF(r,!1,!0),null===u)?l.__first=s:u.getWritable().__next=s,(o.__prev=d,null===c)?l.__last=s:c.getWritable().__prev=s,o.__next=h,o.__parent=f,l.__size=a,t&&(rq(this)&&rq(o)||ey(139),this.getChildren().forEac
1h(e=>{o.append(e)})),n6(n)){e2(n);let e=n.anchor,t=n.focus;e.key===i&&n4(e,o),t.key===i&&n4(t,o)}return eG()===i&&eH(s),o}insertAfter(e,t=!0){rP(),tx(this,e);let n=this.getWritable(),r=e.getWritable(),i=r.getParent(),s=rp(),o=!1,l=!1;if(null!==i){let t=e.getIndexWithinParent();if(eW(r),n6(s)){let e=i.__key,n=s.anchor,r=s.focus;o="element"===n.type&&n.key===e&&n.offset===t+1,l="element"===r.type&&r.key===e&&r.offset===t+1}}let a=this.getNextSibling(),u=this.getParentOrThrow().getWritable(),c=r.__key,d=n.__next;if(null===a?u.__last=c:a.getWritable().__prev=c,u.__size++,n.__next=c,r.__next=d,r.__prev=n.__key,r.__parent=n.__parent,t&&n6(s)){let e=this.getIndexWithinParent();rm(s,u,e+1);let t=u.__key;o&&s.anchor.set(t,e+2,"element"),l&&s.focus.set(t,e+2,"element")}return e}insertBefore(e,t=!0){rP(),tx(this,e);let n=this.getWritable(),r=e.getWritable(),i=r.__key;eW(r);let s=this.getPreviousSibling(),o=this.getParentOrThrow().getWritable(),l=n.__prev,a=this.getIndexWithinParent();null===s?o.__first=i:s.getWritable().__next=i,o.__size++,n.__prev=i,r.__prev=l,r.__next=n.__key,r.__parent=n.__parent;let u=rp();return t&&n6(u)&&rm(u,this.getParentOrThrow(),a),e}isParentRequired(){return!1}createParentElementNode(){return r4()}selectStart(){return this.selectPrevious()}selectEnd(){return this.selectNext(0,0)}selectPrevious(e,t){rP();let n=this.getPreviousSibling(),r=this.getParentOrThrow();if(null===n)return r.select(0,0);if(rq(n))return n.select();if(!nQ(n)){let e=n.getIndexWithinParent()+1;return r.select(e,e)}return n.select(e,t)}selectNext(e,t){rP();let n=this.getNextSibling(),r=this.getParentOrThrow();if(null===n)return r.select();if(rq(n))return n.select(0,0);if(!nQ(n)){let e=n.getIndexWithinParent();return r.select(e,e)}return n.select(e,t)}markDirty(){this.getWritable()}reconcileObservedMutation(e,t){this.markDirty()}}class nD extends nO{static getType(){return"linebreak"}static clone(e){return new nD(e.__key)}constructor(e){super(e)}getTextContent(){return"\n"}createDOM(){return document.createElement("br")}updateDOM(){return!1}static importDOM(){return{br:e=>(function(e){let t=e.parentElement;if(null!==t&&tN(t)){let n=t.firstChild;if(n===e||n.nextSibling===e&&nR(n)){let n=t.lastChild;if(n===e||n.previousSibling===e&&nR(n))return!0}}return!1})(e)||function(e){let t=e.parentElement;if(null!==t&&tN(t)){let n=t.firstChild;if(n===e||n.nextSibling===e&&nR(n))return!1;let r=t.lastChild;if(r===e||r.previousSibling===e&&nR(r))return!0}return!1}(e)?null:{conversion:nL,priority:0}}}static importJSON(e){return nI().updateFromJSON(e)}}function nL(e){return{node:nI()}}function nI(){return tb(new nD)}function nM(e){return e instanceof nD}function nR(e){return eU(e)&&/^( |\t|\r?\n)+$/.test(e.textContent||"")}function nB(e,t){return 16&t?"code":128&t?"mark":32&t?"sub":64&t?"sup":null}function nj(e,t){return 1&t?"strong":2&t?"em":"span"}function nU(e,t,n,r,i){let s=r.classList,o=tl(i,"base");void 0!==o&&s.add(...o);let l=!1,a=8&t&&4&t;for(let e in void 0!==(o=tl(i,"underlineStrikethrough"))&&(8&n&&4&n?(l=!0,a||s.add(...o)):a&&s.remove(...o)),ec){let r=ec[e];if(void 0!==(o=tl(i,e))){if(n&r){if(l&&("underline"===e||"strikethrough"===e)){t&r&&s.remove(...o);continue}t&r&&(!a||"underline"!==e)&&"strikethrough"!==e||s.add(...o)}else t&r&&s.remove(...o)}}}function nV(e,t,n){let r=t.firstChild,i=n.isComposing(),s=e+(i?ei:"");if(null==r)t.textContent=s;else{let e=r.nodeValue;if(e!==s){if(i||J){let[t,n,i]=function(e,t){let n=e.length,r=t.length,i=0,s=0;for(;i<n&&i<r&&e[i]===t[i];)i++;for(;s+i<n&&s+i<r&&e[n-s-1]===t[r-s-1];)s++;return[i,n-i-s,t.slice(i,r-s)]}(e,s);0!==n&&r.deleteData(t,n),r.insertData(t,i)}else r.nodeValue=s}}}function nz(e,t,n,r,i,s){nV(i,e,t);let o=s.theme.text;void 0!==o&&nU(0,0,r,e,o)}function n$(e,t){let n=document.createElement(t);return n.appendChild(e),n}class nW extends nO{static getType(){return"text"}static clone(e){return new nW(e.__text,e.__key)}afterCloneFrom(e){super.afterCloneFrom(e),this.__text=e.__text,this.__format=e.__format,this.__style=e.__style,this.__mode=e.__mode,this.__detail=e.__detail}constructor(e="",t){super(t),this.__text=e,this.__format=0,this.__style="",this.__mode=0,this.__detail=0}getFormat(){return this.getLatest().__format}getDetail(){return this.getLatest().__detail}getMode(){return eg[this.getLatest().__mode]}getStyle(){return this.getLatest().__style}isToken(){return 1===this.getLatest().__mode}isComposing(){return this.__key===eG()}isSegmented(){return 2===this.getLatest().__mode}isDirectionless(){return!!(1&this.getLatest().__detail)}isUnmergeable(){return!!(2&this.getLatest().__detail)}hasFormat(e){let t=ec[e];return!!(this.getFormat()&t)}isSimpleText(){return"text"===this.__type&&0===this.__mode}getTextContent(){return this.getLatest().__text}getFormatFlags(e,t){return ez(this.getLatest().__format,e,t)}canHaveFormat(){return!0}createDOM(e,t){let n=this.__format,r=nB(0,n),i=nj(0,n),s=null===r?i:r,o=document.createElement(s),l=o;
1this.hasFormat("code")&&o.setAttribute("spellcheck","false"),null!==r&&(l=document.createElement(i),o.appendChild(l)),nz(l,this,0,n,this.__text,e);let a=this.__style;return""!==a&&(o.style.cssText=a),o}updateDOM(e,t,n){let r=this.__text,i=e.__format,s=this.__format,o=nB(0,i),l=nB(0,s),a=nj(0,i),u=nj(0,s);if((null===o?a:o)!==(null===l?u:l))return!0;if(o===l&&a!==u){let e=t.firstChild;null==e&&ey(48);let i=document.createElement(u);return nz(i,this,0,s,r,n),t.replaceChild(i,e),!1}let c=t;null!==l&&null!==o&&null==(c=t.firstChild)&&ey(49),nV(r,c,this);let d=n.theme.text;void 0!==d&&i!==s&&nU(0,i,s,c,d);let h=e.__style,f=this.__style;return h!==f&&(t.style.cssText=f),!1}static importDOM(){return{"#text":()=>({conversion:nY,priority:0}),b:()=>({conversion:nH,priority:0}),code:()=>({conversion:nZ,priority:0}),em:()=>({conversion:nZ,priority:0}),i:()=>({conversion:nZ,priority:0}),s:()=>({conversion:nZ,priority:0}),span:()=>({conversion:nK,priority:0}),strong:()=>({conversion:nZ,priority:0}),sub:()=>({conversion:nZ,priority:0}),sup:()=>({conversion:nZ,priority:0}),u:()=>({conversion:nZ,priority:0})}}static importJSON(e){return nX().updateFromJSON(e)}updateFromJSON(e){return super.updateFromJSON(e).setTextContent(e.text).setFormat(e.format).setDetail(e.detail).setMode(e.mode).setStyle(e.style)}
1exportDOM(e){let{element:t}=super.exportDOM(e);return tC(t)||ey(132),t.style.whiteSpace="pre-wrap",this.hasFormat("bold")&&(t=n$(t,"b")),this.hasFormat("italic")&&(t=n$(t,"i")),this.hasFormat("strikethrough")&&(t=n$(t,"s")),this.hasFormat("underline")&&(t=n$(t,"u")),{element:t}}exportJSON(){return{detail:this.getDetail(),format:this.getFormat(),mode:this.getMode(),style:this.getStyle(),text:this.getTextContent(),...super.exportJSON()}}selectionTransform(e,t){}setFormat(e){let t=this.getWritable();return t.__format="string"==typeof e?ec[e]:e,t}setDetail(e){let t=this.getWritable();return t.__detail="string"==typeof e?ed[e]:e,t}setStyle(e){let t=this.getWritable();return t.__style=e,t}toggleFormat(e){let t=ez(this.getFormat(),e,null);return this.setFormat(t)}toggleDirectionless(){let e=this.getWritable();return e.__detail^=1,e}toggleUnmergeable(){let e=this.getWritable();return e.__detail^=2,e}setMode(e){let t=ep[e];if(this.__mode===t)return this;let n=this.getWritable();return n.__mode=t,n}setTextContent(e){if(this.__text===e)return this;let t=this.getWritable();return t.__text=e,t}select(e,t){rP();let n=e,r=t,i=rp(),s=this.getTextContent(),o=this.__key;if("string"==typeof s){let e=s.length;void 0===n&&(n=e),void 0===r&&(r=e)}else n=0,r=0;if(!n6(i))return rc(o,n,o,r,"text","text");{let e=eG();e!==i.anchor.key&&e!==i.focus.key||eH(o),i.setTextNodeRange(this,n,this,r)}return i}selectStart(){return this.select(0,0)}selectEnd(){let e=this.getTextContentSize();return this.select(e,e)}spliceText(e,t,n,r){let i=this.getWritable(),s=i.__text,o=n.length,l=e;l<0&&(l=o+l)<0&&(l=0);let a=rp();if(r&&n6(a)){let t=e+o;a.setTextNodeRange(i,t,i,t)}let u=s.slice(0,l)+n+s.slice(l+t);return i.__text=u,i}canInsertTextBefore(){return!0}canInsertTextAfter(){return!0}splitText(...e){let t;rP();let n=this.getLatest(),r=n.getTextContent(),i=n.__key,s=eG(),o=new Set(e),l=[],a=r.length,u="";for(let e=0;e<a;e++)""!==u&&o.has(e)&&(l.push(u),u=""),u+=r[e];""!==u&&l.push(u);let c=l.length;if(0===c)return[];if(l[0]===r)return[n];let d=l[0],h=n.getParent(),f=n.getFormat(),p=n.getStyle(),g=n.__detail,m=!1;n.isSegmented()?((t=nX(d)).__format=f,t.__style=p,t.__detail=g,m=!0):(t=n.getWritable()).__text=d;let y=rp(),v=[t],_=d.length;for(let e=1;e<c;e++){let t=l[e],n=t.length,r=nX(t).getWritable();r.__format=f,r.__style=p,r.__detail=g;let o=r.__key,a=_+n;if(n6(y)){let e=y.anchor,t=y.focus;e.key===i&&"text"===e.type&&e.offset>_&&e.offset<=a&&(e.key=o,e.offset-=_,y.dirty=!0),t.key===i&&"text"===t.type&&t.offset>_&&t.offset<=a&&(t.key=o,t.offset-=_,y.dirty=!0)}s===i&&eH(o),_=a,v.push(r)}if(null!==h){!function(e){let t=e.getPreviousSibling(),n=e.getNextSibling();null!==t&&eK(t),null!==n&&eK(n)}(this);let e=h.getWritable(),t=this.getIndexWithinParent();m?(e.splice(t,0,v),this.remove()):e.splice(t,1,v),n6(y)&&rm(y,h,t,c-1)}return v}mergeWithSibling(e){let t=e===this.getPreviousSibling();t||e===this.getNextSibling()||ey(50);let n=this.__key,r=e.__key,i=this.__text,s=i.length;eG()===r&&eH(n);let o=rp();if(n6(o)){let i=o.anchor,l=o.focus;null!==i&&i.key===r&&r_(i,t,n,e,s),null!==l&&l.key===r&&r_(l,t,n,e,s)}let l=e.__text,a=t?l+i:i+l;this.setTextContent(a);let u=this.getWritable();return e.remove(),u}isTextEntity(){return!1}}function nK(e){return{forChild:n0(e.style),node:null}}function nH(e){let t="normal"===e.style.fontWeight;return{forChild:n0(e.style,t?void 0:"bold"),node:null}}let nG=new WeakMap;function nY(e){null===e.parentElement&&ey(129);let t=e.textContent||"";if(null!==function(e){let t,n=e.parentNode,r=[e];for(;null!==n&&void 0===(t=nG.get(n))&&!function(e){if(!tC(e))return!1;if("PRE"===e.nodeName)return!0;let t=e.style.whiteSpace;return"string"==typeof t&&t.startsWith("pre")}(n);)r.push(n),n=n.parentNode;let i=void 0===t?n:t;for(let e=0;e<r.length;e++)nG.set(r[e],i);return i}(e)){let e=t.split(/(\r?\n|\t)/),n=[],r=e.length;for(let t=0;t<r;t++){let r=e[t];"\n"===r||"\r\n"===r?n.push(nI()):"	"===r?n.push(n2()):""!==r&&n.push(nX(r))}return{node:n}}if(""===(t=t.replace(/\r/g,"").replace(/[ \t\n]+/g," ")))return{node:null};if(" "===t[0]){let n=e,r=!0;for(;null!==n&&null!==(n=nq(n,!1));){let e=n.textContent||"";if(e.length>
10){/[ \t\n]$/.test(e)&&(t=t.slice(1)),r=!1;break}}r&&(t=t.slice(1))}if(" "===t[t.length-1]){let n=e,r=!0;for(;null!==n&&null!==(n=nq(n,!0));)if((n.textContent||"").replace(/^( |\t|\r?\n)+/,"").length>0){r=!1;break}r&&(t=t.slice(0,t.length-1))}return""===t?{node:null}:{node:nX(t)}}function nq(e,t){let n=e;for(;;){let e;for(;null===(e=t?n.nextSibling:n.previousSibling);){let e=n.parentElement;if(null===e)return null;n=e}if(tC(n=e)){let e=n.style.display;if(""===e&&!tP(n)||""!==e&&!e.startsWith("inline"))return null}let r=n;for(;null!==(r=t?n.firstChild:n.lastChild);)n=r;if(eU(n))return n;if("BR"===n.nodeName)return null}}let nJ={code:"code",em:"italic",i:"italic",s:"strikethrough",strong:"bold",sub:"subscript",sup:"superscript",u:"underline"};function nZ(e){let t=nJ[e.nodeName.toLowerCase()];return void 0===t?{node:null}:{forChild:n0(e.style,t),node:null}}function nX(e=""){return tb(new nW(e))}function nQ(e){return e instanceof nW}function n0(e,t){let n=e.fontWeight,r=e.textDecoration.split(" "),i="700"===n||"bold"===n,s=r.includes("line-through"),o="italic"===e.fontStyle,l=r.includes("underline"),a=e.verticalAlign;return e=>(nQ(e)&&(i&&!e.hasFormat("bold")&&e.toggleFormat("bold"),s&&!e.hasFormat("strikethrough")&&e.toggleFormat("strikethrough"),o&&!e.hasFormat("italic")&&e.toggleFormat("italic"),l&&!e.hasFormat("underline")&&e.toggleFormat("underline"),"sub"!==a||e.hasFormat("subscript")||e.toggleFormat("subscript"),"super"!==a||e.hasFormat("superscript")||e.toggleFormat("superscript"),t&&!e.hasFormat(t)&&e.toggleFormat(t)),e)}class n1 extends nW{static getType(){return"tab"}static clone(e){return new n1(e.__key)}constructor(e){super("	",e),this.__detail=2}static importDOM(){return null}createDOM(e){let t=super.createDOM(e),n=tl(e.theme,"tab");return void 0!==n&&t.classList.add(...n),t}static importJSON(e){return n2().updateFromJSON(e)}setTextContent(e){return"	"!==e&&""!==e&&ey(126),super.setTextContent(e)}setDetail(e){return 2!==e&&ey(127),this}setMode(e){return"normal"!==e&&ey(128),this}canInsertTextBefore(){return!1}canInsertTextAfter(){return!1}}function n2(){return tb(new n1)}function n3(e){return e instanceof n1}class n8{constructor(e,t,n){this._selection=null,this.key=e,this.offset=t,this.type=n}is(e){return this.key===e.key&&this.offset===e.offset&&this.type===e.type}isBefore(e){let t=this.getNode(),n=e.getNode(),r=this.offset,i=e.offset;if(rq(t)){let e=t.getDescendantByIndex(r);t=null!=e?e:t}if(rq(n)){let e=n.getDescendantByIndex(i);n=null!=e?e:n}return t===n?r<i:t.isBefore(n)}getNode(){let e=eY(this.key);return null===e&&ey(20),e}set(e,t,n,r){let i=this._selection,s=this.key;r&&this.key===e&&this.offset===t&&this.type===n||(this.key=e,this.offset=t,this.type=n,rA()||(eG()===s&&eH(e),null!==i&&(i.setCachedNodes(null),i.dirty=!0)))}}function n5(e,t,n){return new n8(e,t,n)}function n7(e,t){let n=t.__key,r=e.offset,i="element";if(nQ(t)){i="text";let e=t.getTextContentSize();r>e&&(r=e)}else if(!rq(t)){let e=t.getNextSibling();if(nQ(e))n=e.__key,r=0,i="text";else{let e=t.getParent();e&&(n=e.__key,r=t.getIndexWithinParent()+1)}}e.set(n,r,i)}function n4(e,t){if(rq(t)){let n=t.getLastDescendant();rq(n)||nQ(n)?n7(e,n):n7(e,t)}else n7(e,t)}class n9{constructor(e){this._cachedNodes=null,this._nodes=e,this.dirty=!1}getCachedNodes(){return this._cachedNodes}setCachedNodes(e){this._cachedNodes=e}is(e){if(!rt(e))return!1;let t=this._nodes,n=e._nodes;return t.size===n.size&&Array.from(t).every(e=>n.has(e))}isCollapsed(){return!1}isBackward(){return!1}getStartEndPoints(){return null}add(e){this.dirty=!0,this._nodes.add(e),this._cachedNodes=null}delete(e){this.dirty=!0,this._nodes.delete(e),this._cachedNodes=null}clear(){this.dirty=!0,this._nodes.clear(),this._cachedNodes=null}has(e){return this._nodes.has(e)}clone(){return new n9(new Set(this._nodes))}extract(){return this.getNodes()}insertRawText(e){}insertText(){}insertNodes(e){let t;let n=this.getNodes(),r=n.length,i=n[r-1];if(nQ(i))t=i.select();else{let e=i.getIndexWithinParent()+1;t=i.getParentOrThrow().select(e,e)}t.insertNodes(e);for(let e=0;e<r;e++)n[e].remove()}getNodes(){let e=this._cachedNodes;if(null!==e)return e;let t=this._nodes,n=[];for(let e of t){let t=eY(e);null!==t&&n.push(t)}return rA()||(this._cachedNodes=n),n}getTextContent(){let e=this.getNodes(),t="";for(let n=0;n<e.length;n++)t+=e[n].getTextContent();return t}}function n6(e){return e instanceof re}class re{constructor(e,t,n,r){this.anchor=e,this.focus=t,e._selection=this,t._selection=this,this._cachedNodes=null,this.format=n,this.style=r,this.dirty=!1}getCachedNodes(){return this._cachedNodes}setCachedNodes(e){this._cachedNodes=e}is(e){return!!n6(e)&&this.anchor.is(e.anchor)&&this.focus.is(e.focus)&&this.format===e.format&&this.style===e.style}isCollapsed(){return this.anchor.is(this.focus)}getNodes(){let e;let t=this._cachedNodes;if(null!==t)return t;let n=this.anchor,r=this.focus,i=n.isBefore(r),s=i?n:r,o=i?r:n,l=s.getNode(),a=o.getNode(),u=rq(l)&&s.offset>0&&s.offset>=l.getChildrenSize(),c=s.offset,d=o.offset;if(rq(l)){let e=l.getDescendantByIndex(c);l=null!=e?e:l}if(rq(a)){let e=a.getDescendantByIndex(d);null!==e&&e!==l&&a.getChildAtIndex(d)===e&&(e=e.getPreviousSibling()),a=null!=e?e:a}if(l.is(a))e=rq(l)&&l.getChildrenSize()>0?[]:[l];else if(e=l.getNodesBetween(a),u){let t=e.findIndex(e=>!e.is(l)&&!e.isBefore(l));e.splice(0,t)}return rA()||(this._cachedNodes=e),e}setTextNodeRange(e,t,n,r){this.anchor.set(e.__key,t,"text"),this.focus.set(n.__key,r,"text")}getTextContent(){let e=this.getNodes();if(0===e.length)return"";let t=e[0],n=e[e.length-1],r=this.anchor,i=this.focus,s=r.isBefore(i),[o,l]=rr(this),a="",u=!0;for(let c=0;c<e.length;c++){let d=e[c];if(rq(d)&&!d.isInline())u||(a+="\n"),u=!d.isEmpty();else if(u=!1,nQ(d)){let e=d.getTextContent();d===t?d===n?"element"===r.type&&"element"===i.type&&i.offset!==r.offset||(e=o<l?e.slice(o,l):e.slice(l,o)):e=s?e.slice(o):e.slice(l):d===n&&(e=s?e.slice(0,l):e.slice(0,o)),a+=e}else!rX(d)&&!nM(d)||d===n&&this.isCollapsed()||(a+=d.getTextContent())}return a}
1applyDOMRange(e){let t=rO(),n=t.getEditorState()._selection,r=ra(e.startContainer,e.startOffset,e.endContainer,e.endOffset,t,n);if(null===r)return;let[i,s]=r;this.anchor.set(i.key,i.offset,i.type,!0),this.focus.set(s.key,s.offset,s.type,!0),eP(this)}clone(){let e=this.anchor,t=this.focus;return new re(n5(e.key,e.offset,e.type),n5(t.key,t.offset,t.type),this.format,this.style)}toggleFormat(e){this.format=ez(this.format,e,null),this.dirty=!0}setStyle(e){this.style=e,this.dirty=!0}hasFormat(e){let t=ec[e];return!!(this.format&t)}insertRawText(e){let t=e.split(/(\r?\n|\t)/),n=[],r=t.length;for(let e=0;e<r;e++){let r=t[e];"\n"===r||"\r\n"===r?n.push(nI()):"	"===r?n.push(n2()):n.push(nX(r))}this.insertNodes(n)}insertText(e){let t=this.anchor,n=this.focus,r=this.format,i=this.style,s=t,o=n;!this.isCollapsed()&&n.isBefore(t)&&(s=n,o=t),"element"===s.type&&function(e,t,n,r){let i=e.getNode(),s=i.getChildAtIndex(e.offset),o=nX(),l=r0(i)?r4().append(o):o;o.setFormat(n),o.setStyle(r),null===s?i.append(l):s.insertBefore(l),e.is(t)&&t.set(o.__key,0,"text"),e.set(o.__key,0,"text")}(s,o,r,i);let l=s.offset,a=o.offset,u=this.getNodes(),c=u.length,d=u[0];nQ(d)||ey(26);let h=d.getTextContent().length,f=d.getParentOrThrow(),p=u[c-1];if(1===c&&"element"===o.type&&(a=h,o.set(s.key,a,"text")),this.isCollapsed()&&l===h&&
1(d.isSegmented()||d.isToken()||!d.canInsertTextAfter()||!f.canInsertTextAfter()&&null===d.getNextSibling())){let t=d.getNextSibling();if(nQ(t)&&t.canInsertTextBefore()&&!ej(t)||((t=nX()).setFormat(r),t.setStyle(i),f.canInsertTextAfter()?d.insertAfter(t):f.insertAfter(t)),t.select(0,0),d=t,""!==e)return void this.insertText(e)}else if(this.isCollapsed()&&0===l&&(d.isSegmented()||d.isToken()||!d.canInsertTextBefore()||!f.canInsertTextBefore()&&null===d.getPreviousSibling())){let t=d.getPreviousSibling();if(nQ(t)&&!ej(t)||((t=nX()).setFormat(r),f.canInsertTextBefore()?d.insertBefore(t):f.insertBefore(t)),t.select(),d=t,""!==e)return void this.insertText(e)}else if(d.isSegmented()&&l!==h){let e=nX(d.getTextContent());e.setFormat(r),d.replace(e),d=e}else if(!this.isCollapsed()&&""!==e){let t=p.getParent();if(!f.canInsertTextBefore()||!f.canInsertTextAfter()||rq(t)&&(!t.canInsertTextBefore()||!t.canInsertTextAfter()))return this.insertText(""),rl(this.anchor,this.focus,null),void this.insertText(e)}if(1===c){if(d.isToken()){let t=nX(e);return t.select(),void d.replace(t)}let t=d.getFormat(),n=d.getStyle();if(l!==a||t===r&&n===i){if(n3(d)){let t=nX(e);return t.setFormat(r),t.setStyle(i),t.select(),void d.replace(t)}}else{if(""!==d.getTextContent()){let t=nX(e);if(t.setFormat(r),t.setStyle(i),t.select(),0===l)d.insertBefore(t,!1);else{let[e]=d.splitText(l);e.insertAfter(t,!1)}return void(t.isComposing()&&"text"===this.anchor.type&&(this.anchor.offset-=e.length))}d.setFormat(r),d.setStyle(i)}let s=a-l;""===(d=d.spliceText(l,s,e,!0)).getTextContent()?d.remove():"text"===this.anchor.type&&(d.isComposing()?this.anchor.offset-=e.length:(this.format=t,this.style=n))}else{let t=new Set([...d.getParentKeys(),...p.getParentKeys()]),n=rq(d)?d:d.getParentOrThrow(),r=rq(p)?p:p.getParentOrThrow(),i=p;if(!n.is(r)&&r.isInline())do i=r,r=r.getParentOrThrow();while(r.isInline());if("text"===o.type&&(0!==a||""===p.getTextContent())||"element"===o.type&&p.getIndexWithinParent()<a){if(nQ(p)&&!p.isToken()&&a!==p.getTextContentSize()){if(p.isSegmented()){let e=nX(p.getTextContent());p.replace(e),p=e}r0(o.getNode())||"text"!==o.type||(p=p.spliceText(0,a,"")),t.add(p.__key)}else{let e=p.getParentOrThrow();e.canBeEmpty()||1!==e.getChildrenSize()?p.remove():e.remove()}}else t.add(p.__key);let s=r.getChildren(),f=new Set(u),g=n.is(r),m=n.isInline()&&null===d.getNextSibling()?n:d;for(let e=s.length-1;e>=0;e--){let t=s[e];if(t.is(d)||rq(t)&&t.isParentOf(d))break;t.isAttached()&&(!f.has(t)||t.is(i)?g||m.insertAfter(t,!1):t.remove())}if(!g){let e=r,n=null;for(;null!==e;){let r=e.getChildren(),i=r.length;(0===i||r[i-1].is(n))&&(t.delete(e.__key),n=e),e=e.getParent()}}if(d.isToken()){if(l===h)d.select();else{let t=nX(e);t.select(),d.replace(t)}}else""===(d=d.spliceText(l,h-l,e,!0)).getTextContent()?d.remove():d.isComposing()&&"text"===this.anchor.type&&(this.anchor.offset-=e.length);for(let e=1;e<c;e++){let n=u[e],r=n.__key;t.has(r)||n.remove()}}}removeText(){if(this.isCollapsed())return;let{anchor:e,focus:t}=this,n=this.getNodes(),r=this.isBackward()?t:e,i=this.isBackward()?e:t,s=r.getNode(),o=i.getNode(),l=tO(s,tF),a=tO(o,tF);for(let e of(nQ(s)&&s.isToken()&&r.offset<s.getTextContentSize()&&r.set(s.getKey(),0,"text"),i.offset>0&&nQ(o)&&o.isToken()&&i.set(o.getKey(),o.getTextContentSize(),"text"),n))tm(s,e)||tm(o,e)||e.getKey()===s.getKey()||e.getKey()===o.getKey()||e.remove();let u=(e,t)=>{if(""===e.getTextContent())e.remove();else if(0!==t&&ej(e)){let t=nX(e.getTextContent());return t.setFormat(e.getFormat()),t.setStyle(e.getStyle()),e.replace(t)}};if(s===o&&nQ(s)){let n=Math.abs(t.offset-e.offset);return s.spliceText(r.offset,n,"",!0),void u(s,n)}if(nQ(s)){let e=s.getTextContentSize()-r.offset;s.spliceText(r.offset,e,""),s=u(s,e)||s}nQ(o)&&(o.spliceText(0,i.offset,""),o=u(o,i.offset)||o),s.isAttached()&&nQ(s)?s.selectEnd():o.isAttached()&&nQ(o)&&o.selectStart(),rq(l)&&rq(a)&&l!==a&&(l.append(...a.getChildren()),a.remove(),i.set(r.key,r.offset,r.type))}formatText(e,t=null){if(this.isCollapsed())return this.toggleFormat(e),void eH(null);let n=this.getNodes(),r=[];for(let e of n)nQ(e)&&r.push(e);let i=t=>
1{n.forEach(n=>{if(rq(n)){let r=n.getFormatFlags(e,t);n.setTextFormat(r)}})},s=r.length;if(0===s)return this.toggleFormat(e),eH(null),void i(t);let o=this.anchor,l=this.focus,a=this.isBackward(),u=a?l:o,c=a?o:l,d=0,h=r[0],f="element"===u.type?0:u.offset;if("text"===u.type&&f===h.getTextContentSize()&&(d=1,h=r[1],f=0),null==h)return;let p=h.getFormatFlags(e,t);i(p);let g=s-1,m=r[g],y="text"===c.type?c.offset:m.getTextContentSize();if(h.is(m)){if(f===y)return;if(ej(h)||0===f&&y===h.getTextContentSize())h.setFormat(p);else{let e=h.splitText(f,y),t=0===f?e[0]:e[1];t.setFormat(p),"text"===u.type&&u.set(t.__key,0,"text"),"text"===c.type&&c.set(t.__key,y-f,"text")}return void(this.format=p)}0===f||ej(h)||([,h]=h.splitText(f),f=0),h.setFormat(p);let v=m.getFormatFlags(e,p);y>0&&(y===m.getTextContentSize()||ej(m)||([m]=m.splitText(y)),m.setFormat(v));for(let t=d+1;t<g;t++){let n=r[t],i=n.getFormatFlags(e,v);n.setFormat(i)}"text"===u.type&&u.set(h.__key,f,"text"),"text"===c.type&&c.set(m.__key,y,"text"),this.format=p|v}insertNodes(e){var t;if(0===e.length)return;if("root"===this.anchor.key){this.insertParagraph();let t=rp();return n6(t)||ey(134),t.insertNodes(e)}let n=(this.isBackward()?this.focus:this.anchor).getNode(),r=tO(n,tF),i=e[e.length-1];if(rq(r)&&"__language"in r){if("__language"in e[0])this.insertText(e[0].getTextContent());else{let t=rx(this);r.splice(t,0,e),i.selectEnd()}return}if(!e.some(e=>(rq(e)||rX(e))&&!e.isInline())){rq(r)||ey(211,n.constructor.name,n.getType());let t=rx(this);return r.splice(t,0,e),void i.selectEnd()}let s=function(e){let t=r4(),n=null;for(let r=0;r<e.length;r++){let i=e[r],s=nM(i);if(s||rX(i)&&i.isInline()||rq(i)&&i.isInline()||nQ(i)||i.isParentRequired()){if(null===n&&(n=i.createParentElementNode(),t.append(n),s))continue;null!==n&&n.append(i)}else t.append(i),n=null}return t}(e),o=s.getLastDescendant(),l=s.getChildren(),a=rq(r)&&r.isEmpty()?null:this.insertParagraph(),u=l[l.length-1],c=l[0];rq(t=c)&&tF(t)&&!t.isEmpty()&&rq(r)&&(!r.isEmpty()||r.canMergeWhenEmpty())&&(rq(r)||ey(211,n.constructor.name,n.getType()),r.append(...c.getChildren()),c=l[1]),c&&(null===r&&ey(212,n.constructor.name,n.getType()),function(e,t,n){let r=t.getParentOrThrow().getLastChild(),i=t,s=[t];for(;i!==r;)i.getNextSibling()||ey(140),s.push(i=i.getNextSibling());let o=e;for(let e of s)o=o.insertAfter(e)}(r,c));let d=tO(o,tF);a&&rq(d)&&(a.canMergeWhenEmpty()||tF(u))&&(d.append(...a.getChildren()),a.remove()),rq(r)&&r.isEmpty()&&r.remove(),o.selectEnd();let h=rq(r)?r.getLastChild():null;nM(h)&&d!==r&&h.remove()}insertParagraph(){if("root"===this.anchor.key){let e=r4();return e0().splice(this.anchor.offset,0,[e]),e.select(),e}let e=rx(this),t=tO(this.anchor.getNode(),tF);rq(t)||ey(213);let n=t.getChildAtIndex(e),r=n?[n,...n.getNextSiblings()]:[],i=t.insertNewAfter(this,!1);return i?(i.append(...r),i.selectStart(),i):null}insertLineBreak(e){let t=nI();if(this.insertNodes([t]),e){let e=t.getParentOrThrow(),n=t.getIndexWithinParent();e.select(n,n)}}extract(){let e=this.getNodes(),t=e.length,n=t-1,r=this.anchor,i=this.focus,s=e[0],o=e[n],[l,a]=rr(this);if(0===t)return[];if(1===t){if(nQ(s)&&!this.isCollapsed()){let e=l>a?a:l,t=s.splitText(e,l>a?l:a),n=0===e?t[0]:t[1];return null!=n?[n]:[]}return[s]}let u=r.isBefore(i);if(nQ(s)){let t=u?l:a;t===s.getTextContentSize()?e.shift():0!==t&&([,s]=s.splitText(t),e[0]=s)}if(nQ(o)){let t=o.getTextContent().length,r=u?a:l;0===r?e.pop():r!==t&&([o]=o.splitText(r),e[n]=o)}return e}modify(e,t,n){let r=this.focus,i=this.anchor,s="move"===e,o=tc(r,t);if(rX(o)&&!o.isIsolated()){if(s&&o.isKeyboardSelectable()){let e=rh();return e.add(o.__key),void e2(e)}let e=t?o.getPreviousSibling():o.getNextSibling();if(nQ(e)){let n=e.__key,o=t?e.getTextContent().length:0;return r.set(n,o,"text"),void(s&&i.set(n,o,"text"))}{let n,l;let a=o.getParentOrThrow();return rq(e)?(l=e.__key,n=t?e.getChildrenSize():0):(n=o.getIndexWithinParent(),l=a.__key,t||n++),r.set(l,n,"element"),void(s&&i.set(l,n,"element"))}}let l=rO(),a=tE(tv(l));if(!a)return;let u=l._blockCursorElement,c=l._rootElement;if(null===c||null===u||!rq(o)||o.isInline()||o.canBeEmpty()||tw(u,l,c),function(e,t,n,r){e.modify(t,n,r)}(a,e,t?"backward":"forward",n),a.rangeCount>0){let e=a.getRangeAt(0),n=this.anchor.getNode(),r=r0(n)?n:function(e){let t=e.getParentOrThrow();for(;null!==t&&!t_(t);)t=t.getParentOrThrow();return t}(n);if(this.applyDOMRange(e),this.dirty=!0,!s){let n=this.getNodes(),i=[],s=!1;for(let e=0;e<n.length;e++){let t=n[e];tm(t,r)?i.push(t):s=!0}if(s&&i.length>0){if(t){let e=i[0];rq(e)?e.selectStart():e.getParentOrThrow().selectStart()}else{let e=i[i.length-1];rq(e)?e.selectEnd():e.getParentOrThrow().selectEnd()}}
1a.anchorNode===e.startContainer&&a.anchorOffset===e.startOffset||function(e){let t=e.focus,n=e.anchor,r=n.key,i=n.offset,s=n.type;n.set(t.key,t.offset,t.type,!0),t.set(r,i,s,!0)}(this)}}}forwardDeletion(e,t,n){if(!n&&("element"===e.type&&rq(t)&&e.offset===t.getChildrenSize()||"text"===e.type&&e.offset===t.getTextContentSize())){let e=t.getParent(),n=t.getNextSibling()||(null===e?null:e.getNextSibling());if(rq(n)&&n.isShadowRoot())return!0}return!1}deleteCharacter(e){let t=this.isCollapsed();if(this.isCollapsed()){let t=this.anchor,n=t.getNode();if(this.forwardDeletion(t,n,e))return;let r=this.focus,s=tc(r,e);if(rX(s)&&!s.isIsolated()){if(s.isKeyboardSelectable()&&rq(n)&&0===n.getChildrenSize()){n.remove();let e=rh();e.add(s.__key),e2(e)}else s.remove(),rO().dispatchCommand(i,void 0);return}if(!e&&rq(s)&&rq(n)&&n.isEmpty())return n.remove(),void s.selectStart();if(this.modify("extend",e,"character"),this.isCollapsed()){if(e&&0===t.offset&&("element"===t.type?t.getNode():t.getNode().getParentOrThrow()).collapseAtStart(this))return}else{let i="text"===r.type?r.getNode():null;if(n="text"===t.type?t.getNode():null,null!==i&&i.isSegmented()){let t=r.offset,s=i.getTextContentSize();if(i.is(n)||e&&t!==s||!e&&0!==t)return void ri(i,e,t)}else if(null!==n&&n.isSegmented()){let r=t.offset,s=n.getTextContentSize();if(n.is(i)||e&&0!==r||!e&&r!==s)return void ri(n,e,r)}!function(e,t){let n=e.anchor,r=e.focus,i=n.getNode();if(i===r.getNode()&&"text"===n.type&&"text"===r.type){let e=n.offset,s=r.offset,o=e<s,l=o?e:s,a=o?s:e,u=a-1;l!==u&&(e5(i.getTextContent().slice(l,a))||(t?r.set(r.key,u,r.type):n.set(n.key,u,n.type)))}}(this,e)}}if(this.removeText(),e&&!t&&this.isCollapsed()&&"element"===this.anchor.type&&0===this.anchor.offset){let e=this.anchor.getNode();e.isEmpty()&&r0(e.getParent())&&0===e.getIndexWithinParent()&&e.collapseAtStart(this)}}deleteLine(e){if(this.isCollapsed()){let t="element"===this.anchor.type;if(t&&this.insertText(" "),this.modify("extend",e,"lineboundary"),this.isCollapsed()&&0===this.anchor.offset&&this.modify("extend",e,"character"),t){let t=e?this.anchor:this.focus;t.set(t.key,t.offset+1,t.type)}}this.removeText()}deleteWord(e){if(this.isCollapsed()){let t=this.anchor,n=t.getNode();if(this.forwardDeletion(t,n,e))return;this.modify("extend",e,"word")}this.removeText()}isBackward(){return this.focus.isBefore(this.anchor)}getStartEndPoints(){return[this.anchor,this.focus]}}function rt(e){return e instanceof n9}function rn(e){let t=e.offset;if("text"===e.type)return t;let n=e.getNode();return t===n.getChildrenSize()?n.getTextContent().length:0}function rr(e){let t=e.getStartEndPoints();if(null===t)return[0,0];let[n,r]=t;return"element"===n.type&&"element"===r.type&&n.key===r.key&&n.offset===r.offset?[0,0]:[rn(n),rn(r)]}function ri(e,t,n){let r=e.getTextContent().split(/(?=\s)/g),i=r.length,s=0,o=0;for(let e=0;e<i;e++){let l=e===i-1;if(o=s,s+=r[e].length,t&&s===n||s>n||l){r.splice(e,1),l&&(o=void 0);break}}let l=r.join("").trim();""===l?e.remove():(e.setTextContent(l),e.select(o,o))}function rs(e,t,n,r){let i,s=t;if(tC(e)){let o=!1,l=e.childNodes,a=l.length,u=r._blockCursorElement;s===a&&(o=!0,s=a-1);let c=l[s],d=!1;if(c===u)c=l[s+1],d=!0;else if(null!==u){let n=u.parentNode;e===n&&t>Array.prototype.indexOf.call(n.children,u)&&s--}if(nQ(i=e3(c)))s=e8(i,o);else{let l=e3(e);if(null===l)return null;if(rq(l)){let a=r.getElementByKey(l.getKey());null===a&&ey(214);let u=l.getDOMSlot(a);[l,s]=u.resolveChildIndex(l,a,e,t),rq(l)||ey(215),o&&s>=l.getChildrenSize()&&(s=Math.max(0,l.getChildrenSize()-1));let c=l.getChildAtIndex(s);if(rq(c)&&function(e,t,n){let r=e.getParent();return null===n||null===r||!r.canBeEmpty()||r!==n.getNode()}(c,0,n)){let e=o?c.getLastDescendant():c.getFirstDescendant();l=null===e?c:rq(c=e)?c:c.getParentOrThrow(),s=0}nQ(c)?(i=c,l=null,s=e8(c,o)):c!==l&&o&&!d&&(rq(l)||ey(216),s=Math.min(l.getChildrenSize(),s+1))}else{let n=l.getIndexWithinParent();s=0===t&&rX(l)&&e3(e)===l?n:n+1,l=l.getParentOrThrow()}if(rq(l))return n5(l.__key,s,"element")}}else i=e3(e);return nQ(i)?n5(i.__key,s,"text"):null}function ro(e,t,n){let r=e.offset,i=e.getNode();if(0===r){let r=i.getPreviousSibling(),s=i.getParent();if(t){if((n||!t)&&null===r&&rq(s)&&s.isInline()){let t=s.getPreviousSibling();nQ(t)&&e.set(t.__key,t.getTextContent().length,"text")}}else rq(r)&&!n&&r.isInline()?e.set(r.__key,r.getChildrenSize(),"element"):nQ(r)&&e.set(r.__key,r.getTextContent().length,"text")}else if(r===i.getTextContent().length){let r=i.getNextSibling(),s=i.getParent();if(t&&rq(r)&&r.isInline())e.set(r.__key,0,"element");else if((n||t)&&null===r&&rq(s)&&s.isInline()&&!s.canInsertTextAfter()){let t=s.getNextSibling();nQ(t)&&e.set(t.__key,0,"text")}}}function rl(e,t,n){if("text"===e.type&&"text"===t.type){let r=e.isBefore(t),i=e.is(t);ro(e,r,i),ro(t,!r,i),i&&t.set(e.key,e.offset,e.type);let s=rO();
1if(s.isComposing()&&s._compositionKey!==e.key&&n6(n)){let r=n.anchor,i=n.focus;e.set(r.key,r.offset,r.type,!0),t.set(i.key,i.offset,i.type,!0)}}}function ra(e,t,n,r,i,s){if(null===e||null===n||!eI(i,e,n))return null;let o=rs(e,t,n6(s)?s.anchor:null,i);if(null===o)return null;let l=rs(n,r,n6(s)?s.focus:null,i);if(null===l)return null;if("element"===o.type&&"element"===l.type){let t=e3(e),r=e3(n);if(rX(t)&&rX(r))return null}return rl(o,l,s),[o,l]}function ru(e){return rq(e)&&!e.isInline()}function rc(e,t,n,r,i,s){let o=rF(),l=new re(n5(e,t,i),n5(n,r,s),0,"");return l.dirty=!0,o._selection=l,l}function rd(){return new re(n5("root",0,"element"),n5("root",0,"element"),0,"")}function rh(){return new n9(new Set)}function rf(e,t,n,r){let i,s,o,l;let a=n._window;if(null===a)return null;let u=r||a.event,c=u?u.type:void 0,d="selectionchange"===c,h=!e_&&(d||"beforeinput"===c||"compositionstart"===c||"compositionend"===c||"click"===c&&u&&3===u.detail||"drop"===c||void 0===c);if(n6(e)&&!h)return e.clone();if(null===t)return null;if(i=t.anchorNode,s=t.focusNode,o=t.anchorOffset,l=t.focusOffset,d&&n6(e)&&!eI(n,i,s))return e.clone();let f=ra(i,o,s,l,n,e);if(null===f)return null;let[p,g]=f;return new re(p,g,n6(e)?e.format:0,n6(e)?e.style:"")}function rp(){return rF()._selection}function rg(){return rO()._editorState._selection}function rm(e,t,n,r=1){let i=e.anchor,s=e.focus,o=i.getNode(),l=s.getNode();if(!t.is(o)&&!t.is(l))return;let a=t.__key;if(e.isCollapsed()){let t=i.offset;if(n<=t&&r>0||n<t&&r<0){let n=Math.max(0,t+r);i.set(a,n,"element"),s.set(a,n,"element"),ry(e)}}else{let o=e.isBackward(),l=o?s:i,u=l.getNode(),c=o?i:s,d=c.getNode();if(t.is(u)){let e=l.offset;(n<=e&&r>0||n<e&&r<0)&&l.set(a,Math.max(0,e+r),"element")}if(t.is(d)){let e=c.offset;(n<=e&&r>0||n<e&&r<0)&&c.set(a,Math.max(0,e+r),"element")}}ry(e)}function ry(e){let t=e.anchor,n=t.offset,r=e.focus,i=r.offset,s=t.getNode(),o=r.getNode();if(e.isCollapsed()){if(!rq(s))return;let e=s.getChildrenSize(),i=n>=e,o=i?s.getChildAtIndex(e-1):s.getChildAtIndex(n);if(nQ(o)){let e=0;i&&(e=o.getTextContentSize()),t.set(o.__key,e,"text"),r.set(o.__key,e,"text")}}else{if(rq(s)){let e=s.getChildrenSize(),r=n>=e,i=r?s.getChildAtIndex(e-1):s.getChildAtIndex(n);if(nQ(i)){let e=0;r&&(e=i.getTextContentSize()),t.set(i.__key,e,"text")}}if(rq(o)){let e=o.getChildrenSize(),t=i>=e,n=t?o.getChildAtIndex(e-1):o.getChildAtIndex(i);if(nQ(n)){let e=0;t&&(e=n.getTextContentSize()),r.set(n.__key,e,"text")}}}}function rv(e,t,n,r,i){let s=null,o=0,l=null;null!==r?(s=r.__key,nQ(r)?(o=r.getTextContentSize(),l="text"):rq(r)&&(o=r.getChildrenSize(),l="element")):null!==i&&(s=i.__key,nQ(i)?l="text":rq(i)&&(l="element")),null!==s&&null!==l?e.set(s,o,l):(-1===(o=t.getIndexWithinParent())&&(o=n.getChildrenSize()),e.set(n.__key,o,"element"))}function r_(e,t,n,r,i){"text"===e.type?e.set(n,e.offset+(t?0:i),"text"):e.offset>r.getIndexWithinParent()&&e.set(e.key,e.offset-1,"element")}function rb(e){let t=rp()||rg();null===t&&(t=e0().selectEnd()),t.insertNodes(e)}function rx(e){let t=e;e.isCollapsed()||t.removeText();let n=rp();n6(n)&&(t=n),n6(t)||ey(161);let r=t.anchor,i=r.getNode(),s=r.offset;for(;!tF(i);){let e=i;if([i,s]=function(e,t){let n=e.getParent();if(!n){let e=r4();return e0().append(e),e.select(),[e0(),0]}if(nQ(e)){let r=e.splitText(t);if(0===r.length)return[n,e.getIndexWithinParent()];let i=0===t?0:1;return[n,r[0].getIndexWithinParent()+i]}if(!rq(e)||0===t)return[n,e.getIndexWithinParent()];let r=e.getChildAtIndex(t);if(r){let n=new re(n5(e.__key,t,"element"),n5(e.__key,t,"element"),0,""),i=e.insertNewAfter(n);i&&i.append(r,...r.getNextSiblings())}return[n,e.getIndexWithinParent()+1]}(i,s),e.is(i))break}return s}let rS=null,rw=null,rE=!1,rT=!1,rC=0,rk={characterData:!0,childList:!0,subtree:!0};function rA(){return rE||null!==rS&&rS._readOnly}function rP(){rE&&ey(13)}function rN(){rC>99&&ey(14)}function rF(){return null===rS&&ey(195,rD()),rS}function rO(){return null===rw&&ey(196,rD()),rw}function rD(){let e=0,t=new Set,n=io.version;if("undefined"!=typeof window)for(let r of document.querySelectorAll("[contenteditable]")){let i=eB(r);if(eM(i))e++;else if(i){let e=String(i.constructor.version||"<0.17.1");e===n&&(e+=" (separately built, likely a bundler configuration issue)"),t.add(e)}}let r=` Detected on the page: ${e} compatible editor(s) with version ${n}`;return t.size&&(r+=` and incompatible editors with versions ${Array.from(t).join(", ")}`),r}function rL(e,t,n){let r=t.__type,i=function(e,t){let n=e._nodes.get(t);return void 0===n&&ey(30,t),n}(e,r),s=n.get(r);void 0===s&&(s=Array.from(i.transforms),n.set(r,s));let o=s.length;for(let e=0;e<o&&(s[e](t),t.isAttached());e++);}function rI(e,t){return void 0!==e&&e.__key!==t&&e.isAttached()}function rM(e,t){if(!t)return;let n=e._updateTags,r=t;for(let e of(Array.isArray(t)||(r=[t]),r))n.add(e)}function rR(e){return rB(e,rO()._nodes)}function rB(e,t){let n=e.type,r=t.get(n);void 0===r&&ey(17,n);let i=r.klass;e.type!==i.getType()&&ey(18,i.name);let s=i.importJSON(e),o=e.children;if(rq(s)&&Array.isArray(o))for(let e=0;e<o.length;e++){let n=rB(o[e],t);s.append(n)}return s}function rj(e,t,n){let r=rS,i=rE,s=rw;rS=t,rE=!0,rw=e;try{return n()}finally{rS=r,rE=i,rw=s}}function rU(e,t){let n=e._pendingEditorState,r=e._rootElement,s=e._headless||null===r;if(null===n)return;let o=e._editorState,l=o._selection,a=n._selection,u=0!==e._dirtyType,c=rS,d=rE,h=rw,f=e._updating,p=e._observer,g=null;if(e._pendingEditorState=null,e._editorState=n,!s&&u&&null!==p){rw=e,rS=n,rE=!1,e._updating=!0;try{let t=e._dirtyType,r=e._dirtyElements,i=e._dirtyLeaves;p.disconnect(),g=function(e,t,n,r,i,s){tq="",tQ="",tJ="",t0=2===r,t2=null,tU=n,tj=n._config,tV=n._nodes,tz=tU._listeners.mutation,t$
1=i,tW=s,tK=e._nodeMap,tH=t._nodeMap,t1=t._readOnly,tG=new Map(n._keyToDOMMap);let o=new Map;return tY=o,function e(t,n){let r=tK.get(t),i=tH.get(t);void 0!==r&&void 0!==i||ey(61);let s=t0||tW.has(t)||t$.has(t),o=tf(tU,t);if(r===i&&!s){if(rq(r)){let e=o.__lexicalTextContent;void 0!==e&&(tq+=e,tQ+=e);let t=o.__lexicalDirTextContent;void 0!==t&&(tJ+=t)}else{let e=r.getTextContent();nQ(r)&&!r.isDirectionless()&&(tJ+=e),tQ+=e,tq+=e}return o}if(r!==i&&s&&ta(tY,tV,tz,i,"updated"),i.updateDOM(r,o,tj)){let e=t9(t,null);return null===n&&ey(62),n.replaceChild(e,o),t3(t,null),e}if(rq(r)&&rq(i)){let t=i.__indent;t!==r.__indent&&t7(o,t);let n=i.__format;n!==r.__format&&t4(o,n),s&&(function(t,n,r){let i=tJ;tJ="",tZ=null,tX="",function(t,n,r){let i=tq,s=t.__size,o=n.__size;tq="";let l=r.element;if(1===s&&1===o){let r=t.__first,i=n.__first;if(r===i)e(r,l);else{let e=no(r),t=t9(i,null);try{l.replaceChild(t,e)}catch(n){if("object"==typeof n&&null!=n)throw Error(`${n.toString()} Parent: ${l.tagName}, new child: {tag: ${t.tagName} key: ${i}}, old child: {tag: ${e.tagName}, key: ${r}}.`);throw n}t3(r,null)}let s=tH.get(i);nQ(s)&&(null===tZ&&(tZ=s.getFormat()),""===tX&&(tX=s.getStyle()))}else{let i=nr(t,tK),a=nr(n,tH);if(i.length!==s&&ey(227),a.length!==o&&ey(228),0===s)0!==o&&t6(a,n,0,o-1,r);else if(0===o){if(0!==s){let e=null==r.after&&null==r.before&&null==r.element.__lexicalLineBreak;t8(i,0,s-1,e?null:l),e&&(l.textContent="")}}else!function(t,n,r,i,s,o){let l=i-1,a=s-1,u,c,d=o.getFirstChild(),h=0,f=0;for(;h<=l&&f<=a;){let t=n[h],i=r[f];if(t===i)d=ns(e(i,o.element)),h++,f++;else{void 0===u&&(u=new Set(n)),void 0===c&&(c=new Set(r));let s=c.has(t),l=u.has(i);if(s){if(l){let t=tf(tU,i);t===d?d=ns(e(i,o.element)):(o.withBefore(d).insertChild(t),e(i,o.element)),h++,f++}else t9(i,o.withBefore(d)),f++}else d=ns(no(t)),t3(t,o.element),h++}let s=tH.get(i);null!==s&&nQ(s)&&(null===tZ&&(tZ=s.getFormat()),""===tX&&(tX=s.getStyle()))}let p=h>l,g=f>a;if(p&&!g){let e=r[a+1],n=void 0===e?null:tU.getElementByKey(e);t6(r,t,f,a,o.withBefore(n))}else g&&!p&&t8(n,h,l,o.element)}(n,i,a,s,o,r)}th(n)&&(tq+="\n\n"),l.__lexicalTextContent=tq,tq=i+tq}(t,n,n.getDOMSlot(r)),nn(n,r),null==tZ||tZ===n.__textFormat||t1||(n.setTextFormat(tZ),n.setTextStyle(tX)),""===tX||tX===n.__textStyle||t1||n.setTextStyle(tX),tJ=i}(r,i,o),r0(i)||i.isInline()||nt(r,i,o)),th(i)&&(tq+="\n\n",tQ+="\n\n")}else{let e=i.getTextContent();if(rX(i)){let e=i.decorate(tU,tj);null!==e&&ni(t,e)}else nQ(i)&&!i.isDirectionless()&&(tJ+=e);tq+=e,tQ+=e}if(!t1&&r0(i)&&i.__cachedText!==tQ){let e=i.getWritable();e.__cachedText=tQ,i=e}return o}("root",null),tU=void 0,tV=void 0,t$=void 0,tW=void 0,tK=void 0,tH=void 0,tj=void 0,tG=void 0,tY=void 0,o}(o,n,e,t,r,i)}catch(t){if(t instanceof Error&&e._onError(t),rT)throw t;return ii(e,null,r,n),eT(e),e._dirtyType=2,rT=!0,rU(e,o),void(rT=!1)}finally{p.observe(r,rk),e._updating=f,rS=c,rE=d,rw=h}}n._readOnly||(n._readOnly=!0);let m=e._dirtyLeaves,y=e._dirtyElements,v=e._normalizedNodes,_=e._updateTags,b=e._deferred;u&&(e._dirtyType=0,e._cloneNotNeeded.clear(),e._dirtyLeaves=new Set,e._dirtyElements=new Map,e._normalizedNodes=new Set,e._updateTags=new Set),function(e,t){let n;let r=e._decorators,i=e._pendingDecorators||r,s=t._nodeMap;for(n in i)s.has(n)||(i===r&&(i=eX(e)),delete i[n])}(e,n);let x=s?null:tE(tv(e));if(e._editable&&null!==x&&(u||null===a||a.dirty)&&null!==r&&!_.has("skip-dom-selection")){rw=e,rS=n;try{if(null!==p&&p.disconnect(),u||null===a||a.dirty){let t=e._blockCursorElement;null!==t&&tw(t,e,r),function(e,t,n,r,i,s,o){let l=r.anchorNode,a=r.focusNode,u=r.anchorOffset,c=r.focusOffset,d=document.activeElement;if(i.has("collaboration")&&d!==s||null!==d&&eL(d))return;if(!n6(t))return void(null!==e&&eI(n,l,a)&&r.removeAllRanges());let h=t.anchor,f=t.focus,p=h.key,g=f.key,m=tf(n,p),y=tf(n,g),v=h.offset,_=f.offset,b=t.format,x=t.style,S=t.isCollapsed(),w=m,E=y,T=!1;if("text"===h.type){w=eV(m);let e=h.getNode();T=e.getFormat()!==b||e.getStyle()!==x}else n6(e)&&"text"===e.anchor.type&&(T=!0);if("text"===f.type&&(E=eV(y)),null!==w&&null!==E&&(S&&(null===e||T||n6(e)&&(e.format!==b||e.style!==x))&&(nb=[b,x,v,p,performance.now()]),u!==v||c!==_||l!==w||a!==E||"Range"===r.type&&S||(null!==d&&s.contains(d)||s.focus({preventScroll:!0}),"element"===h.type))){try{r.setBaseAndExtent(w,v,E,_),en&&setTimeout(()=>{r.setBaseAndExtent(w,v,E,_)})}catch(e){}if(!i.has("skip-scroll-into-view")&&t.isCollapsed()&&null!==s&&s===document.activeElement){let e=n6(t)&&"element"===t.anchor.type?w.childNodes[v]||null:r.rangeCount>0?r.getRangeAt(0):null;if(null!==e){let t;if(e instanceof Text){let n=document.createRange();n.selectNode(e),t=n.getBoundingClientRect()}else t=e.getBoundingClientRect();!function(e,t,n){let r=tg(n),i=ty(r);if(null===r||null===i)return;let{top:s,bottom:o}=t,l=0,a=0,u=n;for(;null!==u;){let t=u===r.body;if(t)l=0,a=tv(e).innerHeight;else{let e=u.getBoundingClientRect();l=e.top,a=e.bottom}let n=0;if(s<l?n=-(l-s):o>a&&(n=o-a),0!==n){if(t)i.scrollBy(0,n);else{let e=u.scrollTop;u.scrollTop+=n;let t=u.scrollTop-e;s-=t,o-=t}}if(t)break;u=tp(u)}}(n,t,s)}}np=!0}}(l,a,e,x,_,r)}!function(e,t,n){let r=e._blockCursorElement;if(n6(n)&&n.isCollapsed()&&"element"===n.anchor.type&&t.contains(document.activeElement)){let i=n.anchor,s=i.getNode(),o=i.offset,l=!1,a=null;if(o===s.getChildrenSize())tS(s.getChildAtIndex(o-1))&&(l=!0);else{let t=s.getChildAtIndex(o);if(null!==t&&tS(t)){let n=t.getPreviousSibling();(null===n||tS(n))&&(l=!0,a=e.getElementByKey(t.__key))}}if(l){let n=e.getElementByKey(s.__key);return null===r&&(e._blockCursorElement=r=function(e){let t=e.theme,n=document.createElement("div");n.contentEditable="false",n.setAttribute("data-lexical-cursor","true");let r=t.blockCursor;if(void 0!==r){if("string"==typeof r){let e=ev(r);r=t.blockCursor=e}void 0!==r&&n.classList.add(...r)}return n}(e._config)),t.style.caretColor="transparent",void(null===a?n.appendChild(r):n.insertBefore(r,a))}}null!==r&&tw(r,e,t)}(e,r,a)}finally{null!==p&&p.observe(r,rk),rw=h,rS=c}}null!==g&&function(e,t,n,r,i){let s=Array.from(e._listeners.mutation),o=s.length;for(let e=0;e<o;e++){let[o,l]=s[e],a=t.get(l);void 0!==a&&o(a,{dirtyLeaves:r,prevEditorState:i,updateTags:n})}}(e,g,_,m,o),n6(a)||null===a||null!==l&&l.is(a)||e.dispatchCommand(i,void 0);let S=e._pendingDecorators;null!==S&&(e._decorators=S,e._pendingDecorators=null,rV("decorator",e,!0,S)),function(e,t,n){let r=eQ(t),i=eQ(n);r!==i&&rV("textcontent",e,!0,i)}(e,t||o,n),rV("update",e,!0,{dirtyElements:y,dirtyLeaves:m,editorState:n,normalizedNodes:v,prevEditorState:t||o,tags:_}),function(e,t){if(e._deferred=[],0!==t.length){let n=e._updating;e._updating=!0;try{for(let e=0;e<t.length;e++)t[e]()}finally{e._updating=n}}}(e,b),function(e){let t=e._updates;if(0!==t.length){let n=t.shift();if(n){let[t,r]=n;rW(e,t,r)}}}(e)}function rV(e,t,n,...r){let i=t._updating;t._updating=n;try{let n=Array.from(t._listeners[e]);for(let e=0;e<n.length;e++)n[e].apply(null,r)}finally{t._updating=i}}function rz(e,t,n){if(!1===e._updating||rw!==e){let r=!1;return e.update(()=>{r=rz(e,t,n)}),r}let r=e7(e);for(let i=4;i>=0;i--)for(let s=0;s<r.length;s++){let o=r[s]._commands.get(t);
1if(void 0!==o){let t=o[i];if(void 0!==t){let r=Array.from(t),i=r.length;for(let t=0;t<i;t++)if(!0===r[t](n,e))return!0}}}return!1}function r$(e,t){let n=e._updates,r=t||!1;for(;0!==n.length;){let t=n.shift();if(t){let n;let[i,s]=t;if(void 0!==s){if(n=s.onUpdate,s.skipTransforms&&(r=!0),s.discrete){let t=e._pendingEditorState;null===t&&ey(191),t._flushSync=!0}n&&e._deferred.push(n),rM(e,s.tag)}i()}}return r}function rW(e,t,n){let r=e._updateTags,i,s=!1,o=!1;void 0!==n&&(i=n.onUpdate,rM(e,n.tag),s=n.skipTransforms||!1,o=n.discrete||!1),i&&e._deferred.push(i);let l=e._editorState,a=e._pendingEditorState,u=!1;(null===a||a._readOnly)&&(a=e._pendingEditorState=r1(a||l),u=!0),a._flushSync=o;let c=rS,d=rE,h=rw,f=e._updating;rS=a,rE=!1,e._updating=!0,rw=e;let p=e._headless||null===e.getRootElement();try{u&&(p?null!==l._selection&&(a._selection=l._selection.clone()):a._selection=function(e,t){let n=e.getEditorState()._selection,r=tE(tv(e));return n6(n)||null==n?rf(n,r,e,t):n.clone()}(e,n&&n.event||null));let r=e._compositionKey;t(),s=r$(e,s),function(e,t){let n=t.getEditorState()._selection,r=e._selection;if(n6(r)){let e;let t=r.anchor,i=r.focus;if("text"===t.type&&(e=t.getNode()).selectionTransform(n,r),"text"===i.type){let t=i.getNode();e!==t&&t.selectionTransform(n,r)}}}(a,e),0!==e._dirtyType&&(s?function(e,t){let n=t._dirtyLeaves,r=e._nodeMap;for(let e of n){let t=r.get(e);nQ(t)&&t.isAttached()&&t.isSimpleText()&&!t.isUnmergeable()&&eA(t)}}(a,e):function(e,t){let n=t._dirtyLeaves,r=t._dirtyElements,i=e._nodeMap,s=eG(),o=new Map,l=n,a=l.size,u=r,c=u.size;for(;a>0||c>0;){if(a>0){for(let e of(t._dirtyLeaves=new Set,l)){let r=i.get(e);nQ(r)&&r.isAttached()&&r.isSimpleText()&&!r.isUnmergeable()&&eA(r),void 0!==r&&rI(r,s)&&rL(t,r,o),n.add(e)}if((a=(l=t._dirtyLeaves).size)>0){rC++;continue}}for(let e of(t._dirtyLeaves=new Set,t._dirtyElements=new Map,u)){let n=e[0],l=e[1];if("root"!==n&&!l)continue;let a=i.get(n);void 0!==a&&rI(a,s)&&rL(t,a,o),r.set(n,l)}a=(l=t._dirtyLeaves).size,c=(u=t._dirtyElements).size,rC++}t._dirtyLeaves=n,t._dirtyElements=r}(a,e),r$(e),function(e,t,n,r){let i=e._nodeMap,s=t._nodeMap,o=[];for(let[e]of r){let t=s.get(e);void 0!==t&&(t.isAttached()||(rq(t)&&function e(t,n,r,i,s,o){let l=t.getFirstChild();for(;null!==l;){let t=l.__key;l.__parent===n&&(rq(l)&&e(l,t,r,i,s,o),r.has(t)||o.delete(t),s.push(t)),l=l.getNextSibling()}}(t,e,i,s,o,r),i.has(e)||r.delete(e),o.push(e)))}for(let e of o)s.delete(e);for(let e of n){let t=s.get(e);void 0===t||t.isAttached()||(i.has(e)||n.delete(e),s.delete(e))}}(l,a,e._dirtyLeaves,e._dirtyElements)),r!==e._compositionKey&&(a._flushSync=!0);let i=a._selection;if(n6(i)){let e=a._nodeMap,t=i.anchor.key,n=i.focus.key;void 0!==e.get(t)&&void 0!==e.get(n)||ey(19)}else rt(i)&&0===i._nodes.size&&(a._selection=null)}catch(t){return t instanceof Error&&e._onError(t),e._pendingEditorState=l,e._dirtyType=2,e._cloneNotNeeded.clear(),e._dirtyLeaves=new Set,e._dirtyElements.clear(),void rU(e)}finally{rS=c,rE=d,rw=h,e._updating=f,rC=0}0!==e._dirtyType||e._deferred.length>0||function(e,t){let n=t.getEditorState()._selection,r=e._selection;if(null!==r){if(r.dirty||!r.is(n))return!0}else if(null!==n)return!0;return!1}(a,e)?a._flushSync?(a._flushSync=!1,rU(e)):u&&eD(()=>{rU(e)}):(a._flushSync=!1,u&&(r.clear(),e._deferred=[],e._pendingEditorState=null))}function rK(e,t,n){e._updating?rw===e?t():e._updates.push([t,n]):rW(e,t,n)}class rH{constructor(e,t,n){this.element=e,this.before=t||null,this.after=n||null}withBefore(e){return new rH(this.element,e,this.after)}withAfter(e){return new rH(this.element,this.before,e)}withElement(e){return new rH(e,this.before,this.after)}insertChild(e){let t=this.before||this.getManagedLineBreak();return null!==t&&t.parentElement!==this.element&&ey(222),this.element.insertBefore(e,t),this}removeChild(e){return e.parentElement!==this.element&&ey(223),this.element.removeChild(e),this}replaceChild(e,t){return t.parentElement!==this.element&&ey(224),this.element.replaceChild(e,t),this}getFirstChild(){let e=this.after?this.after.nextSibling:this.element.firstChild;return e===this.before||e===this.getManagedLineBreak()?null:e}getManagedLineBreak(){return this.element.__lexicalLineBreak||null}setManagedLineBreak(e){null===e?this.removeManagedLineBreak():this.insertManagedLineBreak("decorator"===e&&(Q||X))}removeManagedLineBreak(){let e=this.getManagedLineBreak();if(e){let t=this.element,n="IMG"===e.nodeName?e.nextSibling:null;n&&t.removeChild(n),t.removeChild(e),t.__lexicalLineBreak=void 0}}insertManagedLineBreak(e){let t=this.getManagedLineBreak();if(t){if(e===("IMG"===t.nodeName))return;this.removeManagedLineBreak()}let n=this.element,r=this.before,i=document.createElement("br");if(n.insertBefore(i,r),e){let e=document.createElement("img");e.setAttribute("data-lexical-linebreak","true"),e.style.cssText="display: inline !important; border: 0px !important; margin: 0px !important;",e.alt="",n.insertBefore(e,i),n.__lexicalLineBreak=e}else n.__lexicalLineBreak=i}getFirstChildOffset(){let e=0;for(let t=this.after;null!==t;t=t.previousSibling)e++;return e}resolveChildIndex(e,t,n,r){if(n===this.element){let t=this.getFirstChildOffset();return[e,Math.min(t+e.getChildrenSize(),Math.max(t,r))]}let i=rG(t,n);i.push(r);let s=rG(t,this.element),o=e.getIndexWithinParent();for(let e=0;e<s.length;e++){let t=i[e],n=s[e];if(void 0===t||t<n)break;if(t>n){o+=1;break}}return[e.getParentOrThrow(),o]}}function rG(e,t){let n=[],r=t;for(;r!==e&&null!==r;
1r=t.parentNode){let e=0;for(let t=r.previousSibling;null!==t;t=r.previousSibling)e++;n.push(e)}return r!==e&&ey(225),n.reverse()}class rY extends nO{constructor(e){super(e),this.__first=null,this.__last=null,this.__size=0,this.__format=0,this.__style="",this.__indent=0,this.__dir=null,this.__textFormat=0,this.__textStyle=""}afterCloneFrom(e){super.afterCloneFrom(e),this.__first=e.__first,this.__last=e.__last,this.__size=e.__size,this.__indent=e.__indent,this.__format=e.__format,this.__style=e.__style,this.__dir=e.__dir,this.__textFormat=e.__textFormat,this.__textStyle=e.__textStyle}getFormat(){return this.getLatest().__format}getFormatType(){return ef[this.getFormat()]||""}getStyle(){return this.getLatest().__style}getIndent(){return this.getLatest().__indent}getChildren(){let e=[],t=this.getFirstChild();for(;null!==t;)e.push(t),t=t.getNextSibling();return e}getChildrenKeys(){let e=[],t=this.getFirstChild();for(;null!==t;)e.push(t.__key),t=t.getNextSibling();return e}getChildrenSize(){return this.getLatest().__size}isEmpty(){return 0===this.getChildrenSize()}isDirty(){let e=rO()._dirtyElements;return null!==e&&e.has(this.__key)}isLastChild(){let e=this.getLatest(),t=this.getParentOrThrow().getLastChild();return null!==t&&t.is(e)}getAllTextNodes(){let e=[],t=this.getFirstChild();for(;null!==t;){if(nQ(t)&&e.push(t),rq(t)){let n=t.getAllTextNodes();e.push(...n)}t=t.getNextSibling()}return e}getFirstDescendant(){let e=this.getFirstChild();for(;rq(e);){let t=e.getFirstChild();if(null===t)break;e=t}return e}getLastDescendant(){let e=this.getLastChild();for(;rq(e);){let t=e.getLastChild();if(null===t)break;e=t}return e}getDescendantByIndex(e){let t=this.getChildren(),n=t.length;if(e>=n){let e=t[n-1];return rq(e)&&e.getLastDescendant()||e||null}let r=t[e];return rq(r)&&r.getFirstDescendant()||r||null}getFirstChild(){let e=this.getLatest().__first;return null===e?null:eY(e)}getFirstChildOrThrow(){let e=this.getFirstChild();return null===e&&ey(45,this.__key),e}getLastChild(){let e=this.getLatest().__last;return null===e?null:eY(e)}getLastChildOrThrow(){let e=this.getLastChild();return null===e&&ey(96,this.__key),e}getChildAtIndex(e){let t,n;let r=this.getChildrenSize();if(e<r/2){for(t=this.getFirstChild(),n=0;null!==t&&n<=e;){if(n===e)return t;t=t.getNextSibling(),n++}return null}for(t=this.getLastChild(),n=r-1;null!==t&&n>=e;){if(n===e)return t;t=t.getPreviousSibling(),n--}return null}getTextContent(){let e="",t=this.getChildren(),n=t.length;for(let r=0;r<n;r++){let i=t[r];e+=i.getTextContent(),rq(i)&&r!==n-1&&!i.isInline()&&(e+="\n\n")}return e}getTextContentSize(){let e=0,t=this.getChildren(),n=t.length;for(let r=0;r<n;r++){let i=t[r];e+=i.getTextContentSize(),rq(i)&&r!==n-1&&!i.isInline()&&(e+=2)}return e}getDirection(){return this.getLatest().__dir}getTextFormat(){return this.getLatest().__textFormat}hasFormat(e){if(""!==e){let t=eh[e];return!!(this.getFormat()&t)}return!1}hasTextFormat(e){let t=ec[e];return!!(this.getTextFormat()&t)}getFormatFlags(e,t){return ez(this.getLatest().__textFormat,e,t)}getTextStyle(){return this.getLatest().__textStyle}select(e,t){rP();let n=rp(),r=e,i=t,s=this.getChildrenSize();if(!this.canBeEmpty()){if(0===e&&0===t){let e=this.getFirstChild();if(nQ(e)||rq(e))return e.select(0,0)}else if(!(void 0!==e&&e!==s||void 0!==t&&t!==s)){let e=this.getLastChild();if(nQ(e)||rq(e))return e.select()}}void 0===r&&(r=s),void 0===i&&(i=s);let o=this.__key;return n6(n)?(n.anchor.set(o,r,"element"),n.focus.set(o,i,"element"),n.dirty=!0,n):rc(o,r,o,i,"element","element")}selectStart(){let e=this.getFirstDescendant();return e?e.selectStart():this.select()}selectEnd(){let e=this.getLastDescendant();return e?e.selectEnd():this.select()}clear(){let e=this.getWritable();
1return this.getChildren().forEach(e=>e.remove()),e}append(...e){return this.splice(this.getChildrenSize(),0,e)}setDirection(e){let t=this.getWritable();return t.__dir=e,t}setFormat(e){return this.getWritable().__format=""!==e?eh[e]:0,this}setStyle(e){return this.getWritable().__style=e||"",this}setTextFormat(e){let t=this.getWritable();return t.__textFormat=e,t}setTextStyle(e){let t=this.getWritable();return t.__textStyle=e,t}setIndent(e){return this.getWritable().__indent=e,this}splice(e,t,n){let r=n.length,i=this.getChildrenSize(),s=this.getWritable();e+t<=i||ey(226,String(e),String(t),String(i));let o=s.__key,l=[],a=[],u=this.getChildAtIndex(e+t),c=null,d=i-t+r;if(0!==e){if(e===i)c=this.getLastChild();else{let t=this.getChildAtIndex(e);null!==t&&(c=t.getPreviousSibling())}}if(t>0){let e=null===c?this.getFirstChild():c.getNextSibling();for(let n=0;n<t;n++){null===e&&ey(100);let t=e.getNextSibling(),n=e.__key;eW(e.getWritable()),a.push(n),e=t}}let h=c;for(let e=0;e<r;e++){let t=n[e];null!==h&&t.is(h)&&(c=h=h.getPreviousSibling());let r=t.getWritable();r.__parent===o&&d--,eW(r);let i=t.__key;if(null===h)s.__first=i,r.__prev=null;else{let e=h.getWritable();e.__next=i,r.__prev=e.__key}t.__key===o&&ey(76),r.__parent=o,l.push(i),h=t}if(e+t===i)null!==h&&(h.getWritable().__next=null,s.__last=h.__key);else if(null!==u){let e=u.getWritable();if(null!==h){let t=h.getWritable();e.__prev=h.__key,t.__next=u.__key}else e.__prev=null}if(s.__size=d,a.length){let e=rp();if(n6(e)){let t=new Set(a),n=new Set(l),{anchor:r,focus:i}=e;rJ(r,t,n)&&rv(r,r.getNode(),this,c,u),rJ(i,t,n)&&rv(i,i.getNode(),this,c,u),0!==d||this.canBeEmpty()||t_(this)||this.remove()}}return s}getDOMSlot(e){return new rH(e)}exportDOM(e){let{element:t}=super.exportDOM(e);if(tC(t)){let e=this.getIndent();e>0&&(t.style.paddingInlineStart=40*e+"px")}return{element:t}}exportJSON(){let e={children:[],direction:this.getDirection(),format:this.getFormatType(),indent:this.getIndent(),...super.exportJSON()},t=this.getTextFormat(),n=this.getTextStyle();return 0!==t&&(e.textFormat=t),""!==n&&(e.textStyle=n),e}updateFromJSON(e){return super.updateFromJSON(e).setFormat(e.format).setIndent(e.indent).setDirection(e.direction).setTextFormat(e.textFormat||0).setTextStyle(e.textStyle||"")}insertNewAfter(e,t){return null}canIndent(){return!0}collapseAtStart(e){return!1}excludeFromCopy(e){return!1}canReplaceWith(e){return!0}canInsertAfter(e){return!0}canBeEmpty(){return!0}canInsertTextBefore(){return!0}canInsertTextAfter(){return!0}isInline(){return!1}isShadowRoot(){return!1}canMergeWith(e){return!1}extractWithChild(e,t,n){return!1}canMergeWhenEmpty(){return!1}reconcileObservedMutation(e,t){let n=this.getDOMSlot(e),r=n.getFirstChild();for(let e=this.getFirstChild();e;e=e.getNextSibling()){let i=t.getElementByKey(e.getKey());null!==i&&(null==r?(n.insertChild(i),r=i):r!==i&&n.replaceChild(i,r),r=r.nextSibling)}}}function rq(e){return e instanceof rY}function rJ(e,t,n){let r=e.getNode();for(;r;){let e=r.__key;if(t.has(e)&&!n.has(e))return!0;r=r.getParent()}return!1}class rZ extends nO{decorate(e,t){ey(47)}isIsolated(){return!1}isInline(){return!0}isKeyboardSelectable(){return!0}}function rX(e){return e instanceof rZ}class rQ extends rY{static getType(){return"root"}static clone(){return new rQ}constructor(){super("root"),this.__cachedText=null}getTopLevelElementOrThrow(){ey(51)}getTextContent(){let e=this.__cachedText;return(rA()||0===rO()._dirtyType)&&null!==e?e:super.getTextContent()}remove(){ey(52)}replace(e){ey(53)}insertBefore(e){ey(54)}insertAfter(e){ey(55)}updateDOM(e,t){return!1}append(...e){for(let t=0;t<e.length;t++){let n=e[t];rq(n)||rX(n)||ey(56)}return super.append(...e)}static importJSON(e){return e0().updateFromJSON(e)}collapseAtStart(){return!0}}function r0(e){return e instanceof rQ}function r1(e){return new r3(new Map(e._nodeMap))}function r2(){return new r3(new Map([["root",new rQ]]))}class r3{constructor(e,t){this._nodeMap=e,this._selection=t||null,this._flushSync=!1,this._readOnly=!1}isEmpty(){return 1===this._nodeMap.size&&null===this._selection}read(e,t){return rj(t&&t.editor||null,this,e)}clone(e){let t=new r3(this._nodeMap,void 0===e?this._selection:e);return t._readOnly=!0,t}toJSON(){return rj(null,this,()=>({root:function e(t){let n=t.exportJSON(),r=t.constructor;if(n.type!==r.getType()&&ey(130,r.name),rq(t)){let i=n.children;Array.isArray(i)||ey(59,r.name);let s=t.getChildren();for(let t=0;t<s.length;t++){let n=e(s[t]);i.push(n)}}return n}(e0())}))}}class r8 extends rY{static getType(){return"artificial"}createDOM(e){return document.createElement("div")}}class r5 extends rY{static getType(){return"paragraph"}static clone(e){return new r5(e.__key)}createDOM(e){let t=document.createElement("p"),n=tl(e.theme,"paragraph");return void 0!==n&&t.classList.add(...n),t}updateDOM(e,t,n){return!1}static importDOM(){return{p:e=>({conversion:r7,priority:0})}}exportDOM(e){let{element:t}=super.exportDOM(e);if(tC(t)){this.isEmpty()&&t.append(document.createElement("br"));let e=this.getFormatType();t.style.textAlign=e;let n=this.getDirection();n&&(t.dir=n)}return{element:t}}static importJSON(e){return r4().updateFromJSON(e)}exportJSON(){return{...super.exportJSON(),textFormat:this.getTextFormat(),textStyle:this.getTextStyle()}}insertNewAfter(e,t){let n=r4();n.setTextFormat(e.format),n.setTextStyle(e.style);let r=this.getDirection();return n.setDirection(r),n.setFormat(this.getFormatType()),n.setStyle(this.getTextStyle()),this.insertAfter(n,t),n}collapseAtStart(){let e=this.getChildren();if(0===e.length||nQ(e[0])&&""===e[0].getTextContent().trim()){if(null!==this.getNextSibling())return this.selectNext(),this.remove(),!0;if(null!==this.getPreviousSibling())return this.selectPrevious(),this.remove(),!0}return!1}}function r7(e){let t=r4();return e.style&&(t.setFormat(e.style.textAlign),tB(e,t)),{node:t}}function r4(){return tb(new r5)}function r9(e){return e instanceof r5}let r6=0,ie=1,it=3,ir=4;function ii(e,t,n,r){let i=e._keyToDOMMap;i.clear(),e._editorState=r2(),e._pendingEditorState=r,e._compositionKey=null,e._dirtyType=0,e._cloneNotNeeded.clear(),e._dirtyLeaves=new Set,e._dirtyElements.clear(),e._normalizedNodes=new Set,e._updateTags=new Set,e._updates=[],e._blockCursorElement=null;let s=e._observer;null!==s&&(s.disconnect(),e._observer=null),null!==t&&(t.textContent=""),null!==n&&(n.textContent="",i.set("root",n))}function is(e){let t;let n=e||{},r=rw,i=n.theme||{},s=void 0===e?r:n.parentEditor||null,o=n.disableEvents||!1,l=r2(),a=n.namespace||(null!==s?s._config.namespace:e4()),u=n.editorState,c=[rQ,nW,nD,n1,r5,r8,...n.nodes||[]],{onError:d,html:h}=n,f=void 0===n.editable||n.editable;if(void 0===e&&null!==r)t=r._nodes;else{t=new Map;for(let e=0;e<c.length;e++){let n=c[e],r=null,i=null;if("function"!=typeof n){let e=n;n=e.replace,r=e.with,i=e.withKlass||null}let s=n.getType(),o=n.transform(),l=new Set;null!==o&&l.add(o),t.set(s,{exportDOM:h&&h.export?h.export.get(n):void 0,klass:n,replace:r,replaceWithKlass:i,transforms:l})}}let p=new io(l,s,t,{disableEvents:o,namespace:a,theme:i},d||console.error,function(e,t){let n=new Map,r=new Set,i=e=>{Object.keys(e).forEach(t=>{let r=n.get(t);void 0===r&&(r=[],n.set(t,r)),r.push(e[t])})};
1return e.forEach(e=>{let t=e.klass.importDOM;if(null==t||r.has(t))return;r.add(t);let n=t.call(e.klass);null!==n&&i(n)}),t&&i(t),n}(t,h?h.import:void 0),f);return void 0!==u&&(p._pendingEditorState=u,p._dirtyType=2),p}class io{constructor(e,t,n,r,i,s,o){this._parentEditor=t,this._rootElement=null,this._editorState=e,this._pendingEditorState=null,this._compositionKey=null,this._deferred=[],this._keyToDOMMap=new Map,this._updates=[],this._updating=!1,this._listeners={decorator:new Set,editable:new Set,mutation:new Map,root:new Set,textcontent:new Set,update:new Set},this._commands=new Map,this._config=r,this._nodes=n,this._decorators={},this._pendingDecorators=null,this._dirtyType=0,this._cloneNotNeeded=new Set,this._dirtyLeaves=new Set,this._dirtyElements=new Map,this._normalizedNodes=new Set,this._updateTags=new Set,this._observer=null,this._key=e4(),this._onError=i,this._htmlConversions=s,this._editable=o,this._headless=null!==t&&t._headless,this._window=null,this._blockCursorElement=null}isComposing(){return null!=this._compositionKey}registerUpdateListener(e){let t=this._listeners.update;return t.add(e),()=>{t.delete(e)}}registerEditableListener(e){let t=this._listeners.editable;return t.add(e),()=>{t.delete(e)}}registerDecoratorListener(e){let t=this._listeners.decorator;return t.add(e),()=>{t.delete(e)}}registerTextContentListener(e){let t=this._listeners.textcontent;return t.add(e),()=>{t.delete(e)}}registerRootListener(e){let t=this._listeners.root;return e(this._rootElement,null),t.add(e),()=>{e(null,this._rootElement),t.delete(e)}}registerCommand(e,t,n){void 0===n&&ey(35);let r=this._commands;r.has(e)||r.set(e,[new Set,new Set,new Set,new Set,new Set]);let i=r.get(e);void 0===i&&ey(36,String(e));let s=i[n];return s.add(t),()=>{s.delete(t),i.every(e=>0===e.size)&&r.delete(e)}}registerMutationListener(e,t,n){let r=this.resolveRegisteredNodeAfterReplacements(this.getRegisteredNode(e)).klass,i=this._listeners.mutation;i.set(t,r);let s=n&&n.skipInitialization;return void 0!==s&&s||this.initializeMutationListener(t,r),()=>{i.delete(t)}}getRegisteredNode(e){let t=this._nodes.get(e.getType());return void 0===t&&ey(37,e.name),t}resolveRegisteredNodeAfterReplacements(e){for(;e.replaceWithKlass;)e=this.getRegisteredNode(e.replaceWithKlass);return e}initializeMutationListener(e,t){let n=this._editorState,r=tM(n).get(t.getType());if(!r)return;let i=new Map;for(let e of r.keys())i.set(e,"created");i.size>0&&e(i,{dirtyLeaves:new Set,prevEditorState:n,updateTags:new Set(["registerMutationListener"])})}registerNodeTransformToKlass(e,t){let n=this.getRegisteredNode(e);return n.transforms.add(t),n}registerNodeTransform(e,t){let n=this.registerNodeTransformToKlass(e,t),r=[n],i=n.replaceWithKlass;if(null!=i){let e=this.registerNodeTransformToKlass(i,t);r.push(e)}return function(e,t){let n=tM(e.getEditorState()),r=[];for(let e of t){let t=n.get(e);t&&r.push(t)}0!==r.length&&e.update(()=>{for(let e of r)for(let t of e.keys()){let e=eY(t);e&&e.markDirty()}},null===e._pendingEditorState?{tag:"history-merge"}:void 0)}(this,r.map(e=>e.klass.getType())),()=>{r.forEach(e=>e.transforms.delete(t))}}hasNode(e){return this._nodes.has(e.getType())}hasNodes(e){return e.every(this.hasNode.bind(this))}dispatchCommand(e,t){return rz(this,e,t)}getDecorators(){return this._decorators}getRootElement(){return this._rootElement}getKey(){return this._key}setRootElement(e){let t=this._rootElement;if(e!==t){let n=tl(this._config.theme,"root"),r=this._pendingEditorState||this._editorState;if(this._rootElement=e,ii(this,t,e,r),null!==t&&(this._config.disableEvents||function(e){let t=e.ownerDocument,n=nf.get(t);void 0===n&&ey(162);let r=n-1;r>=0||ey(164),nf.set(t,r),0===r&&t.removeEventListener("selectionchange",nA);let i=eB(e);eM(i)?(function(e){if(null!==e._parentEditor){let t=e7(e),n=t[t.length-1]._key;nk.get(n)===e&&nk.delete(n)}else nk.delete(e._key)}(i),e.__lexicalEditor=null):i&&ey(198);let s=nC(e);for(let e=0;e<s.length;e++)s[e]();e.__lexicalEventHandles=[]}(t),null!=n&&t.classList.remove(...n)),null!==e){let t=ty(e),r=e.style;r.userSelect="text",r.whiteSpace="pre-wrap",r.wordBreak="break-word",e.setAttribute("data-lexical-editor","true"),this._window=t,this._dirtyType=2,eT(this),this._updateTags.add("history-merge"),rU(this),this._config.disableEvents||function(e,t){let n=e.ownerDocument,r=nf.get(n);(void 0===r||r<1)&&n.addEventListener("selectionchange",nA),nf.set(n,(r||0)+1),e.__lexicalEditor=t;let i=nC(e);for(let n=0;n<na.length;n++){let[r,s]=na[n],o="function"==typeof s?e=>{nN(e)||(nP(e),(t.isEditable()||"click"===r)&&s(e,t))}:e=>{if(nN(e))return;nP(e);let n=t.isEditable();switch(r){case"cut":return n&&rz(t,U,e);case"copy":return rz(t,j,e);case"paste":return n&&rz(t,d,e);case"dragstart":return n&&rz(t,M,e);case"dragover":return n&&rz(t,R,e);case"dragend":return n&&rz(t,B,e);case"focus":return n&&rz(t,W,e);case"blur":return n&&rz(t,K,e);case"drop":return n&&rz(t,L,e)}};e.addEventListener(r,o),i.push(()=>{e.removeEventListener(r,o)})}}(e,this),null!=n&&e.classList.add(...n)}else this._window=null,this._updateTags.add("history-merge"),rU(this);rV("root",this,!1,e,t)}}getElementByKey(e){return this._keyToDOMMap.get(e)||null}getEditorState(){return this._editorState}setEditorState(e,t){e.isEmpty()&&ey(38);let n=e;n._readOnly&&((n=r1(e))._selection=e._selection?e._selection.clone():null),eE(this);
1let r=this._pendingEditorState,i=this._updateTags,s=void 0!==t?t.tag:null;null===r||r.isEmpty()||(null!=s&&i.add(s),rU(this)),this._pendingEditorState=n,this._dirtyType=2,this._dirtyElements.set("root",!1),this._compositionKey=null,null!=s&&i.add(s),this._updating||rU(this)}parseEditorState(e,t){return function(e,t,n){let r=r2(),i=rS,s=rE,o=rw,l=t._dirtyElements,a=t._dirtyLeaves,u=t._cloneNotNeeded,c=t._dirtyType;t._dirtyElements=new Map,t._dirtyLeaves=new Set,t._cloneNotNeeded=new Set,t._dirtyType=0,rS=r,rE=!1,rw=t;try{let i=t._nodes;rB(e.root,i),n&&n(),r._readOnly=!0}catch(e){e instanceof Error&&t._onError(e)}finally{t._dirtyElements=l,t._dirtyLeaves=a,t._cloneNotNeeded=u,t._dirtyType=c,rS=i,rE=s,rw=o}return r}("string"==typeof e?JSON.parse(e):e,this,t)}read(e){return rU(this),this.getEditorState().read(e,{editor:this})}update(e,t){this._updating?this._updates.push([e,t]):rW(this,e,t)}focus(e,t={}){let n=this._rootElement;null!==n&&(n.setAttribute("autocapitalize","off"),rK(this,()=>{var r,i;let s=rp(),o=e0();null!==s?s.dirty=!0:0!==o.getChildrenSize()&&("rootStart"===t.defaultSelection?o.selectStart():o.selectEnd()),r="focus",rP(),rO()._updateTags.add(r),i=()=>{n.removeAttribute("autocapitalize"),e&&e()},rP(),rO()._deferred.push(i)}),null===this._pendingEditorState&&n.removeAttribute("autocapitalize"))}blur(){let e=this._rootElement;null!==e&&e.blur();let t=tE(this._window);null!==t&&t.removeAllRanges()}isEditable(){return this._editable}setEditable(e){this._editable!==e&&(this._editable=e,rV("editable",this,!0,e))}toJSON(){return{editorState:this._editorState.toJSON()}}}io.version="0.24.0+prod.esm"},35935:function(e,t,n){"use strict";n.d(t,{Dp:function(){return s},G:function(){return o},Z$:function(){return r},kJ:function(){return l},s7:function(){return i}});let r=e=>e[e.length-1],i=(e,t)=>{for(let n=0;n<t.length;n++)e.push(t[n])},s=Array.from,o=(e,t)=>{for(let n=0;n<e.length;n++)if(t(e[n],n,e))return!0;return!1},l=Array.isArray},99785:function(e,t,n){"use strict";n.d(t,{$2:function(){return d},CY:function(){return s},Ko:function(){return o},Qn:function(){return i},RP:function(){return f},Tg:function(){return p},Vw:function(){return r},cq:function(){return l},jS:function(){return h},kr:function(){return c},rc:function(){return a},x1:function(){return u}});let r=1,i=2,s=4,o=8,l=32,a=64,u=128,c=31,d=63,h=127,f=2147483647,p=4294967295},46328:function(e,t,n){"use strict";n.d(t,{f9:function(){return l}}),n(71239);var r=n(15419),i=n(53094).Buffer;let s=e=>new Uint8Array(e),o=(e,t,n)=>new Uint8Array(e,t,n);r.jU||(e=>i.from(e.buffer,e.byteOffset,e.byteLength).toString("base64")),r.jU||(e=>{let t=i.from(e,"base64");return o(t.buffer,t.byteOffset,t.byteLength)});let l=e=>{let t=s(e.byteLength);return t.set(e),t}},94537:function(e,t,n){"use strict";n.d(t,{HN:function(){return p},UF:function(){return w},XW:function(){return S},dD:function(){return E}
1,kf:function(){return v},kj:function(){return g},l1:function(){return d},sO:function(){return T},v_:function(){return x},yg:function(){return m}});var r=n(99785),i=n(52746),s=n(59236),o=n(71239),l=n(81362);let a=l.Ue("Unexpected end of array"),u=l.Ue("Integer out of Range");class c{constructor(e){this.arr=e,this.pos=0}}let d=e=>new c(e),h=e=>e.pos!==e.arr.length,f=(e,t)=>{let n=new Uint8Array(e.arr.buffer,e.pos+e.arr.byteOffset,t);return e.pos+=t,n},p=e=>f(e,m(e)),g=e=>e.arr[e.pos++],m=e=>{let t=0,n=1,i=e.arr.length;for(;e.pos<i;){let i=e.arr[e.pos++];if(t+=(i&r.jS)*n,n*=128,i<r.x1)return t;if(t>s.YM)throw u}throw a},y=e=>{let t=e.arr[e.pos++],n=t&r.$2,i=64,o=(t&r.rc)>0?-1:1;if((t&r.x1)==0)return o*n;let l=e.arr.length;for(;e.pos<l;){if(n+=((t=e.arr[e.pos++])&r.jS)*i,i*=128,t<r.x1)return o*n;if(n>s.YM)throw u}throw a},v=o.CO?e=>o.CO.decode(p(e)):e=>{let t=m(e);if(0===t)return"";{let n=String.fromCodePoint(g(e));if(--t<100)for(;t--;)n+=String.fromCodePoint(g(e));else for(;t>0;){let r=t<1e4?t:1e4,i=e.arr.subarray(e.pos,e.pos+r);e.pos+=r,n+=String.fromCodePoint.apply(null,i),t-=r}return decodeURIComponent(escape(n))}},_=(e,t)=>{let n=new DataView(e.arr.buffer,e.arr.byteOffset+e.pos,t);return e.pos+=t,n},b=[e=>void 0,e=>null,y,e=>_(e,4).getFloat32(0,!1),e=>_(e,8).getFloat64(0,!1),e=>_(e,8).getBigInt64(0,!1),e=>!1,e=>!0,v,e=>{let t=m(e),n={};for(let r=0;r<t;r++)n[v(e)]=x(e);return n},e=>{let t=m(e),n=[];for(let r=0;r<t;r++)n.push(x(e));return n},p],x=e=>b[127-g(e)](e);class S extends c{constructor(e,t){super(e),this.reader=t,this.s=null,this.count=0}read(){return 0===this.count&&(this.s=this.reader(this),h(this)?this.count=m(this)+1:this.count=-1),this.count--,this.s}}class w extends c{constructor(e){super(e),this.s=0,this.count=0}read(){if(0===this.count){this.s=y(this);let e=i.GR(this.s);this.count=1,e&&(this.s=-this.s,this.count=m(this)+2)}return this.count--,this.s}}class E extends c{constructor(e){super(e),this.s=0,this.count=0,this.diff=0}read(){if(0===this.count){let e=y(this);this.diff=i.GW(e/2),this.count=1,1&e&&(this.count=m(this)+2)}return this.s+=this.diff,this.count--,this.s}}class T{constructor(e){this.decoder=new w(e),this.str=v(this.decoder),this.spos=0}read(){let e=this.spos+this.decoder.read(),t=this.str.slice(this.spos,e);return this.spos=e,t}}},70754:function(e,t,n){"use strict";n.d(t,{$F:function(){return p},EM:function(){return A},GF:function(){return P},HE:function(){return F},HK:function(){return b},Mf:function(){return u},TS:function(){return L},_f:function(){return d},mP:function(){return x},sX:function(){return D},uE:function(){return g},uw:function(){return _}});var r=n(52746),i=n(59236),s=n(99785),o=n(71239),l=n(35935);class a{constructor(){this.cpos=0,this.cbuf=new Uint8Array(100),this.bufs=[]}}let u=()=>new a,c=e=>{let t=e.cpos;for(let n=0;n<e.bufs.length;n++)t+=e.bufs[n].length;return t},d=e=>{let t=new Uint8Array(c(e)),n=0;for(let r=0;r<e.bufs.length;r++){let i=e.bufs[r];t.set(i,n),n+=i.length}return t.set(new Uint8Array(e.cbuf.buffer,0,e.cpos),n),t},h=(e,t)=>{let n=e.cbuf.length;n-e.cpos<t&&(e.bufs.push(new Uint8Array(e.cbuf.buffer,0,e.cpos)),e.cbuf=new Uint8Array(2*r.Fp(n,t)),e.cpos=0)},f=(e,t)=>{let n=e.cbuf.length;e.cpos===n&&(e.bufs.push(e.cbuf),e.cbuf=new Uint8Array(2*n),e.cpos=0),e.cbuf[e.cpos++]=t},p=f,g=(e,t)=>{for(;t>s.jS;)f(e,s.x1|s.jS&t),t=r.GW(t/128);f(e,s.jS&t)},m=(e,t)=>{let n=r.GR(t);for(n&&(t=-t),f(e,(t>s.$2?s.x1:0)|(n?s.rc:0)|s.$2&t),t=r.GW(t/64);t>0;)f(e,(t>s.jS?s.x1:0)|s.jS&t),t=r.GW(t/128)},y=new Uint8Array(3e4),v=y.length/3,_=o.YZ&&o.YZ.encodeInto?(e,t)=>{if(t.length<v){let n=o.YZ.encodeInto(t,y).written||0;g(e,n);for(let t=0;t<n;t++)f(e,y[t])}else x(e,o.lz(t))}:(e,t)=>{let n=unescape(encodeURIComponent(t)),r=n.length;g(e,r);for(let t=0;t<r;t++)f(e,n.codePointAt(t))},b=(e,t)=>{let n=e.cbuf.length,i=e.cpos,s=r.VV(n-i,t.length),o=t.length-s;e.cbuf.set(t.subarray(0,s),i),e.cpos+=s,o>0&&(e.bufs.push(e.cbuf),e.cbuf=new Uint8Array(r.Fp(2*n,o)),e.cbuf.set(t.subarray(s)),e.cpos=o)},x=(e,t)=>{g(e,t.byteLength),b(e,t)},S=(e,t)=>{h(e,t);let n=new DataView(e.cbuf.buffer,e.cpos,t);
1return e.cpos+=t,n},w=(e,t)=>S(e,4).setFloat32(0,t,!1),E=(e,t)=>S(e,8).setFloat64(0,t,!1),T=(e,t)=>S(e,8).setBigInt64(0,t,!1),C=new DataView(new ArrayBuffer(4)),k=e=>(C.setFloat32(0,e),C.getFloat32(0)===e),A=(e,t)=>{switch(typeof t){case"string":f(e,119),_(e,t);break;case"number":i.U(t)&&r.Wn(t)<=s.RP?(f(e,125),m(e,t)):k(t)?(f(e,124),w(e,t)):(f(e,123),E(e,t));break;case"bigint":f(e,122),T(e,t);break;case"object":if(null===t)f(e,126);else if(l.kJ(t)){f(e,117),g(e,t.length);for(let n=0;n<t.length;n++)A(e,t[n])}else if(t instanceof Uint8Array)f(e,116),x(e,t);else{f(e,118);let n=Object.keys(t);g(e,n.length);for(let r=0;r<n.length;r++){let i=n[r];_(e,i),A(e,t[i])}}break;case"boolean":f(e,t?120:121);break;default:f(e,127)}};class P extends a{constructor(e){super(),this.w=e,this.s=null,this.count=0}write(e){this.s===e?this.count++:(this.count>0&&g(this,this.count-1),this.count=1,this.w(this,e),this.s=e)}}let N=e=>{e.count>0&&(m(e.encoder,1===e.count?e.s:-e.s),e.count>1&&g(e.encoder,e.count-2))};class F{constructor(){this.encoder=new a,this.s=0,this.count=0}write(e){this.s===e?this.count++:(N(this),this.count=1,this.s=e)}toUint8Array(){return N(this),d(this.encoder)}}let O=e=>{if(e.count>0){let t=2*e.diff+(1===e.count?0:1);m(e.encoder,t),e.count>1&&g(e.encoder,e.count-2)}};class D{constructor(){this.encoder=new a,this.s=0,this.count=0,this.diff=0}write(e){this.diff===e-this.s?(this.s=e,this.count++):(O(this),this.count=1,this.diff=e-this.s,this.s=e)}toUint8Array(){return O(this),d(this.encoder)}}class L{constructor(){this.sarr=[],this.s="",this.lensE=new F}write(e){this.s+=e,this.s.length>19&&(this.sarr.push(this.s),this.s=""),this.lensE.write(e.length)}toUint8Array(){let e=new a;return this.sarr.push(this.s),this.s="",_(e,this.sarr.join("")),b(e,this.lensE.toUint8Array()),d(e)}}},15419:function(e,t,n){"use strict";let r;n.d(t,{E0:function(){return y},jU:function(){return f},hH:function(){return _}});var i=n(59087),s=n(71239);let o=e=>void 0===e?null:e;class l{constructor(){this.map=new Map}setItem(e,t){this.map.set(e,t)}getItem(e){return this.map.get(e)}}let a=new l;try{"undefined"!=typeof localStorage&&localStorage&&(a=localStorage)}catch(e){}let u=a;var c=n(93714),d=n(28070);let h=void 0!==d&&d.release&&/node|io\.js/.test(d.release.name)&&"[object process]"===Object.prototype.toString.call(void 0!==d?d:0),f="undefined"!=typeof window&&"undefined"!=typeof document&&!h;"undefined"!=typeof navigator&&/Mac/.test(navigator.platform);let p=[],g=()=>{if(void 0===r){if(h){r=i.Ue();let e=d.argv,t=null;for(let n=0;n<e.length;n++){let i=e[n];"-"===i[0]?(null!==t&&r.set(t,""),t=i):null!==t?(r.set(t,i),t=null):p.push(i)}null!==t&&r.set(t,"")}else"object"==typeof location?(r=i.Ue(),(location.search||"?").slice(1).split("&").forEach(e=>{if(0!==e.length){let[t,n]=e.split("=");r.set(`--${s.NF(t,"-")}`,n),r.set(`-${s.NF(t,"-")}`,n)}})):r=i.Ue()}return r},m=e=>g().has(e),y=e=>h?o(d.env[e.toUpperCase().replaceAll("-","_")]):o(u.getItem(e)),v=e=>m("--"+e)||null!==y(e);v("production");let _=h&&c.gB(d.env.FORCE_COLOR,["true","1","2"])||!m("--no-colors")&&!v("no-color")&&(!h||d.stdout.isTTY)&&(!h||m("--color")||null!==y("COLORTERM")||(y("TERM")||"").includes("color"))},81362:function(e,t,n){"use strict";n.d(t,{Nw:function(){return i},Ue:function(){return r},zR:function(){return s}});let r=e=>Error(e),i=()=>{throw r("Method unimplemented")},s=()=>{throw r("Unexpected case")}},93714:function(e,t,n){"use strict";n.d(t,{PP:function(){return i},gB:function(){return o},id:function(){return s}});var r=n(35935);let i=(e,t,n=0)=>{try{for(;n<e.length;n++)e[n](...t)}finally{n<e.length&&i(e,t,n+1)}},s=e=>e,o=(e,t)=>t.includes(e);r.kJ},88196:function(e,t,n){"use strict";n.d(t,{BG:function(){return i},CA:function(){return s}});let r=e=>({[Symbol.iterator](){return this},next:e}),i=(e,t)=>r(()=>{let n;do n=e.next();while(!n.done&&!t(n.value));return n}),s=(e,t)=>r(()=>{let{done:n,value:r}=e.next();return{done:n,value:n?void 0:t(r)}})},56122:function(e,t,n){"use strict";n.d(t,{Ej:function(){return l},Pl:function(){return s},ZA:function(){return u},s7:function(){return a},ud:function(){return h},Wd:function(){return d},hM:function(){return c},YW:function(){return o},WO:function(){return f},_X:function(){return p}});let r=Symbol;var i=n(70491);let s=r(),o=r(),l=r(),a=r(),u=r(),c=r(),d=r(),h=r(),f=r(),p=e=>{1===e.length&&e[0]?.constructor===Function&&(e=e[0]());let t=[],n=[],r=0;for(;r<e.length;r++){let n=e[r];if(void 0===n)break;if(n.constructor===String||n.constructor===Number)t.push(n);else if(n.constructor===Object)break}for(r>0&&n.push(t.join(""));r<e.length;r++){let t=e[r];t instanceof Symbol||n.push(t)}return n};i.ZG()},29453:function(e,t,n){"use strict";n.d(t,{S0:function(){return f},ZK:function(){return p}});var r=n(15419),i=n(18396);class s{constructor(e,t){this.left=e,this.right=t}}let o=(e,t)=>new s(e,t);var l=n(59087);let a="undefined"!=typeof document?document:{};"undefined"!=typeof DOMParser&&new DOMParser;let u=e=>l.UI(e,(e,t)=>`${t}:${e};`).join("");a.ELEMENT_NODE,a.TEXT_NODE,a.CDATA_SECTION_NODE,a.COMMENT_NODE,a.DOCUMENT_NODE,a.DOCUMENT_TYPE_NODE,a.DOCUMENT_FRAGMENT_NODE;var c=n(56122);let d={[c.Pl]:o("font-weight","bold"),[c.YW]:o("font-weight","normal"),[c.Ej]:o("color","blue"),[c.ZA]:o("color","green"),[c.s7]:o("color","grey"),[c.hM]:o("color","red"),[c.Wd]:o("color","purple"),[c.ud]:o("color","orange"),[c.WO]:o("color","black")},h=r.hH?e=>{1===e.length&&e[0]?.constructor===Function&&(e=e[0]());let t=[],n=[],r=l.Ue(),i=[],s=0;for(;s<e.length;s++){let i=e[s],o=d[i];if(void 0!==o)r.set(o.left,o.right);else{if(void 0===i)break;if(i.constructor===String||i.constructor===Number){let e=u(r);s>0||e.length>
10?(t.push("%c"+i),n.push(e)):t.push(i)}else break}}for(s>0&&(i=n).unshift(t.join(""));s<e.length;s++){let t=e[s];t instanceof Symbol||i.push(t)}return i}:c._X,f=(...e)=>{console.log(...h(e)),g.forEach(t=>t.print(e))},p=(...e)=>{console.warn(...h(e)),e.unshift(c.ud),g.forEach(t=>t.print(e))},g=i.Ue()},59087:function(e,t,n){"use strict";n.d(t,{JG:function(){return i},UI:function(){return o},Ue:function(){return r},Yj:function(){return l},Yu:function(){return s}});let r=()=>new Map,i=e=>{let t=r();return e.forEach((e,n)=>{t.set(n,e)}),t},s=(e,t,n)=>{let r=e.get(t);return void 0===r&&e.set(t,r=n()),r},o=(e,t)=>{let n=[];for(let[r,i]of e)n.push(t(i,r));return n},l=(e,t)=>{for(let[n,r]of e)if(t(r,n))return!0;return!1}},52746:function(e,t,n){"use strict";n.d(t,{Fp:function(){return o},GR:function(){return l},GW:function(){return r},VV:function(){return s},Wn:function(){return i}});let r=Math.floor,i=Math.abs,s=(e,t)=>e<t?e:t,o=(e,t)=>e>t?e:t,l=e=>0!==e?e<0:1/e<0},59236:function(e,t,n){"use strict";n.d(t,{U:function(){return o},YM:function(){return s}});var r=n(52746),i=n(99785);let s=Number.MAX_SAFE_INTEGER;i.RP,i.Tg;let o=Number.isInteger||(e=>"number"==typeof e&&isFinite(e)&&r.GW(e)===e)},95459:function(e,t,n){"use strict";n.d(t,{$m:function(){return c},Ed:function(){return s},_A:function(){return h},f0:function(){return r},xb:function(){return l}});let r=Object.assign,i=Object.keys,s=(e,t)=>{for(let n in e)t(e[n],n)},o=e=>i(e).length,l=e=>{for(let t in e)return!1;return!0},a=(e,t)=>{for(let n in e)if(!t(e[n],n))return!1;return!0},u=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),c=(e,t)=>e===t||o(e)===o(t)&&a(e,(e,n)=>(void 0!==e||u(t,n))&&t[n]===e),d=Object.freeze,h=e=>{for(let t in e){let n=e[t];("object"==typeof n||"function"==typeof n)&&h(e[t])}return d(e)}},9027:function(e,t,n){"use strict";n.d(t,{g:function(){return o},y:function(){return l}});var r=n(59087),i=n(18396),s=n(35935);class o{constructor(){this._observers=r.Ue()}on(e,t){return r.Yu(this._observers,e,i.Ue).add(t),t}once(e,t){let n=(...r)=>{this.off(e,n),t(...r)};this.on(e,n)}off(e,t){let n=this._observers.get(e);void 0!==n&&(n.delete(t),0===n.size&&this._observers.delete(e))}emit(e,t){return s.Dp((this._observers.get(e)||r.Ue()).values()).forEach(e=>e(...t))}destroy(){this._observers=r.Ue()}}class l{constructor(){this._observers=r.Ue()}on(e,t){r.Yu(this._observers,e,i.Ue).add(t)}once(e,t){let n=(...r)=>{this.off(e,n),t(...r)};this.on(e,n)}off(e,t){let n=this._observers.get(e);void 0!==n&&(n.delete(t),0===n.size&&this._observers.delete(e))}emit(e,t){return s.Dp((this._observers.get(e)||r.Ue()).values()).forEach(e=>e(...t))}destroy(){this._observers=r.Ue()}}},50345:function(e,t,n){"use strict";n.d(t,{Ue:function(){return r}});let r=e=>new Promise(e);Promise.all.bind(Promise)},96970:function(e,t,n){"use strict";n.d(t,{U7:function(){return i},k$:function(){return s}}),crypto.subtle;let r=crypto.getRandomValues.bind(crypto),i=()=>r(new Uint32Array(1))[0],s=()=>"10000000-1000-4000-8000-100000000000".replace(/[018]/g,e=>(e^i()&15>>e/4).toString(16))},18396:function(e,t,n){"use strict";n.d(t,{Ue:function(){return r}});let r=()=>new Set},71239:function(e,t,n){"use strict";n.d(t,{CO:function(){return d},IK:function(){return r},NF:function(){return a},YZ:function(){return u},lz:function(){return c}});let r=String.fromCharCode;r(65535);let i=e=>e.toLowerCase(),s=/^\s*/g,o=e=>e.replace(s,""),l=/([A-Z])/g,a=(e,t)=>o(e.replace(l,e=>`${t}${i(e)}`)),u="undefined"!=typeof TextEncoder?new TextEncoder:null,c=u?e=>u.encode(e):e=>{let t=unescape(encodeURIComponent(e)),n=t.length,r=new Uint8Array(n);for(let e=0;e<n;e++)r[e]=t.codePointAt(e);return r},d="undefined"==typeof TextDecoder?null:new TextDecoder("utf-8",{fatal:!0,ignoreBOM:!0});d&&1===d.decode(new Uint8Array).length&&(d=null)},70491:function(e,t,n){"use strict";n.d(t,{ZG:function(){return r}});let r=Date.now}}]);
2//# sourceMappingURL=3808-a1e876c8d7d21b96.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.