Scrollmark

Local-first X/Twitter research archive, search, bookmark capture, and portable bundle export by Kyle McCleary.

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

Advertisement:

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

ستحتاج إلى تثبيت إضافة مثل Stylus لتثبيت هذا النمط.

ستحتاج إلى تثبيت إضافة لإدارة أنماط المستخدم لتتمكن من تثبيت هذا النمط.

ستحتاج إلى تثبيت إضافة لإدارة أنماط المستخدم لتثبيت هذا النمط.

ستحتاج إلى تثبيت إضافة لإدارة أنماط المستخدم لتثبيت هذا النمط.

(لدي بالفعل مثبت أنماط للمستخدم، دعني أقم بتثبيته!)

Advertisement:

// ==UserScript==
// @name               Scrollmark
// @name:zh-CN         Scrollmark
// @name:zh-TW         Scrollmark
// @name:ja            Scrollmark
// @namespace          https://github.com/kmccleary3301/scrollmark
// @version            1.3.0
// @author             Kyle McCleary
// @description        Local-first X/Twitter research archive, search, bookmark capture, and portable bundle export by Kyle McCleary.
// @description:zh-CN  本地优先的 X/Twitter 研究归档、搜索、书签采集与可移植 Bundle 导出工具。
// @description:zh-TW  本地優先的 X/Twitter 研究歸檔、搜尋、書籤擷取與可攜式 Bundle 匯出工具。
// @description:ja     ローカルファーストの X/Twitter 研究アーカイブ、検索、ブックマーク取得、ポータブル Bundle 出力ツール。
// @license            MIT
// @icon               data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAABmklEQVR4Ae3XA4wcARSA4dq2bUQ1g9pRbVtBzai2otpug9pxUttn2753/3m9Ozq/5NsdvvfGM6VKoshE8/ORFbAMbxCGWHzDHjS2sXxPlM0eKYclGoq3w1eIHVGYikaYg6e4ZppgAgQrVBSvDw+IEylIhSAATUyTHIYgFdsUNnAGosAfDMccLMtOchli4g7quFC8FhIhCsRD8Bk1sxMdgVjwxRyUdtDABIgKH9DQNNEkiB1fMB9VbDSwEKLQJ1S1TFQRXhAHYnADy9ETdTEeotAze7tzNJIhCiRBFLpnq/hmzMR65UkVO2WrgaOQPLLW3u6XPDLAVgOl8R5isEhUtHcSdkEoxEBXnN3ZuuMbxCDDnTVQF52xBcEQHX1BaWcNtDLwMpzg6tNtN0RnD5U8XsviGkQnYWih9CWjNBbDHaJBMsZqec8rjV54B1EoFXO0Fh+DrxCFEjBTTdFy6IvNGu4Hf9FXSdGheAUvjZdgLPajqtp3+jl4jVSIAgHYjRZ6fWC0wSpcwScEQZCMUPzEfezEYJQrVRKFOdIAZGq1QBG8EiYAAAAASUVORK5CYII=
// @homepage           https://github.com/kmccleary3301/scrollmark
// @homepageURL        https://github.com/kmccleary3301/scrollmark
// @supportURL         https://github.com/kmccleary3301/scrollmark/issues
// @match              *://twitter.com/*
// @match              *://x.com/*
// @match              *://mobile.x.com/*
// @connect            cdn.syndication.twimg.com
// @grant              GM_addStyle
// @grant              GM_registerMenuCommand
// @grant              GM_xmlhttpRequest
// @grant              unsafeWindow
// @inject-into        page
// @run-at             document-start
// ==/UserScript==

(t=>{if(typeof GM_addStyle=="function"){GM_addStyle(t);return}const o=document.createElement("style");o.textContent=t,document.head.append(o)})(` #twe-root *,#twe-root :before,#twe-root :after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }#twe-root ::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }#twe-root *,#twe-root :before,#twe-root :after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}#twe-root :before,#twe-root :after{--tw-content: ""}#twe-root,#twe-root :host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}#twe-root{margin:0;line-height:inherit}#twe-root hr{height:0;color:inherit;border-top-width:1px}#twe-root abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}#twe-root h1,#twe-root h2,#twe-root h3,#twe-root h4,#twe-root h5,#twe-root h6{font-size:inherit;font-weight:inherit}#twe-root a{color:inherit;text-decoration:inherit}#twe-root b,#twe-root strong{font-weight:bolder}#twe-root code,#twe-root kbd,#twe-root samp,#twe-root pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}#twe-root small{font-size:80%}#twe-root sub,#twe-root sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}#twe-root sub{bottom:-.25em}#twe-root sup{top:-.5em}#twe-root table{text-indent:0;border-color:inherit;border-collapse:collapse}#twe-root button,#twe-root input,#twe-root optgroup,#twe-root select,#twe-root textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}#twe-root button,#twe-root select{text-transform:none}#twe-root button,#twe-root input:where([type=button]),#twe-root input:where([type=reset]),#twe-root input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}#twe-root :-moz-focusring{outline:auto}#twe-root :-moz-ui-invalid{box-shadow:none}#twe-root progress{vertical-align:baseline}#twe-root ::-webkit-inner-spin-button,#twe-root ::-webkit-outer-spin-button{height:auto}#twe-root [type=search]{-webkit-appearance:textfield;outline-offset:-2px}#twe-root ::-webkit-search-decoration{-webkit-appearance:none}#twe-root ::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}#twe-root summary{display:list-item}#twe-root blockquote,#twe-root dl,#twe-root dd,#twe-root h1,#twe-root h2,#twe-root h3,#twe-root h4,#twe-root h5,#twe-root h6,#twe-root hr,#twe-root figure,#twe-root p,#twe-root pre{margin:0}#twe-root fieldset{margin:0;padding:0}#twe-root legend{padding:0}#twe-root ol,#twe-root ul,#twe-root menu{list-style:none;margin:0;padding:0}#twe-root dialog{padding:0}#twe-root textarea{resize:vertical}#twe-root input::-moz-placeholder,#twe-root textarea::-moz-placeholder{opacity:1;color:#9ca3af}#twe-root input::placeholder,#twe-root textarea::placeholder{opacity:1;color:#9ca3af}#twe-root button,#twe-root [role=button]{cursor:pointer}#twe-root :disabled{cursor:default}#twe-root img,#twe-root svg,#twe-root video,#twe-root canvas,#twe-root audio,#twe-root iframe,#twe-root embed,#twe-root object{display:block;vertical-align:middle}#twe-root img,#twe-root video{max-width:100%;height:auto}#twe-root [hidden]:where(:not([hidden=until-found])){display:none}#twe-root,#twe-root [data-theme]{background-color:var(--fallback-b1,oklch(var(--b1)/1));color:var(--fallback-bc,oklch(var(--bc)/1))}@supports not (color: oklch(0% 0 0)){#twe-root{color-scheme:light;--fallback-p: #491eff;--fallback-pc: #d4dbff;--fallback-s: #ff41c7;--fallback-sc: #fff9fc;--fallback-a: #00cfbd;--fallback-ac: #00100d;--fallback-n: #2b3440;--fallback-nc: #d7dde4;--fallback-b1: #ffffff;--fallback-b2: #e5e6e6;--fallback-b3: #e5e6e6;--fallback-bc: #1f2937;--fallback-in: #00b3f0;--fallback-inc: #000000;--fallback-su: #00ca92;--fallback-suc: #000000;--fallback-wa: #ffc22d;--fallback-wac: #000000;--fallback-er: #ff6f70;--fallback-erc: #000000}@media(prefers-color-scheme:dark){#twe-root{color-scheme:dark;--fallback-p: #7582ff;--fallback-pc: #050617;--fallback-s: #ff71cf;--fallback-sc: #190211;--fallback-a: #00c7b5;--fallback-ac: #000e0c;--fallback-n: #2a323c;--fallback-nc: #a6adbb;--fallback-b1: #1d232a;--fallback-b2: #191e24;--fallback-b3: #15191e;--fallback-bc: #a6adbb;--fallback-in: #00b3f0;--fallback-inc: #000000;--fallback-su: #00ca92;--fallback-suc: #000000;--fallback-wa: #ffc22d;--fallback-wac: #000000;--fallback-er: #ff6f70;--fallback-erc: #000000}}}#twe-root{-webkit-tap-highlight-color:transparent}#twe-root *{scrollbar-color:color-mix(in oklch,currentColor 35%,transparent) transparent}#twe-root *:hover{scrollbar-color:color-mix(in oklch,currentColor 60%,transparent) transparent}#twe-root{color-scheme:light;--in: 72.06% .191 231.6;--su: 64.8% .15 160;--wa: 84.71% .199 83.87;--er: 71.76% .221 22.18;--pc: 15.2344% .017892 200.026556;--sc: 15.787% .020249 356.29965;--ac: 15.8762% .029206 78.618794;--nc: 84.7148% .013247 313.189598;--inc: 0% 0 0;--suc: 0% 0 0;--wac: 0% 0 0;--erc: 0% 0 0;--rounded-box: 16px;--rounded-badge: 30.4px;--animation-btn: .25s;--animation-input: .2s;--btn-focus-scale: .95;--border-btn: 1px;--p: 76.172% .089459 200.026556;--s: 78.9351% .101246 356.29965;--a: 79.3811% .146032 78.618794;--n: 23.5742% .066235 313.189598;--b1: 97.7882% .00418 56.375637;--b2: 93.9822% .007638 61.449292;--b3: 91.5861% .006811 53.440502;--bc: 23.5742% .066235 313.189598;--rounded-btn: 30.4px;--tab-border: 2px;--tab-radius: 11.2px}@media(prefers-color-scheme:dark){#twe-root{color-scheme:dark;--b2: 26.8053% .020556 277.508664;--b3: 24.7877% .019009 277.508664;--pc: 15.0922% .036614 346.812432;--sc: 14.8405% .029709 301.883095;--ac: 16.6785% .024826 66.558491;--nc: 87.8891% .006515 275.524078;--inc: 17.6526% .018676 212.846491;--suc: 17.4199% .043903 148.024881;--wac: 19.1068% .026849 112.757109;--erc: 13.6441% .041266 24.430965;--rounded-box: 16px;--rounded-btn: 8px;--rounded-badge: 30.4px;--animation-btn: .25s;--animation-input: .2s;--btn-focus-scale: .95;--border-btn: 1px;--tab-border: 1px;--tab-radius: 8px;--p: 75.4611% .18307 346.812432;--s: 74.2023% .148546 301.883095;--a: 83.3927% .124132 66.558491;--n: 39.4456% .032576 275.524078;--b1: 28.8229% .022103 277.508664;--bc: 97.7477% .007913 106.545019;--in: 88.263% .09338 212.846491;--su: 87.0995% .219516 148.024881;--wa: 95.5338% .134246 112.757109;--er: 68.2204% .206328 24.430965}}#twe-root [data-theme=cupcake]{color-scheme:light;--in: 72.06% .191 231.6;--su: 64.8% .15 160;--wa: 84.71% .199 83.87;--er: 71.76% .221 22.18;--pc: 15.2344% .017892 200.026556;--sc: 15.787% .020249 356.29965;--ac: 15.8762% .029206 78.618794;--nc: 84.7148% .013247 313.189598;--inc: 0% 0 0;--suc: 0% 0 0;--wac: 0% 0 0;--erc: 0% 0 0;--rounded-box: 16px;--rounded-badge: 30.4px;--animation-btn: .25s;--animation-input: .2s;--btn-focus-scale: .95;--border-btn: 1px;--p: 76.172% .089459 200.026556;--s: 78.9351% .101246 356.29965;--a: 79.3811% .146032 78.618794;--n: 23.5742% .066235 313.189598;--b1: 97.7882% .00418 56.375637;--b2: 93.9822% .007638 61.449292;--b3: 91.5861% .006811 53.440502;--bc: 23.5742% .066235 313.189598;--rounded-btn: 30.4px;--tab-border: 2px;--tab-radius: 11.2px}#twe-root [data-theme=dark]{color-scheme:dark;--in: 72.06% .191 231.6;--su: 64.8% .15 160;--wa: 84.71% .199 83.87;--er: 71.76% .221 22.18;--pc: 13.138% .0392 275.75;--sc: 14.96% .052 342.55;--ac: 14.902% .0334 183.61;--inc: 0% 0 0;--suc: 0% 0 0;--wac: 0% 0 0;--erc: 0% 0 0;--rounded-box: 16px;--rounded-btn: 8px;--rounded-badge: 30.4px;--animation-btn: .25s;--animation-input: .2s;--btn-focus-scale: .95;--border-btn: 1px;--tab-border: 1px;--tab-radius: 8px;--p: 65.69% .196 275.75;--s: 74.8% .26 342.55;--a: 74.51% .167 183.61;--n: 31.3815% .021108 254.139175;--nc: 74.6477% .0216 264.435964;--b1: 25.3267% .015896 252.417568;--b2: 23.2607% .013807 253.100675;--b3: 21.1484% .01165 254.087939;--bc: 74.6477% .0216 264.435964}#twe-root [data-theme=emerald]{color-scheme:light;--b2: 93% 0 0;--b3: 86% 0 0;--in: 72.06% .191 231.6;--su: 64.8% .15 160;--wa: 84.71% .199 83.87;--er: 71.76% .221 22.18;--inc: 0% 0 0;--suc: 0% 0 0;--wac: 0% 0 0;--erc: 0% 0 0;--rounded-box: 16px;--rounded-btn: 8px;--rounded-badge: 30.4px;--border-btn: 1px;--tab-border: 1px;--tab-radius: 8px;--p: 76.6626% .135433 153.450024;--pc: 33.3872% .040618 162.240129;--s: 61.3028% .202368 261.294233;--sc: 100% 0 0;--a: 72.7725% .149783 33.200363;--ac: 0% 0 0;--n: 35.5192% .032071 262.988584;--nc: 98.4625% .001706 247.838921;--b1: 100% 0 0;--bc: 35.5192% .032071 262.988584;--animation-btn: 0;--animation-input: 0;--btn-focus-scale: 1}#twe-root [data-theme=cyberpunk]{color-scheme:light;--b2: 87.8943% .16647 104.32;--b3: 81.2786% .15394 104.32;--in: 72.06% .191 231.6;--su: 64.8% .15 160;--wa: 84.71% .199 83.87;--er: 71.76% .221 22.18;--bc: 18.902% .0358 104.32;--pc: 14.844% .0418 6.35;--sc: 16.666% .0368 204.72;--ac: 14.372% .04352 310.43;--inc: 0% 0 0;--suc: 0% 0 0;--wac: 0% 0 0;--erc: 0% 0 0;--animation-btn: .25s;--animation-input: .2s;--btn-focus-scale: .95;--border-btn: 1px;--tab-border: 1px;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;--p: 74.22% .209 6.35;--s: 83.33% .184 204.72;--a: 71.86% .2176 310.43;--n: 23.04% .065 269.31;--nc: 94.51% .179 104.32;--b1: 94.51% .179 104.32;--rounded-box: 0;--rounded-btn: 0;--rounded-badge: 0;--tab-radius: 0}#twe-root [data-theme=valentine]{color-scheme:light;--b2: 88.0567% .024834 337.06289;--b3: 81.4288% .022964 337.06289;--pc: 13.7239% .030755 15.066527;--sc: 14.3942% .029258 293.189609;--ac: 14.2537% .014961 197.828857;--inc: 90.923% .043042 262.880917;--suc: 12.541% .033982 149.213788;--wac: 13.3168% .031484 58.31834;--erc: 14.614% .0414 27.33;--rounded-box: 16px;--rounded-badge: 30.4px;--animation-btn: .25s;--animation-input: .2s;--btn-focus-scale: .95;--border-btn: 1px;--tab-border: 1px;--p: 68.6197% .153774 15.066527;--s: 71.971% .14629 293.189609;--a: 71.2685% .074804 197.828857;--n: 54.6053% .143342 358.004839;--nc: 90.2701% .037202 336.955191;--b1: 94.6846% .026703 337.06289;--bc: 37.3085% .081131 4.606426;--in: 54.615% .215208 262.880917;--su: 62.7052% .169912 149.213788;--wa: 66.584% .157422 58.31834;--er: 73.07% .207 27.33;--rounded-btn: 30.4px;--tab-radius: 11.2px}#twe-root [data-theme=lofi]{color-scheme:light;--inc: 15.908% .0206 205.9;--suc: 18.026% .0306 164.14;--wac: 17.674% .027 79.94;--erc: 15.732% .03 28.47;--border-btn: 1px;--tab-border: 1px;--p: 15.9066% 0 0;--pc: 100% 0 0;--s: 21.455% .001566 17.278957;--sc: 100% 0 0;--a: 26.8618% 0 0;--ac: 100% 0 0;--n: 0% 0 0;--nc: 100% 0 0;--b1: 100% 0 0;--b2: 96.1151% 0 0;--b3: 92.268% .001082 17.17934;--bc: 0% 0 0;--in: 79.54% .103 205.9;--su: 90.13% .153 164.14;--wa: 88.37% .135 79.94;--er: 78.66% .15 28.47;--rounded-box: 4px;--rounded-btn: 2px;--rounded-badge: 2px;--tab-radius: 2px;--animation-btn: 0;--animation-input: 0;--btn-focus-scale: 1}#twe-root [data-theme=dracula]{color-scheme:dark;--b2: 26.8053% .020556 277.508664;--b3: 24.7877% .019009 277.508664;--pc: 15.0922% .036614 346.812432;--sc: 14.8405% .029709 301.883095;--ac: 16.6785% .024826 66.558491;--nc: 87.8891% .006515 275.524078;--inc: 17.6526% .018676 212.846491;--suc: 17.4199% .043903 148.024881;--wac: 19.1068% .026849 112.757109;--erc: 13.6441% .041266 24.430965;--rounded-box: 16px;--rounded-btn: 8px;--rounded-badge: 30.4px;--animation-btn: .25s;--animation-input: .2s;--btn-focus-scale: .95;--border-btn: 1px;--tab-border: 1px;--tab-radius: 8px;--p: 75.4611% .18307 346.812432;--s: 74.2023% .148546 301.883095;--a: 83.3927% .124132 66.558491;--n: 39.4456% .032576 275.524078;--b1: 28.8229% .022103 277.508664;--bc: 97.7477% .007913 106.545019;--in: 88.263% .09338 212.846491;--su: 87.0995% .219516 148.024881;--wa: 95.5338% .134246 112.757109;--er: 68.2204% .206328 24.430965}#twe-root [data-theme=cmyk]{color-scheme:light;--b2: 93% 0 0;--b3: 86% 0 0;--bc: 20% 0 0;--pc: 14.3544% .02666 239.443325;--sc: 12.8953% .040552 359.339283;--ac: 18.8458% .037948 105.306968;--nc: 84.3557% 0 0;--inc: 13.6952% .0189 217.284104;--suc: 89.3898% .032505 321.406278;--wac: 14.2473% .031969 52.023412;--erc: 12.4027% .041677 28.717543;--rounded-box: 16px;--rounded-btn: 8px;--rounded-badge: 30.4px;--animation-btn: .25s;--animation-input: .2s;--btn-focus-scale: .95;--border-btn: 1px;--tab-border: 1px;--tab-radius: 8px;--p: 71.7722% .133298 239.443325;--s: 64.4766% .202758 359.339283;--a: 94.2289% .189741 105.306968;--n: 21.7787% 0 0;--b1: 100% 0 0;--in: 68.4759% .094499 217.284104;--su: 46.949% .162524 321.406278;--wa: 71.2364% .159843 52.023412;--er: 62.0133% .208385 28.717543}#twe-root [data-theme=business]{color-scheme:dark;--b2: 22.6487% 0 0;--b3: 20.944% 0 0;--bc: 84.8707% 0 0;--pc: 88.3407% .019811 251.473931;--sc: 12.8185% .005481 229.389418;--ac: 13.4542% .033545 35.791525;--nc: 85.4882% .00265 253.041249;--inc: 12.5233% .028702 240.033697;--suc: 14.0454% .018919 156.59611;--wac: 15.4965% .023141 81.519177;--erc: 90.3221% .029356 29.674507;--animation-btn: .25s;--animation-input: .2s;--btn-focus-scale: .95;--border-btn: 1px;--tab-border: 1px;--tab-radius: 8px;--p: 41.7036% .099057 251.473931;--s: 64.0924% .027405 229.389418;--a: 67.271% .167726 35.791525;--n: 27.441% .01325 253.041249;--b1: 24.3535% 0 0;--in: 62.6163% .143511 240.033697;--su: 70.2268% .094594 156.59611;--wa: 77.4824% .115704 81.519177;--er: 51.6105% .14678 29.674507;--rounded-box: 4px;--rounded-btn: 2px;--rounded-badge: 2px}#twe-root [data-theme=winter]{color-scheme:light;--pc: 91.372% .051 257.57;--sc: 88.5103% .03222 282.339433;--ac: 11.988% .038303 335.171434;--nc: 83.9233% .012704 257.651965;--inc: 17.6255% .017178 214.515264;--suc: 16.0988% .015404 197.823719;--wac: 17.8345% .009167 71.47031;--erc: 14.6185% .022037 20.076293;--rounded-box: 16px;--rounded-btn: 8px;--rounded-badge: 30.4px;--animation-btn: .25s;--animation-input: .2s;--btn-focus-scale: .95;--border-btn: 1px;--tab-border: 1px;--tab-radius: 8px;--p: 56.86% .255 257.57;--s: 42.5516% .161098 282.339433;--a: 59.9398% .191515 335.171434;--n: 19.6166% .063518 257.651965;--b1: 100% 0 0;--b2: 97.4663% .011947 259.822565;--b3: 93.2686% .016223 262.751375;--bc: 41.8869% .053885 255.824911;--in: 88.1275% .085888 214.515264;--su: 80.4941% .077019 197.823719;--wa: 89.1725% .045833 71.47031;--er: 73.0926% .110185 20.076293}#twe-root .alert{display:grid;width:100%;grid-auto-flow:row;align-content:flex-start;align-items:center;justify-items:center;gap:16px;text-align:center;border-radius:var(--rounded-box, 16px);border-width:1px;--tw-border-opacity: 1;border-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-border-opacity)));padding:16px;--tw-text-opacity: 1;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)));--alert-bg: var(--fallback-b2,oklch(var(--b2)/1));--alert-bg-mix: var(--fallback-b1,oklch(var(--b1)/1));background-color:var(--alert-bg)}@media(min-width:640px){#twe-root .alert{grid-auto-flow:column;grid-template-columns:auto minmax(auto,1fr);justify-items:start;text-align:start}}#twe-root .avatar{position:relative;display:inline-flex}#twe-root .avatar>div{display:block;aspect-ratio:1 / 1;overflow:hidden}#twe-root .avatar img{height:100%;width:100%;-o-object-fit:cover;object-fit:cover}#twe-root .avatar.placeholder>div{display:flex;align-items:center;justify-content:center}#twe-root .badge{display:inline-flex;align-items:center;justify-content:center;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-timing-function:cubic-bezier(0,0,.2,1);transition-duration:.2s;height:20px;font-size:14px;line-height:20px;width:-moz-fit-content;width:fit-content;padding-left:9.008px;padding-right:9.008px;border-radius:var(--rounded-badge, 30.4px);border-width:1px;--tw-border-opacity: 1;border-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-border-opacity)));--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)));--tw-text-opacity: 1;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)))}@media(hover:hover){#twe-root .checkbox-accent:hover{--tw-border-opacity: 1;border-color:var(--fallback-a,oklch(var(--a)/var(--tw-border-opacity)))}#twe-root .label a:hover{--tw-text-opacity: 1;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)))}#twe-root .menu li>*:not(ul,.menu-title,details,.btn):active,#twe-root .menu li>*:not(ul,.menu-title,details,.btn).active,#twe-root .menu li>details>summary:active{--tw-bg-opacity: 1;background-color:var(--fallback-n,oklch(var(--n)/var(--tw-bg-opacity)));--tw-text-opacity: 1;color:var(--fallback-nc,oklch(var(--nc)/var(--tw-text-opacity)))}#twe-root .tab:hover{--tw-text-opacity: 1}#twe-root .table tr.hover:hover,#twe-root .table tr.hover:nth-child(2n):hover{--tw-bg-opacity: 1;background-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-bg-opacity)))}#twe-root .\\!table tr.hover:hover,#twe-root .\\!table tr.hover:nth-child(2n):hover{--tw-bg-opacity: 1 !important;background-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-bg-opacity)))!important}#twe-root .table-zebra tr.hover:hover,#twe-root .table-zebra tr.hover:nth-child(2n):hover{--tw-bg-opacity: 1;background-color:var(--fallback-b3,oklch(var(--b3)/var(--tw-bg-opacity)))}}#twe-root .btn{display:inline-flex;height:48px;min-height:48px;flex-shrink:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;user-select:none;flex-wrap:wrap;align-items:center;justify-content:center;border-radius:var(--rounded-btn, 8px);border-color:transparent;border-color:oklch(var(--btn-color, var(--b2)) / var(--tw-border-opacity));padding-left:16px;padding-right:16px;text-align:center;font-size:14px;line-height:1em;gap:8px;font-weight:600;text-decoration-line:none;transition-duration:.2s;transition-timing-function:cubic-bezier(0,0,.2,1);border-width:var(--border-btn, 1px);transition-property:color,background-color,border-color,opacity,box-shadow,transform;--tw-text-opacity: 1;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)));--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);outline-color:var(--fallback-bc,oklch(var(--bc)/1));background-color:oklch(var(--btn-color, var(--b2)) / var(--tw-bg-opacity));--tw-bg-opacity: 1;--tw-border-opacity: 1}#twe-root .btn-disabled,#twe-root .btn[disabled],#twe-root .btn:disabled{pointer-events:none}#twe-root :where(.btn:is(input[type=checkbox])),#twe-root :where(.btn:is(input[type=radio])){width:auto;-webkit-appearance:none;-moz-appearance:none;appearance:none}#twe-root .btn:is(input[type=checkbox]):after,#twe-root .btn:is(input[type=radio]):after{--tw-content: attr(aria-label);content:var(--tw-content)}#twe-root .card{position:relative;display:flex;flex-direction:column;border-radius:var(--rounded-box, 16px)}#twe-root .card:focus{outline:2px solid transparent;outline-offset:2px}#twe-root .card figure{display:flex;align-items:center;justify-content:center}#twe-root .card.image-full{display:grid}#twe-root .card.image-full:before{position:relative;content:"";z-index:10;border-radius:var(--rounded-box, 16px);--tw-bg-opacity: 1;background-color:var(--fallback-n,oklch(var(--n)/var(--tw-bg-opacity)));opacity:.75}#twe-root .card.image-full:before,#twe-root .card.image-full>*{grid-column-start:1;grid-row-start:1}#twe-root .card.image-full>figure img{height:100%;-o-object-fit:cover;object-fit:cover}#twe-root .card.image-full>.card-body{position:relative;z-index:20;--tw-text-opacity: 1;color:var(--fallback-nc,oklch(var(--nc)/var(--tw-text-opacity)))}#twe-root .checkbox{flex-shrink:0;--chkbg: var(--fallback-bc,oklch(var(--bc)/1));--chkfg: var(--fallback-b1,oklch(var(--b1)/1));height:24px;width:24px;cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:var(--rounded-btn, 8px);border-width:1px;border-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-border-opacity)));--tw-border-opacity: .2}#twe-root .divider{display:flex;flex-direction:row;align-items:center;align-self:stretch;margin-top:16px;margin-bottom:16px;height:16px;white-space:nowrap}#twe-root .divider:before,#twe-root .divider:after{height:2px;width:100%;flex-grow:1;--tw-content: "";content:var(--tw-content);background-color:var(--fallback-bc,oklch(var(--bc)/.1))}#twe-root .dropdown{position:relative;display:inline-block}#twe-root .dropdown>*:not(summary):focus{outline:2px solid transparent;outline-offset:2px}#twe-root .dropdown .dropdown-content{position:absolute}#twe-root .dropdown:is(:not(details)) .dropdown-content{visibility:hidden;opacity:0;transform-origin:top;--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-timing-function:cubic-bezier(0,0,.2,1);transition-duration:.2s}#twe-root .dropdown-end .dropdown-content{inset-inline-end:0px}#twe-root .dropdown-left .dropdown-content{bottom:auto;inset-inline-end:100%;top:0;transform-origin:right}#twe-root .dropdown-right .dropdown-content{bottom:auto;inset-inline-start:100%;top:0;transform-origin:left}#twe-root .dropdown-bottom .dropdown-content{bottom:auto;top:100%;transform-origin:top}#twe-root .dropdown-top .dropdown-content{bottom:100%;top:auto;transform-origin:bottom}#twe-root .dropdown-end.dropdown-right .dropdown-content,#twe-root .dropdown-end.dropdown-left .dropdown-content{bottom:0;top:auto}#twe-root .dropdown.dropdown-open .dropdown-content,#twe-root .dropdown:not(.dropdown-hover):focus .dropdown-content,#twe-root .dropdown:focus-within .dropdown-content{visibility:visible;opacity:1}@media(hover:hover){#twe-root .dropdown.dropdown-hover:hover .dropdown-content{visibility:visible;opacity:1}#twe-root .btm-nav>*.disabled:hover,#twe-root .btm-nav>*[disabled]:hover{pointer-events:none;--tw-border-opacity: 0;background-color:var(--fallback-n,oklch(var(--n)/var(--tw-bg-opacity)));--tw-bg-opacity: .1;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)));--tw-text-opacity: .2}#twe-root .btn:hover{--tw-border-opacity: 1;border-color:var(--fallback-b3,oklch(var(--b3)/var(--tw-border-opacity)));--tw-bg-opacity: 1;background-color:var(--fallback-b3,oklch(var(--b3)/var(--tw-bg-opacity)))}@supports (color: color-mix(in oklab,black,black)){#twe-root .btn:hover{background-color:color-mix(in oklab,oklch(var(--btn-color, var(--b2)) / var(--tw-bg-opacity, 1)) 90%,black);border-color:color-mix(in oklab,oklch(var(--btn-color, var(--b2)) / var(--tw-border-opacity, 1)) 90%,black)}}@supports not (color: oklch(0% 0 0)){#twe-root .btn:hover{background-color:var(--btn-color, var(--fallback-b2));border-color:var(--btn-color, var(--fallback-b2))}}#twe-root .btn.glass:hover{--glass-opacity: 25%;--glass-border-opacity: 15%}#twe-root .btn-ghost:hover{border-color:transparent}@supports (color: oklch(0% 0 0)){#twe-root .btn-ghost:hover{background-color:var(--fallback-bc,oklch(var(--bc)/.2))}}#twe-root .btn-outline:hover{--tw-border-opacity: 1;border-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-border-opacity)));--tw-bg-opacity: 1;background-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-bg-opacity)));--tw-text-opacity: 1;color:var(--fallback-b1,oklch(var(--b1)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-primary:hover{--tw-text-opacity: 1;color:var(--fallback-pc,oklch(var(--pc)/var(--tw-text-opacity)))}@supports (color: color-mix(in oklab,black,black)){#twe-root .btn-outline.btn-primary:hover{background-color:color-mix(in oklab,var(--fallback-p,oklch(var(--p)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-p,oklch(var(--p)/1)) 90%,black)}}#twe-root .btn-outline.btn-secondary:hover{--tw-text-opacity: 1;color:var(--fallback-sc,oklch(var(--sc)/var(--tw-text-opacity)))}@supports (color: color-mix(in oklab,black,black)){#twe-root .btn-outline.btn-secondary:hover{background-color:color-mix(in oklab,var(--fallback-s,oklch(var(--s)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-s,oklch(var(--s)/1)) 90%,black)}}#twe-root .btn-outline.btn-accent:hover{--tw-text-opacity: 1;color:var(--fallback-ac,oklch(var(--ac)/var(--tw-text-opacity)))}@supports (color: color-mix(in oklab,black,black)){#twe-root .btn-outline.btn-accent:hover{background-color:color-mix(in oklab,var(--fallback-a,oklch(var(--a)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-a,oklch(var(--a)/1)) 90%,black)}}#twe-root .btn-outline.btn-success:hover{--tw-text-opacity: 1;color:var(--fallback-suc,oklch(var(--suc)/var(--tw-text-opacity)))}@supports (color: color-mix(in oklab,black,black)){#twe-root .btn-outline.btn-success:hover{background-color:color-mix(in oklab,var(--fallback-su,oklch(var(--su)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-su,oklch(var(--su)/1)) 90%,black)}}#twe-root .btn-outline.btn-info:hover{--tw-text-opacity: 1;color:var(--fallback-inc,oklch(var(--inc)/var(--tw-text-opacity)))}@supports (color: color-mix(in oklab,black,black)){#twe-root .btn-outline.btn-info:hover{background-color:color-mix(in oklab,var(--fallback-in,oklch(var(--in)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-in,oklch(var(--in)/1)) 90%,black)}}#twe-root .btn-outline.btn-warning:hover{--tw-text-opacity: 1;color:var(--fallback-wac,oklch(var(--wac)/var(--tw-text-opacity)))}@supports (color: color-mix(in oklab,black,black)){#twe-root .btn-outline.btn-warning:hover{background-color:color-mix(in oklab,var(--fallback-wa,oklch(var(--wa)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-wa,oklch(var(--wa)/1)) 90%,black)}}#twe-root .btn-outline.btn-error:hover{--tw-text-opacity: 1;color:var(--fallback-erc,oklch(var(--erc)/var(--tw-text-opacity)))}@supports (color: color-mix(in oklab,black,black)){#twe-root .btn-outline.btn-error:hover{background-color:color-mix(in oklab,var(--fallback-er,oklch(var(--er)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-er,oklch(var(--er)/1)) 90%,black)}}#twe-root .btn-disabled:hover,#twe-root .btn[disabled]:hover,#twe-root .btn:disabled:hover{--tw-border-opacity: 0;background-color:var(--fallback-n,oklch(var(--n)/var(--tw-bg-opacity)));--tw-bg-opacity: .2;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)));--tw-text-opacity: .2}@supports (color: color-mix(in oklab,black,black)){#twe-root .btn:is(input[type=checkbox]:checked):hover,#twe-root .btn:is(input[type=radio]:checked):hover{background-color:color-mix(in oklab,var(--fallback-p,oklch(var(--p)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-p,oklch(var(--p)/1)) 90%,black)}}#twe-root .dropdown.dropdown-hover:hover .dropdown-content{--tw-scale-x: 1;--tw-scale-y: 1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#twe-root :where(.menu li:not(.menu-title,.disabled)>*:not(ul,details,.menu-title)):not(.active,.btn):hover,#twe-root :where(.menu li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(.active,.btn):hover{cursor:pointer;outline:2px solid transparent;outline-offset:2px}@supports (color: oklch(0% 0 0)){#twe-root :where(.menu li:not(.menu-title,.disabled)>*:not(ul,details,.menu-title)):not(.active,.btn):hover,#twe-root :where(.menu li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(.active,.btn):hover{background-color:var(--fallback-bc,oklch(var(--bc)/.1))}}#twe-root .tab[disabled],#twe-root .tab[disabled]:hover{cursor:not-allowed;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)));--tw-text-opacity: .2}}#twe-root .dropdown:is(details) summary::-webkit-details-marker{display:none}#twe-root .file-input{height:48px;flex-shrink:1;padding-inline-end:16px;font-size:16px;line-height:2;line-height:24px;overflow:hidden;border-radius:var(--rounded-btn, 8px);border-width:1px;border-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-border-opacity)));--tw-border-opacity: 0;--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)))}#twe-root .file-input::file-selector-button{margin-inline-end:16px;display:inline-flex;height:100%;flex-shrink:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;user-select:none;flex-wrap:wrap;align-items:center;justify-content:center;padding-left:16px;padding-right:16px;text-align:center;font-size:14px;line-height:20px;line-height:1em;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-timing-function:cubic-bezier(0,0,.2,1);transition-duration:.2s;border-style:solid;--tw-border-opacity: 1;border-color:var(--fallback-n,oklch(var(--n)/var(--tw-border-opacity)));--tw-bg-opacity: 1;background-color:var(--fallback-n,oklch(var(--n)/var(--tw-bg-opacity)));font-weight:600;text-transform:uppercase;--tw-text-opacity: 1;color:var(--fallback-nc,oklch(var(--nc)/var(--tw-text-opacity)));text-decoration-line:none;border-width:var(--border-btn, 1px);animation:button-pop var(--animation-btn, .25s) ease-out}#twe-root .footer{display:grid;width:100%;grid-auto-flow:row;place-items:start;-moz-column-gap:16px;column-gap:16px;row-gap:40px;font-size:14px;line-height:20px}#twe-root .footer>*{display:grid;place-items:start;gap:8px}@media(min-width:48rem){#twe-root .footer{grid-auto-flow:column}#twe-root .footer-center{grid-auto-flow:row dense}}#twe-root .form-control{display:flex;flex-direction:column}#twe-root .label{display:flex;-webkit-user-select:none;-moz-user-select:none;user-select:none;align-items:center;justify-content:space-between;padding:8px 4px}#twe-root .input{flex-shrink:1;-webkit-appearance:none;-moz-appearance:none;appearance:none;height:48px;padding-left:16px;padding-right:16px;font-size:16px;line-height:2;line-height:24px;border-radius:var(--rounded-btn, 8px);border-width:1px;border-color:transparent;--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)))}#twe-root .input[type=number]::-webkit-inner-spin-button,#twe-root .input-md[type=number]::-webkit-inner-spin-button{margin-top:-16px;margin-bottom:-16px;margin-inline-end:-16px}#twe-root .input-xs[type=number]::-webkit-inner-spin-button{margin-top:-4px;margin-bottom:-4px;margin-inline-end:-0px}#twe-root .input-sm[type=number]::-webkit-inner-spin-button{margin-top:0;margin-bottom:0;margin-inline-end:-0px}#twe-root .join{display:inline-flex;align-items:stretch;border-radius:var(--rounded-btn, 8px)}#twe-root .join :where(.join-item){border-start-end-radius:0;border-end-end-radius:0;border-end-start-radius:0;border-start-start-radius:0}#twe-root .join .join-item:not(:first-child):not(:last-child),#twe-root .join *:not(:first-child):not(:last-child) .join-item{border-start-end-radius:0;border-end-end-radius:0;border-end-start-radius:0;border-start-start-radius:0}#twe-root .join .join-item:first-child:not(:last-child),#twe-root .join *:first-child:not(:last-child) .join-item{border-start-end-radius:0;border-end-end-radius:0}#twe-root .join .dropdown .join-item:first-child:not(:last-child),#twe-root .join *:first-child:not(:last-child) .dropdown .join-item{border-start-end-radius:inherit;border-end-end-radius:inherit}#twe-root .join :where(.join-item:first-child:not(:last-child)),#twe-root .join :where(*:first-child:not(:last-child) .join-item){border-end-start-radius:inherit;border-start-start-radius:inherit}#twe-root .join .join-item:last-child:not(:first-child),#twe-root .join *:last-child:not(:first-child) .join-item{border-end-start-radius:0;border-start-start-radius:0}#twe-root .join :where(.join-item:last-child:not(:first-child)),#twe-root .join :where(*:last-child:not(:first-child) .join-item){border-start-end-radius:inherit;border-end-end-radius:inherit}@supports not selector(:has(*)){#twe-root :where(.join *){border-radius:inherit}}@supports selector(:has(*)){#twe-root :where(.join *:has(.join-item)){border-radius:inherit}}#twe-root .link{cursor:pointer;text-decoration-line:underline}#twe-root .menu{display:flex;flex-direction:column;flex-wrap:wrap;font-size:14px;line-height:20px;padding:8px}#twe-root .menu :where(li ul){position:relative;white-space:nowrap;margin-inline-start:16px;padding-inline-start:8px}#twe-root .menu :where(li:not(.menu-title)>*:not(ul,details,.menu-title,.btn)),#twe-root .menu :where(li:not(.menu-title)>details>summary:not(.menu-title)){display:grid;grid-auto-flow:column;align-content:flex-start;align-items:center;gap:8px;grid-auto-columns:minmax(auto,max-content) auto max-content;-webkit-user-select:none;-moz-user-select:none;user-select:none}#twe-root .menu li.disabled{cursor:not-allowed;-webkit-user-select:none;-moz-user-select:none;user-select:none;color:var(--fallback-bc,oklch(var(--bc)/.3))}#twe-root .menu :where(li>.menu-dropdown:not(.menu-dropdown-show)){display:none}#twe-root :where(.menu li){position:relative;display:flex;flex-shrink:0;flex-direction:column;flex-wrap:wrap;align-items:stretch}#twe-root :where(.menu li) .badge{justify-self:end}#twe-root .modal{pointer-events:none;position:fixed;top:0;right:0;bottom:0;left:0;margin:0;display:grid;height:100%;max-height:none;width:100%;max-width:none;justify-items:center;padding:0;opacity:0;overscroll-behavior:contain;z-index:999;background-color:transparent;color:inherit;transition-duration:.2s;transition-timing-function:cubic-bezier(0,0,.2,1);transition-property:transform,opacity,visibility;overflow-y:hidden}#twe-root :where(.modal){align-items:center}#twe-root .modal-box{max-height:calc(100vh - 5em);grid-column-start:1;grid-row-start:1;width:91.666667%;max-width:512px;--tw-scale-x: .9;--tw-scale-y: .9;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));border-bottom-right-radius:var(--rounded-box, 16px);border-bottom-left-radius:var(--rounded-box, 16px);border-top-left-radius:var(--rounded-box, 16px);border-top-right-radius:var(--rounded-box, 16px);--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)));padding:24px;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-timing-function:cubic-bezier(0,0,.2,1);transition-duration:.2s;box-shadow:#00000040 0 25px 50px -12px;overflow-y:auto;overscroll-behavior:contain}#twe-root .modal-open,#twe-root .modal:target,#twe-root .modal-toggle:checked+.modal,#twe-root .modal[open]{pointer-events:auto;visibility:visible;opacity:1}#twe-root:has(:is(.modal-open,.modal:target,.modal-toggle:checked+.modal,.modal[open])){overflow:hidden;scrollbar-gutter:stable}#twe-root .progress{position:relative;width:100%;-webkit-appearance:none;-moz-appearance:none;appearance:none;overflow:hidden;height:8px;border-radius:var(--rounded-box, 16px);background-color:var(--fallback-bc,oklch(var(--bc)/.2))}#twe-root .radio{flex-shrink:0;--chkbg: var(--bc);height:24px;width:24px;cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:9999px;border-width:1px;border-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-border-opacity)));--tw-border-opacity: .2}#twe-root .range{height:24px;width:100%;cursor:pointer;-moz-appearance:none;appearance:none;-webkit-appearance:none;--range-shdw: var(--fallback-bc,oklch(var(--bc)/1));overflow:hidden;border-radius:var(--rounded-box, 16px);background-color:transparent}#twe-root .range:focus{outline:none}#twe-root .select{display:inline-flex;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;user-select:none;-webkit-appearance:none;-moz-appearance:none;appearance:none;height:48px;min-height:48px;padding-inline-start:16px;padding-inline-end:40px;font-size:14px;line-height:20px;line-height:2;border-radius:var(--rounded-btn, 8px);border-width:1px;border-color:transparent;--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)));background-image:linear-gradient(45deg,transparent 50%,currentColor 50%),linear-gradient(135deg,currentColor 50%,transparent 50%);background-position:calc(100% - 20px) calc(1px + 50%),calc(100% - 16.1px) calc(1px + 50%);background-size:4px 4px,4px 4px;background-repeat:no-repeat}#twe-root .select[multiple]{height:auto}#twe-root .stack{display:inline-grid;place-items:center;align-items:flex-end}#twe-root .stack>*{grid-column-start:1;grid-row-start:1;transform:translateY(10%) scale(.9);z-index:1;width:100%;opacity:.6}#twe-root .stack>*:nth-child(2){transform:translateY(5%) scale(.95);z-index:2;opacity:.8}#twe-root .stack>*:nth-child(1){transform:translateY(0) scale(1);z-index:3;opacity:1}#twe-root .stats{display:inline-grid;border-radius:var(--rounded-box, 16px);--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)));--tw-text-opacity: 1;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)))}#twe-root :where(.stats){grid-auto-flow:column;overflow-x:auto}#twe-root .tabs{display:grid;align-items:flex-end}#twe-root .tabs-lifted:has(.tab-content[class^=rounded-]) .tab:first-child:not(:is(.tab-active,[aria-selected=true])),#twe-root .tabs-lifted:has(.tab-content[class*=" rounded-"]) .tab:first-child:not(:is(.tab-active,[aria-selected=true])){border-bottom-color:transparent}#twe-root .tab{position:relative;grid-row-start:1;display:inline-flex;height:32px;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;user-select:none;-webkit-appearance:none;-moz-appearance:none;appearance:none;flex-wrap:wrap;align-items:center;justify-content:center;text-align:center;font-size:14px;line-height:20px;line-height:2;--tab-padding: 16px;--tw-text-opacity: .5;--tab-color: var(--fallback-bc,oklch(var(--bc)/1));--tab-bg: var(--fallback-b1,oklch(var(--b1)/1));--tab-border-color: var(--fallback-b3,oklch(var(--b3)/1));color:var(--tab-color);padding-inline-start:var(--tab-padding, 16px);padding-inline-end:var(--tab-padding, 16px)}#twe-root .tab:is(input[type=radio]){width:auto;border-bottom-right-radius:0;border-bottom-left-radius:0}#twe-root .tab:is(input[type=radio]):after{--tw-content: attr(aria-label);content:var(--tw-content)}#twe-root .tab:not(input):empty{cursor:default;grid-column-start:span 9999}#twe-root input.tab:checked+.tab-content,#twe-root :is(.tab-active,[aria-selected=true])+.tab-content{display:block}#twe-root .\\!table{position:relative!important;width:100%!important;border-radius:var(--rounded-box, 16px)!important;text-align:left!important;font-size:14px!important;line-height:20px!important}#twe-root .table{position:relative;width:100%;border-radius:var(--rounded-box, 16px);text-align:left;font-size:14px;line-height:20px}#twe-root .\\!table :where(.table-pin-rows thead tr){position:sticky!important;top:0!important;z-index:1!important;--tw-bg-opacity: 1 !important;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)))!important}#twe-root .table :where(.table-pin-rows thead tr){position:sticky;top:0;z-index:1;--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)))}#twe-root .\\!table :where(.table-pin-rows tfoot tr){position:sticky!important;bottom:0!important;z-index:1!important;--tw-bg-opacity: 1 !important;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)))!important}#twe-root .table :where(.table-pin-rows tfoot tr){position:sticky;bottom:0;z-index:1;--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)))}#twe-root .\\!table :where(.table-pin-cols tr th){position:sticky!important;left:0!important;right:0!important;--tw-bg-opacity: 1 !important;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)))!important}#twe-root .table :where(.table-pin-cols tr th){position:sticky;left:0;right:0;--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)))}#twe-root .table-zebra tbody tr:nth-child(2n) :where(.table-pin-cols tr th){--tw-bg-opacity: 1;background-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-bg-opacity)))}#twe-root .textarea{min-height:48px;flex-shrink:1;padding:8px 16px;font-size:14px;line-height:20px;line-height:2;border-radius:var(--rounded-btn, 8px);border-width:1px;border-color:transparent;--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)))}#twe-root .\\!timeline{position:relative!important;display:flex!important}#twe-root .timeline{position:relative;display:flex}#twe-root :where(.\\!timeline>li){position:relative!important;display:grid!important;flex-shrink:0!important;align-items:center!important;grid-template-rows:var(--timeline-row-start, minmax(0, 1fr)) auto var( --timeline-row-end, minmax(0, 1fr) )!important;grid-template-columns:var(--timeline-col-start, minmax(0, 1fr)) auto var( --timeline-col-end, minmax(0, 1fr) )!important}#twe-root :where(.timeline>li){position:relative;display:grid;flex-shrink:0;align-items:center;grid-template-rows:var(--timeline-row-start, minmax(0, 1fr)) auto var( --timeline-row-end, minmax(0, 1fr) );grid-template-columns:var(--timeline-col-start, minmax(0, 1fr)) auto var( --timeline-col-end, minmax(0, 1fr) )}#twe-root .\\!timeline>li>hr{width:100%!important;border-width:0px!important}#twe-root .timeline>li>hr{width:100%;border-width:0px}#twe-root :where(.\\!timeline>li>hr):first-child{grid-column-start:1!important;grid-row-start:2!important}#twe-root :where(.timeline>li>hr):first-child{grid-column-start:1;grid-row-start:2}#twe-root :where(.\\!timeline>li>hr):last-child{grid-column-start:3!important;grid-column-end:none!important;grid-row-start:2!important;grid-row-end:auto!important}#twe-root :where(.timeline>li>hr):last-child{grid-column-start:3;grid-column-end:none;grid-row-start:2;grid-row-end:auto}#twe-root .toggle{flex-shrink:0;--tglbg: var(--fallback-b1,oklch(var(--b1)/1));--handleoffset: 24px;--handleoffsetcalculator: calc(var(--handleoffset) * -1);--togglehandleborder: 0 0;height:24px;width:48px;cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:var(--rounded-badge, 30.4px);border-width:1px;border-color:currentColor;background-color:currentColor;color:var(--fallback-bc,oklch(var(--bc)/.5));transition:background,box-shadow var(--animation-input, .2s) ease-out;box-shadow:var(--handleoffsetcalculator) 0 0 2px var(--tglbg) inset,0 0 0 2px var(--tglbg) inset,var(--togglehandleborder)}#twe-root .alert-error{border-color:var(--fallback-er,oklch(var(--er)/.2));--tw-text-opacity: 1;color:var(--fallback-erc,oklch(var(--erc)/var(--tw-text-opacity)));--alert-bg: var(--fallback-er,oklch(var(--er)/1));--alert-bg-mix: var(--fallback-b1,oklch(var(--b1)/1))}#twe-root .avatar-group :where(.avatar){overflow:hidden;border-radius:9999px;border-width:4px;--tw-border-opacity: 1;border-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-border-opacity)))}#twe-root .badge-outline{border-color:currentColor;--tw-border-opacity: .5;background-color:transparent;color:currentColor}#twe-root .badge-outline.badge-neutral{--tw-text-opacity: 1;color:var(--fallback-n,oklch(var(--n)/var(--tw-text-opacity)))}#twe-root .badge-outline.badge-primary{--tw-text-opacity: 1;color:var(--fallback-p,oklch(var(--p)/var(--tw-text-opacity)))}#twe-root .badge-outline.badge-secondary{--tw-text-opacity: 1;color:var(--fallback-s,oklch(var(--s)/var(--tw-text-opacity)))}#twe-root .badge-outline.badge-accent{--tw-text-opacity: 1;color:var(--fallback-a,oklch(var(--a)/var(--tw-text-opacity)))}#twe-root .badge-outline.badge-info{--tw-text-opacity: 1;color:var(--fallback-in,oklch(var(--in)/var(--tw-text-opacity)))}#twe-root .badge-outline.badge-success{--tw-text-opacity: 1;color:var(--fallback-su,oklch(var(--su)/var(--tw-text-opacity)))}#twe-root .badge-outline.badge-warning{--tw-text-opacity: 1;color:var(--fallback-wa,oklch(var(--wa)/var(--tw-text-opacity)))}#twe-root .badge-outline.badge-error{--tw-text-opacity: 1;color:var(--fallback-er,oklch(var(--er)/var(--tw-text-opacity)))}#twe-root .btm-nav>*:where(.active){border-top-width:2px;--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)))}#twe-root .btm-nav>*.disabled,#twe-root .btm-nav>*[disabled]{pointer-events:none;--tw-border-opacity: 0;background-color:var(--fallback-n,oklch(var(--n)/var(--tw-bg-opacity)));--tw-bg-opacity: .1;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)));--tw-text-opacity: .2}#twe-root .btm-nav>* .label{font-size:16px;line-height:24px}@media(prefers-reduced-motion:no-preference){#twe-root .btn{animation:button-pop var(--animation-btn, .25s) ease-out}}#twe-root .btn:active:hover,#twe-root .btn:active:focus{animation:button-pop 0s ease-out;transform:scale(var(--btn-focus-scale, .97))}@supports not (color: oklch(0% 0 0)){#twe-root .btn{background-color:var(--btn-color, var(--fallback-b2));border-color:var(--btn-color, var(--fallback-b2))}#twe-root .btn-primary{--btn-color: var(--fallback-p)}#twe-root .btn-secondary{--btn-color: var(--fallback-s)}#twe-root .btn-accent{--btn-color: var(--fallback-a)}#twe-root .btn-neutral{--btn-color: var(--fallback-n)}#twe-root .btn-info{--btn-color: var(--fallback-in)}#twe-root .btn-warning{--btn-color: var(--fallback-wa)}#twe-root .btn-error{--btn-color: var(--fallback-er)}}@supports (color: color-mix(in oklab,black,black)){#twe-root .btn-outline.btn-primary.btn-active{background-color:color-mix(in oklab,var(--fallback-p,oklch(var(--p)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-p,oklch(var(--p)/1)) 90%,black)}#twe-root .btn-outline.btn-secondary.btn-active{background-color:color-mix(in oklab,var(--fallback-s,oklch(var(--s)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-s,oklch(var(--s)/1)) 90%,black)}#twe-root .btn-outline.btn-accent.btn-active{background-color:color-mix(in oklab,var(--fallback-a,oklch(var(--a)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-a,oklch(var(--a)/1)) 90%,black)}#twe-root .btn-outline.btn-success.btn-active{background-color:color-mix(in oklab,var(--fallback-su,oklch(var(--su)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-su,oklch(var(--su)/1)) 90%,black)}#twe-root .btn-outline.btn-info.btn-active{background-color:color-mix(in oklab,var(--fallback-in,oklch(var(--in)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-in,oklch(var(--in)/1)) 90%,black)}#twe-root .btn-outline.btn-warning.btn-active{background-color:color-mix(in oklab,var(--fallback-wa,oklch(var(--wa)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-wa,oklch(var(--wa)/1)) 90%,black)}#twe-root .btn-outline.btn-error.btn-active{background-color:color-mix(in oklab,var(--fallback-er,oklch(var(--er)/1)) 90%,black);border-color:color-mix(in oklab,var(--fallback-er,oklch(var(--er)/1)) 90%,black)}}#twe-root .btn:focus-visible{outline-style:solid;outline-width:2px;outline-offset:2px}#twe-root .btn-primary{--tw-text-opacity: 1;color:var(--fallback-pc,oklch(var(--pc)/var(--tw-text-opacity)));outline-color:var(--fallback-p,oklch(var(--p)/1))}@supports (color: oklch(0% 0 0)){#twe-root .btn-primary{--btn-color: var(--p)}#twe-root .btn-secondary{--btn-color: var(--s)}#twe-root .btn-accent{--btn-color: var(--a)}#twe-root .btn-neutral{--btn-color: var(--n)}#twe-root .btn-info{--btn-color: var(--in)}#twe-root .btn-warning{--btn-color: var(--wa)}#twe-root .btn-error{--btn-color: var(--er)}}#twe-root .btn-secondary{--tw-text-opacity: 1;color:var(--fallback-sc,oklch(var(--sc)/var(--tw-text-opacity)));outline-color:var(--fallback-s,oklch(var(--s)/1))}#twe-root .btn-accent{--tw-text-opacity: 1;color:var(--fallback-ac,oklch(var(--ac)/var(--tw-text-opacity)));outline-color:var(--fallback-a,oklch(var(--a)/1))}#twe-root .btn-neutral{--tw-text-opacity: 1;color:var(--fallback-nc,oklch(var(--nc)/var(--tw-text-opacity)));outline-color:var(--fallback-n,oklch(var(--n)/1))}#twe-root .btn-info{--tw-text-opacity: 1;color:var(--fallback-inc,oklch(var(--inc)/var(--tw-text-opacity)));outline-color:var(--fallback-in,oklch(var(--in)/1))}#twe-root .btn-warning{--tw-text-opacity: 1;color:var(--fallback-wac,oklch(var(--wac)/var(--tw-text-opacity)));outline-color:var(--fallback-wa,oklch(var(--wa)/1))}#twe-root .btn-error{--tw-text-opacity: 1;color:var(--fallback-erc,oklch(var(--erc)/var(--tw-text-opacity)));outline-color:var(--fallback-er,oklch(var(--er)/1))}#twe-root .btn.glass{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);outline-color:currentColor}#twe-root .btn.glass.btn-active{--glass-opacity: 25%;--glass-border-opacity: 15%}#twe-root .btn-ghost{border-width:1px;border-color:transparent;background-color:transparent;color:currentColor;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);outline-color:currentColor}#twe-root .btn-ghost.btn-active{border-color:transparent;background-color:var(--fallback-bc,oklch(var(--bc)/.2))}#twe-root .btn-outline{border-color:currentColor;background-color:transparent;--tw-text-opacity: 1;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)));--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}#twe-root .btn-outline.btn-active{--tw-border-opacity: 1;border-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-border-opacity)));--tw-bg-opacity: 1;background-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-bg-opacity)));--tw-text-opacity: 1;color:var(--fallback-b1,oklch(var(--b1)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-primary{--tw-text-opacity: 1;color:var(--fallback-p,oklch(var(--p)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-primary.btn-active{--tw-text-opacity: 1;color:var(--fallback-pc,oklch(var(--pc)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-secondary{--tw-text-opacity: 1;color:var(--fallback-s,oklch(var(--s)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-secondary.btn-active{--tw-text-opacity: 1;color:var(--fallback-sc,oklch(var(--sc)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-accent{--tw-text-opacity: 1;color:var(--fallback-a,oklch(var(--a)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-accent.btn-active{--tw-text-opacity: 1;color:var(--fallback-ac,oklch(var(--ac)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-success{--tw-text-opacity: 1;color:var(--fallback-su,oklch(var(--su)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-success.btn-active{--tw-text-opacity: 1;color:var(--fallback-suc,oklch(var(--suc)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-info{--tw-text-opacity: 1;color:var(--fallback-in,oklch(var(--in)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-info.btn-active{--tw-text-opacity: 1;color:var(--fallback-inc,oklch(var(--inc)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-warning{--tw-text-opacity: 1;color:var(--fallback-wa,oklch(var(--wa)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-warning.btn-active{--tw-text-opacity: 1;color:var(--fallback-wac,oklch(var(--wac)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-error{--tw-text-opacity: 1;color:var(--fallback-er,oklch(var(--er)/var(--tw-text-opacity)))}#twe-root .btn-outline.btn-error.btn-active{--tw-text-opacity: 1;color:var(--fallback-erc,oklch(var(--erc)/var(--tw-text-opacity)))}#twe-root .btn.btn-disabled,#twe-root .btn[disabled],#twe-root .btn:disabled{--tw-border-opacity: 0;background-color:var(--fallback-n,oklch(var(--n)/var(--tw-bg-opacity)));--tw-bg-opacity: .2;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)));--tw-text-opacity: .2}#twe-root .btn:is(input[type=checkbox]:checked),#twe-root .btn:is(input[type=radio]:checked){--tw-border-opacity: 1;border-color:var(--fallback-p,oklch(var(--p)/var(--tw-border-opacity)));--tw-bg-opacity: 1;background-color:var(--fallback-p,oklch(var(--p)/var(--tw-bg-opacity)));--tw-text-opacity: 1;color:var(--fallback-pc,oklch(var(--pc)/var(--tw-text-opacity)))}#twe-root .btn:is(input[type=checkbox]:checked):focus-visible,#twe-root .btn:is(input[type=radio]:checked):focus-visible{outline-color:var(--fallback-p,oklch(var(--p)/1))}@keyframes button-pop{0%{transform:scale(var(--btn-focus-scale, .98))}40%{transform:scale(1.02)}to{transform:scale(1)}}#twe-root .card :where(figure:first-child){overflow:hidden;border-start-start-radius:inherit;border-start-end-radius:inherit;border-end-start-radius:unset;border-end-end-radius:unset}#twe-root .card :where(figure:last-child){overflow:hidden;border-start-start-radius:unset;border-start-end-radius:unset;border-end-start-radius:inherit;border-end-end-radius:inherit}#twe-root .card:focus-visible{outline:2px solid currentColor;outline-offset:2px}#twe-root .card.bordered{border-width:1px;--tw-border-opacity: 1;border-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-border-opacity)))}#twe-root .card.compact .card-body{padding:16px;font-size:14px;line-height:20px}#twe-root .card.image-full :where(figure){overflow:hidden;border-radius:inherit}#twe-root .checkbox:focus{box-shadow:none}#twe-root .checkbox:focus-visible{outline-style:solid;outline-width:2px;outline-offset:2px;outline-color:var(--fallback-bc,oklch(var(--bc)/1))}#twe-root .checkbox:disabled{border-width:0px;cursor:not-allowed;border-color:transparent;--tw-bg-opacity: 1;background-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-bg-opacity)));opacity:.2}#twe-root .checkbox:checked,#twe-root .checkbox[aria-checked=true]{background-repeat:no-repeat;animation:checkmark var(--animation-input, .2s) ease-out;background-color:var(--chkbg);background-image:linear-gradient(-45deg,transparent 65%,var(--chkbg) 65.99%),linear-gradient(45deg,transparent 75%,var(--chkbg) 75.99%),linear-gradient(-45deg,var(--chkbg) 40%,transparent 40.99%),linear-gradient(45deg,var(--chkbg) 30%,var(--chkfg) 30.99%,var(--chkfg) 40%,transparent 40.99%),linear-gradient(-45deg,var(--chkfg) 50%,var(--chkbg) 50.99%)}#twe-root .checkbox:indeterminate{--tw-bg-opacity: 1;background-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-bg-opacity)));background-repeat:no-repeat;animation:checkmark var(--animation-input, .2s) ease-out;background-image:linear-gradient(90deg,transparent 80%,var(--chkbg) 80%),linear-gradient(-90deg,transparent 80%,var(--chkbg) 80%),linear-gradient(0deg,var(--chkbg) 43%,var(--chkfg) 43%,var(--chkfg) 57%,var(--chkbg) 57%)}#twe-root .checkbox-accent{--chkbg: var(--fallback-a,oklch(var(--a)/1));--chkfg: var(--fallback-ac,oklch(var(--ac)/1));--tw-border-opacity: 1;border-color:var(--fallback-a,oklch(var(--a)/var(--tw-border-opacity)))}#twe-root .checkbox-accent:focus-visible{outline-color:var(--fallback-a,oklch(var(--a)/1))}#twe-root .checkbox-accent:checked,#twe-root .checkbox-accent[aria-checked=true]{--tw-border-opacity: 1;border-color:var(--fallback-a,oklch(var(--a)/var(--tw-border-opacity)));--tw-bg-opacity: 1;background-color:var(--fallback-a,oklch(var(--a)/var(--tw-bg-opacity)));--tw-text-opacity: 1;color:var(--fallback-ac,oklch(var(--ac)/var(--tw-text-opacity)))}@keyframes checkmark{0%{background-position-y:5px}50%{background-position-y:-2px}to{background-position-y:0}}#twe-root .divider:not(:empty){gap:16px}#twe-root .dropdown.dropdown-open .dropdown-content,#twe-root .dropdown:focus .dropdown-content,#twe-root .dropdown:focus-within .dropdown-content{--tw-scale-x: 1;--tw-scale-y: 1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#twe-root .file-input-bordered{--tw-border-opacity: .2}#twe-root .file-input:focus{outline-style:solid;outline-width:2px;outline-offset:2px;outline-color:var(--fallback-bc,oklch(var(--bc)/.2))}#twe-root .file-input-disabled,#twe-root .file-input[disabled]{cursor:not-allowed;--tw-border-opacity: 1;border-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-border-opacity)));--tw-bg-opacity: 1;background-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-bg-opacity)));--tw-text-opacity: .2}#twe-root .file-input-disabled::-moz-placeholder,#twe-root .file-input[disabled]::-moz-placeholder{color:var(--fallback-bc,oklch(var(--bc)/var(--tw-placeholder-opacity)));--tw-placeholder-opacity: .2}#twe-root .file-input-disabled::placeholder,#twe-root .file-input[disabled]::placeholder{color:var(--fallback-bc,oklch(var(--bc)/var(--tw-placeholder-opacity)));--tw-placeholder-opacity: .2}#twe-root .file-input-disabled::file-selector-button,#twe-root .file-input[disabled]::file-selector-button{--tw-border-opacity: 0;background-color:var(--fallback-n,oklch(var(--n)/var(--tw-bg-opacity)));--tw-bg-opacity: .2;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)));--tw-text-opacity: .2}#twe-root .label-text{font-size:14px;line-height:20px;--tw-text-opacity: 1;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)))}#twe-root .input input{--tw-bg-opacity: 1;background-color:var(--fallback-p,oklch(var(--p)/var(--tw-bg-opacity)));background-color:transparent}#twe-root .input input:focus{outline:2px solid transparent;outline-offset:2px}#twe-root .input[list]::-webkit-calendar-picker-indicator{line-height:1em}#twe-root .input-bordered{border-color:var(--fallback-bc,oklch(var(--bc)/.2))}#twe-root .input:focus,#twe-root .input:focus-within{box-shadow:none;border-color:var(--fallback-bc,oklch(var(--bc)/.2));outline-style:solid;outline-width:2px;outline-offset:2px;outline-color:var(--fallback-bc,oklch(var(--bc)/.2))}#twe-root .input:has(>input[disabled]),#twe-root .input-disabled,#twe-root .input:disabled,#twe-root .input[disabled]{cursor:not-allowed;--tw-border-opacity: 1;border-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-border-opacity)));--tw-bg-opacity: 1;background-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-bg-opacity)));color:var(--fallback-bc,oklch(var(--bc)/.4))}#twe-root .input:has(>input[disabled])::-moz-placeholder,#twe-root .input-disabled::-moz-placeholder,#twe-root .input:disabled::-moz-placeholder,#twe-root .input[disabled]::-moz-placeholder{color:var(--fallback-bc,oklch(var(--bc)/var(--tw-placeholder-opacity)));--tw-placeholder-opacity: .2}#twe-root .input:has(>input[disabled])::placeholder,#twe-root .input-disabled::placeholder,#twe-root .input:disabled::placeholder,#twe-root .input[disabled]::placeholder{color:var(--fallback-bc,oklch(var(--bc)/var(--tw-placeholder-opacity)));--tw-placeholder-opacity: .2}#twe-root .input:has(>input[disabled])>input[disabled]{cursor:not-allowed}#twe-root .input::-webkit-date-and-time-value{text-align:inherit}#twe-root .join>:where(*:not(:first-child)){margin-top:0;margin-bottom:0;margin-inline-start:-1px}#twe-root .join>:where(*:not(:first-child)):is(.btn){margin-inline-start:calc(var(--border-btn) * -1)}#twe-root .join-item:focus{isolation:isolate}#twe-root .link-primary{--tw-text-opacity: 1;color:var(--fallback-p,oklch(var(--p)/var(--tw-text-opacity)))}@supports (color:color-mix(in oklab,black,black)){@media(hover:hover){#twe-root .link-primary:hover{color:color-mix(in oklab,var(--fallback-p,oklch(var(--p)/1)) 80%,black)}}}#twe-root .link:focus{outline:2px solid transparent;outline-offset:2px}#twe-root .link:focus-visible{outline:2px solid currentColor;outline-offset:2px}#twe-root .loading{pointer-events:none;display:inline-block;aspect-ratio:1 / 1;width:24px;background-color:currentColor;-webkit-mask-size:100%;mask-size:100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;-webkit-mask-position:center;mask-position:center;-webkit-mask-image:url("data:image/svg+xml,%3Csvg width='24' height='24' stroke='black' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform-origin='center'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-width='3' stroke-linecap='round'%3E%3CanimateTransform attributeName='transform' type='rotate' from='0 12 12' to='360 12 12' dur='2s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dasharray' values='0,150;42,150;42,150' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dashoffset' values='0;-16;-59' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3C/circle%3E%3C/g%3E%3C/svg%3E");mask-image:url("data:image/svg+xml,%3Csvg width='24' height='24' stroke='black' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform-origin='center'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-width='3' stroke-linecap='round'%3E%3CanimateTransform attributeName='transform' type='rotate' from='0 12 12' to='360 12 12' dur='2s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dasharray' values='0,150;42,150;42,150' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dashoffset' values='0;-16;-59' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3C/circle%3E%3C/g%3E%3C/svg%3E")}#twe-root .loading-spinner{-webkit-mask-image:url("data:image/svg+xml,%3Csvg width='24' height='24' stroke='black' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform-origin='center'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-width='3' stroke-linecap='round'%3E%3CanimateTransform attributeName='transform' type='rotate' from='0 12 12' to='360 12 12' dur='2s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dasharray' values='0,150;42,150;42,150' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dashoffset' values='0;-16;-59' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3C/circle%3E%3C/g%3E%3C/svg%3E");mask-image:url("data:image/svg+xml,%3Csvg width='24' height='24' stroke='black' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform-origin='center'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-width='3' stroke-linecap='round'%3E%3CanimateTransform attributeName='transform' type='rotate' from='0 12 12' to='360 12 12' dur='2s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dasharray' values='0,150;42,150;42,150' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dashoffset' values='0;-16;-59' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3C/circle%3E%3C/g%3E%3C/svg%3E")}#twe-root .loading-xs{width:16px}#twe-root .loading-sm{width:20px}#twe-root :where(.menu li:empty){--tw-bg-opacity: 1;background-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-bg-opacity)));opacity:.1;margin:8px 16px;height:1px}#twe-root .menu :where(li ul):before{position:absolute;bottom:12px;inset-inline-start:0px;top:12px;width:1px;--tw-bg-opacity: 1;background-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-bg-opacity)));opacity:.1;content:""}#twe-root .menu :where(li:not(.menu-title)>*:not(ul,details,.menu-title,.btn)),#twe-root .menu :where(li:not(.menu-title)>details>summary:not(.menu-title)){border-radius:var(--rounded-btn, 8px);padding:8px 16px;text-align:start;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-timing-function:cubic-bezier(0,0,.2,1);transition-duration:.2s;text-wrap:balance}#twe-root :where(.menu li:not(.menu-title,.disabled)>*:not(ul,details,.menu-title)):not(summary,.active,.btn).focus,#twe-root :where(.menu li:not(.menu-title,.disabled)>*:not(ul,details,.menu-title)):not(summary,.active,.btn):focus,#twe-root :where(.menu li:not(.menu-title,.disabled)>*:not(ul,details,.menu-title)):is(summary):not(.active,.btn):focus-visible,#twe-root :where(.menu li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(summary,.active,.btn).focus,#twe-root :where(.menu li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(summary,.active,.btn):focus,#twe-root :where(.menu li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):is(summary):not(.active,.btn):focus-visible{cursor:pointer;background-color:var(--fallback-bc,oklch(var(--bc)/.1));--tw-text-opacity: 1;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)));outline:2px solid transparent;outline-offset:2px}#twe-root .menu li>*:not(ul,.menu-title,details,.btn):active,#twe-root .menu li>*:not(ul,.menu-title,details,.btn).active,#twe-root .menu li>details>summary:active{--tw-bg-opacity: 1;background-color:var(--fallback-n,oklch(var(--n)/var(--tw-bg-opacity)));--tw-text-opacity: 1;color:var(--fallback-nc,oklch(var(--nc)/var(--tw-text-opacity)))}#twe-root .menu :where(li>details>summary)::-webkit-details-marker{display:none}#twe-root .menu :where(li>details>summary):after,#twe-root .menu :where(li>.menu-dropdown-toggle):after{justify-self:end;display:block;margin-top:-8px;height:8px;width:8px;transform:rotate(45deg);transition-property:transform,margin-top;transition-duration:.3s;transition-timing-function:cubic-bezier(.4,0,.2,1);content:"";transform-origin:75% 75%;box-shadow:2px 2px;pointer-events:none}#twe-root .menu :where(li>details[open]>summary):after,#twe-root .menu :where(li>.menu-dropdown-toggle.menu-dropdown-show):after{transform:rotate(225deg);margin-top:0}#twe-root .mockup-phone .display{overflow:hidden;border-radius:40px;margin-top:-25px}#twe-root .mockup-browser .mockup-browser-toolbar .input{position:relative;margin-left:auto;margin-right:auto;display:block;height:28px;width:384px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;--tw-bg-opacity: 1;background-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-bg-opacity)));padding-left:32px;direction:ltr}#twe-root .mockup-browser .mockup-browser-toolbar .input:before{content:"";position:absolute;left:8px;top:50%;aspect-ratio:1 / 1;height:12px;--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));border-radius:9999px;border-width:2px;border-color:currentColor;opacity:.6}#twe-root .mockup-browser .mockup-browser-toolbar .input:after{content:"";position:absolute;left:20px;top:50%;height:8px;--tw-translate-y: 25%;--tw-rotate: -45deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));border-radius:9999px;border-width:1px;border-color:currentColor;opacity:.6}#twe-root .modal:not(dialog:not(.modal-open)),#twe-root .modal::backdrop{background-color:#0006;animation:modal-pop .2s ease-out}#twe-root .modal-backdrop{z-index:-1;grid-column-start:1;grid-row-start:1;display:grid;align-self:stretch;justify-self:stretch;color:transparent}#twe-root .modal-open .modal-box,#twe-root .modal-toggle:checked+.modal .modal-box,#twe-root .modal:target .modal-box,#twe-root .modal[open] .modal-box{--tw-translate-y: 0px;--tw-scale-x: 1;--tw-scale-y: 1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes modal-pop{0%{opacity:0}}#twe-root .progress::-moz-progress-bar{border-radius:var(--rounded-box, 16px);background-color:currentColor}#twe-root .progress-primary::-moz-progress-bar{border-radius:var(--rounded-box, 16px);--tw-bg-opacity: 1;background-color:var(--fallback-p,oklch(var(--p)/var(--tw-bg-opacity)))}#twe-root .progress-secondary::-moz-progress-bar{border-radius:var(--rounded-box, 16px);--tw-bg-opacity: 1;background-color:var(--fallback-s,oklch(var(--s)/var(--tw-bg-opacity)))}#twe-root .progress:indeterminate{--progress-color: var(--fallback-bc,oklch(var(--bc)/1));background-image:repeating-linear-gradient(90deg,var(--progress-color) -1%,var(--progress-color) 10%,transparent 10%,transparent 90%);background-size:200%;background-position-x:15%;animation:progress-loading 5s ease-in-out infinite}#twe-root .progress-primary:indeterminate{--progress-color: var(--fallback-p,oklch(var(--p)/1))}#twe-root .progress-secondary:indeterminate{--progress-color: var(--fallback-s,oklch(var(--s)/1))}#twe-root .progress::-webkit-progress-bar{border-radius:var(--rounded-box, 16px);background-color:transparent}#twe-root .progress::-webkit-progress-value{border-radius:var(--rounded-box, 16px);background-color:currentColor}#twe-root .progress-primary::-webkit-progress-value{--tw-bg-opacity: 1;background-color:var(--fallback-p,oklch(var(--p)/var(--tw-bg-opacity)))}#twe-root .progress-secondary::-webkit-progress-value{--tw-bg-opacity: 1;background-color:var(--fallback-s,oklch(var(--s)/var(--tw-bg-opacity)))}#twe-root .progress:indeterminate::-moz-progress-bar{background-color:transparent;background-image:repeating-linear-gradient(90deg,var(--progress-color) -1%,var(--progress-color) 10%,transparent 10%,transparent 90%);background-size:200%;background-position-x:15%;animation:progress-loading 5s ease-in-out infinite}@keyframes progress-loading{50%{background-position-x:-115%}}#twe-root .radio:focus{box-shadow:none}#twe-root .radio:focus-visible{outline-style:solid;outline-width:2px;outline-offset:2px;outline-color:var(--fallback-bc,oklch(var(--bc)/1))}#twe-root .radio:checked,#twe-root .radio[aria-checked=true]{--tw-bg-opacity: 1;background-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-bg-opacity)));background-image:none;animation:radiomark var(--animation-input, .2s) ease-out;box-shadow:0 0 0 4px var(--fallback-b1,oklch(var(--b1)/1)) inset,0 0 0 4px var(--fallback-b1,oklch(var(--b1)/1)) inset}#twe-root .radio:disabled{cursor:not-allowed;opacity:.2}@keyframes radiomark{0%{box-shadow:0 0 0 12px var(--fallback-b1,oklch(var(--b1)/1)) inset,0 0 0 12px var(--fallback-b1,oklch(var(--b1)/1)) inset}50%{box-shadow:0 0 0 3px var(--fallback-b1,oklch(var(--b1)/1)) inset,0 0 0 3px var(--fallback-b1,oklch(var(--b1)/1)) inset}to{box-shadow:0 0 0 4px var(--fallback-b1,oklch(var(--b1)/1)) inset,0 0 0 4px var(--fallback-b1,oklch(var(--b1)/1)) inset}}#twe-root .range:focus-visible::-webkit-slider-thumb{--focus-shadow: 0 0 0 6px var(--fallback-b1,oklch(var(--b1)/1)) inset, 0 0 0 32px var(--range-shdw) inset}#twe-root .range:focus-visible::-moz-range-thumb{--focus-shadow: 0 0 0 6px var(--fallback-b1,oklch(var(--b1)/1)) inset, 0 0 0 32px var(--range-shdw) inset}#twe-root .range::-webkit-slider-runnable-track{height:8px;width:100%;border-radius:var(--rounded-box, 16px);background-color:var(--fallback-bc,oklch(var(--bc)/.1))}#twe-root .range::-moz-range-track{height:8px;width:100%;border-radius:var(--rounded-box, 16px);background-color:var(--fallback-bc,oklch(var(--bc)/.1))}#twe-root .range::-webkit-slider-thumb{position:relative;height:24px;width:24px;border-radius:var(--rounded-box, 16px);border-style:none;--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)));-moz-appearance:none;appearance:none;-webkit-appearance:none;top:50%;color:var(--range-shdw);transform:translateY(-50%);--filler-size: 1600px;--filler-offset: 9.6px;box-shadow:0 0 0 3px var(--range-shdw) inset,var(--focus-shadow, 0 0),calc(var(--filler-size) * -1 - var(--filler-offset)) 0 0 var(--filler-size)}#twe-root .range::-moz-range-thumb{position:relative;height:24px;width:24px;border-radius:var(--rounded-box, 16px);border-style:none;--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity)));top:50%;color:var(--range-shdw);--filler-size: 1600px;--filler-offset: 8px;box-shadow:0 0 0 3px var(--range-shdw) inset,var(--focus-shadow, 0 0),calc(var(--filler-size) * -1 - var(--filler-offset)) 0 0 var(--filler-size)}@keyframes rating-pop{0%{transform:translateY(-.125em)}40%{transform:translateY(-.125em)}to{transform:translateY(0)}}#twe-root .select-bordered{border-color:var(--fallback-bc,oklch(var(--bc)/.2))}#twe-root .select:focus{box-shadow:none;border-color:var(--fallback-bc,oklch(var(--bc)/.2));outline-style:solid;outline-width:2px;outline-offset:2px;outline-color:var(--fallback-bc,oklch(var(--bc)/.2))}#twe-root .select-disabled,#twe-root .select:disabled,#twe-root .select[disabled]{cursor:not-allowed;--tw-border-opacity: 1;border-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-border-opacity)));--tw-bg-opacity: 1;background-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-bg-opacity)));color:var(--fallback-bc,oklch(var(--bc)/.4))}#twe-root .select-disabled::-moz-placeholder,#twe-root .select:disabled::-moz-placeholder,#twe-root .select[disabled]::-moz-placeholder{color:var(--fallback-bc,oklch(var(--bc)/var(--tw-placeholder-opacity)));--tw-placeholder-opacity: .2}#twe-root .select-disabled::placeholder,#twe-root .select:disabled::placeholder,#twe-root .select[disabled]::placeholder{color:var(--fallback-bc,oklch(var(--bc)/var(--tw-placeholder-opacity)));--tw-placeholder-opacity: .2}#twe-root .select-multiple,#twe-root .select[multiple],#twe-root .select[size].select:not([size="1"]){background-image:none;padding-right:16px}#twe-root [dir=rtl] .select{background-position:calc(0% + 12px) calc(1px + 50%),calc(0% + 16px) calc(1px + 50%)}@keyframes skeleton{0%{background-position:150%}to{background-position:-50%}}#twe-root :where(.stats)>:not([hidden])~:not([hidden]){--tw-divide-x-reverse: 0;border-right-width:calc(1px * var(--tw-divide-x-reverse));border-left-width:calc(1px * calc(1 - var(--tw-divide-x-reverse)));--tw-divide-y-reverse: 0;border-top-width:calc(0px * calc(1 - var(--tw-divide-y-reverse)));border-bottom-width:calc(0px * var(--tw-divide-y-reverse))}#twe-root [dir=rtl] .stats>*:not([hidden])~*:not([hidden]){--tw-divide-x-reverse: 1}#twe-root .tabs-lifted>.tab:focus-visible{border-end-end-radius:0;border-end-start-radius:0}#twe-root .tab:is(.tab-active,[aria-selected=true]):not(.tab-disabled):not([disabled]),#twe-root .tab:is(input:checked){border-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-border-opacity)));--tw-border-opacity: 1;--tw-text-opacity: 1}#twe-root .tab:focus{outline:2px solid transparent;outline-offset:2px}#twe-root .tab:focus-visible{outline:2px solid currentColor;outline-offset:-5px}#twe-root .tab-disabled,#twe-root .tab[disabled]{cursor:not-allowed;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)));--tw-text-opacity: .2}#twe-root .tabs-bordered>.tab{border-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-border-opacity)));--tw-border-opacity: .2;border-style:solid;border-bottom-width:calc(var(--tab-border, 1px) + 1px)}#twe-root .tabs-lifted>.tab{border:var(--tab-border, 1px) solid transparent;border-width:0 0 var(--tab-border, 1px) 0;border-start-start-radius:var(--tab-radius, 8px);border-start-end-radius:var(--tab-radius, 8px);border-bottom-color:var(--tab-border-color);padding-inline-start:var(--tab-padding, 16px);padding-inline-end:var(--tab-padding, 16px);padding-top:var(--tab-border, 1px)}#twe-root .tabs-lifted>.tab:is(.tab-active,[aria-selected=true]):not(.tab-disabled):not([disabled]),#twe-root .tabs-lifted>.tab:is(input:checked){background-color:var(--tab-bg);border-width:var(--tab-border, 1px) var(--tab-border, 1px) 0 var(--tab-border, 1px);border-inline-start-color:var(--tab-border-color);border-inline-end-color:var(--tab-border-color);border-top-color:var(--tab-border-color);padding-inline-start:calc(var(--tab-padding, 16px) - var(--tab-border, 1px));padding-inline-end:calc(var(--tab-padding, 16px) - var(--tab-border, 1px));padding-bottom:var(--tab-border, 1px);padding-top:0}#twe-root .tabs-lifted>.tab:is(.tab-active,[aria-selected=true]):not(.tab-disabled):not([disabled]):before,#twe-root .tabs-lifted>.tab:is(input:checked):before{z-index:1;content:"";display:block;position:absolute;width:calc(100% + var(--tab-radius, 8px) * 2);height:var(--tab-radius, 8px);bottom:0;background-size:var(--tab-radius, 8px);background-position:top left,top right;background-repeat:no-repeat;--tab-grad: calc(69% - var(--tab-border, 1px));--radius-start: radial-gradient( circle at top left, transparent var(--tab-grad), var(--tab-border-color) calc(var(--tab-grad) + .25px), var(--tab-border-color) calc(var(--tab-grad) + var(--tab-border, 1px)), var(--tab-bg) calc(var(--tab-grad) + var(--tab-border, 1px) + .25px) );--radius-end: radial-gradient( circle at top right, transparent var(--tab-grad), var(--tab-border-color) calc(var(--tab-grad) + .25px), var(--tab-border-color) calc(var(--tab-grad) + var(--tab-border, 1px)), var(--tab-bg) calc(var(--tab-grad) + var(--tab-border, 1px) + .25px) );background-image:var(--radius-start),var(--radius-end)}#twe-root .tabs-lifted>.tab:is(.tab-active,[aria-selected=true]):not(.tab-disabled):not([disabled]):first-child:before,#twe-root .tabs-lifted>.tab:is(input:checked):first-child:before{background-image:var(--radius-end);background-position:top right}#twe-root [dir=rtl] .tabs-lifted>.tab:is(.tab-active,[aria-selected=true]):not(.tab-disabled):not([disabled]):first-child:before,#twe-root [dir=rtl] .tabs-lifted>.tab:is(input:checked):first-child:before{background-image:var(--radius-start);background-position:top left}#twe-root .tabs-lifted>.tab:is(.tab-active,[aria-selected=true]):not(.tab-disabled):not([disabled]):last-child:before,#twe-root .tabs-lifted>.tab:is(input:checked):last-child:before{background-image:var(--radius-start);background-position:top left}#twe-root [dir=rtl] .tabs-lifted>.tab:is(.tab-active,[aria-selected=true]):not(.tab-disabled):not([disabled]):last-child:before,#twe-root [dir=rtl] .tabs-lifted>.tab:is(input:checked):last-child:before{background-image:var(--radius-end);background-position:top right}#twe-root .tabs-lifted>:is(.tab-active,[aria-selected=true]):not(.tab-disabled):not([disabled])+.tabs-lifted :is(.tab-active,[aria-selected=true]):not(.tab-disabled):not([disabled]):before,#twe-root .tabs-lifted>.tab:is(input:checked)+.tabs-lifted .tab:is(input:checked):before{background-image:var(--radius-end);background-position:top right}#twe-root .tabs-boxed .tab{border-radius:var(--rounded-btn, 8px)}#twe-root .\\!table:where([dir=rtl],[dir=rtl] *){text-align:right!important}#twe-root .table:where([dir=rtl],[dir=rtl] *){text-align:right}#twe-root .\\!table :where(th,td){padding:12px 16px!important;vertical-align:middle!important}#twe-root .table :where(th,td){padding:12px 16px;vertical-align:middle}#twe-root .table tr.active,#twe-root .table tr.active:nth-child(2n),#twe-root .table-zebra tbody tr:nth-child(2n){--tw-bg-opacity: 1;background-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-bg-opacity)))}#twe-root .\\!table tr.active,#twe-root .\\!table tr.active:nth-child(2n){--tw-bg-opacity: 1 !important;background-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-bg-opacity)))!important}#twe-root .table-zebra tr.active,#twe-root .table-zebra tr.active:nth-child(2n),#twe-root .table-zebra-zebra tbody tr:nth-child(2n){--tw-bg-opacity: 1;background-color:var(--fallback-b3,oklch(var(--b3)/var(--tw-bg-opacity)))}#twe-root .\\!table :where(thead tr,tbody tr:not(:last-child),tbody tr:first-child:last-child){border-bottom-width:1px!important;--tw-border-opacity: 1 !important;border-bottom-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-border-opacity)))!important}#twe-root .table :where(thead tr,tbody tr:not(:last-child),tbody tr:first-child:last-child){border-bottom-width:1px;--tw-border-opacity: 1;border-bottom-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-border-opacity)))}#twe-root .\\!table :where(thead,tfoot){white-space:nowrap!important;font-size:12px!important;line-height:16px!important;font-weight:700!important;color:var(--fallback-bc,oklch(var(--bc)/.6))!important}#twe-root .table :where(thead,tfoot){white-space:nowrap;font-size:12px;line-height:16px;font-weight:700;color:var(--fallback-bc,oklch(var(--bc)/.6))}#twe-root .\\!table :where(tfoot){border-top-width:1px!important;--tw-border-opacity: 1 !important;border-top-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-border-opacity)))!important}#twe-root .table :where(tfoot){border-top-width:1px;--tw-border-opacity: 1;border-top-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-border-opacity)))}#twe-root .textarea-bordered{border-color:var(--fallback-bc,oklch(var(--bc)/.2))}#twe-root .textarea:focus{box-shadow:none;border-color:var(--fallback-bc,oklch(var(--bc)/.2));outline-style:solid;outline-width:2px;outline-offset:2px;outline-color:var(--fallback-bc,oklch(var(--bc)/.2))}#twe-root .textarea-disabled,#twe-root .textarea:disabled,#twe-root .textarea[disabled]{cursor:not-allowed;--tw-border-opacity: 1;border-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-border-opacity)));--tw-bg-opacity: 1;background-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-bg-opacity)));color:var(--fallback-bc,oklch(var(--bc)/.4))}#twe-root .textarea-disabled::-moz-placeholder,#twe-root .textarea:disabled::-moz-placeholder,#twe-root .textarea[disabled]::-moz-placeholder{color:var(--fallback-bc,oklch(var(--bc)/var(--tw-placeholder-opacity)));--tw-placeholder-opacity: .2}#twe-root .textarea-disabled::placeholder,#twe-root .textarea:disabled::placeholder,#twe-root .textarea[disabled]::placeholder{color:var(--fallback-bc,oklch(var(--bc)/var(--tw-placeholder-opacity)));--tw-placeholder-opacity: .2}#twe-root .\\!timeline hr{height:4px!important}#twe-root .timeline hr{height:4px}#twe-root :where(.\\!timeline hr){--tw-bg-opacity: 1 !important;background-color:var(--fallback-b3,oklch(var(--b3)/var(--tw-bg-opacity)))!important}#twe-root :where(.timeline hr){--tw-bg-opacity: 1;background-color:var(--fallback-b3,oklch(var(--b3)/var(--tw-bg-opacity)))}#twe-root :where(.\\!timeline:has(.timeline-middle) hr):first-child{border-start-end-radius:var(--rounded-badge, 30.4px)!important;border-end-end-radius:var(--rounded-badge, 30.4px)!important;border-start-start-radius:0px!important;border-end-start-radius:0px!important}#twe-root :where(.timeline:has(.timeline-middle) hr):first-child{border-start-end-radius:var(--rounded-badge, 30.4px);border-end-end-radius:var(--rounded-badge, 30.4px);border-start-start-radius:0px;border-end-start-radius:0px}#twe-root :where(.\\!timeline:has(.timeline-middle) hr):last-child{border-start-start-radius:var(--rounded-badge, 30.4px)!important;border-end-start-radius:var(--rounded-badge, 30.4px)!important;border-start-end-radius:0px!important;border-end-end-radius:0px!important}#twe-root :where(.timeline:has(.timeline-middle) hr):last-child{border-start-start-radius:var(--rounded-badge, 30.4px);border-end-start-radius:var(--rounded-badge, 30.4px);border-start-end-radius:0px;border-end-end-radius:0px}#twe-root :where(.\\!timeline:not(:has(.timeline-middle)) :first-child hr:last-child){border-start-start-radius:var(--rounded-badge, 30.4px)!important;border-end-start-radius:var(--rounded-badge, 30.4px)!important;border-start-end-radius:0px!important;border-end-end-radius:0px!important}#twe-root :where(.timeline:not(:has(.timeline-middle)) :first-child hr:last-child){border-start-start-radius:var(--rounded-badge, 30.4px);border-end-start-radius:var(--rounded-badge, 30.4px);border-start-end-radius:0px;border-end-end-radius:0px}#twe-root :where(.\\!timeline:not(:has(.timeline-middle)) :last-child hr:first-child){border-start-end-radius:var(--rounded-badge, 30.4px)!important;border-end-end-radius:var(--rounded-badge, 30.4px)!important;border-start-start-radius:0px!important;border-end-start-radius:0px!important}#twe-root :where(.timeline:not(:has(.timeline-middle)) :last-child hr:first-child){border-start-end-radius:var(--rounded-badge, 30.4px);border-end-end-radius:var(--rounded-badge, 30.4px);border-start-start-radius:0px;border-end-start-radius:0px}@keyframes toast-pop{0%{transform:scale(.9);opacity:0}to{transform:scale(1);opacity:1}}#twe-root [dir=rtl] .toggle{--handleoffsetcalculator: calc(var(--handleoffset) * 1)}#twe-root .toggle:focus-visible{outline-style:solid;outline-width:2px;outline-offset:2px;outline-color:var(--fallback-bc,oklch(var(--bc)/.2))}#twe-root .toggle:hover{background-color:currentColor}#twe-root .toggle:checked,#twe-root .toggle[aria-checked=true]{background-image:none;--handleoffsetcalculator: var(--handleoffset);--tw-text-opacity: 1;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)))}#twe-root [dir=rtl] .toggle:checked,#twe-root [dir=rtl] .toggle[aria-checked=true]{--handleoffsetcalculator: calc(var(--handleoffset) * -1)}#twe-root .toggle:indeterminate{--tw-text-opacity: 1;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity)));box-shadow:calc(var(--handleoffset) / 2) 0 0 2px var(--tglbg) inset,calc(var(--handleoffset) / -2) 0 0 2px var(--tglbg) inset,0 0 0 2px var(--tglbg) inset}#twe-root [dir=rtl] .toggle:indeterminate{box-shadow:calc(var(--handleoffset) / 2) 0 0 2px var(--tglbg) inset,calc(var(--handleoffset) / -2) 0 0 2px var(--tglbg) inset,0 0 0 2px var(--tglbg) inset}#twe-root .toggle-primary:focus-visible{outline-color:var(--fallback-p,oklch(var(--p)/1))}#twe-root .toggle-primary:checked,#twe-root .toggle-primary[aria-checked=true]{border-color:var(--fallback-p,oklch(var(--p)/var(--tw-border-opacity)));--tw-border-opacity: .1;--tw-bg-opacity: 1;background-color:var(--fallback-p,oklch(var(--p)/var(--tw-bg-opacity)));--tw-text-opacity: 1;color:var(--fallback-pc,oklch(var(--pc)/var(--tw-text-opacity)))}#twe-root .toggle-secondary:focus-visible{outline-color:var(--fallback-s,oklch(var(--s)/1))}#twe-root .toggle-secondary:checked,#twe-root .toggle-secondary[aria-checked=true]{border-color:var(--fallback-s,oklch(var(--s)/var(--tw-border-opacity)));--tw-border-opacity: .1;--tw-bg-opacity: 1;background-color:var(--fallback-s,oklch(var(--s)/var(--tw-bg-opacity)));--tw-text-opacity: 1;color:var(--fallback-sc,oklch(var(--sc)/var(--tw-text-opacity)))}#twe-root .toggle-warning:focus-visible{outline-color:var(--fallback-wa,oklch(var(--wa)/1))}#twe-root .toggle-warning:checked,#twe-root .toggle-warning[aria-checked=true]{border-color:var(--fallback-wa,oklch(var(--wa)/var(--tw-border-opacity)));--tw-border-opacity: .1;--tw-bg-opacity: 1;background-color:var(--fallback-wa,oklch(var(--wa)/var(--tw-bg-opacity)));--tw-text-opacity: 1;color:var(--fallback-wac,oklch(var(--wac)/var(--tw-text-opacity)))}#twe-root .toggle:disabled{cursor:not-allowed;--tw-border-opacity: 1;border-color:var(--fallback-bc,oklch(var(--bc)/var(--tw-border-opacity)));background-color:transparent;opacity:.3;--togglehandleborder: 0 0 0 3px var(--fallback-bc,oklch(var(--bc)/1)) inset, var(--handleoffsetcalculator) 0 0 3px var(--fallback-bc,oklch(var(--bc)/1)) inset}#twe-root .badge-xs{height:12px;font-size:12px;line-height:12px;padding-left:5.008px;padding-right:5.008px}#twe-root .badge-sm{height:16px;font-size:12px;line-height:16px;padding-left:7.008px;padding-right:7.008px}#twe-root .btm-nav-xs>*:where(.active){border-top-width:1px}#twe-root .btm-nav-sm>*:where(.active){border-top-width:2px}#twe-root .btm-nav-md>*:where(.active){border-top-width:2px}#twe-root .btm-nav-lg>*:where(.active){border-top-width:4px}#twe-root .btn-xs{height:24px;min-height:24px;padding-left:8px;padding-right:8px;font-size:12px}#twe-root .btn-sm{height:32px;min-height:32px;padding-left:12px;padding-right:12px;font-size:14px}#twe-root .btn-square:where(.btn-xs){height:24px;width:24px;padding:0}#twe-root .btn-square:where(.btn-sm){height:32px;width:32px;padding:0}#twe-root .btn-circle:where(.btn-xs){height:24px;width:24px;border-radius:9999px;padding:0}#twe-root .btn-circle:where(.btn-sm){height:32px;width:32px;border-radius:9999px;padding:0}#twe-root [type=checkbox].checkbox-xs{height:16px;width:16px}#twe-root [type=checkbox].checkbox-sm{height:20px;width:20px}#twe-root .file-input-sm{height:32px;padding-inline-end:12px;font-size:14px;line-height:20px;line-height:2}#twe-root .file-input-sm::file-selector-button{margin-right:12px;font-size:14px}#twe-root .input-xs{height:24px;padding-left:8px;padding-right:8px;font-size:12px;line-height:16px;line-height:1.625}#twe-root .input-sm{height:32px;padding-left:12px;padding-right:12px;font-size:14px;line-height:32px}#twe-root .join.join-vertical{flex-direction:column}#twe-root .join.join-vertical .join-item:first-child:not(:last-child),#twe-root .join.join-vertical *:first-child:not(:last-child) .join-item{border-end-start-radius:0;border-end-end-radius:0;border-start-start-radius:inherit;border-start-end-radius:inherit}#twe-root .join.join-vertical .join-item:last-child:not(:first-child),#twe-root .join.join-vertical *:last-child:not(:first-child) .join-item{border-start-start-radius:0;border-start-end-radius:0;border-end-start-radius:inherit;border-end-end-radius:inherit}#twe-root .join.join-horizontal{flex-direction:row}#twe-root .join.join-horizontal .join-item:first-child:not(:last-child),#twe-root .join.join-horizontal *:first-child:not(:last-child) .join-item{border-end-end-radius:0;border-start-end-radius:0;border-end-start-radius:inherit;border-start-start-radius:inherit}#twe-root .join.join-horizontal .join-item:last-child:not(:first-child),#twe-root .join.join-horizontal *:last-child:not(:first-child) .join-item{border-end-start-radius:0;border-start-start-radius:0;border-end-end-radius:inherit;border-start-end-radius:inherit}#twe-root [type=radio].radio-sm{height:20px;width:20px}#twe-root .select-sm{height:32px;min-height:32px;padding-left:12px;padding-right:32px;font-size:14px;line-height:32px}#twe-root [dir=rtl] .select-sm{padding-left:32px;padding-right:12px}#twe-root .select-xs{height:24px;min-height:24px;padding-left:8px;padding-right:32px;font-size:12px;line-height:16px;line-height:1.625}#twe-root [dir=rtl] .select-xs{padding-left:32px;padding-right:8px}#twe-root .tabs-md :where(.tab){height:32px;font-size:14px;line-height:20px;line-height:2;--tab-padding: 16px}#twe-root .tabs-lg :where(.tab){height:48px;font-size:18px;line-height:28px;line-height:2;--tab-padding: 20px}#twe-root .tabs-sm :where(.tab){height:24px;font-size:14px;line-height:12px;--tab-padding: 12px}#twe-root .tabs-xs :where(.tab){height:20px;font-size:12px;line-height:12px;--tab-padding: 8px}#twe-root [type=checkbox].toggle-xs{--handleoffset: 8px;height:16px;width:24px}#twe-root [type=checkbox].toggle-sm{--handleoffset: 12px;height:20px;width:32px}#twe-root .tooltip{position:relative;display:inline-block;--tooltip-offset: calc(100% + 1px + var(--tooltip-tail, 0px))}#twe-root .tooltip:before{position:absolute;pointer-events:none;z-index:1;content:var(--tw-content);--tw-content: attr(data-tip)}#twe-root .tooltip:before,#twe-root .tooltip-top:before{transform:translate(-50%);top:auto;left:50%;right:auto;bottom:var(--tooltip-offset)}#twe-root .tooltip-bottom:before{transform:translate(-50%);top:var(--tooltip-offset);left:50%;right:auto;bottom:auto}#twe-root .avatar.online:before{content:"";position:absolute;z-index:10;display:block;border-radius:9999px;--tw-bg-opacity: 1;background-color:var(--fallback-su,oklch(var(--su)/var(--tw-bg-opacity)));outline-style:solid;outline-width:2px;outline-color:var(--fallback-b1,oklch(var(--b1)/1));width:15%;height:15%;top:7%;right:7%}#twe-root .avatar.offline:before{content:"";position:absolute;z-index:10;display:block;border-radius:9999px;--tw-bg-opacity: 1;background-color:var(--fallback-b3,oklch(var(--b3)/var(--tw-bg-opacity)));outline-style:solid;outline-width:2px;outline-color:var(--fallback-b1,oklch(var(--b1)/1));width:15%;height:15%;top:7%;right:7%}#twe-root .card-compact .card-body{padding:16px;font-size:14px;line-height:20px}#twe-root .card-compact .card-title{margin-bottom:4px}#twe-root .join.join-vertical>:where(*:not(:first-child)){margin-left:0;margin-right:0;margin-top:-1px}#twe-root .join.join-vertical>:where(*:not(:first-child)):is(.btn){margin-top:calc(var(--border-btn) * -1)}#twe-root .join.join-horizontal>:where(*:not(:first-child)){margin-top:0;margin-bottom:0;margin-inline-start:-1px}#twe-root .join.join-horizontal>:where(*:not(:first-child)):is(.btn){margin-inline-start:calc(var(--border-btn) * -1);margin-top:0}#twe-root .menu-sm :where(li:not(.menu-title)>*:not(ul,details,.menu-title)),#twe-root .menu-sm :where(li:not(.menu-title)>details>summary:not(.menu-title)){border-radius:var(--rounded-btn, 8px);padding:4px 12px;font-size:14px;line-height:20px}#twe-root .menu-sm .menu-title{padding:8px 12px}#twe-root .modal-top :where(.modal-box){width:100%;max-width:none;--tw-translate-y: -40px;--tw-scale-x: 1;--tw-scale-y: 1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));border-bottom-right-radius:var(--rounded-box, 16px);border-bottom-left-radius:var(--rounded-box, 16px);border-top-left-radius:0;border-top-right-radius:0}#twe-root .modal-middle :where(.modal-box){width:91.666667%;max-width:512px;--tw-translate-y: 0px;--tw-scale-x: .9;--tw-scale-y: .9;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));border-top-left-radius:var(--rounded-box, 16px);border-top-right-radius:var(--rounded-box, 16px);border-bottom-right-radius:var(--rounded-box, 16px);border-bottom-left-radius:var(--rounded-box, 16px)}#twe-root .modal-bottom :where(.modal-box){width:100%;max-width:none;--tw-translate-y: 40px;--tw-scale-x: 1;--tw-scale-y: 1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));border-top-left-radius:var(--rounded-box, 16px);border-top-right-radius:var(--rounded-box, 16px);border-bottom-right-radius:0;border-bottom-left-radius:0}#twe-root .table-xs :not(thead):not(tfoot) tr{font-size:12px;line-height:16px}#twe-root .table-xs :where(th,td){padding:4px 8px}#twe-root .table-sm :not(thead):not(tfoot) tr{font-size:14px;line-height:20px}#twe-root .table-sm :where(th,td){padding:8px 12px}#twe-root .tooltip{position:relative;display:inline-block;text-align:center;--tooltip-tail: 3px;--tooltip-color: var(--fallback-n,oklch(var(--n)/1));--tooltip-text-color: var(--fallback-nc,oklch(var(--nc)/1));--tooltip-tail-offset: calc(100% + 1px - var(--tooltip-tail))}#twe-root .tooltip:before,#twe-root .tooltip:after{opacity:0;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-delay:.1s;transition-duration:.2s;transition-timing-function:cubic-bezier(.4,0,.2,1)}#twe-root .tooltip:after{position:absolute;content:"";border-style:solid;border-width:var(--tooltip-tail, 0);width:0;height:0;display:block}#twe-root .tooltip:before{max-width:320px;white-space:normal;border-radius:4px;padding:4px 8px;font-size:14px;line-height:20px;background-color:var(--tooltip-color);color:var(--tooltip-text-color);width:-moz-max-content;width:max-content}#twe-root .tooltip.tooltip-open:before{opacity:1;transition-delay:75ms}#twe-root .tooltip.tooltip-open:after{opacity:1;transition-delay:75ms}#twe-root .tooltip:hover:before{opacity:1;transition-delay:75ms}#twe-root .tooltip:hover:after{opacity:1;transition-delay:75ms}#twe-root .tooltip:has(:focus-visible):after,#twe-root .tooltip:has(:focus-visible):before{opacity:1;transition-delay:75ms}#twe-root .tooltip:not([data-tip]):hover:before,#twe-root .tooltip:not([data-tip]):hover:after{visibility:hidden;opacity:0}#twe-root .tooltip:after,#twe-root .tooltip-top:after{transform:translate(-50%);border-color:var(--tooltip-color) transparent transparent transparent;top:auto;left:50%;right:auto;bottom:var(--tooltip-tail-offset)}#twe-root .tooltip-bottom:after{transform:translate(-50%);border-color:transparent transparent var(--tooltip-color) transparent;top:var(--tooltip-tail-offset);left:50%;right:auto;bottom:auto}#twe-root .pointer-events-none{pointer-events:none}#twe-root .visible{visibility:visible}#twe-root .static{position:static}#twe-root .fixed{position:fixed}#twe-root .absolute{position:absolute}#twe-root .relative{position:relative}#twe-root .sticky{position:sticky}#twe-root .inset-x-0{left:0;right:0}#twe-root .bottom-0{bottom:0}#twe-root .bottom-0\\.5{bottom:2px}#twe-root .bottom-14{bottom:56px}#twe-root .left-0\\.5{left:2px}#twe-root .left-8{left:32px}#twe-root .left-\\[-20px\\]{left:-20px}#twe-root .right-2{right:8px}#twe-root .right-3{right:12px}#twe-root .top-0{top:0}#twe-root .top-3{top:12px}#twe-root .top-8{top:32px}#twe-root .top-\\[60\\%\\]{top:60%}#twe-root .z-10{z-index:10}#twe-root .z-20{z-index:20}#twe-root .z-\\[2\\]{z-index:2}#twe-root .z-\\[6000\\]{z-index:6000}#twe-root .col-span-1{grid-column:span 1 / span 1}#twe-root .col-span-2{grid-column:span 2 / span 2}#twe-root .col-span-3{grid-column:span 3 / span 3}#twe-root .m-0{margin:0}#twe-root .mx-4{margin-left:16px;margin-right:16px}#twe-root .my-1{margin-top:4px;margin-bottom:4px}#twe-root .my-3{margin-top:12px;margin-bottom:12px}#twe-root .my-\\[2px\\]{margin-top:2px;margin-bottom:2px}#twe-root .-ml-2{margin-left:-8px}#twe-root .mb-0{margin-bottom:0}#twe-root .mb-0\\.5{margin-bottom:2px}#twe-root .mb-1{margin-bottom:4px}#twe-root .mb-1\\.5{margin-bottom:6px}#twe-root .mb-2{margin-bottom:8px}#twe-root .mb-3{margin-bottom:12px}#twe-root .mb-4{margin-bottom:16px}#twe-root .ml-0\\.5{margin-left:2px}#twe-root .ml-1{margin-left:4px}#twe-root .ml-2{margin-left:8px}#twe-root .ml-4{margin-left:16px}#twe-root .ml-auto{margin-left:auto}#twe-root .mr-1{margin-right:4px}#twe-root .mr-2{margin-right:8px}#twe-root .mr-3{margin-right:12px}#twe-root .mt-0{margin-top:0}#twe-root .mt-0\\.5{margin-top:2px}#twe-root .mt-1{margin-top:4px}#twe-root .mt-1\\.5{margin-top:6px}#twe-root .mt-2{margin-top:8px}#twe-root .mt-3{margin-top:12px}#twe-root .mt-6{margin-top:24px}#twe-root .line-clamp-3{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3}#twe-root .line-clamp-4{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:4}#twe-root .block{display:block}#twe-root .inline-block{display:inline-block}#twe-root .inline{display:inline}#twe-root .flex{display:flex}#twe-root .inline-flex{display:inline-flex}#twe-root .\\!table{display:table!important}#twe-root .table{display:table}#twe-root .grid{display:grid}#twe-root .contents{display:contents}#twe-root .hidden{display:none}#twe-root .h-11{height:44px}#twe-root .h-12{height:48px}#twe-root .h-20{height:80px}#twe-root .h-28{height:112px}#twe-root .h-36{height:144px}#twe-root .h-4{height:16px}#twe-root .h-5{height:20px}#twe-root .h-6{height:24px}#twe-root .h-8{height:32px}#twe-root .h-9{height:36px}#twe-root .h-\\[320px\\]{height:320px}#twe-root .h-\\[82vh\\]{height:82vh}#twe-root .h-\\[min\\(88vh\\,860px\\)\\]{height:min(88vh,860px)}#twe-root .h-\\[min\\(92vh\\,980px\\)\\]{height:min(92vh,980px)}#twe-root .h-auto{height:auto}#twe-root .h-full{height:100%}#twe-root .h-screen{height:100vh}#twe-root .max-h-44{max-height:176px}#twe-root .max-h-48{max-height:192px}#twe-root .max-h-52{max-height:208px}#twe-root .max-h-56{max-height:224px}#twe-root .max-h-72{max-height:288px}#twe-root .max-h-80{max-height:320px}#twe-root .max-h-\\[460px\\]{max-height:460px}#twe-root .max-h-\\[500px\\]{max-height:500px}#twe-root .max-h-\\[88vh\\]{max-height:88vh}#twe-root .max-h-\\[92vh\\]{max-height:92vh}#twe-root .max-h-\\[calc\\(100vh-4rem\\)\\]{max-height:calc(100vh - 64px)}#twe-root .max-h-full{max-height:100%}#twe-root .max-h-screen{max-height:100vh}#twe-root .min-h-0{min-height:0px}#twe-root .min-h-16{min-height:64px}#twe-root .min-h-6{min-height:24px}#twe-root .min-h-9{min-height:36px}#twe-root .min-h-\\[512px\\]{min-height:512px}#twe-root .min-h-\\[560px\\]{min-height:560px}#twe-root .w-12{width:48px}#twe-root .w-20{width:80px}#twe-root .w-24{width:96px}#twe-root .w-28{width:112px}#twe-root .w-32{width:128px}#twe-root .w-36{width:144px}#twe-root .w-4{width:16px}#twe-root .w-40{width:160px}#twe-root .w-44{width:176px}#twe-root .w-48{width:192px}#twe-root .w-52{width:208px}#twe-root .w-56{width:224px}#twe-root .w-60{width:240px}#twe-root .w-8{width:32px}#twe-root .w-80{width:320px}#twe-root .w-9{width:36px}#twe-root .w-\\[min\\(92vw\\,1040px\\)\\]{width:min(92vw,1040px)}#twe-root .w-\\[min\\(96vw\\,1480px\\)\\]{width:min(96vw,1480px)}#twe-root .w-auto{width:auto}#twe-root .w-full{width:100%}#twe-root .w-max{width:-moz-max-content;width:max-content}#twe-root .w-screen{width:100vw}#twe-root .min-w-0{min-width:0px}#twe-root .min-w-44{min-width:176px}#twe-root .min-w-56{min-width:224px}#twe-root .max-w-2xl{max-width:672px}#twe-root .max-w-3xl{max-width:768px}#twe-root .max-w-4xl{max-width:896px}#twe-root .max-w-\\[50\\%\\]{max-width:50%}#twe-root .max-w-\\[92vw\\]{max-width:92vw}#twe-root .max-w-\\[96vw\\]{max-width:96vw}#twe-root .max-w-\\[calc\\(100\\%-46px\\)\\]{max-width:calc(100% - 46px)}#twe-root .max-w-full{max-width:100%}#twe-root .max-w-lg{max-width:512px}#twe-root .max-w-md{max-width:448px}#twe-root .max-w-none{max-width:none}#twe-root .max-w-sm{max-width:384px}#twe-root .max-w-xl{max-width:576px}#twe-root .max-w-xs{max-width:320px}#twe-root .flex-1{flex:1 1 0%}#twe-root .flex-shrink-0,#twe-root .shrink-0{flex-shrink:0}#twe-root .flex-grow,#twe-root .grow{flex-grow:1}#twe-root .table-fixed{table-layout:fixed}#twe-root .origin-\\[bottom_center\\]{transform-origin:bottom center}#twe-root .translate-x-0{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#twe-root .translate-x-\\[-500px\\]{--tw-translate-x: -500px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#twe-root .transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#twe-root .transform-none{transform:none}@keyframes ping{75%,to{transform:scale(2);opacity:0}}#twe-root .animate-ping{animation:ping 1s cubic-bezier(0,0,.2,1) infinite}#twe-root .cursor-grab{cursor:grab}#twe-root .cursor-pointer{cursor:pointer}#twe-root .cursor-zoom-in{cursor:zoom-in}#twe-root .select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}#twe-root .resize{resize:both}#twe-root .list-decimal{list-style-type:decimal}#twe-root .grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}#twe-root .grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}#twe-root .grid-cols-\\[auto_minmax\\(auto\\,1fr\\)\\]{grid-template-columns:auto minmax(auto,1fr)}#twe-root .flex-row{flex-direction:row}#twe-root .flex-col{flex-direction:column}#twe-root .flex-wrap{flex-wrap:wrap}#twe-root .items-start{align-items:flex-start}#twe-root .items-end{align-items:flex-end}#twe-root .items-center{align-items:center}#twe-root .items-baseline{align-items:baseline}#twe-root .justify-start{justify-content:flex-start}#twe-root .justify-end{justify-content:flex-end}#twe-root .justify-center{justify-content:center}#twe-root .justify-between{justify-content:space-between}#twe-root .gap-1{gap:4px}#twe-root .gap-2{gap:8px}#twe-root .gap-3{gap:12px}#twe-root .gap-4{gap:16px}#twe-root .space-x-1>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(4px * var(--tw-space-x-reverse));margin-left:calc(4px * calc(1 - var(--tw-space-x-reverse)))}#twe-root .space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(8px * var(--tw-space-x-reverse));margin-left:calc(8px * calc(1 - var(--tw-space-x-reverse)))}#twe-root .space-y-0\\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(2px * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(2px * var(--tw-space-y-reverse))}#twe-root .space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(4px * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(4px * var(--tw-space-y-reverse))}#twe-root .space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(8px * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(8px * var(--tw-space-y-reverse))}#twe-root .overflow-auto{overflow:auto}#twe-root .overflow-hidden{overflow:hidden}#twe-root .overflow-visible{overflow:visible}#twe-root .overflow-scroll{overflow:scroll}#twe-root .overflow-x-auto{overflow-x:auto}#twe-root .overflow-y-auto{overflow-y:auto}#twe-root .overflow-x-scroll{overflow-x:scroll}#twe-root .overflow-y-scroll{overflow-y:scroll}#twe-root .overscroll-contain{overscroll-behavior:contain}#twe-root .overscroll-none{overscroll-behavior:none}#twe-root .scroll-smooth{scroll-behavior:smooth}#twe-root .truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}#twe-root .whitespace-normal{white-space:normal}#twe-root .whitespace-nowrap{white-space:nowrap}#twe-root .whitespace-pre{white-space:pre}#twe-root .whitespace-pre-line{white-space:pre-line}#twe-root .whitespace-pre-wrap{white-space:pre-wrap}#twe-root .break-words{overflow-wrap:break-word}#twe-root .break-all{word-break:break-all}#twe-root .rounded{border-radius:4px}#twe-root .rounded-\\[20px\\]{border-radius:20px}#twe-root .rounded-\\[2px\\]{border-radius:2px}#twe-root .rounded-box{border-radius:var(--rounded-box, 16px)}#twe-root .rounded-full{border-radius:9999px}#twe-root .rounded-md{border-radius:6px}#twe-root .rounded-none{border-radius:0}#twe-root .border{border-width:1px}#twe-root .border-0{border-width:0px}#twe-root .border-b{border-bottom-width:1px}#twe-root .border-l-2{border-left-width:2px}#twe-root .border-t{border-top-width:1px}#twe-root .border-solid{border-style:solid}#twe-root .border-accent\\/40{border-color:var(--fallback-a,oklch(var(--a)/.4))}#twe-root .border-accent\\/50{border-color:var(--fallback-a,oklch(var(--a)/.5))}#twe-root .border-base-300{--tw-border-opacity: 1;border-color:var(--fallback-b3,oklch(var(--b3)/var(--tw-border-opacity, 1)))}#twe-root .border-info\\/50{border-color:var(--fallback-in,oklch(var(--in)/.5))}#twe-root .border-neutral-content{--tw-border-opacity: 1;border-color:var(--fallback-nc,oklch(var(--nc)/var(--tw-border-opacity, 1)))}#twe-root .border-success\\/50{border-color:var(--fallback-su,oklch(var(--su)/.5))}#twe-root .border-warning\\/40{border-color:var(--fallback-wa,oklch(var(--wa)/.4))}#twe-root .border-warning\\/60{border-color:var(--fallback-wa,oklch(var(--wa)/.6))}#twe-root .border-opacity-50{--tw-border-opacity: .5}#twe-root .bg-accent{--tw-bg-opacity: 1;background-color:var(--fallback-a,oklch(var(--a)/var(--tw-bg-opacity, 1)))}#twe-root .bg-accent\\/10{background-color:var(--fallback-a,oklch(var(--a)/.1))}#twe-root .bg-base-100{--tw-bg-opacity: 1;background-color:var(--fallback-b1,oklch(var(--b1)/var(--tw-bg-opacity, 1)))}#twe-root .bg-base-200{--tw-bg-opacity: 1;background-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-bg-opacity, 1)))}#twe-root .bg-base-200\\/50{background-color:var(--fallback-b2,oklch(var(--b2)/.5))}#twe-root .bg-base-200\\/60{background-color:var(--fallback-b2,oklch(var(--b2)/.6))}#twe-root .bg-base-200\\/70{background-color:var(--fallback-b2,oklch(var(--b2)/.7))}#twe-root .bg-base-300{--tw-bg-opacity: 1;background-color:var(--fallback-b3,oklch(var(--b3)/var(--tw-bg-opacity, 1)))}#twe-root .bg-black{--tw-bg-opacity: 1;background-color:rgb(0 0 0 / var(--tw-bg-opacity, 1))}#twe-root .bg-black\\/40{background-color:#0006}#twe-root .bg-info{--tw-bg-opacity: 1;background-color:var(--fallback-in,oklch(var(--in)/var(--tw-bg-opacity, 1)))}#twe-root .bg-neutral{--tw-bg-opacity: 1;background-color:var(--fallback-n,oklch(var(--n)/var(--tw-bg-opacity, 1)))}#twe-root .bg-primary{--tw-bg-opacity: 1;background-color:var(--fallback-p,oklch(var(--p)/var(--tw-bg-opacity, 1)))}#twe-root .bg-secondary{--tw-bg-opacity: 1;background-color:var(--fallback-s,oklch(var(--s)/var(--tw-bg-opacity, 1)))}#twe-root .bg-success{--tw-bg-opacity: 1;background-color:var(--fallback-su,oklch(var(--su)/var(--tw-bg-opacity, 1)))}#twe-root .bg-transparent{background-color:transparent}#twe-root .bg-warning{--tw-bg-opacity: 1;background-color:var(--fallback-wa,oklch(var(--wa)/var(--tw-bg-opacity, 1)))}#twe-root .bg-warning\\/10{background-color:var(--fallback-wa,oklch(var(--wa)/.1))}#twe-root .bg-warning\\/30{background-color:var(--fallback-wa,oklch(var(--wa)/.3))}#twe-root .bg-opacity-30{--tw-bg-opacity: .3}#twe-root .bg-gradient-to-b{background-image:linear-gradient(to bottom,var(--tw-gradient-stops))}#twe-root .bg-gradient-to-t{background-image:linear-gradient(to top,var(--tw-gradient-stops))}#twe-root .from-base-100{--tw-gradient-from: var(--fallback-b1,oklch(var(--b1)/1)) var(--tw-gradient-from-position);--tw-gradient-to: var(--fallback-b1,oklch(var(--b1)/0)) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}#twe-root .from-black\\/70{--tw-gradient-from: rgb(0 0 0 / .7) var(--tw-gradient-from-position);--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}#twe-root .via-black\\/20{--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), rgb(0 0 0 / .2) var(--tw-gradient-via-position), var(--tw-gradient-to)}#twe-root .to-base-200\\/80{--tw-gradient-to: var(--fallback-b2,oklch(var(--b2)/.8)) var(--tw-gradient-to-position)}#twe-root .to-transparent{--tw-gradient-to: transparent var(--tw-gradient-to-position)}#twe-root .object-contain{-o-object-fit:contain;object-fit:contain}#twe-root .object-cover{-o-object-fit:cover;object-fit:cover}#twe-root .\\!p-0{padding:0!important}#twe-root .p-0{padding:0}#twe-root .p-2{padding:8px}#twe-root .p-3{padding:12px}#twe-root .p-6{padding:24px}#twe-root .px-0\\.5{padding-left:2px;padding-right:2px}#twe-root .px-1{padding-left:4px;padding-right:4px}#twe-root .px-1\\.5{padding-left:6px;padding-right:6px}#twe-root .px-2{padding-left:8px;padding-right:8px}#twe-root .px-3{padding-left:12px;padding-right:12px}#twe-root .px-4{padding-left:16px;padding-right:16px}#twe-root .px-\\[1px\\]{padding-left:1px;padding-right:1px}#twe-root .py-0{padding-top:0;padding-bottom:0}#twe-root .py-1{padding-top:4px;padding-bottom:4px}#twe-root .py-1\\.5{padding-top:6px;padding-bottom:6px}#twe-root .py-2{padding-top:8px;padding-bottom:8px}#twe-root .py-2\\.5{padding-top:10px;padding-bottom:10px}#twe-root .py-3{padding-top:12px;padding-bottom:12px}#twe-root .pb-2{padding-bottom:8px}#twe-root .pb-3{padding-bottom:12px}#twe-root .pl-2{padding-left:8px}#twe-root .pl-4{padding-left:16px}#twe-root .pl-5{padding-left:20px}#twe-root .pr-1{padding-right:4px}#twe-root .pr-2{padding-right:8px}#twe-root .pt-1{padding-top:4px}#twe-root .pt-8{padding-top:32px}#twe-root .text-left{text-align:left}#twe-root .text-center{text-align:center}#twe-root .align-top{vertical-align:top}#twe-root .align-middle{vertical-align:middle}#twe-root .font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}#twe-root .text-\\[10px\\]{font-size:10px}#twe-root .text-\\[11px\\]{font-size:11px}#twe-root .text-base{font-size:16px;line-height:24px}#twe-root .text-lg{font-size:18px;line-height:28px}#twe-root .text-sm{font-size:14px;line-height:20px}#twe-root .text-xl{font-size:20px;line-height:28px}#twe-root .text-xs{font-size:12px;line-height:16px}#twe-root .font-bold{font-weight:700}#twe-root .font-medium{font-weight:500}#twe-root .font-normal{font-weight:400}#twe-root .font-semibold{font-weight:600}#twe-root .uppercase{text-transform:uppercase}#twe-root .leading-4{line-height:16px}#twe-root .leading-5{line-height:20px}#twe-root .leading-6{line-height:24px}#twe-root .leading-8{line-height:32px}#twe-root .leading-\\[48px\\]{line-height:48px}#twe-root .leading-loose{line-height:2}#twe-root .leading-none{line-height:1}#twe-root .leading-normal{line-height:1.5}#twe-root .leading-tight{line-height:1.25}#twe-root .tracking-\\[0\\.01em\\]{letter-spacing:.01em}#twe-root .tracking-\\[0\\.08em\\]{letter-spacing:.08em}#twe-root .text-base-content{--tw-text-opacity: 1;color:var(--fallback-bc,oklch(var(--bc)/var(--tw-text-opacity, 1)))}#twe-root .text-base-content\\/50{color:var(--fallback-bc,oklch(var(--bc)/.5))}#twe-root .text-base-content\\/70{color:var(--fallback-bc,oklch(var(--bc)/.7))}#twe-root .text-error{--tw-text-opacity: 1;color:var(--fallback-er,oklch(var(--er)/var(--tw-text-opacity, 1)))}#twe-root .text-gray-400{--tw-text-opacity: 1;color:rgb(156 163 175 / var(--tw-text-opacity, 1))}#twe-root .text-info{--tw-text-opacity: 1;color:var(--fallback-in,oklch(var(--in)/var(--tw-text-opacity, 1)))}#twe-root .text-success{--tw-text-opacity: 1;color:var(--fallback-su,oklch(var(--su)/var(--tw-text-opacity, 1)))}#twe-root .text-warning{--tw-text-opacity: 1;color:var(--fallback-wa,oklch(var(--wa)/var(--tw-text-opacity, 1)))}#twe-root .text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}#twe-root .text-opacity-50{--tw-text-opacity: .5}#twe-root .text-opacity-60{--tw-text-opacity: .6}#twe-root .text-opacity-70{--tw-text-opacity: .7}#twe-root .opacity-50{opacity:.5}#twe-root .opacity-60{opacity:.6}#twe-root .opacity-65{opacity:.65}#twe-root .opacity-70{opacity:.7}#twe-root .opacity-75{opacity:.75}#twe-root .opacity-80{opacity:.8}#twe-root .opacity-90{opacity:.9}#twe-root .shadow{--tw-shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}#twe-root .shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}#twe-root .shadow-md{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}#twe-root .shadow-none{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}#twe-root .shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}#twe-root .shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}#twe-root .\\!filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)!important}#twe-root .filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}#twe-root .transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}#twe-root .transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}#twe-root .transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}#twe-root .transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}#twe-root .duration-150{transition-duration:.15s}#twe-root .duration-200{transition-duration:.2s}#twe-root .duration-300{transition-duration:.3s}#twe-root .duration-500{transition-duration:.5s}#twe-root .ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}#twe-root .rounded-box-half{border-radius:calc(var(--rounded-box) / 2)}#twe-root .table-border-bc :where(thead,tbody) :where(tr:not(:last-child)),#twe-root .table-border-bc :where(thead,tbody) :where(tr:first-child:last-child){--tw-border-opacity: 20%;border-bottom-width:1px;border-bottom-color:var(--fallback-bc, oklch(var(--bc) / var(--tw-border-opacity)))}#twe-root .table-padding-sm :where(th,td){padding:8px 12px}#twe-root .scrollmark-table-cell{min-width:0;max-width:0;overflow-wrap:anywhere;word-break:break-word;vertical-align:top}#twe-root .scrollmark-table-cell-content{min-width:0;max-width:100%;overflow-wrap:anywhere;word-break:break-word}#twe-root .scrollmark-table-cell-content :where(a,p,span,div,code,pre){max-width:100%;overflow-wrap:anywhere;word-break:break-word}#twe-root .scrollmark-table-cell-content :where(.whitespace-pre,.whitespace-pre-wrap){white-space:pre-wrap}#twe-root .no-scrollbar::-webkit-scrollbar{display:none}#twe-root .no-scrollbar{-ms-overflow-style:none;scrollbar-width:none}#twe-root .before\\:max-w-40:before{content:var(--tw-content);max-width:160px}#twe-root .before\\:max-w-max:before{content:var(--tw-content);max-width:-moz-max-content;max-width:max-content}#twe-root .before\\:whitespace-pre-line:before{content:var(--tw-content);white-space:pre-line}#twe-root .hover\\:bg-base-200:hover{--tw-bg-opacity: 1;background-color:var(--fallback-b2,oklch(var(--b2)/var(--tw-bg-opacity, 1)))}#twe-root .active\\:cursor-grabbing:active{cursor:grabbing}#twe-root .group:hover .group-hover\\:translate-x-\\[5px\\]{--tw-translate-x: 5px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#twe-root .group:hover .group-hover\\:rotate-\\[20deg\\]{--tw-rotate: 20deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#twe-root .group:hover .group-hover\\:scale-\\[1\\.02\\]{--tw-scale-x: 1.02;--tw-scale-y: 1.02;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#twe-root .group:hover .group-hover\\:opacity-90{opacity:.9}@media(min-width:640px){#twe-root .sm\\:inline{display:inline}#twe-root .sm\\:grid{display:grid}#twe-root .sm\\:h-9{height:36px}#twe-root .sm\\:max-w-screen-sm{max-width:640px}#twe-root .sm\\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}#twe-root .sm\\:grid-cols-5{grid-template-columns:repeat(5,minmax(0,1fr))}#twe-root .sm\\:gap-2{gap:8px}#twe-root .sm\\:pl-2{padding-left:8px}}@media(min-width:768px){#twe-root .md\\:inline{display:inline}#twe-root .md\\:max-w-screen-md{max-width:768px}#twe-root .md\\:max-w-screen-sm{max-width:640px}#twe-root .md\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(min-width:1024px){#twe-root .lg\\:inline{display:inline}}@media(min-width:1280px){#twe-root .xl\\:inline{display:inline}}#twe-root .\\[\\&\\>path\\]\\:stroke-0>path{stroke-width:0} `);

(function () {
  'use strict';

  var kw=Object.defineProperty;var xw=(e,t,n)=>t in e?kw(e,t,{enumerable:true,configurable:true,writable:true,value:n}):e[t]=n;var je=(e,t,n)=>xw(e,typeof t!="symbol"?t+"":t,n);var Nl,$t,qm,Su,la,_f,Vm,zm,Km,yd,Cu,Tu,Gi={},Wm=[],Sw=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,as=Array.isArray;function so(e,t){for(var n in t)e[n]=t[n];return e}function _d(e){e&&e.parentNode&&e.parentNode.removeChild(e);}function Fo(e,t,n){var r,o,a,i={};for(a in t)a=="key"?r=t[a]:a=="ref"?o=t[a]:i[a]=t[a];if(arguments.length>2&&(i.children=arguments.length>3?Nl.call(arguments,2):n),typeof e=="function"&&e.defaultProps!=null)for(a in e.defaultProps)i[a]===void 0&&(i[a]=e.defaultProps[a]);return Gs(e,i,r,o,null)}function Gs(e,t,n,r,o){var a={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:o??++qm,__i:-1,__u:0};return o==null&&$t.vnode!=null&&$t.vnode(a),a}function Jn(e){return e.children}function Fr(e,t){this.props=e,this.context=t;}function Za(e,t){if(t==null)return e.__?Za(e.__,e.__i+1):null;for(var n;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null)return n.__e;return typeof e.type=="function"?Za(e):null}function Gm(e){var t,n;if((e=e.__)!=null&&e.__c!=null){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null){e.__e=e.__c.base=n.__e;break}return Gm(e)}}function wf(e){(!e.__d&&(e.__d=true)&&la.push(e)&&!il.__r++||_f!==$t.debounceRendering)&&((_f=$t.debounceRendering)||Vm)(il);}function il(){for(var e,t,n,r,o,a,i,s=1;la.length;)la.length>s&&la.sort(zm),e=la.shift(),s=la.length,e.__d&&(n=void 0,o=(r=(t=e).__v).__e,a=[],i=[],t.__P&&((n=so({},r)).__v=r.__v+1,$t.vnode&&$t.vnode(n),wd(t.__P,n,r,t.__n,t.__P.namespaceURI,32&r.__u?[o]:null,a,o??Za(r),!!(32&r.__u),i),n.__v=r.__v,n.__.__k[n.__i]=n,Zm(a,n,i),n.__e!=o&&Gm(n)));il.__r=0;}function Ym(e,t,n,r,o,a,i,s,l,c,h){var f,m,g,_,b,C,k=r&&r.__k||Wm,T=t.length;for(l=Cw(n,t,k,l,T),f=0;f<T;f++)(g=n.__k[f])!=null&&(m=g.__i===-1?Gi:k[g.__i]||Gi,g.__i=f,C=wd(e,g,m,o,a,i,s,l,c,h),_=g.__e,g.ref&&m.ref!=g.ref&&(m.ref&&bd(m.ref,null,g),h.push(g.ref,g.__c||_,g)),b==null&&_!=null&&(b=_),4&g.__u||m.__k===g.__k?l=Xm(g,l,e):typeof g.type=="function"&&C!==void 0?l=C:_&&(l=_.nextSibling),g.__u&=-7);return n.__e=b,l}function Cw(e,t,n,r,o){var a,i,s,l,c,h=n.length,f=h,m=0;for(e.__k=new Array(o),a=0;a<o;a++)(i=t[a])!=null&&typeof i!="boolean"&&typeof i!="function"?(l=a+m,(i=e.__k[a]=typeof i=="string"||typeof i=="number"||typeof i=="bigint"||i.constructor==String?Gs(null,i,null,null,null):as(i)?Gs(Jn,{children:i},null,null,null):i.constructor===void 0&&i.__b>0?Gs(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i).__=e,i.__b=e.__b+1,s=null,(c=i.__i=Tw(i,n,l,f))!==-1&&(f--,(s=n[c])&&(s.__u|=2)),s==null||s.__v===null?(c==-1&&(o>h?m--:o<h&&m++),typeof i.type!="function"&&(i.__u|=4)):c!=l&&(c==l-1?m--:c==l+1?m++:(c>l?m--:m++,i.__u|=4))):e.__k[a]=null;if(f)for(a=0;a<h;a++)(s=n[a])!=null&&(2&s.__u)==0&&(s.__e==r&&(r=Za(s)),Jm(s,s));return r}function Xm(e,t,n){var r,o;if(typeof e.type=="function"){for(r=e.__k,o=0;r&&o<r.length;o++)r[o]&&(r[o].__=e,t=Xm(r[o],t,n));return t}e.__e!=t&&(t&&e.type&&!n.contains(t)&&(t=Za(e)),n.insertBefore(e.__e,t||null),t=e.__e);do t=t&&t.nextSibling;while(t!=null&&t.nodeType==8);return t}function Yi(e,t){return t=t||[],e==null||typeof e=="boolean"||(as(e)?e.some(function(n){Yi(n,t);}):t.push(e)),t}function Tw(e,t,n,r){var o,a,i=e.key,s=e.type,l=t[n];if(l===null&&e.key==null||l&&i==l.key&&s===l.type&&(2&l.__u)==0)return n;if(r>(l!=null&&(2&l.__u)==0?1:0))for(o=n-1,a=n+1;o>=0||a<t.length;){if(o>=0){if((l=t[o])&&(2&l.__u)==0&&i==l.key&&s===l.type)return o;o--;}if(a<t.length){if((l=t[a])&&(2&l.__u)==0&&i==l.key&&s===l.type)return a;a++;}}return  -1}function bf(e,t,n){t[0]=="-"?e.setProperty(t,n??""):e[t]=n==null?"":typeof n!="number"||Sw.test(t)?n:n+"px";}function Ss(e,t,n,r,o){var a;e:if(t=="style")if(typeof n=="string")e.style.cssText=n;else {if(typeof r=="string"&&(e.style.cssText=r=""),r)for(t in r)n&&t in n||bf(e.style,t,"");if(n)for(t in n)r&&n[t]===r[t]||bf(e.style,t,n[t]);}else if(t[0]=="o"&&t[1]=="n")a=t!=(t=t.replace(Km,"$1")),t=t.toLowerCase()in e||t=="onFocusOut"||t=="onFocusIn"?t.toLowerCase().slice(2):t.slice(2),e.l||(e.l={}),e.l[t+a]=n,n?r?n.t=r.t:(n.t=yd,e.addEventListener(t,a?Tu:Cu,a)):e.removeEventListener(t,a?Tu:Cu,a);else {if(o=="http://www.w3.org/2000/svg")t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(t!="width"&&t!="height"&&t!="href"&&t!="list"&&t!="form"&&t!="tabIndex"&&t!="download"&&t!="rowSpan"&&t!="colSpan"&&t!="role"&&t!="popover"&&t in e)try{e[t]=n??"";break e}catch{}typeof n=="function"||(n==null||n===false&&t[4]!="-"?e.removeAttribute(t):e.setAttribute(t,t=="popover"&&n==1?"":n));}}function vf(e){return function(t){if(this.l){var n=this.l[t.type+e];if(t.u==null)t.u=yd++;else if(t.u<n.t)return;return n($t.event?$t.event(t):t)}}}function wd(e,t,n,r,o,a,i,s,l,c){var h,f,m,g,_,b,C,k,T,M,P,F,I,O,B,D,v,L=t.type;if(t.constructor!==void 0)return null;128&n.__u&&(l=!!(32&n.__u),a=[s=t.__e=n.__e]),(h=$t.__b)&&h(t);e:if(typeof L=="function")try{if(k=t.props,T="prototype"in L&&L.prototype.render,M=(h=L.contextType)&&r[h.__c],P=h?M?M.props.value:h.__:r,n.__c?C=(f=t.__c=n.__c).__=f.__E:(T?t.__c=f=new L(k,P):(t.__c=f=new Fr(k,P),f.constructor=L,f.render=Rw),M&&M.sub(f),f.props=k,f.state||(f.state={}),f.context=P,f.__n=r,m=f.__d=!0,f.__h=[],f._sb=[]),T&&f.__s==null&&(f.__s=f.state),T&&L.getDerivedStateFromProps!=null&&(f.__s==f.state&&(f.__s=so({},f.__s)),so(f.__s,L.getDerivedStateFromProps(k,f.__s))),g=f.props,_=f.state,f.__v=t,m)T&&L.getDerivedStateFromProps==null&&f.componentWillMount!=null&&f.componentWillMount(),T&&f.componentDidMount!=null&&f.__h.push(f.componentDidMount);else {if(T&&L.getDerivedStateFromProps==null&&k!==g&&f.componentWillReceiveProps!=null&&f.componentWillReceiveProps(k,P),!f.__e&&(f.shouldComponentUpdate!=null&&f.shouldComponentUpdate(k,f.__s,P)===!1||t.__v==n.__v)){for(t.__v!=n.__v&&(f.props=k,f.state=f.__s,f.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.some(function($){$&&($.__=t);}),F=0;F<f._sb.length;F++)f.__h.push(f._sb[F]);f._sb=[],f.__h.length&&i.push(f);break e}f.componentWillUpdate!=null&&f.componentWillUpdate(k,f.__s,P),T&&f.componentDidUpdate!=null&&f.__h.push(function(){f.componentDidUpdate(g,_,b);});}if(f.context=P,f.props=k,f.__P=e,f.__e=!1,I=$t.__r,O=0,T){for(f.state=f.__s,f.__d=!1,I&&I(t),h=f.render(f.props,f.state,f.context),B=0;B<f._sb.length;B++)f.__h.push(f._sb[B]);f._sb=[];}else do f.__d=!1,I&&I(t),h=f.render(f.props,f.state,f.context),f.state=f.__s;while(f.__d&&++O<25);f.state=f.__s,f.getChildContext!=null&&(r=so(so({},r),f.getChildContext())),T&&!m&&f.getSnapshotBeforeUpdate!=null&&(b=f.getSnapshotBeforeUpdate(g,_)),D=h,h!=null&&h.type===Jn&&h.key==null&&(D=Qm(h.props.children)),s=Ym(e,as(D)?D:[D],t,n,r,o,a,i,s,l,c),f.base=t.__e,t.__u&=-161,f.__h.length&&i.push(f),C&&(f.__E=f.__=null);}catch($){if(t.__v=null,l||a!=null)if($.then){for(t.__u|=l?160:128;s&&s.nodeType==8&&s.nextSibling;)s=s.nextSibling;a[a.indexOf(s)]=null,t.__e=s;}else for(v=a.length;v--;)_d(a[v]);else t.__e=n.__e,t.__k=n.__k;$t.__e($,t,n);}else a==null&&t.__v==n.__v?(t.__k=n.__k,t.__e=n.__e):s=t.__e=Mw(n.__e,t,n,r,o,a,i,l,c);return (h=$t.diffed)&&h(t),128&t.__u?void 0:s}function Zm(e,t,n){for(var r=0;r<n.length;r++)bd(n[r],n[++r],n[++r]);$t.__c&&$t.__c(t,e),e.some(function(o){try{e=o.__h,o.__h=[],e.some(function(a){a.call(o);});}catch(a){$t.__e(a,o.__v);}});}function Qm(e){return typeof e!="object"||e==null?e:as(e)?e.map(Qm):so({},e)}function Mw(e,t,n,r,o,a,i,s,l){var c,h,f,m,g,_,b,C=n.props,k=t.props,T=t.type;if(T=="svg"?o="http://www.w3.org/2000/svg":T=="math"?o="http://www.w3.org/1998/Math/MathML":o||(o="http://www.w3.org/1999/xhtml"),a!=null){for(c=0;c<a.length;c++)if((g=a[c])&&"setAttribute"in g==!!T&&(T?g.localName==T:g.nodeType==3)){e=g,a[c]=null;break}}if(e==null){if(T==null)return document.createTextNode(k);e=document.createElementNS(o,T,k.is&&k),s&&($t.__m&&$t.__m(t,a),s=false),a=null;}if(T===null)C===k||s&&e.data===k||(e.data=k);else {if(a=a&&Nl.call(e.childNodes),C=n.props||Gi,!s&&a!=null)for(C={},c=0;c<e.attributes.length;c++)C[(g=e.attributes[c]).name]=g.value;for(c in C)if(g=C[c],c!="children"){if(c=="dangerouslySetInnerHTML")f=g;else if(!(c in k)){if(c=="value"&&"defaultValue"in k||c=="checked"&&"defaultChecked"in k)continue;Ss(e,c,null,g,o);}}for(c in k)g=k[c],c=="children"?m=g:c=="dangerouslySetInnerHTML"?h=g:c=="value"?_=g:c=="checked"?b=g:s&&typeof g!="function"||C[c]===g||Ss(e,c,g,C[c],o);if(h)s||f&&(h.__html===f.__html||h.__html===e.innerHTML)||(e.innerHTML=h.__html),t.__k=[];else if(f&&(e.innerHTML=""),Ym(t.type==="template"?e.content:e,as(m)?m:[m],t,n,r,T=="foreignObject"?"http://www.w3.org/1999/xhtml":o,a,i,a?a[0]:n.__k&&Za(n,0),s,l),a!=null)for(c=a.length;c--;)_d(a[c]);s||(c="value",T=="progress"&&_==null?e.removeAttribute("value"):_!==void 0&&(_!==e[c]||T=="progress"&&!_||T=="option"&&_!==C[c])&&Ss(e,c,_,C[c],o),c="checked",b!==void 0&&b!==e[c]&&Ss(e,c,b,C[c],o));}return e}function bd(e,t,n){try{if(typeof e=="function"){var r=typeof e.__u=="function";r&&e.__u(),r&&t==null||(e.__u=e(t));}else e.current=t;}catch(o){$t.__e(o,n);}}function Jm(e,t,n){var r,o;if($t.unmount&&$t.unmount(e),(r=e.ref)&&(r.current&&r.current!==e.__e||bd(r,null,t)),(r=e.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount();}catch(a){$t.__e(a,t);}r.base=r.__P=null;}if(r=e.__k)for(o=0;o<r.length;o++)r[o]&&Jm(r[o],t,n||typeof e.type!="function");n||_d(e.__e),e.__c=e.__=e.__e=void 0;}function Rw(e,t,n){return this.constructor(e,n)}function Mu(e,t,n){var r,o,a,i;t==document&&(t=document.documentElement),$t.__&&$t.__(e,t),o=(r=false)?null:t.__k,a=[],i=[],wd(t,e=t.__k=Fo(Jn,null,[e]),o||Gi,Gi,t.namespaceURI,o?null:t.firstChild?Nl.call(t.childNodes):null,a,o?o.__e:t.firstChild,r,i),Zm(a,e,i);}Nl=Wm.slice,$t={__e:function(e,t,n,r){for(var o,a,i;t=t.__;)if((o=t.__c)&&!o.__)try{if((a=o.constructor)&&a.getDerivedStateFromError!=null&&(o.setState(a.getDerivedStateFromError(e)),i=o.__d),o.componentDidCatch!=null&&(o.componentDidCatch(e,r||{}),i=o.__d),i)return o.__E=o}catch(s){e=s;}throw e}},qm=0,Su=function(e){return e!=null&&e.constructor==null},Fr.prototype.setState=function(e,t){var n;n=this.__s!=null&&this.__s!==this.state?this.__s:this.__s=so({},this.state),typeof e=="function"&&(e=e(so({},n),this.props)),e&&so(n,e),e!=null&&this.__v&&(t&&this._sb.push(t),wf(this));},Fr.prototype.forceUpdate=function(e){this.__v&&(this.__e=true,e&&this.__h.push(e),wf(this));},Fr.prototype.render=Jn,la=[],Vm=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,zm=function(e,t){return e.__v.__b-t.__v.__b},il.__r=0,Km=/(PointerCapture)$|Capture$/i,yd=0,Cu=vf(false),Tu=vf(true);var Iw=0;function d(e,t,n,r,o,a){t||(t={});var i,s,l=t;if("ref"in l)for(s in l={},t)s=="ref"?i=t[s]:l[s]=t[s];var c={type:e,props:l,key:n,ref:i,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:--Iw,__i:-1,__u:0,__source:o,__self:a};if(typeof e=="function"&&(i=e.defaultProps))for(s in i)l[s]===void 0&&(l[s]=i[s]);return $t.vnode&&$t.vnode(c),c}/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Ew={outline:{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":2,"stroke-linecap":"round","stroke-linejoin":"round"},filled:{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"currentColor",stroke:"none"}};/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */const Jt=(e,t,n,r)=>{const o=({color:a="currentColor",size:i=24,stroke:s=2,title:l,children:c,className:h="",class:f="",style:m,...g})=>Fo("svg",{...Ew[e],width:String(i),height:String(i),class:["tabler-icon",`tabler-icon-${t}`,f,h].join(" "),...e==="filled"?{fill:a}:{"stroke-width":s,stroke:a},style:m,...g},[l&&Fo("title",{},l),...r.map(([_,b])=>Fo(_,b)),...Yi(c)]);return o.displayName=`${n}`,o};/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Aw=Jt("outline","arrow-up-right","IconArrowUpRight",[["path",{d:"M17 7l-10 10",key:"svg-0"}],["path",{d:"M8 7l9 0l0 9",key:"svg-1"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Dw=Jt("outline","arrows-maximize","IconArrowsMaximize",[["path",{d:"M16 4l4 0l0 4",key:"svg-0"}],["path",{d:"M14 10l6 -6",key:"svg-1"}],["path",{d:"M8 20l-4 0l0 -4",key:"svg-2"}],["path",{d:"M4 20l6 -6",key:"svg-3"}],["path",{d:"M16 20l4 0l0 -4",key:"svg-4"}],["path",{d:"M14 14l6 6",key:"svg-5"}],["path",{d:"M8 4l-4 0l0 4",key:"svg-6"}],["path",{d:"M4 4l6 6",key:"svg-7"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Pw=Jt("outline","arrows-minimize","IconArrowsMinimize",[["path",{d:"M5 9l4 0l0 -4",key:"svg-0"}],["path",{d:"M3 3l6 6",key:"svg-1"}],["path",{d:"M5 15l4 0l0 4",key:"svg-2"}],["path",{d:"M3 21l6 -6",key:"svg-3"}],["path",{d:"M19 9l-4 0l0 -4",key:"svg-4"}],["path",{d:"M15 9l6 -6",key:"svg-5"}],["path",{d:"M19 15l-4 0l0 4",key:"svg-6"}],["path",{d:"M15 15l6 6",key:"svg-7"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Ow=Jt("outline","bookmark","IconBookmark",[["path",{d:"M18 7v14l-6 -4l-6 4v-14a4 4 0 0 1 4 -4h4a4 4 0 0 1 4 4z",key:"svg-0"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Fw=Jt("outline","circle-check","IconCircleCheck",[["path",{d:"M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0",key:"svg-0"}],["path",{d:"M9 12l2 2l4 -4",key:"svg-1"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Lw=Jt("outline","circle-dashed","IconCircleDashed",[["path",{d:"M8.56 3.69a9 9 0 0 0 -2.92 1.95",key:"svg-0"}],["path",{d:"M3.69 8.56a9 9 0 0 0 -.69 3.44",key:"svg-1"}],["path",{d:"M3.69 15.44a9 9 0 0 0 1.95 2.92",key:"svg-2"}],["path",{d:"M8.56 20.31a9 9 0 0 0 3.44 .69",key:"svg-3"}],["path",{d:"M15.44 20.31a9 9 0 0 0 2.92 -1.95",key:"svg-4"}],["path",{d:"M20.31 15.44a9 9 0 0 0 .69 -3.44",key:"svg-5"}],["path",{d:"M20.31 8.56a9 9 0 0 0 -1.95 -2.92",key:"svg-6"}],["path",{d:"M15.44 3.69a9 9 0 0 0 -3.44 -.69",key:"svg-7"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var vc=Jt("outline","database-export","IconDatabaseExport",[["path",{d:"M4 6c0 1.657 3.582 3 8 3s8 -1.343 8 -3s-3.582 -3 -8 -3s-8 1.343 -8 3",key:"svg-0"}],["path",{d:"M4 6v6c0 1.657 3.582 3 8 3c1.118 0 2.183 -.086 3.15 -.241",key:"svg-1"}],["path",{d:"M20 12v-6",key:"svg-2"}],["path",{d:"M4 12v6c0 1.657 3.582 3 8 3c.157 0 .312 -.002 .466 -.005",key:"svg-3"}],["path",{d:"M16 19h6",key:"svg-4"}],["path",{d:"M19 16l3 3l-3 3",key:"svg-5"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Nw=Jt("outline","database-import","IconDatabaseImport",[["path",{d:"M4 6c0 1.657 3.582 3 8 3s8 -1.343 8 -3s-3.582 -3 -8 -3s-8 1.343 -8 3",key:"svg-0"}],["path",{d:"M4 6v6c0 1.657 3.582 3 8 3c.856 0 1.68 -.05 2.454 -.144m5.546 -2.856v-6",key:"svg-1"}],["path",{d:"M4 12v6c0 1.657 3.582 3 8 3c.171 0 .341 -.002 .51 -.006",key:"svg-2"}],["path",{d:"M19 22v-6",key:"svg-3"}],["path",{d:"M22 19l-3 -3l-3 3",key:"svg-4"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Bw=Jt("outline","exclamation-circle","IconExclamationCircle",[["path",{d:"M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0",key:"svg-0"}],["path",{d:"M12 9v4",key:"svg-1"}],["path",{d:"M12 16v.01",key:"svg-2"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var eg=Jt("outline","external-link","IconExternalLink",[["path",{d:"M12 6h-6a2 2 0 0 0 -2 2v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2 -2v-6",key:"svg-0"}],["path",{d:"M11 13l9 -9",key:"svg-1"}],["path",{d:"M15 4h5v5",key:"svg-2"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Uw=Jt("outline","file-download","IconFileDownload",[["path",{d:"M14 3v4a1 1 0 0 0 1 1h4",key:"svg-0"}],["path",{d:"M17 21h-10a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2h7l5 5v11a2 2 0 0 1 -2 2z",key:"svg-1"}],["path",{d:"M12 17v-6",key:"svg-2"}],["path",{d:"M9.5 14.5l2.5 2.5l2.5 -2.5",key:"svg-3"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var $w=Jt("outline","heart","IconHeart",[["path",{d:"M19.5 12.572l-7.5 7.428l-7.5 -7.428a5 5 0 1 1 7.5 -6.566a5 5 0 1 1 7.5 6.572",key:"svg-0"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Ha=Jt("outline","help","IconHelp",[["path",{d:"M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0",key:"svg-0"}],["path",{d:"M12 17l0 .01",key:"svg-1"}],["path",{d:"M12 13.5a1.5 1.5 0 0 1 1 -1.5a2.6 2.6 0 1 0 -3 -4",key:"svg-2"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var tg=Jt("outline","info-circle","IconInfoCircle",[["path",{d:"M3 12a9 9 0 1 0 18 0a9 9 0 0 0 -18 0",key:"svg-0"}],["path",{d:"M12 9h.01",key:"svg-1"}],["path",{d:"M11 12h1v4h1",key:"svg-2"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Hw=Jt("outline","layout-columns","IconLayoutColumns",[["path",{d:"M4 4m0 2a2 2 0 0 1 2 -2h12a2 2 0 0 1 2 2v12a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2z",key:"svg-0"}],["path",{d:"M12 4l0 16",key:"svg-1"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var jw=Jt("outline","layout-grid","IconLayoutGrid",[["path",{d:"M4 4m0 1a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1z",key:"svg-0"}],["path",{d:"M14 4m0 1a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1z",key:"svg-1"}],["path",{d:"M4 14m0 1a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1z",key:"svg-2"}],["path",{d:"M14 14m0 1a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1z",key:"svg-3"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var ng=Jt("outline","link","IconLink",[["path",{d:"M9 15l6 -6",key:"svg-0"}],["path",{d:"M11 6l.463 -.536a5 5 0 0 1 7.071 7.072l-.534 .464",key:"svg-1"}],["path",{d:"M13 18l-.397 .534a5.068 5.068 0 0 1 -7.127 0a4.972 4.972 0 0 1 0 -7.071l.524 -.463",key:"svg-2"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var qw=Jt("outline","photo","IconPhoto",[["path",{d:"M15 8h.01",key:"svg-0"}],["path",{d:"M3 6a3 3 0 0 1 3 -3h12a3 3 0 0 1 3 3v12a3 3 0 0 1 -3 3h-12a3 3 0 0 1 -3 -3v-12z",key:"svg-1"}],["path",{d:"M3 16l5 -5c.928 -.893 2.072 -.893 3 0l5 5",key:"svg-2"}],["path",{d:"M14 14l1 -1c.928 -.893 2.072 -.893 3 0l3 3",key:"svg-3"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var rg=Jt("outline","refresh","IconRefresh",[["path",{d:"M20 11a8.1 8.1 0 0 0 -15.5 -2m-.5 -4v4h4",key:"svg-0"}],["path",{d:"M4 13a8.1 8.1 0 0 0 15.5 2m.5 4v-4h-4",key:"svg-1"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Vw=Jt("outline","repeat","IconRepeat",[["path",{d:"M4 12v-3a3 3 0 0 1 3 -3h13m-3 -3l3 3l-3 3",key:"svg-0"}],["path",{d:"M20 12v3a3 3 0 0 1 -3 3h-13m3 3l-3 -3l3 -3",key:"svg-1"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var kf=Jt("outline","report-analytics","IconReportAnalytics",[["path",{d:"M9 5h-2a2 2 0 0 0 -2 2v12a2 2 0 0 0 2 2h10a2 2 0 0 0 2 -2v-12a2 2 0 0 0 -2 -2h-2",key:"svg-0"}],["path",{d:"M9 3m0 2a2 2 0 0 1 2 -2h2a2 2 0 0 1 2 2v0a2 2 0 0 1 -2 2h-2a2 2 0 0 1 -2 -2z",key:"svg-1"}],["path",{d:"M9 17v-5",key:"svg-2"}],["path",{d:"M12 17v-1",key:"svg-3"}],["path",{d:"M15 17v-3",key:"svg-4"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var zw=Jt("outline","search","IconSearch",[["path",{d:"M10 10m-7 0a7 7 0 1 0 14 0a7 7 0 1 0 -14 0",key:"svg-0"}],["path",{d:"M21 21l-6 -6",key:"svg-1"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Kw=Jt("outline","settings","IconSettings",[["path",{d:"M10.325 4.317c.426 -1.756 2.924 -1.756 3.35 0a1.724 1.724 0 0 0 2.573 1.066c1.543 -.94 3.31 .826 2.37 2.37a1.724 1.724 0 0 0 1.065 2.572c1.756 .426 1.756 2.924 0 3.35a1.724 1.724 0 0 0 -1.066 2.573c.94 1.543 -.826 3.31 -2.37 2.37a1.724 1.724 0 0 0 -2.572 1.065c-.426 1.756 -2.924 1.756 -3.35 0a1.724 1.724 0 0 0 -2.573 -1.066c-1.543 .94 -3.31 -.826 -2.37 -2.37a1.724 1.724 0 0 0 -1.065 -2.572c-1.756 -.426 -1.756 -2.924 0 -3.35a1.724 1.724 0 0 0 1.066 -2.573c-.94 -1.543 .826 -3.31 2.37 -2.37c1 .608 2.296 .07 2.572 -1.065z",key:"svg-0"}],["path",{d:"M9 12a3 3 0 1 0 6 0a3 3 0 0 0 -6 0",key:"svg-1"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Ww=Jt("outline","sort-ascending","IconSortAscending",[["path",{d:"M4 6l7 0",key:"svg-0"}],["path",{d:"M4 12l7 0",key:"svg-1"}],["path",{d:"M4 18l9 0",key:"svg-2"}],["path",{d:"M15 9l3 -3l3 3",key:"svg-3"}],["path",{d:"M18 6l0 12",key:"svg-4"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Gw=Jt("outline","sort-descending","IconSortDescending",[["path",{d:"M4 6l9 0",key:"svg-0"}],["path",{d:"M4 12l7 0",key:"svg-1"}],["path",{d:"M4 18l7 0",key:"svg-2"}],["path",{d:"M15 15l3 3l3 -3",key:"svg-3"}],["path",{d:"M18 6l0 12",key:"svg-4"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Ys=Jt("outline","table","IconTable",[["path",{d:"M3 5a2 2 0 0 1 2 -2h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14z",key:"svg-0"}],["path",{d:"M3 10h18",key:"svg-1"}],["path",{d:"M10 3v18",key:"svg-2"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Yw=Jt("outline","trash-x","IconTrashX",[["path",{d:"M4 7h16",key:"svg-0"}],["path",{d:"M5 7l1 12a2 2 0 0 0 2 2h8a2 2 0 0 0 2 -2l1 -12",key:"svg-1"}],["path",{d:"M9 7v-3a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v3",key:"svg-2"}],["path",{d:"M10 12l4 4m0 -4l-4 4",key:"svg-3"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Xw=Jt("outline","trash","IconTrash",[["path",{d:"M4 7l16 0",key:"svg-0"}],["path",{d:"M10 11l0 6",key:"svg-1"}],["path",{d:"M14 11l0 6",key:"svg-2"}],["path",{d:"M5 7l1 12a2 2 0 0 0 2 2h8a2 2 0 0 0 2 -2l1 -12",key:"svg-3"}],["path",{d:"M9 7v-3a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v3",key:"svg-4"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var sl=Jt("outline","x","IconX",[["path",{d:"M18 6l-12 12",key:"svg-0"}],["path",{d:"M6 6l12 12",key:"svg-1"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Zw=Jt("outline","zoom-in","IconZoomIn",[["path",{d:"M10 10m-7 0a7 7 0 1 0 14 0a7 7 0 1 0 -14 0",key:"svg-0"}],["path",{d:"M7 10l6 0",key:"svg-1"}],["path",{d:"M10 7l0 6",key:"svg-2"}],["path",{d:"M21 21l-6 -6",key:"svg-3"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Qw=Jt("outline","zoom-out","IconZoomOut",[["path",{d:"M10 10m-7 0a7 7 0 1 0 14 0a7 7 0 1 0 -14 0",key:"svg-0"}],["path",{d:"M7 10l6 0",key:"svg-1"}],["path",{d:"M21 21l-6 -6",key:"svg-2"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var Jw=Jt("filled","brand-github-filled","IconBrandGithubFilled",[["path",{d:"M5.315 2.1c.791 -.113 1.9 .145 3.333 .966l.272 .161l.16 .1l.397 -.083a13.3 13.3 0 0 1 4.59 -.08l.456 .08l.396 .083l.161 -.1c1.385 -.84 2.487 -1.17 3.322 -1.148l.164 .008l.147 .017l.076 .014l.05 .011l.144 .047a1 1 0 0 1 .53 .514a5.2 5.2 0 0 1 .397 2.91l-.047 .267l-.046 .196l.123 .163c.574 .795 .93 1.728 1.03 2.707l.023 .295l.007 .272c0 3.855 -1.659 5.883 -4.644 6.68l-.245 .061l-.132 .029l.014 .161l.008 .157l.004 .365l-.002 .213l-.003 3.834a1 1 0 0 1 -.883 .993l-.117 .007h-6a1 1 0 0 1 -.993 -.883l-.007 -.117v-.734c-1.818 .26 -3.03 -.424 -4.11 -1.878l-.535 -.766c-.28 -.396 -.455 -.579 -.589 -.644l-.048 -.019a1 1 0 0 1 .564 -1.918c.642 .188 1.074 .568 1.57 1.239l.538 .769c.76 1.079 1.36 1.459 2.609 1.191l.001 -.678l-.018 -.168a5.03 5.03 0 0 1 -.021 -.824l.017 -.185l.019 -.12l-.108 -.024c-2.976 -.71 -4.703 -2.573 -4.875 -6.139l-.01 -.31l-.004 -.292a5.6 5.6 0 0 1 .908 -3.051l.152 -.222l.122 -.163l-.045 -.196a5.2 5.2 0 0 1 .145 -2.642l.1 -.282l.106 -.253a1 1 0 0 1 .529 -.514l.144 -.047l.154 -.03z",key:"svg-0"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var eb=Jt("filled","brand-twitter-filled","IconBrandTwitterFilled",[["path",{d:"M14.058 3.41c-1.807 .767 -2.995 2.453 -3.056 4.38l-.002 .182l-.243 -.023c-2.392 -.269 -4.498 -1.512 -5.944 -3.531a1 1 0 0 0 -1.685 .092l-.097 .186l-.049 .099c-.719 1.485 -1.19 3.29 -1.017 5.203l.03 .273c.283 2.263 1.5 4.215 3.779 5.679l.173 .107l-.081 .043c-1.315 .663 -2.518 .952 -3.827 .9c-1.056 -.04 -1.446 1.372 -.518 1.878c3.598 1.961 7.461 2.566 10.792 1.6c4.06 -1.18 7.152 -4.223 8.335 -8.433l.127 -.495c.238 -.993 .372 -2.006 .401 -3.024l.003 -.332l.393 -.779l.44 -.862l.214 -.434l.118 -.247c.265 -.565 .456 -1.033 .574 -1.43l.014 -.056l.008 -.018c.22 -.593 -.166 -1.358 -.941 -1.358l-.122 .007a.997 .997 0 0 0 -.231 .057l-.086 .038a7.46 7.46 0 0 1 -.88 .36l-.356 .115l-.271 .08l-.772 .214c-1.336 -1.118 -3.144 -1.254 -5.012 -.554l-.211 .084z",key:"svg-0"}]]);/**
   * @license @tabler/icons-preact v3.31.0 - MIT
   *
   * This source code is licensed under the MIT license.
   * See the LICENSE file in the root directory of this source tree.
   */var tb=Jt("filled","player-play-filled","IconPlayerPlayFilled",[["path",{d:"M6 4v16a1 1 0 0 0 1.524 .852l13 -8a1 1 0 0 0 0 -1.704l-13 -8a1 1 0 0 0 -1.524 .852z",key:"svg-0"}]]),Qa,Cn,kc,xf,Xi=0,og=[],Rn=$t,Sf=Rn.__b,Cf=Rn.__r,Tf=Rn.diffed,Mf=Rn.__c,Rf=Rn.unmount,If=Rn.__;function Bl(e,t){Rn.__h&&Rn.__h(Cn,e,Xi||t),Xi=0;var n=Cn.__H||(Cn.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({}),n.__[e]}function De(e){return Xi=1,ag(ig,e)}function ag(e,t,n){var r=Bl(Qa++,2);if(r.t=e,!r.__c&&(r.__=[ig(void 0,t),function(s){var l=r.__N?r.__N[0]:r.__[0],c=r.t(l,s);l!==c&&(r.__N=[c,r.__[1]],r.__c.setState({}));}],r.__c=Cn,!Cn.__f)){var o=function(s,l,c){if(!r.__c.__H)return  true;var h=r.__c.__H.__.filter(function(m){return !!m.__c});if(h.every(function(m){return !m.__N}))return !a||a.call(this,s,l,c);var f=r.__c.props!==s;return h.forEach(function(m){if(m.__N){var g=m.__[0];m.__=m.__N,m.__N=void 0,g!==m.__[0]&&(f=true);}}),a&&a.call(this,s,l,c)||f};Cn.__f=true;var a=Cn.shouldComponentUpdate,i=Cn.componentWillUpdate;Cn.componentWillUpdate=function(s,l,c){if(this.__e){var h=a;a=void 0,o(s,l,c),a=h;}i&&i.call(this,s,l,c);},Cn.shouldComponentUpdate=o;}return r.__N||r.__}function Je(e,t){var n=Bl(Qa++,3);!Rn.__s&&vd(n.__H,t)&&(n.__=e,n.u=t,Cn.__H.__h.push(n));}function nb(e,t){var n=Bl(Qa++,4);!Rn.__s&&vd(n.__H,t)&&(n.__=e,n.u=t,Cn.__h.push(n));}function _t(e){return Xi=5,It(function(){return {current:e}},[])}function It(e,t){var n=Bl(Qa++,7);return vd(n.__H,t)&&(n.__=e(),n.__H=t,n.__h=e),n.__}function Nn(e,t){return Xi=8,It(function(){return e},t)}function rb(){for(var e;e=og.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(Xs),e.__H.__h.forEach(Ru),e.__H.__h=[];}catch(t){e.__H.__h=[],Rn.__e(t,e.__v);}}Rn.__b=function(e){Cn=null,Sf&&Sf(e);},Rn.__=function(e,t){e&&t.__k&&t.__k.__m&&(e.__m=t.__k.__m),If&&If(e,t);},Rn.__r=function(e){Cf&&Cf(e),Qa=0;var t=(Cn=e.__c).__H;t&&(kc===Cn?(t.__h=[],Cn.__h=[],t.__.forEach(function(n){n.__N&&(n.__=n.__N),n.u=n.__N=void 0;})):(t.__h.forEach(Xs),t.__h.forEach(Ru),t.__h=[],Qa=0)),kc=Cn;},Rn.diffed=function(e){Tf&&Tf(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(og.push(t)!==1&&xf===Rn.requestAnimationFrame||((xf=Rn.requestAnimationFrame)||ob)(rb)),t.__H.__.forEach(function(n){n.u&&(n.__H=n.u),n.u=void 0;})),kc=Cn=null;},Rn.__c=function(e,t){t.some(function(n){try{n.__h.forEach(Xs),n.__h=n.__h.filter(function(r){return !r.__||Ru(r)});}catch(r){t.some(function(o){o.__h&&(o.__h=[]);}),t=[],Rn.__e(r,n.__v);}}),Mf&&Mf(e,t);},Rn.unmount=function(e){Rf&&Rf(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach(function(r){try{Xs(r);}catch(o){t=o;}}),n.__H=void 0,t&&Rn.__e(t,n.__v));};var Ef=typeof requestAnimationFrame=="function";function ob(e){var t,n=function(){clearTimeout(r),Ef&&cancelAnimationFrame(t),setTimeout(e);},r=setTimeout(n,100);Ef&&(t=requestAnimationFrame(n));}function Xs(e){var t=Cn,n=e.__c;typeof n=="function"&&(e.__c=void 0,n()),Cn=t;}function Ru(e){var t=Cn;e.__c=e.__(),Cn=t;}function vd(e,t){return !e||e.length!==t.length||t.some(function(n,r){return n!==e[r]})}function ig(e,t){return typeof t=="function"?t(e):t}const Bt=e=>typeof e=="string",_i=()=>{let e,t;const n=new Promise((r,o)=>{e=r,t=o;});return n.resolve=e,n.reject=t,n},Af=e=>e==null?"":""+e,ab=(e,t,n)=>{e.forEach(r=>{t[r]&&(n[r]=t[r]);});},ib=/###/g,Df=e=>e&&e.indexOf("###")>-1?e.replace(ib,"."):e,Pf=e=>!e||Bt(e),Oi=(e,t,n)=>{const r=Bt(t)?t.split("."):t;let o=0;for(;o<r.length-1;){if(Pf(e))return {};const a=Df(r[o]);!e[a]&&n&&(e[a]=new n),Object.prototype.hasOwnProperty.call(e,a)?e=e[a]:e={},++o;}return Pf(e)?{}:{obj:e,k:Df(r[o])}},Of=(e,t,n)=>{const{obj:r,k:o}=Oi(e,t,Object);if(r!==void 0||t.length===1){r[o]=n;return}let a=t[t.length-1],i=t.slice(0,t.length-1),s=Oi(e,i,Object);for(;s.obj===void 0&&i.length;)a=`${i[i.length-1]}.${a}`,i=i.slice(0,i.length-1),s=Oi(e,i,Object),s!=null&&s.obj&&typeof s.obj[`${s.k}.${a}`]<"u"&&(s.obj=void 0);s.obj[`${s.k}.${a}`]=n;},sb=(e,t,n,r)=>{const{obj:o,k:a}=Oi(e,t,Object);o[a]=o[a]||[],o[a].push(n);},ll=(e,t)=>{const{obj:n,k:r}=Oi(e,t);if(n&&Object.prototype.hasOwnProperty.call(n,r))return n[r]},lb=(e,t,n)=>{const r=ll(e,n);return r!==void 0?r:ll(t,n)},sg=(e,t,n)=>{for(const r in t)r!=="__proto__"&&r!=="constructor"&&(r in e?Bt(e[r])||e[r]instanceof String||Bt(t[r])||t[r]instanceof String?n&&(e[r]=t[r]):sg(e[r],t[r],n):e[r]=t[r]);return e},Ra=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var cb={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;"};const ub=e=>Bt(e)?e.replace(/[&<>"'\/]/g,t=>cb[t]):e;class db{constructor(t){this.capacity=t,this.regExpMap=new Map,this.regExpQueue=[];}getRegExp(t){const n=this.regExpMap.get(t);if(n!==void 0)return n;const r=new RegExp(t);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(t,r),this.regExpQueue.push(t),r}}const fb=[" ",",","?","!",";"],hb=new db(20),pb=(e,t,n)=>{t=t||"",n=n||"";const r=fb.filter(i=>t.indexOf(i)<0&&n.indexOf(i)<0);if(r.length===0)return  true;const o=hb.getRegExp(`(${r.map(i=>i==="?"?"\\?":i).join("|")})`);let a=!o.test(e);if(!a){const i=e.indexOf(n);i>0&&!o.test(e.substring(0,i))&&(a=true);}return a},Iu=function(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".";if(!e)return;if(e[t])return Object.prototype.hasOwnProperty.call(e,t)?e[t]:void 0;const r=t.split(n);let o=e;for(let a=0;a<r.length;){if(!o||typeof o!="object")return;let i,s="";for(let l=a;l<r.length;++l)if(l!==a&&(s+=n),s+=r[l],i=o[s],i!==void 0){if(["string","number","boolean"].indexOf(typeof i)>-1&&l<r.length-1)continue;a+=l-a+1;break}o=i;}return o},cl=e=>e==null?void 0:e.replace("_","-"),mb={type:"logger",log(e){this.output("log",e);},warn(e){this.output("warn",e);},error(e){this.output("error",e);},output(e,t){var n,r;(r=(n=console==null?void 0:console[e])==null?void 0:n.apply)==null||r.call(n,console,t);}};let gb=class Eu{constructor(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.init(t,n);}init(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.prefix=n.prefix||"i18next:",this.logger=t||mb,this.options=n,this.debug=n.debug;}log(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return this.forward(n,"log","",true)}warn(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return this.forward(n,"warn","",true)}error(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return this.forward(n,"error","")}deprecate(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return this.forward(n,"warn","WARNING DEPRECATED: ",true)}forward(t,n,r,o){return o&&!this.debug?null:(Bt(t[0])&&(t[0]=`${r}${this.prefix} ${t[0]}`),this.logger[n](t))}create(t){return new Eu(this.logger,{prefix:`${this.prefix}:${t}:`,...this.options})}clone(t){return t=t||this.options,t.prefix=t.prefix||this.prefix,new Eu(this.logger,t)}};var Gr=new gb;class Ul{constructor(){this.observers={};}on(t,n){return t.split(" ").forEach(r=>{this.observers[r]||(this.observers[r]=new Map);const o=this.observers[r].get(n)||0;this.observers[r].set(n,o+1);}),this}off(t,n){if(this.observers[t]){if(!n){delete this.observers[t];return}this.observers[t].delete(n);}}emit(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];this.observers[t]&&Array.from(this.observers[t].entries()).forEach(i=>{let[s,l]=i;for(let c=0;c<l;c++)s(...r);}),this.observers["*"]&&Array.from(this.observers["*"].entries()).forEach(i=>{let[s,l]=i;for(let c=0;c<l;c++)s.apply(s,[t,...r]);});}}class Ff extends Ul{constructor(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{ns:["translation"],defaultNS:"translation"};super(),this.data=t||{},this.options=n,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.options.ignoreJSONStructure===void 0&&(this.options.ignoreJSONStructure=true);}addNamespaces(t){this.options.ns.indexOf(t)<0&&this.options.ns.push(t);}removeNamespaces(t){const n=this.options.ns.indexOf(t);n>-1&&this.options.ns.splice(n,1);}getResource(t,n,r){var c,h;let o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const a=o.keySeparator!==void 0?o.keySeparator:this.options.keySeparator,i=o.ignoreJSONStructure!==void 0?o.ignoreJSONStructure:this.options.ignoreJSONStructure;let s;t.indexOf(".")>-1?s=t.split("."):(s=[t,n],r&&(Array.isArray(r)?s.push(...r):Bt(r)&&a?s.push(...r.split(a)):s.push(r)));const l=ll(this.data,s);return !l&&!n&&!r&&t.indexOf(".")>-1&&(t=s[0],n=s[1],r=s.slice(2).join(".")),l||!i||!Bt(r)?l:Iu((h=(c=this.data)==null?void 0:c[t])==null?void 0:h[n],r,a)}addResource(t,n,r,o){let a=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{silent:false};const i=a.keySeparator!==void 0?a.keySeparator:this.options.keySeparator;let s=[t,n];r&&(s=s.concat(i?r.split(i):r)),t.indexOf(".")>-1&&(s=t.split("."),o=n,n=s[1]),this.addNamespaces(n),Of(this.data,s,o),a.silent||this.emit("added",t,n,r,o);}addResources(t,n,r){let o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{silent:false};for(const a in r)(Bt(r[a])||Array.isArray(r[a]))&&this.addResource(t,n,a,r[a],{silent:true});o.silent||this.emit("added",t,n,r);}addResourceBundle(t,n,r,o,a){let i=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{silent:false,skipCopy:false},s=[t,n];t.indexOf(".")>-1&&(s=t.split("."),o=r,r=n,n=s[1]),this.addNamespaces(n);let l=ll(this.data,s)||{};i.skipCopy||(r=JSON.parse(JSON.stringify(r))),o?sg(l,r,a):l={...l,...r},Of(this.data,s,l),i.silent||this.emit("added",t,n,r);}removeResourceBundle(t,n){this.hasResourceBundle(t,n)&&delete this.data[t][n],this.removeNamespaces(n),this.emit("removed",t,n);}hasResourceBundle(t,n){return this.getResource(t,n)!==void 0}getResourceBundle(t,n){return n||(n=this.options.defaultNS),this.getResource(t,n)}getDataByLanguage(t){return this.data[t]}hasLanguageSomeTranslations(t){const n=this.getDataByLanguage(t);return !!(n&&Object.keys(n)||[]).find(o=>n[o]&&Object.keys(n[o]).length>0)}toJSON(){return this.data}}var lg={processors:{},addPostProcessor(e){this.processors[e.name]=e;},handle(e,t,n,r,o){return e.forEach(a=>{var i;t=((i=this.processors[a])==null?void 0:i.process(t,n,r,o))??t;}),t}};const Lf={},Nf=e=>!Bt(e)&&typeof e!="boolean"&&typeof e!="number";class ul extends Ul{constructor(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};super(),ab(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],t,this),this.options=n,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.logger=Gr.create("translator");}changeLanguage(t){t&&(this.language=t);}exists(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};if(t==null)return  false;const r=this.resolve(t,n);return (r==null?void 0:r.res)!==void 0}extractFromKey(t,n){let r=n.nsSeparator!==void 0?n.nsSeparator:this.options.nsSeparator;r===void 0&&(r=":");const o=n.keySeparator!==void 0?n.keySeparator:this.options.keySeparator;let a=n.ns||this.options.defaultNS||[];const i=r&&t.indexOf(r)>-1,s=!this.options.userDefinedKeySeparator&&!n.keySeparator&&!this.options.userDefinedNsSeparator&&!n.nsSeparator&&!pb(t,r,o);if(i&&!s){const l=t.match(this.interpolator.nestingRegexp);if(l&&l.length>0)return {key:t,namespaces:Bt(a)?[a]:a};const c=t.split(r);(r!==o||r===o&&this.options.ns.indexOf(c[0])>-1)&&(a=c.shift()),t=c.join(o);}return {key:t,namespaces:Bt(a)?[a]:a}}translate(t,n,r){if(typeof n!="object"&&this.options.overloadTranslationOptionHandler&&(n=this.options.overloadTranslationOptionHandler(arguments)),typeof n=="object"&&(n={...n}),n||(n={}),t==null)return "";Array.isArray(t)||(t=[String(t)]);const o=n.returnDetails!==void 0?n.returnDetails:this.options.returnDetails,a=n.keySeparator!==void 0?n.keySeparator:this.options.keySeparator,{key:i,namespaces:s}=this.extractFromKey(t[t.length-1],n),l=s[s.length-1],c=n.lng||this.language,h=n.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if((c==null?void 0:c.toLowerCase())==="cimode"){if(h){const L=n.nsSeparator||this.options.nsSeparator;return o?{res:`${l}${L}${i}`,usedKey:i,exactUsedKey:i,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(n)}:`${l}${L}${i}`}return o?{res:i,usedKey:i,exactUsedKey:i,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(n)}:i}const f=this.resolve(t,n);let m=f==null?void 0:f.res;const g=(f==null?void 0:f.usedKey)||i,_=(f==null?void 0:f.exactUsedKey)||i,b=["[object Number]","[object Function]","[object RegExp]"],C=n.joinArrays!==void 0?n.joinArrays:this.options.joinArrays,k=!this.i18nFormat||this.i18nFormat.handleAsObject,T=n.count!==void 0&&!Bt(n.count),M=ul.hasDefaultValue(n),P=T?this.pluralResolver.getSuffix(c,n.count,n):"",F=n.ordinal&&T?this.pluralResolver.getSuffix(c,n.count,{ordinal:false}):"",I=T&&!n.ordinal&&n.count===0,O=I&&n[`defaultValue${this.options.pluralSeparator}zero`]||n[`defaultValue${P}`]||n[`defaultValue${F}`]||n.defaultValue;let B=m;k&&!m&&M&&(B=O);const D=Nf(B),v=Object.prototype.toString.apply(B);if(k&&B&&D&&b.indexOf(v)<0&&!(Bt(C)&&Array.isArray(B))){if(!n.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const L=this.options.returnedObjectHandler?this.options.returnedObjectHandler(g,B,{...n,ns:s}):`key '${i} (${this.language})' returned an object instead of string.`;return o?(f.res=L,f.usedParams=this.getUsedParamsDetails(n),f):L}if(a){const L=Array.isArray(B),$=L?[]:{},Me=L?_:g;for(const Z in B)if(Object.prototype.hasOwnProperty.call(B,Z)){const re=`${Me}${a}${Z}`;M&&!m?$[Z]=this.translate(re,{...n,defaultValue:Nf(O)?O[Z]:void 0,joinArrays:false,ns:s}):$[Z]=this.translate(re,{...n,joinArrays:false,ns:s}),$[Z]===re&&($[Z]=B[Z]);}m=$;}}else if(k&&Bt(C)&&Array.isArray(m))m=m.join(C),m&&(m=this.extendTranslation(m,t,n,r));else {let L=false,$=false;!this.isValidLookup(m)&&M&&(L=true,m=O),this.isValidLookup(m)||($=true,m=i);const Z=(n.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&$?void 0:m,re=M&&O!==m&&this.options.updateMissing;if($||L||re){if(this.logger.log(re?"updateKey":"missingKey",c,l,i,re?O:m),a){const pe=this.resolve(i,{...n,keySeparator:false});pe&&pe.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.");}let J=[];const le=this.languageUtils.getFallbackCodes(this.options.fallbackLng,n.lng||this.language);if(this.options.saveMissingTo==="fallback"&&le&&le[0])for(let pe=0;pe<le.length;pe++)J.push(le[pe]);else this.options.saveMissingTo==="all"?J=this.languageUtils.toResolveHierarchy(n.lng||this.language):J.push(n.lng||this.language);const he=(pe,ge,z)=>{var Pe;const ue=M&&z!==m?z:Z;this.options.missingKeyHandler?this.options.missingKeyHandler(pe,l,ge,ue,re,n):(Pe=this.backendConnector)!=null&&Pe.saveMissing&&this.backendConnector.saveMissing(pe,l,ge,ue,re,n),this.emit("missingKey",pe,l,ge,m);};this.options.saveMissing&&(this.options.saveMissingPlurals&&T?J.forEach(pe=>{const ge=this.pluralResolver.getSuffixes(pe,n);I&&n[`defaultValue${this.options.pluralSeparator}zero`]&&ge.indexOf(`${this.options.pluralSeparator}zero`)<0&&ge.push(`${this.options.pluralSeparator}zero`),ge.forEach(z=>{he([pe],i+z,n[`defaultValue${z}`]||O);});}):he(J,i,O));}m=this.extendTranslation(m,t,n,f,r),$&&m===i&&this.options.appendNamespaceToMissingKey&&(m=`${l}:${i}`),($||L)&&this.options.parseMissingKeyHandler&&(m=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${l}:${i}`:i,L?m:void 0));}return o?(f.res=m,f.usedParams=this.getUsedParamsDetails(n),f):m}extendTranslation(t,n,r,o,a){var c,h;var i=this;if((c=this.i18nFormat)!=null&&c.parse)t=this.i18nFormat.parse(t,{...this.options.interpolation.defaultVariables,...r},r.lng||this.language||o.usedLng,o.usedNS,o.usedKey,{resolved:o});else if(!r.skipInterpolation){r.interpolation&&this.interpolator.init({...r,interpolation:{...this.options.interpolation,...r.interpolation}});const f=Bt(t)&&(((h=r==null?void 0:r.interpolation)==null?void 0:h.skipOnVariables)!==void 0?r.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let m;if(f){const _=t.match(this.interpolator.nestingRegexp);m=_&&_.length;}let g=r.replace&&!Bt(r.replace)?r.replace:r;if(this.options.interpolation.defaultVariables&&(g={...this.options.interpolation.defaultVariables,...g}),t=this.interpolator.interpolate(t,g,r.lng||this.language||o.usedLng,r),f){const _=t.match(this.interpolator.nestingRegexp),b=_&&_.length;m<b&&(r.nest=false);}!r.lng&&o&&o.res&&(r.lng=this.language||o.usedLng),r.nest!==false&&(t=this.interpolator.nest(t,function(){for(var _=arguments.length,b=new Array(_),C=0;C<_;C++)b[C]=arguments[C];return (a==null?void 0:a[0])===b[0]&&!r.context?(i.logger.warn(`It seems you are nesting recursively key: ${b[0]} in key: ${n[0]}`),null):i.translate(...b,n)},r)),r.interpolation&&this.interpolator.reset();}const s=r.postProcess||this.options.postProcess,l=Bt(s)?[s]:s;return t!=null&&(l!=null&&l.length)&&r.applyPostProcessor!==false&&(t=lg.handle(l,t,n,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...o,usedParams:this.getUsedParamsDetails(r)},...r}:r,this)),t}resolve(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r,o,a,i,s;return Bt(t)&&(t=[t]),t.forEach(l=>{if(this.isValidLookup(r))return;const c=this.extractFromKey(l,n),h=c.key;o=h;let f=c.namespaces;this.options.fallbackNS&&(f=f.concat(this.options.fallbackNS));const m=n.count!==void 0&&!Bt(n.count),g=m&&!n.ordinal&&n.count===0,_=n.context!==void 0&&(Bt(n.context)||typeof n.context=="number")&&n.context!=="",b=n.lngs?n.lngs:this.languageUtils.toResolveHierarchy(n.lng||this.language,n.fallbackLng);f.forEach(C=>{var k,T;this.isValidLookup(r)||(s=C,!Lf[`${b[0]}-${C}`]&&((k=this.utils)!=null&&k.hasLoadedNamespace)&&!((T=this.utils)!=null&&T.hasLoadedNamespace(s))&&(Lf[`${b[0]}-${C}`]=true,this.logger.warn(`key "${o}" for languages "${b.join(", ")}" won't get resolved as namespace "${s}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),b.forEach(M=>{var I;if(this.isValidLookup(r))return;i=M;const P=[h];if((I=this.i18nFormat)!=null&&I.addLookupKeys)this.i18nFormat.addLookupKeys(P,h,M,C,n);else {let O;m&&(O=this.pluralResolver.getSuffix(M,n.count,n));const B=`${this.options.pluralSeparator}zero`,D=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(m&&(P.push(h+O),n.ordinal&&O.indexOf(D)===0&&P.push(h+O.replace(D,this.options.pluralSeparator)),g&&P.push(h+B)),_){const v=`${h}${this.options.contextSeparator}${n.context}`;P.push(v),m&&(P.push(v+O),n.ordinal&&O.indexOf(D)===0&&P.push(v+O.replace(D,this.options.pluralSeparator)),g&&P.push(v+B));}}let F;for(;F=P.pop();)this.isValidLookup(r)||(a=F,r=this.getResource(M,C,F,n));}));});}),{res:r,usedKey:o,exactUsedKey:a,usedLng:i,usedNS:s}}isValidLookup(t){return t!==void 0&&!(!this.options.returnNull&&t===null)&&!(!this.options.returnEmptyString&&t==="")}getResource(t,n,r){var a;let o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return (a=this.i18nFormat)!=null&&a.getResource?this.i18nFormat.getResource(t,n,r,o):this.resourceStore.getResource(t,n,r,o)}getUsedParamsDetails(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const n=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],r=t.replace&&!Bt(t.replace);let o=r?t.replace:t;if(r&&typeof t.count<"u"&&(o.count=t.count),this.options.interpolation.defaultVariables&&(o={...this.options.interpolation.defaultVariables,...o}),!r){o={...o};for(const a of n)delete o[a];}return o}static hasDefaultValue(t){const n="defaultValue";for(const r in t)if(Object.prototype.hasOwnProperty.call(t,r)&&n===r.substring(0,n.length)&&t[r]!==void 0)return  true;return  false}}class Bf{constructor(t){this.options=t,this.supportedLngs=this.options.supportedLngs||false,this.logger=Gr.create("languageUtils");}getScriptPartFromCode(t){if(t=cl(t),!t||t.indexOf("-")<0)return null;const n=t.split("-");return n.length===2||(n.pop(),n[n.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(n.join("-"))}getLanguagePartFromCode(t){if(t=cl(t),!t||t.indexOf("-")<0)return t;const n=t.split("-");return this.formatLanguageCode(n[0])}formatLanguageCode(t){if(Bt(t)&&t.indexOf("-")>-1){let n;try{n=Intl.getCanonicalLocales(t)[0];}catch{}return n&&this.options.lowerCaseLng&&(n=n.toLowerCase()),n||(this.options.lowerCaseLng?t.toLowerCase():t)}return this.options.cleanCode||this.options.lowerCaseLng?t.toLowerCase():t}isSupportedCode(t){return (this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(t=this.getLanguagePartFromCode(t)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(t)>-1}getBestMatchFromCodes(t){if(!t)return null;let n;return t.forEach(r=>{if(n)return;const o=this.formatLanguageCode(r);(!this.options.supportedLngs||this.isSupportedCode(o))&&(n=o);}),!n&&this.options.supportedLngs&&t.forEach(r=>{if(n)return;const o=this.getLanguagePartFromCode(r);if(this.isSupportedCode(o))return n=o;n=this.options.supportedLngs.find(a=>{if(a===o)return a;if(!(a.indexOf("-")<0&&o.indexOf("-")<0)&&(a.indexOf("-")>0&&o.indexOf("-")<0&&a.substring(0,a.indexOf("-"))===o||a.indexOf(o)===0&&o.length>1))return a});}),n||(n=this.getFallbackCodes(this.options.fallbackLng)[0]),n}getFallbackCodes(t,n){if(!t)return [];if(typeof t=="function"&&(t=t(n)),Bt(t)&&(t=[t]),Array.isArray(t))return t;if(!n)return t.default||[];let r=t[n];return r||(r=t[this.getScriptPartFromCode(n)]),r||(r=t[this.formatLanguageCode(n)]),r||(r=t[this.getLanguagePartFromCode(n)]),r||(r=t.default),r||[]}toResolveHierarchy(t,n){const r=this.getFallbackCodes(n||this.options.fallbackLng||[],t),o=[],a=i=>{i&&(this.isSupportedCode(i)?o.push(i):this.logger.warn(`rejecting language code not found in supportedLngs: ${i}`));};return Bt(t)&&(t.indexOf("-")>-1||t.indexOf("_")>-1)?(this.options.load!=="languageOnly"&&a(this.formatLanguageCode(t)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&a(this.getScriptPartFromCode(t)),this.options.load!=="currentOnly"&&a(this.getLanguagePartFromCode(t))):Bt(t)&&a(this.formatLanguageCode(t)),r.forEach(i=>{o.indexOf(i)<0&&a(this.formatLanguageCode(i));}),o}}const Uf={zero:0,one:1,two:2,few:3,many:4,other:5},$f={select:e=>e===1?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})};class yb{constructor(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.languageUtils=t,this.options=n,this.logger=Gr.create("pluralResolver"),this.pluralRulesCache={};}addRule(t,n){this.rules[t]=n;}clearCache(){this.pluralRulesCache={};}getRule(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const r=cl(t==="dev"?"en":t),o=n.ordinal?"ordinal":"cardinal",a=JSON.stringify({cleanedCode:r,type:o});if(a in this.pluralRulesCache)return this.pluralRulesCache[a];let i;try{i=new Intl.PluralRules(r,{type:o});}catch{if(!Intl)return this.logger.error("No Intl support, please use an Intl polyfill!"),$f;if(!t.match(/-|_/))return $f;const l=this.languageUtils.getLanguagePartFromCode(t);i=this.getRule(l,n);}return this.pluralRulesCache[a]=i,i}needsPlural(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=this.getRule(t,n);return r||(r=this.getRule("dev",n)),(r==null?void 0:r.resolvedOptions().pluralCategories.length)>1}getPluralFormsOfKey(t,n){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.getSuffixes(t,r).map(o=>`${n}${o}`)}getSuffixes(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=this.getRule(t,n);return r||(r=this.getRule("dev",n)),r?r.resolvedOptions().pluralCategories.sort((o,a)=>Uf[o]-Uf[a]).map(o=>`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:""}${o}`):[]}getSuffix(t,n){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const o=this.getRule(t,r);return o?`${this.options.prepend}${r.ordinal?`ordinal${this.options.prepend}`:""}${o.select(n)}`:(this.logger.warn(`no plural rule found for: ${t}`),this.getSuffix("dev",n,r))}}const Hf=function(e,t,n){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:".",o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:true,a=lb(e,t,n);return !a&&o&&Bt(n)&&(a=Iu(e,n,r),a===void 0&&(a=Iu(t,n,r))),a},xc=e=>e.replace(/\$/g,"$$$$");class _b{constructor(){var n;let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=Gr.create("interpolator"),this.options=t,this.format=((n=t==null?void 0:t.interpolation)==null?void 0:n.format)||(r=>r),this.init(t);}init(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};t.interpolation||(t.interpolation={escapeValue:true});const{escape:n,escapeValue:r,useRawValueToEscape:o,prefix:a,prefixEscaped:i,suffix:s,suffixEscaped:l,formatSeparator:c,unescapeSuffix:h,unescapePrefix:f,nestingPrefix:m,nestingPrefixEscaped:g,nestingSuffix:_,nestingSuffixEscaped:b,nestingOptionsSeparator:C,maxReplaces:k,alwaysFormat:T}=t.interpolation;this.escape=n!==void 0?n:ub,this.escapeValue=r!==void 0?r:true,this.useRawValueToEscape=o!==void 0?o:false,this.prefix=a?Ra(a):i||"{{",this.suffix=s?Ra(s):l||"}}",this.formatSeparator=c||",",this.unescapePrefix=h?"":f||"-",this.unescapeSuffix=this.unescapePrefix?"":h||"",this.nestingPrefix=m?Ra(m):g||Ra("$t("),this.nestingSuffix=_?Ra(_):b||Ra(")"),this.nestingOptionsSeparator=C||",",this.maxReplaces=k||1e3,this.alwaysFormat=T!==void 0?T:false,this.resetRegExp();}reset(){this.options&&this.init(this.options);}resetRegExp(){const t=(n,r)=>(n==null?void 0:n.source)===r?(n.lastIndex=0,n):new RegExp(r,"g");this.regexp=t(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=t(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=t(this.nestingRegexp,`${this.nestingPrefix}(.+?)${this.nestingSuffix}`);}interpolate(t,n,r,o){var g;let a,i,s;const l=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},c=_=>{if(_.indexOf(this.formatSeparator)<0){const T=Hf(n,l,_,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(T,void 0,r,{...o,...n,interpolationkey:_}):T}const b=_.split(this.formatSeparator),C=b.shift().trim(),k=b.join(this.formatSeparator).trim();return this.format(Hf(n,l,C,this.options.keySeparator,this.options.ignoreJSONStructure),k,r,{...o,...n,interpolationkey:C})};this.resetRegExp();const h=(o==null?void 0:o.missingInterpolationHandler)||this.options.missingInterpolationHandler,f=((g=o==null?void 0:o.interpolation)==null?void 0:g.skipOnVariables)!==void 0?o.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return [{regex:this.regexpUnescape,safeValue:_=>xc(_)},{regex:this.regexp,safeValue:_=>this.escapeValue?xc(this.escape(_)):xc(_)}].forEach(_=>{for(s=0;a=_.regex.exec(t);){const b=a[1].trim();if(i=c(b),i===void 0)if(typeof h=="function"){const k=h(t,a,o);i=Bt(k)?k:"";}else if(o&&Object.prototype.hasOwnProperty.call(o,b))i="";else if(f){i=a[0];continue}else this.logger.warn(`missed to pass in variable ${b} for interpolating ${t}`),i="";else !Bt(i)&&!this.useRawValueToEscape&&(i=Af(i));const C=_.safeValue(i);if(t=t.replace(a[0],C),f?(_.regex.lastIndex+=i.length,_.regex.lastIndex-=a[0].length):_.regex.lastIndex=0,s++,s>=this.maxReplaces)break}}),t}nest(t,n){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o,a,i;const s=(l,c)=>{const h=this.nestingOptionsSeparator;if(l.indexOf(h)<0)return l;const f=l.split(new RegExp(`${h}[ ]*{`));let m=`{${f[1]}`;l=f[0],m=this.interpolate(m,i);const g=m.match(/'/g),_=m.match(/"/g);(((g==null?void 0:g.length)??0)%2===0&&!_||_.length%2!==0)&&(m=m.replace(/'/g,'"'));try{i=JSON.parse(m),c&&(i={...c,...i});}catch(b){return this.logger.warn(`failed parsing options string in nesting for key ${l}`,b),`${l}${h}${m}`}return i.defaultValue&&i.defaultValue.indexOf(this.prefix)>-1&&delete i.defaultValue,l};for(;o=this.nestingRegexp.exec(t);){let l=[];i={...r},i=i.replace&&!Bt(i.replace)?i.replace:i,i.applyPostProcessor=false,delete i.defaultValue;let c=false;if(o[0].indexOf(this.formatSeparator)!==-1&&!/{.*}/.test(o[1])){const h=o[1].split(this.formatSeparator).map(f=>f.trim());o[1]=h.shift(),l=h,c=true;}if(a=n(s.call(this,o[1].trim(),i),i),a&&o[0]===t&&!Bt(a))return a;Bt(a)||(a=Af(a)),a||(this.logger.warn(`missed to resolve ${o[1]} for nesting ${t}`),a=""),c&&(a=l.reduce((h,f)=>this.format(h,f,r.lng,{...r,interpolationkey:o[1].trim()}),a.trim())),t=t.replace(o[0],a),this.regexp.lastIndex=0;}return t}}const wb=e=>{let t=e.toLowerCase().trim();const n={};if(e.indexOf("(")>-1){const r=e.split("(");t=r[0].toLowerCase().trim();const o=r[1].substring(0,r[1].length-1);t==="currency"&&o.indexOf(":")<0?n.currency||(n.currency=o.trim()):t==="relativetime"&&o.indexOf(":")<0?n.range||(n.range=o.trim()):o.split(";").forEach(i=>{if(i){const[s,...l]=i.split(":"),c=l.join(":").trim().replace(/^'+|'+$/g,""),h=s.trim();n[h]||(n[h]=c),c==="false"&&(n[h]=false),c==="true"&&(n[h]=true),isNaN(c)||(n[h]=parseInt(c,10));}});}return {formatName:t,formatOptions:n}},Ia=e=>{const t={};return (n,r,o)=>{let a=o;o&&o.interpolationkey&&o.formatParams&&o.formatParams[o.interpolationkey]&&o[o.interpolationkey]&&(a={...a,[o.interpolationkey]:void 0});const i=r+JSON.stringify(a);let s=t[i];return s||(s=e(cl(r),o),t[i]=s),s(n)}};class bb{constructor(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=Gr.create("formatter"),this.options=t,this.formats={number:Ia((n,r)=>{const o=new Intl.NumberFormat(n,{...r});return a=>o.format(a)}),currency:Ia((n,r)=>{const o=new Intl.NumberFormat(n,{...r,style:"currency"});return a=>o.format(a)}),datetime:Ia((n,r)=>{const o=new Intl.DateTimeFormat(n,{...r});return a=>o.format(a)}),relativetime:Ia((n,r)=>{const o=new Intl.RelativeTimeFormat(n,{...r});return a=>o.format(a,r.range||"day")}),list:Ia((n,r)=>{const o=new Intl.ListFormat(n,{...r});return a=>o.format(a)})},this.init(t);}init(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};this.formatSeparator=n.interpolation.formatSeparator||",";}add(t,n){this.formats[t.toLowerCase().trim()]=n;}addCached(t,n){this.formats[t.toLowerCase().trim()]=Ia(n);}format(t,n,r){let o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const a=n.split(this.formatSeparator);if(a.length>1&&a[0].indexOf("(")>1&&a[0].indexOf(")")<0&&a.find(s=>s.indexOf(")")>-1)){const s=a.findIndex(l=>l.indexOf(")")>-1);a[0]=[a[0],...a.splice(1,s)].join(this.formatSeparator);}return a.reduce((s,l)=>{var f;const{formatName:c,formatOptions:h}=wb(l);if(this.formats[c]){let m=s;try{const g=((f=o==null?void 0:o.formatParams)==null?void 0:f[o.interpolationkey])||{},_=g.locale||g.lng||o.locale||o.lng||r;m=this.formats[c](s,_,{...h,...o,...g});}catch(g){this.logger.warn(g);}return m}else this.logger.warn(`there was no format function for ${c}`);return s},t)}}const vb=(e,t)=>{e.pending[t]!==void 0&&(delete e.pending[t],e.pendingCount--);};class kb extends Ul{constructor(t,n,r){var a,i;let o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};super(),this.backend=t,this.store=n,this.services=r,this.languageUtils=r.languageUtils,this.options=o,this.logger=Gr.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=o.maxParallelReads||10,this.readingCalls=0,this.maxRetries=o.maxRetries>=0?o.maxRetries:5,this.retryTimeout=o.retryTimeout>=1?o.retryTimeout:350,this.state={},this.queue=[],(i=(a=this.backend)==null?void 0:a.init)==null||i.call(a,r,o.backend,o);}queueLoad(t,n,r,o){const a={},i={},s={},l={};return t.forEach(c=>{let h=true;n.forEach(f=>{const m=`${c}|${f}`;!r.reload&&this.store.hasResourceBundle(c,f)?this.state[m]=2:this.state[m]<0||(this.state[m]===1?i[m]===void 0&&(i[m]=true):(this.state[m]=1,h=false,i[m]===void 0&&(i[m]=true),a[m]===void 0&&(a[m]=true),l[f]===void 0&&(l[f]=true)));}),h||(s[c]=true);}),(Object.keys(a).length||Object.keys(i).length)&&this.queue.push({pending:i,pendingCount:Object.keys(i).length,loaded:{},errors:[],callback:o}),{toLoad:Object.keys(a),pending:Object.keys(i),toLoadLanguages:Object.keys(s),toLoadNamespaces:Object.keys(l)}}loaded(t,n,r){const o=t.split("|"),a=o[0],i=o[1];n&&this.emit("failedLoading",a,i,n),!n&&r&&this.store.addResourceBundle(a,i,r,void 0,void 0,{skipCopy:true}),this.state[t]=n?-1:2,n&&r&&(this.state[t]=0);const s={};this.queue.forEach(l=>{sb(l.loaded,[a],i),vb(l,t),n&&l.errors.push(n),l.pendingCount===0&&!l.done&&(Object.keys(l.loaded).forEach(c=>{s[c]||(s[c]={});const h=l.loaded[c];h.length&&h.forEach(f=>{s[c][f]===void 0&&(s[c][f]=true);});}),l.done=true,l.errors.length?l.callback(l.errors):l.callback());}),this.emit("loaded",s),this.queue=this.queue.filter(l=>!l.done);}read(t,n,r){let o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,a=arguments.length>4&&arguments[4]!==void 0?arguments[4]:this.retryTimeout,i=arguments.length>5?arguments[5]:void 0;if(!t.length)return i(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:t,ns:n,fcName:r,tried:o,wait:a,callback:i});return}this.readingCalls++;const s=(c,h)=>{if(this.readingCalls--,this.waitingReads.length>0){const f=this.waitingReads.shift();this.read(f.lng,f.ns,f.fcName,f.tried,f.wait,f.callback);}if(c&&h&&o<this.maxRetries){setTimeout(()=>{this.read.call(this,t,n,r,o+1,a*2,i);},a);return}i(c,h);},l=this.backend[r].bind(this.backend);if(l.length===2){try{const c=l(t,n);c&&typeof c.then=="function"?c.then(h=>s(null,h)).catch(s):s(null,c);}catch(c){s(c);}return}return l(t,n,s)}prepareLoading(t,n){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),o&&o();Bt(t)&&(t=this.languageUtils.toResolveHierarchy(t)),Bt(n)&&(n=[n]);const a=this.queueLoad(t,n,r,o);if(!a.toLoad.length)return a.pending.length||o(),null;a.toLoad.forEach(i=>{this.loadOne(i);});}load(t,n,r){this.prepareLoading(t,n,{},r);}reload(t,n,r){this.prepareLoading(t,n,{reload:true},r);}loadOne(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";const r=t.split("|"),o=r[0],a=r[1];this.read(o,a,"read",void 0,void 0,(i,s)=>{i&&this.logger.warn(`${n}loading namespace ${a} for language ${o} failed`,i),!i&&s&&this.logger.log(`${n}loaded namespace ${a} for language ${o}`,s),this.loaded(t,i,s);});}saveMissing(t,n,r,o,a){var l,c,h,f,m;let i=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{},s=arguments.length>6&&arguments[6]!==void 0?arguments[6]:()=>{};if((c=(l=this.services)==null?void 0:l.utils)!=null&&c.hasLoadedNamespace&&!((f=(h=this.services)==null?void 0:h.utils)!=null&&f.hasLoadedNamespace(n))){this.logger.warn(`did not save key "${r}" as the namespace "${n}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");return}if(!(r==null||r==="")){if((m=this.backend)!=null&&m.create){const g={...i,isUpdate:a},_=this.backend.create.bind(this.backend);if(_.length<6)try{let b;_.length===5?b=_(t,n,r,o,g):b=_(t,n,r,o),b&&typeof b.then=="function"?b.then(C=>s(null,C)).catch(s):s(null,b);}catch(b){s(b);}else _(t,n,r,o,s,g);}!t||!t[0]||this.store.addResource(t[0],n,r,o);}}}const jf=()=>({debug:false,initAsync:true,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:false,supportedLngs:false,nonExplicitSupportedLngs:false,load:"all",preload:false,simplifyPluralSuffix:true,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:false,saveMissing:false,updateMissing:false,saveMissingTo:"fallback",saveMissingPlurals:true,missingKeyHandler:false,missingInterpolationHandler:false,postProcess:false,postProcessPassResolved:false,returnNull:false,returnEmptyString:true,returnObjects:false,joinArrays:false,returnedObjectHandler:false,parseMissingKeyHandler:false,appendNamespaceToMissingKey:false,appendNamespaceToCIMode:false,overloadTranslationOptionHandler:e=>{let t={};if(typeof e[1]=="object"&&(t=e[1]),Bt(e[1])&&(t.defaultValue=e[1]),Bt(e[2])&&(t.tDescription=e[2]),typeof e[2]=="object"||typeof e[3]=="object"){const n=e[3]||e[2];Object.keys(n).forEach(r=>{t[r]=n[r];});}return t},interpolation:{escapeValue:true,format:e=>e,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:true}}),qf=e=>{var t,n;return Bt(e.ns)&&(e.ns=[e.ns]),Bt(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),Bt(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),((n=(t=e.supportedLngs)==null?void 0:t.indexOf)==null?void 0:n.call(t,"cimode"))<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),typeof e.initImmediate=="boolean"&&(e.initAsync=e.initImmediate),e},Cs=()=>{},xb=e=>{Object.getOwnPropertyNames(Object.getPrototypeOf(e)).forEach(n=>{typeof e[n]=="function"&&(e[n]=e[n].bind(e));});};class Zi extends Ul{constructor(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0;if(super(),this.options=qf(t),this.services={},this.logger=Gr,this.modules={external:[]},xb(this),n&&!this.isInitialized&&!t.isClone){if(!this.options.initAsync)return this.init(t,n),this;setTimeout(()=>{this.init(t,n);},0);}}init(){var t=this;let n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;this.isInitializing=true,typeof n=="function"&&(r=n,n={}),n.defaultNS==null&&n.ns&&(Bt(n.ns)?n.defaultNS=n.ns:n.ns.indexOf("translation")<0&&(n.defaultNS=n.ns[0]));const o=jf();this.options={...o,...this.options,...qf(n)},this.options.interpolation={...o.interpolation,...this.options.interpolation},n.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=n.keySeparator),n.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=n.nsSeparator);const a=h=>h?typeof h=="function"?new h:h:null;if(!this.options.isClone){this.modules.logger?Gr.init(a(this.modules.logger),this.options):Gr.init(null,this.options);let h;this.modules.formatter?h=this.modules.formatter:h=bb;const f=new Bf(this.options);this.store=new Ff(this.options.resources,this.options);const m=this.services;m.logger=Gr,m.resourceStore=this.store,m.languageUtils=f,m.pluralResolver=new yb(f,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),h&&(!this.options.interpolation.format||this.options.interpolation.format===o.interpolation.format)&&(m.formatter=a(h),m.formatter.init(m,this.options),this.options.interpolation.format=m.formatter.format.bind(m.formatter)),m.interpolator=new _b(this.options),m.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},m.backendConnector=new kb(a(this.modules.backend),m.resourceStore,m,this.options),m.backendConnector.on("*",function(g){for(var _=arguments.length,b=new Array(_>1?_-1:0),C=1;C<_;C++)b[C-1]=arguments[C];t.emit(g,...b);}),this.modules.languageDetector&&(m.languageDetector=a(this.modules.languageDetector),m.languageDetector.init&&m.languageDetector.init(m,this.options.detection,this.options)),this.modules.i18nFormat&&(m.i18nFormat=a(this.modules.i18nFormat),m.i18nFormat.init&&m.i18nFormat.init(this)),this.translator=new ul(this.services,this.options),this.translator.on("*",function(g){for(var _=arguments.length,b=new Array(_>1?_-1:0),C=1;C<_;C++)b[C-1]=arguments[C];t.emit(g,...b);}),this.modules.external.forEach(g=>{g.init&&g.init(this);});}if(this.format=this.options.interpolation.format,r||(r=Cs),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const h=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);h.length>0&&h[0]!=="dev"&&(this.options.lng=h[0]);}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined"),["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(h=>{this[h]=function(){return t.store[h](...arguments)};}),["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(h=>{this[h]=function(){return t.store[h](...arguments),t};});const l=_i(),c=()=>{const h=(f,m)=>{this.isInitializing=false,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=true,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),l.resolve(m),r(f,m);};if(this.languages&&!this.isInitialized)return h(null,this.t.bind(this));this.changeLanguage(this.options.lng,h);};return this.options.resources||!this.options.initAsync?c():setTimeout(c,0),l}loadResources(t){var a,i;let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Cs;const o=Bt(t)?t:this.language;if(typeof t=="function"&&(r=t),!this.options.resources||this.options.partialBundledLanguages){if((o==null?void 0:o.toLowerCase())==="cimode"&&(!this.options.preload||this.options.preload.length===0))return r();const s=[],l=c=>{if(!c||c==="cimode")return;this.services.languageUtils.toResolveHierarchy(c).forEach(f=>{f!=="cimode"&&s.indexOf(f)<0&&s.push(f);});};o?l(o):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(h=>l(h)),(i=(a=this.options.preload)==null?void 0:a.forEach)==null||i.call(a,c=>l(c)),this.services.backendConnector.load(s,this.options.ns,c=>{!c&&!this.resolvedLanguage&&this.language&&this.setResolvedLanguage(this.language),r(c);});}else r(null);}reloadResources(t,n,r){const o=_i();return typeof t=="function"&&(r=t,t=void 0),typeof n=="function"&&(r=n,n=void 0),t||(t=this.languages),n||(n=this.options.ns),r||(r=Cs),this.services.backendConnector.reload(t,n,a=>{o.resolve(),r(a);}),o}use(t){if(!t)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!t.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return t.type==="backend"&&(this.modules.backend=t),(t.type==="logger"||t.log&&t.warn&&t.error)&&(this.modules.logger=t),t.type==="languageDetector"&&(this.modules.languageDetector=t),t.type==="i18nFormat"&&(this.modules.i18nFormat=t),t.type==="postProcessor"&&lg.addPostProcessor(t),t.type==="formatter"&&(this.modules.formatter=t),t.type==="3rdParty"&&this.modules.external.push(t),this}setResolvedLanguage(t){if(!(!t||!this.languages)&&!(["cimode","dev"].indexOf(t)>-1))for(let n=0;n<this.languages.length;n++){const r=this.languages[n];if(!(["cimode","dev"].indexOf(r)>-1)&&this.store.hasLanguageSomeTranslations(r)){this.resolvedLanguage=r;break}}}changeLanguage(t,n){var r=this;this.isLanguageChangingTo=t;const o=_i();this.emit("languageChanging",t);const a=l=>{this.language=l,this.languages=this.services.languageUtils.toResolveHierarchy(l),this.resolvedLanguage=void 0,this.setResolvedLanguage(l);},i=(l,c)=>{c?(a(c),this.translator.changeLanguage(c),this.isLanguageChangingTo=void 0,this.emit("languageChanged",c),this.logger.log("languageChanged",c)):this.isLanguageChangingTo=void 0,o.resolve(function(){return r.t(...arguments)}),n&&n(l,function(){return r.t(...arguments)});},s=l=>{var h,f;!t&&!l&&this.services.languageDetector&&(l=[]);const c=Bt(l)?l:this.services.languageUtils.getBestMatchFromCodes(l);c&&(this.language||a(c),this.translator.language||this.translator.changeLanguage(c),(f=(h=this.services.languageDetector)==null?void 0:h.cacheUserLanguage)==null||f.call(h,c)),this.loadResources(c,m=>{i(m,c);});};return !t&&this.services.languageDetector&&!this.services.languageDetector.async?s(this.services.languageDetector.detect()):!t&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(s):this.services.languageDetector.detect(s):s(t),o}getFixedT(t,n,r){var o=this;const a=function(i,s){let l;if(typeof s!="object"){for(var c=arguments.length,h=new Array(c>2?c-2:0),f=2;f<c;f++)h[f-2]=arguments[f];l=o.options.overloadTranslationOptionHandler([i,s].concat(h));}else l={...s};l.lng=l.lng||a.lng,l.lngs=l.lngs||a.lngs,l.ns=l.ns||a.ns,l.keyPrefix!==""&&(l.keyPrefix=l.keyPrefix||r||a.keyPrefix);const m=o.options.keySeparator||".";let g;return l.keyPrefix&&Array.isArray(i)?g=i.map(_=>`${l.keyPrefix}${m}${_}`):g=l.keyPrefix?`${l.keyPrefix}${m}${i}`:i,o.t(g,l)};return Bt(t)?a.lng=t:a.lngs=t,a.ns=n,a.keyPrefix=r,a}t(){var o;for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return (o=this.translator)==null?void 0:o.translate(...n)}exists(){var o;for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return (o=this.translator)==null?void 0:o.exists(...n)}setDefaultNamespace(t){this.options.defaultNS=t;}hasLoadedNamespace(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),false;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),false;const r=n.lng||this.resolvedLanguage||this.languages[0],o=this.options?this.options.fallbackLng:false,a=this.languages[this.languages.length-1];if(r.toLowerCase()==="cimode")return  true;const i=(s,l)=>{const c=this.services.backendConnector.state[`${s}|${l}`];return c===-1||c===0||c===2};if(n.precheck){const s=n.precheck(this,i);if(s!==void 0)return s}return !!(this.hasResourceBundle(r,t)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||i(r,t)&&(!o||i(a,t)))}loadNamespaces(t,n){const r=_i();return this.options.ns?(Bt(t)&&(t=[t]),t.forEach(o=>{this.options.ns.indexOf(o)<0&&this.options.ns.push(o);}),this.loadResources(o=>{r.resolve(),n&&n(o);}),r):(n&&n(),Promise.resolve())}loadLanguages(t,n){const r=_i();Bt(t)&&(t=[t]);const o=this.options.preload||[],a=t.filter(i=>o.indexOf(i)<0&&this.services.languageUtils.isSupportedCode(i));return a.length?(this.options.preload=o.concat(a),this.loadResources(i=>{r.resolve(),n&&n(i);}),r):(n&&n(),Promise.resolve())}dir(t){var o,a;if(t||(t=this.resolvedLanguage||(((o=this.languages)==null?void 0:o.length)>0?this.languages[0]:this.language)),!t)return "rtl";const n=["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"],r=((a=this.services)==null?void 0:a.languageUtils)||new Bf(jf());return n.indexOf(r.getLanguagePartFromCode(t))>-1||t.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0;return new Zi(t,n)}cloneInstance(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Cs;const r=t.forkResourceStore;r&&delete t.forkResourceStore;const o={...this.options,...t,isClone:true},a=new Zi(o);if((t.debug!==void 0||t.prefix!==void 0)&&(a.logger=a.logger.clone(t)),["store","services","language"].forEach(s=>{a[s]=this[s];}),a.services={...this.services},a.services.utils={hasLoadedNamespace:a.hasLoadedNamespace.bind(a)},r){const s=Object.keys(this.store.data).reduce((l,c)=>(l[c]={...this.store.data[c]},Object.keys(l[c]).reduce((h,f)=>(h[f]={...l[c][f]},h),{})),{});a.store=new Ff(s,o),a.services.resourceStore=a.store;}return a.translator=new ul(a.services,o),a.translator.on("*",function(s){for(var l=arguments.length,c=new Array(l>1?l-1:0),h=1;h<l;h++)c[h-1]=arguments[h];a.emit(s,...c);}),a.init(o,n),a.translator.options=o,a.translator.backendConnector.services.utils={hasLoadedNamespace:a.hasLoadedNamespace.bind(a)},a}toJSON(){return {options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const Pn=Zi.createInstance();Pn.createInstance=Zi.createInstance;Pn.createInstance;Pn.dir;Pn.init;Pn.loadResources;Pn.reloadResources;Pn.use;Pn.changeLanguage;Pn.getFixedT;Pn.t;Pn.exists;Pn.setDefaultNamespace;Pn.hasLoadedNamespace;Pn.loadNamespaces;Pn.loadLanguages;const Sb={exporter:{ID:"ID",Date:"التاريخ",Content:"المحتوى","Show Full Text":"عرض النص الكامل",Media:"الوسائط","Screen Name":"اسم المستخدم","Profile Name":"اسم الملف الشخصي","Profile Image":"صورة الملف الشخصي","User ID":"معرّف المستخدم","Replying To":"ردًا على","RT Source":"مصدر إعادة التغريد","Quote Source":"مصدر الاقتباس","Media Tags":"وسوم الوسائط",Favorites:"المفضلات",Retweets:"إعادات التغريد",Bookmarks:"العلامات المرجعية",Quotes:"الاقتباسات",Replies:"الردود",Views:"المشاهدات",Favorited:"مضاف إلى المفضلة",Retweeted:"أُعيد تغريده",Bookmarked:"مضاف إلى العلامات المرجعية","Bookmark Folder":"مجلد العلامات المرجعية",URL:"URL",Actions:"الإجراءات",Details:"التفاصيل",Description:"الوصف","Profile Banner":"لافتة الملف الشخصي",Followers:"المتابعون",FollowingCount:"عدد المتابَعين",Statuses:"المنشورات",Favourites:"المفضلات",Listed:"مدرج في القوائم",Location:"الموقع",Website:"الموقع الإلكتروني",Birthdate:"تاريخ الميلاد","Verified Type":"نوع التوثيق","Blue Verified":"موثّق Blue",Following:"يتابع","Follows You":"يتابعك","Can DM":"يمكن مراسلته خاصًا",Protected:"محمي","Created At":"تاريخ الإنشاء",Sender:"المرسل",Recipient:"المستلم","Conversation ID":"معرّف المحادثة","Conversation Type":"نوع المحادثة",Data:"البيانات","Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.":"صدّر البيانات الملتقطة كملف JSON/HTML/CSV. قد يستغرق ذلك وقتًا حسب حجم البيانات. لا يتضمن الملف المصدّر ملفات وسائط مثل الصور والفيديو، بل يتضمن عناوين URL فقط.","Data length:":"طول البيانات:","Export scope:":"نطاق التصدير:","All current results":"كل النتائج الحالية","Selected rows":"الصفوف المحددة","Pinned result set":"مجموعة نتائج مثبتة",Query:"الاستعلام",Sort:"الترتيب","Include all metadata:":"تضمين كل البيانات الوصفية:","Export as:":"تصدير كـ:","No data selected.":"لم يتم تحديد بيانات.",Cancel:"إلغاء","Start Export":"بدء التصدير","Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).":"تنزيل وحفظ ملفات الوسائط من البيانات الملتقطة. قد يستغرق ذلك وقتًا حسب حجم البيانات. تشمل الوسائط التي سيتم تنزيلها صور الملفات الشخصية ولافتاتها (للمستخدمين) والصور والفيديوهات (للتغريدات).","For more than 100 media or large files, it is recommended to copy the URLs and download them with an external download manager such as aria2.":"لأكثر من 100 عنصر وسائط أو للملفات الكبيرة، يُوصى بنسخ عناوين URL وتنزيلها بمدير تنزيل خارجي مثل aria2.","Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.":"يستخدم تصدير ZIP في المتصفح الآن تنزيلات متوازية محدودة. للأعمال الكبيرة جدًا وكثيرة الفيديو، يبقى تصدير URL أو aria2 المسار الأكثر أمانًا والأقل استهلاكًا للذاكرة.","Filename template:":"قالب اسم الملف:","Download scheduler":"مجدول التنزيل","Faster defaults are intended for bulk CDN transfer.":"القيم الافتراضية الأسرع مخصصة للنقل الجماعي من CDN.","Start delay (ms)":"تأخير البدء (ms)","Global parallel":"التوازي العام","Per host":"لكل مضيف",Videos:"الفيديوهات",Retries:"إعادة المحاولة","Use aria2 format:":"استخدام تنسيق aria2:","Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2.":"انقر لمزيد من المعلومات. سيكون كل URL في سطر جديد، واسم ملفه في السطر التالي. هذا التنسيق متوافق مع aria2.","Rate limit (ms):":"حد المعدّل (ms):","Media Filter:":"مرشح الوسائط:","File Name":"اسم الملف","Media Type":"نوع الوسائط","Download URL":"رابط التنزيل","No media selected.":"لم يتم تحديد وسائط.","Preview limited to first 250 media items.":"المعاينة محدودة بأول 250 عنصر وسائط.",Zipping:"جارٍ الضغط","Copied!":"تم النسخ!","Copy URLs":"نسخ الروابط","The tweet ID":"معرّف التغريدة","The username of tweet author":"اسم مستخدم كاتب التغريدة","The profile name of tweet author":"اسم ملف كاتب التغريدة الشخصي","The media index in tweet (start from 0)":"فهرس الوسيط في التغريدة (يبدأ من 0)","The order of media in tweet (1/2/3/4)":"ترتيب الوسيط في التغريدة (1/2/3/4)","The post date in YYYYMMDD format":"تاريخ النشر بتنسيق YYYYMMDD","The post time in HHmmss format":"وقت النشر بتنسيق HHmmss","The media type (photo/video/animated_gif)":"نوع الوسيط (photo/video/animated_gif)","The file extension of media (jpg/png/mp4)":"امتداد ملف الوسيط (jpg/png/mp4)","Failed to export media. Open DevTools for more details.":"فشل تصدير الوسائط. افتح DevTools لمزيد من التفاصيل.","Failed to copy media URLs. Open DevTools for more details.":"فشل نسخ روابط الوسائط. افتح DevTools لمزيد من التفاصيل.","filter.photo":"صورة","filter.video":"فيديو","filter.animated_gif":"GIF","filter.retweet":"تضمين إعادة التغريد","loading remaining rows":"جارٍ تحميل الصفوف المتبقية","Bundle ZIP compression:":"ضغط حزمة ZIP:","Fastest / store":"الأسرع / تخزين","Balanced / fast":"متوازن / سريع","Smaller / slower":"أصغر / أبطأ","Cancel Export":"إلغاء التصدير","Export a canonical portable ZIP bundle for sharing/importing.":"تصدير حزمة ZIP قياسية محمولة للمشاركة/الاستيراد.","Export Bundle ZIP":"تصدير حزمة ZIP","Source-backed media":"وسائط مدعومة من المصدر","rows scanned:":"الصفوف المفحوصة:","media URLs:":"عناوين URL للوسائط:",loading:"جارٍ التحميل","Loading media...":"جارٍ تحميل الوسائط..."},common:{"Open Control Panel":"فتح لوحة التحكم","Browse around to capture more data.":"تصفّح لالتقاط مزيد من البيانات.",Settings:"الإعدادات",General:"عام",Theme:"السمة",Language:"اللغة",Debug:"تصحيح الأخطاء","Date Time Format":"تنسيق التاريخ والوقت","Click for more information. This will take effect on both previewer and exported files.":"انقر لمزيد من المعلومات. سيؤثر هذا في المعاينة والملفات المصدّرة.","Use dedicated DB for accounts":"استخدام قاعدة بيانات مخصصة لكل حساب","This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts.":"سينشئ هذا قاعدة بيانات منفصلة لكل حساب Twitter، مما يساعد على تقليل احتمال اختلاط البيانات عند استخدام عدة حسابات.","Local Database":"قاعدة البيانات المحلية","Analyze DB":"تحليل","Export DB":"تصدير","Clear DB":"مسح","Bundle Export":"تصدير حزمة","Bundle Library":"مكتبة الحزم","QC Session":"جلسة فحص الجودة","Diagnostic capture":"التقاط تشخيصي","Diagnostic buffers cleared.":"تم مسح مخازن التشخيص المؤقتة.","Clear Buffers":"مسح المخازن","Preparing...":"جارٍ التحضير...","Preparing diagnostics...":"جارٍ تحضير التشخيصات...","Export QC Diagnostics":"تصدير تشخيصات فحص الجودة","Export Diagnostics Bundle":"تصدير حزمة التشخيص","QC idle.":"فحص الجودة خامل.","Are you sure to clear all data in the database?":"هل أنت متأكد من مسح كل البيانات في قاعدة البيانات؟","Database cleared.":"تم مسح قاعدة البيانات.",Module:"وحدة","Modules (Scroll to see more)":"الوحدات (مرّر لرؤية المزيد)",About:"حول",Version:"الإصدار","Search...":"بحث...","Something went wrong.":"حدث خطأ ما.","Error:":"خطأ:","Captured:":"تم الالتقاط:","Rows per page:":"الصفوف لكل صفحة:","Relation Types":"أنواع العلاقات","Subject Accounts":"الحسابات محلّ العلاقة","Subject User IDs":"معرّفات المستخدمين محلّ العلاقة","Last Observed At":"آخر رصد","A - B of N items":"{{from}} - {{to}} من {{total}} عنصرًا","No data available.":"لا توجد بيانات متاحة.","No media available.":"لا توجد وسائط متاحة.",Clear:"مسح","Bookmark folders":"مجلدات العلامات المرجعية","1 folder selected":"تم اختيار مجلد واحد","{{count}} folders selected":"تم اختيار {{count}} مجلدات","Export Media":"تصدير الوسائط","Export Data":"تصدير البيانات","Export Search History":"تصدير سجل البحث","JSON View":"عرض JSON","Media View":"عرض الوسائط",Bookmarks:"العلامات المرجعية",Tweets:"التغريدات",Users:"المستخدمون","User Tweets":"تغريدات المستخدم","User Media":"وسائط المستخدم","Tweet Details":"تفاصيل التغريدة","Search Timeline":"خطّ البحث الزمني","Home Timeline":"خطّ الصفحة الرئيسية الزمني","List Timeline":"خطّ القائمة الزمني","Community Timeline":"خطّ المجتمع الزمني","Community Members":"أعضاء المجتمع","List Members":"أعضاء القائمة","List Subscribers":"مشتركو القائمة","Direct Messages":"الرسائل الخاصة","Interaction Events":"أحداث التفاعل","Local Search":"بحث محلي","Runtime Logs":"سجلات التشغيل","Bundle Viewer":"عارض الحزم","{{count}} imported bundles":"{{count}} حزم مستوردة","Search indexed tweets with Twitter-style operators":"ابحث في التغريدات المفهرسة باستخدام معاملات شبيهة بـ Twitter","Local Recorder Search":"بحث المسجّل المحلي",Quotes:"الاقتباسات",CommunityMembers:"أعضاء المجتمع",CommunityTimeline:"خطّ المجتمع الزمني",DirectMessages:"الرسائل الخاصة",Followers:"المتابعون",Following:"يتابع",HomeTimeline:"خطّ الصفحة الرئيسية",Likes:"الإعجابات",ListMembers:"أعضاء القائمة",ListSubscribers:"مشتركو القائمة",ListTimeline:"خطّ القائمة",InteractionEvents:"أحداث التفاعل",LocalSearch:"بحث محلي",RawCapture:"التقاط خام",Retweeters:"معيدو التغريد",RetweetersModule:"معيدو التغريد",RuntimeLogs:"سجلات التشغيل",SearchTimeline:"خطّ البحث",TweetIndex:"فهرس التغريدات",TweetDetail:"تفاصيل التغريدة",UserDetail:"تفاصيل المستخدم",UserMedia:"وسائط المستخدم",UserTweets:"تغريدات المستخدم",on:"تشغيل",off:"إيقاف",unknown:"غير معروف",online:"متصل",offline:"غير متصل",leader:"قائد",follower:"تابع",tab:"تبويب",both:"كلاهما",xhr:"xhr",fetch:"fetch",watchdog:"المراقب",all:"الكل",explicit:"صريح",loading:"جارٍ التحميل",complete:"مكتمل",idle:"خامل","api-name":"اسم API","id-only":"ID فقط","theme.system":"النظام","theme.cupcake":"فاتح","theme.dark":"داكن","theme.emerald":"Emerald","theme.cyberpunk":"Cyberpunk","theme.valentine":"Valentine","theme.lofi":"Lo-fi","theme.dracula":"Dracula","theme.cmyk":"CMYK","theme.business":"الأعمال","theme.winter":"الشتاء","Safe mode":"الوضع الآمن","Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture.":"يعطل الالتقاط المعتمد على hooks عند تفعيله. أوقفه للتصفح العادي والالتقاط التشخيصي.","Hook mode":"وضع hook","Controls whether the userscript hooks XHR, fetch, both, or neither.":"يتحكم بما إذا كان userscript يربط XHR أو fetch أو كليهما أو لا شيء.","Repair mode":"وضع الإصلاح","Controls whether hook repair watchdog behavior is active.":"يتحكم فيما إذا كان watchdog إصلاح hooks نشطاً.","{{seconds}}s ago":"قبل {{seconds}} ث","Hooks: {{status}}":"الخطافات:{{status}}","Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})":"الخطافات:xhr {{xhr}}, fetch {{fetch}}, آخر {{url}} ({{age}})","Hooks: xhr {{xhr}}, fetch {{fetch}}":"الخطافات:xhr {{xhr}}, fetch {{fetch}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}":"الوضع: آمن {{safe}}, hook {{hook}}, إصلاح {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}":"الوضع: آمن {{safe}}, hook {{hook}}, إصلاح {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}","raw events: {{total}} | dropped: {{dropped}}":"أحداث raw: {{total}} | مُسقطة: {{dropped}}","spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed":"spool: {{queued}} جارٍ التحميل / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed","spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms":"إسقاطات تجاوز spool: {{drops}} | غير متاح: {{unavailable}} | أقدم معلّق: {{age}}ms","daemon: {{status}}":"الخادم:{{status}}","daemon: {{status}} | last error: {{error}}":"الخادم:{{status}} | آخر خطأ:{{error}}","monitor: {{role}} | leader: {{leader}} | lease: {{lease}}":"المراقب:{{role}} | قائد:{{leader}} | lease:{{lease}}","monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}":"نبضات monitor route/viewport: {{route}}/{{viewport}} | المكبوت route/viewport: {{suppressedRoute}}/{{suppressedViewport}}","Database connected: {{name}}":"قاعدة البيانات متصلة: {{name}}","App options loaded":"تم تحميل خيارات التطبيق",'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)':'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)',"Search help":"Search help","Clear search":"Clear search","Table view":"Table view","Exit fullscreen":"Exit fullscreen",Fullscreen:"Fullscreen","{{view}} is disabled for large source-backed result sets.":"{{view}} is disabled for large source-backed result sets.","{{view}} view - {{status}}":"{{view}} view - {{status}}","{{view}} view":"{{view}} view","loading {{loaded}}/{{total}}":"loading {{loaded}}/{{total}}","loading more {{loaded}}/{{total}}":"loading more {{loaded}}/{{total}}","searching {{matches}}/{{total}}":"searching {{matches}}/{{total}}","matches {{matches}}/{{total}}":"matches {{matches}}/{{total}}","rows {{loaded}}/{{total}}":"rows {{loaded}}/{{total}}","rows {{count}}":"rows {{count}}","buffering...":"buffering...","history {{count}}":"history {{count}}","selected {{count}} ({{mode}})":"selected {{count}} ({{mode}})","rendered {{rendered}}/{{total}} (window {{start}}-{{end}})":"rendered {{rendered}}/{{total}} (window {{start}}-{{end}})","Search Operators":"Search Operators","Query semantics now follow recorder-style precedence:":"Query semantics now follow recorder-style precedence:","with implicit":"with implicit","between adjacent terms.":"between adjacent terms.","search.category.lexical":"Lexical","search.category.identity":"Identity","search.category.metadata":"Metadata","search.category.presence":"Presence","search.category.numeric_date":"Numeric/date","search.category.compatibility":"Compatibility","Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.":"يتوسع النص غير المنظم إلى مطابقات مصطلحات المحتوى مع تعزيز نوافذ العبارات المتجاورة؛ ويتم خفض أولوية الكلمات الشائعة ما لم تكن بين علامتي اقتباس.","Phrase search with optional slop.":"بحث عن عبارة مع سماحية اختيارية.","Boolean operators with standard precedence and parentheses.":"عوامل منطقية بأولوية قياسية وأقواس.","Match the author handle or author id.":"مطابقة اسم المستخدم أو معرّف المؤلف.","Shorthand for an enforced author constraint, equivalent to from:user.":"اختصار لقيد مؤلف إلزامي، مكافئ لـ from:user.","Match reply targets, entity ids, or conversation ids.":"مطابقة أهداف الرد أو معرّفات الكيانات أو معرّفات المحادثات.","Match bookmark folder id or folder name.":"مطابقة معرّف مجلد الإشارات المرجعية أو اسمه.","Match language, route surface, source text, or card name.":"مطابقة اللغة أو سطح المسار أو نص المصدر أو اسم البطاقة.","Match domains or URLs found in tweets.":"مطابقة النطاقات أو عناوين URL الموجودة في التغريدات.","Boolean state filters.":"مرشحات حالة منطقية.","Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.":"مرشحات وجود للوسائط والروابط والإشارات والوسوم ورموز الأسهم والتفاعل والاستطلاعات.","Compatibility aliases retained for Twitter-style queries.":"أسماء توافقية محفوظة لاستعلامات بأسلوب Twitter.","Numeric threshold filters.":"مرشحات عتبات رقمية.","Date, timestamp, and Snowflake-style boundary filters.":"مرشحات حدود للتاريخ والطابع الزمني ونمط Snowflake.","Explicit mention filter plus shorthand hashtag and cashtag filters.":"مرشح إشارة صريح مع اختصارات وسم ورمز سهم.","Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.":"بحث لفظي محدود بالحقل عبر مسارات متداخلة خام، بما في ذلك مسارات الكائنات المنقطة والمصفوفات.","loading source {{scanned}}/{{total}}":"loading source {{scanned}}/{{total}}","source {{status}} {{scanned}}/{{total}}":"source {{status}} {{scanned}}/{{total}}","media {{count}}":"media {{count}}","loaded media {{count}}":"loaded media {{count}}","source rows {{scanned}}/{{total}} {{status}}":"source rows {{scanned}}/{{total}} {{status}}","source rows {{count}}":"source rows {{count}}","layout {{columns}} cols @ {{width}}px":"layout {{columns}} cols @ {{width}}px","original tweet attachments only":"original tweet attachments only","Loading media.":"Loading media.","Comfortable density":"Comfortable density","Compact density":"Compact density",Photo:"Photo",Video:"Video","Open tweet":"Open tweet","Export menu is open while remaining rows load in the background.":"Export menu is open while remaining rows load in the background.","Wait for records to finish loading before exporting.":"Wait for records to finish loading before exporting.","Exports stream from the active source without loading all rows into the table.":"Exports stream from the active source without loading all rows into the table.","Opens immediately and loads remaining rows in the background.":"Opens immediately and loads remaining rows in the background.","Export persisted bookmark search history":"Export persisted bookmark search history","latest: {{latest}}\napi-name: {{apiName}}\nid-only: {{idOnly}}\nnone: {{none}}":`latest: {{latest}}
api-name: {{apiName}}
id-only: {{idOnly}}
none: {{none}}`,"folder metadata: {{status}}":"folder metadata: {{status}}","Media export is disabled for large result sets until media export has a source-backed stream.":"Media export is disabled for large result sets until media export has a source-backed stream.","App options migrated from v{{oldVersion}} to v{{newVersion}}":"تم ترحيل خيارات التطبيق من v{{oldVersion}} إلى v{{newVersion}}","Hooked into fetch":"Hook في fetch","Hooked into XMLHttpRequest (installed={{installed}})":"Hook في XMLHttpRequest (installed={{installed}})","Hook safe mode enabled ({{reason}})":"تم تفعيل الوضع الآمن للـ hook ({{reason}})","Hook repair failed ({{failures}}/{{limit}})":"فشل إصلاح hook ({{failures}}/{{limit}})","Bookmark context tracking install failed; continuing without tracker ({{details}})":"فشل تثبيت تتبع سياق الإشارات؛ المتابعة بدون متتبع ({{details}})","TWE_DIAG {{phase}}":"TWE_DIAG {{phase}}","{{module}}: {{count}} items received":"{{module}}: تم استلام {{count}} عنصر","Exporting to ZIP file: {{filename}}":"تصدير إلى ملف ZIP: {{filename}}","Exporting to {{format}} file: {{filename}}":"تصدير إلى ملف {{format}}: {{filename}}","Streaming export to {{format}} file: {{filename}}":"تصدير تدفقي إلى ملف {{format}}: {{filename}}","Migration completed: {{users}} users and {{tweets}} tweets updated.":"اكتمل الترحيل: تم تحديث {{users}} مستخدمين و {{tweets}} تغريدات.","TweetTombstone received (Reason: {{reason}})":"تم استلام TweetTombstone (السبب: {{reason}})","Failed to hook into XMLHttpRequest":"فشل hook في XMLHttpRequest","Fetch API not found, skipping fetch hooks":"لم يتم العثور على Fetch API، يتم تخطي hooks الخاصة بـ fetch","Fetch API base function unavailable or unsafe; enabling safe mode":"دالة Fetch API الأساسية غير متاحة أو غير آمنة؛ تفعيل الوضع الآمن","Fetch hook base invocation failed; enabling safe mode":"فشل استدعاء hook fetch الأساسي؛ تفعيل الوضع الآمن","XHR send hook base invocation failed; enabling safe mode":"فشل استدعاء hook XHR send الأساسي؛ تفعيل الوضع الآمن","XHR open hook base invocation failed; enabling safe mode":"فشل استدعاء hook XHR open الأساسي؛ تفعيل الوضع الآمن","Fetch hook already installed":"hook الخاص بـ fetch مثبت بالفعل","Debug mode enabled":"تم تفعيل وضع التصحيح","Database cleared":"تم مسح قاعدة البيانات","Upgrading database schema...":"جارٍ ترقية مخطط قاعدة البيانات...","Database upgraded":"تمت ترقية قاعدة البيانات","Zip stream closed.":"تم إغلاق تدفق ZIP.","Running migration_20250609: Migrating legacy user data format":"تشغيل migration_20250609: ترحيل تنسيق بيانات المستخدم القديم","TweetUnavailable received (Reason: unknown)":"تم استلام TweetUnavailable (السبب: غير معروف)","Empty tweet received":"تم استلام تغريدة فارغة","Unknown tweet type received":"تم استلام نوع تغريدة غير معروف","Failed to extract tweet":"فشل استخراج التغريدة","Failed to export file":"فشل تصدير الملف","Failed to stream export file":"فشل تصدير الملف بالتدفق"}},Cb={exporter:{ID:"ID",Date:"তারিখ",Content:"বিষয়বস্তু","Show Full Text":"সম্পূর্ণ লেখা দেখান",Media:"মিডিয়া","Screen Name":"ব্যবহারকারীর নাম","Profile Name":"প্রোফাইল নাম","Profile Image":"প্রোফাইল ছবি","User ID":"ব্যবহারকারী ID","Replying To":"যার উত্তরে","RT Source":"RT উৎস","Quote Source":"কোট উৎস","Media Tags":"মিডিয়া ট্যাগ",Favorites:"প্রিয়",Retweets:"রিটুইট",Bookmarks:"বুকমার্ক",Quotes:"কোট",Replies:"উত্তর",Views:"দেখা",Favorited:"প্রিয় করা হয়েছে",Retweeted:"রিটুইট করা হয়েছে",Bookmarked:"বুকমার্ক করা হয়েছে","Bookmark Folder":"বুকমার্ক ফোল্ডার",URL:"URL",Actions:"ক্রিয়া",Details:"বিস্তারিত",Description:"বিবরণ","Profile Banner":"প্রোফাইল ব্যানার",Followers:"ফলোয়ার",FollowingCount:"ফলো করা সংখ্যা",Statuses:"পোস্ট",Favourites:"প্রিয়",Listed:"লিস্টে আছে",Location:"অবস্থান",Website:"ওয়েবসাইট",Birthdate:"জন্মতারিখ","Verified Type":"যাচাইকরণ ধরন","Blue Verified":"Blue যাচাইকৃত",Following:"ফলো করছে","Follows You":"আপনাকে ফলো করে","Can DM":"DM করা যায়",Protected:"সুরক্ষিত","Created At":"তৈরি হয়েছে",Sender:"প্রেরক",Recipient:"প্রাপক","Conversation ID":"কথোপকথন ID","Conversation Type":"কথোপকথনের ধরন",Data:"ডেটা","Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.":"ক্যাপচার করা ডেটা JSON/HTML/CSV ফাইল হিসেবে এক্সপোর্ট করুন। ডেটার পরিমাণ অনুযায়ী সময় লাগতে পারে। এক্সপোর্ট করা ফাইলে ছবি বা ভিডিওর মতো মিডিয়া ফাইল থাকবে না, শুধু URL থাকবে।","Data length:":"ডেটার দৈর্ঘ্য:","Export scope:":"এক্সপোর্ট পরিসর:","All current results":"বর্তমান সব ফলাফল","Selected rows":"নির্বাচিত সারি","Pinned result set":"পিন করা ফলাফল সেট",Query:"কোয়েরি",Sort:"সাজানো","Include all metadata:":"সব মেটাডেটা অন্তর্ভুক্ত করুন:","Export as:":"যে রূপে এক্সপোর্ট:","No data selected.":"কোনো ডেটা নির্বাচিত নয়।",Cancel:"বাতিল","Start Export":"এক্সপোর্ট শুরু করুন","Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).":"ক্যাপচার করা ডেটা থেকে মিডিয়া ফাইল ডাউনলোড ও সংরক্ষণ করুন। ডেটার পরিমাণ অনুযায়ী সময় লাগতে পারে। ডাউনলোড হবে: প্রোফাইল ছবি, প্রোফাইল ব্যানার (ব্যবহারকারীর জন্য), ছবি ও ভিডিও (টুইটের জন্য)।","For more than 100 media or large files, it is recommended to copy the URLs and download them with an external download manager such as aria2.":"১০০টির বেশি মিডিয়া বা বড় ফাইলের জন্য URL কপি করে aria2-এর মতো বাহ্যিক ডাউনলোড ম্যানেজার দিয়ে ডাউনলোড করার পরামর্শ দেওয়া হয়।","Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.":"ব্রাউজার ZIP এক্সপোর্ট এখন সীমিত সমান্তরাল ডাউনলোড ব্যবহার করে। খুব বড় ভিডিও-ভিত্তিক কাজের জন্য URL বা aria2 এক্সপোর্ট এখনও কম-মেমরির সবচেয়ে নিরাপদ পথ।","Filename template:":"ফাইলনাম টেমপ্লেট:","Download scheduler":"ডাউনলোড শিডিউলার","Faster defaults are intended for bulk CDN transfer.":"দ্রুততর ডিফল্টগুলো বড় CDN ট্রান্সফারের জন্য।","Start delay (ms)":"শুরুর বিলম্ব (ms)","Global parallel":"গ্লোবাল সমান্তরাল","Per host":"প্রতি হোস্ট",Videos:"ভিডিও",Retries:"পুনঃচেষ্টা","Use aria2 format:":"aria2 ফরম্যাট ব্যবহার করুন:","Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2.":"আরও তথ্যের জন্য ক্লিক করুন। প্রতিটি URL নতুন লাইনে থাকবে, আর পরের লাইনে তার ফাইলনাম থাকবে। এই ফরম্যাট aria2-এর সঙ্গে সামঞ্জস্যপূর্ণ।","Rate limit (ms):":"রেট সীমা (ms):","Media Filter:":"মিডিয়া ফিল্টার:","File Name":"ফাইলনাম","Media Type":"মিডিয়ার ধরন","Download URL":"ডাউনলোড URL","No media selected.":"কোনো মিডিয়া নির্বাচিত নয়।","Preview limited to first 250 media items.":"প্রিভিউ প্রথম ২৫০টি মিডিয়া আইটেমে সীমিত।",Zipping:"ZIP করা হচ্ছে","Copied!":"কপি হয়েছে!","Copy URLs":"URL কপি করুন","The tweet ID":"টুইট ID","The username of tweet author":"টুইট লেখকের ব্যবহারকারীর নাম","The profile name of tweet author":"টুইট লেখকের প্রোফাইল নাম","The media index in tweet (start from 0)":"টুইটে মিডিয়ার ইনডেক্স (০ থেকে শুরু)","The order of media in tweet (1/2/3/4)":"টুইটে মিডিয়ার ক্রম (1/2/3/4)","The post date in YYYYMMDD format":"YYYYMMDD ফরম্যাটে পোস্টের তারিখ","The post time in HHmmss format":"HHmmss ফরম্যাটে পোস্টের সময়","The media type (photo/video/animated_gif)":"মিডিয়ার ধরন (photo/video/animated_gif)","The file extension of media (jpg/png/mp4)":"মিডিয়া ফাইল এক্সটেনশন (jpg/png/mp4)","Failed to export media. Open DevTools for more details.":"মিডিয়া এক্সপোর্ট ব্যর্থ। আরও জানতে DevTools খুলুন।","Failed to copy media URLs. Open DevTools for more details.":"মিডিয়া URL কপি ব্যর্থ। আরও জানতে DevTools খুলুন।","filter.photo":"ছবি","filter.video":"ভিডিও","filter.animated_gif":"GIF","filter.retweet":"রিটুইট অন্তর্ভুক্ত করুন","loading remaining rows":"বাকি সারি লোড হচ্ছে","Bundle ZIP compression:":"Bundle ZIP কমপ্রেশন:","Fastest / store":"সবচেয়ে দ্রুত / store","Balanced / fast":"সামঞ্জস্যপূর্ণ / দ্রুত","Smaller / slower":"ছোট / ধীর","Cancel Export":"রপ্তানি বাতিল","Export a canonical portable ZIP bundle for sharing/importing.":"শেয়ার/ইমপোর্টের জন্য canonical portable ZIP bundle রপ্তানি করুন।","Export Bundle ZIP":"Bundle ZIP রপ্তানি","Source-backed media":"Source-backed মিডিয়া","rows scanned:":"স্ক্যান করা সারি:","media URLs:":"মিডিয়া URL:",loading:"লোড হচ্ছে","Loading media...":"মিডিয়া লোড হচ্ছে..."},common:{"Open Control Panel":"কন্ট্রোল প্যানেল খুলুন","Browse around to capture more data.":"আরও ডেটা ক্যাপচার করতে ব্রাউজ করুন।",Settings:"সেটিংস",General:"সাধারণ",Theme:"থিম",Language:"ভাষা",Debug:"ডিবাগ","Date Time Format":"তারিখ-সময় বিন্যাস","Click for more information. This will take effect on both previewer and exported files.":"আরও তথ্যের জন্য ক্লিক করুন। এটি প্রিভিউয়ার এবং এক্সপোর্ট করা ফাইল—দুটিতেই প্রযোজ্য হবে।","Use dedicated DB for accounts":"প্রতিটি অ্যাকাউন্টের জন্য আলাদা DB ব্যবহার করুন","This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts.":"এটি প্রতিটি Twitter অ্যাকাউন্টের জন্য আলাদা ডেটাবেস তৈরি করবে, ফলে একাধিক অ্যাকাউন্ট ব্যবহার করার সময় ডেটা মিশে যাওয়ার ঝুঁকি কমে।","Local Database":"স্থানীয় ডেটাবেস","Analyze DB":"বিশ্লেষণ","Export DB":"এক্সপোর্ট","Clear DB":"মুছুন","Bundle Export":"বান্ডল এক্সপোর্ট","Bundle Library":"বান্ডল লাইব্রেরি","QC Session":"QC সেশন","Diagnostic capture":"ডায়াগনস্টিক ক্যাপচার","Diagnostic buffers cleared.":"ডায়াগনস্টিক বাফার মুছে ফেলা হয়েছে।","Clear Buffers":"বাফার মুছুন","Preparing...":"প্রস্তুত হচ্ছে...","Preparing diagnostics...":"ডায়াগনস্টিক প্রস্তুত হচ্ছে...","Export QC Diagnostics":"QC ডায়াগনস্টিক এক্সপোর্ট","Export Diagnostics Bundle":"ডায়াগনস্টিক বান্ডল এক্সপোর্ট","QC idle.":"QC নিষ্ক্রিয়।","Are you sure to clear all data in the database?":"আপনি কি নিশ্চিত যে ডেটাবেসের সব ডেটা মুছে ফেলতে চান?","Database cleared.":"ডেটাবেস মুছে ফেলা হয়েছে।",Module:"মডিউল","Modules (Scroll to see more)":"মডিউল (আরও দেখতে স্ক্রল করুন)",About:"সম্পর্কে",Version:"সংস্করণ","Search...":"খুঁজুন...","Something went wrong.":"কিছু ভুল হয়েছে।","Error:":"ত্রুটি:","Captured:":"ক্যাপচার করা হয়েছে:","Rows per page:":"প্রতি পৃষ্ঠায় সারি:","Relation Types":"সম্পর্কের ধরন","Subject Accounts":"বিষয় অ্যাকাউন্ট","Subject User IDs":"বিষয় ব্যবহারকারী ID","Last Observed At":"শেষ পর্যবেক্ষণ","A - B of N items":"{{total}}টির মধ্যে {{from}} - {{to}}","No data available.":"কোনো ডেটা নেই।","No media available.":"কোনো মিডিয়া নেই।",Clear:"সাফ করুন","Bookmark folders":"বুকমার্ক ফোল্ডার","1 folder selected":"১টি ফোল্ডার নির্বাচিত","{{count}} folders selected":"{{count}}টি ফোল্ডার নির্বাচিত","Export Media":"মিডিয়া এক্সপোর্ট","Export Data":"ডেটা এক্সপোর্ট","Export Search History":"সার্চ ইতিহাস এক্সপোর্ট","JSON View":"JSON ভিউ","Media View":"মিডিয়া ভিউ",Bookmarks:"বুকমার্ক",Tweets:"টুইট",Users:"ব্যবহারকারী","User Tweets":"ব্যবহারকারীর টুইট","User Media":"ব্যবহারকারীর মিডিয়া","Tweet Details":"টুইটের বিবরণ","Search Timeline":"সার্চ টাইমলাইন","Home Timeline":"হোম টাইমলাইন","List Timeline":"লিস্ট টাইমলাইন","Community Timeline":"কমিউনিটি টাইমলাইন","Community Members":"কমিউনিটি সদস্য","List Members":"লিস্ট সদস্য","List Subscribers":"লিস্ট সাবস্ক্রাইবার","Direct Messages":"ডাইরেক্ট মেসেজ","Interaction Events":"ইন্টারঅ্যাকশন ইভেন্ট","Local Search":"স্থানীয় সার্চ","Runtime Logs":"রানটাইম লগ","Bundle Viewer":"বান্ডল ভিউয়ার","{{count}} imported bundles":"{{count}}টি আমদানি করা বান্ডল","Search indexed tweets with Twitter-style operators":"Twitter-ধাঁচের অপারেটর দিয়ে ইনডেক্স করা টুইট খুঁজুন","Local Recorder Search":"লোকাল রেকর্ডার সার্চ",Quotes:"কোট",CommunityMembers:"কমিউনিটি সদস্য",CommunityTimeline:"কমিউনিটি টাইমলাইন",DirectMessages:"ডাইরেক্ট মেসেজ",Followers:"ফলোয়ার",Following:"ফলো করছে",HomeTimeline:"হোম টাইমলাইন",Likes:"লাইক",ListMembers:"লিস্ট সদস্য",ListSubscribers:"লিস্ট সাবস্ক্রাইবার",ListTimeline:"লিস্ট টাইমলাইন",InteractionEvents:"ইন্টারঅ্যাকশন ইভেন্ট",LocalSearch:"স্থানীয় সার্চ",RawCapture:"কাঁচা ক্যাপচার",Retweeters:"রিটুইটকারী",RetweetersModule:"রিটুইটকারী",RuntimeLogs:"রানটাইম লগ",SearchTimeline:"সার্চ টাইমলাইন",TweetIndex:"টুইট ইনডেক্স",TweetDetail:"টুইট বিবরণ",UserDetail:"ব্যবহারকারী বিবরণ",UserMedia:"ব্যবহারকারীর মিডিয়া",UserTweets:"ব্যবহারকারীর টুইট",on:"চালু",off:"বন্ধ",unknown:"অজানা",online:"অনলাইন",offline:"অফলাইন",leader:"লিডার",follower:"ফলোয়ার",tab:"ট্যাব",both:"উভয়",xhr:"xhr",fetch:"fetch",watchdog:"ওয়াচডগ",all:"সব",explicit:"স্পষ্ট",loading:"লোড হচ্ছে",complete:"সম্পূর্ণ",idle:"নিষ্ক্রিয়","api-name":"API নাম","id-only":"শুধু ID","theme.system":"সিস্টেম","theme.cupcake":"হালকা","theme.dark":"গাঢ়","theme.emerald":"Emerald","theme.cyberpunk":"Cyberpunk","theme.valentine":"Valentine","theme.lofi":"Lo-fi","theme.dracula":"Dracula","theme.cmyk":"CMYK","theme.business":"ব্যবসা","theme.winter":"শীত","Safe mode":"সেফ মোড","Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture.":"সক্রিয় থাকলে hook-ভিত্তিক ক্যাপচার বন্ধ করে। স্বাভাবিক ব্রাউজিং ও ডায়াগনস্টিক ক্যাপচারের জন্য এটি বন্ধ করুন।","Hook mode":"Hook মোড","Controls whether the userscript hooks XHR, fetch, both, or neither.":"userscript XHR, fetch, দুটোই বা কোনোটাই hook করবে কি না তা নিয়ন্ত্রণ করে।","Repair mode":"মেরামত মোড","Controls whether hook repair watchdog behavior is active.":"hook repair watchdog সক্রিয় থাকবে কি না তা নিয়ন্ত্রণ করে।","{{seconds}}s ago":"{{seconds}} সেকেন্ড আগে","Hooks: {{status}}":"হুকসমূহ:{{status}}","Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})":"হুকসমূহ:xhr {{xhr}}, fetch {{fetch}}, শেষ {{url}} ({{age}})","Hooks: xhr {{xhr}}, fetch {{fetch}}":"হুকসমূহ:xhr {{xhr}}, fetch {{fetch}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}":"মোড: সেফ {{safe}}, hook {{hook}}, মেরামত {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}":"মোড: সেফ {{safe}}, hook {{hook}}, মেরামত {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}","raw events: {{total}} | dropped: {{dropped}}":"raw ইভেন্ট: {{total}} | বাদ: {{dropped}}","spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed":"spool: {{queued}} লোড হচ্ছে / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed","spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms":"spool overflow বাদ: {{drops}} | অনুপলব্ধ: {{unavailable}} | সবচেয়ে পুরনো pending: {{age}}ms","daemon: {{status}}":"ডেমন:{{status}}","daemon: {{status}} | last error: {{error}}":"ডেমন:{{status}} | শেষ ত্রুটি:{{error}}","monitor: {{role}} | leader: {{leader}} | lease: {{lease}}":"মনিটর:{{role}} | লিডার:{{leader}} | lease:{{lease}}","monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}":"monitor ticks route/viewport: {{route}}/{{viewport}} | দমন করা route/viewport: {{suppressedRoute}}/{{suppressedViewport}}","Database connected: {{name}}":"ডাটাবেস সংযুক্ত: {{name}}","App options loaded":"অ্যাপ অপশন লোড হয়েছে",'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)':'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)',"Search help":"Search help","Clear search":"Clear search","Table view":"Table view","Exit fullscreen":"Exit fullscreen",Fullscreen:"Fullscreen","{{view}} is disabled for large source-backed result sets.":"{{view}} is disabled for large source-backed result sets.","{{view}} view - {{status}}":"{{view}} view - {{status}}","{{view}} view":"{{view}} view","loading {{loaded}}/{{total}}":"loading {{loaded}}/{{total}}","loading more {{loaded}}/{{total}}":"loading more {{loaded}}/{{total}}","searching {{matches}}/{{total}}":"searching {{matches}}/{{total}}","matches {{matches}}/{{total}}":"matches {{matches}}/{{total}}","rows {{loaded}}/{{total}}":"rows {{loaded}}/{{total}}","rows {{count}}":"rows {{count}}","buffering...":"buffering...","history {{count}}":"history {{count}}","selected {{count}} ({{mode}})":"selected {{count}} ({{mode}})","rendered {{rendered}}/{{total}} (window {{start}}-{{end}})":"rendered {{rendered}}/{{total}} (window {{start}}-{{end}})","Search Operators":"Search Operators","Query semantics now follow recorder-style precedence:":"Query semantics now follow recorder-style precedence:","with implicit":"with implicit","between adjacent terms.":"between adjacent terms.","search.category.lexical":"Lexical","search.category.identity":"Identity","search.category.metadata":"Metadata","search.category.presence":"Presence","search.category.numeric_date":"Numeric/date","search.category.compatibility":"Compatibility","Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.":"অগঠিত টেক্সট কনটেন্ট-টার্ম মিল এবং উন্নত সংলগ্ন বাক্যাংশ উইন্ডোতে প্রসারিত হয়; উদ্ধৃত না থাকলে সাধারণ ফিলার শব্দের অগ্রাধিকার কমানো হয়।","Phrase search with optional slop.":"ঐচ্ছিক স্লপসহ বাক্যাংশ অনুসন্ধান।","Boolean operators with standard precedence and parentheses.":"স্ট্যান্ডার্ড অগ্রাধিকার ও বন্ধনীসহ বুলিয়ান অপারেটর।","Match the author handle or author id.":"লেখকের হ্যান্ডেল বা লেখক ID মিলান।","Shorthand for an enforced author constraint, equivalent to from:user.":"বাধ্যতামূলক লেখক সীমাবদ্ধতার সংক্ষিপ্ত রূপ, from:user-এর সমতুল্য।","Match reply targets, entity ids, or conversation ids.":"রিপ্লাই টার্গেট, এন্টিটি ID বা কথোপকথন ID মিলান।","Match bookmark folder id or folder name.":"বুকমার্ক ফোল্ডার ID বা নাম মিলান।","Match language, route surface, source text, or card name.":"ভাষা, রুট সারফেস, সোর্স টেক্সট বা কার্ড নাম মিলান।","Match domains or URLs found in tweets.":"টুইটে থাকা ডোমেইন বা URL মিলান।","Boolean state filters.":"বুলিয়ান অবস্থা ফিল্টার।","Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.":"মিডিয়া, লিংক, মেনশন, হ্যাশট্যাগ, ক্যাশট্যাগ, এনগেজমেন্ট ও পোলের উপস্থিতি ফিল্টার।","Compatibility aliases retained for Twitter-style queries.":"Twitter-ধাঁচের কোয়েরির জন্য রাখা সামঞ্জস্যপূর্ণ alias।","Numeric threshold filters.":"সংখ্যাগত থ্রেশহোল্ড ফিল্টার।","Date, timestamp, and Snowflake-style boundary filters.":"তারিখ, টাইমস্ট্যাম্প ও Snowflake-ধাঁচের সীমা ফিল্টার।","Explicit mention filter plus shorthand hashtag and cashtag filters.":"স্পষ্ট মেনশন ফিল্টার এবং সংক্ষিপ্ত হ্যাশট্যাগ ও ক্যাশট্যাগ ফিল্টার।","Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.":"ডটেড অবজেক্ট পাথ ও অ্যারে সহ কাঁচা নেস্টেড পাথে ফিল্ড-স্কোপড শব্দভিত্তিক অনুসন্ধান।","loading source {{scanned}}/{{total}}":"loading source {{scanned}}/{{total}}","source {{status}} {{scanned}}/{{total}}":"source {{status}} {{scanned}}/{{total}}","media {{count}}":"media {{count}}","loaded media {{count}}":"loaded media {{count}}","source rows {{scanned}}/{{total}} {{status}}":"source rows {{scanned}}/{{total}} {{status}}","source rows {{count}}":"source rows {{count}}","layout {{columns}} cols @ {{width}}px":"layout {{columns}} cols @ {{width}}px","original tweet attachments only":"original tweet attachments only","Loading media.":"Loading media.","Comfortable density":"Comfortable density","Compact density":"Compact density",Photo:"Photo",Video:"Video","Open tweet":"Open tweet","Export menu is open while remaining rows load in the background.":"Export menu is open while remaining rows load in the background.","Wait for records to finish loading before exporting.":"Wait for records to finish loading before exporting.","Exports stream from the active source without loading all rows into the table.":"Exports stream from the active source without loading all rows into the table.","Opens immediately and loads remaining rows in the background.":"Opens immediately and loads remaining rows in the background.","Export persisted bookmark search history":"Export persisted bookmark search history","latest: {{latest}}\napi-name: {{apiName}}\nid-only: {{idOnly}}\nnone: {{none}}":`latest: {{latest}}
api-name: {{apiName}}
id-only: {{idOnly}}
none: {{none}}`,"folder metadata: {{status}}":"folder metadata: {{status}}","Media export is disabled for large result sets until media export has a source-backed stream.":"Media export is disabled for large result sets until media export has a source-backed stream.","App options migrated from v{{oldVersion}} to v{{newVersion}}":"অ্যাপ অপশন v{{oldVersion}} থেকে v{{newVersion}}-এ মাইগ্রেট হয়েছে","Hooked into fetch":"fetch-এ hook করা হয়েছে","Hooked into XMLHttpRequest (installed={{installed}})":"XMLHttpRequest-এ hook করা হয়েছে (installed={{installed}})","Hook safe mode enabled ({{reason}})":"Hook safe mode সক্রিয় ({{reason}})","Hook repair failed ({{failures}}/{{limit}})":"Hook মেরামত ব্যর্থ ({{failures}}/{{limit}})","Bookmark context tracking install failed; continuing without tracker ({{details}})":"Bookmark context tracking ইনস্টল ব্যর্থ; tracker ছাড়া চলবে ({{details}})","TWE_DIAG {{phase}}":"TWE_DIAG {{phase}}","{{module}}: {{count}} items received":"{{module}}: {{count}} আইটেম পাওয়া গেছে","Exporting to ZIP file: {{filename}}":"ZIP ফাইলে রপ্তানি: {{filename}}","Exporting to {{format}} file: {{filename}}":"{{format}} ফাইলে রপ্তানি: {{filename}}","Streaming export to {{format}} file: {{filename}}":"{{format}} ফাইলে streaming রপ্তানি: {{filename}}","Migration completed: {{users}} users and {{tweets}} tweets updated.":"মাইগ্রেশন সম্পন্ন: {{users}} ব্যবহারকারী ও {{tweets}} টুইট আপডেট হয়েছে।","TweetTombstone received (Reason: {{reason}})":"TweetTombstone পাওয়া গেছে (কারণ: {{reason}})","Failed to hook into XMLHttpRequest":"XMLHttpRequest hook করতে ব্যর্থ","Fetch API not found, skipping fetch hooks":"Fetch API পাওয়া যায়নি, fetch hooks এড়িয়ে যাওয়া হচ্ছে","Fetch API base function unavailable or unsafe; enabling safe mode":"Fetch API base function অনুপলব্ধ বা অনিরাপদ; safe mode চালু হচ্ছে","Fetch hook base invocation failed; enabling safe mode":"Fetch hook base invocation ব্যর্থ; safe mode চালু হচ্ছে","XHR send hook base invocation failed; enabling safe mode":"XHR send hook base invocation ব্যর্থ; safe mode চালু হচ্ছে","XHR open hook base invocation failed; enabling safe mode":"XHR open hook base invocation ব্যর্থ; safe mode চালু হচ্ছে","Fetch hook already installed":"Fetch hook ইতিমধ্যে ইনস্টল করা","Debug mode enabled":"Debug mode সক্রিয়","Database cleared":"ডাটাবেস পরিষ্কার হয়েছে","Upgrading database schema...":"ডাটাবেস schema আপগ্রেড হচ্ছে...","Database upgraded":"ডাটাবেস আপগ্রেড হয়েছে","Zip stream closed.":"ZIP stream বন্ধ হয়েছে।","Running migration_20250609: Migrating legacy user data format":"migration_20250609 চলছে: legacy user data format মাইগ্রেট হচ্ছে","TweetUnavailable received (Reason: unknown)":"TweetUnavailable পাওয়া গেছে (কারণ: অজানা)","Empty tweet received":"খালি টুইট পাওয়া গেছে","Unknown tweet type received":"অজানা টুইট টাইপ পাওয়া গেছে","Failed to extract tweet":"টুইট বের করতে ব্যর্থ","Failed to export file":"ফাইল রপ্তানি ব্যর্থ","Failed to stream export file":"stream export ফাইল ব্যর্থ"}},Tb={exporter:{ID:"ID",Date:"Date",Content:"Content","Show Full Text":"Show Full Text",Media:"Media","Screen Name":"Screen Name","Profile Name":"Profile Name","Profile Image":"Profile Image","User ID":"User ID","Replying To":"Replying To","RT Source":"RT Source","Quote Source":"Quote Source","Media Tags":"Media Tags",Favorites:"Favorites",Retweets:"Retweets",Bookmarks:"Bookmarks",Quotes:"Quotes",Replies:"Replies",Views:"Views",Favorited:"Favorited",Retweeted:"Retweeted",Bookmarked:"Bookmarked","Bookmark Folder":"Bookmark Folder",URL:"URL",Actions:"Actions",Details:"Details",Description:"Description","Profile Banner":"Profile Banner",Followers:"Followers",FollowingCount:"Following Count",Statuses:"Statuses",Favourites:"Favourites",Listed:"Listed",Location:"Location",Website:"Website",Birthdate:"Birthdate","Verified Type":"Verified Type","Blue Verified":"Blue Verified",Following:"Following","Follows You":"Follows You","Can DM":"Can DM",Protected:"Protected","Created At":"Created At",Sender:"Sender",Recipient:"Recipient","Conversation ID":"Conversation ID","Conversation Type":"Conversation Type",Data:"Data","Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.":"Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.","Data length:":"Data length:","Export scope:":"Export scope:","All current results":"All current results","Selected rows":"Selected rows","Pinned result set":"Pinned result set",Query:"Query",Sort:"Sort","Include all metadata:":"Include all metadata:","Export as:":"Export as:","No data selected.":"No data selected.",Cancel:"Cancel","Start Export":"Start Export","Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).":"Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).","For more than 100 media or large files, it is recommended to copy the URLs and download them with an external download manager such as aria2.":"For more than 100 media or large files, it is recommended to copy the URLs and download them with an external download manager such as aria2.","Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.":"Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.","Filename template:":"Filename template:","Download scheduler":"Download scheduler","Faster defaults are intended for bulk CDN transfer.":"Faster defaults are intended for bulk CDN transfer.","Start delay (ms)":"Start delay (ms)","Global parallel":"Global parallel","Per host":"Per host",Videos:"Videos",Retries:"Retries","Use aria2 format:":"Use aria2 format:","Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2.":"Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2.","Rate limit (ms):":"Rate limit (ms):","Media Filter:":"Media Filter:","File Name":"File Name","Media Type":"Media Type","Download URL":"Download URL","No media selected.":"No media selected.","Preview limited to first 250 media items.":"Preview limited to first 250 media items.",Zipping:"Zipping","Copied!":"Copied!","Copy URLs":"Copy URLs","The tweet ID":"The tweet ID","The username of tweet author":"The username of tweet author","The profile name of tweet author":"The profile name of tweet author","The media index in tweet (start from 0)":"The media index in tweet (start from 0)","The order of media in tweet (1/2/3/4)":"The order of media in tweet (1/2/3/4)","The post date in YYYYMMDD format":"The post date in YYYYMMDD format","The post time in HHmmss format":"The post time in HHmmss format","The media type (photo/video/animated_gif)":"The media type (photo/video/animated_gif)","The file extension of media (jpg/png/mp4)":"The file extension of media (jpg/png/mp4)","Failed to export media. Open DevTools for more details.":"Failed to export media. Open DevTools for more details.","Failed to copy media URLs. Open DevTools for more details.":"Failed to copy media URLs. Open DevTools for more details.","filter.photo":"Photo","filter.video":"Video","filter.animated_gif":"GIF","filter.retweet":"Include retweets","loading remaining rows":"loading remaining rows","Bundle ZIP compression:":"Bundle ZIP compression:","Fastest / store":"Fastest / store","Balanced / fast":"Balanced / fast","Smaller / slower":"Smaller / slower","Cancel Export":"Cancel Export","Export a canonical portable ZIP bundle for sharing/importing.":"Export a canonical portable ZIP bundle for sharing/importing.","Export Bundle ZIP":"Export Bundle ZIP","Source-backed media":"Source-backed media","rows scanned:":"rows scanned:","media URLs:":"media URLs:",loading:"loading","Loading media...":"Loading media..."},common:{"Open Control Panel":"Open Control Panel","Browse around to capture more data.":"Browse around to capture more data.",Settings:"Settings",General:"General",Theme:"Theme",Language:"Language",Debug:"Debug","Date Time Format":"Date Time Format","Click for more information. This will take effect on both previewer and exported files.":"Click for more information. This will take effect on both previewer and exported files.","Use dedicated DB for accounts":"Use dedicated DB for accounts","This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts.":"This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts.","Local Database":"Local Database","Analyze DB":"Analyze","Export DB":"Export","Clear DB":"Clear","Bundle Export":"Bundle Export","Bundle Library":"Bundle Library","QC Session":"QC Session","Diagnostic capture":"Diagnostic capture","Diagnostic buffers cleared.":"Diagnostic buffers cleared.","Clear Buffers":"Clear Buffers","Preparing...":"Preparing...","Preparing diagnostics...":"Preparing diagnostics...","Export QC Diagnostics":"Export QC Diagnostics","Export Diagnostics Bundle":"Export Diagnostics Bundle","QC idle.":"QC idle.","Are you sure to clear all data in the database?":"Are you sure to clear all data in the database?","Database cleared.":"Database cleared.",Module:"Module","Modules (Scroll to see more)":"Modules (Scroll to see more)",About:"About",Version:"Version","Search...":"Search...","Something went wrong.":"Something went wrong.","Error:":"Error:","Captured:":"Captured:","Rows per page:":"Rows per page:","Relation Types":"Relation Types","Subject Accounts":"Subject Accounts","Subject User IDs":"Subject User IDs","Last Observed At":"Last Observed At","A - B of N items":"{{from}} - {{to}} of {{total}} items","No data available.":"No data available.","No media available.":"No media available.",Clear:"Clear","Bookmark folders":"Bookmark folders","1 folder selected":"1 folder selected","{{count}} folders selected":"{{count}} folders selected","Export Media":"Export Media","Export Data":"Export Data","Export Search History":"Export Search History","JSON View":"JSON View","Media View":"Media View",Bookmarks:"Bookmarks",Tweets:"Tweets",Users:"Users","User Tweets":"User Tweets","User Media":"User Media","Tweet Details":"Tweet Details","Search Timeline":"Search Timeline","Home Timeline":"Home Timeline","List Timeline":"List Timeline","Community Timeline":"Community Timeline","Community Members":"Community Members","List Members":"List Members","List Subscribers":"List Subscribers","Direct Messages":"Direct Messages","Interaction Events":"Interaction Events","Local Search":"Local Search","Runtime Logs":"Runtime Logs","Bundle Viewer":"Bundle Viewer","{{count}} imported bundles":"{{count}} imported bundles","Search indexed tweets with Twitter-style operators":"Search indexed tweets with Twitter-style operators","Local Recorder Search":"Local Recorder Search",Quotes:"Quotes",CommunityMembers:"CommunityMembers",CommunityTimeline:"CommunityTimeline",DirectMessages:"DirectMessages",Followers:"Followers",Following:"Following",HomeTimeline:"HomeTimeline",Likes:"Likes",ListMembers:"ListMembers",ListSubscribers:"ListSubscribers",ListTimeline:"ListTimeline",InteractionEvents:"InteractionEvents",LocalSearch:"LocalSearch",RawCapture:"RawCapture",Retweeters:"Retweeters",RetweetersModule:"RetweetersModule",RuntimeLogs:"RuntimeLogs",SearchTimeline:"SearchTimeline",TweetIndex:"TweetIndex",TweetDetail:"TweetDetail",UserDetail:"UserDetail",UserMedia:"UserMedia",UserTweets:"UserTweets",on:"on",off:"off",unknown:"unknown",online:"online",offline:"offline",leader:"leader",follower:"follower",tab:"tab",both:"both",xhr:"xhr",fetch:"fetch",watchdog:"watchdog",all:"all",explicit:"explicit",loading:"loading",complete:"complete",idle:"idle","api-name":"api-name","id-only":"id-only","theme.system":"System","theme.cupcake":"Cupcake","theme.dark":"Dark","theme.emerald":"Emerald","theme.cyberpunk":"Cyberpunk","theme.valentine":"Valentine","theme.lofi":"Lo-fi","theme.dracula":"Dracula","theme.cmyk":"CMYK","theme.business":"Business","theme.winter":"Winter","Safe mode":"Safe mode","Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture.":"Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture.","Hook mode":"Hook mode","Controls whether the userscript hooks XHR, fetch, both, or neither.":"Controls whether the userscript hooks XHR, fetch, both, or neither.","Repair mode":"Repair mode","Controls whether hook repair watchdog behavior is active.":"Controls whether hook repair watchdog behavior is active.","{{seconds}}s ago":"{{seconds}}s ago","Hooks: {{status}}":"Hooks: {{status}}","Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})":"Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})","Hooks: xhr {{xhr}}, fetch {{fetch}}":"Hooks: xhr {{xhr}}, fetch {{fetch}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}":"Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}":"Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}","raw events: {{total}} | dropped: {{dropped}}":"raw events: {{total}} | dropped: {{dropped}}","spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed":"spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed","spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms":"spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms","daemon: {{status}}":"daemon: {{status}}","daemon: {{status}} | last error: {{error}}":"daemon: {{status}} | last error: {{error}}","monitor: {{role}} | leader: {{leader}} | lease: {{lease}}":"monitor: {{role}} | leader: {{leader}} | lease: {{lease}}","monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}":"monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}","Database connected: {{name}}":"Database connected: {{name}}","App options loaded":"App options loaded",'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)':'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)',"Search help":"Search help","Clear search":"Clear search","Table view":"Table view","Exit fullscreen":"Exit fullscreen",Fullscreen:"Fullscreen","{{view}} is disabled for large source-backed result sets.":"{{view}} is disabled for large source-backed result sets.","{{view}} view - {{status}}":"{{view}} view - {{status}}","{{view}} view":"{{view}} view","loading {{loaded}}/{{total}}":"loading {{loaded}}/{{total}}","loading more {{loaded}}/{{total}}":"loading more {{loaded}}/{{total}}","searching {{matches}}/{{total}}":"searching {{matches}}/{{total}}","matches {{matches}}/{{total}}":"matches {{matches}}/{{total}}","rows {{loaded}}/{{total}}":"rows {{loaded}}/{{total}}","rows {{count}}":"rows {{count}}","buffering...":"buffering...","history {{count}}":"history {{count}}","selected {{count}} ({{mode}})":"selected {{count}} ({{mode}})","rendered {{rendered}}/{{total}} (window {{start}}-{{end}})":"rendered {{rendered}}/{{total}} (window {{start}}-{{end}})","Search Operators":"Search Operators","Query semantics now follow recorder-style precedence:":"Query semantics now follow recorder-style precedence:","with implicit":"with implicit","between adjacent terms.":"between adjacent terms.","search.category.lexical":"Lexical","search.category.identity":"Identity","search.category.metadata":"Metadata","search.category.presence":"Presence","search.category.numeric_date":"Numeric/date","search.category.compatibility":"Compatibility","Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.":"Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.","Phrase search with optional slop.":"Phrase search with optional slop.","Boolean operators with standard precedence and parentheses.":"Boolean operators with standard precedence and parentheses.","Match the author handle or author id.":"Match the author handle or author id.","Shorthand for an enforced author constraint, equivalent to from:user.":"Shorthand for an enforced author constraint, equivalent to from:user.","Match reply targets, entity ids, or conversation ids.":"Match reply targets, entity ids, or conversation ids.","Match bookmark folder id or folder name.":"Match bookmark folder id or folder name.","Match language, route surface, source text, or card name.":"Match language, route surface, source text, or card name.","Match domains or URLs found in tweets.":"Match domains or URLs found in tweets.","Boolean state filters.":"Boolean state filters.","Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.":"Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.","Compatibility aliases retained for Twitter-style queries.":"Compatibility aliases retained for Twitter-style queries.","Numeric threshold filters.":"Numeric threshold filters.","Date, timestamp, and Snowflake-style boundary filters.":"Date, timestamp, and Snowflake-style boundary filters.","Explicit mention filter plus shorthand hashtag and cashtag filters.":"Explicit mention filter plus shorthand hashtag and cashtag filters.","Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.":"Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.","loading source {{scanned}}/{{total}}":"loading source {{scanned}}/{{total}}","source {{status}} {{scanned}}/{{total}}":"source {{status}} {{scanned}}/{{total}}","media {{count}}":"media {{count}}","loaded media {{count}}":"loaded media {{count}}","source rows {{scanned}}/{{total}} {{status}}":"source rows {{scanned}}/{{total}} {{status}}","source rows {{count}}":"source rows {{count}}","layout {{columns}} cols @ {{width}}px":"layout {{columns}} cols @ {{width}}px","original tweet attachments only":"original tweet attachments only","Loading media.":"Loading media.","Comfortable density":"Comfortable density","Compact density":"Compact density",Photo:"Photo",Video:"Video","Open tweet":"Open tweet","Export menu is open while remaining rows load in the background.":"Export menu is open while remaining rows load in the background.","Wait for records to finish loading before exporting.":"Wait for records to finish loading before exporting.","Exports stream from the active source without loading all rows into the table.":"Exports stream from the active source without loading all rows into the table.","Opens immediately and loads remaining rows in the background.":"Opens immediately and loads remaining rows in the background.","Export persisted bookmark search history":"Export persisted bookmark search history","latest: {{latest}}\napi-name: {{apiName}}\nid-only: {{idOnly}}\nnone: {{none}}":`latest: {{latest}}
api-name: {{apiName}}
id-only: {{idOnly}}
none: {{none}}`,"folder metadata: {{status}}":"folder metadata: {{status}}","Media export is disabled for large result sets until media export has a source-backed stream.":"Media export is disabled for large result sets until media export has a source-backed stream.","App options migrated from v{{oldVersion}} to v{{newVersion}}":"App options migrated from v{{oldVersion}} to v{{newVersion}}","Hooked into fetch":"Hooked into fetch","Hooked into XMLHttpRequest (installed={{installed}})":"Hooked into XMLHttpRequest (installed={{installed}})","Hook safe mode enabled ({{reason}})":"Hook safe mode enabled ({{reason}})","Hook repair failed ({{failures}}/{{limit}})":"Hook repair failed ({{failures}}/{{limit}})","Bookmark context tracking install failed; continuing without tracker ({{details}})":"Bookmark context tracking install failed; continuing without tracker ({{details}})","TWE_DIAG {{phase}}":"TWE_DIAG {{phase}}","{{module}}: {{count}} items received":"{{module}}: {{count}} items received","Exporting to ZIP file: {{filename}}":"Exporting to ZIP file: {{filename}}","Exporting to {{format}} file: {{filename}}":"Exporting to {{format}} file: {{filename}}","Streaming export to {{format}} file: {{filename}}":"Streaming export to {{format}} file: {{filename}}","Migration completed: {{users}} users and {{tweets}} tweets updated.":"Migration completed: {{users}} users and {{tweets}} tweets updated.","TweetTombstone received (Reason: {{reason}})":"TweetTombstone received (Reason: {{reason}})","Failed to hook into XMLHttpRequest":"Failed to hook into XMLHttpRequest","Fetch API not found, skipping fetch hooks":"Fetch API not found, skipping fetch hooks","Fetch API base function unavailable or unsafe; enabling safe mode":"Fetch API base function unavailable or unsafe; enabling safe mode","Fetch hook base invocation failed; enabling safe mode":"Fetch hook base invocation failed; enabling safe mode","XHR send hook base invocation failed; enabling safe mode":"XHR send hook base invocation failed; enabling safe mode","XHR open hook base invocation failed; enabling safe mode":"XHR open hook base invocation failed; enabling safe mode","Fetch hook already installed":"Fetch hook already installed","Debug mode enabled":"Debug mode enabled","Database cleared":"Database cleared","Upgrading database schema...":"Upgrading database schema...","Database upgraded":"Database upgraded","Zip stream closed.":"Zip stream closed.","Running migration_20250609: Migrating legacy user data format":"Running migration_20250609: Migrating legacy user data format","TweetUnavailable received (Reason: unknown)":"TweetUnavailable received (Reason: unknown)","Empty tweet received":"Empty tweet received","Unknown tweet type received":"Unknown tweet type received","Failed to extract tweet":"Failed to extract tweet","Failed to export file":"Failed to export file","Failed to stream export file":"Failed to stream export file"}},Mb={exporter:{ID:"ID",Date:"Fecha",Content:"Contenido","Show Full Text":"Mostrar texto completo",Media:"Medios","Screen Name":"Nombre de usuario","Profile Name":"Nombre del perfil","Profile Image":"Imagen de perfil","User ID":"ID de usuario","Replying To":"Responde a","RT Source":"Fuente del RT","Quote Source":"Fuente de la cita","Media Tags":"Etiquetas de medios",Favorites:"Favoritos",Retweets:"Retweets",Bookmarks:"Marcadores",Quotes:"Citas",Replies:"Respuestas",Views:"Visualizaciones",Favorited:"Marcado como favorito",Retweeted:"Retuiteado",Bookmarked:"Guardado en marcadores","Bookmark Folder":"Carpeta de marcadores",URL:"URL",Actions:"Acciones",Details:"Detalles",Description:"Descripción","Profile Banner":"Banner del perfil",Followers:"Seguidores",FollowingCount:"Número de seguidos",Statuses:"Publicaciones",Favourites:"Favoritos",Listed:"En listas",Location:"Ubicación",Website:"Sitio web",Birthdate:"Fecha de nacimiento","Verified Type":"Tipo de verificación","Blue Verified":"Verificación Blue",Following:"Siguiendo","Follows You":"Te sigue","Can DM":"Puede recibir DM",Protected:"Protegido","Created At":"Creado el",Sender:"Remitente",Recipient:"Destinatario","Conversation ID":"ID de conversación","Conversation Type":"Tipo de conversación",Data:"Datos","Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.":"Exporta los datos capturados como archivo JSON/HTML/CSV. Puede tardar según la cantidad de datos. El archivo exportado no incluye archivos multimedia como imágenes o videos, solo sus URL.","Data length:":"Longitud de datos:","Export scope:":"Alcance de exportación:","All current results":"Todos los resultados actuales","Selected rows":"Filas seleccionadas","Pinned result set":"Conjunto de resultados fijado",Query:"Consulta",Sort:"Orden","Include all metadata:":"Incluir todos los metadatos:","Export as:":"Exportar como:","No data selected.":"No hay datos seleccionados.",Cancel:"Cancelar","Start Export":"Iniciar exportación","Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).":"Descarga y guarda archivos multimedia desde los datos capturados. Puede tardar según la cantidad de datos. Se descargarán imágenes de perfil, banners de perfil (para usuarios), imágenes y videos (para tweets).","For more than 100 media or large files, it is recommended to copy the URLs and download them with an external download manager such as aria2.":"Para más de 100 medios o archivos grandes, se recomienda copiar las URL y descargarlas con un gestor externo como aria2.","Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.":"La exportación ZIP del navegador ahora usa descargas paralelas limitadas. Para trabajos muy grandes con muchos videos, exportar URL o aria2 sigue siendo la ruta más segura y de baja memoria.","Filename template:":"Plantilla de nombre de archivo:","Download scheduler":"Planificador de descargas","Faster defaults are intended for bulk CDN transfer.":"Los valores predeterminados más rápidos están pensados para transferencias masivas desde CDN.","Start delay (ms)":"Retraso inicial (ms)","Global parallel":"Paralelismo global","Per host":"Por host",Videos:"Videos",Retries:"Reintentos","Use aria2 format:":"Usar formato aria2:","Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2.":"Haz clic para más información. Cada URL irá en una línea nueva, con su nombre de archivo en la línea siguiente. Este formato es compatible con aria2.","Rate limit (ms):":"Límite de tasa (ms):","Media Filter:":"Filtro de medios:","File Name":"Nombre de archivo","Media Type":"Tipo de medio","Download URL":"URL de descarga","No media selected.":"No hay medios seleccionados.","Preview limited to first 250 media items.":"La vista previa se limita a los primeros 250 elementos multimedia.",Zipping:"Comprimiendo","Copied!":"Copiado","Copy URLs":"Copiar URL","The tweet ID":"El ID del tweet","The username of tweet author":"El nombre de usuario del autor del tweet","The profile name of tweet author":"El nombre de perfil del autor del tweet","The media index in tweet (start from 0)":"El índice del medio en el tweet (empieza en 0)","The order of media in tweet (1/2/3/4)":"El orden del medio en el tweet (1/2/3/4)","The post date in YYYYMMDD format":"La fecha de publicación en formato YYYYMMDD","The post time in HHmmss format":"La hora de publicación en formato HHmmss","The media type (photo/video/animated_gif)":"El tipo de medio (photo/video/animated_gif)","The file extension of media (jpg/png/mp4)":"La extensión del archivo multimedia (jpg/png/mp4)","Failed to export media. Open DevTools for more details.":"No se pudieron exportar los medios. Abre DevTools para más detalles.","Failed to copy media URLs. Open DevTools for more details.":"No se pudieron copiar las URL de medios. Abre DevTools para más detalles.","filter.photo":"Foto","filter.video":"Video","filter.animated_gif":"GIF","filter.retweet":"Incluir retweets","loading remaining rows":"cargando filas restantes","Bundle ZIP compression:":"Compresión del ZIP bundle:","Fastest / store":"Más rápido / almacenar","Balanced / fast":"Equilibrado / rápido","Smaller / slower":"Más pequeño / más lento","Cancel Export":"Cancelar exportación","Export a canonical portable ZIP bundle for sharing/importing.":"Exporta un ZIP bundle portátil canónico para compartir/importar.","Export Bundle ZIP":"Exportar ZIP bundle","Source-backed media":"Medios respaldados por fuente","rows scanned:":"filas escaneadas:","media URLs:":"URLs de medios:",loading:"cargando","Loading media...":"Cargando medios..."},common:{"Open Control Panel":"Abrir panel de control","Browse around to capture more data.":"Navega para capturar más datos.",Settings:"Configuración",General:"General",Theme:"Tema",Language:"Idioma",Debug:"Depuración","Date Time Format":"Formato de fecha y hora","Click for more information. This will take effect on both previewer and exported files.":"Haz clic para ver más información. Esto se aplicará tanto al visor previo como a los archivos exportados.","Use dedicated DB for accounts":"Usar una base de datos dedicada por cuenta","This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts.":"Esto creará una base de datos separada para cada cuenta de Twitter, lo que ayuda a reducir la mezcla de datos al usar varias cuentas.","Local Database":"Base de datos local","Analyze DB":"Analizar","Export DB":"Exportar","Clear DB":"Borrar","Bundle Export":"Exportar paquete","Bundle Library":"Biblioteca de paquetes","QC Session":"Sesión de QC","Diagnostic capture":"Captura diagnóstica","Diagnostic buffers cleared.":"Búferes de diagnóstico borrados.","Clear Buffers":"Borrar búferes","Preparing...":"Preparando...","Preparing diagnostics...":"Preparando diagnósticos...","Export QC Diagnostics":"Exportar diagnósticos de QC","Export Diagnostics Bundle":"Exportar paquete de diagnósticos","QC idle.":"QC inactivo.","Are you sure to clear all data in the database?":"¿Seguro que quieres borrar todos los datos de la base de datos?","Database cleared.":"Base de datos borrada.",Module:"Módulo","Modules (Scroll to see more)":"Módulos (desplázate para ver más)",About:"Acerca de",Version:"Versión","Search...":"Buscar...","Something went wrong.":"Algo salió mal.","Error:":"Error:","Captured:":"Capturado:","Rows per page:":"Filas por página:","Relation Types":"Tipos de relación","Subject Accounts":"Cuentas sujeto","Subject User IDs":"ID de usuario sujeto","Last Observed At":"Última observación","A - B of N items":"{{from}} - {{to}} de {{total}} elementos","No data available.":"No hay datos disponibles.","No media available.":"No hay medios disponibles.",Clear:"Limpiar","Bookmark folders":"Carpetas de marcadores","1 folder selected":"1 carpeta seleccionada","{{count}} folders selected":"{{count}} carpetas seleccionadas","Export Media":"Exportar medios","Export Data":"Exportar datos","Export Search History":"Exportar historial de búsqueda","JSON View":"Vista JSON","Media View":"Vista de medios",Bookmarks:"Marcadores",Tweets:"Tweets",Users:"Usuarios","User Tweets":"Tweets de usuario","User Media":"Medios de usuario","Tweet Details":"Detalles del tweet","Search Timeline":"Cronología de búsqueda","Home Timeline":"Cronología de inicio","List Timeline":"Cronología de lista","Community Timeline":"Cronología de comunidad","Community Members":"Miembros de comunidad","List Members":"Miembros de lista","List Subscribers":"Suscriptores de lista","Direct Messages":"Mensajes directos","Interaction Events":"Eventos de interacción","Local Search":"Búsqueda local","Runtime Logs":"Registros de ejecución","Bundle Viewer":"Visor de paquetes","{{count}} imported bundles":"{{count}} paquetes importados","Search indexed tweets with Twitter-style operators":"Busca tweets indexados con operadores estilo Twitter","Local Recorder Search":"Búsqueda del registrador local",Quotes:"Citas",CommunityMembers:"Miembros de comunidad",CommunityTimeline:"Cronología de comunidad",DirectMessages:"Mensajes directos",Followers:"Seguidores",Following:"Siguiendo",HomeTimeline:"Cronología de inicio",Likes:"Me gusta",ListMembers:"Miembros de lista",ListSubscribers:"Suscriptores de lista",ListTimeline:"Cronología de lista",InteractionEvents:"Eventos de interacción",LocalSearch:"Búsqueda local",RawCapture:"Captura sin procesar",Retweeters:"Retuiteadores",RetweetersModule:"Retuiteadores",RuntimeLogs:"Registros de ejecución",SearchTimeline:"Búsqueda",TweetIndex:"Índice de tweets",TweetDetail:"Detalle del tweet",UserDetail:"Detalle de usuario",UserMedia:"Medios de usuario",UserTweets:"Tweets de usuario",on:"activado",off:"desactivado",unknown:"desconocido",online:"en línea",offline:"sin conexión",leader:"líder",follower:"seguidor",tab:"pestaña",both:"ambos",xhr:"xhr",fetch:"fetch",watchdog:"vigilante",all:"todo",explicit:"explícito",loading:"cargando",complete:"completo",idle:"inactivo","api-name":"nombre de API","id-only":"solo ID","theme.system":"Sistema","theme.cupcake":"Claro","theme.dark":"Oscuro","theme.emerald":"Emerald","theme.cyberpunk":"Cyberpunk","theme.valentine":"Valentine","theme.lofi":"Lo-fi","theme.dracula":"Dracula","theme.cmyk":"CMYK","theme.business":"Negocios","theme.winter":"Invierno","Safe mode":"Modo seguro","Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture.":"Desactiva la captura basada en hooks cuando está habilitado. Desactívalo para navegación normal y captura diagnóstica.","Hook mode":"Modo de hook","Controls whether the userscript hooks XHR, fetch, both, or neither.":"Controla si el userscript engancha XHR, fetch, ambos o ninguno.","Repair mode":"Modo de reparación","Controls whether hook repair watchdog behavior is active.":"Controla si el watchdog de reparación de hooks está activo.","{{seconds}}s ago":"hace {{seconds}} s","Hooks: {{status}}":"Hooks:{{status}}","Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})":"Hooks:xhr {{xhr}}, fetch {{fetch}}, último {{url}} ({{age}})","Hooks: xhr {{xhr}}, fetch {{fetch}}":"Hooks:xhr {{xhr}}, fetch {{fetch}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}":"Modo: seguro {{safe}}, hook {{hook}}, reparación {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}":"Modo: seguro {{safe}}, hook {{hook}}, reparación {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}","raw events: {{total}} | dropped: {{dropped}}":"eventos raw: {{total}} | descartados: {{dropped}}","spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed":"spool: {{queued}} en cola / {{enqueued}} enq / {{flushed}} volcados / {{failed}} fallidos","spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms":"descartes por desborde de spool: {{drops}} | no disponible: {{unavailable}} | pendiente más antiguo: {{age}}ms","daemon: {{status}}":"servicio:{{status}}","daemon: {{status}} | last error: {{error}}":"servicio:{{status}} | último error:{{error}}","monitor: {{role}} | leader: {{leader}} | lease: {{lease}}":"monitor:{{role}} | líder:{{leader}} | lease:{{lease}}","monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}":"ticks monitor ruta/viewport: {{route}}/{{viewport}} | suprimidos ruta/viewport: {{suppressedRoute}}/{{suppressedViewport}}","Database connected: {{name}}":"Base de datos conectada: {{name}}","App options loaded":"Opciones de la app cargadas",'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)':'Busca con operadores, frases y lógica booleana: from:alice ("design system"~2 OR reliability)',"Search help":"Ayuda de búsqueda","Clear search":"Limpiar búsqueda","Table view":"Vista de tabla","Exit fullscreen":"Salir de pantalla completa",Fullscreen:"Pantalla completa","{{view}} is disabled for large source-backed result sets.":"{{view}} está deshabilitada para conjuntos grandes respaldados por fuente.","{{view}} view - {{status}}":"Vista {{view}} - {{status}}","{{view}} view":"Vista {{view}}","loading {{loaded}}/{{total}}":"cargando {{loaded}}/{{total}}","loading more {{loaded}}/{{total}}":"cargando más {{loaded}}/{{total}}","searching {{matches}}/{{total}}":"buscando {{matches}}/{{total}}","matches {{matches}}/{{total}}":"coincidencias {{matches}}/{{total}}","rows {{loaded}}/{{total}}":"filas {{loaded}}/{{total}}","rows {{count}}":"filas {{count}}","buffering...":"almacenando...","history {{count}}":"historial {{count}}","selected {{count}} ({{mode}})":"seleccionados {{count}} ({{mode}})","rendered {{rendered}}/{{total}} (window {{start}}-{{end}})":"renderizado {{rendered}}/{{total}} (ventana {{start}}-{{end}})","Search Operators":"Operadores de búsqueda","Query semantics now follow recorder-style precedence:":"La semántica de consulta ahora sigue precedencia estilo recorder:","with implicit":"con","between adjacent terms.":"implícito entre términos adyacentes.","search.category.lexical":"Léxico","search.category.identity":"Identidad","search.category.metadata":"Metadatos","search.category.presence":"Presencia","search.category.numeric_date":"Numérico/fecha","search.category.compatibility":"Compatibilidad","Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.":"El texto no estructurado se expande en coincidencias de términos de contenido y ventanas de frases adyacentes con mayor peso; las palabras comunes pierden prioridad salvo que estén entre comillas.","Phrase search with optional slop.":"Búsqueda de frases con holgura opcional.","Boolean operators with standard precedence and parentheses.":"Operadores booleanos con precedencia estándar y paréntesis.","Match the author handle or author id.":"Coincide con el usuario o ID del autor.","Shorthand for an enforced author constraint, equivalent to from:user.":"Atajo para una restricción de autor obligatoria, equivalente a from:user.","Match reply targets, entity ids, or conversation ids.":"Coincide con destinos de respuesta, IDs de entidad o IDs de conversación.","Match bookmark folder id or folder name.":"Coincide con el ID o nombre de la carpeta de marcadores.","Match language, route surface, source text, or card name.":"Coincide con idioma, superficie de ruta, texto de origen o nombre de tarjeta.","Match domains or URLs found in tweets.":"Coincide con dominios o URLs encontrados en tweets.","Boolean state filters.":"Filtros de estado booleanos.","Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.":"Filtros de presencia para medios, enlaces, menciones, hashtags, cashtags, interacción y encuestas.","Compatibility aliases retained for Twitter-style queries.":"Alias de compatibilidad conservados para consultas estilo Twitter.","Numeric threshold filters.":"Filtros de umbral numérico.","Date, timestamp, and Snowflake-style boundary filters.":"Filtros de límite por fecha, marca temporal y estilo Snowflake.","Explicit mention filter plus shorthand hashtag and cashtag filters.":"Filtro explícito de mención más filtros abreviados de hashtag y cashtag.","Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.":"Búsqueda léxica limitada a campos sobre rutas anidadas sin procesar, incluidas rutas con puntos y arrays.","loading source {{scanned}}/{{total}}":"cargando fuente {{scanned}}/{{total}}","source {{status}} {{scanned}}/{{total}}":"fuente {{status}} {{scanned}}/{{total}}","media {{count}}":"medios {{count}}","loaded media {{count}}":"medios cargados {{count}}","source rows {{scanned}}/{{total}} {{status}}":"filas fuente {{scanned}}/{{total}} {{status}}","source rows {{count}}":"filas fuente {{count}}","layout {{columns}} cols @ {{width}}px":"diseño {{columns}} cols @ {{width}}px","original tweet attachments only":"solo adjuntos del tweet original","Loading media.":"Cargando medios.","Comfortable density":"Densidad cómoda","Compact density":"Densidad compacta",Photo:"Foto",Video:"Video","Open tweet":"Abrir tweet","Export menu is open while remaining rows load in the background.":"El menú de exportación está abierto mientras las filas restantes cargan en segundo plano.","Wait for records to finish loading before exporting.":"Espera a que los registros terminen de cargar antes de exportar.","Exports stream from the active source without loading all rows into the table.":"Exporta en streaming desde la fuente activa sin cargar todas las filas en la tabla.","Opens immediately and loads remaining rows in the background.":"Se abre de inmediato y carga las filas restantes en segundo plano.","Export persisted bookmark search history":"Exportar historial de búsqueda de marcadores guardado","latest: {{latest}}\napi-name: {{apiName}}\nid-only: {{idOnly}}\nnone: {{none}}":`último: {{latest}}
nombre-api: {{apiName}}
solo-id: {{idOnly}}
ninguno: {{none}}`,"folder metadata: {{status}}":"metadatos de carpeta: {{status}}","Media export is disabled for large result sets until media export has a source-backed stream.":"La exportación de medios está deshabilitada para resultados grandes hasta que tenga stream respaldado por fuente.","App options migrated from v{{oldVersion}} to v{{newVersion}}":"Opciones migradas de v{{oldVersion}} a v{{newVersion}}","Hooked into fetch":"Hook instalado en fetch","Hooked into XMLHttpRequest (installed={{installed}})":"Hook instalado en XMLHttpRequest (installed={{installed}})","Hook safe mode enabled ({{reason}})":"Modo seguro de hooks activado ({{reason}})","Hook repair failed ({{failures}}/{{limit}})":"Reparación de hook fallida ({{failures}}/{{limit}})","Bookmark context tracking install failed; continuing without tracker ({{details}})":"Falló la instalación del rastreador de contexto de marcadores; continúa sin rastreador ({{details}})","TWE_DIAG {{phase}}":"TWE_DIAG {{phase}}","{{module}}: {{count}} items received":"{{module}}: {{count}} elementos recibidos","Exporting to ZIP file: {{filename}}":"Exportando a archivo ZIP: {{filename}}","Exporting to {{format}} file: {{filename}}":"Exportando a archivo {{format}}: {{filename}}","Streaming export to {{format}} file: {{filename}}":"Exportación streaming a archivo {{format}}: {{filename}}","Migration completed: {{users}} users and {{tweets}} tweets updated.":"Migración completada: {{users}} usuarios y {{tweets}} tweets actualizados.","TweetTombstone received (Reason: {{reason}})":"TweetTombstone recibido (Razón: {{reason}})","Failed to hook into XMLHttpRequest":"Error al enganchar XMLHttpRequest","Fetch API not found, skipping fetch hooks":"Fetch API no encontrada, omitiendo hooks de fetch","Fetch API base function unavailable or unsafe; enabling safe mode":"Función base de Fetch API no disponible o insegura; activando modo seguro","Fetch hook base invocation failed; enabling safe mode":"Invocación base del hook fetch fallida; activando modo seguro","XHR send hook base invocation failed; enabling safe mode":"Invocación base del hook XHR send fallida; activando modo seguro","XHR open hook base invocation failed; enabling safe mode":"Invocación base del hook XHR open fallida; activando modo seguro","Fetch hook already installed":"Hook de fetch ya instalado","Debug mode enabled":"Modo debug activado","Database cleared":"Base de datos borrada","Upgrading database schema...":"Actualizando esquema de base de datos...","Database upgraded":"Base de datos actualizada","Zip stream closed.":"Stream ZIP cerrado.","Running migration_20250609: Migrating legacy user data format":"Ejecutando migration_20250609: migrando formato heredado de datos de usuario","TweetUnavailable received (Reason: unknown)":"TweetUnavailable recibido (Razón: desconocida)","Empty tweet received":"Tweet vacío recibido","Unknown tweet type received":"Tipo de tweet desconocido recibido","Failed to extract tweet":"No se pudo extraer el tweet","Failed to export file":"No se pudo exportar el archivo","Failed to stream export file":"No se pudo exportar archivo en streaming"}},Rb={exporter:{ID:"ID",Date:"Date",Content:"Contenu","Show Full Text":"Afficher le texte complet",Media:"Médias","Screen Name":"Nom d’utilisateur","Profile Name":"Nom du profil","Profile Image":"Image de profil","User ID":"ID utilisateur","Replying To":"Répond à","RT Source":"Source du RT","Quote Source":"Source de la citation","Media Tags":"Tags média",Favorites:"Favoris",Retweets:"Retweets",Bookmarks:"Signets",Quotes:"Citations",Replies:"Réponses",Views:"Vues",Favorited:"Ajouté aux favoris",Retweeted:"Retweeté",Bookmarked:"Ajouté aux signets","Bookmark Folder":"Dossier de signets",URL:"URL",Actions:"Actions",Details:"Détails",Description:"Description","Profile Banner":"Bannière du profil",Followers:"Abonnés",FollowingCount:"Nombre d’abonnements",Statuses:"Publications",Favourites:"Favoris",Listed:"Listé",Location:"Lieu",Website:"Site web",Birthdate:"Date de naissance","Verified Type":"Type de vérification","Blue Verified":"Vérifié Blue",Following:"Abonnements","Follows You":"Vous suit","Can DM":"DM possible",Protected:"Protégé","Created At":"Créé le",Sender:"Expéditeur",Recipient:"Destinataire","Conversation ID":"ID de conversation","Conversation Type":"Type de conversation",Data:"Données","Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.":"Exportez les données capturées en fichier JSON/HTML/CSV. Cela peut prendre du temps selon la quantité de données. Le fichier exporté n’inclut pas les médias comme les images et vidéos, seulement leurs URL.","Data length:":"Longueur des données :","Export scope:":"Portée de l’export :","All current results":"Tous les résultats actuels","Selected rows":"Lignes sélectionnées","Pinned result set":"Ensemble de résultats épinglé",Query:"Requête",Sort:"Tri","Include all metadata:":"Inclure toutes les métadonnées :","Export as:":"Exporter en :","No data selected.":"Aucune donnée sélectionnée.",Cancel:"Annuler","Start Export":"Démarrer l’export","Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).":"Télécharge et enregistre les médias à partir des données capturées. Cela peut prendre du temps selon la quantité de données. Les médias téléchargés incluent les images de profil, les bannières de profil (pour les utilisateurs), les images et les vidéos (pour les tweets).","For more than 100 media or large files, it is recommended to copy the URLs and download them with an external download manager such as aria2.":"Pour plus de 100 médias ou de gros fichiers, il est recommandé de copier les URL et de les télécharger avec un gestionnaire externe comme aria2.","Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.":"L’export ZIP du navigateur utilise maintenant des téléchargements parallèles bornés. Pour les très gros travaux riches en vidéos, l’export URL ou aria2 reste la voie la plus sûre et la moins gourmande en mémoire.","Filename template:":"Modèle de nom de fichier :","Download scheduler":"Planificateur de téléchargement","Faster defaults are intended for bulk CDN transfer.":"Les valeurs par défaut plus rapides sont prévues pour les transferts CDN en masse.","Start delay (ms)":"Délai de départ (ms)","Global parallel":"Parallélisme global","Per host":"Par hôte",Videos:"Vidéos",Retries:"Tentatives","Use aria2 format:":"Utiliser le format aria2 :","Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2.":"Cliquez pour plus d’informations. Chaque URL sera sur une nouvelle ligne, avec le nom de fichier sur la ligne suivante. Ce format est compatible avec aria2.","Rate limit (ms):":"Limite de débit (ms) :","Media Filter:":"Filtre média :","File Name":"Nom de fichier","Media Type":"Type de média","Download URL":"URL de téléchargement","No media selected.":"Aucun média sélectionné.","Preview limited to first 250 media items.":"Aperçu limité aux 250 premiers médias.",Zipping:"Compression ZIP","Copied!":"Copié !","Copy URLs":"Copier les URL","The tweet ID":"L’ID du tweet","The username of tweet author":"Le nom d’utilisateur de l’auteur du tweet","The profile name of tweet author":"Le nom de profil de l’auteur du tweet","The media index in tweet (start from 0)":"L’index du média dans le tweet (commence à 0)","The order of media in tweet (1/2/3/4)":"L’ordre du média dans le tweet (1/2/3/4)","The post date in YYYYMMDD format":"La date de publication au format YYYYMMDD","The post time in HHmmss format":"L’heure de publication au format HHmmss","The media type (photo/video/animated_gif)":"Le type de média (photo/video/animated_gif)","The file extension of media (jpg/png/mp4)":"L’extension du fichier média (jpg/png/mp4)","Failed to export media. Open DevTools for more details.":"Échec de l’export des médias. Ouvrez DevTools pour plus de détails.","Failed to copy media URLs. Open DevTools for more details.":"Échec de la copie des URL média. Ouvrez DevTools pour plus de détails.","filter.photo":"Photo","filter.video":"Vidéo","filter.animated_gif":"GIF","filter.retweet":"Inclure les retweets","loading remaining rows":"chargement des lignes restantes","Bundle ZIP compression:":"Compression du bundle ZIP :","Fastest / store":"Plus rapide / stocker","Balanced / fast":"Équilibré / rapide","Smaller / slower":"Plus petit / plus lent","Cancel Export":"Annuler l’export","Export a canonical portable ZIP bundle for sharing/importing.":"Exporte un bundle ZIP portable canonique pour partage/import.","Export Bundle ZIP":"Exporter le bundle ZIP","Source-backed media":"Médias basés sur source","rows scanned:":"lignes analysées :","media URLs:":"URL médias :",loading:"chargement","Loading media...":"Chargement des médias..."},common:{"Open Control Panel":"Ouvrir le panneau de contrôle","Browse around to capture more data.":"Parcourez les pages pour capturer plus de données.",Settings:"Paramètres",General:"Général",Theme:"Thème",Language:"Langue",Debug:"Débogage","Date Time Format":"Format de date et d’heure","Click for more information. This will take effect on both previewer and exported files.":"Cliquez pour plus d’informations. Cela s’appliquera à la prévisualisation et aux fichiers exportés.","Use dedicated DB for accounts":"Utiliser une base dédiée par compte","This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts.":"Cela créera une base de données séparée pour chaque compte Twitter, ce qui réduit le risque de mélange des données lorsque vous utilisez plusieurs comptes.","Local Database":"Base de données locale","Analyze DB":"Analyser","Export DB":"Exporter","Clear DB":"Effacer","Bundle Export":"Exporter un paquet","Bundle Library":"Bibliothèque de paquets","QC Session":"Session QC","Diagnostic capture":"Capture diagnostique","Diagnostic buffers cleared.":"Tampons de diagnostic effacés.","Clear Buffers":"Effacer les tampons","Preparing...":"Préparation...","Preparing diagnostics...":"Préparation des diagnostics...","Export QC Diagnostics":"Exporter les diagnostics QC","Export Diagnostics Bundle":"Exporter le paquet de diagnostics","QC idle.":"QC inactif.","Are you sure to clear all data in the database?":"Voulez-vous vraiment effacer toutes les données de la base ?","Database cleared.":"Base de données effacée.",Module:"Module","Modules (Scroll to see more)":"Modules (faites défiler pour en voir plus)",About:"À propos",Version:"Version","Search...":"Rechercher...","Something went wrong.":"Une erreur est survenue.","Error:":"Erreur :","Captured:":"Capturé :","Rows per page:":"Lignes par page :","Relation Types":"Types de relation","Subject Accounts":"Comptes sujets","Subject User IDs":"ID utilisateur sujets","Last Observed At":"Dernière observation","A - B of N items":"{{from}} - {{to}} sur {{total}} éléments","No data available.":"Aucune donnée disponible.","No media available.":"Aucun média disponible.",Clear:"Effacer","Bookmark folders":"Dossiers de signets","1 folder selected":"1 dossier sélectionné","{{count}} folders selected":"{{count}} dossiers sélectionnés","Export Media":"Exporter les médias","Export Data":"Exporter les données","Export Search History":"Exporter l’historique de recherche","JSON View":"Vue JSON","Media View":"Vue média",Bookmarks:"Signets",Tweets:"Tweets",Users:"Utilisateurs","User Tweets":"Tweets utilisateur","User Media":"Médias utilisateur","Tweet Details":"Détails du tweet","Search Timeline":"Fil de recherche","Home Timeline":"Fil d’accueil","List Timeline":"Fil de liste","Community Timeline":"Fil de communauté","Community Members":"Membres de communauté","List Members":"Membres de liste","List Subscribers":"Abonnés de liste","Direct Messages":"Messages directs","Interaction Events":"Événements d’interaction","Local Search":"Recherche locale","Runtime Logs":"Journaux d’exécution","Bundle Viewer":"Visionneuse de paquets","{{count}} imported bundles":"{{count}} paquets importés","Search indexed tweets with Twitter-style operators":"Rechercher des tweets indexés avec des opérateurs de type Twitter","Local Recorder Search":"Recherche de l’enregistreur local",Quotes:"Citations",CommunityMembers:"Membres de communauté",CommunityTimeline:"Fil de communauté",DirectMessages:"Messages directs",Followers:"Abonnés",Following:"Abonnements",HomeTimeline:"Fil d’accueil",Likes:"J’aime",ListMembers:"Membres de liste",ListSubscribers:"Abonnés de liste",ListTimeline:"Fil de liste",InteractionEvents:"Événements d’interaction",LocalSearch:"Recherche locale",RawCapture:"Capture brute",Retweeters:"Retweeteurs",RetweetersModule:"Retweeteurs",RuntimeLogs:"Journaux d’exécution",SearchTimeline:"Fil de recherche",TweetIndex:"Index des tweets",TweetDetail:"Détail du tweet",UserDetail:"Détail utilisateur",UserMedia:"Médias utilisateur",UserTweets:"Tweets utilisateur",on:"activé",off:"désactivé",unknown:"inconnu",online:"en ligne",offline:"hors ligne",leader:"leader",follower:"suiveur",tab:"onglet",both:"les deux",xhr:"xhr",fetch:"fetch",watchdog:"watchdog",all:"tout",explicit:"explicite",loading:"chargement",complete:"terminé",idle:"inactif","api-name":"nom API","id-only":"ID seul","theme.system":"Système","theme.cupcake":"Clair","theme.dark":"Sombre","theme.emerald":"Emerald","theme.cyberpunk":"Cyberpunk","theme.valentine":"Valentine","theme.lofi":"Lo-fi","theme.dracula":"Dracula","theme.cmyk":"CMYK","theme.business":"Business","theme.winter":"Hiver","Safe mode":"Mode sûr","Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture.":"Désactive la capture par hooks lorsqu’il est activé. Désactivez-le pour la navigation normale et la capture diagnostique.","Hook mode":"Mode hook","Controls whether the userscript hooks XHR, fetch, both, or neither.":"Contrôle si le userscript hook XHR, fetch, les deux ou aucun.","Repair mode":"Mode réparation","Controls whether hook repair watchdog behavior is active.":"Contrôle si le watchdog de réparation des hooks est actif.","{{seconds}}s ago":"il y a {{seconds}} s","Hooks: {{status}}":"Hooks : {{status}}","Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})":"Hooks : xhr {{xhr}}, fetch {{fetch}}, dernier {{url}} ({{age}})","Hooks: xhr {{xhr}}, fetch {{fetch}}":"Hooks : xhr {{xhr}}, fetch {{fetch}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}":"Mode : sûr {{safe}}, hook {{hook}}, réparation {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}":"Mode : sûr {{safe}}, hook {{hook}}, réparation {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}","raw events: {{total}} | dropped: {{dropped}}":"événements raw : {{total}} | abandonnés : {{dropped}}","spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed":"spool : {{queued}} en file / {{enqueued}} enq / {{flushed}} vidés / {{failed}} échoués","spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms":"abandons par débordement spool : {{drops}} | indisponible : {{unavailable}} | plus ancien en attente : {{age}}ms","daemon: {{status}}":"daemon : {{status}}","daemon: {{status}} | last error: {{error}}":"daemon : {{status}} | dernière erreur : {{error}}","monitor: {{role}} | leader: {{leader}} | lease: {{lease}}":"monitor : {{role}} | leader : {{leader}} | bail : {{lease}}","monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}":"ticks monitor route/viewport : {{route}}/{{viewport}} | supprimés route/viewport : {{suppressedRoute}}/{{suppressedViewport}}","Database connected: {{name}}":"Base de données connectée : {{name}}","App options loaded":"Options de l’app chargées",'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)':'Rechercher avec opérateurs, phrases et logique booléenne : from:alice ("design system"~2 OR reliability)',"Search help":"Aide recherche","Clear search":"Effacer la recherche","Table view":"Vue tableau","Exit fullscreen":"Quitter le plein écran",Fullscreen:"Plein écran","{{view}} is disabled for large source-backed result sets.":"{{view}} est désactivé pour les grands ensembles basés sur source.","{{view}} view - {{status}}":"Vue {{view}} - {{status}}","{{view}} view":"Vue {{view}}","loading {{loaded}}/{{total}}":"chargement {{loaded}}/{{total}}","loading more {{loaded}}/{{total}}":"chargement supplémentaire {{loaded}}/{{total}}","searching {{matches}}/{{total}}":"recherche {{matches}}/{{total}}","matches {{matches}}/{{total}}":"résultats {{matches}}/{{total}}","rows {{loaded}}/{{total}}":"lignes {{loaded}}/{{total}}","rows {{count}}":"lignes {{count}}","buffering...":"mise en mémoire...","history {{count}}":"historique {{count}}","selected {{count}} ({{mode}})":"sélectionnés {{count}} ({{mode}})","rendered {{rendered}}/{{total}} (window {{start}}-{{end}})":"rendus {{rendered}}/{{total}} (fenêtre {{start}}-{{end}})","Search Operators":"Opérateurs de recherche","Query semantics now follow recorder-style precedence:":"La sémantique suit désormais la priorité style recorder :","with implicit":"avec","between adjacent terms.":"implicite entre termes adjacents.","search.category.lexical":"Lexical","search.category.identity":"Identité","search.category.metadata":"Métadonnées","search.category.presence":"Présence","search.category.numeric_date":"Numérique/date","search.category.compatibility":"Compatibilité","Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.":"Le texte non structuré est développé en correspondances de termes et en fenêtres de phrases adjacentes renforcées ; les mots de remplissage courants sont dépriorisés sauf s’ils sont entre guillemets.","Phrase search with optional slop.":"Recherche d’expression avec marge facultative.","Boolean operators with standard precedence and parentheses.":"Opérateurs booléens avec priorité standard et parenthèses.","Match the author handle or author id.":"Correspond au nom d’utilisateur ou à l’ID de l’auteur.","Shorthand for an enforced author constraint, equivalent to from:user.":"Raccourci pour une contrainte d’auteur obligatoire, équivalent à from:user.","Match reply targets, entity ids, or conversation ids.":"Correspond aux cibles de réponse, IDs d’entité ou IDs de conversation.","Match bookmark folder id or folder name.":"Correspond à l’ID ou au nom du dossier de signets.","Match language, route surface, source text, or card name.":"Correspond à la langue, à la surface de route, au texte source ou au nom de carte.","Match domains or URLs found in tweets.":"Correspond aux domaines ou URL trouvés dans les tweets.","Boolean state filters.":"Filtres d’état booléens.","Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.":"Filtres de présence pour médias, liens, mentions, hashtags, cashtags, engagement et sondages.","Compatibility aliases retained for Twitter-style queries.":"Alias de compatibilité conservés pour les requêtes de style Twitter.","Numeric threshold filters.":"Filtres de seuil numérique.","Date, timestamp, and Snowflake-style boundary filters.":"Filtres de limites par date, horodatage et style Snowflake.","Explicit mention filter plus shorthand hashtag and cashtag filters.":"Filtre de mention explicite avec raccourcis de hashtag et de cashtag.","Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.":"Recherche lexicale limitée à un champ sur des chemins imbriqués bruts, y compris chemins pointés et tableaux.","loading source {{scanned}}/{{total}}":"chargement source {{scanned}}/{{total}}","source {{status}} {{scanned}}/{{total}}":"source {{status}} {{scanned}}/{{total}}","media {{count}}":"médias {{count}}","loaded media {{count}}":"médias chargés {{count}}","source rows {{scanned}}/{{total}} {{status}}":"lignes source {{scanned}}/{{total}} {{status}}","source rows {{count}}":"lignes source {{count}}","layout {{columns}} cols @ {{width}}px":"disposition {{columns}} cols @ {{width}}px","original tweet attachments only":"pièces jointes du tweet original uniquement","Loading media.":"Chargement des médias.","Comfortable density":"Densité confortable","Compact density":"Densité compacte",Photo:"Photo",Video:"Vidéo","Open tweet":"Ouvrir le tweet","Export menu is open while remaining rows load in the background.":"Le menu d’export est ouvert pendant le chargement en arrière-plan des lignes restantes.","Wait for records to finish loading before exporting.":"Attendez la fin du chargement des enregistrements avant d’exporter.","Exports stream from the active source without loading all rows into the table.":"Exporte en flux depuis la source active sans charger toutes les lignes dans le tableau.","Opens immediately and loads remaining rows in the background.":"S’ouvre immédiatement et charge les lignes restantes en arrière-plan.","Export persisted bookmark search history":"Exporter l’historique de recherche de signets persistant","latest: {{latest}}\napi-name: {{apiName}}\nid-only: {{idOnly}}\nnone: {{none}}":`dernier : {{latest}}
nom-api : {{apiName}}
id-seul : {{idOnly}}
aucun : {{none}}`,"folder metadata: {{status}}":"métadonnées du dossier : {{status}}","Media export is disabled for large result sets until media export has a source-backed stream.":"L’export média est désactivé pour les grands résultats tant qu’un flux source n’est pas disponible.","App options migrated from v{{oldVersion}} to v{{newVersion}}":"Options migrées de v{{oldVersion}} vers v{{newVersion}}","Hooked into fetch":"Hook installé dans fetch","Hooked into XMLHttpRequest (installed={{installed}})":"Hook installé dans XMLHttpRequest (installed={{installed}})","Hook safe mode enabled ({{reason}})":"Mode sûr des hooks activé ({{reason}})","Hook repair failed ({{failures}}/{{limit}})":"Réparation du hook échouée ({{failures}}/{{limit}})","Bookmark context tracking install failed; continuing without tracker ({{details}})":"Installation du suivi de contexte des signets échouée ; poursuite sans tracker ({{details}})","TWE_DIAG {{phase}}":"TWE_DIAG {{phase}}","{{module}}: {{count}} items received":"{{module}} : {{count}} éléments reçus","Exporting to ZIP file: {{filename}}":"Export vers fichier ZIP : {{filename}}","Exporting to {{format}} file: {{filename}}":"Export vers fichier {{format}} : {{filename}}","Streaming export to {{format}} file: {{filename}}":"Export en flux vers fichier {{format}} : {{filename}}","Migration completed: {{users}} users and {{tweets}} tweets updated.":"Migration terminée : {{users}} utilisateurs et {{tweets}} tweets mis à jour.","TweetTombstone received (Reason: {{reason}})":"TweetTombstone reçu (Raison : {{reason}})","Failed to hook into XMLHttpRequest":"Échec du hook XMLHttpRequest","Fetch API not found, skipping fetch hooks":"API Fetch introuvable, hooks fetch ignorés","Fetch API base function unavailable or unsafe; enabling safe mode":"Fonction de base Fetch API indisponible ou dangereuse ; activation du mode sûr","Fetch hook base invocation failed; enabling safe mode":"Invocation de base du hook fetch échouée ; activation du mode sûr","XHR send hook base invocation failed; enabling safe mode":"Invocation de base du hook XHR send échouée ; activation du mode sûr","XHR open hook base invocation failed; enabling safe mode":"Invocation de base du hook XHR open échouée ; activation du mode sûr","Fetch hook already installed":"Hook fetch déjà installé","Debug mode enabled":"Mode debug activé","Database cleared":"Base de données effacée","Upgrading database schema...":"Mise à niveau du schéma de base de données...","Database upgraded":"Base de données mise à niveau","Zip stream closed.":"Flux ZIP fermé.","Running migration_20250609: Migrating legacy user data format":"Exécution de migration_20250609 : migration du format utilisateur hérité","TweetUnavailable received (Reason: unknown)":"TweetUnavailable reçu (Raison : inconnue)","Empty tweet received":"Tweet vide reçu","Unknown tweet type received":"Type de tweet inconnu reçu","Failed to extract tweet":"Échec de l’extraction du tweet","Failed to export file":"Échec de l’export du fichier","Failed to stream export file":"Échec de l’export du fichier en flux"}},Ib={exporter:{ID:"ID",Date:"दिनांक",Content:"सामग्री","Show Full Text":"पूरा पाठ दिखाएँ",Media:"मीडिया","Screen Name":"यूज़रनेम","Profile Name":"प्रोफ़ाइल नाम","Profile Image":"प्रोफ़ाइल छवि","User ID":"उपयोगकर्ता ID","Replying To":"जिसे उत्तर दे रहा है","RT Source":"RT स्रोत","Quote Source":"कोट स्रोत","Media Tags":"मीडिया टैग",Favorites:"पसंदीदा",Retweets:"रीट्वीट",Bookmarks:"बुकमार्क",Quotes:"कोट्स",Replies:"उत्तर",Views:"दृश्य",Favorited:"पसंदीदा किया गया",Retweeted:"रीट्वीट किया गया",Bookmarked:"बुकमार्क किया गया","Bookmark Folder":"बुकमार्क फ़ोल्डर",URL:"URL",Actions:"क्रियाएँ",Details:"विवरण",Description:"विवरण","Profile Banner":"प्रोफ़ाइल बैनर",Followers:"फ़ॉलोअर",FollowingCount:"फ़ॉलोइंग संख्या",Statuses:"पोस्ट",Favourites:"पसंदीदा",Listed:"सूचियों में",Location:"स्थान",Website:"वेबसाइट",Birthdate:"जन्म तिथि","Verified Type":"सत्यापन प्रकार","Blue Verified":"Blue सत्यापित",Following:"फ़ॉलो कर रहे हैं","Follows You":"आपको फ़ॉलो करता है","Can DM":"DM कर सकते हैं",Protected:"संरक्षित","Created At":"बनाया गया",Sender:"प्रेषक",Recipient:"प्राप्तकर्ता","Conversation ID":"वार्तालाप ID","Conversation Type":"वार्तालाप प्रकार",Data:"डेटा","Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.":"कैप्चर किए गए डेटा को JSON/HTML/CSV फ़ाइल के रूप में निर्यात करें। डेटा की मात्रा के अनुसार इसमें समय लग सकता है। निर्यात फ़ाइल में चित्र और वीडियो जैसी मीडिया फ़ाइलें शामिल नहीं होंगी, केवल उनके URL होंगे।","Data length:":"डेटा लंबाई:","Export scope:":"निर्यात दायरा:","All current results":"सभी मौजूदा परिणाम","Selected rows":"चयनित पंक्तियाँ","Pinned result set":"पिन किया गया परिणाम सेट",Query:"क्वेरी",Sort:"क्रम","Include all metadata:":"सारा मेटाडेटा शामिल करें:","Export as:":"इस रूप में निर्यात करें:","No data selected.":"कोई डेटा चयनित नहीं है।",Cancel:"रद्द करें","Start Export":"निर्यात शुरू करें","Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).":"कैप्चर किए गए डेटा से मीडिया फ़ाइलें डाउनलोड और सेव करें। डेटा की मात्रा के अनुसार इसमें समय लग सकता है। डाउनलोड में प्रोफ़ाइल छवियाँ, प्रोफ़ाइल बैनर (उपयोगकर्ताओं के लिए), छवियाँ और वीडियो (ट्वीट के लिए) शामिल होंगे।","For more than 100 media or large files, it is recommended to copy the URLs and download them with an external download manager such as aria2.":"100 से अधिक मीडिया या बड़ी फ़ाइलों के लिए URL कॉपी करके aria2 जैसे बाहरी डाउनलोड मैनेजर से डाउनलोड करना बेहतर है।","Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.":"ब्राउज़र ZIP निर्यात अब सीमित समानांतर डाउनलोड का उपयोग करता है। बहुत बड़े, वीडियो-भारी कार्यों के लिए URL या aria2 निर्यात अभी भी कम-मेमोरी वाला सबसे सुरक्षित रास्ता है।","Filename template:":"फ़ाइल नाम टेम्पलेट:","Download scheduler":"डाउनलोड शेड्यूलर","Faster defaults are intended for bulk CDN transfer.":"तेज़ डिफ़ॉल्ट बड़े CDN ट्रांसफ़र के लिए हैं।","Start delay (ms)":"आरंभ विलंब (ms)","Global parallel":"वैश्विक समानांतर","Per host":"प्रति होस्ट",Videos:"वीडियो",Retries:"पुनः प्रयास","Use aria2 format:":"aria2 प्रारूप इस्तेमाल करें:","Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2.":"अधिक जानकारी के लिए क्लिक करें। हर URL नई पंक्ति में होगा, और अगली पंक्ति में उसका फ़ाइल नाम होगा। यह प्रारूप aria2 के साथ संगत है।","Rate limit (ms):":"दर सीमा (ms):","Media Filter:":"मीडिया फ़िल्टर:","File Name":"फ़ाइल नाम","Media Type":"मीडिया प्रकार","Download URL":"डाउनलोड URL","No media selected.":"कोई मीडिया चयनित नहीं है।","Preview limited to first 250 media items.":"पूर्वावलोकन पहले 250 मीडिया आइटम तक सीमित है।",Zipping:"ZIP बनाया जा रहा है","Copied!":"कॉपी किया गया!","Copy URLs":"URL कॉपी करें","The tweet ID":"ट्वीट ID","The username of tweet author":"ट्वीट लेखक का यूज़रनेम","The profile name of tweet author":"ट्वीट लेखक का प्रोफ़ाइल नाम","The media index in tweet (start from 0)":"ट्वीट में मीडिया इंडेक्स (0 से शुरू)","The order of media in tweet (1/2/3/4)":"ट्वीट में मीडिया का क्रम (1/2/3/4)","The post date in YYYYMMDD format":"YYYYMMDD प्रारूप में पोस्ट दिनांक","The post time in HHmmss format":"HHmmss प्रारूप में पोस्ट समय","The media type (photo/video/animated_gif)":"मीडिया प्रकार (photo/video/animated_gif)","The file extension of media (jpg/png/mp4)":"मीडिया फ़ाइल एक्सटेंशन (jpg/png/mp4)","Failed to export media. Open DevTools for more details.":"मीडिया निर्यात विफल। अधिक जानकारी के लिए DevTools खोलें।","Failed to copy media URLs. Open DevTools for more details.":"मीडिया URL कॉपी करने में विफल। अधिक जानकारी के लिए DevTools खोलें।","filter.photo":"फ़ोटो","filter.video":"वीडियो","filter.animated_gif":"GIF","filter.retweet":"रीट्वीट शामिल करें","loading remaining rows":"बाकी पंक्तियाँ लोड हो रही हैं","Bundle ZIP compression:":"बंडल ZIP compression:","Fastest / store":"सबसे तेज़ / store","Balanced / fast":"संतुलित / तेज़","Smaller / slower":"छोटा / धीमा","Cancel Export":"निर्यात रद्द करें","Export a canonical portable ZIP bundle for sharing/importing.":"साझा/आयात करने के लिए canonical portable ZIP bundle निर्यात करें।","Export Bundle ZIP":"Bundle ZIP निर्यात करें","Source-backed media":"Source-backed मीडिया","rows scanned:":"स्कैन की गई पंक्तियाँ:","media URLs:":"मीडिया URL:",loading:"लोड हो रहा है","Loading media...":"मीडिया लोड हो रहा है..."},common:{"Open Control Panel":"कंट्रोल पैनल खोलें","Browse around to capture more data.":"अधिक डेटा कैप्चर करने के लिए ब्राउज़ करें।",Settings:"सेटिंग्स",General:"सामान्य",Theme:"थीम",Language:"भाषा",Debug:"डीबग","Date Time Format":"दिनांक और समय प्रारूप","Click for more information. This will take effect on both previewer and exported files.":"अधिक जानकारी के लिए क्लिक करें। यह प्रीव्यूअर और निर्यात की गई फ़ाइलों दोनों पर लागू होगा।","Use dedicated DB for accounts":"खातों के लिए अलग डेटाबेस इस्तेमाल करें","This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts.":"यह हर Twitter खाते के लिए अलग डेटाबेस बनाएगा, जिससे कई खाते इस्तेमाल करते समय डेटा मिल जाने की संभावना घटती है।","Local Database":"स्थानीय डेटाबेस","Analyze DB":"विश्लेषण","Export DB":"निर्यात","Clear DB":"साफ़ करें","Bundle Export":"बंडल निर्यात","Bundle Library":"बंडल लाइब्रेरी","QC Session":"QC सत्र","Diagnostic capture":"नैदानिक कैप्चर","Diagnostic buffers cleared.":"नैदानिक बफ़र साफ़ किए गए।","Clear Buffers":"बफ़र साफ़ करें","Preparing...":"तैयार हो रहा है...","Preparing diagnostics...":"डायग्नॉस्टिक्स तैयार हो रहे हैं...","Export QC Diagnostics":"QC डायग्नॉस्टिक्स निर्यात करें","Export Diagnostics Bundle":"डायग्नॉस्टिक्स बंडल निर्यात करें","QC idle.":"QC निष्क्रिय है।","Are you sure to clear all data in the database?":"क्या आप डेटाबेस का सारा डेटा साफ़ करना चाहते हैं?","Database cleared.":"डेटाबेस साफ़ कर दिया गया।",Module:"मॉड्यूल","Modules (Scroll to see more)":"मॉड्यूल (और देखने के लिए स्क्रॉल करें)",About:"परिचय",Version:"संस्करण","Search...":"खोजें...","Something went wrong.":"कुछ गलत हो गया।","Error:":"त्रुटि:","Captured:":"कैप्चर किया गया:","Rows per page:":"प्रति पृष्ठ पंक्तियाँ:","Relation Types":"संबंध प्रकार","Subject Accounts":"विषय खाते","Subject User IDs":"विषय उपयोगकर्ता ID","Last Observed At":"अंतिम बार देखा गया","A - B of N items":"{{total}} में से {{from}} - {{to}} आइटम","No data available.":"कोई डेटा उपलब्ध नहीं है।","No media available.":"कोई मीडिया उपलब्ध नहीं है।",Clear:"साफ़ करें","Bookmark folders":"बुकमार्क फ़ोल्डर","1 folder selected":"1 फ़ोल्डर चयनित","{{count}} folders selected":"{{count}} फ़ोल्डर चयनित","Export Media":"मीडिया निर्यात करें","Export Data":"डेटा निर्यात करें","Export Search History":"खोज इतिहास निर्यात करें","JSON View":"JSON दृश्य","Media View":"मीडिया दृश्य",Bookmarks:"बुकमार्क",Tweets:"ट्वीट",Users:"उपयोगकर्ता","User Tweets":"उपयोगकर्ता ट्वीट","User Media":"उपयोगकर्ता मीडिया","Tweet Details":"ट्वीट विवरण","Search Timeline":"खोज टाइमलाइन","Home Timeline":"होम टाइमलाइन","List Timeline":"सूची टाइमलाइन","Community Timeline":"समुदाय टाइमलाइन","Community Members":"समुदाय सदस्य","List Members":"सूची सदस्य","List Subscribers":"सूची सदस्यता लेने वाले","Direct Messages":"डायरेक्ट संदेश","Interaction Events":"इंटरैक्शन घटनाएँ","Local Search":"स्थानीय खोज","Runtime Logs":"रनटाइम लॉग","Bundle Viewer":"बंडल दर्शक","{{count}} imported bundles":"{{count}} आयातित बंडल","Search indexed tweets with Twitter-style operators":"Twitter-शैली ऑपरेटरों से इंडेक्स किए गए ट्वीट खोजें","Local Recorder Search":"स्थानीय रिकॉर्डर खोज",Quotes:"कोट्स",CommunityMembers:"समुदाय सदस्य",CommunityTimeline:"समुदाय टाइमलाइन",DirectMessages:"डायरेक्ट संदेश",Followers:"फ़ॉलोअर",Following:"फ़ॉलो कर रहे हैं",HomeTimeline:"होम टाइमलाइन",Likes:"लाइक",ListMembers:"सूची सदस्य",ListSubscribers:"सूची सदस्यता लेने वाले",ListTimeline:"सूची टाइमलाइन",InteractionEvents:"इंटरैक्शन घटनाएँ",LocalSearch:"स्थानीय खोज",RawCapture:"कच्चा कैप्चर",Retweeters:"रीट्वीट करने वाले",RetweetersModule:"रीट्वीट करने वाले",RuntimeLogs:"रनटाइम लॉग",SearchTimeline:"खोज टाइमलाइन",TweetIndex:"ट्वीट इंडेक्स",TweetDetail:"ट्वीट विवरण",UserDetail:"उपयोगकर्ता विवरण",UserMedia:"उपयोगकर्ता मीडिया",UserTweets:"उपयोगकर्ता ट्वीट",on:"चालू",off:"बंद",unknown:"अज्ञात",online:"ऑनलाइन",offline:"ऑफ़लाइन",leader:"लीडर",follower:"फ़ॉलोअर",tab:"टैब",both:"दोनों",xhr:"XHR",fetch:"fetch",watchdog:"वॉचडॉग",all:"सभी",explicit:"स्पष्ट",loading:"लोड हो रहा है",complete:"पूर्ण",idle:"निष्क्रिय","api-name":"API नाम","id-only":"केवल ID","theme.system":"सिस्टम","theme.cupcake":"हल्का","theme.dark":"गहरा","theme.emerald":"एमराल्ड","theme.cyberpunk":"साइबरपंक","theme.valentine":"वैलेंटाइन","theme.lofi":"Lo-fi","theme.dracula":"Dracula","theme.cmyk":"CMYK","theme.business":"व्यावसायिक","theme.winter":"सर्दी","Safe mode":"सुरक्षित मोड","Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture.":"सक्षम होने पर hook-आधारित कैप्चर बंद करता है। सामान्य ब्राउज़िंग और डायग्नॉस्टिक कैप्चर के लिए इसे बंद करें।","Hook mode":"Hook मोड","Controls whether the userscript hooks XHR, fetch, both, or neither.":"यह नियंत्रित करता है कि userscript XHR, fetch, दोनों या किसी को hook करे।","Repair mode":"मरम्मत मोड","Controls whether hook repair watchdog behavior is active.":"यह नियंत्रित करता है कि hook repair watchdog सक्रिय रहे या नहीं।","{{seconds}}s ago":"{{seconds}} सेकंड पहले","Hooks: {{status}}":"हुक:{{status}}","Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})":"हुक:xhr {{xhr}}, fetch {{fetch}}, अंतिम {{url}} ({{age}})","Hooks: xhr {{xhr}}, fetch {{fetch}}":"हुक:xhr {{xhr}}, fetch {{fetch}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}":"मोड: सुरक्षित {{safe}}, hook {{hook}}, मरम्मत {{repair}} | raw {{raw}}, spool {{spool}}, daemon: {{status}} {{daemon}}, monitor: {{role}} | लीडर: {{leader}} | lease: {{lease}} {{monitor}}, raw {{age}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}":"मोड: सुरक्षित {{safe}}, hook {{hook}}, मरम्मत {{repair}} | raw {{raw}}, spool {{spool}}, daemon: {{status}} {{daemon}}, monitor: {{role}} | लीडर: {{leader}} | lease: {{lease}} {{monitor}}","raw events: {{total}} | dropped: {{dropped}}":"raw घटनाएँ: {{total}} | छोड़ी गई: {{dropped}}","spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed":"spool: {{queued}} कतार में / {{enqueued}} जोड़े गए / {{flushed}} फ्लश / {{failed}} विफल","daemon: {{status}}":"डेमन:{{status}}","monitor: {{role}} | leader: {{leader}} | lease: {{lease}}":"मॉनिटर:{{role}} | लीडर:{{leader}} | lease:{{lease}}","Database connected: {{name}}":"डेटाबेस जुड़ा: {{name}}","App options loaded":"ऐप विकल्प लोड हुए",'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)':'ऑपरेटर, वाक्यांश और बूलियन लॉजिक से खोजें: from:alice ("design system"~2 OR reliability)',"Search help":"खोज सहायता","Clear search":"खोज साफ़ करें","Table view":"तालिका दृश्य","Exit fullscreen":"पूर्ण स्क्रीन से बाहर निकलें",Fullscreen:"पूर्ण स्क्रीन","{{view}} is disabled for large source-backed result sets.":"बड़े source-backed परिणाम सेट के लिए {{view}} अक्षम है।","{{view}} view - {{status}}":"{{view}} दृश्य - {{status}}","{{view}} view":"{{view}} दृश्य","loading {{loaded}}/{{total}}":"लोड हो रहा है {{loaded}}/{{total}}","loading more {{loaded}}/{{total}}":"और लोड हो रहा है {{loaded}}/{{total}}","searching {{matches}}/{{total}}":"खोज रहा है {{matches}}/{{total}}","matches {{matches}}/{{total}}":"मिलान {{matches}}/{{total}}","rows {{loaded}}/{{total}}":"पंक्तियाँ {{loaded}}/{{total}}","rows {{count}}":"पंक्तियाँ {{count}}","buffering...":"बफ़र हो रहा है...","history {{count}}":"इतिहास {{count}}","selected {{count}} ({{mode}})":"चयनित {{count}} ({{mode}})","rendered {{rendered}}/{{total}} (window {{start}}-{{end}})":"रेंडर {{rendered}}/{{total}} (विंडो {{start}}-{{end}})","Search Operators":"खोज ऑपरेटर","Query semantics now follow recorder-style precedence:":"क्वेरी semantics अब recorder-style precedence का पालन करती है:","with implicit":"निहित","between adjacent terms.":"आस-पास के शब्दों के बीच।","search.category.lexical":"शाब्दिक","search.category.identity":"पहचान","search.category.metadata":"मेटाडेटा","search.category.presence":"उपस्थिति","search.category.numeric_date":"संख्या/दिनांक","search.category.compatibility":"संगतता","Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.":"असंरचित पाठ सामग्री-शब्द मिलानों और बढ़े हुए आस-पास के वाक्यांश विंडो में फैलता है; उद्धरण न होने पर सामान्य भराव शब्दों की प्राथमिकता घटती है।","Phrase search with optional slop.":"वैकल्पिक slop के साथ वाक्यांश खोज।","Boolean operators with standard precedence and parentheses.":"मानक प्राथमिकता और कोष्ठकों वाले बूलियन ऑपरेटर।","Match the author handle or author id.":"लेखक हैंडल या लेखक ID मिलाएँ।","Shorthand for an enforced author constraint, equivalent to from:user.":"अनिवार्य लेखक बाधा का संक्षिप्त रूप, from:user के बराबर।","Match reply targets, entity ids, or conversation ids.":"उत्तर लक्ष्य, एंटिटी ID या बातचीत ID मिलाएँ।","Match bookmark folder id or folder name.":"बुकमार्क फ़ोल्डर ID या फ़ोल्डर नाम मिलाएँ।","Match language, route surface, source text, or card name.":"भाषा, रूट सतह, स्रोत पाठ या कार्ड नाम मिलाएँ।","Match domains or URLs found in tweets.":"ट्वीट में मिले डोमेन या URL मिलाएँ।","Boolean state filters.":"बूलियन स्थिति फ़िल्टर।","Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.":"मीडिया, लिंक, उल्लेख, हैशटैग, कैशटैग, एंगेजमेंट और पोल की उपस्थिति के फ़िल्टर।","Compatibility aliases retained for Twitter-style queries.":"Twitter-शैली क्वेरी के लिए रखे गए संगत alias।","Numeric threshold filters.":"संख्यात्मक सीमा फ़िल्टर।","Date, timestamp, and Snowflake-style boundary filters.":"दिनांक, टाइमस्टैम्प और Snowflake-शैली सीमा फ़िल्टर।","Explicit mention filter plus shorthand hashtag and cashtag filters.":"स्पष्ट mention फ़िल्टर और संक्षिप्त hashtag/cashtag फ़िल्टर।","Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.":"डॉटेड ऑब्जेक्ट पाथ और arrays सहित raw nested paths पर field-scoped lexical खोज।","loading source {{scanned}}/{{total}}":"source लोड हो रहा है {{scanned}}/{{total}}","source {{status}} {{scanned}}/{{total}}":"source {{status}} {{scanned}}/{{total}}","media {{count}}":"मीडिया {{count}}","loaded media {{count}}":"लोड मीडिया {{count}}","source rows {{scanned}}/{{total}} {{status}}":"source पंक्तियाँ {{scanned}}/{{total}} {{status}}","source rows {{count}}":"source पंक्तियाँ {{count}}","layout {{columns}} cols @ {{width}}px":"लेआउट {{columns}} कॉलम @ {{width}}px","original tweet attachments only":"केवल मूल ट्वीट attachments","Loading media.":"मीडिया लोड हो रहा है।","Comfortable density":"आरामदायक घनत्व","Compact density":"सघन घनत्व",Photo:"फ़ोटो",Video:"वीडियो","Open tweet":"ट्वीट खोलें","Export menu is open while remaining rows load in the background.":"निर्यात मेनू खुला है जबकि बाकी पंक्तियाँ पृष्ठभूमि में लोड हो रही हैं।","Wait for records to finish loading before exporting.":"निर्यात से पहले रिकॉर्ड लोड होने दें।","Exports stream from the active source without loading all rows into the table.":"सभी पंक्तियाँ तालिका में लोड किए बिना सक्रिय स्रोत से stream निर्यात करता है।","Opens immediately and loads remaining rows in the background.":"तुरंत खुलता है और बाकी पंक्तियाँ पृष्ठभूमि में लोड करता है।","Export persisted bookmark search history":"सहेजा गया बुकमार्क खोज इतिहास निर्यात करें","latest: {{latest}}\napi-name: {{apiName}}\nid-only: {{idOnly}}\nnone: {{none}}":`नवीनतम: {{latest}}
API नाम: {{apiName}}
केवल ID: {{idOnly}}
कोई नहीं: {{none}}`,"folder metadata: {{status}}":"फ़ोल्डर मेटाडेटा: {{status}}","Media export is disabled for large result sets until media export has a source-backed stream.":"बड़े परिणाम सेट के लिए मीडिया निर्यात तब तक अक्षम है जब तक source-backed stream उपलब्ध न हो।","Hooked into fetch":"fetch में hook किया गया","Hooked into XMLHttpRequest (installed={{installed}})":"XMLHttpRequest में hook किया गया (installed={{installed}})","TWE_DIAG {{phase}}":"TWE_DIAG {{phase}}","Hook safe mode enabled ({{reason}})":"Hook safe mode सक्षम हुआ ({{reason}})","Hook repair failed ({{failures}}/{{limit}})":"Hook मरम्मत विफल ({{failures}}/{{limit}})","Bookmark context tracking install failed; continuing without tracker ({{details}})":"Bookmark context tracking इंस्टॉल विफल; tracker के बिना जारी ({{details}})","{{module}}: {{count}} items received":"{{module}}: {{count}} आइटम प्राप्त हुए","Exporting to ZIP file: {{filename}}":"ZIP फ़ाइल में निर्यात: {{filename}}","Exporting to {{format}} file: {{filename}}":"{{format}} फ़ाइल में निर्यात: {{filename}}","Streaming export to {{format}} file: {{filename}}":"{{format}} फ़ाइल में streaming निर्यात: {{filename}}","Migration completed: {{users}} users and {{tweets}} tweets updated.":"माइग्रेशन पूर्ण: {{users}} उपयोगकर्ता और {{tweets}} ट्वीट अपडेट हुए।","TweetTombstone received (Reason: {{reason}})":"TweetTombstone प्राप्त हुआ (कारण: {{reason}})","Failed to hook into XMLHttpRequest":"XMLHttpRequest में hook करने में विफल","Fetch API not found, skipping fetch hooks":"Fetch API नहीं मिला, fetch hooks छोड़े जा रहे हैं","Fetch API base function unavailable or unsafe; enabling safe mode":"Fetch API base function अनुपलब्ध या असुरक्षित है; safe mode सक्षम हो रहा है","Fetch hook base invocation failed; enabling safe mode":"Fetch hook base invocation विफल; safe mode सक्षम हो रहा है","XHR send hook base invocation failed; enabling safe mode":"XHR send hook base invocation विफल; safe mode सक्षम हो रहा है","XHR open hook base invocation failed; enabling safe mode":"XHR open hook base invocation विफल; safe mode सक्षम हो रहा है","Fetch hook already installed":"Fetch hook पहले से इंस्टॉल है","Debug mode enabled":"Debug mode सक्षम","Database cleared":"डेटाबेस साफ़ किया गया","Upgrading database schema...":"डेटाबेस schema अपग्रेड हो रहा है...","Database upgraded":"डेटाबेस अपग्रेड हुआ","Zip stream closed.":"Zip stream बंद हुआ।","Running migration_20250609: Migrating legacy user data format":"migration_20250609 चल रहा है: legacy user data format माइग्रेट हो रहा है","TweetUnavailable received (Reason: unknown)":"TweetUnavailable प्राप्त हुआ (कारण: अज्ञात)","Empty tweet received":"खाली ट्वीट प्राप्त हुआ","Unknown tweet type received":"अज्ञात ट्वीट प्रकार प्राप्त हुआ","Failed to extract tweet":"ट्वीट निकालने में विफल","Failed to export file":"फ़ाइल निर्यात विफल","Failed to stream export file":"stream export फ़ाइल विफल","daemon: {{status}} | last error: {{error}}":"डेमन:{{status}} | अंतिम त्रुटि:{{error}}","spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms":"spool overflow drops: {{drops}} | अनुपलब्ध: {{unavailable}} | सबसे पुराना pending: {{age}}ms","monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}":"monitor ticks route/viewport: {{route}}/{{viewport}} | दबाए गए route/viewport: {{suppressedRoute}}/{{suppressedViewport}}","App options migrated from v{{oldVersion}} to v{{newVersion}}":"ऐप विकल्प v{{oldVersion}} से v{{newVersion}} में माइग्रेट हुए"}},Eb={exporter:{ID:"ID",Date:"Tanggal",Content:"Konten","Show Full Text":"Tampilkan teks lengkap",Media:"Media","Screen Name":"Nama pengguna","Profile Name":"Nama profil","Profile Image":"Gambar profil","User ID":"ID pengguna","Replying To":"Membalas ke","RT Source":"Sumber RT","Quote Source":"Sumber kutipan","Media Tags":"Tag media",Favorites:"Favorit",Retweets:"Retweet",Bookmarks:"Bookmark",Quotes:"Kutipan",Replies:"Balasan",Views:"Tayangan",Favorited:"Difavoritkan",Retweeted:"Di-retweet",Bookmarked:"Di-bookmark","Bookmark Folder":"Folder bookmark",URL:"URL",Actions:"Tindakan",Details:"Detail",Description:"Deskripsi","Profile Banner":"Banner profil",Followers:"Pengikut",FollowingCount:"Jumlah mengikuti",Statuses:"Postingan",Favourites:"Favorit",Listed:"Masuk daftar",Location:"Lokasi",Website:"Situs web",Birthdate:"Tanggal lahir","Verified Type":"Jenis verifikasi","Blue Verified":"Terverifikasi Blue",Following:"Mengikuti","Follows You":"Mengikuti Anda","Can DM":"Bisa DM",Protected:"Dilindungi","Created At":"Dibuat pada",Sender:"Pengirim",Recipient:"Penerima","Conversation ID":"ID percakapan","Conversation Type":"Jenis percakapan",Data:"Data","Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.":"Ekspor data yang ditangkap sebagai file JSON/HTML/CSV. Ini mungkin memerlukan waktu tergantung jumlah data. File ekspor tidak menyertakan file media seperti gambar dan video, hanya URL-nya.","Data length:":"Panjang data:","Export scope:":"Cakupan ekspor:","All current results":"Semua hasil saat ini","Selected rows":"Baris dipilih","Pinned result set":"Set hasil yang dipin",Query:"Kueri",Sort:"Urutkan","Include all metadata:":"Sertakan semua metadata:","Export as:":"Ekspor sebagai:","No data selected.":"Tidak ada data dipilih.",Cancel:"Batal","Start Export":"Mulai ekspor","Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).":"Unduh dan simpan file media dari data yang ditangkap. Ini mungkin memerlukan waktu tergantung jumlah data. Media yang diunduh mencakup gambar profil, banner profil (untuk pengguna), gambar, dan video (untuk tweet).","For more than 100 media or large files, it is recommended to copy the URLs and download them with an external download manager such as aria2.":"Untuk lebih dari 100 media atau file besar, disarankan menyalin URL dan mengunduhnya dengan pengelola unduhan eksternal seperti aria2.","Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.":"Ekspor ZIP browser sekarang menggunakan unduhan paralel terbatas. Untuk pekerjaan sangat besar dan banyak video, ekspor URL atau aria2 tetap jalur paling aman dengan memori rendah.","Filename template:":"Templat nama file:","Download scheduler":"Penjadwal unduhan","Faster defaults are intended for bulk CDN transfer.":"Default yang lebih cepat ditujukan untuk transfer massal CDN.","Start delay (ms)":"Jeda awal (ms)","Global parallel":"Paralel global","Per host":"Per host",Videos:"Video",Retries:"Coba lagi","Use aria2 format:":"Gunakan format aria2:","Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2.":"Klik untuk informasi lebih lanjut. Setiap URL akan berada di baris baru, dengan nama file di baris berikutnya. Format ini kompatibel dengan aria2.","Rate limit (ms):":"Batas laju (ms):","Media Filter:":"Filter media:","File Name":"Nama file","Media Type":"Jenis media","Download URL":"URL unduhan","No media selected.":"Tidak ada media dipilih.","Preview limited to first 250 media items.":"Pratinjau dibatasi pada 250 item media pertama.",Zipping:"Membuat ZIP","Copied!":"Disalin!","Copy URLs":"Salin URL","The tweet ID":"ID tweet","The username of tweet author":"Nama pengguna penulis tweet","The profile name of tweet author":"Nama profil penulis tweet","The media index in tweet (start from 0)":"Indeks media dalam tweet (mulai dari 0)","The order of media in tweet (1/2/3/4)":"Urutan media dalam tweet (1/2/3/4)","The post date in YYYYMMDD format":"Tanggal posting dalam format YYYYMMDD","The post time in HHmmss format":"Waktu posting dalam format HHmmss","The media type (photo/video/animated_gif)":"Jenis media (photo/video/animated_gif)","The file extension of media (jpg/png/mp4)":"Ekstensi file media (jpg/png/mp4)","Failed to export media. Open DevTools for more details.":"Gagal mengekspor media. Buka DevTools untuk detail.","Failed to copy media URLs. Open DevTools for more details.":"Gagal menyalin URL media. Buka DevTools untuk detail.","filter.photo":"Foto","filter.video":"Video","filter.animated_gif":"GIF","filter.retweet":"Sertakan retweet","loading remaining rows":"memuat baris tersisa","Bundle ZIP compression:":"Kompresi ZIP bundle:","Fastest / store":"Tercepat / simpan","Balanced / fast":"Seimbang / cepat","Smaller / slower":"Lebih kecil / lebih lambat","Cancel Export":"Batalkan ekspor","Export a canonical portable ZIP bundle for sharing/importing.":"Ekspor ZIP bundle portabel kanonis untuk berbagi/impor.","Export Bundle ZIP":"Ekspor ZIP bundle","Source-backed media":"Media berbasis sumber","rows scanned:":"baris dipindai:","media URLs:":"URL media:",loading:"memuat","Loading media...":"Memuat media..."},common:{"Open Control Panel":"Buka Panel Kontrol","Browse around to capture more data.":"Jelajahi halaman untuk menangkap lebih banyak data.",Settings:"Pengaturan",General:"Umum",Theme:"Tema",Language:"Bahasa",Debug:"Debug","Date Time Format":"Format Tanggal dan Waktu","Click for more information. This will take effect on both previewer and exported files.":"Klik untuk informasi lebih lanjut. Ini akan berlaku pada pratinjau dan file yang diekspor.","Use dedicated DB for accounts":"Gunakan DB khusus untuk akun","This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts.":"Ini akan membuat database terpisah untuk setiap akun Twitter, sehingga mengurangi kemungkinan data tercampur saat memakai beberapa akun.","Local Database":"Database lokal","Analyze DB":"Analisis","Export DB":"Ekspor","Clear DB":"Hapus","Bundle Export":"Ekspor bundel","Bundle Library":"Pustaka bundel","QC Session":"Sesi QC","Diagnostic capture":"Tangkapan diagnostik","Diagnostic buffers cleared.":"Buffer diagnostik dihapus.","Clear Buffers":"Hapus buffer","Preparing...":"Menyiapkan...","Preparing diagnostics...":"Menyiapkan diagnostik...","Export QC Diagnostics":"Ekspor diagnostik QC","Export Diagnostics Bundle":"Ekspor bundel diagnostik","QC idle.":"QC diam.","Are you sure to clear all data in the database?":"Yakin ingin menghapus semua data di database?","Database cleared.":"Database dihapus.",Module:"Modul","Modules (Scroll to see more)":"Modul (gulir untuk melihat lainnya)",About:"Tentang",Version:"Versi","Search...":"Cari...","Something went wrong.":"Terjadi kesalahan.","Error:":"Kesalahan:","Captured:":"Ditangkap:","Rows per page:":"Baris per halaman:","Relation Types":"Jenis relasi","Subject Accounts":"Akun subjek","Subject User IDs":"ID pengguna subjek","Last Observed At":"Terakhir diamati","A - B of N items":"{{from}} - {{to}} dari {{total}} item","No data available.":"Tidak ada data.","No media available.":"Tidak ada media.",Clear:"Bersihkan","Bookmark folders":"Folder bookmark","1 folder selected":"1 folder dipilih","{{count}} folders selected":"{{count}} folder dipilih","Export Media":"Ekspor media","Export Data":"Ekspor data","Export Search History":"Ekspor riwayat pencarian","JSON View":"Tampilan JSON","Media View":"Tampilan media",Bookmarks:"Bookmark",Tweets:"Tweet",Users:"Pengguna","User Tweets":"Tweet pengguna","User Media":"Media pengguna","Tweet Details":"Detail tweet","Search Timeline":"Linimasa pencarian","Home Timeline":"Linimasa beranda","List Timeline":"Linimasa daftar","Community Timeline":"Linimasa komunitas","Community Members":"Anggota komunitas","List Members":"Anggota daftar","List Subscribers":"Pelanggan daftar","Direct Messages":"Pesan langsung","Interaction Events":"Peristiwa interaksi","Local Search":"Pencarian lokal","Runtime Logs":"Log runtime","Bundle Viewer":"Penampil bundel","{{count}} imported bundles":"{{count}} bundel diimpor","Search indexed tweets with Twitter-style operators":"Cari tweet terindeks dengan operator gaya Twitter","Local Recorder Search":"Pencarian perekam lokal",Quotes:"Kutipan",CommunityMembers:"Anggota komunitas",CommunityTimeline:"Linimasa komunitas",DirectMessages:"Pesan langsung",Followers:"Pengikut",Following:"Mengikuti",HomeTimeline:"Linimasa beranda",Likes:"Suka",ListMembers:"Anggota daftar",ListSubscribers:"Pelanggan daftar",ListTimeline:"Linimasa daftar",InteractionEvents:"Peristiwa interaksi",LocalSearch:"Pencarian lokal",RawCapture:"Tangkapan mentah",Retweeters:"Pengguna yang me-retweet",RetweetersModule:"Pengguna yang me-retweet",RuntimeLogs:"Log runtime",SearchTimeline:"Pencarian",TweetIndex:"Indeks tweet",TweetDetail:"Detail tweet",UserDetail:"Detail pengguna",UserMedia:"Media pengguna",UserTweets:"Tweet pengguna",on:"aktif",off:"nonaktif",unknown:"tidak diketahui",online:"daring",offline:"luring",leader:"pemimpin",follower:"pengikut",tab:"tab",both:"keduanya",xhr:"xhr",fetch:"fetch",watchdog:"pengawas",all:"semua",explicit:"eksplisit",loading:"memuat",complete:"selesai",idle:"diam","api-name":"nama API","id-only":"hanya ID","theme.system":"Sistem","theme.cupcake":"Terang","theme.dark":"Gelap","theme.emerald":"Emerald","theme.cyberpunk":"Cyberpunk","theme.valentine":"Valentine","theme.lofi":"Lo-fi","theme.dracula":"Dracula","theme.cmyk":"CMYK","theme.business":"Bisnis","theme.winter":"Musim dingin","Safe mode":"Mode aman","Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture.":"Menonaktifkan capture berbasis hook saat aktif. Matikan untuk browsing normal dan capture diagnostik.","Hook mode":"Mode hook","Controls whether the userscript hooks XHR, fetch, both, or neither.":"Mengontrol apakah userscript memasang hook XHR, fetch, keduanya, atau tidak sama sekali.","Repair mode":"Mode perbaikan","Controls whether hook repair watchdog behavior is active.":"Mengontrol apakah watchdog perbaikan hook aktif.","{{seconds}}s ago":"{{seconds}} dtk lalu","Hooks: {{status}}":"Hook:{{status}}","Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})":"Hook:xhr {{xhr}}, fetch {{fetch}}, terakhir {{url}} ({{age}})","Hooks: xhr {{xhr}}, fetch {{fetch}}":"Hook:xhr {{xhr}}, fetch {{fetch}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}":"Mode: aman {{safe}}, hook {{hook}}, perbaikan {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}":"Mode: aman {{safe}}, hook {{hook}}, perbaikan {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}","raw events: {{total}} | dropped: {{dropped}}":"event raw: {{total}} | dibuang: {{dropped}}","spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed":"spool: {{queued}} memuat / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed","spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms":"drop overflow spool: {{drops}} | tidak tersedia: {{unavailable}} | pending tertua: {{age}}ms","daemon: {{status}}":"daemon:{{status}}","daemon: {{status}} | last error: {{error}}":"daemon:{{status}} | error terakhir:{{error}}","monitor: {{role}} | leader: {{leader}} | lease: {{lease}}":"monitor:{{role}} | pemimpin:{{leader}} | lease:{{lease}}","monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}":"tick monitor route/viewport: {{route}}/{{viewport}} | ditekan route/viewport: {{suppressedRoute}}/{{suppressedViewport}}","Database connected: {{name}}":"Database terhubung: {{name}}","App options loaded":"Opsi aplikasi dimuat",'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)':'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)',"Search help":"Search help","Clear search":"Clear search","Table view":"Table view","Exit fullscreen":"Exit fullscreen",Fullscreen:"Fullscreen","{{view}} is disabled for large source-backed result sets.":"{{view}} is disabled for large source-backed result sets.","{{view}} view - {{status}}":"{{view}} view - {{status}}","{{view}} view":"{{view}} view","loading {{loaded}}/{{total}}":"loading {{loaded}}/{{total}}","loading more {{loaded}}/{{total}}":"loading more {{loaded}}/{{total}}","searching {{matches}}/{{total}}":"searching {{matches}}/{{total}}","matches {{matches}}/{{total}}":"matches {{matches}}/{{total}}","rows {{loaded}}/{{total}}":"rows {{loaded}}/{{total}}","rows {{count}}":"rows {{count}}","buffering...":"buffering...","history {{count}}":"history {{count}}","selected {{count}} ({{mode}})":"selected {{count}} ({{mode}})","rendered {{rendered}}/{{total}} (window {{start}}-{{end}})":"rendered {{rendered}}/{{total}} (window {{start}}-{{end}})","Search Operators":"Search Operators","Query semantics now follow recorder-style precedence:":"Query semantics now follow recorder-style precedence:","with implicit":"with implicit","between adjacent terms.":"between adjacent terms.","search.category.lexical":"Lexical","search.category.identity":"Identity","search.category.metadata":"Metadata","search.category.presence":"Presence","search.category.numeric_date":"Numeric/date","search.category.compatibility":"Compatibility","Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.":"Teks tidak terstruktur diperluas menjadi kecocokan istilah konten dan jendela frasa berdekatan yang diberi bobot lebih; kata pengisi umum diturunkan prioritasnya kecuali diberi kutip.","Phrase search with optional slop.":"Pencarian frasa dengan slop opsional.","Boolean operators with standard precedence and parentheses.":"Operator boolean dengan prioritas standar dan tanda kurung.","Match the author handle or author id.":"Cocokkan handle penulis atau ID penulis.","Shorthand for an enforced author constraint, equivalent to from:user.":"Singkatan untuk batasan penulis wajib, setara dengan from:user.","Match reply targets, entity ids, or conversation ids.":"Cocokkan target balasan, ID entitas, atau ID percakapan.","Match bookmark folder id or folder name.":"Cocokkan ID folder bookmark atau nama folder.","Match language, route surface, source text, or card name.":"Cocokkan bahasa, permukaan rute, teks sumber, atau nama kartu.","Match domains or URLs found in tweets.":"Cocokkan domain atau URL yang ditemukan di tweet.","Boolean state filters.":"Filter status boolean.","Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.":"Filter keberadaan untuk media, tautan, mention, hashtag, cashtag, engagement, dan polling.","Compatibility aliases retained for Twitter-style queries.":"Alias kompatibilitas dipertahankan untuk kueri bergaya Twitter.","Numeric threshold filters.":"Filter ambang numerik.","Date, timestamp, and Snowflake-style boundary filters.":"Filter batas tanggal, timestamp, dan gaya Snowflake.","Explicit mention filter plus shorthand hashtag and cashtag filters.":"Filter mention eksplisit serta filter singkat hashtag dan cashtag.","Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.":"Pencarian leksikal berbatas field pada path bertingkat mentah, termasuk path objek bertitik dan array.","loading source {{scanned}}/{{total}}":"loading source {{scanned}}/{{total}}","source {{status}} {{scanned}}/{{total}}":"source {{status}} {{scanned}}/{{total}}","media {{count}}":"media {{count}}","loaded media {{count}}":"loaded media {{count}}","source rows {{scanned}}/{{total}} {{status}}":"source rows {{scanned}}/{{total}} {{status}}","source rows {{count}}":"source rows {{count}}","layout {{columns}} cols @ {{width}}px":"layout {{columns}} cols @ {{width}}px","original tweet attachments only":"original tweet attachments only","Loading media.":"Loading media.","Comfortable density":"Comfortable density","Compact density":"Compact density",Photo:"Photo",Video:"Video","Open tweet":"Open tweet","Export menu is open while remaining rows load in the background.":"Export menu is open while remaining rows load in the background.","Wait for records to finish loading before exporting.":"Wait for records to finish loading before exporting.","Exports stream from the active source without loading all rows into the table.":"Exports stream from the active source without loading all rows into the table.","Opens immediately and loads remaining rows in the background.":"Opens immediately and loads remaining rows in the background.","Export persisted bookmark search history":"Export persisted bookmark search history","latest: {{latest}}\napi-name: {{apiName}}\nid-only: {{idOnly}}\nnone: {{none}}":`latest: {{latest}}
api-name: {{apiName}}
id-only: {{idOnly}}
none: {{none}}`,"folder metadata: {{status}}":"folder metadata: {{status}}","Media export is disabled for large result sets until media export has a source-backed stream.":"Media export is disabled for large result sets until media export has a source-backed stream.","App options migrated from v{{oldVersion}} to v{{newVersion}}":"Opsi aplikasi dimigrasi dari v{{oldVersion}} ke v{{newVersion}}","Hooked into fetch":"Hook terpasang ke fetch","Hooked into XMLHttpRequest (installed={{installed}})":"Hook terpasang ke XMLHttpRequest (installed={{installed}})","Hook safe mode enabled ({{reason}})":"Mode aman hook diaktifkan ({{reason}})","Hook repair failed ({{failures}}/{{limit}})":"Perbaikan hook gagal ({{failures}}/{{limit}})","Bookmark context tracking install failed; continuing without tracker ({{details}})":"Instalasi pelacak konteks bookmark gagal; lanjut tanpa pelacak ({{details}})","TWE_DIAG {{phase}}":"TWE_DIAG {{phase}}","{{module}}: {{count}} items received":"{{module}}: {{count}} item diterima","Exporting to ZIP file: {{filename}}":"Mengekspor ke file ZIP: {{filename}}","Exporting to {{format}} file: {{filename}}":"Mengekspor ke file {{format}}: {{filename}}","Streaming export to {{format}} file: {{filename}}":"Ekspor streaming ke file {{format}}: {{filename}}","Migration completed: {{users}} users and {{tweets}} tweets updated.":"Migrasi selesai: {{users}} pengguna dan {{tweets}} tweet diperbarui.","TweetTombstone received (Reason: {{reason}})":"TweetTombstone diterima (Alasan: {{reason}})","Failed to hook into XMLHttpRequest":"Gagal memasang hook ke XMLHttpRequest","Fetch API not found, skipping fetch hooks":"Fetch API tidak ditemukan, melewati hook fetch","Fetch API base function unavailable or unsafe; enabling safe mode":"Fungsi dasar Fetch API tidak tersedia atau tidak aman; mengaktifkan mode aman","Fetch hook base invocation failed; enabling safe mode":"Invokasi dasar hook fetch gagal; mengaktifkan mode aman","XHR send hook base invocation failed; enabling safe mode":"Invokasi dasar hook XHR send gagal; mengaktifkan mode aman","XHR open hook base invocation failed; enabling safe mode":"Invokasi dasar hook XHR open gagal; mengaktifkan mode aman","Fetch hook already installed":"Hook fetch sudah terpasang","Debug mode enabled":"Mode debug aktif","Database cleared":"Database dibersihkan","Upgrading database schema...":"Memutakhirkan skema database...","Database upgraded":"Database dimutakhirkan","Zip stream closed.":"Stream ZIP ditutup.","Running migration_20250609: Migrating legacy user data format":"Menjalankan migration_20250609: migrasi format data pengguna lama","TweetUnavailable received (Reason: unknown)":"TweetUnavailable diterima (Alasan: tidak diketahui)","Empty tweet received":"Tweet kosong diterima","Unknown tweet type received":"Jenis tweet tidak dikenal diterima","Failed to extract tweet":"Gagal mengekstrak tweet","Failed to export file":"Gagal mengekspor file","Failed to stream export file":"Gagal mengekspor file streaming"}},Ab={exporter:{ID:"ID",Date:"日付",Content:"内容","Show Full Text":"全文を表示",Media:"メディア","Screen Name":"ユーザー名","Profile Name":"プロフィール名","Profile Image":"プロフィール画像","User ID":"ユーザーID","Replying To":"返信先","RT Source":"RT元","Quote Source":"引用元","Media Tags":"メディアタグ",Favorites:"お気に入り",Retweets:"リツイート",Bookmarks:"ブックマーク",Quotes:"引用",Replies:"返信",Views:"表示回数",Favorited:"お気に入り済み",Retweeted:"リツイート済み",Bookmarked:"ブックマーク済み","Bookmark Folder":"ブックマークフォルダ",URL:"URL",Actions:"操作",Details:"詳細",Description:"説明","Profile Banner":"プロフィールバナー",Followers:"フォロワー",FollowingCount:"フォロー数",Statuses:"投稿数",Favourites:"お気に入り",Listed:"リスト登録数",Location:"場所",Website:"Webサイト",Birthdate:"生年月日","Verified Type":"認証タイプ","Blue Verified":"Blue認証",Following:"フォロー中","Follows You":"あなたをフォロー","Can DM":"DM可能",Protected:"非公開","Created At":"作成日時",Sender:"送信者",Recipient:"受信者","Conversation ID":"会話ID","Conversation Type":"会話タイプ",Data:"データ","Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.":"取得したデータをJSON/HTML/CSVファイルとしてエクスポートします。データ量によって時間がかかる場合があります。エクスポートファイルには画像や動画などのメディアファイルは含まれず、URLのみが含まれます。","Data length:":"データ件数:","Export scope:":"エクスポート範囲:","All current results":"現在の全結果","Selected rows":"選択した行","Pinned result set":"固定された結果セット",Query:"クエリ",Sort:"並び順","Include all metadata:":"すべてのメタデータを含める:","Export as:":"形式:","No data selected.":"データが選択されていません。",Cancel:"キャンセル","Start Export":"エクスポート開始","Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).":"取得データからメディアファイルをダウンロードして保存します。データ量によって時間がかかる場合があります。ダウンロード対象にはプロフィール画像、プロフィールバナー(ユーザー)、画像、動画(ツイート)が含まれます。","For more than 100 media or large files, it is recommended to copy the URLs and download them with an external download manager such as aria2.":"100件を超えるメディアや大きなファイルでは、URLをコピーし、aria2などの外部ダウンロードマネージャーでダウンロードすることを推奨します。","Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.":"ブラウザのZIPエクスポートは、制限付き並列ダウンロードを使用するようになりました。非常に大きく動画の多い処理では、URLまたはaria2エクスポートが引き続き最も安全で低メモリな方法です。","Filename template:":"ファイル名テンプレート:","Download scheduler":"ダウンロードスケジューラ","Faster defaults are intended for bulk CDN transfer.":"高速な初期値はCDNからの一括転送向けです。","Start delay (ms)":"開始遅延 (ms)","Global parallel":"全体並列数","Per host":"ホストごと",Videos:"動画",Retries:"再試行","Use aria2 format:":"aria2形式を使用:","Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2.":"詳細を確認するにはクリックしてください。各URLは新しい行に、その次の行にファイル名が出力されます。この形式はaria2と互換性があります。","Rate limit (ms):":"レート制限 (ms):","Media Filter:":"メディアフィルター:","File Name":"ファイル名","Media Type":"メディアタイプ","Download URL":"ダウンロードURL","No media selected.":"メディアが選択されていません。","Preview limited to first 250 media items.":"プレビューは最初の250件のメディアに制限されています。",Zipping:"ZIP作成中","Copied!":"コピーしました!","Copy URLs":"URLをコピー","The tweet ID":"ツイートID","The username of tweet author":"ツイート投稿者のユーザー名","The profile name of tweet author":"ツイート投稿者のプロフィール名","The media index in tweet (start from 0)":"ツイート内のメディアインデックス(0から開始)","The order of media in tweet (1/2/3/4)":"ツイート内のメディア順序(1/2/3/4)","The post date in YYYYMMDD format":"YYYYMMDD形式の投稿日","The post time in HHmmss format":"HHmmss形式の投稿時刻","The media type (photo/video/animated_gif)":"メディアタイプ(photo/video/animated_gif)","The file extension of media (jpg/png/mp4)":"メディアファイル拡張子(jpg/png/mp4)","Failed to export media. Open DevTools for more details.":"メディアのエクスポートに失敗しました。詳細はDevToolsを開いてください。","Failed to copy media URLs. Open DevTools for more details.":"メディアURLのコピーに失敗しました。詳細はDevToolsを開いてください。","filter.photo":"写真","filter.video":"動画","filter.animated_gif":"GIF","filter.retweet":"リツイートを含める","loading remaining rows":"残りの行を読み込み中","Bundle ZIP compression:":"バンドル ZIP 圧縮:","Fastest / store":"最速 / store","Balanced / fast":"バランス / 高速","Smaller / slower":"小さめ / 低速","Cancel Export":"エクスポートをキャンセル","Export a canonical portable ZIP bundle for sharing/importing.":"共有/インポート用の正規ポータブル ZIP バンドルをエクスポートします。","Export Bundle ZIP":"バンドル ZIP をエクスポート","Source-backed media":"ソース対応メディア","rows scanned:":"スキャン済み行:","media URLs:":"メディア URL:",loading:"読み込み中","Loading media...":"メディアを読み込み中..."},common:{"Open Control Panel":"コントロールパネルを開く","Browse around to capture more data.":"ページを閲覧して、さらにデータを取得します。",Settings:"設定",General:"一般",Theme:"テーマ",Language:"言語",Debug:"デバッグ","Date Time Format":"日時形式","Click for more information. This will take effect on both previewer and exported files.":"詳細を確認するにはクリックしてください。これはプレビューとエクスポートファイルの両方に適用されます。","Use dedicated DB for accounts":"アカウントごとに専用DBを使用","This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts.":"Twitterアカウントごとに別々のデータベースを作成します。複数アカウント使用時のデータ混在を減らせます。","Local Database":"ローカルデータベース","Analyze DB":"分析","Export DB":"エクスポート","Clear DB":"削除","Bundle Export":"バンドルをエクスポート","Bundle Library":"バンドルライブラリ","QC Session":"QCセッション","Diagnostic capture":"診断キャプチャ","Diagnostic buffers cleared.":"診断バッファをクリアしました。","Clear Buffers":"バッファをクリア","Preparing...":"準備中...","Preparing diagnostics...":"診断を準備中...","Export QC Diagnostics":"QC診断をエクスポート","Export Diagnostics Bundle":"診断バンドルをエクスポート","QC idle.":"QCは待機中です。","Are you sure to clear all data in the database?":"データベース内のすべてのデータを削除しますか?","Database cleared.":"データベースを削除しました。",Module:"モジュール","Modules (Scroll to see more)":"モジュール(スクロールしてさらに表示)",About:"情報",Version:"バージョン","Search...":"検索...","Something went wrong.":"問題が発生しました。","Error:":"エラー:","Captured:":"取得済み:","Rows per page:":"ページあたりの行数:","Relation Types":"関係タイプ","Subject Accounts":"対象アカウント","Subject User IDs":"対象ユーザーID","Last Observed At":"最終観測日時","A - B of N items":"{{total}}件中 {{from}} - {{to}} 件","No data available.":"データがありません。","No media available.":"メディアがありません。",Clear:"クリア","Bookmark folders":"ブックマークフォルダ","1 folder selected":"1個のフォルダを選択中","{{count}} folders selected":"{{count}}個のフォルダを選択中","Export Media":"メディアをエクスポート","Export Data":"データをエクスポート","Export Search History":"検索履歴をエクスポート","JSON View":"JSON表示","Media View":"メディア表示",Bookmarks:"ブックマーク",Tweets:"ツイート",Users:"ユーザー","User Tweets":"ユーザーのツイート","User Media":"ユーザーメディア","Tweet Details":"ツイート詳細","Search Timeline":"検索タイムライン","Home Timeline":"ホームタイムライン","List Timeline":"リストタイムライン","Community Timeline":"コミュニティタイムライン","Community Members":"コミュニティメンバー","List Members":"リストメンバー","List Subscribers":"リスト購読者","Direct Messages":"ダイレクトメッセージ","Interaction Events":"インタラクションイベント","Local Search":"ローカル検索","Runtime Logs":"ランタイムログ","Bundle Viewer":"バンドルビューア","{{count}} imported bundles":"{{count}}個のバンドルをインポート済み","Search indexed tweets with Twitter-style operators":"Twitter風の演算子でインデックス済みツイートを検索","Local Recorder Search":"ローカルレコーダー検索",Quotes:"引用",CommunityMembers:"コミュニティメンバー",CommunityTimeline:"コミュニティタイムライン",DirectMessages:"ダイレクトメッセージ",Followers:"フォロワー",Following:"フォロー中",HomeTimeline:"ホームタイムライン",Likes:"いいね",ListMembers:"リストメンバー",ListSubscribers:"リスト購読者",ListTimeline:"リストタイムライン",InteractionEvents:"インタラクションイベント",LocalSearch:"ローカル検索",RawCapture:"生キャプチャ",Retweeters:"リツイートしたユーザー",RetweetersModule:"リツイートしたユーザー",RuntimeLogs:"ランタイムログ",SearchTimeline:"検索",TweetIndex:"ツイートインデックス",TweetDetail:"ツイート詳細",UserDetail:"ユーザー詳細",UserMedia:"ユーザーメディア",UserTweets:"ユーザーのツイート",on:"オン",off:"オフ",unknown:"不明",online:"オンライン",offline:"オフライン",leader:"リーダー",follower:"フォロワー",tab:"タブ",both:"両方",xhr:"xhr",fetch:"fetch",watchdog:"ウォッチドッグ",all:"すべて",explicit:"明示",loading:"読み込み中",complete:"完了",idle:"アイドル","api-name":"API 名","id-only":"ID のみ","theme.system":"システム","theme.cupcake":"ライト","theme.dark":"ダーク","theme.emerald":"Emerald","theme.cyberpunk":"Cyberpunk","theme.valentine":"Valentine","theme.lofi":"Lo-fi","theme.dracula":"Dracula","theme.cmyk":"CMYK","theme.business":"ビジネス","theme.winter":"冬","Safe mode":"セーフモード","Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture.":"有効時は hook ベースのキャプチャを無効にします。通常の閲覧と診断キャプチャではオフにしてください。","Hook mode":"Hook モード","Controls whether the userscript hooks XHR, fetch, both, or neither.":"userscript が XHR、fetch、両方、またはどちらも hook しないかを制御します。","Repair mode":"修復モード","Controls whether hook repair watchdog behavior is active.":"hook 修復 watchdog の有効/無効を制御します。","{{seconds}}s ago":"{{seconds}} 秒前","Hooks: {{status}}":"フック:{{status}}","Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})":"フック:xhr {{xhr}}, fetch {{fetch}}, 最後 {{url}} ({{age}})","Hooks: xhr {{xhr}}, fetch {{fetch}}":"フック:xhr {{xhr}}, fetch {{fetch}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}":"モード: 安全 {{safe}}, hook {{hook}}, 修復 {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}":"モード: 安全 {{safe}}, hook {{hook}}, 修復 {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}","raw events: {{total}} | dropped: {{dropped}}":"raw イベント: {{total}} | 破棄: {{dropped}}","spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed":"spool: {{queued}} 読み込み中 / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed","spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms":"spool オーバーフロー破棄: {{drops}} | 利用不可: {{unavailable}} | 最古 pending: {{age}}ms","daemon: {{status}}":"デーモン:{{status}}","daemon: {{status}} | last error: {{error}}":"デーモン:{{status}} | 最後のエラー:{{error}}","monitor: {{role}} | leader: {{leader}} | lease: {{lease}}":"モニター:{{role}} | リーダー:{{leader}} | lease:{{lease}}","monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}":"monitor tick route/viewport: {{route}}/{{viewport}} | 抑制 route/viewport: {{suppressedRoute}}/{{suppressedViewport}}","Database connected: {{name}}":"データベース接続済み: {{name}}","App options loaded":"アプリオプションを読み込みました",'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)':'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)',"Search help":"Search help","Clear search":"Clear search","Table view":"Table view","Exit fullscreen":"Exit fullscreen",Fullscreen:"Fullscreen","{{view}} is disabled for large source-backed result sets.":"{{view}} is disabled for large source-backed result sets.","{{view}} view - {{status}}":"{{view}} view - {{status}}","{{view}} view":"{{view}} view","loading {{loaded}}/{{total}}":"loading {{loaded}}/{{total}}","loading more {{loaded}}/{{total}}":"loading more {{loaded}}/{{total}}","searching {{matches}}/{{total}}":"searching {{matches}}/{{total}}","matches {{matches}}/{{total}}":"matches {{matches}}/{{total}}","rows {{loaded}}/{{total}}":"rows {{loaded}}/{{total}}","rows {{count}}":"rows {{count}}","buffering...":"buffering...","history {{count}}":"history {{count}}","selected {{count}} ({{mode}})":"selected {{count}} ({{mode}})","rendered {{rendered}}/{{total}} (window {{start}}-{{end}})":"rendered {{rendered}}/{{total}} (window {{start}}-{{end}})","Search Operators":"Search Operators","Query semantics now follow recorder-style precedence:":"Query semantics now follow recorder-style precedence:","with implicit":"with implicit","between adjacent terms.":"between adjacent terms.","search.category.lexical":"Lexical","search.category.identity":"Identity","search.category.metadata":"Metadata","search.category.presence":"Presence","search.category.numeric_date":"Numeric/date","search.category.compatibility":"Compatibility","Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.":"非構造テキストはコンテンツ語の一致と強化された隣接フレーズ窓に展開されます。引用符で囲まれていない一般的な埋め草語は優先度が下がります。","Phrase search with optional slop.":"任意の slop を指定できるフレーズ検索。","Boolean operators with standard precedence and parentheses.":"標準の優先順位と括弧に対応したブール演算子。","Match the author handle or author id.":"作者のハンドルまたは作者 ID に一致します。","Shorthand for an enforced author constraint, equivalent to from:user.":"必須の作者条件の短縮形で、from:user と同等です。","Match reply targets, entity ids, or conversation ids.":"返信先、エンティティ ID、会話 ID に一致します。","Match bookmark folder id or folder name.":"ブックマークフォルダ ID またはフォルダ名に一致します。","Match language, route surface, source text, or card name.":"言語、ルート面、ソーステキスト、カード名に一致します。","Match domains or URLs found in tweets.":"ツイート内のドメインまたは URL に一致します。","Boolean state filters.":"ブール状態フィルター。","Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.":"メディア、リンク、メンション、ハッシュタグ、キャッシュタグ、エンゲージメント、投票の有無フィルター。","Compatibility aliases retained for Twitter-style queries.":"Twitter 形式のクエリ向けに保持された互換エイリアス。","Numeric threshold filters.":"数値しきい値フィルター。","Date, timestamp, and Snowflake-style boundary filters.":"日付、タイムスタンプ、Snowflake 形式の境界フィルター。","Explicit mention filter plus shorthand hashtag and cashtag filters.":"明示的なメンションフィルターと、ハッシュタグ/キャッシュタグの短縮フィルター。","Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.":"ドット区切りのオブジェクトパスや配列を含む raw のネストパスに対するフィールド限定の語彙検索。","loading source {{scanned}}/{{total}}":"loading source {{scanned}}/{{total}}","source {{status}} {{scanned}}/{{total}}":"source {{status}} {{scanned}}/{{total}}","media {{count}}":"media {{count}}","loaded media {{count}}":"loaded media {{count}}","source rows {{scanned}}/{{total}} {{status}}":"source rows {{scanned}}/{{total}} {{status}}","source rows {{count}}":"source rows {{count}}","layout {{columns}} cols @ {{width}}px":"layout {{columns}} cols @ {{width}}px","original tweet attachments only":"original tweet attachments only","Loading media.":"Loading media.","Comfortable density":"Comfortable density","Compact density":"Compact density",Photo:"Photo",Video:"Video","Open tweet":"Open tweet","Export menu is open while remaining rows load in the background.":"Export menu is open while remaining rows load in the background.","Wait for records to finish loading before exporting.":"Wait for records to finish loading before exporting.","Exports stream from the active source without loading all rows into the table.":"Exports stream from the active source without loading all rows into the table.","Opens immediately and loads remaining rows in the background.":"Opens immediately and loads remaining rows in the background.","Export persisted bookmark search history":"Export persisted bookmark search history","latest: {{latest}}\napi-name: {{apiName}}\nid-only: {{idOnly}}\nnone: {{none}}":`latest: {{latest}}
api-name: {{apiName}}
id-only: {{idOnly}}
none: {{none}}`,"folder metadata: {{status}}":"folder metadata: {{status}}","Media export is disabled for large result sets until media export has a source-backed stream.":"Media export is disabled for large result sets until media export has a source-backed stream.","App options migrated from v{{oldVersion}} to v{{newVersion}}":"アプリオプションを v{{oldVersion}} から v{{newVersion}} に移行しました","Hooked into fetch":"fetch に hook しました","Hooked into XMLHttpRequest (installed={{installed}})":"XMLHttpRequest に hook しました (installed={{installed}})","Hook safe mode enabled ({{reason}})":"Hook セーフモードを有効化しました ({{reason}})","Hook repair failed ({{failures}}/{{limit}})":"Hook 修復に失敗しました ({{failures}}/{{limit}})","Bookmark context tracking install failed; continuing without tracker ({{details}})":"ブックマークコンテキスト追跡のインストールに失敗しました。トラッカーなしで続行します ({{details}})","TWE_DIAG {{phase}}":"TWE_DIAG {{phase}}","{{module}}: {{count}} items received":"{{module}}: {{count}} 件を受信","Exporting to ZIP file: {{filename}}":"ZIP ファイルへエクスポート: {{filename}}","Exporting to {{format}} file: {{filename}}":"{{format}} ファイルへエクスポート: {{filename}}","Streaming export to {{format}} file: {{filename}}":"{{format}} ファイルへストリーミングエクスポート: {{filename}}","Migration completed: {{users}} users and {{tweets}} tweets updated.":"移行完了: {{users}} ユーザーと {{tweets}} ツイートを更新しました。","TweetTombstone received (Reason: {{reason}})":"TweetTombstone を受信しました (理由: {{reason}})","Failed to hook into XMLHttpRequest":"XMLHttpRequest への hook に失敗しました","Fetch API not found, skipping fetch hooks":"Fetch API が見つからないため fetch hooks をスキップします","Fetch API base function unavailable or unsafe; enabling safe mode":"Fetch API のベース関数が利用不可または安全でないためセーフモードを有効化します","Fetch hook base invocation failed; enabling safe mode":"fetch hook のベース呼び出しに失敗したためセーフモードを有効化します","XHR send hook base invocation failed; enabling safe mode":"XHR send hook のベース呼び出しに失敗したためセーフモードを有効化します","XHR open hook base invocation failed; enabling safe mode":"XHR open hook のベース呼び出しに失敗したためセーフモードを有効化します","Fetch hook already installed":"fetch hook は既にインストール済みです","Debug mode enabled":"デバッグモード有効","Database cleared":"データベースを消去しました","Upgrading database schema...":"データベーススキーマをアップグレード中...","Database upgraded":"データベースをアップグレードしました","Zip stream closed.":"ZIP ストリームを閉じました。","Running migration_20250609: Migrating legacy user data format":"migration_20250609 実行中: レガシーユーザーデータ形式を移行しています","TweetUnavailable received (Reason: unknown)":"TweetUnavailable を受信しました (理由: 不明)","Empty tweet received":"空のツイートを受信しました","Unknown tweet type received":"不明なツイートタイプを受信しました","Failed to extract tweet":"ツイート抽出に失敗しました","Failed to export file":"ファイルのエクスポートに失敗しました","Failed to stream export file":"ストリームエクスポートファイルに失敗しました"}},Db={exporter:{ID:"ID",Date:"Data",Content:"Conteúdo","Show Full Text":"Mostrar texto completo",Media:"Mídia","Screen Name":"Nome de usuário","Profile Name":"Nome do perfil","Profile Image":"Imagem do perfil","User ID":"ID do usuário","Replying To":"Respondendo a","RT Source":"Fonte do RT","Quote Source":"Fonte da citação","Media Tags":"Tags de mídia",Favorites:"Favoritos",Retweets:"Retweets",Bookmarks:"Favoritos",Quotes:"Citações",Replies:"Respostas",Views:"Visualizações",Favorited:"Favoritado",Retweeted:"Retweetado",Bookmarked:"Salvo nos favoritos","Bookmark Folder":"Pasta de favoritos",URL:"URL",Actions:"Ações",Details:"Detalhes",Description:"Descrição","Profile Banner":"Banner do perfil",Followers:"Seguidores",FollowingCount:"Contagem de seguindo",Statuses:"Publicações",Favourites:"Favoritos",Listed:"Em listas",Location:"Localização",Website:"Site",Birthdate:"Data de nascimento","Verified Type":"Tipo de verificação","Blue Verified":"Verificado Blue",Following:"Seguindo","Follows You":"Segue você","Can DM":"Pode receber DM",Protected:"Protegido","Created At":"Criado em",Sender:"Remetente",Recipient:"Destinatário","Conversation ID":"ID da conversa","Conversation Type":"Tipo de conversa",Data:"Dados","Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.":"Exporte os dados capturados como arquivo JSON/HTML/CSV. Isso pode demorar conforme a quantidade de dados. O arquivo exportado não inclui arquivos de mídia, como imagens e vídeos, apenas as URLs.","Data length:":"Tamanho dos dados:","Export scope:":"Escopo da exportação:","All current results":"Todos os resultados atuais","Selected rows":"Linhas selecionadas","Pinned result set":"Conjunto de resultados fixado",Query:"Consulta",Sort:"Ordenação","Include all metadata:":"Incluir todos os metadados:","Export as:":"Exportar como:","No data selected.":"Nenhum dado selecionado.",Cancel:"Cancelar","Start Export":"Iniciar exportação","Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).":"Baixe e salve arquivos de mídia dos dados capturados. Isso pode demorar conforme a quantidade de dados. A mídia baixada inclui imagens de perfil, banners de perfil (para usuários), imagens e vídeos (para tweets).","For more than 100 media or large files, it is recommended to copy the URLs and download them with an external download manager such as aria2.":"Para mais de 100 mídias ou arquivos grandes, recomenda-se copiar as URLs e baixar com um gerenciador externo como aria2.","Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.":"A exportação ZIP no navegador agora usa downloads paralelos limitados. Para tarefas muito grandes com muitos vídeos, exportar URLs ou usar aria2 ainda é o caminho mais seguro e com menor uso de memória.","Filename template:":"Modelo de nome de arquivo:","Download scheduler":"Agendador de downloads","Faster defaults are intended for bulk CDN transfer.":"Os padrões mais rápidos são pensados para transferência em massa via CDN.","Start delay (ms)":"Atraso inicial (ms)","Global parallel":"Paralelo global","Per host":"Por host",Videos:"Vídeos",Retries:"Tentativas","Use aria2 format:":"Usar formato aria2:","Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2.":"Clique para mais informações. Cada URL ficará em uma nova linha, com o nome do arquivo na linha seguinte. Esse formato é compatível com aria2.","Rate limit (ms):":"Limite de taxa (ms):","Media Filter:":"Filtro de mídia:","File Name":"Nome do arquivo","Media Type":"Tipo de mídia","Download URL":"URL de download","No media selected.":"Nenhuma mídia selecionada.","Preview limited to first 250 media items.":"Prévia limitada aos primeiros 250 itens de mídia.",Zipping:"Compactando","Copied!":"Copiado!","Copy URLs":"Copiar URLs","The tweet ID":"O ID do tweet","The username of tweet author":"O nome de usuário do autor do tweet","The profile name of tweet author":"O nome de perfil do autor do tweet","The media index in tweet (start from 0)":"O índice da mídia no tweet (começa em 0)","The order of media in tweet (1/2/3/4)":"A ordem da mídia no tweet (1/2/3/4)","The post date in YYYYMMDD format":"A data da publicação no formato YYYYMMDD","The post time in HHmmss format":"A hora da publicação no formato HHmmss","The media type (photo/video/animated_gif)":"O tipo de mídia (photo/video/animated_gif)","The file extension of media (jpg/png/mp4)":"A extensão do arquivo de mídia (jpg/png/mp4)","Failed to export media. Open DevTools for more details.":"Falha ao exportar mídia. Abra o DevTools para mais detalhes.","Failed to copy media URLs. Open DevTools for more details.":"Falha ao copiar URLs de mídia. Abra o DevTools para mais detalhes.","filter.photo":"Foto","filter.video":"Vídeo","filter.animated_gif":"GIF","filter.retweet":"Incluir retweets","loading remaining rows":"carregando linhas restantes","Bundle ZIP compression:":"Compressão do ZIP bundle:","Fastest / store":"Mais rápido / armazenar","Balanced / fast":"Equilibrado / rápido","Smaller / slower":"Menor / mais lento","Cancel Export":"Cancelar exportação","Export a canonical portable ZIP bundle for sharing/importing.":"Exporta um ZIP bundle portátil canônico para compartilhar/importar.","Export Bundle ZIP":"Exportar ZIP bundle","Source-backed media":"Mídia com suporte de origem","rows scanned:":"linhas escaneadas:","media URLs:":"URLs de mídia:",loading:"carregando","Loading media...":"Carregando mídia..."},common:{"Open Control Panel":"Abrir painel de controle","Browse around to capture more data.":"Navegue para capturar mais dados.",Settings:"Configurações",General:"Geral",Theme:"Tema",Language:"Idioma",Debug:"Depuração","Date Time Format":"Formato de data e hora","Click for more information. This will take effect on both previewer and exported files.":"Clique para mais informações. Isso terá efeito no visualizador e nos arquivos exportados.","Use dedicated DB for accounts":"Usar DB dedicado para contas","This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts.":"Isso criará um banco de dados separado para cada conta do Twitter, ajudando a reduzir a chance de mistura de dados ao usar várias contas.","Local Database":"Banco de dados local","Analyze DB":"Analisar","Export DB":"Exportar","Clear DB":"Limpar","Bundle Export":"Exportar pacote","Bundle Library":"Biblioteca de pacotes","QC Session":"Sessão de QC","Diagnostic capture":"Captura diagnóstica","Diagnostic buffers cleared.":"Buffers de diagnóstico limpos.","Clear Buffers":"Limpar buffers","Preparing...":"Preparando...","Preparing diagnostics...":"Preparando diagnósticos...","Export QC Diagnostics":"Exportar diagnósticos de QC","Export Diagnostics Bundle":"Exportar pacote de diagnósticos","QC idle.":"QC ocioso.","Are you sure to clear all data in the database?":"Tem certeza de que deseja limpar todos os dados do banco?","Database cleared.":"Banco de dados limpo.",Module:"Módulo","Modules (Scroll to see more)":"Módulos (role para ver mais)",About:"Sobre",Version:"Versão","Search...":"Pesquisar...","Something went wrong.":"Algo deu errado.","Error:":"Erro:","Captured:":"Capturado:","Rows per page:":"Linhas por página:","Relation Types":"Tipos de relação","Subject Accounts":"Contas sujeitas","Subject User IDs":"IDs de usuário sujeitos","Last Observed At":"Última observação","A - B of N items":"{{from}} - {{to}} de {{total}} itens","No data available.":"Nenhum dado disponível.","No media available.":"Nenhuma mídia disponível.",Clear:"Limpar","Bookmark folders":"Pastas de favoritos","1 folder selected":"1 pasta selecionada","{{count}} folders selected":"{{count}} pastas selecionadas","Export Media":"Exportar mídia","Export Data":"Exportar dados","Export Search History":"Exportar histórico de pesquisa","JSON View":"Visualização JSON","Media View":"Visualização de mídia",Bookmarks:"Favoritos",Tweets:"Tweets",Users:"Usuários","User Tweets":"Tweets do usuário","User Media":"Mídia do usuário","Tweet Details":"Detalhes do tweet","Search Timeline":"Linha do tempo de pesquisa","Home Timeline":"Linha do tempo inicial","List Timeline":"Linha do tempo da lista","Community Timeline":"Linha do tempo da comunidade","Community Members":"Membros da comunidade","List Members":"Membros da lista","List Subscribers":"Assinantes da lista","Direct Messages":"Mensagens diretas","Interaction Events":"Eventos de interação","Local Search":"Pesquisa local","Runtime Logs":"Logs de execução","Bundle Viewer":"Visualizador de pacotes","{{count}} imported bundles":"{{count}} pacotes importados","Search indexed tweets with Twitter-style operators":"Pesquise tweets indexados com operadores no estilo Twitter","Local Recorder Search":"Pesquisa do gravador local",Quotes:"Citações",CommunityMembers:"Membros da comunidade",CommunityTimeline:"Linha do tempo da comunidade",DirectMessages:"Mensagens diretas",Followers:"Seguidores",Following:"Seguindo",HomeTimeline:"Linha do tempo inicial",Likes:"Curtidas",ListMembers:"Membros da lista",ListSubscribers:"Assinantes da lista",ListTimeline:"Linha do tempo da lista",InteractionEvents:"Eventos de interação",LocalSearch:"Pesquisa local",RawCapture:"Captura bruta",Retweeters:"Retuitadores",RetweetersModule:"Retuitadores",RuntimeLogs:"Logs de execução",SearchTimeline:"Pesquisa",TweetIndex:"Índice de tweets",TweetDetail:"Detalhe do tweet",UserDetail:"Detalhe do usuário",UserMedia:"Mídia do usuário",UserTweets:"Tweets do usuário",on:"ligado",off:"desligado",unknown:"desconhecido",online:"conectado",offline:"desconectado",leader:"líder",follower:"seguidor",tab:"aba",both:"ambos",xhr:"xhr",fetch:"fetch",watchdog:"vigia",all:"todos",explicit:"explícito",loading:"carregando",complete:"concluído",idle:"ocioso","api-name":"nome da API","id-only":"somente ID","theme.system":"Sistema","theme.cupcake":"Claro","theme.dark":"Escuro","theme.emerald":"Emerald","theme.cyberpunk":"Cyberpunk","theme.valentine":"Valentine","theme.lofi":"Lo-fi","theme.dracula":"Dracula","theme.cmyk":"CMYK","theme.business":"Negócios","theme.winter":"Inverno","Safe mode":"Modo seguro","Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture.":"Desativa a captura baseada em hooks quando ativado. Desative para navegação normal e captura diagnóstica.","Hook mode":"Modo de hook","Controls whether the userscript hooks XHR, fetch, both, or neither.":"Controla se o userscript aplica hook em XHR, fetch, ambos ou nenhum.","Repair mode":"Modo de reparo","Controls whether hook repair watchdog behavior is active.":"Controla se o watchdog de reparo de hooks está ativo.","{{seconds}}s ago":"há {{seconds}} s","Hooks: {{status}}":"Hooks:{{status}}","Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})":"Hooks:xhr {{xhr}}, fetch {{fetch}}, último {{url}} ({{age}})","Hooks: xhr {{xhr}}, fetch {{fetch}}":"Hooks:xhr {{xhr}}, fetch {{fetch}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}":"Modo: seguro {{safe}}, hook {{hook}}, reparo {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}":"Modo: seguro {{safe}}, hook {{hook}}, reparo {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}","raw events: {{total}} | dropped: {{dropped}}":"eventos raw: {{total}} | descartados: {{dropped}}","spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed":"spool: {{queued}} carregando / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed","spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms":"descartes por overflow do spool: {{drops}} | indisponível: {{unavailable}} | pendente mais antigo: {{age}}ms","daemon: {{status}}":"serviço:{{status}}","daemon: {{status}} | last error: {{error}}":"serviço:{{status}} | último erro:{{error}}","monitor: {{role}} | leader: {{leader}} | lease: {{lease}}":"monitor:{{role}} | líder:{{leader}} | lease:{{lease}}","monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}":"ticks monitor rota/viewport: {{route}}/{{viewport}} | suprimidos rota/viewport: {{suppressedRoute}}/{{suppressedViewport}}","Database connected: {{name}}":"Banco de dados conectado: {{name}}","App options loaded":"Opções do app carregadas",'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)':'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)',"Search help":"Search help","Clear search":"Clear search","Table view":"Table view","Exit fullscreen":"Exit fullscreen",Fullscreen:"Fullscreen","{{view}} is disabled for large source-backed result sets.":"{{view}} is disabled for large source-backed result sets.","{{view}} view - {{status}}":"{{view}} view - {{status}}","{{view}} view":"{{view}} view","loading {{loaded}}/{{total}}":"loading {{loaded}}/{{total}}","loading more {{loaded}}/{{total}}":"loading more {{loaded}}/{{total}}","searching {{matches}}/{{total}}":"searching {{matches}}/{{total}}","matches {{matches}}/{{total}}":"matches {{matches}}/{{total}}","rows {{loaded}}/{{total}}":"rows {{loaded}}/{{total}}","rows {{count}}":"rows {{count}}","buffering...":"buffering...","history {{count}}":"history {{count}}","selected {{count}} ({{mode}})":"selected {{count}} ({{mode}})","rendered {{rendered}}/{{total}} (window {{start}}-{{end}})":"rendered {{rendered}}/{{total}} (window {{start}}-{{end}})","Search Operators":"Search Operators","Query semantics now follow recorder-style precedence:":"Query semantics now follow recorder-style precedence:","with implicit":"with implicit","between adjacent terms.":"between adjacent terms.","search.category.lexical":"Lexical","search.category.identity":"Identity","search.category.metadata":"Metadata","search.category.presence":"Presence","search.category.numeric_date":"Numeric/date","search.category.compatibility":"Compatibility","Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.":"Texto não estruturado é expandido em correspondências de termos de conteúdo e janelas de frases adjacentes reforçadas; palavras comuns perdem prioridade salvo se estiverem entre aspas.","Phrase search with optional slop.":"Busca por frase com folga opcional.","Boolean operators with standard precedence and parentheses.":"Operadores booleanos com precedência padrão e parênteses.","Match the author handle or author id.":"Corresponde ao usuário ou ID do autor.","Shorthand for an enforced author constraint, equivalent to from:user.":"Atalho para uma restrição obrigatória de autor, equivalente a from:user.","Match reply targets, entity ids, or conversation ids.":"Corresponde a alvos de resposta, IDs de entidade ou IDs de conversa.","Match bookmark folder id or folder name.":"Corresponde ao ID ou nome da pasta de favoritos.","Match language, route surface, source text, or card name.":"Corresponde a idioma, superfície de rota, texto de origem ou nome do card.","Match domains or URLs found in tweets.":"Corresponde a domínios ou URLs encontrados em tweets.","Boolean state filters.":"Filtros de estado booleanos.","Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.":"Filtros de presença para mídia, links, menções, hashtags, cashtags, engajamento e enquetes.","Compatibility aliases retained for Twitter-style queries.":"Aliases de compatibilidade preservados para consultas no estilo Twitter.","Numeric threshold filters.":"Filtros de limite numérico.","Date, timestamp, and Snowflake-style boundary filters.":"Filtros de limite por data, timestamp e estilo Snowflake.","Explicit mention filter plus shorthand hashtag and cashtag filters.":"Filtro explícito de menção mais filtros abreviados de hashtag e cashtag.","Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.":"Busca lexical com escopo de campo em caminhos aninhados brutos, incluindo caminhos pontilhados e arrays.","loading source {{scanned}}/{{total}}":"loading source {{scanned}}/{{total}}","source {{status}} {{scanned}}/{{total}}":"source {{status}} {{scanned}}/{{total}}","media {{count}}":"media {{count}}","loaded media {{count}}":"loaded media {{count}}","source rows {{scanned}}/{{total}} {{status}}":"source rows {{scanned}}/{{total}} {{status}}","source rows {{count}}":"source rows {{count}}","layout {{columns}} cols @ {{width}}px":"layout {{columns}} cols @ {{width}}px","original tweet attachments only":"original tweet attachments only","Loading media.":"Loading media.","Comfortable density":"Comfortable density","Compact density":"Compact density",Photo:"Photo",Video:"Video","Open tweet":"Open tweet","Export menu is open while remaining rows load in the background.":"Export menu is open while remaining rows load in the background.","Wait for records to finish loading before exporting.":"Wait for records to finish loading before exporting.","Exports stream from the active source without loading all rows into the table.":"Exports stream from the active source without loading all rows into the table.","Opens immediately and loads remaining rows in the background.":"Opens immediately and loads remaining rows in the background.","Export persisted bookmark search history":"Export persisted bookmark search history","latest: {{latest}}\napi-name: {{apiName}}\nid-only: {{idOnly}}\nnone: {{none}}":`latest: {{latest}}
api-name: {{apiName}}
id-only: {{idOnly}}
none: {{none}}`,"folder metadata: {{status}}":"folder metadata: {{status}}","Media export is disabled for large result sets until media export has a source-backed stream.":"Media export is disabled for large result sets until media export has a source-backed stream.","App options migrated from v{{oldVersion}} to v{{newVersion}}":"Opções do app migradas de v{{oldVersion}} para v{{newVersion}}","Hooked into fetch":"Hook instalado em fetch","Hooked into XMLHttpRequest (installed={{installed}})":"Hook instalado em XMLHttpRequest (installed={{installed}})","Hook safe mode enabled ({{reason}})":"Modo seguro de hooks ativado ({{reason}})","Hook repair failed ({{failures}}/{{limit}})":"Reparo de hook falhou ({{failures}}/{{limit}})","Bookmark context tracking install failed; continuing without tracker ({{details}})":"Instalação do rastreador de contexto de favoritos falhou; continuando sem rastreador ({{details}})","TWE_DIAG {{phase}}":"TWE_DIAG {{phase}}","{{module}}: {{count}} items received":"{{module}}: {{count}} itens recebidos","Exporting to ZIP file: {{filename}}":"Exportando para arquivo ZIP: {{filename}}","Exporting to {{format}} file: {{filename}}":"Exportando para arquivo {{format}}: {{filename}}","Streaming export to {{format}} file: {{filename}}":"Exportação em stream para arquivo {{format}}: {{filename}}","Migration completed: {{users}} users and {{tweets}} tweets updated.":"Migração concluída: {{users}} usuários e {{tweets}} tweets atualizados.","TweetTombstone received (Reason: {{reason}})":"TweetTombstone recebido (Motivo: {{reason}})","Failed to hook into XMLHttpRequest":"Falha ao aplicar hook em XMLHttpRequest","Fetch API not found, skipping fetch hooks":"Fetch API não encontrada, pulando hooks de fetch","Fetch API base function unavailable or unsafe; enabling safe mode":"Função base da Fetch API indisponível ou insegura; ativando modo seguro","Fetch hook base invocation failed; enabling safe mode":"Invocação base do hook fetch falhou; ativando modo seguro","XHR send hook base invocation failed; enabling safe mode":"Invocação base do hook XHR send falhou; ativando modo seguro","XHR open hook base invocation failed; enabling safe mode":"Invocação base do hook XHR open falhou; ativando modo seguro","Fetch hook already installed":"Hook de fetch já instalado","Debug mode enabled":"Modo debug ativado","Database cleared":"Banco de dados limpo","Upgrading database schema...":"Atualizando esquema do banco de dados...","Database upgraded":"Banco de dados atualizado","Zip stream closed.":"Stream ZIP fechado.","Running migration_20250609: Migrating legacy user data format":"Executando migration_20250609: migrando formato legado de dados de usuário","TweetUnavailable received (Reason: unknown)":"TweetUnavailable recebido (Motivo: desconhecido)","Empty tweet received":"Tweet vazio recebido","Unknown tweet type received":"Tipo de tweet desconhecido recebido","Failed to extract tweet":"Falha ao extrair tweet","Failed to export file":"Falha ao exportar arquivo","Failed to stream export file":"Falha ao exportar arquivo em stream"}},Pb={exporter:{ID:"ID",Date:"Дата",Content:"Содержимое","Show Full Text":"Показать полный текст",Media:"Медиа","Screen Name":"Имя пользователя","Profile Name":"Имя профиля","Profile Image":"Изображение профиля","User ID":"ID пользователя","Replying To":"Ответ на","RT Source":"Источник RT","Quote Source":"Источник цитаты","Media Tags":"Медиа-теги",Favorites:"Избранное",Retweets:"Ретвиты",Bookmarks:"Закладки",Quotes:"Цитаты",Replies:"Ответы",Views:"Просмотры",Favorited:"В избранном",Retweeted:"Ретвитнуто",Bookmarked:"В закладках","Bookmark Folder":"Папка закладок",URL:"URL",Actions:"Действия",Details:"Детали",Description:"Описание","Profile Banner":"Баннер профиля",Followers:"Подписчики",FollowingCount:"Количество подписок",Statuses:"Публикации",Favourites:"Избранное",Listed:"В списках",Location:"Местоположение",Website:"Сайт",Birthdate:"Дата рождения","Verified Type":"Тип верификации","Blue Verified":"Blue верифицирован",Following:"Подписки","Follows You":"Подписан на вас","Can DM":"Можно написать в DM",Protected:"Защищён","Created At":"Создано",Sender:"Отправитель",Recipient:"Получатель","Conversation ID":"ID беседы","Conversation Type":"Тип беседы",Data:"Данные","Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.":"Экспортируйте захваченные данные в JSON/HTML/CSV. Это может занять время в зависимости от объёма данных. Экспортируемый файл не содержит медиафайлы, такие как изображения и видео, а только URL.","Data length:":"Длина данных:","Export scope:":"Область экспорта:","All current results":"Все текущие результаты","Selected rows":"Выбранные строки","Pinned result set":"Закреплённый набор результатов",Query:"Запрос",Sort:"Сортировка","Include all metadata:":"Включить все метаданные:","Export as:":"Экспортировать как:","No data selected.":"Данные не выбраны.",Cancel:"Отмена","Start Export":"Начать экспорт","Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).":"Скачать и сохранить медиафайлы из захваченных данных. Это может занять время в зависимости от объёма данных. Будут скачаны изображения профиля, баннеры профиля (для пользователей), изображения и видео (для твитов).","For more than 100 media or large files, it is recommended to copy the URLs and download them with an external download manager such as aria2.":"Для более чем 100 медиа или крупных файлов рекомендуется скопировать URL и скачать их внешним менеджером, например aria2.","Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.":"ZIP-экспорт в браузере теперь использует ограниченные параллельные загрузки. Для очень больших задач с множеством видео экспорт URL или aria2 остаётся самым безопасным вариантом с низким потреблением памяти.","Filename template:":"Шаблон имени файла:","Download scheduler":"Планировщик загрузок","Faster defaults are intended for bulk CDN transfer.":"Более быстрые значения по умолчанию предназначены для массовой передачи через CDN.","Start delay (ms)":"Начальная задержка (мс)","Global parallel":"Общий параллелизм","Per host":"На хост",Videos:"Видео",Retries:"Повторы","Use aria2 format:":"Использовать формат aria2:","Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2.":"Нажмите для подробностей. Каждый URL будет на новой строке, а имя файла — на следующей. Формат совместим с aria2.","Rate limit (ms):":"Ограничение скорости (мс):","Media Filter:":"Фильтр медиа:","File Name":"Имя файла","Media Type":"Тип медиа","Download URL":"URL загрузки","No media selected.":"Медиа не выбраны.","Preview limited to first 250 media items.":"Предпросмотр ограничен первыми 250 медиаэлементами.",Zipping:"Упаковка ZIP","Copied!":"Скопировано!","Copy URLs":"Копировать URL","The tweet ID":"ID твита","The username of tweet author":"Имя пользователя автора твита","The profile name of tweet author":"Имя профиля автора твита","The media index in tweet (start from 0)":"Индекс медиа в твите (начинается с 0)","The order of media in tweet (1/2/3/4)":"Порядок медиа в твите (1/2/3/4)","The post date in YYYYMMDD format":"Дата публикации в формате YYYYMMDD","The post time in HHmmss format":"Время публикации в формате HHmmss","The media type (photo/video/animated_gif)":"Тип медиа (photo/video/animated_gif)","The file extension of media (jpg/png/mp4)":"Расширение медиафайла (jpg/png/mp4)","Failed to export media. Open DevTools for more details.":"Не удалось экспортировать медиа. Откройте DevTools для подробностей.","Failed to copy media URLs. Open DevTools for more details.":"Не удалось скопировать URL медиа. Откройте DevTools для подробностей.","filter.photo":"Фото","filter.video":"Видео","filter.animated_gif":"GIF","filter.retweet":"Включить ретвиты","loading remaining rows":"загрузка оставшихся строк","Bundle ZIP compression:":"Сжатие ZIP-бандла:","Fastest / store":"Самое быстрое / store","Balanced / fast":"Сбалансировано / быстро","Smaller / slower":"Меньше / медленнее","Cancel Export":"Отменить экспорт","Export a canonical portable ZIP bundle for sharing/importing.":"Экспортировать канонический переносимый ZIP-бандл для передачи/импорта.","Export Bundle ZIP":"Экспортировать ZIP-бандл","Source-backed media":"Медиа с поддержкой источника","rows scanned:":"просканировано строк:","media URLs:":"URL медиа:",loading:"загрузка","Loading media...":"Загрузка медиа..."},common:{"Open Control Panel":"Открыть панель управления","Browse around to capture more data.":"Просматривайте страницы, чтобы захватывать больше данных.",Settings:"Настройки",General:"Общие",Theme:"Тема",Language:"Язык",Debug:"Отладка","Date Time Format":"Формат даты и времени","Click for more information. This will take effect on both previewer and exported files.":"Нажмите, чтобы узнать подробнее. Это повлияет и на предпросмотр, и на экспортируемые файлы.","Use dedicated DB for accounts":"Использовать отдельную БД для аккаунтов","This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts.":"Это создаст отдельную базу данных для каждого аккаунта Twitter и снизит риск смешивания данных при использовании нескольких аккаунтов.","Local Database":"Локальная база данных","Analyze DB":"Анализ","Export DB":"Экспорт","Clear DB":"Очистить","Bundle Export":"Экспорт пакета","Bundle Library":"Библиотека пакетов","QC Session":"Сессия QC","Diagnostic capture":"Диагностический захват","Diagnostic buffers cleared.":"Диагностические буферы очищены.","Clear Buffers":"Очистить буферы","Preparing...":"Подготовка...","Preparing diagnostics...":"Подготовка диагностики...","Export QC Diagnostics":"Экспорт диагностики QC","Export Diagnostics Bundle":"Экспорт диагностического пакета","QC idle.":"QC бездействует.","Are you sure to clear all data in the database?":"Вы уверены, что хотите удалить все данные из базы?","Database cleared.":"База данных очищена.",Module:"Модуль","Modules (Scroll to see more)":"Модули (прокрутите, чтобы увидеть больше)",About:"О программе",Version:"Версия","Search...":"Поиск...","Something went wrong.":"Что-то пошло не так.","Error:":"Ошибка:","Captured:":"Захвачено:","Rows per page:":"Строк на странице:","Relation Types":"Типы связей","Subject Accounts":"Целевые аккаунты","Subject User IDs":"ID целевых пользователей","Last Observed At":"Последнее наблюдение","A - B of N items":"{{from}} - {{to}} из {{total}} элементов","No data available.":"Нет доступных данных.","No media available.":"Нет доступных медиа.",Clear:"Очистить","Bookmark folders":"Папки закладок","1 folder selected":"Выбрана 1 папка","{{count}} folders selected":"Выбрано папок: {{count}}","Export Media":"Экспорт медиа","Export Data":"Экспорт данных","Export Search History":"Экспорт истории поиска","JSON View":"JSON-представление","Media View":"Медиа-представление",Bookmarks:"Закладки",Tweets:"Твиты",Users:"Пользователи","User Tweets":"Твиты пользователя","User Media":"Медиа пользователя","Tweet Details":"Детали твита","Search Timeline":"Лента поиска","Home Timeline":"Домашняя лента","List Timeline":"Лента списка","Community Timeline":"Лента сообщества","Community Members":"Участники сообщества","List Members":"Участники списка","List Subscribers":"Подписчики списка","Direct Messages":"Личные сообщения","Interaction Events":"События взаимодействия","Local Search":"Локальный поиск","Runtime Logs":"Журналы выполнения","Bundle Viewer":"Просмотр пакетов","{{count}} imported bundles":"Импортировано пакетов: {{count}}","Search indexed tweets with Twitter-style operators":"Поиск индексированных твитов с операторами в стиле Twitter","Local Recorder Search":"Поиск локального регистратора",Quotes:"Цитаты",CommunityMembers:"Участники сообщества",CommunityTimeline:"Лента сообщества",DirectMessages:"Личные сообщения",Followers:"Подписчики",Following:"Подписки",HomeTimeline:"Домашняя лента",Likes:"Лайки",ListMembers:"Участники списка",ListSubscribers:"Подписчики списка",ListTimeline:"Лента списка",InteractionEvents:"События взаимодействия",LocalSearch:"Локальный поиск",RawCapture:"Сырой захват",Retweeters:"Ретвитнувшие",RetweetersModule:"Ретвитнувшие",RuntimeLogs:"Журналы выполнения",SearchTimeline:"Поиск",TweetIndex:"Индекс твитов",TweetDetail:"Детали твита",UserDetail:"Детали пользователя",UserMedia:"Медиа пользователя",UserTweets:"Твиты пользователя",on:"вкл.",off:"выкл.",unknown:"неизвестно",online:"онлайн",offline:"офлайн",leader:"лидер",follower:"подписчик",tab:"вкладка",both:"оба",xhr:"xhr",fetch:"fetch",watchdog:"сторож",all:"все",explicit:"явно",loading:"загрузка",complete:"готово",idle:"ожидание","api-name":"имя API","id-only":"только ID","theme.system":"Система","theme.cupcake":"Светлая","theme.dark":"Тёмная","theme.emerald":"Emerald","theme.cyberpunk":"Cyberpunk","theme.valentine":"Valentine","theme.lofi":"Lo-fi","theme.dracula":"Dracula","theme.cmyk":"CMYK","theme.business":"Бизнес","theme.winter":"Зима","Safe mode":"Безопасный режим","Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture.":"При включении отключает захват через hooks. Отключите для обычного просмотра и диагностики.","Hook mode":"Режим hook","Controls whether the userscript hooks XHR, fetch, both, or neither.":"Управляет тем, будет ли userscript подключать XHR, fetch, оба или ничего.","Repair mode":"Режим восстановления","Controls whether hook repair watchdog behavior is active.":"Управляет активностью watchdog восстановления hooks.","{{seconds}}s ago":"{{seconds}} с назад","Hooks: {{status}}":"Хуки:{{status}}","Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})":"Хуки:xhr {{xhr}}, fetch {{fetch}}, последний {{url}} ({{age}})","Hooks: xhr {{xhr}}, fetch {{fetch}}":"Хуки:xhr {{xhr}}, fetch {{fetch}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}":"Режим: безопасный {{safe}}, hook {{hook}}, восстановление {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}":"Режим: безопасный {{safe}}, hook {{hook}}, восстановление {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}","raw events: {{total}} | dropped: {{dropped}}":"raw события: {{total}} | отброшено: {{dropped}}","spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed":"spool: {{queued}} загрузка / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed","spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms":"сбросы переполнения spool: {{drops}} | недоступно: {{unavailable}} | самый старый pending: {{age}}ms","daemon: {{status}}":"демон:{{status}}","daemon: {{status}} | last error: {{error}}":"демон:{{status}} | последняя ошибка:{{error}}","monitor: {{role}} | leader: {{leader}} | lease: {{lease}}":"монитор:{{role}} | лидер:{{leader}} | lease:{{lease}}","monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}":"тики monitor route/viewport: {{route}}/{{viewport}} | подавлено route/viewport: {{suppressedRoute}}/{{suppressedViewport}}","Database connected: {{name}}":"База данных подключена: {{name}}","App options loaded":"Параметры приложения загружены",'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)':'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)',"Search help":"Search help","Clear search":"Clear search","Table view":"Table view","Exit fullscreen":"Exit fullscreen",Fullscreen:"Fullscreen","{{view}} is disabled for large source-backed result sets.":"{{view}} is disabled for large source-backed result sets.","{{view}} view - {{status}}":"{{view}} view - {{status}}","{{view}} view":"{{view}} view","loading {{loaded}}/{{total}}":"loading {{loaded}}/{{total}}","loading more {{loaded}}/{{total}}":"loading more {{loaded}}/{{total}}","searching {{matches}}/{{total}}":"searching {{matches}}/{{total}}","matches {{matches}}/{{total}}":"matches {{matches}}/{{total}}","rows {{loaded}}/{{total}}":"rows {{loaded}}/{{total}}","rows {{count}}":"rows {{count}}","buffering...":"buffering...","history {{count}}":"history {{count}}","selected {{count}} ({{mode}})":"selected {{count}} ({{mode}})","rendered {{rendered}}/{{total}} (window {{start}}-{{end}})":"rendered {{rendered}}/{{total}} (window {{start}}-{{end}})","Search Operators":"Search Operators","Query semantics now follow recorder-style precedence:":"Query semantics now follow recorder-style precedence:","with implicit":"with implicit","between adjacent terms.":"between adjacent terms.","search.category.lexical":"Lexical","search.category.identity":"Identity","search.category.metadata":"Metadata","search.category.presence":"Presence","search.category.numeric_date":"Numeric/date","search.category.compatibility":"Compatibility","Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.":"Неструктурированный текст расширяется до совпадений терминов содержимого и усиленных окон соседних фраз; распространённые служебные слова имеют меньший приоритет, если не взяты в кавычки.","Phrase search with optional slop.":"Поиск фразы с необязательным допуском.","Boolean operators with standard precedence and parentheses.":"Булевы операторы со стандартным приоритетом и скобками.","Match the author handle or author id.":"Совпадение с именем пользователя или ID автора.","Shorthand for an enforced author constraint, equivalent to from:user.":"Краткая форма обязательного ограничения автора, эквивалент from:user.","Match reply targets, entity ids, or conversation ids.":"Совпадение с целями ответа, ID сущностей или ID бесед.","Match bookmark folder id or folder name.":"Совпадение с ID или названием папки закладок.","Match language, route surface, source text, or card name.":"Совпадение с языком, поверхностью маршрута, исходным текстом или названием карточки.","Match domains or URLs found in tweets.":"Совпадение с доменами или URL в твитах.","Boolean state filters.":"Булевы фильтры состояния.","Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.":"Фильтры наличия медиа, ссылок, упоминаний, хэштегов, кэштегов, вовлечённости и опросов.","Compatibility aliases retained for Twitter-style queries.":"Совместимые псевдонимы, сохранённые для запросов в стиле Twitter.","Numeric threshold filters.":"Фильтры числовых порогов.","Date, timestamp, and Snowflake-style boundary filters.":"Граничные фильтры даты, timestamp и в стиле Snowflake.","Explicit mention filter plus shorthand hashtag and cashtag filters.":"Явный фильтр упоминания плюс краткие фильтры хэштега и кэштега.","Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.":"Лексический поиск по полю в сырых вложенных путях, включая точечные пути объектов и массивы.","loading source {{scanned}}/{{total}}":"loading source {{scanned}}/{{total}}","source {{status}} {{scanned}}/{{total}}":"source {{status}} {{scanned}}/{{total}}","media {{count}}":"media {{count}}","loaded media {{count}}":"loaded media {{count}}","source rows {{scanned}}/{{total}} {{status}}":"source rows {{scanned}}/{{total}} {{status}}","source rows {{count}}":"source rows {{count}}","layout {{columns}} cols @ {{width}}px":"layout {{columns}} cols @ {{width}}px","original tweet attachments only":"original tweet attachments only","Loading media.":"Loading media.","Comfortable density":"Comfortable density","Compact density":"Compact density",Photo:"Photo",Video:"Video","Open tweet":"Open tweet","Export menu is open while remaining rows load in the background.":"Export menu is open while remaining rows load in the background.","Wait for records to finish loading before exporting.":"Wait for records to finish loading before exporting.","Exports stream from the active source without loading all rows into the table.":"Exports stream from the active source without loading all rows into the table.","Opens immediately and loads remaining rows in the background.":"Opens immediately and loads remaining rows in the background.","Export persisted bookmark search history":"Export persisted bookmark search history","latest: {{latest}}\napi-name: {{apiName}}\nid-only: {{idOnly}}\nnone: {{none}}":`latest: {{latest}}
api-name: {{apiName}}
id-only: {{idOnly}}
none: {{none}}`,"folder metadata: {{status}}":"folder metadata: {{status}}","Media export is disabled for large result sets until media export has a source-backed stream.":"Media export is disabled for large result sets until media export has a source-backed stream.","App options migrated from v{{oldVersion}} to v{{newVersion}}":"Параметры приложения перенесены с v{{oldVersion}} на v{{newVersion}}","Hooked into fetch":"Hook установлен в fetch","Hooked into XMLHttpRequest (installed={{installed}})":"Hook установлен в XMLHttpRequest (installed={{installed}})","Hook safe mode enabled ({{reason}})":"Безопасный режим hooks включён ({{reason}})","Hook repair failed ({{failures}}/{{limit}})":"Восстановление hook не удалось ({{failures}}/{{limit}})","Bookmark context tracking install failed; continuing without tracker ({{details}})":"Установка отслеживания контекста закладок не удалась; продолжаем без трекера ({{details}})","TWE_DIAG {{phase}}":"TWE_DIAG {{phase}}","{{module}}: {{count}} items received":"{{module}}: получено {{count}} элементов","Exporting to ZIP file: {{filename}}":"Экспорт в ZIP-файл: {{filename}}","Exporting to {{format}} file: {{filename}}":"Экспорт в файл {{format}}: {{filename}}","Streaming export to {{format}} file: {{filename}}":"Потоковый экспорт в файл {{format}}: {{filename}}","Migration completed: {{users}} users and {{tweets}} tweets updated.":"Миграция завершена: обновлено пользователей {{users}} и твитов {{tweets}}.","TweetTombstone received (Reason: {{reason}})":"Получен TweetTombstone (Причина: {{reason}})","Failed to hook into XMLHttpRequest":"Не удалось установить hook в XMLHttpRequest","Fetch API not found, skipping fetch hooks":"Fetch API не найден, hooks fetch пропущены","Fetch API base function unavailable or unsafe; enabling safe mode":"Базовая функция Fetch API недоступна или небезопасна; включается безопасный режим","Fetch hook base invocation failed; enabling safe mode":"Базовый вызов hook fetch не удался; включается безопасный режим","XHR send hook base invocation failed; enabling safe mode":"Базовый вызов hook XHR send не удался; включается безопасный режим","XHR open hook base invocation failed; enabling safe mode":"Базовый вызов hook XHR open не удался; включается безопасный режим","Fetch hook already installed":"Hook fetch уже установлен","Debug mode enabled":"Режим отладки включён","Database cleared":"База данных очищена","Upgrading database schema...":"Обновление схемы базы данных...","Database upgraded":"База данных обновлена","Zip stream closed.":"ZIP-поток закрыт.","Running migration_20250609: Migrating legacy user data format":"Запуск migration_20250609: перенос устаревшего формата данных пользователей","TweetUnavailable received (Reason: unknown)":"Получен TweetUnavailable (Причина: неизвестна)","Empty tweet received":"Получен пустой твит","Unknown tweet type received":"Получен неизвестный тип твита","Failed to extract tweet":"Не удалось извлечь твит","Failed to export file":"Не удалось экспортировать файл","Failed to stream export file":"Не удалось выполнить потоковый экспорт файла"}},Ob={exporter:{ID:"ID",Date:"تاریخ",Content:"مواد","Show Full Text":"مکمل متن دکھائیں",Media:"میڈیا","Screen Name":"صارف نام","Profile Name":"پروفائل نام","Profile Image":"پروفائل تصویر","User ID":"صارف ID","Replying To":"جواب برائے","RT Source":"RT ماخذ","Quote Source":"اقتباس ماخذ","Media Tags":"میڈیا ٹیگز",Favorites:"پسندیدہ",Retweets:"ری ٹویٹس",Bookmarks:"بک مارکس",Quotes:"اقتباسات",Replies:"جوابات",Views:"دیکھے جانے کی تعداد",Favorited:"پسندیدہ کیا گیا",Retweeted:"ری ٹویٹ کیا گیا",Bookmarked:"بک مارک کیا گیا","Bookmark Folder":"بک مارک فولڈر",URL:"URL",Actions:"اعمال",Details:"تفصیلات",Description:"تفصیل","Profile Banner":"پروفائل بینر",Followers:"فالوورز",FollowingCount:"فالوونگ تعداد",Statuses:"پوسٹس",Favourites:"پسندیدہ",Listed:"لسٹ میں شامل",Location:"مقام",Website:"ویب سائٹ",Birthdate:"تاریخ پیدائش","Verified Type":"تصدیق کی قسم","Blue Verified":"Blue تصدیق شدہ",Following:"فالو کر رہے ہیں","Follows You":"آپ کو فالو کرتا ہے","Can DM":"DM ہو سکتا ہے",Protected:"محفوظ","Created At":"بنایا گیا",Sender:"بھیجنے والا",Recipient:"وصول کنندہ","Conversation ID":"گفتگو ID","Conversation Type":"گفتگو کی قسم",Data:"ڈیٹا","Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.":"محفوظ شدہ ڈیٹا کو JSON/HTML/CSV فائل کے طور پر برآمد کریں۔ ڈیٹا کی مقدار کے مطابق وقت لگ سکتا ہے۔ برآمد شدہ فائل میں تصاویر اور ویڈیوز جیسے میڈیا فائلز شامل نہیں ہوں گے، صرف URL ہوں گے۔","Data length:":"ڈیٹا لمبائی:","Export scope:":"برآمد کا دائرہ:","All current results":"تمام موجودہ نتائج","Selected rows":"منتخب قطاریں","Pinned result set":"پن کیا ہوا نتیجہ سیٹ",Query:"Query",Sort:"ترتیب","Include all metadata:":"تمام میٹا ڈیٹا شامل کریں:","Export as:":"اس طور پر برآمد کریں:","No data selected.":"کوئی ڈیٹا منتخب نہیں۔",Cancel:"منسوخ","Start Export":"برآمد شروع کریں","Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).":"محفوظ شدہ ڈیٹا سے میڈیا فائلیں ڈاؤن لوڈ اور محفوظ کریں۔ ڈیٹا کی مقدار کے مطابق وقت لگ سکتا ہے۔ ڈاؤن لوڈ ہونے والے میڈیا میں پروفائل تصاویر، پروفائل بینرز (صارفین کے لیے)، تصاویر اور ویڈیوز (ٹویٹس کے لیے) شامل ہیں۔","For more than 100 media or large files, it is recommended to copy the URLs and download them with an external download manager such as aria2.":"100 سے زیادہ میڈیا یا بڑی فائلوں کے لیے URL کاپی کر کے aria2 جیسے بیرونی ڈاؤن لوڈ مینیجر سے ڈاؤن لوڈ کرنا بہتر ہے۔","Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.":"براؤزر ZIP برآمد اب محدود متوازی ڈاؤن لوڈز استعمال کرتی ہے۔ بہت بڑے ویڈیو والے کاموں کے لیے URL یا aria2 برآمد اب بھی کم میموری والا محفوظ ترین راستہ ہے۔","Filename template:":"فائل نام ٹیمپلیٹ:","Download scheduler":"ڈاؤن لوڈ شیڈولر","Faster defaults are intended for bulk CDN transfer.":"تیز ڈیفالٹس بڑے CDN ٹرانسفر کے لیے ہیں۔","Start delay (ms)":"آغاز تاخیر (ms)","Global parallel":"عالمی متوازی","Per host":"فی ہوسٹ",Videos:"ویڈیوز",Retries:"دوبارہ کوششیں","Use aria2 format:":"aria2 فارمیٹ استعمال کریں:","Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2.":"مزید معلومات کے لیے کلک کریں۔ ہر URL نئی لائن میں ہوگا، اور اس کا فائل نام اگلی لائن میں ہوگا۔ یہ فارمیٹ aria2 سے مطابقت رکھتا ہے۔","Rate limit (ms):":"رفتار حد (ms):","Media Filter:":"میڈیا فلٹر:","File Name":"فائل نام","Media Type":"میڈیا قسم","Download URL":"ڈاؤن لوڈ URL","No media selected.":"کوئی میڈیا منتخب نہیں۔","Preview limited to first 250 media items.":"پیش نظارہ پہلے 250 میڈیا آئٹمز تک محدود ہے۔",Zipping:"ZIP بن رہی ہے","Copied!":"کاپی ہو گیا!","Copy URLs":"URL کاپی کریں","The tweet ID":"ٹویٹ ID","The username of tweet author":"ٹویٹ مصنف کا صارف نام","The profile name of tweet author":"ٹویٹ مصنف کا پروفائل نام","The media index in tweet (start from 0)":"ٹویٹ میں میڈیا انڈیکس (0 سے شروع)","The order of media in tweet (1/2/3/4)":"ٹویٹ میں میڈیا ترتیب (1/2/3/4)","The post date in YYYYMMDD format":"YYYYMMDD فارمیٹ میں پوسٹ تاریخ","The post time in HHmmss format":"HHmmss فارمیٹ میں پوسٹ وقت","The media type (photo/video/animated_gif)":"میڈیا قسم (photo/video/animated_gif)","The file extension of media (jpg/png/mp4)":"میڈیا فائل ایکسٹینشن (jpg/png/mp4)","Failed to export media. Open DevTools for more details.":"میڈیا برآمد ناکام۔ مزید تفصیلات کے لیے DevTools کھولیں۔","Failed to copy media URLs. Open DevTools for more details.":"میڈیا URL کاپی ناکام۔ مزید تفصیلات کے لیے DevTools کھولیں۔","filter.photo":"تصویر","filter.video":"ویڈیو","filter.animated_gif":"GIF","filter.retweet":"ری ٹویٹس شامل کریں","loading remaining rows":"باقی قطاریں لوڈ ہو رہی ہیں","Bundle ZIP compression:":"Bundle ZIP کمپریشن:","Fastest / store":"تیز ترین / store","Balanced / fast":"متوازن / تیز","Smaller / slower":"چھوٹا / سست","Cancel Export":"Export منسوخ کریں","Export a canonical portable ZIP bundle for sharing/importing.":"share/import کے لیے canonical portable ZIP bundle export کریں۔","Export Bundle ZIP":"Bundle ZIP export کریں","Source-backed media":"Source-backed میڈیا","rows scanned:":"scan شدہ قطاریں:","media URLs:":"میڈیا URLs:",loading:"لوڈ ہو رہا ہے","Loading media...":"media لوڈ ہو رہا ہے..."},common:{"Open Control Panel":"کنٹرول پینل کھولیں","Browse around to capture more data.":"مزید ڈیٹا محفوظ کرنے کے لیے براؤز کریں۔",Settings:"ترتیبات",General:"عمومی",Theme:"تھیم",Language:"زبان",Debug:"ڈیبگ","Date Time Format":"تاریخ اور وقت کا فارمیٹ","Click for more information. This will take effect on both previewer and exported files.":"مزید معلومات کے لیے کلک کریں۔ یہ پیش نظارہ اور برآمد شدہ فائلوں دونوں پر لاگو ہوگا۔","Use dedicated DB for accounts":"اکاؤنٹس کے لیے الگ DB استعمال کریں","This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts.":"یہ ہر Twitter اکاؤنٹ کے لیے الگ ڈیٹابیس بنائے گا، جس سے متعدد اکاؤنٹس استعمال کرتے وقت ڈیٹا کے مل جانے کا امکان کم ہوتا ہے۔","Local Database":"مقامی ڈیٹابیس","Analyze DB":"تجزیہ","Export DB":"برآمد","Clear DB":"صاف کریں","Bundle Export":"بنڈل برآمد","Bundle Library":"بنڈل لائبریری","QC Session":"QC سیشن","Diagnostic capture":"تشخیصی کیپچر","Diagnostic buffers cleared.":"تشخیصی بفر صاف کر دیے گئے۔","Clear Buffers":"بفر صاف کریں","Preparing...":"تیاری ہو رہی ہے...","Preparing diagnostics...":"تشخیص تیار ہو رہی ہے...","Export QC Diagnostics":"QC تشخیص برآمد کریں","Export Diagnostics Bundle":"تشخیصی بنڈل برآمد کریں","QC idle.":"QC غیر فعال ہے۔","Are you sure to clear all data in the database?":"کیا آپ واقعی ڈیٹابیس کا تمام ڈیٹا صاف کرنا چاہتے ہیں؟","Database cleared.":"ڈیٹابیس صاف کر دی گئی۔",Module:"ماڈیول","Modules (Scroll to see more)":"ماڈیولز (مزید دیکھنے کے لیے اسکرول کریں)",About:"متعلق",Version:"ورژن","Search...":"تلاش...","Something went wrong.":"کچھ غلط ہو گیا۔","Error:":"خرابی:","Captured:":"محفوظ شدہ:","Rows per page:":"فی صفحہ قطاریں:","Relation Types":"رشتہ کی اقسام","Subject Accounts":"موضوع اکاؤنٹس","Subject User IDs":"موضوع صارف ID","Last Observed At":"آخری مشاہدہ","A - B of N items":"{{total}} میں سے {{from}} - {{to}} آئٹمز","No data available.":"کوئی ڈیٹا دستیاب نہیں۔","No media available.":"کوئی میڈیا دستیاب نہیں۔",Clear:"صاف کریں","Bookmark folders":"بک مارک فولڈرز","1 folder selected":"1 فولڈر منتخب","{{count}} folders selected":"{{count}} فولڈرز منتخب","Export Media":"میڈیا برآمد کریں","Export Data":"ڈیٹا برآمد کریں","Export Search History":"تلاش کی تاریخ برآمد کریں","JSON View":"JSON منظر","Media View":"میڈیا منظر",Bookmarks:"بک مارکس",Tweets:"ٹویٹس",Users:"صارفین","User Tweets":"صارف کی ٹویٹس","User Media":"صارف کا میڈیا","Tweet Details":"ٹویٹ کی تفصیلات","Search Timeline":"تلاش ٹائم لائن","Home Timeline":"ہوم ٹائم لائن","List Timeline":"لسٹ ٹائم لائن","Community Timeline":"کمیونٹی ٹائم لائن","Community Members":"کمیونٹی اراکین","List Members":"لسٹ اراکین","List Subscribers":"لسٹ سبسکرائبرز","Direct Messages":"براہ راست پیغامات","Interaction Events":"تعامل کے واقعات","Local Search":"مقامی تلاش","Runtime Logs":"رن ٹائم لاگز","Bundle Viewer":"بنڈل ویور","{{count}} imported bundles":"{{count}} درآمد شدہ بنڈلز","Search indexed tweets with Twitter-style operators":"Twitter طرز کے آپریٹرز سے انڈیکس شدہ ٹویٹس تلاش کریں","Local Recorder Search":"مقامی ریکارڈر تلاش",Quotes:"اقتباسات",CommunityMembers:"کمیونٹی اراکین",CommunityTimeline:"کمیونٹی ٹائم لائن",DirectMessages:"براہ راست پیغامات",Followers:"فالوورز",Following:"فالو کر رہے ہیں",HomeTimeline:"ہوم ٹائم لائن",Likes:"لائکس",ListMembers:"لسٹ اراکین",ListSubscribers:"لسٹ سبسکرائبرز",ListTimeline:"لسٹ ٹائم لائن",InteractionEvents:"تعامل کے واقعات",LocalSearch:"مقامی تلاش",RawCapture:"خام کیپچر",Retweeters:"ری ٹویٹ کرنے والے",RetweetersModule:"ری ٹویٹ کرنے والے",RuntimeLogs:"رن ٹائم لاگز",SearchTimeline:"تلاش",TweetIndex:"ٹویٹ انڈیکس",TweetDetail:"ٹویٹ تفصیل",UserDetail:"صارف تفصیل",UserMedia:"صارف میڈیا",UserTweets:"صارف ٹویٹس",on:"آن",off:"آف",unknown:"نامعلوم",online:"آن لائن",offline:"آف لائن",leader:"لیڈر",follower:"فالوور",tab:"ٹیب",both:"دونوں",xhr:"xhr",fetch:"fetch",watchdog:"واچ ڈاگ",all:"سب",explicit:"واضح",loading:"لوڈ ہو رہا ہے",complete:"مکمل",idle:"خالی","api-name":"API نام","id-only":"صرف ID","theme.system":"سسٹم","theme.cupcake":"ہلکا","theme.dark":"گہرا","theme.emerald":"Emerald","theme.cyberpunk":"Cyberpunk","theme.valentine":"Valentine","theme.lofi":"Lo-fi","theme.dracula":"Dracula","theme.cmyk":"CMYK","theme.business":"بزنس","theme.winter":"سردی","Safe mode":"محفوظ موڈ","Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture.":"فعال ہونے پر hook-based capture بند کرتا ہے۔ عام browsing اور diagnostic capture کے لیے اسے بند کریں۔","Hook mode":"Hook موڈ","Controls whether the userscript hooks XHR, fetch, both, or neither.":"یہ کنٹرول کرتا ہے کہ userscript XHR، fetch، دونوں یا کوئی بھی hook کرے۔","Repair mode":"Repair موڈ","Controls whether hook repair watchdog behavior is active.":"یہ کنٹرول کرتا ہے کہ hook repair watchdog فعال ہے یا نہیں۔","{{seconds}}s ago":"{{seconds}} سیکنڈ پہلے","Hooks: {{status}}":"ہکس:{{status}}","Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})":"ہکس:xhr {{xhr}}, fetch {{fetch}}, آخری {{url}} ({{age}})","Hooks: xhr {{xhr}}, fetch {{fetch}}":"ہکس:xhr {{xhr}}, fetch {{fetch}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}":"موڈ: محفوظ {{safe}}, hook {{hook}}, مرمت {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}":"موڈ: محفوظ {{safe}}, hook {{hook}}, مرمت {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}","raw events: {{total}} | dropped: {{dropped}}":"raw واقعات: {{total}} | dropped: {{dropped}}","spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed":"spool: {{queued}} لوڈ ہو رہا ہے / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed","spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms":"spool overflow drops: {{drops}} | unavailable: {{unavailable}} | سب سے پرانا pending: {{age}}ms","daemon: {{status}}":"ڈیمون:{{status}}","daemon: {{status}} | last error: {{error}}":"ڈیمون:{{status}} | آخری خرابی:{{error}}","monitor: {{role}} | leader: {{leader}} | lease: {{lease}}":"مانیٹر:{{role}} | لیڈر:{{leader}} | lease:{{lease}}","monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}":"monitor ticks route/viewport: {{route}}/{{viewport}} | دبائے گئے route/viewport: {{suppressedRoute}}/{{suppressedViewport}}","Database connected: {{name}}":"ڈیٹابیس منسلک: {{name}}","App options loaded":"App options لوڈ ہو گئے",'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)':'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)',"Search help":"Search help","Clear search":"Clear search","Table view":"Table view","Exit fullscreen":"Exit fullscreen",Fullscreen:"Fullscreen","{{view}} is disabled for large source-backed result sets.":"{{view}} is disabled for large source-backed result sets.","{{view}} view - {{status}}":"{{view}} view - {{status}}","{{view}} view":"{{view}} view","loading {{loaded}}/{{total}}":"loading {{loaded}}/{{total}}","loading more {{loaded}}/{{total}}":"loading more {{loaded}}/{{total}}","searching {{matches}}/{{total}}":"searching {{matches}}/{{total}}","matches {{matches}}/{{total}}":"matches {{matches}}/{{total}}","rows {{loaded}}/{{total}}":"rows {{loaded}}/{{total}}","rows {{count}}":"rows {{count}}","buffering...":"buffering...","history {{count}}":"history {{count}}","selected {{count}} ({{mode}})":"selected {{count}} ({{mode}})","rendered {{rendered}}/{{total}} (window {{start}}-{{end}})":"rendered {{rendered}}/{{total}} (window {{start}}-{{end}})","Search Operators":"Search Operators","Query semantics now follow recorder-style precedence:":"Query semantics now follow recorder-style precedence:","with implicit":"with implicit","between adjacent terms.":"between adjacent terms.","search.category.lexical":"Lexical","search.category.identity":"Identity","search.category.metadata":"Metadata","search.category.presence":"Presence","search.category.numeric_date":"Numeric/date","search.category.compatibility":"Compatibility","Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.":"غیر ساختہ متن مواد کے الفاظ کی مماثلت اور مضبوط قریبی فقرہ ونڈوز میں پھیلتا ہے؛ عام بھرائی الفاظ کو کم ترجیح دی جاتی ہے جب تک وہ اقتباس میں نہ ہوں۔","Phrase search with optional slop.":"اختیاری slop کے ساتھ فقرہ تلاش۔","Boolean operators with standard precedence and parentheses.":"معیاری ترجیح اور قوسین کے ساتھ بولین آپریٹرز۔","Match the author handle or author id.":"مصنف کا ہینڈل یا مصنف ID ملائیں۔","Shorthand for an enforced author constraint, equivalent to from:user.":"لازمی مصنف قید کا مختصر طریقہ، from:user کے برابر۔","Match reply targets, entity ids, or conversation ids.":"جواب کے اہداف، entity IDs یا conversation IDs ملائیں۔","Match bookmark folder id or folder name.":"بک مارک فولڈر ID یا نام ملائیں۔","Match language, route surface, source text, or card name.":"زبان، route surface، source text یا card name ملائیں۔","Match domains or URLs found in tweets.":"ٹویٹس میں موجود domains یا URLs ملائیں۔","Boolean state filters.":"بولین حالت فلٹرز۔","Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.":"میڈیا، links، mentions، hashtags، cashtags، engagement اور polls کی موجودگی کے فلٹرز۔","Compatibility aliases retained for Twitter-style queries.":"Twitter طرز queries کے لیے compatibility aliases برقرار رکھے گئے۔","Numeric threshold filters.":"عددی حد فلٹرز۔","Date, timestamp, and Snowflake-style boundary filters.":"تاریخ، timestamp اور Snowflake طرز boundary فلٹرز۔","Explicit mention filter plus shorthand hashtag and cashtag filters.":"واضح mention فلٹر، نیز مختصر hashtag اور cashtag فلٹرز۔","Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.":"dotted object paths اور arrays سمیت raw nested paths پر field-scoped lexical تلاش۔","loading source {{scanned}}/{{total}}":"loading source {{scanned}}/{{total}}","source {{status}} {{scanned}}/{{total}}":"source {{status}} {{scanned}}/{{total}}","media {{count}}":"media {{count}}","loaded media {{count}}":"loaded media {{count}}","source rows {{scanned}}/{{total}} {{status}}":"source rows {{scanned}}/{{total}} {{status}}","source rows {{count}}":"source rows {{count}}","layout {{columns}} cols @ {{width}}px":"layout {{columns}} cols @ {{width}}px","original tweet attachments only":"original tweet attachments only","Loading media.":"Loading media.","Comfortable density":"Comfortable density","Compact density":"Compact density",Photo:"Photo",Video:"Video","Open tweet":"Open tweet","Export menu is open while remaining rows load in the background.":"Export menu is open while remaining rows load in the background.","Wait for records to finish loading before exporting.":"Wait for records to finish loading before exporting.","Exports stream from the active source without loading all rows into the table.":"Exports stream from the active source without loading all rows into the table.","Opens immediately and loads remaining rows in the background.":"Opens immediately and loads remaining rows in the background.","Export persisted bookmark search history":"Export persisted bookmark search history","latest: {{latest}}\napi-name: {{apiName}}\nid-only: {{idOnly}}\nnone: {{none}}":`latest: {{latest}}
api-name: {{apiName}}
id-only: {{idOnly}}
none: {{none}}`,"folder metadata: {{status}}":"folder metadata: {{status}}","Media export is disabled for large result sets until media export has a source-backed stream.":"Media export is disabled for large result sets until media export has a source-backed stream.","App options migrated from v{{oldVersion}} to v{{newVersion}}":"App options v{{oldVersion}} سے v{{newVersion}} میں migrate ہو گئے","Hooked into fetch":"fetch میں hook کیا گیا","Hooked into XMLHttpRequest (installed={{installed}})":"XMLHttpRequest میں hook کیا گیا (installed={{installed}})","Hook safe mode enabled ({{reason}})":"Hook safe mode فعال ہوا ({{reason}})","Hook repair failed ({{failures}}/{{limit}})":"Hook repair ناکام ({{failures}}/{{limit}})","Bookmark context tracking install failed; continuing without tracker ({{details}})":"Bookmark context tracking install ناکام؛ tracker کے بغیر جاری ({{details}})","TWE_DIAG {{phase}}":"TWE_DIAG {{phase}}","{{module}}: {{count}} items received":"{{module}}: {{count}} items موصول ہوئے","Exporting to ZIP file: {{filename}}":"ZIP file میں export: {{filename}}","Exporting to {{format}} file: {{filename}}":"{{format}} file میں export: {{filename}}","Streaming export to {{format}} file: {{filename}}":"{{format}} file میں streaming export: {{filename}}","Migration completed: {{users}} users and {{tweets}} tweets updated.":"Migration مکمل: {{users}} users اور {{tweets}} tweets update ہوئے۔","TweetTombstone received (Reason: {{reason}})":"TweetTombstone موصول ہوا (Reason: {{reason}})","Failed to hook into XMLHttpRequest":"XMLHttpRequest میں hook ناکام","Fetch API not found, skipping fetch hooks":"Fetch API نہیں ملا، fetch hooks چھوڑے جا رہے ہیں","Fetch API base function unavailable or unsafe; enabling safe mode":"Fetch API base function unavailable یا unsafe ہے؛ safe mode فعال ہو رہا ہے","Fetch hook base invocation failed; enabling safe mode":"Fetch hook base invocation ناکام؛ safe mode فعال ہو رہا ہے","XHR send hook base invocation failed; enabling safe mode":"XHR send hook base invocation ناکام؛ safe mode فعال ہو رہا ہے","XHR open hook base invocation failed; enabling safe mode":"XHR open hook base invocation ناکام؛ safe mode فعال ہو رہا ہے","Fetch hook already installed":"Fetch hook پہلے سے installed ہے","Debug mode enabled":"Debug mode فعال","Database cleared":"Database صاف کیا گیا","Upgrading database schema...":"Database schema upgrade ہو رہا ہے...","Database upgraded":"Database upgrade ہو گیا","Zip stream closed.":"ZIP stream بند ہو گیا۔","Running migration_20250609: Migrating legacy user data format":"migration_20250609 چل رہا ہے: legacy user data format migrate ہو رہا ہے","TweetUnavailable received (Reason: unknown)":"TweetUnavailable موصول ہوا (Reason: unknown)","Empty tweet received":"خالی tweet موصول ہوا","Unknown tweet type received":"Unknown tweet type موصول ہوا","Failed to extract tweet":"Tweet extract ناکام","Failed to export file":"File export ناکام","Failed to stream export file":"Stream export file ناکام"}},Fb={exporter:{ID:"ID",Date:"日期",Content:"内容","Show Full Text":"显示全文",Media:"媒体","Screen Name":"用户名","Profile Name":"用户昵称","Profile Image":"用户头像","User ID":"用户 ID","Replying To":"回复推文","RT Source":"转推来源","Quote Source":"引用来源","Media Tags":"圈人",Favorites:"喜欢数量",Retweets:"转推数量",Bookmarks:"书签数量",Quotes:"引用数量",Replies:"回复数量",Views:"查看次数",Favorited:"已喜欢",Retweeted:"已转推",Bookmarked:"已加书签","Bookmark Folder":"书签文件夹",URL:"URL",Actions:"操作",Details:"查看详情",Description:"简介","Profile Banner":"个人资料头图",Followers:"关注者数量",FollowingCount:"正在关注数量",Statuses:"推文数量",Favourites:"喜欢数量",Listed:"被加入列表数",Location:"位置",Website:"网站",Birthdate:"出生日期","Verified Type":"认证类型","Blue Verified":"蓝标认证",Following:"正在关注","Follows You":"关注你","Can DM":"可私信",Protected:"受保护","Created At":"创建时间",Sender:"发送者",Recipient:"接收者","Conversation ID":"对话 ID","Conversation Type":"对话类型",Data:"数据","Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.":"将捕获的数据导出为 JSON/HTML/CSV 文件。这可能需要一些时间,具体取决于数据量。导出的文件不包括图片和视频等媒体文件,只包括它们的 URL。","Data length:":"数据长度:","Export scope:":"导出范围:","All current results":"当前全部结果","Selected rows":"已选择行","Pinned result set":"已固定结果集",Query:"查询",Sort:"排序","Include all metadata:":"包括所有元数据:","Export as:":"导出为:","No data selected.":"未选择数据。",Cancel:"取消","Start Export":"开始导出","Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).":"从捕获的数据中下载并保存媒体文件。这可能需要一些时间,具体取决于数据量。将下载的媒体包括:用户的个人资料图片、个人资料头图、图片、推文中的视频。","For more than 100 media or large files, it is recommended to copy the URLs and download them with an external download manager such as aria2.":"对于超过 100 个媒体或大文件,建议复制 URL 并使用外部下载管理器(如 aria2)下载。","Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.":"浏览器 ZIP 导出现在使用有界并行下载。对于非常大的视频密集任务,URL 或 aria2 导出仍是内存占用最低的安全路径。","Filename template:":"文件名模板:","Download scheduler":"下载调度器","Faster defaults are intended for bulk CDN transfer.":"更快的默认值用于批量 CDN 传输。","Start delay (ms)":"启动间隔 (ms)","Global parallel":"全局并行","Per host":"每主机",Videos:"视频",Retries:"重试","Use aria2 format:":"使用 aria2 格式:","Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2.":"点击获取更多信息。每个 URL 将在新行中显示,其文件名在下一行。此格式与 aria2 兼容。","Rate limit (ms):":"速率限制(毫秒):","Media Filter:":"媒体过滤器:","File Name":"文件名","Media Type":"媒体类型","Download URL":"下载地址","No media selected.":"未选择媒体。","Preview limited to first 250 media items.":"预览限制为前 250 个媒体项。",Zipping:"正在打包","Copied!":"已复制!","Copy URLs":"复制 URL","The tweet ID":"推文 ID","The username of tweet author":"推文作者的用户名","The profile name of tweet author":"推文作者的用户昵称","The media index in tweet (start from 0)":"推文中的媒体索引(从 0 开始)","The order of media in tweet (1/2/3/4)":"推文中的媒体顺序(1/2/3/4)","The post date in YYYYMMDD format":"发布日期(YYYYMMDD 格式)","The post time in HHmmss format":"发布时间(HHmmss 格式)","The media type (photo/video/animated_gif)":"媒体类型(photo/video/animated_gif)","The file extension of media (jpg/png/mp4)":"媒体文件扩展名(jpg/png/mp4)","Failed to export media. Open DevTools for more details.":"导出媒体失败。打开 DevTools 以获取更多详细信息。","Failed to copy media URLs. Open DevTools for more details.":"复制媒体 URL 失败。打开 DevTools 以获取更多详细信息。","filter.photo":"图片","filter.video":"视频","filter.animated_gif":"GIF","filter.retweet":"包括转推","loading remaining rows":"正在加载剩余行","Bundle ZIP compression:":"捆绑 ZIP 压缩:","Fastest / store":"最快 / 仅存储","Balanced / fast":"平衡 / 快速","Smaller / slower":"更小 / 更慢","Cancel Export":"取消导出","Export a canonical portable ZIP bundle for sharing/importing.":"导出用于分享/导入的规范可移植 ZIP 捆绑包。","Export Bundle ZIP":"导出捆绑 ZIP","Source-backed media":"源支持媒体","rows scanned:":"已扫描行:","media URLs:":"媒体 URL:",loading:"加载中","Loading media...":"正在加载媒体..."},common:{"Open Control Panel":"打开控制面板","Browse around to capture more data.":"浏览页面以捕获更多数据。",Settings:"设置",General:"通用",Theme:"主题",Language:"语言",Debug:"调试开关","Date Time Format":"日期时间格式","Click for more information. This will take effect on both previewer and exported files.":"点击查看详细信息。此选项会影响预览和导出的文件。","Use dedicated DB for accounts":"为每个账户使用专用数据库","This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts.":"这将为每个 Twitter 账户创建单独的数据库,这有助于避免使用多个账户时数据混淆。","Local Database":"本地数据库","Analyze DB":"统计","Export DB":"导出","Clear DB":"清空","Bundle Export":"导出捆绑包","Bundle Library":"捆绑包库","QC Session":"质检会话","Diagnostic capture":"诊断捕获","Diagnostic buffers cleared.":"诊断缓冲区已清除。","Clear Buffers":"清除缓冲区","Preparing...":"准备中...","Preparing diagnostics...":"正在准备诊断...","Export QC Diagnostics":"导出质检诊断","Export Diagnostics Bundle":"导出诊断捆绑包","QC idle.":"质检空闲。","Are you sure to clear all data in the database?":"确定要清空数据库中的所有数据吗?","Database cleared.":"数据库已清空。",Module:"模块","Modules (Scroll to see more)":"模块列表(滑动以查看完整列表)",About:"关于",Version:"版本","Search...":"搜索...","Something went wrong.":"出错了。","Error:":"错误:","Captured:":"已捕获:","Rows per page:":"每页显示行数:","Relation Types":"关系类型","Subject Accounts":"主体账户","Subject User IDs":"主体用户 ID","Last Observed At":"最后观察时间","A - B of N items":"第 {{from}} - {{to}} 项,共 {{total}} 项","No data available.":"没有数据。","No media available.":"没有可用媒体。",Clear:"清除","Bookmark folders":"书签文件夹","1 folder selected":"已选择 1 个文件夹","{{count}} folders selected":"已选择 {{count}} 个文件夹","Export Media":"导出媒体文件","Export Data":"导出数据","Export Search History":"导出搜索历史","JSON View":"JSON 数据预览","Media View":"媒体预览",Bookmarks:"书签",Tweets:"推文",Users:"用户","User Tweets":"用户推文","User Media":"用户媒体","Tweet Details":"推文详情","Search Timeline":"搜索时间线","Home Timeline":"主页时间线","List Timeline":"列表时间线","Community Timeline":"社群时间线","Community Members":"社群成员","List Members":"列表成员","List Subscribers":"列表关注者","Direct Messages":"私信","Interaction Events":"交互事件","Local Search":"本地搜索","Runtime Logs":"运行时日志","Bundle Viewer":"捆绑包查看器","{{count}} imported bundles":"已导入 {{count}} 个捆绑包","Search indexed tweets with Twitter-style operators":"用 Twitter 风格运算符搜索已索引推文","Local Recorder Search":"本地记录器搜索",Quotes:"引用推文",CommunityMembers:"社群成员",CommunityTimeline:"社群时间线",DirectMessages:"私信",Followers:"关注者",Following:"正在关注",HomeTimeline:"主页时间线",Likes:"喜欢",ListMembers:"列表成员",ListSubscribers:"列表关注者",ListTimeline:"列表时间线",InteractionEvents:"交互事件",LocalSearch:"本地搜索",RawCapture:"原始捕获",Retweeters:"转推者",RetweetersModule:"转推者",RuntimeLogs:"运行时日志",SearchTimeline:"搜索结果",TweetIndex:"推文索引",TweetDetail:"推文详情",UserDetail:"用户详情",UserMedia:"用户媒体",UserTweets:"用户推文",on:"开",off:"关",unknown:"未知",online:"在线",offline:"离线",leader:"主控",follower:"跟随",tab:"标签页",both:"两者",xhr:"xhr",fetch:"fetch",watchdog:"看门狗",all:"全部",explicit:"显式",loading:"加载中",complete:"完成",idle:"空闲","api-name":"API 名称","id-only":"仅 ID","theme.system":"跟随 X/系统","theme.cupcake":"浅色","theme.dark":"深色","theme.emerald":"Emerald","theme.cyberpunk":"Cyberpunk","theme.valentine":"Valentine","theme.lofi":"Lo-fi","theme.dracula":"Dracula","theme.cmyk":"CMYK","theme.business":"商务","theme.winter":"冬季","Safe mode":"安全模式","Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture.":"启用后会停用基于 hook 的捕获。正常浏览和诊断捕获时请关闭它。","Hook mode":"Hook 模式","Controls whether the userscript hooks XHR, fetch, both, or neither.":"控制用户脚本 hook XHR、fetch、两者,还是都不 hook。","Repair mode":"修复模式","Controls whether hook repair watchdog behavior is active.":"控制 hook 修复看门狗是否启用。","{{seconds}}s ago":"{{seconds}} 秒前","Hooks: {{status}}":"Hooks:{{status}}","Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})":"Hooks:xhr {{xhr}}, fetch {{fetch}}, 上次 {{url}} ({{age}})","Hooks: xhr {{xhr}}, fetch {{fetch}}":"Hooks:xhr {{xhr}}, fetch {{fetch}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}":"模式: 安全 {{safe}}, hook {{hook}}, 修复 {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}","Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}":"模式: 安全 {{safe}}, hook {{hook}}, 修复 {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}","raw events: {{total}} | dropped: {{dropped}}":"raw 事件:{{total}} | 丢弃:{{dropped}}","spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed":"spool:{{queued}} 排队 / {{enqueued}} 入队 / {{flushed}} 已刷新 / {{failed}} 失败","spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms":"spool 溢出丢弃:{{drops}} | 不可用:{{unavailable}} | 最旧待处理:{{age}}ms","daemon: {{status}}":"守护进程:{{status}}","daemon: {{status}} | last error: {{error}}":"守护进程:{{status}} | 最近错误:{{error}}","monitor: {{role}} | leader: {{leader}} | lease: {{lease}}":"监控器:{{role}} | 主控:{{leader}} | lease:{{lease}}","monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}":"monitor tick 路由/视口:{{route}}/{{viewport}} | 抑制 路由/视口:{{suppressedRoute}}/{{suppressedViewport}}","Database connected: {{name}}":"数据库已连接:{{name}}","App options loaded":"应用选项已加载",'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)':'Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)',"Search help":"Search help","Clear search":"Clear search","Table view":"Table view","Exit fullscreen":"Exit fullscreen",Fullscreen:"Fullscreen","{{view}} is disabled for large source-backed result sets.":"{{view}} is disabled for large source-backed result sets.","{{view}} view - {{status}}":"{{view}} view - {{status}}","{{view}} view":"{{view}} view","loading {{loaded}}/{{total}}":"loading {{loaded}}/{{total}}","loading more {{loaded}}/{{total}}":"loading more {{loaded}}/{{total}}","searching {{matches}}/{{total}}":"searching {{matches}}/{{total}}","matches {{matches}}/{{total}}":"matches {{matches}}/{{total}}","rows {{loaded}}/{{total}}":"rows {{loaded}}/{{total}}","rows {{count}}":"rows {{count}}","buffering...":"buffering...","history {{count}}":"history {{count}}","selected {{count}} ({{mode}})":"selected {{count}} ({{mode}})","rendered {{rendered}}/{{total}} (window {{start}}-{{end}})":"rendered {{rendered}}/{{total}} (window {{start}}-{{end}})","Search Operators":"Search Operators","Query semantics now follow recorder-style precedence:":"Query semantics now follow recorder-style precedence:","with implicit":"with implicit","between adjacent terms.":"between adjacent terms.","search.category.lexical":"Lexical","search.category.identity":"Identity","search.category.metadata":"Metadata","search.category.presence":"Presence","search.category.numeric_date":"Numeric/date","search.category.compatibility":"Compatibility","Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.":"非结构化文本会扩展为内容词匹配,并提升相邻短语窗口;除非加引号,常见填充词会降低权重。","Phrase search with optional slop.":"短语搜索,可选 slop。","Boolean operators with standard precedence and parentheses.":"布尔运算符,支持标准优先级和括号。","Match the author handle or author id.":"匹配作者用户名或作者 ID。","Shorthand for an enforced author constraint, equivalent to from:user.":"强制作者约束的简写,等同于 from:user。","Match reply targets, entity ids, or conversation ids.":"匹配回复目标、实体 ID 或会话 ID。","Match bookmark folder id or folder name.":"匹配书签文件夹 ID 或名称。","Match language, route surface, source text, or card name.":"匹配语言、路由页面、来源文本或卡片名称。","Match domains or URLs found in tweets.":"匹配推文中的域名或 URL。","Boolean state filters.":"布尔状态筛选器。","Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.":"按媒体、链接、提及、话题标签、股票标签、互动和投票是否存在筛选。","Compatibility aliases retained for Twitter-style queries.":"为 Twitter 风格查询保留的兼容别名。","Numeric threshold filters.":"数值阈值筛选器。","Date, timestamp, and Snowflake-style boundary filters.":"日期、时间戳和 Snowflake 风格边界筛选器。","Explicit mention filter plus shorthand hashtag and cashtag filters.":"显式提及筛选,以及话题标签和股票标签简写筛选。","Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.":"在原始嵌套路径上执行字段限定词法搜索,包括点分对象路径和数组。","loading source {{scanned}}/{{total}}":"loading source {{scanned}}/{{total}}","source {{status}} {{scanned}}/{{total}}":"source {{status}} {{scanned}}/{{total}}","media {{count}}":"media {{count}}","loaded media {{count}}":"loaded media {{count}}","source rows {{scanned}}/{{total}} {{status}}":"source rows {{scanned}}/{{total}} {{status}}","source rows {{count}}":"source rows {{count}}","layout {{columns}} cols @ {{width}}px":"layout {{columns}} cols @ {{width}}px","original tweet attachments only":"original tweet attachments only","Loading media.":"Loading media.","Comfortable density":"Comfortable density","Compact density":"Compact density",Photo:"Photo",Video:"Video","Open tweet":"Open tweet","Export menu is open while remaining rows load in the background.":"Export menu is open while remaining rows load in the background.","Wait for records to finish loading before exporting.":"Wait for records to finish loading before exporting.","Exports stream from the active source without loading all rows into the table.":"Exports stream from the active source without loading all rows into the table.","Opens immediately and loads remaining rows in the background.":"Opens immediately and loads remaining rows in the background.","Export persisted bookmark search history":"Export persisted bookmark search history","latest: {{latest}}\napi-name: {{apiName}}\nid-only: {{idOnly}}\nnone: {{none}}":`latest: {{latest}}
api-name: {{apiName}}
id-only: {{idOnly}}
none: {{none}}`,"folder metadata: {{status}}":"folder metadata: {{status}}","Media export is disabled for large result sets until media export has a source-backed stream.":"Media export is disabled for large result sets until media export has a source-backed stream.","App options migrated from v{{oldVersion}} to v{{newVersion}}":"应用选项已从 v{{oldVersion}} 迁移到 v{{newVersion}}","Hooked into fetch":"已 hook fetch","Hooked into XMLHttpRequest (installed={{installed}})":"已 hook XMLHttpRequest(installed={{installed}})","Hook safe mode enabled ({{reason}})":"Hook 安全模式已启用({{reason}})","Hook repair failed ({{failures}}/{{limit}})":"Hook 修复失败({{failures}}/{{limit}})","Bookmark context tracking install failed; continuing without tracker ({{details}})":"书签上下文跟踪安装失败;将在没有跟踪器的情况下继续({{details}})","TWE_DIAG {{phase}}":"TWE_DIAG {{phase}}","{{module}}: {{count}} items received":"{{module}}:已收到 {{count}} 项","Exporting to ZIP file: {{filename}}":"正在导出到 ZIP 文件:{{filename}}","Exporting to {{format}} file: {{filename}}":"正在导出到 {{format}} 文件:{{filename}}","Streaming export to {{format}} file: {{filename}}":"正在流式导出到 {{format}} 文件:{{filename}}","Migration completed: {{users}} users and {{tweets}} tweets updated.":"迁移完成:已更新 {{users}} 个用户和 {{tweets}} 条推文。","TweetTombstone received (Reason: {{reason}})":"收到 TweetTombstone(原因:{{reason}})","Failed to hook into XMLHttpRequest":"hook XMLHttpRequest 失败","Fetch API not found, skipping fetch hooks":"未找到 Fetch API,跳过 fetch hooks","Fetch API base function unavailable or unsafe; enabling safe mode":"Fetch API 基础函数不可用或不安全;正在启用安全模式","Fetch hook base invocation failed; enabling safe mode":"Fetch hook 基础调用失败;正在启用安全模式","XHR send hook base invocation failed; enabling safe mode":"XHR send hook 基础调用失败;正在启用安全模式","XHR open hook base invocation failed; enabling safe mode":"XHR open hook 基础调用失败;正在启用安全模式","Fetch hook already installed":"Fetch hook 已安装","Debug mode enabled":"调试模式已启用","Database cleared":"数据库已清除","Upgrading database schema...":"正在升级数据库架构...","Database upgraded":"数据库已升级","Zip stream closed.":"ZIP 流已关闭。","Running migration_20250609: Migrating legacy user data format":"正在运行 migration_20250609:迁移旧版用户数据格式","TweetUnavailable received (Reason: unknown)":"收到 TweetUnavailable(原因:未知)","Empty tweet received":"收到空推文","Unknown tweet type received":"收到未知推文类型","Failed to extract tweet":"提取推文失败","Failed to export file":"导出文件失败","Failed to stream export file":"流式导出文件失败"}},Lb={ar:Sb,bn:Cb,en:Tb,es:Mb,fr:Rb,hi:Ib,id:Eb,ja:Ab,"pt-BR":Db,ru:Pb,ur:Ob,"zh-Hans":Fb};var Nb=Symbol.for("preact-signals");function $l(){if(Lo>1)Lo--;else {for(var e,t=false;Fi!==void 0;){var n=Fi;for(Fi=void 0,Au++;n!==void 0;){var r=n.o;if(n.o=void 0,n.f&=-3,!(8&n.f)&&ug(n))try{n.c();}catch(o){t||(e=o,t=true);}n=r;}}if(Au=0,Lo--,t)throw e}}function Bb(e){if(Lo>0)return e();Lo++;try{return e()}finally{$l();}}var pn=void 0,Fi=void 0,Lo=0,Au=0,dl=0;function cg(e){if(pn!==void 0){var t=e.n;if(t===void 0||t.t!==pn)return t={i:0,S:e,p:pn.s,n:void 0,t:pn,e:void 0,x:void 0,r:t},pn.s!==void 0&&(pn.s.n=t),pn.s=t,e.n=t,32&pn.f&&e.S(t),t;if(t.i===-1)return t.i=0,t.n!==void 0&&(t.n.p=t.p,t.p!==void 0&&(t.p.n=t.n),t.p=pn.s,t.n=void 0,pn.s.n=t,pn.s=t),t}}function Un(e){this.v=e,this.i=0,this.n=void 0,this.t=void 0;}Un.prototype.brand=Nb;Un.prototype.h=function(){return  true};Un.prototype.S=function(e){this.t!==e&&e.e===void 0&&(e.x=this.t,this.t!==void 0&&(this.t.e=e),this.t=e);};Un.prototype.U=function(e){if(this.t!==void 0){var t=e.e,n=e.x;t!==void 0&&(t.x=n,e.e=void 0),n!==void 0&&(n.e=t,e.x=void 0),e===this.t&&(this.t=n);}};Un.prototype.subscribe=function(e){var t=this;return Hl(function(){var n=t.value,r=pn;pn=void 0;try{e(n);}finally{pn=r;}})};Un.prototype.valueOf=function(){return this.value};Un.prototype.toString=function(){return this.value+""};Un.prototype.toJSON=function(){return this.value};Un.prototype.peek=function(){var e=pn;pn=void 0;try{return this.value}finally{pn=e;}};Object.defineProperty(Un.prototype,"value",{get:function(){var e=cg(this);return e!==void 0&&(e.i=this.i),this.v},set:function(e){if(e!==this.v){if(Au>100)throw new Error("Cycle detected");this.v=e,this.i++,dl++,Lo++;try{for(var t=this.t;t!==void 0;t=t.x)t.t.N();}finally{$l();}}}});function ri(e){return new Un(e)}function ug(e){for(var t=e.s;t!==void 0;t=t.n)if(t.S.i!==t.i||!t.S.h()||t.S.i!==t.i)return  true;return  false}function dg(e){for(var t=e.s;t!==void 0;t=t.n){var n=t.S.n;if(n!==void 0&&(t.r=n),t.S.n=t,t.i=-1,t.n===void 0){e.s=t;break}}}function fg(e){for(var t=e.s,n=void 0;t!==void 0;){var r=t.p;t.i===-1?(t.S.U(t),r!==void 0&&(r.n=t.n),t.n!==void 0&&(t.n.p=r)):n=t,t.S.n=t.r,t.r!==void 0&&(t.r=void 0),t=r;}e.s=n;}function oi(e){Un.call(this,void 0),this.x=e,this.s=void 0,this.g=dl-1,this.f=4;}(oi.prototype=new Un).h=function(){if(this.f&=-3,1&this.f)return  false;if((36&this.f)==32||(this.f&=-5,this.g===dl))return  true;if(this.g=dl,this.f|=1,this.i>0&&!ug(this))return this.f&=-2,true;var e=pn;try{dg(this),pn=this;var t=this.x();(16&this.f||this.v!==t||this.i===0)&&(this.v=t,this.f&=-17,this.i++);}catch(n){this.v=n,this.f|=16,this.i++;}return pn=e,fg(this),this.f&=-2,true};oi.prototype.S=function(e){if(this.t===void 0){this.f|=36;for(var t=this.s;t!==void 0;t=t.n)t.S.S(t);}Un.prototype.S.call(this,e);};oi.prototype.U=function(e){if(this.t!==void 0&&(Un.prototype.U.call(this,e),this.t===void 0)){this.f&=-33;for(var t=this.s;t!==void 0;t=t.n)t.S.U(t);}};oi.prototype.N=function(){if(!(2&this.f)){this.f|=6;for(var e=this.t;e!==void 0;e=e.x)e.t.N();}};Object.defineProperty(oi.prototype,"value",{get:function(){if(1&this.f)throw new Error("Cycle detected");var e=cg(this);if(this.h(),e!==void 0&&(e.i=this.i),16&this.f)throw this.v;return this.v}});function Vf(e){return new oi(e)}function hg(e){var t=e.u;if(e.u=void 0,typeof t=="function"){Lo++;var n=pn;pn=void 0;try{t();}catch(r){throw e.f&=-2,e.f|=8,kd(e),r}finally{pn=n,$l();}}}function kd(e){for(var t=e.s;t!==void 0;t=t.n)t.S.U(t);e.x=void 0,e.s=void 0,hg(e);}function Ub(e){if(pn!==this)throw new Error("Out-of-order effect");fg(this),pn=e,this.f&=-2,8&this.f&&kd(this),$l();}function is(e){this.x=e,this.u=void 0,this.s=void 0,this.o=void 0,this.f=32;}is.prototype.c=function(){var e=this.S();try{if(8&this.f||this.x===void 0)return;var t=this.x();typeof t=="function"&&(this.u=t);}finally{e();}};is.prototype.S=function(){if(1&this.f)throw new Error("Cycle detected");this.f|=1,this.f&=-9,hg(this),dg(this),Lo++;var e=pn;return pn=this,Ub.bind(this,e)};is.prototype.N=function(){2&this.f||(this.f|=2,this.o=Fi,Fi=this);};is.prototype.d=function(){this.f|=8,1&this.f||kd(this);};function Hl(e){var t=new is(e);try{t.c();}catch(n){throw t.d(),n}return t.d.bind(t)}var Sc;function ai(e,t){$t[e]=t.bind(null,$t[e]||function(){});}function fl(e){Sc&&Sc(),Sc=e&&e.S();}function pg(e){var t=this,n=e.data,r=on(n);r.value=n;var o=It(function(){for(var a=t,i=t.__v;i=i.__;)if(i.__c){i.__c.__$f|=4;break}var s=Vf(function(){var c=r.value.value;return c===0?0:c===true?"":c||""}),l=Vf(function(){var c;return Su(s.value)||((c=t.base)==null?void 0:c.nodeType)!==3});return t.__$u.c=function(){var c;!Su(o.peek())&&((c=t.base)==null?void 0:c.nodeType)===3?t.base.data=o.peek():(t.__$f|=1,t.setState({}));},Hl(function(){Qi||(Qi=this.N),this.N=gg,l.value&&a.base&&(a.base.data=s.value);}),s},[]);return o.value}pg.displayName="_st";Object.defineProperties(Un.prototype,{constructor:{configurable:true,value:void 0},type:{configurable:true,value:pg},props:{configurable:true,get:function(){return {data:this}}},__b:{configurable:true,value:1}});ai("__b",function(e,t){if(typeof t.type=="string"){var n,r=t.props;for(var o in r)if(o!=="children"){var a=r[o];a instanceof Un&&(n||(t.__np=n={}),n[o]=a,r[o]=a.peek());}}e(t);});ai("__r",function(e,t){fl();var n,r=t.__c;r&&(r.__$f&=-2,(n=r.__$u)===void 0&&(r.__$u=n=(function(o){var a;return Hl(function(){a=this;}),a.c=function(){r.__$f|=1,r.setState({});},a})())),fl(n),e(t);});ai("__e",function(e,t,n,r){fl(),e(t,n,r);});ai("diffed",function(e,t){fl();var n;if(typeof t.type=="string"&&(n=t.__e)){var r=t.__np,o=t.props;if(r){var a=n.U;if(a)for(var i in a){var s=a[i];s!==void 0&&!(i in r)&&(s.d(),a[i]=void 0);}else n.U=a={};for(var l in r){var c=a[l],h=r[l];c===void 0?(c=$b(n,l,h,o),a[l]=c):c.o(h,o);}}}e(t);});function $b(e,t,n,r){var o=t in e&&e.ownerSVGElement===void 0,a=ri(n);return {o:function(i,s){a.value=i,r=s;},d:Hl(function(){Qi||(Qi=this.N),this.N=gg;var i=a.value.value;r[t]!==i&&(r[t]=i,o?e[t]=i:i?e.setAttribute(t,i):e.removeAttribute(t));})}}ai("unmount",function(e,t){if(typeof t.type=="string"){var n=t.__e;if(n){var r=n.U;if(r){n.U=void 0;for(var o in r){var a=r[o];a&&a.d();}}}}else {var i=t.__c;if(i){var s=i.__$u;s&&(i.__$u=void 0,s.d());}}e(t);});ai("__h",function(e,t,n,r){(r<3||r===9)&&(t.__$f|=2),e(t,n,r);});Fr.prototype.shouldComponentUpdate=function(e,t){var n=this.__$u;if(!(n&&n.s!==void 0||4&this.__$f)||3&this.__$f)return  true;for(var r in t)return  true;for(var o in e)if(o!=="__source"&&e[o]!==this.props[o])return  true;for(var a in this.props)if(!(a in e))return  true;return  false};function on(e){return It(function(){return ri(e)},[])}var Qi,mg=[],Hb=function(e){queueMicrotask(function(){queueMicrotask(e);});};function jb(){Bb(function(){for(var e;e=mg.shift();)Qi.call(e);});}function gg(){mg.push(this)===1&&($t.requestAnimationFrame||Hb)(jb);}var qb=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function yg(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Zs={exports:{}},Vb=Zs.exports,zf;function zb(){return zf||(zf=1,(function(e,t){(function(n,r){e.exports=r();})(Vb,(function(){var n=1e3,r=6e4,o=36e5,a="millisecond",i="second",s="minute",l="hour",c="day",h="week",f="month",m="quarter",g="year",_="date",b="Invalid Date",C=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,k=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,T={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(Z){var re=["th","st","nd","rd"],J=Z%100;return "["+Z+(re[(J-20)%10]||re[J]||re[0])+"]"}},M=function(Z,re,J){var le=String(Z);return !le||le.length>=re?Z:""+Array(re+1-le.length).join(J)+Z},P={s:M,z:function(Z){var re=-Z.utcOffset(),J=Math.abs(re),le=Math.floor(J/60),he=J%60;return (re<=0?"+":"-")+M(le,2,"0")+":"+M(he,2,"0")},m:function Z(re,J){if(re.date()<J.date())return -Z(J,re);var le=12*(J.year()-re.year())+(J.month()-re.month()),he=re.clone().add(le,f),pe=J-he<0,ge=re.clone().add(le+(pe?-1:1),f);return +(-(le+(J-he)/(pe?he-ge:ge-he))||0)},a:function(Z){return Z<0?Math.ceil(Z)||0:Math.floor(Z)},p:function(Z){return {M:f,y:g,w:h,d:c,D:_,h:l,m:s,s:i,ms:a,Q:m}[Z]||String(Z||"").toLowerCase().replace(/s$/,"")},u:function(Z){return Z===void 0}},F="en",I={};I[F]=T;var O="$isDayjsObject",B=function(Z){return Z instanceof $||!(!Z||!Z[O])},D=function Z(re,J,le){var he;if(!re)return F;if(typeof re=="string"){var pe=re.toLowerCase();I[pe]&&(he=pe),J&&(I[pe]=J,he=pe);var ge=re.split("-");if(!he&&ge.length>1)return Z(ge[0])}else {var z=re.name;I[z]=re,he=z;}return !le&&he&&(F=he),he||!le&&F},v=function(Z,re){if(B(Z))return Z.clone();var J=typeof re=="object"?re:{};return J.date=Z,J.args=arguments,new $(J)},L=P;L.l=D,L.i=B,L.w=function(Z,re){return v(Z,{locale:re.$L,utc:re.$u,x:re.$x,$offset:re.$offset})};var $=(function(){function Z(J){this.$L=D(J.locale,null,true),this.parse(J),this.$x=this.$x||J.x||{},this[O]=true;}var re=Z.prototype;return re.parse=function(J){this.$d=(function(le){var he=le.date,pe=le.utc;if(he===null)return new Date(NaN);if(L.u(he))return new Date;if(he instanceof Date)return new Date(he);if(typeof he=="string"&&!/Z$/i.test(he)){var ge=he.match(C);if(ge){var z=ge[2]-1||0,ue=(ge[7]||"0").substring(0,3);return pe?new Date(Date.UTC(ge[1],z,ge[3]||1,ge[4]||0,ge[5]||0,ge[6]||0,ue)):new Date(ge[1],z,ge[3]||1,ge[4]||0,ge[5]||0,ge[6]||0,ue)}}return new Date(he)})(J),this.init();},re.init=function(){var J=this.$d;this.$y=J.getFullYear(),this.$M=J.getMonth(),this.$D=J.getDate(),this.$W=J.getDay(),this.$H=J.getHours(),this.$m=J.getMinutes(),this.$s=J.getSeconds(),this.$ms=J.getMilliseconds();},re.$utils=function(){return L},re.isValid=function(){return this.$d.toString()!==b},re.isSame=function(J,le){var he=v(J);return this.startOf(le)<=he&&he<=this.endOf(le)},re.isAfter=function(J,le){return v(J)<this.startOf(le)},re.isBefore=function(J,le){return this.endOf(le)<v(J)},re.$g=function(J,le,he){return L.u(J)?this[le]:this.set(he,J)},re.unix=function(){return Math.floor(this.valueOf()/1e3)},re.valueOf=function(){return this.$d.getTime()},re.startOf=function(J,le){var he=this,pe=!!L.u(le)||le,ge=L.p(J),z=function(j,se){var _e=L.w(he.$u?Date.UTC(he.$y,se,j):new Date(he.$y,se,j),he);return pe?_e:_e.endOf(c)},ue=function(j,se){return L.w(he.toDate()[j].apply(he.toDate("s"),(pe?[0,0,0,0]:[23,59,59,999]).slice(se)),he)},Pe=this.$W,ce=this.$M,Ee=this.$D,Qe="set"+(this.$u?"UTC":"");switch(ge){case g:return pe?z(1,0):z(31,11);case f:return pe?z(1,ce):z(0,ce+1);case h:var X=this.$locale().weekStart||0,ne=(Pe<X?Pe+7:Pe)-X;return z(pe?Ee-ne:Ee+(6-ne),ce);case c:case _:return ue(Qe+"Hours",0);case l:return ue(Qe+"Minutes",1);case s:return ue(Qe+"Seconds",2);case i:return ue(Qe+"Milliseconds",3);default:return this.clone()}},re.endOf=function(J){return this.startOf(J,false)},re.$set=function(J,le){var he,pe=L.p(J),ge="set"+(this.$u?"UTC":""),z=(he={},he[c]=ge+"Date",he[_]=ge+"Date",he[f]=ge+"Month",he[g]=ge+"FullYear",he[l]=ge+"Hours",he[s]=ge+"Minutes",he[i]=ge+"Seconds",he[a]=ge+"Milliseconds",he)[pe],ue=pe===c?this.$D+(le-this.$W):le;if(pe===f||pe===g){var Pe=this.clone().set(_,1);Pe.$d[z](ue),Pe.init(),this.$d=Pe.set(_,Math.min(this.$D,Pe.daysInMonth())).$d;}else z&&this.$d[z](ue);return this.init(),this},re.set=function(J,le){return this.clone().$set(J,le)},re.get=function(J){return this[L.p(J)]()},re.add=function(J,le){var he,pe=this;J=Number(J);var ge=L.p(le),z=function(ce){var Ee=v(pe);return L.w(Ee.date(Ee.date()+Math.round(ce*J)),pe)};if(ge===f)return this.set(f,this.$M+J);if(ge===g)return this.set(g,this.$y+J);if(ge===c)return z(1);if(ge===h)return z(7);var ue=(he={},he[s]=r,he[l]=o,he[i]=n,he)[ge]||1,Pe=this.$d.getTime()+J*ue;return L.w(Pe,this)},re.subtract=function(J,le){return this.add(-1*J,le)},re.format=function(J){var le=this,he=this.$locale();if(!this.isValid())return he.invalidDate||b;var pe=J||"YYYY-MM-DDTHH:mm:ssZ",ge=L.z(this),z=this.$H,ue=this.$m,Pe=this.$M,ce=he.weekdays,Ee=he.months,Qe=he.meridiem,X=function(se,_e,we,Ye){return se&&(se[_e]||se(le,pe))||we[_e].slice(0,Ye)},ne=function(se){return L.s(z%12||12,se,"0")},j=Qe||function(se,_e,we){var Ye=se<12?"AM":"PM";return we?Ye.toLowerCase():Ye};return pe.replace(k,(function(se,_e){return _e||(function(we){switch(we){case "YY":return String(le.$y).slice(-2);case "YYYY":return L.s(le.$y,4,"0");case "M":return Pe+1;case "MM":return L.s(Pe+1,2,"0");case "MMM":return X(he.monthsShort,Pe,Ee,3);case "MMMM":return X(Ee,Pe);case "D":return le.$D;case "DD":return L.s(le.$D,2,"0");case "d":return String(le.$W);case "dd":return X(he.weekdaysMin,le.$W,ce,2);case "ddd":return X(he.weekdaysShort,le.$W,ce,3);case "dddd":return ce[le.$W];case "H":return String(z);case "HH":return L.s(z,2,"0");case "h":return ne(1);case "hh":return ne(2);case "a":return j(z,ue,true);case "A":return j(z,ue,false);case "m":return String(ue);case "mm":return L.s(ue,2,"0");case "s":return String(le.$s);case "ss":return L.s(le.$s,2,"0");case "SSS":return L.s(le.$ms,3,"0");case "Z":return ge}return null})(se)||ge.replace(":","")}))},re.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},re.diff=function(J,le,he){var pe,ge=this,z=L.p(le),ue=v(J),Pe=(ue.utcOffset()-this.utcOffset())*r,ce=this-ue,Ee=function(){return L.m(ge,ue)};switch(z){case g:pe=Ee()/12;break;case f:pe=Ee();break;case m:pe=Ee()/3;break;case h:pe=(ce-Pe)/6048e5;break;case c:pe=(ce-Pe)/864e5;break;case l:pe=ce/o;break;case s:pe=ce/r;break;case i:pe=ce/n;break;default:pe=ce;}return he?pe:L.a(pe)},re.daysInMonth=function(){return this.endOf(f).$D},re.$locale=function(){return I[this.$L]},re.locale=function(J,le){if(!J)return this.$L;var he=this.clone(),pe=D(J,le,true);return pe&&(he.$L=pe),he},re.clone=function(){return L.w(this.$d,this)},re.toDate=function(){return new Date(this.valueOf())},re.toJSON=function(){return this.isValid()?this.toISOString():null},re.toISOString=function(){return this.$d.toISOString()},re.toString=function(){return this.$d.toUTCString()},Z})(),Me=$.prototype;return v.prototype=Me,[["$ms",a],["$s",i],["$m",s],["$H",l],["$W",c],["$M",f],["$y",g],["$D",_]].forEach((function(Z){Me[Z[1]]=function(re){return this.$g(re,Z[0],Z[1])};})),v.extend=function(Z,re){return Z.$i||(Z(re,$,v),Z.$i=true),v},v.locale=D,v.isDayjs=B,v.unix=function(Z){return v(1e3*Z)},v.en=I[F],v.Ls=I,v.p={},v}));})(Zs)),Zs.exports}var Kb=zb();const Ji=yg(Kb),Du="twe_diagnostic_capture_enabled_v1",hl="__twe_diagnostic_parser_events_v1",pl="__twe_diagnostic_db_events_v1",ml="__twe_diagnostic_interaction_events_v1",xd="twe:diagnostic-event-v1",Kf=500;function ss(){return globalThis}function Wb(e,t=false){try{if(typeof localStorage>"u")return t;const n=localStorage.getItem(e);return n===null?t:n==="1"||n==="true"}catch{return t}}function Gb(e,t){try{if(typeof localStorage>"u")return;localStorage.setItem(e,t?"1":"0");}catch{}}function Sd(e,t){const n=ss(),r=Array.isArray(n[e])?n[e]:[];if(r.push(t),r.length>Kf&&r.splice(0,r.length-Kf),n[e]=r,typeof window<"u"&&typeof window.dispatchEvent=="function")try{window.dispatchEvent(new CustomEvent(xd,{detail:{key:e}}));}catch{}}function kr(){const e=ss(),t=e.__twe_diagnostic_capture_enabled_v1;if(typeof t=="boolean")return t;const n=Wb(Du,false);return e.__twe_diagnostic_capture_enabled_v1=n,n}function _g(e){const t=ss();if(t.__twe_diagnostic_capture_enabled_v1=e,Gb(Du,e),typeof window<"u"&&typeof window.dispatchEvent=="function")try{window.dispatchEvent(new CustomEvent(xd,{detail:{key:Du,enabled:e}}));}catch{}}function Cc(e){kr()&&Sd(hl,e);}function Yb(e){kr()&&Sd(pl,e);}function Xb(e){kr()&&Sd(ml,e);}function Zb(){const e=ss();return {parser:Array.isArray(e[hl])?[...e[hl]]:[],db:Array.isArray(e[pl])?[...e[pl]]:[],interaction:Array.isArray(e[ml])?[...e[ml]]:[]}}function wg(){const e=ss();e[hl]=[],e[pl]=[],e[ml]=[];}const Wf={eventName:xd},gl=ri([]),Qb=200,Jb=400,ev="twe_console_info_v1",bg="twe_console_verbose_v1";function Pu(e){if(!e)return  false;const t=e.trim().toLowerCase();return t==="1"||t==="true"||t==="yes"||t==="on"}function tv(){try{if(Pu(localStorage.getItem(bg)))return !0}catch{}try{if(Pu(localStorage.getItem(ev)))return !0}catch{}return  false}function vg(){try{return Pu(localStorage.getItem(bg))}catch{return  false}}function nv(){return kr()||vg()?Jb:Qb}class rv{constructor(){je(this,"index",0);je(this,"buffer",[]);je(this,"bufferTimer",null);}info(t,...n){tv()&&console.info("[twitter-web-exporter]",t,...n),this.writeBuffer({type:"info",line:t,index:this.index++});}warn(t,...n){console.warn("[twitter-web-exporter]",t,...n),this.writeBuffer({type:"warn",line:t,index:this.index++});}error(t,...n){console.error("[twitter-web-exporter]",t,...n),this.writeBuffer({type:"error",line:t,index:this.index++});}errorWithBanner(t,n,...r){this.error(`${t} (Message: ${(n==null?void 0:n.message)??"none"})
  This may be a problem caused by Twitter updates.
  Please file an issue on GitHub:
  https://github.com/kmccleary3301/scrollmark/issues`,...r);}debug(...t){vg()&&console.debug("[twitter-web-exporter]",...t);}writeBuffer(t){this.buffer.push(t),this.bufferTimer&&clearTimeout(this.bufferTimer),this.bufferTimer=window.setTimeout(()=>{this.bufferTimer=null,this.flushBuffer();},0);}flushBuffer(){const t=[...gl.value,...this.buffer],n=nv();gl.value=t.length>n?t.slice(t.length-n):t,this.buffer=[];}}const Ie=new rv;function ov(e){try{return JSON.parse(e)}catch(t){return Ie.error(t.message),null}}function Hn(e){const t=on(e),n=r=>{t.value=r;};return [t.value,n,t]}function sr(e=false){const t=on(e),n=()=>{t.value=!t.value;};return [t.value,n,t]}function sn(...e){return e.filter(Boolean).join(" ")}function av(e,t){return JSON.stringify(e)===JSON.stringify(t)}function Ea(e){return e.replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}function iv(e){if(!e)return null;try{const t=new URL(e);return t.protocol!=="http:"&&t.protocol!=="https:"?null:t.href}catch{return null}}function yl(e,t){if(!(t!=null&&t.length))return Ea(e);let n=0,r="";const o=[...t].filter(a=>Array.isArray(a.indices)&&a.indices.length>=2).map(a=>({...a,start:Math.max(0,Number(a.indices[0])||0),end:Math.max(0,Number(a.indices[1])||0)})).filter(a=>a.end>a.start&&a.start<e.length).sort((a,i)=>a.start-i.start);for(const a of o){const i=Math.max(n,a.start),s=Math.min(e.length,a.end);i>n&&(r+=Ea(e.slice(n,i)));const l=e.slice(i,s),c=iv(a.expanded_url??a.url);c?r+=`<a class="link" target="_blank" rel="noopener noreferrer" href="${Ea(c)}">${Ea(a.display_url??l)}</a>`:r+=Ea(l),n=s;}return n<e.length&&(r+=Ea(e.slice(n))),r}function Ja(e){if(!e)return Ji(0);const t=e.replace(/^\w+ (.*)$/,"$1");return Ji(t,"MMM DD HH:mm:ss ZZ YYYY","en")}function Pr(e,t){return (typeof e=="number"||typeof e=="string")&&(e=Ji(e)),e.format(t)}function Gf(e){if(!e)return null;const{day:t,month:n,year:r}=e,o=Ji().set("year",r??0).set("month",n-1).set("date",t);return r?o.format("MMM DD, YYYY"):o.format("MMM DD")}function kg(e){if(typeof e!="number"||Number.isNaN(e))return "N/A";const t=Math.floor(e/1e3),n=Math.floor(t/60),r=t%60;return `${n}:${r.toString().padStart(2,"0")}`}const sv="scrollmark",lv="Scrollmark: local-first X/Twitter research archive, search, and portable bundle export.",cv="1.3.0",uv="Kyle McCleary",dv="MIT",fv="https://github.com/kmccleary3301/scrollmark",hv="https://github.com/kmccleary3301/scrollmark/issues",pv="module",mv={clean:"rm -rf dist",dev:"vite",build:"tsc && vite build","build:store":"tsc && SCROLLMARK_BUILD_TARGET=store vite build","build:e2e":"tsc && TWE_BUILD_VARIANT=e2e vite build","build:chrome-e2e":"tsc && TWE_BUILD_VARIANT=chrome-e2e vite build","sync:store-artifact":"mkdir -p store && cp dist/scrollmark.store.user.js store/scrollmark.user.js","build:all":"npm run clean && npm run build && npm run build:store && npm run sync:store-artifact && npm run build:e2e && npm run build:chrome-e2e",prepare:"husky",lint:"eslint .","check:metadata":"node scripts/check-userscript-metadata.mjs","perf:large-count-smoke":"node scripts/large-count-smoke.mjs","test:result-source-contract":"tsx e2e/perf/result_source_contract_harness.ts","test:export-stream-integrity":"tsx e2e/perf/export_stream_integrity_harness.ts","test:db-source-live":"tsx e2e/perf/db_source_live_harness.ts","test:db-migration-compat":"tsx e2e/perf/db_migration_compat_harness.ts","test:write-indexing-regression":"tsx e2e/perf/write_indexing_regression_harness.ts","test:synthetic-seed-matrix":"tsx e2e/perf/synthetic_seed_matrix_harness.ts","test:recovered-db-import":"tsx e2e/perf/recovered_db_import_harness.ts","test:recovered-db-browser":"node e2e/perf/recovered_db_browser_harness.mjs","test:bookmarks-strict-folder":"tsx e2e/perf/bookmarks_strict_folder_harness.ts","test:result-set-lookup":"tsx e2e/perf/result_set_lookup_harness.ts","test:search-phrase-quality":"tsx e2e/perf/search_phrase_quality_harness.ts","test:search-performance":"tsx e2e/perf/search_performance_harness.ts","test:app-diagnostics-smoke":"node e2e/perf/app_diagnostics_smoke.mjs","test:search-threshold-guard":"tsx e2e/perf/search_threshold_guard_harness.ts","test:search-threshold-app":"node e2e/perf/search_threshold_app_harness.mjs","test:search-cancellation-app":"node e2e/perf/search_cancellation_app_harness.mjs","test:folder-search-app":"node e2e/perf/folder_search_app_harness.mjs","test:deep-scroll-app":"node e2e/perf/deep_scroll_app_harness.mjs","test:variable-height-table":"node e2e/perf/variable_height_table_harness.mjs","test:small-dataset-workflow":"node e2e/perf/small_dataset_workflow_harness.mjs","test:folder-source-stress":"node e2e/perf/folder_source_stress_harness.mjs","test:media-masonry-app":"node e2e/perf/media_masonry_app_harness.mjs","test:export-memory-app":"node e2e/perf/export_memory_app_harness.mjs","test:export-modal-app":"node e2e/perf/export_modal_app_harness.mjs",commitlint:"commitlint --edit",changelog:"git-cliff -o CHANGELOG.md",preview:"vite preview"},gv={"@preact/signals":"2.0.0","@preact/signals-core":"1.8.0","@tabler/icons-preact":"3.31.0","@tanstack/table-core":"8.21.2",dayjs:"1.11.13",dexie:"4.0.11","dexie-export-import":"4.1.4",fflate:"^0.8.2","file-saver-es":"2.0.5",i18next:"24.2.3",preact:"10.26.4"},yv={"@commitlint/cli":"^19.8.0","@commitlint/config-conventional":"^19.8.0","@eslint/js":"^9.23.0","@preact/preset-vite":"^2.10.1","@types/file-saver-es":"^2.0.3","@types/node":"^22.14.0",autoprefixer:"^10.4.21",daisyui:"^4",eslint:"^9.23.0","eslint-config-prettier":"^10.1.1","eslint-plugin-prettier":"^5.2.6","fake-indexeddb":"^6.2.5","git-cliff":"^2.8.0",husky:"^9.1.7",playwright:"^1.60.0",postcss:"^8.5.3","postcss-prefix-selector":"^2.1.1","postcss-rem-to-pixel-next":"^5.0.3",tailwindcss:"^3",tsx:"^4.22.2",typescript:"^5.8.2","typescript-eslint":"^8.29.0",vite:"^6.2.5","vite-plugin-i18next-loader":"^3.1.2","vite-plugin-monkey":"^5.0.8"},vr={name:sv,description:lv,version:cv,author:uv,license:dv,homepage:fv,bugs:hv,private:true,type:pv,scripts:mv,dependencies:gv,devDependencies:yv},Qs={theme:"system",debug:false,showControlPanel:true,disabledExtensions:["HomeTimelineModule"],dateTimeFormat:"YYYY-MM-DD HH:mm:ss Z",filenamePattern:"{screen_name}_{id}_{type}_{num}_{date}.{ext}",language:"",dedicatedDbForAccounts:false,safeMode:false,hookMode:"both",repairMode:"watchdog",directMessagesCaptureEnabled:false,rawCaptureEncryptedStorageReady:false,rawCapturePolicyPublicEnabled:true,rawCapturePolicySensitiveEnabled:true,rawCapturePolicyDmEnabled:true,rawCaptureEnabled:true,rawCaptureStreamEnabled:false,rawCaptureDaemonUrl:"http://127.0.0.1:8754",version:vr.version},_v=["system","cupcake","dark","emerald","cyberpunk","valentine","lofi","dracula","cmyk","business","winter"],Yf=vr.name,wv=new Set(["RetweetersModule","ListTimelineModule","ListSubscribersModule","ListMembersModule","CommunityMembersModule","CommunityTimelineModule"]);function Xf(e){const n=(Array.isArray(e)?e.filter(r=>typeof r=="string"):[]).filter(r=>!wv.has(r));return Array.from(new Set(n))}class bv{constructor(){je(this,"appOptions",{...Qs});je(this,"previous",{...Qs});je(this,"signal",new Un(0));this.loadAppOptions();}get(t,n){return this.appOptions[t]??n}set(t,n){this.appOptions[t]=n,this.saveAppOptions();}loadAppOptions(){this.appOptions={...this.appOptions,...ov(localStorage.getItem(Yf)||"{}")},this.appOptions.disabledExtensions=Xf(this.appOptions.disabledExtensions);const t=this.appOptions.version??"",n=Qs.version;n.startsWith("1.1")&&t.startsWith("1.0")&&(this.appOptions.disabledExtensions=[...Xf(this.appOptions.disabledExtensions),"HomeTimelineModule","ListTimelineModule"],Ie.info(`App options migrated from v${t} to v${n}`),setTimeout(()=>this.saveAppOptions(),0)),this.previous={...this.appOptions},Ie.info("App options loaded",this.appOptions),this.signal.value++;}saveAppOptions(){const t=this.previous,n={...this.appOptions,version:vr.version};av(t,n)||(this.appOptions=n,localStorage.setItem(Yf,JSON.stringify(this.appOptions)),this.previous={...this.appOptions},Ie.debug("App options saved",this.appOptions),this.signal.value++);}}const ut=new bv,xg={en:{name:"English",nameEn:"English",test:e=>/^en/.test(e)},"zh-Hans":{name:"简体中文",nameEn:"Simplified Chinese",test:e=>/^zh/.test(e)},es:{name:"Español",nameEn:"Spanish",test:e=>/^es/.test(e)},hi:{name:"हिन्दी",nameEn:"Hindi",test:e=>/^hi/.test(e)},fr:{name:"Français",nameEn:"French",test:e=>/^fr/.test(e)},ar:{name:"العربية",nameEn:"Arabic",test:e=>/^ar/.test(e)},bn:{name:"বাংলা",nameEn:"Bengali",test:e=>/^bn/.test(e)},"pt-BR":{name:"Português (Brasil)",nameEn:"Portuguese",test:e=>/^pt/.test(e)},ru:{name:"Русский",nameEn:"Russian",test:e=>/^ru/.test(e)},ur:{name:"اردو",nameEn:"Urdu",test:e=>/^ur/.test(e)},id:{name:"Bahasa Indonesia",nameEn:"Indonesian",test:e=>/^id/.test(e)},ja:{name:"日本語",nameEn:"Japanese",test:e=>/^ja/.test(e)}};function Sg(){const e=window.navigator.language||"en";for(const[t,n]of Object.entries(xg))if(n.test(e))return t;return e}const vv={type:"languageDetector",detect:function(){return ut.get("language")||Sg()}},kv="twe_i18n_debug_v1";function xv(e){if(!e)return  false;const t=e.trim().toLowerCase();return t==="1"||t==="true"||t==="yes"||t==="on"}function Sv(){try{return xv(localStorage.getItem(kv))}catch{return  false}}function Cv(){return Pn.isInitialized||(Pn.on("languageChanged",e=>{ut.get("language")||ut.set("language",e);}),Pn.use(vv).init({initImmediate:true,defaultNS:"common",fallbackLng:"en",nsSeparator:"::",interpolation:{escapeValue:false},debug:Sv(),resources:Lb})),Pn}function Wn(e){const t=Cv(),[n,r]=De(()=>t.getFixedT(null,e??null)),o=_t(true),a=_t(e);return Je(()=>{o.current=true,a.current!==e&&(a.current=e,r(()=>t.getFixedT(null,e??null)));function i(){o.current&&r(()=>t.getFixedT(null,e??null));}return t.on("languageChanged",i),()=>{o.current=false,t.off("languageChanged",i);}},[e]),{t:n,i18n:t}}function gt({i18nKey:e,ns:t="exporter"}){const{t:n}=Wn(t);return d("span",{children:n(e)})}class Li extends Fr{constructor(){super(...arguments);je(this,"state",{error:null});}static getDerivedStateFromError(n){return {error:n.message}}componentDidCatch(n){Ie.error(n.message,n),this.setState({error:n.message});}render(){return this.state.error?d("div",{class:"alert alert-error p-2",children:[d(Bw,{}),d("div",{children:[d("h3",{class:"font-bold leading-normal",children:d(gt,{ns:"common",i18nKey:"Something went wrong."})}),d("p",{class:"text-xs",children:[d(gt,{ns:"common",i18nKey:"Error:"})," ",this.state.error]})]})]}):this.props.children}}var _l=typeof GM_registerMenuCommand<"u"?GM_registerMenuCommand:void 0,Tv=typeof unsafeWindow<"u"?unsafeWindow:void 0;class Mv{dispatch(t,n,r){t.filter(o=>o.enabled).forEach(o=>{try{const a=o.intercept();if(!a)return;const i=Date.now();Cc({ts:i,extension:o.name,phase:"claimed",request_id:n.requestId,method:n.method,url:n.url,status:r.status}),a(n,r,o),Cc({ts:Date.now(),extension:o.name,phase:"completed",request_id:n.requestId,method:n.method,url:n.url,status:r.status,duration_ms:Math.max(0,Date.now()-i)});}catch(a){Cc({ts:Date.now(),extension:o.name,phase:"error",request_id:n.requestId,method:n.method,url:n.url,status:r.status,error:a instanceof Error?a.message:String(a)}),Ie.error(`Interceptor error (${o.name}):`,a);}});}}const Rv="twe_safe_mode_v1",Iv="twe_hook_mode_v1",Ev="twe_repair_mode_v1",Av="twe_debug_disable_xhr_open_wrap_v1",Dv="twe_debug_disable_xhr_send_wrap_v1",Pv="twe_debug_disable_xhr_load_listener_v1",Ov="twe_debug_disable_fetch_wrap_v1",Fv="twe_debug_disable_expando_meta_v1",Lv="twe_debug_force_call_not_apply_v1",Nv="twe_debug_hook_diag_v1",Bv="twe_console_verbose_v1",Uv=6,Zf=1100,$v=6e4,Qf=5;function Hv(e){return e==="xhr"||e==="fetch"||e==="off"?e:"both"}function jv(e){return e==="off"?"off":"watchdog"}function So(e){try{return typeof localStorage>"u"?null:localStorage.getItem(e)}catch{return null}}function Tc(e,t){try{if(typeof localStorage>"u")return;localStorage.setItem(e,t);}catch{}}function Co(e){if(!e)return  false;const t=e.trim().toLowerCase();return t==="1"||t==="true"||t==="yes"||t==="on"}function Jf(){const e=Co(So(Nv)),t=Co(So(Bv));return {disableXhrOpenWrap:Co(So(Av)),disableXhrSendWrap:Co(So(Dv)),disableXhrLoadListener:Co(So(Pv)),disableFetchWrap:Co(So(Ov)),disableExpandoMeta:Co(So(Fv)),forceCallNotApply:Co(So(Lv)),hookDiag:e&&t}}function eh(){const e=!!ut.get("safeMode",false),t=Hv(ut.get("hookMode","both")),n=jv(ut.get("repairMode","watchdog"));return {safeMode:e,hookMode:t,repairMode:n}}class qv{constructor(t){je(this,"runtimeModes",eh());je(this,"hookDebugConfig",Jf());je(this,"hookDiagCounters",Object.create(null));je(this,"runtimeModeReason","");je(this,"hookRepairInterval",null);je(this,"hookBootProbeTimeout",null);je(this,"hookRepairBackoffMs",Zf);je(this,"hookRepairFailures",0);this.host=t;}initialize(){if(this.refreshRuntimeModes(),this.runtimeModes.hookMode!=="off")try{this.host.installPageMessageBridge();}catch(t){this.enableSafeMode("install-page-message-bridge-failed",t);}if(!this.runtimeModes.safeMode&&this.runtimeModes.hookMode!=="off")try{this.host.installBookmarkContextTracking();}catch(t){const n=t instanceof Error?`${t.name}: ${t.message}`:`unknown error: ${String(t)}`;Ie.warn(`Bookmark context tracking install failed; continuing without tracker (${n})`);}try{this.isHookModeEnabled("xhr")&&this.host.installHttpHooks(),this.isHookModeEnabled("fetch")&&this.host.installFetchHooks();const t=this.host.runHookSelfTest();t.ok?!this.runtimeModes.safeMode&&this.runtimeModes.repairMode!=="off"&&this.startHookRepairLoop():this.enableSafeMode("hook-self-test-failed",t.error),this.runtimeModes.safeMode||this.startFetchHookBootProbe();}catch(t){this.enableSafeMode("hook-install-failed",t);}}dispose(){this.clearHookRepairLoop(),this.clearFetchHookBootProbe(),this.host.uninstallHooks();}applyRuntimeModesFromOptions(){const t={...this.runtimeModes};this.refreshRuntimeModes();const n=this.runtimeModes;if(!(t.safeMode===n.safeMode&&t.hookMode===n.hookMode&&t.repairMode===n.repairMode)){if(n.safeMode||(this.runtimeModeReason=""),n.hookMode==="off"){this.host.uninstallHooks(),this.clearHookRepairLoop(),this.clearFetchHookBootProbe();return}if(n.safeMode){this.host.uninstallHooks(),this.clearHookRepairLoop(),this.clearFetchHookBootProbe();try{this.host.installPageMessageBridge(),this.isHookModeEnabled("xhr")&&this.host.installHttpHooks(!0),this.isHookModeEnabled("fetch")&&this.host.installFetchHooks(!0);}catch(r){Ie.warn("Failed to reconfigure lightweight safe mode hooks",r??"");}return}try{this.host.installPageMessageBridge(),this.host.installBookmarkContextTracking(),this.isHookModeEnabled("xhr")&&this.host.installHttpHooks(!0),this.isHookModeEnabled("fetch")&&this.host.installFetchHooks(!0);const r=this.host.runHookSelfTest();if(!r.ok){this.runtimeModeReason="hook-self-test-failed",Ie.warn("Hook self-test failed after runtime reconfigure",r.error??""),this.publishRuntimeModes({enabledAt:Date.now(),error:r.error?String(r.error):void 0});return}this.runtimeModes.repairMode!=="off"?this.startHookRepairLoop():this.clearHookRepairLoop(),this.startFetchHookBootProbe();}catch(r){this.enableSafeMode("hook-reconfigure-failed",r);}}}getRuntimeModesSnapshot(){return {safeMode:this.runtimeModes.safeMode,hookMode:this.runtimeModes.hookMode,repairMode:this.runtimeModes.repairMode,reason:this.runtimeModeReason||void 0}}getHookStatsSnapshot(){return this.host.readHookStatsSnapshot()}getRuntimeModes(){return this.runtimeModes}getHookDebugConfig(){return this.hookDebugConfig}refreshHookDebugConfig(){this.hookDebugConfig=Jf();}isHookModeEnabled(t){return this.runtimeModes.hookMode==="off"?false:this.runtimeModes.hookMode==="both"?true:this.runtimeModes.hookMode===t}emitHookDiag(t,n,r){const o=!!(r!=null&&r.force);if(!this.hookDebugConfig.hookDiag)return;const a=(this.hookDiagCounters[t]??0)+1;this.hookDiagCounters[t]=a,!(!o&&a>Uv)&&Ie.info(`TWE_DIAG ${t}`,{...n,count:a,safeMode:this.runtimeModes.safeMode,hookMode:this.runtimeModes.hookMode,repairMode:this.runtimeModes.repairMode,forceCallNotApply:this.hookDebugConfig.forceCallNotApply,disableExpandoMeta:this.hookDebugConfig.disableExpandoMeta,ts:Date.now()});}enableSafeMode(t,n){this.clearFetchHookBootProbe(),this.runtimeModes.safeMode=true,this.runtimeModeReason=t,this.persistRuntimeModes(),this.publishRuntimeModes({enabledAt:Date.now(),error:n?String(n):void 0}),this.host.uninstallHooks(),this.clearHookRepairLoop(),Ie.error(`Hook safe mode enabled (${t})`,n??"");}startFetchHookBootProbe(t=1200){this.runtimeModes.safeMode||!this.isHookModeEnabled("fetch")||(this.clearFetchHookBootProbe(),this.hookBootProbeTimeout=setTimeout(()=>{this.hookBootProbeTimeout=null,!(this.runtimeModes.safeMode||!this.isHookModeEnabled("fetch"))&&this.host.runFetchHookBootProbePass();},t));}startHookRepairLoop(){if(this.runtimeModes.safeMode||this.runtimeModes.repairMode==="off"||this.hookRepairInterval!==null)return;const t=r=>{this.hookRepairInterval=setTimeout(()=>{this.hookRepairInterval=null,n();},r);},n=()=>{if(!(this.runtimeModes.safeMode||this.runtimeModes.repairMode==="off")){try{const r=this.host.runHookRepairPass();if(!r.ok){this.enableSafeMode("hook-repair-self-test-failed",r.error);return}this.hookRepairFailures=0,this.hookRepairBackoffMs=Zf;}catch(r){if(this.hookRepairFailures+=1,this.hookRepairBackoffMs=Math.min(this.hookRepairBackoffMs*2,$v),Ie.warn(`Hook repair failed (${this.hookRepairFailures}/${Qf})`,r),this.hookRepairFailures>=Qf){this.enableSafeMode("hook-repair-failure-limit",r);return}}t(this.hookRepairBackoffMs);}};t(0);}clearHookRepairLoop(){this.hookRepairInterval!==null&&(clearTimeout(this.hookRepairInterval),this.hookRepairInterval=null);}clearFetchHookBootProbe(){this.hookBootProbeTimeout!==null&&(clearTimeout(this.hookBootProbeTimeout),this.hookBootProbeTimeout=null);}persistRuntimeModes(){Tc(Rv,this.runtimeModes.safeMode?"1":"0"),Tc(Iv,this.runtimeModes.hookMode),Tc(Ev,this.runtimeModes.repairMode);try{ut.set("safeMode",this.runtimeModes.safeMode),ut.set("hookMode",this.runtimeModes.hookMode),ut.set("repairMode",this.runtimeModes.repairMode);}catch{}}publishRuntimeModes(t){}refreshRuntimeModes(){this.runtimeModes=eh(),this.refreshHookDebugConfig(),this.persistRuntimeModes(),this.publishRuntimeModes();}}function Cg(){try{return Tv??null}catch{return null}}function Tg(e){try{const t=e;return !(t!=null&&t.wrappedJSObject)||typeof t.wrappedJSObject!="object"?null:t.wrappedJSObject}catch{return null}}let Ts=null;function Ni(){if(Ts)return Ts;const e=Cg();return Ts=Tg(e)??e??(typeof window<"u"?window:null)??globalThis,Ts}const An=new Proxy({},{get(e,t){const n=Ni();return Reflect.get(n,t,n)},set(e,t,n){const r=Ni();return Reflect.set(r,t,n,r)}});function Mg(){try{return globalThis.exportFunction}catch{return}}const Vv="__twe_mcp_hook_v1",$r="__twe_orig_xhr_open_v1",Hr="__twe_orig_xhr_send_v1",Aa="__twe_orig_fetch_v1",zv="__twe_bootstrap_error_v1",Bi=45e3,Kv=18e4,Wv=6,Gv=12,Rg=200,uo=3,Yv="twitter-web-exporter-extension-manager-v1",Xv=3,Ig=2600,Zv=500,Qv=120;function Jv(){const e=Cg();return {hasUnsafeWindow:!!e,hasWrappedJSObject:!!Tg(e),hasExportFunction:!!Mg()}}function ek(e){let t=2166136261;for(let n=0;n<e.length;n++)t^=e.charCodeAt(n),t=Math.imul(t,16777619);return (t>>>0).toString(16)}function tk(e,t,n,r){return `${e.toUpperCase()} ${t} ${n} ${ek(r)}`}function nk(e){const t=Date.now();if(e.size<=Zv)return;const n=[...e.entries()].filter(([,r])=>t-r.at>Ig).sort((r,o)=>r[1].at-o[1].at);for(const[r]of n.slice(0,Qv))e.delete(r);}function Mc(e){return {xhrMessages:0,fetchMessages:0,lastUrl:"",lastAt:0,loggedUrls:0,messagesTotal:0,messagesLegacyShape:0,messagesMissingContext:0,messagesRepairedAtBridge:0,messagesMissingBody:0,responsesProcessed:0,responsesSkippedDuplicate:0,lastMessageAt:0,activeInstanceId:e,rev:uo,repairCount:0,endpointStats:Object.create(null)}}let Vr={folderId:null,pageUrl:"",source:"startup",capturedAt:0},Cd=null,th=[];const Ou=new WeakMap;function rk(){return {method:"GET",url:"",body:"",requestId:"",bookmarkContext:null,hooked:false}}function ok(e){const t=Ou.get(e);if(t)return t;const n=rk();return Ou.set(e,n),n}function Rc(e,t){if(t.disableExpandoMeta)return ok(e);const n=typeof e.__twe_req_method_v1=="string"?e.__twe_req_method_v1:"GET",r=typeof e.__twe_req_url_v1=="string"?e.__twe_req_url_v1:"",o=typeof e.__twe_req_body_v1=="string"?e.__twe_req_body_v1:"",a=typeof e.__twe_req_id_v1=="string"?e.__twe_req_id_v1:"",i=e.__twe_req_bookmark_context_v1&&typeof e.__twe_req_bookmark_context_v1=="object"?e.__twe_req_bookmark_context_v1:null,s=!!e.__twe_hooked_v1;return {method:n,url:r,body:o,requestId:a,bookmarkContext:i,hooked:s}}function Ic(e,t,n){if(t.disableExpandoMeta){Ou.set(e,n);return}e.__twe_req_method_v1=n.method,e.__twe_req_url_v1=n.url,e.__twe_req_body_v1=n.body,e.__twe_req_id_v1=n.requestId,e.__twe_req_bookmark_context_v1=n.bookmarkContext,e.__twe_hooked_v1=n.hooked;}function Ec(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2]);case 4:return e.call(t,n[0],n[1],n[2],n[3]);default:return e.call(t,n[0],n[1],n[2],n[3],n[4])}}function ak(e,t,n){const r=n instanceof Error?`${n.name}: ${n.message}`:String(n),o=n instanceof Error?n.stack:void 0;return {message:r,stack:o,phase:e,instanceId:t,at:Date.now()}}function ik(){try{((t,n)=>{t&&typeof t=="object"&&delete t[n];})(globalThis,zv);}catch{}}function sk(e,t){if(!e||typeof e!="object")return t;const n=e;return {...n,xhrMessages:Number(n.xhrMessages)||0,fetchMessages:Number(n.fetchMessages)||0,lastUrl:typeof n.lastUrl=="string"?n.lastUrl:"",lastAt:Number(n.lastAt)||0,loggedUrls:Number(n.loggedUrls)||0,messagesTotal:Number(n.messagesTotal)||0,messagesLegacyShape:Number(n.messagesLegacyShape)||0,messagesMissingContext:Number(n.messagesMissingContext)||0,messagesRepairedAtBridge:Number(n.messagesRepairedAtBridge)||0,messagesMissingBody:Number(n.messagesMissingBody)||0,responsesProcessed:Number(n.responsesProcessed)||0,responsesSkippedDuplicate:Number(n.responsesSkippedDuplicate)||0,lastMessageAt:Number(n.lastMessageAt)||0,activeInstanceId:typeof n.activeInstanceId=="string"?n.activeInstanceId:t.activeInstanceId,rev:Number(n.rev)||uo,repairCount:Number(n.repairCount)||0,endpointStats:n.endpointStats||Object.create(null)}}function lk(e){if(typeof e!="function")return "";try{return Function.prototype.toString.call(e)}catch{return ""}}function Da(e,t){if(!e||typeof e!="function")return  false;const n=e;return n[t]?n.__twe_is_hook_revision_v1===uo:false}function wl(e,t){if(!e||typeof e!="function")return  false;const n=e;if(n.__twe_is_hook_open_v1||n.__twe_is_hook_send_v1||n.__twe_is_hook_fetch_v1||n.__twe_orig_xhr_open_v1||n.__twe_orig_xhr_send_v1||n.__twe_orig_fetch_v1||t&&n[t])return  true;const r=lk(e);return r?r.includes("__twe_mcp_hook_v1")||r.includes("__twe_is_hook_open_v1")||r.includes("__twe_is_hook_send_v1")||r.includes("__twe_is_hook_fetch_v1")||r.includes("__twe_is_hook_revision_v1")||r.includes("__twe_orig_xhr_open_v1")||r.includes("__twe_orig_xhr_send_v1")||r.includes("__twe_orig_fetch_v1")||r.includes("__twe_req_body_v1")||r.includes("__twe_req_url_v1")||r.includes("__twe_req_bookmark_context_v1"):false}const Eg=`${Date.now().toString(36)}-${Math.random().toString(36).slice(2,8)}`;let nh=0;function ja(){return nh+=1,`${Eg}-${nh}`}function ck(e){var n,r,o,a,i,s,l,c;if(!Array.isArray(e))return [];const t=[];for(const h of e){const f=h;f&&typeof f.requestId=="string"&&typeof f.ts=="number"&&typeof f.url=="string"&&t.push({requestId:f.requestId,ts:f.ts,method:typeof f.method=="string"?f.method:"GET",url:f.url,hasBody:!!f.hasBody,confidenceSource:typeof f.confidenceSource=="string"&&f.confidenceSource?f.confidenceSource:typeof((n=f.context)==null?void 0:n.source)=="string"?f.context.source:"unknown",context:{folderId:typeof((r=f.context)==null?void 0:r.folderId)=="string"?f.context.folderId:null,pageUrl:typeof((o=f.context)==null?void 0:o.pageUrl)=="string"?f.context.pageUrl:"",source:typeof((a=f.context)==null?void 0:a.source)=="string"?f.context.source:"unknown",capturedAt:typeof((i=f.context)==null?void 0:i.capturedAt)=="number"?f.context.capturedAt:Date.now(),requestId:typeof((s=f.context)==null?void 0:s.requestId)=="string"?f.context.requestId:void 0,routeSource:typeof((l=f.context)==null?void 0:l.routeSource)=="string"?f.context.routeSource:void 0,pageRouteUrl:typeof((c=f.context)==null?void 0:c.pageRouteUrl)=="string"?f.context.pageRouteUrl:void 0},normalizedRoute:typeof f.normalizedRoute=="string"?f.normalizedRoute:""});}return t.sort((h,f)=>f.ts-h.ts).slice(0,Rg)}function uk(e){var s,l,c,h,f,m,g,_;const t=Date.now(),n={requestId:e.requestId||`${Eg}-${t}`,ts:Number.isFinite(e.ts)?e.ts:t,method:e.method||"GET",url:e.url||"",hasBody:!!e.hasBody,confidenceSource:typeof e.confidenceSource=="string"&&e.confidenceSource?e.confidenceSource:((s=e.context)==null?void 0:s.source)||"unknown",context:{folderId:((l=e.context)==null?void 0:l.folderId)??null,pageUrl:((c=e.context)==null?void 0:c.pageUrl)||"",source:((h=e.context)==null?void 0:h.source)||"unknown",capturedAt:Number.isFinite((f=e.context)==null?void 0:f.capturedAt)?e.context.capturedAt:t,requestId:(m=e.context)==null?void 0:m.requestId,routeSource:(g=e.context)==null?void 0:g.routeSource,pageRouteUrl:(_=e.context)==null?void 0:_.pageRouteUrl},normalizedRoute:e.normalizedRoute||""},r=ck(th);r.unshift(n);const o=new Map;for(const b of r)o.has(b.requestId)||o.set(b.requestId,b);const a=Array.from(o.values()).slice(0,Rg).sort((b,C)=>C.ts-b.ts),i=Date.now()-Bi*6;th=a.filter(b=>!i||b.ts>=i);}function dk(e){const t={folderId:e.folderId,pageUrl:e.pageUrl||"",source:e.source||"lock",capturedAt:e.capturedAt||Date.now(),requestId:e.requestId,routeSource:e.routeSource,pageRouteUrl:e.pageRouteUrl};t.folderId&&(Cd=t);}function fk(e=Date.now()){const t=[Cd];for(const n of t){if(!n||typeof n!="object")continue;const r=n;if(typeof r.folderId!="string"||!r.folderId)continue;const o=typeof r.capturedAt=="number"&&Number.isFinite(r.capturedAt)?r.capturedAt:0;if(!(!o||e-o>Kv))return {folderId:r.folderId,pageUrl:typeof r.pageUrl=="string"?r.pageUrl:"",source:typeof r.source=="string"?r.source:"lock",capturedAt:o,requestId:typeof r.requestId=="string"?r.requestId:void 0,routeSource:typeof r.routeSource=="string"?r.routeSource:void 0,pageRouteUrl:typeof r.pageRouteUrl=="string"?r.pageRouteUrl:void 0}}return null}function hk(){Cd=null;}function Ag(e){return Uo(e)||{folderId:null,pageUrl:e}}function ra(e,t){if(typeof e=="function")try{const n=e;n[t]=!0,n.__twe_is_hook_revision_v1=uo;}catch{}}function Dg(e){const t=e,n={method:typeof t.method=="string"?t.method:"GET",url:typeof t.url=="string"?t.url:""};return typeof t.body=="string"&&(n.body=t.body),t.bookmarkContext!==void 0&&(n.bookmarkContext=t.bookmarkContext),n.bookmarkContext===void 0&&t.requestContext!==void 0&&(n.bookmarkContext=t.requestContext),typeof t.requestId=="string"&&t.requestId&&(n.requestId=t.requestId),typeof t.__twe_hook_revision_v1=="number"&&Number.isFinite(t.__twe_hook_revision_v1)&&(n.hookRevision=t.__twe_hook_revision_v1),n}function Js(e){const t=Dg(e),n=typeof t.requestId=="string"&&t.requestId.trim().length>0?t.requestId:ja(),r=typeof t.method=="string"&&t.method?t.method:"GET",o=typeof t.url=="string"?t.url:"",a=typeof t.body=="string"?t.body:"",i=jl(t.bookmarkContext,{requestId:n,hasBody:a.length>0});return {method:r,url:o,body:a,bookmarkContext:i,requestId:n,hookRevision:uo,__twe_hook_revision_v1:uo}}function pk(e){if(!e||typeof e!="object")return null;const t=e;return t.req&&typeof t.req=="object"?t.req:t}function mk(e){if(!e||typeof e!="object")return null;const t=e,n=t.req;return typeof t.__twe_msg_revision_v1=="number"?Number(t.__twe_msg_revision_v1):n&&typeof n=="object"&&typeof n.__twe_hook_revision_v1=="number"?Number(n.__twe_hook_revision_v1):null}function rh(){return {received:0,processed:0,skippedDuplicate:0,newUniqueTweets:0,legacyShape:0,missingContext:0,lastAt:0,lastStatus:0,lastUrl:""}}function gk(e){try{const n=new URL(e,"https://x.com").pathname.toLowerCase(),r=n.match(/\/graphql\/[^/]+\/([^/?#]+)/);if(r!=null&&r[1])return `graphql:${r[1]}`;const o=n.match(/\/i\/api\/1\.1\/([^/?#]+)/);if(o!=null&&o[1])return `api:${o[1]}`}catch{}return "other"}function yk(e){const t=new Set,n=/"rest_id"\s*:\s*"(\d{10,})"/g;for(;;){const r=n.exec(e);if(!r)break;r[1]&&t.add(r[1]);}return t.size}function oh(e){try{if(!e)return;if(typeof e=="string")return e;if(typeof URLSearchParams<"u"&&e instanceof URLSearchParams)return e.toString();if(typeof FormData<"u"&&e instanceof FormData)try{return [...e.entries()].map(([n,r])=>`${n}=${String(r).slice(0,200)}`).join("&")}catch{return}return typeof Blob<"u"&&e instanceof Blob?`blob:${e.type||"application/octet-stream"}:${e.size}`:void 0}catch{return}}function Uo(e){try{const t=new URL(e,"https://x.com"),n=t.pathname.match(/\/bookmarks\/(\d+)/);return {folderId:(n==null?void 0:n[1])??null,pageUrl:t.href}}catch{return null}}function Pg(e){if(typeof e=="number"&&Number.isFinite(e)){const n=String(Math.trunc(e));return /^\d+$/.test(n)?n:null}if(typeof e!="string")return null;const t=e.trim();return /^\d+$/.test(t)?t:null}function _k(e){const t=e.toLowerCase().replace(/[^a-z0-9]/g,"");return /^(bookmarkcollectionid|bookmarkfolderid|bookmarkcollection|folderid|collectionid|bookmarkfolder|bookmarkcollectionid)/.test(t)}function ei(e,t=0,n=new Set){if(!e||t>Wv)return null;if(typeof e=="string"){const o=Uo(e);if(o!=null&&o.folderId)return {folderId:o.folderId,pageUrl:o.pageUrl};const a=e.match(/(?:bookmark|folder|collection)[^\w]{0,20}(?:id|_id|Id|_Id)\W*[:=]\W*["']?(\d{5,})["']?/i);return a!=null&&a[1]?{folderId:a[1]}:null}if(typeof e!="object")return null;if(Array.isArray(e)){for(const o of e){const a=ei(o,t+1,n);if(a!=null&&a.folderId)return a}return null}const r=e;if(n.has(r))return null;n.add(r);for(const[o,a]of Object.entries(r)){const i=_k(o)?Pg(a):null;if(i){const l=typeof a=="string"?a:"",c=l?Uo(l):null;return c!=null&&c.folderId?{folderId:c.folderId,pageUrl:c.pageUrl}:{folderId:i}}const s=ei(a,t+1,n);if(s!=null&&s.folderId)return s}return null}const Og=["bookmark_collection_id","bookmarkcollectionid","bookmarkCollectionId","folder_id","folderid","folderId","collection_id","collectionid","collectionId"];function wk(e){if(!e)return null;let t;try{t=JSON.parse(decodeURIComponent(e));}catch{try{t=JSON.parse(e);}catch{return null}}const n=ei(t);if(n!=null&&n.folderId)return n.folderId;if(t&&typeof t=="object"){const r=t;for(const o of Og){const a=r[o],i=Pg(a);if(i)return i}}return null}function bk(e){try{const t=new URL(e,"https://x.com"),n=Og.map(o=>t.searchParams.get(o)).find(o=>!!o&&/^\d+$/.test(o));if(n)return n;const r=wk(t.searchParams.get("variables"));return r||null}catch{return null}}function vk(e){if(!e)return null;let t;try{t=JSON.parse(e);}catch{try{const o=new URLSearchParams(e).get("variables");if(o)t=JSON.parse(o);else return null}catch{return null}}const n=ei(t);return n!=null&&n.folderId?n.folderId:null}function kk(e){try{const n=new URL(e,location.href).pathname.match(/\/bookmarks\/(\d+)/);return (n==null?void 0:n[1])??null}catch{return null}}function xk(e){return e||"bookmark-tab"}function Sk(){try{if(typeof performance>"u"||typeof performance.getEntriesByType!="function")return null;const e=performance.getEntriesByType("navigation"),t=e[e.length-1];if(!t||!t.name)return null;const n=Uo(t.name);return n!=null&&n.folderId?{folderId:n.folderId,pageUrl:n.pageUrl,source:"performance",confidence:88}:null}catch{return null}}function Ck(){if(typeof document>"u")return null;const e=['[role="tab"] a[href*="/i/bookmarks/"]','a[role="tab"][href*="/i/bookmarks/"]','[role="tablist"] a[href*="/i/bookmarks/"]','a[href*="/i/bookmarks/"]','nav a[href*="/bookmarks/"]','[data-testid="primaryColumn"] a[href*="/bookmarks/"]','a[href*="/bookmarks/"]'],t=[],n=[],r=new Set;for(const i of e){const s=Array.from(document.querySelectorAll(i));for(const l of s){if(!(l instanceof HTMLAnchorElement))continue;const c=l.getAttribute("href");if(!c)continue;const h=kk(c);if(!h)continue;const f=h;if(r.has(f))continue;r.add(f);const m=(()=>{try{return new URL(c,location.href).href}catch{return c}})(),g=l.closest("a[href]")||l,_=(O,B)=>O==null?void 0:O.getAttribute(B),b=(O,B)=>_(O,B)==="true",C=b(g,"aria-selected")||b(g,"aria-current")||b(g,"data-selected")||b(g,"data-state"),k=!!g.closest('[role="tablist"]'),T=g instanceof HTMLAnchorElement&&(g.role==="tab"||!!g.closest('[role="tab"]'));let M=null;try{M=window.getComputedStyle(g);}catch{}const P=M?M.display!=="none"&&M.visibility!=="hidden"&&M.opacity!=="0":true;let F=0;C&&(F+=20),k&&(F+=5),T&&(F+=3),P&&(F+=2);const I={folderId:f,pageUrl:m,source:xk(g.getAttribute("data-testid")??(T?"bookmark-tab":null)),score:F};n.push(I),C&&t.push(I);}}const o=t.length>0?t:n;if(!o.length)return null;o.sort((i,s)=>i.score!==s.score?s.score-i.score:i.folderId.localeCompare(s.folderId));const a=o[0];return a?{folderId:a.folderId,pageUrl:a.pageUrl,source:a.source,confidence:Math.max(t.length>0?45:25,a.score+(t.length>0?45:25))}:null}function Tk(){var e;try{const t=(e=An.history)==null?void 0:e.state;if(!t)return null;const n=ei(t);if(!(n!=null&&n.folderId))return null;const r=n.pageUrl||(typeof location<"u"?location.href:"");return {folderId:n.folderId,pageUrl:r,source:"history-state",confidence:86}}catch{return null}}function Mk(){const e=["__INITIAL_STATE__","__NEXT_DATA__","__INITIAL_PROPS__","__NEXT_REDUX_STATE__","__META_DATA__"],t=[],n=An;for(const r of e){const o=n[r];o&&t.push({source:r,value:o});}for(const{source:r,value:o}of t){const a=ei(o);if(a!=null&&a.folderId)return {folderId:a.folderId,pageUrl:a.pageUrl||(typeof location<"u"?location.href:""),source:r,confidence:82}}return null}function Rk(e){var i;if(!e||typeof e!="object")return null;const t=[],n=new Set,r=s=>{s instanceof Element&&!n.has(s)&&(n.add(s),t.push(s));};r(e);const o=e;typeof o.composedPath=="function"&&(o.composedPath()||[]).forEach(l=>{r(l);});const a=e;r(a.target),r(a.currentTarget);for(const s of t){const l=(i=s.closest)==null?void 0:i.call(s,"a[href]"),c=s instanceof HTMLAnchorElement?s:l;if(!c)continue;const h=c.getAttribute("href");if(!h||!h.includes("/i/bookmarks/"))continue;const f=Uo(h);if(f!=null&&f.folderId)return {folderId:f.folderId,pageUrl:f.pageUrl,source:"bookmark-click",confidence:92}}return null}function sa(e){try{const t=new URL(e,"https://x.com").pathname.toLowerCase();return /(bookmarks|bookmarkfolderslice|bookmarkfoldertimeline|bookmarkcollectiontimeline|bookmarkcollectionstimeline)/.test(t)}catch{return  false}}function wi(e,t,n){const r=Date.now(),o=typeof location<"u"?location.href:"",a=Ag(o);if(sa(e)){const i=bk(e);if(i)return {folderId:i,pageUrl:o,source:"request-url",capturedAt:r,requestId:n==null?void 0:n.requestId,routeSource:"request-url",pageRouteUrl:a==null?void 0:a.pageUrl};const s=vk(t);if(s)return {folderId:s,pageUrl:o,source:"request-body",capturedAt:r,requestId:n==null?void 0:n.requestId,routeSource:"request-body",pageRouteUrl:a==null?void 0:a.pageUrl};if(a!=null&&a.folderId)return {folderId:a.folderId,pageUrl:a.pageUrl||o,source:"page-route",capturedAt:r,requestId:n==null?void 0:n.requestId,routeSource:"location",pageRouteUrl:a.pageUrl||o};const l=fk(r);if(l!=null&&l.folderId&&vl(o))return {folderId:l.folderId,pageUrl:l.pageUrl||o,source:l.source||"active-context-lock",capturedAt:r,requestId:n==null?void 0:n.requestId,routeSource:"active-context-lock",pageRouteUrl:l.pageUrl||o};const c=typeof location<"u"?location.href:o;if(Vr!=null&&Vr.folderId&&r-Vr.capturedAt<=Bi)return {folderId:Vr.folderId,pageUrl:Vr.pageUrl||c,source:Vr.source||"active-context",capturedAt:r,requestId:n==null?void 0:n.requestId,routeSource:"active-context",pageRouteUrl:Vr.pageUrl||c};const h=bl();if(h!=null&&h.folderId)return {folderId:h.folderId,pageUrl:h.pageUrl,source:h.source,capturedAt:r,requestId:n==null?void 0:n.requestId,routeSource:h.source,pageRouteUrl:h.pageUrl}}return jl(Vr,{method:(n==null?void 0:n.method)||"GET",requestId:n==null?void 0:n.requestId,hasBody:!!(n!=null&&n.body)})}function jl(e,t){const r={folderId:null,pageUrl:typeof location<"u"?location.href:typeof document<"u"?document.URL:"",source:"fallback",capturedAt:Date.now(),requestId:t==null?void 0:t.requestId};if(!e){const a=bl();return {folderId:(a==null?void 0:a.folderId)??null,pageUrl:(a==null?void 0:a.pageUrl)??r.pageUrl,source:(a==null?void 0:a.source)??r.source,requestId:t==null?void 0:t.requestId,routeSource:a==null?void 0:a.source,pageRouteUrl:a==null?void 0:a.pageUrl,capturedAt:Date.now()}}if(typeof e=="string"){const a=e.trim();if(!a)return r;if(/^\d+$/.test(a))return {folderId:a,pageUrl:r.pageUrl,source:"string-id",capturedAt:Date.now(),requestId:t==null?void 0:t.requestId};const i=Uo(a);return {folderId:(i==null?void 0:i.folderId)??null,pageUrl:(i==null?void 0:i.pageUrl)??r.pageUrl,source:"raw-string",capturedAt:Date.now(),requestId:t==null?void 0:t.requestId,routeSource:i!=null&&i.folderId?"string-id":"fallback",pageRouteUrl:i==null?void 0:i.pageUrl}}if(typeof e=="object"){const a=e,i=[a.folderUrl,a.pageUrl,a.url,a.location,a.currentUrl,a.pageUrlBase64].map(f=>f).filter(f=>typeof f=="string"&&f.length>0),s=Date.now(),l=i.map(f=>Uo(f)).find(f=>!!(f!=null&&f.folderId)),c=typeof a.folderId=="string"||typeof a.folderId=="number"?String(a.folderId):null,h=typeof a.pageUrl=="string"&&a.pageUrl.length>0?a.pageUrl:typeof a.url=="string"&&a.url.length>0?a.url:r.pageUrl;if(l!=null&&l.folderId)return {folderId:l.folderId,pageUrl:l.pageUrl,source:typeof a.source=="string"&&a.source.length>0?a.source:"object",capturedAt:typeof a.capturedAt=="number"?a.capturedAt:s,requestId:t==null?void 0:t.requestId,routeSource:typeof a.source=="string"&&a.source.length>0?a.source:"object",pageRouteUrl:h};if(c&&/^\d+$/.test(c))return {folderId:c,pageUrl:h,source:typeof a.source=="string"&&a.source.length>0?a.source:"object",capturedAt:typeof a.capturedAt=="number"?a.capturedAt:s,requestId:t==null?void 0:t.requestId,routeSource:typeof a.source=="string"&&a.source.length>0?a.source:"object",pageRouteUrl:h}}const o=bl();return {folderId:(o==null?void 0:o.folderId)??null,pageUrl:(o==null?void 0:o.pageUrl)??r.pageUrl,source:"fallback",capturedAt:Date.now(),requestId:t==null?void 0:t.requestId,routeSource:o==null?void 0:o.source,pageRouteUrl:o==null?void 0:o.pageUrl}}function bl(){const e=[],t=Ck();t&&e.push(t);const n=Tk();n&&e.push(n);const r=Sk();r&&e.push(r);const o=Mk();o&&e.push(o);const a=e.filter(g=>!!g.folderId).sort((g,_)=>_.confidence-g.confidence)[0];if(a)return {folderId:a.folderId,pageUrl:a.pageUrl,source:a.source,confidence:a.confidence};const i=[],s=typeof location<"u"?location.href:"",l=typeof document<"u"?document.URL:"",c=typeof document<"u"?document.querySelector('link[rel="canonical"]'):null,h=typeof document<"u"?document.querySelector('meta[property="og:url"]'):null;s&&i.push({source:"location",url:s}),l&&l!==s&&i.push({source:"document",url:l}),c!=null&&c.href&&i.push({source:"canonical",url:c.href}),h!=null&&h.content&&i.push({source:"og",url:h.content});for(const g of i){const _=Uo(g.url);if(_!=null&&_.folderId)return {..._,source:g.source,confidence:30}}const f=i[0];if(!f)return null;const m=f.url;return m?{folderId:null,pageUrl:m,source:f.source,confidence:14}:null}function vl(e){try{return /\/i\/bookmarks(?:\/|$)/.test(new URL(e,"https://x.com").pathname)}catch{return  false}}function _r(e){const t=jl(e);Vr=t,t.folderId?dk(t):vl(t.pageUrl)||hk();}function Ac(e,t,n){if(typeof n!="function")return  false;const r=n,o=Mg();if(o)try{return o(r,e,{defineAs:t}),!0}catch(a){return Ie.error(`Failed to define ${t} hook`,a),false}if(e!==globalThis)return Ie.error(`Failed to define ${t} hook`,new Error("exportFunction unavailable for cross-realm target")),false;try{return e[t]=r,!0}catch(a){return Ie.error(`Failed to define ${t} hook`,a),false}}function Dc(e,t,n){if(!e||typeof e!="function")return;let r=e;if(!wl(e,t))return e;for(let o=0;o<10;o++){const a=r[n];if(!a||typeof a!="function")return;if(!wl(a,t))return a;r=a;}}function Ik(e){return !(typeof e!="function"||wl(e,"__twe_is_hook_fetch_v1"))}function Fg(e,t){if(!e||typeof e!="object"&&typeof e!="function")return null;try{const n=e[t];return typeof n=="string"?n:null}catch{return null}}function Ek(e,t){const n=typeof(t==null?void 0:t.method)=="string"&&t.method?t.method:null;if(n)return n;try{if(typeof Request<"u"&&e instanceof Request)return e.method||"GET"}catch{}const r=Fg(e,"method");return r&&r.length>0?r:"GET"}function Ak(e){try{if(typeof e=="string")return e;if(typeof URL<"u"&&e instanceof URL)return e.toString();if(typeof Request<"u"&&e instanceof Request)return e.url||""}catch{}const t=Fg(e,"url");if(t&&t.length>0)return t;try{return String(e??"")}catch{return ""}}function Pc(e){return e?/\/graphql\/|\/i\/api\/|\/api\/1\.1\/|\/api\/2\//.test(e):false}function zr(e){let t=typeof e,n="";if(e===null)return {name:"null",message:"null",summary:"null: null"};if(typeof e>"u")return {name:"undefined",message:"undefined",summary:"undefined: undefined"};if(typeof e=="string")return {name:"Error",message:e,summary:`Error: ${e}`};try{const r=e;typeof r.name=="string"&&r.name.length>0&&(t=r.name),typeof r.message=="string"&&r.message.length>0&&(n=r.message);}catch{}if(!n)try{n=String(e);}catch{n="[inaccessible error object]";}return {name:t,message:n,summary:`${t}: ${n}`}}function Dk(e){const t=zr(e);return /permission denied to access (property|object|then|apply)/i.test(t.summary)}function ah(e){try{if(typeof e!="object"||e===null||e.__twe_mcp_hook_v1!==!0)return;const n=e;n.req&&typeof n.req=="object"&&(n.req=Js(n.req)),e={...e,__twe_msg_revision_v1:uo};const r=An.postMessage;r==null||r(e,"*");return}catch{}try{const n=globalThis.postMessage;n==null||n(e,"*");}catch{}}function Ms(e,t,n,r){if(!e||typeof e!="object"&&typeof e!="function")return  false;const o=e.addEventListener;if(typeof o!="function")return  false;try{return o.call(e,t,n,r),!0}catch{return  false}}class Pk{constructor(){je(this,"extensions",new Map);je(this,"disabledExtensions",new Set);je(this,"debugEnabled",false);je(this,"hookStats",null);je(this,"hookRuntime",null);je(this,"recentResponseSigs",new Map);je(this,"lastStickyBookmarkContext",null);je(this,"runtimeControlPlane");je(this,"interceptorDispatcher",new Mv);je(this,"pageMessageHandler",null);je(this,"instanceId",`${Date.now().toString(36)}-${Math.random().toString(36).slice(2,10)}`);je(this,"__twe_extension_manager_signature_v1",Yv);je(this,"__twe_extension_manager_revision_v1",Xv);je(this,"__twe_extension_manager_started_at_v1",Date.now());je(this,"disposed",false);je(this,"endpointMetricLimit",40);je(this,"signal",new Un(1));this.runtimeControlPlane=new qv({installPageMessageBridge:()=>this.installPageMessageBridge(),installBookmarkContextTracking:()=>this.installBookmarkContextTracking(),installHttpHooks:n=>this.installHttpHooks(n),installFetchHooks:n=>this.installFetchHooks(n),uninstallHooks:()=>this.uninstallHooks(),runHookSelfTest:()=>this.runHookSelfTest(),runFetchHookBootProbePass:()=>this.runFetchHookBootProbePass(),runHookRepairPass:()=>this.runHookRepairPass(),readHookStatsSnapshot:()=>this.readHookStatsSnapshot()}),this.disabledExtensions=new Set(ut.get("disabledExtensions",[])),ut.get("debug")&&(this.debugEnabled=true,Ie.info("Debug mode enabled")),ik();let t=null;try{this.hookStats=Mc(this.instanceId),this.hookRuntime=this.hookStats,this.syncRuntimeStats();}catch(n){t=ak("ExtensionManager.constructor",this.instanceId,n),Ie.error("ExtensionManager constructor bootstrap error",n);}try{const n=sk(this.hookStats,Mc(this.instanceId));(!this.hookStats||this.hookStats.activeInstanceId!==this.instanceId)&&(this.hookStats=n),this.hookStats.activeInstanceId=this.instanceId,this.hookStats.rev=uo,t&&(this.hookStats.repairCount=(this.hookStats.repairCount||0)+1),this.hookRuntime=this.hookStats,this.syncRuntimeStats();}catch{}(!this.hookRuntime||!this.hookStats)&&(this.hookStats=Mc(this.instanceId),this.hookRuntime=this.hookStats,this.syncRuntimeStats()),this.runtimeControlPlane.initialize();}get runtimeModes(){return this.runtimeControlPlane.getRuntimeModes()}get hookDebugConfig(){return this.runtimeControlPlane.getHookDebugConfig()}isHookModeEnabled(t){return this.runtimeControlPlane.isHookModeEnabled(t)}refreshHookDebugConfig(){this.runtimeControlPlane.refreshHookDebugConfig();}emitHookDiag(t,n,r){this.runtimeControlPlane.emitHookDiag(t,n,r);}enableSafeMode(t,n){this.runtimeControlPlane.enableSafeMode(t,n);}applyRuntimeModesFromOptions(){this.runtimeControlPlane.applyRuntimeModesFromOptions();}getRuntimeModesSnapshot(){return this.runtimeControlPlane.getRuntimeModesSnapshot()}getHookStatsSnapshot(){return this.runtimeControlPlane.getHookStatsSnapshot()}dispose(){if(!this.disposed){this.disposed=true;try{this.getExtensions().forEach(t=>{try{t.enabled&&(t.enabled=!1,t.dispose());}catch{}});}catch{}if(this.pageMessageHandler){try{window.removeEventListener("message",this.pageMessageHandler,!1);}catch{}this.pageMessageHandler=null;}this.runtimeControlPlane.dispose();}}runHookSelfTest(){try{if(this.runtimeModes.safeMode||this.runtimeModes.hookMode==="off")return {ok:!0};const t=Ni();if(this.isHookModeEnabled("xhr")){const n=t.XMLHttpRequest;if(!(n!=null&&n.prototype))return {ok:!1,error:"XMLHttpRequest.prototype unavailable"};if(typeof n.prototype.open!="function")return {ok:!1,error:"XMLHttpRequest.prototype.open unavailable"};if(typeof n.prototype.send!="function")return {ok:!1,error:"XMLHttpRequest.prototype.send unavailable"}}return this.isHookModeEnabled("fetch")&&typeof t.fetch!="function"?{ok:!1,error:"fetch unavailable"}:{ok:!0}}catch(t){return {ok:false,error:String(t)}}}syncRuntimeStats(){!this.hookStats||!this.hookRuntime||(this.hookRuntime.messagesTotal=this.hookStats.messagesTotal,this.hookRuntime.messagesLegacyShape=this.hookStats.messagesLegacyShape,this.hookRuntime.messagesMissingContext=this.hookStats.messagesMissingContext,this.hookRuntime.messagesRepairedAtBridge=this.hookStats.messagesRepairedAtBridge,this.hookRuntime.messagesMissingBody=this.hookStats.messagesMissingBody,this.hookRuntime.responsesProcessed=this.hookStats.responsesProcessed,this.hookRuntime.responsesSkippedDuplicate=this.hookStats.responsesSkippedDuplicate,this.hookRuntime.lastMessageAt=this.hookStats.lastMessageAt,this.hookRuntime.activeInstanceId=this.hookStats.activeInstanceId,this.hookRuntime.rev=this.hookStats.rev,this.hookRuntime.endpointStats=this.hookStats.endpointStats);}readHookStatsSnapshot(){return this.hookStats?{xhrMessages:Number(this.hookStats.xhrMessages||0),fetchMessages:Number(this.hookStats.fetchMessages||0),lastUrl:typeof this.hookStats.lastUrl=="string"?this.hookStats.lastUrl:"",lastAt:Number(this.hookStats.lastAt||0)}:null}getEndpointStats(t){if(!this.hookStats)return rh();const n=this.hookStats.endpointStats[t];if(n)return n;if(Object.keys(this.hookStats.endpointStats).length>=this.endpointMetricLimit){const a=Object.keys(this.hookStats.endpointStats)[0];a&&delete this.hookStats.endpointStats[a];}const r=rh();return this.hookStats.endpointStats[t]=r,r}uninstallHooks(){try{const t=An,n=t.XMLHttpRequest,r=n==null?void 0:n.prototype;if(r&&(typeof r[$r]=="function"&&(r.open=r[$r]),typeof r[Hr]=="function"&&(r.send=r[Hr]),delete r.__twe_is_hook_open_v1,delete r.__twe_is_hook_send_v1,delete r.__twe_is_hook_revision_v1),typeof t[Aa]=="function"&&(t.fetch=t[Aa]),typeof t.fetch=="object"&&t.fetch!==null){const o=t.fetch;delete o.__twe_is_hook_fetch_v1,delete o.__twe_is_hook_revision_v1;}}catch{}}applyBookmarkRouteCandidate(t){var l;const n=Date.now(),r=typeof location<"u"?location.href:"",o=vl(r),a=t!=null&&t.pageUrl?vl(t.pageUrl):o;if(!t){if(o&&((l=this.lastStickyBookmarkContext)!=null&&l.folderId)){const c=this.lastStickyBookmarkContext;if(n-c.capturedAt<=Bi){_r({folderId:c.folderId,pageUrl:c.pageUrl||r,source:c.source,capturedAt:n});return}}this.lastStickyBookmarkContext=null,_r({folderId:null,pageUrl:r,source:"refresh",capturedAt:n});return}if(!a){this.lastStickyBookmarkContext=null,_r({folderId:null,pageUrl:t.pageUrl,source:t.source,capturedAt:n});return}if(t.folderId){const c={folderId:t.folderId,pageUrl:t.pageUrl,source:t.source,capturedAt:n};this.lastStickyBookmarkContext=c,_r(c);return}const i=this.lastStickyBookmarkContext,s=i&&!!i.folderId&&t.confidence<=Gv&&n-i.capturedAt<=Bi;if(!t.folderId&&s){_r({folderId:i.folderId,pageUrl:t.pageUrl,source:i.source,capturedAt:n});return}if(!t.folderId&&o&&(i!=null&&i.folderId)&&n-i.capturedAt<=Bi){_r({folderId:i.folderId,pageUrl:t.pageUrl,source:i.source,capturedAt:n});return}this.lastStickyBookmarkContext=null,_r({folderId:null,pageUrl:t.pageUrl,source:t.source,capturedAt:n});}updateBookmarkRouteContext(){try{const t=bl();this.applyBookmarkRouteCandidate(t??null);}catch{}}installBookmarkContextTracking(){if(this.runtimeModes.safeMode||this.runtimeModes.hookMode==="off"||(this.updateBookmarkRouteContext(),!An.history))return;const n=()=>this.updateBookmarkRouteContext(),r=o=>{this.applyBookmarkRouteCandidate(o);};if(!An.__twe_bookmark_context_listeners_v1){An.__twe_bookmark_context_listeners_v1=true;const o=[An,window,globalThis];for(const a of o)Ms(a,"popstate",n),Ms(a,"hashchange",n);}if(!An.__twe_bookmark_context_bookmark_click_v1&&(document!=null&&document.body)){const o=s=>{try{const l=s.target,c=Rk(l);c&&r(c);}catch{}};An.__twe_bookmark_context_bookmark_click_v1=true;const a=[An,window,document,globalThis];let i=false;for(const s of a)i=Ms(s,"click",o,{capture:true})||i;!i&&(document!=null&&document.body)&&Ms(document.body,"click",o,{capture:true}),An.__twe_bookmark_context_bookmark_click_handler_v1=o;}if(An.__twe_bookmark_context_interval_v1||(An.__twe_bookmark_context_interval_v1=setInterval(()=>{try{this.updateBookmarkRouteContext();}catch{}},1200)),!An.__twe_bookmark_context_mutation_v1){const o=document,a=typeof MutationObserver<"u";if(o!=null&&o.body&&a){const i=new MutationObserver(()=>{this.updateBookmarkRouteContext();});i.observe(o.body,{subtree:true,childList:true,attributes:true,attributeFilter:["href","aria-selected","data-state","class"]}),An.__twe_bookmark_context_mutation_v1=i;}}}add(t){try{Ie.debug(`Register new extension: ${t.name}`);const n=new t(this),r=this.extensions.get(n.name);if(r&&r!==n)try{r.enabled&&r.dispose();}catch{}this.extensions.set(n.name,n);}catch(n){Ie.error(`Failed to register extension: ${t.name}`,n);}}start(){for(const t of this.extensions.values())this.disabledExtensions.has(t.name)?this.disable(t.name):this.enable(t.name);}enable(t){try{this.disabledExtensions.delete(t),ut.set("disabledExtensions",[...this.disabledExtensions]);const n=this.extensions.get(t);if(n.enabled)return;n.enabled=!0,n.setup(),Ie.debug(`Enabled extension: ${t}`),this.signal.value++;}catch(n){Ie.error(`Failed to enable extension: ${t}`,n);}}disable(t){try{this.disabledExtensions.add(t),ut.set("disabledExtensions",[...this.disabledExtensions]);const n=this.extensions.get(t);if(!n.enabled)return;n.enabled=!1,n.dispose(),Ie.debug(`Disabled extension: ${t}`),this.signal.value++;}catch(n){Ie.error(`Failed to disable extension: ${t}`,n);}}isDisposed(){return this.disposed}getExtensions(){return [...this.extensions.values()]}installPageMessageBridge(){this.runtimeModes.hookMode!=="off"&&(this.pageMessageHandler||(this.pageMessageHandler=t=>{var n,r,o;try{const a=t.origin||"";if(a&&!/^https:\/\/(x|twitter|mobile\.x)\.com$/.test(a))return;const i=t.data;if(!i||i[Vv]!==!0)return;const s=mk(i),l=s===null||s!==uo,c=pk(i),h=Dg(c),f=i.res;if(!f)return;const m=c&&typeof c=="object"?c:null,g=typeof h.requestId=="string"&&h.requestId.trim().length?h.requestId:typeof(m==null?void 0:m.requestId)=="string"&&((n=m.requestId)!=null&&n.trim().length)?m.requestId:ja(),_=typeof h.method=="string"&&h.method?h.method:typeof(m==null?void 0:m.method)=="string"?m.method:"GET",b=typeof h.url=="string"&&h.url.length?h.url:typeof(m==null?void 0:m.url)=="string"?m.url:"";if(!b)return;const C=typeof h.body=="string"?h.body:typeof(m==null?void 0:m.body)=="string"?m.body:void 0,k=m?m.bookmarkContext:void 0,T=m&&Object.prototype.hasOwnProperty.call(m,"requestContext")?m.requestContext:void 0,M=k!=null||T!=null||h.bookmarkContext!==void 0,P=typeof h.body=="string"||typeof(m==null?void 0:m.body)=="string",F=typeof h.requestId=="string"&&h.requestId.trim().length>0||typeof(m==null?void 0:m.requestId)=="string"&&(((r=m.requestId)==null?void 0:r.trim().length)||0)>0,I=Js({method:_,url:b,body:C,bookmarkContext:h.bookmarkContext??k??T,requestId:g}),O=l||!M||!P||!F,D=sa(I.url)?gk(I.url):null,v=D?this.getEndpointStats(D):null,L=Date.now(),$=typeof f.responseText=="string"?f.responseText:"";if(!this.hookStats)return;O&&this.hookStats.messagesRepairedAtBridge++,P||this.hookStats.messagesMissingBody++,l&&this.hookStats.messagesLegacyShape++,v&&(v.received+=1,v.lastAt=L,v.lastStatus=f.status??0,v.lastUrl=I.url),M||(this.hookStats.messagesLegacyShape++,v&&(v.legacyShape+=1)),!M||I.bookmarkContext===null?(this.hookStats.messagesMissingContext++,v&&(v.missingContext+=1),I.bookmarkContext=wi(I.url,I.body,{method:I.method,url:I.url,body:I.body,requestId:g})):I.bookmarkContext=jl(I.bookmarkContext,{method:I.method,url:I.url,body:I.body,requestId:g,hasBody:!!I.body}),_r(I.bookmarkContext),uk({requestId:g,ts:Date.now(),method:I.method,url:I.url,hasBody:!!I.body,confidenceSource:typeof((o=I.bookmarkContext)==null?void 0:o.source)=="string"?I.bookmarkContext.source:"unknown",context:I.bookmarkContext,normalizedRoute:Ag(I.url).pageUrl});const Me=(I.method||"GET").toUpperCase();if(!sa(I.url)){const J=tk(Me,I.url,f.status??0,$),le=this.recentResponseSigs.get(J);if(le&&L-le.at<Ig){this.hookStats.responsesSkippedDuplicate++,v&&(v.skippedDuplicate+=1),this.syncRuntimeStats();return}this.recentResponseSigs.set(J,{sig:J,at:L}),nk(this.recentResponseSigs);}this.hookStats.responsesProcessed++,v&&(v.processed+=1,v.newUniqueTweets+=yk($)),this.hookStats.messagesTotal++,this.hookStats.lastMessageAt=L,this.hookStats&&(this.hookStats.lastUrl=I.url,this.hookStats.lastAt=Date.now(),(I.method||"").toUpperCase()==="GET"?this.hookStats.xhrMessages++:this.hookStats.fetchMessages++,this.debugEnabled&&this.hookStats.loggedUrls<5&&(this.hookStats.loggedUrls++,Ie.debug("Hook saw request",{method:I.method,url:I.url,status:f.status})),this.syncRuntimeStats());const re={status:f.status,responseText:$};this.runInterceptors(I,re);}catch(a){Ie.debug("Failed to process hook message",a);}},window.addEventListener("message",this.pageMessageHandler,false)));}installHttpHooks(t=false){var a,i,s;if(!this.isHookModeEnabled("xhr"))return;this.refreshHookDebugConfig();const n=this.hookDebugConfig;this.emitHookDiag("xhr.install.begin",{force:t,...n}),n.disableXhrLoadListener&&this.emitHookDiag("xhr.load.listener.disabled",{},{force:true});let r=false,o;try{if(!((a=An.XMLHttpRequest)!=null&&a.prototype)||!((s=(i=An.XMLHttpRequest)==null?void 0:i.prototype)!=null&&s.open))throw new Error("XMLHttpRequest.prototype.open not available");const l=An.XMLHttpRequest.prototype,c=l.open,h=l.send;o=typeof l[$r]=="function"?l[$r]:c,!l[$r]&&typeof c=="function"&&(l[$r]=c),!l[Hr]&&typeof h=="function"&&(l[Hr]=h);const f=Dc(h,"__twe_is_hook_send_v1",Hr),m=typeof f=="function"?f:typeof l[Hr]=="function"?l[Hr]:h;if(typeof m!="function")throw new Error("XMLHttpRequest.prototype.send not available");const g=!n.disableXhrSendWrap&&(t||!Da(h,"__twe_is_hook_send_v1"));if(n.disableXhrSendWrap)typeof l[Hr]=="function"&&(l.send=l[Hr]),r=!0,this.emitHookDiag("xhr.send.wrap.disabled",{},{force:!0});else if(g){const _=this.emitHookDiag.bind(this),b=this.enableSafeMode.bind(this),C=function(T){let M="",P="GET",F="";try{const I=this,O=Rc(I,n);if(P=String(O.method||"GET"),F=O.requestId||ja(),O.requestId=F,O.body=oh(T)??"",M=String(O.url||""),M){const B={method:P,url:M,body:O.body,requestId:F};sa(M)?(O.bookmarkContext=wi(M,O.body,B),_r(O.bookmarkContext)):O.bookmarkContext=null;}Ic(I,n,O);}catch{}try{n.forceCallNotApply?m.call(this,T):m.apply(this,[T]),_("xhr.send.basecall.ok",{method:P,url:M});}catch{try{const I=n.forceCallNotApply?m.apply(this,[T]):m.call(this,T);return _("xhr.send.basecall.recovered",{method:P,url:M},{force:!0}),I}catch(I){_("xhr.send.basecall.error",{method:P,url:M,requestId:F,errName:I instanceof Error?I.name:typeof I,errMsg:I instanceof Error?I.message:String(I)},{force:!0}),Ie.error("XHR send hook base invocation failed; enabling safe mode",{method:P,url:M,err:I});try{b("xhr-send-basecall-failed",I);}catch{}throw I}}};if(ra(C,"__twe_is_hook_send_v1"),!Ac(l,"send",C))throw new Error("Failed to define XMLHttpRequest.send hook safely");ra(l.send,"__twe_is_hook_send_v1"),r=!0;}else r=!0;if(!t&&!n.disableXhrOpenWrap&&Da(c,"__twe_is_hook_open_v1")&&(n.disableXhrSendWrap||Da(h,"__twe_is_hook_send_v1")))r=!0;else {const _=Dc(c,"__twe_is_hook_open_v1",$r),b=typeof _=="function"?_:typeof l[$r]=="function"?l[$r]:c;if(typeof b!="function")throw new Error("XMLHttpRequest.prototype.open base function unavailable");if(n.disableXhrOpenWrap)l.open=b,this.emitHookDiag("xhr.open.wrap.disabled",{},{force:!0}),r=!0;else {const C=this.emitHookDiag.bind(this),k=this.enableSafeMode.bind(this),T=function(...P){let F="",I="",O="";try{F=typeof P[0]=="string"?P[0]:String(P[0]??"");const B=P[1];if(I=typeof B=="string"?B:String(B??""),Pc(I)){const D=this,v=Rc(D,n);O=v.requestId||ja(),v.requestId=O,v.method=F,v.url=I,v.body="",sa(I)?(v.bookmarkContext=wi(I,void 0,{method:F,url:I,requestId:v.requestId}),_r(v.bookmarkContext)):v.bookmarkContext=null,!n.disableXhrLoadListener&&!v.hooked&&(v.hooked=!0,this.addEventListener("load",function(){try{const L=this,$=Rc(L,n),Me=F||"GET",Z=I,re=$.method||Me,J=$.url||Z;if(!Pc(J))return;const le=String(this.responseText??""),he=$.body,pe=$.requestId||ja();$.requestId=pe;const ge=sa(J),z=$.bookmarkContext||(ge?wi(J,he,{method:re,url:J,body:he,requestId:pe}):null);$.bookmarkContext||($.bookmarkContext=z),Ic(L,n,$),ge&&z&&_r(z);const ue=Js({method:re,url:J,body:he||"",bookmarkContext:z??null,requestId:pe});ah({__twe_mcp_hook_v1:!0,req:ue,res:{status:this.status??0,responseText:le}});}catch{}})),Ic(D,n,v);}}catch{}try{const B=n.forceCallNotApply?Ec(b,this,P):b.apply(this,P);return C("xhr.open.basecall.ok",{method:F,url:I}),B}catch{try{const B=n.forceCallNotApply?b.apply(this,P):Ec(b,this,P);return C("xhr.open.basecall.recovered",{method:F,url:I},{force:!0}),B}catch(B){C("xhr.open.basecall.error",{method:F,url:I,requestId:O,errName:B instanceof Error?B.name:typeof B,errMsg:B instanceof Error?B.message:String(B)},{force:!0}),Ie.error("XHR open hook base invocation failed; enabling safe mode",{method:F,url:I,err:B});try{k("xhr-open-basecall-failed",B);}catch{}throw B}}};if(ra(T,"__twe_is_hook_open_v1"),!Ac(l,"open",T))throw new Error("Failed to define XMLHttpRequest.open hook safely");r=!0,ra(l.open,"__twe_is_hook_open_v1"),ra(l.send,"__twe_is_hook_send_v1");}l[$r]=b,l[Hr]=m;}}catch(l){Ie.error("Failed to hook into XMLHttpRequest",l),this.enableSafeMode("xhr-hook-install-failed",l);}this.debugEnabled&&Ie.info(`Hooked into XMLHttpRequest (installed=${r})`),setTimeout(()=>{var l,c;try{const h=Jv();((c=(l=An.XMLHttpRequest)==null?void 0:l.prototype)==null?void 0:c.open)!==(typeof o=="function"?o:void 0)?this.debugEnabled&&Ie.debug("XHR hook active",{unsafeWindow:h.hasUnsafeWindow,wrappedJSObject:h.hasWrappedJSObject,exportFunction:h.hasExportFunction}):Ie.error(`XHR hook not active (unsafeWindow=${h.hasUnsafeWindow}, wrappedJSObject=${h.hasWrappedJSObject}, exportFunction=${h.hasExportFunction}). Bookmark capture will not work.`);}catch(h){Ie.debug("XHR hook diagnostics failed",h);}},1e3);}installFetchHooks(t=false){if(!this.isHookModeEnabled("fetch"))return;this.refreshHookDebugConfig();const n=this.hookDebugConfig;this.emitHookDiag("fetch.install.begin",{force:t,...n});const r=Ni(),o=r.fetch;if(typeof o!="function"){Ie.warn("Fetch API not found, skipping fetch hooks");return}const a=r,i=r.fetch;if(!t&&Da(i,"__twe_is_hook_fetch_v1")){Ie.debug("Fetch hook already installed");return}const s=a[Aa],l=Dc(i,"__twe_is_hook_fetch_v1",Aa),c=[s,l,o].find(Ik)??null;if(!c){Ie.error("Fetch API base function unavailable or unsafe; enabling safe mode"),this.enableSafeMode("fetch-hook-base-unavailable");return}const h=c;if(n.disableFetchWrap){r.fetch=h,this.emitHookDiag("fetch.wrap.disabled",{},{force:true});return}a[Aa]=h;const f=this.emitHookDiag.bind(this),m=this.enableSafeMode.bind(this);let g=false,_=r;const b=(M,P,F=2)=>{try{return F<=1?h(M):h(M,P)}catch(I){return Promise.reject(I)}},C=(M,P,F,I,O=2)=>{const B=O<=1?[F]:[F,I];let D=null;for(const v of P)if(v){try{const L=Ec(M,v,B);return _=v,L}catch(L){D=L;}if(!n.forceCallNotApply)try{const L=Reflect.apply(M,v,B);return _=v,L}catch(L){D=L;}}try{return O<=1?M(F):M(F,I)}catch(v){D=v;}throw D instanceof Error?D:new Error(`fetch invocation failed (${zr(D).summary})`)},k=function(M,P){const F=arguments.length<=1?1:2;let I="GET",O="",B,D="",v;try{I=Ek(M,P);}catch{I=(P==null?void 0:P.method)??"GET";}try{O=Ak(M);}catch{O="";}try{B=oh(P==null?void 0:P.body);}catch{B=void 0;}try{D=ja();}catch{D="";}f("fetch.wrapper.enter",{method:I,url:O,requestId:D});try{sa(O)?(v=wi(O,B,{method:I,url:O,body:B,requestId:D}),_r(v)):v=void 0;}catch(Me){Ie.debug("fetch request context capture failed",{method:I,url:O,err:Me});}if(!Pc(O))return b(M,P,F);let $;try{const Me=a[Aa]??h;if(typeof Me!="function"||wl(Me,"__twe_is_hook_fetch_v1"))throw new Error("fetch base function unavailable");const Z=[this,_,r];typeof window<"u"&&Z.push(window),Z.push(globalThis);const re=[],J=new Set;for(const le of Z)!le||J.has(le)||(J.add(le),re.push(le));$=C(Me,re,M,P,F);}catch(Me){const Z=zr(Me);if(f("fetch.basecall.error",{method:I,url:O,requestId:D,errName:Z.name,errMsg:Z.message}),!g){g=true,Ie.error("Fetch hook base invocation failed; enabling safe mode",{method:I,url:O,err:Z.summary});try{m("fetch-hook-invocation-failed",Z.summary);}catch{}}return b(M,P,F).catch(re=>{const J=zr(re);throw f("fetch.fallback.error",{method:I,url:O,requestId:D,errName:J.name,errMsg:J.message},{force:true}),re??Z.summary})}try{$.then(Me=>{try{f("fetch.basecall.ok",{method:I,url:O});const Z=Me.headers.get("content-type")??"";if(!(!Z||Z.includes("json")||Z.startsWith("text/")))return;Me.clone().text().then(J=>{if(J)try{const le=Js({method:I,url:O,body:B||"",bookmarkContext:v??null,requestId:D});ah({__twe_mcp_hook_v1:!0,req:le,res:{status:Me.status,responseText:J}});}catch{}}).catch(J=>{const le=zr(J);Ie.debug("fetch clone.text() failed",{method:I,url:O,err:le.summary});});}catch(Z){const re=zr(Z);Ie.debug("fetch response hook observer callback failed",{method:I,url:O,err:re.summary});}},Me=>{const Z=zr(Me);if(f("fetch.basecall.error",{method:I,url:O,requestId:D,errName:Z.name,errMsg:Z.message}),!g){g=!0,Ie.error("Fetch hook base invocation failed; enabling safe mode",{method:I,url:O,err:Z.summary});try{m("fetch-hook-invocation-failed",Z.summary);}catch{}}}).catch(Me=>{const Z=zr(Me);Ie.debug("fetch response hook observer promise failed",{method:I,url:O,err:Z.summary});});}catch(Me){const Z=zr(Me);Ie.debug("fetch response hook observer setup failed",{method:I,url:O,err:Z.summary});}return $};ra(k,"__twe_is_hook_fetch_v1");const T=Ac(a,"fetch",k);if(!T){this.enableSafeMode("fetch-hook-define-failed");return}ra(a.fetch,"__twe_is_hook_fetch_v1"),this.emitHookDiag("fetch.install.ok",{hasHookMarker:Da(a.fetch,"__twe_is_hook_fetch_v1")},{force:true}),T&&this.debugEnabled&&Ie.info("Hooked into fetch"),T&&this.startFetchHookBootProbe(1200);}runFetchHookBootProbePass(){if(this.runtimeModes.safeMode||!this.isHookModeEnabled("fetch"))return;const t=Ni(),n=t.fetch;if(typeof n!="function"){this.enableSafeMode("fetch-hook-probe-missing-fetch");return}this.emitHookDiag("fetch.bootprobe.begin",{hasHookMarker:Da(n,"__twe_is_hook_fetch_v1")},{force:true}),(async()=>{const o=[t];typeof window<"u"&&o.push(window),o.push(globalThis);const a=typeof location<"u"&&location.origin?`${location.origin}/favicon.ico?__twe_fetch_probe=1`:"https://x.com/favicon.ico?__twe_fetch_probe=1";let i=null;try{await(await n(a)).text().catch(()=>""),this.debugEnabled&&Ie.debug("Fetch hook boot probe passed"),this.emitHookDiag("fetch.bootprobe.ok",{});return}catch(l){i=l;}for(const l of o)try{await(this.hookDebugConfig.forceCallNotApply?await n.call(l,a):await Reflect.apply(n,l,[a])).text().catch(()=>""),this.debugEnabled&&Ie.debug("Fetch hook boot probe passed"),this.emitHookDiag("fetch.bootprobe.ok",{});return}catch(c){i=c;}const s=zr(i);if(this.emitHookDiag("fetch.bootprobe.error",{errName:s.name,errMsg:s.message},{force:true}),Dk(i)){Ie.warn("Fetch boot probe hit cross-realm permission error; keeping fetch hook active",s.summary);return}this.enableSafeMode("fetch-hook-probe-failed",i);})();}startFetchHookBootProbe(t=1200){this.runtimeControlPlane.startFetchHookBootProbe(t);}runHookRepairPass(){return this.hookStats&&(this.hookStats.repairCount+=1,this.syncRuntimeStats()),this.isHookModeEnabled("xhr")&&this.installHttpHooks(true),this.isHookModeEnabled("fetch")&&this.installFetchHooks(true),this.runHookSelfTest()}runInterceptors(t,n){this.interceptorDispatcher.dispatch(this.getExtensions(),t,n);}}var xt=(e=>(e.TWEET="tweet",e.USER="user",e.CUSTOM="custom",e.NONE="none",e))(xt||{});class bn{constructor(t){je(this,"name","");je(this,"enabled",true);je(this,"type","none");je(this,"manager");this.manager=t;}setup(){}dispose(){}intercept(){return null}render(){return null}}let bi=null;function kl(){return bi&&!bi.isDisposed()||(bi=new Pk),bi}const rr=new Proxy({},{get(e,t,n){const r=kl(),o=Reflect.get(r,t,n);return typeof o=="function"?o.bind(r):o},set(e,t,n,r){const o=kl();return Reflect.set(o,t,n,r)}}),Ok="cupcake",Fk="dracula";function Lk(e){const t=e.match(/rgba?\(([^)]+)\)/i),n=t==null?void 0:t[1];if(!n)return null;const r=n.split(",").slice(0,3).map(s=>Number.parseFloat(s.trim()));if(r.length!==3||r.some(s=>!Number.isFinite(s)))return null;const[o,a,i]=r;return o===void 0||a===void 0||i===void 0?null:[o,a,i]}function Nk([e,t,n]){const[r,o,a]=[e,t,n].map(i=>{const s=Math.max(0,Math.min(255,i))/255;return s<=.03928?s/12.92:Math.pow((s+.055)/1.055,2.4)});return r===void 0||o===void 0||a===void 0?0:.2126*r+.7152*o+.0722*a}function Bk(){const e=[document.documentElement,document.body].filter(Boolean);for(const t of e){const n=[t.getAttribute("data-theme"),t.getAttribute("data-color-mode"),t.getAttribute("color-mode"),t.className,t.getAttribute("style")].join(" ").toLowerCase();if(/\b(dark|dim|night|lights-out|black)\b/.test(n))return "dark";if(/\b(light|default|white)\b/.test(n))return "light"}return null}function Uk(){const e=getComputedStyle(document.documentElement).colorScheme.toLowerCase();if(e.includes("dark"))return "dark";if(e.includes("light"))return "light";const t=document.querySelector("main"),n=[document.body,t,document.documentElement].filter(r=>!!r);for(const r of n){const o=Lk(getComputedStyle(r).backgroundColor);if(o)return Nk(o)<.35?"dark":"light"}return null}function ih(){var e;return (e=globalThis.matchMedia)!=null&&e.call(globalThis,"(prefers-color-scheme: dark)").matches?"dark":"light"}function $k(){return typeof document>"u"?ih():Bk()??Uk()??ih()}function sh(e){return e&&e!=="system"?e:$k()==="dark"?Fk:Ok}function Hk(e){const t=on(sh(e));return Je(()=>{var a,i;const n=()=>{t.value=sh(e);};if(n(),e&&e!=="system")return;const r=(a=globalThis.matchMedia)==null?void 0:a.call(globalThis,"(prefers-color-scheme: dark)");(i=r==null?void 0:r.addEventListener)==null||i.call(r,"change",n);const o=typeof MutationObserver<"u"?new MutationObserver(n):null;return o&&typeof document<"u"&&(o.observe(document.documentElement,{attributes:true,attributeFilter:["class","style","data-theme","data-color-mode","color-mode"]}),document.body&&o.observe(document.body,{attributes:true,attributeFilter:["class","style","data-theme","data-color-mode","color-mode"]})),()=>{var s;(s=r==null?void 0:r.removeEventListener)==null||s.call(r,"change",n),o==null||o.disconnect();}},[e,t]),t}function jk(e){const t=on(rr.getExtensions()),n=on(ut.get("theme")),r=Hk(n.value),o=on(ut.get("showControlPanel")),a=on(null),i=on(null),s=on(null),l=()=>{o.value=!o.value,ut.set("showControlPanel",o.value);};return Je(()=>{t.value=rr.getExtensions(),n.value=ut.get("theme"),o.value=ut.get("showControlPanel"),rr.signal.subscribe(()=>{t.value=rr.getExtensions();}),ut.signal.subscribe(()=>{n.value=ut.get("theme");try{rr.applyRuntimeModesFromOptions(),i.value=rr.getRuntimeModesSnapshot();}catch{i.value=null;}});try{rr.applyRuntimeModesFromOptions();}catch{}typeof _l=="function"&&_l(e,l);let c=null;const h=()=>{try{a.value=rr.getHookStatsSnapshot();}catch{a.value=null;}try{i.value=rr.getRuntimeModesSnapshot();}catch{i.value=null;}try{s.value=globalThis.__twe_raw_capture_stats_v1;}catch{s.value=null;}},f=()=>{const m=typeof document<"u"&&document.hidden?8e3:2e3;c=globalThis.setTimeout(()=>{h(),f();},m);};return h(),f(),Ie.debug("Workspace shell state effect executed"),()=>{c!==null&&globalThis.clearTimeout(c);}},[]),{extensions:t,currentTheme:n,resolvedTheme:r,showControlPanel:o,hookStats:a,runtimeModes:i,rawCaptureStats:s,toggleControlPanel:l}}function qk(e){return d("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 100 100","aria-hidden":"true",...e,children:d("path",{fill:"currentColor",d:"m82.7 88.4c1.8-2.2 4.1-5.4 4.1-9.9s-1.9-7.3-4.5-9.8c1.8-3.2 6.6-5.4 9.8-5.4 0.8 0 2.2-1 2.2-2.8 0-3.4-3.3-7.3-7.9-7.3-1.1 0-1.9-0.1-1.9-3.9 0-0.6 0.1-1.4 0.1-2.4 6 0 14.3-3.1 14.3-11.4 0-4.7-4.6-13.6-13.8-18.7l-0.1-0.1v-0.1c0.3-5.9-1.6-8.9-4-8.9-2.5 0-4.4 3-5 4.6-1.4-3-3.9-6.5-7.1-6.5-2.2 0-4.4 2.1-4.4 6.6 0 2.8 0.7 5.8 1.7 8.1-2.5 3.4-4.6 7.9-4.6 15.1 0 8.7-9.9 8.8-16.6 20.5-3.9 6.4-4 12.5-3.8 18.6-1.4-1.8-1.8-7.3-0.7-12.2 2.2-8.7 9.4-12.8 12-22.9 0.7-2.5 1-5.1 1-7.9 0-12.5-9.5-28.2-27.2-28.2-13.6 0-24.8 11.3-24.8 24.5 0 5.5 1.7 10.9 5 13.7 1 1.1 2.3 1.4 2.5 0 0.5-2.3 3-5.7 7.3-5.7 4 0 7.6 2.3 7.6 6.6 0 4.7-4.1 8.2-6.5 16.5-0.7 2.4-1.1 5-1.1 7.9 0 16.1 11.7 29.4 32.3 29.4h33c4.3 0 6.6-0.6 6.6-2.8 0-2.4-2.1-4.3-5.5-5.2zm1-59.5c1.2 0 2.2 1 2.2 2.2s-0.9 2.2-2.2 2.5c-1.2 0-2.3-1-2.4-2.4 0-1.2 1.1-2.3 2.4-2.3z"})})}function Vk({currentTheme:e,onToggle:t}){return d("div",{onClick:t,"data-theme":e,class:"group w-12 h-12 fixed top-[60%] left-[-20px] cursor-pointer bg-transparent text-base-content",children:d("div",{class:"w-full h-full origin origin-[bottom_center] transition-all duration-200 group-hover:translate-x-[5px] group-hover:rotate-[20deg] opacity-50 group-hover:opacity-90",children:d(qk,{class:"h-full w-full"})})})}function zk(e,t){for(var n in t)e[n]=t[n];return e}function lh(e,t){for(var n in e)if(n!=="__source"&&!(n in t))return  true;for(var r in t)if(r!=="__source"&&e[r]!==t[r])return  true;return  false}function ch(e,t){this.props=e,this.context=t;}(ch.prototype=new Fr).isPureReactComponent=true,ch.prototype.shouldComponentUpdate=function(e,t){return lh(this.props,e)||lh(this.state,t)};var uh=$t.__b;$t.__b=function(e){e.type&&e.type.__f&&e.ref&&(e.props.ref=e.ref,e.ref=null),uh&&uh(e);};var Kk=$t.__e;$t.__e=function(e,t,n,r){if(e.then){for(var o,a=t;a=a.__;)if((o=a.__c)&&o.__c)return t.__e==null&&(t.__e=n.__e,t.__k=n.__k),o.__c(e,t)}Kk(e,t,n,r);};var dh=$t.unmount;function Lg(e,t,n){return e&&(e.__c&&e.__c.__H&&(e.__c.__H.__.forEach(function(r){typeof r.__c=="function"&&r.__c();}),e.__c.__H=null),(e=zk({},e)).__c!=null&&(e.__c.__P===n&&(e.__c.__P=t),e.__c=null),e.__k=e.__k&&e.__k.map(function(r){return Lg(r,t,n)})),e}function Ng(e,t,n){return e&&n&&(e.__v=null,e.__k=e.__k&&e.__k.map(function(r){return Ng(r,t,n)}),e.__c&&e.__c.__P===t&&(e.__e&&n.appendChild(e.__e),e.__c.__e=true,e.__c.__P=n)),e}function Oc(){this.__u=0,this.o=null,this.__b=null;}function Bg(e){var t=e.__.__c;return t&&t.__a&&t.__a(e)}function Rs(){this.i=null,this.l=null;}$t.unmount=function(e){var t=e.__c;t&&t.__R&&t.__R(),t&&32&e.__u&&(e.type=null),dh&&dh(e);},(Oc.prototype=new Fr).__c=function(e,t){var n=t.__c,r=this;r.o==null&&(r.o=[]),r.o.push(n);var o=Bg(r.__v),a=false,i=function(){a||(a=true,n.__R=null,o?o(s):s());};n.__R=i;var s=function(){if(!--r.__u){if(r.state.__a){var l=r.state.__a;r.__v.__k[0]=Ng(l,l.__c.__P,l.__c.__O);}var c;for(r.setState({__a:r.__b=null});c=r.o.pop();)c.forceUpdate();}};r.__u++||32&t.__u||r.setState({__a:r.__b=r.__v.__k[0]}),e.then(i,i);},Oc.prototype.componentWillUnmount=function(){this.o=[];},Oc.prototype.render=function(e,t){if(this.__b){if(this.__v.__k){var n=document.createElement("div"),r=this.__v.__k[0].__c;this.__v.__k[0]=Lg(this.__b,n,r.__O=r.__P);}this.__b=null;}var o=t.__a&&Fo(Jn,null,e.fallback);return o&&(o.__u&=-33),[Fo(Jn,null,t.__a?null:e.children),o]};var fh=function(e,t,n){if(++n[1]===n[0]&&e.l.delete(t),e.props.revealOrder&&(e.props.revealOrder[0]!=="t"||!e.l.size))for(n=e.i;n;){for(;n.length>3;)n.pop()();if(n[1]<n[0])break;e.i=n=n[2];}};function Wk(e){return this.getChildContext=function(){return e.context},e.children}function Gk(e){var t=this,n=e.h;t.componentWillUnmount=function(){Mu(null,t.v),t.v=null,t.h=null;},t.h&&t.h!==n&&t.componentWillUnmount(),t.v||(t.h=n,t.v={nodeType:1,parentNode:n,childNodes:[],contains:function(){return  true},appendChild:function(r){this.childNodes.push(r),t.h.appendChild(r);},insertBefore:function(r,o){this.childNodes.push(r),t.h.insertBefore(r,o);},removeChild:function(r){this.childNodes.splice(this.childNodes.indexOf(r)>>>1,1),t.h.removeChild(r);}}),Mu(Fo(Wk,{context:t.context},e.__v),t.v);}function Yk(e,t){var n=Fo(Gk,{__v:e,h:t});return n.containerInfo=t,n}(Rs.prototype=new Fr).__a=function(e){var t=this,n=Bg(t.__v),r=t.l.get(e);return r[0]++,function(o){var a=function(){t.props.revealOrder?(r.push(o),fh(t,e,r)):o();};n?n(a):a();}},Rs.prototype.render=function(e){this.i=null,this.l=new Map;var t=Yi(e.children);e.revealOrder&&e.revealOrder[0]==="b"&&t.reverse();for(var n=t.length;n--;)this.l.set(t[n],this.i=[1,0,this.i]);return e.children},Rs.prototype.componentDidUpdate=Rs.prototype.componentDidMount=function(){var e=this;this.l.forEach(function(t,n){fh(e,n,t);});};var Xk=typeof Symbol<"u"&&Symbol.for&&Symbol.for("react.element")||60103,Zk=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image(!S)|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,Qk=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,Jk=/[A-Z0-9]/g,ex=typeof document<"u",tx=function(e){return (typeof Symbol<"u"&&typeof Symbol()=="symbol"?/fil|che|rad/:/fil|che|ra/).test(e)};Fr.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(e){Object.defineProperty(Fr.prototype,e,{configurable:true,get:function(){return this["UNSAFE_"+e]},set:function(t){Object.defineProperty(this,e,{configurable:true,writable:true,value:t});}});});var hh=$t.event;function nx(){}function rx(){return this.cancelBubble}function ox(){return this.defaultPrevented}$t.event=function(e){return hh&&(e=hh(e)),e.persist=nx,e.isPropagationStopped=rx,e.isDefaultPrevented=ox,e.nativeEvent=e};var ax={enumerable:false,configurable:true,get:function(){return this.class}},ph=$t.vnode;$t.vnode=function(e){typeof e.type=="string"&&(function(t){var n=t.props,r=t.type,o={},a=r.indexOf("-")===-1;for(var i in n){var s=n[i];if(!(i==="value"&&"defaultValue"in n&&s==null||ex&&i==="children"&&r==="noscript"||i==="class"||i==="className")){var l=i.toLowerCase();i==="defaultValue"&&"value"in n&&n.value==null?i="value":i==="download"&&s===true?s="":l==="translate"&&s==="no"?s=false:l[0]==="o"&&l[1]==="n"?l==="ondoubleclick"?i="ondblclick":l!=="onchange"||r!=="input"&&r!=="textarea"||tx(n.type)?l==="onfocus"?i="onfocusin":l==="onblur"?i="onfocusout":Qk.test(i)&&(i=l):l=i="oninput":a&&Zk.test(i)?i=i.replace(Jk,"-$&").toLowerCase():s===null&&(s=void 0),l==="oninput"&&o[i=l]&&(i="oninputCapture"),o[i]=s;}}r=="select"&&o.multiple&&Array.isArray(o.value)&&(o.value=Yi(n.children).forEach(function(c){c.props.selected=o.value.indexOf(c.props.value)!=-1;})),r=="select"&&o.defaultValue!=null&&(o.value=Yi(n.children).forEach(function(c){c.props.selected=o.multiple?o.defaultValue.indexOf(c.props.value)!=-1:o.defaultValue==c.props.value;})),n.class&&!n.className?(o.class=n.class,Object.defineProperty(o,"className",ax)):(n.className&&!n.class||n.class&&n.className)&&(o.class=o.className=n.className),t.props=o;})(e),e.$$typeof=Xk,ph&&ph(e);};var mh=$t.__r;$t.__r=function(e){mh&&mh(e),e.__c;};var gh=$t.diffed;$t.diffed=function(e){gh&&gh(e);var t=e.props,n=e.__e;n!=null&&e.type==="textarea"&&"value"in t&&t.value!==n.value&&(n.value=t.value==null?"":t.value);};function _a(e,t,n){const r=JSON.parse(e.responseText),o=t(r),a=ix(o),i=new Set,s=[];for(const l of a){const c=n(l);!c||i.has(c.rest_id)||(i.add(c.rest_id),s.push(c));}return s}function ix(e){var n,r,o,a;const t=[];for(const i of e){if(i.type==="TimelineAddEntries"){const l=i;for(const c of l.entries??[])ua(c)&&t.push(c);continue}if(i.type==="TimelinePinEntry"){const c=i.entry;c&&ua(c)&&t.push(c);continue}if(i.type==="TimelineAddToModule"){const l=i;for(const c of l.moduleItems??[]){const h=(n=c==null?void 0:c.item)==null?void 0:n.itemContent;h&&t.push({entryId:c.entryId??"",sortIndex:"0",content:{entryType:"TimelineTimelineItem",__typename:"TimelineTimelineItem",itemContent:h,clientEventInfo:((r=c==null?void 0:c.item)==null?void 0:r.clientEventInfo)??null}});}continue}const s=i;if(Array.isArray(s==null?void 0:s.entries)){for(const l of s.entries)l&&ua(l)&&t.push(l);continue}if(s!=null&&s.entry&&ua(s.entry)){t.push(s.entry);continue}if(Array.isArray(s==null?void 0:s.moduleItems)){for(const l of s.moduleItems??[]){const c=(o=l==null?void 0:l.item)==null?void 0:o.itemContent;c&&t.push({entryId:l.entryId??"",sortIndex:"0",content:{entryType:"TimelineTimelineItem",__typename:"TimelineTimelineItem",itemContent:c,clientEventInfo:((a=l==null?void 0:l.item)==null?void 0:a.clientEventInfo)??null}});}continue}}return t}function jn(e){const t=e.tweet_results.result;return t?Rd(t):(Ie.warn("TimelineTweet is empty. This could happen when the tweet's visibility is limited by Twitter.",e),null)}function Yr(e){const t=e.user_results.result;return !t||t.__typename!=="User"?(Ie.warn("TimelineUser is empty. This could happen when the user's account is suspended or deleted.",e),null):t}function ua(e){return e.content.entryType==="TimelineTimelineItem"}function Td(e){return ua(e)&&e.entryId.startsWith("tweet-")&&e.content.itemContent.__typename==="TimelineTweet"}function Md(e){return ua(e)&&e.entryId.startsWith("user-")&&e.content.itemContent.__typename==="TimelineUser"}function Vo(e){return e.content.entryType==="TimelineTimelineModule"}function sx(e){return Vo(e)&&e.entryId.startsWith("conversationthread-")&&Array.isArray(e.content.items)}function lx(e){return Vo(e)&&e.entryId.startsWith("profile-conversation-")&&Array.isArray(e.content.items)}function cx(e){return Vo(e)&&e.entryId.startsWith("profile-grid-")&&Array.isArray(e.content.items)}function ux(e){return Vo(e)&&e.entryId.startsWith("search-grid-")&&Array.isArray(e.content.items)}function dx(e){return Vo(e)&&e.entryId.startsWith("list-search-")&&Array.isArray(e.content.items)}function fx(e){return Vo(e)&&e.entryId.startsWith("communities-grid-")&&Array.isArray(e.content.items)}function Rd(e){var t,n;try{if(e.__typename==="Tweet")return yh(e);if(e.__typename==="TweetWithVisibilityResults")return yh(e.tweet);if(e.__typename==="TweetTombstone")return Ie.warn(`TweetTombstone received (Reason: ${(n=(t=e.tombstone)==null?void 0:t.text)==null?void 0:n.text})`,e),null;if(e.__typename==="TweetUnavailable")return Ie.warn("TweetUnavailable received (Reason: unknown)",e),null;Ie.debug(e),Ie.errorWithBanner("Unknown tweet type received");}catch(r){Ie.debug(e),Ie.errorWithBanner("Failed to extract tweet",r);}return null}function ii(e){var t;return (t=e.legacy.retweeted_status_result)!=null&&t.result?Rd(e.legacy.retweeted_status_result.result):null}function Id(e){var t;return (t=e.quoted_status_result)!=null&&t.result?Rd(e.quoted_status_result.result):null}function ql(e){var n,r;const t=(r=(n=e.article)==null?void 0:n.article_results)==null?void 0:r.result;return t&&typeof t=="object"?t:null}function hx(e){var r;const t=(r=e==null?void 0:e.content_state)==null?void 0:r.blocks;if(!Array.isArray(t))return [];const n=[];for(const o of t){const a=typeof(o==null?void 0:o.text)=="string"?o.text.trim():"";a&&n.push(a);}return n}function Ug(e){const t=String(e||"").trim();return t?t.replace(/\?(?:format|name)=[^&]+(?:&name=[^&]+)?$/i,""):""}function Fu(e){const t=String(e.url||"").trim();if(!t)return null;const n=ca(e.tweet),r=String(e.mediaId||`${e.idPrefix||"synthetic"}_${e.tweet.rest_id}`).trim(),o=String(e.mediaKey||`${e.idPrefix||"synthetic"}_${r}`).trim(),a=Number(e.width||0)||0,i=Number(e.height||0)||0;return {display_url:t,expanded_url:n,id_str:r||e.tweet.rest_id,indices:[0,0],media_url_https:t,type:"photo",url:t,sizes:{large:{h:i,w:a,resize:"fit"},medium:{h:i,w:a,resize:"fit"},small:{h:i,w:a,resize:"fit"},thumb:{h:i,w:a,resize:"fit"}},original_info:{height:i,width:a},media_results:{result:{media_key:o||`synthetic_${e.tweet.rest_id}`}},ext_alt_text:String(e.altText||"").trim()||void 0,media_key:o||`synthetic_${e.tweet.rest_id}`}}function $g(e,t){var a,i,s,l,c,h;if(!t)return [];const n=new Map,r=f=>{if(!f)return;const m=Ug(f.media_url_https);!m||n.has(m)||n.set(m,f);};for(const f of t.media_entities??[])r(Fu({tweet:e,url:((a=f==null?void 0:f.media_info)==null?void 0:a.original_img_url)||"",mediaId:(f==null?void 0:f.media_id)||(f==null?void 0:f.id)||(t==null?void 0:t.rest_id)||e.rest_id,mediaKey:(f==null?void 0:f.media_key)||null,width:((i=f==null?void 0:f.media_info)==null?void 0:i.original_img_width)||0,height:((s=f==null?void 0:f.media_info)==null?void 0:s.original_img_height)||0,altText:(t==null?void 0:t.title)||(t==null?void 0:t.preview_text)||null,idPrefix:"article"}));const o=t.cover_media;return r(Fu({tweet:e,url:((l=o==null?void 0:o.media_info)==null?void 0:l.original_img_url)||"",mediaId:(o==null?void 0:o.media_id)||(t==null?void 0:t.rest_id)||e.rest_id,mediaKey:(o==null?void 0:o.media_key)||null,width:((c=o==null?void 0:o.media_info)==null?void 0:c.original_img_width)||0,height:((h=o==null?void 0:o.media_info)==null?void 0:h.original_img_height)||0,altText:(t==null?void 0:t.title)||(t==null?void 0:t.preview_text)||null,idPrefix:"article"})),Array.from(n.values())}function px(e){const t=[e.card,e.unified_card],n=new Map,r=a=>{if(!a)return;if(Array.isArray(a)){for(const s of a)r(s);return}if(typeof a!="object")return;const i=a;for(const[s,l]of Object.entries(i)){if(s==="url"&&typeof l=="string"&&/https:\/\/pbs\.twimg\.com\/(?:card_img|media)\//.test(l)){const c=Ug(l);c&&!n.has(c)&&n.set(c,l);continue}r(l);}};for(const a of t)r(a);let o=0;return Array.from(n.values()).slice(0,12).map(a=>Fu({tweet:e,url:a,mediaId:`${e.rest_id}_${o++}`,mediaKey:`card_${e.rest_id}_${o}`,altText:zl(e),idPrefix:"card"})).filter(a=>!!a)}function ha(e){var r,o,a;const t=(r=e.legacy)==null?void 0:r.created_at;if(typeof t=="string"&&t.trim()){const i=+Ja(t);if(Number.isFinite(i)&&i>0)return i}const n=Number(((a=(o=ql(e))==null?void 0:o.metadata)==null?void 0:a.first_published_at_secs)||0);return Number.isFinite(n)&&n>0?n*1e3:Date.now()}function Vl(e){return e.core.user_results.result.core.screen_name}function fo(e){var a,i,s,l;const t=ii(e)??e;if((a=t.legacy.extended_entities)!=null&&a.media)return t.legacy.extended_entities.media;const n=((s=(i=t.legacy)==null?void 0:i.entities)==null?void 0:s.media)??[];if(n.length)return n;const r=$g(t,ql(t));if(r.length)return r;if((Number(((l=t.twe_private_fields)==null?void 0:l.media_count)||0)||0)>0){const c=px(t);if(c.length)return c}return []}function mx(e){return ii(e)?false:fo(e).length>0}function gx(e){const t=fo(e),n=[];for(const r of t){const o=yx(r);for(const a of o)n.some(i=>i.user_id===a.user_id)||n.push(a);}return n}function zl(e){var i,s;const t=(i=e.note_tweet)==null?void 0:i.note_tweet_results.result.text;if(t&&t.trim())return t;const n=(s=e.legacy)==null?void 0:s.full_text;if(n&&n.trim())return n;const r=ql(e),o=[r==null?void 0:r.title,r==null?void 0:r.preview_text,...hx(r)].map(l=>String(l||"").trim()).filter(Boolean);return o.filter((l,c)=>o.indexOf(l)===c).join(`

`)}function yh(e){var t,n;if(!e.legacy){const r=ql(e);if(!r||!((n=(t=e.core)==null?void 0:t.user_results)!=null&&n.result))return Ie.warn("Empty tweet received",e),null;const o=ha(e),a=zl(e),i=$g(e,r),s=e.core.user_results.result.rest_id||String(e.core.user_results.result.id||"").split(":").pop()||"";e.legacy={bookmark_count:0,bookmarked:false,created_at:new Date(o).toUTCString(),conversation_id_str:e.rest_id,display_text_range:[0,a.length],entities:{media:i.length?i:void 0,user_mentions:[],urls:[],hashtags:[],symbols:[],timestamps:[]},extended_entities:i.length?{media:i}:void 0,favorite_count:0,favorited:false,full_text:a,is_quote_status:false,lang:"und",possibly_sensitive:false,possibly_sensitive_editable:false,quote_count:0,reply_count:0,retweet_count:0,retweeted:false,user_id_str:s,id_str:e.rest_id};}return e}function _h(e,t){const n=t.media_key;return fo(e).findIndex(r=>r.media_key===n)}function pa(e){var t;if(e.type==="video"||e.type==="animated_gif"){const n=((t=e.video_info)==null?void 0:t.variants)??[];let r=n[0];for(const o of n)o.bitrate&&o.bitrate>((r==null?void 0:r.bitrate)??0)&&(r=o);return (r==null?void 0:r.url)??e.media_url_https}return ti(e.media_url_https,"orig")}function yx(e){var t,n;return ((n=(t=e.features)==null?void 0:t.all)==null?void 0:n.tags)??[]}function ti(e,t="medium"){if(!e)return "";try{const i=new URL(e);if(i.hostname==="pbs.twimg.com"){const s=i.searchParams.get("format"),l=i.pathname.match(/^(\/media\/.+)\.(\w+)$/);if(l){const[,c,h]=l;return i.pathname=c||i.pathname,i.search="",i.searchParams.set("format",h||s||"jpg"),i.searchParams.set("name",t),i.toString()}if(s||i.searchParams.has("name"))return i.searchParams.set("name",t),i.toString()}}catch{}const n=/^(https?:\/\/pbs\.twimg\.com\/media\/.+)\.(\w+)$/,r=e.match(n);if(!r){const i=e.includes("?")?"&":"?";return `${e}${i}name=${t}`}const[,o,a]=r;return `${o}?format=${a}&name=${t}`}function Ed(e){return e.replace(/_normal\.(jpe?g|png|gif)$/,".$1")}function Lu(e){const n=/format=(\w+)|\.(\w+)$|\.(\w+)\?.+$/.exec(e);return (n==null?void 0:n[1])??(n==null?void 0:n[2])??(n==null?void 0:n[3])??"jpg"}function ca(e){var n;const t=String(((n=e.legacy)==null?void 0:n.id_str)||e.rest_id||"").trim();return `https://twitter.com/${Vl(e)}/status/${t}`}function Ui(e){return `https://twitter.com/${typeof e=="string"?e:e.core.screen_name}`}function _x(e){return `https://twitter.com/${e.legacy.in_reply_to_screen_name}/status/${e.legacy.in_reply_to_status_id_str}`}function ls({title:e,description:t,children:n,onClick:r,active:o,indicatorColor:a="bg-secondary",panelClass:i,contentClass:s,buttonClass:l}){return d("section",{class:sn("module-panel -ml-2 overflow-visible pl-2 transition-colors duration-150",i),children:[d("div",{class:sn("h-12 flex items-center justify-start",s),children:[d("div",{class:"relative flex h-4 w-4 mr-3 shrink-0",children:[o&&d("span",{class:sn("animate-ping absolute inline-flex h-full w-full rounded-full opacity-75",a)}),d("span",{class:sn("relative inline-flex rounded-full h-4 w-4",a)})]}),d("div",{class:"flex flex-col flex-grow",children:[d("p",{class:"text-base m-0 font-medium leading-none",children:e}),d("p",{class:"text-sm text-base-content leading-5 text-opacity-70 m-0",children:t})]}),d("button",{class:sn("btn btn-sm p-0 w-9 h-9",l),onClick:r,children:d(Aw,{})})]}),n]})}function lr({show:e,onClose:t,title:n,children:r,class:o,fullscreen:a}){const[i,s]=De(null);if(Je(()=>{!e||typeof document>"u"||s(document.getElementById("twe-root")??document.body);},[e]),!e)return d("dialog",{class:"modal"});const l=d("dialog",{class:sn("modal modal-open z-[6000]",a&&"!p-0"),open:true,children:[d("div",{class:sn("modal-box p-3 flex min-h-0 flex-col",a&&"h-screen w-screen max-h-screen max-w-none rounded-none border-0 p-0 shadow-none",o),children:[d("header",{class:sn("flex items-center h-8 mb-1.5",a&&"mb-0 h-11 border-b border-base-300 px-3"),children:[d("div",{onClick:t,class:"w-8 h-8 mr-2 cursor-pointer flex justify-center items-center transition-colors duration-200 rounded-full hover:bg-base-200",children:d(sl,{})}),d("h2",{class:"leading-none text-lg m-0 font-semibold tracking-[0.01em]",children:n})]}),d(Li,{children:r})]}),d("form",{method:"dialog",class:"modal-backdrop",children:d("div",{onClick:t})})]});return i?Yk(l,i):l}function Hg(e){const{options:t,selected:n,onChange:r}=e,[o,a]=De(""),i=t.filter(c=>n.includes(c.value)),s=It(()=>{const c=o.trim().toLowerCase();return (c?t.filter(f=>f.label.toLowerCase().includes(c)||String(f.value).toLowerCase().includes(c)):t).slice(0,250)},[o,t]),l=c=>{const h=c.target;h.checked?r([...new Set([...n,h.value])]):r(n.filter(f=>f!==h.value));};return d("div",{class:sn("dropdown",e.class),children:[d("div",{tabIndex:0,class:"input input-bordered input-sm flex flex-row items-center space-x-1 cursor-pointer min-h-9",children:i.length?d("div",{class:"min-w-0 truncate text-xs font-medium",children:e.selectedSummary?e.selectedSummary(i.length):`${i.length} selected`}):d("span",{class:"text-xs opacity-60 select-none",children:e.placeholder||"Select..."})}),d("ul",{tabIndex:0,class:"dropdown-content menu menu-sm z-10 w-full rounded-box bg-base-100 p-2 shadow",children:[t.length>80?d("li",{class:"mb-1",children:d("input",{class:"input input-bordered input-xs w-full",value:o,placeholder:"Filter...",onInput:c=>a(c.target.value)})}):null,s.map(c=>d("li",{children:d("label",{class:"label cursor-pointer justify-start",children:[d("input",{type:"checkbox",class:"checkbox checkbox-accent checkbox-sm",value:c.value,checked:n.includes(c.value),onChange:l}),d("span",{class:"label-text ml-1",children:c.label})]})},c.value))]})]})}function jg({data:e,onClick:t}){return d("div",{class:"flex max-w-full flex-row flex-wrap items-start gap-1",children:[e.map(n=>{var r;return d("div",{class:"flex-shrink-0 block cursor-pointer relative w-12 h-12 rounded bg-base-300 overflow-hidden",onClick:()=>t(n),children:[d("img",{class:"w-full h-full object-cover",src:ti(n.media_url_https,"thumb"),alt:n.ext_alt_text||"",title:n.ext_alt_text||"",loading:"lazy",decoding:"async"}),n.type!=="photo"&&d("div",{class:"absolute bottom-0.5 left-0.5 h-4 w-max px-0.5 text-xs text-white bg-black bg-opacity-30 leading-4 text-center rounded",children:n.type==="video"?kg((r=n.video_info)==null?void 0:r.duration_millis):"GIF"}),n.type==="photo"&&n.ext_alt_text&&d("div",{class:"absolute bottom-0.5 left-0.5 h-4 w-max px-0.5 text-xs text-white bg-black bg-opacity-30 leading-4 text-center rounded",children:"ALT"})]},n.media_key??n.id_str)}),e.length?null:"N/A"]})}const wx=(function(){const t=typeof document<"u"&&document.createElement("link").relList;return t&&t.supports&&t.supports("modulepreload")?"modulepreload":"preload"})(),bx=function(e){return "/"+e},wh={},vx=function(t,n,r){let o=Promise.resolve();if(n&&n.length>0){let i=function(c){return Promise.all(c.map(h=>Promise.resolve(h).then(f=>({status:"fulfilled",value:f}),f=>({status:"rejected",reason:f}))))};document.getElementsByTagName("link");const s=document.querySelector("meta[property=csp-nonce]"),l=(s==null?void 0:s.nonce)||(s==null?void 0:s.getAttribute("nonce"));o=i(n.map(c=>{if(c=bx(c),c in wh)return;wh[c]=true;const h=c.endsWith(".css"),f=h?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${c}"]${f}`))return;const m=document.createElement("link");if(m.rel=h?"stylesheet":wx,h||(m.as="script"),m.crossOrigin="",m.href=c,l&&m.setAttribute("nonce",l),document.head.appendChild(m),h)return new Promise((g,_)=>{m.addEventListener("load",g),m.addEventListener("error",()=>_(new Error(`Unable to preload CSS for ${c}`)));})}));}function a(i){const s=new Event("vite:preloadError",{cancelable:true});if(s.payload=i,window.dispatchEvent(s),!s.defaultPrevented)throw i}return o.then(i=>{for(const s of i||[])s.status==="rejected"&&a(s.reason);return t().catch(a)})},kx=4294967296;function bh(e){let t=2166136261;for(let n=0;n<e.length;n+=1)t^=e.charCodeAt(n),t=Math.imul(t,16777619)>>>0;return t.toString(16).padStart(8,"0")}async function xl(e){var r;const t=typeof e=="string"?new TextEncoder().encode(e):e;if((r=globalThis.crypto)!=null&&r.subtle){const o=t.buffer.slice(t.byteOffset,t.byteOffset+t.byteLength),a=await globalThis.crypto.subtle.digest("SHA-256",o);return [...new Uint8Array(a)].map(i=>i.toString(16).padStart(2,"0")).join("")}let n="";for(let o=0;o<t.length;o+=4096)n+=bh(String.fromCharCode(...t.slice(o,o+4096)));return bh(`${t.length}:${n}:${kx}`)}async function qg(e){return `bundle_${(await xl(e)).slice(0,24)}`}async function Vg(e,t,n){return `record_${(await xl(`${e}:${t}:${n}`)).slice(0,32)}`}const zg={includeViewerAccountId:false,includeSourceCaptureTimes:false,includeRawGraphQL:false,includePrivateNotes:false,includeMediaBlobs:false,visibility:"shared_safe"};function Kg(e){return {visibility:e.visibility,includesViewerAccountId:e.includeViewerAccountId,includesSourceCaptureTimes:e.includeSourceCaptureTimes,includesRawGraphQL:e.includeRawGraphQL,includesPrivateNotes:e.includePrivateNotes,includesMediaBlobs:e.includeMediaBlobs,warnings:xx(e)}}function xx(e){const t=[];return e.includeViewerAccountId&&t.push("Includes the exporting account identifier."),e.includeSourceCaptureTimes&&t.push("Includes local capture/import timestamps."),e.includeRawGraphQL&&t.push("Includes raw API payloads that may contain unrelated account context."),e.includePrivateNotes&&t.push("Includes user-authored local notes or labels."),e.includeMediaBlobs&&t.push("Includes downloaded media files, increasing size and redistribution risk."),e.visibility==="public"&&t.length&&t.unshift("Public bundle includes fields that should be reviewed before sharing."),t}var Tn=Uint8Array,hr=Uint16Array,Ad=Int32Array,Kl=new Tn([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),Wl=new Tn([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),Nu=new Tn([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),Wg=function(e,t){for(var n=new hr(31),r=0;r<31;++r)n[r]=t+=1<<e[r-1];for(var o=new Ad(n[30]),r=1;r<30;++r)for(var a=n[r];a<n[r+1];++a)o[a]=a-n[r]<<5|r;return {b:n,r:o}},Gg=Wg(Kl,2),Yg=Gg.b,Bu=Gg.r;Yg[28]=258,Bu[258]=28;var Xg=Wg(Wl,0),Sx=Xg.b,vh=Xg.r,Uu=new hr(32768);for(var yn=0;yn<32768;++yn){var To=(yn&43690)>>1|(yn&21845)<<1;To=(To&52428)>>2|(To&13107)<<2,To=(To&61680)>>4|(To&3855)<<4,Uu[yn]=((To&65280)>>8|(To&255)<<8)>>1;}var Xr=(function(e,t,n){for(var r=e.length,o=0,a=new hr(t);o<r;++o)e[o]&&++a[e[o]-1];var i=new hr(t);for(o=1;o<t;++o)i[o]=i[o-1]+a[o-1]<<1;var s;if(n){s=new hr(1<<t);var l=15-t;for(o=0;o<r;++o)if(e[o])for(var c=o<<4|e[o],h=t-e[o],f=i[e[o]-1]++<<h,m=f|(1<<h)-1;f<=m;++f)s[Uu[f]>>l]=c;}else for(s=new hr(r),o=0;o<r;++o)e[o]&&(s[o]=Uu[i[e[o]-1]++]>>15-e[o]);return s}),$o=new Tn(288);for(var yn=0;yn<144;++yn)$o[yn]=8;for(var yn=144;yn<256;++yn)$o[yn]=9;for(var yn=256;yn<280;++yn)$o[yn]=7;for(var yn=280;yn<288;++yn)$o[yn]=8;var es=new Tn(32);for(var yn=0;yn<32;++yn)es[yn]=5;var Cx=Xr($o,9,0),Tx=Xr($o,9,1),Mx=Xr(es,5,0),Rx=Xr(es,5,1),Fc=function(e){for(var t=e[0],n=1;n<e.length;++n)e[n]>t&&(t=e[n]);return t},Ir=function(e,t,n){var r=t/8|0;return (e[r]|e[r+1]<<8)>>(t&7)&n},Lc=function(e,t){var n=t/8|0;return (e[n]|e[n+1]<<8|e[n+2]<<16)>>(t&7)},Dd=function(e){return (e+7)/8|0},cs=function(e,t,n){return (t==null||t<0)&&(t=0),(n==null||n>e.length)&&(n=e.length),new Tn(e.subarray(t,n))},Ix=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],or=function(e,t,n){var r=new Error(t||Ix[e]);if(r.code=e,Error.captureStackTrace&&Error.captureStackTrace(r,or),!n)throw r;return r},Ex=function(e,t,n,r){var o=e.length,a=r?r.length:0;if(!o||t.f&&!t.l)return n||new Tn(0);var i=!n,s=i||t.i!=2,l=t.i;i&&(n=new Tn(o*3));var c=function(_e){var we=n.length;if(_e>we){var Ye=new Tn(Math.max(we*2,_e));Ye.set(n),n=Ye;}},h=t.f||0,f=t.p||0,m=t.b||0,g=t.l,_=t.d,b=t.m,C=t.n,k=o*8;do{if(!g){h=Ir(e,f,1);var T=Ir(e,f+1,3);if(f+=3,T)if(T==1)g=Tx,_=Rx,b=9,C=5;else if(T==2){var I=Ir(e,f,31)+257,O=Ir(e,f+10,15)+4,B=I+Ir(e,f+5,31)+1;f+=14;for(var D=new Tn(B),v=new Tn(19),L=0;L<O;++L)v[Nu[L]]=Ir(e,f+L*3,7);f+=O*3;for(var $=Fc(v),Me=(1<<$)-1,Z=Xr(v,$,1),L=0;L<B;){var re=Z[Ir(e,f,Me)];f+=re&15;var M=re>>4;if(M<16)D[L++]=M;else {var J=0,le=0;for(M==16?(le=3+Ir(e,f,3),f+=2,J=D[L-1]):M==17?(le=3+Ir(e,f,7),f+=3):M==18&&(le=11+Ir(e,f,127),f+=7);le--;)D[L++]=J;}}var he=D.subarray(0,I),pe=D.subarray(I);b=Fc(he),C=Fc(pe),g=Xr(he,b,1),_=Xr(pe,C,1);}else or(1);else {var M=Dd(f)+4,P=e[M-4]|e[M-3]<<8,F=M+P;if(F>o){l&&or(0);break}s&&c(m+P),n.set(e.subarray(M,F),m),t.b=m+=P,t.p=f=F*8,t.f=h;continue}if(f>k){l&&or(0);break}}s&&c(m+131072);for(var ge=(1<<b)-1,z=(1<<C)-1,ue=f;;ue=f){var J=g[Lc(e,f)&ge],Pe=J>>4;if(f+=J&15,f>k){l&&or(0);break}if(J||or(2),Pe<256)n[m++]=Pe;else if(Pe==256){ue=f,g=null;break}else {var ce=Pe-254;if(Pe>264){var L=Pe-257,Ee=Kl[L];ce=Ir(e,f,(1<<Ee)-1)+Yg[L],f+=Ee;}var Qe=_[Lc(e,f)&z],X=Qe>>4;Qe||or(3),f+=Qe&15;var pe=Sx[X];if(X>3){var Ee=Wl[X];pe+=Lc(e,f)&(1<<Ee)-1,f+=Ee;}if(f>k){l&&or(0);break}s&&c(m+131072);var ne=m+ce;if(m<pe){var j=a-pe,se=Math.min(pe,ne);for(j+m<0&&or(3);m<se;++m)n[m]=r[j+m];}for(;m<ne;++m)n[m]=n[m-pe];}}t.l=g,t.p=ue,t.b=m,t.f=h,g&&(h=1,t.m=b,t.d=_,t.n=C);}while(!h);return m!=n.length&&i?cs(n,0,m):n.subarray(0,m)},no=function(e,t,n){n<<=t&7;var r=t/8|0;e[r]|=n,e[r+1]|=n>>8;},vi=function(e,t,n){n<<=t&7;var r=t/8|0;e[r]|=n,e[r+1]|=n>>8,e[r+2]|=n>>16;},Nc=function(e,t){for(var n=[],r=0;r<e.length;++r)e[r]&&n.push({s:r,f:e[r]});var o=n.length,a=n.slice();if(!o)return {t:Qg,l:0};if(o==1){var i=new Tn(n[0].s+1);return i[n[0].s]=1,{t:i,l:1}}n.sort(function(F,I){return F.f-I.f}),n.push({s:-1,f:25001});var s=n[0],l=n[1],c=0,h=1,f=2;for(n[0]={s:-1,f:s.f+l.f,l:s,r:l};h!=o-1;)s=n[n[c].f<n[f].f?c++:f++],l=n[c!=h&&n[c].f<n[f].f?c++:f++],n[h++]={s:-1,f:s.f+l.f,l:s,r:l};for(var m=a[0].s,r=1;r<o;++r)a[r].s>m&&(m=a[r].s);var g=new hr(m+1),_=$u(n[h-1],g,0);if(_>t){var r=0,b=0,C=_-t,k=1<<C;for(a.sort(function(I,O){return g[O.s]-g[I.s]||I.f-O.f});r<o;++r){var T=a[r].s;if(g[T]>t)b+=k-(1<<_-g[T]),g[T]=t;else break}for(b>>=C;b>0;){var M=a[r].s;g[M]<t?b-=1<<t-g[M]++-1:++r;}for(;r>=0&&b;--r){var P=a[r].s;g[P]==t&&(--g[P],++b);}_=t;}return {t:new Tn(g),l:_}},$u=function(e,t,n){return e.s==-1?Math.max($u(e.l,t,n+1),$u(e.r,t,n+1)):t[e.s]=n},kh=function(e){for(var t=e.length;t&&!e[--t];);for(var n=new hr(++t),r=0,o=e[0],a=1,i=function(l){n[r++]=l;},s=1;s<=t;++s)if(e[s]==o&&s!=t)++a;else {if(!o&&a>2){for(;a>138;a-=138)i(32754);a>2&&(i(a>10?a-11<<5|28690:a-3<<5|12305),a=0);}else if(a>3){for(i(o),--a;a>6;a-=6)i(8304);a>2&&(i(a-3<<5|8208),a=0);}for(;a--;)i(o);a=1,o=e[s];}return {c:n.subarray(0,r),n:t}},ki=function(e,t){for(var n=0,r=0;r<t.length;++r)n+=e[r]*t[r];return n},Zg=function(e,t,n){var r=n.length,o=Dd(t+2);e[o]=r&255,e[o+1]=r>>8,e[o+2]=e[o]^255,e[o+3]=e[o+1]^255;for(var a=0;a<r;++a)e[o+a+4]=n[a];return (o+4+r)*8},xh=function(e,t,n,r,o,a,i,s,l,c,h){no(t,h++,n),++o[256];for(var f=Nc(o,15),m=f.t,g=f.l,_=Nc(a,15),b=_.t,C=_.l,k=kh(m),T=k.c,M=k.n,P=kh(b),F=P.c,I=P.n,O=new hr(19),B=0;B<T.length;++B)++O[T[B]&31];for(var B=0;B<F.length;++B)++O[F[B]&31];for(var D=Nc(O,7),v=D.t,L=D.l,$=19;$>4&&!v[Nu[$-1]];--$);var Me=c+5<<3,Z=ki(o,$o)+ki(a,es)+i,re=ki(o,m)+ki(a,b)+i+14+3*$+ki(O,v)+2*O[16]+3*O[17]+7*O[18];if(l>=0&&Me<=Z&&Me<=re)return Zg(t,h,e.subarray(l,l+c));var J,le,he,pe;if(no(t,h,1+(re<Z)),h+=2,re<Z){J=Xr(m,g,0),le=m,he=Xr(b,C,0),pe=b;var ge=Xr(v,L,0);no(t,h,M-257),no(t,h+5,I-1),no(t,h+10,$-4),h+=14;for(var B=0;B<$;++B)no(t,h+3*B,v[Nu[B]]);h+=3*$;for(var z=[T,F],ue=0;ue<2;++ue)for(var Pe=z[ue],B=0;B<Pe.length;++B){var ce=Pe[B]&31;no(t,h,ge[ce]),h+=v[ce],ce>15&&(no(t,h,Pe[B]>>5&127),h+=Pe[B]>>12);}}else J=Cx,le=$o,he=Mx,pe=es;for(var B=0;B<s;++B){var Ee=r[B];if(Ee>255){var ce=Ee>>18&31;vi(t,h,J[ce+257]),h+=le[ce+257],ce>7&&(no(t,h,Ee>>23&31),h+=Kl[ce]);var Qe=Ee&31;vi(t,h,he[Qe]),h+=pe[Qe],Qe>3&&(vi(t,h,Ee>>5&8191),h+=Wl[Qe]);}else vi(t,h,J[Ee]),h+=le[Ee];}return vi(t,h,J[256]),h+le[256]},Ax=new Ad([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),Qg=new Tn(0),Dx=function(e,t,n,r,o,a){var i=a.z||e.length,s=new Tn(r+i+5*(1+Math.ceil(i/7e3))+o),l=s.subarray(r,s.length-o),c=a.l,h=(a.r||0)&7;if(t){h&&(l[0]=a.r>>3);for(var f=Ax[t-1],m=f>>13,g=f&8191,_=(1<<n)-1,b=a.p||new hr(32768),C=a.h||new hr(_+1),k=Math.ceil(n/3),T=2*k,M=function(We){return (e[We]^e[We+1]<<k^e[We+2]<<T)&_},P=new Ad(25e3),F=new hr(288),I=new hr(32),O=0,B=0,D=a.i||0,v=0,L=a.w||0,$=0;D+2<i;++D){var Me=M(D),Z=D&32767,re=C[Me];if(b[Z]=re,C[Me]=Z,L<=D){var J=i-D;if((O>7e3||v>24576)&&(J>423||!c)){h=xh(e,l,0,P,F,I,B,v,$,D-$,h),v=O=B=0,$=D;for(var le=0;le<286;++le)F[le]=0;for(var le=0;le<30;++le)I[le]=0;}var he=2,pe=0,ge=g,z=Z-re&32767;if(J>2&&Me==M(D-z))for(var ue=Math.min(m,J)-1,Pe=Math.min(32767,D),ce=Math.min(258,J);z<=Pe&&--ge&&Z!=re;){if(e[D+he]==e[D+he-z]){for(var Ee=0;Ee<ce&&e[D+Ee]==e[D+Ee-z];++Ee);if(Ee>he){if(he=Ee,pe=z,Ee>ue)break;for(var Qe=Math.min(z,Ee-2),X=0,le=0;le<Qe;++le){var ne=D-z+le&32767,j=b[ne],se=ne-j&32767;se>X&&(X=se,re=ne);}}}Z=re,re=b[Z],z+=Z-re&32767;}if(pe){P[v++]=268435456|Bu[he]<<18|vh[pe];var _e=Bu[he]&31,we=vh[pe]&31;B+=Kl[_e]+Wl[we],++F[257+_e],++I[we],L=D+he,++O;}else P[v++]=e[D],++F[e[D]];}}for(D=Math.max(D,L);D<i;++D)P[v++]=e[D],++F[e[D]];h=xh(e,l,c,P,F,I,B,v,$,D-$,h),c||(a.r=h&7|l[h/8|0]<<3,h-=7,a.h=C,a.p=b,a.i=D,a.w=L);}else {for(var D=a.w||0;D<i+c;D+=65535){var Ye=D+65535;Ye>=i&&(l[h/8|0]=c,Ye=i),h=Zg(l,h+1,e.subarray(D,Ye));}a.i=i;}return cs(s,0,r+Dd(h)+o)},Px=(function(){for(var e=new Int32Array(256),t=0;t<256;++t){for(var n=t,r=9;--r;)n=(n&1&&-306674912)^n>>>1;e[t]=n;}return e})(),Ox=function(){var e=-1;return {p:function(t){for(var n=e,r=0;r<t.length;++r)n=Px[n&255^t[r]]^n>>>8;e=n;},d:function(){return ~e}}},Fx=function(e,t,n,r,o){if(!o&&(o={l:1},t.dictionary)){var a=t.dictionary.subarray(-32768),i=new Tn(a.length+e.length);i.set(a),i.set(e,a.length),e=i,o.w=a.length;}return Dx(e,t.level==null?6:t.level,t.mem==null?o.l?Math.ceil(Math.max(8,Math.min(13,Math.log(e.length)))*1.5):20:12+t.mem,n,r,o)},Jg=function(e,t){var n={};for(var r in e)n[r]=e[r];for(var r in t)n[r]=t[r];return n},Wr=function(e,t){return e[t]|e[t+1]<<8},Ar=function(e,t){return (e[t]|e[t+1]<<8|e[t+2]<<16|e[t+3]<<24)>>>0},Bc=function(e,t){return Ar(e,t)+Ar(e,t+4)*4294967296},Kn=function(e,t,n){for(;n;++t)e[t]=n,n>>>=8;};function Lx(e,t){return Fx(e,t||{},0,0)}function Nx(e,t){return Ex(e,{i:2},t&&t.out,t&&t.dictionary)}var ey=function(e,t,n,r){for(var o in e){var a=e[o],i=t+o,s=r;Array.isArray(a)&&(s=Jg(r,a[1]),a=a[0]),a instanceof Tn?n[i]=[a,s]:(n[i+="/"]=[new Tn(0),s],ey(a,i,n,r));}},Sh=typeof TextEncoder<"u"&&new TextEncoder,Hu=typeof TextDecoder<"u"&&new TextDecoder,Bx=0;try{Hu.decode(Qg,{stream:!0}),Bx=1;}catch{}var Ux=function(e){for(var t="",n=0;;){var r=e[n++],o=(r>127)+(r>223)+(r>239);if(n+o>e.length)return {s:t,r:cs(e,n-1)};o?o==3?(r=((r&15)<<18|(e[n++]&63)<<12|(e[n++]&63)<<6|e[n++]&63)-65536,t+=String.fromCharCode(55296|r>>10,56320|r&1023)):o&1?t+=String.fromCharCode((r&31)<<6|e[n++]&63):t+=String.fromCharCode((r&15)<<12|(e[n++]&63)<<6|e[n++]&63):t+=String.fromCharCode(r);}};function ju(e,t){var n;if(Sh)return Sh.encode(e);for(var r=e.length,o=new Tn(e.length+(e.length>>1)),a=0,i=function(c){o[a++]=c;},n=0;n<r;++n){if(a+5>o.length){var s=new Tn(a+8+(r-n<<1));s.set(o),o=s;}var l=e.charCodeAt(n);l<128||t?i(l):l<2048?(i(192|l>>6),i(128|l&63)):l>55295&&l<57344?(l=65536+(l&1047552)|e.charCodeAt(++n)&1023,i(240|l>>18),i(128|l>>12&63),i(128|l>>6&63),i(128|l&63)):(i(224|l>>12),i(128|l>>6&63),i(128|l&63));}return cs(o,0,a)}function ty(e,t){if(t){for(var n="",r=0;r<e.length;r+=16384)n+=String.fromCharCode.apply(null,e.subarray(r,r+16384));return n}else {if(Hu)return Hu.decode(e);var o=Ux(e),a=o.s,n=o.r;return n.length&&or(8),a}}var $x=function(e,t){return t+30+Wr(e,t+26)+Wr(e,t+28)},Hx=function(e,t,n){var r=Wr(e,t+28),o=ty(e.subarray(t+46,t+46+r),!(Wr(e,t+8)&2048)),a=t+46+r,i=Ar(e,t+20),s=n&&i==4294967295?jx(e,a):[i,Ar(e,t+24),Ar(e,t+42)],l=s[0],c=s[1],h=s[2];return [Wr(e,t+10),l,c,o,a+Wr(e,t+30)+Wr(e,t+32),h]},jx=function(e,t){for(;Wr(e,t)!=1;t+=4+Wr(e,t+2));return [Bc(e,t+12),Bc(e,t+4),Bc(e,t+20)]},qu=function(e){var t=0;if(e)for(var n in e){var r=e[n].length;r>65535&&or(9),t+=r+4;}return t},Ch=function(e,t,n,r,o,a,i,s){var l=r.length,c=n.extra,h=s&&s.length,f=qu(c);Kn(e,t,i!=null?33639248:67324752),t+=4,i!=null&&(e[t++]=20,e[t++]=n.os),e[t]=20,t+=2,e[t++]=n.flag<<1|(a<0&&8),e[t++]=o&&8,e[t++]=n.compression&255,e[t++]=n.compression>>8;var m=new Date(n.mtime==null?Date.now():n.mtime),g=m.getFullYear()-1980;if((g<0||g>119)&&or(10),Kn(e,t,g<<25|m.getMonth()+1<<21|m.getDate()<<16|m.getHours()<<11|m.getMinutes()<<5|m.getSeconds()>>1),t+=4,a!=-1&&(Kn(e,t,n.crc),Kn(e,t+4,a<0?-a-2:a),Kn(e,t+8,n.size)),Kn(e,t+12,l),Kn(e,t+14,f),t+=16,i!=null&&(Kn(e,t,h),Kn(e,t+6,n.attrs),Kn(e,t+10,i),t+=14),e.set(r,t),t+=l,f)for(var _ in c){var b=c[_],C=b.length;Kn(e,t,+_),Kn(e,t+2,C),e.set(b,t+4),t+=4+C;}return h&&(e.set(s,t),t+=h),t},qx=function(e,t,n,r,o){Kn(e,t,101010256),Kn(e,t+8,n),Kn(e,t+10,n),Kn(e,t+12,r),Kn(e,t+16,o);};function Vx(e,t){t||(t={});var n={},r=[];ey(e,"",n,t);var o=0,a=0;for(var i in n){var s=n[i],l=s[0],c=s[1],h=c.level==0?0:8,f=ju(i),m=f.length,g=c.comment,_=g&&ju(g),b=_&&_.length,C=qu(c.extra);m>65535&&or(11);var k=h?Lx(l,c):l,T=k.length,M=Ox();M.p(l),r.push(Jg(c,{size:l.length,crc:M.d(),c:k,f,m:_,u:m!=i.length||_&&g.length!=b,o,compression:h})),o+=30+m+C+T,a+=76+2*(m+C)+(b||0)+T;}for(var P=new Tn(a+22),F=o,I=a-o,O=0;O<r.length;++O){var f=r[O];Ch(P,f.o,f,f.f,f.u,f.c.length);var B=30+f.f.length+qu(f.extra);P.set(f.c,f.o+B),Ch(P,o,f,f.f,f.u,f.c.length,f.o,f.m),o+=16+B+(f.m?f.m.length:0);}return qx(P,o,r.length,I,F),P}function zx(e,t){for(var n={},r=e.length-22;Ar(e,r)!=101010256;--r)(!r||e.length-r>65558)&&or(13);var o=Wr(e,r+8);if(!o)return {};var a=Ar(e,r+16),i=a==4294967295||o==65535;if(i){var s=Ar(e,r-12);i=Ar(e,s)==101075792,i&&(o=Ar(e,s+32),a=Ar(e,s+48));}for(var l=0;l<o;++l){var c=Hx(e,a,i),h=c[0],f=c[1],m=c[2],g=c[3],_=c[4],b=c[5],C=$x(e,b);a=_,h?h==8?n[g]=Nx(e.subarray(C,C+f),{out:new Tn(m)}):or(14,"unknown compression type "+h):n[g]=cs(e,C,C+f);}return n}const Kx=1e4,Wx=128*1024*1024,Gx=512*1024*1024;function Yx(e){return !!e&&typeof e=="object"&&typeof e.arrayBuffer=="function"}function Sl(e){const t=new Uint8Array(e.byteLength);return t.set(e),t}async function Xx(e){const t=await e.arrayBuffer();return Sl(new Uint8Array(t))}function Zx(e){if(!e||typeof e!="object")return null;if(ArrayBuffer.isView(e)){const n=e;return Sl(new Uint8Array(n.buffer,n.byteOffset,n.byteLength))}const t=e;return typeof t.byteLength=="number"&&typeof t.slice=="function"?Sl(new Uint8Array(e)):null}function ny(e){const t=e.replace(/\\/g,"/").replace(/^\/+/,"");if(!t||t.includes("..")||t.startsWith("/"))throw new Error(`Unsafe bundle ZIP path: ${e}`);return t}function Qx(e){const t={};for(const n of e){const r=ny(n.path),o={level:n.level??6};t[r]=[typeof n.data=="string"?ju(n.data):n.data,o];}return Vx(t)}async function Jx(e,t={}){const n=Yx(e)?await Xx(e):Zx(e);if(!n)throw new Error("Bundle ZIP input must be a File, Blob, ArrayBuffer, or Uint8Array.");const r=t.maxEntries??Kx,o=t.maxEntryBytes??Wx,a=t.maxTotalBytes??Gx,i=zx(n),s=new Map;let l=0;for(const[c,h]of Object.entries(i)){if(s.size>=r)throw new Error(`Bundle ZIP exceeds ${r} entries.`);const f=ny(c);if(h.byteLength>o)throw new Error(`Bundle ZIP entry exceeds limit: ${f}`);if(l+=h.byteLength,l>a)throw new Error(`Bundle ZIP exceeds ${a} bytes after decompression.`);s.set(f,Sl(h));}return {entries:s,totalBytes:l}}function Th(e,t){const n=e.get(t);if(!n)throw new Error(`Missing bundle ZIP entry: ${t}`);return ty(n)}function e0(e){return String(e||"bundle").trim().replace(/[^a-zA-Z0-9._-]+/g,"_").replace(/_+/g,"_").replace(/^_+|_+$/g,"").slice(0,80)||"bundle"}function Mh(e){if(typeof e=="string")try{const t=new URL(e);return t.protocol==="http:"||t.protocol==="https:"?t.href:void 0}catch{return}}function t0(e,t){const r=String((e&&typeof e=="object"?e:{}).__typename||t.__typename||"").toLowerCase();return r.includes("tweet")||t.full_text||t.media?"tweet":r.includes("user")||t.screen_name||t.profile_image_url?"user":"unknown"}function n0(e,t){const r=(e&&typeof e=="object"?e:{}).twe_private_fields,o=[r==null?void 0:r.created_at,r==null?void 0:r.updated_at,t.created_at,t.time,t.date];for(const a of o){const i=Number(a);if(Number.isFinite(i)&&i>0)return i;if(typeof a=="string"){const s=Date.parse(a);if(Number.isFinite(s))return s}}}async function r0(e,t,n){const r=t0(t.original,t.record),o=String(t.id||t.record.id||t.record.rest_id||""),a=await Vg(e,r,o||JSON.stringify(t.record)),i=n.includeOriginalMetadata?{...t.record,metadata:t.original}:t.record;return {id:a,kind:r,sourceId:o||void 0,observedAt:n0(t.original,t.record),sensitivity:"low",data:i,mediaRefs:Array.isArray(t.record.media)?t.record.media.map((s,l)=>({id:`${a}:media:${l}`,type:s.type==="photo"||s.type==="video"||s.type==="animated_gif"?s.type:"unknown",url:Mh(s.original),previewUrl:Mh(s.thumbnail),altText:typeof s.ext_alt_text=="string"?s.ext_alt_text:void 0})):void 0}}function o0(){return {records:0,tweets:0,users:0,socialEdges:0,captures:0,mediaBlobs:0}}function a0(e,t){e.records+=1,t.kind==="tweet"&&(e.tweets+=1),t.kind==="user"&&(e.users+=1),t.kind==="social_edge"&&(e.socialEdges+=1),t.kind==="capture"&&(e.captures+=1),e.mediaBlobs+=0;}async function i0(e,t){const n=Date.now(),r=typeof performance<"u"?performance.now():Date.now(),o=Math.max(0,Math.floor(Number(t.totalRecords||0))),a=(P,F)=>{var I;(I=t.onProgress)==null||I.call(t,{phase:P,processedRecords:F,totalRecords:o||F,elapsedMs:(typeof performance<"u"?performance.now():Date.now())-r});},i=await qg(`${t.title}:${t.scope}:${t.queryText||""}:${n}:${o}`),s=o0(),l=[],c=[];let h=0;for await(const P of e){if(!P)continue;const F=await r0(i,P,t);a0(s,F),l.push(`${JSON.stringify(F)}
`);for(const I of F.mediaRefs||[])I.url&&c.push(I.url);h+=1,(h===1||h===o||h%100===0)&&a("envelope",h);}const f=l.join(""),m=Kg(zg),g=[{path:"manifest.json",contentType:"application/json",role:"manifest"},{path:"records/records.jsonl",contentType:"application/x-ndjson",role:"records",bytes:new TextEncoder().encode(f).byteLength,sha256:await xl(f)}],_=c.join(`
`)+(c.length?`
`:"");c.length&&g.push({path:"media/media-urls.txt",contentType:"text/plain",role:"media",bytes:new TextEncoder().encode(_).byteLength,sha256:await xl(_)});const b={id:i,title:t.title,description:t.description,producer:{app:"twitter-web-exporter",appVersion:vr.version,schemaVersion:1,exportedAt:n},privacy:m,counts:s,files:g},C=g[0];C&&(g[0]={...C,bytes:new TextEncoder().encode(JSON.stringify(b,void 0,2)).byteLength}),a("manifest",h);const k=t.compressionLevel??1,T=[{path:"manifest.json",data:JSON.stringify(b,void 0,2),level:k},{path:"records/records.jsonl",data:f,level:k}];c.length&&T.push({path:"media/media-urls.txt",data:_,level:k}),a("zip",h);const M={filename:`twe-bundle-${e0(t.title)}-${n}.zip`,bytes:Qx(T),manifest:b};return a("done",h),M}async function s0(e,t){return i0(e,{...t,totalRecords:t.totalRecords??e.length})}async function l0(e,t){const{filename:n,bytes:r}=await s0(e,t),o=r.buffer.slice(r.byteOffset,r.byteOffset+r.byteLength),{saveFile:a}=await vx(async()=>{const{saveFile:i}=await Promise.resolve().then(()=>S0);return {saveFile:i}},void 0);return a(n,new Blob([o],{type:"application/zip"})),n}function Ei(e){return !!e&&typeof e=="object"&&!Array.isArray(e)}function wr(e,t,n){e.push({path:t,message:n,severity:"error"});}function c0(e){const t=[];if(!Ei(e))return wr(t,"$","Manifest must be an object."),{ok:false,issues:t};const n=e;return (!n.id||typeof n.id!="string")&&wr(t,"$.id","Missing bundle id."),(!n.title||typeof n.title!="string")&&wr(t,"$.title","Missing title."),Ei(n.producer)||wr(t,"$.producer","Missing producer block."),Ei(n.privacy)||wr(t,"$.privacy","Missing privacy block."),Ei(n.counts)||wr(t,"$.counts","Missing counts block."),Array.isArray(n.files)||wr(t,"$.files","Files must be an array."),{ok:!t.some(r=>r.severity==="error"),issues:t}}function u0(e){const t=[];if(!Ei(e))return wr(t,"$","Record envelope must be an object."),{ok:false,issues:t};const n=e;return (!n.id||typeof n.id!="string")&&wr(t,"$.id","Missing record id."),(!n.kind||typeof n.kind!="string")&&wr(t,"$.kind","Missing record kind."),(!n.sensitivity||typeof n.sensitivity!="string")&&wr(t,"$.sensitivity","Missing sensitivity."),"data"in n||wr(t,"$.data","Missing data payload."),{ok:!t.some(r=>r.severity==="error"),issues:t}}function ry(e){if(e&&typeof e=="object"){const t=e.message;if(typeof t=="string"&&t.trim())return t}return String(e)}function d0(e,t){const n=e.trim();if(!n)return null;try{return JSON.parse(n)}catch(r){throw new Error(`Invalid JSONL at records line ${t}: ${ry(r)}`)}}function f0(e){const t=[],n=e.data;for(const r of ["full_text","text","description","name","screen_name"]){const o=n==null?void 0:n[r];typeof o=="string"&&o.trim()&&t.push(o);}return t.length||t.push(JSON.stringify(e.data).slice(0,2e4)),t.join(`
`)}function h0(e,t){return {id:e.id,title:e.title,description:e.description,status:"importing",visibility:e.privacy.visibility,importedAt:t,updatedAt:t,schemaVersion:e.producer.schemaVersion,appVersion:e.producer.appVersion,recordCount:e.counts.records,mediaBlobCount:e.counts.mediaBlobs,manifest:e}}async function oy(e,t){var k,T,M;const n=Date.now(),{entries:r}=await Jx(t),o=JSON.parse(Th(r,"manifest.json")),a=c0(o);if(!a.ok)throw new Error(`Invalid bundle manifest: ${((k=a.issues[0])==null?void 0:k.message)??"unknown error"}`);const i=((T=o.files.find(P=>P.role==="records"))==null?void 0:T.path)??[...r.keys()].find(P=>P.endsWith(".jsonl"));if(!i)throw new Error("Bundle is missing a records JSONL file.");const s=`${o.id}:import:${n}`,l=Th(r,i),c={id:`${o.id}:all`,bundle_id:o.id,name:"All Records",kind:"mixed",record_count:0,created_at:n,updated_at:n},h=[],f=[],m=[];let g=0,_=0;const b=l.split(/\r?\n/);for(let P=0;P<b.length;P+=1){const F=d0(b[P]??"",P+1);if(!F)continue;g+=1;const I=u0(F);if(!I.ok){_+=1,m.push(`Skipped line ${P+1}: ${((M=I.issues[0])==null?void 0:M.message)??"invalid record"}`);continue}const O=`${o.id}:${F.id}`;h.push({id:O,bundle_id:o.id,kind:F.kind,source_id:F.sourceId,source_extension:F.sourceExtension,observed_at:F.observedAt,sensitivity:F.sensitivity,data:F.data,media_refs:F.mediaRefs,search_text:f0(F),created_at:n,updated_at:n}),f.push({id:`${c.id}:${F.id}`,bundle_id:o.id,collection_id:c.id,record_id:O,kind:F.kind,source_id:F.sourceId,sort_time:F.observedAt,created_at:n});}c.record_count=f.length;const C={id:s,bundle_id:o.id,started_at:n,finished_at:Date.now(),status:"ok",records_seen:g,records_imported:h.length,records_skipped:_,warnings:m};try{await e.bundlePutImportBatch({bundle:h0({...o,producer:{...o.producer,appVersion:o.producer.appVersion||vr.version}},n),collections:[c],items:f,snapshots:h,report:C}),await e.bundleMarkReady(o.id);}catch(P){throw await e.bundleMarkFailed(o.id,ry(P)),P}return {bundleId:o.id,recordsSeen:g,recordsImported:h.length,recordsSkipped:_,warnings:m}}function p0(e){if(e&&typeof e=="object"){const t=e.message;if(typeof t=="string"&&t.trim())return t}return String(e)}function Dr(e){return !!e&&typeof e=="object"&&!Array.isArray(e)}function ay(e){if(e.metadata&&Dr(e.metadata))return ay(e.metadata);const t=String(e.__typename||"").toLowerCase();return t.includes("tweet")||e.full_text||e.media||e.bookmark_folder_id?"tweet":t.includes("user")||e.screen_name||e.profile_image_url?"user":"unknown"}function Rh(e){if(typeof e=="string")try{const t=new URL(e);return t.protocol==="http:"||t.protocol==="https:"?t.href:void 0}catch{return}}function iy(e,t){return e.metadata&&Dr(e.metadata)?iy(e.metadata,t):String(e.rest_id||e.id||e.user_id||e.tweet_id||t)}function m0(e){const t=Dr(e.metadata)?e.metadata:null,n=Dr(t==null?void 0:t.twe_private_fields)?t.twe_private_fields:Dr(e.twe_private_fields)?e.twe_private_fields:null,r=[n==null?void 0:n.created_at,n==null?void 0:n.updated_at,e.created_at,e.date,e.time];for(const o of r){const a=Number(o);if(Number.isFinite(a)&&a>0)return a;if(typeof o=="string"){const i=Date.parse(o);if(Number.isFinite(i))return i}}}function g0(e){return Array.isArray(e)?e.filter(Dr):Dr(e)?Array.isArray(e.records)?e.records.filter(Dr):Array.isArray(e.data)?e.data.filter(Dr):Array.isArray(e.rows)?e.rows.filter(Dr):[e]:[]}function y0(e,t){const n=e.trim();if(!n)return [];if(t.endsWith(".jsonl")||n.includes(`
{`)){const r=[];for(const o of n.split(/\r?\n/)){const a=o.trim();if(!a)continue;const i=JSON.parse(a);Dr(i)&&r.push(i);}if(r.length)return r}return g0(JSON.parse(n))}async function _0(e,t,n){const r=ay(t),o=iy(t,n),a=await Vg(e,r,o);return {id:a,kind:r,sourceId:o,observedAt:m0(t),sensitivity:"low",data:t,mediaRefs:Array.isArray(t.media)?t.media.map((i,s)=>({id:`${a}:media:${s}`,type:i.type==="photo"||i.type==="video"||i.type==="animated_gif"?i.type:"unknown",url:Rh(i.original),previewUrl:Rh(i.thumbnail),altText:typeof i.ext_alt_text=="string"?i.ext_alt_text:void 0})):void 0}}async function sy(e,t){const n=Date.now(),r=await t.text(),o=y0(r,t.name),a=await qg(`legacy:${t.name}:${t.size}:${n}`),i=await Promise.all(o.map((g,_)=>_0(a,g,_))),s=Kg({...zg,includeSourceCaptureTimes:true}),l={id:a,title:t.name.replace(/\.(json|jsonl)$/i,""),description:`Imported from legacy ${t.name}`,producer:{app:"twitter-web-exporter",appVersion:vr.version,schemaVersion:1,exportedAt:n},privacy:s,counts:{records:i.length,tweets:i.filter(g=>g.kind==="tweet").length,users:i.filter(g=>g.kind==="user").length,socialEdges:0,captures:0,mediaBlobs:0},files:[{path:t.name,contentType:t.name.endsWith(".jsonl")?"application/x-ndjson":"application/json",role:"records",bytes:t.size}]},c={id:`${a}:all`,bundle_id:a,name:"All Records",kind:"mixed",record_count:i.length,created_at:n,updated_at:n},h=i.map(g=>({id:`${a}:${g.id}`,bundle_id:a,kind:g.kind,source_id:g.sourceId,observed_at:g.observedAt,sensitivity:g.sensitivity,data:g.data,media_refs:g.mediaRefs,search_text:JSON.stringify(g.data).slice(0,2e4),created_at:n,updated_at:n})),f=h.map(g=>({id:`${c.id}:${g.id}`,bundle_id:a,collection_id:c.id,record_id:g.id,kind:g.kind,source_id:g.source_id,sort_time:g.observed_at,created_at:n})),m={id:`${a}:import:${n}`,bundle_id:a,started_at:n,finished_at:Date.now(),status:"ok",records_seen:o.length,records_imported:h.length,records_skipped:o.length-h.length,warnings:["Imported through legacy JSON/JSONL compatibility path."]};try{await e.bundlePutImportBatch({bundle:{id:a,title:l.title,description:l.description,status:"importing",visibility:l.privacy.visibility,importedAt:n,updatedAt:n,schemaVersion:l.producer.schemaVersion,appVersion:vr.version,recordCount:h.length,mediaBlobCount:0,manifest:l},collections:[c],items:f,snapshots:h,report:m}),await e.bundleMarkReady(a);}catch(g){throw await e.bundleMarkFailed(a,p0(g)),g}return {bundleId:a,recordsSeen:o.length,recordsImported:h.length,recordsSkipped:o.length-h.length,warnings:m.warnings}}function ly(e){return !!e&&typeof e=="object"&&!Array.isArray(e)}function Ih(e){if(!ly(e))return {};try{return JSON.parse(JSON.stringify(e))}catch{return {...e}}}function w0(e){const t=Ih(e),n=t.metadata;return ly(n)?Ih(n):t}function En(e,t){const n=e[t];return typeof n=="string"?n:""}function ir(e,t){const n=e[t];if(typeof n=="number"&&Number.isFinite(n))return n;if(typeof n=="string"){const r=Number(n);return Number.isFinite(r)?r:0}return 0}function b0(e,t){if(e.legacy&&e.core)return e;const n=e,r=String(e.rest_id||t.source_id||t.id),o=En(n,"screen_name")||En(n,"author_screen_name"),a=En(n,"name")||En(n,"profile_name")||o,i=En(n,"profile_image_url"),s=En(n,"created_at")||(t.observed_at?new Date(t.observed_at).toUTCString():""),l=En(n,"full_text")||En(n,"text")||En(n,"content"),h=(Array.isArray(n.media)?n.media:[]).map((f,m)=>{const g=En(f,"original")||En(f,"url"),_=En(f,"thumbnail")||En(f,"previewUrl")||g;return {id_str:En(f,"id_str")||`${r}-media-${m}`,media_key:En(f,"media_key")||`${r}-media-${m}`,type:En(f,"type")||"photo",url:_,media_url_https:_||g,expanded_url:g,ext_alt_text:En(f,"ext_alt_text")||En(f,"altText"),original_info:{width:ir(f,"width")||void 0,height:ir(f,"height")||void 0},sizes:{large:{w:ir(f,"width")||1,h:ir(f,"height")||1,resize:"fit"}}}});return e.rest_id=r,e.legacy={id_str:r,full_text:l,created_at:s,favorite_count:ir(n,"favorite_count")||ir(n,"favorites"),retweet_count:ir(n,"retweet_count")||ir(n,"retweets"),reply_count:ir(n,"reply_count")||ir(n,"replies"),bookmark_count:ir(n,"bookmark_count")||ir(n,"bookmarks"),quote_count:ir(n,"quote_count")||ir(n,"quotes"),entities:{urls:[],media:h},extended_entities:{media:h}},e.core={user_results:{result:{rest_id:En(n,"user_id")||En(n,"author_id")||"",core:{screen_name:o,name:a},avatar:{image_url:i},legacy:{screen_name:o,name:a,profile_image_url_https:i}}}},e}function cy(e){const t=w0(e.data);return t.__twe_imported_bundle_id=e.bundle_id,t.__twe_imported_snapshot_id=e.id,t.__twe_imported_source_id=e.source_id,!t.rest_id&&e.source_id&&(t.rest_id=e.source_id),e.kind==="tweet"&&b0(t,e),(!t.twe_private_fields||typeof t.twe_private_fields!="object")&&(t.twe_private_fields={created_at:e.observed_at||e.created_at,updated_at:e.updated_at}),t}function v0(e,t){return e.filter(n=>!t||n.kind===t).map(n=>cy(n))}const k0="twe_stream_export_row_delay_ms_v1",No={JSON:"JSON",HTML:"HTML",CSV:"CSV"};function ts(e){return `"${e.replace(/"/g,'""').replace(/\n/g,"\\n").replace(/\r/g,"\\r")}"`}function fa(e,t,n=false){const r=document.createElement("a");let o;t instanceof Blob?o=t:o=new Blob(n?[new Uint8Array([239,187,191]),t]:[t],{type:"text/plain;charset=utf-8"});const a=URL.createObjectURL(o);r.href=a,r.download=e,r.click(),URL.revokeObjectURL(a);}async function uy(e,t,n,r){try{let o="",a=!1;switch(Ie.info(`Exporting to ${t} file: ${n}`),t){case No.JSON:o=await fy(e);break;case No.HTML:o=await hy(e,r);break;case No.CSV:a=!0,o=await py(e);break}fa(n,o,a);}catch(o){Ie.errorWithBanner("Failed to export file",o);}}function Eh(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;")}function Ah(e){return e==null?"":typeof e=="string"?e:typeof e=="number"||typeof e=="boolean"?String(e):JSON.stringify(e)}function x0(){if(typeof localStorage>"u")return 0;try{const e=localStorage.getItem(k0),t=Number(e||0);return Number.isFinite(t)&&t>0?Math.min(1e3,t):0}catch{return 0}}async function Uc(e){e&&await new Promise(t=>{globalThis.setTimeout(t,e);});}async function dy(e,t,n,r,o={}){var a,i,s;try{Ie.info(`Streaming export to ${t} file: ${n}`);let l=0,c=[];const h=[],f=x0(),m=()=>{var _;l+=1,(_=o.onProgress)==null||_.call(o,l);};if(t===No.JSON){h.push(`[
`);let _=!0;for await(const b of e){if((a=o.signal)!=null&&a.aborted)return;h.push(_?"":`,
`),h.push(JSON.stringify(b,void 0,"  ").replace(/^/gm,"  ")),_=!1,m(),await Uc(f);}h.push(`
]
`),fa(n,new Blob(h,{type:"application/json;charset=utf-8"}));return}if(t===No.CSV){let _=!1;for await(const b of e){if((i=o.signal)!=null&&i.aborted)return;_||(c=Object.keys(b),h.push(c.join(",")+`
`),_=!0),h.push(c.map(C=>{const k=b[C];return ts(typeof k=="object"?JSON.stringify(k):Ah(k))}).join(",")+`
`),m(),await Uc(f);}fa(n,new Blob([new Uint8Array([239,187,191]),...h],{type:"text/csv;charset=utf-8"}));return}h.push(`
    <html>
      <head>
        <meta charset="utf-8">
        <title>Exported Data ${new Date().toISOString()}</title>
        <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css">
      </head>
      <body>
        <table class="table table-striped">
`);let g=!1;for await(const _ of e){if((s=o.signal)!=null&&s.aborted)return;if(!g){c=Object.keys(_),h.push("<thead><tr>");for(const b of c)h.push(`<th>${Eh(r[b]??b)}</th>`);h.push("</tr></thead><tbody>"),g=!0;}h.push("<tr>");for(const b of c)h.push(`<td>${Eh(Ah(_[b]))}</td>`);h.push("</tr>"),m(),await Uc(f);}h.push(`
          </tbody>
        </table>
      </body>
    </html>
`),fa(n,new Blob(h,{type:"text/html;charset=utf-8"}));}catch(l){Ie.errorWithBanner("Failed to stream export file",l);}}async function fy(e){return JSON.stringify(e,void 0,"  ")}async function hy(e,t){const n=document.createElement("table"),r=document.createElement("thead"),o=document.createElement("tbody"),a=Object.keys(e[0]??{}),i=document.createElement("tr");for(const s of a){const l=document.createElement("th");l.textContent=t[s]??s,i.appendChild(l);}r.appendChild(i),n.appendChild(r),n.className="table table-striped";for(const s of e){const l=document.createElement("tr");for(const c of a){const h=document.createElement("td"),f=s[c];if(c==="profile_image_url"||c==="profile_banner_url"){const m=document.createElement("img");m.src=f,m.width=50,h.innerHTML="",h.appendChild(m);}else if(c==="media"){if((f==null?void 0:f.length)>0)for(const m of f){const g=document.createElement("img");g.src=m.thumbnail,g.width=50,g.alt=m.ext_alt_text||"",g.title=m.ext_alt_text||"";const _=document.createElement("a");_.href=m.original,_.target="_blank",_.style.marginRight="0.5em",_.appendChild(g),h.appendChild(_);}}else if(c==="full_text"||c==="description"){const m=document.createElement("p");m.textContent=typeof f=="string"?f:JSON.stringify(f),m.style.whiteSpace="pre-wrap",m.style.maxWidth="640px",h.appendChild(m);}else if(c==="metadata"){const m=document.createElement("details"),g=document.createElement("summary");g.textContent="Expand",m.appendChild(g);const _=document.createElement("pre");_.textContent=JSON.stringify(f,void 0,"  "),m.appendChild(_),h.appendChild(m);}else if(c==="url"){const m=document.createElement("a");m.href=f,m.target="_blank",m.textContent=f,h.appendChild(m);}else h.textContent=typeof f=="string"?f:JSON.stringify(s[c]);l.appendChild(h);}o.appendChild(l);}return n.appendChild(o),`
    <html>
      <head>
        <meta charset="utf-8">
        <title>Exported Data ${new Date().toISOString()}</title>
        <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css">
      </head>
      <body>
        ${n.outerHTML}
      </body>
    </html>
  `}async function py(e){const t=Object.keys(e[0]??{});let n=t.join(",")+`
`;for(const r of e){const o=t.map(a=>{const i=r[a];return typeof i=="string"?ts(i):typeof i=="object"?ts(JSON.stringify(i)):i});n+=o.join(","),n+=`
`;}return n}const S0=Object.freeze(Object.defineProperty({__proto__:null,EXPORT_FORMAT:No,csvEscapeStr:ts,csvExporter:py,exportData:uy,exportDataFromAsyncRows:dy,htmlExporter:hy,jsonExporter:fy,saveFile:fa},Symbol.toStringTag,{value:"Module"}));var Kr=typeof window=="object"&&window.window===window?window:typeof self=="object"&&self.self===self?self:typeof global=="object"&&global.global===global?global:void 0;function C0(e,t){return typeof t>"u"?t={autoBom:false}:typeof t!="object"&&(console.warn("Deprecated: Expected third argument to be a object"),t={autoBom:!t}),t.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(e.type)?new Blob(["\uFEFF",e],{type:e.type}):e}function $c(e,t,n){var r=new XMLHttpRequest;r.open("GET",e),r.responseType="blob",r.onload=function(){ns(r.response,t,n);},r.onerror=function(){console.error("could not download file");},r.send();}function Dh(e){var t=new XMLHttpRequest;t.open("HEAD",e,false);try{t.send();}catch{}return t.status>=200&&t.status<=299}function Is(e){try{e.dispatchEvent(new MouseEvent("click"));}catch{var t=document.createEvent("MouseEvents");t.initMouseEvent("click",true,true,window,0,0,0,80,20,false,false,false,false,0,null),e.dispatchEvent(t);}}var Ph=Kr.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),ns=Kr.saveAs||(typeof window!="object"||window!==Kr?function(){}:"download"in HTMLAnchorElement.prototype&&!Ph?function(t,n,r){var o=Kr.URL||Kr.webkitURL,a=document.createElement("a");n=n||t.name||"download",a.download=n,a.rel="noopener",typeof t=="string"?(a.href=t,a.origin!==location.origin?Dh(a.href)?$c(t,n,r):Is(a,a.target="_blank"):Is(a)):(a.href=o.createObjectURL(t),setTimeout(function(){o.revokeObjectURL(a.href);},4e4),setTimeout(function(){Is(a);},0));}:"msSaveOrOpenBlob"in navigator?function(t,n,r){if(n=n||t.name||"download",typeof t=="string")if(Dh(t))$c(t,n,r);else {var o=document.createElement("a");o.href=t,o.target="_blank",setTimeout(function(){Is(o);});}else navigator.msSaveOrOpenBlob(C0(t,r),n);}:function(t,n,r,o){if(o=o||open("","_blank"),o&&(o.document.title=o.document.body.innerText="downloading..."),typeof t=="string")return $c(t,n,r);var a=t.type==="application/octet-stream",i=/constructor/i.test(Kr.HTMLElement)||Kr.safari,s=/CriOS\/[\d]+/.test(navigator.userAgent);if((s||a&&i||Ph)&&typeof FileReader<"u"){var l=new FileReader;l.onloadend=function(){var f=l.result;f=s?f:f.replace(/^data:[^;]*;/,"data:attachment/file;"),o?o.location.href=f:location=f,o=null;},l.readAsDataURL(t);}else {var c=Kr.URL||Kr.webkitURL,h=c.createObjectURL(t);o?o.location=h:location.href=h,o=null,setTimeout(function(){c.revokeObjectURL(h);},4e4);}});Kr.saveAs=ns.saveAs=ns;const T0=67324752,M0=33639248,R0=101010256,my=2048,Vu=20;let Hc=null;function I0(){if(Hc)return Hc;const e=new Uint32Array(256);for(let t=0;t<256;t++){let n=t;for(let r=0;r<8;r++)n=n&1?3988292384^n>>>1:n>>>1;e[t]=n>>>0;}return Hc=e,e}function E0(e){const t=I0();let n=4294967295;for(let r=0;r<e.length;r++){const o=e[r]??0;n=(t[(n^o)&255]??0)^n>>>8;}return (n^4294967295)>>>0}function A0(e){const t=Math.floor(e.getSeconds()/2);return (e.getHours()<<11|e.getMinutes()<<5|t)&65535}function D0(e){return (Math.max(1980,e.getFullYear())-1980<<9|e.getMonth()+1<<5|e.getDate())&65535}function P0(e,t,n,r,o){const a=new Uint8Array(30+e.length),i=new DataView(a.buffer,a.byteOffset,a.byteLength);return i.setUint32(0,T0,true),i.setUint16(4,Vu,true),i.setUint16(6,my,true),i.setUint16(8,0,true),i.setUint16(10,r,true),i.setUint16(12,o,true),i.setUint32(14,t,true),i.setUint32(18,n,true),i.setUint32(22,n,true),i.setUint16(26,e.length,true),i.setUint16(28,0,true),a.set(e,30),a}function O0(e,t,n,r,o,a){const i=new Uint8Array(46+e.length),s=new DataView(i.buffer,i.byteOffset,i.byteLength);return s.setUint32(0,M0,true),s.setUint16(4,Vu,true),s.setUint16(6,Vu,true),s.setUint16(8,my,true),s.setUint16(10,0,true),s.setUint16(12,r,true),s.setUint16(14,o,true),s.setUint32(16,t,true),s.setUint32(20,n,true),s.setUint32(24,n,true),s.setUint16(28,e.length,true),s.setUint16(30,0,true),s.setUint16(32,0,true),s.setUint16(34,0,true),s.setUint16(36,0,true),s.setUint32(38,0,true),s.setUint32(42,a,true),i.set(e,46),i}function F0(e,t,n){const r=new Uint8Array(22),o=new DataView(r.buffer,r.byteOffset,r.byteLength);return o.setUint32(0,R0,true),o.setUint16(4,0,true),o.setUint16(6,0,true),o.setUint16(8,e,true),o.setUint16(10,e,true),o.setUint32(12,t,true),o.setUint32(16,n,true),o.setUint16(20,0,true),r}function Es(e){return L0(e)}function L0(e){const t=new Uint8Array(e.byteLength);return t.set(e),t.buffer}function gy(e){return new Promise(t=>setTimeout(t,e))}function N0(){return new Promise(e=>{if(typeof requestAnimationFrame=="function"){requestAnimationFrame(()=>e());return}setTimeout(e,0);})}function B0(e){return e.type==="video"||e.type==="animated_gif"||/\.mp4(?:[?#].*)?$/i.test(e.url)}function U0(e){try{return new URL(e).hostname}catch{return ""}}function $0(e){if(typeof e=="number")return {minDelayBetweenStartsMs:Math.max(0,e),globalConcurrency:1,perHostConcurrency:1,videoConcurrency:1,maxRetries:0};const t=e||{};return {minDelayBetweenStartsMs:Math.max(0,t.minDelayBetweenStartsMs??100),globalConcurrency:Math.max(1,Math.min(32,t.globalConcurrency??8)),perHostConcurrency:Math.max(1,Math.min(32,t.perHostConcurrency??8)),videoConcurrency:Math.max(1,Math.min(16,t.videoConcurrency??3)),maxRetries:Math.max(0,Math.min(8,t.maxRetries??3))}}function H0(e){const t=Math.min(3e4,750*2**Math.max(0,e-1)),n=.8+Math.random()*.4;return Math.round(t*n)}async function j0(e,t){let n=null;for(let r=0;r<=t;r+=1){try{const o=await fetch(e.url);if(o.ok)return await o.blob();{const a=new Error(`Failed to fetch ${e.url}: HTTP ${o.status}`);if(o.status===403||o.status===404)throw a;n=a;}}catch(o){n=o;const a=o instanceof Error?o.message:String(o);if(/HTTP (403|404)/.test(a))throw o}r<t&&await gy(H0(r+1));}throw n instanceof Error?n:new Error(`Failed to fetch ${e.url}`)}async function q0(e,t,n,r){const o=$0(r),a=new Array(t.length),i=t.length;let s=0,l=0,c=0,h=0,f=0;const m=new Map,g=async C=>{const k=U0(C.url),T=B0(C);for(;;){const M=m.get(k)||0,P=Date.now()-c;if(h<o.globalConcurrency&&M<o.perHostConcurrency&&(!T||f<o.videoConcurrency)&&P>=o.minDelayBetweenStartsMs)return h+=1,T&&(f+=1),m.set(k,M+1),c=Date.now(),()=>{h-=1,T&&(f-=1);const F=m.get(k)||1;F<=1?m.delete(k):m.set(k,F-1);};await gy(Math.max(25,Math.min(100,o.minDelayBetweenStartsMs-P)));}},_=async()=>{for(;s<t.length;){const C=s++,k=t[C];if(!k)continue;const T=await g(k),M=Date.now();try{Ie.debug(`Start downloading ${k.filename} from ${k.url}`),a[C]={filename:k.filename,blob:await j0(k,o.maxRetries)},l+=1,n==null||n(l,i,k),Ie.debug(`Finished downloading ${k.filename} in ${Date.now()-M}ms`);}finally{T();}}},b=Math.min(o.globalConcurrency,t.length||1);await Promise.all(Array.from({length:b},()=>_())),await Pd(e,a.filter(C=>!!C),typeof r=="object"?r.onZipProgress:void 0);}async function Pd(e,t,n){Ie.info(`Exporting to ZIP file: ${e}`);const r=new Date,o=A0(r),a=D0(r),i=[],s=[];let l=0,c=0;const h=new TextEncoder,f=t.length;for(const[_,b]of t.entries()){const{filename:C,blob:k}=b,T=h.encode(C),M=new Uint8Array(await k.arrayBuffer()),P=E0(M),F=M.byteLength,I=l,O=P0(T,P,F,o,a);i.push(Es(O),Es(M)),l+=O.byteLength+M.byteLength;const B=O0(T,P,F,o,a,I);s.push(B),c+=B.byteLength,n==null||n(_+1,f,b),_%4===3&&await N0();}for(const _ of s)i.push(Es(_));const m=F0(t.length,c,l);i.push(Es(m));const g=new Blob(i,{type:"application/zip"});return Ie.info("Zip stream closed."),ns(g,e),g}var el={exports:{}},V0=el.exports,Oh;function z0(){return Oh||(Oh=1,(function(e,t){(function(n,r){e.exports=r();})(V0,function(){var n=function(u,p){return (n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,w){y.__proto__=w;}||function(y,w){for(var S in w)Object.prototype.hasOwnProperty.call(w,S)&&(y[S]=w[S]);})(u,p)},r=function(){return (r=Object.assign||function(u){for(var p,y=1,w=arguments.length;y<w;y++)for(var S in p=arguments[y])Object.prototype.hasOwnProperty.call(p,S)&&(u[S]=p[S]);return u}).apply(this,arguments)};function o(u,p,y){for(var w,S=0,A=p.length;S<A;S++)!w&&S in p||((w=w||Array.prototype.slice.call(p,0,S))[S]=p[S]);return u.concat(w||Array.prototype.slice.call(p))}var a=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:qb,i=Object.keys,s=Array.isArray;function l(u,p){return typeof p!="object"||i(p).forEach(function(y){u[y]=p[y];}),u}typeof Promise>"u"||a.Promise||(a.Promise=Promise);var c=Object.getPrototypeOf,h={}.hasOwnProperty;function f(u,p){return h.call(u,p)}function m(u,p){typeof p=="function"&&(p=p(c(u))),(typeof Reflect>"u"?i:Reflect.ownKeys)(p).forEach(function(y){_(u,y,p[y]);});}var g=Object.defineProperty;function _(u,p,y,w){g(u,p,l(y&&f(y,"get")&&typeof y.get=="function"?{get:y.get,set:y.set,configurable:true}:{value:y,configurable:true,writable:true},w));}function b(u){return {from:function(p){return u.prototype=Object.create(p.prototype),_(u.prototype,"constructor",u),{extend:m.bind(null,u.prototype)}}}}var C=Object.getOwnPropertyDescriptor,k=[].slice;function T(u,p,y){return k.call(u,p,y)}function M(u,p){return p(u)}function P(u){if(!u)throw new Error("Assertion Failed")}function F(u){a.setImmediate?setImmediate(u):setTimeout(u,0);}function I(u,p){if(typeof p=="string"&&f(u,p))return u[p];if(!p)return u;if(typeof p!="string"){for(var y=[],w=0,S=p.length;w<S;++w){var A=I(u,p[w]);y.push(A);}return y}var N=p.indexOf(".");if(N!==-1){var H=u[p.substr(0,N)];return H==null?void 0:I(H,p.substr(N+1))}}function O(u,p,y){if(u&&p!==void 0&&!("isFrozen"in Object&&Object.isFrozen(u)))if(typeof p!="string"&&"length"in p){P(typeof y!="string"&&"length"in y);for(var w=0,S=p.length;w<S;++w)O(u,p[w],y[w]);}else {var A,N,H=p.indexOf(".");H!==-1?(A=p.substr(0,H),(N=p.substr(H+1))===""?y===void 0?s(u)&&!isNaN(parseInt(A))?u.splice(A,1):delete u[A]:u[A]=y:O(H=!(H=u[A])||!f(u,A)?u[A]={}:H,N,y)):y===void 0?s(u)&&!isNaN(parseInt(p))?u.splice(p,1):delete u[p]:u[p]=y;}}function B(u){var p,y={};for(p in u)f(u,p)&&(y[p]=u[p]);return y}var D=[].concat;function v(u){return D.apply([],u)}var it="BigUint64Array,BigInt64Array,Array,Boolean,String,Date,RegExp,Blob,File,FileList,FileSystemFileHandle,FileSystemDirectoryHandle,ArrayBuffer,DataView,Uint8ClampedArray,ImageBitmap,ImageData,Map,Set,CryptoKey".split(",").concat(v([8,16,32,64].map(function(u){return ["Int","Uint","Float"].map(function(p){return p+u+"Array"})}))).filter(function(u){return a[u]}),L=new Set(it.map(function(u){return a[u]})),$=null;function Me(u){return $=new WeakMap,u=(function p(y){if(!y||typeof y!="object")return y;var w=$.get(y);if(w)return w;if(s(y)){w=[],$.set(y,w);for(var S=0,A=y.length;S<A;++S)w.push(p(y[S]));}else if(L.has(y.constructor))w=y;else {var N,H=c(y);for(N in w=H===Object.prototype?{}:Object.create(H),$.set(y,w),y)f(y,N)&&(w[N]=p(y[N]));}return w})(u),$=null,u}var Z={}.toString;function re(u){return Z.call(u).slice(8,-1)}var J=typeof Symbol<"u"?Symbol.iterator:"@@iterator",le=typeof J=="symbol"?function(u){var p;return u!=null&&(p=u[J])&&p.apply(u)}:function(){return null};function he(u,p){return p=u.indexOf(p),0<=p&&u.splice(p,1),0<=p}var pe={};function ge(u){var p,y,w,S;if(arguments.length===1){if(s(u))return u.slice();if(this===pe&&typeof u=="string")return [u];if(S=le(u)){for(y=[];!(w=S.next()).done;)y.push(w.value);return y}if(u==null)return [u];if(typeof(p=u.length)!="number")return [u];for(y=new Array(p);p--;)y[p]=u[p];return y}for(p=arguments.length,y=new Array(p);p--;)y[p]=arguments[p];return y}var z=typeof Symbol<"u"?function(u){return u[Symbol.toStringTag]==="AsyncFunction"}:function(){return  false},ht=["Unknown","Constraint","Data","TransactionInactive","ReadOnly","Version","NotFound","InvalidState","InvalidAccess","Abort","Timeout","QuotaExceeded","Syntax","DataClone"],yr=["Modify","Bulk","OpenFailed","VersionChange","Schema","Upgrade","InvalidTable","MissingAPI","NoSuchDatabase","InvalidArgument","SubTransaction","Unsupported","Internal","DatabaseClosed","PrematureCommit","ForeignAwait"].concat(ht),ue={VersionChanged:"Database version changed by other database connection",DatabaseClosed:"Database has been closed",Abort:"Transaction aborted",TransactionInactive:"Transaction has already completed or failed",MissingAPI:"IndexedDB API missing. Please visit https://tinyurl.com/y2uuvskb"};function Pe(u,p){this.name=u,this.message=p;}function ce(u,p){return u+". Errors: "+Object.keys(p).map(function(y){return p[y].toString()}).filter(function(y,w,S){return S.indexOf(y)===w}).join(`
`)}function Ee(u,p,y,w){this.failures=p,this.failedKeys=w,this.successCount=y,this.message=ce(u,p);}function Qe(u,p){this.name="BulkError",this.failures=Object.keys(p).map(function(y){return p[y]}),this.failuresByPos=p,this.message=ce(u,this.failures);}b(Pe).from(Error).extend({toString:function(){return this.name+": "+this.message}}),b(Ee).from(Pe),b(Qe).from(Pe);var X=yr.reduce(function(u,p){return u[p]=p+"Error",u},{}),ne=Pe,j=yr.reduce(function(u,p){var y=p+"Error";function w(S,A){this.name=y,S?typeof S=="string"?(this.message="".concat(S).concat(A?`
 `+A:""),this.inner=A||null):typeof S=="object"&&(this.message="".concat(S.name," ").concat(S.message),this.inner=S):(this.message=ue[p]||y,this.inner=null);}return b(w).from(ne),u[p]=w,u},{});j.Syntax=SyntaxError,j.Type=TypeError,j.Range=RangeError;var se=ht.reduce(function(u,p){return u[p+"Error"]=j[p],u},{}),_e=yr.reduce(function(u,p){return ["Syntax","Type","Range"].indexOf(p)===-1&&(u[p+"Error"]=j[p]),u},{});function we(){}function Ye(u){return u}function We(u,p){return u==null||u===Ye?p:function(y){return p(u(y))}}function Se(u,p){return function(){u.apply(this,arguments),p.apply(this,arguments);}}function Tt(u,p){return u===we?p:function(){var y=u.apply(this,arguments);y!==void 0&&(arguments[0]=y);var w=this.onsuccess,S=this.onerror;this.onsuccess=null,this.onerror=null;var A=p.apply(this,arguments);return w&&(this.onsuccess=this.onsuccess?Se(w,this.onsuccess):w),S&&(this.onerror=this.onerror?Se(S,this.onerror):S),A!==void 0?A:y}}function jt(u,p){return u===we?p:function(){u.apply(this,arguments);var y=this.onsuccess,w=this.onerror;this.onsuccess=this.onerror=null,p.apply(this,arguments),y&&(this.onsuccess=this.onsuccess?Se(y,this.onsuccess):y),w&&(this.onerror=this.onerror?Se(w,this.onerror):w);}}function Wt(u,p){return u===we?p:function(y){var w=u.apply(this,arguments);l(y,w);var S=this.onsuccess,A=this.onerror;return this.onsuccess=null,this.onerror=null,y=p.apply(this,arguments),S&&(this.onsuccess=this.onsuccess?Se(S,this.onsuccess):S),A&&(this.onerror=this.onerror?Se(A,this.onerror):A),w===void 0?y===void 0?void 0:y:l(w,y)}}function Gt(u,p){return u===we?p:function(){return p.apply(this,arguments)!==false&&u.apply(this,arguments)}}function Rt(u,p){return u===we?p:function(){var y=u.apply(this,arguments);if(y&&typeof y.then=="function"){for(var w=this,S=arguments.length,A=new Array(S);S--;)A[S]=arguments[S];return y.then(function(){return p.apply(w,A)})}return p.apply(this,arguments)}}_e.ModifyError=Ee,_e.DexieError=Pe,_e.BulkError=Qe;var et=typeof location<"u"&&/^(http|https):\/\/(localhost|127\.0\.0\.1)/.test(location.href);function at(u){et=u;}var wt={},Ce=100,it=typeof Promise>"u"?[]:(function(){var u=Promise.resolve();if(typeof crypto>"u"||!crypto.subtle)return [u,c(u),u];var p=crypto.subtle.digest("SHA-512",new Uint8Array([0]));return [p,c(p),u]})(),ht=it[0],yr=it[1],it=it[2],yr=yr&&yr.then,yt=ht&&ht.constructor,Oe=!!it,ke=function(u,p){Le.push([u,p]),x&&(queueMicrotask(ze),x=false);},E=true,x=true,R=[],U=[],V=Ye,be={id:"global",global:true,ref:0,unhandleds:[],onunhandled:we,pgp:false,env:{},finalize:we},ie=be,Le=[],Ne=0,tt=[];function fe(u){if(typeof this!="object")throw new TypeError("Promises must be constructed via new");this._listeners=[],this._lib=false;var p=this._PSD=ie;if(typeof u!="function"){if(u!==wt)throw new TypeError("Not a function");return this._state=arguments[1],this._value=arguments[2],void(this._state===false&&St(this,this._value))}this._state=null,this._value=null,++p.ref,(function y(w,S){try{S(function(A){if(w._state===null){if(A===w)throw new TypeError("A promise cannot be resolved with itself.");var N=w._lib&&Dt();A&&typeof A.then=="function"?y(w,function(H,W){A instanceof fe?A._then(H,W):A.then(H,W);}):(w._state=!0,w._value=A,vt(w)),N&&Re();}},St.bind(null,w));}catch(A){St(w,A);}})(this,u);}var Ve={get:function(){var u=ie,p=Ae;function y(w,S){var A=this,N=!u.global&&(u!==ie||p!==Ae),H=N&&!Mt(),W=new fe(function(Y,te){Yt(A,new pt(In(w,u,N,H),In(S,u,N,H),Y,te,u));});return this._consoleTask&&(W._consoleTask=this._consoleTask),W}return y.prototype=wt,y},set:function(u){_(this,"then",u&&u.prototype===wt?Ve:{get:function(){return u},set:Ve.set});}};function pt(u,p,y,w,S){this.onFulfilled=typeof u=="function"?u:null,this.onRejected=typeof p=="function"?p:null,this.resolve=y,this.reject=w,this.psd=S;}function St(u,p){var y,w;U.push(p),u._state===null&&(y=u._lib&&Dt(),p=V(p),u._state=false,u._value=p,w=u,R.some(function(S){return S._value===w._value})||R.push(w),vt(u),y&&Re());}function vt(u){var p=u._listeners;u._listeners=[];for(var y=0,w=p.length;y<w;++y)Yt(u,p[y]);var S=u._PSD;--S.ref||S.finalize(),Ne===0&&(++Ne,ke(function(){--Ne==0&&Fe();},[]));}function Yt(u,p){if(u._state!==null){var y=u._state?p.onFulfilled:p.onRejected;if(y===null)return (u._state?p.resolve:p.reject)(u._value);++p.psd.ref,++Ne,ke(K,[y,u,p]);}else u._listeners.push(p);}function K(u,p,y){try{var w,S=p._value;!p._state&&U.length&&(U=[]),w=et&&p._consoleTask?p._consoleTask.run(function(){return u(S)}):u(S),p._state||U.indexOf(S)!==-1||(function(A){for(var N=R.length;N;)if(R[--N]._value===A._value)return R.splice(N,1)})(p),y.resolve(w);}catch(A){y.reject(A);}finally{--Ne==0&&Fe(),--y.psd.ref||y.psd.finalize();}}function ze(){Qt(be,function(){Dt()&&Re();});}function Dt(){var u=E;return x=E=false,u}function Re(){var u,p,y;do for(;0<Le.length;)for(u=Le,Le=[],y=u.length,p=0;p<y;++p){var w=u[p];w[0].apply(null,w[1]);}while(0<Le.length);x=E=true;}function Fe(){var u=R;R=[],u.forEach(function(w){w._PSD.onunhandled.call(null,w._value,w);});for(var p=tt.slice(0),y=p.length;y;)p[--y]();}function rt(u){return new fe(wt,false,u)}function Ue(u,p){var y=ie;return function(){var w=Dt(),S=ie;try{return ft(y,!0),u.apply(this,arguments)}catch(A){p&&p(A);}finally{ft(S,false),w&&Re();}}}m(fe.prototype,{then:Ve,_then:function(u,p){Yt(this,new pt(null,null,u,p,ie));},catch:function(u){if(arguments.length===1)return this.then(null,u);var p=u,y=arguments[1];return typeof p=="function"?this.then(null,function(w){return (w instanceof p?y:rt)(w)}):this.then(null,function(w){return (w&&w.name===p?y:rt)(w)})},finally:function(u){return this.then(function(p){return fe.resolve(u()).then(function(){return p})},function(p){return fe.resolve(u()).then(function(){return rt(p)})})},timeout:function(u,p){var y=this;return u<1/0?new fe(function(w,S){var A=setTimeout(function(){return S(new j.Timeout(p))},u);y.then(w,S).finally(clearTimeout.bind(null,A));}):this}}),typeof Symbol<"u"&&Symbol.toStringTag&&_(fe.prototype,Symbol.toStringTag,"Dexie.Promise"),be.env=Xt(),m(fe,{all:function(){var u=ge.apply(null,arguments).map(lt);return new fe(function(p,y){u.length===0&&p([]);var w=u.length;u.forEach(function(S,A){return fe.resolve(S).then(function(N){u[A]=N,--w||p(u);},y)});})},resolve:function(u){return u instanceof fe?u:u&&typeof u.then=="function"?new fe(function(p,y){u.then(p,y);}):new fe(wt,true,u)},reject:rt,race:function(){var u=ge.apply(null,arguments).map(lt);return new fe(function(p,y){u.map(function(w){return fe.resolve(w).then(p,y)});})},PSD:{get:function(){return ie},set:function(u){return ie=u}},totalEchoes:{get:function(){return Ae}},newPSD:nt,usePSD:Qt,scheduler:{get:function(){return ke},set:function(u){ke=u;}},rejectionMapper:{get:function(){return V},set:function(u){V=u;}},follow:function(u,p){return new fe(function(y,w){return nt(function(S,A){var N=ie;N.unhandleds=[],N.onunhandled=A,N.finalize=Se(function(){var H,W=this;H=function(){W.unhandleds.length===0?S():A(W.unhandleds[0]);},tt.push(function Y(){H(),tt.splice(tt.indexOf(Y),1);}),++Ne,ke(function(){--Ne==0&&Fe();},[]);},N.finalize),u();},p,y,w)})}}),yt&&(yt.allSettled&&_(fe,"allSettled",function(){var u=ge.apply(null,arguments).map(lt);return new fe(function(p){u.length===0&&p([]);var y=u.length,w=new Array(y);u.forEach(function(S,A){return fe.resolve(S).then(function(N){return w[A]={status:"fulfilled",value:N}},function(N){return w[A]={status:"rejected",reason:N}}).then(function(){return --y||p(w)})});})}),yt.any&&typeof AggregateError<"u"&&_(fe,"any",function(){var u=ge.apply(null,arguments).map(lt);return new fe(function(p,y){u.length===0&&y(new AggregateError([]));var w=u.length,S=new Array(w);u.forEach(function(A,N){return fe.resolve(A).then(function(H){return p(H)},function(H){S[N]=H,--w||y(new AggregateError(S));})});})}),yt.withResolvers&&(fe.withResolvers=yt.withResolvers));var st={awaits:0,echoes:0,id:0},Ut=0,ln=[],Te=0,Ae=0,At=0;function nt(u,p,y,w){var S=ie,A=Object.create(S);return A.parent=S,A.ref=0,A.global=false,A.id=++At,be.env,A.env=Oe?{Promise:fe,PromiseProp:{value:fe,configurable:true,writable:true},all:fe.all,race:fe.race,allSettled:fe.allSettled,any:fe.any,resolve:fe.resolve,reject:fe.reject}:{},p&&l(A,p),++S.ref,A.finalize=function(){--this.parent.ref||this.parent.finalize();},w=Qt(A,u,y,w),A.ref===0&&A.finalize(),w}function Lt(){return st.id||(st.id=++Ut),++st.awaits,st.echoes+=Ce,st.id}function Mt(){return !!st.awaits&&(--st.awaits==0&&(st.id=0),st.echoes=st.awaits*Ce,true)}function lt(u){return st.echoes&&u&&u.constructor===yt?(Lt(),u.then(function(p){return Mt(),p},function(p){return Mt(),Vt(p)})):u}function kt(){var u=ln[ln.length-1];ln.pop(),ft(u,false);}function ft(u,p){var y,w=ie;(p?!st.echoes||Te++&&u===ie:!Te||--Te&&u===ie)||queueMicrotask(p?(function(S){++Ae,st.echoes&&--st.echoes!=0||(st.echoes=st.awaits=st.id=0),ln.push(ie),ft(S,true);}).bind(null,u):kt),u!==ie&&(ie=u,w===be&&(be.env=Xt()),Oe&&(y=be.env.Promise,p=u.env,(w.global||u.global)&&(Object.defineProperty(a,"Promise",p.PromiseProp),y.all=p.all,y.race=p.race,y.resolve=p.resolve,y.reject=p.reject,p.allSettled&&(y.allSettled=p.allSettled),p.any&&(y.any=p.any))));}function Xt(){var u=a.Promise;return Oe?{Promise:u,PromiseProp:Object.getOwnPropertyDescriptor(a,"Promise"),all:u.all,race:u.race,allSettled:u.allSettled,any:u.any,resolve:u.resolve,reject:u.reject}:{}}function Qt(u,p,y,w,S){var A=ie;try{return ft(u,!0),p(y,w,S)}finally{ft(A,false);}}function In(u,p,y,w){return typeof u!="function"?u:function(){var S=ie;y&&Lt(),ft(p,true);try{return u.apply(this,arguments)}finally{ft(S,false),w&&queueMicrotask(Mt);}}}function mn(u){Promise===yt&&st.echoes===0?Te===0?u():enqueueNativeMicroTask(u):setTimeout(u,0);}(""+yr).indexOf("[native code]")===-1&&(Lt=Mt=we);var Vt=fe.reject,dn="￿",nn="Invalid key provided. Keys must be of type string, number, Date or Array<string | number | Date>.",en="String expected.",kn=[],xn="__dbnames",Br="readonly",Qr="readwrite";function mr(u,p){return u?p?function(){return u.apply(this,arguments)&&p.apply(this,arguments)}:u:p}var po={type:3,lower:-1/0,lowerOpen:false,upper:[[]],upperOpen:false};function ka(u){return typeof u!="string"||/\./.test(u)?function(p){return p}:function(p){return p[u]===void 0&&u in p&&delete(p=Me(p))[u],p}}function fs(){throw j.Type()}function Et(u,p){try{var y=li(u),w=li(p);if(y!==w)return y==="Array"?1:w==="Array"?-1:y==="binary"?1:w==="binary"?-1:y==="string"?1:w==="string"?-1:y==="Date"?1:w!=="Date"?NaN:-1;switch(y){case "number":case "Date":case "string":return p<u?1:u<p?-1:0;case "binary":return (function(S,A){for(var N=S.length,H=A.length,W=N<H?N:H,Y=0;Y<W;++Y)if(S[Y]!==A[Y])return S[Y]<A[Y]?-1:1;return N===H?0:N<H?-1:1})(xa(u),xa(p));case "Array":return (function(S,A){for(var N=S.length,H=A.length,W=N<H?N:H,Y=0;Y<W;++Y){var te=Et(S[Y],A[Y]);if(te!==0)return te}return N===H?0:N<H?-1:1})(u,p)}}catch{}return NaN}function li(u){var p=typeof u;return p!="object"?p:ArrayBuffer.isView(u)?"binary":(u=re(u),u==="ArrayBuffer"?"binary":u)}function xa(u){return u instanceof Uint8Array?u:ArrayBuffer.isView(u)?new Uint8Array(u.buffer,u.byteOffset,u.byteLength):new Uint8Array(u)}var cn=(Ct.prototype._trans=function(u,p,y){var w=this._tx||ie.trans,S=this.name,A=et&&typeof console<"u"&&console.createTask&&console.createTask("Dexie: ".concat(u==="readonly"?"read":"write"," ").concat(this.name));function N(Y,te,q){if(!q.schema[S])throw new j.NotFound("Table "+S+" not part of transaction");return p(q.idbtrans,q)}var H=Dt();try{var W=w&&w.db._novip===this.db._novip?w===ie.trans?w._promise(u,N,y):nt(function(){return w._promise(u,N,y)},{trans:w,transless:ie.transless||ie}):(function Y(te,q,ae,G){if(te.idbdb&&(te._state.openComplete||ie.letThrough||te._vip)){var ee=te._createTransaction(q,ae,te._dbSchema);try{ee.create(),te._state.PR1398_maxLoop=3;}catch(oe){return oe.name===X.InvalidState&&te.isOpen()&&0<--te._state.PR1398_maxLoop?(console.warn("Dexie: Need to reopen db"),te.close({disableAutoOpen:!1}),te.open().then(function(){return Y(te,q,ae,G)})):Vt(oe)}return ee._promise(q,function(oe,Q){return nt(function(){return ie.trans=ee,G(oe,Q,ee)})}).then(function(oe){if(q==="readwrite")try{ee.idbtrans.commit();}catch{}return q==="readonly"?oe:ee._completion.then(function(){return oe})})}if(te._state.openComplete)return Vt(new j.DatabaseClosed(te._state.dbOpenError));if(!te._state.isBeingOpened){if(!te._state.autoOpen)return Vt(new j.DatabaseClosed);te.open().catch(we);}return te._state.dbReadyPromise.then(function(){return Y(te,q,ae,G)})})(this.db,u,[this.name],N);return A&&(W._consoleTask=A,W=W.catch(function(Y){return console.trace(Y),Vt(Y)})),W}finally{H&&Re();}},Ct.prototype.get=function(u,p){var y=this;return u&&u.constructor===Object?this.where(u).first(p):u==null?Vt(new j.Type("Invalid argument to Table.get()")):this._trans("readonly",function(w){return y.core.get({trans:w,key:u}).then(function(S){return y.hook.reading.fire(S)})}).then(p)},Ct.prototype.where=function(u){if(typeof u=="string")return new this.db.WhereClause(this,u);if(s(u))return new this.db.WhereClause(this,"[".concat(u.join("+"),"]"));var p=i(u);if(p.length===1)return this.where(p[0]).equals(u[p[0]]);var y=this.schema.indexes.concat(this.schema.primKey).filter(function(H){if(H.compound&&p.every(function(Y){return 0<=H.keyPath.indexOf(Y)})){for(var W=0;W<p.length;++W)if(p.indexOf(H.keyPath[W])===-1)return  false;return  true}return  false}).sort(function(H,W){return H.keyPath.length-W.keyPath.length})[0];if(y&&this.db._maxKey!==dn){var A=y.keyPath.slice(0,p.length);return this.where(A).equals(A.map(function(W){return u[W]}))}!y&&et&&console.warn("The query ".concat(JSON.stringify(u)," on ").concat(this.name," would benefit from a ")+"compound index [".concat(p.join("+"),"]"));var w=this.schema.idxByName;function S(H,W){return Et(H,W)===0}var N=p.reduce(function(q,W){var Y=q[0],te=q[1],q=w[W],ae=u[W];return [Y||q,Y||!q?mr(te,q&&q.multi?function(G){return G=I(G,W),s(G)&&G.some(function(ee){return S(ae,ee)})}:function(G){return S(ae,I(G,W))}):te]},[null,null]),A=N[0],N=N[1];return A?this.where(A.name).equals(u[A.keyPath]).filter(N):y?this.filter(N):this.where(p).equals("")},Ct.prototype.filter=function(u){return this.toCollection().and(u)},Ct.prototype.count=function(u){return this.toCollection().count(u)},Ct.prototype.offset=function(u){return this.toCollection().offset(u)},Ct.prototype.limit=function(u){return this.toCollection().limit(u)},Ct.prototype.each=function(u){return this.toCollection().each(u)},Ct.prototype.toArray=function(u){return this.toCollection().toArray(u)},Ct.prototype.toCollection=function(){return new this.db.Collection(new this.db.WhereClause(this))},Ct.prototype.orderBy=function(u){return new this.db.Collection(new this.db.WhereClause(this,s(u)?"[".concat(u.join("+"),"]"):u))},Ct.prototype.reverse=function(){return this.toCollection().reverse()},Ct.prototype.mapToClass=function(u){var p,y=this.db,w=this.name;function S(){return p!==null&&p.apply(this,arguments)||this}(this.schema.mappedClass=u).prototype instanceof fs&&((function(W,Y){if(typeof Y!="function"&&Y!==null)throw new TypeError("Class extends value "+String(Y)+" is not a constructor or null");function te(){this.constructor=W;}n(W,Y),W.prototype=Y===null?Object.create(Y):(te.prototype=Y.prototype,new te);})(S,p=u),Object.defineProperty(S.prototype,"db",{get:function(){return y},enumerable:false,configurable:true}),S.prototype.table=function(){return w},u=S);for(var A=new Set,N=u.prototype;N;N=c(N))Object.getOwnPropertyNames(N).forEach(function(W){return A.add(W)});function H(W){if(!W)return W;var Y,te=Object.create(u.prototype);for(Y in W)if(!A.has(Y))try{te[Y]=W[Y];}catch{}return te}return this.schema.readHook&&this.hook.reading.unsubscribe(this.schema.readHook),this.schema.readHook=H,this.hook("reading",H),u},Ct.prototype.defineClass=function(){return this.mapToClass(function(u){l(this,u);})},Ct.prototype.add=function(u,p){var y=this,w=this.schema.primKey,S=w.auto,A=w.keyPath,N=u;return A&&S&&(N=ka(A)(u)),this._trans("readwrite",function(H){return y.core.mutate({trans:H,type:"add",keys:p!=null?[p]:null,values:[N]})}).then(function(H){return H.numFailures?fe.reject(H.failures[0]):H.lastResult}).then(function(H){if(A)try{O(u,A,H);}catch{}return H})},Ct.prototype.update=function(u,p){return typeof u!="object"||s(u)?this.where(":id").equals(u).modify(p):(u=I(u,this.schema.primKey.keyPath),u===void 0?Vt(new j.InvalidArgument("Given object does not contain its primary key")):this.where(":id").equals(u).modify(p))},Ct.prototype.put=function(u,p){var y=this,w=this.schema.primKey,S=w.auto,A=w.keyPath,N=u;return A&&S&&(N=ka(A)(u)),this._trans("readwrite",function(H){return y.core.mutate({trans:H,type:"put",values:[N],keys:p!=null?[p]:null})}).then(function(H){return H.numFailures?fe.reject(H.failures[0]):H.lastResult}).then(function(H){if(A)try{O(u,A,H);}catch{}return H})},Ct.prototype.delete=function(u){var p=this;return this._trans("readwrite",function(y){return p.core.mutate({trans:y,type:"delete",keys:[u]})}).then(function(y){return y.numFailures?fe.reject(y.failures[0]):void 0})},Ct.prototype.clear=function(){var u=this;return this._trans("readwrite",function(p){return u.core.mutate({trans:p,type:"deleteRange",range:po})}).then(function(p){return p.numFailures?fe.reject(p.failures[0]):void 0})},Ct.prototype.bulkGet=function(u){var p=this;return this._trans("readonly",function(y){return p.core.getMany({keys:u,trans:y}).then(function(w){return w.map(function(S){return p.hook.reading.fire(S)})})})},Ct.prototype.bulkAdd=function(u,p,y){var w=this,S=Array.isArray(p)?p:void 0,A=(y=y||(S?void 0:p))?y.allKeys:void 0;return this._trans("readwrite",function(N){var Y=w.schema.primKey,H=Y.auto,Y=Y.keyPath;if(Y&&S)throw new j.InvalidArgument("bulkAdd(): keys argument invalid on tables with inbound keys");if(S&&S.length!==u.length)throw new j.InvalidArgument("Arguments objects and keys must have the same length");var W=u.length,Y=Y&&H?u.map(ka(Y)):u;return w.core.mutate({trans:N,type:"add",keys:S,values:Y,wantResults:A}).then(function(ee){var q=ee.numFailures,ae=ee.results,G=ee.lastResult,ee=ee.failures;if(q===0)return A?ae:G;throw new Qe("".concat(w.name,".bulkAdd(): ").concat(q," of ").concat(W," operations failed"),ee)})})},Ct.prototype.bulkPut=function(u,p,y){var w=this,S=Array.isArray(p)?p:void 0,A=(y=y||(S?void 0:p))?y.allKeys:void 0;return this._trans("readwrite",function(N){var Y=w.schema.primKey,H=Y.auto,Y=Y.keyPath;if(Y&&S)throw new j.InvalidArgument("bulkPut(): keys argument invalid on tables with inbound keys");if(S&&S.length!==u.length)throw new j.InvalidArgument("Arguments objects and keys must have the same length");var W=u.length,Y=Y&&H?u.map(ka(Y)):u;return w.core.mutate({trans:N,type:"put",keys:S,values:Y,wantResults:A}).then(function(ee){var q=ee.numFailures,ae=ee.results,G=ee.lastResult,ee=ee.failures;if(q===0)return A?ae:G;throw new Qe("".concat(w.name,".bulkPut(): ").concat(q," of ").concat(W," operations failed"),ee)})})},Ct.prototype.bulkUpdate=function(u){var p=this,y=this.core,w=u.map(function(N){return N.key}),S=u.map(function(N){return N.changes}),A=[];return this._trans("readwrite",function(N){return y.getMany({trans:N,keys:w,cache:"clone"}).then(function(H){var W=[],Y=[];u.forEach(function(q,ae){var G=q.key,ee=q.changes,oe=H[ae];if(oe){for(var Q=0,de=Object.keys(ee);Q<de.length;Q++){var me=de[Q],ye=ee[me];if(me===p.schema.primKey.keyPath){if(Et(ye,G)!==0)throw new j.Constraint("Cannot update primary key in bulkUpdate()")}else O(oe,me,ye);}A.push(ae),W.push(G),Y.push(oe);}});var te=W.length;return y.mutate({trans:N,type:"put",keys:W,values:Y,updates:{keys:w,changeSpecs:S}}).then(function(q){var ae=q.numFailures,G=q.failures;if(ae===0)return te;for(var ee=0,oe=Object.keys(G);ee<oe.length;ee++){var Q,de=oe[ee],me=A[Number(de)];me!=null&&(Q=G[de],delete G[de],G[me]=Q);}throw new Qe("".concat(p.name,".bulkUpdate(): ").concat(ae," of ").concat(te," operations failed"),G)})})})},Ct.prototype.bulkDelete=function(u){var p=this,y=u.length;return this._trans("readwrite",function(w){return p.core.mutate({trans:w,type:"delete",keys:u})}).then(function(N){var S=N.numFailures,A=N.lastResult,N=N.failures;if(S===0)return A;throw new Qe("".concat(p.name,".bulkDelete(): ").concat(S," of ").concat(y," operations failed"),N)})},Ct);function Ct(){}function Jr(u){function p(N,H){if(H){for(var W=arguments.length,Y=new Array(W-1);--W;)Y[W-1]=arguments[W];return y[N].subscribe.apply(null,Y),u}if(typeof N=="string")return y[N]}var y={};p.addEventType=A;for(var w=1,S=arguments.length;w<S;++w)A(arguments[w]);return p;function A(N,H,W){if(typeof N!="object"){var Y;H=H||Gt;var te={subscribers:[],fire:W=W||we,subscribe:function(q){te.subscribers.indexOf(q)===-1&&(te.subscribers.push(q),te.fire=H(te.fire,q));},unsubscribe:function(q){te.subscribers=te.subscribers.filter(function(ae){return ae!==q}),te.fire=te.subscribers.reduce(H,W);}};return y[N]=p[N]=te}i(Y=N).forEach(function(q){var ae=Y[q];if(s(ae))A(q,Y[q][0],Y[q][1]);else {if(ae!=="asap")throw new j.InvalidArgument("Invalid event config");var G=A(q,Ye,function(){for(var ee=arguments.length,oe=new Array(ee);ee--;)oe[ee]=arguments[ee];G.subscribers.forEach(function(Q){F(function(){Q.apply(null,oe);});});});}});}}function Cr(u,p){return b(p).from({prototype:u}),p}function cr(u,p){return !(u.filter||u.algorithm||u.or)&&(p?u.justLimit:!u.replayFilter)}function $n(u,p){u.filter=mr(u.filter,p);}function ci(u,p,y){var w=u.replayFilter;u.replayFilter=w?function(){return mr(w(),p())}:p,u.justLimit=y&&!w;}function Fn(u,p){if(u.isPrimKey)return p.primaryKey;var y=p.getIndexByKeyPath(u.index);if(!y)throw new j.Schema("KeyPath "+u.index+" on object store "+p.name+" is not indexed");return y}function ui(u,p,y){var w=Fn(u,p.schema);return p.openCursor({trans:y,values:!u.keysOnly,reverse:u.dir==="prev",unique:!!u.unique,query:{index:w,range:u.range}})}function Ur(u,p,y,w){var S=u.replayFilter?mr(u.filter,u.replayFilter()):u.filter;if(u.or){var A={},N=function(H,W,Y){var te,q;S&&!S(W,Y,function(ae){return W.stop(ae)},function(ae){return W.fail(ae)})||((q=""+(te=W.primaryKey))=="[object ArrayBuffer]"&&(q=""+new Uint8Array(te)),f(A,q)||(A[q]=true,p(H,W,Y)));};return Promise.all([u.or._iterate(N,y),di(ui(u,w,y),u.algorithm,N,!u.keysOnly&&u.valueMapper)])}return di(ui(u,w,y),mr(u.algorithm,S),p,!u.keysOnly&&u.valueMapper)}function di(u,p,y,w){var S=Ue(w?function(A,N,H){return y(w(A),N,H)}:y);return u.then(function(A){if(A)return A.start(function(){var N=function(){return A.continue()};p&&!p(A,function(H){return N=H},function(H){A.stop(H),N=we;},function(H){A.fail(H),N=we;})||S(A.value,A,function(H){return N=H}),N();})})}var ar=(mo.prototype.execute=function(u){var p=this["@@propmod"];if(p.add!==void 0){var y=p.add;if(s(y))return o(o([],s(u)?u:[],true),y).sort();if(typeof y=="number")return (Number(u)||0)+y;if(typeof y=="bigint")try{return BigInt(u)+y}catch{return BigInt(0)+y}throw new TypeError("Invalid term ".concat(y))}if(p.remove!==void 0){var w=p.remove;if(s(w))return s(u)?u.filter(function(S){return !w.includes(S)}).sort():[];if(typeof w=="number")return Number(u)-w;if(typeof w=="bigint")try{return BigInt(u)-w}catch{return BigInt(0)-w}throw new TypeError("Invalid subtrahend ".concat(w))}return y=(y=p.replacePrefix)===null||y===void 0?void 0:y[0],y&&typeof u=="string"&&u.startsWith(y)?p.replacePrefix[1]+u.substring(y.length):u},mo);function mo(u){this["@@propmod"]=u;}var go=(Zt.prototype._read=function(u,p){var y=this._ctx;return y.error?y.table._trans(null,Vt.bind(null,y.error)):y.table._trans("readonly",u).then(p)},Zt.prototype._write=function(u){var p=this._ctx;return p.error?p.table._trans(null,Vt.bind(null,p.error)):p.table._trans("readwrite",u,"locked")},Zt.prototype._addAlgorithm=function(u){var p=this._ctx;p.algorithm=mr(p.algorithm,u);},Zt.prototype._iterate=function(u,p){return Ur(this._ctx,u,p,this._ctx.table.core)},Zt.prototype.clone=function(u){var p=Object.create(this.constructor.prototype),y=Object.create(this._ctx);return u&&l(y,u),p._ctx=y,p},Zt.prototype.raw=function(){return this._ctx.valueMapper=null,this},Zt.prototype.each=function(u){var p=this._ctx;return this._read(function(y){return Ur(p,u,y,p.table.core)})},Zt.prototype.count=function(u){var p=this;return this._read(function(y){var w=p._ctx,S=w.table.core;if(cr(w,true))return S.count({trans:y,query:{index:Fn(w,S.schema),range:w.range}}).then(function(N){return Math.min(N,w.limit)});var A=0;return Ur(w,function(){return ++A,false},y,S).then(function(){return A})}).then(u)},Zt.prototype.sortBy=function(u,p){var y=u.split(".").reverse(),w=y[0],S=y.length-1;function A(W,Y){return Y?A(W[y[Y]],Y-1):W[w]}var N=this._ctx.dir==="next"?1:-1;function H(W,Y){return Et(A(W,S),A(Y,S))*N}return this.toArray(function(W){return W.sort(H)}).then(p)},Zt.prototype.toArray=function(u){var p=this;return this._read(function(y){var w=p._ctx;if(w.dir==="next"&&cr(w,true)&&0<w.limit){var S=w.valueMapper,A=Fn(w,w.table.core.schema);return w.table.core.query({trans:y,limit:w.limit,values:true,query:{index:A,range:w.range}}).then(function(H){return H=H.result,S?H.map(S):H})}var N=[];return Ur(w,function(H){return N.push(H)},y,w.table.core).then(function(){return N})},u)},Zt.prototype.offset=function(u){var p=this._ctx;return u<=0||(p.offset+=u,cr(p)?ci(p,function(){var y=u;return function(w,S){return y===0||(y===1?--y:S(function(){w.advance(y),y=0;}),false)}}):ci(p,function(){var y=u;return function(){return --y<0}})),this},Zt.prototype.limit=function(u){return this._ctx.limit=Math.min(this._ctx.limit,u),ci(this._ctx,function(){var p=u;return function(y,w,S){return --p<=0&&w(S),0<=p}},true),this},Zt.prototype.until=function(u,p){return $n(this._ctx,function(y,w,S){return !u(y.value)||(w(S),p)}),this},Zt.prototype.first=function(u){return this.limit(1).toArray(function(p){return p[0]}).then(u)},Zt.prototype.last=function(u){return this.reverse().first(u)},Zt.prototype.filter=function(u){var p;return $n(this._ctx,function(y){return u(y.value)}),(p=this._ctx).isMatch=mr(p.isMatch,u),this},Zt.prototype.and=function(u){return this.filter(u)},Zt.prototype.or=function(u){return new this.db.WhereClause(this._ctx.table,u,this)},Zt.prototype.reverse=function(){return this._ctx.dir=this._ctx.dir==="prev"?"next":"prev",this._ondirectionchange&&this._ondirectionchange(this._ctx.dir),this},Zt.prototype.desc=function(){return this.reverse()},Zt.prototype.eachKey=function(u){var p=this._ctx;return p.keysOnly=!p.isMatch,this.each(function(y,w){u(w.key,w);})},Zt.prototype.eachUniqueKey=function(u){return this._ctx.unique="unique",this.eachKey(u)},Zt.prototype.eachPrimaryKey=function(u){var p=this._ctx;return p.keysOnly=!p.isMatch,this.each(function(y,w){u(w.primaryKey,w);})},Zt.prototype.keys=function(u){var p=this._ctx;p.keysOnly=!p.isMatch;var y=[];return this.each(function(w,S){y.push(S.key);}).then(function(){return y}).then(u)},Zt.prototype.primaryKeys=function(u){var p=this._ctx;if(p.dir==="next"&&cr(p,true)&&0<p.limit)return this._read(function(w){var S=Fn(p,p.table.core.schema);return p.table.core.query({trans:w,values:false,limit:p.limit,query:{index:S,range:p.range}})}).then(function(w){return w.result}).then(u);p.keysOnly=!p.isMatch;var y=[];return this.each(function(w,S){y.push(S.primaryKey);}).then(function(){return y}).then(u)},Zt.prototype.uniqueKeys=function(u){return this._ctx.unique="unique",this.keys(u)},Zt.prototype.firstKey=function(u){return this.limit(1).keys(function(p){return p[0]}).then(u)},Zt.prototype.lastKey=function(u){return this.reverse().firstKey(u)},Zt.prototype.distinct=function(){var u=this._ctx,u=u.index&&u.table.schema.idxByName[u.index];if(!u||!u.multi)return this;var p={};return $n(this._ctx,function(S){var w=S.primaryKey.toString(),S=f(p,w);return p[w]=true,!S}),this},Zt.prototype.modify=function(u){var p=this,y=this._ctx;return this._write(function(w){var S,A,N;N=typeof u=="function"?u:(S=i(u),A=S.length,function(Q){for(var de=false,me=0;me<A;++me){var ye=S[me],xe=u[ye],$e=I(Q,ye);xe instanceof ar?(O(Q,ye,xe.execute($e)),de=true):$e!==xe&&(O(Q,ye,xe),de=true);}return de});var H=y.table.core,q=H.schema.primaryKey,W=q.outbound,Y=q.extractKey,te=200,q=p.db._options.modifyChunkSize;q&&(te=typeof q=="object"?q[H.name]||q["*"]||200:q);function ae(Q,ye){var me=ye.failures,ye=ye.numFailures;ee+=Q-ye;for(var xe=0,$e=i(me);xe<$e.length;xe++){var Ze=$e[xe];G.push(me[Ze]);}}var G=[],ee=0,oe=[];return p.clone().primaryKeys().then(function(Q){function de(ye){var xe=Math.min(te,Q.length-ye);return H.getMany({trans:w,keys:Q.slice(ye,ye+xe),cache:"immutable"}).then(function($e){for(var Ze=[],He=[],Ke=W?[]:null,ot=[],Xe=0;Xe<xe;++Xe){var mt=$e[Xe],qt={value:Me(mt),primKey:Q[ye+Xe]};N.call(qt,qt.value,qt)!==false&&(qt.value==null?ot.push(Q[ye+Xe]):W||Et(Y(mt),Y(qt.value))===0?(He.push(qt.value),W&&Ke.push(Q[ye+Xe])):(ot.push(Q[ye+Xe]),Ze.push(qt.value)));}return Promise.resolve(0<Ze.length&&H.mutate({trans:w,type:"add",values:Ze}).then(function(zt){for(var Kt in zt.failures)ot.splice(parseInt(Kt),1);ae(Ze.length,zt);})).then(function(){return (0<He.length||me&&typeof u=="object")&&H.mutate({trans:w,type:"put",keys:Ke,values:He,criteria:me,changeSpec:typeof u!="function"&&u,isAdditionalChunk:0<ye}).then(function(zt){return ae(He.length,zt)})}).then(function(){return (0<ot.length||me&&u===Ko)&&H.mutate({trans:w,type:"delete",keys:ot,criteria:me,isAdditionalChunk:0<ye}).then(function(zt){return ae(ot.length,zt)})}).then(function(){return Q.length>ye+xe&&de(ye+te)})})}var me=cr(y)&&y.limit===1/0&&(typeof u!="function"||u===Ko)&&{index:y.index,range:y.range};return de(0).then(function(){if(0<G.length)throw new Ee("Error modifying one or more objects",G,ee,oe);return Q.length})})})},Zt.prototype.delete=function(){var u=this._ctx,p=u.range;return cr(u)&&(u.isPrimKey||p.type===3)?this._write(function(y){var w=u.table.core.schema.primaryKey,S=p;return u.table.core.count({trans:y,query:{index:w,range:S}}).then(function(A){return u.table.core.mutate({trans:y,type:"deleteRange",range:S}).then(function(N){var H=N.failures;if(N.lastResult,N.results,N=N.numFailures,N)throw new Ee("Could not delete some values",Object.keys(H).map(function(W){return H[W]}),A-N);return A-N})})}):this.modify(Ko)},Zt);function Zt(){}var Ko=function(u,p){return p.value=null};function yo(u,p){return u<p?-1:u===p?0:1}function fi(u,p){return p<u?-1:u===p?0:1}function er(u,p,y){return u=u instanceof ps?new u.Collection(u):u,u._ctx.error=new(y||TypeError)(p),u}function eo(u){return new u.Collection(u,function(){return hs("")}).limit(0)}function Wo(u,p,y,w){var S,A,N,H,W,Y,te,q=y.length;if(!y.every(function(ee){return typeof ee=="string"}))return er(u,en);function ae(ee){S=ee==="next"?function(Q){return Q.toUpperCase()}:function(Q){return Q.toLowerCase()},A=ee==="next"?function(Q){return Q.toLowerCase()}:function(Q){return Q.toUpperCase()},N=ee==="next"?yo:fi;var oe=y.map(function(Q){return {lower:A(Q),upper:S(Q)}}).sort(function(Q,de){return N(Q.lower,de.lower)});H=oe.map(function(Q){return Q.upper}),W=oe.map(function(Q){return Q.lower}),te=(Y=ee)==="next"?"":w;}ae("next"),u=new u.Collection(u,function(){return Tr(H[0],W[q-1]+w)}),u._ondirectionchange=function(ee){ae(ee);};var G=0;return u._addAlgorithm(function(ee,oe,Q){var de=ee.key;if(typeof de!="string")return  false;var me=A(de);if(p(me,W,G))return  true;for(var ye=null,xe=G;xe<q;++xe){var $e=(function(Ze,He,Ke,ot,Xe,mt){for(var qt=Math.min(Ze.length,ot.length),zt=-1,Kt=0;Kt<qt;++Kt){var dr=He[Kt];if(dr!==ot[Kt])return Xe(Ze[Kt],Ke[Kt])<0?Ze.substr(0,Kt)+Ke[Kt]+Ke.substr(Kt+1):Xe(Ze[Kt],ot[Kt])<0?Ze.substr(0,Kt)+ot[Kt]+Ke.substr(Kt+1):0<=zt?Ze.substr(0,zt)+He[zt]+Ke.substr(zt+1):null;Xe(Ze[Kt],dr)<0&&(zt=Kt);}return qt<ot.length&&mt==="next"?Ze+Ke.substr(Ze.length):qt<Ze.length&&mt==="prev"?Ze.substr(0,Ke.length):zt<0?null:Ze.substr(0,zt)+ot[zt]+Ke.substr(zt+1)})(de,me,H[xe],W[xe],N,Y);$e===null&&ye===null?G=xe+1:(ye===null||0<N(ye,$e))&&(ye=$e);}return oe(ye!==null?function(){ee.continue(ye+te);}:Q),false}),u}function Tr(u,p,y,w){return {type:2,lower:u,upper:p,lowerOpen:y,upperOpen:w}}function hs(u){return {type:1,lower:u,upper:u}}var ps=(Object.defineProperty(fn.prototype,"Collection",{get:function(){return this._ctx.table.db.Collection},enumerable:false,configurable:true}),fn.prototype.between=function(u,p,y,w){y=y!==false,w=w===true;try{return 0<this._cmp(u,p)||this._cmp(u,p)===0&&(y||w)&&(!y||!w)?eo(this):new this.Collection(this,function(){return Tr(u,p,!y,!w)})}catch{return er(this,nn)}},fn.prototype.equals=function(u){return u==null?er(this,nn):new this.Collection(this,function(){return hs(u)})},fn.prototype.above=function(u){return u==null?er(this,nn):new this.Collection(this,function(){return Tr(u,void 0,true)})},fn.prototype.aboveOrEqual=function(u){return u==null?er(this,nn):new this.Collection(this,function(){return Tr(u,void 0,false)})},fn.prototype.below=function(u){return u==null?er(this,nn):new this.Collection(this,function(){return Tr(void 0,u,false,true)})},fn.prototype.belowOrEqual=function(u){return u==null?er(this,nn):new this.Collection(this,function(){return Tr(void 0,u)})},fn.prototype.startsWith=function(u){return typeof u!="string"?er(this,en):this.between(u,u+dn,true,true)},fn.prototype.startsWithIgnoreCase=function(u){return u===""?this.startsWith(u):Wo(this,function(p,y){return p.indexOf(y[0])===0},[u],dn)},fn.prototype.equalsIgnoreCase=function(u){return Wo(this,function(p,y){return p===y[0]},[u],"")},fn.prototype.anyOfIgnoreCase=function(){var u=ge.apply(pe,arguments);return u.length===0?eo(this):Wo(this,function(p,y){return y.indexOf(p)!==-1},u,"")},fn.prototype.startsWithAnyOfIgnoreCase=function(){var u=ge.apply(pe,arguments);return u.length===0?eo(this):Wo(this,function(p,y){return y.some(function(w){return p.indexOf(w)===0})},u,dn)},fn.prototype.anyOf=function(){var u=this,p=ge.apply(pe,arguments),y=this._cmp;try{p.sort(y);}catch{return er(this,nn)}if(p.length===0)return eo(this);var w=new this.Collection(this,function(){return Tr(p[0],p[p.length-1])});w._ondirectionchange=function(A){y=A==="next"?u._ascending:u._descending,p.sort(y);};var S=0;return w._addAlgorithm(function(A,N,H){for(var W=A.key;0<y(W,p[S]);)if(++S===p.length)return N(H),false;return y(W,p[S])===0||(N(function(){A.continue(p[S]);}),false)}),w},fn.prototype.notEqual=function(u){return this.inAnyRange([[-1/0,u],[u,this.db._maxKey]],{includeLowers:false,includeUppers:false})},fn.prototype.noneOf=function(){var u=ge.apply(pe,arguments);if(u.length===0)return new this.Collection(this);try{u.sort(this._ascending);}catch{return er(this,nn)}var p=u.reduce(function(y,w){return y?y.concat([[y[y.length-1][1],w]]):[[-1/0,w]]},null);return p.push([u[u.length-1],this.db._maxKey]),this.inAnyRange(p,{includeLowers:false,includeUppers:false})},fn.prototype.inAnyRange=function(de,p){var y=this,w=this._cmp,S=this._ascending,A=this._descending,N=this._min,H=this._max;if(de.length===0)return eo(this);if(!de.every(function(me){return me[0]!==void 0&&me[1]!==void 0&&S(me[0],me[1])<=0}))return er(this,"First argument to inAnyRange() must be an Array of two-value Arrays [lower,upper] where upper must not be lower than lower",j.InvalidArgument);var W=!p||p.includeLowers!==false,Y=p&&p.includeUppers===true,te,q=S;function ae(me,ye){return q(me[0],ye[0])}try{(te=de.reduce(function(me,ye){for(var xe=0,$e=me.length;xe<$e;++xe){var Ze=me[xe];if(w(ye[0],Ze[1])<0&&0<w(ye[1],Ze[0])){Ze[0]=N(Ze[0],ye[0]),Ze[1]=H(Ze[1],ye[1]);break}}return xe===$e&&me.push(ye),me},[])).sort(ae);}catch{return er(this,nn)}var G=0,ee=Y?function(me){return 0<S(me,te[G][1])}:function(me){return 0<=S(me,te[G][1])},oe=W?function(me){return 0<A(me,te[G][0])}:function(me){return 0<=A(me,te[G][0])},Q=ee,de=new this.Collection(this,function(){return Tr(te[0][0],te[te.length-1][1],!W,!Y)});return de._ondirectionchange=function(me){q=me==="next"?(Q=ee,S):(Q=oe,A),te.sort(ae);},de._addAlgorithm(function(me,ye,xe){for(var $e,Ze=me.key;Q(Ze);)if(++G===te.length)return ye(xe),false;return !ee($e=Ze)&&!oe($e)||(y._cmp(Ze,te[G][1])===0||y._cmp(Ze,te[G][0])===0||ye(function(){q===S?me.continue(te[G][0]):me.continue(te[G][1]);}),false)}),de},fn.prototype.startsWithAnyOf=function(){var u=ge.apply(pe,arguments);return u.every(function(p){return typeof p=="string"})?u.length===0?eo(this):this.inAnyRange(u.map(function(p){return [p,p+dn]})):er(this,"startsWithAnyOf() only works with strings")},fn);function fn(){}function an(u){return Ue(function(p){return _o(p),u(p.target.error),false})}function _o(u){u.stopPropagation&&u.stopPropagation(),u.preventDefault&&u.preventDefault();}var Go="storagemutated",Yo="x-storagemutated-1",Vn=Jr(null,Go),ac=(ur.prototype._lock=function(){return P(!ie.global),++this._reculock,this._reculock!==1||ie.global||(ie.lockOwnerFor=this),this},ur.prototype._unlock=function(){if(P(!ie.global),--this._reculock==0)for(ie.global||(ie.lockOwnerFor=null);0<this._blockedFuncs.length&&!this._locked();){var u=this._blockedFuncs.shift();try{Qt(u[1],u[0]);}catch{}}return this},ur.prototype._locked=function(){return this._reculock&&ie.lockOwnerFor!==this},ur.prototype.create=function(u){var p=this;if(!this.mode)return this;var y=this.db.idbdb,w=this.db._state.dbOpenError;if(P(!this.idbtrans),!u&&!y)switch(w&&w.name){case "DatabaseClosedError":throw new j.DatabaseClosed(w);case "MissingAPIError":throw new j.MissingAPI(w.message,w);default:throw new j.OpenFailed(w)}if(!this.active)throw new j.TransactionInactive;return P(this._completion._state===null),(u=this.idbtrans=u||(this.db.core||y).transaction(this.storeNames,this.mode,{durability:this.chromeTransactionDurability})).onerror=Ue(function(S){_o(S),p._reject(u.error);}),u.onabort=Ue(function(S){_o(S),p.active&&p._reject(new j.Abort(u.error)),p.active=false,p.on("abort").fire(S);}),u.oncomplete=Ue(function(){p.active=false,p._resolve(),"mutatedParts"in u&&Vn.storagemutated.fire(u.mutatedParts);}),this},ur.prototype._promise=function(u,p,y){var w=this;if(u==="readwrite"&&this.mode!=="readwrite")return Vt(new j.ReadOnly("Transaction is readonly"));if(!this.active)return Vt(new j.TransactionInactive);if(this._locked())return new fe(function(A,N){w._blockedFuncs.push([function(){w._promise(u,p,y).then(A,N);},ie]);});if(y)return nt(function(){var A=new fe(function(N,H){w._lock();var W=p(N,H,w);W&&W.then&&W.then(N,H);});return A.finally(function(){return w._unlock()}),A._lib=true,A});var S=new fe(function(A,N){var H=p(A,N,w);H&&H.then&&H.then(A,N);});return S._lib=true,S},ur.prototype._root=function(){return this.parent?this.parent._root():this},ur.prototype.waitFor=function(u){var p,y=this._root(),w=fe.resolve(u);y._waitingFor?y._waitingFor=y._waitingFor.then(function(){return w}):(y._waitingFor=w,y._waitingQueue=[],p=y.idbtrans.objectStore(y.storeNames[0]),(function A(){for(++y._spinCount;y._waitingQueue.length;)y._waitingQueue.shift()();y._waitingFor&&(p.get(-1/0).onsuccess=A);})());var S=y._waitingFor;return new fe(function(A,N){w.then(function(H){return y._waitingQueue.push(Ue(A.bind(null,H)))},function(H){return y._waitingQueue.push(Ue(N.bind(null,H)))}).finally(function(){y._waitingFor===S&&(y._waitingFor=null);});})},ur.prototype.abort=function(){this.active&&(this.active=false,this.idbtrans&&this.idbtrans.abort(),this._reject(new j.Abort));},ur.prototype.table=function(u){var p=this._memoizedTables||(this._memoizedTables={});if(f(p,u))return p[u];var y=this.schema[u];if(!y)throw new j.NotFound("Table "+u+" not part of transaction");return y=new this.db.Table(u,y,this),y.core=this.db.core.table(u),p[u]=y},ur);function ur(){}function wo(u,p,y,w,S,A,N){return {name:u,keyPath:p,unique:y,multi:w,auto:S,compound:A,src:(y&&!N?"&":"")+(w?"*":"")+(S?"++":"")+hi(p)}}function hi(u){return typeof u=="string"?u:u?"["+[].join.call(u,"+")+"]":""}function pi(u,p,y){return {name:u,primKey:p,indexes:y,mappedClass:null,idxByName:(w=function(S){return [S.name,S]},y.reduce(function(S,A,N){return N=w(A,N),N&&(S[N[0]]=N[1]),S},{}))};var w;}var Xo=function(u){try{return u.only([[]]),Xo=function(){return [[]]},[[]]}catch{return Xo=function(){return dn},dn}};function Zo(u){return u==null?function(){}:typeof u=="string"?(p=u).split(".").length===1?function(y){return y[p]}:function(y){return I(y,p)}:function(y){return I(y,u)};var p;}function ve(u){return [].slice.call(u)}var bt=0;function Nt(u){return u==null?":id":typeof u=="string"?u:"[".concat(u.join("+"),"]")}function Mr(u,p,W){function w(Q){if(Q.type===3)return null;if(Q.type===4)throw new Error("Cannot convert never type to IDBKeyRange");var G=Q.lower,ee=Q.upper,oe=Q.lowerOpen,Q=Q.upperOpen;return G===void 0?ee===void 0?null:p.upperBound(ee,!!Q):ee===void 0?p.lowerBound(G,!!oe):p.bound(G,ee,!!oe,!!Q)}function S(ae){var G,ee=ae.name;return {name:ee,schema:ae,mutate:function(oe){var Q=oe.trans,de=oe.type,me=oe.keys,ye=oe.values,xe=oe.range;return new Promise(function($e,Ze){$e=Ue($e);var He=Q.objectStore(ee),Ke=He.keyPath==null,ot=de==="put"||de==="add";if(!ot&&de!=="delete"&&de!=="deleteRange")throw new Error("Invalid operation type: "+de);var Xe,mt=(me||ye||{length:1}).length;if(me&&ye&&me.length!==ye.length)throw new Error("Given keys array must have same length as given values array.");if(mt===0)return $e({numFailures:0,failures:{},results:[],lastResult:void 0});function qt(tr){++dr,_o(tr);}var zt=[],Kt=[],dr=0;if(de==="deleteRange"){if(xe.type===4)return $e({numFailures:dr,failures:Kt,results:[],lastResult:void 0});xe.type===3?zt.push(Xe=He.clear()):zt.push(Xe=He.delete(w(xe)));}else {var Ke=ot?Ke?[ye,me]:[ye,null]:[me,null],Ht=Ke[0],Xn=Ke[1];if(ot)for(var Zn=0;Zn<mt;++Zn)zt.push(Xe=Xn&&Xn[Zn]!==void 0?He[de](Ht[Zn],Xn[Zn]):He[de](Ht[Zn])),Xe.onerror=qt;else for(Zn=0;Zn<mt;++Zn)zt.push(Xe=He[de](Ht[Zn])),Xe.onerror=qt;}function xs(tr){tr=tr.target.result,zt.forEach(function(na,bc){return na.error!=null&&(Kt[bc]=na.error)}),$e({numFailures:dr,failures:Kt,results:de==="delete"?me:zt.map(function(na){return na.result}),lastResult:tr});}Xe.onerror=function(tr){qt(tr),xs(tr);},Xe.onsuccess=xs;})},getMany:function(oe){var Q=oe.trans,de=oe.keys;return new Promise(function(me,ye){me=Ue(me);for(var xe,$e=Q.objectStore(ee),Ze=de.length,He=new Array(Ze),Ke=0,ot=0,Xe=function(zt){zt=zt.target,He[zt._pos]=zt.result,++ot===Ke&&me(He);},mt=an(ye),qt=0;qt<Ze;++qt)de[qt]!=null&&((xe=$e.get(de[qt]))._pos=qt,xe.onsuccess=Xe,xe.onerror=mt,++Ke);Ke===0&&me(He);})},get:function(oe){var Q=oe.trans,de=oe.key;return new Promise(function(me,ye){me=Ue(me);var xe=Q.objectStore(ee).get(de);xe.onsuccess=function($e){return me($e.target.result)},xe.onerror=an(ye);})},query:(G=Y,function(oe){return new Promise(function(Q,de){Q=Ue(Q);var me,ye,xe,Ke=oe.trans,$e=oe.values,Ze=oe.limit,Xe=oe.query,He=Ze===1/0?void 0:Ze,ot=Xe.index,Xe=Xe.range,Ke=Ke.objectStore(ee),ot=ot.isPrimaryKey?Ke:Ke.index(ot.name),Xe=w(Xe);if(Ze===0)return Q({result:[]});G?((He=$e?ot.getAll(Xe,He):ot.getAllKeys(Xe,He)).onsuccess=function(mt){return Q({result:mt.target.result})},He.onerror=an(de)):(me=0,ye=!$e&&"openKeyCursor"in ot?ot.openKeyCursor(Xe):ot.openCursor(Xe),xe=[],ye.onsuccess=function(mt){var qt=ye.result;return qt?(xe.push($e?qt.value:qt.primaryKey),++me===Ze?Q({result:xe}):void qt.continue()):Q({result:xe})},ye.onerror=an(de));})}),openCursor:function(oe){var Q=oe.trans,de=oe.values,me=oe.query,ye=oe.reverse,xe=oe.unique;return new Promise(function($e,Ze){$e=Ue($e);var ot=me.index,He=me.range,Ke=Q.objectStore(ee),Ke=ot.isPrimaryKey?Ke:Ke.index(ot.name),ot=ye?xe?"prevunique":"prev":xe?"nextunique":"next",Xe=!de&&"openKeyCursor"in Ke?Ke.openKeyCursor(w(He),ot):Ke.openCursor(w(He),ot);Xe.onerror=an(Ze),Xe.onsuccess=Ue(function(mt){var qt,zt,Kt,dr,Ht=Xe.result;Ht?(Ht.___id=++bt,Ht.done=false,qt=Ht.continue.bind(Ht),zt=(zt=Ht.continuePrimaryKey)&&zt.bind(Ht),Kt=Ht.advance.bind(Ht),dr=function(){throw new Error("Cursor not stopped")},Ht.trans=Q,Ht.stop=Ht.continue=Ht.continuePrimaryKey=Ht.advance=function(){throw new Error("Cursor not started")},Ht.fail=Ue(Ze),Ht.next=function(){var Xn=this,Zn=1;return this.start(function(){return Zn--?Xn.continue():Xn.stop()}).then(function(){return Xn})},Ht.start=function(Xn){function Zn(){if(Xe.result)try{Xn();}catch(tr){Ht.fail(tr);}else Ht.done=true,Ht.start=function(){throw new Error("Cursor behind last entry")},Ht.stop();}var xs=new Promise(function(tr,na){tr=Ue(tr),Xe.onerror=an(na),Ht.fail=na,Ht.stop=function(bc){Ht.stop=Ht.continue=Ht.continuePrimaryKey=Ht.advance=dr,tr(bc);};});return Xe.onsuccess=Ue(function(tr){Xe.onsuccess=Zn,Zn();}),Ht.continue=qt,Ht.continuePrimaryKey=zt,Ht.advance=Kt,Zn(),xs},$e(Ht)):$e(null);},Ze);})},count:function(oe){var Q=oe.query,de=oe.trans,me=Q.index,ye=Q.range;return new Promise(function(xe,$e){var Ze=de.objectStore(ee),He=me.isPrimaryKey?Ze:Ze.index(me.name),Ze=w(ye),He=Ze?He.count(Ze):He.count();He.onsuccess=Ue(function(Ke){return xe(Ke.target.result)}),He.onerror=an($e);})}}}var A,N,H,te=(N=W,H=ve((A=u).objectStoreNames),{schema:{name:A.name,tables:H.map(function(ae){return N.objectStore(ae)}).map(function(ae){var G=ae.keyPath,Q=ae.autoIncrement,ee=s(G),oe={},Q={name:ae.name,primaryKey:{name:null,isPrimaryKey:true,outbound:G==null,compound:ee,keyPath:G,autoIncrement:Q,unique:true,extractKey:Zo(G)},indexes:ve(ae.indexNames).map(function(de){return ae.index(de)}).map(function(xe){var me=xe.name,ye=xe.unique,$e=xe.multiEntry,xe=xe.keyPath,$e={name:me,compound:s(xe),keyPath:xe,unique:ye,multiEntry:$e,extractKey:Zo(xe)};return oe[Nt(xe)]=$e}),getIndexByKeyPath:function(de){return oe[Nt(de)]}};return oe[":id"]=Q.primaryKey,G!=null&&(oe[Nt(G)]=Q.primaryKey),Q})},hasGetAll:0<H.length&&"getAll"in N.objectStore(H[0])&&!(typeof navigator<"u"&&/Safari/.test(navigator.userAgent)&&!/(Chrome\/|Edge\/)/.test(navigator.userAgent)&&[].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1]<604)}),W=te.schema,Y=te.hasGetAll,te=W.tables.map(S),q={};return te.forEach(function(ae){return q[ae.name]=ae}),{stack:"dbcore",transaction:u.transaction.bind(u),table:function(ae){if(!q[ae])throw new Error("Table '".concat(ae,"' not found"));return q[ae]},MIN_KEY:-1/0,MAX_KEY:Xo(p),schema:W}}function bo(u,p,y,w){var S=y.IDBKeyRange;return y.indexedDB,{dbcore:(w=Mr(p,S,w),u.dbcore.reduce(function(A,N){return N=N.create,r(r({},A),N(A))},w))}}function Qo(u,w){var y=w.db,w=bo(u._middlewares,y,u._deps,w);u.core=w.dbcore,u.tables.forEach(function(S){var A=S.name;u.core.schema.tables.some(function(N){return N.name===A})&&(S.core=u.core.table(A),u[A]instanceof u.Table&&(u[A].core=S.core));});}function vo(u,p,y,w){y.forEach(function(S){var A=w[S];p.forEach(function(N){var H=(function W(Y,te){return C(Y,te)||(Y=c(Y))&&W(Y,te)})(N,S);(!H||"value"in H&&H.value===void 0)&&(N===u.Transaction.prototype||N instanceof u.Transaction?_(N,S,{get:function(){return this.table(S)},set:function(W){g(this,S,{value:W,writable:true,configurable:true,enumerable:true});}}):N[S]=new u.Table(S,A));});});}function Sa(u,p){p.forEach(function(y){for(var w in y)y[w]instanceof u.Table&&delete y[w];});}function mi(u,p){return u._cfg.version-p._cfg.version}function rf(u,p,y,w){var S=u._dbSchema;y.objectStoreNames.contains("$meta")&&!S.$meta&&(S.$meta=pi("$meta",of("")[0],[]),u._storeNames.push("$meta"));var A=u._createTransaction("readwrite",u._storeNames,S);A.create(y),A._completion.catch(w);var N=A._reject.bind(A),H=ie.transless||ie;nt(function(){return ie.trans=A,ie.transless=H,p!==0?(Qo(u,y),Y=p,((W=A).storeNames.includes("$meta")?W.table("$meta").get("version").then(function(te){return te??Y}):fe.resolve(Y)).then(function(te){return ae=te,G=A,ee=y,oe=[],te=(q=u)._versions,Q=q._dbSchema=Ta(0,q.idbdb,ee),(te=te.filter(function(de){return de._cfg.version>=ae})).length!==0?(te.forEach(function(de){oe.push(function(){var me=Q,ye=de._cfg.dbschema;ms(q,me,ee),ms(q,ye,ee),Q=q._dbSchema=ye;var xe=gr(me,ye);xe.add.forEach(function(ot){Jo(ee,ot[0],ot[1].primKey,ot[1].indexes);}),xe.change.forEach(function(ot){if(ot.recreate)throw new j.Upgrade("Not yet support for changing primary key");var Xe=ee.objectStore(ot.name);ot.add.forEach(function(mt){return Ca(Xe,mt)}),ot.change.forEach(function(mt){Xe.deleteIndex(mt.name),Ca(Xe,mt);}),ot.del.forEach(function(mt){return Xe.deleteIndex(mt)});});var $e=de._cfg.contentUpgrade;if($e&&de._cfg.version>ae){Qo(q,ee),G._memoizedTables={};var Ze=B(ye);xe.del.forEach(function(ot){Ze[ot]=me[ot];}),Sa(q,[q.Transaction.prototype]),vo(q,[q.Transaction.prototype],i(Ze),Ze),G.schema=Ze;var He,Ke=z($e);return Ke&&Lt(),xe=fe.follow(function(){var ot;(He=$e(G))&&Ke&&(ot=Mt.bind(null,null),He.then(ot,ot));}),He&&typeof He.then=="function"?fe.resolve(He):xe.then(function(){return He})}}),oe.push(function(me){var ye,xe,$e=de._cfg.dbschema;ye=$e,xe=me,[].slice.call(xe.db.objectStoreNames).forEach(function(Ze){return ye[Ze]==null&&xe.db.deleteObjectStore(Ze)}),Sa(q,[q.Transaction.prototype]),vo(q,[q.Transaction.prototype],q._storeNames,q._dbSchema),G.schema=q._dbSchema;}),oe.push(function(me){q.idbdb.objectStoreNames.contains("$meta")&&(Math.ceil(q.idbdb.version/10)===de._cfg.version?(q.idbdb.deleteObjectStore("$meta"),delete q._dbSchema.$meta,q._storeNames=q._storeNames.filter(function(ye){return ye!=="$meta"})):me.objectStore("$meta").put(de._cfg.version,"version"));});}),(function de(){return oe.length?fe.resolve(oe.shift()(G.idbtrans)).then(de):fe.resolve()})().then(function(){ko(Q,ee);})):fe.resolve();var q,ae,G,ee,oe,Q;}).catch(N)):(i(S).forEach(function(te){Jo(y,te,S[te].primKey,S[te].indexes);}),Qo(u,y),void fe.follow(function(){return u.on.populate.fire(A)}).catch(N));var W,Y;});}function Rr(u,p){ko(u._dbSchema,p),p.db.version%10!=0||p.objectStoreNames.contains("$meta")||p.db.createObjectStore("$meta").add(Math.ceil(p.db.version/10-1),"version");var y=Ta(0,u.idbdb,p);ms(u,u._dbSchema,p);for(var w=0,S=gr(y,u._dbSchema).change;w<S.length;w++){var A=(function(N){if(N.change.length||N.recreate)return console.warn("Unable to patch indexes of table ".concat(N.name," because it has changes on the type of index or primary key.")),{value:void 0};var H=p.objectStore(N.name);N.add.forEach(function(W){et&&console.debug("Dexie upgrade patch: Creating missing index ".concat(N.name,".").concat(W.src)),Ca(H,W);});})(S[w]);if(typeof A=="object")return A.value}}function gr(u,p){var y,w={del:[],add:[],change:[]};for(y in u)p[y]||w.del.push(y);for(y in p){var S=u[y],A=p[y];if(S){var N={name:y,def:A,recreate:false,del:[],add:[],change:[]};if(""+(S.primKey.keyPath||"")!=""+(A.primKey.keyPath||"")||S.primKey.auto!==A.primKey.auto)N.recreate=true,w.change.push(N);else {var H=S.idxByName,W=A.idxByName,Y=void 0;for(Y in H)W[Y]||N.del.push(Y);for(Y in W){var te=H[Y],q=W[Y];te?te.src!==q.src&&N.change.push(q):N.add.push(q);}(0<N.del.length||0<N.add.length||0<N.change.length)&&w.change.push(N);}}else w.add.push([y,A]);}return w}function Jo(u,p,y,w){var S=u.db.createObjectStore(p,y.keyPath?{keyPath:y.keyPath,autoIncrement:y.auto}:{autoIncrement:y.auto});return w.forEach(function(A){return Ca(S,A)}),S}function ko(u,p){i(u).forEach(function(y){p.db.objectStoreNames.contains(y)||(et&&console.debug("Dexie: Creating missing table",y),Jo(p,y,u[y].primKey,u[y].indexes));});}function Ca(u,p){u.createIndex(p.name,p.keyPath,{unique:p.unique,multiEntry:p.multi});}function Ta(u,p,y){var w={};return T(p.objectStoreNames,0).forEach(function(S){for(var A=y.objectStore(S),N=wo(hi(Y=A.keyPath),Y||"",true,false,!!A.autoIncrement,Y&&typeof Y!="string",true),H=[],W=0;W<A.indexNames.length;++W){var te=A.index(A.indexNames[W]),Y=te.keyPath,te=wo(te.name,Y,!!te.unique,!!te.multiEntry,false,Y&&typeof Y!="string",false);H.push(te);}w[S]=pi(S,N,H);}),w}function ms(u,p,y){for(var w=y.db.objectStoreNames,S=0;S<w.length;++S){var A=w[S],N=y.objectStore(A);u._hasGetAll="getAll"in N;for(var H=0;H<N.indexNames.length;++H){var W=N.indexNames[H],Y=N.index(W).keyPath,te=typeof Y=="string"?Y:"["+T(Y).join("+")+"]";!p[A]||(Y=p[A].idxByName[te])&&(Y.name=W,delete p[A].idxByName[te],p[A].idxByName[W]=Y);}}typeof navigator<"u"&&/Safari/.test(navigator.userAgent)&&!/(Chrome\/|Edge\/)/.test(navigator.userAgent)&&a.WorkerGlobalScope&&a instanceof a.WorkerGlobalScope&&[].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1]<604&&(u._hasGetAll=false);}function of(u){return u.split(",").map(function(p,y){var w=(p=p.trim()).replace(/([&*]|\+\+)/g,""),S=/^\[/.test(w)?w.match(/^\[(.*)\]$/)[1].split("+"):w;return wo(w,S||null,/\&/.test(p),/\*/.test(p),/\+\+/.test(p),s(S),y===0)})}var fw=(gs.prototype._parseStoresSpec=function(u,p){i(u).forEach(function(y){if(u[y]!==null){var w=of(u[y]),S=w.shift();if(S.unique=true,S.multi)throw new j.Schema("Primary key cannot be multi-valued");w.forEach(function(A){if(A.auto)throw new j.Schema("Only primary key can be marked as autoIncrement (++)");if(!A.keyPath)throw new j.Schema("Index must have a name and cannot be an empty string")}),p[y]=pi(y,S,w);}});},gs.prototype.stores=function(y){var p=this.db;this._cfg.storesSource=this._cfg.storesSource?l(this._cfg.storesSource,y):y;var y=p._versions,w={},S={};return y.forEach(function(A){l(w,A._cfg.storesSource),S=A._cfg.dbschema={},A._parseStoresSpec(w,S);}),p._dbSchema=S,Sa(p,[p._allTables,p,p.Transaction.prototype]),vo(p,[p._allTables,p,p.Transaction.prototype,this._cfg.tables],i(S),S),p._storeNames=i(S),this},gs.prototype.upgrade=function(u){return this._cfg.contentUpgrade=Rt(this._cfg.contentUpgrade||we,u),this},gs);function gs(){}function ic(u,p){var y=u._dbNamesDB;return y||(y=u._dbNamesDB=new to(xn,{addons:[],indexedDB:u,IDBKeyRange:p})).version(1).stores({dbnames:"name"}),y.table("dbnames")}function sc(u){return u&&typeof u.databases=="function"}function lc(u){return nt(function(){return ie.letThrough=true,u()})}function cc(u){return !("from"in u)}var Yn=function(u,p){if(!this){var y=new Yn;return u&&"d"in u&&l(y,u),y}l(this,arguments.length?{d:1,from:u,to:1<arguments.length?p:u}:{d:0});};function gi(u,p,y){var w=Et(p,y);if(!isNaN(w)){if(0<w)throw RangeError();if(cc(u))return l(u,{from:p,to:y,d:1});var S=u.l,w=u.r;if(Et(y,u.from)<0)return S?gi(S,p,y):u.l={from:p,to:y,d:1,l:null,r:null},sf(u);if(0<Et(p,u.to))return w?gi(w,p,y):u.r={from:p,to:y,d:1,l:null,r:null},sf(u);Et(p,u.from)<0&&(u.from=p,u.l=null,u.d=w?w.d+1:1),0<Et(y,u.to)&&(u.to=y,u.r=null,u.d=u.l?u.l.d+1:1),y=!u.r,S&&!u.l&&yi(u,S),w&&y&&yi(u,w);}}function yi(u,p){cc(p)||(function y(w,W){var A=W.from,N=W.to,H=W.l,W=W.r;gi(w,A,N),H&&y(w,H),W&&y(w,W);})(u,p);}function af(u,p){var y=ys(p),w=y.next();if(w.done)return  false;for(var S=w.value,A=ys(u),N=A.next(S.from),H=N.value;!w.done&&!N.done;){if(Et(H.from,S.to)<=0&&0<=Et(H.to,S.from))return  true;Et(S.from,H.from)<0?S=(w=y.next(H.from)).value:H=(N=A.next(S.from)).value;}return  false}function ys(u){var p=cc(u)?null:{s:0,n:u};return {next:function(y){for(var w=0<arguments.length;p;)switch(p.s){case 0:if(p.s=1,w)for(;p.n.l&&Et(y,p.n.from)<0;)p={up:p,n:p.n.l,s:1};else for(;p.n.l;)p={up:p,n:p.n.l,s:1};case 1:if(p.s=2,!w||Et(y,p.n.to)<=0)return {value:p.n,done:false};case 2:if(p.n.r){p.s=3,p={up:p,n:p.n.r,s:0};continue}case 3:p=p.up;}return {done:true}}}}function sf(u){var p,y,w=(((p=u.r)===null||p===void 0?void 0:p.d)||0)-(((y=u.l)===null||y===void 0?void 0:y.d)||0),S=1<w?"r":w<-1?"l":"";S&&(p=S=="r"?"l":"r",y=r({},u),w=u[S],u.from=w.from,u.to=w.to,u[S]=w[S],y[S]=w[p],(u[p]=y).d=lf(y)),u.d=lf(u);}function lf(y){var p=y.r,y=y.l;return (p?y?Math.max(p.d,y.d):p.d:y?y.d:0)+1}function _s(u,p){return i(p).forEach(function(y){u[y]?yi(u[y],p[y]):u[y]=(function w(S){var A,N,H={};for(A in S)f(S,A)&&(N=S[A],H[A]=!N||typeof N!="object"||L.has(N.constructor)?N:w(N));return H})(p[y]);}),u}function uc(u,p){return u.all||p.all||Object.keys(u).some(function(y){return p[y]&&af(p[y],u[y])})}m(Yn.prototype,((yr={add:function(u){return yi(this,u),this},addKey:function(u){return gi(this,u,u),this},addKeys:function(u){var p=this;return u.forEach(function(y){return gi(p,y,y)}),this},hasKey:function(u){var p=ys(this).next(u).value;return p&&Et(p.from,u)<=0&&0<=Et(p.to,u)}})[J]=function(){return ys(this)},yr));var ea={},dc={},fc=false;function ws(u){_s(dc,u),fc||(fc=true,setTimeout(function(){fc=false,hc(dc,!(dc={}));},0));}function hc(u,p){p===void 0&&(p=false);var y=new Set;if(u.all)for(var w=0,S=Object.values(ea);w<S.length;w++)cf(N=S[w],u,y,p);else for(var A in u){var N,H=/^idb\:\/\/(.*)\/(.*)\//.exec(A);H&&(A=H[1],H=H[2],(N=ea["idb://".concat(A,"/").concat(H)])&&cf(N,u,y,p));}y.forEach(function(W){return W()});}function cf(u,p,y,w){for(var S=[],A=0,N=Object.entries(u.queries.query);A<N.length;A++){for(var H=N[A],W=H[0],Y=[],te=0,q=H[1];te<q.length;te++){var ae=q[te];uc(p,ae.obsSet)?ae.subscribers.forEach(function(Q){return y.add(Q)}):w&&Y.push(ae);}w&&S.push([W,Y]);}if(w)for(var G=0,ee=S;G<ee.length;G++){var oe=ee[G],W=oe[0],Y=oe[1];u.queries.query[W]=Y;}}function hw(u){var p=u._state,y=u._deps.indexedDB;if(p.isBeingOpened||u.idbdb)return p.dbReadyPromise.then(function(){return p.dbOpenError?Vt(p.dbOpenError):u});p.isBeingOpened=true,p.dbOpenError=null,p.openComplete=false;var w=p.openCanceller,S=Math.round(10*u.verno),A=false;function N(){if(p.openCanceller!==w)throw new j.DatabaseClosed("db.open() was cancelled")}function H(){return new fe(function(ae,G){if(N(),!y)throw new j.MissingAPI;var ee=u.name,oe=p.autoSchema||!S?y.open(ee):y.open(ee,S);if(!oe)throw new j.MissingAPI;oe.onerror=an(G),oe.onblocked=Ue(u._fireOnBlocked),oe.onupgradeneeded=Ue(function(Q){var de;te=oe.transaction,p.autoSchema&&!u._options.allowEmptyDB?(oe.onerror=_o,te.abort(),oe.result.close(),(de=y.deleteDatabase(ee)).onsuccess=de.onerror=Ue(function(){G(new j.NoSuchDatabase("Database ".concat(ee," doesnt exist")));})):(te.onerror=an(G),Q=Q.oldVersion>Math.pow(2,62)?0:Q.oldVersion,q=Q<1,u.idbdb=oe.result,A&&Rr(u,te),rf(u,Q/10,te,G));},G),oe.onsuccess=Ue(function(){te=null;var Q,de,me,ye,xe,$e=u.idbdb=oe.result,Ze=T($e.objectStoreNames);if(0<Ze.length)try{var He=$e.transaction((ye=Ze).length===1?ye[0]:ye,"readonly");if(p.autoSchema)de=$e,me=He,(Q=u).verno=de.version/10,me=Q._dbSchema=Ta(0,de,me),Q._storeNames=T(de.objectStoreNames,0),vo(Q,[Q._allTables],i(me),me);else if(ms(u,u._dbSchema,He),((xe=gr(Ta(0,(xe=u).idbdb,He),xe._dbSchema)).add.length||xe.change.some(function(Ke){return Ke.add.length||Ke.change.length}))&&!A)return console.warn("Dexie SchemaDiff: Schema was extended without increasing the number passed to db.version(). Dexie will add missing parts and increment native version number to workaround this."),$e.close(),S=$e.version+1,A=!0,ae(H());Qo(u,He);}catch{}kn.push(u),$e.onversionchange=Ue(function(Ke){p.vcFired=true,u.on("versionchange").fire(Ke);}),$e.onclose=Ue(function(Ke){u.on("close").fire(Ke);}),q&&(xe=u._deps,He=ee,$e=xe.indexedDB,xe=xe.IDBKeyRange,sc($e)||He===xn||ic($e,xe).put({name:He}).catch(we)),ae();},G);}).catch(function(ae){switch(ae==null?void 0:ae.name){case "UnknownError":if(0<p.PR1398_maxLoop)return p.PR1398_maxLoop--,console.warn("Dexie: Workaround for Chrome UnknownError on open()"),H();break;case "VersionError":if(0<S)return S=0,H()}return fe.reject(ae)})}var W,Y=p.dbReadyResolve,te=null,q=false;return fe.race([w,(typeof navigator>"u"?fe.resolve():!navigator.userAgentData&&/Safari\//.test(navigator.userAgent)&&!/Chrom(e|ium)\//.test(navigator.userAgent)&&indexedDB.databases?new Promise(function(ae){function G(){return indexedDB.databases().finally(ae)}W=setInterval(G,100),G();}).finally(function(){return clearInterval(W)}):Promise.resolve()).then(H)]).then(function(){return N(),p.onReadyBeingFired=[],fe.resolve(lc(function(){return u.on.ready.fire(u.vip)})).then(function ae(){if(0<p.onReadyBeingFired.length){var G=p.onReadyBeingFired.reduce(Rt,we);return p.onReadyBeingFired=[],fe.resolve(lc(function(){return G(u.vip)})).then(ae)}})}).finally(function(){p.openCanceller===w&&(p.onReadyBeingFired=null,p.isBeingOpened=false);}).catch(function(ae){p.dbOpenError=ae;try{te&&te.abort();}catch{}return w===p.openCanceller&&u._close(),Vt(ae)}).finally(function(){p.openComplete=true,Y();}).then(function(){var ae;return q&&(ae={},u.tables.forEach(function(G){G.schema.indexes.forEach(function(ee){ee.name&&(ae["idb://".concat(u.name,"/").concat(G.name,"/").concat(ee.name)]=new Yn(-1/0,[[[]]]));}),ae["idb://".concat(u.name,"/").concat(G.name,"/")]=ae["idb://".concat(u.name,"/").concat(G.name,"/:dels")]=new Yn(-1/0,[[[]]]);}),Vn(Go).fire(ae),hc(ae,true)),u})}function pc(u){function p(A){return u.next(A)}var y=S(p),w=S(function(A){return u.throw(A)});function S(A){return function(W){var H=A(W),W=H.value;return H.done?W:W&&typeof W.then=="function"?W.then(y,w):s(W)?Promise.all(W).then(y,w):y(W)}}return S(p)()}function bs(u,p,y){for(var w=s(u)?u.slice():[u],S=0;S<y;++S)w.push(p);return w}var pw={stack:"dbcore",name:"VirtualIndexMiddleware",level:1,create:function(u){return r(r({},u),{table:function(p){var y=u.table(p),w=y.schema,S={},A=[];function N(q,ae,G){var ee=Nt(q),oe=S[ee]=S[ee]||[],Q=q==null?0:typeof q=="string"?1:q.length,de=0<ae,de=r(r({},G),{name:de?"".concat(ee,"(virtual-from:").concat(G.name,")"):G.name,lowLevelIndex:G,isVirtual:de,keyTail:ae,keyLength:Q,extractKey:Zo(q),unique:!de&&G.unique});return oe.push(de),de.isPrimaryKey||A.push(de),1<Q&&N(Q===2?q[0]:q.slice(0,Q-1),ae+1,G),oe.sort(function(me,ye){return me.keyTail-ye.keyTail}),de}p=N(w.primaryKey.keyPath,0,w.primaryKey),S[":id"]=[p];for(var H=0,W=w.indexes;H<W.length;H++){var Y=W[H];N(Y.keyPath,0,Y);}function te(q){var ae,G=q.query.index;return G.isVirtual?r(r({},q),{query:{index:G.lowLevelIndex,range:(ae=q.query.range,G=G.keyTail,{type:ae.type===1?2:ae.type,lower:bs(ae.lower,ae.lowerOpen?u.MAX_KEY:u.MIN_KEY,G),lowerOpen:true,upper:bs(ae.upper,ae.upperOpen?u.MIN_KEY:u.MAX_KEY,G),upperOpen:true})}}):q}return r(r({},y),{schema:r(r({},w),{primaryKey:p,indexes:A,getIndexByKeyPath:function(q){return (q=S[Nt(q)])&&q[0]}}),count:function(q){return y.count(te(q))},query:function(q){return y.query(te(q))},openCursor:function(q){var ae=q.query.index,G=ae.keyTail,ee=ae.isVirtual,oe=ae.keyLength;return ee?y.openCursor(te(q)).then(function(de){return de&&Q(de)}):y.openCursor(q);function Q(de){return Object.create(de,{continue:{value:function(me){me!=null?de.continue(bs(me,q.reverse?u.MAX_KEY:u.MIN_KEY,G)):q.unique?de.continue(de.key.slice(0,oe).concat(q.reverse?u.MIN_KEY:u.MAX_KEY,G)):de.continue();}},continuePrimaryKey:{value:function(me,ye){de.continuePrimaryKey(bs(me,u.MAX_KEY,G),ye);}},primaryKey:{get:function(){return de.primaryKey}},key:{get:function(){var me=de.key;return oe===1?me[0]:me.slice(0,oe)}},value:{get:function(){return de.value}}})}}})}})}};function mc(u,p,y,w){return y=y||{},w=w||"",i(u).forEach(function(S){var A,N,H;f(p,S)?(A=u[S],N=p[S],typeof A=="object"&&typeof N=="object"&&A&&N?(H=re(A))!==re(N)?y[w+S]=p[S]:H==="Object"?mc(A,N,y,w+S+"."):A!==N&&(y[w+S]=p[S]):A!==N&&(y[w+S]=p[S])):y[w+S]=void 0;}),i(p).forEach(function(S){f(u,S)||(y[w+S]=p[S]);}),y}function gc(u,p){return p.type==="delete"?p.keys:p.keys||p.values.map(u.extractKey)}var mw={stack:"dbcore",name:"HooksMiddleware",level:2,create:function(u){return r(r({},u),{table:function(p){var y=u.table(p),w=y.schema.primaryKey;return r(r({},y),{mutate:function(S){var A=ie.trans,N=A.table(p).hook,H=N.deleting,W=N.creating,Y=N.updating;switch(S.type){case "add":if(W.fire===we)break;return A._promise("readwrite",function(){return te(S)},true);case "put":if(W.fire===we&&Y.fire===we)break;return A._promise("readwrite",function(){return te(S)},true);case "delete":if(H.fire===we)break;return A._promise("readwrite",function(){return te(S)},true);case "deleteRange":if(H.fire===we)break;return A._promise("readwrite",function(){return (function q(ae,G,ee){return y.query({trans:ae,values:false,query:{index:w,range:G},limit:ee}).then(function(oe){var Q=oe.result;return te({type:"delete",keys:Q,trans:ae}).then(function(de){return 0<de.numFailures?Promise.reject(de.failures[0]):Q.length<ee?{failures:[],numFailures:0,lastResult:void 0}:q(ae,r(r({},G),{lower:Q[Q.length-1],lowerOpen:true}),ee)})})})(S.trans,S.range,1e4)},true)}return y.mutate(S);function te(q){var ae,G,ee,oe=ie.trans,Q=q.keys||gc(w,q);if(!Q)throw new Error("Keys missing");return (q=q.type==="add"||q.type==="put"?r(r({},q),{keys:Q}):r({},q)).type!=="delete"&&(q.values=o([],q.values)),q.keys&&(q.keys=o([],q.keys)),ae=y,ee=Q,((G=q).type==="add"?Promise.resolve([]):ae.getMany({trans:G.trans,keys:ee,cache:"immutable"})).then(function(de){var me=Q.map(function(ye,xe){var $e,Ze,He,Ke=de[xe],ot={onerror:null,onsuccess:null};return q.type==="delete"?H.fire.call(ot,ye,Ke,oe):q.type==="add"||Ke===void 0?($e=W.fire.call(ot,ye,q.values[xe],oe),ye==null&&$e!=null&&(q.keys[xe]=ye=$e,w.outbound||O(q.values[xe],w.keyPath,ye))):($e=mc(Ke,q.values[xe]),(Ze=Y.fire.call(ot,$e,ye,Ke,oe))&&(He=q.values[xe],Object.keys(Ze).forEach(function(Xe){f(He,Xe)?He[Xe]=Ze[Xe]:O(He,Xe,Ze[Xe]);}))),ot});return y.mutate(q).then(function(ye){for(var xe=ye.failures,$e=ye.results,Ze=ye.numFailures,ye=ye.lastResult,He=0;He<Q.length;++He){var Ke=($e||Q)[He],ot=me[He];Ke==null?ot.onerror&&ot.onerror(xe[He]):ot.onsuccess&&ot.onsuccess(q.type==="put"&&de[He]?q.values[He]:Ke);}return {failures:xe,results:$e,numFailures:Ze,lastResult:ye}}).catch(function(ye){return me.forEach(function(xe){return xe.onerror&&xe.onerror(ye)}),Promise.reject(ye)})})}}})}})}};function uf(u,p,y){try{if(!p||p.keys.length<u.length)return null;for(var w=[],S=0,A=0;S<p.keys.length&&A<u.length;++S)Et(p.keys[S],u[A])===0&&(w.push(y?Me(p.values[S]):p.values[S]),++A);return w.length===u.length?w:null}catch{return null}}var gw={stack:"dbcore",level:-1,create:function(u){return {table:function(p){var y=u.table(p);return r(r({},y),{getMany:function(w){if(!w.cache)return y.getMany(w);var S=uf(w.keys,w.trans._cache,w.cache==="clone");return S?fe.resolve(S):y.getMany(w).then(function(A){return w.trans._cache={keys:w.keys,values:w.cache==="clone"?Me(A):A},A})},mutate:function(w){return w.type!=="add"&&(w.trans._cache=null),y.mutate(w)}})}}}};function df(u,p){return u.trans.mode==="readonly"&&!!u.subscr&&!u.trans.explicit&&u.trans.db._options.cache!=="disabled"&&!p.schema.primaryKey.outbound}function ff(u,p){switch(u){case "query":return p.values&&!p.unique;case "get":case "getMany":case "count":case "openCursor":return  false}}var yw={stack:"dbcore",level:0,name:"Observability",create:function(u){var p=u.schema.name,y=new Yn(u.MIN_KEY,u.MAX_KEY);return r(r({},u),{transaction:function(w,S,A){if(ie.subscr&&S!=="readonly")throw new j.ReadOnly("Readwrite transaction in liveQuery context. Querier source: ".concat(ie.querier));return u.transaction(w,S,A)},table:function(w){var S=u.table(w),A=S.schema,N=A.primaryKey,q=A.indexes,H=N.extractKey,W=N.outbound,Y=N.autoIncrement&&q.filter(function(G){return G.compound&&G.keyPath.includes(N.keyPath)}),te=r(r({},S),{mutate:function(G){function ee(Xe){return Xe="idb://".concat(p,"/").concat(w,"/").concat(Xe),ye[Xe]||(ye[Xe]=new Yn)}var oe,Q,de,me=G.trans,ye=G.mutatedParts||(G.mutatedParts={}),xe=ee(""),$e=ee(":dels"),Ze=G.type,ot=G.type==="deleteRange"?[G.range]:G.type==="delete"?[G.keys]:G.values.length<50?[gc(N,G).filter(function(Xe){return Xe}),G.values]:[],He=ot[0],Ke=ot[1],ot=G.trans._cache;return s(He)?(xe.addKeys(He),(ot=Ze==="delete"||He.length===Ke.length?uf(He,ot):null)||$e.addKeys(He),(ot||Ke)&&(oe=ee,Q=ot,de=Ke,A.indexes.forEach(function(Xe){var mt=oe(Xe.name||"");function qt(Kt){return Kt!=null?Xe.extractKey(Kt):null}function zt(Kt){return Xe.multiEntry&&s(Kt)?Kt.forEach(function(dr){return mt.addKey(dr)}):mt.addKey(Kt)}(Q||de).forEach(function(Kt,Xn){var Ht=Q&&qt(Q[Xn]),Xn=de&&qt(de[Xn]);Et(Ht,Xn)!==0&&(Ht!=null&&zt(Ht),Xn!=null&&zt(Xn));});}))):He?(Ke={from:(Ke=He.lower)!==null&&Ke!==void 0?Ke:u.MIN_KEY,to:(Ke=He.upper)!==null&&Ke!==void 0?Ke:u.MAX_KEY},$e.add(Ke),xe.add(Ke)):(xe.add(y),$e.add(y),A.indexes.forEach(function(Xe){return ee(Xe.name).add(y)})),S.mutate(G).then(function(Xe){return !He||G.type!=="add"&&G.type!=="put"||(xe.addKeys(Xe.results),Y&&Y.forEach(function(mt){for(var qt=G.values.map(function(Ht){return mt.extractKey(Ht)}),zt=mt.keyPath.findIndex(function(Ht){return Ht===N.keyPath}),Kt=0,dr=Xe.results.length;Kt<dr;++Kt)qt[Kt][zt]=Xe.results[Kt];ee(mt.name).addKeys(qt);})),me.mutatedParts=_s(me.mutatedParts||{},ye),Xe})}}),q=function(ee){var oe=ee.query,ee=oe.index,oe=oe.range;return [ee,new Yn((ee=oe.lower)!==null&&ee!==void 0?ee:u.MIN_KEY,(oe=oe.upper)!==null&&oe!==void 0?oe:u.MAX_KEY)]},ae={get:function(G){return [N,new Yn(G.key)]},getMany:function(G){return [N,new Yn().addKeys(G.keys)]},count:q,query:q,openCursor:q};return i(ae).forEach(function(G){te[G]=function(ee){var oe=ie.subscr,Q=!!oe,de=df(ie,S)&&ff(G,ee)?ee.obsSet={}:oe;if(Q){var me=function(Ke){return Ke="idb://".concat(p,"/").concat(w,"/").concat(Ke),de[Ke]||(de[Ke]=new Yn)},ye=me(""),xe=me(":dels"),oe=ae[G](ee),Q=oe[0],oe=oe[1];if((G==="query"&&Q.isPrimaryKey&&!ee.values?xe:me(Q.name||"")).add(oe),!Q.isPrimaryKey){if(G!=="count"){var $e=G==="query"&&W&&ee.values&&S.query(r(r({},ee),{values:false}));return S[G].apply(this,arguments).then(function(Ke){if(G==="query"){if(W&&ee.values)return $e.then(function(qt){return qt=qt.result,ye.addKeys(qt),Ke});var ot=ee.values?Ke.result.map(H):Ke.result;(ee.values?ye:xe).addKeys(ot);}else if(G==="openCursor"){var Xe=Ke,mt=ee.values;return Xe&&Object.create(Xe,{key:{get:function(){return xe.addKey(Xe.primaryKey),Xe.key}},primaryKey:{get:function(){var qt=Xe.primaryKey;return xe.addKey(qt),qt}},value:{get:function(){return mt&&ye.addKey(Xe.primaryKey),Xe.value}}})}return Ke})}xe.add(y);}}return S[G].apply(this,arguments)};}),te}})}};function hf(u,p,y){if(y.numFailures===0)return p;if(p.type==="deleteRange")return null;var w=p.keys?p.keys.length:"values"in p&&p.values?p.values.length:1;return y.numFailures===w?null:(p=r({},p),s(p.keys)&&(p.keys=p.keys.filter(function(S,A){return !(A in y.failures)})),"values"in p&&s(p.values)&&(p.values=p.values.filter(function(S,A){return !(A in y.failures)})),p)}function yc(u,p){return y=u,((w=p).lower===void 0||(w.lowerOpen?0<Et(y,w.lower):0<=Et(y,w.lower)))&&(u=u,(p=p).upper===void 0||(p.upperOpen?Et(u,p.upper)<0:Et(u,p.upper)<=0));var y,w;}function pf(u,p,ae,w,S,A){if(!ae||ae.length===0)return u;var N=p.query.index,H=N.multiEntry,W=p.query.range,Y=w.schema.primaryKey.extractKey,te=N.extractKey,q=(N.lowLevelIndex||N).extractKey,ae=ae.reduce(function(G,ee){var oe=G,Q=[];if(ee.type==="add"||ee.type==="put")for(var de=new Yn,me=ee.values.length-1;0<=me;--me){var ye,xe=ee.values[me],$e=Y(xe);de.hasKey($e)||(ye=te(xe),(H&&s(ye)?ye.some(function(Xe){return yc(Xe,W)}):yc(ye,W))&&(de.addKey($e),Q.push(xe)));}switch(ee.type){case "add":var Ze=new Yn().addKeys(p.values?G.map(function(mt){return Y(mt)}):G),oe=G.concat(p.values?Q.filter(function(mt){return mt=Y(mt),!Ze.hasKey(mt)&&(Ze.addKey(mt),true)}):Q.map(function(mt){return Y(mt)}).filter(function(mt){return !Ze.hasKey(mt)&&(Ze.addKey(mt),true)}));break;case "put":var He=new Yn().addKeys(ee.values.map(function(mt){return Y(mt)}));oe=G.filter(function(mt){return !He.hasKey(p.values?Y(mt):mt)}).concat(p.values?Q:Q.map(function(mt){return Y(mt)}));break;case "delete":var Ke=new Yn().addKeys(ee.keys);oe=G.filter(function(mt){return !Ke.hasKey(p.values?Y(mt):mt)});break;case "deleteRange":var ot=ee.range;oe=G.filter(function(mt){return !yc(Y(mt),ot)});}return oe},u);return ae===u?u:(ae.sort(function(G,ee){return Et(q(G),q(ee))||Et(Y(G),Y(ee))}),p.limit&&p.limit<1/0&&(ae.length>p.limit?ae.length=p.limit:u.length===p.limit&&ae.length<p.limit&&(S.dirty=true)),A?Object.freeze(ae):ae)}function mf(u,p){return Et(u.lower,p.lower)===0&&Et(u.upper,p.upper)===0&&!!u.lowerOpen==!!p.lowerOpen&&!!u.upperOpen==!!p.upperOpen}function _w(u,p){return (function(y,w,S,A){if(y===void 0)return w!==void 0?-1:0;if(w===void 0)return 1;if((w=Et(y,w))===0){if(S&&A)return 0;if(S)return 1;if(A)return  -1}return w})(u.lower,p.lower,u.lowerOpen,p.lowerOpen)<=0&&0<=(function(y,w,S,A){if(y===void 0)return w!==void 0?1:0;if(w===void 0)return  -1;if((w=Et(y,w))===0){if(S&&A)return 0;if(S)return  -1;if(A)return 1}return w})(u.upper,p.upper,u.upperOpen,p.upperOpen)}function ww(u,p,y,w){u.subscribers.add(y),w.addEventListener("abort",function(){var S,A;u.subscribers.delete(y),u.subscribers.size===0&&(S=u,A=p,setTimeout(function(){S.subscribers.size===0&&he(A,S);},3e3));});}var bw={stack:"dbcore",level:0,name:"Cache",create:function(u){var p=u.schema.name;return r(r({},u),{transaction:function(y,w,S){var A,N,H=u.transaction(y,w,S);return w==="readwrite"&&(N=(A=new AbortController).signal,S=function(W){return function(){if(A.abort(),w==="readwrite"){for(var Y=new Set,te=0,q=y;te<q.length;te++){var ae=q[te],G=ea["idb://".concat(p,"/").concat(ae)];if(G){var ee=u.table(ae),oe=G.optimisticOps.filter(function(mt){return mt.trans===H});if(H._explicit&&W&&H.mutatedParts)for(var Q=0,de=Object.values(G.queries.query);Q<de.length;Q++)for(var me=0,ye=(Ze=de[Q]).slice();me<ye.length;me++)uc((He=ye[me]).obsSet,H.mutatedParts)&&(he(Ze,He),He.subscribers.forEach(function(mt){return Y.add(mt)}));else if(0<oe.length){G.optimisticOps=G.optimisticOps.filter(function(mt){return mt.trans!==H});for(var xe=0,$e=Object.values(G.queries.query);xe<$e.length;xe++)for(var Ze,He,Ke,ot=0,Xe=(Ze=$e[xe]).slice();ot<Xe.length;ot++)(He=Xe[ot]).res!=null&&H.mutatedParts&&(W&&!He.dirty?(Ke=Object.isFrozen(He.res),Ke=pf(He.res,He.req,oe,ee,He,Ke),He.dirty?(he(Ze,He),He.subscribers.forEach(function(mt){return Y.add(mt)})):Ke!==He.res&&(He.res=Ke,He.promise=fe.resolve({result:Ke}))):(He.dirty&&he(Ze,He),He.subscribers.forEach(function(mt){return Y.add(mt)})));}}}Y.forEach(function(mt){return mt()});}}},H.addEventListener("abort",S(false),{signal:N}),H.addEventListener("error",S(false),{signal:N}),H.addEventListener("complete",S(true),{signal:N})),H},table:function(y){var w=u.table(y),S=w.schema.primaryKey;return r(r({},w),{mutate:function(A){var N=ie.trans;if(S.outbound||N.db._options.cache==="disabled"||N.explicit||N.idbtrans.mode!=="readwrite")return w.mutate(A);var H=ea["idb://".concat(p,"/").concat(y)];return H?(N=w.mutate(A),A.type!=="add"&&A.type!=="put"||!(50<=A.values.length||gc(S,A).some(function(W){return W==null}))?(H.optimisticOps.push(A),A.mutatedParts&&ws(A.mutatedParts),N.then(function(W){0<W.numFailures&&(he(H.optimisticOps,A),(W=hf(0,A,W))&&H.optimisticOps.push(W),A.mutatedParts&&ws(A.mutatedParts));}),N.catch(function(){he(H.optimisticOps,A),A.mutatedParts&&ws(A.mutatedParts);})):N.then(function(W){var Y=hf(0,r(r({},A),{values:A.values.map(function(te,q){var ae;return W.failures[q]?te:(te=(ae=S.keyPath)!==null&&ae!==void 0&&ae.includes(".")?Me(te):r({},te),O(te,S.keyPath,W.results[q]),te)})}),W);H.optimisticOps.push(Y),queueMicrotask(function(){return A.mutatedParts&&ws(A.mutatedParts)});}),N):w.mutate(A)},query:function(A){if(!df(ie,w)||!ff("query",A))return w.query(A);var N=((Y=ie.trans)===null||Y===void 0?void 0:Y.db._options.cache)==="immutable",q=ie,H=q.requery,W=q.signal,Y=(function(ee,oe,Q,de){var me=ea["idb://".concat(ee,"/").concat(oe)];if(!me)return [];if(!(oe=me.queries[Q]))return [null,false,me,null];var ye=oe[(de.query?de.query.index.name:null)||""];if(!ye)return [null,false,me,null];switch(Q){case "query":var xe=ye.find(function($e){return $e.req.limit===de.limit&&$e.req.values===de.values&&mf($e.req.query.range,de.query.range)});return xe?[xe,true,me,ye]:[ye.find(function($e){return ("limit"in $e.req?$e.req.limit:1/0)>=de.limit&&(!de.values||$e.req.values)&&_w($e.req.query.range,de.query.range)}),false,me,ye];case "count":return xe=ye.find(function($e){return mf($e.req.query.range,de.query.range)}),[xe,!!xe,me,ye]}})(p,y,"query",A),te=Y[0],q=Y[1],ae=Y[2],G=Y[3];return te&&q?te.obsSet=A.obsSet:(q=w.query(A).then(function(ee){var oe=ee.result;if(te&&(te.res=oe),N){for(var Q=0,de=oe.length;Q<de;++Q)Object.freeze(oe[Q]);Object.freeze(oe);}else ee.result=Me(oe);return ee}).catch(function(ee){return G&&te&&he(G,te),Promise.reject(ee)}),te={obsSet:A.obsSet,promise:q,subscribers:new Set,type:"query",req:A,dirty:false},G?G.push(te):(G=[te],(ae=ae||(ea["idb://".concat(p,"/").concat(y)]={queries:{query:{},count:{}},objs:new Map,optimisticOps:[],unsignaledParts:{}})).queries.query[A.query.index.name||""]=G)),ww(te,G,H,W),te.promise.then(function(ee){return {result:pf(ee.result,A,ae==null?void 0:ae.optimisticOps,w,te,N)}})}})}})}};function vs(u,p){return new Proxy(u,{get:function(y,w,S){return w==="db"?p:Reflect.get(y,w,S)}})}var to=(Mn.prototype.version=function(u){if(isNaN(u)||u<.1)throw new j.Type("Given version is not a positive number");if(u=Math.round(10*u)/10,this.idbdb||this._state.isBeingOpened)throw new j.Schema("Cannot add version when database is open");this.verno=Math.max(this.verno,u);var p=this._versions,y=p.filter(function(w){return w._cfg.version===u})[0];return y||(y=new this.Version(u),p.push(y),p.sort(mi),y.stores({}),this._state.autoSchema=false,y)},Mn.prototype._whenReady=function(u){var p=this;return this.idbdb&&(this._state.openComplete||ie.letThrough||this._vip)?u():new fe(function(y,w){if(p._state.openComplete)return w(new j.DatabaseClosed(p._state.dbOpenError));if(!p._state.isBeingOpened){if(!p._state.autoOpen)return void w(new j.DatabaseClosed);p.open().catch(we);}p._state.dbReadyPromise.then(y,w);}).then(u)},Mn.prototype.use=function(u){var p=u.stack,y=u.create,w=u.level,S=u.name;return S&&this.unuse({stack:p,name:S}),u=this._middlewares[p]||(this._middlewares[p]=[]),u.push({stack:p,create:y,level:w??10,name:S}),u.sort(function(A,N){return A.level-N.level}),this},Mn.prototype.unuse=function(u){var p=u.stack,y=u.name,w=u.create;return p&&this._middlewares[p]&&(this._middlewares[p]=this._middlewares[p].filter(function(S){return w?S.create!==w:!!y&&S.name!==y})),this},Mn.prototype.open=function(){var u=this;return Qt(be,function(){return hw(u)})},Mn.prototype._close=function(){var u=this._state,p=kn.indexOf(this);if(0<=p&&kn.splice(p,1),this.idbdb){try{this.idbdb.close();}catch{}this.idbdb=null;}u.isBeingOpened||(u.dbReadyPromise=new fe(function(y){u.dbReadyResolve=y;}),u.openCanceller=new fe(function(y,w){u.cancelOpen=w;}));},Mn.prototype.close=function(y){var p=(y===void 0?{disableAutoOpen:true}:y).disableAutoOpen,y=this._state;p?(y.isBeingOpened&&y.cancelOpen(new j.DatabaseClosed),this._close(),y.autoOpen=false,y.dbOpenError=new j.DatabaseClosed):(this._close(),y.autoOpen=this._options.autoOpen||y.isBeingOpened,y.openComplete=false,y.dbOpenError=null);},Mn.prototype.delete=function(u){var p=this;u===void 0&&(u={disableAutoOpen:true});var y=0<arguments.length&&typeof arguments[0]!="object",w=this._state;return new fe(function(S,A){function N(){p.close(u);var H=p._deps.indexedDB.deleteDatabase(p.name);H.onsuccess=Ue(function(){var W,Y,te;W=p._deps,Y=p.name,te=W.indexedDB,W=W.IDBKeyRange,sc(te)||Y===xn||ic(te,W).delete(Y).catch(we),S();}),H.onerror=an(A),H.onblocked=p._fireOnBlocked;}if(y)throw new j.InvalidArgument("Invalid closeOptions argument to db.delete()");w.isBeingOpened?w.dbReadyPromise.then(N):N();})},Mn.prototype.backendDB=function(){return this.idbdb},Mn.prototype.isOpen=function(){return this.idbdb!==null},Mn.prototype.hasBeenClosed=function(){var u=this._state.dbOpenError;return u&&u.name==="DatabaseClosed"},Mn.prototype.hasFailed=function(){return this._state.dbOpenError!==null},Mn.prototype.dynamicallyOpened=function(){return this._state.autoSchema},Object.defineProperty(Mn.prototype,"tables",{get:function(){var u=this;return i(this._allTables).map(function(p){return u._allTables[p]})},enumerable:false,configurable:true}),Mn.prototype.transaction=function(){var u=(function(p,y,w){var S=arguments.length;if(S<2)throw new j.InvalidArgument("Too few arguments");for(var A=new Array(S-1);--S;)A[S-1]=arguments[S];return w=A.pop(),[p,v(A),w]}).apply(this,arguments);return this._transaction.apply(this,u)},Mn.prototype._transaction=function(u,p,y){var w=this,S=ie.trans;S&&S.db===this&&u.indexOf("!")===-1||(S=null);var A,N,H=u.indexOf("?")!==-1;u=u.replace("!","").replace("?","");try{if(N=p.map(function(Y){if(Y=Y instanceof w.Table?Y.name:Y,typeof Y!="string")throw new TypeError("Invalid table argument to Dexie.transaction(). Only Table or String are allowed");return Y}),u=="r"||u===Br)A=Br;else {if(u!="rw"&&u!=Qr)throw new j.InvalidArgument("Invalid transaction mode: "+u);A=Qr;}if(S){if(S.mode===Br&&A===Qr){if(!H)throw new j.SubTransaction("Cannot enter a sub-transaction with READWRITE mode when parent transaction is READONLY");S=null;}S&&N.forEach(function(Y){if(S&&S.storeNames.indexOf(Y)===-1){if(!H)throw new j.SubTransaction("Table "+Y+" not included in parent transaction.");S=null;}}),H&&S&&!S.active&&(S=null);}}catch(Y){return S?S._promise(null,function(te,q){q(Y);}):Vt(Y)}var W=(function Y(te,q,ae,G,ee){return fe.resolve().then(function(){var oe=ie.transless||ie,Q=te._createTransaction(q,ae,te._dbSchema,G);if(Q.explicit=true,oe={trans:Q,transless:oe},G)Q.idbtrans=G.idbtrans;else try{Q.create(),Q.idbtrans._explicit=!0,te._state.PR1398_maxLoop=3;}catch(ye){return ye.name===X.InvalidState&&te.isOpen()&&0<--te._state.PR1398_maxLoop?(console.warn("Dexie: Need to reopen db"),te.close({disableAutoOpen:false}),te.open().then(function(){return Y(te,q,ae,null,ee)})):Vt(ye)}var de,me=z(ee);return me&&Lt(),oe=fe.follow(function(){var ye;(de=ee.call(Q,Q))&&(me?(ye=Mt.bind(null,null),de.then(ye,ye)):typeof de.next=="function"&&typeof de.throw=="function"&&(de=pc(de)));},oe),(de&&typeof de.then=="function"?fe.resolve(de).then(function(ye){return Q.active?ye:Vt(new j.PrematureCommit("Transaction committed too early. See http://bit.ly/2kdckMn"))}):oe.then(function(){return de})).then(function(ye){return G&&Q._resolve(),Q._completion.then(function(){return ye})}).catch(function(ye){return Q._reject(ye),Vt(ye)})})}).bind(null,this,A,N,S,y);return S?S._promise(A,W,"lock"):ie.trans?Qt(ie.transless,function(){return w._whenReady(W)}):this._whenReady(W)},Mn.prototype.table=function(u){if(!f(this._allTables,u))throw new j.InvalidTable("Table ".concat(u," does not exist"));return this._allTables[u]},Mn);function Mn(u,p){var y=this;this._middlewares={},this.verno=0;var w=Mn.dependencies;this._options=p=r({addons:Mn.addons,autoOpen:true,indexedDB:w.indexedDB,IDBKeyRange:w.IDBKeyRange,cache:"cloned"},p),this._deps={indexedDB:p.indexedDB,IDBKeyRange:p.IDBKeyRange},w=p.addons,this._dbSchema={},this._versions=[],this._storeNames=[],this._allTables={},this.idbdb=null,this._novip=this;var S,A,N,H,W,Y={dbOpenError:null,isBeingOpened:false,onReadyBeingFired:null,openComplete:false,dbReadyResolve:we,dbReadyPromise:null,cancelOpen:we,openCanceller:null,autoSchema:true,PR1398_maxLoop:3,autoOpen:p.autoOpen};Y.dbReadyPromise=new fe(function(q){Y.dbReadyResolve=q;}),Y.openCanceller=new fe(function(q,ae){Y.cancelOpen=ae;}),this._state=Y,this.name=u,this.on=Jr(this,"populate","blocked","versionchange","close",{ready:[Rt,we]}),this.on.ready.subscribe=M(this.on.ready.subscribe,function(q){return function(ae,G){Mn.vip(function(){var ee,oe=y._state;oe.openComplete?(oe.dbOpenError||fe.resolve().then(ae),G&&q(ae)):oe.onReadyBeingFired?(oe.onReadyBeingFired.push(ae),G&&q(ae)):(q(ae),ee=y,G||q(function Q(){ee.on.ready.unsubscribe(ae),ee.on.ready.unsubscribe(Q);}));});}}),this.Collection=(S=this,Cr(go.prototype,function(de,Q){this.db=S;var G=po,ee=null;if(Q)try{G=Q();}catch(me){ee=me;}var oe=de._ctx,Q=oe.table,de=Q.hook.reading.fire;this._ctx={table:Q,index:oe.index,isPrimKey:!oe.index||Q.schema.primKey.keyPath&&oe.index===Q.schema.primKey.name,range:G,keysOnly:false,dir:"next",unique:"",algorithm:null,filter:null,replayFilter:null,justLimit:true,isMatch:null,offset:0,limit:1/0,error:ee,or:oe.or,valueMapper:de!==Ye?de:null};})),this.Table=(A=this,Cr(cn.prototype,function(q,ae,G){this.db=A,this._tx=G,this.name=q,this.schema=ae,this.hook=A._allTables[q]?A._allTables[q].hook:Jr(null,{creating:[Tt,we],reading:[We,Ye],updating:[Wt,we],deleting:[jt,we]});})),this.Transaction=(N=this,Cr(ac.prototype,function(q,ae,G,ee,oe){var Q=this;this.db=N,this.mode=q,this.storeNames=ae,this.schema=G,this.chromeTransactionDurability=ee,this.idbtrans=null,this.on=Jr(this,"complete","error","abort"),this.parent=oe||null,this.active=true,this._reculock=0,this._blockedFuncs=[],this._resolve=null,this._reject=null,this._waitingFor=null,this._waitingQueue=null,this._spinCount=0,this._completion=new fe(function(de,me){Q._resolve=de,Q._reject=me;}),this._completion.then(function(){Q.active=false,Q.on.complete.fire();},function(de){var me=Q.active;return Q.active=false,Q.on.error.fire(de),Q.parent?Q.parent._reject(de):me&&Q.idbtrans&&Q.idbtrans.abort(),Vt(de)});})),this.Version=(H=this,Cr(fw.prototype,function(q){this.db=H,this._cfg={version:q,storesSource:null,dbschema:{},tables:{},contentUpgrade:null};})),this.WhereClause=(W=this,Cr(ps.prototype,function(q,ae,G){if(this.db=W,this._ctx={table:q,index:ae===":id"?null:ae,or:G},this._cmp=this._ascending=Et,this._descending=function(ee,oe){return Et(oe,ee)},this._max=function(ee,oe){return 0<Et(ee,oe)?ee:oe},this._min=function(ee,oe){return Et(ee,oe)<0?ee:oe},this._IDBKeyRange=W._deps.IDBKeyRange,!this._IDBKeyRange)throw new j.MissingAPI})),this.on("versionchange",function(q){0<q.newVersion?console.warn("Another connection wants to upgrade database '".concat(y.name,"'. Closing db now to resume the upgrade.")):console.warn("Another connection wants to delete database '".concat(y.name,"'. Closing db now to resume the delete request.")),y.close({disableAutoOpen:false});}),this.on("blocked",function(q){!q.newVersion||q.newVersion<q.oldVersion?console.warn("Dexie.delete('".concat(y.name,"') was blocked")):console.warn("Upgrade '".concat(y.name,"' blocked by other connection holding version ").concat(q.oldVersion/10));}),this._maxKey=Xo(p.IDBKeyRange),this._createTransaction=function(q,ae,G,ee){return new y.Transaction(q,ae,G,y._options.chromeTransactionDurability,ee)},this._fireOnBlocked=function(q){y.on("blocked").fire(q),kn.filter(function(ae){return ae.name===y.name&&ae!==y&&!ae._state.vcFired}).map(function(ae){return ae.on("versionchange").fire(q)});},this.use(gw),this.use(bw),this.use(yw),this.use(pw),this.use(mw);var te=new Proxy(this,{get:function(q,ae,G){if(ae==="_vip")return  true;if(ae==="table")return function(oe){return vs(y.table(oe),te)};var ee=Reflect.get(q,ae,G);return ee instanceof cn?vs(ee,te):ae==="tables"?ee.map(function(oe){return vs(oe,te)}):ae==="_createTransaction"?function(){return vs(ee.apply(this,arguments),te)}:ee}});this.vip=te,w.forEach(function(q){return q(y)});}var ks,yr=typeof Symbol<"u"&&"observable"in Symbol?Symbol.observable:"@@observable",vw=(_c.prototype.subscribe=function(u,p,y){return this._subscribe(u&&typeof u!="function"?u:{next:u,error:p,complete:y})},_c.prototype[yr]=function(){return this},_c);function _c(u){this._subscribe=u;}try{ks={indexedDB:a.indexedDB||a.mozIndexedDB||a.webkitIndexedDB||a.msIndexedDB,IDBKeyRange:a.IDBKeyRange||a.webkitIDBKeyRange};}catch{ks={indexedDB:null,IDBKeyRange:null};}function gf(u){var p,y=false,w=new vw(function(S){var A=z(u),N,H=false,W={},Y={},te={get closed(){return H},unsubscribe:function(){H||(H=true,N&&N.abort(),q&&Vn.storagemutated.unsubscribe(G));}};S.start&&S.start(te);var q=false,ae=function(){return mn(ee)},G=function(oe){_s(W,oe),uc(Y,W)&&ae();},ee=function(){var oe,Q,de;!H&&ks.indexedDB&&(W={},oe={},N&&N.abort(),N=new AbortController,de=(function(me){var ye=Dt();try{A&&Lt();var xe=nt(u,me);return xe=A?xe.finally(Mt):xe}finally{ye&&Re();}})(Q={subscr:oe,signal:N.signal,requery:ae,querier:u,trans:null}),Promise.resolve(de).then(function(me){y=true,p=me,H||Q.signal.aborted||(W={},(function(ye){for(var xe in ye)if(f(ye,xe))return;return 1})(Y=oe)||q||(Vn(Go,G),q=true),mn(function(){return !H&&S.next&&S.next(me)}));},function(me){y=false,["DatabaseClosedError","AbortError"].includes(me==null?void 0:me.name)||H||mn(function(){H||S.error&&S.error(me);});}));};return setTimeout(ae,0),te});return w.hasValue=function(){return y},w.getValue=function(){return p},w}var ta=to;function wc(u){var p=xo;try{xo=!0,Vn.storagemutated.fire(u),hc(u,!0);}finally{xo=p;}}m(ta,r(r({},_e),{delete:function(u){return new ta(u,{addons:[]}).delete()},exists:function(u){return new ta(u,{addons:[]}).open().then(function(p){return p.close(),true}).catch("NoSuchDatabaseError",function(){return  false})},getDatabaseNames:function(u){try{return p=ta.dependencies,y=p.indexedDB,p=p.IDBKeyRange,(sc(y)?Promise.resolve(y.databases()).then(function(w){return w.map(function(S){return S.name}).filter(function(S){return S!==xn})}):ic(y,p).toCollection().primaryKeys()).then(u)}catch{return Vt(new j.MissingAPI)}var p,y;},defineClass:function(){return function(u){l(this,u);}},ignoreTransaction:function(u){return ie.trans?Qt(ie.transless,u):u()},vip:lc,async:function(u){return function(){try{var p=pc(u.apply(this,arguments));return p&&typeof p.then=="function"?p:fe.resolve(p)}catch(y){return Vt(y)}}},spawn:function(u,p,y){try{var w=pc(u.apply(y,p||[]));return w&&typeof w.then=="function"?w:fe.resolve(w)}catch(S){return Vt(S)}},currentTransaction:{get:function(){return ie.trans||null}},waitFor:function(u,p){return p=fe.resolve(typeof u=="function"?ta.ignoreTransaction(u):u).timeout(p||6e4),ie.trans?ie.trans.waitFor(p):p},Promise:fe,debug:{get:function(){return et},set:function(u){at(u);}},derive:b,extend:l,props:m,override:M,Events:Jr,on:Vn,liveQuery:gf,extendObservabilitySet:_s,getByKeyPath:I,setByKeyPath:O,delByKeyPath:function(u,p){typeof p=="string"?O(u,p,void 0):"length"in p&&[].map.call(p,function(y){O(u,y,void 0);});},shallowClone:B,deepClone:Me,getObjectDiff:mc,cmp:Et,asap:F,minKey:-1/0,addons:[],connections:kn,errnames:X,dependencies:ks,cache:ea,semVer:"4.0.11",version:"4.0.11".split(".").map(function(u){return parseInt(u)}).reduce(function(u,p,y){return u+p/Math.pow(10,2*y)})})),ta.maxKey=Xo(ta.dependencies.IDBKeyRange),typeof dispatchEvent<"u"&&typeof addEventListener<"u"&&(Vn(Go,function(u){xo||(u=new CustomEvent(Yo,{detail:u}),xo=true,dispatchEvent(u),xo=false);}),addEventListener(Yo,function(u){u=u.detail,xo||wc(u);}));var Ma,xo=false,yf=function(){};return typeof BroadcastChannel<"u"&&((yf=function(){(Ma=new BroadcastChannel(Yo)).onmessage=function(u){return u.data&&wc(u.data)};})(),typeof Ma.unref=="function"&&Ma.unref(),Vn(Go,function(u){xo||Ma.postMessage(u);})),typeof addEventListener<"u"&&(addEventListener("pagehide",function(u){if(!to.disableBfCache&&u.persisted){et&&console.debug("Dexie: handling persisted pagehide"),Ma!=null&&Ma.close();for(var p=0,y=kn;p<y.length;p++)y[p].close({disableAutoOpen:false});}}),addEventListener("pageshow",function(u){!to.disableBfCache&&u.persisted&&(et&&console.debug("Dexie: handling persisted pageshow"),yf(),wc({all:new Yn(-1/0,[[]])}));})),fe.rejectionMapper=function(u,p){return !u||u instanceof Pe||u instanceof TypeError||u instanceof SyntaxError||!u.name||!se[u.name]?u:(p=new se[u.name](p||u.message,u),"stack"in u&&_(p,"stack",{get:function(){return this.inner.stack}}),p)},at(et),r(to,Object.freeze({__proto__:null,Dexie:to,liveQuery:gf,Entity:fs,cmp:Et,PropModification:ar,replacePrefix:function(u,p){return new ar({replacePrefix:[u,p]})},add:function(u){return new ar({add:u})},remove:function(u){return new ar({remove:u})},default:to,RangeSet:Yn,mergeRanges:yi,rangesOverlap:af}),{default:to}),to});})(el)),el.exports}var K0=z0();const zu=yg(K0),Fh=Symbol.for("Dexie"),On=globalThis[Fh]||(globalThis[Fh]=zu);if(zu.semVer!==On.semVer)throw new Error(`Two different versions of Dexie loaded in the same app: ${zu.semVer} and ${On.semVer}`);const{liveQuery:W0,mergeRanges:IA,rangesOverlap:EA,RangeSet:AA,cmp:DA,Entity:PA,PropModification:OA,replacePrefix:FA,add:LA,remove:NA}=On;var Lh={};/*! *****************************************************************************
  Copyright (c) Microsoft Corporation.

  Permission to use, copy, modify, and/or distribute this software for any
  purpose with or without fee is hereby granted.

  THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
  REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
  AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
  INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
  LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
  OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
  PERFORMANCE OF THIS SOFTWARE.
  ***************************************************************************** */var Cl=function(){return Cl=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a]);}return t},Cl.apply(this,arguments)};function Ho(e,t,n,r){function o(a){return a instanceof n?a:new n(function(i){i(a);})}return new(n||(n=Promise))(function(a,i){function s(h){try{c(r.next(h));}catch(f){i(f);}}function l(h){try{c(r.throw(h));}catch(f){i(f);}}function c(h){h.done?a(h.value):o(h.value).then(s,l);}c((r=r.apply(e,[])).next());})}function Or(e,t){var n={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},r,o,a,i;return i={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(i[Symbol.iterator]=function(){return this}),i;function s(c){return function(h){return l([c,h])}}function l(c){if(r)throw new TypeError("Generator is already executing.");for(;n;)try{if(r=1,o&&(a=c[0]&2?o.return:c[0]?o.throw||((a=o.return)&&a.call(o),0):o.next)&&!(a=a.call(o,c[1])).done)return a;switch(o=0,a&&(c=[c[0]&2,a.value]),c[0]){case 0:case 1:a=c;break;case 4:return n.label++,{value:c[1],done:!1};case 5:n.label++,o=c[1],c=[0];continue;case 7:c=n.ops.pop(),n.trys.pop();continue;default:if(a=n.trys,!(a=a.length>0&&a[a.length-1])&&(c[0]===6||c[0]===2)){n=0;continue}if(c[0]===3&&(!a||c[1]>a[0]&&c[1]<a[3])){n.label=c[1];break}if(c[0]===6&&n.label<a[1]){n.label=a[1],a=c;break}if(a&&n.label<a[2]){n.label=a[2],n.ops.push(c);break}a[2]&&n.ops.pop(),n.trys.pop();continue}c=t.call(e,n);}catch(h){c=[6,h],o=0;}finally{r=a=0;}if(c[0]&5)throw c[1];return {value:c[0]?c[1]:void 0,done:true}}}function G0(e){var t=[e.schema.primKey].concat(e.schema.indexes);return t.map(function(n){return n.src}).join(",")}function Y0(e){for(var t={},n=0,r=e.tables;n<r.length;n++){var o=r[n];t[o.name]=o.schema;}return t}function yy(e,t){return new Promise(function(n,r){var o=new FileReader;o.onabort=function(a){return r(new Error("file read aborted"))},o.onerror=function(a){return r(a.target.error)},o.onload=function(a){return n(a.target.result)},t==="binary"?o.readAsArrayBuffer(e):o.readAsText(e);})}function _y(e,t){if(typeof FileReaderSync>"u")throw new Error("FileReaderSync missing. Reading blobs synchronously requires code to run from within a web worker. Use TSON.encapsulateAsync() to do it from the main thread.");var n=new FileReaderSync,r=t==="binary"?n.readAsArrayBuffer(e):n.readAsText(e);return r}var Ku=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Od(e,t){return t={exports:{}},e(t,t.exports),t.exports}var Gl=Od(function(e,t){(function(n,r){e.exports=r();})(Ku,(function(){function n(X){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?n=function(ne){return typeof ne}:n=function(ne){return ne&&typeof Symbol=="function"&&ne.constructor===Symbol&&ne!==Symbol.prototype?"symbol":typeof ne},n(X)}function r(X,ne,j,se,_e,we,Ye){try{var We=X[we](Ye),Se=We.value;}catch(Tt){j(Tt);return}We.done?ne(Se):Promise.resolve(Se).then(se,_e);}function o(X){return function(){var ne=this,j=arguments;return new Promise(function(se,_e){var we=X.apply(ne,j);function Ye(Se){r(we,se,_e,Ye,We,"next",Se);}function We(Se){r(we,se,_e,Ye,We,"throw",Se);}Ye(void 0);})}}function a(X,ne){if(!(X instanceof ne))throw new TypeError("Cannot call a class as a function")}function i(X,ne){for(var j=0;j<ne.length;j++){var se=ne[j];se.enumerable=se.enumerable||false,se.configurable=true,"value"in se&&(se.writable=true),Object.defineProperty(X,se.key,se);}}function s(X,ne,j){return ne&&i(X.prototype,ne),X}function l(X,ne,j){return ne in X?Object.defineProperty(X,ne,{value:j,enumerable:true,configurable:true,writable:true}):X[ne]=j,X}function c(X,ne){var j=Object.keys(X);if(Object.getOwnPropertySymbols){var se=Object.getOwnPropertySymbols(X);ne&&(se=se.filter(function(_e){return Object.getOwnPropertyDescriptor(X,_e).enumerable})),j.push.apply(j,se);}return j}function h(X){for(var ne=1;ne<arguments.length;ne++){var j=arguments[ne]!=null?arguments[ne]:{};ne%2?c(Object(j),true).forEach(function(se){l(X,se,j[se]);}):Object.getOwnPropertyDescriptors?Object.defineProperties(X,Object.getOwnPropertyDescriptors(j)):c(Object(j)).forEach(function(se){Object.defineProperty(X,se,Object.getOwnPropertyDescriptor(j,se));});}return X}function f(X,ne){return _(X)||C(X,ne)||T()}function m(X){return g(X)||b(X)||k()}function g(X){if(Array.isArray(X)){for(var ne=0,j=new Array(X.length);ne<X.length;ne++)j[ne]=X[ne];return j}}function _(X){if(Array.isArray(X))return X}function b(X){if(Symbol.iterator in Object(X)||Object.prototype.toString.call(X)==="[object Arguments]")return Array.from(X)}function C(X,ne){if(Symbol.iterator in Object(X)||Object.prototype.toString.call(X)==="[object Arguments]"){var j=[],se=true,_e=false,we=void 0;try{for(var Ye=X[Symbol.iterator](),We;!(se=(We=Ye.next()).done)&&(j.push(We.value),!(ne&&j.length===ne));se=!0);}catch(Se){_e=true,we=Se;}finally{try{!se&&Ye.return!=null&&Ye.return();}finally{if(_e)throw we}}return j}}function k(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function T(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}var M=function X(ne){a(this,X),this.p=new Promise(ne);};M.__typeson__type__="TypesonPromise",typeof Symbol<"u"&&(M.prototype[Symbol.toStringTag]="TypesonPromise"),M.prototype.then=function(X,ne){var j=this;return new M(function(se,_e){j.p.then(function(we){se(X?X(we):we);}).catch(function(we){return ne?ne(we):Promise.reject(we)}).then(se,_e);})},M.prototype.catch=function(X){return this.then(null,X)},M.resolve=function(X){return new M(function(ne){ne(X);})},M.reject=function(X){return new M(function(ne,j){j(X);})},["all","race"].forEach(function(X){M[X]=function(ne){return new M(function(j,se){Promise[X](ne.map(function(_e){return _e&&_e.constructor&&_e.constructor.__typeson__type__==="TypesonPromise"?_e.p:_e})).then(j,se);})};});var P={},F=P.toString,I={}.hasOwnProperty,O=Object.getPrototypeOf,B=I.toString;function D(X,ne){return Z(X)&&typeof X.then=="function"&&(!ne||typeof X.catch=="function")}function v(X){return F.call(X).slice(8,-1)}function L(X,ne){if(!X||n(X)!=="object")return  false;var j=O(X);if(!j)return ne===null;var se=I.call(j,"constructor")&&j.constructor;return typeof se!="function"?ne===null:ne===se||ne!==null&&B.call(se)===B.call(ne)||typeof ne=="function"&&typeof se.__typeson__type__=="string"&&se.__typeson__type__===ne.__typeson__type__}function $(X){if(!X||v(X)!=="Object")return  false;var ne=O(X);return ne?L(X,Object):true}function Me(X){if(!X||v(X)!=="Object")return  false;var ne=O(X);return ne?L(X,Object)||Me(ne):true}function Z(X){return X&&n(X)==="object"}function re(X){return X.replace(/~/g,"~0").replace(/\./g,"~1")}function J(X){return X.replace(/~1/g,".").replace(/~0/g,"~")}function le(X,ne){if(ne==="")return X;var j=ne.indexOf(".");if(j>-1){var se=X[J(ne.slice(0,j))];return se===void 0?void 0:le(se,ne.slice(j+1))}return X[J(ne)]}function he(X,ne,j){if(ne==="")return j;var se=ne.indexOf(".");if(se>-1){var _e=X[J(ne.slice(0,se))];return he(_e,ne.slice(se+1),j)}return X[J(ne)]=j,X}function pe(X){return X===null?"null":Array.isArray(X)?"array":n(X)}var ge=Object.keys,z=Array.isArray,ue={}.hasOwnProperty,Pe=["type","replaced","iterateIn","iterateUnsetNumeric"];function ce(X,ne){if(X.keypath==="")return  -1;var j=X.keypath.match(/\./g)||0,se=ne.keypath.match(/\./g)||0;return j&&(j=j.length),se&&(se=se.length),j>se?-1:j<se?1:X.keypath<ne.keypath?-1:X.keypath>ne.keypath}var Ee=(function(){function X(ne){a(this,X),this.options=ne,this.plainObjectReplacers=[],this.nonplainObjectReplacers=[],this.revivers={},this.types={};}return s(X,[{key:"stringify",value:function(j,se,_e,we){we=h({},this.options,{},we,{stringification:true});var Ye=this.encapsulate(j,null,we);return z(Ye)?JSON.stringify(Ye[0],se,_e):Ye.then(function(We){return JSON.stringify(We,se,_e)})}},{key:"stringifySync",value:function(j,se,_e,we){return this.stringify(j,se,_e,h({throwOnBadSyncType:true},we,{sync:true}))}},{key:"stringifyAsync",value:function(j,se,_e,we){return this.stringify(j,se,_e,h({throwOnBadSyncType:true},we,{sync:false}))}},{key:"parse",value:function(j,se,_e){return _e=h({},this.options,{},_e,{parse:true}),this.revive(JSON.parse(j,se),_e)}},{key:"parseSync",value:function(j,se,_e){return this.parse(j,se,h({throwOnBadSyncType:true},_e,{sync:true}))}},{key:"parseAsync",value:function(j,se,_e){return this.parse(j,se,h({throwOnBadSyncType:true},_e,{sync:false}))}},{key:"specialTypeNames",value:function(j,se){var _e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return _e.returnTypeNames=true,this.encapsulate(j,se,_e)}},{key:"rootTypeName",value:function(j,se){var _e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return _e.iterateNone=true,this.encapsulate(j,se,_e)}},{key:"encapsulate",value:function(j,se,_e){_e=h({sync:true},this.options,{},_e);var we=_e,Ye=we.sync,We=this,Se={},Tt=[],jt=[],Wt=[],Gt="cyclic"in _e?_e.cyclic:true,Rt=_e,et=Rt.encapsulateObserver,at=yt("",j,Gt,se||{},Wt);function wt(ke){var E=Object.values(Se);if(_e.iterateNone)return E.length?E[0]:X.getJSONType(ke);if(E.length){if(_e.returnTypeNames)return m(new Set(E));!ke||!$(ke)||ue.call(ke,"$types")?ke={$:ke,$types:{$:Se}}:ke.$types=Se;}else Z(ke)&&ue.call(ke,"$types")&&(ke={$:ke,$types:true});return _e.returnTypeNames?false:ke}function Ce(ke,E){return ht.apply(this,arguments)}function ht(){return ht=o(regeneratorRuntime.mark(function ke(E,x){var R;return regeneratorRuntime.wrap(function(V){for(;;)switch(V.prev=V.next){case 0:return V.next=2,Promise.all(x.map(function(be){return be[1].p}));case 2:return R=V.sent,V.next=5,Promise.all(R.map((function(){var be=o(regeneratorRuntime.mark(function ie(Le){var Ne,tt,fe,Ve,pt,St,vt,Yt,K,ze,Dt,Re,Fe,rt;return regeneratorRuntime.wrap(function(st){for(;;)switch(st.prev=st.next){case 0:if(Ne=[],tt=x.splice(0,1),fe=f(tt,1),Ve=fe[0],pt=f(Ve,7),St=pt[0],vt=pt[2],Yt=pt[3],K=pt[4],ze=pt[5],Dt=pt[6],Re=yt(St,Le,vt,Yt,Ne,true,Dt),Fe=L(Re,M),!(St&&Fe)){st.next=11;break}return st.next=8,Re.p;case 8:return rt=st.sent,K[ze]=rt,st.abrupt("return",Ce(E,Ne));case 11:return St?K[ze]=Re:Fe?E=Re.p:E=Re,st.abrupt("return",Ce(E,Ne));case 13:case "end":return st.stop()}},ie)}));return function(ie){return be.apply(this,arguments)}})()));case 5:return V.abrupt("return",E);case 6:case "end":return V.stop()}},ke)})),ht.apply(this,arguments)}function it(ke,E,x){Object.assign(ke,E);var R=Pe.map(function(U){var V=ke[U];return delete ke[U],V});x(),Pe.forEach(function(U,V){ke[U]=R[V];});}function yt(ke,E,x,R,U,V,be){var ie,Le={},Ne=n(E),tt=et?function(Fe){var rt=be||R.type||X.getJSONType(E);et(Object.assign(Fe||Le,{keypath:ke,value:E,cyclic:x,stateObj:R,promisesData:U,resolvingTypesonPromise:V,awaitingTypesonPromise:L(E,M)},{type:rt}));}:null;if(["string","boolean","number","undefined"].includes(Ne))return E===void 0||Ne==="number"&&(isNaN(E)||E===-1/0||E===1/0)?(R.replaced?ie=E:ie=Oe(ke,E,R,U,false,V,tt),ie!==E&&(Le={replaced:ie})):ie=E,tt&&tt(),ie;if(E===null)return tt&&tt(),E;if(x&&!R.iterateIn&&!R.iterateUnsetNumeric&&E&&n(E)==="object"){var fe=Tt.indexOf(E);if(fe<0)x===true&&(Tt.push(E),jt.push(ke));else return Se[ke]="#",tt&&tt({cyclicKeypath:jt[fe]}),"#"+jt[fe]}var Ve=$(E),pt=z(E),St=(Ve||pt)&&(!We.plainObjectReplacers.length||R.replaced)||R.iterateIn?E:Oe(ke,E,R,U,Ve||pt,null,tt),vt;if(St!==E?(ie=St,Le={replaced:St}):ke===""&&L(E,M)?(U.push([ke,E,x,R,void 0,void 0,R.type]),ie=E):pt&&R.iterateIn!=="object"||R.iterateIn==="array"?(vt=new Array(E.length),Le={clone:vt}):!["function","symbol"].includes(n(E))&&!("toJSON"in E)&&!L(E,M)&&!L(E,Promise)&&!L(E,ArrayBuffer)||Ve||R.iterateIn==="object"?(vt={},R.addLength&&(vt.length=E.length),Le={clone:vt}):ie=E,tt&&tt(),_e.iterateNone)return vt||ie;if(!vt)return ie;if(R.iterateIn){var Yt=function(rt){var Ue={ownKeys:ue.call(E,rt)};it(R,Ue,function(){var st=ke+(ke?".":"")+re(rt),Ut=yt(st,E[rt],!!x,R,U,V);L(Ut,M)?U.push([st,Ut,!!x,R,vt,rt,R.type]):Ut!==void 0&&(vt[rt]=Ut);});};for(var K in E)Yt(K);tt&&tt({endIterateIn:true,end:true});}else ge(E).forEach(function(Fe){var rt=ke+(ke?".":"")+re(Fe),Ue={ownKeys:true};it(R,Ue,function(){var st=yt(rt,E[Fe],!!x,R,U,V);L(st,M)?U.push([rt,st,!!x,R,vt,Fe,R.type]):st!==void 0&&(vt[Fe]=st);});}),tt&&tt({endIterateOwn:true,end:true});if(R.iterateUnsetNumeric){for(var ze=E.length,Dt=function(rt){if(!(rt in E)){var Ue=ke+(ke?".":"")+rt,st={ownKeys:false};it(R,st,function(){var Ut=yt(Ue,void 0,!!x,R,U,V);L(Ut,M)?U.push([Ue,Ut,!!x,R,vt,rt,R.type]):Ut!==void 0&&(vt[rt]=Ut);});}},Re=0;Re<ze;Re++)Dt(Re);tt&&tt({endIterateUnsetNumeric:true,end:true});}return vt}function Oe(ke,E,x,R,U,V,be){for(var ie=U?We.plainObjectReplacers:We.nonplainObjectReplacers,Le=ie.length;Le--;){var Ne=ie[Le];if(Ne.test(E,x)){var tt=Ne.type;if(We.revivers[tt]){var fe=Se[ke];Se[ke]=fe?[tt].concat(fe):tt;}if(Object.assign(x,{type:tt,replaced:true}),(Ye||!Ne.replaceAsync)&&!Ne.replace)return be&&be({typeDetected:true}),yt(ke,E,Gt&&"readonly",x,R,V,tt);be&&be({replacing:true});var Ve=Ye||!Ne.replaceAsync?"replace":"replaceAsync";return yt(ke,Ne[Ve](E,x),Gt&&"readonly",x,R,V,tt)}}return E}return Wt.length?Ye&&_e.throwOnBadSyncType?(function(){throw new TypeError("Sync method requested but async result obtained")})():Promise.resolve(Ce(at,Wt)).then(wt):!Ye&&_e.throwOnBadSyncType?(function(){throw new TypeError("Async method requested but sync result obtained")})():_e.stringification&&Ye?[wt(at)]:Ye?wt(at):Promise.resolve(wt(at))}},{key:"encapsulateSync",value:function(j,se,_e){return this.encapsulate(j,se,h({throwOnBadSyncType:true},_e,{sync:true}))}},{key:"encapsulateAsync",value:function(j,se,_e){return this.encapsulate(j,se,h({throwOnBadSyncType:true},_e,{sync:false}))}},{key:"revive",value:function(j,se){var _e=j&&j.$types;if(!_e)return j;if(_e===true)return j.$;se=h({sync:true},this.options,{},se);var we=se,Ye=we.sync,We=[],Se={},Tt=true;_e.$&&$(_e.$)&&(j=j.$,_e=_e.$,Tt=false);var jt=this;function Wt(ht,it){var yt=jt.revivers[ht]||[],Oe=f(yt,1),ke=Oe[0];if(!ke)throw new Error("Unregistered type: "+ht);return Ye&&!("revive"in ke)?it:ke[Ye&&ke.revive?"revive":!Ye&&ke.reviveAsync?"reviveAsync":"revive"](it,Se)}function Gt(){var ht=[];if(Object.entries(_e).forEach(function(it){var yt=f(it,2),Oe=yt[0],ke=yt[1];ke!=="#"&&[].concat(ke).forEach(function(E){var x=jt.revivers[E]||[null,{}],R=f(x,2),U=R[1].plain;U&&(ht.push({keypath:Oe,type:E}),delete _e[Oe]);});}),!!ht.length)return ht.sort(ce).reduce(function it(yt,Oe){var ke=Oe.keypath,E=Oe.type;if(D(yt))return yt.then(function(U){return it(U,{keypath:ke,type:E})});var x=le(j,ke);if(x=Wt(E,x),L(x,M))return x.then(function(U){var V=he(j,ke,U);V===U&&(j=V);});var R=he(j,ke,x);R===x&&(j=R);},void 0)}var Rt=[];function et(ht,it,yt,Oe,ke){if(!(Tt&&ht==="$types")){var E=_e[ht],x=z(it);if(x||$(it)){var R=x?new Array(it.length):{};for(ge(it).forEach(function(fe){var Ve=et(ht+(ht?".":"")+re(fe),it[fe],yt||R,R,fe),pt=function(vt){return L(vt,Qe)?R[fe]=void 0:vt!==void 0&&(R[fe]=vt),vt};L(Ve,M)?Rt.push(Ve.then(function(St){return pt(St)})):pt(Ve);}),it=R;We.length;){var U=f(We[0],4),V=U[0],be=U[1],ie=U[2],Le=U[3],Ne=le(V,be);if(Ne!==void 0)ie[Le]=Ne;else break;We.splice(0,1);}}if(!E)return it;if(E==="#"){var tt=le(yt,it.slice(1));return tt===void 0&&We.push([yt,it.slice(1),Oe,ke]),tt}return [].concat(E).reduce(function fe(Ve,pt){return L(Ve,M)?Ve.then(function(St){return fe(St,pt)}):Wt(pt,Ve)},it)}}function at(ht){return L(ht,Qe)?void 0:ht}var wt=Gt(),Ce;return L(wt,M)?Ce=wt.then(function(){return j}):(Ce=et("",j,null),Rt.length&&(Ce=M.resolve(Ce).then(function(ht){return M.all([ht].concat(Rt))}).then(function(ht){var it=f(ht,1),yt=it[0];return yt}))),D(Ce)?Ye&&se.throwOnBadSyncType?(function(){throw new TypeError("Sync method requested but async result obtained")})():L(Ce,M)?Ce.p.then(at):Ce:!Ye&&se.throwOnBadSyncType?(function(){throw new TypeError("Async method requested but sync result obtained")})():Ye?at(Ce):Promise.resolve(at(Ce))}},{key:"reviveSync",value:function(j,se){return this.revive(j,h({throwOnBadSyncType:true},se,{sync:true}))}},{key:"reviveAsync",value:function(j,se){return this.revive(j,h({throwOnBadSyncType:true},se,{sync:false}))}},{key:"register",value:function(j,se){return se=se||{},[].concat(j).forEach(function _e(we){var Ye=this;if(z(we))return we.map(function(We){return _e.call(Ye,We)});we&&ge(we).forEach(function(We){if(We==="#")throw new TypeError("# cannot be used as a type name as it is reserved for cyclic objects");if(X.JSON_TYPES.includes(We))throw new TypeError("Plain JSON object types are reserved as type names");var Se=we[We],Tt=Se&&Se.testPlainObjects?this.plainObjectReplacers:this.nonplainObjectReplacers,jt=Tt.filter(function(yt){return yt.type===We});if(jt.length&&(Tt.splice(Tt.indexOf(jt[0]),1),delete this.revivers[We],delete this.types[We]),typeof Se=="function"){var Wt=Se;Se={test:function(Oe){return Oe&&Oe.constructor===Wt},replace:function(Oe){return h({},Oe)},revive:function(Oe){return Object.assign(Object.create(Wt.prototype),Oe)}};}else if(z(Se)){var Gt=Se,Rt=f(Gt,3),et=Rt[0],at=Rt[1],wt=Rt[2];Se={test:et,replace:at,revive:wt};}if(!(!Se||!Se.test)){var Ce={type:We,test:Se.test.bind(Se)};Se.replace&&(Ce.replace=Se.replace.bind(Se)),Se.replaceAsync&&(Ce.replaceAsync=Se.replaceAsync.bind(Se));var ht=typeof se.fallback=="number"?se.fallback:se.fallback?0:1/0;if(Se.testPlainObjects?this.plainObjectReplacers.splice(ht,0,Ce):this.nonplainObjectReplacers.splice(ht,0,Ce),Se.revive||Se.reviveAsync){var it={};Se.revive&&(it.revive=Se.revive.bind(Se)),Se.reviveAsync&&(it.reviveAsync=Se.reviveAsync.bind(Se)),this.revivers[We]=[it,{plain:Se.testPlainObjects}];}this.types[We]=Se;}},this);},this),this}}]),X})(),Qe=function X(){a(this,X);};return Qe.__typeson__type__="TypesonUndefined",Ee.Undefined=Qe,Ee.Promise=M,Ee.isThenable=D,Ee.toStringTag=v,Ee.hasConstructorOf=L,Ee.isObject=Z,Ee.isPlainObject=$,Ee.isUserObject=Me,Ee.escapeKeyPathComponent=re,Ee.unescapeKeyPathComponent=J,Ee.getByKeyPath=le,Ee.getJSONType=pe,Ee.JSON_TYPES=["null","boolean","number","string","array","object"],Ee}));}),X0=Od(function(e,t){(function(n,r){e.exports=r();})(Ku,(function(){function n(E){return (n=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(x){return typeof x}:function(x){return x&&typeof Symbol=="function"&&x.constructor===Symbol&&x!==Symbol.prototype?"symbol":typeof x})(E)}function r(E,x){if(!(E instanceof x))throw new TypeError("Cannot call a class as a function")}function o(E,x){for(var R=0;R<x.length;R++){var U=x[R];U.enumerable=U.enumerable||false,U.configurable=true,"value"in U&&(U.writable=true),Object.defineProperty(E,U.key,U);}}function a(E,x,R){return x in E?Object.defineProperty(E,x,{value:R,enumerable:true,configurable:true,writable:true}):E[x]=R,E}function i(E,x){var R=Object.keys(E);if(Object.getOwnPropertySymbols){var U=Object.getOwnPropertySymbols(E);x&&(U=U.filter((function(V){return Object.getOwnPropertyDescriptor(E,V).enumerable}))),R.push.apply(R,U);}return R}function s(E){return (function(R){if(Array.isArray(R))return l(R)})(E)||(function(R){if(typeof Symbol<"u"&&Symbol.iterator in Object(R))return Array.from(R)})(E)||(function(R,U){if(R){if(typeof R=="string")return l(R,U);var V=Object.prototype.toString.call(R).slice(8,-1);if(V==="Object"&&R.constructor&&(V=R.constructor.name),V==="Map"||V==="Set")return Array.from(R);if(V==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(V))return l(R,U)}})(E)||(function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function l(E,x){(x==null||x>E.length)&&(x=E.length);for(var R=0,U=new Array(x);R<x;R++)U[R]=E[R];return U}function c(E){return (c=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(R){return typeof R}:function(R){return R&&typeof Symbol=="function"&&R.constructor===Symbol&&R!==Symbol.prototype?"symbol":typeof R})(E)}function h(E,x){if(!(E instanceof x))throw new TypeError("Cannot call a class as a function")}function f(E,x){for(var R=0;R<x.length;R++){var U=x[R];U.enumerable=U.enumerable||false,U.configurable=true,"value"in U&&(U.writable=true),Object.defineProperty(E,U.key,U);}}function m(E,x,R){return x in E?Object.defineProperty(E,x,{value:R,enumerable:true,configurable:true,writable:true}):E[x]=R,E}function g(E,x){var R=Object.keys(E);if(Object.getOwnPropertySymbols){var U=Object.getOwnPropertySymbols(E);x&&(U=U.filter((function(V){return Object.getOwnPropertyDescriptor(E,V).enumerable}))),R.push.apply(R,U);}return R}function _(E){for(var x=1;x<arguments.length;x++){var R=arguments[x]!=null?arguments[x]:{};x%2?g(Object(R),true).forEach((function(U){m(E,U,R[U]);})):Object.getOwnPropertyDescriptors?Object.defineProperties(E,Object.getOwnPropertyDescriptors(R)):g(Object(R)).forEach((function(U){Object.defineProperty(E,U,Object.getOwnPropertyDescriptor(R,U));}));}return E}function b(E,x){return (function(U){if(Array.isArray(U))return U})(E)||(function(U,V){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(U)))){var be=[],ie=true,Le=false,Ne=void 0;try{for(var tt,fe=U[Symbol.iterator]();!(ie=(tt=fe.next()).done)&&(be.push(tt.value),!V||be.length!==V);ie=!0);}catch(Ve){Le=true,Ne=Ve;}finally{try{ie||fe.return==null||fe.return();}finally{if(Le)throw Ne}}return be}})(E,x)||k(E,x)||(function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function C(E){return (function(R){if(Array.isArray(R))return T(R)})(E)||(function(R){if(typeof Symbol<"u"&&Symbol.iterator in Object(R))return Array.from(R)})(E)||k(E)||(function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function k(E,x){if(E){if(typeof E=="string")return T(E,x);var R=Object.prototype.toString.call(E).slice(8,-1);return R==="Object"&&E.constructor&&(R=E.constructor.name),R==="Map"||R==="Set"?Array.from(E):R==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(R)?T(E,x):void 0}}function T(E,x){(x==null||x>E.length)&&(x=E.length);for(var R=0,U=new Array(x);R<x;R++)U[R]=E[R];return U}var M=function E(x){h(this,E),this.p=new Promise(x);};M.__typeson__type__="TypesonPromise",typeof Symbol<"u"&&(M.prototype[Symbol.toStringTag]="TypesonPromise"),M.prototype.then=function(E,x){var R=this;return new M((function(U,V){R.p.then((function(be){U(E?E(be):be);})).catch((function(be){return x?x(be):Promise.reject(be)})).then(U,V);}))},M.prototype.catch=function(E){return this.then(null,E)},M.resolve=function(E){return new M((function(x){x(E);}))},M.reject=function(E){return new M((function(x,R){R(E);}))},["all","race"].forEach((function(E){M[E]=function(x){return new M((function(R,U){Promise[E](x.map((function(V){return V&&V.constructor&&V.constructor.__typeson__type__==="TypesonPromise"?V.p:V}))).then(R,U);}))};}));var P={}.toString,F={}.hasOwnProperty,I=Object.getPrototypeOf,O=F.toString;function B(E,x){return $(E)&&typeof E.then=="function"&&(!x||typeof E.catch=="function")}function D(E){return P.call(E).slice(8,-1)}function v(E,x){if(!E||c(E)!=="object")return  false;var R=I(E);if(!R)return x===null;var U=F.call(R,"constructor")&&R.constructor;return typeof U!="function"?x===null:x===U||x!==null&&O.call(U)===O.call(x)||typeof x=="function"&&typeof U.__typeson__type__=="string"&&U.__typeson__type__===x.__typeson__type__}function L(E){return !(!E||D(E)!=="Object")&&(!I(E)||v(E,Object))}function $(E){return E&&c(E)==="object"}function Me(E){return E.replace(/~/g,"~0").replace(/\./g,"~1")}function Z(E){return E.replace(/~1/g,".").replace(/~0/g,"~")}function re(E,x){if(x==="")return E;var R=x.indexOf(".");if(R>-1){var U=E[Z(x.slice(0,R))];return U===void 0?void 0:re(U,x.slice(R+1))}return E[Z(x)]}function J(E,x,R){if(x==="")return R;var U=x.indexOf(".");return U>-1?J(E[Z(x.slice(0,U))],x.slice(U+1),R):(E[Z(x)]=R,E)}function le(E,x,R){return R?x?x(E):E:(E&&E.then||(E=Promise.resolve(E)),x?E.then(x):E)}var he=Object.keys,pe=Array.isArray,ge={}.hasOwnProperty,z=["type","replaced","iterateIn","iterateUnsetNumeric"];function ue(E){return function(){for(var x=[],R=0;R<arguments.length;R++)x[R]=arguments[R];try{return Promise.resolve(E.apply(this,x))}catch(U){return Promise.reject(U)}}}function Pe(E,x){if(E.keypath==="")return  -1;var R=E.keypath.match(/\./g)||0,U=x.keypath.match(/\./g)||0;return R&&(R=R.length),U&&(U=U.length),R>U?-1:R<U?1:E.keypath<x.keypath?-1:E.keypath>x.keypath}var ce=(function(){function E(x){h(this,E),this.options=x,this.plainObjectReplacers=[],this.nonplainObjectReplacers=[],this.revivers={},this.types={};}return (function(R,U,V){return U&&f(R.prototype,U),R})(E,[{key:"stringify",value:function(R,U,V,be){be=_(_(_({},this.options),be),{},{stringification:true});var ie=this.encapsulate(R,null,be);return pe(ie)?JSON.stringify(ie[0],U,V):ie.then((function(Le){return JSON.stringify(Le,U,V)}))}},{key:"stringifySync",value:function(R,U,V,be){return this.stringify(R,U,V,_(_({throwOnBadSyncType:true},be),{},{sync:true}))}},{key:"stringifyAsync",value:function(R,U,V,be){return this.stringify(R,U,V,_(_({throwOnBadSyncType:true},be),{},{sync:false}))}},{key:"parse",value:function(R,U,V){return V=_(_(_({},this.options),V),{},{parse:true}),this.revive(JSON.parse(R,U),V)}},{key:"parseSync",value:function(R,U,V){return this.parse(R,U,_(_({throwOnBadSyncType:true},V),{},{sync:true}))}},{key:"parseAsync",value:function(R,U,V){return this.parse(R,U,_(_({throwOnBadSyncType:true},V),{},{sync:false}))}},{key:"specialTypeNames",value:function(R,U){var V=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return V.returnTypeNames=true,this.encapsulate(R,U,V)}},{key:"rootTypeName",value:function(R,U){var V=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return V.iterateNone=true,this.encapsulate(R,U,V)}},{key:"encapsulate",value:function(R,U,V){var be=ue((function(Re,Fe){return le(Promise.all(Fe.map((function(rt){return rt[1].p}))),(function(rt){return le(Promise.all(rt.map(ue((function(Ue){var st=false,Ut=[],ln=b(Fe.splice(0,1),1),Te=b(ln[0],7),Ae=Te[0],At=Te[2],nt=Te[3],Lt=Te[4],Mt=Te[5],lt=Te[6],kt=ze(Ae,Ue,At,nt,Ut,true,lt),ft=v(kt,M);return (function(Qt,In){var mn=Qt();return mn&&mn.then?mn.then(In):In(mn)})((function(){if(Ae&&ft)return le(kt.p,(function(Xt){return Lt[Mt]=Xt,st=true,be(Re,Ut)}))}),(function(Xt){return st?Xt:(Ae?Lt[Mt]=kt:Re=ft?kt.p:kt,be(Re,Ut))}))})))),(function(){return Re}))}))})),ie=(V=_(_({sync:true},this.options),V)).sync,Le=this,Ne={},tt=[],fe=[],Ve=[],pt=!("cyclic"in V)||V.cyclic,St=V.encapsulateObserver,vt=ze("",R,pt,U||{},Ve);function Yt(Re){var Fe=Object.values(Ne);if(V.iterateNone)return Fe.length?Fe[0]:E.getJSONType(Re);if(Fe.length){if(V.returnTypeNames)return C(new Set(Fe));Re&&L(Re)&&!ge.call(Re,"$types")?Re.$types=Ne:Re={$:Re,$types:{$:Ne}};}else $(Re)&&ge.call(Re,"$types")&&(Re={$:Re,$types:true});return !V.returnTypeNames&&Re}function K(Re,Fe,rt){Object.assign(Re,Fe);var Ue=z.map((function(st){var Ut=Re[st];return delete Re[st],Ut}));rt(),z.forEach((function(st,Ut){Re[st]=Ue[Ut];}));}function ze(Re,Fe,rt,Ue,st,Ut,ln){var Te,Ae={},At=c(Fe),nt=St?function(dn){var nn=ln||Ue.type||E.getJSONType(Fe);St(Object.assign(dn||Ae,{keypath:Re,value:Fe,cyclic:rt,stateObj:Ue,promisesData:st,resolvingTypesonPromise:Ut,awaitingTypesonPromise:v(Fe,M)},{type:nn}));}:null;if(["string","boolean","number","undefined"].includes(At))return Fe===void 0||Number.isNaN(Fe)||Fe===Number.NEGATIVE_INFINITY||Fe===Number.POSITIVE_INFINITY?(Te=Ue.replaced?Fe:Dt(Re,Fe,Ue,st,false,Ut,nt))!==Fe&&(Ae={replaced:Te}):Te=Fe,nt&&nt(),Te;if(Fe===null)return nt&&nt(),Fe;if(rt&&!Ue.iterateIn&&!Ue.iterateUnsetNumeric&&Fe&&c(Fe)==="object"){var Lt=tt.indexOf(Fe);if(!(Lt<0))return Ne[Re]="#",nt&&nt({cyclicKeypath:fe[Lt]}),"#"+fe[Lt];rt===true&&(tt.push(Fe),fe.push(Re));}var Mt,lt=L(Fe),kt=pe(Fe),ft=(lt||kt)&&(!Le.plainObjectReplacers.length||Ue.replaced)||Ue.iterateIn?Fe:Dt(Re,Fe,Ue,st,lt||kt,null,nt);if(ft!==Fe?(Te=ft,Ae={replaced:ft}):Re===""&&v(Fe,M)?(st.push([Re,Fe,rt,Ue,void 0,void 0,Ue.type]),Te=Fe):kt&&Ue.iterateIn!=="object"||Ue.iterateIn==="array"?(Mt=new Array(Fe.length),Ae={clone:Mt}):(["function","symbol"].includes(c(Fe))||"toJSON"in Fe||v(Fe,M)||v(Fe,Promise)||v(Fe,ArrayBuffer))&&!lt&&Ue.iterateIn!=="object"?Te=Fe:(Mt={},Ue.addLength&&(Mt.length=Fe.length),Ae={clone:Mt}),nt&&nt(),V.iterateNone)return Mt||Te;if(!Mt)return Te;if(Ue.iterateIn){var Xt=function(nn){var en={ownKeys:ge.call(Fe,nn)};K(Ue,en,(function(){var kn=Re+(Re?".":"")+Me(nn),xn=ze(kn,Fe[nn],!!rt,Ue,st,Ut);v(xn,M)?st.push([kn,xn,!!rt,Ue,Mt,nn,Ue.type]):xn!==void 0&&(Mt[nn]=xn);}));};for(var Qt in Fe)Xt(Qt);nt&&nt({endIterateIn:true,end:true});}else he(Fe).forEach((function(dn){var nn=Re+(Re?".":"")+Me(dn);K(Ue,{ownKeys:true},(function(){var en=ze(nn,Fe[dn],!!rt,Ue,st,Ut);v(en,M)?st.push([nn,en,!!rt,Ue,Mt,dn,Ue.type]):en!==void 0&&(Mt[dn]=en);}));})),nt&&nt({endIterateOwn:true,end:true});if(Ue.iterateUnsetNumeric){for(var In=Fe.length,mn=function(nn){if(!(nn in Fe)){var en=Re+(Re?".":"")+nn;K(Ue,{ownKeys:false},(function(){var kn=ze(en,void 0,!!rt,Ue,st,Ut);v(kn,M)?st.push([en,kn,!!rt,Ue,Mt,nn,Ue.type]):kn!==void 0&&(Mt[nn]=kn);}));}},Vt=0;Vt<In;Vt++)mn(Vt);nt&&nt({endIterateUnsetNumeric:true,end:true});}return Mt}function Dt(Re,Fe,rt,Ue,st,Ut,ln){for(var Te=st?Le.plainObjectReplacers:Le.nonplainObjectReplacers,Ae=Te.length;Ae--;){var At=Te[Ae];if(At.test(Fe,rt)){var nt=At.type;if(Le.revivers[nt]){var Lt=Ne[Re];Ne[Re]=Lt?[nt].concat(Lt):nt;}return Object.assign(rt,{type:nt,replaced:true}),!ie&&At.replaceAsync||At.replace?(ln&&ln({replacing:true}),ze(Re,At[ie||!At.replaceAsync?"replace":"replaceAsync"](Fe,rt),pt&&"readonly",rt,Ue,Ut,nt)):(ln&&ln({typeDetected:true}),ze(Re,Fe,pt&&"readonly",rt,Ue,Ut,nt))}}return Fe}return Ve.length?ie&&V.throwOnBadSyncType?(function(){throw new TypeError("Sync method requested but async result obtained")})():Promise.resolve(be(vt,Ve)).then(Yt):!ie&&V.throwOnBadSyncType?(function(){throw new TypeError("Async method requested but sync result obtained")})():V.stringification&&ie?[Yt(vt)]:ie?Yt(vt):Promise.resolve(Yt(vt))}},{key:"encapsulateSync",value:function(R,U,V){return this.encapsulate(R,U,_(_({throwOnBadSyncType:true},V),{},{sync:true}))}},{key:"encapsulateAsync",value:function(R,U,V){return this.encapsulate(R,U,_(_({throwOnBadSyncType:true},V),{},{sync:false}))}},{key:"revive",value:function(R,U){var V=R&&R.$types;if(!V)return R;if(V===true)return R.$;var be=(U=_(_({sync:true},this.options),U)).sync,ie=[],Le={},Ne=true;V.$&&L(V.$)&&(R=R.$,V=V.$,Ne=false);var tt=this;function fe(Yt,K){var ze=b(tt.revivers[Yt]||[],1)[0];if(!ze)throw new Error("Unregistered type: "+Yt);return be&&!("revive"in ze)?K:ze[be&&ze.revive?"revive":!be&&ze.reviveAsync?"reviveAsync":"revive"](K,Le)}var Ve=[];function pt(Yt){return v(Yt,Ee)?void 0:Yt}var St,vt=(function(){var K=[];if(Object.entries(V).forEach((function(ze){var Dt=b(ze,2),Re=Dt[0],Fe=Dt[1];Fe!=="#"&&[].concat(Fe).forEach((function(rt){b(tt.revivers[rt]||[null,{}],2)[1].plain&&(K.push({keypath:Re,type:rt}),delete V[Re]);}));})),K.length)return K.sort(Pe).reduce((function ze(Dt,Re){var Fe=Re.keypath,rt=Re.type;if(B(Dt))return Dt.then((function(Ut){return ze(Ut,{keypath:Fe,type:rt})}));var Ue=re(R,Fe);if(v(Ue=fe(rt,Ue),M))return Ue.then((function(Ut){var ln=J(R,Fe,Ut);ln===Ut&&(R=ln);}));var st=J(R,Fe,Ue);st===Ue&&(R=st);}),void 0)})();return v(vt,M)?St=vt.then((function(){return R})):(St=(function Yt(K,ze,Dt,Re,Fe){if(!Ne||K!=="$types"){var rt=V[K],Ue=pe(ze);if(Ue||L(ze)){var st=Ue?new Array(ze.length):{};for(he(ze).forEach((function(Mt){var lt=Yt(K+(K?".":"")+Me(Mt),ze[Mt],Dt||st,st,Mt),kt=function(Xt){return v(Xt,Ee)?st[Mt]=void 0:Xt!==void 0&&(st[Mt]=Xt),Xt};v(lt,M)?Ve.push(lt.then((function(ft){return kt(ft)}))):kt(lt);})),ze=st;ie.length;){var Ut=b(ie[0],4),ln=Ut[0],Te=Ut[1],Ae=Ut[2],At=Ut[3],nt=re(ln,Te);if(nt===void 0)break;Ae[At]=nt,ie.splice(0,1);}}if(!rt)return ze;if(rt==="#"){var Lt=re(Dt,ze.slice(1));return Lt===void 0&&ie.push([Dt,ze.slice(1),Re,Fe]),Lt}return [].concat(rt).reduce((function Mt(lt,kt){return v(lt,M)?lt.then((function(ft){return Mt(ft,kt)})):fe(kt,lt)}),ze)}})("",R,null),Ve.length&&(St=M.resolve(St).then((function(Yt){return M.all([Yt].concat(Ve))})).then((function(Yt){return b(Yt,1)[0]})))),B(St)?be&&U.throwOnBadSyncType?(function(){throw new TypeError("Sync method requested but async result obtained")})():v(St,M)?St.p.then(pt):St:!be&&U.throwOnBadSyncType?(function(){throw new TypeError("Async method requested but sync result obtained")})():be?pt(St):Promise.resolve(pt(St))}},{key:"reviveSync",value:function(R,U){return this.revive(R,_(_({throwOnBadSyncType:true},U),{},{sync:true}))}},{key:"reviveAsync",value:function(R,U){return this.revive(R,_(_({throwOnBadSyncType:true},U),{},{sync:false}))}},{key:"register",value:function(R,U){return U=U||{},[].concat(R).forEach((function V(be){var ie=this;if(pe(be))return be.map((function(Le){return V.call(ie,Le)}));be&&he(be).forEach((function(Le){if(Le==="#")throw new TypeError("# cannot be used as a type name as it is reserved for cyclic objects");if(E.JSON_TYPES.includes(Le))throw new TypeError("Plain JSON object types are reserved as type names");var Ne=be[Le],tt=Ne&&Ne.testPlainObjects?this.plainObjectReplacers:this.nonplainObjectReplacers,fe=tt.filter((function(K){return K.type===Le}));if(fe.length&&(tt.splice(tt.indexOf(fe[0]),1),delete this.revivers[Le],delete this.types[Le]),typeof Ne=="function"){var Ve=Ne;Ne={test:function(ze){return ze&&ze.constructor===Ve},replace:function(ze){return _({},ze)},revive:function(ze){return Object.assign(Object.create(Ve.prototype),ze)}};}else if(pe(Ne)){var pt=b(Ne,3);Ne={test:pt[0],replace:pt[1],revive:pt[2]};}if(Ne&&Ne.test){var St={type:Le,test:Ne.test.bind(Ne)};Ne.replace&&(St.replace=Ne.replace.bind(Ne)),Ne.replaceAsync&&(St.replaceAsync=Ne.replaceAsync.bind(Ne));var vt=typeof U.fallback=="number"?U.fallback:U.fallback?0:Number.POSITIVE_INFINITY;if(Ne.testPlainObjects?this.plainObjectReplacers.splice(vt,0,St):this.nonplainObjectReplacers.splice(vt,0,St),Ne.revive||Ne.reviveAsync){var Yt={};Ne.revive&&(Yt.revive=Ne.revive.bind(Ne)),Ne.reviveAsync&&(Yt.reviveAsync=Ne.reviveAsync.bind(Ne)),this.revivers[Le]=[Yt,{plain:Ne.testPlainObjects}];}this.types[Le]=Ne;}}),this);}),this),this}}]),E})(),Ee=function E(){h(this,E);};Ee.__typeson__type__="TypesonUndefined",ce.Undefined=Ee,ce.Promise=M,ce.isThenable=B,ce.toStringTag=D,ce.hasConstructorOf=v,ce.isObject=$,ce.isPlainObject=L,ce.isUserObject=function E(x){if(!x||D(x)!=="Object")return  false;var R=I(x);return !R||v(x,Object)||E(R)},ce.escapeKeyPathComponent=Me,ce.unescapeKeyPathComponent=Z,ce.getByKeyPath=re,ce.getJSONType=function(x){return x===null?"null":Array.isArray(x)?"array":c(x)},ce.JSON_TYPES=["null","boolean","number","string","array","object"];for(var Qe={userObject:{test:function(x,R){return ce.isUserObject(x)},replace:function(x){return (function(U){for(var V=1;V<arguments.length;V++){var be=arguments[V]!=null?arguments[V]:{};V%2?i(Object(be),true).forEach((function(ie){a(U,ie,be[ie]);})):Object.getOwnPropertyDescriptors?Object.defineProperties(U,Object.getOwnPropertyDescriptors(be)):i(Object(be)).forEach((function(ie){Object.defineProperty(U,ie,Object.getOwnPropertyDescriptor(be,ie));}));}return U})({},x)},revive:function(x){return x}}},X=[{arrayNonindexKeys:{testPlainObjects:true,test:function(x,R){return !!Array.isArray(x)&&(Object.keys(x).some((function(U){return String(Number.parseInt(U))!==U}))&&(R.iterateIn="object",R.addLength=true),true)},replace:function(x,R){return R.iterateUnsetNumeric=true,x},revive:function(x){if(Array.isArray(x))return x;var R=[];return Object.keys(x).forEach((function(U){var V=x[U];R[U]=V;})),R}}},{sparseUndefined:{test:function(x,R){return x===void 0&&R.ownKeys===false},replace:function(x){return 0},revive:function(x){}}}],ne={undef:{test:function(x,R){return x===void 0&&(R.ownKeys||!("ownKeys"in R))},replace:function(x){return 0},revive:function(x){return new ce.Undefined}}},j={StringObject:{test:function(x){return ce.toStringTag(x)==="String"&&n(x)==="object"},replace:function(x){return String(x)},revive:function(x){return new String(x)}},BooleanObject:{test:function(x){return ce.toStringTag(x)==="Boolean"&&n(x)==="object"},replace:function(x){return !!x},revive:function(x){return new Boolean(x)}},NumberObject:{test:function(x){return ce.toStringTag(x)==="Number"&&n(x)==="object"},replace:function(x){return Number(x)},revive:function(x){return new Number(x)}}},se=[{nan:{test:function(x){return Number.isNaN(x)},replace:function(x){return "NaN"},revive:function(x){return Number.NaN}}},{infinity:{test:function(x){return x===Number.POSITIVE_INFINITY},replace:function(x){return "Infinity"},revive:function(x){return Number.POSITIVE_INFINITY}}},{negativeInfinity:{test:function(x){return x===Number.NEGATIVE_INFINITY},replace:function(x){return "-Infinity"},revive:function(x){return Number.NEGATIVE_INFINITY}}}],_e={date:{test:function(x){return ce.toStringTag(x)==="Date"},replace:function(x){var R=x.getTime();return Number.isNaN(R)?"NaN":R},revive:function(x){return x==="NaN"?new Date(Number.NaN):new Date(x)}}},we={regexp:{test:function(x){return ce.toStringTag(x)==="RegExp"},replace:function(x){return {source:x.source,flags:(x.global?"g":"")+(x.ignoreCase?"i":"")+(x.multiline?"m":"")+(x.sticky?"y":"")+(x.unicode?"u":"")}},revive:function(x){var R=x.source,U=x.flags;return new RegExp(R,U)}}},Ye={map:{test:function(x){return ce.toStringTag(x)==="Map"},replace:function(x){return s(x.entries())},revive:function(x){return new Map(x)}}},We={set:{test:function(x){return ce.toStringTag(x)==="Set"},replace:function(x){return s(x.values())},revive:function(x){return new Set(x)}}},Se="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Tt=new Uint8Array(256),jt=0;jt<Se.length;jt++)Tt[Se.charCodeAt(jt)]=jt;var Wt=function(x,R,U){U==null&&(U=x.byteLength);for(var V=new Uint8Array(x,0,U),be=V.length,ie="",Le=0;Le<be;Le+=3)ie+=Se[V[Le]>>2],ie+=Se[(3&V[Le])<<4|V[Le+1]>>4],ie+=Se[(15&V[Le+1])<<2|V[Le+2]>>6],ie+=Se[63&V[Le+2]];return be%3==2?ie=ie.slice(0,-1)+"=":be%3==1&&(ie=ie.slice(0,-2)+"=="),ie},Gt=function(x){var R,U,V,be,ie=x.length,Le=.75*x.length,Ne=0;x[x.length-1]==="="&&(Le--,x[x.length-2]==="="&&Le--);for(var tt=new ArrayBuffer(Le),fe=new Uint8Array(tt),Ve=0;Ve<ie;Ve+=4)R=Tt[x.charCodeAt(Ve)],U=Tt[x.charCodeAt(Ve+1)],V=Tt[x.charCodeAt(Ve+2)],be=Tt[x.charCodeAt(Ve+3)],fe[Ne++]=R<<2|U>>4,fe[Ne++]=(15&U)<<4|V>>2,fe[Ne++]=(3&V)<<6|63&be;return tt},Rt={arraybuffer:{test:function(x){return ce.toStringTag(x)==="ArrayBuffer"},replace:function(x,R){R.buffers||(R.buffers=[]);var U=R.buffers.indexOf(x);return U>-1?{index:U}:(R.buffers.push(x),Wt(x))},revive:function(x,R){if(R.buffers||(R.buffers=[]),n(x)==="object")return R.buffers[x.index];var U=Gt(x);return R.buffers.push(U),U}}},et=typeof self>"u"?Ku:self,at={};["Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Uint16Array","Int32Array","Uint32Array","Float32Array","Float64Array"].forEach((function(E){var x=E,R=et[x];R&&(at[E.toLowerCase()]={test:function(V){return ce.toStringTag(V)===x},replace:function(V,be){var ie=V.buffer,Le=V.byteOffset,Ne=V.length;be.buffers||(be.buffers=[]);var tt=be.buffers.indexOf(ie);return tt>-1?{index:tt,byteOffset:Le,length:Ne}:(be.buffers.push(ie),{encoded:Wt(ie),byteOffset:Le,length:Ne})},revive:function(V,be){be.buffers||(be.buffers=[]);var ie,Le=V.byteOffset,Ne=V.length,tt=V.encoded,fe=V.index;return "index"in V?ie=be.buffers[fe]:(ie=Gt(tt),be.buffers.push(ie)),new R(ie,Le,Ne)}});}));var wt={dataview:{test:function(x){return ce.toStringTag(x)==="DataView"},replace:function(x,R){var U=x.buffer,V=x.byteOffset,be=x.byteLength;R.buffers||(R.buffers=[]);var ie=R.buffers.indexOf(U);return ie>-1?{index:ie,byteOffset:V,byteLength:be}:(R.buffers.push(U),{encoded:Wt(U),byteOffset:V,byteLength:be})},revive:function(x,R){R.buffers||(R.buffers=[]);var U,V=x.byteOffset,be=x.byteLength,ie=x.encoded,Le=x.index;return "index"in x?U=R.buffers[Le]:(U=Gt(ie),R.buffers.push(U)),new DataView(U,V,be)}}},Ce={IntlCollator:{test:function(x){return ce.hasConstructorOf(x,Intl.Collator)},replace:function(x){return x.resolvedOptions()},revive:function(x){return new Intl.Collator(x.locale,x)}},IntlDateTimeFormat:{test:function(x){return ce.hasConstructorOf(x,Intl.DateTimeFormat)},replace:function(x){return x.resolvedOptions()},revive:function(x){return new Intl.DateTimeFormat(x.locale,x)}},IntlNumberFormat:{test:function(x){return ce.hasConstructorOf(x,Intl.NumberFormat)},replace:function(x){return x.resolvedOptions()},revive:function(x){return new Intl.NumberFormat(x.locale,x)}}};function ht(E){for(var x=new Uint8Array(E.length),R=0;R<E.length;R++)x[R]=E.charCodeAt(R);return x.buffer}var it={file:{test:function(x){return ce.toStringTag(x)==="File"},replace:function(x){var R=new XMLHttpRequest;if(R.overrideMimeType("text/plain; charset=x-user-defined"),R.open("GET",URL.createObjectURL(x),false),R.send(),R.status!==200&&R.status!==0)throw new Error("Bad File access: "+R.status);return {type:x.type,stringContents:R.responseText,name:x.name,lastModified:x.lastModified}},revive:function(x){var R=x.name,U=x.type,V=x.stringContents,be=x.lastModified;return new File([ht(V)],R,{type:U,lastModified:be})},replaceAsync:function(x){return new ce.Promise((function(R,U){var V=new FileReader;V.addEventListener("load",(function(){R({type:x.type,stringContents:V.result,name:x.name,lastModified:x.lastModified});})),V.addEventListener("error",(function(){U(V.error);})),V.readAsBinaryString(x);}))}}},yt={bigint:{test:function(x){return typeof x=="bigint"},replace:function(x){return String(x)},revive:function(x){return BigInt(x)}}},Oe={bigintObject:{test:function(x){return n(x)==="object"&&ce.hasConstructorOf(x,BigInt)},replace:function(x){return String(x)},revive:function(x){return new Object(BigInt(x))}}},ke={cryptokey:{test:function(x){return ce.toStringTag(x)==="CryptoKey"&&x.extractable},replaceAsync:function(x){return new ce.Promise((function(R,U){crypto.subtle.exportKey("jwk",x).catch((function(V){U(V);})).then((function(V){R({jwk:V,algorithm:x.algorithm,usages:x.usages});}));}))},revive:function(x){var R=x.jwk,U=x.algorithm,V=x.usages;return crypto.subtle.importKey("jwk",R,U,true,V)}}};return [Qe,ne,X,j,se,_e,we,{imagedata:{test:function(x){return ce.toStringTag(x)==="ImageData"},replace:function(x){return {array:s(x.data),width:x.width,height:x.height}},revive:function(x){return new ImageData(new Uint8ClampedArray(x.array),x.width,x.height)}}},{imagebitmap:{test:function(x){return ce.toStringTag(x)==="ImageBitmap"||x&&x.dataset&&x.dataset.toStringTag==="ImageBitmap"},replace:function(x){var R=document.createElement("canvas");return R.getContext("2d").drawImage(x,0,0),R.toDataURL()},revive:function(x){var R=document.createElement("canvas"),U=R.getContext("2d"),V=document.createElement("img");return V.addEventListener("load",(function(){U.drawImage(V,0,0);})),V.src=x,R},reviveAsync:function(x){var R=document.createElement("canvas"),U=R.getContext("2d"),V=document.createElement("img");return V.addEventListener("load",(function(){U.drawImage(V,0,0);})),V.src=x,createImageBitmap(R)}}},it,{file:it.file,filelist:{test:function(x){return ce.toStringTag(x)==="FileList"},replace:function(x){for(var R=[],U=0;U<x.length;U++)R[U]=x.item(U);return R},revive:function(x){return new((function(){function R(){r(this,R),this._files=arguments[0],this.length=this._files.length;}return (function(V,be,ie){return be&&o(V.prototype,be),V})(R,[{key:"item",value:function(V){return this._files[V]}},{key:Symbol.toStringTag,get:function(){return "FileList"}}]),R})())(x)}}},{blob:{test:function(x){return ce.toStringTag(x)==="Blob"},replace:function(x){var R=new XMLHttpRequest;if(R.overrideMimeType("text/plain; charset=x-user-defined"),R.open("GET",URL.createObjectURL(x),false),R.send(),R.status!==200&&R.status!==0)throw new Error("Bad Blob access: "+R.status);return {type:x.type,stringContents:R.responseText}},revive:function(x){var R=x.type,U=x.stringContents;return new Blob([ht(U)],{type:R})},replaceAsync:function(x){return new ce.Promise((function(R,U){var V=new FileReader;V.addEventListener("load",(function(){R({type:x.type,stringContents:V.result});})),V.addEventListener("error",(function(){U(V.error);})),V.readAsBinaryString(x);}))}}}].concat(typeof Map=="function"?Ye:[],typeof Set=="function"?We:[],typeof ArrayBuffer=="function"?Rt:[],typeof Uint8Array=="function"?at:[],typeof DataView=="function"?wt:[],typeof Intl<"u"?Ce:[],typeof crypto<"u"?ke:[],typeof BigInt<"u"?[yt,Oe]:[])}));}),za="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Ai=new Uint8Array(256);for(var As=0;As<za.length;As++)Ai[za.codePointAt(As)]=As;var Wu=function(t,n,r){r==null&&(r=t.byteLength);for(var o=new Uint8Array(t,0,r),a=o.length,i="",s=0;s<a;s+=3)i+=za[o[s]>>2],i+=za[(o[s]&3)<<4|o[s+1]>>4],i+=za[(o[s+1]&15)<<2|o[s+2]>>6],i+=za[o[s+2]&63];return a%3===2?i=i.slice(0,-1)+"=":a%3===1&&(i=i.slice(0,-2)+"=="),i},wy=function(t){var n=t.length,r=t.length*.75,o=0,a,i,s,l;t[t.length-1]==="="&&(r--,t[t.length-2]==="="&&r--);for(var c=new ArrayBuffer(r),h=new Uint8Array(c),f=0;f<n;f+=4)a=Ai[t.codePointAt(f)],i=Ai[t.codePointAt(f+1)],s=Ai[t.codePointAt(f+2)],l=Ai[t.codePointAt(f+3)],h[o++]=a<<2|i>>4,h[o++]=(i&15)<<4|s>>2,h[o++]=(s&3)<<6|l&63;return c},Z0=typeof self>"u"?global:self,by={};["Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Uint16Array","Int32Array","Uint32Array","Float32Array","Float64Array"].forEach(function(e){var t=e,n=Z0[t];n&&(by[e.toLowerCase()+"2"]={test:function(r){return Gl.toStringTag(r)===t},replace:function(r){var o=r.buffer,a=r.byteOffset,i=r.length;return {buffer:o,byteOffset:a,length:i}},revive:function(r){var o=r.buffer,a=r.byteOffset,i=r.length;return new n(o,a,i)}});});var Q0={arraybuffer:{test:function(e){return Gl.toStringTag(e)==="ArrayBuffer"},replace:function(e){return Wu(e,0,e.byteLength)},revive:function(e){var t=wy(e);return t}}},br=new Gl().register(X0),J0="FileReaderSync"in self,Tl=[],tl=0;br.register([Q0,by,{blob2:{test:function(e){return Gl.toStringTag(e)==="Blob"},replace:function(e){if(e.isClosed)throw new Error("The Blob is closed");if(J0){var t=_y(e,"binary"),n=Wu(t,0,t.byteLength);return {type:e.type,data:n}}else {Tl.push(e);var r={type:e.type,data:{start:tl,end:tl+e.size}};return tl+=e.size,r}},finalize:function(e,t){e.data=Wu(t,0,t.byteLength);},revive:function(e){var t=e.type,n=e.data;return new Blob([wy(n)],{type:t})}}}]);br.mustFinalize=function(){return Tl.length>0};br.finalize=function(e){return Ho(void 0,void 0,void 0,function(){var t,n,r,o,a,i,s,l,c,h,f,m;return Or(this,function(g){switch(g.label){case 0:return [4,yy(new Blob(Tl),"binary")];case 1:if(t=g.sent(),e){for(n=0,r=e;n<r.length;n++)if(o=r[n],o.$types){a=o.$types,i=a.$,i&&(a=a.$);for(s in a)l=a[s],c=br.types[l],c&&c.finalize&&(h=On.getByKeyPath(o,i?"$."+s:s),c.finalize(h,t.slice((f=h.data)===null||f===void 0?void 0:f.start,(m=h.data)===null||m===void 0?void 0:m.end)));}}return Tl=[],tl=0,[2]}})})};var eS=2e3;function vy(e,t){return Ho(this,void 0,void 0,function(){function n(){return Ho(this,void 0,void 0,function(){var f,m,g,_,b,C,k,T,M,P;return Or(this,function(F){switch(F.label){case 0:return [4,Promise.all(o.map(function(I){return I.count()}))];case 1:f=F.sent(),f.forEach(function(I,O){return i[O].rowCount=I}),h.totalRows=f.reduce(function(I,O){return I+O}),m=JSON.stringify(l,void 0,s?2:void 0),g=m.lastIndexOf("]"),_=m.substring(0,g),a.push(_),b=t.filter,C=t.transform,k=function(I){var O,B,D,v,L,$,Me,Z,re,J,le,he;return Or(this,function(pe){switch(pe.label){case 0:O=e.table(I),B=O.schema.primKey,D=!!B.keyPath,v=t.numRowsPerChunk||eS,L=D?{tableName:O.name,inbound:true,rows:[]}:{tableName:O.name,inbound:false,rows:[]},$=JSON.stringify(L,void 0,s?2:void 0),s&&($=$.split(`
`).join(`
    `)),Me=$.lastIndexOf("]"),a.push($.substring(0,Me)),Z=null,re=0,J=true,le=function(){var ge,z,ue,Pe,ce,ne,Ee,Qe,X,ne;return Or(this,function(j){switch(j.label){case 0:return c&&On.ignoreTransaction(function(){return c(h)}),ge=Z==null?O.limit(v):O.where(":id").above(Z).limit(v),[4,ge.toArray()];case 1:return z=j.sent(),z.length===0?[2,"break"]:(Z!=null&&re>0&&(a.push(","),s&&a.push(`
      `)),J=z.length===v,D?(ue=b?z.filter(function(se){return b(I,se)}):z,Pe=C?ue.map(function(se){return C(I,se).value}):ue,ce=Pe.map(function(se){return br.encapsulate(se)}),br.mustFinalize()?[4,On.waitFor(br.finalize(ce))]:[3,3]):[3,4]);case 2:j.sent(),j.label=3;case 3:return ne=JSON.stringify(ce,void 0,s?2:void 0),s&&(ne=ne.split(`
`).join(`
      `)),a.push(new Blob([ne.substring(1,ne.length-1)])),re=Pe.length,Z=z.length>0?On.getByKeyPath(z[z.length-1],B.keyPath):null,[3,8];case 4:return [4,ge.primaryKeys()];case 5:return Ee=j.sent(),Qe=Ee.map(function(se,_e){return [se,z[_e]]}),b&&(Qe=Qe.filter(function(se){var _e=se[0],we=se[1];return b(I,we,_e)})),C&&(Qe=Qe.map(function(se){var _e=se[0],we=se[1],Ye=C(I,we,_e);return [Ye.key,Ye.value]})),X=Qe.map(function(se){return br.encapsulate(se)}),br.mustFinalize()?[4,On.waitFor(br.finalize(X))]:[3,7];case 6:j.sent(),j.label=7;case 7:ne=JSON.stringify(X,void 0,s?2:void 0),s&&(ne=ne.split(`
`).join(`
      `)),a.push(new Blob([ne.substring(1,ne.length-1)])),re=Qe.length,Z=Ee.length>0?Ee[Ee.length-1]:null,j.label=8;case 8:return h.completedRows+=z.length,[2]}})},pe.label=1;case 1:return J?[5,le()]:[3,3];case 2:return he=pe.sent(),he==="break"?[3,3]:[3,1];case 3:return a.push($.substr(Me)),h.completedTables+=1,h.completedTables<h.totalTables&&a.push(","),[2]}})},T=0,M=i,F.label=2;case 2:return T<M.length?(P=M[T].name,[5,k(P)]):[3,5];case 3:F.sent(),F.label=4;case 4:return T++,[3,2];case 5:return a.push(m.substr(g)),h.done=true,c&&On.ignoreTransaction(function(){return c(h)}),[2]}})})}var r,o,a,i,s,l,c,h;return Or(this,function(f){switch(f.label){case 0:t=t||{},r=t.skipTables?t.skipTables:[],o=e.tables.filter(function(m){return !r.includes(m.name)}),a=[],i=o.map(function(m){return {name:m.name,schema:G0(m),rowCount:0}}),s=t.prettyJson,l={formatName:"dexie",formatVersion:1,data:{databaseName:e.name,databaseVersion:e.verno,tables:i,data:[]}},c=t.progressCallback,h={done:false,completedRows:0,completedTables:0,totalRows:NaN,totalTables:i.length},f.label=1;case 1:return f.trys.push([1,,6,7]),t.noTransaction?[4,n()]:[3,3];case 2:return f.sent(),[3,5];case 3:return [4,e.transaction("r",e.tables,n)];case 4:f.sent(),f.label=5;case 5:return [3,7];case 6:return br.finalize(),[7];case 7:return [2,new Blob(a,{type:"text/json"})]}})})}var tS=1,nS={Stream:function(){}},rS=Od(function(e,t){(function(n){var r=typeof process=="object"&&Lh?Lh:self;n.parser=function(D){return new g(D)},n.CParser=g,n.CStream=b,n.createStream=_,n.MAX_BUFFER_LENGTH=10*1024*1024,n.DEBUG=r.CDEBUG==="debug",n.INFO=r.CDEBUG==="debug"||r.CDEBUG==="info",n.EVENTS=["value","string","key","openobject","closeobject","openarray","closearray","error","end","ready"];var o={textNode:void 0,numberNode:""},a=n.EVENTS.filter(function(D){return D!=="error"&&D!=="end"}),i=0,s;n.STATE={BEGIN:i++,VALUE:i++,OPEN_OBJECT:i++,CLOSE_OBJECT:i++,OPEN_ARRAY:i++,CLOSE_ARRAY:i++,TEXT_ESCAPE:i++,STRING:i++,BACKSLASH:i++,END:i++,OPEN_KEY:i++,CLOSE_KEY:i++,TRUE:i++,TRUE2:i++,TRUE3:i++,FALSE:i++,FALSE2:i++,FALSE3:i++,FALSE4:i++,NULL:i++,NULL2:i++,NULL3:i++,NUMBER_DECIMAL_POINT:i++,NUMBER_DIGIT:i++};for(var l in n.STATE)n.STATE[n.STATE[l]]=l;i=n.STATE;const c={tab:9,lineFeed:10,carriageReturn:13,space:32,doubleQuote:34,plus:43,comma:44,minus:45,period:46,_0:48,_9:57,colon:58,E:69,openBracket:91,backslash:92,closeBracket:93,a:97,b:98,e:101,f:102,l:108,n:110,r:114,s:115,t:116,u:117,openBrace:123,closeBrace:125};Object.create||(Object.create=function(D){function v(){this.__proto__=D;}return v.prototype=D,new v}),Object.getPrototypeOf||(Object.getPrototypeOf=function(D){return D.__proto__}),Object.keys||(Object.keys=function(D){var v=[];for(var L in D)D.hasOwnProperty(L)&&v.push(L);return v});function h(D){var v=Math.max(n.MAX_BUFFER_LENGTH,10),L=0;for(var $ in o){var Me=D[$]===void 0?0:D[$].length;if(Me>v)switch($){case "text":closeText(D);break;default:F(D,"Max buffer length exceeded: "+$);}L=Math.max(L,Me);}D.bufferCheckPosition=n.MAX_BUFFER_LENGTH-L+D.position;}function f(D){for(var v in o)D[v]=o[v];}var m=/[\\"\n]/g;function g(D){if(!(this instanceof g))return new g(D);var v=this;f(v),v.bufferCheckPosition=n.MAX_BUFFER_LENGTH,v.q=v.c=v.p="",v.opt=D||{},v.closed=v.closedRoot=v.sawRoot=false,v.tag=v.error=null,v.state=i.BEGIN,v.stack=new Array,v.position=v.column=0,v.line=1,v.slashed=false,v.unicodeI=0,v.unicodeS=null,v.depth=0,C(v,"onready");}g.prototype={end:function(){I(this);},write:B,resume:function(){return this.error=null,this},close:function(){return this.write(null)}};try{s=nS.Stream;}catch{s=function(){};}function _(D){return new b(D)}function b(D){if(!(this instanceof b))return new b(D);this._parser=new g(D),this.writable=true,this.readable=true,this.bytes_remaining=0,this.bytes_in_sequence=0,this.temp_buffs={2:new Buffer(2),3:new Buffer(3),4:new Buffer(4)},this.string="";var v=this;s.apply(v),this._parser.onend=function(){v.emit("end");},this._parser.onerror=function(L){v.emit("error",L),v._parser.error=null;},a.forEach(function(L){Object.defineProperty(v,"on"+L,{get:function(){return v._parser["on"+L]},set:function($){if(!$)return v.removeAllListeners(L),v._parser["on"+L]=$,$;v.on(L,$);},enumerable:true,configurable:false});});}b.prototype=Object.create(s.prototype,{constructor:{value:b}}),b.prototype.write=function(D){D=new Buffer(D);for(var v=0;v<D.length;v++){var L=D[v];if(this.bytes_remaining>0){for(var $=0;$<this.bytes_remaining;$++)this.temp_buffs[this.bytes_in_sequence][this.bytes_in_sequence-this.bytes_remaining+$]=D[$];this.string=this.temp_buffs[this.bytes_in_sequence].toString(),this.bytes_in_sequence=this.bytes_remaining=0,v=v+$-1,this._parser.write(this.string),this.emit("data",this.string);continue}if(this.bytes_remaining===0&&L>=128)if(L>=194&&L<=223&&(this.bytes_in_sequence=2),L>=224&&L<=239&&(this.bytes_in_sequence=3),L>=240&&L<=244&&(this.bytes_in_sequence=4),this.bytes_in_sequence+v>D.length){for(var Me=0;Me<=D.length-1-v;Me++)this.temp_buffs[this.bytes_in_sequence][Me]=D[v+Me];return this.bytes_remaining=v+this.bytes_in_sequence-D.length,true}else {this.string=D.slice(v,v+this.bytes_in_sequence).toString(),v=v+this.bytes_in_sequence-1,this._parser.write(this.string),this.emit("data",this.string);continue}for(var Z=v;Z<D.length&&!(D[Z]>=128);Z++);this.string=D.slice(v,Z).toString(),this._parser.write(this.string),this.emit("data",this.string),v=Z-1;}},b.prototype.end=function(D){return D&&D.length&&this._parser.write(D.toString()),this._parser.end(),true},b.prototype.on=function(D,v){var L=this;return !L._parser["on"+D]&&a.indexOf(D)!==-1&&(L._parser["on"+D]=function(){var $=arguments.length===1?[arguments[0]]:Array.apply(null,arguments);$.splice(0,0,D),L.emit.apply(L,$);}),s.prototype.on.call(L,D,v)},b.prototype.destroy=function(){f(this._parser),this.emit("close");};function C(D,v,L){n.INFO&&console.log("-- emit",v,L),D[v]&&D[v](L);}function k(D,v,L){T(D),C(D,v,L);}function T(D,v){D.textNode=P(D.opt,D.textNode),D.textNode!==void 0&&C(D,v||"onvalue",D.textNode),D.textNode=void 0;}function M(D){D.numberNode&&C(D,"onvalue",parseFloat(D.numberNode)),D.numberNode="";}function P(D,v){return v===void 0||(D.trim&&(v=v.trim()),D.normalize&&(v=v.replace(/\s+/g," "))),v}function F(D,v){return T(D),v+=`
Line: `+D.line+`
Column: `+D.column+`
Char: `+D.c,v=new Error(v),D.error=v,C(D,"onerror",v),D}function I(D){return (D.state!==i.VALUE||D.depth!==0)&&F(D,"Unexpected end"),T(D),D.c="",D.closed=true,C(D,"onend"),g.call(D,D.opt),D}function O(D){return D===c.carriageReturn||D===c.lineFeed||D===c.space||D===c.tab}function B(D){var v=this;if(this.error)throw this.error;if(v.closed)return F(v,"Cannot write after close. Assign an onready handler.");if(D===null)return I(v);var L=0,$=D.charCodeAt(0),Me=v.p;for(n.DEBUG&&console.log("write -> ["+D+"]");$&&(Me=$,v.c=$=D.charCodeAt(L++),Me!==$?v.p=Me:Me=v.p,!!$);)switch(n.DEBUG&&console.log(L,$,n.STATE[v.state]),v.position++,$===c.lineFeed?(v.line++,v.column=0):v.column++,v.state){case i.BEGIN:$===c.openBrace?v.state=i.OPEN_OBJECT:$===c.openBracket?v.state=i.OPEN_ARRAY:O($)||F(v,"Non-whitespace before {[.");continue;case i.OPEN_KEY:case i.OPEN_OBJECT:if(O($))continue;if(v.state===i.OPEN_KEY)v.stack.push(i.CLOSE_KEY);else if($===c.closeBrace){C(v,"onopenobject"),this.depth++,C(v,"oncloseobject"),this.depth--,v.state=v.stack.pop()||i.VALUE;continue}else v.stack.push(i.CLOSE_OBJECT);$===c.doubleQuote?v.state=i.STRING:F(v,'Malformed object key should start with "');continue;case i.CLOSE_KEY:case i.CLOSE_OBJECT:if(O($))continue;v.state,i.CLOSE_KEY,$===c.colon?(v.state===i.CLOSE_OBJECT?(v.stack.push(i.CLOSE_OBJECT),T(v,"onopenobject"),this.depth++):T(v,"onkey"),v.state=i.VALUE):$===c.closeBrace?(k(v,"oncloseobject"),this.depth--,v.state=v.stack.pop()||i.VALUE):$===c.comma?(v.state===i.CLOSE_OBJECT&&v.stack.push(i.CLOSE_OBJECT),T(v),v.state=i.OPEN_KEY):F(v,"Bad object");continue;case i.OPEN_ARRAY:case i.VALUE:if(O($))continue;if(v.state===i.OPEN_ARRAY)if(C(v,"onopenarray"),this.depth++,v.state=i.VALUE,$===c.closeBracket){C(v,"onclosearray"),this.depth--,v.state=v.stack.pop()||i.VALUE;continue}else v.stack.push(i.CLOSE_ARRAY);$===c.doubleQuote?v.state=i.STRING:$===c.openBrace?v.state=i.OPEN_OBJECT:$===c.openBracket?v.state=i.OPEN_ARRAY:$===c.t?v.state=i.TRUE:$===c.f?v.state=i.FALSE:$===c.n?v.state=i.NULL:$===c.minus?v.numberNode+="-":c._0<=$&&$<=c._9?(v.numberNode+=String.fromCharCode($),v.state=i.NUMBER_DIGIT):F(v,"Bad value");continue;case i.CLOSE_ARRAY:if($===c.comma)v.stack.push(i.CLOSE_ARRAY),T(v,"onvalue"),v.state=i.VALUE;else if($===c.closeBracket)k(v,"onclosearray"),this.depth--,v.state=v.stack.pop()||i.VALUE;else {if(O($))continue;F(v,"Bad array");}continue;case i.STRING:v.textNode===void 0&&(v.textNode="");var Z=L-1,re=v.slashed,J=v.unicodeI;e:for(;;){for(n.DEBUG&&console.log(L,$,n.STATE[v.state],re);J>0;)if(v.unicodeS+=String.fromCharCode($),$=D.charCodeAt(L++),v.position++,J===4?(v.textNode+=String.fromCharCode(parseInt(v.unicodeS,16)),J=0,Z=L-1):J++,!$)break e;if($===c.doubleQuote&&!re){v.state=v.stack.pop()||i.VALUE,v.textNode+=D.substring(Z,L-1),v.position+=L-1-Z;break}if($===c.backslash&&!re&&(re=true,v.textNode+=D.substring(Z,L-1),v.position+=L-1-Z,$=D.charCodeAt(L++),v.position++,!$))break;if(re){if(re=false,$===c.n?v.textNode+=`
`:$===c.r?v.textNode+="\r":$===c.t?v.textNode+="	":$===c.f?v.textNode+="\f":$===c.b?v.textNode+="\b":$===c.u?(J=1,v.unicodeS=""):v.textNode+=String.fromCharCode($),$=D.charCodeAt(L++),v.position++,Z=L-1,$)continue;break}m.lastIndex=L;var le=m.exec(D);if(le===null){L=D.length+1,v.textNode+=D.substring(Z,L-1),v.position+=L-1-Z;break}if(L=le.index+1,$=D.charCodeAt(le.index),!$){v.textNode+=D.substring(Z,L-1),v.position+=L-1-Z;break}}v.slashed=re,v.unicodeI=J;continue;case i.TRUE:$===c.r?v.state=i.TRUE2:F(v,"Invalid true started with t"+$);continue;case i.TRUE2:$===c.u?v.state=i.TRUE3:F(v,"Invalid true started with tr"+$);continue;case i.TRUE3:$===c.e?(C(v,"onvalue",true),v.state=v.stack.pop()||i.VALUE):F(v,"Invalid true started with tru"+$);continue;case i.FALSE:$===c.a?v.state=i.FALSE2:F(v,"Invalid false started with f"+$);continue;case i.FALSE2:$===c.l?v.state=i.FALSE3:F(v,"Invalid false started with fa"+$);continue;case i.FALSE3:$===c.s?v.state=i.FALSE4:F(v,"Invalid false started with fal"+$);continue;case i.FALSE4:$===c.e?(C(v,"onvalue",false),v.state=v.stack.pop()||i.VALUE):F(v,"Invalid false started with fals"+$);continue;case i.NULL:$===c.u?v.state=i.NULL2:F(v,"Invalid null started with n"+$);continue;case i.NULL2:$===c.l?v.state=i.NULL3:F(v,"Invalid null started with nu"+$);continue;case i.NULL3:$===c.l?(C(v,"onvalue",null),v.state=v.stack.pop()||i.VALUE):F(v,"Invalid null started with nul"+$);continue;case i.NUMBER_DECIMAL_POINT:$===c.period?(v.numberNode+=".",v.state=i.NUMBER_DIGIT):F(v,"Leading zero not followed by .");continue;case i.NUMBER_DIGIT:c._0<=$&&$<=c._9?v.numberNode+=String.fromCharCode($):$===c.period?(v.numberNode.indexOf(".")!==-1&&F(v,"Invalid number has two dots"),v.numberNode+="."):$===c.e||$===c.E?((v.numberNode.indexOf("e")!==-1||v.numberNode.indexOf("E")!==-1)&&F(v,"Invalid number has two exponential"),v.numberNode+="e"):$===c.plus||$===c.minus?(Me===c.e||Me===c.E||F(v,"Invalid symbol in number"),v.numberNode+=String.fromCharCode($)):(M(v),L--,v.state=v.stack.pop()||i.VALUE);continue;default:F(v,"Unknown state: "+v.state);}return v.position>=v.bufferCheckPosition&&h(v),v}})(t);});function oS(e){var t=0,n=aS(),r={pullAsync:function(o){return Ho(this,void 0,void 0,function(){var a,i,s;return Or(this,function(l){switch(l.label){case 0:return a=e.slice(t,t+o),t+=o,[4,yy(a,"text")];case 1:return i=l.sent(),s=n.write(i),r.result=s||{},[2,s]}})})},pullSync:function(o){var a=e.slice(t,t+o);t+=o;var i=_y(a,"text"),s=n.write(i);return r.result=s||{},s},done:function(){return n.done()},eof:function(){return t>=e.size},result:{}};return r}function aS(e){var t=rS.parser(),n=0,r,o=[],a,i,s=false,l=false;return t.onopenobject=function(c){var h={};h.incomplete=true,r||(r=h),a&&(o.push([i,a,l]),l?a.push(h):a[i]=h),a=h,i=c,l=false,++n;},t.onkey=function(c){return i=c},t.onvalue=function(c){return l?a.push(c):a[i]=c},t.oncloseobject=function(){var c;delete a.incomplete,i=null,--n===0?s=true:(c=o.pop(),i=c[0],a=c[1],l=c[2]);},t.onopenarray=function(){var c=[];c.incomplete=true,r||(r=c),a&&(o.push([i,a,l]),l?a.push(c):a[i]=c),a=c,l=true,i=null,++n;},t.onclosearray=function(){var c;delete a.incomplete,i=null,--n===0?s=true:(c=o.pop(),i=c[0],a=c[1],l=c[2]);},{write:function(c){return t.write(c),r},done:function(){return s}}}var ky=1024;function iS(e,t){return Ho(this,void 0,void 0,function(){var n,r,o,a;return Or(this,function(i){switch(i.label){case 0:return t=t||{},n=t.chunkSizeBytes||ky*1024,[4,xy(e,n)];case 1:return r=i.sent(),o=r.result.data,a=new On(t.name!==void 0?t.name:o.databaseName),a.version(o.databaseVersion).stores(Y0(o)),[4,Fd(a,r,t.name!==void 0?Cl(Cl({},t),{acceptNameDiff:true}):t)];case 2:return i.sent(),[2,a]}})})}function Fd(e,t,n){return Ho(this,void 0,void 0,function(){function r(){return Ho(this,void 0,void 0,function(){var b,C,k,T,M;return Or(this,function(P){switch(P.label){case 0:b=function(F){var I,O,B,D,v,L,$,Me,Z,re,J,le,he;return Or(this,function(pe){switch(pe.label){case 0:if(c.includes(F.tableName))return [2,"continue"];if(!F.rows)return [2,"break"];if(!F.rows.incomplete&&F.rows.length===0)return [2,"continue"];if(h&&On.ignoreTransaction(function(){return h(f)}),I=F.tableName,O=e.table(I),B=l.tables.filter(function(ge){return ge.name===I})[0].schema,!O){if(n.acceptMissingTables)return [2,"continue"];throw new Error("Exported table ".concat(F.tableName," is missing in installed database"))}if(!n.acceptChangedPrimaryKey&&B.split(",")[0]!=O.schema.primKey.src)throw new Error("Primary key differs for table ".concat(F.tableName,". "));for(D=F.rows,v=[],L=0;L<D.length&&($=D[L],!$.incomplete);L++)v.push(br.revive($));return Me=n.filter,Z=n.transform,re=Me?F.inbound?v.filter(function(ge){return Me(I,ge)}):v.filter(function(ge){var z=ge[0],ue=ge[1];return Me(I,ue,z)}):v,Z&&(re=re.map(F.inbound?function(ge){return Z(I,ge).value}:function(ge){var z=ge[0],ue=ge[1],Pe=Z(I,ue,z);return [Pe.key,Pe.value]})),J=F.inbound?[void 0,re]:[re.map(function(ge){return ge[0]}),v.map(function(ge){return ge[1]})],le=J[0],he=J[1],n.overwriteValues?[4,O.bulkPut(he,le)]:[3,2];case 1:return pe.sent(),[3,4];case 2:return [4,O.bulkAdd(he,le)];case 3:pe.sent(),pe.label=4;case 4:return f.completedRows+=v.length,v.incomplete||(f.completedTables+=1),D.splice(0,v.length),[2]}})},C=0,k=l.data,P.label=1;case 1:return C<k.length?(T=k[C],[5,b(T)]):[3,4];case 2:if(M=P.sent(),M==="break")return [3,4];P.label=3;case 3:return C++,[3,1];case 4:for(;l.data.length>0&&l.data[0].rows&&!l.data[0].rows.incomplete;)l.data.splice(0,1);return !a.done()&&!a.eof()?s?(a.pullSync(o),[3,7]):[3,5]:[3,8];case 5:return [4,On.waitFor(a.pullAsync(o))];case 6:P.sent(),P.label=7;case 7:return [3,9];case 8:return [3,10];case 9:return [3,0];case 10:return [2]}})})}var o,a,i,s,l,c,h,f,m,g,_;return Or(this,function(b){switch(b.label){case 0:return n=n||{},o=n.chunkSizeBytes||ky*1024,[4,xy(t,o)];case 1:if(a=b.sent(),i=a.result,s="FileReaderSync"in self,l=i.data,c=n.skipTables?n.skipTables:[],!n.acceptNameDiff&&e.name!==l.databaseName)throw new Error("Name differs. Current database name is ".concat(e.name," but export is ").concat(l.databaseName));if(!n.acceptVersionDiff&&e.verno!==l.databaseVersion)throw new Error("Database version differs. Current database is in version ".concat(e.verno," but export is ").concat(l.databaseVersion));if(h=n.progressCallback,f={done:false,completedRows:0,completedTables:0,totalRows:l.tables.reduce(function(C,k){return C+k.rowCount},0),totalTables:l.tables.length},h&&On.ignoreTransaction(function(){return h(f)}),!n.clearTablesBeforeImport)return [3,5];m=0,g=e.tables,b.label=2;case 2:return m<g.length?(_=g[m],c.includes(_.name)?[3,4]:[4,_.clear()]):[3,5];case 3:b.sent(),b.label=4;case 4:return m++,[3,2];case 5:return n.noTransaction?[4,r()]:[3,7];case 6:return b.sent(),[3,9];case 7:return [4,e.transaction("rw",e.tables,r)];case 8:b.sent(),b.label=9;case 9:return f.done=true,h&&On.ignoreTransaction(function(){return h(f)}),[2]}})})}function xy(e,t){return Ho(this,void 0,void 0,function(){var n,r;return Or(this,function(o){switch(o.label){case 0:n="slice"in e?oS(e):e,o.label=1;case 1:return n.eof()?[3,3]:[4,n.pullAsync(t)];case 2:return o.sent(),n.result.data&&n.result.data.data?[3,3]:[3,1];case 3:if(r=n.result,!r||r.formatName!="dexie")throw new Error("Given file is not a dexie export");if(r.formatVersion>tS)throw new Error("Format version ".concat(r.formatVersion," not supported"));if(!r.data)throw new Error("No data in export file");if(!r.data.databaseName)throw new Error("Missing databaseName in export file");if(!r.data.databaseVersion)throw new Error("Missing databaseVersion in export file");if(!r.data.tables)throw new Error("Missing tables in export file");return [2,n]}})})}On.prototype.export=function(e){return vy(this,e)};On.prototype.import=function(e,t){return Fd(this,e,t)};On.import=function(e,t){return iS(e,t)};async function sS(e){Ie.info("Running migration_20250609: Migrating legacy user data format");let t=0;await e.table("users").toCollection().modify(r=>{r.core&&r.avatar||(Ds(r),Ie.debug(`Migrated user: ${r.rest_id}`),r.twe_private_fields.migrated_at=Date.now(),t++);});let n=0;await e.table("tweets").toCollection().modify(r=>{var s,l,c,h,f,m;const o=(l=(s=r.core)==null?void 0:s.user_results)==null?void 0:l.result;if(o&&o.core&&o.avatar)return;Ds(o),Ie.debug(`Migrated tweet user: ${r.rest_id} `);const a=ii(r);(h=(c=a==null?void 0:a.core)==null?void 0:c.user_results)!=null&&h.result&&(Ds(a.core.user_results.result),Ie.debug(`Migrated retweeted user: ${a.rest_id}`));const i=Id(r);(m=(f=i==null?void 0:i.core)==null?void 0:f.user_results)!=null&&m.result&&(Ds(i.core.user_results.result),Ie.debug(`Migrated quoted user: ${i.rest_id}`)),r.twe_private_fields.migrated_at=Date.now(),n++;}),Ie.info(`Migration completed: ${t} users and ${n} tweets updated.`);}function Ds(e){const t=e;if(!(t!=null&&t.legacy)){Ie.debug("migrateFromLegacyUser",e),Ie.warn(`User ${e==null?void 0:e.rest_id} has no legacy data to migrate.`);return}e.core??(e.core={created_at:t.legacy.created_at,name:t.legacy.name,screen_name:t.legacy.screen_name}),e.avatar??(e.avatar={image_url:t.legacy.profile_image_url_https}),e.verification??(e.verification={verified:t.legacy.verified,verified_type:t.legacy.verified_type}),e.relationship_perspectives??(e.relationship_perspectives={following:t.legacy.following,followed_by:t.legacy.followed_by}),e.dm_permissions??(e.dm_permissions={can_dm:t.legacy.can_dm}),e.privacy??(e.privacy={protected:t.legacy.protected}),e.location??(e.location={location:t.legacy.location});}function lS(e){const t=Array.from(new Set(e.map(a=>a.relation_type))).sort(),n=Array.from(new Set(e.map(a=>a.subject_user_id))).sort(),r=Array.from(new Set(e.map(a=>String(a.subject_screen_name||"").trim()).filter(Boolean))).sort(),o=Math.max(...e.map(a=>Number(a.observed_at)||0),0);return {relation_types:t,subject_user_ids:n,subject_screen_names:r,last_observed_at:o,edge_count:e.length}}function cS(e,t){if(!e.length||!t.length)return e;const n=new Map;for(const r of t){const o=String(r.related_user_id||"").trim();if(!o)continue;const a=n.get(o);a?a.push(r):n.set(o,[r]);}return e.map(r=>{const o=n.get(String(r.rest_id||"").trim());return o!=null&&o.length?{...r,twe_relationship_fields:lS(o)}:r})}const jc="__twe_perf_events_v1",Nh="__twe_perf_summary_v1",uS="twe:perf-event-v1",Bh=1e3;let Uh=false;function Sy(){return globalThis}function dS(){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?crypto.randomUUID():`perf-${Date.now()}-${Math.random().toString(36).slice(2,10)}`}function Cy(){const e=Sy();return Array.isArray(e[jc])||(e[jc]=[]),e[jc]}function Yl(){const e=Sy(),t=e[Nh];if(!t||typeof t!="object"){const r={buckets:{},counters:{},workers:{}};return e[Nh]=r,r}const n=t;return n.buckets||(n.buckets={}),n.counters||(n.counters={}),n.workers||(n.workers={}),n}function fS(e,t){return `${e}:${t}`}function $h(e,t){var o;if(!e.length)return 0;const n=[...e].sort((a,i)=>a-i),r=Math.min(n.length-1,Math.max(0,Math.ceil(n.length*t)-1));return Number(((o=n[r])==null?void 0:o.toFixed(2))||0)}function hS(e){if(!e)return;const t={};for(const[n,r]of Object.entries(e))if(r!==void 0){if(typeof r=="string"){t[n]=r.length>160?`${r.slice(0,160)}...`:r;continue}t[n]=r;}return t}function Be(e){const t={schema:"twe.perf.event.v1",id:dS(),name:e.name,kind:e.kind,atMs:Date.now(),durationMs:Number.isFinite(e.durationMs)?Number(e.durationMs):void 0,value:Number.isFinite(e.value)?Number(e.value):void 0,tags:hS(e.tags)},n=Cy();n.push(t),n.length>Bh&&n.splice(0,n.length-Bh);const r=Yl();if(r.counters[`${t.kind}:${t.name}:count`]=(r.counters[`${t.kind}:${t.name}:count`]||0)+1,typeof t.value=="number"&&(r.counters[`${t.kind}:${t.name}:value`]=t.value),typeof t.durationMs=="number"){const o=fS(t.kind,t.name),a=r.buckets[o]||{count:0,totalMs:0,maxMs:0,values:[]};a.count+=1,a.totalMs+=t.durationMs,a.maxMs=Math.max(a.maxMs,t.durationMs),a.values.push(t.durationMs),a.values.length>300&&a.values.splice(0,a.values.length-300),r.buckets[o]=a;}if(typeof window<"u"&&typeof window.dispatchEvent=="function")try{window.dispatchEvent(new CustomEvent(uS,{detail:t}));}catch{}return t}function Do(e,t=1){const n=Yl();n.counters[e]=(n.counters[e]||0)+t;}function Ga(e,t){const n=Yl();e==="search"?n.workers.searchWorkerAvailable=t:n.workers.exportWorkerAvailable=t,Be({kind:"worker",name:`${e}-availability`,value:t?1:0});}function pS(){const e=[...Cy()],t=Yl(),n={};for(const[r,o]of Object.entries(t.buckets))n[r]={count:o.count,p50Ms:$h(o.values,.5),p95Ms:$h(o.values,.95),maxMs:Number(o.maxMs.toFixed(2)),avgMs:o.count?Number((o.totalMs/o.count).toFixed(2)):0};return {schema:"twe.perf.diagnostics.v1",generatedAtMs:Date.now(),eventsBuffered:e.length,buckets:n,counters:{...t.counters},workers:{...t.workers},recent:e.slice(-100)}}function qe(){return typeof performance<"u"&&typeof performance.now=="function"?performance.now():Date.now()}function mS(){if(!Uh){Uh=true;try{const e=globalThis.PerformanceObserver;if(!e)return;const t=e.supportedEntryTypes;if(Array.isArray(t)&&!t.includes("longtask"))return;new e(r=>{for(const o of r.getEntries())Be({kind:"longtask",name:"main-thread-longtask",durationMs:o.duration,tags:{entryType:o.entryType}});}).observe({entryTypes:["longtask"]});}catch{}}}function gS(){try{const e=globalThis.unsafeWindow;if(e&&typeof e=="object")return e}catch{}try{if(typeof window<"u")return window}catch{}return globalThis}const Ty="__twe_db_mutation_v1",yS="twe-db-mutation-v1",My=ri(0),Hh=new Map;let jh=false,$i=null;function Ry(e){let t=Hh.get(e);return t||(t=ri(0),Hh.set(e,t)),t}function Iy(e){if(e){Ry(e).value+=1;return}My.value+=1;}function _S(e){if(!e||typeof e!="object")return null;const t=e;return {extension:typeof t.extension=="string"?t.extension:void 0,operation:typeof t.operation=="string"?t.operation:void 0}}function qh(e){const t=_S(e);t&&Iy(t==null?void 0:t.extension);}function Ey(){if(!(jh||typeof window>"u")&&(jh=true,window.addEventListener("storage",e=>{if(!(e.key!==Ty||!e.newValue))try{const t=JSON.parse(e.newValue);qh(t);}catch{}}),typeof BroadcastChannel<"u"))try{$i=new BroadcastChannel(yS),$i.onmessage=e=>{qh(e.data);};}catch{$i=null;}}function Dn(e={}){Ey();const t={extension:e.extension,operation:e.operation,at:Date.now(),nonce:Math.random().toString(36).slice(2)};if(Iy(t.extension),$i)try{$i.postMessage(t);}catch{}try{typeof localStorage<"u"&&localStorage.setItem(Ty,JSON.stringify(t));}catch{}Yb({ts:t.at||Date.now(),extension:e.extension,operation:e.operation,count:typeof e.count=="number"?e.count:void 0,keys:Array.isArray(e.keys)?e.keys.slice(0,20):void 0});}function ho(e){Ey();const t=My.value;return e?t+Ry(e).value:t}const Vh="twitter-web-exporter",wS=10,Ps="__twe_capture_counts_v1",Os="__twe_capture_counts_v2",qc="__twe_active_db_name_v1",Pa="__twe_capture_index_revisions_v1",Oa="__twe_folder_source_index_revisions_v1",zh="twe:capture-count-updated-v1",Vc=500,nr=256,oa=256,bS=1e3,vS=1500,Mo=0,jr=Number.MAX_SAFE_INTEGER,Ro="",Io="￿",kS=["__bookmark_folder_id","__bookmark_folder_name","__bookmark_folder_name_source","__bookmark_folder_url"];function zc(e,t){if(e.length<=t)return [e];const n=[];for(let r=0;r<e.length;r+=t)n.push(e.slice(r,r+t));return n}function rn(e,t){let n=e;for(const r of t.split(".")){if(!n||typeof n!="object")return;n=n[r];}return n}function wn(e){return typeof e=="string"?e.trim():typeof e=="number"&&Number.isFinite(e)?String(e):""}function Fa(e){return e===xt.USER?"user":e===xt.TWEET?"tweet":""}function Kh(e){if(e)return {createdAt:Number(e.created_at)||0,captureId:e.id}}function Eo(e){if(e)return {observedAtMs:Number(e.observed_at_ms||e.created_at_ms||e.updated_at_ms)||0,documentId:e.id}}function xS(e){return e.folder_id&&e.folder_name?"api-name":e.folder_id?"id-only":"none"}function Fs(e){let t=0;for(let n=0;n<e.length;n+=1)t=t*31+e.charCodeAt(n)|0;return Math.abs(t).toString(36)}function La(e){return [...new Set(e.map(t=>t.trim()).filter(Boolean))].join(" ")}function SS(e,t){if(!e||typeof e!="object")return t;const n={...t},r=e;for(const o of kS){const a=r[o],i=t[o];if(i===void 0&&a!==void 0){n[o]=a;continue}if(i===null&&a!==void 0&&a!==null){n[o]=a;continue}if(o==="__bookmark_folder_name_source"){const s=String(i||""),l=String(a||"");s==="id-only"&&l==="api"&&(n[o]=l);}}return n}class CS{constructor(){je(this,"db");je(this,"ready");je(this,"writeQueue",Promise.resolve());je(this,"captureIndexBuilds",new Map);je(this,"captureIndexRevisionFallback",new Map);var r;let t="unknown";try{t=((r=gS().__META_DATA__)==null?void 0:r.userId)??"unknown";}catch{t="unknown";}const n=ut.get("dedicatedDbForAccounts")?`_${t}`:"";Ie.debug(`Using database: ${Vh}${n} for userId: ${t}`),this.db=new On(`${Vh}${n}`),this.publishActiveDatabaseName(),this.ready=this.init();}async whenReady(){await this.ready;}enqueueWrite(t,n){const r=this.writeQueue.then(n,n);return this.writeQueue=r.then(()=>{},()=>{}),r.catch(o=>{throw this.logError(o,t),o})}tweets(){return this.db.table("tweets")}users(){return this.db.table("users")}captures(){return this.db.table("captures")}captureIndexPages(){return this.db.table("capture_index_pages")}folderSourceIndexPages(){return this.db.table("folder_source_index_pages")}socialEdges(){return this.db.table("social_edges")}importedBundles(){return this.db.table("imported_bundles")}importedBundleCollections(){return this.db.table("imported_bundle_collections")}importedBundleItems(){return this.db.table("imported_bundle_items")}importedEntitySnapshots(){return this.db.table("imported_entity_snapshots")}importedBundleImportReports(){return this.db.table("imported_bundle_import_reports")}searchDocuments(){return this.db.table("search_documents")}normalizeFolderSourceIds(t){return [...new Set(t.map(n=>String(n||"").trim()).filter(Boolean))].sort()}folderSourceIndexRevisionId(t){return [this.db.name,t].join("|")}folderSourceHash(t){return Fs(t)}folderSourceIndexPageId(t){return [this.folderSourceHash(t.sourceKey),Math.max(0,Math.floor(t.sourceCount)),Math.max(0,Math.floor(t.sourceRevision)),Math.max(0,Math.floor(t.pageStart))].join("|")}readFolderSourceIndexRevisionMap(){const t=r=>{if(!r||typeof r!="object")return null;const o=r[Oa];if(!o||typeof o!="object")return null;const a={};for(const[i,s]of Object.entries(o)){const l=Number(s);Number.isFinite(l)&&l>=0&&(a[i]=Math.floor(l));}return a};let n={};try{n={...n,...t(globalThis)??{}};}catch{}try{typeof window<"u"&&(n={...n,...t(window)??{}});}catch{}try{if(typeof localStorage<"u"){const r=localStorage.getItem(Oa);r&&(n={...n,...t({[Oa]:JSON.parse(r)})??{}});}}catch{}return n}writeFolderSourceIndexRevisionMap(t){try{const n={};for(const[r,o]of Object.entries(t)){const a=Number(o);Number.isFinite(a)&&a>=0&&(n[r]=Math.floor(a));}globalThis[Oa]=n,typeof window<"u"&&(window[Oa]=n),typeof localStorage<"u"&&localStorage.setItem(Oa,JSON.stringify(n));}catch{}}bumpFolderSourceIndexRevision(t){const n=this.folderSourceIndexRevisionId(t),r=this.readFolderSourceIndexRevisionMap(),o=Math.max(0,Math.floor(Number(r[n])||0))+1;return r[n]=o,this.writeFolderSourceIndexRevisionMap(r),o}readFolderSourceIndexRevision(t){const n=this.folderSourceIndexRevisionId(t),r=this.readFolderSourceIndexRevisionMap();return Math.max(0,Math.floor(Number(r[n])||0))}async deleteFolderSourceIndexPages(t){if(!t){await this.folderSourceIndexPages().clear().catch(n=>this.logError(n,"deleteFolderSourceIndexPages:clear"));return}await this.folderSourceIndexPages().where("extension_name").equals(t).delete().catch(n=>this.logError(n,"deleteFolderSourceIndexPages:extension"));}async invalidateFolderSourceIndexPages(t){if(t){this.bumpFolderSourceIndexRevision(t),await this.deleteFolderSourceIndexPages(t);return}const n=this.readFolderSourceIndexRevisionMap(),r=`${this.db.name}|`;for(const o of Object.keys(n).filter(a=>a.startsWith(r)))n[o]=Math.max(0,Math.floor(Number(n[o])||0))+1;this.writeFolderSourceIndexRevisionMap(n),await this.deleteFolderSourceIndexPages();}searchDocumentExtensionNames(t){return [...new Set(t.map(n=>String(n.extension_name||"").trim()).filter(Boolean))]}async invalidateFolderSourceIndexPagesForExtensions(t){const n=[...new Set(t.map(r=>r.trim()).filter(Boolean))];if(n.length)for(const r of n)await this.invalidateFolderSourceIndexPages(r);}async extPutFolderSourceIndexPages(t){const n=this.normalizeFolderSourceIds(t.folderIds),r=n.join(`
`),o=Math.max(0,Math.floor(Number(t.sourceCount)||0)),a=Math.max(0,Math.floor(Number(t.sourceRevision)||0)),i=Date.now(),s=t.pages.map(l=>{const c=Math.max(0,Math.floor(Number(l.pageStart)||0));return {id:this.folderSourceIndexPageId({sourceKey:t.sourceKey,sourceCount:o,sourceRevision:a,pageStart:c}),source_hash:this.folderSourceHash(t.sourceKey),source_key:t.sourceKey,extension_name:t.extensionName,entity_type:t.entityType,folder_ids_key:r,source_count:o,source_revision:a,page_start:c,page_size:oa,row_ids:this.normalizeDataKeys(l.rowIds),cursor_after:l.cursorAfter,built_at_ms:i}});await this.enqueueWrite("extPutFolderSourceIndexPages",async()=>{await this.db.transaction("rw",this.folderSourceIndexPages(),async()=>{await this.folderSourceIndexPages().where("source_hash").equals(this.folderSourceHash(t.sourceKey)).filter(l=>l.source_key===t.sourceKey).delete(),s.length&&await this.bulkPutInChunks(this.folderSourceIndexPages(),s);});}),Be({kind:"db",name:"folder-source-index-pages-put",value:s.length,tags:{extName:t.extensionName,entityType:t.entityType,folderCount:n.length,sourceCount:o,sourceRevision:a}});}async extGetFolderSourceIndexedPage(t){var M;const n=qe(),r=Math.max(0,Math.floor(Number(t.sourceCount)||0));if(!r)return null;const o=Math.max(0,Math.floor(Number(t.offset)||0)),a=Math.max(1,Math.min(1e3,Number(t.limit)||100)),i=this.readFolderSourceIndexRevision(t.extensionName),s=Math.floor(o/oa)*oa,l=Math.max(o,o+a-1),c=Math.floor(l/oa)*oa,h=[];for(let P=s;P<=c;P+=oa)h.push(P);const f=h.map(P=>this.folderSourceIndexPageId({sourceKey:t.sourceKey,sourceCount:r,sourceRevision:i,pageStart:P})),m=await this.folderSourceIndexPages().bulkGet(f).catch(this.logError);if(!m||m.some(P=>!P))return Be({kind:"db",name:"folder-source-index-page-miss",durationMs:qe()-n,value:0,tags:{extName:t.extensionName,entityType:t.entityType,offset:o,limit:a,sourceCount:r,sourceRevision:i}}),null;const g=this.normalizeFolderSourceIds(t.folderIds).join(`
`),_=m;if(_.some(P=>P.source_key!==t.sourceKey||P.extension_name!==t.extensionName||P.entity_type!==t.entityType||P.folder_ids_key!==g||P.source_count!==r||P.source_revision!==i||P.page_size!==oa))return Be({kind:"db",name:"folder-source-index-page-stale",durationMs:qe()-n,value:0,tags:{extName:t.extensionName,entityType:t.entityType,offset:o,limit:a,sourceCount:r,sourceRevision:i}}),null;const b=_.sort((P,F)=>P.page_start-F.page_start),C=b.flatMap(P=>P.row_ids),k=o-s,T=C.slice(k,k+a);return Be({kind:"db",name:"folder-source-index-page",durationMs:qe()-n,value:T.length,tags:{extName:t.extensionName,entityType:t.entityType,folderCount:t.folderIds.length,offset:o,limit:a,sourceCount:r,sourceRevision:i,pages:f.length}}),{rowIds:T,cursorAfter:k+T.length===C.length?(M=b[b.length-1])==null?void 0:M.cursor_after:void 0}}async extGetCaptures(t){return this.captures().where("extension").equals(t).toArray().catch(this.logError)}async extGetCaptureCount(t,n){const r=qe(),o=await(n?this.captures().where("[extension+type]").equals([t,n]).count().catch(this.logError):this.captures().where("extension").equals(t).count().catch(this.logError))??0;return Be({kind:"db",name:"capture-count",durationMs:qe()-r,value:o,tags:{extName:t,type:n}}),o}async extGetCaptureDataKeys(t){const n=await this.extGetCaptures(t);return n?this.normalizeDataKeys(n.map(r=>r.data_key)):[]}async extGetCapturePage(t,n={}){const r=qe(),o=Math.max(0,Number(n.offset)||0),a=Math.max(1,Math.min(1e3,Number(n.limit)||100));let i=n.type?this.captures().where("[extension+type+created_at]").between([t,n.type,On.minKey],[t,n.type,On.maxKey]):this.captures().where("extension").equals(t);n.order!=="oldest"&&(i=i.reverse());let s=await i.offset(o).limit(a).toArray().catch(this.logError);s||(s=[]),n.type&&!s.every(c=>c.type===n.type)&&(s=s.filter(c=>c.type===n.type));const l=s.slice(0,a);return Be({kind:"db",name:"capture-page",durationMs:qe()-r,value:l.length,tags:{extName:t,type:n.type,offset:o,limit:a}}),l}async extGetCaptureIdsPage(t,n={}){const r=await this.extGetCapturePage(t,n);return this.normalizeDataKeys(r.map(o=>o.data_key))}captureIndexPageId(t){return [t.extName,t.type,t.order,Math.max(0,Math.floor(t.sourceCount)),Math.max(0,Math.floor(t.pageStart))].join("|")}captureIndexRevisionId(t,n){return [this.db.name,t,n].join("|")}readCaptureIndexRevisionMap(){const t=r=>{if(!r||typeof r!="object")return null;const o=r[Pa];if(!o||typeof o!="object")return null;const a={};for(const[i,s]of Object.entries(o)){const l=Number(s);Number.isFinite(l)&&l>=0&&(a[i]=Math.floor(l));}return a};let n={};try{n={...n,...t(globalThis)??{}};}catch{}try{typeof window<"u"&&(n={...n,...t(window)??{}});}catch{}try{if(typeof localStorage<"u"){const r=localStorage.getItem(Pa);r&&(n={...n,...t({[Pa]:JSON.parse(r)})??{}});}}catch{}for(const[r,o]of this.captureIndexRevisionFallback)n[r]=Math.max(Number(n[r])||0,o);return n}writeCaptureIndexRevisionMap(t){try{const n={};for(const[r,o]of Object.entries(t)){const a=Number(o);Number.isFinite(a)&&a>=0&&(n[r]=Math.floor(a),this.captureIndexRevisionFallback.set(r,Math.floor(a)));}globalThis[Pa]=n,typeof window<"u"&&(window[Pa]=n),typeof localStorage<"u"&&localStorage.setItem(Pa,JSON.stringify(n));}catch{}}readCaptureIndexRevision(t,n){const r=this.captureIndexRevisionId(t,n),o=this.readCaptureIndexRevisionMap(),a=Math.max(0,Math.floor(Number(o[r])||0));return this.captureIndexRevisionFallback.has(r)||this.captureIndexRevisionFallback.set(r,a),a}bumpCaptureIndexRevision(t,n){const r=this.captureIndexRevisionId(t,n),o=this.readCaptureIndexRevisionMap(),a=Math.max(0,Math.floor(Number(o[r])||0))+1;return o[r]=a,this.writeCaptureIndexRevisionMap(o),a}bumpAllCaptureIndexRevisions(){const t=this.readCaptureIndexRevisionMap(),n=`${this.db.name}|`;for(const r of new Set([...Object.keys(t).filter(o=>o.startsWith(n)),...[...this.captureIndexRevisionFallback.keys()].filter(o=>o.startsWith(n))]))t[r]=Math.max(0,Math.floor(Number(t[r])||0))+1;this.writeCaptureIndexRevisionMap(t);}async deleteCaptureIndexPagesForScope(t,n,r){await this.captureIndexPages().where("extension").equals(t).filter(o=>!(n&&o.type!==n||r&&o.order!==r)).delete().catch(o=>this.logError(o,"deleteCaptureIndexPagesForScope"));}async invalidateCaptureIndexPages(t,n,r={}){if(!t)return;const o=r.deletePages??true;if(n){this.bumpCaptureIndexRevision(t,n),o&&await this.deleteCaptureIndexPagesForScope(t,n);return}const a=await this.captureIndexPages().where("extension").equals(t).toArray().catch(this.logError)??[],i=new Set(a.map(s=>String(s.type||"")).filter(Boolean));if(!i.size){const s=`${this.db.name}|${t}|`;for(const l of Object.keys(this.readCaptureIndexRevisionMap()))if(l.startsWith(s)){const c=l.slice(s.length);c&&i.add(c);}}for(const s of i)this.bumpCaptureIndexRevision(t,s);o&&await this.deleteCaptureIndexPagesForScope(t);}async invalidateCaptureIndexPagesForRows(t){const n=new Map;for(const r of t){const o=String((r==null?void 0:r.extension)||"").trim(),a=String((r==null?void 0:r.type)||"").trim();if(!o||!a)continue;const i=n.get(o)??new Set;i.add(a),n.set(o,i);}for(const[r,o]of n)for(const a of o)await this.invalidateCaptureIndexPages(r,a);}async extPutCaptureIndexPagesFromOrderedCaptures(t,n,r,o,a="newest"){if(!r.length)return;const i=Math.max(0,Math.floor(Number(o)||0)),s=qe(),l=Date.now(),c=this.readCaptureIndexRevision(t,n),h=[];for(let f=0;f<r.length;f+=nr){const m=r.slice(f,f+nr);h.push({id:this.captureIndexPageId({extName:t,type:n,order:a,sourceCount:i,pageStart:f}),extension:t,type:n,order:a,source_count:i,source_revision:c,page_start:f,page_size:nr,data_keys:this.normalizeDataKeys(m.map(g=>g.data_key)),built_at_ms:l});}await this.enqueueWrite("extPutCaptureIndexPagesFromOrderedCaptures",async()=>{await this.db.transaction("rw",this.captureIndexPages(),async()=>{await this.deleteCaptureIndexPagesForScope(t,n,a),await this.bulkPutInChunks(this.captureIndexPages(),h);});}),Be({kind:"db",name:"capture-index-pages-put",durationMs:qe()-s,value:h.length,tags:{extName:t,type:n,order:a,sourceCount:i,sourceRevision:c}});}scheduleCaptureIndexPageBuild(t,n){const r=Math.max(0,Math.floor(Number(n.sourceCount)||0));if(r<bS)return;const o=n.order??"newest",a=[this.db.name,t,n.type,o,r].join("|");if(this.captureIndexBuilds.has(a))return;const i=new Promise((s,l)=>{globalThis.setTimeout(()=>{this.extBuildCaptureIndexPages(t,{type:n.type,order:o,sourceCount:r}).then(s,l);},vS);}).finally(()=>{this.captureIndexBuilds.delete(a);});this.captureIndexBuilds.set(a,i),i.catch(s=>{this.logError(s,"scheduleCaptureIndexPageBuild");});}async extBuildCaptureIndexPages(t,n){const r=qe(),o=n.order??"newest",a=typeof n.sourceCount=="number"&&Number.isFinite(n.sourceCount)?Math.max(0,Math.floor(n.sourceCount)):Math.max(0,Math.floor(Number(await this.extGetCaptureCount(t,n.type))||0));if(!a)return  false;const i=this.readCaptureIndexRevision(t,n.type),s=Date.now(),l=[];let c=0,h,f=[];for(;;){const _=await this.extGetCaptureCursorPage(t,{type:n.type,after:h,limit:1e3,order:o});for(f.push(...this.normalizeDataKeys(_.captures.map(b=>b.data_key)));f.length>=nr;){const b=f.slice(0,nr);f=f.slice(nr),l.push({id:this.captureIndexPageId({extName:t,type:n.type,order:o,sourceCount:a,pageStart:c}),extension:t,type:n.type,order:o,source_count:a,source_revision:i,page_start:c,page_size:nr,data_keys:b,built_at_ms:s}),c+=nr;}if(!_.hasAfter||!_.cursorAfter||!_.captures.length)break;h=_.cursorAfter;}f.length&&l.push({id:this.captureIndexPageId({extName:t,type:n.type,order:o,sourceCount:a,pageStart:c}),extension:t,type:n.type,order:o,source_count:a,source_revision:i,page_start:c,page_size:nr,data_keys:f,built_at_ms:s});const m=Math.max(0,Math.floor(Number(await this.extGetCaptureCount(t,n.type))||0)),g=this.readCaptureIndexRevision(t,n.type);return m!==a||g!==i?(Be({kind:"db",name:"capture-index-build-stale",durationMs:qe()-r,value:l.length,tags:{extName:t,type:n.type,order:o,expectedCount:a,currentCount:m,sourceRevision:i,currentRevision:g}}),false):(await this.enqueueWrite("extBuildCaptureIndexPages",async()=>{this.readCaptureIndexRevision(t,n.type)===i&&await this.db.transaction("rw",this.captureIndexPages(),async()=>{await this.deleteCaptureIndexPagesForScope(t,n.type,o),await this.bulkPutInChunks(this.captureIndexPages(),l);});}),Be({kind:"db",name:"capture-index-build",durationMs:qe()-r,value:l.length,tags:{extName:t,type:n.type,order:o,sourceCount:a,sourceRevision:i}}),true)}async extGetCaptureIdsIndexedPage(t,n){const r=qe(),o=Math.max(0,Math.floor(Number(n.sourceCount)||0));if(!o)return null;const a=Math.max(0,Math.floor(Number(n.offset)||0)),i=Math.max(1,Math.min(1e3,Number(n.limit)||100)),s=n.order??"newest",l=Math.floor(a/nr)*nr,c=Math.max(a,a+i-1),h=Math.floor(c/nr)*nr,f=[];for(let M=l;M<=h;M+=nr)f.push(M);const m=f.map(M=>this.captureIndexPageId({extName:t,type:n.type,order:s,sourceCount:o,pageStart:M})),g=await this.captureIndexPages().bulkGet(m).catch(this.logError);if(!g||g.some(M=>!M))return this.scheduleCaptureIndexPageBuild(t,{type:n.type,order:s,sourceCount:o}),Be({kind:"db",name:"capture-index-page-miss",durationMs:qe()-r,value:0,tags:{extName:t,type:n.type,offset:a,limit:i,order:s,sourceCount:o}}),null;const _=this.readCaptureIndexRevision(t,n.type),b=g;if(b.some(M=>M.source_revision!==_||M.source_count!==o||M.page_size!==nr))return this.scheduleCaptureIndexPageBuild(t,{type:n.type,order:s,sourceCount:o}),Be({kind:"db",name:"capture-index-page-stale",durationMs:qe()-r,value:0,tags:{extName:t,type:n.type,offset:a,limit:i,order:s,sourceCount:o,sourceRevision:_}}),null;const C=b.sort((M,P)=>M.page_start-P.page_start).flatMap(M=>M.data_keys),k=a-l,T=C.slice(k,k+i);return Be({kind:"db",name:"capture-index-page",durationMs:qe()-r,value:T.length,tags:{extName:t,type:n.type,offset:a,limit:i,order:s,sourceCount:o,sourceRevision:_,pages:m.length}}),T}async extGetCaptureCursorPage(t,n){const r=qe(),o=Math.max(1,Math.min(1e3,Number(n.limit)||100)),a=n.order??"newest",i=[t,n.type,Mo,Ro],s=[t,n.type,jr,Io];let l=i,c=s,h=true,f=true;const m=n.after??n.before;if(m){const T=[t,n.type,m.createdAt,m.captureId];n.before?a==="newest"?(l=T,h=false):(c=T,f=false):a==="newest"?(c=T,f=false):(l=T,h=false);}let g=this.captures().where("[extension+type+created_at+id]").between(l,c,h,f);a==="newest"&&(g=g.reverse());const _=await g.limit(o+1).toArray().catch(this.logError)??[],b=_.slice(0,o),C=_.length>o,k={captures:b,cursorBefore:Kh(b[0]),cursorAfter:Kh(b[b.length-1]),hasBefore:!!(n.after||n.before),hasAfter:C};return Be({kind:"db",name:"capture-cursor-page",durationMs:qe()-r,value:b.length,tags:{extName:t,type:n.type,limit:o,order:a,hasAfter:k.hasAfter,cursorCreatedAt:m==null?void 0:m.createdAt}}),k}async extGetCaptureIdsCursorPage(t,n){const r=await this.extGetCaptureCursorPage(t,n);return {...r,ids:this.normalizeDataKeys(r.captures.map(o=>o.data_key))}}async extGetTweetsByIds(t){const n=qe(),r=this.normalizeDataKeys(t);return r.length?this.tweets().bulkGet(r).then(o=>{const a=o.filter(i=>!!i&&this.filterEmptyData(i));return Be({kind:"db",name:"tweets-by-ids",durationMs:qe()-n,value:a.length,tags:{requested:r.length}}),a}).catch(this.logError):[]}async extGetUsersByIds(t){const n=qe(),r=this.normalizeDataKeys(t);return r.length?this.users().bulkGet(r).then(o=>{const a=o.filter(i=>!!i&&this.filterEmptyData(i));return Be({kind:"db",name:"users-by-ids",durationMs:qe()-n,value:a.length,tags:{requested:r.length}}),a}).catch(this.logError):[]}async extGetCapturedTweets(t,n){const r=n??await this.extGetCaptures(t);return r?this.extGetTweetsByIds(r.map(o=>o.data_key)):[]}async extGetCapturedUsers(t,n){const r=n??await this.extGetCaptures(t);if(!r)return [];const o=await this.extGetUsersByIds(r.map(a=>a.data_key))??[];return this.enrichUsersWithRelationshipContext(t,o)}async extGetSocialEdges(t){return this.socialEdges().where("extension").equals(t).toArray().catch(this.logError)}async extGetSearchDocuments(t,n){const r=qe(),o=Fa(n),i=(n&&o?await this.searchDocuments().where("[extension_name+entity_type]").equals([t,o]).toArray().catch(this.logError):await this.searchDocuments().where("extension_name").equals(t).toArray().catch(this.logError))??[];return Be({kind:"db",name:"search-documents",durationMs:qe()-r,value:i.length,tags:{extName:t,type:n}}),i}async extGetSearchDocumentPage(t,n={}){const r=qe(),o=n.entityType??Fa(n.type),a=Math.max(0,Math.floor(Number(n.offset)||0)),i=Math.max(1,Math.min(5e3,Number(n.limit)||1e3)),l=await(o?this.searchDocuments().where("[extension_name+entity_type]").equals([t,o]):this.searchDocuments().where("extension_name").equals(t)).offset(a).limit(i+1).toArray().catch(this.logError)??[],c=l.slice(0,i),h={documents:c,cursorBefore:Eo(c[0]),cursorAfter:Eo(c[c.length-1]),hasBefore:a>0,hasAfter:l.length>i};return Be({kind:"db",name:"search-document-page",durationMs:qe()-r,value:c.length,tags:{extName:t,type:n.type,entityType:o,offset:a,limit:i,hasAfter:h.hasAfter}}),h}async extGetSearchDocumentCount(t,n={}){const r=qe(),o=n.entityType??Fa(n.type),a=String(n.folderId||"").trim(),i=String(n.sourceKey||"").trim();let s=0;return o&&a&&!i?s=await this.searchDocuments().where("[extension_name+entity_type+folder_id+observed_at_ms+id]").between([t,o,a,Mo,Ro],[t,o,a,jr,Io],true,true).count().catch(this.logError)??0:i&&o?s=await this.searchDocuments().where("[source_key+entity_type]").equals([i,o]).filter(l=>!a||l.folder_id===a).count().catch(this.logError)??0:o?s=await this.searchDocuments().where("[extension_name+entity_type]").equals([t,o]).filter(l=>!a||l.folder_id===a).count().catch(this.logError)??0:s=await this.searchDocuments().where("extension_name").equals(t).filter(l=>!a||l.folder_id===a).count().catch(this.logError)??0,Be({kind:"db",name:"search-document-count",durationMs:qe()-r,value:s,tags:{extName:t,type:n.type,entityType:o,folderId:a,sourceKey:i}}),s}async extGetSearchDocumentFolderFacets(t,n={}){const r=qe(),o=n.entityType??Fa(n.type),a={"api-name":0,"id-only":0,none:0},i=new Map;let s=0;await(o?this.searchDocuments().where("[extension_name+entity_type]").equals([t,o]):this.searchDocuments().where("extension_name").equals(t)).each(h=>{s+=1;const f=xS(h);a[f]+=1;const m=String(h.folder_id||"").trim();if(!m)return;const g=String(h.folder_name||"").trim(),_=i.get(m);if(_){_.count+=1,g&&_.status!=="api-name"&&(_.label=g,_.status="api-name");return}i.set(m,{folderId:m,label:g||`Folder ${m}`,count:1,status:f});}).catch(this.logError);const c=[...i.values()].sort((h,f)=>f.count!==h.count?f.count-h.count:h.label.localeCompare(f.label));return Be({kind:"db",name:"search-document-folder-facets",durationMs:qe()-r,value:c.length,tags:{extName:t,type:n.type,entityType:o,totalDocuments:s}}),{totalDocuments:s,statusCounts:a,facets:c}}async extGetSearchDocumentFolderCursorPage(t,n){const r=qe(),o=n.entityType??Fa(n.type),a=String(n.folderId||"").trim(),i=Math.max(1,Math.min(1e3,Number(n.limit)||100)),s=n.order??"newest";if(!o||!a)return {documents:[],hasBefore:false,hasAfter:false};const l=[t,o,a,Mo,Ro],c=[t,o,a,jr,Io];let h=l,f=c,m=true,g=true;const _=n.after??n.before;if(_){const M=[t,o,a,_.observedAtMs,_.documentId];n.before?s==="newest"?(h=M,m=false):(f=M,g=false):s==="newest"?(f=M,g=false):(h=M,m=false);}let b=this.searchDocuments().where("[extension_name+entity_type+folder_id+observed_at_ms+id]").between(h,f,m,g);s==="newest"&&(b=b.reverse());const C=await b.limit(i+1).toArray().catch(this.logError)??[],k=C.slice(0,i),T={documents:k,cursorBefore:Eo(k[0]),cursorAfter:Eo(k[k.length-1]),hasBefore:!!(n.after||n.before),hasAfter:C.length>i};return Be({kind:"db",name:"search-document-folder-cursor-page",durationMs:qe()-r,value:k.length,tags:{extName:t,type:n.type,entityType:o,folderId:a,limit:i,order:s,hasAfter:T.hasAfter}}),T}async extGetSearchDocumentFolderPage(t,n){const r=qe(),o=n.entityType??Fa(n.type),a=String(n.folderId||"").trim(),i=Math.max(0,Math.floor(Number(n.offset)||0)),s=Math.max(1,Math.min(1e3,Number(n.limit)||100)),l=n.order??"newest";if(!o||!a)return {documents:[],hasBefore:false,hasAfter:false};const c=[t,o,a,Mo,Ro],h=[t,o,a,jr,Io];let f=this.searchDocuments().where("[extension_name+entity_type+folder_id+observed_at_ms+id]").between(c,h,true,true);l==="newest"&&(f=f.reverse());const m=await f.offset(i).limit(s+1).toArray().catch(this.logError)??[],g=m.slice(0,s),_={documents:g,cursorBefore:Eo(g[0]),cursorAfter:Eo(g[g.length-1]),hasBefore:i>0,hasAfter:m.length>s};return Be({kind:"db",name:"search-document-folder-page",durationMs:qe()-r,value:g.length,tags:{extName:t,type:n.type,entityType:o,folderId:a,offset:i,limit:s,order:l,hasAfter:_.hasAfter}}),_}searchDocumentHasMedia(t){var n,r;return !!((n=t.flags_json)!=null&&n.has_media||Number(((r=t.numeric_json)==null?void 0:r.media_count)||0)>0||Number(t.media_flag||0)>0)}async getSearchDocumentMediaScanRows(t,n,r,o){const a=await this.searchDocuments().where("[extension_name+entity_type]").equals([t,n]).filter(i=>r.size&&!r.has(String(i.folder_id||"").trim())?false:this.searchDocumentHasMedia(i)).toArray().catch(this.logError)??[];return a.sort((i,s)=>{const l=Number(i.observed_at_ms||0),c=Number(s.observed_at_ms||0);return l!==c?o==="newest"?c-l:l-c:o==="newest"?String(s.id).localeCompare(String(i.id)):String(i.id).localeCompare(String(s.id))}),a}async repairSearchDocumentMediaIndexes(t){const n=t.filter(r=>{var o,a;return this.searchDocumentHasMedia(r)&&(Number(r.media_flag||0)!==1||Number(((o=r.numeric_json)==null?void 0:o.media_count)||0)<=0||((a=r.flags_json)==null?void 0:a.has_media)!==true)}).map(r=>{var o;return {...r,media_flag:1,flags_json:{...r.flags_json??{},has_media:true},numeric_json:{...r.numeric_json??{},media_count:Math.max(1,Number(((o=r.numeric_json)==null?void 0:o.media_count)||0))}}});n.length&&await this.upsertSearchDocuments(n);}async extGetSearchDocumentMediaCount(t,n={}){const r=qe(),o=n.entityType??"tweet",a=new Set((n.folderIds??[]).map(g=>g.trim()).filter(Boolean)),i=await this.searchDocuments().where("[extension_name+entity_type+media_flag+observed_at_ms+id]").between([t,o,1,Mo,Ro],[t,o,1,jr,Io],true,true).filter(g=>!a.size||a.has(String(g.folder_id||"").trim())).count().catch(this.logError)??0,s=await this.searchDocuments().where("[extension_name+entity_type+numeric_json.media_count+observed_at_ms+id]").between([t,o,1,Mo,Ro],[t,o,jr,jr,Io],true,true).filter(g=>!a.size||a.has(String(g.folder_id||"").trim())).count().catch(this.logError)??0,l=await this.getSearchDocumentMediaScanRows(t,o,a,"newest"),c=l.length,h=Math.max(i,s);c>h&&await this.repairSearchDocumentMediaIndexes(l);const f=c>h?"legacy_flags_scan":i?"media_flag":s?"numeric_json":"none",m=Math.max(h,c);return Be({kind:"db",name:"search-document-media-count",durationMs:qe()-r,value:m,tags:{extName:t,entityType:o,folderIds:[...a].join(","),fallbackMode:f}}),m}async extGetSearchDocumentMediaCursorPage(t,n={}){const r=qe(),o=n.entityType??"tweet",a=new Set((n.folderIds??[]).map(I=>I.trim()).filter(Boolean)),i=Math.max(1,Math.min(1e3,Number(n.limit)||100)),s=Math.max(0,Math.floor(Number(n.offset)||0)),l=n.order??"newest",c=[t,o,1,Mo,Ro],h=[t,o,1,jr,Io];let f=c,m=h,g=true,_=true;const b=n.after??n.before;if(b){const I=[t,o,1,b.observedAtMs,b.documentId];n.before?l==="newest"?(f=I,g=false):(m=I,_=false):l==="newest"?(m=I,_=false):(f=I,g=false);}let C=this.searchDocuments().where("[extension_name+entity_type+media_flag+observed_at_ms+id]").between(f,m,g,_).filter(I=>!a.size||a.has(String(I.folder_id||"").trim()));l==="newest"&&(C=C.reverse());let k=false,T=await C.offset(b?0:s).limit(i+1).toArray().catch(this.logError)??[];if(!T.length&&!b){k=true;const I=[t,o,1,Mo,Ro],O=[t,o,jr,jr,Io];let B=this.searchDocuments().where("[extension_name+entity_type+numeric_json.media_count+observed_at_ms+id]").between(I,O,true,true).filter(D=>!a.size||a.has(String(D.folder_id||"").trim()));l==="newest"&&(B=B.reverse()),T=await B.offset(s).limit(i+1).toArray().catch(this.logError)??[];}const M=k?"numeric_json":"media_flag",P=T.slice(0,i),F={documents:P,cursorBefore:Eo(P[0]),cursorAfter:Eo(P[P.length-1]),hasBefore:!!(n.after||n.before||s>0),hasAfter:T.length>i};return Be({kind:"db",name:"search-document-media-cursor-page",durationMs:qe()-r,value:P.length,tags:{extName:t,entityType:o,folderIds:[...a].join(","),offset:b?0:s,limit:i,order:l,hasAfter:F.hasAfter,fallback:k,fallbackMode:M}}),F}async searchDocumentsForSource(t,n){const r=await this.searchDocuments().where("source_key").equals(t).toArray().catch(this.logError);return r?n?r.filter(o=>o.entity_type===n):r:[]}async bundleList(){return this.importedBundles().orderBy("updatedAt").reverse().toArray().catch(this.logError)}async bundleGet(t){return this.importedBundles().get(t).catch(this.logError)}async bundleGetCollections(t){return this.importedBundleCollections().where("bundle_id").equals(t).toArray().catch(this.logError)}async bundleGetItems(t,n=5e3){return this.importedBundleItems().where("bundle_id").equals(t).limit(n).toArray().catch(this.logError)}async bundleGetSnapshots(t,n=5e3){return this.importedEntitySnapshots().where("bundle_id").equals(t).limit(n).toArray().catch(this.logError)}async bundleGetSnapshotCount(t,n){return n?this.importedEntitySnapshots().where("[bundle_id+kind]").equals([t,n]).count().catch(this.logError):this.importedEntitySnapshots().where("bundle_id").equals(t).count().catch(this.logError)}async bundleGetSnapshotPage(t,n={}){const r=Math.max(0,Number(n.offset||0)),o=Math.max(1,Number(n.limit||5e3));return ((n.kind?await this.importedEntitySnapshots().where("[bundle_id+kind]").equals([t,n.kind]).toArray().catch(this.logError):await this.importedEntitySnapshots().where("bundle_id").equals(t).toArray().catch(this.logError))??[]).sort((i,s)=>{const l=Number(i.observed_at||i.created_at||i.updated_at||0),c=Number(s.observed_at||s.created_at||s.updated_at||0);return l!==c?n.order==="oldest"?l-c:c-l:s.id.localeCompare(i.id)}).slice(r,r+o)}async bundleGetSnapshotsByIds(t){const n=this.normalizeDataKeys(t);return n.length?this.importedEntitySnapshots().bulkGet(n).then(r=>r.filter(o=>!!o)).catch(this.logError):[]}async bundleSearchSnapshots(t,n,r=5e3){const o=n.trim().toLowerCase(),a=this.importedEntitySnapshots().where("bundle_id").equals(t);return o?a.filter(i=>String(i.search_text||"").toLowerCase().includes(o)).limit(r).toArray().catch(this.logError):a.limit(r).toArray().catch(this.logError)}async extAddTweets(t,n){const r=this.normalizeRowsByRestId(n);r.length&&await this.enqueueWrite("extAddTweets",async()=>{const o=Date.now(),a=r.map(s=>({id:`${t}-${s.rest_id}`,extension:t,type:xt.TWEET,data_key:s.rest_id,created_at:o})),i=this.buildTweetSearchDocuments(t,r);await this.db.transaction("rw",this.tweets(),this.captures(),this.searchDocuments(),async()=>{await this.putMergedTweets(r),await this.bulkPutInChunks(this.captures(),a),await this.bulkPutInChunks(this.searchDocuments(),i);}),await this.invalidateCaptureIndexPages(t,xt.TWEET),await this.invalidateFolderSourceIndexPages(t),Dn({extension:t,operation:"extAddTweets",count:r.length,keys:r.map(s=>s.rest_id)}),this.publishCaptureCountSnapshot(t);});}async extAddUsers(t,n){const r=this.normalizeRowsByRestId(n);r.length&&await this.enqueueWrite("extAddUsers",async()=>{const o=Date.now(),a=r.map(s=>({id:`${t}-${s.rest_id}`,extension:t,type:xt.USER,data_key:s.rest_id,created_at:o})),i=this.buildUserSearchDocuments(t,r);await this.db.transaction("rw",this.users(),this.captures(),this.searchDocuments(),async()=>{await this.putUsers(r),await this.bulkPutInChunks(this.captures(),a),await this.bulkPutInChunks(this.searchDocuments(),i);}),await this.invalidateCaptureIndexPages(t,xt.USER),await this.invalidateFolderSourceIndexPages(t),Dn({extension:t,operation:"extAddUsers",count:r.length,keys:r.map(s=>s.rest_id)}),this.publishCaptureCountSnapshot(t);});}async extAddCustomCaptures(t,n){if(!n.length)return;const r=[];for(const o of n){const a=String(o.id||"").trim(),i=String(o.data_key||"").trim();!a||!i||r.push({id:`${t}-${a}`,extension:t,type:xt.CUSTOM,data_key:i,created_at:Number(o.created_at)||Date.now()});}r.length&&await this.enqueueWrite("extAddCustomCaptures",async()=>{await this.db.transaction("rw",this.captures(),async()=>{await this.bulkPutInChunks(this.captures(),r);}),await this.invalidateCaptureIndexPages(t,xt.CUSTOM),Dn({extension:t,operation:"extAddCustomCaptures",count:r.length,keys:r.map(o=>o.data_key)}),this.publishCaptureCountSnapshot(t);});}async extAddSocialEdges(t,n){const r=n.map(o=>({...o,extension:t,observed_at:Number(o.observed_at)||Date.now()})).filter(o=>o.subject_user_id&&o.related_user_id&&o.relation_type&&o.id);r.length&&await this.enqueueWrite("extAddSocialEdges",async()=>{await this.db.transaction("rw",this.socialEdges(),async()=>{await this.bulkPutInChunks(this.socialEdges(),r);}),Dn({extension:t,operation:"extAddSocialEdges",count:r.length,keys:r.map(o=>o.id)});});}async extAddTweetCaptureIds(t,n,r){const o=this.normalizeDataKeys(n);o.length&&await this.enqueueWrite("extAddTweetCaptureIds",async()=>{await this.db.transaction("rw",this.tweets(),this.captures(),this.searchDocuments(),async()=>{const a=[];for(const i of zc(o,Vc))a.push(...await this.tweets().where("rest_id").anyOf(i).toArray());r&&a.length&&await this.bulkPutInChunks(this.tweets(),a.map(i=>r(i))),await this.bulkPutInChunks(this.captures(),o.map(i=>({id:`${t}-${i}`,extension:t,type:xt.TWEET,data_key:i,created_at:Date.now()}))),await this.bulkPutInChunks(this.searchDocuments(),this.buildTweetSearchDocuments(t,a));}),await this.invalidateCaptureIndexPages(t,xt.TWEET),await this.invalidateFolderSourceIndexPages(t),Dn({extension:t,operation:"extAddTweetCaptureIds",count:o.length,keys:o}),this.publishCaptureCountSnapshot(t);});}async extBackfillTweetCapturesFromAllTweets(t){if(await this.extGetCaptureCount(t))return;const r=await this.tweets().toCollection().primaryKeys().then(o=>o.map(a=>String(a||"")).filter(Boolean)).catch(this.logError);r!=null&&r.length&&await this.extAddTweetCaptureIds(t,r);}async extRemoveTweetCaptureIds(t,n,r){const o=this.normalizeDataKeys(n);o.length&&(await this.db.transaction("rw",this.tweets(),this.captures(),this.searchDocuments(),async()=>{if(r){const a=await this.tweets().where("rest_id").anyOf(o).toArray();a.length&&await this.tweets().bulkPut(a.map(i=>r(i)));}await this.captures().bulkDelete(o.map(a=>`${t}-${a}`)),await this.searchDocuments().bulkDelete(o.map(a=>`live:${t}:tweet:${a}`));}).catch(this.logError),await this.invalidateCaptureIndexPages(t,xt.TWEET),await this.invalidateFolderSourceIndexPages(t),Dn({extension:t,operation:"extRemoveTweetCaptureIds",count:o.length,keys:o}),this.publishCaptureCountSnapshot(t));}async extAddUserCaptureIds(t,n,r){const o=this.normalizeDataKeys(n);o.length&&(await this.db.transaction("rw",this.users(),this.captures(),this.searchDocuments(),async()=>{let a=[];r?(a=await this.users().where("rest_id").anyOf(o).toArray(),a.length&&await this.users().bulkPut(a.map(i=>r(i)))):a=await this.users().where("rest_id").anyOf(o).toArray(),await this.captures().bulkPut(o.map(i=>({id:`${t}-${i}`,extension:t,type:xt.USER,data_key:i,created_at:Date.now()}))),await this.searchDocuments().bulkPut(this.buildUserSearchDocuments(t,a));}).catch(this.logError),await this.invalidateCaptureIndexPages(t,xt.USER),await this.invalidateFolderSourceIndexPages(t),Dn({extension:t,operation:"extAddUserCaptureIds",count:o.length,keys:o}),this.publishCaptureCountSnapshot(t));}async extRemoveUserCaptureIds(t,n,r){const o=this.normalizeDataKeys(n);o.length&&(await this.db.transaction("rw",this.users(),this.captures(),this.searchDocuments(),async()=>{if(r){const a=await this.users().where("rest_id").anyOf(o).toArray();a.length&&await this.users().bulkPut(a.map(i=>r(i)));}await this.captures().bulkDelete(o.map(a=>`${t}-${a}`)),await this.searchDocuments().bulkDelete(o.map(a=>`live:${t}:user:${a}`));}).catch(this.logError),await this.invalidateCaptureIndexPages(t,xt.USER),await this.invalidateFolderSourceIndexPages(t),Dn({extension:t,operation:"extRemoveUserCaptureIds",count:o.length,keys:o}),this.publishCaptureCountSnapshot(t));}async bundlePutImportBatch(t){var o;const n=Date.now(),r={...t.bundle,updatedAt:n};await this.db.transaction("rw",[this.importedBundles(),this.importedBundleCollections(),this.importedBundleItems(),this.importedEntitySnapshots(),this.importedBundleImportReports(),this.searchDocuments()],async()=>{var a,i,s;await this.importedBundles().put(r),(a=t.collections)!=null&&a.length&&await this.importedBundleCollections().bulkPut(t.collections),(i=t.items)!=null&&i.length&&await this.importedBundleItems().bulkPut(t.items),(s=t.snapshots)!=null&&s.length&&(await this.importedEntitySnapshots().bulkPut(t.snapshots),await this.searchDocuments().bulkPut(this.buildImportedSnapshotSearchDocuments(r.id,t.snapshots))),t.report&&await this.importedBundleImportReports().put(t.report);}).catch(this.logError),await this.invalidateFolderSourceIndexPages(),Dn({operation:"bundlePutImportBatch",count:((o=t.snapshots)==null?void 0:o.length)??0,keys:[r.id]});}async bundleMarkReady(t){await this.importedBundles().update(t,{status:"ready",updatedAt:Date.now()}).catch(this.logError),Dn({operation:"bundleMarkReady",keys:[t]});}async bundleMarkFailed(t,n){await this.importedBundles().update(t,{status:"failed",error:n,updatedAt:Date.now()}).catch(this.logError),Dn({operation:"bundleMarkFailed",keys:[t]});}async extClearCaptures(t){const n=await this.extGetCaptures(t);if(!n)return;const r=await this.db.transaction("rw",this.captures(),this.searchDocuments(),async()=>{const o=await this.captures().bulkDelete(n.map(i=>i.id)),a=n.map(i=>i.type===xt.TWEET?`live:${t}:tweet:${i.data_key}`:i.type===xt.USER?`live:${t}:user:${i.data_key}`:"").filter(Boolean);return a.length&&await this.searchDocuments().bulkDelete(a),o}).catch(this.logError);return Dn({extension:t,operation:"extClearCaptures",count:n.length,keys:n.map(o=>o.data_key)}),await this.invalidateCaptureIndexPages(t),await this.invalidateFolderSourceIndexPages(t),this.publishCaptureCountSnapshot(t),r}async extBackfillRecentBookmarkFolderName(t,n,r,o={}){if(!t||!n||!r)return {candidates:0,inspected:0,updated:0};const a=Math.max(1,Math.min(1e3,Number(o.candidateLimit)||250)),i=Math.max(100,Math.min(5e3,Number(o.recentCaptureScanLimit)||1800)),s=new Set;for(const h of o.candidateTweetIds||[]){if(typeof h!="string")continue;const f=h.trim();if(f&&(s.add(f),s.size>=a))break}if(s.size<a){const h=await this.captures().orderBy("created_at").reverse().limit(i).toArray().catch(this.logError);for(const f of h||[]){if((f==null?void 0:f.extension)!==t||(f==null?void 0:f.type)!==xt.TWEET)continue;const m=String((f==null?void 0:f.data_key)||"").trim();if(!(!m||s.has(m))&&(s.add(m),s.size>=a))break}}if(!s.size)return {candidates:0,inspected:0,updated:0};const l=[...s],c=await this.db.transaction("rw",this.tweets(),this.searchDocuments(),async()=>{const h=await this.tweets().where("rest_id").anyOf(l).toArray(),f=[];for(const m of h){const g=m;if(String(g.__bookmark_folder_id||"")!==n)continue;const _=String(g.__bookmark_folder_name||""),b=String(g.__bookmark_folder_name_source||"");_===r&&b==="api"||f.push({...m,__bookmark_folder_name:r,__bookmark_folder_name_source:"api"});}return f.length&&(await this.tweets().bulkPut(f),await this.searchDocuments().bulkPut(this.buildTweetSearchDocuments(t,f)),Dn({extension:t,operation:"bookmarkFolderNameBackfill"})),{candidates:l.length,inspected:h.length,updated:f.length}}).catch(h=>(this.logError(h),{candidates:l.length,inspected:0,updated:0}));return c.updated>0&&await this.invalidateFolderSourceIndexPages(t),c}async export(){return vy(this.db).catch(this.logError)}async import(t,n={}){const r=await Fd(this.db,t,{acceptMissingTables:true,acceptVersionDiff:true,progressCallback:n.progressCallback}).catch(o=>{throw this.logError(o,"import"),o});return this.bumpAllCaptureIndexRevisions(),await this.deleteAllCaptureIndexPages(),await this.invalidateFolderSourceIndexPages(),Dn({operation:"import"}),this.publishCaptureCountSnapshotForAllKnownExtensions(),r}async clear(){this.bumpAllCaptureIndexRevisions(),await this.deleteAllCaptures(),await this.deleteAllCaptureIndexPages(),await this.deleteAllSocialEdges(),await this.deleteAllSearchDocuments(),await this.invalidateFolderSourceIndexPages(),await this.deleteAllTweets(),await this.deleteAllUsers(),Dn({operation:"clear"}),this.publishCaptureCountSnapshotForAllKnownExtensions(),Ie.info("Database cleared");}async count(){try{return {tweets:await this.tweets().count(),users:await this.users().count(),captures:await this.captures().count(),social_edges:await this.socialEdges().count(),imported_bundles:await this.importedBundles().count(),imported_entity_snapshots:await this.importedEntitySnapshots().count(),search_documents:await this.searchDocuments().count(),folder_source_index_pages:await this.folderSourceIndexPages().count()}}catch(t){return this.logError(t),null}}async publishKnownCaptureCountSnapshot(t,n){await this.writeCaptureCountSnapshot(t,Math.max(0,Math.floor(Number(n)||0)));}async publishCaptureCountSnapshot(t){try{const n=Number(await this.extGetCaptureCount(t)||0);await this.writeCaptureCountSnapshot(t,n);}catch{}}async writeCaptureCountSnapshot(t,n){try{const r=this.db.name,o=Date.now(),a=globalThis,i=a[Ps],s=i&&typeof i=="object"?{...i}:{};s[t]=n;const l=a[Os],c=l&&typeof l=="object"?{...l}:{};c[t]={count:n,dbName:r,updatedAt:o},a[Ps]=s,a[Os]=c,typeof window<"u"&&(window[Ps]=s,window[Os]=c);try{typeof localStorage<"u"&&(localStorage.setItem(Ps,JSON.stringify(s)),localStorage.setItem(Os,JSON.stringify(c)));}catch{}try{if(typeof window<"u"&&typeof window.dispatchEvent=="function"){const h={extension:t,count:n,dbName:r,updatedAt:o};try{window.dispatchEvent(new CustomEvent(zh,{detail:h}));}catch{window.dispatchEvent(new Event(zh));}}}catch{}}catch{}}publishCaptureCountSnapshotForAllKnownExtensions(){this.captures().toArray().then(t=>{const n=new Set;for(const r of t)r!=null&&r.extension&&n.add(String(r.extension));return Promise.all([...n].map(r=>this.publishCaptureCountSnapshot(r)))}).catch(()=>{});}publishActiveDatabaseName(){try{const t=this.db.name,n=globalThis;n[qc]=t,typeof window<"u"&&(window[qc]=t),typeof localStorage<"u"&&localStorage.setItem(qc,t);}catch{}}buildTweetSearchDocuments(t,n){const r=Date.now(),o=[];for(const a of n){const i=a,s=String(a.rest_id||rn(i,"legacy.id_str")||"").trim();if(!s)continue;const l=wn(rn(i,"article.article_results.result.title")),c=wn(rn(i,"article.article_results.result.preview_text")),h=La([wn(rn(i,"note_tweet.note_tweet_results.result.text")),l,c,wn(rn(i,"legacy.full_text")),wn(rn(i,"legacy.text"))]),f=La([wn(rn(i,"quoted_status_result.result.note_tweet.note_tweet_results.result.text")),wn(rn(i,"quoted_status_result.result.legacy.full_text")),wn(rn(i,"quoted_status_result.result.legacy.text"))]),m=wn(rn(i,"core.user_results.result.core.screen_name")||rn(i,"core.screen_name")).toLowerCase(),g=wn(rn(i,"core.user_results.result.rest_id")||rn(i,"author_id")),_=wn(rn(i,"__bookmark_folder_id")),b=wn(rn(i,"__bookmark_folder_name")),C=ha(a),k=La([h,m,_,b]),T=La([wn(rn(i,"legacy.lang")),wn(rn(i,"card.name")),wn(rn(i,"card.card_platform.card_name"))]),M=fo(a).length,P=M>0,F=Fs([k,f,T].join(`
`));o.push({id:`live:${t}:tweet:${s}`,source_key:`live:${t}`,source_kind:"live",entity_type:"tweet",entity_id:s,extension_name:t,updated_at_ms:r,created_at_ms:C||void 0,observed_at_ms:r,primary_text:k,quoted_text:f||void 0,auxiliary_text:T||void 0,author_screen_name:m||void 0,author_id:g||void 0,folder_id:_||void 0,folder_name:b||void 0,media_flag:P?1:0,route_type:wn(rn(i,"__route_type"))||void 0,lang:wn(rn(i,"legacy.lang"))||void 0,flags_json:{has_media:P},exact_json:{author:m?[m,`@${m}`]:[],folder:[_,b].filter(Boolean)},numeric_json:{favorite_count:Number(rn(i,"legacy.favorite_count")||0),retweet_count:Number(rn(i,"legacy.retweet_count")||0),reply_count:Number(rn(i,"legacy.reply_count")||0),bookmark_count:Number(rn(i,"legacy.bookmark_count")||0),media_count:M},raw_ref_table:"tweets",raw_ref_key:s,doc_hash:F});}return o}buildUserSearchDocuments(t,n){var a;const r=Date.now(),o=[];for(const i of n){const s=i,l=String(i.rest_id||"").trim();if(!l)continue;const c=wn(rn(s,"core.screen_name")).toLowerCase(),h=wn(rn(s,"core.name")),f=wn(rn(s,"legacy.description")),m=La([c,h,f]);o.push({id:`live:${t}:user:${l}`,source_key:`live:${t}`,source_kind:"live",entity_type:"user",entity_id:l,extension_name:t,updated_at_ms:r,created_at_ms:Number(((a=i.twe_private_fields)==null?void 0:a.created_at)||0)||void 0,observed_at_ms:r,primary_text:m,author_screen_name:c||void 0,author_id:l,flags_json:{is_blue_verified:!!rn(s,"is_blue_verified")},exact_json:{author:c?[c,`@${c}`]:[]},raw_ref_table:"users",raw_ref_key:l,doc_hash:Fs(m)});}return o}buildImportedSnapshotSearchDocuments(t,n){const r=Date.now();return n.map(o=>{const a=o.data,i=o.kind==="tweet"||o.kind==="user"?cy(o):a,s=String(o.source_id||o.id).trim(),l=wn(o.search_text)||La([JSON.stringify(a)]),c=wn(rn(i,"__bookmark_folder_id")),h=wn(rn(i,"__bookmark_folder_name")),f=Number(rn(i,"twe_private_fields.media_count")||0);return {id:`bundle:${t}:${o.kind}:${o.id}`,source_key:`bundle:${t}`,source_kind:"bundle",entity_type:o.kind==="user"?"user":o.kind==="tweet"?"tweet":"bundle_item",entity_id:s,bundle_id:t,bundle_item_id:o.id,extension_name:o.source_extension,updated_at_ms:r,created_at_ms:o.created_at,observed_at_ms:o.observed_at,primary_text:l,folder_id:c||void 0,folder_name:h||void 0,media_flag:f>0?1:0,exact_json:{folder:[c,h].filter(Boolean)},numeric_json:{media_count:f},raw_ref_table:"imported_entity_snapshots",raw_ref_key:o.id,doc_hash:Fs(l)}})}async upsertSearchDocuments(t){if(!t.length)return;const n=qe(),r=this.searchDocumentExtensionNames(t);return this.enqueueWrite("upsertSearchDocuments",async()=>{const o=await this.db.transaction("rw",this.searchDocuments(),async()=>{await this.bulkPutInChunks(this.searchDocuments(),t);});return await this.invalidateFolderSourceIndexPagesForExtensions(r),Be({kind:"db",name:"search-documents-upsert",durationMs:qe()-n,value:t.length}),o})}async putSyntheticSeedRows(t){const n=t.users??[],r=t.tweets??[],o=t.captures??[],a=t.searchDocuments??[],i=n.length+r.length+o.length+a.length;if(!i)return;const s=qe(),l=this.searchDocumentExtensionNames(a);return this.enqueueWrite("putSyntheticSeedRows",async()=>{const c=await this.db.transaction("rw",this.users(),this.tweets(),this.captures(),this.searchDocuments(),async()=>{n.length&&await this.bulkPutInChunks(this.users(),n),r.length&&await this.bulkPutInChunks(this.tweets(),r),o.length&&await this.bulkPutInChunks(this.captures(),o),a.length&&await this.bulkPutInChunks(this.searchDocuments(),a);});return o.length&&await this.invalidateCaptureIndexPagesForRows(o),await this.invalidateFolderSourceIndexPagesForExtensions(l),Be({kind:"db",name:"synthetic-seed-bulk-put",durationMs:qe()-s,value:i,tags:{users:n.length,tweets:r.length,captures:o.length,searchDocuments:a.length}}),c})}async extBackfillSearchDocuments(t,n,r=640){const o=qe();if(!(n===xt.USER?"user":n===xt.TWEET?"tweet":null))return {processed:0,documents:0};let i=0,s=0,l=0;for(;;){const c=await this.extGetCapturePage(t,{type:n,offset:i,limit:r,order:"newest"});if(!c.length)break;const h=new Map(c.map(f=>[f.data_key,Number(f.created_at)||Date.now()]));if(n===xt.USER){const f=await this.extGetCapturedUsers(t,c)??[],m=this.buildUserSearchDocuments(t,f);m.forEach(g=>{g.observed_at_ms=h.get(g.raw_ref_key)||g.observed_at_ms;}),await this.upsertSearchDocuments(m),l+=m.length;}else {const f=await this.extGetCapturedTweets(t,c)??[],m=this.buildTweetSearchDocuments(t,f);m.forEach(g=>{g.observed_at_ms=h.get(g.raw_ref_key)||g.observed_at_ms;}),await this.upsertSearchDocuments(m),l+=m.length;}if(s+=c.length,i+=c.length,c.length<r)break}return Be({kind:"db",name:"search-documents-backfill",durationMs:qe()-o,value:l,tags:{extName:t,type:n,processed:s}}),Dn({extension:t,operation:"searchDocumentsBackfill"}),{processed:s,documents:l}}async putMergedTweets(t){if(!t.length)return;const n=this.normalizeDataKeys(t.map(i=>i.rest_id)),r=[];for(const i of zc(n,Vc))r.push(...await this.tweets().where("rest_id").anyOf(i).toArray());const o=new Map(r.map(i=>[String(i.rest_id),i])),a=t.map(i=>{const s={...i,twe_private_fields:{created_at:ha(i),updated_at:Date.now(),media_count:fo(i).length}};return SS(o.get(i.rest_id)??null,s)});await this.bulkPutInChunks(this.tweets(),a);}async putUsers(t){if(!t.length)return;const n=t.map(r=>({...r,twe_private_fields:{created_at:+Ja(r.core.created_at),updated_at:Date.now()}}));await this.bulkPutInChunks(this.users(),n);}async bulkPutInChunks(t,n){for(const r of zc(n,Vc))await t.bulkPut(r);}normalizeRowsByRestId(t){const n=new Map;for(const r of t){const o=String((r==null?void 0:r.rest_id)||"").trim();o&&n.set(o,{...r,rest_id:o});}return [...n.values()]}async upsertTweets(t){const n=this.normalizeRowsByRestId(t);if(n.length)return this.enqueueWrite("upsertTweets",async()=>{await this.db.transaction("rw",this.tweets(),async()=>{await this.putMergedTweets(n);});})}async upsertUsers(t){const n=this.normalizeRowsByRestId(t);if(n.length)return this.enqueueWrite("upsertUsers",async()=>{await this.db.transaction("rw",this.users(),async()=>{await this.putUsers(n);});})}async upsertCaptures(t){if(t.length)return this.enqueueWrite("upsertCaptures",async()=>{await this.db.transaction("rw",this.captures(),async()=>{await this.bulkPutInChunks(this.captures(),t);}),await this.invalidateCaptureIndexPagesForRows(t);})}async upsertSocialEdges(t){if(t.length)return this.enqueueWrite("upsertSocialEdges",async()=>{await this.db.transaction("rw",this.socialEdges(),async()=>{await this.bulkPutInChunks(this.socialEdges(),t);});})}async deleteAllTweets(){return this.tweets().clear().catch(this.logError)}async deleteAllUsers(){return this.users().clear().catch(this.logError)}async deleteAllCaptures(){return this.bumpAllCaptureIndexRevisions(),await this.deleteAllCaptureIndexPages(),this.captures().clear().catch(this.logError)}async deleteAllCaptureIndexPages(){return this.captureIndexPages().clear().catch(this.logError)}async deleteAllSocialEdges(){return this.socialEdges().clear().catch(this.logError)}async deleteAllSearchDocuments(){return await this.invalidateFolderSourceIndexPages(),this.searchDocuments().clear().catch(this.logError)}async bundleDelete(t){await this.db.transaction("rw",[this.importedBundles(),this.importedBundleCollections(),this.importedBundleItems(),this.importedEntitySnapshots(),this.importedBundleImportReports(),this.searchDocuments()],async()=>{const n=await this.importedBundleCollections().where("bundle_id").equals(t).primaryKeys(),r=await this.importedBundleItems().where("bundle_id").equals(t).primaryKeys(),o=await this.importedEntitySnapshots().where("bundle_id").equals(t).primaryKeys(),a=await this.importedBundleImportReports().where("bundle_id").equals(t).primaryKeys(),i=await this.searchDocuments().where("bundle_id").equals(t).primaryKeys();await this.importedBundleCollections().bulkDelete(n),await this.importedBundleItems().bulkDelete(r),await this.importedEntitySnapshots().bulkDelete(o),await this.importedBundleImportReports().bulkDelete(a),await this.searchDocuments().bulkDelete(i),await this.importedBundles().delete(t);}).catch(this.logError),await this.invalidateFolderSourceIndexPages(),Dn({operation:"bundleDelete",keys:[t]});}async enrichUsersWithRelationshipContext(t,n){if(!n.length||t!=="FollowersModule"&&t!=="FollowingModule")return n;const r=this.normalizeDataKeys(n.map(a=>a.rest_id));if(!r.length)return n;const o=await this.socialEdges().where("[extension+related_user_id]").anyOf(r.map(a=>[t,a])).toArray().catch(this.logError);return o!=null&&o.length?cS(n,o):n}normalizeDataKeys(t){const n=new Set;for(const r of t){const o=String(r||"").trim();o&&n.add(o);}return [...n]}filterEmptyData(t){if(!t)return Ie.warn("Empty data found in DB",t),false;if(t.__typename==="Tweet"){const n=t;return !n.legacy&&!n.article?(Ie.warn("Empty data found in DB",t),false):true}return t.legacy?true:(Ie.warn("Empty data found in DB",t),false)}async init(){const t=["rest_id","twe_private_fields.created_at","twe_private_fields.updated_at","twe_private_fields.media_count","core.user_results.result.core.screen_name","legacy.favorite_count","legacy.retweet_count","legacy.bookmark_count","legacy.quote_count","legacy.reply_count","views.count","legacy.favorited","legacy.retweeted","legacy.bookmarked"],n=["rest_id","twe_private_fields.created_at","twe_private_fields.updated_at","core.screen_name","legacy.followers_count","legacy.friends_count","legacy.statuses_count","legacy.favourites_count","legacy.listed_count","verification.verified_type","is_blue_verified","relationship_perspectives.following","relationship_perspectives.followed_by"],r=["id","extension","type","created_at","[extension+type]","[extension+type+created_at]","[extension+type+created_at+id]"],o=["id","extension","type","order","source_count","page_start","[extension+type+order+source_count+page_start]"],a=["id","source_hash","source_key","extension_name","entity_type","source_count","source_revision","page_start","[source_hash+source_count+source_revision+page_start]"],i=["id","extension","relation_type","subject_user_id","related_user_id","observed_at","[extension+relation_type]","[extension+subject_user_id]","[extension+related_user_id]"],s=["id","status","visibility","importedAt","updatedAt","recordCount"],l=["id","bundle_id","kind","[bundle_id+kind]"],c=["id","bundle_id","collection_id","record_id","kind","source_id","sort_time","[bundle_id+kind]","[bundle_id+sort_time]"],h=["id","bundle_id","kind","source_id","source_extension","observed_at","updated_at","[bundle_id+kind]","[kind+source_id]"],f=["id","bundle_id","started_at","finished_at","status"],m=["id","source_key","source_kind","entity_type","entity_id","extension_name","bundle_id","bundle_item_id","updated_at_ms","created_at_ms","observed_at_ms","author_screen_name","author_id","folder_id","media_flag","numeric_json.media_count","[source_key+entity_type]","[extension_name+entity_type]","[extension_name+entity_type+media_flag+observed_at_ms+id]","[extension_name+entity_type+numeric_json.media_count+observed_at_ms+id]","[extension_name+entity_type+folder_id+observed_at_ms]","[extension_name+entity_type+folder_id+observed_at_ms+id]","[bundle_id+entity_type]","[entity_type+entity_id]"];try{this.db.version(2).stores({tweets:t.join(","),users:n.join(","),captures:r.join(",")}).upgrade(async g=>{Ie.info("Upgrading database schema..."),await sS(g),Ie.info("Database upgraded");}),this.db.version(wS).stores({tweets:t.join(","),users:n.join(","),captures:r.join(","),capture_index_pages:o.join(","),folder_source_index_pages:a.join(","),social_edges:i.join(","),imported_bundles:s.join(","),imported_bundle_collections:l.join(","),imported_bundle_items:c.join(","),imported_entity_snapshots:h.join(","),imported_bundle_import_reports:f.join(","),search_documents:m.join(",")}),await this.db.open(),Ie.info(`Database connected: ${this.db.name}`);}catch(g){this.logError(g);}}logError(t,n){const r=t instanceof Error?t.message:String(t),o=n?`Database Error (${n})`:"Database Error";Ie.error(`${o}: ${r}`,t);}}function TS(e){return {schema:"scrollmark.result_source.v1",kind:"captures",extensionName:e.extensionName,extensionType:e.extensionType,sort:{kind:"observed_at",direction:e.direction??"desc"}}}function MS(e){return {schema:"scrollmark.result_source.v1",kind:"folder",extensionName:e.extensionName,entityType:e.entityType,folderIds:[...e.folderIds],sort:{kind:"observed_at",direction:e.direction??"desc"}}}function RS(e){var t;return {schema:"scrollmark.result_source.v1",kind:"media",extensionName:e.extensionName,entityType:"tweet",folderIds:(t=e.folderIds)!=null&&t.length?[...e.folderIds]:void 0,sort:{kind:"observed_at",direction:e.direction??"desc"}}}function Xl(e){return JSON.stringify(e)}const Wh="__scrollmark_result_source_diagnostics_v1",IS=24;function Ay(){const e=globalThis,t=e[Wh];if(t instanceof Map)return t;const n=new Map;return e[Wh]=n,n}function ma(e){const t=Ay();for(t.set(e.sourceKey,{schema:"scrollmark.result_source.diagnostics.v1",mode:e.descriptor.kind,updatedAtMs:e.updatedAtMs??Date.now(),...e});t.size>IS;){const n=[...t.entries()].sort((r,o)=>r[1].updatedAtMs-o[1].updatedAtMs)[0];if(!n)break;t.delete(n[0]);}}function ES(){return [...Ay().values()].sort((e,t)=>t.updatedAtMs-e.updatedAtMs)}const Gh=160;function Yh(e,t){const n=e[t];if(!(t<0||!n))return {index:t,id:n}}function AS(e,t,n){if(t.after){const r=e[t.after.index]===t.after.id?t.after.index:-1,o=e.indexOf(t.after.id);return Math.max(0,(r>=0?r:o)+1)}if(t.before){const r=e[t.before.index]===t.before.id?t.before.index:-1,o=e.indexOf(t.before.id);return Math.max(0,(r>=0?r:o)-n)}return Math.max(0,Math.floor(Number(t.startIndex)||0))}function Dy(e){const t=[...e.ids],n=Xl(e.descriptor),r=e.totalCount??t.length,o=async a=>{const i=performance.now(),s=Math.max(1,Math.min(1e3,Number(a.limit)||Gh)),l=AS(t,a,s),c=t.slice(l,l+s),h=await e.hydrateByIds(c),f={source:e.descriptor,totalCount:r,startIndex:l,rows:h,rowIds:c,hasBefore:l>0,hasAfter:l+c.length<r,cursorBefore:Yh(t,l),cursorAfter:Yh(t,l+c.length-1)};return ma({sourceKey:n,descriptor:e.descriptor,totalCount:r,cachedPages:0,cachedRows:0,lastFetchDurationMs:performance.now()-i,lastWindowRows:h.length,lastWindowStartIndex:l,lastCacheHit:false}),f};return {key:n,descriptor:e.descriptor,totalCount:async()=>r,getWindow:o,getByIds:e.hydrateByIds,streamRows:async function*(i={}){var c,h;let s=0;i.cursor&&(s=Math.max(0,i.cursor.index+1));const l=Math.max(1,Math.min(1e3,Number(i.batchSize)||Gh));for(;s<r&&!((c=i.signal)!=null&&c.aborted);){const f=await o({startIndex:s,limit:l});for(const m of f.rows){if((h=i.signal)!=null&&h.aborted)return;yield m;}if(!f.rowIds.length||!f.hasAfter)return;s+=f.rowIds.length;}}}}function DS(e){const t={schema:"scrollmark.result_source.v1",kind:"explicit-selection",extensionName:e.extensionName,entityType:e.entityType,ids:[...e.ids],source:e.source};return Dy({descriptor:t,ids:e.ids,hydrateByIds:e.hydrateByIds})}function PS(e){const t={schema:"scrollmark.result_source.v1",kind:"search",extensionName:e.extensionName,entityType:e.entityType,query:e.query,folderIds:e.folderIds,searchEngine:e.searchEngine??"worker-corpus",sort:{kind:"search_rank",direction:"desc"}};return Dy({descriptor:t,ids:e.ids,totalCount:e.totalCount,hydrateByIds:e.hydrateByIds})}const ni=160,Zl=10,OS=1e3,FS=5e3,Ls=256,LS=1e3,NS=1500,Kc="__twe_capture_counts_v2",BS="__twe_active_db_name_v1";class Ld{constructor(t=Zl){je(this,"entries",new Map);this.maxPages=t;}get(t){const n=this.entries.get(t);return n?(n.touchedAt=Date.now(),n.value):null}set(t,n){if(this.entries.set(t,{key:t,value:n,touchedAt:Date.now()}),this.entries.size<=this.maxPages)return;const r=[...this.entries.values()].sort((o,a)=>o.touchedAt-a.touchedAt);for(const o of r.slice(0,Math.max(0,this.entries.size-this.maxPages)))this.entries.delete(o.key);}get size(){return this.entries.size}get rowCount(){let t=0;for(const n of this.entries.values())t+=n.value.rows.length;return t}}function Ya(e,t,n){const r=Math.max(0,Math.floor(Number(t)||0));r>0&&!n||e.set(r,{index:r,cursorAfter:n});}function Py(e,t){let n=null;for(const r of e.values())r.index>t||(!n||r.index>n.index)&&(n=r);return !n||t-n.index>FS?null:n}function Nd(e){return JSON.stringify({startIndex:e.startIndex??0,limit:e.limit,after:e.after??null,before:e.before??null,direction:e.direction??"forward"})}function Oy(e){return [...new Set(e.map(t=>t.trim()).filter(Boolean))].sort()}function US(){try{const e=localStorage.getItem(BS);return (e==null?void 0:e.trim())??""}catch{return ""}}function Xh(e){var i;const t=[],n=US(),r=s=>{if(!s||typeof s!="object")return;const l=s[Kc];if(!l||typeof l!="object")return;const c=l[e];if(!c||typeof c!="object")return;const h=c,f=Number(h.count);if(!Number.isFinite(f)||f<0)return;const m=typeof h.dbName=="string"?h.dbName:"",g=Number(h.updatedAt);t.push({count:Math.floor(f),dbName:m,updatedAt:Number.isFinite(g)?g:0});};try{r(globalThis);}catch{}try{typeof window<"u"&&r(window);}catch{}try{const s=localStorage.getItem(Kc);s&&r({[Kc]:JSON.parse(s)});}catch{}const o=n?t.filter(s=>s.dbName===n):t,a=o.length?o:t;return a.sort((s,l)=>l.updatedAt!==s.updatedAt?l.updatedAt-s.updatedAt:l.count-s.count),((i=a[0])==null?void 0:i.count)??null}function Ao(e){if(e)return {observedAtMs:Number(e.observed_at_ms||e.created_at_ms||e.updated_at_ms)||0,documentId:e.id}}function Zh(e){if(e)return {createdAt:Number(e.created_at)||0,captureId:e.id}}function Qh(e,t){const n=Number(e.observed_at_ms||e.created_at_ms||e.updated_at_ms)||0,r=Number(t.observed_at_ms||t.created_at_ms||t.updated_at_ms)||0;return r!==n?r-n:t.id.localeCompare(e.id)}function Wc(e){const t=new Set,n=[];for(const r of e)t.has(r.id)||(t.add(r.id),n.push(r));return n}async function Jh(e,t){return e===xt.USER?await Ge.extGetUsersByIds(t)??[]:await Ge.extGetTweetsByIds(t)??[]}async function ep(e,t){return e==="user"?await Ge.extGetUsersByIds(t)??[]:e==="tweet"?await Ge.extGetTweetsByIds(t)??[]:[]}function $S(e){const t=TS({extensionName:e.extensionName,extensionType:e.extensionType,direction:"desc"}),n=new Ld(e.cachePages??Zl),r=new Map;Ya(r,0);const o=Xl(t);let a=Xh(e.extensionName),i=null;const s=async()=>{const h=Xh(e.extensionName);return h!==null?(a=h,h):(a!==null||(i||(i=Ge.extGetCaptureCount(e.extensionName,e.extensionType).then(f=>Number(f)||0).finally(()=>{i=null;})),a=await i),a)},l=async(h,f)=>{const m=Py(r,h);if(!m)return null;const g=h+f;let _=m.index,b=m.cursorAfter,C=false;const k=[];for(;_<g;){const T=await Ge.extGetCaptureIdsCursorPage(e.extensionName,{type:e.extensionType,after:b,limit:Math.min(1e3,Math.max(1,g-_)),order:"newest"});if(!T.captures.length){C=false;break}const M=_,P=_+T.captures.length,F=Math.max(0,h-M),I=Math.max(F,Math.min(T.captures.length,g-M));if(k.push(...T.captures.slice(F,I)),_=P,b=T.cursorAfter,C=T.hasAfter,Ya(r,_,b),!T.hasAfter||P<=M)break}return {captures:k,cursorBefore:Zh(k[0]),cursorAfter:Zh(k[k.length-1]),hasBefore:h>0,hasAfter:C||_>g}},c=async h=>{const f=performance.now(),m=Math.max(1,Math.min(1e3,Number(h.limit)||ni)),g={...h,limit:m,direction:h.direction??"forward"},_=Nd(g),b=n.get(_);if(b)return ma({sourceKey:o,descriptor:t,totalCount:b.totalCount,cachedPages:n.size,cachedRows:n.rowCount,lastFetchDurationMs:performance.now()-f,lastWindowRows:b.rows.length,lastWindowStartIndex:b.startIndex,lastCacheHit:true}),b;const C=s();let k=[],T,M,P=false,F=false,I=null;if(g.after||g.before){const D=await Ge.extGetCaptureIdsCursorPage(e.extensionName,{type:e.extensionType,after:g.after,before:g.before,limit:m,order:"newest"});k=D.ids,T=D.cursorBefore,M=D.cursorAfter,P=D.hasBefore,F=D.hasAfter;}else {const D=Math.max(0,Math.floor(Number(g.startIndex)||0));I=await C;const v=await Ge.extGetCaptureIdsIndexedPage(e.extensionName,{type:e.extensionType,offset:D,limit:m,order:"newest",sourceCount:I});if(v)k=v,P=D>0,F=D+k.length<I;else {const L=await l(D,m);L?(k=L.captures.map($=>$.data_key).filter(Boolean),T=L.cursorBefore,M=L.cursorAfter,P=L.hasBefore,F=L.hasAfter):(k=await Ge.extGetCaptureIdsPage(e.extensionName,{type:e.extensionType,offset:D,limit:m,order:"newest"}),P=D>0);}}I??(I=await C),F||(F=Math.max(0,Math.floor(Number(g.startIndex)||0))+k.length<I);const O=await Jh(e.extensionType,k),B={source:t,totalCount:I,startIndex:g.startIndex,rows:O,rowIds:k,hasBefore:P,hasAfter:F,cursorBefore:T,cursorAfter:M};return Ya(r,Math.max(0,Math.floor(Number(g.startIndex)||0))+k.length,M),n.set(_,B),ma({sourceKey:o,descriptor:t,totalCount:I,cachedPages:n.size,cachedRows:n.rowCount,lastFetchDurationMs:performance.now()-f,lastWindowRows:O.length,lastWindowStartIndex:g.startIndex,lastCacheHit:false}),B};return {key:o,descriptor:t,totalCount:s,getWindow:c,getByIds:h=>Jh(e.extensionType,h),streamRows:async function*(f={}){var C,k;let m=f.cursor,g=0;const _=!!f.cursor,b=Math.max(1,Math.min(1e3,Number(f.batchSize)||ni));for(;!((C=f.signal)!=null&&C.aborted);){const T=_&&m?await c({limit:b,after:m}):await c({startIndex:g,limit:b});for(const M of T.rows){if((k=f.signal)!=null&&k.aborted)return;yield M;}if(!T.hasAfter||!T.rowIds.length)return;if(g+=T.rowIds.length,T.cursorAfter)m=T.cursorAfter;else if(_)return}}}}function tp(e){const t=Oy([...e.folderIds??[],...e.folderId?[e.folderId]:[]]),n=MS({extensionName:e.extensionName,entityType:e.entityType,folderIds:t,direction:"desc"}),r=new Ld(e.cachePages??Zl),o=new Map;Ya(o,0);const a=Xl(n),i=typeof e.knownTotalCount=="number"&&Number.isFinite(e.knownTotalCount)?Math.max(0,Math.floor(e.knownTotalCount)):null;let s=null;const l=async()=>i!==null?i:(await Promise.all(t.map(C=>Ge.extGetSearchDocumentCount(e.extensionName,{entityType:e.entityType,folderId:C})))).reduce((C,k)=>C+(Number(k)||0),0),c=async(b,C)=>{if(t.length===1)return Ge.extGetSearchDocumentFolderCursorPage(e.extensionName,{entityType:e.entityType,folderId:t[0],after:b.after,before:b.before,limit:C,order:"newest"});const k=await Promise.all(t.map(M=>Ge.extGetSearchDocumentFolderCursorPage(e.extensionName,{entityType:e.entityType,folderId:M,after:b.after,before:b.before,limit:C+1,order:"newest"}))),T=Wc(k.flatMap(M=>M.documents).sort(Qh)).slice(0,C);return {documents:T,cursorBefore:Ao(T[0]),cursorAfter:Ao(T[T.length-1]),hasBefore:!!(b.after||b.before),hasAfter:k.some(M=>M.hasAfter)||Wc(k.flatMap(M=>M.documents)).length>C}},h=async(b,C)=>{const k=Py(o,b);if(!k)return null;const T=b+C;let M=k.index,P=k.cursorAfter,F=false;const I=[];for(;M<T;){const O=await c({after:P},Math.min(1e3,Math.max(1,T-M)));if(!O.documents.length){F=false;break}const B=M,D=M+O.documents.length,v=Math.max(0,b-B),L=Math.max(v,Math.min(O.documents.length,T-B));if(I.push(...O.documents.slice(v,L)),M=D,P=O.cursorAfter,F=O.hasAfter,Ya(o,M,P),!O.hasAfter||D<=B)break}return {documents:I,cursorBefore:Ao(I[0]),cursorAfter:Ao(I[I.length-1]),hasBefore:b>0,hasAfter:F}},f=async(b,C)=>{if(t.length===1)return Ge.extGetSearchDocumentFolderPage(e.extensionName,{entityType:e.entityType,folderId:t[0],offset:b,limit:C,order:"newest"});const k=b+C+1,T=await Promise.all(t.map(async F=>{const I=[];let O=0;for(;I.length<k;){const B=await Ge.extGetSearchDocumentFolderPage(e.extensionName,{entityType:e.entityType,folderId:F,offset:O,limit:Math.min(OS,k-I.length),order:"newest"});if(I.push(...B.documents),!B.hasAfter||!B.documents.length)break;O+=B.documents.length;}return I})),M=Wc(T.flat().sort(Qh)),P=M.slice(b,b+C);return {documents:P,cursorBefore:Ao(P[0]),cursorAfter:Ao(P[P.length-1]),hasBefore:b>0,hasAfter:M.length>b+C}},m=async b=>{const C=qe(),k=Math.max(0,Math.floor(Number(b)||0));if(!k)return  false;const T=Ge.readFolderSourceIndexRevision(e.extensionName),M=[];let P=0,F,I=[];for(;;){const D=await c({after:F},1e3);for(I.push(...D.documents);I.length>=Ls;){const $=I.slice(0,Ls);I=I.slice(Ls),M.push({pageStart:P,rowIds:$.map(Me=>Me.raw_ref_key||Me.entity_id).filter(Boolean),cursorAfter:Ao($[$.length-1])}),P+=Ls;}const v=F?`${F.observedAtMs}|${F.documentId}`:"",L=D.cursorAfter?`${D.cursorAfter.observedAtMs}|${D.cursorAfter.documentId}`:"";if(!D.hasAfter||!D.cursorAfter||!D.documents.length||L===v)break;F=D.cursorAfter;}I.length&&M.push({pageStart:P,rowIds:I.map(D=>D.raw_ref_key||D.entity_id).filter(Boolean),cursorAfter:Ao(I[I.length-1])});const O=await l(),B=Ge.readFolderSourceIndexRevision(e.extensionName);return O!==k||B!==T?(Be({kind:"db",name:"folder-source-index-build-stale",durationMs:qe()-C,value:M.length,tags:{extName:e.extensionName,entityType:e.entityType,folderCount:t.length,expectedCount:k,currentCount:O,sourceRevision:T,currentRevision:B}}),false):(await Ge.extPutFolderSourceIndexPages({sourceKey:a,extensionName:e.extensionName,entityType:e.entityType,folderIds:t,sourceCount:k,sourceRevision:T,pages:M}),Be({kind:"db",name:"folder-source-index-build",durationMs:qe()-C,value:M.length,tags:{extName:e.extensionName,entityType:e.entityType,folderCount:t.length,sourceCount:k,sourceRevision:T}}),true)},g=b=>{const C=Math.max(0,Math.floor(Number(b)||0));C<LS||s||(s=new Promise((k,T)=>{globalThis.setTimeout(()=>{m(C).then(k,T);},NS);}).finally(()=>{s=null;}),s.catch(k=>{Be({kind:"db",name:"folder-source-index-build-error",value:0,tags:{extName:e.extensionName,entityType:e.entityType,folderCount:t.length,message:k instanceof Error?k.message:String(k)}});}));},_=async b=>{const C=performance.now(),k=Math.max(1,Math.min(1e3,Number(b.limit)||ni)),T={...b,limit:k,direction:b.direction??"forward"},M=Nd(T),P=r.get(M);if(P)return ma({sourceKey:a,descriptor:n,totalCount:P.totalCount,cachedPages:r.size,cachedRows:r.rowCount,lastFetchDurationMs:performance.now()-C,lastWindowRows:P.rows.length,lastWindowStartIndex:P.startIndex,lastCacheHit:true}),P;const F=Math.max(0,Math.floor(Number(T.startIndex)||0)),I=l();let O=null,B=[],D,v,L=false,$=false;const Me=!!(T.after||T.before);if(Me){const J=await c(T,k);B=J.documents.map(le=>le.raw_ref_key||le.entity_id).filter(Boolean),D=J.cursorBefore,v=J.cursorAfter,L=J.hasBefore,$=J.hasAfter;}else {O=await I;const J=await Ge.extGetFolderSourceIndexedPage({sourceKey:a,extensionName:e.extensionName,entityType:e.entityType,folderIds:t,sourceCount:O,offset:F,limit:k});if(J)B=J.rowIds,v=J.cursorAfter,L=F>0,$=F+B.length<O;else {g(O);const le=await h(F,k)??await f(F,k);B=le.documents.map(he=>he.raw_ref_key||he.entity_id).filter(Boolean),D=le.cursorBefore,v=le.cursorAfter,L=le.hasBefore,$=le.hasAfter;}}O??(O=await I),!Me&&!$&&($=F+B.length<O);const Z=await ep(e.entityType,B),re={source:n,totalCount:O,startIndex:T.startIndex,rows:Z,rowIds:B,hasBefore:L,hasAfter:$,cursorBefore:D,cursorAfter:v};return Ya(o,F+B.length,v),r.set(M,re),ma({sourceKey:a,descriptor:n,totalCount:O,cachedPages:r.size,cachedRows:r.rowCount,lastFetchDurationMs:performance.now()-C,lastWindowRows:Z.length,lastWindowStartIndex:T.startIndex,lastCacheHit:false}),re};return {key:a,descriptor:n,totalCount:l,getWindow:_,getByIds:b=>ep(e.entityType,b),streamRows:async function*(C={}){var F,I;let k=C.cursor,T=0;const M=!!C.cursor,P=Math.max(1,Math.min(1e3,Number(C.batchSize)||ni));for(;!((F=C.signal)!=null&&F.aborted);){const O=M&&k?await _({limit:P,after:k}):await _({startIndex:T,limit:P});for(const B of O.rows){if((I=C.signal)!=null&&I.aborted)return;yield B;}if(!O.hasAfter||!O.rows.length)return;if(T+=O.rows.length,O.cursorAfter)k=O.cursorAfter;else if(M)return}}}}function HS(e){const t=Oy(e.folderIds??[]),n=RS({extensionName:e.extensionName,folderIds:t,direction:"desc"}),r=new Ld(e.cachePages??Zl),o=Xl(n);let a=null,i=null;const s=async()=>i!==null?i:(a||(a=Ge.extGetSearchDocumentMediaCount(e.extensionName,{entityType:"tweet",folderIds:t}).then(c=>(i=Number(c)||0,i)).catch(c=>{throw a=null,c})),await a),l=async c=>{const h=performance.now(),f=Math.max(1,Math.min(1e3,Number(c.limit)||ni)),m={...c,limit:f,direction:c.direction??"forward"},g=Nd(m),_=r.get(g);if(_)return ma({sourceKey:o,descriptor:n,totalCount:_.totalCount,cachedPages:r.size,cachedRows:r.rowCount,lastFetchDurationMs:performance.now()-h,lastWindowRows:_.rows.length,lastWindowStartIndex:_.startIndex,lastCacheHit:true}),_;const b=Math.max(0,Math.floor(Number(m.startIndex)||0)),C=await Ge.extGetSearchDocumentMediaCursorPage(e.extensionName,{entityType:"tweet",folderIds:t,after:m.after,before:m.before,offset:m.after||m.before?void 0:b,limit:f,order:"newest"}),k=i??Math.max(b+C.documents.length+(C.hasAfter?1:0),0),T=C.documents.map(F=>F.entity_id).filter(Boolean),M=await Ge.extGetTweetsByIds(T)??[],P={source:n,totalCount:k,startIndex:m.startIndex,rows:M,rowIds:T,hasBefore:C.hasBefore,hasAfter:C.hasAfter,cursorBefore:C.cursorBefore,cursorAfter:C.cursorAfter};return r.set(g,P),ma({sourceKey:o,descriptor:n,totalCount:k,cachedPages:r.size,cachedRows:r.rowCount,lastFetchDurationMs:performance.now()-h,lastWindowRows:M.length,lastWindowStartIndex:m.startIndex,lastCacheHit:false}),i===null&&globalThis.setTimeout(()=>{s().catch(()=>{});},3e3),P};return {key:o,descriptor:n,totalCount:s,getWindow:l,getByIds:async c=>await Ge.extGetTweetsByIds(c)??[],streamRows:async function*(h={}){var b,C;let f=h.cursor,m=0;const g=!!h.cursor,_=Math.max(1,Math.min(1e3,Number(h.batchSize)||ni));for(;!((b=h.signal)!=null&&b.aborted);){const k=g&&f?await l({limit:_,after:f}):await l({startIndex:m,limit:_});for(const T of k.rows){if((C=h.signal)!=null&&C.aborted)return;yield T;}if(!k.hasAfter||!k.rows.length)return;if(m+=k.rows.length,k.cursorAfter)f=k.cursorAfter;else if(g)return}}}}let Ns=null;function np(){return Ns||(Ns=new CS,Ns)}const Ge=new Proxy({},{get(e,t,n){const r=np(),o=Reflect.get(r,t,n);return typeof o=="function"?o.bind(r):o},set(e,t,n,r){const o=np();return Reflect.set(o,t,n,r)}}),rp="__twe_active_db_name_v1",Gc="BookmarksModule",jS=["twitter-web-exporter","scrollmark"],qS=["captures","tweets","users","social_edges","search_documents","imported_bundles","imported_entity_snapshots"];function Fy(e){return jS.some(t=>e.includes(t))}function VS(){const e=t=>{if(!t||typeof t!="object")return null;const n=t[rp];return typeof n=="string"&&n.trim()?n.trim():null};try{const t=e(globalThis);if(t)return t}catch{}try{if(typeof window<"u"){const t=e(window);if(t)return t}}catch{}try{if(typeof localStorage<"u"){const t=localStorage.getItem(rp);if(t!=null&&t.trim())return t.trim()}}catch{}return null}async function zS(){if(typeof indexedDB>"u"||typeof indexedDB.databases!="function")return [];try{const e=await indexedDB.databases();return Array.from(new Set((e||[]).map(t=>t==null?void 0:t.name).filter(t=>typeof t=="string"&&Fy(t)))).sort()}catch{return []}}function Yc(e){return new Promise(t=>{e.onsuccess=()=>t(Number(e.result)||0),e.onerror=()=>t(0);})}async function KS(e,t){return await new Promise(n=>{const r=indexedDB.open(e);r.onerror=()=>{var o;n({name:e,active:e===t,tables:{},error:((o=r.error)==null?void 0:o.message)||"open failed"});},r.onsuccess=()=>{const o=r.result;(async()=>{try{const a=qS.filter(m=>o.objectStoreNames.contains(m));if(!a.length){o.close(),n({name:e,active:e===t,tables:{}});return}const i={},s=o.transaction(a,"readonly");s.onerror=()=>{var m;o.close(),n({name:e,active:e===t,tables:i,error:((m=s.error)==null?void 0:m.message)||"transaction failed"});};const l={};let c;const h=a.map(async m=>{i[m]=await Yc(s.objectStore(m).count());}),f=[];if(a.includes("captures")){const m=s.objectStore("captures");m.indexNames.contains("extension")&&f.push(Yc(m.index("extension").count(Gc)).then(g=>{l[Gc]=g;})),m.indexNames.contains("[extension+type]")&&f.push(Yc(m.index("[extension+type]").count([Gc,"tweet"])).then(g=>{c=g;}));}await Promise.all([...h,...f]),o.close(),n({name:e,active:e===t,tables:i,captures_by_extension:Object.keys(l).length?l:void 0,bookmark_tweet_captures:c});}catch(a){o.close(),n({name:e,active:e===t,tables:{},error:a instanceof Error?a.message:String(a)});}})();};})}async function Ly(){const e=VS(),t=await zS();return e&&Fy(e)&&!t.includes(e)&&(t.push(e),t.sort()),typeof indexedDB>"u"?{active_db_name:e,databases:[]}:{active_db_name:e,databases:await Promise.all(t.map(n=>KS(n,e)))}}function Ny(){try{const e=globalThis.GM_info;if(!e||typeof e!="object")return {};const t=e,n=t.script&&typeof t.script=="object"?t.script:{};return {scriptHandler:t.scriptHandler,version:t.version,platform:t.platform,script:n}}catch{return {}}}function By(){const e=typeof navigator<"u"?navigator:null;return {userAgent:(e==null?void 0:e.userAgent)??"",vendor:(e==null?void 0:e.vendor)??"",platform:(e==null?void 0:e.platform)??"",language:(e==null?void 0:e.language)??"",languages:e!=null&&e.languages?[...e.languages]:[],cookieEnabled:(e==null?void 0:e.cookieEnabled)??null,webdriver:(e==null?void 0:e.webdriver)??null}}async function WS(){const e=await Ge.count().catch(()=>null),t=(await Ge.bundleList().catch(()=>[])??[]).map(n=>({id:n.id,title:n.title,status:n.status,recordCount:n.recordCount,schemaVersion:n.schemaVersion,importedAt:n.importedAt,updatedAt:n.updatedAt}));return {generated_at_ms:Date.now(),browser:By(),userscript_manager:Ny(),runtime_modes:Hy(),hook_stats:jy(),raw_capture_stats:Ml(),diagnostic_capture_enabled:kr(),database_counts:e,imported_bundle_count:t.length,imported_bundles:t,checklist:{canonical_bundle_export:"manual-qc-required",canonical_bundle_import:"manual-qc-required",legacy_json_import:"manual-qc-required",malicious_import_safety:"manual-qc-required",chrome_parity:"manual-qc-required",firefox_parity:"manual-qc-required"}}}async function Uy(){const e=Date.now(),t=new Date(e).toISOString(),n=globalThis,r=await(async()=>{try{if(!(indexedDB!=null&&indexedDB.databases))return [];const m=await indexedDB.databases();return (Array.isArray(m)?m:[]).map(g=>g==null?void 0:g.name).filter(g=>typeof g=="string")}catch{return []}})(),o=await Ly(),a=(()=>{try{const m=n.__twe_raw_events_v1;return Array.isArray(m)?m.slice(-10).map(g=>{if(!g||typeof g!="object")return null;const _=g;return {event_id:typeof _.event_id=="string"?_.event_id:null,kind:typeof _.kind=="string"?_.kind:null,wall_time_ms:typeof _.wall_time_ms=="number"?_.wall_time_ms:null,route_type:typeof _.route_type=="string"?_.route_type:null}}):[]}catch{return []}})(),i=(()=>{try{const m=n.__twe_raw_events_v1;return Array.isArray(m)?m.slice():[]}catch{return []}})(),s=Zb(),l=gl.value.slice(-400),c=["twe_safe_mode_v1","twe_hook_mode_v1","twe_repair_mode_v1","twe_raw_capture_enabled_v1","twe_raw_capture_encryption_ready_v1","twe_raw_capture_dm_session_armed_until_ms_v1","twe_raw_capture_stream_enabled_v1","twe_raw_capture_daemon_url_v1"],h={};for(const m of c)try{h[m]=localStorage.getItem(m);}catch{h[m]=null;}const f={dedicatedDbForAccounts:ut.get("dedicatedDbForAccounts",false),directMessagesCaptureEnabled:ut.get("directMessagesCaptureEnabled",false),rawCaptureEncryptedStorageReady:ut.get("rawCaptureEncryptedStorageReady",false),rawCapturePolicyPublicEnabled:ut.get("rawCapturePolicyPublicEnabled",true),rawCapturePolicySensitiveEnabled:ut.get("rawCapturePolicySensitiveEnabled",true),rawCapturePolicyDmEnabled:ut.get("rawCapturePolicyDmEnabled",true)};return {generated_at_ms:e,generated_at_iso:t,location:typeof location<"u"?location.href:"",title:typeof document<"u"?document.title:"",runtime_modes:Hy(),hook_stats:jy(),browser:By(),userscript_manager:Ny(),release_readiness:await WS(),performance:pS(),result_sources:ES(),raw_capture_stats:Ml(),raw_events_recent:a,raw_events_count:i.length,diagnostic_capture_enabled:kr(),diagnostic_buffer_counts:{parser:s.parser.length,db:s.db.length,interaction:s.interaction.length,logs:l.length},indexeddb_names:r,indexeddb_inventory:o,local_storage:h,app_options:f,raw_events_full:i,diagnostic_buffers:s,recent_logs:l}}function $y(e,t){const n=new Blob([JSON.stringify(e,null,2)],{type:"application/json"}),r=URL.createObjectURL(n),o=document.createElement("a");o.href=r,o.download=t,o.click(),URL.revokeObjectURL(r);}async function Bd(){const e=await Uy(),t=Date.now(),{raw_events_full:n=[],diagnostic_buffers:r={parser:[],db:[],interaction:[]},recent_logs:o=[],...a}=e,i=[{filename:"summary.json",blob:new Blob([JSON.stringify(a,null,2)],{type:"application/json"})},{filename:"raw-events.json",blob:new Blob([JSON.stringify(n,null,2)],{type:"application/json"})},{filename:"parser-events.json",blob:new Blob([JSON.stringify(r.parser??[],null,2)],{type:"application/json"})},{filename:"db-events.json",blob:new Blob([JSON.stringify(r.db??[],null,2)],{type:"application/json"})},{filename:"interaction-events.json",blob:new Blob([JSON.stringify(r.interaction??[],null,2)],{type:"application/json"})},{filename:"recent-logs.json",blob:new Blob([JSON.stringify(o,null,2)],{type:"application/json"})},{filename:"release-readiness.json",blob:new Blob([JSON.stringify(a.release_readiness??{},null,2)],{type:"application/json"})}];return await Pd(`twe-diagnostics-${t}.zip`,i)}function GS(){try{return localStorage.getItem("twe_enable_synthetic_db_tools_v1")==="1"||location.search.includes("scrollmarkSyntheticDb=1")}catch{return  false}}function YS(){if(!GS())return;const e=globalThis;e.__scrollmark_collect_diagnostics_bundle_v1=Uy,e.__scrollmark_export_diagnostics_bundle_zip_v1=Bd;}YS();function Ml(){try{const e=globalThis.__twe_raw_capture_stats_v1;return !e||typeof e!="object"?{}:e}catch{return {}}}function Hy(){try{const e=globalThis.__twe_runtime_modes_v1;return !e||typeof e!="object"?{}:e}catch{return {}}}function jy(){try{const e=globalThis.__twe_hook_stats_v1;return !e||typeof e!="object"?{}:e}catch{return {}}}function XS(e){return String(e||"").replace(/[^a-zA-Z0-9._-]/g,"_").replace(/_+/g,"_")}function ZS(e){const t=e.data&&typeof e.data=="object"?e.data:{},n=t.metadata&&typeof t.metadata=="object"?t.metadata:{},r=[t.full_text,t.text,t.description,n.legacy&&typeof n.legacy=="object"?n.legacy.full_text:void 0,t.name,t.screen_name];for(const o of r)if(typeof o=="string"&&o.trim())return o.trim();return String(e.search_text||"").slice(0,240)}function Xc(e){if(typeof e!="string")return null;try{const t=new URL(e);return t.protocol==="http:"||t.protocol==="https:"?t.href:null}catch{return null}}function op(e){const t=new Set;for(const o of e.media_refs||[]){const a=Xc(o.previewUrl),i=Xc(o.url);a&&t.add(a),i&&t.add(i);}const n=e.data&&typeof e.data=="object"?e.data:{},r=Array.isArray(n.media)?n.media:[];for(const o of r){if(!o||typeof o!="object")continue;const a=o;for(const i of ["thumbnail","original","url","media_url_https"]){const s=a[i],l=Xc(s);l&&t.add(l);}}return [...t].slice(0,8)}async function ap(){await new Promise(e=>{setTimeout(e,0);});}function QS(){const{t:e,i18n:t}=Wn(),n=on(ut.get("theme")),r=on(0),[o,a]=sr(false),[i,s]=sr(false),[l,c]=sr(false),[h,f]=sr(false),m=on(true),g=on(true),_=on(false),b=on({current:0,total:0}),C=on(""),k=on(null),T=on(""),M=on(""),P=on([]),F=on([]),I=on(""),O=on(""),B=on("all"),D=on(""),v=on(false),L=on(""),$=on(false),Me=on(kr()),Z={subtitle:"mb-2 text-base-content ml-4 opacity-50 font-semibold text-xs",block:"text-sm mb-2 w-full flex px-4 py-2 text-base-content bg-base-200 rounded-box justify-between",item:"label cursor-pointer flex justify-between h-8 items-center p-0",wrapButton:"btn btn-xs h-auto min-h-6 max-w-full whitespace-normal break-words text-center leading-tight"},re=async()=>{if(_.value)return;_.value=true,k.value=null,C.value="Preparing export...",b.value={current:0,total:0};const z=Date.now(),ue=[],Pe=[];let ce=0;try{if(m.value){C.value="Exporting DB snapshot...";const ne=await Ge.export();ne&&ue.push({filename:"database/twitter-web-exporter-db.json",blob:ne});}if(g.value){C.value="Collecting module exports...";const ne=rr.getExtensions(),j=ne.length;for(const[se,_e]of ne.entries()){C.value=`Collecting module exports (${se+1}/${j}): ${_e.name}`;const we=await Ge.extGetCaptures(_e.name)??[];if(!we.length){ce+=1,await ap();continue}let Ye=[];_e.type===xt.TWEET?Ye=await Ge.extGetCapturedTweets(_e.name,we)??[]:_e.type===xt.USER&&(Ye=await Ge.extGetCapturedUsers(_e.name,we)??[]);const Se=`modules/${XS(_e.name)}.json`,Tt={extension:_e.name,type:_e.type,exported_at_ms:z,capture_count:we.length,record_count:Ye.length,captures:we,records:Ye};ue.push({filename:Se,blob:new Blob([JSON.stringify(Tt)],{type:"application/json"})}),Pe.push({extension:_e.name,type:_e.type,capture_count:we.length,record_count:Ye.length,filename:Se}),await ap();}}const Ee={generated_at_ms:z,generated_at_iso:new Date(z).toISOString(),include_db_snapshot:m.value,include_module_exports:g.value,files_total:ue.length+1,modules_exported:Pe.length,modules_skipped_empty:ce,modules:Pe};if(ue.unshift({filename:"manifest.json",blob:new Blob([JSON.stringify(Ee,void 0,2)],{type:"application/json"})}),!ue.length)throw new Error("No files prepared for bundle export.");const Qe=`twitter-web-exporter-bundle-${z}.zip`;C.value="Creating ZIP...",b.value={current:0,total:ue.length};const X=await Pd(Qe,ue,(ne,j)=>{b.value={current:ne,total:j};});M.value&&(URL.revokeObjectURL(M.value),M.value=""),T.value=Qe,M.value=URL.createObjectURL(X),C.value=`Bundle export completed: ${Qe}`,k.value={modules:Pe.length,files:ue.length,skipped:ce};}catch(Ee){C.value=`Bundle export failed: ${(Ee==null?void 0:Ee.message)??"Unknown error"}`;}finally{_.value=false;}},J=async()=>{P.value=await Ge.bundleList()??[];},le=async z=>{if(!(!z||v.value)){v.value=true,D.value=`Importing ${z.name}...`;try{const Pe=z.name.toLowerCase().endsWith(".zip")||z.type==="application/zip"||z.type==="application/x-zip-compressed"?await oy(Ge,z):await sy(Ge,z);D.value=`Imported ${Pe.recordsImported}/${Pe.recordsSeen} records from ${z.name}`,await J();}catch(ue){D.value=`Import failed: ${ue.message}`;}finally{v.value=false;}}},he=async()=>{if(!I.value){F.value=[];return}const z=await Ge.bundleSearchSnapshots(I.value,O.value,1e3)??[];F.value=B.value==="all"?z:z.filter(ue=>ue.kind===B.value);},pe=async()=>{const z=P.value.find(ue=>ue.id===I.value);!z||!F.value.length||await l0(F.value.map((ue,Pe)=>({id:ue.source_id||ue.id||String(Pe),original:ue.data,record:ue.data&&typeof ue.data=="object"?ue.data:{value:ue.data}})),{title:`${z.title}-subset`,description:`Re-exported subset from imported bundle ${z.id}`,scope:"bundle",queryText:O.value});},ge=async()=>{if(!$.value){$.value=true,L.value="Preparing QC diagnostics bundle...";try{await Bd(),L.value="QC diagnostics bundle exported.";}catch(z){L.value=`QC diagnostics export failed: ${z.message}`;}finally{$.value=false;}}};return Je(()=>{const z=ut.signal.subscribe(()=>{r.value++,n.value=ut.get("theme");});return ()=>{typeof z=="function"&&z(),M.value&&URL.revokeObjectURL(M.value);}},[]),Je(()=>{l&&J();},[l]),Je(()=>{typeof _l=="function"&&_l(`${e("Version")} ${vr.version}`,()=>{window.open(vr.homepage,"_blank");});},[]),d(Jn,{children:[d("div",{onClick:a,class:"w-9 h-9 mr-2 cursor-pointer flex justify-center items-center transition-colors duration-200 rounded-full hover:bg-base-200",children:d(Kw,{})}),d(lr,{title:e("Settings"),show:o,onClose:a,class:"max-w-lg",children:[d("p",{class:Z.subtitle,children:e("General")}),d("div",{class:sn(Z.block,"flex-col"),children:[d("label",{class:Z.item,children:[d("span",{class:"label-text whitespace-nowrap",children:e("Theme")}),d("select",{class:"select select-xs",onChange:z=>{var ue;n.value=((ue=z.target)==null?void 0:ue.value)??Qs.theme,ut.set("theme",n.value);},children:_v.map(z=>d("option",{value:z,selected:n.value===z,children:e(`theme.${z}`)},z))})]}),d("label",{class:Z.item,children:[d("span",{class:"label-text whitespace-nowrap",children:e("Language")}),d("select",{class:"select select-xs",onChange:z=>{var Pe;const ue=((Pe=z.target)==null?void 0:Pe.value)??Sg();t.changeLanguage(ue),ut.set("language",ue);},children:Object.entries(xg).map(([z,ue])=>d("option",{value:z,selected:ut.get("language")===z,children:[ue.nameEn," - ",ue.name]},z))})]}),d("label",{class:Z.item,children:[d("span",{class:"label-text whitespace-nowrap",children:e("Debug")}),d("input",{type:"checkbox",class:"toggle toggle-primary",checked:ut.get("debug"),onChange:z=>{var ue;ut.set("debug",(ue=z.target)==null?void 0:ue.checked);}})]}),d("label",{class:Z.item,children:[d("div",{class:"flex items-center",children:[d("span",{class:"label-text whitespace-nowrap",children:e("Safe mode")}),d("a",{class:"tooltip tooltip-bottom ml-0.5 before:max-w-40","data-tip":e("Disables hook-based capture when enabled. Turn this off for normal browsing and diagnostic capture."),children:d(Ha,{size:20})})]}),d("input",{type:"checkbox",class:"toggle toggle-warning",checked:ut.get("safeMode"),onChange:z=>{var ue;ut.set("safeMode",(ue=z.target)==null?void 0:ue.checked);}},`safe-mode-${r.value}`)]}),d("label",{class:Z.item,children:[d("div",{class:"flex items-center",children:[d("span",{class:"label-text whitespace-nowrap",children:e("Hook mode")}),d("a",{class:"tooltip tooltip-bottom ml-0.5 before:max-w-40","data-tip":e("Controls whether the userscript hooks XHR, fetch, both, or neither."),children:d(Ha,{size:20})})]}),d("select",{class:"select select-xs",value:ut.get("hookMode"),onChange:z=>{var ue;ut.set("hookMode",(ue=z.target)==null?void 0:ue.value);},children:[d("option",{value:"both",children:e("both")}),d("option",{value:"xhr",children:e("xhr")}),d("option",{value:"fetch",children:e("fetch")}),d("option",{value:"off",children:e("off")})]})]}),d("label",{class:Z.item,children:[d("div",{class:"flex items-center",children:[d("span",{class:"label-text whitespace-nowrap",children:e("Repair mode")}),d("a",{class:"tooltip tooltip-bottom ml-0.5 before:max-w-40","data-tip":e("Controls whether hook repair watchdog behavior is active."),children:d(Ha,{size:20})})]}),d("select",{class:"select select-xs",value:ut.get("repairMode"),onChange:z=>{var ue;ut.set("repairMode",(ue=z.target)==null?void 0:ue.value);},children:[d("option",{value:"watchdog",children:e("watchdog")}),d("option",{value:"off",children:e("off")})]})]}),d("label",{class:Z.item,children:[d("div",{class:"flex items-center",children:[d("span",{class:"label-text whitespace-nowrap",children:e("Date Time Format")}),d("a",{href:"https://day.js.org/docs/en/display/format",target:"_blank",rel:"noopener noreferrer",class:"tooltip tooltip-bottom ml-0.5 before:max-w-40","data-tip":e("Click for more information. This will take effect on both previewer and exported files."),children:d(Ha,{size:20})})]}),d("input",{type:"text",class:"input input-bordered input-xs w-48",value:ut.get("dateTimeFormat"),onChange:z=>{var ue;ut.set("dateTimeFormat",(ue=z.target)==null?void 0:ue.value);}})]}),d("label",{class:Z.item,children:[d("div",{class:"flex items-center",children:[d("span",{class:"label-text whitespace-nowrap",children:e("Use dedicated DB for accounts")}),d("a",{class:"tooltip tooltip-bottom ml-0.5 before:max-w-40","data-tip":e("This will create separate database for each Twitter account, which can help reduce the chance of data mixing when you use multiple accounts."),children:d(Ha,{size:20})})]}),d("input",{type:"checkbox",class:"toggle toggle-primary",checked:ut.get("dedicatedDbForAccounts"),onChange:z=>{var ue;ut.set("dedicatedDbForAccounts",(ue=z.target)==null?void 0:ue.checked);}})]}),d("div",{class:"flex w-full flex-col gap-2 py-1",children:[d("div",{class:"flex items-center justify-between gap-2",children:d("span",{class:"label-text whitespace-nowrap",children:e("Local Database")})}),d("div",{class:"grid min-w-0 grid-cols-2 gap-2 sm:grid-cols-3",children:[d("button",{class:sn(Z.wrapButton,"btn-neutral"),onClick:async()=>{let z="Storage usage: N/A";if(typeof navigator.storage.estimate=="function"){const{quota:ce=1,usage:Ee=0}=await navigator.storage.estimate(),Qe=(Ee/1024/1024).toFixed(2),X=(ce/1024/1024).toFixed(2);z=`Storage usage: ${Qe}MB / ${X}MB`;}const ue=await Ge.count(),Pe=await Ly();alert(z+`

IndexedDB tables count:
`+JSON.stringify(ue,void 0,"  ")+`

Scrollmark database inventory:
`+JSON.stringify(Pe,void 0,"  "));},children:[d(kf,{size:20}),e("Analyze DB")]}),d("button",{class:sn(Z.wrapButton,"btn-primary"),onClick:async()=>{const z=await Ge.export();z&&fa(`twitter-web-exporter-${Date.now()}.json`,z);},children:[d(vc,{size:20}),e("Export DB")]}),d("button",{class:sn(Z.wrapButton,"btn-info"),onClick:s,children:[d(vc,{size:20}),e("Bundle Export")]}),d("button",{class:sn(Z.wrapButton,"btn-secondary"),onClick:c,children:[d(vc,{size:20}),e("Bundle Library")]}),d("button",{class:sn(Z.wrapButton,"btn-accent"),onClick:f,children:[d(kf,{size:20}),e("QC Session")]}),d("button",{class:sn(Z.wrapButton,"btn-warning"),onClick:async()=>{confirm(e("Are you sure to clear all data in the database?"))&&await Ge.clear();},children:[d(Yw,{size:20}),e("Clear DB")]})]})]})]}),d("p",{class:Z.subtitle,children:e("Modules (Scroll to see more)")}),d("div",{class:sn(Z.block,"flex-col","max-h-44 overflow-scroll"),children:rr.getExtensions().map(z=>d("label",{class:sn(Z.item,"flex-shrink-0"),children:[d("span",{children:[e(z.name.replace("Module",""))," ",e("Module")]}),d("input",{type:"checkbox",class:"toggle toggle-secondary",checked:z.enabled,onChange:()=>{z.enabled?rr.disable(z.name):rr.enable(z.name);}})]},z.name))}),d("p",{class:Z.subtitle,children:e("About")}),d("div",{class:Z.block,children:[d("span",{class:"label-text whitespace-nowrap",children:[e("Version")," ",vr.version]}),d("a",{class:"btn btn-xs btn-ghost",target:"_blank",href:vr.homepage,children:[d(Jw,{class:"[&>path]:stroke-0"}),"GitHub"]})]})]}),d(lr,{title:"Bundle Export",show:i,onClose:s,class:"max-w-lg",children:[d("div",{class:"px-4 text-base",children:[d("p",{class:"text-base-content text-opacity-60 mb-2 leading-5 text-sm",children:"Create one ZIP with a DB snapshot and per-module JSON exports."}),d("label",{class:Z.item,children:[d("span",{class:"label-text whitespace-nowrap",children:"Include DB snapshot"}),d("input",{type:"checkbox",class:"toggle toggle-primary",checked:m.value,onChange:z=>{var ue;m.value=(ue=z.target)==null?void 0:ue.checked;}})]}),d("label",{class:Z.item,children:[d("span",{class:"label-text whitespace-nowrap",children:"Include module exports"}),d("input",{type:"checkbox",class:"toggle toggle-primary",checked:g.value,onChange:z=>{var ue;g.value=(ue=z.target)==null?void 0:ue.checked;}})]}),d("div",{class:"text-xs text-base-content text-opacity-70 mt-2",children:["Status: ",C.value||"Idle"]}),d("div",{class:"text-xs text-base-content text-opacity-70",children:["Progress: ",b.value.current,"/",b.value.total]}),k.value&&d("div",{class:"text-xs text-base-content text-opacity-70 mt-1",children:["Exported modules: ",k.value.modules," | files: ",k.value.files," | skipped empty modules: ",k.value.skipped]}),T.value&&d("div",{class:"text-xs text-base-content text-opacity-70 mt-1 break-all",children:["Last ZIP: ",d("code",{children:T.value})]}),M.value&&d("div",{class:"text-xs mt-1",children:d("a",{class:"link link-primary",href:M.value,download:T.value,children:"Download again"})})]}),d("div",{class:"flex space-x-2",children:[d("span",{class:"flex-grow"}),d("button",{class:"btn",onClick:s,children:"Cancel"}),d("button",{class:sn("btn btn-primary",_.value&&"btn-disabled"),onClick:re,children:[_.value&&d("span",{class:"loading loading-spinner"}),"Export Bundle ZIP"]})]})]}),d(lr,{title:"Bundle Library",show:l,onClose:c,class:"max-w-2xl",children:[d("div",{class:"px-4 text-sm",children:[d("p",{class:"text-base-content text-opacity-60 mb-3 leading-5",children:"Import canonical TWE bundle ZIPs into isolated local bundle tables. Imported bundles do not mutate live captures or your X account."}),d("div",{class:"rounded-box-half border border-base-300 bg-base-200/70 p-3",children:[d("label",{class:"flex items-center justify-between gap-3",children:[d("span",{class:"font-semibold",children:"Import bundle ZIP or legacy JSON/JSONL"}),d("input",{type:"file",accept:".zip,.json,.jsonl,application/zip,application/json,application/x-ndjson",class:"file-input file-input-bordered file-input-sm max-w-xs",disabled:v.value,onChange:z=>{var Pe;const ue=z.target;le((Pe=ue.files)==null?void 0:Pe[0]),ue.value="";}})]}),d("div",{class:"mt-2 font-mono text-xs opacity-70",children:[v.value?"busy: ":"",D.value||"Idle"]})]}),d("div",{class:"mt-3 flex items-center justify-between",children:[d("h3",{class:"font-semibold",children:"Imported bundles"}),d("button",{class:"btn btn-xs btn-outline",onClick:()=>void J(),children:"Refresh"})]}),d("div",{class:"mt-2 max-h-80 overflow-y-auto rounded-box-half border border-base-300",children:P.value.length?d("table",{class:"table table-sm",children:[d("thead",{children:d("tr",{children:[d("th",{children:"Title"}),d("th",{children:"Status"}),d("th",{children:"Records"}),d("th",{children:"Imported"}),d("th",{})]})}),d("tbody",{children:P.value.map(z=>d("tr",{children:[d("td",{children:[d("div",{class:"font-semibold",children:z.title}),d("div",{class:"font-mono text-[10px] opacity-60",children:z.id})]}),d("td",{children:d("span",{class:"badge badge-sm badge-outline",children:z.status})}),d("td",{class:"font-mono text-xs",children:z.recordCount}),d("td",{class:"font-mono text-xs",children:new Date(z.importedAt).toLocaleString()}),d("td",{children:[d("button",{class:"btn btn-xs btn-primary btn-outline mr-1",onClick:async()=>{I.value=z.id,O.value="",B.value="all",await he();},children:"View"}),d("button",{class:"btn btn-xs btn-error btn-outline",onClick:async()=>{confirm(`Delete imported bundle "${z.title}"?`)&&(await Ge.bundleDelete(z.id),I.value===z.id&&(I.value="",F.value=[]),await J());},children:"Delete"})]})]},z.id))})]}):d("div",{class:"p-6 text-center text-base-content/50",children:"No imported bundles yet."})}),I.value?d("div",{class:"mt-3 rounded-box-half border border-base-300 bg-base-200/50 p-3",children:[d("div",{class:"mb-2 flex items-center justify-between gap-2",children:[d("div",{children:[d("h3",{class:"font-semibold",children:"Bundle Viewer"}),d("div",{class:"font-mono text-[10px] opacity-60",children:I.value})]}),d("button",{class:"btn btn-xs btn-outline",onClick:()=>{I.value="",F.value=[];},children:"Close Viewer"})]}),d("label",{class:"input input-bordered input-sm mb-2 flex items-center gap-2",children:[d("span",{class:"text-xs opacity-60",children:"Search"}),d("input",{class:"grow bg-transparent",value:O.value,onInput:z=>{O.value=z.target.value;},onKeyDown:z=>{z.key==="Enter"&&he();}}),d("button",{class:"btn btn-xs",onClick:()=>void he(),children:"Run"})]}),d("div",{class:"mb-2 flex items-center justify-between gap-2",children:[d("div",{class:"flex items-center gap-2",children:[d("select",{class:"select select-bordered select-xs",value:B.value,onChange:z=>{B.value=z.target.value,he();},children:[d("option",{value:"all",children:"all kinds"}),d("option",{value:"tweet",children:"tweets"}),d("option",{value:"user",children:"users"}),d("option",{value:"unknown",children:"unknown"})]}),d("span",{class:"font-mono text-xs opacity-70",children:["Showing ",F.value.length," snapshots"]})]}),d("button",{class:"btn btn-xs btn-secondary",disabled:!F.value.length,onClick:()=>void pe(),children:"Export Loaded Subset"})]}),d("div",{class:"max-h-72 overflow-y-auto rounded-box-half border border-base-300 bg-base-100",children:F.value.length?F.value.map(z=>d("details",{class:"border-b border-base-300 p-2 text-xs",children:[d("summary",{class:"cursor-pointer",children:[d("span",{class:"badge badge-xs badge-outline mr-2",children:z.kind}),d("span",{class:"font-mono mr-2",children:z.source_id||z.id}),d("span",{class:"opacity-60",children:z.observed_at?new Date(z.observed_at).toLocaleString():""})]}),d("div",{class:"mt-2 rounded bg-base-100 p-2",children:[d("p",{class:"whitespace-pre-wrap text-sm leading-5",children:ZS(z)||"(no text preview)"}),op(z).length?d("div",{class:"mt-2 grid grid-cols-4 gap-2",children:op(z).map(ue=>d("a",{href:ue,target:"_blank",rel:"noopener noreferrer",children:ue.includes(".mp4")?d("video",{src:ue,class:"h-20 w-full rounded object-cover"}):d("img",{src:ue,class:"h-20 w-full rounded object-cover",loading:"lazy"})},ue))}):null]}),d("pre",{class:"mt-2 max-h-52 overflow-auto whitespace-pre-wrap rounded bg-base-200 p-2 text-[10px] leading-4",children:JSON.stringify(z.data,null,2)})]},z.id)):d("div",{class:"p-6 text-center text-base-content/50",children:"No snapshots loaded."})})]}):null]}),d("div",{class:"flex space-x-2",children:[d("span",{class:"flex-grow"}),d("button",{class:"btn",onClick:c,children:"Close"})]})]}),d(lr,{title:"Unified QC Session",show:h,onClose:f,class:"max-w-3xl",children:[d("div",{class:"px-4 text-sm",children:[d("p",{class:"mb-3 text-base-content/70",children:"Use this single session to QC Bundle Library, core release workflows, and Firefox/Chrome parity. Run Firefox first, export diagnostics, then repeat the browser parity subset in Chrome and export diagnostics again."}),d("div",{class:"grid gap-3 md:grid-cols-2",children:[d("section",{class:"rounded-box-half border border-base-300 bg-base-200/60 p-3",children:[d("h3",{class:"mb-2 font-semibold",children:"Preparation"}),d("ol",{class:"list-decimal space-y-1 pl-5 text-xs leading-5",children:[d("li",{children:"Install the current local userscript in Firefox."}),d("li",{children:"Open Settings and set Safe mode off, Hook mode both, Repair mode watchdog."}),d("li",{children:"Enable Diagnostic capture below."}),d("li",{children:"Browse X normally long enough to confirm counters increment."}),d("li",{children:"Repeat the parity subset in Chrome after Firefox is complete."})]})]}),d("section",{class:"rounded-box-half border border-base-300 bg-base-200/60 p-3",children:[d("h3",{class:"mb-2 font-semibold",children:"Bundle Library"}),d("ol",{class:"list-decimal space-y-1 pl-5 text-xs leading-5",children:[d("li",{children:["Export a filtered result set with Export Data ","->"," Export Bundle ZIP."]}),d("li",{children:["Import that ZIP through Settings ","->"," Bundle Library."]}),d("li",{children:"Search exact text from one imported row."}),d("li",{children:"Filter by tweets/users, inspect text/media/raw JSON."}),d("li",{children:"Export Loaded Subset, then import that subset ZIP."}),d("li",{children:"Import the legacy and malicious fixtures from e2e/fixtures/bundles."})]})]}),d("section",{class:"rounded-box-half border border-base-300 bg-base-200/60 p-3",children:[d("h3",{class:"mb-2 font-semibold",children:"Core Release Smoke"}),d("ol",{class:"list-decimal space-y-1 pl-5 text-xs leading-5",children:[d("li",{children:"Bookmarks folder scroll indexes rows and folder metadata."}),d("li",{children:"Bookmark-from-feed increments and later resolves folder details."}),d("li",{children:"Search exact snippets and phrases rank correctly enough for QC."}),d("li",{children:"Table fullscreen and masonry scrolling remain stable."}),d("li",{children:"Export Data and Export Media complete without browser freeze."})]})]}),d("section",{class:"rounded-box-half border border-base-300 bg-base-200/60 p-3",children:[d("h3",{class:"mb-2 font-semibold",children:"Chrome Parity"}),d("ol",{class:"list-decimal space-y-1 pl-5 text-xs leading-5",children:[d("li",{children:"Install in Chrome userscript manager."}),d("li",{children:"Confirm widget loads on x.com and settings toggles work."}),d("li",{children:"Confirm hooks/counters increment with Safe mode off."}),d("li",{children:"Run Bundle ZIP export/import and legacy import."}),d("li",{children:"Run one media export and one diagnostics export."}),d("li",{children:"Record any Chrome-only console errors or CSP differences."})]})]})]}),d("div",{class:"mt-3 rounded-box-half border border-base-300 bg-base-100 p-3",children:[d("div",{class:"grid min-w-0 grid-cols-2 items-center gap-2",children:[d("label",{class:"label min-w-0 cursor-pointer gap-2 py-0",children:[d("span",{class:"text-xs",children:e("Diagnostic capture")}),d("input",{type:"checkbox",class:"toggle toggle-sm",checked:Me.value,onChange:z=>{const ue=z.target.checked;_g(ue),Me.value=ue;}})]}),d("button",{class:sn(Z.wrapButton,"btn-outline"),onClick:()=>{wg(),L.value=e("Diagnostic buffers cleared.");},children:e("Clear Buffers")}),d("button",{class:sn(Z.wrapButton,"btn-primary col-span-2"),disabled:$.value,onClick:ge,children:$.value?e("Preparing..."):e("Export QC Diagnostics")})]}),d("div",{class:"mt-2 font-mono text-xs opacity-70",children:L.value||e("QC idle.")}),d("div",{class:"mt-2 text-xs opacity-70",children:["Full runbook: ",d("code",{children:"docs/release/unified-qc-session-runbook.md"})]})]})]}),d("div",{class:"flex space-x-2",children:[d("span",{class:"flex-grow"}),d("button",{class:"btn",onClick:f,children:"Close"})]})]})]})}function JS({currentTheme:e,show:t,title:n,byline:r,description:o,hookLine:a,healthLine:i,onToggle:s,children:l}){return d("section",{"data-theme":e,class:sn("card card-compact bg-base-100 fixed border shadow-xl w-80 leading-loose text-base-content py-3 rounded-box border-solid border-neutral-content border-opacity-50 left-8 top-8 transition-transform duration-500 flex flex-col overflow-hidden",t?"translate-x-0 transform-none":"translate-x-[-500px]"),style:{maxHeight:"calc(100vh - 4rem)"},children:[d("header",{class:"mx-4 mb-1 flex h-9 items-center",children:[d(eb,{class:"mr-2 shrink-0 text-base-content"}),d("div",{class:"flex-grow leading-none",children:[d("h2",{class:"m-0 flex items-baseline gap-2 text-xl font-semibold leading-none",children:[d("span",{children:n}),d("span",{class:"font-mono text-[10px] font-normal text-base-content opacity-70",children:["v",vr.version]})]}),r?d("p",{class:"font-mono text-[10px] opacity-70 m-0 mt-1",children:r}):null]}),d(Li,{children:d(QS,{})}),d("div",{onClick:s,class:"w-9 h-9 cursor-pointer flex justify-center items-center transition-colors duration-200 rounded-full hover:bg-base-200",children:d(sl,{})})]}),d("p",{class:"mx-4 mb-1 text-sm leading-none text-base-content text-opacity-70",children:o}),d("p",{class:"mx-4 mb-1 font-mono text-xs leading-none text-base-content text-opacity-60",children:a}),d("p",{class:"mx-4 mb-1 font-mono text-xs leading-none text-base-content text-opacity-60",children:i}),d("div",{class:"divider mt-0 mb-0"}),d("main",{class:"min-h-0 grow overflow-y-auto overscroll-contain scroll-smooth",children:d("div",{class:"pl-4 pr-2",children:l})})]})}const ip=5e3;function e1(){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?crypto.randomUUID():`rs-${Date.now()}-${Math.random().toString(36).slice(2,10)}`}function Oo(e,t){var l,c;if(!e||typeof e!="object")return `row-${t}`;const n=e,r=h=>typeof h=="string"&&h.trim()?h.trim():typeof h=="number"&&Number.isFinite(h)?String(h):"",a=((...h)=>{for(const f of h){const m=r(f);if(m)return m}return ""})(n.id,n.rest_id,n.id_str,(l=n.legacy)==null?void 0:l.id_str,(c=n.core)==null?void 0:c.screen_name,n.screen_name),i=[n.__bookmark_folder_id,n.__twe_imported_bundle_id,n.__twe_imported_snapshot_id,n.entryId,n.conversationId,n.conversation_id,n.dm_conversation_id].map(r).filter(Boolean);return (a&&i.length?`${a}::${i.join("::")}`:a)||`row-${t}`}function qy(e){const t=String(e||"").trim();if(!t)return "";const[n]=t.split("::");return n||t}function Bs(e,t){let n=e;for(const r of t.split(".")){if(!n||typeof n!="object")return;n=n[r];}return n}function t1(e){return typeof e=="string"&&e.trim()?e.trim():typeof e=="number"&&Number.isFinite(e)?String(e):""}function aa(e,t){const n=new Set,r=o=>{const a=t1(o);a&&n.add(a);};if(r(Oo(e,t)),e&&typeof e=="object"){const o=e;r(o.id),r(o.rest_id),r(o.id_str),r(Bs(o,"legacy.id_str")),r(Bs(o,"legacy.id")),r(Bs(o,"core.user_results.result.rest_id")),r(Bs(o,"core.screen_name")),r(o.__twe_imported_snapshot_id),r(o.__twe_imported_source_id);}return [...n]}function n1(e,t,n=new Set){const r=[];for(const o of e){const a=t.get(o);if(a){r.push(a);continue}if(!n.has(o))break}return r}function r1(e){return e!=null&&e.length?e.map(t=>`${t.id}:${t.desc?"desc":"asc"}`).join(","):"default"}function o1(e){const t=e.sourceDescriptor&&e.idsTruncated?[]:e.ids.slice(0,ip),n=!!e.idsTruncated||e.ids.length>ip;return {resultSetId:e1(),scope:"table",engine:"local-sync",generatedAtMs:Date.now(),queryText:e.queryText,sort:e.sort,totalMatches:e.totalMatches,ids:t,idsTotalCount:e.ids.length,idsTruncated:n,sourceDescriptor:e.sourceDescriptor,warnings:[...e.warnings]}}const a1="^[a-zA-Z0-9_.]+$",i1=["from","from_id","author_id","to","to_id","in_reply_to_id","lang","since","until","since_time","until_time","since_id","max_id","conversation_id","min_faves","min_likes","min_retweets","min_replies","min_bookmarks","url","domain","id","source","card_name","filter","include","is","has","bookmark_folder","folder","route","mention","hashtag","cashtag"],s1=["since","until","since_time","until_time","since_id","max_id","min_faves","min_likes","min_retweets","min_replies","min_bookmarks","id","from_id","author_id","to_id","in_reply_to_id","conversation_id"],l1={min_content_term_length:2,full_run_exact_min_terms:2,stop_terms:["a","an","the","and","or","but","if","then","than","to","of","in","on","for","with","by","at","from","into","onto","as","is","are","was","were","be","been","being","do","does","did","done","have","has","had","can","could","should","would","will","just","about","what","when","where","why","how","who","whom","whose","this","that","these","those","it","its","my","your","our","their","his","her","me","you","we","they","he","she","them","us","post","tweet","too"],bigram_slop:2,trigram_slop:3,fourgram_slop:4,bigram_boost:20,trigram_boost:60,fourgram_boost:140,full_run_exact_boost:320},c1={min_term_length:3,max_expansions:128},u1={min_term_length:5,max_edit_distance:1,prefix_root_length:4,max_expansions:64},wa={field_path_pattern:a1,known_filter_keys:i1,non_highlight_filters:s1,free_text:l1,prefix:c1,fuzzy:u1},Vy=new RegExp(wa.field_path_pattern),sp=new Set(wa.known_filter_keys),d1=new Set(wa.non_highlight_filters),ro=wa.free_text,Ud=wa.prefix,us=wa.fuzzy,f1=new Set((wa.free_text.stop_terms||[]).map(e=>String(e||"").trim().toLowerCase()).filter(Boolean));function zy(e){return e.kind==="term"||e.kind==="phrase"}const h1=/[\p{L}\p{N}_]+(?:['’][\p{L}\p{N}_]+)*/gu,p1=32,m1=Math.max(1,Number(ro.min_content_term_length)),g1=Math.max(2,Number(ro.full_run_exact_min_terms)),y1=Math.max(1,Number(Ud.min_term_length)),_1=Math.max(1,Number(us.min_term_length)),w1=[{category:"lexical",syntax:"plain free text",description:"Unstructured text expands into content-term matches plus boosted adjacent phrase windows; common filler words are deprioritized unless quoted.",examples:["tour guides in France","distributed systems design"]},{category:"lexical",syntax:'"exact phrase"~2',description:"Phrase search with optional slop.",examples:['"design system"','"design system"~2',"machine^2"]},{category:"lexical",syntax:"AND / OR / NOT / (...)",description:"Boolean operators with standard precedence and parentheses.",examples:["machine OR reliability","(machine OR reliability) AND fragile","machine AND NOT reliability"]},{category:"identity",syntax:"from: / from_id: / author_id:",description:"Match the author handle or author id.",examples:["from:alice","from_id:12345"]},{category:"identity",syntax:"@user",description:"Shorthand for an enforced author constraint, equivalent to from:user.",examples:["@sama","@openai"]},{category:"identity",syntax:"to: / to_id: / in_reply_to_id: / id: / conversation_id:",description:"Match reply targets, entity ids, or conversation ids.",examples:["to:alice","in_reply_to_id:1888","id:1999"]},{category:"metadata",syntax:"bookmark_folder: / folder:",description:"Match bookmark folder id or folder name.",examples:["bookmark_folder:12345",'folder:"Design References"']},{category:"metadata",syntax:"lang: / route: / source: / card_name:",description:"Match language, route surface, source text, or card name.",examples:["lang:en","route:bookmarks","source:iphone"]},{category:"metadata",syntax:"domain: / url:",description:"Match domains or URLs found in tweets.",examples:["domain:github.com","url:openai.com"]},{category:"presence",syntax:"is:",description:"Boolean state filters.",examples:["is:bookmarked","is:reply","is:verified","is:blue_verified"]},{category:"presence",syntax:"has:",description:"Presence filters for media, links, mentions, hashtags, cashtags, engagement, and polls.",examples:["has:media","has:links","has:hashtags","has:engagement"]},{category:"compatibility",syntax:"filter: / include:",description:"Compatibility aliases retained for Twitter-style queries.",examples:["filter:media","filter:replies","include:nativeretweets"]},{category:"numeric_date",syntax:"min_likes: / min_retweets: / min_replies: / min_bookmarks:",description:"Numeric threshold filters.",examples:["min_likes:50","min_bookmarks:10"]},{category:"numeric_date",syntax:"since: / until: / since_time: / until_time: / since_id: / max_id:",description:"Date, timestamp, and Snowflake-style boundary filters.",examples:["since:2026-03-01","until:2026-03-31","since_id:1900"]},{category:"compatibility",syntax:"mention: / #tag / $symbol",description:"Explicit mention filter plus shorthand hashtag and cashtag filters.",examples:["mention:alice","#ai","$tsla"]},{category:"metadata",syntax:'field:value / field:"quoted phrase"',description:"Field-scoped lexical search over raw nested paths, including dotted object paths and arrays.",examples:["md.collection:B","legacy.entities.hashtags.text:ai",'core.user_results.result.legacy.name:"Jane Doe"']}];function qa(e,t,n=""){return {code:e,message:t,token:n||void 0,severity:"warn"}}function lp(e){const t=Number(e);return Number.isFinite(t)?Math.max(.05,Math.min(100,t)):1}function jo(e){if(!e)return [];const t=e.toLowerCase().match(h1);return t?t.map(n=>n.replace(/['’]/g,"")).filter(Boolean):[]}function $d(e){const t=String(e||"").trim().toLowerCase();return !t||t.length<m1?true:f1.has(t)}function Ky(e){const t=e.flatMap(r=>jo(r.value)),n=t.filter(r=>!$d(r));return n.length?n:t}function b1(e){const t=new Set(Ky(e));if(!t.size)return e;const n=e.filter(r=>t.has(String(r.value||"").trim().toLowerCase()));return n.length?n:e}function Zc(e){let t=0;for(const n of e)for(const r of jo(n.value))$d(r)||(t+=1);return t}function Di(e){return jo(e).join(" ").trim()}function v1(e){return Number.isFinite(e)?Math.round(e*100)/100:1}function k1(e,t){const n=e.lastIndexOf(t);if(n<=0)return {base:e,value:null};const r=e.slice(n+1);return !r||!/^\d+(?:\.\d+)?$/.test(r)?{base:e,value:null}:{base:e.slice(0,n),value:r}}function x1(e){const t=String(e||""),n=[];let r=0;for(;r<t.length;){for(;r<t.length&&/\s/.test(t[r]??"");)r+=1;if(r>=t.length)break;const o=t[r]??"";if(o==="("){n.push({kind:"lparen"}),r+=1;continue}if(o===")"){n.push({kind:"rparen"}),r+=1;continue}let a=false;if(o==="-"){for(a=true,r+=1;r<t.length&&/\s/.test(t[r]??"");)r+=1;if(r>=t.length)break;if((t[r]??"")==="("){n.push({kind:"op",op:"NOT"});continue}}let i;const s=r;for(;r<t.length&&/[a-zA-Z0-9_.]/.test(t[r]??"");)r+=1;if(r>s&&(t[r]??"")===":"&&(t[r+1]??"")==='"'&&Vy.test(t.slice(s,r))?(i=t.slice(s,r),r+=1):r=s,(t[r]??"")==='"'){r+=1;let g="";for(;r<t.length;){const C=t[r]??"";if(C==="\\"&&r+1<t.length){g+=t[r+1]??"",r+=2;continue}if(C==='"'){r+=1;break}g+=C,r+=1;}let _=0,b=1;if((t[r]??"")==="~"){r+=1;const C=r;for(;r<t.length&&/\d/.test(t[r]??"");)r+=1;r>C&&(_=Math.max(0,Number(t.slice(C,r))||0));}if((t[r]??"")==="^"){r+=1;const C=r;for(;r<t.length&&/[\d.]/.test(t[r]??"");)r+=1;r>C&&(b=lp(t.slice(C,r)));}n.push({kind:"phrase",value:g.trim(),negated:a,boost:b,slop:_,field:i,quoted:true});continue}const l=r;for(;r<t.length&&!/\s/.test(t[r]??"")&&(t[r]??"")!=="("&&(t[r]??"")!==")";)r+=1;const c=t.slice(l,r).trim();if(!c)continue;const{base:h,value:f}=k1(c,"^"),m=h.toUpperCase();if((m==="AND"||m==="OR"||m==="NOT")&&!a){n.push({kind:"op",op:m});continue}n.push({kind:"term",value:h,negated:a,boost:f?lp(f):1,slop:0});}return n}function S1(e,t){if(t.length&&!/\s$/.test(String(e||"")))for(let n=t.length-1;n>=0;n-=1){const r=t[n];if(!r||!zy(r))continue;if(r.kind!=="term"||r.field||r.quoted)return;const o=Di(r.value);o.length>=y1&&(r.prefix=true),o.length>=_1&&(r.fuzzy=true);return}}function io(e){return e?e.kind==="term"||e.kind==="phrase":false}function C1(e){const t=[];if(!e.length)return {ast:null,warnings:t};const n=[];let r=null;for(const f of e){let m=false;if(r){const g=io(r)||r.kind==="rparen",_=io(f)||f.kind==="lparen"||f.kind==="op"&&f.op==="NOT";g&&_&&(m=true);}m&&n.push({kind:"op",op:"AND"}),n.push(f),r=f;}const o={OR:1,AND:2,NOT:3},a=[],i=[];for(const f of n){if(io(f)){a.push(f);continue}if(f.kind==="lparen"){i.push(f);continue}if(f.kind==="rparen"){let m=false;for(;i.length;){const g=i.pop();if(!g)break;if(g.kind==="lparen"){m=true;break}a.push(g);}m||t.push(qa("boolean_syntax","unmatched closing parenthesis in query"));continue}if(f.kind==="op"){for(;i.length;){const m=i[i.length-1];if(!m||m.kind!=="op"||!(f.op==="NOT"?o[f.op]<o[m.op]:o[f.op]<=o[m.op]))break;a.push(i.pop());}i.push(f);}}for(;i.length;){const f=i.pop();if(!f)break;if(f.kind==="lparen"){t.push(qa("boolean_syntax","unmatched opening parenthesis in query"));continue}a.push(f);}const s=[];for(const f of a){if(io(f)){s.push(f);continue}if(f.kind!=="op")continue;if(f.op==="NOT"){const _=s.pop();if(!_){t.push(qa("boolean_syntax","dangling NOT operator in query","NOT"));continue}s.push({kind:"op",op:"NOT",child:_});continue}const m=s.pop(),g=s.pop();if(!g||!m){t.push(qa("boolean_syntax",`dangling ${f.op} operator in query`,f.op));continue}s.push({kind:"op",op:f.op,left:g,right:m});}if(s.length===1)return {ast:s[0]??null,warnings:t};const l=e.filter(io);if(!l.length)return {ast:null,warnings:t};const c=l[0];if(!c)return {ast:null,warnings:t};let h=c;for(let f=1;f<l.length;f+=1){const m=l[f];m&&(h={kind:"op",op:"AND",left:h,right:m});}return t.push(qa("boolean_syntax","query boolean expression was malformed; fell back to implicit AND between lexical terms")),{ast:h,warnings:t}}function cp(e,t){const n=[],r=(o,a)=>{if(o){if(io(o)){a===t&&n.push(o);return}if(o.op==="NOT"){r(o.child,!a);return}r(o.left,a),r(o.right,a);}};return r(e,true),n}function Gu(e,t,n){if(e){if(!io(e)&&e.op===t){Gu(e.left,t,n),Gu(e.right,t,n);return}n.push(e);}}function Yu(e){if(!e)return "";if(io(e)){let r=e.kind==="phrase"?`"${e.value}"`:e.value;return e.prefix&&(r+="*"),e.kind==="phrase"&&e.slop>0&&(r+=`~${e.slop}`),Math.abs(e.boost-1)>1e-9&&(r+=`^${e.boost}`),e.field&&(r=`${e.field}:${r}`),r}if(e.op==="NOT"){const r=Yu(e.child);return r?`NOT (${r})`:"NOT (?)"}const t=[];return Gu(e,e.op,t),t.map(r=>{const o=Yu(r);return o?!io(r)&&r.op!==e.op?`(${o})`:o:""}).filter(Boolean).join(` ${e.op} `)}function T1(e){return !e.field&&e.kind==="term"&&jo(e.value).length===1}function M1(e){var a,i,s,l,c,h,f,m;if(e.length<=1)return e;const t=[],n=new Set,r=g=>{const _=`${g.kind}|${g.field||""}|${g.value}|${g.slop}|${g.boost}`;n.has(_)||(n.add(_),t.push(g));},o=(g,_)=>{const b=g.reduce((C,k)=>C+k.boost,0)/g.length;return v1(_*b)};for(const g of b1(e))r(g);for(let g=0;g<=e.length-2;g+=1){const _=e.slice(g,g+2);Zc(_)<2||r({kind:"phrase",value:_.map(b=>b.value).join(" "),slop:ro.bigram_slop,boost:o(_,ro.bigram_boost),prefix:!!((a=_[_.length-1])!=null&&a.prefix),fuzzy:!!((i=_[_.length-1])!=null&&i.fuzzy)});}for(let g=0;g<=e.length-3;g+=1){const _=e.slice(g,g+3);Zc(_)<2||r({kind:"phrase",value:_.map(b=>b.value).join(" "),slop:ro.trigram_slop,boost:o(_,ro.trigram_boost),prefix:!!((s=_[_.length-1])!=null&&s.prefix),fuzzy:!!((l=_[_.length-1])!=null&&l.fuzzy)});}for(let g=0;g<=e.length-4;g+=1){const _=e.slice(g,g+4);Zc(_)<2||r({kind:"phrase",value:_.map(b=>b.value).join(" "),slop:ro.fourgram_slop,boost:o(_,ro.fourgram_boost),prefix:!!((c=_[_.length-1])!=null&&c.prefix),fuzzy:!!((h=_[_.length-1])!=null&&h.fuzzy)});}return e.length>=g1&&r({kind:"phrase",value:e.map(g=>g.value).join(" "),slop:0,boost:o(e,ro.full_run_exact_boost),prefix:!!((f=e[e.length-1])!=null&&f.prefix),fuzzy:!!((m=e[e.length-1])!=null&&m.fuzzy)}),t}function R1(e,t){if(!t.length)return;if(t.length===1){e.push(t[0]),t.length=0;return}const n=M1(t);e.push({kind:"lparen"}),n.forEach((r,o)=>{o>0&&e.push({kind:"op",op:"OR"}),e.push(r);}),e.push({kind:"rparen"}),t.length=0;}function I1(e){const t=new Set,n=[];for(const r of e)for(const o of jo(r))!o||t.has(o)||(t.add(o),n.push(o));return n}function E1(e,t){const n=new Set;for(const r of e)for(const o of jo(r.value))o&&!$d(o)&&n.add(o);for(const r of t)if(!(r.negated||d1.has(r.name)))for(const o of jo(r.value))o&&n.add(o);return [...n].slice(0,p1)}function A1(e){var k;const t=x1(e);S1(e,t);const n=[],r=[],o=[],a=[],i=[],s=[],l=()=>{if(a.length){const T=Ky(a);s.push(...T),i.push(...T);}R1(o,a);};for(const T of t){if(!zy(T)){l(),o.push(T);continue}const M=String(T.value||"").trim();if(!M)continue;let P=T.kind,F=M,I=(k=T.field)==null?void 0:k.trim(),O=false;if(I&&sp.has(I)){n.push({name:I,value:M,negated:T.negated}),l();continue}if(T.kind==="term"&&M.startsWith("@")&&M.length>1){const D=Di(M.slice(1));if(D){n.push({name:"from",value:D,negated:T.negated}),l();continue}}else if(T.kind==="term"&&M.startsWith("#")&&M.length>1){const D=Di(M.slice(1));D&&(n.push({name:"hashtag",value:D,negated:T.negated}),P="term",F=D,O=true);}else if(T.kind==="term"&&M.startsWith("$")&&M.length>1){const D=Di(M.slice(1));D&&(n.push({name:"cashtag",value:D,negated:T.negated}),P="term",F=D,O=true);}else if(T.kind==="term"&&M.includes(":")){const[D,...v]=M.split(":"),L=String(D||"").trim().toLowerCase(),$=v.join(":").trim();if(sp.has(L)){if(!$){r.push(M);continue}n.push({name:L,value:$,negated:T.negated}),l();continue}L&&$&&Vy.test(L)&&(P="term",F=$,I=L);}const B={kind:P,value:P==="term"?Di(F):F.trim(),boost:T.boost,slop:T.slop,field:I||void 0,quoted:!!T.quoted,prefix:!!T.prefix,fuzzy:!!T.fuzzy};if(B.value){if(T.negated){l(),o.push({kind:"op",op:"NOT"}),o.push(B);continue}if(!O&&T1(B)){a.push(B);continue}if(l(),!B.field){const D=jo(B.value);s.push(...D),i.push(...D);}o.push(B);}}l();const{ast:c,warnings:h}=C1(o),f=cp(c,true),m=cp(c,false),g=s.filter(Boolean),_=I1(i),b=E1(f,n),C=r.map(T=>qa("unsupported_token",`unsupported token: ${T}`,T));return {query:String(e||""),lexicalTokens:o,lexicalAst:c,lexicalExpression:Yu(c),positiveLexicalTokens:f,negativeLexicalTokens:m,positiveTerms:_,filters:n,unsupported:r,orderedTerms:g,highlightTerms:b,warnings:[...h,...C],hasPositiveLexical:f.length>0,filterBooleanSemantics:"global_and"}}const Wy="twe_search_history_v1";function Gy(){return typeof localStorage<"u"}function Yy(e){return [...new Set(e.map(t=>t.trim()).filter(Boolean))].sort()}function up(e,t,n){return `${e}::${t}::${Yy(n).join(",")}`}function Hd(e){if(!Gy())return [];try{const t=localStorage.getItem(Wy);if(!t)return [];const n=JSON.parse(t);if(!Array.isArray(n))return [];const r=n.filter(o=>!!o&&typeof o=="object");return e?r.filter(o=>o.scope===e):r}catch{return []}}function D1(e){const t=Date.now(),n={...e,selected_folders:Yy(e.selected_folders),id:`${e.scope}:${t}:${Math.random().toString(36).slice(2,8)}`,searched_at_iso:new Date(t).toISOString(),repeat_count:1},o=[...Hd()],a=up(n.scope,n.normalized_query,n.selected_folders),i=o[o.length-1];i&&up(i.scope,i.normalized_query,i.selected_folders||[])===a?o[o.length-1]={...i,query:n.query,title:n.title,searched_at_ms:n.searched_at_ms,searched_at_iso:n.searched_at_iso,result_count:n.result_count,total_records:n.total_records,lexical_expression:n.lexical_expression,warning_messages:[...n.warning_messages],repeat_count:(i.repeat_count||1)+1}:o.push(n);const s=o.slice(-4e3);if(Gy())try{localStorage.setItem(Wy,JSON.stringify(s));}catch{}return s}/**
     * table-core
     *
     * Copyright (c) TanStack
     *
     * This source code is licensed under the MIT license found in the
     * LICENSE.md file in the root directory of this source tree.
     *
     * @license MIT
     */function jd(){return {accessor:(e,t)=>typeof e=="function"?{...t,accessorFn:e}:{...t,accessorKey:e},display:e=>e,group:e=>e}}function lo(e,t){return typeof e=="function"?e(t):e}function pr(e,t){return n=>{t.setState(r=>({...r,[e]:lo(n,r[e])}));}}function Ql(e){return e instanceof Function}function P1(e){return Array.isArray(e)&&e.every(t=>typeof t=="number")}function O1(e,t){const n=[],r=o=>{o.forEach(a=>{n.push(a);const i=t(a);i!=null&&i.length&&r(i);});};return r(e),n}function Pt(e,t,n){let r=[],o;return a=>{let i;n.key&&n.debug&&(i=Date.now());const s=e(a);if(!(s.length!==r.length||s.some((h,f)=>r[f]!==h)))return o;r=s;let c;if(n.key&&n.debug&&(c=Date.now()),o=t(...s),n==null||n.onChange==null||n.onChange(o),n.key&&n.debug&&n!=null&&n.debug()){const h=Math.round((Date.now()-i)*100)/100,f=Math.round((Date.now()-c)*100)/100,m=f/16,g=(_,b)=>{for(_=String(_);_.length<b;)_=" "+_;return _};console.info(`%c⏱ ${g(f,5)} /${g(h,5)} ms`,`
            font-size: .6rem;
            font-weight: bold;
            color: hsl(${Math.max(0,Math.min(120-120*m,120))}deg 100% 31%);`,n==null?void 0:n.key);}return o}}function Ot(e,t,n,r){return {debug:()=>{var o;return (o=e==null?void 0:e.debugAll)!=null?o:e[t]},key:false,onChange:r}}function F1(e,t,n,r){const o=()=>{var i;return (i=a.getValue())!=null?i:e.options.renderFallbackValue},a={id:`${t.id}_${n.id}`,row:t,column:n,getValue:()=>t.getValue(r),renderValue:o,getContext:Pt(()=>[e,n,t,a],(i,s,l,c)=>({table:i,column:s,row:l,cell:c,getValue:c.getValue,renderValue:c.renderValue}),Ot(e.options,"debugCells"))};return e._features.forEach(i=>{i.createCell==null||i.createCell(a,n,t,e);},{}),a}function L1(e,t,n,r){var o,a;const s={...e._getDefaultColumnDef(),...t},l=s.accessorKey;let c=(o=(a=s.id)!=null?a:l?typeof String.prototype.replaceAll=="function"?l.replaceAll(".","_"):l.replace(/\./g,"_"):void 0)!=null?o:typeof s.header=="string"?s.header:void 0,h;if(s.accessorFn?h=s.accessorFn:l&&(l.includes(".")?h=m=>{let g=m;for(const b of l.split(".")){var _;g=(_=g)==null?void 0:_[b];}return g}:h=m=>m[s.accessorKey]),!c)throw new Error;let f={id:`${String(c)}`,accessorFn:h,parent:r,depth:n,columnDef:s,columns:[],getFlatColumns:Pt(()=>[true],()=>{var m;return [f,...(m=f.columns)==null?void 0:m.flatMap(g=>g.getFlatColumns())]},Ot(e.options,"debugColumns")),getLeafColumns:Pt(()=>[e._getOrderColumnsFn()],m=>{var g;if((g=f.columns)!=null&&g.length){let _=f.columns.flatMap(b=>b.getLeafColumns());return m(_)}return [f]},Ot(e.options,"debugColumns"))};for(const m of e._features)m.createColumn==null||m.createColumn(f,e);return f}const Qn="debugHeaders";function dp(e,t,n){var r;let a={id:(r=n.id)!=null?r:t.id,column:t,index:n.index,isPlaceholder:!!n.isPlaceholder,placeholderId:n.placeholderId,depth:n.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const i=[],s=l=>{l.subHeaders&&l.subHeaders.length&&l.subHeaders.map(s),i.push(l);};return s(a),i},getContext:()=>({table:e,header:a,column:t})};return e._features.forEach(i=>{i.createHeader==null||i.createHeader(a,e);}),a}const N1={createTable:e=>{e.getHeaderGroups=Pt(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r,o)=>{var a,i;const s=(a=r==null?void 0:r.map(f=>n.find(m=>m.id===f)).filter(Boolean))!=null?a:[],l=(i=o==null?void 0:o.map(f=>n.find(m=>m.id===f)).filter(Boolean))!=null?i:[],c=n.filter(f=>!(r!=null&&r.includes(f.id))&&!(o!=null&&o.includes(f.id)));return Us(t,[...s,...c,...l],e)},Ot(e.options,Qn)),e.getCenterHeaderGroups=Pt(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r,o)=>(n=n.filter(a=>!(r!=null&&r.includes(a.id))&&!(o!=null&&o.includes(a.id))),Us(t,n,e,"center")),Ot(e.options,Qn)),e.getLeftHeaderGroups=Pt(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left],(t,n,r)=>{var o;const a=(o=r==null?void 0:r.map(i=>n.find(s=>s.id===i)).filter(Boolean))!=null?o:[];return Us(t,a,e,"left")},Ot(e.options,Qn)),e.getRightHeaderGroups=Pt(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right],(t,n,r)=>{var o;const a=(o=r==null?void 0:r.map(i=>n.find(s=>s.id===i)).filter(Boolean))!=null?o:[];return Us(t,a,e,"right")},Ot(e.options,Qn)),e.getFooterGroups=Pt(()=>[e.getHeaderGroups()],t=>[...t].reverse(),Ot(e.options,Qn)),e.getLeftFooterGroups=Pt(()=>[e.getLeftHeaderGroups()],t=>[...t].reverse(),Ot(e.options,Qn)),e.getCenterFooterGroups=Pt(()=>[e.getCenterHeaderGroups()],t=>[...t].reverse(),Ot(e.options,Qn)),e.getRightFooterGroups=Pt(()=>[e.getRightHeaderGroups()],t=>[...t].reverse(),Ot(e.options,Qn)),e.getFlatHeaders=Pt(()=>[e.getHeaderGroups()],t=>t.map(n=>n.headers).flat(),Ot(e.options,Qn)),e.getLeftFlatHeaders=Pt(()=>[e.getLeftHeaderGroups()],t=>t.map(n=>n.headers).flat(),Ot(e.options,Qn)),e.getCenterFlatHeaders=Pt(()=>[e.getCenterHeaderGroups()],t=>t.map(n=>n.headers).flat(),Ot(e.options,Qn)),e.getRightFlatHeaders=Pt(()=>[e.getRightHeaderGroups()],t=>t.map(n=>n.headers).flat(),Ot(e.options,Qn)),e.getCenterLeafHeaders=Pt(()=>[e.getCenterFlatHeaders()],t=>t.filter(n=>{var r;return !((r=n.subHeaders)!=null&&r.length)}),Ot(e.options,Qn)),e.getLeftLeafHeaders=Pt(()=>[e.getLeftFlatHeaders()],t=>t.filter(n=>{var r;return !((r=n.subHeaders)!=null&&r.length)}),Ot(e.options,Qn)),e.getRightLeafHeaders=Pt(()=>[e.getRightFlatHeaders()],t=>t.filter(n=>{var r;return !((r=n.subHeaders)!=null&&r.length)}),Ot(e.options,Qn)),e.getLeafHeaders=Pt(()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()],(t,n,r)=>{var o,a,i,s,l,c;return [...(o=(a=t[0])==null?void 0:a.headers)!=null?o:[],...(i=(s=n[0])==null?void 0:s.headers)!=null?i:[],...(l=(c=r[0])==null?void 0:c.headers)!=null?l:[]].map(h=>h.getLeafHeaders()).flat()},Ot(e.options,Qn));}};function Us(e,t,n,r){var o,a;let i=0;const s=function(m,g){g===void 0&&(g=1),i=Math.max(i,g),m.filter(_=>_.getIsVisible()).forEach(_=>{var b;(b=_.columns)!=null&&b.length&&s(_.columns,g+1);},0);};s(e);let l=[];const c=(m,g)=>{const _={depth:g,id:[r,`${g}`].filter(Boolean).join("_"),headers:[]},b=[];m.forEach(C=>{const k=[...b].reverse()[0],T=C.column.depth===_.depth;let M,P=false;if(T&&C.column.parent?M=C.column.parent:(M=C.column,P=true),k&&(k==null?void 0:k.column)===M)k.subHeaders.push(C);else {const F=dp(n,M,{id:[r,g,M.id,C==null?void 0:C.id].filter(Boolean).join("_"),isPlaceholder:P,placeholderId:P?`${b.filter(I=>I.column===M).length}`:void 0,depth:g,index:b.length});F.subHeaders.push(C),b.push(F);}_.headers.push(C),C.headerGroup=_;}),l.push(_),g>0&&c(b,g-1);},h=t.map((m,g)=>dp(n,m,{depth:i,index:g}));c(h,i-1),l.reverse();const f=m=>m.filter(_=>_.column.getIsVisible()).map(_=>{let b=0,C=0,k=[0];_.subHeaders&&_.subHeaders.length?(k=[],f(_.subHeaders).forEach(M=>{let{colSpan:P,rowSpan:F}=M;b+=P,k.push(F);})):b=1;const T=Math.min(...k);return C=C+T,_.colSpan=b,_.rowSpan=C,{colSpan:b,rowSpan:C}});return f((o=(a=l[0])==null?void 0:a.headers)!=null?o:[]),l}const B1=(e,t,n,r,o,a,i)=>{let s={id:t,index:r,original:n,depth:o,parentId:i,_valuesCache:{},_uniqueValuesCache:{},getValue:l=>{if(s._valuesCache.hasOwnProperty(l))return s._valuesCache[l];const c=e.getColumn(l);if(c!=null&&c.accessorFn)return s._valuesCache[l]=c.accessorFn(s.original,r),s._valuesCache[l]},getUniqueValues:l=>{if(s._uniqueValuesCache.hasOwnProperty(l))return s._uniqueValuesCache[l];const c=e.getColumn(l);if(c!=null&&c.accessorFn)return c.columnDef.getUniqueValues?(s._uniqueValuesCache[l]=c.columnDef.getUniqueValues(s.original,r),s._uniqueValuesCache[l]):(s._uniqueValuesCache[l]=[s.getValue(l)],s._uniqueValuesCache[l])},renderValue:l=>{var c;return (c=s.getValue(l))!=null?c:e.options.renderFallbackValue},subRows:[],getLeafRows:()=>O1(s.subRows,l=>l.subRows),getParentRow:()=>s.parentId?e.getRow(s.parentId,true):void 0,getParentRows:()=>{let l=[],c=s;for(;;){const h=c.getParentRow();if(!h)break;l.push(h),c=h;}return l.reverse()},getAllCells:Pt(()=>[e.getAllLeafColumns()],l=>l.map(c=>F1(e,s,c,c.id)),Ot(e.options,"debugRows")),_getAllCellsByColumnId:Pt(()=>[s.getAllCells()],l=>l.reduce((c,h)=>(c[h.column.id]=h,c),{}),Ot(e.options,"debugRows"))};for(let l=0;l<e._features.length;l++){const c=e._features[l];c==null||c.createRow==null||c.createRow(s,e);}return s},U1={createColumn:(e,t)=>{e._getFacetedRowModel=t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,e.id),e.getFacetedRowModel=()=>e._getFacetedRowModel?e._getFacetedRowModel():t.getPreFilteredRowModel(),e._getFacetedUniqueValues=t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,e.id),e.getFacetedUniqueValues=()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,e._getFacetedMinMaxValues=t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,e.id),e.getFacetedMinMaxValues=()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()};}},Xy=(e,t,n)=>{var r,o;const a=n==null||(r=n.toString())==null?void 0:r.toLowerCase();return !!(!((o=e.getValue(t))==null||(o=o.toString())==null||(o=o.toLowerCase())==null)&&o.includes(a))};Xy.autoRemove=e=>Lr(e);const Zy=(e,t,n)=>{var r;return !!(!((r=e.getValue(t))==null||(r=r.toString())==null)&&r.includes(n))};Zy.autoRemove=e=>Lr(e);const Qy=(e,t,n)=>{var r;return ((r=e.getValue(t))==null||(r=r.toString())==null?void 0:r.toLowerCase())===(n==null?void 0:n.toLowerCase())};Qy.autoRemove=e=>Lr(e);const Jy=(e,t,n)=>{var r;return (r=e.getValue(t))==null?void 0:r.includes(n)};Jy.autoRemove=e=>Lr(e);const e_=(e,t,n)=>!n.some(r=>{var o;return !((o=e.getValue(t))!=null&&o.includes(r))});e_.autoRemove=e=>Lr(e)||!(e!=null&&e.length);const t_=(e,t,n)=>n.some(r=>{var o;return (o=e.getValue(t))==null?void 0:o.includes(r)});t_.autoRemove=e=>Lr(e)||!(e!=null&&e.length);const n_=(e,t,n)=>e.getValue(t)===n;n_.autoRemove=e=>Lr(e);const r_=(e,t,n)=>e.getValue(t)==n;r_.autoRemove=e=>Lr(e);const qd=(e,t,n)=>{let[r,o]=n;const a=e.getValue(t);return a>=r&&a<=o};qd.resolveFilterValue=e=>{let[t,n]=e,r=typeof t!="number"?parseFloat(t):t,o=typeof n!="number"?parseFloat(n):n,a=t===null||Number.isNaN(r)?-1/0:r,i=n===null||Number.isNaN(o)?1/0:o;if(a>i){const s=a;a=i,i=s;}return [a,i]};qd.autoRemove=e=>Lr(e)||Lr(e[0])&&Lr(e[1]);const oo={includesString:Xy,includesStringSensitive:Zy,equalsString:Qy,arrIncludes:Jy,arrIncludesAll:e_,arrIncludesSome:t_,equals:n_,weakEquals:r_,inNumberRange:qd};function Lr(e){return e==null||e===""}const $1={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],...e}),getDefaultOptions:e=>({onColumnFiltersChange:pr("columnFilters",e),filterFromLeafRows:false,maxLeafRowFilterDepth:100}),createColumn:(e,t)=>{e.getAutoFilterFn=()=>{const n=t.getCoreRowModel().flatRows[0],r=n==null?void 0:n.getValue(e.id);return typeof r=="string"?oo.includesString:typeof r=="number"?oo.inNumberRange:typeof r=="boolean"||r!==null&&typeof r=="object"?oo.equals:Array.isArray(r)?oo.arrIncludes:oo.weakEquals},e.getFilterFn=()=>{var n,r;return Ql(e.columnDef.filterFn)?e.columnDef.filterFn:e.columnDef.filterFn==="auto"?e.getAutoFilterFn():(n=(r=t.options.filterFns)==null?void 0:r[e.columnDef.filterFn])!=null?n:oo[e.columnDef.filterFn]},e.getCanFilter=()=>{var n,r,o;return ((n=e.columnDef.enableColumnFilter)!=null?n:true)&&((r=t.options.enableColumnFilters)!=null?r:true)&&((o=t.options.enableFilters)!=null?o:true)&&!!e.accessorFn},e.getIsFiltered=()=>e.getFilterIndex()>-1,e.getFilterValue=()=>{var n;return (n=t.getState().columnFilters)==null||(n=n.find(r=>r.id===e.id))==null?void 0:n.value},e.getFilterIndex=()=>{var n,r;return (n=(r=t.getState().columnFilters)==null?void 0:r.findIndex(o=>o.id===e.id))!=null?n:-1},e.setFilterValue=n=>{t.setColumnFilters(r=>{const o=e.getFilterFn(),a=r==null?void 0:r.find(h=>h.id===e.id),i=lo(n,a?a.value:void 0);if(fp(o,i,e)){var s;return (s=r==null?void 0:r.filter(h=>h.id!==e.id))!=null?s:[]}const l={id:e.id,value:i};if(a){var c;return (c=r==null?void 0:r.map(h=>h.id===e.id?l:h))!=null?c:[]}return r!=null&&r.length?[...r,l]:[l]});};},createRow:(e,t)=>{e.columnFilters={},e.columnFiltersMeta={};},createTable:e=>{e.setColumnFilters=t=>{const n=e.getAllLeafColumns(),r=o=>{var a;return (a=lo(t,o))==null?void 0:a.filter(i=>{const s=n.find(l=>l.id===i.id);if(s){const l=s.getFilterFn();if(fp(l,i.value,s))return  false}return  true})};e.options.onColumnFiltersChange==null||e.options.onColumnFiltersChange(r);},e.resetColumnFilters=t=>{var n,r;e.setColumnFilters(t?[]:(n=(r=e.initialState)==null?void 0:r.columnFilters)!=null?n:[]);},e.getPreFilteredRowModel=()=>e.getCoreRowModel(),e.getFilteredRowModel=()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel());}};function fp(e,t,n){return (e&&e.autoRemove?e.autoRemove(t,n):false)||typeof t>"u"||typeof t=="string"&&!t}const H1=(e,t,n)=>n.reduce((r,o)=>{const a=o.getValue(e);return r+(typeof a=="number"?a:0)},0),j1=(e,t,n)=>{let r;return n.forEach(o=>{const a=o.getValue(e);a!=null&&(r>a||r===void 0&&a>=a)&&(r=a);}),r},q1=(e,t,n)=>{let r;return n.forEach(o=>{const a=o.getValue(e);a!=null&&(r<a||r===void 0&&a>=a)&&(r=a);}),r},V1=(e,t,n)=>{let r,o;return n.forEach(a=>{const i=a.getValue(e);i!=null&&(r===void 0?i>=i&&(r=o=i):(r>i&&(r=i),o<i&&(o=i)));}),[r,o]},z1=(e,t)=>{let n=0,r=0;if(t.forEach(o=>{let a=o.getValue(e);a!=null&&(a=+a)>=a&&(++n,r+=a);}),n)return r/n},K1=(e,t)=>{if(!t.length)return;const n=t.map(a=>a.getValue(e));if(!P1(n))return;if(n.length===1)return n[0];const r=Math.floor(n.length/2),o=n.sort((a,i)=>a-i);return n.length%2!==0?o[r]:(o[r-1]+o[r])/2},W1=(e,t)=>Array.from(new Set(t.map(n=>n.getValue(e))).values()),G1=(e,t)=>new Set(t.map(n=>n.getValue(e))).size,Y1=(e,t)=>t.length,Qc={sum:H1,min:j1,max:q1,extent:V1,mean:z1,median:K1,unique:W1,uniqueCount:G1,count:Y1},X1={getDefaultColumnDef:()=>({aggregatedCell:e=>{var t,n;return (t=(n=e.getValue())==null||n.toString==null?void 0:n.toString())!=null?t:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:pr("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,t)=>{e.toggleGrouping=()=>{t.setGrouping(n=>n!=null&&n.includes(e.id)?n.filter(r=>r!==e.id):[...n??[],e.id]);},e.getCanGroup=()=>{var n,r;return ((n=e.columnDef.enableGrouping)!=null?n:true)&&((r=t.options.enableGrouping)!=null?r:true)&&(!!e.accessorFn||!!e.columnDef.getGroupingValue)},e.getIsGrouped=()=>{var n;return (n=t.getState().grouping)==null?void 0:n.includes(e.id)},e.getGroupedIndex=()=>{var n;return (n=t.getState().grouping)==null?void 0:n.indexOf(e.id)},e.getToggleGroupingHandler=()=>{const n=e.getCanGroup();return ()=>{n&&e.toggleGrouping();}},e.getAutoAggregationFn=()=>{const n=t.getCoreRowModel().flatRows[0],r=n==null?void 0:n.getValue(e.id);if(typeof r=="number")return Qc.sum;if(Object.prototype.toString.call(r)==="[object Date]")return Qc.extent},e.getAggregationFn=()=>{var n,r;if(!e)throw new Error;return Ql(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:e.columnDef.aggregationFn==="auto"?e.getAutoAggregationFn():(n=(r=t.options.aggregationFns)==null?void 0:r[e.columnDef.aggregationFn])!=null?n:Qc[e.columnDef.aggregationFn]};},createTable:e=>{e.setGrouping=t=>e.options.onGroupingChange==null?void 0:e.options.onGroupingChange(t),e.resetGrouping=t=>{var n,r;e.setGrouping(t?[]:(n=(r=e.initialState)==null?void 0:r.grouping)!=null?n:[]);},e.getPreGroupedRowModel=()=>e.getFilteredRowModel(),e.getGroupedRowModel=()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel());},createRow:(e,t)=>{e.getIsGrouped=()=>!!e.groupingColumnId,e.getGroupingValue=n=>{if(e._groupingValuesCache.hasOwnProperty(n))return e._groupingValuesCache[n];const r=t.getColumn(n);return r!=null&&r.columnDef.getGroupingValue?(e._groupingValuesCache[n]=r.columnDef.getGroupingValue(e.original),e._groupingValuesCache[n]):e.getValue(n)},e._groupingValuesCache={};},createCell:(e,t,n,r)=>{e.getIsGrouped=()=>t.getIsGrouped()&&t.id===n.groupingColumnId,e.getIsPlaceholder=()=>!e.getIsGrouped()&&t.getIsGrouped(),e.getIsAggregated=()=>{var o;return !e.getIsGrouped()&&!e.getIsPlaceholder()&&!!((o=n.subRows)!=null&&o.length)};}};function Z1(e,t,n){if(!(t!=null&&t.length)||!n)return e;const r=e.filter(a=>!t.includes(a.id));return n==="remove"?r:[...t.map(a=>e.find(i=>i.id===a)).filter(Boolean),...r]}const Q1={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:pr("columnOrder",e)}),createColumn:(e,t)=>{e.getIndex=Pt(n=>[Hi(t,n)],n=>n.findIndex(r=>r.id===e.id),Ot(t.options,"debugColumns")),e.getIsFirstColumn=n=>{var r;return ((r=Hi(t,n)[0])==null?void 0:r.id)===e.id},e.getIsLastColumn=n=>{var r;const o=Hi(t,n);return ((r=o[o.length-1])==null?void 0:r.id)===e.id};},createTable:e=>{e.setColumnOrder=t=>e.options.onColumnOrderChange==null?void 0:e.options.onColumnOrderChange(t),e.resetColumnOrder=t=>{var n;e.setColumnOrder(t?[]:(n=e.initialState.columnOrder)!=null?n:[]);},e._getOrderColumnsFn=Pt(()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode],(t,n,r)=>o=>{let a=[];if(!(t!=null&&t.length))a=o;else {const i=[...t],s=[...o];for(;s.length&&i.length;){const l=i.shift(),c=s.findIndex(h=>h.id===l);c>-1&&a.push(s.splice(c,1)[0]);}a=[...a,...s];}return Z1(a,n,r)},Ot(e.options,"debugTable"));}},Jc=()=>({left:[],right:[]}),J1={getInitialState:e=>({columnPinning:Jc(),...e}),getDefaultOptions:e=>({onColumnPinningChange:pr("columnPinning",e)}),createColumn:(e,t)=>{e.pin=n=>{const r=e.getLeafColumns().map(o=>o.id).filter(Boolean);t.setColumnPinning(o=>{var a,i;if(n==="right"){var s,l;return {left:((s=o==null?void 0:o.left)!=null?s:[]).filter(f=>!(r!=null&&r.includes(f))),right:[...((l=o==null?void 0:o.right)!=null?l:[]).filter(f=>!(r!=null&&r.includes(f))),...r]}}if(n==="left"){var c,h;return {left:[...((c=o==null?void 0:o.left)!=null?c:[]).filter(f=>!(r!=null&&r.includes(f))),...r],right:((h=o==null?void 0:o.right)!=null?h:[]).filter(f=>!(r!=null&&r.includes(f)))}}return {left:((a=o==null?void 0:o.left)!=null?a:[]).filter(f=>!(r!=null&&r.includes(f))),right:((i=o==null?void 0:o.right)!=null?i:[]).filter(f=>!(r!=null&&r.includes(f)))}});},e.getCanPin=()=>e.getLeafColumns().some(r=>{var o,a,i;return ((o=r.columnDef.enablePinning)!=null?o:true)&&((a=(i=t.options.enableColumnPinning)!=null?i:t.options.enablePinning)!=null?a:true)}),e.getIsPinned=()=>{const n=e.getLeafColumns().map(s=>s.id),{left:r,right:o}=t.getState().columnPinning,a=n.some(s=>r==null?void 0:r.includes(s)),i=n.some(s=>o==null?void 0:o.includes(s));return a?"left":i?"right":false},e.getPinnedIndex=()=>{var n,r;const o=e.getIsPinned();return o?(n=(r=t.getState().columnPinning)==null||(r=r[o])==null?void 0:r.indexOf(e.id))!=null?n:-1:0};},createRow:(e,t)=>{e.getCenterVisibleCells=Pt(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,t.getState().columnPinning.right],(n,r,o)=>{const a=[...r??[],...o??[]];return n.filter(i=>!a.includes(i.column.id))},Ot(t.options,"debugRows")),e.getLeftVisibleCells=Pt(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left],(n,r)=>(r??[]).map(a=>n.find(i=>i.column.id===a)).filter(Boolean).map(a=>({...a,position:"left"})),Ot(t.options,"debugRows")),e.getRightVisibleCells=Pt(()=>[e._getAllVisibleCells(),t.getState().columnPinning.right],(n,r)=>(r??[]).map(a=>n.find(i=>i.column.id===a)).filter(Boolean).map(a=>({...a,position:"right"})),Ot(t.options,"debugRows"));},createTable:e=>{e.setColumnPinning=t=>e.options.onColumnPinningChange==null?void 0:e.options.onColumnPinningChange(t),e.resetColumnPinning=t=>{var n,r;return e.setColumnPinning(t?Jc():(n=(r=e.initialState)==null?void 0:r.columnPinning)!=null?n:Jc())},e.getIsSomeColumnsPinned=t=>{var n;const r=e.getState().columnPinning;if(!t){var o,a;return !!((o=r.left)!=null&&o.length||(a=r.right)!=null&&a.length)}return !!((n=r[t])!=null&&n.length)},e.getLeftLeafColumns=Pt(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left],(t,n)=>(n??[]).map(r=>t.find(o=>o.id===r)).filter(Boolean),Ot(e.options,"debugColumns")),e.getRightLeafColumns=Pt(()=>[e.getAllLeafColumns(),e.getState().columnPinning.right],(t,n)=>(n??[]).map(r=>t.find(o=>o.id===r)).filter(Boolean),Ot(e.options,"debugColumns")),e.getCenterLeafColumns=Pt(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r)=>{const o=[...n??[],...r??[]];return t.filter(a=>!o.includes(a.id))},Ot(e.options,"debugColumns"));}},$s={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},eu=()=>({startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:false,columnSizingStart:[]}),eC={getDefaultColumnDef:()=>$s,getInitialState:e=>({columnSizing:{},columnSizingInfo:eu(),...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",columnResizeDirection:"ltr",onColumnSizingChange:pr("columnSizing",e),onColumnSizingInfoChange:pr("columnSizingInfo",e)}),createColumn:(e,t)=>{e.getSize=()=>{var n,r,o;const a=t.getState().columnSizing[e.id];return Math.min(Math.max((n=e.columnDef.minSize)!=null?n:$s.minSize,(r=a??e.columnDef.size)!=null?r:$s.size),(o=e.columnDef.maxSize)!=null?o:$s.maxSize)},e.getStart=Pt(n=>[n,Hi(t,n),t.getState().columnSizing],(n,r)=>r.slice(0,e.getIndex(n)).reduce((o,a)=>o+a.getSize(),0),Ot(t.options,"debugColumns")),e.getAfter=Pt(n=>[n,Hi(t,n),t.getState().columnSizing],(n,r)=>r.slice(e.getIndex(n)+1).reduce((o,a)=>o+a.getSize(),0),Ot(t.options,"debugColumns")),e.resetSize=()=>{t.setColumnSizing(n=>{let{[e.id]:r,...o}=n;return o});},e.getCanResize=()=>{var n,r;return ((n=e.columnDef.enableResizing)!=null?n:true)&&((r=t.options.enableColumnResizing)!=null?r:true)},e.getIsResizing=()=>t.getState().columnSizingInfo.isResizingColumn===e.id;},createHeader:(e,t)=>{e.getSize=()=>{let n=0;const r=o=>{if(o.subHeaders.length)o.subHeaders.forEach(r);else {var a;n+=(a=o.column.getSize())!=null?a:0;}};return r(e),n},e.getStart=()=>{if(e.index>0){const n=e.headerGroup.headers[e.index-1];return n.getStart()+n.getSize()}return 0},e.getResizeHandler=n=>{const r=t.getColumn(e.column.id),o=r==null?void 0:r.getCanResize();return a=>{if(!r||!o||(a.persist==null||a.persist(),tu(a)&&a.touches&&a.touches.length>1))return;const i=e.getSize(),s=e?e.getLeafHeaders().map(k=>[k.column.id,k.column.getSize()]):[[r.id,r.getSize()]],l=tu(a)?Math.round(a.touches[0].clientX):a.clientX,c={},h=(k,T)=>{typeof T=="number"&&(t.setColumnSizingInfo(M=>{var P,F;const I=t.options.columnResizeDirection==="rtl"?-1:1,O=(T-((P=M==null?void 0:M.startOffset)!=null?P:0))*I,B=Math.max(O/((F=M==null?void 0:M.startSize)!=null?F:0),-0.999999);return M.columnSizingStart.forEach(D=>{let[v,L]=D;c[v]=Math.round(Math.max(L+L*B,0)*100)/100;}),{...M,deltaOffset:O,deltaPercentage:B}}),(t.options.columnResizeMode==="onChange"||k==="end")&&t.setColumnSizing(M=>({...M,...c})));},f=k=>h("move",k),m=k=>{h("end",k),t.setColumnSizingInfo(T=>({...T,isResizingColumn:false,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]}));},g=n||typeof document<"u"?document:null,_={moveHandler:k=>f(k.clientX),upHandler:k=>{g==null||g.removeEventListener("mousemove",_.moveHandler),g==null||g.removeEventListener("mouseup",_.upHandler),m(k.clientX);}},b={moveHandler:k=>(k.cancelable&&(k.preventDefault(),k.stopPropagation()),f(k.touches[0].clientX),false),upHandler:k=>{var T;g==null||g.removeEventListener("touchmove",b.moveHandler),g==null||g.removeEventListener("touchend",b.upHandler),k.cancelable&&(k.preventDefault(),k.stopPropagation()),m((T=k.touches[0])==null?void 0:T.clientX);}},C=tC()?{passive:false}:false;tu(a)?(g==null||g.addEventListener("touchmove",b.moveHandler,C),g==null||g.addEventListener("touchend",b.upHandler,C)):(g==null||g.addEventListener("mousemove",_.moveHandler,C),g==null||g.addEventListener("mouseup",_.upHandler,C)),t.setColumnSizingInfo(k=>({...k,startOffset:l,startSize:i,deltaOffset:0,deltaPercentage:0,columnSizingStart:s,isResizingColumn:r.id}));}};},createTable:e=>{e.setColumnSizing=t=>e.options.onColumnSizingChange==null?void 0:e.options.onColumnSizingChange(t),e.setColumnSizingInfo=t=>e.options.onColumnSizingInfoChange==null?void 0:e.options.onColumnSizingInfoChange(t),e.resetColumnSizing=t=>{var n;e.setColumnSizing(t?{}:(n=e.initialState.columnSizing)!=null?n:{});},e.resetHeaderSizeInfo=t=>{var n;e.setColumnSizingInfo(t?eu():(n=e.initialState.columnSizingInfo)!=null?n:eu());},e.getTotalSize=()=>{var t,n;return (t=(n=e.getHeaderGroups()[0])==null?void 0:n.headers.reduce((r,o)=>r+o.getSize(),0))!=null?t:0},e.getLeftTotalSize=()=>{var t,n;return (t=(n=e.getLeftHeaderGroups()[0])==null?void 0:n.headers.reduce((r,o)=>r+o.getSize(),0))!=null?t:0},e.getCenterTotalSize=()=>{var t,n;return (t=(n=e.getCenterHeaderGroups()[0])==null?void 0:n.headers.reduce((r,o)=>r+o.getSize(),0))!=null?t:0},e.getRightTotalSize=()=>{var t,n;return (t=(n=e.getRightHeaderGroups()[0])==null?void 0:n.headers.reduce((r,o)=>r+o.getSize(),0))!=null?t:0};}};let Hs=null;function tC(){if(typeof Hs=="boolean")return Hs;let e=false;try{const t={get passive(){return e=!0,!1}},n=()=>{};window.addEventListener("test",n,t),window.removeEventListener("test",n);}catch{e=false;}return Hs=e,Hs}function tu(e){return e.type==="touchstart"}const nC={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:pr("columnVisibility",e)}),createColumn:(e,t)=>{e.toggleVisibility=n=>{e.getCanHide()&&t.setColumnVisibility(r=>({...r,[e.id]:n??!e.getIsVisible()}));},e.getIsVisible=()=>{var n,r;const o=e.columns;return (n=o.length?o.some(a=>a.getIsVisible()):(r=t.getState().columnVisibility)==null?void 0:r[e.id])!=null?n:true},e.getCanHide=()=>{var n,r;return ((n=e.columnDef.enableHiding)!=null?n:true)&&((r=t.options.enableHiding)!=null?r:true)},e.getToggleVisibilityHandler=()=>n=>{e.toggleVisibility==null||e.toggleVisibility(n.target.checked);};},createRow:(e,t)=>{e._getAllVisibleCells=Pt(()=>[e.getAllCells(),t.getState().columnVisibility],n=>n.filter(r=>r.column.getIsVisible()),Ot(t.options,"debugRows")),e.getVisibleCells=Pt(()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()],(n,r,o)=>[...n,...r,...o],Ot(t.options,"debugRows"));},createTable:e=>{const t=(n,r)=>Pt(()=>[r(),r().filter(o=>o.getIsVisible()).map(o=>o.id).join("_")],o=>o.filter(a=>a.getIsVisible==null?void 0:a.getIsVisible()),Ot(e.options,"debugColumns"));e.getVisibleFlatColumns=t("getVisibleFlatColumns",()=>e.getAllFlatColumns()),e.getVisibleLeafColumns=t("getVisibleLeafColumns",()=>e.getAllLeafColumns()),e.getLeftVisibleLeafColumns=t("getLeftVisibleLeafColumns",()=>e.getLeftLeafColumns()),e.getRightVisibleLeafColumns=t("getRightVisibleLeafColumns",()=>e.getRightLeafColumns()),e.getCenterVisibleLeafColumns=t("getCenterVisibleLeafColumns",()=>e.getCenterLeafColumns()),e.setColumnVisibility=n=>e.options.onColumnVisibilityChange==null?void 0:e.options.onColumnVisibilityChange(n),e.resetColumnVisibility=n=>{var r;e.setColumnVisibility(n?{}:(r=e.initialState.columnVisibility)!=null?r:{});},e.toggleAllColumnsVisible=n=>{var r;n=(r=n)!=null?r:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce((o,a)=>({...o,[a.id]:n||!(a.getCanHide!=null&&a.getCanHide())}),{}));},e.getIsAllColumnsVisible=()=>!e.getAllLeafColumns().some(n=>!(n.getIsVisible!=null&&n.getIsVisible())),e.getIsSomeColumnsVisible=()=>e.getAllLeafColumns().some(n=>n.getIsVisible==null?void 0:n.getIsVisible()),e.getToggleAllColumnsVisibilityHandler=()=>n=>{var r;e.toggleAllColumnsVisible((r=n.target)==null?void 0:r.checked);};}};function Hi(e,t){return t?t==="center"?e.getCenterVisibleLeafColumns():t==="left"?e.getLeftVisibleLeafColumns():e.getRightVisibleLeafColumns():e.getVisibleLeafColumns()}const rC={createTable:e=>{e._getGlobalFacetedRowModel=e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),e.getGlobalFacetedRowModel=()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),e._getGlobalFacetedUniqueValues=e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),e.getGlobalFacetedUniqueValues=()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,e._getGlobalFacetedMinMaxValues=e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),e.getGlobalFacetedMinMaxValues=()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()};}},oC={getInitialState:e=>({globalFilter:void 0,...e}),getDefaultOptions:e=>({onGlobalFilterChange:pr("globalFilter",e),globalFilterFn:"auto",getColumnCanGlobalFilter:t=>{var n;const r=(n=e.getCoreRowModel().flatRows[0])==null||(n=n._getAllCellsByColumnId()[t.id])==null?void 0:n.getValue();return typeof r=="string"||typeof r=="number"}}),createColumn:(e,t)=>{e.getCanGlobalFilter=()=>{var n,r,o,a;return ((n=e.columnDef.enableGlobalFilter)!=null?n:true)&&((r=t.options.enableGlobalFilter)!=null?r:true)&&((o=t.options.enableFilters)!=null?o:true)&&((a=t.options.getColumnCanGlobalFilter==null?void 0:t.options.getColumnCanGlobalFilter(e))!=null?a:true)&&!!e.accessorFn};},createTable:e=>{e.getGlobalAutoFilterFn=()=>oo.includesString,e.getGlobalFilterFn=()=>{var t,n;const{globalFilterFn:r}=e.options;return Ql(r)?r:r==="auto"?e.getGlobalAutoFilterFn():(t=(n=e.options.filterFns)==null?void 0:n[r])!=null?t:oo[r]},e.setGlobalFilter=t=>{e.options.onGlobalFilterChange==null||e.options.onGlobalFilterChange(t);},e.resetGlobalFilter=t=>{e.setGlobalFilter(t?void 0:e.initialState.globalFilter);};}},aC={getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:pr("expanded",e),paginateExpandedRows:true}),createTable:e=>{let t=false,n=false;e._autoResetExpanded=()=>{var r,o;if(!t){e._queue(()=>{t=true;});return}if((r=(o=e.options.autoResetAll)!=null?o:e.options.autoResetExpanded)!=null?r:!e.options.manualExpanding){if(n)return;n=true,e._queue(()=>{e.resetExpanded(),n=false;});}},e.setExpanded=r=>e.options.onExpandedChange==null?void 0:e.options.onExpandedChange(r),e.toggleAllRowsExpanded=r=>{r??!e.getIsAllRowsExpanded()?e.setExpanded(true):e.setExpanded({});},e.resetExpanded=r=>{var o,a;e.setExpanded(r?{}:(o=(a=e.initialState)==null?void 0:a.expanded)!=null?o:{});},e.getCanSomeRowsExpand=()=>e.getPrePaginationRowModel().flatRows.some(r=>r.getCanExpand()),e.getToggleAllRowsExpandedHandler=()=>r=>{r.persist==null||r.persist(),e.toggleAllRowsExpanded();},e.getIsSomeRowsExpanded=()=>{const r=e.getState().expanded;return r===true||Object.values(r).some(Boolean)},e.getIsAllRowsExpanded=()=>{const r=e.getState().expanded;return typeof r=="boolean"?r===true:!(!Object.keys(r).length||e.getRowModel().flatRows.some(o=>!o.getIsExpanded()))},e.getExpandedDepth=()=>{let r=0;return (e.getState().expanded===true?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach(a=>{const i=a.split(".");r=Math.max(r,i.length);}),r},e.getPreExpandedRowModel=()=>e.getSortedRowModel(),e.getExpandedRowModel=()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel());},createRow:(e,t)=>{e.toggleExpanded=n=>{t.setExpanded(r=>{var o;const a=r===true?true:!!(r!=null&&r[e.id]);let i={};if(r===true?Object.keys(t.getRowModel().rowsById).forEach(s=>{i[s]=true;}):i=r,n=(o=n)!=null?o:!a,!a&&n)return {...i,[e.id]:true};if(a&&!n){const{[e.id]:s,...l}=i;return l}return r});},e.getIsExpanded=()=>{var n;const r=t.getState().expanded;return !!((n=t.options.getIsRowExpanded==null?void 0:t.options.getIsRowExpanded(e))!=null?n:r===true||r!=null&&r[e.id])},e.getCanExpand=()=>{var n,r,o;return (n=t.options.getRowCanExpand==null?void 0:t.options.getRowCanExpand(e))!=null?n:((r=t.options.enableExpanding)!=null?r:true)&&!!((o=e.subRows)!=null&&o.length)},e.getIsAllParentsExpanded=()=>{let n=true,r=e;for(;n&&r.parentId;)r=t.getRow(r.parentId,true),n=r.getIsExpanded();return n},e.getToggleExpandedHandler=()=>{const n=e.getCanExpand();return ()=>{n&&e.toggleExpanded();}};}},Xu=0,Zu=10,nu=()=>({pageIndex:Xu,pageSize:Zu}),iC={getInitialState:e=>({...e,pagination:{...nu(),...e==null?void 0:e.pagination}}),getDefaultOptions:e=>({onPaginationChange:pr("pagination",e)}),createTable:e=>{let t=false,n=false;e._autoResetPageIndex=()=>{var r,o;if(!t){e._queue(()=>{t=true;});return}if((r=(o=e.options.autoResetAll)!=null?o:e.options.autoResetPageIndex)!=null?r:!e.options.manualPagination){if(n)return;n=true,e._queue(()=>{e.resetPageIndex(),n=false;});}},e.setPagination=r=>{const o=a=>lo(r,a);return e.options.onPaginationChange==null?void 0:e.options.onPaginationChange(o)},e.resetPagination=r=>{var o;e.setPagination(r?nu():(o=e.initialState.pagination)!=null?o:nu());},e.setPageIndex=r=>{e.setPagination(o=>{let a=lo(r,o.pageIndex);const i=typeof e.options.pageCount>"u"||e.options.pageCount===-1?Number.MAX_SAFE_INTEGER:e.options.pageCount-1;return a=Math.max(0,Math.min(a,i)),{...o,pageIndex:a}});},e.resetPageIndex=r=>{var o,a;e.setPageIndex(r?Xu:(o=(a=e.initialState)==null||(a=a.pagination)==null?void 0:a.pageIndex)!=null?o:Xu);},e.resetPageSize=r=>{var o,a;e.setPageSize(r?Zu:(o=(a=e.initialState)==null||(a=a.pagination)==null?void 0:a.pageSize)!=null?o:Zu);},e.setPageSize=r=>{e.setPagination(o=>{const a=Math.max(1,lo(r,o.pageSize)),i=o.pageSize*o.pageIndex,s=Math.floor(i/a);return {...o,pageIndex:s,pageSize:a}});},e.setPageCount=r=>e.setPagination(o=>{var a;let i=lo(r,(a=e.options.pageCount)!=null?a:-1);return typeof i=="number"&&(i=Math.max(-1,i)),{...o,pageCount:i}}),e.getPageOptions=Pt(()=>[e.getPageCount()],r=>{let o=[];return r&&r>0&&(o=[...new Array(r)].fill(null).map((a,i)=>i)),o},Ot(e.options,"debugTable")),e.getCanPreviousPage=()=>e.getState().pagination.pageIndex>0,e.getCanNextPage=()=>{const{pageIndex:r}=e.getState().pagination,o=e.getPageCount();return o===-1?true:o===0?false:r<o-1},e.previousPage=()=>e.setPageIndex(r=>r-1),e.nextPage=()=>e.setPageIndex(r=>r+1),e.firstPage=()=>e.setPageIndex(0),e.lastPage=()=>e.setPageIndex(e.getPageCount()-1),e.getPrePaginationRowModel=()=>e.getExpandedRowModel(),e.getPaginationRowModel=()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),e.getPageCount=()=>{var r;return (r=e.options.pageCount)!=null?r:Math.ceil(e.getRowCount()/e.getState().pagination.pageSize)},e.getRowCount=()=>{var r;return (r=e.options.rowCount)!=null?r:e.getPrePaginationRowModel().rows.length};}},ru=()=>({top:[],bottom:[]}),sC={getInitialState:e=>({rowPinning:ru(),...e}),getDefaultOptions:e=>({onRowPinningChange:pr("rowPinning",e)}),createRow:(e,t)=>{e.pin=(n,r,o)=>{const a=r?e.getLeafRows().map(l=>{let{id:c}=l;return c}):[],i=o?e.getParentRows().map(l=>{let{id:c}=l;return c}):[],s=new Set([...i,e.id,...a]);t.setRowPinning(l=>{var c,h;if(n==="bottom"){var f,m;return {top:((f=l==null?void 0:l.top)!=null?f:[]).filter(b=>!(s!=null&&s.has(b))),bottom:[...((m=l==null?void 0:l.bottom)!=null?m:[]).filter(b=>!(s!=null&&s.has(b))),...Array.from(s)]}}if(n==="top"){var g,_;return {top:[...((g=l==null?void 0:l.top)!=null?g:[]).filter(b=>!(s!=null&&s.has(b))),...Array.from(s)],bottom:((_=l==null?void 0:l.bottom)!=null?_:[]).filter(b=>!(s!=null&&s.has(b)))}}return {top:((c=l==null?void 0:l.top)!=null?c:[]).filter(b=>!(s!=null&&s.has(b))),bottom:((h=l==null?void 0:l.bottom)!=null?h:[]).filter(b=>!(s!=null&&s.has(b)))}});},e.getCanPin=()=>{var n;const{enableRowPinning:r,enablePinning:o}=t.options;return typeof r=="function"?r(e):(n=r??o)!=null?n:true},e.getIsPinned=()=>{const n=[e.id],{top:r,bottom:o}=t.getState().rowPinning,a=n.some(s=>r==null?void 0:r.includes(s)),i=n.some(s=>o==null?void 0:o.includes(s));return a?"top":i?"bottom":false},e.getPinnedIndex=()=>{var n,r;const o=e.getIsPinned();if(!o)return  -1;const a=(n=o==="top"?t.getTopRows():t.getBottomRows())==null?void 0:n.map(i=>{let{id:s}=i;return s});return (r=a==null?void 0:a.indexOf(e.id))!=null?r:-1};},createTable:e=>{e.setRowPinning=t=>e.options.onRowPinningChange==null?void 0:e.options.onRowPinningChange(t),e.resetRowPinning=t=>{var n,r;return e.setRowPinning(t?ru():(n=(r=e.initialState)==null?void 0:r.rowPinning)!=null?n:ru())},e.getIsSomeRowsPinned=t=>{var n;const r=e.getState().rowPinning;if(!t){var o,a;return !!((o=r.top)!=null&&o.length||(a=r.bottom)!=null&&a.length)}return !!((n=r[t])!=null&&n.length)},e._getPinnedRows=(t,n,r)=>{var o;return ((o=e.options.keepPinnedRows)==null||o?(n??[]).map(i=>{const s=e.getRow(i,true);return s.getIsAllParentsExpanded()?s:null}):(n??[]).map(i=>t.find(s=>s.id===i))).filter(Boolean).map(i=>({...i,position:r}))},e.getTopRows=Pt(()=>[e.getRowModel().rows,e.getState().rowPinning.top],(t,n)=>e._getPinnedRows(t,n,"top"),Ot(e.options,"debugRows")),e.getBottomRows=Pt(()=>[e.getRowModel().rows,e.getState().rowPinning.bottom],(t,n)=>e._getPinnedRows(t,n,"bottom"),Ot(e.options,"debugRows")),e.getCenterRows=Pt(()=>[e.getRowModel().rows,e.getState().rowPinning.top,e.getState().rowPinning.bottom],(t,n,r)=>{const o=new Set([...n??[],...r??[]]);return t.filter(a=>!o.has(a.id))},Ot(e.options,"debugRows"));}},lC={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:pr("rowSelection",e),enableRowSelection:true,enableMultiRowSelection:true,enableSubRowSelection:true}),createTable:e=>{e.setRowSelection=t=>e.options.onRowSelectionChange==null?void 0:e.options.onRowSelectionChange(t),e.resetRowSelection=t=>{var n;return e.setRowSelection(t?{}:(n=e.initialState.rowSelection)!=null?n:{})},e.toggleAllRowsSelected=t=>{e.setRowSelection(n=>{t=typeof t<"u"?t:!e.getIsAllRowsSelected();const r={...n},o=e.getPreGroupedRowModel().flatRows;return t?o.forEach(a=>{a.getCanSelect()&&(r[a.id]=true);}):o.forEach(a=>{delete r[a.id];}),r});},e.toggleAllPageRowsSelected=t=>e.setRowSelection(n=>{const r=typeof t<"u"?t:!e.getIsAllPageRowsSelected(),o={...n};return e.getRowModel().rows.forEach(a=>{Qu(o,a.id,r,true,e);}),o}),e.getPreSelectedRowModel=()=>e.getCoreRowModel(),e.getSelectedRowModel=Pt(()=>[e.getState().rowSelection,e.getCoreRowModel()],(t,n)=>Object.keys(t).length?ou(e,n):{rows:[],flatRows:[],rowsById:{}},Ot(e.options,"debugTable")),e.getFilteredSelectedRowModel=Pt(()=>[e.getState().rowSelection,e.getFilteredRowModel()],(t,n)=>Object.keys(t).length?ou(e,n):{rows:[],flatRows:[],rowsById:{}},Ot(e.options,"debugTable")),e.getGroupedSelectedRowModel=Pt(()=>[e.getState().rowSelection,e.getSortedRowModel()],(t,n)=>Object.keys(t).length?ou(e,n):{rows:[],flatRows:[],rowsById:{}},Ot(e.options,"debugTable")),e.getIsAllRowsSelected=()=>{const t=e.getFilteredRowModel().flatRows,{rowSelection:n}=e.getState();let r=!!(t.length&&Object.keys(n).length);return r&&t.some(o=>o.getCanSelect()&&!n[o.id])&&(r=false),r},e.getIsAllPageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows.filter(o=>o.getCanSelect()),{rowSelection:n}=e.getState();let r=!!t.length;return r&&t.some(o=>!n[o.id])&&(r=false),r},e.getIsSomeRowsSelected=()=>{var t;const n=Object.keys((t=e.getState().rowSelection)!=null?t:{}).length;return n>0&&n<e.getFilteredRowModel().flatRows.length},e.getIsSomePageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows;return e.getIsAllPageRowsSelected()?false:t.filter(n=>n.getCanSelect()).some(n=>n.getIsSelected()||n.getIsSomeSelected())},e.getToggleAllRowsSelectedHandler=()=>t=>{e.toggleAllRowsSelected(t.target.checked);},e.getToggleAllPageRowsSelectedHandler=()=>t=>{e.toggleAllPageRowsSelected(t.target.checked);};},createRow:(e,t)=>{e.toggleSelected=(n,r)=>{const o=e.getIsSelected();t.setRowSelection(a=>{var i;if(n=typeof n<"u"?n:!o,e.getCanSelect()&&o===n)return a;const s={...a};return Qu(s,e.id,n,(i=r==null?void 0:r.selectChildren)!=null?i:true,t),s});},e.getIsSelected=()=>{const{rowSelection:n}=t.getState();return Vd(e,n)},e.getIsSomeSelected=()=>{const{rowSelection:n}=t.getState();return Ju(e,n)==="some"},e.getIsAllSubRowsSelected=()=>{const{rowSelection:n}=t.getState();return Ju(e,n)==="all"},e.getCanSelect=()=>{var n;return typeof t.options.enableRowSelection=="function"?t.options.enableRowSelection(e):(n=t.options.enableRowSelection)!=null?n:true},e.getCanSelectSubRows=()=>{var n;return typeof t.options.enableSubRowSelection=="function"?t.options.enableSubRowSelection(e):(n=t.options.enableSubRowSelection)!=null?n:true},e.getCanMultiSelect=()=>{var n;return typeof t.options.enableMultiRowSelection=="function"?t.options.enableMultiRowSelection(e):(n=t.options.enableMultiRowSelection)!=null?n:true},e.getToggleSelectedHandler=()=>{const n=e.getCanSelect();return r=>{var o;n&&e.toggleSelected((o=r.target)==null?void 0:o.checked);}};}},Qu=(e,t,n,r,o)=>{var a;const i=o.getRow(t,true);n?(i.getCanMultiSelect()||Object.keys(e).forEach(s=>delete e[s]),i.getCanSelect()&&(e[t]=true)):delete e[t],r&&(a=i.subRows)!=null&&a.length&&i.getCanSelectSubRows()&&i.subRows.forEach(s=>Qu(e,s.id,n,r,o));};function ou(e,t){const n=e.getState().rowSelection,r=[],o={},a=function(i,s){return i.map(l=>{var c;const h=Vd(l,n);if(h&&(r.push(l),o[l.id]=l),(c=l.subRows)!=null&&c.length&&(l={...l,subRows:a(l.subRows)}),h)return l}).filter(Boolean)};return {rows:a(t.rows),flatRows:r,rowsById:o}}function Vd(e,t){var n;return (n=t[e.id])!=null?n:false}function Ju(e,t,n){var r;if(!((r=e.subRows)!=null&&r.length))return  false;let o=true,a=false;return e.subRows.forEach(i=>{if(!(a&&!o)&&(i.getCanSelect()&&(Vd(i,t)?a=true:o=false),i.subRows&&i.subRows.length)){const s=Ju(i,t);s==="all"?a=true:(s==="some"&&(a=true),o=false);}}),o?"all":a?"some":false}const ed=/([0-9]+)/gm,cC=(e,t,n)=>o_(qo(e.getValue(n)).toLowerCase(),qo(t.getValue(n)).toLowerCase()),uC=(e,t,n)=>o_(qo(e.getValue(n)),qo(t.getValue(n))),dC=(e,t,n)=>zd(qo(e.getValue(n)).toLowerCase(),qo(t.getValue(n)).toLowerCase()),fC=(e,t,n)=>zd(qo(e.getValue(n)),qo(t.getValue(n))),hC=(e,t,n)=>{const r=e.getValue(n),o=t.getValue(n);return r>o?1:r<o?-1:0},pC=(e,t,n)=>zd(e.getValue(n),t.getValue(n));function zd(e,t){return e===t?0:e>t?1:-1}function qo(e){return typeof e=="number"?isNaN(e)||e===1/0||e===-1/0?"":String(e):typeof e=="string"?e:""}function o_(e,t){const n=e.split(ed).filter(Boolean),r=t.split(ed).filter(Boolean);for(;n.length&&r.length;){const o=n.shift(),a=r.shift(),i=parseInt(o,10),s=parseInt(a,10),l=[i,s].sort();if(isNaN(l[0])){if(o>a)return 1;if(a>o)return  -1;continue}if(isNaN(l[1]))return isNaN(i)?-1:1;if(i>s)return 1;if(s>i)return  -1}return n.length-r.length}const xi={alphanumeric:cC,alphanumericCaseSensitive:uC,text:dC,textCaseSensitive:fC,datetime:hC,basic:pC},mC={getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto",sortUndefined:1}),getDefaultOptions:e=>({onSortingChange:pr("sorting",e),isMultiSortEvent:t=>t.shiftKey}),createColumn:(e,t)=>{e.getAutoSortingFn=()=>{const n=t.getFilteredRowModel().flatRows.slice(10);let r=false;for(const o of n){const a=o==null?void 0:o.getValue(e.id);if(Object.prototype.toString.call(a)==="[object Date]")return xi.datetime;if(typeof a=="string"&&(r=true,a.split(ed).length>1))return xi.alphanumeric}return r?xi.text:xi.basic},e.getAutoSortDir=()=>{const n=t.getFilteredRowModel().flatRows[0];return typeof(n==null?void 0:n.getValue(e.id))=="string"?"asc":"desc"},e.getSortingFn=()=>{var n,r;if(!e)throw new Error;return Ql(e.columnDef.sortingFn)?e.columnDef.sortingFn:e.columnDef.sortingFn==="auto"?e.getAutoSortingFn():(n=(r=t.options.sortingFns)==null?void 0:r[e.columnDef.sortingFn])!=null?n:xi[e.columnDef.sortingFn]},e.toggleSorting=(n,r)=>{const o=e.getNextSortingOrder(),a=typeof n<"u"&&n!==null;t.setSorting(i=>{const s=i==null?void 0:i.find(g=>g.id===e.id),l=i==null?void 0:i.findIndex(g=>g.id===e.id);let c=[],h,f=a?n:o==="desc";if(i!=null&&i.length&&e.getCanMultiSort()&&r?s?h="toggle":h="add":i!=null&&i.length&&l!==i.length-1?h="replace":s?h="toggle":h="replace",h==="toggle"&&(a||o||(h="remove")),h==="add"){var m;c=[...i,{id:e.id,desc:f}],c.splice(0,c.length-((m=t.options.maxMultiSortColCount)!=null?m:Number.MAX_SAFE_INTEGER));}else h==="toggle"?c=i.map(g=>g.id===e.id?{...g,desc:f}:g):h==="remove"?c=i.filter(g=>g.id!==e.id):c=[{id:e.id,desc:f}];return c});},e.getFirstSortDir=()=>{var n,r;return ((n=(r=e.columnDef.sortDescFirst)!=null?r:t.options.sortDescFirst)!=null?n:e.getAutoSortDir()==="desc")?"desc":"asc"},e.getNextSortingOrder=n=>{var r,o;const a=e.getFirstSortDir(),i=e.getIsSorted();return i?i!==a&&((r=t.options.enableSortingRemoval)==null||r)&&(!(n&&(o=t.options.enableMultiRemove)!=null)||o)?false:i==="desc"?"asc":"desc":a},e.getCanSort=()=>{var n,r;return ((n=e.columnDef.enableSorting)!=null?n:true)&&((r=t.options.enableSorting)!=null?r:true)&&!!e.accessorFn},e.getCanMultiSort=()=>{var n,r;return (n=(r=e.columnDef.enableMultiSort)!=null?r:t.options.enableMultiSort)!=null?n:!!e.accessorFn},e.getIsSorted=()=>{var n;const r=(n=t.getState().sorting)==null?void 0:n.find(o=>o.id===e.id);return r?r.desc?"desc":"asc":false},e.getSortIndex=()=>{var n,r;return (n=(r=t.getState().sorting)==null?void 0:r.findIndex(o=>o.id===e.id))!=null?n:-1},e.clearSorting=()=>{t.setSorting(n=>n!=null&&n.length?n.filter(r=>r.id!==e.id):[]);},e.getToggleSortingHandler=()=>{const n=e.getCanSort();return r=>{n&&(r.persist==null||r.persist(),e.toggleSorting==null||e.toggleSorting(void 0,e.getCanMultiSort()?t.options.isMultiSortEvent==null?void 0:t.options.isMultiSortEvent(r):false));}};},createTable:e=>{e.setSorting=t=>e.options.onSortingChange==null?void 0:e.options.onSortingChange(t),e.resetSorting=t=>{var n,r;e.setSorting(t?[]:(n=(r=e.initialState)==null?void 0:r.sorting)!=null?n:[]);},e.getPreSortedRowModel=()=>e.getGroupedRowModel(),e.getSortedRowModel=()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel());}},gC=[N1,nC,Q1,J1,U1,$1,rC,oC,mC,X1,aC,iC,sC,lC,eC];function yC(e){var t,n;const r=[...gC,...(t=e._features)!=null?t:[]];let o={_features:r};const a=o._features.reduce((m,g)=>Object.assign(m,g.getDefaultOptions==null?void 0:g.getDefaultOptions(o)),{}),i=m=>o.options.mergeOptions?o.options.mergeOptions(a,m):{...a,...m};let l={...{},...(n=e.initialState)!=null?n:{}};o._features.forEach(m=>{var g;l=(g=m.getInitialState==null?void 0:m.getInitialState(l))!=null?g:l;});const c=[];let h=false;const f={_features:r,options:{...a,...e},initialState:l,_queue:m=>{c.push(m),h||(h=true,Promise.resolve().then(()=>{for(;c.length;)c.shift()();h=false;}).catch(g=>setTimeout(()=>{throw g})));},reset:()=>{o.setState(o.initialState);},setOptions:m=>{const g=lo(m,o.options);o.options=i(g);},getState:()=>o.options.state,setState:m=>{o.options.onStateChange==null||o.options.onStateChange(m);},_getRowId:(m,g,_)=>{var b;return (b=o.options.getRowId==null?void 0:o.options.getRowId(m,g,_))!=null?b:`${_?[_.id,g].join("."):g}`},getCoreRowModel:()=>(o._getCoreRowModel||(o._getCoreRowModel=o.options.getCoreRowModel(o)),o._getCoreRowModel()),getRowModel:()=>o.getPaginationRowModel(),getRow:(m,g)=>{let _=(g?o.getPrePaginationRowModel():o.getRowModel()).rowsById[m];if(!_&&(_=o.getCoreRowModel().rowsById[m],!_))throw new Error;return _},_getDefaultColumnDef:Pt(()=>[o.options.defaultColumn],m=>{var g;return m=(g=m)!=null?g:{},{header:_=>{const b=_.header.column.columnDef;return b.accessorKey?b.accessorKey:b.accessorFn?b.id:null},cell:_=>{var b,C;return (b=(C=_.renderValue())==null||C.toString==null?void 0:C.toString())!=null?b:null},...o._features.reduce((_,b)=>Object.assign(_,b.getDefaultColumnDef==null?void 0:b.getDefaultColumnDef()),{}),...m}},Ot(e,"debugColumns")),_getColumnDefs:()=>o.options.columns,getAllColumns:Pt(()=>[o._getColumnDefs()],m=>{const g=function(_,b,C){return C===void 0&&(C=0),_.map(k=>{const T=L1(o,k,C,b),M=k;return T.columns=M.columns?g(M.columns,T,C+1):[],T})};return g(m)},Ot(e,"debugColumns")),getAllFlatColumns:Pt(()=>[o.getAllColumns()],m=>m.flatMap(g=>g.getFlatColumns()),Ot(e,"debugColumns")),_getAllFlatColumnsById:Pt(()=>[o.getAllFlatColumns()],m=>m.reduce((g,_)=>(g[_.id]=_,g),{}),Ot(e,"debugColumns")),getAllLeafColumns:Pt(()=>[o.getAllColumns(),o._getOrderColumnsFn()],(m,g)=>{let _=m.flatMap(b=>b.getLeafColumns());return g(_)},Ot(e,"debugColumns")),getColumn:m=>o._getAllFlatColumnsById()[m]};Object.assign(o,f);for(let m=0;m<o._features.length;m++){const g=o._features[m];g==null||g.createTable==null||g.createTable(o);}return o}function _C(){return e=>Pt(()=>[e.options.data],t=>{const n={rows:[],flatRows:[],rowsById:{}},r=function(o,a,i){a===void 0&&(a=0);const s=[];for(let c=0;c<o.length;c++){const h=B1(e,e._getRowId(o[c],c,i),o[c],c,a,void 0,i==null?void 0:i.id);if(n.flatRows.push(h),n.rowsById[h.id]=h,s.push(h),e.options.getSubRows){var l;h.originalSubRows=e.options.getSubRows(o[c],c),(l=h.originalSubRows)!=null&&l.length&&(h.subRows=r(h.originalSubRows,a+1,h));}}return s};return n.rows=r(t),n},Ot(e.options,"debugTable","getRowModel",()=>e._autoResetPageIndex()))}function hp(e,t){return e?wC(e)?d(e,{...t}):e:null}function wC(e){return typeof e=="function"}/**
   * @license MIT
   * https://github.com/TanStack/table/blob/main/packages/react-table/src/index.tsx
   */function bC(e){const t={state:{},onStateChange:()=>{},renderFallbackValue:null,...e},[n]=De(()=>({current:yC(t)})),[r,o]=De(()=>n.current.initialState);return n.current.setOptions(a=>({...a,...e,state:{...r,...e.state},onStateChange:i=>{var s;o(i),(s=e.onStateChange)==null||s.call(e,i);}})),n.current}const a_='(function(){"use strict";var Ne={version:"1.3.0"};const Oe=4294967296;function pe(r){let e=2166136261;for(let n=0;n<r.length;n+=1)e^=r.charCodeAt(n),e=Math.imul(e,16777619)>>>0;return e.toString(16).padStart(8,"0")}async function q(r){var t;const e=typeof r=="string"?new TextEncoder().encode(r):r;if((t=globalThis.crypto)!=null&&t.subtle){const a=e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength),i=await globalThis.crypto.subtle.digest("SHA-256",a);return[...new Uint8Array(i)].map(o=>o.toString(16).padStart(2,"0")).join("")}let n="";for(let a=0;a<e.length;a+=4096)n+=pe(String.fromCharCode(...e.slice(a,a+4096)));return pe(`${e.length}:${n}:${Oe}`)}async function Ue(r){return`bundle_${(await q(r)).slice(0,24)}`}async function De(r,e,n){return`record_${(await q(`${r}:${e}:${n}`)).slice(0,32)}`}const Je={includeViewerAccountId:!1,includeSourceCaptureTimes:!1,includeRawGraphQL:!1,includePrivateNotes:!1,includeMediaBlobs:!1,visibility:"shared_safe"};function je(r){return{visibility:r.visibility,includesViewerAccountId:r.includeViewerAccountId,includesSourceCaptureTimes:r.includeSourceCaptureTimes,includesRawGraphQL:r.includeRawGraphQL,includesPrivateNotes:r.includePrivateNotes,includesMediaBlobs:r.includeMediaBlobs,warnings:He(r)}}function He(r){const e=[];return r.includeViewerAccountId&&e.push("Includes the exporting account identifier."),r.includeSourceCaptureTimes&&e.push("Includes local capture/import timestamps."),r.includeRawGraphQL&&e.push("Includes raw API payloads that may contain unrelated account context."),r.includePrivateNotes&&e.push("Includes user-authored local notes or labels."),r.includeMediaBlobs&&e.push("Includes downloaded media files, increasing size and redistribution risk."),r.visibility==="public"&&e.length&&e.unshift("Public bundle includes fields that should be reviewed before sharing."),e}var S=Uint8Array,R=Uint16Array,ae=Int32Array,ie=new S([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),oe=new S([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),me=new S([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),xe=function(r,e){for(var n=new R(31),t=0;t<31;++t)n[t]=e+=1<<r[t-1];for(var a=new ae(n[30]),t=1;t<30;++t)for(var i=n[t];i<n[t+1];++i)a[i]=i-n[t]<<5|t;return{b:n,r:a}},be=xe(ie,2),Ve=be.b,le=be.r;Ve[28]=258,le[258]=28;for(var Ze=xe(oe,0),Ae=Ze.r,se=new R(32768),y=0;y<32768;++y){var D=(y&43690)>>1|(y&21845)<<1;D=(D&52428)>>2|(D&13107)<<2,D=(D&61680)>>4|(D&3855)<<4,se[y]=((D&65280)>>8|(D&255)<<8)>>1}for(var Q=(function(r,e,n){for(var t=r.length,a=0,i=new R(e);a<t;++a)r[a]&&++i[r[a]-1];var o=new R(e);for(a=1;a<e;++a)o[a]=o[a-1]+i[a-1]<<1;var s;if(n){s=new R(1<<e);var f=15-e;for(a=0;a<t;++a)if(r[a])for(var u=a<<4|r[a],l=e-r[a],c=o[r[a]-1]++<<l,w=c|(1<<l)-1;c<=w;++c)s[se[c]>>f]=u}else for(s=new R(t),a=0;a<t;++a)r[a]&&(s[a]=se[o[r[a]-1]++]>>15-r[a]);return s}),j=new S(288),y=0;y<144;++y)j[y]=8;for(var y=144;y<256;++y)j[y]=9;for(var y=256;y<280;++y)j[y]=7;for(var y=280;y<288;++y)j[y]=8;for(var ee=new S(32),y=0;y<32;++y)ee[y]=5;var Ge=Q(j,9,0),Qe=Q(ee,5,0),Ie=function(r){return(r+7)/8|0},Me=function(r,e,n){return(n==null||n>r.length)&&(n=r.length),new S(r.subarray(e,n))},Ke=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],re=function(r,e,n){var t=new Error(e||Ke[r]);if(t.code=r,Error.captureStackTrace&&Error.captureStackTrace(t,re),!n)throw t;return t},U=function(r,e,n){n<<=e&7;var t=e/8|0;r[t]|=n,r[t+1]|=n>>8},K=function(r,e,n){n<<=e&7;var t=e/8|0;r[t]|=n,r[t+1]|=n>>8,r[t+2]|=n>>16},fe=function(r,e){for(var n=[],t=0;t<r.length;++t)r[t]&&n.push({s:t,f:r[t]});var a=n.length,i=n.slice();if(!a)return{t:Te,l:0};if(a==1){var o=new S(n[0].s+1);return o[n[0].s]=1,{t:o,l:1}}n.sort(function(x,b){return x.f-b.f}),n.push({s:-1,f:25001});var s=n[0],f=n[1],u=0,l=1,c=2;for(n[0]={s:-1,f:s.f+f.f,l:s,r:f};l!=a-1;)s=n[n[u].f<n[c].f?u++:c++],f=n[u!=l&&n[u].f<n[c].f?u++:c++],n[l++]={s:-1,f:s.f+f.f,l:s,r:f};for(var w=i[0].s,t=1;t<a;++t)i[t].s>w&&(w=i[t].s);var h=new R(w+1),p=ce(n[l-1],h,0);if(p>e){var t=0,g=0,M=p-e,C=1<<M;for(i.sort(function(b,A){return h[A.s]-h[b.s]||b.f-A.f});t<a;++t){var T=i[t].s;if(h[T]>e)g+=C-(1<<p-h[T]),h[T]=e;else break}for(g>>=M;g>0;){var E=i[t].s;h[E]<e?g-=1<<e-h[E]++-1:++t}for(;t>=0&&g;--t){var m=i[t].s;h[m]==e&&(--h[m],++g)}p=e}return{t:new S(h),l:p}},ce=function(r,e,n){return r.s==-1?Math.max(ce(r.l,e,n+1),ce(r.r,e,n+1)):e[r.s]=n},_e=function(r){for(var e=r.length;e&&!r[--e];);for(var n=new R(++e),t=0,a=r[0],i=1,o=function(f){n[t++]=f},s=1;s<=e;++s)if(r[s]==a&&s!=e)++i;else{if(!a&&i>2){for(;i>138;i-=138)o(32754);i>2&&(o(i>10?i-11<<5|28690:i-3<<5|12305),i=0)}else if(i>3){for(o(a),--i;i>6;i-=6)o(8304);i>2&&(o(i-3<<5|8208),i=0)}for(;i--;)o(a);i=1,a=r[s]}return{c:n.subarray(0,t),n:e}},W=function(r,e){for(var n=0,t=0;t<e.length;++t)n+=r[t]*e[t];return n},Se=function(r,e,n){var t=n.length,a=Ie(e+2);r[a]=t&255,r[a+1]=t>>8,r[a+2]=r[a]^255,r[a+3]=r[a+1]^255;for(var i=0;i<t;++i)r[a+i+4]=n[i];return(a+4+t)*8},ke=function(r,e,n,t,a,i,o,s,f,u,l){U(e,l++,n),++a[256];for(var c=fe(a,15),w=c.t,h=c.l,p=fe(i,15),g=p.t,M=p.l,C=_e(w),T=C.c,E=C.n,m=_e(g),x=m.c,b=m.n,A=new R(19),d=0;d<T.length;++d)++A[T[d]&31];for(var d=0;d<x.length;++d)++A[x[d]&31];for(var v=fe(A,7),B=v.t,H=v.l,F=19;F>4&&!B[me[F-1]];--F);var V=u+5<<3,$=W(a,j)+W(i,ee)+o,L=W(a,w)+W(i,g)+o+14+3*F+W(A,B)+2*A[16]+3*A[17]+7*A[18];if(f>=0&&V<=$&&V<=L)return Se(e,l,r.subarray(f,f+u));var z,_,P,J;if(U(e,l,1+(L<$)),l+=2,L<$){z=Q(w,h,0),_=w,P=Q(g,M,0),J=g;var he=Q(B,H,0);U(e,l,E-257),U(e,l+5,b-1),U(e,l+10,F-4),l+=14;for(var d=0;d<F;++d)U(e,l+3*d,B[me[d]]);l+=3*F;for(var N=[T,x],X=0;X<2;++X)for(var Z=N[X],d=0;d<Z.length;++d){var O=Z[d]&31;U(e,l,he[O]),l+=B[O],O>15&&(U(e,l,Z[d]>>5&127),l+=Z[d]>>12)}}else z=Ge,_=j,P=Qe,J=ee;for(var d=0;d<s;++d){var k=t[d];if(k>255){var O=k>>18&31;K(e,l,z[O+257]),l+=_[O+257],O>7&&(U(e,l,k>>23&31),l+=ie[O]);var G=k&31;K(e,l,P[G]),l+=J[G],G>3&&(K(e,l,k>>5&8191),l+=oe[G])}else K(e,l,z[k]),l+=_[k]}return K(e,l,z[256]),l+_[256]},We=new ae([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),Te=new S(0),Ye=function(r,e,n,t,a,i){var o=i.z||r.length,s=new S(t+o+5*(1+Math.ceil(o/7e3))+a),f=s.subarray(t,s.length-a),u=i.l,l=(i.r||0)&7;if(e){l&&(f[0]=i.r>>3);for(var c=We[e-1],w=c>>13,h=c&8191,p=(1<<n)-1,g=i.p||new R(32768),M=i.h||new R(p+1),C=Math.ceil(n/3),T=2*C,E=function(ye){return(r[ye]^r[ye+1]<<C^r[ye+2]<<T)&p},m=new ae(25e3),x=new R(288),b=new R(32),A=0,d=0,v=i.i||0,B=0,H=i.w||0,F=0;v+2<o;++v){var V=E(v),$=v&32767,L=M[V];if(g[$]=L,M[V]=$,H<=v){var z=o-v;if((A>7e3||B>24576)&&(z>423||!u)){l=ke(r,f,0,m,x,b,d,B,F,v-F,l),B=A=d=0,F=v;for(var _=0;_<286;++_)x[_]=0;for(var _=0;_<30;++_)b[_]=0}var P=2,J=0,he=h,N=$-L&32767;if(z>2&&V==E(v-N))for(var X=Math.min(w,z)-1,Z=Math.min(32767,v),O=Math.min(258,z);N<=Z&&--he&&$!=L;){if(r[v+P]==r[v+P-N]){for(var k=0;k<O&&r[v+k]==r[v+k-N];++k);if(k>P){if(P=k,J=N,k>X)break;for(var G=Math.min(N,k-2),$e=0,_=0;_<G;++_){var we=v-N+_&32767,mr=g[we],Le=we-mr&32767;Le>$e&&($e=Le,L=we)}}}$=L,L=g[$],N+=$-L&32767}if(J){m[B++]=268435456|le[P]<<18|Ae[J];var Pe=le[P]&31,ze=Ae[J]&31;d+=ie[Pe]+oe[ze],++x[257+Pe],++b[ze],H=v+P,++A}else m[B++]=r[v],++x[r[v]]}}for(v=Math.max(v,H);v<o;++v)m[B++]=r[v],++x[r[v]];l=ke(r,f,u,m,x,b,d,B,F,v-F,l),u||(i.r=l&7|f[l/8|0]<<3,l-=7,i.h=M,i.p=g,i.i=v,i.w=H)}else{for(var v=i.w||0;v<o+u;v+=65535){var ge=v+65535;ge>=o&&(f[l/8|0]=u,ge=o),l=Se(f,l+1,r.subarray(v,ge))}i.i=o}return Me(s,0,t+Ie(l)+a)},Xe=(function(){for(var r=new Int32Array(256),e=0;e<256;++e){for(var n=e,t=9;--t;)n=(n&1&&-306674912)^n>>>1;r[e]=n}return r})(),qe=function(){var r=-1;return{p:function(e){for(var n=r,t=0;t<e.length;++t)n=Xe[n&255^e[t]]^n>>>8;r=n},d:function(){return~r}}},er=function(r,e,n,t,a){if(!a&&(a={l:1},e.dictionary)){var i=e.dictionary.subarray(-32768),o=new S(i.length+r.length);o.set(i),o.set(r,i.length),r=o,a.w=i.length}return Ye(r,e.level==null?6:e.level,e.mem==null?a.l?Math.ceil(Math.max(8,Math.min(13,Math.log(r.length)))*1.5):20:12+e.mem,n,t,a)},Ce=function(r,e){var n={};for(var t in r)n[t]=r[t];for(var t in e)n[t]=e[t];return n},I=function(r,e,n){for(;n;++e)r[e]=n,n>>>=8};function rr(r,e){return er(r,e||{},0,0)}var Re=function(r,e,n,t){for(var a in r){var i=r[a],o=e+a,s=t;Array.isArray(i)&&(s=Ce(t,i[1]),i=i[0]),i instanceof S?n[o]=[i,s]:(n[o+="/"]=[new S(0),s],Re(i,o,n,t))}},Be=typeof TextEncoder<"u"&&new TextEncoder,nr=typeof TextDecoder<"u"&&new TextDecoder,tr=0;try{nr.decode(Te,{stream:!0}),tr=1}catch{}function ue(r,e){var n;if(Be)return Be.encode(r);for(var t=r.length,a=new S(r.length+(r.length>>1)),i=0,o=function(u){a[i++]=u},n=0;n<t;++n){if(i+5>a.length){var s=new S(i+8+(t-n<<1));s.set(a),a=s}var f=r.charCodeAt(n);f<128||e?o(f):f<2048?(o(192|f>>6),o(128|f&63)):f>55295&&f<57344?(f=65536+(f&1047552)|r.charCodeAt(++n)&1023,o(240|f>>18),o(128|f>>12&63),o(128|f>>6&63),o(128|f&63)):(o(224|f>>12),o(128|f>>6&63),o(128|f&63))}return Me(a,0,i)}var ve=function(r){var e=0;if(r)for(var n in r){var t=r[n].length;t>65535&&re(9),e+=t+4}return e},Fe=function(r,e,n,t,a,i,o,s){var f=t.length,u=n.extra,l=s&&s.length,c=ve(u);I(r,e,o!=null?33639248:67324752),e+=4,o!=null&&(r[e++]=20,r[e++]=n.os),r[e]=20,e+=2,r[e++]=n.flag<<1|(i<0&&8),r[e++]=a&&8,r[e++]=n.compression&255,r[e++]=n.compression>>8;var w=new Date(n.mtime==null?Date.now():n.mtime),h=w.getFullYear()-1980;if((h<0||h>119)&&re(10),I(r,e,h<<25|w.getMonth()+1<<21|w.getDate()<<16|w.getHours()<<11|w.getMinutes()<<5|w.getSeconds()>>1),e+=4,i!=-1&&(I(r,e,n.crc),I(r,e+4,i<0?-i-2:i),I(r,e+8,n.size)),I(r,e+12,f),I(r,e+14,c),e+=16,o!=null&&(I(r,e,l),I(r,e+6,n.attrs),I(r,e+10,o),e+=14),r.set(t,e),e+=f,c)for(var p in u){var g=u[p],M=g.length;I(r,e,+p),I(r,e+2,M),r.set(g,e+4),e+=4+M}return l&&(r.set(s,e),e+=l),e},ar=function(r,e,n,t,a){I(r,e,101010256),I(r,e+8,n),I(r,e+10,n),I(r,e+12,t),I(r,e+16,a)};function ir(r,e){e||(e={});var n={},t=[];Re(r,"",n,e);var a=0,i=0;for(var o in n){var s=n[o],f=s[0],u=s[1],l=u.level==0?0:8,c=ue(o),w=c.length,h=u.comment,p=h&&ue(h),g=p&&p.length,M=ve(u.extra);w>65535&&re(11);var C=l?rr(f,u):f,T=C.length,E=qe();E.p(f),t.push(Ce(u,{size:f.length,crc:E.d(),c:C,f:c,m:p,u:w!=o.length||p&&h.length!=g,o:a,compression:l})),a+=30+w+M+T,i+=76+2*(w+M)+(g||0)+T}for(var m=new S(i+22),x=a,b=i-a,A=0;A<t.length;++A){var c=t[A];Fe(m,c.o,c,c.f,c.u,c.c.length);var d=30+c.f.length+ve(c.extra);m.set(c.c,c.o+d),Fe(m,a,c,c.f,c.u,c.c.length,c.o,c.m),a+=16+d+(c.m?c.m.length:0)}return ar(m,a,t.length,b,x),m}function or(r){const e=r.replace(/\\\\/g,"/").replace(/^\\/+/,"");if(!e||e.includes("..")||e.startsWith("/"))throw new Error(`Unsafe bundle ZIP path: ${r}`);return e}function lr(r){const e={};for(const n of r){const t=or(n.path),a={level:n.level??6};e[t]=[typeof n.data=="string"?ue(n.data):n.data,a]}return ir(e)}function sr(r){return String(r||"bundle").trim().replace(/[^a-zA-Z0-9._-]+/g,"_").replace(/_+/g,"_").replace(/^_+|_+$/g,"").slice(0,80)||"bundle"}function Ee(r){if(typeof r=="string")try{const e=new URL(r);return e.protocol==="http:"||e.protocol==="https:"?e.href:void 0}catch{return}}function fr(r,e){const t=String((r&&typeof r=="object"?r:{}).__typename||e.__typename||"").toLowerCase();return t.includes("tweet")||e.full_text||e.media?"tweet":t.includes("user")||e.screen_name||e.profile_image_url?"user":"unknown"}function cr(r,e){const t=(r&&typeof r=="object"?r:{}).twe_private_fields,a=[t==null?void 0:t.created_at,t==null?void 0:t.updated_at,e.created_at,e.time,e.date];for(const i of a){const o=Number(i);if(Number.isFinite(o)&&o>0)return o;if(typeof i=="string"){const s=Date.parse(i);if(Number.isFinite(s))return s}}}async function ur(r,e,n){const t=fr(e.original,e.record),a=String(e.id||e.record.id||e.record.rest_id||""),i=await De(r,t,a||JSON.stringify(e.record)),o=n.includeOriginalMetadata?{...e.record,metadata:e.original}:e.record;return{id:i,kind:t,sourceId:a||void 0,observedAt:cr(e.original,e.record),sensitivity:"low",data:o,mediaRefs:Array.isArray(e.record.media)?e.record.media.map((s,f)=>({id:`${i}:media:${f}`,type:s.type==="photo"||s.type==="video"||s.type==="animated_gif"?s.type:"unknown",url:Ee(s.original),previewUrl:Ee(s.thumbnail),altText:typeof s.ext_alt_text=="string"?s.ext_alt_text:void 0})):void 0}}function vr(){return{records:0,tweets:0,users:0,socialEdges:0,captures:0,mediaBlobs:0}}function dr(r,e){r.records+=1,e.kind==="tweet"&&(r.tweets+=1),e.kind==="user"&&(r.users+=1),e.kind==="social_edge"&&(r.socialEdges+=1),e.kind==="capture"&&(r.captures+=1),r.mediaBlobs+=0}async function hr(r,e){const n=Date.now(),t=typeof performance<"u"?performance.now():Date.now(),a=Math.max(0,Math.floor(Number(e.totalRecords||0))),i=(m,x)=>{var b;(b=e.onProgress)==null||b.call(e,{phase:m,processedRecords:x,totalRecords:a||x,elapsedMs:(typeof performance<"u"?performance.now():Date.now())-t})},o=await Ue(`${e.title}:${e.scope}:${e.queryText||""}:${n}:${a}`),s=vr(),f=[],u=[];let l=0;for await(const m of r){if(!m)continue;const x=await ur(o,m,e);dr(s,x),f.push(`${JSON.stringify(x)}\n`);for(const b of x.mediaRefs||[])b.url&&u.push(b.url);l+=1,(l===1||l===a||l%100===0)&&i("envelope",l)}const c=f.join(""),w=je(Je),h=[{path:"manifest.json",contentType:"application/json",role:"manifest"},{path:"records/records.jsonl",contentType:"application/x-ndjson",role:"records",bytes:new TextEncoder().encode(c).byteLength,sha256:await q(c)}],p=u.join(`\n`)+(u.length?`\n`:"");u.length&&h.push({path:"media/media-urls.txt",contentType:"text/plain",role:"media",bytes:new TextEncoder().encode(p).byteLength,sha256:await q(p)});const g={id:o,title:e.title,description:e.description,producer:{app:"twitter-web-exporter",appVersion:Ne.version,schemaVersion:1,exportedAt:n},privacy:w,counts:s,files:h},M=h[0];M&&(h[0]={...M,bytes:new TextEncoder().encode(JSON.stringify(g,void 0,2)).byteLength}),i("manifest",l);const C=e.compressionLevel??1,T=[{path:"manifest.json",data:JSON.stringify(g,void 0,2),level:C},{path:"records/records.jsonl",data:c,level:C}];u.length&&T.push({path:"media/media-urls.txt",data:p,level:C}),i("zip",l);const E={filename:`twe-bundle-${sr(e.title)}-${n}.zip`,bytes:lr(T),manifest:g};return i("done",l),E}const Y=new Map;function de(){return typeof performance<"u"&&typeof performance.now=="function"?performance.now():Date.now()}function ne(r,e){self.postMessage(r,{transfer:e||[]})}function wr(r){return r instanceof Error?r.message:String(r)}function te(r){var e;(e=r.wake)==null||e.call(r),r.wake=null}async function gr(r){r.rows.length||r.finished||r.cancelled||(r.waitingForChunk||(r.waitingForChunk=!0,ne({type:"bundle-export:ready-for-chunk",jobId:r.jobId})),await new Promise(e=>{r.wake=e}))}async function*yr(r){for(;;){if(await gr(r),r.cancelled)throw new Error("Bundle export cancelled.");const e=r.rows.shift();if(e){yield e;continue}if(r.finished)return}}async function pr(r,e){try{const n=await hr(yr(r),{...e.options,totalRecords:e.totalRecords,onProgress:a=>{if(r.cancelled)throw new Error("Bundle export cancelled.");ne({type:"bundle-export:progress",jobId:e.jobId,progress:a})}});if(r.cancelled)return;const t=n.bytes.buffer.slice(n.bytes.byteOffset,n.bytes.byteOffset+n.bytes.byteLength);ne({type:"bundle-export:done",jobId:e.jobId,filename:n.filename,buffer:t,manifest:n.manifest,elapsedMs:de()-r.startedAt},[t])}catch(n){r.cancelled||ne({type:"bundle-export:error",jobId:e.jobId,error:wr(n),elapsedMs:de()-r.startedAt})}finally{Y.delete(e.jobId)}}self.onmessage=r=>{const e=r.data;if(!e||typeof e!="object")return;if(e.type==="bundle-export:start"){const t=Y.get(e.jobId);t&&(t.cancelled=!0,te(t),Y.delete(e.jobId));const a={jobId:e.jobId,startedAt:de(),rows:[],finished:!1,cancelled:!1,waitingForChunk:!1,wake:null};Y.set(e.jobId,a),pr(a,e);return}const n=Y.get(e.jobId);if(n){if(e.type==="bundle-export:chunk"){!n.finished&&!n.cancelled&&(n.rows.push(...e.rows),n.waitingForChunk=!1,te(n));return}if(e.type==="bundle-export:finish"){n.finished=!0,te(n);return}e.type==="bundle-export:cancel"&&(n.cancelled=!0,te(n))}}})();\n',pp=typeof self<"u"&&self.Blob&&new Blob([a_],{type:"text/javascript;charset=utf-8"});function vC(e){let t;try{if(t=pp&&(self.URL||self.webkitURL).createObjectURL(pp),!t)throw "";const n=new Worker(t,{name:e==null?void 0:e.name});return n.addEventListener("error",()=>{(self.URL||self.webkitURL).revokeObjectURL(t);}),n}catch{return new Worker("data:text/javascript;charset=utf-8,"+encodeURIComponent(a_),{name:e==null?void 0:e.name})}finally{t&&(self.URL||self.webkitURL).revokeObjectURL(t);}}const kC=100,xC="twe_bundle_export_batch_delay_ms_v1";function SC(){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?`bundle-${crypto.randomUUID()}`:`bundle-${Date.now()}-${Math.random().toString(36).slice(2,10)}`}function CC(e){return !!e&&typeof e=="object"&&Symbol.asyncIterator in e}async function*TC(e){if(CC(e)){yield*e;return}yield*e;}function MC(){if(typeof localStorage>"u")return 0;try{const e=localStorage.getItem(xC),t=Number(e||0);return Number.isFinite(t)&&t>0?Math.min(1e3,t):0}catch{return 0}}async function mp(e){e&&await new Promise(t=>{globalThis.setTimeout(t,e);});}function RC({rows:e,totalRecords:t,options:n,onProgress:r,batchSize:o=kC}){const a=SC(),i=qe(),s=Math.max(1,Math.floor(o)),l=MC();let c=null,h=false,f=false,m=0,g=0,_=null,b=null,C=false;const k=()=>new Promise((F,I)=>{if(f||h){I(new Error("Bundle export cancelled."));return}if(C){C=false,F();return}b=F;}),T=()=>{h=true,b==null||b(),b=null;},M=F=>{!c||h||f||c.postMessage(F);},P=new Promise((F,I)=>{_=I;try{c=new vC,Ga("export",!0);}catch(O){Ga("export",false),I(O instanceof Error?O:new Error(String(O)));return}c.onmessage=O=>{const B=O.data;if(!B||B.jobId!==a)return;if(B.type==="bundle-export:ready-for-chunk"){b?(b(),b=null):C=true;return}if(B.type==="bundle-export:progress"){r==null||r(B.progress);return}if(T(),c==null||c.terminate(),c=null,B.type==="bundle-export:error"){Be({kind:"export",name:"bundle-worker-error",durationMs:B.elapsedMs,tags:{error:B.error}}),I(new Error(B.error));return}const D=new Blob([B.buffer],{type:"application/zip"});fa(B.filename,D),Be({kind:"export",name:"bundle-worker-complete",durationMs:qe()-i,value:B.buffer.byteLength,tags:{records:B.manifest.counts.records,compressionLevel:n.compressionLevel??1,batches:g,sentRows:m}}),F(B.filename);},c.onerror=O=>{h||(T(),Ga("export",false),c==null||c.terminate(),c=null,I(new Error(O.message||"Bundle export worker failed.")));},M({type:"bundle-export:start",jobId:a,totalRecords:t,options:{...n,compressionLevel:n.compressionLevel??1,totalRecords:t}}),(async()=>{try{let O=[];for await(const B of TC(e)){if(f||h)return;if(O.push(B),!(O.length<s)){if(await k(),f||h)return;g+=1,m+=O.length,M({type:"bundle-export:chunk",jobId:a,rows:O}),Be({kind:"export",name:"bundle-worker-batch-sent",value:O.length,tags:{batch:g,sentRows:m,totalRecords:t}}),O=[],await mp(l);}}if(O.length){if(await k(),f||h)return;g+=1,m+=O.length,M({type:"bundle-export:chunk",jobId:a,rows:O}),Be({kind:"export",name:"bundle-worker-batch-sent",value:O.length,tags:{batch:g,sentRows:m,totalRecords:t}}),await mp(l);}if(await k(),f||h)return;M({type:"bundle-export:finish",jobId:a}),Be({kind:"export",name:"bundle-worker-stream-complete",durationMs:qe()-i,value:m,tags:{batches:g,totalRecords:t}});}catch(O){if(h)return;T(),c==null||c.terminate(),c=null,I(O instanceof Error?O:new Error(String(O)));}})();});return {jobId:a,promise:P,cancel:()=>{h||f||(f=true,T(),c==null||c.postMessage({type:"bundle-export:cancel",jobId:a}),c==null||c.terminate(),c=null,_==null||_(new Error("Bundle export cancelled.")),Be({kind:"export",name:"bundle-worker-cancel",durationMs:qe()-i,value:m,tags:{batches:g}}));}}}function Er(e){if(e==null||typeof e!="object")return e;if(typeof structuredClone=="function")try{return structuredClone(e)}catch{}try{return JSON.parse(JSON.stringify(e))}catch{return e}}function IC(e,t){if(!e||typeof e!="object")return;const n=t.split(".");let r=e;for(const o of n){if(!r||typeof r!="object")return;r=r[o];}return r}function Kd(e){const t=[];for(const n of e){if("columns"in n&&Array.isArray(n.columns)){t.push(...Kd(n.columns));continue}t.push(n);}return t}function td(e){return "id"in e&&typeof e.id=="string"&&e.id?e.id:"accessorKey"in e&&typeof e.accessorKey=="string"?e.accessorKey:""}function EC(e,t,n){if("accessorFn"in e&&typeof e.accessorFn=="function")return e.accessorFn(t,n);if("accessorKey"in e){if(typeof e.accessorKey=="string")return IC(t,e.accessorKey);if(typeof e.accessorKey=="number"&&Array.isArray(t))return t[e.accessorKey]}}function Si(e,t,n){const r={},o=Kd(t);for(const i of o){const s=i.meta;if((s==null?void 0:s.exportable)===false)continue;const l=EC(i,e,n),c={original:e};let h=s!=null&&s.exportValue?s.exportValue(c):l;h===void 0&&(h=null),r[(s==null?void 0:s.exportKey)||td(i)]=Er(h);}const a=Er(e);if(a&&(a.__bookmark_folder_id||a.__bookmark_folder_name||a.__bookmark_folder_url)){const i=a.__bookmark_folder_name_source==="api"?a.__bookmark_folder_name??null:null;r.bookmark_folder_id=a.__bookmark_folder_id??null,r.bookmark_folder_name=i,r.bookmark_folder_url=a.__bookmark_folder_url??null;}return {id:Oo(a,n),original:Er(e),record:r}}function AC({title:e,columns:t,resultRecords:n,selectedRecords:r,selectedRecordCount:o,selectionExcludedRecordIds:a=[],resultCount:i,streamResultRecords:s,streamSelectedRecords:l,resultSetSnapshot:c,selectionMode:h,preparingFullDataset:f=false,show:m,onClose:g}){const{t:_}=Wn("exporter"),[b,C]=Hn(No.JSON),[k,T]=Hn(false),[M,P]=Hn(false),[F,I]=sr(false),[O,B]=Hn(0),[D,v]=Hn(0),[L,$]=Hn("result_set"),[Me,Z]=Hn(1),[re,J]=De(null),le=_t(false),he=_t(null),pe=_t(null),ge=_t(null),z=_t(false);Je(()=>{if(!m){le.current=false;return}le.current||(le.current=true,J({...c,ids:[...c.ids],warnings:[...c.warnings]}),$(r.length>0&&h==="explicit"?"selected":"result_set"),B(0),v(0));},[c,r,h,B,$,v,m]);const ue=i??(re==null?void 0:re.totalMatches)??n.length,Pe=It(()=>new Set(h==="all"?a:[]),[a,h]),ce=h==="all"?Math.min(Pe.size,ue):0,Ee=Math.max(0,ue-ce),Qe=o??r.length,X=L==="selected"?r:n,ne=L==="selected"?Qe:Ee,j=L==="result_set"&&!!s,se=L==="selected"&&!!l,_e=j||se,we=f&&L==="result_set",Ye=ne>0&&!we,We=et=>L==="result_set"&&Pe.has(et),Se=()=>{const et=[];return X.forEach((at,wt)=>{const Ce=Si(at,t,wt);We(Ce.id)||et.push(Ce);}),et};async function*Tt(){if(j&&s){let et=0;for await(const at of s()){const wt=Si(at,t,et);if(et+=1,We(wt.id))continue;const Ce=Er(wt.record);F&&(Ce.metadata=Er(wt.original)),yield Ce;}return}if(se&&l){let et=0;for await(const at of l()){const wt=Si(at,t,et);et+=1;const Ce=Er(wt.record);F&&(Ce.metadata=Er(wt.original)),yield Ce;}return}for(const et of Se()){const at=Er(et.record);F&&(at.metadata=Er(et.original)),yield at;}}const jt=async()=>{if(!Ye)return;const et=new AbortController,at=qe();z.current=false,pe.current=et,T(true),B(0),v(ne),Be({kind:"export",name:"modal-export-start",value:ne,tags:{scope:L,format:b,streaming:_e,excluded:ce}});const wt=Kd(t).reduce((ht,it)=>{var ke,E;const yt=((ke=it.meta)==null?void 0:ke.exportKey)||td(it),Oe=((E=it.meta)==null?void 0:E.exportHeader)||td(it);return ht[yt]=_(Oe),ht},{});if(_e){if(await dy(Tt(),b,`twitter-${e}-${L==="selected"?"selected":"results"}-${Date.now()}.${b.toLowerCase()}`,wt,{onProgress:B,signal:et.signal}),pe.current=null,T(false),et.signal.aborted){z.current||Be({kind:"export",name:"modal-export-cancel",durationMs:qe()-at,value:O,tags:{scope:L,format:b,streaming:true,excluded:ce}});return}Be({kind:"export",name:"modal-export-complete",durationMs:qe()-at,value:ne,tags:{scope:L,format:b,streaming:true,excluded:ce}});return}const Ce=[];for(const ht of Se()){if(et.signal.aborted){pe.current=null,T(false);return}const it=Er(ht.record);F&&(it.metadata=Er(ht.original)),Ce.push(it),B(Ce.length);}Be({kind:"export",name:"modal-array-export-rows",value:Ce.length,tags:{scope:L,format:b,excluded:ce}}),await uy(Ce,b,`twitter-${e}-${L==="selected"?"selected":"results"}-${Date.now()}.${b.toLowerCase()}`,wt),pe.current=null,T(false),Be({kind:"export",name:"modal-export-complete",durationMs:qe()-at,value:Ce.length,tags:{scope:L,format:b,streaming:false,excluded:ce}});};async function*Wt(et){if(j&&s){let at=0;for await(const wt of s()){if(et.aborted)return;const Ce=Si(wt,t,at);at+=1,!We(Ce.id)&&(yield Ce);}return}if(se&&l){let at=0;for await(const wt of l()){if(et.aborted)return;yield Si(wt,t,at),at+=1;}return}for(const at of Se()){if(et.aborted)return;yield at;}}const Gt=async()=>{if(!Ye)return;const et=new AbortController;ge.current=et,P(true),B(0),v(ne);try{const at=RC({rows:Wt(et.signal),totalRecords:ne,options:{title:e,scope:L,queryText:re==null?void 0:re.queryText,sort:re==null?void 0:re.sort,includeOriginalMetadata:F,compressionLevel:Me},onProgress:wt=>{B(wt.processedRecords),v(wt.totalRecords);}});if(he.current=at,await at.promise,et.signal.aborted)return;B(ne);}catch(at){const wt=at instanceof Error?at.message:String(at);/cancelled/i.test(wt)||console.error("[twitter-web-exporter] Failed to export bundle ZIP.",at);}finally{he.current=null,ge.current=null,P(false);}},Rt=()=>{var et,at,wt;if(k){(et=pe.current)==null||et.abort(),z.current=true,Be({kind:"export",name:"modal-export-cancel",value:O,tags:{scope:L,format:b,streaming:_e}}),pe.current=null,T(false);return}if(M){(at=ge.current)==null||at.abort(),(wt=he.current)==null||wt.cancel(),he.current=null,ge.current=null,P(false);return}g==null||g();};return d(lr,{class:"max-w-sm md:max-w-screen-sm sm:max-w-screen-sm max-h-full",title:`${e} ${_("Data")}`,show:m,onClose:g,children:[d("div",{class:"px-4 text-base",children:[d("p",{class:"text-base-content text-opacity-60 mb-2 leading-5 text-sm",children:_("Export captured data as JSON/HTML/CSV file. This may take a while depending on the amount of data. The exported file does not include media files such as images and videos but only the URLs.")}),d("div",{class:"flex items-center",children:[d("p",{class:"mr-2 leading-8",children:_("Data length:")}),d("span",{class:"font-mono leading-6 h-6 bg-base-200 px-2 rounded-md",children:ne}),we?d("span",{class:"ml-2 inline-flex items-center gap-1 text-xs opacity-70",children:[d("span",{class:"loading loading-spinner loading-xs"}),_("loading remaining rows")]}):null]}),d("div",{class:"flex items-center gap-4",children:[d("p",{class:"leading-8",children:_("Export scope:")}),d("label",{class:"label cursor-pointer gap-2 py-0",children:[d("input",{type:"radio",name:"export-scope",class:"radio radio-sm",checked:L==="result_set",onChange:()=>$("result_set")}),d("span",{children:_("All current results")}),d("span",{class:"font-mono opacity-60",children:["(",Ee,")"]})]}),d("label",{class:sn("label cursor-pointer gap-2 py-0",Qe<=0&&"opacity-50"),children:[d("input",{type:"radio",name:"export-scope",class:"radio radio-sm",checked:L==="selected",disabled:Qe<=0,onChange:()=>$("selected")}),d("span",{children:_("Selected rows")}),d("span",{class:"font-mono opacity-60",children:["(",Qe,")"]})]})]}),re?d("div",{class:"rounded-box-half border border-base-300 bg-base-200/60 px-3 py-2 text-xs leading-5",children:[d("div",{class:"font-semibold",children:_("Pinned result set")}),d("div",{class:"font-mono opacity-70",children:re.resultSetId}),d("div",{children:[_("Query"),":"," ",d("span",{class:"font-mono",children:re.queryText||"-"})]}),d("div",{children:[_("Sort"),": ",d("span",{class:"font-mono",children:re.sort})]})]}):null,d("div",{class:"flex items-center",children:[d("p",{class:"mr-2 leading-8",children:_("Include all metadata:")}),d("input",{type:"checkbox",class:"checkbox checkbox-sm",checked:F,onChange:I})]}),d("div",{class:"flex",children:[d("p",{class:"mr-2 leading-8",children:_("Export as:")}),d("select",{class:"select select-bordered select-sm w-32",onChange:et=>{C(et.target.value);},children:Object.values(No).map(et=>d("option",{selected:et===b,children:et},et))})]}),d("div",{class:"flex items-center gap-2",children:[d("p",{class:"leading-8",children:_("Bundle ZIP compression:")}),d("select",{class:"select select-bordered select-sm w-44",value:String(Me),onChange:et=>Z(Number(et.target.value)),children:[d("option",{value:"0",children:_("Fastest / store")}),d("option",{value:"1",children:_("Balanced / fast")}),d("option",{value:"6",children:_("Smaller / slower")})]})]}),ne>0?null:d("div",{class:"flex items-center justify-center h-28 w-full",children:d("p",{class:"text-base-content text-opacity-50",children:_("No data selected.")})}),d("div",{class:"flex flex-col mt-6",children:[d("progress",{class:"progress progress-primary w-full",value:O/(D||1)*100,max:"100"}),d("span",{class:"text-sm leading-none mt-2 text-base-content text-opacity-60",children:`${O}/${ne}`})]})]}),d("div",{class:"flex space-x-2",children:[d("span",{class:"flex-grow"}),d("button",{class:"btn",onClick:Rt,children:_(M||k?"Cancel Export":"Cancel")}),d("button",{class:sn("btn btn-secondary",(M||!Ye)&&"btn-disabled"),onClick:Gt,title:_("Export a canonical portable ZIP bundle for sharing/importing."),children:[M&&d("span",{class:"loading loading-spinner"}),_("Export Bundle ZIP")]}),d("button",{class:sn("btn btn-primary",(k||!Ye)&&"btn-disabled"),onClick:jt,children:[k&&d("span",{class:"loading loading-spinner"}),_("Start Export")]})]})]})}const gp=.5,yp=8,_p=1.25;function wp(e,t,n){return Math.max(t,Math.min(n,e))}function DC(e){return /\.mp4(?:[?#].*)?$/i.test(e)}function PC({show:e,url:t,dockAfterClose:n,onDockAfterCloseChange:r,onClose:o}){const{t:a}=Wn(),[i,s]=De(1),[l,c]=De({x:0,y:0}),h=_t(false),f=_t({x:0,y:0}),m=_t({x:0,y:0}),g=DC(t);Je(()=>{s(1),c({x:0,y:0});},[t]);const _=Nn(I=>{s(O=>{const B=wp(I,gp,yp);return B<=1&&O>1&&c({x:0,y:0}),B});},[]),b=Nn(I=>{s(O=>{const B=wp(O*I,gp,yp);return B<=1&&c({x:0,y:0}),B});},[]),C=Nn(()=>{s(1),c({x:0,y:0});},[]),k=I=>{if(!g){if(I.ctrlKey||I.metaKey||I.altKey){I.preventDefault(),b(I.deltaY<0?1.12:.88);return}i>1&&(I.preventDefault(),c(O=>({x:O.x-I.deltaX,y:O.y-I.deltaY})));}},T=I=>{var O,B;g||i<=1||(h.current=true,f.current={x:I.clientX,y:I.clientY},m.current=l,(B=(O=I.currentTarget).setPointerCapture)==null||B.call(O,I.pointerId));},M=I=>{h.current&&(I.preventDefault(),c({x:m.current.x+I.clientX-f.current.x,y:m.current.y+I.clientY-f.current.y}));},P=I=>{var O,B;h.current=false,(B=(O=I.currentTarget).releasePointerCapture)==null||B.call(O,I.pointerId);},F=()=>{g||(i>1?C():_(2));};return d(lr,{title:a("Media View"),class:"h-[min(92vh,980px)] w-[min(96vw,1480px)] max-w-[96vw] max-h-[92vh]",show:e&&!!t,onClose:o,children:d("div",{class:"flex min-h-0 grow flex-col gap-2",children:[d("div",{class:"flex flex-wrap items-center gap-2 border-b border-base-300 pb-2 text-xs",children:[g?null:d(Jn,{children:[d("button",{class:"btn btn-xs",onClick:()=>b(1/_p),children:[d(Qw,{size:14}),Math.round(i*100),"%"]}),d("button",{class:"btn btn-xs",onClick:()=>b(_p),children:d(Zw,{size:14})}),d("button",{class:"btn btn-xs",onClick:C,children:[d(rg,{size:14}),"Reset"]})]}),d("a",{class:"btn btn-xs",href:t,target:"_blank",rel:"noreferrer",children:[d(eg,{size:14}),"Open"]}),d("label",{class:"label ml-auto cursor-pointer gap-2 py-0",children:[d("input",{type:"checkbox",class:"toggle toggle-xs",checked:n,onChange:I=>r(I.target.checked)}),d("span",{class:"label-text text-xs",children:"Keep mini preview after close"})]})]}),d("main",{class:`relative min-h-0 grow overflow-hidden rounded-box-half bg-base-200 ${g?"":i>1?"cursor-grab active:cursor-grabbing":"cursor-zoom-in"}`,onWheel:k,onPointerDown:T,onPointerMove:M,onPointerUp:P,onPointerCancel:P,onDblClick:F,children:g?d("video",{controls:true,class:"h-full w-full object-contain",src:t}):d("img",{class:"h-full w-full select-none object-contain",style:{transform:`translate3d(${l.x}px, ${l.y}px, 0) scale(${i})`,transformOrigin:"center center",transition:h.current?"none":"transform 120ms ease-out"},src:t,draggable:false})})]})})}const OC=/[\p{L}\p{N}_]+(?:['’][\p{L}\p{N}_]+)*/gu,bp={bm25:1,lexical:1,cover_density:1,recency:0,term_match:1,phrase_match:8,quoted_phrase_match:256,cover_bigram:10,cover_trigram:30},FC="twe_raw_search_ranking_v1",LC=128,i_=Math.max(1,Number(Ud.min_term_length)),NC=Math.max(8,Number(Ud.max_expansions)),nd=Math.max(1,Number(us.min_term_length)),ji=Math.max(0,Number(us.max_edit_distance)),s_=Math.max(1,Number(us.prefix_root_length)),l_=Math.max(8,Number(us.max_expansions)),c_=3,BC=4,UC=.65,$C=1.5,Ci=new Map,vp=new WeakMap;function ct(e,t){const n=t.split(".");let r=e;for(const o of n){if(!r||typeof r!="object")return null;r=r[o];}return r}function Ft(e){return typeof e=="string"?e:""}function Ti(e){if(typeof e=="boolean")return e;if(typeof e=="number")return e>0;if(typeof e=="string"){const t=e.trim().toLowerCase();return t==="1"||t==="true"||t==="yes"}return  false}function js(e){if(typeof e=="number"&&Number.isFinite(e))return e;if(typeof e=="string"){const t=Number(e);if(Number.isFinite(t))return t}return 0}function Ln(e){return e.trim().toLowerCase()}function Bo(e){if(!e)return [];const t=e.toLowerCase().match(OC);return t?t.map(n=>n.replace(/['’]/g,"")).filter(Boolean):[]}function au(e){const t=new Map;for(let n=0;n<e.length;n+=1){const r=e[n];r&&t.set(r,(t.get(r)||0)+1);}return t}function u_(e,t){if(e===t)return 0;if(!e.length)return t.length;if(!t.length)return e.length;const n=new Array(t.length+1),r=new Array(t.length+1);for(let o=0;o<=t.length;o+=1)n[o]=o;for(let o=1;o<=e.length;o+=1){r[0]=o;for(let a=1;a<=t.length;a+=1){const i=e[o-1]===t[a-1]?0:1;r[a]=Math.min((n[a]??0)+1,(r[a-1]??0)+1,(n[a-1]??0)+i);}for(let a=0;a<=t.length;a+=1)n[a]=r[a]??0;}return n[t.length]??Math.max(e.length,t.length)}function rd(e,t=false){if(!e)return 0;if(/^\d{4}-\d{2}-\d{2}$/.test(e)){const r=t?"T23:59:59.999Z":"T00:00:00.000Z",o=Date.parse(`${e}${r}`);return Number.isFinite(o)?o:0}const n=Date.parse(e);return Number.isFinite(n)?n:0}function HC(e){return e?e.replace(/<[^>]+>/g," ").replace(/\s+/g," ").trim():""}function jC(e){const t=new Set,n=r=>{if(Array.isArray(r))for(const o of r){if(!o||typeof o!="object")continue;const a=o,i=Ft(a.expanded_url).trim(),s=Ft(a.display_url).trim(),l=Ft(a.url).trim();i&&t.add(i),s&&t.add(s),l&&t.add(l);}};return n(ct(e,"legacy.entities.urls")),n(ct(e,"legacy.entities.media")),n(ct(e,"legacy.entities.description.urls")),n(ct(e,"legacy.entities.url.urls")),[...t]}function iu(e,t,n="text"){const r=ct(e,t);if(!Array.isArray(r))return [];const o=new Set;for(const a of r){if(!a||typeof a!="object")continue;const s=Ln(Ft(a[n]).trim());s&&o.add(s);}return [...o]}function qC(e){const t=(Array.isArray(ct(e,"legacy.extended_entities.media"))?ct(e,"legacy.extended_entities.media"):ct(e,"legacy.entities.media"))||[];if(!Array.isArray(t))return [];const n=new Set;for(const r of t){if(!r||typeof r!="object")continue;const a=Ln(Ft(r.type).trim());a&&n.add(a);}return [...n]}function VC(e){const t=ct(e,"article.article_results.result.content_state.blocks");if(!Array.isArray(t))return [];const n=[];for(const r of t){if(!r||typeof r!="object")continue;const o=Ft(r.text).trim();o&&n.push(o);}return n}function zC(e){const t=new Set;for(const n of e)try{const r=n.startsWith("http")?n:`https://${n}`,o=new URL(r).hostname.replace(/^www\./,"").toLowerCase();o&&t.add(o);}catch{}return [...t]}function qi(e,t,n=false){if(!t.length)return 0;const r=t[0],o=[];for(let i=0;i<e.length;i+=1)e[i]===r&&o.push(i);if(!o.length)return null;let a=null;for(const i of o){let s=i,l=true;for(let m=1;m<t.length;m+=1){const g=t[m],_=n&&m===t.length-1;let b=-1;for(let C=s+1;C<e.length;C+=1){const k=e[C];if(_&&g&&(k!=null&&k.startsWith(g))||k===g){b=C;break}}if(b<0){l=false;break}s=b;}if(!l)continue;const c=s-i,h=Math.max(0,t.length-1),f=Math.max(0,c-h);(a===null||f<a)&&(a=f);}return a}function kp(e){const t=e||{},n=Ft(ct(t,"rest_id"))||Ft(ct(t,"legacy.id_str"))||Ft(ct(t,"id_str"))||`${Math.random().toString(36).slice(2)}`,r=Ft(ct(t,"note_tweet.note_tweet_results.result.text"))||[Ft(ct(t,"article.article_results.result.title")),Ft(ct(t,"article.article_results.result.preview_text")),...VC(t)].map(Rt=>Rt.trim()).filter(Boolean).filter((Rt,et,at)=>at.indexOf(Rt)===et).join(`

`)||Ft(ct(t,"legacy.full_text"))||Ft(ct(t,"legacy.text"))||Ft(ct(t,"legacy.description")),o=Ft(ct(t,"quoted_status_result.result.note_tweet.note_tweet_results.result.text"))||Ft(ct(t,"quoted_status_result.result.legacy.full_text"))||Ft(ct(t,"quoted_status_result.result.legacy.text"))||Ft(ct(t,"quoted_status_result.result.article.article_results.result.title"))||Ft(ct(t,"quoted_status_result.result.article.article_results.result.preview_text")),a=Ln(Ft(ct(t,"quoted_status_result.result.core.user_results.result.core.screen_name"))),i=Ft(ct(t,"quoted_status_result.result.core.user_results.result.core.name")),s=Ln(Ft(ct(t,"core.user_results.result.core.screen_name"))||Ft(ct(t,"core.screen_name"))),l=Ft(ct(t,"core.user_results.result.core.name"))||Ft(ct(t,"core.name")),c=Ft(ct(t,"core.user_results.result.rest_id"))||Ft(ct(t,"rest_id")),h=Ft(ct(t,"legacy.created_at"))||Ft(ct(t,"core.created_at")),f=h?Number(Ja(h)||0):Number(ct(t,"article.article_results.result.metadata.first_published_at_secs")||0)*1e3,m=HC(Ft(ct(t,"legacy.source"))),g=Ln(Ft(ct(t,"card.card_platform.card_name"))||Ft(ct(t,"card.name"))||Ft(ct(t,"__card_name"))),_=Ft(ct(t,"__bookmark_folder_id")).trim(),b=Ft(ct(t,"__bookmark_folder_name")).trim(),C=jC(t),k=zC(C),T=iu(t,"legacy.entities.user_mentions","screen_name"),M=iu(t,"legacy.entities.hashtags"),P=iu(t,"legacy.entities.symbols"),F=qC(t),I=co(ct(t,"twe_relationship_fields.subject_screen_names")).map(Rt=>Ln(Rt)),O=co(ct(t,"twe_relationship_fields.subject_user_ids")).map(Rt=>String(Rt).trim()),B=co(ct(t,"twe_relationship_fields.relation_types")).map(Rt=>Ln(Rt)),D=Ln(Ft(ct(t,"legacy.in_reply_to_screen_name"))),v=Ft(ct(t,"legacy.in_reply_to_user_id_str")).trim(),L=Ft(ct(t,"legacy.in_reply_to_status_id_str")).trim(),$=Ft(ct(t,"legacy.conversation_id_str"))||Ft(ct(t,"conversation_id_str")),Me=Ln(Ft(ct(t,"legacy.lang"))),Z=Ln(Ft(ct(t,"__route_type"))),re=F.length>0,J=F.includes("photo"),le=F.includes("video")||F.includes("animated_gif"),he=C.length>0,pe=!!ct(t,"legacy.retweeted_status_result")||Ft(ct(t,"legacy.full_text")).startsWith("RT @"),ge=!!ct(t,"quoted_status_result"),z=!!L,ue=Ln(Ft(ct(t,"core.user_results.result.verification.verified_type")))==="verified"||Ln(Ft(ct(t,"verification.verified_type")))==="verified",Pe=Ti(ct(t,"core.user_results.result.is_blue_verified"))||Ti(ct(t,"is_blue_verified")),ce=Ti(ct(t,"legacy.favorited")),Ee=Ti(ct(t,"legacy.retweeted")),Qe=Ti(ct(t,"legacy.bookmarked")),X=js(ct(t,"legacy.favorite_count")),ne=js(ct(t,"legacy.retweet_count")),j=js(ct(t,"legacy.reply_count")),se=js(ct(t,"legacy.bookmark_count")),_e=[r,o,m,s,l,a,i,D,_,b,g,...I,...O,...B,...T,...M,...P,...C,...k].filter(Boolean).join(" ").trim(),we=[r,m,s,l,D,_,b,g,...I,...O,...B,...T,...M,...P,...C,...k].filter(Boolean).join(" ").trim(),Ye=[o,a,i].filter(Boolean).join(" ").trim(),We=Bo(_e),Se=Bo(we),Tt=Bo(Ye),jt=au(We),Wt=au(Se),Gt=au(Tt);return {raw:e,id:n,text:_e,primaryText:we,quotedText:Ye,tokens:We,primaryTokens:Se,quotedTokens:Tt,tokenFreq:jt,primaryTokenFreq:Wt,quotedTokenFreq:Gt,createdAtMs:f,authorScreenName:s,authorId:c,toUser:D,toUserId:v,inReplyToId:L,conversationId:$,lang:Me,routeType:Z,sourceText:Ln(m),cardName:g,bookmarkFolderId:_,bookmarkFolderName:Ln(b),mentions:T,hashtags:M,cashtags:P,urls:C.map(Rt=>Rt.toLowerCase()),domains:k,favoriteCount:X,retweetCount:ne,replyCount:j,bookmarkCount:se,favorited:ce,retweeted:Ee,bookmarked:Qe,hasMedia:re,hasImages:J,hasVideo:le,hasLinks:he,isReply:z,isRetweet:pe,isQuote:ge,isVerified:ue,isBlueVerified:Pe,fieldSearchCache:new Map}}function KC(e){if(!e||typeof e!="object")return kp(e);const t=vp.get(e);if(t)return t;const n=kp(e);return vp.set(e,n),n}function co(e){if(e==null)return [];if(typeof e=="string"){const t=e.trim();return t?[t]:[]}return typeof e=="number"||typeof e=="boolean"?[String(e)]:Array.isArray(e)?e.flatMap(t=>co(t)):typeof e=="object"?Object.values(e).flatMap(t=>co(t)):[]}function WC(e,t){switch(t){case "text":return e.text;case "id":return e.id;case "author_screen_name":return e.authorScreenName;case "author_id":return e.authorId;case "to_user":return e.toUser;case "to_user_id":return e.toUserId;case "conversation_id":return e.conversationId;case "lang":return e.lang;case "route":case "route_type":return e.routeType;case "source":case "source_text":return e.sourceText;case "card_name":return e.cardName;case "bookmark_folder_id":return e.bookmarkFolderId;case "bookmark_folder_name":return e.bookmarkFolderName;case "subject_screen_names":return co(ct(e.raw||{},"twe_relationship_fields.subject_screen_names"));case "subject_user_ids":return co(ct(e.raw||{},"twe_relationship_fields.subject_user_ids"));case "relation_types":return co(ct(e.raw||{},"twe_relationship_fields.relation_types"));case "mentions":return e.mentions;case "hashtags":return e.hashtags;case "cashtags":return e.cashtags;case "urls":return e.urls;case "domains":return e.domains;default:return ct(e.raw||{},t)}}function GC(e,t){const n=String(t||"").trim();if(!n)return {text:e.text,tokens:e.tokens,tokenFreq:e.tokenFreq};const r=e.fieldSearchCache.get(n);if(r)return r;const a=co(WC(e,n)).join(" ").trim(),i=Bo(a),s=new Map;for(const c of i)s.set(c,(s.get(c)||0)+1);const l={text:a,tokens:i,tokenFreq:s};return e.fieldSearchCache.set(n,l),l}function YC(e){const t=new Map;let n=0;for(const r of e){n+=r.tokens.length;for(const o of r.tokenFreq.keys())t.set(o,(t.get(o)||0)+1);}return {docCount:e.length,avgDocLength:e.length?n/e.length:1,termDocFreq:t}}function hn(e,t,n){if(!t)return;const r=e.get(t);if(r){r.push(n);return}e.set(t,[n]);}function tn(e,t){return `${e}:${t}`}function XC(e){const t=new Map,n=new Map;for(let r=0;r<e.length;r+=1){const o=e[r];if(o){for(const a of o.tokenFreq.keys())hn(t,a,r);hn(n,tn("id",o.id),r),hn(n,tn("from",o.authorScreenName),r),hn(n,tn("from_id",o.authorId),r),hn(n,tn("author_id",o.authorId),r),hn(n,tn("to",o.toUser),r),hn(n,tn("to_id",o.toUserId),r),hn(n,tn("in_reply_to_id",o.inReplyToId),r),hn(n,tn("conversation_id",o.conversationId),r),hn(n,tn("lang",o.lang),r),hn(n,tn("route",o.routeType),r),hn(n,tn("bookmark_folder",o.bookmarkFolderId),r);for(const a of o.mentions)hn(n,tn("mention",a),r);for(const a of o.hashtags)hn(n,tn("hashtag",a),r);for(const a of o.cashtags)hn(n,tn("cashtag",a),r);o.hasMedia&&hn(n,tn("is","media"),r),o.hasImages&&hn(n,tn("is","images"),r),o.hasVideo&&hn(n,tn("is","videos"),r),o.hasLinks&&hn(n,tn("is","links"),r),o.bookmarked&&hn(n,tn("is","bookmarked"),r),o.favorited&&hn(n,tn("is","liked"),r),o.retweeted&&hn(n,tn("is","retweeted"),r),o.isReply&&hn(n,tn("is","reply"),r),o.isRetweet&&hn(n,tn("is","retweet"),r),o.isQuote&&hn(n,tn("is","quote"),r),o.isVerified&&hn(n,tn("is","verified"),r),o.isBlueVerified&&hn(n,tn("is","blue_verified"),r);}}return {tokenDocs:t,exactFilterDocs:n,tokenVocabulary:[...t.keys()].sort()}}function su(e,t){const n=t instanceof Set?t:new Set(t);if(!e)return new Set(n);const r=new Set;for(const o of e)n.has(o)&&r.add(o);return r}function Rl(e){const t=new Set;for(const n of e)for(const r of n)t.add(r);return t}function ZC(e,t){if(!e.length||!t.length)return [];const n=e.length<=t.length?e:t,r=e.length<=t.length?t:e,o=new Set(r),a=[];for(const i of n)o.has(i)&&a.push(i);return a}function QC(e,t){const n=t.orderedTerms.filter(Boolean);if(n.length<c_)return null;const r=[];for(let a=0;a<n.length-1;a+=1){const i=e.indexes.tokenDocs.get(n[a]||"")||[],s=e.indexes.tokenDocs.get(n[a+1]||"")||[],l=ZC(i,s);l.length&&r.push(l);}if(!r.length)return null;const o=Rl(r);return !o.size||o.size>=e.docs.length?null:o}function JC(e,t){var f;const n=t.positiveTerms.filter(Boolean);if(n.length<c_)return null;const r=Math.max(1,e.rankingContext.docCount),o=n.map(m=>({term:m,docFreq:e.rankingContext.termDocFreq.get(m)||0})).filter(m=>m.docFreq>0).sort((m,g)=>m.docFreq!==g.docFreq?m.docFreq-g.docFreq:m.term.localeCompare(g.term));if(!o.length)return null;const a=o.filter(m=>m.docFreq/r<=UC),i=a.length?a:o,s=((f=i[0])==null?void 0:f.docFreq)||0,l=s>0?i.filter(m=>m.docFreq<=s*$C):i,c=(l.length?l:i).slice(0,BC);if(!c.length)return null;const h=Rl(c.map(m=>e.indexes.tokenDocs.get(m.term)||[]));return !h.size||h.size>=e.docs.length?null:h}function eT(e,t,n){if(!t||t.length<i_)return [];const r=[];for(const o of e)if(o.startsWith(t)&&(r.push(o),r.length>=n))break;return r}function d_(e,t,n){if(!t||t.length<nd||ji<=0)return [];const r=t.slice(0,s_),o=[];for(const a of e)if(a.startsWith(r)&&!(Math.abs(a.length-t.length)>ji)&&!(u_(a,t)>ji)&&(o.push(a),o.length>=n))break;return o}function tT(e,t){const n=e.indexes.tokenDocs,r=e.indexes.tokenVocabulary,o=Bo(t.value);if(!o.length)return [];const a=new Set;for(let i=0;i<o.length;i+=1){const s=o[i];if(!(!s||(a.add(s),!(i===o.length-1)))){if(t.prefix)for(const c of eT(r,s,NC))a.add(c);if(t.fuzzy)for(const c of d_(r,s,l_))a.add(c);}}return [...a].flatMap(i=>n.get(i)||[])}function nT(e,t){const n=String(t.value||"").trim(),r=Ln(n);if(!n)return null;const o=e.indexes.exactFilterDocs;switch(t.name){case "from":case "to":case "lang":case "route":case "mention":case "hashtag":case "cashtag":case "id":return new Set(o.get(tn(t.name,r))||[]);case "from_id":case "author_id":case "to_id":case "in_reply_to_id":case "conversation_id":return new Set(o.get(tn(t.name,n))||[]);case "bookmark_folder":return /^\d+$/.test(n)?new Set(o.get(tn("bookmark_folder",n))||[]):null;case "folder":return /^\d+$/.test(n)?new Set(o.get(tn("bookmark_folder",n))||[]):null;case "is":return new Set(o.get(tn("is",r))||[]);default:return null}}function rT(e,t,n){let r=null;if(n.size){const s=Rl([...n].map(l=>e.indexes.exactFilterDocs.get(tn("bookmark_folder",l))||[]));r=su(r,s);}for(const s of t.filters){const l=nT(e,s);if(l){if(s.negated){if(!r)continue;for(const c of l)r.delete(c);continue}r=su(r,l);}}const o=t.negativeLexicalTokens.length?null:QC(e,t)||JC(e,t),a=t.positiveLexicalTokens.filter(s=>!s.field),i=o||Rl(a.map(s=>tT(e,s)));return i.size&&(r=su(r,i)),r}function oT(){const e={...bp};try{if(typeof localStorage>"u")return e;const t=localStorage.getItem(FC);if(!t)return e;const n=JSON.parse(t);for(const r of Object.keys(bp)){const o=Number(n[r]);Number.isFinite(o)&&(e[r]=o);}return e}catch{return e}}function aT(e){const t=String(e||"").trim(),n=Ci.get(t);if(n)return n;const r=A1(t);if(Ci.set(t,r),Ci.size>LC){const o=Ci.keys().next().value;typeof o=="string"&&Ci.delete(o);}return r}function iT(e,t,n){const r=e.tokenFreq.get(t)||0;if(!r)return 0;const o=n.termDocFreq.get(t)||0,a=Math.max(1,n.docCount),i=Math.max(1,n.avgDocLength),s=Math.max(1,e.tokens.length),l=1.2,c=.75,h=Math.log(1+(a-o+.5)/(o+.5)),f=r+l*(1-c+c*s/i);return h*(r*(l+1))/f}function sT(e){const t=[],n=new Set(["bookmarked","liked","retweeted","reply","retweet","quote","media","images","videos","links","verified","blue_verified"]),r=new Set(["media","images","videos","links","mentions","hashtags","cashtags","engagement","polls"]),o=new Set(["replies","retweets","nativeretweets","quote","media","images","videos","links","mentions","hashtags","verified","blue_verified","twimg","native_video","consumer_video","pro_video","has_engagement"]);for(const a of e){const i=`${a.name}:${a.value}`,s=String(a.value||"").trim();if(s){if(["since","until"].includes(a.name)&&!rd(s,a.name==="until")){t.push({code:"invalid_filter_value",message:`invalid ${i}`,token:i,severity:"warn"});continue}if(["since_time","until_time","since_id","max_id","min_faves","min_likes","min_retweets","min_replies","min_bookmarks"].includes(a.name)&&!Number.isFinite(Number(s))){t.push({code:"invalid_filter_value",message:`invalid ${i}`,token:i,severity:"warn"});continue}if(a.name==="is"&&!n.has(Ln(s))){t.push({code:"unsupported_filter",message:`unsupported ${i}`,token:i,severity:"warn"});continue}if(a.name==="has"&&!r.has(Ln(s))){t.push({code:"unsupported_filter",message:`unsupported ${i}`,token:i,severity:"warn"});continue}if(["filter","include"].includes(a.name)&&!o.has(Ln(s))){t.push({code:"unsupported_filter",message:`unsupported ${i}`,token:i,severity:"warn"});continue}}}return t}function lT(e,t){const n=String(t.value||"").trim(),r=Ln(n);if(!n)return  true;const a=(()=>{switch(t.name){case "from":return e.authorScreenName===r;case "from_id":case "author_id":return e.authorId===n;case "to":return e.toUser===r;case "to_id":return e.toUserId===n;case "in_reply_to_id":return e.inReplyToId===n;case "id":return e.id===n;case "lang":return e.lang===r;case "route":return e.routeType===r;case "conversation_id":return e.conversationId===n;case "bookmark_folder":case "folder":return /^\d+$/.test(n)?e.bookmarkFolderId===n:e.bookmarkFolderName===r||e.bookmarkFolderName.includes(r);case "mention":return e.mentions.includes(r);case "hashtag":return e.hashtags.includes(r);case "cashtag":return e.cashtags.includes(r);case "source":return e.sourceText.includes(r);case "card_name":{const i=r.replace(/\s+/g,"_");return e.cardName===i||e.cardName.includes(i)}case "domain":return e.domains.some(i=>i===r||i.endsWith(`.${r}`));case "url":return e.urls.some(i=>i.includes(r));case "is":return r==="bookmarked"?e.bookmarked:r==="liked"?e.favorited:r==="retweeted"?e.retweeted:r==="reply"?e.isReply:r==="retweet"?e.isRetweet:r==="quote"?e.isQuote:r==="media"?e.hasMedia:r==="images"?e.hasImages:r==="videos"?e.hasVideo:r==="links"?e.hasLinks:r==="verified"?e.isVerified:r==="blue_verified"?e.isBlueVerified:true;case "has":return r==="media"?e.hasMedia:r==="images"?e.hasImages:r==="videos"?e.hasVideo:r==="links"?e.hasLinks:r==="mentions"?e.mentions.length>0:r==="hashtags"?e.hashtags.length>0:r==="cashtags"?e.cashtags.length>0:r==="engagement"?e.favoriteCount+e.retweetCount+e.replyCount+e.bookmarkCount>0:r==="polls"?e.cardName.includes("poll"):true;case "filter":case "include":return t.name==="include"&&r==="nativeretweets"&&!t.negated?true:r==="replies"?e.isReply:r==="retweets"?e.isRetweet||e.isQuote:r==="nativeretweets"?e.isRetweet:r==="quote"?e.isQuote:r==="media"?e.hasMedia:r==="images"?e.hasImages:r==="videos"||r==="native_video"||r==="consumer_video"||r==="pro_video"?e.hasVideo:r==="links"?e.hasLinks:r==="mentions"?e.mentions.length>0:r==="hashtags"?e.hashtags.length>0:r==="verified"?e.isVerified:r==="blue_verified"?e.isBlueVerified:r==="twimg"?e.urls.some(i=>i.includes("pbs.twimg.com")||i.includes("pic.twitter.com")):r==="has_engagement"?e.favoriteCount+e.retweetCount+e.replyCount+e.bookmarkCount>0:true;case "since":{const i=rd(n,false);return !i||!e.createdAtMs?true:e.createdAtMs>=i}case "until":{const i=rd(n,true);return !i||!e.createdAtMs?true:e.createdAtMs<i}case "since_time":{const i=Number(n)*1e3;return !Number.isFinite(i)||!e.createdAtMs?true:e.createdAtMs>=i}case "until_time":{const i=Number(n)*1e3;return !Number.isFinite(i)||!e.createdAtMs?true:e.createdAtMs<i}case "since_id":return /^\d+$/.test(e.id)&&Number(e.id)>Number(n);case "max_id":return /^\d+$/.test(e.id)&&Number(e.id)<=Number(n);case "min_faves":case "min_likes":return e.favoriteCount>=Number(n);case "min_retweets":return e.retweetCount>=Number(n);case "min_replies":return e.replyCount>=Number(n);case "min_bookmarks":return e.bookmarkCount>=Number(n);default:return  true}})();return t.negated?!a:a}function lu(e,t,n){if(n.kind==="phrase"){const a=Bo(n.value),i=qi(e,a,!!n.prefix);if(i===null){if(n.fuzzy&&a.length){const s=a[a.length-1],l=s&&s.length>=nd?d_([...new Set(e)],s,l_):[];for(const c of l){const h=[...a];h[h.length-1]=c;const f=qi(e,h,false);if(f!==null&&f<=n.slop)return {matched:true,slopUsed:f}}}return {matched:false,slopUsed:Number.POSITIVE_INFINITY}}return i>n.slop?{matched:false,slopUsed:i}:{matched:true,slopUsed:i}}const r=Bo(n.value);if(!r.length)return {matched:false,slopUsed:Number.POSITIVE_INFINITY};if(r.length===1){const a=r[0];if(!a)return {matched:false,slopUsed:Number.POSITIVE_INFINITY};let i=t.has(a);return !i&&n.prefix&&a.length>=i_&&(i=[...t.keys()].some(s=>s.startsWith(a))),!i&&n.fuzzy&&a.length>=nd&&(i=[...t.keys()].some(s=>s.startsWith(a.slice(0,s_))&&Math.abs(s.length-a.length)<=ji&&u_(s,a)<=ji)),{matched:i,slopUsed:i?0:Number.POSITIVE_INFINITY}}const o=qi(e,r,!!n.prefix);return {matched:o!==null&&o<=0,slopUsed:o??Number.POSITIVE_INFINITY}}function f_(e,t){const n=t.field?GC(e,t.field):null;if(n){const i=lu(n.tokens,n.tokenFreq,t);return {matched:i.matched,slopUsed:i.slopUsed,primaryMatched:i.matched,quotedMatched:false}}const r=lu(e.primaryTokens,e.primaryTokenFreq,t),o=e.quotedTokens.length>0?lu(e.quotedTokens,e.quotedTokenFreq,t):{matched:false,slopUsed:Number.POSITIVE_INFINITY};if(!r.matched&&!o.matched)return {matched:false,slopUsed:Number.POSITIVE_INFINITY,primaryMatched:false,quotedMatched:false};let a=Number.POSITIVE_INFINITY;return r.matched&&(a=Math.min(a,r.slopUsed)),o.matched&&(a=Math.min(a,o.slopUsed)),{matched:true,slopUsed:a,primaryMatched:r.matched,quotedMatched:o.matched}}function cT(e,t,n,r=false){if(e.kind==="phrase"){const i=(e.quoted&&e.slop===0?n.quoted_phrase_match:n.phrase_match)*e.boost/(1+Math.max(0,t));return r?i*.2:i}const o=n.term_match*e.boost;return r?o*.2:o}function uT(e,t){let n=0,r=0,o=0,a=0;for(const i of t){if(i.kind!=="phrase")continue;const s=f_(e,i);if(!s.matched||s.slopUsed!==0)continue;const c=Bo(i.value).length;c>n&&(n=c),s.primaryMatched&&c>o&&(o=c),i.quoted&&i.slop===0&&c>r&&(r=c),i.quoted&&i.slop===0&&s.primaryMatched&&c>a&&(a=c);}return {exactPhraseTerms:n,exactQuotedPhraseTerms:r,exactPrimaryPhraseTerms:o,exactPrimaryQuotedPhraseTerms:a}}function Va(e,t,n){if(t.kind==="term"||t.kind==="phrase"){const a=f_(e,t);return a.matched?{matched:true,lexicalRaw:cT(t,a.slopUsed,n,a.quotedMatched&&!a.primaryMatched)}:{matched:false,lexicalRaw:0}}if(t.kind!=="op")return {matched:true,lexicalRaw:0};if(t.op==="NOT")return {matched:!Va(e,t.child,n).matched,lexicalRaw:0};if(t.op==="AND"){const a=Va(e,t.left,n);if(!a.matched)return {matched:false,lexicalRaw:0};const i=Va(e,t.right,n);return i.matched?{matched:true,lexicalRaw:a.lexicalRaw+i.lexicalRaw}:{matched:false,lexicalRaw:0}}const r=Va(e,t.left,n),o=Va(e,t.right,n);return !r.matched&&!o.matched?{matched:false,lexicalRaw:0}:r.matched&&o.matched?{matched:true,lexicalRaw:r.lexicalRaw+o.lexicalRaw}:r.matched?r:o}function dT(e,t,n){const r=t.filter(Boolean);if(!r.length)return 0;let o=0;if(r.length>=2)for(let a=0;a<r.length-1;a+=1){const i=r.slice(a,a+2),s=qi(e.tokens,i);s===null||s>2||(o+=n.cover_bigram/(1+s));}if(r.length>=3)for(let a=0;a<r.length-2;a+=1){const i=r.slice(a,a+3),s=qi(e.tokens,i);s===null||s>3||(o+=n.cover_trigram/(1+s));}return o}function fT(e,t){if(!t.length)return e;const n=new Set(t.map(r=>String(r||"").trim()).filter(Boolean));return n.size?e.filter(r=>{const a=String(ct(r||{},"__bookmark_folder_id")||"").trim();return a?n.has(a):false}):e}function hT(e){const t=e.map(n=>KC(n));return {records:e,docs:t,rankingContext:YC(t),indexes:XC(t)}}function pT(e,t,n={}){const r=String(t||"").trim(),o=new Set((n.bookmarkFolderIds||[]).map(k=>String(k||"").trim()).filter(Boolean)),a=o.size>0;if(!r){const k=a?e.docs.filter(T=>T.bookmarkFolderId&&o.has(T.bookmarkFolderId)).map(T=>T.raw):e.records;return {records:k,highlightTerms:[],totalMatches:k.length,warnings:[],warningObjects:[],parsed:{query:"",lexicalExpression:"",filterBooleanSemantics:"global_and"}}}const i=oT(),s=aT(r),l=[...s.warnings,...sT(s.filters)],c=Date.now(),h=rT(e,s,o),f=h&&h.size<e.docs.length?[...h].sort((k,T)=>k-T).map(k=>e.docs[k]).filter(k=>!!k):e.docs,m=[];for(const k of f){if(a&&(!k.bookmarkFolderId||!o.has(k.bookmarkFolderId)))continue;let T=true;for(const Me of s.filters)if(!lT(k,Me)){T=false;break}if(!T)continue;let M=!s.hasPositiveLexical,P=0;if(s.lexicalAst){const Me=Va(k,s.lexicalAst,i);M=Me.matched,P=Me.lexicalRaw;}if(!M)continue;let F=0;for(const Me of s.positiveTerms)F+=iT(k,Me,e.rankingContext);const I=dT(k,s.orderedTerms,i),O=F*i.bm25,B=P*i.lexical,D=I*i.cover_density,v=(k.createdAtMs?k.createdAtMs/1e15:c/1e15)*i.recency,L=uT(k,s.positiveLexicalTokens),$=O+B+D+v;m.push({doc:k,score:$,weightedBm25:O,weightedLexical:B,weightedDensity:D,exactPhraseTerms:L.exactPhraseTerms,exactQuotedPhraseTerms:L.exactQuotedPhraseTerms,exactPrimaryPhraseTerms:L.exactPrimaryPhraseTerms,exactPrimaryQuotedPhraseTerms:L.exactPrimaryQuotedPhraseTerms});}m.sort((k,T)=>T.score!==k.score?T.score-k.score:T.exactPrimaryQuotedPhraseTerms!==k.exactPrimaryQuotedPhraseTerms?T.exactPrimaryQuotedPhraseTerms-k.exactPrimaryQuotedPhraseTerms:T.exactPrimaryPhraseTerms!==k.exactPrimaryPhraseTerms?T.exactPrimaryPhraseTerms-k.exactPrimaryPhraseTerms:T.exactQuotedPhraseTerms!==k.exactQuotedPhraseTerms?T.exactQuotedPhraseTerms-k.exactQuotedPhraseTerms:T.exactPhraseTerms!==k.exactPhraseTerms?T.exactPhraseTerms-k.exactPhraseTerms:T.weightedLexical!==k.weightedLexical?T.weightedLexical-k.weightedLexical:T.weightedDensity!==k.weightedDensity?T.weightedDensity-k.weightedDensity:T.doc.createdAtMs!==k.doc.createdAtMs?T.doc.createdAtMs-k.doc.createdAtMs:T.doc.id.localeCompare(k.doc.id));const g=[],_=new Set;for(const k of m){const T=[k.doc.authorId||k.doc.authorScreenName||"",k.doc.text.replace(/\s+/g," ").trim().toLowerCase()].join("::");T!=="::"&&_.has(T)||(T!=="::"&&_.add(T),g.push(k));}const b=Number(n.limit||0);return {records:(Number.isFinite(b)&&b>0?g.slice(0,Math.max(1,Math.floor(b))):g).map(k=>k.doc.raw),highlightTerms:s.highlightTerms,totalMatches:g.length,warnings:l.map(k=>k.message),warningObjects:l,parsed:{query:s.query,lexicalExpression:s.lexicalExpression,filterBooleanSemantics:s.filterBooleanSemantics}}}function xp(e,t,n={}){const r=fT(e,n.bookmarkFolderIds||[]),o=String(t||"").trim();return o?pT(hT(r),o):{records:r,highlightTerms:[],totalMatches:r.length,warnings:[],warningObjects:[],parsed:{query:"",lexicalExpression:"",filterBooleanSemantics:"global_and"}}}const h_='(function(){"use strict";function Vt(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Fe={exports:{}},Qt=Fe.exports,st;function Wt(){return st||(st=1,(function(t,e){(function(n,r){t.exports=r()})(Qt,(function(){var n=1e3,r=6e4,s=36e5,i="millisecond",o="second",a="minute",d="hour",f="day",M="week",c="month",y="quarter",l="year",x="date",A="Invalid Date",F=/^(\\d{4})[-/]?(\\d{1,2})?[-/]?(\\d{0,2})[Tt\\s]*(\\d{1,2})?:?(\\d{1,2})?:?(\\d{1,2})?[.:]?(\\d+)?$/,g=/\\[([^\\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,p={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(b){var _=["th","st","nd","rd"],u=b%100;return"["+b+(_[(u-20)%10]||_[u]||_[0])+"]"}},R=function(b,_,u){var v=String(b);return!v||v.length>=_?b:""+Array(_+1-v.length).join(u)+b},Y={s:R,z:function(b){var _=-b.utcOffset(),u=Math.abs(_),v=Math.floor(u/60),m=u%60;return(_<=0?"+":"-")+R(v,2,"0")+":"+R(m,2,"0")},m:function b(_,u){if(_.date()<u.date())return-b(u,_);var v=12*(u.year()-_.year())+(u.month()-_.month()),m=_.clone().add(v,c),k=u-m<0,T=_.clone().add(v+(k?-1:1),c);return+(-(v+(u-m)/(k?m-T:T-m))||0)},a:function(b){return b<0?Math.ceil(b)||0:Math.floor(b)},p:function(b){return{M:c,y:l,w:M,d:f,D:x,h:d,m:a,s:o,ms:i,Q:y}[b]||String(b||"").toLowerCase().replace(/s$/,"")},u:function(b){return b===void 0}},z="en",H={};H[z]=p;var X="$isDayjsObject",K=function(b){return b instanceof W||!(!b||!b[X])},C=function b(_,u,v){var m;if(!_)return z;if(typeof _=="string"){var k=_.toLowerCase();H[k]&&(m=k),u&&(H[k]=u,m=k);var T=_.split("-");if(!m&&T.length>1)return b(T[0])}else{var N=_.name;H[N]=_,m=N}return!v&&m&&(z=m),m||!v&&z},q=function(b,_){if(K(b))return b.clone();var u=typeof _=="object"?_:{};return u.date=b,u.args=arguments,new W(u)},S=Y;S.l=C,S.i=K,S.w=function(b,_){return q(b,{locale:_.$L,utc:_.$u,x:_.$x,$offset:_.$offset})};var W=(function(){function b(u){this.$L=C(u.locale,null,!0),this.parse(u),this.$x=this.$x||u.x||{},this[X]=!0}var _=b.prototype;return _.parse=function(u){this.$d=(function(v){var m=v.date,k=v.utc;if(m===null)return new Date(NaN);if(S.u(m))return new Date;if(m instanceof Date)return new Date(m);if(typeof m=="string"&&!/Z$/i.test(m)){var T=m.match(F);if(T){var N=T[2]-1||0,D=(T[7]||"0").substring(0,3);return k?new Date(Date.UTC(T[1],N,T[3]||1,T[4]||0,T[5]||0,T[6]||0,D)):new Date(T[1],N,T[3]||1,T[4]||0,T[5]||0,T[6]||0,D)}}return new Date(m)})(u),this.init()},_.init=function(){var u=this.$d;this.$y=u.getFullYear(),this.$M=u.getMonth(),this.$D=u.getDate(),this.$W=u.getDay(),this.$H=u.getHours(),this.$m=u.getMinutes(),this.$s=u.getSeconds(),this.$ms=u.getMilliseconds()},_.$utils=function(){return S},_.isValid=function(){return this.$d.toString()!==A},_.isSame=function(u,v){var m=q(u);return this.startOf(v)<=m&&m<=this.endOf(v)},_.isAfter=function(u,v){return q(u)<this.startOf(v)},_.isBefore=function(u,v){return this.endOf(v)<q(u)},_.$g=function(u,v,m){return S.u(u)?this[v]:this.set(m,u)},_.unix=function(){return Math.floor(this.valueOf()/1e3)},_.valueOf=function(){return this.$d.getTime()},_.startOf=function(u,v){var m=this,k=!!S.u(v)||v,T=S.p(u),N=function(oe,B){var J=S.w(m.$u?Date.UTC(m.$y,B,oe):new Date(m.$y,B,oe),m);return k?J:J.endOf(f)},D=function(oe,B){return S.w(m.toDate()[oe].apply(m.toDate("s"),(k?[0,0,0,0]:[23,59,59,999]).slice(B)),m)},O=this.$W,U=this.$M,V=this.$D,le="set"+(this.$u?"UTC":"");switch(T){case l:return k?N(1,0):N(31,11);case c:return k?N(1,U):N(0,U+1);case M:var ie=this.$locale().weekStart||0,me=(O<ie?O+7:O)-ie;return N(k?V-me:V+(6-me),U);case f:case x:return D(le+"Hours",0);case d:return D(le+"Minutes",1);case a:return D(le+"Seconds",2);case o:return D(le+"Milliseconds",3);default:return this.clone()}},_.endOf=function(u){return this.startOf(u,!1)},_.$set=function(u,v){var m,k=S.p(u),T="set"+(this.$u?"UTC":""),N=(m={},m[f]=T+"Date",m[x]=T+"Date",m[c]=T+"Month",m[l]=T+"FullYear",m[d]=T+"Hours",m[a]=T+"Minutes",m[o]=T+"Seconds",m[i]=T+"Milliseconds",m)[k],D=k===f?this.$D+(v-this.$W):v;if(k===c||k===l){var O=this.clone().set(x,1);O.$d[N](D),O.init(),this.$d=O.set(x,Math.min(this.$D,O.daysInMonth())).$d}else N&&this.$d[N](D);return this.init(),this},_.set=function(u,v){return this.clone().$set(u,v)},_.get=function(u){return this[S.p(u)]()},_.add=function(u,v){var m,k=this;u=Number(u);var T=S.p(v),N=function(U){var V=q(k);return S.w(V.date(V.date()+Math.round(U*u)),k)};if(T===c)return this.set(c,this.$M+u);if(T===l)return this.set(l,this.$y+u);if(T===f)return N(1);if(T===M)return N(7);var D=(m={},m[a]=r,m[d]=s,m[o]=n,m)[T]||1,O=this.$d.getTime()+u*D;return S.w(O,this)},_.subtract=function(u,v){return this.add(-1*u,v)},_.format=function(u){var v=this,m=this.$locale();if(!this.isValid())return m.invalidDate||A;var k=u||"YYYY-MM-DDTHH:mm:ssZ",T=S.z(this),N=this.$H,D=this.$m,O=this.$M,U=m.weekdays,V=m.months,le=m.meridiem,ie=function(B,J,fe,_e){return B&&(B[J]||B(v,k))||fe[J].slice(0,_e)},me=function(B){return S.s(N%12||12,B,"0")},oe=le||function(B,J,fe){var _e=B<12?"AM":"PM";return fe?_e.toLowerCase():_e};return k.replace(g,(function(B,J){return J||(function(fe){switch(fe){case"YY":return String(v.$y).slice(-2);case"YYYY":return S.s(v.$y,4,"0");case"M":return O+1;case"MM":return S.s(O+1,2,"0");case"MMM":return ie(m.monthsShort,O,V,3);case"MMMM":return ie(V,O);case"D":return v.$D;case"DD":return S.s(v.$D,2,"0");case"d":return String(v.$W);case"dd":return ie(m.weekdaysMin,v.$W,U,2);case"ddd":return ie(m.weekdaysShort,v.$W,U,3);case"dddd":return U[v.$W];case"H":return String(N);case"HH":return S.s(N,2,"0");case"h":return me(1);case"hh":return me(2);case"a":return oe(N,D,!0);case"A":return oe(N,D,!1);case"m":return String(D);case"mm":return S.s(D,2,"0");case"s":return String(v.$s);case"ss":return S.s(v.$s,2,"0");case"SSS":return S.s(v.$ms,3,"0");case"Z":return T}return null})(B)||T.replace(":","")}))},_.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},_.diff=function(u,v,m){var k,T=this,N=S.p(v),D=q(u),O=(D.utcOffset()-this.utcOffset())*r,U=this-D,V=function(){return S.m(T,D)};switch(N){case l:k=V()/12;break;case c:k=V();break;case y:k=V()/3;break;case M:k=(U-O)/6048e5;break;case f:k=(U-O)/864e5;break;case d:k=U/s;break;case a:k=U/r;break;case o:k=U/n;break;default:k=U}return m?k:S.a(k)},_.daysInMonth=function(){return this.endOf(c).$D},_.$locale=function(){return H[this.$L]},_.locale=function(u,v){if(!u)return this.$L;var m=this.clone(),k=C(u,v,!0);return k&&(m.$L=k),m},_.clone=function(){return S.w(this.$d,this)},_.toDate=function(){return new Date(this.valueOf())},_.toJSON=function(){return this.isValid()?this.toISOString():null},_.toISOString=function(){return this.$d.toISOString()},_.toString=function(){return this.$d.toUTCString()},b})(),G=W.prototype;return q.prototype=G,[["$ms",i],["$s",o],["$m",a],["$H",d],["$W",f],["$M",c],["$y",l],["$D",x]].forEach((function(b){G[b[1]]=function(_){return this.$g(_,b[0],b[1])}})),q.extend=function(b,_){return b.$i||(b(_,W,q),b.$i=!0),q},q.locale=C,q.isDayjs=K,q.unix=function(b){return q(1e3*b)},q.en=H[z],q.Ls=H,q.p={},q}))})(Fe)),Fe.exports}var Zt=Wt(),it=Vt(Zt),be,ze;be={__e:function(t,e,n,r){for(var s,i,o;e=e.__;)if((s=e.__c)&&!s.__)try{if((i=s.constructor)&&i.getDerivedStateFromError!=null&&(s.setState(i.getDerivedStateFromError(t)),o=s.__d),s.componentDidCatch!=null&&(s.componentDidCatch(t,r||{}),o=s.__d),o)return s.__E=s}catch(a){t=a}throw t}},ze=function(t){return t!=null&&t.constructor==null},typeof Promise=="function"&&Promise.prototype.then.bind(Promise.resolve());var He,Q,Ue,ot,at=0,ut=[],P=be,ct=P.__b,lt=P.__r,ft=P.diffed,ht=P.__c,dt=P.unmount,mt=P.__;function Xt(t,e){P.__h&&P.__h(Q,t,at||e),at=0;var n=Q.__H||(Q.__H={__:[],__h:[]});return t>=n.__.length&&n.__.push({}),n.__[t]}function _t(t,e){var n=Xt(He++,7);return er(n.__H,e)&&(n.__=t(),n.__H=e,n.__h=t),n.__}function Gt(){for(var t;t=ut.shift();)if(t.__P&&t.__H)try{t.__H.__h.forEach(Ce),t.__H.__h.forEach(je),t.__H.__h=[]}catch(e){t.__H.__h=[],P.__e(e,t.__v)}}P.__b=function(t){Q=null,ct&&ct(t)},P.__=function(t,e){t&&e.__k&&e.__k.__m&&(t.__m=e.__k.__m),mt&&mt(t,e)},P.__r=function(t){lt&&lt(t),He=0;var e=(Q=t.__c).__H;e&&(Ue===Q?(e.__h=[],Q.__h=[],e.__.forEach(function(n){n.__N&&(n.__=n.__N),n.u=n.__N=void 0})):(e.__h.forEach(Ce),e.__h.forEach(je),e.__h=[],He=0)),Ue=Q},P.diffed=function(t){ft&&ft(t);var e=t.__c;e&&e.__H&&(e.__H.__h.length&&(ut.push(e)!==1&&ot===P.requestAnimationFrame||((ot=P.requestAnimationFrame)||Jt)(Gt)),e.__H.__.forEach(function(n){n.u&&(n.__H=n.u),n.u=void 0})),Ue=Q=null},P.__c=function(t,e){e.some(function(n){try{n.__h.forEach(Ce),n.__h=n.__h.filter(function(r){return!r.__||je(r)})}catch(r){e.some(function(s){s.__h&&(s.__h=[])}),e=[],P.__e(r,n.__v)}}),ht&&ht(t,e)},P.unmount=function(t){dt&&dt(t);var e,n=t.__c;n&&n.__H&&(n.__H.__.forEach(function(r){try{Ce(r)}catch(s){e=s}}),n.__H=void 0,e&&P.__e(e,n.__v))};var pt=typeof requestAnimationFrame=="function";function Jt(t){var e,n=function(){clearTimeout(r),pt&&cancelAnimationFrame(e),setTimeout(t)},r=setTimeout(n,100);pt&&(e=requestAnimationFrame(n))}function Ce(t){var e=Q,n=t.__c;typeof n=="function"&&(t.__c=void 0,n()),Q=e}function je(t){var e=Q;t.__c=t.__(),Q=e}function er(t,e){return!t||t.length!==e.length||e.some(function(n,r){return n!==t[r]})}var tr=Symbol.for("preact-signals");function Re(){if(ae>1)ae--;else{for(var t,e=!1;ke!==void 0;){var n=ke;for(ke=void 0,Ke++;n!==void 0;){var r=n.o;if(n.o=void 0,n.f&=-3,!(8&n.f)&&vt(n))try{n.c()}catch(s){e||(t=s,e=!0)}n=r}}if(Ke=0,ae--,e)throw t}}function rr(t){if(ae>0)return t();ae++;try{return t()}finally{Re()}}var I=void 0,ke=void 0,ae=0,Ke=0,qe=0;function gt(t){if(I!==void 0){var e=t.n;if(e===void 0||e.t!==I)return e={i:0,S:t,p:I.s,n:void 0,t:I,e:void 0,x:void 0,r:e},I.s!==void 0&&(I.s.n=e),I.s=e,t.n=e,32&I.f&&t.S(e),e;if(e.i===-1)return e.i=0,e.n!==void 0&&(e.n.p=e.p,e.p!==void 0&&(e.p.n=e.n),e.p=I.s,e.n=void 0,I.s.n=e,I.s=e),e}}function j(t){this.v=t,this.i=0,this.n=void 0,this.t=void 0}j.prototype.brand=tr,j.prototype.h=function(){return!0},j.prototype.S=function(t){this.t!==t&&t.e===void 0&&(t.x=this.t,this.t!==void 0&&(this.t.e=t),this.t=t)},j.prototype.U=function(t){if(this.t!==void 0){var e=t.e,n=t.x;e!==void 0&&(e.x=n,t.e=void 0),n!==void 0&&(n.e=e,t.x=void 0),t===this.t&&(this.t=n)}},j.prototype.subscribe=function(t){var e=this;return De(function(){var n=e.value,r=I;I=void 0;try{t(n)}finally{I=r}})},j.prototype.valueOf=function(){return this.value},j.prototype.toString=function(){return this.value+""},j.prototype.toJSON=function(){return this.value},j.prototype.peek=function(){var t=I;I=void 0;try{return this.value}finally{I=t}},Object.defineProperty(j.prototype,"value",{get:function(){var t=gt(this);return t!==void 0&&(t.i=this.i),this.v},set:function(t){if(t!==this.v){if(Ke>100)throw new Error("Cycle detected");this.v=t,this.i++,qe++,ae++;try{for(var e=this.t;e!==void 0;e=e.x)e.t.N()}finally{Re()}}}});function yt(t){return new j(t)}function vt(t){for(var e=t.s;e!==void 0;e=e.n)if(e.S.i!==e.i||!e.S.h()||e.S.i!==e.i)return!0;return!1}function xt(t){for(var e=t.s;e!==void 0;e=e.n){var n=e.S.n;if(n!==void 0&&(e.r=n),e.S.n=e,e.i=-1,e.n===void 0){t.s=e;break}}}function wt(t){for(var e=t.s,n=void 0;e!==void 0;){var r=e.p;e.i===-1?(e.S.U(e),r!==void 0&&(r.n=e.n),e.n!==void 0&&(e.n.p=r)):n=e,e.S.n=e.r,e.r!==void 0&&(e.r=void 0),e=r}t.s=n}function pe(t){j.call(this,void 0),this.x=t,this.s=void 0,this.g=qe-1,this.f=4}(pe.prototype=new j).h=function(){if(this.f&=-3,1&this.f)return!1;if((36&this.f)==32||(this.f&=-5,this.g===qe))return!0;if(this.g=qe,this.f|=1,this.i>0&&!vt(this))return this.f&=-2,!0;var t=I;try{xt(this),I=this;var e=this.x();(16&this.f||this.v!==e||this.i===0)&&(this.v=e,this.f&=-17,this.i++)}catch(n){this.v=n,this.f|=16,this.i++}return I=t,wt(this),this.f&=-2,!0},pe.prototype.S=function(t){if(this.t===void 0){this.f|=36;for(var e=this.s;e!==void 0;e=e.n)e.S.S(e)}j.prototype.S.call(this,t)},pe.prototype.U=function(t){if(this.t!==void 0&&(j.prototype.U.call(this,t),this.t===void 0)){this.f&=-33;for(var e=this.s;e!==void 0;e=e.n)e.S.U(e)}},pe.prototype.N=function(){if(!(2&this.f)){this.f|=6;for(var t=this.t;t!==void 0;t=t.x)t.t.N()}},Object.defineProperty(pe.prototype,"value",{get:function(){if(1&this.f)throw new Error("Cycle detected");var t=gt(this);if(this.h(),t!==void 0&&(t.i=this.i),16&this.f)throw this.v;return this.v}});function bt(t){return new pe(t)}function kt(t){var e=t.u;if(t.u=void 0,typeof e=="function"){ae++;var n=I;I=void 0;try{e()}catch(r){throw t.f&=-2,t.f|=8,Be(t),r}finally{I=n,Re()}}}function Be(t){for(var e=t.s;e!==void 0;e=e.n)e.S.U(e);t.x=void 0,t.s=void 0,kt(t)}function nr(t){if(I!==this)throw new Error("Out-of-order effect");wt(this),I=t,this.f&=-2,8&this.f&&Be(this),Re()}function Te(t){this.x=t,this.u=void 0,this.s=void 0,this.o=void 0,this.f=32}Te.prototype.c=function(){var t=this.S();try{if(8&this.f||this.x===void 0)return;var e=this.x();typeof e=="function"&&(this.u=e)}finally{t()}},Te.prototype.S=function(){if(1&this.f)throw new Error("Cycle detected");this.f|=1,this.f&=-9,kt(this),xt(this),ae++;var t=I;return I=this,nr.bind(this,t)},Te.prototype.N=function(){2&this.f||(this.f|=2,this.o=ke,ke=this)},Te.prototype.d=function(){this.f|=8,1&this.f||Be(this)};function De(t){var e=new Te(t);try{e.c()}catch(n){throw e.d(),n}return e.d.bind(e)}var Ye;function ge(t,e){be[t]=e.bind(null,be[t]||function(){})}function Oe(t){Ye&&Ye(),Ye=t&&t.S()}function Tt(t){var e=this,n=t.data,r=ir(n);r.value=n;var s=_t(function(){for(var i=e,o=e.__v;o=o.__;)if(o.__c){o.__c.__$f|=4;break}var a=bt(function(){var f=r.value.value;return f===0?0:f===!0?"":f||""}),d=bt(function(){var f;return ze(a.value)||((f=e.base)==null?void 0:f.nodeType)!==3});return e.__$u.c=function(){var f;!ze(s.peek())&&((f=e.base)==null?void 0:f.nodeType)===3?e.base.data=s.peek():(e.__$f|=1,e.setState({}))},De(function(){Se||(Se=this.N),this.N=Mt,d.value&&i.base&&(i.base.data=a.value)}),a},[]);return s.value}Tt.displayName="_st",Object.defineProperties(j.prototype,{constructor:{configurable:!0,value:void 0},type:{configurable:!0,value:Tt},props:{configurable:!0,get:function(){return{data:this}}},__b:{configurable:!0,value:1}}),ge("__b",function(t,e){if(typeof e.type=="string"){var n,r=e.props;for(var s in r)if(s!=="children"){var i=r[s];i instanceof j&&(n||(e.__np=n={}),n[s]=i,r[s]=i.peek())}}t(e)}),ge("__r",function(t,e){Oe();var n,r=e.__c;r&&(r.__$f&=-2,(n=r.__$u)===void 0&&(r.__$u=n=(function(s){var i;return De(function(){i=this}),i.c=function(){r.__$f|=1,r.setState({})},i})())),Oe(n),t(e)}),ge("__e",function(t,e,n,r){Oe(),t(e,n,r)}),ge("diffed",function(t,e){Oe();var n;if(typeof e.type=="string"&&(n=e.__e)){var r=e.__np,s=e.props;if(r){var i=n.U;if(i)for(var o in i){var a=i[o];a!==void 0&&!(o in r)&&(a.d(),i[o]=void 0)}else n.U=i={};for(var d in r){var f=i[d],M=r[d];f===void 0?(f=sr(n,d,M,s),i[d]=f):f.o(M,s)}}}t(e)});function sr(t,e,n,r){var s=e in t&&t.ownerSVGElement===void 0,i=yt(n);return{o:function(o,a){i.value=o,r=a},d:De(function(){Se||(Se=this.N),this.N=Mt;var o=i.value.value;r[e]!==o&&(r[e]=o,s?t[e]=o:o?t.setAttribute(e,o):t.removeAttribute(e))})}}ge("unmount",function(t,e){if(typeof e.type=="string"){var n=e.__e;if(n){var r=n.U;if(r){n.U=void 0;for(var s in r){var i=r[s];i&&i.d()}}}}else{var o=e.__c;if(o){var a=o.__$u;a&&(o.__$u=void 0,a.d())}}t(e)}),ge("__h",function(t,e,n,r){(r<3||r===9)&&(e.__$f|=2),t(e,n,r)});function ir(t){return _t(function(){return yt(t)},[])}var Se,St=[],or=function(t){queueMicrotask(function(){queueMicrotask(t)})};function ar(){rr(function(){for(var t;t=St.shift();)Se.call(t)})}function Mt(){St.push(this)===1&&(be.requestAnimationFrame||or)(ar)}function ur(t){if(!t)return it(0);const e=t.replace(/^\\w+ (.*)$/,"$1");return it(e,"MMM DD HH:mm:ss ZZ YYYY","en")}var he={field_path_pattern:"^[a-zA-Z0-9_.]+$",known_filter_keys:["from","from_id","author_id","to","to_id","in_reply_to_id","lang","since","until","since_time","until_time","since_id","max_id","conversation_id","min_faves","min_likes","min_retweets","min_replies","min_bookmarks","url","domain","id","source","card_name","filter","include","is","has","bookmark_folder","folder","route","mention","hashtag","cashtag"],non_highlight_filters:["since","until","since_time","until_time","since_id","max_id","min_faves","min_likes","min_retweets","min_replies","min_bookmarks","id","from_id","author_id","to_id","in_reply_to_id","conversation_id"],free_text:{min_content_term_length:2,full_run_exact_min_terms:2,stop_terms:["a","an","the","and","or","but","if","then","than","to","of","in","on","for","with","by","at","from","into","onto","as","is","are","was","were","be","been","being","do","does","did","done","have","has","had","can","could","should","would","will","just","about","what","when","where","why","how","who","whom","whose","this","that","these","those","it","its","my","your","our","their","his","her","me","you","we","they","he","she","them","us","post","tweet","too"],bigram_slop:2,trigram_slop:3,fourgram_slop:4,bigram_boost:20,trigram_boost:60,fourgram_boost:140,full_run_exact_boost:320},prefix:{min_term_length:3,max_expansions:128},fuzzy:{min_term_length:5,max_edit_distance:1,prefix_root_length:4,max_expansions:64}};const $t=new RegExp(he.field_path_pattern),Nt=new Set(he.known_filter_keys),cr=new Set(he.non_highlight_filters),re=he.free_text,Ve=he.prefix,Me=he.fuzzy,lr=new Set((he.free_text.stop_terms||[]).map(t=>String(t||"").trim().toLowerCase()).filter(Boolean));function It(t){return t.kind==="term"||t.kind==="phrase"}const fr=/[\\p{L}\\p{N}_]+(?:[\'’][\\p{L}\\p{N}_]+)*/gu,hr=32,dr=Math.max(1,Number(re.min_content_term_length)),mr=Math.max(2,Number(re.full_run_exact_min_terms)),_r=Math.max(1,Number(Ve.min_term_length)),pr=Math.max(1,Number(Me.min_term_length));function ye(t,e,n=""){return{code:t,message:e,token:n||void 0,severity:"warn"}}function Et(t){const e=Number(t);return Number.isFinite(e)?Math.max(.05,Math.min(100,e)):1}function ue(t){if(!t)return[];const e=t.toLowerCase().match(fr);return e?e.map(n=>n.replace(/[\'’]/g,"")).filter(Boolean):[]}function Qe(t){const e=String(t||"").trim().toLowerCase();return!e||e.length<dr?!0:lr.has(e)}function At(t){const e=t.flatMap(r=>ue(r.value)),n=e.filter(r=>!Qe(r));return n.length?n:e}function gr(t){const e=new Set(At(t));if(!e.size)return t;const n=t.filter(r=>e.has(String(r.value||"").trim().toLowerCase()));return n.length?n:t}function We(t){let e=0;for(const n of t)for(const r of ue(n.value))Qe(r)||(e+=1);return e}function $e(t){return ue(t).join(" ").trim()}function yr(t){return Number.isFinite(t)?Math.round(t*100)/100:1}function vr(t,e){const n=t.lastIndexOf(e);if(n<=0)return{base:t,value:null};const r=t.slice(n+1);return!r||!/^\\d+(?:\\.\\d+)?$/.test(r)?{base:t,value:null}:{base:t.slice(0,n),value:r}}function xr(t){const e=String(t||""),n=[];let r=0;for(;r<e.length;){for(;r<e.length&&/\\s/.test(e[r]??"");)r+=1;if(r>=e.length)break;const s=e[r]??"";if(s==="("){n.push({kind:"lparen"}),r+=1;continue}if(s===")"){n.push({kind:"rparen"}),r+=1;continue}let i=!1;if(s==="-"){for(i=!0,r+=1;r<e.length&&/\\s/.test(e[r]??"");)r+=1;if(r>=e.length)break;if((e[r]??"")==="("){n.push({kind:"op",op:"NOT"});continue}}let o;const a=r;for(;r<e.length&&/[a-zA-Z0-9_.]/.test(e[r]??"");)r+=1;if(r>a&&(e[r]??"")===":"&&(e[r+1]??"")===\'"\'&&$t.test(e.slice(a,r))?(o=e.slice(a,r),r+=1):r=a,(e[r]??"")===\'"\'){r+=1;let l="";for(;r<e.length;){const F=e[r]??"";if(F==="\\\\"&&r+1<e.length){l+=e[r+1]??"",r+=2;continue}if(F===\'"\'){r+=1;break}l+=F,r+=1}let x=0,A=1;if((e[r]??"")==="~"){r+=1;const F=r;for(;r<e.length&&/\\d/.test(e[r]??"");)r+=1;r>F&&(x=Math.max(0,Number(e.slice(F,r))||0))}if((e[r]??"")==="^"){r+=1;const F=r;for(;r<e.length&&/[\\d.]/.test(e[r]??"");)r+=1;r>F&&(A=Et(e.slice(F,r)))}n.push({kind:"phrase",value:l.trim(),negated:i,boost:A,slop:x,field:o,quoted:!0});continue}const d=r;for(;r<e.length&&!/\\s/.test(e[r]??"")&&(e[r]??"")!=="("&&(e[r]??"")!==")";)r+=1;const f=e.slice(d,r).trim();if(!f)continue;const{base:M,value:c}=vr(f,"^"),y=M.toUpperCase();if((y==="AND"||y==="OR"||y==="NOT")&&!i){n.push({kind:"op",op:y});continue}n.push({kind:"term",value:M,negated:i,boost:c?Et(c):1,slop:0})}return n}function wr(t,e){if(e.length&&!/\\s$/.test(String(t||"")))for(let n=e.length-1;n>=0;n-=1){const r=e[n];if(!r||!It(r))continue;if(r.kind!=="term"||r.field||r.quoted)return;const s=$e(r.value);s.length>=_r&&(r.prefix=!0),s.length>=pr&&(r.fuzzy=!0);return}}function ne(t){return t?t.kind==="term"||t.kind==="phrase":!1}function br(t){const e=[];if(!t.length)return{ast:null,warnings:e};const n=[];let r=null;for(const c of t){let y=!1;if(r){const l=ne(r)||r.kind==="rparen",x=ne(c)||c.kind==="lparen"||c.kind==="op"&&c.op==="NOT";l&&x&&(y=!0)}y&&n.push({kind:"op",op:"AND"}),n.push(c),r=c}const s={OR:1,AND:2,NOT:3},i=[],o=[];for(const c of n){if(ne(c)){i.push(c);continue}if(c.kind==="lparen"){o.push(c);continue}if(c.kind==="rparen"){let y=!1;for(;o.length;){const l=o.pop();if(!l)break;if(l.kind==="lparen"){y=!0;break}i.push(l)}y||e.push(ye("boolean_syntax","unmatched closing parenthesis in query"));continue}if(c.kind==="op"){for(;o.length;){const y=o[o.length-1];if(!y||y.kind!=="op"||!(c.op==="NOT"?s[c.op]<s[y.op]:s[c.op]<=s[y.op]))break;i.push(o.pop())}o.push(c)}}for(;o.length;){const c=o.pop();if(!c)break;if(c.kind==="lparen"){e.push(ye("boolean_syntax","unmatched opening parenthesis in query"));continue}i.push(c)}const a=[];for(const c of i){if(ne(c)){a.push(c);continue}if(c.kind!=="op")continue;if(c.op==="NOT"){const x=a.pop();if(!x){e.push(ye("boolean_syntax","dangling NOT operator in query","NOT"));continue}a.push({kind:"op",op:"NOT",child:x});continue}const y=a.pop(),l=a.pop();if(!l||!y){e.push(ye("boolean_syntax",`dangling ${c.op} operator in query`,c.op));continue}a.push({kind:"op",op:c.op,left:l,right:y})}if(a.length===1)return{ast:a[0]??null,warnings:e};const d=t.filter(ne);if(!d.length)return{ast:null,warnings:e};const f=d[0];if(!f)return{ast:null,warnings:e};let M=f;for(let c=1;c<d.length;c+=1){const y=d[c];y&&(M={kind:"op",op:"AND",left:M,right:y})}return e.push(ye("boolean_syntax","query boolean expression was malformed; fell back to implicit AND between lexical terms")),{ast:M,warnings:e}}function Ft(t,e){const n=[],r=(s,i)=>{if(s){if(ne(s)){i===e&&n.push(s);return}if(s.op==="NOT"){r(s.child,!i);return}r(s.left,i),r(s.right,i)}};return r(t,!0),n}function Ze(t,e,n){if(t){if(!ne(t)&&t.op===e){Ze(t.left,e,n),Ze(t.right,e,n);return}n.push(t)}}function Xe(t){if(!t)return"";if(ne(t)){let r=t.kind==="phrase"?`"${t.value}"`:t.value;return t.prefix&&(r+="*"),t.kind==="phrase"&&t.slop>0&&(r+=`~${t.slop}`),Math.abs(t.boost-1)>1e-9&&(r+=`^${t.boost}`),t.field&&(r=`${t.field}:${r}`),r}if(t.op==="NOT"){const r=Xe(t.child);return r?`NOT (${r})`:"NOT (?)"}const e=[];return Ze(t,t.op,e),e.map(r=>{const s=Xe(r);return s?!ne(r)&&r.op!==t.op?`(${s})`:s:""}).filter(Boolean).join(` ${t.op} `)}function kr(t){return!t.field&&t.kind==="term"&&ue(t.value).length===1}function Tr(t){var i,o,a,d,f,M,c,y;if(t.length<=1)return t;const e=[],n=new Set,r=l=>{const x=`${l.kind}|${l.field||""}|${l.value}|${l.slop}|${l.boost}`;n.has(x)||(n.add(x),e.push(l))},s=(l,x)=>{const A=l.reduce((F,g)=>F+g.boost,0)/l.length;return yr(x*A)};for(const l of gr(t))r(l);for(let l=0;l<=t.length-2;l+=1){const x=t.slice(l,l+2);We(x)<2||r({kind:"phrase",value:x.map(A=>A.value).join(" "),slop:re.bigram_slop,boost:s(x,re.bigram_boost),prefix:!!((i=x[x.length-1])!=null&&i.prefix),fuzzy:!!((o=x[x.length-1])!=null&&o.fuzzy)})}for(let l=0;l<=t.length-3;l+=1){const x=t.slice(l,l+3);We(x)<2||r({kind:"phrase",value:x.map(A=>A.value).join(" "),slop:re.trigram_slop,boost:s(x,re.trigram_boost),prefix:!!((a=x[x.length-1])!=null&&a.prefix),fuzzy:!!((d=x[x.length-1])!=null&&d.fuzzy)})}for(let l=0;l<=t.length-4;l+=1){const x=t.slice(l,l+4);We(x)<2||r({kind:"phrase",value:x.map(A=>A.value).join(" "),slop:re.fourgram_slop,boost:s(x,re.fourgram_boost),prefix:!!((f=x[x.length-1])!=null&&f.prefix),fuzzy:!!((M=x[x.length-1])!=null&&M.fuzzy)})}return t.length>=mr&&r({kind:"phrase",value:t.map(l=>l.value).join(" "),slop:0,boost:s(t,re.full_run_exact_boost),prefix:!!((c=t[t.length-1])!=null&&c.prefix),fuzzy:!!((y=t[t.length-1])!=null&&y.fuzzy)}),e}function Sr(t,e){if(!e.length)return;if(e.length===1){t.push(e[0]),e.length=0;return}const n=Tr(e);t.push({kind:"lparen"}),n.forEach((r,s)=>{s>0&&t.push({kind:"op",op:"OR"}),t.push(r)}),t.push({kind:"rparen"}),e.length=0}function Mr(t){const e=new Set,n=[];for(const r of t)for(const s of ue(r))!s||e.has(s)||(e.add(s),n.push(s));return n}function $r(t,e){const n=new Set;for(const r of t)for(const s of ue(r.value))s&&!Qe(s)&&n.add(s);for(const r of e)if(!(r.negated||cr.has(r.name)))for(const s of ue(r.value))s&&n.add(s);return[...n].slice(0,hr)}function Nr(t){var g;const e=xr(t);wr(t,e);const n=[],r=[],s=[],i=[],o=[],a=[],d=()=>{if(i.length){const p=At(i);a.push(...p),o.push(...p)}Sr(s,i)};for(const p of e){if(!It(p)){d(),s.push(p);continue}const R=String(p.value||"").trim();if(!R)continue;let Y=p.kind,z=R,H=(g=p.field)==null?void 0:g.trim(),X=!1;if(H&&Nt.has(H)){n.push({name:H,value:R,negated:p.negated}),d();continue}if(p.kind==="term"&&R.startsWith("@")&&R.length>1){const C=$e(R.slice(1));if(C){n.push({name:"from",value:C,negated:p.negated}),d();continue}}else if(p.kind==="term"&&R.startsWith("#")&&R.length>1){const C=$e(R.slice(1));C&&(n.push({name:"hashtag",value:C,negated:p.negated}),Y="term",z=C,X=!0)}else if(p.kind==="term"&&R.startsWith("$")&&R.length>1){const C=$e(R.slice(1));C&&(n.push({name:"cashtag",value:C,negated:p.negated}),Y="term",z=C,X=!0)}else if(p.kind==="term"&&R.includes(":")){const[C,...q]=R.split(":"),S=String(C||"").trim().toLowerCase(),W=q.join(":").trim();if(Nt.has(S)){if(!W){r.push(R);continue}n.push({name:S,value:W,negated:p.negated}),d();continue}S&&W&&$t.test(S)&&(Y="term",z=W,H=S)}const K={kind:Y,value:Y==="term"?$e(z):z.trim(),boost:p.boost,slop:p.slop,field:H||void 0,quoted:!!p.quoted,prefix:!!p.prefix,fuzzy:!!p.fuzzy};if(K.value){if(p.negated){d(),s.push({kind:"op",op:"NOT"}),s.push(K);continue}if(!X&&kr(K)){i.push(K);continue}if(d(),!K.field){const C=ue(K.value);a.push(...C),o.push(...C)}s.push(K)}}d();const{ast:f,warnings:M}=br(s),c=Ft(f,!0),y=Ft(f,!1),l=a.filter(Boolean),x=Mr(o),A=$r(c,n),F=r.map(p=>ye("unsupported_token",`unsupported token: ${p}`,p));return{query:String(t||""),lexicalTokens:s,lexicalAst:f,lexicalExpression:Xe(f),positiveLexicalTokens:c,negativeLexicalTokens:y,positiveTerms:x,filters:n,unsupported:r,orderedTerms:l,highlightTerms:A,warnings:[...M,...F],hasPositiveLexical:c.length>0,filterBooleanSemantics:"global_and"}}const Ir=/[\\p{L}\\p{N}_]+(?:[\'’][\\p{L}\\p{N}_]+)*/gu,Ct={bm25:1,lexical:1,cover_density:1,recency:0,term_match:1,phrase_match:8,quoted_phrase_match:256,cover_bigram:10,cover_trigram:30},Er="twe_raw_search_ranking_v1",Ar=128,Rt=Math.max(1,Number(Ve.min_term_length)),Fr=Math.max(8,Number(Ve.max_expansions)),Ge=Math.max(1,Number(Me.min_term_length)),Ne=Math.max(0,Number(Me.max_edit_distance)),qt=Math.max(1,Number(Me.prefix_root_length)),Dt=Math.max(8,Number(Me.max_expansions)),Ot=3,Cr=4,Rr=.65,qr=1.5,Ie=new Map,Pt=new WeakMap;function h(t,e){const n=e.split(".");let r=t;for(const s of n){if(!r||typeof r!="object")return null;r=r[s]}return r}function w(t){return typeof t=="string"?t:""}function Ee(t){if(typeof t=="boolean")return t;if(typeof t=="number")return t>0;if(typeof t=="string"){const e=t.trim().toLowerCase();return e==="1"||e==="true"||e==="yes"}return!1}function Pe(t){if(typeof t=="number"&&Number.isFinite(t))return t;if(typeof t=="string"){const e=Number(t);if(Number.isFinite(e))return e}return 0}function L(t){return t.trim().toLowerCase()}function ce(t){if(!t)return[];const e=t.toLowerCase().match(Ir);return e?e.map(n=>n.replace(/[\'’]/g,"")).filter(Boolean):[]}function Je(t){const e=new Map;for(let n=0;n<t.length;n+=1){const r=t[n];r&&e.set(r,(e.get(r)||0)+1)}return e}function Lt(t,e){if(t===e)return 0;if(!t.length)return e.length;if(!e.length)return t.length;const n=new Array(e.length+1),r=new Array(e.length+1);for(let s=0;s<=e.length;s+=1)n[s]=s;for(let s=1;s<=t.length;s+=1){r[0]=s;for(let i=1;i<=e.length;i+=1){const o=t[s-1]===e[i-1]?0:1;r[i]=Math.min((n[i]??0)+1,(r[i-1]??0)+1,(n[i-1]??0)+o)}for(let i=0;i<=e.length;i+=1)n[i]=r[i]??0}return n[e.length]??Math.max(t.length,e.length)}function et(t,e=!1){if(!t)return 0;if(/^\\d{4}-\\d{2}-\\d{2}$/.test(t)){const r=e?"T23:59:59.999Z":"T00:00:00.000Z",s=Date.parse(`${t}${r}`);return Number.isFinite(s)?s:0}const n=Date.parse(t);return Number.isFinite(n)?n:0}function Dr(t){return t?t.replace(/<[^>]+>/g," ").replace(/\\s+/g," ").trim():""}function Or(t){const e=new Set,n=r=>{if(Array.isArray(r))for(const s of r){if(!s||typeof s!="object")continue;const i=s,o=w(i.expanded_url).trim(),a=w(i.display_url).trim(),d=w(i.url).trim();o&&e.add(o),a&&e.add(a),d&&e.add(d)}};return n(h(t,"legacy.entities.urls")),n(h(t,"legacy.entities.media")),n(h(t,"legacy.entities.description.urls")),n(h(t,"legacy.entities.url.urls")),[...e]}function tt(t,e,n="text"){const r=h(t,e);if(!Array.isArray(r))return[];const s=new Set;for(const i of r){if(!i||typeof i!="object")continue;const a=L(w(i[n]).trim());a&&s.add(a)}return[...s]}function Pr(t){const e=(Array.isArray(h(t,"legacy.extended_entities.media"))?h(t,"legacy.extended_entities.media"):h(t,"legacy.entities.media"))||[];if(!Array.isArray(e))return[];const n=new Set;for(const r of e){if(!r||typeof r!="object")continue;const i=L(w(r.type).trim());i&&n.add(i)}return[...n]}function Lr(t){const e=h(t,"article.article_results.result.content_state.blocks");if(!Array.isArray(e))return[];const n=[];for(const r of e){if(!r||typeof r!="object")continue;const s=w(r.text).trim();s&&n.push(s)}return n}function zr(t){const e=new Set;for(const n of t)try{const r=n.startsWith("http")?n:`https://${n}`,s=new URL(r).hostname.replace(/^www\\./,"").toLowerCase();s&&e.add(s)}catch{}return[...e]}function Ae(t,e,n=!1){if(!e.length)return 0;const r=e[0],s=[];for(let o=0;o<t.length;o+=1)t[o]===r&&s.push(o);if(!s.length)return null;let i=null;for(const o of s){let a=o,d=!0;for(let y=1;y<e.length;y+=1){const l=e[y],x=n&&y===e.length-1;let A=-1;for(let F=a+1;F<t.length;F+=1){const g=t[F];if(x&&l&&(g!=null&&g.startsWith(l))||g===l){A=F;break}}if(A<0){d=!1;break}a=A}if(!d)continue;const f=a-o,M=Math.max(0,e.length-1),c=Math.max(0,f-M);(i===null||c<i)&&(i=c)}return i}function zt(t){const e=t||{},n=w(h(e,"rest_id"))||w(h(e,"legacy.id_str"))||w(h(e,"id_str"))||`${Math.random().toString(36).slice(2)}`,r=w(h(e,"note_tweet.note_tweet_results.result.text"))||[w(h(e,"article.article_results.result.title")),w(h(e,"article.article_results.result.preview_text")),...Lr(e)].map(ee=>ee.trim()).filter(Boolean).filter((ee,mn,_n)=>_n.indexOf(ee)===mn).join(`\n\n`)||w(h(e,"legacy.full_text"))||w(h(e,"legacy.text"))||w(h(e,"legacy.description")),s=w(h(e,"quoted_status_result.result.note_tweet.note_tweet_results.result.text"))||w(h(e,"quoted_status_result.result.legacy.full_text"))||w(h(e,"quoted_status_result.result.legacy.text"))||w(h(e,"quoted_status_result.result.article.article_results.result.title"))||w(h(e,"quoted_status_result.result.article.article_results.result.preview_text")),i=L(w(h(e,"quoted_status_result.result.core.user_results.result.core.screen_name"))),o=w(h(e,"quoted_status_result.result.core.user_results.result.core.name")),a=L(w(h(e,"core.user_results.result.core.screen_name"))||w(h(e,"core.screen_name"))),d=w(h(e,"core.user_results.result.core.name"))||w(h(e,"core.name")),f=w(h(e,"core.user_results.result.rest_id"))||w(h(e,"rest_id")),M=w(h(e,"legacy.created_at"))||w(h(e,"core.created_at")),c=M?Number(ur(M)||0):Number(h(e,"article.article_results.result.metadata.first_published_at_secs")||0)*1e3,y=Dr(w(h(e,"legacy.source"))),l=L(w(h(e,"card.card_platform.card_name"))||w(h(e,"card.name"))||w(h(e,"__card_name"))),x=w(h(e,"__bookmark_folder_id")).trim(),A=w(h(e,"__bookmark_folder_name")).trim(),F=Or(e),g=zr(F),p=tt(e,"legacy.entities.user_mentions","screen_name"),R=tt(e,"legacy.entities.hashtags"),Y=tt(e,"legacy.entities.symbols"),z=Pr(e),H=se(h(e,"twe_relationship_fields.subject_screen_names")).map(ee=>L(ee)),X=se(h(e,"twe_relationship_fields.subject_user_ids")).map(ee=>String(ee).trim()),K=se(h(e,"twe_relationship_fields.relation_types")).map(ee=>L(ee)),C=L(w(h(e,"legacy.in_reply_to_screen_name"))),q=w(h(e,"legacy.in_reply_to_user_id_str")).trim(),S=w(h(e,"legacy.in_reply_to_status_id_str")).trim(),W=w(h(e,"legacy.conversation_id_str"))||w(h(e,"conversation_id_str")),G=L(w(h(e,"legacy.lang"))),b=L(w(h(e,"__route_type"))),_=z.length>0,u=z.includes("photo"),v=z.includes("video")||z.includes("animated_gif"),m=F.length>0,k=!!h(e,"legacy.retweeted_status_result")||w(h(e,"legacy.full_text")).startsWith("RT @"),T=!!h(e,"quoted_status_result"),N=!!S,D=L(w(h(e,"core.user_results.result.verification.verified_type")))==="verified"||L(w(h(e,"verification.verified_type")))==="verified",O=Ee(h(e,"core.user_results.result.is_blue_verified"))||Ee(h(e,"is_blue_verified")),U=Ee(h(e,"legacy.favorited")),V=Ee(h(e,"legacy.retweeted")),le=Ee(h(e,"legacy.bookmarked")),ie=Pe(h(e,"legacy.favorite_count")),me=Pe(h(e,"legacy.retweet_count")),oe=Pe(h(e,"legacy.reply_count")),B=Pe(h(e,"legacy.bookmark_count")),J=[r,s,y,a,d,i,o,C,x,A,l,...H,...X,...K,...p,...R,...Y,...F,...g].filter(Boolean).join(" ").trim(),fe=[r,y,a,d,C,x,A,l,...H,...X,...K,...p,...R,...Y,...F,...g].filter(Boolean).join(" ").trim(),_e=[s,i,o].filter(Boolean).join(" ").trim(),Kt=ce(J),Bt=ce(fe),Yt=ce(_e),fn=Je(Kt),hn=Je(Bt),dn=Je(Yt);return{raw:t,id:n,text:J,primaryText:fe,quotedText:_e,tokens:Kt,primaryTokens:Bt,quotedTokens:Yt,tokenFreq:fn,primaryTokenFreq:hn,quotedTokenFreq:dn,createdAtMs:c,authorScreenName:a,authorId:f,toUser:C,toUserId:q,inReplyToId:S,conversationId:W,lang:G,routeType:b,sourceText:L(y),cardName:l,bookmarkFolderId:x,bookmarkFolderName:L(A),mentions:p,hashtags:R,cashtags:Y,urls:F.map(ee=>ee.toLowerCase()),domains:g,favoriteCount:ie,retweetCount:me,replyCount:oe,bookmarkCount:B,favorited:U,retweeted:V,bookmarked:le,hasMedia:_,hasImages:u,hasVideo:v,hasLinks:m,isReply:N,isRetweet:k,isQuote:T,isVerified:D,isBlueVerified:O,fieldSearchCache:new Map}}function Hr(t){if(!t||typeof t!="object")return zt(t);const e=Pt.get(t);if(e)return e;const n=zt(t);return Pt.set(t,n),n}function se(t){if(t==null)return[];if(typeof t=="string"){const e=t.trim();return e?[e]:[]}return typeof t=="number"||typeof t=="boolean"?[String(t)]:Array.isArray(t)?t.flatMap(e=>se(e)):typeof t=="object"?Object.values(t).flatMap(e=>se(e)):[]}function Ur(t,e){switch(e){case"text":return t.text;case"id":return t.id;case"author_screen_name":return t.authorScreenName;case"author_id":return t.authorId;case"to_user":return t.toUser;case"to_user_id":return t.toUserId;case"conversation_id":return t.conversationId;case"lang":return t.lang;case"route":case"route_type":return t.routeType;case"source":case"source_text":return t.sourceText;case"card_name":return t.cardName;case"bookmark_folder_id":return t.bookmarkFolderId;case"bookmark_folder_name":return t.bookmarkFolderName;case"subject_screen_names":return se(h(t.raw||{},"twe_relationship_fields.subject_screen_names"));case"subject_user_ids":return se(h(t.raw||{},"twe_relationship_fields.subject_user_ids"));case"relation_types":return se(h(t.raw||{},"twe_relationship_fields.relation_types"));case"mentions":return t.mentions;case"hashtags":return t.hashtags;case"cashtags":return t.cashtags;case"urls":return t.urls;case"domains":return t.domains;default:return h(t.raw||{},e)}}function jr(t,e){const n=String(e||"").trim();if(!n)return{text:t.text,tokens:t.tokens,tokenFreq:t.tokenFreq};const r=t.fieldSearchCache.get(n);if(r)return r;const i=se(Ur(t,n)).join(" ").trim(),o=ce(i),a=new Map;for(const f of o)a.set(f,(a.get(f)||0)+1);const d={text:i,tokens:o,tokenFreq:a};return t.fieldSearchCache.set(n,d),d}function Kr(t){const e=new Map;let n=0;for(const r of t){n+=r.tokens.length;for(const s of r.tokenFreq.keys())e.set(s,(e.get(s)||0)+1)}return{docCount:t.length,avgDocLength:t.length?n/t.length:1,termDocFreq:e}}function E(t,e,n){if(!e)return;const r=t.get(e);if(r){r.push(n);return}t.set(e,[n])}function $(t,e){return`${t}:${e}`}function Br(t){const e=new Map,n=new Map;for(let r=0;r<t.length;r+=1){const s=t[r];if(s){for(const i of s.tokenFreq.keys())E(e,i,r);E(n,$("id",s.id),r),E(n,$("from",s.authorScreenName),r),E(n,$("from_id",s.authorId),r),E(n,$("author_id",s.authorId),r),E(n,$("to",s.toUser),r),E(n,$("to_id",s.toUserId),r),E(n,$("in_reply_to_id",s.inReplyToId),r),E(n,$("conversation_id",s.conversationId),r),E(n,$("lang",s.lang),r),E(n,$("route",s.routeType),r),E(n,$("bookmark_folder",s.bookmarkFolderId),r);for(const i of s.mentions)E(n,$("mention",i),r);for(const i of s.hashtags)E(n,$("hashtag",i),r);for(const i of s.cashtags)E(n,$("cashtag",i),r);s.hasMedia&&E(n,$("is","media"),r),s.hasImages&&E(n,$("is","images"),r),s.hasVideo&&E(n,$("is","videos"),r),s.hasLinks&&E(n,$("is","links"),r),s.bookmarked&&E(n,$("is","bookmarked"),r),s.favorited&&E(n,$("is","liked"),r),s.retweeted&&E(n,$("is","retweeted"),r),s.isReply&&E(n,$("is","reply"),r),s.isRetweet&&E(n,$("is","retweet"),r),s.isQuote&&E(n,$("is","quote"),r),s.isVerified&&E(n,$("is","verified"),r),s.isBlueVerified&&E(n,$("is","blue_verified"),r)}}return{tokenDocs:e,exactFilterDocs:n,tokenVocabulary:[...e.keys()].sort()}}function rt(t,e){const n=e instanceof Set?e:new Set(e);if(!t)return new Set(n);const r=new Set;for(const s of t)n.has(s)&&r.add(s);return r}function Le(t){const e=new Set;for(const n of t)for(const r of n)e.add(r);return e}function Yr(t,e){if(!t.length||!e.length)return[];const n=t.length<=e.length?t:e,r=t.length<=e.length?e:t,s=new Set(r),i=[];for(const o of n)s.has(o)&&i.push(o);return i}function Vr(t,e){const n=e.orderedTerms.filter(Boolean);if(n.length<Ot)return null;const r=[];for(let i=0;i<n.length-1;i+=1){const o=t.indexes.tokenDocs.get(n[i]||"")||[],a=t.indexes.tokenDocs.get(n[i+1]||"")||[],d=Yr(o,a);d.length&&r.push(d)}if(!r.length)return null;const s=Le(r);return!s.size||s.size>=t.docs.length?null:s}function Qr(t,e){var c;const n=e.positiveTerms.filter(Boolean);if(n.length<Ot)return null;const r=Math.max(1,t.rankingContext.docCount),s=n.map(y=>({term:y,docFreq:t.rankingContext.termDocFreq.get(y)||0})).filter(y=>y.docFreq>0).sort((y,l)=>y.docFreq!==l.docFreq?y.docFreq-l.docFreq:y.term.localeCompare(l.term));if(!s.length)return null;const i=s.filter(y=>y.docFreq/r<=Rr),o=i.length?i:s,a=((c=o[0])==null?void 0:c.docFreq)||0,d=a>0?o.filter(y=>y.docFreq<=a*qr):o,f=(d.length?d:o).slice(0,Cr);if(!f.length)return null;const M=Le(f.map(y=>t.indexes.tokenDocs.get(y.term)||[]));return!M.size||M.size>=t.docs.length?null:M}function Wr(t,e,n){if(!e||e.length<Rt)return[];const r=[];for(const s of t)if(s.startsWith(e)&&(r.push(s),r.length>=n))break;return r}function Ht(t,e,n){if(!e||e.length<Ge||Ne<=0)return[];const r=e.slice(0,qt),s=[];for(const i of t)if(i.startsWith(r)&&!(Math.abs(i.length-e.length)>Ne)&&!(Lt(i,e)>Ne)&&(s.push(i),s.length>=n))break;return s}function Zr(t,e){const n=t.indexes.tokenDocs,r=t.indexes.tokenVocabulary,s=ce(e.value);if(!s.length)return[];const i=new Set;for(let o=0;o<s.length;o+=1){const a=s[o];if(!(!a||(i.add(a),!(o===s.length-1)))){if(e.prefix)for(const f of Wr(r,a,Fr))i.add(f);if(e.fuzzy)for(const f of Ht(r,a,Dt))i.add(f)}}return[...i].flatMap(o=>n.get(o)||[])}function Xr(t,e){const n=String(e.value||"").trim(),r=L(n);if(!n)return null;const s=t.indexes.exactFilterDocs;switch(e.name){case"from":case"to":case"lang":case"route":case"mention":case"hashtag":case"cashtag":case"id":return new Set(s.get($(e.name,r))||[]);case"from_id":case"author_id":case"to_id":case"in_reply_to_id":case"conversation_id":return new Set(s.get($(e.name,n))||[]);case"bookmark_folder":return/^\\d+$/.test(n)?new Set(s.get($("bookmark_folder",n))||[]):null;case"folder":return/^\\d+$/.test(n)?new Set(s.get($("bookmark_folder",n))||[]):null;case"is":return new Set(s.get($("is",r))||[]);default:return null}}function Gr(t,e,n){let r=null;if(n.size){const a=Le([...n].map(d=>t.indexes.exactFilterDocs.get($("bookmark_folder",d))||[]));r=rt(r,a)}for(const a of e.filters){const d=Xr(t,a);if(d){if(a.negated){if(!r)continue;for(const f of d)r.delete(f);continue}r=rt(r,d)}}const s=e.negativeLexicalTokens.length?null:Vr(t,e)||Qr(t,e),i=e.positiveLexicalTokens.filter(a=>!a.field),o=s||Le(i.map(a=>Zr(t,a)));return o.size&&(r=rt(r,o)),r}function Jr(){const t={...Ct};try{if(typeof localStorage>"u")return t;const e=localStorage.getItem(Er);if(!e)return t;const n=JSON.parse(e);for(const r of Object.keys(Ct)){const s=Number(n[r]);Number.isFinite(s)&&(t[r]=s)}return t}catch{return t}}function en(t){const e=String(t||"").trim(),n=Ie.get(e);if(n)return n;const r=Nr(e);if(Ie.set(e,r),Ie.size>Ar){const s=Ie.keys().next().value;typeof s=="string"&&Ie.delete(s)}return r}function tn(t,e,n){const r=t.tokenFreq.get(e)||0;if(!r)return 0;const s=n.termDocFreq.get(e)||0,i=Math.max(1,n.docCount),o=Math.max(1,n.avgDocLength),a=Math.max(1,t.tokens.length),d=1.2,f=.75,M=Math.log(1+(i-s+.5)/(s+.5)),c=r+d*(1-f+f*a/o);return M*(r*(d+1))/c}function rn(t){const e=[],n=new Set(["bookmarked","liked","retweeted","reply","retweet","quote","media","images","videos","links","verified","blue_verified"]),r=new Set(["media","images","videos","links","mentions","hashtags","cashtags","engagement","polls"]),s=new Set(["replies","retweets","nativeretweets","quote","media","images","videos","links","mentions","hashtags","verified","blue_verified","twimg","native_video","consumer_video","pro_video","has_engagement"]);for(const i of t){const o=`${i.name}:${i.value}`,a=String(i.value||"").trim();if(a){if(["since","until"].includes(i.name)&&!et(a,i.name==="until")){e.push({code:"invalid_filter_value",message:`invalid ${o}`,token:o,severity:"warn"});continue}if(["since_time","until_time","since_id","max_id","min_faves","min_likes","min_retweets","min_replies","min_bookmarks"].includes(i.name)&&!Number.isFinite(Number(a))){e.push({code:"invalid_filter_value",message:`invalid ${o}`,token:o,severity:"warn"});continue}if(i.name==="is"&&!n.has(L(a))){e.push({code:"unsupported_filter",message:`unsupported ${o}`,token:o,severity:"warn"});continue}if(i.name==="has"&&!r.has(L(a))){e.push({code:"unsupported_filter",message:`unsupported ${o}`,token:o,severity:"warn"});continue}if(["filter","include"].includes(i.name)&&!s.has(L(a))){e.push({code:"unsupported_filter",message:`unsupported ${o}`,token:o,severity:"warn"});continue}}}return e}function nn(t,e){const n=String(e.value||"").trim(),r=L(n);if(!n)return!0;const i=(()=>{switch(e.name){case"from":return t.authorScreenName===r;case"from_id":case"author_id":return t.authorId===n;case"to":return t.toUser===r;case"to_id":return t.toUserId===n;case"in_reply_to_id":return t.inReplyToId===n;case"id":return t.id===n;case"lang":return t.lang===r;case"route":return t.routeType===r;case"conversation_id":return t.conversationId===n;case"bookmark_folder":case"folder":return/^\\d+$/.test(n)?t.bookmarkFolderId===n:t.bookmarkFolderName===r||t.bookmarkFolderName.includes(r);case"mention":return t.mentions.includes(r);case"hashtag":return t.hashtags.includes(r);case"cashtag":return t.cashtags.includes(r);case"source":return t.sourceText.includes(r);case"card_name":{const o=r.replace(/\\s+/g,"_");return t.cardName===o||t.cardName.includes(o)}case"domain":return t.domains.some(o=>o===r||o.endsWith(`.${r}`));case"url":return t.urls.some(o=>o.includes(r));case"is":return r==="bookmarked"?t.bookmarked:r==="liked"?t.favorited:r==="retweeted"?t.retweeted:r==="reply"?t.isReply:r==="retweet"?t.isRetweet:r==="quote"?t.isQuote:r==="media"?t.hasMedia:r==="images"?t.hasImages:r==="videos"?t.hasVideo:r==="links"?t.hasLinks:r==="verified"?t.isVerified:r==="blue_verified"?t.isBlueVerified:!0;case"has":return r==="media"?t.hasMedia:r==="images"?t.hasImages:r==="videos"?t.hasVideo:r==="links"?t.hasLinks:r==="mentions"?t.mentions.length>0:r==="hashtags"?t.hashtags.length>0:r==="cashtags"?t.cashtags.length>0:r==="engagement"?t.favoriteCount+t.retweetCount+t.replyCount+t.bookmarkCount>0:r==="polls"?t.cardName.includes("poll"):!0;case"filter":case"include":return e.name==="include"&&r==="nativeretweets"&&!e.negated?!0:r==="replies"?t.isReply:r==="retweets"?t.isRetweet||t.isQuote:r==="nativeretweets"?t.isRetweet:r==="quote"?t.isQuote:r==="media"?t.hasMedia:r==="images"?t.hasImages:r==="videos"||r==="native_video"||r==="consumer_video"||r==="pro_video"?t.hasVideo:r==="links"?t.hasLinks:r==="mentions"?t.mentions.length>0:r==="hashtags"?t.hashtags.length>0:r==="verified"?t.isVerified:r==="blue_verified"?t.isBlueVerified:r==="twimg"?t.urls.some(o=>o.includes("pbs.twimg.com")||o.includes("pic.twitter.com")):r==="has_engagement"?t.favoriteCount+t.retweetCount+t.replyCount+t.bookmarkCount>0:!0;case"since":{const o=et(n,!1);return!o||!t.createdAtMs?!0:t.createdAtMs>=o}case"until":{const o=et(n,!0);return!o||!t.createdAtMs?!0:t.createdAtMs<o}case"since_time":{const o=Number(n)*1e3;return!Number.isFinite(o)||!t.createdAtMs?!0:t.createdAtMs>=o}case"until_time":{const o=Number(n)*1e3;return!Number.isFinite(o)||!t.createdAtMs?!0:t.createdAtMs<o}case"since_id":return/^\\d+$/.test(t.id)&&Number(t.id)>Number(n);case"max_id":return/^\\d+$/.test(t.id)&&Number(t.id)<=Number(n);case"min_faves":case"min_likes":return t.favoriteCount>=Number(n);case"min_retweets":return t.retweetCount>=Number(n);case"min_replies":return t.replyCount>=Number(n);case"min_bookmarks":return t.bookmarkCount>=Number(n);default:return!0}})();return e.negated?!i:i}function nt(t,e,n){if(n.kind==="phrase"){const i=ce(n.value),o=Ae(t,i,!!n.prefix);if(o===null){if(n.fuzzy&&i.length){const a=i[i.length-1],d=a&&a.length>=Ge?Ht([...new Set(t)],a,Dt):[];for(const f of d){const M=[...i];M[M.length-1]=f;const c=Ae(t,M,!1);if(c!==null&&c<=n.slop)return{matched:!0,slopUsed:c}}}return{matched:!1,slopUsed:Number.POSITIVE_INFINITY}}return o>n.slop?{matched:!1,slopUsed:o}:{matched:!0,slopUsed:o}}const r=ce(n.value);if(!r.length)return{matched:!1,slopUsed:Number.POSITIVE_INFINITY};if(r.length===1){const i=r[0];if(!i)return{matched:!1,slopUsed:Number.POSITIVE_INFINITY};let o=e.has(i);return!o&&n.prefix&&i.length>=Rt&&(o=[...e.keys()].some(a=>a.startsWith(i))),!o&&n.fuzzy&&i.length>=Ge&&(o=[...e.keys()].some(a=>a.startsWith(i.slice(0,qt))&&Math.abs(a.length-i.length)<=Ne&&Lt(a,i)<=Ne)),{matched:o,slopUsed:o?0:Number.POSITIVE_INFINITY}}const s=Ae(t,r,!!n.prefix);return{matched:s!==null&&s<=0,slopUsed:s??Number.POSITIVE_INFINITY}}function Ut(t,e){const n=e.field?jr(t,e.field):null;if(n){const o=nt(n.tokens,n.tokenFreq,e);return{matched:o.matched,slopUsed:o.slopUsed,primaryMatched:o.matched,quotedMatched:!1}}const r=nt(t.primaryTokens,t.primaryTokenFreq,e),s=t.quotedTokens.length>0?nt(t.quotedTokens,t.quotedTokenFreq,e):{matched:!1,slopUsed:Number.POSITIVE_INFINITY};if(!r.matched&&!s.matched)return{matched:!1,slopUsed:Number.POSITIVE_INFINITY,primaryMatched:!1,quotedMatched:!1};let i=Number.POSITIVE_INFINITY;return r.matched&&(i=Math.min(i,r.slopUsed)),s.matched&&(i=Math.min(i,s.slopUsed)),{matched:!0,slopUsed:i,primaryMatched:r.matched,quotedMatched:s.matched}}function sn(t,e,n,r=!1){if(t.kind==="phrase"){const o=(t.quoted&&t.slop===0?n.quoted_phrase_match:n.phrase_match)*t.boost/(1+Math.max(0,e));return r?o*.2:o}const s=n.term_match*t.boost;return r?s*.2:s}function on(t,e){let n=0,r=0,s=0,i=0;for(const o of e){if(o.kind!=="phrase")continue;const a=Ut(t,o);if(!a.matched||a.slopUsed!==0)continue;const f=ce(o.value).length;f>n&&(n=f),a.primaryMatched&&f>s&&(s=f),o.quoted&&o.slop===0&&f>r&&(r=f),o.quoted&&o.slop===0&&a.primaryMatched&&f>i&&(i=f)}return{exactPhraseTerms:n,exactQuotedPhraseTerms:r,exactPrimaryPhraseTerms:s,exactPrimaryQuotedPhraseTerms:i}}function ve(t,e,n){if(e.kind==="term"||e.kind==="phrase"){const i=Ut(t,e);return i.matched?{matched:!0,lexicalRaw:sn(e,i.slopUsed,n,i.quotedMatched&&!i.primaryMatched)}:{matched:!1,lexicalRaw:0}}if(e.kind!=="op")return{matched:!0,lexicalRaw:0};if(e.op==="NOT")return{matched:!ve(t,e.child,n).matched,lexicalRaw:0};if(e.op==="AND"){const i=ve(t,e.left,n);if(!i.matched)return{matched:!1,lexicalRaw:0};const o=ve(t,e.right,n);return o.matched?{matched:!0,lexicalRaw:i.lexicalRaw+o.lexicalRaw}:{matched:!1,lexicalRaw:0}}const r=ve(t,e.left,n),s=ve(t,e.right,n);return!r.matched&&!s.matched?{matched:!1,lexicalRaw:0}:r.matched&&s.matched?{matched:!0,lexicalRaw:r.lexicalRaw+s.lexicalRaw}:r.matched?r:s}function an(t,e,n){const r=e.filter(Boolean);if(!r.length)return 0;let s=0;if(r.length>=2)for(let i=0;i<r.length-1;i+=1){const o=r.slice(i,i+2),a=Ae(t.tokens,o);a===null||a>2||(s+=n.cover_bigram/(1+a))}if(r.length>=3)for(let i=0;i<r.length-2;i+=1){const o=r.slice(i,i+3),a=Ae(t.tokens,o);a===null||a>3||(s+=n.cover_trigram/(1+a))}return s}function un(t){const e=t.map(n=>Hr(n));return{records:t,docs:e,rankingContext:Kr(e),indexes:Br(e)}}function cn(t,e,n={}){const r=String(e||"").trim(),s=new Set((n.bookmarkFolderIds||[]).map(g=>String(g||"").trim()).filter(Boolean)),i=s.size>0;if(!r){const g=i?t.docs.filter(p=>p.bookmarkFolderId&&s.has(p.bookmarkFolderId)).map(p=>p.raw):t.records;return{records:g,highlightTerms:[],totalMatches:g.length,warnings:[],warningObjects:[],parsed:{query:"",lexicalExpression:"",filterBooleanSemantics:"global_and"}}}const o=Jr(),a=en(r),d=[...a.warnings,...rn(a.filters)],f=Date.now(),M=Gr(t,a,s),c=M&&M.size<t.docs.length?[...M].sort((g,p)=>g-p).map(g=>t.docs[g]).filter(g=>!!g):t.docs,y=[];for(const g of c){if(i&&(!g.bookmarkFolderId||!s.has(g.bookmarkFolderId)))continue;let p=!0;for(const G of a.filters)if(!nn(g,G)){p=!1;break}if(!p)continue;let R=!a.hasPositiveLexical,Y=0;if(a.lexicalAst){const G=ve(g,a.lexicalAst,o);R=G.matched,Y=G.lexicalRaw}if(!R)continue;let z=0;for(const G of a.positiveTerms)z+=tn(g,G,t.rankingContext);const H=an(g,a.orderedTerms,o),X=z*o.bm25,K=Y*o.lexical,C=H*o.cover_density,q=(g.createdAtMs?g.createdAtMs/1e15:f/1e15)*o.recency,S=on(g,a.positiveLexicalTokens),W=X+K+C+q;y.push({doc:g,score:W,weightedBm25:X,weightedLexical:K,weightedDensity:C,exactPhraseTerms:S.exactPhraseTerms,exactQuotedPhraseTerms:S.exactQuotedPhraseTerms,exactPrimaryPhraseTerms:S.exactPrimaryPhraseTerms,exactPrimaryQuotedPhraseTerms:S.exactPrimaryQuotedPhraseTerms})}y.sort((g,p)=>p.score!==g.score?p.score-g.score:p.exactPrimaryQuotedPhraseTerms!==g.exactPrimaryQuotedPhraseTerms?p.exactPrimaryQuotedPhraseTerms-g.exactPrimaryQuotedPhraseTerms:p.exactPrimaryPhraseTerms!==g.exactPrimaryPhraseTerms?p.exactPrimaryPhraseTerms-g.exactPrimaryPhraseTerms:p.exactQuotedPhraseTerms!==g.exactQuotedPhraseTerms?p.exactQuotedPhraseTerms-g.exactQuotedPhraseTerms:p.exactPhraseTerms!==g.exactPhraseTerms?p.exactPhraseTerms-g.exactPhraseTerms:p.weightedLexical!==g.weightedLexical?p.weightedLexical-g.weightedLexical:p.weightedDensity!==g.weightedDensity?p.weightedDensity-g.weightedDensity:p.doc.createdAtMs!==g.doc.createdAtMs?p.doc.createdAtMs-g.doc.createdAtMs:p.doc.id.localeCompare(g.doc.id));const l=[],x=new Set;for(const g of y){const p=[g.doc.authorId||g.doc.authorScreenName||"",g.doc.text.replace(/\\s+/g," ").trim().toLowerCase()].join("::");p!=="::"&&x.has(p)||(p!=="::"&&x.add(p),l.push(g))}const A=Number(n.limit||0);return{records:(Number.isFinite(A)&&A>0?l.slice(0,Math.max(1,Math.floor(A))):l).map(g=>g.doc.raw),highlightTerms:a.highlightTerms,totalMatches:l.length,warnings:d.map(g=>g.message),warningObjects:d,parsed:{query:a.query,lexicalExpression:a.lexicalExpression,filterBooleanSemantics:a.filterBooleanSemantics}}}function de(){return typeof performance<"u"&&typeof performance.now=="function"?performance.now():Date.now()}const xe=new Map,te=new Map,Z=new Set;function we(t){self.postMessage(t)}function ln(t){return t instanceof Error?t.message:String(t)}function jt(t,e){const n=e.map(s=>s.record),r=new Map;return e.forEach((s,i)=>{r.set(s.record,s.id||`row-${i}`)}),{rows:e,prepared:un(n),idByRecord:r}}self.onmessage=t=>{const e=t.data;if(!e||typeof e!="object")return;if(e.type==="search:cancel"){Z.add(e.requestId);return}if(e.type==="search:dispose"){e.scopeKey?(xe.delete(e.scopeKey),te.delete(e.scopeKey)):(xe.clear(),te.clear()),Z.delete(e.requestId);return}const n=de();try{if(e.type==="search:set-corpus"){const r=jt(e.scopeKey,e.records||[]);xe.set(e.scopeKey,r),we({type:"search:corpus-ready",requestId:e.requestId,scopeKey:e.scopeKey,corpusSize:r.rows.length,elapsedMs:de()-n});return}if(e.type==="search:begin-corpus"){if(Z.has(e.requestId)){te.delete(e.scopeKey),Z.delete(e.requestId);return}xe.delete(e.scopeKey),te.set(e.scopeKey,[]);return}if(e.type==="search:append-corpus"){if(Z.has(e.requestId)){te.delete(e.scopeKey),Z.delete(e.requestId);return}const r=te.get(e.scopeKey);if(!r){te.set(e.scopeKey,[...e.records||[]]);return}r.push(...e.records||[]);return}if(e.type==="search:commit-corpus"){if(Z.has(e.requestId)){te.delete(e.scopeKey),Z.delete(e.requestId);return}const r=te.get(e.scopeKey);if(!r){we({type:"search:error",requestId:e.requestId,scopeKey:e.scopeKey,error:`Search corpus chunks not ready for scope: ${e.scopeKey}`,elapsedMs:de()-n});return}te.delete(e.scopeKey);const s=jt(e.scopeKey,r);xe.set(e.scopeKey,s),we({type:"search:corpus-ready",requestId:e.requestId,scopeKey:e.scopeKey,corpusSize:s.rows.length,elapsedMs:de()-n});return}if(e.type==="search:query"){const r=xe.get(e.scopeKey);if(!r){we({type:"search:error",requestId:e.requestId,scopeKey:e.scopeKey,error:`Search corpus not ready for scope: ${e.scopeKey}`,elapsedMs:de()-n});return}if(Z.has(e.requestId)){Z.delete(e.requestId);return}const s=cn(r.prepared,e.query,e.options);if(Z.has(e.requestId)){Z.delete(e.requestId);return}const i=s.records.map((o,a)=>{var d;return r.idByRecord.get(o)||((d=r.rows[a])==null?void 0:d.id)||`row-${a}`});we({type:"search:result",requestId:e.requestId,scopeKey:e.scopeKey,query:e.query,ids:i,elapsedMs:de()-n,corpusSize:r.rows.length,result:{highlightTerms:s.highlightTerms,totalMatches:s.totalMatches,warnings:s.warnings,warningObjects:s.warningObjects,parsed:s.parsed}})}}catch(r){we({type:"search:error",requestId:e.requestId,scopeKey:"scopeKey"in e?e.scopeKey:void 0,error:ln(r),elapsedMs:de()-n})}}})();\n',Sp=typeof self<"u"&&self.Blob&&new Blob([h_],{type:"text/javascript;charset=utf-8"});function mT(e){let t;try{if(t=Sp&&(self.URL||self.webkitURL).createObjectURL(Sp),!t)throw "";const n=new Worker(t,{name:e==null?void 0:e.name});return n.addEventListener("error",()=>{(self.URL||self.webkitURL).revokeObjectURL(t);}),n}catch{return new Worker("data:text/javascript;charset=utf-8,"+encodeURIComponent(h_),{name:e==null?void 0:e.name})}finally{t&&(self.URL||self.webkitURL).revokeObjectURL(t);}}const gT="twe_search_worker_request_delay_ms_v1",yT=5e3;function Cp(e){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?`${e}-${crypto.randomUUID()}`:`${e}-${Date.now()}-${Math.random().toString(36).slice(2,10)}`}function _T(e){if(e.type!=="search:query")return 0;try{if(typeof localStorage>"u")return 0;const t=localStorage.getItem(gT);if(!t)return 0;const n=Number(t);return !Number.isFinite(n)||n<=0?0:Math.min(yT,Math.floor(n))}catch{return 0}}class wT{constructor(){je(this,"worker",null);je(this,"pending",new Map);je(this,"available",false);try{this.worker=new mT,this.worker.onmessage=t=>this.handleMessage(t.data),this.worker.onerror=t=>{Ga("search",!1),Do("search:worker:error");for(const[n,r]of this.pending)r.reject(new Error(t.message||`Search worker error: ${n}`));this.pending.clear();},this.available=!0,Ga("search",!0);}catch(t){this.worker=null,this.available=false,Ga("search",false),Be({kind:"worker",name:"search-create-failed",tags:{error:t instanceof Error?t.message:String(t)}});}}isAvailable(){return this.available&&!!this.worker}async setCorpus(t,n){const r=Cp("corpus");return this.request({type:"search:set-corpus",requestId:r,scopeKey:t,records:n})}beginCorpus(t){this.worker&&this.worker.postMessage({type:"search:begin-corpus",requestId:t.requestId,scopeKey:t.scopeKey,expectedCount:t.expectedCount});}appendCorpus(t){this.worker&&this.worker.postMessage({type:"search:append-corpus",requestId:t.requestId,scopeKey:t.scopeKey,records:t.records});}async commitCorpus(t,n){return this.request({type:"search:commit-corpus",requestId:n,scopeKey:t})}async query(t){const n=t.requestId||Cp("query"),r=await this.request({type:"search:query",requestId:n,scopeKey:t.scopeKey,query:t.query,options:t.options});if(r.type==="search:result")return r;throw r.type==="search:error"?new Error(r.error):new Error(`Unexpected search worker response: ${r.type}`)}cancel(t){const n=this.pending.get(t);n&&(n.reject(new Error(`Search request cancelled: ${t}`)),this.pending.delete(t)),this.worker&&(this.worker.postMessage({type:"search:cancel",requestId:t}),Do("search:cancelled"),Be({kind:"search",name:"query-cancel",tags:{requestId:t,pending:!!n}}));}dispose(){var t;for(const[n,r]of this.pending)r.reject(new Error(`Search worker disposed: ${n}`));this.pending.clear(),(t=this.worker)==null||t.terminate(),this.worker=null,this.available=false;}request(t){if(!this.worker)return Promise.reject(new Error("Search worker unavailable"));const n=qe(),r=_T(t);return new Promise((o,a)=>{this.pending.set(t.requestId,{resolve:o,reject:a,startedAt:n});const i=()=>{var s;if(!this.pending.has(t.requestId)){r>0&&Be({kind:"search",name:"delayed-query-cancelled-before-post",value:r,tags:{requestId:t.requestId,type:t.type}});return}(s=this.worker)==null||s.postMessage(t);};r>0?globalThis.setTimeout(i,r):i();})}handleMessage(t){const n=this.pending.get(t.requestId);if(!n){Do("search:stale-response");return}this.pending.delete(t.requestId),Be({kind:"search",name:t.type==="search:result"?"worker-query":"worker-corpus",durationMs:qe()-n.startedAt,tags:{type:t.type,corpusSize:"corpusSize"in t?t.corpusSize:void 0,resultCount:t.type==="search:result"?t.ids.length:void 0}}),n.resolve(t);}}function p_(e,t){if(!e||typeof e!="object")return;const n=t.split(".");let r=e;for(const o of n){if(!r||typeof r!="object")return;r=r[o];}return r}function Tp(e){return e==null?"":typeof e=="number"&&Number.isFinite(e)?e:typeof e=="boolean"?e?1:0:e instanceof Date?e.getTime():String(e).toLowerCase()}function bT(e,t){const n=Tp(e),r=Tp(t);return typeof n=="number"&&typeof r=="number"?n-r:String(n).localeCompare(String(r),void 0,{numeric:true,sensitivity:"base"})}function m_(e){const t=[];for(const n of e){if("columns"in n&&Array.isArray(n.columns)){t.push(...m_(n.columns));continue}t.push(n);}return t}function vT(e){return "id"in e&&typeof e.id=="string"&&e.id?e.id:"accessorKey"in e&&typeof e.accessorKey=="string"?e.accessorKey:""}function Mp(e,t,n){if("accessorFn"in e&&typeof e.accessorFn=="function")return e.accessorFn(t,n);if("accessorKey"in e){if(typeof e.accessorKey=="string")return p_(t,e.accessorKey);if(typeof e.accessorKey=="number"&&Array.isArray(t))return t[e.accessorKey]}}function kT(e){if(typeof e=="number"&&Number.isFinite(e))return e;const t=Number(e);return Number.isFinite(t)?t:null}function xT(e){if(e==null||e==="")return null;const t=kT(e);if(t!==null)return t>1e12?t:t*1e3;if(typeof e=="string"){const n=Number(Ja(e)||0);if(Number.isFinite(n)&&n>0)return n;const r=Date.parse(e);if(Number.isFinite(r))return r}return null}function Rp(e){if(!e||typeof e!="object")return 0;const t=["twe_private_fields.created_at","created_at","legacy.created_at","core.created_at","article.published_at","__seen_at"];for(const n of t){const r=p_(e,n),o=xT(r);if(o!==null&&o>0)return o}return 0}const Ip=1200,qs=6e3,cu=320,ST=1e3;function Na(e,t=[]){return {records:[],highlightTerms:[],totalMatches:0,warnings:t,warningObjects:t.map(n=>({code:"unsupported_token",message:n,severity:"warn"})),parsed:{query:e,lexicalExpression:"",filterBooleanSemantics:"global_and"}}}function Ep(e){return {records:e.records,highlightTerms:[],totalMatches:e.totalMatches,warnings:[],warningObjects:[],parsed:{query:e.query,lexicalExpression:"",filterBooleanSemantics:"global_and"}}}function CT(){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?`search-${crypto.randomUUID()}`:`search-${Date.now()}-${Math.random().toString(36).slice(2,10)}`}function Ba(e){switch(e){case "idle":return "search idle";case "unavailable":return "search worker unavailable";case "preparing-corpus":return "preparing search index";case "ready":return "search ready";case "querying":return "querying local index";case "degraded":return "search degraded";case "cancelled":return "search cancelled";case "failed":return "search failed";default:return "search"}}function Sn(e,t){let n=e;for(const r of t.split(".")){if(!n||typeof n!="object")return;n=n[r];}return n}function TT(e){if(!e||typeof e!="object")return e;const t=e;return {__typename:t.__typename,rest_id:t.rest_id,id_str:t.id_str,__bookmark_folder_id:t.__bookmark_folder_id,__bookmark_folder_name:t.__bookmark_folder_name,__route_type:t.__route_type,twe_relationship_fields:t.twe_relationship_fields,note_tweet:t.note_tweet,article:t.article,quoted_status_result:t.quoted_status_result,card:t.card,views:t.views,core:t.core,verification:t.verification,is_blue_verified:t.is_blue_verified,legacy:{id_str:Sn(t,"legacy.id_str"),full_text:Sn(t,"legacy.full_text"),text:Sn(t,"legacy.text"),description:Sn(t,"legacy.description"),created_at:Sn(t,"legacy.created_at"),source:Sn(t,"legacy.source"),lang:Sn(t,"legacy.lang"),entities:Sn(t,"legacy.entities"),extended_entities:Sn(t,"legacy.extended_entities"),in_reply_to_screen_name:Sn(t,"legacy.in_reply_to_screen_name"),in_reply_to_user_id_str:Sn(t,"legacy.in_reply_to_user_id_str"),in_reply_to_status_id_str:Sn(t,"legacy.in_reply_to_status_id_str"),conversation_id_str:Sn(t,"legacy.conversation_id_str"),favorite_count:Sn(t,"legacy.favorite_count"),retweet_count:Sn(t,"legacy.retweet_count"),reply_count:Sn(t,"legacy.reply_count"),bookmark_count:Sn(t,"legacy.bookmark_count"),quote_count:Sn(t,"legacy.quote_count"),favorited:Sn(t,"legacy.favorited"),retweeted:Sn(t,"legacy.retweeted"),bookmarked:Sn(t,"legacy.bookmarked"),retweeted_status_result:Sn(t,"legacy.retweeted_status_result")}}}function g_(e){var r,o,a,i,s;const t=e.raw_ref_key||e.entity_id,n=[e.primary_text,e.quoted_text,e.auxiliary_text].filter(l=>typeof l=="string"&&l.trim().length>0).join(`

`);return {rest_id:t,id_str:t,__bookmark_folder_id:e.folder_id,__bookmark_folder_name:e.folder_name,__route_type:e.route_type,core:{user_results:{result:{rest_id:e.author_id,core:{screen_name:e.author_screen_name,name:e.author_screen_name},legacy:{screen_name:e.author_screen_name,name:e.author_screen_name}}}},legacy:{id_str:t,full_text:n,text:n,created_at:e.created_at_ms?new Date(e.created_at_ms).toUTCString():void 0,lang:e.lang,favorite_count:(r=e.numeric_json)==null?void 0:r.favorite_count,retweet_count:(o=e.numeric_json)==null?void 0:o.retweet_count,reply_count:(a=e.numeric_json)==null?void 0:a.reply_count,bookmark_count:(i=e.numeric_json)==null?void 0:i.bookmark_count,quote_count:(s=e.numeric_json)==null?void 0:s.quote_count}}}function MT(e,t){return e.map((n,r)=>({id:n.raw_ref_key||n.entity_id||`search-doc-${t+r}`,record:g_(n)}))}function RT({title:e,viewStateKey:t,fullscreen:n,onFullscreenChange:r,records:o,searchDocuments:a,searchDocumentsLoading:i=false,searchDocumentsLoaded:s=false,searchDocumentTotalCount:l=0,searchDocumentsBlockedReason:c,loadSearchDocuments:h,loadSearchDocumentChunks:f,folderScopeSourceBacked:m=false,resultSourceDescriptor:g,resultSourceTotalCount:_,resultEntityType:b,hydrateRecordsByIds:C,columns:k,alternateViews:T}){const[M,P]=De(""),[F,I]=De(""),[O,B]=De([]),[D,v]=De({}),[L,$]=De([]),[Me,Z]=De("all"),[re,J]=De(false),[le,he]=De("table"),[pe,ge]=De(null),[z,ue]=De([]),[Pe,ce]=De(()=>({key:"",ids:new Set})),Ee=_t(null),Qe=_t(""),X=_t(""),ne=_t(""),j=_t(""),se=_t(""),_e=_t(null),we=_t(""),Ye=_t(""),We=F.trim(),Se=We.length>0,Tt=O.length>0,jt=Tt&&m&&!Se,Wt=Se,Gt=(Se||Tt&&!jt)&&(s||!!(a!=null&&a.length)),Rt=Se&&Gt,et=Rt&&!(a!=null&&a.length)&&l>0&&!!f,at=It(()=>{const Te=M.trim();if(!Te)return 60;const Ae=/["():]|^[@#$-]/.test(Te),At=Te.split(/\s+/).filter(Boolean).length;return Ae||At>1?180:240},[M]),wt=n??re,Ce=Te=>{const Ae=typeof Te=="function"?Te(wt):Te;n===void 0&&J(Ae),r==null||r(Ae);},ht=It(()=>`twe_table_view_state_v2:${t||e}`,[e,t]),it=It(()=>a!=null&&a.length||l>0?`${ht}:search-documents:${l||(a==null?void 0:a.length)||0}`:`${ht}:records:${o.length}`,[o.length,ht,l,a==null?void 0:a.length]),yt=It(()=>[...O].sort().join(","),[O]),Oe=It(()=>o.map((Te,Ae)=>Oo(Te,Ae)),[o]),ke=It(()=>{if(a!=null&&a.length){const Te=a[0],Ae=a[a.length-1];return [it,"docs",a.length,(Te==null?void 0:Te.id)||"",(Te==null?void 0:Te.updated_at_ms)||"",(Ae==null?void 0:Ae.id)||"",(Ae==null?void 0:Ae.updated_at_ms)||""].join(":")}return et?[it,"docs-stream",l].join(":"):[it,"records",o.length,Oe[0]||"",Oe[Oe.length-1]||""].join(":")},[Oe,o.length,it,l,a,et]),E=`${ke}:${We}:${yt}`,x=It(()=>{const Te=new Map;return o.forEach((Ae,At)=>{for(const nt of aa(Ae,At))Te.set(nt,Ae);Te.set(Oe[At]||`row-${At}`,Ae);}),z.forEach((Ae,At)=>{for(const nt of aa(Ae,At))Te.set(nt,Ae);}),Te},[Oe,o,z]),R=_t(x);Je(()=>{R.current=x;},[x]),Je(()=>{Be({kind:"viewer",name:"table-record-lookup-ids",value:x.size,tags:{title:e,viewStateKey:t||"",records:o.length,searchHydratedRecords:z.length}});},[x.size,o.length,z.length,e,t]),Je(()=>{ue([]),ce({key:"",ids:new Set}),we.current="",Ye.current="",_e.current=null,X.current="",ne.current="";},[it]);const U=It(()=>Rt?(a==null?void 0:a.map((Te,Ae)=>({id:Te.raw_ref_key||Te.entity_id||`search-doc-${Ae}`,record:g_(Te)})))??[]:[],[a,Rt]),V=It(()=>!Se||Gt?[]:o.map((Te,Ae)=>({id:Oe[Ae]||`row-${Ae}`,record:TT(Te)})),[Se,Oe,o,Gt]),be=Gt?U:V,ie=_t(be),Le=_t(O),Ne=_t(C);Je(()=>{Be({kind:"search",name:"worker-corpus-candidates",value:be.length,tags:{title:e,viewStateKey:t||"",source:Gt?"search-documents":"records",records:o.length,searchDocuments:(a==null?void 0:a.length)??0,searchDocumentTotalCount:l,searchDocumentsLoaded:s,searchDocumentsLoading:i,searchDocumentsBlocked:!!c}});},[o.length,a==null?void 0:a.length,l,c,s,i,Gt,e,t,be.length]),Je(()=>{ie.current=be;},[be]),Je(()=>{!Se||!h||c||s||i||a!=null&&a.length||h().catch(Te=>{Be({kind:"search",name:"lazy-search-documents-error",tags:{error:Te instanceof Error?Te.message:String(Te)}});});},[Tt,Se,jt,h,c,a==null?void 0:a.length,s,i]),Je(()=>{Le.current=O;},[O]),Je(()=>{Ne.current=C;},[C]);const tt=It(()=>{if(jt||Se||!Tt||!(a!=null&&a.length))return [];const Te=new Set(O);return a.filter(Ae=>Ae.folder_id&&Te.has(Ae.folder_id)).sort((Ae,At)=>{const nt=At.observed_at_ms||At.created_at_ms||At.updated_at_ms||0,Lt=Ae.observed_at_ms||Ae.created_at_ms||Ae.updated_at_ms||0;return nt!==Lt?nt-Lt:(At.raw_ref_key||At.entity_id).localeCompare(Ae.raw_ref_key||Ae.entity_id)})},[jt,Tt,Se,a,O]),fe=It(()=>tt.map(Te=>Te.raw_ref_key||Te.entity_id).filter(Boolean).slice(0,qs),[tt]),Ve=It(()=>{if(!fe.length)return "";const Te=fe[0]||"",Ae=fe[fe.length-1]||"";return `${it}:folders:${yt}:${fe.length}:${Te}:${Ae}`},[fe,it,yt]);Je(()=>{if(Se||jt||!Tt||!fe.length||!C||we.current===Ve||Ye.current===Ve)return;we.current=Ve,ce(nt=>nt.key===Ve?nt:{key:Ve,ids:new Set});let Te=false;const Ae=nt=>{nt.length&&ue(Lt=>{const Mt=new Set(Lt.flatMap((kt,ft)=>aa(kt,ft))),lt=nt.filter((kt,ft)=>{const Xt=aa(kt,ft);return Xt.some(Qt=>Mt.has(Qt))?false:(Xt.forEach(Qt=>Mt.add(Qt)),true)});return lt.length?[...Lt,...lt].slice(-qs):Lt});};return (async()=>{const nt=qe();let Lt=0;const Mt=fe.filter(lt=>!R.current.has(lt));for(let lt=0;lt<Mt.length&&!Te;lt+=cu){const kt=Mt.slice(lt,lt+cu),ft=await C(kt);if(Te||we.current!==Ve)return;Lt+=ft.length,ce(Xt=>{if(Xt.key!==Ve)return Xt;const Qt=new Set(Xt.ids);return kt.forEach(In=>Qt.add(In)),{key:Ve,ids:Qt}}),Ae(ft),await new Promise(Xt=>globalThis.setTimeout(Xt,0));}!Te&&we.current===Ve&&(Ye.current=Ve,we.current=""),Be({kind:"viewer",name:"folder-result-hydrate",durationMs:qe()-nt,value:Lt,tags:{selectedFolders:yt,totalMatches:fe.length,missingIds:Mt.length,batchSize:cu}});})().catch(nt=>{we.current===Ve&&(we.current=""),Be({kind:"viewer",name:"folder-result-hydrate-error",tags:{error:nt instanceof Error?nt.message:String(nt)}});}),()=>{Te=true,we.current===Ve&&(we.current="");}},[Ve,fe,jt,Tt,Se,C,yt]),Je(()=>{const Te=new wT;return Ee.current=Te,()=>{Te.dispose(),Ee.current=null,j.current="";}},[]),Je(()=>{j.current="",se.current="";},[it]),Je(()=>{const Te=Ee.current;if(!Se||!(Te!=null&&Te.isAvailable())||!ie.current.length||j.current===ke||se.current===ke)return;let Ae=false;const At=()=>{if(Ae||j.current===ke)return;se.current=ke;const Lt=qe(),Mt=Te.setCorpus(it,ie.current);_e.current=Mt,Mt.then(lt=>{Ae||lt.type==="search:corpus-ready"&&(j.current=ke,Be({kind:"search",name:"corpus-warm-ready",durationMs:qe()-Lt,tags:{corpusSize:lt.corpusSize}}));}).catch(lt=>{Ae||Be({kind:"search",name:"corpus-warm-error",durationMs:qe()-Lt,tags:{error:lt instanceof Error?lt.message:String(lt)}});}).finally(()=>{se.current===ke&&(se.current=""),_e.current===Mt&&(_e.current=null);});},nt=globalThis.setTimeout(At,120);return ()=>{Ae=true,globalThis.clearTimeout(nt);}},[ke,Se,it]),Je(()=>{if(!Wt){X.current="",ne.current="",ge(null);return}if(c){ge({key:E,pending:false,phase:"degraded",result:Na(We,[c]),error:c}),Do("search:large-corpus-blocked");return}const Te=Ee.current;if(h&&!s&&!(a!=null&&a.length)){ge({key:E,pending:true,phase:"preparing-corpus",result:Na(We)});return}if(ne.current===E||X.current===E)return;X.current=E;const Ae=CT();Qe.current=Ae;const At=qe(),nt=We;let Lt=false;if(!(Te!=null&&Te.isAvailable())){if(o.length<=1500||!(a!=null&&a.length)){const kt=xp(o??[],nt,{bookmarkFolderIds:Le.current});ne.current=E,X.current="";const ft=kt.records.map((Xt,Qt)=>qy(Oo(Xt,Qt)));ge({key:E,pending:false,phase:"unavailable",result:kt,resultIds:ft,error:"Search worker unavailable; used bounded main-thread fallback."});return}const lt=a!=null&&a.length?"Search worker unavailable; large-corpus indexed folder/search hydration was blocked.":"Search worker unavailable; large-corpus main-thread search was blocked.";ge({key:E,pending:false,phase:"unavailable",result:Na(nt,[lt]),error:lt}),X.current="",Do("search:large-fallback-blocked");return}return ge(lt=>({key:E,pending:true,phase:j.current===ke?"querying":"preparing-corpus",result:(lt==null?void 0:lt.key)===E?lt.result:null})),(async()=>{if(j.current!==ke){const lt=qe();let kt=null;if(se.current===ke&&_e.current)try{kt=await _e.current;}catch{kt=null;}if((!kt||kt.type!=="search:corpus-ready")&&et&&f){let ft=0;if(Te.beginCorpus({scopeKey:it,requestId:Ae,expectedCount:l}),(await f({chunkSize:ST,isCancelled:()=>Lt||Qe.current!==Ae,onChunk:(Qt,In)=>{if(Lt||Qe.current!==Ae)return;const mn=MT(Qt,ft);ft+=mn.length,Te.appendCorpus({scopeKey:it,requestId:Ae,records:mn}),Be({kind:"search",name:"chunked-corpus-transfer",value:In.loaded,tags:{totalCount:In.totalCount,chunkRows:mn.length,scopeKey:it}});}})).cancelled||Lt||Qe.current!==Ae){Do("search:chunked-corpus-cancelled");return}kt=await Te.commitCorpus(it,Ae);}if((!kt||kt.type!=="search:corpus-ready")&&(kt=await Te.setCorpus(it,ie.current)),Qe.current!==Ae){Do("search:stale-corpus-ignored");return}kt.type==="search:corpus-ready"&&(j.current=ke,ge(ft=>(ft==null?void 0:ft.key)===E?{...ft,pending:true,phase:"querying"}:ft),Be({kind:"search",name:"corpus-ready",durationMs:qe()-lt,tags:{corpusSize:kt.corpusSize}}));}return await Te.query({scopeKey:it,query:nt,options:{bookmarkFolderIds:Le.current,limit:Ip},requestId:Ae})})().then(lt=>{if(!lt){X.current===E&&(X.current="");return}if(Qe.current!==Ae){X.current===E&&(X.current=""),Do("search:stale-ignored");return}const kt=R.current,ft=lt.ids.map(mn=>kt.get(mn)).filter(mn=>!!mn);ge({key:E,pending:false,phase:"ready",result:{...lt.result,records:ft},resultIds:lt.ids}),ne.current=E,X.current===E&&(X.current="");const Xt=Se?Ip:qs,Qt=Ne.current,In=Qt?lt.ids.filter(mn=>!kt.has(mn)).slice(0,Xt):[];if(In.length){const mn=qe();Qt==null||Qt(In).then(Vt=>{if(Qe.current!==Ae)return;const dn=new Map(R.current);Vt.forEach((en,kn)=>{for(const xn of aa(en,kn))dn.set(xn,en);}),ue(en=>{const kn=new Set(en.flatMap((Br,Qr)=>aa(Br,Qr))),xn=Vt.filter((Br,Qr)=>{const mr=aa(Br,Qr);return mr.some(po=>kn.has(po))?false:(mr.forEach(po=>kn.add(po)),true)});return xn.length?[...en,...xn].slice(-qs):en});const nn=lt.ids.map(en=>dn.get(en)).filter(en=>!!en);ge({key:E,pending:false,phase:"ready",result:{...lt.result,records:nn},resultIds:lt.ids}),Be({kind:"viewer",name:"search-result-hydrate",durationMs:qe()-mn,value:Vt.length,tags:{missingIds:In.length,resultCount:lt.ids.length}});}).catch(Vt=>{Be({kind:"viewer",name:"search-result-hydrate-error",durationMs:qe()-mn,tags:{error:Vt instanceof Error?Vt.message:String(Vt)}});});}Be({kind:"search",name:"query-total",durationMs:qe()-At,tags:{corpusSize:lt.corpusSize,resultCount:lt.ids.length,queryLength:nt.length}});}).catch(lt=>{if(Qe.current!==Ae)return;const kt=lt instanceof Error?lt.message:String(lt);ge({key:E,pending:false,phase:/cancelled/i.test(kt)?"cancelled":"failed",result:Na(nt,[kt]),error:kt}),X.current===E&&(X.current=""),Be({kind:"search",name:"query-error",durationMs:qe()-At,tags:{error:kt,queryLength:nt.length}});}),()=>{Lt=true;const lt=X.current===E;lt&&(X.current=""),Te.cancel(Ae),lt&&Be({kind:"search",name:"readiness-state",value:1,tags:{phase:"cancelled",queryLength:We.length,corpusRows:ie.current.length,searchDocuments:(a==null?void 0:a.length)??0,searchDocumentsLoaded:s,searchDocumentsLoading:i,cancellable:false}}),ge(kt=>(kt==null?void 0:kt.key)===E&&kt.pending?{...kt,pending:false,phase:"cancelled",result:kt.result??Na(We),error:"Search request cancelled."}:kt);}},[E,Se,Wt,We,ke,it,f,l,a==null?void 0:a.length,s,i,c,et]);const pt=It(()=>{if(!Se&&jt)return Ep({query:"",records:o??[],totalMatches:(o==null?void 0:o.length)??0});if(!Se&&Tt&&(a!=null&&a.length)){const Te=Pe.key===Ve?Pe.ids:new Set,Ae=n1(fe,x,Te);return Ep({query:"",records:Ae,totalMatches:tt.length})}return Wt?(pe==null?void 0:pe.key)===E&&pe.result?pe.result:Na(We):xp(o??[],"",{bookmarkFolderIds:O})},[E,pe,fe,tt.length,Pe,Ve,jt,Tt,Se,Wt,We,x,o,a==null?void 0:a.length,O]),St=!!(Wt&&(pe==null?void 0:pe.key)===E&&pe.pending),vt=Se&&(pe==null?void 0:pe.key)===E?pe.resultIds??[]:[],Yt=It(()=>{if(!Se||L.length||!C||!b||!vt.length)return;const Te=PS({extensionName:g&&"extensionName"in g&&typeof g.extensionName=="string"&&g.extensionName?g.extensionName:e,entityType:b,query:We,ids:vt,totalCount:vt.length,folderIds:O,hydrateByIds:C});return ()=>Te.streamRows()},[Se,C,We,b,g,vt,O,L.length,e]),K=(pe==null?void 0:pe.key)===E?pe:null,ze=It(()=>Se?K!=null&&K.phase?{phase:K.phase,label:Ba(K.phase),detail:K.error,cancellable:K.pending&&(K.phase==="preparing-corpus"||K.phase==="querying")}:c?{phase:"degraded",label:Ba("degraded"),detail:c,cancellable:false}:h&&!s&&!(a!=null&&a.length)?{phase:"preparing-corpus",label:Ba("preparing-corpus"),detail:i?"loading search documents":"waiting for search corpus",cancellable:true}:j.current===ke?{phase:"ready",label:Ba("ready"),cancellable:false}:{phase:"preparing-corpus",label:Ba("preparing-corpus"),cancellable:true}:{phase:"idle",label:Ba("idle"),cancellable:false},[ke,K,Se,h,a==null?void 0:a.length,c,s,i]);Je(()=>{Be({kind:"search",name:"readiness-state",value:Se?1:0,tags:{phase:ze.phase,queryLength:We.length,corpusRows:be.length,searchDocuments:(a==null?void 0:a.length)??0,searchDocumentsLoaded:s,searchDocumentsLoading:i,cancellable:ze.cancellable}});},[Se,We.length,a==null?void 0:a.length,s,i,ze.cancellable,ze.phase,be.length]);const Dt=It(()=>{const Te=m_(k),Ae=new Map;for(const At of Te){const nt=vT(At);nt&&Ae.set(nt,At);}return Ae},[k]),Re=It(()=>{if(!L.length)return Se||Tt&&(a!=null&&a.length)?pt.records:[...pt.records].sort((At,nt)=>{const Lt=Rp(nt),Mt=Rp(At);return Lt!==Mt?Lt-Mt:0});const Te=new Map;pt.records.forEach((At,nt)=>{Te.set(At,nt);});const Ae=[...pt.records];return Ae.sort((At,nt)=>{const Lt=Te.get(At)??0,Mt=Te.get(nt)??0;for(const lt of L){const kt=Dt.get(lt.id);if(!kt)continue;const ft=Mp(kt,At,Lt),Xt=Mp(kt,nt,Mt),Qt=bT(ft,Xt);if(Qt!==0)return lt.desc?-Qt:Qt}return Lt-Mt}),Ae},[Se,pt.records,Dt,L]),Fe=It(()=>Re.map((Te,Ae)=>Oo(Te,Ae)),[Re]),rt=!!g&&!Se&&!L.length&&(!Tt||jt),Ue=Te=>{const Ae=lo(Te,D);if(v(Ae),!Fe.length)return;const At=Fe.every(nt=>!!Ae[nt]);Z(At?"all":"explicit");},st=It(()=>Me==="all"?[]:Re.filter((Te,Ae)=>{const At=Oo(Te,Ae);return !!D[At]}),[D,Me,Re]),Ut=It(()=>Me==="all"?[]:Object.entries(D).filter(([,Te])=>Te).map(([Te])=>Te),[D,Me]),ln=It(()=>o1({queryText:We,sort:r1(L),ids:rt?[]:Fe,idsTruncated:rt?Fe.length>0:false,sourceDescriptor:rt?g:void 0,totalMatches:rt?_??pt.totalMatches:pt.totalMatches,warnings:pt.warnings}),[Fe,rt,We,g,_,pt.totalMatches,pt.warnings,L]);return Je(()=>{const Te=globalThis.setTimeout(()=>{I(M);},at);return ()=>{globalThis.clearTimeout(Te);}},[at,M]),Je(()=>{if(!(T!=null&&T.length)&&le!=="table"){he("table");return}le!=="table"&&!(T!=null&&T.some(Te=>Te.id===le))&&he("table");},[le,T]),Je(()=>{try{if(typeof localStorage>"u")return;const Te=localStorage.getItem(ht);if(!Te)return;const Ae=JSON.parse(Te);n===void 0&&typeof Ae.fullscreen=="boolean"&&J(Ae.fullscreen),typeof Ae.activeViewId=="string"&&Ae.activeViewId.trim()&&he(Ae.activeViewId);}catch{}},[ht]),Je(()=>{try{if(typeof localStorage>"u")return;localStorage.setItem(ht,JSON.stringify({fullscreen:wt,activeViewId:le}));}catch{}},[le,wt,ht]),{searchQuery:M,setSearchQuery:P,normalizedSearchQuery:We,selectedFolders:O,setSelectedFolders:B,rowSelection:D,setRowSelection:v,sorting:L,setSorting:$,selectionMode:Me,setSelectionMode:Z,isFullscreen:wt,setIsFullscreen:Ce,activeViewId:le,setActiveViewId:he,searchResult:pt,searchPending:St,searchReadinessState:ze,sortedRecords:Re,currentResultIds:Fe,handleRowSelectionChange:Ue,selectedRecords:st,selectedRecordIds:Ut,streamSearchResultRows:Yt,resultSetSnapshot:ln,resolvedViewStateKey:ht}}const ia=12,Ap=74,IT=4,Vs=1600,Dp=90,ET=24,od=2500,AT=2,DT=96,PT=140,Pp=1e4,OT="data-twe-highlight-v1",FT="scrollmark-table-search-",Op="scrollmark_media_preview_dock_after_close_v1",ad=new WeakMap;let Fp=0;function LT(e){const t=e.parentNode;if(t){for(;e.firstChild;)t.insertBefore(e.firstChild,e);t.removeChild(e),t.normalize();}}function id(e){const t=ad.get(e),n=y_();t&&n&&(n.delete(t),UT(t)),e.querySelectorAll(`mark[${OT}="1"]`).forEach(o=>{o instanceof HTMLElement&&LT(o);});}function y_(){const e=globalThis.CSS,t=__();return !(e!=null&&e.highlights)||!t?null:e.highlights}function __(){const e=globalThis.Highlight;return typeof e=="function"?e:null}function NT(e){const t=ad.get(e);if(t)return Lp(t),t;Fp+=1;const n=`${FT}${Fp}`;return ad.set(e,n),Lp(n),n}function BT(e="sm"){switch(e){case "md":return "hidden md:inline";case "lg":return "hidden lg:inline";case "xl":return "hidden xl:inline";case "sm":default:return "hidden sm:inline"}}function Lp(e){if(typeof document>"u")return;const t=`twe-css-highlight-style-${e}`;if(document.getElementById(t))return;const n=document.createElement("style");n.id=t,n.textContent=`
::highlight(${e}) {
  background-color: rgba(250, 204, 21, 0.32);
  color: inherit;
}
`,document.head.appendChild(n);}function UT(e){var t;typeof document>"u"||(t=document.getElementById(`twe-css-highlight-style-${e}`))==null||t.remove();}function $T(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function HT(e,t){if(id(e),!t.length)return;const n=[...new Set(t.map(c=>c.trim().toLowerCase()))].filter(c=>c.length>=2).sort((c,h)=>h.length-c.length).slice(0,24);if(!n.length)return;const r=y_(),o=__();if(!r||!o)return;const a=new RegExp(`(${n.map(c=>$T(c)).join("|")})`,"ig"),i=document.createTreeWalker(e,NodeFilter.SHOW_TEXT,{acceptNode:c=>{if(!c.nodeValue||!c.nodeValue.trim())return NodeFilter.FILTER_REJECT;const h=c.parentElement;return !h||h.closest("mark,button,input,textarea,select,option,svg,code,pre,.btn,.checkbox,.label,.dropdown-content")?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT}}),s=[];for(;i.nextNode();)s.push(i.currentNode);const l=[];for(const c of s){const h=c.nodeValue||"";a.lastIndex=0,a.test(h)&&(a.lastIndex=0,h.replace(a,(f,m,g)=>{const _=document.createRange();return _.setStart(c,g),_.setEnd(c,g+f.length),l.push(_),f}));}l.length&&r.set(NT(e),new o(...l));}function Np(e,t){if(t<=0||e.length<=1)return 0;let n=0,r=e.length-1;for(;n<r;){const o=Math.floor((n+r+1)/2);(e[o]||0)<=t?n=o:r=o-1;}return Math.max(0,Math.min(e.length-2,n))}function jT(e){if(e.size<=od)return;const t=[...e.entries()].sort((n,r)=>n[1].touchedAt-r[1].touchedAt);for(const[n]of t.slice(0,e.size-od))e.delete(n);}function rs({title:e,viewStateKey:t,searchHistoryScope:n,fullscreen:r,onFullscreenChange:o,loading:a=false,loadingMore:i=false,loadedCount:s=0,totalCount:l=0,hasMore:c=false,sourceMode:h=false,sourceModeFiltersActive:f=false,sourceWindowStartIndex:m=0,resultSourceDescriptor:g,resultEntityType:_,onSourceWindowChange:b,streamSourceRows:C,streamMediaRows:k,mediaSourceKey:T,mediaSourceTotalCount:M,getMediaWindow:P,onBookmarkFolderSelectionChange:F,loadMore:I,loadAll:O,hydrateRecordsByIds:B,records:D,searchDocuments:v,searchDocumentsLoading:L,searchDocumentsLoaded:$,searchDocumentTotalCount:Me,searchDocumentsBlockedReason:Z,loadSearchDocuments:re,loadSearchDocumentChunks:J,columns:le,clear:he,showClearButton:pe=true,renderActions:ge,renderExtra:z,bookmarkFolderOptions:ue,alternateViews:Pe}){const{t:ce}=Wn(),Ee=_t(qe()),Qe=_t(false),X=_t(false),ne=_t(false),[j,se]=Hn(""),[_e,we]=Hn(false),[Ye,We]=De(()=>{try{return localStorage.getItem(Op)==="1"}catch{return  false}}),[Se,Tt]=Hn(null);Je(()=>{try{localStorage.setItem(Op,Ye?"1":"0");}catch{}},[Ye]);const jt=Nn(()=>{we(false),Ye||se("");},[Ye,se,we]),[Wt,Gt]=sr(false),[Rt,et]=De(0),{searchQuery:at,setSearchQuery:wt,normalizedSearchQuery:Ce,selectedFolders:ht,setSelectedFolders:it,rowSelection:yt,setRowSelection:Oe,sorting:ke,setSorting:E,selectionMode:x,setSelectionMode:R,isFullscreen:U,setIsFullscreen:V,activeViewId:be,setActiveViewId:ie,searchResult:Le,searchPending:Ne,searchReadinessState:tt,sortedRecords:fe,currentResultIds:Ve,handleRowSelectionChange:pt,selectedRecords:St,selectedRecordIds:vt,streamSearchResultRows:Yt,resultSetSnapshot:K,resolvedViewStateKey:ze}=RT({title:e,viewStateKey:t,fullscreen:r,onFullscreenChange:o,records:D,columns:le,alternateViews:Pe,searchDocuments:v,searchDocumentsLoading:L,searchDocumentsLoaded:$,searchDocumentTotalCount:Me,searchDocumentsBlockedReason:Z,loadSearchDocuments:re,loadSearchDocumentChunks:J,hydrateRecordsByIds:B,folderScopeSourceBacked:f,resultSourceDescriptor:g,resultEntityType:_,resultSourceTotalCount:l}),Dt=It(()=>{const ve=new Map;for(const bt of w1){const Nt=ve.get(bt.category)||[];Nt.push(bt),ve.set(bt.category,Nt);}return [...ve.entries()]},[]),Re=It(()=>(Pe==null?void 0:Pe.find(ve=>ve.id===be))??null,[be,Pe]),Fe=!Re,[rt,Ue]=De(null),st=Nn(ve=>{Ue(ve);},[]);Je(()=>{Ue(null);},[Re==null?void 0:Re.id,Ce]);const Ut=!!Re&&h&&l>Pp&&(Re==null?void 0:Re.sourceBacked)!==true&&!Ce,ln=!!(Re&&Ce),Te=ln?false:h,Ae=ln?fe.length:l,At=ln?void 0:C,nt=ln?void 0:T,Lt=ln?void 0:M,Mt=ln?void 0:P,lt=ln?void 0:k,kt=ve=>{F==null||F(ve),it(ve);};Je(()=>{F==null||F(ht);},[F,ht]);const ft=It(()=>({title:e,viewStateKey:t||"",resolvedViewStateKey:ze,activeViewId:be,fullscreen:U}),[be,U,ze,e,t]);Je(()=>{Be({kind:"viewer",name:"table-open-start",value:l,tags:{...ft,loadedCount:s,totalCount:l,searchDocuments:(v==null?void 0:v.length)??0}});},[]);const Xt=_t(null),Qt=_t(null),In=_t(0),mn=_t(0),Vt=_t(null),dn=_t(new Map),nn=_t(false),[en,kn]=De(0),[xn,Br]=De(520),[Qr,mr]=De(Ap),[po,ka]=De(0);Je(()=>{const ve=Xt.current;ve&&(ve.scrollTop=0,In.current=0,kn(0),Br(Math.max(320,ve.clientHeight||520)));},[be,Ce,ht]);const fs=()=>{const ve=Xt.current;ve&&(mn.current=qe(),In.current=ve.scrollTop,Vt.current===null&&(Vt.current=window.requestAnimationFrame(()=>{Vt.current=null;const bt=In.current;kn(Nt=>Math.abs(bt-Nt)<ET?Nt:bt);})));};Je(()=>{const ve=Xt.current;if(!ve||typeof ResizeObserver>"u")return;const bt=new ResizeObserver(()=>{const Nt=Math.max(320,ve.clientHeight||520);Br(Mr=>Math.abs(Mr-Nt)>12?Nt:Mr);});return bt.observe(ve),()=>bt.disconnect()},[]),Je(()=>()=>{Vt.current!==null&&window.cancelAnimationFrame(Vt.current);},[]);const Et=Math.max(32,Qr||Ap),li=h&&!Ce&&(!ht.length||f)&&!Re,xa=li&&l>D.length,cn=li&&!ke.length,Ct=cn?Math.max(l,D.length):fe.length,Jr=Ve,Cr=It(()=>{var bt;if(cn)return [];const ve=new Array(Ct+1);ve[0]=0;for(let Nt=0;Nt<Ct;Nt+=1){const Mr=Jr[Nt]||`row-${Nt}`,bo=((bt=dn.current.get(Mr))==null?void 0:bt.height)||Et;ve[Nt+1]=(ve[Nt]||0)+Math.max(24,bo);}return ve},[po,Jr,Et,cn,Ct]),cr=cn?Ct*Et:Cr[Ct]||0,$n=cn?Math.max(0,Math.floor(Math.max(0,en-Vs)/Et)-ia):Math.max(0,Np(Cr,en-Vs)-ia),ci=cn?Math.ceil((en+xn+Vs)/Et)+ia+1:Np(Cr,en+xn+Vs)+ia+1,Fn=Math.min(Ct,Math.max($n+1,Math.min(ci,$n+Dp))),ui=m+D.length,Ur=cn?Math.max(m,Math.min($n,ui)):$n,di=cn?Math.max(Ur,Math.min(Fn,ui,Ct)):Fn,ar=It(()=>{if(cn){const ve=Math.max(0,Ur-m),bt=Math.max(ve,di-m);return D.slice(ve,bt)}return fe.slice($n,Fn)},[Fn,D,fe,cn,di,Ur,m,$n]);Je(()=>{if(!cn||!b)return;const ve=Math.max(0,$n-ia),bt=Math.min(Ct,Fn+ia);b(ve,bt);},[Fn,b,cn,$n,Ct]),Je(()=>{if(cn||!c||a||i||Re||Ce)return;const ve=Math.max(0,cr-(en+xn)),bt=Math.max(900,xn*IT,Et*80);Ct>0&&(Fn>=Ct-ia||ve<=bt)&&(I==null||I());},[Re,Fn,c,I,a,i,Ce,Et,cr,Ct,en,xn]);const mo=cn&&i&&Ct>0&&ar.length===0,go=mo?$n:cn?Ur:$n,Zt=cn?mo?Fn:Math.min(Ct,Ur+ar.length):Fn,Ko=It(()=>x==="all"?Object.entries(yt).filter(([,ve])=>ve).map(([ve])=>ve):[],[yt,x]),yo=Ko.length,fi=x==="all"?Math.max(0,Ct-yo):vt.length,er=It(()=>{if(x!=="explicit"||!vt.length||!B||!g||!_)return;const ve=vt.map(Nt=>qy(Nt)).filter(Nt=>Nt.length>0);if(!ve.length)return;const bt=DS({extensionName:"extensionName"in g?g.extensionName:void 0,entityType:_,ids:ve,source:g,hydrateByIds:B});return ()=>bt.streamRows()},[B,_,g,vt,x]),eo=cn?go*Et:Cr[$n]||0,Wo=mo?Math.max(Et,Math.max(1,Zt-go)*Et):0,Tr=Math.max(0,cr-(cn?Zt*Et:Cr[Fn]||cr));Je(()=>{!xa||!ke.length||(E([]),Be({kind:"viewer",name:"source-sort-cleared",value:l,tags:ft}));},[ft,E,ke.length,xa,l]);const hs=ve=>{if(x==="all"){Oe(bt=>{const Nt={...bt};return Nt[ve]?delete Nt[ve]:Nt[ve]=true,Be({kind:"viewer",name:"selection-all-exception-toggle",value:Object.keys(Nt).length,tags:{...ft,totalRows:Ct,rowId:ve}}),Nt}),Be({kind:"viewer",name:"selection-mode-retained-all",value:Math.max(0,Ct-1),tags:{...ft,totalRows:Ct,rowId:ve}});return}pt(bt=>({...bt,[ve]:!bt[ve]}));},ps=()=>{if(x==="all"){if(yo>0){Oe({}),Be({kind:"viewer",name:"selection-all-exceptions-cleared",value:Ct,tags:ft});return}R("explicit"),Oe({}),Be({kind:"viewer",name:"selection-all-cleared",value:0,tags:ft});return}if(Ve.length>0&&Ve.every(bt=>!!yt[bt])){Oe({}),Be({kind:"viewer",name:"selection-explicit-visible-cleared",value:0,tags:ft});return}R("all"),Oe({}),Be({kind:"viewer",name:"selection-explicit-promoted-all",value:Ct,tags:ft});},fn=bC({data:ar,columns:le,defaultColumn:{size:160,minSize:48,maxSize:520},enableRowSelection:true,getCoreRowModel:_C(),getRowId:(ve,bt)=>Oo(ve,go+bt),enableSorting:!xa,manualSorting:true,onSortingChange:E,onRowSelectionChange:pt,state:{rowSelection:yt,sorting:ke},meta:{mediaPreview:j,setMediaPreview:ve=>{se(ve),we(true);},rawDataPreview:Se,setRawDataPreview:ve=>Tt(ve),isAllResultRowsSelected:()=>x==="all"?Ve.length>0&&yo===0:Ve.length>0&&Ve.every(ve=>!!yt[ve]),isSomeResultRowsSelected:()=>x==="all"?yo>0:Ve.some(ve=>!!yt[ve]),toggleAllResultRowsSelected:ps,isResultRowSelected:ve=>x==="all"?!yt[ve]:!!yt[ve],toggleResultRowSelected:hs}}),an=fn.getRowModel().rows,_o=fn.getVisibleLeafColumns(),Go=_o.reduce((ve,bt)=>ve+bt.getSize(),0);Je(()=>{Qe.current||!an.length||(Qe.current=true,Be({kind:"viewer",name:"first-visible-rows",durationMs:qe()-Ee.current,value:an.length,tags:{...ft,hydratedRecords:D.length,totalRows:Ct,loadedCount:s,totalCount:l,searchDocuments:(v==null?void 0:v.length)??0,visibleRows:an.length,loading:a}}));},[s,a,ft,D.length,v==null?void 0:v.length,l,Ct,an.length]),Je(()=>{X.current||a||!an.length||(X.current=true,Be({kind:"viewer",name:"first-interactive",durationMs:qe()-Ee.current,value:an.length,tags:{...ft,hydratedRecords:D.length,loadedCount:s,totalCount:l,totalRows:Ct,visibleRows:an.length}}));},[s,a,ft,D.length,l,Ct,an.length]),Je(()=>{if(ne.current||a||i||!an.length)return;const ve=globalThis.setTimeout(()=>{ne.current||(ne.current=true,Be({kind:"viewer",name:"first-stable-layout",durationMs:qe()-Ee.current,value:an.length,tags:{...ft,hydratedRecords:D.length,loadedCount:s,totalCount:l,totalRows:Ct,visibleRows:an.length,safeRowHeight:Et,measuredRows:dn.current.size,virtualHeight:cr}}));},350);return ()=>globalThis.clearTimeout(ve)},[s,a,i,ft,D.length,Et,l,Ct,cr,an.length]),Je(()=>{Be({kind:"viewer",name:"table-hydrated-records",value:D.length,tags:ft}),Be({kind:"viewer",name:"table-search-documents",value:(v==null?void 0:v.length)??0,tags:ft}),Be({kind:"viewer",name:"table-result-ids",value:Ve.length,tags:ft}),Be({kind:"viewer",name:"table-selected-records",value:St.length,tags:{...ft,selectionMode:x}}),Be({kind:"viewer",name:"table-selection-exceptions",value:yo,tags:{...ft,selectionMode:x}}),Be({kind:"viewer",name:"table-selected-result-count",value:fi,tags:{...ft,selectionMode:x}}),Be({kind:"viewer",name:"table-visible-rows",value:an.length,tags:{...ft,startIndex:$n,endIndex:Fn}});},[Ve.length,Fn,ft,D.length,v==null?void 0:v.length,St.length,fi,yo,x,$n,an.length]),Je(()=>{const ve=()=>{const Mr=Qt.current;if(!Mr)return;const bo=Mr.querySelectorAll('tr[data-vrow="1"]');if(!bo.length)return;let Qo=0,vo=0,Sa=false;bo.forEach(Rr=>{if(Rr instanceof HTMLTableRowElement){const gr=Rr.getBoundingClientRect().height;Qo+=gr,vo+=1;const Jo=Rr.dataset.vrowKey;if(Jo&&Number.isFinite(gr)&&gr>0){const ko=dn.current.get(Jo),Ca=(ko==null?void 0:ko.height)??Et,Ta=gr-Ca;!ko||Math.abs(Ta)>AT?(dn.current.set(Jo,{height:gr,touchedAt:qe()}),jT(dn.current),Sa=true):ko.touchedAt=qe();}}});const mi=Qo/vo;(dn.current.size<DT||en<xn*2||Ct<=Dp)&&Number.isFinite(mi)&&mi>16&&mr(Rr=>{const gr=Math.max(24,Rr*.92+mi*.08);return Math.abs(gr-Rr)>4?gr:Rr}),Sa&&(ka(Rr=>Rr+1),Be({kind:"viewer",name:"table-row-height-cache",value:dn.current.size,tags:{...ft,limit:od,measuredRows:vo,visibleRows:an.length}}));},bt=Math.max(0,PT-(qe()-mn.current)),Nt=globalThis.setTimeout(ve,bt);return ()=>globalThis.clearTimeout(Nt)},[Fn,ft,Ce,Et,ht,$n,Ct,xn,en,an]),Je(()=>{const ve=Qt.current;if(ve){if(!Le.highlightTerms.length){nn.current&&(id(ve),nn.current=false);return}return nn.current=true,HT(ve,Le.highlightTerms),()=>{id(ve);}}},[an,Le.highlightTerms]),Je(()=>{if(!U)return;const ve=bt=>{bt.key==="Escape"&&V(false);};return window.addEventListener("keydown",ve),()=>window.removeEventListener("keydown",ve)},[U]);const Yo=_t(""),Vn=_t(null);Je(()=>{!n||typeof localStorage>"u"||et(Hd(n).length);},[n]),Je(()=>{if(!n)return;if(!Ce){Yo.current="";return}const ve=[...ht].sort().join(","),bt=`${n}::${Ce}::${ve}`;if(Yo.current===bt)return;Yo.current=bt;const Nt=()=>{const Mr=D1({scope:n,title:e,query:at,normalized_query:Ce,searched_at_ms:Date.now(),result_count:Le.totalMatches,total_records:D.length,selected_folders:ht,lexical_expression:Le.parsed.lexicalExpression,warning_messages:Le.warnings});et(Mr.filter(bo=>bo.scope===n).length);};return typeof window<"u"&&"requestIdleCallback"in window&&typeof window.requestIdleCallback=="function"?Vn.current=window.requestIdleCallback(()=>{Vn.current=null,Nt();}):Vn.current=window.setTimeout(()=>{Vn.current=null,Nt();},160),()=>{Vn.current!==null&&(typeof window<"u"&&"cancelIdleCallback"in window&&typeof window.cancelIdleCallback=="function"?window.cancelIdleCallback(Vn.current):window.clearTimeout(Vn.current),Vn.current=null);}},[D.length,n,at,Le.parsed.lexicalExpression,Le.totalMatches,Le.warnings,Ce,ht,e]),Je(()=>{if(!U||typeof document>"u")return;const{body:ve}=document,bt=ve.style.overflow;return ve.style.overflow="hidden",()=>{ve.style.overflow=bt;}},[U]);const[ac,ur]=sr(),[wo,hi]=De(false),pi=()=>{ur(),c&&!Ce&&O&&!wo&&(hi(true),O().finally(()=>{hi(false);}));},Xo=U?"relative flex min-h-0 grow flex-col overflow-hidden bg-base-100 text-base-content":"relative flex min-h-0 grow flex-col",Zo=Re==null?void 0:Re.component;return d("div",{class:Xo,children:[d("section",{class:U?"sticky top-0 z-20 border-b border-base-300 bg-base-100 px-3 py-2":"sticky top-0 z-20 mb-1.5 rounded-box-half border border-base-300 bg-base-200 px-2 py-1.5",children:[d("div",{class:"flex items-center gap-2",children:[d("label",{class:"input input-bordered input-sm flex h-9 flex-1 items-center gap-2",children:[d(zw,{size:18,class:"opacity-70"}),d("input",{type:"text",class:"grow bg-transparent text-sm",value:at,placeholder:ce('Search with operators, phrases, and boolean logic: from:alice ("design system"~2 OR reliability)'),onInput:ve=>wt(ve.target.value),onKeyDown:ve=>{ve.key==="Escape"&&wt("");}}),at?d("button",{class:"btn btn-ghost btn-xs",title:ce("Clear search"),onClick:()=>wt(""),children:d(sl,{size:14})}):null]}),ue!=null&&ue.length?d(Hg,{class:"w-56",options:ue,selected:ht,onChange:kt,placeholder:ce("Bookmark folders"),selectedSummary:ve=>ve===1?ce("1 folder selected"):ce("{{count}} folders selected",{count:ve})}):null,d("button",{class:"btn btn-ghost btn-sm",onClick:Gt,title:ce("Search help"),children:d(tg,{size:18})}),Pe!=null&&Pe.length?d("div",{class:"join",children:[d("button",{class:`btn join-item btn-sm ${be==="table"?"btn-primary":"btn-ghost"}`,onClick:()=>ie("table"),title:ce("Table view"),children:d(Ys,{size:16})}),Pe.map(ve=>{const bt=h&&l>Pp&&ve.sourceBacked!==true&&!Ce;return d("button",{class:`btn join-item btn-sm ${be===ve.id?"btn-primary":"btn-ghost"} ${bt?"btn-disabled":""}`,onClick:()=>ie(ve.id),disabled:bt,title:bt?ce("{{view}} is disabled for large source-backed result sets.",{view:ve.label}):ce(ve.label),children:ve.icon==="grid"?d(jw,{size:16}):d(Ys,{size:16})},ve.id)})]}):null,d("button",{class:"btn btn-ghost btn-sm",onClick:()=>V(ve=>!ve),title:ce(U?"Exit fullscreen":"Fullscreen"),children:U?d(Pw,{size:18}):d(Dw,{size:18})})]}),Ce?d("div",{class:"mt-1.5 space-y-1 text-[10px] leading-4",children:[tt.phase!=="idle"?d("div",{class:`font-mono ${tt.phase==="degraded"||tt.phase==="failed"?"text-warning":"opacity-70"}`,children:[tt.label,tt.cancellable?" - cancellable on query change":""]}):null,Le.parsed.lexicalExpression?d("div",{class:"font-mono opacity-70 break-all",children:["parsed: ",Le.parsed.lexicalExpression]}):null,Le.warningObjects.length?d("div",{class:"rounded-box-half border border-warning/40 bg-warning/10 px-2 py-1 font-mono text-warning",children:Le.warningObjects.map((ve,bt)=>d("div",{children:["[",ve.code,"] ",ve.message,ve.token?` (${ve.token})`:""]},`search-warning-${bt}`))}):null]}):null,d("div",{class:"mt-1 flex min-w-0 items-center justify-between gap-3 overflow-hidden whitespace-nowrap text-[10px] leading-4 font-mono opacity-70",children:[d("span",{class:"min-w-0 flex-1 truncate",children:[Re?rt!=null&&rt.primary?ce("{{view}} view - {{status}}",{view:ce(Re.label),status:rt.primary}):ce("{{view}} view",{view:ce(Re.label)}):a?ce("loading {{loaded}}/{{total}}",{loaded:s,total:Math.max(l,D.length)}):Ce?Ne?ce("searching {{matches}}/{{total}}",{matches:Le.totalMatches,total:D.length}):ce("matches {{matches}}/{{total}}",{matches:Le.totalMatches,total:D.length}):c||l>D.length?ce("rows {{loaded}}/{{total}}",{loaded:D.length,total:Math.max(l,D.length)}):ce("rows {{count}}",{count:D.length}),!Re&&!Ce&&i?` ${ce("buffering...")}`:""]}),d("div",{class:"flex shrink-0 items-center gap-3 overflow-hidden whitespace-nowrap",children:Re?d(Jn,{children:[((rt==null?void 0:rt.details)??[]).map(ve=>d("span",{class:BT(ve.minWidth),children:ve.label},ve.key)),rt!=null&&rt.actions?d("span",{class:"shrink-0",children:rt.actions}):null]}):d(Jn,{children:[n?d("span",{class:"hidden lg:inline",children:ce("history {{count}}",{count:Rt})}):null,d("span",{class:"hidden md:inline",children:ce("selected {{count}} ({{mode}})",{count:fi,mode:ce(x)})}),Fe?d("span",{class:"hidden sm:inline",children:ce("rendered {{rendered}}/{{total}} (window {{start}}-{{end}})",{rendered:mo?0:an.length,total:Ct,start:go+1,end:Zt||0})}):null]})})]})]}),d("main",{ref:Xt,onScroll:fs,class:"max-w-full min-h-0 grow overflow-y-auto overflow-x-auto bg-base-200 overscroll-none rounded-box-half border border-base-300",children:Zo&&Ut?d("div",{class:"flex h-[320px] flex-col items-center justify-center gap-3 px-4 text-center text-sm",children:[d("div",{class:"max-w-md opacity-70",children:[Re==null?void 0:Re.label," is available after narrowing the result set or switching back to table mode."]}),d("button",{class:"btn btn-sm btn-primary",onClick:()=>ie("table"),children:[d(Ys,{size:16}),"Table"]})]}):Zo?d(Zo,{records:fe,scrollParentRef:Xt,storageKey:`${ze}:${(Re==null?void 0:Re.id)||"table"}`,fullscreen:U,sourceMode:Te,sourceTotalCount:Ae,streamSourceRows:At,mediaSourceKey:nt,mediaSourceTotalCount:Lt,getMediaWindow:Mt,streamMediaRows:lt,onDiagnosticsChange:st,onOpenMedia:ve=>{se(ve),we(true);}}):d(Jn,{children:[d("table",{class:"table table-fixed table-pin-rows table-border-bc table-padding-sm",style:{width:`max(${Go}px, 100%)`},children:[d("colgroup",{children:_o.map(ve=>d("col",{style:{width:`${ve.getSize()}px`}},ve.id))}),d("thead",{children:fn.getHeaderGroups().map(ve=>d("tr",{children:ve.headers.map(bt=>d("th",{className:bt.column.getCanSort()?"cursor-pointer select-none":"",onClick:bt.column.getToggleSortingHandler(),children:[hp(bt.column.columnDef.header,bt.getContext()),bt.column.getIsSorted()==="asc"&&d(Ww,{size:15,class:"inline align-top ml-1"}),bt.column.getIsSorted()==="desc"&&d(Gw,{size:15,class:"inline align-top ml-1"})]},bt.id))},ve.id))}),d("tbody",{ref:Qt,children:[eo>0?d("tr",{"aria-hidden":"true",children:d("td",{colSpan:Math.max(1,fn.getVisibleFlatColumns().length),style:{height:`${eo}px`,padding:0,border:0}})}):null,an.map((ve,bt)=>d("tr",{"data-vrow":"1","data-vrow-key":Jr[cn?Math.max(0,go-m)+bt:go+bt]||ve.id,children:ve.getVisibleCells().map(Nt=>d("td",{class:"scrollmark-table-cell",children:d("div",{class:"scrollmark-table-cell-content",children:hp(Nt.column.columnDef.cell,Nt.getContext())})},Nt.id))},ve.id)),Wo>0?d("tr",{"aria-hidden":"true","data-source-buffering-window":"1",children:d("td",{colSpan:Math.max(1,fn.getVisibleFlatColumns().length),style:{height:`${Wo}px`,padding:0,border:0}})}):null,Tr>0?d("tr",{"aria-hidden":"true",children:d("td",{colSpan:Math.max(1,fn.getVisibleFlatColumns().length),style:{height:`${Tr}px`,padding:0,border:0}})}):null]})]}),ar.length>0||mo?null:d("div",{class:"flex items-center justify-center h-[320px] w-full",children:d("p",{class:"text-base-content text-opacity-50",children:ce("No data available.")})})]})}),d("div",{class:"flex mt-1.5 items-center gap-2 border-t border-base-300 px-2 py-1.5",children:[pe?d("button",{class:"btn btn-sm btn-neutral btn-ghost",onClick:he,children:ce("Clear")}):null,d("span",{class:"flex-grow"}),ge==null?void 0:ge(fn,{loading:a,loadingMore:i,loadedCount:s,totalCount:l,resultRecords:cn?ar:fe,visibleRecords:ar}),d("button",{class:"btn btn-sm btn-primary",onClick:pi,disabled:a,title:wo?ce("Export menu is open while remaining rows load in the background."):a?ce("Wait for records to finish loading before exporting."):cn&&C?ce("Exports stream from the active source without loading all rows into the table."):c&&!Ce?ce("Opens immediately and loads remaining rows in the background."):void 0,children:[wo?d("span",{class:"loading loading-spinner"}):null,ce("Export Data")]})]}),Ye&&j&&!_e?d("aside",{class:"absolute right-2 bottom-14 z-[2] w-56 rounded-box-half border border-base-300 bg-base-100 shadow-lg",children:[d("header",{class:"flex items-center justify-between border-b border-base-300 px-2 py-1 text-xs font-semibold",children:[d("span",{children:ce("Media View")}),d("div",{class:"flex items-center gap-1",children:[d("button",{class:"btn btn-ghost btn-xs",onClick:()=>we(true),children:"Open"}),d("button",{class:"btn btn-ghost btn-xs",onClick:()=>{we(false),se("");},children:d(sl,{size:12})})]})]}),d("div",{class:"h-36 overflow-hidden bg-base-200",children:j.includes(".mp4")?d("video",{controls:true,class:"h-full w-full object-contain",src:j}):d("img",{class:"h-full w-full object-contain",src:j})})]}):null,d(lr,{title:ce("JSON View"),class:"max-w-xl",show:!!Se,onClose:()=>Tt(null),children:d("main",{class:"max-w-full max-h-[500px] overflow-scroll overscroll-none",children:typeof Se=="string"?d("p",{class:"whitespace-pre-wrap",children:Se}):d("pre",{class:"text-xs leading-none",children:JSON.stringify(Se,null,2)})})}),d(PC,{show:_e&&!!j,url:j,dockAfterClose:Ye,onDockAfterCloseChange:We,onClose:jt}),d(lr,{title:ce("Search Operators"),class:"h-[min(88vh,860px)] w-[min(92vw,1040px)] max-w-[92vw] max-h-[88vh] overflow-hidden",show:Wt,onClose:Gt,children:d("div",{class:"min-h-0 grow overflow-y-auto pr-1 text-sm leading-6",children:[d("p",{class:"mb-2",children:[ce("Query semantics now follow recorder-style precedence:")," ",d("code",{class:"ml-1",children:"NOT"}),",",d("code",{class:"ml-1",children:"AND"}),",",d("code",{class:"ml-1",children:"OR"}),", ",ce("with implicit")," ",d("code",{class:"ml-1",children:"AND"})," ",ce("between adjacent terms.")]}),d("div",{class:"grid gap-3 md:grid-cols-2",children:Dt.map(([ve,bt])=>d("section",{class:"rounded-box-half border border-base-300 bg-base-200/70 p-3",children:[d("h4",{class:"mb-2 text-xs font-semibold uppercase tracking-[0.08em] opacity-70",children:ce(`search.category.${ve}`)}),d("div",{class:"space-y-2",children:bt.map(Nt=>d("div",{class:"text-xs",children:[d("div",{class:"font-mono text-[11px] text-info",children:Nt.syntax}),d("div",{children:ce(Nt.description)}),d("div",{class:"font-mono opacity-70",children:Nt.examples.join(" | ")})]},`${ve}-${Nt.syntax}`))})]},ve))})]})}),d(AC,{title:e,columns:le,resultRecords:cn?ar:fe,resultCount:cn?Ct:fe.length,streamResultRecords:cn?C:Yt,selectedRecords:St,selectedRecordCount:x==="explicit"?vt.length:void 0,streamSelectedRecords:er,selectionExcludedRecordIds:Ko,resultSetSnapshot:K,selectionMode:x,preparingFullDataset:wo,show:ac,onClose:ur}),z==null?void 0:z(fn,{resultSetSnapshot:K,resultRecords:cn?ar:fe,selectedRecords:St,selectionMode:x,selectionExcludedRecordIds:Ko})]})}const gn=jd(),Bp=new WeakMap;function zn(e){var a;const t=Bp.get(e);if(t)return t;const n=(()=>{const i=e,s=i.__bookmark_folder_name_source,l=i.__bookmark_folder_name;return s==="api"&&typeof l=="string"&&l.trim()?l:null})(),r=(()=>{const i=e.__bookmark_folder_id;return typeof i=="string"&&i.trim()?i:null})(),o={createdAtMs:typeof((a=e.twe_private_fields)==null?void 0:a.created_at)=="number"?e.twe_private_fields.created_at:ha(e),fullText:zl(e),media:fo(e),mediaTags:gx(e),retweetedTweet:ii(e),quotedTweet:Id(e),bookmarkFolderName:n,bookmarkFolderId:r};return Bp.set(e,o),o}const qT=e=>{const t=zn(e).retweetedTweet;return t?Vl(t):null},VT=e=>{const t=zn(e).quotedTweet;return t?Vl(t):null},Up=e=>zn(e).bookmarkFolderName,$p=e=>zn(e).bookmarkFolderId,w_=[gn.display({id:"select",size:48,minSize:48,maxSize:48,meta:{exportable:false},header:({table:e})=>{var t,n,r,o;return d("input",{type:"checkbox",class:"checkbox checkbox-sm align-middle",checked:((n=(t=e.options.meta)==null?void 0:t.isAllResultRowsSelected)==null?void 0:n.call(t))??e.getIsAllRowsSelected(),indeterminate:((o=(r=e.options.meta)==null?void 0:r.isSomeResultRowsSelected)==null?void 0:o.call(r))??e.getIsSomeRowsSelected(),onChange:()=>{var a;if((a=e.options.meta)!=null&&a.toggleAllResultRowsSelected){e.options.meta.toggleAllResultRowsSelected();return}e.toggleAllRowsSelected();}})},cell:({row:e,table:t})=>{var n,r;return d("input",{type:"checkbox",class:"checkbox checkbox-sm",checked:((r=(n=t.options.meta)==null?void 0:n.isResultRowSelected)==null?void 0:r.call(n,e.id))??e.getIsSelected(),disabled:!e.getCanSelect(),indeterminate:e.getIsSomeSelected(),onChange:()=>{var o;if((o=t.options.meta)!=null&&o.toggleResultRowSelected){t.options.meta.toggleResultRowSelected(e.id);return}e.toggleSelected();}})}}),gn.accessor("rest_id",{size:112,minSize:112,meta:{exportKey:"id",exportHeader:"ID"},header:()=>d(gt,{i18nKey:"ID"}),cell:e=>d("p",{class:"w-20 break-all font-mono text-xs",children:e.getValue()})}),gn.accessor(e=>zn(e).createdAtMs,{id:"created_at",size:136,minSize:128,meta:{exportKey:"created_at",exportHeader:"Date",exportValue:e=>Pr(zn(e.original).createdAtMs,ut.get("dateTimeFormat"))},header:()=>d(gt,{i18nKey:"Date"}),cell:e=>d("p",{class:"w-24",children:d("a",{class:"link",target:"_blank",href:ca(e.row.original),children:Pr(e.getValue(),ut.get("dateTimeFormat"))})})}),gn.accessor("legacy.full_text",{size:360,minSize:280,maxSize:520,meta:{exportKey:"full_text",exportHeader:"Content",exportValue:e=>zn(e.original).fullText},header:()=>d(gt,{i18nKey:"Content"}),cell:e=>{var t,n,r,o;return d("div",{children:[d("p",{class:"w-60 whitespace-pre-wrap",dangerouslySetInnerHTML:{__html:yl(zn(e.row.original).fullText,[...((n=(t=e.row.original.legacy)==null?void 0:t.entities)==null?void 0:n.urls)??[],...((o=(r=e.row.original.legacy)==null?void 0:r.entities)==null?void 0:o.media)??[]])}}),e.row.original.note_tweet&&d("button",{class:"link",onClick:()=>{var a;return (a=e.table.options.meta)==null?void 0:a.setRawDataPreview(zn(e.row.original).fullText)},children:[">>"," ",d(gt,{i18nKey:"Show Full Text"})]})]})}}),gn.accessor(e=>zn(e).media.length,{id:"media",size:176,minSize:136,meta:{exportKey:"media",exportHeader:"Media",exportValue:e=>zn(e.original).media.map(t=>({type:t.type,url:t.url,thumbnail:ti(t.media_url_https,"thumb"),original:pa(t),ext_alt_text:t.ext_alt_text}))},header:()=>d(gt,{i18nKey:"Media"}),cell:e=>d(jg,{data:zn(e.row.original).media,onClick:t=>{var n;return (n=e.table.options.meta)==null?void 0:n.setMediaPreview(pa(t))}})}),gn.accessor("core.user_results.result.core.screen_name",{size:144,minSize:120,meta:{exportKey:"screen_name",exportHeader:"Screen Name"},header:()=>d(gt,{i18nKey:"Screen Name"}),cell:e=>d("p",{class:"whitespace-pre",children:d("a",{class:"link",target:"_blank",href:Ui(e.row.original.core.user_results.result),children:["@",e.getValue()]})})}),gn.accessor("core.user_results.result.core.name",{size:184,minSize:144,meta:{exportKey:"name",exportHeader:"Profile Name"},header:()=>d(gt,{i18nKey:"Profile Name"}),cell:e=>d("p",{class:"w-32",children:e.getValue()})}),gn.accessor("core.user_results.result.avatar.image_url",{size:96,minSize:84,meta:{exportKey:"profile_image_url",exportHeader:"Profile Image"},header:()=>d(gt,{i18nKey:"Profile Image"}),cell:e=>d("div",{class:"cursor-pointer",onClick:()=>{var t;return (t=e.table.options.meta)==null?void 0:t.setMediaPreview(Ed(e.getValue()))},children:d("img",{class:"w-12 h-12 rounded",src:e.getValue(),loading:"lazy",decoding:"async"})})}),gn.accessor("core.user_results.result.rest_id",{size:112,minSize:112,meta:{exportKey:"user_id",exportHeader:"User ID"},header:()=>d(gt,{i18nKey:"User ID"}),cell:e=>d("p",{class:"w-20 break-all font-mono text-xs",children:e.getValue()})}),gn.accessor("legacy.in_reply_to_screen_name",{size:144,minSize:120,meta:{exportKey:"in_reply_to",exportHeader:"Replying To",exportValue:e=>e.original.legacy.in_reply_to_status_id_str},header:()=>d(gt,{i18nKey:"Replying To"}),cell:e=>d("p",{class:"whitespace-pre",children:e.row.original.legacy.in_reply_to_status_id_str?d("a",{class:"link",target:"_blank",href:_x(e.row.original),children:["@",e.getValue()]}):"N/A"})}),gn.accessor(qT,{id:"rt_source",size:144,minSize:120,meta:{exportKey:"retweeted_status",exportHeader:"RT Source",exportValue:e=>{var t;return (t=ii(e.original))==null?void 0:t.rest_id}},header:()=>d(gt,{i18nKey:"RT Source"}),cell:e=>{const t=zn(e.row.original).retweetedTweet;return d("p",{class:"whitespace-pre",children:t?d("a",{class:"link",target:"_blank",href:ca(t),children:["@",e.getValue()]}):"N/A"})}}),gn.accessor(VT,{id:"quote_source",size:144,minSize:120,meta:{exportKey:"quoted_status",exportHeader:"Quote Source",exportValue:e=>{var t;return (t=Id(e.original))==null?void 0:t.rest_id}},header:()=>d(gt,{i18nKey:"Quote Source"}),cell:e=>{const t=zn(e.row.original).quotedTweet;return d("p",{class:"whitespace-pre",children:t?d("a",{class:"link",target:"_blank",href:ca(t),children:["@",e.getValue()]}):"N/A"})}}),gn.display({id:"media_tags",size:184,minSize:144,meta:{exportKey:"media_tags",exportHeader:"Media Tags",exportValue:e=>zn(e.original).mediaTags},header:()=>d(gt,{i18nKey:"Media Tags"}),cell:e=>d("p",{children:zn(e.row.original).mediaTags.length?zn(e.row.original).mediaTags.map(t=>d("a",{class:"link inline-block",target:"_blank",href:Ui(t.screen_name),children:["@",t.screen_name]})):"N/A"})}),gn.accessor("legacy.favorite_count",{size:96,minSize:88,meta:{exportKey:"favorite_count",exportHeader:"Favorites"},header:()=>d(gt,{i18nKey:"Favorites"}),cell:e=>d("p",{children:e.getValue()})}),gn.accessor("legacy.retweet_count",{size:96,minSize:88,meta:{exportKey:"retweet_count",exportHeader:"Retweets"},header:()=>d(gt,{i18nKey:"Retweets"}),cell:e=>d("p",{children:e.getValue()})}),gn.accessor("legacy.bookmark_count",{size:104,minSize:96,meta:{exportKey:"bookmark_count",exportHeader:"Bookmarks"},header:()=>d(gt,{i18nKey:"Bookmarks"}),cell:e=>d("p",{children:e.getValue()})}),gn.accessor("legacy.quote_count",{size:88,minSize:80,meta:{exportKey:"quote_count",exportHeader:"Quotes"},header:()=>d(gt,{i18nKey:"Quotes"}),cell:e=>d("p",{children:e.getValue()})}),gn.accessor("legacy.reply_count",{size:88,minSize:80,meta:{exportKey:"reply_count",exportHeader:"Replies"},header:()=>d(gt,{i18nKey:"Replies"}),cell:e=>d("p",{children:e.getValue()})}),gn.accessor("views.count",{size:88,minSize:80,meta:{exportKey:"views_count",exportHeader:"Views",exportValue:e=>{var t;return typeof((t=e.original.views)==null?void 0:t.count)>"u"?null:+e.original.views.count}},header:()=>d(gt,{i18nKey:"Views"}),cell:e=>d("p",{children:e.getValue()??"N/A"})}),gn.accessor("legacy.favorited",{size:104,minSize:96,meta:{exportKey:"favorited",exportHeader:"Favorited"},header:()=>d(gt,{i18nKey:"Favorited"}),cell:e=>d("p",{children:e.getValue()?"YES":"NO"})}),gn.accessor("legacy.retweeted",{size:104,minSize:96,meta:{exportKey:"retweeted",exportHeader:"Retweeted"},header:()=>d(gt,{i18nKey:"Retweeted"}),cell:e=>d("p",{children:e.getValue()?"YES":"NO"})}),gn.accessor("legacy.bookmarked",{size:112,minSize:104,meta:{exportKey:"bookmarked",exportHeader:"Bookmarked"},header:()=>d(gt,{i18nKey:"Bookmarked"}),cell:e=>d("p",{children:e.getValue()?"YES":"NO"})}),gn.accessor(Up,{id:"bookmark_folder_name",size:184,minSize:152,meta:{exportKey:"bookmark_folder_name",exportHeader:"Bookmark Folder",exportValue:e=>Up(e.original)},header:()=>d(gt,{i18nKey:"Bookmark Folder"}),cell:e=>{const t=e.getValue();return t?d("p",{class:"w-36 truncate",title:String(t),children:t}):d("p",{class:"text-gray-400",children:"—"})}}),gn.accessor($p,{id:"bookmark_folder_id",size:168,minSize:144,meta:{exportKey:"bookmark_folder_id",exportHeader:"Bookmark Folder ID",exportValue:e=>$p(e.original)},header:()=>d("span",{children:"Bookmark Folder ID"}),cell:e=>{const t=e.getValue();return t?d("p",{class:"w-32 break-all font-mono text-xs",children:t}):d("p",{class:"text-gray-400",children:"—"})}}),gn.display({id:"url",size:64,minSize:56,maxSize:72,meta:{exportKey:"url",exportHeader:"URL",exportValue:e=>ca(e.original)},header:()=>d(gt,{i18nKey:"URL"}),cell:e=>d("a",{href:ca(e.row.original),target:"_blank",children:d(ng,{})})}),gn.display({id:"actions",size:112,minSize:104,meta:{exportable:false},header:()=>d(gt,{i18nKey:"Actions"}),cell:e=>d("div",{class:"flex flex-row items-start space-x-1",children:d("button",{onClick:()=>{var t;return (t=e.table.options.meta)==null?void 0:t.setRawDataPreview(e.row.original)},class:"btn btn-xs btn-neutral whitespace-nowrap",children:d(gt,{i18nKey:"Details"})})})})],un=jd(),b_=[un.display({id:"select",size:48,minSize:48,maxSize:48,meta:{exportable:false},header:({table:e})=>{var t,n,r,o;return d("input",{type:"checkbox",class:"checkbox checkbox-sm align-middle",checked:((n=(t=e.options.meta)==null?void 0:t.isAllResultRowsSelected)==null?void 0:n.call(t))??e.getIsAllRowsSelected(),indeterminate:((o=(r=e.options.meta)==null?void 0:r.isSomeResultRowsSelected)==null?void 0:o.call(r))??e.getIsSomeRowsSelected(),onChange:()=>{var a;if((a=e.options.meta)!=null&&a.toggleAllResultRowsSelected){e.options.meta.toggleAllResultRowsSelected();return}e.toggleAllRowsSelected();}})},cell:({row:e,table:t})=>{var n,r;return d("input",{type:"checkbox",class:"checkbox checkbox-sm",checked:((r=(n=t.options.meta)==null?void 0:n.isResultRowSelected)==null?void 0:r.call(n,e.id))??e.getIsSelected(),disabled:!e.getCanSelect(),indeterminate:e.getIsSomeSelected(),onChange:()=>{var o;if((o=t.options.meta)!=null&&o.toggleResultRowSelected){t.options.meta.toggleResultRowSelected(e.id);return}e.toggleSelected();}})}}),un.accessor("rest_id",{size:112,minSize:112,meta:{exportKey:"id",exportHeader:"ID"},header:()=>d(gt,{i18nKey:"ID"}),cell:e=>d("p",{class:"w-20 break-all font-mono text-xs",children:e.getValue()})}),un.accessor("core.screen_name",{size:144,minSize:120,meta:{exportKey:"screen_name",exportHeader:"Screen Name"},header:()=>d(gt,{i18nKey:"Screen Name"}),cell:e=>d("p",{class:"whitespace-pre",children:d("a",{class:"link",target:"_blank",href:Ui(e.row.original),children:["@",e.getValue()]})})}),un.accessor("core.name",{size:184,minSize:144,meta:{exportKey:"name",exportHeader:"Profile Name"},header:()=>d(gt,{i18nKey:"Profile Name"}),cell:e=>d("p",{class:"w-32",children:e.getValue()})}),un.accessor("legacy.description",{size:336,minSize:260,maxSize:520,meta:{exportKey:"description",exportHeader:"Description"},header:()=>d(gt,{i18nKey:"Description"}),cell:e=>{var t;return d("p",{class:"w-52 break-words",dangerouslySetInnerHTML:{__html:yl(e.row.original.legacy.description||"N/A",(t=e.row.original.legacy.entities)==null?void 0:t.description.urls)}})}}),un.accessor("avatar.image_url",{size:104,minSize:92,meta:{exportKey:"profile_image_url",exportHeader:"Profile Image"},header:()=>d(gt,{i18nKey:"Profile Image"}),cell:e=>d("div",{class:"cursor-pointer",onClick:()=>{var t;return (t=e.table.options.meta)==null?void 0:t.setMediaPreview(Ed(e.getValue()))},children:d("img",{class:"w-12 h-12 rounded",src:e.getValue(),loading:"lazy",decoding:"async"})})}),un.accessor("legacy.profile_banner_url",{size:184,minSize:160,meta:{exportKey:"profile_banner_url",exportHeader:"Profile Banner"},header:()=>d(gt,{i18nKey:"Profile Banner"}),cell:e=>d("div",{class:"cursor-pointer w-36 h-12",onClick:()=>{var t;return (t=e.table.options.meta)==null?void 0:t.setMediaPreview(e.getValue()??"")},children:e.getValue()?d("img",{class:"w-auto h-12 rounded",src:`${e.getValue()}/600x200`,loading:"lazy",decoding:"async"}):d("span",{class:"leading-[48px]",children:"N/A"})})}),un.accessor("legacy.followers_count",{size:104,minSize:96,meta:{exportKey:"followers_count",exportHeader:"Followers"},header:()=>d(gt,{i18nKey:"Followers"}),cell:e=>d("p",{children:e.getValue()??"N/A"})}),un.accessor("legacy.friends_count",{size:120,minSize:104,meta:{exportKey:"friends_count",exportHeader:"FollowingCount"},header:()=>d(gt,{i18nKey:"FollowingCount"}),cell:e=>d("p",{children:e.getValue()??"N/A"})}),un.accessor("legacy.statuses_count",{size:104,minSize:96,meta:{exportKey:"statuses_count",exportHeader:"Statuses"},header:()=>d(gt,{i18nKey:"Statuses"}),cell:e=>d("p",{children:e.getValue()??"N/A"})}),un.accessor("legacy.favourites_count",{size:112,minSize:104,meta:{exportKey:"favourites_count",exportHeader:"Favourites"},header:()=>d(gt,{i18nKey:"Favourites"}),cell:e=>d("p",{children:e.getValue()??"N/A"})}),un.accessor("legacy.listed_count",{size:88,minSize:80,meta:{exportKey:"listed_count",exportHeader:"Listed"},header:()=>d(gt,{i18nKey:"Listed"}),cell:e=>d("p",{children:e.getValue()??"N/A"})}),un.accessor("location.location",{size:176,minSize:136,meta:{exportKey:"location",exportHeader:"Location"},header:()=>d(gt,{i18nKey:"Location"}),cell:e=>d("p",{children:e.getValue()??"N/A"})}),un.accessor("legacy.url",{size:220,minSize:160,meta:{exportKey:"website",exportHeader:"Website"},header:()=>d(gt,{i18nKey:"Website"}),cell:e=>{var t,n;return d("p",{dangerouslySetInnerHTML:{__html:yl(e.row.original.legacy.url||"N/A",(n=(t=e.row.original.legacy.entities)==null?void 0:t.url)==null?void 0:n.urls)}})}}),un.accessor("legacy_extended_profile.birthdate",{size:120,minSize:104,meta:{exportKey:"birthdate",exportHeader:"Birthdate",exportValue:e=>{var t;return Gf((t=e.original.legacy_extended_profile)==null?void 0:t.birthdate)}},header:()=>d(gt,{i18nKey:"Birthdate"}),cell:e=>d("p",{children:Gf(e.getValue())??"N/A"})}),un.accessor("verification.verified_type",{size:128,minSize:112,meta:{exportKey:"verified_type",exportHeader:"Verified Type"},header:()=>d(gt,{i18nKey:"Verified Type"}),cell:e=>d("p",{children:e.getValue()??"N/A"})}),un.accessor("is_blue_verified",{size:128,minSize:112,meta:{exportKey:"is_blue_verified",exportHeader:"Blue Verified"},header:()=>d(gt,{i18nKey:"Blue Verified"}),cell:e=>d("p",{children:e.getValue()?"YES":"NO"})}),un.accessor("relationship_perspectives.following",{size:112,minSize:104,meta:{exportKey:"following",exportHeader:"Following"},header:()=>d(gt,{i18nKey:"Following"}),cell:e=>d("p",{children:e.getValue()?"YES":"NO"})}),un.accessor("relationship_perspectives.followed_by",{size:112,minSize:104,meta:{exportKey:"followed_by",exportHeader:"Follows You"},header:()=>d(gt,{i18nKey:"Follows You"}),cell:e=>d("p",{children:e.getValue()?"YES":"NO"})}),un.accessor(e=>{var t,n;return ((n=(t=e.twe_relationship_fields)==null?void 0:t.relation_types)==null?void 0:n.join(", "))||""},{id:"relation_types",size:160,minSize:128,meta:{exportKey:"relation_types",exportHeader:"Relation Types"},header:()=>d(gt,{i18nKey:"Relation Types"}),cell:e=>d("p",{children:e.getValue()||"N/A"})}),un.accessor(e=>{var t,n;return ((n=(t=e.twe_relationship_fields)==null?void 0:t.subject_screen_names)==null?void 0:n.join(", "))||""},{id:"subject_screen_names",size:192,minSize:160,meta:{exportKey:"subject_screen_names",exportHeader:"Subject Accounts"},header:()=>d(gt,{i18nKey:"Subject Accounts"}),cell:e=>d("p",{class:"w-40 break-words",children:e.getValue()||"N/A"})}),un.accessor(e=>{var t,n;return ((n=(t=e.twe_relationship_fields)==null?void 0:t.subject_user_ids)==null?void 0:n.join(", "))||""},{id:"subject_user_ids",size:152,minSize:136,meta:{exportKey:"subject_user_ids",exportHeader:"Subject User IDs"},header:()=>d(gt,{i18nKey:"Subject User IDs"}),cell:e=>d("p",{class:"w-28 break-all font-mono text-xs",children:e.getValue()||"N/A"})}),un.accessor(e=>{var t;return ((t=e.twe_relationship_fields)==null?void 0:t.last_observed_at)||0},{id:"last_observed_at",size:136,minSize:128,meta:{exportKey:"last_observed_at",exportHeader:"Last Observed At",exportValue:e=>{var t;return (t=e.original.twe_relationship_fields)!=null&&t.last_observed_at?Pr(e.original.twe_relationship_fields.last_observed_at,ut.get("dateTimeFormat")):""}},header:()=>d(gt,{i18nKey:"Last Observed At"}),cell:e=>d("p",{class:"w-24",children:e.getValue()?Pr(e.getValue(),ut.get("dateTimeFormat")):"N/A"})}),un.accessor("dm_permissions.can_dm",{size:88,minSize:80,meta:{exportKey:"can_dm",exportHeader:"Can DM"},header:()=>d(gt,{i18nKey:"Can DM"}),cell:e=>d("p",{children:e.getValue()?"YES":"NO"})}),un.accessor("privacy.protected",{size:104,minSize:96,meta:{exportKey:"protected",exportHeader:"Protected"},header:()=>d(gt,{i18nKey:"Protected"}),cell:e=>d("p",{children:e.getValue()?"YES":"NO"})}),un.accessor(e=>+Ja(e.core.created_at),{id:"created_at",size:136,minSize:128,meta:{exportKey:"created_at",exportHeader:"Created At",exportValue:e=>Pr(Ja(e.original.core.created_at),ut.get("dateTimeFormat"))},header:()=>d(gt,{i18nKey:"Created At"}),cell:e=>d("p",{class:"w-24",children:e.getValue()?Pr(e.getValue(),ut.get("dateTimeFormat")):"N/A"})}),un.display({id:"url",size:64,minSize:56,maxSize:72,meta:{exportKey:"url",exportHeader:"URL",exportValue:e=>Ui(e.original)},header:()=>d(gt,{i18nKey:"URL"}),cell:e=>d("a",{href:Ui(e.row.original),target:"_blank",children:d(ng,{})})}),un.display({id:"actions",size:112,minSize:104,meta:{exportable:false},header:()=>d(gt,{i18nKey:"Actions"}),cell:e=>d("div",{class:"flex flex-row items-start space-x-1",children:d("button",{onClick:()=>{var t;return (t=e.table.options.meta)==null?void 0:t.setRawDataPreview(e.row.original)},class:"btn btn-xs btn-neutral whitespace-nowrap",children:d(gt,{i18nKey:"Details"})})})})],Mi=42,zT=24,KT=900,WT=320,GT=264,YT=228,XT=196,ZT=16,QT=14,Hp=360,JT=48,eM=160,tM=42,zs=144,nM=8,Pi=new Map;function jp(e){return Pi.get(e)??null}function uu(e,t){var r;if(t.updatedAt=Date.now(),Pi.set(e,t),Pi.size<=nM)return;const n=(r=[...Pi.entries()].sort((o,a)=>o[1].updatedAt-a[1].updatedAt)[0])==null?void 0:r[0];n&&Pi.delete(n);}function qp(e){return {items:[],nextRowIndex:0,scannedRows:0,exhausted:false,totalCount:e,updatedAt:Date.now()}}function rM(e){return ii(e)?[]:fo(e).filter(n=>n.type==="photo"||n.type==="video"||n.type==="animated_gif")}function oM(e){const t=e;return t.__bookmark_folder_name_source==="api"&&typeof t.__bookmark_folder_name=="string"?t.__bookmark_folder_name.trim():""}function aM(e){return e.type==="photo"?ti(e.media_url_https,"large"):ti(e.media_url_https,"medium")}function iM(e){var r,o,a,i,s,l,c,h,f,m;const t=((r=e.original_info)==null?void 0:r.width)||((a=(o=e.sizes)==null?void 0:o.large)==null?void 0:a.w)||((s=(i=e.sizes)==null?void 0:i.medium)==null?void 0:s.w)||1,n=((l=e.original_info)==null?void 0:l.height)||((h=(c=e.sizes)==null?void 0:c.large)==null?void 0:h.h)||((m=(f=e.sizes)==null?void 0:f.medium)==null?void 0:m.h)||1;return Math.max(.56,Math.min(1.8,t/n))}function sM(e,t){if(!e.trim())return 0;const n=t==="compact"?34:42;return Math.max(1,Math.min(t==="compact"?3:4,Math.ceil(e.trim().length/n)))}function lM(e,t,n){const r=t/Math.max(.56,e.aspectRatio||1),a=sM(e.fullText,n)*20,i=n==="compact"?96:108,s=34,l=e.bookmarkFolderName?22:0,c=e.durationLabel?4:0,h=n==="compact"?24:30;return r+i+s+l+a+c+h}function cM(e,t,n,r){const o=Math.max(1,t),a=Array.from({length:o},()=>({items:[],estimatedHeight:0}));for(const i of e){let s=0;for(let l=1;l<a.length;l+=1)a[l].estimatedHeight<a[s].estimatedHeight&&(s=l);a[s].items.push(i),a[s].estimatedHeight+=lM(i,n,r);}return a}function du(e){const t=rM(e);if(!t.length)return [];const n=Vl(e),r=zl(e).trim(),o=Pr(ha(e),ut.get("dateTimeFormat")),a=ca(e),i=oM(e);return t.map((s,l)=>{var c,h,f,m,g;return {id:`${e.rest_id}:${s.media_key||s.id_str||l}`,tweet:e,media:s,screenName:n,fullText:r,createdAtLabel:o,tweetUrl:a,previewUrl:aM(s),originalUrl:pa(s),aspectRatio:iM(s),bookmarkFolderName:i,favoriteCount:Number(((c=e.legacy)==null?void 0:c.favorite_count)||0),retweetCount:Number(((h=e.legacy)==null?void 0:h.retweet_count)||0),bookmarkCount:Number(((f=e.legacy)==null?void 0:f.bookmark_count)||0),replyCount:Number(((m=e.legacy)==null?void 0:m.reply_count)||0),durationLabel:s.type==="photo"?"":kg((g=s.video_info)==null?void 0:g.duration_millis)}})}function v_({records:e,scrollParentRef:t,onOpenMedia:n,storageKey:r,fullscreen:o,sourceMode:a,sourceTotalCount:i=0,streamSourceRows:s,mediaSourceKey:l,mediaSourceTotalCount:c,getMediaWindow:h,streamMediaRows:f,onDiagnosticsChange:m}){var x;const{t:g}=Wn(),_=_t(null),b=_t(""),C=_t(null),k=_t(null),T=_t(0),M=_t(false),P=_t(false),F=_t(0),I=_t([]),O=_t(""),[B,D]=De(Mi),[v,L]=De("comfortable"),[$,Me]=De(0),[Z,re]=De([]),[J,le]=De(0),[he,pe]=De(false),[ge,z]=De(false),[ue,Pe]=De({start:0,end:0,count:0}),ce=f??s,Ee=c??i,Qe=It(()=>[r||"media-masonry",l||"stream-source",i].join(":"),[l,i,r]),X=!!(a&&(h||ce));Je(()=>{try{if(typeof localStorage>"u"||!r)return;const R=localStorage.getItem(`${r}:density`);(R==="compact"||R==="comfortable")&&L(R);}catch{}},[r]),Je(()=>{try{if(typeof localStorage>"u"||!r)return;localStorage.setItem(`${r}:density`,v);}catch{}},[v,r]);const ne=It(()=>e.flatMap(R=>du(R)),[e]),j=X?Z:ne;Je(()=>{I.current=Z;},[Z]);const se=async R=>{if(!X||!ce&&!h||M.current||P.current||I.current.length>=R)return;M.current=true,pe(true);const U=T.current,V=F.current,be=O.current||Qe,ie=jp(be)??qp(Ee);let Le=0,Ne=0;try{const tt=[];if(h)for(;I.current.length+tt.length<R&&Le<Hp&&!ie.exhausted;){if(T.current!==U)return;const fe=ie.nextRowIndex<=0?JT:eM,Ve=await h(ie.nextRowIndex,fe);if(T.current!==U)return;Le+=Ve.rows.length,ie.nextRowIndex+=Ve.rows.length,F.current=Math.max(F.current,ie.nextRowIndex),le(F.current);for(const pt of Ve.rows){const St=du(pt);St.length&&(tt.push(...St),Ne+=St.length);}if(ie.totalCount=Ve.totalCount||Ee,!Ve.hasAfter||!Ve.rows.length){ie.exhausted=!0,P.current=!0,z(!0);break}}else if(ce){const fe=C.current??ce()[Symbol.asyncIterator]();for(C.current=fe;I.current.length+tt.length<R&&Le<Hp;){if(T.current!==U)return;const Ve=await fe.next();if(T.current!==U)return;if(Ve.done){ie.exhausted=!0,P.current=!0,z(!0);break}Le+=1,ie.nextRowIndex+=1,F.current+=1,Le%12===0&&le(F.current);const pt=du(Ve.value);pt.length&&(tt.push(...pt),Ne+=pt.length);}}tt.length?re(fe=>{if(T.current!==U)return fe;const Ve=new Set(fe.map(vt=>vt.id)),pt=tt.filter(vt=>Ve.has(vt.id)?!1:(Ve.add(vt.id),!0));if(!pt.length)return fe;const St=[...fe,...pt];return ie.items=St,ie.scannedRows=F.current,ie.exhausted=P.current,uu(be,ie),I.current=St,St}):(ie.items=I.current,ie.scannedRows=F.current,ie.exhausted=P.current,uu(be,ie));}finally{T.current===U&&(M.current=false,le(F.current),pe(false)),Be({kind:"viewer",name:"media-source-scan",value:Ne,tags:{scannedRows:Le,scannedRowsTotal:F.current,scannedRowsBefore:V,mediaItems:I.current.length+Ne,targetMediaCount:R,exhausted:P.current,sourceTotalCount:Ee,windowBacked:!!h}});}};Je(()=>{if(T.current+=1,C.current=null,M.current=false,pe(false),O.current=Qe,!X){P.current=false,F.current=0,I.current=[],re([]),le(0),z(false);return}const R=jp(Qe);if(R){P.current=R.exhausted,F.current=R.scannedRows,I.current=R.items,re(R.items),le(R.scannedRows),z(R.exhausted);return}const U=qp(Ee);uu(Qe,U),P.current=false,F.current=0,I.current=[],re([]),le(0),z(false);},[Ee,Qe,X]),Je(()=>{X&&se(tM);},[Ee,Qe,Z.length,X]);const _e=((x=j[0])==null?void 0:x.id)||"";Je(()=>{D(R=>b.current!==_e?(b.current=_e,Math.min(Mi,Math.max(0,j.length))):j.length<=Mi?Math.min(Mi,Math.max(0,j.length)):R>j.length?j.length:Math.max(R,Math.min(Mi,j.length)));},[_e,j.length]),Je(()=>{const R=t.current;if(!R)return;const U=()=>{if(R.scrollHeight-(R.scrollTop+R.clientHeight)<=KT){const be=Math.min(j.length,B+zT);D(be),X&&!ge&&j.length<=be+zs&&se(be+zs);}};return U(),R.addEventListener("scroll",U,{passive:true}),()=>R.removeEventListener("scroll",U)},[j.length,t,ge,X,B]),Je(()=>{!X||ge||j.length<=B+zs&&se(B+zs);},[j.length,ge,X,B]),nb(()=>{const R=_.current,U=t.current;if(!R&&!U)return;const V=()=>{const ie=(R==null?void 0:R.clientWidth)||0,Le=(U==null?void 0:U.clientWidth)||0;Me(Math.max(ie,Le,0));};V();const be=new ResizeObserver(()=>V());return R&&be.observe(R),U&&U!==R&&be.observe(U),()=>be.disconnect()},[t]);const we=j.slice(0,B),Ye=It(()=>{const R=new Map;return we.forEach((U,V)=>R.set(U.id,V)),R},[we]),We=v==="compact"?QT:ZT,Se=!o,Tt=v==="compact"?Se?XT:GT:Se?YT:WT,jt=Math.max(1,$?Math.floor(($+We)/(Tt+We)):1),Wt=!o&&$>=520?2:1,Rt=Math.max(Wt,Math.min(o?6:4,jt)),et=$>0?($-We*Math.max(0,Rt-1))/Rt:Tt,at=It(()=>cM(we,Rt,et,v),[Rt,et,v,we]);Je(()=>{const R=_.current,U=t.current;if(!R||!U)return;const V=()=>{k.current=null;const ie=U.getBoundingClientRect(),Le=Array.from(R.querySelectorAll("article[data-masonry-index]"));let Ne=Number.POSITIVE_INFINITY,tt=-1,fe=0;for(const pt of Le){const St=pt.getBoundingClientRect();if(St.bottom<ie.top||St.top>ie.bottom)continue;const vt=Number(pt.dataset.masonryIndex??-1);!Number.isFinite(vt)||vt<0||(Ne=Math.min(Ne,vt),tt=Math.max(tt,vt),fe+=1);}const Ve=fe>0?{start:Ne,end:tt,count:fe}:{start:0,end:Math.max(0,Math.min(we.length,B)-1),count:0};Pe(pt=>pt.start===Ve.start&&pt.end===Ve.end&&pt.count===Ve.count?pt:Ve);},be=()=>{k.current===null&&(k.current=window.requestAnimationFrame(V));};return be(),U.addEventListener("scroll",be,{passive:true}),window.addEventListener("resize",be),()=>{U.removeEventListener("scroll",be),window.removeEventListener("resize",be),k.current!==null&&(window.cancelAnimationFrame(k.current),k.current=null);}},[Rt,v,t,B,we.length]);const wt=ue.count?ue.start+1:we.length?1:0,Ce=ue.count?ue.end+1:Math.min(we.length,B),ht=ue.count||we.length,it=he?"loading":ge?"complete":"idle",yt=Ee||"?",Oe=X?he?g("loading source {{scanned}}/{{total}}",{scanned:J,total:yt}):g("source {{status}} {{scanned}}/{{total}}",{status:g(it),scanned:J,total:yt}):g("media {{count}}",{count:j.length}),ke=It(()=>d("div",{class:"join",children:[d("button",{class:`btn join-item btn-xs ${v==="comfortable"?"btn-primary":"btn-ghost"}`,onClick:()=>L("comfortable"),title:g("Comfortable density"),children:d(Ys,{size:14})}),d("button",{class:`btn join-item btn-xs ${v==="compact"?"btn-primary":"btn-ghost"}`,onClick:()=>L("compact"),title:g("Compact density"),children:d(Hw,{size:14})})]}),[v,g]),E=It(()=>({primary:Oe,details:[{key:"rendered",label:g("rendered {{rendered}}/{{total}} (window {{start}}-{{end}})",{rendered:ht,total:j.length,start:wt,end:Ce}),minWidth:"sm"},{key:"loaded-media",label:g("loaded media {{count}}",{count:j.length}),minWidth:"md"},{key:"source-rows",label:X?g("source rows {{scanned}}/{{total}} {{status}}",{scanned:J,total:yt,status:g(it)}):`result rows ${e.length}`,minWidth:"lg"},{key:"layout",label:g("layout {{columns}} cols @ {{width}}px",{columns:Rt,width:Math.round(et)}),minWidth:"xl"},{key:"scope",label:g("original tweet attachments only"),minWidth:"xl"}],actions:ke}),[Rt,et,ke,j.length,Oe,e.length,Ce,wt,ht,J,it,yt,g,X,ue.count]);return Je(()=>{m==null||m(E);},[E,m]),Je(()=>()=>m==null?void 0:m(null),[m]),j.length?d("div",{ref:_,class:"w-full min-w-0 px-3 py-3",children:d("div",{class:"flex items-start",style:{gap:`${We}px`},children:at.map((R,U)=>d("div",{class:"min-w-0 flex-1",children:R.items.map(V=>d("article",{"data-masonry-index":Ye.get(V.id)??0,class:`overflow-hidden rounded-[20px] border border-base-300 bg-gradient-to-b from-base-100 to-base-200/80 shadow-md ${v==="compact"?"mb-3":"mb-4"}`,children:[d("button",{class:"group relative block w-full bg-base-300 text-left",onClick:()=>n(V.originalUrl),children:[d("div",{class:"w-full overflow-hidden",style:{aspectRatio:`${V.aspectRatio}`},children:d("img",{class:"h-full w-full object-cover transition duration-300 group-hover:scale-[1.02]",src:V.previewUrl,loading:"lazy",decoding:"async"})}),d("div",{class:"pointer-events-none absolute inset-x-0 bottom-0 flex items-end justify-between bg-gradient-to-t from-black/70 via-black/20 to-transparent px-3 pb-3 pt-8 text-white",children:[d("div",{class:"flex items-center gap-2 text-[11px] font-semibold uppercase tracking-[0.08em]",children:[V.media.type==="photo"?d(qw,{size:14}):d(tb,{size:14}),d("span",{children:V.media.type==="photo"?g("Photo"):g("Video")})]}),V.durationLabel?d("div",{class:"rounded-full bg-black/40 px-2 py-1 text-[10px] font-semibold",children:V.durationLabel}):null]})]}),d("div",{class:`space-y-2 px-3 ${v==="compact"?"py-2.5":"py-3"}`,children:[d("div",{class:"flex items-start justify-between gap-2",children:[d("div",{class:"min-w-0",children:[d("div",{class:"truncate text-sm font-semibold",children:["@",V.screenName]}),d("div",{class:"text-[11px] opacity-60",children:V.createdAtLabel})]}),d("a",{class:"btn btn-ghost btn-xs",href:V.tweetUrl,target:"_blank",rel:"noreferrer",title:g("Open tweet"),children:d(eg,{size:14})})]}),V.bookmarkFolderName?d("div",{class:"badge badge-outline badge-sm",children:V.bookmarkFolderName}):null,V.fullText?d("p",{class:`text-xs leading-5 opacity-80 ${v==="compact"?"line-clamp-3":"line-clamp-4"}`,children:V.fullText}):null,d("div",{class:"flex flex-wrap items-center gap-2 pt-1 text-[10px] font-semibold uppercase tracking-[0.08em] opacity-65",children:[d("span",{class:"inline-flex items-center gap-1",children:[d($w,{size:12}),V.favoriteCount]}),d("span",{class:"inline-flex items-center gap-1",children:[d(Vw,{size:12}),V.retweetCount]}),d("span",{class:"inline-flex items-center gap-1",children:[d(Ow,{size:12}),V.bookmarkCount]}),d("span",{children:["Replies ",V.replyCount]})]})]})]},V.id))},`column-${U}`))})}):d("div",{ref:_,class:"w-full min-w-0 px-3 py-3",children:d("div",{class:"flex h-[320px] items-center justify-center text-sm opacity-60",children:he?d("span",{class:"inline-flex items-center gap-2",children:[d("span",{class:"loading loading-spinner loading-sm"}),g("Loading media.")]}):g("No media available.")})})}const uM=160,Vp=320,dM=960;function fM(e){return e.name.toLowerCase().endsWith(".zip")||e.type==="application/zip"}function zp(e){if(e&&typeof e=="object"){const t=e.message;if(typeof t=="string"&&t.trim())return t}return String(e)}function Kp(e){var t,n,r,o;return !e||(n=(t=e.manifest)==null?void 0:t.counts)!=null&&n.tweets?"tweet":(o=(r=e.manifest)==null?void 0:r.counts)!=null&&o.users?"user":"tweet"}function hM(e){const t=ho(),[n,r]=De([]),o=Nn(async()=>{r(await Ge.bundleList()??[]);},[]);return Je(()=>{e&&o();},[t,o,e]),{bundles:n,refresh:o}}function pM(e,t){const n=ho(),[r,o]=De([]);return Je(()=>{let a=false;if(!e){o([]);return}return Ge.searchDocumentsForSource(`bundle:${e}`,t).then(i=>{a||o(i??[]);}).catch(()=>{a||o([]);}),()=>{a=true;}},[e,t,n]),r}function mM(e,t){const n=ho(),[r,o]=De({records:[],loading:false,loadingMore:false,loadedCount:0,totalCount:0,hasMore:false}),a=_t(0),i=_t([]),s=_t(false),l=Nn(g=>v0(g,t),[t]),c=Nn(async g=>{const _=(await Ge.bundleGetSnapshotsByIds(g)??[]).filter(b=>b.kind===t);return l(_)},[t,l]),h=Nn(async(g,_)=>{const b=await Ge.bundleGetSnapshotPage(e,{kind:t,offset:g,limit:_,order:"newest"})??[];return l(b)},[e,t,l]),f=Nn(async()=>{if(!(!e||s.current)&&!(r.totalCount>0&&a.current>=r.totalCount)){s.current=true,o(g=>({...g,loadingMore:true}));try{const g=await h(a.current,Vp),_=[...i.current,...g];a.current+=g.length,i.current=_,o(b=>({records:_,loading:!1,loadingMore:!1,loadedCount:_.length,totalCount:Math.max(b.totalCount,_.length),hasMore:g.length>=Vp}));}finally{s.current=false,o(g=>({...g,loadingMore:false}));}}},[e,h,r.totalCount]),m=Nn(async()=>{for(;r.hasMore&&a.current<r.totalCount;){const g=a.current;if(await f(),a.current===g)break}},[f,r.hasMore,r.totalCount]);return Je(()=>{let g=false;if(a.current=0,i.current=[],!e){o({records:[],loading:false,loadingMore:false,loadedCount:0,totalCount:0,hasMore:false});return}return (async()=>{o({records:[],loading:true,loadingMore:false,loadedCount:0,totalCount:0,hasMore:false});const[b,C]=await Promise.all([Ge.bundleGetSnapshotCount(e,t),h(0,uM)]);g||(a.current=C.length,i.current=C,o({records:C,loading:false,loadingMore:false,loadedCount:C.length,totalCount:b??C.length,hasMore:C.length<(b??C.length)}));})(),()=>{g=true;}},[e,t,h,n]),Je(()=>{if(r.loading||r.loadingMore||!r.hasMore||r.loadedCount>=dM)return;const g=globalThis.setTimeout(()=>{f();},120);return ()=>globalThis.clearTimeout(g)},[f,r.hasMore,r.loadedCount,r.loading,r.loadingMore]),{...r,loadMore:f,loadAll:m,hydrateRecordsBySnapshotIds:c}}function gM(){const{t:e}=Wn(),[t,n]=sr(false),[r,o]=De(false),[a,i]=De(""),[s,l]=De("tweet"),[c,h]=De("Idle"),[f,m]=De(false),{bundles:g,refresh:_}=hM(t),b=g.find(I=>I.id===a)??null,C=pM(a,s),k=mM(a,s),T=It(()=>{const I=new Map;for(const O of C){const B=String(O.folder_id||"").trim();if(!B)continue;const D=String(O.folder_name||"").trim(),v=I.get(B);v?v.count+=1:I.set(B,{label:D||`Folder ${B}`,count:1});}return [...I.entries()].sort((O,B)=>B[1].count!==O[1].count?B[1].count-O[1].count:O[1].label.localeCompare(B[1].label)).map(([O,B])=>({value:O,label:`${B.label} (${B.count})`}))},[C]);Je(()=>{if(!t||a||!g.length)return;const I=g.find(O=>O.status==="ready")??g[0];I&&(i(I.id),l(Kp(I)));},[g,a,t]);const M=async I=>{if(!I||f)return;const O=I.name||"selected bundle";m(true),h(`Importing ${O}...`);let B="";try{const D=fM(I)?await oy(Ge,I):await sy(Ge,I);B=D.bundleId,h(`Imported ${D.recordsImported}/${D.recordsSeen} records from ${O}`);}catch(D){h(`Import failed: ${zp(D)}`),m(false);return}try{await _(),i(B);}catch(D){h(`Imported ${O}, but refresh failed: ${zp(D)}`);}finally{m(false);}},P=b?`${e("Bundle Viewer")}: ${b.title}`:e("Bundle Viewer"),F=g.length>0;return d(ls,{title:e("Bundle Viewer"),description:e("{{count}} imported bundles",{count:g.length}),active:F,onClick:n,indicatorColor:"bg-accent",panelClass:"my-1 rounded-box-half border border-accent/40 bg-accent/10 px-2 shadow-sm",buttonClass:"btn-accent",children:d(lr,{class:r?"h-screen max-h-screen max-w-none":"max-w-4xl md:max-w-screen-md sm:max-w-screen-sm h-[82vh] max-h-[calc(100vh-4rem)]",title:e("Bundle Viewer"),show:t,fullscreen:r,onClose:()=>{o(false),n();},children:d("div",{class:"flex min-h-0 grow flex-col gap-2",children:[d("section",{class:"rounded-box-half border border-base-300 bg-base-200 px-2 py-1.5",children:d("div",{class:"flex flex-wrap items-center gap-2",children:[d("label",{class:"btn btn-sm btn-outline",children:[d(Nw,{size:16}),"Import Bundle",d("input",{type:"file",accept:".zip,.json,.jsonl,application/zip,application/json,application/x-ndjson",class:"hidden",disabled:f,onChange:I=>{var B;const O=I.target;M((B=O.files)==null?void 0:B[0]),O.value="";}})]}),d("select",{class:"select select-bordered select-sm min-w-56",value:a,onChange:I=>{const O=I.target.value,B=g.find(D=>D.id===O)??null;i(O),l(Kp(B));},children:[d("option",{value:"",children:"Select imported bundle"}),g.map(I=>d("option",{value:I.id,children:[I.title," (",I.recordCount,")"]},I.id))]}),d("select",{class:"select select-bordered select-sm",value:s,onChange:I=>l(I.target.value),children:[d("option",{value:"tweet",children:"Tweets"}),d("option",{value:"user",children:"Users"})]}),d("button",{class:"btn btn-sm btn-ghost",onClick:()=>void _(),children:[d(rg,{size:16}),"Refresh"]}),b?d("button",{class:"btn btn-sm btn-error btn-outline",onClick:async()=>{confirm(`Delete imported bundle "${b.title}"?`)&&(await Ge.bundleDelete(b.id),i(""),await _());},children:[d(Xw,{size:16}),"Delete"]}):null,d("span",{class:"font-mono text-[10px] opacity-70",children:[f?"busy: ":"",c]})]})}),a?s==="tweet"?d(rs,{title:P,viewStateKey:`bundle:${a}:tweet`,fullscreen:r,onFullscreenChange:o,loading:k.loading,loadingMore:k.loadingMore,loadedCount:k.loadedCount,totalCount:k.totalCount,hasMore:k.hasMore,loadMore:k.loadMore,loadAll:k.loadAll,hydrateRecordsByIds:k.hydrateRecordsBySnapshotIds,records:k.records,searchDocuments:C,columns:w_,clear:()=>{},showClearButton:false,alternateViews:[{id:"media-masonry",label:"Media masonry",icon:"grid",component:v_}],bookmarkFolderOptions:T,renderActions:()=>d("span",{class:"badge badge-outline badge-sm font-mono",children:["imported bundle: ",(b==null?void 0:b.recordCount)??0," records"]})}):d(rs,{title:P,viewStateKey:`bundle:${a}:user`,fullscreen:r,onFullscreenChange:o,loading:k.loading,loadingMore:k.loadingMore,loadedCount:k.loadedCount,totalCount:k.totalCount,hasMore:k.hasMore,loadMore:k.loadMore,loadAll:k.loadAll,hydrateRecordsByIds:k.hydrateRecordsBySnapshotIds,records:k.records,searchDocuments:C,columns:b_,clear:()=>{},showClearButton:false,renderActions:()=>d("span",{class:"badge badge-outline badge-sm font-mono",children:["imported bundle: ",(b==null?void 0:b.recordCount)??0," records"]})}):d("div",{class:"flex grow items-center justify-center rounded-box-half border border-base-300 bg-base-200 text-sm opacity-70",children:"Import or select a bundle to open it in the explorer."})]})})})}const yM={BookmarksModule:10,TweetIndexModule:20,UserDetailModule:30,UserTweetsModule:40,UserMediaModule:50,LikesModule:60,QuotesModule:70,TweetDetailModule:80,SearchTimelineModule:90,FollowersModule:120,FollowingModule:130,RetweetersModule:140,HomeTimelineModule:220,ListTimelineModule:230,CommunityTimelineModule:240,ListMembersModule:320,ListSubscribersModule:330,CommunityMembersModule:340,DirectMessagesModule:420,LocalSearchModule:9e3,InteractionEventsModule:9010,RuntimeLogsModule:9990},_M={BookmarksModule:"Bookmarks",TweetIndexModule:"Tweets",UserDetailModule:"Users",UserTweetsModule:"User Tweets",UserMediaModule:"User Media",TweetDetailModule:"Tweet Details",SearchTimelineModule:"Search Timeline",HomeTimelineModule:"Home Timeline",ListTimelineModule:"List Timeline",CommunityTimelineModule:"Community Timeline",CommunityMembersModule:"Community Members",ListMembersModule:"List Members",ListSubscribersModule:"List Subscribers",DirectMessagesModule:"Direct Messages",InteractionEventsModule:"Interaction Events",LocalSearchModule:"Local Search",RuntimeLogsModule:"Runtime Logs"},wM={BookmarksModule:{indicatorColor:"bg-warning",panelClass:"border-l-2 border-warning/60 pl-2"},TweetIndexModule:{indicatorColor:"bg-info",panelClass:"border-l-2 border-info/50 pl-2"},UserDetailModule:{indicatorColor:"bg-success",panelClass:"border-l-2 border-success/50 pl-2"},UserTweetsModule:{indicatorColor:"bg-info"},UserMediaModule:{indicatorColor:"bg-info"},TweetDetailModule:{indicatorColor:"bg-info"},SearchTimelineModule:{indicatorColor:"bg-info"},LikesModule:{indicatorColor:"bg-secondary"},QuotesModule:{indicatorColor:"bg-secondary"},RetweetersModule:{indicatorColor:"bg-secondary"},FollowersModule:{indicatorColor:"bg-success"},FollowingModule:{indicatorColor:"bg-success"},HomeTimelineModule:{indicatorColor:"bg-primary"},ListTimelineModule:{indicatorColor:"bg-primary"},CommunityTimelineModule:{indicatorColor:"bg-primary"},ListMembersModule:{indicatorColor:"bg-success"},ListSubscribersModule:{indicatorColor:"bg-success"},CommunityMembersModule:{indicatorColor:"bg-success"},DirectMessagesModule:{indicatorColor:"bg-accent"},LocalSearchModule:{indicatorColor:"bg-neutral",panelClass:"opacity-90"},InteractionEventsModule:{indicatorColor:"bg-neutral",panelClass:"opacity-90"},RuntimeLogsModule:{indicatorColor:"bg-neutral",panelClass:"opacity-90"}};function bM(e){return e===xt.TWEET?{indicatorColor:"bg-info"}:e===xt.USER?{indicatorColor:"bg-success"}:e===xt.CUSTOM?{indicatorColor:"bg-accent"}:{indicatorColor:"bg-neutral"}}function Il(e){const t=wM[e.name]??bM(e.type);return {rank:yM[e.name]??5e3,titleKey:_M[e.name],...t}}function vM(e,t){const n=Il(e).rank,r=Il(t).rank;return n!==r?n-r:e.name.localeCompare(t.name)}function Wp(e){return Il(e).rank>=9e3}function kM(){const{t:e}=Wn(),{extensions:t,resolvedTheme:n,showControlPanel:r,hookStats:o,runtimeModes:a,rawCaptureStats:i,toggleControlPanel:s}=jk(e("Open Control Panel")),l=C=>e(typeof C=="boolean"?C?"on":"off":String(C||"unknown")),c=C=>C===null?"":e("{{seconds}}s ago",{seconds:C}),h=(()=>{const C=o.value;if(!C)return e("Hooks: {{status}}",{status:e("unknown")});const k=C.lastAt?Math.max(0,Math.floor((Date.now()-C.lastAt)/1e3)):null;let T=C.lastUrl||"";try{const P=new URL(T);T=`${P.hostname}${P.pathname}`;}catch{}T.length>48&&(T=T.slice(0,45)+"...");const M=c(k);return C.lastUrl?e("Hooks: xhr {{xhr}}, fetch {{fetch}}, last {{url}} ({{age}})",{xhr:C.xhrMessages,fetch:C.fetchMessages,url:T,age:M}):e("Hooks: xhr {{xhr}}, fetch {{fetch}}",{xhr:C.xhrMessages,fetch:C.fetchMessages})})(),f=(()=>{const C=a.value,k=i.value,T=l(C==null?void 0:C.safeMode),M=l(C==null?void 0:C.hookMode),P=l(C==null?void 0:C.repairMode),F=Number((k==null?void 0:k.total)||0),I=Number((k==null?void 0:k.spool_count)||0),O=l(k==null?void 0:k.daemon_online),B=l(k==null?void 0:k.monitor_role),D=k!=null&&k.last_at?Math.max(0,Math.floor((Date.now()-k.last_at)/1e3)):null,v=c(D);return v?e("Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}, raw {{age}}",{safe:T,hook:M,repair:P,raw:F,spool:I,daemon:O,monitor:B,age:v}):e("Mode: safe {{safe}}, hook {{hook}}, repair {{repair}} | raw {{raw}}, spool {{spool}}, daemon {{daemon}}, monitor {{monitor}}",{safe:T,hook:M,repair:P,raw:F,spool:I,daemon:O,monitor:B})})(),m=t.value.slice().sort(vM),g=m.filter(C=>!Wp(C)),_=m.filter(Wp),b=C=>{const k=C.render();return C.enabled&&k?d(Li,{children:d(k,{extension:C})},C.name):null};return d(Jn,{children:[d(Vk,{currentTheme:n.value,onToggle:s}),d(JS,{currentTheme:n.value,show:!!r.value,title:"Scrollmark",byline:"By Kyle McCleary",description:e("Browse around to capture more data."),hookLine:h,healthLine:f,onToggle:s,children:d(Li,{children:[g.map(b),d(Li,{children:d(gM,{})}),_.length?d("div",{class:"divider mb-0 mt-1 opacity-60"}):null,_.map(b)]})})]})}const sd="BookmarksModule",Vi="SyntheticUsersModule",xM="twe_enable_synthetic_db_tools_v1",Gp=2500,Yp=1e4,Xp=1e3,SM=5e3,CM=1e4,TM=85e3,MM=87500,k_=997,RM={"1k":{count:1e3,folderDistribution:"mixed"},"10k":{count:1e4,folderDistribution:"mixed"},"50k":{count:5e4,folderDistribution:"mixed"},"100k":{count:1e5,folderDistribution:"mixed"},"250k":{count:25e4,folderDistribution:"mixed"},hugeFolder100k:{count:1e5,folderDistribution:"one-huge"},manyFolders100k:{count:1e5,folderDistribution:"many-small"},noFolders10k:{count:1e4,folderDistribution:"none"},captureScroll100k:{count:1e5,folderDistribution:"none",includeSearchDocuments:false}};function x_(e){let t=0;for(let n=0;n<e.length;n+=1)t=t*31+e.charCodeAt(n)|0;return Math.abs(t).toString(36)}function S_(e,t){if(t==="none")return {};if(t==="one-huge")return {id:"synthetic-folder-huge",name:"Synthetic Huge Folder",nameSource:"api"};const r=e%(t==="many-small"?2e3:48);return t==="mixed"&&e%7===0?{}:t==="mixed"&&e%5===0?{id:`synthetic-folder-${r}`}:{id:`synthetic-folder-${r}`,name:`Synthetic Folder ${r}`,nameSource:"api"}}function IM(e,t){const n=String(9e12+e);return {__typename:"User",id:n,rest_id:n,affiliates_highlighted_label:{},has_graduated_access:true,is_blue_verified:e%11===0,profile_image_shape:"Circle",legacy:{default_profile:false,default_profile_image:false,description:`Synthetic researcher ${e} writing about local archives, search, and browser performance.`,entities:{description:{urls:[]},url:{urls:[]}},fast_followers_count:e%1e3,favourites_count:e*3,followers_count:100+e*2,friends_count:50+e,has_custom_timelines:false,is_translator:false,listed_count:e%40,media_count:e%70,normal_followers_count:100+e*2,pinned_tweet_ids_str:[],possibly_sensitive:false,profile_interstitial_type:"",statuses_count:1e3+e,translator_type:"none",want_retweets:true,withheld_in_countries:[]},avatar:{image_url:`https://example.invalid/avatar-${e}.jpg`},core:{created_at:new Date(t-e*864e5).toUTCString(),name:`Synthetic Researcher ${e}`,screen_name:`synthetic_researcher_${e}`},dm_permissions:{can_dm:false},location:{location:"Synthetic Lab"},media_permissions:{can_media_tag:false},privacy:{protected:false},verification:{verified:e%13===0},relationship_perspectives:{following:false,followed_by:false},twe_private_fields:{created_at:t-e*864e5,updated_at:t}}}function EM(e,t,n,r,o){const a=String(8e12+e),i=n-e*6e4,s=S_(e,r),l=["local-first archive scaling","IndexedDB cursor pagination","advanced phrase search quality","bookmark folder recovery","virtual table row measurement","streaming export reliability"][e%6],c=o==="variable-heights"&&e%9===0?[`Synthetic bookmark ${e} about ${l}.`,`Exact phrase checkpoint ${e%97}.`,"This intentionally long row repeats enough local-archive context to force wrapped table content across several lines.","It exercises estimated source heights, measured row-height cache updates, translated header labels, and scroll spacer correction without requiring a full dataset load.","The row should remain readable and must not overlap adjacent rows when the virtual window moves."].join(" "):"",h=o==="variable-heights"&&e%7===0||o==="sparse-media"&&e%k_===0||o==="dense-media"?[{id_str:`synthetic-media-${e}`,media_key:`3_${8e12+e}`,type:"photo",media_url_https:`https://example.invalid/synthetic-media-${e}.jpg`,ext_alt_text:`Synthetic media thumbnail ${e}`,indices:[0,10]}]:[],f={__typename:"Tweet",rest_id:a,core:{user_results:{result:t}},edit_control:{edit_tweet_ids:[a],editable_until_msecs:String(i+36e5),is_edit_eligible:false,edits_remaining:"0"},is_translatable:false,views:{count:String(e%1e4),state:"EnabledWithCount"},source:"Scrollmark synthetic fixture",legacy:{bookmark_count:e%200,bookmarked:true,created_at:new Date(i).toUTCString(),conversation_id_str:a,display_text_range:[0,140],entities:{hashtags:[{indices:[0,9],text:"scrollmark"},{indices:[10,18],text:`topic${e%17}`}],media:h,symbols:[],timestamps:[],urls:[],user_mentions:[]},favorite_count:e%5e3,favorited:e%9===0,full_text:c||`Synthetic bookmark ${e} about ${l}. Exact phrase checkpoint ${e%97}. This row exists to test large local table performance.`,is_quote_status:false,lang:"en",possibly_sensitive:false,possibly_sensitive_editable:false,quote_count:e%30,reply_count:e%80,retweet_count:e%500,retweeted:false,user_id_str:t.rest_id,id_str:a},twe_private_fields:{created_at:i,updated_at:n,media_count:h.length||(e%3===0?1:0)}},m=f;return s.id&&(m.__bookmark_folder_id=s.id,m.__bookmark_folder_url=`https://x.com/i/bookmarks/${s.id}`),s.name&&(m.__bookmark_folder_name=s.name,m.__bookmark_folder_name_source=s.nameSource),f}function AM(e,t,n){const r=t,o=typeof r.__bookmark_folder_id=="string"?r.__bookmark_folder_id:"",a=typeof r.__bookmark_folder_name=="string"?r.__bookmark_folder_name:"",i=t.core.user_results.result,s=i.core.screen_name.toLowerCase(),l=[t.legacy.full_text,s,i.core.name,o,a].filter(Boolean).join(" "),c=fo(t).length;return {id:`live:${e}:tweet:${t.rest_id}`,source_key:`live:${e}`,source_kind:"live",entity_type:"tweet",entity_id:t.rest_id,extension_name:e,updated_at_ms:n,created_at_ms:t.twe_private_fields.created_at,observed_at_ms:n,primary_text:l,author_screen_name:s,author_id:i.rest_id,folder_id:o||void 0,folder_name:a||void 0,media_flag:c>0?1:0,route_type:"synthetic",lang:"en",flags_json:{has_media:c>0},exact_json:{author:[s,`@${s}`],folder:[o,a].filter(Boolean)},numeric_json:{favorite_count:t.legacy.favorite_count,retweet_count:t.legacy.retweet_count,reply_count:t.legacy.reply_count,bookmark_count:t.legacy.bookmark_count,media_count:c},raw_ref_table:"tweets",raw_ref_key:t.rest_id,doc_hash:x_(l)}}function DM(e,t,n){const r=[t.core.screen_name,t.core.name,t.legacy.description].filter(Boolean).join(" ");return {id:`live:${e}:user:${t.rest_id}`,source_key:`live:${e}`,source_kind:"live",entity_type:"user",entity_id:t.rest_id,extension_name:e,updated_at_ms:n,created_at_ms:t.twe_private_fields.created_at,observed_at_ms:n,primary_text:r,author_screen_name:t.core.screen_name.toLowerCase(),author_id:t.rest_id,flags_json:{is_blue_verified:t.is_blue_verified},exact_json:{author:[t.core.screen_name.toLowerCase(),`@${t.core.screen_name}`]},raw_ref_table:"users",raw_ref_key:t.rest_id,doc_hash:x_(r)}}function PM(e,t,n,r){return {id:`${e}-${t.rest_id}`,extension:e,type:xt.TWEET,data_key:t.rest_id,created_at:r-n*6e4}}function OM(e,t,n){return {id:`${Vi}-${e.rest_id}`,extension:Vi,type:xt.USER,data_key:e.rest_id,created_at:n-t*864e5}}async function FM(){await new Promise(e=>globalThis.setTimeout(e,0));}function Zp(e,t,n,r){n<Yp&&t<n||t!==n&&t%Yp!==0||console.info(`[scrollmark-synthetic-seed] ${e} ${t}/${n} elapsedMs=${Math.round(performance.now()-r)}`);}function LM(e,t,n,r){return n==="complete"||e<Xp||r==="dense-media"||r==="sparse-media"&&e%k_===0?true:t==="one-huge"?e%CM<SM||e>=TM&&e<MM:t==="many-small"?S_(e,t).id==="synthetic-folder-0"&&e/2e3<Xp:false}function NM(e={}){const t=Math.max(0,Math.floor(Number(e.count??1e4)));return {count:t,folderDistribution:e.folderDistribution??"mixed",rawRecordMode:e.rawRecordMode??"complete",contentProfile:e.contentProfile??"default",includeSearchDocuments:e.includeSearchDocuments??true,extensionName:e.extensionName||sd,clearFirst:e.clearFirst??true,userCount:Math.max(1,Math.floor(Number(e.userCount??Math.min(500,t/10))))}}async function BM(e={}){const t=performance.now(),{count:n,folderDistribution:r,rawRecordMode:o,contentProfile:a,includeSearchDocuments:i,extensionName:s,userCount:l,clearFirst:c}=NM(e),h=Date.now();let f=0;const m=[];c&&await Ge.clear();const g=Array.from({length:l},(C,k)=>IM(k,h)),_=g.map((C,k)=>OM(C,k,h)),b=i?g.map((C,k)=>DM(Vi,C,h-k)):[];await Ge.putSyntheticSeedRows({users:g,captures:_,searchDocuments:b}),Zp("users",g.length,g.length,t);for(let C=0;C<n;C+=Gp){const k=Math.min(n,C+Gp),T=[],M=[],P=[];for(let F=C;F<k;F+=1){const I=EM(F,g[F%g.length],h,r,a);LM(F,r,o,a)&&(T.push(I),f+=1);const O=PM(s,I,F,h);M.push(O),m.push(O),i&&P.push(AM(s,I,h-F));}await Ge.putSyntheticSeedRows({tweets:T,captures:M,searchDocuments:P}),Zp("tweets",k,n,t),await FM();}return await Ge.publishKnownCaptureCountSnapshot(s,n),await Ge.publishKnownCaptureCountSnapshot(Vi,_.length),await Ge.extPutCaptureIndexPagesFromOrderedCaptures(s,xt.TWEET,m,n,"newest"),Dn({extension:s,operation:"seedSyntheticBookmarks",count:n,keys:Array.from({length:Math.min(20,n)},(C,k)=>String(8e12+k))}),Dn({extension:Vi,operation:"seedSyntheticUsers",count:l,keys:g.slice(0,20).map(C=>C.rest_id)}),{ok:true,extensionName:s,tweetCount:n,userCount:g.length,storedTweetCount:f,captureCount:n+_.length,searchDocumentCount:i?n+b.length:0,folderDistribution:r,rawRecordMode:o,contentProfile:a,includeSearchDocuments:i,elapsedMs:Number((performance.now()-t).toFixed(2))}}async function UM(){return await Ge.clear(),Dn({operation:"clearSyntheticDatabase"}),{ok:true}}async function $M(e){const t=performance.now();let n={completedRows:0,completedTables:0,totalTables:0};const r=await Ge.import(e,{progressCallback:s=>(n={completedRows:Number(s.completedRows||0),totalRows:typeof s.totalRows=="number"?Number(s.totalRows||0):void 0,completedTables:Number(s.completedTables||0),totalTables:Number(s.totalTables||0),done:!!s.done},(n.done||n.completedRows===0||n.completedRows%2500===0)&&console.info(`[scrollmark-synthetic-import] rows=${n.completedRows}/${n.totalRows??"?"} tables=${n.completedTables}/${n.totalTables} elapsedMs=${Math.round(performance.now()-t)}`),true)}),o=await Ge.count(),a=await Ge.extGetCaptureCount(sd,xt.TWEET),i=await Ge.extGetSearchDocumentCount(sd,{entityType:"tweet"});return {ok:true,counts:o,bookmarkCaptureCount:a,bookmarkSearchDocumentCount:i,importResult:r,progress:n,elapsedMs:Number((performance.now()-t).toFixed(2))}}function HM(){try{if(typeof location<"u"&&`${location.search} ${location.hash}`.includes("scrollmarkSyntheticDb=1"))return !0;if(typeof localStorage<"u")return localStorage.getItem(xM)==="1"}catch{return  false}return  false}function jM(){if(!HM())return  false;const e={seedBookmarks:BM,importDbExport:$M,clearAll:UM,presets:RM};return globalThis.__scrollmarkSyntheticDb=e,true}const C_={id:{description:"The tweet ID",extractor:e=>e.rest_id},screen_name:{description:"The username of tweet author",extractor:e=>e.core.user_results.result.core.screen_name},name:{description:"The profile name of tweet author",extractor:e=>e.core.user_results.result.core.name},index:{description:"The media index in tweet (start from 0)",extractor:(e,t)=>String(_h(e,t))},num:{description:"The order of media in tweet (1/2/3/4)",extractor:(e,t)=>String(_h(e,t)+1)},date:{description:"The post date in YYYYMMDD format",extractor:e=>Pr(ha(e),"YYYYMMDD")},time:{description:"The post time in HHmmss format",extractor:e=>Pr(ha(e),"HHmmss")},type:{description:"The media type (photo/video/animated_gif)",extractor:(e,t)=>t.type},ext:{description:"The file extension of media (jpg/png/mp4)",extractor:(e,t)=>Lu(pa(t))}},qM=["photo","video","animated_gif"];function Qp(e,t,n){var o;const r=new Map;for(const a of e){if(a.__typename==="Tweet"||typeof a.__typename>"u"&&"core"in a){if(!t&&((o=a.legacy)!=null&&o.retweeted_status_result))continue;const i=fo(a).map(s=>{let l=n;for(const[c,h]of Object.entries(C_))l=l.replace(`{${c}}`,h.extractor(a,s));return {filename:l,type:s.type,url:pa(s)}});for(const s of i)r.set(s.filename,s);}if(a.__typename==="User"){if(a.avatar.image_url){const i=Lu(a.avatar.image_url),s=`${a.core.screen_name}_profile_image.${i}`;r.set(s,{filename:s,type:"photo",url:Ed(a.avatar.image_url)});}if(a.legacy.profile_banner_url){const i=Lu(a.legacy.profile_banner_url),s=`${a.core.screen_name}_profile_banner.${i}`;r.set(s,{filename:s,type:"photo",url:a.legacy.profile_banner_url});}}}return Array.from(r.values())}function Jp(e){if(e==null||typeof e!="object")return e;if(typeof structuredClone=="function")try{return structuredClone(e)}catch{}try{return JSON.parse(JSON.stringify(e))}catch{return e}}function em({title:e,resultRecords:t,selectedRecords:n,streamResultMediaRows:r,resultMediaSourceCount:o,selectionExcludedRecordIds:a=[],resultSetSnapshot:i,selectionMode:s,isTweet:l,show:c,onClose:h}){const{t:f}=Wn("exporter"),[m,g]=Hn(false),[_,b]=Hn(false),[C,k]=sr(false),[T,M]=De("75"),[P,F]=De("10"),[I,O]=De("8"),[B,D]=De("3"),[v,L]=De("3"),[$,Me]=Hn(ut.get("filenamePattern")),[Z,re]=Hn(0),[J,le]=Hn(0),[he,pe]=Hn(0),[ge,z]=Hn("result_set"),[ue,Pe]=De([]),[ce,Ee]=De([]),[Qe,X]=De([]),[ne,j]=De(false),[se,_e]=De(0),[we,Ye]=De(null),We=on({}),Se=_t(false),Tt=_t(0),[jt,Wt]=Hn([...qM,...l?["retweet"]:[]]),Gt=jt.includes("retweet"),Rt=!!r,et=It(()=>ge==="selected"?ce:ue,[ge,ue,ce]),at=It(()=>(ge==="result_set"&&Rt?Qe:Qp(et,Gt,$??"")).filter(ke=>jt.includes(ke.type)),[et,ge,$,jt,Gt,Rt,Qe]),wt=It(()=>at.slice(0,250),[at]),Ce=It(()=>new Set(wt.map(Oe=>Oe.filename)),[wt]);Je(()=>{if(!c){Se.current=false,X([]),j(false),_e(0);return}if(Se.current)return;Se.current=true;const Oe=s==="all"&&a.length?new Set(a):null;Pe(t.filter((ke,E)=>!(Oe!=null&&Oe.has(Oo(ke,E)))).map(ke=>Jp(ke))),Ee(n.map(ke=>Jp(ke))),Ye({...i,ids:[...i.ids],warnings:[...i.warnings]}),z(n.length>0&&s==="explicit"?"selected":"result_set"),re(0),le(0),pe(0),We.value={};},[t,i,n,a,s,re,z,le,pe,c,We]),Je(()=>{if(!c||!r){X([]),j(false),_e(0);return}let Oe=false;const ke=qe(),E=new Map;let x=0;const R=()=>{Oe||(X([...E.values()]),_e(x));};return (async()=>{j(true),X([]),_e(0);try{for await(const V of r()){if(Oe)return;x+=1;for(const be of Qp([V],Gt,$??""))E.set(be.filename,be);x%200===0&&(R(),await new Promise(be=>globalThis.setTimeout(be,0)));}R(),Be({kind:"export",name:"media-export-source-scan",durationMs:qe()-ke,value:E.size,tags:{rowsScanned:x,sourceRows:o??0,includeRetweets:Gt}});}finally{Oe||j(false);}})().catch(V=>{Oe||j(false),Be({kind:"export",name:"media-export-source-scan-error",durationMs:qe()-ke,tags:{error:V instanceof Error?V.message:String(V),rowsScanned:x}});}),()=>{Oe=true;}},[$,Gt,o,c,r]);const ht=(Oe,ke,E)=>{const x=Date.now();if((Oe===ke||x-Tt.current>120)&&(Tt.current=x,re(Oe),le(ke)),E!=null&&E.filename&&Ce.has(E.filename)){const R={...We.value,[E.filename]:100};We.value=R;}},it=async()=>{try{const Oe={minDelayBetweenStartsMs:Math.max(0,parseInt(T,10)||0),globalConcurrency:Math.max(1,parseInt(P,10)||1),perHostConcurrency:Math.max(1,parseInt(I,10)||1),videoConcurrency:Math.max(1,parseInt(B,10)||1),maxRetries:Math.max(0,parseInt(v,10)||0),onZipProgress:ke=>pe(ke)};g(!0),Tt.current=0,re(0),le(at.length),pe(0),await q0(`twitter-${e}-${ge==="selected"?"selected":"results"}-${Date.now()}-media.zip`,at,ht,Oe),g(!1);}catch(Oe){g(false),Ie.error(f("Failed to export media. Open DevTools for more details."),Oe);}},yt=(Oe=false)=>{const ke=at.map(E=>C?`${E.url}
  out=${E.filename}`:E.url).join(`
`);try{if(Oe){ns(new Blob([ke],{type:"text/plain;charset=utf-8"}),"media-urls.txt");return}navigator.clipboard.writeText(ke),b(!0),setTimeout(()=>b(!1),2e3);}catch(E){Ie.error(f("Failed to copy media URLs. Open DevTools for more details."),E);}};return d(lr,{class:"max-w-sm md:max-w-screen-sm sm:max-w-screen-sm max-h-full",title:`${e} ${f("Media")}`,show:c,onClose:h,children:[d("div",{class:"px-4 text-base overflow-y-scroll overscroll-none",children:[d("p",{class:"text-base-content text-opacity-60 leading-5 text-sm",children:f("Download and save media files from captured data. This may take a while depending on the amount of data. Media that will be downloaded includes: profile images, profile banners (for users), images, videos (for tweets).")}),d("div",{role:"alert",class:"alert text-sm py-2 mt-2 mb-2 grid-cols-[auto_minmax(auto,1fr)]",children:[d(tg,{size:24}),d("span",{children:f("Browser ZIP export now uses bounded parallel downloads. For very large video-heavy jobs, URL or aria2 export is still the safest low-memory path.")})]}),d("div",{class:"flex items-center gap-4 mb-1",children:[d("p",{class:"leading-8",children:f("Export scope:")}),d("label",{class:"label cursor-pointer gap-2 py-0",children:[d("input",{type:"radio",name:"media-export-scope",class:"radio radio-sm",checked:ge==="result_set",onChange:()=>z("result_set")}),d("span",{children:f("All current results")}),d("span",{class:"font-mono opacity-60",children:["(",(we==null?void 0:we.totalMatches)??ue.length,")"]})]}),d("label",{class:sn("label cursor-pointer gap-2 py-0",!ce.length&&"opacity-50"),children:[d("input",{type:"radio",name:"media-export-scope",class:"radio radio-sm",checked:ge==="selected",disabled:!ce.length,onChange:()=>z("selected")}),d("span",{children:f("Selected rows")}),d("span",{class:"font-mono opacity-60",children:["(",ce.length,")"]})]})]}),Rt&&ge==="result_set"?d("div",{class:"rounded-box-half border border-base-300 bg-base-200/60 px-3 py-2 text-xs leading-5 mb-2",children:[d("div",{class:"font-semibold",children:f("Source-backed media")}),d("div",{children:[f("rows scanned:")," ",d("span",{class:"font-mono",children:[se,o?`/${o}`:""]})]}),d("div",{children:[f("media URLs:")," ",d("span",{class:"font-mono",children:[at.length,ne?` ${f("loading")}`:""]})]})]}):null,we?d("div",{class:"rounded-box-half border border-base-300 bg-base-200/60 px-3 py-2 text-xs leading-5 mb-2",children:[d("div",{class:"font-semibold",children:f("Pinned result set")}),d("div",{class:"font-mono opacity-70",children:we.resultSetId}),d("div",{children:[f("Query"),":"," ",d("span",{class:"font-mono",children:we.queryText||"-"})]}),d("div",{children:[f("Sort"),": ",d("span",{class:"font-mono",children:we.sort})]})]}):null,l&&d("div",{class:"flex flex-wrap sm:grid grid-cols-4 sm:gap-2 items-center sm:h-9",children:[d("p",{class:"leading-8",children:f("Filename template:")}),d("div",{class:"tooltip tooltip-bottom col-span-3 before:whitespace-pre-line before:max-w-max","data-tip":Object.entries(C_).map(([Oe,ke])=>`{${Oe}} - ${f(ke.description)}`).reduce((Oe,ke)=>Oe+ke+`
`,""),children:d("input",{type:"text",class:"input input-bordered input-sm w-full",value:$,onChange:Oe=>{var E;const ke=(E=Oe==null?void 0:Oe.target)==null?void 0:E.value;Me(ke),ut.set("filenamePattern",ke);}})})]}),d("div",{class:"rounded-box-half border border-base-300 bg-base-200/60 px-3 py-2 mt-2 mb-2",children:[d("div",{class:"mb-1 flex items-center justify-between gap-2",children:[d("p",{class:"font-semibold text-sm",children:f("Download scheduler")}),d("span",{class:"font-mono text-[10px] opacity-60",children:f("Faster defaults are intended for bulk CDN transfer.")})]}),d("div",{class:"grid grid-cols-2 sm:grid-cols-5 gap-2",children:[d("label",{class:"form-control",children:[d("span",{class:"label-text text-xs",children:f("Start delay (ms)")}),d("input",{type:"number",min:"0",class:"input input-bordered input-sm",value:T,onInput:Oe=>M(Oe.currentTarget.value)})]}),d("label",{class:"form-control",children:[d("span",{class:"label-text text-xs",children:f("Global parallel")}),d("input",{type:"number",min:"1",max:"32",class:"input input-bordered input-sm",value:P,onInput:Oe=>F(Oe.currentTarget.value)})]}),d("label",{class:"form-control",children:[d("span",{class:"label-text text-xs",children:f("Per host")}),d("input",{type:"number",min:"1",max:"32",class:"input input-bordered input-sm",value:I,onInput:Oe=>O(Oe.currentTarget.value)})]}),d("label",{class:"form-control",children:[d("span",{class:"label-text text-xs",children:f("Videos")}),d("input",{type:"number",min:"1",max:"16",class:"input input-bordered input-sm",value:B,onInput:Oe=>D(Oe.currentTarget.value)})]}),d("label",{class:"form-control",children:[d("span",{class:"label-text text-xs",children:f("Retries")}),d("input",{type:"number",min:"0",max:"8",class:"input input-bordered input-sm",value:v,onInput:Oe=>L(Oe.currentTarget.value)})]})]})]}),d("div",{class:"flex flex-wrap sm:grid grid-cols-4 sm:gap-2 items-center sm:h-9",children:[d("p",{class:"leading-8 col-span-1 whitespace-nowrap sm:pl-2",children:f("Use aria2 format:")}),d("div",{class:"col-span-1 flex items-center",children:[d("input",{type:"checkbox",class:"toggle toggle-primary",checked:C,onChange:k}),d("a",{href:"https://aria2.github.io/manual/en/html/aria2c.html#input-file",target:"_blank",rel:"noopener noreferrer",class:"tooltip tooltip-bottom before:max-w-40 ml-1","data-tip":f("Click for more information. Each URL will be on a new line, with its filename on the next line. This format is compatible with aria2."),children:d(Ha,{size:20})})]})]}),d("div",{class:"flex flex-wrap sm:grid grid-cols-4 sm:gap-2 items-center sm:h-9",children:[d("p",{class:"leading-8",children:f("Media Filter:")}),d(Hg,{class:"col-span-3",options:[{label:f("filter.photo"),value:"photo"},{label:f("filter.video"),value:"video"},{label:f("filter.animated_gif"),value:"animated_gif"},...l?[{label:f("filter.retweet"),value:"retweet"}]:[]],selected:jt,onChange:Wt})]}),d("div",{class:"my-3 overflow-x-scroll",children:[d("table",{class:"table table-xs table-zebra",children:[d("thead",{children:d("tr",{children:[d("th",{}),d("th",{children:"#"}),d("th",{children:f("File Name")}),d("th",{children:f("Media Type")}),d("th",{children:f("Download URL")})]})}),d("tbody",{children:wt.map((Oe,ke)=>d("tr",{children:[d("td",{children:We.value[Oe.filename]?d(Fw,{class:"text-success",size:14}):d(Lw,{size:14})}),d("th",{children:ke+1}),d("td",{children:Oe.filename}),d("td",{children:f(`filter.${Oe.type}`)}),d("td",{children:d("a",{class:"link whitespace-nowrap",href:Oe.url,target:"_blank",rel:"noopener noreferrer",children:Oe.url})})]}))})]}),at.length>250?d("div",{class:"px-2 py-1 text-xs opacity-60",children:f("Preview limited to first 250 media items.")}):null,at.length>0?null:d("div",{class:"flex items-center justify-center h-28 w-full",children:d("p",{class:"text-base-content text-opacity-50",children:f(ne?"Loading media...":"No media selected.")})})]}),d("div",{class:"flex flex-col mt-6",children:[d("progress",{class:"progress progress-secondary w-full",value:Z/(J||1)*100,max:"100"}),d("span",{class:"text-sm h-4 leading-none mt-2 text-base-content text-opacity-60",children:he?`${f("Zipping")}: ${he}/${at.length}`:`${Z}/${at.length}`})]})]}),d("div",{class:"flex space-x-2 mt-2",children:[d("span",{class:"flex-grow"}),d("button",{class:"btn",onClick:h,children:f("Cancel")}),d("div",{class:"join",children:[d("button",{class:sn("btn join-item pr-2",ne&&"btn-disabled"),onClick:()=>yt(),disabled:ne,children:f(_?"Copied!":"Copy URLs")}),d("button",{class:sn("btn join-item pl-2",ne&&"btn-disabled"),onClick:()=>yt(true),disabled:ne,children:d(Uw,{})})]}),d("button",{class:sn("btn btn-secondary",(m||ne||at.length===0)&&"btn-disabled"),onClick:it,disabled:m||ne||at.length===0,children:[m&&d("span",{class:"loading loading-spinner"}),f("Start Export")]})]})]})}/**
   * Modified from `dexie-react-hooks` with some lines removed. The modified version
   * is specifically designed for `Observable` and `liveQuery` from Dexie.js.
   *
   * @license Apache-2.0
   * @see https://dexie.org/docs/dexie-react-hooks/useObservable()
   * @see https://github.com/dexie/Dexie.js/blob/v4.0.4/libs/dexie-react-hooks/src/useObservable.ts
   * @param observableFactory Function that returns an observable.
   * @param deps The observableFactory function will be re-executed if deps change.
   * @param defaultResult Result returned on initial render.
   * @returns The current result of the observable.
   */function VM(e,t,n){const r=_t({hasResult:false,result:n,error:null}),[,o]=ag(i=>i+1,0),a=It(()=>{const i=e();if(!i||typeof i.subscribe!="function")throw new TypeError("Observable factory given to useObservable() did not return a valid observable.");return r.current.hasResult||(typeof i.hasValue!="function"||i.hasValue())&&typeof i.getValue=="function"&&(r.current.result=i.getValue(),r.current.hasResult=true),i},t);if(Je(()=>{const i=a.subscribe(s=>{const l=r.current;(l.error!==null||l.result!==s)&&(l.error=null,l.result=s,l.hasResult=true,o(1));},s=>{r.current.error!==s&&(r.current.error=s,o(1));});return i.unsubscribe.bind(i)},t),r.current.error)throw r.current.error;return r.current.result}/**
   * A hook that subscribes to a live query and returns the current result.
   * Copied from `dexie-react-hooks` with some function overloads removed.
   *
   * @license Apache-2.0
   * @see https://dexie.org/docs/dexie-react-hooks/useLiveQuery()
   * @see https://github.com/dexie/Dexie.js/blob/v4.0.4/libs/dexie-react-hooks/src/useLiveQuery.ts
   * @see https://github.com/dexie/Dexie.js/blob/v4.0.4/src/live-query/live-query.ts
   * @param querier Function that returns a final result (Promise).
   * @param deps Variables that querier is dependent on.
   * @param defaultResult Result returned on initial render.
   * @returns The current result of the live query.
   */function T_(e,t,n){return VM(()=>W0(e),t||[],n)}const M_=80,R_=48,I_=240,El=5e4,E_="twe_allow_large_search_corpus_v1",zM="twe_search_document_full_load_count_override_v1",KM="twe_source_window_request_delay_ms_v1",WM=5e3,GM=12e3;function A_(){try{return localStorage.getItem(E_)==="1"}catch{return  false}}function tm(){try{const e=localStorage.getItem(zM);if(!e)return null;const t=Number(e);return !Number.isFinite(t)||t<=0?null:Math.floor(t)}catch{return null}}function YM(){try{const e=localStorage.getItem(KM);if(!e)return 0;const t=Number(e);return !Number.isFinite(t)||t<=0?0:Math.min(WM,Math.floor(t))}catch{return 0}}async function D_(){const e=YM();e<=0||await new Promise(t=>globalThis.setTimeout(t,e));}function XM(e){return e<=El||A_()?null:`Search corpus has ${e.toLocaleString()} indexed documents. Full in-memory search is blocked above ${El.toLocaleString()} documents; normal high-count search should use chunked DB-to-worker preparation instead. Set localStorage.${E_} = "1" to force the legacy path for local diagnostics.`}function nm(e){return e===xt.USER?"user":"tweet"}function ZM(e,t){const n=ho(e),r=It(()=>$S({extensionName:e,extensionType:t}),[e,n,t]),o=_t(""),a=_t(false),i=_t(null),[s,l]=De({records:[],loading:true,loadingWindow:false,loadedCount:0,totalCount:0,hasMore:false,windowStartIndex:0}),c=Nn(async(m,g,_=false)=>{const b=Math.max(0,Math.floor(Number(m)||0)),C=Math.max(b+1,Math.floor(Number(g)||0)),k=Math.min(I_,Math.max(R_,C-b)),T=`${n}:${b}:${k}`;if(o.current===T)return;if(o.current=T,a.current&&!_){i.current={startIndex:b,endIndex:C},Be({kind:"viewer",name:"source-window-request-coalesced",value:k,tags:{mode:"captures",extName:e,type:t,startIndex:b,limit:k}});return}a.current=true;const M=qe();l(P=>({...P,loading:_?true:P.loading,loadingWindow:!_}));try{await D_();const P=await r.getWindow({startIndex:b,limit:k});if(o.current!==T){Be({kind:"viewer",name:"source-window-stale-ignored",durationMs:qe()-M,value:P.rows.length,tags:{mode:"captures",extName:e,type:t,startIndex:b,limit:k,totalCount:P.totalCount,initial:_}});return}l({records:P.rows,loading:!1,loadingWindow:!1,loadedCount:P.rows.length,totalCount:P.totalCount,hasMore:P.hasAfter,windowStartIndex:b}),Be({kind:"viewer",name:"db-backed-capture-window",durationMs:qe()-M,value:P.rows.length,tags:{extName:e,type:t,startIndex:b,limit:k,totalCount:P.totalCount,initial:_}});}finally{a.current=false;const P=i.current;i.current=null,P&&(o.current="",c(P.startIndex,P.endIndex,false).catch(F=>{Ie.warn("DB-backed queued capture window load failed",F),l(I=>({...I,loading:false,loadingWindow:false}));}));}},[e,n,r,t]),h=Nn(async()=>{o.current="",await c(0,M_,true);},[c]);Je(()=>{h();},[h]);const f=Nn((m,g)=>{c(m,g,false).catch(_=>{Ie.warn("DB-backed capture window load failed",_),l(b=>({...b,loading:false,loadingWindow:false}));});},[c]);return {sourceKey:r.key,sourceDescriptor:r.descriptor,...s,requestWindow:f,reload:h,streamRows:()=>r.streamRows()}}function QM(e,t,n,r,o){const a=ho(e),i=It(()=>[...new Set((Array.isArray(n)?n:n?[n]:[]).map(k=>k.trim()).filter(Boolean))].sort(),[n]),s=i.join(","),l=It(()=>!r||!i.length?null:tp({extensionName:e,entityType:nm(t),folderIds:i,knownTotalCount:o}),[r,e,o,a,i,t]),c=_t(""),h=_t(false),f=_t(null),[m,g]=De({records:[],loading:false,loadingWindow:false,loadedCount:0,totalCount:0,hasMore:false,windowStartIndex:0}),_=Nn(async(k,T,M=false)=>{if(!l||!r||!i.length)return;const P=Math.max(0,Math.floor(Number(k)||0)),F=Math.max(P+1,Math.floor(Number(T)||0)),I=Math.min(I_,Math.max(R_,F-P)),O=`${a}:${s}:${P}:${I}`;if(c.current===O)return;if(c.current=O,h.current&&!M){f.current={startIndex:P,endIndex:F},Be({kind:"viewer",name:"source-window-request-coalesced",value:I,tags:{mode:"folder",extName:e,type:t,folderId:s,folderCount:i.length,startIndex:P,limit:I}});return}h.current=true;const B=qe();g(D=>({...D,loading:M?true:D.loading,loadingWindow:!M}));try{await D_();const D=await l.getWindow({startIndex:P,limit:I});if(c.current!==O){Be({kind:"viewer",name:"source-window-stale-ignored",durationMs:qe()-B,value:D.rows.length,tags:{mode:"folder",extName:e,type:t,folderId:s,folderCount:i.length,startIndex:P,limit:I,totalCount:D.totalCount,initial:M}});return}g({records:D.rows,loading:!1,loadingWindow:!1,loadedCount:D.rows.length,totalCount:D.totalCount,hasMore:D.hasAfter,windowStartIndex:P}),Be({kind:"viewer",name:"db-backed-folder-window",durationMs:qe()-B,value:D.rows.length,tags:{extName:e,type:t,folderId:s,folderCount:i.length,startIndex:P,limit:I,totalCount:D.totalCount,initial:M}});}finally{h.current=false;const D=f.current;f.current=null,D&&(c.current="",_(D.startIndex,D.endIndex,false).catch(v=>{Ie.warn("DB-backed queued folder window load failed",v),g(L=>({...L,loading:false,loadingWindow:false}));}));}},[r,e,a,i.length,s,l,t]),b=Nn(async()=>{if(c.current="",!l||!r||!i.length){g({records:[],loading:false,loadingWindow:false,loadedCount:0,totalCount:0,hasMore:false,windowStartIndex:0});return}await _(0,M_,true);},[r,_,i.length,l]);Je(()=>{b();},[b]);const C=Nn((k,T)=>{!l||!r||!i.length||_(k,T,false).catch(M=>{Ie.warn("DB-backed folder window load failed",M),g(P=>({...P,loading:false,loadingWindow:false}));});},[r,_,i.length,l]);return {sourceKey:(l==null?void 0:l.key)??"",sourceDescriptor:(l==null?void 0:l.descriptor)??tp({extensionName:e,entityType:nm(t),folderIds:i.length?i:["__inactive__"]}).descriptor,...m,active:!!(l&&r&&i.length),folderId:s,requestWindow:C,reload:b,streamRows:()=>(l==null?void 0:l.streamRows())??eR()}}function JM(e,t,n){const r=ho(e),o=It(()=>[...new Set((t??[]).map(c=>c.trim()).filter(Boolean))].sort(),[t]),a=o.join(","),i=It(()=>n?HS({extensionName:e,folderIds:o}):null,[n,e,r,o]),[s,l]=De(0);return Je(()=>{let c=false,h=null;if(!i){l(0);return}return h=globalThis.setTimeout(()=>{i.totalCount().then(f=>{c||l(f);});},GM),()=>{c=true,h!==null&&globalThis.clearTimeout(h);}},[a,i]),i?{sourceKey:i.key,sourceDescriptor:i.descriptor,totalCount:s,getWindow:async(c,h)=>{const f=await i.getWindow({startIndex:c,limit:h});return l(m=>Math.max(m,f.totalCount)),f},streamRows:()=>i.streamRows()}:null}async function*eR(){}function P_(e){const t=ho(e),n=T_(async()=>(await Ge.whenReady(),Math.max(0,Math.floor(Number(await Ge.extGetCaptureCount(e)||0)))),[e,t],0);return Math.max(0,Math.floor(Number(n)||0))}function tR(e,t,n=true){const r=ho(e),[o,a]=De({documents:[],loading:n,loaded:false,totalCount:0}),i=_t(""),s=_t(null),l=_t(""),c=_t(0),h=Nn(async()=>{if(s.current)return s.current;const m=`${r}:${e}:${t}:${c.current+1}`;c.current+=1,l.current=m,a(_=>({..._,loading:true}));const g=Ge.extGetSearchDocumentCount(e,{type:t}).then(async _=>{if(l.current!==m)return [];const b=Number(_)||0,C=tm()??b;if(XM(C))return l.current===m&&a({documents:[],loading:false,loaded:true,totalCount:C}),Be({kind:"search",name:"large-corpus-chunked-load-required",value:C,tags:{extName:e,type:t,limit:El}}),[];const[T,M]=await Promise.all([Ge.extGetSearchDocuments(e,t),Ge.extGetCaptureCount(e,t)]);if(l.current!==m)return [];const P=T??[];a({documents:P,loading:false,loaded:true,totalCount:C||P.length});const F=M??0,I=`${e}:${t}:${F}:${P.length}`,O=Math.max(50,Math.ceil(F*.02));return F>0&&P.length+O<F&&i.current!==I&&(i.current=I,Ge.extBackfillSearchDocuments(e,t).catch(B=>{Ie.warn("Search document backfill failed",B);})),P}).catch(_=>l.current!==m?[]:(Ie.warn("Search documents load failed",_),a({documents:[],loading:false,loaded:true,totalCount:0}),[])).finally(()=>{l.current===m&&(s.current=null);});return s.current=g,g},[e,r,t]),f=Nn(async m=>{var P,F;const g=qe(),_=Math.max(100,Math.min(5e3,Math.floor(m.chunkSize||1e3))),b=Number(await Ge.extGetSearchDocumentCount(e,{type:t}))||0,C=tm()??b;let k=0,T=0,M=false;try{for(;T<b;){if((P=m.isCancelled)!=null&&P.call(m)){M=!0;break}const I=await Ge.extGetSearchDocumentPage(e,{type:t,offset:T,limit:_});if((F=m.isCancelled)!=null&&F.call(m)){M=!0;break}const O=I.documents??[];if(!O.length||(k+=O.length,m.onChunk(O,{loaded:k,totalCount:C}),Be({kind:"search",name:"search-document-chunk-loaded",value:k,tags:{extName:e,type:t,chunkSize:_,chunkRows:O.length,totalCount:C,offset:T}}),T+=O.length,!I.hasAfter))break;await new Promise(B=>globalThis.setTimeout(B,0));}}finally{a(I=>({...I,documents:C>El&&!A_()?[]:I.documents,loading:false,loaded:I.loaded||!M,totalCount:C,blockedReason:void 0}));}return Be({kind:"search",name:M?"search-document-chunk-load-cancelled":"search-document-chunk-load-complete",durationMs:qe()-g,value:k,tags:{extName:e,type:t,chunkSize:_,totalCount:C}}),{loaded:k,totalCount:C,cancelled:M}},[e,t]);return Je(()=>{return s.current=null,l.current="",a({documents:[],loading:n,loaded:false,totalCount:0}),n&&h().then(()=>{}),()=>{}},[n,e,h,r,t]),{...o,load:h,loadChunks:f}}function nR(e,t,n=true){const r=ho(e),[o,a]=De({summary:null,loading:n});return Je(()=>{let i=false;if(!n){a({summary:null,loading:false});return}return a(s=>({...s,loading:true})),Ge.extGetSearchDocumentFolderFacets(e,{type:t}).then(s=>{i||a({summary:s,loading:false});}).catch(s=>{i||(Ie.warn("Search document folder facets failed",s),a({summary:null,loading:false}));}),()=>{i=true;}},[n,e,r,t]),o}function rR(e){return async()=>(Ie.debug("Clearing captures for extension:",e),Ge.extClearCaptures(e))}async function*rm(){}function om(e){const t=e,n=t==null?void 0:t.__bookmark_folder_name,r=t==null?void 0:t.__bookmark_folder_name_source,o=t==null?void 0:t.__bookmark_folder_id;return r==="api"&&typeof n=="string"&&n.trim().length>0?"api-name":typeof o=="string"&&o.trim().length>0?"id-only":"none"}function oR(e){const{isBookmarksModule:t,records:n,summary:r}=e,[o,a]=De({latestStatus:"none",counts:{"api-name":0,"id-only":0,none:0}}),[i,s]=De([]);return Je(()=>{if(!t){a({latestStatus:"none",counts:{"api-name":0,"id-only":0,none:0}}),s([]);return}let l=false,c=0,h=null;const f=()=>{if(l)return;const m=n??[],g={"api-name":0,"id-only":0,none:0},_=new Map;if(r){g["api-name"]=r.statusCounts["api-name"],g["id-only"]=r.statusCounts["id-only"],g.none=r.statusCounts.none;for(const b of r.facets)_.set(b.folderId,{label:b.label,count:b.count});}else for(const b of m){if(g[om(b)]++,!b||typeof b!="object")continue;const C=b,k=typeof C.__bookmark_folder_id=="string"?C.__bookmark_folder_id:"";if(!k.trim())continue;const T=C.__bookmark_folder_name_source==="api"&&typeof C.__bookmark_folder_name=="string"?C.__bookmark_folder_name.trim():"",M=_.get(k);M?M.count+=1:_.set(k,{label:T?`${T}`:`Folder ${k}`,count:1});}a({latestStatus:r?g["api-name"]>0?"api-name":g["id-only"]>0?"id-only":"none":m.length>0?om(m[m.length-1]):"none",counts:g}),s([..._.entries()].sort((b,C)=>C[1].count!==b[1].count?C[1].count-b[1].count:b[1].label.localeCompare(C[1].label)).map(([b,C])=>({value:b,label:`${C.label} (${C.count})`})));};return typeof window<"u"&&"requestIdleCallback"in window?c=window.requestIdleCallback(()=>f()):h=globalThis.setTimeout(f,80),()=>{l=true,c&&typeof window<"u"&&"cancelIdleCallback"in window&&window.cancelIdleCallback(c),h!==null&&globalThis.clearTimeout(h);}},[t,n,r]),{bookmarkStatus:o,bookmarkFolderOptions:i}}function aR({title:e,extension:t,fullscreen:n,onFullscreenChange:r}){return d(iR,{title:e,extension:t,fullscreen:n,onFullscreenChange:r})}function iR({title:e,extension:t,fullscreen:n,onFullscreenChange:r}){const{t:o}=Wn(),{name:a,type:i}=t,s=ZM(a,i),l=tR(a,i,false),c=nR(a,i,a==="BookmarksModule"&&i===xt.TWEET),h=rR(a),f=a==="BookmarksModule"&&i===xt.TWEET,[m,g]=De([]),_=f&&m.length>0?m:void 0,b=It(()=>{if(!(_!=null&&_.length)||!c.summary)return;const v=new Map(c.summary.facets.map(L=>[L.folderId,L.count]));return _.reduce((L,$)=>L+(Number(v.get($))||0),0)},[c.summary,_]),C=QM(a,i,_,!!(_!=null&&_.length),b),k=JM(a,_,i===xt.TWEET),T=C.active?C:s,M=T.records,{bookmarkStatus:P,bookmarkFolderOptions:F}=oR({isBookmarksModule:f,records:M,summary:c.summary}),[I,O]=sr(),B=[{id:"media-masonry",label:"Media masonry",icon:"grid",sourceBacked:true,component:v_}],D=(v,L)=>{const $=f&&L.totalCount>1e4&&L.resultRecords.length<L.totalCount&&!k;return d("div",{class:"flex items-center gap-2",children:[L.loading?d("span",{class:"font-mono text-[10px] opacity-60",children:o("loading {{loaded}}/{{total}}",{loaded:L.loadedCount,total:L.totalCount})}):null,L.loadingMore?d("span",{class:"font-mono text-[10px] opacity-60",children:o("loading more {{loaded}}/{{total}}",{loaded:L.loadedCount,total:L.totalCount})}):null,f&&d("button",{class:"btn btn-sm btn-accent btn-outline",onClick:()=>{const Me=Hd("bookmarks");$y({exported_at_ms:Date.now(),exported_at_iso:new Date().toISOString(),scope:"bookmarks",count:Me.length,history:Me},`twe-bookmarks-search-history-${Date.now()}.json`);},title:o("Export persisted bookmark search history"),children:o("Export Search History")}),f&&d("span",{class:"badge badge-outline badge-sm font-mono tooltip before:whitespace-pre-line before:max-w-40","data-tip":o(`latest: {{latest}}
api-name: {{apiName}}
id-only: {{idOnly}}
none: {{none}}`,{latest:o(P.latestStatus),apiName:P.counts["api-name"],idOnly:P.counts["id-only"],none:P.counts.none}),children:o("folder metadata: {{status}}",{status:o(P.latestStatus)})}),d("button",{class:"btn btn-sm btn-secondary",onClick:O,disabled:L.loading||$,title:L.loading?o("Wait for records to finish loading before exporting."):$?o("Media export is disabled for large result sets until media export has a source-backed stream."):void 0,children:o("Export Media")})]})};return i===xt.TWEET?d(rs,{title:e,viewStateKey:`${a}:${i}`,searchHistoryScope:f?"bookmarks":void 0,fullscreen:n,onFullscreenChange:r,loading:T.loading,loadingMore:T.loadingWindow,loadedCount:T.loadedCount,totalCount:T.totalCount,hasMore:T.hasMore,sourceMode:true,sourceModeFiltersActive:C.active,sourceWindowStartIndex:T.windowStartIndex,resultSourceDescriptor:T.sourceDescriptor,resultEntityType:"tweet",onSourceWindowChange:T.requestWindow,streamSourceRows:()=>T.streamRows(),streamMediaRows:()=>(k==null?void 0:k.streamRows())??rm(),mediaSourceKey:k==null?void 0:k.sourceKey,mediaSourceTotalCount:(k==null?void 0:k.totalCount)??void 0,getMediaWindow:k?(v,L)=>k.getWindow(v,L):void 0,onBookmarkFolderSelectionChange:g,hydrateRecordsByIds:v=>Ge.extGetTweetsByIds(v),records:M??[],searchDocuments:l.documents,searchDocumentsLoading:l.loading,searchDocumentsLoaded:l.loaded,searchDocumentTotalCount:l.totalCount,searchDocumentsBlockedReason:l.blockedReason,loadSearchDocuments:l.load,loadSearchDocumentChunks:l.loadChunks,columns:w_,clear:h,alternateViews:B,bookmarkFolderOptions:F,renderActions:D,renderExtra:(v,L)=>d(em,{title:e,resultRecords:L.resultRecords,selectedRecords:L.selectedRecords,streamResultMediaRows:()=>(k==null?void 0:k.streamRows())??rm(),resultMediaSourceCount:(k==null?void 0:k.totalCount)??void 0,selectionExcludedRecordIds:L.selectionExcludedRecordIds,resultSetSnapshot:L.resultSetSnapshot,selectionMode:L.selectionMode,isTweet:true,show:I,onClose:O})}):d(rs,{title:e,viewStateKey:`${a}:${i}`,searchHistoryScope:f?"bookmarks":void 0,fullscreen:n,onFullscreenChange:r,loading:T.loading,loadingMore:T.loadingWindow,loadedCount:T.loadedCount,totalCount:T.totalCount,hasMore:T.hasMore,sourceMode:true,sourceModeFiltersActive:C.active,sourceWindowStartIndex:T.windowStartIndex,resultSourceDescriptor:T.sourceDescriptor,resultEntityType:"user",onSourceWindowChange:T.requestWindow,streamSourceRows:()=>T.streamRows(),onBookmarkFolderSelectionChange:g,hydrateRecordsByIds:v=>Ge.extGetUsersByIds(v),records:M??[],searchDocuments:l.documents,searchDocumentsLoading:l.loading,searchDocumentsLoaded:l.loaded,searchDocumentTotalCount:l.totalCount,searchDocumentsBlockedReason:l.blockedReason,loadSearchDocuments:l.load,loadSearchDocumentChunks:l.loadChunks,columns:b_,clear:h,bookmarkFolderOptions:F,renderActions:D,renderExtra:(v,L)=>d(em,{title:e,resultRecords:L.resultRecords,selectedRecords:L.selectedRecords,selectionExcludedRecordIds:L.selectionExcludedRecordIds,resultSetSnapshot:L.resultSetSnapshot,selectionMode:L.selectionMode,isTweet:false,show:I,onClose:O})})}function qn({extension:e}){const{t}=Wn(),[n,r]=sr(),[o,a]=De(false),i=P_(e.name);if(e.type!==xt.TWEET&&e.type!==xt.USER)throw new Error("Incorrect use of CommonModuleUI component.");const s=Il(e),l=s.titleKey??e.name.replace("Module",""),c=t(l);return d(ls,{title:c,description:`${t("Captured:")} ${i}`,active:!!i&&i>0,onClick:r,indicatorColor:s.indicatorColor,panelClass:s.panelClass,children:d(lr,{class:o?"h-screen max-h-screen max-w-none":"max-w-4xl md:max-w-screen-md sm:max-w-screen-sm h-[82vh] max-h-[calc(100vh-4rem)]",title:c,show:n,fullscreen:o,onClose:()=>{a(false),r();},children:d(aR,{title:c,extension:e,fullscreen:o,onFullscreenChange:a})})})}const sR="UserMediaModule";function lR(e,t){return e===sR||!Array.isArray(t)||!t.length?[]:t.filter(n=>mx(n)).map(n=>String(n.rest_id||"").trim()).filter(Boolean)}const am="TweetIndexModule";async function Zr(e,t){const n=Array.isArray(t)?t:[];await Ge.extAddTweets(e,n);const r=n.map(a=>String((a==null?void 0:a.rest_id)||"").trim()).filter(Boolean);e!==am&&r.length&&await Ge.extAddTweetCaptureIds(am,r);const o=lR(e,n);return o.length&&await Ge.extAddTweetCaptureIds("UserMediaModule",o),{kind:"tweets",count:n.length}}async function ds(e,t){const n=Array.isArray(t)?t:[];return await Ge.extAddUsers(e,n),{kind:"users",count:n.length}}async function O_(e,t,n){const r=Array.isArray(t)?t:[];return await Ge.extAddUsers(e,r),n.length&&await Ge.extAddSocialEdges(e,n),{kind:"users",count:r.length}}function F_(e,t){Ie.info(`${e}: ${t} items received`);}function L_(e,t,n,r){Ie.debug(t.method,t.url,n.status,n.responseText),Ie.errorWithBanner(`${e}: Failed to parse API response`,r);}function Gn(e){return (t,n,r)=>{if(e.match(t,n))try{const o=e.parse(t,n,r),a=e.count?e.count(o):Array.isArray(o)?o.length:0,i=e.project?e.project(r.name,o,t,n):{kind:"none",count:a},s=l=>{var h;const c=l&&typeof l=="object"?l:{kind:"none",count:a};F_(e.moduleName,a),(h=e.onSuccess)==null||h.call(e,o,{ext:r,req:t,res:n,projection:c,count:a});};i&&typeof i.then=="function"?i.then(l=>s(l)).catch(l=>{Ie.errorWithBanner(`${e.moduleName}: Failed to write API response projection`,l instanceof Error?l:new Error(String(l)));}):s(i);}catch(o){L_(e.moduleName,t,n,o instanceof Error?o:new Error(String(o)));}}}const N_="twe_bookmark_folder_name_cache_v1",B_=260,cR=1800,ld=new Set,fu=new Set;function uR(){try{if(typeof localStorage>"u")return new Map;const e=localStorage.getItem(N_);if(!e)return new Map;const t=JSON.parse(e);if(!Array.isArray(t))return new Map;const n=[];for(const r of t)Array.isArray(r)&&r.length===2&&typeof r[0]=="string"&&typeof r[1]=="string"&&n.push([r[0],r[1]]);return new Map(n)}catch{return new Map}}function dR(e){try{if(typeof localStorage>"u")return;localStorage.setItem(N_,JSON.stringify([...e.entries()]));}catch{}}function fR(e){const t=[];for(const n of e){if(!n||typeof n!="object")continue;const r=String(n.rest_id||"").trim();if(r&&(t.push(r),t.length>=B_))break}return t}function hR(e){for(const t of e){const n=String(t||"").trim();n&&ld.add(n);}}function pR(e,t,n){if(!t||!ld.has(t)||fu.has(t))return;const r=zi.get(t);if(!r)return;const o=fR(n);fu.add(t),Ge.extBackfillRecentBookmarkFolderName(e,t,r,{candidateTweetIds:o,candidateLimit:B_,recentCaptureScanLimit:cR}).then(a=>{((a==null?void 0:a.inspected)||0)>0&&ld.delete(t),((a==null?void 0:a.updated)||0)>0&&Ie.info(`Bookmarks: folder-name backfill updated ${a.updated} rows for folder ${t}`);}).catch(()=>{}).finally(()=>{fu.delete(t);});}const zi=uR();function mR(e){if(!e||typeof e!="object")return  false;const t=e.timeline;if(!t||typeof t!="object")return  false;const n=t.instructions;return Array.isArray(n)}function cd(e,t=0,n=new Set){var o;if(!e||typeof e!="object"||t>5)return null;if(Array.isArray(e)){for(const a of e){const i=cd(a,t+1,n);if(i)return i}return null}if(mR(e))return ((o=e.timeline)==null?void 0:o.instructions)||null;const r=e;if(n.has(r))return null;n.add(r);for(const a of Object.keys(r)){const i=cd(r[a],t+1,n);if(i)return i}return null}function Al(e){if(typeof e=="number"&&Number.isFinite(e)){const n=String(Math.trunc(e));return /^\d+$/.test(n)?n:null}if(typeof e!="string")return null;const t=e.trim();return /^\d+$/.test(t)?t:null}function gR(e){const t=e.toLowerCase().replace(/[^a-z0-9]/g,"");return /^(bookmarkcollectionid|bookmarkfolderid|bookmarkcollection|folderid|collectionid|folder)$/.test(t)}function ga(e){const t=new Set;function n(r,o){const a=o&&gR(o)?Al(r):null;if(a)return a;if(!r||typeof r!="object")return null;if(Array.isArray(r)){for(const s of r){const l=n(s);if(l)return l}return null}const i=r;if(t.has(i))return null;t.add(i);for(const[s,l]of Object.entries(i)){const c=n(l,s);if(c)return c}return null}return n(e)}function yR(e){var r,o,a,i,s,l;const t=((o=(r=e.data)==null?void 0:r.bookmark_timeline_v2)==null?void 0:o.timeline)||((i=(a=e.data)==null?void 0:a.bookmark_timeline)==null?void 0:i.timeline)||((l=(s=e.data)==null?void 0:s.bookmark_collection_timeline)==null?void 0:l.timeline)||e.timeline;if(t&&Array.isArray(t.instructions))return t.instructions;const n=cd(e.data,0,new Set);if(n)return n;throw new Error("Bookmarks response missing timeline instructions")}const _R="__twe_bookmark_context_v1",wR="__twe_bookmark_strict_folder_id_v1",bR="twe_bookmark_strict_folder_id_v1",vR="__twe_bookmark_strict_mode_v1",kR="twe_bookmark_strict_mode_v1",xR="__twe_hook_stats_v1",SR="__twe_runtime_v1";function Ks(e){const t=n=>{if(!n||typeof n!="object")return;const r=n,o=Number(r[e]);r[e]=Number.isFinite(o)?o+1:1;};try{const n=globalThis;t(n[xR]),t(n[SR]);}catch{}}function Dl(e){try{return JSON.parse(e)}catch{return null}}function CR(e){try{return new URLSearchParams(e)}catch{return null}}function Wd(e){if(typeof e>"u"||e===null)return null;if(typeof e=="string"){let t=Dl(e);if(t!==null)return t;const n=CR(e);if(n){const r=n.get("variables");if(r&&(t=Dl(r),t!==null))return t;const o=n.get("bookmark_collection_id")??n.get("folder_id");if(o)return {bookmark_collection_id:o,folder_id:o}}return null}if(typeof Blob<"u"&&e instanceof Blob)return null;if(typeof FormData<"u"&&e instanceof FormData)try{const t=new URLSearchParams;for(const[n,r]of e.entries())typeof r=="string"?t.set(n,r):t.set(n,String(r));return Wd(t.toString())}catch{return null}return null}function hu(e){if(!e)return null;if(typeof e=="string"){const t=e.trim();if(!t)return null;if(/^\d+$/.test(t))return t;const n=ao(t);if(n)return n;const r=Dl(t);return r?ga(r):null}if(typeof e=="object"&&e!==null){const t=e;if(typeof t.folderId=="string"&&/^\d+$/.test(t.folderId))return t.folderId;if(typeof t.folderId=="number"&&Number.isFinite(t.folderId))return String(Math.trunc(t.folderId));if(typeof t.folder_id=="string"&&/^\d+$/.test(t.folder_id))return t.folder_id;if(typeof t.folder_id=="number"&&Number.isFinite(t.folder_id))return String(Math.trunc(t.folder_id));const n=ga(e);if(n)return n;const r=[t.pageUrl,t.url,t.location,t.currentUrl,t.folderUrl].find(o=>typeof o=="string");if(typeof r=="string"){const o=ao(r);if(o)return o}}return null}function pu(){try{return globalThis[_R]??null}catch{return null}}function TR(){try{const e=globalThis;if(e[vR]===!1)return null;const t=Al(e[wR]);if(t)return t}catch{}try{if(typeof localStorage>"u")return null;const e=localStorage.getItem(kR);if(e&&/^(0|false|off|no)$/i.test(e.trim()))return null;const t=Al(localStorage.getItem(bR));if(t)return t}catch{}return null}function MR(e){const t=U_(e.url);if(t)return t;if(e.body){const n=Wd(e.body);if(n){const r=ga(n);if(r)return r}}return null}function RR(e){if(!e)return null;const t=Dl(e);return t?ga(t):null}function ao(e){try{const t=new URL(e,"https://x.com"),n=["bookmark_collection_id","bookmarkcollectionid","bookmarkCollectionId","folder_id","folderid","folderId","collection_id","collectionid","collectionId"],r=t.pathname.match(/\/bookmarks\/(\d+)/)||t.pathname.match(/\/bookmarks\/folders\/(\d+)/)||t.pathname.match(/\/bookmarks\/folder\/(\d+)/)||t.pathname.match(/\/bookmark_folders\/(\d+)/);if(r&&r[1])return r[1];for(const o of n){const a=t.searchParams.get(o);if(a&&/^\d+$/.test(a))return a}for(const[o,a]of t.searchParams.entries())if(/folder/i.test(o)&&/^\d+$/.test(a))return a;return null}catch{return null}}function U_(e){try{const n=new URL(e,"https://x.com").searchParams.get("variables");if(!n)return null;let r;try{r=JSON.parse(decodeURIComponent(n));}catch{try{r=JSON.parse(n);}catch{return null}}const o=ga(r);if(o)return o;if(r&&typeof r=="object"){const a=r;for(const i of ["bookmark_collection_id","bookmarkcollectionid","bookmarkCollectionId","folder_id","folderid","folderId","collection_id","collectionid","collectionId"]){const s=a[i],l=Al(s);if(l)return l}}}catch{return null}return null}function IR(e){const t={folder_id:null,folder_name:null,folder_url:typeof location<"u"?location.href:""};if(!t.folder_id)try{const n=new URL(e.url,"https://x.com"),r=U_(e.url);if(r)t.folder_id=r;else {const o=ao(n.href);if(o)t.folder_id=o;else {const a=n.searchParams.get("variables");if(a){let i;try{i=JSON.parse(decodeURIComponent(a));}catch{i=JSON.parse(a);}const s=ga(i);s&&(t.folder_id=s);}}}}catch{}if(!t.folder_id&&e.body){const n=Wd(e.body);if(n){const r=ga(n);r&&(t.folder_id=r);}}if(!t.folder_id){const n=hu(e.bookmarkContext);n&&(t.folder_id=n);}if(!t.folder_id){const n=hu(pu());n&&(t.folder_id=n);}if(!t.folder_id&&e.bookmarkContext&&typeof e.bookmarkContext=="object"){const n=e.bookmarkContext,r=[n.folderUrl,n.pageUrl,n.url,n.location,n.currentUrl].filter(o=>typeof o=="string"&&o.length>0).map(o=>ao(o)).find(o=>!!o);r&&(t.folder_id=r);}if(e.bookmarkContext&&typeof e.bookmarkContext=="object"){const n=e.bookmarkContext;typeof n.folderUrl=="string"?t.folder_url=n.folderUrl:typeof n.pageUrl=="string"?t.folder_url=n.pageUrl:typeof n.url=="string"?t.folder_url=n.url:typeof n.location=="string"?t.folder_url=n.location:typeof n.currentUrl=="string"&&(t.folder_url=n.currentUrl);}else {const n=pu();if(n&&typeof n=="object"){const r=n;typeof r.folderUrl=="string"?t.folder_url=r.folderUrl:typeof r.pageUrl=="string"?t.folder_url=r.pageUrl:typeof r.url=="string"?t.folder_url=r.url:typeof r.location=="string"?t.folder_url=r.location:typeof r.currentUrl=="string"&&(t.folder_url=r.currentUrl);}}if(!t.folder_id){const n=typeof location<"u"?location.href:"";if(n){const r=ao(n);r&&(t.folder_id=r,t.folder_url=n);}}if(!t.folder_id&&e.responseText){const n=RR(e.responseText);n&&(t.folder_id=n);}if(!t.folder_id){const n=hu(pu());n&&(t.folder_id=n);}if(!t.folder_id&&typeof document<"u"&&(t.folder_id=ao(document.URL)),!t.folder_id&&typeof document<"u"){const n=document.querySelector('link[rel="canonical"]');n!=null&&n.href&&(t.folder_id=ao(n.href));}if(!t.folder_id&&typeof document<"u"){const n=document.querySelector('meta[property="og:url"]'),r=(n==null?void 0:n.content)??"";r&&(t.folder_id=ao(r));}if(t.folder_id){try{const r=new URL(t.folder_url||"","https://x.com");/\/i\/bookmarks\/?$/.test(r.pathname)&&(t.folder_url=`https://x.com/i/bookmarks/${t.folder_id}`);}catch{(!t.folder_url||/\/i\/bookmarks\/?$/.test(t.folder_url))&&(t.folder_url=`https://x.com/i/bookmarks/${t.folder_id}`);}const n=zi.get(t.folder_id);n&&(t.folder_name=n);}return t}function ER(e){var n,r,o,a,i;const t=new Set;try{const l=((i=(a=(o=(r=(n=JSON.parse(e).data)==null?void 0:n.viewer)==null?void 0:r.user_results)==null?void 0:o.result)==null?void 0:a.bookmark_collections_slice)==null?void 0:i.items)??[];let c=!1;for(const h of l)h.id&&typeof h.name=="string"&&zi.get(h.id)!==h.name&&(zi.set(h.id,h.name),t.add(h.id),c=!0);c&&dR(zi);}catch{}return t}function AR(e){try{const n=new URL(e,"https://x.com").pathname.toLowerCase().match(/\/graphql\/[^/]+\/([^/?#]+)/),r=String((n==null?void 0:n[1])||"").toLowerCase();return r?r==="bookmarks"||r==="bookmarktimeline"||r==="bookmarkfoldertimeline"||r==="bookmarkcollectiontimeline"||r==="bookmarkcollectionstimeline"||r==="bookmarkfoldersslice"||r==="bookmarkfolderslice"||r==="bookmarkcollectionslice"||r==="bookmarkslice":!1}catch{return  false}}const DR=(e,t,n)=>{if(/\/graphql\/.+\/BookmarkFoldersSlice/.test(e.url)){const r=typeof t.responseText=="string"?t.responseText:"";if(r){const o=ER(r);o.size>0&&hR(o);}return}if(AR(e.url))try{const r=MR(e),o=typeof location<"u"?ao(location.href):null;if(o&&r&&r!==o){Ks("bookmarkDropsCrossFolder"),Ie.debug(`Bookmarks: skip cross-folder request pageFolder=${o}, requestFolder=${r}`);return}const a=IR({...e,responseText:t.responseText}),i=TR();if(i){const c=r||o||a.folder_id||null,h=r?"request":o?"page":a.folder_id?"context":"none";if(!c){Ks("bookmarkDropsStrictNoExplicitFolder"),Ie.debug(`Bookmarks(strict): skip request without folder evidence: ${e.url}`);return}if(c!==i){Ks("bookmarkDropsStrictFolderMismatch"),Ie.debug(`Bookmarks(strict): skip folder mismatch source=${h} candidateFolder=${c}, strictFolder=${i}`);return}!r&&h!=="none"&&Ie.debug(`Bookmarks(strict): allowing request without explicit folder id via ${h} context`),a.folder_id!==i&&(a.folder_id=i,a.folder_url=`https://x.com/i/bookmarks/${i}`);}a.folder_id||Ks("bookmarkContextUnresolved");const s=_a(t,yR,c=>jn(c.content.itemContent));for(const c of s)if(c&&typeof c=="object"){const h=c;a.folder_id&&(h.__bookmark_folder_id=a.folder_id),a.folder_name&&(h.__bookmark_folder_name=a.folder_name),a.folder_id&&(h.__bookmark_folder_name_source=a.folder_name?"api":"id-only"),a.folder_url&&(h.__bookmark_folder_url=a.folder_url);}const l=`Bookmarks${a.folder_id?` (folder: ${a.folder_name??a.folder_id})`:""}`;Zr(n.name,s).then(()=>{pR(n.name,a.folder_id,s),F_(l,s.length);}).catch(c=>{Ie.errorWithBanner(`${l}: Failed to write API response projection`,c instanceof Error?c:new Error(String(c)));});}catch(r){L_("Bookmarks",e,t,r);}};class im extends bn{constructor(){super(...arguments);je(this,"name","BookmarksModule");je(this,"type",xt.TWEET);}intercept(){return DR}render(){return qn}}const PR=Gn({moduleName:"CommunityMembers",match:e=>/\/graphql\/.+\/(members|moderators)SliceTimeline_Query/.test(e.url),parse:(e,t)=>{const r=JSON.parse(t.responseText).data.communityResults.result;return (r.members_slice??r.moderators_slice).items_results.map(o=>o.result).filter(o=>o.__typename==="User")},project:(e,t)=>ds(e,t)});class OR extends bn{constructor(){super(...arguments);je(this,"name","CommunityMembersModule");je(this,"type",xt.USER);}intercept(){return PR}render(){return qn}}const FR=Gn({moduleName:"CommunityTimeline",match:e=>/\/graphql\/.+\/Community(Tweets|Media)Timeline/.test(e.url),parse:(e,t)=>{const r=JSON.parse(t.responseText).data.communityResults.result,a=(r.ranked_community_timeline??r.community_media_timeline).timeline.instructions,i=[],s=a.find(h=>h.type==="TimelineAddEntries"),l=(s==null?void 0:s.entries)??[];for(const h of l){if(ua(h)){const f=jn(h.content.itemContent);f&&i.push(f);}if(fx(h)){const f=h.content.items.map(m=>jn(m.item.itemContent)).filter(m=>!!m);i.push(...f);}}const c=a.find(h=>h.type==="TimelineAddToModule");if(c!=null&&c.moduleItems){const h=c.moduleItems.map(f=>jn(f.item.itemContent)).filter(f=>!!f);i.push(...h);}return i},project:(e,t)=>Zr(e,t)});class LR extends bn{constructor(){super(...arguments);je(this,"name","CommunityTimelineModule");je(this,"type",xt.TWEET);}intercept(){return FR}render(){return qn}}const Ki=ri([]),$_=new Map,H_=new Map,sm=[{test:e=>/\/dm\/inbox_initial_state\.json/.test(e),parse:e=>({entries:e.inbox_initial_state.entries,conversations:Object.values(e.inbox_initial_state.conversations),users:Object.values(e.inbox_initial_state.users)})},{test:e=>/\/dm\/inbox_timeline\/trusted\.json/.test(e),parse:e=>({entries:e.inbox_timeline.entries,conversations:Object.values(e.inbox_timeline.conversations),users:Object.values(e.inbox_timeline.users)})},{test:e=>/\/dm\/conversation\/\d+-?\d+\.json/.test(e),parse:e=>({entries:e.conversation_timeline.entries,conversations:Object.values(e.conversation_timeline.conversations),users:Object.values(e.conversation_timeline.users)})}],NR=Gn({moduleName:"DirectMessages",match:e=>sm.some(t=>t.test(e.url)),parse:(e,t)=>{const n=sm.find(l=>l.test(e.url));if(!n)return {messages:[],conversations:[],users:[]};const r=JSON.parse(t.responseText),{entries:o,conversations:a,users:i}=n.parse(r);return {messages:o.map(l=>l.message).filter(l=>!!l),conversations:a,users:i}},count:e=>e.messages.length,onSuccess:e=>{Ki.value=[...Ki.value,...e.messages],e.conversations.filter(Boolean).forEach(t=>$_.set(t.conversation_id,t)),e.users.filter(Boolean).forEach(t=>H_.set(t.id_str,t));}});function lm(e){const t=e?H_.get(e):null;return t?t.screen_name:""}function BR(e){const t=e?$_.get(e):null;return t?t.type:""}function cm(e){var t,n,r;return [(t=e.message_data.attachment)==null?void 0:t.photo,(n=e.message_data.attachment)==null?void 0:n.video,(r=e.message_data.attachment)==null?void 0:r.animated_gif].filter(o=>!!o)}const qr=jd(),UR=[qr.display({id:"select",size:48,minSize:48,maxSize:48,meta:{exportable:false},header:({table:e})=>d("input",{type:"checkbox",class:"checkbox checkbox-sm align-middle",checked:e.getIsAllRowsSelected(),indeterminate:e.getIsSomeRowsSelected(),onChange:e.getToggleAllRowsSelectedHandler()}),cell:({row:e})=>d("input",{type:"checkbox",class:"checkbox checkbox-sm",checked:e.getIsSelected(),disabled:!e.getCanSelect(),indeterminate:e.getIsSomeSelected(),onChange:e.getToggleSelectedHandler()})}),qr.accessor("id",{size:112,minSize:112,meta:{exportKey:"id",exportHeader:"ID"},header:()=>d(gt,{i18nKey:"ID"}),cell:e=>d("p",{class:"w-20 break-all font-mono text-xs",children:e.getValue()})}),qr.accessor("time",{size:136,minSize:128,meta:{exportKey:"time",exportHeader:"Date",exportValue:e=>Pr(Ji(+e.original.time),ut.get("dateTimeFormat"))},header:()=>d(gt,{i18nKey:"Date"}),cell:e=>d("p",{class:"w-24",children:Pr(+e.getValue(),ut.get("dateTimeFormat"))})}),qr.accessor("message_data.text",{size:360,minSize:280,maxSize:520,meta:{exportKey:"text",exportHeader:"Content"},header:()=>d(gt,{i18nKey:"Content"}),cell:e=>{var t;return d("div",{children:d("p",{class:"w-60 whitespace-pre-wrap",dangerouslySetInnerHTML:{__html:yl(e.row.original.message_data.text,(t=e.row.original.message_data.entities)==null?void 0:t.urls)}})})}}),qr.accessor(e=>cm(e),{id:"media",size:176,minSize:136,meta:{exportKey:"media",exportHeader:"Media",exportValue:e=>cm(e.original).map(t=>({type:t.type,url:t.url,thumbnail:ti(t.media_url_https,"thumb"),original:pa(t),ext_alt_text:t.ext_alt_text}))},header:()=>d(gt,{i18nKey:"Media"}),cell:e=>d(jg,{data:e.getValue().filter(t=>!!t),onClick:t=>{var n;return (n=e.table.options.meta)==null?void 0:n.setMediaPreview(pa(t))}})}),qr.accessor(e=>lm(e.message_data.sender_id),{id:"sender",size:144,minSize:120,meta:{exportKey:"sender",exportHeader:"Sender"},header:()=>d(gt,{i18nKey:"Sender"}),cell:e=>d("p",{class:"whitespace-pre",children:d("a",{class:"link",target:"_blank",href:`https://twitter.com/${e.getValue()}`,children:["@",e.getValue()]})})}),qr.accessor(e=>lm(e.message_data.recipient_id),{id:"recipient",size:144,minSize:120,meta:{exportKey:"recipient",exportHeader:"Recipient"},header:()=>d(gt,{i18nKey:"Recipient"}),cell:e=>d("p",{class:"whitespace-pre",children:e.getValue()?d("a",{class:"link",target:"_blank",href:`https://twitter.com/${e.getValue()}`,children:["@",e.getValue()]}):"N/A"})}),qr.accessor("conversation_id",{size:144,minSize:128,meta:{exportKey:"conversation_id",exportHeader:"Conversation ID"},header:()=>d(gt,{i18nKey:"Conversation ID"}),cell:e=>d("p",{class:"w-20 break-all font-mono text-xs",children:e.getValue()})}),qr.accessor(e=>BR(e.conversation_id),{id:"conversation_type",size:160,minSize:136,meta:{exportKey:"conversation_type",exportHeader:"Conversation Type"},header:()=>d(gt,{i18nKey:"Conversation Type"}),cell:e=>d("p",{class:"whitespace-pre",children:e.getValue()})}),qr.display({id:"actions",size:112,minSize:104,meta:{exportable:false},header:()=>d(gt,{i18nKey:"Actions"}),cell:e=>d("div",{class:"flex flex-row items-start space-x-1",children:d("button",{onClick:()=>{var t;return (t=e.table.options.meta)==null?void 0:t.setRawDataPreview(e.row.original)},class:"btn btn-xs btn-neutral whitespace-nowrap",children:d(gt,{i18nKey:"Details"})})})})];function $R(){const{t:e}=Wn(),[t,n]=sr(),r=e("DirectMessages"),o=Ki.value.length;return d(ls,{title:r,description:`${e("Captured:")} ${o}`,active:!!o&&o>0,onClick:n,indicatorColor:"bg-accent",panelClass:"border-l-2 border-accent/50 pl-2",children:d(lr,{class:"max-w-4xl md:max-w-screen-md sm:max-w-screen-sm min-h-[512px]",title:r,show:t,onClose:n,children:d(rs,{title:r,records:Ki.value,columns:UR,clear:()=>Ki.value=[]})})})}class HR extends bn{constructor(){super(...arguments);je(this,"name","DirectMessagesModule");je(this,"type",xt.CUSTOM);}intercept(){return NR}render(){return $R}}function jR(e){try{const n=new URL(e,"https://x.com").searchParams.get("variables");if(!n)return null;try{return JSON.parse(decodeURIComponent(n))}catch{return JSON.parse(n)}}catch{return null}}function qR(e){const t=jR(e.url),n=String((t==null?void 0:t.userId)||(t==null?void 0:t.user_id)||(t==null?void 0:t.rest_id)||(t==null?void 0:t.profileUserId)||"").trim(),r=String((t==null?void 0:t.screen_name)||(t==null?void 0:t.screenName)||(t==null?void 0:t.userScreenName)||"").trim();return {rest_id:n||void 0,screen_name:r||void 0}}function VR(e,t){var f,m,g,_,b,C;const n=JSON.parse(t.responseText),r=(m=(f=n==null?void 0:n.data)==null?void 0:f.user)==null?void 0:m.result,o=(_=(g=r==null?void 0:r.timeline)==null?void 0:g.timeline)==null?void 0:_.instructions;if(!Array.isArray(o))throw new Error("Followers response missing timeline instructions");const a=[];for(const k of o){if(k.type==="TimelineAddEntries")for(const T of k.entries||[]){if(Md(T)){const M=Yr(T.content.itemContent);M&&a.push(M);continue}if(Vo(T))for(const M of T.content.items||[]){if(M.item.itemContent.__typename!=="TimelineUser")continue;const P=Yr(M.item.itemContent);P&&a.push(P);}}if(k.type==="TimelineAddToModule")for(const T of k.moduleItems||[]){if(T.item.itemContent.__typename!=="TimelineUser")continue;const M=Yr(T.item.itemContent);M&&a.push(M);}}const i=qR(e),s=r&&r.__typename==="User"?{...r,rest_id:String(r.rest_id||i.rest_id||"").trim(),core:{...r.core,screen_name:String(((b=r.core)==null?void 0:b.screen_name)||i.screen_name||"").trim()}}:null,l=String((s==null?void 0:s.rest_id)||i.rest_id||"").trim(),c=String(((C=s==null?void 0:s.core)==null?void 0:C.screen_name)||i.screen_name||"").trim(),h=l?a.map(k=>{var T;return {id:`FollowersModule-follower-${l}-${k.rest_id}`,extension:"FollowersModule",relation_type:"follower",subject_user_id:l,subject_screen_name:c||void 0,related_user_id:k.rest_id,related_screen_name:(T=k.core)==null?void 0:T.screen_name,observed_at:Date.now(),provenance_surface:"followers"}}):[];return {subject:s,users:a,edges:h}}const zR=Gn({moduleName:"Followers",match:e=>/\/graphql\/.+\/(BlueVerified)*Followers/.test(e.url),parse:(e,t)=>VR(e,t),count:e=>e.users.length,project:(e,t)=>O_(e,t.users,t.edges)});class KR extends bn{constructor(){super(...arguments);je(this,"name","FollowersModule");je(this,"type",xt.USER);}intercept(){return zR}render(){return qn}}function WR(e){try{const n=new URL(e,"https://x.com").searchParams.get("variables");if(!n)return null;try{return JSON.parse(decodeURIComponent(n))}catch{return JSON.parse(n)}}catch{return null}}function GR(e){const t=WR(e.url),n=String((t==null?void 0:t.userId)||(t==null?void 0:t.user_id)||(t==null?void 0:t.rest_id)||(t==null?void 0:t.profileUserId)||"").trim(),r=String((t==null?void 0:t.screen_name)||(t==null?void 0:t.screenName)||(t==null?void 0:t.userScreenName)||"").trim();return {rest_id:n||void 0,screen_name:r||void 0}}function YR(e,t){var f,m,g,_,b,C;const n=JSON.parse(t.responseText),r=(m=(f=n==null?void 0:n.data)==null?void 0:f.user)==null?void 0:m.result,o=(_=(g=r==null?void 0:r.timeline)==null?void 0:g.timeline)==null?void 0:_.instructions;if(!Array.isArray(o))throw new Error("Following response missing timeline instructions");const a=[];for(const k of o){if(k.type==="TimelineAddEntries")for(const T of k.entries||[]){if(Md(T)){const M=Yr(T.content.itemContent);M&&a.push(M);continue}if(Vo(T))for(const M of T.content.items||[]){if(M.item.itemContent.__typename!=="TimelineUser")continue;const P=Yr(M.item.itemContent);P&&a.push(P);}}if(k.type==="TimelineAddToModule")for(const T of k.moduleItems||[]){if(T.item.itemContent.__typename!=="TimelineUser")continue;const M=Yr(T.item.itemContent);M&&a.push(M);}}const i=GR(e),s=r&&r.__typename==="User"?{...r,rest_id:String(r.rest_id||i.rest_id||"").trim(),core:{...r.core,screen_name:String(((b=r.core)==null?void 0:b.screen_name)||i.screen_name||"").trim()}}:null,l=String((s==null?void 0:s.rest_id)||i.rest_id||"").trim(),c=String(((C=s==null?void 0:s.core)==null?void 0:C.screen_name)||i.screen_name||"").trim(),h=l?a.map(k=>{var T;return {id:`FollowingModule-following-${l}-${k.rest_id}`,extension:"FollowingModule",relation_type:"following",subject_user_id:l,subject_screen_name:c||void 0,related_user_id:k.rest_id,related_screen_name:(T=k.core)==null?void 0:T.screen_name,observed_at:Date.now(),provenance_surface:"following"}}):[];return {subject:s,users:a,edges:h}}const XR=Gn({moduleName:"Following",match:e=>/\/graphql\/.+\/Following/.test(e.url),parse:(e,t)=>YR(e,t),count:e=>e.users.length,project:(e,t)=>O_(e,t.users,t.edges)});class ZR extends bn{constructor(){super(...arguments);je(this,"name","FollowingModule");je(this,"type",xt.USER);}intercept(){return XR}render(){return qn}}const QR=Gn({moduleName:"HomeTimeline",match:e=>/\/graphql\/.+\/Home(Latest)?Timeline/.test(e.url),parse:(e,t)=>_a(t,n=>n.data.home.home_timeline_urt.instructions,n=>jn(n.content.itemContent)),project:(e,t)=>Zr(e,t)});class JR extends bn{constructor(){super(...arguments);je(this,"name","HomeTimelineModule");je(this,"type",xt.TWEET);}intercept(){return QR}render(){return qn}}function eI(e){if(!(e instanceof HTMLElement))return  false;const t=e.getBoundingClientRect();return t.width>0&&t.height>0&&t.bottom>0&&t.top<window.innerHeight}function j_(e){const t=new Set,n=[];for(const r of e){const o=String(r||"").trim();o&&(t.has(o)||(t.add(o),n.push(o)));}return n}function ud(e){return String(e||"").replace(/\s+/g," ").replace(/\u00a0/g," ").trim()}function tI(e){if(typeof document>"u"||!e)return null;const t=[...document.querySelectorAll(`a[href*="/status/${e}"]`)],n=t.map(o=>o.closest("article")).find(o=>eI(o));if(n instanceof HTMLElement)return n;const r=t.map(o=>o.closest("article")).find(Boolean);return r instanceof HTMLElement?r:null}function nI(e,t){const n=e.querySelector(`a[href*="/status/${t}"]`),o=((n==null?void 0:n.getAttribute("href"))||"").match(/^\/([^/?#]+)\/status\//);return (o==null?void 0:o[1])||"unknown"}function rI(e,t){var o;const n=((o=e.querySelector('[data-testid="User-Name"] span'))==null?void 0:o.textContent)||"",r=ud(n);return r?r.replace(/^@/,""):t}function oI(e){const t=j_([...e.querySelectorAll('[data-testid="tweetText"], div[lang]')].map(r=>ud(r.textContent||"")));return t.length?t.join(`

`):ud(e.innerText||e.textContent||"")}function aI(e){if(!e)return new Date().toUTCString();const t=Date.parse(e);return Number.isFinite(t)?new Date(t).toUTCString():new Date().toUTCString()}function iI(e){const t=[...e.querySelectorAll("img")].find(n=>{const r=n.getAttribute("src")||"";return /profile_images/.test(r)});return (t==null?void 0:t.getAttribute("src"))||""}function sI(e,t){const n=[...e.querySelectorAll("img")].map(o=>({src:o.getAttribute("src")||"",width:o.naturalWidth||o.clientWidth||0,height:o.naturalHeight||o.clientHeight||0,alt:o.getAttribute("alt")||""})).filter(({src:o,alt:a})=>!o||/profile_images/.test(o)||/emoji/.test(o)||!/twimg\.com\//.test(o)?false:a==="Image"?true:/\/media\//.test(o)||/name=/.test(o));return j_(n.map(o=>o.src)).slice(0,8).map((o,a)=>{const i=n.find(s=>s.src===o);return {type:"photo",media_url_https:o,media_url:o,id_str:`${t}${a}`,media_key:`dom:${t}:${a}`,indices:[0,0],url:o,display_url:o,expanded_url:o,sizes:{medium:{w:(i==null?void 0:i.width)||1200,h:(i==null?void 0:i.height)||675,resize:"fit"},large:{w:(i==null?void 0:i.width)||1200,h:(i==null?void 0:i.height)||675,resize:"fit"},small:{w:(i==null?void 0:i.width)||680,h:(i==null?void 0:i.height)||382,resize:"fit"},thumb:{w:150,h:150,resize:"crop"}},original_info:{width:(i==null?void 0:i.width)||1200,height:(i==null?void 0:i.height)||675},features:{}}})}function lI(e,t,n){return {__typename:"User",id:e||"unknown",rest_id:e||"unknown",affiliates_highlighted_label:null,has_graduated_access:false,is_blue_verified:false,profile_image_shape:"Circle",legacy:{default_profile:false,default_profile_image:!n,description:"",entities:{description:{urls:[]}},fast_followers_count:0,favourites_count:0,followers_count:0,friends_count:0,has_custom_timelines:false,is_translator:false,listed_count:0,media_count:0,normal_followers_count:0,pinned_tweet_ids_str:[],possibly_sensitive:false,profile_interstitial_type:"",statuses_count:0,translator_type:"",want_retweets:true,withheld_in_countries:[]},avatar:{image_url:n},core:{name:t||e||"unknown",screen_name:e||"unknown",created_at:new Date(0).toUTCString()},dm_permissions:{can_dm:false},location:{location:""},media_permissions:{can_media_tag:false},privacy:{protected:false},verification:{verified:false},relationship_perspectives:{following:false,followed_by:false},twe_private_fields:{created_at:0,updated_at:Date.now()}}}function cI(e){var g;const t=String(e.tweetId||"").trim();if(!t)return null;const n=tI(t);if(!n)return null;const r=nI(n,t),o=rI(n,r),a=oI(n),i=((g=n.querySelector("time"))==null?void 0:g.getAttribute("datetime"))||null,s=aI(i),l=iI(n),c=sI(n,t),h=e.bookmarkFolderId?String(e.bookmarkFolderId):"",f=e.bookmarkFolderName?String(e.bookmarkFolderName).trim():"";return {__typename:"Tweet",rest_id:t,core:{user_results:{result:lI(r,o,l)}},edit_control:{edit_tweet_ids:[t],editable_until_msecs:"0",is_edit_eligible:false,edits_remaining:"0"},is_translatable:false,views:{count:"0",state:"Enabled"},source:"dom-snapshot",legacy:{bookmark_count:0,bookmarked:e.bookmarked===true,created_at:s,conversation_id_str:t,display_text_range:[0,a.length],entities:{media:c.length?c:void 0,user_mentions:[],urls:[],hashtags:[],symbols:[],timestamps:[]},extended_entities:c.length?{media:c}:void 0,favorite_count:0,favorited:false,full_text:a,is_quote_status:false,lang:"",possibly_sensitive:false,possibly_sensitive_editable:false,quote_count:0,reply_count:0,retweet_count:0,retweeted:false,user_id_str:r||"unknown",id_str:t},twe_private_fields:{created_at:Date.parse(s)||Date.now(),updated_at:Date.now(),media_count:c.length},...h?{__bookmark_folder_id:h,__bookmark_folder_url:`https://x.com/i/bookmarks/${h}`,__bookmark_folder_name_source:f?"api":"id-only",...f?{__bookmark_folder_name:f}:{}}:{}}}const uI=/\/graphql\/[^/]+\/([^/?#]+)/i,um=/^\d{5,25}$/,dI=new Set(["tweetid","tweetidstr","statusid","statusidstr","id","restid"]),fI=new Set(["userid","targetuserid","useridstr","sourceuserid"]),hI=new Set(["bookmarkcollectionid","bookmarkfolderid","bookmarkcollection","bookmarkfolder","folderid","collectionid"]),nl="BookmarksModule",dm="LikesModule",fm="FollowingModule",pI="twe_bookmark_folder_name_cache_v1";function mI(e){return String(e||"").toLowerCase().replace(/[^a-z0-9]/g,"")}function hm(e){if(typeof e=="number"&&Number.isFinite(e)){const n=String(Math.trunc(e));return um.test(n)?n:null}const t=String(e??"").trim();return t&&um.test(t)?t:null}function q_(e){const t=String(e||"").match(uI);return (t==null?void 0:t[1])||""}function gI(e){const t=String(e||"").toLowerCase(),n=q_(e).toLowerCase(),r=`${t} ${n}`;return /(bookmarktweettofolder|addbookmarktofolder|createbookmarktofolder|bookmarktofolder)/.test(r)?{kind:"bookmark_folder_add",targetType:"folder"}:/(createbookmark|addbookmark|bookmarkcreate|bookmark\/entries\/add)/.test(r)?{kind:"bookmark_add",targetType:"tweet"}:/(deletebookmark|removebookmark|destroybookmark|bookmark\/entries\/(remove|delete|destroy))/.test(r)?{kind:"bookmark_remove",targetType:"tweet"}:/(favoritetweet|createfavorite|like(add|tweet)?\b)/.test(r)?{kind:"like_add",targetType:"tweet"}:/(unfavoritetweet|deletefavorite|destroyfavorite|unlike(tweet)?\b)/.test(r)?{kind:"like_remove",targetType:"tweet"}:/(followuser|createfollow|friendships\/create(\.json)?\b)/.test(r)?{kind:"follow_add",targetType:"user"}:/(unfollowuser|destroyfollow|friendships\/destroy(\.json)?\b)/.test(r)?{kind:"follow_remove",targetType:"user"}:/(createretweet|statuses\/retweet\/)/.test(r)?{kind:"retweet_add",targetType:"tweet"}:/(deleteretweet|unretweet|statuses\/unretweet\/)/.test(r)?{kind:"retweet_remove",targetType:"tweet"}:null}function pm(e){try{return JSON.parse(e)}catch{return null}}function yI(e){if(!e)return {};const t=e.trim();if(!t)return {};if(t.startsWith("{")||t.startsWith("[")){const r=pm(t);return r&&typeof r=="object"?r:{}}const n={};try{const r=new URLSearchParams(t);for(const[o,a]of r.entries()){const i=a.startsWith("{")||a.startsWith("[")?pm(a)??a:a;if(o in n){const s=n[o];Array.isArray(s)?s.push(i):n[o]=[s,i];}else n[o]=i;}}catch{return {}}return n}function Wi(e,t,n,r=0,o=new Set){if(r>8||!e)return;if(Array.isArray(e)){for(const i of e)Wi(i,t,n,r+1,o);return}if(typeof e!="object")return;const a=e;if(!o.has(a)){o.add(a);for(const[i,s]of Object.entries(a)){const l=mI(i);if(t(l))if(Array.isArray(s))for(const c of s){const h=hm(c);h&&n.add(h);}else {const c=hm(s);c&&n.add(c);}Wi(s,t,n,r+1,o);}}}function _I(e,t){const n=new Set,r=new Set,o=new Set;Wi(e,s=>dI.has(s),n),Wi(e,s=>fI.has(s),r),Wi(e,s=>hI.has(s),o);const i=String(t||"").match(/\/(?:retweet|unretweet)\/(\d{5,25})/i);return i!=null&&i[1]&&n.add(i[1]),{tweetIds:[...n],userIds:[...r],folderIds:[...o]}}function wI(e,t){return e.targetType==="tweet"&&t.tweetIds.length?t.tweetIds:e.targetType==="user"&&t.userIds.length?t.userIds:e.targetType==="folder"&&t.folderIds.length?t.folderIds:t.tweetIds.length?t.tweetIds:t.userIds.length?t.userIds:t.folderIds.length?t.folderIds:["unknown"]}function mu(e){return e.replace(/[^a-zA-Z0-9:_-]/g,"_").slice(0,128)}function bI(e){if(!e)return null;try{if(typeof localStorage>"u")return null;const t=localStorage.getItem(pI);if(!t)return null;const n=JSON.parse(t);if(!Array.isArray(n))return null;for(const r of n)if(Array.isArray(r)&&r.length===2&&String(r[0]||"").trim()===e&&typeof r[1]=="string")return r[1]}catch{return null}return null}function Ri(e,t){const n={...e,legacy:{...e.legacy}};return typeof t.bookmarked=="boolean"&&(n.legacy.bookmarked=t.bookmarked),typeof t.favorited=="boolean"&&(n.legacy.favorited=t.favorited),typeof t.retweeted=="boolean"&&(n.legacy.retweeted=t.retweeted),t.bookmarkFolderId!==void 0&&(t.bookmarkFolderId?(n.__bookmark_folder_id=t.bookmarkFolderId,n.__bookmark_folder_url=`https://x.com/i/bookmarks/${t.bookmarkFolderId}`,n.__bookmark_folder_name_source=t.bookmarkFolderName?"api":"id-only",t.bookmarkFolderName?n.__bookmark_folder_name=t.bookmarkFolderName:delete n.__bookmark_folder_name):(delete n.__bookmark_folder_id,delete n.__bookmark_folder_name,delete n.__bookmark_folder_name_source,delete n.__bookmark_folder_url)),n}function mm(e,t){return {...e,relationship_perspectives:{...e.relationship_perspectives||{},following:t}}}async function gm(e,t){const n=e.filter(Boolean);if(!n.length)return {hydratedIds:[],tasks:[]};const r=[];for(const o of n){const a=cI({tweetId:o,bookmarked:t.bookmarked,bookmarkFolderId:t.bookmarkFolderId,bookmarkFolderName:t.bookmarkFolderName});a&&r.push(a);}return r.length?(await Ge.extAddTweets(nl,r),{hydratedIds:r.map(o=>o.rest_id),tasks:[]}):{hydratedIds:[],tasks:[]}}async function vI(e,t){const n=t.folderIds[0]??null,r=bI(n);switch(e.kind){case "bookmark_add":if(!t.tweetIds.length)return [];{const o=await gm(t.tweetIds,{bookmarked:true}),a=t.tweetIds.filter(i=>!o.hydratedIds.includes(i));return [...o.tasks,...a.length?[Ge.extAddTweetCaptureIds(nl,a,i=>Ri(i,{bookmarked:true}))]:[]]}case "bookmark_folder_add":if(!t.tweetIds.length)return [];{const o=await gm(t.tweetIds,{bookmarked:true,bookmarkFolderId:n??void 0,bookmarkFolderName:r}),a=new Set(o.hydratedIds),i=t.tweetIds.filter(s=>!a.has(s));return [...o.tasks,...i.length?[Ge.extAddTweetCaptureIds(nl,i,s=>Ri(s,{bookmarked:true,bookmarkFolderId:n??void 0,bookmarkFolderName:r}))]:[]]}case "bookmark_remove":return t.tweetIds.length?[Ge.extRemoveTweetCaptureIds(nl,t.tweetIds,o=>Ri(o,{bookmarked:false,bookmarkFolderId:null}))]:[];case "like_add":return t.tweetIds.length?[Ge.extAddTweetCaptureIds(dm,t.tweetIds,o=>Ri(o,{favorited:true}))]:[];case "like_remove":return t.tweetIds.length?[Ge.extRemoveTweetCaptureIds(dm,t.tweetIds,o=>Ri(o,{favorited:false}))]:[];case "follow_add":return t.userIds.length?[Ge.extAddUserCaptureIds(fm,t.userIds,o=>mm(o,true))]:[];case "follow_remove":return t.userIds.length?[Ge.extRemoveUserCaptureIds(fm,t.userIds,o=>mm(o,false))]:[];default:return []}}const kI=(e,t,n)=>{const r=gI(e.url);if(!r||t.status<200||t.status>=300)return;const o=yI(e.body),a=_I(o,e.url),i=wI(r,a),s=q_(e.url)||"none",l=mu(e.requestId||`${Date.now()}-${Math.random().toString(36).slice(2,9)}`),c=Date.now(),h=i.map((m,g)=>{const _=mu(m||"unknown"),b=`${l}-${r.kind}-${g}`,C=`${r.kind}|target:${_}|type:${r.targetType}|op:${mu(s)}`;return {id:b,data_key:C,created_at:c}}),f=[Ge.extAddCustomCaptures(n.name,h)];Xb({ts:c,extension:n.name,kind:r.kind,target_type:r.targetType,operation:s,request_id:e.requestId,tweet_ids:a.tweetIds,user_ids:a.userIds,folder_ids:a.folderIds,targets:i,mirror_task_count:f.length}),vI(r,a).then(m=>Promise.allSettled([...f,...m])).then(m=>{for(const g of m)g.status==="rejected"&&Ie.warn("InteractionEvents: failed to mirror interaction state",g.reason);}),Ie.info(`InteractionEvents: ${h.length} items received`),Ie.debug(`InteractionEvents: kind=${r.kind} targetType=${r.targetType} op=${s}`);};function xI(e){return e.slice().sort((t,n)=>Number(n.created_at||0)-Number(t.created_at||0))}function SI(e){if(!Number.isFinite(e)||e<=0)return "-";try{return new Date(e).toLocaleString()}catch{return String(e)}}function CI(e){var a,i;const t=String(e||"").split("|"),n=t[0]||"unknown",r=((a=t.find(s=>s.startsWith("target:")))==null?void 0:a.slice(7))||"-",o=((i=t.find(s=>s.startsWith("op:")))==null?void 0:i.slice(3))||"-";return {kind:n,target:r,operation:o}}function TI({extension:e}){const{t}=Wn(),[n,r]=sr(),o=P_(e.name),a=T_(()=>Ge.extGetCaptures(e.name),[e.name]),i=Array.isArray(a)?a:[],s=xI(i).slice(0,150);return d(ls,{title:t("Interaction Events"),description:`${t("Captured:")} ${o}`,active:o>0,onClick:r,indicatorColor:"bg-neutral",panelClass:"opacity-90",children:d(lr,{class:"max-w-4xl md:max-w-screen-md sm:max-w-screen-sm min-h-[512px]",title:t("Interaction Events"),show:n,onClose:r,children:[d("div",{class:"text-xs text-base-content opacity-70 mb-2",children:["Captures request-level actions (like/bookmark/follow/repost). Showing latest"," ",s.length," events."]}),d("div",{class:"overflow-y-auto max-h-[460px] border rounded-box-half border-base-300",children:d("table",{class:"table table-xs w-full",children:[d("thead",{children:d("tr",{children:[d("th",{children:"Time"}),d("th",{children:"Action"}),d("th",{children:"Target"}),d("th",{children:"Op"})]})}),d("tbody",{children:s.map(l=>{const c=CI(l.data_key);return d("tr",{children:[d("td",{class:"font-mono",children:SI(Number(l.created_at||0))}),d("td",{class:"font-mono",children:c.kind}),d("td",{class:"font-mono break-all",children:c.target}),d("td",{class:"font-mono break-all",children:c.operation})]},l.id)})})]})})]})})}class MI extends bn{constructor(){super(...arguments);je(this,"name","InteractionEventsModule");je(this,"type",xt.CUSTOM);}intercept(){return kI}render(){return TI}}const RI=Gn({moduleName:"Likes",match:e=>/\/graphql\/.+\/Likes/.test(e.url),parse:(e,t)=>_a(t,n=>n.data.user.result.timeline.timeline.instructions,n=>jn(n.content.itemContent)),project:(e,t)=>Zr(e,t)});class II extends bn{constructor(){super(...arguments);je(this,"name","LikesModule");je(this,"type",xt.TWEET);}intercept(){return RI}render(){return qn}}const EI=Gn({moduleName:"ListMembers",match:e=>/\/graphql\/.+\/ListMembers/.test(e.url),parse:(e,t)=>_a(t,n=>n.data.list.members_timeline.timeline.instructions,n=>Yr(n.content.itemContent)),project:(e,t)=>ds(e,t)});class AI extends bn{constructor(){super(...arguments);je(this,"name","ListMembersModule");je(this,"type",xt.USER);}intercept(){return EI}render(){return qn}}const DI=Gn({moduleName:"ListSubscribers",match:e=>/\/graphql\/.+\/ListSubscribers/.test(e.url),parse:(e,t)=>_a(t,n=>n.data.list.subscribers_timeline.timeline.instructions,n=>Yr(n.content.itemContent)),project:(e,t)=>ds(e,t)});class PI extends bn{constructor(){super(...arguments);je(this,"name","ListSubscribersModule");je(this,"type",xt.USER);}intercept(){return DI}render(){return qn}}const OI=Gn({moduleName:"ListTimeline",match:e=>/\/graphql\/.+\/ListLatestTweetsTimeline/.test(e.url),parse:(e,t)=>_a(t,n=>n.data.list.tweets_timeline.timeline.instructions,n=>jn(n.content.itemContent)),project:(e,t)=>Zr(e,t)});class FI extends bn{constructor(){super(...arguments);je(this,"name","ListTimelineModule");je(this,"type",xt.TWEET);}intercept(){return OI}render(){return qn}}const LI={info:"text-base-content",warn:"text-warning",error:"text-error"},NI=[{pattern:/^Database connected: (.+)$/,key:"Database connected: {{name}}",map:e=>({name:e[1]})},{pattern:/^App options migrated from v(.+) to v(.+)$/,key:"App options migrated from v{{oldVersion}} to v{{newVersion}}",map:e=>({oldVersion:e[1],newVersion:e[2]})},{pattern:/^Hooked into XMLHttpRequest \(installed=(true|false)\)$/,key:"Hooked into XMLHttpRequest (installed={{installed}})",map:e=>({installed:e[1]})},{pattern:/^Hook safe mode enabled \((.+)\)$/,key:"Hook safe mode enabled ({{reason}})",map:e=>({reason:e[1]})},{pattern:/^Hook repair failed \((\d+)\/(\d+)\)$/,key:"Hook repair failed ({{failures}}/{{limit}})",map:e=>({failures:e[1],limit:e[2]})},{pattern:/^Bookmark context tracking install failed; continuing without tracker \((.+)\)$/,key:"Bookmark context tracking install failed; continuing without tracker ({{details}})",map:e=>({details:e[1]})},{pattern:/^TWE_DIAG (.+)$/,key:"TWE_DIAG {{phase}}",map:e=>({phase:e[1]})},{pattern:/^([A-Za-z]+): (\d+) items received$/,key:"{{module}}: {{count}} items received",map:e=>({module:e[1],count:e[2]})},{pattern:/^Exporting to ZIP file: (.+)$/,key:"Exporting to ZIP file: {{filename}}",map:e=>({filename:e[1]})},{pattern:/^Exporting to (.+) file: (.+)$/,key:"Exporting to {{format}} file: {{filename}}",map:e=>({format:e[1],filename:e[2]})},{pattern:/^Streaming export to (.+) file: (.+)$/,key:"Streaming export to {{format}} file: {{filename}}",map:e=>({format:e[1],filename:e[2]})},{pattern:/^Migration completed: (\d+) users and (\d+) tweets updated\.$/,key:"Migration completed: {{users}} users and {{tweets}} tweets updated.",map:e=>({users:e[1],tweets:e[2]})},{pattern:/^TweetTombstone received \(Reason: (.+)\)$/,key:"TweetTombstone received (Reason: {{reason}})",map:e=>({reason:e[1]})}],V_="twe_raw_capture_daemon_url_v1",ym="twe_raw_search_query_v1",_m="twe_raw_search_sort_v1",wm="twe_raw_search_limit_v1",z_="twe_raw_search_saved_v1",K_="twe_raw_search_ranking_v1";function BI({lines:e}){const{t}=Wn(),n=e.value.slice().reverse(),r=o=>{for(const a of NI){const i=o.match(a.pattern);if(i)return t(a.key,a.map(i))}return t(o)};return d("pre",{class:"leading-none text-xs max-h-48 bg-base-200 overflow-y-scroll m-0 px-1 py-2.5 no-scrollbar rounded-box-half",children:n.map(o=>d("span",{class:LI[o.type],children:["#",o.index," ",r(o.line),`
`]},o.index))})}function UI(){const{t:e}=Wn(),[t,n]=De(()=>Ml()),r=o=>e(typeof o=="boolean"?o?"online":"offline":String(o||"unknown"));return Je(()=>{const o=()=>n(Ml());o();let a=null;const i=()=>{const s=document.hidden?9e3:2500;a=window.setTimeout(()=>{o(),i();},s);};return i(),window.addEventListener("twe:raw-event-v1",o),window.addEventListener("twe:raw-spool-state-v1",o),window.addEventListener("twe:raw-monitor-role-v1",o),()=>{a!==null&&window.clearTimeout(a),window.removeEventListener("twe:raw-event-v1",o),window.removeEventListener("twe:raw-spool-state-v1",o),window.removeEventListener("twe:raw-monitor-role-v1",o);}},[]),d("div",{class:"text-[11px] leading-tight bg-base-200 rounded-box-half px-2 py-1.5 mb-1",children:[d("div",{children:e("raw events: {{total}} | dropped: {{dropped}}",{total:Number(t.total||0),dropped:Number(t.dropped||0)})}),d("div",{children:e("spool: {{queued}} queued / {{enqueued}} enq / {{flushed}} flushed / {{failed}} failed",{queued:Number(t.spool_count||0),enqueued:Number(t.spool_enqueued||0),flushed:Number(t.spool_flushed||0),failed:Number(t.spool_failed||0)})}),d("div",{children:e("spool overflow drops: {{drops}} | unavailable: {{unavailable}} | oldest pending: {{age}}ms",{drops:Number(t.spool_drop_overflow||0),unavailable:Number(t.spool_unavailable||0),age:Number(t.oldest_pending_age_ms||0)})}),d("div",{children:t.daemon_last_error?e("daemon: {{status}} | last error: {{error}}",{status:r(t.daemon_online),error:t.daemon_last_error}):e("daemon: {{status}}",{status:r(t.daemon_online)})}),d("div",{children:e("monitor: {{role}} | leader: {{leader}} | lease: {{lease}}",{role:r(t.monitor_role),leader:t.monitor_leader_tab_id||"-",lease:Number(t.monitor_last_heartbeat_ms||0)})}),d("div",{children:e("monitor ticks route/viewport: {{route}}/{{viewport}} | suppressed route/viewport: {{suppressedRoute}}/{{suppressedViewport}}",{route:Number(t.monitor_ticks_route||0),viewport:Number(t.monitor_ticks_viewport||0),suppressedRoute:Number(t.monitor_suppressed_route||0),suppressedViewport:Number(t.monitor_suppressed_viewport||0)})})]})}function $I(){const{t:e}=Wn(),[t,n]=De(false),[r,o]=De(()=>kr());Je(()=>{const i=()=>o(kr());return window.addEventListener(Wf.eventName,i),()=>window.removeEventListener(Wf.eventName,i)},[]);const a=async()=>{if(!t){n(true);try{await Bd();}finally{n(false);}}};return d("div",{class:"mb-1 grid min-w-0 grid-cols-2 items-center gap-2",children:[d("label",{class:"label min-w-0 cursor-pointer gap-2 py-0",children:[d("span",{class:"text-[11px]",children:e("Diagnostic capture")}),d("input",{type:"checkbox",class:"toggle toggle-xs",checked:r,onChange:i=>{const s=i.target.checked;_g(s),o(s);}})]}),d("button",{class:"btn btn-xs h-auto min-h-6 max-w-full whitespace-normal break-words text-center leading-tight",onClick:()=>{wg();},children:e("Clear Buffers")}),d("button",{class:"btn btn-xs col-span-2 h-auto min-h-6 max-w-full whitespace-normal break-words text-center leading-tight",disabled:t,onClick:a,children:e(t?"Preparing diagnostics...":"Export Diagnostics Bundle")})]})}const rl={bm25:"",lexical:"",cover_density:"",recency:"",term_match:"",phrase_match:"",cover_bigram:"",cover_trigram:""};function Xa(e){try{return localStorage.getItem(e)}catch{return null}}function Ka(e,t){try{localStorage.setItem(e,t);}catch{}}function HI(){try{const e=Xa(z_);if(!e)return [];const t=JSON.parse(e);if(!Array.isArray(t))return [];const n=[];for(const r of t){if(!r||typeof r!="object")continue;const o=r,a=String(o.id||"").trim(),i=String(o.name||"").trim(),s=String(o.query||"").trim();!a||!i||n.push({id:a,name:i,query:s});}return n.slice(0,30)}catch{return []}}function jI(e){try{const t=JSON.stringify(e.slice(0,30));Ka(z_,t);}catch{}}function qI(){try{const e=Xa(K_);if(!e)return {...rl};const t=JSON.parse(e);if(!t||typeof t!="object")return {...rl};const n=t;return {bm25:String(n.bm25||"").trim(),lexical:String(n.lexical||"").trim(),cover_density:String(n.cover_density||"").trim(),recency:String(n.recency||"").trim(),term_match:String(n.term_match||"").trim(),phrase_match:String(n.phrase_match||"").trim(),cover_bigram:String(n.cover_bigram||"").trim(),cover_trigram:String(n.cover_trigram||"").trim()}}catch{return {...rl}}}function VI(e){try{Ka(K_,JSON.stringify({bm25:String(e.bm25||"").trim(),lexical:String(e.lexical||"").trim(),cover_density:String(e.cover_density||"").trim(),recency:String(e.recency||"").trim(),term_match:String(e.term_match||"").trim(),phrase_match:String(e.phrase_match||"").trim(),cover_bigram:String(e.cover_bigram||"").trim(),cover_trigram:String(e.cover_trigram||"").trim()}));}catch{}}function zI(e){const t=String(e||"").trim();if(!t)return "";const n=Number(t);return Number.isFinite(n)?String(n):""}function bm(e){const t={};for(const n of Object.keys(rl)){const r=zI(e[n]);r&&(t[n]=Number(r));}return t}function Pl(e){const t=String(e||"").trim();return t?t.replace(/\/+$/g,""):""}function gu(){const e=ut.get("rawCaptureDaemonUrl",""),t=Pl(String(e||""));if(t)return t;const n=Pl(Xa(V_)||"");return n||"http://127.0.0.1:8754"}function Ii(e,t){const n=String(e||"").trim(),r=String(t||"").trim();return r?n?`${n} ${r}`:r:n}function KI(){return `saved-${Date.now().toString(36)}-${Math.random().toString(36).slice(2,8)}`}function WI(e){const t=n=>{const r=new Map;for(const o of n){const a=String(o||"").trim();a&&r.set(a,(r.get(a)||0)+1);}return [...r.entries()].sort((o,a)=>a[1]!==o[1]?a[1]-o[1]:o[0].localeCompare(a[0])).slice(0,6).map(([o,a])=>({value:o,count:a}))};return {authors:t(e.map(n=>n.author_screen_name||"")),routes:t(e.map(n=>n.route_type||"")),folders:t(e.map(n=>n.bookmark_folder_id||""))}}function yu(e,t){const n=[],r=String(e||"").trim();return r&&n.push(r),t.fromUser.trim()&&n.push(`from:${t.fromUser.trim().replace(/^@+/,"")}`),t.toUser.trim()&&n.push(`to:${t.toUser.trim().replace(/^@+/,"")}`),t.folderIdOrName.trim()&&n.push(`bookmark_folder:${t.folderIdOrName.trim()}`),t.sourceContains.trim()&&n.push(`source:${t.sourceContains.trim()}`),t.cardName.trim()&&n.push(`card_name:${t.cardName.trim()}`),t.bookmarkedOnly&&n.push("is:bookmarked"),t.likedOnly&&n.push("is:liked"),t.mediaOnly&&n.push("filter:media"),t.repliesOnly&&n.push("filter:replies"),t.excludeRetweets&&n.push("-filter:retweets"),t.verifiedOnly&&n.push("filter:verified"),t.blueVerifiedOnly&&n.push("filter:blue_verified"),n.join(" ").trim()}const GI=["filter:replies","-filter:replies","filter:media","-filter:retweets","id:","from_id:","in_reply_to_id:","domain:x.com","is:bookmarked","is:liked","filter:verified","filter:blue_verified","source:iphone","card_name:summary_large_image","min_faves:100","lang:en","since:2026-01-01","until:2026-12-31","OR"],vm=["AND","OR","NOT","from:","from_id:","author_id:","to:","to_id:","in_reply_to_id:","id:","lang:","route:","bookmark_folder:","conversation_id:","source:","card_name:","url:","domain:","filter:replies","filter:retweets","-filter:retweets","filter:media","filter:links","filter:verified","filter:blue_verified","is:bookmarked","is:liked","is:verified","is:blue_verified","has:links","has:hashtags","has:mentions","has:cashtags","min_faves:","min_likes:","min_retweets:","min_replies:","min_bookmarks:","since:","until:"],YI="search.export.v1";function XI(e){const t=String(e||"");if(!t.trim())return "";const n=t.split(/\s+/g);return String(n[n.length-1]||"").trim()}function ZI(e,t){const n=String(t||"").trim();if(!n)return String(e||"");const r=String(e||"");return r.trim()?/\s$/.test(r)?`${r}${n}`:r.replace(/\S+$/,n).trim():n}function QI(e){const t=XI(e).toLowerCase();return t?vm.filter(n=>n.toLowerCase().startsWith(t)||n.toLowerCase().includes(t)).slice(0,10):vm.slice(0,10)}function JI(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function eE(e,t){const n=String(e),r=[...new Set(t.map(i=>String(i||"").trim().toLowerCase()))].filter(i=>i.length>=2).sort((i,s)=>s.length-i.length).slice(0,24);if(!n||!r.length)return d(Jn,{children:n});const o=new RegExp(`(${r.map(i=>JI(i)).join("|")})`,"ig"),a=n.split(o);return d(Jn,{children:a.map((i,s)=>{const l=i.toLowerCase();return r.includes(l)?d("mark",{class:"bg-warning/30 px-[1px] rounded-[2px]",children:i},`hl-${s}`):d(Jn,{children:i},`txt-${s}`)})})}function tE(e){const t=[];return e.author_screen_name&&t.push(`from:${e.author_screen_name}`),e.route_type&&t.push(`route:${e.route_type}`),e.bookmark_folder_id&&t.push(`bookmark_folder:${e.bookmark_folder_id}`),e.has_media&&t.push("filter:media"),e.has_links&&t.push("has:links"),e.bookmarked&&t.push("is:bookmarked"),e.favorited&&t.push("is:liked"),e.author_verified&&t.push("is:verified"),e.author_blue_verified&&t.push("is:blue_verified"),[...new Set(t)].slice(0,8)}function nE(e){const t=Date.now();return {schema_version:YI,generated_at_ms:t,generated_at_iso:new Date(t).toISOString(),producer:{name:"twitter-web-exporter.local-search",version:"1"},source:{daemon_base_url:e.daemonBaseUrl,page_url:typeof location<"u"?location.href:""},request:{query:e.effectiveQuery,sort:e.sort,limit:e.limit,offset:e.offset,ranking:e.ranking},response:e.payload}}function rE(){var fe,Ve,pt,St,vt,Yt;const[e,t]=De(()=>gu()),[n,r]=De(()=>Xa(ym)||""),[o,a]=De(()=>{const K=Xa(_m);return K==="newest"||K==="oldest"||K==="relevance"?K:"relevance"}),[i,s]=De(()=>{const K=Number(Xa(wm)||"50");return Number.isFinite(K)&&K>0&&K<=500?Math.floor(K):50}),[l,c]=De(0),[h,f]=De(()=>HI()),[m,g]=De(""),[_,b]=De(""),[C,k]=De(""),[T,M]=De(""),[P,F]=De(""),[I,O]=De(""),[B,D]=De(""),[v,L]=De(false),[$,Me]=De(false),[Z,re]=De(false),[J,le]=De(false),[he,pe]=De(false),[ge,z]=De(false),[ue,Pe]=De(false),[ce,Ee]=De(""),[Qe,X]=De(""),[ne,j]=De(""),[se,_e]=De(""),[we,Ye]=De(""),[We,Se]=De(""),[Tt,jt]=De(""),[Wt,Gt]=De(""),[Rt,et]=De(false),[at,wt]=De(""),[Ce,ht]=De(null),[it,yt]=De("");Je(()=>{const K=qI();Ee(K.bm25),X(K.lexical),j(K.cover_density),_e(K.recency),Ye(K.term_match),Se(K.phrase_match),jt(K.cover_bigram),Gt(K.cover_trigram);},[]),Je(()=>{Ka(ym,n);},[n]),Je(()=>{Ka(_m,o);},[o]),Je(()=>{Ka(wm,String(i));},[i]),Je(()=>{jI(h);},[h]),Je(()=>{VI({bm25:ce,lexical:Qe,cover_density:ne,recency:se,term_match:we,phrase_match:We,cover_bigram:Tt,cover_trigram:Wt});},[ce,Qe,ne,se,we,We,Tt,Wt]);const Oe=async(K=l)=>{if(Rt)return;const ze=Pl(e||gu());if(!ze){wt("Missing recorder daemon URL.");return}et(true),wt("");try{const Dt=yu(n,{fromUser:C,toUser:T,folderIdOrName:P,sourceContains:I,cardName:B,bookmarkedOnly:v,likedOnly:$,mediaOnly:Z,repliesOnly:J,excludeRetweets:he,verifiedOnly:ge,blueVerifiedOnly:ue}),Re=new URLSearchParams;Dt.trim()&&Re.set("q",Dt.trim()),Re.set("sort",o),Re.set("limit",String(i)),Re.set("offset",String(Math.max(0,K)));const Fe=bm({bm25:ce,lexical:Qe,cover_density:ne,recency:se,term_match:we,phrase_match:We,cover_bigram:Tt,cover_trigram:Wt});for(const[st,Ut]of Object.entries(Fe))Re.set(`rank_${st}`,String(Ut));const rt=await fetch(`${ze}/query/search?${Re.toString()}`),Ue=await rt.json();if(!rt.ok||!(Ue!=null&&Ue.ok)||!Ue.query)throw new Error((Ue==null?void 0:Ue.error)||`HTTP ${rt.status}`);ht(Ue.query),c(Math.max(0,K)),yt(Dt);}catch(Dt){wt(Dt instanceof Error?Dt.message:String(Dt)),ht(null);}finally{et(false);}},ke=K=>{const ze=String(K||"").trim();if(!ze)return;const Dt=`https://x.com/i/web/status/${ze}`;window.open(Dt,"_blank","noopener,noreferrer");},E=()=>{const K=Math.max(0,l-i);Oe(K);},x=()=>{const K=l+i;Oe(K);},R=!!Ce&&l+i<Ce.total_matches,U=WI((Ce==null?void 0:Ce.rows)||[]),V=()=>{const K=yu(n,{fromUser:C,toUser:T,folderIdOrName:P,sourceContains:I,cardName:B,bookmarkedOnly:v,likedOnly:$,mediaOnly:Z,repliesOnly:J,excludeRetweets:he,verifiedOnly:ge,blueVerifiedOnly:ue}).trim();if(!K)return;const ze=m.trim()||`Saved ${new Date().toLocaleString()}`;f(Dt=>[{id:KI(),name:ze,query:K},...Dt.filter(Fe=>Fe.query!==K)].slice(0,30)),g("");},be=K=>{const ze=h.find(Dt=>Dt.id===K);ze&&(r(ze.query),b(K));},ie=()=>{const K=_.trim();K&&(f(ze=>ze.filter(Dt=>Dt.id!==K)),b(""));},Le=()=>{if(!Ce)return;const K=nE({daemonBaseUrl:Pl(e||gu()),effectiveQuery:it||yu(n,{fromUser:C,toUser:T,folderIdOrName:P,sourceContains:I,cardName:B,bookmarkedOnly:v,likedOnly:$,mediaOnly:Z,repliesOnly:J,excludeRetweets:he,verifiedOnly:ge,blueVerifiedOnly:ue}),payload:Ce,sort:o,limit:i,offset:l,ranking:bm({bm25:ce,lexical:Qe,cover_density:ne,recency:se,term_match:we,phrase_match:We,cover_bigram:Tt,cover_trigram:Wt})});$y(K,`twe-search-export-${Date.now()}.json`);},Ne=QI(n),tt=((fe=Ce==null?void 0:Ce.parsed)==null?void 0:fe.positive_terms)||[];return d("div",{class:"text-[11px] leading-tight bg-base-200 rounded-box-half px-2 py-1.5 mb-1",children:[d("div",{class:"font-semibold mb-1",children:"Local Recorder Search"}),d("div",{class:"mb-1",children:[d("label",{class:"text-[10px] opacity-70",children:"Daemon URL"}),d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono mt-0.5",value:e,onInput:K=>{const ze=K.target.value;t(ze),Ka(V_,ze),ut.set("rawCaptureDaemonUrl",ze);}})]}),d("div",{class:"mb-1",children:[d("label",{class:"text-[10px] opacity-70",children:"Query (Twitter-style operators)"}),d("textarea",{class:"textarea textarea-bordered w-full min-h-16 mt-0.5 font-mono text-[11px]",value:n,onInput:K=>r(K.target.value),onKeyDown:K=>{K.key==="Enter"&&(K.metaKey||K.ctrlKey)&&(K.preventDefault(),Oe(0));}})]}),d("div",{class:"flex flex-wrap gap-1 mb-1",children:Ne.map(K=>d("button",{class:"btn btn-ghost btn-xs h-5 min-h-0 px-1 font-mono opacity-80",onClick:()=>r(ze=>ZI(ze,K)),children:K},`suggest-${K}`))}),d("details",{class:"mb-1",children:[d("summary",{class:"cursor-pointer text-[10px] opacity-70",children:"operator quick reference"}),d("div",{class:"text-[10px] font-mono mt-0.5 opacity-80 leading-tight",children:"boolean: `AND` `OR` `NOT` `(...)` | filters: global `AND` semantics"}),d("div",{class:"text-[10px] font-mono opacity-80 leading-tight",children:"core: `from:` `from_id:` `to:` `to_id:` `id:` `domain:` `filter:*` `is:*` `has:*` `lang:` `since:` `until:`"}),d("div",{class:"text-[10px] font-mono opacity-80 leading-tight",children:"ranking params: `rank_bm25` `rank_lexical` `rank_cover_density` `rank_recency`"}),d("div",{class:"text-[10px] font-mono opacity-80 leading-tight",children:"phrase/density: `rank_term_match` `rank_phrase_match` `rank_cover_bigram` `rank_cover_trigram`"})]}),d("div",{class:"flex flex-wrap gap-1 mb-1",children:GI.map(K=>d("button",{class:"btn btn-ghost btn-xs h-5 min-h-0 px-1 font-mono",onClick:()=>r(ze=>Ii(ze,K)),children:K},K))}),d("div",{class:"flex flex-wrap items-center gap-1 mb-1",children:[d("select",{class:"select select-bordered select-xs flex-1 min-w-44",value:_,onChange:K=>be(K.target.value),children:[d("option",{value:"",children:"saved searches"}),h.map(K=>d("option",{value:K.id,children:K.name},K.id))]}),d("input",{type:"text",class:"input input-bordered input-xs w-32",placeholder:"save name",value:m,onInput:K=>g(K.target.value)}),d("button",{class:"btn btn-ghost btn-xs",onClick:V,children:"Save"}),d("button",{class:"btn btn-ghost btn-xs",disabled:!_,onClick:ie,children:"Delete"})]}),d("div",{class:"grid grid-cols-2 gap-1 mb-1",children:[d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono",placeholder:"from user (alice)",value:C,onInput:K=>k(K.target.value)}),d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono",placeholder:"to user (bob)",value:T,onInput:K=>M(K.target.value)}),d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono col-span-2",placeholder:"bookmark folder id/name",value:P,onInput:K=>F(K.target.value)}),d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono",placeholder:"source contains (iphone)",value:I,onInput:K=>O(K.target.value)}),d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono",placeholder:"card name (summary_large_image)",value:B,onInput:K=>D(K.target.value)})]}),d("div",{class:"flex flex-wrap items-center gap-2 mb-1",children:[d("label",{class:"label cursor-pointer p-0 gap-1",children:[d("input",{type:"checkbox",class:"checkbox checkbox-xs",checked:v,onChange:K=>L(K.target.checked)}),d("span",{class:"label-text text-[10px]",children:"bookmarked"})]}),d("label",{class:"label cursor-pointer p-0 gap-1",children:[d("input",{type:"checkbox",class:"checkbox checkbox-xs",checked:$,onChange:K=>Me(K.target.checked)}),d("span",{class:"label-text text-[10px]",children:"liked"})]}),d("label",{class:"label cursor-pointer p-0 gap-1",children:[d("input",{type:"checkbox",class:"checkbox checkbox-xs",checked:Z,onChange:K=>re(K.target.checked)}),d("span",{class:"label-text text-[10px]",children:"media"})]}),d("label",{class:"label cursor-pointer p-0 gap-1",children:[d("input",{type:"checkbox",class:"checkbox checkbox-xs",checked:J,onChange:K=>le(K.target.checked)}),d("span",{class:"label-text text-[10px]",children:"replies"})]}),d("label",{class:"label cursor-pointer p-0 gap-1",children:[d("input",{type:"checkbox",class:"checkbox checkbox-xs",checked:he,onChange:K=>pe(K.target.checked)}),d("span",{class:"label-text text-[10px]",children:"exclude retweets"})]}),d("label",{class:"label cursor-pointer p-0 gap-1",children:[d("input",{type:"checkbox",class:"checkbox checkbox-xs",checked:ge,onChange:K=>z(K.target.checked)}),d("span",{class:"label-text text-[10px]",children:"verified"})]}),d("label",{class:"label cursor-pointer p-0 gap-1",children:[d("input",{type:"checkbox",class:"checkbox checkbox-xs",checked:ue,onChange:K=>Pe(K.target.checked)}),d("span",{class:"label-text text-[10px]",children:"blue verified"})]})]}),d("div",{class:"flex flex-wrap items-center gap-1 mb-1",children:[d("select",{class:"select select-bordered select-xs w-24",value:o,onChange:K=>a(K.target.value),children:[d("option",{value:"relevance",children:"relevance"}),d("option",{value:"newest",children:"newest"}),d("option",{value:"oldest",children:"oldest"})]}),d("select",{class:"select select-bordered select-xs w-20",value:String(i),onChange:K=>s(Number(K.target.value)),children:[d("option",{value:"25",children:"25"}),d("option",{value:"50",children:"50"}),d("option",{value:"100",children:"100"}),d("option",{value:"200",children:"200"})]}),d("button",{class:"btn btn-primary btn-xs",disabled:Rt,onClick:()=>void Oe(0),children:Rt?"Searching...":"Search"}),d("button",{class:"btn btn-ghost btn-xs",disabled:!Ce,onClick:Le,children:"Export Blob"}),d("button",{class:"btn btn-ghost btn-xs",disabled:Rt,onClick:E,children:"Prev"}),d("button",{class:"btn btn-ghost btn-xs",disabled:Rt||!R,onClick:x,children:"Next"})]}),d("details",{class:"mb-1",children:[d("summary",{class:"cursor-pointer text-[10px] opacity-70",children:"ranking overrides (blank = daemon defaults)"}),d("div",{class:"grid grid-cols-2 gap-1 mt-1",children:[d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono",placeholder:"bm25",value:ce,onInput:K=>Ee(K.target.value)}),d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono",placeholder:"lexical",value:Qe,onInput:K=>X(K.target.value)}),d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono",placeholder:"cover_density",value:ne,onInput:K=>j(K.target.value)}),d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono",placeholder:"recency",value:se,onInput:K=>_e(K.target.value)}),d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono",placeholder:"term_match",value:we,onInput:K=>Ye(K.target.value)}),d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono",placeholder:"phrase_match",value:We,onInput:K=>Se(K.target.value)}),d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono",placeholder:"cover_bigram",value:Tt,onInput:K=>jt(K.target.value)}),d("input",{type:"text",class:"input input-bordered input-xs w-full font-mono",placeholder:"cover_trigram",value:Wt,onInput:K=>Gt(K.target.value)})]})]}),d("div",{class:"text-[10px] opacity-70 mb-1",children:Ce?`rows ${Ce.count} / total ${Ce.total_matches} (offset ${Ce.offset}, sort ${Ce.sort})`:"No results yet."}),it?d("div",{class:"text-[10px] font-mono opacity-70 mb-1",children:["effective: ",it]}):null,(Ve=Ce==null?void 0:Ce.parsed)!=null&&Ve.lexical_expression?d("div",{class:"text-[10px] font-mono opacity-70 mb-1",children:["parse: ",Ce.parsed.lexical_expression,Ce.parsed.filter_boolean_semantics?` | filters=${Ce.parsed.filter_boolean_semantics}`:""]}):null,Ce!=null&&Ce.ranking?d("div",{class:"text-[10px] font-mono opacity-70 mb-1 leading-tight",children:["weights bm25=",Number(Ce.ranking.bm25||0).toFixed(2)," lexical=",Number(Ce.ranking.lexical||0).toFixed(2)," density=",Number(Ce.ranking.cover_density||0).toFixed(2)," recency=",Number(Ce.ranking.recency||0).toFixed(2),d("br",{}),"term=",Number(Ce.ranking.term_match||0).toFixed(2)," phrase=",Number(Ce.ranking.phrase_match||0).toFixed(2)," bigram=",Number(Ce.ranking.cover_bigram||0).toFixed(2)," trigram=",Number(Ce.ranking.cover_trigram||0).toFixed(2)]}):null,at?d("div",{class:"text-error mb-1",children:["search error: ",at]}):null,(pt=Ce==null?void 0:Ce.warning_objects)!=null&&pt.length?d("div",{class:"text-warning mb-1 space-y-0.5",children:Ce.warning_objects.map((K,ze)=>d("div",{children:["[",K.code||"search_warning","] ",K.message||"search warning",K.token?` (${K.token})`:""]},`warn-${ze}`))}):(St=Ce==null?void 0:Ce.warnings)!=null&&St.length?d("div",{class:"text-warning mb-1",children:["warnings: ",Ce.warnings.join(" | ")]}):null,(vt=Ce==null?void 0:Ce.rows)!=null&&vt.length?d("div",{class:"mb-1",children:[d("div",{class:"text-[10px] opacity-70 mb-0.5",children:"facets"}),d("div",{class:"flex flex-wrap gap-1 mb-0.5",children:U.authors.map(K=>d("button",{class:"btn btn-ghost btn-xs h-5 min-h-0 px-1 font-mono",onClick:()=>r(ze=>Ii(ze,`from:${K.value}`)),children:["@",K.value," (",K.count,")"]},`author-${K.value}`))}),d("div",{class:"flex flex-wrap gap-1 mb-0.5",children:U.routes.map(K=>d("button",{class:"btn btn-ghost btn-xs h-5 min-h-0 px-1 font-mono",onClick:()=>r(ze=>Ii(ze,`route:${K.value}`)),children:["route:",K.value," (",K.count,")"]},`route-${K.value}`))}),d("div",{class:"flex flex-wrap gap-1",children:U.folders.map(K=>d("button",{class:"btn btn-ghost btn-xs h-5 min-h-0 px-1 font-mono",onClick:()=>r(ze=>Ii(ze,`bookmark_folder:${K.value}`)),children:["folder:",K.value," (",K.count,")"]},`folder-${K.value}`))})]}):null,d("div",{class:"max-h-56 overflow-y-auto space-y-1",children:(Yt=Ce==null?void 0:Ce.rows)!=null&&Yt.length?Ce.rows.map(K=>d("div",{class:"bg-base-100 rounded px-1.5 py-1",children:[d("div",{class:"flex items-center justify-between gap-1",children:[d("div",{class:"font-mono text-[10px]",children:["@",K.author_screen_name||"unknown"," · ",K.entity_id," · ",K.route_type]}),d("button",{class:"btn btn-ghost btn-xs h-5 min-h-0 px-1",onClick:()=>ke(K.entity_id),children:"Open"})]}),d("div",{class:"text-[11px] whitespace-pre-line break-words",children:eE(K.text||"[no text available in snapshot]",tt)}),d("div",{class:"font-mono text-[10px] opacity-70 mt-0.5",children:["score=",Number(K.score||0).toFixed(3)," | fav=",Number(K.favorite_count||0)," ","rt=",Number(K.retweet_count||0)," rep=",Number(K.reply_count||0)," q=",Number(K.quote_count||0),K.bookmark_folder_id?` | folder=${K.bookmark_folder_id}`:"",K.source_text?` | src=${K.source_text}`:"",K.card_name?` | card=${K.card_name}`:"",K.author_verified?" | verified":"",K.author_blue_verified?" | blue":"",K.has_media?" | media":"",K.has_links?" | links":"",K.is_reply?" | reply":"",K.is_retweet?" | retweet":"",K.is_quote?" | quote":"",K.bookmarked?" | bookmarked":"",K.favorited?" | liked":""]}),d("div",{class:"flex flex-wrap gap-1 mt-0.5",children:tE(K).map(ze=>d("button",{class:"btn btn-ghost btn-xs h-5 min-h-0 px-1 font-mono",onClick:()=>r(Dt=>Ii(Dt,ze)),children:ze},`${K.entity_id}-${ze}`))})]},K.entity_id)):d("div",{class:"text-[10px] opacity-70",children:"Run a query to load rows."})})]})}function oE(){return d(Jn,{children:[d("div",{class:"divider mt-0 mb-1"}),d($I,{}),d(UI,{}),d(BI,{lines:gl})]})}function aE(){const{t:e}=Wn(),[t,n]=sr();return d(ls,{title:e("Local Search"),description:e("Search indexed tweets with Twitter-style operators"),active:true,onClick:n,indicatorColor:"bg-neutral",panelClass:"opacity-90",children:d(lr,{class:"max-w-4xl md:max-w-screen-md sm:max-w-screen-sm min-h-[560px]",title:e("Local Recorder Search"),show:t,onClose:n,children:d(rE,{})})})}class iE extends bn{constructor(){super(...arguments);je(this,"name","LocalSearchModule");je(this,"type",xt.CUSTOM);}render(){return aE}}const sE=Gn({moduleName:"Retweeters",match:e=>/\/graphql\/.+\/Retweeters/.test(e.url),parse:(e,t)=>_a(t,n=>n.data.retweeters_timeline.timeline.instructions,n=>Yr(n.content.itemContent)),project:(e,t)=>ds(e,t)});class lE extends bn{constructor(){super(...arguments);je(this,"name","RetweetersModule");je(this,"type",xt.USER);}intercept(){return sE}render(){return qn}}class cE extends bn{constructor(){super(...arguments);je(this,"name","RuntimeLogsModule");}render(){return oE}}const uE={home:"public",bookmarks:"sensitive",tweet_detail:"public",notifications:"sensitive",search_top:"public",search_latest:"public",search_people:"public",search_media:"public",list:"public",list_members:"public",list_subscribers:"public",community:"public",community_members:"public",followers:"sensitive",following:"sensitive",user_profile_tweets:"public",user_profile_replies:"public",user_profile_media:"public",user_profile_likes:"sensitive",messages:"dm",unknown:"public"},dE={route_policies:uE},km=dE;function fE(e){return String(e||"").trim()||"unknown"}function W_(e){var r,o;const t=fE(e),n=((r=km.route_policies)==null?void 0:r[t])||((o=km.route_policies)==null?void 0:o.unknown);return n==="dm"||n==="sensitive"||n==="public"?n:"public"}function hE(e,t){return W_(e)==="dm"?!!t.dmCaptureAllowed:true}const Gd="twe.raw.v1",xm="__twe_raw_events_v1",pE="twe:raw-event-v1",G_="__twe_raw_capture_stats_v1",dd="__twe_route_epoch_v1",Jl="__twe_raw_capture_session_id_v1",ba="__twe_raw_capture_tab_id_v1",mE=1,gE=48,yE=160,_E=4096,wE=32768,bE="twitter-web-exporter-raw-spool-v1",xr="events",Y_=5e3,vE=50,kE=2500,xE=8,_u="__twe_raw_spool_flush_timer_v1",SE="twe:raw-spool-state-v1",Sm="__twe_raw_spool_clear_v1",fd="__twe_raw_route_monitor_timer_v1",hd="__twe_raw_viewport_monitor_timer_v1",pd="__twe_raw_monitor_coord_timer_v1",Ol="__twe_raw_monitor_coordination_v1",X_="__twe_raw_monitor_metrics_v1",Fl="__twe_raw_monitor_storage_listener_v1",Ll="__twe_raw_monitor_beforeunload_v1",Cm="__twe_raw_monitor_tick_v1",CE="twe:raw-monitor-role-v1",TE=2500,ME=4e3,Z_=6e4,RE=40,Tm=48,Q_=5e3,IE=2e4,EE="twe_raw_capture_daemon_url_v1",AE="twe_raw_capture_stream_enabled_v1",DE="twe_raw_capture_enabled_v1",PE="twe_raw_capture_encryption_ready_v1",J_="twe_raw_capture_dm_session_armed_until_ms_v1",Mm=900*1e3,ec="twe_raw_monitor_leader_v1",OE=new Set(["s","t","cn","ref_src","ref_url","utm_source","utm_medium","utm_campaign","utm_term","utm_content"]),FE=/(token|auth|authorization|cookie|csrf|sig|signature|bearer|session|oauth)/i;let Rm=0,Im="",Ua=null,wu=false,Em=0,Po=0,Am="",Dm="",Ws="";const os=new Map;function vn(){return globalThis}function ol(e){const t=vn(),n=t[e];if(typeof n=="number"||typeof n=="object"){try{clearInterval(n);}catch{}delete t[e];}}function LE(){const t=vn()[X_],n=t&&typeof t=="object"?t:{},r={};for(const[o,a]of Object.entries(n))r[o]=dt(a,0);return r}function da(e,t=1){if(!e)return;const n=vn(),r=LE();r[e]=dt(r[e],0)+Math.max(1,dt(t,1)),n[X_]=r;}function dt(e,t=0){const n=Number(e);return Number.isFinite(n)?n:t}function md(e){let t=2166136261;for(let n=0;n<e.length;n+=1)t^=e.charCodeAt(n),t=Math.imul(t,16777619);return `fnv1a32:${(t>>>0).toString(16)}`}function tc(e){return Rm+=1,`${e}-${Date.now().toString(36)}-${Rm.toString(36)}-${Math.random().toString(36).slice(2,8)}`}function Nr(e,t){const n=vn(),r=n[e];if(typeof r=="string"&&r.length>0)return r;const o=tc(t);return n[e]=o,o}function Pm(e,t){try{const n=new URL(e,location.href),r=new URL(n.toString()),o=[...r.searchParams.keys()];for(const i of o){if(FE.test(i)){r.searchParams.delete(i);continue}t&&OE.has(i.toLowerCase())&&r.searchParams.delete(i);}const a=[...r.searchParams.entries()].sort(([i,s],[l,c])=>i===l?s.localeCompare(c):i.localeCompare(l));r.search="";for(const[i,s]of a)r.searchParams.append(i,s);return r.toString()}catch{return e}}function ew(e){try{const t=new URLSearchParams(e||""),n=(t.get("f")||t.get("src")||"").toLowerCase();if(n.includes("live")||n.includes("latest"))return "latest";if(n.includes("user")||n.includes("people"))return "people";if(n.includes("image")||n.includes("media"))return "media";if(n.includes("top"))return "top"}catch{}return "top"}function nc(e,t=""){if(/^\/home\/?$/.test(e))return "home";if(/^\/i\/bookmarks(\/|$)/.test(e))return "bookmarks";if(/\/status\/\d+/.test(e))return "tweet_detail";if(/^\/notifications(\/|$)/.test(e))return "notifications";if(/^\/search\/?$/.test(e)){const n=ew(t);return n==="latest"?"search_latest":n==="people"?"search_people":n==="media"?"search_media":"search_top"}return /^\/i\/lists\/\d+\/(members)(\/|$)/.test(e)?"list_members":/^\/i\/lists\/\d+\/(followers|subscribers)(\/|$)/.test(e)?"list_subscribers":/^\/i\/lists\//.test(e)?"list":/^\/i\/communities\/\d+\/(members)(\/|$)/.test(e)?"community_members":/^\/i\/communities\//.test(e)?"community":/^\/[A-Za-z0-9_]+\/(followers)(\/|$)/.test(e)?"followers":/^\/[A-Za-z0-9_]+\/(following)(\/|$)/.test(e)?"following":/^\/[A-Za-z0-9_]+\/(with_replies)(\/|$)/.test(e)?"user_profile_replies":/^\/[A-Za-z0-9_]+\/(media)(\/|$)/.test(e)?"user_profile_media":/^\/[A-Za-z0-9_]+\/(likes)(\/|$)/.test(e)?"user_profile_likes":/^\/messages(\/|$)/.test(e)?"messages":/^\/[A-Za-z0-9_]+\/?$/.test(e)?"user_profile_tweets":"unknown"}function Yd(e,t=""){const n={},r=new Set(["home","search","notifications","messages","explore","i"]),o=e.match(/\/status\/(\d+)/);o!=null&&o[1]&&(n.tweetId=o[1]);const a=e.match(/\/i\/bookmarks\/(\d+)/);a!=null&&a[1]&&(n.folderId=a[1]);const i=e.match(/\/i\/lists\/(\d+)/);i!=null&&i[1]&&(n.listId=i[1]);const s=e.match(/\/i\/communities\/(\d+)/);s!=null&&s[1]&&(n.communityId=s[1]);const l=e.match(/^\/([A-Za-z0-9_]+)\/(with_replies|media|likes|followers|following)(\/|$)/);l!=null&&l[1]&&(n.screenName=l[1]),l!=null&&l[2]&&(n.profileTab=l[2]);const c=e.match(/^\/([A-Za-z0-9_]+)\/?$/);return c!=null&&c[1]&&!r.has(String(c[1]).toLowerCase())&&(n.screenName=c[1]),/^\/search\/?$/.test(e)&&(n.searchMode=ew(t)),Object.keys(n).length?n:void 0}function NE(e){const t=e.trim();return t&&(t.startsWith("{")||t.startsWith("["))?"application/json":"text/plain"}function Xd(){const e=si(ec);if(!e)return null;try{const t=JSON.parse(e);if(!t||typeof t!="object")return null;const n=typeof t.tab_id=="string"?t.tab_id:"";if(!n)return null;const r=dt(t.heartbeat_ms,0),o=dt(t.acquired_ms,0);return {tab_id:n,session_id:typeof t.session_id=="string"?t.session_id:void 0,heartbeat_ms:r,acquired_ms:o}}catch{return null}}function Om(e){try{if(typeof localStorage>"u")return null;localStorage.setItem(ec,JSON.stringify(e));}catch{return null}return Xd()}function tw(e){if(e)try{if(typeof localStorage>"u")return;const t=Xd();if(!t||t.tab_id!==e)return;localStorage.removeItem(ec);}catch{}}function nw(e){const t=Bn();Sr({...t,...e});}function bu(e,t,n){const r=vn(),o={role:e,tab_id:Nr(ba,"tab"),leader_tab_id:t||void 0,lease_heartbeat_ms:n||0,updated_at_ms:Date.now()};r[Ol]=o,nw({monitor_role:e,monitor_leader_tab_id:t||void 0,monitor_last_heartbeat_ms:n||0});const a=`${o.role}|${o.tab_id}|${o.leader_tab_id||""}|${o.lease_heartbeat_ms||0}`;if(a!==Dm&&(Dm=a,typeof window<"u"&&typeof window.dispatchEvent=="function"))try{window.dispatchEvent(new CustomEvent(CE,{detail:o}));}catch{}}function al(e=false){const t=Nr(ba,"tab"),n=Nr(Jl,"session"),r=Date.now();let o=Xd();if(!o){const c=Om({tab_id:t,session_id:n,heartbeat_ms:r,acquired_ms:r});if(!c){bu("single",t,r);return}o=c;}const a=dt(o.heartbeat_ms,0)<=0||r-dt(o.heartbeat_ms,0)>IE,i=o.tab_id===t;if((a||i)&&(e||!i||r-dt(o.heartbeat_ms,0)>=Math.floor(Q_/2))){const c={tab_id:t,session_id:n,acquired_ms:i?dt(o.acquired_ms,r):r,heartbeat_ms:r},h=Om(c);if((h==null?void 0:h.tab_id)===t){bu("leader",t,dt(h.heartbeat_ms,r));return}o=h||o;}const s=typeof o.tab_id=="string"?o.tab_id:"";bu("follower",s,dt(o.heartbeat_ms,0));}function rw(){const e=vn(),t=e.__twe_raw_monitor_force_leader_v1;if(typeof t=="boolean")return t;const n=e[Ol],r=n&&typeof n=="object"?n:void 0;if(!r||typeof r.role!="string"){al(true);const o=e[Ol],a=o&&typeof o=="object"?o:void 0;return (a==null?void 0:a.role)==="leader"||(a==null?void 0:a.role)==="single"}return r.role==="leader"||r.role==="single"}function Zd(){const e=vn(),t=Bn(),n=e.__twe_runtime_modes_v1,r=e.__twe_runtime_v1,o=n&&typeof n=="object"?n:void 0,a=r&&typeof r=="object"?r:void 0,i=dt(a==null?void 0:a.revision,0)||dt(a==null?void 0:a.rev,0)||void 0,s=a==null?void 0:a.capabilities,l=s&&typeof s=="object"?s:void 0;return {recorder_rev:mE,hook_rev:i,modes:{safeMode:!!(o!=null&&o.safeMode),hookMode:typeof(o==null?void 0:o.hookMode)=="string"?o.hookMode:void 0,repairMode:typeof(o==null?void 0:o.repairMode)=="string"?o.repairMode:void 0},capabilities:{hasExportFunction:!!(l!=null&&l.hasExportFunction),hasWrappedJSObject:!!(l!=null&&l.hasWrappedJSObject)},spool:{queued:dt(t.spool_count,0),enqueued_total:dt(t.spool_enqueued,0),flushed_total:dt(t.spool_flushed,0),failed_total:dt(t.spool_failed,0),oldest_pending_age_ms:dt(t.oldest_pending_age_ms,0)},coordination:{role:t.monitor_role==="leader"||t.monitor_role==="follower"||t.monitor_role==="single"?t.monitor_role:void 0,leader_tab_id:typeof t.monitor_leader_tab_id=="string"?t.monitor_leader_tab_id:void 0,lease_heartbeat_ms:dt(t.monitor_last_heartbeat_ms,0)||void 0}}}function ow(){const e=vn(),t=dt(e[dd],0)+1;return e[dd]=t,t}function Qd(e,t,n){const r=Im||void 0,o=md(`${r||""}|${e}|${t}|${n}`);return Im=o,{prevHash:r,eventHash:o}}function Jd(){const e=vn().__META_DATA__,t=e&&typeof e=="object"?e:void 0,n=typeof(t==null?void 0:t.userId)=="string"?t.userId:void 0;return n?{user_rest_id:n}:void 0}function BE(e,t){const n=Date.now(),r=typeof performance<"u"?Number(performance.now()):0,o=typeof location<"u"?location.href:"",a=typeof location<"u"?location.pathname:"",i=typeof location<"u"?location.search:"",s=typeof e.body=="string"&&e.body?md(e.body):void 0,l=typeof t.responseText=="string"?t.responseText:"",c=md(l),h=UE(),f=l.length>h,m=f?l.slice(0,h):l,g=e.requestId&&e.requestId.length>0?e.requestId:tc("evt"),{prevHash:_,eventHash:b}=Qd(g,n,`${e.method}|${e.url}|${t.status}|${c}`);return {schema:Gd,event_id:g,prev_event_hash:_,event_hash:b,wall_time_ms:n,mono_time_ms:r,tz_offset_min:new Date().getTimezoneOffset(),page_url:o,route_type:nc(a,i),route_params:Yd(a,i),route_epoch:ow(),kind:"net",session_id:Nr(Jl,"session"),tab_id:Nr(ba,"tab"),account_hint:Jd(),net:{transport:e.method.toUpperCase()==="GET"?"xhr":"fetch",phase:"response",method:e.method.toUpperCase(),url_raw_redacted:Pm(e.url,false),url_norm:Pm(e.url,true),status:t.status,req_body_hash:s,resp_content_type:NE(l),resp_body_ref:`sha:${c}`,resp_body_hash:c,resp_body_size:l.length,resp_truncated:f,resp_body_sample:m},recorder:Zd()}}function UE(){return kr()||va()?wE:_E}function $E(){return kr()||va()?yE:gE}function Fm(e){const t=Date.now(),n=typeof performance<"u"?Number(performance.now()):0,r=typeof location<"u"?location.href:"",o=typeof location<"u"?location.pathname:"",a=typeof location<"u"?location.search:"",i=typeof location<"u"?location.hash:"",s=tc("route"),{prevHash:l,eventHash:c}=Qd(s,t,`route|${e}|${r}|${o}|${a}|${i}`);return {schema:Gd,event_id:s,prev_event_hash:l,event_hash:c,wall_time_ms:t,mono_time_ms:n,tz_offset_min:new Date().getTimezoneOffset(),page_url:r,route_type:nc(o,a),route_params:Yd(o,a),route_epoch:ow(),kind:"route",session_id:Nr(Jl,"session"),tab_id:Nr(ba,"tab"),account_hint:Jd(),route:{source:e,pathname:o,search:a,hash:i},recorder:Zd()}}function HE(e,t="dom-scan"){const n=Date.now(),r=typeof performance<"u"?Number(performance.now()):0,o=typeof location<"u"?location.href:"",a=typeof location<"u"?location.pathname:"",i=typeof location<"u"?location.search:"",s=tc("vp"),{prevHash:l,eventHash:c}=Qd(s,n,`viewport|${t}|${e}|${o}|${a}`);return {schema:Gd,event_id:s,prev_event_hash:l,event_hash:c,wall_time_ms:n,mono_time_ms:r,tz_offset_min:new Date().getTimezoneOffset(),page_url:o,route_type:nc(a,i),route_params:Yd(a,i),route_epoch:dt(vn()[dd],0),kind:"viewport",session_id:Nr(Jl,"session"),tab_id:Nr(ba,"tab"),account_hint:Jd(),viewport:{tweet_id:e,source:t},recorder:Zd()}}function Bn(){const t=vn()[G_];if(!t||typeof t!="object")return {total:0,emitted:0,dropped:0,last_at:0,spool_count:0,spool_enqueued:0,spool_flushed:0,spool_failed:0,spool_drop_overflow:0,spool_unavailable:0,oldest_pending_age_ms:0,daemon_online:false,monitor_role:"single",monitor_leader_tab_id:void 0,monitor_last_heartbeat_ms:0,monitor_ticks_route:0,monitor_ticks_viewport:0,monitor_suppressed_route:0,monitor_suppressed_viewport:0};const n=t;return {total:dt(n.total,0),emitted:dt(n.emitted,0),dropped:dt(n.dropped,0),last_at:dt(n.last_at,0),last_event_id:typeof n.last_event_id=="string"?n.last_event_id:void 0,last_event_hash:typeof n.last_event_hash=="string"?n.last_event_hash:void 0,spool_count:dt(n.spool_count,0),spool_enqueued:dt(n.spool_enqueued,0),spool_flushed:dt(n.spool_flushed,0),spool_failed:dt(n.spool_failed,0),spool_drop_overflow:dt(n.spool_drop_overflow,0),spool_unavailable:dt(n.spool_unavailable,0),oldest_pending_age_ms:dt(n.oldest_pending_age_ms,0),daemon_online:!!n.daemon_online,daemon_last_flush_at:dt(n.daemon_last_flush_at,0)||void 0,daemon_last_error:typeof n.daemon_last_error=="string"?n.daemon_last_error:void 0,monitor_role:n.monitor_role==="leader"||n.monitor_role==="follower"||n.monitor_role==="single"?n.monitor_role:void 0,monitor_leader_tab_id:typeof n.monitor_leader_tab_id=="string"?n.monitor_leader_tab_id:void 0,monitor_last_heartbeat_ms:dt(n.monitor_last_heartbeat_ms,0),monitor_ticks_route:dt(n.monitor_ticks_route,0),monitor_ticks_viewport:dt(n.monitor_ticks_viewport,0),monitor_suppressed_route:dt(n.monitor_suppressed_route,0),monitor_suppressed_viewport:dt(n.monitor_suppressed_viewport,0)}}function Sr(e){const t=vn();t[G_]=e;const n=[dt(e.spool_count,0),dt(e.spool_enqueued,0),dt(e.spool_flushed,0),dt(e.spool_failed,0),dt(e.spool_drop_overflow,0),dt(e.spool_unavailable,0),dt(e.oldest_pending_age_ms,0),e.daemon_online?1:0].join("|");if(n!==Am&&(Am=n,typeof window<"u"&&typeof window.dispatchEvent=="function"))try{window.dispatchEvent(new CustomEvent(SE,{detail:{stats:e}}));}catch{}}function fr(e){const t=Bn();Sr({...t,...e});}function aw(e){const t=vn(),n=t[xm],r=Array.isArray(n)?n:[];r.push(e);let o=0;const a=$E();r.length>a&&(o=r.length-a),o>0&&r.splice(0,o),t[xm]=r;const i=Bn();if(Sr({...i,total:i.total+1,emitted:i.emitted+1,dropped:i.dropped+o,last_at:Date.now(),last_event_id:e.event_id,last_event_hash:e.event_hash}),typeof window<"u"&&typeof window.dispatchEvent=="function")try{window.dispatchEvent(new CustomEvent(pE,{detail:e}));}catch{}}function gd(e){aw(e),va()&&(cw(e),nf());}function ef(){return !tf()||typeof document<"u"&&document.visibilityState==="hidden"?false:va()||kr()||iw()}function vu(){if(!ef()||typeof document<"u"&&document.visibilityState==="hidden")return;if(!rw()){da("route_suppressed_checks",1);const n=Bn();Sr({...n,monitor_suppressed_route:dt(n.monitor_suppressed_route,0)+1});return}const e=Bn();Sr({...e,monitor_ticks_route:dt(e.monitor_ticks_route,0)+1}),da("route_leader_checks",1);const t=typeof location<"u"?location.href:"";if(t){if(!Ws){Ws=t,gd(Fm("bootstrap")),da("route_emits",1);return}t!==Ws&&(Ws=t,gd(Fm("poll")),da("route_emits",1));}}function jE(e){const t=e.match(/\/status\/(\d+)/);return t!=null&&t[1]?t[1]:null}function qE(e){if(!(e instanceof Element))return  false;const t=e.getBoundingClientRect();return !(t.width<=0||t.height<=0||t.bottom<Tm||t.top>window.innerHeight-Tm)}function VE(e=RE){if(typeof document>"u")return [];const t=[],n=new Set,r=document.querySelectorAll('article a[href*="/status/"]');for(const o of r){if(t.length>=e)break;if(!(o instanceof HTMLAnchorElement)||!qE(o))continue;const a=jE(o.getAttribute("href")||"");!a||n.has(a)||(n.add(a),t.push(a));}return t}function zE(e){for(const[t,n]of os.entries())e-n>Z_&&os.delete(t);}function Lm(){if(!ef()||typeof document<"u"&&document.visibilityState==="hidden")return;if(!rw()){da("viewport_suppressed_checks",1);const r=Bn();Sr({...r,monitor_suppressed_viewport:dt(r.monitor_suppressed_viewport,0)+1});return}const e=Bn();Sr({...e,monitor_ticks_viewport:dt(e.monitor_ticks_viewport,0)+1}),da("viewport_leader_checks",1);const t=Date.now();zE(t);const n=VE();for(const r of n){const o=dt(os.get(r),0);o>0&&t-o<Z_||(os.set(r,t),gd(HE(r)),da("viewport_emits",1));}}function tf(){const t=vn().__twe_raw_capture_enabled_v1;if(typeof t=="boolean")return t;const n=ut.get("rawCaptureEnabled",true);if(typeof n=="boolean")return n;const r=si(DE);return r?r!=="0"&&r!=="false":true}function iw(){return vn().__twe_raw_capture_dev_utils_v1===true?true:!!ut.get("debug",false)}function KE(e){const t=e.toLowerCase();return t==="localhost"||t==="127.0.0.1"||t==="::1"?true:t.endsWith(".localhost")}function WE(e){if(!e)return  false;try{const t=new URL(e,location.href),n=new URL(lw(),location.href);return t.origin===n.origin&&/^\/(?:ingest|health|stats|query)(\/|$)/.test(t.pathname)?!0:KE(t.hostname)&&/^\/(?:ingest|health|stats|query)(\/|$)/.test(t.pathname)}catch{return  false}}function Nm(){return ut.get("directMessagesCaptureEnabled",false)===true&&GE()&&YE()}function GE(){if(vn().__twe_raw_capture_encryption_ready_v1===true||ut.get("rawCaptureEncryptedStorageReady",false)===true)return  true;const n=si(PE);if(!n)return  false;const r=n.trim().toLowerCase();return r==="1"||r==="true"||r==="yes"||r==="on"}function YE(){const e=vn(),t=dt(e.__twe_raw_capture_dm_session_armed_until_ms_v1,0),n=Date.now();if(t>n)return  true;const r=si(J_);return dt(r,0)>n}function Bm(e){const t=vn();t.__twe_raw_capture_dm_session_armed_until_ms_v1=e;try{localStorage.setItem(J_,String(e));}catch{}}function XE(e){return e==="sensitive"?ut.get("rawCapturePolicySensitiveEnabled",true)!==false:e==="dm"?ut.get("rawCapturePolicyDmEnabled",true)!==false:ut.get("rawCapturePolicyPublicEnabled",true)!==false}function ZE(){let e="unknown";if(Nm())return {blocked:false,routeType:e,policyClass:"dm"};try{e=nc(location.pathname||"/",location.search||"");const t=W_(e);return XE(t)?{blocked:!hE(e,{dmCaptureAllowed:Nm()}),routeType:e,policyClass:t}:{blocked:!0,routeType:e,policyClass:t}}catch{return {blocked:false,routeType:"unknown",policyClass:"public"}}}function QE(e,t){if(!e.url||!tf()||WE(e.url))return  false;const n=ZE();if(n.blocked){const i=Bn();return fr({dm_policy_blocks:dt(i.dm_policy_blocks,0)+1,dm_policy_last_route_type:n.routeType,dm_policy_last_policy_class:n.policyClass}),false}return !(!/\/graphql\/|\/api\/1\.1\//.test(e.url)||!String(t.responseText||""))}function zo(){return Date.now()<Po?Promise.reject(new Error("raw spool unavailable")):typeof indexedDB>"u"?(Po=Date.now()+6e4,fr({spool_unavailable:dt(Bn().spool_unavailable,0)+1,daemon_last_error:"raw-spool-indexeddb-unavailable"}),Promise.reject(new Error("indexeddb unavailable"))):Ua||(Ua=new Promise((e,t)=>{let n;try{n=indexedDB.open(bE,1);}catch(r){Ua=null,Po=Date.now()+6e4,fr({spool_unavailable:dt(Bn().spool_unavailable,0)+1,daemon_last_error:`raw-spool-open-failed:${ya(r)}`}),t(r);return}n.onupgradeneeded=()=>{const r=n.result;if(!r.objectStoreNames.contains(xr)){const o=r.createObjectStore(xr,{keyPath:"event_id"});o.createIndex("created_at","created_at",{unique:false}),o.createIndex("next_retry_at","next_retry_at",{unique:false}),o.createIndex("wall_time_ms","wall_time_ms",{unique:false});}},n.onsuccess=()=>{Po=0,e(n.result);},n.onerror=()=>{Ua=null,Po=Date.now()+6e4,fr({spool_unavailable:dt(Bn().spool_unavailable,0)+1,daemon_last_error:`raw-spool-open-error:${ya(n.error??new Error("failed to open raw spool db"))}`}),t(n.error??new Error("failed to open raw spool db"));};}),Ua)}function rc(e,t,n,r){return new Promise((o,a)=>{const i=e.transaction([xr],t),s=i.objectStore(xr);i.oncomplete=()=>{try{o(r());}catch(l){a(l);}},i.onerror=()=>a(i.error??new Error("raw spool transaction failed")),i.onabort=()=>a(i.error??new Error("raw spool transaction aborted")),n(s);})}async function JE(e){const t=await zo();await rc(t,"readwrite",n=>{n.put(e);},()=>{});}async function oc(){const e=await zo();return await new Promise(t=>{const o=e.transaction([xr],"readonly").objectStore(xr).count();o.onsuccess=()=>t(dt(o.result,0)),o.onerror=()=>t(0);})}async function eA(){const e=await zo();return await new Promise(t=>{const a=e.transaction([xr],"readonly").objectStore(xr).index("created_at").openCursor();a.onsuccess=()=>{const i=a.result;if(!i){t(0);return}const s=i.value;t(dt(s.created_at,0));},a.onerror=()=>t(0);})}async function sw(e){const t=await zo(),n=await oc();if(n<=e)return 0;const r=n-e;return await new Promise((o,a)=>{const i=t.transaction([xr],"readwrite"),s=i.objectStore(xr),l=s.index("created_at"),c=[],h=l.openCursor();h.onsuccess=()=>{const f=h.result;if(!f||c.length>=r){for(const m of c)s.delete(m);return}c.push(f.primaryKey),f.continue();},h.onerror=()=>a(h.error??new Error("cursor read failed")),i.oncomplete=()=>o(c.length),i.onerror=()=>a(i.error??new Error("prune tx failed")),i.onabort=()=>a(i.error??new Error("prune tx aborted"));})}async function tA(e,t){const n=await zo();return await new Promise((r,o)=>{const a=n.transaction([xr],"readonly"),s=a.objectStore(xr).index("created_at"),l=[],c=s.openCursor();c.onsuccess=()=>{const h=c.result;if(!h||l.length>=t){r(l);return}const f=h.value;dt(f.next_retry_at,0)<=e&&l.push(f),h.continue();},c.onerror=()=>o(c.error??new Error("list batch failed")),a.onerror=()=>o(a.error??new Error("list batch tx failed"));})}async function nA(e){if(!e.length)return;const t=await zo();await rc(t,"readwrite",n=>{for(const r of e)n.delete(r);},()=>{});}async function Um(e){if(!e.length)return;const t=await zo();await rc(t,"readwrite",n=>{for(const r of e)n.put(r);},()=>{});}async function rA(){const e=await zo();return await rc(e,"readwrite",t=>{t.clear();},()=>{}),await oc()}async function Wa(e=0){try{const t=await oc(),n=await eA(),r=n?Math.max(0,Date.now()-n):0,o=Bn();Sr({...o,spool_count:t,oldest_pending_age_ms:r,dropped:o.dropped+Math.max(0,e),spool_drop_overflow:dt(o.spool_drop_overflow,0)+Math.max(0,e)});}catch{}}async function oA(){if(Date.now()<Po){fr({spool_count:0,oldest_pending_age_ms:0});return}try{const e=await sw(Y_);await Wa(e);}catch{}}function $m(e){const t=Math.max(0,Math.min(6,e));return Math.min(6e4,1e3*2**t)}function si(e){try{return typeof localStorage>"u"?null:localStorage.getItem(e)}catch{return null}}function va(){const t=vn().__twe_raw_capture_stream_enabled_v1;if(typeof t=="boolean")return t;const n=ut.get("rawCaptureStreamEnabled",false);if(typeof n=="boolean")return n;const r=si(AE);return r?r==="1"||r==="true":false}function lw(){const t=vn().__twe_raw_capture_daemon_url_v1,n=ut.get("rawCaptureDaemonUrl","http://127.0.0.1:8754");return (typeof t=="string"&&t.trim().length>0?t.trim():typeof n=="string"&&n.trim().length>0?n.trim():si(EE)||"http://127.0.0.1:8754").replace(/\/+$/,"")}async function cw(e){if(Date.now()<Po){fr({spool_unavailable:dt(Bn().spool_unavailable,0)+1});return}try{const t=Date.now(),n={event_id:e.event_id,wall_time_ms:e.wall_time_ms,created_at:t,attempts:0,next_retry_at:t,payload:e};await JE(n);const r=await sw(Y_),o=Bn();Sr({...o,spool_enqueued:dt(o.spool_enqueued,0)+1,dropped:o.dropped+Math.max(0,r),spool_drop_overflow:dt(o.spool_drop_overflow,0)+Math.max(0,r)}),await Wa();}catch(t){fr({spool_unavailable:dt(Bn().spool_unavailable,0)+1,daemon_last_error:`spool-enqueue-error:${ya(t)}`});}}function aA(){const e=vn();ol(pd),ol(fd),ol(hd),os.clear();const t=e[Fl];if(typeof t=="function"&&typeof window<"u")try{window.removeEventListener("storage",t);}catch{}delete e[Fl];const n=e[Ll];if(typeof n=="function"&&typeof window<"u")try{window.removeEventListener("beforeunload",n);}catch{}delete e[Ll];try{const r=Nr(ba,"tab");tw(r);}catch{}delete e[Ol],nw({monitor_role:void 0,monitor_leader_tab_id:void 0,monitor_last_heartbeat_ms:0});}function iA(){if(va()){const e=vn(),t=e[_u];if(!(typeof t=="number"||typeof t=="object")){const n=setInterval(()=>{Em+=1,Em%xE===0&&oA(),nf();},kE);e[_u]=n;}return}ol(_u);}function sA(){const e=vn();if(iw()&&typeof e[Sm]!="function"&&(e[Sm]=async()=>{try{const t=await rA(),n=Bn();return Sr({...n,spool_count:t,oldest_pending_age_ms:0}),{ok:!0,remaining:t}}catch(t){const n=ya(t);return fr({daemon_last_error:`spool-clear-error:${n}`}),{ok:false,error:n}}}),typeof e[Cm]!="function"&&(e[Cm]=(t="both")=>{try{return (t==="both"||t==="route")&&vu(),(t==="both"||t==="viewport")&&Lm(),{ok:!0}}catch(n){return {ok:false,error:ya(n)}}}),typeof e.__twe_arm_dm_capture_v1!="function"&&(e.__twe_arm_dm_capture_v1=(t=Mm)=>{const r=Date.now()+Math.max(3e4,dt(t,Mm));return Bm(r),{ok:true,armed_until_ms:r}}),typeof e.__twe_disarm_dm_capture_v1!="function"&&(e.__twe_disarm_dm_capture_v1=()=>(Bm(0),{ok:true,armed_until_ms:0})),ef()){if(al(true),typeof e[Fl]!="function"){const o=a=>{if(a.key===ec)try{al(!0);}catch{}};if(e[Fl]=o,typeof window<"u"&&typeof window.addEventListener=="function")try{window.addEventListener("storage",o);}catch{}}if(typeof e[Ll]!="function"){const o=()=>{try{const a=Nr(ba,"tab");tw(a);}catch{}};if(e[Ll]=o,typeof window<"u"&&typeof window.addEventListener=="function")try{window.addEventListener("beforeunload",o);}catch{}}const t=e[pd];if(!(typeof t=="number"||typeof t=="object")){const o=setInterval(()=>{if(!(typeof document<"u"&&document.visibilityState==="hidden"))try{al(!0);}catch{}},Q_);e[pd]=o;}const n=e[fd];if(!(typeof n=="number"||typeof n=="object")){const o=setInterval(()=>{try{vu();}catch{}},TE);e[fd]=o;try{vu();}catch{}}const r=e[hd];if(!(typeof r=="number"||typeof r=="object")){const o=setInterval(()=>{try{Lm();}catch{}},ME);e[hd]=o;}}else aA();iA();}function ya(e){return e instanceof Error?`${e.name}: ${e.message}`:String(e)}async function lA(e){const t=lw(),n=await fetch(`${t}/ingest/events`,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({events:e.map(a=>a.payload)})});if(!n.ok)throw new Error(`daemon-response-${n.status}`);let r=null;try{r=await n.json();}catch{return e.map(a=>a.event_id)}const o=r&&typeof r=="object"&&Array.isArray(r.accepted_ids)?r.accepted_ids.map(a=>typeof a=="string"?a:"").filter(a=>!!a):null;return !o||!o.length?e.map(a=>a.event_id):o}async function nf(){if(!wu){wu=true;try{if(Date.now()<Po){fr({spool_count:0,oldest_pending_age_ms:0,daemon_online:!1});return}const e=await oc();if(await Wa(),!va()){fr({daemon_online:!1});return}if(e<=0){fr({daemon_online:!0,daemon_last_flush_at:Date.now(),oldest_pending_age_ms:0});return}const t=Date.now(),n=await tA(t,vE);if(!n.length){fr({daemon_online:!0}),await Wa();return}try{const r=await lA(n),o=new Set(r),a=n.filter(s=>!o.has(s.event_id));if(r.length&&await nA(r),a.length){const s=Date.now(),l=a.map(c=>{const h=dt(c.attempts,0)+1;return {...c,attempts:h,next_retry_at:s+$m(h)}});await Um(l);}const i=Bn();Sr({...i,spool_flushed:dt(i.spool_flushed,0)+r.length,daemon_online:!0,daemon_last_flush_at:Date.now(),daemon_last_error:void 0}),await Wa();}catch(r){const o=Date.now(),a=n.map(s=>{const l=dt(s.attempts,0)+1;return {...s,attempts:l,next_retry_at:o+$m(l)}});await Um(a);const i=Bn();Sr({...i,spool_failed:dt(i.spool_failed,0)+n.length,daemon_online:!1,daemon_last_error:ya(r)}),await Wa();}}catch(e){fr({daemon_last_error:`flush-error:${ya(e)}`});}finally{wu=false;}}}const cA=(e,t)=>{try{if(!tf())return;const n={method:typeof e.method=="string"&&e.method?e.method:"GET",url:typeof e.url=="string"?e.url:"",body:typeof e.body=="string"?e.body:void 0,requestId:typeof e.requestId=="string"?e.requestId:void 0},r={status:Number(t.status??0),responseText:String(t.responseText||"")};if(!QE(n,r))return;sA();const o=BE(n,r);aw(o),va()&&(cw(o),nf());}catch{}};class uA extends bn{constructor(){super(...arguments);je(this,"name","RawCaptureModule");je(this,"type",xt.CUSTOM);}intercept(){return cA}}function dA(e){try{const n=new URL(e.url).searchParams.get("variables");if(!n)return null;const r=JSON.parse(n);return r&&typeof r=="object"?r:null}catch{return null}}function uw(e){const t=dA(e),n=String((t==null?void 0:t.rawQuery)||"").trim().toLowerCase(),r=String((t==null?void 0:t.querySource)||"").trim().toLowerCase();return n.startsWith("quoted_tweet_id:")||r==="tdqt"}function dw(e){const n=JSON.parse(e.responseText).data.search_by_raw_query.search_timeline.timeline.instructions,r=[],o=[],a=[],i=n.find(c=>c.type==="TimelineAddEntries"),s=n.find(c=>c.type==="TimelineAddToModule"),l=(i==null?void 0:i.entries)??[];for(const c of l){if(Td(c)){const h=jn(c.content.itemContent);h&&r.push(h);}if(ux(c)){const h=c.content.items.map(f=>jn(f.item.itemContent)).filter(f=>!!f);r.push(...h);}if(Md(c)){const h=Yr(c.content.itemContent);h&&o.push(h);}if(dx(c)){const h=c.content.items.map(f=>f.item.itemContent.list);a.push(...h);}}if(s){const c=s.moduleItems.map(m=>m.item.itemContent),h=c.filter(m=>m.__typename==="TimelineTweet").map(m=>jn(m)).filter(m=>!!m);r.push(...h);const f=c.filter(m=>m.__typename==="TimelineTwitterList").map(m=>m.list);a.push(...f);}return {tweets:r,users:o,lists:a}}const fA=Gn({moduleName:"SearchTimeline",match:e=>/\/graphql\/.+\/SearchTimeline/.test(e.url)&&!uw(e),parse:(e,t)=>dw(t),count:e=>e.tweets.length,project:(e,t)=>Zr(e,t.tweets),onSuccess:e=>{e.lists.length>0&&Ie.warn(`SearchList: ${e.lists.length} lists received but ignored (Reason: not implemented)`,e.lists),e.users.length>0&&Ie.warn(`SearchUser: ${e.users.length} users received but ignored (Reason: not implemented)`,e.users);}}),hA=Gn({moduleName:"Quotes",match:e=>/\/graphql\/.+\/SearchTimeline/.test(e.url)&&uw(e),parse:(e,t)=>({tweets:dw(t).tweets}),count:e=>e.tweets.length,project:(e,t)=>Zr(e,t.tweets),onSuccess:e=>{Ie.debug(`Quotes: projected ${e.tweets.length} quote-tweet rows`);}});class pA extends bn{constructor(){super(...arguments);je(this,"name","QuotesModule");je(this,"type",xt.TWEET);}intercept(){return hA}render(){return qn}}class mA extends bn{constructor(){super(...arguments);je(this,"name","SearchTimelineModule");je(this,"type",xt.TWEET);}intercept(){return fA}render(){return qn}}const gA="TweetIndexModule";class yA extends bn{constructor(){super(...arguments);je(this,"name",gA);je(this,"type",xt.TWEET);}setup(){Ge.extBackfillTweetCapturesFromAllTweets(this.name);}render(){return qn}}const _A=Gn({moduleName:"TweetDetail",match:e=>/\/graphql\/.+\/TweetDetail/.test(e.url)||/\/graphql\/.+\/ModeratedTimeline/.test(e.url),parse:(e,t)=>{const n=/\/graphql\/.+\/TweetDetail/.test(e.url),r=/\/graphql\/.+\/ModeratedTimeline/.test(e.url),o=JSON.parse(t.responseText);let a=[];n?a=o.data.threaded_conversation_with_injections_v2.instructions:r&&(a=o.data.tweet.result.timeline_response.timeline.instructions);const i=[],s=a.find(h=>h.type==="TimelineAddEntries"),l=(s==null?void 0:s.entries)??[];for(const h of l){if(Td(h)){const f=jn(h.content.itemContent);f&&i.push(f);}if(n&&sx(h)){const f=h.content.items.map(m=>{if(m.entryId.includes("-tweet-"))return jn(m.item.itemContent)});i.push(...f.filter(m=>!!m));}}const c=a.find(h=>h.type==="TimelineAddToModule");if(c){const h=c.moduleItems.map(f=>jn(f.item.itemContent)).filter(f=>!!f);i.push(...h);}return i},project:(e,t)=>Zr(e,t)});class wA extends bn{constructor(){super(...arguments);je(this,"name","TweetDetailModule");je(this,"type",xt.TWEET);}intercept(){return _A}render(){return qn}}const bA=Gn({moduleName:"UserDetail",match:e=>/\/graphql\/.+\/UserByScreenName/.test(e.url),parse:(e,t)=>[JSON.parse(t.responseText).data.user.result],project:(e,t)=>ds(e,t)});class vA extends bn{constructor(){super(...arguments);je(this,"name","UserDetailModule");je(this,"type",xt.USER);}intercept(){return bA}render(){return qn}}const kA=Gn({moduleName:"UserMedia",match:e=>/\/graphql\/.+\/UserMedia/.test(e.url),parse:(e,t)=>{const r=JSON.parse(t.responseText).data.user.result.timeline.timeline.instructions,o=[],a=r.find(l=>l.type==="TimelineAddEntries"),i=(a==null?void 0:a.entries)??[];for(const l of i)if(cx(l)){const c=l.content.items.map(h=>jn(h.item.itemContent)).filter(h=>!!h);o.push(...c);}const s=r.find(l=>l.type==="TimelineAddToModule");if(s){const l=s.moduleItems.map(c=>jn(c.item.itemContent)).filter(c=>!!c);o.push(...l);}return o},project:(e,t)=>Zr(e,t)});class xA extends bn{constructor(){super(...arguments);je(this,"name","UserMediaModule");je(this,"type",xt.TWEET);}intercept(){return kA}render(){return qn}}const SA=Gn({moduleName:"UserTweets",match:e=>/\/graphql\/.+\/UserTweets/.test(e.url),parse:(e,t)=>{const r=JSON.parse(t.responseText).data.user.result.timeline.timeline.instructions,o=[],a=r.find(l=>l.type==="TimelinePinEntry");if(a){const l=jn(a.entry.content.itemContent);l&&o.push(l);}const i=r.find(l=>l.type==="TimelineAddEntries"),s=(i==null?void 0:i.entries)??[];for(const l of s){if(Td(l)){const c=jn(l.content.itemContent);c&&o.push(c);}if(lx(l)){const c=l.content.items.map(h=>jn(h.item.itemContent)).filter(h=>!!h);o.push(...c);}}return o},project:(e,t)=>Zr(e,t)});class CA extends bn{constructor(){super(...arguments);je(this,"name","UserTweetsModule");je(this,"type",xt.TWEET);}intercept(){return SA}render(){return qn}}const Hm="twe-root",ku="__twe_root_mounted_v1",xu=globalThis;function $a(e){const t=String(e??"");return t.includes("Twitter Web Exporter")||t.includes("Twitter%20Web%20Exporter")||t.includes("Scrollmark")||t.includes("twitter-web-exporter")||t.includes("moz-extension://")}function TA(){try{window.addEventListener("error",e=>{var t;try{if(!($a(e.filename)||$a(e.message)||$a((t=e.error)==null?void 0:t.stack)))return;console.error("[twitter-web-exporter] suppressed global error",e.error||e.message),e.preventDefault(),e.stopImmediatePropagation();}catch{}},!0);}catch{}try{window.addEventListener("unhandledrejection",e=>{try{const t=e.reason;if(!($a(t==null?void 0:t.stack)||$a(t==null?void 0:t.message)||$a(t)))return;console.error("[twitter-web-exporter] suppressed rejection",t),e.preventDefault(),e.stopImmediatePropagation();}catch{}},!0);}catch{}}function _n(e,t){try{e.add(t);}catch(n){console.error("[twitter-web-exporter] Failed to add extension",t==null?void 0:t.name,n);}}function jm(){try{const e=document.getElementById(Hm);if(xu[ku]){if(e)return;xu[ku]=!1;}const t=e??document.createElement("div");e||(t.id=Hm,document.body.append(t)),xu[ku]=!0,Mu(d(kM,{}),t);}catch(e){console.error("[twitter-web-exporter] mountApp failed",e);}}function MA(){TA(),mS(),jM();try{const e=kl();_n(e,KR),_n(e,ZR),_n(e,vA),_n(e,AI),_n(e,PI),_n(e,OR),_n(e,lE),_n(e,JR),_n(e,FI),_n(e,LR),_n(e,im),_n(e,pA),_n(e,II),_n(e,yA),_n(e,CA),_n(e,xA),_n(e,wA),_n(e,mA),_n(e,MI),ut.get("directMessagesCaptureEnabled",!1)&&_n(e,HR),_n(e,iE),_n(e,cE),ut.get("rawCaptureEnabled",!0)&&_n(e,uA),rr.start();}catch(e){console.error("[twitter-web-exporter] bootstrap failed",e),setTimeout(()=>{try{const t=kl();_n(t,im),rr.start();}catch(t){console.error("[twitter-web-exporter] bootstrap retry failed",t);}},250);}document.readyState==="loading"?document.addEventListener("DOMContentLoaded",jm):jm();}MA();

})();