@benev/tact 0.2.0-0 → 0.3.0-1
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 +48 -390
- package/package.json +25 -27
- package/s/_archive/README.md +435 -0
- package/s/_archive/deck/deck.ts +69 -0
- package/s/_archive/demo/main.bundle.ts +10 -0
- package/s/_archive/demo/main.css +85 -0
- package/s/_archive/index.html.ts +61 -0
- package/s/_archive/index.ts +8 -0
- package/s/_archive/tests.test.ts +6 -0
- package/s/_archive/utils/circular-clamp.ts +14 -0
- package/s/_archive/utils/evergreen.ts +10 -0
- package/s/_archive/utils/split-axis.ts +15 -0
- package/s/assets/b.png +0 -0
- package/s/core/atom/defaults.ts +32 -0
- package/s/core/atom/lens-algo.ts +84 -0
- package/s/core/atom/types.ts +44 -0
- package/s/core/bindings/normalize.ts +27 -0
- package/s/core/bindings/shape.ts +15 -0
- package/s/core/bindings/table.ts +22 -0
- package/s/core/intent/bucket.ts +28 -0
- package/s/core/intent/consts.ts +4 -0
- package/s/core/intent/decode.ts +23 -0
- package/s/core/intent/encode.ts +20 -0
- package/s/core/intent/merge.ts +15 -0
- package/s/core/parts/action.ts +36 -0
- package/s/core/parts/sample-map.ts +24 -0
- package/s/core/resolvers/actions.ts +30 -0
- package/s/core/resolvers/intents.ts +106 -0
- package/s/core/types.ts +40 -0
- package/s/deck/controller.ts +35 -0
- package/s/deck/deck.ts +76 -53
- package/s/deck/parts/profiles.ts +39 -0
- package/s/deck/parts/runtime.ts +11 -0
- package/s/deck/parts/settings.ts +30 -0
- package/s/deck/port.ts +35 -0
- package/s/deck/types.ts +16 -0
- package/s/demo/demo-app/element.ts +17 -0
- package/s/demo/demo-app/style.css.ts +10 -0
- package/s/demo/main.bundle.ts +67 -6
- package/s/demo/main.css +6 -8
- package/s/device/devices.ts +24 -0
- package/s/device/gamepad.ts +42 -0
- package/s/device/keyboard.ts +33 -0
- package/s/device/pad/on-pad.ts +50 -0
- package/s/device/pad/pad.ts +10 -0
- package/s/device/pointer.ts +97 -0
- package/s/device/sampler.ts +25 -0
- package/s/device/stick.ts +24 -0
- package/s/gamepad/gamepad-app/element.ts +65 -0
- package/s/gamepad/gamepad-app/style.css.ts +73 -0
- package/s/gamepad/index.html.ts +44 -0
- package/s/gamepad/main.bundle.ts +6 -0
- package/s/gamepad/main.css +60 -0
- package/s/index-ui.ts +3 -0
- package/s/index.html.ts +10 -17
- package/s/index.ts +28 -5
- package/s/test.ts +339 -0
- package/s/ui/views/desk/style.css.ts +70 -0
- package/s/ui/views/desk/view.ts +122 -0
- package/s/utils/circular-clamp.ts +2 -2
- package/s/utils/do-async.ts +5 -0
- package/s/utils/freeze-clone.ts +7 -0
- package/s/utils/identifier.ts +30 -0
- package/s/utils/insert.ts +6 -0
- package/s/utils/is-down.ts +5 -0
- package/s/utils/make-id.ts +7 -0
- package/s/utils/remap.ts +7 -0
- package/s/utils/shift-limit.ts +9 -0
- package/s/utils/sort-by-key.ts +7 -0
- package/s/utils/tmax.ts +7 -0
- package/s/utils/tmin.ts +7 -0
- package/x/_archive/demo/main.css +85 -0
- package/x/assets/b.png +0 -0
- package/x/core/{bindings/parts → atom}/defaults.d.ts +1 -1
- package/x/core/atom/defaults.js.map +1 -0
- package/x/core/{bindings/parts → atom}/lens-algo.d.ts +1 -1
- package/x/core/{bindings/parts → atom}/lens-algo.js +8 -8
- package/x/core/atom/lens-algo.js.map +1 -0
- package/x/core/{bindings → atom}/types.d.ts +1 -15
- package/x/core/{devices → atom}/types.js.map +1 -1
- package/x/core/bindings/normalize.d.ts +2 -0
- package/x/core/bindings/normalize.js +17 -0
- package/x/core/bindings/normalize.js.map +1 -0
- package/x/core/bindings/shape.d.ts +2 -0
- package/x/core/bindings/shape.js +10 -0
- package/x/core/bindings/shape.js.map +1 -0
- package/x/core/bindings/table.d.ts +2 -0
- package/x/core/bindings/table.js +15 -0
- package/x/core/bindings/table.js.map +1 -0
- package/x/core/intent/bucket.d.ts +7 -0
- package/x/core/intent/bucket.js +21 -0
- package/x/core/intent/bucket.js.map +1 -0
- package/x/core/intent/consts.d.ts +2 -0
- package/x/core/intent/consts.js +3 -0
- package/x/core/intent/consts.js.map +1 -0
- package/x/core/intent/decode.d.ts +3 -0
- package/x/core/intent/decode.js +18 -0
- package/x/core/intent/decode.js.map +1 -0
- package/x/core/intent/encode.d.ts +3 -0
- package/x/core/intent/encode.js +15 -0
- package/x/core/intent/encode.js.map +1 -0
- package/x/core/intent/merge.d.ts +3 -0
- package/x/core/intent/merge.js +10 -0
- package/x/core/intent/merge.js.map +1 -0
- package/x/core/{bindings → parts}/action.d.ts +5 -3
- package/x/core/parts/action.js +30 -0
- package/x/core/parts/action.js.map +1 -0
- package/x/core/parts/sample-map.d.ts +6 -0
- package/x/core/{bindings → parts}/sample-map.js +2 -3
- package/x/core/parts/sample-map.js.map +1 -0
- package/x/core/resolvers/actions.d.ts +2 -0
- package/x/core/resolvers/actions.js +23 -0
- package/x/core/resolvers/actions.js.map +1 -0
- package/x/core/resolvers/intents.d.ts +2 -0
- package/x/core/{bindings/resolver.js → resolvers/intents.js} +39 -43
- package/x/core/resolvers/intents.js.map +1 -0
- package/x/core/types.d.ts +43 -0
- package/x/core/types.js +2 -0
- package/x/core/types.js.map +1 -0
- package/x/deck/controller.d.ts +11 -0
- package/x/deck/controller.js +28 -0
- package/x/deck/controller.js.map +1 -0
- package/x/deck/deck.d.ts +30 -26
- package/x/deck/deck.js +64 -43
- package/x/deck/deck.js.map +1 -1
- package/x/deck/parts/profiles.d.ts +12 -0
- package/x/deck/parts/profiles.js +31 -0
- package/x/deck/parts/profiles.js.map +1 -0
- package/x/deck/parts/runtime.d.ts +8 -0
- package/x/deck/parts/runtime.js +7 -0
- package/x/deck/parts/runtime.js.map +1 -0
- package/x/deck/parts/settings.d.ts +11 -0
- package/x/deck/parts/settings.js +26 -0
- package/x/deck/parts/settings.js.map +1 -0
- package/x/deck/port.d.ts +10 -0
- package/x/deck/port.js +24 -0
- package/x/deck/port.js.map +1 -0
- package/x/deck/types.d.ts +11 -0
- package/x/deck/types.js +2 -0
- package/x/deck/types.js.map +1 -0
- package/x/demo/demo-app/element.d.ts +3 -0
- package/x/demo/demo-app/element.js +13 -0
- package/x/demo/demo-app/element.js.map +1 -0
- package/x/demo/demo-app/style.css.js +9 -0
- package/x/demo/demo-app/style.css.js.map +1 -0
- package/x/demo/main.bundle.js +53 -5
- package/x/demo/main.bundle.js.map +1 -1
- package/x/demo/main.bundle.min.js +107 -385
- package/x/demo/main.bundle.min.js.LEGAL.txt +33 -0
- package/x/demo/main.bundle.min.js.map +4 -4
- package/x/demo/main.css +6 -8
- package/x/device/devices.d.ts +7 -0
- package/x/device/devices.js +17 -0
- package/x/device/devices.js.map +1 -0
- package/x/device/gamepad.d.ts +9 -0
- package/x/device/gamepad.js +37 -0
- package/x/device/gamepad.js.map +1 -0
- package/x/{core/devices/standard → device}/keyboard.d.ts +1 -1
- package/x/{core/devices/standard → device}/keyboard.js +4 -2
- package/x/device/keyboard.js.map +1 -0
- package/x/device/pad/on-pad.d.ts +3 -0
- package/x/device/pad/on-pad.js +42 -0
- package/x/device/pad/on-pad.js.map +1 -0
- package/x/device/pad/pad.d.ts +6 -0
- package/x/device/pad/pad.js +11 -0
- package/x/device/pad/pad.js.map +1 -0
- package/x/{core/devices/standard → device}/pointer.d.ts +2 -2
- package/x/{core/devices/standard → device}/pointer.js +4 -4
- package/x/device/pointer.js.map +1 -0
- package/x/device/sampler.d.ts +9 -0
- package/x/device/sampler.js +19 -0
- package/x/device/sampler.js.map +1 -0
- package/x/{core/devices/standard → device}/stick.d.ts +2 -3
- package/x/{core/devices/standard → device}/stick.js +4 -6
- package/x/device/stick.js.map +1 -0
- package/x/gamepad/gamepad-app/element.d.ts +1 -0
- package/x/gamepad/gamepad-app/element.js +54 -0
- package/x/gamepad/gamepad-app/element.js.map +1 -0
- package/x/gamepad/gamepad-app/style.css.js +72 -0
- package/x/gamepad/gamepad-app/style.css.js.map +1 -0
- package/x/gamepad/index.html +35 -0
- package/x/gamepad/index.html.d.ts +2 -0
- package/x/gamepad/index.html.js +41 -0
- package/x/gamepad/index.html.js.map +1 -0
- package/x/gamepad/main.bundle.js +4 -0
- package/x/gamepad/main.bundle.js.map +1 -0
- package/x/gamepad/main.bundle.min.js +126 -0
- package/x/gamepad/main.bundle.min.js.LEGAL.txt +33 -0
- package/x/gamepad/main.bundle.min.js.map +7 -0
- package/x/gamepad/main.css +60 -0
- package/x/index-ui.d.ts +1 -0
- package/x/index-ui.js +2 -0
- package/x/index-ui.js.map +1 -0
- package/x/index.d.ts +27 -5
- package/x/index.html +17 -24
- package/x/index.html.js +10 -17
- package/x/index.html.js.map +1 -1
- package/x/index.js +27 -5
- package/x/index.js.map +1 -1
- package/x/test.d.ts +9 -0
- package/x/test.js +307 -0
- package/x/test.js.map +1 -0
- package/x/ui/views/desk/style.css.js +69 -0
- package/x/ui/views/desk/style.css.js.map +1 -0
- package/x/ui/views/desk/view.d.ts +7 -0
- package/x/ui/views/desk/view.js +102 -0
- package/x/ui/views/desk/view.js.map +1 -0
- package/x/utils/circular-clamp.js +2 -2
- package/x/utils/circular-clamp.js.map +1 -1
- package/x/utils/do-async.d.ts +1 -0
- package/x/utils/do-async.js +4 -0
- package/x/utils/do-async.js.map +1 -0
- package/x/utils/freeze-clone.d.ts +1 -0
- package/x/utils/freeze-clone.js +5 -0
- package/x/utils/freeze-clone.js.map +1 -0
- package/x/utils/identifier.d.ts +6 -0
- package/x/utils/identifier.js +25 -0
- package/x/utils/identifier.js.map +1 -0
- package/x/utils/insert.d.ts +1 -0
- package/x/utils/insert.js +5 -0
- package/x/utils/insert.js.map +1 -0
- package/x/utils/is-down.d.ts +1 -0
- package/x/utils/is-down.js +4 -0
- package/x/utils/is-down.js.map +1 -0
- package/x/utils/make-id.d.ts +1 -0
- package/x/utils/make-id.js +5 -0
- package/x/utils/make-id.js.map +1 -0
- package/x/utils/remap.d.ts +1 -0
- package/x/utils/remap.js +6 -0
- package/x/utils/remap.js.map +1 -0
- package/x/utils/shift-limit.d.ts +2 -0
- package/x/utils/shift-limit.js +7 -0
- package/x/utils/shift-limit.js.map +1 -0
- package/x/utils/sort-by-key.d.ts +1 -0
- package/x/utils/sort-by-key.js +6 -0
- package/x/utils/sort-by-key.js.map +1 -0
- package/x/utils/{quick-math.d.ts → tmax.d.ts} +0 -1
- package/x/utils/tmax.js +6 -0
- package/x/utils/tmax.js.map +1 -0
- package/x/utils/tmin.d.ts +1 -0
- package/x/utils/tmin.js +6 -0
- package/x/utils/tmin.js.map +1 -0
- package/s/tests.test.ts +0 -6
- package/x/core/bindings/action.js +0 -24
- package/x/core/bindings/action.js.map +0 -1
- package/x/core/bindings/parts/defaults.js.map +0 -1
- package/x/core/bindings/parts/is-pressed.d.ts +0 -1
- package/x/core/bindings/parts/is-pressed.js +0 -4
- package/x/core/bindings/parts/is-pressed.js.map +0 -1
- package/x/core/bindings/parts/lens-algo.js.map +0 -1
- package/x/core/bindings/parts/lookup-proxies.js +0 -19
- package/x/core/bindings/parts/lookup-proxies.js.map +0 -1
- package/x/core/bindings/resolver.d.ts +0 -9
- package/x/core/bindings/resolver.js.map +0 -1
- package/x/core/bindings/sample-map.d.ts +0 -7
- package/x/core/bindings/sample-map.js.map +0 -1
- package/x/core/bindings/types.js +0 -4
- package/x/core/bindings/types.js.map +0 -1
- package/x/core/core.test.d.ts +0 -13
- package/x/core/core.test.js +0 -138
- package/x/core/core.test.js.map +0 -1
- package/x/core/devices/auto-gamepads.d.ts +0 -2
- package/x/core/devices/auto-gamepads.js +0 -6
- package/x/core/devices/auto-gamepads.js.map +0 -1
- package/x/core/devices/device.d.ts +0 -5
- package/x/core/devices/device.js +0 -7
- package/x/core/devices/device.js.map +0 -1
- package/x/core/devices/infra/group.d.ts +0 -7
- package/x/core/devices/infra/group.js +0 -21
- package/x/core/devices/infra/group.js.map +0 -1
- package/x/core/devices/infra/sampler.d.ts +0 -9
- package/x/core/devices/infra/sampler.js +0 -18
- package/x/core/devices/infra/sampler.js.map +0 -1
- package/x/core/devices/standard/gamepad.d.ts +0 -11
- package/x/core/devices/standard/gamepad.js +0 -65
- package/x/core/devices/standard/gamepad.js.map +0 -1
- package/x/core/devices/standard/index.d.ts +0 -6
- package/x/core/devices/standard/index.js +0 -7
- package/x/core/devices/standard/index.js.map +0 -1
- package/x/core/devices/standard/keyboard.js.map +0 -1
- package/x/core/devices/standard/pointer.js.map +0 -1
- package/x/core/devices/standard/primary.d.ts +0 -10
- package/x/core/devices/standard/primary.js +0 -17
- package/x/core/devices/standard/primary.js.map +0 -1
- package/x/core/devices/standard/stick.js.map +0 -1
- package/x/core/devices/standard/vpad.d.ts +0 -7
- package/x/core/devices/standard/vpad.js +0 -20
- package/x/core/devices/standard/vpad.js.map +0 -1
- package/x/core/devices/types.d.ts +0 -1
- package/x/core/hub/hub.d.ts +0 -32
- package/x/core/hub/hub.js +0 -101
- package/x/core/hub/hub.js.map +0 -1
- package/x/core/hub/meta-bindings.d.ts +0 -2
- package/x/core/hub/meta-bindings.js +0 -21
- package/x/core/hub/meta-bindings.js.map +0 -1
- package/x/core/hub/parts/connected.d.ts +0 -14
- package/x/core/hub/parts/connected.js +0 -12
- package/x/core/hub/parts/connected.js.map +0 -1
- package/x/core/hub/port.d.ts +0 -9
- package/x/core/hub/port.js +0 -19
- package/x/core/hub/port.js.map +0 -1
- package/x/core/hub/types.d.ts +0 -9
- package/x/core/hub/types.js +0 -2
- package/x/core/hub/types.js.map +0 -1
- package/x/core/index.d.ts +0 -15
- package/x/core/index.js +0 -16
- package/x/core/index.js.map +0 -1
- package/x/core/testing/testing.d.ts +0 -52
- package/x/core/testing/testing.js +0 -45
- package/x/core/testing/testing.js.map +0 -1
- package/x/deck/index.d.ts +0 -9
- package/x/deck/index.js +0 -10
- package/x/deck/index.js.map +0 -1
- package/x/deck/parts/catalog.d.ts +0 -22
- package/x/deck/parts/catalog.js +0 -35
- package/x/deck/parts/catalog.js.map +0 -1
- package/x/deck/parts/db.d.ts +0 -17
- package/x/deck/parts/db.js +0 -52
- package/x/deck/parts/db.js.map +0 -1
- package/x/deck/parts/device-skins/device-icons.d.ts +0 -12
- package/x/deck/parts/device-skins/device-icons.js +0 -27
- package/x/deck/parts/device-skins/device-icons.js.map +0 -1
- package/x/deck/parts/device-skins/device-skin.d.ts +0 -14
- package/x/deck/parts/device-skins/device-skin.js +0 -22
- package/x/deck/parts/device-skins/device-skin.js.map +0 -1
- package/x/deck/parts/local-storage-kv.d.ts +0 -2
- package/x/deck/parts/local-storage-kv.js +0 -6
- package/x/deck/parts/local-storage-kv.js.map +0 -1
- package/x/deck/parts/merge-bindings.d.ts +0 -2
- package/x/deck/parts/merge-bindings.js +0 -15
- package/x/deck/parts/merge-bindings.js.map +0 -1
- package/x/deck/parts/overlay-visibility.d.ts +0 -18
- package/x/deck/parts/overlay-visibility.js +0 -35
- package/x/deck/parts/overlay-visibility.js.map +0 -1
- package/x/deck/views/bindings/style.css.js +0 -5
- package/x/deck/views/bindings/style.css.js.map +0 -1
- package/x/deck/views/bindings/view.d.ts +0 -2
- package/x/deck/views/bindings/view.js +0 -80
- package/x/deck/views/bindings/view.js.map +0 -1
- package/x/deck/views/overlay/style.css.js +0 -109
- package/x/deck/views/overlay/style.css.js.map +0 -1
- package/x/deck/views/overlay/view.d.ts +0 -2
- package/x/deck/views/overlay/view.js +0 -40
- package/x/deck/views/overlay/view.js.map +0 -1
- package/x/demo/game/game.d.ts +0 -17
- package/x/demo/game/game.js +0 -63
- package/x/demo/game/game.js.map +0 -1
- package/x/demo/game/parts/agent.d.ts +0 -7
- package/x/demo/game/parts/agent.js +0 -8
- package/x/demo/game/parts/agent.js.map +0 -1
- package/x/demo/game/parts/game-bindings.d.ts +0 -15
- package/x/demo/game/parts/game-bindings.js +0 -10
- package/x/demo/game/parts/game-bindings.js.map +0 -1
- package/x/demo/game/parts/logic.d.ts +0 -8
- package/x/demo/game/parts/logic.js +0 -21
- package/x/demo/game/parts/logic.js.map +0 -1
- package/x/demo/game/parts/player.d.ts +0 -14
- package/x/demo/game/parts/player.js +0 -26
- package/x/demo/game/parts/player.js.map +0 -1
- package/x/demo/game/parts/renderer.d.ts +0 -13
- package/x/demo/game/parts/renderer.js +0 -91
- package/x/demo/game/parts/renderer.js.map +0 -1
- package/x/demo/game/parts/state.d.ts +0 -8
- package/x/demo/game/parts/state.js +0 -20
- package/x/demo/game/parts/state.js.map +0 -1
- package/x/demo/game/parts/virtual-device.d.ts +0 -8
- package/x/demo/game/parts/virtual-device.js +0 -11
- package/x/demo/game/parts/virtual-device.js.map +0 -1
- package/x/demo/ui/theater/styles.css.d.ts +0 -1
- package/x/demo/ui/theater/styles.css.js +0 -57
- package/x/demo/ui/theater/styles.css.js.map +0 -1
- package/x/demo/ui/theater/view.d.ts +0 -2
- package/x/demo/ui/theater/view.js +0 -45
- package/x/demo/ui/theater/view.js.map +0 -1
- package/x/demo/ui/theater/virtual/style.css.js +0 -42
- package/x/demo/ui/theater/virtual/style.css.js.map +0 -1
- package/x/demo/ui/theater/virtual/view.d.ts +0 -4
- package/x/demo/ui/theater/virtual/view.js +0 -19
- package/x/demo/ui/theater/virtual/view.js.map +0 -1
- package/x/demo/ui/utils/loader.d.ts +0 -2
- package/x/demo/ui/utils/loader.js +0 -3
- package/x/demo/ui/utils/loader.js.map +0 -1
- package/x/nubs/index.d.ts +0 -3
- package/x/nubs/index.js +0 -4
- package/x/nubs/index.js.map +0 -1
- package/x/nubs/lookpad/styles.d.ts +0 -1
- package/x/nubs/lookpad/styles.js +0 -21
- package/x/nubs/lookpad/styles.js.map +0 -1
- package/x/nubs/lookpad/view.d.ts +0 -1
- package/x/nubs/lookpad/view.js +0 -33
- package/x/nubs/lookpad/view.js.map +0 -1
- package/x/nubs/stick/style.css.d.ts +0 -2
- package/x/nubs/stick/style.css.js +0 -69
- package/x/nubs/stick/style.css.js.map +0 -1
- package/x/nubs/stick/view.d.ts +0 -2
- package/x/nubs/stick/view.js +0 -95
- package/x/nubs/stick/view.js.map +0 -1
- package/x/nubs/vpad/styles.css.d.ts +0 -2
- package/x/nubs/vpad/styles.css.js +0 -133
- package/x/nubs/vpad/styles.css.js.map +0 -1
- package/x/nubs/vpad/utils/gamepad-inputs.d.ts +0 -29
- package/x/nubs/vpad/utils/gamepad-inputs.js +0 -31
- package/x/nubs/vpad/utils/gamepad-inputs.js.map +0 -1
- package/x/nubs/vpad/utils/prevent-default-touch-shenanigans.d.ts +0 -1
- package/x/nubs/vpad/utils/prevent-default-touch-shenanigans.js +0 -9
- package/x/nubs/vpad/utils/prevent-default-touch-shenanigans.js.map +0 -1
- package/x/nubs/vpad/utils/touch-tracking.d.ts +0 -6
- package/x/nubs/vpad/utils/touch-tracking.js +0 -55
- package/x/nubs/vpad/utils/touch-tracking.js.map +0 -1
- package/x/nubs/vpad/view.d.ts +0 -2
- package/x/nubs/vpad/view.js +0 -123
- package/x/nubs/vpad/view.js.map +0 -1
- package/x/tests.test.d.ts +0 -1
- package/x/tests.test.js +0 -4
- package/x/tests.test.js.map +0 -1
- package/x/utils/dispensers.d.ts +0 -7
- package/x/utils/dispensers.js +0 -16
- package/x/utils/dispensers.js.map +0 -1
- package/x/utils/gamepads.d.ts +0 -14
- package/x/utils/gamepads.js +0 -40
- package/x/utils/gamepads.js.map +0 -1
- package/x/utils/quick-math.js +0 -11
- package/x/utils/quick-math.js.map +0 -1
- /package/s/{core → _archive/core}/bindings/action.ts +0 -0
- /package/s/{core → _archive/core}/bindings/parts/defaults.ts +0 -0
- /package/s/{core → _archive/core}/bindings/parts/is-pressed.ts +0 -0
- /package/s/{core → _archive/core}/bindings/parts/lens-algo.ts +0 -0
- /package/s/{core → _archive/core}/bindings/parts/lookup-proxies.ts +0 -0
- /package/s/{core → _archive/core}/bindings/resolver.ts +0 -0
- /package/s/{core → _archive/core}/bindings/sample-map.ts +0 -0
- /package/s/{core → _archive/core}/bindings/types.ts +0 -0
- /package/s/{core → _archive/core}/core.test.ts +0 -0
- /package/s/{core → _archive/core}/devices/auto-gamepads.ts +0 -0
- /package/s/{core → _archive/core}/devices/device.ts +0 -0
- /package/s/{core → _archive/core}/devices/infra/group.ts +0 -0
- /package/s/{core → _archive/core}/devices/infra/sampler.ts +0 -0
- /package/s/{core → _archive/core}/devices/standard/gamepad.ts +0 -0
- /package/s/{core → _archive/core}/devices/standard/index.ts +0 -0
- /package/s/{core → _archive/core}/devices/standard/keyboard.ts +0 -0
- /package/s/{core → _archive/core}/devices/standard/pointer.ts +0 -0
- /package/s/{core → _archive/core}/devices/standard/primary.ts +0 -0
- /package/s/{core → _archive/core}/devices/standard/stick.ts +0 -0
- /package/s/{core → _archive/core}/devices/standard/vpad.ts +0 -0
- /package/s/{core → _archive/core}/devices/types.ts +0 -0
- /package/s/{core → _archive/core}/hub/hub.ts +0 -0
- /package/s/{core → _archive/core}/hub/meta-bindings.ts +0 -0
- /package/s/{core → _archive/core}/hub/parts/connected.ts +0 -0
- /package/s/{core → _archive/core}/hub/port.ts +0 -0
- /package/s/{core → _archive/core}/hub/types.ts +0 -0
- /package/s/{core → _archive/core}/index.ts +0 -0
- /package/s/{core → _archive/core}/testing/testing.ts +0 -0
- /package/s/{deck → _archive/deck}/index.ts +0 -0
- /package/s/{deck → _archive/deck}/parts/catalog.ts +0 -0
- /package/s/{deck → _archive/deck}/parts/db.ts +0 -0
- /package/s/{deck → _archive/deck}/parts/device-skins/device-icons.ts +0 -0
- /package/s/{deck → _archive/deck}/parts/device-skins/device-skin.ts +0 -0
- /package/s/{deck → _archive/deck}/parts/local-storage-kv.ts +0 -0
- /package/s/{deck → _archive/deck}/parts/merge-bindings.ts +0 -0
- /package/s/{deck → _archive/deck}/parts/overlay-visibility.ts +0 -0
- /package/s/{deck → _archive/deck}/views/bindings/style.css.ts +0 -0
- /package/s/{deck → _archive/deck}/views/bindings/view.ts +0 -0
- /package/s/{deck → _archive/deck}/views/overlay/style.css.ts +0 -0
- /package/s/{deck → _archive/deck}/views/overlay/view.ts +0 -0
- /package/s/{demo → _archive/demo}/game/game.ts +0 -0
- /package/s/{demo → _archive/demo}/game/parts/agent.ts +0 -0
- /package/s/{demo → _archive/demo}/game/parts/game-bindings.ts +0 -0
- /package/s/{demo → _archive/demo}/game/parts/logic.ts +0 -0
- /package/s/{demo → _archive/demo}/game/parts/player.ts +0 -0
- /package/s/{demo → _archive/demo}/game/parts/renderer.ts +0 -0
- /package/s/{demo → _archive/demo}/game/parts/state.ts +0 -0
- /package/s/{demo → _archive/demo}/game/parts/virtual-device.ts +0 -0
- /package/s/{demo → _archive/demo}/ui/theater/styles.css.ts +0 -0
- /package/s/{demo → _archive/demo}/ui/theater/view.ts +0 -0
- /package/s/{demo → _archive/demo}/ui/theater/virtual/style.css.ts +0 -0
- /package/s/{demo → _archive/demo}/ui/theater/virtual/view.ts +0 -0
- /package/s/{demo → _archive/demo}/ui/utils/loader.ts +0 -0
- /package/s/{nubs → _archive/nubs}/index.ts +0 -0
- /package/s/{nubs → _archive/nubs}/lookpad/styles.ts +0 -0
- /package/s/{nubs → _archive/nubs}/lookpad/view.ts +0 -0
- /package/s/{nubs → _archive/nubs}/stick/style.css.ts +0 -0
- /package/s/{nubs → _archive/nubs}/stick/view.ts +0 -0
- /package/s/{nubs → _archive/nubs}/vpad/styles.css.ts +0 -0
- /package/s/{nubs → _archive/nubs}/vpad/utils/gamepad-inputs.ts +0 -0
- /package/s/{nubs → _archive/nubs}/vpad/utils/prevent-default-touch-shenanigans.ts +0 -0
- /package/s/{nubs → _archive/nubs}/vpad/utils/touch-tracking.ts +0 -0
- /package/s/{nubs → _archive/nubs}/vpad/view.ts +0 -0
- /package/s/{utils → _archive/utils}/dispensers.ts +0 -0
- /package/s/{utils → _archive/utils}/gamepads.ts +0 -0
- /package/s/{utils → _archive/utils}/quick-math.ts +0 -0
- /package/x/core/{bindings/parts → atom}/defaults.js +0 -0
- /package/x/core/{devices → atom}/types.js +0 -0
- /package/x/{deck/views/bindings → demo/demo-app}/style.css.d.ts +0 -0
- /package/x/{deck/views/overlay → gamepad/gamepad-app}/style.css.d.ts +0 -0
- /package/x/{core/bindings/parts/lookup-proxies.d.ts → gamepad/main.bundle.d.ts} +0 -0
- /package/x/{demo/ui/theater/virtual → ui/views/desk}/style.css.d.ts +0 -0
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { Atom } from "./atom/types.js";
|
|
2
|
+
import { Action } from "./parts/action.js";
|
|
3
|
+
/** json-friendly description of how samples are interpreted */
|
|
4
|
+
export type Bindings = {
|
|
5
|
+
[mode: string]: {
|
|
6
|
+
[action: string]: Atom;
|
|
7
|
+
};
|
|
8
|
+
};
|
|
9
|
+
/** describes the shape of how bindings relate to the binds index (useful on serverside) */
|
|
10
|
+
export type BindingsShape<B extends Bindings> = {
|
|
11
|
+
[MK in keyof B]: {
|
|
12
|
+
[AK in keyof B[MK]]: number;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
/** integer-indexed flat map of bindings info (for efficient networking) */
|
|
16
|
+
export type BindingsTable<B extends Bindings> = Map<number, BindingsRow<B>>;
|
|
17
|
+
/** the binding for a single action */
|
|
18
|
+
export type BindingsRow<B extends Bindings> = {
|
|
19
|
+
id: number;
|
|
20
|
+
mode: keyof B;
|
|
21
|
+
action: keyof B[keyof B];
|
|
22
|
+
atom: Atom;
|
|
23
|
+
};
|
|
24
|
+
/** produces user input samples (eg, a keyboard produces samples) */
|
|
25
|
+
export type Device = {
|
|
26
|
+
samples(): Iterable<Sample>;
|
|
27
|
+
};
|
|
28
|
+
/** raw user input, eg, `["KeyW", 1]` */
|
|
29
|
+
export type Sample = [code: string, value: number];
|
|
30
|
+
/** efficiently express resolved values */
|
|
31
|
+
export type Intent = [id: number, value: number];
|
|
32
|
+
/** ergonomic access to user inputs (your app logic should read from this) */
|
|
33
|
+
export type Actions<B extends Bindings> = {
|
|
34
|
+
[M in keyof B]: {
|
|
35
|
+
[A in keyof B[M]]: Action;
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
export type AsBindings<B extends Bindings> = {
|
|
39
|
+
[MK in keyof B]: {
|
|
40
|
+
[AK in keyof B[MK]]: Atom;
|
|
41
|
+
};
|
|
42
|
+
};
|
|
43
|
+
export declare const asBindings: <B extends Bindings>(b: B) => AsBindings<B>;
|
package/x/core/types.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../s/core/types.ts"],"names":[],"mappings":"AAsCA,MAAM,CAAC,MAAM,UAAU,GAAG,CAAqB,CAAI,EAAE,EAAE,CAAE,CAAmB,CAAA"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Bindings, Device } from "../core/types.js";
|
|
2
|
+
/** associate a device with particular bindings */
|
|
3
|
+
export declare class Controller<B extends Bindings = Bindings, D extends Device = Device> {
|
|
4
|
+
#private;
|
|
5
|
+
readonly handle: string;
|
|
6
|
+
device: D;
|
|
7
|
+
constructor(handle: string, bindings: B, device: D);
|
|
8
|
+
get bindings(): B;
|
|
9
|
+
set bindings(bindings: B);
|
|
10
|
+
resolveIntents(now: number): import("../core/types.js").Intent[];
|
|
11
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { deep } from "@e280/stz";
|
|
2
|
+
import { makeIntentsResolver } from "../core/resolvers/intents.js";
|
|
3
|
+
/** associate a device with particular bindings */
|
|
4
|
+
export class Controller {
|
|
5
|
+
handle;
|
|
6
|
+
device;
|
|
7
|
+
#bindings;
|
|
8
|
+
#resolveIntents;
|
|
9
|
+
constructor(handle, bindings, device) {
|
|
10
|
+
this.handle = handle;
|
|
11
|
+
this.device = device;
|
|
12
|
+
this.#bindings = bindings;
|
|
13
|
+
this.#resolveIntents = makeIntentsResolver(bindings);
|
|
14
|
+
}
|
|
15
|
+
get bindings() {
|
|
16
|
+
return this.#bindings;
|
|
17
|
+
}
|
|
18
|
+
set bindings(bindings) {
|
|
19
|
+
if (!deep.equal(this.#bindings, bindings)) {
|
|
20
|
+
this.#bindings = bindings;
|
|
21
|
+
this.#resolveIntents = makeIntentsResolver(bindings);
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
resolveIntents(now) {
|
|
25
|
+
return this.#resolveIntents(now, this.device.samples());
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
//# sourceMappingURL=controller.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"controller.js","sourceRoot":"","sources":["../../s/deck/controller.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,IAAI,EAAC,MAAM,WAAW,CAAA;AAE9B,OAAO,EAAC,mBAAmB,EAAC,MAAM,8BAA8B,CAAA;AAEhE,kDAAkD;AAClD,MAAM,OAAO,UAAU;IAKX,MAAM;IAER,MAAM;IANf,SAAS,CAAG;IACZ,eAAe,CAAA;IAEf,YACW,MAAc,EACvB,QAAW,EACJ,MAAS;sBAFP,MAAM;sBAER,MAAM;QAEd,IAAI,CAAC,SAAS,GAAG,QAAQ,CAAA;QACzB,IAAI,CAAC,eAAe,GAAG,mBAAmB,CAAC,QAAQ,CAAC,CAAA;IACrD,CAAC;IAED,IAAI,QAAQ;QACX,OAAO,IAAI,CAAC,SAAS,CAAA;IACtB,CAAC;IAED,IAAI,QAAQ,CAAC,QAAW;QACvB,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,SAAS,EAAE,QAAQ,CAAC,EAAE,CAAC;YAC3C,IAAI,CAAC,SAAS,GAAG,QAAQ,CAAA;YACzB,IAAI,CAAC,eAAe,GAAG,mBAAmB,CAAC,QAAQ,CAAC,CAAA;QACrD,CAAC;IACF,CAAC;IAED,cAAc,CAAC,GAAW;QACzB,OAAO,IAAI,CAAC,eAAe,CAAC,GAAG,EAAE,IAAI,CAAC,MAAM,CAAC,OAAO,EAAE,CAAC,CAAA;IACxD,CAAC;CACD"}
|
package/x/deck/deck.d.ts
CHANGED
|
@@ -1,27 +1,31 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
1
|
+
import { Cubby } from "@e280/stz";
|
|
2
|
+
import { Port } from "./port.js";
|
|
3
|
+
import { Device } from "../core/types.js";
|
|
4
|
+
import { Controller } from "./controller.js";
|
|
5
|
+
import { Profiles } from "./parts/profiles.js";
|
|
6
|
+
import { Settings } from "./parts/settings.js";
|
|
7
|
+
import { DeckState, Profile, ProfileKey } from "./types.js";
|
|
8
|
+
export declare class Deck<StockProfileKey extends ProfileKey = ProfileKey> {
|
|
9
|
+
#private;
|
|
10
|
+
profiles: Profiles;
|
|
11
|
+
settings: Settings;
|
|
12
|
+
constructor(options: {
|
|
13
|
+
store: Cubby<DeckState>;
|
|
14
|
+
stockProfiles: Record<StockProfileKey, Profile>;
|
|
15
|
+
});
|
|
16
|
+
load(): Promise<void>;
|
|
17
|
+
get ports(): Port[];
|
|
18
|
+
get controllers(): Controller<import("../core/types.js").Bindings, Device>[];
|
|
19
|
+
get unassignedControllers(): Controller<import("../core/types.js").Bindings, Device>[];
|
|
20
|
+
createPort(): Port;
|
|
21
|
+
deletePort(port: Port): void;
|
|
22
|
+
createController<D extends Device = Device>(handle: string, stockProfileKey: StockProfileKey, device: D): Controller<import("../core/types.js").Bindings, D>;
|
|
23
|
+
deleteController(controller: Controller): void;
|
|
24
|
+
assignControllerProfile(controller: Controller, profileKey: StockProfileKey | ProfileKey): Promise<void>;
|
|
25
|
+
queryController(controller: Controller): {
|
|
26
|
+
controller: Controller<import("../core/types.js").Bindings, Device>;
|
|
27
|
+
port: Port | undefined;
|
|
28
|
+
profileKey: string | undefined;
|
|
29
|
+
profile: Profile;
|
|
30
|
+
};
|
|
27
31
|
}
|
package/x/deck/deck.js
CHANGED
|
@@ -1,47 +1,68 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import { makeMetaBindings } from "../core/hub/meta-bindings.js";
|
|
8
|
-
import { DeviceSkins } from "./parts/device-skins/device-skin.js";
|
|
9
|
-
import { OverlayVisibility } from "./parts/overlay-visibility.js";
|
|
10
|
-
import { PrimaryDevice } from "../core/devices/standard/primary.js";
|
|
1
|
+
import { debounce, guarantee } from "@e280/stz";
|
|
2
|
+
import { Port } from "./port.js";
|
|
3
|
+
import { Runtime } from "./parts/runtime.js";
|
|
4
|
+
import { Controller } from "./controller.js";
|
|
5
|
+
import { Profiles } from "./parts/profiles.js";
|
|
6
|
+
import { Settings } from "./parts/settings.js";
|
|
11
7
|
export class Deck {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
this.
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
8
|
+
profiles;
|
|
9
|
+
settings;
|
|
10
|
+
#runtime = new Runtime();
|
|
11
|
+
constructor(options) {
|
|
12
|
+
this.settings = new Settings(options.store);
|
|
13
|
+
this.profiles = new Profiles(options.stockProfiles, this.settings.customProfiles);
|
|
14
|
+
}
|
|
15
|
+
async load() {
|
|
16
|
+
await this.settings.load();
|
|
17
|
+
for (const controller of this.#runtime.controllers.keys())
|
|
18
|
+
this.#applyControllerProfile(controller);
|
|
19
|
+
}
|
|
20
|
+
#save = debounce(100, () => this.settings.save());
|
|
21
|
+
get ports() {
|
|
22
|
+
return [...this.#runtime.ports];
|
|
23
|
+
}
|
|
24
|
+
get controllers() {
|
|
25
|
+
return [...this.#runtime.controllers];
|
|
26
|
+
}
|
|
27
|
+
get unassignedControllers() {
|
|
28
|
+
return [...this.#runtime.controllers]
|
|
29
|
+
.filter(controller => !this.#runtime.portAssignments.get(controller));
|
|
30
|
+
}
|
|
31
|
+
createPort() {
|
|
32
|
+
const port = new Port(this.#runtime);
|
|
33
|
+
this.#runtime.ports.add(port);
|
|
34
|
+
return port;
|
|
35
|
+
}
|
|
36
|
+
deletePort(port) {
|
|
37
|
+
for (const controller of port.controllers)
|
|
38
|
+
port.unplug(controller);
|
|
39
|
+
this.#runtime.ports.delete(port);
|
|
40
|
+
}
|
|
41
|
+
createController(handle, stockProfileKey, device) {
|
|
42
|
+
const profileKey = guarantee(this.settings.profileAssignments, handle, () => stockProfileKey);
|
|
43
|
+
const profile = this.profiles.get(profileKey);
|
|
44
|
+
const controller = new Controller(handle, profile.bindings, device);
|
|
45
|
+
this.#runtime.controllers.add(controller);
|
|
46
|
+
return controller;
|
|
47
|
+
}
|
|
48
|
+
deleteController(controller) {
|
|
49
|
+
this.#runtime.controllers.delete(controller);
|
|
50
|
+
this.#runtime.portAssignments.delete(controller);
|
|
51
|
+
}
|
|
52
|
+
async assignControllerProfile(controller, profileKey) {
|
|
53
|
+
this.settings.profileAssignments.set(controller.handle, profileKey);
|
|
54
|
+
this.#applyControllerProfile(controller);
|
|
55
|
+
await this.#save();
|
|
56
|
+
}
|
|
57
|
+
queryController(controller) {
|
|
58
|
+
const port = this.#runtime.portAssignments.get(controller);
|
|
59
|
+
const profileKey = this.settings.profileAssignments.get(controller.handle);
|
|
60
|
+
const profile = this.profiles.get(profileKey);
|
|
61
|
+
return { controller, port, profileKey, profile };
|
|
62
|
+
}
|
|
63
|
+
#applyControllerProfile(controller) {
|
|
64
|
+
const profileKey = this.settings.profileAssignments.get(controller.handle);
|
|
65
|
+
controller.bindings = this.profiles.get(profileKey).bindings;
|
|
45
66
|
}
|
|
46
67
|
}
|
|
47
68
|
//# sourceMappingURL=deck.js.map
|
package/x/deck/deck.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deck.js","sourceRoot":"","sources":["../../s/deck/deck.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"deck.js","sourceRoot":"","sources":["../../s/deck/deck.ts"],"names":[],"mappings":"AACA,OAAO,EAAQ,QAAQ,EAAE,SAAS,EAAC,MAAM,WAAW,CAAA;AACpD,OAAO,EAAC,IAAI,EAAC,MAAM,WAAW,CAAA;AAE9B,OAAO,EAAC,OAAO,EAAC,MAAM,oBAAoB,CAAA;AAC1C,OAAO,EAAC,UAAU,EAAC,MAAM,iBAAiB,CAAA;AAC1C,OAAO,EAAC,QAAQ,EAAC,MAAM,qBAAqB,CAAA;AAC5C,OAAO,EAAC,QAAQ,EAAC,MAAM,qBAAqB,CAAA;AAG5C,MAAM,OAAO,IAAI;IAChB,QAAQ,CAAA;IACR,QAAQ,CAAA;IACR,QAAQ,GAAG,IAAI,OAAO,EAAE,CAAA;IAExB,YAAY,OAGV;QACD,IAAI,CAAC,QAAQ,GAAG,IAAI,QAAQ,CAAC,OAAO,CAAC,KAAK,CAAC,CAAA;QAC3C,IAAI,CAAC,QAAQ,GAAG,IAAI,QAAQ,CAAC,OAAO,CAAC,aAAa,EAAE,IAAI,CAAC,QAAQ,CAAC,cAAc,CAAC,CAAA;IAClF,CAAC;IAED,KAAK,CAAC,IAAI;QACT,MAAM,IAAI,CAAC,QAAQ,CAAC,IAAI,EAAE,CAAA;QAC1B,KAAK,MAAM,UAAU,IAAI,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC,IAAI,EAAE;YACxD,IAAI,CAAC,uBAAuB,CAAC,UAAU,CAAC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IAC7D,CAAC;CACD"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { RMap } from "@e280/strata";
|
|
2
|
+
import { Profile, ProfileKey } from "../types.js";
|
|
3
|
+
export declare class Profiles {
|
|
4
|
+
custom: RMap<ProfileKey, Profile>;
|
|
5
|
+
stock: RMap<string, Profile>;
|
|
6
|
+
constructor(stock: Record<ProfileKey, Profile>, custom: RMap<ProfileKey, Profile>);
|
|
7
|
+
get all(): [string, Profile][];
|
|
8
|
+
normalizeKey(key?: ProfileKey): string;
|
|
9
|
+
get defaultId(): string;
|
|
10
|
+
get(key?: ProfileKey): Profile;
|
|
11
|
+
need(key: ProfileKey): Profile;
|
|
12
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { RMap } from "@e280/strata";
|
|
2
|
+
import { inserts, need } from "@e280/stz";
|
|
3
|
+
export class Profiles {
|
|
4
|
+
custom;
|
|
5
|
+
stock;
|
|
6
|
+
constructor(stock, custom) {
|
|
7
|
+
this.custom = custom;
|
|
8
|
+
this.stock = new RMap();
|
|
9
|
+
inserts(this.stock, Object.entries(stock));
|
|
10
|
+
if (this.stock.size === 0)
|
|
11
|
+
throw new Error("must be at least one stock profile");
|
|
12
|
+
}
|
|
13
|
+
get all() {
|
|
14
|
+
return [...this.stock, ...this.custom];
|
|
15
|
+
}
|
|
16
|
+
normalizeKey(key) {
|
|
17
|
+
return key && (this.stock.has(key) || this.custom.has(key))
|
|
18
|
+
? key
|
|
19
|
+
: this.defaultId;
|
|
20
|
+
}
|
|
21
|
+
get defaultId() {
|
|
22
|
+
return [...this.stock.keys()][0];
|
|
23
|
+
}
|
|
24
|
+
get(key) {
|
|
25
|
+
return this.need(this.normalizeKey(key));
|
|
26
|
+
}
|
|
27
|
+
need(key) {
|
|
28
|
+
return this.stock.get(key) ?? need(this.custom, key);
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
//# sourceMappingURL=profiles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
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,IAAI,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IACrD,CAAC;CACD"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { RMap, RSet } from "@e280/strata";
|
|
2
|
+
import { Port } from "../port.js";
|
|
3
|
+
import { Controller } from "../controller.js";
|
|
4
|
+
export declare class Runtime {
|
|
5
|
+
ports: RSet<Port>;
|
|
6
|
+
controllers: RSet<Controller<import("../../index.js").Bindings, import("../../index.js").Device>>;
|
|
7
|
+
portAssignments: RMap<Controller<import("../../index.js").Bindings, import("../../index.js").Device>, Port | undefined>;
|
|
8
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runtime.js","sourceRoot":"","sources":["../../../s/deck/parts/runtime.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,IAAI,EAAE,IAAI,EAAC,MAAM,cAAc,CAAA;AAIvC,MAAM,OAAO,OAAO;IACnB,KAAK,GAAG,IAAI,IAAI,EAAQ,CAAA;IACxB,WAAW,GAAG,IAAI,IAAI,EAAc,CAAA;IACpC,eAAe,GAAG,IAAI,IAAI,EAAgC,CAAA;CAC1D"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { RMap } from "@e280/strata";
|
|
2
|
+
import { Cubby } from "@e280/stz";
|
|
3
|
+
import { DeckState, Profile } from "../types.js";
|
|
4
|
+
export declare class Settings {
|
|
5
|
+
private store;
|
|
6
|
+
profileAssignments: RMap<string, string>;
|
|
7
|
+
customProfiles: RMap<string, Profile>;
|
|
8
|
+
constructor(store: Cubby<DeckState>);
|
|
9
|
+
save(): Promise<void>;
|
|
10
|
+
load(): Promise<void>;
|
|
11
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { RMap } from "@e280/strata";
|
|
2
|
+
import { inserts } from "@e280/stz";
|
|
3
|
+
import { shiftLimit } from "../../utils/shift-limit.js";
|
|
4
|
+
const limit = 256;
|
|
5
|
+
export class Settings {
|
|
6
|
+
store;
|
|
7
|
+
profileAssignments = new RMap();
|
|
8
|
+
customProfiles = new RMap();
|
|
9
|
+
constructor(store) {
|
|
10
|
+
this.store = store;
|
|
11
|
+
}
|
|
12
|
+
async save() {
|
|
13
|
+
await this.store.set({
|
|
14
|
+
customProfiles: shiftLimit(limit, [...this.customProfiles]),
|
|
15
|
+
profileAssignments: shiftLimit(limit, [...this.profileAssignments]),
|
|
16
|
+
});
|
|
17
|
+
}
|
|
18
|
+
async load() {
|
|
19
|
+
const state = await this.store.get();
|
|
20
|
+
this.customProfiles.clear();
|
|
21
|
+
this.profileAssignments.clear();
|
|
22
|
+
inserts(this.customProfiles, state?.customProfiles ?? []);
|
|
23
|
+
inserts(this.profileAssignments, state?.profileAssignments ?? []);
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=settings.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"settings.js","sourceRoot":"","sources":["../../../s/deck/parts/settings.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,IAAI,EAAC,MAAM,cAAc,CAAA;AACjC,OAAO,EAAQ,OAAO,EAAC,MAAM,WAAW,CAAA;AACxC,OAAO,EAAC,UAAU,EAAC,MAAM,4BAA4B,CAAA;AAGrD,MAAM,KAAK,GAAG,GAAG,CAAA;AAEjB,MAAM,OAAO,QAAQ;IAIA,KAAK;IAHzB,kBAAkB,GAAG,IAAI,IAAI,EAAgC,CAAA;IAC7D,cAAc,GAAG,IAAI,IAAI,EAAuB,CAAA;IAEhD,YAAoB,KAAuB;qBAAvB,KAAK;IAAqB,CAAC;IAE/C,KAAK,CAAC,IAAI;QACT,MAAM,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC;YACpB,cAAc,EAAE,UAAU,CAAC,KAAK,EAAE,CAAC,GAAG,IAAI,CAAC,cAAc,CAAC,CAAC;YAC3D,kBAAkB,EAAE,UAAU,CAAC,KAAK,EAAE,CAAC,GAAG,IAAI,CAAC,kBAAkB,CAAC,CAAC;SACnE,CAAC,CAAA;IACH,CAAC;IAED,KAAK,CAAC,IAAI;QACT,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,GAAG,EAAE,CAAA;QACpC,IAAI,CAAC,cAAc,CAAC,KAAK,EAAE,CAAA;QAC3B,IAAI,CAAC,kBAAkB,CAAC,KAAK,EAAE,CAAA;QAC/B,OAAO,CAAC,IAAI,CAAC,cAAc,EAAE,KAAK,EAAE,cAAc,IAAI,EAAE,CAAC,CAAA;QACzD,OAAO,CAAC,IAAI,CAAC,kBAAkB,EAAE,KAAK,EAAE,kBAAkB,IAAI,EAAE,CAAC,CAAA;IAClE,CAAC;CACD"}
|
package/x/deck/port.d.ts
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Runtime } from "./parts/runtime.js";
|
|
2
|
+
import { Controller } from "./controller.js";
|
|
3
|
+
export declare class Port {
|
|
4
|
+
#private;
|
|
5
|
+
constructor(runtime: Runtime);
|
|
6
|
+
get controllers(): Controller<import("../index.js").Bindings, import("../index.js").Device>[];
|
|
7
|
+
plug(controller: Controller): void;
|
|
8
|
+
unplug(controller: Controller): void;
|
|
9
|
+
resolveIntents(now: number): import("../index.js").Intent[];
|
|
10
|
+
}
|
package/x/deck/port.js
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { derived } from "@e280/strata";
|
|
2
|
+
export class Port {
|
|
3
|
+
#runtime;
|
|
4
|
+
#controllers;
|
|
5
|
+
constructor(runtime) {
|
|
6
|
+
this.#runtime = runtime;
|
|
7
|
+
this.#controllers = derived(() => [...this.#runtime.controllers]
|
|
8
|
+
.filter(controller => this.#runtime.portAssignments.get(controller) === this));
|
|
9
|
+
}
|
|
10
|
+
get controllers() {
|
|
11
|
+
return this.#controllers();
|
|
12
|
+
}
|
|
13
|
+
plug(controller) {
|
|
14
|
+
this.#runtime.portAssignments.set(controller, this);
|
|
15
|
+
}
|
|
16
|
+
unplug(controller) {
|
|
17
|
+
this.#runtime.portAssignments.delete(controller);
|
|
18
|
+
}
|
|
19
|
+
resolveIntents(now) {
|
|
20
|
+
return this.controllers
|
|
21
|
+
.flatMap(controller => controller.resolveIntents(now));
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
//# sourceMappingURL=port.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"port.js","sourceRoot":"","sources":["../../s/deck/port.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,OAAO,EAAC,MAAM,cAAc,CAAA;AAIpC,MAAM,OAAO,IAAI;IAChB,QAAQ,CAAA;IACR,YAAY,CAAA;IAEZ,YAAY,OAAgB;QAC3B,IAAI,CAAC,QAAQ,GAAG,OAAO,CAAA;QACvB,IAAI,CAAC,YAAY,GAAG,OAAO,CAC1B,GAAG,EAAE,CAAC,CAAC,GAAG,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC;aAClC,MAAM,CAAC,UAAU,CAAC,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,eAAe,CAAC,GAAG,CAAC,UAAU,CAAC,KAAK,IAAI,CAAC,CAC9E,CAAA;IACF,CAAC;IAED,IAAI,WAAW;QACd,OAAO,IAAI,CAAC,YAAY,EAAE,CAAA;IAC3B,CAAC;IAED,IAAI,CAAC,UAAsB;QAC1B,IAAI,CAAC,QAAQ,CAAC,eAAe,CAAC,GAAG,CAAC,UAAU,EAAE,IAAI,CAAC,CAAA;IACpD,CAAC;IAED,MAAM,CAAC,UAAsB;QAC5B,IAAI,CAAC,QAAQ,CAAC,eAAe,CAAC,MAAM,CAAC,UAAU,CAAC,CAAA;IACjD,CAAC;IAED,cAAc,CAAC,GAAW;QACzB,OAAO,IAAI,CAAC,WAAW;aACrB,OAAO,CAAC,UAAU,CAAC,EAAE,CAAC,UAAU,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC,CAAA;IACxD,CAAC;CACD"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Bindings } from "../core/types.js";
|
|
2
|
+
export type ProfileKey = string;
|
|
3
|
+
export type ControllerHandle = string;
|
|
4
|
+
export type Profile = {
|
|
5
|
+
label: string;
|
|
6
|
+
bindings: Bindings;
|
|
7
|
+
};
|
|
8
|
+
export type DeckState = {
|
|
9
|
+
customProfiles: [key: ProfileKey, profile: Profile][];
|
|
10
|
+
profileAssignments: [handle: ControllerHandle, key: ProfileKey][];
|
|
11
|
+
};
|
package/x/deck/types.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../s/deck/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
import { shadowElement, useCss } from "@e280/sly";
|
|
3
|
+
import styleCss from "./style.css.js";
|
|
4
|
+
import { DeskView } from "../../ui/views/desk/view.js";
|
|
5
|
+
export const setupDemoApp = (deck, options = {}) => shadowElement(() => {
|
|
6
|
+
useCss(styleCss);
|
|
7
|
+
return html `
|
|
8
|
+
<div class=plate>
|
|
9
|
+
${DeskView(deck, options)}
|
|
10
|
+
</div>
|
|
11
|
+
`;
|
|
12
|
+
});
|
|
13
|
+
//# sourceMappingURL=element.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"element.js","sourceRoot":"","sources":["../../../s/demo/demo-app/element.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,IAAI,EAAC,MAAM,KAAK,CAAA;AACxB,OAAO,EAAC,aAAa,EAAE,MAAM,EAAC,MAAM,WAAW,CAAA;AAC/C,OAAO,QAAQ,MAAM,gBAAgB,CAAA;AAErC,OAAO,EAAc,QAAQ,EAAC,MAAM,6BAA6B,CAAA;AAEjE,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,IAAU,EAAE,OAAO,GAAgB,EAAE,EAAE,EAAE,CAAC,aAAa,CAAC,GAAG,EAAE;IACzF,MAAM,CAAC,QAAQ,CAAC,CAAA;IAEhB,OAAO,IAAI,CAAA;;KAEP,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;;EAE1B,CAAA;AACF,CAAC,CAAC,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"style.css.js","sourceRoot":"","sources":["../../../s/demo/demo-app/style.css.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,GAAG,EAAC,MAAM,KAAK,CAAA;AACvB,eAAe,GAAG,CAAA;;;;;;CAMjB,CAAA"}
|
package/x/demo/main.bundle.js
CHANGED
|
@@ -1,7 +1,55 @@
|
|
|
1
1
|
import { dom } from "@e280/sly";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
2
|
+
import { LocalStore } from "@e280/strata";
|
|
3
|
+
import { Deck } from "../deck/deck.js";
|
|
4
|
+
import { asBindings } from "../core/types.js";
|
|
5
|
+
import { Devices } from "../device/devices.js";
|
|
6
|
+
import { onPad } from "../device/pad/on-pad.js";
|
|
7
|
+
import { PointerDevice } from "../device/pointer.js";
|
|
8
|
+
import { GamepadDevice } from "../device/gamepad.js";
|
|
9
|
+
import { setupDemoApp } from "./demo-app/element.js";
|
|
10
|
+
import { KeyboardDevice } from "../device/keyboard.js";
|
|
11
|
+
const bindings = asBindings({
|
|
12
|
+
play: {
|
|
13
|
+
action: ["or", "Space", "pointer.button.left", "gamepad.button.1"],
|
|
14
|
+
up: ["or", "KeyW", "gamepad.axis.2.pos"],
|
|
15
|
+
down: ["or", "KeyS", "gamepad.axis.2.neg"],
|
|
16
|
+
left: ["or", "KeyA", "gamepad.axis.1.pos"],
|
|
17
|
+
right: ["or", "KeyD", "gamepad.axis.1.neg"],
|
|
18
|
+
},
|
|
19
|
+
});
|
|
20
|
+
const store = new LocalStore("tactDeck");
|
|
21
|
+
const deck = new Deck({
|
|
22
|
+
store,
|
|
23
|
+
stockProfiles: {
|
|
24
|
+
standard: { label: "📜standard", bindings },
|
|
25
|
+
micro: { label: "🦠micro", bindings: asBindings({
|
|
26
|
+
play: {
|
|
27
|
+
action: ["or", "Space", "pointer.button.left", "gamepad.button.1"],
|
|
28
|
+
up: ["or", "KeyW", "gamepad.axis.2.pos"],
|
|
29
|
+
down: ["or", "KeyS", "gamepad.axis.2.neg"],
|
|
30
|
+
left: ["or", "KeyA", "gamepad.axis.1.pos"],
|
|
31
|
+
right: ["or", "KeyD", "gamepad.axis.1.neg"],
|
|
32
|
+
},
|
|
33
|
+
}) },
|
|
34
|
+
},
|
|
35
|
+
});
|
|
36
|
+
await deck.load();
|
|
37
|
+
store.onStorageEvent(() => deck.load());
|
|
38
|
+
const port = deck.createPort();
|
|
39
|
+
const controller = deck.createController("primary", "standard", new Devices(new KeyboardDevice(), new PointerDevice()));
|
|
40
|
+
port.plug(controller);
|
|
41
|
+
const labels = new Map()
|
|
42
|
+
.set(controller, "⌨️🖱keyboard+mouse");
|
|
43
|
+
onPad(pad => {
|
|
44
|
+
const handle = `(${pad.gamepad.index + 1}) ${pad.gamepad.id}`;
|
|
45
|
+
const controller = deck.createController(handle, "standard", new GamepadDevice(pad));
|
|
46
|
+
labels.set(controller, `🎮${handle}`);
|
|
47
|
+
port.plug(controller);
|
|
48
|
+
return () => deck.deleteController(controller);
|
|
49
|
+
});
|
|
50
|
+
dom.register({
|
|
51
|
+
DemoApp: setupDemoApp(deck, {
|
|
52
|
+
getControllerLabel: labels.get.bind(labels),
|
|
53
|
+
}),
|
|
54
|
+
});
|
|
7
55
|
//# sourceMappingURL=main.bundle.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"main.bundle.js","sourceRoot":"","sources":["../../s/demo/main.bundle.ts"],"names":[],"mappings":"AACA,OAAO,
|
|
1
|
+
{"version":3,"file":"main.bundle.js","sourceRoot":"","sources":["../../s/demo/main.bundle.ts"],"names":[],"mappings":"AACA,OAAO,EAAU,GAAG,EAAC,MAAM,WAAW,CAAA;AACtC,OAAO,EAAC,UAAU,EAAC,MAAM,cAAc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