@openephemeris/mcp-server 3.13.9 → 3.13.10

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.
Files changed (61) hide show
  1. package/README.md +2 -2
  2. package/config/dev-allowlist.json +28 -4
  3. package/dist/index.js +45 -0
  4. package/dist/oauth/dcr.d.ts +11 -0
  5. package/dist/oauth/dcr.js +49 -0
  6. package/dist/oauth/discovery.d.ts +11 -0
  7. package/dist/oauth/discovery.js +40 -0
  8. package/dist/oauth/pkce.d.ts +18 -0
  9. package/dist/oauth/pkce.js +34 -0
  10. package/dist/oauth/rate-limit.d.ts +20 -0
  11. package/dist/oauth/rate-limit.js +65 -0
  12. package/dist/oauth/store.d.ts +68 -0
  13. package/dist/oauth/store.js +247 -0
  14. package/dist/oauth/supabase-jwt.d.ts +39 -0
  15. package/dist/oauth/supabase-jwt.js +194 -0
  16. package/dist/oauth/token.d.ts +21 -0
  17. package/dist/oauth/token.js +213 -0
  18. package/dist/prompts.js +171 -159
  19. package/dist/server-sse.js +134 -36
  20. package/dist/tools/apps/bazi-app.d.ts +23 -0
  21. package/dist/tools/apps/bazi-app.js +224 -0
  22. package/dist/tools/apps/bi-wheel-app.d.ts +14 -7
  23. package/dist/tools/apps/bi-wheel-app.js +293 -108
  24. package/dist/tools/apps/bodygraph-app.js +38 -3
  25. package/dist/tools/apps/moon-phase-app.d.ts +19 -0
  26. package/dist/tools/apps/moon-phase-app.js +190 -0
  27. package/dist/tools/apps/transit-timeline-app.d.ts +20 -0
  28. package/dist/tools/apps/transit-timeline-app.js +243 -0
  29. package/dist/tools/apps/vedic-chart-app.d.ts +17 -0
  30. package/dist/tools/apps/vedic-chart-app.js +226 -0
  31. package/dist/tools/index.js +4 -0
  32. package/dist/tools/specialized/acg.js +2 -2
  33. package/dist/tools/specialized/bazi.js +367 -44
  34. package/dist/tools/specialized/bi_wheel.js +1 -1
  35. package/dist/tools/specialized/chart_wheel.js +1 -1
  36. package/dist/tools/specialized/comparative.js +4 -4
  37. package/dist/tools/specialized/eclipse.js +1 -1
  38. package/dist/tools/specialized/electional.js +4 -4
  39. package/dist/tools/specialized/ephemeris_core.js +2 -2
  40. package/dist/tools/specialized/ephemeris_extended.js +8 -8
  41. package/dist/tools/specialized/hd_bodygraph.js +1 -1
  42. package/dist/tools/specialized/hd_cycles.js +2 -2
  43. package/dist/tools/specialized/hd_group.js +2 -2
  44. package/dist/tools/specialized/human_design.js +1 -1
  45. package/dist/tools/specialized/moon.js +2 -2
  46. package/dist/tools/specialized/natal.js +1 -1
  47. package/dist/tools/specialized/progressed.js +1 -1
  48. package/dist/tools/specialized/relocation.js +1 -1
  49. package/dist/tools/specialized/returns.js +3 -3
  50. package/dist/tools/specialized/synastry.js +1 -1
  51. package/dist/tools/specialized/transits.js +1 -1
  52. package/dist/tools/specialized/vedic.js +1 -1
  53. package/dist/tools/specialized/venus_star_points.js +6 -6
  54. package/dist/ui/bazi.html +213 -0
  55. package/dist/ui/bi-wheel.html +762 -489
  56. package/dist/ui/bodygraph.html +1788 -1649
  57. package/dist/ui/chart-wheel.html +1772 -1593
  58. package/dist/ui/moon-phase.html +6758 -0
  59. package/dist/ui/transit-timeline.html +6835 -0
  60. package/dist/ui/vedic-chart.html +210 -0
  61. package/package.json +2 -2
@@ -3,11 +3,11 @@
3
3
  <head>
4
4
  <meta charset="UTF-8" />
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
- <meta name="color-scheme" content="dark" />
6
+ <meta name="color-scheme" content="dark light" />
7
7
  <title>Bi-Wheel Explorer</title>
8
8
 
9
9
 
10
- <style>:root{--bg:#010203;--surface:#040609;--surface-2:#0b0d13;--border:#13161d;--border-strong:#242932;--text:#e2e4e9;--text-secondary:#777a80;--gold:#cc9c42;--gold-dim:#7b6540;--gold-glow:rgba(204,156,66,.2);--gold-subtle:rgba(204,156,66,.1);--success:#1da871;--error:#c53443;--radius:10px;--radius-sm:6px;--radius-pill:99px;--shadow:0 4px 20px rgba(0,0,0,.45);--shadow-md:0 8px 40px rgba(0,0,0,.65), 0 0 0 1px var(--border-strong);--inner-glyph:#a494f6;--inner-tick:#7a6cbc;--inner-ring:#090810;--inner-stroke:#24222d;--outer-glyph:#e6ac3d;--outer-tick:#ac7d1b;--outer-ring:#070503;--outer-stroke:#342d20;--xasp-conjunction:#a494f6;--xasp-opposition:#dd4d57;--xasp-trine:#00b4bb;--xasp-square:#ec6d3d;--xasp-sextile:#1da871}@supports (color:color(display-p3 0 0 0)){:root{--bg:color(display-p3 .00515318 .00655345 .0110262);--surface:color(display-p3 .0181758 .0222118 .0344746);--surface-2:color(display-p3 .0438795 .0516065 .0708656);--border:color(display-p3 .0763929 .0859556 .109705);--border-strong:color(display-p3 .146313 .159736 .192938);--text:color(display-p3 .889546 .895785 .910689);--text-secondary:color(display-p3 .470023 .47923 .50135);--gold:color(display-p3 .76996 .617341 .321369);--gold-dim:color(display-p3 .469305 .400291 .270966);--gold-glow:color(display-p3 .76996 .617341 .321369/.2);--gold-subtle:color(display-p3 .76996 .617341 .321369/.1);--success:color(display-p3 .313719 .651039 .459895);--error:color(display-p3 .710345 .252818 .279408);--shadow:0 4px 20px color(display-p3 0 0 0/.45);--shadow-md:0 8px 40px color(display-p3 0 0 0/.65), 0 0 0 1px var(--border-strong);--inner-glyph:color(display-p3 .63252 .582093 .937636);--inner-tick:color(display-p3 .469481 .426877 .716469);--inner-ring:color(display-p3 .0342889 .0311906 .0606274);--inner-stroke:color(display-p3 .139053 .135371 .174039);--outer-glyph:color(display-p3 .866978 .684443 .324483);--outer-tick:color(display-p3 .645333 .49681 .196492);--outer-ring:color(display-p3 .0275363 .0215619 .01263);--outer-stroke:color(display-p3 .20063 .175863 .129743);--xasp-conjunction:color(display-p3 .63252 .582093 .937636);--xasp-opposition:color(display-p3 .803557 .340931 .357065);--xasp-trine:color(display-p3 .311493 .696068 .728277);--xasp-square:color(display-p3 .864679 .454605 .289251);--xasp-sextile:color(display-p3 .313719 .651039 .459895)}}@supports (color:lab(0% 0 0)){:root{--bg:lab(.455387% .00626594 -.517511);--surface:lab(1.54195% -.000223517 -1.4246);--surface-2:lab(3.66055% -.0193194 -3.00652);--border:lab(7.15581% -.0557452 -5.11242);--border-strong:lab(16.3845% -.109613 -6.65551);--text:lab(90.6942% -.142396 -2.26941);--text-secondary:lab(51.2352% -.205308 -3.76425);--gold:lab(67.5798% 11.9379 52.333);--gold-dim:lab(44.394% 5.21129 24.4453);--gold-glow:lab(67.5798% 11.9379 52.333/.2);--gold-subtle:lab(67.5798% 11.9379 52.333/.1);--success:lab(61.2436% -46.7762 18.3644);--error:lab(45.8893% 57.7361 27.393);--shadow:0 4px 20px lab(0% 0 0/.45);--shadow-md:0 8px 40px lab(0% 0 0/.65), 0 0 0 1px var(--border-strong);--inner-glyph:lab(65.7597% 22.6847 -47.4333);--inner-tick:lab(49.7428% 19.7831 -40.5855);--inner-ring:lab(2.38607% 1.22919 -3.41513);--inner-stroke:lab(13.9501% 2.71787 -6.94334);--outer-glyph:lab(74.5248% 14.3487 62.5064);--outer-tick:lab(55.9353% 12.6865 55.2442);--outer-ring:lab(1.56667% .268132 1.12634);--outer-stroke:lab(18.8428% 1.96196 9.88836);--xasp-conjunction:lab(65.7597% 22.6847 -47.4333);--xasp-opposition:lab(54.0218% 57.6814 26.7913);--xasp-trine:lab(66.3586% -37.5367 -15.4041);--xasp-square:lab(61.5466% 48.3829 50.2676);--xasp-sextile:lab(61.2436% -46.7762 18.3644)}}*,:before,:after{box-sizing:border-box;margin:0;padding:0}[hidden]{display:none!important}html,body{--lightningcss-light: ;--lightningcss-dark:initial;color-scheme:dark;height:100%}body{background:var(--bg);color:var(--text);-webkit-user-select:none;-moz-user-select:none;user-select:none;background-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.030'/%3E%3C/svg%3E");font-family:Geist,Space Grotesk,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;line-height:1.5;overflow:hidden}#app{flex-direction:column;height:100vh;display:flex;position:relative;overflow:hidden}#loading-state{color:var(--text-secondary);flex-direction:column;flex:1;justify-content:center;align-items:center;gap:14px;display:flex}#loading-state p{letter-spacing:.06em;text-transform:uppercase;font-size:11px}.oe-loader{width:64px;height:64px;stroke:var(--gold);stroke-width:2px;fill:none;stroke-dasharray:200;stroke-dashoffset:200px;filter:drop-shadow(0 0 4px var(--gold-glow));animation:2.5s cubic-bezier(.16,1,.3,1) infinite oe-draw}@keyframes oe-draw{0%{stroke-dashoffset:200px;stroke-opacity:.1}50%{stroke-dashoffset:0;stroke-opacity:1;filter:drop-shadow(0 0 8px var(--gold))}to{stroke-dashoffset:-200px;stroke-opacity:.1}}#chart-container{aspect-ratio:1;flex-grow:1;flex-shrink:1;justify-content:center;align-items:center;width:100%;min-height:0;max-height:min(520px,100vh - 180px);padding:8px;display:flex;position:relative;overflow:hidden}#chart-container svg{width:100%;height:100%;display:block}#mode-badge{border-top:1px solid var(--border);background:var(--surface);flex-shrink:0;justify-content:center;align-items:center;gap:10px;padding:6px 14px;font-size:11px;display:flex}.mode-badge-inner{color:var(--inner-glyph);letter-spacing:.02em;align-items:center;gap:5px;font-weight:600;display:inline-flex}.mode-badge-outer{color:var(--outer-glyph);letter-spacing:.02em;align-items:center;gap:5px;font-weight:600;display:inline-flex}.mode-badge-sep{color:var(--text-secondary);font-weight:400}.mode-badge-dot-inner{background:var(--inner-tick);border-radius:50%;flex-shrink:0;width:8px;height:8px}.mode-badge-dot-outer{background:var(--outer-tick);border-radius:50%;flex-shrink:0;width:8px;height:8px}.hit-region{cursor:pointer;fill:transparent;stroke:transparent;transition:fill .15s,stroke .15s,opacity .2s}.hit-region:hover{fill:var(--gold-subtle);stroke:var(--gold-dim);stroke-width:1px;stroke-opacity:.45}.hit-region.planet-hit{rx:12px;ry:12px}.hit-region.planet-hit:not(.dim):hover{filter:drop-shadow(0 0 5px var(--gold-glow))}.hit-region.dim{opacity:.12}.hit-region.aspect-hit{stroke-width:20px}.info-drawer{background:var(--surface-2);border:1px solid var(--border-strong);border-radius:var(--radius);width:100%;box-shadow:var(--shadow-md);opacity:0;pointer-events:none;max-height:0;padding:14px 16px 12px;transition:max-height .26s cubic-bezier(.16,1,.3,1),opacity .2s,padding .2s;position:relative;overflow:hidden}.info-drawer:before{content:"";background:var(--border-strong);border-radius:2px;flex-shrink:0;width:36px;height:4px;margin:0 auto 10px;display:block}.info-drawer.open{opacity:1;pointer-events:all;max-height:500px;padding:14px 16px 12px}.info-header{align-items:flex-start;gap:10px;margin-bottom:12px;display:flex}.info-glyph{text-align:center;flex-shrink:0;width:32px;font-size:26px;line-height:1}.info-title{color:var(--text);flex:1;font-size:13px;font-weight:700}.info-subtitle{color:var(--text-secondary);margin-top:2px;font-family:JetBrains Mono,monospace;font-size:11px;font-weight:400}.wheel-badge{border-radius:var(--radius-pill);white-space:nowrap;align-items:center;gap:3px;padding:1px 7px;font-size:10px;font-weight:600;line-height:1.6;display:inline-flex}.wheel-badge.inner{color:var(--inner-glyph);background:rgba(164,148,246,.12);background:color(display-p3 .63252 .582093 .937636/.12);background:lab(65.7597% 22.6847 -47.4333/.12);border:1px solid rgba(164,148,246,.3);border:1px solid color(display-p3 .63252 .582093 .937636/.3);border:1px solid lab(65.7597% 22.6847 -47.4333/.3)}.wheel-badge.outer{color:var(--outer-glyph);background:rgba(230,172,61,.12);background:color(display-p3 .866978 .684443 .324483/.12);background:lab(74.5248% 14.3487 62.5064/.12);border:1px solid rgba(230,172,61,.3);border:1px solid color(display-p3 .866978 .684443 .324483/.3);border:1px solid lab(74.5248% 14.3487 62.5064/.3)}.info-close{cursor:pointer;color:var(--text-secondary);background:0 0;border:none;border-radius:4px;flex-shrink:0;padding:2px 4px;font-size:15px;line-height:1;transition:color .12s}.info-close:hover{color:var(--text)}.aspects-title{text-transform:uppercase;letter-spacing:.1em;color:var(--text-secondary);margin-bottom:6px;font-size:10px;font-weight:700}.aspects-list{scrollbar-width:thin;scrollbar-color:var(--border-strong) transparent;flex-direction:column;gap:4px;max-height:130px;display:flex;overflow-y:auto}.aspects-list::-webkit-scrollbar{width:3px}.aspects-list::-webkit-scrollbar-track{background:0 0}.aspects-list::-webkit-scrollbar-thumb{background:var(--border-strong);border-radius:3px}.aspect-row{align-items:center;gap:7px;padding:3px 0;font-size:12px;display:flex}.aspect-dot{border-radius:50%;flex-shrink:0;width:7px;height:7px}.aspect-sym{text-align:center;flex-shrink:0;width:16px;font-size:14px}.aspect-other{color:var(--text);flex:1}.aspect-meta{color:var(--text-secondary);white-space:nowrap;font-family:JetBrains Mono,monospace;font-size:11px}.no-aspects{color:var(--text-secondary);padding:4px 0;font-size:11px;font-style:italic}.info-hint{color:var(--gold-dim);letter-spacing:.03em;text-align:center;margin-top:10px;font-size:10px}.tooltip{-webkit-backdrop-filter:blur(14px)saturate(1.6);backdrop-filter:blur(14px)saturate(1.6);border:1px solid var(--border-strong);border-radius:var(--radius);pointer-events:none;z-index:1000;opacity:0;background:rgba(7,9,14,.92);background:color(display-p3 .0286832 .0352525 .0537785/.92);background:lab(2.44746% .00379235 -2.33402/.92);max-width:240px;padding:8px 12px;font-size:12px;transition:opacity .12s;position:fixed;box-shadow:0 8px 32px rgba(0,0,0,.55),inset 0 .5px rgba(255,255,255,.04);box-shadow:0 8px 32px color(display-p3 0 0 0/.55),inset 0 .5px color(display-p3 1 1 1/.04);box-shadow:0 8px 32px lab(0% 0 0/.55),inset 0 .5px lab(100% 0 0/.04)}.tooltip.visible{opacity:1}.tooltip-title{color:var(--text);margin-bottom:2px;font-weight:700}.tooltip-detail{color:var(--text-secondary);line-height:1.4}.tooltip-hint{color:var(--gold-dim);letter-spacing:.03em;margin-top:4px;font-size:10px}.error-state{text-align:center;color:var(--text-secondary);flex-direction:column;flex:1;justify-content:center;align-items:center;gap:8px;padding:24px;display:flex}.error-state .error-icon{opacity:.6;margin-bottom:4px;font-size:28px}.error-state .error-msg{color:var(--text-secondary);text-align:center;max-width:280px;font-size:13px;line-height:1.5}#chart-hint{text-align:center;color:var(--text-secondary);letter-spacing:.04em;opacity:.65;flex-shrink:0;padding:4px 12px 6px;font-size:10px}.chart-status{-webkit-backdrop-filter:blur(12px);backdrop-filter:blur(12px);border-radius:var(--radius-pill);color:var(--gold);z-index:900;opacity:0;pointer-events:none;letter-spacing:.04em;background:rgba(7,9,14,.92);background:color(display-p3 .0286832 .0352525 .0537785/.92);background:lab(2.44746% .00379235 -2.33402/.92);border:1px solid rgba(204,156,66,.35);border:1px solid color(display-p3 .76996 .617341 .321369/.35);border:1px solid lab(67.5798% 11.9379 52.333/.35);max-height:0;padding:5px 16px;font-size:11px;font-weight:600;transition:max-height .24s cubic-bezier(.16,1,.3,1),opacity .24s,transform .24s cubic-bezier(.16,1,.3,1);position:fixed;top:10px;left:50%;overflow:hidden;transform:translate(-50%)translateY(-10px);box-shadow:0 4px 20px rgba(0,0,0,.5),0 0 0 1px rgba(204,156,66,.1);box-shadow:0 4px 20px color(display-p3 0 0 0/.5),0 0 0 1px color(display-p3 .76996 .617341 .321369/.1);box-shadow:0 4px 20px lab(0% 0 0/.5),0 0 0 1px lab(67.5798% 11.9379 52.333/.1)}.chart-status.visible{opacity:1;max-height:44px;transform:translate(-50%)translateY(0)}.ask-claude-btn{border-radius:var(--radius-sm);width:100%;color:var(--gold);letter-spacing:.04em;cursor:pointer;background:rgba(204,156,66,.12);background:color(display-p3 .76996 .617341 .321369/.12);background:lab(67.5798% 11.9379 52.333/.12);border:1px solid rgba(204,156,66,.4);border:1px solid color(display-p3 .76996 .617341 .321369/.4);border:1px solid lab(67.5798% 11.9379 52.333/.4);justify-content:center;align-items:center;gap:6px;margin-top:12px;padding:9px 16px;font-family:Geist,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:12px;font-weight:600;transition:background .16s,border-color .16s,box-shadow .16s;display:flex}.ask-claude-btn:hover:not(:disabled){background:rgba(204,156,66,.2);background:color(display-p3 .76996 .617341 .321369/.2);background:lab(67.5798% 11.9379 52.333/.2);border-color:rgba(204,156,66,.65);border-color:color(display-p3 .76996 .617341 .321369/.65);border-color:lab(67.5798% 11.9379 52.333/.65);box-shadow:0 0 0 3px rgba(204,156,66,.12);box-shadow:0 0 0 3px color(display-p3 .76996 .617341 .321369/.12);box-shadow:0 0 0 3px lab(67.5798% 11.9379 52.333/.12)}.ask-claude-btn:disabled{opacity:.45;cursor:not-allowed}.ask-claude-btn.sending{color:var(--gold-dim);opacity:.8;cursor:wait;pointer-events:none;background:rgba(204,156,66,.08);background:color(display-p3 .76996 .617341 .321369/.08);background:lab(67.5798% 11.9379 52.333/.08);border-color:rgba(204,156,66,.25);border-color:color(display-p3 .76996 .617341 .321369/.25);border-color:lab(67.5798% 11.9379 52.333/.25)}.ask-claude-btn.sent{color:var(--success);pointer-events:none;background:rgba(29,168,113,.15);background:color(display-p3 .313719 .651039 .459895/.15);background:lab(61.2436% -46.7762 18.3644/.15);border-color:rgba(29,168,113,.5);border-color:color(display-p3 .313719 .651039 .459895/.5);border-color:lab(61.2436% -46.7762 18.3644/.5)}.ask-claude-btn.error{color:var(--error);background:rgba(197,52,67,.15);background:color(display-p3 .710345 .252818 .279408/.15);background:lab(45.8893% 57.7361 27.393/.15);border-color:rgba(197,52,67,.5);border-color:color(display-p3 .710345 .252818 .279408/.5);border-color:lab(45.8893% 57.7361 27.393/.5)}.hd-action-bar{flex-wrap:wrap;gap:8px;padding:10px 16px 6px;display:flex}.action-btn{color:#d4af37;letter-spacing:.02em;cursor:pointer;white-space:nowrap;background:rgba(212,175,55,.08);border:1px solid rgba(212,175,55,.3);border-radius:8px;align-items:center;gap:6px;padding:7px 16px;font-size:12px;font-weight:600;transition:background .2s,border-color .2s,transform .1s;display:inline-flex}.action-btn:hover{background:rgba(212,175,55,.15);border-color:rgba(212,175,55,.5);transform:translateY(-1px)}.action-btn:active{background:rgba(212,175,55,.2);transform:translateY(0)}.action-btn--primary{color:#f0d060;background:linear-gradient(135deg,rgba(212,175,55,.2),rgba(180,140,30,.25));border-color:rgba(212,175,55,.5)}.action-btn--primary:hover{background:linear-gradient(135deg,rgba(212,175,55,.3),rgba(180,140,30,.35));border-color:rgba(212,175,55,.7)}.pan-zoom-controls{z-index:800;flex-direction:column;gap:6px;display:flex;position:fixed;bottom:20px;right:20px}.pan-zoom-controls[hidden]{display:none!important}.pan-btn{background:var(--surface-2);border:1px solid var(--border-strong);color:var(--text);border-radius:var(--radius-sm);cursor:pointer;width:36px;height:36px;box-shadow:var(--shadow-md);justify-content:center;align-items:center;font-family:inherit;font-size:18px;transition:all .15s;display:flex}.pan-btn.reset{width:auto;padding:0 10px;font-size:11px;font-weight:500}.pan-btn:hover{background:var(--surface);border-color:var(--gold-dim);color:var(--gold)}.pan-btn:active{transform:scale(.95)}.dignity-badge{letter-spacing:.03em;border-radius:4px;padding:1px 6px;font-size:10px;font-weight:600;display:inline-block}.dignity-domicile{color:#cc9c42;color:color(display-p3 .76996 .617341 .321369);color:lab(67.5798% 11.9379 52.333);background:rgba(204,156,66,.15);background:color(display-p3 .76996 .617341 .321369/.15);background:lab(67.5798% 11.9379 52.333/.15);border:1px solid rgba(204,156,66,.3);border:1px solid color(display-p3 .76996 .617341 .321369/.3);border:1px solid lab(67.5798% 11.9379 52.333/.3)}.dignity-exaltation{color:#1da871;color:color(display-p3 .313719 .651039 .459895);color:lab(61.2436% -46.7762 18.3644);background:rgba(29,168,113,.15);background:color(display-p3 .313719 .651039 .459895/.15);background:lab(61.2436% -46.7762 18.3644/.15);border:1px solid rgba(29,168,113,.3);border:1px solid color(display-p3 .313719 .651039 .459895/.3);border:1px solid lab(61.2436% -46.7762 18.3644/.3)}.dignity-detriment,.dignity-fall{color:#c53443;color:color(display-p3 .710345 .252818 .279408);color:lab(45.8893% 57.7361 27.393);background:rgba(197,52,67,.12);background:color(display-p3 .710345 .252818 .279408/.12);background:lab(45.8893% 57.7361 27.393/.12);border:1px solid rgba(197,52,67,.25);border:1px solid color(display-p3 .710345 .252818 .279408/.25);border:1px solid lab(45.8893% 57.7361 27.393/.25)}.mode-badge-name{cursor:pointer;font-family:inherit;font-size:inherit;letter-spacing:.02em;background:0 0;border:none;border-radius:4px;align-items:center;gap:5px;padding:2px 6px;font-weight:600;transition:background .15s,color .15s;display:inline-flex}.mode-badge-name.inner-name{color:var(--inner-glyph)}.mode-badge-name.outer-name{color:var(--outer-glyph)}.mode-badge-name:hover{background:rgba(255,255,255,.06);background:color(display-p3 1 1 1/.06);background:lab(100% 0 0/.06)}.mode-badge-name.focused{color:var(--gold);background:rgba(204,156,66,.12);background:color(display-p3 .76996 .617341 .321369/.12);background:lab(67.5798% 11.9379 52.333/.12)}.mode-badge-swap{cursor:pointer;color:var(--text-secondary);background:0 0;border:none;align-items:center;padding:2px 4px;font-size:13px;line-height:1;transition:color .15s,transform .15s;display:inline-flex}.mode-badge-swap:hover{color:var(--gold);transform:scaleX(-1)}.mode-badge-date{color:var(--text-secondary);letter-spacing:.02em;font-size:10px;font-weight:400}#chart-container[data-focus=inner] .outer-planet-group,#chart-container[data-focus=outer] .inner-planet-group{opacity:.25;transition:opacity .25s}.param-controls{background:var(--surface);border-top:1px solid var(--border);flex-shrink:0;padding:8px 12px}.param-controls-grid{flex-wrap:wrap;align-items:center;gap:12px;display:flex}.param-group{flex-direction:column;gap:4px;display:flex}.param-group label{text-transform:uppercase;color:var(--text-secondary);letter-spacing:.05em;font-size:10px;font-weight:700}.param-group input[type=date],.param-group input[type=time],.param-group input[type=text]{border:1px solid var(--border-strong);color:var(--text);border-radius:var(--radius-sm);background:#07090e;background:color(display-p3 .0286832 .0352525 .0537785);background:lab(2.44746% .00379235 -2.33402);width:130px;padding:4px 8px;font-family:inherit;font-size:12px;transition:border-color .15s}.param-group input:focus{border-color:var(--gold-dim);outline:none}.param-group-loc{flex:1;position:relative}.param-group-loc input{width:100%}.loc-suggestions{background:var(--surface-2);border:1px solid var(--border-strong);border-radius:var(--radius-sm);box-shadow:var(--shadow-md);z-index:100;max-height:200px;margin-top:4px;position:absolute;top:100%;left:0;right:0;overflow-y:auto}.loc-item{color:var(--text);cursor:pointer;white-space:nowrap;text-overflow:ellipsis;border-bottom:1px solid var(--border);padding:8px 10px;font-size:12px;overflow:hidden}.loc-item:last-child{border-bottom:none}.loc-item:hover{background:var(--gold-subtle);color:var(--gold)}.param-actions{align-items:flex-end;gap:6px;padding-top:14px;display:flex}.param-btn-icon{border:1px solid var(--border-strong);color:var(--text-secondary);border-radius:var(--radius-sm);cursor:pointer;background:0 0;justify-content:center;align-items:center;width:26px;height:26px;transition:all .15s;display:flex}.param-btn-icon:hover{background:var(--surface-2);color:var(--text);border-color:var(--gold-dim)}.param-btn-primary{color:var(--gold);border-radius:var(--radius-sm);cursor:pointer;text-transform:uppercase;letter-spacing:.05em;background:rgba(204,156,66,.12);background:color(display-p3 .76996 .617341 .321369/.12);background:lab(67.5798% 11.9379 52.333/.12);border:1px solid rgba(204,156,66,.4);border:1px solid color(display-p3 .76996 .617341 .321369/.4);border:1px solid lab(67.5798% 11.9379 52.333/.4);height:26px;padding:4px 12px;font-family:inherit;font-size:11px;font-weight:600;transition:all .15s}.param-btn-primary:hover:not(:disabled){background:rgba(204,156,66,.2);background:color(display-p3 .76996 .617341 .321369/.2);background:lab(67.5798% 11.9379 52.333/.2);border-color:rgba(204,156,66,.65);border-color:color(display-p3 .76996 .617341 .321369/.65);border-color:lab(67.5798% 11.9379 52.333/.65)}.param-btn-primary:disabled{opacity:.5;cursor:not-allowed}
10
+ <style>:root{--bg:#010203;--surface:#040609;--surface-2:#0b0d13;--border:#13161d;--border-strong:#242932;--text:#e2e4e9;--text-secondary:#777a80;--gold:#cc9c42;--gold-dim:#7b6540;--gold-glow:rgba(204,156,66,.2);--gold-subtle:rgba(204,156,66,.1);--success:#1da871;--error:#c53443;--radius:10px;--radius-sm:6px;--radius-pill:99px;--shadow:0 4px 20px rgba(0,0,0,.45);--shadow-md:0 8px 40px rgba(0,0,0,.65), 0 0 0 1px var(--border-strong);--inner-glyph:#a494f6;--inner-tick:#7a6cbc;--inner-ring:#090810;--inner-stroke:#24222d;--outer-glyph:#e6ac3d;--outer-tick:#ac7d1b;--outer-ring:#070503;--outer-stroke:#342d20;--xasp-conjunction:#a494f6;--xasp-opposition:#dd4d57;--xasp-trine:#00b4bb;--xasp-square:#ec6d3d;--xasp-sextile:#1da871}@supports (color:color(display-p3 0 0 0)){:root{--bg:color(display-p3 .00515318 .00655345 .0110262);--surface:color(display-p3 .0181758 .0222118 .0344746);--surface-2:color(display-p3 .0438795 .0516065 .0708656);--border:color(display-p3 .0763929 .0859556 .109705);--border-strong:color(display-p3 .146313 .159736 .192938);--text:color(display-p3 .889546 .895785 .910689);--text-secondary:color(display-p3 .470023 .47923 .50135);--gold:color(display-p3 .76996 .617341 .321369);--gold-dim:color(display-p3 .469305 .400291 .270966);--gold-glow:color(display-p3 .76996 .617341 .321369/.2);--gold-subtle:color(display-p3 .76996 .617341 .321369/.1);--success:color(display-p3 .313719 .651039 .459895);--error:color(display-p3 .710345 .252818 .279408);--shadow:0 4px 20px color(display-p3 0 0 0/.45);--shadow-md:0 8px 40px color(display-p3 0 0 0/.65), 0 0 0 1px var(--border-strong);--inner-glyph:color(display-p3 .63252 .582093 .937636);--inner-tick:color(display-p3 .469481 .426877 .716469);--inner-ring:color(display-p3 .0342889 .0311906 .0606274);--inner-stroke:color(display-p3 .139053 .135371 .174039);--outer-glyph:color(display-p3 .866978 .684443 .324483);--outer-tick:color(display-p3 .645333 .49681 .196492);--outer-ring:color(display-p3 .0275363 .0215619 .01263);--outer-stroke:color(display-p3 .20063 .175863 .129743);--xasp-conjunction:color(display-p3 .63252 .582093 .937636);--xasp-opposition:color(display-p3 .803557 .340931 .357065);--xasp-trine:color(display-p3 .311493 .696068 .728277);--xasp-square:color(display-p3 .864679 .454605 .289251);--xasp-sextile:color(display-p3 .313719 .651039 .459895)}}@supports (color:lab(0% 0 0)){:root{--bg:lab(.455387% .00626594 -.517511);--surface:lab(1.54195% -.000223517 -1.4246);--surface-2:lab(3.66055% -.0193194 -3.00652);--border:lab(7.15581% -.0557452 -5.11242);--border-strong:lab(16.3845% -.109613 -6.65551);--text:lab(90.6942% -.142396 -2.26941);--text-secondary:lab(51.2352% -.205308 -3.76425);--gold:lab(67.5798% 11.9379 52.333);--gold-dim:lab(44.394% 5.21129 24.4453);--gold-glow:lab(67.5798% 11.9379 52.333/.2);--gold-subtle:lab(67.5798% 11.9379 52.333/.1);--success:lab(61.2436% -46.7762 18.3644);--error:lab(45.8893% 57.7361 27.393);--shadow:0 4px 20px lab(0% 0 0/.45);--shadow-md:0 8px 40px lab(0% 0 0/.65), 0 0 0 1px var(--border-strong);--inner-glyph:lab(65.7597% 22.6847 -47.4333);--inner-tick:lab(49.7428% 19.7831 -40.5855);--inner-ring:lab(2.38607% 1.22919 -3.41513);--inner-stroke:lab(13.9501% 2.71787 -6.94334);--outer-glyph:lab(74.5248% 14.3487 62.5064);--outer-tick:lab(55.9353% 12.6865 55.2442);--outer-ring:lab(1.56667% .268132 1.12634);--outer-stroke:lab(18.8428% 1.96196 9.88836);--xasp-conjunction:lab(65.7597% 22.6847 -47.4333);--xasp-opposition:lab(54.0218% 57.6814 26.7913);--xasp-trine:lab(66.3586% -37.5367 -15.4041);--xasp-square:lab(61.5466% 48.3829 50.2676);--xasp-sextile:lab(61.2436% -46.7762 18.3644)}}@media (prefers-color-scheme:light){:root{--bg:#f7f5f1;--surface:#eeebe5;--surface-2:#e5e1da;--border:#c8c3bc;--border-strong:#aaa49a;--text:#0a0b0e;--text-secondary:#52555b;--gold:#a75b00;--gold-dim:#754a23;--gold-glow:rgba(167,91,0,.15);--gold-subtle:rgba(167,91,0,.08);--success:#007245;--error:#ac1730;--shadow:0 4px 20px rgba(0,0,0,.08);--shadow-md:0 8px 40px rgba(0,0,0,.12), 0 0 0 1px var(--border);--inner-glyph:#4c279f;--inner-tick:#6451ac;--inner-ring:#e4e3ec;--inner-stroke:#9e9daa;--outer-glyph:#814300;--outer-tick:#944f00;--outer-ring:#f0eae4;--outer-stroke:#9d8b7d;--xasp-conjunction:#6141b9;--xasp-opposition:#b50027;--xasp-trine:#006267;--xasp-square:#af2f00;--xasp-sextile:#006035}@supports (color:color(display-p3 0 0 0)){:root{--bg:color(display-p3 .967616 .959866 .945308);--surface:color(display-p3 .93077 .92051 .901245);--surface-2:color(display-p3 .894193 .881459 .857567);--border:color(display-p3 .781676 .766768 .738822);--border-strong:color(display-p3 .662031 .642737 .606629);--text:color(display-p3 .0396217 .0435166 .0529772);--text-secondary:color(display-p3 .32541 .334025 .354781);--gold:color(display-p3 .62703 .366019 .066174);--gold-dim:color(display-p3 .435961 .29658 .164877);--gold-glow:color(display-p3 .62703 .366019 .066174/.15);--gold-subtle:color(display-p3 .62703 .366019 .066174/.08);--success:color(display-p3 .0747822 .446674 .270898);--error:color(display-p3 .618437 .159268 .203901);--shadow:0 4px 20px color(display-p3 0 0 0/.08);--shadow-md:0 8px 40px color(display-p3 0 0 0/.12), 0 0 0 1px var(--border);--inner-glyph:color(display-p3 .278794 .158398 .599673);--inner-tick:color(display-p3 .380501 .320666 .65345);--inner-ring:color(display-p3 .893891 .891594 .923406);--inner-stroke:color(display-p3 .617945 .614102 .663586);--outer-glyph:color(display-p3 .546568 .206982 -.163371);--outer-tick:color(display-p3 .565006 .308137 -.0454755);--outer-ring:color(display-p3 .935871 .918792 .897114);--outer-stroke:color(display-p3 .605539 .54878 .497832);--xasp-conjunction:color(display-p3 .360823 .260383 .701441);--xasp-opposition:color(display-p3 .665511 -.0200913 .159308);--xasp-trine:color(display-p3 -.23194 .411708 .46114);--xasp-square:color(display-p3 .66427 .178286 -.097047);--xasp-sextile:color(display-p3 -.128224 .386233 .192567)}}@supports (color:lab(0% 0 0)){:root{--bg:lab(96.5376% .34076 2.2589);--surface:lab(93.0632% .459909 3.01538);--surface-2:lab(89.5886% .582159 3.77401);--border:lab(79.1535% .711322 4.53734);--border-strong:lab(67.5627% .983775 6.07444);--text:lab(3.03328% -.0427738 -1.26205);--text-secondary:lab(36.1544% -.190288 -3.75628);--gold:lab(47.1545% 30.4528 65.1933);--gold-dim:lab(35.8965% 16.3481 30.6261);--gold-glow:lab(47.1545% 30.4528 65.1933/.15);--gold-subtle:lab(47.1545% 30.4528 65.1933/.08);--success:lab(41.5033% -47.7771 18.6417);--error:lab(37.7533% 57.7998 28.3288);--shadow:0 4px 20px lab(0% 0 0/.08);--shadow-md:0 8px 40px lab(0% 0 0/.12), 0 0 0 1px var(--border);--inner-glyph:lab(27.1202% 39.9647 -60.0506);--inner-tick:lab(40.0022% 25.4312 -46.9756);--inner-ring:lab(90.6063% 1.4658 -4.25532);--inner-stroke:lab(65.0057% 2.50918 -7.05094);--outer-glyph:lab(35.1174% 42.778 92.0471);--outer-tick:lab(41.3182% 31.0066 70.9209);--outer-ring:lab(93.0452% 1.15132 3.60588);--outer-stroke:lab(59.332% 5.31071 10.1738);--xasp-conjunction:lab(36.7332% 36.7148 -60.0885);--xasp-opposition:lab(37.2913% 70.76 37.4636);--xasp-trine:lab(37.6858% -48.9476 -19.9732);--xasp-square:lab(40.2557% 59.1646 82.2511);--xasp-sextile:lab(34.7777% -56.2553 21.7589)}}}*,:before,:after{box-sizing:border-box;margin:0;padding:0}[hidden]{display:none!important}html,body{--lightningcss-light:initial;--lightningcss-dark: ;color-scheme:light dark;height:100%}@media (prefers-color-scheme:dark){html,body{--lightningcss-light: ;--lightningcss-dark:initial}}body{background:var(--bg);color:var(--text);-webkit-user-select:none;-moz-user-select:none;user-select:none;background-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.030'/%3E%3C/svg%3E");font-family:Geist,Space Grotesk,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;line-height:1.5;overflow-x:hidden;overflow-y:auto}#app{flex-direction:column;min-height:600px;display:flex;position:relative;overflow-x:hidden;overflow-y:auto}#loading-state{color:var(--text-secondary);flex-direction:column;flex:1;justify-content:center;align-items:center;gap:14px;display:flex}#loading-state p{letter-spacing:.06em;text-transform:uppercase;font-size:11px}.oe-loader{width:64px;height:64px;stroke:var(--gold);stroke-width:2px;fill:none;stroke-dasharray:200;stroke-dashoffset:200px;filter:drop-shadow(0 0 4px var(--gold-glow));animation:2.5s cubic-bezier(.16,1,.3,1) infinite oe-draw}@keyframes oe-draw{0%{stroke-dashoffset:200px;stroke-opacity:.1}50%{stroke-dashoffset:0;stroke-opacity:1;filter:drop-shadow(0 0 8px var(--gold))}to{stroke-dashoffset:-200px;stroke-opacity:.1}}#chart-container{aspect-ratio:1;flex-grow:1;flex-shrink:1;justify-content:center;align-items:center;width:100%;min-height:0;max-height:min(520px,100vh - 180px);padding:8px;display:flex;position:relative;overflow:hidden}#chart-container svg{width:100%;height:100%;display:block}#mode-badge{border-top:1px solid var(--border);background:var(--surface);flex-shrink:0;justify-content:center;align-items:center;gap:10px;padding:6px 14px;font-size:11px;display:flex}.mode-badge-inner{color:var(--inner-glyph);letter-spacing:.02em;align-items:center;gap:5px;font-weight:600;display:inline-flex}.mode-badge-outer{color:var(--outer-glyph);letter-spacing:.02em;align-items:center;gap:5px;font-weight:600;display:inline-flex}.mode-badge-sep{color:var(--text-secondary);font-weight:400}.mode-badge-dot-inner{background:var(--inner-tick);border-radius:50%;flex-shrink:0;width:8px;height:8px}.mode-badge-dot-outer{background:var(--outer-tick);border-radius:50%;flex-shrink:0;width:8px;height:8px}.hit-region{cursor:pointer;fill:transparent;stroke:transparent;transition:fill .15s,stroke .15s,opacity .2s}.hit-region:hover{fill:var(--gold-subtle);stroke:var(--gold-dim);stroke-width:1px;stroke-opacity:.45}.hit-region.planet-hit{rx:12px;ry:12px}.hit-region.planet-hit:not(.dim):hover{filter:drop-shadow(0 0 5px var(--gold-glow))}.hit-region.dim{opacity:.12}.hit-region.aspect-hit{stroke-width:20px}.info-drawer{background:var(--surface-2);border:1px solid var(--border-strong);border-radius:var(--radius);width:100%;box-shadow:var(--shadow-md);opacity:0;pointer-events:none;max-height:0;padding:14px 16px 12px;transition:max-height .26s cubic-bezier(.16,1,.3,1),opacity .2s,padding .2s;position:relative;overflow:hidden}.info-drawer:before{content:"";background:var(--border-strong);border-radius:2px;flex-shrink:0;width:36px;height:4px;margin:0 auto 10px;display:block}.info-drawer.open{opacity:1;pointer-events:all;max-height:500px;padding:14px 16px 12px}.info-header{align-items:flex-start;gap:10px;margin-bottom:12px;display:flex}.info-glyph{text-align:center;flex-shrink:0;width:32px;font-size:26px;line-height:1}.info-title{color:var(--text);flex:1;font-size:13px;font-weight:700}.info-subtitle{color:var(--text-secondary);margin-top:2px;font-family:JetBrains Mono,monospace;font-size:11px;font-weight:400}.wheel-badge{border-radius:var(--radius-pill);white-space:nowrap;align-items:center;gap:3px;padding:1px 7px;font-size:10px;font-weight:600;line-height:1.6;display:inline-flex}.wheel-badge.inner{color:var(--inner-glyph);background:rgba(164,148,246,.12);background:color(display-p3 .63252 .582093 .937636/.12);background:lab(65.7597% 22.6847 -47.4333/.12);border:1px solid rgba(164,148,246,.3);border:1px solid color(display-p3 .63252 .582093 .937636/.3);border:1px solid lab(65.7597% 22.6847 -47.4333/.3)}.wheel-badge.outer{color:var(--outer-glyph);background:rgba(230,172,61,.12);background:color(display-p3 .866978 .684443 .324483/.12);background:lab(74.5248% 14.3487 62.5064/.12);border:1px solid rgba(230,172,61,.3);border:1px solid color(display-p3 .866978 .684443 .324483/.3);border:1px solid lab(74.5248% 14.3487 62.5064/.3)}.info-close{cursor:pointer;color:var(--text-secondary);background:0 0;border:none;border-radius:4px;flex-shrink:0;padding:2px 4px;font-size:15px;line-height:1;transition:color .12s}.info-close:hover{color:var(--text)}.aspects-title{text-transform:uppercase;letter-spacing:.1em;color:var(--text-secondary);margin-bottom:6px;font-size:10px;font-weight:700}.aspects-list{scrollbar-width:thin;scrollbar-color:var(--border-strong) transparent;flex-direction:column;gap:4px;max-height:130px;display:flex;overflow-y:auto}.aspects-list::-webkit-scrollbar{width:3px}.aspects-list::-webkit-scrollbar-track{background:0 0}.aspects-list::-webkit-scrollbar-thumb{background:var(--border-strong);border-radius:3px}.aspect-row{align-items:center;gap:7px;padding:3px 0;font-size:12px;display:flex}.aspect-dot{border-radius:50%;flex-shrink:0;width:7px;height:7px}.aspect-sym{text-align:center;flex-shrink:0;width:16px;font-size:14px}.aspect-other{color:var(--text);flex:1}.aspect-meta{color:var(--text-secondary);white-space:nowrap;font-family:JetBrains Mono,monospace;font-size:11px}.no-aspects{color:var(--text-secondary);padding:4px 0;font-size:11px;font-style:italic}.info-hint{color:var(--gold-dim);letter-spacing:.03em;text-align:center;margin-top:10px;font-size:10px}.tooltip{-webkit-backdrop-filter:blur(14px)saturate(1.6);backdrop-filter:blur(14px)saturate(1.6);border:1px solid var(--border-strong);border-radius:var(--radius);pointer-events:none;z-index:1000;opacity:0;background:rgba(7,9,14,.92);background:color(display-p3 .0286832 .0352525 .0537785/.92);background:lab(2.44746% .00379235 -2.33402/.92);max-width:240px;padding:8px 12px;font-size:12px;transition:opacity .12s;position:fixed;box-shadow:0 8px 32px rgba(0,0,0,.55),inset 0 .5px rgba(255,255,255,.04);box-shadow:0 8px 32px color(display-p3 0 0 0/.55),inset 0 .5px color(display-p3 1 1 1/.04);box-shadow:0 8px 32px lab(0% 0 0/.55),inset 0 .5px lab(100% 0 0/.04)}.tooltip.visible{opacity:1}.tooltip-title{color:var(--text);margin-bottom:2px;font-weight:700}.tooltip-detail{color:var(--text-secondary);line-height:1.4}.tooltip-hint{color:var(--gold-dim);letter-spacing:.03em;margin-top:4px;font-size:10px}.error-state{text-align:center;color:var(--text-secondary);flex-direction:column;flex:1;justify-content:center;align-items:center;gap:8px;padding:24px;display:flex}.error-state .error-icon{opacity:.6;margin-bottom:4px;font-size:28px}.error-state .error-msg{color:var(--text-secondary);text-align:center;max-width:280px;font-size:13px;line-height:1.5}#chart-hint{text-align:center;color:var(--text-secondary);letter-spacing:.04em;opacity:.65;flex-shrink:0;padding:4px 12px 6px;font-size:10px}.chart-status{-webkit-backdrop-filter:blur(12px);backdrop-filter:blur(12px);border-radius:var(--radius-pill);color:var(--gold);z-index:900;opacity:0;pointer-events:none;letter-spacing:.04em;background:rgba(7,9,14,.92);background:color(display-p3 .0286832 .0352525 .0537785/.92);background:lab(2.44746% .00379235 -2.33402/.92);border:1px solid rgba(204,156,66,.35);border:1px solid color(display-p3 .76996 .617341 .321369/.35);border:1px solid lab(67.5798% 11.9379 52.333/.35);max-height:0;padding:5px 16px;font-size:11px;font-weight:600;transition:max-height .24s cubic-bezier(.16,1,.3,1),opacity .24s,transform .24s cubic-bezier(.16,1,.3,1);position:fixed;top:10px;left:50%;overflow:hidden;transform:translate(-50%)translateY(-10px);box-shadow:0 4px 20px rgba(0,0,0,.5),0 0 0 1px rgba(204,156,66,.1);box-shadow:0 4px 20px color(display-p3 0 0 0/.5),0 0 0 1px color(display-p3 .76996 .617341 .321369/.1);box-shadow:0 4px 20px lab(0% 0 0/.5),0 0 0 1px lab(67.5798% 11.9379 52.333/.1)}.chart-status.visible{opacity:1;max-height:44px;transform:translate(-50%)translateY(0)}.ask-claude-btn{border-radius:var(--radius-sm);width:100%;color:var(--gold);letter-spacing:.04em;cursor:pointer;background:rgba(204,156,66,.12);background:color(display-p3 .76996 .617341 .321369/.12);background:lab(67.5798% 11.9379 52.333/.12);border:1px solid rgba(204,156,66,.4);border:1px solid color(display-p3 .76996 .617341 .321369/.4);border:1px solid lab(67.5798% 11.9379 52.333/.4);justify-content:center;align-items:center;gap:6px;margin-top:12px;padding:9px 16px;font-family:Geist,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:12px;font-weight:600;transition:background .16s,border-color .16s,box-shadow .16s;display:flex}.ask-claude-btn:hover:not(:disabled){background:rgba(204,156,66,.2);background:color(display-p3 .76996 .617341 .321369/.2);background:lab(67.5798% 11.9379 52.333/.2);border-color:rgba(204,156,66,.65);border-color:color(display-p3 .76996 .617341 .321369/.65);border-color:lab(67.5798% 11.9379 52.333/.65);box-shadow:0 0 0 3px rgba(204,156,66,.12);box-shadow:0 0 0 3px color(display-p3 .76996 .617341 .321369/.12);box-shadow:0 0 0 3px lab(67.5798% 11.9379 52.333/.12)}.ask-claude-btn:disabled{opacity:.45;cursor:not-allowed}.ask-claude-btn.sending{color:var(--gold-dim);opacity:.8;cursor:wait;pointer-events:none;background:rgba(204,156,66,.08);background:color(display-p3 .76996 .617341 .321369/.08);background:lab(67.5798% 11.9379 52.333/.08);border-color:rgba(204,156,66,.25);border-color:color(display-p3 .76996 .617341 .321369/.25);border-color:lab(67.5798% 11.9379 52.333/.25)}.ask-claude-btn.sent{color:var(--success);pointer-events:none;background:rgba(29,168,113,.15);background:color(display-p3 .313719 .651039 .459895/.15);background:lab(61.2436% -46.7762 18.3644/.15);border-color:rgba(29,168,113,.5);border-color:color(display-p3 .313719 .651039 .459895/.5);border-color:lab(61.2436% -46.7762 18.3644/.5)}.ask-claude-btn.error{color:var(--error);background:rgba(197,52,67,.15);background:color(display-p3 .710345 .252818 .279408/.15);background:lab(45.8893% 57.7361 27.393/.15);border-color:rgba(197,52,67,.5);border-color:color(display-p3 .710345 .252818 .279408/.5);border-color:lab(45.8893% 57.7361 27.393/.5)}.hd-action-bar{flex-wrap:wrap;gap:8px;padding:10px 16px 6px;display:flex}.action-btn{color:#d4af37;letter-spacing:.02em;cursor:pointer;white-space:nowrap;background:rgba(212,175,55,.08);border:1px solid rgba(212,175,55,.3);border-radius:8px;align-items:center;gap:6px;padding:7px 16px;font-size:12px;font-weight:600;transition:background .2s,border-color .2s,transform .1s;display:inline-flex}.action-btn:hover{background:rgba(212,175,55,.15);border-color:rgba(212,175,55,.5);transform:translateY(-1px)}.action-btn:active{background:rgba(212,175,55,.2);transform:translateY(0)}.action-btn--primary{color:#f0d060;background:linear-gradient(135deg,rgba(212,175,55,.2),rgba(180,140,30,.25));border-color:rgba(212,175,55,.5)}.action-btn--primary:hover{background:linear-gradient(135deg,rgba(212,175,55,.3),rgba(180,140,30,.35));border-color:rgba(212,175,55,.7)}.pan-zoom-controls{z-index:800;flex-direction:column;gap:6px;display:flex;position:fixed;bottom:20px;right:20px}.pan-zoom-controls[hidden]{display:none!important}.pan-btn{background:var(--surface-2);border:1px solid var(--border-strong);color:var(--text);border-radius:var(--radius-sm);cursor:pointer;width:36px;height:36px;box-shadow:var(--shadow-md);justify-content:center;align-items:center;font-family:inherit;font-size:18px;transition:all .15s;display:flex}.pan-btn.reset{width:auto;padding:0 10px;font-size:11px;font-weight:500}.pan-btn:hover{background:var(--surface);border-color:var(--gold-dim);color:var(--gold)}.pan-btn:active{transform:scale(.95)}.pan-btn--fullscreen{width:36px;height:36px}body.is-fullscreen{height:100vh;overflow:hidden}body.is-fullscreen #app{grid-template-rows:100vh;grid-template-columns:1fr 300px;width:100vw;height:100vh;padding:0;display:grid;overflow:hidden}body.is-fullscreen #chart-container{height:100vh;max-height:100vh;aspect-ratio:unset;grid-area:1/1;padding:16px}body.is-fullscreen #fs-sidebar{border-left:1px solid var(--border);background:var(--surface);flex-direction:column;grid-area:1/2;height:100vh;display:flex;overflow-x:hidden;overflow-y:auto}body.is-fullscreen #loading-state{grid-area:1/1/auto/-1;height:100vh}body.is-fullscreen .pan-zoom-controls{bottom:24px;right:316px}.cancel-toast{background:var(--surface-2,#1e1e2e);border:1px solid var(--border-strong,#444);color:var(--text-muted,#aaa);border-radius:var(--radius-sm,6px);opacity:0;z-index:9999;pointer-events:none;box-shadow:var(--shadow-md,0 4px 12px rgba(0,0,0,.3));padding:8px 16px;font-family:inherit;font-size:12px;transition:opacity .3s,transform .3s;position:fixed;bottom:20px;left:50%;transform:translate(-50%)translateY(20px)}.cancel-toast.visible{opacity:1;transform:translate(-50%)translateY(0)}.dignity-badge{letter-spacing:.03em;border-radius:4px;padding:1px 6px;font-size:10px;font-weight:600;display:inline-block}.dignity-domicile{color:#cc9c42;color:color(display-p3 .76996 .617341 .321369);color:lab(67.5798% 11.9379 52.333);background:rgba(204,156,66,.15);background:color(display-p3 .76996 .617341 .321369/.15);background:lab(67.5798% 11.9379 52.333/.15);border:1px solid rgba(204,156,66,.3);border:1px solid color(display-p3 .76996 .617341 .321369/.3);border:1px solid lab(67.5798% 11.9379 52.333/.3)}.dignity-exaltation{color:#1da871;color:color(display-p3 .313719 .651039 .459895);color:lab(61.2436% -46.7762 18.3644);background:rgba(29,168,113,.15);background:color(display-p3 .313719 .651039 .459895/.15);background:lab(61.2436% -46.7762 18.3644/.15);border:1px solid rgba(29,168,113,.3);border:1px solid color(display-p3 .313719 .651039 .459895/.3);border:1px solid lab(61.2436% -46.7762 18.3644/.3)}.dignity-detriment,.dignity-fall{color:#c53443;color:color(display-p3 .710345 .252818 .279408);color:lab(45.8893% 57.7361 27.393);background:rgba(197,52,67,.12);background:color(display-p3 .710345 .252818 .279408/.12);background:lab(45.8893% 57.7361 27.393/.12);border:1px solid rgba(197,52,67,.25);border:1px solid color(display-p3 .710345 .252818 .279408/.25);border:1px solid lab(45.8893% 57.7361 27.393/.25)}.mode-badge-name{cursor:pointer;font-family:inherit;font-size:inherit;letter-spacing:.02em;background:0 0;border:none;border-radius:4px;align-items:center;gap:5px;padding:2px 6px;font-weight:600;transition:background .15s,color .15s;display:inline-flex}.mode-badge-name.inner-name{color:var(--inner-glyph)}.mode-badge-name.outer-name{color:var(--outer-glyph)}.mode-badge-name:hover{background:rgba(255,255,255,.06);background:color(display-p3 1 1 1/.06);background:lab(100% 0 0/.06)}.mode-badge-name.focused{color:var(--gold);background:rgba(204,156,66,.12);background:color(display-p3 .76996 .617341 .321369/.12);background:lab(67.5798% 11.9379 52.333/.12)}.mode-badge-swap{cursor:pointer;color:var(--text-secondary);background:0 0;border:none;align-items:center;padding:2px 4px;font-size:13px;line-height:1;transition:color .15s,transform .15s;display:inline-flex}.mode-badge-swap:hover{color:var(--gold);transform:scaleX(-1)}.mode-badge-date{color:var(--text-secondary);letter-spacing:.02em;font-size:10px;font-weight:400}#chart-container[data-focus=inner] .outer-planet-group,#chart-container[data-focus=outer] .inner-planet-group{opacity:.25;transition:opacity .25s}#aspect-filter{padding:0}.asp-panel{flex-wrap:wrap;align-items:center;gap:6px 16px;padding:6px 0;display:flex}.asp-section{align-items:center;gap:6px;display:flex}.asp-section-label{letter-spacing:.08em;text-transform:uppercase;color:var(--text-secondary);white-space:nowrap;font-size:10px;font-weight:700}.aspect-toggle-btn,.orb-preset-btn{border:1.5px solid var(--border-strong);color:var(--text-secondary);cursor:pointer;white-space:nowrap;background:0 0;border-radius:20px;padding:4px 10px;font-size:11px;font-weight:600;transition:background .15s,color .15s,border-color .15s}.aspect-toggle-btn:hover,.orb-preset-btn:hover{border-color:var(--gold-dim);color:var(--text)}.aspect-toggle-btn.active{background:var(--gold);border-color:var(--gold);color:#0d0802;color:color(display-p3 .0492866 .0328715 .0111297);color:lab(2.4863% .883393 2.81807)}.orb-preset-btn.active{background:var(--surface-2);border-color:var(--gold);color:var(--gold)}.aspect-toggle-btn .toggle-icon{font-size:13px;line-height:1}@media (prefers-color-scheme:light){.aspect-toggle-btn.active{color:#0d0802;color:color(display-p3 .0492866 .0328715 .0111297);color:lab(2.4863% .883393 2.81807)}.orb-preset-btn.active{color:var(--gold)}}.chart-provenance{border-bottom:1px solid var(--border);background:var(--surface);flex-direction:column;flex-shrink:0;align-items:center;gap:3px;padding:7px 14px 6px;font-size:10px;animation:.2s both prov-in;display:flex}@keyframes prov-in{0%{opacity:0;transform:translateY(-4px)}to{opacity:1;transform:translateY(0)}}.prov-name{color:var(--text);letter-spacing:.01em;align-items:center;gap:7px;font-size:11px;font-weight:600;display:flex}.prov-mode-tag{letter-spacing:.06em;text-transform:uppercase;color:var(--text-secondary);background:var(--surface-2);border:1px solid var(--border);border-radius:var(--radius-pill);padding:1px 6px;font-size:9px;font-weight:500}.prov-trio{color:var(--text);align-items:center;gap:6px;font-size:11px;display:flex}.prov-planet{font-variant-numeric:tabular-nums;letter-spacing:.01em}.prov-sep{color:var(--border-strong);font-size:12px}.prov-meta{color:var(--text-secondary);letter-spacing:.02em;font-size:10px}.prov-tz{opacity:.7;font-size:9px}.error-state{flex-direction:column;justify-content:center;align-items:center;gap:12px;height:100%;min-height:200px;padding:24px;display:flex}.error-icon{opacity:.7;font-size:28px}.error-msg{color:var(--text-secondary);text-align:center;max-width:260px;font-size:12px;line-height:1.5}.error-retry-btn{border-radius:var(--radius-pill);border:1px solid var(--border-strong);background:var(--surface-2);color:var(--text);font:inherit;cursor:pointer;letter-spacing:.02em;margin-top:4px;padding:7px 20px;font-size:11px;font-weight:500;transition:all .18s}.error-retry-btn:hover{background:var(--gold-subtle);border-color:var(--gold-dim);color:var(--gold)}.chart-layer{opacity:0;transform-origin:310px 310px;will-change:opacity, transform;transform:scale(.98)translateZ(0)}#chart-container.chart-visible .chart-layer{animation:.6s cubic-bezier(.16,1,.3,1) forwards svgLayerAssemble;animation-delay:calc(var(--layer-index,1) * .1s + .1s)}@keyframes svgLayerAssemble{0%{opacity:0;transform:scale(.97)}to{opacity:1;transform:scale(1)}}.floating-action-btn:after{content:"";background:linear-gradient(90deg,transparent,rgba(255,255,255,.2),transparent);width:50%;height:100%;animation:3s 2s infinite shimmer;position:absolute;top:0;left:-100%;transform:skew(-20deg)}@keyframes shimmer{0%{left:-100%}20%{left:200%}to{left:200%}}@keyframes slideUpFadeIn{0%{opacity:0;transform:translateY(20px)}to{opacity:1;transform:translateY(0)}}@keyframes slideUpFadeInPanel{0%{opacity:0;transform:translateY(12px)scale(.98)}to{opacity:1;transform:translateY(0)scale(1)}}.param-controls{background:var(--surface);border-top:1px solid var(--border);flex-shrink:0;padding:8px 12px}.param-controls-grid{flex-wrap:wrap;align-items:center;gap:12px;display:flex}.param-group{flex-direction:column;gap:4px;display:flex}.param-group label{text-transform:uppercase;color:var(--text-secondary);letter-spacing:.05em;font-size:10px;font-weight:700}.param-group input[type=date],.param-group input[type=time],.param-group input[type=text]{background:var(--surface-2);border:1px solid var(--border-strong);color:var(--text);color-scheme:inherit;border-radius:var(--radius-sm);width:130px;padding:4px 8px;font-family:inherit;font-size:12px;transition:border-color .15s}.param-group input:focus{border-color:var(--gold-dim);outline:none}.param-group-loc{flex:1;position:relative}.param-group-loc input{width:100%}.loc-suggestions{background:var(--surface-2);border:1px solid var(--border-strong);border-radius:var(--radius-sm);box-shadow:var(--shadow-md);z-index:100;max-height:200px;margin-top:4px;position:absolute;top:100%;left:0;right:0;overflow-y:auto}.loc-item{color:var(--text);cursor:pointer;white-space:nowrap;text-overflow:ellipsis;border-bottom:1px solid var(--border);padding:8px 10px;font-size:12px;overflow:hidden}.loc-item:last-child{border-bottom:none}.loc-item:hover{background:var(--gold-subtle);color:var(--gold)}.param-actions{align-items:flex-end;gap:6px;padding-top:14px;display:flex}.param-btn-icon{border:1px solid var(--border-strong);color:var(--text-secondary);border-radius:var(--radius-sm);cursor:pointer;background:0 0;justify-content:center;align-items:center;width:26px;height:26px;transition:all .15s;display:flex}.param-btn-icon:hover{background:var(--surface-2);color:var(--text);border-color:var(--gold-dim)}.param-btn-primary{color:var(--gold);border-radius:var(--radius-sm);cursor:pointer;text-transform:uppercase;letter-spacing:.05em;background:rgba(204,156,66,.12);background:color(display-p3 .76996 .617341 .321369/.12);background:lab(67.5798% 11.9379 52.333/.12);border:1px solid rgba(204,156,66,.4);border:1px solid color(display-p3 .76996 .617341 .321369/.4);border:1px solid lab(67.5798% 11.9379 52.333/.4);height:26px;padding:4px 12px;font-family:inherit;font-size:11px;font-weight:600;transition:all .15s}.param-btn-primary:hover:not(:disabled){background:rgba(204,156,66,.2);background:color(display-p3 .76996 .617341 .321369/.2);background:lab(67.5798% 11.9379 52.333/.2);border-color:rgba(204,156,66,.65);border-color:color(display-p3 .76996 .617341 .321369/.65);border-color:lab(67.5798% 11.9379 52.333/.65)}.param-btn-primary:disabled{opacity:.5;cursor:not-allowed}@media (prefers-color-scheme:light){.param-group input[type=date],.param-group input[type=time],.param-group input[type=text]{border-color:var(--border-strong);color:var(--text);--lightningcss-light:initial;--lightningcss-dark: ;color-scheme:light;background:#fff;background:color(display-p3 1 1 1);background:lab(100% 0 0)}.loc-suggestions{border-color:var(--border-strong);background:#fff;background:color(display-p3 1 1 1);background:lab(100% 0 0)}.param-btn-primary{background:rgba(160,112,0,.12);background:color(display-p3 .615135 .441554 -.0204711/.12);background:lab(51.2092% 16.2654 78.3504/.12);border-color:rgba(160,112,0,.4);border-color:color(display-p3 .615135 .441554 -.0204711/.4);border-color:lab(51.2092% 16.2654 78.3504/.4)}.param-btn-primary:hover:not(:disabled){background:rgba(160,112,0,.22);background:color(display-p3 .615135 .441554 -.0204711/.22);background:lab(51.2092% 16.2654 78.3504/.22);border-color:rgba(160,112,0,.65);border-color:color(display-p3 .615135 .441554 -.0204711/.65);border-color:lab(51.2092% 16.2654 78.3504/.65)}}
11
11
  /*$vite$:1*/</style>
12
12
  </head>
13
13
  <body>
@@ -24,6 +24,8 @@
24
24
  </div>
25
25
  <div id="chart-container" hidden></div>
26
26
  <div id="mode-badge" hidden></div>
27
+ <div id="chart-provenance" class="chart-provenance" hidden></div>
28
+ <div id="bi-patterns-strip" class="patterns-strip" hidden></div>
27
29
  <div id="tooltip" class="tooltip" aria-live="polite"></div>
28
30
  <div id="aspect-filter" hidden></div>
29
31
  <div id="param-controls-container" hidden></div>
@@ -120,7 +122,7 @@ var l = /* @__PURE__ */ Symbol("zod_brand"), u = class extends Error {
120
122
  function p(e4) {
121
123
  return e4 && Object.assign(f, e4), f;
122
124
  }
123
- var m = t({ BIGINT_FORMAT_RANGES: () => Ce, Class: () => Ge, NUMBER_FORMAT_RANGES: () => Se, aborted: () => je, allowsEval: () => de, assert: () => y, assertEqual: () => h, assertIs: () => _, assertNever: () => v, assertNotEqual: () => g, assignProp: () => ne, base64ToUint8Array: () => ze, base64urlToUint8Array: () => Ve, cached: () => C, captureStackTrace: () => le, cleanEnum: () => Re, cleanRegex: () => T, clone: () => ye, cloneDef: () => re, createTransparentProxy: () => be, defineLazy: () => D, esc: () => se, escapeRegex: () => ve, extend: () => Ee, finalizeIssue: () => Pe, floatSafeRemainder: () => E, getElementAtPath: () => ie, getEnumValues: () => b, getLengthableOrigin: () => Ie, getParsedType: () => he, getSizableOrigin: () => Fe, hexToUint8Array: () => Ue, isObject: () => ue, isPlainObject: () => fe, issue: () => Le, joinValues: () => x, jsonStringifyReplacer: () => S, merge: () => Oe, mergeDefs: () => O, normalizeParams: () => k, nullish: () => w, numKeys: () => me, objectClone: () => te, omit: () => Te, optionalKeys: () => xe, partial: () => ke, pick: () => we, prefixIssues: () => Me, primitiveTypes: () => _e, promiseAllObject: () => ae, propertyKeyTypes: () => ge, randomString: () => oe, required: () => Ae, safeExtend: () => De, shallowClone: () => pe, slugify: () => ce, stringifyPrimitive: () => A, uint8ArrayToBase64: () => Be, uint8ArrayToBase64url: () => He, uint8ArrayToHex: () => We, unwrapMessage: () => Ne });
125
+ var m = t({ BIGINT_FORMAT_RANGES: () => Ce, Class: () => Ge, NUMBER_FORMAT_RANGES: () => Se, aborted: () => je, allowsEval: () => de, assert: () => y, assertEqual: () => h, assertIs: () => _, assertNever: () => v, assertNotEqual: () => g, assignProp: () => O, base64ToUint8Array: () => ze, base64urlToUint8Array: () => Ve, cached: () => C, captureStackTrace: () => le, cleanEnum: () => Re, cleanRegex: () => T, clone: () => ye, cloneDef: () => re, createTransparentProxy: () => be, defineLazy: () => D, esc: () => se, escapeRegex: () => ve, extend: () => Ee, finalizeIssue: () => Pe, floatSafeRemainder: () => ee, getElementAtPath: () => ie, getEnumValues: () => b, getLengthableOrigin: () => Ie, getParsedType: () => he, getSizableOrigin: () => Fe, hexToUint8Array: () => Ue, isObject: () => ue, isPlainObject: () => fe, issue: () => Le, joinValues: () => x, jsonStringifyReplacer: () => S, merge: () => Oe, mergeDefs: () => ne, normalizeParams: () => k, nullish: () => w, numKeys: () => me, objectClone: () => te, omit: () => Te, optionalKeys: () => xe, partial: () => ke, pick: () => we, prefixIssues: () => Me, primitiveTypes: () => _e, promiseAllObject: () => ae, propertyKeyTypes: () => ge, randomString: () => oe, required: () => Ae, safeExtend: () => De, shallowClone: () => pe, slugify: () => ce, stringifyPrimitive: () => A, uint8ArrayToBase64: () => Be, uint8ArrayToBase64url: () => He, uint8ArrayToHex: () => We, unwrapMessage: () => Ne });
124
126
  function h(e4) {
125
127
  return e4;
126
128
  }
@@ -160,7 +162,7 @@ function T(e4) {
160
162
  let t2 = +!!e4.startsWith("^"), n2 = e4.endsWith("$") ? e4.length - 1 : e4.length;
161
163
  return e4.slice(t2, n2);
162
164
  }
163
- function E(e4, t2) {
165
+ function ee(e4, t2) {
164
166
  let n2 = (e4.toString().split(".")[1] || "").length, r2 = t2.toString(), i2 = (r2.split(".")[1] || "").length;
165
167
  if (i2 === 0 && /\d?e-\d?/.test(r2)) {
166
168
  let e5 = r2.match(/\d?e-(\d?)/);
@@ -169,11 +171,11 @@ function E(e4, t2) {
169
171
  let a2 = n2 > i2 ? n2 : i2;
170
172
  return Number.parseInt(e4.toFixed(a2).replace(".", "")) % Number.parseInt(t2.toFixed(a2).replace(".", "")) / 10 ** a2;
171
173
  }
172
- var ee = /* @__PURE__ */ Symbol("evaluating");
174
+ var E = /* @__PURE__ */ Symbol("evaluating");
173
175
  function D(e4, t2, n2) {
174
176
  let r2;
175
177
  Object.defineProperty(e4, t2, { get() {
176
- if (r2 !== ee) return r2 === void 0 && (r2 = ee, r2 = n2()), r2;
178
+ if (r2 !== E) return r2 === void 0 && (r2 = E, r2 = n2()), r2;
177
179
  }, set(n3) {
178
180
  Object.defineProperty(e4, t2, { value: n3 });
179
181
  }, configurable: true });
@@ -181,16 +183,16 @@ function D(e4, t2, n2) {
181
183
  function te(e4) {
182
184
  return Object.create(Object.getPrototypeOf(e4), Object.getOwnPropertyDescriptors(e4));
183
185
  }
184
- function ne(e4, t2, n2) {
186
+ function O(e4, t2, n2) {
185
187
  Object.defineProperty(e4, t2, { value: n2, writable: true, enumerable: true, configurable: true });
186
188
  }
187
- function O(...e4) {
189
+ function ne(...e4) {
188
190
  let t2 = {};
189
191
  for (let n2 of e4) Object.assign(t2, Object.getOwnPropertyDescriptors(n2));
190
192
  return Object.defineProperties({}, t2);
191
193
  }
192
194
  function re(e4) {
193
- return O(e4._zod.def);
195
+ return ne(e4._zod.def);
194
196
  }
195
197
  function ie(e4, t2) {
196
198
  return t2 ? t2.reduce((e5, t3) => e5 == null ? void 0 : e5[t3], e4) : e4;
@@ -310,70 +312,70 @@ function xe(e4) {
310
312
  var Se = { safeint: [-(2 ** 53 - 1), 2 ** 53 - 1], int32: [-2147483648, 2147483647], uint32: [0, 4294967295], float32: [-34028234663852886e22, 34028234663852886e22], float64: [-Number.MAX_VALUE, Number.MAX_VALUE] }, Ce = { int64: [BigInt("-9223372036854775808"), BigInt("9223372036854775807")], uint64: [BigInt(0), BigInt("18446744073709551615")] };
311
313
  function we(e4, t2) {
312
314
  let n2 = e4._zod.def;
313
- return ye(e4, O(e4._zod.def, { get shape() {
315
+ return ye(e4, ne(e4._zod.def, { get shape() {
314
316
  let e5 = {};
315
317
  for (let r2 in t2) {
316
318
  if (!(r2 in n2.shape)) throw Error('Unrecognized key: "'.concat(r2, '"'));
317
319
  t2[r2] && (e5[r2] = n2.shape[r2]);
318
320
  }
319
- return ne(this, "shape", e5), e5;
321
+ return O(this, "shape", e5), e5;
320
322
  }, checks: [] }));
321
323
  }
322
324
  function Te(e4, t2) {
323
325
  let n2 = e4._zod.def;
324
- return ye(e4, O(e4._zod.def, { get shape() {
326
+ return ye(e4, ne(e4._zod.def, { get shape() {
325
327
  let r2 = { ...e4._zod.def.shape };
326
328
  for (let e5 in t2) {
327
329
  if (!(e5 in n2.shape)) throw Error('Unrecognized key: "'.concat(e5, '"'));
328
330
  t2[e5] && delete r2[e5];
329
331
  }
330
- return ne(this, "shape", r2), r2;
332
+ return O(this, "shape", r2), r2;
331
333
  }, checks: [] }));
332
334
  }
333
335
  function Ee(e4, t2) {
334
336
  if (!fe(t2)) throw Error("Invalid input to extend: expected a plain object");
335
337
  let n2 = e4._zod.def.checks;
336
338
  if (n2 && n2.length > 0) throw Error("Object schemas containing refinements cannot be extended. Use `.safeExtend()` instead.");
337
- return ye(e4, O(e4._zod.def, { get shape() {
339
+ return ye(e4, ne(e4._zod.def, { get shape() {
338
340
  let n3 = { ...e4._zod.def.shape, ...t2 };
339
- return ne(this, "shape", n3), n3;
341
+ return O(this, "shape", n3), n3;
340
342
  }, checks: [] }));
341
343
  }
342
344
  function De(e4, t2) {
343
345
  if (!fe(t2)) throw Error("Invalid input to safeExtend: expected a plain object");
344
346
  return ye(e4, { ...e4._zod.def, get shape() {
345
347
  let n2 = { ...e4._zod.def.shape, ...t2 };
346
- return ne(this, "shape", n2), n2;
348
+ return O(this, "shape", n2), n2;
347
349
  }, checks: e4._zod.def.checks });
348
350
  }
349
351
  function Oe(e4, t2) {
350
- return ye(e4, O(e4._zod.def, { get shape() {
352
+ return ye(e4, ne(e4._zod.def, { get shape() {
351
353
  let n2 = { ...e4._zod.def.shape, ...t2._zod.def.shape };
352
- return ne(this, "shape", n2), n2;
354
+ return O(this, "shape", n2), n2;
353
355
  }, get catchall() {
354
356
  return t2._zod.def.catchall;
355
357
  }, checks: [] }));
356
358
  }
357
359
  function ke(e4, t2, n2) {
358
- return ye(t2, O(t2._zod.def, { get shape() {
360
+ return ye(t2, ne(t2._zod.def, { get shape() {
359
361
  let r2 = t2._zod.def.shape, i2 = { ...r2 };
360
362
  if (n2) for (let t3 in n2) {
361
363
  if (!(t3 in r2)) throw Error('Unrecognized key: "'.concat(t3, '"'));
362
364
  n2[t3] && (i2[t3] = e4 ? new e4({ type: "optional", innerType: r2[t3] }) : r2[t3]);
363
365
  }
364
366
  else for (let t3 in r2) i2[t3] = e4 ? new e4({ type: "optional", innerType: r2[t3] }) : r2[t3];
365
- return ne(this, "shape", i2), i2;
367
+ return O(this, "shape", i2), i2;
366
368
  }, checks: [] }));
367
369
  }
368
370
  function Ae(e4, t2, n2) {
369
- return ye(t2, O(t2._zod.def, { get shape() {
371
+ return ye(t2, ne(t2._zod.def, { get shape() {
370
372
  let r2 = t2._zod.def.shape, i2 = { ...r2 };
371
373
  if (n2) for (let t3 in n2) {
372
374
  if (!(t3 in i2)) throw Error('Unrecognized key: "'.concat(t3, '"'));
373
375
  n2[t3] && (i2[t3] = new e4({ type: "nonoptional", innerType: r2[t3] }));
374
376
  }
375
377
  else for (let t3 in r2) i2[t3] = new e4({ type: "nonoptional", innerType: r2[t3] });
376
- return ne(this, "shape", i2), i2;
378
+ return O(this, "shape", i2), i2;
377
379
  }, checks: [] }));
378
380
  }
379
381
  function je(e4, t2 = 0) {
@@ -603,7 +605,7 @@ var bn = /^[0-9a-fA-F]{32}$/, xn = vn(22, "=="), Sn = yn(22), Cn = /^[0-9a-fA-F]
603
605
  (n2 = e5._zod.bag).multipleOf != null || (n2.multipleOf = t2.value);
604
606
  }), e4._zod.check = (n2) => {
605
607
  if (typeof n2.value != typeof t2.value) throw Error("Cannot mix number and bigint in multiple_of check.");
606
- (typeof n2.value == "bigint" ? n2.value % t2.value === BigInt(0) : E(n2.value, t2.value) === 0) || n2.issues.push({ origin: typeof n2.value, code: "not_multiple_of", divisor: t2.value, input: n2.value, inst: e4, continue: !t2.abort });
608
+ (typeof n2.value == "bigint" ? n2.value % t2.value === BigInt(0) : ee(n2.value, t2.value) === 0) || n2.issues.push({ origin: typeof n2.value, code: "not_multiple_of", divisor: t2.value, input: n2.value, inst: e4, continue: !t2.abort });
607
609
  };
608
610
  }), zn = c("$ZodCheckNumberFormat", (e4, t2) => {
609
611
  var n2;
@@ -2533,14 +2535,14 @@ var Sa = () => {
2533
2535
  return e5 != null && e5.unit ? "".concat(e5.shortLabel, " \u05DE\u05D3\u05D9: ").concat(n4, " ").concat(s3, " ").concat(r3).concat(t3.minimum.toString(), " ").concat(e5.unit) : "".concat((y2 = e5 == null ? void 0 : e5.shortLabel) == null ? "\u05E7\u05D8\u05DF" : y2, " \u05DE\u05D3\u05D9: ").concat(n4, " ").concat(s3, " ").concat(r3).concat(t3.minimum.toString());
2534
2536
  }
2535
2537
  case "invalid_format": {
2536
- var T2, E2;
2538
+ var T2, ee2;
2537
2539
  let e5 = t3;
2538
2540
  if (e5.format === "starts_with") return '\u05D4\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D7\u05D9\u05DC \u05D1 "'.concat(e5.prefix, '"');
2539
2541
  if (e5.format === "ends_with") return '\u05D4\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05E1\u05EA\u05D9\u05D9\u05DD \u05D1 "'.concat(e5.suffix, '"');
2540
2542
  if (e5.format === "includes") return '\u05D4\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05DB\u05DC\u05D5\u05DC "'.concat(e5.includes, '"');
2541
2543
  if (e5.format === "regex") return "\u05D4\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D0\u05D9\u05DD \u05DC\u05EA\u05D1\u05E0\u05D9\u05EA ".concat(e5.pattern);
2542
2544
  let n4 = c2[e5.format];
2543
- return "".concat((T2 = n4 == null ? void 0 : n4.label) == null ? e5.format : T2, " \u05DC\u05D0 ").concat(((E2 = n4 == null ? void 0 : n4.gender) == null ? "m" : E2) === "f" ? "\u05EA\u05E7\u05D9\u05E0\u05D4" : "\u05EA\u05E7\u05D9\u05DF");
2545
+ return "".concat((T2 = n4 == null ? void 0 : n4.label) == null ? e5.format : T2, " \u05DC\u05D0 ").concat(((ee2 = n4 == null ? void 0 : n4.gender) == null ? "m" : ee2) === "f" ? "\u05EA\u05E7\u05D9\u05E0\u05D4" : "\u05EA\u05E7\u05D9\u05DF");
2544
2546
  }
2545
2547
  case "not_multiple_of":
2546
2548
  return "\u05DE\u05E1\u05E4\u05E8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05D7\u05D9\u05D9\u05D1 \u05DC\u05D4\u05D9\u05D5\u05EA \u05DE\u05DB\u05E4\u05DC\u05D4 \u05E9\u05DC ".concat(t3.divisor);
@@ -2551,8 +2553,8 @@ var Sa = () => {
2551
2553
  case "invalid_union":
2552
2554
  return "\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF";
2553
2555
  case "invalid_element":
2554
- var ee2;
2555
- return "\u05E2\u05E8\u05DA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF \u05D1".concat(i2((ee2 = t3.origin) == null ? "array" : ee2));
2556
+ var E2;
2557
+ return "\u05E2\u05E8\u05DA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF \u05D1".concat(i2((E2 = t3.origin) == null ? "array" : E2));
2556
2558
  default:
2557
2559
  return "\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF";
2558
2560
  }
@@ -5105,7 +5107,7 @@ var gl = (e4, t2) => {
5105
5107
  } } });
5106
5108
  }, _l = c("ZodError", gl), vl = c("ZodError", gl, { Parent: Error }), yl = et(vl), bl = nt(vl), xl = it(vl), Sl = ot(vl), Cl = ct(vl), wl = ut(vl), Tl = ft(vl), El = mt(vl), Dl = gt(vl), Ol = vt(vl), kl = bt(vl), Al = St(vl), P = c("ZodType", (e4, t2) => (M.init(e4, t2), e4.def = t2, e4.type = t2.type, Object.defineProperty(e4, "_def", { value: t2 }), e4.check = (...n2) => {
5107
5109
  var r2;
5108
- return e4.clone(O(t2, { checks: [...(r2 = t2.checks) == null ? [] : r2, ...n2.map((e5) => typeof e5 == "function" ? { _zod: { check: e5, def: { check: "custom" }, onattach: [] } } : e5)] }));
5110
+ return e4.clone(ne(t2, { checks: [...(r2 = t2.checks) == null ? [] : r2, ...n2.map((e5) => typeof e5 == "function" ? { _zod: { check: e5, def: { check: "custom" }, onattach: [] } } : e5)] }));
5109
5111
  }, e4.clone = (t3, n2) => ye(e4, t3, n2), e4.brand = () => e4, e4.register = ((t3, n2) => (t3.add(e4, n2), e4)), e4.parse = (t3, n2) => yl(e4, t3, n2, { callee: e4.parse }), e4.safeParse = (t3, n2) => xl(e4, t3, n2), e4.parseAsync = async (t3, n2) => bl(e4, t3, n2, { callee: e4.parseAsync }), e4.safeParseAsync = async (t3, n2) => Sl(e4, t3, n2), e4.spa = e4.safeParseAsync, e4.encode = (t3, n2) => Cl(e4, t3, n2), e4.decode = (t3, n2) => wl(e4, t3, n2), e4.encodeAsync = async (t3, n2) => Tl(e4, t3, n2), e4.decodeAsync = async (t3, n2) => El(e4, t3, n2), e4.safeEncode = (t3, n2) => Dl(e4, t3, n2), e4.safeDecode = (t3, n2) => Ol(e4, t3, n2), e4.safeEncodeAsync = async (t3, n2) => kl(e4, t3, n2), e4.safeDecodeAsync = async (t3, n2) => Al(e4, t3, n2), e4.refine = (t3, n2) => e4.check(cf(t3, n2)), e4.superRefine = (t3) => e4.check(lf(t3)), e4.overwrite = (t3) => e4.check(mc(t3)), e4.optional = () => G(e4), e4.nullable = () => Ad(e4), e4.nullish = () => G(Ad(e4)), e4.nonoptional = (t3) => Ld(e4, t3), e4.array = () => B(e4), e4.or = (t3) => H([e4, t3]), e4.and = (t3) => dd(e4, t3), e4.transform = (t3) => Gd(e4, Dd(t3)), e4.default = (t3) => Nd(e4, t3), e4.prefault = (t3) => Fd(e4, t3), e4.catch = (t3) => Vd(e4, t3), e4.pipe = (t3) => Gd(e4, t3), e4.readonly = () => Yd(e4), e4.describe = (t3) => {
5110
5112
  let n2 = e4.clone();
5111
5113
  return Go.add(n2, { description: t3 }), n2;
@@ -5659,72 +5661,72 @@ var Ef = t({ $brand: () => l, $input: () => Ho, $output: () => Vo, NEVER: () =>
5659
5661
  p(ca());
5660
5662
  var Df = t({ $brand: () => l, $input: () => Ho, $output: () => Vo, NEVER: () => s, TimePrecision: () => _s, ZodAny: () => qu, ZodArray: () => nd, ZodBase64: () => hu, ZodBase64URL: () => _u, ZodBigInt: () => Iu, ZodBigIntFormat: () => Ru, ZodBoolean: () => Fu, ZodCIDRv4: () => du, ZodCIDRv6: () => pu, ZodCUID: () => Yl, ZodCUID2: () => Zl, ZodCatch: () => Bd, ZodCodec: () => Kd, ZodCustom: () => af, ZodCustomStringFormat: () => Cu, ZodDate: () => ed, ZodDefault: () => Md, ZodDiscriminatedUnion: () => cd, ZodE164: () => yu, ZodEmail: () => Nl, ZodEmoji: () => Gl, ZodEnum: () => bd, ZodError: () => _l, ZodFile: () => wd, ZodFirstPartyTypeKind: () => yf, ZodFunction: () => nf, ZodGUID: () => Fl, ZodIPv4: () => au, ZodIPv6: () => lu, ZodISODate: () => ul, ZodISODateTime: () => cl, ZodISODuration: () => ml, ZodISOTime: () => fl, ZodIntersection: () => ud, ZodIssueCode: () => gf, ZodJWT: () => xu, ZodKSUID: () => ru, ZodLazy: () => Qd, ZodLiteral: () => Cd, ZodMAC: () => su, ZodMap: () => gd, ZodNaN: () => Hd, ZodNanoID: () => ql, ZodNever: () => Xu, ZodNonOptional: () => Id, ZodNull: () => Gu, ZodNullable: () => kd, ZodNumber: () => Ou, ZodNumberFormat: () => ku, ZodObject: () => id, ZodOptional: () => Od, ZodPipe: () => Wd, ZodPrefault: () => Pd, ZodPromise: () => ef, ZodReadonly: () => Jd, ZodRealError: () => vl, ZodRecord: () => md, ZodSet: () => vd, ZodString: () => Ml, ZodStringFormat: () => I, ZodSuccess: () => Rd, ZodSymbol: () => Vu, ZodTemplateLiteral: () => Xd, ZodTransform: () => Ed, ZodTuple: () => fd, ZodType: () => P, ZodULID: () => $l, ZodURL: () => Hl, ZodUUID: () => Ll, ZodUndefined: () => Uu, ZodUnion: () => sd, ZodUnknown: () => Yu, ZodVoid: () => Qu, ZodXID: () => tu, _ZodString: () => jl, _default: () => Nd, _function: () => rf, any: () => Ju, array: () => B, base64: () => gu, base64url: () => vu, bigint: () => Lu, boolean: () => R, catch: () => Vd, check: () => of, cidrv4: () => fu, cidrv6: () => mu, clone: () => ye, codec: () => qd, coerce: () => bf, config: () => p, core: () => nl, cuid: () => Xl, cuid2: () => Ql, custom: () => sf, date: () => td, decode: () => wl, decodeAsync: () => El, describe: () => uf, discriminatedUnion: () => ld, e164: () => bu, email: () => Pl, emoji: () => Kl, encode: () => Cl, encodeAsync: () => Tl, endsWith: () => dc, enum: () => xd, file: () => Td, flattenError: () => Ye, float32: () => ju, float64: () => Mu, formatError: () => Xe, function: () => rf, getErrorMap: () => vf, globalRegistry: () => Go, gt: () => qs, gte: () => Js, guid: () => Il, hash: () => Du, hex: () => Eu, hostname: () => Tu, httpUrl: () => Wl, includes: () => lc, instanceof: () => ff, int: () => Au, int32: () => Nu, int64: () => zu, intersection: () => dd, ipv4: () => ou, ipv6: () => uu, iso: () => sl, json: () => mf, jwt: () => Su, keyof: () => rd, ksuid: () => iu, lazy: () => $d, length: () => ac, literal: () => W, locales: () => zo, looseObject: () => od, lowercase: () => sc, lt: () => Gs, lte: () => Ks, mac: () => cu, map: () => _d, maxLength: () => rc, maxSize: () => ec, meta: () => df, mime: () => pc, minLength: () => ic, minSize: () => tc, multipleOf: () => $s, nan: () => Ud, nanoid: () => Jl, nativeEnum: () => Sd, negative: () => Xs, never: () => Zu, nonnegative: () => Qs, nonoptional: () => Ld, nonpositive: () => Zs, normalize: () => hc, null: () => Ku, nullable: () => Ad, nullish: () => jd, number: () => L, object: () => V, optional: () => G, overwrite: () => mc, parse: () => yl, parseAsync: () => bl, partialRecord: () => hd, pipe: () => Gd, positive: () => Ys, prefault: () => Fd, preprocess: () => hf, prettifyError: () => $e, promise: () => tf, property: () => fc, readonly: () => Yd, record: () => U, refine: () => cf, regex: () => oc, regexes: () => wt, registry: () => Wo, safeDecode: () => Ol, safeDecodeAsync: () => Al, safeEncode: () => Dl, safeEncodeAsync: () => kl, safeParse: () => xl, safeParseAsync: () => Sl, set: () => yd, setErrorMap: () => _f, size: () => nc, slugify: () => yc, startsWith: () => uc, strictObject: () => ad, string: () => F, stringFormat: () => wu, stringbool: () => pf, success: () => zd, superRefine: () => lf, symbol: () => Hu, templateLiteral: () => Zd, toJSONSchema: () => $c, toLowerCase: () => _c, toUpperCase: () => vc, transform: () => Dd, treeifyError: () => Ze, trim: () => gc, tuple: () => pd, uint32: () => Pu, uint64: () => Bu, ulid: () => eu, undefined: () => Wu, union: () => H, unknown: () => z, uppercase: () => cc, url: () => Ul, util: () => m, uuid: () => Rl, uuidv4: () => zl, uuidv6: () => Bl, uuidv7: () => Vl, void: () => $u, xid: () => nu, z: () => Ef }), Of = "io.modelcontextprotocol/related-task", K = sf((e4) => e4 !== null && (typeof e4 == "object" || typeof e4 == "function")), kf = H([F(), L().int()]), Af = F();
5661
5663
  od({ ttl: L().optional(), pollInterval: L().optional() });
5662
- var jf = V({ ttl: L().optional() }), Mf = V({ taskId: F() }), Nf = od({ progressToken: kf.optional(), [Of]: Mf.optional() }), Pf = V({ _meta: Nf.optional() }), Ff = Pf.extend({ task: jf.optional() }), If = (e4) => Ff.safeParse(e4).success, q = V({ method: F(), params: Pf.loose().optional() }), Lf = V({ _meta: Nf.optional() }), Rf = V({ method: F(), params: Lf.loose().optional() }), J = od({ _meta: Nf.optional() }), zf = H([F(), L().int()]), Bf = V({ jsonrpc: W("2.0"), id: zf, ...q.shape }).strict(), Vf = (e4) => Bf.safeParse(e4).success, Hf = V({ jsonrpc: W("2.0"), ...Rf.shape }).strict(), Uf = (e4) => Hf.safeParse(e4).success, Wf = V({ jsonrpc: W("2.0"), id: zf, result: J }).strict(), Gf = (e4) => Wf.safeParse(e4).success, Y;
5664
+ var jf = V({ ttl: L().optional() }), Mf = V({ taskId: F() }), Nf = od({ progressToken: kf.optional(), [Of]: Mf.optional() }), Pf = V({ _meta: Nf.optional() }), Ff = Pf.extend({ task: jf.optional() }), If = (e4) => Ff.safeParse(e4).success, Lf = V({ method: F(), params: Pf.loose().optional() }), Rf = V({ _meta: Nf.optional() }), zf = V({ method: F(), params: Rf.loose().optional() }), Bf = od({ _meta: Nf.optional() }), Vf = H([F(), L().int()]), Hf = V({ jsonrpc: W("2.0"), id: Vf, ...Lf.shape }).strict(), Uf = (e4) => Hf.safeParse(e4).success, Wf = V({ jsonrpc: W("2.0"), ...zf.shape }).strict(), Gf = (e4) => Wf.safeParse(e4).success, Kf = V({ jsonrpc: W("2.0"), id: Vf, result: Bf }).strict(), qf = (e4) => Kf.safeParse(e4).success, q;
5663
5665
  (function(e4) {
5664
5666
  e4[e4.ConnectionClosed = -32e3] = "ConnectionClosed", e4[e4.RequestTimeout = -32001] = "RequestTimeout", e4[e4.ParseError = -32700] = "ParseError", e4[e4.InvalidRequest = -32600] = "InvalidRequest", e4[e4.MethodNotFound = -32601] = "MethodNotFound", e4[e4.InvalidParams = -32602] = "InvalidParams", e4[e4.InternalError = -32603] = "InternalError", e4[e4.UrlElicitationRequired = -32042] = "UrlElicitationRequired";
5665
- })(Y || (Y = {}));
5666
- var Kf = V({ jsonrpc: W("2.0"), id: zf.optional(), error: V({ code: L().int(), message: F(), data: z().optional() }) }).strict(), qf = (e4) => Kf.safeParse(e4).success, Jf = H([Bf, Hf, Wf, Kf]);
5667
- H([Wf, Kf]);
5668
- var Yf = J.strict(), Xf = Lf.extend({ requestId: zf.optional(), reason: F().optional() }), Zf = Rf.extend({ method: W("notifications/cancelled"), params: Xf }), Qf = V({ icons: B(V({ src: F(), mimeType: F().optional(), sizes: B(F()).optional(), theme: xd(["light", "dark"]).optional() })).optional() }), $f = V({ name: F(), title: F().optional() }), ep = $f.extend({ ...$f.shape, ...Qf.shape, version: F(), websiteUrl: F().optional(), description: F().optional() }), tp = hf((e4) => e4 && typeof e4 == "object" && !Array.isArray(e4) && Object.keys(e4).length === 0 ? { form: {} } : e4, dd(V({ form: dd(V({ applyDefaults: R().optional() }), U(F(), z())).optional(), url: K.optional() }), U(F(), z()).optional())), np = od({ list: K.optional(), cancel: K.optional(), requests: od({ sampling: od({ createMessage: K.optional() }).optional(), elicitation: od({ create: K.optional() }).optional() }).optional() }), rp = od({ list: K.optional(), cancel: K.optional(), requests: od({ tools: od({ call: K.optional() }).optional() }).optional() }), ip = V({ experimental: U(F(), K).optional(), sampling: V({ context: K.optional(), tools: K.optional() }).optional(), elicitation: tp.optional(), roots: V({ listChanged: R().optional() }).optional(), tasks: np.optional(), extensions: U(F(), K).optional() }), ap = Pf.extend({ protocolVersion: F(), capabilities: ip, clientInfo: ep }), op = q.extend({ method: W("initialize"), params: ap }), sp = V({ experimental: U(F(), K).optional(), logging: K.optional(), completions: K.optional(), prompts: V({ listChanged: R().optional() }).optional(), resources: V({ subscribe: R().optional(), listChanged: R().optional() }).optional(), tools: V({ listChanged: R().optional() }).optional(), tasks: rp.optional(), extensions: U(F(), K).optional() }), cp = J.extend({ protocolVersion: F(), capabilities: sp, serverInfo: ep, instructions: F().optional() }), lp = Rf.extend({ method: W("notifications/initialized"), params: Lf.optional() }), up = q.extend({ method: W("ping"), params: Pf.optional() }), dp = V({ progress: L(), total: G(L()), message: G(F()) }), fp = V({ ...Lf.shape, ...dp.shape, progressToken: kf }), pp = Rf.extend({ method: W("notifications/progress"), params: fp }), mp = Pf.extend({ cursor: Af.optional() }), hp = q.extend({ params: mp.optional() }), gp = J.extend({ nextCursor: Af.optional() }), _p = xd(["working", "input_required", "completed", "failed", "cancelled"]), vp = V({ taskId: F(), status: _p, ttl: H([L(), Ku()]), createdAt: F(), lastUpdatedAt: F(), pollInterval: G(L()), statusMessage: G(F()) }), yp = J.extend({ task: vp }), bp = Lf.merge(vp), xp = Rf.extend({ method: W("notifications/tasks/status"), params: bp }), Sp = q.extend({ method: W("tasks/get"), params: Pf.extend({ taskId: F() }) }), Cp = J.merge(vp), wp = q.extend({ method: W("tasks/result"), params: Pf.extend({ taskId: F() }) });
5669
- J.loose();
5670
- var Tp = hp.extend({ method: W("tasks/list") }), Ep = gp.extend({ tasks: B(vp) }), Dp = q.extend({ method: W("tasks/cancel"), params: Pf.extend({ taskId: F() }) }), Op = J.merge(vp), kp = V({ uri: F(), mimeType: G(F()), _meta: U(F(), z()).optional() }), Ap = kp.extend({ text: F() }), jp = F().refine((e4) => {
5667
+ })(q || (q = {}));
5668
+ var Jf = V({ jsonrpc: W("2.0"), id: Vf.optional(), error: V({ code: L().int(), message: F(), data: z().optional() }) }).strict(), Yf = (e4) => Jf.safeParse(e4).success, Xf = H([Hf, Wf, Kf, Jf]);
5669
+ H([Kf, Jf]);
5670
+ var Zf = Bf.strict(), Qf = Rf.extend({ requestId: Vf.optional(), reason: F().optional() }), $f = zf.extend({ method: W("notifications/cancelled"), params: Qf }), ep = V({ icons: B(V({ src: F(), mimeType: F().optional(), sizes: B(F()).optional(), theme: xd(["light", "dark"]).optional() })).optional() }), tp = V({ name: F(), title: F().optional() }), np = tp.extend({ ...tp.shape, ...ep.shape, version: F(), websiteUrl: F().optional(), description: F().optional() }), rp = hf((e4) => e4 && typeof e4 == "object" && !Array.isArray(e4) && Object.keys(e4).length === 0 ? { form: {} } : e4, dd(V({ form: dd(V({ applyDefaults: R().optional() }), U(F(), z())).optional(), url: K.optional() }), U(F(), z()).optional())), ip = od({ list: K.optional(), cancel: K.optional(), requests: od({ sampling: od({ createMessage: K.optional() }).optional(), elicitation: od({ create: K.optional() }).optional() }).optional() }), ap = od({ list: K.optional(), cancel: K.optional(), requests: od({ tools: od({ call: K.optional() }).optional() }).optional() }), op = V({ experimental: U(F(), K).optional(), sampling: V({ context: K.optional(), tools: K.optional() }).optional(), elicitation: rp.optional(), roots: V({ listChanged: R().optional() }).optional(), tasks: ip.optional(), extensions: U(F(), K).optional() }), sp = Pf.extend({ protocolVersion: F(), capabilities: op, clientInfo: np }), cp = Lf.extend({ method: W("initialize"), params: sp }), lp = V({ experimental: U(F(), K).optional(), logging: K.optional(), completions: K.optional(), prompts: V({ listChanged: R().optional() }).optional(), resources: V({ subscribe: R().optional(), listChanged: R().optional() }).optional(), tools: V({ listChanged: R().optional() }).optional(), tasks: ap.optional(), extensions: U(F(), K).optional() }), up = Bf.extend({ protocolVersion: F(), capabilities: lp, serverInfo: np, instructions: F().optional() }), dp = zf.extend({ method: W("notifications/initialized"), params: Rf.optional() }), fp = Lf.extend({ method: W("ping"), params: Pf.optional() }), pp = V({ progress: L(), total: G(L()), message: G(F()) }), mp = V({ ...Rf.shape, ...pp.shape, progressToken: kf }), hp = zf.extend({ method: W("notifications/progress"), params: mp }), gp = Pf.extend({ cursor: Af.optional() }), _p = Lf.extend({ params: gp.optional() }), vp = Bf.extend({ nextCursor: Af.optional() }), yp = xd(["working", "input_required", "completed", "failed", "cancelled"]), bp = V({ taskId: F(), status: yp, ttl: H([L(), Ku()]), createdAt: F(), lastUpdatedAt: F(), pollInterval: G(L()), statusMessage: G(F()) }), xp = Bf.extend({ task: bp }), Sp = Rf.merge(bp), Cp = zf.extend({ method: W("notifications/tasks/status"), params: Sp }), wp = Lf.extend({ method: W("tasks/get"), params: Pf.extend({ taskId: F() }) }), Tp = Bf.merge(bp), Ep = Lf.extend({ method: W("tasks/result"), params: Pf.extend({ taskId: F() }) });
5671
+ Bf.loose();
5672
+ var Dp = _p.extend({ method: W("tasks/list") }), Op = vp.extend({ tasks: B(bp) }), kp = Lf.extend({ method: W("tasks/cancel"), params: Pf.extend({ taskId: F() }) }), Ap = Bf.merge(bp), jp = V({ uri: F(), mimeType: G(F()), _meta: U(F(), z()).optional() }), Mp = jp.extend({ text: F() }), Np = F().refine((e4) => {
5671
5673
  try {
5672
5674
  return atob(e4), true;
5673
5675
  } catch (e5) {
5674
5676
  return false;
5675
5677
  }
5676
- }, { message: "Invalid Base64 string" }), Mp = kp.extend({ blob: jp }), Np = xd(["user", "assistant"]), Pp = V({ audience: B(Np).optional(), priority: L().min(0).max(1).optional(), lastModified: ll({ offset: true }).optional() }), Fp = V({ ...$f.shape, ...Qf.shape, uri: F(), description: G(F()), mimeType: G(F()), size: G(L()), annotations: Pp.optional(), _meta: G(od({})) }), Ip = V({ ...$f.shape, ...Qf.shape, uriTemplate: F(), description: G(F()), mimeType: G(F()), annotations: Pp.optional(), _meta: G(od({})) }), Lp = hp.extend({ method: W("resources/list") }), Rp = gp.extend({ resources: B(Fp) }), zp = hp.extend({ method: W("resources/templates/list") }), Bp = gp.extend({ resourceTemplates: B(Ip) }), Vp = Pf.extend({ uri: F() }), Hp = Vp, Up = q.extend({ method: W("resources/read"), params: Hp }), Wp = J.extend({ contents: B(H([Ap, Mp])) }), Gp = Rf.extend({ method: W("notifications/resources/list_changed"), params: Lf.optional() }), Kp = Vp, qp = q.extend({ method: W("resources/subscribe"), params: Kp }), Jp = Vp, Yp = q.extend({ method: W("resources/unsubscribe"), params: Jp }), Xp = Lf.extend({ uri: F() }), Zp = Rf.extend({ method: W("notifications/resources/updated"), params: Xp }), Qp = V({ name: F(), description: G(F()), required: G(R()) }), $p = V({ ...$f.shape, ...Qf.shape, description: G(F()), arguments: G(B(Qp)), _meta: G(od({})) }), em = hp.extend({ method: W("prompts/list") }), tm = gp.extend({ prompts: B($p) }), nm = Pf.extend({ name: F(), arguments: U(F(), F()).optional() }), rm = q.extend({ method: W("prompts/get"), params: nm }), im = V({ type: W("text"), text: F(), annotations: Pp.optional(), _meta: U(F(), z()).optional() }), am = V({ type: W("image"), data: jp, mimeType: F(), annotations: Pp.optional(), _meta: U(F(), z()).optional() }), om = V({ type: W("audio"), data: jp, mimeType: F(), annotations: Pp.optional(), _meta: U(F(), z()).optional() }), sm = V({ type: W("tool_use"), name: F(), id: F(), input: U(F(), z()), _meta: U(F(), z()).optional() }), cm = V({ type: W("resource"), resource: H([Ap, Mp]), annotations: Pp.optional(), _meta: U(F(), z()).optional() }), lm = Fp.extend({ type: W("resource_link") }), um = H([im, am, om, lm, cm]), dm = V({ role: Np, content: um }), fm = J.extend({ description: F().optional(), messages: B(dm) }), pm = Rf.extend({ method: W("notifications/prompts/list_changed"), params: Lf.optional() }), mm = V({ title: F().optional(), readOnlyHint: R().optional(), destructiveHint: R().optional(), idempotentHint: R().optional(), openWorldHint: R().optional() }), hm = V({ taskSupport: xd(["required", "optional", "forbidden"]).optional() }), gm = V({ ...$f.shape, ...Qf.shape, description: F().optional(), inputSchema: V({ type: W("object"), properties: U(F(), K).optional(), required: B(F()).optional() }).catchall(z()), outputSchema: V({ type: W("object"), properties: U(F(), K).optional(), required: B(F()).optional() }).catchall(z()).optional(), annotations: mm.optional(), execution: hm.optional(), _meta: U(F(), z()).optional() }), _m = hp.extend({ method: W("tools/list") }), vm = gp.extend({ tools: B(gm) }), ym = J.extend({ content: B(um).default([]), structuredContent: U(F(), z()).optional(), isError: R().optional() });
5677
- ym.or(J.extend({ toolResult: z() }));
5678
- var bm = Ff.extend({ name: F(), arguments: U(F(), z()).optional() }), xm = q.extend({ method: W("tools/call"), params: bm }), Sm = Rf.extend({ method: W("notifications/tools/list_changed"), params: Lf.optional() });
5678
+ }, { message: "Invalid Base64 string" }), Pp = jp.extend({ blob: Np }), Fp = xd(["user", "assistant"]), Ip = V({ audience: B(Fp).optional(), priority: L().min(0).max(1).optional(), lastModified: ll({ offset: true }).optional() }), Lp = V({ ...tp.shape, ...ep.shape, uri: F(), description: G(F()), mimeType: G(F()), size: G(L()), annotations: Ip.optional(), _meta: G(od({})) }), Rp = V({ ...tp.shape, ...ep.shape, uriTemplate: F(), description: G(F()), mimeType: G(F()), annotations: Ip.optional(), _meta: G(od({})) }), zp = _p.extend({ method: W("resources/list") }), Bp = vp.extend({ resources: B(Lp) }), Vp = _p.extend({ method: W("resources/templates/list") }), Hp = vp.extend({ resourceTemplates: B(Rp) }), Up = Pf.extend({ uri: F() }), Wp = Up, Gp = Lf.extend({ method: W("resources/read"), params: Wp }), Kp = Bf.extend({ contents: B(H([Mp, Pp])) }), qp = zf.extend({ method: W("notifications/resources/list_changed"), params: Rf.optional() }), Jp = Up, Yp = Lf.extend({ method: W("resources/subscribe"), params: Jp }), Xp = Up, Zp = Lf.extend({ method: W("resources/unsubscribe"), params: Xp }), Qp = Rf.extend({ uri: F() }), $p = zf.extend({ method: W("notifications/resources/updated"), params: Qp }), em = V({ name: F(), description: G(F()), required: G(R()) }), tm = V({ ...tp.shape, ...ep.shape, description: G(F()), arguments: G(B(em)), _meta: G(od({})) }), nm = _p.extend({ method: W("prompts/list") }), rm = vp.extend({ prompts: B(tm) }), im = Pf.extend({ name: F(), arguments: U(F(), F()).optional() }), am = Lf.extend({ method: W("prompts/get"), params: im }), om = V({ type: W("text"), text: F(), annotations: Ip.optional(), _meta: U(F(), z()).optional() }), sm = V({ type: W("image"), data: Np, mimeType: F(), annotations: Ip.optional(), _meta: U(F(), z()).optional() }), cm = V({ type: W("audio"), data: Np, mimeType: F(), annotations: Ip.optional(), _meta: U(F(), z()).optional() }), lm = V({ type: W("tool_use"), name: F(), id: F(), input: U(F(), z()), _meta: U(F(), z()).optional() }), um = V({ type: W("resource"), resource: H([Mp, Pp]), annotations: Ip.optional(), _meta: U(F(), z()).optional() }), dm = Lp.extend({ type: W("resource_link") }), fm = H([om, sm, cm, dm, um]), pm = V({ role: Fp, content: fm }), mm = Bf.extend({ description: F().optional(), messages: B(pm) }), hm = zf.extend({ method: W("notifications/prompts/list_changed"), params: Rf.optional() }), gm = V({ title: F().optional(), readOnlyHint: R().optional(), destructiveHint: R().optional(), idempotentHint: R().optional(), openWorldHint: R().optional() }), _m = V({ taskSupport: xd(["required", "optional", "forbidden"]).optional() }), vm = V({ ...tp.shape, ...ep.shape, description: F().optional(), inputSchema: V({ type: W("object"), properties: U(F(), K).optional(), required: B(F()).optional() }).catchall(z()), outputSchema: V({ type: W("object"), properties: U(F(), K).optional(), required: B(F()).optional() }).catchall(z()).optional(), annotations: gm.optional(), execution: _m.optional(), _meta: U(F(), z()).optional() }), ym = _p.extend({ method: W("tools/list") }), bm = vp.extend({ tools: B(vm) }), xm = Bf.extend({ content: B(fm).default([]), structuredContent: U(F(), z()).optional(), isError: R().optional() });
5679
+ xm.or(Bf.extend({ toolResult: z() }));
5680
+ var Sm = Ff.extend({ name: F(), arguments: U(F(), z()).optional() }), Cm = Lf.extend({ method: W("tools/call"), params: Sm }), wm = zf.extend({ method: W("notifications/tools/list_changed"), params: Rf.optional() });
5679
5681
  V({ autoRefresh: R().default(true), debounceMs: L().int().nonnegative().default(300) });
5680
- var Cm = xd(["debug", "info", "notice", "warning", "error", "critical", "alert", "emergency"]), wm = Pf.extend({ level: Cm }), Tm = q.extend({ method: W("logging/setLevel"), params: wm }), Em = Lf.extend({ level: Cm, logger: F().optional(), data: z() }), Dm = Rf.extend({ method: W("notifications/message"), params: Em }), Om = V({ hints: B(V({ name: F().optional() })).optional(), costPriority: L().min(0).max(1).optional(), speedPriority: L().min(0).max(1).optional(), intelligencePriority: L().min(0).max(1).optional() }), km = V({ mode: xd(["auto", "required", "none"]).optional() }), Am = V({ type: W("tool_result"), toolUseId: F().describe("The unique identifier for the corresponding tool call."), content: B(um).default([]), structuredContent: V({}).loose().optional(), isError: R().optional(), _meta: U(F(), z()).optional() }), jm = ld("type", [im, am, om]), Mm = ld("type", [im, am, om, sm, Am]), Nm = V({ role: Np, content: H([Mm, B(Mm)]), _meta: U(F(), z()).optional() }), Pm = Ff.extend({ messages: B(Nm), modelPreferences: Om.optional(), systemPrompt: F().optional(), includeContext: xd(["none", "thisServer", "allServers"]).optional(), temperature: L().optional(), maxTokens: L().int(), stopSequences: B(F()).optional(), metadata: K.optional(), tools: B(gm).optional(), toolChoice: km.optional() }), Fm = q.extend({ method: W("sampling/createMessage"), params: Pm }), Im = J.extend({ model: F(), stopReason: G(xd(["endTurn", "stopSequence", "maxTokens"]).or(F())), role: Np, content: jm }), Lm = J.extend({ model: F(), stopReason: G(xd(["endTurn", "stopSequence", "maxTokens", "toolUse"]).or(F())), role: Np, content: H([Mm, B(Mm)]) }), Rm = V({ type: W("boolean"), title: F().optional(), description: F().optional(), default: R().optional() }), zm = V({ type: W("string"), title: F().optional(), description: F().optional(), minLength: L().optional(), maxLength: L().optional(), format: xd(["email", "uri", "date", "date-time"]).optional(), default: F().optional() }), Bm = V({ type: xd(["number", "integer"]), title: F().optional(), description: F().optional(), minimum: L().optional(), maximum: L().optional(), default: L().optional() }), Vm = V({ type: W("string"), title: F().optional(), description: F().optional(), enum: B(F()), default: F().optional() }), Hm = V({ type: W("string"), title: F().optional(), description: F().optional(), oneOf: B(V({ const: F(), title: F() })), default: F().optional() }), Um = H([H([V({ type: W("string"), title: F().optional(), description: F().optional(), enum: B(F()), enumNames: B(F()).optional(), default: F().optional() }), H([Vm, Hm]), H([V({ type: W("array"), title: F().optional(), description: F().optional(), minItems: L().optional(), maxItems: L().optional(), items: V({ type: W("string"), enum: B(F()) }), default: B(F()).optional() }), V({ type: W("array"), title: F().optional(), description: F().optional(), minItems: L().optional(), maxItems: L().optional(), items: V({ anyOf: B(V({ const: F(), title: F() })) }), default: B(F()).optional() })])]), Rm, zm, Bm]), Wm = H([Ff.extend({ mode: W("form").optional(), message: F(), requestedSchema: V({ type: W("object"), properties: U(F(), Um), required: B(F()).optional() }) }), Ff.extend({ mode: W("url"), message: F(), elicitationId: F(), url: F().url() })]), Gm = q.extend({ method: W("elicitation/create"), params: Wm }), Km = Lf.extend({ elicitationId: F() }), qm = Rf.extend({ method: W("notifications/elicitation/complete"), params: Km }), Jm = J.extend({ action: xd(["accept", "decline", "cancel"]), content: hf((e4) => e4 === null ? void 0 : e4, U(F(), H([F(), L(), R(), B(F())])).optional()) }), Ym = V({ type: W("ref/resource"), uri: F() }), Xm = V({ type: W("ref/prompt"), name: F() }), Zm = Pf.extend({ ref: H([Xm, Ym]), argument: V({ name: F(), value: F() }), context: V({ arguments: U(F(), F()).optional() }).optional() }), Qm = q.extend({ method: W("completion/complete"), params: Zm }), $m = J.extend({ completion: od({ values: B(F()).max(100), total: G(L().int()), hasMore: G(R()) }) }), eh = V({ uri: F().startsWith("file://"), name: F().optional(), _meta: U(F(), z()).optional() }), th = q.extend({ method: W("roots/list"), params: Pf.optional() }), nh = J.extend({ roots: B(eh) }), rh = Rf.extend({ method: W("notifications/roots/list_changed"), params: Lf.optional() });
5681
- H([up, op, Qm, Tm, rm, em, Lp, zp, Up, qp, Yp, xm, _m, Sp, wp, Tp, Dp]), H([Zf, pp, lp, rh, xp]), H([Yf, Im, Lm, Jm, nh, Cp, Ep, yp]), H([up, Fm, Gm, th, Sp, wp, Tp, Dp]), H([Zf, pp, Dm, Zp, Gp, Sm, pm, xp, qm]), H([Yf, cp, $m, fm, tm, Rp, Bp, Wp, ym, vm, Cp, Ep, yp]);
5682
- var X = class e2 extends Error {
5682
+ var Tm = xd(["debug", "info", "notice", "warning", "error", "critical", "alert", "emergency"]), Em = Pf.extend({ level: Tm }), Dm = Lf.extend({ method: W("logging/setLevel"), params: Em }), Om = Rf.extend({ level: Tm, logger: F().optional(), data: z() }), km = zf.extend({ method: W("notifications/message"), params: Om }), Am = V({ hints: B(V({ name: F().optional() })).optional(), costPriority: L().min(0).max(1).optional(), speedPriority: L().min(0).max(1).optional(), intelligencePriority: L().min(0).max(1).optional() }), jm = V({ mode: xd(["auto", "required", "none"]).optional() }), Mm = V({ type: W("tool_result"), toolUseId: F().describe("The unique identifier for the corresponding tool call."), content: B(fm).default([]), structuredContent: V({}).loose().optional(), isError: R().optional(), _meta: U(F(), z()).optional() }), Nm = ld("type", [om, sm, cm]), Pm = ld("type", [om, sm, cm, lm, Mm]), Fm = V({ role: Fp, content: H([Pm, B(Pm)]), _meta: U(F(), z()).optional() }), Im = Ff.extend({ messages: B(Fm), modelPreferences: Am.optional(), systemPrompt: F().optional(), includeContext: xd(["none", "thisServer", "allServers"]).optional(), temperature: L().optional(), maxTokens: L().int(), stopSequences: B(F()).optional(), metadata: K.optional(), tools: B(vm).optional(), toolChoice: jm.optional() }), Lm = Lf.extend({ method: W("sampling/createMessage"), params: Im }), Rm = Bf.extend({ model: F(), stopReason: G(xd(["endTurn", "stopSequence", "maxTokens"]).or(F())), role: Fp, content: Nm }), zm = Bf.extend({ model: F(), stopReason: G(xd(["endTurn", "stopSequence", "maxTokens", "toolUse"]).or(F())), role: Fp, content: H([Pm, B(Pm)]) }), Bm = V({ type: W("boolean"), title: F().optional(), description: F().optional(), default: R().optional() }), Vm = V({ type: W("string"), title: F().optional(), description: F().optional(), minLength: L().optional(), maxLength: L().optional(), format: xd(["email", "uri", "date", "date-time"]).optional(), default: F().optional() }), Hm = V({ type: xd(["number", "integer"]), title: F().optional(), description: F().optional(), minimum: L().optional(), maximum: L().optional(), default: L().optional() }), Um = V({ type: W("string"), title: F().optional(), description: F().optional(), enum: B(F()), default: F().optional() }), Wm = V({ type: W("string"), title: F().optional(), description: F().optional(), oneOf: B(V({ const: F(), title: F() })), default: F().optional() }), Gm = H([H([V({ type: W("string"), title: F().optional(), description: F().optional(), enum: B(F()), enumNames: B(F()).optional(), default: F().optional() }), H([Um, Wm]), H([V({ type: W("array"), title: F().optional(), description: F().optional(), minItems: L().optional(), maxItems: L().optional(), items: V({ type: W("string"), enum: B(F()) }), default: B(F()).optional() }), V({ type: W("array"), title: F().optional(), description: F().optional(), minItems: L().optional(), maxItems: L().optional(), items: V({ anyOf: B(V({ const: F(), title: F() })) }), default: B(F()).optional() })])]), Bm, Vm, Hm]), Km = H([Ff.extend({ mode: W("form").optional(), message: F(), requestedSchema: V({ type: W("object"), properties: U(F(), Gm), required: B(F()).optional() }) }), Ff.extend({ mode: W("url"), message: F(), elicitationId: F(), url: F().url() })]), qm = Lf.extend({ method: W("elicitation/create"), params: Km }), Jm = Rf.extend({ elicitationId: F() }), Ym = zf.extend({ method: W("notifications/elicitation/complete"), params: Jm }), Xm = Bf.extend({ action: xd(["accept", "decline", "cancel"]), content: hf((e4) => e4 === null ? void 0 : e4, U(F(), H([F(), L(), R(), B(F())])).optional()) }), Zm = V({ type: W("ref/resource"), uri: F() }), Qm = V({ type: W("ref/prompt"), name: F() }), $m = Pf.extend({ ref: H([Qm, Zm]), argument: V({ name: F(), value: F() }), context: V({ arguments: U(F(), F()).optional() }).optional() }), eh = Lf.extend({ method: W("completion/complete"), params: $m }), th = Bf.extend({ completion: od({ values: B(F()).max(100), total: G(L().int()), hasMore: G(R()) }) }), nh = V({ uri: F().startsWith("file://"), name: F().optional(), _meta: U(F(), z()).optional() }), rh = Lf.extend({ method: W("roots/list"), params: Pf.optional() }), ih = Bf.extend({ roots: B(nh) }), ah = zf.extend({ method: W("notifications/roots/list_changed"), params: Rf.optional() });
5683
+ H([fp, cp, eh, Dm, am, nm, zp, Vp, Gp, Yp, Zp, Cm, ym, wp, Ep, Dp, kp]), H([$f, hp, dp, ah, Cp]), H([Zf, Rm, zm, Xm, ih, Tp, Op, xp]), H([fp, Lm, qm, rh, wp, Ep, Dp, kp]), H([$f, hp, km, $p, qp, wm, hm, Cp, Ym]), H([Zf, up, th, mm, rm, Bp, Hp, Kp, xm, bm, Tp, Op, xp]);
5684
+ var J = class e2 extends Error {
5683
5685
  constructor(e4, t2, n2) {
5684
5686
  super("MCP error ".concat(e4, ": ").concat(t2)), this.code = e4, this.data = n2, this.name = "McpError";
5685
5687
  }
5686
5688
  static fromError(t2, n2, r2) {
5687
- if (t2 === Y.UrlElicitationRequired && r2) {
5689
+ if (t2 === q.UrlElicitationRequired && r2) {
5688
5690
  let e4 = r2;
5689
- if (e4.elicitations) return new ih(e4.elicitations, n2);
5691
+ if (e4.elicitations) return new oh(e4.elicitations, n2);
5690
5692
  }
5691
5693
  return new e2(t2, n2, r2);
5692
5694
  }
5693
- }, ih = class extends X {
5695
+ }, oh = class extends J {
5694
5696
  constructor(e4, t2 = "URL elicitation".concat(e4.length > 1 ? "s" : "", " required")) {
5695
- super(Y.UrlElicitationRequired, t2, { elicitations: e4 });
5697
+ super(q.UrlElicitationRequired, t2, { elicitations: e4 });
5696
5698
  }
5697
5699
  get elicitations() {
5698
5700
  var e4, t2;
5699
5701
  return (e4 = (t2 = this.data) == null ? void 0 : t2.elicitations) == null ? [] : e4;
5700
5702
  }
5701
5703
  };
5702
- function ah(e4) {
5704
+ function sh(e4) {
5703
5705
  return e4 === "completed" || e4 === "failed" || e4 === "cancelled";
5704
5706
  }
5705
- function oh(e4) {
5707
+ function ch(e4) {
5706
5708
  let t2 = al(e4), n2 = t2 == null ? void 0 : t2.method;
5707
5709
  if (!n2) throw Error("Schema is missing a method literal");
5708
5710
  let r2 = ol(n2);
5709
5711
  if (typeof r2 != "string") throw Error("Schema method literal must be a string");
5710
5712
  return r2;
5711
5713
  }
5712
- function sh(e4, t2) {
5714
+ function lh(e4, t2) {
5713
5715
  let n2 = il(e4, t2);
5714
5716
  if (!n2.success) throw n2.error;
5715
5717
  return n2.data;
5716
5718
  }
5717
- var ch = 6e4, lh = class {
5719
+ var uh = 6e4, dh = class {
5718
5720
  constructor(e4) {
5719
- this._options = e4, this._requestMessageId = 0, this._requestHandlers = /* @__PURE__ */ new Map(), this._requestHandlerAbortControllers = /* @__PURE__ */ new Map(), this._notificationHandlers = /* @__PURE__ */ new Map(), this._responseHandlers = /* @__PURE__ */ new Map(), this._progressHandlers = /* @__PURE__ */ new Map(), this._timeoutInfo = /* @__PURE__ */ new Map(), this._pendingDebouncedNotifications = /* @__PURE__ */ new Set(), this._taskProgressTokens = /* @__PURE__ */ new Map(), this._requestResolvers = /* @__PURE__ */ new Map(), this.setNotificationHandler(Zf, (e5) => {
5721
+ this._options = e4, this._requestMessageId = 0, this._requestHandlers = /* @__PURE__ */ new Map(), this._requestHandlerAbortControllers = /* @__PURE__ */ new Map(), this._notificationHandlers = /* @__PURE__ */ new Map(), this._responseHandlers = /* @__PURE__ */ new Map(), this._progressHandlers = /* @__PURE__ */ new Map(), this._timeoutInfo = /* @__PURE__ */ new Map(), this._pendingDebouncedNotifications = /* @__PURE__ */ new Set(), this._taskProgressTokens = /* @__PURE__ */ new Map(), this._requestResolvers = /* @__PURE__ */ new Map(), this.setNotificationHandler($f, (e5) => {
5720
5722
  this._oncancel(e5);
5721
- }), this.setNotificationHandler(pp, (e5) => {
5723
+ }), this.setNotificationHandler(hp, (e5) => {
5722
5724
  this._onprogress(e5);
5723
- }), this.setRequestHandler(up, (e5) => ({})), this._taskStore = e4 == null ? void 0 : e4.taskStore, this._taskMessageQueue = e4 == null ? void 0 : e4.taskMessageQueue, this._taskStore && (this.setRequestHandler(Sp, async (e5, t2) => {
5725
+ }), this.setRequestHandler(fp, (e5) => ({})), this._taskStore = e4 == null ? void 0 : e4.taskStore, this._taskMessageQueue = e4 == null ? void 0 : e4.taskMessageQueue, this._taskStore && (this.setRequestHandler(wp, async (e5, t2) => {
5724
5726
  let n2 = await this._taskStore.getTask(e5.params.taskId, t2.sessionId);
5725
- if (!n2) throw new X(Y.InvalidParams, "Failed to retrieve task: Task not found");
5727
+ if (!n2) throw new J(q.InvalidParams, "Failed to retrieve task: Task not found");
5726
5728
  return { ...n2 };
5727
- }), this.setRequestHandler(wp, async (e5, t2) => {
5729
+ }), this.setRequestHandler(Ep, async (e5, t2) => {
5728
5730
  let n2 = async () => {
5729
5731
  let r2 = e5.params.taskId;
5730
5732
  if (this._taskMessageQueue) {
@@ -5736,7 +5738,7 @@ var ch = 6e4, lh = class {
5736
5738
  if (r3) if (this._requestResolvers.delete(n3), e6.type === "response") r3(t3);
5737
5739
  else {
5738
5740
  let e7 = t3;
5739
- r3(new X(e7.error.code, e7.error.message, e7.error.data));
5741
+ r3(new J(e7.error.code, e7.error.message, e7.error.data));
5740
5742
  }
5741
5743
  else {
5742
5744
  let t4 = e6.type === "response" ? "Response" : "Error";
@@ -5748,34 +5750,34 @@ var ch = 6e4, lh = class {
5748
5750
  }
5749
5751
  }
5750
5752
  let a2 = await this._taskStore.getTask(r2, t2.sessionId);
5751
- if (!a2) throw new X(Y.InvalidParams, "Task not found: ".concat(r2));
5752
- if (!ah(a2.status)) return await this._waitForTaskUpdate(r2, t2.signal), await n2();
5753
- if (ah(a2.status)) {
5753
+ if (!a2) throw new J(q.InvalidParams, "Task not found: ".concat(r2));
5754
+ if (!sh(a2.status)) return await this._waitForTaskUpdate(r2, t2.signal), await n2();
5755
+ if (sh(a2.status)) {
5754
5756
  let e6 = await this._taskStore.getTaskResult(r2, t2.sessionId);
5755
5757
  return this._clearTaskQueue(r2), { ...e6, _meta: { ...e6._meta, [Of]: { taskId: r2 } } };
5756
5758
  }
5757
5759
  return await n2();
5758
5760
  };
5759
5761
  return await n2();
5760
- }), this.setRequestHandler(Tp, async (e5, t2) => {
5762
+ }), this.setRequestHandler(Dp, async (e5, t2) => {
5761
5763
  try {
5762
5764
  var n2;
5763
5765
  let { tasks: r2, nextCursor: i2 } = await this._taskStore.listTasks((n2 = e5.params) == null ? void 0 : n2.cursor, t2.sessionId);
5764
5766
  return { tasks: r2, nextCursor: i2, _meta: {} };
5765
5767
  } catch (e6) {
5766
- throw new X(Y.InvalidParams, "Failed to list tasks: ".concat(e6 instanceof Error ? e6.message : String(e6)));
5768
+ throw new J(q.InvalidParams, "Failed to list tasks: ".concat(e6 instanceof Error ? e6.message : String(e6)));
5767
5769
  }
5768
- }), this.setRequestHandler(Dp, async (e5, t2) => {
5770
+ }), this.setRequestHandler(kp, async (e5, t2) => {
5769
5771
  try {
5770
5772
  let n2 = await this._taskStore.getTask(e5.params.taskId, t2.sessionId);
5771
- if (!n2) throw new X(Y.InvalidParams, "Task not found: ".concat(e5.params.taskId));
5772
- if (ah(n2.status)) throw new X(Y.InvalidParams, "Cannot cancel task in terminal status: ".concat(n2.status));
5773
+ if (!n2) throw new J(q.InvalidParams, "Task not found: ".concat(e5.params.taskId));
5774
+ if (sh(n2.status)) throw new J(q.InvalidParams, "Cannot cancel task in terminal status: ".concat(n2.status));
5773
5775
  await this._taskStore.updateTaskStatus(e5.params.taskId, "cancelled", "Client cancelled task execution.", t2.sessionId), this._clearTaskQueue(e5.params.taskId);
5774
5776
  let r2 = await this._taskStore.getTask(e5.params.taskId, t2.sessionId);
5775
- if (!r2) throw new X(Y.InvalidParams, "Task not found after cancellation: ".concat(e5.params.taskId));
5777
+ if (!r2) throw new J(q.InvalidParams, "Task not found after cancellation: ".concat(e5.params.taskId));
5776
5778
  return { _meta: {}, ...r2 };
5777
5779
  } catch (e6) {
5778
- throw e6 instanceof X ? e6 : new X(Y.InvalidRequest, "Failed to cancel task: ".concat(e6 instanceof Error ? e6.message : String(e6)));
5780
+ throw e6 instanceof J ? e6 : new J(q.InvalidRequest, "Failed to cancel task: ".concat(e6 instanceof Error ? e6.message : String(e6)));
5779
5781
  }
5780
5782
  }));
5781
5783
  }
@@ -5791,7 +5793,7 @@ var ch = 6e4, lh = class {
5791
5793
  let t2 = this._timeoutInfo.get(e4);
5792
5794
  if (!t2) return false;
5793
5795
  let n2 = Date.now() - t2.startTime;
5794
- if (t2.maxTotalTimeout && n2 >= t2.maxTotalTimeout) throw this._timeoutInfo.delete(e4), X.fromError(Y.RequestTimeout, "Maximum total timeout exceeded", { maxTotalTimeout: t2.maxTotalTimeout, totalElapsed: n2 });
5796
+ if (t2.maxTotalTimeout && n2 >= t2.maxTotalTimeout) throw this._timeoutInfo.delete(e4), J.fromError(q.RequestTimeout, "Maximum total timeout exceeded", { maxTotalTimeout: t2.maxTotalTimeout, totalElapsed: n2 });
5795
5797
  return clearTimeout(t2.timeoutId), t2.timeoutId = setTimeout(t2.onTimeout, t2.timeout), true;
5796
5798
  }
5797
5799
  _cleanupTimeout(e4) {
@@ -5812,7 +5814,7 @@ var ch = 6e4, lh = class {
5812
5814
  };
5813
5815
  let o2 = (r2 = this._transport) == null ? void 0 : r2.onmessage;
5814
5816
  this._transport.onmessage = (e5, t3) => {
5815
- o2 == null || o2(e5, t3), Gf(e5) || qf(e5) ? this._onresponse(e5) : Vf(e5) ? this._onrequest(e5, t3) : Uf(e5) ? this._onnotification(e5) : this._onerror(Error("Unknown message type: ".concat(JSON.stringify(e5))));
5817
+ o2 == null || o2(e5, t3), qf(e5) || Yf(e5) ? this._onresponse(e5) : Uf(e5) ? this._onrequest(e5, t3) : Gf(e5) ? this._onnotification(e5) : this._onerror(Error("Unknown message type: ".concat(JSON.stringify(e5))));
5816
5818
  }, await this._transport.start();
5817
5819
  }
5818
5820
  _onclose() {
@@ -5823,7 +5825,7 @@ var ch = 6e4, lh = class {
5823
5825
  this._timeoutInfo.clear();
5824
5826
  for (let e5 of this._requestHandlerAbortControllers.values()) e5.abort();
5825
5827
  this._requestHandlerAbortControllers.clear();
5826
- let n2 = X.fromError(Y.ConnectionClosed, "Connection closed");
5828
+ let n2 = J.fromError(q.ConnectionClosed, "Connection closed");
5827
5829
  this._transport = void 0, (e4 = this.onclose) == null || e4.call(this);
5828
5830
  for (let e5 of t2.values()) e5(n2);
5829
5831
  }
@@ -5840,7 +5842,7 @@ var ch = 6e4, lh = class {
5840
5842
  var n2, r2, i2;
5841
5843
  let a2 = (n2 = this._requestHandlers.get(e4.method)) == null ? this.fallbackRequestHandler : n2, o2 = this._transport, s2 = (r2 = e4.params) == null || (r2 = r2._meta) == null || (r2 = r2["io.modelcontextprotocol/related-task"]) == null ? void 0 : r2.taskId;
5842
5844
  if (a2 === void 0) {
5843
- let t3 = { jsonrpc: "2.0", id: e4.id, error: { code: Y.MethodNotFound, message: "Method not found" } };
5845
+ let t3 = { jsonrpc: "2.0", id: e4.id, error: { code: q.MethodNotFound, message: "Method not found" } };
5844
5846
  s2 && this._taskMessageQueue ? this._enqueueTaskMessage(s2, { type: "error", message: t3, timestamp: Date.now() }, o2 == null ? void 0 : o2.sessionId).catch((e5) => this._onerror(Error("Failed to enqueue error response: ".concat(e5)))) : o2 == null || o2.send(t3).catch((e5) => this._onerror(Error("Failed to send an error response: ".concat(e5))));
5845
5847
  return;
5846
5848
  }
@@ -5852,7 +5854,7 @@ var ch = 6e4, lh = class {
5852
5854
  s2 && (n3.relatedTask = { taskId: s2 }), await this.notification(t3, n3);
5853
5855
  }, sendRequest: async (t3, n3, r3) => {
5854
5856
  var i3, a3;
5855
- if (c2.signal.aborted) throw new X(Y.ConnectionClosed, "Request was cancelled");
5857
+ if (c2.signal.aborted) throw new J(q.ConnectionClosed, "Request was cancelled");
5856
5858
  let o3 = { ...r3, relatedRequestId: e4.id };
5857
5859
  s2 && !o3.relatedTask && (o3.relatedTask = { taskId: s2 });
5858
5860
  let l3 = (i3 = (a3 = o3.relatedTask) == null ? void 0 : a3.taskId) == null ? s2 : i3;
@@ -5867,7 +5869,7 @@ var ch = 6e4, lh = class {
5867
5869
  }, async (t3) => {
5868
5870
  var n3;
5869
5871
  if (c2.signal.aborted) return;
5870
- let r3 = { jsonrpc: "2.0", id: e4.id, error: { code: Number.isSafeInteger(t3.code) ? t3.code : Y.InternalError, message: (n3 = t3.message) == null ? "Internal error" : n3, ...t3.data !== void 0 && { data: t3.data } } };
5872
+ let r3 = { jsonrpc: "2.0", id: e4.id, error: { code: Number.isSafeInteger(t3.code) ? t3.code : q.InternalError, message: (n3 = t3.message) == null ? "Internal error" : n3, ...t3.data !== void 0 && { data: t3.data } } };
5871
5873
  s2 && this._taskMessageQueue ? await this._enqueueTaskMessage(s2, { type: "error", message: r3, timestamp: Date.now() }, o2 == null ? void 0 : o2.sessionId) : await (o2 == null ? void 0 : o2.send(r3));
5872
5874
  }).catch((e5) => this._onerror(Error("Failed to send response: ".concat(e5)))).finally(() => {
5873
5875
  this._requestHandlerAbortControllers.get(e4.id) === c2 && this._requestHandlerAbortControllers.delete(e4.id);
@@ -5891,7 +5893,7 @@ var ch = 6e4, lh = class {
5891
5893
  _onresponse(e4) {
5892
5894
  let t2 = Number(e4.id), n2 = this._requestResolvers.get(t2);
5893
5895
  if (n2) {
5894
- this._requestResolvers.delete(t2), Gf(e4) ? n2(e4) : n2(new X(e4.error.code, e4.error.message, e4.error.data));
5896
+ this._requestResolvers.delete(t2), qf(e4) ? n2(e4) : n2(new J(e4.error.code, e4.error.message, e4.error.data));
5895
5897
  return;
5896
5898
  }
5897
5899
  let r2 = this._responseHandlers.get(t2);
@@ -5901,14 +5903,14 @@ var ch = 6e4, lh = class {
5901
5903
  }
5902
5904
  this._responseHandlers.delete(t2), this._cleanupTimeout(t2);
5903
5905
  let i2 = false;
5904
- if (Gf(e4) && e4.result && typeof e4.result == "object") {
5906
+ if (qf(e4) && e4.result && typeof e4.result == "object") {
5905
5907
  let n3 = e4.result;
5906
5908
  if (n3.task && typeof n3.task == "object") {
5907
5909
  let e5 = n3.task;
5908
5910
  typeof e5.taskId == "string" && (i2 = true, this._taskProgressTokens.set(e5.taskId, t2));
5909
5911
  }
5910
5912
  }
5911
- i2 || this._progressHandlers.delete(t2), Gf(e4) ? r2(e4) : r2(X.fromError(e4.error.code, e4.error.message, e4.error.data));
5913
+ i2 || this._progressHandlers.delete(t2), qf(e4) ? r2(e4) : r2(J.fromError(e4.error.code, e4.error.message, e4.error.data));
5912
5914
  }
5913
5915
  get transport() {
5914
5916
  return this._transport;
@@ -5923,20 +5925,20 @@ var ch = 6e4, lh = class {
5923
5925
  try {
5924
5926
  yield { type: "result", result: await this.request(e4, t2, n2) };
5925
5927
  } catch (e5) {
5926
- yield { type: "error", error: e5 instanceof X ? e5 : new X(Y.InternalError, String(e5)) };
5928
+ yield { type: "error", error: e5 instanceof J ? e5 : new J(q.InternalError, String(e5)) };
5927
5929
  }
5928
5930
  return;
5929
5931
  }
5930
5932
  let i2;
5931
5933
  try {
5932
- let r3 = await this.request(e4, yp, n2);
5934
+ let r3 = await this.request(e4, xp, n2);
5933
5935
  if (r3.task) i2 = r3.task.taskId, yield { type: "taskCreated", task: r3.task };
5934
- else throw new X(Y.InternalError, "Task creation did not return a task");
5936
+ else throw new J(q.InternalError, "Task creation did not return a task");
5935
5937
  for (; ; ) {
5936
5938
  var a2, o2, s2, c2;
5937
5939
  let e5 = await this.getTask({ taskId: i2 }, n2);
5938
- if (yield { type: "taskStatus", task: e5 }, ah(e5.status)) {
5939
- e5.status === "completed" ? yield { type: "result", result: await this.getTaskResult({ taskId: i2 }, t2, n2) } : e5.status === "failed" ? yield { type: "error", error: new X(Y.InternalError, "Task ".concat(i2, " failed")) } : e5.status === "cancelled" && (yield { type: "error", error: new X(Y.InternalError, "Task ".concat(i2, " was cancelled")) });
5940
+ if (yield { type: "taskStatus", task: e5 }, sh(e5.status)) {
5941
+ e5.status === "completed" ? yield { type: "result", result: await this.getTaskResult({ taskId: i2 }, t2, n2) } : e5.status === "failed" ? yield { type: "error", error: new J(q.InternalError, "Task ".concat(i2, " failed")) } : e5.status === "cancelled" && (yield { type: "error", error: new J(q.InternalError, "Task ".concat(i2, " was cancelled")) });
5940
5942
  return;
5941
5943
  }
5942
5944
  if (e5.status === "input_required") {
@@ -5947,7 +5949,7 @@ var ch = 6e4, lh = class {
5947
5949
  await new Promise((e6) => setTimeout(e6, r4)), n2 == null || (c2 = n2.signal) == null || c2.throwIfAborted();
5948
5950
  }
5949
5951
  } catch (e5) {
5950
- yield { type: "error", error: e5 instanceof X ? e5 : new X(Y.InternalError, String(e5)) };
5952
+ yield { type: "error", error: e5 instanceof J ? e5 : new J(q.InternalError, String(e5)) };
5951
5953
  }
5952
5954
  }
5953
5955
  request(e4, t2, n2) {
@@ -5979,7 +5981,7 @@ var ch = 6e4, lh = class {
5979
5981
  }
5980
5982
  let b2 = (e5) => {
5981
5983
  var t3;
5982
- this._responseHandlers.delete(g2), this._progressHandlers.delete(g2), this._cleanupTimeout(g2), (t3 = this._transport) == null || t3.send({ jsonrpc: "2.0", method: "notifications/cancelled", params: { requestId: g2, reason: String(e5) } }, { relatedRequestId: r2, resumptionToken: i2, onresumptiontoken: a2 }).catch((e6) => this._onerror(Error("Failed to send cancellation: ".concat(e6)))), l2(e5 instanceof X ? e5 : new X(Y.RequestTimeout, String(e5)));
5984
+ this._responseHandlers.delete(g2), this._progressHandlers.delete(g2), this._cleanupTimeout(g2), (t3 = this._transport) == null || t3.send({ jsonrpc: "2.0", method: "notifications/cancelled", params: { requestId: g2, reason: String(e5) } }, { relatedRequestId: r2, resumptionToken: i2, onresumptiontoken: a2 }).catch((e6) => this._onerror(Error("Failed to send cancellation: ".concat(e6)))), l2(e5 instanceof J ? e5 : new J(q.RequestTimeout, String(e5)));
5983
5985
  };
5984
5986
  this._responseHandlers.set(g2, (e5) => {
5985
5987
  var r3;
@@ -5996,8 +5998,8 @@ var ch = 6e4, lh = class {
5996
5998
  var e5;
5997
5999
  b2(n2 == null || (e5 = n2.signal) == null ? void 0 : e5.reason);
5998
6000
  });
5999
- let x2 = (p2 = n2 == null ? void 0 : n2.timeout) == null ? ch : p2;
6000
- this._setupTimeout(g2, x2, n2 == null ? void 0 : n2.maxTotalTimeout, () => b2(X.fromError(Y.RequestTimeout, "Request timed out", { timeout: x2 })), (m2 = n2 == null ? void 0 : n2.resetTimeoutOnProgress) == null ? false : m2);
6001
+ let x2 = (p2 = n2 == null ? void 0 : n2.timeout) == null ? uh : p2;
6002
+ this._setupTimeout(g2, x2, n2 == null ? void 0 : n2.maxTotalTimeout, () => b2(J.fromError(q.RequestTimeout, "Request timed out", { timeout: x2 })), (m2 = n2 == null ? void 0 : n2.resetTimeoutOnProgress) == null ? false : m2);
6001
6003
  let S2 = s2 == null ? void 0 : s2.taskId;
6002
6004
  S2 ? (this._requestResolvers.set(g2, (e5) => {
6003
6005
  let t3 = this._responseHandlers.get(g2);
@@ -6010,16 +6012,16 @@ var ch = 6e4, lh = class {
6010
6012
  });
6011
6013
  }
6012
6014
  async getTask(e4, t2) {
6013
- return this.request({ method: "tasks/get", params: e4 }, Cp, t2);
6015
+ return this.request({ method: "tasks/get", params: e4 }, Tp, t2);
6014
6016
  }
6015
6017
  async getTaskResult(e4, t2, n2) {
6016
6018
  return this.request({ method: "tasks/result", params: e4 }, t2, n2);
6017
6019
  }
6018
6020
  async listTasks(e4, t2) {
6019
- return this.request({ method: "tasks/list", params: e4 }, Ep, t2);
6021
+ return this.request({ method: "tasks/list", params: e4 }, Op, t2);
6020
6022
  }
6021
6023
  async cancelTask(e4, t2) {
6022
- return this.request({ method: "tasks/cancel", params: e4 }, Op, t2);
6024
+ return this.request({ method: "tasks/cancel", params: e4 }, Ap, t2);
6023
6025
  }
6024
6026
  async notification(e4, t2) {
6025
6027
  var n2, r2, i2;
@@ -6054,9 +6056,9 @@ var ch = 6e4, lh = class {
6054
6056
  await this._transport.send(s2, t2);
6055
6057
  }
6056
6058
  setRequestHandler(e4, t2) {
6057
- let n2 = oh(e4);
6059
+ let n2 = ch(e4);
6058
6060
  this.assertRequestHandlerCapability(n2), this._requestHandlers.set(n2, (n3, r2) => {
6059
- let i2 = sh(e4, n3);
6061
+ let i2 = lh(e4, n3);
6060
6062
  return Promise.resolve(t2(i2, r2));
6061
6063
  });
6062
6064
  }
@@ -6067,9 +6069,9 @@ var ch = 6e4, lh = class {
6067
6069
  if (this._requestHandlers.has(e4)) throw Error("A request handler for ".concat(e4, " already exists, which would be overridden"));
6068
6070
  }
6069
6071
  setNotificationHandler(e4, t2) {
6070
- let n2 = oh(e4);
6072
+ let n2 = ch(e4);
6071
6073
  this._notificationHandlers.set(n2, (n3) => {
6072
- let r2 = sh(e4, n3);
6074
+ let r2 = lh(e4, n3);
6073
6075
  return Promise.resolve(t2(r2));
6074
6076
  });
6075
6077
  }
@@ -6089,9 +6091,9 @@ var ch = 6e4, lh = class {
6089
6091
  async _clearTaskQueue(e4, t2) {
6090
6092
  if (this._taskMessageQueue) {
6091
6093
  let n2 = await this._taskMessageQueue.dequeueAll(e4, t2);
6092
- for (let t3 of n2) if (t3.type === "request" && Vf(t3.message)) {
6094
+ for (let t3 of n2) if (t3.type === "request" && Uf(t3.message)) {
6093
6095
  let n3 = t3.message.id, r2 = this._requestResolvers.get(n3);
6094
- r2 ? (r2(new X(Y.InternalError, "Task cancelled or completed")), this._requestResolvers.delete(n3)) : this._onerror(Error("Resolver missing for request ".concat(n3, " during task ").concat(e4, " cleanup")));
6096
+ r2 ? (r2(new J(q.InternalError, "Task cancelled or completed")), this._requestResolvers.delete(n3)) : this._onerror(Error("Resolver missing for request ".concat(n3, " during task ").concat(e4, " cleanup")));
6095
6097
  }
6096
6098
  }
6097
6099
  }
@@ -6106,12 +6108,12 @@ var ch = 6e4, lh = class {
6106
6108
  }
6107
6109
  return new Promise((e5, n3) => {
6108
6110
  if (t2.aborted) {
6109
- n3(new X(Y.InvalidRequest, "Request cancelled"));
6111
+ n3(new J(q.InvalidRequest, "Request cancelled"));
6110
6112
  return;
6111
6113
  }
6112
6114
  let r3 = setTimeout(e5, i2);
6113
6115
  t2.addEventListener("abort", () => {
6114
- clearTimeout(r3), n3(new X(Y.InvalidRequest, "Request cancelled"));
6116
+ clearTimeout(r3), n3(new J(q.InvalidRequest, "Request cancelled"));
6115
6117
  }, { once: true });
6116
6118
  });
6117
6119
  }
@@ -6123,44 +6125,44 @@ var ch = 6e4, lh = class {
6123
6125
  return await n2.createTask(r2, e4.id, { method: e4.method, params: e4.params }, t2);
6124
6126
  }, getTask: async (e5) => {
6125
6127
  let r2 = await n2.getTask(e5, t2);
6126
- if (!r2) throw new X(Y.InvalidParams, "Failed to retrieve task: Task not found");
6128
+ if (!r2) throw new J(q.InvalidParams, "Failed to retrieve task: Task not found");
6127
6129
  return r2;
6128
6130
  }, storeTaskResult: async (e5, r2, i2) => {
6129
6131
  await n2.storeTaskResult(e5, r2, i2, t2);
6130
6132
  let a2 = await n2.getTask(e5, t2);
6131
6133
  if (a2) {
6132
- let t3 = xp.parse({ method: "notifications/tasks/status", params: a2 });
6133
- await this.notification(t3), ah(a2.status) && this._cleanupTaskProgressHandler(e5);
6134
+ let t3 = Cp.parse({ method: "notifications/tasks/status", params: a2 });
6135
+ await this.notification(t3), sh(a2.status) && this._cleanupTaskProgressHandler(e5);
6134
6136
  }
6135
6137
  }, getTaskResult: (e5) => n2.getTaskResult(e5, t2), updateTaskStatus: async (e5, r2, i2) => {
6136
6138
  let a2 = await n2.getTask(e5, t2);
6137
- if (!a2) throw new X(Y.InvalidParams, 'Task "'.concat(e5, '" not found - it may have been cleaned up'));
6138
- if (ah(a2.status)) throw new X(Y.InvalidParams, 'Cannot update task "'.concat(e5, '" from terminal status "').concat(a2.status, '" to "').concat(r2, '". Terminal states (completed, failed, cancelled) cannot transition to other states.'));
6139
+ if (!a2) throw new J(q.InvalidParams, 'Task "'.concat(e5, '" not found - it may have been cleaned up'));
6140
+ if (sh(a2.status)) throw new J(q.InvalidParams, 'Cannot update task "'.concat(e5, '" from terminal status "').concat(a2.status, '" to "').concat(r2, '". Terminal states (completed, failed, cancelled) cannot transition to other states.'));
6139
6141
  await n2.updateTaskStatus(e5, r2, i2, t2);
6140
6142
  let o2 = await n2.getTask(e5, t2);
6141
6143
  if (o2) {
6142
- let t3 = xp.parse({ method: "notifications/tasks/status", params: o2 });
6143
- await this.notification(t3), ah(o2.status) && this._cleanupTaskProgressHandler(e5);
6144
+ let t3 = Cp.parse({ method: "notifications/tasks/status", params: o2 });
6145
+ await this.notification(t3), sh(o2.status) && this._cleanupTaskProgressHandler(e5);
6144
6146
  }
6145
6147
  }, listTasks: (e5) => n2.listTasks(e5, t2) };
6146
6148
  }
6147
6149
  };
6148
- function uh(e4) {
6150
+ function fh(e4) {
6149
6151
  return typeof e4 == "object" && !!e4 && !Array.isArray(e4);
6150
6152
  }
6151
- function dh(e4, t2) {
6153
+ function ph(e4, t2) {
6152
6154
  let n2 = { ...e4 };
6153
6155
  for (let e5 in t2) {
6154
6156
  let r2 = e5, i2 = t2[r2];
6155
6157
  if (i2 === void 0) continue;
6156
6158
  let a2 = n2[r2];
6157
- uh(a2) && uh(i2) ? n2[r2] = { ...a2, ...i2 } : n2[r2] = i2;
6159
+ fh(a2) && fh(i2) ? n2[r2] = { ...a2, ...i2 } : n2[r2] = i2;
6158
6160
  }
6159
6161
  return n2;
6160
6162
  }
6161
- var fh = "modulepreload", ph = function(e4) {
6163
+ var mh = "modulepreload", hh = function(e4) {
6162
6164
  return "/" + e4;
6163
- }, mh = {}, hh = function(e4, t2, n2) {
6165
+ }, gh = {}, _h = function(e4, t2, n2) {
6164
6166
  let r2 = Promise.resolve();
6165
6167
  if (t2 && t2.length > 0) {
6166
6168
  let o3 = function(e6) {
@@ -6169,8 +6171,8 @@ var fh = "modulepreload", ph = function(e4) {
6169
6171
  var o2 = o3;
6170
6172
  let e5 = document.getElementsByTagName("link"), i3 = document.querySelector("meta[property=csp-nonce]"), a2 = (i3 == null ? void 0 : i3.nonce) || (i3 == null ? void 0 : i3.getAttribute("nonce"));
6171
6173
  r2 = o3(t2.map((t3) => {
6172
- if (t3 = ph(t3, n2), t3 in mh) return;
6173
- mh[t3] = true;
6174
+ if (t3 = hh(t3, n2), t3 in gh) return;
6175
+ gh[t3] = true;
6174
6176
  let r3 = t3.endsWith(".css"), i4 = r3 ? '[rel="stylesheet"]' : "";
6175
6177
  if (n2) for (let n3 = e5.length - 1; n3 >= 0; n3--) {
6176
6178
  let i5 = e5[n3];
@@ -6178,7 +6180,7 @@ var fh = "modulepreload", ph = function(e4) {
6178
6180
  }
6179
6181
  else if (document.querySelector('link[href="'.concat(t3, '"]').concat(i4))) return;
6180
6182
  let o4 = document.createElement("link");
6181
- if (o4.rel = r3 ? "stylesheet" : fh, r3 || (o4.as = "script"), o4.crossOrigin = "", o4.href = t3, a2 && o4.setAttribute("nonce", a2), document.head.appendChild(o4), r3) return new Promise((e6, n3) => {
6183
+ if (o4.rel = r3 ? "stylesheet" : mh, r3 || (o4.as = "script"), o4.crossOrigin = "", o4.href = t3, a2 && o4.setAttribute("nonce", a2), document.head.appendChild(o4), r3) return new Promise((e6, n3) => {
6182
6184
  o4.addEventListener("load", e6), o4.addEventListener("error", () => n3(Error("Unable to preload CSS for ".concat(t3))));
6183
6185
  });
6184
6186
  }));
@@ -6196,7 +6198,7 @@ var fh = "modulepreload", ph = function(e4) {
6196
6198
  if (typeof n < "u") return n.apply(this, arguments);
6197
6199
  throw Error('Dynamic require of "' + e4 + '" is not supported');
6198
6200
  });
6199
- var gh = class extends lh {
6201
+ var vh = class extends dh {
6200
6202
  constructor(...e4) {
6201
6203
  super(...e4), o(this, "_registeredMethods", /* @__PURE__ */ new Set()), o(this, "_eventSlots", /* @__PURE__ */ new Map()), o(this, "setRequestHandler", (e5, t2) => {
6202
6204
  this._assertMethodNotRegistered(e5, "setRequestHandler"), super.setRequestHandler(e5, t2);
@@ -6252,7 +6254,7 @@ var gh = class extends lh {
6252
6254
  if (this._registeredMethods.has(n2)) throw Error('Handler for "'.concat(n2, '" already registered (via ').concat(t2, "). Use addEventListener() to attach multiple listeners, or the on* setter for replace semantics."));
6253
6255
  this._registeredMethods.add(n2);
6254
6256
  }
6255
- }, _h = "2026-01-26", vh = class {
6257
+ }, yh = "2026-01-26", bh = class {
6256
6258
  constructor(e4 = window.parent, t2) {
6257
6259
  o(this, "eventTarget", void 0), o(this, "eventSource", void 0), o(this, "messageListener", void 0), o(this, "onclose", void 0), o(this, "onerror", void 0), o(this, "onmessage", void 0), o(this, "sessionId", void 0), o(this, "setProtocolVersion", void 0), this.eventTarget = e4, this.eventSource = t2, this.messageListener = (e5) => {
6258
6260
  var n2, r2, i2;
@@ -6260,7 +6262,7 @@ var gh = class extends lh {
6260
6262
  console.debug("Ignoring message from unknown source", e5);
6261
6263
  return;
6262
6264
  }
6263
- let a2 = Jf.safeParse(e5.data);
6265
+ let a2 = Xf.safeParse(e5.data);
6264
6266
  a2.success ? (console.debug("Parsed message", a2.data), (n2 = this.onmessage) == null || n2.call(this, a2.data)) : ((r2 = e5.data) == null ? void 0 : r2.jsonrpc) === "2.0" ? (console.error("Failed to parse message", a2.error.message, e5), (i2 = this.onerror) == null || i2.call(this, Error("Invalid JSON-RPC message received: " + a2.error.message))) : console.debug("Ignoring non-JSON-RPC message", a2.error.message, e5);
6265
6267
  };
6266
6268
  }
@@ -6274,28 +6276,28 @@ var gh = class extends lh {
6274
6276
  var e4;
6275
6277
  window.removeEventListener("message", this.messageListener), (e4 = this.onclose) == null || e4.call(this);
6276
6278
  }
6277
- }, yh = H([W("light"), W("dark")]).describe("Color theme preference for the host environment."), bh = H([W("inline"), W("fullscreen"), W("pip")]).describe("Display mode for UI presentation."), xh = U(H([W("--color-background-primary"), W("--color-background-secondary"), W("--color-background-tertiary"), W("--color-background-inverse"), W("--color-background-ghost"), W("--color-background-info"), W("--color-background-danger"), W("--color-background-success"), W("--color-background-warning"), W("--color-background-disabled"), W("--color-text-primary"), W("--color-text-secondary"), W("--color-text-tertiary"), W("--color-text-inverse"), W("--color-text-ghost"), W("--color-text-info"), W("--color-text-danger"), W("--color-text-success"), W("--color-text-warning"), W("--color-text-disabled"), W("--color-border-primary"), W("--color-border-secondary"), W("--color-border-tertiary"), W("--color-border-inverse"), W("--color-border-ghost"), W("--color-border-info"), W("--color-border-danger"), W("--color-border-success"), W("--color-border-warning"), W("--color-border-disabled"), W("--color-ring-primary"), W("--color-ring-secondary"), W("--color-ring-inverse"), W("--color-ring-info"), W("--color-ring-danger"), W("--color-ring-success"), W("--color-ring-warning"), W("--font-sans"), W("--font-mono"), W("--font-weight-normal"), W("--font-weight-medium"), W("--font-weight-semibold"), W("--font-weight-bold"), W("--font-text-xs-size"), W("--font-text-sm-size"), W("--font-text-md-size"), W("--font-text-lg-size"), W("--font-heading-xs-size"), W("--font-heading-sm-size"), W("--font-heading-md-size"), W("--font-heading-lg-size"), W("--font-heading-xl-size"), W("--font-heading-2xl-size"), W("--font-heading-3xl-size"), W("--font-text-xs-line-height"), W("--font-text-sm-line-height"), W("--font-text-md-line-height"), W("--font-text-lg-line-height"), W("--font-heading-xs-line-height"), W("--font-heading-sm-line-height"), W("--font-heading-md-line-height"), W("--font-heading-lg-line-height"), W("--font-heading-xl-line-height"), W("--font-heading-2xl-line-height"), W("--font-heading-3xl-line-height"), W("--border-radius-xs"), W("--border-radius-sm"), W("--border-radius-md"), W("--border-radius-lg"), W("--border-radius-xl"), W("--border-radius-full"), W("--border-width-regular"), W("--shadow-hairline"), W("--shadow-sm"), W("--shadow-md"), W("--shadow-lg")]).describe("CSS variable keys available to MCP apps for theming.").describe("Style variables for theming MCP apps.\n\nIndividual style keys are optional - hosts may provide any subset of these values.\nValues are strings containing CSS values (colors, sizes, font stacks, etc.).\n\nNote: This type uses `Record<K, string | undefined>` rather than `Partial<Record<K, string>>`\nfor compatibility with Zod schema generation. Both are functionally equivalent for validation."), H([F(), Wu()]).describe("Style variables for theming MCP apps.\n\nIndividual style keys are optional - hosts may provide any subset of these values.\nValues are strings containing CSS values (colors, sizes, font stacks, etc.).\n\nNote: This type uses `Record<K, string | undefined>` rather than `Partial<Record<K, string>>`\nfor compatibility with Zod schema generation. Both are functionally equivalent for validation.")).describe("Style variables for theming MCP apps.\n\nIndividual style keys are optional - hosts may provide any subset of these values.\nValues are strings containing CSS values (colors, sizes, font stacks, etc.).\n\nNote: This type uses `Record<K, string | undefined>` rather than `Partial<Record<K, string>>`\nfor compatibility with Zod schema generation. Both are functionally equivalent for validation.");
6279
+ }, xh = H([W("light"), W("dark")]).describe("Color theme preference for the host environment."), Sh = H([W("inline"), W("fullscreen"), W("pip")]).describe("Display mode for UI presentation."), Ch = U(H([W("--color-background-primary"), W("--color-background-secondary"), W("--color-background-tertiary"), W("--color-background-inverse"), W("--color-background-ghost"), W("--color-background-info"), W("--color-background-danger"), W("--color-background-success"), W("--color-background-warning"), W("--color-background-disabled"), W("--color-text-primary"), W("--color-text-secondary"), W("--color-text-tertiary"), W("--color-text-inverse"), W("--color-text-ghost"), W("--color-text-info"), W("--color-text-danger"), W("--color-text-success"), W("--color-text-warning"), W("--color-text-disabled"), W("--color-border-primary"), W("--color-border-secondary"), W("--color-border-tertiary"), W("--color-border-inverse"), W("--color-border-ghost"), W("--color-border-info"), W("--color-border-danger"), W("--color-border-success"), W("--color-border-warning"), W("--color-border-disabled"), W("--color-ring-primary"), W("--color-ring-secondary"), W("--color-ring-inverse"), W("--color-ring-info"), W("--color-ring-danger"), W("--color-ring-success"), W("--color-ring-warning"), W("--font-sans"), W("--font-mono"), W("--font-weight-normal"), W("--font-weight-medium"), W("--font-weight-semibold"), W("--font-weight-bold"), W("--font-text-xs-size"), W("--font-text-sm-size"), W("--font-text-md-size"), W("--font-text-lg-size"), W("--font-heading-xs-size"), W("--font-heading-sm-size"), W("--font-heading-md-size"), W("--font-heading-lg-size"), W("--font-heading-xl-size"), W("--font-heading-2xl-size"), W("--font-heading-3xl-size"), W("--font-text-xs-line-height"), W("--font-text-sm-line-height"), W("--font-text-md-line-height"), W("--font-text-lg-line-height"), W("--font-heading-xs-line-height"), W("--font-heading-sm-line-height"), W("--font-heading-md-line-height"), W("--font-heading-lg-line-height"), W("--font-heading-xl-line-height"), W("--font-heading-2xl-line-height"), W("--font-heading-3xl-line-height"), W("--border-radius-xs"), W("--border-radius-sm"), W("--border-radius-md"), W("--border-radius-lg"), W("--border-radius-xl"), W("--border-radius-full"), W("--border-width-regular"), W("--shadow-hairline"), W("--shadow-sm"), W("--shadow-md"), W("--shadow-lg")]).describe("CSS variable keys available to MCP apps for theming.").describe("Style variables for theming MCP apps.\n\nIndividual style keys are optional - hosts may provide any subset of these values.\nValues are strings containing CSS values (colors, sizes, font stacks, etc.).\n\nNote: This type uses `Record<K, string | undefined>` rather than `Partial<Record<K, string>>`\nfor compatibility with Zod schema generation. Both are functionally equivalent for validation."), H([F(), Wu()]).describe("Style variables for theming MCP apps.\n\nIndividual style keys are optional - hosts may provide any subset of these values.\nValues are strings containing CSS values (colors, sizes, font stacks, etc.).\n\nNote: This type uses `Record<K, string | undefined>` rather than `Partial<Record<K, string>>`\nfor compatibility with Zod schema generation. Both are functionally equivalent for validation.")).describe("Style variables for theming MCP apps.\n\nIndividual style keys are optional - hosts may provide any subset of these values.\nValues are strings containing CSS values (colors, sizes, font stacks, etc.).\n\nNote: This type uses `Record<K, string | undefined>` rather than `Partial<Record<K, string>>`\nfor compatibility with Zod schema generation. Both are functionally equivalent for validation.");
6278
6280
  V({ method: W("ui/open-link"), params: V({ url: F().describe("URL to open in the host's browser") }) });
6279
- var Sh = V({ isError: R().optional().describe("True if the host failed to open the URL (e.g., due to security policy).") }).passthrough(), Ch = V({ isError: R().optional().describe("True if the download failed (e.g., user cancelled or host denied).") }).passthrough(), wh = V({ isError: R().optional().describe("True if the host rejected or failed to deliver the message.") }).passthrough();
6281
+ var wh = V({ isError: R().optional().describe("True if the host failed to open the URL (e.g., due to security policy).") }).passthrough(), Th = V({ isError: R().optional().describe("True if the download failed (e.g., user cancelled or host denied).") }).passthrough(), Eh = V({ isError: R().optional().describe("True if the host rejected or failed to deliver the message.") }).passthrough();
6280
6282
  V({ method: W("ui/notifications/sandbox-proxy-ready"), params: V({}) });
6281
- var Th = V({ connectDomains: B(F()).optional().describe("Origins for network requests (fetch/XHR/WebSocket).\n\n- Maps to CSP `connect-src` directive\n- Empty or omitted \u2192 no network connections (secure default)"), resourceDomains: B(F()).optional().describe("Origins for static resources (images, scripts, stylesheets, fonts, media).\n\n- Maps to CSP `img-src`, `script-src`, `style-src`, `font-src`, `media-src` directives\n- Wildcard subdomains supported: `https://*.example.com`\n- Empty or omitted \u2192 no network resources (secure default)"), frameDomains: B(F()).optional().describe("Origins for nested iframes.\n\n- Maps to CSP `frame-src` directive\n- Empty or omitted \u2192 no nested iframes allowed (`frame-src 'none'`)"), baseUriDomains: B(F()).optional().describe("Allowed base URIs for the document.\n\n- Maps to CSP `base-uri` directive\n- Empty or omitted \u2192 only same origin allowed (`base-uri 'self'`)") }), Eh = V({ camera: V({}).optional().describe("Request camera access.\n\nMaps to Permission Policy `camera` feature."), microphone: V({}).optional().describe("Request microphone access.\n\nMaps to Permission Policy `microphone` feature."), geolocation: V({}).optional().describe("Request geolocation access.\n\nMaps to Permission Policy `geolocation` feature."), clipboardWrite: V({}).optional().describe("Request clipboard write access.\n\nMaps to Permission Policy `clipboard-write` feature.") });
6283
+ var Dh = V({ connectDomains: B(F()).optional().describe("Origins for network requests (fetch/XHR/WebSocket).\n\n- Maps to CSP `connect-src` directive\n- Empty or omitted \u2192 no network connections (secure default)"), resourceDomains: B(F()).optional().describe("Origins for static resources (images, scripts, stylesheets, fonts, media).\n\n- Maps to CSP `img-src`, `script-src`, `style-src`, `font-src`, `media-src` directives\n- Wildcard subdomains supported: `https://*.example.com`\n- Empty or omitted \u2192 no network resources (secure default)"), frameDomains: B(F()).optional().describe("Origins for nested iframes.\n\n- Maps to CSP `frame-src` directive\n- Empty or omitted \u2192 no nested iframes allowed (`frame-src 'none'`)"), baseUriDomains: B(F()).optional().describe("Allowed base URIs for the document.\n\n- Maps to CSP `base-uri` directive\n- Empty or omitted \u2192 only same origin allowed (`base-uri 'self'`)") }), Oh = V({ camera: V({}).optional().describe("Request camera access.\n\nMaps to Permission Policy `camera` feature."), microphone: V({}).optional().describe("Request microphone access.\n\nMaps to Permission Policy `microphone` feature."), geolocation: V({}).optional().describe("Request geolocation access.\n\nMaps to Permission Policy `geolocation` feature."), clipboardWrite: V({}).optional().describe("Request clipboard write access.\n\nMaps to Permission Policy `clipboard-write` feature.") });
6282
6284
  V({ method: W("ui/notifications/size-changed"), params: V({ width: L().optional().describe("New width in pixels."), height: L().optional().describe("New height in pixels.") }) });
6283
- var Dh = V({ method: W("ui/notifications/tool-input"), params: V({ arguments: U(F(), z().describe("Complete tool call arguments as key-value pairs.")).optional().describe("Complete tool call arguments as key-value pairs.") }) }), Oh = V({ method: W("ui/notifications/tool-input-partial"), params: V({ arguments: U(F(), z().describe("Partial tool call arguments (incomplete, may change).")).optional().describe("Partial tool call arguments (incomplete, may change).") }) }), kh = V({ method: W("ui/notifications/tool-cancelled"), params: V({ reason: F().optional().describe('Optional reason for the cancellation (e.g., "user action", "timeout").') }) }), Ah = V({ fonts: F().optional() }), jh = V({ variables: xh.optional().describe("CSS variables for theming the app."), css: Ah.optional().describe("CSS blocks that apps can inject.") }), Mh = V({ method: W("ui/resource-teardown"), params: V({}) });
6285
+ var kh = V({ method: W("ui/notifications/tool-input"), params: V({ arguments: U(F(), z().describe("Complete tool call arguments as key-value pairs.")).optional().describe("Complete tool call arguments as key-value pairs.") }) }), Ah = V({ method: W("ui/notifications/tool-input-partial"), params: V({ arguments: U(F(), z().describe("Partial tool call arguments (incomplete, may change).")).optional().describe("Partial tool call arguments (incomplete, may change).") }) }), jh = V({ method: W("ui/notifications/tool-cancelled"), params: V({ reason: F().optional().describe('Optional reason for the cancellation (e.g., "user action", "timeout").') }) }), Mh = V({ fonts: F().optional() }), Nh = V({ variables: Ch.optional().describe("CSS variables for theming the app."), css: Mh.optional().describe("CSS blocks that apps can inject.") }), Ph = V({ method: W("ui/resource-teardown"), params: V({}) });
6284
6286
  U(F(), z());
6285
- var Nh = V({ text: V({}).optional().describe("Host supports text content blocks."), image: V({}).optional().describe("Host supports image content blocks."), audio: V({}).optional().describe("Host supports audio content blocks."), resource: V({}).optional().describe("Host supports resource content blocks."), resourceLink: V({}).optional().describe("Host supports resource link content blocks."), structuredContent: V({}).optional().describe("Host supports structured content.") });
6287
+ var Fh = V({ text: V({}).optional().describe("Host supports text content blocks."), image: V({}).optional().describe("Host supports image content blocks."), audio: V({}).optional().describe("Host supports audio content blocks."), resource: V({}).optional().describe("Host supports resource content blocks."), resourceLink: V({}).optional().describe("Host supports resource link content blocks."), structuredContent: V({}).optional().describe("Host supports structured content.") });
6286
6288
  V({ method: W("ui/notifications/request-teardown"), params: V({}).optional() });
6287
- var Ph = V({ experimental: V({}).optional().describe("Experimental features (structure TBD)."), openLinks: V({}).optional().describe("Host supports opening external URLs."), downloadFile: V({}).optional().describe("Host supports file downloads via ui/download-file."), serverTools: V({ listChanged: R().optional().describe("Host supports tools/list_changed notifications.") }).optional().describe("Host can proxy tool calls to the MCP server."), serverResources: V({ listChanged: R().optional().describe("Host supports resources/list_changed notifications.") }).optional().describe("Host can proxy resource reads to the MCP server."), logging: V({}).optional().describe("Host accepts log messages."), sandbox: V({ permissions: Eh.optional().describe("Permissions granted by the host (camera, microphone, geolocation)."), csp: Th.optional().describe("CSP domains approved by the host.") }).optional().describe("Sandbox configuration applied by the host."), updateModelContext: Nh.optional().describe("Host accepts context updates (ui/update-model-context) to be included in the model's context for future turns."), message: Nh.optional().describe("Host supports receiving content messages (ui/message) from the view."), sampling: V({ tools: V({}).optional().describe("Host supports tool use via `tools` and `toolChoice` parameters.") }).optional().describe("Host supports LLM sampling (sampling/createMessage) from the view.\nMirrors the MCP `ClientCapabilities.sampling` shape so hosts can pass it through.") }), Fh = V({ experimental: V({}).optional().describe("Experimental features (structure TBD)."), tools: V({ listChanged: R().optional().describe("App supports tools/list_changed notifications.") }).optional().describe("App exposes MCP-style tools that the host can call."), availableDisplayModes: B(bh).optional().describe("Display modes the app supports.") });
6288
- V({ method: W("ui/notifications/initialized"), params: V({}).optional() }), V({ csp: Th.optional().describe("Content Security Policy configuration for UI resources."), permissions: Eh.optional().describe("Sandbox permissions requested by the UI resource."), domain: F().optional().describe("Dedicated origin for view sandbox.\n\nUseful when views need stable, dedicated origins for OAuth callbacks, CORS policies, or API key allowlists.\n\n**Host-dependent:** The format and validation rules for this field are determined by each host. Servers MUST consult host-specific documentation for the expected domain format. Common patterns include:\n- Hash-based subdomains (e.g., `{hash}.claudemcpcontent.com`)\n- URL-derived subdomains (e.g., `www-example-com.oaiusercontent.com`)\n\nIf omitted, host uses default sandbox origin (typically per-conversation)."), prefersBorder: R().optional().describe("Visual boundary preference - true if view prefers a visible border.\n\nBoolean requesting whether a visible border and background is provided by the host. Specifying an explicit value for this is recommended because hosts' defaults may vary.\n\n- `true`: request visible border + background\n- `false`: request no visible border + background\n- omitted: host decides border") }), V({ method: W("ui/request-display-mode"), params: V({ mode: bh.describe("The display mode being requested.") }) });
6289
- var Ih = V({ mode: bh.describe("The display mode that was actually set. May differ from requested if not supported.") }).passthrough(), Lh = H([W("model"), W("app")]).describe("Tool visibility scope - who can access the tool.");
6290
- V({ resourceUri: F().optional(), visibility: B(Lh).optional().describe('Who can access this tool. Default: ["model", "app"]\n- "model": Tool visible to and callable by the agent\n- "app": Tool callable by the app from this server only'), csp: Zu().optional(), permissions: Zu().optional() }), V({ mimeTypes: B(F()).optional().describe('Array of supported MIME types for UI resources.\nMust include `"text/html;profile=mcp-app"` for MCP Apps support.') }), V({ method: W("ui/download-file"), params: V({ contents: B(H([cm, lm])).describe("Resource contents to download \u2014 embedded (inline data) or linked (host fetches). Uses standard MCP resource types.") }) }), V({ method: W("ui/message"), params: V({ role: W("user").describe('Message role, currently only "user" is supported.'), content: B(um).describe("Message content blocks (text, image, etc.).") }) }), V({ method: W("ui/notifications/sandbox-resource-ready"), params: V({ html: F().describe("HTML content to load into the inner iframe."), sandbox: F().optional().describe("Optional override for the inner iframe's sandbox attribute."), csp: Th.optional().describe("CSP configuration from resource metadata."), permissions: Eh.optional().describe("Sandbox permissions from resource metadata.") }) });
6291
- var Rh = V({ method: W("ui/notifications/tool-result"), params: ym.describe("Standard MCP tool execution result.") }), zh = V({ toolInfo: V({ id: zf.optional().describe("JSON-RPC id of the tools/call request."), tool: gm.describe("Tool definition including name, inputSchema, etc.") }).optional().describe("Metadata of the tool call that instantiated this App."), theme: yh.optional().describe("Current color theme preference."), styles: jh.optional().describe("Style configuration for theming the app."), displayMode: bh.optional().describe("How the UI is currently displayed."), availableDisplayModes: B(bh).optional().describe("Display modes the host supports."), containerDimensions: H([V({ height: L().describe("Fixed container height in pixels.") }), V({ maxHeight: H([L(), Wu()]).optional().describe("Maximum container height in pixels.") })]).and(H([V({ width: L().describe("Fixed container width in pixels.") }), V({ maxWidth: H([L(), Wu()]).optional().describe("Maximum container width in pixels.") })])).optional().describe("Container dimensions. Represents the dimensions of the iframe or other\ncontainer holding the app. Specify either width or maxWidth, and either height or maxHeight."), locale: F().optional().describe("User's language and region preference in BCP 47 format."), timeZone: F().optional().describe("User's timezone in IANA format."), userAgent: F().optional().describe("Host application identifier."), platform: H([W("web"), W("desktop"), W("mobile")]).optional().describe("Platform type for responsive design decisions."), deviceCapabilities: V({ touch: R().optional().describe("Whether the device supports touch input."), hover: R().optional().describe("Whether the device supports hover interactions.") }).optional().describe("Device input capabilities."), safeAreaInsets: V({ top: L().describe("Top safe area inset in pixels."), right: L().describe("Right safe area inset in pixels."), bottom: L().describe("Bottom safe area inset in pixels."), left: L().describe("Left safe area inset in pixels.") }).optional().describe("Mobile safe area boundaries in pixels.") }).passthrough(), Bh = V({ method: W("ui/notifications/host-context-changed"), params: zh.describe("Partial context update containing only changed fields.") });
6292
- V({ method: W("ui/update-model-context"), params: V({ content: B(um).optional().describe("Context content blocks (text, image, etc.)."), structuredContent: U(F(), z().describe("Structured content for machine-readable context data.")).optional().describe("Structured content for machine-readable context data.") }) }), V({ method: W("ui/initialize"), params: V({ appInfo: ep.describe("App identification (name and version)."), appCapabilities: Fh.describe("Features and capabilities this app provides."), protocolVersion: F().describe("Protocol version this app supports.") }) });
6293
- var Vh = V({ protocolVersion: F().describe('Negotiated protocol version string (e.g., "2025-11-21").'), hostInfo: ep.describe("Host application identification and version."), hostCapabilities: Ph.describe("Features and capabilities provided by the host."), hostContext: zh.describe("Rich context about the host environment.") }).passthrough(), Hh = { target: "draft-2020-12" };
6294
- async function Uh(e4, t2) {
6289
+ var Ih = V({ experimental: V({}).optional().describe("Experimental features (structure TBD)."), openLinks: V({}).optional().describe("Host supports opening external URLs."), downloadFile: V({}).optional().describe("Host supports file downloads via ui/download-file."), serverTools: V({ listChanged: R().optional().describe("Host supports tools/list_changed notifications.") }).optional().describe("Host can proxy tool calls to the MCP server."), serverResources: V({ listChanged: R().optional().describe("Host supports resources/list_changed notifications.") }).optional().describe("Host can proxy resource reads to the MCP server."), logging: V({}).optional().describe("Host accepts log messages."), sandbox: V({ permissions: Oh.optional().describe("Permissions granted by the host (camera, microphone, geolocation)."), csp: Dh.optional().describe("CSP domains approved by the host.") }).optional().describe("Sandbox configuration applied by the host."), updateModelContext: Fh.optional().describe("Host accepts context updates (ui/update-model-context) to be included in the model's context for future turns."), message: Fh.optional().describe("Host supports receiving content messages (ui/message) from the view."), sampling: V({ tools: V({}).optional().describe("Host supports tool use via `tools` and `toolChoice` parameters.") }).optional().describe("Host supports LLM sampling (sampling/createMessage) from the view.\nMirrors the MCP `ClientCapabilities.sampling` shape so hosts can pass it through.") }), Lh = V({ experimental: V({}).optional().describe("Experimental features (structure TBD)."), tools: V({ listChanged: R().optional().describe("App supports tools/list_changed notifications.") }).optional().describe("App exposes MCP-style tools that the host can call."), availableDisplayModes: B(Sh).optional().describe("Display modes the app supports.") });
6290
+ V({ method: W("ui/notifications/initialized"), params: V({}).optional() }), V({ csp: Dh.optional().describe("Content Security Policy configuration for UI resources."), permissions: Oh.optional().describe("Sandbox permissions requested by the UI resource."), domain: F().optional().describe("Dedicated origin for view sandbox.\n\nUseful when views need stable, dedicated origins for OAuth callbacks, CORS policies, or API key allowlists.\n\n**Host-dependent:** The format and validation rules for this field are determined by each host. Servers MUST consult host-specific documentation for the expected domain format. Common patterns include:\n- Hash-based subdomains (e.g., `{hash}.claudemcpcontent.com`)\n- URL-derived subdomains (e.g., `www-example-com.oaiusercontent.com`)\n\nIf omitted, host uses default sandbox origin (typically per-conversation)."), prefersBorder: R().optional().describe("Visual boundary preference - true if view prefers a visible border.\n\nBoolean requesting whether a visible border and background is provided by the host. Specifying an explicit value for this is recommended because hosts' defaults may vary.\n\n- `true`: request visible border + background\n- `false`: request no visible border + background\n- omitted: host decides border") }), V({ method: W("ui/request-display-mode"), params: V({ mode: Sh.describe("The display mode being requested.") }) });
6291
+ var Rh = V({ mode: Sh.describe("The display mode that was actually set. May differ from requested if not supported.") }).passthrough(), zh = H([W("model"), W("app")]).describe("Tool visibility scope - who can access the tool.");
6292
+ V({ resourceUri: F().optional(), visibility: B(zh).optional().describe('Who can access this tool. Default: ["model", "app"]\n- "model": Tool visible to and callable by the agent\n- "app": Tool callable by the app from this server only'), csp: Zu().optional(), permissions: Zu().optional() }), V({ mimeTypes: B(F()).optional().describe('Array of supported MIME types for UI resources.\nMust include `"text/html;profile=mcp-app"` for MCP Apps support.') }), V({ method: W("ui/download-file"), params: V({ contents: B(H([um, dm])).describe("Resource contents to download \u2014 embedded (inline data) or linked (host fetches). Uses standard MCP resource types.") }) }), V({ method: W("ui/message"), params: V({ role: W("user").describe('Message role, currently only "user" is supported.'), content: B(fm).describe("Message content blocks (text, image, etc.).") }) }), V({ method: W("ui/notifications/sandbox-resource-ready"), params: V({ html: F().describe("HTML content to load into the inner iframe."), sandbox: F().optional().describe("Optional override for the inner iframe's sandbox attribute."), csp: Dh.optional().describe("CSP configuration from resource metadata."), permissions: Oh.optional().describe("Sandbox permissions from resource metadata.") }) });
6293
+ var Bh = V({ method: W("ui/notifications/tool-result"), params: xm.describe("Standard MCP tool execution result.") }), Vh = V({ toolInfo: V({ id: Vf.optional().describe("JSON-RPC id of the tools/call request."), tool: vm.describe("Tool definition including name, inputSchema, etc.") }).optional().describe("Metadata of the tool call that instantiated this App."), theme: xh.optional().describe("Current color theme preference."), styles: Nh.optional().describe("Style configuration for theming the app."), displayMode: Sh.optional().describe("How the UI is currently displayed."), availableDisplayModes: B(Sh).optional().describe("Display modes the host supports."), containerDimensions: H([V({ height: L().describe("Fixed container height in pixels.") }), V({ maxHeight: H([L(), Wu()]).optional().describe("Maximum container height in pixels.") })]).and(H([V({ width: L().describe("Fixed container width in pixels.") }), V({ maxWidth: H([L(), Wu()]).optional().describe("Maximum container width in pixels.") })])).optional().describe("Container dimensions. Represents the dimensions of the iframe or other\ncontainer holding the app. Specify either width or maxWidth, and either height or maxHeight."), locale: F().optional().describe("User's language and region preference in BCP 47 format."), timeZone: F().optional().describe("User's timezone in IANA format."), userAgent: F().optional().describe("Host application identifier."), platform: H([W("web"), W("desktop"), W("mobile")]).optional().describe("Platform type for responsive design decisions."), deviceCapabilities: V({ touch: R().optional().describe("Whether the device supports touch input."), hover: R().optional().describe("Whether the device supports hover interactions.") }).optional().describe("Device input capabilities."), safeAreaInsets: V({ top: L().describe("Top safe area inset in pixels."), right: L().describe("Right safe area inset in pixels."), bottom: L().describe("Bottom safe area inset in pixels."), left: L().describe("Left safe area inset in pixels.") }).optional().describe("Mobile safe area boundaries in pixels.") }).passthrough(), Hh = V({ method: W("ui/notifications/host-context-changed"), params: Vh.describe("Partial context update containing only changed fields.") });
6294
+ V({ method: W("ui/update-model-context"), params: V({ content: B(fm).optional().describe("Context content blocks (text, image, etc.)."), structuredContent: U(F(), z().describe("Structured content for machine-readable context data.")).optional().describe("Structured content for machine-readable context data.") }) }), V({ method: W("ui/initialize"), params: V({ appInfo: np.describe("App identification (name and version)."), appCapabilities: Lh.describe("Features and capabilities this app provides."), protocolVersion: F().describe("Protocol version this app supports.") }) });
6295
+ var Uh = V({ protocolVersion: F().describe('Negotiated protocol version string (e.g., "2025-11-21").'), hostInfo: np.describe("Host application identification and version."), hostCapabilities: Ih.describe("Features and capabilities provided by the host."), hostContext: Vh.describe("Rich context about the host environment.") }).passthrough(), Wh = { target: "draft-2020-12" };
6296
+ async function Gh(e4, t2) {
6295
6297
  let n2 = e4["~standard"];
6296
- if (n2.jsonSchema) return n2.jsonSchema[t2](Hh);
6298
+ if (n2.jsonSchema) return n2.jsonSchema[t2](Wh);
6297
6299
  if (n2.vendor === "zod") {
6298
- let { z: n3 } = await hh(async () => {
6300
+ let { z: n3 } = await _h(async () => {
6299
6301
  let { z: e5 } = await Promise.resolve().then(() => Df);
6300
6302
  return { z: e5 };
6301
6303
  }, __VITE_PRELOAD__);
@@ -6303,7 +6305,7 @@ async function Uh(e4, t2) {
6303
6305
  }
6304
6306
  throw Error("Schema (vendor: ".concat(n2.vendor, ") does not implement Standard JSON Schema (~standard.jsonSchema). Use a library that does (zod v4, ArkType, Valibot) or wrap your schema accordingly."));
6305
6307
  }
6306
- async function Wh(e4, t2, n2 = "") {
6308
+ async function Kh(e4, t2, n2 = "") {
6307
6309
  let r2 = await e4["~standard"].validate(t2);
6308
6310
  if (r2.issues) {
6309
6311
  let e5 = r2.issues.map((e6) => {
@@ -6315,7 +6317,7 @@ async function Wh(e4, t2, n2 = "") {
6315
6317
  }
6316
6318
  return r2.value;
6317
6319
  }
6318
- var Gh = class e3 extends gh {
6320
+ var qh = class e3 extends vh {
6319
6321
  _assertInitialized(e4) {
6320
6322
  var t2;
6321
6323
  if (this._initializedSent) return;
@@ -6340,11 +6342,11 @@ var Gh = class e3 extends gh {
6340
6342
  e4 === "hostcontextchanged" && (this._hostContext = { ...this._hostContext, ...t2 });
6341
6343
  }
6342
6344
  constructor(e4, t2 = {}, n2 = { autoResize: true }) {
6343
- super(n2), o(this, "_appInfo", void 0), o(this, "_capabilities", void 0), o(this, "options", void 0), o(this, "_hostCapabilities", void 0), o(this, "_hostInfo", void 0), o(this, "_hostContext", void 0), o(this, "_registeredTools", {}), o(this, "_initializedSent", false), o(this, "eventSchemas", { toolinput: Dh, toolinputpartial: Oh, toolresult: Rh, toolcancelled: kh, hostcontextchanged: Bh }), o(this, "_everHadListener", /* @__PURE__ */ new Set()), o(this, "_toolHandlersInitialized", false), o(this, "_onteardown", void 0), o(this, "_oncalltool", void 0), o(this, "_onlisttools", void 0), o(this, "sendOpenLink", this.openLink), this._appInfo = e4, this._capabilities = t2, this.options = n2, n2.allowUnsafeEval || p({ jitless: true }), this.setRequestHandler(up, (e5) => (console.log("Received ping:", e5.params), {})), this.setEventHandler("hostcontextchanged", void 0);
6345
+ super(n2), o(this, "_appInfo", void 0), o(this, "_capabilities", void 0), o(this, "options", void 0), o(this, "_hostCapabilities", void 0), o(this, "_hostInfo", void 0), o(this, "_hostContext", void 0), o(this, "_registeredTools", {}), o(this, "_initializedSent", false), o(this, "eventSchemas", { toolinput: kh, toolinputpartial: Ah, toolresult: Bh, toolcancelled: jh, hostcontextchanged: Hh }), o(this, "_everHadListener", /* @__PURE__ */ new Set()), o(this, "_toolHandlersInitialized", false), o(this, "_onteardown", void 0), o(this, "_oncalltool", void 0), o(this, "_onlisttools", void 0), o(this, "sendOpenLink", this.openLink), this._appInfo = e4, this._capabilities = t2, this.options = n2, n2.allowUnsafeEval || p({ jitless: true }), this.setRequestHandler(fp, (e5) => (console.log("Received ping:", e5.params), {})), this.setEventHandler("hostcontextchanged", void 0);
6344
6346
  }
6345
6347
  registerCapabilities(e4) {
6346
6348
  if (this.transport) throw Error("Cannot register capabilities after transport is established");
6347
- this._capabilities = dh(this._capabilities, e4);
6349
+ this._capabilities = ph(this._capabilities, e4);
6348
6350
  }
6349
6351
  registerTool(e4, t2, n2) {
6350
6352
  if (this._registeredTools[e4]) throw Error("Tool ".concat(e4, " is already registered"));
@@ -6364,9 +6366,9 @@ var Gh = class e3 extends gh {
6364
6366
  let i3;
6365
6367
  if (a2) {
6366
6368
  let a3 = o2.inputSchema;
6367
- i3 = await n2(a3 ? await Wh(a3, t3 == null ? {} : t3, "Invalid input for tool ".concat(e4, ": ")) : t3 == null ? {} : t3, r3);
6369
+ i3 = await n2(a3 ? await Kh(a3, t3 == null ? {} : t3, "Invalid input for tool ".concat(e4, ": ")) : t3 == null ? {} : t3, r3);
6368
6370
  } else i3 = await n2(r3);
6369
- return o2.outputSchema && !i3.isError && (i3.structuredContent = await Wh(o2.outputSchema, i3.structuredContent, "Invalid output for tool ".concat(e4, ": "))), i3;
6371
+ return o2.outputSchema && !i3.isError && (i3.structuredContent = await Kh(o2.outputSchema, i3.structuredContent, "Invalid output for tool ".concat(e4, ": "))), i3;
6370
6372
  } };
6371
6373
  return this._registeredTools[e4] = o2, !this._capabilities.tools && !this.transport && this.registerCapabilities({ tools: { listChanged: true } }), this.ensureToolHandlersInitialized(), i2(), o2;
6372
6374
  }
@@ -6376,8 +6378,8 @@ var Gh = class e3 extends gh {
6376
6378
  if (!n2) throw Error("Tool ".concat(e4.name, " not found"));
6377
6379
  return n2.handler(e4.arguments, t2);
6378
6380
  }, this.onlisttools = async (e4, t2) => ({ tools: await Promise.all(Object.entries(this._registeredTools).filter(([e5, t3]) => t3.enabled).map(async ([e5, t3]) => {
6379
- let n2 = { name: e5, title: t3.title, description: t3.description, inputSchema: t3.inputSchema ? await Uh(t3.inputSchema, "input") : { type: "object", properties: {} } };
6380
- return t3.outputSchema && (n2.outputSchema = await Uh(t3.outputSchema, "output")), t3.annotations && (n2.annotations = t3.annotations), t3._meta && (n2._meta = t3._meta), n2;
6381
+ let n2 = { name: e5, title: t3.title, description: t3.description, inputSchema: t3.inputSchema ? await Gh(t3.inputSchema, "input") : { type: "object", properties: {} } };
6382
+ return t3.outputSchema && (n2.outputSchema = await Gh(t3.outputSchema, "output")), t3.annotations && (n2.annotations = t3.annotations), t3._meta && (n2._meta = t3._meta), n2;
6381
6383
  })) }));
6382
6384
  }
6383
6385
  async sendToolListChanged(e4 = {}) {
@@ -6426,7 +6428,7 @@ var Gh = class e3 extends gh {
6426
6428
  return this._onteardown;
6427
6429
  }
6428
6430
  set onteardown(e4) {
6429
- this.warnIfRequestHandlerReplaced("onteardown", this._onteardown, e4), this._onteardown = e4, this.replaceRequestHandler(Mh, (e5, t2) => {
6431
+ this.warnIfRequestHandlerReplaced("onteardown", this._onteardown, e4), this._onteardown = e4, this.replaceRequestHandler(Ph, (e5, t2) => {
6430
6432
  if (!this._onteardown) throw Error("No onteardown handler set");
6431
6433
  return this._onteardown(e5.params, t2);
6432
6434
  });
@@ -6435,7 +6437,7 @@ var Gh = class e3 extends gh {
6435
6437
  return this._oncalltool;
6436
6438
  }
6437
6439
  set oncalltool(e4) {
6438
- this.warnIfRequestHandlerReplaced("oncalltool", this._oncalltool, e4), this._oncalltool = e4, this.replaceRequestHandler(xm, (e5, t2) => {
6440
+ this.warnIfRequestHandlerReplaced("oncalltool", this._oncalltool, e4), this._oncalltool = e4, this.replaceRequestHandler(Cm, (e5, t2) => {
6439
6441
  if (!this._oncalltool) throw Error("No oncalltool handler set");
6440
6442
  return this._oncalltool(e5.params, t2);
6441
6443
  });
@@ -6444,7 +6446,7 @@ var Gh = class e3 extends gh {
6444
6446
  return this._onlisttools;
6445
6447
  }
6446
6448
  set onlisttools(e4) {
6447
- this.warnIfRequestHandlerReplaced("onlisttools", this._onlisttools, e4), this._onlisttools = e4, this.replaceRequestHandler(_m, (e5, t2) => {
6449
+ this.warnIfRequestHandlerReplaced("onlisttools", this._onlisttools, e4), this._onlisttools = e4, this.replaceRequestHandler(ym, (e5, t2) => {
6448
6450
  if (!this._onlisttools) throw Error("No onlisttools handler set");
6449
6451
  return this._onlisttools(e5.params, t2);
6450
6452
  });
@@ -6480,40 +6482,40 @@ var Gh = class e3 extends gh {
6480
6482
  }
6481
6483
  async callServerTool(e4, t2) {
6482
6484
  if (this._assertInitialized("callServerTool"), typeof e4 == "string") throw Error('callServerTool() expects an object as its first argument, but received a string ("'.concat(e4, '"). Did you mean: callServerTool({ name: "').concat(e4, '", arguments: { ... } })?'));
6483
- return await this.request({ method: "tools/call", params: e4 }, ym, { onprogress: () => {
6485
+ return await this.request({ method: "tools/call", params: e4 }, xm, { onprogress: () => {
6484
6486
  }, resetTimeoutOnProgress: true, ...t2 });
6485
6487
  }
6486
6488
  async readServerResource(e4, t2) {
6487
- return this._assertInitialized("readServerResource"), await this.request({ method: "resources/read", params: e4 }, Wp, t2);
6489
+ return this._assertInitialized("readServerResource"), await this.request({ method: "resources/read", params: e4 }, Kp, t2);
6488
6490
  }
6489
6491
  async listServerResources(e4, t2) {
6490
- return this._assertInitialized("listServerResources"), await this.request({ method: "resources/list", params: e4 }, Rp, t2);
6492
+ return this._assertInitialized("listServerResources"), await this.request({ method: "resources/list", params: e4 }, Bp, t2);
6491
6493
  }
6492
6494
  async createSamplingMessage(e4, t2) {
6493
6495
  this._assertInitialized("createSamplingMessage");
6494
- let n2 = e4.tools ? Lm : Im;
6496
+ let n2 = e4.tools ? zm : Rm;
6495
6497
  return await this.request({ method: "sampling/createMessage", params: e4 }, n2, t2);
6496
6498
  }
6497
6499
  sendMessage(e4, t2) {
6498
- return this._assertInitialized("sendMessage"), this.request({ method: "ui/message", params: e4 }, wh, t2);
6500
+ return this._assertInitialized("sendMessage"), this.request({ method: "ui/message", params: e4 }, Eh, t2);
6499
6501
  }
6500
6502
  sendLog(e4) {
6501
6503
  return this.notification({ method: "notifications/message", params: e4 });
6502
6504
  }
6503
6505
  updateModelContext(e4, t2) {
6504
- return this._assertInitialized("updateModelContext"), this.request({ method: "ui/update-model-context", params: e4 }, Yf, t2);
6506
+ return this._assertInitialized("updateModelContext"), this.request({ method: "ui/update-model-context", params: e4 }, Zf, t2);
6505
6507
  }
6506
6508
  openLink(e4, t2) {
6507
- return this._assertInitialized("openLink"), this.request({ method: "ui/open-link", params: e4 }, Sh, t2);
6509
+ return this._assertInitialized("openLink"), this.request({ method: "ui/open-link", params: e4 }, wh, t2);
6508
6510
  }
6509
6511
  downloadFile(e4, t2) {
6510
- return this._assertInitialized("downloadFile"), this.request({ method: "ui/download-file", params: e4 }, Ch, t2);
6512
+ return this._assertInitialized("downloadFile"), this.request({ method: "ui/download-file", params: e4 }, Th, t2);
6511
6513
  }
6512
6514
  requestTeardown(e4 = {}) {
6513
6515
  return this.notification({ method: "ui/notifications/request-teardown", params: e4 });
6514
6516
  }
6515
6517
  requestDisplayMode(e4, t2) {
6516
- return this._assertInitialized("requestDisplayMode"), this.request({ method: "ui/request-display-mode", params: e4 }, Ih, t2);
6518
+ return this._assertInitialized("requestDisplayMode"), this.request({ method: "ui/request-display-mode", params: e4 }, Rh, t2);
6517
6519
  }
6518
6520
  sendSizeChanged(e4) {
6519
6521
  return this.notification({ method: "ui/notifications/size-changed", params: e4 });
@@ -6534,12 +6536,12 @@ var Gh = class e3 extends gh {
6534
6536
  let i2 = new ResizeObserver(r2);
6535
6537
  return i2.observe(document.documentElement), i2.observe(document.body), () => i2.disconnect();
6536
6538
  }
6537
- async connect(e4 = new vh(window.parent, window.parent), t2) {
6539
+ async connect(e4 = new bh(window.parent, window.parent), t2) {
6538
6540
  if (this.transport) throw Error("App is already connected. Call close() before connecting again.");
6539
6541
  this._initializedSent = false, await super.connect(e4);
6540
6542
  try {
6541
6543
  var n2;
6542
- let e5 = await this.request({ method: "ui/initialize", params: { appCapabilities: this._capabilities, appInfo: this._appInfo, protocolVersion: _h } }, Vh, t2);
6544
+ let e5 = await this.request({ method: "ui/initialize", params: { appCapabilities: this._capabilities, appInfo: this._appInfo, protocolVersion: yh } }, Uh, t2);
6543
6545
  if (e5 === void 0) throw Error("Server sent invalid initialize result: ".concat(e5));
6544
6546
  this._hostCapabilities = e5.hostCapabilities, this._hostInfo = e5.hostInfo, this._hostContext = e5.hostContext, await this.notification({ method: "ui/notifications/initialized" }), this._initializedSent = true, (n2 = this.options) != null && n2.autoResize && this.setupSizeChangedNotifications();
6545
6547
  } catch (e5) {
@@ -6547,8 +6549,8 @@ var Gh = class e3 extends gh {
6547
6549
  }
6548
6550
  }
6549
6551
  };
6550
- o(Gh, "ONE_SHOT_EVENTS", /* @__PURE__ */ new Set(["toolinput", "toolinputpartial", "toolresult", "toolcancelled"]));
6551
- function Kh(e4, t2) {
6552
+ o(qh, "ONE_SHOT_EVENTS", /* @__PURE__ */ new Set(["toolinput", "toolinputpartial", "toolresult", "toolcancelled"]));
6553
+ function Jh(e4, t2) {
6552
6554
  var n2, r2, i2, a2, o2, s2;
6553
6555
  let c2 = document.getElementById(t2), l2 = c2 == null ? void 0 : c2.querySelector("#btn-zoom-in"), u2 = c2 == null ? void 0 : c2.querySelector("#btn-zoom-out"), d2 = c2 == null ? void 0 : c2.querySelector("#btn-reset-view");
6554
6556
  c2 && (c2.hidden = false);
@@ -6575,121 +6577,121 @@ function Kh(e4, t2) {
6575
6577
  _2 && (_2 = false, e4.releasePointerCapture(t3.pointerId), e4.style.cursor = "default");
6576
6578
  });
6577
6579
  }
6578
- var qh = 310, Jh = 310, Yh = 240, Xh = 204, Zh = 190, Qh = 159, $h = 140, eg = 134, tg = 290, ng = 246, rg = 264, ig = 16;
6579
- function Z(e4, t2, n2) {
6580
+ var Yh = 310, Xh = 310, Zh = 240, Qh = 204, $h = 190, eg = 159, tg = 140, ng = 134, rg = 290, ig = 246, ag = 264, og = 16;
6581
+ function Y(e4, t2, n2) {
6580
6582
  let r2 = -(e4 - n2 + 180) * Math.PI / 180;
6581
- return { x: qh + t2 * Math.cos(r2), y: Jh + t2 * Math.sin(r2) };
6583
+ return { x: Yh + t2 * Math.cos(r2), y: Xh + t2 * Math.sin(r2) };
6582
6584
  }
6583
- function Q(e4) {
6585
+ function X(e4) {
6584
6586
  return document.createElementNS("http://www.w3.org/2000/svg", e4);
6585
6587
  }
6586
- var ag = { sun: "\u2609", moon: "\u263D", mercury: "\u263F", venus: "\u2640", mars: "\u2642", jupiter: "\u2643", saturn: "\u2644", uranus: "\u2645", neptune: "\u2646", pluto: "\u2647", "north node": "\u260A", "south node": "\u260B", chiron: "\u26B7", "true node": "\u260A", north_node: "\u260A", south_node: "\u260B", true_node: "\u260A", asc: "AC", mc: "MC" }, og = ["\u2648", "\u2649", "\u264A", "\u264B", "\u264C", "\u264D", "\u264E", "\u264F", "\u2650", "\u2651", "\u2652", "\u2653"], sg = ["Aries", "Taurus", "Gemini", "Cancer", "Leo", "Virgo", "Libra", "Scorpio", "Sagittarius", "Capricorn", "Aquarius", "Pisces"], cg = { conjunction: "\u260C", opposition: "\u260D", trine: "\u25B3", square: "\u25A1", sextile: "\u26B9" };
6587
- function lg(e4) {
6588
+ var sg = { sun: "\u2609", moon: "\u263D", mercury: "\u263F", venus: "\u2640", mars: "\u2642", jupiter: "\u2643", saturn: "\u2644", uranus: "\u2645", neptune: "\u2646", pluto: "\u2647", "north node": "\u260A", "south node": "\u260B", chiron: "\u26B7", "true node": "\u260A", north_node: "\u260A", south_node: "\u260B", true_node: "\u260A", asc: "AC", mc: "MC" }, cg = ["\u2648", "\u2649", "\u264A", "\u264B", "\u264C", "\u264D", "\u264E", "\u264F", "\u2650", "\u2651", "\u2652", "\u2653"], lg = ["Aries", "Taurus", "Gemini", "Cancer", "Leo", "Virgo", "Libra", "Scorpio", "Sagittarius", "Capricorn", "Aquarius", "Pisces"], ug = { conjunction: "\u260C", opposition: "\u260D", trine: "\u25B3", square: "\u25A1", sextile: "\u26B9" };
6589
+ function dg(e4) {
6588
6590
  var t2;
6589
6591
  let n2 = e4.toLowerCase();
6590
6592
  return getComputedStyle(document.documentElement).getPropertyValue("--xasp-".concat(n2)).trim() || ((t2 = { conjunction: "#9a7fd4", opposition: "#e05252", trine: "#52a8e0", square: "#e08a52", sextile: "#52c07a" }[n2]) == null ? "#888" : t2);
6591
6593
  }
6592
- function ug(e4) {
6593
- return e4 <= 1 ? { dash: "", width: "1.8", opacity: "0.70" } : e4 <= 3 ? { dash: "6,4", width: "1.3", opacity: "0.55" } : { dash: "8,6", width: "0.9", opacity: "0.35" };
6594
+ function fg(e4) {
6595
+ return e4 <= 1 ? { dash: "", width: "1.5", opacity: "0.72" } : e4 <= 3 ? { dash: "5,4", width: "1.1", opacity: "0.50" } : { dash: "3,5", width: "0.7", opacity: "0.30" };
6594
6596
  }
6595
- var dg = { sun: { domicile: [4], exaltation: [0], detriment: [10], fall: [6] }, moon: { domicile: [3], exaltation: [1], detriment: [9], fall: [7] }, mercury: { domicile: [2, 5], exaltation: [5], detriment: [8, 11], fall: [11] }, venus: { domicile: [1, 6], exaltation: [11], detriment: [7, 0], fall: [5] }, mars: { domicile: [0, 7], exaltation: [9], detriment: [6, 1], fall: [3] }, jupiter: { domicile: [8, 11], exaltation: [3], detriment: [2, 5], fall: [9] }, saturn: { domicile: [9, 10], exaltation: [6], detriment: [3, 4], fall: [0] } };
6596
- function fg(e4, t2) {
6597
- let n2 = dg[e4.toLowerCase()];
6597
+ var pg = { sun: { domicile: [4], exaltation: [0], detriment: [10], fall: [6] }, moon: { domicile: [3], exaltation: [1], detriment: [9], fall: [7] }, mercury: { domicile: [2, 5], exaltation: [5], detriment: [8, 11], fall: [11] }, venus: { domicile: [1, 6], exaltation: [11], detriment: [7, 0], fall: [5] }, mars: { domicile: [0, 7], exaltation: [9], detriment: [6, 1], fall: [3] }, jupiter: { domicile: [8, 11], exaltation: [3], detriment: [2, 5], fall: [9] }, saturn: { domicile: [9, 10], exaltation: [6], detriment: [3, 4], fall: [0] } };
6598
+ function mg(e4, t2) {
6599
+ let n2 = pg[e4.toLowerCase()];
6598
6600
  if (!n2) return null;
6599
6601
  let r2 = Math.floor((t2 % 360 + 360) % 360 / 30);
6600
6602
  return n2.domicile.includes(r2) ? { label: "Domicile", emoji: "\u{1F3DB}", cssClass: "dignity-domicile", positive: true } : n2.exaltation.includes(r2) ? { label: "Exaltation", emoji: "\u2B06", cssClass: "dignity-exaltation", positive: true } : n2.detriment.includes(r2) ? { label: "Detriment", emoji: "\u2B07", cssClass: "dignity-detriment", positive: false } : n2.fall.includes(r2) ? { label: "Fall", emoji: "\u{1F53B}", cssClass: "dignity-fall", positive: false } : null;
6601
6603
  }
6602
- var pg = ["#e8854c", "#7aaa6a", "#5aaad0", "#8878c8", "#e8854c", "#7aaa6a", "#5aaad0", "#8878c8", "#e8854c", "#7aaa6a", "#5aaad0", "#8878c8"];
6603
- function mg(e4, t2, n2, r2, i2, a2, o2) {
6604
- let s2 = n2 * 30, c2 = s2 + 30, l2 = Z(s2, r2, t2), u2 = Z(s2, i2, t2), d2 = Z(c2, i2, t2), f2 = Z(c2, r2, t2), p2 = ["M ".concat(l2.x.toFixed(2), " ").concat(l2.y.toFixed(2)), "L ".concat(u2.x.toFixed(2), " ").concat(u2.y.toFixed(2)), "A ".concat(i2, " ").concat(i2, " 0 0 0 ").concat(d2.x.toFixed(2), " ").concat(d2.y.toFixed(2)), "L ".concat(f2.x.toFixed(2), " ").concat(f2.y.toFixed(2)), "A ".concat(r2, " ").concat(r2, " 0 0 1 ").concat(l2.x.toFixed(2), " ").concat(l2.y.toFixed(2)), "Z"].join(" "), m2 = Q("path");
6604
+ var hg = ["#e85c1a", "#3da84a", "#2196d4", "#6b4cc8", "#e85c1a", "#3da84a", "#2196d4", "#6b4cc8", "#e85c1a", "#3da84a", "#2196d4", "#6b4cc8"];
6605
+ function gg(e4, t2, n2, r2, i2, a2, o2) {
6606
+ let s2 = n2 * 30, c2 = s2 + 30, l2 = Y(s2, r2, t2), u2 = Y(s2, i2, t2), d2 = Y(c2, i2, t2), f2 = Y(c2, r2, t2), p2 = ["M ".concat(l2.x.toFixed(2), " ").concat(l2.y.toFixed(2)), "L ".concat(u2.x.toFixed(2), " ").concat(u2.y.toFixed(2)), "A ".concat(i2, " ").concat(i2, " 0 0 0 ").concat(d2.x.toFixed(2), " ").concat(d2.y.toFixed(2)), "L ".concat(f2.x.toFixed(2), " ").concat(f2.y.toFixed(2)), "A ".concat(r2, " ").concat(r2, " 0 0 1 ").concat(l2.x.toFixed(2), " ").concat(l2.y.toFixed(2)), "Z"].join(" "), m2 = X("path");
6605
6607
  m2.setAttribute("d", p2), m2.setAttribute("fill", a2), m2.setAttribute("fill-opacity", String(o2)), m2.setAttribute("pointer-events", "none"), e4.appendChild(m2);
6606
6608
  }
6607
- var hg = /* @__PURE__ */ new Set(["sun", "moon", "mercury", "venus", "mars", "jupiter", "saturn", "uranus", "neptune", "pluto", "chiron", "north node", "south node", "true node", "north_node", "south_node", "true_node", "asc", "mc"]);
6608
- function gg(e4) {
6609
+ var _g = /* @__PURE__ */ new Set(["sun", "moon", "mercury", "venus", "mars", "jupiter", "saturn", "uranus", "neptune", "pluto", "chiron", "north node", "south node", "true node", "north_node", "south_node", "true_node", "asc", "mc"]);
6610
+ function vg(e4) {
6609
6611
  let t2 = (e4 % 360 + 360) % 360, n2 = Math.floor(t2 / 30), r2 = Math.floor(t2 % 30);
6610
- return "".concat(r2, "\xB0").concat(Math.floor((t2 % 30 - r2) * 60).toString().padStart(2, "0"), "\u2032 ").concat(sg[n2]);
6612
+ return "".concat(r2, "\xB0").concat(Math.floor((t2 % 30 - r2) * 60).toString().padStart(2, "0"), "\u2032 ").concat(lg[n2]);
6611
6613
  }
6612
- function _g(e4) {
6614
+ function Z(e4) {
6613
6615
  return e4.replace(/\b\w/g, (e5) => e5.toUpperCase());
6614
6616
  }
6615
- function $(e4) {
6617
+ function Q(e4) {
6616
6618
  return String(e4).replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;");
6617
6619
  }
6618
- function vg(e4) {
6619
- return Array.isArray(e4) ? e4.filter((e5) => e5 && typeof e5.longitude == "number" && isFinite(e5.longitude)) : e4 && typeof e4 == "object" ? Object.entries(e4).filter(([e5]) => hg.has(e5.toLowerCase())).map(([e5, t2]) => {
6620
+ function yg(e4) {
6621
+ return Array.isArray(e4) ? e4.filter((e5) => e5 && typeof e5.longitude == "number" && isFinite(e5.longitude)) : e4 && typeof e4 == "object" ? Object.entries(e4).filter(([e5]) => _g.has(e5.toLowerCase())).map(([e5, t2]) => {
6620
6622
  var n2, r2, i2, a2, o2, s2;
6621
6623
  return { name: e5.toLowerCase(), longitude: (n2 = (r2 = t2.longitude) == null ? t2.lon : r2) == null ? 0 : n2, speed: (i2 = t2.longitude_speed) == null ? t2.speed : i2, retrograde: !!((a2 = t2.is_retrograde) == null ? t2.retrograde : a2), sign: (o2 = t2.sign_name) == null ? t2.sign : o2, house: (s2 = t2.house_number) == null ? t2.house : s2 };
6622
6624
  }) : [];
6623
6625
  }
6624
- var yg = [{ type: "conjunction", angle: 0, orb: 8 }, { type: "opposition", angle: 180, orb: 8 }, { type: "trine", angle: 120, orb: 6 }, { type: "square", angle: 90, orb: 5 }, { type: "sextile", angle: 60, orb: 4 }];
6625
- function bg(e4, t2) {
6626
- let n2 = [];
6627
- for (let a2 of e4) for (let e5 of t2) {
6628
- let t3 = Math.abs(a2.longitude - e5.longitude) % 360;
6626
+ var bg = [{ type: "conjunction", angle: 0, orb: 8 }, { type: "opposition", angle: 180, orb: 8 }, { type: "trine", angle: 120, orb: 6 }, { type: "square", angle: 90, orb: 5 }, { type: "sextile", angle: 60, orb: 4 }];
6627
+ function xg(e4, t2, n2 = 1) {
6628
+ let r2 = [];
6629
+ for (let o2 of e4) for (let e5 of t2) {
6630
+ let t3 = Math.abs(o2.longitude - e5.longitude) % 360;
6629
6631
  t3 > 180 && (t3 = 360 - t3);
6630
- for (let o2 of yg) {
6631
- let s2 = Math.abs(t3 - o2.angle);
6632
- if (s2 <= o2.orb) {
6633
- var r2, i2;
6634
- let c2 = ((r2 = a2.speed) == null ? 1 : r2) - ((i2 = e5.speed) == null ? 0 : i2) < 0 ? t3 < o2.angle : t3 > o2.angle;
6635
- n2.push({ planet1: a2.name, wheel1: "inner", planet2: e5.name, wheel2: "outer", type: o2.type, angle: o2.angle, orb: Math.round(s2 * 100) / 100, applying: c2 });
6632
+ for (let s2 of bg) {
6633
+ let c2 = s2.orb * n2, l2 = Math.abs(t3 - s2.angle);
6634
+ if (l2 <= c2) {
6635
+ var i2, a2;
6636
+ let n3 = ((i2 = o2.speed) == null ? 1 : i2) - ((a2 = e5.speed) == null ? 0 : a2) < 0 ? t3 < s2.angle : t3 > s2.angle;
6637
+ r2.push({ planet1: o2.name, wheel1: "inner", planet2: e5.name, wheel2: "outer", type: s2.type, angle: s2.angle, orb: Math.round(l2 * 100) / 100, applying: n3 });
6636
6638
  break;
6637
6639
  }
6638
6640
  }
6639
6641
  }
6640
- return n2.sort((e5, t3) => e5.orb - t3.orb).slice(0, 30);
6642
+ return r2.sort((e5, t3) => e5.orb - t3.orb).slice(0, 40);
6641
6643
  }
6642
- var xg = null;
6643
- function Sg(e4) {
6644
- xg = e4;
6644
+ var Sg = null;
6645
+ function Cg(e4) {
6646
+ Sg = e4;
6645
6647
  }
6646
- var Cg = null, wg = null;
6647
- function Tg() {
6648
- return wg || (wg = document.getElementById("tooltip")), wg;
6648
+ var wg = null, Tg = null;
6649
+ function Eg() {
6650
+ return Tg || (Tg = document.getElementById("tooltip")), Tg;
6649
6651
  }
6650
- function Eg(e4, t2, n2, r2, i2) {
6651
- let a2 = Tg();
6652
+ function Dg(e4, t2, n2, r2, i2) {
6653
+ let a2 = Eg();
6652
6654
  a2.innerHTML = '\n <div class="tooltip-title">'.concat(n2, '</div>\n <div class="tooltip-detail">').concat(r2, "</div>\n ").concat(i2 ? '<div class="tooltip-hint">'.concat(i2, "</div>") : "", "\n ");
6653
6655
  let o2 = a2.getBoundingClientRect(), s2 = o2.width || 240, c2 = o2.height || 80, l2 = e4 + 14, u2 = t2 + 10;
6654
6656
  l2 + s2 > window.innerWidth && (l2 = e4 - s2 - 8), u2 + c2 > window.innerHeight && (u2 = t2 - c2 - 8), a2.style.left = "".concat(l2, "px"), a2.style.top = "".concat(u2, "px"), a2.classList.add("visible");
6655
6657
  }
6656
- function Dg() {
6657
- Tg().classList.remove("visible");
6658
+ function Og() {
6659
+ Eg().classList.remove("visible");
6658
6660
  }
6659
- var Og = null, kg = null, Ag = /* @__PURE__ */ new Map();
6660
- function jg(e4) {
6661
+ var kg = null, Ag = null, jg = /* @__PURE__ */ new Map();
6662
+ function Mg(e4) {
6661
6663
  return "".concat(e4.planet1, "|inner|").concat(e4.planet2, "|outer|").concat(e4.type);
6662
6664
  }
6663
- function Mg() {
6664
- if (Og) return Og;
6665
- Og = document.createElement("div"), Og.id = "bi-info-drawer", Og.className = "info-drawer";
6665
+ function Ng() {
6666
+ if (kg) return kg;
6667
+ kg = document.createElement("div"), kg.id = "bi-info-drawer", kg.className = "info-drawer";
6666
6668
  let e4 = document.getElementById("chart-container");
6667
- if (e4 != null && e4.parentElement) e4.parentElement.insertBefore(Og, e4.nextSibling);
6669
+ if (e4 != null && e4.parentElement) e4.parentElement.insertBefore(kg, e4.nextSibling);
6668
6670
  else {
6669
6671
  var t2;
6670
- (t2 = document.getElementById("app")) == null || t2.appendChild(Og);
6672
+ (t2 = document.getElementById("app")) == null || t2.appendChild(kg);
6671
6673
  }
6672
- return Og;
6674
+ return kg;
6673
6675
  }
6674
- function Ng() {
6675
- Og == null || Og.classList.remove("open"), xg == null || xg(null);
6676
+ function Pg() {
6677
+ kg == null || kg.classList.remove("open"), Sg == null || Sg(null);
6676
6678
  }
6677
- function Pg(e4, t2, n2, r2, i2, a2, o2) {
6679
+ function Fg(e4, t2, n2, r2, i2, a2, o2) {
6678
6680
  var s2, c2, l2, u2, d2;
6679
- let f2 = Mg(), p2 = (s2 = ag[t2.name.toLowerCase()]) == null ? "\u2605" : s2, m2 = (c2 = og[Math.floor((t2.longitude % 360 + 360) % 360 / 30)]) == null ? "" : c2, h2 = fg(t2.name, t2.longitude), g2;
6681
+ let f2 = Ng(), p2 = (s2 = sg[t2.name.toLowerCase()]) == null ? "\u2605" : s2, m2 = (c2 = cg[Math.floor((t2.longitude % 360 + 360) % 360 / 30)]) == null ? "" : c2, h2 = mg(t2.name, t2.longitude), g2;
6680
6682
  g2 = n2 === "inner" ? a2 ? "".concat(a2, " \xB7 Natal") : "Inner \xB7 Natal" : i2 === "transit" ? "Outer \xB7 Transit" : o2 ? "".concat(o2, " \xB7 Synastry") : "Outer \xB7 Synastry";
6681
6683
  let _2 = n2, v2 = r2.filter((e5) => n2 === "inner" && e5.planet1 === t2.name || n2 === "outer" && e5.planet2 === t2.name).sort((e5, t3) => e5.orb - t3.orb), y2 = v2.length ? v2.map((e5) => {
6682
6684
  var t3, r3, a3, o3, s3, c3, l3;
6683
- let u3 = n2 === "inner" ? e5.planet2 : e5.planet1, d3 = (t3 = ag[u3.toLowerCase()]) == null ? u3 : t3, f3 = (r3 = (a3 = cg[(o3 = (s3 = e5.type) == null ? void 0 : s3.toLowerCase()) == null ? "" : o3]) == null ? e5.type : a3) == null ? "\u2014" : r3, p3 = lg((c3 = (l3 = e5.type) == null ? void 0 : l3.toLowerCase()) == null ? "" : c3), m3 = "".concat(e5.orb.toFixed(1), "\xB0"), h3 = i2 === "transit" ? e5.applying ? "\u2197" : "\u2198" : e5.orb <= 1 ? "exact" : e5.orb <= 3 ? "tight" : "wide";
6684
- return '<div class="aspect-row">\n <span class="aspect-dot" style="background:'.concat(p3, '"></span>\n <span class="aspect-sym" style="color:').concat(p3, '">').concat(f3, '</span>\n <span class="aspect-other">').concat($(d3), " ").concat($(_g(u3)), '</span>\n <span class="aspect-meta">').concat(m3, " ").concat(h3, "</span>\n </div>");
6685
- }).join("") : '<div class="no-aspects">No cross-aspects within orb</div>', b2 = (l2 = sg[Math.floor((t2.longitude % 360 + 360) % 360 / 30)]) == null ? "Unknown" : l2, x2 = Cg ? '<button class="ask-claude-btn" id="bi-ask-claude-planet-btn">\u2728 Ask Claude to interpret</button>' : "";
6686
- f2.innerHTML = '\n <div class="info-header">\n <span class="info-glyph">'.concat($(p2), '</span>\n <div class="info-title">\n <div style="display:flex;align-items:center;gap:6px;flex-wrap:wrap;">\n <strong>').concat($(_g(t2.name)), "</strong>\n ").concat(t2.retrograde ? "<span style='color:#e05252'>\u211E</span>" : "", "\n ").concat(h2 ? '<span class="dignity-badge '.concat(h2.cssClass, '">').concat(h2.emoji, " ").concat($(h2.label), "</span>") : "", '\n <span class="wheel-badge ').concat(_2, '">').concat($(g2), '</span>\n </div>\n <div class="info-subtitle">').concat($(m2), " ").concat($(gg(t2.longitude))).concat(t2.house ? " \xB7 House ".concat(t2.house) : "", '</div>\n </div>\n <button class="info-close" id="bi-info-close-btn">\u2715</button>\n </div>\n <div class="aspects-title">Cross-Aspects</div>\n <div class="aspects-list">').concat(y2, "</div>\n ").concat(x2, "\n "), f2.classList.add("open"), f2.scrollIntoView({ behavior: "smooth", block: "nearest" }), (u2 = document.getElementById("bi-info-close-btn")) == null || u2.addEventListener("click", () => {
6687
- Ng(), zg();
6685
+ let u3 = n2 === "inner" ? e5.planet2 : e5.planet1, d3 = (t3 = sg[u3.toLowerCase()]) == null ? u3 : t3, f3 = (r3 = (a3 = ug[(o3 = (s3 = e5.type) == null ? void 0 : s3.toLowerCase()) == null ? "" : o3]) == null ? e5.type : a3) == null ? "\u2014" : r3, p3 = dg((c3 = (l3 = e5.type) == null ? void 0 : l3.toLowerCase()) == null ? "" : c3), m3 = "".concat(e5.orb.toFixed(1), "\xB0"), h3 = i2 === "transit" ? e5.applying ? "\u2197" : "\u2198" : e5.orb <= 1 ? "exact" : e5.orb <= 3 ? "tight" : "wide";
6686
+ return '<div class="aspect-row">\n <span class="aspect-dot" style="background:'.concat(p3, '"></span>\n <span class="aspect-sym" style="color:').concat(p3, '">').concat(f3, '</span>\n <span class="aspect-other">').concat(Q(d3), " ").concat(Q(Z(u3)), '</span>\n <span class="aspect-meta">').concat(m3, " ").concat(h3, "</span>\n </div>");
6687
+ }).join("") : '<div class="no-aspects">No cross-aspects within orb</div>', b2 = (l2 = lg[Math.floor((t2.longitude % 360 + 360) % 360 / 30)]) == null ? "Unknown" : l2, x2 = wg ? '<button class="ask-claude-btn" id="bi-ask-claude-planet-btn">\u2728 Ask Claude to interpret</button>' : "";
6688
+ f2.innerHTML = '\n <div class="info-header">\n <span class="info-glyph">'.concat(Q(p2), '</span>\n <div class="info-title">\n <div style="display:flex;align-items:center;gap:6px;flex-wrap:wrap;">\n <strong>').concat(Q(Z(t2.name)), "</strong>\n ").concat(t2.retrograde ? "<span style='color:#e05252'>\u211E</span>" : "", "\n ").concat(h2 ? '<span class="dignity-badge '.concat(h2.cssClass, '">').concat(h2.emoji, " ").concat(Q(h2.label), "</span>") : "", '\n <span class="wheel-badge ').concat(_2, '">').concat(Q(g2), '</span>\n </div>\n <div class="info-subtitle">').concat(Q(m2), " ").concat(Q(vg(t2.longitude))).concat(t2.house ? " \xB7 House ".concat(t2.house) : "", '</div>\n </div>\n <button class="info-close" id="bi-info-close-btn">\u2715</button>\n </div>\n <div class="aspects-title">Cross-Aspects</div>\n <div class="aspects-list">').concat(y2, "</div>\n ").concat(x2, "\n "), f2.classList.add("open"), f2.scrollIntoView({ behavior: "smooth", block: "nearest" }), (u2 = document.getElementById("bi-info-close-btn")) == null || u2.addEventListener("click", () => {
6689
+ Pg(), Bg();
6688
6690
  }), (d2 = document.getElementById("bi-ask-claude-planet-btn")) == null || d2.addEventListener("click", () => {
6689
6691
  var e5, r3;
6690
- if (!Cg) return;
6692
+ if (!wg) return;
6691
6693
  let a3 = document.getElementById("bi-ask-claude-planet-btn");
6692
- !a3 || a3.disabled || (a3.disabled = true, a3.textContent = "\u23F3 Sending\u2026", a3.classList.add("sending"), Cg({ type: "planet", data: { planet_name: t2.name, wheel: n2, longitude: t2.longitude, sign: b2, position: "".concat(Math.floor(t2.longitude % 30), "\xB0 ").concat(b2), house: (e5 = t2.house) == null ? null : e5, retrograde: (r3 = t2.retrograde) == null ? false : r3, mode: i2, cross_aspects: v2.map((e6) => ({ type: e6.type, partner: n2 === "inner" ? e6.planet2 : e6.planet1, orb: e6.orb, applying: e6.applying, orb_label: i2 === "transit" ? e6.applying ? "applying" : "separating" : e6.orb <= 1 ? "exact" : e6.orb <= 3 ? "tight" : "wide" })) } }).then(() => {
6694
+ !a3 || a3.disabled || (a3.disabled = true, a3.textContent = "\u23F3 Sending\u2026", a3.classList.add("sending"), wg({ type: "planet", data: { planet_name: t2.name, wheel: n2, longitude: t2.longitude, sign: b2, position: "".concat(Math.floor(t2.longitude % 30), "\xB0 ").concat(b2), house: (e5 = t2.house) == null ? null : e5, retrograde: (r3 = t2.retrograde) == null ? false : r3, mode: i2, cross_aspects: v2.map((e6) => ({ type: e6.type, partner: n2 === "inner" ? e6.planet2 : e6.planet1, orb: e6.orb, applying: e6.applying, orb_label: i2 === "transit" ? e6.applying ? "applying" : "separating" : e6.orb <= 1 ? "exact" : e6.orb <= 3 ? "tight" : "wide" })) } }).then(() => {
6693
6695
  a3.textContent = "\u2713 Sent to Claude", a3.classList.remove("sending"), a3.classList.add("sent"), setTimeout(() => {
6694
6696
  a3.textContent = "\u2728 Ask Claude to interpret", a3.classList.remove("sent"), a3.disabled = false;
6695
6697
  }, 2500);
@@ -6698,15 +6700,15 @@ function Pg(e4, t2, n2, r2, i2, a2, o2) {
6698
6700
  }));
6699
6701
  });
6700
6702
  }
6701
- function Fg(e4, t2, n2, r2, i2) {
6703
+ function Ig(e4, t2, n2, r2, i2) {
6702
6704
  var a2, o2, s2, c2, l2, u2, d2, f2, p2;
6703
- let m2 = Mg(), h2 = (a2 = ag[t2.planet1.toLowerCase()]) == null ? "\u2605" : a2, g2 = (o2 = ag[t2.planet2.toLowerCase()]) == null ? "\u2605" : o2, _2 = (s2 = cg[(c2 = (l2 = t2.type) == null ? void 0 : l2.toLowerCase()) == null ? "" : c2]) == null ? t2.type : s2, v2 = lg((u2 = (d2 = t2.type) == null ? void 0 : d2.toLowerCase()) == null ? "" : u2), y2 = r2 ? "".concat(r2, "'s ").concat(_g(t2.planet1)) : _g(t2.planet1), b2 = n2 === "transit" ? "Tr. ".concat(_g(t2.planet2)) : i2 ? "".concat(i2, "'s ").concat(_g(t2.planet2)) : _g(t2.planet2), x2 = n2 === "transit" ? t2.applying ? "\u2197 Applying" : "\u2198 Separating" : t2.orb <= 1 ? "Exact" : t2.orb <= 3 ? "Tight" : "Wide", S2 = Cg ? '<button class="ask-claude-btn" id="bi-ask-claude-asp-btn">\u2728 Ask Claude to interpret</button>' : "";
6704
- m2.innerHTML = '\n <div class="info-header">\n <span class="info-glyph" style="color:'.concat(v2, '">').concat($(String(_2)), '</span>\n <div class="info-title">\n <div style="display:flex;align-items:center;gap:5px;flex-wrap:wrap;">\n <strong>').concat($(h2), " ").concat($(y2), '</strong>\n <span style="color:').concat(v2, '">').concat($(String(_2)), "</span>\n <strong>").concat($(g2), " ").concat($(b2), '</strong>\n </div>\n <div class="info-subtitle">').concat(t2.orb.toFixed(1), "\xB0 orb \xB7 ").concat($(x2), '</div>\n </div>\n <button class="info-close" id="bi-info-close-btn">\u2715</button>\n </div>\n <div style="display:flex;gap:6px;margin-bottom:10px;">\n <span class="wheel-badge inner">Inner \xB7 ').concat($(y2), '</span>\n <span class="wheel-badge outer">Outer \xB7 ').concat($(b2), "</span>\n </div>\n ").concat(S2, "\n "), m2.classList.add("open"), m2.scrollIntoView({ behavior: "smooth", block: "nearest" }), (f2 = document.getElementById("bi-info-close-btn")) == null || f2.addEventListener("click", () => {
6705
- Ng(), zg();
6705
+ let m2 = Ng(), h2 = (a2 = sg[t2.planet1.toLowerCase()]) == null ? "\u2605" : a2, g2 = (o2 = sg[t2.planet2.toLowerCase()]) == null ? "\u2605" : o2, _2 = (s2 = ug[(c2 = (l2 = t2.type) == null ? void 0 : l2.toLowerCase()) == null ? "" : c2]) == null ? t2.type : s2, v2 = dg((u2 = (d2 = t2.type) == null ? void 0 : d2.toLowerCase()) == null ? "" : u2), y2 = r2 ? "".concat(r2, "'s ").concat(Z(t2.planet1)) : Z(t2.planet1), b2 = n2 === "transit" ? "Tr. ".concat(Z(t2.planet2)) : i2 ? "".concat(i2, "'s ").concat(Z(t2.planet2)) : Z(t2.planet2), x2 = n2 === "transit" ? t2.applying ? "\u2197 Applying" : "\u2198 Separating" : t2.orb <= 1 ? "Exact" : t2.orb <= 3 ? "Tight" : "Wide", S2 = wg ? '<button class="ask-claude-btn" id="bi-ask-claude-asp-btn">\u2728 Ask Claude to interpret</button>' : "";
6706
+ m2.innerHTML = '\n <div class="info-header">\n <span class="info-glyph" style="color:'.concat(v2, '">').concat(Q(String(_2)), '</span>\n <div class="info-title">\n <div style="display:flex;align-items:center;gap:5px;flex-wrap:wrap;">\n <strong>').concat(Q(h2), " ").concat(Q(y2), '</strong>\n <span style="color:').concat(v2, '">').concat(Q(String(_2)), "</span>\n <strong>").concat(Q(g2), " ").concat(Q(b2), '</strong>\n </div>\n <div class="info-subtitle">').concat(t2.orb.toFixed(1), "\xB0 orb \xB7 ").concat(Q(x2), '</div>\n </div>\n <button class="info-close" id="bi-info-close-btn">\u2715</button>\n </div>\n <div style="display:flex;gap:6px;margin-bottom:10px;">\n <span class="wheel-badge inner">Inner \xB7 ').concat(Q(y2), '</span>\n <span class="wheel-badge outer">Outer \xB7 ').concat(Q(b2), "</span>\n </div>\n ").concat(S2, "\n "), m2.classList.add("open"), m2.scrollIntoView({ behavior: "smooth", block: "nearest" }), (f2 = document.getElementById("bi-info-close-btn")) == null || f2.addEventListener("click", () => {
6707
+ Pg(), Bg();
6706
6708
  }), (p2 = document.getElementById("bi-ask-claude-asp-btn")) == null || p2.addEventListener("click", () => {
6707
- if (!Cg) return;
6709
+ if (!wg) return;
6708
6710
  let e5 = document.getElementById("bi-ask-claude-asp-btn");
6709
- !e5 || e5.disabled || (e5.disabled = true, e5.textContent = "\u23F3 Sending\u2026", e5.classList.add("sending"), Cg({ type: "cross_aspect", data: { planet1: t2.planet1, wheel1: t2.wheel1, planet2: t2.planet2, wheel2: t2.wheel2, aspect_type: t2.type, orb: t2.orb, applying: t2.applying, mode: n2 } }).then(() => {
6711
+ !e5 || e5.disabled || (e5.disabled = true, e5.textContent = "\u23F3 Sending\u2026", e5.classList.add("sending"), wg({ type: "cross_aspect", data: { planet1: t2.planet1, wheel1: t2.wheel1, planet2: t2.planet2, wheel2: t2.wheel2, aspect_type: t2.type, orb: t2.orb, applying: t2.applying, mode: n2 } }).then(() => {
6710
6712
  e5.textContent = "\u2713 Sent to Claude", e5.classList.remove("sending"), e5.classList.add("sent"), setTimeout(() => {
6711
6713
  e5.textContent = "\u2728 Ask Claude to interpret", e5.classList.remove("sent"), e5.disabled = false;
6712
6714
  }, 2500);
@@ -6715,211 +6717,326 @@ function Fg(e4, t2, n2, r2, i2) {
6715
6717
  }));
6716
6718
  });
6717
6719
  }
6718
- function Ig(e4, t2) {
6719
- Ag.forEach(({ vis: n2, color: r2 }, i2) => {
6720
- let a2 = i2.split("|");
6721
- (t2 === "inner" ? a2[0] === e4 : a2[2] === e4) ? (n2.style.stroke = r2, n2.style.strokeOpacity = "0.92", n2.style.strokeWidth = "2", n2.removeAttribute("stroke-dasharray")) : (n2.style.strokeOpacity = "0.05", n2.style.strokeWidth = "0.7");
6722
- }), Rg(e4, t2);
6723
- }
6724
6720
  function Lg(e4, t2) {
6725
- Ag.forEach(({ vis: n2, color: r2 }, i2) => {
6726
- i2 === e4 ? (n2.style.stroke = t2, n2.style.strokeOpacity = "0.92", n2.style.strokeWidth = "2.5", n2.removeAttribute("stroke-dasharray")) : (n2.style.strokeOpacity = "0.05", n2.style.strokeWidth = "0.7");
6727
- });
6721
+ jg.forEach(({ vis: n2, color: r2, symbolEls: i2 }, a2) => {
6722
+ let o2 = a2.split("|");
6723
+ (t2 === "inner" ? o2[0] === e4 : o2[2] === e4) ? (n2.style.stroke = r2, n2.style.strokeOpacity = "0.92", n2.style.strokeWidth = "1.8", n2.removeAttribute("stroke-dasharray"), n2.setAttribute("filter", "url(#aspect-glow)"), i2.forEach((e5) => e5.style.opacity = "1")) : (n2.style.strokeOpacity = "0.05", n2.style.strokeWidth = "0.5", n2.removeAttribute("filter"), i2.forEach((e5) => e5.style.opacity = "0.15"));
6724
+ }), zg(e4, t2);
6728
6725
  }
6729
6726
  function Rg(e4, t2) {
6730
- kg == null || kg.querySelectorAll(".planet-hit").forEach((n2) => {
6727
+ jg.forEach(({ vis: n2, color: r2, symbolEls: i2 }, a2) => {
6728
+ a2 === e4 ? (n2.style.stroke = t2, n2.style.strokeOpacity = "0.95", n2.style.strokeWidth = "2", n2.removeAttribute("stroke-dasharray"), n2.setAttribute("filter", "url(#aspect-glow)"), i2.forEach((e5) => e5.style.opacity = "1")) : (n2.style.strokeOpacity = "0.05", n2.style.strokeWidth = "0.5", n2.removeAttribute("filter"), i2.forEach((e5) => e5.style.opacity = "0.15"));
6729
+ });
6730
+ }
6731
+ function zg(e4, t2) {
6732
+ Ag == null || Ag.querySelectorAll(".planet-hit").forEach((n2) => {
6731
6733
  var r2;
6732
6734
  let i2 = n2.dataset.wheel, a2 = ((r2 = n2.dataset.planet) == null ? "" : r2) === e4 && i2 === t2;
6733
6735
  n2.classList.toggle("dim", !a2);
6734
6736
  });
6735
6737
  }
6736
- function zg() {
6737
- Ag.forEach(({ vis: e4, color: t2, orb: n2 }) => {
6738
- let r2 = ug(n2 == null ? 4 : n2);
6739
- e4.style.stroke = t2, e4.style.strokeOpacity = r2.opacity, e4.style.strokeWidth = r2.width, r2.dash ? e4.setAttribute("stroke-dasharray", r2.dash) : e4.removeAttribute("stroke-dasharray");
6740
- }), kg == null || kg.querySelectorAll(".planet-hit").forEach((e4) => e4.classList.remove("dim"));
6738
+ function Bg() {
6739
+ jg.forEach(({ vis: e4, color: t2, orb: n2, symbolEls: r2 }) => {
6740
+ let i2 = fg(n2 == null ? 4 : n2);
6741
+ e4.style.stroke = t2, e4.style.strokeOpacity = i2.opacity, e4.style.strokeWidth = i2.width, e4.removeAttribute("filter"), i2.dash ? e4.setAttribute("stroke-dasharray", i2.dash) : e4.removeAttribute("stroke-dasharray"), r2.forEach((e5) => e5.style.opacity = "");
6742
+ }), Ag == null || Ag.querySelectorAll(".planet-hit").forEach((e4) => e4.classList.remove("dim")), Yg();
6743
+ }
6744
+ function Vg(e4) {
6745
+ jg.forEach(({ vis: t2, symbolEls: n2 }) => {
6746
+ t2.style.display = e4 ? "" : "none", n2.forEach((t3) => t3.style.display = e4 ? "" : "none");
6747
+ }), Ag == null || Ag.querySelectorAll(".aspect-hit").forEach((t2) => {
6748
+ t2.style.display = e4 ? "" : "none";
6749
+ });
6741
6750
  }
6742
- function Bg(e4, t2, n2, r2, i2, a2) {
6751
+ function Hg(e4, t2, n2) {
6752
+ return "".concat(e4, "|inner|").concat(t2, "|outer|").concat(n2);
6753
+ }
6754
+ function Ug(e4, t2, n2, r2, i2) {
6755
+ return t2 === "inner" && r2 === "outer" ? "".concat(e4, "|inner|").concat(n2, "|outer|").concat(i2) : r2 === "inner" && t2 === "outer" ? "".concat(n2, "|inner|").concat(e4, "|outer|").concat(i2) : [e4, n2].sort().join("|") + "|".concat(i2);
6756
+ }
6757
+ function Wg(e4, t2) {
6758
+ return e4.filter((e5) => {
6759
+ var n2;
6760
+ return ((n2 = e5.type) == null ? "" : n2).toLowerCase() === t2;
6761
+ });
6762
+ }
6763
+ function Gg(e4) {
6764
+ let t2 = [];
6765
+ if (!e4.length) return t2;
6766
+ let n2 = Wg(e4, "trine"), r2 = Wg(e4, "square"), i2 = Wg(e4, "opposition"), a2 = Wg(e4, "conjunction"), o2 = /* @__PURE__ */ new Set();
6767
+ for (let e5 = 0; e5 < n2.length; e5++) for (let r3 = e5 + 1; r3 < n2.length; r3++) {
6768
+ let i3 = n2[e5], a3 = n2[r3];
6769
+ if (i3.planet1 !== a3.planet1) continue;
6770
+ let s3 = i3.planet1, c3 = i3.planet2, l2 = a3.planet2;
6771
+ if (c3 === l2) continue;
6772
+ let u2 = [s3, c3, l2].sort().join("|");
6773
+ o2.has(u2) || (o2.add(u2), t2.push({ name: "Cross Trine", description: "".concat(Z(s3), " trines ").concat(Z(c3), " & ").concat(Z(l2)), planets: [{ name: s3, wheel: "inner" }, { name: c3, wheel: "outer" }, { name: l2, wheel: "outer" }], aspectKeys: [Hg(s3, c3, "trine"), Hg(s3, l2, "trine")] }));
6774
+ }
6775
+ let s2 = /* @__PURE__ */ new Set();
6776
+ for (let e5 of i2) {
6777
+ let n3 = e5.planet1, i3 = e5.planet2;
6778
+ for (let e6 of r2) {
6779
+ let a3, o3;
6780
+ if (e6.planet1 === n3) a3 = e6.planet2, o3 = "outer";
6781
+ else if (e6.planet2 === i3) a3 = e6.planet1, o3 = "inner";
6782
+ else continue;
6783
+ if (a3 === n3 || a3 === i3) continue;
6784
+ let c3 = [n3, i3, a3].sort().join("|");
6785
+ if (s2.has(c3)) continue;
6786
+ let l2;
6787
+ if (l2 = o3 === "outer" ? e6 : r2.find((e7) => e7.planet1 === a3 && e7.planet2 === i3), l2) {
6788
+ s2.add(c3), t2.push({ name: "Cross T-Square", description: "Apex: ".concat(Z(a3), " (").concat(o3, ")"), planets: [{ name: n3, wheel: "inner" }, { name: i3, wheel: "outer" }, { name: a3, wheel: o3 }], aspectKeys: [Hg(n3, i3, "opposition"), Ug(n3, "inner", a3, o3, "square"), Ug(a3, o3, i3, "outer", "square")] });
6789
+ break;
6790
+ }
6791
+ }
6792
+ }
6793
+ if (a2.length >= 2) {
6794
+ let e5 = /* @__PURE__ */ new Map();
6795
+ for (let t3 of a2) {
6796
+ var c2;
6797
+ let n4 = (c2 = e5.get(t3.planet1)) == null ? [] : c2;
6798
+ n4.push(t3.planet2), e5.set(t3.planet1, n4);
6799
+ }
6800
+ let n3 = /* @__PURE__ */ new Set();
6801
+ for (let [r3, i3] of e5) {
6802
+ if (i3.length < 2) continue;
6803
+ let e6 = "".concat(r3, "|").concat([...i3].sort().join("|"));
6804
+ n3.has(e6) || (n3.add(e6), t2.push({ name: "Cross Stellium", description: "".concat(Z(r3), " conjunct ").concat(i3.map(Z).join(" & "), " (cross-wheel)"), planets: [{ name: r3, wheel: "inner" }, ...i3.map((e7) => ({ name: e7, wheel: "outer" }))], aspectKeys: i3.map((e7) => Hg(r3, e7, "conjunction")) }));
6805
+ }
6806
+ }
6807
+ return t2;
6808
+ }
6809
+ var Kg = { "Cross Trine": "rgba( 82,168,224, 0.14)", "Cross T-Square": "rgba(224,138, 82, 0.14)", "Cross Stellium": "rgba(154,127,212, 0.14)" }, qg = { "Cross Trine": "rgba( 82,168,224, 0.70)", "Cross T-Square": "rgba(224,138, 82, 0.70)", "Cross Stellium": "rgba(154,127,212, 0.70)" };
6810
+ function Jg(e4, t2, n2, r2) {
6811
+ var i2, a2;
6812
+ if (!Ag) return null;
6813
+ let o2 = /* @__PURE__ */ new Map();
6814
+ for (let e5 of t2) o2.set(e5.name.toLowerCase(), e5.longitude);
6815
+ let s2 = /* @__PURE__ */ new Map();
6816
+ for (let e5 of n2) s2.set(e5.name.toLowerCase(), e5.longitude);
6817
+ let c2 = [];
6818
+ for (let { name: t3, wheel: n3 } of e4.planets) {
6819
+ let e5 = n3 === "inner" ? o2 : s2, i3 = n3 === "inner" ? ng : ag, a3 = e5.get(t3.toLowerCase());
6820
+ a3 != null && c2.push(Y(a3, i3, r2));
6821
+ }
6822
+ if (c2.length < 2) return null;
6823
+ let l2 = (i2 = Kg[e4.name]) == null ? "rgba(128,128,128,0.12)" : i2, u2 = (a2 = qg[e4.name]) == null ? "rgba(128,128,128,0.60)" : a2, d2;
6824
+ if (c2.length === 2) {
6825
+ let e5 = X("line");
6826
+ e5.setAttribute("x1", c2[0].x.toFixed(1)), e5.setAttribute("y1", c2[0].y.toFixed(1)), e5.setAttribute("x2", c2[1].x.toFixed(1)), e5.setAttribute("y2", c2[1].y.toFixed(1)), e5.setAttribute("stroke", u2), e5.setAttribute("stroke-width", "2"), e5.setAttribute("fill", "none"), d2 = e5;
6827
+ } else {
6828
+ let e5 = [...c2].sort((e6, t4) => Math.atan2(e6.y - 310, e6.x - 310) - Math.atan2(t4.y - 310, t4.x - 310)), t3 = X("polygon");
6829
+ t3.setAttribute("points", e5.map((e6) => "".concat(e6.x.toFixed(1), ",").concat(e6.y.toFixed(1))).join(" ")), t3.setAttribute("fill", l2), t3.setAttribute("stroke", u2), t3.setAttribute("stroke-width", "1.5"), t3.setAttribute("stroke-linejoin", "round"), d2 = t3;
6830
+ }
6831
+ d2.setAttribute("pointer-events", "none"), d2.setAttribute("class", "pattern-overlay");
6832
+ let f2 = Ag.querySelector(".aspect-hit");
6833
+ return f2 ? Ag.insertBefore(d2, f2) : Ag.appendChild(d2), d2;
6834
+ }
6835
+ function Yg() {
6836
+ Ag == null || Ag.querySelectorAll(".pattern-overlay").forEach((e4) => e4.remove());
6837
+ }
6838
+ function Xg(e4) {
6839
+ let t2 = new Set(e4.aspectKeys);
6840
+ jg.forEach(({ vis: e5, color: n3, symbolEls: r2 }, i2) => {
6841
+ t2.has(i2) ? (e5.style.stroke = n3, e5.style.strokeOpacity = "0.92", e5.style.strokeWidth = "1.8", e5.removeAttribute("stroke-dasharray"), e5.setAttribute("filter", "url(#aspect-glow)"), r2.forEach((e6) => e6.style.opacity = "1")) : (e5.style.strokeOpacity = "0.05", e5.style.strokeWidth = "0.5", e5.removeAttribute("filter"), r2.forEach((e6) => e6.style.opacity = "0.15"));
6842
+ });
6843
+ let n2 = new Set(e4.planets.map((e5) => "".concat(e5.name, "|").concat(e5.wheel)));
6844
+ Ag == null || Ag.querySelectorAll(".planet-hit").forEach((e5) => {
6845
+ var t3, r2;
6846
+ let i2 = "".concat((t3 = e5.dataset.planet) == null ? "" : t3, "|").concat((r2 = e5.dataset.wheel) == null ? "" : r2);
6847
+ e5.classList.toggle("dim", !n2.has(i2));
6848
+ });
6849
+ }
6850
+ function Zg(e4, t2, n2, r2, i2, a2) {
6743
6851
  var o2, s2, c2, l2, u2, d2, f2, p2, m2, h2, g2, _2;
6744
- Cg = i2 == null ? null : i2;
6852
+ wg = i2 == null ? null : i2;
6745
6853
  let v2 = (o2 = t2.mode) == null ? "synastry" : o2, y2 = (s2 = t2._birth_params_inner) == null ? void 0 : s2.location, b2 = (c2 = t2._birth_params_outer) == null ? void 0 : c2.location;
6746
- e4.innerHTML = "", Ag.clear(), Ng();
6747
- let x2 = vg(t2.inner), S2 = vg(t2.outer), C2 = (l2 = t2.inner_houses) == null ? [] : l2, w2 = (u2 = t2.cross_aspects) == null ? [] : u2;
6748
- w2.length === 0 && x2.length > 0 && S2.length > 0 && (w2 = bg(x2, S2));
6749
- let T2 = (d2 = (f2 = (p2 = C2[0]) == null ? void 0 : p2.cusp_lon) == null ? t2.ascendant : f2) == null ? 0 : d2, E2 = Q("svg");
6750
- E2.setAttribute("viewBox", "0 0 620 620"), E2.setAttribute("width", "100%"), E2.setAttribute("height", "100%"), E2.style.display = "block", e4.appendChild(E2), kg = E2, Kh(E2, "pan-zoom-controls");
6751
- let ee2 = Q("circle");
6752
- ee2.setAttribute("cx", "310"), ee2.setAttribute("cy", "310"), ee2.setAttribute("r", "304"), ee2.style.fill = "var(--bg, #faf9f5)", ee2.setAttribute("stroke", "#d4cec8"), ee2.setAttribute("stroke-width", "0.5"), ee2.setAttribute("pointer-events", "none"), E2.appendChild(ee2);
6753
- let D2 = Q("circle");
6754
- D2.setAttribute("cx", "310"), D2.setAttribute("cy", "310"), D2.setAttribute("r", String(tg)), D2.setAttribute("fill", "var(--outer-ring, #fdf5e4)"), D2.setAttribute("stroke", "var(--outer-stroke, #d4ac60)"), D2.setAttribute("stroke-width", "0.8"), D2.setAttribute("pointer-events", "none"), E2.appendChild(D2);
6755
- let te2 = Q("circle");
6756
- te2.setAttribute("cx", "310"), te2.setAttribute("cy", "310"), te2.setAttribute("r", String(ng)), te2.style.fill = "var(--bg, #faf9f5)", te2.setAttribute("stroke", "var(--outer-stroke, #d4ac60)"), te2.setAttribute("stroke-width", "0.8"), te2.setAttribute("pointer-events", "none"), E2.appendChild(te2);
6757
- for (let e5 = 0; e5 < 12; e5++) mg(E2, T2, e5, ng, tg, Vg(pg[e5]), 0.16);
6854
+ e4.innerHTML = "", jg.clear(), Pg();
6855
+ let x2 = yg(t2.inner), S2 = yg(t2.outer), C2 = (l2 = t2.inner_houses) == null ? [] : l2, w2 = (u2 = t2.cross_aspects) == null ? [] : u2;
6856
+ w2.length === 0 && x2.length > 0 && S2.length > 0 && (w2 = xg(x2, S2));
6857
+ let T2 = (d2 = (f2 = (p2 = C2[0]) == null ? void 0 : p2.cusp_lon) == null ? t2.ascendant : f2) == null ? 0 : d2, ee2 = window.matchMedia("(prefers-color-scheme: dark)").matches;
6858
+ if (!ee2) try {
6859
+ let e5 = getComputedStyle(document.body).backgroundColor.match(/\d+/g);
6860
+ e5 && e5.length >= 3 && (ee2 = (0.299 * e5[0] + 0.587 * e5[1] + 0.114 * e5[2]) / 255 < 0.35);
6861
+ } catch (e5) {
6862
+ }
6863
+ let E2 = X("svg");
6864
+ E2.setAttribute("viewBox", "0 0 620 620"), E2.setAttribute("width", "100%"), E2.setAttribute("height", "100%"), E2.style.display = "block", e4.appendChild(E2), Ag = E2;
6865
+ let D2 = X("defs");
6866
+ D2.innerHTML = '\n <filter id="aspect-glow" x="-50%" y="-50%" width="200%" height="200%">\n <feGaussianBlur in="SourceGraphic" stdDeviation="2.5" result="blur" />\n <feComposite in="SourceGraphic" in2="blur" operator="over" />\n </filter>\n ', E2.appendChild(D2), Jh(E2, "pan-zoom-controls");
6867
+ let te2 = X("g");
6868
+ te2.setAttribute("class", "chart-layer"), te2.style.setProperty("--layer-index", "1"), E2.appendChild(te2);
6869
+ let O2 = X("g");
6870
+ O2.setAttribute("class", "chart-layer"), O2.style.setProperty("--layer-index", "2"), E2.appendChild(O2);
6871
+ let ne2 = X("g");
6872
+ ne2.setAttribute("class", "chart-layer"), ne2.style.setProperty("--layer-index", "3"), E2.appendChild(ne2);
6873
+ let re2 = X("g");
6874
+ re2.setAttribute("class", "chart-layer"), re2.style.setProperty("--layer-index", "4"), E2.appendChild(re2);
6875
+ let ie2 = X("g");
6876
+ ie2.setAttribute("class", "chart-layer"), ie2.style.setProperty("--layer-index", "5"), E2.appendChild(ie2);
6877
+ let ae2 = X("g");
6878
+ E2.appendChild(ae2);
6879
+ let oe2 = X("circle");
6880
+ oe2.setAttribute("cx", "310"), oe2.setAttribute("cy", "310"), oe2.setAttribute("r", "304"), oe2.style.fill = "var(--bg, #faf9f5)", oe2.setAttribute("stroke", ee2 ? "#2a2a3a" : "#d4cec8"), oe2.setAttribute("stroke-width", "0.5"), oe2.setAttribute("pointer-events", "none"), te2.appendChild(oe2);
6881
+ let se2 = X("circle");
6882
+ se2.setAttribute("cx", "310"), se2.setAttribute("cy", "310"), se2.setAttribute("r", String(rg)), se2.setAttribute("fill", "var(--outer-ring, #fdf5e4)"), se2.setAttribute("stroke", "var(--outer-stroke, #d4ac60)"), se2.setAttribute("stroke-width", "0.8"), se2.setAttribute("pointer-events", "none"), E2.appendChild(se2);
6883
+ let ce2 = X("circle");
6884
+ ce2.setAttribute("cx", "310"), ce2.setAttribute("cy", "310"), ce2.setAttribute("r", String(ig)), ce2.style.fill = "var(--bg, #faf9f5)", ce2.setAttribute("stroke", "var(--outer-stroke, #d4ac60)"), ce2.setAttribute("stroke-width", "0.8"), ce2.setAttribute("pointer-events", "none"), E2.appendChild(ce2);
6885
+ for (let e5 = 0; e5 < 12; e5++) gg(E2, T2, e5, ig, rg, Qg(hg[e5]), 0.16);
6758
6886
  for (let e5 = 0; e5 < 12; e5++) {
6759
- let t3 = e5 * 30, { x: n3, y: r3 } = Z(t3, ng, T2), { x: i3, y: a3 } = Z(t3, tg, T2), o3 = Q("line");
6760
- o3.setAttribute("x1", n3.toFixed(1)), o3.setAttribute("y1", r3.toFixed(1)), o3.setAttribute("x2", i3.toFixed(1)), o3.setAttribute("y2", a3.toFixed(1)), o3.setAttribute("stroke", "var(--outer-stroke, #d4ac60)"), o3.setAttribute("stroke-width", "0.5"), o3.setAttribute("pointer-events", "none"), E2.appendChild(o3);
6761
- let { x: s3, y: c3 } = Z(t3 + 15, (ng + tg) / 2, T2), l3 = Q("text");
6762
- l3.setAttribute("x", s3.toFixed(1)), l3.setAttribute("y", c3.toFixed(1)), l3.setAttribute("text-anchor", "middle"), l3.setAttribute("dominant-baseline", "central"), l3.setAttribute("font-size", "12"), l3.setAttribute("fill", Vg(pg[e5])), l3.setAttribute("pointer-events", "none"), l3.style.fontFamily = "serif", l3.textContent = og[e5], E2.appendChild(l3);
6763
- }
6764
- let ne2 = Q("circle");
6765
- ne2.setAttribute("cx", "310"), ne2.setAttribute("cy", "310"), ne2.setAttribute("r", String(Yh)), ne2.setAttribute("fill", "var(--inner-ring, #f2ede6)"), ne2.setAttribute("stroke", "var(--inner-stroke, #c0b8a8)"), ne2.setAttribute("stroke-width", "0.5"), ne2.setAttribute("pointer-events", "none"), E2.appendChild(ne2);
6766
- let O2 = Q("circle");
6767
- O2.setAttribute("cx", "310"), O2.setAttribute("cy", "310"), O2.setAttribute("r", String(Xh)), O2.style.fill = "var(--bg, #faf9f5)", O2.setAttribute("stroke", "var(--inner-stroke, #c0b8a8)"), O2.setAttribute("stroke-width", "0.5"), O2.setAttribute("pointer-events", "none"), E2.appendChild(O2);
6768
- for (let e5 = 0; e5 < 12; e5++) mg(E2, T2, e5, Xh, Yh, pg[e5], 0.12);
6887
+ let t3 = e5 * 30, { x: n3, y: r3 } = Y(t3, ig, T2), { x: i3, y: a3 } = Y(t3, rg, T2), o3 = X("line");
6888
+ o3.setAttribute("x1", n3.toFixed(1)), o3.setAttribute("y1", r3.toFixed(1)), o3.setAttribute("x2", i3.toFixed(1)), o3.setAttribute("y2", a3.toFixed(1)), o3.setAttribute("stroke", "var(--outer-stroke, #d4ac60)"), o3.setAttribute("stroke-width", "0.5"), o3.setAttribute("pointer-events", "none"), O2.appendChild(o3);
6889
+ let { x: s3, y: c3 } = Y(t3 + 15, (ig + rg) / 2, T2), l3 = X("text");
6890
+ l3.setAttribute("x", s3.toFixed(1)), l3.setAttribute("y", c3.toFixed(1)), l3.setAttribute("text-anchor", "middle"), l3.setAttribute("dominant-baseline", "central"), l3.setAttribute("font-size", "12"), l3.setAttribute("fill", Qg(hg[e5])), l3.setAttribute("pointer-events", "none"), l3.style.fontFamily = "serif", l3.textContent = cg[e5], O2.appendChild(l3);
6891
+ }
6892
+ let le2 = X("circle");
6893
+ le2.setAttribute("cx", "310"), le2.setAttribute("cy", "310"), le2.setAttribute("r", String(Zh)), le2.setAttribute("fill", "var(--inner-ring, #f2ede6)"), le2.setAttribute("stroke", "var(--inner-stroke, #c0b8a8)"), le2.setAttribute("stroke-width", "0.5"), le2.setAttribute("pointer-events", "none"), O2.appendChild(le2);
6894
+ let ue2 = X("circle");
6895
+ ue2.setAttribute("cx", "310"), ue2.setAttribute("cy", "310"), ue2.setAttribute("r", String(Qh)), ue2.style.fill = "var(--bg, #faf9f5)", ue2.setAttribute("stroke", "var(--inner-stroke, #c0b8a8)"), ue2.setAttribute("stroke-width", "0.5"), ue2.setAttribute("pointer-events", "none"), O2.appendChild(ue2);
6896
+ for (let e5 = 0; e5 < 12; e5++) gg(E2, T2, e5, Qh, Zh, hg[e5], 0.12);
6769
6897
  for (let e5 = 0; e5 < 12; e5++) {
6770
- let t3 = e5 * 30, { x: n3, y: r3 } = Z(t3, Xh, T2), { x: i3, y: a3 } = Z(t3, Yh, T2), o3 = Q("line");
6771
- o3.setAttribute("x1", n3.toFixed(1)), o3.setAttribute("y1", r3.toFixed(1)), o3.setAttribute("x2", i3.toFixed(1)), o3.setAttribute("y2", a3.toFixed(1)), o3.setAttribute("stroke", "var(--inner-stroke, #c0b8a8)"), o3.setAttribute("stroke-width", "0.5"), o3.setAttribute("pointer-events", "none"), E2.appendChild(o3);
6772
- let { x: s3, y: c3 } = Z(t3 + 15, (Xh + Yh) / 2, T2), l3 = Q("text");
6773
- l3.setAttribute("x", s3.toFixed(1)), l3.setAttribute("y", c3.toFixed(1)), l3.setAttribute("text-anchor", "middle"), l3.setAttribute("dominant-baseline", "central"), l3.setAttribute("font-size", "13"), l3.setAttribute("fill", pg[e5]), l3.setAttribute("pointer-events", "none"), l3.style.fontFamily = "serif", l3.textContent = og[e5], E2.appendChild(l3);
6774
- }
6775
- let re2 = Q("g");
6776
- re2.setAttribute("pointer-events", "none"), re2.setAttribute("opacity", "0.10"), re2.setAttribute("transform", "translate(".concat(qh, ", ").concat(Jh, ")"));
6777
- let ie2 = Q("circle");
6778
- ie2.setAttribute("cx", "0"), ie2.setAttribute("cy", "0"), ie2.setAttribute("r", "46"), ie2.setAttribute("fill", "none"), ie2.setAttribute("stroke", "var(--gold, #c8a84b)"), ie2.setAttribute("stroke-width", "2"), re2.appendChild(ie2);
6779
- let ae2 = Q("circle");
6780
- ae2.setAttribute("cx", "0"), ae2.setAttribute("cy", "0"), ae2.setAttribute("r", "36"), ae2.setAttribute("fill", "none"), ae2.setAttribute("stroke", "var(--gold, #c8a84b)"), ae2.setAttribute("stroke-width", "0.7"), re2.appendChild(ae2);
6781
- let oe2 = Q("text");
6782
- oe2.setAttribute("x", "0"), oe2.setAttribute("y", "1"), oe2.setAttribute("text-anchor", "middle"), oe2.setAttribute("dominant-baseline", "central"), oe2.setAttribute("font-size", "18"), oe2.setAttribute("font-weight", "600"), oe2.setAttribute("letter-spacing", "3"), oe2.setAttribute("fill", "var(--gold, #c8a84b)"), oe2.style.fontFamily = "'Geist', system-ui, sans-serif", oe2.textContent = "OE", re2.appendChild(oe2);
6898
+ let t3 = e5 * 30, { x: n3, y: r3 } = Y(t3, Qh, T2), { x: i3, y: a3 } = Y(t3, Zh, T2), o3 = X("line");
6899
+ o3.setAttribute("x1", n3.toFixed(1)), o3.setAttribute("y1", r3.toFixed(1)), o3.setAttribute("x2", i3.toFixed(1)), o3.setAttribute("y2", a3.toFixed(1)), o3.setAttribute("stroke", "var(--inner-stroke, #c0b8a8)"), o3.setAttribute("stroke-width", "0.5"), o3.setAttribute("pointer-events", "none"), O2.appendChild(o3);
6900
+ let { x: s3, y: c3 } = Y(t3 + 15, (Qh + Zh) / 2, T2), l3 = X("text");
6901
+ l3.setAttribute("x", s3.toFixed(1)), l3.setAttribute("y", c3.toFixed(1)), l3.setAttribute("text-anchor", "middle"), l3.setAttribute("dominant-baseline", "central"), l3.setAttribute("font-size", "13"), l3.setAttribute("fill", hg[e5]), l3.setAttribute("pointer-events", "none"), l3.style.fontFamily = "serif", l3.textContent = cg[e5], O2.appendChild(l3);
6902
+ }
6903
+ let de2 = X("g");
6904
+ de2.setAttribute("pointer-events", "none"), de2.setAttribute("opacity", ee2 ? "0.18" : "0.10"), de2.setAttribute("transform", "translate(".concat(Yh, ", ").concat(Xh, ")"));
6905
+ let fe2 = X("circle");
6906
+ fe2.setAttribute("cx", "0"), fe2.setAttribute("cy", "0"), fe2.setAttribute("r", "46"), fe2.setAttribute("fill", "none"), fe2.setAttribute("stroke", "var(--gold, #c8a84b)"), fe2.setAttribute("stroke-width", "2"), de2.appendChild(fe2);
6907
+ let pe2 = X("circle");
6908
+ pe2.setAttribute("cx", "0"), pe2.setAttribute("cy", "0"), pe2.setAttribute("r", "36"), pe2.setAttribute("fill", "none"), pe2.setAttribute("stroke", "var(--gold, #c8a84b)"), pe2.setAttribute("stroke-width", "0.7"), de2.appendChild(pe2);
6909
+ let me2 = X("text");
6910
+ me2.setAttribute("x", "0"), me2.setAttribute("y", "1"), me2.setAttribute("text-anchor", "middle"), me2.setAttribute("dominant-baseline", "central"), me2.setAttribute("font-size", "18"), me2.setAttribute("font-weight", "600"), me2.setAttribute("letter-spacing", "3"), me2.setAttribute("fill", "var(--gold, #c8a84b)"), me2.style.fontFamily = "'Geist', system-ui, sans-serif", me2.textContent = "OE", de2.appendChild(me2);
6783
6911
  for (let e5 of [0, 90, 180, 270]) {
6784
- let t3 = e5 * Math.PI / 180, n3 = Math.cos(t3) * 38, r3 = Math.sin(t3) * 38, i3 = Math.cos(t3) * 46, a3 = Math.sin(t3) * 46, o3 = Q("line");
6785
- o3.setAttribute("x1", n3.toFixed(1)), o3.setAttribute("y1", r3.toFixed(1)), o3.setAttribute("x2", i3.toFixed(1)), o3.setAttribute("y2", a3.toFixed(1)), o3.setAttribute("stroke", "var(--gold, #c8a84b)"), o3.setAttribute("stroke-width", "1.5"), re2.appendChild(o3);
6786
- }
6787
- E2.appendChild(re2);
6788
- let se2 = Q("circle");
6789
- if (se2.setAttribute("cx", "310"), se2.setAttribute("cy", "310"), se2.setAttribute("r", String($h)), se2.style.fill = "var(--bg, #faf9f5)", se2.setAttribute("stroke", "var(--inner-stroke, #c0b8a8)"), se2.setAttribute("stroke-width", "0.5"), se2.setAttribute("pointer-events", "none"), E2.appendChild(se2), C2.length > 0) for (let e5 = 0; e5 < C2.length; e5++) {
6790
- let t3 = C2[e5], n3 = C2[(e5 + 1) % C2.length], r3 = [1, 4, 7, 10].includes(t3.number), { x: i3, y: a3 } = Z(t3.cusp_lon, $h, T2), { x: o3, y: s3 } = Z(t3.cusp_lon, Xh, T2), c3 = Q("line");
6791
- c3.setAttribute("x1", i3.toFixed(1)), c3.setAttribute("y1", a3.toFixed(1)), c3.setAttribute("x2", o3.toFixed(1)), c3.setAttribute("y2", s3.toFixed(1)), c3.setAttribute("stroke", r3 ? "#7060b8" : "#a89898"), c3.setAttribute("stroke-width", r3 ? "1.5" : "0.7"), c3.setAttribute("pointer-events", "none"), E2.appendChild(c3);
6792
- let l3 = (n3.cusp_lon - t3.cusp_lon + 360) % 360, { x: u3, y: d3 } = Z(t3.cusp_lon + l3 / 2, Qh, T2), f3 = Q("text");
6793
- f3.setAttribute("x", u3.toFixed(1)), f3.setAttribute("y", d3.toFixed(1)), f3.setAttribute("text-anchor", "middle"), f3.setAttribute("dominant-baseline", "central"), f3.setAttribute("font-size", "9"), f3.setAttribute("fill", r3 ? "#7060b8" : "#90808a"), f3.setAttribute("pointer-events", "none"), f3.textContent = String(t3.number), E2.appendChild(f3);
6794
- }
6795
- let ce2 = C2.find((e5) => e5.number === 1), le2 = C2.find((e5) => e5.number === 4), ue2 = C2.find((e5) => e5.number === 7), de2 = C2.find((e5) => e5.number === 10), fe2 = [{ lon: (m2 = ce2 == null ? void 0 : ce2.cusp_lon) == null ? T2 : m2, label: "ASC" }, { lon: (h2 = ue2 == null ? void 0 : ue2.cusp_lon) == null ? (T2 + 180) % 360 : h2, label: "DSC" }, { lon: (g2 = de2 == null ? void 0 : de2.cusp_lon) == null ? (T2 + 270) % 360 : g2, label: "MC" }, { lon: (_2 = le2 == null ? void 0 : le2.cusp_lon) == null ? (T2 + 90) % 360 : _2, label: "IC" }];
6796
- for (let e5 of fe2) {
6797
- let { x: t3, y: n3 } = Z(e5.lon, tg - 8, T2), r3 = Q("text");
6798
- r3.setAttribute("x", t3.toFixed(1)), r3.setAttribute("y", n3.toFixed(1)), r3.setAttribute("text-anchor", "middle"), r3.setAttribute("dominant-baseline", "central"), r3.setAttribute("font-size", "7.5"), r3.setAttribute("font-weight", "700"), r3.setAttribute("fill", "#7060b8"), r3.setAttribute("pointer-events", "none"), r3.textContent = e5.label, E2.appendChild(r3);
6912
+ let t3 = e5 * Math.PI / 180, n3 = Math.cos(t3) * 38, r3 = Math.sin(t3) * 38, i3 = Math.cos(t3) * 46, a3 = Math.sin(t3) * 46, o3 = X("line");
6913
+ o3.setAttribute("x1", n3.toFixed(1)), o3.setAttribute("y1", r3.toFixed(1)), o3.setAttribute("x2", i3.toFixed(1)), o3.setAttribute("y2", a3.toFixed(1)), o3.setAttribute("stroke", "var(--gold, #c8a84b)"), o3.setAttribute("stroke-width", "1.5"), de2.appendChild(o3);
6914
+ }
6915
+ E2.appendChild(de2);
6916
+ let he2 = X("circle");
6917
+ if (he2.setAttribute("cx", "310"), he2.setAttribute("cy", "310"), he2.setAttribute("r", String(tg)), he2.style.fill = "var(--bg, #faf9f5)", he2.setAttribute("stroke", "var(--inner-stroke, #c0b8a8)"), he2.setAttribute("stroke-width", "0.8"), he2.setAttribute("pointer-events", "none"), ne2.appendChild(he2), C2.length > 0) for (let e5 = 0; e5 < C2.length; e5++) {
6918
+ let t3 = C2[e5], n3 = C2[(e5 + 1) % C2.length], r3 = [1, 4, 7, 10].includes(t3.number), { x: i3, y: a3 } = Y(t3.cusp_lon, tg, T2), { x: o3, y: s3 } = Y(t3.cusp_lon, Qh, T2), c3 = X("line");
6919
+ c3.setAttribute("x1", i3.toFixed(1)), c3.setAttribute("y1", a3.toFixed(1)), c3.setAttribute("x2", o3.toFixed(1)), c3.setAttribute("y2", s3.toFixed(1)), c3.setAttribute("stroke", r3 ? ee2 ? "#9080d0" : "#7060b8" : ee2 ? "#504868" : "#a89898"), c3.setAttribute("stroke-width", r3 ? "1.5" : "1.0"), c3.setAttribute("pointer-events", "none"), ne2.appendChild(c3);
6920
+ let l3 = (n3.cusp_lon - t3.cusp_lon + 360) % 360, { x: u3, y: d3 } = Y(t3.cusp_lon + l3 / 2, eg, T2), f3 = X("text");
6921
+ f3.setAttribute("x", u3.toFixed(1)), f3.setAttribute("y", d3.toFixed(1)), f3.setAttribute("text-anchor", "middle"), f3.setAttribute("dominant-baseline", "central"), f3.setAttribute("font-size", "10"), f3.setAttribute("fill", r3 ? ee2 ? "#a090d8" : "#7060b8" : ee2 ? "#8878a0" : "#787080"), f3.setAttribute("font-weight", r3 ? "700" : "500"), f3.setAttribute("pointer-events", "none"), f3.textContent = String(t3.number), ne2.appendChild(f3);
6922
+ }
6923
+ let ge2 = C2.find((e5) => e5.number === 1), _e2 = C2.find((e5) => e5.number === 4), ve2 = C2.find((e5) => e5.number === 7), ye2 = C2.find((e5) => e5.number === 10), k2 = [{ lon: (m2 = ge2 == null ? void 0 : ge2.cusp_lon) == null ? T2 : m2, label: "ASC" }, { lon: (h2 = ve2 == null ? void 0 : ve2.cusp_lon) == null ? (T2 + 180) % 360 : h2, label: "DSC" }, { lon: (g2 = ye2 == null ? void 0 : ye2.cusp_lon) == null ? (T2 + 270) % 360 : g2, label: "MC" }, { lon: (_2 = _e2 == null ? void 0 : _e2.cusp_lon) == null ? (T2 + 90) % 360 : _2, label: "IC" }];
6924
+ for (let e5 of k2) {
6925
+ let { x: t3, y: n3 } = Y(e5.lon, rg - 8, T2), r3 = X("text");
6926
+ r3.setAttribute("x", t3.toFixed(1)), r3.setAttribute("y", n3.toFixed(1)), r3.setAttribute("text-anchor", "middle"), r3.setAttribute("dominant-baseline", "central"), r3.setAttribute("font-size", "11"), r3.setAttribute("font-weight", "700"), r3.setAttribute("fill", ee2 ? "#a090d8" : "#7060b8"), r3.setAttribute("pointer-events", "none"), r3.textContent = e5.label, ne2.appendChild(r3);
6799
6927
  }
6800
6928
  for (let e5 of w2) {
6801
- var pe2, me2, he2, ge2, _e2, ve2, ye2, k2, be2;
6929
+ var be2, A2, xe2, Se2, Ce2, we2, Te2, Ee2, De2;
6802
6930
  let t3 = x2.find((t4) => t4.name === e5.planet1), n3 = S2.find((t4) => t4.name === e5.planet2);
6803
6931
  if (!t3 || !n3) continue;
6804
- let i3 = lg((pe2 = (me2 = e5.type) == null ? void 0 : me2.toLowerCase()) == null ? "" : pe2), a3 = ug(e5.orb), { x: o3, y: s3 } = Z(t3.longitude, eg, T2), { x: c3, y: l3 } = Z(n3.longitude, ng, T2), u3 = Q("line");
6805
- u3.setAttribute("x1", o3.toFixed(1)), u3.setAttribute("y1", s3.toFixed(1)), u3.setAttribute("x2", c3.toFixed(1)), u3.setAttribute("y2", l3.toFixed(1)), a3.dash && u3.setAttribute("stroke-dasharray", a3.dash), u3.setAttribute("pointer-events", "none"), u3.style.stroke = i3, u3.style.strokeOpacity = a3.opacity, u3.style.strokeWidth = a3.width, E2.appendChild(u3);
6806
- let d3 = (o3 + c3) / 2, f3 = (s3 + l3) / 2;
6807
- if (Math.hypot(c3 - o3, l3 - s3) > 40) {
6808
- var A2, xe2, Se2;
6809
- let t4 = (A2 = cg[(xe2 = (Se2 = e5.type) == null ? void 0 : Se2.toLowerCase()) == null ? "" : xe2]) == null ? "" : A2;
6932
+ let i3 = dg((be2 = (A2 = e5.type) == null ? void 0 : A2.toLowerCase()) == null ? "" : be2), a3 = fg(e5.orb), { x: o3, y: s3 } = Y(t3.longitude, ng, T2), { x: c3, y: l3 } = Y(n3.longitude, ig, T2), u3 = X("line");
6933
+ u3.setAttribute("x1", o3.toFixed(1)), u3.setAttribute("y1", s3.toFixed(1)), u3.setAttribute("x2", c3.toFixed(1)), u3.setAttribute("y2", l3.toFixed(1)), a3.dash && u3.setAttribute("stroke-dasharray", a3.dash), u3.setAttribute("stroke-linecap", "round"), u3.setAttribute("pointer-events", "none"), u3.style.stroke = i3, u3.style.strokeOpacity = a3.opacity, u3.style.strokeWidth = a3.width, re2.appendChild(u3);
6934
+ let d3 = (o3 + c3) / 2, f3 = (s3 + l3) / 2, p3 = Math.hypot(c3 - o3, l3 - s3), m3 = [];
6935
+ if (p3 > 40) {
6936
+ var Oe2, ke2, Ae2;
6937
+ let t4 = (Oe2 = ug[(ke2 = (Ae2 = e5.type) == null ? void 0 : Ae2.toLowerCase()) == null ? "" : ke2]) == null ? "" : Oe2;
6810
6938
  if (t4) {
6811
- let e6 = Q("circle");
6812
- e6.setAttribute("cx", d3.toFixed(1)), e6.setAttribute("cy", f3.toFixed(1)), e6.setAttribute("r", "8"), e6.setAttribute("fill", "var(--bg, #0a0a10)"), e6.setAttribute("stroke", i3), e6.setAttribute("stroke-opacity", "0.4"), e6.setAttribute("stroke-width", "0.8"), e6.setAttribute("pointer-events", "none"), E2.appendChild(e6);
6813
- let n4 = Q("text");
6814
- n4.setAttribute("x", d3.toFixed(1)), n4.setAttribute("y", f3.toFixed(1)), n4.setAttribute("text-anchor", "middle"), n4.setAttribute("dominant-baseline", "central"), n4.setAttribute("font-size", "10"), n4.setAttribute("fill", i3), n4.setAttribute("pointer-events", "none"), n4.textContent = t4, E2.appendChild(n4);
6939
+ let e6 = X("circle");
6940
+ e6.setAttribute("cx", d3.toFixed(1)), e6.setAttribute("cy", f3.toFixed(1)), e6.setAttribute("r", "9"), e6.setAttribute("fill", "var(--bg, #0a0a10)"), e6.setAttribute("stroke", i3), e6.setAttribute("stroke-opacity", "0.30"), e6.setAttribute("stroke-width", "0.6"), e6.setAttribute("pointer-events", "none"), e6.classList.add("aspect-symbol-group"), ae2.appendChild(e6), m3.push(e6);
6941
+ let n4 = X("text");
6942
+ n4.setAttribute("x", d3.toFixed(1)), n4.setAttribute("y", f3.toFixed(1)), n4.setAttribute("text-anchor", "middle"), n4.setAttribute("dominant-baseline", "central"), n4.setAttribute("font-size", "10"), n4.setAttribute("fill", i3), n4.setAttribute("pointer-events", "none"), n4.classList.add("aspect-symbol-group"), n4.textContent = t4, ae2.appendChild(n4), m3.push(n4);
6815
6943
  }
6816
6944
  }
6817
- let p3 = Q("line");
6818
- p3.setAttribute("x1", o3.toFixed(1)), p3.setAttribute("y1", s3.toFixed(1)), p3.setAttribute("x2", c3.toFixed(1)), p3.setAttribute("y2", l3.toFixed(1)), p3.setAttribute("stroke", "transparent"), p3.setAttribute("stroke-width", "20"), p3.setAttribute("fill", "none"), p3.setAttribute("class", "hit-region aspect-hit"), p3.style.pointerEvents = "all", Hg(p3, "Aspect: ".concat(e5.type || "Aspect", " between inner ").concat(e5.planet1, " and outer ").concat(e5.planet2));
6819
- let m3 = (he2 = ag[t3.name.toLowerCase()]) == null ? t3.name : he2, h3 = (ge2 = ag[n3.name.toLowerCase()]) == null ? n3.name : ge2, g3 = (_e2 = (ve2 = cg[(ye2 = (k2 = e5.type) == null ? void 0 : k2.toLowerCase()) == null ? "" : ye2]) == null ? e5.type : ve2) == null ? "" : _e2, _3 = v2 === "transit" ? e5.applying ? " (applying)" : " (separating)" : e5.orb <= 1 ? " (exact)" : e5.orb <= 3 ? " (tight)" : " (wide)", C3 = "".concat(m3, " ").concat(g3, " ").concat(h3, " \xB7 ").concat(e5.orb.toFixed(1), "\xB0 orb").concat(_3);
6820
- p3.addEventListener("mouseenter", (t4) => {
6945
+ let h3 = X("line");
6946
+ h3.setAttribute("x1", o3.toFixed(1)), h3.setAttribute("y1", s3.toFixed(1)), h3.setAttribute("x2", c3.toFixed(1)), h3.setAttribute("y2", l3.toFixed(1)), h3.setAttribute("stroke", "transparent"), h3.setAttribute("stroke-width", "20"), h3.setAttribute("fill", "none"), h3.setAttribute("class", "hit-region aspect-hit"), h3.style.pointerEvents = "all", $g(h3, "Aspect: ".concat(e5.type || "Aspect", " between inner ").concat(e5.planet1, " and outer ").concat(e5.planet2));
6947
+ let g3 = (xe2 = sg[t3.name.toLowerCase()]) == null ? t3.name : xe2, _3 = (Se2 = sg[n3.name.toLowerCase()]) == null ? n3.name : Se2, C3 = (Ce2 = (we2 = ug[(Te2 = (Ee2 = e5.type) == null ? void 0 : Ee2.toLowerCase()) == null ? "" : Te2]) == null ? e5.type : we2) == null ? "" : Ce2, w3 = v2 === "transit" ? e5.applying ? " (applying)" : " (separating)" : e5.orb <= 1 ? " (exact)" : e5.orb <= 3 ? " (tight)" : " (wide)", ee3 = "".concat(g3, " ").concat(C3, " ").concat(_3, " \xB7 ").concat(e5.orb.toFixed(1), "\xB0 orb").concat(w3);
6948
+ h3.addEventListener("mouseenter", (t4) => {
6821
6949
  var n4;
6822
- return Eg(t4.clientX, t4.clientY, _g((n4 = e5.type) == null ? "Cross-Aspect" : n4), C3, "Click for interpretation");
6823
- }), p3.addEventListener("mousemove", (t4) => {
6950
+ return Dg(t4.clientX, t4.clientY, Z((n4 = e5.type) == null ? "Cross-Aspect" : n4), ee3, "Click for interpretation");
6951
+ }), h3.addEventListener("mousemove", (t4) => {
6824
6952
  var n4;
6825
- return Eg(t4.clientX, t4.clientY, _g((n4 = e5.type) == null ? "Cross-Aspect" : n4), C3, "Click for interpretation");
6826
- }), p3.addEventListener("mouseleave", Dg), p3.addEventListener("click", (t4) => {
6953
+ return Dg(t4.clientX, t4.clientY, Z((n4 = e5.type) == null ? "Cross-Aspect" : n4), ee3, "Click for interpretation");
6954
+ }), h3.addEventListener("mouseleave", Og), h3.addEventListener("click", (t4) => {
6827
6955
  var n4, a4, o4, s4, c4, l4;
6828
- Dg(), Lg(jg(e5), i3), Fg(t4, e5, v2, y2, b2);
6829
- let u4 = (n4 = ag[e5.planet1.toLowerCase()]) == null ? e5.planet1 : n4, d4 = (a4 = ag[e5.planet2.toLowerCase()]) == null ? e5.planet2 : a4, f4 = (o4 = (s4 = cg[(c4 = (l4 = e5.type) == null ? void 0 : l4.toLowerCase()) == null ? "" : c4]) == null ? e5.type : s4) == null ? "" : o4, p4 = y2 ? "".concat(y2, "'s ").concat(u4) : "".concat(u4), m4 = v2 === "transit" ? "Tr. ".concat(d4) : b2 ? "".concat(b2, "'s ").concat(d4) : d4;
6830
- xg == null || xg("".concat(p4, " ").concat(f4, " ").concat(m4, " \xB7 ").concat(e5.orb.toFixed(1), "\xB0")), r2(e5);
6831
- }), Ag.set(jg(e5), { vis: u3, color: i3, aspectType: ((be2 = e5.type) == null ? void 0 : be2.toLowerCase()) || "unknown", orb: e5.orb }), E2.appendChild(p3);
6956
+ Og(), Rg(Mg(e5), i3), Ig(t4, e5, v2, y2, b2);
6957
+ let u4 = (n4 = sg[e5.planet1.toLowerCase()]) == null ? e5.planet1 : n4, d4 = (a4 = sg[e5.planet2.toLowerCase()]) == null ? e5.planet2 : a4, f4 = (o4 = (s4 = ug[(c4 = (l4 = e5.type) == null ? void 0 : l4.toLowerCase()) == null ? "" : c4]) == null ? e5.type : s4) == null ? "" : o4, p4 = y2 ? "".concat(y2, "'s ").concat(u4) : "".concat(u4), m4 = v2 === "transit" ? "Tr. ".concat(d4) : b2 ? "".concat(b2, "'s ").concat(d4) : d4;
6958
+ Sg == null || Sg("".concat(p4, " ").concat(f4, " ").concat(m4, " \xB7 ").concat(e5.orb.toFixed(1), "\xB0")), r2(e5);
6959
+ }), jg.set(Mg(e5), { vis: u3, color: i3, aspectType: ((De2 = e5.type) == null ? void 0 : De2.toLowerCase()) || "unknown", orb: e5.orb, symbolEls: m3 }), ae2.appendChild(h3);
6832
6960
  }
6833
- let Ce2 = Q("g");
6834
- Ce2.setAttribute("class", "outer-planet-group"), E2.appendChild(Ce2);
6961
+ let je2 = X("g");
6962
+ je2.setAttribute("class", "outer-planet-group"), ie2.appendChild(je2);
6835
6963
  for (let e5 of S2) {
6836
- var we2;
6837
- let t3 = (we2 = ag[e5.name.toLowerCase()]) == null ? "\u2605" : we2, { x: r3, y: i3 } = Z(e5.longitude, rg, T2), { x: a3, y: o3 } = Z(e5.longitude, ng + 5, T2), s3 = Q("circle");
6838
- s3.setAttribute("cx", a3.toFixed(1)), s3.setAttribute("cy", o3.toFixed(1)), s3.setAttribute("r", "2.5"), s3.setAttribute("fill", "var(--outer-tick, #c8860e)"), s3.setAttribute("opacity", "0.75"), s3.setAttribute("pointer-events", "none"), Ce2.appendChild(s3);
6839
- let c3 = Q("text");
6840
- c3.setAttribute("x", r3.toFixed(1)), c3.setAttribute("y", i3.toFixed(1)), c3.setAttribute("text-anchor", "middle"), c3.setAttribute("dominant-baseline", "central"), c3.setAttribute("font-size", "14"), c3.setAttribute("pointer-events", "none"), c3.style.fill = "var(--outer-glyph, #92650a)", c3.style.fontFamily = "serif", c3.textContent = t3, Ce2.appendChild(c3);
6841
- let l3 = Math.floor((e5.longitude % 360 + 360) % 360 % 30), { x: u3, y: d3 } = Z(e5.longitude, rg - 14, T2), f3 = Q("text");
6842
- if (f3.setAttribute("x", u3.toFixed(1)), f3.setAttribute("y", d3.toFixed(1)), f3.setAttribute("text-anchor", "middle"), f3.setAttribute("dominant-baseline", "central"), f3.setAttribute("font-size", "7"), f3.setAttribute("fill", "#b08030"), f3.setAttribute("pointer-events", "none"), f3.textContent = "".concat(l3, "\xB0"), Ce2.appendChild(f3), e5.retrograde) {
6843
- let { x: t4, y: n3 } = Z(e5.longitude, rg + 13, T2), r4 = Q("text");
6844
- r4.setAttribute("x", t4.toFixed(1)), r4.setAttribute("y", n3.toFixed(1)), r4.setAttribute("text-anchor", "middle"), r4.setAttribute("dominant-baseline", "central"), r4.setAttribute("font-size", "8"), r4.setAttribute("fill", "#e05252"), r4.setAttribute("pointer-events", "none"), r4.textContent = "\u211E", Ce2.appendChild(r4);
6845
- }
6846
- let p3 = fg(e5.name, e5.longitude);
6964
+ var Me2;
6965
+ let t3 = (Me2 = sg[e5.name.toLowerCase()]) == null ? "\u2605" : Me2, { x: r3, y: i3 } = Y(e5.longitude, ag, T2), { x: a3, y: o3 } = Y(e5.longitude, ig + 5, T2), s3 = X("circle");
6966
+ s3.setAttribute("cx", a3.toFixed(1)), s3.setAttribute("cy", o3.toFixed(1)), s3.setAttribute("r", "2.5"), s3.setAttribute("fill", "var(--outer-tick, #c8860e)"), s3.setAttribute("opacity", "0.75"), s3.setAttribute("pointer-events", "none"), je2.appendChild(s3);
6967
+ let c3 = X("text");
6968
+ c3.setAttribute("x", r3.toFixed(1)), c3.setAttribute("y", i3.toFixed(1)), c3.setAttribute("text-anchor", "middle"), c3.setAttribute("dominant-baseline", "central"), c3.setAttribute("font-size", "18"), c3.setAttribute("font-weight", "600"), c3.setAttribute("pointer-events", "none"), c3.style.fill = "var(--outer-glyph, #92650a)", c3.style.fontFamily = "serif", c3.textContent = t3, je2.appendChild(c3);
6969
+ let l3 = Math.floor((e5.longitude % 360 + 360) % 360 % 30), { x: u3, y: d3 } = Y(e5.longitude, ag - 14, T2), f3 = X("text");
6970
+ if (f3.setAttribute("x", u3.toFixed(1)), f3.setAttribute("y", d3.toFixed(1)), f3.setAttribute("text-anchor", "middle"), f3.setAttribute("dominant-baseline", "central"), f3.setAttribute("font-size", "8.5"), f3.setAttribute("fill", "#b08030"), f3.setAttribute("pointer-events", "none"), f3.textContent = "".concat(l3, "\xB0"), je2.appendChild(f3), e5.retrograde) {
6971
+ let { x: t4, y: n3 } = Y(e5.longitude, ag + 13, T2), r4 = X("text");
6972
+ r4.setAttribute("x", t4.toFixed(1)), r4.setAttribute("y", n3.toFixed(1)), r4.setAttribute("text-anchor", "middle"), r4.setAttribute("dominant-baseline", "central"), r4.setAttribute("font-size", "8"), r4.setAttribute("fill", "#e05252"), r4.setAttribute("pointer-events", "none"), r4.textContent = "\u211E", je2.appendChild(r4);
6973
+ }
6974
+ let p3 = mg(e5.name, e5.longitude);
6847
6975
  if (p3) {
6848
- let { x: t4, y: n3 } = Z(e5.longitude, rg + 12, T2), r4 = Q("circle");
6849
- r4.setAttribute("cx", t4.toFixed(1)), r4.setAttribute("cy", n3.toFixed(1)), r4.setAttribute("r", "2.5"), r4.setAttribute("fill", p3.positive ? "oklch(72% 0.12 80)" : "oklch(55% 0.18 20 / 0.6)"), r4.setAttribute("pointer-events", "none"), Ce2.appendChild(r4);
6976
+ let { x: t4, y: n3 } = Y(e5.longitude, ag + 12, T2), r4 = X("circle");
6977
+ r4.setAttribute("cx", t4.toFixed(1)), r4.setAttribute("cy", n3.toFixed(1)), r4.setAttribute("r", "2.5"), r4.setAttribute("fill", p3.positive ? "oklch(72% 0.12 80)" : "oklch(55% 0.18 20 / 0.6)"), r4.setAttribute("pointer-events", "none"), je2.appendChild(r4);
6850
6978
  }
6851
- let m3 = Q("circle");
6852
- m3.setAttribute("cx", r3.toFixed(1)), m3.setAttribute("cy", i3.toFixed(1)), m3.setAttribute("r", String(ig)), m3.setAttribute("fill", "transparent"), m3.setAttribute("class", "hit-region planet-hit"), m3.dataset.planet = e5.name.toLowerCase(), m3.dataset.wheel = "outer", m3.style.pointerEvents = "all", Hg(m3, "Outer Planet: ".concat(e5.name));
6853
- let h3 = "".concat(v2 === "transit" ? "Tr. " : b2 ? "".concat(b2, "'s ") : "").concat(t3, " ").concat(_g(e5.name)), g3 = p3 ? " \xB7 ".concat(p3.label) : "", _3 = "".concat(gg(e5.longitude)).concat(e5.house ? " \xB7 H".concat(e5.house) : "").concat(e5.retrograde ? " \u211E" : "").concat(g3);
6854
- m3.addEventListener("mouseenter", (e6) => Eg(e6.clientX, e6.clientY, h3, _3, "Click to explore")), m3.addEventListener("mousemove", (e6) => Eg(e6.clientX, e6.clientY, h3, _3, "Click to explore")), m3.addEventListener("mouseleave", Dg), m3.addEventListener("click", (t4) => {
6979
+ let m3 = X("circle");
6980
+ m3.setAttribute("cx", r3.toFixed(1)), m3.setAttribute("cy", i3.toFixed(1)), m3.setAttribute("r", String(og)), m3.setAttribute("fill", "transparent"), m3.setAttribute("class", "hit-region planet-hit"), m3.dataset.planet = e5.name.toLowerCase(), m3.dataset.wheel = "outer", m3.style.pointerEvents = "all", $g(m3, "Outer Planet: ".concat(e5.name));
6981
+ let h3 = "".concat(v2 === "transit" ? "Tr. " : b2 ? "".concat(b2, "'s ") : "").concat(t3, " ").concat(Z(e5.name)), g3 = p3 ? " \xB7 ".concat(p3.label) : "", _3 = "".concat(vg(e5.longitude)).concat(e5.house ? " \xB7 H".concat(e5.house) : "").concat(e5.retrograde ? " \u211E" : "").concat(g3);
6982
+ m3.addEventListener("mouseenter", (e6) => Dg(e6.clientX, e6.clientY, h3, _3, "Click to explore")), m3.addEventListener("mousemove", (e6) => Dg(e6.clientX, e6.clientY, h3, _3, "Click to explore")), m3.addEventListener("mouseleave", Og), m3.addEventListener("click", (t4) => {
6855
6983
  var r4, i4;
6856
- Dg(), Ig(e5.name, "outer"), Pg(t4, e5, "outer", w2, v2, y2, b2);
6857
- let a4 = (r4 = ag[e5.name.toLowerCase()]) == null ? "\u2605" : r4, o4 = Math.floor((e5.longitude % 360 + 360) % 360 / 30), s4 = v2 === "transit" ? "Tr. " : b2 ? "".concat(b2, "'s ") : "";
6858
- xg == null || xg("".concat(s4).concat(a4, " ").concat(_g(e5.name), " \xB7 ").concat((i4 = sg[o4]) == null ? "" : i4)), n2(e5, "outer", w2);
6859
- }), Ce2.appendChild(m3);
6984
+ Og(), Lg(e5.name, "outer"), Fg(t4, e5, "outer", w2, v2, y2, b2);
6985
+ let a4 = (r4 = sg[e5.name.toLowerCase()]) == null ? "\u2605" : r4, o4 = Math.floor((e5.longitude % 360 + 360) % 360 / 30), s4 = v2 === "transit" ? "Tr. " : b2 ? "".concat(b2, "'s ") : "";
6986
+ Sg == null || Sg("".concat(s4).concat(a4, " ").concat(Z(e5.name), " \xB7 ").concat((i4 = lg[o4]) == null ? "" : i4)), n2(e5, "outer", w2);
6987
+ }), je2.appendChild(m3);
6860
6988
  }
6861
- let Te2 = Q("g");
6862
- Te2.setAttribute("class", "inner-planet-group"), E2.appendChild(Te2);
6989
+ let Ne2 = X("g");
6990
+ Ne2.setAttribute("class", "inner-planet-group"), ie2.appendChild(Ne2);
6863
6991
  for (let e5 of x2) {
6864
- var Ee2;
6865
- let t3 = (Ee2 = ag[e5.name.toLowerCase()]) == null ? "\u2605" : Ee2, { x: r3, y: i3 } = Z(e5.longitude, Zh, T2), { x: a3, y: o3 } = Z(e5.longitude, Xh - 5, T2), s3 = Q("circle");
6866
- s3.setAttribute("cx", a3.toFixed(1)), s3.setAttribute("cy", o3.toFixed(1)), s3.setAttribute("r", "2.5"), s3.setAttribute("fill", "var(--inner-tick, #7060b8)"), s3.setAttribute("opacity", "0.65"), s3.setAttribute("pointer-events", "none"), Te2.appendChild(s3);
6867
- let c3 = Q("text");
6868
- c3.setAttribute("x", r3.toFixed(1)), c3.setAttribute("y", i3.toFixed(1)), c3.setAttribute("text-anchor", "middle"), c3.setAttribute("dominant-baseline", "central"), c3.setAttribute("font-size", "15"), c3.setAttribute("pointer-events", "none"), c3.style.fill = "var(--inner-glyph, #4a3a8a)", c3.style.fontFamily = "serif", c3.textContent = t3, Te2.appendChild(c3);
6869
- let l3 = Math.floor((e5.longitude % 360 + 360) % 360 % 30), { x: u3, y: d3 } = Z(e5.longitude, Zh - 17, T2), f3 = Q("text");
6870
- if (f3.setAttribute("x", u3.toFixed(1)), f3.setAttribute("y", d3.toFixed(1)), f3.setAttribute("text-anchor", "middle"), f3.setAttribute("dominant-baseline", "central"), f3.setAttribute("font-size", "7"), f3.setAttribute("fill", "#9080a0"), f3.setAttribute("pointer-events", "none"), f3.textContent = "".concat(l3, "\xB0"), Te2.appendChild(f3), e5.retrograde) {
6871
- let { x: t4, y: n3 } = Z(e5.longitude, Zh + 14, T2), r4 = Q("text");
6872
- r4.setAttribute("x", t4.toFixed(1)), r4.setAttribute("y", n3.toFixed(1)), r4.setAttribute("text-anchor", "middle"), r4.setAttribute("dominant-baseline", "central"), r4.setAttribute("font-size", "8"), r4.setAttribute("fill", "#e05252"), r4.setAttribute("pointer-events", "none"), r4.textContent = "\u211E", Te2.appendChild(r4);
6873
- }
6874
- let p3 = fg(e5.name, e5.longitude);
6992
+ var Pe2;
6993
+ let t3 = (Pe2 = sg[e5.name.toLowerCase()]) == null ? "\u2605" : Pe2, { x: r3, y: i3 } = Y(e5.longitude, $h, T2), { x: a3, y: o3 } = Y(e5.longitude, Qh - 5, T2), s3 = X("circle");
6994
+ s3.setAttribute("cx", a3.toFixed(1)), s3.setAttribute("cy", o3.toFixed(1)), s3.setAttribute("r", "2.5"), s3.setAttribute("fill", "var(--inner-tick, #7060b8)"), s3.setAttribute("opacity", "0.65"), s3.setAttribute("pointer-events", "none"), Ne2.appendChild(s3);
6995
+ let c3 = X("text");
6996
+ c3.setAttribute("x", r3.toFixed(1)), c3.setAttribute("y", i3.toFixed(1)), c3.setAttribute("text-anchor", "middle"), c3.setAttribute("dominant-baseline", "central"), c3.setAttribute("font-size", "18"), c3.setAttribute("font-weight", "600"), c3.setAttribute("pointer-events", "none"), c3.style.fill = ee2 ? "var(--inner-glyph, #b0a0e0)" : "var(--inner-glyph, #5a4a9a)", c3.style.fontFamily = "serif", c3.textContent = t3, Ne2.appendChild(c3);
6997
+ let l3 = Math.floor((e5.longitude % 360 + 360) % 360 % 30), { x: u3, y: d3 } = Y(e5.longitude, $h - 17, T2), f3 = X("text");
6998
+ if (f3.setAttribute("x", u3.toFixed(1)), f3.setAttribute("y", d3.toFixed(1)), f3.setAttribute("text-anchor", "middle"), f3.setAttribute("dominant-baseline", "central"), f3.setAttribute("font-size", "8.5"), f3.setAttribute("fill", ee2 ? "#b0a0c8" : "#9080a0"), f3.setAttribute("pointer-events", "none"), f3.textContent = "".concat(l3, "\xB0"), Ne2.appendChild(f3), e5.retrograde) {
6999
+ let { x: t4, y: n3 } = Y(e5.longitude, $h + 14, T2), r4 = X("text");
7000
+ r4.setAttribute("x", t4.toFixed(1)), r4.setAttribute("y", n3.toFixed(1)), r4.setAttribute("text-anchor", "middle"), r4.setAttribute("dominant-baseline", "central"), r4.setAttribute("font-size", "8"), r4.setAttribute("fill", "#e05252"), r4.setAttribute("pointer-events", "none"), r4.textContent = "\u211E", Ne2.appendChild(r4);
7001
+ }
7002
+ let p3 = mg(e5.name, e5.longitude);
6875
7003
  if (p3) {
6876
- let { x: t4, y: n3 } = Z(e5.longitude, Zh + 12, T2), r4 = Q("circle");
6877
- r4.setAttribute("cx", t4.toFixed(1)), r4.setAttribute("cy", n3.toFixed(1)), r4.setAttribute("r", "2.5"), r4.setAttribute("fill", p3.positive ? "oklch(72% 0.12 80)" : "oklch(55% 0.18 20 / 0.6)"), r4.setAttribute("pointer-events", "none"), Te2.appendChild(r4);
7004
+ let { x: t4, y: n3 } = Y(e5.longitude, $h + 12, T2), r4 = X("circle");
7005
+ r4.setAttribute("cx", t4.toFixed(1)), r4.setAttribute("cy", n3.toFixed(1)), r4.setAttribute("r", "2.5"), r4.setAttribute("fill", p3.positive ? "oklch(72% 0.12 80)" : "oklch(55% 0.18 20 / 0.6)"), r4.setAttribute("pointer-events", "none"), Ne2.appendChild(r4);
6878
7006
  }
6879
- let m3 = Q("circle");
6880
- m3.setAttribute("cx", r3.toFixed(1)), m3.setAttribute("cy", i3.toFixed(1)), m3.setAttribute("r", String(ig)), m3.setAttribute("fill", "transparent"), m3.setAttribute("class", "hit-region planet-hit"), m3.dataset.planet = e5.name.toLowerCase(), m3.dataset.wheel = "inner", m3.style.pointerEvents = "all", Hg(m3, "Inner Planet: ".concat(e5.name));
6881
- let h3 = y2 ? "".concat(y2, "'s ").concat(t3, " ").concat(_g(e5.name)) : "".concat(t3, " ").concat(_g(e5.name), " (natal)"), g3 = p3 ? " \xB7 ".concat(p3.label) : "", _3 = "".concat(gg(e5.longitude)).concat(e5.house ? " \xB7 H".concat(e5.house) : "").concat(e5.retrograde ? " \u211E" : "").concat(g3);
6882
- m3.addEventListener("mouseenter", (e6) => Eg(e6.clientX, e6.clientY, h3, _3, "Click to explore")), m3.addEventListener("mousemove", (e6) => Eg(e6.clientX, e6.clientY, h3, _3, "Click to explore")), m3.addEventListener("mouseleave", Dg), m3.addEventListener("click", (t4) => {
7007
+ let m3 = X("circle");
7008
+ m3.setAttribute("cx", r3.toFixed(1)), m3.setAttribute("cy", i3.toFixed(1)), m3.setAttribute("r", String(og)), m3.setAttribute("fill", "transparent"), m3.setAttribute("class", "hit-region planet-hit"), m3.dataset.planet = e5.name.toLowerCase(), m3.dataset.wheel = "inner", m3.style.pointerEvents = "all", $g(m3, "Inner Planet: ".concat(e5.name));
7009
+ let h3 = y2 ? "".concat(y2, "'s ").concat(t3, " ").concat(Z(e5.name)) : "".concat(t3, " ").concat(Z(e5.name), " (natal)"), g3 = p3 ? " \xB7 ".concat(p3.label) : "", _3 = "".concat(vg(e5.longitude)).concat(e5.house ? " \xB7 H".concat(e5.house) : "").concat(e5.retrograde ? " \u211E" : "").concat(g3);
7010
+ m3.addEventListener("mouseenter", (e6) => Dg(e6.clientX, e6.clientY, h3, _3, "Click to explore")), m3.addEventListener("mousemove", (e6) => Dg(e6.clientX, e6.clientY, h3, _3, "Click to explore")), m3.addEventListener("mouseleave", Og), m3.addEventListener("click", (t4) => {
6883
7011
  var r4, i4, a4;
6884
- Dg(), Ig(e5.name, "inner"), Pg(t4, e5, "inner", w2, v2, y2, b2);
6885
- let o4 = (r4 = ag[e5.name.toLowerCase()]) == null ? "\u2605" : r4, s4 = Math.floor((e5.longitude % 360 + 360) % 360 / 30), c4 = y2 ? "".concat(y2, "'s ").concat(o4, " ").concat(_g(e5.name), " \xB7 ").concat((i4 = sg[s4]) == null ? "" : i4) : "".concat(o4, " ").concat(_g(e5.name), " \xB7 ").concat((a4 = sg[s4]) == null ? "" : a4, " (natal)");
6886
- xg == null || xg(c4), n2(e5, "inner", w2);
6887
- }), Te2.appendChild(m3);
6888
- }
6889
- let De2 = "__biWheelClickOutside__", Oe2 = document[De2];
6890
- Oe2 && document.removeEventListener("click", Oe2, false);
6891
- let ke2 = (e5) => {
7012
+ Og(), Lg(e5.name, "inner"), Fg(t4, e5, "inner", w2, v2, y2, b2);
7013
+ let o4 = (r4 = sg[e5.name.toLowerCase()]) == null ? "\u2605" : r4, s4 = Math.floor((e5.longitude % 360 + 360) % 360 / 30), c4 = y2 ? "".concat(y2, "'s ").concat(o4, " ").concat(Z(e5.name), " \xB7 ").concat((i4 = lg[s4]) == null ? "" : i4) : "".concat(o4, " ").concat(Z(e5.name), " \xB7 ").concat((a4 = lg[s4]) == null ? "" : a4, " (natal)");
7014
+ Sg == null || Sg(c4), n2(e5, "inner", w2);
7015
+ }), Ne2.appendChild(m3);
7016
+ }
7017
+ let Fe2 = "__biWheelClickOutside__", Ie2 = document[Fe2];
7018
+ Ie2 && document.removeEventListener("click", Ie2, false);
7019
+ let Le2 = (e5) => {
6892
7020
  let t3 = e5.target;
6893
- !t3.closest(".hit-region") && !t3.closest("#bi-info-drawer") && (zg(), Ng());
7021
+ !t3.closest(".hit-region") && !t3.closest("#bi-info-drawer") && (Bg(), Pg());
6894
7022
  };
6895
- document[De2] = ke2, document.addEventListener("click", ke2, false);
6896
- let Ae2 = (e5) => {
6897
- e5.key === "Escape" && (zg(), Ng());
7023
+ document[Fe2] = Le2, document.addEventListener("click", Le2, false);
7024
+ let Re2 = (e5) => {
7025
+ e5.key === "Escape" && (Bg(), Pg());
6898
7026
  };
6899
- document.removeEventListener("keydown", window.__biWheelEscHandler, false), window.__biWheelEscHandler = Ae2, document.addEventListener("keydown", Ae2, false);
7027
+ document.removeEventListener("keydown", window.__biWheelEscHandler, false), window.__biWheelEscHandler = Re2, document.addEventListener("keydown", Re2, false);
6900
7028
  }
6901
- function Vg(e4) {
7029
+ function Qg(e4) {
6902
7030
  let t2 = parseInt(e4.slice(1, 3), 16), n2 = parseInt(e4.slice(3, 5), 16), r2 = parseInt(e4.slice(5, 7), 16), i2 = 0.6;
6903
7031
  return "rgb(".concat(Math.round(t2 * (1 - i2) + 208 * i2), ",").concat(Math.round(n2 * (1 - i2) + 144 * i2), ",").concat(Math.round(r2 * (1 - i2) + 32 * i2), ")");
6904
7032
  }
6905
- function Hg(e4, t2) {
7033
+ function $g(e4, t2) {
6906
7034
  e4 && (e4.setAttribute("tabindex", "0"), e4.setAttribute("role", "button"), e4.setAttribute("aria-label", t2), e4.addEventListener("keydown", (t3) => {
6907
7035
  let n2 = t3;
6908
7036
  (n2.key === "Enter" || n2.key === " ") && (n2.preventDefault(), e4.dispatchEvent(new MouseEvent("click", { bubbles: true, cancelable: true })));
6909
7037
  }));
6910
7038
  }
6911
- function Ug() {
6912
- let e4 = /* @__PURE__ */ new Set();
6913
- return Ag.forEach((t2) => {
6914
- t2.aspectType && e4.add(t2.aspectType);
6915
- }), Array.from(e4).sort();
6916
- }
6917
- function Wg(e4) {
6918
- Ag.forEach((t2) => {
6919
- !e4 || e4.has(t2.aspectType) ? t2.vis.style.display = "" : t2.vis.style.display = "none";
6920
- });
6921
- }
6922
- var Gg = class {
7039
+ var e_ = class {
6923
7040
  constructor(e4) {
6924
7041
  var t2, n2, r2, i2, a2, s2;
6925
7042
  o(this, "config", void 0), o(this, "params", void 0), o(this, "dateInput", void 0), o(this, "timeInput", void 0), o(this, "refreshBtn", void 0), this.config = e4, this.params = { date: ((t2 = e4.initialParams) == null ? void 0 : t2.date) || this.getTodayDate(), time: ((n2 = e4.initialParams) == null ? void 0 : n2.time) || "12:00", latitude: ((r2 = e4.initialParams) == null ? void 0 : r2.latitude) || null, longitude: ((i2 = e4.initialParams) == null ? void 0 : i2.longitude) || null, timezone: ((a2 = e4.initialParams) == null ? void 0 : a2.timezone) || null, locationName: ((s2 = e4.initialParams) == null ? void 0 : s2.locationName) || null }, this.render();
@@ -6965,30 +7082,30 @@ var Gg = class {
6965
7082
  let t2 = new Date(this.params.date);
6966
7083
  t2.setUTCDate(t2.getUTCDate() + e4), this.params.date = t2.toISOString().split("T")[0], this.dateInput.value = this.params.date, this.config.onRefresh(this.params);
6967
7084
  }
6968
- }, Kg = "oe_mcp_first_run_";
6969
- function qg(e4) {
6970
- return "".concat(Kg).concat(e4);
7085
+ }, t_ = "oe_mcp_first_run_";
7086
+ function n_(e4) {
7087
+ return "".concat(t_).concat(e4);
6971
7088
  }
6972
- function Jg(e4) {
7089
+ function r_(e4) {
6973
7090
  try {
6974
- return localStorage.getItem(qg(e4)) === "1";
7091
+ return localStorage.getItem(n_(e4)) === "1";
6975
7092
  } catch (e5) {
6976
7093
  return true;
6977
7094
  }
6978
7095
  }
6979
- function Yg(e4) {
7096
+ function i_(e4) {
6980
7097
  try {
6981
- localStorage.setItem(qg(e4), "1");
7098
+ localStorage.setItem(n_(e4), "1");
6982
7099
  } catch (e5) {
6983
7100
  }
6984
7101
  }
6985
- var Xg = { "chart-wheel": { stripIcon: "\u2726", stripTitle: "Welcome to your Natal Chart", stripHints: ["Click any <strong>planet</strong> for a deep placement reading", "Click any <strong>aspect line</strong> for its dynamic interpretation", "Click any <strong>house cusp</strong> for house themes", "Use the <strong>date controls</strong> to move through time"], modalText: "Your birth chart is now rendered \u2014 an exact celestial snapshot of the sky at your moment of birth." }, "bi-wheel": { stripIcon: "\u2295", stripTitle: "Welcome to the Bi-Wheel", stripHints: ["Click any <strong>inner planet</strong> for natal placement depth", "Click any <strong>outer planet</strong> for transit or synastry meaning", "Click a <strong>cross-aspect line</strong> for inter-chart dynamics", "Use the <strong>date controls</strong> to advance transits"], modalText: "Two charts are now layered \u2014 the inner wheel is your natal chart; the outer ring shows the second chart (transits or another person's planets)." }, bodygraph: { stripIcon: "\u25C8", stripTitle: "Welcome to your Bodygraph", stripHints: ["Click any <strong>center</strong> (defined or undefined) for its meaning", "Click any <strong>channel</strong> to explore its life theme", "Click any <strong>gate number</strong> for its I Ching hexagram reading", "Click a <strong>planet row</strong> in the sidebar for its HD role"], modalText: "Your bodygraph is now rendered \u2014 a living map of the energy centres, channels, and gates that define your design." } }, Zg = '\n .oe-welcome-backdrop {\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: rgba(0, 0, 0, 0.4);\n backdrop-filter: blur(8px);\n -webkit-backdrop-filter: blur(8px);\n z-index: 9999;\n display: flex;\n align-items: center;\n justify-content: center;\n animation: oe-fade-in 0.4s ease both;\n font-family: system-ui, sans-serif;\n }\n \n .oe-welcome-modal {\n background: linear-gradient(135deg, rgba(30,30,35,0.9) 0%, rgba(20,20,25,0.95) 100%);\n border: 1px solid rgba(255,215,0,0.15); /* Gold tint border */\n border-radius: 16px;\n padding: 32px;\n width: 90%;\n max-width: 440px;\n box-shadow: 0 20px 40px rgba(0,0,0,0.5), inset 0 1px 0 rgba(255,255,255,0.1);\n animation: oe-modal-in 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;\n display: flex;\n flex-direction: column;\n gap: 20px;\n }\n\n @keyframes oe-fade-in {\n from { opacity: 0; }\n to { opacity: 1; }\n }\n\n @keyframes oe-modal-in {\n from { opacity: 0; transform: scale(0.95) translateY(10px); }\n to { opacity: 1; transform: scale(1) translateY(0); }\n }\n\n .oe-welcome-header {\n display: flex;\n align-items: center;\n gap: 12px;\n margin-bottom: 4px;\n }\n\n .oe-welcome-icon {\n font-size: 28px;\n color: #D4AF37; /* Gold */\n line-height: 1;\n text-shadow: 0 0 10px rgba(212,175,55,0.3);\n }\n\n .oe-welcome-title {\n font-size: 20px;\n font-weight: 600;\n color: rgba(255,255,255,0.95);\n margin: 0;\n letter-spacing: 0.02em;\n }\n\n .oe-welcome-text {\n font-size: 14.5px;\n line-height: 1.5;\n color: rgba(255,255,255,0.8);\n margin: 0;\n }\n\n .oe-welcome-hints {\n display: flex;\n flex-direction: column;\n gap: 12px;\n margin: 8px 0 12px 0;\n padding: 0;\n list-style: none;\n }\n\n .oe-welcome-hints li {\n font-size: 13.5px;\n line-height: 1.4;\n color: rgba(255,255,255,0.7);\n display: flex;\n align-items: flex-start;\n gap: 10px;\n opacity: 0;\n animation: oe-fade-in 0.4s ease forwards;\n }\n\n /* Stagger the hints */\n .oe-welcome-hints li:nth-child(1) { animation-delay: 0.15s; }\n .oe-welcome-hints li:nth-child(2) { animation-delay: 0.25s; }\n .oe-welcome-hints li:nth-child(3) { animation-delay: 0.35s; }\n .oe-welcome-hints li:nth-child(4) { animation-delay: 0.45s; }\n\n .oe-welcome-hints li::before {\n content: "\u2726";\n color: rgba(212,175,55,0.7); /* Muted gold */\n font-size: 12px;\n padding-top: 2px;\n }\n \n .oe-welcome-hints strong {\n color: rgba(255,255,255,0.9);\n font-weight: 600;\n }\n\n .oe-welcome-button {\n align-self: flex-end;\n background: rgba(212,175,55,0.15);\n color: #D4AF37;\n border: 1px solid rgba(212,175,55,0.3);\n padding: 10px 24px;\n border-radius: 8px;\n font-size: 14px;\n font-weight: 600;\n cursor: pointer;\n transition: all 0.2s ease;\n margin-top: 4px;\n }\n\n .oe-welcome-button:hover {\n background: rgba(212,175,55,0.25);\n border-color: rgba(212,175,55,0.5);\n transform: translateY(-1px);\n }\n\n .oe-welcome-backdrop.is-dismissing {\n animation: oe-fade-out 0.3s ease forwards;\n }\n\n .oe-welcome-backdrop.is-dismissing .oe-welcome-modal {\n animation: oe-modal-out 0.3s cubic-bezier(0.22, 1, 0.36, 1) forwards;\n }\n\n @keyframes oe-fade-out {\n to { opacity: 0; }\n }\n\n @keyframes oe-modal-out {\n to { opacity: 0; transform: scale(0.95) translateY(10px); }\n }\n';
6986
- function Qg() {
7102
+ var a_ = { "chart-wheel": { stripIcon: "\u2726", stripTitle: "Welcome to your Natal Chart", stripHints: ["Click any <strong>planet</strong> for a deep placement reading", "Click any <strong>aspect line</strong> for its dynamic interpretation", "Click any <strong>house cusp</strong> for house themes", "Use the <strong>date controls</strong> to move through time"], modalText: "Your birth chart is now rendered \u2014 an exact celestial snapshot of the sky at your moment of birth." }, "bi-wheel": { stripIcon: "\u2295", stripTitle: "Welcome to the Bi-Wheel", stripHints: ["Click any <strong>inner planet</strong> for natal placement depth", "Click any <strong>outer planet</strong> for transit or synastry meaning", "Click a <strong>cross-aspect line</strong> for inter-chart dynamics", "Use the <strong>date controls</strong> to advance transits"], modalText: "Two charts are now layered \u2014 the inner wheel is your natal chart; the outer ring shows the second chart (transits or another person's planets)." }, bodygraph: { stripIcon: "\u25C8", stripTitle: "Welcome to your Bodygraph", stripHints: ["Click any <strong>center</strong> (defined or undefined) for its meaning", "Click any <strong>channel</strong> to explore its life theme", "Click any <strong>gate number</strong> for its I Ching hexagram reading", "Click a <strong>planet row</strong> in the sidebar for its HD role"], modalText: "Your bodygraph is now rendered \u2014 a living map of the energy centres, channels, and gates that define your design." } }, o_ = '\n .oe-welcome-backdrop {\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: rgba(0, 0, 0, 0.4);\n backdrop-filter: blur(8px);\n -webkit-backdrop-filter: blur(8px);\n z-index: 9999;\n display: flex;\n align-items: center;\n justify-content: center;\n animation: oe-fade-in 0.4s ease both;\n font-family: system-ui, sans-serif;\n }\n \n .oe-welcome-modal {\n background: linear-gradient(135deg, rgba(30,30,35,0.9) 0%, rgba(20,20,25,0.95) 100%);\n border: 1px solid rgba(255,215,0,0.15); /* Gold tint border */\n border-radius: 16px;\n padding: 32px;\n width: 90%;\n max-width: 440px;\n box-shadow: 0 20px 40px rgba(0,0,0,0.5), inset 0 1px 0 rgba(255,255,255,0.1);\n animation: oe-modal-in 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;\n display: flex;\n flex-direction: column;\n gap: 20px;\n }\n\n @keyframes oe-fade-in {\n from { opacity: 0; }\n to { opacity: 1; }\n }\n\n @keyframes oe-modal-in {\n from { opacity: 0; transform: scale(0.95) translateY(10px); }\n to { opacity: 1; transform: scale(1) translateY(0); }\n }\n\n .oe-welcome-header {\n display: flex;\n align-items: center;\n gap: 12px;\n margin-bottom: 4px;\n }\n\n .oe-welcome-icon {\n font-size: 28px;\n color: #D4AF37; /* Gold */\n line-height: 1;\n text-shadow: 0 0 10px rgba(212,175,55,0.3);\n }\n\n .oe-welcome-title {\n font-size: 20px;\n font-weight: 600;\n color: rgba(255,255,255,0.95);\n margin: 0;\n letter-spacing: 0.02em;\n }\n\n .oe-welcome-text {\n font-size: 14.5px;\n line-height: 1.5;\n color: rgba(255,255,255,0.8);\n margin: 0;\n }\n\n .oe-welcome-hints {\n display: flex;\n flex-direction: column;\n gap: 12px;\n margin: 8px 0 12px 0;\n padding: 0;\n list-style: none;\n }\n\n .oe-welcome-hints li {\n font-size: 13.5px;\n line-height: 1.4;\n color: rgba(255,255,255,0.7);\n display: flex;\n align-items: flex-start;\n gap: 10px;\n opacity: 0;\n animation: oe-fade-in 0.4s ease forwards;\n }\n\n /* Stagger the hints */\n .oe-welcome-hints li:nth-child(1) { animation-delay: 0.15s; }\n .oe-welcome-hints li:nth-child(2) { animation-delay: 0.25s; }\n .oe-welcome-hints li:nth-child(3) { animation-delay: 0.35s; }\n .oe-welcome-hints li:nth-child(4) { animation-delay: 0.45s; }\n\n .oe-welcome-hints li::before {\n content: "\u2726";\n color: rgba(212,175,55,0.7); /* Muted gold */\n font-size: 12px;\n padding-top: 2px;\n }\n \n .oe-welcome-hints strong {\n color: rgba(255,255,255,0.9);\n font-weight: 600;\n }\n\n .oe-welcome-button {\n align-self: flex-end;\n background: rgba(212,175,55,0.15);\n color: #D4AF37;\n border: 1px solid rgba(212,175,55,0.3);\n padding: 10px 24px;\n border-radius: 8px;\n font-size: 14px;\n font-weight: 600;\n cursor: pointer;\n transition: all 0.2s ease;\n margin-top: 4px;\n }\n\n .oe-welcome-button:hover {\n background: rgba(212,175,55,0.25);\n border-color: rgba(212,175,55,0.5);\n transform: translateY(-1px);\n }\n\n .oe-welcome-backdrop.is-dismissing {\n animation: oe-fade-out 0.3s ease forwards;\n }\n\n .oe-welcome-backdrop.is-dismissing .oe-welcome-modal {\n animation: oe-modal-out 0.3s cubic-bezier(0.22, 1, 0.36, 1) forwards;\n }\n\n @keyframes oe-fade-out {\n to { opacity: 0; }\n }\n\n @keyframes oe-modal-out {\n to { opacity: 0; transform: scale(0.95) translateY(10px); }\n }\n';
7103
+ function s_() {
6987
7104
  if (document.getElementById("oe-first-run-styles")) return;
6988
7105
  let e4 = document.createElement("style");
6989
- e4.id = "oe-first-run-styles", e4.textContent = Zg, document.head.appendChild(e4);
7106
+ e4.id = "oe-first-run-styles", e4.textContent = o_, document.head.appendChild(e4);
6990
7107
  }
6991
- function $g(e4, t2) {
7108
+ function c_(e4, t2) {
6992
7109
  let n2 = document.createElement("div");
6993
7110
  n2.className = "oe-welcome-backdrop";
6994
7111
  let r2 = document.createElement("div");
@@ -6996,50 +7113,137 @@ function $g(e4, t2) {
6996
7113
  let i2 = e4.stripHints.map((e5) => "<li>".concat(e5, "</li>")).join("");
6997
7114
  r2.innerHTML = '\n <div class="oe-welcome-header">\n <div class="oe-welcome-icon" aria-hidden="true">'.concat(e4.stripIcon, '</div>\n <h2 class="oe-welcome-title">').concat(e4.stripTitle, '</h2>\n </div>\n <p class="oe-welcome-text">').concat(e4.modalText, '</p>\n <ul class="oe-welcome-hints">').concat(i2, '</ul>\n <button class="oe-welcome-button" aria-label="Explore the chart">Explore</button>\n '), n2.appendChild(r2);
6998
7115
  let a2 = r2.querySelector(".oe-welcome-button"), o2 = () => {
6999
- n2.classList.add("is-dismissing"), n2.addEventListener("animationend", () => n2.remove(), { once: true }), Yg(t2);
7116
+ n2.classList.add("is-dismissing"), n2.addEventListener("animationend", () => n2.remove(), { once: true }), i_(t2);
7000
7117
  };
7001
7118
  return a2.addEventListener("click", o2), n2.addEventListener("click", (e5) => {
7002
7119
  e5.target === n2 && o2();
7003
7120
  }), n2;
7004
7121
  }
7005
- function e_(e4, t2) {
7006
- if (Jg(e4)) return;
7007
- let n2 = Xg[e4];
7008
- Qg();
7009
- let r2 = $g(n2, e4);
7122
+ function l_(e4, t2) {
7123
+ if (r_(e4)) return;
7124
+ let n2 = a_[e4];
7125
+ s_();
7126
+ let r2 = c_(n2, e4);
7010
7127
  document.body.appendChild(r2);
7011
7128
  }
7012
- var t_ = document.getElementById("chart-container"), n_ = document.getElementById("loading-state"), r_ = document.getElementById("mode-badge"), i_ = document.getElementById("chart-status"), a_ = document.getElementById("aspect-filter"), o_ = document.getElementById("param-controls-container"), s_ = new Gh({ name: "Bi-Wheel Chart Explorer", version: "1.0.0" }), c_ = null, l_ = null, u_ = false, d_ = false;
7129
+ function u_(e4, t2, n2 = []) {
7130
+ var r2, i2;
7131
+ if (!t2 || t2.querySelector("#btn-fullscreen")) return;
7132
+ let a2 = document.createElement("button");
7133
+ a2.id = "btn-fullscreen", a2.className = "pan-btn pan-btn--fullscreen", a2.setAttribute("aria-label", "Toggle fullscreen"), a2.innerHTML = '<svg width="16" height="16" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round">\n <polyline points="5,1 1,1 1,5"/>\n <polyline points="11,1 15,1 15,5"/>\n <polyline points="5,15 1,15 1,11"/>\n <polyline points="11,15 15,15 15,11"/>\n </svg>';
7134
+ let o2 = a2.innerHTML;
7135
+ function s2() {
7136
+ if (document.getElementById("fs-sidebar") || !n2.length) return;
7137
+ let e5 = document.getElementById("app"), t3 = document.getElementById("chart-container");
7138
+ if (!e5 || !t3) return;
7139
+ let r3 = document.createElement("div");
7140
+ r3.id = "fs-sidebar";
7141
+ for (let e6 of n2) {
7142
+ let t4 = document.getElementById(e6);
7143
+ t4 && r3.appendChild(t4);
7144
+ }
7145
+ t3.insertAdjacentElement("afterend", r3);
7146
+ }
7147
+ function c2() {
7148
+ let e5 = document.getElementById("fs-sidebar");
7149
+ if (!e5) return;
7150
+ let t3 = document.getElementById("app");
7151
+ if (!t3) {
7152
+ e5.remove();
7153
+ return;
7154
+ }
7155
+ for (; e5.firstChild; ) t3.appendChild(e5.firstChild);
7156
+ e5.remove();
7157
+ }
7158
+ function l2(e5) {
7159
+ let t3 = e5 === "fullscreen", n3 = document.body.classList.contains("is-fullscreen");
7160
+ document.body.classList.toggle("is-fullscreen", t3), a2.innerHTML = t3 ? '<svg width="16" height="16" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round">\n <polyline points="1,5 5,5 5,1"/>\n <polyline points="15,5 11,5 11,1"/>\n <polyline points="1,11 5,11 5,15"/>\n <polyline points="15,11 11,11 11,15"/>\n </svg>' : o2, a2.setAttribute("aria-label", t3 ? "Exit fullscreen" : "Toggle fullscreen"), t3 && !n3 && s2(), !t3 && n3 && c2();
7161
+ }
7162
+ a2.addEventListener("click", async () => {
7163
+ try {
7164
+ var t3, n3, r3, i3;
7165
+ let a3 = (t3 = e4.getHostContext) == null ? void 0 : t3.call(e4), o3 = (n3 = a3 == null ? void 0 : a3.displayMode) == null ? "inline" : n3, s3 = (r3 = a3 == null ? void 0 : a3.availableDisplayModes) == null ? [] : r3, c3 = o3 === "inline" ? "fullscreen" : "inline";
7166
+ if (s3.length > 0 && !s3.includes(c3)) {
7167
+ console.warn('[AppChrome] Display mode "'.concat(c3, '" not available. Available: ').concat(s3.join(", ")));
7168
+ return;
7169
+ }
7170
+ let u3 = await e4.requestDisplayMode({ mode: c3 });
7171
+ l2((i3 = u3 == null ? void 0 : u3.mode) == null ? "inline" : i3);
7172
+ } catch (e5) {
7173
+ console.warn("[AppChrome] requestDisplayMode failed:", e5);
7174
+ }
7175
+ }), (r2 = e4.addEventListener) == null || r2.call(e4, "hostcontextchanged", (e5) => {
7176
+ var t3;
7177
+ l2((t3 = e5 == null ? void 0 : e5.displayMode) == null ? "inline" : t3);
7178
+ });
7179
+ let u2 = (i2 = e4.getHostContext) == null ? void 0 : i2.call(e4);
7180
+ u2 != null && u2.displayMode && l2(u2.displayMode), t2.insertBefore(a2, t2.firstChild);
7181
+ }
7182
+ function d_(e4, t2) {
7183
+ e4.ontoolcancelled = (e5) => {
7184
+ var n2, r2, i2;
7185
+ let a2 = (n2 = e5.reason) == null ? "Tool call was cancelled" : n2;
7186
+ console.warn("[AppChrome] Tool cancelled:", a2), (r2 = t2.statusFn) == null || r2.call(t2, null), !t2.loadingEl.hidden && t2.loadingEl.getAttribute("hidden") === null && (t2.loadingEl.setAttribute("hidden", ""), t2.contentEl.removeAttribute("hidden")), (i2 = t2.paramControls) == null || i2.setBusy(false), f_(a2);
7187
+ };
7188
+ }
7013
7189
  function f_(e4) {
7014
- if (i_) {
7190
+ var t2;
7191
+ (t2 = document.getElementById("cancel-toast")) == null || t2.remove();
7192
+ let n2 = document.createElement("div");
7193
+ n2.id = "cancel-toast", n2.className = "cancel-toast", n2.textContent = "\u23F9 ".concat(e4), document.body.appendChild(n2), n2.offsetHeight, n2.classList.add("visible"), setTimeout(() => {
7194
+ n2.classList.remove("visible"), setTimeout(() => n2.remove(), 300);
7195
+ }, 3e3);
7196
+ }
7197
+ function p_(e4) {
7198
+ var t2;
7199
+ function n2(e5) {
7200
+ if (!e5) return;
7201
+ let t3 = e5.containerDimensions;
7202
+ if (!t3) return;
7203
+ let n3 = document.documentElement;
7204
+ t3.width && n3.style.setProperty("--host-width", "".concat(t3.width, "px")), t3.maxWidth && n3.style.setProperty("--host-max-width", "".concat(t3.maxWidth, "px")), t3.height && n3.style.setProperty("--host-height", "".concat(t3.height, "px")), t3.maxHeight && n3.style.setProperty("--host-max-height", "".concat(t3.maxHeight, "px"));
7205
+ }
7206
+ n2((t2 = e4.getHostContext) == null ? void 0 : t2.call(e4)), e4.addEventListener("hostcontextchanged", (e5) => {
7207
+ n2(e5);
7208
+ });
7209
+ }
7210
+ var m_ = document.getElementById("chart-container"), h_ = document.getElementById("loading-state"), g_ = document.getElementById("mode-badge"), __ = document.getElementById("chart-status"), v_ = document.getElementById("aspect-filter"), y_ = document.getElementById("chart-provenance"), b_ = document.getElementById("bi-patterns-strip"), x_ = document.getElementById("param-controls-container"), S_ = new qh({ name: "Bi-Wheel Chart Explorer", version: "1.0.0" }), $ = null, C_ = null, w_ = false, T_ = false;
7211
+ function E_(e4) {
7212
+ if (__) {
7015
7213
  if (!e4) {
7016
- i_.classList.remove("visible");
7214
+ __.classList.remove("visible");
7017
7215
  return;
7018
7216
  }
7019
- i_.textContent = "\xB7 ".concat(e4), i_.classList.add("visible");
7217
+ __.textContent = "\xB7 ".concat(e4), __.classList.add("visible");
7020
7218
  }
7021
7219
  }
7022
- Sg(f_);
7023
- function p_() {
7024
- n_.hidden = false, t_.hidden = true, r_.hidden = true;
7220
+ Cg(E_);
7221
+ function D_() {
7222
+ h_.hidden = false, m_.hidden = true, g_.hidden = true, y_ && (y_.hidden = true), b_ && (b_.hidden = true, b_.innerHTML = "");
7025
7223
  }
7026
- function m_() {
7027
- n_.hidden = true, t_.hidden = false, r_.hidden = false;
7224
+ function O_() {
7225
+ h_.hidden = true, m_.hidden = false, g_.hidden = false, y_ && (y_.hidden = false);
7028
7226
  }
7029
- function h_(e4) {
7030
- n_.hidden = true, t_.innerHTML = '\n <div class="error-state">\n <div class="error-icon">\u26A0\uFE0F</div>\n <p class="error-msg">'.concat(g_(e4), "</p>\n </div>"), t_.hidden = false;
7227
+ function k_(e4, t2) {
7228
+ h_.hidden = true, y_ && (y_.hidden = true);
7229
+ let n2 = t2 ? '<button class="error-retry-btn" id="error-retry-btn">\u21BA Try again</button>' : "";
7230
+ if (m_.innerHTML = '\n <div class="error-state">\n <div class="error-icon">\u26A0\uFE0F</div>\n <p class="error-msg">'.concat(A_(e4), "</p>\n ").concat(n2, "\n </div>"), t2) {
7231
+ var r2;
7232
+ (r2 = document.getElementById("error-retry-btn")) == null || r2.addEventListener("click", t2);
7233
+ }
7234
+ m_.hidden = false;
7031
7235
  }
7032
- function g_(e4) {
7236
+ function A_(e4) {
7033
7237
  return e4.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;");
7034
7238
  }
7035
- async function __(e4) {
7239
+ async function j_(e4) {
7036
7240
  try {
7037
- (await s_.sendMessage({ role: "user", content: [{ type: "text", text: e4 }] })).isError && console.error("[BiWheel] Host rejected sendMessage");
7241
+ (await S_.sendMessage({ role: "user", content: [{ type: "text", text: e4 }] })).isError && console.error("[BiWheel] Host rejected sendMessage");
7038
7242
  } catch (e5) {
7039
7243
  console.error("[BiWheel] sendMessage failed:", e5);
7040
7244
  }
7041
7245
  }
7042
- function v_(e4) {
7246
+ function M_(e4) {
7043
7247
  var t2;
7044
7248
  for (let n2 of (t2 = e4.content) == null ? [] : t2) {
7045
7249
  if (n2.type !== "text" || !n2.text) continue;
@@ -7052,58 +7256,90 @@ function v_(e4) {
7052
7256
  }
7053
7257
  return null;
7054
7258
  }
7055
- var y_ = { conjunction: "#9a7fd4", opposition: "#e05252", trine: "#52a8e0", square: "#e08a52", sextile: "#52c07a", quincunx: "#c0b052", semisquare: "#b07a5a" }, b_ = null;
7056
- function x_() {
7057
- if (!a_) return;
7058
- let e4 = Ug();
7059
- if (e4.length === 0) {
7060
- a_.setAttribute("hidden", "");
7061
- return;
7062
- }
7063
- b_ = new Set(e4);
7064
- let t2 = (e5) => e5.charAt(0).toUpperCase() + e5.slice(1);
7065
- a_.innerHTML = '\n <span class="patterns-label">Aspects:</span>\n '.concat(e4.map((e5) => {
7066
- var n2, r2;
7067
- let i2 = (n2 = y_[e5]) == null ? "#888" : n2, a2 = (r2 = cg[e5]) == null ? "" : r2;
7068
- return '\n <button class="pattern-pill aspect-type-pill active"\n data-type="'.concat(e5, '" data-color="').concat(i2, '"\n style="background:').concat(i2, ";color:#fff;border-color:").concat(i2, '"\n title="Toggle ').concat(t2(e5), ' aspects">\n ').concat(a2, " ").concat(t2(e5), "\n </button>\n ");
7069
- }).join(""), "\n "), a_.removeAttribute("hidden"), a_.querySelectorAll(".aspect-type-pill").forEach((e5) => {
7259
+ var N_ = [{ label: "Tight", mult: 0.55 }, { label: "Standard", mult: 1 }, { label: "Wide", mult: 1.6 }], P_ = true, F_ = 1;
7260
+ function I_() {
7261
+ var e4;
7262
+ if (!v_) return;
7263
+ let t2 = ((e4 = $ == null ? void 0 : $.mode) == null ? "synastry" : e4) === "transit" ? "Transit \u2192 Natal" : "Synastry \u2192 Natal";
7264
+ P_ = true, v_.innerHTML = '\n <div class="asp-panel">\n <div class="asp-section">\n <span class="asp-section-label">Aspects</span>\n <button class="aspect-toggle-btn active" id="aspect-vis-toggle"\n title="Toggle all aspect lines &amp; symbols">\n <span class="toggle-icon">\u2295</span> '.concat(t2, '\n </button>\n </div>\n <div class="asp-section">\n <span class="asp-section-label">Orb</span>\n ').concat(N_.map((e5) => '<button class="orb-preset-btn'.concat(e5.mult === F_ ? " active" : "", '" data-mult="').concat(e5.mult, '" title="').concat(e5.label, ' orbs">').concat(e5.label, "</button>")).join(""), "\n </div>\n </div>\n "), v_.removeAttribute("hidden");
7265
+ let n2 = document.getElementById("aspect-vis-toggle");
7266
+ n2 == null || n2.addEventListener("click", () => {
7267
+ P_ = !P_, Vg(P_), n2.classList.toggle("active", P_), n2.querySelector(".toggle-icon").textContent = P_ ? "\u2295" : "\u2296";
7268
+ }), v_.querySelectorAll(".orb-preset-btn").forEach((e5) => {
7070
7269
  e5.addEventListener("click", () => {
7071
- var t3, n2;
7072
- if (!b_) return;
7073
- let r2 = (t3 = e5.dataset.type) == null ? "" : t3, i2 = (n2 = e5.dataset.color) == null ? "#888" : n2;
7074
- b_.has(r2) ? (b_.delete(r2), e5.classList.remove("active"), e5.style.background = "transparent", e5.style.color = i2) : (b_.add(r2), e5.classList.add("active"), e5.style.background = i2, e5.style.color = "#fff"), Wg(b_);
7270
+ var t3;
7271
+ let n3 = parseFloat((t3 = e5.dataset.mult) == null ? "1" : t3);
7272
+ n3 !== F_ && (F_ = n3, v_.querySelectorAll(".orb-preset-btn").forEach((e6) => e6.classList.toggle("active", e6.dataset.mult === String(n3))), $ && L_($, n3));
7075
7273
  });
7076
7274
  });
7077
7275
  }
7078
- var S_ = null;
7079
- function C_(e4) {
7080
- S_ = e4, e4 ? t_.setAttribute("data-focus", e4) : t_.removeAttribute("data-focus"), r_.querySelectorAll(".mode-badge-name").forEach((t2) => {
7276
+ function L_(e4, t2) {
7277
+ var n2, r2, i2, a2;
7278
+ let o2 = yg(e4.inner), s2 = yg(e4.outer), c2 = xg(o2, s2, t2), l2 = { ...e4, cross_aspects: c2 };
7279
+ Zg(m_, l2, tv, nv, K_, X_()), P_ || Vg(false);
7280
+ let u2 = (r2 = (i2 = (a2 = ((n2 = l2.inner_houses) == null ? [] : n2)[0]) == null ? void 0 : a2.cusp_lon) == null ? l2.ascendant : i2) == null ? 0 : r2;
7281
+ ev(Gg(c2), o2, s2, u2);
7282
+ }
7283
+ var R_ = null;
7284
+ function z_(e4) {
7285
+ R_ = e4, e4 ? m_.setAttribute("data-focus", e4) : m_.removeAttribute("data-focus"), g_.querySelectorAll(".mode-badge-name").forEach((t2) => {
7081
7286
  let n2 = t2.dataset.focus;
7082
7287
  t2.classList.toggle("focused", n2 === e4);
7083
- });
7288
+ }), $ && G_($, e4);
7084
7289
  }
7085
- function w_(e4) {
7290
+ function B_(e4) {
7086
7291
  var t2, n2, r2, i2, a2, o2, s2;
7087
7292
  let c2 = (t2 = e4.mode) == null ? "synastry" : t2, l2 = (n2 = (r2 = e4._birth_params_inner) == null ? void 0 : r2.location) == null ? "Person 1" : n2, u2 = (i2 = (a2 = e4._birth_params_outer) == null ? void 0 : a2.location) == null ? c2 === "transit" ? "Transits" : "Person 2" : i2;
7088
- S_ = null, t_.removeAttribute("data-focus");
7293
+ R_ = null, m_.removeAttribute("data-focus");
7089
7294
  let d2 = "";
7090
7295
  if (c2 === "transit" && (o2 = e4._birth_params_outer) != null && o2.datetime) try {
7091
7296
  let t3 = new Date(e4._birth_params_outer.datetime);
7092
- isNaN(t3.getTime()) || (d2 = '<span class="mode-badge-date">'.concat(g_(t3.toLocaleDateString("en-US", { month: "short", day: "numeric", year: "numeric" })), "</span>"));
7297
+ isNaN(t3.getTime()) || (d2 = '<span class="mode-badge-date">'.concat(A_(t3.toLocaleDateString("en-US", { month: "short", day: "numeric", year: "numeric" })), "</span>"));
7093
7298
  } catch (e5) {
7094
7299
  }
7095
- r_.innerHTML = '\n <button class="mode-badge-name inner-name" data-focus="inner" title="Click to focus inner (natal) wheel">\n <span class="mode-badge-dot-inner"></span>'.concat(g_(l2), '\n </button>\n <button class="mode-badge-swap" title="Toggle focus">\u21C4</button>\n <button class="mode-badge-name outer-name" data-focus="outer" title="Click to focus outer (').concat(c2, ') wheel">\n <span class="mode-badge-dot-outer"></span>').concat(g_(u2), "\n </button>\n ").concat(d2), r_.querySelectorAll(".mode-badge-name").forEach((e5) => {
7300
+ g_.innerHTML = '\n <button class="mode-badge-name inner-name" data-focus="inner" title="Click to focus inner (natal) wheel">\n <span class="mode-badge-dot-inner"></span>'.concat(A_(l2), '\n </button>\n <button class="mode-badge-swap" title="Toggle focus">\u21C4</button>\n <button class="mode-badge-name outer-name" data-focus="outer" title="Click to focus outer (').concat(c2, ') wheel">\n <span class="mode-badge-dot-outer"></span>').concat(A_(u2), "\n </button>\n ").concat(d2), g_.querySelectorAll(".mode-badge-name").forEach((e5) => {
7096
7301
  e5.addEventListener("click", () => {
7097
7302
  let t3 = e5.dataset.focus;
7098
- C_(S_ === t3 ? null : t3);
7303
+ z_(R_ === t3 ? null : t3);
7099
7304
  });
7100
- }), (s2 = r_.querySelector(".mode-badge-swap")) == null || s2.addEventListener("click", () => {
7101
- C_(S_ === "inner" ? "outer" : "inner");
7305
+ }), (s2 = g_.querySelector(".mode-badge-swap")) == null || s2.addEventListener("click", () => {
7306
+ z_(R_ === "inner" ? "outer" : "inner");
7102
7307
  });
7103
7308
  }
7104
- async function T_(e4) {
7309
+ var V_ = ["Aries", "Taurus", "Gemini", "Cancer", "Leo", "Virgo", "Libra", "Scorpio", "Sagittarius", "Capricorn", "Aquarius", "Pisces"], H_ = { sun: "\u2609", moon: "\u263D", mercury: "\u263F", venus: "\u2640", mars: "\u2642", jupiter: "\u2643", saturn: "\u2644", uranus: "\u2645", neptune: "\u2646", pluto: "\u2647", asc: "AC", mc: "MC" };
7310
+ function U_(e4, t2) {
7311
+ var n2, r2;
7312
+ let i2 = e4.find((e5) => e5.name.toLowerCase() === t2);
7313
+ if (!i2) return "\u2014";
7314
+ let a2 = Math.floor((i2.longitude % 360 + 360) % 360 / 30), o2 = Math.floor(i2.longitude % 30);
7315
+ return "".concat((n2 = H_[t2]) == null ? t2 : n2, " ").concat(o2, "\xB0 ").concat((r2 = V_[a2]) == null ? "" : r2);
7316
+ }
7317
+ function W_(e4) {
7318
+ try {
7319
+ let t2 = new Date(e4);
7320
+ return isNaN(t2.getTime()) ? e4 : t2.toLocaleDateString("en-US", { month: "short", day: "numeric", year: "numeric" }) + " \xB7 " + t2.toLocaleTimeString("en-US", { hour: "numeric", minute: "2-digit", hour12: true });
7321
+ } catch (t2) {
7322
+ return e4;
7323
+ }
7324
+ }
7325
+ function G_(e4, t2) {
7326
+ var n2, r2, i2, a2, o2;
7327
+ if (!y_) return;
7328
+ let s2 = t2 == null ? "inner" : t2, c2 = s2 === "inner" ? e4.inner : e4.outer, l2 = s2 === "inner" ? e4._birth_params_inner : e4._birth_params_outer, u2 = (n2 = e4.mode) == null ? "synastry" : n2, d2 = (r2 = l2 == null ? void 0 : l2.location) == null ? s2 === "inner" ? "Inner chart" : u2 === "transit" ? "Transits" : "Outer chart" : r2, f2 = l2 != null && l2.datetime ? W_(l2.datetime) : null, p2 = (i2 = l2 == null ? void 0 : l2.timezone) == null ? null : i2, m2 = s2 === "inner" ? e4.inner_houses : (a2 = e4.outer_houses) == null ? [] : a2, h2 = (o2 = e4.house_system) == null ? m2.length > 0 ? "Placidus" : null : o2, g2 = U_(c2, "sun"), _2 = U_(c2, "moon"), v2 = U_(c2, "asc");
7329
+ if (v2 === "AC \u2014" && m2.length > 0) {
7330
+ let e5 = m2.find((e6) => e6.number === 1);
7331
+ if (e5) {
7332
+ var y2;
7333
+ let t3 = Math.floor((e5.cusp_lon % 360 + 360) % 360 / 30);
7334
+ v2 = "AC ".concat(Math.floor(e5.cusp_lon % 30), "\xB0 ").concat((y2 = V_[t3]) == null ? "" : y2);
7335
+ }
7336
+ }
7337
+ let b2 = s2 === "outer" && u2 === "transit" ? "Transit" : s2 === "outer" ? "Synastry" : "Natal";
7338
+ y_.innerHTML = '\n <div class="prov-name">'.concat(A_(d2), '\n <span class="prov-mode-tag">').concat(A_(b2), '</span>\n </div>\n <div class="prov-trio">\n <span class="prov-planet">').concat(A_(g2), '</span>\n <span class="prov-sep">\xB7</span>\n <span class="prov-planet">').concat(A_(_2), '</span>\n <span class="prov-sep">\xB7</span>\n <span class="prov-planet">').concat(A_(v2), "</span>\n </div>\n ").concat(f2 ? '<div class="prov-meta">'.concat(A_(f2)).concat(p2 ? ' <span class="prov-tz">'.concat(A_(p2), "</span>") : "", "</div>") : "", "\n ").concat(h2 ? '<div class="prov-meta">'.concat(A_(h2), " houses</div>") : "", "\n "), y_.hidden = false;
7339
+ }
7340
+ async function K_(e4) {
7105
7341
  var t2;
7106
- let n2 = (t2 = c_ == null ? void 0 : c_.mode) == null ? "synastry" : t2, r2 = "";
7342
+ let n2 = (t2 = $ == null ? void 0 : $.mode) == null ? "synastry" : t2, r2 = "";
7107
7343
  if (e4.type === "planet") {
7108
7344
  var i2, a2;
7109
7345
  let t3 = e4.data, o2 = String((i2 = t3.wheel) == null ? "inner" : i2) === "inner" ? "inner (natal)" : n2 === "transit" ? "outer (transit)" : "outer (synastry)", s2 = ((a2 = t3.cross_aspects) == null ? [] : a2).slice(0, 5).map((e5) => "\u2022 ".concat(e5.type, " with ").concat(e5.partner, " (").concat(e5.orb.toFixed(2), "\xB0 orb").concat(e5.orb_label ? ", ".concat(e5.orb_label) : "").concat(n2 === "transit" && e5.applying !== void 0 ? ", ".concat(e5.applying ? "applying" : "separating") : "", ")")).join("\n");
@@ -7112,30 +7348,30 @@ async function T_(e4) {
7112
7348
  let t3 = e4.data, i3 = n2 === "transit" ? "natal ".concat(String(t3.planet1)) : "".concat(String(t3.planet1), " (inner)"), a3 = n2 === "transit" ? "transit ".concat(String(t3.planet2)) : "".concat(String(t3.planet2), " (outer)"), o2 = n2 === "transit" ? t3.applying ? "applying" : "separating" : Number(t3.orb) <= 1 ? "exact" : Number(t3.orb) <= 3 ? "tight" : "wide";
7113
7349
  r2 = "Interpret the ".concat(String(t3.aspect_type), " between ").concat(i3, " and ").concat(a3, " in this ").concat(n2, " chart.\n\nOrb: ").concat(Number(t3.orb).toFixed(2), "\xB0 (").concat(o2, ")\n") + (t3.planet1_sign ? "".concat(String(t3.planet1), ": ").concat(String(t3.planet1_sign), "\n") : "") + (t3.planet2_sign ? "".concat(String(t3.planet2), ": ").concat(String(t3.planet2_sign), "\n") : "") + "\nPlease give a rich interpretation of this contact \u2014 its psychological theme, practical expression, and timing relevance".concat(n2 === "transit" ? " given the applying/separating direction" : " in the synastry", ".");
7114
7350
  }
7115
- r2 && await __(r2);
7351
+ r2 && await j_(r2);
7116
7352
  }
7117
- async function E_() {
7353
+ async function q_() {
7118
7354
  var e4, t2, n2, r2, i2, a2, o2, s2;
7119
- if (!c_) return;
7120
- let c2 = c_, l2 = (e4 = c2.mode) == null ? "synastry" : e4, u2 = String((t2 = (n2 = c2._birth_params_inner) == null ? void 0 : n2.location) == null ? "Person 1" : t2), d2 = l2 === "transit" ? "transits (".concat(String((r2 = (i2 = c2._birth_params_outer) == null ? void 0 : i2.location) == null ? "today" : r2), ")") : String((a2 = (o2 = c2._birth_params_outer) == null ? void 0 : o2.location) == null ? "Person 2" : a2), f2 = ((s2 = c2.cross_aspects) == null ? [] : s2).slice(0, 8).map((e5) => " \u2022 ".concat(e5.planet1, " ").concat(e5.type, " ").concat(e5.planet2, " (").concat(e5.orb.toFixed(1), "\xB0").concat(e5.applying === void 0 ? "" : ", ".concat(e5.applying ? "applying" : "separating"), ")")).join("\n") || " \u2022 No cross-aspects within orb";
7121
- await __(l2 === "transit" ? "Please interpret this transit chart for ".concat(u2, ".\n\nKey transit cross-aspects:\n").concat(f2, "\n\nCover: (1) The most significant active transits and their themes, (2) Timing \u2014 what's applying vs separating, (3) Practical guidance \u2014 what to focus on now, (4) The overall energetic signature of this moment in time.") : "Please interpret this synastry bi-wheel between ".concat(u2, " and ").concat(d2, ".\n\nTop cross-wheel aspects:\n").concat(f2, "\n\nCover: (1) The core relational dynamic and overall compatibility theme, (2) The most significant planet-to-planet contacts and their meaning, (3) Areas of natural ease vs creative tension, (4) How each person experiences the other energetically."));
7355
+ if (!$) return;
7356
+ let c2 = $, l2 = (e4 = c2.mode) == null ? "synastry" : e4, u2 = String((t2 = (n2 = c2._birth_params_inner) == null ? void 0 : n2.location) == null ? "Person 1" : t2), d2 = l2 === "transit" ? "transits (".concat(String((r2 = (i2 = c2._birth_params_outer) == null ? void 0 : i2.location) == null ? "today" : r2), ")") : String((a2 = (o2 = c2._birth_params_outer) == null ? void 0 : o2.location) == null ? "Person 2" : a2), f2 = ((s2 = c2.cross_aspects) == null ? [] : s2).slice(0, 8).map((e5) => " \u2022 ".concat(e5.planet1, " ").concat(e5.type, " ").concat(e5.planet2, " (").concat(e5.orb.toFixed(1), "\xB0").concat(e5.applying === void 0 ? "" : ", ".concat(e5.applying ? "applying" : "separating"), ")")).join("\n") || " \u2022 No cross-aspects within orb";
7357
+ await j_(l2 === "transit" ? "Please interpret this transit chart for ".concat(u2, ".\n\nKey transit cross-aspects:\n").concat(f2, "\n\nCover: (1) The most significant active transits and their themes, (2) Timing \u2014 what's applying vs separating, (3) Practical guidance \u2014 what to focus on now, (4) The overall energetic signature of this moment in time.") : "Please interpret this synastry bi-wheel between ".concat(u2, " and ").concat(d2, ".\n\nTop cross-wheel aspects:\n").concat(f2, "\n\nCover: (1) The core relational dynamic and overall compatibility theme, (2) The most significant planet-to-planet contacts and their meaning, (3) Areas of natural ease vs creative tension, (4) How each person experiences the other energetically."));
7122
7358
  }
7123
- async function D_() {
7359
+ async function J_() {
7124
7360
  var e4, t2, n2, r2, i2, a2;
7125
- if (!c_) return;
7126
- let o2 = c_, s2 = (e4 = o2.mode) == null ? "synastry" : e4, c2 = String((t2 = (n2 = o2._birth_params_inner) == null ? void 0 : n2.location) == null ? "Person 1" : t2), l2 = s2 === "transit" ? "today's transits" : String((r2 = (i2 = o2._birth_params_outer) == null ? void 0 : i2.location) == null ? "Person 2" : r2), u2 = ((a2 = o2.cross_aspects) == null ? [] : a2).slice(0, 6).map((e5) => "".concat(e5.planet1, " ").concat(e5.type, " ").concat(e5.planet2, " (").concat(e5.orb.toFixed(1), "\xB0)")).join(", ") || "none detected";
7127
- await __(s2 === "transit" ? "I'm exploring a transit chart for ".concat(c2, ". The active cross-aspects include: ").concat(u2, ".\n\nBased on these transits, please suggest 3-4 specific, insightful questions I could ask to understand this moment \u2014 such as what each transit means for different life areas, timing, or how to work with the energy consciously. Present each as a tappable question I can ask you.") : "I'm exploring a synastry chart between ".concat(c2, " and ").concat(l2, ". The key cross-wheel contacts include: ").concat(u2, ".\n\nBased on these connections, please suggest 3-4 specific, insightful questions I could ask to understand this relationship dynamic \u2014 such as what specific aspects mean, areas of natural ease or tension, or how these two charts interact. Present each as a tappable question I can ask you."));
7361
+ if (!$) return;
7362
+ let o2 = $, s2 = (e4 = o2.mode) == null ? "synastry" : e4, c2 = String((t2 = (n2 = o2._birth_params_inner) == null ? void 0 : n2.location) == null ? "Person 1" : t2), l2 = s2 === "transit" ? "today's transits" : String((r2 = (i2 = o2._birth_params_outer) == null ? void 0 : i2.location) == null ? "Person 2" : r2), u2 = ((a2 = o2.cross_aspects) == null ? [] : a2).slice(0, 6).map((e5) => "".concat(e5.planet1, " ").concat(e5.type, " ").concat(e5.planet2, " (").concat(e5.orb.toFixed(1), "\xB0)")).join(", ") || "none detected";
7363
+ await j_(s2 === "transit" ? "I'm exploring a transit chart for ".concat(c2, ". The active cross-aspects include: ").concat(u2, ".\n\nBased on these transits, please suggest 3-4 specific, insightful questions I could ask to understand this moment \u2014 such as what each transit means for different life areas, timing, or how to work with the energy consciously. Present each as a tappable question I can ask you.") : "I'm exploring a synastry chart between ".concat(c2, " and ").concat(l2, ". The key cross-wheel contacts include: ").concat(u2, ".\n\nBased on these connections, please suggest 3-4 specific, insightful questions I could ask to understand this relationship dynamic \u2014 such as what specific aspects mean, areas of natural ease or tension, or how these two charts interact. Present each as a tappable question I can ask you."));
7128
7364
  }
7129
- async function O_(e4) {
7130
- if (u_) try {
7365
+ async function Y_(e4) {
7366
+ if (w_) try {
7131
7367
  var t2;
7132
- await s_.updateModelContext({ content: [{ type: "text", text: "User selected ".concat(e4.type, ": ").concat(JSON.stringify(e4.data, null, 2), "\nMode: ").concat((t2 = c_ == null ? void 0 : c_.mode) == null ? "synastry" : t2) }] });
7368
+ await S_.updateModelContext({ content: [{ type: "text", text: "User selected ".concat(e4.type, ": ").concat(JSON.stringify(e4.data, null, 2), "\nMode: ").concat((t2 = $ == null ? void 0 : $.mode) == null ? "synastry" : t2) }] });
7133
7369
  } catch (e5) {
7134
7370
  }
7135
7371
  }
7136
- function k_() {
7137
- if (d_) return async (e4) => {
7138
- let t2 = await s_.createSamplingMessage({ maxTokens: 150, systemPrompt: "You are an expert astrologer. Be insightful but concise.", messages: [{ role: "user", content: { type: "text", text: e4 } }] });
7372
+ function X_() {
7373
+ if (T_) return async (e4) => {
7374
+ let t2 = await S_.createSamplingMessage({ maxTokens: 150, systemPrompt: "You are an expert astrologer. Be insightful but concise.", messages: [{ role: "user", content: { type: "text", text: e4 } }] });
7139
7375
  if (t2.isError) {
7140
7376
  var n2, r2;
7141
7377
  throw Error((n2 = (r2 = t2.error) == null ? void 0 : r2.message) == null ? "Sampling failed" : n2);
@@ -7145,64 +7381,101 @@ function k_() {
7145
7381
  throw Error("Unexpected sampling response format");
7146
7382
  };
7147
7383
  }
7148
- function A_(e4) {
7149
- var t2, n2;
7150
- c_ = e4, w_(e4), Bg(t_, e4, j_, M_, T_, k_()), x_();
7151
- let r2 = document.getElementById("bi-action-bar");
7152
- if (!r2) {
7153
- r2 = document.createElement("div"), r2.id = "bi-action-bar", r2.className = "hd-action-bar";
7384
+ function Z_(e4) {
7385
+ var t2, n2, r2, i2, a2, o2, s2;
7386
+ $ = e4, clearTimeout(rv), B_(e4), Zg(m_, e4, tv, nv, K_, X_()), I_(), G_(e4, R_);
7387
+ let c2 = yg(e4.inner), l2 = yg(e4.outer), u2 = (n2 = (r2 = (i2 = ((t2 = e4.inner_houses) == null ? [] : t2)[0]) == null ? void 0 : i2.cusp_lon) == null ? e4.ascendant : r2) == null ? 0 : n2;
7388
+ ev(Gg((a2 = e4.cross_aspects) == null ? [] : a2), c2, l2, u2);
7389
+ let d2 = document.getElementById("bi-action-bar");
7390
+ if (!d2) {
7391
+ d2 = document.createElement("div"), d2.id = "bi-action-bar", d2.className = "hd-action-bar";
7154
7392
  let e5 = document.getElementById("app");
7155
- e5 == null || e5.insertBefore(r2, r_);
7393
+ e5 == null || e5.insertBefore(d2, g_);
7156
7394
  }
7157
- r2.innerHTML = '\n <button class="action-btn action-btn--primary" id="bi-interpret-btn">\u2728 Interpret this chart</button>\n <button class="action-btn" id="bi-questions-btn">\u{1F52E} What should I ask?</button>\n ', (t2 = r2.querySelector("#bi-interpret-btn")) == null || t2.addEventListener("click", () => void E_()), (n2 = r2.querySelector("#bi-questions-btn")) == null || n2.addEventListener("click", () => void D_()), m_(), e_("bi-wheel", t_);
7395
+ d2.innerHTML = '\n <button class="action-btn action-btn--primary" id="bi-interpret-btn">\u2728 Interpret this chart</button>\n <button class="action-btn" id="bi-questions-btn">\u{1F52E} What should I ask?</button>\n ', (o2 = d2.querySelector("#bi-interpret-btn")) == null || o2.addEventListener("click", () => void q_()), (s2 = d2.querySelector("#bi-questions-btn")) == null || s2.addEventListener("click", () => void J_()), O_(), l_("bi-wheel", m_);
7158
7396
  }
7159
- function j_(e4, t2, n2) {
7397
+ var Q_ = null, $_ = { "Cross Trine": "#52a8e0", "Cross T-Square": "#e08a52", "Cross Stellium": "#9a7fd4" };
7398
+ function ev(e4, t2, n2, r2) {
7399
+ if (b_) {
7400
+ if (e4.length === 0) {
7401
+ b_.hidden = true, b_.innerHTML = "";
7402
+ return;
7403
+ }
7404
+ Q_ = null, b_.innerHTML = '\n <span class="patterns-label">Cross-Patterns:</span>\n '.concat(e4.map((e5, t3) => {
7405
+ var n3;
7406
+ let r3 = (n3 = $_[e5.name]) == null ? "#888" : n3;
7407
+ return '<button class="pattern-pill"\n data-idx="'.concat(t3, '"\n data-color="').concat(r3, '"\n style="color:').concat(r3, ";border-color:").concat(r3, '"\n title="').concat(e5.description, '">\n ').concat(e5.name, '\n <span class="pattern-pill-detail">').concat(e5.description, "</span>\n </button>");
7408
+ }).join(""), "\n "), b_.removeAttribute("hidden"), b_.querySelectorAll(".pattern-pill").forEach((i2) => {
7409
+ i2.addEventListener("click", () => {
7410
+ var a2, o2;
7411
+ let s2 = parseInt((a2 = i2.dataset.idx) == null ? "-1" : a2, 10), c2 = e4[s2];
7412
+ if (!c2) return;
7413
+ let l2 = (o2 = i2.dataset.color) == null ? "#888" : o2;
7414
+ if (Q_ === s2) {
7415
+ Q_ = null, i2.classList.remove("active"), i2.style.background = "transparent", i2.style.color = l2, i2.style.borderColor = l2, Bg();
7416
+ return;
7417
+ }
7418
+ Q_ = s2, b_.querySelectorAll(".pattern-pill").forEach((e5) => {
7419
+ var t3;
7420
+ e5.classList.remove("active");
7421
+ let n3 = (t3 = e5.dataset.color) == null ? "#888" : t3;
7422
+ e5.style.color = n3, e5.style.borderColor = n3, e5.style.background = "transparent";
7423
+ }), i2.classList.add("active"), i2.style.background = l2, i2.style.color = "#fff", i2.style.borderColor = l2, Xg(c2), Yg(), Jg(c2, t2, n2, r2);
7424
+ });
7425
+ });
7426
+ }
7427
+ }
7428
+ function tv(e4, t2, n2) {
7160
7429
  var r2, i2, a2, o2, s2;
7161
7430
  let c2 = Math.floor((e4.longitude % 360 + 360) % 360 / 30), l2 = (r2 = (i2 = e4.sign) == null ? ["Aries", "Taurus", "Gemini", "Cancer", "Leo", "Virgo", "Libra", "Scorpio", "Sagittarius", "Capricorn", "Aquarius", "Pisces"][c2] : i2) == null ? "Unknown" : r2;
7162
- O_({ type: "planet", data: { planet_name: e4.name, wheel: t2, longitude: e4.longitude, sign: l2, position: "".concat(Math.floor(e4.longitude % 30), "\xB0 ").concat(l2), house: (a2 = e4.house) == null ? null : a2, retrograde: (o2 = e4.retrograde) == null ? false : o2, mode: (s2 = c_ == null ? void 0 : c_.mode) == null ? "synastry" : s2, cross_aspects: n2.filter((n3) => t2 === "inner" && n3.planet1 === e4.name || t2 === "outer" && n3.planet2 === e4.name).slice(0, 5).map((e5) => ({ type: e5.type, partner: t2 === "inner" ? e5.planet2 : e5.planet1, orb: e5.orb, applying: e5.applying, orb_label: e5.orb <= 1 ? "exact" : e5.orb <= 3 ? "tight" : "wide" })) } });
7431
+ Y_({ type: "planet", data: { planet_name: e4.name, wheel: t2, longitude: e4.longitude, sign: l2, position: "".concat(Math.floor(e4.longitude % 30), "\xB0 ").concat(l2), house: (a2 = e4.house) == null ? null : a2, retrograde: (o2 = e4.retrograde) == null ? false : o2, mode: (s2 = $ == null ? void 0 : $.mode) == null ? "synastry" : s2, cross_aspects: n2.filter((n3) => t2 === "inner" && n3.planet1 === e4.name || t2 === "outer" && n3.planet2 === e4.name).slice(0, 5).map((e5) => ({ type: e5.type, partner: t2 === "inner" ? e5.planet2 : e5.planet1, orb: e5.orb, applying: e5.applying, orb_label: e5.orb <= 1 ? "exact" : e5.orb <= 3 ? "tight" : "wide" })) } });
7163
7432
  }
7164
- function M_(e4) {
7433
+ function nv(e4) {
7165
7434
  var t2;
7166
- let n2 = c_ == null ? void 0 : c_.inner.find((t3) => t3.name === e4.planet1), r2 = c_ == null ? void 0 : c_.outer.find((t3) => t3.name === e4.planet2), i2 = n2 ? Math.floor((n2.longitude % 360 + 360) % 360 / 30) : NaN, a2 = r2 ? Math.floor((r2.longitude % 360 + 360) % 360 / 30) : NaN, o2 = ["Aries", "Taurus", "Gemini", "Cancer", "Leo", "Virgo", "Libra", "Scorpio", "Sagittarius", "Capricorn", "Aquarius", "Pisces"];
7167
- O_({ type: "cross_aspect", data: { planet1: e4.planet1, wheel1: e4.wheel1, planet2: e4.planet2, wheel2: e4.wheel2, aspect_type: e4.type, orb: e4.orb, applying: e4.applying, planet1_sign: isNaN(i2) ? null : o2[i2], planet2_sign: isNaN(a2) ? null : o2[a2], mode: (t2 = c_ == null ? void 0 : c_.mode) == null ? "synastry" : t2 } });
7435
+ let n2 = $ == null ? void 0 : $.inner.find((t3) => t3.name === e4.planet1), r2 = $ == null ? void 0 : $.outer.find((t3) => t3.name === e4.planet2), i2 = n2 ? Math.floor((n2.longitude % 360 + 360) % 360 / 30) : NaN, a2 = r2 ? Math.floor((r2.longitude % 360 + 360) % 360 / 30) : NaN, o2 = ["Aries", "Taurus", "Gemini", "Cancer", "Leo", "Virgo", "Libra", "Scorpio", "Sagittarius", "Capricorn", "Aquarius", "Pisces"];
7436
+ Y_({ type: "cross_aspect", data: { planet1: e4.planet1, wheel1: e4.wheel1, planet2: e4.planet2, wheel2: e4.wheel2, aspect_type: e4.type, orb: e4.orb, applying: e4.applying, planet1_sign: isNaN(i2) ? null : o2[i2], planet2_sign: isNaN(a2) ? null : o2[a2], mode: (t2 = $ == null ? void 0 : $.mode) == null ? "synastry" : t2 } });
7168
7437
  }
7169
- s_.ontoolresult = (e4) => {
7170
- clearTimeout(N_);
7171
- let t2 = v_(e4);
7438
+ S_.ontoolresult = (e4) => {
7439
+ clearTimeout(rv);
7440
+ let t2 = M_(e4);
7172
7441
  if (!t2) {
7173
- h_("Ask your AI assistant to generate a bi-wheel chart to get started.");
7442
+ k_("Ask your AI assistant to generate a bi-wheel chart to get started.");
7174
7443
  return;
7175
7444
  }
7176
- if (!l_) {
7445
+ if (!C_) {
7177
7446
  var n2, r2, i2, a2;
7178
7447
  let e5 = (n2 = t2._birth_params_outer) == null ? {} : n2, o2 = (r2 = e5.datetime) == null ? "" : r2, s2 = (i2 = e5.location) == null ? "" : i2, c2 = (a2 = e5.timezone) == null ? "" : a2, l2 = e5.latitude, u2 = e5.longitude, d2 = "", f2 = "12:00";
7179
7448
  if (o2 && o2.includes("T")) {
7180
7449
  let e6 = o2.split("T");
7181
7450
  d2 = e6[0], f2 = e6[1].substring(0, 5);
7182
7451
  }
7183
- l_ = new Gg({ app: s_, container: o_, initialParams: { date: d2, time: f2, locationName: s2, timezone: c2, latitude: typeof l2 == "number" ? l2 : null, longitude: typeof u2 == "number" ? u2 : null }, showStepControls: t2.mode === "transit", onRefresh: async (e6) => {
7184
- l_ == null || l_.setBusy(true), p_(), o_.setAttribute("hidden", "");
7452
+ C_ = new e_({ app: S_, container: x_, initialParams: { date: d2, time: f2, locationName: s2, timezone: c2, latitude: typeof l2 == "number" ? l2 : null, longitude: typeof u2 == "number" ? u2 : null }, showStepControls: t2.mode === "transit", onRefresh: async (e6) => {
7453
+ C_ == null || C_.setBusy(true), D_(), x_.setAttribute("hidden", "");
7185
7454
  try {
7186
7455
  var n3, r3, i3, a3, o3;
7187
- let s3 = "".concat(e6.date, "T").concat(e6.time, ":00");
7188
- await s_.callServerTool({ name: "bi_wheel_recalculate", arguments: { mode: t2.mode, person1_datetime: (n3 = t2._birth_params_inner) == null ? void 0 : n3.datetime, person1_latitude: (r3 = t2._birth_params_inner) == null ? void 0 : r3.latitude, person1_longitude: (i3 = t2._birth_params_inner) == null ? void 0 : i3.longitude, person1_timezone: (a3 = t2._birth_params_inner) == null ? void 0 : a3.timezone, person1_name: (o3 = t2._birth_params_inner) == null ? void 0 : o3.location, person2_datetime: "".concat(s3).concat(e6.timezone ? "" : "Z"), person2_latitude: e6.latitude, person2_longitude: e6.longitude, person2_timezone: e6.timezone, person2_name: e6.locationName } });
7456
+ let s3 = "".concat(e6.date, "T").concat(e6.time, ":00"), c3 = S_.callServerTool({ name: "bi_wheel_recalculate", arguments: { mode: t2.mode, person1_datetime: (n3 = t2._birth_params_inner) == null ? void 0 : n3.datetime, person1_latitude: (r3 = t2._birth_params_inner) == null ? void 0 : r3.latitude, person1_longitude: (i3 = t2._birth_params_inner) == null ? void 0 : i3.longitude, person1_timezone: (a3 = t2._birth_params_inner) == null ? void 0 : a3.timezone, person1_name: (o3 = t2._birth_params_inner) == null ? void 0 : o3.location, person2_datetime: "".concat(s3).concat(e6.timezone ? "" : "Z"), person2_latitude: e6.latitude, person2_longitude: e6.longitude, person2_timezone: e6.timezone, person2_name: e6.locationName } }), l3 = new Promise((e7, t3) => setTimeout(() => t3(Error("Bi-wheel recalculate timed out after 30s")), 3e4));
7457
+ await Promise.race([c3, l3]);
7189
7458
  } catch (e7) {
7190
- console.error("Recalculate failed:", e7);
7459
+ console.error("[BiWheel] Recalculate failed or timed out:", e7), $ && O_();
7191
7460
  } finally {
7192
- l_ == null || l_.setBusy(false), o_.removeAttribute("hidden");
7461
+ C_ == null || C_.setBusy(false), x_.removeAttribute("hidden");
7193
7462
  }
7194
7463
  } });
7195
7464
  }
7196
- A_(t2), o_.removeAttribute("hidden");
7465
+ Z_(t2), x_.removeAttribute("hidden");
7197
7466
  };
7198
- var N_ = setTimeout(() => {
7199
- t_.hidden && h_("Chart data is taking longer than expected. Please try regenerating the chart.");
7200
- }, 12e3);
7201
- p_(), (async () => {
7467
+ var rv = setTimeout(() => {
7468
+ m_.hidden && k_("Chart data is taking longer than expected.", () => {
7469
+ D_(), rv = setTimeout(() => {
7470
+ m_.hidden && k_("Still no response from the server. Please close and re-open the chart.");
7471
+ }, 3e4), S_.sendMessage({ role: "user", content: [{ type: "text", text: "Please regenerate the bi-wheel chart." }] });
7472
+ });
7473
+ }, 3e4);
7474
+ D_(), d_(S_, { loadingEl: h_, contentEl: m_, statusFn: E_, paramControls: C_ }), (async () => {
7202
7475
  try {
7203
- await s_.connect();
7204
- let e4 = s_.getHostCapabilities();
7205
- u_ = !!(e4 != null && e4.modelContext), d_ = !!(e4 != null && e4.sampling);
7476
+ await S_.connect();
7477
+ let e4 = S_.getHostCapabilities();
7478
+ w_ = !!(e4 != null && e4.modelContext), T_ = !!(e4 != null && e4.sampling), u_(S_, document.getElementById("pan-zoom-controls"), ["mode-badge", "chart-provenance", "aspect-filter", "param-controls-container"]), p_(S_);
7206
7479
  } catch (e4) {
7207
7480
  console.error("[BiWheel] connect() failed:", e4);
7208
7481
  }