@octaviaflow/core 3.1.0-beta.100 → 3.1.0-beta.101
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/styles.css +1 -1
- package/dist/workflow/components/FxPanel/FxPanel.d.ts.map +1 -1
- package/dist/workflow.cjs +70 -46
- package/dist/workflow.cjs.map +1 -1
- package/dist/workflow.js +72 -47
- package/dist/workflow.js.map +1 -1
- package/package.json +1 -1
package/dist/workflow.js
CHANGED
|
@@ -68,7 +68,8 @@ import {
|
|
|
68
68
|
Button,
|
|
69
69
|
Input,
|
|
70
70
|
Select,
|
|
71
|
-
Spinner
|
|
71
|
+
Spinner,
|
|
72
|
+
Tooltip
|
|
72
73
|
} from "./chunk-2VYRM5DQ.js";
|
|
73
74
|
import {
|
|
74
75
|
cn
|
|
@@ -2401,53 +2402,77 @@ function FxPanel({
|
|
|
2401
2402
|
const mono = category.kind === "function";
|
|
2402
2403
|
const draggable = !!item.insertValue;
|
|
2403
2404
|
const isFocused = focusedId === item.id;
|
|
2404
|
-
|
|
2405
|
-
"
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
|
|
2409
|
-
|
|
2410
|
-
|
|
2411
|
-
|
|
2412
|
-
|
|
2405
|
+
const tip = /* @__PURE__ */ jsxs3("span", { className: "ods-flow-fx-panel__tip", children: [
|
|
2406
|
+
/* @__PURE__ */ jsxs3("span", { className: "ods-flow-fx-panel__tip-head", children: [
|
|
2407
|
+
/* @__PURE__ */ jsx3(
|
|
2408
|
+
"span",
|
|
2409
|
+
{
|
|
2410
|
+
className: cn(
|
|
2411
|
+
"ods-flow-fx-panel__tip-label",
|
|
2412
|
+
mono && "ods-flow-fx-panel__tip-label--mono"
|
|
2413
|
+
),
|
|
2414
|
+
children: item.label
|
|
2415
|
+
}
|
|
2413
2416
|
),
|
|
2414
|
-
|
|
2415
|
-
|
|
2416
|
-
|
|
2417
|
-
|
|
2418
|
-
|
|
2419
|
-
|
|
2420
|
-
|
|
2421
|
-
|
|
2422
|
-
|
|
2423
|
-
|
|
2424
|
-
|
|
2425
|
-
|
|
2426
|
-
|
|
2427
|
-
|
|
2428
|
-
|
|
2429
|
-
|
|
2430
|
-
|
|
2431
|
-
|
|
2432
|
-
|
|
2433
|
-
|
|
2434
|
-
|
|
2435
|
-
|
|
2436
|
-
|
|
2437
|
-
|
|
2438
|
-
|
|
2439
|
-
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
|
|
2443
|
-
|
|
2444
|
-
|
|
2445
|
-
|
|
2446
|
-
|
|
2447
|
-
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
|
|
2417
|
+
item.valueType && /* @__PURE__ */ jsx3("span", { className: "ods-flow-fx-panel__tip-type", children: item.valueType })
|
|
2418
|
+
] }),
|
|
2419
|
+
item.description && /* @__PURE__ */ jsx3("span", { className: "ods-flow-fx-panel__tip-desc", children: item.description }),
|
|
2420
|
+
item.insertValue && /* @__PURE__ */ jsx3("span", { className: "ods-flow-fx-panel__tip-ref", children: item.insertValue })
|
|
2421
|
+
] });
|
|
2422
|
+
return /* @__PURE__ */ jsx3(
|
|
2423
|
+
Tooltip,
|
|
2424
|
+
{
|
|
2425
|
+
content: tip,
|
|
2426
|
+
position: "left",
|
|
2427
|
+
disabled: !item.description && !item.insertValue,
|
|
2428
|
+
children: /* @__PURE__ */ jsxs3(
|
|
2429
|
+
"div",
|
|
2430
|
+
{
|
|
2431
|
+
"data-fx-row": item.id,
|
|
2432
|
+
className: cn(
|
|
2433
|
+
"ods-flow-fx-panel__row",
|
|
2434
|
+
hasChildren ? "ods-flow-fx-panel__row--branch" : "ods-flow-fx-panel__row--leaf",
|
|
2435
|
+
draggingId === item.id && "ods-flow-fx-panel__row--dragging",
|
|
2436
|
+
isFocused && "ods-flow-fx-panel__row--focused"
|
|
2437
|
+
),
|
|
2438
|
+
role: "treeitem",
|
|
2439
|
+
"aria-expanded": hasChildren ? expanded : void 0,
|
|
2440
|
+
"aria-level": depth + 1,
|
|
2441
|
+
tabIndex: isFocused || focusedId === null && rows[0]?.item.id === item.id ? 0 : -1,
|
|
2442
|
+
draggable,
|
|
2443
|
+
onDragStart: draggable ? handleDragStart(item, category) : void 0,
|
|
2444
|
+
onDragEnd: () => setDraggingId(null),
|
|
2445
|
+
onFocus: () => setFocusedId(item.id),
|
|
2446
|
+
onKeyDown: (e) => onRowKeyDown(e, rows, row, category),
|
|
2447
|
+
onClick: () => {
|
|
2448
|
+
if (hasChildren) toggleItem(item.id);
|
|
2449
|
+
else onItemSelect?.(item, category);
|
|
2450
|
+
},
|
|
2451
|
+
children: [
|
|
2452
|
+
Array.from({ length: depth }, (_, i) => /* @__PURE__ */ jsx3("span", { className: "ods-flow-fx-panel__indent", "aria-hidden": "true" }, i)),
|
|
2453
|
+
hasChildren ? /* @__PURE__ */ jsx3("span", { className: "ods-flow-fx-panel__twisty", "aria-hidden": "true", children: expanded ? /* @__PURE__ */ jsx3(ChevronDownIcon, { size: "sm" }) : /* @__PURE__ */ jsx3(ChevronRightIcon, { size: "sm" }) }) : /* @__PURE__ */ jsx3("span", { className: "ods-flow-fx-panel__grip", "aria-hidden": "true", children: /* @__PURE__ */ jsx3(DraggableIcon, { size: "sm" }) }),
|
|
2454
|
+
/* @__PURE__ */ jsxs3("span", { className: "ods-flow-fx-panel__row-main", children: [
|
|
2455
|
+
/* @__PURE__ */ jsxs3("span", { className: "ods-flow-fx-panel__row-line", children: [
|
|
2456
|
+
mono ? /* @__PURE__ */ jsx3("code", { className: "ods-flow-fx-panel__row-label ods-flow-fx-panel__row-label--mono", children: item.label }) : /* @__PURE__ */ jsx3("span", { className: "ods-flow-fx-panel__row-label", children: item.label }),
|
|
2457
|
+
item.valueType && /* @__PURE__ */ jsx3(
|
|
2458
|
+
"span",
|
|
2459
|
+
{
|
|
2460
|
+
className: cn(
|
|
2461
|
+
"ods-flow-fx-panel__type",
|
|
2462
|
+
`ods-flow-fx-panel__type--${item.valueType}`
|
|
2463
|
+
),
|
|
2464
|
+
children: item.valueType
|
|
2465
|
+
}
|
|
2466
|
+
)
|
|
2467
|
+
] }),
|
|
2468
|
+
(item.description || crumb) && /* @__PURE__ */ jsxs3("span", { className: "ods-flow-fx-panel__row-sub", children: [
|
|
2469
|
+
crumb && /* @__PURE__ */ jsx3("span", { className: "ods-flow-fx-panel__crumb", children: crumb }),
|
|
2470
|
+
item.description
|
|
2471
|
+
] })
|
|
2472
|
+
] })
|
|
2473
|
+
]
|
|
2474
|
+
}
|
|
2475
|
+
)
|
|
2451
2476
|
},
|
|
2452
2477
|
item.id
|
|
2453
2478
|
);
|