@pollen-robotics/reachy-mini-sdk 1.9.0 → 1.10.0-dev.0.main.05ce680

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,7 +1,7 @@
1
- var $ = Object.defineProperty, F = (r, e, t) => e in r ? $(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, k = (r, e, t) => (F(r, typeof e != "symbol" ? e + "" : e, t), t), x = "https://huggingface.co";
2
- async function C(r, e) {
1
+ var O = Object.defineProperty, x = (r, e, t) => e in r ? O(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, C = (r, e, t) => (x(r, typeof e != "symbol" ? e + "" : e, t), t), $ = "https://huggingface.co";
2
+ async function k(r, e) {
3
3
  var t, s;
4
- const i = new O(r.url, r.status, (t = r.headers.get("X-Request-Id")) != null ? t : void 0);
4
+ const i = new F(r.url, r.status, (t = r.headers.get("X-Request-Id")) != null ? t : void 0);
5
5
  i.message = `Api error with status ${i.statusCode}`;
6
6
  const o = [`URL: ${i.url}`, i.requestId ? `Request ID: ${i.requestId}` : void 0].filter(Boolean).join(". ");
7
7
  if ((s = r.headers.get("Content-Type")) != null && s.startsWith("application/json")) {
@@ -11,14 +11,14 @@ async function C(r, e) {
11
11
  i.data = { message: await r.text() };
12
12
  throw i.message += `. ${o}`, i;
13
13
  }
14
- var O = class extends Error {
14
+ var F = class extends Error {
15
15
  constructor(r, e, t, s) {
16
- super(s), k(this, "statusCode"), k(this, "url"), k(this, "requestId"), k(this, "data"), this.statusCode = e, this.requestId = t, this.url = r;
16
+ super(s), C(this, "statusCode"), C(this, "url"), C(this, "requestId"), C(this, "data"), this.statusCode = e, this.requestId = t, this.url = r;
17
17
  }
18
18
  };
19
19
  new Promise((r) => {
20
20
  });
21
- function H(r) {
21
+ function N(r) {
22
22
  if (globalThis.Buffer)
23
23
  return globalThis.Buffer.from(r).toString("base64");
24
24
  {
@@ -54,13 +54,13 @@ async function M(r) {
54
54
  }
55
55
  if (h.nonce !== a)
56
56
  throw new Error("Invalid oauth state in redirected URL");
57
- const d = x, m = `${new URL(d).origin}/.well-known/openid-configuration`, f = await fetch(m, {
57
+ const d = $, m = `${new URL(d).origin}/.well-known/openid-configuration`, f = await fetch(m, {
58
58
  headers: {
59
59
  Accept: "application/json"
60
60
  }
61
61
  });
62
62
  if (!f.ok)
63
- throw await C(f);
63
+ throw await k(f);
64
64
  const p = await f.json(), v = await fetch(p.token_endpoint, {
65
65
  method: "POST",
66
66
  headers: {
@@ -74,14 +74,14 @@ async function M(r) {
74
74
  }).toString()
75
75
  });
76
76
  if (localStorage.removeItem("huggingface.co:oauth:code_verifier"), localStorage.removeItem("huggingface.co:oauth:nonce"), !v.ok)
77
- throw await C(v);
77
+ throw await k(v);
78
78
  const g = await v.json(), w = new Date(Date.now() + g.expires_in * 1e3), S = await fetch(p.userinfo_endpoint, {
79
79
  headers: {
80
80
  Authorization: `Bearer ${g.access_token}`
81
81
  }
82
82
  });
83
83
  if (!S.ok)
84
- throw await C(S);
84
+ throw await k(S);
85
85
  const u = await S.json();
86
86
  return {
87
87
  accessToken: g.access_token,
@@ -109,7 +109,7 @@ async function M(r) {
109
109
  scope: g.scope
110
110
  };
111
111
  }
112
- async function N(r) {
112
+ async function H(r) {
113
113
  if (typeof window > "u")
114
114
  throw new Error("oauthHandleRedirect is only available in the browser");
115
115
  const e = new URLSearchParams(window.location.search);
@@ -121,13 +121,13 @@ async function V(r) {
121
121
  var e, t;
122
122
  if (typeof window > "u")
123
123
  throw new Error("oauthLogin is only available in the browser");
124
- const s = r?.hubUrl || x, i = `${new URL(s).origin}/.well-known/openid-configuration`, o = await fetch(i, {
124
+ const s = r?.hubUrl || $, i = `${new URL(s).origin}/.well-known/openid-configuration`, o = await fetch(i, {
125
125
  headers: {
126
126
  Accept: "application/json"
127
127
  }
128
128
  });
129
129
  if (!o.ok)
130
- throw await C(o);
130
+ throw await k(o);
131
131
  const n = await o.json(), a = globalThis.crypto.randomUUID(), c = globalThis.crypto.randomUUID() + globalThis.crypto.randomUUID();
132
132
  localStorage.setItem("huggingface.co:oauth:nonce", a), localStorage.setItem("huggingface.co:oauth:code_verifier", c);
133
133
  const l = r?.redirectUrl || window.location.href, h = JSON.stringify({
@@ -137,7 +137,7 @@ async function V(r) {
137
137
  }), d = (t = (e = window?.huggingface) == null ? void 0 : e.variables) != null ? t : null, m = r?.clientId || d?.OAUTH_CLIENT_ID;
138
138
  if (!m)
139
139
  throw d ? new Error("Missing clientId, please add hf_oauth: true to the README.md's metadata in your static Space") : new Error("Missing clientId");
140
- const f = H(
140
+ const f = N(
141
141
  new Uint8Array(await globalThis.crypto.subtle.digest("SHA-256", new TextEncoder().encode(c)))
142
142
  ).replace(/[+]/g, "-").replace(/[/]/g, "_").replace(/=/g, "");
143
143
  return `${n.authorization_endpoint}?${new URLSearchParams({
@@ -212,14 +212,14 @@ function W(r) {
212
212
  if (s.startsWith("m=audio") ? t = !0 : s.startsWith("m=") && (t = !1), t && s === "a=sendrecv") return !0;
213
213
  return !1;
214
214
  }
215
- const y = 12 * 1024, A = 1 * 1024 * 1024, z = 512 * 1024;
215
+ const y = 12 * 1024, E = 1 * 1024 * 1024, z = 512 * 1024;
216
216
  function J() {
217
217
  return typeof CompressionStream < "u";
218
218
  }
219
219
  function U() {
220
220
  return "u" + Math.random().toString(36).slice(2, 11) + Date.now().toString(36);
221
221
  }
222
- function E(r) {
222
+ function A(r) {
223
223
  let e = "";
224
224
  for (let s = 0; s < r.length; s += 32768)
225
225
  e += String.fromCharCode.apply(
@@ -232,7 +232,7 @@ async function X(r) {
232
232
  const e = new TextEncoder().encode(r), t = await new Response(
233
233
  new Blob([e]).stream().pipeThrough(new CompressionStream("gzip"))
234
234
  ).arrayBuffer();
235
- return E(new Uint8Array(t));
235
+ return A(new Uint8Array(t));
236
236
  }
237
237
  function L(r) {
238
238
  const e = Math.round(Number(r) || 0);
@@ -261,8 +261,8 @@ function P(r) {
261
261
  return "wav-base64";
262
262
  }
263
263
  }
264
- const j = 3e3, D = 1e3, Y = 6e4;
265
- class K extends EventTarget {
264
+ const j = 3e3, D = 1e3, Y = 6e4, K = 4e3;
265
+ class Q extends EventTarget {
266
266
  // ─── Config ──────────────────────────────────────────────────────────
267
267
  _signalingUrl;
268
268
  _clientId;
@@ -309,6 +309,13 @@ class K extends EventTarget {
309
309
  // ─── Log subscribers ─────────────────────────────────────────────────
310
310
  _logSubscribers = /* @__PURE__ */ new Set();
311
311
  _updateProgressSubscribers = /* @__PURE__ */ new Set();
312
+ // ─── JSON-RPC app control (over the same DataChannel) ────────────────
313
+ // rpcCall() sends {jsonrpc,id,method,params} and awaits the matching
314
+ // response; onNotification() subscribes to one-way events (no id) the
315
+ // robot/app pushes (conversation.phase/turn/transcript, ...).
316
+ _rpcCounter = 0;
317
+ _pendingRpc = /* @__PURE__ */ new Map();
318
+ _rpcListeners = /* @__PURE__ */ new Map();
312
319
  // ─── Broadcast waiters (playMove / playUploadedAudio) ────────────────
313
320
  _broadcastWaiters = [];
314
321
  // ─── Active upload ids for no-arg cancels ────────────────────────────
@@ -393,7 +400,7 @@ class K extends EventTarget {
393
400
  async authenticate() {
394
401
  try {
395
402
  G();
396
- const e = await N();
403
+ const e = await H();
397
404
  if (e)
398
405
  return this._username = e.userInfo.preferred_username || e.userInfo.name || null, this._token = e.accessToken, this._tokenExpires = e.accessTokenExpiresAt, sessionStorage.setItem("hf_token", this._token), sessionStorage.setItem("hf_username", this._username ?? ""), sessionStorage.setItem(
399
406
  "hf_token_expires",
@@ -648,7 +655,7 @@ class K extends EventTarget {
648
655
  }
649
656
  }
650
657
  async stopSession() {
651
- this._versionResolve && (this._versionResolve(null), this._versionResolve = null), this._hardwareIdResolve && (this._hardwareIdResolve(null), this._hardwareIdResolve = null), this._volumeResolve && (this._volumeResolve(null), this._volumeResolve = null), this._micVolumeResolve && (this._micVolumeResolve(null), this._micVolumeResolve = null), this._trackedFaceResolve && (this._trackedFaceResolve(null), this._trackedFaceResolve = null), this._applyAudioConfigResolve && (this._applyAudioConfigResolve(!1), this._applyAudioConfigResolve = null), this._readAudioParameterResolve && (this._readAudioParameterResolve(null), this._readAudioParameterResolve = null), this._logSubscribers.clear(), this._updateProgressSubscribers.clear(), this._rejectPendingMotionCompletions(new Error("Session stopped")), this._clearIceGrace(), this._uninstallNetworkListeners(), this._sessionReject && (this._sessionReject(new Error("Session stopped")), this._sessionResolve = null, this._sessionReject = null), this._stateRefreshInterval && (clearInterval(this._stateRefreshInterval), this._stateRefreshInterval = null), this._latencyMonitorId && (clearInterval(this._latencyMonitorId), this._latencyMonitorId = null), this._sessionId && await this._sendToServer({ type: "endSession", sessionId: this._sessionId }), this._micStream && (this._micStream.getTracks().forEach((t) => t.stop()), this._micStream = null), this._micMuted = !0, this._micSupported = !1, this._pc && (this._pc.close(), this._pc = null), this._dc && (this._dc.close(), this._dc = null), this._sessionId = null, this._iceConnected = !1, this._dcOpen = !1, this._state === "streaming" && (this._state = "connected", this._emit("sessionStopped", { reason: "user" }));
658
+ this._versionResolve && (this._versionResolve(null), this._versionResolve = null), this._hardwareIdResolve && (this._hardwareIdResolve(null), this._hardwareIdResolve = null), this._volumeResolve && (this._volumeResolve(null), this._volumeResolve = null), this._micVolumeResolve && (this._micVolumeResolve(null), this._micVolumeResolve = null), this._trackedFaceResolve && (this._trackedFaceResolve(null), this._trackedFaceResolve = null), this._applyAudioConfigResolve && (this._applyAudioConfigResolve(!1), this._applyAudioConfigResolve = null), this._readAudioParameterResolve && (this._readAudioParameterResolve(null), this._readAudioParameterResolve = null), this._logSubscribers.clear(), this._updateProgressSubscribers.clear(), this._rejectPendingMotionCompletions(new Error("Session stopped")), this._rejectPendingRpc(new Error("Session stopped")), this._clearIceGrace(), this._uninstallNetworkListeners(), this._sessionReject && (this._sessionReject(new Error("Session stopped")), this._sessionResolve = null, this._sessionReject = null), this._stateRefreshInterval && (clearInterval(this._stateRefreshInterval), this._stateRefreshInterval = null), this._latencyMonitorId && (clearInterval(this._latencyMonitorId), this._latencyMonitorId = null), this._sessionId && await this._sendToServer({ type: "endSession", sessionId: this._sessionId }), this._micStream && (this._micStream.getTracks().forEach((t) => t.stop()), this._micStream = null), this._micMuted = !0, this._micSupported = !1, this._pc && (this._pc.close(), this._pc = null), this._dc && (this._dc.close(), this._dc = null), this._sessionId = null, this._iceConnected = !1, this._dcOpen = !1, this._state === "streaming" && (this._state = "connected", this._emit("sessionStopped", { reason: "user" }));
652
659
  }
653
660
  disconnect() {
654
661
  this._sseAbortController && (this._sseAbortController.abort(), this._sseAbortController = null), this._versionResolve && (this._versionResolve(null), this._versionResolve = null), this._hardwareIdResolve && (this._hardwareIdResolve(null), this._hardwareIdResolve = null), this._volumeResolve && (this._volumeResolve(null), this._volumeResolve = null), this._micVolumeResolve && (this._micVolumeResolve(null), this._micVolumeResolve = null), this._trackedFaceResolve && (this._trackedFaceResolve(null), this._trackedFaceResolve = null), this._applyAudioConfigResolve && (this._applyAudioConfigResolve(!1), this._applyAudioConfigResolve = null), this._readAudioParameterResolve && (this._readAudioParameterResolve(null), this._readAudioParameterResolve = null), this._logSubscribers.clear(), this._updateProgressSubscribers.clear(), this._rejectPendingMotionCompletions(new Error("Disconnected")), this._clearIceGrace(), this._uninstallNetworkListeners(), this._sessionReject && (this._sessionReject(new Error("Disconnected")), this._sessionResolve = null, this._sessionReject = null), this._stateRefreshInterval && (clearInterval(this._stateRefreshInterval), this._stateRefreshInterval = null), this._latencyMonitorId && (clearInterval(this._latencyMonitorId), this._latencyMonitorId = null), this._sessionId && this._token && this._sendToServer({ type: "endSession", sessionId: this._sessionId }), this._micStream && (this._micStream.getTracks().forEach((e) => e.stop()), this._micStream = null), this._pc && (this._pc.close(), this._pc = null), this._dc && (this._dc.close(), this._dc = null), this._sessionId = null, this._micMuted = !0, this._micSupported = !1, this._iceConnected = !1, this._dcOpen = !1, this._robots = [], this._state = "disconnected", this._emit("disconnected", { reason: "user" });
@@ -1065,7 +1072,12 @@ class K extends EventTarget {
1065
1072
  return;
1066
1073
  }
1067
1074
  const n = e();
1068
- n && n(null), t(i), this._sendCommand(s);
1075
+ n && n(null);
1076
+ let a;
1077
+ const c = (l) => {
1078
+ a !== void 0 && (clearTimeout(a), a = void 0), e() === c && t(null), i(l);
1079
+ };
1080
+ t(c), a = setTimeout(() => c(null), K), this._sendCommand(s);
1069
1081
  });
1070
1082
  }
1071
1083
  sendRaw(e) {
@@ -1148,7 +1160,7 @@ class K extends EventTarget {
1148
1160
  encoding: v
1149
1161
  });
1150
1162
  for (let u = 0; u < g; u++) {
1151
- this._dc.bufferedAmount > A && await this._awaitDataChannelDrain();
1163
+ this._dc.bufferedAmount > E && await this._awaitDataChannelDrain();
1152
1164
  const _ = u * y;
1153
1165
  this._sendCommand({
1154
1166
  type: "upload_move_chunk",
@@ -1158,7 +1170,7 @@ class K extends EventTarget {
1158
1170
  }), l({ phase: "upload", sent: u + 1, total: g });
1159
1171
  }
1160
1172
  if (this._sendCommand({ type: "upload_move_finish", upload_id: d }), l({ phase: "uploaded", sent: g, total: g }), t) {
1161
- const u = new Uint8Array(await t.arrayBuffer()), _ = E(u), b = Math.ceil(_.length / y) || 1;
1173
+ const u = new Uint8Array(await t.arrayBuffer()), _ = A(u), b = Math.ceil(_.length / y) || 1;
1162
1174
  l({
1163
1175
  phase: "audio-starting",
1164
1176
  sent: 0,
@@ -1172,7 +1184,7 @@ class K extends EventTarget {
1172
1184
  description: i
1173
1185
  });
1174
1186
  for (let I = 0; I < b; I++) {
1175
- this._dc.bufferedAmount > A && await this._awaitDataChannelDrain();
1187
+ this._dc.bufferedAmount > E && await this._awaitDataChannelDrain();
1176
1188
  const T = I * y;
1177
1189
  this._sendCommand({
1178
1190
  type: "upload_audio_chunk",
@@ -1231,7 +1243,7 @@ class K extends EventTarget {
1231
1243
  throw new Error("data channel not open");
1232
1244
  if (!(e instanceof Blob))
1233
1245
  throw new TypeError("uploadAudio: expected a Blob");
1234
- const i = U(), o = new Uint8Array(await e.arrayBuffer()), n = E(o), a = Math.ceil(n.length / y) || 1;
1246
+ const i = U(), o = new Uint8Array(await e.arrayBuffer()), n = A(o), a = Math.ceil(n.length / y) || 1;
1235
1247
  s({ phase: "audio-starting", sent: 0, total: a, bytes: n.length }), this._sendCommand({
1236
1248
  type: "upload_audio_start",
1237
1249
  upload_id: i,
@@ -1240,7 +1252,7 @@ class K extends EventTarget {
1240
1252
  description: t
1241
1253
  });
1242
1254
  for (let c = 0; c < a; c++) {
1243
- this._dc.bufferedAmount > A && await this._awaitDataChannelDrain();
1255
+ this._dc.bufferedAmount > E && await this._awaitDataChannelDrain();
1244
1256
  const l = c * y;
1245
1257
  this._sendCommand({
1246
1258
  type: "upload_audio_chunk",
@@ -1318,6 +1330,62 @@ class K extends EventTarget {
1318
1330
  _sendCommand(e) {
1319
1331
  return !this._dc || this._dc.readyState !== "open" ? !1 : (this._dc.send(JSON.stringify(e)), !0);
1320
1332
  }
1333
+ /**
1334
+ * Call a JSON-RPC method on the robot/app over the DataChannel and await
1335
+ * its result. This is the one way to drive an on-robot app (start/stop it
1336
+ * via `apps.*`, or drive a running app via its own namespace, e.g.
1337
+ * `conversation.say`). Rejects on the JSON-RPC error, a closed channel, or
1338
+ * timeout.
1339
+ */
1340
+ rpcCall(e, t = {}, s = {}) {
1341
+ const i = s.timeoutMs ?? 2e4, o = `rpc-${++this._rpcCounter}`;
1342
+ return this._sendCommand({ jsonrpc: "2.0", id: o, method: e, params: t }) ? new Promise((n, a) => {
1343
+ const c = setTimeout(() => {
1344
+ this._pendingRpc.delete(o), a(new Error(`rpcCall(${e}) timed out after ${i}ms`));
1345
+ }, i);
1346
+ this._pendingRpc.set(o, {
1347
+ resolve: (l) => n(l),
1348
+ reject: a,
1349
+ timer: c
1350
+ });
1351
+ }) : Promise.reject(new Error(`rpcCall(${e}): data channel not open`));
1352
+ }
1353
+ /**
1354
+ * Subscribe to a JSON-RPC notification (one-way event) pushed by the
1355
+ * robot/app, e.g. `conversation.turn`. Returns an unsubscribe function.
1356
+ */
1357
+ onNotification(e, t) {
1358
+ let s = this._rpcListeners.get(e);
1359
+ return s || (s = /* @__PURE__ */ new Set(), this._rpcListeners.set(e, s)), s.add(t), () => {
1360
+ this._rpcListeners.get(e)?.delete(t);
1361
+ };
1362
+ }
1363
+ _rejectPendingRpc(e) {
1364
+ for (const t of this._pendingRpc.values())
1365
+ clearTimeout(t.timer), t.reject(e);
1366
+ this._pendingRpc.clear();
1367
+ }
1368
+ _handleRpcMessage(e) {
1369
+ if ("id" in e && e.id != null && ("result" in e || "error" in e)) {
1370
+ const t = this._pendingRpc.get(e.id);
1371
+ if (!t) return;
1372
+ if (this._pendingRpc.delete(e.id), clearTimeout(t.timer), "error" in e && e.error) {
1373
+ const s = e.error, i = new Error(s.message ?? "rpc error");
1374
+ i.reason = s.data?.reason, t.reject(i);
1375
+ } else
1376
+ t.resolve(e.result);
1377
+ return;
1378
+ }
1379
+ if (typeof e.method == "string") {
1380
+ const t = e.params ?? {};
1381
+ for (const s of this._rpcListeners.get(e.method) ?? [])
1382
+ try {
1383
+ s(t);
1384
+ } catch (i) {
1385
+ console.error(`onNotification(${e.method}) threw:`, i);
1386
+ }
1387
+ }
1388
+ }
1321
1389
  _checkSessionReady() {
1322
1390
  this._iceConnected && this._dcOpen && this._sessionResolve && (this._state = "streaming", this.requestState(), this._stateRefreshInterval = setInterval(() => this.requestState(), 500), this._emit("streaming", { sessionId: this._sessionId, robotId: this._selectedRobotId }), this._sessionResolve(), this._sessionResolve = null, this._sessionReject = null);
1323
1391
  }
@@ -1403,6 +1471,10 @@ class K extends EventTarget {
1403
1471
  }
1404
1472
  }
1405
1473
  _handleRobotMessage(e) {
1474
+ if (e.jsonrpc === "2.0") {
1475
+ this._handleRpcMessage(e);
1476
+ return;
1477
+ }
1406
1478
  if ("version" in e && this._versionResolve) {
1407
1479
  this._versionResolve(e.version), this._versionResolve = null;
1408
1480
  return;
@@ -1519,5 +1591,5 @@ class K extends EventTarget {
1519
1591
  }
1520
1592
  }
1521
1593
  export {
1522
- K as R
1594
+ Q as R
1523
1595
  };
@@ -1 +1 @@
1
- {"version":3,"file":"ConnectingView.d.ts","sourceRoot":"","sources":["../../src/components/ConnectingView.tsx"],"names":[],"mappings":"AA6BA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAIjC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AAIzD,MAAM,WAAW,mBAAmB;IAClC,+DAA+D;IAC/D,IAAI,EAAE,iBAAiB,GAAG,IAAI,CAAC;IAC/B;;oCAEgC;IAChC,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CACzB;AAiBD,wBAAgB,cAAc,CAAC,EAC7B,IAAI,EACJ,OAAO,GACR,EAAE,mBAAmB,GAAG,GAAG,CAAC,OAAO,CA6FnC;AAkED,eAAO,MAAM,qBAAqB,qBAAa,CAAC"}
1
+ {"version":3,"file":"ConnectingView.d.ts","sourceRoot":"","sources":["../../src/components/ConnectingView.tsx"],"names":[],"mappings":"AA6BA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAIjC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AAIzD,MAAM,WAAW,mBAAmB;IAClC,+DAA+D;IAC/D,IAAI,EAAE,iBAAiB,GAAG,IAAI,CAAC;IAC/B;;oCAEgC;IAChC,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CACzB;AAiBD,wBAAgB,cAAc,CAAC,EAC7B,IAAI,EACJ,OAAO,GACR,EAAE,mBAAmB,GAAG,GAAG,CAAC,OAAO,CAmGnC;AAkED,eAAO,MAAM,qBAAqB,qBAAa,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"ErrorView.d.ts","sourceRoot":"","sources":["../../src/components/ErrorView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAMjC,MAAM,WAAW,cAAc;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,QAAQ,IAAI,IAAI,CAAC;IACjB,cAAc,IAAI,IAAI,CAAC;CACxB;AAED,wBAAgB,SAAS,CAAC,EACxB,KAA8B,EAC9B,OAAO,EACP,MAAM,EACN,QAAQ,EACR,cAAc,GACf,EAAE,cAAc,GAAG,GAAG,CAAC,OAAO,CA6D9B"}
1
+ {"version":3,"file":"ErrorView.d.ts","sourceRoot":"","sources":["../../src/components/ErrorView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAMjC,MAAM,WAAW,cAAc;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,QAAQ,IAAI,IAAI,CAAC;IACjB,cAAc,IAAI,IAAI,CAAC;CACxB;AAED,wBAAgB,SAAS,CAAC,EACxB,KAA8B,EAC9B,OAAO,EACP,MAAM,EACN,QAAQ,EACR,cAAc,GACf,EAAE,cAAc,GAAG,GAAG,CAAC,OAAO,CA+D9B"}
@@ -1 +1 @@
1
- {"version":3,"file":"LeavingView.d.ts","sourceRoot":"","sources":["../../src/components/LeavingView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAKjC,wBAAgB,WAAW,IAAI,GAAG,CAAC,OAAO,CA2CzC"}
1
+ {"version":3,"file":"LeavingView.d.ts","sourceRoot":"","sources":["../../src/components/LeavingView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAKjC,wBAAgB,WAAW,IAAI,GAAG,CAAC,OAAO,CA+CzC"}
@@ -1 +1 @@
1
- {"version":3,"file":"PickerView.d.ts","sourceRoot":"","sources":["../../src/components/PickerView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAkBjC,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAIlD,MAAM,WAAW,eAAe;IAC9B,MAAM,EAAE,SAAS,EAAE,CAAC;IACpB;uEACmE;IACnE,YAAY,EAAE,OAAO,CAAC;IACtB;;;+BAG2B;IAC3B,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,kBAAkB,EAAE,MAAM,GAAG,IAAI,CAAC;IAClC,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC;;mDAE+C;IAC/C,SAAS,CAAC,IAAI,IAAI,CAAC;CACpB;AAED,wBAAgB,UAAU,CAAC,EACzB,MAAM,EACN,YAAY,EACZ,KAAK,EACL,kBAAkB,EAClB,QAAQ,EACR,SAAS,GACV,EAAE,eAAe,GAAG,GAAG,CAAC,OAAO,CAiF/B"}
1
+ {"version":3,"file":"PickerView.d.ts","sourceRoot":"","sources":["../../src/components/PickerView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAkBjC,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAIlD,MAAM,WAAW,eAAe;IAC9B,MAAM,EAAE,SAAS,EAAE,CAAC;IACpB;uEACmE;IACnE,YAAY,EAAE,OAAO,CAAC;IACtB;;;+BAG2B;IAC3B,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,kBAAkB,EAAE,MAAM,GAAG,IAAI,CAAC;IAClC,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC;;mDAE+C;IAC/C,SAAS,CAAC,IAAI,IAAI,CAAC;CACpB;AAED,wBAAgB,UAAU,CAAC,EACzB,MAAM,EACN,YAAY,EACZ,KAAK,EACL,kBAAkB,EAClB,QAAQ,EACR,SAAS,GACV,EAAE,eAAe,GAAG,GAAG,CAAC,OAAO,CAkF/B"}
@@ -1 +1 @@
1
- {"version":3,"file":"PostOAuthSplash.d.ts","sourceRoot":"","sources":["../../src/components/PostOAuthSplash.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AA6BjC,wBAAgB,eAAe,IAAI,GAAG,CAAC,OAAO,CAsD7C"}
1
+ {"version":3,"file":"PostOAuthSplash.d.ts","sourceRoot":"","sources":["../../src/components/PostOAuthSplash.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AA6BjC,wBAAgB,eAAe,IAAI,GAAG,CAAC,OAAO,CAuD7C"}
@@ -1 +1 @@
1
- {"version":3,"file":"TopBar.d.ts","sourceRoot":"","sources":["../../src/components/TopBar.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,OAAO,EAAuB,KAAK,GAAG,EAAE,MAAM,OAAO,CAAC;AAsBtD,MAAM,MAAM,SAAS,GACjB,YAAY,GACZ,SAAS,GACT,UAAU,GACV,SAAS,GACT,OAAO,CAAC;AAEZ,MAAM,WAAW,WAAW;IAC1B,OAAO,EAAE,MAAM,CAAC;IAChB;+CAC2C;IAC3C,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B;kDAC8C;IAC9C,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,SAAS,EAAE,SAAS,CAAC;IACrB,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB;wEACoE;IACpE,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,iBAAiB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAClC;;sDAEkD;IAClD,sBAAsB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACvC;qEACiE;IACjE,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,SAAS,IAAI,IAAI,CAAC;IAClB,YAAY,IAAI,IAAI,CAAC;CACtB;AAED,wBAAgB,MAAM,CAAC,EACrB,OAAO,EACP,UAAiB,EACjB,QAAe,EACf,SAAS,EACT,QAAQ,EACR,SAAgB,EAChB,iBAAwB,EACxB,sBAA6B,EAC7B,SAAgB,EAChB,SAAS,EACT,YAAY,GACb,EAAE,WAAW,GAAG,GAAG,CAAC,OAAO,CAwJ3B"}
1
+ {"version":3,"file":"TopBar.d.ts","sourceRoot":"","sources":["../../src/components/TopBar.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,OAAO,EAAuB,KAAK,GAAG,EAAE,MAAM,OAAO,CAAC;AAsBtD,MAAM,MAAM,SAAS,GACjB,YAAY,GACZ,SAAS,GACT,UAAU,GACV,SAAS,GACT,OAAO,CAAC;AAEZ,MAAM,WAAW,WAAW;IAC1B,OAAO,EAAE,MAAM,CAAC;IAChB;+CAC2C;IAC3C,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B;kDAC8C;IAC9C,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,SAAS,EAAE,SAAS,CAAC;IACrB,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB;wEACoE;IACpE,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,iBAAiB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAClC;;sDAEkD;IAClD,sBAAsB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACvC;qEACiE;IACjE,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,SAAS,IAAI,IAAI,CAAC;IAClB,YAAY,IAAI,IAAI,CAAC;CACtB;AAED,wBAAgB,MAAM,CAAC,EACrB,OAAO,EACP,UAAiB,EACjB,QAAe,EACf,SAAS,EACT,QAAQ,EACR,SAAgB,EAChB,iBAAwB,EACxB,sBAA6B,EAC7B,SAAgB,EAChB,SAAS,EACT,YAAY,GACb,EAAE,WAAW,GAAG,GAAG,CAAC,OAAO,CAuJ3B"}
@@ -1 +1 @@
1
- {"version":3,"file":"WelcomeBackOverlay.d.ts","sourceRoot":"","sources":["../../src/components/WelcomeBackOverlay.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAsCjC,MAAM,WAAW,uBAAuB;IACtC,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,MAAM,IAAI,IAAI,CAAC;CAChB;AAED,wBAAgB,kBAAkB,CAAC,EACjC,QAAQ,EACR,MAAM,GACP,EAAE,uBAAuB,GAAG,GAAG,CAAC,OAAO,CAuFvC"}
1
+ {"version":3,"file":"WelcomeBackOverlay.d.ts","sourceRoot":"","sources":["../../src/components/WelcomeBackOverlay.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAsCjC,MAAM,WAAW,uBAAuB;IACtC,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,MAAM,IAAI,IAAI,CAAC;CAChB;AAED,wBAAgB,kBAAkB,CAAC,EACjC,QAAQ,EACR,MAAM,GACP,EAAE,uBAAuB,GAAG,GAAG,CAAC,OAAO,CAwFvC"}
@@ -1,5 +1,5 @@
1
- import { R as i } from "../chunks/reachy-mini-CdsdQLIU.js";
2
- import { m as n } from "../chunks/mountHost-DjE5zE9R.js";
1
+ import { R as i } from "../chunks/reachy-mini-DJD3mwi2.js";
2
+ import { m as n } from "../chunks/mountHost-DztGlWwu.js";
3
3
  typeof window < "u" && (window.ReachyMini || (window.ReachyMini = i, window.dispatchEvent(new Event("reachymini:ready"))), window.ReachyMiniHost = { mountHost: n });
4
4
  export {
5
5
  n as mountHost
@@ -1,4 +1,4 @@
1
- import { R as i } from "../chunks/reachy-mini-CdsdQLIU.js";
1
+ import { R as i } from "../chunks/reachy-mini-DJD3mwi2.js";
2
2
  import { c as n } from "../chunks/index-lMs2sCXG.js";
3
3
  typeof window < "u" && (window.ReachyMini || (window.ReachyMini = i, window.dispatchEvent(new Event("reachymini:ready"))), window.ReachyMiniHostEmbed = { connectToHost: n });
4
4
  export {
@@ -1,5 +1,5 @@
1
- import { R as o } from "./chunks/reachy-mini-CdsdQLIU.js";
2
- import { R as s, m as a } from "./chunks/mountHost-DjE5zE9R.js";
1
+ import { R as o } from "./chunks/reachy-mini-DJD3mwi2.js";
2
+ import { R as s, m as a } from "./chunks/mountHost-DztGlWwu.js";
3
3
  import { c as t } from "./chunks/index-lMs2sCXG.js";
4
4
  import { PROTOCOL_VERSION as c, decodeCredsFromHash as m, encodeCredsToHash as w, isProtocolMessage as h } from "./lib/protocol.js";
5
5
  typeof window < "u" && !window.ReachyMini && (window.ReachyMini = o, window.dispatchEvent(new Event("reachymini:ready")));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pollen-robotics/reachy-mini-sdk",
3
- "version": "1.9.0",
3
+ "version": "1.10.0-dev.0.main.05ce680",
4
4
  "description": "Browser SDK for controlling a Reachy Mini robot over WebRTC, plus an optional Hugging Face Spaces host shell (OAuth + robot picker + iframe bridge) exposed via the ./host subpath.",
5
5
  "type": "module",
6
6
  "main": "./dist/reachy-mini-sdk.js",
@@ -59,8 +59,8 @@
59
59
  "@emotion/react": "^11.14.0",
60
60
  "@emotion/styled": "^11.14.1",
61
61
  "@huggingface/hub": "^0.15.2",
62
- "@mui/icons-material": "^7.3.5",
63
- "@mui/material": "^7.3.5"
62
+ "@mui/icons-material": "^9.0.0",
63
+ "@mui/material": "^9.0.0"
64
64
  },
65
65
  "peerDependencies": {
66
66
  "react": "^18.0.0 || ^19.0.0",