@genai-fi/base 4.1.0 → 4.1.2
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/{DialogQR-C2SNQ9Uf.js → DialogQR-BIfoHwVy.js} +3 -2
- package/dist/{SvgLayer-BWQvvvqo.js → SvgLayer-DHFiKVQ9.js} +12 -12
- package/dist/components/QRCode/DialogQR.js +3 -2
- package/dist/components/QRCode/QRCode.js +1 -1
- package/dist/components/WorkflowLayout/Layout.js +30 -29
- package/dist/components/WorkflowLayout/SvgLayer.d.ts +1 -0
- package/dist/components/WorkflowLayout/SvgLayer.js +1 -1
- package/dist/components/WorkflowLayout/Widget.d.ts +2 -1
- package/dist/components/WorkflowLayout/Widget.js +1079 -1074
- package/dist/components/WorkflowLayout/index.js +1 -1
- package/dist/components/WorkflowLayout/lines.d.ts +1 -0
- package/dist/components/WorkflowLayout/lines.js +23 -22
- package/dist/components/WorkflowLayout/svgContext.d.ts +2 -0
- package/dist/components/WorkflowLayout/svgContext.js +11 -0
- package/dist/main.js +1 -1
- package/package.json +1 -1
|
@@ -13,6 +13,7 @@ import "./util/canvas.js";
|
|
|
13
13
|
import "./FileSaver.min-DhePf63e.js";
|
|
14
14
|
import "./components/BusyButton/BusyButton.js";
|
|
15
15
|
import "./components/WorkflowLayout/lines.js";
|
|
16
|
+
import "./components/WorkflowLayout/svgContext.js";
|
|
16
17
|
import "./components/WorkflowLayout/Widget.js";
|
|
17
18
|
import "./components/IconMenu/context.js";
|
|
18
19
|
import "@emotion/react";
|
|
@@ -1568,7 +1569,7 @@ const ze = /* @__PURE__ */ le(ke), Ve = "_link_1udre_3", He = "_container_1udre_
|
|
|
1568
1569
|
}, Ye = me(/* @__PURE__ */ U("path", {
|
|
1569
1570
|
d: "M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2m0 16H8V7h11z"
|
|
1570
1571
|
}), "ContentCopy");
|
|
1571
|
-
function
|
|
1572
|
+
function dn({ url: r, open: o, onClose: i }) {
|
|
1572
1573
|
var s;
|
|
1573
1574
|
const { t: n } = he("translation"), t = ue(null), e = ae(() => {
|
|
1574
1575
|
navigator.clipboard.writeText(r);
|
|
@@ -1625,7 +1626,7 @@ function fn({ url: r, open: o, onClose: i }) {
|
|
|
1625
1626
|
);
|
|
1626
1627
|
}
|
|
1627
1628
|
export {
|
|
1628
|
-
|
|
1629
|
+
dn as D,
|
|
1629
1630
|
ze as q,
|
|
1630
1631
|
je as s
|
|
1631
1632
|
};
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import { jsx as o, jsxs as g } from "react/jsx-runtime";
|
|
2
|
-
import './assets/SvgLayer.css';const
|
|
3
|
-
svglayer:
|
|
4
|
-
workspace:
|
|
2
|
+
import './assets/SvgLayer.css';const x = "_svglayer_qfgw7_3", i = "_workspace_qfgw7_10", w = "_container_qfgw7_19", _ = "_annotation_qfgw7_48", d = {
|
|
3
|
+
svglayer: x,
|
|
4
|
+
workspace: i,
|
|
5
5
|
container: w,
|
|
6
6
|
annotation: _
|
|
7
|
-
},
|
|
8
|
-
function $({ lines:
|
|
7
|
+
}, y = 0.4, s = 40;
|
|
8
|
+
function $({ lines: e }) {
|
|
9
9
|
return /* @__PURE__ */ o(
|
|
10
10
|
"svg",
|
|
11
11
|
{
|
|
12
|
-
className:
|
|
12
|
+
className: d.svglayer,
|
|
13
13
|
xmlns: "http://www.w3.org/2000/svg",
|
|
14
14
|
width: "100%",
|
|
15
15
|
height: "100%",
|
|
16
16
|
"aria-hidden": !0,
|
|
17
|
-
children:
|
|
18
|
-
const n = t.direction === "horizontal" ? Math.abs(t.x1 - t.x2) *
|
|
17
|
+
children: e.map((t, r) => {
|
|
18
|
+
const n = t.direction === "horizontal" ? Math.abs(t.x1 - t.x2) * y : 0, c = t.direction === "vertical" ? Math.abs(t.y1 - t.y2) * y : 0, a = Math.max(Math.abs(t.x1 - t.x2), Math.abs(t.y1 - t.y2)), h = t.active;
|
|
19
19
|
return /* @__PURE__ */ g("g", { children: [
|
|
20
20
|
/* @__PURE__ */ o(
|
|
21
21
|
"path",
|
|
@@ -23,9 +23,9 @@ function $({ lines: y }) {
|
|
|
23
23
|
"data-testid": `line-${t.id1}-${t.id2}`,
|
|
24
24
|
d: `M ${t.x1} ${t.y1} C ${t.x1 + n} ${t.y1 + c}, ${t.x2 - n} ${t.y2 - c}, ${t.x2} ${t.y2}`,
|
|
25
25
|
fill: "none",
|
|
26
|
-
stroke: "rgb(174, 37, 174)",
|
|
26
|
+
stroke: h ? "rgb(174, 37, 174)" : "#7C828D",
|
|
27
27
|
strokeWidth: "2",
|
|
28
|
-
strokeDasharray: void 0
|
|
28
|
+
strokeDasharray: h ? void 0 : "4 4"
|
|
29
29
|
},
|
|
30
30
|
r
|
|
31
31
|
),
|
|
@@ -36,7 +36,7 @@ function $({ lines: y }) {
|
|
|
36
36
|
y: (t.y1 + t.y2) / 2 - (a - s) / 2,
|
|
37
37
|
width: a - s,
|
|
38
38
|
height: a - s,
|
|
39
|
-
children: /* @__PURE__ */ o("div", { className:
|
|
39
|
+
children: /* @__PURE__ */ o("div", { className: d.annotation, children: t.annotationElement })
|
|
40
40
|
}
|
|
41
41
|
)
|
|
42
42
|
] }, `annotation-${r}`);
|
|
@@ -46,5 +46,5 @@ function $({ lines: y }) {
|
|
|
46
46
|
}
|
|
47
47
|
export {
|
|
48
48
|
$ as S,
|
|
49
|
-
|
|
49
|
+
d as s
|
|
50
50
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
|
-
import { D as
|
|
3
|
+
import { D as j } from "../../DialogQR-BIfoHwVy.js";
|
|
4
4
|
import "@mui/material";
|
|
5
5
|
import "react-i18next";
|
|
6
6
|
import "../../state/webrtcState.js";
|
|
@@ -12,9 +12,10 @@ import "../../util/canvas.js";
|
|
|
12
12
|
import "../../FileSaver.min-DhePf63e.js";
|
|
13
13
|
import "../BusyButton/BusyButton.js";
|
|
14
14
|
import "../WorkflowLayout/lines.js";
|
|
15
|
+
import "../WorkflowLayout/svgContext.js";
|
|
15
16
|
import "../WorkflowLayout/Widget.js";
|
|
16
17
|
import "../IconMenu/context.js";
|
|
17
18
|
import "@emotion/react";
|
|
18
19
|
export {
|
|
19
|
-
|
|
20
|
+
j as default
|
|
20
21
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as i, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { useRef as h, useState as m, useEffect as u, Suspense as v } from "react";
|
|
3
|
-
import { q as p, s as o, D as b } from "../../DialogQR-
|
|
3
|
+
import { q as p, s as o, D as b } from "../../DialogQR-BIfoHwVy.js";
|
|
4
4
|
function q({ url: a, size: r, code: c, label: l, dialog: d }) {
|
|
5
5
|
const t = h(null), [f, n] = m(!1);
|
|
6
6
|
return u(() => {
|
|
@@ -1,44 +1,45 @@
|
|
|
1
|
-
import { jsx as a, jsxs as
|
|
2
|
-
import { useState as
|
|
3
|
-
import { extractNodesFromElements as y, generateLines as
|
|
4
|
-
import { s as u, S as
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
1
|
+
import { jsx as a, jsxs as p } from "react/jsx-runtime";
|
|
2
|
+
import { useState as v, useRef as l, useCallback as h, useEffect as x } from "react";
|
|
3
|
+
import { extractNodesFromElements as y, generateLines as L } from "./lines.js";
|
|
4
|
+
import { s as u, S as b } from "../../SvgLayer-DHFiKVQ9.js";
|
|
5
|
+
import { LinesUpdateContext as g } from "./svgContext.js";
|
|
6
|
+
function S({ children: o, connections: c }) {
|
|
7
|
+
const [f, m] = v([]), e = l(null), n = l(), i = h(() => {
|
|
8
|
+
const r = y(e.current), s = L(r, c);
|
|
9
|
+
m(s);
|
|
10
|
+
}, [c]);
|
|
11
|
+
return x(() => {
|
|
12
|
+
if (e.current) {
|
|
13
|
+
const r = () => {
|
|
14
|
+
e.current && i();
|
|
14
15
|
};
|
|
15
|
-
|
|
16
|
-
const
|
|
17
|
-
if (
|
|
18
|
-
for (let
|
|
19
|
-
const
|
|
20
|
-
|
|
16
|
+
n.current = new ResizeObserver(r), n.current.observe(e.current);
|
|
17
|
+
const s = e.current.children;
|
|
18
|
+
if (s)
|
|
19
|
+
for (let t = 0; t < s.length; ++t) {
|
|
20
|
+
const d = s[t];
|
|
21
|
+
n.current.observe(d);
|
|
21
22
|
}
|
|
22
|
-
return
|
|
23
|
-
var
|
|
24
|
-
(
|
|
23
|
+
return r(), () => {
|
|
24
|
+
var t;
|
|
25
|
+
(t = n.current) == null || t.disconnect();
|
|
25
26
|
};
|
|
26
27
|
}
|
|
27
|
-
}, [i]), /* @__PURE__ */ a("div", { className: u.workspace, children: /* @__PURE__ */
|
|
28
|
+
}, [c, i]), /* @__PURE__ */ a("div", { className: u.workspace, children: /* @__PURE__ */ a(g.Provider, { value: i, children: /* @__PURE__ */ p(
|
|
28
29
|
"div",
|
|
29
30
|
{
|
|
30
31
|
className: u.container,
|
|
31
|
-
ref:
|
|
32
|
+
ref: e,
|
|
32
33
|
style: {
|
|
33
|
-
gridTemplateColumns: `repeat(${Array.isArray(
|
|
34
|
+
gridTemplateColumns: `repeat(${Array.isArray(o) ? o.filter((r) => !!r).length : 1}, max-content)`
|
|
34
35
|
},
|
|
35
36
|
children: [
|
|
36
|
-
/* @__PURE__ */ a(
|
|
37
|
-
|
|
37
|
+
/* @__PURE__ */ a(b, { lines: f }),
|
|
38
|
+
o
|
|
38
39
|
]
|
|
39
40
|
}
|
|
40
|
-
) });
|
|
41
|
+
) }) });
|
|
41
42
|
}
|
|
42
43
|
export {
|
|
43
|
-
|
|
44
|
+
S as default
|
|
44
45
|
};
|
|
@@ -10,10 +10,11 @@ interface Props extends React.HTMLProps<HTMLDivElement> {
|
|
|
10
10
|
dataWidget?: string;
|
|
11
11
|
'aria-label'?: string;
|
|
12
12
|
active?: boolean;
|
|
13
|
+
activated?: boolean;
|
|
13
14
|
id?: string;
|
|
14
15
|
noPadding?: boolean;
|
|
15
16
|
contentStyle?: CSSProperties;
|
|
16
17
|
headerColour?: string;
|
|
17
18
|
}
|
|
18
|
-
export declare function Widget({ disabled, focus, title, setTitle, children, menu, className, hidden, dataWidget, id, noPadding, active, contentStyle, headerColour, ...props }: Props): import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export declare function Widget({ disabled, focus, title, setTitle, children, menu, className, hidden, dataWidget, id, noPadding, active, activated, contentStyle, headerColour, ...props }: Props): import("react/jsx-runtime").JSX.Element;
|
|
19
20
|
export {};
|