@roxyapi/ui 1.2.0 → 1.3.0
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/AGENTS.md +19 -1
- package/README.md +39 -0
- package/THEMING.md +2 -0
- package/components-catalog.json +1 -1
- package/dist/cdn/components/almanac-day.js +3 -3
- package/dist/cdn/components/angel-number-card.js +1 -1
- package/dist/cdn/components/angel-number-lookup.js +1 -1
- package/dist/cdn/components/arudha-padas.js +2 -2
- package/dist/cdn/components/ashtakavarga-grid.js +3 -3
- package/dist/cdn/components/aspects-table.js +1 -1
- package/dist/cdn/components/astrocartography-map.js +4 -4
- package/dist/cdn/components/bazi-chart.js +2 -2
- package/dist/cdn/components/bhav-chalit-table.js +2 -2
- package/dist/cdn/components/bhava-bala-table.js +2 -2
- package/dist/cdn/components/biorhythm-chart.js +2 -2
- package/dist/cdn/components/bodygraph.js +3 -3
- package/dist/cdn/components/chara-karakas.js +2 -2
- package/dist/cdn/components/choghadiya-grid.js +1 -1
- package/dist/cdn/components/compatibility-card.js +2 -2
- package/dist/cdn/components/compound-number.js +3 -3
- package/dist/cdn/components/crystal-card.js +1 -1
- package/dist/cdn/components/crystal-grid.js +2 -2
- package/dist/cdn/components/dasha-timeline.js +2 -2
- package/dist/cdn/components/data.js +1 -1
- package/dist/cdn/components/divisional-chart.js +4 -4
- package/dist/cdn/components/dosha-card.js +2 -2
- package/dist/cdn/components/dosha-constitution.js +2 -2
- package/dist/cdn/components/dream-card.js +3 -3
- package/dist/cdn/components/dream-search.js +2 -2
- package/dist/cdn/components/endpoint-form.js +2 -2
- package/dist/cdn/components/ephemeris-table.js +2 -2
- package/dist/cdn/components/fixed-stars.js +3 -3
- package/dist/cdn/components/flying-star-chart.js +2 -2
- package/dist/cdn/components/forecast-digest.js +3 -3
- package/dist/cdn/components/forecast-timeline.js +3 -3
- package/dist/cdn/components/gematria.js +3 -3
- package/dist/cdn/components/gochara-table.js +3 -3
- package/dist/cdn/components/guna-milan.js +3 -3
- package/dist/cdn/components/hd-connection.js +2 -2
- package/dist/cdn/components/hd-penta.js +16 -16
- package/dist/cdn/components/hd-type-card.js +3 -3
- package/dist/cdn/components/hd-variables.js +1 -1
- package/dist/cdn/components/heliacal-table.js +3 -3
- package/dist/cdn/components/hexagram.js +1 -1
- package/dist/cdn/components/hora-table.js +3 -3
- package/dist/cdn/components/horoscope-card.js +2 -2
- package/dist/cdn/components/kp-chart.js +3 -3
- package/dist/cdn/components/kp-finance-card.js +2 -2
- package/dist/cdn/components/kp-planets-table.js +2 -2
- package/dist/cdn/components/kp-ruling-planets.js +3 -3
- package/dist/cdn/components/kua-card.js +2 -2
- package/dist/cdn/components/local-space-compass.js +4 -4
- package/dist/cdn/components/location-search.js +1 -1
- package/dist/cdn/components/luck-pillars.js +3 -3
- package/dist/cdn/components/mayan-day-sign.js +3 -3
- package/dist/cdn/components/moon-phase.js +2 -2
- package/dist/cdn/components/nakshatra-card.js +3 -3
- package/dist/cdn/components/natal-chart.js +10 -10
- package/dist/cdn/components/numerology-card.js +2 -2
- package/dist/cdn/components/panchang-table.js +2 -2
- package/dist/cdn/components/positions-table.js +3 -3
- package/dist/cdn/components/profection-card.js +3 -3
- package/dist/cdn/components/reference-card.js +3 -3
- package/dist/cdn/components/relocation-wheel.js +11 -11
- package/dist/cdn/components/report.js +50 -0
- package/dist/cdn/components/shadbala-table.js +2 -2
- package/dist/cdn/components/synastry-chart.js +6 -6
- package/dist/cdn/components/tarot-card.js +2 -2
- package/dist/cdn/components/tarot-catalog.js +2 -2
- package/dist/cdn/components/tarot-spread.js +2 -2
- package/dist/cdn/components/transit-wheel.js +1 -1
- package/dist/cdn/components/transits-table.js +2 -2
- package/dist/cdn/components/upagraha-table.js +3 -3
- package/dist/cdn/components/vastu-mandala.js +5 -5
- package/dist/cdn/components/vedic-aspects.js +3 -3
- package/dist/cdn/components/vedic-daily.js +2 -2
- package/dist/cdn/components/vedic-kundli.js +45 -45
- package/dist/cdn/components/vedic-planets-table.js +1 -1
- package/dist/cdn/components/western-planets-table.js +2 -2
- package/dist/cdn/components/yoga-list.js +1 -1
- package/dist/cdn/components/zodiac-card.js +3 -3
- package/dist/cdn/locales/de.js +1 -1
- package/dist/cdn/locales/es.js +1 -1
- package/dist/cdn/locales/fr.js +1 -1
- package/dist/cdn/locales/hi.js +1 -1
- package/dist/cdn/locales/pt.js +1 -1
- package/dist/cdn/locales/ru.js +1 -1
- package/dist/cdn/locales/tr.js +1 -1
- package/dist/cdn/roxy-ui.js +84 -84
- package/dist/cdn/widgets.js +1 -1
- package/dist/components/almanac-day.js +1 -1
- package/dist/components/angel-number-card.js +1 -1
- package/dist/components/angel-number-lookup.js +1 -1
- package/dist/components/arudha-padas.js +1 -1
- package/dist/components/ashtakavarga-grid.js +1 -1
- package/dist/components/aspects-table.js +1 -1
- package/dist/components/astrocartography-map.js +2 -2
- package/dist/components/bazi-chart.js +1 -1
- package/dist/components/bhav-chalit-table.js +1 -1
- package/dist/components/bhava-bala-table.js +1 -1
- package/dist/components/biorhythm-chart.js +1 -1
- package/dist/components/bodygraph.js +2 -2
- package/dist/components/chara-karakas.js +1 -1
- package/dist/components/choghadiya-grid.js +1 -1
- package/dist/components/compatibility-card.js +1 -1
- package/dist/components/compound-number.js +1 -1
- package/dist/components/crystal-card.js +1 -1
- package/dist/components/crystal-grid.js +1 -1
- package/dist/components/dasha-timeline.js +1 -1
- package/dist/components/data.js +1 -1
- package/dist/components/divisional-chart.js +8 -8
- package/dist/components/dosha-card.js +1 -1
- package/dist/components/dosha-constitution.js +1 -1
- package/dist/components/dream-card.js +1 -1
- package/dist/components/dream-search.js +1 -1
- package/dist/components/endpoint-form.js +1 -1
- package/dist/components/ephemeris-table.js +1 -1
- package/dist/components/fixed-stars.js +1 -1
- package/dist/components/flying-star-chart.js +1 -1
- package/dist/components/forecast-digest.js +1 -1
- package/dist/components/forecast-timeline.js +1 -1
- package/dist/components/gematria.js +1 -1
- package/dist/components/gochara-table.js +1 -1
- package/dist/components/guna-milan.js +1 -1
- package/dist/components/hd-connection.js +3 -3
- package/dist/components/hd-penta.js +1 -1
- package/dist/components/hd-type-card.js +1 -1
- package/dist/components/hd-variables.js +1 -1
- package/dist/components/heliacal-table.js +1 -1
- package/dist/components/hexagram.js +1 -1
- package/dist/components/hora-table.js +1 -1
- package/dist/components/horoscope-card.js +1 -1
- package/dist/components/kp-chart.js +1 -1
- package/dist/components/kp-finance-card.js +1 -1
- package/dist/components/kp-planets-table.js +1 -1
- package/dist/components/kp-ruling-planets.js +1 -1
- package/dist/components/kua-card.js +1 -1
- package/dist/components/local-space-compass.js +3 -3
- package/dist/components/location-search.js +1 -1
- package/dist/components/luck-pillars.js +1 -1
- package/dist/components/mayan-day-sign.js +1 -1
- package/dist/components/moon-phase.js +1 -1
- package/dist/components/nakshatra-card.js +1 -1
- package/dist/components/natal-chart.js +1 -1
- package/dist/components/numerology-card.js +1 -1
- package/dist/components/panchang-table.js +1 -1
- package/dist/components/positions-table.js +1 -1
- package/dist/components/profection-card.js +1 -1
- package/dist/components/reference-card.js +1 -1
- package/dist/components/relocation-wheel.js +10 -10
- package/dist/components/report.d.ts +61 -0
- package/dist/components/report.js +1 -0
- package/dist/components/shadbala-table.js +1 -1
- package/dist/components/synastry-chart.js +4 -4
- package/dist/components/tarot-card.js +1 -1
- package/dist/components/tarot-catalog.js +1 -1
- package/dist/components/tarot-spread.js +1 -1
- package/dist/components/transit-wheel.js +7 -7
- package/dist/components/transits-table.js +1 -1
- package/dist/components/upagraha-table.js +1 -1
- package/dist/components/vastu-mandala.js +4 -4
- package/dist/components/vedic-aspects.js +1 -1
- package/dist/components/vedic-daily.js +1 -1
- package/dist/components/vedic-kundli.js +1 -1
- package/dist/components/vedic-planets-table.js +1 -1
- package/dist/components/western-planets-table.js +1 -1
- package/dist/components/yoga-list.js +1 -1
- package/dist/components/zodiac-card.js +1 -1
- package/dist/forms/labels/de.json +1 -1
- package/dist/forms/labels/en.json +1 -1
- package/dist/forms/labels/es.json +1 -1
- package/dist/forms/labels/fr.json +1 -1
- package/dist/forms/labels/hi.json +1 -1
- package/dist/forms/labels/pt.json +1 -1
- package/dist/forms/labels/ru.json +1 -1
- package/dist/forms/labels/tr.json +1 -1
- package/dist/forms.json +1 -1
- package/dist/generated/endpoint-defaults.d.ts +1 -0
- package/dist/i18n/chrome-strings.d.ts +1 -1
- package/dist/index.cjs +83 -83
- package/dist/index.d.ts +1 -0
- package/dist/index.js +85 -85
- package/dist/locales/de.js +1 -1
- package/dist/locales/es.js +1 -1
- package/dist/locales/fr.js +1 -1
- package/dist/locales/hi.js +1 -1
- package/dist/locales/pt.js +1 -1
- package/dist/locales/ru.js +1 -1
- package/dist/locales/tr.js +1 -1
- package/dist/manifest.json +1 -1
- package/dist/schemas/post--reports-bazi.json +1 -0
- package/dist/schemas/post--reports-human-design.json +1 -0
- package/dist/schemas/post--reports-kundli.json +1 -0
- package/dist/schemas/post--reports-matchmaking.json +1 -0
- package/dist/schemas/post--reports-natal.json +1 -0
- package/dist/schemas/post--reports-numerology.json +1 -0
- package/dist/schemas/post--reports-synastry.json +1 -0
- package/dist/schemas/post--reports-tarot.json +1 -0
- package/dist/schemas/post--reports-yearly-forecast.json +1 -0
- package/dist/tool-component.cjs +1 -1
- package/dist/tool-component.js +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/types.gen.d.ts +17614 -15166
- package/dist/utils/brand.d.ts +3 -0
- package/dist/utils/object-url.d.ts +17 -0
- package/dist/version.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
var RoxyUI_ephemeris_table=(()=>{var q=Object.defineProperty;var Pt=Object.getOwnPropertyDescriptor;var Le=Object.getOwnPropertyNames;var Ue=Object.prototype.hasOwnProperty;var Me=(r,t)=>{for(var e in t)q(r,e,{get:t[e],enumerable:true})},Ne=(r,t,e,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of Le(t))!Ue.call(r,o)&&o!==e&&q(r,o,{get:()=>t[o],enumerable:!(n=Pt(t,o))||n.enumerable});return r};var Ie=r=>Ne(q({},"__esModule",{value:true}),r),u=(r,t,e,n)=>{for(var o=n>1?void 0:n?Pt(t,e):t,s=r.length-1,i;s>=0;s--)(i=r[s])&&(o=(n?i(t,e,o):i(o))||o);return n&&o&&q(t,e,o),o};var Cn={};Me(Cn,{ROXY_UI_TOKENS_STYLE_ID:()=>nt,RoxyEphemerisTable:()=>T,injectRoxyTokens:()=>rt});var V=globalThis,Y=V.ShadowRoot&&(V.ShadyCSS===void 0||V.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,pt=Symbol(),Ct=new WeakMap,M=class{constructor(t,e,n){if(this._$cssResult$=true,n!==pt)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o,e=this.t;if(Y&&t===void 0){let n=e!==void 0&&e.length===1;n&&(t=Ct.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),n&&Ct.set(e,t))}return t}toString(){return this.cssText}},
|
|
1
|
+
var RoxyUI_ephemeris_table=(()=>{var q=Object.defineProperty;var Pt=Object.getOwnPropertyDescriptor;var Le=Object.getOwnPropertyNames;var Ue=Object.prototype.hasOwnProperty;var Me=(r,t)=>{for(var e in t)q(r,e,{get:t[e],enumerable:true})},Ne=(r,t,e,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of Le(t))!Ue.call(r,o)&&o!==e&&q(r,o,{get:()=>t[o],enumerable:!(n=Pt(t,o))||n.enumerable});return r};var Ie=r=>Ne(q({},"__esModule",{value:true}),r),u=(r,t,e,n)=>{for(var o=n>1?void 0:n?Pt(t,e):t,s=r.length-1,i;s>=0;s--)(i=r[s])&&(o=(n?i(t,e,o):i(o))||o);return n&&o&&q(t,e,o),o};var Cn={};Me(Cn,{ROXY_UI_TOKENS_STYLE_ID:()=>nt,RoxyEphemerisTable:()=>T,injectRoxyTokens:()=>rt});var V=globalThis,Y=V.ShadowRoot&&(V.ShadyCSS===void 0||V.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,pt=Symbol(),Ct=new WeakMap,M=class{constructor(t,e,n){if(this._$cssResult$=true,n!==pt)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o,e=this.t;if(Y&&t===void 0){let n=e!==void 0&&e.length===1;n&&(t=Ct.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),n&&Ct.set(e,t))}return t}toString(){return this.cssText}},Ot=r=>new M(typeof r=="string"?r:r+"",void 0,pt),v=(r,...t)=>{let e=r.length===1?r[0]:t.reduce((n,o,s)=>n+(i=>{if(i._$cssResult$===true)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.")})(o)+r[s+1],r[0]);return new M(e,r,pt)},Ft=(r,t)=>{if(Y)r.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet);else for(let e of t){let n=document.createElement("style"),o=V.litNonce;o!==void 0&&n.setAttribute("nonce",o),n.textContent=e.cssText,r.appendChild(n)}},ht=Y?r=>r:r=>r instanceof CSSStyleSheet?(t=>{let e="";for(let n of t.cssRules)e+=n.cssText;return Ot(e)})(r):r;var{is:De,defineProperty:Ge,getOwnPropertyDescriptor:Ke,getOwnPropertyNames:je,getOwnPropertySymbols:ze,getPrototypeOf:He}=Object,W=globalThis,Lt=W.trustedTypes,Be=Lt?Lt.emptyScript:"",qe=W.reactiveElementPolyfillSupport,N=(r,t)=>r,I={toAttribute(r,t){switch(t){case Boolean:r=r?Be:null;break;case Object:case Array:r=r==null?r:JSON.stringify(r)}return r},fromAttribute(r,t){let e=r;switch(t){case Boolean:e=r!==null;break;case Number:e=r===null?null:Number(r);break;case Object:case Array:try{e=JSON.parse(r)}catch{e=null}}return e}},Z=(r,t)=>!De(r,t),Ut={attribute:true,type:String,converter:I,reflect:false,useDefault:false,hasChanged:Z};Symbol.metadata??=Symbol("metadata"),W.litPropertyMetadata??=new WeakMap;var w=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,e=Ut){if(e.state&&(e.attribute=false),this._$Ei(),this.prototype.hasOwnProperty(t)&&((e=Object.create(e)).wrapped=true),this.elementProperties.set(t,e),!e.noAccessor){let n=Symbol(),o=this.getPropertyDescriptor(t,n,e);o!==void 0&&Ge(this.prototype,t,o)}}static getPropertyDescriptor(t,e,n){let{get:o,set:s}=Ke(this.prototype,t)??{get(){return this[e]},set(i){this[e]=i}};return{get:o,set(i){let d=o?.call(this);s?.call(this,i),this.requestUpdate(t,d,n)},configurable:true,enumerable:true}}static getPropertyOptions(t){return this.elementProperties.get(t)??Ut}static _$Ei(){if(this.hasOwnProperty(N("elementProperties")))return;let t=He(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(N("finalized")))return;if(this.finalized=true,this._$Ei(),this.hasOwnProperty(N("properties"))){let e=this.properties,n=[...je(e),...ze(e)];for(let o of n)this.createProperty(o,e[o])}let t=this[Symbol.metadata];if(t!==null){let e=litPropertyMetadata.get(t);if(e!==void 0)for(let[n,o]of e)this.elementProperties.set(n,o)}this._$Eh=new Map;for(let[e,n]of this.elementProperties){let o=this._$Eu(e,n);o!==void 0&&this._$Eh.set(o,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){let e=[];if(Array.isArray(t)){let n=new Set(t.flat(1/0).reverse());for(let o of n)e.unshift(ht(o))}else t!==void 0&&e.push(ht(t));return e}static _$Eu(t,e){let n=e.attribute;return n===false?void 0:typeof n=="string"?n:typeof t=="string"?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=false,this.hasUpdated=false,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise(t=>this.enableUpdating=t),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach(t=>t(this))}addController(t){(this._$EO??=new Set).add(t),this.renderRoot!==void 0&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){let t=new Map,e=this.constructor.elementProperties;for(let n of e.keys())this.hasOwnProperty(n)&&(t.set(n,this[n]),delete this[n]);t.size>0&&(this._$Ep=t)}createRenderRoot(){let t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return Ft(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(true),this._$EO?.forEach(t=>t.hostConnected?.())}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach(t=>t.hostDisconnected?.())}attributeChangedCallback(t,e,n){this._$AK(t,n)}_$ET(t,e){let n=this.constructor.elementProperties.get(t),o=this.constructor._$Eu(t,n);if(o!==void 0&&n.reflect===true){let s=(n.converter?.toAttribute!==void 0?n.converter:I).toAttribute(e,n.type);this._$Em=t,s==null?this.removeAttribute(o):this.setAttribute(o,s),this._$Em=null}}_$AK(t,e){let n=this.constructor,o=n._$Eh.get(t);if(o!==void 0&&this._$Em!==o){let s=n.getPropertyOptions(o),i=typeof s.converter=="function"?{fromAttribute:s.converter}:s.converter?.fromAttribute!==void 0?s.converter:I;this._$Em=o;let d=i.fromAttribute(e,s.type);this[o]=d??this._$Ej?.get(o)??d,this._$Em=null}}requestUpdate(t,e,n,o=false,s){if(t!==void 0){let i=this.constructor;if(o===false&&(s=this[t]),n??=i.getPropertyOptions(t),!((n.hasChanged??Z)(s,e)||n.useDefault&&n.reflect&&s===this._$Ej?.get(t)&&!this.hasAttribute(i._$Eu(t,n))))return;this.C(t,e,n)}this.isUpdatePending===false&&(this._$ES=this._$EP())}C(t,e,{useDefault:n,reflect:o,wrapped:s},i){n&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,i??e??this[t]),s!==true||i!==void 0)||(this._$AL.has(t)||(this.hasUpdated||n||(e=void 0),this._$AL.set(t,e)),o===true&&this._$Em!==t&&(this._$Eq??=new Set).add(t))}async _$EP(){this.isUpdatePending=true;try{await this._$ES}catch(e){Promise.reject(e)}let t=this.scheduleUpdate();return t!=null&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(let[o,s]of this._$Ep)this[o]=s;this._$Ep=void 0}let n=this.constructor.elementProperties;if(n.size>0)for(let[o,s]of n){let{wrapped:i}=s,d=this[o];i!==true||this._$AL.has(o)||d===void 0||this.C(o,void 0,s,d)}}let t=false,e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach(n=>n.hostUpdate?.()),this.update(e)):this._$EM()}catch(n){throw t=false,this._$EM(),n}t&&this._$AE(e)}willUpdate(t){}_$AE(t){this._$EO?.forEach(e=>e.hostUpdated?.()),this.hasUpdated||(this.hasUpdated=true,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=new Map,this.isUpdatePending=false}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return true}update(t){this._$Eq&&=this._$Eq.forEach(e=>this._$ET(e,this[e])),this._$EM()}updated(t){}firstUpdated(t){}};w.elementStyles=[],w.shadowRootOptions={mode:"open"},w[N("elementProperties")]=new Map,w[N("finalized")]=new Map,qe?.({ReactiveElement:w}),(W.reactiveElementVersions??=[]).push("2.1.2");var bt=globalThis,Mt=r=>r,J=bt.trustedTypes,Nt=J?J.createPolicy("lit-html",{createHTML:r=>r}):void 0,zt="$lit$",E=`lit$${Math.random().toFixed(9).slice(2)}$`,Ht="?"+E,Ve=`<${Ht}>`,_=document,G=()=>_.createComment(""),K=r=>r===null||typeof r!="object"&&typeof r!="function",vt=Array.isArray,Ye=r=>vt(r)||typeof r?.[Symbol.iterator]=="function",ut=`[
|
|
2
2
|
\f\r]`,D=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,It=/-->/g,Dt=/>/g,A=RegExp(`>|${ut}(?:([^\\s"'>=/]+)(${ut}*=${ut}*(?:[^
|
|
3
|
-
\f\r"'\`<>=]|("|')|))|$)`,"g"),Gt=/'/g,Kt=/"/g,Bt=/^(?:script|style|textarea|title)$/i,St=r=>(t,...e)=>({_$litType$:r,strings:t,values:e}),c=St(1),Nn=St(2),In=St(3),P=Symbol.for("lit-noChange"),l=Symbol.for("lit-nothing"),jt=new WeakMap,R=_.createTreeWalker(_,129);function qt(r,t){if(!vt(r)||!r.hasOwnProperty("raw"))throw Error("invalid template strings array");return Nt!==void 0?Nt.createHTML(t):t}var We=(r,t)=>{let e=r.length-1,n=[],o,s=t===2?"<svg>":t===3?"<math>":"",i=D;for(let d=0;d<e;d++){let a=r[d],p,h,m=-1,f=0;for(;f<a.length&&(i.lastIndex=f,h=i.exec(a),h!==null);)f=i.lastIndex,i===D?h[1]==="!--"?i=It:h[1]!==void 0?i=Dt:h[2]!==void 0?(Bt.test(h[2])&&(o=RegExp("</"+h[2],"g")),i=A):h[3]!==void 0&&(i=A):i===A?h[0]===">"?(i=o??D,m=-1):h[1]===void 0?m=-2:(m=i.lastIndex-h[2].length,p=h[1],i=h[3]===void 0?A:h[3]==='"'?Kt:Gt):i===Kt||i===Gt?i=A:i===It||i===Dt?i=D:(i=A,o=void 0);let b=i===A&&r[d+1].startsWith("/>")?" ":"";s+=i===D?a+Ve:m>=0?(n.push(p),a.slice(0,m)+zt+a.slice(m)+E+b):a+E+(m===-2?d:b)}return[qt(r,s+(r[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),n]},j=class r{constructor({strings:t,_$litType$:e},n){let o;this.parts=[];let s=0,i=0,d=t.length-1,a=this.parts,[p,h]=We(t,e);if(this.el=r.createElement(p,n),R.currentNode=this.el.content,e===2||e===3){let m=this.el.content.firstChild;m.replaceWith(...m.childNodes)}for(;(o=R.nextNode())!==null&&a.length<d;){if(o.nodeType===1){if(o.hasAttributes())for(let m of o.getAttributeNames())if(m.endsWith(zt)){let f=h[i++],b=o.getAttribute(m).split(E),k=/([.?@])?(.*)/.exec(f);a.push({type:1,index:s,name:k[2],strings:b,ctor:k[1]==="."?mt:k[1]==="?"?yt:k[1]==="@"?ft:O}),o.removeAttribute(m)}else m.startsWith(E)&&(a.push({type:6,index:s}),o.removeAttribute(m));if(Bt.test(o.tagName)){let m=o.textContent.split(E),f=m.length-1;if(f>0){o.textContent=J?J.emptyScript:"";for(let b=0;b<f;b++)o.append(m[b],G()),R.nextNode(),a.push({type:2,index:++s});o.append(m[f],G())}}}else if(o.nodeType===8)if(o.data===Ht)a.push({type:2,index:s});else{let m=-1;for(;(m=o.data.indexOf(E,m+1))!==-1;)a.push({type:7,index:s}),m+=E.length-1}s++}}static createElement(t,e){let n=_.createElement("template");return n.innerHTML=t,n}};function F(r,t,e=r,n){if(t===P)return t;let o=n!==void 0?e._$Co?.[n]:e._$Cl,s=K(t)?void 0:t._$litDirective$;return o?.constructor!==s&&(o?._$AO?.(false),s===void 0?o=void 0:(o=new s(r),o._$AT(r,e,n)),n!==void 0?(e._$Co??=[])[n]=o:e._$Cl=o),o!==void 0&&(t=F(r,o._$AS(r,t.values),o,n)),t}var gt=class{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){let{el:{content:e},parts:n}=this._$AD,o=(t?.creationScope??_).importNode(e,true);R.currentNode=o;let s=R.nextNode(),i=0,d=0,a=n[0];for(;a!==void 0;){if(i===a.index){let p;a.type===2?p=new z(s,s.nextSibling,this,t):a.type===1?p=new a.ctor(s,a.name,a.strings,this,t):a.type===6&&(p=new xt(s,this,t)),this._$AV.push(p),a=n[++d]}i!==a?.index&&(s=R.nextNode(),i++)}return R.currentNode=_,o}p(t){let e=0;for(let n of this._$AV)n!==void 0&&(n.strings!==void 0?(n._$AI(t,n,e),e+=n.strings.length-2):n._$AI(t[e])),e++}},z=class r{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,n,o){this.type=2,this._$AH=l,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=n,this.options=o,this._$Cv=o?.isConnected??true}get parentNode(){let t=this._$AA.parentNode,e=this._$AM;return e!==void 0&&t?.nodeType===11&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=F(this,t,e),K(t)?t===l||t==null||t===""?(this._$AH!==l&&this._$AR(),this._$AH=l):t!==this._$AH&&t!==P&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):Ye(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==l&&K(this._$AH)?this._$AA.nextSibling.data=t:this.T(_.createTextNode(t)),this._$AH=t}$(t){let{values:e,_$litType$:n}=t,o=typeof n=="number"?this._$AC(t):(n.el===void 0&&(n.el=j.createElement(qt(n.h,n.h[0]),this.options)),n);if(this._$AH?._$AD===o)this._$AH.p(e);else{let s=new gt(o,this),i=s.u(this.options);s.p(e),this.T(i),this._$AH=s}}_$AC(t){let e=jt.get(t.strings);return e===void 0&&jt.set(t.strings,e=new j(t)),e}k(t){vt(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,n,o=0;for(let s of t)o===e.length?e.push(n=new r(this.O(G()),this.O(G()),this,this.options)):n=e[o],n._$AI(s),o++;o<e.length&&(this._$AR(n&&n._$AB.nextSibling,o),e.length=o)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(false,true,e);t!==this._$AB;){let n=Mt(t).nextSibling;Mt(t).remove(),t=n}}setConnected(t){this._$AM===void 0&&(this._$Cv=t,this._$AP?.(t))}},O=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,n,o,s){this.type=1,this._$AH=l,this._$AN=void 0,this.element=t,this.name=e,this._$AM=o,this.options=s,n.length>2||n[0]!==""||n[1]!==""?(this._$AH=Array(n.length-1).fill(new String),this.strings=n):this._$AH=l}_$AI(t,e=this,n,o){let s=this.strings,i=false;if(s===void 0)t=F(this,t,e,0),i=!K(t)||t!==this._$AH&&t!==P,i&&(this._$AH=t);else{let d=t,a,p;for(t=s[0],a=0;a<s.length-1;a++)p=F(this,d[n+a],e,a),p===P&&(p=this._$AH[a]),i||=!K(p)||p!==this._$AH[a],p===l?t=l:t!==l&&(t+=(p??"")+s[a+1]),this._$AH[a]=p}i&&!o&&this.j(t)}j(t){t===l?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},mt=class extends O{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===l?void 0:t}},yt=class extends O{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==l)}},ft=class extends O{constructor(t,e,n,o,s){super(t,e,n,o,s),this.type=5}_$AI(t,e=this){if((t=F(this,t,e,0)??l)===P)return;let n=this._$AH,o=t===l&&n!==l||t.capture!==n.capture||t.once!==n.once||t.passive!==n.passive,s=t!==l&&(n===l||o);o&&this.element.removeEventListener(this.name,this,n),s&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){typeof this._$AH=="function"?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}},xt=class{constructor(t,e,n){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=n}get _$AU(){return this._$AM._$AU}_$AI(t){F(this,t)}};var Ze=bt.litHtmlPolyfillSupport;Ze?.(j,z),(bt.litHtmlVersions??=[]).push("3.3.3");var Vt=(r,t,e)=>{let n=e?.renderBefore??t,o=n._$litPart$;if(o===void 0){let s=e?.renderBefore??null;n._$litPart$=o=new z(t.insertBefore(G(),s),s,void 0,e??{})}return o._$AI(r),o};var wt=globalThis,$=class extends w{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){let t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){let e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=Vt(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(true)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(false)}render(){return P}};$._$litElement$=true,$.finalized=true,wt.litElementHydrateSupport?.({LitElement:$});var Je=wt.litElementPolyfillSupport;Je?.({LitElement:$});(wt.litElementVersions??=[]).push("4.2.2");var Xe={attribute:true,type:String,converter:I,reflect:false,hasChanged:Z},Qe=(r=Xe,t,e)=>{let{kind:n,metadata:o}=e,s=globalThis.litPropertyMetadata.get(o);if(s===void 0&&globalThis.litPropertyMetadata.set(o,s=new Map),n==="setter"&&((r=Object.create(r)).wrapped=true),s.set(e.name,r),n==="accessor"){let{name:i}=e;return{set(d){let a=t.get.call(this);t.set.call(this,d),this.requestUpdate(i,a,r,true,d)},init(d){return d!==void 0&&this.C(i,void 0,r,d),d}}}if(n==="setter"){let{name:i}=e;return function(d){let a=this[i];t.call(this,d),this.requestUpdate(i,a,r,true,d)}}throw Error("Unsupported decorator location: "+n)};function y(r){return(t,e)=>typeof e=="object"?Qe(r,t,e):((n,o,s)=>{let i=o.hasOwnProperty(s);return o.constructor.createProperty(s,n),i?Object.getOwnPropertyDescriptor(o,s):void 0})(r,t,e)}function S(r){return y({...r,state:true,attribute:false})}var Yt=[{endpoint:"astrology/planets/monthly",method:"POST"},{endpoint:"vedic-astrology/planetary-positions/monthly",method:"POST"}];function Q(r){return r.toLowerCase().replace(/[\s_-]+/g," ").trim()}var Wt=(r,t)=>t?r[Q(t)]:void 0,tn={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",midheaven:"MC","part of fortune":"\u2297",vertex:"Vx",lagna:"La","north node":"\u260A","south node":"\u260B",chiron:"\u26B7",lilith:"\u26B8","black moon lilith":"\u26B8"},Et=r=>Wt(tn,r);var en={aries:"\u2648",taurus:"\u2649",gemini:"\u264A",cancer:"\u264B",leo:"\u264C",virgo:"\u264D",libra:"\u264E",scorpio:"\u264F",sagittarius:"\u2650",capricorn:"\u2651",aquarius:"\u2652",pisces:"\u2653"},tt=r=>Wt(en,r);var Zt=["Aries","Taurus","Gemini","Cancer","Leo","Virgo","Libra","Scorpio","Sagittarius","Capricorn","Aquarius","Pisces"];var C=r=>r??l;var Jt=["de","en","es","fr","hi","pt","ru","tr","zh-Hans","zh-Hant"];function Tt(r){if(r.lang)return r.lang;if(typeof document>"u")return;let t=r.closest?.("[lang]")?.getAttribute("lang");return t||document.documentElement.lang||void 0}var nn={tw:"hant",hk:"hant",mo:"hant",cn:"hans",sg:"hans",my:"hans"};function $t(r,t){let e=r.toLowerCase();return t.find(n=>n.toLowerCase()===e)}function Xt(r,t=Jt){let e=Tt(r);if(!e)return;let n=$t(e,t);if(n)return n;let o=e.toLowerCase().split("-"),s=o[0];if(s==="zh"){let i=o.find(d=>d==="hans"||d==="hant")??nn[o[1]??""];return i?$t(`zh-${i}`,t):void 0}return $t(s,t)}var rn={Fraunces:["latin","latin-ext"],Jost:["latin","latin-ext","cyrillic"],Geist:["latin","latin-ext","cyrillic"]},kt='"Jost", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',Qt='"Geist", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',te='system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif',et={"fraunces-jost":{name:"Fraunces with Jost",sans:kt,display:'"Fraunces", ui-serif, Georgia, Cambria, "Times New Roman", Times, serif'},jost:{name:"Jost",sans:kt,display:kt},geist:{name:"Geist",sans:Qt,display:Qt},system:{name:"System",sans:te,display:te}};function ee(r){let{sans:t,display:e}=et[r];return Object.keys(rn).filter(n=>`${t} ${e}`.includes(`"${n}"`))}var ne="1.2.0";var on=/^(.*)\/cdn\/(?:roxy-ui|components\/[\w-]+)\.js$/,sn=/^(.*\/dist)\/(?:index|components\/[\w-]+)\.js$/;function re(r,t){if(!t)return;let e=new URL(t);if(e.protocol!=="https:"&&e.protocol!=="http:")return;let n=(on.exec(e.pathname)??sn.exec(e.pathname))?.[1];if(n!==void 0)return e.hostname==="cdn.jsdelivr.net"?`https://cdn.jsdelivr.net/npm/@roxyapi/ui@${r}/dist`:`${e.origin}${n}`}var pn={},an="color-mix(in oklab, var(--roxy-accent) 70%, black)",dn="var(--roxy-accent)",cn="color-mix(in srgb, var(--roxy-accent) 40%, transparent)",oe=/^#(?:[\da-f]{3}|[\da-f]{6})$/i;function se(r){return r!==void 0&&Object.hasOwn(et,r)}function ie(r){let t=[];return r.brandColor&&oe.test(r.brandColor)&&t.push(`--roxy-primary:${r.brandColor}`),r.brandAccent&&oe.test(r.brandAccent)&&t.push(`--roxy-accent:${r.brandAccent}`,`--roxy-accent-ink:light-dark(${an},${dn})`,`--roxy-ring:${cn}`),t.join(";")}function ae(r,t){if(se(t))return t;let e=r.getRootNode();if(("host"in e?e.host:null)?.localName.startsWith("roxy-")||!globalThis.getComputedStyle)return;let o=r.shadowRoot?.firstElementChild,s=o?.localName==="style"?o:null;s?.sheet&&(s.sheet.disabled=true);let i,d,a;try{let p=globalThis.getComputedStyle(r),h=m=>p.getPropertyValue(m).trim();i=h("--roxy-font-sans"),d=h("--roxy-font-display"),a=h("--roxy-font")}finally{s?.sheet&&(s.sheet.disabled=false)}if(!(i||d))return se(a)?a:void 0}function de(r){let{sans:t,display:e}=et[r];return`--roxy-font:${r};--roxy-font-sans:${t};--roxy-font-display:${e}`}var ln=re(ne,globalThis.document?.currentScript?.src||pn.url);function ce(r,t=ln){if(typeof document>"u"||t===void 0)return;let e=`roxy-ui-font-${r}`;if(ee(r).length===0||document.getElementById(e))return;let n=document.createElement("link");n.id=e,n.rel="stylesheet",n.href=`${t}/styles/fonts/${r}.css`,document.head.append(n)}var le='@layer roxy.tokens,roxy.theme;@layer roxy.tokens{:where(:root,:host){color-scheme:light;--roxy-bg: #ffffff;--roxy-fg: #0a0a0a;--roxy-accent: #4a6297;--roxy-success: #16a34a;--roxy-warning: #ea580c;--roxy-danger: #dc2626;--roxy-info: #0284c7;--roxy-accent-ink: color-mix(in oklab, var(--roxy-accent) 70%, black);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, black);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, black);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, black);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, black);--roxy-font: initial;--roxy-font-sans: initial;--roxy-font-mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, "Liberation Mono", monospace;--roxy-text-base: 1rem;--roxy-text-scale: 1.15;--roxy-weight-normal: 400;--roxy-weight-bold: 600;--roxy-leading-tight: 1.25;--roxy-leading-normal: 1.5;--roxy-tracking-tight: -0.01em;--roxy-tracking-normal: 0em;--roxy-space-unit: 0.25rem;--roxy-radius: 6px;--roxy-motion-duration: 200ms;--roxy-motion-easing: cubic-bezier(0.4, 0, 0.2, 1)}:where(:root,:host,[data-theme],.light,.dark){--roxy-surface: var(--roxy-bg);--roxy-primary: var(--roxy-fg);--roxy-secondary: color-mix(in oklab, var(--roxy-fg) 78%, var(--roxy-bg));--roxy-muted: color-mix(in oklab, var(--roxy-fg) 60%, var(--roxy-bg));--roxy-border: color-mix(in oklab, var(--roxy-fg) 14%, var(--roxy-bg));--roxy-ring: color-mix(in srgb, var(--roxy-accent) 40%, transparent);--roxy-heat: var(--roxy-danger);--roxy-font-display: var(--roxy-font-sans);--roxy-text-sm: calc(var(--roxy-text-base) / var(--roxy-text-scale));--roxy-text-xs: calc(var(--roxy-text-sm) / var(--roxy-text-scale));--roxy-text-lg: calc(var(--roxy-text-base) * var(--roxy-text-scale));--roxy-text-xl: calc( var(--roxy-text-lg) * var(--roxy-text-scale) * var(--roxy-text-scale) );--roxy-space-xs: var(--roxy-space-unit);--roxy-space-sm: calc(var(--roxy-space-unit) * 2);--roxy-space-md: calc(var(--roxy-space-unit) * 4);--roxy-space-lg: calc(var(--roxy-space-unit) * 6);--roxy-space-xl: calc(var(--roxy-space-unit) * 10);--roxy-line-thick: calc(var(--roxy-space-unit) / 2);--roxy-touch: calc(var(--roxy-space-unit) * 11);--roxy-radius-sm: calc(var(--roxy-radius) / 2);--roxy-radius-md: var(--roxy-radius);--roxy-radius-lg: calc(var(--roxy-radius) * 5 / 3);--roxy-radius-full: 9999px;--roxy-shadow-sm: none;--roxy-shadow-md: 0 4px 12px color-mix(in srgb, black 10%, transparent);--roxy-shadow-lg: 0 12px 32px color-mix(in srgb, black 18%, transparent)}@media(prefers-color-scheme:dark){:where(:root,:host){color-scheme:dark;--roxy-bg: #0a0a0a;--roxy-fg: #fafafa;--roxy-accent: #92aade;--roxy-success: #22c55e;--roxy-warning: #fb923c;--roxy-danger: #ef4444;--roxy-info: #38bdf8;--roxy-accent-ink: var(--roxy-accent);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, white);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, white);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, white);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, white)}}:where(:root[data-theme=light],[data-theme=light],:root.light,.light,:host([data-theme="light"])){color-scheme:light;--roxy-bg: #ffffff;--roxy-fg: #0a0a0a;--roxy-accent: #4a6297;--roxy-success: #16a34a;--roxy-warning: #ea580c;--roxy-danger: #dc2626;--roxy-info: #0284c7;--roxy-accent-ink: color-mix(in oklab, var(--roxy-accent) 70%, black);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, black);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, black);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, black);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, black)}:where(:root[data-theme=dark],[data-theme=dark],:root.dark,.dark,:host([data-theme="dark"])){color-scheme:dark;--roxy-bg: #0a0a0a;--roxy-fg: #fafafa;--roxy-accent: #92aade;--roxy-success: #22c55e;--roxy-warning: #fb923c;--roxy-danger: #ef4444;--roxy-info: #38bdf8;--roxy-accent-ink: var(--roxy-accent);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, white);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, white);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, white);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, white)}@media(prefers-reduced-motion:reduce){:where(:root,:host){--roxy-motion-duration: 0ms}}}';var nt="roxy-ui-tokens";function rt(){if(typeof document>"u")return null;let r=document.getElementById(nt);if(r)return r;let t=document.createElement("style");return t.id=nt,t.textContent=le,document.head.prepend(t),t}var pe="__ROXY_UI_I18N__";function he(){let r=globalThis,t=r[pe];if(t)return t;let e={catalogs:{},fieldLabels:{},requested:new Set,listeners:new Set};return r[pe]=e,e}function hn(r,t){return t?r.replace(/\{\{(\w+)\}\}/g,(e,n)=>n in t?String(t[n]??""):e):r}function ue(r,t,e){return hn(un(r,t)??t,e)}function un(r,t){if(!r)return;let{catalogs:e}=he(),n=r.toLowerCase();return(e[n]??e[n.split("-")[0]])?.[Q(t)]}function ge(r){let{listeners:t}=he();return t.add(r),()=>{t.delete(r)}}var ot=class{constructor(t){this.host=t,t.addController(this)}hostConnected(){this.unsubscribe=ge(()=>this.host.requestUpdate())}hostDisconnected(){this.unsubscribe?.(),this.unsubscribe=void 0}};var st=class extends ${constructor(){super();this.translator=(e,n)=>this.t(e,n);new ot(this)}connectedCallback(){super.connectedCallback(),rt()}fontDeclarations(e){let n=ae(this,e);return n?(ce(n),de(n)):""}renderFontStyle(){let e=this.fontDeclarations();return e?c`<style>:host{${e}}</style>`:l}t(e,n){return ue(this.effectiveLang(),e,n)}effectiveLang(){return Tt(this)}};var me=v`:where([part~=card]){background:var(--roxy-surface);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);box-shadow:var(--roxy-shadow-sm)}:where([part~=card] [part~=card],[part~=card] [part~=reading],[part~=card] .roxy-card){border:0;border-block-start:1px solid var(--roxy-border);box-shadow:none;background:0 0;border-radius:0;padding-inline:0}:host([bare]) [part~=card]{box-shadow:none;background:0 0;border:0;border-radius:0;padding:0}:where(h1,h2){color:var(--roxy-fg);font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);letter-spacing:var(--roxy-tracking-tight);text-wrap:balance}:where(h3,h4,h5,h6){color:var(--roxy-fg);font-size:var(--roxy-text-base);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);letter-spacing:var(--roxy-tracking-normal);text-transform:none}:where(.roxy-label,th,dt){color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-normal);letter-spacing:var(--roxy-tracking-normal);text-transform:none}:where(.roxy-chips){gap:var(--roxy-space-xs);flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}:where(.roxy-chip,.roxy-chips>li){align-items:center;gap:var(--roxy-space-xs);padding:calc(var(--roxy-space-unit) / 2) var(--roxy-space-sm);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-sm);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);line-height:var(--roxy-leading-tight);overflow-wrap:anywhere;background:0 0;max-inline-size:100%;display:inline-flex}:where(.roxy-chip[data-tone=success],.roxy-chips>li[data-tone=success]){color:var(--roxy-success-fg)}:where(.roxy-chip[data-tone=warning],.roxy-chips>li[data-tone=warning]){color:var(--roxy-warning-fg)}:where(.roxy-chip[data-tone=danger],.roxy-chips>li[data-tone=danger]){color:var(--roxy-danger-fg)}:where(.roxy-chip[data-tone=info],.roxy-chips>li[data-tone=info]){color:var(--roxy-info-fg)}:where(table){border-collapse:collapse;font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}:where(th,td){padding:var(--roxy-space-xs) var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);text-align:start;vertical-align:top}:where(summary){cursor:pointer}:where(a,button,summary,input,select,textarea,[tabindex]):focus-visible{outline:var(--roxy-line-thick) solid var(--roxy-ring);outline-offset:var(--roxy-line-thick)}:where(summary:focus-visible){border-radius:var(--roxy-radius-sm)}:where(input,select,textarea,button){font:inherit}:where(input:not([type=checkbox],[type=radio],[type=range]),select,textarea){padding:var(--roxy-space-xs) var(--roxy-space-sm);background:var(--roxy-bg);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md)}`;var gn=v`:host{--roxy-label-col:minmax(0, 25%);--_mask:var(--roxy-surface);font-family:var(--roxy-font-sans);color:var(--roxy-fg);font-size:var(--roxy-text-base);line-height:var(--roxy-leading-normal);animation:roxy-fade-in var(--roxy-motion-duration) var(--roxy-motion-easing) both;background:0 0;display:block;container-type:inline-size}:host([bare]){--_mask:var(--roxy-bg)}:host([hidden]){display:none}: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)}@keyframes roxy-fade-in{0%{transform:translateY(calc(var(--roxy-space-unit) / 2))}to{transform:translateY(0)}}@media (prefers-reduced-motion:reduce){:host{animation:none}}.roxy-skeleton{background:linear-gradient(90deg, var(--roxy-border) 0%, color-mix(in srgb, var(--roxy-border) 60%, transparent) 50%, var(--roxy-border) 100%);border-radius:var(--roxy-radius-md);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);color:var(--roxy-muted);text-align:center;font-size:var(--roxy-text-sm)}.roxy-error{gap:var(--roxy-space-sm);padding:var(--roxy-space-lg);background:var(--roxy-surface);border:1px solid var(--roxy-danger);border-radius:var(--roxy-radius-md);color:var(--roxy-danger-fg);font-size:var(--roxy-text-sm);justify-items:start;display:grid}:host(:focus-within) .roxy-card{outline:var(--roxy-line-thick) solid var(--roxy-ring);outline-offset:var(--roxy-line-thick)}.roxy-attribution{margin-top:var(--roxy-space-sm);font-size:var(--roxy-text-xs);color:var(--roxy-muted);text-align:right}.roxy-attribution a{color:inherit;text-decoration:none}.roxy-attribution a:hover{color:var(--roxy-accent-ink);text-decoration:underline}.roxy-edit-bar{margin-bottom:var(--roxy-space-sm);justify-content:flex-end;display:flex}.roxy-edit{padding:var(--roxy-space-xs) var(--roxy-space-md);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);color:var(--roxy-fg);font-family:inherit;font-size:var(--roxy-text-sm);cursor:pointer;background:0 0}.roxy-edit:hover{border-color:var(--roxy-accent);color:var(--roxy-accent-ink)}.roxy-edit:disabled{cursor:progress;color:var(--roxy-muted)}roxy-endpoint-form+*{margin-top:var(--roxy-space-md)}.roxy-more{justify-items:center;gap:var(--roxy-space-sm);margin-top:var(--roxy-space-md);display:grid}.roxy-more .roxy-edit{min-height:var(--roxy-touch)}:host{font-variant-emoji:text}`,it=[gn,me];var mn="__cols",yn="__rows";function fn(r){return typeof r=="object"&&r!==null&&!Array.isArray(r)}function at(r){if(Array.isArray(r)){let s=false,i=r.map(d=>{let a=at(d);return a!==d&&(s=true),a});return s?i:r}if(!fn(r))return r;let t=r[mn],e=r[yn];if(Array.isArray(t)&&Array.isArray(e)&&Object.keys(r).length===2)return e.map(s=>{let i={};return t.forEach((d,a)=>{i[d]=at(s[a])}),i});let n=false,o={};for(let[s,i]of Object.entries(r)){let d=at(i);d!==i&&(n=true),o[s]=d}return n?o:r}function ye(r){return at(r)}function fe(r,t){return r.find(e=>e.attrs&&Object.entries(e.attrs).every(([n,o])=>t[n]===o))??r[0]}var xn="pk_live_YOUR_KEY",xe={secret:{reason:"possible-secret-key",message:"Client-side components accept a pk_ publishable key only. Use a publishable key with an origin allowlist, or render server-side."},sample:{reason:"sample-key",message:"Replace the sample key with your own publishable key from your RoxyAPI account."}};function be(r){if(r)return r===xn?xe.sample:r.startsWith("pk_")?void 0:xe.secret}function ve(r,t,e={}){e.warn&&console.warn(t.message),r.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{reason:t.reason,message:t.message},bubbles:true,composed:true}))}var Se="https://roxyapi.com/api/v2";async function bn(r){try{let t=await r.json();if(t?.error){let e=t.code==="validation_error"&&Array.isArray(t.issues)?t.issues.filter(n=>typeof n.path=="string"&&typeof n.message=="string").map(n=>({path:n.path,message:n.message})):null;return{message:t.error,issues:e?.length?e:null,worded:true,...t.code?{code:t.code}:{}}}}catch{}return{message:`Request failed (${r.status})`,issues:null,worded:false}}var we={fromAttribute:r=>{if(r!=null){try{let t=JSON.parse(r);if(t&&typeof t=="object"&&!Array.isArray(t))return t}catch{}console.warn("[roxy-ui] submit-context must be a JSON object; sending the request without it.")}}},L=class extends Error{constructor(e,n=null,o=true,s,i){super(e);this.issues=n;this.worded=o;this.status=s;this.code=i}};function Ee(r){return r.submitUrl?void 0:be(r.publishableKey)}async function At(r,t,e){let n=Ee(r);if(n)throw new L(n.message);let o=r.submitUrl?await fetch(r.submitUrl,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:vn(t,r.submitContext),signal:e}):await Sn(r,t,e);if(!o.ok){let s=await bn(o);throw new L(s.message,s.issues,s.worded,o.status,s.code)}return await o.json()}function vn(r,t){return JSON.stringify(t?{...r,context:t}:r)}function Sn(r,t,e){let n=new URL(`${r.baseUrl??Se}${t.path}`,document.baseURI);for(let[s,i]of Object.entries(t.query??{}))i!=null&&n.searchParams.set(s,String(i));let o={Accept:"application/json"};return r.publishableKey&&(o["X-API-Key"]=r.publishableKey),t.body!=null&&(o["Content-Type"]="application/json"),fetch(n,{method:t.method??"GET",headers:o,body:t.body!=null?JSON.stringify(t.body):void 0,signal:e})}var dt=class{constructor(t){this.baseUrl=Se;this.worded=true;this.failure={};this.host=t,t.addController(this)}hostDisconnected(){this.abort?.abort(),this.abort=void 0}async run(t){this.worded=true,this.failure={};let e=Ee(this);if(e){this.host.error=e.message,ve(this.host,e);return}this.abort?.abort();let n=new AbortController;this.abort=n,this.host.loading=true,this.host.error=null,this.host.issues=null;try{let o=await At(this,t,n.signal);if(n.signal.aborted)return;this.host.data=o}catch(o){if(n.signal.aborted||o?.name==="AbortError")return;o instanceof L&&(this.host.issues=o.issues,this.failure={status:o.status,code:o.code}),this.worded=o instanceof L&&o.worded,this.host.error=o instanceof Error?o.message:String(o)}finally{this.abort===n&&(this.abort=void 0),n.signal.aborted||(this.host.loading=false)}}};function $e(r,t,e,n=[]){let o={...e},s=`/${r.replace(/^\//,"")}`.replace(/\{([^}]+)\}/g,(p,h)=>{let m=o[h];return delete o[h],encodeURIComponent(String(m??""))}),i=new Set(n),d={},a={};for(let[p,h]of Object.entries(o))h===void 0||h===""||(t==="GET"||i.has(p)?d[p]=h:a[p]=h);return{path:s,method:t,query:d,body:t==="POST"?a:void 0}}function Te(){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 go=v`summary{list-style:none}summary::-webkit-details-marker{display:none}.roxy-chevron{aspect-ratio:auto;width:.7lh;height:.7lh;color:var(--roxy-muted);transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing);flex-shrink:0}details[open]>summary .roxy-chevron{transform:rotate(180deg)}@media (prefers-reduced-motion:reduce){.roxy-chevron{transition:none}}`;var xo=v`.block{border-top:1px solid var(--roxy-border);padding-top:var(--roxy-space-md)}.block h3{margin:0 0 var(--roxy-space-sm)}.interp-card{padding-block:var(--roxy-space-sm)}.interp-card summary{font-weight:var(--roxy-weight-bold);color:var(--roxy-fg);align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);display:flex}.interp-lead{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;flex:auto;order:1;min-width:0;display:inline-flex}.interp-aside{align-items:center;gap:var(--roxy-space-sm);flex-shrink:0;order:2;display:inline-flex}.roxy-chevron{order:3}.interp-aside small{color:var(--roxy-muted);font-weight:var(--roxy-weight-normal);white-space:nowrap}@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);gap:var(--roxy-space-sm);color:var(--roxy-fg);font-size:var(--roxy-text-sm);line-height:var(--roxy-leading-normal);overflow-wrap:anywhere;display:grid}.interp-body p{margin:0}`;function ke(r,t,e){let n=r.filter(o=>!!o.body);return n.length===0?l:c`<section class="block" part="section readings"><h3>${e}</h3>${n.map((o,s)=>c`<details class="interp-card" part="reading" name="${t}" ?open="${s===0}"><summary><span class="interp-lead">${o.label}</span> ${Te()} ${o.aside?c`<span class="interp-aside"><small>${o.aside}</small></span>`:l}</summary><div class="interp-body"><p>${o.body}</p>${o.extra??l}</div></details>`)}</section>`}var wn="roxy-data";function En(r){return r.nodeName==="SCRIPT"&&r.getAttribute("type")==="application/json"}var ct=class{constructor(t){this.host=t,t.addController(this)}hostConnected(){if(this.host.data!=null)return;let t=this.read();t!==void 0&&(this.host.data=t,this.host.requestUpdate())}read(){let t=this.findInlineScript();return t?this.parse(t.textContent):void 0}findInlineScript(){for(let t of Array.from(this.host.children))if(En(t)&&t.classList.contains(wn))return t;return null}parse(t){if(t?.trim())try{return JSON.parse(t)}catch{return}}};var g=class extends st{constructor(){super();this.data=null;this.endpoint="";this.remember=false;this.hideReadings=false;this.hideSections="";this.loading=false;this.error=null;this.issues=null;this.selfFetched=false;this.editing=false;this.sticky=false;this.hostLoaded=false;this.moreLoading=false;this.moreError=null;this.onMore=async()=>{let e=this.lastRequest,n=this.listKey,o=this.listRows();if(!(!e||!n||!o)){this.moreLoading=true,this.moreError=null;try{let s=await At(this.fetcher,{...e,query:{...e.query,offset:o.length}});if(this.lastRequest!==e)return;let i=s[n];this.data={...this.data,...s,[n]:[...o,...Array.isArray(i)?i:[]]}}catch(s){this.lastRequest===e&&(this.moreError=s instanceof Error?s.message:String(s))}finally{this.moreLoading=false}}};this.onEdit=()=>{this.editing=true};this.onFormSubmit=e=>{let n=this.selfFetch();if(!n)return;let o=e.detail;this.lastValues=o.values,this.sticky=!!o.sticky,this.selfFetched=true,this.editing=false,this.remember&&this.writeRemembered(o.values),this.fetchFresh($e(n.endpoint,n.method,{...o.values,...this.ownRequest()},o.queryKeys??[]))};new ct(this),this.fetcher=new dt(this)}static{this.styles=[it]}static{this.endpoints=[]}willUpdate(e){if(e.has("data")&&this.data!=null){let n=ye(this.data);n!==this.data&&(this.data=n)}(e.has("publishableKey")||e.has("baseUrl")||e.has("submitUrl")||e.has("submitContext"))&&this.syncFetcher()}syncFetcher(){this.fetcher.publishableKey=this.publishableKey,this.baseUrl&&(this.fetcher.baseUrl=this.baseUrl),this.fetcher.submitUrl=this.submitUrl,this.fetcher.submitContext=this.submitContext}selfFetch(){let e=this.endpoint?{endpoint:this.endpoint,method:"POST"}:this.hostLoaded||!(this.publishableKey||this.submitUrl)?void 0:fe(this.constructor.endpoints,this);return e&&{endpoint:e.endpoint,method:this.method??e.method}}render(){return c`${this.hostStyle()}${this.renderState()}`}drawn(e){try{return this.renderData(e)}catch(n){return console.warn(`[roxy-ui] ${this.localName} could not draw its response`,n),this.dispatchEvent(new CustomEvent("roxy-render-error",{detail:{error:n},bubbles:true,composed:true})),customElements.get("roxy-data")?c`<roxy-data .data="${e}" lang="${C(this.effectiveLang())}"></roxy-data>`:this.renderEmpty()}}hostStyle(){let e=this.hideSections.split(",").map(s=>s.trim().toLowerCase()).filter(s=>/^[a-z][a-z0-9-]*$/.test(s)),n=[ie(this),this.fontDeclarations(this.font)].filter(Boolean).join(";");if(e.length===0&&!n)return l;let o=(n?`:host{${n}}`:"")+e.map(s=>`[part~="${s}"],roxy-endpoint-form::part(${s}){display:none!important}`).join("");return c`<style>${o}</style>`}ownRequest(){return{}}get failure(){return this.fetcher.failure}renderState(){return this.selfFetch()&&this.sticky&&this.selfFetched&&!this.editing?this.renderWithForm(this.stickyBody()):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.drawn(this.data)}${this.renderAttribution()}`:this.drawn(this.data):this.renderNoData()}renderInterpretation(e,n,o){return this.hideReadings?l:ke(e,n,this.t(o??"Reading"))}renderResult(e){let n=c`<div class="roxy-edit-bar" part="edit-bar"><button type="button" class="roxy-edit" @click="${this.onEdit}">${this.t("Edit query")}</button></div>${this.drawn(e)}`;return this.showAttribution()?c`${n}${this.renderAttribution()}`:n}renderWithForm(e){return c`${this.renderForm()}${e}`}stickyBody(){return this.loading?this.renderLoading():this.error!=null?this.issues?l:this.renderErrorBanner(this.error):this.data==null?l:this.showAttribution()?c`${this.drawn(this.data)}${this.renderAttribution()}`:this.drawn(this.data)}renderMore(){let e=this.listRows(),n=this.data?.total;return!this.lastRequest||!e||typeof n!="number"?l:e.length>=n?l:c`<div class="roxy-more" part="more"><button type="button" class="roxy-edit" ?disabled="${this.moreLoading}" aria-busy="${this.moreLoading?"true":"false"}" @click="${this.onMore}">${this.t("Show more")}</button> ${this.moreError?c`<p class="roxy-error" role="alert">${this.t(this.moreError)}</p>`:l}</div>`}listRows(){let e=this.listKey?this.data?.[this.listKey]:void 0;return Array.isArray(e)?e:void 0}fetchFresh(e){return this.lastRequest=e,this.openedRow=void 0,this.openedRowId=void 0,this.moreError=null,this.fetcher.run(e)}load(e){return this.hostLoaded=true,this.syncFetcher(),this.fetchFresh(e)}pickRow(e){this.dispatchEvent(new CustomEvent("roxy-symbol-select",{detail:e,bubbles:true,composed:true})),this.openRow(e.id)}openRow(e){if(!this.rowDetail||!(this.publishableKey||this.submitUrl))return;let n=this.openedRow??document.createElement(this.rowDetail.tag);n.publishableKey=this.publishableKey,n.baseUrl=this.baseUrl,n.submitUrl=this.submitUrl,n.submitContext=this.submitContext,n.hideReadings=this.hideReadings,n.hideSections=this.hideSections;let o=this.effectiveLang();o&&n.setAttribute("lang",o),this.openedRow=n,this.openedRowId=e,n.load({path:`/${this.rowDetail.path.replace("{id}",encodeURIComponent(e))}`,method:"GET",query:{lang:Xt(this)}}).then(()=>n.scrollIntoView?.({block:"nearest"}))}showAttribution(){return this.attribution!=null&&this.attribution!=="off"&&this.attribution!=="false"}renderAttribution(){return c`<div class="roxy-attribution" part="attribution"><a href="https://roxyapi.com/?utm_source=widget&utm_medium=embed" target="_blank" rel="noopener">${this.t("Spiritual data by RoxyAPI")}</a></div>`}renderNoData(){return this.selfFetch()?this.renderWithForm(l):this.renderEmpty()}renderForm(){let e=this.selfFetch();return c`<roxy-endpoint-form part="form" exportparts="hint" data-endpoint="${e?.endpoint??""}" method="${e?.method??"POST"}" spec-url="${C(this.specUrl)}" publishable-key="${C(this.publishableKey)}" location-url="${C(this.locationUrl)}" submit-label="${C(this.submitLabel)}" lang="${C(this.effectiveLang())}" .initialValues="${this.formInitialValues()}" .serverIssues="${this.issues}" .apiRoute="${this.fetcher}" .autoload="${!this.selfFetched}" .fullPages="${!!this.listKey}" @roxy-submit="${this.onFormSubmit}"></roxy-endpoint-form>`}formInitialValues(){return this.lastValues??(this.remember?this.readRemembered():void 0)}rememberKey(){return`roxy-ui:form:${this.selfFetch()?.endpoint??""}`}readRemembered(){try{let e=sessionStorage.getItem(this.rememberKey());return e?JSON.parse(e):void 0}catch{return}}writeRemembered(e){try{sessionStorage.setItem(this.rememberKey(),JSON.stringify(e))}catch{}}renderEmpty(){return c`<div class="roxy-empty" role="status" part="empty">${this.t("No data")}</div>`}renderLoading(){return c`<div class="roxy-skeleton" style="height:5lh" role="status" aria-label="${this.t("Loading")}" part="loading"></div>`}renderError(e){let n=!!this.selfFetch();if(n&&this.issues)return this.renderForm();let o=this.renderErrorBanner(e);return n?c`${o}${this.renderForm()}`:o}renderErrorBanner(e){return c`<div class="roxy-error" role="alert" part="error">${!this.fetcher.worded&&this.errorMessage||this.t(e)}</div>`}};u([y({attribute:false})],g.prototype,"data",2),u([y({type:String,attribute:"data-endpoint"})],g.prototype,"endpoint",2),u([y({type:String})],g.prototype,"method",2),u([y({type:String,attribute:"publishable-key"})],g.prototype,"publishableKey",2),u([y({type:String,attribute:"base-url"})],g.prototype,"baseUrl",2),u([y({type:String,attribute:"spec-url"})],g.prototype,"specUrl",2),u([y({type:String,attribute:"submit-url"})],g.prototype,"submitUrl",2),u([y({attribute:"submit-context",converter:we})],g.prototype,"submitContext",2),u([y({type:String,attribute:"location-url"})],g.prototype,"locationUrl",2),u([y({type:Boolean})],g.prototype,"remember",2),u([y({type:Boolean,attribute:"hide-readings",reflect:true})],g.prototype,"hideReadings",2),u([y({type:String,attribute:"hide-sections",reflect:true})],g.prototype,"hideSections",2),u([y({type:String,attribute:"brand-color"})],g.prototype,"brandColor",2),u([y({type:String,attribute:"brand-accent"})],g.prototype,"brandAccent",2),u([y({type:String})],g.prototype,"font",2),u([y({type:String,attribute:"submit-label"})],g.prototype,"submitLabel",2),u([y({type:String,attribute:"error-message"})],g.prototype,"errorMessage",2),u([y({type:String})],g.prototype,"attribution",2),u([S()],g.prototype,"loading",2),u([S()],g.prototype,"error",2),u([S()],g.prototype,"issues",2),u([S()],g.prototype,"selfFetched",2),u([S()],g.prototype,"editing",2),u([S()],g.prototype,"sticky",2),u([S()],g.prototype,"openedRow",2),u([S()],g.prototype,"openedRowId",2),u([S()],g.prototype,"moreLoading",2),u([S()],g.prototype,"moreError",2);var Ae=r=>t=>{customElements.get(r)||customElements.define(r,t)};function Re(r){let t=Math.floor(r);return{degree:t,minute:Math.floor((r-t)*60)}}var $n=/^\d{4}-\d{2}-\d{2}$/,Tn=/^\d{4}-\d{2}$/,kn=/^\d{2}:\d{2}(:\d{2})?$/,An=/^\d{4}-\d{2}-\d{2}[T ]\d{2}:\d{2}(:\d{2}(\.\d+)?)?$/,_e=new Map;function Rt(r){if(!r)return["en"];let t=_e.get(r);if(t)return[t,"en"];let e="en";try{e=Intl.getCanonicalLocales(r)[0]??"en"}catch{e="en"}return _e.set(r,e),[e,"en"]}function Rn(r,t){return r&&t?`${r} - ${t}`:r||t}function Pe(r){let t=kn.test(r)?`1970-01-01T${r}`:$n.test(r)?`${r}T00:00:00`:Tn.test(r)?`${r}-01T00:00:00`:An.test(r)?r.replace(" ","T"):null;return t?{d:new Date(`${t}Z`),timeZone:"UTC"}:{d:new Date(r)}}function lt(r,t){if(typeof t!="string"||t.length===0)return"";let{d:e,timeZone:n}=Pe(t);return Number.isNaN(e.getTime())?t:e.toLocaleDateString(Rt(r),{month:"short",day:"numeric",timeZone:n})}function Ce(r,t,e){let n=lt(r,t),o=lt(r,e);return n===o?n:Rn(n,o)}function Fe(r,t){if(typeof t!="string"||t.length===0)return"";let{d:e,timeZone:n}=Pe(t);return Number.isNaN(e.getTime())?t:e.toLocaleDateString(Rt(r),{weekday:"short",day:"numeric",timeZone:n})}function Oe(r,t,e){return typeof t!="number"||!Number.isFinite(t)||typeof e!="number"||!Number.isInteger(e)||e<1||e>12?"":new Date(Date.UTC(t,e-1,1,12)).toLocaleDateString(Rt(r),{month:"long",year:"numeric",timeZone:"UTC"})}var _n="Localized";function H(r,t,e){let n=r,o=n?.[`${t}${_n}`];if(typeof o=="string"&&o!=="")return o;if(e!==void 0)return e;let s=n?.[t];return typeof s=="string"?s:""}var Pn="12:00 UTC",T=class extends g{constructor(){super(...arguments);this.heading="Ephemeris"}renderData(e){if(!e.days?.length)return this.renderEmpty();let n=this.toViewModel(e),o=this.effectiveLang();return c`<div class="wrap" part="card"><header part="header"><h2>${this.t(this.heading)}</h2><p class="month roxy-label"><span>${Oe(o,n.year,n.month)}</span><span>${Pn}</span></p></header>${this.renderSignKey(n.signs)}<section part="section changes"><h3>${this.t("Sign changes and retrograde periods")}</h3><div role="list">${n.bodies.map(s=>this.renderTrack(s))}</div></section><section part="section daily"><h3>${this.t("Daily positions")}</h3><div class="scroll" part="table" tabindex="0" aria-label="${this.t("Daily positions")}">${this.renderGrid(n)}</div></section></div>`}renderSignKey(e){return e.length===0?l:c`<section part="section legend"><h3>${this.t("Signs in this month")}</h3><ul class="signkey" role="list">${e.map(n=>c`<li class="signkey-item"><span class="signkey-glyph" aria-hidden="true">${n.glyph}</span>${n.label}</li>`)}</ul></section>`}renderTrack(e){let n=Et(e.name);return c`<div class="track" role="listitem"><span class="body-name">${n?c`<span class="glyph" aria-hidden="true">${n}</span>`:l}${e.label} </span><span class="span">${this.renderPosition(e.first)}<span class="arrow" aria-hidden="true">→</span>${this.renderPosition(e.last)} </span>${e.ingresses.length||e.retrogrades.length?c`<span class="chips roxy-chips">${e.ingresses.map(o=>this.renderIngressChip(o))} ${e.retrogrades.map(o=>this.renderRetrogradeChip(o))}</span>`:l}</div>`}renderPosition(e){let{degree:n,minute:o}=Re(e.degreeInSign),s=tt(e.sign),i=H(e,"sign");return c`<span class="pos" title="${i}">${n}${s?c`<span class="sg" aria-hidden="true">${s}</span>`:c`<span class="sg">${i}</span>`}${String(o).padStart(2,"0")}</span>`}renderIngressChip(e){let n=tt(e.sign),o=lt(this.effectiveLang(),e.date);return c`<span class="roxy-chip chip--ingress" aria-label="${this.t("Enters {{sign}} on {{date}}",{sign:e.signLabel,date:o})}"><span aria-hidden="true">→</span>${n?c`<span aria-hidden="true">${n}</span>`:l}${e.signLabel} <span class="chip-date">${o}</span></span>`}renderRetrogradeChip(e){let n=Ce(this.effectiveLang(),e.start,e.end);return c`<span class="roxy-chip chip--retro" data-tone="danger"><span aria-hidden="true">℞</span>${this.t("Retrograde {{range}}",{range:n})}</span>`}renderGrid(e){let n=this.effectiveLang();return c`<table><caption class="roxy-sr-only">${this.t("Every body with its position on each day of the month, as a zodiac sign and a degree.")}</caption><thead><tr><th scope="col" class="day">${this.t("Date")}</th>${e.bodies.map(o=>{let s=Et(o.name);return c`<th scope="col" title="${o.label}">${s?c`<span class="glyph" aria-hidden="true">${s}</span><span class="roxy-sr-only">${o.label}</span>`:o.label}</th>`})}</tr></thead><tbody>${e.rows.map(o=>c`<tr><th scope="row" class="day">${Fe(n,o.date)}</th>${o.cells.map((s,i)=>this.renderCell(s,e.bodies[i],o.date))}</tr>`)}</tbody></table>`}renderCell(e,n,o){if(!e)return c`<td>—</td>`;let s=[e.isRetrograde?"retro":"",n?.ingressDates.has(o)?"ingress":"",n?.stationDates.has(o)?"station":""].filter(Boolean).join(" ");return c`<td class="${s}">${this.renderPosition(e)}${e.isRetrograde?c`<span class="retro-mark" aria-label="${this.t("retrograde")}">℞</span>`:l}</td>`}toViewModel(e){let n=[],o=new Map;for(let d of e.days)for(let a of d.positions){let p=o.get(a.planet);p||(p=[],o.set(a.planet,p),n.push(a.planet)),p.push({date:d.date,p:a})}let s=[];for(let d of n){let a=o.get(d),p=a?.[0],h=a?.[a.length-1];if(!a||!p||!h)continue;let m=[],f=[],b=new Set,k=new Set;for(let B=0;B<a.length;B++){let x=a[B],U=a[B-1];if(!x||(U&&x.p.sign!==U.p.sign&&(m.push({date:x.date,sign:x.p.sign,signLabel:H(x.p,"sign")}),b.add(x.date)),U&&x.p.isRetrograde!==U.p.isRetrograde&&k.add(x.date),!x.p.isRetrograde))continue;let _t=f[f.length-1];_t&&U?.p.isRetrograde?_t.end=x.date:f.push({start:x.date,end:x.date})}s.push({name:d,label:H(h.p,"planet"),first:p.p,last:h.p,ingresses:m,retrogrades:f,ingressDates:b,stationDates:k})}let i=e.days.map(d=>{let a=new Map(d.positions.map(p=>[p.planet,p]));return{date:d.date,cells:s.map(p=>a.get(p.name))}});return{year:e.year,month:e.month,bodies:s,rows:i,signs:this.toSignKey(e)}}toSignKey(e){let n=new Map;for(let s of e.days)for(let i of s.positions){let d=String(i.sign??"").toLowerCase();d&&!n.has(d)&&n.set(d,H(i,"sign"))}let o=[];for(let s of Zt){let i=n.get(s.toLowerCase()),d=tt(s);i&&d&&o.push({sign:s,label:i,glyph:d})}return o}};T.endpoints=Yt,T.styles=[it,v`:host{overflow-x:clip}.wrap{gap:var(--roxy-space-lg);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.wrap>*{min-width:0}h2,h3,p{margin:0}header,section{gap:var(--roxy-space-sm);display:grid}.month{gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}.signkey{gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}.signkey-item{align-items:baseline;gap:var(--roxy-space-xs);color:var(--roxy-muted);font-size:var(--roxy-text-xs);white-space:nowrap;display:inline-flex}.signkey-glyph{color:var(--roxy-fg);font-size:var(--roxy-text-sm)}.track{align-items:center;gap:var(--roxy-space-xs) var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.body-name{align-items:baseline;gap:var(--roxy-space-xs);min-inline-size:16ch;font-weight:var(--roxy-weight-bold);display:inline-flex}.body-name .glyph{color:var(--roxy-accent-ink)}.span{align-items:baseline;gap:var(--roxy-space-xs);color:var(--roxy-secondary);font-variant-numeric:tabular-nums;white-space:nowrap;display:inline-flex}.arrow{color:var(--roxy-muted)}.chips{margin-inline-start:auto}.chip-date{color:var(--roxy-muted)}.scroll{min-width:0;overflow-x:auto}table{font-size:var(--roxy-text-xs)}:is(th,td){white-space:nowrap}thead th .glyph{color:var(--roxy-fg);font-size:var(--roxy-text-sm)}th.day{z-index:1;background:var(--roxy-bg);color:var(--roxy-fg);border-inline-end:1px solid var(--roxy-border);position:sticky;left:0}thead th.day{z-index:2}.sg{margin-inline:calc(var(--roxy-space-unit) / 2);color:var(--roxy-secondary);font-variant-numeric:normal}.retro-mark{font-weight:var(--roxy-weight-bold);margin-inline-start:calc(var(--roxy-space-unit) / 2)}td.retro,td.retro .sg{color:var(--roxy-danger-fg)}td.ingress{box-shadow:inset var(--roxy-line-thick) 0 var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}td.station{border-block-start:var(--roxy-line-thick) solid var(--roxy-danger-fg);font-weight:var(--roxy-weight-bold)}`],u([y({type:String})],T.prototype,"heading",2),T=u([Ae("roxy-ephemeris-table")],T);return Ie(Cn)})();/*! Bundled license information:
|
|
3
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),Gt=/'/g,Kt=/"/g,Bt=/^(?:script|style|textarea|title)$/i,St=r=>(t,...e)=>({_$litType$:r,strings:t,values:e}),c=St(1),Nn=St(2),In=St(3),P=Symbol.for("lit-noChange"),l=Symbol.for("lit-nothing"),jt=new WeakMap,R=_.createTreeWalker(_,129);function qt(r,t){if(!vt(r)||!r.hasOwnProperty("raw"))throw Error("invalid template strings array");return Nt!==void 0?Nt.createHTML(t):t}var We=(r,t)=>{let e=r.length-1,n=[],o,s=t===2?"<svg>":t===3?"<math>":"",i=D;for(let d=0;d<e;d++){let a=r[d],p,h,g=-1,f=0;for(;f<a.length&&(i.lastIndex=f,h=i.exec(a),h!==null);)f=i.lastIndex,i===D?h[1]==="!--"?i=It:h[1]!==void 0?i=Dt:h[2]!==void 0?(Bt.test(h[2])&&(o=RegExp("</"+h[2],"g")),i=A):h[3]!==void 0&&(i=A):i===A?h[0]===">"?(i=o??D,g=-1):h[1]===void 0?g=-2:(g=i.lastIndex-h[2].length,p=h[1],i=h[3]===void 0?A:h[3]==='"'?Kt:Gt):i===Kt||i===Gt?i=A:i===It||i===Dt?i=D:(i=A,o=void 0);let b=i===A&&r[d+1].startsWith("/>")?" ":"";s+=i===D?a+Ve:g>=0?(n.push(p),a.slice(0,g)+zt+a.slice(g)+E+b):a+E+(g===-2?d:b)}return[qt(r,s+(r[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),n]},j=class r{constructor({strings:t,_$litType$:e},n){let o;this.parts=[];let s=0,i=0,d=t.length-1,a=this.parts,[p,h]=We(t,e);if(this.el=r.createElement(p,n),R.currentNode=this.el.content,e===2||e===3){let g=this.el.content.firstChild;g.replaceWith(...g.childNodes)}for(;(o=R.nextNode())!==null&&a.length<d;){if(o.nodeType===1){if(o.hasAttributes())for(let g of o.getAttributeNames())if(g.endsWith(zt)){let f=h[i++],b=o.getAttribute(g).split(E),k=/([.?@])?(.*)/.exec(f);a.push({type:1,index:s,name:k[2],strings:b,ctor:k[1]==="."?gt:k[1]==="?"?yt:k[1]==="@"?ft:F}),o.removeAttribute(g)}else g.startsWith(E)&&(a.push({type:6,index:s}),o.removeAttribute(g));if(Bt.test(o.tagName)){let g=o.textContent.split(E),f=g.length-1;if(f>0){o.textContent=J?J.emptyScript:"";for(let b=0;b<f;b++)o.append(g[b],G()),R.nextNode(),a.push({type:2,index:++s});o.append(g[f],G())}}}else if(o.nodeType===8)if(o.data===Ht)a.push({type:2,index:s});else{let g=-1;for(;(g=o.data.indexOf(E,g+1))!==-1;)a.push({type:7,index:s}),g+=E.length-1}s++}}static createElement(t,e){let n=_.createElement("template");return n.innerHTML=t,n}};function O(r,t,e=r,n){if(t===P)return t;let o=n!==void 0?e._$Co?.[n]:e._$Cl,s=K(t)?void 0:t._$litDirective$;return o?.constructor!==s&&(o?._$AO?.(false),s===void 0?o=void 0:(o=new s(r),o._$AT(r,e,n)),n!==void 0?(e._$Co??=[])[n]=o:e._$Cl=o),o!==void 0&&(t=O(r,o._$AS(r,t.values),o,n)),t}var mt=class{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){let{el:{content:e},parts:n}=this._$AD,o=(t?.creationScope??_).importNode(e,true);R.currentNode=o;let s=R.nextNode(),i=0,d=0,a=n[0];for(;a!==void 0;){if(i===a.index){let p;a.type===2?p=new z(s,s.nextSibling,this,t):a.type===1?p=new a.ctor(s,a.name,a.strings,this,t):a.type===6&&(p=new xt(s,this,t)),this._$AV.push(p),a=n[++d]}i!==a?.index&&(s=R.nextNode(),i++)}return R.currentNode=_,o}p(t){let e=0;for(let n of this._$AV)n!==void 0&&(n.strings!==void 0?(n._$AI(t,n,e),e+=n.strings.length-2):n._$AI(t[e])),e++}},z=class r{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,n,o){this.type=2,this._$AH=l,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=n,this.options=o,this._$Cv=o?.isConnected??true}get parentNode(){let t=this._$AA.parentNode,e=this._$AM;return e!==void 0&&t?.nodeType===11&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=O(this,t,e),K(t)?t===l||t==null||t===""?(this._$AH!==l&&this._$AR(),this._$AH=l):t!==this._$AH&&t!==P&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):Ye(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==l&&K(this._$AH)?this._$AA.nextSibling.data=t:this.T(_.createTextNode(t)),this._$AH=t}$(t){let{values:e,_$litType$:n}=t,o=typeof n=="number"?this._$AC(t):(n.el===void 0&&(n.el=j.createElement(qt(n.h,n.h[0]),this.options)),n);if(this._$AH?._$AD===o)this._$AH.p(e);else{let s=new mt(o,this),i=s.u(this.options);s.p(e),this.T(i),this._$AH=s}}_$AC(t){let e=jt.get(t.strings);return e===void 0&&jt.set(t.strings,e=new j(t)),e}k(t){vt(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,n,o=0;for(let s of t)o===e.length?e.push(n=new r(this.O(G()),this.O(G()),this,this.options)):n=e[o],n._$AI(s),o++;o<e.length&&(this._$AR(n&&n._$AB.nextSibling,o),e.length=o)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(false,true,e);t!==this._$AB;){let n=Mt(t).nextSibling;Mt(t).remove(),t=n}}setConnected(t){this._$AM===void 0&&(this._$Cv=t,this._$AP?.(t))}},F=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,n,o,s){this.type=1,this._$AH=l,this._$AN=void 0,this.element=t,this.name=e,this._$AM=o,this.options=s,n.length>2||n[0]!==""||n[1]!==""?(this._$AH=Array(n.length-1).fill(new String),this.strings=n):this._$AH=l}_$AI(t,e=this,n,o){let s=this.strings,i=false;if(s===void 0)t=O(this,t,e,0),i=!K(t)||t!==this._$AH&&t!==P,i&&(this._$AH=t);else{let d=t,a,p;for(t=s[0],a=0;a<s.length-1;a++)p=O(this,d[n+a],e,a),p===P&&(p=this._$AH[a]),i||=!K(p)||p!==this._$AH[a],p===l?t=l:t!==l&&(t+=(p??"")+s[a+1]),this._$AH[a]=p}i&&!o&&this.j(t)}j(t){t===l?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},gt=class extends F{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===l?void 0:t}},yt=class extends F{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==l)}},ft=class extends F{constructor(t,e,n,o,s){super(t,e,n,o,s),this.type=5}_$AI(t,e=this){if((t=O(this,t,e,0)??l)===P)return;let n=this._$AH,o=t===l&&n!==l||t.capture!==n.capture||t.once!==n.once||t.passive!==n.passive,s=t!==l&&(n===l||o);o&&this.element.removeEventListener(this.name,this,n),s&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){typeof this._$AH=="function"?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}},xt=class{constructor(t,e,n){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=n}get _$AU(){return this._$AM._$AU}_$AI(t){O(this,t)}};var Ze=bt.litHtmlPolyfillSupport;Ze?.(j,z),(bt.litHtmlVersions??=[]).push("3.3.3");var Vt=(r,t,e)=>{let n=e?.renderBefore??t,o=n._$litPart$;if(o===void 0){let s=e?.renderBefore??null;n._$litPart$=o=new z(t.insertBefore(G(),s),s,void 0,e??{})}return o._$AI(r),o};var wt=globalThis,$=class extends w{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){let t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){let e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=Vt(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(true)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(false)}render(){return P}};$._$litElement$=true,$.finalized=true,wt.litElementHydrateSupport?.({LitElement:$});var Je=wt.litElementPolyfillSupport;Je?.({LitElement:$});(wt.litElementVersions??=[]).push("4.2.2");var Xe={attribute:true,type:String,converter:I,reflect:false,hasChanged:Z},Qe=(r=Xe,t,e)=>{let{kind:n,metadata:o}=e,s=globalThis.litPropertyMetadata.get(o);if(s===void 0&&globalThis.litPropertyMetadata.set(o,s=new Map),n==="setter"&&((r=Object.create(r)).wrapped=true),s.set(e.name,r),n==="accessor"){let{name:i}=e;return{set(d){let a=t.get.call(this);t.set.call(this,d),this.requestUpdate(i,a,r,true,d)},init(d){return d!==void 0&&this.C(i,void 0,r,d),d}}}if(n==="setter"){let{name:i}=e;return function(d){let a=this[i];t.call(this,d),this.requestUpdate(i,a,r,true,d)}}throw Error("Unsupported decorator location: "+n)};function y(r){return(t,e)=>typeof e=="object"?Qe(r,t,e):((n,o,s)=>{let i=o.hasOwnProperty(s);return o.constructor.createProperty(s,n),i?Object.getOwnPropertyDescriptor(o,s):void 0})(r,t,e)}function S(r){return y({...r,state:true,attribute:false})}var Yt=[{endpoint:"astrology/planets/monthly",method:"POST"},{endpoint:"vedic-astrology/planetary-positions/monthly",method:"POST"}];function Q(r){return r.toLowerCase().replace(/[\s_-]+/g," ").trim()}var Wt=(r,t)=>t?r[Q(t)]:void 0,tn={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",midheaven:"MC","part of fortune":"\u2297",vertex:"Vx",lagna:"La","north node":"\u260A","south node":"\u260B",chiron:"\u26B7",lilith:"\u26B8","black moon lilith":"\u26B8"},Et=r=>Wt(tn,r);var en={aries:"\u2648",taurus:"\u2649",gemini:"\u264A",cancer:"\u264B",leo:"\u264C",virgo:"\u264D",libra:"\u264E",scorpio:"\u264F",sagittarius:"\u2650",capricorn:"\u2651",aquarius:"\u2652",pisces:"\u2653"},tt=r=>Wt(en,r);var Zt=["Aries","Taurus","Gemini","Cancer","Leo","Virgo","Libra","Scorpio","Sagittarius","Capricorn","Aquarius","Pisces"];var C=r=>r??l;var Jt=["de","en","es","fr","hi","pt","ru","tr","zh-Hans","zh-Hant"];function Tt(r){if(r.lang)return r.lang;if(typeof document>"u")return;let t=r.closest?.("[lang]")?.getAttribute("lang");return t||document.documentElement.lang||void 0}var nn={tw:"hant",hk:"hant",mo:"hant",cn:"hans",sg:"hans",my:"hans"};function $t(r,t){let e=r.toLowerCase();return t.find(n=>n.toLowerCase()===e)}function Xt(r,t=Jt){let e=Tt(r);if(!e)return;let n=$t(e,t);if(n)return n;let o=e.toLowerCase().split("-"),s=o[0];if(s==="zh"){let i=o.find(d=>d==="hans"||d==="hant")??nn[o[1]??""];return i?$t(`zh-${i}`,t):void 0}return $t(s,t)}var rn={Fraunces:["latin","latin-ext"],Jost:["latin","latin-ext","cyrillic"],Geist:["latin","latin-ext","cyrillic"]},kt='"Jost", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',Qt='"Geist", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',te='system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif',et={"fraunces-jost":{name:"Fraunces with Jost",sans:kt,display:'"Fraunces", ui-serif, Georgia, Cambria, "Times New Roman", Times, serif'},jost:{name:"Jost",sans:kt,display:kt},geist:{name:"Geist",sans:Qt,display:Qt},system:{name:"System",sans:te,display:te}};function ee(r){let{sans:t,display:e}=et[r];return Object.keys(rn).filter(n=>`${t} ${e}`.includes(`"${n}"`))}var ne="1.3.0";var on=/^(.*)\/cdn\/(?:roxy-ui|components\/[\w-]+)\.js$/,sn=/^(.*\/dist)\/(?:index|components\/[\w-]+)\.js$/;function re(r,t){if(!t)return;let e=new URL(t);if(e.protocol!=="https:"&&e.protocol!=="http:")return;let n=(on.exec(e.pathname)??sn.exec(e.pathname))?.[1];if(n!==void 0)return e.hostname==="cdn.jsdelivr.net"?`https://cdn.jsdelivr.net/npm/@roxyapi/ui@${r}/dist`:`${e.origin}${n}`}var pn={},an="color-mix(in oklab, var(--roxy-accent) 70%, black)",dn="var(--roxy-accent)",cn="color-mix(in srgb, var(--roxy-accent) 40%, transparent)",oe=/^#(?:[\da-f]{3}|[\da-f]{6})$/i;function se(r){return r!==void 0&&Object.hasOwn(et,r)}function ie(r){let t=[];return r.brandColor&&oe.test(r.brandColor)&&t.push(`--roxy-primary:${r.brandColor}`),r.brandAccent&&oe.test(r.brandAccent)&&t.push(`--roxy-accent:${r.brandAccent}`,`--roxy-accent-ink:light-dark(${an},${dn})`,`--roxy-ring:${cn}`),t.join(";")}function ae(r,t){if(se(t))return t;let e=r.getRootNode();if(("host"in e?e.host:null)?.localName.startsWith("roxy-")||!globalThis.getComputedStyle)return;let o=r.shadowRoot?.firstElementChild,s=o?.localName==="style"?o:null;s?.sheet&&(s.sheet.disabled=true);let i,d,a;try{let p=globalThis.getComputedStyle(r),h=g=>p.getPropertyValue(g).trim();i=h("--roxy-font-sans"),d=h("--roxy-font-display"),a=h("--roxy-font")}finally{s?.sheet&&(s.sheet.disabled=false)}if(!(i||d))return se(a)?a:void 0}function de(r){let{sans:t,display:e}=et[r];return`--roxy-font:${r};--roxy-font-sans:${t};--roxy-font-display:${e}`}var ln=re(ne,globalThis.document?.currentScript?.src||pn.url);function ce(r,t=ln){if(typeof document>"u"||t===void 0)return;let e=`roxy-ui-font-${r}`;if(ee(r).length===0||document.getElementById(e))return;let n=document.createElement("link");n.id=e,n.rel="stylesheet",n.href=`${t}/styles/fonts/${r}.css`,document.head.append(n)}var le='@layer roxy.tokens,roxy.theme;@layer roxy.tokens{:where(:root,:host){color-scheme:light;--roxy-bg: #ffffff;--roxy-fg: #0a0a0a;--roxy-accent: #4a6297;--roxy-success: #16a34a;--roxy-warning: #ea580c;--roxy-danger: #dc2626;--roxy-info: #0284c7;--roxy-accent-ink: color-mix(in oklab, var(--roxy-accent) 70%, black);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, black);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, black);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, black);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, black);--roxy-font: initial;--roxy-font-sans: initial;--roxy-font-mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, "Liberation Mono", monospace;--roxy-text-base: 1rem;--roxy-text-scale: 1.15;--roxy-weight-normal: 400;--roxy-weight-bold: 600;--roxy-leading-tight: 1.25;--roxy-leading-normal: 1.5;--roxy-tracking-tight: -0.01em;--roxy-tracking-normal: 0em;--roxy-space-unit: 0.25rem;--roxy-radius: 6px;--roxy-motion-duration: 200ms;--roxy-motion-easing: cubic-bezier(0.4, 0, 0.2, 1)}:where(:root,:host,[data-theme],.light,.dark){--roxy-surface: var(--roxy-bg);--roxy-primary: var(--roxy-fg);--roxy-secondary: color-mix(in oklab, var(--roxy-fg) 78%, var(--roxy-bg));--roxy-muted: color-mix(in oklab, var(--roxy-fg) 60%, var(--roxy-bg));--roxy-border: color-mix(in oklab, var(--roxy-fg) 14%, var(--roxy-bg));--roxy-ring: color-mix(in srgb, var(--roxy-accent) 40%, transparent);--roxy-heat: var(--roxy-danger);--roxy-font-display: var(--roxy-font-sans);--roxy-text-sm: calc(var(--roxy-text-base) / var(--roxy-text-scale));--roxy-text-xs: calc(var(--roxy-text-sm) / var(--roxy-text-scale));--roxy-text-lg: calc(var(--roxy-text-base) * var(--roxy-text-scale));--roxy-text-xl: calc( var(--roxy-text-lg) * var(--roxy-text-scale) * var(--roxy-text-scale) );--roxy-space-xs: var(--roxy-space-unit);--roxy-space-sm: calc(var(--roxy-space-unit) * 2);--roxy-space-md: calc(var(--roxy-space-unit) * 4);--roxy-space-lg: calc(var(--roxy-space-unit) * 6);--roxy-space-xl: calc(var(--roxy-space-unit) * 10);--roxy-line-thick: calc(var(--roxy-space-unit) / 2);--roxy-touch: calc(var(--roxy-space-unit) * 11);--roxy-radius-sm: calc(var(--roxy-radius) / 2);--roxy-radius-md: var(--roxy-radius);--roxy-radius-lg: calc(var(--roxy-radius) * 5 / 3);--roxy-radius-full: 9999px;--roxy-shadow-sm: none;--roxy-shadow-md: 0 4px 12px color-mix(in srgb, black 10%, transparent);--roxy-shadow-lg: 0 12px 32px color-mix(in srgb, black 18%, transparent)}@media(prefers-color-scheme:dark){:where(:root,:host){color-scheme:dark;--roxy-bg: #0a0a0a;--roxy-fg: #fafafa;--roxy-accent: #92aade;--roxy-success: #22c55e;--roxy-warning: #fb923c;--roxy-danger: #ef4444;--roxy-info: #38bdf8;--roxy-accent-ink: var(--roxy-accent);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, white);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, white);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, white);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, white)}}:where(:root[data-theme=light],[data-theme=light],:root.light,.light,:host([data-theme="light"])){color-scheme:light;--roxy-bg: #ffffff;--roxy-fg: #0a0a0a;--roxy-accent: #4a6297;--roxy-success: #16a34a;--roxy-warning: #ea580c;--roxy-danger: #dc2626;--roxy-info: #0284c7;--roxy-accent-ink: color-mix(in oklab, var(--roxy-accent) 70%, black);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, black);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, black);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, black);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, black)}:where(:root[data-theme=dark],[data-theme=dark],:root.dark,.dark,:host([data-theme="dark"])){color-scheme:dark;--roxy-bg: #0a0a0a;--roxy-fg: #fafafa;--roxy-accent: #92aade;--roxy-success: #22c55e;--roxy-warning: #fb923c;--roxy-danger: #ef4444;--roxy-info: #38bdf8;--roxy-accent-ink: var(--roxy-accent);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, white);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, white);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, white);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, white)}@media(prefers-reduced-motion:reduce){:where(:root,:host){--roxy-motion-duration: 0ms}}}';var nt="roxy-ui-tokens";function rt(){if(typeof document>"u")return null;let r=document.getElementById(nt);if(r)return r;let t=document.createElement("style");return t.id=nt,t.textContent=le,document.head.prepend(t),t}var pe="__ROXY_UI_I18N__";function he(){let r=globalThis,t=r[pe];if(t)return t;let e={catalogs:{},fieldLabels:{},requested:new Set,listeners:new Set};return r[pe]=e,e}function hn(r,t){return t?r.replace(/\{\{(\w+)\}\}/g,(e,n)=>n in t?String(t[n]??""):e):r}function ue(r,t,e){return hn(un(r,t)??t,e)}function un(r,t){if(!r)return;let{catalogs:e}=he(),n=r.toLowerCase();return(e[n]??e[n.split("-")[0]])?.[Q(t)]}function me(r){let{listeners:t}=he();return t.add(r),()=>{t.delete(r)}}var ot=class{constructor(t){this.host=t,t.addController(this)}hostConnected(){this.unsubscribe=me(()=>this.host.requestUpdate())}hostDisconnected(){this.unsubscribe?.(),this.unsubscribe=void 0}};var st=class extends ${constructor(){super();this.translator=(e,n)=>this.t(e,n);new ot(this)}connectedCallback(){super.connectedCallback(),rt()}fontDeclarations(e){let n=ae(this,e);return n?(ce(n),de(n)):""}renderFontStyle(){let e=this.fontDeclarations();return e?c`<style>:host{${e}}</style>`:l}t(e,n){return ue(this.effectiveLang(),e,n)}effectiveLang(){return Tt(this)}};var ge=v`:where([part~=card]){background:var(--roxy-surface);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);box-shadow:var(--roxy-shadow-sm)}:where([part~=card] [part~=card],[part~=card] [part~=reading],[part~=card] .roxy-card){border:0;border-block-start:1px solid var(--roxy-border);box-shadow:none;background:0 0;border-radius:0;padding-inline:0}:host([bare]) [part~=card]{box-shadow:none;background:0 0;border:0;border-radius:0;padding:0}:where(h1,h2){color:var(--roxy-fg);font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);letter-spacing:var(--roxy-tracking-tight);text-wrap:balance}:where(h3,h4,h5,h6){color:var(--roxy-fg);font-size:var(--roxy-text-base);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);letter-spacing:var(--roxy-tracking-normal);text-transform:none}:where(.roxy-label,th,dt){color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-normal);letter-spacing:var(--roxy-tracking-normal);text-transform:none}:where(.roxy-chips){gap:var(--roxy-space-xs);flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}:where(.roxy-chip,.roxy-chips>li){align-items:center;gap:var(--roxy-space-xs);padding:calc(var(--roxy-space-unit) / 2) var(--roxy-space-sm);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-sm);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);line-height:var(--roxy-leading-tight);overflow-wrap:anywhere;background:0 0;max-inline-size:100%;display:inline-flex}:where(.roxy-chip[data-tone=success],.roxy-chips>li[data-tone=success]){color:var(--roxy-success-fg)}:where(.roxy-chip[data-tone=warning],.roxy-chips>li[data-tone=warning]){color:var(--roxy-warning-fg)}:where(.roxy-chip[data-tone=danger],.roxy-chips>li[data-tone=danger]){color:var(--roxy-danger-fg)}:where(.roxy-chip[data-tone=info],.roxy-chips>li[data-tone=info]){color:var(--roxy-info-fg)}:where(table){border-collapse:collapse;font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}:where(th,td){padding:var(--roxy-space-xs) var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);text-align:start;vertical-align:top}:where(summary){cursor:pointer}:where(a,button,summary,input,select,textarea,[tabindex]):focus-visible{outline:var(--roxy-line-thick) solid var(--roxy-ring);outline-offset:var(--roxy-line-thick)}:where(summary:focus-visible){border-radius:var(--roxy-radius-sm)}:where(input,select,textarea,button){font:inherit}:where(input:not([type=checkbox],[type=radio],[type=range]),select,textarea){padding:var(--roxy-space-xs) var(--roxy-space-sm);background:var(--roxy-bg);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md)}`;var mn=v`:host{--roxy-label-col:minmax(0, 25%);--_mask:var(--roxy-surface);font-family:var(--roxy-font-sans);color:var(--roxy-fg);font-size:var(--roxy-text-base);line-height:var(--roxy-leading-normal);animation:roxy-fade-in var(--roxy-motion-duration) var(--roxy-motion-easing) both;background:0 0;display:block;container-type:inline-size}:host([bare]){--_mask:var(--roxy-bg)}:host([hidden]){display:none}: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)}@keyframes roxy-fade-in{0%{transform:translateY(calc(var(--roxy-space-unit) / 2))}to{transform:translateY(0)}}@media (prefers-reduced-motion:reduce){:host{animation:none}}.roxy-skeleton{background:linear-gradient(90deg, var(--roxy-border) 0%, color-mix(in srgb, var(--roxy-border) 60%, transparent) 50%, var(--roxy-border) 100%);border-radius:var(--roxy-radius-md);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);color:var(--roxy-muted);text-align:center;font-size:var(--roxy-text-sm)}.roxy-error{gap:var(--roxy-space-sm);padding:var(--roxy-space-lg);background:var(--roxy-surface);border:1px solid var(--roxy-danger);border-radius:var(--roxy-radius-md);color:var(--roxy-danger-fg);font-size:var(--roxy-text-sm);justify-items:start;display:grid}:host(:focus-within) .roxy-card{outline:var(--roxy-line-thick) solid var(--roxy-ring);outline-offset:var(--roxy-line-thick)}.roxy-attribution{margin-top:var(--roxy-space-sm);font-size:var(--roxy-text-xs);color:var(--roxy-muted);text-align:right}.roxy-attribution a{color:inherit;text-decoration:none}.roxy-attribution a:hover{color:var(--roxy-accent-ink);text-decoration:underline}.roxy-edit-bar{margin-bottom:var(--roxy-space-sm);justify-content:flex-end;display:flex}.roxy-edit{padding:var(--roxy-space-xs) var(--roxy-space-md);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);color:var(--roxy-fg);font-family:inherit;font-size:var(--roxy-text-sm);cursor:pointer;background:0 0}.roxy-edit:hover{border-color:var(--roxy-accent);color:var(--roxy-accent-ink)}.roxy-edit:disabled{cursor:progress;color:var(--roxy-muted)}roxy-endpoint-form+*{margin-top:var(--roxy-space-md)}.roxy-more{justify-items:center;gap:var(--roxy-space-sm);margin-top:var(--roxy-space-md);display:grid}.roxy-more .roxy-edit{min-height:var(--roxy-touch)}:host{font-variant-emoji:text}`,it=[mn,ge];var gn="__cols",yn="__rows";function fn(r){return typeof r=="object"&&r!==null&&!Array.isArray(r)}function at(r){if(Array.isArray(r)){let s=false,i=r.map(d=>{let a=at(d);return a!==d&&(s=true),a});return s?i:r}if(!fn(r))return r;let t=r[gn],e=r[yn];if(Array.isArray(t)&&Array.isArray(e)&&Object.keys(r).length===2)return e.map(s=>{let i={};return t.forEach((d,a)=>{i[d]=at(s[a])}),i});let n=false,o={};for(let[s,i]of Object.entries(r)){let d=at(i);d!==i&&(n=true),o[s]=d}return n?o:r}function ye(r){return at(r)}function fe(r,t){return r.find(e=>e.attrs&&Object.entries(e.attrs).every(([n,o])=>t[n]===o))??r[0]}var xn="pk_live_YOUR_KEY",xe={secret:{reason:"possible-secret-key",message:"Client-side components accept a pk_ publishable key only. Use a publishable key with an origin allowlist, or render server-side."},sample:{reason:"sample-key",message:"Replace the sample key with your own publishable key from your RoxyAPI account."}};function be(r){if(r)return r===xn?xe.sample:r.startsWith("pk_")?void 0:xe.secret}function ve(r,t,e={}){e.warn&&console.warn(t.message),r.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{reason:t.reason,message:t.message},bubbles:true,composed:true}))}var Se="https://roxyapi.com/api/v2";async function bn(r){try{let t=await r.json();if(t?.error){let e=t.code==="validation_error"&&Array.isArray(t.issues)?t.issues.filter(n=>typeof n.path=="string"&&typeof n.message=="string").map(n=>({path:n.path,message:n.message})):null;return{message:t.error,issues:e?.length?e:null,worded:true,...t.code?{code:t.code}:{}}}}catch{}return{message:`Request failed (${r.status})`,issues:null,worded:false}}var we={fromAttribute:r=>{if(r!=null){try{let t=JSON.parse(r);if(t&&typeof t=="object"&&!Array.isArray(t))return t}catch{}console.warn("[roxy-ui] submit-context must be a JSON object; sending the request without it.")}}},L=class extends Error{constructor(e,n=null,o=true,s,i){super(e);this.issues=n;this.worded=o;this.status=s;this.code=i}};function Ee(r){return r.submitUrl?void 0:be(r.publishableKey)}async function At(r,t,e){let n=Ee(r);if(n)throw new L(n.message);let o=r.submitUrl?await fetch(r.submitUrl,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:vn(t,r.submitContext),signal:e}):await Sn(r,t,e);if(!o.ok){let s=await bn(o);throw new L(s.message,s.issues,s.worded,o.status,s.code)}return await o.json()}function vn(r,t){return JSON.stringify(t?{...r,context:t}:r)}function Sn(r,t,e){let n=new URL(`${r.baseUrl??Se}${t.path}`,document.baseURI);for(let[s,i]of Object.entries(t.query??{}))i!=null&&n.searchParams.set(s,String(i));let o={Accept:"application/json"};return r.publishableKey&&(o["X-API-Key"]=r.publishableKey),t.body!=null&&(o["Content-Type"]="application/json"),fetch(n,{method:t.method??"GET",headers:o,body:t.body!=null?JSON.stringify(t.body):void 0,signal:e})}var dt=class{constructor(t){this.baseUrl=Se;this.worded=true;this.failure={};this.host=t,t.addController(this)}hostDisconnected(){this.abort?.abort(),this.abort=void 0}async run(t){this.worded=true,this.failure={};let e=Ee(this);if(e){this.host.error=e.message,ve(this.host,e);return}this.abort?.abort();let n=new AbortController;this.abort=n,this.host.loading=true,this.host.error=null,this.host.issues=null;try{let o=await At(this,t,n.signal);if(n.signal.aborted)return;this.host.data=o}catch(o){if(n.signal.aborted||o?.name==="AbortError")return;o instanceof L&&(this.host.issues=o.issues,this.failure={status:o.status,code:o.code}),this.worded=o instanceof L&&o.worded,this.host.error=o instanceof Error?o.message:String(o)}finally{this.abort===n&&(this.abort=void 0),n.signal.aborted||(this.host.loading=false)}}};function $e(r,t,e,n=[]){let o={...e},s=`/${r.replace(/^\//,"")}`.replace(/\{([^}]+)\}/g,(p,h)=>{let g=o[h];return delete o[h],encodeURIComponent(String(g??""))}),i=new Set(n),d={},a={};for(let[p,h]of Object.entries(o))h===void 0||h===""||(t==="GET"||i.has(p)?d[p]=h:a[p]=h);return{path:s,method:t,query:d,body:t==="POST"?a:void 0}}function Te(){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 mo=v`summary{list-style:none}summary::-webkit-details-marker{display:none}.roxy-chevron{aspect-ratio:auto;width:.7lh;height:.7lh;color:var(--roxy-muted);transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing);flex-shrink:0}details[open]>summary .roxy-chevron{transform:rotate(180deg)}@media (prefers-reduced-motion:reduce){.roxy-chevron{transition:none}}`;var xo=v`.block{border-top:1px solid var(--roxy-border);padding-top:var(--roxy-space-md)}.block h3{margin:0 0 var(--roxy-space-sm)}.interp-card{padding-block:var(--roxy-space-sm)}.interp-card summary{font-weight:var(--roxy-weight-bold);color:var(--roxy-fg);align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);display:flex}.interp-lead{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;flex:auto;order:1;min-width:0;display:inline-flex}.interp-aside{align-items:center;gap:var(--roxy-space-sm);flex-shrink:0;order:2;display:inline-flex}.roxy-chevron{order:3}.interp-aside small{color:var(--roxy-muted);font-weight:var(--roxy-weight-normal);white-space:nowrap}@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);gap:var(--roxy-space-sm);color:var(--roxy-fg);font-size:var(--roxy-text-sm);line-height:var(--roxy-leading-normal);overflow-wrap:anywhere;display:grid}.interp-body p{margin:0}`;function ke(r,t,e){let n=r.filter(o=>!!o.body);return n.length===0?l:c`<section class="block" part="section readings"><h3>${e}</h3>${n.map((o,s)=>c`<details class="interp-card" part="reading" name="${t}" ?open="${s===0}"><summary><span class="interp-lead">${o.label}</span> ${Te()} ${o.aside?c`<span class="interp-aside"><small>${o.aside}</small></span>`:l}</summary><div class="interp-body"><p>${o.body}</p>${o.extra??l}</div></details>`)}</section>`}var wn="roxy-data";function En(r){return r.nodeName==="SCRIPT"&&r.getAttribute("type")==="application/json"}var ct=class{constructor(t){this.host=t,t.addController(this)}hostConnected(){if(this.host.data!=null)return;let t=this.read();t!==void 0&&(this.host.data=t,this.host.requestUpdate())}read(){let t=this.findInlineScript();return t?this.parse(t.textContent):void 0}findInlineScript(){for(let t of Array.from(this.host.children))if(En(t)&&t.classList.contains(wn))return t;return null}parse(t){if(t?.trim())try{return JSON.parse(t)}catch{return}}};var m=class extends st{constructor(){super();this.data=null;this.endpoint="";this.remember=false;this.hideReadings=false;this.hideSections="";this.loading=false;this.error=null;this.issues=null;this.selfFetched=false;this.editing=false;this.sticky=false;this.hostLoaded=false;this.moreLoading=false;this.moreError=null;this.onMore=async()=>{let e=this.lastRequest,n=this.listKey,o=this.listRows();if(!(!e||!n||!o)){this.moreLoading=true,this.moreError=null;try{let s=await At(this.fetcher,{...e,query:{...e.query,offset:o.length}});if(this.lastRequest!==e)return;let i=s[n];this.data={...this.data,...s,[n]:[...o,...Array.isArray(i)?i:[]]}}catch(s){this.lastRequest===e&&(this.moreError=s instanceof Error?s.message:String(s))}finally{this.moreLoading=false}}};this.onEdit=()=>{this.editing=true};this.onFormSubmit=e=>{let n=this.selfFetch();if(!n)return;let o=e.detail;this.lastValues=o.values,this.sticky=!!o.sticky,this.selfFetched=true,this.editing=false,this.remember&&this.writeRemembered(o.values),this.fetchFresh($e(n.endpoint,n.method,{...o.values,...this.ownRequest()},o.queryKeys??[]))};new ct(this),this.fetcher=new dt(this)}static{this.styles=[it]}static{this.endpoints=[]}willUpdate(e){if(e.has("data")&&this.data!=null){let n=ye(this.data);n!==this.data&&(this.data=n)}(e.has("publishableKey")||e.has("baseUrl")||e.has("submitUrl")||e.has("submitContext"))&&this.syncFetcher()}syncFetcher(){this.fetcher.publishableKey=this.publishableKey,this.baseUrl&&(this.fetcher.baseUrl=this.baseUrl),this.fetcher.submitUrl=this.submitUrl,this.fetcher.submitContext=this.submitContext}selfFetch(){let e=this.endpoint?{endpoint:this.endpoint,method:"POST"}:this.hostLoaded||!(this.publishableKey||this.submitUrl)?void 0:fe(this.constructor.endpoints,this);return e&&{endpoint:e.endpoint,method:this.method??e.method}}render(){return c`${this.hostStyle()}${this.renderState()}`}drawn(e){try{return this.renderData(e)}catch(n){return console.warn(`[roxy-ui] ${this.localName} could not draw its response`,n),this.dispatchEvent(new CustomEvent("roxy-render-error",{detail:{error:n},bubbles:true,composed:true})),customElements.get("roxy-data")?c`<roxy-data .data="${e}" lang="${C(this.effectiveLang())}"></roxy-data>`:this.renderEmpty()}}hostStyle(){let e=this.hideSections.split(",").map(s=>s.trim().toLowerCase()).filter(s=>/^[a-z][a-z0-9-]*$/.test(s)),n=[ie(this),this.fontDeclarations(this.font)].filter(Boolean).join(";");if(e.length===0&&!n)return l;let o=(n?`:host{${n}}`:"")+e.map(s=>`[part~="${s}"],roxy-endpoint-form::part(${s}){display:none!important}`).join("");return c`<style>${o}</style>`}ownRequest(){return{}}get failure(){return this.fetcher.failure}renderState(){return this.selfFetch()&&this.sticky&&this.selfFetched&&!this.editing?this.renderWithForm(this.stickyBody()):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.drawn(this.data)}${this.renderAttribution()}`:this.drawn(this.data):this.renderNoData()}renderInterpretation(e,n,o){return this.hideReadings?l:ke(e,n,this.t(o??"Reading"))}renderResult(e){let n=c`<div class="roxy-edit-bar" part="edit-bar"><button type="button" class="roxy-edit" @click="${this.onEdit}">${this.t("Edit query")}</button></div>${this.drawn(e)}`;return this.showAttribution()?c`${n}${this.renderAttribution()}`:n}renderWithForm(e){return c`${this.renderForm()}${e}`}stickyBody(){return this.loading?this.renderLoading():this.error!=null?this.issues?l:this.renderErrorBanner(this.error):this.data==null?l:this.showAttribution()?c`${this.drawn(this.data)}${this.renderAttribution()}`:this.drawn(this.data)}renderMore(){let e=this.listRows(),n=this.data?.total;return!this.lastRequest||!e||typeof n!="number"?l:e.length>=n?l:c`<div class="roxy-more" part="more"><button type="button" class="roxy-edit" ?disabled="${this.moreLoading}" aria-busy="${this.moreLoading?"true":"false"}" @click="${this.onMore}">${this.t("Show more")}</button> ${this.moreError?c`<p class="roxy-error" role="alert">${this.t(this.moreError)}</p>`:l}</div>`}listRows(){let e=this.listKey?this.data?.[this.listKey]:void 0;return Array.isArray(e)?e:void 0}fetchFresh(e){return this.lastRequest=e,this.openedRow=void 0,this.openedRowId=void 0,this.moreError=null,this.fetcher.run(e)}load(e){return this.hostLoaded=true,this.syncFetcher(),this.fetchFresh(e)}pickRow(e){this.dispatchEvent(new CustomEvent("roxy-symbol-select",{detail:e,bubbles:true,composed:true})),this.openRow(e.id)}openRow(e){if(!this.rowDetail||!(this.publishableKey||this.submitUrl))return;let n=this.openedRow??document.createElement(this.rowDetail.tag);n.publishableKey=this.publishableKey,n.baseUrl=this.baseUrl,n.submitUrl=this.submitUrl,n.submitContext=this.submitContext,n.hideReadings=this.hideReadings,n.hideSections=this.hideSections;let o=this.effectiveLang();o&&n.setAttribute("lang",o),this.openedRow=n,this.openedRowId=e,n.load({path:`/${this.rowDetail.path.replace("{id}",encodeURIComponent(e))}`,method:"GET",query:{lang:Xt(this)}}).then(()=>n.scrollIntoView?.({block:"nearest"}))}showAttribution(){return this.attribution!=null&&this.attribution!=="off"&&this.attribution!=="false"}renderAttribution(){return c`<div class="roxy-attribution" part="attribution"><a href="https://roxyapi.com/?utm_source=widget&utm_medium=embed" target="_blank" rel="noopener">${this.t("Spiritual data by RoxyAPI")}</a></div>`}renderNoData(){return this.selfFetch()?this.renderWithForm(l):this.renderEmpty()}renderForm(){let e=this.selfFetch();return c`<roxy-endpoint-form part="form" exportparts="hint" data-endpoint="${e?.endpoint??""}" method="${e?.method??"POST"}" spec-url="${C(this.specUrl)}" publishable-key="${C(this.publishableKey)}" location-url="${C(this.locationUrl)}" submit-label="${C(this.submitLabel)}" lang="${C(this.effectiveLang())}" .initialValues="${this.formInitialValues()}" .serverIssues="${this.issues}" .apiRoute="${this.fetcher}" .autoload="${!this.selfFetched}" .fullPages="${!!this.listKey}" @roxy-submit="${this.onFormSubmit}"></roxy-endpoint-form>`}formInitialValues(){return this.lastValues??(this.remember?this.readRemembered():void 0)}rememberKey(){return`roxy-ui:form:${this.selfFetch()?.endpoint??""}`}readRemembered(){try{let e=sessionStorage.getItem(this.rememberKey());return e?JSON.parse(e):void 0}catch{return}}writeRemembered(e){try{sessionStorage.setItem(this.rememberKey(),JSON.stringify(e))}catch{}}renderEmpty(){return c`<div class="roxy-empty" role="status" part="empty">${this.t("No data")}</div>`}renderLoading(){return c`<div class="roxy-skeleton" style="height:5lh" role="status" aria-label="${this.t("Loading")}" part="loading"></div>`}renderError(e){let n=!!this.selfFetch();if(n&&this.issues)return this.renderForm();let o=this.renderErrorBanner(e);return n?c`${o}${this.renderForm()}`:o}renderErrorBanner(e){return c`<div class="roxy-error" role="alert" part="error">${!this.fetcher.worded&&this.errorMessage||this.t(e)}</div>`}};u([y({attribute:false})],m.prototype,"data",2),u([y({type:String,attribute:"data-endpoint"})],m.prototype,"endpoint",2),u([y({type:String})],m.prototype,"method",2),u([y({type:String,attribute:"publishable-key"})],m.prototype,"publishableKey",2),u([y({type:String,attribute:"base-url"})],m.prototype,"baseUrl",2),u([y({type:String,attribute:"spec-url"})],m.prototype,"specUrl",2),u([y({type:String,attribute:"submit-url"})],m.prototype,"submitUrl",2),u([y({attribute:"submit-context",converter:we})],m.prototype,"submitContext",2),u([y({type:String,attribute:"location-url"})],m.prototype,"locationUrl",2),u([y({type:Boolean})],m.prototype,"remember",2),u([y({type:Boolean,attribute:"hide-readings",reflect:true})],m.prototype,"hideReadings",2),u([y({type:String,attribute:"hide-sections",reflect:true})],m.prototype,"hideSections",2),u([y({type:String,attribute:"brand-color"})],m.prototype,"brandColor",2),u([y({type:String,attribute:"brand-accent"})],m.prototype,"brandAccent",2),u([y({type:String})],m.prototype,"font",2),u([y({type:String,attribute:"submit-label"})],m.prototype,"submitLabel",2),u([y({type:String,attribute:"error-message"})],m.prototype,"errorMessage",2),u([y({type:String})],m.prototype,"attribution",2),u([S()],m.prototype,"loading",2),u([S()],m.prototype,"error",2),u([S()],m.prototype,"issues",2),u([S()],m.prototype,"selfFetched",2),u([S()],m.prototype,"editing",2),u([S()],m.prototype,"sticky",2),u([S()],m.prototype,"openedRow",2),u([S()],m.prototype,"openedRowId",2),u([S()],m.prototype,"moreLoading",2),u([S()],m.prototype,"moreError",2);var Ae=r=>t=>{customElements.get(r)||customElements.define(r,t)};function Re(r){let t=Math.floor(r);return{degree:t,minute:Math.floor((r-t)*60)}}var $n=/^\d{4}-\d{2}-\d{2}$/,Tn=/^\d{4}-\d{2}$/,kn=/^\d{2}:\d{2}(:\d{2})?$/,An=/^\d{4}-\d{2}-\d{2}[T ]\d{2}:\d{2}(:\d{2}(\.\d+)?)?$/,_e=new Map;function Rt(r){if(!r)return["en"];let t=_e.get(r);if(t)return[t,"en"];let e="en";try{e=Intl.getCanonicalLocales(r)[0]??"en"}catch{e="en"}return _e.set(r,e),[e,"en"]}function Rn(r,t){return r&&t?`${r} - ${t}`:r||t}function Pe(r){let t=kn.test(r)?`1970-01-01T${r}`:$n.test(r)?`${r}T00:00:00`:Tn.test(r)?`${r}-01T00:00:00`:An.test(r)?r.replace(" ","T"):null;return t?{d:new Date(`${t}Z`),timeZone:"UTC"}:{d:new Date(r)}}function lt(r,t){if(typeof t!="string"||t.length===0)return"";let{d:e,timeZone:n}=Pe(t);return Number.isNaN(e.getTime())?t:e.toLocaleDateString(Rt(r),{month:"short",day:"numeric",timeZone:n})}function Ce(r,t,e){let n=lt(r,t),o=lt(r,e);return n===o?n:Rn(n,o)}function Oe(r,t){if(typeof t!="string"||t.length===0)return"";let{d:e,timeZone:n}=Pe(t);return Number.isNaN(e.getTime())?t:e.toLocaleDateString(Rt(r),{weekday:"short",day:"numeric",timeZone:n})}function Fe(r,t,e){return typeof t!="number"||!Number.isFinite(t)||typeof e!="number"||!Number.isInteger(e)||e<1||e>12?"":new Date(Date.UTC(t,e-1,1,12)).toLocaleDateString(Rt(r),{month:"long",year:"numeric",timeZone:"UTC"})}var _n="Localized";function H(r,t,e){let n=r,o=n?.[`${t}${_n}`];if(typeof o=="string"&&o!=="")return o;if(e!==void 0)return e;let s=n?.[t];return typeof s=="string"?s:""}var Pn="12:00 UTC",T=class extends m{constructor(){super(...arguments);this.heading="Ephemeris"}renderData(e){if(!e.days?.length)return this.renderEmpty();let n=this.toViewModel(e),o=this.effectiveLang();return c`<div class="wrap" part="card"><header part="header"><h2>${this.t(this.heading)}</h2><p class="month roxy-label"><span>${Fe(o,n.year,n.month)}</span><span>${Pn}</span></p></header>${this.renderSignKey(n.signs)}<section part="section changes"><h3>${this.t("Sign changes and retrograde periods")}</h3><div role="list">${n.bodies.map(s=>this.renderTrack(s))}</div></section><section part="section daily"><h3>${this.t("Daily positions")}</h3><div class="scroll" part="table" tabindex="0" aria-label="${this.t("Daily positions")}">${this.renderGrid(n)}</div></section></div>`}renderSignKey(e){return e.length===0?l:c`<section part="section legend"><h3>${this.t("Signs in this month")}</h3><ul class="signkey" role="list">${e.map(n=>c`<li class="signkey-item"><span class="signkey-glyph" aria-hidden="true">${n.glyph}</span>${n.label}</li>`)}</ul></section>`}renderTrack(e){let n=Et(e.name);return c`<div class="track" role="listitem"><span class="body-name">${n?c`<span class="glyph" aria-hidden="true">${n}</span>`:l}${e.label} </span><span class="span">${this.renderPosition(e.first)}<span class="arrow" aria-hidden="true">→</span>${this.renderPosition(e.last)} </span>${e.ingresses.length||e.retrogrades.length?c`<span class="chips roxy-chips">${e.ingresses.map(o=>this.renderIngressChip(o))} ${e.retrogrades.map(o=>this.renderRetrogradeChip(o))}</span>`:l}</div>`}renderPosition(e){let{degree:n,minute:o}=Re(e.degreeInSign),s=tt(e.sign),i=H(e,"sign");return c`<span class="pos" title="${i}">${n}${s?c`<span class="sg" aria-hidden="true">${s}</span>`:c`<span class="sg">${i}</span>`}${String(o).padStart(2,"0")}</span>`}renderIngressChip(e){let n=tt(e.sign),o=lt(this.effectiveLang(),e.date);return c`<span class="roxy-chip chip--ingress" aria-label="${this.t("Enters {{sign}} on {{date}}",{sign:e.signLabel,date:o})}"><span aria-hidden="true">→</span>${n?c`<span aria-hidden="true">${n}</span>`:l}${e.signLabel} <span class="chip-date">${o}</span></span>`}renderRetrogradeChip(e){let n=Ce(this.effectiveLang(),e.start,e.end);return c`<span class="roxy-chip chip--retro" data-tone="danger"><span aria-hidden="true">℞</span>${this.t("Retrograde {{range}}",{range:n})}</span>`}renderGrid(e){let n=this.effectiveLang();return c`<table><caption class="roxy-sr-only">${this.t("Every body with its position on each day of the month, as a zodiac sign and a degree.")}</caption><thead><tr><th scope="col" class="day">${this.t("Date")}</th>${e.bodies.map(o=>{let s=Et(o.name);return c`<th scope="col" title="${o.label}">${s?c`<span class="glyph" aria-hidden="true">${s}</span><span class="roxy-sr-only">${o.label}</span>`:o.label}</th>`})}</tr></thead><tbody>${e.rows.map(o=>c`<tr><th scope="row" class="day">${Oe(n,o.date)}</th>${o.cells.map((s,i)=>this.renderCell(s,e.bodies[i],o.date))}</tr>`)}</tbody></table>`}renderCell(e,n,o){if(!e)return c`<td>—</td>`;let s=[e.isRetrograde?"retro":"",n?.ingressDates.has(o)?"ingress":"",n?.stationDates.has(o)?"station":""].filter(Boolean).join(" ");return c`<td class="${s}">${this.renderPosition(e)}${e.isRetrograde?c`<span class="retro-mark" aria-label="${this.t("retrograde")}">℞</span>`:l}</td>`}toViewModel(e){let n=[],o=new Map;for(let d of e.days)for(let a of d.positions){let p=o.get(a.planet);p||(p=[],o.set(a.planet,p),n.push(a.planet)),p.push({date:d.date,p:a})}let s=[];for(let d of n){let a=o.get(d),p=a?.[0],h=a?.[a.length-1];if(!a||!p||!h)continue;let g=[],f=[],b=new Set,k=new Set;for(let B=0;B<a.length;B++){let x=a[B],U=a[B-1];if(!x||(U&&x.p.sign!==U.p.sign&&(g.push({date:x.date,sign:x.p.sign,signLabel:H(x.p,"sign")}),b.add(x.date)),U&&x.p.isRetrograde!==U.p.isRetrograde&&k.add(x.date),!x.p.isRetrograde))continue;let _t=f[f.length-1];_t&&U?.p.isRetrograde?_t.end=x.date:f.push({start:x.date,end:x.date})}s.push({name:d,label:H(h.p,"planet"),first:p.p,last:h.p,ingresses:g,retrogrades:f,ingressDates:b,stationDates:k})}let i=e.days.map(d=>{let a=new Map(d.positions.map(p=>[p.planet,p]));return{date:d.date,cells:s.map(p=>a.get(p.name))}});return{year:e.year,month:e.month,bodies:s,rows:i,signs:this.toSignKey(e)}}toSignKey(e){let n=new Map;for(let s of e.days)for(let i of s.positions){let d=String(i.sign??"").toLowerCase();d&&!n.has(d)&&n.set(d,H(i,"sign"))}let o=[];for(let s of Zt){let i=n.get(s.toLowerCase()),d=tt(s);i&&d&&o.push({sign:s,label:i,glyph:d})}return o}};T.endpoints=Yt,T.styles=[it,v`:host{overflow-x:clip}.wrap{gap:var(--roxy-space-lg);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.wrap>*{min-width:0}h2,h3,p{margin:0}header,section{gap:var(--roxy-space-sm);display:grid}.month{gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}.signkey{gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}.signkey-item{align-items:baseline;gap:var(--roxy-space-xs);color:var(--roxy-muted);font-size:var(--roxy-text-xs);white-space:nowrap;display:inline-flex}.signkey-glyph{color:var(--roxy-fg);font-size:var(--roxy-text-sm)}.track{align-items:center;gap:var(--roxy-space-xs) var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.body-name{align-items:baseline;gap:var(--roxy-space-xs);min-inline-size:16ch;font-weight:var(--roxy-weight-bold);display:inline-flex}.body-name .glyph{color:var(--roxy-accent-ink)}.span{align-items:baseline;gap:var(--roxy-space-xs);color:var(--roxy-secondary);font-variant-numeric:tabular-nums;white-space:nowrap;display:inline-flex}.arrow{color:var(--roxy-muted)}.chips{margin-inline-start:auto}.chip-date{color:var(--roxy-muted)}.scroll{min-width:0;overflow-x:auto}table{font-size:var(--roxy-text-xs)}:is(th,td){white-space:nowrap}thead th .glyph{color:var(--roxy-fg);font-size:var(--roxy-text-sm)}th.day{z-index:1;background:var(--roxy-bg);color:var(--roxy-fg);border-inline-end:1px solid var(--roxy-border);position:sticky;left:0}thead th.day{z-index:2}.sg{margin-inline:calc(var(--roxy-space-unit) / 2);color:var(--roxy-secondary);font-variant-numeric:normal}.retro-mark{font-weight:var(--roxy-weight-bold);margin-inline-start:calc(var(--roxy-space-unit) / 2)}td.retro,td.retro .sg{color:var(--roxy-danger-fg)}td.ingress{box-shadow:inset var(--roxy-line-thick) 0 var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}td.station{border-block-start:var(--roxy-line-thick) solid var(--roxy-danger-fg);font-weight:var(--roxy-weight-bold)}`],u([y({type:String})],T.prototype,"heading",2),T=u([Ae("roxy-ephemeris-table")],T);return Ie(Cn)})();/*! Bundled license information:
|
|
4
4
|
|
|
5
5
|
@lit/reactive-element/css-tag.js:
|
|
6
6
|
(**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
var RoxyUI_fixed_stars=(()=>{var
|
|
2
|
-
\f\r]`,N=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Ct=/-->/g,
|
|
3
|
-
\f\r"'\`<>=]|("|')|))|$)`,"g"),Ot=/'/g,Lt=/"/g,It=/^(?:script|style|textarea|title)$/i,ft=r=>(t,...e)=>({_$litType$:r,strings:t,values:e}),l=ft(1),En=ft(2),$n=ft(3),A=Symbol.for("lit-noChange"),c=Symbol.for("lit-nothing"),Ut=new WeakMap,T=k.createTreeWalker(k,129);function Dt(r,t){if(!gt(r)||!r.hasOwnProperty("raw"))throw Error("invalid template strings array");return Pt!==void 0?Pt.createHTML(t):t}var De=(r,t)=>{let e=r.length-1,n=[],o,i=t===2?"<svg>":t===3?"<math>":"",s=N;for(let d=0;d<e;d++){let a=r[d],y,u,m=-1,b=0;for(;b<a.length&&(s.lastIndex=b,u=s.exec(a),u!==null);)b=s.lastIndex,s===N?u[1]==="!--"?s=Ct:u[1]!==void 0?s=Ft:u[2]!==void 0?(It.test(u[2])&&(o=RegExp("</"+u[2],"g")),s=$):u[3]!==void 0&&(s=$):s===$?u[0]===">"?(s=o??N,m=-1):u[1]===void 0?m=-2:(m=s.lastIndex-u[2].length,y=u[1],s=u[3]===void 0?$:u[3]==='"'?Lt:Ot):s===Lt||s===Ot?s=$:s===Ct||s===Ft?s=N:(s=$,o=void 0);let S=s===$&&r[d+1].startsWith("/>")?" ":"";i+=s===N?a+Me:m>=0?(n.push(y),a.slice(0,m)+Nt+a.slice(m)+w+S):a+w+(m===-2?d:S)}return[Dt(r,i+(r[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),n]},D=class r{constructor({strings:t,_$litType$:e},n){let o;this.parts=[];let i=0,s=0,d=t.length-1,a=this.parts,[y,u]=De(t,e);if(this.el=r.createElement(y,n),T.currentNode=this.el.content,e===2||e===3){let m=this.el.content.firstChild;m.replaceWith(...m.childNodes)}for(;(o=T.nextNode())!==null&&a.length<d;){if(o.nodeType===1){if(o.hasAttributes())for(let m of o.getAttributeNames())if(m.endsWith(Nt)){let b=u[s++],S=o.getAttribute(m).split(w),K=/([.?@])?(.*)/.exec(b);a.push({type:1,index:i,name:K[2],strings:S,ctor:K[1]==="."?pt:K[1]==="?"?ht:K[1]==="@"?ut:C}),o.removeAttribute(m)}else m.startsWith(w)&&(a.push({type:6,index:i}),o.removeAttribute(m));if(It.test(o.tagName)){let m=o.textContent.split(w),b=m.length-1;if(b>0){o.textContent=Y?Y.emptyScript:"";for(let S=0;S<b;S++)o.append(m[S],M()),T.nextNode(),a.push({type:2,index:++i});o.append(m[b],M())}}}else if(o.nodeType===8)if(o.data===Mt)a.push({type:2,index:i});else{let m=-1;for(;(m=o.data.indexOf(w,m+1))!==-1;)a.push({type:7,index:i}),m+=w.length-1}i++}}static createElement(t,e){let n=k.createElement("template");return n.innerHTML=t,n}};function P(r,t,e=r,n){if(t===A)return t;let o=n!==void 0?e._$Co?.[n]:e._$Cl,i=I(t)?void 0:t._$litDirective$;return o?.constructor!==i&&(o?._$AO?.(false),i===void 0?o=void 0:(o=new i(r),o._$AT(r,e,n)),n!==void 0?(e._$Co??=[])[n]=o:e._$Cl=o),o!==void 0&&(t=P(r,o._$AS(r,t.values),o,n)),t}var lt=class{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){let{el:{content:e},parts:n}=this._$AD,o=(t?.creationScope??k).importNode(e,true);T.currentNode=o;let i=T.nextNode(),s=0,d=0,a=n[0];for(;a!==void 0;){if(s===a.index){let y;a.type===2?y=new G(i,i.nextSibling,this,t):a.type===1?y=new a.ctor(i,a.name,a.strings,this,t):a.type===6&&(y=new mt(i,this,t)),this._$AV.push(y),a=n[++d]}s!==a?.index&&(i=T.nextNode(),s++)}return T.currentNode=k,o}p(t){let e=0;for(let n of this._$AV)n!==void 0&&(n.strings!==void 0?(n._$AI(t,n,e),e+=n.strings.length-2):n._$AI(t[e])),e++}},G=class r{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,n,o){this.type=2,this._$AH=c,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=n,this.options=o,this._$Cv=o?.isConnected??true}get parentNode(){let t=this._$AA.parentNode,e=this._$AM;return e!==void 0&&t?.nodeType===11&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=P(this,t,e),I(t)?t===c||t==null||t===""?(this._$AH!==c&&this._$AR(),this._$AH=c):t!==this._$AH&&t!==A&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):Ie(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==c&&I(this._$AH)?this._$AA.nextSibling.data=t:this.T(k.createTextNode(t)),this._$AH=t}$(t){let{values:e,_$litType$:n}=t,o=typeof n=="number"?this._$AC(t):(n.el===void 0&&(n.el=D.createElement(Dt(n.h,n.h[0]),this.options)),n);if(this._$AH?._$AD===o)this._$AH.p(e);else{let i=new lt(o,this),s=i.u(this.options);i.p(e),this.T(s),this._$AH=i}}_$AC(t){let e=Ut.get(t.strings);return e===void 0&&Ut.set(t.strings,e=new D(t)),e}k(t){gt(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,n,o=0;for(let i of t)o===e.length?e.push(n=new r(this.O(M()),this.O(M()),this,this.options)):n=e[o],n._$AI(i),o++;o<e.length&&(this._$AR(n&&n._$AB.nextSibling,o),e.length=o)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(false,true,e);t!==this._$AB;){let n=Rt(t).nextSibling;Rt(t).remove(),t=n}}setConnected(t){this._$AM===void 0&&(this._$Cv=t,this._$AP?.(t))}},C=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,n,o,i){this.type=1,this._$AH=c,this._$AN=void 0,this.element=t,this.name=e,this._$AM=o,this.options=i,n.length>2||n[0]!==""||n[1]!==""?(this._$AH=Array(n.length-1).fill(new String),this.strings=n):this._$AH=c}_$AI(t,e=this,n,o){let i=this.strings,s=false;if(i===void 0)t=P(this,t,e,0),s=!I(t)||t!==this._$AH&&t!==A,s&&(this._$AH=t);else{let d=t,a,y;for(t=i[0],a=0;a<i.length-1;a++)y=P(this,d[n+a],e,a),y===A&&(y=this._$AH[a]),s||=!I(y)||y!==this._$AH[a],y===c?t=c:t!==c&&(t+=(y??"")+i[a+1]),this._$AH[a]=y}s&&!o&&this.j(t)}j(t){t===c?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},pt=class extends C{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===c?void 0:t}},ht=class extends C{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==c)}},ut=class extends C{constructor(t,e,n,o,i){super(t,e,n,o,i),this.type=5}_$AI(t,e=this){if((t=P(this,t,e,0)??c)===A)return;let n=this._$AH,o=t===c&&n!==c||t.capture!==n.capture||t.once!==n.once||t.passive!==n.passive,i=t!==c&&(n===c||o);o&&this.element.removeEventListener(this.name,this,n),i&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){typeof this._$AH=="function"?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}},mt=class{constructor(t,e,n){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=n}get _$AU(){return this._$AM._$AU}_$AI(t){P(this,t)}};var Ge=yt.litHtmlPolyfillSupport;Ge?.(D,G),(yt.litHtmlVersions??=[]).push("3.3.3");var Gt=(r,t,e)=>{let n=e?.renderBefore??t,o=n._$litPart$;if(o===void 0){let i=e?.renderBefore??null;n._$litPart$=o=new G(t.insertBefore(M(),i),i,void 0,e??{})}return o._$AI(r),o};var xt=globalThis,E=class extends v{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){let t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){let e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=Gt(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(true)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(false)}render(){return A}};E._$litElement$=true,E.finalized=true,xt.litElementHydrateSupport?.({LitElement:E});var je=xt.litElementPolyfillSupport;je?.({LitElement:E});(xt.litElementVersions??=[]).push("4.2.2");var jt=[{endpoint:"astrology/fixed-stars",method:"POST"}];function W(r){return r.toLowerCase().replace(/[\s_-]+/g," ").trim()}var Ke=(r,t)=>t?r[W(t)]:void 0;var He={aries:"\u2648",taurus:"\u2649",gemini:"\u264A",cancer:"\u264B",leo:"\u264C",virgo:"\u264D",libra:"\u264E",scorpio:"\u264F",sagittarius:"\u2650",capricorn:"\u2651",aquarius:"\u2652",pisces:"\u2653"},Kt=r=>Ke(He,r);var ze={attribute:true,type:String,converter:U,reflect:false,hasChanged:V},Be=(r=ze,t,e)=>{let{kind:n,metadata:o}=e,i=globalThis.litPropertyMetadata.get(o);if(i===void 0&&globalThis.litPropertyMetadata.set(o,i=new Map),n==="setter"&&((r=Object.create(r)).wrapped=true),i.set(e.name,r),n==="accessor"){let{name:s}=e;return{set(d){let a=t.get.call(this);t.set.call(this,d),this.requestUpdate(s,a,r,true,d)},init(d){return d!==void 0&&this.C(s,void 0,r,d),d}}}if(n==="setter"){let{name:s}=e;return function(d){let a=this[s];t.call(this,d),this.requestUpdate(s,a,r,true,d)}}throw Error("Unsupported decorator location: "+n)};function g(r){return(t,e)=>typeof e=="object"?Be(r,t,e):((n,o,i)=>{let s=o.hasOwnProperty(i);return o.constructor.createProperty(i,n),s?Object.getOwnPropertyDescriptor(o,i):void 0})(r,t,e)}function x(r){return g({...r,state:true,attribute:false})}var _=r=>r??c;var Ht=["de","en","es","fr","hi","pt","ru","tr","zh-Hans","zh-Hant"];function vt(r){if(r.lang)return r.lang;if(typeof document>"u")return;let t=r.closest?.("[lang]")?.getAttribute("lang");return t||document.documentElement.lang||void 0}var qe={tw:"hant",hk:"hant",mo:"hant",cn:"hans",sg:"hans",my:"hans"};function bt(r,t){let e=r.toLowerCase();return t.find(n=>n.toLowerCase()===e)}function zt(r,t=Ht){let e=vt(r);if(!e)return;let n=bt(e,t);if(n)return n;let o=e.toLowerCase().split("-"),i=o[0];if(i==="zh"){let s=o.find(d=>d==="hans"||d==="hant")??qe[o[1]??""];return s?bt(`zh-${s}`,t):void 0}return bt(i,t)}var Ve={Fraunces:["latin","latin-ext"],Jost:["latin","latin-ext","cyrillic"],Geist:["latin","latin-ext","cyrillic"]},St='"Jost", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',Bt='"Geist", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',qt='system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif',J={"fraunces-jost":{name:"Fraunces with Jost",sans:St,display:'"Fraunces", ui-serif, Georgia, Cambria, "Times New Roman", Times, serif'},jost:{name:"Jost",sans:St,display:St},geist:{name:"Geist",sans:Bt,display:Bt},system:{name:"System",sans:qt,display:qt}};function Vt(r){let{sans:t,display:e}=J[r];return Object.keys(Ve).filter(n=>`${t} ${e}`.includes(`"${n}"`))}var Yt="1.2.0";var Ye=/^(.*)\/cdn\/(?:roxy-ui|components\/[\w-]+)\.js$/,We=/^(.*\/dist)\/(?:index|components\/[\w-]+)\.js$/;function Wt(r,t){if(!t)return;let e=new URL(t);if(e.protocol!=="https:"&&e.protocol!=="http:")return;let n=(Ye.exec(e.pathname)??We.exec(e.pathname))?.[1];if(n!==void 0)return e.hostname==="cdn.jsdelivr.net"?`https://cdn.jsdelivr.net/npm/@roxyapi/ui@${r}/dist`:`${e.origin}${n}`}var tn={},Ze="color-mix(in oklab, var(--roxy-accent) 70%, black)",Je="var(--roxy-accent)",Xe="color-mix(in srgb, var(--roxy-accent) 40%, transparent)",Zt=/^#(?:[\da-f]{3}|[\da-f]{6})$/i;function Jt(r){return r!==void 0&&Object.hasOwn(J,r)}function Xt(r){let t=[];return r.brandColor&&Zt.test(r.brandColor)&&t.push(`--roxy-primary:${r.brandColor}`),r.brandAccent&&Zt.test(r.brandAccent)&&t.push(`--roxy-accent:${r.brandAccent}`,`--roxy-accent-ink:light-dark(${Ze},${Je})`,`--roxy-ring:${Xe}`),t.join(";")}function Qt(r,t){if(Jt(t))return t;let e=r.getRootNode();if(("host"in e?e.host:null)?.localName.startsWith("roxy-")||!globalThis.getComputedStyle)return;let o=r.shadowRoot?.firstElementChild,i=o?.localName==="style"?o:null;i?.sheet&&(i.sheet.disabled=true);let s,d,a;try{let y=globalThis.getComputedStyle(r),u=m=>y.getPropertyValue(m).trim();s=u("--roxy-font-sans"),d=u("--roxy-font-display"),a=u("--roxy-font")}finally{i?.sheet&&(i.sheet.disabled=false)}if(!(s||d))return Jt(a)?a:void 0}function te(r){let{sans:t,display:e}=J[r];return`--roxy-font:${r};--roxy-font-sans:${t};--roxy-font-display:${e}`}var Qe=Wt(Yt,globalThis.document?.currentScript?.src||tn.url);function ee(r,t=Qe){if(typeof document>"u"||t===void 0)return;let e=`roxy-ui-font-${r}`;if(Vt(r).length===0||document.getElementById(e))return;let n=document.createElement("link");n.id=e,n.rel="stylesheet",n.href=`${t}/styles/fonts/${r}.css`,document.head.append(n)}var ne='@layer roxy.tokens,roxy.theme;@layer roxy.tokens{:where(:root,:host){color-scheme:light;--roxy-bg: #ffffff;--roxy-fg: #0a0a0a;--roxy-accent: #4a6297;--roxy-success: #16a34a;--roxy-warning: #ea580c;--roxy-danger: #dc2626;--roxy-info: #0284c7;--roxy-accent-ink: color-mix(in oklab, var(--roxy-accent) 70%, black);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, black);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, black);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, black);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, black);--roxy-font: initial;--roxy-font-sans: initial;--roxy-font-mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, "Liberation Mono", monospace;--roxy-text-base: 1rem;--roxy-text-scale: 1.15;--roxy-weight-normal: 400;--roxy-weight-bold: 600;--roxy-leading-tight: 1.25;--roxy-leading-normal: 1.5;--roxy-tracking-tight: -0.01em;--roxy-tracking-normal: 0em;--roxy-space-unit: 0.25rem;--roxy-radius: 6px;--roxy-motion-duration: 200ms;--roxy-motion-easing: cubic-bezier(0.4, 0, 0.2, 1)}:where(:root,:host,[data-theme],.light,.dark){--roxy-surface: var(--roxy-bg);--roxy-primary: var(--roxy-fg);--roxy-secondary: color-mix(in oklab, var(--roxy-fg) 78%, var(--roxy-bg));--roxy-muted: color-mix(in oklab, var(--roxy-fg) 60%, var(--roxy-bg));--roxy-border: color-mix(in oklab, var(--roxy-fg) 14%, var(--roxy-bg));--roxy-ring: color-mix(in srgb, var(--roxy-accent) 40%, transparent);--roxy-heat: var(--roxy-danger);--roxy-font-display: var(--roxy-font-sans);--roxy-text-sm: calc(var(--roxy-text-base) / var(--roxy-text-scale));--roxy-text-xs: calc(var(--roxy-text-sm) / var(--roxy-text-scale));--roxy-text-lg: calc(var(--roxy-text-base) * var(--roxy-text-scale));--roxy-text-xl: calc( var(--roxy-text-lg) * var(--roxy-text-scale) * var(--roxy-text-scale) );--roxy-space-xs: var(--roxy-space-unit);--roxy-space-sm: calc(var(--roxy-space-unit) * 2);--roxy-space-md: calc(var(--roxy-space-unit) * 4);--roxy-space-lg: calc(var(--roxy-space-unit) * 6);--roxy-space-xl: calc(var(--roxy-space-unit) * 10);--roxy-line-thick: calc(var(--roxy-space-unit) / 2);--roxy-touch: calc(var(--roxy-space-unit) * 11);--roxy-radius-sm: calc(var(--roxy-radius) / 2);--roxy-radius-md: var(--roxy-radius);--roxy-radius-lg: calc(var(--roxy-radius) * 5 / 3);--roxy-radius-full: 9999px;--roxy-shadow-sm: none;--roxy-shadow-md: 0 4px 12px color-mix(in srgb, black 10%, transparent);--roxy-shadow-lg: 0 12px 32px color-mix(in srgb, black 18%, transparent)}@media(prefers-color-scheme:dark){:where(:root,:host){color-scheme:dark;--roxy-bg: #0a0a0a;--roxy-fg: #fafafa;--roxy-accent: #92aade;--roxy-success: #22c55e;--roxy-warning: #fb923c;--roxy-danger: #ef4444;--roxy-info: #38bdf8;--roxy-accent-ink: var(--roxy-accent);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, white);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, white);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, white);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, white)}}:where(:root[data-theme=light],[data-theme=light],:root.light,.light,:host([data-theme="light"])){color-scheme:light;--roxy-bg: #ffffff;--roxy-fg: #0a0a0a;--roxy-accent: #4a6297;--roxy-success: #16a34a;--roxy-warning: #ea580c;--roxy-danger: #dc2626;--roxy-info: #0284c7;--roxy-accent-ink: color-mix(in oklab, var(--roxy-accent) 70%, black);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, black);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, black);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, black);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, black)}:where(:root[data-theme=dark],[data-theme=dark],:root.dark,.dark,:host([data-theme="dark"])){color-scheme:dark;--roxy-bg: #0a0a0a;--roxy-fg: #fafafa;--roxy-accent: #92aade;--roxy-success: #22c55e;--roxy-warning: #fb923c;--roxy-danger: #ef4444;--roxy-info: #38bdf8;--roxy-accent-ink: var(--roxy-accent);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, white);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, white);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, white);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, white)}@media(prefers-reduced-motion:reduce){:where(:root,:host){--roxy-motion-duration: 0ms}}}';var X="roxy-ui-tokens";function Q(){if(typeof document>"u")return null;let r=document.getElementById(X);if(r)return r;let t=document.createElement("style");return t.id=X,t.textContent=ne,document.head.prepend(t),t}var re="__ROXY_UI_I18N__";function oe(){let r=globalThis,t=r[re];if(t)return t;let e={catalogs:{},fieldLabels:{},requested:new Set,listeners:new Set};return r[re]=e,e}function en(r,t){return t?r.replace(/\{\{(\w+)\}\}/g,(e,n)=>n in t?String(t[n]??""):e):r}function ie(r,t,e){return en(nn(r,t)??t,e)}function nn(r,t){if(!r)return;let{catalogs:e}=oe(),n=r.toLowerCase();return(e[n]??e[n.split("-")[0]])?.[W(t)]}function se(r){let{listeners:t}=oe();return t.add(r),()=>{t.delete(r)}}var tt=class{constructor(t){this.host=t,t.addController(this)}hostConnected(){this.unsubscribe=se(()=>this.host.requestUpdate())}hostDisconnected(){this.unsubscribe?.(),this.unsubscribe=void 0}};var et=class extends E{constructor(){super();this.translator=(e,n)=>this.t(e,n);new tt(this)}connectedCallback(){super.connectedCallback(),Q()}fontDeclarations(e){let n=Qt(this,e);return n?(ee(n),te(n)):""}renderFontStyle(){let e=this.fontDeclarations();return e?l`<style>:host{${e}}</style>`:c}t(e,n){return ie(this.effectiveLang(),e,n)}effectiveLang(){return vt(this)}};var ae=f`:where([part~=card]){background:var(--roxy-surface);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);box-shadow:var(--roxy-shadow-sm)}:where([part~=card] [part~=card],[part~=card] [part~=reading],[part~=card] .roxy-card){border:0;border-block-start:1px solid var(--roxy-border);box-shadow:none;background:0 0;border-radius:0;padding-inline:0}:host([bare]) [part~=card]{box-shadow:none;background:0 0;border:0;border-radius:0;padding:0}:where(h1,h2){color:var(--roxy-fg);font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);letter-spacing:var(--roxy-tracking-tight);text-wrap:balance}:where(h3,h4,h5,h6){color:var(--roxy-fg);font-size:var(--roxy-text-base);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);letter-spacing:var(--roxy-tracking-normal);text-transform:none}:where(.roxy-label,th,dt){color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-normal);letter-spacing:var(--roxy-tracking-normal);text-transform:none}:where(.roxy-chips){gap:var(--roxy-space-xs);flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}:where(.roxy-chip,.roxy-chips>li){align-items:center;gap:var(--roxy-space-xs);padding:calc(var(--roxy-space-unit) / 2) var(--roxy-space-sm);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-sm);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);line-height:var(--roxy-leading-tight);overflow-wrap:anywhere;background:0 0;max-inline-size:100%;display:inline-flex}:where(.roxy-chip[data-tone=success],.roxy-chips>li[data-tone=success]){color:var(--roxy-success-fg)}:where(.roxy-chip[data-tone=warning],.roxy-chips>li[data-tone=warning]){color:var(--roxy-warning-fg)}:where(.roxy-chip[data-tone=danger],.roxy-chips>li[data-tone=danger]){color:var(--roxy-danger-fg)}:where(.roxy-chip[data-tone=info],.roxy-chips>li[data-tone=info]){color:var(--roxy-info-fg)}:where(table){border-collapse:collapse;font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}:where(th,td){padding:var(--roxy-space-xs) var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);text-align:start;vertical-align:top}:where(summary){cursor:pointer}:where(a,button,summary,input,select,textarea,[tabindex]):focus-visible{outline:var(--roxy-line-thick) solid var(--roxy-ring);outline-offset:var(--roxy-line-thick)}:where(summary:focus-visible){border-radius:var(--roxy-radius-sm)}:where(input,select,textarea,button){font:inherit}:where(input:not([type=checkbox],[type=radio],[type=range]),select,textarea){padding:var(--roxy-space-xs) var(--roxy-space-sm);background:var(--roxy-bg);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md)}`;var rn=f`:host{--roxy-label-col:minmax(0, 25%);--_mask:var(--roxy-surface);font-family:var(--roxy-font-sans);color:var(--roxy-fg);font-size:var(--roxy-text-base);line-height:var(--roxy-leading-normal);animation:roxy-fade-in var(--roxy-motion-duration) var(--roxy-motion-easing) both;background:0 0;display:block;container-type:inline-size}:host([bare]){--_mask:var(--roxy-bg)}:host([hidden]){display:none}: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)}@keyframes roxy-fade-in{0%{transform:translateY(calc(var(--roxy-space-unit) / 2))}to{transform:translateY(0)}}@media (prefers-reduced-motion:reduce){:host{animation:none}}.roxy-skeleton{background:linear-gradient(90deg, var(--roxy-border) 0%, color-mix(in srgb, var(--roxy-border) 60%, transparent) 50%, var(--roxy-border) 100%);border-radius:var(--roxy-radius-md);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);color:var(--roxy-muted);text-align:center;font-size:var(--roxy-text-sm)}.roxy-error{gap:var(--roxy-space-sm);padding:var(--roxy-space-lg);background:var(--roxy-surface);border:1px solid var(--roxy-danger);border-radius:var(--roxy-radius-md);color:var(--roxy-danger-fg);font-size:var(--roxy-text-sm);justify-items:start;display:grid}:host(:focus-within) .roxy-card{outline:var(--roxy-line-thick) solid var(--roxy-ring);outline-offset:var(--roxy-line-thick)}.roxy-attribution{margin-top:var(--roxy-space-sm);font-size:var(--roxy-text-xs);color:var(--roxy-muted);text-align:right}.roxy-attribution a{color:inherit;text-decoration:none}.roxy-attribution a:hover{color:var(--roxy-accent-ink);text-decoration:underline}.roxy-edit-bar{margin-bottom:var(--roxy-space-sm);justify-content:flex-end;display:flex}.roxy-edit{padding:var(--roxy-space-xs) var(--roxy-space-md);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);color:var(--roxy-fg);font-family:inherit;font-size:var(--roxy-text-sm);cursor:pointer;background:0 0}.roxy-edit:hover{border-color:var(--roxy-accent);color:var(--roxy-accent-ink)}.roxy-edit:disabled{cursor:progress;color:var(--roxy-muted)}roxy-endpoint-form+*{margin-top:var(--roxy-space-md)}.roxy-more{justify-items:center;gap:var(--roxy-space-sm);margin-top:var(--roxy-space-md);display:grid}.roxy-more .roxy-edit{min-height:var(--roxy-touch)}:host{font-variant-emoji:text}`,nt=[rn,ae];var on="__cols",sn="__rows";function an(r){return typeof r=="object"&&r!==null&&!Array.isArray(r)}function rt(r){if(Array.isArray(r)){let i=false,s=r.map(d=>{let a=rt(d);return a!==d&&(i=true),a});return i?s:r}if(!an(r))return r;let t=r[on],e=r[sn];if(Array.isArray(t)&&Array.isArray(e)&&Object.keys(r).length===2)return e.map(i=>{let s={};return t.forEach((d,a)=>{s[d]=rt(i[a])}),s});let n=false,o={};for(let[i,s]of Object.entries(r)){let d=rt(s);d!==s&&(n=true),o[i]=d}return n?o:r}function de(r){return rt(r)}function ce(r,t){return r.find(e=>e.attrs&&Object.entries(e.attrs).every(([n,o])=>t[n]===o))??r[0]}var dn="pk_live_YOUR_KEY",le={secret:{reason:"possible-secret-key",message:"Client-side components accept a pk_ publishable key only. Use a publishable key with an origin allowlist, or render server-side."},sample:{reason:"sample-key",message:"Replace the sample key with your own publishable key from your RoxyAPI account."}};function pe(r){if(r)return r===dn?le.sample:r.startsWith("pk_")?void 0:le.secret}function he(r,t,e={}){e.warn&&console.warn(t.message),r.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{reason:t.reason,message:t.message},bubbles:true,composed:true}))}var ue="https://roxyapi.com/api/v2";async function cn(r){try{let t=await r.json();if(t?.error){let e=t.code==="validation_error"&&Array.isArray(t.issues)?t.issues.filter(n=>typeof n.path=="string"&&typeof n.message=="string").map(n=>({path:n.path,message:n.message})):null;return{message:t.error,issues:e?.length?e:null,worded:true,...t.code?{code:t.code}:{}}}}catch{}return{message:`Request failed (${r.status})`,issues:null,worded:false}}var me={fromAttribute:r=>{if(r!=null){try{let t=JSON.parse(r);if(t&&typeof t=="object"&&!Array.isArray(t))return t}catch{}console.warn("[roxy-ui] submit-context must be a JSON object; sending the request without it.")}}},F=class extends Error{constructor(e,n=null,o=true,i,s){super(e);this.issues=n;this.worded=o;this.status=i;this.code=s}};function ye(r){return r.submitUrl?void 0:pe(r.publishableKey)}async function wt(r,t,e){let n=ye(r);if(n)throw new F(n.message);let o=r.submitUrl?await fetch(r.submitUrl,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:ln(t,r.submitContext),signal:e}):await pn(r,t,e);if(!o.ok){let i=await cn(o);throw new F(i.message,i.issues,i.worded,o.status,i.code)}return await o.json()}function ln(r,t){return JSON.stringify(t?{...r,context:t}:r)}function pn(r,t,e){let n=new URL(`${r.baseUrl??ue}${t.path}`,document.baseURI);for(let[i,s]of Object.entries(t.query??{}))s!=null&&n.searchParams.set(i,String(s));let o={Accept:"application/json"};return r.publishableKey&&(o["X-API-Key"]=r.publishableKey),t.body!=null&&(o["Content-Type"]="application/json"),fetch(n,{method:t.method??"GET",headers:o,body:t.body!=null?JSON.stringify(t.body):void 0,signal:e})}var ot=class{constructor(t){this.baseUrl=ue;this.worded=true;this.failure={};this.host=t,t.addController(this)}hostDisconnected(){this.abort?.abort(),this.abort=void 0}async run(t){this.worded=true,this.failure={};let e=ye(this);if(e){this.host.error=e.message,he(this.host,e);return}this.abort?.abort();let n=new AbortController;this.abort=n,this.host.loading=true,this.host.error=null,this.host.issues=null;try{let o=await wt(this,t,n.signal);if(n.signal.aborted)return;this.host.data=o}catch(o){if(n.signal.aborted||o?.name==="AbortError")return;o instanceof F&&(this.host.issues=o.issues,this.failure={status:o.status,code:o.code}),this.worded=o instanceof F&&o.worded,this.host.error=o instanceof Error?o.message:String(o)}finally{this.abort===n&&(this.abort=void 0),n.signal.aborted||(this.host.loading=false)}}};function ge(r,t,e,n=[]){let o={...e},i=`/${r.replace(/^\//,"")}`.replace(/\{([^}]+)\}/g,(y,u)=>{let m=o[u];return delete o[u],encodeURIComponent(String(m??""))}),s=new Set(n),d={},a={};for(let[y,u]of Object.entries(o))u===void 0||u===""||(t==="GET"||s.has(y)?d[y]=u:a[y]=u);return{path:i,method:t,query:d,body:t==="POST"?a:void 0}}function j(){return l`<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 fe=f`summary{list-style:none}summary::-webkit-details-marker{display:none}.roxy-chevron{aspect-ratio:auto;width:.7lh;height:.7lh;color:var(--roxy-muted);transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing);flex-shrink:0}details[open]>summary .roxy-chevron{transform:rotate(180deg)}@media (prefers-reduced-motion:reduce){.roxy-chevron{transition:none}}`;var xe=f`.block{border-top:1px solid var(--roxy-border);padding-top:var(--roxy-space-md)}.block h3{margin:0 0 var(--roxy-space-sm)}.interp-card{padding-block:var(--roxy-space-sm)}.interp-card summary{font-weight:var(--roxy-weight-bold);color:var(--roxy-fg);align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);display:flex}.interp-lead{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;flex:auto;order:1;min-width:0;display:inline-flex}.interp-aside{align-items:center;gap:var(--roxy-space-sm);flex-shrink:0;order:2;display:inline-flex}.roxy-chevron{order:3}.interp-aside small{color:var(--roxy-muted);font-weight:var(--roxy-weight-normal);white-space:nowrap}@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);gap:var(--roxy-space-sm);color:var(--roxy-fg);font-size:var(--roxy-text-sm);line-height:var(--roxy-leading-normal);overflow-wrap:anywhere;display:grid}.interp-body p{margin:0}`;function be(r,t,e){let n=r.filter(o=>!!o.body);return n.length===0?c:l`<section class="block" part="section readings"><h3>${e}</h3>${n.map((o,i)=>l`<details class="interp-card" part="reading" name="${t}" ?open="${i===0}"><summary><span class="interp-lead">${o.label}</span> ${j()} ${o.aside?l`<span class="interp-aside"><small>${o.aside}</small></span>`:c}</summary><div class="interp-body"><p>${o.body}</p>${o.extra??c}</div></details>`)}</section>`}var hn="roxy-data";function un(r){return r.nodeName==="SCRIPT"&&r.getAttribute("type")==="application/json"}var it=class{constructor(t){this.host=t,t.addController(this)}hostConnected(){if(this.host.data!=null)return;let t=this.read();t!==void 0&&(this.host.data=t,this.host.requestUpdate())}read(){let t=this.findInlineScript();return t?this.parse(t.textContent):void 0}findInlineScript(){for(let t of Array.from(this.host.children))if(un(t)&&t.classList.contains(hn))return t;return null}parse(t){if(t?.trim())try{return JSON.parse(t)}catch{return}}};var p=class extends et{constructor(){super();this.data=null;this.endpoint="";this.remember=false;this.hideReadings=false;this.hideSections="";this.loading=false;this.error=null;this.issues=null;this.selfFetched=false;this.editing=false;this.sticky=false;this.hostLoaded=false;this.moreLoading=false;this.moreError=null;this.onMore=async()=>{let e=this.lastRequest,n=this.listKey,o=this.listRows();if(!(!e||!n||!o)){this.moreLoading=true,this.moreError=null;try{let i=await wt(this.fetcher,{...e,query:{...e.query,offset:o.length}});if(this.lastRequest!==e)return;let s=i[n];this.data={...this.data,...i,[n]:[...o,...Array.isArray(s)?s:[]]}}catch(i){this.lastRequest===e&&(this.moreError=i instanceof Error?i.message:String(i))}finally{this.moreLoading=false}}};this.onEdit=()=>{this.editing=true};this.onFormSubmit=e=>{let n=this.selfFetch();if(!n)return;let o=e.detail;this.lastValues=o.values,this.sticky=!!o.sticky,this.selfFetched=true,this.editing=false,this.remember&&this.writeRemembered(o.values),this.fetchFresh(ge(n.endpoint,n.method,{...o.values,...this.ownRequest()},o.queryKeys??[]))};new it(this),this.fetcher=new ot(this)}static{this.styles=[nt]}static{this.endpoints=[]}willUpdate(e){if(e.has("data")&&this.data!=null){let n=de(this.data);n!==this.data&&(this.data=n)}(e.has("publishableKey")||e.has("baseUrl")||e.has("submitUrl")||e.has("submitContext"))&&this.syncFetcher()}syncFetcher(){this.fetcher.publishableKey=this.publishableKey,this.baseUrl&&(this.fetcher.baseUrl=this.baseUrl),this.fetcher.submitUrl=this.submitUrl,this.fetcher.submitContext=this.submitContext}selfFetch(){let e=this.endpoint?{endpoint:this.endpoint,method:"POST"}:this.hostLoaded||!(this.publishableKey||this.submitUrl)?void 0:ce(this.constructor.endpoints,this);return e&&{endpoint:e.endpoint,method:this.method??e.method}}render(){return l`${this.hostStyle()}${this.renderState()}`}drawn(e){try{return this.renderData(e)}catch(n){return console.warn(`[roxy-ui] ${this.localName} could not draw its response`,n),this.dispatchEvent(new CustomEvent("roxy-render-error",{detail:{error:n},bubbles:true,composed:true})),customElements.get("roxy-data")?l`<roxy-data .data="${e}" lang="${_(this.effectiveLang())}"></roxy-data>`:this.renderEmpty()}}hostStyle(){let e=this.hideSections.split(",").map(i=>i.trim().toLowerCase()).filter(i=>/^[a-z][a-z0-9-]*$/.test(i)),n=[Xt(this),this.fontDeclarations(this.font)].filter(Boolean).join(";");if(e.length===0&&!n)return c;let o=(n?`:host{${n}}`:"")+e.map(i=>`[part~="${i}"],roxy-endpoint-form::part(${i}){display:none!important}`).join("");return l`<style>${o}</style>`}ownRequest(){return{}}get failure(){return this.fetcher.failure}renderState(){return this.selfFetch()&&this.sticky&&this.selfFetched&&!this.editing?this.renderWithForm(this.stickyBody()):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()?l`${this.drawn(this.data)}${this.renderAttribution()}`:this.drawn(this.data):this.renderNoData()}renderInterpretation(e,n,o){return this.hideReadings?c:be(e,n,this.t(o??"Reading"))}renderResult(e){let n=l`<div class="roxy-edit-bar" part="edit-bar"><button type="button" class="roxy-edit" @click="${this.onEdit}">${this.t("Edit query")}</button></div>${this.drawn(e)}`;return this.showAttribution()?l`${n}${this.renderAttribution()}`:n}renderWithForm(e){return l`${this.renderForm()}${e}`}stickyBody(){return this.loading?this.renderLoading():this.error!=null?this.issues?c:this.renderErrorBanner(this.error):this.data==null?c:this.showAttribution()?l`${this.drawn(this.data)}${this.renderAttribution()}`:this.drawn(this.data)}renderMore(){let e=this.listRows(),n=this.data?.total;return!this.lastRequest||!e||typeof n!="number"?c:e.length>=n?c:l`<div class="roxy-more" part="more"><button type="button" class="roxy-edit" ?disabled="${this.moreLoading}" aria-busy="${this.moreLoading?"true":"false"}" @click="${this.onMore}">${this.t("Show more")}</button> ${this.moreError?l`<p class="roxy-error" role="alert">${this.t(this.moreError)}</p>`:c}</div>`}listRows(){let e=this.listKey?this.data?.[this.listKey]:void 0;return Array.isArray(e)?e:void 0}fetchFresh(e){return this.lastRequest=e,this.openedRow=void 0,this.openedRowId=void 0,this.moreError=null,this.fetcher.run(e)}load(e){return this.hostLoaded=true,this.syncFetcher(),this.fetchFresh(e)}pickRow(e){this.dispatchEvent(new CustomEvent("roxy-symbol-select",{detail:e,bubbles:true,composed:true})),this.openRow(e.id)}openRow(e){if(!this.rowDetail||!(this.publishableKey||this.submitUrl))return;let n=this.openedRow??document.createElement(this.rowDetail.tag);n.publishableKey=this.publishableKey,n.baseUrl=this.baseUrl,n.submitUrl=this.submitUrl,n.submitContext=this.submitContext,n.hideReadings=this.hideReadings,n.hideSections=this.hideSections;let o=this.effectiveLang();o&&n.setAttribute("lang",o),this.openedRow=n,this.openedRowId=e,n.load({path:`/${this.rowDetail.path.replace("{id}",encodeURIComponent(e))}`,method:"GET",query:{lang:zt(this)}}).then(()=>n.scrollIntoView?.({block:"nearest"}))}showAttribution(){return this.attribution!=null&&this.attribution!=="off"&&this.attribution!=="false"}renderAttribution(){return l`<div class="roxy-attribution" part="attribution"><a href="https://roxyapi.com/?utm_source=widget&utm_medium=embed" target="_blank" rel="noopener">${this.t("Spiritual data by RoxyAPI")}</a></div>`}renderNoData(){return this.selfFetch()?this.renderWithForm(c):this.renderEmpty()}renderForm(){let e=this.selfFetch();return l`<roxy-endpoint-form part="form" exportparts="hint" data-endpoint="${e?.endpoint??""}" method="${e?.method??"POST"}" spec-url="${_(this.specUrl)}" publishable-key="${_(this.publishableKey)}" location-url="${_(this.locationUrl)}" submit-label="${_(this.submitLabel)}" lang="${_(this.effectiveLang())}" .initialValues="${this.formInitialValues()}" .serverIssues="${this.issues}" .apiRoute="${this.fetcher}" .autoload="${!this.selfFetched}" .fullPages="${!!this.listKey}" @roxy-submit="${this.onFormSubmit}"></roxy-endpoint-form>`}formInitialValues(){return this.lastValues??(this.remember?this.readRemembered():void 0)}rememberKey(){return`roxy-ui:form:${this.selfFetch()?.endpoint??""}`}readRemembered(){try{let e=sessionStorage.getItem(this.rememberKey());return e?JSON.parse(e):void 0}catch{return}}writeRemembered(e){try{sessionStorage.setItem(this.rememberKey(),JSON.stringify(e))}catch{}}renderEmpty(){return l`<div class="roxy-empty" role="status" part="empty">${this.t("No data")}</div>`}renderLoading(){return l`<div class="roxy-skeleton" style="height:5lh" role="status" aria-label="${this.t("Loading")}" part="loading"></div>`}renderError(e){let n=!!this.selfFetch();if(n&&this.issues)return this.renderForm();let o=this.renderErrorBanner(e);return n?l`${o}${this.renderForm()}`:o}renderErrorBanner(e){return l`<div class="roxy-error" role="alert" part="error">${!this.fetcher.worded&&this.errorMessage||this.t(e)}</div>`}};h([g({attribute:false})],p.prototype,"data",2),h([g({type:String,attribute:"data-endpoint"})],p.prototype,"endpoint",2),h([g({type:String})],p.prototype,"method",2),h([g({type:String,attribute:"publishable-key"})],p.prototype,"publishableKey",2),h([g({type:String,attribute:"base-url"})],p.prototype,"baseUrl",2),h([g({type:String,attribute:"spec-url"})],p.prototype,"specUrl",2),h([g({type:String,attribute:"submit-url"})],p.prototype,"submitUrl",2),h([g({attribute:"submit-context",converter:me})],p.prototype,"submitContext",2),h([g({type:String,attribute:"location-url"})],p.prototype,"locationUrl",2),h([g({type:Boolean})],p.prototype,"remember",2),h([g({type:Boolean,attribute:"hide-readings",reflect:true})],p.prototype,"hideReadings",2),h([g({type:String,attribute:"hide-sections",reflect:true})],p.prototype,"hideSections",2),h([g({type:String,attribute:"brand-color"})],p.prototype,"brandColor",2),h([g({type:String,attribute:"brand-accent"})],p.prototype,"brandAccent",2),h([g({type:String})],p.prototype,"font",2),h([g({type:String,attribute:"submit-label"})],p.prototype,"submitLabel",2),h([g({type:String,attribute:"error-message"})],p.prototype,"errorMessage",2),h([g({type:String})],p.prototype,"attribution",2),h([x()],p.prototype,"loading",2),h([x()],p.prototype,"error",2),h([x()],p.prototype,"issues",2),h([x()],p.prototype,"selfFetched",2),h([x()],p.prototype,"editing",2),h([x()],p.prototype,"sticky",2),h([x()],p.prototype,"openedRow",2),h([x()],p.prototype,"openedRowId",2),h([x()],p.prototype,"moreLoading",2),h([x()],p.prototype,"moreError",2);var ve=r=>t=>{customElements.get(r)||customElements.define(r,t)};function mn(r){let t=Math.floor(r);return{degree:t,minute:Math.floor((r-t)*60)}}function Se(r){let{degree:t,minute:e}=mn(r);return`${t}\xB0${String(e).padStart(2,"0")}'`}var we=new Map;function yn(r){if(!r)return["en"];let t=we.get(r);if(t)return[t,"en"];let e="en";try{e=Intl.getCanonicalLocales(r)[0]??"en"}catch{e="en"}return we.set(r,e),[e,"en"]}function st(r,t,e=1){return typeof t!="number"||!Number.isFinite(t)?"":t.toLocaleString(yn(r),{maximumFractionDigits:e})}var gn="Localized";function Ee(r,t,e){let n=r,o=n?.[`${t}${gn}`];if(typeof o=="string"&&o!=="")return o;if(e!==void 0)return e;let i=n?.[t];return typeof i=="string"?i:""}var R=class extends p{renderData(t){let e=t.conjunctions??[],n=t.stars??[];return l`<div class="wrap" part="card"><header part="header"><h2>${this.t("Fixed stars")}</h2>${typeof t.orb=="number"?l`<p class="roxy-label">${this.t("Orb")} ${st(this.effectiveLang(),t.orb,1)}°</p>`:c}</header>${t.summary&&!this.hideReadings?l`<p class="summary">${t.summary}</p>`:c} ${e.length?l`<section part="section conjunctions"><h3>${this.t("Conjunctions to the chart")}</h3>${e.map((o,i)=>l`<details class="interp-card" part="reading" name="fixed-star-contacts" ?open="${i===0}"><summary><span class="interp-lead">${this.t("{{point}} conjunct {{star}}",{point:Ee(o,"point"),star:o.star})}</span> ${j()} <span class="interp-aside"><small>${this.t("orb {{value}}\xB0",{value:st(this.effectiveLang(),o.orb,2)})}</small></span></summary>${o.interpretation&&!this.hideReadings?l`<div class="interp-body"><p>${o.interpretation}</p></div>`:c}</details>`)}</section>`:l`<p class="empty-note">${this.t("No star sits within the orb of a natal point.")}</p>`} ${n.length?this.renderCatalog(n):c}</div>`}renderCatalog(t){return l`<details class="catalog"><summary>${j()} ${this.t("Star catalog ({{count}})",{count:t.length})}</summary><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Precessed positions for the chart date")}"><table><caption class="roxy-label">${this.t("Precessed positions for the chart date")}</caption><thead><tr><th scope="col">${this.t("Star")}</th><th scope="col">${this.t("Position")}</th><th scope="col" class="num">${this.t("Mag")}</th><th scope="col">${this.t("Nature")}</th><th scope="col">${this.t("Keywords")}</th></tr></thead><tbody>${t.map(e=>{let n=Kt(e.sign);return l`<tr><td>${e.name}</td><td>${n?l`<span class="sg">${n}</span>`:c}${Se(e.degree)} ${e.sign}</td><td class="num">${st(this.effectiveLang(),e.magnitude,1)}</td><td>${e.nature}</td><td><ul class="kw roxy-chips">${(e.keywords??[]).map(o=>l`<li>${o}</li>`)}</ul></td></tr>`})}</tbody></table></div></details>`}};R.endpoints=jt,R.styles=[nt,fe,xe,f`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}header{gap:var(--roxy-space-xs);display:grid}.summary{font-size:var(--roxy-text-sm)}.empty-note{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}section>h3{margin-block-end:var(--roxy-space-sm)}.interp-lead .point{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.interp-aside small{font-variant-numeric:tabular-nums}.catalog summary{align-items:center;gap:var(--roxy-space-sm);font-weight:var(--roxy-weight-bold);display:flex}.scroll{min-width:0;margin-block-start:var(--roxy-space-sm);overflow-x:auto}table{width:100%}caption{caption-side:top;text-align:start;padding-block-end:var(--roxy-space-xs)}:is(th,td){white-space:nowrap}:is(th,td).num{text-align:end}.sg{color:var(--roxy-secondary);margin-inline-end:var(--roxy-space-xs)}.kw{max-inline-size:32ch}`],R=h([ve("roxy-fixed-stars")],R);return _e(fn)})();/*! Bundled license information:
|
|
1
|
+
var RoxyUI_fixed_stars=(()=>{var z=Object.defineProperty;var Et=Object.getOwnPropertyDescriptor;var $e=Object.getOwnPropertyNames;var Te=Object.prototype.hasOwnProperty;var ke=(r,t)=>{for(var e in t)z(r,e,{get:t[e],enumerable:true})},Ae=(r,t,e,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of $e(t))!Te.call(r,o)&&o!==e&&z(r,o,{get:()=>t[o],enumerable:!(n=Et(t,o))||n.enumerable});return r};var _e=r=>Ae(z({},"__esModule",{value:true}),r),h=(r,t,e,n)=>{for(var o=n>1?void 0:n?Et(t,e):t,i=r.length-1,s;i>=0;i--)(s=r[i])&&(o=(n?s(t,e,o):s(o))||o);return n&&o&&z(t,e,o),o};var fn={};ke(fn,{ROXY_UI_TOKENS_STYLE_ID:()=>X,RoxyFixedStars:()=>P,injectRoxyTokens:()=>Q});var H=globalThis,B=H.ShadowRoot&&(H.ShadyCSS===void 0||H.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,at=Symbol(),$t=new WeakMap,F=class{constructor(t,e,n){if(this._$cssResult$=true,n!==at)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o,e=this.t;if(B&&t===void 0){let n=e!==void 0&&e.length===1;n&&(t=$t.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),n&&$t.set(e,t))}return t}toString(){return this.cssText}},Tt=r=>new F(typeof r=="string"?r:r+"",void 0,at),f=(r,...t)=>{let e=r.length===1?r[0]:t.reduce((n,o,i)=>n+(s=>{if(s._$cssResult$===true)return s.cssText;if(typeof s=="number")return s;throw Error("Value passed to 'css' function must be a 'css' function result: "+s+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(o)+r[i+1],r[0]);return new F(e,r,at)},kt=(r,t)=>{if(B)r.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet);else for(let e of t){let n=document.createElement("style"),o=H.litNonce;o!==void 0&&n.setAttribute("nonce",o),n.textContent=e.cssText,r.appendChild(n)}},dt=B?r=>r:r=>r instanceof CSSStyleSheet?(t=>{let e="";for(let n of t.cssRules)e+=n.cssText;return Tt(e)})(r):r;var{is:Pe,defineProperty:Re,getOwnPropertyDescriptor:Ce,getOwnPropertyNames:Oe,getOwnPropertySymbols:Fe,getPrototypeOf:Le}=Object,q=globalThis,At=q.trustedTypes,Ue=At?At.emptyScript:"",Ne=q.reactiveElementPolyfillSupport,L=(r,t)=>r,U={toAttribute(r,t){switch(t){case Boolean:r=r?Ue:null;break;case Object:case Array:r=r==null?r:JSON.stringify(r)}return r},fromAttribute(r,t){let e=r;switch(t){case Boolean:e=r!==null;break;case Number:e=r===null?null:Number(r);break;case Object:case Array:try{e=JSON.parse(r)}catch{e=null}}return e}},V=(r,t)=>!Pe(r,t),_t={attribute:true,type:String,converter:U,reflect:false,useDefault:false,hasChanged:V};Symbol.metadata??=Symbol("metadata"),q.litPropertyMetadata??=new WeakMap;var v=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,e=_t){if(e.state&&(e.attribute=false),this._$Ei(),this.prototype.hasOwnProperty(t)&&((e=Object.create(e)).wrapped=true),this.elementProperties.set(t,e),!e.noAccessor){let n=Symbol(),o=this.getPropertyDescriptor(t,n,e);o!==void 0&&Re(this.prototype,t,o)}}static getPropertyDescriptor(t,e,n){let{get:o,set:i}=Ce(this.prototype,t)??{get(){return this[e]},set(s){this[e]=s}};return{get:o,set(s){let d=o?.call(this);i?.call(this,s),this.requestUpdate(t,d,n)},configurable:true,enumerable:true}}static getPropertyOptions(t){return this.elementProperties.get(t)??_t}static _$Ei(){if(this.hasOwnProperty(L("elementProperties")))return;let t=Le(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(L("finalized")))return;if(this.finalized=true,this._$Ei(),this.hasOwnProperty(L("properties"))){let e=this.properties,n=[...Oe(e),...Fe(e)];for(let o of n)this.createProperty(o,e[o])}let t=this[Symbol.metadata];if(t!==null){let e=litPropertyMetadata.get(t);if(e!==void 0)for(let[n,o]of e)this.elementProperties.set(n,o)}this._$Eh=new Map;for(let[e,n]of this.elementProperties){let o=this._$Eu(e,n);o!==void 0&&this._$Eh.set(o,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){let e=[];if(Array.isArray(t)){let n=new Set(t.flat(1/0).reverse());for(let o of n)e.unshift(dt(o))}else t!==void 0&&e.push(dt(t));return e}static _$Eu(t,e){let n=e.attribute;return n===false?void 0:typeof n=="string"?n:typeof t=="string"?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=false,this.hasUpdated=false,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise(t=>this.enableUpdating=t),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach(t=>t(this))}addController(t){(this._$EO??=new Set).add(t),this.renderRoot!==void 0&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){let t=new Map,e=this.constructor.elementProperties;for(let n of e.keys())this.hasOwnProperty(n)&&(t.set(n,this[n]),delete this[n]);t.size>0&&(this._$Ep=t)}createRenderRoot(){let t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return kt(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(true),this._$EO?.forEach(t=>t.hostConnected?.())}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach(t=>t.hostDisconnected?.())}attributeChangedCallback(t,e,n){this._$AK(t,n)}_$ET(t,e){let n=this.constructor.elementProperties.get(t),o=this.constructor._$Eu(t,n);if(o!==void 0&&n.reflect===true){let i=(n.converter?.toAttribute!==void 0?n.converter:U).toAttribute(e,n.type);this._$Em=t,i==null?this.removeAttribute(o):this.setAttribute(o,i),this._$Em=null}}_$AK(t,e){let n=this.constructor,o=n._$Eh.get(t);if(o!==void 0&&this._$Em!==o){let i=n.getPropertyOptions(o),s=typeof i.converter=="function"?{fromAttribute:i.converter}:i.converter?.fromAttribute!==void 0?i.converter:U;this._$Em=o;let d=s.fromAttribute(e,i.type);this[o]=d??this._$Ej?.get(o)??d,this._$Em=null}}requestUpdate(t,e,n,o=false,i){if(t!==void 0){let s=this.constructor;if(o===false&&(i=this[t]),n??=s.getPropertyOptions(t),!((n.hasChanged??V)(i,e)||n.useDefault&&n.reflect&&i===this._$Ej?.get(t)&&!this.hasAttribute(s._$Eu(t,n))))return;this.C(t,e,n)}this.isUpdatePending===false&&(this._$ES=this._$EP())}C(t,e,{useDefault:n,reflect:o,wrapped:i},s){n&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,s??e??this[t]),i!==true||s!==void 0)||(this._$AL.has(t)||(this.hasUpdated||n||(e=void 0),this._$AL.set(t,e)),o===true&&this._$Em!==t&&(this._$Eq??=new Set).add(t))}async _$EP(){this.isUpdatePending=true;try{await this._$ES}catch(e){Promise.reject(e)}let t=this.scheduleUpdate();return t!=null&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(let[o,i]of this._$Ep)this[o]=i;this._$Ep=void 0}let n=this.constructor.elementProperties;if(n.size>0)for(let[o,i]of n){let{wrapped:s}=i,d=this[o];s!==true||this._$AL.has(o)||d===void 0||this.C(o,void 0,i,d)}}let t=false,e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach(n=>n.hostUpdate?.()),this.update(e)):this._$EM()}catch(n){throw t=false,this._$EM(),n}t&&this._$AE(e)}willUpdate(t){}_$AE(t){this._$EO?.forEach(e=>e.hostUpdated?.()),this.hasUpdated||(this.hasUpdated=true,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=new Map,this.isUpdatePending=false}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return true}update(t){this._$Eq&&=this._$Eq.forEach(e=>this._$ET(e,this[e])),this._$EM()}updated(t){}firstUpdated(t){}};v.elementStyles=[],v.shadowRootOptions={mode:"open"},v[L("elementProperties")]=new Map,v[L("finalized")]=new Map,Ne?.({ReactiveElement:v}),(q.reactiveElementVersions??=[]).push("2.1.2");var yt=globalThis,Pt=r=>r,Y=yt.trustedTypes,Rt=Y?Y.createPolicy("lit-html",{createHTML:r=>r}):void 0,Nt="$lit$",w=`lit$${Math.random().toFixed(9).slice(2)}$`,Mt="?"+w,Me=`<${Mt}>`,k=document,M=()=>k.createComment(""),I=r=>r===null||typeof r!="object"&&typeof r!="function",gt=Array.isArray,Ie=r=>gt(r)||typeof r?.[Symbol.iterator]=="function",ct=`[
|
|
2
|
+
\f\r]`,N=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Ct=/-->/g,Ot=/>/g,$=RegExp(`>|${ct}(?:([^\\s"'>=/]+)(${ct}*=${ct}*(?:[^
|
|
3
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),Ft=/'/g,Lt=/"/g,It=/^(?:script|style|textarea|title)$/i,ft=r=>(t,...e)=>({_$litType$:r,strings:t,values:e}),l=ft(1),En=ft(2),$n=ft(3),A=Symbol.for("lit-noChange"),c=Symbol.for("lit-nothing"),Ut=new WeakMap,T=k.createTreeWalker(k,129);function Dt(r,t){if(!gt(r)||!r.hasOwnProperty("raw"))throw Error("invalid template strings array");return Rt!==void 0?Rt.createHTML(t):t}var De=(r,t)=>{let e=r.length-1,n=[],o,i=t===2?"<svg>":t===3?"<math>":"",s=N;for(let d=0;d<e;d++){let a=r[d],y,u,m=-1,b=0;for(;b<a.length&&(s.lastIndex=b,u=s.exec(a),u!==null);)b=s.lastIndex,s===N?u[1]==="!--"?s=Ct:u[1]!==void 0?s=Ot:u[2]!==void 0?(It.test(u[2])&&(o=RegExp("</"+u[2],"g")),s=$):u[3]!==void 0&&(s=$):s===$?u[0]===">"?(s=o??N,m=-1):u[1]===void 0?m=-2:(m=s.lastIndex-u[2].length,y=u[1],s=u[3]===void 0?$:u[3]==='"'?Lt:Ft):s===Lt||s===Ft?s=$:s===Ct||s===Ot?s=N:(s=$,o=void 0);let S=s===$&&r[d+1].startsWith("/>")?" ":"";i+=s===N?a+Me:m>=0?(n.push(y),a.slice(0,m)+Nt+a.slice(m)+w+S):a+w+(m===-2?d:S)}return[Dt(r,i+(r[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),n]},D=class r{constructor({strings:t,_$litType$:e},n){let o;this.parts=[];let i=0,s=0,d=t.length-1,a=this.parts,[y,u]=De(t,e);if(this.el=r.createElement(y,n),T.currentNode=this.el.content,e===2||e===3){let m=this.el.content.firstChild;m.replaceWith(...m.childNodes)}for(;(o=T.nextNode())!==null&&a.length<d;){if(o.nodeType===1){if(o.hasAttributes())for(let m of o.getAttributeNames())if(m.endsWith(Nt)){let b=u[s++],S=o.getAttribute(m).split(w),K=/([.?@])?(.*)/.exec(b);a.push({type:1,index:i,name:K[2],strings:S,ctor:K[1]==="."?pt:K[1]==="?"?ht:K[1]==="@"?ut:C}),o.removeAttribute(m)}else m.startsWith(w)&&(a.push({type:6,index:i}),o.removeAttribute(m));if(It.test(o.tagName)){let m=o.textContent.split(w),b=m.length-1;if(b>0){o.textContent=Y?Y.emptyScript:"";for(let S=0;S<b;S++)o.append(m[S],M()),T.nextNode(),a.push({type:2,index:++i});o.append(m[b],M())}}}else if(o.nodeType===8)if(o.data===Mt)a.push({type:2,index:i});else{let m=-1;for(;(m=o.data.indexOf(w,m+1))!==-1;)a.push({type:7,index:i}),m+=w.length-1}i++}}static createElement(t,e){let n=k.createElement("template");return n.innerHTML=t,n}};function R(r,t,e=r,n){if(t===A)return t;let o=n!==void 0?e._$Co?.[n]:e._$Cl,i=I(t)?void 0:t._$litDirective$;return o?.constructor!==i&&(o?._$AO?.(false),i===void 0?o=void 0:(o=new i(r),o._$AT(r,e,n)),n!==void 0?(e._$Co??=[])[n]=o:e._$Cl=o),o!==void 0&&(t=R(r,o._$AS(r,t.values),o,n)),t}var lt=class{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){let{el:{content:e},parts:n}=this._$AD,o=(t?.creationScope??k).importNode(e,true);T.currentNode=o;let i=T.nextNode(),s=0,d=0,a=n[0];for(;a!==void 0;){if(s===a.index){let y;a.type===2?y=new G(i,i.nextSibling,this,t):a.type===1?y=new a.ctor(i,a.name,a.strings,this,t):a.type===6&&(y=new mt(i,this,t)),this._$AV.push(y),a=n[++d]}s!==a?.index&&(i=T.nextNode(),s++)}return T.currentNode=k,o}p(t){let e=0;for(let n of this._$AV)n!==void 0&&(n.strings!==void 0?(n._$AI(t,n,e),e+=n.strings.length-2):n._$AI(t[e])),e++}},G=class r{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,n,o){this.type=2,this._$AH=c,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=n,this.options=o,this._$Cv=o?.isConnected??true}get parentNode(){let t=this._$AA.parentNode,e=this._$AM;return e!==void 0&&t?.nodeType===11&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=R(this,t,e),I(t)?t===c||t==null||t===""?(this._$AH!==c&&this._$AR(),this._$AH=c):t!==this._$AH&&t!==A&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):Ie(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==c&&I(this._$AH)?this._$AA.nextSibling.data=t:this.T(k.createTextNode(t)),this._$AH=t}$(t){let{values:e,_$litType$:n}=t,o=typeof n=="number"?this._$AC(t):(n.el===void 0&&(n.el=D.createElement(Dt(n.h,n.h[0]),this.options)),n);if(this._$AH?._$AD===o)this._$AH.p(e);else{let i=new lt(o,this),s=i.u(this.options);i.p(e),this.T(s),this._$AH=i}}_$AC(t){let e=Ut.get(t.strings);return e===void 0&&Ut.set(t.strings,e=new D(t)),e}k(t){gt(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,n,o=0;for(let i of t)o===e.length?e.push(n=new r(this.O(M()),this.O(M()),this,this.options)):n=e[o],n._$AI(i),o++;o<e.length&&(this._$AR(n&&n._$AB.nextSibling,o),e.length=o)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(false,true,e);t!==this._$AB;){let n=Pt(t).nextSibling;Pt(t).remove(),t=n}}setConnected(t){this._$AM===void 0&&(this._$Cv=t,this._$AP?.(t))}},C=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,n,o,i){this.type=1,this._$AH=c,this._$AN=void 0,this.element=t,this.name=e,this._$AM=o,this.options=i,n.length>2||n[0]!==""||n[1]!==""?(this._$AH=Array(n.length-1).fill(new String),this.strings=n):this._$AH=c}_$AI(t,e=this,n,o){let i=this.strings,s=false;if(i===void 0)t=R(this,t,e,0),s=!I(t)||t!==this._$AH&&t!==A,s&&(this._$AH=t);else{let d=t,a,y;for(t=i[0],a=0;a<i.length-1;a++)y=R(this,d[n+a],e,a),y===A&&(y=this._$AH[a]),s||=!I(y)||y!==this._$AH[a],y===c?t=c:t!==c&&(t+=(y??"")+i[a+1]),this._$AH[a]=y}s&&!o&&this.j(t)}j(t){t===c?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},pt=class extends C{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===c?void 0:t}},ht=class extends C{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==c)}},ut=class extends C{constructor(t,e,n,o,i){super(t,e,n,o,i),this.type=5}_$AI(t,e=this){if((t=R(this,t,e,0)??c)===A)return;let n=this._$AH,o=t===c&&n!==c||t.capture!==n.capture||t.once!==n.once||t.passive!==n.passive,i=t!==c&&(n===c||o);o&&this.element.removeEventListener(this.name,this,n),i&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){typeof this._$AH=="function"?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}},mt=class{constructor(t,e,n){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=n}get _$AU(){return this._$AM._$AU}_$AI(t){R(this,t)}};var Ge=yt.litHtmlPolyfillSupport;Ge?.(D,G),(yt.litHtmlVersions??=[]).push("3.3.3");var Gt=(r,t,e)=>{let n=e?.renderBefore??t,o=n._$litPart$;if(o===void 0){let i=e?.renderBefore??null;n._$litPart$=o=new G(t.insertBefore(M(),i),i,void 0,e??{})}return o._$AI(r),o};var xt=globalThis,E=class extends v{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){let t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){let e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=Gt(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(true)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(false)}render(){return A}};E._$litElement$=true,E.finalized=true,xt.litElementHydrateSupport?.({LitElement:E});var je=xt.litElementPolyfillSupport;je?.({LitElement:E});(xt.litElementVersions??=[]).push("4.2.2");var jt=[{endpoint:"astrology/fixed-stars",method:"POST"}];function W(r){return r.toLowerCase().replace(/[\s_-]+/g," ").trim()}var Ke=(r,t)=>t?r[W(t)]:void 0;var ze={aries:"\u2648",taurus:"\u2649",gemini:"\u264A",cancer:"\u264B",leo:"\u264C",virgo:"\u264D",libra:"\u264E",scorpio:"\u264F",sagittarius:"\u2650",capricorn:"\u2651",aquarius:"\u2652",pisces:"\u2653"},Kt=r=>Ke(ze,r);var He={attribute:true,type:String,converter:U,reflect:false,hasChanged:V},Be=(r=He,t,e)=>{let{kind:n,metadata:o}=e,i=globalThis.litPropertyMetadata.get(o);if(i===void 0&&globalThis.litPropertyMetadata.set(o,i=new Map),n==="setter"&&((r=Object.create(r)).wrapped=true),i.set(e.name,r),n==="accessor"){let{name:s}=e;return{set(d){let a=t.get.call(this);t.set.call(this,d),this.requestUpdate(s,a,r,true,d)},init(d){return d!==void 0&&this.C(s,void 0,r,d),d}}}if(n==="setter"){let{name:s}=e;return function(d){let a=this[s];t.call(this,d),this.requestUpdate(s,a,r,true,d)}}throw Error("Unsupported decorator location: "+n)};function g(r){return(t,e)=>typeof e=="object"?Be(r,t,e):((n,o,i)=>{let s=o.hasOwnProperty(i);return o.constructor.createProperty(i,n),s?Object.getOwnPropertyDescriptor(o,i):void 0})(r,t,e)}function x(r){return g({...r,state:true,attribute:false})}var _=r=>r??c;var zt=["de","en","es","fr","hi","pt","ru","tr","zh-Hans","zh-Hant"];function vt(r){if(r.lang)return r.lang;if(typeof document>"u")return;let t=r.closest?.("[lang]")?.getAttribute("lang");return t||document.documentElement.lang||void 0}var qe={tw:"hant",hk:"hant",mo:"hant",cn:"hans",sg:"hans",my:"hans"};function bt(r,t){let e=r.toLowerCase();return t.find(n=>n.toLowerCase()===e)}function Ht(r,t=zt){let e=vt(r);if(!e)return;let n=bt(e,t);if(n)return n;let o=e.toLowerCase().split("-"),i=o[0];if(i==="zh"){let s=o.find(d=>d==="hans"||d==="hant")??qe[o[1]??""];return s?bt(`zh-${s}`,t):void 0}return bt(i,t)}var Ve={Fraunces:["latin","latin-ext"],Jost:["latin","latin-ext","cyrillic"],Geist:["latin","latin-ext","cyrillic"]},St='"Jost", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',Bt='"Geist", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',qt='system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif',J={"fraunces-jost":{name:"Fraunces with Jost",sans:St,display:'"Fraunces", ui-serif, Georgia, Cambria, "Times New Roman", Times, serif'},jost:{name:"Jost",sans:St,display:St},geist:{name:"Geist",sans:Bt,display:Bt},system:{name:"System",sans:qt,display:qt}};function Vt(r){let{sans:t,display:e}=J[r];return Object.keys(Ve).filter(n=>`${t} ${e}`.includes(`"${n}"`))}var Yt="1.3.0";var Ye=/^(.*)\/cdn\/(?:roxy-ui|components\/[\w-]+)\.js$/,We=/^(.*\/dist)\/(?:index|components\/[\w-]+)\.js$/;function Wt(r,t){if(!t)return;let e=new URL(t);if(e.protocol!=="https:"&&e.protocol!=="http:")return;let n=(Ye.exec(e.pathname)??We.exec(e.pathname))?.[1];if(n!==void 0)return e.hostname==="cdn.jsdelivr.net"?`https://cdn.jsdelivr.net/npm/@roxyapi/ui@${r}/dist`:`${e.origin}${n}`}var tn={},Ze="color-mix(in oklab, var(--roxy-accent) 70%, black)",Je="var(--roxy-accent)",Xe="color-mix(in srgb, var(--roxy-accent) 40%, transparent)",Zt=/^#(?:[\da-f]{3}|[\da-f]{6})$/i;function Jt(r){return r!==void 0&&Object.hasOwn(J,r)}function Xt(r){let t=[];return r.brandColor&&Zt.test(r.brandColor)&&t.push(`--roxy-primary:${r.brandColor}`),r.brandAccent&&Zt.test(r.brandAccent)&&t.push(`--roxy-accent:${r.brandAccent}`,`--roxy-accent-ink:light-dark(${Ze},${Je})`,`--roxy-ring:${Xe}`),t.join(";")}function Qt(r,t){if(Jt(t))return t;let e=r.getRootNode();if(("host"in e?e.host:null)?.localName.startsWith("roxy-")||!globalThis.getComputedStyle)return;let o=r.shadowRoot?.firstElementChild,i=o?.localName==="style"?o:null;i?.sheet&&(i.sheet.disabled=true);let s,d,a;try{let y=globalThis.getComputedStyle(r),u=m=>y.getPropertyValue(m).trim();s=u("--roxy-font-sans"),d=u("--roxy-font-display"),a=u("--roxy-font")}finally{i?.sheet&&(i.sheet.disabled=false)}if(!(s||d))return Jt(a)?a:void 0}function te(r){let{sans:t,display:e}=J[r];return`--roxy-font:${r};--roxy-font-sans:${t};--roxy-font-display:${e}`}var Qe=Wt(Yt,globalThis.document?.currentScript?.src||tn.url);function ee(r,t=Qe){if(typeof document>"u"||t===void 0)return;let e=`roxy-ui-font-${r}`;if(Vt(r).length===0||document.getElementById(e))return;let n=document.createElement("link");n.id=e,n.rel="stylesheet",n.href=`${t}/styles/fonts/${r}.css`,document.head.append(n)}var ne='@layer roxy.tokens,roxy.theme;@layer roxy.tokens{:where(:root,:host){color-scheme:light;--roxy-bg: #ffffff;--roxy-fg: #0a0a0a;--roxy-accent: #4a6297;--roxy-success: #16a34a;--roxy-warning: #ea580c;--roxy-danger: #dc2626;--roxy-info: #0284c7;--roxy-accent-ink: color-mix(in oklab, var(--roxy-accent) 70%, black);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, black);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, black);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, black);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, black);--roxy-font: initial;--roxy-font-sans: initial;--roxy-font-mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, "Liberation Mono", monospace;--roxy-text-base: 1rem;--roxy-text-scale: 1.15;--roxy-weight-normal: 400;--roxy-weight-bold: 600;--roxy-leading-tight: 1.25;--roxy-leading-normal: 1.5;--roxy-tracking-tight: -0.01em;--roxy-tracking-normal: 0em;--roxy-space-unit: 0.25rem;--roxy-radius: 6px;--roxy-motion-duration: 200ms;--roxy-motion-easing: cubic-bezier(0.4, 0, 0.2, 1)}:where(:root,:host,[data-theme],.light,.dark){--roxy-surface: var(--roxy-bg);--roxy-primary: var(--roxy-fg);--roxy-secondary: color-mix(in oklab, var(--roxy-fg) 78%, var(--roxy-bg));--roxy-muted: color-mix(in oklab, var(--roxy-fg) 60%, var(--roxy-bg));--roxy-border: color-mix(in oklab, var(--roxy-fg) 14%, var(--roxy-bg));--roxy-ring: color-mix(in srgb, var(--roxy-accent) 40%, transparent);--roxy-heat: var(--roxy-danger);--roxy-font-display: var(--roxy-font-sans);--roxy-text-sm: calc(var(--roxy-text-base) / var(--roxy-text-scale));--roxy-text-xs: calc(var(--roxy-text-sm) / var(--roxy-text-scale));--roxy-text-lg: calc(var(--roxy-text-base) * var(--roxy-text-scale));--roxy-text-xl: calc( var(--roxy-text-lg) * var(--roxy-text-scale) * var(--roxy-text-scale) );--roxy-space-xs: var(--roxy-space-unit);--roxy-space-sm: calc(var(--roxy-space-unit) * 2);--roxy-space-md: calc(var(--roxy-space-unit) * 4);--roxy-space-lg: calc(var(--roxy-space-unit) * 6);--roxy-space-xl: calc(var(--roxy-space-unit) * 10);--roxy-line-thick: calc(var(--roxy-space-unit) / 2);--roxy-touch: calc(var(--roxy-space-unit) * 11);--roxy-radius-sm: calc(var(--roxy-radius) / 2);--roxy-radius-md: var(--roxy-radius);--roxy-radius-lg: calc(var(--roxy-radius) * 5 / 3);--roxy-radius-full: 9999px;--roxy-shadow-sm: none;--roxy-shadow-md: 0 4px 12px color-mix(in srgb, black 10%, transparent);--roxy-shadow-lg: 0 12px 32px color-mix(in srgb, black 18%, transparent)}@media(prefers-color-scheme:dark){:where(:root,:host){color-scheme:dark;--roxy-bg: #0a0a0a;--roxy-fg: #fafafa;--roxy-accent: #92aade;--roxy-success: #22c55e;--roxy-warning: #fb923c;--roxy-danger: #ef4444;--roxy-info: #38bdf8;--roxy-accent-ink: var(--roxy-accent);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, white);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, white);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, white);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, white)}}:where(:root[data-theme=light],[data-theme=light],:root.light,.light,:host([data-theme="light"])){color-scheme:light;--roxy-bg: #ffffff;--roxy-fg: #0a0a0a;--roxy-accent: #4a6297;--roxy-success: #16a34a;--roxy-warning: #ea580c;--roxy-danger: #dc2626;--roxy-info: #0284c7;--roxy-accent-ink: color-mix(in oklab, var(--roxy-accent) 70%, black);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, black);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, black);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, black);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, black)}:where(:root[data-theme=dark],[data-theme=dark],:root.dark,.dark,:host([data-theme="dark"])){color-scheme:dark;--roxy-bg: #0a0a0a;--roxy-fg: #fafafa;--roxy-accent: #92aade;--roxy-success: #22c55e;--roxy-warning: #fb923c;--roxy-danger: #ef4444;--roxy-info: #38bdf8;--roxy-accent-ink: var(--roxy-accent);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, white);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, white);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, white);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, white)}@media(prefers-reduced-motion:reduce){:where(:root,:host){--roxy-motion-duration: 0ms}}}';var X="roxy-ui-tokens";function Q(){if(typeof document>"u")return null;let r=document.getElementById(X);if(r)return r;let t=document.createElement("style");return t.id=X,t.textContent=ne,document.head.prepend(t),t}var re="__ROXY_UI_I18N__";function oe(){let r=globalThis,t=r[re];if(t)return t;let e={catalogs:{},fieldLabels:{},requested:new Set,listeners:new Set};return r[re]=e,e}function en(r,t){return t?r.replace(/\{\{(\w+)\}\}/g,(e,n)=>n in t?String(t[n]??""):e):r}function ie(r,t,e){return en(nn(r,t)??t,e)}function nn(r,t){if(!r)return;let{catalogs:e}=oe(),n=r.toLowerCase();return(e[n]??e[n.split("-")[0]])?.[W(t)]}function se(r){let{listeners:t}=oe();return t.add(r),()=>{t.delete(r)}}var tt=class{constructor(t){this.host=t,t.addController(this)}hostConnected(){this.unsubscribe=se(()=>this.host.requestUpdate())}hostDisconnected(){this.unsubscribe?.(),this.unsubscribe=void 0}};var et=class extends E{constructor(){super();this.translator=(e,n)=>this.t(e,n);new tt(this)}connectedCallback(){super.connectedCallback(),Q()}fontDeclarations(e){let n=Qt(this,e);return n?(ee(n),te(n)):""}renderFontStyle(){let e=this.fontDeclarations();return e?l`<style>:host{${e}}</style>`:c}t(e,n){return ie(this.effectiveLang(),e,n)}effectiveLang(){return vt(this)}};var ae=f`:where([part~=card]){background:var(--roxy-surface);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);box-shadow:var(--roxy-shadow-sm)}:where([part~=card] [part~=card],[part~=card] [part~=reading],[part~=card] .roxy-card){border:0;border-block-start:1px solid var(--roxy-border);box-shadow:none;background:0 0;border-radius:0;padding-inline:0}:host([bare]) [part~=card]{box-shadow:none;background:0 0;border:0;border-radius:0;padding:0}:where(h1,h2){color:var(--roxy-fg);font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);letter-spacing:var(--roxy-tracking-tight);text-wrap:balance}:where(h3,h4,h5,h6){color:var(--roxy-fg);font-size:var(--roxy-text-base);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);letter-spacing:var(--roxy-tracking-normal);text-transform:none}:where(.roxy-label,th,dt){color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-normal);letter-spacing:var(--roxy-tracking-normal);text-transform:none}:where(.roxy-chips){gap:var(--roxy-space-xs);flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}:where(.roxy-chip,.roxy-chips>li){align-items:center;gap:var(--roxy-space-xs);padding:calc(var(--roxy-space-unit) / 2) var(--roxy-space-sm);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-sm);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);line-height:var(--roxy-leading-tight);overflow-wrap:anywhere;background:0 0;max-inline-size:100%;display:inline-flex}:where(.roxy-chip[data-tone=success],.roxy-chips>li[data-tone=success]){color:var(--roxy-success-fg)}:where(.roxy-chip[data-tone=warning],.roxy-chips>li[data-tone=warning]){color:var(--roxy-warning-fg)}:where(.roxy-chip[data-tone=danger],.roxy-chips>li[data-tone=danger]){color:var(--roxy-danger-fg)}:where(.roxy-chip[data-tone=info],.roxy-chips>li[data-tone=info]){color:var(--roxy-info-fg)}:where(table){border-collapse:collapse;font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}:where(th,td){padding:var(--roxy-space-xs) var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);text-align:start;vertical-align:top}:where(summary){cursor:pointer}:where(a,button,summary,input,select,textarea,[tabindex]):focus-visible{outline:var(--roxy-line-thick) solid var(--roxy-ring);outline-offset:var(--roxy-line-thick)}:where(summary:focus-visible){border-radius:var(--roxy-radius-sm)}:where(input,select,textarea,button){font:inherit}:where(input:not([type=checkbox],[type=radio],[type=range]),select,textarea){padding:var(--roxy-space-xs) var(--roxy-space-sm);background:var(--roxy-bg);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md)}`;var rn=f`:host{--roxy-label-col:minmax(0, 25%);--_mask:var(--roxy-surface);font-family:var(--roxy-font-sans);color:var(--roxy-fg);font-size:var(--roxy-text-base);line-height:var(--roxy-leading-normal);animation:roxy-fade-in var(--roxy-motion-duration) var(--roxy-motion-easing) both;background:0 0;display:block;container-type:inline-size}:host([bare]){--_mask:var(--roxy-bg)}:host([hidden]){display:none}: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)}@keyframes roxy-fade-in{0%{transform:translateY(calc(var(--roxy-space-unit) / 2))}to{transform:translateY(0)}}@media (prefers-reduced-motion:reduce){:host{animation:none}}.roxy-skeleton{background:linear-gradient(90deg, var(--roxy-border) 0%, color-mix(in srgb, var(--roxy-border) 60%, transparent) 50%, var(--roxy-border) 100%);border-radius:var(--roxy-radius-md);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);color:var(--roxy-muted);text-align:center;font-size:var(--roxy-text-sm)}.roxy-error{gap:var(--roxy-space-sm);padding:var(--roxy-space-lg);background:var(--roxy-surface);border:1px solid var(--roxy-danger);border-radius:var(--roxy-radius-md);color:var(--roxy-danger-fg);font-size:var(--roxy-text-sm);justify-items:start;display:grid}:host(:focus-within) .roxy-card{outline:var(--roxy-line-thick) solid var(--roxy-ring);outline-offset:var(--roxy-line-thick)}.roxy-attribution{margin-top:var(--roxy-space-sm);font-size:var(--roxy-text-xs);color:var(--roxy-muted);text-align:right}.roxy-attribution a{color:inherit;text-decoration:none}.roxy-attribution a:hover{color:var(--roxy-accent-ink);text-decoration:underline}.roxy-edit-bar{margin-bottom:var(--roxy-space-sm);justify-content:flex-end;display:flex}.roxy-edit{padding:var(--roxy-space-xs) var(--roxy-space-md);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);color:var(--roxy-fg);font-family:inherit;font-size:var(--roxy-text-sm);cursor:pointer;background:0 0}.roxy-edit:hover{border-color:var(--roxy-accent);color:var(--roxy-accent-ink)}.roxy-edit:disabled{cursor:progress;color:var(--roxy-muted)}roxy-endpoint-form+*{margin-top:var(--roxy-space-md)}.roxy-more{justify-items:center;gap:var(--roxy-space-sm);margin-top:var(--roxy-space-md);display:grid}.roxy-more .roxy-edit{min-height:var(--roxy-touch)}:host{font-variant-emoji:text}`,nt=[rn,ae];var on="__cols",sn="__rows";function an(r){return typeof r=="object"&&r!==null&&!Array.isArray(r)}function rt(r){if(Array.isArray(r)){let i=false,s=r.map(d=>{let a=rt(d);return a!==d&&(i=true),a});return i?s:r}if(!an(r))return r;let t=r[on],e=r[sn];if(Array.isArray(t)&&Array.isArray(e)&&Object.keys(r).length===2)return e.map(i=>{let s={};return t.forEach((d,a)=>{s[d]=rt(i[a])}),s});let n=false,o={};for(let[i,s]of Object.entries(r)){let d=rt(s);d!==s&&(n=true),o[i]=d}return n?o:r}function de(r){return rt(r)}function ce(r,t){return r.find(e=>e.attrs&&Object.entries(e.attrs).every(([n,o])=>t[n]===o))??r[0]}var dn="pk_live_YOUR_KEY",le={secret:{reason:"possible-secret-key",message:"Client-side components accept a pk_ publishable key only. Use a publishable key with an origin allowlist, or render server-side."},sample:{reason:"sample-key",message:"Replace the sample key with your own publishable key from your RoxyAPI account."}};function pe(r){if(r)return r===dn?le.sample:r.startsWith("pk_")?void 0:le.secret}function he(r,t,e={}){e.warn&&console.warn(t.message),r.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{reason:t.reason,message:t.message},bubbles:true,composed:true}))}var ue="https://roxyapi.com/api/v2";async function cn(r){try{let t=await r.json();if(t?.error){let e=t.code==="validation_error"&&Array.isArray(t.issues)?t.issues.filter(n=>typeof n.path=="string"&&typeof n.message=="string").map(n=>({path:n.path,message:n.message})):null;return{message:t.error,issues:e?.length?e:null,worded:true,...t.code?{code:t.code}:{}}}}catch{}return{message:`Request failed (${r.status})`,issues:null,worded:false}}var me={fromAttribute:r=>{if(r!=null){try{let t=JSON.parse(r);if(t&&typeof t=="object"&&!Array.isArray(t))return t}catch{}console.warn("[roxy-ui] submit-context must be a JSON object; sending the request without it.")}}},O=class extends Error{constructor(e,n=null,o=true,i,s){super(e);this.issues=n;this.worded=o;this.status=i;this.code=s}};function ye(r){return r.submitUrl?void 0:pe(r.publishableKey)}async function wt(r,t,e){let n=ye(r);if(n)throw new O(n.message);let o=r.submitUrl?await fetch(r.submitUrl,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:ln(t,r.submitContext),signal:e}):await pn(r,t,e);if(!o.ok){let i=await cn(o);throw new O(i.message,i.issues,i.worded,o.status,i.code)}return await o.json()}function ln(r,t){return JSON.stringify(t?{...r,context:t}:r)}function pn(r,t,e){let n=new URL(`${r.baseUrl??ue}${t.path}`,document.baseURI);for(let[i,s]of Object.entries(t.query??{}))s!=null&&n.searchParams.set(i,String(s));let o={Accept:"application/json"};return r.publishableKey&&(o["X-API-Key"]=r.publishableKey),t.body!=null&&(o["Content-Type"]="application/json"),fetch(n,{method:t.method??"GET",headers:o,body:t.body!=null?JSON.stringify(t.body):void 0,signal:e})}var ot=class{constructor(t){this.baseUrl=ue;this.worded=true;this.failure={};this.host=t,t.addController(this)}hostDisconnected(){this.abort?.abort(),this.abort=void 0}async run(t){this.worded=true,this.failure={};let e=ye(this);if(e){this.host.error=e.message,he(this.host,e);return}this.abort?.abort();let n=new AbortController;this.abort=n,this.host.loading=true,this.host.error=null,this.host.issues=null;try{let o=await wt(this,t,n.signal);if(n.signal.aborted)return;this.host.data=o}catch(o){if(n.signal.aborted||o?.name==="AbortError")return;o instanceof O&&(this.host.issues=o.issues,this.failure={status:o.status,code:o.code}),this.worded=o instanceof O&&o.worded,this.host.error=o instanceof Error?o.message:String(o)}finally{this.abort===n&&(this.abort=void 0),n.signal.aborted||(this.host.loading=false)}}};function ge(r,t,e,n=[]){let o={...e},i=`/${r.replace(/^\//,"")}`.replace(/\{([^}]+)\}/g,(y,u)=>{let m=o[u];return delete o[u],encodeURIComponent(String(m??""))}),s=new Set(n),d={},a={};for(let[y,u]of Object.entries(o))u===void 0||u===""||(t==="GET"||s.has(y)?d[y]=u:a[y]=u);return{path:i,method:t,query:d,body:t==="POST"?a:void 0}}function j(){return l`<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 fe=f`summary{list-style:none}summary::-webkit-details-marker{display:none}.roxy-chevron{aspect-ratio:auto;width:.7lh;height:.7lh;color:var(--roxy-muted);transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing);flex-shrink:0}details[open]>summary .roxy-chevron{transform:rotate(180deg)}@media (prefers-reduced-motion:reduce){.roxy-chevron{transition:none}}`;var xe=f`.block{border-top:1px solid var(--roxy-border);padding-top:var(--roxy-space-md)}.block h3{margin:0 0 var(--roxy-space-sm)}.interp-card{padding-block:var(--roxy-space-sm)}.interp-card summary{font-weight:var(--roxy-weight-bold);color:var(--roxy-fg);align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);display:flex}.interp-lead{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;flex:auto;order:1;min-width:0;display:inline-flex}.interp-aside{align-items:center;gap:var(--roxy-space-sm);flex-shrink:0;order:2;display:inline-flex}.roxy-chevron{order:3}.interp-aside small{color:var(--roxy-muted);font-weight:var(--roxy-weight-normal);white-space:nowrap}@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);gap:var(--roxy-space-sm);color:var(--roxy-fg);font-size:var(--roxy-text-sm);line-height:var(--roxy-leading-normal);overflow-wrap:anywhere;display:grid}.interp-body p{margin:0}`;function be(r,t,e){let n=r.filter(o=>!!o.body);return n.length===0?c:l`<section class="block" part="section readings"><h3>${e}</h3>${n.map((o,i)=>l`<details class="interp-card" part="reading" name="${t}" ?open="${i===0}"><summary><span class="interp-lead">${o.label}</span> ${j()} ${o.aside?l`<span class="interp-aside"><small>${o.aside}</small></span>`:c}</summary><div class="interp-body"><p>${o.body}</p>${o.extra??c}</div></details>`)}</section>`}var hn="roxy-data";function un(r){return r.nodeName==="SCRIPT"&&r.getAttribute("type")==="application/json"}var it=class{constructor(t){this.host=t,t.addController(this)}hostConnected(){if(this.host.data!=null)return;let t=this.read();t!==void 0&&(this.host.data=t,this.host.requestUpdate())}read(){let t=this.findInlineScript();return t?this.parse(t.textContent):void 0}findInlineScript(){for(let t of Array.from(this.host.children))if(un(t)&&t.classList.contains(hn))return t;return null}parse(t){if(t?.trim())try{return JSON.parse(t)}catch{return}}};var p=class extends et{constructor(){super();this.data=null;this.endpoint="";this.remember=false;this.hideReadings=false;this.hideSections="";this.loading=false;this.error=null;this.issues=null;this.selfFetched=false;this.editing=false;this.sticky=false;this.hostLoaded=false;this.moreLoading=false;this.moreError=null;this.onMore=async()=>{let e=this.lastRequest,n=this.listKey,o=this.listRows();if(!(!e||!n||!o)){this.moreLoading=true,this.moreError=null;try{let i=await wt(this.fetcher,{...e,query:{...e.query,offset:o.length}});if(this.lastRequest!==e)return;let s=i[n];this.data={...this.data,...i,[n]:[...o,...Array.isArray(s)?s:[]]}}catch(i){this.lastRequest===e&&(this.moreError=i instanceof Error?i.message:String(i))}finally{this.moreLoading=false}}};this.onEdit=()=>{this.editing=true};this.onFormSubmit=e=>{let n=this.selfFetch();if(!n)return;let o=e.detail;this.lastValues=o.values,this.sticky=!!o.sticky,this.selfFetched=true,this.editing=false,this.remember&&this.writeRemembered(o.values),this.fetchFresh(ge(n.endpoint,n.method,{...o.values,...this.ownRequest()},o.queryKeys??[]))};new it(this),this.fetcher=new ot(this)}static{this.styles=[nt]}static{this.endpoints=[]}willUpdate(e){if(e.has("data")&&this.data!=null){let n=de(this.data);n!==this.data&&(this.data=n)}(e.has("publishableKey")||e.has("baseUrl")||e.has("submitUrl")||e.has("submitContext"))&&this.syncFetcher()}syncFetcher(){this.fetcher.publishableKey=this.publishableKey,this.baseUrl&&(this.fetcher.baseUrl=this.baseUrl),this.fetcher.submitUrl=this.submitUrl,this.fetcher.submitContext=this.submitContext}selfFetch(){let e=this.endpoint?{endpoint:this.endpoint,method:"POST"}:this.hostLoaded||!(this.publishableKey||this.submitUrl)?void 0:ce(this.constructor.endpoints,this);return e&&{endpoint:e.endpoint,method:this.method??e.method}}render(){return l`${this.hostStyle()}${this.renderState()}`}drawn(e){try{return this.renderData(e)}catch(n){return console.warn(`[roxy-ui] ${this.localName} could not draw its response`,n),this.dispatchEvent(new CustomEvent("roxy-render-error",{detail:{error:n},bubbles:true,composed:true})),customElements.get("roxy-data")?l`<roxy-data .data="${e}" lang="${_(this.effectiveLang())}"></roxy-data>`:this.renderEmpty()}}hostStyle(){let e=this.hideSections.split(",").map(i=>i.trim().toLowerCase()).filter(i=>/^[a-z][a-z0-9-]*$/.test(i)),n=[Xt(this),this.fontDeclarations(this.font)].filter(Boolean).join(";");if(e.length===0&&!n)return c;let o=(n?`:host{${n}}`:"")+e.map(i=>`[part~="${i}"],roxy-endpoint-form::part(${i}){display:none!important}`).join("");return l`<style>${o}</style>`}ownRequest(){return{}}get failure(){return this.fetcher.failure}renderState(){return this.selfFetch()&&this.sticky&&this.selfFetched&&!this.editing?this.renderWithForm(this.stickyBody()):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()?l`${this.drawn(this.data)}${this.renderAttribution()}`:this.drawn(this.data):this.renderNoData()}renderInterpretation(e,n,o){return this.hideReadings?c:be(e,n,this.t(o??"Reading"))}renderResult(e){let n=l`<div class="roxy-edit-bar" part="edit-bar"><button type="button" class="roxy-edit" @click="${this.onEdit}">${this.t("Edit query")}</button></div>${this.drawn(e)}`;return this.showAttribution()?l`${n}${this.renderAttribution()}`:n}renderWithForm(e){return l`${this.renderForm()}${e}`}stickyBody(){return this.loading?this.renderLoading():this.error!=null?this.issues?c:this.renderErrorBanner(this.error):this.data==null?c:this.showAttribution()?l`${this.drawn(this.data)}${this.renderAttribution()}`:this.drawn(this.data)}renderMore(){let e=this.listRows(),n=this.data?.total;return!this.lastRequest||!e||typeof n!="number"?c:e.length>=n?c:l`<div class="roxy-more" part="more"><button type="button" class="roxy-edit" ?disabled="${this.moreLoading}" aria-busy="${this.moreLoading?"true":"false"}" @click="${this.onMore}">${this.t("Show more")}</button> ${this.moreError?l`<p class="roxy-error" role="alert">${this.t(this.moreError)}</p>`:c}</div>`}listRows(){let e=this.listKey?this.data?.[this.listKey]:void 0;return Array.isArray(e)?e:void 0}fetchFresh(e){return this.lastRequest=e,this.openedRow=void 0,this.openedRowId=void 0,this.moreError=null,this.fetcher.run(e)}load(e){return this.hostLoaded=true,this.syncFetcher(),this.fetchFresh(e)}pickRow(e){this.dispatchEvent(new CustomEvent("roxy-symbol-select",{detail:e,bubbles:true,composed:true})),this.openRow(e.id)}openRow(e){if(!this.rowDetail||!(this.publishableKey||this.submitUrl))return;let n=this.openedRow??document.createElement(this.rowDetail.tag);n.publishableKey=this.publishableKey,n.baseUrl=this.baseUrl,n.submitUrl=this.submitUrl,n.submitContext=this.submitContext,n.hideReadings=this.hideReadings,n.hideSections=this.hideSections;let o=this.effectiveLang();o&&n.setAttribute("lang",o),this.openedRow=n,this.openedRowId=e,n.load({path:`/${this.rowDetail.path.replace("{id}",encodeURIComponent(e))}`,method:"GET",query:{lang:Ht(this)}}).then(()=>n.scrollIntoView?.({block:"nearest"}))}showAttribution(){return this.attribution!=null&&this.attribution!=="off"&&this.attribution!=="false"}renderAttribution(){return l`<div class="roxy-attribution" part="attribution"><a href="https://roxyapi.com/?utm_source=widget&utm_medium=embed" target="_blank" rel="noopener">${this.t("Spiritual data by RoxyAPI")}</a></div>`}renderNoData(){return this.selfFetch()?this.renderWithForm(c):this.renderEmpty()}renderForm(){let e=this.selfFetch();return l`<roxy-endpoint-form part="form" exportparts="hint" data-endpoint="${e?.endpoint??""}" method="${e?.method??"POST"}" spec-url="${_(this.specUrl)}" publishable-key="${_(this.publishableKey)}" location-url="${_(this.locationUrl)}" submit-label="${_(this.submitLabel)}" lang="${_(this.effectiveLang())}" .initialValues="${this.formInitialValues()}" .serverIssues="${this.issues}" .apiRoute="${this.fetcher}" .autoload="${!this.selfFetched}" .fullPages="${!!this.listKey}" @roxy-submit="${this.onFormSubmit}"></roxy-endpoint-form>`}formInitialValues(){return this.lastValues??(this.remember?this.readRemembered():void 0)}rememberKey(){return`roxy-ui:form:${this.selfFetch()?.endpoint??""}`}readRemembered(){try{let e=sessionStorage.getItem(this.rememberKey());return e?JSON.parse(e):void 0}catch{return}}writeRemembered(e){try{sessionStorage.setItem(this.rememberKey(),JSON.stringify(e))}catch{}}renderEmpty(){return l`<div class="roxy-empty" role="status" part="empty">${this.t("No data")}</div>`}renderLoading(){return l`<div class="roxy-skeleton" style="height:5lh" role="status" aria-label="${this.t("Loading")}" part="loading"></div>`}renderError(e){let n=!!this.selfFetch();if(n&&this.issues)return this.renderForm();let o=this.renderErrorBanner(e);return n?l`${o}${this.renderForm()}`:o}renderErrorBanner(e){return l`<div class="roxy-error" role="alert" part="error">${!this.fetcher.worded&&this.errorMessage||this.t(e)}</div>`}};h([g({attribute:false})],p.prototype,"data",2),h([g({type:String,attribute:"data-endpoint"})],p.prototype,"endpoint",2),h([g({type:String})],p.prototype,"method",2),h([g({type:String,attribute:"publishable-key"})],p.prototype,"publishableKey",2),h([g({type:String,attribute:"base-url"})],p.prototype,"baseUrl",2),h([g({type:String,attribute:"spec-url"})],p.prototype,"specUrl",2),h([g({type:String,attribute:"submit-url"})],p.prototype,"submitUrl",2),h([g({attribute:"submit-context",converter:me})],p.prototype,"submitContext",2),h([g({type:String,attribute:"location-url"})],p.prototype,"locationUrl",2),h([g({type:Boolean})],p.prototype,"remember",2),h([g({type:Boolean,attribute:"hide-readings",reflect:true})],p.prototype,"hideReadings",2),h([g({type:String,attribute:"hide-sections",reflect:true})],p.prototype,"hideSections",2),h([g({type:String,attribute:"brand-color"})],p.prototype,"brandColor",2),h([g({type:String,attribute:"brand-accent"})],p.prototype,"brandAccent",2),h([g({type:String})],p.prototype,"font",2),h([g({type:String,attribute:"submit-label"})],p.prototype,"submitLabel",2),h([g({type:String,attribute:"error-message"})],p.prototype,"errorMessage",2),h([g({type:String})],p.prototype,"attribution",2),h([x()],p.prototype,"loading",2),h([x()],p.prototype,"error",2),h([x()],p.prototype,"issues",2),h([x()],p.prototype,"selfFetched",2),h([x()],p.prototype,"editing",2),h([x()],p.prototype,"sticky",2),h([x()],p.prototype,"openedRow",2),h([x()],p.prototype,"openedRowId",2),h([x()],p.prototype,"moreLoading",2),h([x()],p.prototype,"moreError",2);var ve=r=>t=>{customElements.get(r)||customElements.define(r,t)};function mn(r){let t=Math.floor(r);return{degree:t,minute:Math.floor((r-t)*60)}}function Se(r){let{degree:t,minute:e}=mn(r);return`${t}\xB0${String(e).padStart(2,"0")}'`}var we=new Map;function yn(r){if(!r)return["en"];let t=we.get(r);if(t)return[t,"en"];let e="en";try{e=Intl.getCanonicalLocales(r)[0]??"en"}catch{e="en"}return we.set(r,e),[e,"en"]}function st(r,t,e=1){return typeof t!="number"||!Number.isFinite(t)?"":t.toLocaleString(yn(r),{maximumFractionDigits:e})}var gn="Localized";function Ee(r,t,e){let n=r,o=n?.[`${t}${gn}`];if(typeof o=="string"&&o!=="")return o;if(e!==void 0)return e;let i=n?.[t];return typeof i=="string"?i:""}var P=class extends p{renderData(t){let e=t.conjunctions??[],n=t.stars??[];return l`<div class="wrap" part="card"><header part="header"><h2>${this.t("Fixed stars")}</h2>${typeof t.orb=="number"?l`<p class="roxy-label">${this.t("Orb")} ${st(this.effectiveLang(),t.orb,1)}°</p>`:c}</header>${t.summary&&!this.hideReadings?l`<p class="summary">${t.summary}</p>`:c} ${e.length?l`<section part="section conjunctions"><h3>${this.t("Conjunctions to the chart")}</h3>${e.map((o,i)=>l`<details class="interp-card" part="reading" name="fixed-star-contacts" ?open="${i===0}"><summary><span class="interp-lead">${this.t("{{point}} conjunct {{star}}",{point:Ee(o,"point"),star:o.star})}</span> ${j()} <span class="interp-aside"><small>${this.t("orb {{value}}\xB0",{value:st(this.effectiveLang(),o.orb,2)})}</small></span></summary>${o.interpretation&&!this.hideReadings?l`<div class="interp-body"><p>${o.interpretation}</p></div>`:c}</details>`)}</section>`:l`<p class="empty-note">${this.t("No star sits within the orb of a natal point.")}</p>`} ${n.length?this.renderCatalog(n):c}</div>`}renderCatalog(t){return l`<details class="catalog"><summary>${j()} ${this.t("Star catalog ({{count}})",{count:t.length})}</summary><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Precessed positions for the chart date")}"><table><caption class="roxy-label">${this.t("Precessed positions for the chart date")}</caption><thead><tr><th scope="col">${this.t("Star")}</th><th scope="col">${this.t("Position")}</th><th scope="col" class="num">${this.t("Mag")}</th><th scope="col">${this.t("Nature")}</th><th scope="col">${this.t("Keywords")}</th></tr></thead><tbody>${t.map(e=>{let n=Kt(e.sign);return l`<tr><td>${e.name}</td><td>${n?l`<span class="sg">${n}</span>`:c}${Se(e.degree)} ${e.sign}</td><td class="num">${st(this.effectiveLang(),e.magnitude,1)}</td><td>${e.nature}</td><td><ul class="kw roxy-chips">${(e.keywords??[]).map(o=>l`<li>${o}</li>`)}</ul></td></tr>`})}</tbody></table></div></details>`}};P.endpoints=jt,P.styles=[nt,fe,xe,f`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}header{gap:var(--roxy-space-xs);display:grid}.summary{font-size:var(--roxy-text-sm)}.empty-note{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}section>h3{margin-block-end:var(--roxy-space-sm)}.interp-lead .point{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.interp-aside small{font-variant-numeric:tabular-nums}.catalog summary{align-items:center;gap:var(--roxy-space-sm);font-weight:var(--roxy-weight-bold);display:flex}.scroll{min-width:0;margin-block-start:var(--roxy-space-sm);overflow-x:auto}table{width:100%}caption{caption-side:top;text-align:start;padding-block-end:var(--roxy-space-xs)}:is(th,td){white-space:nowrap}:is(th,td).num{text-align:end}.sg{color:var(--roxy-secondary);margin-inline-end:var(--roxy-space-xs)}.kw{max-inline-size:32ch}`],P=h([ve("roxy-fixed-stars")],P);return _e(fn)})();/*! Bundled license information:
|
|
4
4
|
|
|
5
5
|
@lit/reactive-element/css-tag.js:
|
|
6
6
|
(**
|