@a2f0/skyline 0.1.5 → 0.1.7

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@a2f0/skyline",
3
- "version": "0.1.5",
3
+ "version": "0.1.7",
4
4
  "description": "Interactive Chicago skyline viewer and reusable Three.js building models",
5
5
  "license": "UNLICENSED",
6
6
  "repository": {
@@ -75,7 +75,8 @@ for (const button of celebrationButtons) {
75
75
  return message ? [`${message.lines.join(" ")}${message.adapted ? " (adapted tribute)" : ""} · ${model.building.userData["geography"]?.name ?? model.building.name}`] : [];
76
76
  });
77
77
  button.title = `${preset.label}: ${displays.join("; ")} · click to light all; click again to turn off`;
78
- button.disabled = displays.length === 0;
78
+ // A badge no mapped building can display is left out rather than greyed out.
79
+ button.hidden = displays.length === 0;
79
80
  button.addEventListener("click", () => {
80
81
  const next = button.getAttribute("aria-pressed") === "true" ? null : preset.id;
81
82
  const targets = next === null ? illuminated.filter((model) => model.illumination.active === preset.id) : illuminated;
@@ -74,7 +74,8 @@ export function createSkylineComparison(models, anchor) {
74
74
  const streetButton = document.querySelector("#streets");
75
75
  function onLayoutChange(name) {
76
76
  const geographic = name === "geographic";
77
- streetButton.disabled = !geographic;
77
+ // Only the geographic layout maps streets; elsewhere the toggle is left out.
78
+ streetButton.hidden = !geographic;
78
79
  document.querySelector("#layout-status").textContent = geographic
79
80
  ? "Geographic layout · mapped footprints and published heights, or heights read on the drawing where none is published, with detailed facades on all thirty-four buildings. Skyline view: the drawing’s camera, on the lakefront by the Adler Planetarium. Light grey outlines: mapped ground coverage. Grey lines: street centerlines. Grid: 100 m."
80
81
  : "Original layout · proportions and spacing fitted to the drawing. Use ground plan or height comparison, then toggle layouts to compare at the same camera scale.";
@@ -50,7 +50,7 @@
50
50
  <button type="button" id="reset">reset view</button>
51
51
  </div>
52
52
  <div class="button-group" role="group" aria-label="Model display">
53
- <button type="button" id="streets" aria-pressed="true" disabled>streets</button>
53
+ <button type="button" id="streets" aria-pressed="true" hidden>streets</button>
54
54
  <button type="button" id="wireframe" aria-pressed="false">wireframe</button>
55
55
  <button type="button" id="turntable" aria-pressed="false" aria-describedby="motion-status">turntable</button>
56
56
  </div>
@@ -470,7 +470,8 @@ export function createBuildingStudy({ models, defaultView = "quarter", views = {
470
470
  }
471
471
  function updateMotionPreference() {
472
472
  controls.enabled = !reducedMotion.matches;
473
- turntableButton.disabled = reducedMotion.matches;
473
+ // Under reduced motion the turntable cannot run, so its button goes rather than greying out.
474
+ turntableButton.hidden = reducedMotion.matches;
474
475
  if (reducedMotion.matches)
475
476
  setTurning(false);
476
477
  updateMotionStatus();