@octaviaflow/core 3.0.18-beta.26 → 3.0.18-beta.28
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/DataRefButton.d.ts +9 -0
- package/dist/workflow/components/FxPanel/DataRefButton.d.ts.map +1 -0
- package/dist/workflow/components/FxPanel/FxPanel.d.ts.map +1 -1
- package/dist/workflow/index.d.ts +1 -1
- package/dist/workflow/index.d.ts.map +1 -1
- package/dist/workflow.cjs +24 -18
- package/dist/workflow.cjs.map +1 -1
- package/dist/workflow.js +27 -19
- package/dist/workflow.js.map +1 -1
- package/package.json +2 -1
package/dist/workflow.js
CHANGED
|
@@ -630,12 +630,14 @@ import {
|
|
|
630
630
|
CollapseAllIcon,
|
|
631
631
|
DraggableIcon,
|
|
632
632
|
ExpandAllIcon,
|
|
633
|
-
|
|
633
|
+
FunctionMathIcon,
|
|
634
|
+
SearchIcon,
|
|
635
|
+
ValueVariableIcon
|
|
634
636
|
} from "@octaviaflow/icons";
|
|
635
637
|
import { Fragment as Fragment2, jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
636
|
-
var
|
|
637
|
-
function:
|
|
638
|
-
variable:
|
|
638
|
+
var KIND_ICON = {
|
|
639
|
+
function: FunctionMathIcon,
|
|
640
|
+
variable: ValueVariableIcon
|
|
639
641
|
};
|
|
640
642
|
function countLeaves(items) {
|
|
641
643
|
let n = 0;
|
|
@@ -956,6 +958,7 @@ function FxPanel({
|
|
|
956
958
|
!query && visibleCategories.map((cat) => {
|
|
957
959
|
const isOpen = openCategoryId === cat.id;
|
|
958
960
|
const kind = cat.kind ?? "function";
|
|
961
|
+
const KindIcon = KIND_ICON[kind];
|
|
959
962
|
const branchIds = /* @__PURE__ */ new Set();
|
|
960
963
|
collectBranchIds(cat.items, branchIds);
|
|
961
964
|
const hasTree = branchIds.size > 0;
|
|
@@ -998,11 +1001,10 @@ function FxPanel({
|
|
|
998
1001
|
),
|
|
999
1002
|
children: [
|
|
1000
1003
|
/* @__PURE__ */ jsx2(
|
|
1001
|
-
|
|
1004
|
+
KindIcon,
|
|
1002
1005
|
{
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
children: KIND_GLYPH[kind]
|
|
1006
|
+
size: "sm",
|
|
1007
|
+
className: "ods-flow-fx-panel__badge-icon"
|
|
1006
1008
|
}
|
|
1007
1009
|
),
|
|
1008
1010
|
cat.label
|
|
@@ -1044,12 +1046,12 @@ function FxPanel({
|
|
|
1044
1046
|
);
|
|
1045
1047
|
}
|
|
1046
1048
|
|
|
1047
|
-
// src/workflow/components/FxPanel/
|
|
1048
|
-
import {
|
|
1049
|
+
// src/workflow/components/FxPanel/DataRefButton.tsx
|
|
1050
|
+
import { DataReferenceIcon } from "@octaviaflow/icons";
|
|
1049
1051
|
import { jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
1050
|
-
function
|
|
1052
|
+
function DataRefButton({
|
|
1051
1053
|
active = false,
|
|
1052
|
-
label = "
|
|
1054
|
+
label = "Data ref",
|
|
1053
1055
|
className,
|
|
1054
1056
|
type = "button",
|
|
1055
1057
|
...rest
|
|
@@ -1060,16 +1062,22 @@ function FxToggleButton({
|
|
|
1060
1062
|
...rest,
|
|
1061
1063
|
type,
|
|
1062
1064
|
className: cn(
|
|
1063
|
-
"ods-flow-
|
|
1064
|
-
active && "ods-flow-
|
|
1065
|
-
label == null && "ods-flow-
|
|
1065
|
+
"ods-flow-dataref-button",
|
|
1066
|
+
active && "ods-flow-dataref-button--active",
|
|
1067
|
+
label == null && "ods-flow-dataref-button--icon-only",
|
|
1066
1068
|
className
|
|
1067
1069
|
),
|
|
1068
1070
|
"aria-pressed": active,
|
|
1069
|
-
title: active ? "Hide
|
|
1071
|
+
title: active ? "Hide data references" : "Show data references",
|
|
1070
1072
|
children: [
|
|
1071
|
-
/* @__PURE__ */ jsx3(
|
|
1072
|
-
|
|
1073
|
+
/* @__PURE__ */ jsx3(
|
|
1074
|
+
DataReferenceIcon,
|
|
1075
|
+
{
|
|
1076
|
+
size: "sm",
|
|
1077
|
+
className: "ods-flow-dataref-button__icon"
|
|
1078
|
+
}
|
|
1079
|
+
),
|
|
1080
|
+
label != null && /* @__PURE__ */ jsx3("span", { className: "ods-flow-dataref-button__label", children: label })
|
|
1073
1081
|
]
|
|
1074
1082
|
}
|
|
1075
1083
|
);
|
|
@@ -1251,13 +1259,13 @@ export {
|
|
|
1251
1259
|
DEFAULT_NODE_HEIGHT,
|
|
1252
1260
|
DEFAULT_NODE_KINDS,
|
|
1253
1261
|
DEFAULT_NODE_WIDTH,
|
|
1262
|
+
DataRefButton,
|
|
1254
1263
|
ErrorNode,
|
|
1255
1264
|
FlowCanvas,
|
|
1256
1265
|
FlowEdge,
|
|
1257
1266
|
FlowNode,
|
|
1258
1267
|
ForEachNode,
|
|
1259
1268
|
FxPanel,
|
|
1260
|
-
FxToggleButton,
|
|
1261
1269
|
GroupNode,
|
|
1262
1270
|
Handle,
|
|
1263
1271
|
HttpRequestNode,
|