@akhilpulse/samadhaan-session-replay 0.6.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.
- package/README.md +1 -1
- package/package.json +1 -1
- package/src/SessionReplayProvider.tsx +3 -3
package/README.md
CHANGED
|
@@ -177,7 +177,7 @@ iOS: `cd ios && pod install && cd .. && npx react-native run-ios`.
|
|
|
177
177
|
|
|
178
178
|
- Creates a session against `POST /api/guided-support/sessions` and persists `sessionId` in AsyncStorage so it can be resumed after relaunch.
|
|
179
179
|
- Captures gestures (tap, swipe) using a passive PanResponder + onTouchEnd bubble listener — host taps still work.
|
|
180
|
-
- Captures screenshots every 10 s in background mode, every
|
|
180
|
+
- Captures screenshots every 10 s in background mode, every 500 ms (~2 fps) in live/assistant mode, via `react-native-view-shot`. Uploads via `POST /api/guided-support/storage/uploads/request-url` then PUTs to the returned URL.
|
|
181
181
|
- Auto-connects to `WS /ws/guided-support?sessionId=…&role=device&token=…` when the dashboard flips the session to `live`.
|
|
182
182
|
- Streams binary frames as `[ts u32 BE | width u16 BE | height u16 BE] + JPEG bytes`.
|
|
183
183
|
- Renders a remote-control overlay that visualizes incoming taps. Native touch dispatch (iOS UIEvent / Android AccessibilityService) is wired by the integrator via a small custom native module.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@akhilpulse/samadhaan-session-replay",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.1",
|
|
4
4
|
"description": "React Native SDK for Samadhaan Guided Support — session recording, live remote screen-share, take-control, guided-tour overlays, and Shake-to-Assist AI voice guide.",
|
|
5
5
|
"main": "src/index.ts",
|
|
6
6
|
"module": "src/index.ts",
|
|
@@ -56,7 +56,7 @@ let pixelCopyDisabled = false; // turned true after repeated runtime failures to
|
|
|
56
56
|
let pixelCopyFailStreak = 0; // consecutive non-busy failures; resets on success
|
|
57
57
|
|
|
58
58
|
const STORAGE_KEY = "@akhilpulse/samadhaan-session-replay/sessionId";
|
|
59
|
-
const SDK_VERSION = "0.6.
|
|
59
|
+
const SDK_VERSION = "0.6.1";
|
|
60
60
|
|
|
61
61
|
// ---- Module-level session singleton --------------------------------------
|
|
62
62
|
// Multiple SessionReplayProvider mounts (intentional or via React StrictMode's
|
|
@@ -370,9 +370,9 @@ export function SessionReplayProvider({ config, children }: { config: Config; ch
|
|
|
370
370
|
// waste CPU/battery/network on periodic screenshots.
|
|
371
371
|
if (config.disableScreenshots || !sessionId || !streamActive) return;
|
|
372
372
|
let stopped = false;
|
|
373
|
-
// ~
|
|
373
|
+
// ~2 fps target — low device load while still feeling responsive. Capture
|
|
374
374
|
// takes time, so the loop self-paces: next tick is scheduled AFTER the previous capture completes.
|
|
375
|
-
const liveTargetMs =
|
|
375
|
+
const liveTargetMs = 500;
|
|
376
376
|
let lastUploadFrameAt = 0;
|
|
377
377
|
const tick = async () => {
|
|
378
378
|
if (stopped) return;
|