@skippr/live-agent-sdk 0.67.0 → 0.69.0

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.
@@ -0,0 +1,4 @@
1
+ export interface PausedCountdownProps {
2
+ secondsRemaining: number;
3
+ }
4
+ export declare function PausedCountdown({ secondsRemaining }: PausedCountdownProps): import("react/jsx-runtime").JSX.Element;
@@ -100,6 +100,7 @@ export interface LiveAgentPublicValue {
100
100
  selectModule: (id: string) => void;
101
101
  }
102
102
  export interface LiveAgentContextValue extends LiveAgentPublicValue {
103
+ pauseTimeoutSeconds: number | null;
103
104
  usesHostAuth: boolean;
104
105
  authFailed: boolean;
105
106
  connection: {
@@ -123,5 +124,7 @@ export interface LiveAgentContextValue extends LiveAgentPublicValue {
123
124
  togglePanelExpanded: () => void;
124
125
  panelRef: React.RefObject<HTMLDivElement | null>;
125
126
  controlBarRef: React.RefObject<HTMLDivElement | null>;
127
+ isDragging: boolean;
128
+ setIsDragging: (dragging: boolean) => void;
126
129
  }
127
130
  export declare const LiveAgentContext: import("react").Context<LiveAgentContextValue | null>;
@@ -3,7 +3,7 @@ export interface LauncherDropTarget {
3
3
  bottomPx: number;
4
4
  }
5
5
  type FollowerRef = React.RefObject<HTMLElement | null>;
6
- export declare function useLauncherDrag(containerRef: React.RefObject<HTMLElement | null>, onDrop: (target: LauncherDropTarget) => void, followRefs?: FollowerRef[] | null): {
6
+ export declare function useLauncherDrag(containerRef: React.RefObject<HTMLElement | null>, onDrop: (target: LauncherDropTarget) => void, followRefs?: FollowerRef[] | null, reportDragging?: (dragging: boolean) => void): {
7
7
  wasDraggedRef: React.RefObject<boolean>;
8
8
  };
9
9
  export {};
@@ -33,6 +33,7 @@ export declare function useSession({ captureMode, authToken, appKey, getUserToke
33
33
  disconnect: () => Promise<void>;
34
34
  isPaused: boolean;
35
35
  isPausing: boolean;
36
+ pauseTimeoutSeconds: number | null;
36
37
  historyMessages: Message[];
37
38
  pendingScreenStream: MediaStream | null;
38
39
  bearerToken: string | null;
@@ -0,0 +1,13 @@
1
+ export declare const FALLBACK_PAUSE_TIMEOUT_SECONDS = 120;
2
+ export interface UseSessionHoldOptions {
3
+ pauseSession: () => Promise<void>;
4
+ pauseTimeoutSeconds: number | null;
5
+ }
6
+ export interface UseSessionHoldValue {
7
+ isHeld: boolean;
8
+ countdown: number;
9
+ toggle: () => void;
10
+ }
11
+ /** Owns the user's in-session pause/resume: mutes the mic, signals the worker to stop listening,
12
+ * and ends the session if the hold outlasts the countdown. */
13
+ export declare function useSessionHold({ pauseSession, pauseTimeoutSeconds, }: UseSessionHoldOptions): UseSessionHoldValue;
@@ -1,4 +1,4 @@
1
- export declare const SIDEBAR_WIDTH = 360;
1
+ export declare const SIDEBAR_WIDTH = 280;
2
2
  export declare const WIDGET_ROOT_ID = "skippr-sdk-root";
3
3
  export declare const REF_ATTR = "data-skippr-ref";
4
4
  export declare const PRIVATE_ATTR = "data-skippr-private";
@@ -8,5 +8,6 @@ export declare const HIGHLIGHT_TOPIC = "skippr.highlight";
8
8
  export declare const PAGE_ACTIONS_TOPIC = "skippr.page-actions";
9
9
  export declare const TEXT_MODE_TOPIC = "skippr.text-mode";
10
10
  export declare const ACTION_CONTROL_TOPIC = "skippr.action-control";
11
+ export declare const SESSION_HOLD_TOPIC = "skippr.session-hold";
11
12
  export declare const PLAN_ATTR = "skippr.action-plan";
12
13
  export declare const NAME_MAX_CHARS = 80;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@skippr/live-agent-sdk",
3
- "version": "0.67.0",
3
+ "version": "0.69.0",
4
4
  "type": "module",
5
5
  "main": "dist/esm/lib-exports.js",
6
6
  "module": "dist/esm/lib-exports.js",