tosijs-3d 0.10.5 → 0.10.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/CHANGELOG.md +119 -0
- package/README.md +2 -2
- package/dist/anchor-layout.d.ts +60 -0
- package/dist/anchor-layout.d.ts.map +1 -0
- package/dist/anchor-layout.js +140 -0
- package/dist/anchor-layout.js.map +1 -0
- package/dist/b3d-beacon.js +1 -1
- package/dist/b3d-biped.d.ts +17 -3
- package/dist/b3d-biped.d.ts.map +1 -1
- package/dist/b3d-biped.js +85 -16
- package/dist/b3d-biped.js.map +1 -1
- package/dist/b3d-black-hole.js +1 -1
- package/dist/b3d-cloud-deck.js +1 -1
- package/dist/b3d-collisions.js +1 -1
- package/dist/b3d-death.d.ts +3 -1
- package/dist/b3d-death.d.ts.map +1 -1
- package/dist/b3d-death.js +24 -12
- package/dist/b3d-death.js.map +1 -1
- package/dist/b3d-exploder.js +1 -1
- package/dist/b3d-galaxy.js +1 -1
- package/dist/b3d-hud.js +1 -1
- package/dist/b3d-lamp.js +1 -1
- package/dist/b3d-launcher.js +2 -2
- package/dist/b3d-light-shafts.js +2 -2
- package/dist/b3d-light.js +1 -1
- package/dist/b3d-lightning.js +1 -1
- package/dist/b3d-moon.js +2 -2
- package/dist/b3d-panel.d.ts +19 -1
- package/dist/b3d-panel.d.ts.map +1 -1
- package/dist/b3d-panel.js +136 -4
- package/dist/b3d-panel.js.map +1 -1
- package/dist/b3d-particles.js +1 -1
- package/dist/b3d-physics.js +1 -1
- package/dist/b3d-planet.d.ts.map +1 -1
- package/dist/b3d-planet.js +32 -6
- package/dist/b3d-planet.js.map +1 -1
- package/dist/b3d-primitives.d.ts +13 -0
- package/dist/b3d-primitives.d.ts.map +1 -1
- package/dist/b3d-primitives.js +57 -10
- package/dist/b3d-primitives.js.map +1 -1
- package/dist/b3d-radar.js +1 -1
- package/dist/b3d-reflections.js +1 -1
- package/dist/b3d-shadows.d.ts +9 -2
- package/dist/b3d-shadows.d.ts.map +1 -1
- package/dist/b3d-shadows.js +18 -7
- package/dist/b3d-shadows.js.map +1 -1
- package/dist/b3d-skybox.d.ts +1 -0
- package/dist/b3d-skybox.d.ts.map +1 -1
- package/dist/b3d-skybox.js +38 -5
- package/dist/b3d-skybox.js.map +1 -1
- package/dist/b3d-sound.js +1 -1
- package/dist/b3d-star-system.d.ts +2 -0
- package/dist/b3d-star-system.d.ts.map +1 -1
- package/dist/b3d-star-system.js +44 -12
- package/dist/b3d-star-system.js.map +1 -1
- package/dist/b3d-star.js +1 -1
- package/dist/b3d-svg-plane.d.ts +21 -3
- package/dist/b3d-svg-plane.d.ts.map +1 -1
- package/dist/b3d-svg-plane.js +48 -6
- package/dist/b3d-svg-plane.js.map +1 -1
- package/dist/b3d-terrain.js +1 -1
- package/dist/b3d-turret.js +1 -1
- package/dist/b3d-utils.d.ts.map +1 -1
- package/dist/b3d-utils.js +2 -0
- package/dist/b3d-utils.js.map +1 -1
- package/dist/b3d-warhead.js +1 -1
- package/dist/box.d.ts +16 -0
- package/dist/box.d.ts.map +1 -1
- package/dist/box.js +159 -17
- package/dist/box.js.map +1 -1
- package/dist/buoyancy.d.ts +11 -0
- package/dist/buoyancy.d.ts.map +1 -1
- package/dist/buoyancy.js +19 -2
- package/dist/buoyancy.js.map +1 -1
- package/dist/carry-box.d.ts +132 -0
- package/dist/carry-box.d.ts.map +1 -0
- package/dist/carry-box.js +823 -0
- package/dist/carry-box.js.map +1 -0
- package/dist/carry.d.ts +52 -0
- package/dist/carry.d.ts.map +1 -0
- package/dist/carry.js +140 -0
- package/dist/carry.js.map +1 -0
- package/dist/demo-utils.d.ts +1 -1
- package/dist/demo-utils.d.ts.map +1 -1
- package/dist/demo-utils.js +1 -1
- package/dist/demo-utils.js.map +1 -1
- package/dist/frame-panel.d.ts +127 -1
- package/dist/frame-panel.d.ts.map +1 -1
- package/dist/frame-panel.js +527 -74
- package/dist/frame-panel.js.map +1 -1
- package/dist/gas-giant.js +2 -2
- package/dist/glass-gamepad.d.ts.map +1 -1
- package/dist/glass-gamepad.js +5 -2
- package/dist/glass-gamepad.js.map +1 -1
- package/dist/icon-data.d.ts +8 -0
- package/dist/icon-data.d.ts.map +1 -1
- package/dist/icon-data.js +8 -0
- package/dist/icon-data.js.map +1 -1
- package/dist/index.d.ts +15 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +10 -2
- package/dist/index.js.map +1 -1
- package/dist/inventory-box.d.ts +151 -0
- package/dist/inventory-box.d.ts.map +1 -0
- package/dist/inventory-box.js +1159 -0
- package/dist/inventory-box.js.map +1 -0
- package/dist/inventory.d.ts +193 -0
- package/dist/inventory.d.ts.map +1 -0
- package/dist/inventory.js +495 -0
- package/dist/inventory.js.map +1 -0
- package/dist/mersenne-twister.d.ts +7 -9
- package/dist/mersenne-twister.d.ts.map +1 -1
- package/dist/mersenne-twister.js +80 -19
- package/dist/mersenne-twister.js.map +1 -1
- package/dist/panel-layer.d.ts +10 -0
- package/dist/panel-layer.d.ts.map +1 -1
- package/dist/panel-layer.js +24 -2
- package/dist/panel-layer.js.map +1 -1
- package/dist/panel-rim.d.ts +8 -0
- package/dist/panel-rim.d.ts.map +1 -0
- package/dist/panel-rim.js +47 -0
- package/dist/panel-rim.js.map +1 -0
- package/dist/planet-map.js +1 -1
- package/dist/playground.d.ts +2 -0
- package/dist/playground.d.ts.map +1 -1
- package/dist/playground.js +77 -15
- package/dist/playground.js.map +1 -1
- package/dist/popup-chrome.d.ts.map +1 -1
- package/dist/popup-chrome.js +26 -10
- package/dist/popup-chrome.js.map +1 -1
- package/dist/popup-surface.d.ts.map +1 -1
- package/dist/popup-surface.js +83 -53
- package/dist/popup-surface.js.map +1 -1
- package/dist/scene-schemas.d.ts.map +1 -1
- package/dist/scene-schemas.js +7 -1
- package/dist/scene-schemas.js.map +1 -1
- package/dist/sdf-lattice.js +2 -2
- package/dist/skybox-baker.js +1 -1
- package/dist/sol.d.ts.map +1 -1
- package/dist/sol.js +81 -14
- package/dist/sol.js.map +1 -1
- package/dist/solar-system.d.ts.map +1 -1
- package/dist/solar-system.js +24 -7
- package/dist/solar-system.js.map +1 -1
- package/dist/svg-texture.d.ts +18 -0
- package/dist/svg-texture.d.ts.map +1 -1
- package/dist/svg-texture.js +10 -4
- package/dist/svg-texture.js.map +1 -1
- package/dist/system-bar.d.ts +17 -0
- package/dist/system-bar.d.ts.map +1 -0
- package/dist/system-bar.js +194 -0
- package/dist/system-bar.js.map +1 -0
- package/dist/system-layout.d.ts +31 -2
- package/dist/system-layout.d.ts.map +1 -1
- package/dist/system-layout.js +37 -4
- package/dist/system-layout.js.map +1 -1
- package/dist/tosi-b3d.d.ts +76 -1
- package/dist/tosi-b3d.d.ts.map +1 -1
- package/dist/tosi-b3d.js +927 -74
- package/dist/tosi-b3d.js.map +1 -1
- package/dist/widgets3d.d.ts +30 -0
- package/dist/widgets3d.d.ts.map +1 -1
- package/dist/widgets3d.js +267 -51
- package/dist/widgets3d.js.map +1 -1
- package/package.json +2 -2
- package/static/attributes.json +108 -6
- package/static/attributes.txt +35 -5
package/CHANGELOG.md
CHANGED
|
@@ -6,6 +6,125 @@ All notable changes to **tosijs-3d**. This project is pre-1.0 (`0.x`), so minor
|
|
|
6
6
|
versions may carry breaking peer-dependency changes — each is called out in a
|
|
7
7
|
**⚠️ Breaking** block in its version section below, with what a consumer must do.
|
|
8
8
|
|
|
9
|
+
## 0.10.7
|
|
10
|
+
|
|
11
|
+
**What you will see on upgrading** (nothing exported in 0.10.6 is removed or renamed, but a `^0.10` range picks this up unasked):
|
|
12
|
+
|
|
13
|
+
- Every `panel3d` is tighter (shorter rows, half the space between them), and icon-bar captions are tooltips.
|
|
14
|
+
- Flat, the corner buttons, settings panel and pause are drawn in the scene; `::part(...)` styling of them no longer shows. `<tosi-b3d flat-ui="dom">` keeps the HTML.
|
|
15
|
+
- The settings panel has a title bar (move, name, ×); in a headset it opens from the system bar ahead of you, and Exit VR is on that bar.
|
|
16
|
+
- Popups are alpha-blended with the panels' light outline, where they were opaque with a grey rim.
|
|
17
|
+
- The placeholder Inventory, Journal, Quick Access and Menu rig panels no longer ship; declare your own `<tosi-b3d-panel>`s.
|
|
18
|
+
|
|
19
|
+
### Changed
|
|
20
|
+
|
|
21
|
+
- **The scene's corner controls, settings panel and pause are drawn in the scene by default** (flat), not as HTML over the canvas (#3307). If you styled them through `::part(sceneToolbar)`, `::part(scenePanelGear)`, `::part(enterVrButton)` or the pause host, that styling no longer shows: the HTML is still there but hidden. A button you hide with `display: none` (on `::part(...)` or otherwise) is still left off the in-scene toolbar, which mirrors what shows. The toolbar now has a third button (full screen) and covers about 150 x 56 px at the top left, so anything of yours pinned there needs moving (the demo loadouts moved to 64 px down). `<tosi-b3d flat-ui="dom">` restores the HTML presentation.
|
|
22
|
+
- **The system bar** (`systemBar`, was `sceneToolbar` earlier in this cycle): the scene's one row of buttons, flat in the top-left corner and, in a headset, up ahead where the settings panel used to hang for the whole session (twice the flat bar's size there). The owl opens the settings panel under it (now with a ×, flat and in VR alike); in a headset Exit VR is on the bar and no longer on the settings panel. **System panels**: a `<tosi-b3d-panel preset="system-bar" icon="personStanding">` is not pinned to the rig but gets a button on the bar and opens under it, flat and in a headset (and from the HTML lozenge with `flat-ui="dom"`). One is open at a time, the settings panel included. The content is asked with a cancelable `panelopen`, so content that opens itself (`inventoryDock`) does, and its own close puts the panel away. `FramePanelSpec.focusable: false` keeps a panel where it is placed (#3307).
|
|
23
|
+
- **Placeholder cards wear the outline too** (the pins demo's plaques, a system panel with no `svg`): `placeholderPanelSvg` draws the shared `panelRim`, and the card now fills its viewBox.
|
|
24
|
+
- **A panel on the system bar is an icon, a title and what it shows.** `<tosi-b3d-panel icon="map" title="Map">` with an `<svg>` inside it (in HTML, or `b3dPanel({ icon, title }, panel3d(...))`) gets a button on the bar and opens under it; nothing else to wire. An `icon` with no `preset` now means the system bar (`preset="system-bar"` still works), and an `<svg>` child is the content (the `svg` property, when set, wins). A panel with neither shows a card with its title.
|
|
25
|
+
- **Frame panels can be dragged by their title bar in space**, not only on the screen: in a headset the panel slides over its sphere to where the controller points, keeping the offset you grabbed it by (a point along the ray, not its direction from your eyes: `orbitFromAim`). For a panel whose anchor is its own angles (not a preset, not a `position`). A system panel reopens where you left it in a headset too; holding its button resets both.
|
|
26
|
+
- **A list's "put in" target stays in view**: with the heading and the drop target, at the top of a fixed-height list, and the things scroll in the space left. It was the list's last row, below the bottom of a list taller than its panel.
|
|
27
|
+
- **Polish, from a headset pass.** The system bar's buttons are 3 apart with the same 3 between them and its outline (`BAR_GAP`, `BAR_PAD`, `BAR_HEIGHT` exported), so it reads as one even strip. Panels and popups have no dark fringe at their rounded corners: their textures are premultiplied (`SvgTexture` `premultiplied`) and blended `SRC + DST(1 - a)`. A box's clip is rounded as the box is, so a pinned heading no longer squares off its top corners. The inventory dock: the bag sits half as far from the loadout, has no "bag" caption, and its two targets sit side by side as **unequip** (Lucide's backpack, new icon `lucideBackpack`) and **drop** (`trash`) (`inventoryPanel` `headings`, `putLabel`, `putIcon`, `dropIcon`; `carrySocket` `inline`, `icon`); a list that scrolls leaves room for its scrollbar, so rows breathe evenly either side; a one-line target centres its label, and a refusal's reason takes its place.
|
|
28
|
+
- **A system panel wears the settings panel's title bar** (move, its title, ×), flat and in a headset, in place of content's own close (the dock's minus in a circle, and its outline, are left to the frame: `panelopen` says `framed`). Flat, a drag by the bar moves it and it reopens where you left it, as the settings panel does; **holding** its button on the system bar (or the owl's, for the settings panel) puts it back under the bar (`systemhold`, after `HOLD_MS`). `<tosi-b3d-panel chrome="none">` for content with chrome of its own; `titled3d(content, { title, handleClose })` gives any SVG the same bar.
|
|
29
|
+
- **The demo inventory is on the system bar** (`demoLoadout`, the inventory-box page): a button (Lucide's person-standing) that opens the loadout with its bag. The small closed loadout over your shoulder is gone.
|
|
30
|
+
- **The rig's spots are named pins, empty by default**: `left-shoulder`, `right-shoulder`, `overhead`, `waist`, `wrist`, demonstrated on the b3d-panel page. The placeholder Inventory, Journal, Quick Access and Menu panels no longer ship; declared `<tosi-b3d-panel>`s are the set.
|
|
31
|
+
- **Panels are tighter.** A control row pads ¾ as much above and below (40 px, was 46), rows in a `panel3d` stack half the theme spacing apart (4, was 8), the icon bar is its buttons plus 2 px either side (36, was 46 plus a caption band), and the gap under a pinned header is halved. A panel shows about a fifth more in the same height. `gap` on `panel3d` restores the old space between rows; the rows themselves and the icon bar stay tighter (a larger `--w3d-padding` grows the rows), so a panel given a fixed height comes out with room to spare.
|
|
32
|
+
- **Icon-bar captions are tooltips.** The first word under every icon is gone; hovering (a mouse, or a controller ray) shows the whole title in a tooltip drawn in the SVG, so a texture shows it too.
|
|
33
|
+
- **Panels and popups share one outline**, the corner toolbar's light line (`panelRim`: white at 60%, 4 units wide, heavy enough to pop a panel off a dark sky), in place of a popup's grey rim, since nothing in a scene casts a shadow to separate them.
|
|
34
|
+
- **Popups are alpha-blended quads like every other panel**, not opaque meshes with cut corners, so their outline and corners are the SVG's and a translucent theme shows through them. They still write depth (`b3dSvgPlane` `transparent: 'depth'`, new: blended, depth-written, empty pixels discarded), so stacked popups do not swap order as you orbit.
|
|
35
|
+
|
|
36
|
+
### Added
|
|
37
|
+
|
|
38
|
+
- **Icons: `book`, `bookOpen` (Feather's), `personStanding` (Lucide's), `backpack` and `loadout` (ours).** The inventory dock wears the panels' outline, open and closed (closed, its line scaled to the small picture). `<tosi-b3d-panel icon>` / `FramePanelSpec.icon` is a system panel's button.
|
|
39
|
+
- **The settings panel has a title bar**: move, its name and close, in the band that was empty headroom. `panelTitle` on `<tosi-b3d>` names it (the demos' title rows moved there, a row each saved); flat, the panel can be dragged by the bar, stays where you put it across rebuilds, and its × closes it (close is no longer in the icon bar). The DOM panel shows the title in its head. `panel3d` takes `title` and `handleClose` (a close glyph it handles itself, so every presentation gets it) and exposes `gripHit(x, y)`, the bar less the close target, for a host that drags it. Frame panels pinned with `screenAnchor` move with a drag on that grip, writing `left`/`top` into the anchor.
|
|
40
|
+
|
|
41
|
+
- **The settings panel is in the scene** (flat): the same panel the headset gets, as a `ui`-layer frame panel pinned under the corner toolbar, and its popups (Perf, errors, …) are made in the same layer, hanging from it (`b3dSvgPlane`'s new `layer`, taken by a popup from its opener; `panelLayerOf`). A press on the background still closes it; a press a panel took does not (`pointerClaimedByPanel`, since Babylon cancels every canvas press, so `defaultPrevented` cannot tell). The glass gamepad, which stays HTML and so sat over in-scene panels and took their presses, steps aside while the settings panel or a pause is up. `flat-ui="dom"` keeps the HTML panel (#3307).
|
|
42
|
+
- **The respawn panel is the scene's modal too, and so is the pause in a headset**: a death's panel (`b3dDeath`) and the pause are one modal, over everything so terrain and the wreck's smoke cannot bury it: flat in the middle of the screen, in a headset in front of you a little below eye level, riding your body frame. One that is open when you enter or leave VR comes with you. Both come through `b3d.showModal(svg, height, fallback)`: where the scene has no modal to give (`flat-ui="dom"` on a monitor, a custom `setupXr` rig) it calls `fallback`, the caller's own presentation (the pause's DOM host, the respawn's world plane), including after entering or leaving VR, so a respawn panel never simply vanishes. Two open at once are stacked, the newer nearer and on top (#3307).
|
|
43
|
+
- **Pause is in the scene** (flat): the same panel as a `modal`-layer frame panel pinned to the middle of the screen, square to it, over the world and the ui layer, drawn and pressed first. The reasons it once moved to the DOM (occlusion, a line-of-sight placement, a raycast to press it) are each answered by the layer and the screen pins. The scene panel, open behind it, can still unpause (its header's play button). `flat-ui="dom"` keeps the DOM pause (#3307).
|
|
44
|
+
- **The corner toolbar is in the scene** (flat): settings, Enter VR and the new **full-screen** button are a panel in the `ui` layer pinned to the top-left corner, the same in-scene UI a headset gets. It mirrors the HTML buttons rather than redoing them (`systemBar`): what shows, what is enabled, the icon, and a press is that button's own `click()`, so VR entry and full screen keep one definition and still run inside the user's press. `<tosi-b3d flat-ui="dom">` keeps the HTML overlay (#3307).
|
|
45
|
+
- **System bar icons carry their names**: each button's `title` (or `aria-label`) is its SVG `<title>`, kept current. A texture does not draw it, and everything else can read it. This is the first step of "icons first, never nameless" (UI-DESIGN-NOTES).
|
|
46
|
+
- **Full screen** (`fullscreenButton` part): the scene element, not the page; the standard API with the webkit fallback, and no button where neither exists (iPhone Safari). Toggles, and says which way.
|
|
47
|
+
- **UI layers: `world`, `ui`, `modal`.** A frame panel's `layer` (and `<tosi-b3d-panel layer>`) puts it in a Babylon utility layer drawn over the whole world with its own depth, and given the pointer first: a nearer wall can neither hide it nor take its press. `modal` is over `ui`. Made in pairs per scene (`panelLayerScene(scene, layer)`, exported so a game can promote its own objects); a layered panel's stand-in rides its frame in the main scene and the drawn copy takes its pose each frame. The demo loadouts are `ui`. **In a headset too**: Babylon's XR controller ray picks the world and only its own default layer, and lets a nearer world hit win, so while it picks each frame a ray that hits one of our layers (modal first) returns that pick: it beats the wall, the laser stops at the panel, and the press lands (`pickPanelLayers`, exported). Checked in the emulated headset with a box between the controller and the loadout: the plain pick hits the box, the controller's pick is the panel, and the press opens it (#3307). ⚠️ It does this by wrapping `scene.pickWithRay` from the start of each XR frame until it renders: a pick of yours in that window that crosses a `ui` or `modal` panel returns the panel, whatever your predicate says (#3327, fixed in the next patch).
|
|
48
|
+
|
|
49
|
+
### Fixed
|
|
50
|
+
|
|
51
|
+
- **A `<tosi-b3d>` removed and added back keeps running.** Its system bar was kept as 'the same buttons' across the teardown, so the re-added scene had none, threw in its render loop and froze; an open system panel is now closed with the scene too.
|
|
52
|
+
- **A system-bar panel declared in markup alone** (`preset="system-bar"` and a `title`, no JS `svg`) was dropped silently; it now gets its button and opens a card with its title, as a pinned panel does. `flat-ui` has a row in the attribute table, and a value other than `scene` or `dom` warns once.
|
|
53
|
+
- **Title bars: the title is centred, and the move and × glyphs are centred in the bar with the same margin at the side as at the top** (they were pulled into their corners). The × is drawn larger than the move glyph so the two read the same size: Feather's × covers 12 of its 24 units and the move arrows 20. The HTML panel centres its title too. This is all `chromeLayout`, so popups, `panel3d`, `titled3d` and the settings panel get it alike.
|
|
54
|
+
- **A focused frame panel no longer swells and shrinks with your head** in a headset: its fit to the view is worked out once per focus (and per content size), not every frame.
|
|
55
|
+
|
|
56
|
+
- **A sky with its own moons no longer draws Earth's.** At night the skybox drew its built-in moon on the replayed day arc and lit the scene from it, even when `<tosi-b3d-moon>`s gave the sky other moons: on Io (Land and Sky) a bright disc sat low in the east under Jupiter and read as the sun, while Jupiter was lit, correctly, by the real sun set in the west. Now a sky's own moons replace the built-in one, and the night light comes from the first of them, as bright as its sunlit face (Jupitershine).
|
|
57
|
+
- **A popup opened from the in-scene settings panel can be moved and closed, and fits the screen.** Its × and title bar were tested by a pick in the main scene, but it lives in the `ui` layer's own scene (which also keeps the press from the main scene's observers), so neither did anything; popups are now picked in their own scenes, layers first. A screen-pinned panel's popup is built no taller than the screen (a layer host's `roomFor`; it scrolls past that) and kept on it, where it used to hang from its row at up to 480 px and run off the bottom (the solar system's 27-body picker).
|
|
58
|
+
- A press on a popup opened from the in-scene settings panel (Perf, errors…) no longer closes the settings panel: in-scene planes claim their presses as frame panels do (`claimPointer`).
|
|
59
|
+
- The glass gamepad really steps aside for a menu: `suppress` hid it with `visibility`, which parts of the pad override, so bits of it still drew and took presses meant for the panel under it. It uses `display` now.
|
|
60
|
+
- Full screen: a scene removed and re-added no longer gets a second toggle on its button (one press went in and straight back out), and a refused request no longer throws an unhandled rejection.
|
|
61
|
+
|
|
62
|
+
Size: barrel (min, packages external) 1104.9 KB raw / 376.3 KB gz, +2.11% on 0.10.6.
|
|
63
|
+
|
|
64
|
+
## 0.10.6
|
|
65
|
+
|
|
66
|
+
### Added
|
|
67
|
+
|
|
68
|
+
- **Flat panels can be placed in screen terms**: `screenAnchor` (on `b3dPanel` and frame panels) pins a panel to the view's edges in pixels, a fraction of the axis (`'5%'`) or of the shorter side (`'3vmin'`), with an anchor point, and `height` sets its size on screen. It is solved with `anchorLayout` every frame and placed square to the screen in the head-locked frame, so a resize or a different window shape keeps it where you put it; it wins over `flatAnchor`'s degrees, which suit a headset, where a panel is around you. The demo loadouts use it: 64 px in, 2vmin down, 14% of the screen tall. Opened, a screen-pinned panel comes to the middle of the screen square to it, not tilted up from below eye level.
|
|
69
|
+
- **A box scrolls with a pointer alone**: a scrollbar on its right edge when its content overflows a fixed height (drag the thumb; press the track to page). A wheel scrolls a box on a page, but a panel in a scene gets no wheel and a headset has none, so a long list was cut off with no way to reach the rest. **Sticky children** (`sticky: true` on a leading run) stay put while the rest scrolls under them: the inventory list's heading and drop row (#3290).
|
|
70
|
+
- **The Biped Playground has the loadout, and the pistol lives on your hip.** Firing mode follows where the pistol is: in a hand the gun is up, on the hip it is down, in the bag or dropped there is nothing to raise. The weapon button draws it from the hip or holsters it, and dragging it into a hand does the same. `b3dBiped`'s new `whenWeapon` (JS) lets a game answer the weapon button itself and call `setGunplay`; `demoLoadout({ equip })` starts with things worn and returns its `inv` (#3305).
|
|
71
|
+
- **The Biped Playground has a pool**: 14 x 10 m, 3.5 m deep, in the far corner past the catwalk, with a shelving ramp at one end to walk in on (where `isSwimming`'s hysteresis is tested) and caustics on the floor. Sunk into the ground, because a biped swims anywhere below the water's height: `b3dGround`'s new `holes` (JS) cuts rectangles out of it, keeping its texture unbroken around them. `playground({ pool: false })` leaves it out.
|
|
72
|
+
- **A drop target.** `inventoryPanel`/`inventoryDock` `handleDrop(item, kind, from)` adds a **drop** row at the top of the list: a thing dropped there leaves the inventory, after the game has had its say (return reasons to refuse and it springs back; otherwise put it in the world). Both demos have one (#3290).
|
|
73
|
+
- **`ui.anchorLayout`, the third layout** beside the flow: positioned and layered. An item is pinned to any edge with an offset (units or a fraction, `'50%'`), with a natural or fixed size; between two pins its size is what they leave and a stated size is a minimum. Its anchor (`anchorX`/`anchorY`, `anchor: 'center'`; default the top left) is the point a pin places and the way a minimum that does not fit overflows. `within` pins it inside a rectangle of the container (a window in the artwork). Paint order is the order given or `z`. Pure and unit-tested; the box mode that uses it is next (#3309).
|
|
74
|
+
- **Things have pictures, and say what they are.** An item kind's `icon` (SVG markup) is drawn on its tile: beside the name in a list, alone and filling a socket, and as the ghost a drag carries. Pointing at a thing, or selecting it with a gamepad, shows an info floater (its name, `description`, mass and what it adds by default; `info` replaces that), drawn in the ghost's layer so nothing clips it. `carryTile` takes `icon` and `info`. The demos load one picture per kind from `/item-icons.json` (#3290).
|
|
75
|
+
- **A frame panel can come to you.** Content that dispatches `panelfocus` (`detail: { focus: true }`) on its SVG brings its panel front and centre (`focusAnchor`, default straight ahead and a little low), enlarged (`focusScale`, default 1.9, at 0.75 m) and always revealed; `focus: false` sends it back. A focused panel never sits inside the camera's near plane (it is pushed out and scaled to look the same size) and is never bigger than the view (it fits 92% of it, allowing for being off-centre), so a monitor shows all of it. `flatAnchor` places a panel somewhere else in the flat view (the shoulder is off a monitor's edge), and `<tosi-b3d-panel>` takes `svg`, `flatAnchor`, `focusAnchor` and `focusScale` as JS properties. A frame panel also grows with its SVG's viewBox now, so content that opens wider gets a wider plane. `inventoryDock` asks for focus as it opens, and the main `tosi-b3d` demo pins your loadout up and to the left (over the shoulder in VR, the top left flat): touch or click it and it comes front and centre with your bag (#3290).
|
|
76
|
+
- **An inventory in 3D: `inventoryDock`.** A loadout that lives on a plane in the scene, flat and in a headset. Closed, it is the schematic alone, small; a tap opens it, with the list beside it (a bag) to drag to and from, and a button closes it. Both are drawn in one SVG, so a drag between them is one plane with one ghost (`carryGhostLayer`). Without a `list` it opens to the schematic alone (a craft fitted from a carrier's stock). Demo: "In 3D" on the inventory-box page, where the loadout replaces the "Inventory" placeholder over your shoulder (top left flat) and a touch brings it front and centre (#3290).
|
|
77
|
+
- **A two-handed weapon shows in both hands**: `inventoryPanel`'s `alsoIn(item, kind, at)` names the other slots an item takes up, where it is drawn faded (and can be picked up from either). The game decides which; the panel only draws it (#3290).
|
|
78
|
+
- **Drag and drop, as a model and on a panel** (INVENTORY-DESIGN step 1). `createCarry` is picking up and putting down with nothing drawn: what is carried and from where, the target under the pointer, and its verdict as REASONS; drop is all or nothing; dragging and two taps are one model, and one carry spans every panel. `carryTile`, `carrySocket` and `carryPanel` draw it on a box: things with decorations (a status bar, a damaged or broken outline, a badge), sockets that light when the held thing would fit, dim when not and say why, and a ghost that follows the pointer. A drag goes from one panel to another (they share the carry), and letting go outside every panel puts the thing back.
|
|
79
|
+
- **An inventory model** (`createInventory`, INVENTORY-DESIGN step 2): pure, with the game's catalogue, rules, contributions and prices plugged in. Holders hold slots (a paper doll, hardpoints, mounts), lists (a bag, a stock) and grids (a hull of boxes). A move is checked against every rule on a copy and kept only if all pass, so it happens completely or not at all; it can swap, split a stack, take from the catalogue, or pay. `stage()` is a draft that may be incomplete (a cart, a barter, a design not yet committed); `totals` adds up what is fitted (and what its mount adds); `damage` crosses off a system's boxes. `craft` runs a recipe (inputs used up, tools required but kept, outputs made, one move) and `compile` turns a finished design into a new kind (a ship class, a learned spell, a forged sword). Tested against a party, a loadout, a starship design, a shop and a smithy.
|
|
80
|
+
- **`inventoryPanel`**: one holder of an inventory on a panel, with drag and drop wired to the model, so a socket lights, dims and explains with the game's own rules. Panels sharing an inventory and a carry are a party, a trade or (with `moveFor` adding a price) a shop.
|
|
81
|
+
- **Schematics**: `inventoryPanel({ schematics: { body: svgText } })` draws a container as art, and its slots go where the art's sockets are (`data-slot="…"`, or ids in a `Sockets` group; `readSchematic` reads one). Sockets on art draw nothing at rest, outline when what is held fits, darken when not, and name themselves and the reason on hover. Demos: equip a person, arm a Manta from a carrier's counted stock, and a shop (its goods left, yours right, the deal in the middle: one `move` that buys, sells and pays, or does none of it). Panels take `height` (a scrolling list), `only`/`hide` (split one holder across panels) and `refuse` (a view's own reasons), and show the holder's purse.
|
|
82
|
+
- **A schematic is drawn at the art's own scale**, cropped to what it draws and shrunk only when the panel is too narrow (`schematicFit`), so a socket designed 44 units square is a 44-unit target, not whatever the file's margins left of it.
|
|
83
|
+
- **The demo schematics are coloured by CSS variables** with defaults for a dark panel (`--schematic-body`, `--schematic-socket`, `--schematic-socket-edge`, `--schematic-label`): a host restyles them on the page, and a texture draws the defaults.
|
|
84
|
+
- **A box child can be placed** (`at: { x, y }`): over the flowed child before it, at that offset, taking no flow space and hit first. Sockets on a schematic are this.
|
|
85
|
+
|
|
86
|
+
### Changed
|
|
87
|
+
|
|
88
|
+
- **The closed loadout is a small picture**: no heading over it and no sockets drawn, only what is in them (all return when open), corners rounded well past the panel's own, 0.125 m wide (was 0.3; `focusScale` 4.56 keeps the opened size), and flat it sits nearer the top-left corner (18° up, was 10°), square to the screen. Frame panel anchors gain `flatOn` (parallel to the frame's view plane rather than turned to face the eye) and `tiltDeg` (tip it about its own horizontal axis without moving it) (#3290).
|
|
89
|
+
- **Inventory list rows are full width**, so a row is a button you can hit anywhere along it. **Swimming starts chest deep** (0.65 submerged, down to 0.5 to stand again; it was waist deep, 0.5 and 0.35), and a swimmer rides a little higher than the last change (12 cm of water above the head bone, was 20; treading unchanged) (#3290).
|
|
90
|
+
- **The opened dock's list is as tall as the loadout beside it** (it scrolls), not a fixed 540 that made the whole dock taller than its picture. `height` still sets it explicitly (#3290).
|
|
91
|
+
- **An inventory panel's heading sits over its schematic's top left** (title, totals, the container's name) instead of stacked above it, so the picture is larger, which matters most on the small pinned loadout. A panel whose first container is not a schematic keeps its heading above (#3290).
|
|
92
|
+
- **SVG panels are mipmapped** (`SvgTexture` `mipmaps`, default `true`: trilinear, anisotropic 4). A panel is nearly always drawn smaller than its texture (1024 px over ~300 px of a Quest 3's view at arm's length), and unfiltered its hairlines broke up and its text crawled; the small pinned loadout's socket outlines were visibly broken and now draw whole. Every in-scene panel, popup and HUD goes through it. Mip generation measured under 0.1 ms per repaint at 1024 px; it costs a third more texture memory. `mipmaps: false` for a texture always seen at about a texel per pixel.
|
|
93
|
+
- **An inventory panel on a page fits the space it is given** instead of being cropped (`fit`, default on): side by side they shrink in proportion, in a column it is no wider than the column, never taller than its container, never larger than drawn, always the same shape. Anything the page sets inline on the host wins (#3290).
|
|
94
|
+
- The default body panels are an inventory over the left shoulder and a **journal** over the right (both were "Inventory") (#3290).
|
|
95
|
+
- `panelScene`'s orbit camera stops at half its starting distance (`camera.minRadius`), so zooming cannot pass through the panel (#3290).
|
|
96
|
+
- **A planet's edge has a golden hour.** Where you see its air edge on and the sun is low over it, the air takes the colour left when its own is scattered out: Earth's goes gold, Mars's dusty air goes blue. The whole lit rim takes it together, by how far the sun has gone behind the planet from where you are: lit from the side, the rim (its "poles" included) stays the air's own colour. Face on, nothing changes (#3285).
|
|
97
|
+
- **The Solar System's sky is tilted as ours is**: the planets orbit about 60.2° to the galaxy's plane, so the Milky Way crosses the orbits steeply instead of running along them (`spaceBackdrop({ tilt })`).
|
|
98
|
+
- **While you carry something, the sockets that would take it light up**, the one under the pointer brighter and named, and the rest go dark. The ghost hangs above the pointer, so the socket you are over stays in sight (#3290).
|
|
99
|
+
- **A panel that shows one list takes a drop anywhere on it**, not just on its tiles or the "put in" row at the bottom of a scrolled list, and is outlined while it would take what you carry. Dragging a thing off a socket back into the bag is a drop on the bag (`carryPanel(box, carry, { fallback })`) (#3290).
|
|
100
|
+
- **A drop that does not land springs back.** Refused by its target, let go on nothing, or released outside every panel, the ghost returns to where it was picked up and shows why it was refused there for a moment. `carryPanel` now returns `dispose`, and `inventoryPanel` calls it on each rebuild (a rebuilt panel used to leave its old carry subscription behind) (#3290).
|
|
101
|
+
|
|
102
|
+
### Fixed
|
|
103
|
+
|
|
104
|
+
- **In a headset, a screen-pinned panel is where its VR anchor says** (found by the release review). Screen pins are for a monitor: in a session they were still applied, putting the loadout a metre ahead, sized from the flat canvas, instead of on your left shoulder. `presentationSpec(spec, flat)` is now the one rule every attach site uses (flat: the flat anchor and screen pins; in VR: neither). Checked in the emulated headset.
|
|
105
|
+
- **Two-tap works on a page** (found by the release review). The page examples cancelled the carry on every `pointerup`, and a tap pick-up happens ON a release, so it was put straight back. `carryOverlay` now cancels a drag let go over nothing itself, after the panels have had the release, and never a tap; the examples no longer add their own.
|
|
106
|
+
- **A press on a panel in the scene no longer also works the game's controls.** The biped reads mouse buttons (the left button is A, a jump), so every press on the playground's loadout made the hero jump, and with a weapon up could fire it. A frame panel now cancels the `pointerdown` it takes, which by the web's own rule stops the matching `mousedown`/`mouseup`; the scene's picking is pointer events and carries on.
|
|
107
|
+
- **A focused panel fits the view a looking-down camera actually has.** Its room was worked out from where it sits in its frame, which is level while a follow camera pitches down; it is now measured in the camera's own view.
|
|
108
|
+
- **Swimmers ride lower.** The water sat at the head bone (the base of the skull), which left a treader's shoulders and arms out and a swimmer's head, shoulders and back riding on top. It now sits 10 cm higher on a treader (at the jaw: the head out) and 20 cm on a swimmer (over the back: the head breaking).
|
|
109
|
+
- **Raising the weapon aims straight ahead.** The aim is the look pitch, which kept whatever it was left at (looking at the ground, the last dive), so the gun often came up pointing at your feet. `setGunplay(true)` levels it, flat only (in a headset the aim is the controller); lowering the weapon leaves the view alone.
|
|
110
|
+
- **First person shows the world, not the back of your head.** Sprinting leans the head 22° forward and swimming far more, and the back and underside of the skull filled the view (measured in the playground: half the screen while sprinting). The head bone is collapsed while in first person, the way first-person games do it, so the arms and body stay (your hands show as you swim); it is restored out of first person, and the shadow is headless while you are in it. The eye now sits along the head's own axes, 10 cm up the skull, rather than offset along the body's level facing (#3291).
|
|
111
|
+
- **Aiming down while swimming dives.** At the surface a swimmer's buoyancy (set so the swim pose floats on the waterline) lifted about as fast as a downward stroke sank, so pitching down with the right stick and swimming went nowhere, and up is capped at the surface by design: the stick seemed to do nothing either way. A stroke aimed down now takes the vertical from buoyancy in proportion to how steeply and how hard you swim (`diveBuoyancy`); let go and buoyancy surfaces you as before. Measured in the new pool: 1.3 m deeper in two seconds, where it was 0.3.
|
|
112
|
+
- **An open inventory survives entering or leaving a headset.** Opened flat, then into VR, the loadout came up small on its shoulder still showing the bag, and a tap did nothing (it was already open), there and back out. A session change rebuilds the frame panels, and the new one never heard the dock's `panelfocus`. Content now also marks its SVG `data-focus="true"` while focused, and a frame panel made later starts from it (#3290).
|
|
113
|
+
- **A sun's shadows can be turned off**: `<tosi-b3d-sun shadows="off">` (`'on'` by default; live, so a toggle works). The demos, the README and this repo's notes passed `shadowCascading: true`, which was never an attribute: shadows are always cascaded, and `shadowCascading: false` silently did nothing. It is gone from every example.
|
|
114
|
+
- **No more fine bands over every lit surface.** `<tosi-b3d-sun>`'s `shadowBias` default is 0.0005 (was Babylon's 0.00005). With `shadowNormalBias` at 0.02, which has to stay low or thin limbs lose their shadow, plain scenes (the primitives and getting-started demos) were striped with shadow acne on the ground, the boxes and the spheres. A character's shadow is unchanged. The attribute table also said `shadowNormalBias` defaulted to 0.05; it is 0.02.
|
|
115
|
+
- **The checker ground is checkered.** `b3dGround({ texture: 'checker' })` drew one flat grey: the texture clamped at its edge instead of repeating, so every tile past the first was the edge colour. It repeats now, and is mipmapped so it does not shimmer toward the horizon. Its dark squares are 70% of the ground colour (they were a fixed grey barely darker than the default ground).
|
|
116
|
+
- **Getting started opens on a running scene**: the first scene is a live example, and below it the same scene as plain HTML markup, live too.
|
|
117
|
+
- **A star system keeps real time.** Every day, month and year is the real one, and a new `timeScale` attribute (simulated seconds per real second, default 3600: an hour a second, an Earth day in 24 seconds) says how fast it runs; both demos have a log **time** slider from real time to a year every ten seconds. Planets used to turn once in about 80 seconds against a 60-second year, so they looked still, and moons took longer to go round their planet than the planet took to go round the Sun. Now `SystemPlanetSpec.day` (Earth days, negative backwards) and `SystemBodySpec.period` (a moon's month in days, negative backwards) carry the truth for Sol (Venus and Uranus turn backwards, Triton goes round backwards); a generated moon gets Kepler's month for a true distance (`moonPeriod`), a generated rock an Earth day, a giant a Jupiter one. Orbits, months and days are angles of one clock (`spinAngle`), so they keep time together and stop together with `animate`.
|
|
118
|
+
- **Dragging on a frame panel no longer turns the camera.** Flat, the camera's own controls took the same pointer, so a drag across a panel orbited the view behind it. A press on a frame panel now holds the camera's controls until release (#3290).
|
|
119
|
+
- **A drag that leaves its panel at once still drags.** A press on a thing, then a pointer that was already over another panel by its next move (a controller ray moves in big steps; so does a fast flick), forgot the press and dragged nothing. Leaving a panel with a thing pressed now starts the drag. Found driving the loadout with an emulated controller (#3290).
|
|
120
|
+
- **A trigger press in VR always counts, whichever hand it is.** Babylon points with one controller, the first to connect, and a press on the other one only switched to it: the press was dropped, so the first press of a session (and any press after the headset swapped controllers) did nothing. Now the right hand points first, and a press on the hand that is not pointing switches to it and is delivered. It reads Babylon's private per-controller state; a Babylon upgrade that renames it brings back the dropped press rather than breaking anything (#3290).
|
|
121
|
+
- An inventory panel's totals line is always there, so the first thing worn no longer pushes the schematic down (#3290).
|
|
122
|
+
- **Dragging between inventory panels works with a finger or a headset's laser.** Both are captured by the element they press, so the moves and the release never reached another panel; `inventoryPanel` now lets the capture go as it arrives (a mouse was never captured, which is why it worked on a desktop). And on a page the ghost is drawn in one overlay above every panel (`carryOverlay(carry)`, with `carryPanel(…, { ghost: false })`), so it crosses from one panel to the next instead of being clipped by each. A panel on a 3D plane keeps its own ghost (#3290).
|
|
123
|
+
|
|
124
|
+
- **A thing can be dragged out of a socket** (it could only be dragged out of a list), and a thing in a list is itself a place to drop into that list, so a long, scrolled list takes a drop anywhere. A thing put back in a list joins a stack of its kind with room (a missile returned to the carrier is counted again); one drawn from a stack swaps with what a slot held.
|
|
125
|
+
|
|
126
|
+
Size: barrel (min, packages external) 1082.1 KB raw / 368.9 KB gz, +3.80% on 0.10.5.
|
|
127
|
+
|
|
9
128
|
## 0.10.5
|
|
10
129
|
|
|
11
130
|
### Added
|
package/README.md
CHANGED
|
@@ -17,7 +17,7 @@ markup you can read:
|
|
|
17
17
|
|
|
18
18
|
```javascript
|
|
19
19
|
b3d(
|
|
20
|
-
b3dSun(
|
|
20
|
+
b3dSun(),
|
|
21
21
|
b3dSkybox({ timeOfDay: 6 }),
|
|
22
22
|
b3dLoader({ url: './scene.glb' }),
|
|
23
23
|
b3dWater({ y: -0.2 })
|
|
@@ -45,7 +45,7 @@ import { b3d, b3dSun, b3dSkybox, b3dGround, b3dBox, b3dSphere } from 'tosijs-3d'
|
|
|
45
45
|
|
|
46
46
|
document.body.append(
|
|
47
47
|
b3d(
|
|
48
|
-
b3dSun(
|
|
48
|
+
b3dSun(),
|
|
49
49
|
b3dSkybox({ timeOfDay: 10 }),
|
|
50
50
|
b3dGround({ size: 24, texture: 'checker' }),
|
|
51
51
|
b3dBox({ x: -1.5, y: 0.5, color: '#c8553d' }),
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/** A length: layout units, or a fraction of the container (`'50%'`). */
|
|
2
|
+
export type AnchorLength = number | `${number}%`;
|
|
3
|
+
/** A rectangle, top-left origin, in layout units. */
|
|
4
|
+
export interface AnchorBox {
|
|
5
|
+
x: number;
|
|
6
|
+
y: number;
|
|
7
|
+
width: number;
|
|
8
|
+
height: number;
|
|
9
|
+
}
|
|
10
|
+
export interface AnchorItem {
|
|
11
|
+
left?: AnchorLength;
|
|
12
|
+
right?: AnchorLength;
|
|
13
|
+
top?: AnchorLength;
|
|
14
|
+
bottom?: AnchorLength;
|
|
15
|
+
/**
|
|
16
|
+
* The point of the item a pin places, as a fraction of its width: 0 its
|
|
17
|
+
* left edge (default), 0.5 its centre, 1 its right edge. Between two pins,
|
|
18
|
+
* which way a minimum that does not fit overflows.
|
|
19
|
+
*/
|
|
20
|
+
anchorX?: number;
|
|
21
|
+
/** The same, of its height: 0 its top edge (default). */
|
|
22
|
+
anchorY?: number;
|
|
23
|
+
/** Both anchors at once: `'center'` is `anchorX: 0.5, anchorY: 0.5`. */
|
|
24
|
+
anchor?: 'center';
|
|
25
|
+
/** Exact with one pin or none; a minimum between two pins. */
|
|
26
|
+
width?: AnchorLength;
|
|
27
|
+
/** Exact with one pin or none; a minimum between two pins. */
|
|
28
|
+
height?: AnchorLength;
|
|
29
|
+
/** Paint order; higher is on top. Default 0, ties keep the order given. */
|
|
30
|
+
z?: number;
|
|
31
|
+
/**
|
|
32
|
+
* The item's natural size: called with no width for its natural width,
|
|
33
|
+
* then with the resolved width for its height. Leave `width` out of the
|
|
34
|
+
* answer to fill what it is given. Absent: no natural size, so it fills
|
|
35
|
+
* what it is given on both axes.
|
|
36
|
+
*/
|
|
37
|
+
measure?: (width?: number) => {
|
|
38
|
+
width?: number;
|
|
39
|
+
height: number;
|
|
40
|
+
};
|
|
41
|
+
/** Pin within this rectangle of the container instead of its edges. */
|
|
42
|
+
within?: AnchorBox;
|
|
43
|
+
}
|
|
44
|
+
export interface AnchorResult {
|
|
45
|
+
/** One box per item, in the order given. */
|
|
46
|
+
boxes: AnchorBox[];
|
|
47
|
+
/** Item indices bottom to top: paint in this order, hit-test from the end. */
|
|
48
|
+
order: number[];
|
|
49
|
+
}
|
|
50
|
+
/** A length in layout units, given the size a fraction is of. */
|
|
51
|
+
export declare function anchorLength(v: AnchorLength, of: number): number;
|
|
52
|
+
/**
|
|
53
|
+
* Lay out `items` in a container `width` x `height`. Returns a box per item
|
|
54
|
+
* and the order to paint them in.
|
|
55
|
+
*/
|
|
56
|
+
export declare function anchorLayout(items: AnchorItem[], container: {
|
|
57
|
+
width: number;
|
|
58
|
+
height: number;
|
|
59
|
+
}): AnchorResult;
|
|
60
|
+
//# sourceMappingURL=anchor-layout.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"anchor-layout.d.ts","sourceRoot":"","sources":["../src/anchor-layout.ts"],"names":[],"mappings":"AA4EA,wEAAwE;AACxE,MAAM,MAAM,YAAY,GAAG,MAAM,GAAG,GAAG,MAAM,GAAG,CAAA;AAEhD,qDAAqD;AACrD,MAAM,WAAW,SAAS;IACxB,CAAC,EAAE,MAAM,CAAA;IACT,CAAC,EAAE,MAAM,CAAA;IACT,KAAK,EAAE,MAAM,CAAA;IACb,MAAM,EAAE,MAAM,CAAA;CACf;AAED,MAAM,WAAW,UAAU;IACzB,IAAI,CAAC,EAAE,YAAY,CAAA;IACnB,KAAK,CAAC,EAAE,YAAY,CAAA;IACpB,GAAG,CAAC,EAAE,YAAY,CAAA;IAClB,MAAM,CAAC,EAAE,YAAY,CAAA;IACrB;;;;OAIG;IACH,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,yDAAyD;IACzD,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,wEAAwE;IACxE,MAAM,CAAC,EAAE,QAAQ,CAAA;IACjB,8DAA8D;IAC9D,KAAK,CAAC,EAAE,YAAY,CAAA;IACpB,8DAA8D;IAC9D,MAAM,CAAC,EAAE,YAAY,CAAA;IACrB,2EAA2E;IAC3E,CAAC,CAAC,EAAE,MAAM,CAAA;IACV;;;;;OAKG;IACH,OAAO,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,MAAM,KAAK;QAAE,KAAK,CAAC,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAA;IAChE,uEAAuE;IACvE,MAAM,CAAC,EAAE,SAAS,CAAA;CACnB;AAED,MAAM,WAAW,YAAY;IAC3B,4CAA4C;IAC5C,KAAK,EAAE,SAAS,EAAE,CAAA;IAClB,8EAA8E;IAC9E,KAAK,EAAE,MAAM,EAAE,CAAA;CAChB;AAED,iEAAiE;AACjE,wBAAgB,YAAY,CAAC,CAAC,EAAE,YAAY,EAAE,EAAE,EAAE,MAAM,GAAG,MAAM,CAGhE;AAuCD;;;GAGG;AACH,wBAAgB,YAAY,CAC1B,KAAK,EAAE,UAAU,EAAE,EACnB,SAAS,EAAE;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,GAC3C,YAAY,CAoCd"}
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
/*#
|
|
2
|
+
# anchor-layout
|
|
3
|
+
|
|
4
|
+
Pure **anchored layout**: the third way to lay out the SVG UI, beside the
|
|
5
|
+
flow ([flow-layout](/flow-layout/)). Where the flow stacks and wraps, this
|
|
6
|
+
**positions and layers**: each item is pinned to the edges of its container
|
|
7
|
+
(or to a named rectangle inside it, such as a window in a piece of artwork),
|
|
8
|
+
and is drawn over whatever came before it. A HUD, widgets composed onto
|
|
9
|
+
artwork, a desktop-style window with its title bar and close button: all of
|
|
10
|
+
these are this.
|
|
11
|
+
|
|
12
|
+
Like the flow it is pure (no DOM, no Babylon), measured in layout units, and
|
|
13
|
+
re-run whenever the container changes size.
|
|
14
|
+
|
|
15
|
+
## The rule, per axis
|
|
16
|
+
|
|
17
|
+
Horizontally (vertically the same, with `top`, `bottom`, `anchorY` and
|
|
18
|
+
`height`):
|
|
19
|
+
|
|
20
|
+
| Pins | Width | Where |
|
|
21
|
+
| --- | --- | --- |
|
|
22
|
+
| `left` and `right` | what the pins leave, but never less than `width` (a stated width is a MINIMUM) | between the pins; a minimum that does not fit overflows by the anchor |
|
|
23
|
+
| `left` | `width`, else the item's natural width | its anchor point at `left` |
|
|
24
|
+
| `right` | the same | its right edge at `right` from the right edge (its anchor point, if you give one) |
|
|
25
|
+
| none | the same | as `left: 0` |
|
|
26
|
+
|
|
27
|
+
An offset or a size is a number (layout units) or a **fraction** of the
|
|
28
|
+
container, written `'50%'`.
|
|
29
|
+
|
|
30
|
+
**The anchor** is the point of the ITEM that a pin places, as fractions of its
|
|
31
|
+
own size: `anchorX` 0 is its left edge, 0.5 its centre, 1 its right edge. The
|
|
32
|
+
default is the TOP LEFT, to keep surprises down, so `left: '50%'` puts the left
|
|
33
|
+
edge at the middle and **`anchor: 'center'` with `left: '50%'` and `top: '50%'`
|
|
34
|
+
centres an item**. A lone `right` (or `bottom`) pin places the right (bottom)
|
|
35
|
+
edge unless an anchor is given, or a default top-left anchor would hang the
|
|
36
|
+
item outside the container.
|
|
37
|
+
|
|
38
|
+
**The anchor also decides overflow.** Between two pins the item is stretched;
|
|
39
|
+
when its minimum does not fit, the anchor says which way the excess goes: 0
|
|
40
|
+
runs past the right pin (as CSS's `min-width` does), 1 past the left, 0.5
|
|
41
|
+
spills evenly both ways. It is never squashed below its minimum.
|
|
42
|
+
|
|
43
|
+
- **Width comes first.** The item is then asked for its height AT that width,
|
|
44
|
+
so text in a stretched item wraps to the width it was given.
|
|
45
|
+
- **An item with no natural width** (a block that fills what it is given)
|
|
46
|
+
fills from its pin to the opposite edge, or the whole width with no pin.
|
|
47
|
+
- **Layers** paint in the order given unless an item has a `z` (higher is
|
|
48
|
+
on top; equal `z` keeps the order given). `order` lists the items bottom
|
|
49
|
+
to top; hit-test it from the end.
|
|
50
|
+
- **`within`** is a rectangle inside the container (a window in the art, by
|
|
51
|
+
name, measured by the caller) that the item's pins and fractions are
|
|
52
|
+
measured against instead of the container's edges.
|
|
53
|
+
|
|
54
|
+
## Example
|
|
55
|
+
|
|
56
|
+
```javascript
|
|
57
|
+
import { ui } from 'tosijs-3d'
|
|
58
|
+
const { anchorLayout } = ui
|
|
59
|
+
|
|
60
|
+
// A 400 x 300 window: a title bar across the top, a close button in its
|
|
61
|
+
// corner, content filling the rest, and a dialog centred over it all.
|
|
62
|
+
const { boxes } = anchorLayout(
|
|
63
|
+
[
|
|
64
|
+
{ left: 0, right: 0, top: 0, height: 28 },
|
|
65
|
+
{ right: 4, top: 4, width: 20, height: 20 },
|
|
66
|
+
{ left: 0, right: 0, top: 28, bottom: 0 },
|
|
67
|
+
{ left: '50%', top: '50%', anchor: 'center', width: '60%', height: 120 },
|
|
68
|
+
],
|
|
69
|
+
{ width: 400, height: 300 }
|
|
70
|
+
)
|
|
71
|
+
// boxes[0] = { x: 0, y: 0, width: 400, height: 28 }
|
|
72
|
+
// boxes[3] = { x: 80, y: 90, width: 240, height: 120 }
|
|
73
|
+
```
|
|
74
|
+
*/
|
|
75
|
+
/*{ "parent": "box", "order": 11 }*/
|
|
76
|
+
/** A length in layout units, given the size a fraction is of. */
|
|
77
|
+
export function anchorLength(v, of) {
|
|
78
|
+
if (typeof v === 'number')
|
|
79
|
+
return v;
|
|
80
|
+
return (parseFloat(v) / 100) * of;
|
|
81
|
+
}
|
|
82
|
+
/** Size and offset along one axis; `natural` is the item's own size, if any. */
|
|
83
|
+
function solveAxis(a, span, natural) {
|
|
84
|
+
const L = (v) => anchorLength(v, span);
|
|
85
|
+
const stated = a.size != null ? L(a.size) : undefined;
|
|
86
|
+
const anchor = a.anchor ?? 0;
|
|
87
|
+
if (a.start != null && a.end != null) {
|
|
88
|
+
const at = L(a.start);
|
|
89
|
+
const between = span - at - L(a.end);
|
|
90
|
+
const size = Math.max(between, stated ?? 0);
|
|
91
|
+
return { at: at - anchor * (size - between), size };
|
|
92
|
+
}
|
|
93
|
+
const own = (room) => stated ?? natural() ?? room;
|
|
94
|
+
if (a.start != null) {
|
|
95
|
+
const p = L(a.start);
|
|
96
|
+
const size = own(span - p);
|
|
97
|
+
return { at: p - anchor * size, size };
|
|
98
|
+
}
|
|
99
|
+
if (a.end != null) {
|
|
100
|
+
const p = span - L(a.end);
|
|
101
|
+
const size = own(p);
|
|
102
|
+
return { at: p - (a.anchor ?? 1) * size, size };
|
|
103
|
+
}
|
|
104
|
+
const size = own(span);
|
|
105
|
+
return { at: -anchor * size, size };
|
|
106
|
+
}
|
|
107
|
+
/**
|
|
108
|
+
* Lay out `items` in a container `width` x `height`. Returns a box per item
|
|
109
|
+
* and the order to paint them in.
|
|
110
|
+
*/
|
|
111
|
+
export function anchorLayout(items, container) {
|
|
112
|
+
const boxes = items.map((it) => {
|
|
113
|
+
const r = it.within ?? {
|
|
114
|
+
x: 0,
|
|
115
|
+
y: 0,
|
|
116
|
+
width: container.width,
|
|
117
|
+
height: container.height,
|
|
118
|
+
};
|
|
119
|
+
const centre = it.anchor === 'center' ? 0.5 : undefined;
|
|
120
|
+
const h = solveAxis({
|
|
121
|
+
start: it.left,
|
|
122
|
+
end: it.right,
|
|
123
|
+
anchor: it.anchorX ?? centre,
|
|
124
|
+
size: it.width,
|
|
125
|
+
}, r.width, () => it.measure?.().width);
|
|
126
|
+
const v = solveAxis({
|
|
127
|
+
start: it.top,
|
|
128
|
+
end: it.bottom,
|
|
129
|
+
anchor: it.anchorY ?? centre,
|
|
130
|
+
size: it.height,
|
|
131
|
+
}, r.height, () => it.measure?.(h.size).height);
|
|
132
|
+
return { x: r.x + h.at, y: r.y + v.at, width: h.size, height: v.size };
|
|
133
|
+
});
|
|
134
|
+
const order = items
|
|
135
|
+
.map((it, i) => ({ z: it.z ?? 0, i }))
|
|
136
|
+
.sort((a, b) => a.z - b.z || a.i - b.i)
|
|
137
|
+
.map((o) => o.i);
|
|
138
|
+
return { boxes, order };
|
|
139
|
+
}
|
|
140
|
+
//# sourceMappingURL=anchor-layout.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"anchor-layout.js","sourceRoot":"","sources":["../src/anchor-layout.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAyEE;AACF,oCAAoC;AAoDpC,iEAAiE;AACjE,MAAM,UAAU,YAAY,CAAC,CAAe,EAAE,EAAU;IACtD,IAAI,OAAO,CAAC,KAAK,QAAQ;QAAE,OAAO,CAAC,CAAA;IACnC,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC,GAAG,EAAE,CAAA;AACnC,CAAC;AASD,gFAAgF;AAChF,SAAS,SAAS,CAChB,CAAO,EACP,IAAY,EACZ,OAAiC;IAEjC,MAAM,CAAC,GAAG,CAAC,CAAe,EAAE,EAAE,CAAC,YAAY,CAAC,CAAC,EAAE,IAAI,CAAC,CAAA;IACpD,MAAM,MAAM,GAAG,CAAC,CAAC,IAAI,IAAI,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,SAAS,CAAA;IACrD,MAAM,MAAM,GAAG,CAAC,CAAC,MAAM,IAAI,CAAC,CAAA;IAC5B,IAAI,CAAC,CAAC,KAAK,IAAI,IAAI,IAAI,CAAC,CAAC,GAAG,IAAI,IAAI,EAAE,CAAC;QACrC,MAAM,EAAE,GAAG,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAA;QACrB,MAAM,OAAO,GAAG,IAAI,GAAG,EAAE,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAA;QACpC,MAAM,IAAI,GAAG,IAAI,CAAC,GAAG,CAAC,OAA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I,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;SACtC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;IAClB,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,CAAA;AACzB,CAAC"}
|
package/dist/b3d-beacon.js
CHANGED
package/dist/b3d-biped.d.ts
CHANGED
|
@@ -219,9 +219,16 @@ export declare class B3dBiped extends B3dControllable {
|
|
|
219
219
|
/** Eye position for first-person: the head bone (or eyeHeight fallback) nudged
|
|
220
220
|
* up + forward to roughly the eyes, so the camera sits at the eyes rather than
|
|
221
221
|
* the neck / head-bone base — which would leave the head & neck in front of the
|
|
222
|
-
* view.
|
|
223
|
-
*
|
|
224
|
-
|
|
222
|
+
* view. Returns a cached vector — read it now, don't retain.
|
|
223
|
+
*
|
|
224
|
+
* ALONG THE HEAD'S OWN AXES, not the body's. A sprint leans the head 22°
|
|
225
|
+
* forward and a swim far more, and an offset along the body's level facing
|
|
226
|
+
* left the eye inside the skull: in first person the back of your own head
|
|
227
|
+
* filled the screen as you ran (Tonio: "first person view when swimming is a
|
|
228
|
+
* disaster and it's still a big problem when running"). The UAL head bone's
|
|
229
|
+
* forward is the face's, measured. Only the eye's POSITION follows the head;
|
|
230
|
+
* the view's orientation does not (no bob in the rotation, no roll). */
|
|
231
|
+
getHeadPosition(extraForward?: number): BABYLON.Vector3 | null;
|
|
225
232
|
xrStuff?: XRStuff;
|
|
226
233
|
private xrInputProvider?;
|
|
227
234
|
animationState?: AnimState;
|
|
@@ -302,6 +309,13 @@ export declare class B3dBiped extends B3dControllable {
|
|
|
302
309
|
*/
|
|
303
310
|
gunplay: boolean;
|
|
304
311
|
private weaponWasPressed;
|
|
312
|
+
/**
|
|
313
|
+
* What the weapon button does, when a game decides (JS only). Called with
|
|
314
|
+
* whether the button asks for the weapon UP; the game moves it (draw from
|
|
315
|
+
* the hip, holster it) and calls `setGunplay` if and when it is in hand.
|
|
316
|
+
* Unset, the button toggles `gunplay` as before.
|
|
317
|
+
*/
|
|
318
|
+
whenWeapon: ((up: boolean) => void) | null;
|
|
305
319
|
/**
|
|
306
320
|
* Put the weapon up or down.
|
|
307
321
|
*
|
package/dist/b3d-biped.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"b3d-biped.d.ts","sourceRoot":"","sources":["../src/b3d-biped.ts"],"names":[],"mappings":"AAkOA,OAAO,KAAK,OAAO,MAAM,iBAAiB,CAAA;AAC1C,OAAO,EACL,OAAO,EAKR,MAAM,gBAAgB,CAAA;
|
|
1
|
+
{"version":3,"file":"b3d-biped.d.ts","sourceRoot":"","sources":["../src/b3d-biped.ts"],"names":[],"mappings":"AAkOA,OAAO,KAAK,OAAO,MAAM,iBAAiB,CAAA;AAC1C,OAAO,EACL,OAAO,EAKR,MAAM,gBAAgB,CAAA;AAyBvB,OAAO,EAQL,KAAK,GAAG,EAET,MAAM,UAAU,CAAA;AACjB,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,eAAe,CAAA;AAExC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAA;AAC1D,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AACvD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAA;AAEtD,OAAO,EAAgB,KAAK,cAAc,EAAE,MAAM,sBAAsB,CAAA;AAWxE,MAAM,MAAM,aAAa,GAAG;IAC1B,SAAS,EAAE,MAAM,CAAA;IACjB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,SAAS,CAAC,EAAE,OAAO,CAAA;CACpB,CAAA;AAED,qBAAa,SAAS;IACpB,SAAS,EA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