forge-cw 0.1.11 → 0.1.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/console/assets/index-CC7_QwVk.js +31 -0
- package/console/assets/index-GXv21xGs.css +1 -0
- package/console/index.html +6 -2
- package/console/shared/forge-dev-sdk.js +1 -0
- package/console/shared/forge-dev-ui.css +32 -0
- package/console/shared/forge-dev-ui.js +13 -0
- package/console/shared/preact-compat.js +1 -0
- package/console/shared/preact-hooks.js +1 -0
- package/console/shared/preact-jsx-runtime.js +1 -0
- package/console/shared/preact-signals.js +1 -0
- package/console/shared/preact.js +1 -0
- package/dist/index.js +3868 -310
- package/package.json +3 -3
- package/console/assets/index-5ifgSOpU.js +0 -41
- package/console/assets/index-N7b3C-h8.css +0 -32
- /package/console/{assets/addon-web-links-BWjmmSgS.js → shared/chunk-BWjmmSgS.js} +0 -0
- /package/console/{assets/addon-fit-BlxrFPDK.js → shared/chunk-BlxrFPDK.js} +0 -0
- /package/console/{assets/xterm-DlVFs1Kw.js → shared/chunk-DlVFs1Kw.js} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
:root,[data-theme=dark]{--bg: #161618;--bg-2: #1f1f22;--card: #26262a;--card-2: #2e2e33;--elev: rgba(255,255,255,.04);--hair: rgba(255,255,255,.1);--hair-2: rgba(255,255,255,.16);--ink: #f5f5f7;--ink-2: #a1a1a8;--ink-3: #6e6e76;--blue: #0a84ff;--blue-2: #409cff;--green: #30d158;--orange: #ff9f0a;--red: #ff453a;--purple: #bf5af2;--teal: #40c8e0;--glass: rgba(28,28,30,.72);--shadow-s: 0 1px 2px rgba(0,0,0,.4);--shadow-m: 0 6px 20px rgba(0,0,0,.42);--shadow-l: 0 24px 60px rgba(0,0,0,.55);--term: #0e0e10;--sel: rgba(10,132,255,.18);--forge-harness-claude: #e08a68;--forge-harness-codex: #2fbf97;--forge-harness-pi: #6b9bff;--forge-harness-opencode: #e8b44a;--font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Helvetica Neue", Helvetica, sans-serif;--mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, monospace;--ease: cubic-bezier(.32,.72,0,1);color-scheme:dark}[data-theme=light]{--bg: #f2f2f5;--bg-2: #f8f8fa;--card: #ffffff;--card-2: #ffffff;--elev: rgba(0,0,0,.02);--hair: rgba(0,0,0,.09);--hair-2: rgba(0,0,0,.16);--ink: #1d1d1f;--ink-2: #6e6e73;--ink-3: #8e8e93;--blue: #007aff;--blue-2: #0a6cff;--green: #28a745;--orange: #e08600;--red: #e0352b;--purple: #8944ab;--teal: #0d9bb5;--glass: rgba(248,248,250,.78);--shadow-s: 0 1px 2px rgba(0,0,0,.06);--shadow-m: 0 6px 18px rgba(0,0,0,.09);--shadow-l: 0 24px 60px rgba(0,0,0,.14);--term: #1c1c1e;--sel: rgba(0,122,255,.14);--forge-harness-claude: #c9633f;--forge-harness-codex: #0f8f6f;--forge-harness-pi: #2f6fe0;--forge-harness-opencode: #c98a12;color-scheme:light}*{box-sizing:border-box;margin:0;padding:0}body{font-family:var(--font);font-size:13.5px;line-height:1.45;letter-spacing:-.003em;background:var(--bg);color:var(--ink);-webkit-font-smoothing:antialiased}input,textarea,select,button{font-family:inherit;letter-spacing:inherit}input::placeholder,textarea::placeholder{color:var(--ink-3)}a{color:var(--blue);text-decoration:none}a:hover{color:var(--blue-2)}::selection{background:var(--sel)}.mono,code,pre,kbd{font-family:var(--mono);font-variant-numeric:tabular-nums}select{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238e8e93' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 10px center;padding-right:28px}:focus-visible{outline:3px solid color-mix(in srgb,var(--blue) 55%,transparent);outline-offset:2px;border-radius:8px}input:focus-visible,textarea:focus-visible,select:focus-visible{outline:none}.field{width:100%;height:38px;padding:0 12px;border-radius:11px;border:1px solid var(--hair);background-color:var(--card);color:var(--ink);font-size:13.5px;outline:none;transition:border-color .18s var(--ease),box-shadow .18s var(--ease)}textarea.field{height:auto;padding:10px 12px;resize:none;line-height:1.45}select.field{padding-right:28px}.field:focus,.field:focus-within{border-color:var(--blue)!important;box-shadow:0 0 0 4px var(--sel)!important}@keyframes riseIn{0%{opacity:0;transform:translateY(6px)}to{opacity:1;transform:none}}@keyframes slideIn{0%{transform:translate(24px);opacity:0}to{transform:none;opacity:1}}@keyframes popIn{0%{transform:scale(.96);opacity:0}to{transform:none;opacity:1}}@keyframes breathe{0%,to{opacity:1;transform:scale(1)}50%{opacity:.45;transform:scale(.82)}}@keyframes sweep{0%{transform:translate(-100%)}to{transform:translate(320%)}}.sb-toggle,.sb-scrim{display:none}@media(max-width:900px){.forge-shell{grid-template-columns:56px minmax(0,1fr)!important}.forge-sidebar{padding:14px 8px 12px!important;align-items:stretch}.forge-sidebar .sb-label,.forge-sidebar .sb-section{display:none!important}.forge-sidebar nav button,.forge-sidebar>[role=button],.forge-sidebar>button{justify-content:center;padding:0!important}.forge-sidebar>button{height:32px}.task-row .harness-pill{display:none}}@media(max-width:700px){.forge-shell{grid-template-columns:minmax(0,1fr)!important}.forge-sidebar{position:fixed!important;z-index:65;left:0;width:min(272px,86vw);padding:14px 10px 12px!important;box-shadow:var(--shadow-l);transform:translate(-105%);transition:transform .3s var(--ease)}.forge-sidebar.open{transform:none}.forge-sidebar .sb-label,.forge-sidebar .sb-section{display:revert!important}.forge-sidebar .sb-section{display:flex!important}.forge-sidebar nav button,.forge-sidebar>[role=button],.forge-sidebar>button{justify-content:flex-start;padding:0 9px!important}.forge-sidebar>button{padding:6px 9px!important;height:auto}.sb-scrim.open{display:block;position:fixed;top:0;right:0;bottom:0;left:0;z-index:64;background:#00000061;backdrop-filter:blur(4px);-webkit-backdrop-filter:blur(4px)}.sb-toggle{display:grid}.task-row .task-meta,.task-row .task-chip,.task-row .task-done{display:none}.task-row{gap:10px!important}.skills-page{grid-template-columns:minmax(0,1fr)!important;grid-template-rows:auto minmax(0,1fr);height:auto!important;min-height:100vh}.skills-rail{max-height:42vh;border-right:0!important;border-bottom:1px solid var(--hair)}.task-terminal{margin:0 12px 12px!important}}@media(prefers-reduced-motion:reduce){*,*:before,*:after{animation-duration:.001ms!important;animation-iteration-count:1!important;transition-duration:.001ms!important}}*,:before,:after{--un-rotate:0;--un-rotate-x:0;--un-rotate-y:0;--un-rotate-z:0;--un-scale-x:1;--un-scale-y:1;--un-scale-z:1;--un-skew-x:0;--un-skew-y:0;--un-translate-x:0;--un-translate-y:0;--un-translate-z:0;--un-pan-x: ;--un-pan-y: ;--un-pinch-zoom: ;--un-scroll-snap-strictness:proximity;--un-ordinal: ;--un-slashed-zero: ;--un-numeric-figure: ;--un-numeric-spacing: ;--un-numeric-fraction: ;--un-border-spacing-x:0;--un-border-spacing-y:0;--un-ring-offset-shadow:0 0 rgb(0 0 0 / 0);--un-ring-shadow:0 0 rgb(0 0 0 / 0);--un-shadow-inset: ;--un-shadow:0 0 rgb(0 0 0 / 0);--un-ring-inset: ;--un-ring-offset-width:0px;--un-ring-offset-color:#fff;--un-ring-width:0px;--un-ring-color:rgb(147 197 253 / .5);--un-blur: ;--un-brightness: ;--un-contrast: ;--un-drop-shadow: ;--un-grayscale: ;--un-hue-rotate: ;--un-invert: ;--un-saturate: ;--un-sepia: ;--un-backdrop-blur: ;--un-backdrop-brightness: ;--un-backdrop-contrast: ;--un-backdrop-grayscale: ;--un-backdrop-hue-rotate: ;--un-backdrop-invert: ;--un-backdrop-opacity: ;--un-backdrop-saturate: ;--un-backdrop-sepia: }::backdrop{--un-rotate:0;--un-rotate-x:0;--un-rotate-y:0;--un-rotate-z:0;--un-scale-x:1;--un-scale-y:1;--un-scale-z:1;--un-skew-x:0;--un-skew-y:0;--un-translate-x:0;--un-translate-y:0;--un-translate-z:0;--un-pan-x: ;--un-pan-y: ;--un-pinch-zoom: ;--un-scroll-snap-strictness:proximity;--un-ordinal: ;--un-slashed-zero: ;--un-numeric-figure: ;--un-numeric-spacing: ;--un-numeric-fraction: ;--un-border-spacing-x:0;--un-border-spacing-y:0;--un-ring-offset-shadow:0 0 rgb(0 0 0 / 0);--un-ring-shadow:0 0 rgb(0 0 0 / 0);--un-shadow-inset: ;--un-shadow:0 0 rgb(0 0 0 / 0);--un-ring-inset: ;--un-ring-offset-width:0px;--un-ring-offset-color:#fff;--un-ring-width:0px;--un-ring-color:rgb(147 197 253 / .5);--un-blur: ;--un-brightness: ;--un-contrast: ;--un-drop-shadow: ;--un-grayscale: ;--un-hue-rotate: ;--un-invert: ;--un-saturate: ;--un-sepia: ;--un-backdrop-blur: ;--un-backdrop-brightness: ;--un-backdrop-contrast: ;--un-backdrop-grayscale: ;--un-backdrop-hue-rotate: ;--un-backdrop-invert: ;--un-backdrop-opacity: ;--un-backdrop-saturate: ;--un-backdrop-sepia: }.i-lucide-brain{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M12 18V5m3 8a4.17 4.17 0 0 1-3-4a4.17 4.17 0 0 1-3 4m8.598-6.5A3 3 0 1 0 12 5a3 3 0 1 0-5.598 1.5'/%3E%3Cpath d='M17.997 5.125a4 4 0 0 1 2.526 5.77'/%3E%3Cpath d='M18 18a4 4 0 0 0 2-7.464'/%3E%3Cpath d='M19.967 17.483A4 4 0 1 1 12 18a4 4 0 1 1-7.967-.517'/%3E%3Cpath d='M6 18a4 4 0 0 1-2-7.464'/%3E%3Cpath d='M6.003 5.125a4 4 0 0 0-2.526 5.77'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-check{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M20 6L9 17l-5-5'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-chevron-down{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m6 9l6 6l6-6'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-chevron-right{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m9 18l6-6l-6-6'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-chevrons-up-down{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m7 15l5 5l5-5M7 9l5-5l5 5'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-clock{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M12 6v6l4 2'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-copy{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Crect width='14' height='14' x='8' y='8' rx='2' ry='2'/%3E%3Cpath d='M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-external-link{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M15 3h6v6m-11 5L21 3m-3 10v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-folder{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-folder-search{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M10.7 20H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2v4.1M21 21l-1.9-1.9'/%3E%3Ccircle cx='17' cy='17' r='3'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-frame{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M22 6H2m20 12H2M6 2v20M18 2v20'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-inbox{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M22 12h-6l-2 3h-4l-2-3H2'/%3E%3Cpath d='M5.45 5.11L2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-loader-2{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M21 12a9 9 0 1 1-6.219-8.56'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-menu{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 5h16M4 12h16M4 19h16'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-message-square{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-package{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73zm1 .27V12'/%3E%3Cpath d='M3.29 7L12 12l8.71-5M7.5 4.27l9 5.15'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-package-x{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M12 22V12m4.5 2.5l5 5m-5 0l5-5m-.5-4V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.729l7 4a2 2 0 0 0 2 .001l.13-.074'/%3E%3Cpath d='M3.29 7L12 12l8.71-5M7.5 4.27l8.997 5.148'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-plus{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M5 12h14m-7-7v14'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-refresh-cw{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M3 12a9 9 0 0 1 9-9a9.75 9.75 0 0 1 6.74 2.74L21 8'/%3E%3Cpath d='M21 3v5h-5m5 4a9 9 0 0 1-9 9a9.75 9.75 0 0 1-6.74-2.74L3 16'/%3E%3Cpath d='M8 16H3v5'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-search{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='m21 21l-4.34-4.34'/%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-settings{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M9.671 4.136a2.34 2.34 0 0 1 4.659 0a2.34 2.34 0 0 0 3.319 1.915a2.34 2.34 0 0 1 2.33 4.033a2.34 2.34 0 0 0 0 3.831a2.34 2.34 0 0 1-2.33 4.033a2.34 2.34 0 0 0-3.319 1.915a2.34 2.34 0 0 1-4.659 0a2.34 2.34 0 0 0-3.32-1.915a2.34 2.34 0 0 1-2.33-4.033a2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.i-lucide-x{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M18 6L6 18M6 6l12 12'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;width:1.2em;height:1.2em}.container{width:100%}@media(min-width:640px){.container{max-width:640px}}@media(min-width:768px){.container{max-width:768px}}@media(min-width:1024px){.container{max-width:1024px}}@media(min-width:1280px){.container{max-width:1280px}}@media(min-width:1536px){.container{max-width:1536px}}.pointer-events-none{pointer-events:none}.visible{visibility:visible}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.inset-y-0{top:0;bottom:0}.bottom-0{bottom:0}.bottom-4{bottom:1rem}.left-0{left:0}.right-0{right:0}.right-4{right:1rem}.top-0{top:0}.top-full{top:100%}.z-\[55\]{z-index:55}.z-\[60\]{z-index:60}.z-\[70\]{z-index:70}.z-1{z-index:1}.z-20{z-index:20}.z-30{z-index:30}.z-40{z-index:40}.z-50{z-index:50}.grid{display:grid}.mx-auto{margin-left:auto;margin-right:auto}.my{margin-top:1rem;margin-bottom:1rem}.mb-1{margin-bottom:.25rem}.mb-3\.5{margin-bottom:.875rem}.me{margin-inline-end:1rem}.ml-3{margin-left:.75rem}.ms{margin-inline-start:1rem}.mt-2{margin-top:.5rem}.block{display:block}.contents{display:contents}.hidden{display:none}.h-0\.5{height:.125rem}.h-16{height:4rem}.h-full{height:100%}.max-w-full{max-width:100%}.min-h-0{min-height:0}.min-h-full{min-height:100%}.min-w-0{min-width:0}.w-1{width:.25rem}.w-full{width:100%}.flex{display:flex}.inline-flex{display:inline-flex}.flex-1{flex:1 1 0%}.shrink-0{flex-shrink:0}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.hover\:-translate-y-px:hover{--un-translate-y:-1px;transform:translate(var(--un-translate-x)) translateY(var(--un-translate-y)) translateZ(var(--un-translate-z)) rotate(var(--un-rotate)) rotateX(var(--un-rotate-x)) rotateY(var(--un-rotate-y)) rotate(var(--un-rotate-z)) skew(var(--un-skew-x)) skewY(var(--un-skew-y)) scaleX(var(--un-scale-x)) scaleY(var(--un-scale-y)) scaleZ(var(--un-scale-z))}.transform{transform:translate(var(--un-translate-x)) translateY(var(--un-translate-y)) translateZ(var(--un-translate-z)) rotate(var(--un-rotate)) rotateX(var(--un-rotate-x)) rotateY(var(--un-rotate-y)) rotate(var(--un-rotate-z)) skew(var(--un-skew-x)) skewY(var(--un-skew-y)) scaleX(var(--un-scale-x)) scaleY(var(--un-scale-y)) scaleZ(var(--un-scale-z))}@keyframes pulse{0%,to{opacity:1}50%{opacity:.5}}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}.animate-spin{animation:spin 1s linear infinite}.cursor-pointer{cursor:pointer}.disabled\:cursor-wait:disabled{cursor:wait}.cursor-copy{cursor:copy}.cursor-not-allowed{cursor:not-allowed}.disabled\:cursor-not-allowed:disabled{cursor:not-allowed}.cursor-col-resize{cursor:col-resize}.cursor-zoom-in{cursor:zoom-in}.cursor-zoom-out{cursor:zoom-out}.resize{resize:both}.place-items-center{place-items:center}.items-start{align-items:flex-start}.items-center{align-items:center}.self-start{align-self:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-1\.5{gap:.375rem}.gap-2{gap:.5rem}.gap-2\.5{gap:.625rem}.gap-3\.5{gap:.875rem}.space-y-1>:not([hidden])~:not([hidden]){--un-space-y-reverse:0;margin-top:calc(.25rem * calc(1 - var(--un-space-y-reverse)));margin-bottom:calc(.25rem * var(--un-space-y-reverse))}.space-y-2>:not([hidden])~:not([hidden]){--un-space-y-reverse:0;margin-top:calc(.5rem * calc(1 - var(--un-space-y-reverse)));margin-bottom:calc(.5rem * var(--un-space-y-reverse))}.space-y-4>:not([hidden])~:not([hidden]){--un-space-y-reverse:0;margin-top:calc(1rem * calc(1 - var(--un-space-y-reverse)));margin-bottom:calc(1rem * var(--un-space-y-reverse))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.overflow-x-hidden{overflow-x:hidden}.overflow-y-auto{overflow-y:auto}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.whitespace-nowrap{white-space:nowrap}.b,.border{border-width:1px}.hover\:border-hair2:hover{border-color:var(--hair-2)}.hover\:bg-blue:hover{background-color:var(--blue)}.hover\:bg-elev:hover{background-color:var(--elev)}.px{padding-left:1rem;padding-right:1rem}.px-3{padding-left:.75rem;padding-right:.75rem}.py-2\.5{padding-top:.625rem;padding-bottom:.625rem}.py-20{padding-top:5rem;padding-bottom:5rem}.pb-3{padding-bottom:.75rem}.pr{padding-right:1rem}.pt-1{padding-top:.25rem}.text-center{text-align:center}.text-left{text-align:left}.text-right{text-align:right}.indent{text-indent:1.5rem}.text-ink2{color:var(--ink-2)}.text-ink3{color:var(--ink-3)}.hover\:text-green:hover{color:var(--green)}.hover\:text-ink:hover{color:var(--ink)}.hover\:text-red:hover{color:var(--red)}.uppercase{text-transform:uppercase}.tabular-nums{--un-numeric-spacing:tabular-nums;font-variant-numeric:var(--un-ordinal) var(--un-slashed-zero) var(--un-numeric-figure) var(--un-numeric-spacing) var(--un-numeric-fraction)}.hover\:underline:hover{text-decoration-line:underline}.tab{-moz-tab-size:4;-o-tab-size:4;tab-size:4}.opacity-0{opacity:0}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.group:hover .group-hover\:opacity-100{opacity:1}.focus-visible\:opacity-100:focus-visible{opacity:1}.disabled\:opacity-40:disabled{opacity:.4}.disabled\:opacity-60:disabled{opacity:.6}.outline{outline-style:solid}.hover\:brightness-106:hover{--un-brightness:brightness(1.06);filter:var(--un-blur) var(--un-brightness) var(--un-contrast) var(--un-drop-shadow) var(--un-grayscale) var(--un-hue-rotate) var(--un-invert) var(--un-saturate) var(--un-sepia)}.filter{filter:var(--un-blur) var(--un-brightness) var(--un-contrast) var(--un-drop-shadow) var(--un-grayscale) var(--un-hue-rotate) var(--un-invert) var(--un-saturate) var(--un-sepia)}.backdrop-filter{-webkit-backdrop-filter:var(--un-backdrop-blur) var(--un-backdrop-brightness) var(--un-backdrop-contrast) var(--un-backdrop-grayscale) var(--un-backdrop-hue-rotate) var(--un-backdrop-invert) var(--un-backdrop-opacity) var(--un-backdrop-saturate) var(--un-backdrop-sepia);backdrop-filter:var(--un-backdrop-blur) var(--un-backdrop-brightness) var(--un-backdrop-contrast) var(--un-backdrop-grayscale) var(--un-backdrop-hue-rotate) var(--un-backdrop-invert) var(--un-backdrop-opacity) var(--un-backdrop-saturate) var(--un-backdrop-sepia)}.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}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.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}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-140{transition-duration:.14s}.duration-160{transition-duration:.16s}.duration-180{transition-duration:.18s}.duration-200{transition-duration:.2s}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}.hover\:shadow-m:hover{box-shadow:var(--shadow-m)}.ease-spring{transition-timing-function:var(--ease)}.glass{background:var(--glass);backdrop-filter:blur(22px) saturate(180%);-webkit-backdrop-filter:blur(22px) saturate(180%)}.popover{background:var(--glass);backdrop-filter:blur(30px) saturate(180%);-webkit-backdrop-filter:blur(30px) saturate(180%);border:1px solid var(--hair-2);box-shadow:var(--shadow-l);animation:popIn .2s var(--ease) both}.breathe{animation:breathe 2.4s ease-in-out infinite}
|
package/console/index.html
CHANGED
|
@@ -1,11 +1,15 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
2
|
<html lang="en">
|
|
3
3
|
<head>
|
|
4
|
+
|
|
5
|
+
|
|
4
6
|
<meta charset="UTF-8" />
|
|
5
7
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
8
|
<title>Forge Console</title>
|
|
7
|
-
<script type="
|
|
8
|
-
<
|
|
9
|
+
<script type="importmap">{"imports":{"preact":"/shared/preact.js","preact/hooks":"/shared/preact-hooks.js","preact/jsx-runtime":"/shared/preact-jsx-runtime.js","preact/compat":"/shared/preact-compat.js","@preact/signals":"/shared/preact-signals.js","@forge-dev/ui":"/shared/forge-dev-ui.js","@forge-dev/sdk":"/shared/forge-dev-sdk.js"}}</script>
|
|
10
|
+
<script type="module" crossorigin src="/assets/index-CC7_QwVk.js"></script>
|
|
11
|
+
<link rel="stylesheet" crossorigin href="/assets/index-GXv21xGs.css">
|
|
12
|
+
<link rel="stylesheet" href="/shared/forge-dev-ui.css">
|
|
9
13
|
</head>
|
|
10
14
|
<body>
|
|
11
15
|
<div id="app"></div>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var s=Object.defineProperty;var i=(e,r,n)=>r in e?s(e,r,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[r]=n;var t=(e,r,n)=>i(e,typeof r!="symbol"?r+"":r,n);const u="1.0.0";function d(e){return e}function l(e){return e}function f(e){return e}function a(e){return e}function E(e){return e}function p(e){return e}function h(e,r){return{event:e,handler:r}}function m(e,r){return{kind:"shell",command:e,args:r}}function x(e){return typeof e=="object"&&e!==null&&e.kind==="shell"}const M=["preact","preact/hooks","preact/jsx-runtime","preact/compat","@preact/signals","@forge-dev/ui","@forge-dev/sdk"],R=/^[a-z][a-z0-9-]{1,31}$/;class v extends Error{constructor(n,o){super(o);t(this,"code");this.name="ModuleError",this.code=n}}class D extends Error{constructor(n,o){super(`permission ${n} does not cover ${o}`);t(this,"permission");t(this,"value");this.name="PermissionError",this.permission=n,this.value=o}}class S extends Error{constructor(n,o){super(o);t(this,"code");this.name="ModuleRequestError",this.code=n}}export{R as MODULE_ID_RE,v as ModuleError,S as ModuleRequestError,D as PermissionError,u as SDK_VERSION,M as SHARED_PACKAGES,a as defineAction,p as defineDetector,E as defineJob,l as defineModule,d as definePanel,f as defineRoute,x as isShellExecutor,h as onEvent,m as shell};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2014 The xterm.js authors. All rights reserved.
|
|
3
|
+
* Copyright (c) 2012-2013, Christopher Jeffrey (MIT License)
|
|
4
|
+
* https://github.com/chjj/term.js
|
|
5
|
+
* @license MIT
|
|
6
|
+
*
|
|
7
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
8
|
+
* of this software and associated documentation files (the "Software"), to deal
|
|
9
|
+
* in the Software without restriction, including without limitation the rights
|
|
10
|
+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
11
|
+
* copies of the Software, and to permit persons to whom the Software is
|
|
12
|
+
* furnished to do so, subject to the following conditions:
|
|
13
|
+
*
|
|
14
|
+
* The above copyright notice and this permission notice shall be included in
|
|
15
|
+
* all copies or substantial portions of the Software.
|
|
16
|
+
*
|
|
17
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
18
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
19
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
20
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
21
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
22
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
23
|
+
* THE SOFTWARE.
|
|
24
|
+
*
|
|
25
|
+
* Originally forked from (with the author's permission):
|
|
26
|
+
* Fabrice Bellard's javascript vt100 for jslinux:
|
|
27
|
+
* http://bellard.org/jslinux/
|
|
28
|
+
* Copyright (c) 2011 Fabrice Bellard
|
|
29
|
+
* The original design remains. The terminal itself
|
|
30
|
+
* has been extended to include xterm CSI codes, among
|
|
31
|
+
* other features.
|
|
32
|
+
*/.xterm{cursor:text;position:relative;user-select:none;-ms-user-select:none;-webkit-user-select:none}.xterm.focus,.xterm:focus{outline:none}.xterm .xterm-helpers{position:absolute;top:0;z-index:5}.xterm .xterm-helper-textarea{padding:0;border:0;margin:0;position:absolute;opacity:0;left:-9999em;top:0;width:0;height:0;z-index:-5;white-space:nowrap;overflow:hidden;resize:none}.xterm .composition-view{background:#000;color:#fff;display:none;position:absolute;white-space:nowrap;z-index:1}.xterm .composition-view.active{display:block}.xterm .xterm-viewport{background-color:#000;overflow-y:scroll;cursor:default;position:absolute;right:0;left:0;top:0;bottom:0}.xterm .xterm-screen{position:relative}.xterm .xterm-screen canvas{position:absolute;left:0;top:0}.xterm .xterm-scroll-area{visibility:hidden}.xterm-char-measure-element{display:inline-block;visibility:hidden;position:absolute;top:0;left:-9999em;line-height:normal}.xterm.enable-mouse-events{cursor:default}.xterm.xterm-cursor-pointer,.xterm .xterm-cursor-pointer{cursor:pointer}.xterm.column-select.focus{cursor:crosshair}.xterm .xterm-accessibility:not(.debug),.xterm .xterm-message{position:absolute;left:0;top:0;bottom:0;right:0;z-index:10;color:transparent;pointer-events:none}.xterm .xterm-accessibility-tree:not(.debug) *::selection{color:transparent}.xterm .xterm-accessibility-tree{-webkit-user-select:text;user-select:text;white-space:pre}.xterm .live-region{position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden}.xterm-dim{opacity:1!important}.xterm-underline-1{text-decoration:underline}.xterm-underline-2{text-decoration:double underline}.xterm-underline-3{text-decoration:wavy underline}.xterm-underline-4{text-decoration:dotted underline}.xterm-underline-5{text-decoration:dashed underline}.xterm-overline{text-decoration:overline}.xterm-overline.xterm-underline-1{text-decoration:overline underline}.xterm-overline.xterm-underline-2{text-decoration:overline double underline}.xterm-overline.xterm-underline-3{text-decoration:overline wavy underline}.xterm-overline.xterm-underline-4{text-decoration:overline dotted underline}.xterm-overline.xterm-underline-5{text-decoration:overline dashed underline}.xterm-strikethrough{text-decoration:line-through}.xterm-screen .xterm-decoration-container .xterm-decoration{z-index:6;position:absolute}.xterm-screen .xterm-decoration-container .xterm-decoration.xterm-decoration-top-layer{z-index:7}.xterm-decoration-overview-ruler{z-index:8;position:absolute;top:0;right:0;pointer-events:none}.xterm-decoration-top{z-index:2;position:relative}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import{jsx as e}from"./preact-jsx-runtime.js";import{useState as B,useRef as w,useEffect as _,useLayoutEffect as H,useCallback as G}from"./preact-hooks.js";import{signal as U}from"./preact-signals.js";import"./preact.js";const ee={good:"var(--green)",warn:"var(--orange)",bad:"var(--red)",neutral:"var(--ink-3)"},ge=({icon:r,label:n,value:o,trend:t,status:a})=>e("div",{class:"relative overflow-hidden",style:{padding:"10px 12px",borderRadius:"13px",background:"var(--card)",border:"1px solid var(--hair)",boxShadow:"var(--shadow-s)"},children:[e("div",{class:"flex items-center gap-2",style:{fontSize:"11.5px",color:"var(--ink-2)"},children:[e("span",{children:r}),e("span",{children:n})]}),e("div",{class:"mono",style:{fontSize:"19px",fontWeight:650,marginTop:"2px"},children:o}),t&&e("div",{class:"mono",style:{fontSize:"11.5px",marginTop:"2px",color:t.startsWith("-")?"var(--red)":"var(--green)"},children:t}),e("div",{class:"absolute bottom-0 left-0 right-0 h-0.5",style:{backgroundColor:ee[a]}})]}),re={sm:{pad:"6px 12px",primaryPad:"6px 14px",font:"12.5px",radius:"9px"},md:{pad:"7px 13px",primaryPad:"7px 15px",font:"13px",radius:"9px"},lg:{pad:"12px 16px",primaryPad:"12px 16px",font:"14.5px",radius:"12px"}},q={primary:{background:"linear-gradient(180deg, var(--blue-2), var(--blue))",color:"#fff",border:"0",boxShadow:"var(--shadow-m)",fontWeight:"600"},secondary:{background:"var(--card)",color:"var(--ink)",border:"1px solid var(--hair)",boxShadow:"var(--shadow-s)",fontWeight:"500"},danger:{background:"var(--card)",color:"var(--red)",border:"1px solid var(--hair)",boxShadow:"var(--shadow-s)",fontWeight:"500"},destructive:{background:"var(--red)",color:"#fff",border:"0",boxShadow:"var(--shadow-m)",fontWeight:"600"}},te={background:"var(--elev)",color:"var(--ink-3)",border:"1px solid transparent",boxShadow:"none",opacity:".8"},ne=({label:r,icon:n,variant:o="primary",size:t="md",block:a,title:x,disabled:s,loading:c,onClick:d})=>{const[i,h]=B(!1),p=c??i,l=!!(s||p),u=async()=>{if(!l){h(!0);try{await d()}finally{h(!1)}}},f=re[t],S=o==="primary"||o==="destructive",L=s&&!p?{...q[o],...te}:q[o];return e("button",{type:"button",class:`inline-flex items-center justify-center gap-1.5 whitespace-nowrap transition-all duration-180 ease-spring ${l?"cursor-not-allowed":`cursor-pointer hover:-translate-y-px hover:shadow-m${S?" hover:brightness-106":""}`}${a?" w-full":""}`,style:{...L,padding:S?f.primaryPad:f.pad,fontSize:f.font,borderRadius:f.radius},disabled:l,title:x,onClick:u,children:[p?e("span",{class:"i-lucide-loader-2 animate-spin"}):n?e("span",{class:n}):null,e("span",{children:r})]})},oe="modulepreload",se=function(r){return"/"+r},X={},N=function(n,o,t){let a=Promise.resolve();if(o&&o.length>0){let s=function(i){return Promise.all(i.map(h=>Promise.resolve(h).then(p=>({status:"fulfilled",value:p}),p=>({status:"rejected",reason:p}))))};document.getElementsByTagName("link");const c=document.querySelector("meta[property=csp-nonce]"),d=(c==null?void 0:c.nonce)||(c==null?void 0:c.getAttribute("nonce"));a=s(o.map(i=>{if(i=se(i),i in X)return;X[i]=!0;const h=i.endsWith(".css"),p=h?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${i}"]${p}`))return;const l=document.createElement("link");if(l.rel=h?"stylesheet":oe,h||(l.as="script"),l.crossOrigin="",l.href=i,d&&l.setAttribute("nonce",d),document.head.appendChild(l),h)return new Promise((u,f)=>{l.addEventListener("load",u),l.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${i}`)))})}))}function x(s){const c=new Event("vite:preloadError",{cancelable:!0});if(c.payload=s,window.dispatchEvent(c),!c.defaultPrevented)throw s}return a.then(s=>{for(const c of s||[])c.status==="rejected"&&x(c.reason);return n().catch(x)})},ae='ui-monospace, "SF Mono", SFMono-Regular, Menlo, monospace',I=r=>({background:r==="dark"?"#0e0e10":"#1c1c1e",foreground:"#e3e3e8",cursor:"#e3e3e8",selectionBackground:"rgba(10,132,255,0.35)"}),be=({streamUrl:r,content:n,wsUrl:o,height:t=300,onExit:a,onGiveUp:x,onConnectionChange:s,onOutput:c,focused:d=!0,theme:i="dark"})=>{const h=w(null),p=!!o,l=w(a);l.current=a;const u=w(x);u.current=x;const f=w(s);f.current=s;const S=w(c);S.current=c;const L=w(i);L.current=i;const j=w(d);j.current=d;const T=w(null);_(()=>{T.current&&(T.current.options.theme=I(i))},[i]),_(()=>{var k;p&&d&&((k=T.current)==null||k.focus())},[d,p]),_(()=>{if(!h.current)return;let k=!1,v=null,C=null,$=0;const J=[];return(async()=>{const{Terminal:F}=await N(async()=>{const{Terminal:b}=await import("./chunk-DlVFs1Kw.js").then(m=>m.x);return{Terminal:b}},[]),{FitAddon:Y}=await N(async()=>{const{FitAddon:b}=await import("./chunk-BlxrFPDK.js").then(m=>m.a);return{FitAddon:b}},[]),{WebLinksAddon:K}=await N(async()=>{const{WebLinksAddon:b}=await import("./chunk-BWjmmSgS.js");return{WebLinksAddon:b}},[]);if(k)return;const g=new F({theme:I(L.current),fontSize:13,fontFamily:ae,convertEol:!p,disableStdin:!p,cursorBlink:p,scrollback:1e4});T.current=g;const D=b=>{var m;g.write(b),(m=S.current)==null||m.call(S,b)},M=new Y;g.loadAddon(M),g.loadAddon(new K),g.open(h.current),setTimeout(()=>{M.fit(),p&&j.current&&g.focus()},50),n&&!p&&D(n);let E;if(r&&!p&&(E=new EventSource(r),E.addEventListener("output",b=>{const{chunk:m}=JSON.parse(b.data);D(m)}),E.addEventListener("done",b=>{const{exitCode:m}=JSON.parse(b.data);g.write(`\r
|
|
2
|
+
\x1B[${m===0?"32":"31"}m--- Exit code: ${m} ---\x1B[0m\r
|
|
3
|
+
`),E==null||E.close()})),o&&!k){const b=m=>{if(k)return;console.log("[ForgeTerminal] Connecting to:",m),v=new WebSocket(m);const O=[];v.onopen=()=>{var y;console.log("[ForgeTerminal] WebSocket OPEN"),$=0,(y=f.current)==null||y.call(f,!0),M.fit();const{cols:W,rows:z}=g;v.send(JSON.stringify({type:"resize",cols:W,rows:z})),O.push(g.onData(R=>{(v==null?void 0:v.readyState)===WebSocket.OPEN&&v.send(JSON.stringify({type:"input",data:R}))})),O.push(g.onResize(({cols:R,rows:P})=>{(v==null?void 0:v.readyState)===WebSocket.OPEN&&v.send(JSON.stringify({type:"resize",cols:R,rows:P}))}))},v.onmessage=W=>{var z;try{const y=JSON.parse(W.data);y.type==="output"||y.type==="scrollback"?D(y.data):y.type==="exit"?(g.write(`\r
|
|
4
|
+
\x1B[33m--- Session ended (code ${y.code}) ---\x1B[0m\r
|
|
5
|
+
`),(z=l.current)==null||z.call(l,y.code)):y.type==="error"&&g.write(`\r
|
|
6
|
+
\x1B[31m--- Error: ${y.message} ---\x1B[0m\r
|
|
7
|
+
`)}catch{}},v.onclose=W=>{var z,y,R;if(console.log("[ForgeTerminal] WebSocket CLOSE:",W.code,W.reason),O.forEach(P=>P.dispose()),O.length=0,(z=f.current)==null||z.call(f,!1),!k)if(W.code===4404)g.write(`\r
|
|
8
|
+
\x1B[31m--- Click Restart to try again. ---\x1B[0m\r
|
|
9
|
+
`),(y=u.current)==null||y.call(u);else if($<5){const P=Math.min(2e3*Math.pow(2,$),16e3);$++,g.write(`\r
|
|
10
|
+
\x1B[90m--- Reconnecting (attempt ${$}/5)... ---\x1B[0m\r
|
|
11
|
+
`),C=setTimeout(()=>b(m),P)}else g.write(`\r
|
|
12
|
+
\x1B[31m--- Connection lost. Click Restart to try again. ---\x1B[0m\r
|
|
13
|
+
`),(R=u.current)==null||R.call(u)},v.onerror=W=>{console.error("[ForgeTerminal] WebSocket error:",W)}};b(o)}const V=new ResizeObserver(()=>{k||M.fit()});V.observe(h.current),J.push({dispose:()=>{E==null||E.close(),V.disconnect(),C&&clearTimeout(C),v&&(k=!0,v.close()),g.dispose(),T.current=null}})})(),()=>{k=!0,J.forEach(F=>F.dispose())}},[r,n,o,p]);const Q=p?{width:"100%",height:"100%"}:{width:"100%",height:`${t}px`};return e("div",{ref:h,class:"overflow-hidden",style:{...Q,background:I(i).background}})},A=U([]);function me(r,n="info"){const o=Math.random().toString(36).slice(2);A.value=[...A.value,{id:o,message:r,type:n}],setTimeout(()=>{A.value=A.value.filter(t=>t.id!==o)},4e3)}const ie={success:"var(--green)",error:"var(--red)",info:"var(--blue)"},ye=()=>e("div",{class:"fixed bottom-4 right-4 flex flex-col gap-2 z-[70]",style:{maxWidth:"calc(100vw - 32px)"},role:"status","aria-live":"polite",children:A.value.map(r=>e("div",{class:"flex items-center gap-2.5",style:{padding:"10px 14px",borderRadius:"12px",background:"var(--card)",border:"1px solid var(--hair)",boxShadow:"var(--shadow-l)",fontSize:"13px",color:"var(--ink)",animation:"riseIn .3s var(--ease) both"},children:[e("span",{class:"shrink-0",style:{width:"6px",height:"6px",borderRadius:"50%",background:ie[r.type]}}),r.message]},r.id))}),le=({label:r,color:n="var(--ink-2)",variant:o="tint",dot:t})=>{const a=o==="tint"?{background:`color-mix(in srgb, ${n} 18%, transparent)`,color:n}:{background:"var(--elev)",color:"var(--ink-2)",border:"1px solid var(--hair)"};return e("span",{class:"inline-flex items-center gap-1.5 whitespace-nowrap shrink-0",style:{...a,padding:"2px 8px",borderRadius:"99px",fontSize:"11px",fontWeight:600},children:[t&&e("span",{style:{width:"6px",height:"6px",borderRadius:"50%",background:n}}),r]})},Z=({onClick:r,label:n="Close"})=>e("button",{type:"button","aria-label":n,class:"grid place-items-center shrink-0 cursor-pointer transition-all duration-180 ease-spring hover:text-ink",style:{width:"26px",height:"26px",borderRadius:"50%",border:"1px solid var(--hair)",background:"var(--card)",color:"var(--ink-2)"},onClick:r,children:e("span",{class:"i-lucide-x",style:{width:"13px",height:"13px"}})}),we=({open:r,title:n,onClose:o,footer:t,width:a=540,children:x})=>(H(()=>{if(!r)return;const s=c=>{c.key==="Escape"&&o()};return window.addEventListener("keydown",s),()=>window.removeEventListener("keydown",s)},[r,o]),r?e("div",{class:"fixed inset-0 z-[55] flex items-start justify-center overflow-auto",style:{background:"rgba(0,0,0,.42)",backdropFilter:"blur(6px)",WebkitBackdropFilter:"blur(6px)",padding:"56px 16px 16px"},onClick:o,children:e("div",{role:"dialog","aria-modal":"true","aria-label":n,class:"flex flex-col overflow-hidden",style:{width:`min(${a}px, 100%)`,maxHeight:"calc(100vh - 72px)",borderRadius:"18px",background:"var(--bg-2)",border:"1px solid var(--hair-2)",boxShadow:"var(--shadow-l)",animation:"popIn .26s var(--ease) both"},onClick:s=>s.stopPropagation(),children:[e("div",{class:"flex items-center gap-2.5 shrink-0",style:{padding:"14px 18px",borderBottom:"1px solid var(--hair)"},children:[e("h2",{style:{fontSize:"17px",fontWeight:700,letterSpacing:"-0.02em"},children:n}),e("span",{class:"flex-1"}),e(Z,{onClick:o})]}),e("div",{class:"overflow-auto min-h-0",style:{padding:"16px 18px"},children:x}),t&&e("div",{class:"flex items-center gap-2.5 shrink-0",style:{padding:"13px 18px",borderTop:"1px solid var(--hair)"},children:t})]})}):null),ke=({title:r,onClose:n,children:o})=>(H(()=>{const t=a=>{a.key==="Escape"&&n()};return window.addEventListener("keydown",t),()=>window.removeEventListener("keydown",t)},[n]),e("div",{class:"fixed inset-0 z-50 flex justify-end",style:{background:"rgba(0,0,0,.38)",backdropFilter:"blur(4px)",WebkitBackdropFilter:"blur(4px)"},onClick:n,children:e("aside",{role:"dialog","aria-modal":"true","aria-label":r,class:"flex flex-col h-full overflow-auto",style:{width:"min(492px, 100%)",background:"var(--bg-2)",borderLeft:"1px solid var(--hair)",boxShadow:"var(--shadow-l)",animation:"slideIn .3s var(--ease) both"},onClick:t=>t.stopPropagation(),children:[e("div",{class:"glass flex items-center sticky top-0 z-1",style:{gap:"10px",padding:"14px 18px",borderBottom:"1px solid var(--hair)"},children:[e("h2",{style:{fontSize:"17px",fontWeight:700,letterSpacing:"-0.02em"},children:r}),e("span",{class:"flex-1"}),e(Z,{onClick:n})]}),e("div",{class:"flex flex-col",style:{padding:"16px 18px 24px",gap:"14px"},children:o})]})})),Se=({tabs:r,active:n,onChange:o,fill:t,size:a="md",label:x})=>{const s=a!=="md",c=a==="xs";return e("div",{role:"tablist","aria-label":x,class:`${t?"flex":"inline-flex"} max-w-full overflow-x-auto`,style:{padding:"3px",borderRadius:s?"10px":"11px",background:"var(--elev)",border:"1px solid var(--hair)"},children:r.map(d=>{const i=n===d.id;return e("button",{type:"button",role:"tab","aria-selected":i,disabled:d.disabled,class:`flex items-center justify-center gap-1.5 whitespace-nowrap transition-all duration-200 ease-spring ${t?"flex-1":""} ${d.disabled?"cursor-not-allowed opacity-50":"cursor-pointer"}`,style:{padding:c?"4px 0":t?s?"5px 6px":"7px 8px":s?"5px 11px":"6px 12px",border:0,borderRadius:s?"7px":"8px",fontSize:c?"11.5px":s?"12px":"12.5px",fontWeight:600,background:i?"var(--card)":"transparent",color:i?"var(--ink)":"var(--ink-3)",boxShadow:i?"var(--shadow-s)":"none"},onClick:()=>o(d.id),children:[d.label,d.count!==void 0&&e("span",{class:"mono",style:{fontSize:"11px",fontWeight:400,color:"var(--ink-3)"},children:d.count})]},d.id)})})},ce=({item:r,onItemClick:n})=>{const[o,t]=B(!1);return e("div",{class:`flex items-center justify-between transition-all duration-180 ease-spring ${n?"cursor-pointer":""}`,style:{padding:"11px 15px",borderRadius:"12px",background:"var(--card)",border:`1px solid ${n&&o?"var(--hair-2)":"var(--hair)"}`,boxShadow:"var(--shadow-s)"},onMouseEnter:n?()=>t(!0):void 0,onMouseLeave:n?()=>t(!1):void 0,onClick:n?()=>n(r.id):void 0,children:[e("div",{class:"min-w-0 flex-1",children:[e("div",{class:"truncate",style:{fontSize:"14px",fontWeight:600},children:r.title}),r.subtitle&&e("div",{class:"truncate",style:{fontSize:"12px",color:"var(--ink-2)",marginTop:"2px"},children:r.subtitle})]}),e("div",{class:"flex items-center gap-2 ml-3",children:[r.badge&&e(le,{label:r.badge.label,color:r.badge.color,variant:"tint"}),r.trailing]})]})},Ee=({items:r,loading:n,onItemClick:o})=>n?e("div",{class:"space-y-2",children:[1,2,3].map(t=>e("div",{class:"h-16 animate-pulse",style:{borderRadius:"12px",background:"var(--card)"}},t))}):r.length===0?null:e("div",{class:"space-y-1",children:r.map(t=>e(ce,{item:t,onItemClick:o},t.id))}),We=({icon:r,title:n,description:o,action:t})=>e("div",{class:"flex flex-col items-center justify-center text-center mx-auto",style:{maxWidth:"520px",padding:"36px 28px",borderRadius:"16px",background:"var(--card)",border:"1px solid var(--hair)",boxShadow:"var(--shadow-m)",animation:"riseIn .34s var(--ease) both"},children:[r&&e("span",{class:r,style:{width:"28px",height:"28px",color:"var(--ink-3)",marginBottom:"14px"}}),e("h3",{style:{fontSize:"17px",fontWeight:700,letterSpacing:"-0.02em",marginBottom:"6px"},children:n}),o&&e("p",{style:{fontSize:"13px",color:"var(--ink-2)",maxWidth:"40ch",marginBottom:t?"16px":0},children:o}),t&&e(ne,{label:t.label,variant:"primary",onClick:t.onClick})]}),ze=({checked:r,onChange:n,label:o,disabled:t})=>e("button",{type:"button",role:"switch","aria-checked":r,"aria-label":o,disabled:t,class:`relative shrink-0 ${t?"opacity-50 cursor-not-allowed":"cursor-pointer"}`,style:{width:"44px",height:"26px",borderRadius:"99px",border:0,background:r?"var(--green)":"var(--hair-2)",transition:"background .22s var(--ease)"},onClick:()=>!t&&n(!r),children:e("span",{class:"absolute pointer-events-none",style:{top:"3px",left:r?"21px":"3px",width:"20px",height:"20px",borderRadius:"50%",background:"#fff",boxShadow:"var(--shadow-s)",transition:"left .22s var(--ease)"}})}),Le=({left:r,right:n,defaultWidth:o=300,minWidth:t=200,maxWidth:a=600,storageKey:x="forge-split-width"})=>{const[s,c]=B(()=>{if(typeof localStorage<"u"&&x){const l=localStorage.getItem(x);if(l){const u=parseInt(l,10);if(!isNaN(u)&&u>=t&&u<=a)return u}}return o}),d=w(!1),i=w(0),h=w(0),p=G(l=>{l.preventDefault(),d.current=!0,i.current=l.clientX,h.current=s,document.body.style.cursor="col-resize",document.body.style.userSelect="none"},[s]);return _(()=>{const l=f=>{if(!d.current)return;const S=f.clientX-i.current,L=Math.min(a,Math.max(t,h.current+S));c(L)},u=()=>{d.current&&(d.current=!1,document.body.style.cursor="",document.body.style.userSelect="",typeof localStorage<"u"&&x&&localStorage.setItem(x,String(s)))};return document.addEventListener("mousemove",l),document.addEventListener("mouseup",u),()=>{document.removeEventListener("mousemove",l),document.removeEventListener("mouseup",u)}},[s,t,a,x]),e("div",{class:"flex h-full w-full overflow-hidden",children:[e("div",{class:"shrink-0 overflow-y-auto overflow-x-hidden",style:{width:`${s}px`},children:r}),e("div",{class:"shrink-0 w-1 cursor-col-resize transition-colors hover:bg-blue",style:{backgroundColor:"var(--hair)"},onMouseDown:p}),e("div",{class:"flex-1 min-w-0 overflow-hidden",children:n})]})},Re=({title:r,defaultOpen:n=!1,children:o})=>{const[t,a]=B(n);return e("div",{style:{borderBottom:"1px solid var(--hair)"},children:[e("button",{class:"flex items-center justify-between w-full px-3 py-2.5 cursor-pointer transition-colors text-ink3 hover:text-ink",style:{fontSize:"11px",fontWeight:600,border:0,background:"none"},onClick:()=>a(!t),children:[e("span",{children:r}),e("span",{class:"transition-transform",style:{transform:t?"rotate(90deg)":"rotate(0deg)"},children:e("span",{class:"i-lucide-chevron-right"})})]}),t&&e("div",{class:"px-3 pb-3",children:o})]})},de={normal:"--blue",warning:"--orange",critical:"--red"},pe=({bar:r,size:n})=>{const o=`var(${de[r.severity]})`,t=n==="sm",a=Math.max(0,Math.min(100,r.percent));return e("span",{class:"flex items-center w-full",style:{gap:t?"6px":"9px"},children:[e("span",{class:"mono shrink-0 text-right",style:{width:t?"28px":"32px",fontSize:t?"10px":"11.5px",color:"var(--ink-3)"},children:r.label}),e("span",{class:"relative block flex-1 overflow-hidden",style:{height:t?"4px":"6px",borderRadius:"99px",background:"var(--elev)"},children:e("span",{class:"block h-full",style:{width:`${a}%`,borderRadius:"99px",background:o,transition:"width .6s var(--ease)"}})}),e("span",{class:"mono shrink-0 text-right",style:{width:t?"30px":"36px",fontSize:t?"10px":"11.5px",fontWeight:600,color:r.severity==="normal"?"var(--ink-2)":o},children:[Math.round(r.percent),"%"]}),!t&&r.reset&&e("span",{class:"shrink-0 whitespace-nowrap",style:{fontSize:"11px",color:"var(--ink-3)"},children:r.reset})]})},Te=({bars:r,size:n="md"})=>e("span",{class:"flex flex-col w-full",style:{gap:n==="sm"?"4px":"6px"},children:r.map((o,t)=>e("span",{class:"flex flex-col w-full",style:{gap:"2px"},children:[e(pe,{bar:o,size:n}),o.scope&&n==="md"&&e("span",{style:{paddingLeft:"39px",fontSize:"10.5px",color:"var(--ink-3)"},children:o.scope})]},t))});export{Re as AccordionSection,ne as ActionButton,le as Badge,Z as CloseButton,Ee as DataList,ke as Drawer,We as EmptyState,be as ForgeTerminal,we as Modal,Le as SplitPane,ge as StatusCard,Se as Tabs,ye as ToastContainer,ze as ToggleSwitch,Te as UsageMeter,me as showToast,A as toasts};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{Component as p,options as s,createElement as f,Fragment as m,toChildArray as c,createRef as Q,createContext as ee,cloneElement as te,render as h,hydrate as ne}from"./preact.js";import{useState as S,useRef as L,useReducer as M,useMemo as T,useLayoutEffect as y,useImperativeHandle as V,useId as A,useEffect as x,useDebugValue as F,useContext as W,useCallback as H}from"./preact-hooks.js";import{useErrorBoundary as Me}from"./preact-hooks.js";function z(e,t){for(var n in t)e[n]=t[n];return e}function R(e,t){for(var n in e)if(n!=="__source"&&!(n in t))return!0;for(var r in t)if(r!=="__source"&&e[r]!==t[r])return!0;return!1}function B(e,t){var n=t(),r=S({t:{__:n,u:t}}),o=r[0].t,u=r[1];return y(function(){o.__=n,o.u=t,C(o)&&u({t:o})},[e,n,t]),x(function(){return C(o)&&u({t:o}),e(function(){C(o)&&u({t:o})})},[e]),n}function C(e){try{return!((t=e.__)===(n=e.u())&&(t!==0||1/t==1/n)||t!=t&&n!=n)}catch{return!0}var t,n}function j(e){e()}function Y(e){return e}function Z(){return[!1,j]}var q=y;function g(e,t){this.props=e,this.context=t}function re(e,t){function n(o){var u=this.props.ref;return u!=o.ref&&u&&(typeof u=="function"?u(null):u.current=null),t?!t(this.props,o)||u!=o.ref:R(this.props,o)}function r(o){return this.shouldComponentUpdate=n,f(e,o)}return r.displayName="Memo("+(e.displayName||e.name)+")",r.__f=r.prototype.isReactComponent=!0,r.type=e,r}(g.prototype=new p).isPureReactComponent=!0,g.prototype.shouldComponentUpdate=function(e,t){return R(this.props,e)||R(this.state,t)};var k=s.__b;s.__b=function(e){e.type&&e.type.__f&&e.ref&&(e.props.ref=e.ref,e.ref=null),k&&k(e)};var oe=typeof Symbol<"u"&&Symbol.for&&Symbol.for("react.forward_ref")||3911;function ue(e){function t(n){var r=z({},n);return delete r.ref,e(r,n.ref||null)}return t.$$typeof=oe,t.render=e,t.prototype.isReactComponent=t.__f=!0,t.displayName="ForwardRef("+(e.displayName||e.name)+")",t}var O=function(e,t){return e==null?null:c(c(e).map(t))},ae={map:O,forEach:O,count:function(e){return e?c(e).length:0},only:function(e){var t=c(e);if(t.length!==1)throw"Children.only";return t[0]},toArray:c},se=s.__e;s.__e=function(e,t,n,r){if(e.then){for(var o,u=t;u=u.__;)if((o=u.__c)&&o.__c)return t.__e==null&&(t.__e=n.__e,t.__k=n.__k),o.__c(e,t)}se(e,t,n,r)};var P=s.unmount;function X(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=z({},e)).__c!=null&&(e.__c.__P===n&&(e.__c.__P=t),e.__c.__e=!0,e.__c=null),e.__k=e.__k&&e.__k.map(function(r){return X(r,t,n)})),e}function G(e,t,n){return e&&n&&(e.__v=null,e.__k=e.__k&&e.__k.map(function(r){return G(r,t,n)}),e.__c&&e.__c.__P===t&&(e.__e&&n.appendChild(e.__e),e.__c.__e=!0,e.__c.__P=n)),e}function v(){this.__u=0,this.o=null,this.__b=null}function J(e){var t=e.__&&e.__.__c;return t&&t.__a&&t.__a(e)}function le(e){var t,n,r,o=null;function u(a){if(t||(t=e()).then(function(l){l&&(o=l.default||l),r=!0},function(l){n=l,r=!0}),n)throw n;if(!r)throw t;return o?f(o,a):null}return u.displayName="Lazy",u.__f=!0,u}function d(){this.i=null,this.l=null}s.unmount=function(e){var t=e.__c;t&&(t.__z=!0),t&&t.__R&&t.__R(),t&&32&e.__u&&(e.type=null),P&&P(e)},(v.prototype=new p).__c=function(e,t){var n=t.__c,r=this;r.o==null&&(r.o=[]),r.o.push(n);var o=J(r.__v),u=!1,a=function(){u||r.__z||(u=!0,n.__R=null,o?o(_):_())};n.__R=a;var l=n.__P;n.__P=null;var _=function(){if(!--r.__u){if(r.state.__a){var i=r.state.__a;r.__v.__k[0]=G(i,i.__c.__P,i.__c.__O)}var E;for(r.setState({__a:r.__b=null});E=r.o.pop();)E.__P=l,E.forceUpdate()}};r.__u++||32&t.__u||r.setState({__a:r.__b=r.__v.__k[0]}),e.then(a,a)},v.prototype.componentWillUnmount=function(){this.o=[]},v.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]=X(this.__b,n,r.__O=r.__P)}this.__b=null}var o=t.__a&&f(m,null,e.fallback);return o&&(o.__u&=-33),[f(m,null,t.__a?null:e.children),o]};var $=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 _e(e){return this.getChildContext=function(){return e.context},e.children}function ie(e){var t=this,n=e.h;if(t.componentWillUnmount=function(){h(null,t.v),t.v=null,t.h=null},t.h&&t.h!==n&&t.componentWillUnmount(),!t.v){for(var r=t.__v;r!==null&&!r.__m&&r.__!==null;)r=r.__;t.h=n,t.v={nodeType:1,parentNode:n,childNodes:[],__k:{__m:r.__m},contains:function(){return!0},namespaceURI:n.namespaceURI,insertBefore:function(o,u){this.childNodes.push(o),t.h.insertBefore(o,u)},removeChild:function(o){this.childNodes.splice(this.childNodes.indexOf(o)>>>1,1),t.h.removeChild(o)}}}h(f(_e,{context:t.context},e.__v),t.v)}function ce(e,t){var n=f(ie,{__v:e,h:t});return n.containerInfo=t,n}(d.prototype=new p).__a=function(e){var t=this,n=J(t.__v),r=t.l.get(e);return r[0]++,function(o){var u=function(){t.props.revealOrder?(r.push(o),$(t,e,r)):o()};n?n(u):u()}},d.prototype.render=function(e){this.i=null,this.l=new Map;var t=c(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},d.prototype.componentDidUpdate=d.prototype.componentDidMount=function(){var e=this;this.l.forEach(function(t,n){$(e,n,t)})};var K=typeof Symbol<"u"&&Symbol.for&&Symbol.for("react.element")||60103,fe=/^(?: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]/,pe=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,de=/[A-Z0-9]/g,me=typeof document<"u",ve=function(e){return(typeof Symbol<"u"&&typeof Symbol()=="symbol"?/fil|che|rad/:/fil|che|ra/).test(e)};function he(e,t,n){return t.__k==null&&(t.textContent=""),h(e,t),typeof n=="function"&&n(),e?e.__c:null}function ye(e,t,n){return ne(e,t),typeof n=="function"&&n(),e?e.__c:null}p.prototype.isReactComponent=!0,["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(e){Object.defineProperty(p.prototype,e,{configurable:!0,get:function(){return this["UNSAFE_"+e]},set:function(t){Object.defineProperty(this,e,{configurable:!0,writable:!0,value:t})}})});var I=s.event;s.event=function(e){return I&&(e=I(e)),e.persist=function(){},e.isPropagationStopped=function(){return this.cancelBubble},e.isDefaultPrevented=function(){return this.defaultPrevented},e.nativeEvent=e};var N,be={configurable:!0,get:function(){return this.class}},U=s.vnode;s.vnode=function(e){typeof e.type=="string"&&(function(t){var n=t.props,r=t.type,o={},u=r.indexOf("-")==-1;for(var a in n){var l=n[a];if(!(a==="value"&&"defaultValue"in n&&l==null||me&&a==="children"&&r==="noscript"||a==="class"||a==="className")){var _=a.toLowerCase();a==="defaultValue"&&"value"in n&&n.value==null?a="value":a==="download"&&l===!0?l="":_==="translate"&&l==="no"?l=!1:_[0]==="o"&&_[1]==="n"?_==="ondoubleclick"?a="ondblclick":_!=="onchange"||r!=="input"&&r!=="textarea"||ve(n.type)?_==="onfocus"?a="onfocusin":_==="onblur"?a="onfocusout":pe.test(a)&&(a=_):_=a="oninput":u&&fe.test(a)?a=a.replace(de,"-$&").toLowerCase():l===null&&(l=void 0),_==="oninput"&&o[a=_]&&(a="oninputCapture"),o[a]=l}}r=="select"&&(o.multiple&&Array.isArray(o.value)&&(o.value=c(n.children).forEach(function(i){i.props.selected=o.value.indexOf(i.props.value)!=-1})),o.defaultValue!=null&&(o.value=c(n.children).forEach(function(i){i.props.selected=o.multiple?o.defaultValue.indexOf(i.props.value)!=-1:o.defaultValue==i.props.value}))),n.class&&!n.className?(o.class=n.class,Object.defineProperty(o,"className",be)):n.className&&(o.class=o.className=n.className),t.props=o})(e),e.$$typeof=K,U&&U(e)};var w=s.__r;s.__r=function(e){w&&w(e),N=e.__c};var D=s.diffed;s.diffed=function(e){D&&D(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),N=null};var Ee={ReactCurrentDispatcher:{current:{readContext:function(e){return N.__n[e.__c].props.value},useCallback:H,useContext:W,useDebugValue:F,useDeferredValue:Y,useEffect:x,useId:A,useImperativeHandle:V,useInsertionEffect:q,useLayoutEffect:y,useMemo:T,useReducer:M,useRef:L,useState:S,useSyncExternalStore:B,useTransition:Z}}},Ue="18.3.1";function Ce(e){return f.bind(null,e)}function b(e){return!!e&&e.$$typeof===K}function Re(e){return b(e)&&e.type===m}function ge(e){return!!e&&typeof e.displayName=="string"&&e.displayName.indexOf("Memo(")==0}function Se(e){return b(e)?te.apply(null,arguments):e}function xe(e){return!!e.__k&&(h(null,e),!0)}function Ne(e){return e&&(e.base||e.nodeType===1&&e)||null}var ke=function(e,t){return e(t)},Oe=function(e,t){var n=s.debounceRendering;s.debounceRendering=function(o){return o()};var r=e(t);return s.debounceRendering=n,r},Pe=b,we={useState:S,useId:A,useReducer:M,useEffect:x,useLayoutEffect:y,useInsertionEffect:q,useTransition:Z,useDeferredValue:Y,useSyncExternalStore:B,startTransition:j,useRef:L,useImperativeHandle:V,useMemo:T,useCallback:H,useContext:W,useDebugValue:F,version:"18.3.1",Children:ae,render:he,hydrate:ye,unmountComponentAtNode:xe,createPortal:ce,createElement:f,createContext:ee,createFactory:Ce,cloneElement:Se,createRef:Q,Fragment:m,isValidElement:b,isElement:Pe,isFragment:Re,isMemo:ge,findDOMNode:Ne,Component:p,PureComponent:g,memo:re,forwardRef:ue,flushSync:Oe,unstable_batchedUpdates:ke,StrictMode:m,Suspense:v,SuspenseList:d,lazy:le,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:Ee};export{ae as Children,p as Component,m as Fragment,g as PureComponent,m as StrictMode,v as Suspense,d as SuspenseList,Ee as __SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,Se as cloneElement,ee as createContext,f as createElement,Ce as createFactory,ce as createPortal,Q as createRef,we as default,Ne as findDOMNode,Oe as flushSync,ue as forwardRef,ye as hydrate,Pe as isElement,Re as isFragment,ge as isMemo,b as isValidElement,le as lazy,re as memo,he as render,j as startTransition,xe as unmountComponentAtNode,ke as unstable_batchedUpdates,H as useCallback,W as useContext,F as useDebugValue,Y as useDeferredValue,x as useEffect,Me as useErrorBoundary,A as useId,V as useImperativeHandle,q as useInsertionEffect,y as useLayoutEffect,T as useMemo,M as useReducer,L as useRef,S as useState,B as useSyncExternalStore,Z as useTransition,Ue as version};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{options as V}from"./preact.js";var c,e,d,g,v=0,T=[],o=V,C=o.__b,A=o.__r,D=o.diffed,F=o.__c,k=o.unmount,q=o.__;function m(t,_){o.__h&&o.__h(e,t,v||_),v=0;var u=e.__H||(e.__H={__:[],__h:[]});return t>=u.__.length&&u.__.push({}),u.__[t]}function B(t){return v=1,I(E,t)}function I(t,_,u){var n=m(c++,2);if(n.t=t,!n.__c&&(n.__=[u?u(_):E(void 0,_),function(f){var a=n.__N?n.__N[0]:n.__[0],s=n.t(a,f);a!==s&&(n.__N=[s,n.__[1]],n.__c.setState({}))}],n.__c=e,!e.__f)){var i=function(f,a,s){if(!n.__c.__H)return!0;var h=n.__c.__H.__.filter(function(r){return r.__c});if(h.every(function(r){return!r.__N}))return!l||l.call(this,f,a,s);var b=n.__c.props!==f;return h.some(function(r){if(r.__N){var P=r.__[0];r.__=r.__N,r.__N=void 0,P!==r.__[0]&&(b=!0)}}),l&&l.call(this,f,a,s)||b};e.__f=!0;var l=e.shouldComponentUpdate,N=e.componentWillUpdate;e.componentWillUpdate=function(f,a,s){if(this.__e){var h=l;l=void 0,i(f,a,s),l=h}N&&N.call(this,f,a,s)},e.shouldComponentUpdate=i}return n.__N||n.__}function w(t,_){var u=m(c++,3);!o.__s&&y(u.__H,_)&&(u.__=t,u.u=_,e.__H.__h.push(u))}function R(t,_){var u=m(c++,4);!o.__s&&y(u.__H,_)&&(u.__=t,u.u=_,e.__h.push(u))}function z(t){return v=5,U(function(){return{current:t}},[])}function L(t,_,u){v=6,R(function(){if(typeof t=="function"){var n=t(_());return function(){t(null),n&&typeof n=="function"&&n()}}if(t)return t.current=_(),function(){return t.current=null}},u==null?u:u.concat(t))}function U(t,_){var u=m(c++,7);return y(u.__H,_)&&(u.__=t(),u.__H=_,u.__h=t),u.__}function M(t,_){return v=8,U(function(){return t},_)}function $(t){var _=e.context[t.__c],u=m(c++,9);return u.c=t,_?(u.__==null&&(u.__=!0,_.sub(e)),_.props.value):t.__}function G(t,_){o.useDebugValue&&o.useDebugValue(_?_(t):t)}function J(t){var _=m(c++,10),u=B();return _.__=t,e.componentDidCatch||(e.componentDidCatch=function(n,i){_.__&&_.__(n,i),u[1](n)}),[u[0],function(){u[1](void 0)}]}function K(){var t=m(c++,11);if(!t.__){for(var _=e.__v;_!==null&&!_.__m&&_.__!==null;)_=_.__;var u=_.__m||(_.__m=[0,0]);t.__="P"+u[0]+"-"+u[1]++}return t.__}function S(){for(var t;t=T.shift();){var _=t.__H;if(t.__P&&_)try{_.__h.some(p),_.__h.some(H),_.__h=[]}catch(u){_.__h=[],o.__e(u,t.__v)}}}o.__b=function(t){e=null,C&&C(t)},o.__=function(t,_){t&&_.__k&&_.__k.__m&&(t.__m=_.__k.__m),q&&q(t,_)},o.__r=function(t){A&&A(t),c=0;var _=(e=t.__c).__H;_&&(d===e?(_.__h=[],e.__h=[],_.__.some(function(u){u.__N&&(u.__=u.__N),u.u=u.__N=void 0})):(_.__h.some(p),_.__h.some(H),_.__h=[],c=0)),d=e},o.diffed=function(t){D&&D(t);var _=t.__c;_&&_.__H&&(_.__H.__h.length&&(T.push(_)!==1&&g===o.requestAnimationFrame||((g=o.requestAnimationFrame)||W)(S)),_.__H.__.some(function(u){u.u&&(u.__H=u.u),u.u=void 0})),d=e=null},o.__c=function(t,_){_.some(function(u){try{u.__h.some(p),u.__h=u.__h.filter(function(n){return!n.__||H(n)})}catch(n){_.some(function(i){i.__h&&(i.__h=[])}),_=[],o.__e(n,u.__v)}}),F&&F(t,_)},o.unmount=function(t){k&&k(t);var _,u=t.__c;u&&u.__H&&(u.__H.__.some(function(n){try{p(n)}catch(i){_=i}}),u.__H=void 0,_&&o.__e(_,u.__v))};var x=typeof requestAnimationFrame=="function";function W(t){var _,u=function(){clearTimeout(n),x&&cancelAnimationFrame(_),setTimeout(t)},n=setTimeout(u,35);x&&(_=requestAnimationFrame(u))}function p(t){var _=e,u=t.__c;typeof u=="function"&&(t.__c=void 0,u()),e=_}function H(t){var _=e;t.__c=t.__(),e=_}function y(t,_){return!t||t.length!==_.length||_.some(function(u,n){return u!==t[n]})}function E(t,_){return typeof _=="function"?_(t):_}export{M as useCallback,$ as useContext,G as useDebugValue,w as useEffect,J as useErrorBoundary,K as useId,L as useImperativeHandle,R as useLayoutEffect,U as useMemo,I as useReducer,z as useRef,B as useState};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{options as u,Fragment as v}from"./preact.js";var _=/["&<]/;function l(e){if(e.length===0||_.test(e)===!1)return e;for(var t=0,r=0,f="",n="";r<e.length;r++){switch(e.charCodeAt(r)){case 34:n=""";break;case 38:n="&";break;case 60:n="<";break;default:continue}r!==t&&(f+=e.slice(t,r)),f+=n,t=r+1}return r!==t&&(f+=e.slice(t,r)),f}var y=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,b=0,d=Array.isArray;function g(e,t,r,f,n,i){t||(t={});var s,o,a=t;if("ref"in a)for(o in a={},t)o=="ref"?s=t[o]:a[o]=t[o];var c={type:e,props:a,key:r,ref:s,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:--b,__i:-1,__u:0,__source:n,__self:i};if(typeof e=="function"&&(s=e.defaultProps))for(o in s)a[o]===void 0&&(a[o]=s[o]);return u.vnode&&u.vnode(c),c}function h(e){var t=g(v,{tpl:e,exprs:[].slice.call(arguments,1)});return t.key=t.__v,t}var p={},j=/[A-Z]/g;function k(e,t){if(u.attr){var r=u.attr(e,t);if(typeof r=="string")return r}if(t=(function(a){return a!==null&&typeof a=="object"&&typeof a.valueOf=="function"?a.valueOf():a})(t),e==="ref"||e==="key")return"";if(e==="style"&&typeof t=="object"){var f="";for(var n in t){var i=t[n];if(i!=null&&i!==""){var s=n[0]=="-"?n:p[n]||(p[n]=n.replace(j,"-$&").toLowerCase()),o=";";typeof i!="number"||s.startsWith("--")||y.test(s)||(o="px;"),f=f+s+":"+i+o}}return e+'="'+l(f)+'"'}return t==null||t===!1||typeof t=="function"||typeof t=="object"?"":t===!0?e:e+'="'+l(""+t)+'"'}function x(e){if(e==null||typeof e=="boolean"||typeof e=="function")return null;if(typeof e=="object"){if(e.constructor===void 0)return e;if(d(e)){for(var t=0;t<e.length;t++)e[t]=x(e[t]);return e}}return l(""+e)}export{v as Fragment,g as jsx,k as jsxAttr,g as jsxDEV,x as jsxEscape,h as jsxTemplate,g as jsxs};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{Component as X,options as g,Fragment as Y,isValidElement as ii}from"./preact.js";import{useRef as P,useMemo as E,useEffect as R}from"./preact-hooks.js";var ti=Symbol.for("preact-signals");function U(){if(l>1)l--;else{var t,i=!1;for((function(){var e=A;for(A=void 0;e!==void 0;)e.S.v===e.v&&(e.S.i=e.i),e=e.o})();$!==void 0;){var n=$;for($=void 0,x++;n!==void 0;){var r=n.u;if(n.u=void 0,n.f&=-3,!(8&n.f)&&Z(n))try{n.c()}catch(e){i||(t=e,i=!0)}n=r}}if(x=0,l--,i)throw t}}function F(t){if(l>0)return t();O=++ni,l++;try{return t()}finally{U()}}var o=void 0;function T(t){var i=o;o=void 0;try{return t()}finally{o=i}}var h,$=void 0,l=0,x=0,ni=0,O=0,A=void 0,N=0;function V(t){if(o!==void 0){var i=t.n;if(i===void 0||i.t!==o)return i={i:0,S:t,p:o.s,n:void 0,t:o,e:void 0,x:void 0,r:i},o.s!==void 0&&(o.s.n=i),o.s=i,t.n=i,32&o.f&&t.S(i),i;if(i.i===-1)return i.i=0,i.n!==void 0&&(i.n.p=i.p,i.p!==void 0&&(i.p.n=i.n),i.p=o.s,i.n=void 0,o.s.n=i,o.s=i),i}}function a(t,i){this.v=t,this.i=0,this.n=void 0,this.t=void 0,this.l=0,this.W=i==null?void 0:i.watched,this.Z=i==null?void 0:i.unwatched,this.name=i==null?void 0:i.name}a.prototype.brand=ti;a.prototype.h=function(){return!0};a.prototype.S=function(t){var i=this,n=this.t;n!==t&&t.e===void 0&&(t.x=n,this.t=t,n!==void 0?n.e=t:T(function(){var r;(r=i.W)==null||r.call(i)}))};a.prototype.U=function(t){var i=this;if(this.t!==void 0){var n=t.e,r=t.x;n!==void 0&&(n.x=r,t.e=void 0),r!==void 0&&(r.e=n,t.x=void 0),t===this.t&&(this.t=r,r===void 0&&T(function(){var e;(e=i.Z)==null||e.call(i)}))}};a.prototype.subscribe=function(t){var i=this;return _(function(){var n=i.value,r=o;o=void 0;try{t(n)}finally{o=r}},{name:"sub"})};a.prototype.valueOf=function(){return this.value};a.prototype.toString=function(){return this.value+""};a.prototype.toJSON=function(){return this.value};a.prototype.peek=function(){var t=this;return T(function(){return t.value})};Object.defineProperty(a.prototype,"value",{get:function(){var t=V(this);return t!==void 0&&(t.i=this.i),this.v},set:function(t){if(t!==this.v){if(x>100)throw new Error("Cycle detected");(function(n){l!==0&&x===0&&n.l!==O&&(n.l=O,A={S:n,v:n.v,i:n.i,o:A})})(this),this.v=t,this.i++,N++,l++;try{for(var i=this.t;i!==void 0;i=i.x)i.t.N()}finally{U()}}}});function W(t,i){return new a(t,i)}function Z(t){for(var i=t.s;i!==void 0;i=i.n)if(i.S.i!==i.i||!i.S.h()||i.S.i!==i.i)return!0;return!1}function G(t){for(var i=t.s;i!==void 0;i=i.n){var n=i.S.n;if(n!==void 0&&(i.r=n),i.S.n=i,i.i=-1,i.n===void 0){t.s=i;break}}}function L(t){for(var i=t.s,n=void 0;i!==void 0;){var r=i.p;i.i===-1?(i.S.U(i),r!==void 0&&(r.n=i.n),i.n!==void 0&&(i.n.p=r)):n=i,i.S.n=i.r,i.r!==void 0&&(i.r=void 0),i=r}t.s=n}function d(t,i){a.call(this,void 0),this.x=t,this.s=void 0,this.g=N-1,this.f=4,this.W=i==null?void 0:i.watched,this.Z=i==null?void 0:i.unwatched,this.name=i==null?void 0:i.name}d.prototype=new a;d.prototype.h=function(){if(this.f&=-3,1&this.f)return!1;if((36&this.f)==32||(this.f&=-5,this.g===N))return!0;if(this.g=N,this.f|=1,this.i>0&&!Z(this))return this.f&=-2,!0;var t=o;try{G(this),o=this;var i=this.x();(16&this.f||this.v!==i||this.i===0)&&(this.v=i,this.f&=-17,this.i++)}catch(n){this.v=n,this.f|=16,this.i++}return o=t,L(this),this.f&=-2,!0};d.prototype.S=function(t){if(this.t===void 0){this.f|=36;for(var i=this.s;i!==void 0;i=i.n)i.S.S(i)}a.prototype.S.call(this,t)};d.prototype.U=function(t){if(this.t!==void 0&&(a.prototype.U.call(this,t),this.t===void 0)){this.f&=-33;for(var i=this.s;i!==void 0;i=i.n)i.S.U(i)}};d.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(d.prototype,"value",{get:function(){if(1&this.f)throw new Error("Cycle detected");var t=V(this);if(this.h(),t!==void 0&&(t.i=this.i),16&this.f)throw this.v;return this.v}});function q(t,i){return new d(t,i)}function D(t){var i=t.m;if(t.m=void 0,typeof i=="function"){l++;var n=o;o=void 0;try{i()}catch(r){throw t.f&=-2,t.f|=8,M(t),r}finally{o=n,U()}}}function M(t){for(var i=t.s;i!==void 0;i=i.n)i.S.U(i);t.x=void 0,t.s=void 0,D(t)}function ri(t){if(o!==this)throw new Error("Out-of-order effect");L(this),o=t,this.f&=-2,8&this.f&&M(this),U()}function p(t,i){this.x=t,this.m=void 0,this.s=void 0,this.u=void 0,this.f=32,this.name=i==null?void 0:i.name,h&&h.push(this)}p.prototype.c=function(){var t=this.S();try{if(8&this.f||this.x===void 0)return;var i=this.x();typeof i=="function"&&(this.m=i)}finally{t()}};p.prototype.S=function(){if(1&this.f)throw new Error("Cycle detected");this.f|=1,this.f&=-9,D(this),G(this),l++;var t=o;return o=this,ri.bind(this,t)};p.prototype.N=function(){2&this.f||(this.f|=2,this.u=$,$=this)};p.prototype.d=function(){this.f|=8,1&this.f||M(this)};p.prototype.dispose=function(){this.d()};function _(t,i){var n=new p(t,i);try{n.c()}catch(e){throw n.d(),e}var r=n.d.bind(n);return r[Symbol.dispose]=r,r}function I(t){return function(){var i=arguments,n=this;return F(function(){return T(function(){return t.apply(n,[].slice.call(i))})})}}function ei(){var t=h;return h=[],function(){var i=h;return h&&t&&(t=t.concat(h)),h=t,i}}var J=function(t){for(var i in t){var n=t[i];typeof n=="function"?t[i]=I(n):typeof n=="object"&&n!==null&&!("brand"in n)&&J(n)}};function pi(t){return function(){var i,n,r=ei();try{n=t.apply(void 0,[].slice.call(arguments))}catch(e){throw h=void 0,e}finally{i=r()}return J(n),n[Symbol.dispose]=I(function(){if(i)for(var e=0;e<i.length;e++)i[e].dispose();i=void 0}),n}}var j,C,b,oi=typeof window<"u"&&!!window.__PREACT_SIGNALS_DEVTOOLS__,z=[],B=[];_(function(){j=this.N})();function y(t,i){g[t]=i.bind(null,g[t]||function(){})}function k(t){if(b){var i=b;b=void 0,i()}b=t&&t.S()}function H(t){var i=this,n=t.data,r=ui(n);r.value=n;var e=E(function(){for(var s=i,v=i.__v;v=v.__;)if(v.__c){v.__c.__$f|=4;break}var c=q(function(){var S=r.value.value;return S===0?0:S===!0?"":S||""}),m=q(function(){return!Array.isArray(c.value)&&!ii(c.value)}),w=_(function(){if(this.N=K,m.value){var S=c.value;s.__v&&s.__v.__e&&s.__v.__e.nodeType===3&&(s.__v.__e.data=S)}}),Q=i.__$u.d;return i.__$u.d=function(){w(),Q.call(this)},[m,c]},[]),f=e[0],u=e[1];return f.value?u.peek():u.value}H.displayName="ReactiveTextNode";Object.defineProperties(a.prototype,{constructor:{configurable:!0,value:void 0},type:{configurable:!0,value:H},props:{configurable:!0,get:function(){var t=this;return{data:{get value(){return t.value}}}}},__b:{configurable:!0,value:1}});y("__b",function(t,i){if(typeof i.type=="string"){var n,r=i.props;for(var e in r)if(e!=="children"){var f=r[e];f instanceof a&&(n||(i.__np=n={}),n[e]=f,r[e]=f.peek())}}t(i)});y("__r",function(t,i){if(t(i),i.type!==Y){k();var n,r=i.__c;r&&(r.__$f&=-2,(n=r.__$u)===void 0&&(r.__$u=n=(function(e,f){var u;return _(function(){u=this},{name:f}),u.c=e,u})(function(){var e;oi&&((e=n.y)==null||e.call(n)),r.__$f|=1,r.setState({})},typeof i.type=="function"?i.type.displayName||i.type.name:""))),C=r,k(n)}});y("__e",function(t,i,n,r){k(),C=void 0,t(i,n,r)});y("diffed",function(t,i){k(),C=void 0;var n;if(typeof i.type=="string"&&(n=i.__e)){var r=i.__np,e=i.props;if(r){var f=n.U;if(f)for(var u in f){var s=f[u];s!==void 0&&!(u in r)&&(s.d(),f[u]=void 0)}else f={},n.U=f;for(var v in r){var c=f[v],m=r[v];c===void 0?(c=fi(n,v,m),f[v]=c):c.o(m,e)}for(var w in r)e[w]=r[w]}}t(i)});function fi(t,i,n,r){var e=i in t&&t.ownerSVGElement===void 0,f=W(n),u=n.peek();return{o:function(s,v){f.value=s,u=s.peek()},d:_(function(){this.N=K;var s=f.value.value;u!==s?(u=void 0,e?t[i]=s:s!=null&&(s!==!1||i[4]==="-")?t.setAttribute(i,s):t.removeAttribute(i)):u=void 0})}}y("unmount",function(t,i){if(typeof i.type=="string"){var n=i.__e;if(n){var r=n.U;if(r){n.U=void 0;for(var e in r){var f=r[e];f&&f.d()}}}i.__np=void 0}else{var u=i.__c;if(u){var s=u.__$u;s&&(u.__$u=void 0,s.d())}}t(i)});y("__h",function(t,i,n,r){(r<3||r===9)&&(i.__$f|=2),t(i,n,r)});X.prototype.shouldComponentUpdate=function(t,i){if(this.__R)return!0;var n=this.__$u,r=n&&n.s!==void 0;for(var e in i)return!0;if(this.__f||typeof this.u=="boolean"&&this.u===!0){var f=2&this.__$f;if(!(r||f||4&this.__$f)||1&this.__$f)return!0}else if(!(r||4&this.__$f)||3&this.__$f)return!0;for(var u in t)if(u!=="__source"&&t[u]!==this.props[u])return!0;for(var s in this.props)if(!(s in t))return!0;return!1};function ui(t,i){return E(function(){return W(t,i)},[])}function _i(t,i){var n=P(t);return n.current=t,C.__$f|=4,E(function(){return q(function(){return n.current()},i)},[])}var si=typeof requestAnimationFrame>"u"?setTimeout:function(t){var i=function(){clearTimeout(n),cancelAnimationFrame(r),t()},n=setTimeout(i,35),r=requestAnimationFrame(i)},ai=function(t){queueMicrotask(function(){queueMicrotask(t)})};function vi(){F(function(){for(var t;t=z.shift();)j.call(t)})}function ci(){z.push(this)===1&&(g.requestAnimationFrame||si)(vi)}function hi(){F(function(){for(var t;t=B.shift();)j.call(t)})}function K(){B.push(this)===1&&(g.requestAnimationFrame||ai)(hi)}function yi(t,i){var n=P(t);n.current=t,R(function(){return _(function(){return this.N=ci,n.current()},i)},[])}function mi(t){var i=E(function(){return t()},[]);return R(function(){return i[Symbol.dispose]},[i]),i}export{a as Signal,I as action,F as batch,q as computed,pi as createModel,_ as effect,W as signal,T as untracked,_i as useComputed,mi as useModel,ui as useSignal,yi as useSignalEffect};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var E,v,ee,pe,x,X,_e,te,B,F,T,ne,q,O,j,re,N={},H=[],fe=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,D=Array.isArray;function b(_,e){for(var t in e)_[t]=e[t];return _}function G(_){_&&_.parentNode&&_.parentNode.removeChild(_)}function ae(_,e,t){var o,l,n,i={};for(n in e)n=="key"?o=e[n]:n=="ref"?l=e[n]:i[n]=e[n];if(arguments.length>2&&(i.children=arguments.length>3?E.call(arguments,2):t),typeof _=="function"&&_.defaultProps!=null)for(n in _.defaultProps)i[n]===void 0&&(i[n]=_.defaultProps[n]);return M(_,i,o,l,null)}function M(_,e,t,o,l){var n={type:_,props:e,key:t,ref:o,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:l??++ee,__i:-1,__u:0};return l==null&&v.vnode!=null&&v.vnode(n),n}function we(){return{current:null}}function R(_){return _.children}function L(_,e){this.props=_,this.context=e}function S(_,e){if(e==null)return _.__?S(_.__,_.__i+1):null;for(var t;e<_.__k.length;e++)if((t=_.__k[e])!=null&&t.__e!=null)return t.__e;return typeof _.type=="function"?S(_):null}function he(_){if(_.__P&&_.__d){var e=_.__v,t=e.__e,o=[],l=[],n=b({},e);n.__v=e.__v+1,v.vnode&&v.vnode(n),J(_.__P,n,e,_.__n,_.__P.namespaceURI,32&e.__u?[t]:null,o,t??S(e),!!(32&e.__u),l),n.__v=e.__v,n.__.__k[n.__i]=n,se(o,n,l),e.__e=e.__=null,n.__e!=t&&oe(n)}}function oe(_){if((_=_.__)!=null&&_.__c!=null)return _.__e=_.__c.base=null,_.__k.some(function(e){if(e!=null&&e.__e!=null)return _.__e=_.__c.base=e.__e}),oe(_)}function V(_){(!_.__d&&(_.__d=!0)&&x.push(_)&&!I.__r++||X!=v.debounceRendering)&&((X=v.debounceRendering)||_e)(I)}function I(){try{for(var _,e=1;x.length;)x.length>e&&x.sort(te),_=x.shift(),e=x.length,he(_)}finally{x.length=I.__r=0}}function le(_,e,t,o,l,n,i,u,f,s,p){var r,d,c,y,g,m,a,h=o&&o.__k||H,w=e.length;for(f=de(t,e,h,f,w),r=0;r<w;r++)(c=t.__k[r])!=null&&(d=c.__i!=-1&&h[c.__i]||N,c.__i=r,m=J(_,c,d,l,n,i,u,f,s,p),y=c.__e,c.ref&&d.ref!=c.ref&&(d.ref&&K(d.ref,null,c),p.push(c.ref,c.__c||y,c)),g==null&&y!=null&&(g=y),(a=!!(4&c.__u))||d.__k===c.__k?(f=ie(c,f,_,a),a&&d.__e&&(d.__e=null)):typeof c.type=="function"&&m!==void 0?f=m:y&&(f=y.nextSibling),c.__u&=-7);return t.__e=g,f}function de(_,e,t,o,l){var n,i,u,f,s,p=t.length,r=p,d=0;for(_.__k=new Array(l),n=0;n<l;n++)(i=e[n])!=null&&typeof i!="boolean"&&typeof i!="function"?(typeof i=="string"||typeof i=="number"||typeof i=="bigint"||i.constructor==String?i=_.__k[n]=M(null,i,null,null,null):D(i)?i=_.__k[n]=M(R,{children:i},null,null,null):i.constructor===void 0&&i.__b>0?i=_.__k[n]=M(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):_.__k[n]=i,f=n+d,i.__=_,i.__b=_.__b+1,u=null,(s=i.__i=ye(i,t,f,r))!=-1&&(r--,(u=t[s])&&(u.__u|=2)),u==null||u.__v==null?(s==-1&&(l>p?d--:l<p&&d++),typeof i.type!="function"&&(i.__u|=4)):s!=f&&(s==f-1?d--:s==f+1?d++:(s>f?d--:d++,i.__u|=4))):_.__k[n]=null;if(r)for(n=0;n<p;n++)(u=t[n])!=null&&(2&u.__u)==0&&(u.__e==o&&(o=S(u)),ce(u,u));return o}function ie(_,e,t,o){var l,n;if(typeof _.type=="function"){for(l=_.__k,n=0;l&&n<l.length;n++)l[n]&&(l[n].__=_,e=ie(l[n],e,t,o));return e}_.__e!=e&&(o&&(e&&_.type&&!e.parentNode&&(e=S(_)),t.insertBefore(_.__e,e||null)),e=_.__e);do e=e&&e.nextSibling;while(e!=null&&e.nodeType==8);return e}function ve(_,e){return e=e||[],_==null||typeof _=="boolean"||(D(_)?_.some(function(t){ve(t,e)}):e.push(_)),e}function ye(_,e,t,o){var l,n,i,u=_.key,f=_.type,s=e[t],p=s!=null&&(2&s.__u)==0;if(s===null&&u==null||p&&u==s.key&&f==s.type)return t;if(o>(p?1:0)){for(l=t-1,n=t+1;l>=0||n<e.length;)if((s=e[i=l>=0?l--:n++])!=null&&(2&s.__u)==0&&u==s.key&&f==s.type)return i}return-1}function Y(_,e,t){e[0]=="-"?_.setProperty(e,t??""):_[e]=t==null?"":typeof t!="number"||fe.test(e)?t:t+"px"}function A(_,e,t,o,l){var n,i;e:if(e=="style")if(typeof t=="string")_.style.cssText=t;else{if(typeof o=="string"&&(_.style.cssText=o=""),o)for(e in o)t&&e in t||Y(_.style,e,"");if(t)for(e in t)o&&t[e]==o[e]||Y(_.style,e,t[e])}else if(e[0]=="o"&&e[1]=="n")n=e!=(e=e.replace(ne,"$1")),i=e.toLowerCase(),e=i in _||e=="onFocusOut"||e=="onFocusIn"?i.slice(2):e.slice(2),_.l||(_.l={}),_.l[e+n]=t,t?o?t[T]=o[T]:(t[T]=q,_.addEventListener(e,n?j:O,n)):_.removeEventListener(e,n?j:O,n);else{if(l=="http://www.w3.org/2000/svg")e=e.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(e!="width"&&e!="height"&&e!="href"&&e!="list"&&e!="form"&&e!="tabIndex"&&e!="download"&&e!="rowSpan"&&e!="colSpan"&&e!="role"&&e!="popover"&&e in _)try{_[e]=t??"";break e}catch{}typeof t=="function"||(t==null||t===!1&&e[4]!="-"?_.removeAttribute(e):_.setAttribute(e,e=="popover"&&t==1?"":t))}}function Z(_){return function(e){if(this.l){var t=this.l[e.type+_];if(e[F]==null)e[F]=q++;else if(e[F]<t[T])return;return t(v.event?v.event(e):e)}}}function J(_,e,t,o,l,n,i,u,f,s){var p,r,d,c,y,g,m,a,h,w,C,U,Q,W,$,k=e.type;if(e.constructor!==void 0)return null;128&t.__u&&(f=!!(32&t.__u),n=[u=e.__e=t.__e]),(p=v.__b)&&p(e);e:if(typeof k=="function")try{if(a=e.props,h=k.prototype&&k.prototype.render,w=(p=k.contextType)&&o[p.__c],C=p?w?w.props.value:p.__:o,t.__c?m=(r=e.__c=t.__c).__=r.__E:(h?e.__c=r=new k(a,C):(e.__c=r=new L(a,C),r.constructor=k,r.render=ge),w&&w.sub(r),r.state||(r.state={}),r.__n=o,d=r.__d=!0,r.__h=[],r._sb=[]),h&&r.__s==null&&(r.__s=r.state),h&&k.getDerivedStateFromProps!=null&&(r.__s==r.state&&(r.__s=b({},r.__s)),b(r.__s,k.getDerivedStateFromProps(a,r.__s))),c=r.props,y=r.state,r.__v=e,d)h&&k.getDerivedStateFromProps==null&&r.componentWillMount!=null&&r.componentWillMount(),h&&r.componentDidMount!=null&&r.__h.push(r.componentDidMount);else{if(h&&k.getDerivedStateFromProps==null&&a!==c&&r.componentWillReceiveProps!=null&&r.componentWillReceiveProps(a,C),e.__v==t.__v||!r.__e&&r.shouldComponentUpdate!=null&&r.shouldComponentUpdate(a,r.__s,C)===!1){e.__v!=t.__v&&(r.props=a,r.state=r.__s,r.__d=!1),e.__e=t.__e,e.__k=t.__k,e.__k.some(function(P){P&&(P.__=e)}),H.push.apply(r.__h,r._sb),r._sb=[],r.__h.length&&i.push(r);break e}r.componentWillUpdate!=null&&r.componentWillUpdate(a,r.__s,C),h&&r.componentDidUpdate!=null&&r.__h.push(function(){r.componentDidUpdate(c,y,g)})}if(r.context=C,r.props=a,r.__P=_,r.__e=!1,U=v.__r,Q=0,h)r.state=r.__s,r.__d=!1,U&&U(e),p=r.render(r.props,r.state,r.context),H.push.apply(r.__h,r._sb),r._sb=[];else do r.__d=!1,U&&U(e),p=r.render(r.props,r.state,r.context),r.state=r.__s;while(r.__d&&++Q<25);r.state=r.__s,r.getChildContext!=null&&(o=b(b({},o),r.getChildContext())),h&&!d&&r.getSnapshotBeforeUpdate!=null&&(g=r.getSnapshotBeforeUpdate(c,y)),W=p!=null&&p.type===R&&p.key==null?ue(p.props.children):p,u=le(_,D(W)?W:[W],e,t,o,l,n,i,u,f,s),r.base=e.__e,e.__u&=-161,r.__h.length&&i.push(r),m&&(r.__E=r.__=null)}catch(P){if(e.__v=null,f||n!=null)if(P.then){for(e.__u|=f?160:128;u&&u.nodeType==8&&u.nextSibling;)u=u.nextSibling;n[n.indexOf(u)]=null,e.__e=u}else{for($=n.length;$--;)G(n[$]);z(e)}else e.__e=t.__e,e.__k=t.__k,P.then||z(e);v.__e(P,e,t)}else n==null&&e.__v==t.__v?(e.__k=t.__k,e.__e=t.__e):u=e.__e=me(t.__e,e,t,o,l,n,i,f,s);return(p=v.diffed)&&p(e),128&e.__u?void 0:u}function z(_){_&&(_.__c&&(_.__c.__e=!0),_.__k&&_.__k.some(z))}function se(_,e,t){for(var o=0;o<t.length;o++)K(t[o],t[++o],t[++o]);v.__c&&v.__c(e,_),_.some(function(l){try{_=l.__h,l.__h=[],_.some(function(n){n.call(l)})}catch(n){v.__e(n,l.__v)}})}function ue(_){return typeof _!="object"||_==null||_.__b>0?_:D(_)?_.map(ue):b({},_)}function me(_,e,t,o,l,n,i,u,f){var s,p,r,d,c,y,g,m=t.props||N,a=e.props,h=e.type;if(h=="svg"?l="http://www.w3.org/2000/svg":h=="math"?l="http://www.w3.org/1998/Math/MathML":l||(l="http://www.w3.org/1999/xhtml"),n!=null){for(s=0;s<n.length;s++)if((c=n[s])&&"setAttribute"in c==!!h&&(h?c.localName==h:c.nodeType==3)){_=c,n[s]=null;break}}if(_==null){if(h==null)return document.createTextNode(a);_=document.createElementNS(l,h,a.is&&a),u&&(v.__m&&v.__m(e,n),u=!1),n=null}if(h==null)m===a||u&&_.data==a||(_.data=a);else{if(n=n&&E.call(_.childNodes),!u&&n!=null)for(m={},s=0;s<_.attributes.length;s++)m[(c=_.attributes[s]).name]=c.value;for(s in m)c=m[s],s=="dangerouslySetInnerHTML"?r=c:s=="children"||s in a||s=="value"&&"defaultValue"in a||s=="checked"&&"defaultChecked"in a||A(_,s,null,c,l);for(s in a)c=a[s],s=="children"?d=c:s=="dangerouslySetInnerHTML"?p=c:s=="value"?y=c:s=="checked"?g=c:u&&typeof c!="function"||m[s]===c||A(_,s,c,m[s],l);if(p)u||r&&(p.__html==r.__html||p.__html==_.innerHTML)||(_.innerHTML=p.__html),e.__k=[];else if(r&&(_.innerHTML=""),le(e.type=="template"?_.content:_,D(d)?d:[d],e,t,o,h=="foreignObject"?"http://www.w3.org/1999/xhtml":l,n,i,n?n[0]:t.__k&&S(t,0),u,f),n!=null)for(s=n.length;s--;)G(n[s]);u||(s="value",h=="progress"&&y==null?_.removeAttribute("value"):y!=null&&(y!==_[s]||h=="progress"&&!y||h=="option"&&y!=m[s])&&A(_,s,y,m[s],l),s="checked",g!=null&&g!=_[s]&&A(_,s,g,m[s],l))}return _}function K(_,e,t){try{if(typeof _=="function"){var o=typeof _.__u=="function";o&&_.__u(),o&&e==null||(_.__u=_(e))}else _.current=e}catch(l){v.__e(l,t)}}function ce(_,e,t){var o,l;if(v.unmount&&v.unmount(_),(o=_.ref)&&(o.current&&o.current!=_.__e||K(o,null,e)),(o=_.__c)!=null){if(o.componentWillUnmount)try{o.componentWillUnmount()}catch(n){v.__e(n,e)}o.base=o.__P=null}if(o=_.__k)for(l=0;l<o.length;l++)o[l]&&ce(o[l],e,t||typeof _.type!="function");t||G(_.__e),_.__c=_.__=_.__e=void 0}function ge(_,e,t){return this.constructor(_,t)}function ke(_,e,t){var o,l,n,i;e==document&&(e=document.documentElement),v.__&&v.__(_,e),l=(o=typeof t=="function")?null:t&&t.__k||e.__k,n=[],i=[],J(e,_=(!o&&t||e).__k=ae(R,null,[_]),l||N,N,e.namespaceURI,!o&&t?[t]:l?null:e.firstChild?E.call(e.childNodes):null,n,!o&&t?t:l?l.__e:e.firstChild,o,i),se(n,_,i)}function be(_,e){ke(_,e,be)}function xe(_,e,t){var o,l,n,i,u=b({},_.props);for(n in _.type&&_.type.defaultProps&&(i=_.type.defaultProps),e)n=="key"?o=e[n]:n=="ref"?l=e[n]:u[n]=e[n]===void 0&&i!=null?i[n]:e[n];return arguments.length>2&&(u.children=arguments.length>3?E.call(arguments,2):t),M(_.type,u,o||_.key,l||_.ref,null)}function Ce(_){function e(t){var o,l;return this.getChildContext||(o=new Set,(l={})[e.__c]=this,this.getChildContext=function(){return l},this.componentWillUnmount=function(){o=null},this.shouldComponentUpdate=function(n){this.props.value!=n.value&&o.forEach(function(i){i.__e=!0,V(i)})},this.sub=function(n){o.add(n);var i=n.componentWillUnmount;n.componentWillUnmount=function(){o&&o.delete(n),i&&i.call(n)}}),t.children}return e.__c="__cC"+re++,e.__=_,e.Provider=e.__l=(e.Consumer=function(t,o){return t.children(o)}).contextType=e,e}E=H.slice,v={__e:function(_,e,t,o){for(var l,n,i;e=e.__;)if((l=e.__c)&&!l.__)try{if((n=l.constructor)&&n.getDerivedStateFromError!=null&&(l.setState(n.getDerivedStateFromError(_)),i=l.__d),l.componentDidCatch!=null&&(l.componentDidCatch(_,o||{}),i=l.__d),i)return l.__E=l}catch(u){_=u}throw _}},ee=0,pe=function(_){return _!=null&&_.constructor===void 0},L.prototype.setState=function(_,e){var t;t=this.__s!=null&&this.__s!=this.state?this.__s:this.__s=b({},this.state),typeof _=="function"&&(_=_(b({},t),this.props)),_&&b(t,_),_!=null&&this.__v&&(e&&this._sb.push(e),V(this))},L.prototype.forceUpdate=function(_){this.__v&&(this.__e=!0,_&&this.__h.push(_),V(this))},L.prototype.render=R,x=[],_e=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,te=function(_,e){return _.__v.__b-e.__v.__b},I.__r=0,B=Math.random().toString(8),F="__d"+B,T="__a"+B,ne=/(PointerCapture)$|Capture$/i,q=0,O=Z(!1),j=Z(!0),re=0;export{L as Component,R as Fragment,xe as cloneElement,Ce as createContext,ae as createElement,we as createRef,ae as h,be as hydrate,pe as isValidElement,v as options,ke as render,ve as toChildArray};
|