@roxyapi/ui 1.6.2 → 1.7.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.
Files changed (189) hide show
  1. package/components-catalog.json +1 -1
  2. package/dist/cdn/components/almanac-day.js +1 -1
  3. package/dist/cdn/components/angel-number-card.js +1 -1
  4. package/dist/cdn/components/angel-number-lookup.js +1 -1
  5. package/dist/cdn/components/arudha-padas.js +2 -2
  6. package/dist/cdn/components/ashtakavarga-grid.js +2 -2
  7. package/dist/cdn/components/aspects-table.js +2 -2
  8. package/dist/cdn/components/astrocartography-map.js +3 -3
  9. package/dist/cdn/components/bazi-chart.js +2 -2
  10. package/dist/cdn/components/bhav-chalit-table.js +1 -1
  11. package/dist/cdn/components/bhava-bala-table.js +3 -3
  12. package/dist/cdn/components/biorhythm-chart.js +1 -1
  13. package/dist/cdn/components/bodygraph.js +1 -1
  14. package/dist/cdn/components/chara-karakas.js +2 -2
  15. package/dist/cdn/components/choghadiya-grid.js +1 -1
  16. package/dist/cdn/components/compatibility-card.js +2 -2
  17. package/dist/cdn/components/compound-number.js +2 -2
  18. package/dist/cdn/components/crystal-card.js +1 -1
  19. package/dist/cdn/components/crystal-grid.js +1 -1
  20. package/dist/cdn/components/dasha-timeline.js +1 -1
  21. package/dist/cdn/components/data.js +1 -1
  22. package/dist/cdn/components/divisional-chart.js +1 -1
  23. package/dist/cdn/components/dosha-card.js +2 -2
  24. package/dist/cdn/components/dosha-constitution.js +2 -2
  25. package/dist/cdn/components/dream-card.js +1 -1
  26. package/dist/cdn/components/dream-search.js +2 -2
  27. package/dist/cdn/components/endpoint-form.js +2 -2
  28. package/dist/cdn/components/ephemeris-table.js +1 -1
  29. package/dist/cdn/components/fixed-stars.js +1 -1
  30. package/dist/cdn/components/flying-star-chart.js +2 -2
  31. package/dist/cdn/components/forecast-digest.js +1 -1
  32. package/dist/cdn/components/forecast-timeline.js +2 -2
  33. package/dist/cdn/components/gematria.js +1 -1
  34. package/dist/cdn/components/gochara-table.js +2 -2
  35. package/dist/cdn/components/guna-milan.js +3 -3
  36. package/dist/cdn/components/hd-connection.js +1 -1
  37. package/dist/cdn/components/hd-penta.js +15 -15
  38. package/dist/cdn/components/hd-type-card.js +1 -1
  39. package/dist/cdn/components/hd-variables.js +1 -1
  40. package/dist/cdn/components/heliacal-table.js +1 -1
  41. package/dist/cdn/components/hexagram.js +1 -1
  42. package/dist/cdn/components/hora-table.js +1 -1
  43. package/dist/cdn/components/horoscope-card.js +3 -3
  44. package/dist/cdn/components/kp-chart.js +3 -3
  45. package/dist/cdn/components/kp-finance-card.js +2 -2
  46. package/dist/cdn/components/kp-planets-table.js +3 -3
  47. package/dist/cdn/components/kp-ruling-planets.js +1 -1
  48. package/dist/cdn/components/kua-card.js +3 -3
  49. package/dist/cdn/components/local-space-compass.js +1 -1
  50. package/dist/cdn/components/location-search.js +1 -1
  51. package/dist/cdn/components/luck-pillars.js +3 -3
  52. package/dist/cdn/components/mayan-day-sign.js +1 -1
  53. package/dist/cdn/components/moon-phase.js +2 -2
  54. package/dist/cdn/components/nakshatra-card.js +1 -1
  55. package/dist/cdn/components/natal-chart.js +1 -1
  56. package/dist/cdn/components/numerology-card.js +2 -2
  57. package/dist/cdn/components/panchang-table.js +2 -2
  58. package/dist/cdn/components/positions-table.js +1 -1
  59. package/dist/cdn/components/profection-card.js +1 -1
  60. package/dist/cdn/components/reference-card.js +1 -1
  61. package/dist/cdn/components/relocation-wheel.js +1 -1
  62. package/dist/cdn/components/report.js +1 -1
  63. package/dist/cdn/components/shadbala-table.js +1 -1
  64. package/dist/cdn/components/synastry-chart.js +1 -1
  65. package/dist/cdn/components/tarot-card.js +2 -2
  66. package/dist/cdn/components/tarot-catalog.js +2 -2
  67. package/dist/cdn/components/tarot-spread.js +3 -3
  68. package/dist/cdn/components/transit-wheel.js +1 -1
  69. package/dist/cdn/components/transits-table.js +2 -2
  70. package/dist/cdn/components/upagraha-table.js +3 -3
  71. package/dist/cdn/components/vastu-mandala.js +2 -2
  72. package/dist/cdn/components/vedic-aspects.js +2 -2
  73. package/dist/cdn/components/vedic-daily.js +2 -2
  74. package/dist/cdn/components/vedic-kundli.js +1 -1
  75. package/dist/cdn/components/vedic-planets-table.js +1 -1
  76. package/dist/cdn/components/western-planets-table.js +1 -1
  77. package/dist/cdn/components/yoga-list.js +2 -2
  78. package/dist/cdn/components/zodiac-card.js +2 -2
  79. package/dist/cdn/locales/de.js +1 -1
  80. package/dist/cdn/locales/es.js +1 -1
  81. package/dist/cdn/locales/fr.js +1 -1
  82. package/dist/cdn/locales/hi.js +1 -1
  83. package/dist/cdn/locales/pt.js +1 -1
  84. package/dist/cdn/locales/ru.js +1 -1
  85. package/dist/cdn/locales/tr.js +1 -1
  86. package/dist/cdn/roxy-ui.js +85 -85
  87. package/dist/charts.cjs +13 -13
  88. package/dist/charts.js +10 -10
  89. package/dist/components/almanac-day.js +1 -1
  90. package/dist/components/angel-number-card.js +1 -1
  91. package/dist/components/angel-number-lookup.js +1 -1
  92. package/dist/components/arudha-padas.js +1 -1
  93. package/dist/components/ashtakavarga-grid.js +1 -1
  94. package/dist/components/aspects-table.js +1 -1
  95. package/dist/components/astrocartography-map.js +2 -2
  96. package/dist/components/bazi-chart.js +1 -1
  97. package/dist/components/bhav-chalit-table.js +1 -1
  98. package/dist/components/bhava-bala-table.js +1 -1
  99. package/dist/components/biorhythm-chart.js +1 -1
  100. package/dist/components/bodygraph.js +1 -1
  101. package/dist/components/chara-karakas.js +1 -1
  102. package/dist/components/choghadiya-grid.js +1 -1
  103. package/dist/components/compatibility-card.js +1 -1
  104. package/dist/components/compound-number.js +1 -1
  105. package/dist/components/crystal-card.js +1 -1
  106. package/dist/components/crystal-grid.js +1 -1
  107. package/dist/components/dasha-timeline.js +1 -1
  108. package/dist/components/data.js +1 -1
  109. package/dist/components/divisional-chart.js +1 -1
  110. package/dist/components/dosha-card.js +1 -1
  111. package/dist/components/dosha-constitution.js +1 -1
  112. package/dist/components/dream-card.js +1 -1
  113. package/dist/components/dream-search.js +1 -1
  114. package/dist/components/endpoint-form.js +1 -1
  115. package/dist/components/ephemeris-table.js +1 -1
  116. package/dist/components/fixed-stars.js +1 -1
  117. package/dist/components/flying-star-chart.js +1 -1
  118. package/dist/components/forecast-digest.js +1 -1
  119. package/dist/components/forecast-timeline.js +1 -1
  120. package/dist/components/gematria.js +1 -1
  121. package/dist/components/gochara-table.js +1 -1
  122. package/dist/components/guna-milan.js +1 -1
  123. package/dist/components/hd-connection.js +1 -1
  124. package/dist/components/hd-penta.js +1 -1
  125. package/dist/components/hd-type-card.js +1 -1
  126. package/dist/components/hd-variables.js +1 -1
  127. package/dist/components/heliacal-table.js +1 -1
  128. package/dist/components/hexagram.js +1 -1
  129. package/dist/components/hora-table.js +1 -1
  130. package/dist/components/horoscope-card.d.ts +24 -8
  131. package/dist/components/horoscope-card.js +1 -1
  132. package/dist/components/kp-chart.js +1 -1
  133. package/dist/components/kp-finance-card.js +1 -1
  134. package/dist/components/kp-planets-table.js +1 -1
  135. package/dist/components/kp-ruling-planets.js +1 -1
  136. package/dist/components/kua-card.js +1 -1
  137. package/dist/components/local-space-compass.js +2 -2
  138. package/dist/components/location-search.js +1 -1
  139. package/dist/components/luck-pillars.js +1 -1
  140. package/dist/components/mayan-day-sign.js +1 -1
  141. package/dist/components/moon-phase.js +1 -1
  142. package/dist/components/nakshatra-card.js +1 -1
  143. package/dist/components/natal-chart.js +4 -4
  144. package/dist/components/numerology-card.js +1 -1
  145. package/dist/components/panchang-table.js +1 -1
  146. package/dist/components/positions-table.js +1 -1
  147. package/dist/components/profection-card.js +1 -1
  148. package/dist/components/reference-card.js +1 -1
  149. package/dist/components/relocation-wheel.js +1 -1
  150. package/dist/components/report.js +1 -1
  151. package/dist/components/shadbala-table.js +1 -1
  152. package/dist/components/synastry-chart.js +1 -1
  153. package/dist/components/tarot-card.js +1 -1
  154. package/dist/components/tarot-catalog.js +1 -1
  155. package/dist/components/tarot-spread.d.ts +2 -0
  156. package/dist/components/tarot-spread.js +1 -1
  157. package/dist/components/transit-wheel.js +8 -8
  158. package/dist/components/transits-table.js +1 -1
  159. package/dist/components/upagraha-table.js +1 -1
  160. package/dist/components/vastu-mandala.js +2 -2
  161. package/dist/components/vedic-aspects.js +1 -1
  162. package/dist/components/vedic-daily.js +1 -1
  163. package/dist/components/vedic-kundli.js +2 -2
  164. package/dist/components/vedic-planets-table.js +1 -1
  165. package/dist/components/western-planets-table.js +1 -1
  166. package/dist/components/yoga-list.js +1 -1
  167. package/dist/components/zodiac-card.js +1 -1
  168. package/dist/forms.json +1 -1
  169. package/dist/i18n/chrome-strings.d.ts +1 -1
  170. package/dist/index.cjs +111 -111
  171. package/dist/index.js +91 -91
  172. package/dist/locales/de.js +1 -1
  173. package/dist/locales/es.js +1 -1
  174. package/dist/locales/fr.js +1 -1
  175. package/dist/locales/hi.js +1 -1
  176. package/dist/locales/pt.js +1 -1
  177. package/dist/locales/ru.js +1 -1
  178. package/dist/locales/tr.js +1 -1
  179. package/dist/manifest.json +1 -1
  180. package/dist/schemas/get--astrology-horoscope-sign-daily.json +1 -1
  181. package/dist/schemas/get--astrology-horoscope-sign-monthly.json +1 -1
  182. package/dist/schemas/get--astrology-horoscope-sign-weekly.json +1 -1
  183. package/dist/types/types.gen.d.ts +344 -51
  184. package/dist/utils/base-element.d.ts +2 -1
  185. package/dist/utils/format.d.ts +2 -0
  186. package/dist/utils/interp-accordion.d.ts +2 -2
  187. package/dist/utils/tarot.d.ts +2 -0
  188. package/dist/version.d.ts +1 -1
  189. package/package.json +1 -1
@@ -1,3 +1,3 @@
1
- var RoxyUI_endpoint_form=(()=>{var Q=Object.defineProperty;var it=Object.getOwnPropertyDescriptor;var Cr=Object.getOwnPropertyNames;var Or=Object.prototype.hasOwnProperty;var Fr=(n,t)=>{for(var e in t)Q(n,e,{get:t[e],enumerable:true})},Dr=(n,t,e,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of Cr(t))!Or.call(n,i)&&i!==e&&Q(n,i,{get:()=>t[i],enumerable:!(r=it(t,i))||r.enumerable});return n};var Pr=n=>Dr(Q({},"__esModule",{value:true}),n),y=(n,t,e,r)=>{for(var i=r>1?void 0:r?it(t,e):t,o=n.length-1,s;o>=0;o--)(s=n[o])&&(i=(r?s(t,e,i):s(i))||i);return r&&i&&Q(t,e,i),i};var Rn={};Fr(Rn,{ROXY_UI_TOKENS_STYLE_ID:()=>me,RoxyEndpointForm:()=>g,injectRoxyTokens:()=>ge,resetSpecCache:()=>wn});var ee=globalThis,te=ee.ShadowRoot&&(ee.ShadyCSS===void 0||ee.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,Le=Symbol(),ot=new WeakMap,j=class{constructor(t,e,r){if(this._$cssResult$=true,r!==Le)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(te&&t===void 0){let r=e!==void 0&&e.length===1;r&&(t=ot.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),r&&ot.set(e,t))}return t}toString(){return this.cssText}},st=n=>new j(typeof n=="string"?n:n+"",void 0,Le),$=(n,...t)=>{let e=n.length===1?n[0]:t.reduce((r,i,o)=>r+(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.")})(i)+n[o+1],n[0]);return new j(e,n,Le)},at=(n,t)=>{if(te)n.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet);else for(let e of t){let r=document.createElement("style"),i=ee.litNonce;i!==void 0&&r.setAttribute("nonce",i),r.textContent=e.cssText,n.appendChild(r)}},Ce=te?n=>n:n=>n instanceof CSSStyleSheet?(t=>{let e="";for(let r of t.cssRules)e+=r.cssText;return st(e)})(n):n;var{is:Ur,defineProperty:Ir,getOwnPropertyDescriptor:Nr,getOwnPropertyNames:Mr,getOwnPropertySymbols:qr,getPrototypeOf:Hr}=Object,re=globalThis,lt=re.trustedTypes,zr=lt?lt.emptyScript:"",Br=re.reactiveElementPolyfillSupport,G=(n,t)=>n,Y={toAttribute(n,t){switch(t){case Boolean:n=n?zr:null;break;case Object:case Array:n=n==null?n:JSON.stringify(n)}return n},fromAttribute(n,t){let e=n;switch(t){case Boolean:e=n!==null;break;case Number:e=n===null?null:Number(n);break;case Object:case Array:try{e=JSON.parse(n)}catch{e=null}}return e}},ne=(n,t)=>!Ur(n,t),ct={attribute:true,type:String,converter:Y,reflect:false,useDefault:false,hasChanged:ne};Symbol.metadata??=Symbol("metadata"),re.litPropertyMetadata??=new WeakMap;var T=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=ct){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 r=Symbol(),i=this.getPropertyDescriptor(t,r,e);i!==void 0&&Ir(this.prototype,t,i)}}static getPropertyDescriptor(t,e,r){let{get:i,set:o}=Nr(this.prototype,t)??{get(){return this[e]},set(s){this[e]=s}};return{get:i,set(s){let a=i?.call(this);o?.call(this,s),this.requestUpdate(t,a,r)},configurable:true,enumerable:true}}static getPropertyOptions(t){return this.elementProperties.get(t)??ct}static _$Ei(){if(this.hasOwnProperty(G("elementProperties")))return;let t=Hr(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(G("finalized")))return;if(this.finalized=true,this._$Ei(),this.hasOwnProperty(G("properties"))){let e=this.properties,r=[...Mr(e),...qr(e)];for(let i of r)this.createProperty(i,e[i])}let t=this[Symbol.metadata];if(t!==null){let e=litPropertyMetadata.get(t);if(e!==void 0)for(let[r,i]of e)this.elementProperties.set(r,i)}this._$Eh=new Map;for(let[e,r]of this.elementProperties){let i=this._$Eu(e,r);i!==void 0&&this._$Eh.set(i,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){let e=[];if(Array.isArray(t)){let r=new Set(t.flat(1/0).reverse());for(let i of r)e.unshift(Ce(i))}else t!==void 0&&e.push(Ce(t));return e}static _$Eu(t,e){let r=e.attribute;return r===false?void 0:typeof r=="string"?r: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 r of e.keys())this.hasOwnProperty(r)&&(t.set(r,this[r]),delete this[r]);t.size>0&&(this._$Ep=t)}createRenderRoot(){let t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return at(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,r){this._$AK(t,r)}_$ET(t,e){let r=this.constructor.elementProperties.get(t),i=this.constructor._$Eu(t,r);if(i!==void 0&&r.reflect===true){let o=(r.converter?.toAttribute!==void 0?r.converter:Y).toAttribute(e,r.type);this._$Em=t,o==null?this.removeAttribute(i):this.setAttribute(i,o),this._$Em=null}}_$AK(t,e){let r=this.constructor,i=r._$Eh.get(t);if(i!==void 0&&this._$Em!==i){let o=r.getPropertyOptions(i),s=typeof o.converter=="function"?{fromAttribute:o.converter}:o.converter?.fromAttribute!==void 0?o.converter:Y;this._$Em=i;let a=s.fromAttribute(e,o.type);this[i]=a??this._$Ej?.get(i)??a,this._$Em=null}}requestUpdate(t,e,r,i=false,o){if(t!==void 0){let s=this.constructor;if(i===false&&(o=this[t]),r??=s.getPropertyOptions(t),!((r.hasChanged??ne)(o,e)||r.useDefault&&r.reflect&&o===this._$Ej?.get(t)&&!this.hasAttribute(s._$Eu(t,r))))return;this.C(t,e,r)}this.isUpdatePending===false&&(this._$ES=this._$EP())}C(t,e,{useDefault:r,reflect:i,wrapped:o},s){r&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,s??e??this[t]),o!==true||s!==void 0)||(this._$AL.has(t)||(this.hasUpdated||r||(e=void 0),this._$AL.set(t,e)),i===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[i,o]of this._$Ep)this[i]=o;this._$Ep=void 0}let r=this.constructor.elementProperties;if(r.size>0)for(let[i,o]of r){let{wrapped:s}=o,a=this[i];s!==true||this._$AL.has(i)||a===void 0||this.C(i,void 0,o,a)}}let t=false,e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach(r=>r.hostUpdate?.()),this.update(e)):this._$EM()}catch(r){throw t=false,this._$EM(),r}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){}};T.elementStyles=[],T.shadowRootOptions={mode:"open"},T[G("elementProperties")]=new Map,T[G("finalized")]=new Map,Br?.({ReactiveElement:T}),(re.reactiveElementVersions??=[]).push("2.1.2");var Fe=globalThis,dt=n=>n,ie=Fe.trustedTypes,ut=ie?ie.createPolicy("lit-html",{createHTML:n=>n}):void 0,De="$lit$",L=`lit$${Math.random().toFixed(9).slice(2)}$`,Pe="?"+L,Kr=`<${Pe}>`,N=document,Z=()=>N.createComment(""),W=n=>n===null||typeof n!="object"&&typeof n!="function",Ue=Array.isArray,yt=n=>Ue(n)||typeof n?.[Symbol.iterator]=="function",Oe=`[
1
+ var RoxyUI_endpoint_form=(()=>{var Q=Object.defineProperty;var it=Object.getOwnPropertyDescriptor;var Lr=Object.getOwnPropertyNames;var Or=Object.prototype.hasOwnProperty;var Fr=(n,t)=>{for(var e in t)Q(n,e,{get:t[e],enumerable:true})},Dr=(n,t,e,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of Lr(t))!Or.call(n,i)&&i!==e&&Q(n,i,{get:()=>t[i],enumerable:!(r=it(t,i))||r.enumerable});return n};var Pr=n=>Dr(Q({},"__esModule",{value:true}),n),y=(n,t,e,r)=>{for(var i=r>1?void 0:r?it(t,e):t,o=n.length-1,s;o>=0;o--)(s=n[o])&&(i=(r?s(t,e,i):s(i))||i);return r&&i&&Q(t,e,i),i};var Rn={};Fr(Rn,{ROXY_UI_TOKENS_STYLE_ID:()=>me,RoxyEndpointForm:()=>g,injectRoxyTokens:()=>ge,resetSpecCache:()=>wn});var ee=globalThis,te=ee.ShadowRoot&&(ee.ShadyCSS===void 0||ee.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,Ce=Symbol(),ot=new WeakMap,j=class{constructor(t,e,r){if(this._$cssResult$=true,r!==Ce)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(te&&t===void 0){let r=e!==void 0&&e.length===1;r&&(t=ot.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),r&&ot.set(e,t))}return t}toString(){return this.cssText}},st=n=>new j(typeof n=="string"?n:n+"",void 0,Ce),$=(n,...t)=>{let e=n.length===1?n[0]:t.reduce((r,i,o)=>r+(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.")})(i)+n[o+1],n[0]);return new j(e,n,Ce)},at=(n,t)=>{if(te)n.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet);else for(let e of t){let r=document.createElement("style"),i=ee.litNonce;i!==void 0&&r.setAttribute("nonce",i),r.textContent=e.cssText,n.appendChild(r)}},Le=te?n=>n:n=>n instanceof CSSStyleSheet?(t=>{let e="";for(let r of t.cssRules)e+=r.cssText;return st(e)})(n):n;var{is:Ur,defineProperty:Ir,getOwnPropertyDescriptor:Nr,getOwnPropertyNames:Mr,getOwnPropertySymbols:qr,getPrototypeOf:Hr}=Object,re=globalThis,lt=re.trustedTypes,zr=lt?lt.emptyScript:"",Br=re.reactiveElementPolyfillSupport,G=(n,t)=>n,Y={toAttribute(n,t){switch(t){case Boolean:n=n?zr:null;break;case Object:case Array:n=n==null?n:JSON.stringify(n)}return n},fromAttribute(n,t){let e=n;switch(t){case Boolean:e=n!==null;break;case Number:e=n===null?null:Number(n);break;case Object:case Array:try{e=JSON.parse(n)}catch{e=null}}return e}},ne=(n,t)=>!Ur(n,t),dt={attribute:true,type:String,converter:Y,reflect:false,useDefault:false,hasChanged:ne};Symbol.metadata??=Symbol("metadata"),re.litPropertyMetadata??=new WeakMap;var T=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=dt){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 r=Symbol(),i=this.getPropertyDescriptor(t,r,e);i!==void 0&&Ir(this.prototype,t,i)}}static getPropertyDescriptor(t,e,r){let{get:i,set:o}=Nr(this.prototype,t)??{get(){return this[e]},set(s){this[e]=s}};return{get:i,set(s){let a=i?.call(this);o?.call(this,s),this.requestUpdate(t,a,r)},configurable:true,enumerable:true}}static getPropertyOptions(t){return this.elementProperties.get(t)??dt}static _$Ei(){if(this.hasOwnProperty(G("elementProperties")))return;let t=Hr(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(G("finalized")))return;if(this.finalized=true,this._$Ei(),this.hasOwnProperty(G("properties"))){let e=this.properties,r=[...Mr(e),...qr(e)];for(let i of r)this.createProperty(i,e[i])}let t=this[Symbol.metadata];if(t!==null){let e=litPropertyMetadata.get(t);if(e!==void 0)for(let[r,i]of e)this.elementProperties.set(r,i)}this._$Eh=new Map;for(let[e,r]of this.elementProperties){let i=this._$Eu(e,r);i!==void 0&&this._$Eh.set(i,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){let e=[];if(Array.isArray(t)){let r=new Set(t.flat(1/0).reverse());for(let i of r)e.unshift(Le(i))}else t!==void 0&&e.push(Le(t));return e}static _$Eu(t,e){let r=e.attribute;return r===false?void 0:typeof r=="string"?r: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 r of e.keys())this.hasOwnProperty(r)&&(t.set(r,this[r]),delete this[r]);t.size>0&&(this._$Ep=t)}createRenderRoot(){let t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return at(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,r){this._$AK(t,r)}_$ET(t,e){let r=this.constructor.elementProperties.get(t),i=this.constructor._$Eu(t,r);if(i!==void 0&&r.reflect===true){let o=(r.converter?.toAttribute!==void 0?r.converter:Y).toAttribute(e,r.type);this._$Em=t,o==null?this.removeAttribute(i):this.setAttribute(i,o),this._$Em=null}}_$AK(t,e){let r=this.constructor,i=r._$Eh.get(t);if(i!==void 0&&this._$Em!==i){let o=r.getPropertyOptions(i),s=typeof o.converter=="function"?{fromAttribute:o.converter}:o.converter?.fromAttribute!==void 0?o.converter:Y;this._$Em=i;let a=s.fromAttribute(e,o.type);this[i]=a??this._$Ej?.get(i)??a,this._$Em=null}}requestUpdate(t,e,r,i=false,o){if(t!==void 0){let s=this.constructor;if(i===false&&(o=this[t]),r??=s.getPropertyOptions(t),!((r.hasChanged??ne)(o,e)||r.useDefault&&r.reflect&&o===this._$Ej?.get(t)&&!this.hasAttribute(s._$Eu(t,r))))return;this.C(t,e,r)}this.isUpdatePending===false&&(this._$ES=this._$EP())}C(t,e,{useDefault:r,reflect:i,wrapped:o},s){r&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,s??e??this[t]),o!==true||s!==void 0)||(this._$AL.has(t)||(this.hasUpdated||r||(e=void 0),this._$AL.set(t,e)),i===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[i,o]of this._$Ep)this[i]=o;this._$Ep=void 0}let r=this.constructor.elementProperties;if(r.size>0)for(let[i,o]of r){let{wrapped:s}=o,a=this[i];s!==true||this._$AL.has(i)||a===void 0||this.C(i,void 0,o,a)}}let t=false,e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach(r=>r.hostUpdate?.()),this.update(e)):this._$EM()}catch(r){throw t=false,this._$EM(),r}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){}};T.elementStyles=[],T.shadowRootOptions={mode:"open"},T[G("elementProperties")]=new Map,T[G("finalized")]=new Map,Br?.({ReactiveElement:T}),(re.reactiveElementVersions??=[]).push("2.1.2");var Fe=globalThis,ct=n=>n,ie=Fe.trustedTypes,ut=ie?ie.createPolicy("lit-html",{createHTML:n=>n}):void 0,De="$lit$",C=`lit$${Math.random().toFixed(9).slice(2)}$`,Pe="?"+C,Kr=`<${Pe}>`,N=document,Z=()=>N.createComment(""),W=n=>n===null||typeof n!="object"&&typeof n!="function",Ue=Array.isArray,yt=n=>Ue(n)||typeof n?.[Symbol.iterator]=="function",Oe=`[
2
2
  \f\r]`,V=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,pt=/-->/g,ht=/>/g,U=RegExp(`>|${Oe}(?:([^\\s"'>=/]+)(${Oe}*=${Oe}*(?:[^
3
- \f\r"'\`<>=]|("|')|))|$)`,"g"),ft=/'/g,mt=/"/g,xt=/^(?:script|style|textarea|title)$/i,Ie=n=>(t,...e)=>({_$litType$:n,strings:t,values:e}),h=Ie(1),Dn=Ie(2),Pn=Ie(3),A=Symbol.for("lit-noChange"),p=Symbol.for("lit-nothing"),gt=new WeakMap,I=N.createTreeWalker(N,129);function bt(n,t){if(!Ue(n)||!n.hasOwnProperty("raw"))throw Error("invalid template strings array");return ut!==void 0?ut.createHTML(t):t}var vt=(n,t)=>{let e=n.length-1,r=[],i,o=t===2?"<svg>":t===3?"<math>":"",s=V;for(let a=0;a<e;a++){let c=n[a],u,d,m=-1,l=0;for(;l<c.length&&(s.lastIndex=l,d=s.exec(c),d!==null);)l=s.lastIndex,s===V?d[1]==="!--"?s=pt:d[1]!==void 0?s=ht:d[2]!==void 0?(xt.test(d[2])&&(i=RegExp("</"+d[2],"g")),s=U):d[3]!==void 0&&(s=U):s===U?d[0]===">"?(s=i??V,m=-1):d[1]===void 0?m=-2:(m=s.lastIndex-d[2].length,u=d[1],s=d[3]===void 0?U:d[3]==='"'?mt:ft):s===mt||s===ft?s=U:s===pt||s===ht?s=V:(s=U,i=void 0);let f=s===U&&n[a+1].startsWith("/>")?" ":"";o+=s===V?c+Kr:m>=0?(r.push(u),c.slice(0,m)+De+c.slice(m)+L+f):c+L+(m===-2?a:f)}return[bt(n,o+(n[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),r]},J=class n{constructor({strings:t,_$litType$:e},r){let i;this.parts=[];let o=0,s=0,a=t.length-1,c=this.parts,[u,d]=vt(t,e);if(this.el=n.createElement(u,r),I.currentNode=this.el.content,e===2||e===3){let m=this.el.content.firstChild;m.replaceWith(...m.childNodes)}for(;(i=I.nextNode())!==null&&c.length<a;){if(i.nodeType===1){if(i.hasAttributes())for(let m of i.getAttributeNames())if(m.endsWith(De)){let l=d[s++],f=i.getAttribute(m).split(L),x=/([.?@])?(.*)/.exec(l);c.push({type:1,index:o,name:x[2],strings:f,ctor:x[1]==="."?se:x[1]==="?"?ae:x[1]==="@"?le:q}),i.removeAttribute(m)}else m.startsWith(L)&&(c.push({type:6,index:o}),i.removeAttribute(m));if(xt.test(i.tagName)){let m=i.textContent.split(L),l=m.length-1;if(l>0){i.textContent=ie?ie.emptyScript:"";for(let f=0;f<l;f++)i.append(m[f],Z()),I.nextNode(),c.push({type:2,index:++o});i.append(m[l],Z())}}}else if(i.nodeType===8)if(i.data===Pe)c.push({type:2,index:o});else{let m=-1;for(;(m=i.data.indexOf(L,m+1))!==-1;)c.push({type:7,index:o}),m+=L.length-1}o++}}static createElement(t,e){let r=N.createElement("template");return r.innerHTML=t,r}};function M(n,t,e=n,r){if(t===A)return t;let i=r!==void 0?e._$Co?.[r]:e._$Cl,o=W(t)?void 0:t._$litDirective$;return i?.constructor!==o&&(i?._$AO?.(false),o===void 0?i=void 0:(i=new o(n),i._$AT(n,e,r)),r!==void 0?(e._$Co??=[])[r]=i:e._$Cl=i),i!==void 0&&(t=M(n,i._$AS(n,t.values),i,r)),t}var oe=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:r}=this._$AD,i=(t?.creationScope??N).importNode(e,true);I.currentNode=i;let o=I.nextNode(),s=0,a=0,c=r[0];for(;c!==void 0;){if(s===c.index){let u;c.type===2?u=new B(o,o.nextSibling,this,t):c.type===1?u=new c.ctor(o,c.name,c.strings,this,t):c.type===6&&(u=new ce(o,this,t)),this._$AV.push(u),c=r[++a]}s!==c?.index&&(o=I.nextNode(),s++)}return I.currentNode=N,i}p(t){let e=0;for(let r of this._$AV)r!==void 0&&(r.strings!==void 0?(r._$AI(t,r,e),e+=r.strings.length-2):r._$AI(t[e])),e++}},B=class n{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,r,i){this.type=2,this._$AH=p,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=r,this.options=i,this._$Cv=i?.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=M(this,t,e),W(t)?t===p||t==null||t===""?(this._$AH!==p&&this._$AR(),this._$AH=p):t!==this._$AH&&t!==A&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):yt(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!==p&&W(this._$AH)?this._$AA.nextSibling.data=t:this.T(N.createTextNode(t)),this._$AH=t}$(t){let{values:e,_$litType$:r}=t,i=typeof r=="number"?this._$AC(t):(r.el===void 0&&(r.el=J.createElement(bt(r.h,r.h[0]),this.options)),r);if(this._$AH?._$AD===i)this._$AH.p(e);else{let o=new oe(i,this),s=o.u(this.options);o.p(e),this.T(s),this._$AH=o}}_$AC(t){let e=gt.get(t.strings);return e===void 0&&gt.set(t.strings,e=new J(t)),e}k(t){Ue(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,r,i=0;for(let o of t)i===e.length?e.push(r=new n(this.O(Z()),this.O(Z()),this,this.options)):r=e[i],r._$AI(o),i++;i<e.length&&(this._$AR(r&&r._$AB.nextSibling,i),e.length=i)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(false,true,e);t!==this._$AB;){let r=dt(t).nextSibling;dt(t).remove(),t=r}}setConnected(t){this._$AM===void 0&&(this._$Cv=t,this._$AP?.(t))}},q=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,r,i,o){this.type=1,this._$AH=p,this._$AN=void 0,this.element=t,this.name=e,this._$AM=i,this.options=o,r.length>2||r[0]!==""||r[1]!==""?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=p}_$AI(t,e=this,r,i){let o=this.strings,s=false;if(o===void 0)t=M(this,t,e,0),s=!W(t)||t!==this._$AH&&t!==A,s&&(this._$AH=t);else{let a=t,c,u;for(t=o[0],c=0;c<o.length-1;c++)u=M(this,a[r+c],e,c),u===A&&(u=this._$AH[c]),s||=!W(u)||u!==this._$AH[c],u===p?t=p:t!==p&&(t+=(u??"")+o[c+1]),this._$AH[c]=u}s&&!i&&this.j(t)}j(t){t===p?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},se=class extends q{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===p?void 0:t}},ae=class extends q{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==p)}},le=class extends q{constructor(t,e,r,i,o){super(t,e,r,i,o),this.type=5}_$AI(t,e=this){if((t=M(this,t,e,0)??p)===A)return;let r=this._$AH,i=t===p&&r!==p||t.capture!==r.capture||t.once!==r.once||t.passive!==r.passive,o=t!==p&&(r===p||i);i&&this.element.removeEventListener(this.name,this,r),o&&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)}},ce=class{constructor(t,e,r){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(t){M(this,t)}},$t={M:De,P:L,A:Pe,C:1,L:vt,R:oe,D:yt,V:M,I:B,H:q,N:ae,U:le,B:se,F:ce},jr=Fe.litHtmlPolyfillSupport;jr?.(J,B),(Fe.litHtmlVersions??=[]).push("3.3.3");var kt=(n,t,e)=>{let r=e?.renderBefore??t,i=r._$litPart$;if(i===void 0){let o=e?.renderBefore??null;r._$litPart$=i=new B(t.insertBefore(Z(),o),o,void 0,e??{})}return i._$AI(n),i};var Ne=globalThis,F=class extends T{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=kt(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(true)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(false)}render(){return A}};F._$litElement$=true,F.finalized=true,Ne.litElementHydrateSupport?.({LitElement:F});var Gr=Ne.litElementPolyfillSupport;Gr?.({LitElement:F});(Ne.litElementVersions??=[]).push("4.2.2");var Yr={attribute:true,type:String,converter:Y,reflect:false,hasChanged:ne},Vr=(n=Yr,t,e)=>{let{kind:r,metadata:i}=e,o=globalThis.litPropertyMetadata.get(i);if(o===void 0&&globalThis.litPropertyMetadata.set(i,o=new Map),r==="setter"&&((n=Object.create(n)).wrapped=true),o.set(e.name,n),r==="accessor"){let{name:s}=e;return{set(a){let c=t.get.call(this);t.set.call(this,a),this.requestUpdate(s,c,n,true,a)},init(a){return a!==void 0&&this.C(s,void 0,n,a),a}}}if(r==="setter"){let{name:s}=e;return function(a){let c=this[s];t.call(this,a),this.requestUpdate(s,c,n,true,a)}}throw Error("Unsupported decorator location: "+r)};function w(n){return(t,e)=>typeof e=="object"?Vr(n,t,e):((r,i,o)=>{let s=i.hasOwnProperty(o);return i.constructor.createProperty(o,r),s?Object.getOwnPropertyDescriptor(i,o):void 0})(n,t,e)}function E(n){return w({...n,state:true,attribute:false})}var k=n=>n??p;var H={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},wt=n=>(...t)=>({_$litDirective$:n,values:t}),ue=class{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,r){this._$Ct=t,this._$AM=e,this._$Ci=r}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}};var{I:Ei}=$t;var At=n=>n.strings===void 0;var Zr={},St=(n,t=Zr)=>n._$AH=t;var _t=wt(class extends ue{constructor(n){if(super(n),n.type!==H.PROPERTY&&n.type!==H.ATTRIBUTE&&n.type!==H.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!At(n))throw Error("`live` bindings can only contain a single expression")}render(n){return n}update(n,[t]){if(t===A||t===p)return t;let e=n.element,r=n.name;if(n.type===H.PROPERTY){if(t===e[r])return A}else if(n.type===H.BOOLEAN_ATTRIBUTE){if(!!t===e.hasAttribute(r))return A}else if(n.type===H.ATTRIBUTE&&e.getAttribute(r)===t+"")return A;return St(n),t}});var C={accent:"Accent color",afterSunset:"Born after sunset",allowDuplicates:"Allow duplicate cards",allowReversals:"Allow reversed cards",angelDating:"How the name of the day is dated",annualFromYear:"Annual pillars from year",annualYears:"Years of annual pillars",approximateDate:"Approximate date",aspectTypes:"Aspect types",atbashOutput:"AtBash and Albam output",avasthaInfo:"Include avastha details",avoidAnimal:"Avoid clashes with",ayadiText:"Ayadi text family",ayanamsaValue:"Custom ayanamsa value",birthData:"Birth details",birthDate:"Birth date",birthLatitude:"Birth latitude",birthLongitude:"Birth longitude",birthTime:"Birth time",ciphers:"Ciphers to return",colors:"Brand colors",context:"Where you saw it",coordinateSystem:"Coordinate system",correlation:"Correlation constant",count:"How many",currentYear:"Current year",cuts:"Cut corners",dasha:"Dasha lords",datetime:"Date and time",dayBoundary:"Day boundary",depth:"Depth, north to south",directionScheme:"Direction reading",division:"Divisional chart",domainWeights:"Domain weights",door:"Door coordinates",doorPosition:"Door position along the side",doshaClock:"How the dosha periods are cut",endDate:"End date",endDatetime:"End date and time",expression:"Expression number",extensions:"Extended corners",facing:"Facing direction",facingDegrees:"Facing degrees",family:"Yoga family",firstName:"First name",firstNameHebrew:"First name in Hebrew",font:"Typeface",footer:"Footer line",fullName:"Full name",gainHouses:"Gain houses",grid:"Mandala grid",hastaInches:"Length of one hasta in inches",horaryNumber:"Horary number",hourClock:"Hour clock",houseSystem:"House system",id:"ID",include:"Additional bodies",includeMatches:"Include equal value matches",interpretation:"Position meaning",intervalMinutes:"Interval in minutes",isLeapMonth:"Leap month",iso2:"Country code",kua:"Kua number",lang:"Language",latinCiphers:"Also score the Latin ciphers",leapDayPolicy:"Where 29 February falls",letter:"Starting letter",letterAttribution:"Letter attribution reading",lifePath:"Life Path number",limit:"Results per page",lines:"Line pattern",logo:"Logo URL",lossHouses:"Loss houses",lunarDay:"Lunar day",lunarMonth:"Lunar month",lunarYear:"Lunar year",members:"Group members",minSignificance:"Minimum significance",minStrength:"Minimum strength",misparGadol:"Mispar gadol method",modernPlanets:"Include modern planets",moonWindows:"Moon windows",muhurtaText:"Muhurta text",nameHebrew:"Name in Hebrew",natalChart:"Natal chart",nodeType:"Lunar node type",offset:"Results to skip",polygon:"Outline",positions:"Spread positions",primary:"Primary color",q:"Search",question:"Your question",readings:"Include readings",relocationLatitude:"Relocation latitude",relocationLongitude:"Relocation longitude",returnDate:"Return date",returnYear:"Return year",ritucharyaScheme:"Season division",rituZodiac:"Zodiac the season boundaries are measured in",road:"Road side",rulingPlanets:"Ruling planets",scheme:"Karaka scheme",secondName:"Second name",secondNameHebrew:"Second name in Hebrew",sephirotSystem:"Sephirot reading",sign:"Zodiac sign",sign1:"First animal sign",sign2:"Second animal sign",signDoshaScheme:"Sign humour table",significators:"Include KP significators",size:"Paper size",slopeLowDirection:"Direction the ground falls toward",slopeSchool:"Ground level school",soulUrge:"Soul Urge number",spreadName:"Spread name",startDate:"Start date",startDatetime:"Start date and time",strictOrbs:"Use tighter orbs",system:"Avastha system",targetDate:"Target date",targetMonth:"Target month",text:"Word or name",textHebrew:"Hebrew word or name",top:"Top events per window",transitDate:"Transit date",transitTime:"Transit time",transliteration:"Transliteration scheme",treeVariant:"Tree arrangement",type:"Pattern type",vyayaFormula:"Vyaya formula",water:"Standing water direction",weights:"Layer weights",width:"Width, east to west",x:"Distance east",y:"Distance north",yearBearerSystem:"Year Bearer school",yearBoundary:"Year boundary",yearStart:"Wheel year start",zodiac:"Zodiac sign"};var Et=["de","en","es","fr","hi","pt","ru","tr","zh-Hans","zh-Hant"];function qe(n){if(n.lang)return n.lang;if(typeof document>"u")return;let t=n.closest?.("[lang]")?.getAttribute("lang");return t||document.documentElement.lang||void 0}function Rt(n){return!n||n.toLowerCase().split("-")[0]==="en"}var Wr={tw:"hant",hk:"hant",mo:"hant",cn:"hans",sg:"hans",my:"hans"};function Me(n,t){let e=n.toLowerCase();return t.find(r=>r.toLowerCase()===e)}function Tt(n,t=Et){let e=qe(n);if(!e)return;let r=Me(e,t);if(r)return r;let i=e.toLowerCase().split("-"),o=i[0];if(o==="zh"){let s=i.find(a=>a==="hans"||a==="hant")??Wr[i[1]??""];return s?Me(`zh-${s}`,t):void 0}return Me(o,t)}var Ot="symbols";var Jr={Fraunces:["latin","latin-ext"],Jost:["latin","latin-ext","cyrillic"],Geist:["latin","latin-ext","cyrillic"]},He='"Jost", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',Lt='"Geist", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',Ct='system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif',pe={"fraunces-jost":{name:"Fraunces with Jost",sans:He,display:'"Fraunces", ui-serif, Georgia, Cambria, "Times New Roman", Times, serif'},jost:{name:"Jost",sans:He,display:He},geist:{name:"Geist",sans:Lt,display:Lt},system:{name:"System",sans:Ct,display:Ct}};function Ft(n){let{sans:t,display:e}=pe[n];return Object.keys(Jr).filter(r=>`${t} ${e}`.includes(`"${r}"`))}var he="1.6.2";var Xr=/^(.*)\/cdn\/(?:roxy-ui|components\/[\w-]+)\.js$/,Qr=/^(.*\/dist)\/(?:index|components\/[\w-]+)\.js$/;function fe(n,t){if(!t)return;let e=new URL(t);if(e.protocol!=="https:"&&e.protocol!=="http:")return;let r=(Xr.exec(e.pathname)??Qr.exec(e.pathname))?.[1];if(r!==void 0)return e.hostname==="cdn.jsdelivr.net"?`https://cdn.jsdelivr.net/npm/@roxyapi/ui@${n}/dist`:`${e.origin}${r}`}var en={};function Dt(n){return n!==void 0&&Object.hasOwn(pe,n)}function Pt(n,t){if(Dt(t))return t;let e=n.getRootNode();if(("host"in e?e.host:null)?.localName.startsWith("roxy-")||!globalThis.getComputedStyle)return;let i=n.shadowRoot?.firstElementChild,o=i?.localName==="style"?i:null;o?.sheet&&(o.sheet.disabled=true);let s,a,c;try{let u=globalThis.getComputedStyle(n),d=m=>u.getPropertyValue(m).trim();s=d("--roxy-font-sans"),a=d("--roxy-font-display"),c=d("--roxy-font")}finally{o?.sheet&&(o.sheet.disabled=false)}if(!(s||a))return Dt(c)?c:void 0}function Ut(n){let{sans:t,display:e}=pe[n];return`--roxy-font:${n};--roxy-font-sans:${t};--roxy-font-display:${e}`}var It=fe(he,globalThis.document?.currentScript?.src||en.url);function Nt(n,t){if(typeof document>"u"||t===void 0)return;let e=`roxy-ui-font-${n}`;if(document.getElementById(e))return;let r=document.createElement("link");r.id=e,r.rel="stylesheet",r.href=`${t}/styles/fonts/${n}.css`,document.head.append(r)}function Mt(n,t=It){Ft(n).length>0&&Nt(n,t)}function qt(n=It){Nt(Ot,n)}var Ht='@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-moon-shade: color-mix(in oklab, var(--roxy-fg) 78%, var(--roxy-bg));--roxy-font: initial;--roxy-font-sans: initial;--roxy-font-mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, "Liberation Mono", monospace;--roxy-font-symbol: "Roxy Symbols", ui-sans-serif, system-ui, sans-serif;--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-moon-lit: color-mix(in oklab, var(--roxy-accent) 6%, #f6eedf);--roxy-moon-mare: color-mix( in oklab, var(--roxy-moon-lit) 62%, var(--roxy-moon-shade) );--roxy-moon-rim: color-mix( in oklab, var(--roxy-moon-shade) 70%, var(--roxy-fg) );--roxy-moon-eclipse: color-mix( in oklab, color-mix(in oklab, var(--roxy-danger) 55%, var(--roxy-warning)) 72%, var(--roxy-moon-shade) );--roxy-moon-corona: color-mix( in oklab, var(--roxy-warning) 60%, var(--roxy-moon-lit) );--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);--roxy-moon-shade: color-mix( in oklab, var(--roxy-fg) 10%, var(--roxy-bg) )}}: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);--roxy-moon-shade: color-mix(in oklab, var(--roxy-fg) 78%, var(--roxy-bg))}: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);--roxy-moon-shade: color-mix(in oklab, var(--roxy-fg) 10%, var(--roxy-bg))}@media(prefers-reduced-motion:reduce){:where(:root,:host){--roxy-motion-duration: 0ms}}}';var me="roxy-ui-tokens";function ge(){if(typeof document>"u")return null;let n=document.getElementById(me);if(n)return n;let t=document.createElement("style");return t.id=me,t.textContent=Ht,document.head.prepend(t),t}function ye(n){return n.toLowerCase().replace(/[\s_-]+/g," ").trim()}function R(n){return n.replace(/[_-]+/g," ").replace(/([a-z])([A-Z])/g,"$1 $2").replace(/([a-z])([0-9])/g,"$1 $2").replace(/^\w/,t=>t.toUpperCase())}var zt="__ROXY_UI_I18N__";function ze(){let n=globalThis,t=n[zt];if(t)return t;let e={catalogs:{},fieldLabels:{},requested:new Set,listeners:new Set};return n[zt]=e,e}function Be(n,t){return t?n.replace(/\{\{(\w+)\}\}/g,(e,r)=>r in t?String(t[r]??""):e):n}function Bt(n,t,e){return Be(Ke(n,t)??t,e)}function Ke(n,t){if(!n)return;let{catalogs:e}=ze(),r=n.toLowerCase();return(e[r]??e[r.split("-")[0]])?.[ye(t)]}function Kt(n){if(!n)return;let{fieldLabels:t}=ze(),e=n.toLowerCase();return t[e]??t[e.split("-")[0]]}function K(n,t){return Kt(n)?.fields[t]}function jt(n,t,e){return Kt(n)?.enums[`${t}.${e}`]}function Gt(n){let{listeners:t}=ze();return t.add(n),()=>{t.delete(n)}}var xe=class{constructor(t){this.host=t,t.addController(this)}hostConnected(){this.unsubscribe=Gt(()=>this.host.requestUpdate())}hostDisconnected(){this.unsubscribe?.(),this.unsubscribe=void 0}};var be=class extends F{constructor(){super();this.translator=(e,r)=>this.t(e,r);new xe(this)}connectedCallback(){super.connectedCallback(),ge()}updated(e){super.updated(e),this.renderRoot.querySelector(".roxy-glyph")&&qt()}fontDeclarations(e){let r=Pt(this,e);return r?(Mt(r),Ut(r)):""}renderFontStyle(){let e=this.fontDeclarations();return e?h`<style>:host{${e}}</style>`:p}t(e,r){return Bt(this.effectiveLang(),e,r)}effectiveLang(){return qe(this)}};var tn=new RegExp("(?![\\d#*])\\p{Emoji}","gu"),rn=n=>n.replace(tn,"$&\uFE0E"),ve=n=>Object.fromEntries(Object.entries(n).map(([t,e])=>[t,rn(e)])),nn=(n,t)=>t?n[ye(t)]:void 0,co=ve({sun:"\u2609",moon:"\u263D",mercury:"\u263F",venus:"\u2640",earth:"\u2641",mars:"\u2642",jupiter:"\u2643",saturn:"\u2644",uranus:"\u2645",neptune:"\u2646",pluto:"\u2BD3",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"});var on=ve({aries:"\u2648",taurus:"\u2649",gemini:"\u264A",cancer:"\u264B",leo:"\u264C",virgo:"\u264D",libra:"\u264E",scorpio:"\u264F",sagittarius:"\u2650",capricorn:"\u2651",aquarius:"\u2652",pisces:"\u2653"}),Yt=n=>nn(on,n);var Vt=["Aries","Taurus","Gemini","Cancer","Leo","Virgo","Libra","Scorpio","Sagittarius","Capricorn","Aquarius","Pisces"],uo=ve({conjunction:"\u260C",semisextile:"\u26BA","semi sextile":"\u26BA",semisquare:"\u2220","semi square":"\u2220",sextile:"\u26B9",square:"\u25A1",trine:"\u25B3",sesquiquadrate:"\u26BC",quincunx:"\u26BB",opposition:"\u260D"});var po=ve({heaven:"\u2630",lake:"\u2631",fire:"\u2632",thunder:"\u2633",wind:"\u2634",water:"\u2635",mountain:"\u2636",earth:"\u2637"});var Zt=$`:where(.roxy-glyph){font-family:var(--roxy-font-symbol)}`;var Wt=$`: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 sn=$`: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);letter-spacing:var(--roxy-tracking-normal);word-spacing: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(:focus){outline:none!important}: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}`,Jt=[sn,Wt,Zt];var Xt=n=>t=>{customElements.get(n)||customElements.define(n,t)};function je(){return h`<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 Qt=$`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 an="pk_live_YOUR_KEY",er={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 X(n){if(n)return n===an?er.sample:n.startsWith("pk_")?void 0:er.secret}function Ge(n,t,e={}){e.warn&&console.warn(t.message),n.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{reason:t.reason,message:t.message},bubbles:true,composed:true}))}var Ye="https://roxyapi.com/api/v2";async function ln(n){try{let t=await n.json();if(t?.error){let e=t.code==="validation_error"&&Array.isArray(t.issues)?t.issues.filter(r=>typeof r.path=="string"&&typeof r.message=="string").map(r=>({path:r.path,message:r.message})):null;return{message:t.error,issues:e?.length?e:null,worded:true,...t.code?{code:t.code}:{}}}}catch{}return{message:`Request failed (${n.status})`,issues:null,worded:false}}var $e=class extends Error{constructor(e,r=null,i=true,o,s){super(e);this.issues=r;this.worded=i;this.status=o;this.code=s}};function tr(n){return n.submitUrl?void 0:X(n.publishableKey)}function Ve(n){return!!(n.submitUrl||n.publishableKey&&!tr(n))}async function Ze(n,t,e){let r=tr(n);if(r)throw new $e(r.message);let i=n.submitUrl?await fetch(n.submitUrl,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:cn(t,n.submitContext),signal:e}):await dn(n,t,e);if(!i.ok){let o=await ln(i);throw new $e(o.message,o.issues,o.worded,i.status,o.code)}return await i.json()}function cn(n,t){return JSON.stringify(t?{...n,context:t}:n)}function dn(n,t,e){let r=new URL(`${n.baseUrl??Ye}${t.path}`,document.baseURI);for(let[o,s]of Object.entries(t.query??{}))s!=null&&r.searchParams.set(o,String(s));let i={Accept:"application/json"};return n.publishableKey&&(i["X-API-Key"]=n.publishableKey),t.body!=null&&(i["Content-Type"]="application/json"),fetch(r,{method:t.method??"GET",headers:i,body:t.body!=null?JSON.stringify(t.body):void 0,signal:e})}var rr={"GET /angel-numbers/numbers/{number}":{number:{path:"/angel-numbers/numbers",limit:50,lang:true}},"GET /astrology/planet-meanings/{id}":{id:{path:"/astrology/planet-meanings",lang:true}},"GET /astrology/signs/{id}":{id:{path:"/astrology/signs",lang:true}},"GET /crystals":{color:{path:"/crystals/colors",lang:true},planet:{path:"/crystals/planets",lang:true}},"GET /crystals/{id}":{id:{path:"/crystals",limit:100,lang:true}},"GET /dreams/symbols":{letter:{path:"/dreams/symbols/letters"}},"GET /dreams/symbols/{id}":{id:{path:"/dreams/symbols",search:"q",limit:50}},"GET /iching/trigrams/{id}":{id:{path:"/iching/trigrams",lang:true}},"GET /tarot/cards/{id}":{id:{path:"/tarot/cards",limit:100,lang:true}}},nr={"GET /tarot/cards":{suit:{field:"arcana",value:"major"}}};var S=(n,t)=>`${n}.${t}`;function we(n){let t=/^(.+)\.(\d+)$/.exec(n);return t?{key:t[1],index:Number(t[2])}:null}function Ae(n,t=Be,e=r=>C[r]??R(r)){let r=we(n);return r?t("{{group}} {{n}}",{group:e(r.key),n:r.index+1}):t(R(n))}function or(n,t){let e=t.key??t.name;if(ar(e))return K(n,e);if(!t.label)return K(n,t.name);let r=Object.keys(C).find(i=>C[i]===t.label);return Ke(n,t.label)??(r?K(n,r):void 0)}function sr(n,t,e){let r=S(t,0);return n.filter(i=>i.group===r).map(i=>({...i,key:`${S(t,e)}.${i.name}`,group:S(t,e)}))}function Xe(n){return n.length<=(Se(n)?30:12)?"tiles":"select"}function Se(n){return n.every(t=>t.length<=2)}var un=["format","branding","readings"],pn=["latitude","longitude","timezone"],ir=["latitude","longitude"];function ar(n){let t=n.match(/^(.+?)(Latitude|Longitude)$/);return t?{group:t[1],leaf:t[2].toLowerCase()}:null}var hn=Vt.map(n=>n.toLowerCase());function D(n,t){if(n){if("$ref"in n&&n.$ref){let e=n.$ref.split("/").pop();return e?t[e]:void 0}return n}}function lr(n){let t=n.anyOf??n.oneOf;return!t||t.length===0?n:t.find(e=>Array.isArray(e.enum))??t.find(e=>Je(e)&&Je(e)!=="null")??t[0]??n}function Je(n){if(typeof n.type=="string")return n.type;if(!Array.isArray(n.type))return;let t=n.type.filter(e=>e!=="null");return t.length===1?t[0]:void 0}function fn(n){let t=lr(n),e=Je(t);return Array.isArray(t.enum)?Xe(t.enum):e==="boolean"?"toggle":t.format==="date"?"date":t.format==="time"?"time":t.format==="date-time"?"datetime":e==="integer"||e==="number"?"number":e==="string"?"text":e==="array"?"array":null}function cr(n){if(n.length!==12)return false;let t=new Set(n.map(e=>e.toLowerCase()));return hn.every(e=>t.has(e))}function ke(n,t,e){let r=lr(t);return{key:e.key,name:n,group:e.group,inQuery:e.inQuery,kind:fn(t)??"text",required:e.required,description:r.description??t.description,enum:r.enum,min:r.minimum??r.exclusiveMinimum,max:r.maximum??r.exclusiveMaximum,default:t.default??r.default,example:t.example??r.example}}function We(n){return new Set([...n.required??[],...n["x-required-any-of"]?.[0]??[]])}function dr(n,t,e,r=n.requestBody?"POST":"GET"){let i=[],o=[],s=false,a,c=n.requestBody?.content?.["application/json"]?.schema,u=D(c,t),d=u?.["x-required-any-of"],m=(n["x-request-cost"]??1)>1;if(u?.properties){let l=We(u);for(let[f,x]of Object.entries(u.properties)){if(m&&un.includes(f))continue;let v=D(x,t)??{},b=v.type==="array"?D(v.items,t):void 0;if(b?.type==="object"&&b.properties){let _=Math.max(1,v.minItems??1),O=We(b);o.push({key:f,min:_,max:v.maxItems??_});for(let z=0;z<_;z++)for(let[P,Tr]of Object.entries(b.properties)){let Lr=D(Tr,t)??{};i.push(ke(P,Lr,{key:`${S(f,z)}.${P}`,group:S(f,z),required:l.has(f)&&O.has(P)}))}}else if(v.type==="object"&&v.properties){let _=We(v);for(let[O,z]of Object.entries(v.properties)){let P=D(z,t)??{};P.type==="array"&&D(P.items,t)?.type==="object"||i.push(ke(O,P,{key:`${f}.${O}`,group:f,required:l.has(f)&&_.has(O)}))}}else{let _=ar(f),O=ke(_?.leaf??f,v,{key:f,group:_?.group,required:l.has(f)});_&&(O.label=`${R(_.group)} ${_.leaf}`),i.push(O)}}}for(let l of n.parameters??[]){if(l.in!=="path"&&l.in!=="query")continue;if(l.name==="lang"&&l.in==="query"){s=true,a=D(l.schema,t)?.enum?.filter(v=>typeof v=="string");continue}let f=D(l.schema,t)??{},x=ke(l.name,f,{key:l.name,required:!!l.required,inQuery:l.in==="query"});if(l.in==="path"&&x.enum&&/^(id|identifier|slug)$/i.test(C[x.name]??R(x.name))){let v=/^([A-Za-z][A-Za-z -]*?)\s+(?:id|identifier|slug)\b/i.exec(l.description??x.description??"")?.[1]?.trim();v&&(x.label=v)}i.push(x)}for(let l of i)!l.group&&!l.label&&i.some(f=>f.group&&f.name===l.name)&&(l.label=mn(l));return Qe({title:gn(n.summary,e),fields:i,hasLang:s,...a?.length?{langs:a}:{},...o.length>0?{repeats:o}:{},...d?{requiredAnyOf:d}:{}},r,e)}function mn(n){let e=(C[n.name]??R(n.name)).toLowerCase().replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),r=new RegExp(`^(\\p{L}+) ${e}\\b`,"iu").exec(n.description??"")?.[1];return r?C[r.toLowerCase()+n.name.replace(/^./,i=>i.toUpperCase())]:void 0}function Qe(n,t,e){let r=`${t.toUpperCase()} /${e.replace(/^\//,"")}`,i=rr[r]??{},o=nr[r]??{},s=n.fields.map(l=>{let f={...l};return delete f.role,delete f.city,delete f.viewerZone,delete f.moment,delete f.fold,{...f,...i[l.key]&&{source:i[l.key]},...o[l.key]&&{disabledWhen:o[l.key]}}}),a=[...new Set(s.map(l=>l.group))].map(l=>l===void 0?{}:{key:l,label:Ae(l)}),c=a.filter(l=>ir.every(f=>s.some(x=>x.group===l.key&&x.name===f)));for(let[l,f]of c.entries()){let x=s.filter(b=>b.group===f.key),v=x.find(b=>b.name==="timezone")??(l===0?s.find(b=>!b.group&&b.name==="timezone"):void 0);f.location={fields:[...x.filter(b=>ir.includes(b.name)).map(b=>b.key),...v?[v.key]:[]],required:x.some(b=>pn.includes(b.name)&&b.required)}}for(let l of s)l.name==="seed"?l.role="seed":(l.name==="limit"||l.name==="offset")&&!l.required?l.role="hidden-default":c.some(f=>f.location?.fields.includes(l.key))?l.role="location":l.name==="timezone"&&(l.city=true,!l.group&&!l.required&&(l.viewerZone=true));let u=a.filter(l=>l.key!==void 0&&(l.location||s.some(f=>f.group===l.key&&f.required))),d=s.some(l=>!l.group&&!l.role&&l.required)||u.length>0||c.some(l=>l.key===void 0);for(let l of a)l.key!==void 0&&d&&!u.includes(l)&&(l.fold=true);let m=l=>u.length>0&&l.default===void 0&&(l.kind==="date"||l.kind==="time"||l.kind==="datetime");for(let l of s)l.group?a.find(f=>f.key===l.group)?.fold&&(l.fold=true):!l.role&&d&&!l.required?m(l)?l.moment=true:l.fold=true:!l.role&&!d&&l.default!==void 0&&(l.fold=true);return{...n,fields:s,groups:a,opensOnLoad:yn(n,t)}}function ur(n,t){let e=n.filter(r=>r.moment);return e.some(r=>r.kind==="time"||r.kind==="datetime")&&e.every(r=>t[r.key]===void 0||t[r.key]==="")}function gn(n,t){let e=n?.split(" - ")[0]?.trim();return e||R(t.split("/").pop()??"")}function yn(n,t){return t.toUpperCase()==="GET"&&!n.fields.some(e=>e.required)}function pr(n,t=[]){if(t.some(r=>r.name==="limit"||r.name==="offset"))return"Search";let e=n.toLowerCase();return/compat|synastry|guna|connection|penta|composite/.test(e)?"Compare":/\bcast\b|\/draw|iching|hexagram|tarot/.test(e)?"Cast":/horoscope|dream|angel|nakshatra|crystal|meaning|reference/.test(e)?"Get reading":"Generate"}function hr(n,t){let e=fe(n,t);return e&&`${e}/schemas`}function fr(n,t){let e=t.replace(/^\//,"").replace(/[{}]/g,"").replace(/\//g,"-");return`${n.toLowerCase()}--${e}.json`}function xn(n){if(Array.isArray(n))return n;if(!n||typeof n!="object")return null;let t=Object.values(n),e=t.find(Array.isArray);return e||(t.find(i=>!!i&&typeof i=="object"&&Object.values(i).every(o=>typeof o=="number"))??null)}function et(n,t="id"){let e=xn(n);if(!e)return[];if(!Array.isArray(e)){let i=Object.keys(e),o=i.length>0&&i.every(a=>/^[a-z]$/.test(a));return(o?[..."abcdefghijklmnopqrstuvwxyz"]:i).map(a=>({value:a,label:o?a.toUpperCase():a,disabled:!e[a]}))}let r=[];for(let i of e){if(typeof i=="string"){r.push({value:i,label:i});continue}if(!i||typeof i!="object")continue;let o=i,s=o.id??o[t]??o.number;if(s==null)continue;let a=String(s),c=o.name??o.english;r.push({value:a,label:typeof c=="string"?c:a})}return r}function mr(n){let t=n?.total;return typeof t=="number"?t:void 0}var gr=new Map;function bn(n){if(!n)return["en"];let t=gr.get(n);if(t)return[t,"en"];let e="en";try{e=Intl.getCanonicalLocales(n)[0]??"en"}catch{e="en"}return gr.set(n,e),[e,"en"]}function yr(){try{return new Intl.DateTimeFormat(bn(void 0)).resolvedOptions().timeZone}catch{return}}function xr(n,t,e){return K(n,t)??e??R(t)}function br(n,t,e,r){return jt(n,t,e)??r??R(e)}var vr=$`.spinner{inset-inline-end:calc(var(--roxy-space-unit) * 3);border:var(--roxy-line-thick) solid var(--roxy-muted);border-radius:var(--roxy-radius-full);border-top-color:#0000;block-size:.6lh;inline-size:.6lh;animation:.7s linear infinite roxy-spin;position:absolute;top:50%;transform:translateY(-50%)}@keyframes roxy-spin{to{transform:translateY(-50%)rotate(360deg)}}@media (prefers-reduced-motion:reduce){.spinner{animation:none}}.results{z-index:50;top:calc(100% + var(--roxy-space-xs));padding:var(--roxy-space-xs);background:var(--roxy-bg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);box-shadow:var(--roxy-shadow-md);max-block-size:15lh;animation:roxy-fade-in var(--roxy-motion-duration) var(--roxy-motion-easing);margin:0;list-style:none;position:absolute;left:0;right:0;overflow-y:auto}.option{align-items:center;gap:var(--roxy-space-sm);inline-size:100%;min-block-size:var(--roxy-touch);padding:var(--roxy-space-sm) var(--roxy-space-md);border-radius:var(--roxy-radius-sm);text-align:start;font-size:var(--roxy-text-sm);color:var(--roxy-fg);cursor:pointer;transition:background-color var(--roxy-motion-duration);background:0 0;border:0;display:flex}.option:hover,.option[aria-selected=true]{background:color-mix(in srgb, var(--roxy-accent) 10%, transparent)}.empty{padding:var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-sm)}`;function $r(n,t){let e,r=((...i)=>{e&&clearTimeout(e),e=setTimeout(()=>{e=void 0,n(...i)},t)});return r.cancel=()=>{e&&(clearTimeout(e),e=void 0)},r}var vn=10,$n=10,tt=new Map;function kr(n,t,e={}){return{...n.limit?{limit:n.limit}:{},...n.lang&&t?{lang:t}:{},...e}}function nt(n,t,e,r){let i=JSON.stringify([n.submitUrl??n.baseUrl,t.path,e,r]),o=tt.get(i);return o||(o=kn(n,t,e,r).catch(s=>{throw tt.delete(i),s}),tt.set(i,o)),o}async function kn(n,t,e,r){let i=[];for(let o=0;o<$n;o++){let s=await Ze(n,{path:t.path,method:"GET",query:kr(t,r,i.length?{offset:i.length}:{})}),a=et(s,e);i.push(...a);let c=mr(s);if(!t.limit||c===void 0||i.length>=c||!a.length)break}return i}var rt=n=>n.normalize("NFD").replace(new RegExp("\\p{M}","gu"),"").toLowerCase(),_e=class{constructor(t,e,r,i,o){this.host=t;this.source=e;this.field=r;this.context=i;this.onPick=o;this.query="";this.options=[];this.open=false;this.highlight=-1;this.loading=false;this.error=null;this.search=$r(t2=>{this.searchServer(t2)},250);t.addController(this)}hostDisconnected(){this.search.cancel(),this.abort?.abort()}input(t){this.query=t,this.error=null,this.source.search?t.trim().length<2?this.close():this.search(t):this.filter(t),this.host.requestUpdate()}focus(){!this.source.search&&!this.open&&this.filter(this.query)}close(){this.open=false,this.highlight=-1,this.host.requestUpdate()}pick(t){this.query=t.label,this.close(),this.onPick(t)}keydown(t){let e=this.options.length;if(t.key==="Escape"){this.close();return}if(t.key==="ArrowDown"&&!this.open){t.preventDefault(),this.input(this.query);return}if(!(!this.open||e===0)){if(t.key==="ArrowDown")this.highlight=(this.highlight+1)%e;else if(t.key==="ArrowUp")this.highlight=(this.highlight-1+e)%e;else if(t.key==="Home")this.highlight=0;else if(t.key==="End")this.highlight=e-1;else if(t.key==="Enter"){let r=this.options[this.highlight]??this.options[0];r&&this.pick(r)}else return;t.preventDefault(),this.host.requestUpdate()}}async filter(t){let{route:e,lang:r}=this.context();this.loading=true,this.host.requestUpdate();try{let i=await nt(e,this.source,this.field,r);if(t!==this.query)return;let o=rt(t.trim());this.show(i.filter(s=>rt(s.label).includes(o)||rt(s.value).includes(o)))}catch(i){this.fail(i)}finally{this.loading=false,this.host.requestUpdate()}}async searchServer(t){let{route:e,lang:r}=this.context(),i=this.source.search;this.abort?.abort();let o=new AbortController;this.abort=o,this.loading=true,this.host.requestUpdate();try{let s=await Ze(e,{path:this.source.path,method:"GET",query:kr({...this.source,limit:vn},r,{[i]:t})},o.signal);if(o.signal.aborted)return;this.show(et(s,this.field))}catch(s){if(o.signal.aborted)return;this.fail(s)}finally{this.abort===o&&(this.abort=void 0),o.signal.aborted||(this.loading=false,this.host.requestUpdate())}}show(t){this.options=t,this.open=true,this.highlight=t.length?0:-1}fail(t){this.options=[],this.open=false,this.error=t instanceof Error?t.message:String(t)}};function wr(n,t,e,r={}){let i=`${t}-listbox`;return h`<div class="picker"><input id="${t}" type="text" role="combobox" aria-expanded="${n.open?"true":"false"}" aria-controls="${i}" aria-autocomplete="list" aria-labelledby="${k(r.labelledby)}" aria-describedby="${k(r.describedby)}" aria-invalid="${k(r.invalid?"true":void 0)}" aria-activedescendant="${n.open&&n.highlight>=0?`${t}-opt-${n.highlight}`:""}" autocomplete="off" placeholder="${e.placeholder}" .value="${n.query}" @input="${o=>n.input(o.target.value)}" @keydown="${o=>n.keydown(o)}" @focus="${()=>n.focus()}" @blur="${()=>n.close()}"> ${n.loading?h`<span class="spinner" role="status" aria-label="${e.loading}"></span>`:p} ${n.open?h`<ul id="${i}" class="results" role="listbox">${n.options.length===0?h`<li class="empty" role="status">${e.empty}</li>`:n.options.map((o,s)=>h`<li id="${`${t}-opt-${s}`}" class="option" role="option" aria-selected="${n.highlight===s?"true":"false"}" @mousedown="${a=>a.preventDefault()}" @click="${()=>n.pick(o)}">${o.label}</li>`)}</ul>`:p}</div>${n.error?h`<small class="field-error" role="alert">${n.error}</small>`:p}`}var Ar=[vr,$`.picker{position:relative}`];var En={};var Sr=`${Ye}/openapi.json`,_r=hr(he,globalThis.document?.currentScript?.src||En.url),Ee=new Map,Re=class extends Error{constructor(e){super(`HTTP ${e}`);this.status=e}},Te=class extends Error{constructor(e,r){super(`Endpoint ${e} ${r} not found in OpenAPI spec`);this.method=e;this.path=r}};function wn(){Ee.clear()}async function An(n){let t=Ee.get(n);return t||(t=fetch(n).then(async e=>{if(!e.ok)throw new Re(e.status);return await e.json()}).catch(e=>{throw Ee.delete(n),e}),Ee.set(n,t)),t}function Sn(){return globalThis.crypto?.randomUUID?.()??Math.random().toString(36).slice(2)}var Er=n=>/\bbirth/i.test(n?.description??""),Rr=n=>n.key===`${n.group}.${n.name}`;function _n(n){let t=n.trim();if(!t)return[];try{let e=JSON.parse(t);if(Array.isArray(e))return e}catch{}return t.split(",").map(e=>e.trim()).filter(Boolean)}var g=class extends be{constructor(){super(...arguments);this.endpoint="vedic-astrology/birth-chart";this.method="POST";this.specUrl="";this.submitLabel="";this.serverIssues=null;this.autoload=false;this.fullPages=false;this.choices={};this.pickers=new Map;this.clearedIssues=new Set;this.fields=[];this.groups=[];this.modelOpensOnLoad=false;this.repeats=[];this.formTitle="";this.hasLang=false;this.values={};this.loaded=false;this.specError=null;this.validationErrors=[];this.retryLoadSchema=()=>{this.loaded=false,this.specError=null,this.loadSchema()};this.onSubmit=e=>{e.preventDefault(),this.submit()}}connectedCallback(){super.connectedCallback(),this.loadSchema()}async loadSchema(){this.specError=null;try{this.applyModel(await this.resolveModel())}catch(e){this.specError=this.specErrorMessage(e),this.loaded=true,this.dispatchEvent(new CustomEvent("roxy-spec-error",{detail:{url:this.specUrl||Sr,message:e instanceof Error?e.message:String(e)},bubbles:true,composed:true}))}}specErrorMessage(e){return e instanceof Re?this.t("HTTP error {{status}}",{status:e.status}):e instanceof Te?this.t("Endpoint {{method}} {{path}} not found in OpenAPI spec",{method:e.method,path:e.path}):e instanceof Error?e.message:String(e)}async resolveModel(){return this.specUrl?this.modelFromSpec(this.specUrl):await this.tryLoadSlice()??this.modelFromSpec(Sr)}async modelFromSpec(e){let r=await An(e),i=`/${this.endpoint.replace(/^\//,"")}`,o=r.paths?.[i]?.[this.method.toLowerCase()];if(!o)throw new Te(this.method,i);return dr(o,r.components?.schemas??{},this.endpoint,this.method)}async tryLoadSlice(){if(!_r)return null;try{let e=await fetch(`${_r}/${fr(this.method,this.endpoint)}`);return e.ok?await e.json():null}catch{return null}}applyModel(e){(!e.groups||e.opensOnLoad===void 0)&&(e=Qe(e,this.method,this.endpoint)),this.fields=e.fields,this.groups=e.groups??[],this.modelOpensOnLoad=e.opensOnLoad??false,this.repeats=e.repeats??[],this.formTitle=e.title,this.hasLang=e.hasLang,this.langs=e.langs;let r={};for(let i of e.fields){let o=i.viewerZone?void 0:this.fullPages&&i.name==="limit"&&this.roleOf(i)==="hidden-default"?i.max??i.default:i.default;o!==void 0&&(r[i.key]=o);let s=i.group&&Rr(i)?this.initialValues?.[i.group]?.[i.name]:this.initialValues?.[i.key];s!==void 0&&(r[i.key]=s)}this.values=this.withoutDisabled(r),this.loaded=true,this.loadChoices(),this.autoload&&this.opensOnLoad&&Ve(this.route)&&this.updateComplete.then(()=>this.submit())}get route(){return this.apiRoute??{publishableKey:this.publishableKey}}loadChoices(){for(let r of this.pickers.values())this.removeController(r);if(this.pickers.clear(),!Ve(this.route))return;let e=()=>({route:this.route,lang:this.requestLang()});for(let r of this.fields)if(r.source){if(r.required){let i=new _e(this,r.source,r.name,e,o=>this.pickChoice(r,o.value));i.query=String(this.values[r.key]??""),this.pickers.set(r.key,i);continue}this.choices={...this.choices,[r.key]:"loading"},nt(this.route,r.source,r.name,this.requestLang()).then(i=>{this.choices={...this.choices,[r.key]:i}},()=>{let{[r.key]:i,...o}=this.choices;this.choices=o})}}setValue(e,r){this.setValues({[e]:r})}setValues(e){this.values=this.withoutDisabled({...this.values,...e});let r=Object.keys(e).filter(i=>this.serverIssues?.some(o=>o.path===i));r.length&&(this.clearedIssues=new Set([...this.clearedIssues,...r]))}isDisabled(e,r=this.values){let i=e.disabledWhen;return!!i&&r[i.field]===i.value}withoutDisabled(e){for(let r of this.fields)this.isDisabled(r,e)&&(e[r.key]=void 0);return e}willUpdate(e){e.has("serverIssues")&&(this.clearedIssues=new Set);let r=e.has("publishableKey")?X(this.publishableKey):void 0;r&&Ge(this,r,{warn:true})}liveIssues(){return(this.serverIssues??[]).filter(e=>!this.clearedIssues.has(e.path))}issueFor(e){return this.liveIssues().find(r=>r.path===e.key)}cityIssues(e){return this.liveIssues().filter(r=>{let i=this.fields.find(o=>o.key===r.path);return!!i&&this.roleOf(i)==="location"&&this.cityGroup(i)===e})}issuesForGroup(e){return this.liveIssues().filter(r=>r.path===e)}fieldLabel(e){return this.roleOf(e)==="location"||e.city?this.locationLabel(this.cityGroup(e)):e.group?`${this.groupName(e.group)} ${this.fieldText(e)}`:this.fieldText(e)}issueLines(e){return e.map(r=>h`<small part="field-error" class="field-error" role="alert">${r.message}</small>`)}fieldIssue(e){let r=this.issueFor(e);return r?h`<small part="field-error" class="field-error" id="${`roxy-form-${e.key}-error`}" role="alert">${r.message}</small>`:p}renderIssueSummary(){let e=this.liveIssues();if(e.length===0)return p;let r=i=>{let o=this.fields.find(a=>a.key===i);if(o)return this.fieldLabel(o);let s=this.groupKeys().find(a=>a===i);return s?this.groupName(s):this.fieldText({name:i.split(".")[0]??i})};return h`<div part="validation-error" class="validation-error" role="alert">${e.map(i=>h`<div><strong>${r(i.path)}</strong> ${i.message}</div>`)}</div>`}roleOf(e){return e.role??"normal"}isRendered(e){return this.roleOf(e)==="normal"}groupKeys(){return this.groups.map(e=>e.key)}groupHasLocation(e){return!!this.groups.find(r=>r.key===e)?.location}cityGroup(e){return this.groups.find(r=>r.location?.fields.includes(e.key))?.key??e.group}placeField(e){let r=this.fields.filter(i=>i.group===e);return r.find(i=>i.name==="latitude")??r.find(i=>i.name==="timezone")}locationRequired(e){return this.groups.find(r=>r.key===e)?.location?.required??false}get soleChoice(){if(this.groupKeys().some(i=>this.groupHasLocation(i))||this.groupKeys().some(i=>i!==void 0))return null;let e=this.fields.filter(i=>i.required&&this.isRendered(i)),r=e[0];return e.length!==1||!r?null:r.kind==="tiles"||r.kind==="select"||this.pickers.has(r.key)?r:null}get opensOnLoad(){return this.modelOpensOnLoad}isFilter(e){return this.opensOnLoad&&!e.required&&!!(e.enum||e.source)}get selfSubmits(){if(this.soleChoice)return true;if(!this.opensOnLoad)return false;let e=this.fields.filter(r=>this.isRendered(r));return e.length>0&&e.every(r=>this.isFilter(r))}choiceKind(e){let r=this.choicesOf(e).map(i=>i.value);return this.isFilter(e)&&!Se(r)?"select":this.choices[e.key]?Xe(r):e.kind}choicesOf(e){let r=this.choices[e.key];return Array.isArray(r)?r:(e.enum??[]).map(i=>({value:i,label:this.optionText(e.name,i)}))}effectiveSubmitLabel(){return this.submitLabel?this.submitLabel:ur(this.fields,this.values)?this.t("Show right now"):this.t(pr(this.endpoint,this.fields))}requestLang(e){return Tt(this,e)}fieldText(e){let r=this.requestLang();return e.label?or(r,e)??e.label:xr(r,e.name,C[e.name])}optionText(e,r){return br(this.requestLang(),e,r)}onLocationFor(e){return r=>{let i=this.groups.find(s=>s.key===e)?.location?.fields??[],o={};for(let s of i){let a=this.fields.find(c=>c.key===s)?.name;a&&(o[s]=r[a])}this.setValues(o)}}chooseOption(e,r){if(this.isFilter(e)){this.setFilter(e,this.values[e.key]===r?"":r),this.submit();return}this.pickChoice(e,r)}pickChoice(e,r){this.setValue(e.key,r),this.resend()}resend(){let e=this.soleChoice;e&&this.values[e.key]&&this.submit()}setFilter(e,r){let i={[e.key]:r};for(let o of this.fields)o!==e&&(this.isFilter(o)||this.opensOnLoad&&o.kind==="text"&&this.isRendered(o))&&(i[o.key]=void 0);this.setValues(i)}onTilesKeyDown(e){return r=>{let i=this.choicesOf(e).filter(d=>!d.disabled).map(d=>d.value);if(i.length===0)return;let o=i.indexOf(this.values[e.key]),s;if(r.key==="Home")s=0;else if(r.key==="End")s=i.length-1;else if(r.key==="ArrowRight"||r.key==="ArrowDown")s=o===-1?0:(o+1)%i.length;else if(r.key==="ArrowLeft"||r.key==="ArrowUp")s=o===-1?i.length-1:(o-1+i.length)%i.length;else return;r.preventDefault();let a=i[s];if(a===void 0)return;this.chooseOption(e,a);let c=r.currentTarget,u=this.choicesOf(e).findIndex(d=>d.value===a);requestAnimationFrame(()=>c.querySelector(`[data-tile='${u}']`)?.focus())}}submit(){let e=this.collectMissing();if(e.keys.length>0){this.validationErrors=e.labels,this.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{missing:e.keys},bubbles:true,composed:true}));return}this.validationErrors=[],this.clearedIssues=new Set((this.serverIssues??[]).map(s=>s.path));let r={};for(let s of this.fields){let a=this.values[s.key];if(s.name==="seed"&&(a===void 0||a==="")&&(a=Sn()),s.viewerZone&&(a===void 0||a==="")&&(a=yr()??s.default),a===void 0||a==="")continue;s.kind==="array"&&typeof a=="string"&&(a=_n(a));let c=s.group?we(s.group):null;if(c){let u=r[c.key]??[],d=u[c.index]??{};d[s.name]=a,u[c.index]=d,r[c.key]=u}else if(s.group&&Rr(s)){let u=r[s.group]??{};u[s.name]=a,r[s.group]=u}else r[s.key]=a}let i=this.fields.filter(s=>s.inQuery).map(s=>s.name),o=this.requestLang(this.langs);this.hasLang&&o&&(r.lang=o,i.push("lang")),this.dispatchEvent(new CustomEvent("roxy-submit",{detail:{endpoint:this.endpoint,values:r,queryKeys:i,sticky:this.soleChoice!=null||this.opensOnLoad},bubbles:true,composed:true}))}collectMissing(){let e=[],r=[],i=new Set;for(let o of this.fields){if(!o.required)continue;let s=this.roleOf(o)==="location";if(!this.isRendered(o)&&!s)continue;let a=this.values[o.key];if(!(a!==void 0&&a!=="")){if(e.push(o.key),s){i.add(this.cityGroup(o));continue}r.push(this.fieldLabel(o))}}for(let o of i)r.push(this.locationLabel(o));return{keys:e,labels:r}}get readsEnglish(){return Rt(this.effectiveLang())}renderTitle(){return this.readsEnglish?h`<h2 part="title" class="title" id="roxy-form-title">${this.formTitle}</h2>`:p}reqMark(e){return e.required?h`<span class="req" aria-hidden="true">*</span>`:p}description(e){if(!e.description||!this.readsEnglish)return p;if(e.description.length<=120)return h`<small part="hint" class="help">${e.description}</small>`;let r=e.description.split(". ")[0]??e.description;return h`<details part="hint" class="help-details"><summary><span class="help-lead">${r}</span>${je()}</summary><small class="help help-full">${e.description}</small></details>`}renderTiles(e){let r=`roxy-form-${e.key}-label`,i=!!e.enum&&cr(e.enum),o=this.choicesOf(e),s=Se(o.map(u=>u.value)),a=o.findIndex(u=>u.value===this.values[e.key]),c=a===-1?o.findIndex(u=>!u.disabled):a;return h`<div class="field tiles-field"><span class="label" id="${r}">${this.fieldText(e)}${this.reqMark(e)}</span><div class="${s?"tiles narrow":"tiles"}" role="radiogroup" aria-labelledby="${r}" @keydown="${this.onTilesKeyDown(e)}">${o.map((u,d)=>{let m=this.values[e.key]===u.value,l=i?Yt(u.value):void 0;return h`<button type="button" class="tile" role="radio" data-tile="${d}" aria-checked="${m?"true":"false"}" tabindex="${d===c?"0":"-1"}" ?disabled="${!!u.disabled||this.isDisabled(e)}" @click="${()=>this.chooseOption(e,u.value)}">${l?h`<span class="tile-glyph roxy-glyph" aria-hidden="true">${l}</span>`:p} <span class="tile-label">${u.label}</span></button>`})}</div>${this.description(e)} ${this.fieldIssue(e)}</div>`}renderSelect(e){let r=`roxy-form-${e.key}`;return h`<div part="field" class="field"><label for="${r}">${this.fieldText(e)}${this.reqMark(e)}</label> <select id="${r}" ?required="${e.required}" ?disabled="${this.isDisabled(e)}" aria-invalid="${k(this.issueFor(e)?"true":void 0)}" aria-describedby="${k(this.issueFor(e)?`${r}-error`:void 0)}" .value="${_t(this.values[e.key]??"")}" @change="${i=>this.chooseOption(e,i.target.value)}"><option value="">${this.t("Choose")}</option>${this.choicesOf(e).map(i=>h`<option value="${i.value}" ?selected="${this.values[e.key]===i.value}" ?disabled="${!!i.disabled}">${i.label}</option>`)}</select> ${this.description(e)} ${this.fieldIssue(e)}</div>`}renderPickerField(e,r){let i=`roxy-form-${e.key}`,o=this.soleChoice?.key===e.key&&this.readsEnglish,s=this.issueFor(e);return h`<div part="field" class="field">${o?p:h`<label for="${i}">${this.fieldText(e)}${this.reqMark(e)}</label>`} ${wr(r,i,{placeholder:this.t("Type to search"),empty:this.t("{{count}} matches",{count:0}),loading:this.t("Loading")},{labelledby:o?"roxy-form-title":void 0,describedby:s?`${i}-error`:void 0,invalid:!!s})} ${this.fieldIssue(e)}</div>`}renderToggle(e){let r=`roxy-form-${e.key}`,i=this.values[e.key]===true;return h`<div part="field" class="field"><div class="toggle-row"><button type="button" id="${r}" class="toggle" role="switch" aria-checked="${i?"true":"false"}" @click="${()=>this.pickChoice(e,!i)}"><span class="knob"></span></button> <label class="toggle-label" for="${r}">${this.fieldText(e)}${this.reqMark(e)}</label></div>${this.description(e)} ${this.fieldIssue(e)}</div>`}renderInput(e){let r=`roxy-form-${e.key}`,i=e.kind==="datetime"?"datetime-local":e.kind==="number"?"number":e.kind,o=e.example!=null?String(e.example):"",s=e.kind==="array"?this.t("Comma separated"):this.readsEnglish||!new RegExp("\\p{L}","u").test(o)?o:"";return h`<div part="field" class="field"><label for="${r}">${this.fieldText(e)}${this.reqMark(e)}</label> <input id="${r}" type="${e.kind==="array"?"text":i}" ?required="${e.required}" ?disabled="${this.isDisabled(e)}" aria-invalid="${k(this.issueFor(e)?"true":void 0)}" aria-describedby="${k(this.issueFor(e)?`${r}-error`:void 0)}" min="${k(e.min)}" max="${k(e.max)}" step="${e.kind==="number"?"any":p}" placeholder="${s||p}" .value="${this.values[e.key]??""}" @input="${a=>{let c=this.coerce(e.kind,a.target.value);this.opensOnLoad&&e.kind==="text"?this.setFilter(e,c):this.setValue(e.key,c)}}" @change="${()=>this.resend()}"> ${this.description(e)} ${this.fieldIssue(e)}</div>`}renderField(e){if(e.city)return this.renderTimezoneCity(e);let r=this.pickers.get(e.key);if(r)return this.renderPickerField(e,r);let i=this.choices[e.key];return i==="loading"?h`<div class="field"><div class="roxy-skeleton field-skeleton" aria-label="${this.t("Loading")}" role="status"></div></div>`:i||e.kind==="tiles"||e.kind==="select"?this.choiceKind(e)==="tiles"?this.renderTiles(e):this.renderSelect(e):e.kind==="toggle"?this.renderToggle(e):this.renderInput(e)}groupName(e){return Ae(e,(r,i)=>this.t(r,i),r=>this.fieldText({name:r}))}repeatCount(e){return new Set(this.fields.map(r=>r.group&&we(r.group)).filter(r=>r&&r.key===e).map(r=>r.index)).size}addRecord(e){let r=this.repeatCount(e),i=sr(this.fields,e,r),o=this.groups.find(a=>a.key===S(e,0));if(o){let a=c=>c.replace(`${S(e,0)}.`,`${S(e,r)}.`);this.groups=[...this.groups,{...o,key:S(e,r),label:Ae(S(e,r)),...o.location&&{location:{...o.location,fields:o.location.fields.map(a)}}}]}let s={...this.values};for(let a of i)a.default!==void 0&&(s[a.key]=a.default);this.values=s,this.fields=[...this.fields,...i]}removeRecord(e){let r=S(e,this.repeatCount(e)-1);this.fields=this.fields.filter(o=>o.group!==r),this.groups=this.groups.filter(o=>o.key!==r);let i={...this.values};for(let o of Object.keys(i))o.startsWith(`${r}.`)&&delete i[o];this.values=i}repeatControls(e){let r=this.repeatCount(e.key);return e.max<=e.min?p:h`<div class="repeat-controls">${r<e.max?h`<button type="button" class="repeat-btn" @click="${()=>this.addRecord(e.key)}"><span aria-hidden="true">+</span> ${this.t("Add")}</button>`:p} ${r>e.min?h`<button type="button" class="repeat-btn" @click="${()=>this.removeRecord(e.key)}"><span aria-hidden="true">−</span> ${this.t("Remove")}</button>`:p}</div>`}locationLabel(e){return e?this.t("{{group}} location",{group:this.groupName(e)}):Er(this.placeField(e))?this.t("Birth location"):this.t("Location")}locationBlock(e){return h`<div class="location-block"><label>${this.locationLabel(e)}${this.locationRequired(e)?h`<span class="req" aria-hidden="true">*</span>`:p}</label> ${this.citySearch(e,this.onLocationFor(e))} ${this.issueLines(this.cityIssues(e))}</div>`}renderTimezoneCity(e){return h`<div part="field" class="field location-block"><label>${this.locationLabel(e.group)}${this.reqMark(e)}</label> ${this.citySearch(e.group,r=>this.pickChoice(e,r.timezone))} ${this.fieldIssue(e)}</div>`}citySearch(e,r){let i=e?this.t("{{group}} city",{group:this.groupName(e)}):Er(this.placeField(e))?this.t("City of birth"):void 0;return h`<roxy-location-search endpoint="${k(this.locationUrl||void 0)}" publishable-key="${k(this.publishableKey)}" .submitUrl="${this.route.submitUrl}" .submitContext="${this.route.submitContext}" lang="${k(this.effectiveLang())}" placeholder="${k(i)}" @roxy-location-select="${o=>r(o.detail)}"></roxy-location-search><small class="help">${this.t("Type a city, then pick it from the list.")}</small>`}groupCard(e){let r=this.fields.filter(i=>i.group===e&&this.isRendered(i));return h`<fieldset part="group" class="person-group"><legend>${this.groupName(e)}</legend>${this.groupHasLocation(e)?this.locationBlock(e):p}<div class="fields">${r.map(i=>this.renderField(i))}</div>${this.issueLines(this.issuesForGroup(e))}</fieldset>`}render(){return h`${this.renderFontStyle()}${this.renderBody()}`}renderBody(){if(!this.loaded)return h`<form><div class="roxy-skeleton form-skeleton"></div></form>`;if(this.specError)return h`<div class="roxy-error" role="alert">${this.t("Schema load failed: {{message}}",{message:this.specError})} <button type="button" class="submit" @click="${this.retryLoadSchema}">${this.t("Retry")}</button></div>`;let e=X(this.publishableKey);if(e)return h`<form>${this.renderTitle()}<div part="validation-error" class="validation-error" role="alert">${this.t(e.message)}</div></form>`;let r=this.fields.filter(d=>!d.group&&this.isRendered(d)),i=this.groupKeys().filter(d=>d!==void 0),o=r.filter(d=>!d.fold),s=r.filter(d=>d.fold),a=i.filter(d=>!this.groups.find(m=>m.key===d)?.fold),c=i.filter(d=>this.groups.find(m=>m.key===d)?.fold),u=s.length>0||c.length>0;return h`<form @submit="${this.onSubmit}">${this.renderTitle()} ${this.validationErrors.length>0?h`<div part="validation-error" class="validation-error" role="alert"><strong>${this.t("Please complete:")}</strong> ${this.validationErrors.join(", ")}</div>`:p} ${this.renderIssueSummary()}<div class="fields">${o.map(d=>this.renderField(d))}</div>${this.groupHasLocation(void 0)?this.locationBlock(void 0):p} ${a.map(d=>this.groupCard(d))} ${this.repeats.map(d=>this.repeatControls(d))} ${u?h`<details part="advanced" class="advanced" ?open="${this.liveIssues().some(d=>[...s.map(m=>m.key),...c].some(m=>d.path===m||d.path.startsWith(`${m}.`)))}"><summary>${this.t("Advanced")}${je()}</summary><div class="fields">${s.map(d=>this.renderField(d))}</div>${c.map(d=>this.groupCard(d))}</details>`:p} ${this.selfSubmits?p:h`<button part="submit" class="submit" type="submit">${this.effectiveSubmitLabel()}</button>`}</form>`}coerce(e,r){if(r!==""){if(e==="number"){let i=Number(r);return Number.isFinite(i)?i:void 0}return r}}};g.styles=[Jt,Qt,Ar,$`form{gap:var(--roxy-space-md);background:var(--roxy-surface);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);padding:var(--roxy-space-lg);box-shadow:var(--roxy-shadow-sm);grid-template-columns:minmax(0,1fr);display:grid}.title{margin:0}.fields{align-items:start;gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(22ch,1fr));display:grid}.fields:empty{display:none}.person-group{gap:var(--roxy-space-md);min-inline-size:0;padding:var(--roxy-space-md) 0 0;border:0;border-block-start:1px solid var(--roxy-border);margin:0;display:grid}.person-group legend{float:inline-start;color:var(--roxy-fg);font-weight:var(--roxy-weight-bold);padding:0}.field{gap:var(--roxy-space-xs);flex-direction:column;min-inline-size:0;display:flex}.fields>*{min-inline-size:0}.tiles-field{grid-column:1/-1}label,.label{font-size:var(--roxy-text-sm);color:var(--roxy-secondary)}.req{color:var(--roxy-danger-fg);margin-inline-start:var(--roxy-space-xs)}input,select{inline-size:100%;min-inline-size:0;min-block-size:var(--roxy-touch)}.help{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.field-error{color:var(--roxy-danger-fg);font-size:var(--roxy-text-xs)}input[aria-invalid=true],select[aria-invalid=true]{border-color:var(--roxy-danger)}input:disabled,select:disabled{cursor:default;color:var(--roxy-muted);border-style:dashed}.help-details>summary{align-items:center;gap:var(--roxy-space-xs);color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:flex}.help-details .help-lead{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.help-details .help-full{margin-block-start:var(--roxy-space-xs);display:block}.location-block{gap:var(--roxy-space-xs);grid-column:1/-1;display:grid}.tiles{gap:var(--roxy-space-sm);grid-template-columns:repeat(auto-fit,minmax(10ch,1fr));display:grid}.tiles.narrow{gap:var(--roxy-space-xs);grid-template-columns:repeat(auto-fill,minmax(4ch,1fr))}.tile{justify-content:center;align-items:center;gap:calc(var(--roxy-space-unit) / 2);min-block-size:var(--roxy-touch);padding:var(--roxy-space-sm);background:var(--roxy-bg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);color:var(--roxy-fg);font-size:var(--roxy-text-sm);cursor:pointer;transition:border-color var(--roxy-motion-duration) var(--roxy-motion-easing), background-color var(--roxy-motion-duration) var(--roxy-motion-easing);flex-direction:column;display:flex}.tile:hover:not(:disabled){border-color:var(--roxy-accent)}.tile:disabled{cursor:default;color:var(--roxy-muted);border-style:dashed}.tile[aria-checked=true]{border-color:var(--roxy-accent);background:color-mix(in srgb, var(--roxy-accent) 12%, transparent);color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.tile-glyph{font-size:var(--roxy-text-lg);line-height:1}.toggle-row{align-items:center;gap:var(--roxy-space-sm);display:flex}.toggle{box-sizing:content-box;block-size:.8lh;inline-size:1.6lh;padding:calc(var(--roxy-space-unit) / 2);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-full);background:var(--roxy-border);cursor:pointer;transition:background-color var(--roxy-motion-duration) var(--roxy-motion-easing);flex-shrink:0;display:inline-flex}.toggle[aria-checked=true]{background:var(--roxy-accent);border-color:var(--roxy-accent)}.toggle .knob{border-radius:var(--roxy-radius-full);background:var(--roxy-bg);block-size:.8lh;inline-size:.8lh;transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing)}.toggle[aria-checked=true] .knob{transform:translate(100%)}.toggle-label{cursor:pointer}@media (prefers-reduced-motion:reduce){.tile,.toggle,.toggle .knob{transition:none}}.advanced{border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-md)}.advanced>summary{align-items:center;gap:var(--roxy-space-xs);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);color:var(--roxy-fg);display:flex}.advanced[open]>summary{margin-block-end:var(--roxy-space-md)}.repeat-controls{gap:var(--roxy-space-sm);display:flex}.repeat-btn{color:var(--roxy-accent-ink);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);padding:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);cursor:pointer;background:0 0}.repeat-btn:hover{border-color:var(--roxy-accent-ink)}.advanced .fields,.advanced .person-group{margin-block-start:var(--roxy-space-md)}.validation-error{gap:var(--roxy-space-xs);border-inline-start:var(--roxy-line-thick) solid var(--roxy-danger);color:var(--roxy-danger-fg);font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-sm);display:grid}button.submit{min-block-size:var(--roxy-touch);background:var(--roxy-accent-ink);color:var(--roxy-bg);border-radius:var(--roxy-radius-md);padding:var(--roxy-space-sm) var(--roxy-space-lg);font-weight:var(--roxy-weight-bold);cursor:pointer;transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing);border:0;justify-self:start}button.submit:hover{transform:scale(1.02)}@media (prefers-reduced-motion:reduce){button.submit{transition:none}}.field-skeleton{block-size:var(--roxy-touch)}.form-skeleton{block-size:5lh}`],y([w({type:String,attribute:"data-endpoint"})],g.prototype,"endpoint",2),y([w({type:String})],g.prototype,"method",2),y([w({type:String,attribute:"spec-url"})],g.prototype,"specUrl",2),y([w({type:String,attribute:"submit-label"})],g.prototype,"submitLabel",2),y([w({type:String,attribute:"publishable-key"})],g.prototype,"publishableKey",2),y([w({type:String,attribute:"location-url"})],g.prototype,"locationUrl",2),y([w({attribute:false})],g.prototype,"initialValues",2),y([w({attribute:false})],g.prototype,"serverIssues",2),y([w({attribute:false})],g.prototype,"apiRoute",2),y([w({attribute:false})],g.prototype,"autoload",2),y([w({attribute:false})],g.prototype,"fullPages",2),y([E()],g.prototype,"choices",2),y([E()],g.prototype,"clearedIssues",2),y([E()],g.prototype,"fields",2),y([E()],g.prototype,"repeats",2),y([E()],g.prototype,"formTitle",2),y([E()],g.prototype,"hasLang",2),y([E()],g.prototype,"values",2),y([E()],g.prototype,"loaded",2),y([E()],g.prototype,"specError",2),y([E()],g.prototype,"validationErrors",2),g=y([Xt("roxy-endpoint-form")],g);return Pr(Rn)})();
3
+ \f\r"'\`<>=]|("|')|))|$)`,"g"),ft=/'/g,mt=/"/g,xt=/^(?:script|style|textarea|title)$/i,Ie=n=>(t,...e)=>({_$litType$:n,strings:t,values:e}),h=Ie(1),Dn=Ie(2),Pn=Ie(3),A=Symbol.for("lit-noChange"),p=Symbol.for("lit-nothing"),gt=new WeakMap,I=N.createTreeWalker(N,129);function bt(n,t){if(!Ue(n)||!n.hasOwnProperty("raw"))throw Error("invalid template strings array");return ut!==void 0?ut.createHTML(t):t}var vt=(n,t)=>{let e=n.length-1,r=[],i,o=t===2?"<svg>":t===3?"<math>":"",s=V;for(let a=0;a<e;a++){let d=n[a],u,c,m=-1,l=0;for(;l<d.length&&(s.lastIndex=l,c=s.exec(d),c!==null);)l=s.lastIndex,s===V?c[1]==="!--"?s=pt:c[1]!==void 0?s=ht:c[2]!==void 0?(xt.test(c[2])&&(i=RegExp("</"+c[2],"g")),s=U):c[3]!==void 0&&(s=U):s===U?c[0]===">"?(s=i??V,m=-1):c[1]===void 0?m=-2:(m=s.lastIndex-c[2].length,u=c[1],s=c[3]===void 0?U:c[3]==='"'?mt:ft):s===mt||s===ft?s=U:s===pt||s===ht?s=V:(s=U,i=void 0);let f=s===U&&n[a+1].startsWith("/>")?" ":"";o+=s===V?d+Kr:m>=0?(r.push(u),d.slice(0,m)+De+d.slice(m)+C+f):d+C+(m===-2?a:f)}return[bt(n,o+(n[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),r]},J=class n{constructor({strings:t,_$litType$:e},r){let i;this.parts=[];let o=0,s=0,a=t.length-1,d=this.parts,[u,c]=vt(t,e);if(this.el=n.createElement(u,r),I.currentNode=this.el.content,e===2||e===3){let m=this.el.content.firstChild;m.replaceWith(...m.childNodes)}for(;(i=I.nextNode())!==null&&d.length<a;){if(i.nodeType===1){if(i.hasAttributes())for(let m of i.getAttributeNames())if(m.endsWith(De)){let l=c[s++],f=i.getAttribute(m).split(C),x=/([.?@])?(.*)/.exec(l);d.push({type:1,index:o,name:x[2],strings:f,ctor:x[1]==="."?se:x[1]==="?"?ae:x[1]==="@"?le:q}),i.removeAttribute(m)}else m.startsWith(C)&&(d.push({type:6,index:o}),i.removeAttribute(m));if(xt.test(i.tagName)){let m=i.textContent.split(C),l=m.length-1;if(l>0){i.textContent=ie?ie.emptyScript:"";for(let f=0;f<l;f++)i.append(m[f],Z()),I.nextNode(),d.push({type:2,index:++o});i.append(m[l],Z())}}}else if(i.nodeType===8)if(i.data===Pe)d.push({type:2,index:o});else{let m=-1;for(;(m=i.data.indexOf(C,m+1))!==-1;)d.push({type:7,index:o}),m+=C.length-1}o++}}static createElement(t,e){let r=N.createElement("template");return r.innerHTML=t,r}};function M(n,t,e=n,r){if(t===A)return t;let i=r!==void 0?e._$Co?.[r]:e._$Cl,o=W(t)?void 0:t._$litDirective$;return i?.constructor!==o&&(i?._$AO?.(false),o===void 0?i=void 0:(i=new o(n),i._$AT(n,e,r)),r!==void 0?(e._$Co??=[])[r]=i:e._$Cl=i),i!==void 0&&(t=M(n,i._$AS(n,t.values),i,r)),t}var oe=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:r}=this._$AD,i=(t?.creationScope??N).importNode(e,true);I.currentNode=i;let o=I.nextNode(),s=0,a=0,d=r[0];for(;d!==void 0;){if(s===d.index){let u;d.type===2?u=new B(o,o.nextSibling,this,t):d.type===1?u=new d.ctor(o,d.name,d.strings,this,t):d.type===6&&(u=new de(o,this,t)),this._$AV.push(u),d=r[++a]}s!==d?.index&&(o=I.nextNode(),s++)}return I.currentNode=N,i}p(t){let e=0;for(let r of this._$AV)r!==void 0&&(r.strings!==void 0?(r._$AI(t,r,e),e+=r.strings.length-2):r._$AI(t[e])),e++}},B=class n{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,r,i){this.type=2,this._$AH=p,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=r,this.options=i,this._$Cv=i?.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=M(this,t,e),W(t)?t===p||t==null||t===""?(this._$AH!==p&&this._$AR(),this._$AH=p):t!==this._$AH&&t!==A&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):yt(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!==p&&W(this._$AH)?this._$AA.nextSibling.data=t:this.T(N.createTextNode(t)),this._$AH=t}$(t){let{values:e,_$litType$:r}=t,i=typeof r=="number"?this._$AC(t):(r.el===void 0&&(r.el=J.createElement(bt(r.h,r.h[0]),this.options)),r);if(this._$AH?._$AD===i)this._$AH.p(e);else{let o=new oe(i,this),s=o.u(this.options);o.p(e),this.T(s),this._$AH=o}}_$AC(t){let e=gt.get(t.strings);return e===void 0&&gt.set(t.strings,e=new J(t)),e}k(t){Ue(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,r,i=0;for(let o of t)i===e.length?e.push(r=new n(this.O(Z()),this.O(Z()),this,this.options)):r=e[i],r._$AI(o),i++;i<e.length&&(this._$AR(r&&r._$AB.nextSibling,i),e.length=i)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(false,true,e);t!==this._$AB;){let r=ct(t).nextSibling;ct(t).remove(),t=r}}setConnected(t){this._$AM===void 0&&(this._$Cv=t,this._$AP?.(t))}},q=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,r,i,o){this.type=1,this._$AH=p,this._$AN=void 0,this.element=t,this.name=e,this._$AM=i,this.options=o,r.length>2||r[0]!==""||r[1]!==""?(this._$AH=Array(r.length-1).fill(new String),this.strings=r):this._$AH=p}_$AI(t,e=this,r,i){let o=this.strings,s=false;if(o===void 0)t=M(this,t,e,0),s=!W(t)||t!==this._$AH&&t!==A,s&&(this._$AH=t);else{let a=t,d,u;for(t=o[0],d=0;d<o.length-1;d++)u=M(this,a[r+d],e,d),u===A&&(u=this._$AH[d]),s||=!W(u)||u!==this._$AH[d],u===p?t=p:t!==p&&(t+=(u??"")+o[d+1]),this._$AH[d]=u}s&&!i&&this.j(t)}j(t){t===p?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},se=class extends q{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===p?void 0:t}},ae=class extends q{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==p)}},le=class extends q{constructor(t,e,r,i,o){super(t,e,r,i,o),this.type=5}_$AI(t,e=this){if((t=M(this,t,e,0)??p)===A)return;let r=this._$AH,i=t===p&&r!==p||t.capture!==r.capture||t.once!==r.once||t.passive!==r.passive,o=t!==p&&(r===p||i);i&&this.element.removeEventListener(this.name,this,r),o&&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)}},de=class{constructor(t,e,r){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=r}get _$AU(){return this._$AM._$AU}_$AI(t){M(this,t)}},$t={M:De,P:C,A:Pe,C:1,L:vt,R:oe,D:yt,V:M,I:B,H:q,N:ae,U:le,B:se,F:de},jr=Fe.litHtmlPolyfillSupport;jr?.(J,B),(Fe.litHtmlVersions??=[]).push("3.3.3");var kt=(n,t,e)=>{let r=e?.renderBefore??t,i=r._$litPart$;if(i===void 0){let o=e?.renderBefore??null;r._$litPart$=i=new B(t.insertBefore(Z(),o),o,void 0,e??{})}return i._$AI(n),i};var Ne=globalThis,F=class extends T{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=kt(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(true)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(false)}render(){return A}};F._$litElement$=true,F.finalized=true,Ne.litElementHydrateSupport?.({LitElement:F});var Gr=Ne.litElementPolyfillSupport;Gr?.({LitElement:F});(Ne.litElementVersions??=[]).push("4.2.2");var Yr={attribute:true,type:String,converter:Y,reflect:false,hasChanged:ne},Vr=(n=Yr,t,e)=>{let{kind:r,metadata:i}=e,o=globalThis.litPropertyMetadata.get(i);if(o===void 0&&globalThis.litPropertyMetadata.set(i,o=new Map),r==="setter"&&((n=Object.create(n)).wrapped=true),o.set(e.name,n),r==="accessor"){let{name:s}=e;return{set(a){let d=t.get.call(this);t.set.call(this,a),this.requestUpdate(s,d,n,true,a)},init(a){return a!==void 0&&this.C(s,void 0,n,a),a}}}if(r==="setter"){let{name:s}=e;return function(a){let d=this[s];t.call(this,a),this.requestUpdate(s,d,n,true,a)}}throw Error("Unsupported decorator location: "+r)};function w(n){return(t,e)=>typeof e=="object"?Vr(n,t,e):((r,i,o)=>{let s=i.hasOwnProperty(o);return i.constructor.createProperty(o,r),s?Object.getOwnPropertyDescriptor(i,o):void 0})(n,t,e)}function E(n){return w({...n,state:true,attribute:false})}var k=n=>n??p;var H={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},wt=n=>(...t)=>({_$litDirective$:n,values:t}),ue=class{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,r){this._$Ct=t,this._$AM=e,this._$Ci=r}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}};var{I:Ei}=$t;var At=n=>n.strings===void 0;var Zr={},St=(n,t=Zr)=>n._$AH=t;var _t=wt(class extends ue{constructor(n){if(super(n),n.type!==H.PROPERTY&&n.type!==H.ATTRIBUTE&&n.type!==H.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!At(n))throw Error("`live` bindings can only contain a single expression")}render(n){return n}update(n,[t]){if(t===A||t===p)return t;let e=n.element,r=n.name;if(n.type===H.PROPERTY){if(t===e[r])return A}else if(n.type===H.BOOLEAN_ATTRIBUTE){if(!!t===e.hasAttribute(r))return A}else if(n.type===H.ATTRIBUTE&&e.getAttribute(r)===t+"")return A;return St(n),t}});var L={accent:"Accent color",afterSunset:"Born after sunset",allowDuplicates:"Allow duplicate cards",allowReversals:"Allow reversed cards",angelDating:"How the name of the day is dated",annualFromYear:"Annual pillars from year",annualYears:"Years of annual pillars",approximateDate:"Approximate date",aspectTypes:"Aspect types",atbashOutput:"AtBash and Albam output",avasthaInfo:"Include avastha details",avoidAnimal:"Avoid clashes with",ayadiText:"Ayadi text family",ayanamsaValue:"Custom ayanamsa value",birthData:"Birth details",birthDate:"Birth date",birthLatitude:"Birth latitude",birthLongitude:"Birth longitude",birthTime:"Birth time",ciphers:"Ciphers to return",colors:"Brand colors",context:"Where you saw it",coordinateSystem:"Coordinate system",correlation:"Correlation constant",count:"How many",currentYear:"Current year",cuts:"Cut corners",dasha:"Dasha lords",datetime:"Date and time",dayBoundary:"Day boundary",depth:"Depth, north to south",directionScheme:"Direction reading",division:"Divisional chart",domainWeights:"Domain weights",door:"Door coordinates",doorPosition:"Door position along the side",doshaClock:"How the dosha periods are cut",endDate:"End date",endDatetime:"End date and time",expression:"Expression number",extensions:"Extended corners",facing:"Facing direction",facingDegrees:"Facing degrees",family:"Yoga family",firstName:"First name",firstNameHebrew:"First name in Hebrew",font:"Typeface",footer:"Footer line",fullName:"Full name",gainHouses:"Gain houses",grid:"Mandala grid",hastaInches:"Length of one hasta in inches",horaryNumber:"Horary number",hourClock:"Hour clock",houseSystem:"House system",id:"ID",include:"Additional bodies",includeMatches:"Include equal value matches",interpretation:"Position meaning",intervalMinutes:"Interval in minutes",isLeapMonth:"Leap month",iso2:"Country code",kua:"Kua number",lang:"Language",latinCiphers:"Also score the Latin ciphers",leapDayPolicy:"Where 29 February falls",letter:"Starting letter",letterAttribution:"Letter attribution reading",lifePath:"Life Path number",limit:"Results per page",lines:"Line pattern",logo:"Logo URL",lossHouses:"Loss houses",lunarDay:"Lunar day",lunarMonth:"Lunar month",lunarYear:"Lunar year",members:"Group members",minSignificance:"Minimum significance",minStrength:"Minimum strength",misparGadol:"Mispar gadol method",modernPlanets:"Include modern planets",moonWindows:"Moon windows",muhurtaText:"Muhurta text",nameHebrew:"Name in Hebrew",natalChart:"Natal chart",nodeType:"Lunar node type",offset:"Results to skip",polygon:"Outline",positions:"Spread positions",primary:"Primary color",q:"Search",question:"Your question",readings:"Include readings",relocationLatitude:"Relocation latitude",relocationLongitude:"Relocation longitude",returnDate:"Return date",returnYear:"Return year",ritucharyaScheme:"Season division",rituZodiac:"Zodiac the season boundaries are measured in",road:"Road side",rulingPlanets:"Ruling planets",scheme:"Karaka scheme",secondName:"Second name",secondNameHebrew:"Second name in Hebrew",sephirotSystem:"Sephirot reading",sign:"Zodiac sign",sign1:"First animal sign",sign2:"Second animal sign",signDoshaScheme:"Sign humour table",significators:"Include KP significators",size:"Paper size",slopeLowDirection:"Direction the ground falls toward",slopeSchool:"Ground level school",soulUrge:"Soul Urge number",spreadName:"Spread name",startDate:"Start date",startDatetime:"Start date and time",strictOrbs:"Use tighter orbs",system:"Avastha system",targetDate:"Target date",targetMonth:"Target month",text:"Word or name",textHebrew:"Hebrew word or name",top:"Top events per window",transitDate:"Transit date",transitTime:"Transit time",transliteration:"Transliteration scheme",treeVariant:"Tree arrangement",type:"Pattern type",vyayaFormula:"Vyaya formula",water:"Standing water direction",weights:"Layer weights",width:"Width, east to west",x:"Distance east",y:"Distance north",yearBearerSystem:"Year Bearer school",yearBoundary:"Year boundary",yearStart:"Wheel year start",zodiac:"Zodiac sign"};var Et=["de","en","es","fr","hi","pt","ru","tr","zh-Hans","zh-Hant"];function qe(n){if(n.lang)return n.lang;if(typeof document>"u")return;let t=n.closest?.("[lang]")?.getAttribute("lang");return t||document.documentElement.lang||void 0}function Rt(n){return!n||n.toLowerCase().split("-")[0]==="en"}var Wr={tw:"hant",hk:"hant",mo:"hant",cn:"hans",sg:"hans",my:"hans"};function Me(n,t){let e=n.toLowerCase();return t.find(r=>r.toLowerCase()===e)}function Tt(n,t=Et){let e=qe(n);if(!e)return;let r=Me(e,t);if(r)return r;let i=e.toLowerCase().split("-"),o=i[0];if(o==="zh"){let s=i.find(a=>a==="hans"||a==="hant")??Wr[i[1]??""];return s?Me(`zh-${s}`,t):void 0}return Me(o,t)}var Ot="symbols";var Jr={Fraunces:["latin","latin-ext"],Jost:["latin","latin-ext","cyrillic"],Geist:["latin","latin-ext","cyrillic"]},He='"Jost", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',Ct='"Geist", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',Lt='system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif',pe={"fraunces-jost":{name:"Fraunces with Jost",sans:He,display:'"Fraunces", ui-serif, Georgia, Cambria, "Times New Roman", Times, serif'},jost:{name:"Jost",sans:He,display:He},geist:{name:"Geist",sans:Ct,display:Ct},system:{name:"System",sans:Lt,display:Lt}};function Ft(n){let{sans:t,display:e}=pe[n];return Object.keys(Jr).filter(r=>`${t} ${e}`.includes(`"${r}"`))}var he="1.7.0";var Xr=/^(.*)\/cdn\/(?:roxy-ui|components\/[\w-]+)\.js$/,Qr=/^(.*\/dist)\/(?:index|components\/[\w-]+)\.js$/;function fe(n,t){if(!t)return;let e=new URL(t);if(e.protocol!=="https:"&&e.protocol!=="http:")return;let r=(Xr.exec(e.pathname)??Qr.exec(e.pathname))?.[1];if(r!==void 0)return e.hostname==="cdn.jsdelivr.net"?`https://cdn.jsdelivr.net/npm/@roxyapi/ui@${n}/dist`:`${e.origin}${r}`}var en={};function Dt(n){return n!==void 0&&Object.hasOwn(pe,n)}function Pt(n,t){if(Dt(t))return t;let e=n.getRootNode();if(("host"in e?e.host:null)?.localName.startsWith("roxy-")||!globalThis.getComputedStyle)return;let i=n.shadowRoot?.firstElementChild,o=i?.localName==="style"?i:null;o?.sheet&&(o.sheet.disabled=true);let s,a,d;try{let u=globalThis.getComputedStyle(n),c=m=>u.getPropertyValue(m).trim();s=c("--roxy-font-sans"),a=c("--roxy-font-display"),d=c("--roxy-font")}finally{o?.sheet&&(o.sheet.disabled=false)}if(!(s||a))return Dt(d)?d:void 0}function Ut(n){let{sans:t,display:e}=pe[n];return`--roxy-font:${n};--roxy-font-sans:${t};--roxy-font-display:${e}`}var It=fe(he,globalThis.document?.currentScript?.src||en.url);function Nt(n,t){if(typeof document>"u"||t===void 0)return;let e=`roxy-ui-font-${n}`;if(document.getElementById(e))return;let r=document.createElement("link");r.id=e,r.rel="stylesheet",r.href=`${t}/styles/fonts/${n}.css`,document.head.append(r)}function Mt(n,t=It){Ft(n).length>0&&Nt(n,t)}function qt(n=It){Nt(Ot,n)}var Ht='@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-moon-shade: color-mix(in oklab, var(--roxy-fg) 78%, var(--roxy-bg));--roxy-font: initial;--roxy-font-sans: initial;--roxy-font-mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, "Liberation Mono", monospace;--roxy-font-symbol: "Roxy Symbols", ui-sans-serif, system-ui, sans-serif;--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-moon-lit: color-mix(in oklab, var(--roxy-accent) 6%, #f6eedf);--roxy-moon-mare: color-mix( in oklab, var(--roxy-moon-lit) 62%, var(--roxy-moon-shade) );--roxy-moon-rim: color-mix( in oklab, var(--roxy-moon-shade) 70%, var(--roxy-fg) );--roxy-moon-eclipse: color-mix( in oklab, color-mix(in oklab, var(--roxy-danger) 55%, var(--roxy-warning)) 72%, var(--roxy-moon-shade) );--roxy-moon-corona: color-mix( in oklab, var(--roxy-warning) 60%, var(--roxy-moon-lit) );--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);--roxy-moon-shade: color-mix( in oklab, var(--roxy-fg) 10%, var(--roxy-bg) )}}: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);--roxy-moon-shade: color-mix(in oklab, var(--roxy-fg) 78%, var(--roxy-bg))}: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);--roxy-moon-shade: color-mix(in oklab, var(--roxy-fg) 10%, var(--roxy-bg))}@media(prefers-reduced-motion:reduce){:where(:root,:host){--roxy-motion-duration: 0ms}}}';var me="roxy-ui-tokens";function ge(){if(typeof document>"u")return null;let n=document.getElementById(me);if(n)return n;let t=document.createElement("style");return t.id=me,t.textContent=Ht,document.head.prepend(t),t}function ye(n){return n.toLowerCase().replace(/[\s_-]+/g," ").trim()}function R(n){return n.replace(/[_-]+/g," ").replace(/([a-z])([A-Z])/g,"$1 $2").replace(/([a-z])([0-9])/g,"$1 $2").replace(/^\w/,t=>t.toUpperCase())}var zt="__ROXY_UI_I18N__";function ze(){let n=globalThis,t=n[zt];if(t)return t;let e={catalogs:{},fieldLabels:{},requested:new Set,listeners:new Set};return n[zt]=e,e}function Be(n,t){return t?n.replace(/\{\{(\w+)\}\}/g,(e,r)=>r in t?String(t[r]??""):e):n}function Bt(n,t,e){return Be(Ke(n,t)??t,e)}function Ke(n,t){if(!n)return;let{catalogs:e}=ze(),r=n.toLowerCase();return(e[r]??e[r.split("-")[0]])?.[ye(t)]}function Kt(n){if(!n)return;let{fieldLabels:t}=ze(),e=n.toLowerCase();return t[e]??t[e.split("-")[0]]}function K(n,t){return Kt(n)?.fields[t]}function jt(n,t,e){return Kt(n)?.enums[`${t}.${e}`]}function Gt(n){let{listeners:t}=ze();return t.add(n),()=>{t.delete(n)}}var xe=class{constructor(t){this.host=t,t.addController(this)}hostConnected(){this.unsubscribe=Gt(()=>this.host.requestUpdate())}hostDisconnected(){this.unsubscribe?.(),this.unsubscribe=void 0}};var be=class extends F{constructor(){super();this.translator=(e,r)=>this.t(e,r);new xe(this)}connectedCallback(){super.connectedCallback(),ge()}updated(e){super.updated(e),this.renderRoot.querySelector(".roxy-glyph")&&qt()}fontDeclarations(e){let r=Pt(this,e);return r?(Mt(r),Ut(r)):""}renderFontStyle(){let e=this.fontDeclarations();return e?h`<style>:host{${e}}</style>`:p}t(e,r){return Bt(this.effectiveLang(),e,r)}effectiveLang(){return qe(this)}};var tn=new RegExp("(?![\\d#*])\\p{Emoji}","gu"),rn=n=>n.replace(tn,"$&\uFE0E"),ve=n=>Object.fromEntries(Object.entries(n).map(([t,e])=>[t,rn(e)])),nn=(n,t)=>t?n[ye(t)]:void 0,co=ve({sun:"\u2609",moon:"\u263D",mercury:"\u263F",venus:"\u2640",earth:"\u2641",mars:"\u2642",jupiter:"\u2643",saturn:"\u2644",uranus:"\u2645",neptune:"\u2646",pluto:"\u2BD3",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"});var on=ve({aries:"\u2648",taurus:"\u2649",gemini:"\u264A",cancer:"\u264B",leo:"\u264C",virgo:"\u264D",libra:"\u264E",scorpio:"\u264F",sagittarius:"\u2650",capricorn:"\u2651",aquarius:"\u2652",pisces:"\u2653"}),Yt=n=>nn(on,n);var Vt=["Aries","Taurus","Gemini","Cancer","Leo","Virgo","Libra","Scorpio","Sagittarius","Capricorn","Aquarius","Pisces"],uo=ve({conjunction:"\u260C",semisextile:"\u26BA","semi sextile":"\u26BA",semisquare:"\u2220","semi square":"\u2220",sextile:"\u26B9",square:"\u25A1",trine:"\u25B3",sesquiquadrate:"\u26BC",quincunx:"\u26BB",opposition:"\u260D"});var po=ve({heaven:"\u2630",lake:"\u2631",fire:"\u2632",thunder:"\u2633",wind:"\u2634",water:"\u2635",mountain:"\u2636",earth:"\u2637"});var Zt=$`:where(.roxy-glyph){font-family:var(--roxy-font-symbol)}`;var Wt=$`: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 sn=$`: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);letter-spacing:var(--roxy-tracking-normal);word-spacing: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(:focus){outline:none!important}: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}`,Jt=[sn,Wt,Zt];var Xt=n=>t=>{customElements.get(n)||customElements.define(n,t)};function je(){return h`<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 Qt=$`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 an="pk_live_YOUR_KEY",er={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 X(n){if(n)return n===an?er.sample:n.startsWith("pk_")?void 0:er.secret}function Ge(n,t,e={}){e.warn&&console.warn(t.message),n.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{reason:t.reason,message:t.message},bubbles:true,composed:true}))}var Ye="https://roxyapi.com/api/v2";async function ln(n){try{let t=await n.json();if(t?.error){let e=t.code==="validation_error"&&Array.isArray(t.issues)?t.issues.filter(r=>typeof r.path=="string"&&typeof r.message=="string").map(r=>({path:r.path,message:r.message})):null;return{message:t.error,issues:e?.length?e:null,worded:true,...t.code?{code:t.code}:{}}}}catch{}return{message:`Request failed (${n.status})`,issues:null,worded:false}}var $e=class extends Error{constructor(e,r=null,i=true,o,s){super(e);this.issues=r;this.worded=i;this.status=o;this.code=s}};function tr(n){return n.submitUrl?void 0:X(n.publishableKey)}function Ve(n){return!!(n.submitUrl||n.publishableKey&&!tr(n))}async function Ze(n,t,e){let r=tr(n);if(r)throw new $e(r.message);let i=n.submitUrl?await fetch(n.submitUrl,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:dn(t,n.submitContext),signal:e}):await cn(n,t,e);if(!i.ok){let o=await ln(i);throw new $e(o.message,o.issues,o.worded,i.status,o.code)}return await i.json()}function dn(n,t){return JSON.stringify(t?{...n,context:t}:n)}function cn(n,t,e){let r=new URL(`${n.baseUrl??Ye}${t.path}`,document.baseURI);for(let[o,s]of Object.entries(t.query??{}))s!=null&&r.searchParams.set(o,String(s));let i={Accept:"application/json"};return n.publishableKey&&(i["X-API-Key"]=n.publishableKey),t.body!=null&&(i["Content-Type"]="application/json"),fetch(r,{method:t.method??"GET",headers:i,body:t.body!=null?JSON.stringify(t.body):void 0,signal:e})}var rr={"GET /angel-numbers/numbers/{number}":{number:{path:"/angel-numbers/numbers",limit:50,lang:true}},"GET /astrology/planet-meanings/{id}":{id:{path:"/astrology/planet-meanings",lang:true}},"GET /astrology/signs/{id}":{id:{path:"/astrology/signs",lang:true}},"GET /crystals":{color:{path:"/crystals/colors",lang:true},planet:{path:"/crystals/planets",lang:true}},"GET /crystals/{id}":{id:{path:"/crystals",limit:100,lang:true}},"GET /dreams/symbols":{letter:{path:"/dreams/symbols/letters"}},"GET /dreams/symbols/{id}":{id:{path:"/dreams/symbols",search:"q",limit:50}},"GET /iching/trigrams/{id}":{id:{path:"/iching/trigrams",lang:true}},"GET /tarot/cards/{id}":{id:{path:"/tarot/cards",limit:100,lang:true}}},nr={"GET /tarot/cards":{suit:{field:"arcana",value:"major"}}};var S=(n,t)=>`${n}.${t}`;function we(n){let t=/^(.+)\.(\d+)$/.exec(n);return t?{key:t[1],index:Number(t[2])}:null}function Ae(n,t=Be,e=r=>L[r]??R(r)){let r=we(n);return r?t("{{group}} {{n}}",{group:e(r.key),n:r.index+1}):t(R(n))}function or(n,t){let e=t.key??t.name;if(ar(e))return K(n,e);if(!t.label)return K(n,t.name);let r=Object.keys(L).find(i=>L[i]===t.label);return Ke(n,t.label)??(r?K(n,r):void 0)}function sr(n,t,e){let r=S(t,0);return n.filter(i=>i.group===r).map(i=>({...i,key:`${S(t,e)}.${i.name}`,group:S(t,e)}))}function Xe(n){return n.length<=(Se(n)?30:12)?"tiles":"select"}function Se(n){return n.every(t=>t.length<=2)}var un=["format","branding","readings"],pn=["latitude","longitude","timezone"],ir=["latitude","longitude"];function ar(n){let t=n.match(/^(.+?)(Latitude|Longitude)$/);return t?{group:t[1],leaf:t[2].toLowerCase()}:null}var hn=Vt.map(n=>n.toLowerCase());function D(n,t){if(n){if("$ref"in n&&n.$ref){let e=n.$ref.split("/").pop();return e?t[e]:void 0}return n}}function lr(n){let t=n.anyOf??n.oneOf;return!t||t.length===0?n:t.find(e=>Array.isArray(e.enum))??t.find(e=>Je(e)&&Je(e)!=="null")??t[0]??n}function Je(n){if(typeof n.type=="string")return n.type;if(!Array.isArray(n.type))return;let t=n.type.filter(e=>e!=="null");return t.length===1?t[0]:void 0}function fn(n){let t=lr(n),e=Je(t);return Array.isArray(t.enum)?Xe(t.enum):e==="boolean"?"toggle":t.format==="date"?"date":t.format==="time"?"time":t.format==="date-time"?"datetime":e==="integer"||e==="number"?"number":e==="string"?"text":e==="array"?"array":null}function dr(n){if(n.length!==12)return false;let t=new Set(n.map(e=>e.toLowerCase()));return hn.every(e=>t.has(e))}function ke(n,t,e){let r=lr(t);return{key:e.key,name:n,group:e.group,inQuery:e.inQuery,kind:fn(t)??"text",required:e.required,description:r.description??t.description,enum:r.enum,min:r.minimum??r.exclusiveMinimum,max:r.maximum??r.exclusiveMaximum,default:t.default??r.default,example:t.example??r.example}}function We(n){return new Set([...n.required??[],...n["x-required-any-of"]?.[0]??[]])}function cr(n,t,e,r=n.requestBody?"POST":"GET"){let i=[],o=[],s=false,a,d=n.requestBody?.content?.["application/json"]?.schema,u=D(d,t),c=u?.["x-required-any-of"],m=(n["x-request-cost"]??1)>1;if(u?.properties){let l=We(u);for(let[f,x]of Object.entries(u.properties)){if(m&&un.includes(f))continue;let v=D(x,t)??{},b=v.type==="array"?D(v.items,t):void 0;if(b?.type==="object"&&b.properties){let _=Math.max(1,v.minItems??1),O=We(b);o.push({key:f,min:_,max:v.maxItems??_});for(let z=0;z<_;z++)for(let[P,Tr]of Object.entries(b.properties)){let Cr=D(Tr,t)??{};i.push(ke(P,Cr,{key:`${S(f,z)}.${P}`,group:S(f,z),required:l.has(f)&&O.has(P)}))}}else if(v.type==="object"&&v.properties){let _=We(v);for(let[O,z]of Object.entries(v.properties)){let P=D(z,t)??{};P.type==="array"&&D(P.items,t)?.type==="object"||i.push(ke(O,P,{key:`${f}.${O}`,group:f,required:l.has(f)&&_.has(O)}))}}else{let _=ar(f),O=ke(_?.leaf??f,v,{key:f,group:_?.group,required:l.has(f)});_&&(O.label=`${R(_.group)} ${_.leaf}`),i.push(O)}}}for(let l of n.parameters??[]){if(l.in!=="path"&&l.in!=="query")continue;if(l.name==="lang"&&l.in==="query"){s=true,a=D(l.schema,t)?.enum?.filter(v=>typeof v=="string");continue}let f=D(l.schema,t)??{},x=ke(l.name,f,{key:l.name,required:!!l.required,inQuery:l.in==="query"});if(l.in==="path"&&x.enum&&/^(id|identifier|slug)$/i.test(L[x.name]??R(x.name))){let v=/^([A-Za-z][A-Za-z -]*?)\s+(?:id|identifier|slug)\b/i.exec(l.description??x.description??"")?.[1]?.trim();v&&(x.label=v)}i.push(x)}for(let l of i)!l.group&&!l.label&&i.some(f=>f.group&&f.name===l.name)&&(l.label=mn(l));return Qe({title:gn(n.summary,e),fields:i,hasLang:s,...a?.length?{langs:a}:{},...o.length>0?{repeats:o}:{},...c?{requiredAnyOf:c}:{}},r,e)}function mn(n){let e=(L[n.name]??R(n.name)).toLowerCase().replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),r=new RegExp(`^(\\p{L}+) ${e}\\b`,"iu").exec(n.description??"")?.[1];return r?L[r.toLowerCase()+n.name.replace(/^./,i=>i.toUpperCase())]:void 0}function Qe(n,t,e){let r=`${t.toUpperCase()} /${e.replace(/^\//,"")}`,i=rr[r]??{},o=nr[r]??{},s=n.fields.map(l=>{let f={...l};return delete f.role,delete f.city,delete f.viewerZone,delete f.moment,delete f.fold,{...f,...i[l.key]&&{source:i[l.key]},...o[l.key]&&{disabledWhen:o[l.key]}}}),a=[...new Set(s.map(l=>l.group))].map(l=>l===void 0?{}:{key:l,label:Ae(l)}),d=a.filter(l=>ir.every(f=>s.some(x=>x.group===l.key&&x.name===f)));for(let[l,f]of d.entries()){let x=s.filter(b=>b.group===f.key),v=x.find(b=>b.name==="timezone")??(l===0?s.find(b=>!b.group&&b.name==="timezone"):void 0);f.location={fields:[...x.filter(b=>ir.includes(b.name)).map(b=>b.key),...v?[v.key]:[]],required:x.some(b=>pn.includes(b.name)&&b.required)}}for(let l of s)l.name==="seed"?l.role="seed":(l.name==="limit"||l.name==="offset")&&!l.required?l.role="hidden-default":d.some(f=>f.location?.fields.includes(l.key))?l.role="location":l.name==="timezone"&&(l.city=true,!l.group&&!l.required&&(l.viewerZone=true));let u=a.filter(l=>l.key!==void 0&&(l.location||s.some(f=>f.group===l.key&&f.required))),c=s.some(l=>!l.group&&!l.role&&l.required)||u.length>0||d.some(l=>l.key===void 0);for(let l of a)l.key!==void 0&&c&&!u.includes(l)&&(l.fold=true);let m=l=>u.length>0&&l.default===void 0&&(l.kind==="date"||l.kind==="time"||l.kind==="datetime");for(let l of s)l.group?a.find(f=>f.key===l.group)?.fold&&(l.fold=true):!l.role&&c&&!l.required?m(l)?l.moment=true:l.fold=true:!l.role&&!c&&l.default!==void 0&&(l.fold=true);return{...n,fields:s,groups:a,opensOnLoad:yn(n,t)}}function ur(n,t){let e=n.filter(r=>r.moment);return e.some(r=>r.kind==="time"||r.kind==="datetime")&&e.every(r=>t[r.key]===void 0||t[r.key]==="")}function gn(n,t){let e=n?.split(" - ")[0]?.trim();return e||R(t.split("/").pop()??"")}function yn(n,t){return t.toUpperCase()==="GET"&&!n.fields.some(e=>e.required)}function pr(n,t=[]){if(t.some(r=>r.name==="limit"||r.name==="offset"))return"Search";let e=n.toLowerCase();return/compat|synastry|guna|connection|penta|composite/.test(e)?"Compare":/\bcast\b|\/draw|iching|hexagram|tarot/.test(e)?"Cast":/horoscope|dream|angel|nakshatra|crystal|meaning|reference/.test(e)?"Get reading":"Generate"}function hr(n,t){let e=fe(n,t);return e&&`${e}/schemas`}function fr(n,t){let e=t.replace(/^\//,"").replace(/[{}]/g,"").replace(/\//g,"-");return`${n.toLowerCase()}--${e}.json`}function xn(n){if(Array.isArray(n))return n;if(!n||typeof n!="object")return null;let t=Object.values(n),e=t.find(Array.isArray);return e||(t.find(i=>!!i&&typeof i=="object"&&Object.values(i).every(o=>typeof o=="number"))??null)}function et(n,t="id"){let e=xn(n);if(!e)return[];if(!Array.isArray(e)){let i=Object.keys(e),o=i.length>0&&i.every(a=>/^[a-z]$/.test(a));return(o?[..."abcdefghijklmnopqrstuvwxyz"]:i).map(a=>({value:a,label:o?a.toUpperCase():a,disabled:!e[a]}))}let r=[];for(let i of e){if(typeof i=="string"){r.push({value:i,label:i});continue}if(!i||typeof i!="object")continue;let o=i,s=o.id??o[t]??o.number;if(s==null)continue;let a=String(s),d=o.name??o.english;r.push({value:a,label:typeof d=="string"?d:a})}return r}function mr(n){let t=n?.total;return typeof t=="number"?t:void 0}var gr=new Map;function bn(n){if(!n)return["en"];let t=gr.get(n);if(t)return[t,"en"];let e="en";try{e=Intl.getCanonicalLocales(n)[0]??"en"}catch{e="en"}return gr.set(n,e),[e,"en"]}function yr(){try{return new Intl.DateTimeFormat(bn(void 0)).resolvedOptions().timeZone}catch{return}}function xr(n,t,e){return K(n,t)??e??R(t)}function br(n,t,e,r){return jt(n,t,e)??r??R(e)}var vr=$`.spinner{inset-inline-end:calc(var(--roxy-space-unit) * 3);border:var(--roxy-line-thick) solid var(--roxy-muted);border-radius:var(--roxy-radius-full);border-top-color:#0000;block-size:.6lh;inline-size:.6lh;animation:.7s linear infinite roxy-spin;position:absolute;top:50%;transform:translateY(-50%)}@keyframes roxy-spin{to{transform:translateY(-50%)rotate(360deg)}}@media (prefers-reduced-motion:reduce){.spinner{animation:none}}.results{z-index:50;top:calc(100% + var(--roxy-space-xs));padding:var(--roxy-space-xs);background:var(--roxy-bg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);box-shadow:var(--roxy-shadow-md);max-block-size:15lh;animation:roxy-fade-in var(--roxy-motion-duration) var(--roxy-motion-easing);margin:0;list-style:none;position:absolute;left:0;right:0;overflow-y:auto}.option{align-items:center;gap:var(--roxy-space-sm);inline-size:100%;min-block-size:var(--roxy-touch);padding:var(--roxy-space-sm) var(--roxy-space-md);border-radius:var(--roxy-radius-sm);text-align:start;font-size:var(--roxy-text-sm);color:var(--roxy-fg);cursor:pointer;transition:background-color var(--roxy-motion-duration);background:0 0;border:0;display:flex}.option:hover,.option[aria-selected=true]{background:color-mix(in srgb, var(--roxy-accent) 10%, transparent)}.empty{padding:var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-sm)}`;function $r(n,t){let e,r=((...i)=>{e&&clearTimeout(e),e=setTimeout(()=>{e=void 0,n(...i)},t)});return r.cancel=()=>{e&&(clearTimeout(e),e=void 0)},r}var vn=10,$n=10,tt=new Map;function kr(n,t,e={}){return{...n.limit?{limit:n.limit}:{},...n.lang&&t?{lang:t}:{},...e}}function nt(n,t,e,r){let i=JSON.stringify([n.submitUrl??n.baseUrl,t.path,e,r]),o=tt.get(i);return o||(o=kn(n,t,e,r).catch(s=>{throw tt.delete(i),s}),tt.set(i,o)),o}async function kn(n,t,e,r){let i=[];for(let o=0;o<$n;o++){let s=await Ze(n,{path:t.path,method:"GET",query:kr(t,r,i.length?{offset:i.length}:{})}),a=et(s,e);i.push(...a);let d=mr(s);if(!t.limit||d===void 0||i.length>=d||!a.length)break}return i}var rt=n=>n.normalize("NFD").replace(new RegExp("\\p{M}","gu"),"").toLowerCase(),_e=class{constructor(t,e,r,i,o){this.host=t;this.source=e;this.field=r;this.context=i;this.onPick=o;this.query="";this.options=[];this.open=false;this.highlight=-1;this.loading=false;this.error=null;this.search=$r(t2=>{this.searchServer(t2)},250);t.addController(this)}hostDisconnected(){this.search.cancel(),this.abort?.abort()}input(t){this.query=t,this.error=null,this.source.search?t.trim().length<2?this.close():this.search(t):this.filter(t),this.host.requestUpdate()}focus(){!this.source.search&&!this.open&&this.filter(this.query)}close(){this.open=false,this.highlight=-1,this.host.requestUpdate()}pick(t){this.query=t.label,this.close(),this.onPick(t)}keydown(t){let e=this.options.length;if(t.key==="Escape"){this.close();return}if(t.key==="ArrowDown"&&!this.open){t.preventDefault(),this.input(this.query);return}if(!(!this.open||e===0)){if(t.key==="ArrowDown")this.highlight=(this.highlight+1)%e;else if(t.key==="ArrowUp")this.highlight=(this.highlight-1+e)%e;else if(t.key==="Home")this.highlight=0;else if(t.key==="End")this.highlight=e-1;else if(t.key==="Enter"){let r=this.options[this.highlight]??this.options[0];r&&this.pick(r)}else return;t.preventDefault(),this.host.requestUpdate()}}async filter(t){let{route:e,lang:r}=this.context();this.loading=true,this.host.requestUpdate();try{let i=await nt(e,this.source,this.field,r);if(t!==this.query)return;let o=rt(t.trim());this.show(i.filter(s=>rt(s.label).includes(o)||rt(s.value).includes(o)))}catch(i){this.fail(i)}finally{this.loading=false,this.host.requestUpdate()}}async searchServer(t){let{route:e,lang:r}=this.context(),i=this.source.search;this.abort?.abort();let o=new AbortController;this.abort=o,this.loading=true,this.host.requestUpdate();try{let s=await Ze(e,{path:this.source.path,method:"GET",query:kr({...this.source,limit:vn},r,{[i]:t})},o.signal);if(o.signal.aborted)return;this.show(et(s,this.field))}catch(s){if(o.signal.aborted)return;this.fail(s)}finally{this.abort===o&&(this.abort=void 0),o.signal.aborted||(this.loading=false,this.host.requestUpdate())}}show(t){this.options=t,this.open=true,this.highlight=t.length?0:-1}fail(t){this.options=[],this.open=false,this.error=t instanceof Error?t.message:String(t)}};function wr(n,t,e,r={}){let i=`${t}-listbox`;return h`<div class="picker"><input id="${t}" type="text" role="combobox" aria-expanded="${n.open?"true":"false"}" aria-controls="${i}" aria-autocomplete="list" aria-labelledby="${k(r.labelledby)}" aria-describedby="${k(r.describedby)}" aria-invalid="${k(r.invalid?"true":void 0)}" aria-activedescendant="${n.open&&n.highlight>=0?`${t}-opt-${n.highlight}`:""}" autocomplete="off" placeholder="${e.placeholder}" .value="${n.query}" @input="${o=>n.input(o.target.value)}" @keydown="${o=>n.keydown(o)}" @focus="${()=>n.focus()}" @blur="${()=>n.close()}"> ${n.loading?h`<span class="spinner" role="status" aria-label="${e.loading}"></span>`:p} ${n.open?h`<ul id="${i}" class="results" role="listbox">${n.options.length===0?h`<li class="empty" role="status">${e.empty}</li>`:n.options.map((o,s)=>h`<li id="${`${t}-opt-${s}`}" class="option" role="option" aria-selected="${n.highlight===s?"true":"false"}" @mousedown="${a=>a.preventDefault()}" @click="${()=>n.pick(o)}">${o.label}</li>`)}</ul>`:p}</div>${n.error?h`<small class="field-error" role="alert">${n.error}</small>`:p}`}var Ar=[vr,$`.picker{position:relative}`];var En={};var Sr=`${Ye}/openapi.json`,_r=hr(he,globalThis.document?.currentScript?.src||En.url),Ee=new Map,Re=class extends Error{constructor(e){super(`HTTP ${e}`);this.status=e}},Te=class extends Error{constructor(e,r){super(`Endpoint ${e} ${r} not found in OpenAPI spec`);this.method=e;this.path=r}};function wn(){Ee.clear()}async function An(n){let t=Ee.get(n);return t||(t=fetch(n).then(async e=>{if(!e.ok)throw new Re(e.status);return await e.json()}).catch(e=>{throw Ee.delete(n),e}),Ee.set(n,t)),t}function Sn(){return globalThis.crypto?.randomUUID?.()??Math.random().toString(36).slice(2)}var Er=n=>/\bbirth/i.test(n?.description??""),Rr=n=>n.key===`${n.group}.${n.name}`;function _n(n){let t=n.trim();if(!t)return[];try{let e=JSON.parse(t);if(Array.isArray(e))return e}catch{}return t.split(",").map(e=>e.trim()).filter(Boolean)}var g=class extends be{constructor(){super(...arguments);this.endpoint="vedic-astrology/birth-chart";this.method="POST";this.specUrl="";this.submitLabel="";this.serverIssues=null;this.autoload=false;this.fullPages=false;this.choices={};this.pickers=new Map;this.clearedIssues=new Set;this.fields=[];this.groups=[];this.modelOpensOnLoad=false;this.repeats=[];this.formTitle="";this.hasLang=false;this.values={};this.loaded=false;this.specError=null;this.validationErrors=[];this.retryLoadSchema=()=>{this.loaded=false,this.specError=null,this.loadSchema()};this.onSubmit=e=>{e.preventDefault(),this.submit()}}connectedCallback(){super.connectedCallback(),this.loadSchema()}async loadSchema(){this.specError=null;try{this.applyModel(await this.resolveModel())}catch(e){this.specError=this.specErrorMessage(e),this.loaded=true,this.dispatchEvent(new CustomEvent("roxy-spec-error",{detail:{url:this.specUrl||Sr,message:e instanceof Error?e.message:String(e)},bubbles:true,composed:true}))}}specErrorMessage(e){return e instanceof Re?this.t("HTTP error {{status}}",{status:e.status}):e instanceof Te?this.t("Endpoint {{method}} {{path}} not found in OpenAPI spec",{method:e.method,path:e.path}):e instanceof Error?e.message:String(e)}async resolveModel(){return this.specUrl?this.modelFromSpec(this.specUrl):await this.tryLoadSlice()??this.modelFromSpec(Sr)}async modelFromSpec(e){let r=await An(e),i=`/${this.endpoint.replace(/^\//,"")}`,o=r.paths?.[i]?.[this.method.toLowerCase()];if(!o)throw new Te(this.method,i);return cr(o,r.components?.schemas??{},this.endpoint,this.method)}async tryLoadSlice(){if(!_r)return null;try{let e=await fetch(`${_r}/${fr(this.method,this.endpoint)}`);return e.ok?await e.json():null}catch{return null}}applyModel(e){(!e.groups||e.opensOnLoad===void 0)&&(e=Qe(e,this.method,this.endpoint)),this.fields=e.fields,this.groups=e.groups??[],this.modelOpensOnLoad=e.opensOnLoad??false,this.repeats=e.repeats??[],this.formTitle=e.title,this.hasLang=e.hasLang,this.langs=e.langs;let r={};for(let i of e.fields){let o=i.viewerZone?void 0:this.fullPages&&i.name==="limit"&&this.roleOf(i)==="hidden-default"?i.max??i.default:i.default;o!==void 0&&(r[i.key]=o);let s=i.group&&Rr(i)?this.initialValues?.[i.group]?.[i.name]:this.initialValues?.[i.key];s!==void 0&&(r[i.key]=s)}this.values=this.withoutDisabled(r),this.loaded=true,this.loadChoices(),this.autoload&&this.opensOnLoad&&Ve(this.route)&&this.updateComplete.then(()=>this.submit())}get route(){return this.apiRoute??{publishableKey:this.publishableKey}}loadChoices(){for(let r of this.pickers.values())this.removeController(r);if(this.pickers.clear(),!Ve(this.route))return;let e=()=>({route:this.route,lang:this.requestLang()});for(let r of this.fields)if(r.source){if(r.required){let i=new _e(this,r.source,r.name,e,o=>this.pickChoice(r,o.value));i.query=String(this.values[r.key]??""),this.pickers.set(r.key,i);continue}this.choices={...this.choices,[r.key]:"loading"},nt(this.route,r.source,r.name,this.requestLang()).then(i=>{this.choices={...this.choices,[r.key]:i}},()=>{let{[r.key]:i,...o}=this.choices;this.choices=o})}}setValue(e,r){this.setValues({[e]:r})}setValues(e){this.values=this.withoutDisabled({...this.values,...e});let r=Object.keys(e).filter(i=>this.serverIssues?.some(o=>o.path===i));r.length&&(this.clearedIssues=new Set([...this.clearedIssues,...r]))}isDisabled(e,r=this.values){let i=e.disabledWhen;return!!i&&r[i.field]===i.value}withoutDisabled(e){for(let r of this.fields)this.isDisabled(r,e)&&(e[r.key]=void 0);return e}willUpdate(e){e.has("serverIssues")&&(this.clearedIssues=new Set);let r=e.has("publishableKey")?X(this.publishableKey):void 0;r&&Ge(this,r,{warn:true})}liveIssues(){return(this.serverIssues??[]).filter(e=>!this.clearedIssues.has(e.path))}issueFor(e){return this.liveIssues().find(r=>r.path===e.key)}cityIssues(e){return this.liveIssues().filter(r=>{let i=this.fields.find(o=>o.key===r.path);return!!i&&this.roleOf(i)==="location"&&this.cityGroup(i)===e})}issuesForGroup(e){return this.liveIssues().filter(r=>r.path===e)}fieldLabel(e){return this.roleOf(e)==="location"||e.city?this.locationLabel(this.cityGroup(e)):e.group?`${this.groupName(e.group)} ${this.fieldText(e)}`:this.fieldText(e)}issueLines(e){return e.map(r=>h`<small part="field-error" class="field-error" role="alert">${r.message}</small>`)}fieldIssue(e){let r=this.issueFor(e);return r?h`<small part="field-error" class="field-error" id="${`roxy-form-${e.key}-error`}" role="alert">${r.message}</small>`:p}renderIssueSummary(){let e=this.liveIssues();if(e.length===0)return p;let r=i=>{let o=this.fields.find(a=>a.key===i);if(o)return this.fieldLabel(o);let s=this.groupKeys().find(a=>a===i);return s?this.groupName(s):this.fieldText({name:i.split(".")[0]??i})};return h`<div part="validation-error" class="validation-error" role="alert">${e.map(i=>h`<div><strong>${r(i.path)}</strong> ${i.message}</div>`)}</div>`}roleOf(e){return e.role??"normal"}isRendered(e){return this.roleOf(e)==="normal"}groupKeys(){return this.groups.map(e=>e.key)}groupHasLocation(e){return!!this.groups.find(r=>r.key===e)?.location}cityGroup(e){return this.groups.find(r=>r.location?.fields.includes(e.key))?.key??e.group}placeField(e){let r=this.fields.filter(i=>i.group===e);return r.find(i=>i.name==="latitude")??r.find(i=>i.name==="timezone")}locationRequired(e){return this.groups.find(r=>r.key===e)?.location?.required??false}get soleChoice(){if(this.groupKeys().some(i=>this.groupHasLocation(i))||this.groupKeys().some(i=>i!==void 0))return null;let e=this.fields.filter(i=>i.required&&this.isRendered(i)),r=e[0];return e.length!==1||!r?null:r.kind==="tiles"||r.kind==="select"||this.pickers.has(r.key)?r:null}get opensOnLoad(){return this.modelOpensOnLoad}isFilter(e){return this.opensOnLoad&&!e.required&&!!(e.enum||e.source)}get selfSubmits(){if(this.soleChoice)return true;if(!this.opensOnLoad)return false;let e=this.fields.filter(r=>this.isRendered(r));return e.length>0&&e.every(r=>this.isFilter(r))}choiceKind(e){let r=this.choicesOf(e).map(i=>i.value);return this.isFilter(e)&&!Se(r)?"select":this.choices[e.key]?Xe(r):e.kind}choicesOf(e){let r=this.choices[e.key];return Array.isArray(r)?r:(e.enum??[]).map(i=>({value:i,label:this.optionText(e.name,i)}))}effectiveSubmitLabel(){return this.submitLabel?this.submitLabel:ur(this.fields,this.values)?this.t("Show right now"):this.t(pr(this.endpoint,this.fields))}requestLang(e){return Tt(this,e)}fieldText(e){let r=this.requestLang();return e.label?or(r,e)??e.label:xr(r,e.name,L[e.name])}optionText(e,r){return br(this.requestLang(),e,r)}onLocationFor(e){return r=>{let i=this.groups.find(s=>s.key===e)?.location?.fields??[],o={};for(let s of i){let a=this.fields.find(d=>d.key===s)?.name;a&&(o[s]=r[a])}this.setValues(o)}}chooseOption(e,r){if(this.isFilter(e)){this.setFilter(e,this.values[e.key]===r?"":r),this.submit();return}this.pickChoice(e,r)}pickChoice(e,r){this.setValue(e.key,r),this.resend()}resend(){let e=this.soleChoice;e&&this.values[e.key]&&this.submit()}setFilter(e,r){let i={[e.key]:r};for(let o of this.fields)o!==e&&(this.isFilter(o)||this.opensOnLoad&&o.kind==="text"&&this.isRendered(o))&&(i[o.key]=void 0);this.setValues(i)}onTilesKeyDown(e){return r=>{let i=this.choicesOf(e).filter(c=>!c.disabled).map(c=>c.value);if(i.length===0)return;let o=i.indexOf(this.values[e.key]),s;if(r.key==="Home")s=0;else if(r.key==="End")s=i.length-1;else if(r.key==="ArrowRight"||r.key==="ArrowDown")s=o===-1?0:(o+1)%i.length;else if(r.key==="ArrowLeft"||r.key==="ArrowUp")s=o===-1?i.length-1:(o-1+i.length)%i.length;else return;r.preventDefault();let a=i[s];if(a===void 0)return;this.chooseOption(e,a);let d=r.currentTarget,u=this.choicesOf(e).findIndex(c=>c.value===a);requestAnimationFrame(()=>d.querySelector(`[data-tile='${u}']`)?.focus())}}submit(){let e=this.collectMissing();if(e.keys.length>0){this.validationErrors=e.labels,this.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{missing:e.keys},bubbles:true,composed:true}));return}this.validationErrors=[],this.clearedIssues=new Set((this.serverIssues??[]).map(s=>s.path));let r={};for(let s of this.fields){let a=this.values[s.key];if(s.name==="seed"&&(a===void 0||a==="")&&(a=Sn()),s.viewerZone&&(a===void 0||a==="")&&(a=yr()??s.default),a===void 0||a==="")continue;s.kind==="array"&&typeof a=="string"&&(a=_n(a));let d=s.group?we(s.group):null;if(d){let u=r[d.key]??[],c=u[d.index]??{};c[s.name]=a,u[d.index]=c,r[d.key]=u}else if(s.group&&Rr(s)){let u=r[s.group]??{};u[s.name]=a,r[s.group]=u}else r[s.key]=a}let i=this.fields.filter(s=>s.inQuery).map(s=>s.name),o=this.requestLang(this.langs);this.hasLang&&o&&(r.lang=o,i.push("lang")),this.dispatchEvent(new CustomEvent("roxy-submit",{detail:{endpoint:this.endpoint,values:r,queryKeys:i,sticky:this.soleChoice!=null||this.opensOnLoad},bubbles:true,composed:true}))}collectMissing(){let e=[],r=[],i=new Set;for(let o of this.fields){if(!o.required)continue;let s=this.roleOf(o)==="location";if(!this.isRendered(o)&&!s)continue;let a=this.values[o.key];if(!(a!==void 0&&a!=="")){if(e.push(o.key),s){i.add(this.cityGroup(o));continue}r.push(this.fieldLabel(o))}}for(let o of i)r.push(this.locationLabel(o));return{keys:e,labels:r}}get readsEnglish(){return Rt(this.effectiveLang())}renderTitle(){return this.readsEnglish?h`<h2 part="title" class="title" id="roxy-form-title">${this.formTitle}</h2>`:p}reqMark(e){return e.required?h`<span class="req" aria-hidden="true">*</span>`:p}description(e){if(!e.description||!this.readsEnglish)return p;if(e.description.length<=120)return h`<small part="hint" class="help">${e.description}</small>`;let r=e.description.split(". ")[0]??e.description;return h`<details part="hint" class="help-details"><summary><span class="help-lead">${r}</span>${je()}</summary><small class="help help-full">${e.description}</small></details>`}renderTiles(e){let r=`roxy-form-${e.key}-label`,i=!!e.enum&&dr(e.enum),o=this.choicesOf(e),s=Se(o.map(u=>u.value)),a=o.findIndex(u=>u.value===this.values[e.key]),d=a===-1?o.findIndex(u=>!u.disabled):a;return h`<div class="field tiles-field"><span class="label" id="${r}">${this.fieldText(e)}${this.reqMark(e)}</span><div class="${s?"tiles narrow":"tiles"}" role="radiogroup" aria-labelledby="${r}" @keydown="${this.onTilesKeyDown(e)}">${o.map((u,c)=>{let m=this.values[e.key]===u.value,l=i?Yt(u.value):void 0;return h`<button type="button" class="tile" role="radio" data-tile="${c}" aria-checked="${m?"true":"false"}" tabindex="${c===d?"0":"-1"}" ?disabled="${!!u.disabled||this.isDisabled(e)}" @click="${()=>this.chooseOption(e,u.value)}">${l?h`<span class="tile-glyph roxy-glyph" aria-hidden="true">${l}</span>`:p} <span class="tile-label">${u.label}</span></button>`})}</div>${this.description(e)} ${this.fieldIssue(e)}</div>`}renderSelect(e){let r=`roxy-form-${e.key}`;return h`<div part="field" class="field"><label for="${r}">${this.fieldText(e)}${this.reqMark(e)}</label> <select id="${r}" ?required="${e.required}" ?disabled="${this.isDisabled(e)}" aria-invalid="${k(this.issueFor(e)?"true":void 0)}" aria-describedby="${k(this.issueFor(e)?`${r}-error`:void 0)}" .value="${_t(this.values[e.key]??"")}" @change="${i=>this.chooseOption(e,i.target.value)}"><option value="">${this.t("Choose")}</option>${this.choicesOf(e).map(i=>h`<option value="${i.value}" ?selected="${this.values[e.key]===i.value}" ?disabled="${!!i.disabled}">${i.label}</option>`)}</select> ${this.description(e)} ${this.fieldIssue(e)}</div>`}renderPickerField(e,r){let i=`roxy-form-${e.key}`,o=this.soleChoice?.key===e.key&&this.readsEnglish,s=this.issueFor(e);return h`<div part="field" class="field">${o?p:h`<label for="${i}">${this.fieldText(e)}${this.reqMark(e)}</label>`} ${wr(r,i,{placeholder:this.t("Type to search"),empty:this.t("{{count}} matches",{count:0}),loading:this.t("Loading")},{labelledby:o?"roxy-form-title":void 0,describedby:s?`${i}-error`:void 0,invalid:!!s})} ${this.fieldIssue(e)}</div>`}renderToggle(e){let r=`roxy-form-${e.key}`,i=this.values[e.key]===true;return h`<div part="field" class="field"><div class="toggle-row"><button type="button" id="${r}" class="toggle" role="switch" aria-checked="${i?"true":"false"}" @click="${()=>this.pickChoice(e,!i)}"><span class="knob"></span></button> <label class="toggle-label" for="${r}">${this.fieldText(e)}${this.reqMark(e)}</label></div>${this.description(e)} ${this.fieldIssue(e)}</div>`}renderInput(e){let r=`roxy-form-${e.key}`,i=e.kind==="datetime"?"datetime-local":e.kind==="number"?"number":e.kind,o=e.example!=null?String(e.example):"",s=e.kind==="array"?this.t("Comma separated"):this.readsEnglish||!new RegExp("\\p{L}","u").test(o)?o:"";return h`<div part="field" class="field"><label for="${r}">${this.fieldText(e)}${this.reqMark(e)}</label> <input id="${r}" type="${e.kind==="array"?"text":i}" ?required="${e.required}" ?disabled="${this.isDisabled(e)}" aria-invalid="${k(this.issueFor(e)?"true":void 0)}" aria-describedby="${k(this.issueFor(e)?`${r}-error`:void 0)}" min="${k(e.min)}" max="${k(e.max)}" step="${e.kind==="number"?"any":p}" placeholder="${s||p}" .value="${this.values[e.key]??""}" @input="${a=>{let d=this.coerce(e.kind,a.target.value);this.opensOnLoad&&e.kind==="text"?this.setFilter(e,d):this.setValue(e.key,d)}}" @change="${()=>this.resend()}"> ${this.description(e)} ${this.fieldIssue(e)}</div>`}renderField(e){if(e.city)return this.renderTimezoneCity(e);let r=this.pickers.get(e.key);if(r)return this.renderPickerField(e,r);let i=this.choices[e.key];return i==="loading"?h`<div class="field"><div class="roxy-skeleton field-skeleton" aria-label="${this.t("Loading")}" role="status"></div></div>`:i||e.kind==="tiles"||e.kind==="select"?this.choiceKind(e)==="tiles"?this.renderTiles(e):this.renderSelect(e):e.kind==="toggle"?this.renderToggle(e):this.renderInput(e)}groupName(e){return Ae(e,(r,i)=>this.t(r,i),r=>this.fieldText({name:r}))}repeatCount(e){return new Set(this.fields.map(r=>r.group&&we(r.group)).filter(r=>r&&r.key===e).map(r=>r.index)).size}addRecord(e){let r=this.repeatCount(e),i=sr(this.fields,e,r),o=this.groups.find(a=>a.key===S(e,0));if(o){let a=d=>d.replace(`${S(e,0)}.`,`${S(e,r)}.`);this.groups=[...this.groups,{...o,key:S(e,r),label:Ae(S(e,r)),...o.location&&{location:{...o.location,fields:o.location.fields.map(a)}}}]}let s={...this.values};for(let a of i)a.default!==void 0&&(s[a.key]=a.default);this.values=s,this.fields=[...this.fields,...i]}removeRecord(e){let r=S(e,this.repeatCount(e)-1);this.fields=this.fields.filter(o=>o.group!==r),this.groups=this.groups.filter(o=>o.key!==r);let i={...this.values};for(let o of Object.keys(i))o.startsWith(`${r}.`)&&delete i[o];this.values=i}repeatControls(e){let r=this.repeatCount(e.key);return e.max<=e.min?p:h`<div class="repeat-controls">${r<e.max?h`<button type="button" class="repeat-btn" @click="${()=>this.addRecord(e.key)}"><span aria-hidden="true">+</span> ${this.t("Add")}</button>`:p} ${r>e.min?h`<button type="button" class="repeat-btn" @click="${()=>this.removeRecord(e.key)}"><span aria-hidden="true">−</span> ${this.t("Remove")}</button>`:p}</div>`}locationLabel(e){return e?this.t("{{group}} location",{group:this.groupName(e)}):Er(this.placeField(e))?this.t("Birth location"):this.t("Location")}locationBlock(e){return h`<div class="location-block"><label>${this.locationLabel(e)}${this.locationRequired(e)?h`<span class="req" aria-hidden="true">*</span>`:p}</label> ${this.citySearch(e,this.onLocationFor(e))} ${this.issueLines(this.cityIssues(e))}</div>`}renderTimezoneCity(e){return h`<div part="field" class="field location-block"><label>${this.locationLabel(e.group)}${this.reqMark(e)}</label> ${this.citySearch(e.group,r=>this.pickChoice(e,r.timezone))} ${this.fieldIssue(e)}</div>`}citySearch(e,r){let i=e?this.t("{{group}} city",{group:this.groupName(e)}):Er(this.placeField(e))?this.t("City of birth"):void 0;return h`<roxy-location-search endpoint="${k(this.locationUrl||void 0)}" publishable-key="${k(this.publishableKey)}" .submitUrl="${this.route.submitUrl}" .submitContext="${this.route.submitContext}" lang="${k(this.effectiveLang())}" placeholder="${k(i)}" @roxy-location-select="${o=>r(o.detail)}"></roxy-location-search><small class="help">${this.t("Type a city, then pick it from the list.")}</small>`}groupCard(e){let r=this.fields.filter(i=>i.group===e&&this.isRendered(i));return h`<fieldset part="group" class="person-group"><legend>${this.groupName(e)}</legend>${this.groupHasLocation(e)?this.locationBlock(e):p}<div class="fields">${r.map(i=>this.renderField(i))}</div>${this.issueLines(this.issuesForGroup(e))}</fieldset>`}render(){return h`${this.renderFontStyle()}${this.renderBody()}`}renderBody(){if(!this.loaded)return h`<form><div class="roxy-skeleton form-skeleton"></div></form>`;if(this.specError)return h`<div class="roxy-error" role="alert">${this.t("Schema load failed: {{message}}",{message:this.specError})} <button type="button" class="submit" @click="${this.retryLoadSchema}">${this.t("Retry")}</button></div>`;let e=X(this.publishableKey);if(e)return h`<form>${this.renderTitle()}<div part="validation-error" class="validation-error" role="alert">${this.t(e.message)}</div></form>`;let r=this.fields.filter(c=>!c.group&&this.isRendered(c)),i=this.groupKeys().filter(c=>c!==void 0),o=r.filter(c=>!c.fold),s=r.filter(c=>c.fold),a=i.filter(c=>!this.groups.find(m=>m.key===c)?.fold),d=i.filter(c=>this.groups.find(m=>m.key===c)?.fold),u=s.length>0||d.length>0;return h`<form @submit="${this.onSubmit}">${this.renderTitle()} ${this.validationErrors.length>0?h`<div part="validation-error" class="validation-error" role="alert"><strong>${this.t("Please complete:")}</strong> ${this.validationErrors.join(", ")}</div>`:p} ${this.renderIssueSummary()}<div class="fields">${o.map(c=>this.renderField(c))}</div>${this.groupHasLocation(void 0)?this.locationBlock(void 0):p} ${a.map(c=>this.groupCard(c))} ${this.repeats.map(c=>this.repeatControls(c))} ${u?h`<details part="advanced" class="advanced" ?open="${this.liveIssues().some(c=>[...s.map(m=>m.key),...d].some(m=>c.path===m||c.path.startsWith(`${m}.`)))}"><summary>${this.t("Advanced")}${je()}</summary><div class="fields">${s.map(c=>this.renderField(c))}</div>${d.map(c=>this.groupCard(c))}</details>`:p} ${this.selfSubmits?p:h`<button part="submit" class="submit" type="submit">${this.effectiveSubmitLabel()}</button>`}</form>`}coerce(e,r){if(r!==""){if(e==="number"){let i=Number(r);return Number.isFinite(i)?i:void 0}return r}}};g.styles=[Jt,Qt,Ar,$`form{gap:var(--roxy-space-md);background:var(--roxy-surface);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);padding:var(--roxy-space-lg);box-shadow:var(--roxy-shadow-sm);grid-template-columns:minmax(0,1fr);display:grid}.title{margin:0}.fields{align-items:start;gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(22ch,1fr));display:grid}.fields:empty{display:none}.person-group{gap:var(--roxy-space-md);min-inline-size:0;padding:var(--roxy-space-md) 0 0;border:0;border-block-start:1px solid var(--roxy-border);margin:0;display:grid}.person-group legend{float:inline-start;color:var(--roxy-fg);font-weight:var(--roxy-weight-bold);padding:0}.field{gap:var(--roxy-space-xs);flex-direction:column;min-inline-size:0;display:flex}.fields>*{min-inline-size:0}.tiles-field{grid-column:1/-1}label,.label{font-size:var(--roxy-text-sm);color:var(--roxy-secondary)}.req{color:var(--roxy-danger-fg);margin-inline-start:var(--roxy-space-xs)}input,select{inline-size:100%;min-inline-size:0;min-block-size:var(--roxy-touch)}.help{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.field-error{color:var(--roxy-danger-fg);font-size:var(--roxy-text-xs)}input[aria-invalid=true],select[aria-invalid=true]{border-color:var(--roxy-danger)}input:disabled,select:disabled{cursor:default;color:var(--roxy-muted);border-style:dashed}.help-details>summary{align-items:center;gap:var(--roxy-space-xs);color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:flex}.help-details .help-lead{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.help-details .help-full{margin-block-start:var(--roxy-space-xs);display:block}.location-block{gap:var(--roxy-space-xs);grid-column:1/-1;display:grid}.tiles{gap:var(--roxy-space-sm);grid-template-columns:repeat(auto-fit,minmax(10ch,1fr));display:grid}.tiles.narrow{gap:var(--roxy-space-xs);grid-template-columns:repeat(auto-fill,minmax(4ch,1fr))}.tile{justify-content:center;align-items:center;gap:calc(var(--roxy-space-unit) / 2);min-block-size:var(--roxy-touch);padding:var(--roxy-space-sm);background:var(--roxy-bg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);color:var(--roxy-fg);font-size:var(--roxy-text-sm);cursor:pointer;transition:border-color var(--roxy-motion-duration) var(--roxy-motion-easing), background-color var(--roxy-motion-duration) var(--roxy-motion-easing);flex-direction:column;display:flex}.tile:hover:not(:disabled){border-color:var(--roxy-accent)}.tile:disabled{cursor:default;color:var(--roxy-muted);border-style:dashed}.tile[aria-checked=true]{border-color:var(--roxy-accent);background:color-mix(in srgb, var(--roxy-accent) 12%, transparent);color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.tile-glyph{font-size:var(--roxy-text-lg);line-height:1}.toggle-row{align-items:center;gap:var(--roxy-space-sm);display:flex}.toggle{box-sizing:content-box;block-size:.8lh;inline-size:1.6lh;padding:calc(var(--roxy-space-unit) / 2);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-full);background:var(--roxy-border);cursor:pointer;transition:background-color var(--roxy-motion-duration) var(--roxy-motion-easing);flex-shrink:0;display:inline-flex}.toggle[aria-checked=true]{background:var(--roxy-accent);border-color:var(--roxy-accent)}.toggle .knob{border-radius:var(--roxy-radius-full);background:var(--roxy-bg);block-size:.8lh;inline-size:.8lh;transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing)}.toggle[aria-checked=true] .knob{transform:translate(100%)}.toggle-label{cursor:pointer}@media (prefers-reduced-motion:reduce){.tile,.toggle,.toggle .knob{transition:none}}.advanced{border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-md)}.advanced>summary{align-items:center;gap:var(--roxy-space-xs);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);color:var(--roxy-fg);display:flex}.advanced[open]>summary{margin-block-end:var(--roxy-space-md)}.repeat-controls{gap:var(--roxy-space-sm);display:flex}.repeat-btn{color:var(--roxy-accent-ink);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);padding:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);cursor:pointer;background:0 0}.repeat-btn:hover{border-color:var(--roxy-accent-ink)}.advanced .fields,.advanced .person-group{margin-block-start:var(--roxy-space-md)}.validation-error{gap:var(--roxy-space-xs);border-inline-start:var(--roxy-line-thick) solid var(--roxy-danger);color:var(--roxy-danger-fg);font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-sm);display:grid}button.submit{min-block-size:var(--roxy-touch);background:var(--roxy-accent-ink);color:var(--roxy-bg);border-radius:var(--roxy-radius-md);padding:var(--roxy-space-sm) var(--roxy-space-lg);font-weight:var(--roxy-weight-bold);cursor:pointer;transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing);border:0;justify-self:start}button.submit:hover{transform:scale(1.02)}@media (prefers-reduced-motion:reduce){button.submit{transition:none}}.field-skeleton{block-size:var(--roxy-touch)}.form-skeleton{block-size:5lh}`],y([w({type:String,attribute:"data-endpoint"})],g.prototype,"endpoint",2),y([w({type:String})],g.prototype,"method",2),y([w({type:String,attribute:"spec-url"})],g.prototype,"specUrl",2),y([w({type:String,attribute:"submit-label"})],g.prototype,"submitLabel",2),y([w({type:String,attribute:"publishable-key"})],g.prototype,"publishableKey",2),y([w({type:String,attribute:"location-url"})],g.prototype,"locationUrl",2),y([w({attribute:false})],g.prototype,"initialValues",2),y([w({attribute:false})],g.prototype,"serverIssues",2),y([w({attribute:false})],g.prototype,"apiRoute",2),y([w({attribute:false})],g.prototype,"autoload",2),y([w({attribute:false})],g.prototype,"fullPages",2),y([E()],g.prototype,"choices",2),y([E()],g.prototype,"clearedIssues",2),y([E()],g.prototype,"fields",2),y([E()],g.prototype,"repeats",2),y([E()],g.prototype,"formTitle",2),y([E()],g.prototype,"hasLang",2),y([E()],g.prototype,"values",2),y([E()],g.prototype,"loaded",2),y([E()],g.prototype,"specError",2),y([E()],g.prototype,"validationErrors",2),g=y([Xt("roxy-endpoint-form")],g);return Pr(Rn)})();