@readerseye2/cr_type 1.0.183 → 1.0.184

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.
@@ -1,3 +1,8 @@
1
+ /**
2
+ * Socket 디바이스 플랫폼 (얼굴보기 디바이스 선택용).
3
+ * 자녀 socket에만 채워짐. userAgent에서 파싱.
4
+ */
5
+ export type DevicePlatform = 'windows' | 'macos' | 'android' | 'ios' | 'linux' | 'unknown';
1
6
  /**
2
7
  * 연결된 사용자 정보 (Socket 기반)
3
8
  */
@@ -12,10 +17,12 @@ export interface ConnectedUser {
12
17
  userName: string;
13
18
  /** 부모 idx (child인 경우) */
14
19
  parentIdx?: number;
15
- /** 연결 시간 */
20
+ /** 연결 시간 (ISO) */
16
21
  connectedAt: string;
17
22
  /** 현재 읽기 세션 ID (읽기 중인 경우) */
18
23
  readingSessionId?: string;
24
+ /** 디바이스 플랫폼 — 자녀 socket에만 채워짐 (얼굴보기 디바이스 선택용) */
25
+ platform?: DevicePlatform;
19
26
  }
20
27
  /**
21
28
  * 가족 그룹 (family:{parentIdx} 기준)
@@ -26,9 +26,14 @@ export interface ClientToServerEvents {
26
26
  'reading:watch-children': (childIdxList: number[]) => void;
27
27
  /** 자녀 읽기 상태 구독 해제 */
28
28
  'reading:unwatch-children': () => void;
29
- /** 부모→자녀 offer */
29
+ /**
30
+ * 부모→자녀 offer.
31
+ * targetChildSocketId: 같은 자녀 계정으로 여러 단말 접속 시 부모가 선택한 단말의 socketId.
32
+ * (디바이스 선택 모달 → ConnectedUser.socketId)
33
+ */
30
34
  'webrtc:offer': (payload: {
31
35
  targetChildIdx: number;
36
+ targetChildSocketId: string;
32
37
  sdp: string;
33
38
  }) => void;
34
39
  /** 자녀→부모 answer */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@readerseye2/cr_type",
3
- "version": "1.0.183",
3
+ "version": "1.0.184",
4
4
  "description": "CheckReading shared TypeScript types",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",