@roxyapi/ui 0.2.1 → 0.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -366,7 +366,7 @@ The server component fetches, the client component renders. The API key never cr
366
366
  <details>
367
367
  <summary><strong>Tailwind v3 vs v4 compatibility?</strong></summary>
368
368
 
369
- Both work. Components do not consume Tailwind utilities. Tailwind utilities apply outside the components on wrappers and containers; inside the Shadow DOM, components read `--roxy-*` CSS custom properties only.
369
+ Both work. Components do not consume Tailwind utilities. Tailwind utilities apply outside the components on parent layout elements and containers; inside the Shadow DOM, components read `--roxy-*` CSS custom properties only.
370
370
 
371
371
  For Tailwind v4 users, the shadcn registry installs a CSS bridge that maps your existing v4 design tokens onto `--roxy-*`. For Tailwind v3 users, set `--roxy-*` directly on `:root`, or write a tiny bridge:
372
372
 
@@ -400,7 +400,7 @@ useEffect(() => {
400
400
  return <roxy-location-search ref={ref} />;
401
401
  ```
402
402
 
403
- Upgrade to React 19 when you can; the wrappers route everything cleanly.
403
+ Upgrade to React 19 when you can; the React components route everything cleanly.
404
404
  </details>
405
405
 
406
406
  <details>
@@ -460,7 +460,7 @@ Mock `@roxyapi/sdk` at the network boundary so unit tests do not hit the live AP
460
460
  <details>
461
461
  <summary><strong>What if I want to fork or own a component?</strong></summary>
462
462
 
463
- Use the shadcn registry. The registry drops the component source, a wrapper file, and a CSS theme bridge into your repo. Edit anything; the source is yours from that point.
463
+ Use the shadcn registry. The registry drops the React component source and a CSS theme bridge into your repo. Edit anything; the source is yours from that point.
464
464
 
465
465
  ```bash
466
466
  npx shadcn@latest add https://cdn.jsdelivr.net/gh/RoxyAPI/ui@latest/registry/natal-chart.json
@@ -171,12 +171,12 @@
171
171
  </div>`:c}
172
172
  </div>`}renderInterpretations(){let e=this.getPlanets().filter(r=>r.interpretation);return e.length===0?c:m`<section class="interpretations">
173
173
  <h3>Planet readings</h3>
174
- ${e.map(r=>{let s=r.interpretation,i=Y[k(r.name)]??"",o=dt(r.degree??0,1);return m`<details class="interp-card">
175
- <summary>${i} ${r.name} <small>${r.sign??""} ${o}</small></summary>
174
+ ${e.map((r,s)=>{let i=r.interpretation,o=Y[k(r.name)]??"",l=dt(r.degree??0,1);return m`<details class="interp-card" name="natal-planet-readings" ?open=${s===0}>
175
+ <summary>${o} ${r.name} <small>${r.sign??""} ${l}</small></summary>
176
176
  <div class="interp-body">
177
- ${s.summary?m`<p class="interp-summary">${s.summary}</p>`:c}
178
- ${s.detailed?m`<p class="interp-detail">${s.detailed}</p>`:c}
179
- ${s.keywords?.length?m`<div class="interp-keywords">${s.keywords.map(l=>m`<span class="kw">${l}</span>`)}</div>`:c}
177
+ ${i.summary?m`<p class="interp-summary">${i.summary}</p>`:c}
178
+ ${i.detailed?m`<p class="interp-detail">${i.detailed}</p>`:c}
179
+ ${i.keywords?.length?m`<div class="interp-keywords">${i.keywords.map(a=>m`<span class="kw">${a}</span>`)}</div>`:c}
180
180
  </div>
181
181
  </details>`})}
182
182
  </section>`}renderAspects(e,r){let s=new Map;for(let i of e){if(typeof i.longitude!="number")continue;let o=k(i.name);o&&s.set(o,i.longitude)}return r.map(i=>{let o=s.get(k(i.planet1)),l=s.get(k(i.planet2));if(o===void 0||l===void 0)return c;let a=f(u,u,J-18,this.toAngle(o)),d=f(u,u,J-18,this.toAngle(l)),p=Ut(i),h=Lt[p]??"aspect-other",g=dt(i.orb,1);return E`<line class=${`aspect ${h}`} x1=${a.x} y1=${a.y} x2=${d.x} y2=${d.y}><title>${i.planet1} ${p||""} ${i.planet2}${g?` (orb ${g}\xB0)`:""}</title></line>`})}};b.styles=[Ot,N`