@roxyapi/ui 0.19.2 → 0.19.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components-catalog.json +109 -109
- package/dist/cdn/components/aspects-table.js +3 -3
- package/dist/cdn/components/aspects-table.js.map +3 -3
- package/dist/cdn/components/compatibility-card.js +4 -4
- package/dist/cdn/components/compatibility-card.js.map +3 -3
- package/dist/cdn/components/endpoint-form.js +1 -1
- package/dist/cdn/components/endpoint-form.js.map +1 -1
- package/dist/cdn/components/synastry-chart.js +4 -4
- package/dist/cdn/components/synastry-chart.js.map +3 -3
- package/dist/cdn/roxy-ui.js +19 -19
- package/dist/cdn/roxy-ui.js.map +3 -3
- package/dist/components/aspects-table.js +1 -1
- package/dist/components/aspects-table.js.map +3 -3
- package/dist/components/compatibility-card.d.ts.map +1 -1
- package/dist/components/compatibility-card.js +1 -1
- package/dist/components/compatibility-card.js.map +3 -3
- package/dist/components/endpoint-form.js +1 -1
- package/dist/components/endpoint-form.js.map +1 -1
- package/dist/components/synastry-chart.js +2 -2
- package/dist/components/synastry-chart.js.map +3 -3
- package/dist/index.cjs +13 -13
- package/dist/index.cjs.map +3 -3
- package/dist/index.js +15 -15
- package/dist/index.js.map +3 -3
- package/dist/version.d.ts +1 -1
- package/package.json +1 -1
- package/src/components/aspects-table.ts +1 -1
- package/src/components/compatibility-card.ts +4 -3
- package/src/components/synastry-chart.ts +1 -1
- package/src/version.ts +1 -1
|
@@ -259,15 +259,15 @@ var RoxyUI_synastry_chart=(()=>{var Y=Object.defineProperty;var Te=Object.getOwn
|
|
|
259
259
|
--roxy-motion-duration: 0ms;
|
|
260
260
|
}
|
|
261
261
|
}
|
|
262
|
-
`;var J="roxy-ui-tokens";function Z(){if(typeof document>"u")return null;let o=document.getElementById(J);if(o)return o;let e=document.createElement("style");return e.id=J,e.textContent=Pe,document.head.prepend(e),e}var X=globalThis,Q=X.ShadowRoot&&(X.ShadyCSS===void 0||X.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,
|
|
263
|
-
\f\r]`,q=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,He=/-->/g,De=/>/g,C=RegExp(`>|${
|
|
264
|
-
\f\r"'\`<>=]|("|')|))|$)`,"g"),je=/'/g,qe=/"/g,Ge=/^(?:script|style|textarea|title)$/i,$e=o=>(e,...t)=>({_$litType$:o,strings:e,values:t}),c=$e(1),N=$e(2),zt=$e(3),P=Symbol.for("lit-noChange"),p=Symbol.for("lit-nothing"),Ke=new WeakMap,R=T.createTreeWalker(T,129);function Ve(o,e){if(!ve(o)||!o.hasOwnProperty("raw"))throw Error("invalid template strings array");return ze!==void 0?ze.createHTML(e):e}var xt=(o,e)=>{let t=o.length-1,r=[],s,n=e===2?"<svg>":e===3?"<math>":"",i=q;for(let l=0;l<t;l++){let a=o[l],h,u,d=-1,y=0;for(;y<a.length&&(i.lastIndex=y,u=i.exec(a),u!==null);)y=i.lastIndex,i===q?u[1]==="!--"?i=He:u[1]!==void 0?i=De:u[2]!==void 0?(Ge.test(u[2])&&(s=RegExp("</"+u[2],"g")),i=C):u[3]!==void 0&&(i=C):i===C?u[0]===">"?(i=s??q,d=-1):u[1]===void 0?d=-2:(d=i.lastIndex-u[2].length,h=u[1],i=u[3]===void 0?C:u[3]==='"'?qe:je):i===qe||i===je?i=C:i===He||i===De?i=q:(i=C,s=void 0);let b=i===C&&o[l+1].startsWith("/>")?" ":"";n+=i===q?a+ft:d>=0?(r.push(h),a.slice(0,d)+Be+a.slice(d)+_+b):a+_+(d===-2?l:b)}return[Ve(o,n+(o[t]||"<?>")+(e===2?"</svg>":e===3?"</math>":"")),r]},F=class o{constructor({strings:e,_$litType$:t},r){let s;this.parts=[];let n=0,i=0,l=e.length-1,a=this.parts,[h,u]=xt(e,t);if(this.el=o.createElement(h,r),R.currentNode=this.el.content,t===2||t===3){let d=this.el.content.firstChild;d.replaceWith(...d.childNodes)}for(;(s=R.nextNode())!==null&&a.length<l;){if(s.nodeType===1){if(s.hasAttributes())for(let d of s.getAttributeNames())if(d.endsWith(Be)){let y=u[i++],b=s.getAttribute(d).split(_),v=/([.?@])?(.*)/.exec(y);a.push({type:1,index:n,name:v[2],strings:b,ctor:v[1]==="."?ye:v[1]==="?"?fe:v[1]==="@"?ge:U}),s.removeAttribute(d)}else d.startsWith(_)&&(a.push({type:6,index:n}),s.removeAttribute(d));if(Ge.test(s.tagName)){let d=s.textContent.split(_),y=d.length-1;if(y>0){s.textContent=re?re.emptyScript:"";for(let b=0;b<y;b++)s.append(d[b],K()),R.nextNode(),a.push({type:2,index:++n});s.append(d[y],K())}}}else if(s.nodeType===8)if(s.data===Fe)a.push({type:2,index:n});else{let d=-1;for(;(d=s.data.indexOf(_,d+1))!==-1;)a.push({type:7,index:n}),d+=_.length-1}n++}}static createElement(e,t){let r=T.createElement("template");return r.innerHTML=e,r}};function M(o,e,t=o,r){if(e===P)return e;let s=r!==void 0?t._$Co?.[r]:t._$Cl,n=B(e)?void 0:e._$litDirective$;return s?.constructor!==n&&(s?._$AO?.(!1),n===void 0?s=void 0:(s=new n(o),s._$AT(o,t,r)),r!==void 0?(t._$Co??=[])[r]=s:t._$Cl=s),s!==void 0&&(e=M(o,s._$AS(o,e.values),s,r)),e}var me=class{constructor(e,t){this._$AV=[],this._$AN=void 0,this._$AD=e,this._$AM=t}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(e){let{el:{content:t},parts:r}=this._$AD,s=(e?.creationScope??T).importNode(t,!0);R.currentNode=s;let n=R.nextNode(),i=0,l=0,a=r[0];for(;a!==void 0;){if(i===a.index){let h;a.type===2?h=new G(n,n.nextSibling,this,e):a.type===1?h=new a.ctor(n,a.name,a.strings,this,e):a.type===6&&(h=new xe(n,this,e)),this._$AV.push(h),a=r[++l]}i!==a?.index&&(n=R.nextNode(),i++)}return R.currentNode=T,s}p(e){let t=0;for(let r of this._$AV)r!==void 0&&(r.strings!==void 0?(r._$AI(e,r,t),t+=r.strings.length-2):r._$AI(e[t])),t++}},G=class o{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(e,t,r,s){this.type=2,this._$AH=p,this._$AN=void 0,this._$AA=e,this._$AB=t,this._$AM=r,this.options=s,this._$Cv=s?.isConnected??!0}get parentNode(){let e=this._$AA.parentNode,t=this._$AM;return t!==void 0&&e?.nodeType===11&&(e=t.parentNode),e}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(e,t=this){e=M(this,e,t),B(e)?e===p||e==null||e===""?(this._$AH!==p&&this._$AR(),this._$AH=p):e!==this._$AH&&e!==P&&this._(e):e._$litType$!==void 0?this.$(e):e.nodeType!==void 0?this.T(e):gt(e)?this.k(e):this._(e)}O(e){return this._$AA.parentNode.insertBefore(e,this._$AB)}T(e){this._$AH!==e&&(this._$AR(),this._$AH=this.O(e))}_(e){this._$AH!==p&&B(this._$AH)?this._$AA.nextSibling.data=e:this.T(T.createTextNode(e)),this._$AH=e}$(e){let{values:t,_$litType$:r}=e,s=typeof r=="number"?this._$AC(e):(r.el===void 0&&(r.el=F.createElement(Ve(r.h,r.h[0]),this.options)),r);if(this._$AH?._$AD===s)this._$AH.p(t);else{let n=new me(s,this),i=n.u(this.options);n.p(t),this.T(i),this._$AH=n}}_$AC(e){let t=Ke.get(e.strings);return t===void 0&&Ke.set(e.strings,t=new F(e)),t}k(e){ve(this._$AH)||(this._$AH=[],this._$AR());let t=this._$AH,r,s=0;for(let n of e)s===t.length?t.push(r=new o(this.O(K()),this.O(K()),this,this.options)):r=t[s],r._$AI(n),s++;s<t.length&&(this._$AR(r&&r._$AB.nextSibling,s),t.length=s)}_$AR(e=this._$AA.nextSibling,t){for(this._$AP?.(!1,!0,t);e!==this._$AB;){let r=Ie(e).nextSibling;Ie(e).remove(),e=r}}setConnected(e){this._$AM===void 0&&(this._$Cv=e,this._$AP?.(e))}},U=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(e,t,r,s,n){this.type=1,this._$AH=p,this._$AN=void 0,this.element=e,this.name=t,this._$AM=s,this.options=n,r.length>2||r[0]!==""||r[1]!==""?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=p}_$AI(e,t=this,r,s){let n=this.strings,i=!1;if(n===void 0)e=M(this,e,t,0),i=!B(e)||e!==this._$AH&&e!==P,i&&(this._$AH=e);else{let l=e,a,h;for(e=n[0],a=0;a<n.length-1;a++)h=M(this,l[r+a],t,a),h===P&&(h=this._$AH[a]),i||=!B(h)||h!==this._$AH[a],h===p?e=p:e!==p&&(e+=(h??"")+n[a+1]),this._$AH[a]=h}i&&!s&&this.j(e)}j(e){e===p?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,e??"")}},ye=class extends U{constructor(){super(...arguments),this.type=3}j(e){this.element[this.name]=e===p?void 0:e}},fe=class extends U{constructor(){super(...arguments),this.type=4}j(e){this.element.toggleAttribute(this.name,!!e&&e!==p)}},ge=class extends U{constructor(e,t,r,s,n){super(e,t,r,s,n),this.type=5}_$AI(e,t=this){if((e=M(this,e,t,0)??p)===P)return;let r=this._$AH,s=e===p&&r!==p||e.capture!==r.capture||e.once!==r.once||e.passive!==r.passive,n=e!==p&&(r===p||s);s&&this.element.removeEventListener(this.name,this,r),n&&this.element.addEventListener(this.name,this,e),this._$AH=e}handleEvent(e){typeof this._$AH=="function"?this._$AH.call(this.options?.host??this.element,e):this._$AH.handleEvent(e)}},xe=class{constructor(e,t,r){this.element=e,this.type=6,this._$AN=void 0,this._$AM=t,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(e){M(this,e)}};var bt=be.litHtmlPolyfillSupport;bt?.(F,G),(be.litHtmlVersions??=[]).push("3.3.3");var We=(o,e,t)=>{let r=t?.renderBefore??e,s=r._$litPart$;if(s===void 0){let n=t?.renderBefore??null;r._$litPart$=s=new G(e.insertBefore(K(),n),n,void 0,t??{})}return s._$AI(o),s};var we=globalThis,k=class extends A{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){let e=super.createRenderRoot();return this.renderOptions.renderBefore??=e.firstChild,e}update(e){let t=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(e),this._$Do=We(t,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return P}};k._$litElement$=!0,k.finalized=!0,we.litElementHydrateSupport?.({LitElement:k});var vt=we.litElementPolyfillSupport;vt?.({LitElement:k});(we.litElementVersions??=[]).push("4.2.2");var Ye=o=>(e,t)=>{t!==void 0?t.addInitializer(()=>{customElements.define(o,e)}):customElements.define(o,e)};var $t={attribute:!0,type:String,converter:j,reflect:!1,hasChanged:te},wt=(o=$t,e,t)=>{let{kind:r,metadata:s}=t,n=globalThis.litPropertyMetadata.get(s);if(n===void 0&&globalThis.litPropertyMetadata.set(s,n=new Map),r==="setter"&&((o=Object.create(o)).wrapped=!0),n.set(t.name,o),r==="accessor"){let{name:i}=t;return{set(l){let a=e.get.call(this);e.set.call(this,l),this.requestUpdate(i,a,o,!0,l)},init(l){return l!==void 0&&this.C(i,void 0,o,l),l}}}if(r==="setter"){let{name:i}=t;return function(l){let a=this[i];e.call(this,l),this.requestUpdate(i,a,o,!0,l)}}throw Error("Unsupported decorator location: "+r)};function x(o){return(e,t)=>typeof t=="object"?wt(o,e,t):((r,s,n)=>{let i=s.hasOwnProperty(n);return s.constructor.createProperty(n,r),i?Object.getOwnPropertyDescriptor(s,n):void 0})(o,e,t)}function L(o){return x({...o,state:!0,attribute:!1})}var oe={Sun:"\u2609",Moon:"\u263D",Mercury:"\u263F",Venus:"\u2640",Earth:"\u2641",Mars:"\u2642",Jupiter:"\u2643",Saturn:"\u2644",Uranus:"\u2645",Neptune:"\u2646",Pluto:"\u2647",Rahu:"\u260A",Ketu:"\u260B",Ascendant:"Asc",Lagna:"La",NorthNode:"\u260A",SouthNode:"\u260B","North node":"\u260A","South node":"\u260B",Chiron:"\u26B7",Lilith:"\u26B8","Black moon lilith":"\u26B8"};var Se={Aries:"\u2648",Taurus:"\u2649",Gemini:"\u264A",Cancer:"\u264B",Leo:"\u264C",Virgo:"\u264D",Libra:"\u264E",Scorpio:"\u264F",Sagittarius:"\u2650",Capricorn:"\u2651",Aquarius:"\u2652",Pisces:"\u2653"};var V=["Aries","Taurus","Gemini","Cancer","Leo","Virgo","Libra","Scorpio","Sagittarius","Capricorn","Aquarius","Pisces"];var W=o=>o??p;var ne=S`:host{font-family:var(--roxy-font-sans,system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-base,1rem);line-height:var(--roxy-leading-normal,1.5);animation:roxy-fade-in var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,cubic-bezier(.4, 0, .2, 1)) both;background:0 0;display:block;container-type:inline-size}:host([bare]){--roxy-surface:transparent;--roxy-shadow-sm:none;--roxy-shadow-md:none}*,:before,:after{box-sizing:border-box}h1,h2,h3,h4{font-family:var(--roxy-font-display,var(--roxy-font-sans,system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif))}@keyframes roxy-fade-in{0%{opacity:0;transform:translateY(2px)}to{opacity:1;transform:translateY(0)}}@media (prefers-reduced-motion:reduce){:host{animation:none}}.roxy-skeleton{background:linear-gradient(90deg, var(--roxy-border,#e4e4e7) 0%, color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent) 50%, var(--roxy-border,#e4e4e7) 100%);border-radius:var(--roxy-radius-md,8px);background-size:200% 100%;animation:1.4s ease-in-out infinite roxy-shimmer}@keyframes roxy-shimmer{0%{background-position:200% 0}to{background-position:-200% 0}}@media (prefers-reduced-motion:reduce){.roxy-skeleton{animation:none}}.roxy-sr-only{clip-path:inset(50%);white-space:nowrap;border:0;width:1px;height:1px;margin:0;padding:0;position:absolute;overflow:hidden}.roxy-empty{padding:var(--roxy-space-lg,1.5rem);color:var(--roxy-muted,#71717a);text-align:center;font-size:var(--roxy-text-sm,.875rem)}.roxy-error{gap:var(--roxy-space-sm,.5rem);padding:var(--roxy-space-lg,1.5rem);background:var(--roxy-surface,#fff);border:1px solid var(--roxy-danger,#dc2626);border-radius:var(--roxy-radius-md,8px);color:var(--roxy-danger-fg,#991b1b);font-size:var(--roxy-text-sm,.875rem);justify-items:start;display:grid}.roxy-surface{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a)}:host(:focus-within) .roxy-card{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px}.roxy-attribution{margin-top:var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-align:right}.roxy-attribution a{color:inherit;text-decoration:none}.roxy-attribution a:hover{color:var(--roxy-accent-ink,#b45309);text-decoration:underline}.roxy-attribution a:focus-visible{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px}.roxy-edit-bar{margin-bottom:var(--roxy-space-sm,.5rem);justify-content:flex-end;display:flex}.roxy-edit{padding:var(--roxy-space-xs,.25rem) var(--roxy-space-md,1rem);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);color:var(--roxy-fg,#0a0a0a);font-family:inherit;font-size:var(--roxy-text-sm,.875rem);cursor:pointer;background:0 0}.roxy-edit:hover{border-color:var(--roxy-accent,#f59e0b);color:var(--roxy-accent-ink,#b45309)}.roxy-edit:focus-visible{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px}:host{font-variant-emoji:text}`;var ie="Client-side components accept a pk_ publishable key only. Use a publishable key with an origin allowlist, or render server-side.";function Je(o){return!!o&&!o.startsWith("pk_")}function Ze(o,e={}){e.warn&&console.warn(ie),o.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{reason:"possible-secret-key",message:ie},bubbles:!0,composed:!0}))}var St="https://roxyapi.com/api/v2",ae=class{constructor(e){this.baseUrl=St;this.host=e,e.addController(this)}hostDisconnected(){this.abort?.abort(),this.abort=void 0}async run(e){if(!this.submitUrl&&this.secretKeyRefused())return;this.abort?.abort();let t=new AbortController;this.abort=t,this.host.loading=!0,this.host.error=null;try{let r=this.submitUrl?await fetch(this.submitUrl,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e),signal:t.signal}):await this.callApi(e,t.signal);if(!r.ok)throw new Error(await this.readError(r));let s=await r.json();if(t.signal.aborted)return;this.host.data=s}catch(r){if(r?.name==="AbortError")return;this.host.error=r instanceof Error?r.message:String(r)}finally{this.abort===t&&(this.abort=void 0),t.signal.aborted||(this.host.loading=!1)}}callApi(e,t){let r=new URL(`${this.baseUrl}${e.path}`);for(let[n,i]of Object.entries(e.query??{}))i!=null&&r.searchParams.set(n,String(i));let s={Accept:"application/json"};return this.publishableKey&&(s["X-API-Key"]=this.publishableKey),e.body!=null&&(s["Content-Type"]="application/json"),fetch(r,{method:e.method??"GET",headers:s,body:e.body!=null?JSON.stringify(e.body):void 0,signal:t})}secretKeyRefused(){return Je(this.publishableKey)?(this.host.error=ie,Ze(this.host),!0):!1}async readError(e){try{let t=await e.json();if(t?.error)return t.error}catch{}return`Request failed (${e.status})`}};function Xe(o,e,t,r=[]){let s={...t},n=`/${o.replace(/^\//,"")}`.replace(/\{([^}]+)\}/g,(h,u)=>{let d=s[u];return delete s[u],encodeURIComponent(String(d??""))}),i=new Set(r),l={},a={};for(let[h,u]of Object.entries(s))u===void 0||u===""||(e==="GET"||i.has(h)?l[h]=u:a[h]=u);return{path:n,method:e,query:l,body:e==="POST"?a:void 0}}var At="roxy-data";function _t(o){return o.nodeName==="SCRIPT"&&o.getAttribute("type")==="application/json"}var le=class{constructor(e){this.host=e,e.addController(this)}hostConnected(){if(this.host.data!=null)return;let e=this.read();e!==void 0&&(this.host.data=e,this.host.requestUpdate())}read(){let e=this.findInlineScript();return e?this.parse(e.textContent):void 0}findInlineScript(){for(let e of Array.from(this.host.children))if(_t(e)&&e.classList.contains(At))return e;return null}parse(e){if(e?.trim())try{return JSON.parse(e)}catch{return}}};var f=class extends k{constructor(){super();this.data=null;this.endpoint="";this.method="POST";this.remember=!1;this.loading=!1;this.error=null;this.selfFetched=!1;this.editing=!1;this.sticky=!1;this.onEdit=()=>{this.editing=!0};this.onFormSubmit=t=>{let r=t.detail;this.lastValues=r.values,this.sticky=!!r.sticky,this.selfFetched=!0,this.editing=!1,this.remember&&this.writeRemembered(r.values),this.fetcher.run(Xe(this.endpoint,this.method,r.values,r.queryKeys??[]))};new le(this),this.fetcher=new ae(this)}static{this.styles=[ne]}willUpdate(t){t.has("publishableKey")&&(this.fetcher.publishableKey=this.publishableKey),t.has("baseUrl")&&this.baseUrl&&(this.fetcher.baseUrl=this.baseUrl),t.has("submitUrl")&&(this.fetcher.submitUrl=this.submitUrl)}render(){return this.loading?this.renderLoading():this.error!=null?this.renderError(this.error):this.data!=null?this.selfFetched?this.editing?this.renderForm():this.renderResult(this.data):this.showAttribution()?c`${this.renderData(this.data)}${this.renderAttribution()}`:this.renderData(this.data):this.renderNoData()}renderResult(t){let r=this.sticky?c`${this.renderForm()}${this.renderData(t)}`:c`<div class="roxy-edit-bar"><button type="button" class="roxy-edit" @click="${this.onEdit}">Edit query</button></div>${this.renderData(t)}`;return this.showAttribution()?c`${r}${this.renderAttribution()}`:r}showAttribution(){return this.attribution!=null&&this.attribution!=="off"&&this.attribution!=="false"}renderAttribution(){return c`<div class="roxy-attribution"><a href="https://roxyapi.com/?utm_source=widget&utm_medium=embed" target="_blank" rel="noopener">Spiritual data by RoxyAPI</a></div>`}renderNoData(){return this.endpoint?this.renderForm():this.renderEmpty()}renderForm(){return c`<roxy-endpoint-form data-endpoint="${this.endpoint}" method="${this.method}" spec-url="${W(this.specUrl)}" publishable-key="${W(this.publishableKey)}" submit-label="${W(this.submitLabel)}" lang="${W(this.effectiveLang())}" .initialValues="${this.formInitialValues()}" @roxy-submit="${this.onFormSubmit}"></roxy-endpoint-form>`}formInitialValues(){return this.lastValues??(this.remember?this.readRemembered():void 0)}effectiveLang(){return this.lang||void 0}rememberKey(){return`roxy-ui:form:${this.endpoint}`}readRemembered(){try{let t=sessionStorage.getItem(this.rememberKey());return t?JSON.parse(t):void 0}catch{return}}writeRemembered(t){try{sessionStorage.setItem(this.rememberKey(),JSON.stringify(t))}catch{}}renderEmpty(){return c`<div class="roxy-empty" role="status">No data</div>`}renderLoading(){return c`<div class="roxy-skeleton" style="height:8rem" role="status" aria-label="Loading"></div>`}renderError(t){let r=c`<div class="roxy-error" role="alert">${t}</div>`;return this.endpoint?c`${r}${this.renderForm()}`:r}};g([x({attribute:!1})],f.prototype,"data",2),g([x({type:String,attribute:"data-endpoint"})],f.prototype,"endpoint",2),g([x({type:String})],f.prototype,"method",2),g([x({type:String,attribute:"publishable-key"})],f.prototype,"publishableKey",2),g([x({type:String,attribute:"base-url"})],f.prototype,"baseUrl",2),g([x({type:String,attribute:"spec-url"})],f.prototype,"specUrl",2),g([x({type:String,attribute:"submit-url"})],f.prototype,"submitUrl",2),g([x({type:Boolean})],f.prototype,"remember",2),g([x({type:String,attribute:"submit-label"})],f.prototype,"submitLabel",2),g([x({type:String})],f.prototype,"attribution",2),g([L()],f.prototype,"loading",2),g([L()],f.prototype,"error",2),g([L()],f.prototype,"selfFetched",2),g([L()],f.prototype,"editing",2),g([L()],f.prototype,"sticky",2);function kt(o){let e=o%360;return e<0?e+360:e}function Qe(o){let e=kt(o),t=Math.floor(e/30)%12,r=e%30,s=Math.floor(r),n=(r-s)*60,i=Math.floor(n),l=Math.round((n-i)*60);return{sign:V[t]??"Aries",signIndex:t,degree:s,minute:i,second:l}}function $(o,e,t,r){let s=r*Math.PI/180;return{x:o+t*Math.cos(s),y:e+t*Math.sin(s)}}function Ae(){return c`<svg class="roxy-chevron" viewBox="0 0 16 16" width="14" height="14" aria-hidden="true"><path d="M4 6l4 4 4-4" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>`}var et=S`summary{list-style:none}summary::-webkit-details-marker{display:none}.roxy-chevron{aspect-ratio:auto;width:14px;height:14px;color:var(--roxy-muted,#71717a);transition:transform var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,ease);flex-shrink:0}details[open]>summary .roxy-chevron{transform:rotate(180deg)}@media (prefers-reduced-motion:reduce){.roxy-chevron{transition:none}}`;function w(o){return o?o.charAt(0).toUpperCase()+o.slice(1).toLowerCase():""}function O(o,e=1){if(typeof o!="number"||!Number.isFinite(o))return"";let t=o.toFixed(e);return t.includes(".")?t.replace(/\.?0+$/,""):t}var tt={conjunction:"aspect-conjunction",sextile:"aspect-sextile",square:"aspect-square",trine:"aspect-trine",opposition:"aspect-opposition"};function _e(o){return(o.type??"").toLowerCase().trim().replace(/[\s_]+/g,"-")}function ke(o){return w(_e(o))}var rt=S`.block{border-top:1px solid var(--roxy-border,#e4e4e7);padding-top:var(--roxy-space-md,1rem)}.block h3{margin:0 0 var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em}.interp-card{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);margin-bottom:var(--roxy-space-xs,.25rem)}.interp-card summary{cursor:pointer;color:var(--roxy-fg,#0a0a0a);align-items:center;gap:var(--roxy-space-sm,.5rem);font-weight:500;font-size:var(--roxy-text-sm,.875rem);display:flex}.interp-card summary:focus-visible{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px;border-radius:var(--roxy-radius-sm,4px)}.interp-lead{flex-wrap:wrap;flex:auto;order:1;align-items:baseline;gap:.4rem;min-width:0;display:inline-flex}.interp-aside{flex-shrink:0;order:2;align-items:center;gap:.5rem;display:inline-flex}.roxy-chevron{order:3}.interp-aside small{color:var(--roxy-muted,#71717a);white-space:nowrap;font-weight:400}@container (width<=26rem){.interp-card summary{flex-wrap:wrap}.roxy-chevron{order:2}.interp-aside{flex-basis:100%;order:3;justify-content:flex-end}}.interp-body{margin-top:var(--roxy-space-sm,.5rem);gap:var(--roxy-space-sm,.5rem);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-sm,.875rem);overflow-wrap:anywhere;line-height:1.6;display:grid}.interp-body p{margin:0}`;var Et=12,Re=360,m=Re/2,Ee=170,Ct=154,Ce=124,I=96,z=class extends f{renderEmpty(){return c`<div class="roxy-empty" role="status">No synastry data</div>`}renderData(e){let{person1:t,person2:r,compatibilityScore:s,analysis:n}=e,i=e.interAspects??[],l=t?.planets??[],a=r?.planets??[],h=typeof s=="number"?Math.round(s):void 0,u=n?.overall,d=n?.strengths??[],y=n?.challenges??[],b=l.length>0&&a.length>0,v=[...i].sort((E,de)=>(de.strength??0)-(E.strength??0)),ce=v.slice(0,Et);return c`<div class="wrap" aria-label="Synastry compatibility chart"><div class="head"><h2 class="title">Synastry</h2>${typeof h=="number"?c`<span class="score" aria-label="${`Score ${h} of 100`}">${h} / 100</span>`:p}</div>${this.renderPeople(t,r)} ${b?c`<svg viewBox="0 0 ${Re} ${Re}" role="img" aria-label="Dual chart wheel comparing two natal charts"><title>Synastry dual wheel</title><circle class="wheel-line" cx="${m}" cy="${m}" r="${Ee}" stroke-width="1.5"/><circle class="wheel-line" cx="${m}" cy="${m}" r="${I+14}" stroke-width="0.8"/><circle class="wheel-line" cx="${m}" cy="${m}" r="${I-14}" stroke-width="0.6"/>${this.renderSpokes()} ${this.renderSigns()} ${this.renderInterAspectLines(l,a,i)} ${this.renderRing(l,Ce,"p1",1)} ${this.renderRing(a,I,"p2",2)} ${this.renderAscendants(e)}</svg><div class="legend-row"><span><span class="swatch" style="background:var(--roxy-accent)"></span>Person 1</span> <span><span class="swatch" style="background:var(--roxy-info)"></span>Person 2</span> <span><span class="swatch" style="background:var(--roxy-success)"></span>harmonious</span> <span><span class="swatch" style="background:var(--roxy-danger)"></span>challenging</span></div>`:c`<div class="missing-planets" role="status">Synastry response missing planet positions. Pass <code>data</code> with <code>person1.planets</code> and <code>person2.planets</code> arrays from the natal-chart endpoint, or use the <code><roxy-data></code> fallback.</div>`} ${this.renderSummaryPills(e.summary)} ${u?c`<p class="summary">${u}</p>`:p} ${ce.length>0?c`<section class="block"><h3>Inter-aspects</h3>${ce.map((E,de)=>this.renderAspectCard(E,de))}</section>`:p} ${v.length>ce.length?this.renderCatalog(v):p} ${d.length>0||y.length>0?c`<div class="lists">${d.length?c`<div><h3>Strengths</h3><ul>${d.map(E=>c`<li>${E}</li>`)}</ul></div>`:p} ${y.length?c`<div><h3>Challenges</h3><ul>${y.map(E=>c`<li>${E}</li>`)}</ul></div>`:p}</div>`:p}</div>`}renderPeople(e,t){let r=(n,i)=>{if(!n)return p;let a=[["Sun",n.sunSign??""],["Moon",n.moonSign??""],["Asc",n.ascendant?`${n.ascendant.sign} ${O(n.ascendant.degree,0)}\xB0`:""]].filter(([,h])=>h);return a.length===0?p:c`<div class="person"><span class="person-name"><span class="person-dot p${i}" aria-hidden="true"></span> ${n.name||`Person ${i}`}</span><div class="big-three">${a.map(([h,u])=>c`<span><span class="lbl">${h}</span> <span aria-hidden="true">${Se[w(u.split(" ")[0]??"")]??""}</span> ${u}</span>`)}</div></div>`},s=[r(e,1),r(t,2)].filter(n=>n!==p);return s.length===0?p:c`<div class="people">${s}</div>`}renderSummaryPills(e){if(!e||typeof e!="object")return p;let t=Object.entries(e.byType??{}).sort((r,s)=>s[1]-r[1]);return typeof e.total!="number"&&t.length===0?p:c`<div class="summary-pills" role="region" aria-label="Inter-aspect summary">${typeof e.total=="number"?c`<span class="pill">Total: ${e.total}</span>`:p} <span class="pill pill--success">Harmonious: ${e.harmonious}</span> <span class="pill pill--danger">Challenging: ${e.challenging}</span> <span class="pill">Neutral: ${e.neutral}</span> ${t.map(([r,s])=>c`<span class="pill">${w(r.replace(/_/g," "))}: ${s}</span>`)}</div>`}renderAspectCard(e,t){let r=oe[w(e.planet1)]??"",s=oe[w(e.planet2)]??"",n=(e.interpretation??"neutral").toLowerCase(),i=e.meaning,l=c`<span class="interp-lead"><span aria-hidden="true" class="glyph">${r}</span>${e.planet1} <span class="asp-name ${n}">${ke(e)}</span> <span aria-hidden="true" class="glyph">${s}</span>${e.planet2}</span>`,a=c`<span class="interp-aside"><small>orb ${O(e.orb,2)}° · str ${O(e.strength,0)}</small></span>`;return!i?.relationshipContext&&!i?.description?.short?c`<div class="interp-card"><div class="static-head">${l}${a}</div></div>`:c`<details class="interp-card" name="synastry-aspects" ?open="${t===0}"><summary>${l}${Ae()}${a}</summary><div class="interp-body">${i.relationshipContext?c`<p><span class="context">In this pairing</span> ${i.relationshipContext}</p>`:p} ${i.description?.short?c`<p>${i.description.short}</p>`:p} ${i.keywords?.length?c`<div class="interp-keywords">${i.keywords.map(h=>c`<span class="kw">${h}</span>`)}</div>`:p}</div></details>`}renderCatalog(e){return c`<details class="catalog"><summary>${Ae()} All ${e.length} inter-aspects</summary><div class="scroll">${this.renderAspects(e)}</div></details>`}toAngle(e){return 180-e}renderSpokes(){return Array.from({length:12},(e,t)=>{let r=this.toAngle(t*30),s=$(m,m,I-14,r),n=$(m,m,Ee,r);return N`<line class="wheel-line" x1=${s.x} y1=${s.y} x2=${n.x} y2=${n.y} stroke-width="0.6" />`})}renderSigns(){return V.map((e,t)=>{let r=this.toAngle(t*30+15),s=$(m,m,Ct,r);return N`<text class="sign" x=${s.x} y=${s.y} text-anchor="middle" dominant-baseline="central">${Se[e]}</text>`})}renderRing(e,t,r,s){return e.map(n=>{if(!Number.isFinite(n.longitude))return p;let i=this.toAngle(n.longitude),l=$(m,m,t,i),h=$(m,m,t+(s===1?-12:-10),i),u=oe[w(n.name)]??n.name.slice(0,2),d=Qe(n.longitude),y=n.isRetrograde===!0,b=`${d.degree}\xB0${String(d.minute).padStart(2,"0")}'`,v=`${n.name}${y?" retrograde":""} - ${b} ${d.sign}`;return N`<g>
|
|
262
|
+
`;var J="roxy-ui-tokens";function Z(){if(typeof document>"u")return null;let o=document.getElementById(J);if(o)return o;let e=document.createElement("style");return e.id=J,e.textContent=Pe,document.head.prepend(e),e}var X=globalThis,Q=X.ShadowRoot&&(X.ShadyCSS===void 0||X.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,he=Symbol(),Ne=new WeakMap,H=class{constructor(e,t,r){if(this._$cssResult$=!0,r!==he)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=e,this.t=t}get styleSheet(){let e=this.o,t=this.t;if(Q&&e===void 0){let r=t!==void 0&&t.length===1;r&&(e=Ne.get(t)),e===void 0&&((this.o=e=new CSSStyleSheet).replaceSync(this.cssText),r&&Ne.set(t,e))}return e}toString(){return this.cssText}},Oe=o=>new H(typeof o=="string"?o:o+"",void 0,he),w=(o,...e)=>{let t=o.length===1?o[0]:e.reduce((r,s,n)=>r+(i=>{if(i._$cssResult$===!0)return i.cssText;if(typeof i=="number")return i;throw Error("Value passed to 'css' function must be a 'css' function result: "+i+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(s)+o[n+1],o[0]);return new H(t,o,he)},Me=(o,e)=>{if(Q)o.adoptedStyleSheets=e.map(t=>t instanceof CSSStyleSheet?t:t.styleSheet);else for(let t of e){let r=document.createElement("style"),s=X.litNonce;s!==void 0&&r.setAttribute("nonce",s),r.textContent=t.cssText,o.appendChild(r)}},ue=Q?o=>o:o=>o instanceof CSSStyleSheet?(e=>{let t="";for(let r of e.cssRules)t+=r.cssText;return Oe(t)})(o):o;var{is:lt,defineProperty:ct,getOwnPropertyDescriptor:dt,getOwnPropertyNames:pt,getOwnPropertySymbols:ht,getPrototypeOf:ut}=Object,ee=globalThis,Ue=ee.trustedTypes,mt=Ue?Ue.emptyScript:"",yt=ee.reactiveElementPolyfillSupport,D=(o,e)=>o,j={toAttribute(o,e){switch(e){case Boolean:o=o?mt:null;break;case Object:case Array:o=o==null?o:JSON.stringify(o)}return o},fromAttribute(o,e){let t=o;switch(e){case Boolean:t=o!==null;break;case Number:t=o===null?null:Number(o);break;case Object:case Array:try{t=JSON.parse(o)}catch{t=null}}return t}},te=(o,e)=>!lt(o,e),Le={attribute:!0,type:String,converter:j,reflect:!1,useDefault:!1,hasChanged:te};Symbol.metadata??=Symbol("metadata"),ee.litPropertyMetadata??=new WeakMap;var S=class extends HTMLElement{static addInitializer(e){this._$Ei(),(this.l??=[]).push(e)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(e,t=Le){if(t.state&&(t.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(e)&&((t=Object.create(t)).wrapped=!0),this.elementProperties.set(e,t),!t.noAccessor){let r=Symbol(),s=this.getPropertyDescriptor(e,r,t);s!==void 0&&ct(this.prototype,e,s)}}static getPropertyDescriptor(e,t,r){let{get:s,set:n}=dt(this.prototype,e)??{get(){return this[t]},set(i){this[t]=i}};return{get:s,set(i){let l=s?.call(this);n?.call(this,i),this.requestUpdate(e,l,r)},configurable:!0,enumerable:!0}}static getPropertyOptions(e){return this.elementProperties.get(e)??Le}static _$Ei(){if(this.hasOwnProperty(D("elementProperties")))return;let e=ut(this);e.finalize(),e.l!==void 0&&(this.l=[...e.l]),this.elementProperties=new Map(e.elementProperties)}static finalize(){if(this.hasOwnProperty(D("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(D("properties"))){let t=this.properties,r=[...pt(t),...ht(t)];for(let s of r)this.createProperty(s,t[s])}let e=this[Symbol.metadata];if(e!==null){let t=litPropertyMetadata.get(e);if(t!==void 0)for(let[r,s]of t)this.elementProperties.set(r,s)}this._$Eh=new Map;for(let[t,r]of this.elementProperties){let s=this._$Eu(t,r);s!==void 0&&this._$Eh.set(s,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(e){let t=[];if(Array.isArray(e)){let r=new Set(e.flat(1/0).reverse());for(let s of r)t.unshift(ue(s))}else e!==void 0&&t.push(ue(e));return t}static _$Eu(e,t){let r=t.attribute;return r===!1?void 0:typeof r=="string"?r:typeof e=="string"?e.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise(e=>this.enableUpdating=e),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach(e=>e(this))}addController(e){(this._$EO??=new Set).add(e),this.renderRoot!==void 0&&this.isConnected&&e.hostConnected?.()}removeController(e){this._$EO?.delete(e)}_$E_(){let e=new Map,t=this.constructor.elementProperties;for(let r of t.keys())this.hasOwnProperty(r)&&(e.set(r,this[r]),delete this[r]);e.size>0&&(this._$Ep=e)}createRenderRoot(){let e=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return Me(e,this.constructor.elementStyles),e}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$EO?.forEach(e=>e.hostConnected?.())}enableUpdating(e){}disconnectedCallback(){this._$EO?.forEach(e=>e.hostDisconnected?.())}attributeChangedCallback(e,t,r){this._$AK(e,r)}_$ET(e,t){let r=this.constructor.elementProperties.get(e),s=this.constructor._$Eu(e,r);if(s!==void 0&&r.reflect===!0){let n=(r.converter?.toAttribute!==void 0?r.converter:j).toAttribute(t,r.type);this._$Em=e,n==null?this.removeAttribute(s):this.setAttribute(s,n),this._$Em=null}}_$AK(e,t){let r=this.constructor,s=r._$Eh.get(e);if(s!==void 0&&this._$Em!==s){let n=r.getPropertyOptions(s),i=typeof n.converter=="function"?{fromAttribute:n.converter}:n.converter?.fromAttribute!==void 0?n.converter:j;this._$Em=s;let l=i.fromAttribute(t,n.type);this[s]=l??this._$Ej?.get(s)??l,this._$Em=null}}requestUpdate(e,t,r,s=!1,n){if(e!==void 0){let i=this.constructor;if(s===!1&&(n=this[e]),r??=i.getPropertyOptions(e),!((r.hasChanged??te)(n,t)||r.useDefault&&r.reflect&&n===this._$Ej?.get(e)&&!this.hasAttribute(i._$Eu(e,r))))return;this.C(e,t,r)}this.isUpdatePending===!1&&(this._$ES=this._$EP())}C(e,t,{useDefault:r,reflect:s,wrapped:n},i){r&&!(this._$Ej??=new Map).has(e)&&(this._$Ej.set(e,i??t??this[e]),n!==!0||i!==void 0)||(this._$AL.has(e)||(this.hasUpdated||r||(t=void 0),this._$AL.set(e,t)),s===!0&&this._$Em!==e&&(this._$Eq??=new Set).add(e))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(t){Promise.reject(t)}let e=this.scheduleUpdate();return e!=null&&await e,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(let[s,n]of this._$Ep)this[s]=n;this._$Ep=void 0}let r=this.constructor.elementProperties;if(r.size>0)for(let[s,n]of r){let{wrapped:i}=n,l=this[s];i!==!0||this._$AL.has(s)||l===void 0||this.C(s,void 0,n,l)}}let e=!1,t=this._$AL;try{e=this.shouldUpdate(t),e?(this.willUpdate(t),this._$EO?.forEach(r=>r.hostUpdate?.()),this.update(t)):this._$EM()}catch(r){throw e=!1,this._$EM(),r}e&&this._$AE(t)}willUpdate(e){}_$AE(e){this._$EO?.forEach(t=>t.hostUpdated?.()),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(e)),this.updated(e)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(e){return!0}update(e){this._$Eq&&=this._$Eq.forEach(t=>this._$ET(t,this[t])),this._$EM()}updated(e){}firstUpdated(e){}};S.elementStyles=[],S.shadowRootOptions={mode:"open"},S[D("elementProperties")]=new Map,S[D("finalized")]=new Map,yt?.({ReactiveElement:S}),(ee.reactiveElementVersions??=[]).push("2.1.2");var ve=globalThis,Ie=o=>o,re=ve.trustedTypes,ze=re?re.createPolicy("lit-html",{createHTML:o=>o}):void 0,Be="$lit$",_=`lit$${Math.random().toFixed(9).slice(2)}$`,Fe="?"+_,ft=`<${Fe}>`,T=document,K=()=>T.createComment(""),B=o=>o===null||typeof o!="object"&&typeof o!="function",$e=Array.isArray,gt=o=>$e(o)||typeof o?.[Symbol.iterator]=="function",me=`[
|
|
263
|
+
\f\r]`,q=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,He=/-->/g,De=/>/g,C=RegExp(`>|${me}(?:([^\\s"'>=/]+)(${me}*=${me}*(?:[^
|
|
264
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),je=/'/g,qe=/"/g,Ge=/^(?:script|style|textarea|title)$/i,we=o=>(e,...t)=>({_$litType$:o,strings:e,values:t}),c=we(1),N=we(2),zt=we(3),P=Symbol.for("lit-noChange"),p=Symbol.for("lit-nothing"),Ke=new WeakMap,R=T.createTreeWalker(T,129);function Ve(o,e){if(!$e(o)||!o.hasOwnProperty("raw"))throw Error("invalid template strings array");return ze!==void 0?ze.createHTML(e):e}var xt=(o,e)=>{let t=o.length-1,r=[],s,n=e===2?"<svg>":e===3?"<math>":"",i=q;for(let l=0;l<t;l++){let a=o[l],h,u,d=-1,y=0;for(;y<a.length&&(i.lastIndex=y,u=i.exec(a),u!==null);)y=i.lastIndex,i===q?u[1]==="!--"?i=He:u[1]!==void 0?i=De:u[2]!==void 0?(Ge.test(u[2])&&(s=RegExp("</"+u[2],"g")),i=C):u[3]!==void 0&&(i=C):i===C?u[0]===">"?(i=s??q,d=-1):u[1]===void 0?d=-2:(d=i.lastIndex-u[2].length,h=u[1],i=u[3]===void 0?C:u[3]==='"'?qe:je):i===qe||i===je?i=C:i===He||i===De?i=q:(i=C,s=void 0);let b=i===C&&o[l+1].startsWith("/>")?" ":"";n+=i===q?a+ft:d>=0?(r.push(h),a.slice(0,d)+Be+a.slice(d)+_+b):a+_+(d===-2?l:b)}return[Ve(o,n+(o[t]||"<?>")+(e===2?"</svg>":e===3?"</math>":"")),r]},F=class o{constructor({strings:e,_$litType$:t},r){let s;this.parts=[];let n=0,i=0,l=e.length-1,a=this.parts,[h,u]=xt(e,t);if(this.el=o.createElement(h,r),R.currentNode=this.el.content,t===2||t===3){let d=this.el.content.firstChild;d.replaceWith(...d.childNodes)}for(;(s=R.nextNode())!==null&&a.length<l;){if(s.nodeType===1){if(s.hasAttributes())for(let d of s.getAttributeNames())if(d.endsWith(Be)){let y=u[i++],b=s.getAttribute(d).split(_),v=/([.?@])?(.*)/.exec(y);a.push({type:1,index:n,name:v[2],strings:b,ctor:v[1]==="."?fe:v[1]==="?"?ge:v[1]==="@"?xe:U}),s.removeAttribute(d)}else d.startsWith(_)&&(a.push({type:6,index:n}),s.removeAttribute(d));if(Ge.test(s.tagName)){let d=s.textContent.split(_),y=d.length-1;if(y>0){s.textContent=re?re.emptyScript:"";for(let b=0;b<y;b++)s.append(d[b],K()),R.nextNode(),a.push({type:2,index:++n});s.append(d[y],K())}}}else if(s.nodeType===8)if(s.data===Fe)a.push({type:2,index:n});else{let d=-1;for(;(d=s.data.indexOf(_,d+1))!==-1;)a.push({type:7,index:n}),d+=_.length-1}n++}}static createElement(e,t){let r=T.createElement("template");return r.innerHTML=e,r}};function M(o,e,t=o,r){if(e===P)return e;let s=r!==void 0?t._$Co?.[r]:t._$Cl,n=B(e)?void 0:e._$litDirective$;return s?.constructor!==n&&(s?._$AO?.(!1),n===void 0?s=void 0:(s=new n(o),s._$AT(o,t,r)),r!==void 0?(t._$Co??=[])[r]=s:t._$Cl=s),s!==void 0&&(e=M(o,s._$AS(o,e.values),s,r)),e}var ye=class{constructor(e,t){this._$AV=[],this._$AN=void 0,this._$AD=e,this._$AM=t}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(e){let{el:{content:t},parts:r}=this._$AD,s=(e?.creationScope??T).importNode(t,!0);R.currentNode=s;let n=R.nextNode(),i=0,l=0,a=r[0];for(;a!==void 0;){if(i===a.index){let h;a.type===2?h=new G(n,n.nextSibling,this,e):a.type===1?h=new a.ctor(n,a.name,a.strings,this,e):a.type===6&&(h=new be(n,this,e)),this._$AV.push(h),a=r[++l]}i!==a?.index&&(n=R.nextNode(),i++)}return R.currentNode=T,s}p(e){let t=0;for(let r of this._$AV)r!==void 0&&(r.strings!==void 0?(r._$AI(e,r,t),t+=r.strings.length-2):r._$AI(e[t])),t++}},G=class o{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(e,t,r,s){this.type=2,this._$AH=p,this._$AN=void 0,this._$AA=e,this._$AB=t,this._$AM=r,this.options=s,this._$Cv=s?.isConnected??!0}get parentNode(){let e=this._$AA.parentNode,t=this._$AM;return t!==void 0&&e?.nodeType===11&&(e=t.parentNode),e}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(e,t=this){e=M(this,e,t),B(e)?e===p||e==null||e===""?(this._$AH!==p&&this._$AR(),this._$AH=p):e!==this._$AH&&e!==P&&this._(e):e._$litType$!==void 0?this.$(e):e.nodeType!==void 0?this.T(e):gt(e)?this.k(e):this._(e)}O(e){return this._$AA.parentNode.insertBefore(e,this._$AB)}T(e){this._$AH!==e&&(this._$AR(),this._$AH=this.O(e))}_(e){this._$AH!==p&&B(this._$AH)?this._$AA.nextSibling.data=e:this.T(T.createTextNode(e)),this._$AH=e}$(e){let{values:t,_$litType$:r}=e,s=typeof r=="number"?this._$AC(e):(r.el===void 0&&(r.el=F.createElement(Ve(r.h,r.h[0]),this.options)),r);if(this._$AH?._$AD===s)this._$AH.p(t);else{let n=new ye(s,this),i=n.u(this.options);n.p(t),this.T(i),this._$AH=n}}_$AC(e){let t=Ke.get(e.strings);return t===void 0&&Ke.set(e.strings,t=new F(e)),t}k(e){$e(this._$AH)||(this._$AH=[],this._$AR());let t=this._$AH,r,s=0;for(let n of e)s===t.length?t.push(r=new o(this.O(K()),this.O(K()),this,this.options)):r=t[s],r._$AI(n),s++;s<t.length&&(this._$AR(r&&r._$AB.nextSibling,s),t.length=s)}_$AR(e=this._$AA.nextSibling,t){for(this._$AP?.(!1,!0,t);e!==this._$AB;){let r=Ie(e).nextSibling;Ie(e).remove(),e=r}}setConnected(e){this._$AM===void 0&&(this._$Cv=e,this._$AP?.(e))}},U=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(e,t,r,s,n){this.type=1,this._$AH=p,this._$AN=void 0,this.element=e,this.name=t,this._$AM=s,this.options=n,r.length>2||r[0]!==""||r[1]!==""?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=p}_$AI(e,t=this,r,s){let n=this.strings,i=!1;if(n===void 0)e=M(this,e,t,0),i=!B(e)||e!==this._$AH&&e!==P,i&&(this._$AH=e);else{let l=e,a,h;for(e=n[0],a=0;a<n.length-1;a++)h=M(this,l[r+a],t,a),h===P&&(h=this._$AH[a]),i||=!B(h)||h!==this._$AH[a],h===p?e=p:e!==p&&(e+=(h??"")+n[a+1]),this._$AH[a]=h}i&&!s&&this.j(e)}j(e){e===p?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,e??"")}},fe=class extends U{constructor(){super(...arguments),this.type=3}j(e){this.element[this.name]=e===p?void 0:e}},ge=class extends U{constructor(){super(...arguments),this.type=4}j(e){this.element.toggleAttribute(this.name,!!e&&e!==p)}},xe=class extends U{constructor(e,t,r,s,n){super(e,t,r,s,n),this.type=5}_$AI(e,t=this){if((e=M(this,e,t,0)??p)===P)return;let r=this._$AH,s=e===p&&r!==p||e.capture!==r.capture||e.once!==r.once||e.passive!==r.passive,n=e!==p&&(r===p||s);s&&this.element.removeEventListener(this.name,this,r),n&&this.element.addEventListener(this.name,this,e),this._$AH=e}handleEvent(e){typeof this._$AH=="function"?this._$AH.call(this.options?.host??this.element,e):this._$AH.handleEvent(e)}},be=class{constructor(e,t,r){this.element=e,this.type=6,this._$AN=void 0,this._$AM=t,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(e){M(this,e)}};var bt=ve.litHtmlPolyfillSupport;bt?.(F,G),(ve.litHtmlVersions??=[]).push("3.3.3");var We=(o,e,t)=>{let r=t?.renderBefore??e,s=r._$litPart$;if(s===void 0){let n=t?.renderBefore??null;r._$litPart$=s=new G(e.insertBefore(K(),n),n,void 0,t??{})}return s._$AI(o),s};var Se=globalThis,k=class extends S{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){let e=super.createRenderRoot();return this.renderOptions.renderBefore??=e.firstChild,e}update(e){let t=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(e),this._$Do=We(t,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return P}};k._$litElement$=!0,k.finalized=!0,Se.litElementHydrateSupport?.({LitElement:k});var vt=Se.litElementPolyfillSupport;vt?.({LitElement:k});(Se.litElementVersions??=[]).push("4.2.2");var Ye=o=>(e,t)=>{t!==void 0?t.addInitializer(()=>{customElements.define(o,e)}):customElements.define(o,e)};var $t={attribute:!0,type:String,converter:j,reflect:!1,hasChanged:te},wt=(o=$t,e,t)=>{let{kind:r,metadata:s}=t,n=globalThis.litPropertyMetadata.get(s);if(n===void 0&&globalThis.litPropertyMetadata.set(s,n=new Map),r==="setter"&&((o=Object.create(o)).wrapped=!0),n.set(t.name,o),r==="accessor"){let{name:i}=t;return{set(l){let a=e.get.call(this);e.set.call(this,l),this.requestUpdate(i,a,o,!0,l)},init(l){return l!==void 0&&this.C(i,void 0,o,l),l}}}if(r==="setter"){let{name:i}=t;return function(l){let a=this[i];e.call(this,l),this.requestUpdate(i,a,o,!0,l)}}throw Error("Unsupported decorator location: "+r)};function x(o){return(e,t)=>typeof t=="object"?wt(o,e,t):((r,s,n)=>{let i=s.hasOwnProperty(n);return s.constructor.createProperty(n,r),i?Object.getOwnPropertyDescriptor(s,n):void 0})(o,e,t)}function L(o){return x({...o,state:!0,attribute:!1})}var oe={Sun:"\u2609",Moon:"\u263D",Mercury:"\u263F",Venus:"\u2640",Earth:"\u2641",Mars:"\u2642",Jupiter:"\u2643",Saturn:"\u2644",Uranus:"\u2645",Neptune:"\u2646",Pluto:"\u2647",Rahu:"\u260A",Ketu:"\u260B",Ascendant:"Asc",Lagna:"La",NorthNode:"\u260A",SouthNode:"\u260B","North node":"\u260A","South node":"\u260B",Chiron:"\u26B7",Lilith:"\u26B8","Black moon lilith":"\u26B8"};var Ae={Aries:"\u2648",Taurus:"\u2649",Gemini:"\u264A",Cancer:"\u264B",Leo:"\u264C",Virgo:"\u264D",Libra:"\u264E",Scorpio:"\u264F",Sagittarius:"\u2650",Capricorn:"\u2651",Aquarius:"\u2652",Pisces:"\u2653"};var V=["Aries","Taurus","Gemini","Cancer","Leo","Virgo","Libra","Scorpio","Sagittarius","Capricorn","Aquarius","Pisces"];var W=o=>o??p;var ne=w`:host{font-family:var(--roxy-font-sans,system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-base,1rem);line-height:var(--roxy-leading-normal,1.5);animation:roxy-fade-in var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,cubic-bezier(.4, 0, .2, 1)) both;background:0 0;display:block;container-type:inline-size}:host([bare]){--roxy-surface:transparent;--roxy-shadow-sm:none;--roxy-shadow-md:none}*,:before,:after{box-sizing:border-box}h1,h2,h3,h4{font-family:var(--roxy-font-display,var(--roxy-font-sans,system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif))}@keyframes roxy-fade-in{0%{opacity:0;transform:translateY(2px)}to{opacity:1;transform:translateY(0)}}@media (prefers-reduced-motion:reduce){:host{animation:none}}.roxy-skeleton{background:linear-gradient(90deg, var(--roxy-border,#e4e4e7) 0%, color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent) 50%, var(--roxy-border,#e4e4e7) 100%);border-radius:var(--roxy-radius-md,8px);background-size:200% 100%;animation:1.4s ease-in-out infinite roxy-shimmer}@keyframes roxy-shimmer{0%{background-position:200% 0}to{background-position:-200% 0}}@media (prefers-reduced-motion:reduce){.roxy-skeleton{animation:none}}.roxy-sr-only{clip-path:inset(50%);white-space:nowrap;border:0;width:1px;height:1px;margin:0;padding:0;position:absolute;overflow:hidden}.roxy-empty{padding:var(--roxy-space-lg,1.5rem);color:var(--roxy-muted,#71717a);text-align:center;font-size:var(--roxy-text-sm,.875rem)}.roxy-error{gap:var(--roxy-space-sm,.5rem);padding:var(--roxy-space-lg,1.5rem);background:var(--roxy-surface,#fff);border:1px solid var(--roxy-danger,#dc2626);border-radius:var(--roxy-radius-md,8px);color:var(--roxy-danger-fg,#991b1b);font-size:var(--roxy-text-sm,.875rem);justify-items:start;display:grid}.roxy-surface{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a)}:host(:focus-within) .roxy-card{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px}.roxy-attribution{margin-top:var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-align:right}.roxy-attribution a{color:inherit;text-decoration:none}.roxy-attribution a:hover{color:var(--roxy-accent-ink,#b45309);text-decoration:underline}.roxy-attribution a:focus-visible{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px}.roxy-edit-bar{margin-bottom:var(--roxy-space-sm,.5rem);justify-content:flex-end;display:flex}.roxy-edit{padding:var(--roxy-space-xs,.25rem) var(--roxy-space-md,1rem);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);color:var(--roxy-fg,#0a0a0a);font-family:inherit;font-size:var(--roxy-text-sm,.875rem);cursor:pointer;background:0 0}.roxy-edit:hover{border-color:var(--roxy-accent,#f59e0b);color:var(--roxy-accent-ink,#b45309)}.roxy-edit:focus-visible{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px}:host{font-variant-emoji:text}`;var ie="Client-side components accept a pk_ publishable key only. Use a publishable key with an origin allowlist, or render server-side.";function Je(o){return!!o&&!o.startsWith("pk_")}function Ze(o,e={}){e.warn&&console.warn(ie),o.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{reason:"possible-secret-key",message:ie},bubbles:!0,composed:!0}))}var St="https://roxyapi.com/api/v2",ae=class{constructor(e){this.baseUrl=St;this.host=e,e.addController(this)}hostDisconnected(){this.abort?.abort(),this.abort=void 0}async run(e){if(!this.submitUrl&&this.secretKeyRefused())return;this.abort?.abort();let t=new AbortController;this.abort=t,this.host.loading=!0,this.host.error=null;try{let r=this.submitUrl?await fetch(this.submitUrl,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e),signal:t.signal}):await this.callApi(e,t.signal);if(!r.ok)throw new Error(await this.readError(r));let s=await r.json();if(t.signal.aborted)return;this.host.data=s}catch(r){if(r?.name==="AbortError")return;this.host.error=r instanceof Error?r.message:String(r)}finally{this.abort===t&&(this.abort=void 0),t.signal.aborted||(this.host.loading=!1)}}callApi(e,t){let r=new URL(`${this.baseUrl}${e.path}`);for(let[n,i]of Object.entries(e.query??{}))i!=null&&r.searchParams.set(n,String(i));let s={Accept:"application/json"};return this.publishableKey&&(s["X-API-Key"]=this.publishableKey),e.body!=null&&(s["Content-Type"]="application/json"),fetch(r,{method:e.method??"GET",headers:s,body:e.body!=null?JSON.stringify(e.body):void 0,signal:t})}secretKeyRefused(){return Je(this.publishableKey)?(this.host.error=ie,Ze(this.host),!0):!1}async readError(e){try{let t=await e.json();if(t?.error)return t.error}catch{}return`Request failed (${e.status})`}};function Xe(o,e,t,r=[]){let s={...t},n=`/${o.replace(/^\//,"")}`.replace(/\{([^}]+)\}/g,(h,u)=>{let d=s[u];return delete s[u],encodeURIComponent(String(d??""))}),i=new Set(r),l={},a={};for(let[h,u]of Object.entries(s))u===void 0||u===""||(e==="GET"||i.has(h)?l[h]=u:a[h]=u);return{path:n,method:e,query:l,body:e==="POST"?a:void 0}}var At="roxy-data";function _t(o){return o.nodeName==="SCRIPT"&&o.getAttribute("type")==="application/json"}var le=class{constructor(e){this.host=e,e.addController(this)}hostConnected(){if(this.host.data!=null)return;let e=this.read();e!==void 0&&(this.host.data=e,this.host.requestUpdate())}read(){let e=this.findInlineScript();return e?this.parse(e.textContent):void 0}findInlineScript(){for(let e of Array.from(this.host.children))if(_t(e)&&e.classList.contains(At))return e;return null}parse(e){if(e?.trim())try{return JSON.parse(e)}catch{return}}};var f=class extends k{constructor(){super();this.data=null;this.endpoint="";this.method="POST";this.remember=!1;this.loading=!1;this.error=null;this.selfFetched=!1;this.editing=!1;this.sticky=!1;this.onEdit=()=>{this.editing=!0};this.onFormSubmit=t=>{let r=t.detail;this.lastValues=r.values,this.sticky=!!r.sticky,this.selfFetched=!0,this.editing=!1,this.remember&&this.writeRemembered(r.values),this.fetcher.run(Xe(this.endpoint,this.method,r.values,r.queryKeys??[]))};new le(this),this.fetcher=new ae(this)}static{this.styles=[ne]}willUpdate(t){t.has("publishableKey")&&(this.fetcher.publishableKey=this.publishableKey),t.has("baseUrl")&&this.baseUrl&&(this.fetcher.baseUrl=this.baseUrl),t.has("submitUrl")&&(this.fetcher.submitUrl=this.submitUrl)}render(){return this.loading?this.renderLoading():this.error!=null?this.renderError(this.error):this.data!=null?this.selfFetched?this.editing?this.renderForm():this.renderResult(this.data):this.showAttribution()?c`${this.renderData(this.data)}${this.renderAttribution()}`:this.renderData(this.data):this.renderNoData()}renderResult(t){let r=this.sticky?c`${this.renderForm()}${this.renderData(t)}`:c`<div class="roxy-edit-bar"><button type="button" class="roxy-edit" @click="${this.onEdit}">Edit query</button></div>${this.renderData(t)}`;return this.showAttribution()?c`${r}${this.renderAttribution()}`:r}showAttribution(){return this.attribution!=null&&this.attribution!=="off"&&this.attribution!=="false"}renderAttribution(){return c`<div class="roxy-attribution"><a href="https://roxyapi.com/?utm_source=widget&utm_medium=embed" target="_blank" rel="noopener">Spiritual data by RoxyAPI</a></div>`}renderNoData(){return this.endpoint?this.renderForm():this.renderEmpty()}renderForm(){return c`<roxy-endpoint-form data-endpoint="${this.endpoint}" method="${this.method}" spec-url="${W(this.specUrl)}" publishable-key="${W(this.publishableKey)}" submit-label="${W(this.submitLabel)}" lang="${W(this.effectiveLang())}" .initialValues="${this.formInitialValues()}" @roxy-submit="${this.onFormSubmit}"></roxy-endpoint-form>`}formInitialValues(){return this.lastValues??(this.remember?this.readRemembered():void 0)}effectiveLang(){return this.lang||void 0}rememberKey(){return`roxy-ui:form:${this.endpoint}`}readRemembered(){try{let t=sessionStorage.getItem(this.rememberKey());return t?JSON.parse(t):void 0}catch{return}}writeRemembered(t){try{sessionStorage.setItem(this.rememberKey(),JSON.stringify(t))}catch{}}renderEmpty(){return c`<div class="roxy-empty" role="status">No data</div>`}renderLoading(){return c`<div class="roxy-skeleton" style="height:8rem" role="status" aria-label="Loading"></div>`}renderError(t){let r=c`<div class="roxy-error" role="alert">${t}</div>`;return this.endpoint?c`${r}${this.renderForm()}`:r}};g([x({attribute:!1})],f.prototype,"data",2),g([x({type:String,attribute:"data-endpoint"})],f.prototype,"endpoint",2),g([x({type:String})],f.prototype,"method",2),g([x({type:String,attribute:"publishable-key"})],f.prototype,"publishableKey",2),g([x({type:String,attribute:"base-url"})],f.prototype,"baseUrl",2),g([x({type:String,attribute:"spec-url"})],f.prototype,"specUrl",2),g([x({type:String,attribute:"submit-url"})],f.prototype,"submitUrl",2),g([x({type:Boolean})],f.prototype,"remember",2),g([x({type:String,attribute:"submit-label"})],f.prototype,"submitLabel",2),g([x({type:String})],f.prototype,"attribution",2),g([L()],f.prototype,"loading",2),g([L()],f.prototype,"error",2),g([L()],f.prototype,"selfFetched",2),g([L()],f.prototype,"editing",2),g([L()],f.prototype,"sticky",2);function kt(o){let e=o%360;return e<0?e+360:e}function Qe(o){let e=kt(o),t=Math.floor(e/30)%12,r=e%30,s=Math.floor(r),n=(r-s)*60,i=Math.floor(n),l=Math.round((n-i)*60);return{sign:V[t]??"Aries",signIndex:t,degree:s,minute:i,second:l}}function $(o,e,t,r){let s=r*Math.PI/180;return{x:o+t*Math.cos(s),y:e+t*Math.sin(s)}}function _e(){return c`<svg class="roxy-chevron" viewBox="0 0 16 16" width="14" height="14" aria-hidden="true"><path d="M4 6l4 4 4-4" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>`}var et=w`summary{list-style:none}summary::-webkit-details-marker{display:none}.roxy-chevron{aspect-ratio:auto;width:14px;height:14px;color:var(--roxy-muted,#71717a);transition:transform var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,ease);flex-shrink:0}details[open]>summary .roxy-chevron{transform:rotate(180deg)}@media (prefers-reduced-motion:reduce){.roxy-chevron{transition:none}}`;function A(o){return o?o.charAt(0).toUpperCase()+o.slice(1).toLowerCase():""}function O(o,e=1){if(typeof o!="number"||!Number.isFinite(o))return"";let t=o.toFixed(e);return t.includes(".")?t.replace(/\.?0+$/,""):t}var tt={conjunction:"aspect-conjunction",sextile:"aspect-sextile",square:"aspect-square",trine:"aspect-trine",opposition:"aspect-opposition"};function ke(o){return(o.type??"").toLowerCase().trim().replace(/[\s_]+/g,"-")}function ce(o){return A(ke(o))}var rt=w`.block{border-top:1px solid var(--roxy-border,#e4e4e7);padding-top:var(--roxy-space-md,1rem)}.block h3{margin:0 0 var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em}.interp-card{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);margin-bottom:var(--roxy-space-xs,.25rem)}.interp-card summary{cursor:pointer;color:var(--roxy-fg,#0a0a0a);align-items:center;gap:var(--roxy-space-sm,.5rem);font-weight:500;font-size:var(--roxy-text-sm,.875rem);display:flex}.interp-card summary:focus-visible{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px;border-radius:var(--roxy-radius-sm,4px)}.interp-lead{flex-wrap:wrap;flex:auto;order:1;align-items:baseline;gap:.4rem;min-width:0;display:inline-flex}.interp-aside{flex-shrink:0;order:2;align-items:center;gap:.5rem;display:inline-flex}.roxy-chevron{order:3}.interp-aside small{color:var(--roxy-muted,#71717a);white-space:nowrap;font-weight:400}@container (width<=26rem){.interp-card summary{flex-wrap:wrap}.roxy-chevron{order:2}.interp-aside{flex-basis:100%;order:3;justify-content:flex-end}}.interp-body{margin-top:var(--roxy-space-sm,.5rem);gap:var(--roxy-space-sm,.5rem);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-sm,.875rem);overflow-wrap:anywhere;line-height:1.6;display:grid}.interp-body p{margin:0}`;var Et=12,Re=360,m=Re/2,Ee=170,Ct=154,Ce=124,I=96,z=class extends f{renderEmpty(){return c`<div class="roxy-empty" role="status">No synastry data</div>`}renderData(e){let{person1:t,person2:r,compatibilityScore:s,analysis:n}=e,i=e.interAspects??[],l=t?.planets??[],a=r?.planets??[],h=typeof s=="number"?Math.round(s):void 0,u=n?.overall,d=n?.strengths??[],y=n?.challenges??[],b=l.length>0&&a.length>0,v=[...i].sort((E,pe)=>(pe.strength??0)-(E.strength??0)),de=v.slice(0,Et);return c`<div class="wrap" aria-label="Synastry compatibility chart"><div class="head"><h2 class="title">Synastry</h2>${typeof h=="number"?c`<span class="score" aria-label="${`Score ${h} of 100`}">${h} / 100</span>`:p}</div>${this.renderPeople(t,r)} ${b?c`<svg viewBox="0 0 ${Re} ${Re}" role="img" aria-label="Dual chart wheel comparing two natal charts"><title>Synastry dual wheel</title><circle class="wheel-line" cx="${m}" cy="${m}" r="${Ee}" stroke-width="1.5"/><circle class="wheel-line" cx="${m}" cy="${m}" r="${I+14}" stroke-width="0.8"/><circle class="wheel-line" cx="${m}" cy="${m}" r="${I-14}" stroke-width="0.6"/>${this.renderSpokes()} ${this.renderSigns()} ${this.renderInterAspectLines(l,a,i)} ${this.renderRing(l,Ce,"p1",1)} ${this.renderRing(a,I,"p2",2)} ${this.renderAscendants(e)}</svg><div class="legend-row"><span><span class="swatch" style="background:var(--roxy-accent)"></span>Person 1</span> <span><span class="swatch" style="background:var(--roxy-info)"></span>Person 2</span> <span><span class="swatch" style="background:var(--roxy-success)"></span>harmonious</span> <span><span class="swatch" style="background:var(--roxy-danger)"></span>challenging</span></div>`:c`<div class="missing-planets" role="status">Synastry response missing planet positions. Pass <code>data</code> with <code>person1.planets</code> and <code>person2.planets</code> arrays from the natal-chart endpoint, or use the <code><roxy-data></code> fallback.</div>`} ${this.renderSummaryPills(e.summary)} ${u?c`<p class="summary">${u}</p>`:p} ${de.length>0?c`<section class="block"><h3>Inter-aspects</h3>${de.map((E,pe)=>this.renderAspectCard(E,pe))}</section>`:p} ${v.length>de.length?this.renderCatalog(v):p} ${d.length>0||y.length>0?c`<div class="lists">${d.length?c`<div><h3>Strengths</h3><ul>${d.map(E=>c`<li>${E}</li>`)}</ul></div>`:p} ${y.length?c`<div><h3>Challenges</h3><ul>${y.map(E=>c`<li>${E}</li>`)}</ul></div>`:p}</div>`:p}</div>`}renderPeople(e,t){let r=(n,i)=>{if(!n)return p;let a=[["Sun",n.sunSign??""],["Moon",n.moonSign??""],["Asc",n.ascendant?`${n.ascendant.sign} ${O(n.ascendant.degree,0)}\xB0`:""]].filter(([,h])=>h);return a.length===0?p:c`<div class="person"><span class="person-name"><span class="person-dot p${i}" aria-hidden="true"></span> ${n.name||`Person ${i}`}</span><div class="big-three">${a.map(([h,u])=>c`<span><span class="lbl">${h}</span> <span aria-hidden="true">${Ae[A(u.split(" ")[0]??"")]??""}</span> ${u}</span>`)}</div></div>`},s=[r(e,1),r(t,2)].filter(n=>n!==p);return s.length===0?p:c`<div class="people">${s}</div>`}renderSummaryPills(e){if(!e||typeof e!="object")return p;let t=Object.entries(e.byType??{}).sort((r,s)=>s[1]-r[1]);return typeof e.total!="number"&&t.length===0?p:c`<div class="summary-pills" role="region" aria-label="Inter-aspect summary">${typeof e.total=="number"?c`<span class="pill">Total: ${e.total}</span>`:p} <span class="pill pill--success">Harmonious: ${e.harmonious}</span> <span class="pill pill--danger">Challenging: ${e.challenging}</span> <span class="pill">Neutral: ${e.neutral}</span> ${t.map(([r,s])=>c`<span class="pill">${ce({type:r})}: ${s}</span>`)}</div>`}renderAspectCard(e,t){let r=oe[A(e.planet1)]??"",s=oe[A(e.planet2)]??"",n=(e.interpretation??"neutral").toLowerCase(),i=e.meaning,l=c`<span class="interp-lead"><span aria-hidden="true" class="glyph">${r}</span>${e.planet1} <span class="asp-name ${n}">${ce(e)}</span> <span aria-hidden="true" class="glyph">${s}</span>${e.planet2}</span>`,a=c`<span class="interp-aside"><small>orb ${O(e.orb,2)}° · str ${O(e.strength,0)}</small></span>`;return!i?.relationshipContext&&!i?.description?.short?c`<div class="interp-card"><div class="static-head">${l}${a}</div></div>`:c`<details class="interp-card" name="synastry-aspects" ?open="${t===0}"><summary>${l}${_e()}${a}</summary><div class="interp-body">${i.relationshipContext?c`<p><span class="context">In this pairing</span> ${i.relationshipContext}</p>`:p} ${i.description?.short?c`<p>${i.description.short}</p>`:p} ${i.keywords?.length?c`<div class="interp-keywords">${i.keywords.map(h=>c`<span class="kw">${h}</span>`)}</div>`:p}</div></details>`}renderCatalog(e){return c`<details class="catalog"><summary>${_e()} All ${e.length} inter-aspects</summary><div class="scroll">${this.renderAspects(e)}</div></details>`}toAngle(e){return 180-e}renderSpokes(){return Array.from({length:12},(e,t)=>{let r=this.toAngle(t*30),s=$(m,m,I-14,r),n=$(m,m,Ee,r);return N`<line class="wheel-line" x1=${s.x} y1=${s.y} x2=${n.x} y2=${n.y} stroke-width="0.6" />`})}renderSigns(){return V.map((e,t)=>{let r=this.toAngle(t*30+15),s=$(m,m,Ct,r);return N`<text class="sign" x=${s.x} y=${s.y} text-anchor="middle" dominant-baseline="central">${Ae[e]}</text>`})}renderRing(e,t,r,s){return e.map(n=>{if(!Number.isFinite(n.longitude))return p;let i=this.toAngle(n.longitude),l=$(m,m,t,i),h=$(m,m,t+(s===1?-12:-10),i),u=oe[A(n.name)]??n.name.slice(0,2),d=Qe(n.longitude),y=n.isRetrograde===!0,b=`${d.degree}\xB0${String(d.minute).padStart(2,"0")}'`,v=`${n.name}${y?" retrograde":""} - ${b} ${d.sign}`;return N`<g>
|
|
265
265
|
<text class=${r} x=${l.x} y=${l.y} text-anchor="middle" dominant-baseline="central"><title>${v}</title>${u}<tspan class="person-tag" dy="-0.55em" dx="0.15em">${s}</tspan></text>
|
|
266
266
|
<text class="planet-deg" x=${h.x} y=${h.y} text-anchor="middle" dominant-baseline="central">${d.degree}°${y?N`<tspan class="retro"> ℞</tspan>`:p}</text>
|
|
267
267
|
</g>`})}renderAscendants(e){let t=[],r=(s,n)=>{if(!s)return;let i=V.findIndex(y=>y.toLowerCase()===s.sign.toLowerCase());if(i===-1)return;let l=i*30+s.degree,a=this.toAngle(l),h=n===1?Ce+14:I+14,u=$(m,m,h,a),d=$(m,m,Ee+14,a);t.push(N`<g>
|
|
268
268
|
<line class="asc-tick" x1=${u.x} y1=${u.y} x2=${d.x} y2=${d.y} />
|
|
269
269
|
<text class="asc-label" x=${d.x} y=${d.y} text-anchor="middle" dominant-baseline="central">Asc${n}</text>
|
|
270
|
-
</g>`)};return r(e.person1?.ascendant,1),r(e.person2?.ascendant,2),t}renderInterAspectLines(e,t,r){let s=(n,i)=>{let l=
|
|
270
|
+
</g>`)};return r(e.person1?.ascendant,1),r(e.person2?.ascendant,2),t}renderInterAspectLines(e,t,r){let s=(n,i)=>{let l=A(i);for(let a of n)if(A(a.name)===l&&typeof a.longitude=="number")return a.longitude};return r.map(n=>{let i=s(e,n.planet1),l=s(t,n.planet2);if(i===void 0||l===void 0)return p;let a=$(m,m,Ce-12,this.toAngle(i)),h=$(m,m,I+8,this.toAngle(l)),u=ke(n),d=tt[u]??"aspect-other",y=O(n.orb,1);return N`<line class=${`aspect ${d}`} x1=${a.x} y1=${a.y} x2=${h.x} y2=${h.y}><title>${n.planet1} ${u} ${n.planet2}${y?` (orb ${y}\xB0)`:""}</title></line>`})}renderAspects(e){return c`<table><caption class="roxy-sr-only">Inter-chart aspects: the planet from chart 1, the planet from chart 2, the aspect between them, the orb in degrees and the strength.</caption><thead><tr><th scope="col">Planet 1</th><th scope="col">Planet 2</th><th scope="col">Aspect</th><th scope="col">Orb</th><th scope="col">Strength</th></tr></thead><tbody>${e.map(t=>c`<tr><td>${t.planet1}</td><td>${t.planet2}</td><td>${ce(t)}</td><td class="orb">${O(t.orb,1)}</td><td>${O(t.strength,0)}</td></tr>`)}</tbody></table>`}};z.styles=[ne,et,rt,w`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:center;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.score{font-variant-numeric:tabular-nums;font-weight:var(--roxy-weight-bold,600);color:var(--roxy-accent-ink,#b45309);font-size:var(--roxy-text-xl,1.5rem)}svg{width:100%;max-width:var(--roxy-chart-max-width,560px);aspect-ratio:1;height:auto;margin:0 auto;display:block}.wheel-line{fill:none;stroke:var(--roxy-border,#e4e4e7)}.sign{fill:var(--roxy-secondary,#475569);font-size:14px}.p1{fill:var(--roxy-accent,#f59e0b);font-size:13px;font-weight:600}.p2{fill:var(--roxy-info,#0284c7);font-size:13px;font-weight:600}.person-tag{opacity:.85;font-size:7px;font-weight:700}.planet-deg{fill:var(--roxy-muted,#71717a);font-size:7px;font-family:var(--roxy-font-sans)}.planet-deg .retro{fill:var(--roxy-danger,#dc2626)}.asc-tick{stroke:var(--roxy-accent-ink,#b45309);stroke-width:1px;opacity:.75}.asc-label{fill:var(--roxy-accent-ink,#b45309);font-size:9px;font-weight:700;font-family:var(--roxy-font-sans);letter-spacing:.04em}.aspect{stroke-width:.8px;fill:none;opacity:.5}.aspect-trine,.aspect-sextile{stroke:var(--roxy-success,#16a34a)}.aspect-square,.aspect-opposition{stroke:var(--roxy-danger,#dc2626)}.aspect-conjunction{stroke:var(--roxy-accent-ink,#b45309)}.aspect-other{stroke:var(--roxy-muted,#71717a);opacity:.35}.legend-row{gap:var(--roxy-space-md,1rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);margin-top:calc(var(--roxy-space-xs,.25rem) * -1);flex-wrap:wrap;display:flex}.legend-row .swatch{vertical-align:middle;border-radius:50%;width:8px;height:8px;margin-right:4px;display:inline-block}.summary{color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-base,1rem);margin:0}.people{gap:var(--roxy-space-sm,.5rem);grid-template-columns:repeat(auto-fit,minmax(11rem,1fr));display:grid}.person{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);gap:.3rem;display:grid}.person-name{font-weight:var(--roxy-weight-bold,600);font-size:var(--roxy-text-sm,.875rem);align-items:center;gap:.4rem;display:flex}.person-dot{border-radius:50%;flex-shrink:0;width:8px;height:8px}.person-dot.p1{background:var(--roxy-accent,#f59e0b)}.person-dot.p2{background:var(--roxy-info,#0284c7)}.big-three{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);flex-wrap:wrap;gap:.25rem .75rem;display:flex}.big-three span{align-items:baseline;gap:.25rem;display:inline-flex}.big-three .lbl{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem)}.summary-pills{gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;display:flex}.pill{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent);color:var(--roxy-fg,#0a0a0a);padding:2px 8px}.pill--success{background:color-mix(in srgb, var(--roxy-success,#16a34a) 12%, transparent);color:var(--roxy-success-fg,#166534)}.pill--danger{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 12%, transparent);color:var(--roxy-danger-fg,#991b1b)}.glyph{font-size:1.1em;line-height:1}.static-head{align-items:center;gap:var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-sm,.875rem);flex-wrap:wrap;font-weight:500;display:flex}.asp-name{font-weight:var(--roxy-weight-bold,600);text-transform:capitalize}.asp-name.harmonious{color:var(--roxy-success-fg,#166534)}.asp-name.challenging{color:var(--roxy-danger-fg,#991b1b)}.interp-keywords{flex-wrap:wrap;gap:.25rem;display:flex}.interp-keywords .kw{border-radius:var(--roxy-radius-full,9999px);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-xs,.75rem);padding:1px 8px}.context{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);text-transform:uppercase;letter-spacing:.06em;font-weight:var(--roxy-weight-bold,600)}.catalog>summary{cursor:pointer;font-weight:var(--roxy-weight-bold,600);font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);align-items:center;gap:.5rem;display:flex}.scroll{min-width:0;margin-top:var(--roxy-space-sm,.5rem);overflow-x:auto}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{padding:var(--roxy-space-sm,.5rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);text-align:left}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.06em}td.orb{font-variant-numeric:tabular-nums;color:var(--roxy-muted,#71717a)}.lists{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fit,minmax(14rem,1fr));display:grid}.lists h3{margin:0 0 var(--roxy-space-xs,.25rem) 0;font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em}.lists ul{padding-left:var(--roxy-space-md,1rem);font-size:var(--roxy-text-sm,.875rem);margin:0}.missing-planets{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 8%, transparent);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-md,1rem);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-sm,.875rem);line-height:1.5}.missing-planets code{font-family:var(--roxy-font-mono,ui-monospace, SFMono-Regular, Menlo, monospace);background:color-mix(in srgb, var(--roxy-fg,#0a0a0a) 6%, transparent);border-radius:4px;padding:0 4px;font-size:.95em}`],z=g([Ye("roxy-synastry-chart")],z);Z();return at(Rt);})();
|
|
271
271
|
/*! Bundled license information:
|
|
272
272
|
|
|
273
273
|
@lit/reactive-element/css-tag.js:
|