@seamapi/react 1.9.1 → 1.10.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.
package/dist/elements.js CHANGED
@@ -8077,7 +8077,7 @@ const mm = "https://fonts.googleapis.com/css2?family=Source+Sans+Pro:wght@400;60
8077
8077
  const n = globalThis.document.createElement("link");
8078
8078
  n.rel = "stylesheet", n.type = "text/css", n.href = mm, globalThis.document.head.appendChild(n);
8079
8079
  }, [t]);
8080
- }, NE = "1.9.1", HE = "https://react.seam.co", DE = ({
8080
+ }, NE = "1.10.0", HE = "https://react.seam.co", DE = ({
8081
8081
  disabled: t = !1,
8082
8082
  unminified: e = !1
8083
8083
  }) => {
@@ -24591,50 +24591,53 @@ function yT(t) {
24591
24591
  return { ...i, devices: r };
24592
24592
  }
24593
24593
  function gT({
24594
- onBack: t,
24595
- className: e
24594
+ deviceIds: t,
24595
+ onBack: e,
24596
+ className: n
24596
24597
  } = {}) {
24597
- const { devices: n, isLoading: r, isError: i, error: o } = yT(), [s, l] = k.useState(null), [c, a] = k.useState("");
24598
- if (s != null)
24598
+ const { devices: r, isLoading: i, isError: o, error: s } = yT({
24599
+ device_ids: t
24600
+ }), [l, c] = k.useState(null), [a, u] = k.useState("");
24601
+ if (l != null)
24599
24602
  return /* @__PURE__ */ v.jsx(
24600
24603
  Wf,
24601
24604
  {
24602
- className: e,
24603
- deviceId: s,
24605
+ className: n,
24606
+ deviceId: l,
24604
24607
  onBack: () => {
24605
- l(null);
24608
+ c(null);
24606
24609
  }
24607
24610
  }
24608
24611
  );
24609
- if (r)
24610
- return /* @__PURE__ */ v.jsx("p", { className: e, children: "..." });
24611
24612
  if (i)
24612
- return /* @__PURE__ */ v.jsx("p", { className: e, children: o == null ? void 0 : o.message });
24613
- if (n == null)
24613
+ return /* @__PURE__ */ v.jsx("p", { className: n, children: "..." });
24614
+ if (o)
24615
+ return /* @__PURE__ */ v.jsx("p", { className: n, children: s == null ? void 0 : s.message });
24616
+ if (r == null)
24614
24617
  return null;
24615
- const u = n.length, p = n.filter((d) => c === "" ? !0 : new RegExp(c, "i").test(d.properties.name));
24616
- return /* @__PURE__ */ v.jsxs("div", { className: Re("seam-device-table", e), children: [
24617
- /* @__PURE__ */ v.jsx(nd, { onBack: t }),
24618
+ const p = r.length, d = r.filter((f) => a === "" ? !0 : new RegExp(a, "i").test(f.properties.name));
24619
+ return /* @__PURE__ */ v.jsxs("div", { className: Re("seam-device-table", n), children: [
24620
+ /* @__PURE__ */ v.jsx(nd, { onBack: e }),
24618
24621
  /* @__PURE__ */ v.jsxs(x1, { children: [
24619
24622
  /* @__PURE__ */ v.jsxs(T1, { children: [
24620
24623
  N1.devices,
24621
24624
  " ",
24622
24625
  /* @__PURE__ */ v.jsxs(j1, { children: [
24623
24626
  "(",
24624
- u,
24627
+ p,
24625
24628
  ")"
24626
24629
  ] })
24627
24630
  ] }),
24628
24631
  /* @__PURE__ */ v.jsx(
24629
24632
  Qf,
24630
24633
  {
24631
- value: c,
24632
- onChange: a,
24633
- disabled: u === 0
24634
+ value: a,
24635
+ onChange: u,
24636
+ disabled: p === 0
24634
24637
  }
24635
24638
  )
24636
24639
  ] }),
24637
- /* @__PURE__ */ v.jsx(C1, { children: /* @__PURE__ */ v.jsx(vT, { devices: p, selectDevice: l }) })
24640
+ /* @__PURE__ */ v.jsx(C1, { children: /* @__PURE__ */ v.jsx(vT, { devices: d, selectDevice: c }) })
24638
24641
  ] });
24639
24642
  }
24640
24643
  function vT(t) {