@n-uf/placement 26.11.38 → 26.11.39

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.
@@ -67,7 +67,10 @@ interface SceneItem {
67
67
  readonly fixed?: boolean;
68
68
  /** Closed: it keeps its place in its edge (or its float rect) but takes no room and has no targets. */
69
69
  readonly closed?: boolean;
70
- /** Its zone in its edge (default start). */
70
+ /**
71
+ * Its zone (default start): the item's own, not its edge's. It lies there where its edge takes its kind there, else in
72
+ * the first zone that does (`zoneIn`). Only a drop that names a zone (a gap in a zone, `moveTo` with `zone`) sets it.
73
+ */
71
74
  readonly align?: Zone;
72
75
  /**
73
76
  * Its give-way priority in its edge (default: the edge's `priority`, else 0). When an edge runs short, items step down
@@ -663,7 +666,9 @@ declare function fitResize(scene: Scene, id: string, rect: Rect, moving: ResizeE
663
666
  * given, the same object, so `after === before` says nothing changed.
664
667
  *
665
668
  * - `moveTo(scene, id, { edge, zone?, at })`: docks the item in that edge, before the `at`-th item of the zone (counting
666
- * the zone's items without it, closed ones included), or at the zone's end. The zone becomes the item's `align`.
669
+ * the zone's items without it, closed ones included), or at the zone's end. A zone named becomes the item's `align`;
670
+ * with none, the item keeps its own and docks in the zone it lies in there (`zoneIn`: its own where the edge takes it
671
+ * there, else the first that does). A new column, a rail and `dockHome` name none either: the item's zone is its own.
667
672
  * `{ kind: "column", side, ring }` makes a new column from `scene.columns[side]` at that ring (`Infinity`: the side's
668
673
  * inner end, "Move to › Dock left"); `{ kind: "rail", side, ring }` does the same with the item folded by hand, so it
669
674
  * shows in the rail (on a side with no declared rail, `Scene.rails`, its rail is its outermost column that takes the
@@ -1,6 +1,6 @@
1
1
  import { P as Point, R as Rect } from './geometry-Bf37LbCT.js';
2
2
  import { S as StackFormKind } from './model-X7eUaKlA.js';
3
- import { S as Scene, a as ScenePlace, b as SceneLayout, c as StoredScene, Z as Zone, d as Side, e as SceneNoteCode, f as SceneTarget, g as SceneRefusal } from './model-bUSbHw8v.js';
3
+ import { S as Scene, a as ScenePlace, b as SceneLayout, c as StoredScene, Z as Zone, d as Side, e as SceneNoteCode, f as SceneTarget, g as SceneRefusal } from './model-gUF8juqt.js';
4
4
  import './target-Db9z1bWt.js';
5
5
 
6
6
  /**
@@ -19,7 +19,7 @@ import {
19
19
  storeScene,
20
20
  targets,
21
21
  use
22
- } from "./chunk-GWZ5BPIN.js";
22
+ } from "./chunk-US2TGS3W.js";
23
23
  import "./chunk-AE3BWTAE.js";
24
24
  import {
25
25
  centre,
@@ -576,6 +576,7 @@ var DOCKING_ROWS = [
576
576
  expect: "A float dropped with the pointer past the stage's edge: the pointer is clamped into the stage first (the host contract; the runner clamps every `move` to a point), and the clamped point, on the window's edge, picks only a target drawn against that edge. Outside the window is no drawn space: the float and every refusal hold only points strictly inside it. Nothing is docked at this stage's right edge, so nothing is picked: the preview leaves the held float's place empty and the drop commits nothing, the float back where it was. A window with a docked edge there picks that edge's last gap instead.",
577
577
  group: "floats",
578
578
  scene: bench(),
579
+ requires: { railDrop: "scene" },
579
580
  gestures: [g.press("findings", { x: 40, y: 10 }), g.at(920, 240), g.hold(), g.release()],
580
581
  checkpoints: [{ at: 2, layout: { items: { findings: null } }, note: "no target past the edge: the held float out of the layout" }],
581
582
  expectLayout: { items: { findings: { floating: true, rect: rect(440, 130, 220, 190) } } }