@omnipad/core 0.5.0 → 0.6.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.
Files changed (45) hide show
  1. package/dist/chunk-42WBUPM3.cjs +1 -0
  2. package/dist/chunk-45F3BQT7.cjs +1 -0
  3. package/dist/chunk-52YF3VHH.cjs +1 -0
  4. package/dist/chunk-6XY2ZHZ3.mjs +1 -0
  5. package/dist/chunk-AK3RL7NL.mjs +1 -0
  6. package/dist/chunk-EYKCVOUA.mjs +1 -0
  7. package/dist/chunk-HCOFKHVV.cjs +1 -0
  8. package/dist/chunk-HQNUZXP5.mjs +1 -0
  9. package/dist/chunk-J5SVBM6K.mjs +1 -0
  10. package/dist/chunk-NB4FTDOP.cjs +1 -0
  11. package/dist/chunk-OVV5DKL6.cjs +1 -0
  12. package/dist/chunk-YAS6LFBF.mjs +1 -0
  13. package/dist/dom/index.cjs +1 -1
  14. package/dist/dom/index.d.cts +105 -36
  15. package/dist/dom/index.d.ts +105 -36
  16. package/dist/dom/index.mjs +1 -1
  17. package/dist/guest/index.cjs +1 -0
  18. package/dist/guest/index.d.cts +21 -0
  19. package/dist/guest/index.d.ts +21 -0
  20. package/dist/guest/index.mjs +1 -0
  21. package/dist/{index-DVegtw8s.d.cts → index-Dd0aHJaA.d.cts} +739 -27
  22. package/dist/{index-DVegtw8s.d.ts → index-Dd0aHJaA.d.ts} +739 -27
  23. package/dist/index.cjs +1 -1
  24. package/dist/index.d.cts +312 -5
  25. package/dist/index.d.ts +312 -5
  26. package/dist/index.mjs +1 -1
  27. package/dist/sticky-CCj0ECTY.d.cts +285 -0
  28. package/dist/sticky-d_z_GU83.d.ts +285 -0
  29. package/dist/utils/index.cjs +1 -1
  30. package/dist/utils/index.d.cts +122 -69
  31. package/dist/utils/index.d.ts +122 -69
  32. package/dist/utils/index.mjs +1 -1
  33. package/package.json +9 -1
  34. package/dist/chunk-FSJTQU4W.cjs +0 -1
  35. package/dist/chunk-MKVX5ALC.mjs +0 -1
  36. package/dist/chunk-PACTGVBB.mjs +0 -1
  37. package/dist/chunk-U52W5J3K.cjs +0 -1
  38. package/dist/chunk-V7AHGFPB.mjs +0 -1
  39. package/dist/chunk-VHF3K5X6.cjs +0 -1
  40. package/dist/chunk-ZHPNS73J.cjs +0 -1
  41. package/dist/chunk-ZM2LX5IW.mjs +0 -1
  42. package/dist/sticky-4yk5DLzG.d.cts +0 -59
  43. package/dist/sticky-CLBq1EPa.d.ts +0 -59
  44. package/dist/traits-D6ePqSA6.d.cts +0 -152
  45. package/dist/traits-dAndzyWS.d.ts +0 -152
package/dist/index.d.ts CHANGED
@@ -1,7 +1,37 @@
1
- import { I as InputActionSignal, V as Vec2, E as EntityType, A as AbstractRect, B as ButtonConfig, a as AbstractPointerEvent, D as DPadConfig, b as InputZoneConfig, c as AnyFunction, J as JoystickConfig, d as BaseConfig, T as TargetZoneConfig, e as TrackpadConfig } from './index-DVegtw8s.js';
2
- export { f as ACTION_TYPES, g as ActionMapping, h as AnchorPoint, i as AnyConfig, j as AnyEntityType, k as BuiltInActionType, C as CMP_TYPES, l as CONTEXT, m as ConfigTreeNode, n as CssUnit, F as FlatConfigItem, o as FlexibleLength, G as GamepadMappingConfig, p as InputActionType, K as KEYS, q as KeyMapping, L as LayoutBox, O as OmniPadProfile, P as ParsedLength, S as StageId, r as StandardButton, s as VALID_UNITS, W as WidgetId, t as WidgetType, Z as ZoneId, u as ZoneType } from './index-DVegtw8s.js';
3
- import { I as ICoreEntity, a as ISpatial, b as IResettable, c as IConfigurable, d as IStateful, e as IPointerHandler, f as IProgrammatic, g as IDependencyBindable, h as ISignalReceiver } from './traits-dAndzyWS.js';
4
- export { i as IIdentifiable, j as ILifecycle } from './traits-dAndzyWS.js';
1
+ import { I as InputActionSignal, V as Vec2, A as AnyFunction, C as ConfigTreeNode, B as BaseConfig, E as EntityType, a as AbstractRect, O as OmniPadProfile, G as GamepadMappingConfig, b as ButtonConfig, c as AbstractPointerEvent, D as DPadConfig, d as InputZoneConfig, J as JoystickConfig, T as TargetZoneConfig, e as TrackpadConfig } from './index-Dd0aHJaA.js';
2
+ export { f as ACTION_TYPES, g as ActionMapping, h as AnchorPoint, i as AnyConfig, j as AnyEntityType, k as BuiltInActionType, l as CMP_TYPES, m as CONTEXT, n as CssUnit, F as FlatConfigItem, o as FlexibleLength, p as InputActionType, K as KEYS, q as KeyMapping, L as LayoutBox, P as ParsedLength, S as StageId, r as StandardButton, s as VALID_UNITS, W as WidgetId, t as WidgetType, Z as ZoneId, u as ZoneType } from './index-Dd0aHJaA.js';
3
+ import { I as ICoreEntity, a as IElementObserver, S as StickyProvider, b as ISpatial, c as IResettable, d as IConfigurable, e as IStateful, f as IPointerHandler, g as IProgrammatic, h as IDependencyBindable, i as ISignalReceiver } from './sticky-d_z_GU83.js';
4
+ export { j as IIdentifiable, k as ILifecycle, l as StickyController } from './sticky-d_z_GU83.js';
5
+
6
+ /**
7
+ * A unique signature used to identify and verify that messages received via
8
+ * window.postMessage originate from the OmniPad system.
9
+ */
10
+ declare const OMNIPAD_IPC_SIGNATURE = "__OMNIPAD_IPC_V1__";
11
+ /**
12
+ * Represents the structure of a data packet used for Inter-Process Communication (IPC)
13
+ * between the Host (main window) and the Guest (iframe).
14
+ */
15
+ interface IpcMessage {
16
+ /** Verification string to filter out external third-party messages */
17
+ signature: typeof OMNIPAD_IPC_SIGNATURE;
18
+ /**
19
+ * The broad category of the input event.
20
+ * Distinguishes between spatial interactions and discrete key signals.
21
+ */
22
+ type: 'pointer' | 'keyboard';
23
+ /**
24
+ * The specific event action name.
25
+ * Corresponds to standard browser event types like 'pointerdown', 'mousemove', 'keydown', etc.
26
+ */
27
+ action: string;
28
+ /**
29
+ * The data payload for the event.
30
+ * For 'pointer' type: Contains relative coordinates {x, y} and event options.
31
+ * For 'keyboard' type: Contains key mapping data {key, code, keyCode}.
32
+ */
33
+ payload: any;
34
+ }
5
35
 
6
36
  /**
7
37
  * Interface for the global Registry singleton.
@@ -172,6 +202,168 @@ interface DPadState extends InteractionState, AxisLogicState {
172
202
  interface JoystickState extends InteractionState, AxisLogicState, ButtonLogicState {
173
203
  }
174
204
 
205
+ /**
206
+ * Binds a map of delegate functions to a core entity instance.
207
+ *
208
+ * @param entity - The target entity instance.
209
+ * @param delegates - A key-value map of functions to bind.
210
+ */
211
+ declare function bindEntityDelegates(entity: any, delegates?: Record<string, AnyFunction>): void;
212
+ /**
213
+ * Orchestrates environment-agnostic spatial and visibility logic for an entity.
214
+ *
215
+ * @template T - The type of the physical element (e.g., HTMLElement, Element).
216
+ * @param entity - The logic core entity instance (must implement ICoreEntity).
217
+ * @param element - The physical element target to be observed.
218
+ * @param observer - The unified observer singleton (RO/IO) to track the element.
219
+ * @param getRect - An environment-specific function to retrieve the element's current Rect.
220
+ * @param stickyProvider - Optional. If provided, its cache will be invalidated alongside the entity's.
221
+ *
222
+ * @returns A cleanup function to disconnect all registered observers.
223
+ */
224
+ declare function setupSpatialLogic<T>(entity: any, element: T, observer: IElementObserver<T>, getRect: (el: T) => AbstractRect, stickyProvider?: StickyProvider<T> | null): () => void;
225
+ /**
226
+ * Filters out a specific dynamic child node from the tree by its ID (UID).
227
+ *
228
+ * @param children - The array of tree nodes to filter.
229
+ * @param dynamicWidgetId - The UID of the widget to be removed.
230
+ * @returns A new array excluding the specified dynamic child, or an empty array.
231
+ */
232
+ declare function filterNotDynamicChildren(children: ConfigTreeNode[] | undefined, dynamicWidgetId: string): ConfigTreeNode[];
233
+ /**
234
+ * Extract filtered override configurations.
235
+ * @param props Original Props object (e.g. Vue's props)
236
+ * @param skipKeys Ignore key set
237
+ */
238
+ declare function getOverrideProps(props: Record<string, any>, skipKeys: Set<string>): Record<string, any>;
239
+ /**
240
+ * Merges multiple configuration sources into a unified widget configuration object.
241
+ *
242
+ * @description
243
+ * This function performs a shallow merge of the provided configuration objects with a
244
+ * specific precedence order (Right-most takes priority). It also performs a one-level
245
+ * deep merge specifically for the `layout` property to ensure layout settings are
246
+ * preserved across different sources.
247
+ *
248
+ * **Merge Priority (Highest to Lowest):**
249
+ * 1. Fixed metadata (`id`, `baseType`, `parentId`) - *Guaranteed overrides*
250
+ * 2. `overrideProps`
251
+ * 3. `treeConfig`
252
+ * 4. `defaultProps`
253
+ *
254
+ * @param requiredType - The formal entity type (e.g., 'button', 'input-zone') assigned to `baseType`.
255
+ * @param uid - The unique identifier to be assigned to the `id` property.
256
+ * @param parentId - The unique identifier of the parent container, if any.
257
+ * @param defaultProps - The baseline fallback configuration.
258
+ * @param treeConfig - Configuration derived from the widget tree structure.
259
+ * @param overrideProps - Domain-specific or instance-specific property overrides.
260
+ *
261
+ * @returns A complete configuration object of type `T`.
262
+ */
263
+ declare function mergeWidgetConfig<T extends BaseConfig>(requiredType: EntityType, uid: string, parentId: string | undefined, defaultProps: Record<string, any>, treeConfig: Record<string, any>, overrideProps: Record<string, any>): T;
264
+ /**
265
+ * Resolves the dynamic widget instance to be rendered based on priority and exclusivity rules.
266
+ *
267
+ * This utility handles conflicts between manual components provided via slots and template
268
+ * components defined in the configuration. It implements a "Slot-First" strategy:
269
+ * 1. If slot nodes are present, the first valid node is chosen, and configuration templates are ignored.
270
+ * 2. If no slot nodes are present, it fallbacks to searching the configuration children for the matching UID.
271
+ * 3. Enforces uniqueness by ensuring only one component is rendered even if multiple are provided.
272
+ *
273
+ * @template T - The type of the node provided by the adapter (e.g., Vue VNode).
274
+ * @param slotNodes - An array of nodes retrieved from the dynamic widget slot.
275
+ * @param children - The array of child nodes from the current ConfigTreeNode.
276
+ * @param dynamicId - The UID assigned to the dynamic widget template.
277
+ * @returns An object containing the resolved node to render and its source origin.
278
+ */
279
+ declare function resolveDynamicWidget<T>(slotNodes: T[], children: ConfigTreeNode[] | undefined, dynamicId: string): {
280
+ nodeToRender: T | ConfigTreeNode | null;
281
+ isFromSlot: boolean;
282
+ };
283
+ /**
284
+ * Validates that the provided node exists and is non-empty.
285
+ *
286
+ * It matches the node against the `requiredType` by checking both the protocol-level `config.baseType`
287
+ * and the potentially custom `type`.
288
+ *
289
+ * @param node - The configuration node to validate. Can be `undefined`.
290
+ * @param requiredType - The expected {@link EntityType} the node should represent.
291
+ *
292
+ * @returns The original `node` if validation passes; otherwise, `undefined`.
293
+ */
294
+ declare function validateWidgetNode(node: ConfigTreeNode | undefined, requiredType: EntityType): ConfigTreeNode | undefined;
295
+
296
+ /**
297
+ * @deprecated Use validateProfile() instead.
298
+ * This function will be removed in v0.7.0.
299
+ *
300
+ * Validates and normalizes raw JSON data into a standard OmniPadProfile.
301
+ * Performs structural checks and injects default metadata.
302
+ *
303
+ * @param raw - The raw JSON object from disk or network.
304
+ * @returns A validated OmniPadProfile object.
305
+ * @throws Error if the core structure is invalid.
306
+ */
307
+ declare function parseProfileJson(raw: any): OmniPadProfile;
308
+ /**
309
+ * Validates and normalizes raw JSON data into a standard OmniPadProfile.
310
+ * Performs structural checks and injects default metadata.
311
+ *
312
+ * @param raw - The raw JSON object from disk or network.
313
+ * @returns A validated OmniPadProfile object.
314
+ * @throws Error if the core structure is invalid.
315
+ */
316
+ declare function validateProfile(raw: any): OmniPadProfile;
317
+ /**
318
+ * The resulting structure after parsing a OmniPadProfile.
319
+ * Contains a map of root nodes and a runtime-ready gamepad mapping table.
320
+ */
321
+ interface ParsedProfileForest {
322
+ meta: OmniPadProfile['meta'];
323
+ /** Root nodes indexed by their original Config ID. */
324
+ roots: Record<string, ConfigTreeNode>;
325
+ /**
326
+ * Processed gamepad mapping where all CIDs have been
327
+ * translated into unique runtime UIDs.
328
+ */
329
+ runtimeGamepadMappings: GamepadMappingConfig[];
330
+ }
331
+ /**
332
+ * @deprecated Use parseProfileForest() instead.
333
+ * This function will be removed in v0.7.0.
334
+ *
335
+ * Converts a flat OmniPadProfile into a forest of ConfigTreeNodes for runtime rendering.
336
+ * Automatically identifies all items without a parentId as root nodes.
337
+ *
338
+ * @param profile - The normalized profile data.
339
+ * @returns A record map of root nodes, keyed by their original configuration ID.
340
+ */
341
+ declare function parseProfileTrees(profile: OmniPadProfile): ParsedProfileForest;
342
+ /**
343
+ * [Recommended Entry Point]
344
+ * Parses raw input (JSON string or object) into a fully resolved Profile Forest.
345
+ *
346
+ * This function orchestrates:
347
+ * 1. JSON string parsing (if needed)
348
+ * 2. Structural validation & Security hardening
349
+ * 3. Flat-to-tree transformation & ID resolution
350
+ *
351
+ * @param raw - The raw profile data (JSON string or object).
352
+ * @returns A hierarchical forest structure and resolved gamepad mappings.
353
+ * @throws Error if parsing or validation fails.
354
+ */
355
+ declare function parseProfileForest(raw: string | OmniPadProfile): ParsedProfileForest;
356
+ /**
357
+ * Serializes the specified runtime entities into a flat OmniPadProfile.
358
+ * If no rootUids are provided, exports all entities currently in the registry.
359
+ *
360
+ * @param meta - Metadata for the exported profile.
361
+ * @param rootUid - The Entity ID of the node to be treated as the root.
362
+ * @param runtimeGamepadMapping - The current mapping from GamepadManager (using UIDs).
363
+ * @returns A flat OmniPadProfile ready for storage.
364
+ */
365
+ declare function exportProfile(meta: OmniPadProfile['meta'], rootUids?: string[], runtimeGamepadMappings?: Readonly<GamepadMappingConfig[]>): OmniPadProfile;
366
+
175
367
  /**
176
368
  * Configures the global fallback handler for action signals.
177
369
  *
@@ -525,500 +717,615 @@ declare const OmniPad: {
525
717
  };
526
718
  Keys: {
527
719
  readonly Backspace: {
720
+ readonly type: "keyboard";
528
721
  readonly key: "Backspace";
529
722
  readonly code: "Backspace";
530
723
  readonly keyCode: 8;
531
724
  };
532
725
  readonly Tab: {
726
+ readonly type: "keyboard";
533
727
  readonly key: "Tab";
534
728
  readonly code: "Tab";
535
729
  readonly keyCode: 9;
536
730
  };
537
731
  readonly Enter: {
732
+ readonly type: "keyboard";
538
733
  readonly key: "Enter";
539
734
  readonly code: "Enter";
540
735
  readonly keyCode: 13;
541
736
  };
542
737
  readonly ShiftLeft: {
738
+ readonly type: "keyboard";
543
739
  readonly key: "Shift";
544
740
  readonly code: "ShiftLeft";
545
741
  readonly keyCode: 16;
546
742
  };
547
743
  readonly ControlLeft: {
744
+ readonly type: "keyboard";
548
745
  readonly key: "Control";
549
746
  readonly code: "ControlLeft";
550
747
  readonly keyCode: 17;
551
748
  };
552
749
  readonly AltLeft: {
750
+ readonly type: "keyboard";
553
751
  readonly key: "Alt";
554
752
  readonly code: "AltLeft";
555
753
  readonly keyCode: 18;
556
754
  };
557
755
  readonly Pause: {
756
+ readonly type: "keyboard";
558
757
  readonly key: "Pause";
559
758
  readonly code: "Pause";
560
759
  readonly keyCode: 19;
561
760
  };
562
761
  readonly CapsLock: {
762
+ readonly type: "keyboard";
563
763
  readonly key: "CapsLock";
564
764
  readonly code: "CapsLock";
565
765
  readonly keyCode: 20;
566
766
  };
567
767
  readonly Escape: {
768
+ readonly type: "keyboard";
568
769
  readonly key: "Escape";
569
770
  readonly code: "Escape";
570
771
  readonly keyCode: 27;
571
772
  };
572
773
  readonly Space: {
774
+ readonly type: "keyboard";
573
775
  readonly key: " ";
574
776
  readonly code: "Space";
575
777
  readonly keyCode: 32;
576
778
  };
577
779
  readonly PageUp: {
780
+ readonly type: "keyboard";
578
781
  readonly key: "PageUp";
579
782
  readonly code: "PageUp";
580
783
  readonly keyCode: 33;
581
784
  };
582
785
  readonly PageDown: {
786
+ readonly type: "keyboard";
583
787
  readonly key: "PageDown";
584
788
  readonly code: "PageDown";
585
789
  readonly keyCode: 34;
586
790
  };
587
791
  readonly End: {
792
+ readonly type: "keyboard";
588
793
  readonly key: "End";
589
794
  readonly code: "End";
590
795
  readonly keyCode: 35;
591
796
  };
592
797
  readonly Home: {
798
+ readonly type: "keyboard";
593
799
  readonly key: "Home";
594
800
  readonly code: "Home";
595
801
  readonly keyCode: 36;
596
802
  };
597
803
  readonly ArrowLeft: {
804
+ readonly type: "keyboard";
598
805
  readonly key: "ArrowLeft";
599
806
  readonly code: "ArrowLeft";
600
807
  readonly keyCode: 37;
601
808
  };
602
809
  readonly ArrowUp: {
810
+ readonly type: "keyboard";
603
811
  readonly key: "ArrowUp";
604
812
  readonly code: "ArrowUp";
605
813
  readonly keyCode: 38;
606
814
  };
607
815
  readonly ArrowRight: {
816
+ readonly type: "keyboard";
608
817
  readonly key: "ArrowRight";
609
818
  readonly code: "ArrowRight";
610
819
  readonly keyCode: 39;
611
820
  };
612
821
  readonly ArrowDown: {
822
+ readonly type: "keyboard";
613
823
  readonly key: "ArrowDown";
614
824
  readonly code: "ArrowDown";
615
825
  readonly keyCode: 40;
616
826
  };
617
827
  readonly PrintScreen: {
828
+ readonly type: "keyboard";
618
829
  readonly key: "PrintScreen";
619
830
  readonly code: "PrintScreen";
620
831
  readonly keyCode: 44;
621
832
  };
622
833
  readonly Insert: {
834
+ readonly type: "keyboard";
623
835
  readonly key: "Insert";
624
836
  readonly code: "Insert";
625
837
  readonly keyCode: 45;
626
838
  };
627
839
  readonly Delete: {
840
+ readonly type: "keyboard";
628
841
  readonly key: "Delete";
629
842
  readonly code: "Delete";
630
843
  readonly keyCode: 46;
631
844
  };
632
845
  readonly Digit0: {
846
+ readonly type: "keyboard";
633
847
  readonly key: "0";
634
848
  readonly code: "Digit0";
635
849
  readonly keyCode: 48;
636
850
  };
637
851
  readonly Digit1: {
852
+ readonly type: "keyboard";
638
853
  readonly key: "1";
639
854
  readonly code: "Digit1";
640
855
  readonly keyCode: 49;
641
856
  };
642
857
  readonly Digit2: {
858
+ readonly type: "keyboard";
643
859
  readonly key: "2";
644
860
  readonly code: "Digit2";
645
861
  readonly keyCode: 50;
646
862
  };
647
863
  readonly Digit3: {
864
+ readonly type: "keyboard";
648
865
  readonly key: "3";
649
866
  readonly code: "Digit3";
650
867
  readonly keyCode: 51;
651
868
  };
652
869
  readonly Digit4: {
870
+ readonly type: "keyboard";
653
871
  readonly key: "4";
654
872
  readonly code: "Digit4";
655
873
  readonly keyCode: 52;
656
874
  };
657
875
  readonly Digit5: {
876
+ readonly type: "keyboard";
658
877
  readonly key: "5";
659
878
  readonly code: "Digit5";
660
879
  readonly keyCode: 53;
661
880
  };
662
881
  readonly Digit6: {
882
+ readonly type: "keyboard";
663
883
  readonly key: "6";
664
884
  readonly code: "Digit6";
665
885
  readonly keyCode: 54;
666
886
  };
667
887
  readonly Digit7: {
888
+ readonly type: "keyboard";
668
889
  readonly key: "7";
669
890
  readonly code: "Digit7";
670
891
  readonly keyCode: 55;
671
892
  };
672
893
  readonly Digit8: {
894
+ readonly type: "keyboard";
673
895
  readonly key: "8";
674
896
  readonly code: "Digit8";
675
897
  readonly keyCode: 56;
676
898
  };
677
899
  readonly Digit9: {
900
+ readonly type: "keyboard";
678
901
  readonly key: "9";
679
902
  readonly code: "Digit9";
680
903
  readonly keyCode: 57;
681
904
  };
682
905
  readonly KeyA: {
906
+ readonly type: "keyboard";
683
907
  readonly key: "a";
684
908
  readonly code: "KeyA";
685
909
  readonly keyCode: 65;
686
910
  };
687
911
  readonly KeyB: {
912
+ readonly type: "keyboard";
688
913
  readonly key: "b";
689
914
  readonly code: "KeyB";
690
915
  readonly keyCode: 66;
691
916
  };
692
917
  readonly KeyC: {
918
+ readonly type: "keyboard";
693
919
  readonly key: "c";
694
920
  readonly code: "KeyC";
695
921
  readonly keyCode: 67;
696
922
  };
697
923
  readonly KeyD: {
924
+ readonly type: "keyboard";
698
925
  readonly key: "d";
699
926
  readonly code: "KeyD";
700
927
  readonly keyCode: 68;
701
928
  };
702
929
  readonly KeyE: {
930
+ readonly type: "keyboard";
703
931
  readonly key: "e";
704
932
  readonly code: "KeyE";
705
933
  readonly keyCode: 69;
706
934
  };
707
935
  readonly KeyF: {
936
+ readonly type: "keyboard";
708
937
  readonly key: "f";
709
938
  readonly code: "KeyF";
710
939
  readonly keyCode: 70;
711
940
  };
712
941
  readonly KeyG: {
942
+ readonly type: "keyboard";
713
943
  readonly key: "g";
714
944
  readonly code: "KeyG";
715
945
  readonly keyCode: 71;
716
946
  };
717
947
  readonly KeyH: {
948
+ readonly type: "keyboard";
718
949
  readonly key: "h";
719
950
  readonly code: "KeyH";
720
951
  readonly keyCode: 72;
721
952
  };
722
953
  readonly KeyI: {
954
+ readonly type: "keyboard";
723
955
  readonly key: "i";
724
956
  readonly code: "KeyI";
725
957
  readonly keyCode: 73;
726
958
  };
727
959
  readonly KeyJ: {
960
+ readonly type: "keyboard";
728
961
  readonly key: "j";
729
962
  readonly code: "KeyJ";
730
963
  readonly keyCode: 74;
731
964
  };
732
965
  readonly KeyK: {
966
+ readonly type: "keyboard";
733
967
  readonly key: "k";
734
968
  readonly code: "KeyK";
735
969
  readonly keyCode: 75;
736
970
  };
737
971
  readonly KeyL: {
972
+ readonly type: "keyboard";
738
973
  readonly key: "l";
739
974
  readonly code: "KeyL";
740
975
  readonly keyCode: 76;
741
976
  };
742
977
  readonly KeyM: {
978
+ readonly type: "keyboard";
743
979
  readonly key: "m";
744
980
  readonly code: "KeyM";
745
981
  readonly keyCode: 77;
746
982
  };
747
983
  readonly KeyN: {
984
+ readonly type: "keyboard";
748
985
  readonly key: "n";
749
986
  readonly code: "KeyN";
750
987
  readonly keyCode: 78;
751
988
  };
752
989
  readonly KeyO: {
990
+ readonly type: "keyboard";
753
991
  readonly key: "o";
754
992
  readonly code: "KeyO";
755
993
  readonly keyCode: 79;
756
994
  };
757
995
  readonly KeyP: {
996
+ readonly type: "keyboard";
758
997
  readonly key: "p";
759
998
  readonly code: "KeyP";
760
999
  readonly keyCode: 80;
761
1000
  };
762
1001
  readonly KeyQ: {
1002
+ readonly type: "keyboard";
763
1003
  readonly key: "q";
764
1004
  readonly code: "KeyQ";
765
1005
  readonly keyCode: 81;
766
1006
  };
767
1007
  readonly KeyR: {
1008
+ readonly type: "keyboard";
768
1009
  readonly key: "r";
769
1010
  readonly code: "KeyR";
770
1011
  readonly keyCode: 82;
771
1012
  };
772
1013
  readonly KeyS: {
1014
+ readonly type: "keyboard";
773
1015
  readonly key: "s";
774
1016
  readonly code: "KeyS";
775
1017
  readonly keyCode: 83;
776
1018
  };
777
1019
  readonly KeyT: {
1020
+ readonly type: "keyboard";
778
1021
  readonly key: "t";
779
1022
  readonly code: "KeyT";
780
1023
  readonly keyCode: 84;
781
1024
  };
782
1025
  readonly KeyU: {
1026
+ readonly type: "keyboard";
783
1027
  readonly key: "u";
784
1028
  readonly code: "KeyU";
785
1029
  readonly keyCode: 85;
786
1030
  };
787
1031
  readonly KeyV: {
1032
+ readonly type: "keyboard";
788
1033
  readonly key: "v";
789
1034
  readonly code: "KeyV";
790
1035
  readonly keyCode: 86;
791
1036
  };
792
1037
  readonly KeyW: {
1038
+ readonly type: "keyboard";
793
1039
  readonly key: "w";
794
1040
  readonly code: "KeyW";
795
1041
  readonly keyCode: 87;
796
1042
  };
797
1043
  readonly KeyX: {
1044
+ readonly type: "keyboard";
798
1045
  readonly key: "x";
799
1046
  readonly code: "KeyX";
800
1047
  readonly keyCode: 88;
801
1048
  };
802
1049
  readonly KeyY: {
1050
+ readonly type: "keyboard";
803
1051
  readonly key: "y";
804
1052
  readonly code: "KeyY";
805
1053
  readonly keyCode: 89;
806
1054
  };
807
1055
  readonly KeyZ: {
1056
+ readonly type: "keyboard";
808
1057
  readonly key: "z";
809
1058
  readonly code: "KeyZ";
810
1059
  readonly keyCode: 90;
811
1060
  };
812
1061
  readonly MetaLeft: {
1062
+ readonly type: "keyboard";
813
1063
  readonly key: "Meta";
814
1064
  readonly code: "MetaLeft";
815
1065
  readonly keyCode: 91;
816
1066
  };
817
1067
  readonly ContextMenu: {
1068
+ readonly type: "keyboard";
818
1069
  readonly key: "ContextMenu";
819
1070
  readonly code: "ContextMenu";
820
1071
  readonly keyCode: 93;
821
1072
  };
822
1073
  readonly Numpad0: {
1074
+ readonly type: "keyboard";
823
1075
  readonly key: "0";
824
1076
  readonly code: "Numpad0";
825
1077
  readonly keyCode: 96;
826
1078
  };
827
1079
  readonly Numpad1: {
1080
+ readonly type: "keyboard";
828
1081
  readonly key: "1";
829
1082
  readonly code: "Numpad1";
830
1083
  readonly keyCode: 97;
831
1084
  };
832
1085
  readonly Numpad2: {
1086
+ readonly type: "keyboard";
833
1087
  readonly key: "2";
834
1088
  readonly code: "Numpad2";
835
1089
  readonly keyCode: 98;
836
1090
  };
837
1091
  readonly Numpad3: {
1092
+ readonly type: "keyboard";
838
1093
  readonly key: "3";
839
1094
  readonly code: "Numpad3";
840
1095
  readonly keyCode: 99;
841
1096
  };
842
1097
  readonly Numpad4: {
1098
+ readonly type: "keyboard";
843
1099
  readonly key: "4";
844
1100
  readonly code: "Numpad4";
845
1101
  readonly keyCode: 100;
846
1102
  };
847
1103
  readonly Numpad5: {
1104
+ readonly type: "keyboard";
848
1105
  readonly key: "5";
849
1106
  readonly code: "Numpad5";
850
1107
  readonly keyCode: 101;
851
1108
  };
852
1109
  readonly Numpad6: {
1110
+ readonly type: "keyboard";
853
1111
  readonly key: "6";
854
1112
  readonly code: "Numpad6";
855
1113
  readonly keyCode: 102;
856
1114
  };
857
1115
  readonly Numpad7: {
1116
+ readonly type: "keyboard";
858
1117
  readonly key: "7";
859
1118
  readonly code: "Numpad7";
860
1119
  readonly keyCode: 103;
861
1120
  };
862
1121
  readonly Numpad8: {
1122
+ readonly type: "keyboard";
863
1123
  readonly key: "8";
864
1124
  readonly code: "Numpad8";
865
1125
  readonly keyCode: 104;
866
1126
  };
867
1127
  readonly Numpad9: {
1128
+ readonly type: "keyboard";
868
1129
  readonly key: "9";
869
1130
  readonly code: "Numpad9";
870
1131
  readonly keyCode: 105;
871
1132
  };
872
1133
  readonly NumpadMultiply: {
1134
+ readonly type: "keyboard";
873
1135
  readonly key: "*";
874
1136
  readonly code: "NumpadMultiply";
875
1137
  readonly keyCode: 106;
876
1138
  };
877
1139
  readonly NumpadAdd: {
1140
+ readonly type: "keyboard";
878
1141
  readonly key: "+";
879
1142
  readonly code: "NumpadAdd";
880
1143
  readonly keyCode: 107;
881
1144
  };
882
1145
  readonly NumpadSubtract: {
1146
+ readonly type: "keyboard";
883
1147
  readonly key: "-";
884
1148
  readonly code: "NumpadSubtract";
885
1149
  readonly keyCode: 109;
886
1150
  };
887
1151
  readonly NumpadDecimal: {
1152
+ readonly type: "keyboard";
888
1153
  readonly key: ".";
889
1154
  readonly code: "NumpadDecimal";
890
1155
  readonly keyCode: 110;
891
1156
  };
892
1157
  readonly NumpadDivide: {
1158
+ readonly type: "keyboard";
893
1159
  readonly key: "/";
894
1160
  readonly code: "NumpadDivide";
895
1161
  readonly keyCode: 111;
896
1162
  };
897
1163
  readonly F1: {
1164
+ readonly type: "keyboard";
898
1165
  readonly key: "F1";
899
1166
  readonly code: "F1";
900
1167
  readonly keyCode: 112;
901
1168
  };
902
1169
  readonly F2: {
1170
+ readonly type: "keyboard";
903
1171
  readonly key: "F2";
904
1172
  readonly code: "F2";
905
1173
  readonly keyCode: 113;
906
1174
  };
907
1175
  readonly F3: {
1176
+ readonly type: "keyboard";
908
1177
  readonly key: "F3";
909
1178
  readonly code: "F3";
910
1179
  readonly keyCode: 114;
911
1180
  };
912
1181
  readonly F4: {
1182
+ readonly type: "keyboard";
913
1183
  readonly key: "F4";
914
1184
  readonly code: "F4";
915
1185
  readonly keyCode: 115;
916
1186
  };
917
1187
  readonly F5: {
1188
+ readonly type: "keyboard";
918
1189
  readonly key: "F5";
919
1190
  readonly code: "F5";
920
1191
  readonly keyCode: 116;
921
1192
  };
922
1193
  readonly F6: {
1194
+ readonly type: "keyboard";
923
1195
  readonly key: "F6";
924
1196
  readonly code: "F6";
925
1197
  readonly keyCode: 117;
926
1198
  };
927
1199
  readonly F7: {
1200
+ readonly type: "keyboard";
928
1201
  readonly key: "F7";
929
1202
  readonly code: "F7";
930
1203
  readonly keyCode: 118;
931
1204
  };
932
1205
  readonly F8: {
1206
+ readonly type: "keyboard";
933
1207
  readonly key: "F8";
934
1208
  readonly code: "F8";
935
1209
  readonly keyCode: 119;
936
1210
  };
937
1211
  readonly F9: {
1212
+ readonly type: "keyboard";
938
1213
  readonly key: "F9";
939
1214
  readonly code: "F9";
940
1215
  readonly keyCode: 120;
941
1216
  };
942
1217
  readonly F10: {
1218
+ readonly type: "keyboard";
943
1219
  readonly key: "F10";
944
1220
  readonly code: "F10";
945
1221
  readonly keyCode: 121;
946
1222
  };
947
1223
  readonly F11: {
1224
+ readonly type: "keyboard";
948
1225
  readonly key: "F11";
949
1226
  readonly code: "F11";
950
1227
  readonly keyCode: 122;
951
1228
  };
952
1229
  readonly F12: {
1230
+ readonly type: "keyboard";
953
1231
  readonly key: "F12";
954
1232
  readonly code: "F12";
955
1233
  readonly keyCode: 123;
956
1234
  };
957
1235
  readonly NumLock: {
1236
+ readonly type: "keyboard";
958
1237
  readonly key: "NumLock";
959
1238
  readonly code: "NumLock";
960
1239
  readonly keyCode: 144;
961
1240
  };
962
1241
  readonly ScrollLock: {
1242
+ readonly type: "keyboard";
963
1243
  readonly key: "ScrollLock";
964
1244
  readonly code: "ScrollLock";
965
1245
  readonly keyCode: 145;
966
1246
  };
967
1247
  readonly Semicolon: {
1248
+ readonly type: "keyboard";
968
1249
  readonly key: ";";
969
1250
  readonly code: "Semicolon";
970
1251
  readonly keyCode: 186;
971
1252
  };
972
1253
  readonly Equal: {
1254
+ readonly type: "keyboard";
973
1255
  readonly key: "=";
974
1256
  readonly code: "Equal";
975
1257
  readonly keyCode: 187;
976
1258
  };
977
1259
  readonly Comma: {
1260
+ readonly type: "keyboard";
978
1261
  readonly key: ",";
979
1262
  readonly code: "Comma";
980
1263
  readonly keyCode: 188;
981
1264
  };
982
1265
  readonly Minus: {
1266
+ readonly type: "keyboard";
983
1267
  readonly key: "-";
984
1268
  readonly code: "Minus";
985
1269
  readonly keyCode: 189;
986
1270
  };
987
1271
  readonly Period: {
1272
+ readonly type: "keyboard";
988
1273
  readonly key: ".";
989
1274
  readonly code: "Period";
990
1275
  readonly keyCode: 190;
991
1276
  };
992
1277
  readonly Slash: {
1278
+ readonly type: "keyboard";
993
1279
  readonly key: "/";
994
1280
  readonly code: "Slash";
995
1281
  readonly keyCode: 191;
996
1282
  };
997
1283
  readonly Backquote: {
1284
+ readonly type: "keyboard";
998
1285
  readonly key: "`";
999
1286
  readonly code: "Backquote";
1000
1287
  readonly keyCode: 192;
1001
1288
  };
1002
1289
  readonly BracketLeft: {
1290
+ readonly type: "keyboard";
1003
1291
  readonly key: "[";
1004
1292
  readonly code: "BracketLeft";
1005
1293
  readonly keyCode: 219;
1006
1294
  };
1007
1295
  readonly Backslash: {
1296
+ readonly type: "keyboard";
1008
1297
  readonly key: "\\";
1009
1298
  readonly code: "Backslash";
1010
1299
  readonly keyCode: 220;
1011
1300
  };
1012
1301
  readonly BracketRight: {
1302
+ readonly type: "keyboard";
1013
1303
  readonly key: "]";
1014
1304
  readonly code: "BracketRight";
1015
1305
  readonly keyCode: 221;
1016
1306
  };
1017
1307
  readonly Quote: {
1308
+ readonly type: "keyboard";
1018
1309
  readonly key: "'";
1019
1310
  readonly code: "Quote";
1020
1311
  readonly keyCode: 222;
1021
1312
  };
1313
+ readonly Mouse: {
1314
+ readonly type: "mouse";
1315
+ readonly button: 0;
1316
+ };
1317
+ readonly MouseLeft: {
1318
+ readonly type: "mouse";
1319
+ readonly button: 0;
1320
+ };
1321
+ readonly MouseMiddle: {
1322
+ readonly type: "mouse";
1323
+ readonly button: 1;
1324
+ };
1325
+ readonly MouseRight: {
1326
+ readonly type: "mouse";
1327
+ readonly button: 2;
1328
+ };
1022
1329
  };
1023
1330
  Types: {
1024
1331
  readonly INPUT_ZONE: "input-zone";
@@ -1034,4 +1341,4 @@ declare const OmniPad: {
1034
1341
  };
1035
1342
  };
1036
1343
 
1037
- export { AbstractPointerEvent, AbstractRect, AnyFunction, type AxisLogicState, BaseConfig, BaseEntity, ButtonConfig, ButtonCore, type ButtonLogicState, type ButtonState, type CursorState, DPadConfig, DPadCore, type DPadState, EntityType, IConfigurable, ICoreEntity, IDependencyBindable, IPointerHandler, IProgrammatic, type IRegistry, IResettable, ISignalReceiver, ISpatial, IStateful, InputActionSignal, InputZoneConfig, InputZoneCore, type InputZoneState, type InteractionState, JoystickConfig, JoystickCore, type JoystickState, type KeyboardButtonState, type LayerState, type MouseButtonState, OmniPad, Registry, RootLayerCore, TargetZoneConfig, TargetZoneCore, TrackpadConfig, TrackpadCore, type TrackpadState, Vec2, setGlobalSignalHandler };
1344
+ export { AbstractPointerEvent, AbstractRect, AnyFunction, type AxisLogicState, BaseConfig, BaseEntity, ButtonConfig, ButtonCore, type ButtonLogicState, type ButtonState, ConfigTreeNode, type CursorState, DPadConfig, DPadCore, type DPadState, EntityType, GamepadMappingConfig, IConfigurable, ICoreEntity, IDependencyBindable, IElementObserver, IPointerHandler, IProgrammatic, type IRegistry, IResettable, ISignalReceiver, ISpatial, IStateful, InputActionSignal, InputZoneConfig, InputZoneCore, type InputZoneState, type InteractionState, type IpcMessage, JoystickConfig, JoystickCore, type JoystickState, type KeyboardButtonState, type LayerState, type MouseButtonState, OMNIPAD_IPC_SIGNATURE, OmniPad, OmniPadProfile, type ParsedProfileForest, Registry, RootLayerCore, StickyProvider, TargetZoneConfig, TargetZoneCore, TrackpadConfig, TrackpadCore, type TrackpadState, Vec2, bindEntityDelegates, exportProfile, filterNotDynamicChildren, getOverrideProps, mergeWidgetConfig, parseProfileForest, parseProfileJson, parseProfileTrees, resolveDynamicWidget, setGlobalSignalHandler, setupSpatialLogic, validateProfile, validateWidgetNode };