@genai-fi/base 4.3.7 → 4.3.8

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.
Files changed (48) hide show
  1. package/dist/{Button-BgSe1MyE.js → Button-HlUfDiMM.js} +3 -3
  2. package/dist/{CircularProgress-DgKnRiq7.js → CircularProgress-DZ8YZ0Dt.js} +345 -310
  3. package/dist/{Close-Cv_QwhIN.js → Close-TS8H1lQg.js} +1 -1
  4. package/dist/{DefaultPropsProvider-BurgXZzw.js → DefaultPropsProvider-B_x1hwuY.js} +2 -2
  5. package/dist/{DialogQR-DoM8ZHBM.js → DialogQR-ByOert0g.js} +4 -4
  6. package/dist/{FileSaver.min-DhePf63e.js → FileSaver.min-CDwyANUI.js} +57 -57
  7. package/dist/{FlashWifi-slUpI7sB.js → FlashWifi-CNanHNye.js} +1 -1
  8. package/dist/{Portal-MiwrHMB_.js → Portal-BdRLJx1y.js} +140 -133
  9. package/dist/assets/SidePanel.css +1 -1
  10. package/dist/assets/SvgLayer.css +1 -1
  11. package/dist/assets/Widget.css +1 -1
  12. package/dist/{browser-HW-wgeM2.js → browser-DWbgwj89.js} +421 -451
  13. package/dist/components/AlertPara/AlertPara.js +1 -1
  14. package/dist/components/Application/Application.js +724 -689
  15. package/dist/components/BusyButton/BusyButton.d.ts +4 -4
  16. package/dist/components/BusyButton/BusyButton.js +1 -1
  17. package/dist/components/Button/Button.js +2 -2
  18. package/dist/components/ConnectionStatus/ConnectionStatus.js +3 -3
  19. package/dist/components/ConnectionStatus/FlashWifi.js +1 -1
  20. package/dist/components/Feedback/Feedback.js +4 -4
  21. package/dist/components/Feedback/Rating.js +1 -1
  22. package/dist/components/Help/Help.js +5 -5
  23. package/dist/components/LangSelect/LangSelect.js +1 -1
  24. package/dist/components/Motd/Motd.js +1 -1
  25. package/dist/components/PieScore/PieScore.js +9609 -6092
  26. package/dist/components/QRCode/DialogQR.js +4 -4
  27. package/dist/components/QRCode/QRCode.js +2 -2
  28. package/dist/components/SidePanel/SidePanel.d.ts +2 -1
  29. package/dist/components/SidePanel/SidePanel.js +107 -89
  30. package/dist/components/Webcam/Webcam.js +3 -3
  31. package/dist/components/WorkflowLayout/Widget.js +1460 -1438
  32. package/dist/{createSvgIcon-BM4dw4Lw.js → createSvgIcon-DjQWJ3wn.js} +2 -2
  33. package/dist/{createTheme-DV959X3d.js → createTheme-DnBeI7Zz.js} +752 -749
  34. package/dist/hooks/peer.js +1 -1
  35. package/dist/{index-SOhdqzHq.js → index-B_zFkp-8.js} +2 -2
  36. package/dist/react-CiLnfHJp.js +140 -0
  37. package/dist/services/peer2peer/Incoming.js +1 -1
  38. package/dist/services/peer2peer/Outgoing.js +1 -1
  39. package/dist/services/peer2peer/Peer2Peer.js +538 -541
  40. package/dist/services/peer2peer/PeerConnection.js +1 -1
  41. package/dist/state/webrtcState.js +1 -1
  42. package/dist/style/theme.js +1 -1
  43. package/dist/util/Observer.js +1 -1
  44. package/dist/util/zip.js +1 -1
  45. package/dist/vanilla-OLGM3aAq.js +439 -0
  46. package/package.json +3 -3
  47. package/dist/react-B9NW8BS7.js +0 -112
  48. package/dist/vanilla-BJxibF1U.js +0 -404
@@ -2,7 +2,7 @@ import { jsx as B } from "react/jsx-runtime";
2
2
  import { createContext as F, useState as y, useRef as p, useEffect as c, useContext as i } from "react";
3
3
  import { iceConfig as E, webrtcActive as O } from "../state/webrtcState.js";
4
4
  import R from "../services/peer2peer/Peer2Peer.js";
5
- import { a as T, u as V } from "../react-B9NW8BS7.js";
5
+ import { a as T, u as V } from "../react-CiLnfHJp.js";
6
6
  const f = F(null), G = f.Provider;
7
7
  function Q({
8
8
  children: e,
@@ -1,7 +1,7 @@
1
1
  import { g as L } from "./_commonjsHelpers-DaMA6jEr.js";
2
2
  var x = { exports: {} }, E;
3
3
  function C() {
4
- return E || (E = 1, function(g) {
4
+ return E || (E = 1, (function(g) {
5
5
  var w = Object.prototype.hasOwnProperty, c = "~";
6
6
  function h() {
7
7
  }
@@ -104,7 +104,7 @@ function C() {
104
104
  var n;
105
105
  return t ? (n = c ? c + t : t, this._events[n] && y(this, n)) : (this._events = new h(), this._eventsCount = 0), this;
106
106
  }, f.prototype.off = f.prototype.removeListener, f.prototype.addListener = f.prototype.on, f.prefixed = c, f.EventEmitter = f, g.exports = f;
107
- }(x)), x.exports;
107
+ })(x)), x.exports;
108
108
  }
109
109
  var O = C();
110
110
  const k = /* @__PURE__ */ L(O);
@@ -0,0 +1,140 @@
1
+ import A, { useRef as V, createElement as y, useReducer as _, useEffect as R, useDebugValue as k, createContext as C, useCallback as E, useContext as m } from "react";
2
+ import { c as x, g as D, b as B } from "./vanilla-OLGM3aAq.js";
3
+ const F = {}, v = C(
4
+ void 0
5
+ );
6
+ function S(e) {
7
+ return m(v) || D();
8
+ }
9
+ function H({
10
+ children: e,
11
+ store: n
12
+ }) {
13
+ const o = V(null);
14
+ return n ? y(v.Provider, { value: n }, e) : (o.current === null && (o.current = x()), y(
15
+ v.Provider,
16
+ {
17
+ // TODO: If this is not a false positive, consider using useState instead of useRef like https://github.com/pmndrs/jotai/pull/2771
18
+ // eslint-disable-next-line react-hooks/refs
19
+ value: o.current
20
+ },
21
+ e
22
+ ));
23
+ }
24
+ const h = (e) => typeof (e == null ? void 0 : e.then) == "function", w = (e) => {
25
+ e.status || (e.status = "pending", e.then(
26
+ (n) => {
27
+ e.status = "fulfilled", e.value = n;
28
+ },
29
+ (n) => {
30
+ e.status = "rejected", e.reason = n;
31
+ }
32
+ ));
33
+ }, j = A.use || // A shim for older React versions
34
+ ((e) => {
35
+ if (e.status === "pending")
36
+ throw e;
37
+ if (e.status === "fulfilled")
38
+ return e.value;
39
+ throw e.status === "rejected" ? e.reason : (w(e), e);
40
+ }), b = /* @__PURE__ */ new WeakMap(), P = (e, n, o) => {
41
+ const t = B(e)[26];
42
+ let a = b.get(n);
43
+ return a || (a = new Promise((f, d) => {
44
+ let c = n;
45
+ const l = (u) => (g) => {
46
+ c === u && f(g);
47
+ }, s = (u) => (g) => {
48
+ c === u && d(g);
49
+ }, r = () => {
50
+ try {
51
+ const u = o();
52
+ h(u) ? (b.set(u, a), c = u, u.then(l(u), s(u)), t(e, u, r)) : f(u);
53
+ } catch (u) {
54
+ d(u);
55
+ }
56
+ };
57
+ n.then(l(n), s(n)), t(e, n, r);
58
+ }), b.set(n, a)), a;
59
+ };
60
+ function M(e, n) {
61
+ const { delay: o, unstable_promiseStatus: i = !A.use } = {}, t = S(), [[a, f, d], c] = _(
62
+ (s) => {
63
+ const r = t.get(e);
64
+ return Object.is(s[0], r) && s[1] === t && s[2] === e ? s : [r, t, e];
65
+ },
66
+ void 0,
67
+ () => [t.get(e), t, e]
68
+ );
69
+ let l = a;
70
+ if ((f !== t || d !== e) && (c(), l = t.get(e)), R(() => {
71
+ const s = t.sub(e, () => {
72
+ if (i)
73
+ try {
74
+ const r = t.get(e);
75
+ h(r) && w(
76
+ P(t, r, () => t.get(e))
77
+ );
78
+ } catch {
79
+ }
80
+ if (typeof o == "number") {
81
+ console.warn(`[DEPRECATED] delay option is deprecated and will be removed in v3.
82
+
83
+ Migration guide:
84
+
85
+ Create a custom hook like the following.
86
+
87
+ function useAtomValueWithDelay<Value>(
88
+ atom: Atom<Value>,
89
+ options: { delay: number },
90
+ ): Value {
91
+ const { delay } = options
92
+ const store = useStore(options)
93
+ const [value, setValue] = useState(() => store.get(atom))
94
+ useEffect(() => {
95
+ const unsub = store.sub(atom, () => {
96
+ setTimeout(() => setValue(store.get(atom)), delay)
97
+ })
98
+ return unsub
99
+ }, [store, atom, delay])
100
+ return value
101
+ }
102
+ `), setTimeout(c, o);
103
+ return;
104
+ }
105
+ c();
106
+ });
107
+ return c(), s;
108
+ }, [t, e, o, i]), k(l), h(l)) {
109
+ const s = P(
110
+ t,
111
+ l,
112
+ () => t.get(e)
113
+ );
114
+ return i && w(s), j(s);
115
+ }
116
+ return l;
117
+ }
118
+ function T(e, n) {
119
+ const o = S();
120
+ return E(
121
+ (...t) => {
122
+ if ((F ? "production" : void 0) !== "production" && !("write" in e))
123
+ throw new Error("not writable atom");
124
+ return o.set(e, ...t);
125
+ },
126
+ [o, e]
127
+ );
128
+ }
129
+ function L(e, n) {
130
+ return [
131
+ M(e),
132
+ // We do wrong type assertion here, which results in throwing an error.
133
+ T(e)
134
+ ];
135
+ }
136
+ export {
137
+ H as P,
138
+ L as a,
139
+ M as u
140
+ };
@@ -1,7 +1,7 @@
1
1
  var s = Object.defineProperty;
2
2
  var i = (n, e, t) => e in n ? s(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t;
3
3
  var o = (n, e, t) => i(n, typeof e != "symbol" ? e + "" : e, t);
4
- import { E as c } from "../../index-SOhdqzHq.js";
4
+ import { E as c } from "../../index-B_zFkp-8.js";
5
5
  function r(n) {
6
6
  return typeof n.event == "string";
7
7
  }
@@ -1,7 +1,7 @@
1
1
  var s = Object.defineProperty;
2
2
  var c = (i, o, t) => o in i ? s(i, o, { enumerable: !0, configurable: !0, writable: !0, value: t }) : i[o] = t;
3
3
  var n = (i, o, t) => c(i, typeof o != "symbol" ? o + "" : o, t);
4
- import { E as r } from "../../index-SOhdqzHq.js";
4
+ import { E as r } from "../../index-B_zFkp-8.js";
5
5
  import h from "./PeerConnection.js";
6
6
  import { expBackoff as a } from "../../util/backoff.js";
7
7
  function u(i) {