@cocorograph/hub-agent 0.6.35 → 0.6.36
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/package.json +1 -1
- package/src/claude-history.mjs +5 -0
package/package.json
CHANGED
package/src/claude-history.mjs
CHANGED
|
@@ -38,6 +38,11 @@ export function normalizeHistoryEvent(obj) {
|
|
|
38
38
|
if (obj.message !== undefined) event.message = obj.message
|
|
39
39
|
if (obj.subtype !== undefined) event.subtype = obj.subtype
|
|
40
40
|
if (obj.uuid !== undefined) event.uuid = obj.uuid
|
|
41
|
+
// jsonl 各行の ISO8601 タイムスタンプ。Browser 側でバブル上の時刻表示・日付区切りに
|
|
42
|
+
// 使う。履歴 hydrate と live watch の両経路がこの関数を通るため、ここ 1 箇所で拾えば
|
|
43
|
+
// 両方に時刻が乗る (純粋なライブ SDK stream には timestamp が無く、Browser が受信時刻で
|
|
44
|
+
// 補完する)。
|
|
45
|
+
if (obj.timestamp !== undefined) event.timestamp = obj.timestamp
|
|
41
46
|
if (obj.session_id !== undefined) event.session_id = obj.session_id
|
|
42
47
|
else if (obj.sessionId !== undefined) event.session_id = obj.sessionId
|
|
43
48
|
if (obj.model !== undefined) event.model = obj.model
|