@mentra/engine 3.2.0-dev.261 → 3.2.0-dev.263

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 (33) hide show
  1. package/build/generated/releaseMetadata.js +5 -5
  2. package/build/generated/releaseMetadata.js.map +1 -1
  3. package/build/services/AcsMeetingService.d.ts +25 -1
  4. package/build/services/AcsMeetingService.d.ts.map +1 -1
  5. package/build/services/AcsMeetingService.js +41 -3
  6. package/build/services/AcsMeetingService.js.map +1 -1
  7. package/build/services/LocalMiniappRuntime.d.ts +32 -3
  8. package/build/services/LocalMiniappRuntime.d.ts.map +1 -1
  9. package/build/services/LocalMiniappRuntime.js +284 -30
  10. package/build/services/LocalMiniappRuntime.js.map +1 -1
  11. package/build/services/MiniappLiveness.d.ts +11 -0
  12. package/build/services/MiniappLiveness.d.ts.map +1 -1
  13. package/build/services/MiniappLiveness.js +11 -0
  14. package/build/services/MiniappLiveness.js.map +1 -1
  15. package/build/services/PhoneStreamCoordinator.d.ts +13 -1
  16. package/build/services/PhoneStreamCoordinator.d.ts.map +1 -1
  17. package/build/services/PhoneStreamCoordinator.js +27 -4
  18. package/build/services/PhoneStreamCoordinator.js.map +1 -1
  19. package/build/services/SoftapCallTransport.d.ts +87 -7
  20. package/build/services/SoftapCallTransport.d.ts.map +1 -1
  21. package/build/services/SoftapCallTransport.js +229 -28
  22. package/build/services/SoftapCallTransport.js.map +1 -1
  23. package/build/utils/miniappGlobals.d.ts.map +1 -1
  24. package/build/utils/miniappGlobals.js +13 -11
  25. package/build/utils/miniappGlobals.js.map +1 -1
  26. package/package.json +8 -8
  27. package/src/generated/releaseMetadata.ts +5 -5
  28. package/src/services/AcsMeetingService.ts +51 -3
  29. package/src/services/LocalMiniappRuntime.ts +296 -30
  30. package/src/services/MiniappLiveness.ts +18 -0
  31. package/src/services/PhoneStreamCoordinator.ts +27 -5
  32. package/src/services/SoftapCallTransport.ts +274 -32
  33. package/src/utils/miniappGlobals.ts +13 -11
@@ -28,12 +28,14 @@ export interface CapsuleMenuRect {
28
28
  * The capsule menu bounding rect in the WebView's own coordinate space.
29
29
  *
30
30
  * Keep in sync with CapsuleMenu.tsx:
31
- * - CapsuleButton height h-7.5 (30px), width ≈ 73px
32
- * - Positioned at right-2 (8px), top = theme.spacing.s2 (8px) below insets.top
31
+ * - CapsuleButton is `h-8 w-20` (32×80)
32
+ * - Positioned at right = theme.spacing.s4 (16px), top = theme.spacing.s2 (8px)
33
+ * below insets.top
33
34
  */
34
- const CAPSULE_MENU_HEIGHT = 30
35
- const CAPSULE_MENU_WIDTH = 73
36
- const CAPSULE_MENU_PADDING = 8
35
+ const CAPSULE_MENU_HEIGHT = 32
36
+ const CAPSULE_MENU_WIDTH = 80
37
+ const CAPSULE_MENU_TOP = 8
38
+ const CAPSULE_MENU_RIGHT = 16
37
39
 
38
40
  /**
39
41
  * @param topInsetOffset extra top offset to add when the WebView container does
@@ -43,12 +45,12 @@ const CAPSULE_MENU_PADDING = 8
43
45
  */
44
46
  export function getCapsuleMenuRect(topInsetOffset = 0): CapsuleMenuRect {
45
47
  const screenWidth = Dimensions.get("window").width
46
- const top = topInsetOffset + CAPSULE_MENU_PADDING
48
+ const top = topInsetOffset + CAPSULE_MENU_TOP
47
49
  return {
48
50
  top,
49
- right: CAPSULE_MENU_PADDING,
51
+ right: CAPSULE_MENU_RIGHT,
50
52
  bottom: top + CAPSULE_MENU_HEIGHT,
51
- left: screenWidth - CAPSULE_MENU_PADDING - CAPSULE_MENU_WIDTH,
53
+ left: screenWidth - CAPSULE_MENU_RIGHT - CAPSULE_MENU_WIDTH,
52
54
  width: CAPSULE_MENU_WIDTH,
53
55
  height: CAPSULE_MENU_HEIGHT,
54
56
  }
@@ -115,9 +117,9 @@ export function buildMiniappGlobalsScript(opts: BuildMiniappGlobalsOptions): str
115
117
  "--mentra-capsule-width": `${capsule.width}px`,
116
118
  "--mentra-capsule-height": `${capsule.height}px`,
117
119
  "--mentra-capsule-center-y": `${capsuleCenter}px`,
118
- // Right-side gutter to reserve so content doesn't slide under the
119
- // capsule: capsule width + 16px breathing room.
120
- "--mentra-capsule-gutter": `${capsule.width + 16}px`,
120
+ // Right-side gutter so content doesn't slide under the capsule:
121
+ // host right offset + capsule width + 16px breathing room.
122
+ "--mentra-capsule-gutter": `${capsule.right + capsule.width + 16}px`,
121
123
  }
122
124
  const cssVarsBlock = Object.entries(cssVars)
123
125
  .map(([k, v]) => `${k}: ${v};`)