@johnmorrisdotca/uchusen-rockets 0.6.0 → 0.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.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,12 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [0.7.0] - 2026-11-03
6
+
7
+ - Demo: the view controls' Auto-turn speeds are the family's speed buttons, 0.5×, 1× and 2× (kazoku-ui 0.14, `^0.14.0`), in place of Slow, Medium and Fast. The reader's choice is the controls' `pace` attribute and `?pace=2` in the address (the address key was `speed`). The base speed stays `speed="5"` degrees a second, which the buttons multiply, and Turn left and Turn right keep their way at any speed. The copied embed code turns at the same speed as the page (`spin` is the seconds a turn: 144, 72 or 36), where it said `slow` whatever the buttons said. Browser tests hold the three buttons, the speed each sets (sign kept), the address and the copied code, and that an old `?speed=fast` opens at 1×.
8
+ - Fixed: the drawing of a flight (no WebGL, `mode="drawing"`, the embed page before the 3D view) took each phase's own angles for the grid fins, legs and flaps, so every move jumped at a phase while the 3D view mixed them. It now takes the angles the 3D view has at that moment, rounded to 5 degrees: the drawing changes at most about one time in five degrees of a move (17 times for Falcon 9's grid fins opening from 85 degrees), still no more than about 20 draws a second. A browser test seeks across the fins' opening and holds that each angle has its drawing, the drawing changes only when the rounded angle does, and the phase's own drawing is no longer the one for all of it; it fails without the fix.
9
+ - Documentation: the Element page, the Looks guide and the Upgrading guide (English and Japanese) say what the speed buttons do; the README's pictures of the demo show them.
10
+
5
11
  ## [0.6.0] - 2026-11-03
6
12
 
7
13
  - Fixed: a look chosen while the 3D view starts, or while a rocket loads, is no longer lost. `start()` and the rocket change read the look before the load and applied it after, so the attribute said the new look and the view drew the old one; both now read it again after the load (and the parts shown with it). Two browser tests change the look in the turn the canvas appears and again with a variant change, and fail without the fix.
package/dist/element.js CHANGED
@@ -503,7 +503,8 @@ export class UchusenRocket extends HTMLBase {
503
503
  const from = this.driven ? turnedBy(angle, this.driven.yaw, this.driven.tilt) : (this.viewer?.currentAngle() ?? angle);
504
504
  const label = this.getAttribute("label") ?? this.builtNow.report.label;
505
505
  const lit = flying ? (media("(prefers-reduced-motion: reduce)") ? false : flying.burns) : this.engineLights();
506
- const moves = flying ? Object.fromEntries(Object.entries(flying.phase.pose).flatMap(([slot, pose]) => (pose.moves ? [[slot, pose.moves]] : []))) : undefined;
506
+ // the angles the 3D view has now, to 5 degrees: the drawing changes a few times a phase, not once a frame
507
+ const moves = flying ? Object.fromEntries(Object.entries(flying.poses).flatMap(([slot, pose]) => { const turned = Object.entries(pose.moves).map(([name, angle]) => [name, Math.round(angle / 5) * 5]).filter(([, angle]) => angle !== 0); return turned.length ? [[slot, Object.fromEntries(turned)]] : []; })) : undefined;
507
508
  const key = `${this.key}|${look}|${show}|${from.az.toFixed(2)}|${from.el.toFixed(2)}|${label}|${flying ? flying.index : ""}|${JSON.stringify(lit)}|${JSON.stringify(moves ?? {})}`;
508
509
  let node = this.drawing.firstElementChild;
509
510
  if (key !== this.drawn.key || !node) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@johnmorrisdotca/uchusen-rockets",
3
- "version": "0.6.0",
3
+ "version": "0.7.0",
4
4
  "description": "Uchusen Rockets 宇宙船: line drawings and 3D views of rockets, as a web component. Every variant with its own sourced sizes, a typed way to assemble a rocket from parts, stack and separate. No logos. three.js is a peer dependency.",
5
5
  "keywords": [
6
6
  "rocket",
@@ -125,7 +125,7 @@
125
125
  "@gltf-transform/extensions": "4.5.1",
126
126
  "@gltf-transform/functions": "4.5.1",
127
127
  "@johnmorrisdotca/chikyu-earth": "0.10.0",
128
- "@johnmorrisdotca/kazoku-ui": "^0.12.0",
128
+ "@johnmorrisdotca/kazoku-ui": "^0.14.0",
129
129
  "@playwright/test": "1.64.0",
130
130
  "@sveltejs/vite-plugin-svelte": "^7.3.1",
131
131
  "@types/node": "24.10.1",