@octaviaflow/core 3.1.0-beta.54 → 3.1.0-beta.55
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/components/StatusList/StatusList.d.ts +48 -0
- package/dist/components/StatusList/StatusList.d.ts.map +1 -0
- package/dist/components/StatusList/index.d.ts +2 -0
- package/dist/components/StatusList/index.d.ts.map +1 -0
- package/dist/index.cjs +820 -737
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +730 -648
- package/dist/index.js.map +1 -1
- package/dist/styles.css +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -180,6 +180,7 @@ __export(src_exports, {
|
|
|
180
180
|
Spotlight: () => Spotlight,
|
|
181
181
|
Stack: () => Stack,
|
|
182
182
|
Stat: () => Stat,
|
|
183
|
+
StatusList: () => StatusList,
|
|
183
184
|
StatusTiles: () => StatusTiles,
|
|
184
185
|
Stepper: () => Stepper,
|
|
185
186
|
Switch: () => Switch,
|
|
@@ -24855,9 +24856,90 @@ function VersionHistory({
|
|
|
24855
24856
|
}
|
|
24856
24857
|
VersionHistory.displayName = "VersionHistory";
|
|
24857
24858
|
|
|
24859
|
+
// src/components/StatusList/StatusList.tsx
|
|
24860
|
+
var import_jsx_runtime113 = require("react/jsx-runtime");
|
|
24861
|
+
var TONE_TO_CHIP2 = {
|
|
24862
|
+
success: "success",
|
|
24863
|
+
running: "primary",
|
|
24864
|
+
warning: "warning",
|
|
24865
|
+
danger: "error",
|
|
24866
|
+
neutral: "default",
|
|
24867
|
+
info: "primary"
|
|
24868
|
+
};
|
|
24869
|
+
function StatusList({
|
|
24870
|
+
items,
|
|
24871
|
+
title,
|
|
24872
|
+
action,
|
|
24873
|
+
dense = false,
|
|
24874
|
+
max,
|
|
24875
|
+
emptyLabel = "Nothing to show",
|
|
24876
|
+
onItemClick,
|
|
24877
|
+
className,
|
|
24878
|
+
...rest
|
|
24879
|
+
}) {
|
|
24880
|
+
const visible = typeof max === "number" ? items.slice(0, max) : items;
|
|
24881
|
+
const overflow = items.length - visible.length;
|
|
24882
|
+
const renderRowInner = (item) => /* @__PURE__ */ (0, import_jsx_runtime113.jsxs)(import_jsx_runtime113.Fragment, { children: [
|
|
24883
|
+
/* @__PURE__ */ (0, import_jsx_runtime113.jsx)(
|
|
24884
|
+
"span",
|
|
24885
|
+
{
|
|
24886
|
+
className: "ods-status-list__lead",
|
|
24887
|
+
"data-tone": item.tone ?? "neutral",
|
|
24888
|
+
"aria-hidden": "true",
|
|
24889
|
+
children: item.icon ?? /* @__PURE__ */ (0, import_jsx_runtime113.jsx)("span", { className: "ods-status-list__dot" })
|
|
24890
|
+
}
|
|
24891
|
+
),
|
|
24892
|
+
/* @__PURE__ */ (0, import_jsx_runtime113.jsxs)("span", { className: "ods-status-list__text", children: [
|
|
24893
|
+
/* @__PURE__ */ (0, import_jsx_runtime113.jsx)("span", { className: "ods-status-list__name", children: item.name }),
|
|
24894
|
+
item.meta != null && /* @__PURE__ */ (0, import_jsx_runtime113.jsx)("span", { className: "ods-status-list__meta", children: item.meta })
|
|
24895
|
+
] }),
|
|
24896
|
+
item.sparkline && item.sparkline.length > 1 && /* @__PURE__ */ (0, import_jsx_runtime113.jsx)("span", { className: "ods-status-list__spark", children: /* @__PURE__ */ (0, import_jsx_runtime113.jsx)(Sparkline, { data: item.sparkline, width: 72, height: 22 }) }),
|
|
24897
|
+
item.status != null && /* @__PURE__ */ (0, import_jsx_runtime113.jsx)(Chip, { size: "sm", variant: TONE_TO_CHIP2[item.tone ?? "neutral"], children: item.status }),
|
|
24898
|
+
item.trailing != null && /* @__PURE__ */ (0, import_jsx_runtime113.jsx)("span", { className: "ods-status-list__trailing", children: item.trailing })
|
|
24899
|
+
] });
|
|
24900
|
+
return /* @__PURE__ */ (0, import_jsx_runtime113.jsxs)("div", { className: cn("ods-status-list", className), ...rest, children: [
|
|
24901
|
+
(title != null || action != null) && /* @__PURE__ */ (0, import_jsx_runtime113.jsxs)("div", { className: "ods-status-list__header", children: [
|
|
24902
|
+
title != null && /* @__PURE__ */ (0, import_jsx_runtime113.jsx)("h3", { className: "ods-status-list__title", children: title }),
|
|
24903
|
+
action != null && /* @__PURE__ */ (0, import_jsx_runtime113.jsx)("div", { className: "ods-status-list__action", children: action })
|
|
24904
|
+
] }),
|
|
24905
|
+
visible.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime113.jsx)("div", { className: "ods-status-list__empty", children: emptyLabel }) : /* @__PURE__ */ (0, import_jsx_runtime113.jsx)(
|
|
24906
|
+
"ul",
|
|
24907
|
+
{
|
|
24908
|
+
className: cn(
|
|
24909
|
+
"ods-status-list__rows",
|
|
24910
|
+
dense && "ods-status-list__rows--dense"
|
|
24911
|
+
),
|
|
24912
|
+
children: visible.map((item) => {
|
|
24913
|
+
const interactive = Boolean(item.href || onItemClick);
|
|
24914
|
+
const rowClass = cn(
|
|
24915
|
+
"ods-status-list__row",
|
|
24916
|
+
interactive && "ods-status-list__row--interactive",
|
|
24917
|
+
item.muted && "ods-status-list__row--muted"
|
|
24918
|
+
);
|
|
24919
|
+
return /* @__PURE__ */ (0, import_jsx_runtime113.jsx)("li", { className: "ods-status-list__item", children: item.href ? /* @__PURE__ */ (0, import_jsx_runtime113.jsx)("a", { className: rowClass, href: item.href, children: renderRowInner(item) }) : onItemClick ? /* @__PURE__ */ (0, import_jsx_runtime113.jsx)(
|
|
24920
|
+
"button",
|
|
24921
|
+
{
|
|
24922
|
+
type: "button",
|
|
24923
|
+
className: rowClass,
|
|
24924
|
+
onClick: () => onItemClick(item),
|
|
24925
|
+
children: renderRowInner(item)
|
|
24926
|
+
}
|
|
24927
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime113.jsx)("div", { className: rowClass, children: renderRowInner(item) }) }, item.id);
|
|
24928
|
+
})
|
|
24929
|
+
}
|
|
24930
|
+
),
|
|
24931
|
+
overflow > 0 && /* @__PURE__ */ (0, import_jsx_runtime113.jsxs)("div", { className: "ods-status-list__more", children: [
|
|
24932
|
+
"+",
|
|
24933
|
+
overflow,
|
|
24934
|
+
" more"
|
|
24935
|
+
] })
|
|
24936
|
+
] });
|
|
24937
|
+
}
|
|
24938
|
+
StatusList.displayName = "StatusList";
|
|
24939
|
+
|
|
24858
24940
|
// src/components/Slider/Slider.tsx
|
|
24859
24941
|
var import_react133 = require("react");
|
|
24860
|
-
var
|
|
24942
|
+
var import_jsx_runtime114 = require("react/jsx-runtime");
|
|
24861
24943
|
var Slider = (0, import_react133.forwardRef)(function Slider2({
|
|
24862
24944
|
label,
|
|
24863
24945
|
value,
|
|
@@ -24891,7 +24973,7 @@ var Slider = (0, import_react133.forwardRef)(function Slider2({
|
|
|
24891
24973
|
const valueText = String(display);
|
|
24892
24974
|
const handle = (e) => onChange?.(Number(e.target.value));
|
|
24893
24975
|
const describedBy = [consumerDescribedBy, hintId].filter(Boolean).join(" ") || void 0;
|
|
24894
|
-
return /* @__PURE__ */ (0,
|
|
24976
|
+
return /* @__PURE__ */ (0, import_jsx_runtime114.jsxs)(
|
|
24895
24977
|
"div",
|
|
24896
24978
|
{
|
|
24897
24979
|
className: cn(
|
|
@@ -24903,8 +24985,8 @@ var Slider = (0, import_react133.forwardRef)(function Slider2({
|
|
|
24903
24985
|
className
|
|
24904
24986
|
),
|
|
24905
24987
|
children: [
|
|
24906
|
-
(label || showValue) && /* @__PURE__ */ (0,
|
|
24907
|
-
label && /* @__PURE__ */ (0,
|
|
24988
|
+
(label || showValue) && /* @__PURE__ */ (0, import_jsx_runtime114.jsxs)("div", { className: "ods-slider__head", children: [
|
|
24989
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime114.jsx)(
|
|
24908
24990
|
"label",
|
|
24909
24991
|
{
|
|
24910
24992
|
id: labelId,
|
|
@@ -24913,17 +24995,17 @@ var Slider = (0, import_react133.forwardRef)(function Slider2({
|
|
|
24913
24995
|
children: label
|
|
24914
24996
|
}
|
|
24915
24997
|
),
|
|
24916
|
-
showValue && /* @__PURE__ */ (0,
|
|
24998
|
+
showValue && /* @__PURE__ */ (0, import_jsx_runtime114.jsx)("span", { className: "ods-slider__value", "aria-hidden": "true", children: display })
|
|
24917
24999
|
] }),
|
|
24918
|
-
/* @__PURE__ */ (0,
|
|
24919
|
-
/* @__PURE__ */ (0,
|
|
25000
|
+
/* @__PURE__ */ (0, import_jsx_runtime114.jsxs)("div", { className: "ods-slider__track", children: [
|
|
25001
|
+
/* @__PURE__ */ (0, import_jsx_runtime114.jsx)(
|
|
24920
25002
|
"span",
|
|
24921
25003
|
{
|
|
24922
25004
|
className: "ods-slider__fill",
|
|
24923
25005
|
style: { width: `${pct}%` }
|
|
24924
25006
|
}
|
|
24925
25007
|
),
|
|
24926
|
-
/* @__PURE__ */ (0,
|
|
25008
|
+
/* @__PURE__ */ (0, import_jsx_runtime114.jsx)(
|
|
24927
25009
|
"input",
|
|
24928
25010
|
{
|
|
24929
25011
|
...rest,
|
|
@@ -24947,22 +25029,22 @@ var Slider = (0, import_react133.forwardRef)(function Slider2({
|
|
|
24947
25029
|
] }),
|
|
24948
25030
|
marks && marks.length > 0 && // Marks are decorative — aria-hidden so the screen reader hears
|
|
24949
25031
|
// the formatted value, not "tick mark, tick mark, …".
|
|
24950
|
-
/* @__PURE__ */ (0,
|
|
25032
|
+
/* @__PURE__ */ (0, import_jsx_runtime114.jsx)("div", { className: "ods-slider__marks", "aria-hidden": "true", children: marks.map((m) => {
|
|
24951
25033
|
const left = (m.value - min) / span * 100;
|
|
24952
|
-
return /* @__PURE__ */ (0,
|
|
25034
|
+
return /* @__PURE__ */ (0, import_jsx_runtime114.jsxs)(
|
|
24953
25035
|
"div",
|
|
24954
25036
|
{
|
|
24955
25037
|
className: "ods-slider__mark",
|
|
24956
25038
|
style: { left: `${left}%` },
|
|
24957
25039
|
children: [
|
|
24958
|
-
/* @__PURE__ */ (0,
|
|
24959
|
-
m.label && /* @__PURE__ */ (0,
|
|
25040
|
+
/* @__PURE__ */ (0, import_jsx_runtime114.jsx)("span", { className: "ods-slider__mark-tick" }),
|
|
25041
|
+
m.label && /* @__PURE__ */ (0, import_jsx_runtime114.jsx)("span", { className: "ods-slider__mark-label", children: m.label })
|
|
24960
25042
|
]
|
|
24961
25043
|
},
|
|
24962
25044
|
m.value
|
|
24963
25045
|
);
|
|
24964
25046
|
}) }),
|
|
24965
|
-
error ? /* @__PURE__ */ (0,
|
|
25047
|
+
error ? /* @__PURE__ */ (0, import_jsx_runtime114.jsx)(
|
|
24966
25048
|
"div",
|
|
24967
25049
|
{
|
|
24968
25050
|
id: hintId,
|
|
@@ -24970,7 +25052,7 @@ var Slider = (0, import_react133.forwardRef)(function Slider2({
|
|
|
24970
25052
|
role: "alert",
|
|
24971
25053
|
children: error
|
|
24972
25054
|
}
|
|
24973
|
-
) : helperText ? /* @__PURE__ */ (0,
|
|
25055
|
+
) : helperText ? /* @__PURE__ */ (0, import_jsx_runtime114.jsx)("div", { id: hintId, className: "ods-slider__hint", children: helperText }) : null
|
|
24974
25056
|
]
|
|
24975
25057
|
}
|
|
24976
25058
|
);
|
|
@@ -24980,7 +25062,7 @@ Slider.displayName = "Slider";
|
|
|
24980
25062
|
// src/components/SocialButton/SocialButton.tsx
|
|
24981
25063
|
var import_icons35 = require("@octaviaflow/icons");
|
|
24982
25064
|
var import_react134 = require("react");
|
|
24983
|
-
var
|
|
25065
|
+
var import_jsx_runtime115 = require("react/jsx-runtime");
|
|
24984
25066
|
var DEFAULT_LABELS = {
|
|
24985
25067
|
google: "Continue with Google",
|
|
24986
25068
|
github: "Continue with GitHub",
|
|
@@ -24990,29 +25072,29 @@ var DEFAULT_LABELS = {
|
|
|
24990
25072
|
microsoft: "Continue with Microsoft",
|
|
24991
25073
|
linkedin: "Continue with LinkedIn"
|
|
24992
25074
|
};
|
|
24993
|
-
var GoogleIcon = () => /* @__PURE__ */ (0,
|
|
24994
|
-
/* @__PURE__ */ (0,
|
|
25075
|
+
var GoogleIcon = () => /* @__PURE__ */ (0, import_jsx_runtime115.jsxs)("svg", { width: "18", height: "18", viewBox: "0 0 18 18", fill: "none", "aria-hidden": "true", children: [
|
|
25076
|
+
/* @__PURE__ */ (0, import_jsx_runtime115.jsx)(
|
|
24995
25077
|
"path",
|
|
24996
25078
|
{
|
|
24997
25079
|
d: "M17.64 9.2c0-.64-.06-1.25-.16-1.84H9v3.48h4.84a4.14 4.14 0 0 1-1.79 2.72v2.26h2.9c1.69-1.56 2.69-3.85 2.69-6.62z",
|
|
24998
25080
|
fill: "#4285F4"
|
|
24999
25081
|
}
|
|
25000
25082
|
),
|
|
25001
|
-
/* @__PURE__ */ (0,
|
|
25083
|
+
/* @__PURE__ */ (0, import_jsx_runtime115.jsx)(
|
|
25002
25084
|
"path",
|
|
25003
25085
|
{
|
|
25004
25086
|
d: "M9 18c2.43 0 4.47-.8 5.96-2.18l-2.9-2.26c-.8.54-1.84.86-3.06.86-2.34 0-4.33-1.58-5.04-3.71H.96v2.33A9 9 0 0 0 9 18z",
|
|
25005
25087
|
fill: "#34A853"
|
|
25006
25088
|
}
|
|
25007
25089
|
),
|
|
25008
|
-
/* @__PURE__ */ (0,
|
|
25090
|
+
/* @__PURE__ */ (0, import_jsx_runtime115.jsx)(
|
|
25009
25091
|
"path",
|
|
25010
25092
|
{
|
|
25011
25093
|
d: "M3.96 10.71A5.38 5.38 0 0 1 3.68 9c0-.6.1-1.18.28-1.71V4.96H.96A9 9 0 0 0 0 9c0 1.45.35 2.82.96 4.04l3-2.33z",
|
|
25012
25094
|
fill: "#FBBC05"
|
|
25013
25095
|
}
|
|
25014
25096
|
),
|
|
25015
|
-
/* @__PURE__ */ (0,
|
|
25097
|
+
/* @__PURE__ */ (0, import_jsx_runtime115.jsx)(
|
|
25016
25098
|
"path",
|
|
25017
25099
|
{
|
|
25018
25100
|
d: "M9 3.58c1.32 0 2.5.45 3.44 1.35l2.58-2.58A9 9 0 0 0 9 0 9 9 0 0 0 .96 4.96l3 2.33C4.67 5.16 6.66 3.58 9 3.58z",
|
|
@@ -25020,34 +25102,34 @@ var GoogleIcon = () => /* @__PURE__ */ (0, import_jsx_runtime114.jsxs)("svg", {
|
|
|
25020
25102
|
}
|
|
25021
25103
|
)
|
|
25022
25104
|
] });
|
|
25023
|
-
var AppleIcon = () => /* @__PURE__ */ (0,
|
|
25105
|
+
var AppleIcon = () => /* @__PURE__ */ (0, import_jsx_runtime115.jsx)("svg", { width: "18", height: "18", viewBox: "0 0 18 18", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(
|
|
25024
25106
|
"path",
|
|
25025
25107
|
{
|
|
25026
25108
|
d: "M13.4 9.5c0-1.7 1.4-2.5 1.5-2.6-.8-1.2-2.1-1.3-2.5-1.3-1.1-.1-2.1.6-2.6.6-.6 0-1.4-.6-2.3-.6-1.2 0-2.3.7-2.9 1.8-1.2 2.1-.3 5.3.9 7 .6.9 1.3 1.8 2.2 1.8.9 0 1.2-.6 2.3-.6s1.4.6 2.3.6 1.5-.9 2.1-1.8c.7-1 1-2 1-2.1 0 0-1.9-.7-2-2.8zM11.5 4.5c.5-.6.8-1.4.7-2.2-.7 0-1.5.5-2 1.1-.4.5-.8 1.3-.7 2.1.8.1 1.6-.4 2-1z",
|
|
25027
25109
|
fill: "currentColor"
|
|
25028
25110
|
}
|
|
25029
25111
|
) });
|
|
25030
|
-
var MicrosoftIcon = () => /* @__PURE__ */ (0,
|
|
25031
|
-
/* @__PURE__ */ (0,
|
|
25032
|
-
/* @__PURE__ */ (0,
|
|
25033
|
-
/* @__PURE__ */ (0,
|
|
25034
|
-
/* @__PURE__ */ (0,
|
|
25112
|
+
var MicrosoftIcon = () => /* @__PURE__ */ (0, import_jsx_runtime115.jsxs)("svg", { width: "18", height: "18", viewBox: "0 0 18 18", fill: "none", "aria-hidden": "true", children: [
|
|
25113
|
+
/* @__PURE__ */ (0, import_jsx_runtime115.jsx)("rect", { x: "1", y: "1", width: "7.5", height: "7.5", fill: "#F25022" }),
|
|
25114
|
+
/* @__PURE__ */ (0, import_jsx_runtime115.jsx)("rect", { x: "9.5", y: "1", width: "7.5", height: "7.5", fill: "#7FBA00" }),
|
|
25115
|
+
/* @__PURE__ */ (0, import_jsx_runtime115.jsx)("rect", { x: "1", y: "9.5", width: "7.5", height: "7.5", fill: "#00A4EF" }),
|
|
25116
|
+
/* @__PURE__ */ (0, import_jsx_runtime115.jsx)("rect", { x: "9.5", y: "9.5", width: "7.5", height: "7.5", fill: "#FFB900" })
|
|
25035
25117
|
] });
|
|
25036
25118
|
function resolveIcon2(provider) {
|
|
25037
25119
|
switch (provider) {
|
|
25038
25120
|
case "google":
|
|
25039
|
-
return /* @__PURE__ */ (0,
|
|
25121
|
+
return /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(GoogleIcon, {});
|
|
25040
25122
|
case "apple":
|
|
25041
|
-
return /* @__PURE__ */ (0,
|
|
25123
|
+
return /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(AppleIcon, {});
|
|
25042
25124
|
case "microsoft":
|
|
25043
|
-
return /* @__PURE__ */ (0,
|
|
25125
|
+
return /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(MicrosoftIcon, {});
|
|
25044
25126
|
case "github":
|
|
25045
|
-
return /* @__PURE__ */ (0,
|
|
25127
|
+
return /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(import_icons35.LogoGithubIcon, { size: "sm" });
|
|
25046
25128
|
case "x":
|
|
25047
25129
|
case "twitter":
|
|
25048
|
-
return /* @__PURE__ */ (0,
|
|
25130
|
+
return /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(import_icons35.LogoXIcon, { size: "sm" });
|
|
25049
25131
|
case "linkedin":
|
|
25050
|
-
return /* @__PURE__ */ (0,
|
|
25132
|
+
return /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(import_icons35.LogoLinkedinIcon, { size: "sm" });
|
|
25051
25133
|
case "custom":
|
|
25052
25134
|
return null;
|
|
25053
25135
|
}
|
|
@@ -25069,7 +25151,7 @@ var SocialButton = (0, import_react134.forwardRef)(
|
|
|
25069
25151
|
const resolvedIcon = icon ?? resolveIcon2(provider);
|
|
25070
25152
|
const resolvedLabel = label ?? children ?? (provider !== "custom" ? DEFAULT_LABELS[provider] : null);
|
|
25071
25153
|
const providerClass = provider === "twitter" ? "x" : provider;
|
|
25072
|
-
return /* @__PURE__ */ (0,
|
|
25154
|
+
return /* @__PURE__ */ (0, import_jsx_runtime115.jsx)(
|
|
25073
25155
|
Button,
|
|
25074
25156
|
{
|
|
25075
25157
|
...rest,
|
|
@@ -25097,7 +25179,7 @@ SocialButton.displayName = "SocialButton";
|
|
|
25097
25179
|
// src/components/Sortable/Sortable.tsx
|
|
25098
25180
|
var import_react135 = require("react");
|
|
25099
25181
|
var import_icons36 = require("@octaviaflow/icons");
|
|
25100
|
-
var
|
|
25182
|
+
var import_jsx_runtime116 = require("react/jsx-runtime");
|
|
25101
25183
|
var DT_TYPE = "application/x-ods-sortable";
|
|
25102
25184
|
function Sortable({
|
|
25103
25185
|
items,
|
|
@@ -25277,7 +25359,7 @@ function Sortable({
|
|
|
25277
25359
|
if (e.key === "ArrowRight") return moveBy(1);
|
|
25278
25360
|
}
|
|
25279
25361
|
};
|
|
25280
|
-
return /* @__PURE__ */ (0,
|
|
25362
|
+
return /* @__PURE__ */ (0, import_jsx_runtime116.jsxs)(
|
|
25281
25363
|
"div",
|
|
25282
25364
|
{
|
|
25283
25365
|
...rest,
|
|
@@ -25314,7 +25396,7 @@ function Sortable({
|
|
|
25314
25396
|
isDragging,
|
|
25315
25397
|
isKeyboardActive: isKbActive
|
|
25316
25398
|
};
|
|
25317
|
-
return /* @__PURE__ */ (0,
|
|
25399
|
+
return /* @__PURE__ */ (0, import_jsx_runtime116.jsxs)(
|
|
25318
25400
|
"div",
|
|
25319
25401
|
{
|
|
25320
25402
|
ref: (el) => {
|
|
@@ -25330,7 +25412,7 @@ function Sortable({
|
|
|
25330
25412
|
),
|
|
25331
25413
|
onDragOver: onItemDragOver(item.id),
|
|
25332
25414
|
children: [
|
|
25333
|
-
/* @__PURE__ */ (0,
|
|
25415
|
+
/* @__PURE__ */ (0, import_jsx_runtime116.jsx)(
|
|
25334
25416
|
"span",
|
|
25335
25417
|
{
|
|
25336
25418
|
className: "ods-sortable__indicator ods-sortable__indicator--before",
|
|
@@ -25338,7 +25420,7 @@ function Sortable({
|
|
|
25338
25420
|
}
|
|
25339
25421
|
),
|
|
25340
25422
|
renderItem(item, idx, dragProps),
|
|
25341
|
-
/* @__PURE__ */ (0,
|
|
25423
|
+
/* @__PURE__ */ (0, import_jsx_runtime116.jsx)(
|
|
25342
25424
|
"span",
|
|
25343
25425
|
{
|
|
25344
25426
|
className: "ods-sortable__indicator ods-sortable__indicator--after",
|
|
@@ -25350,7 +25432,7 @@ function Sortable({
|
|
|
25350
25432
|
item.id
|
|
25351
25433
|
);
|
|
25352
25434
|
}),
|
|
25353
|
-
/* @__PURE__ */ (0,
|
|
25435
|
+
/* @__PURE__ */ (0, import_jsx_runtime116.jsx)("span", { className: "ods-sortable__sr", "aria-live": "polite", "aria-atomic": "true", children: kbActiveId ? `Item picked up. Use arrow keys to reorder, Space or Enter to drop, Escape to cancel.` : "" })
|
|
25354
25436
|
]
|
|
25355
25437
|
}
|
|
25356
25438
|
);
|
|
@@ -25363,7 +25445,7 @@ var DragHandle = (0, import_react135.forwardRef)(
|
|
|
25363
25445
|
ariaLabel: legacyAriaLabel,
|
|
25364
25446
|
dragProps
|
|
25365
25447
|
}, ref) {
|
|
25366
|
-
return /* @__PURE__ */ (0,
|
|
25448
|
+
return /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(
|
|
25367
25449
|
"span",
|
|
25368
25450
|
{
|
|
25369
25451
|
ref,
|
|
@@ -25372,7 +25454,7 @@ var DragHandle = (0, import_react135.forwardRef)(
|
|
|
25372
25454
|
className: cn("ods-sortable-handle", className),
|
|
25373
25455
|
style,
|
|
25374
25456
|
...dragProps,
|
|
25375
|
-
children: /* @__PURE__ */ (0,
|
|
25457
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(import_icons36.DraggableIcon, { size: "xs" })
|
|
25376
25458
|
}
|
|
25377
25459
|
);
|
|
25378
25460
|
}
|
|
@@ -25381,7 +25463,7 @@ DragHandle.displayName = "DragHandle";
|
|
|
25381
25463
|
|
|
25382
25464
|
// src/components/Stack/Stack.tsx
|
|
25383
25465
|
var import_react136 = require("react");
|
|
25384
|
-
var
|
|
25466
|
+
var import_jsx_runtime117 = require("react/jsx-runtime");
|
|
25385
25467
|
function resolveGap2(gap) {
|
|
25386
25468
|
if (typeof gap === "string") return gap;
|
|
25387
25469
|
if (gap === 0) return "0";
|
|
@@ -25420,11 +25502,11 @@ var Stack = (0, import_react136.forwardRef)(function Stack2({
|
|
|
25420
25502
|
const Component = as ?? "div";
|
|
25421
25503
|
const items = divider ? import_react136.Children.toArray(children).flatMap(
|
|
25422
25504
|
(child, i, arr) => i < arr.length - 1 ? [
|
|
25423
|
-
/* @__PURE__ */ (0,
|
|
25424
|
-
/* @__PURE__ */ (0,
|
|
25425
|
-
] : [/* @__PURE__ */ (0,
|
|
25505
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)(import_react136.Fragment, { children: child }, `item-${i}`),
|
|
25506
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)(import_react136.Fragment, { children: divider }, `divider-${i}`)
|
|
25507
|
+
] : [/* @__PURE__ */ (0, import_jsx_runtime117.jsx)(import_react136.Fragment, { children: child }, `item-${i}`)]
|
|
25426
25508
|
) : children;
|
|
25427
|
-
return /* @__PURE__ */ (0,
|
|
25509
|
+
return /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(
|
|
25428
25510
|
Component,
|
|
25429
25511
|
{
|
|
25430
25512
|
...rest,
|
|
@@ -25452,13 +25534,13 @@ var Stack = (0, import_react136.forwardRef)(function Stack2({
|
|
|
25452
25534
|
Stack.displayName = "Stack";
|
|
25453
25535
|
var HStack = (0, import_react136.forwardRef)(
|
|
25454
25536
|
function HStack2(props, ref) {
|
|
25455
|
-
return /* @__PURE__ */ (0,
|
|
25537
|
+
return /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(Stack, { ref, direction: "row", ...props });
|
|
25456
25538
|
}
|
|
25457
25539
|
);
|
|
25458
25540
|
HStack.displayName = "HStack";
|
|
25459
25541
|
var VStack = (0, import_react136.forwardRef)(
|
|
25460
25542
|
function VStack2(props, ref) {
|
|
25461
|
-
return /* @__PURE__ */ (0,
|
|
25543
|
+
return /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(Stack, { ref, direction: "column", ...props });
|
|
25462
25544
|
}
|
|
25463
25545
|
);
|
|
25464
25546
|
VStack.displayName = "VStack";
|
|
@@ -25467,7 +25549,7 @@ VStack.displayName = "VStack";
|
|
|
25467
25549
|
var import_framer_motion31 = require("framer-motion");
|
|
25468
25550
|
var import_react137 = require("react");
|
|
25469
25551
|
var import_react_dom16 = require("react-dom");
|
|
25470
|
-
var
|
|
25552
|
+
var import_jsx_runtime118 = require("react/jsx-runtime");
|
|
25471
25553
|
var Spotlight = (0, import_react137.forwardRef)(
|
|
25472
25554
|
function Spotlight2({
|
|
25473
25555
|
open,
|
|
@@ -25534,7 +25616,7 @@ var Spotlight = (0, import_react137.forwardRef)(
|
|
|
25534
25616
|
height: rect.height + padding * 2
|
|
25535
25617
|
} : null;
|
|
25536
25618
|
return (0, import_react_dom16.createPortal)(
|
|
25537
|
-
/* @__PURE__ */ (0,
|
|
25619
|
+
/* @__PURE__ */ (0, import_jsx_runtime118.jsx)(import_framer_motion31.AnimatePresence, { children: open && /* @__PURE__ */ (0, import_jsx_runtime118.jsxs)(
|
|
25538
25620
|
import_framer_motion31.motion.div,
|
|
25539
25621
|
{
|
|
25540
25622
|
...rest,
|
|
@@ -25546,7 +25628,7 @@ var Spotlight = (0, import_react137.forwardRef)(
|
|
|
25546
25628
|
exit: disableAnimation || reducedMotion ? void 0 : { opacity: 0 },
|
|
25547
25629
|
transition: { duration: 0.18 },
|
|
25548
25630
|
children: [
|
|
25549
|
-
/* @__PURE__ */ (0,
|
|
25631
|
+
/* @__PURE__ */ (0, import_jsx_runtime118.jsxs)(
|
|
25550
25632
|
"svg",
|
|
25551
25633
|
{
|
|
25552
25634
|
className: cn(
|
|
@@ -25560,8 +25642,8 @@ var Spotlight = (0, import_react137.forwardRef)(
|
|
|
25560
25642
|
"aria-hidden": "true",
|
|
25561
25643
|
onClick: onDismiss,
|
|
25562
25644
|
children: [
|
|
25563
|
-
/* @__PURE__ */ (0,
|
|
25564
|
-
/* @__PURE__ */ (0,
|
|
25645
|
+
/* @__PURE__ */ (0, import_jsx_runtime118.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime118.jsxs)("mask", { id: maskId, children: [
|
|
25646
|
+
/* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
|
|
25565
25647
|
"rect",
|
|
25566
25648
|
{
|
|
25567
25649
|
x: 0,
|
|
@@ -25571,7 +25653,7 @@ var Spotlight = (0, import_react137.forwardRef)(
|
|
|
25571
25653
|
fill: "white"
|
|
25572
25654
|
}
|
|
25573
25655
|
),
|
|
25574
|
-
cutout && shape === "rect" && /* @__PURE__ */ (0,
|
|
25656
|
+
cutout && shape === "rect" && /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
|
|
25575
25657
|
"rect",
|
|
25576
25658
|
{
|
|
25577
25659
|
x: cutout.x,
|
|
@@ -25583,7 +25665,7 @@ var Spotlight = (0, import_react137.forwardRef)(
|
|
|
25583
25665
|
fill: "black"
|
|
25584
25666
|
}
|
|
25585
25667
|
),
|
|
25586
|
-
cutout && shape === "circle" && /* @__PURE__ */ (0,
|
|
25668
|
+
cutout && shape === "circle" && /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
|
|
25587
25669
|
"ellipse",
|
|
25588
25670
|
{
|
|
25589
25671
|
cx: cutout.x + cutout.width / 2,
|
|
@@ -25594,7 +25676,7 @@ var Spotlight = (0, import_react137.forwardRef)(
|
|
|
25594
25676
|
}
|
|
25595
25677
|
)
|
|
25596
25678
|
] }) }),
|
|
25597
|
-
/* @__PURE__ */ (0,
|
|
25679
|
+
/* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
|
|
25598
25680
|
"rect",
|
|
25599
25681
|
{
|
|
25600
25682
|
x: 0,
|
|
@@ -25608,7 +25690,7 @@ var Spotlight = (0, import_react137.forwardRef)(
|
|
|
25608
25690
|
]
|
|
25609
25691
|
}
|
|
25610
25692
|
),
|
|
25611
|
-
children && /* @__PURE__ */ (0,
|
|
25693
|
+
children && /* @__PURE__ */ (0, import_jsx_runtime118.jsx)("div", { className: "ods-spotlight__content", children })
|
|
25612
25694
|
]
|
|
25613
25695
|
}
|
|
25614
25696
|
) }),
|
|
@@ -25621,7 +25703,7 @@ Spotlight.displayName = "Spotlight";
|
|
|
25621
25703
|
// src/components/Stat/Stat.tsx
|
|
25622
25704
|
var import_react138 = require("react");
|
|
25623
25705
|
var import_icons37 = require("@octaviaflow/icons");
|
|
25624
|
-
var
|
|
25706
|
+
var import_jsx_runtime119 = require("react/jsx-runtime");
|
|
25625
25707
|
var Stat = (0, import_react138.forwardRef)(function Stat2({
|
|
25626
25708
|
label,
|
|
25627
25709
|
value,
|
|
@@ -25635,23 +25717,23 @@ var Stat = (0, import_react138.forwardRef)(function Stat2({
|
|
|
25635
25717
|
...rest
|
|
25636
25718
|
}, ref) {
|
|
25637
25719
|
const TrendIcon = deltaTrend === "up" ? import_icons37.ArrowUpIcon : deltaTrend === "down" ? import_icons37.ArrowDownIcon : import_icons37.SubtractIcon;
|
|
25638
|
-
return /* @__PURE__ */ (0,
|
|
25720
|
+
return /* @__PURE__ */ (0, import_jsx_runtime119.jsxs)(
|
|
25639
25721
|
"div",
|
|
25640
25722
|
{
|
|
25641
25723
|
...rest,
|
|
25642
25724
|
ref,
|
|
25643
25725
|
className: cn("ods-stat", `ods-stat--${size}`, className),
|
|
25644
25726
|
children: [
|
|
25645
|
-
/* @__PURE__ */ (0,
|
|
25646
|
-
/* @__PURE__ */ (0,
|
|
25647
|
-
icon && /* @__PURE__ */ (0,
|
|
25727
|
+
/* @__PURE__ */ (0, import_jsx_runtime119.jsxs)("div", { className: "ods-stat__head", children: [
|
|
25728
|
+
/* @__PURE__ */ (0, import_jsx_runtime119.jsx)("div", { className: "ods-stat__label", children: label }),
|
|
25729
|
+
icon && /* @__PURE__ */ (0, import_jsx_runtime119.jsx)("span", { className: "ods-stat__icon", "aria-hidden": "true", children: icon })
|
|
25648
25730
|
] }),
|
|
25649
|
-
/* @__PURE__ */ (0,
|
|
25650
|
-
description && /* @__PURE__ */ (0,
|
|
25651
|
-
delta && /* @__PURE__ */ (0,
|
|
25652
|
-
/* @__PURE__ */ (0,
|
|
25653
|
-
/* @__PURE__ */ (0,
|
|
25654
|
-
deltaSuffix && /* @__PURE__ */ (0,
|
|
25731
|
+
/* @__PURE__ */ (0, import_jsx_runtime119.jsx)("div", { className: "ods-stat__value", children: value }),
|
|
25732
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime119.jsx)("div", { className: "ods-stat__description", children: description }),
|
|
25733
|
+
delta && /* @__PURE__ */ (0, import_jsx_runtime119.jsxs)("div", { className: cn("ods-stat__delta", `ods-stat__delta--${deltaTrend}`), children: [
|
|
25734
|
+
/* @__PURE__ */ (0, import_jsx_runtime119.jsx)("span", { className: "ods-stat__delta-arrow", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime119.jsx)(TrendIcon, { size: "xs" }) }),
|
|
25735
|
+
/* @__PURE__ */ (0, import_jsx_runtime119.jsx)("span", { className: "ods-stat__delta-value", children: delta }),
|
|
25736
|
+
deltaSuffix && /* @__PURE__ */ (0, import_jsx_runtime119.jsx)("span", { className: "ods-stat__delta-suffix", children: deltaSuffix })
|
|
25655
25737
|
] })
|
|
25656
25738
|
]
|
|
25657
25739
|
}
|
|
@@ -25662,7 +25744,7 @@ Stat.displayName = "Stat";
|
|
|
25662
25744
|
// src/components/StatusTiles/StatusTiles.tsx
|
|
25663
25745
|
var import_framer_motion32 = require("framer-motion");
|
|
25664
25746
|
var import_react139 = require("react");
|
|
25665
|
-
var
|
|
25747
|
+
var import_jsx_runtime120 = require("react/jsx-runtime");
|
|
25666
25748
|
var STATUS_COLORS = {
|
|
25667
25749
|
success: "var(--ods-status-success)",
|
|
25668
25750
|
failed: "var(--ods-status-failed)",
|
|
@@ -25734,7 +25816,7 @@ var StatusTiles = (0, import_react139.forwardRef)(
|
|
|
25734
25816
|
return `${t} \u2014 ${visible.length} runs (${summaryText})`;
|
|
25735
25817
|
}, [ariaLabel, title, visible]);
|
|
25736
25818
|
const interactive = Boolean(onTileHover || onTileClick);
|
|
25737
|
-
return /* @__PURE__ */ (0,
|
|
25819
|
+
return /* @__PURE__ */ (0, import_jsx_runtime120.jsxs)(
|
|
25738
25820
|
"div",
|
|
25739
25821
|
{
|
|
25740
25822
|
...rest,
|
|
@@ -25743,14 +25825,14 @@ var StatusTiles = (0, import_react139.forwardRef)(
|
|
|
25743
25825
|
role: "group",
|
|
25744
25826
|
"aria-label": resolvedAriaLabel,
|
|
25745
25827
|
children: [
|
|
25746
|
-
(title || summary) && /* @__PURE__ */ (0,
|
|
25747
|
-
title && /* @__PURE__ */ (0,
|
|
25748
|
-
summary && /* @__PURE__ */ (0,
|
|
25828
|
+
(title || summary) && /* @__PURE__ */ (0, import_jsx_runtime120.jsxs)("div", { className: "ods-status-tiles__head", children: [
|
|
25829
|
+
title && /* @__PURE__ */ (0, import_jsx_runtime120.jsx)("span", { className: "ods-status-tiles__title", children: title }),
|
|
25830
|
+
summary && /* @__PURE__ */ (0, import_jsx_runtime120.jsx)("span", { className: "ods-status-tiles__summary", children: summary })
|
|
25749
25831
|
] }),
|
|
25750
|
-
/* @__PURE__ */ (0,
|
|
25832
|
+
/* @__PURE__ */ (0, import_jsx_runtime120.jsx)("div", { className: "ods-status-tiles__row", style: { gap }, children: visible.map((tile, i) => {
|
|
25751
25833
|
const fill = tile.color ?? STATUS_COLORS[tile.status];
|
|
25752
25834
|
const tooltipText = tile.label !== void 0 ? typeof tile.label === "string" ? tile.label : void 0 : STATUS_TEXT[tile.status];
|
|
25753
|
-
return /* @__PURE__ */ (0,
|
|
25835
|
+
return /* @__PURE__ */ (0, import_jsx_runtime120.jsx)(
|
|
25754
25836
|
import_framer_motion32.motion.button,
|
|
25755
25837
|
{
|
|
25756
25838
|
type: "button",
|
|
@@ -25799,7 +25881,7 @@ StatusTiles.displayName = "StatusTiles";
|
|
|
25799
25881
|
// src/components/Stepper/Stepper.tsx
|
|
25800
25882
|
var import_icons38 = require("@octaviaflow/icons");
|
|
25801
25883
|
var import_react140 = require("react");
|
|
25802
|
-
var
|
|
25884
|
+
var import_jsx_runtime121 = require("react/jsx-runtime");
|
|
25803
25885
|
function deriveStatus(step, index, active) {
|
|
25804
25886
|
if (step.status) return step.status;
|
|
25805
25887
|
if (index < active) return "complete";
|
|
@@ -25867,7 +25949,7 @@ var Stepper = (0, import_react140.forwardRef)(
|
|
|
25867
25949
|
e.preventDefault();
|
|
25868
25950
|
goTo(i);
|
|
25869
25951
|
};
|
|
25870
|
-
return /* @__PURE__ */ (0,
|
|
25952
|
+
return /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(
|
|
25871
25953
|
"ol",
|
|
25872
25954
|
{
|
|
25873
25955
|
...rest,
|
|
@@ -25886,13 +25968,13 @@ var Stepper = (0, import_react140.forwardRef)(
|
|
|
25886
25968
|
const status = deriveStatus(step, i, activeIndex);
|
|
25887
25969
|
const isLast = i === steps.length - 1;
|
|
25888
25970
|
const segmentCompleted = showProgressTrail && i < activeIndex && status !== "error";
|
|
25889
|
-
const indicatorContent = step.indicator ?? (status === "complete" ? /* @__PURE__ */ (0,
|
|
25890
|
-
const labelText = /* @__PURE__ */ (0,
|
|
25891
|
-
/* @__PURE__ */ (0,
|
|
25892
|
-
step.optional && /* @__PURE__ */ (0,
|
|
25893
|
-
step.description && /* @__PURE__ */ (0,
|
|
25971
|
+
const indicatorContent = step.indicator ?? (status === "complete" ? /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(import_icons38.CheckmarkIcon, { size: "sm", "aria-hidden": true }) : status === "error" ? /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(import_icons38.ErrorIcon, { size: "sm", "aria-hidden": true }) : /* @__PURE__ */ (0, import_jsx_runtime121.jsx)("span", { className: "ods-stepper__indicator-num", children: i + 1 }));
|
|
25972
|
+
const labelText = /* @__PURE__ */ (0, import_jsx_runtime121.jsxs)("span", { className: "ods-stepper__label-text", children: [
|
|
25973
|
+
/* @__PURE__ */ (0, import_jsx_runtime121.jsx)("span", { className: "ods-stepper__label-title", children: step.label }),
|
|
25974
|
+
step.optional && /* @__PURE__ */ (0, import_jsx_runtime121.jsx)("span", { className: "ods-stepper__label-optional", children: "Optional" }),
|
|
25975
|
+
step.description && /* @__PURE__ */ (0, import_jsx_runtime121.jsx)("span", { className: "ods-stepper__label-desc", children: step.description })
|
|
25894
25976
|
] });
|
|
25895
|
-
const stepInner = isInteractive ? /* @__PURE__ */ (0,
|
|
25977
|
+
const stepInner = isInteractive ? /* @__PURE__ */ (0, import_jsx_runtime121.jsxs)(
|
|
25896
25978
|
"button",
|
|
25897
25979
|
{
|
|
25898
25980
|
type: "button",
|
|
@@ -25904,7 +25986,7 @@ var Stepper = (0, import_react140.forwardRef)(
|
|
|
25904
25986
|
onClick: handleClick(i),
|
|
25905
25987
|
onKeyDown: (e) => handleKeyDown(e, i),
|
|
25906
25988
|
children: [
|
|
25907
|
-
/* @__PURE__ */ (0,
|
|
25989
|
+
/* @__PURE__ */ (0, import_jsx_runtime121.jsx)(
|
|
25908
25990
|
"span",
|
|
25909
25991
|
{
|
|
25910
25992
|
className: cn(
|
|
@@ -25918,13 +26000,13 @@ var Stepper = (0, import_react140.forwardRef)(
|
|
|
25918
26000
|
labelText
|
|
25919
26001
|
]
|
|
25920
26002
|
}
|
|
25921
|
-
) : /* @__PURE__ */ (0,
|
|
26003
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime121.jsxs)(
|
|
25922
26004
|
"span",
|
|
25923
26005
|
{
|
|
25924
26006
|
className: "ods-stepper__step-static",
|
|
25925
26007
|
"aria-current": status === "active" ? "step" : void 0,
|
|
25926
26008
|
children: [
|
|
25927
|
-
/* @__PURE__ */ (0,
|
|
26009
|
+
/* @__PURE__ */ (0, import_jsx_runtime121.jsx)(
|
|
25928
26010
|
"span",
|
|
25929
26011
|
{
|
|
25930
26012
|
className: cn(
|
|
@@ -25939,7 +26021,7 @@ var Stepper = (0, import_react140.forwardRef)(
|
|
|
25939
26021
|
]
|
|
25940
26022
|
}
|
|
25941
26023
|
);
|
|
25942
|
-
return /* @__PURE__ */ (0,
|
|
26024
|
+
return /* @__PURE__ */ (0, import_jsx_runtime121.jsxs)(
|
|
25943
26025
|
"li",
|
|
25944
26026
|
{
|
|
25945
26027
|
className: cn(
|
|
@@ -25949,7 +26031,7 @@ var Stepper = (0, import_react140.forwardRef)(
|
|
|
25949
26031
|
),
|
|
25950
26032
|
children: [
|
|
25951
26033
|
stepInner,
|
|
25952
|
-
!isLast && /* @__PURE__ */ (0,
|
|
26034
|
+
!isLast && /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(
|
|
25953
26035
|
"span",
|
|
25954
26036
|
{
|
|
25955
26037
|
className: cn(
|
|
@@ -25973,7 +26055,7 @@ Stepper.displayName = "Stepper";
|
|
|
25973
26055
|
// src/components/Sankey/Sankey.tsx
|
|
25974
26056
|
var import_framer_motion33 = require("framer-motion");
|
|
25975
26057
|
var import_react141 = require("react");
|
|
25976
|
-
var
|
|
26058
|
+
var import_jsx_runtime122 = require("react/jsx-runtime");
|
|
25977
26059
|
var defaultFormat7 = (n) => {
|
|
25978
26060
|
if (Math.abs(n) >= 1e6) return `${(n / 1e6).toFixed(1)}M`;
|
|
25979
26061
|
if (Math.abs(n) >= 1e3) return `${(n / 1e3).toFixed(1)}k`;
|
|
@@ -26197,7 +26279,7 @@ var Sankey = (0, import_react141.forwardRef)(function Sankey2({
|
|
|
26197
26279
|
const t = typeof title === "string" ? title : "Sankey";
|
|
26198
26280
|
return `${t} \u2014 ${nodes.length} nodes, ${links.length} flows`;
|
|
26199
26281
|
}, [ariaLabel, title, nodes.length, links.length]);
|
|
26200
|
-
return /* @__PURE__ */ (0,
|
|
26282
|
+
return /* @__PURE__ */ (0, import_jsx_runtime122.jsxs)(
|
|
26201
26283
|
"div",
|
|
26202
26284
|
{
|
|
26203
26285
|
...rest,
|
|
@@ -26206,11 +26288,11 @@ var Sankey = (0, import_react141.forwardRef)(function Sankey2({
|
|
|
26206
26288
|
role: "group",
|
|
26207
26289
|
"aria-label": resolvedAriaLabel,
|
|
26208
26290
|
children: [
|
|
26209
|
-
(title || total) && /* @__PURE__ */ (0,
|
|
26210
|
-
title && /* @__PURE__ */ (0,
|
|
26211
|
-
total && /* @__PURE__ */ (0,
|
|
26291
|
+
(title || total) && /* @__PURE__ */ (0, import_jsx_runtime122.jsxs)("div", { className: "ods-sankey__head", children: [
|
|
26292
|
+
title && /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("div", { className: "ods-sankey__title", children: title }),
|
|
26293
|
+
total && /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("div", { className: "ods-sankey__total", children: total })
|
|
26212
26294
|
] }),
|
|
26213
|
-
/* @__PURE__ */ (0,
|
|
26295
|
+
/* @__PURE__ */ (0, import_jsx_runtime122.jsx)("div", { className: "ods-sankey__plot", style: { width, height }, children: /* @__PURE__ */ (0, import_jsx_runtime122.jsxs)(
|
|
26214
26296
|
"svg",
|
|
26215
26297
|
{
|
|
26216
26298
|
className: "ods-sankey__svg",
|
|
@@ -26220,7 +26302,7 @@ var Sankey = (0, import_react141.forwardRef)(function Sankey2({
|
|
|
26220
26302
|
layoutLinks.map((l) => {
|
|
26221
26303
|
const color = l.color ?? linkColor ?? l.sourceNode.color ?? nodeColor;
|
|
26222
26304
|
const active = hoveredLink === l || hoveredNode?.id === l.source || hoveredNode?.id === l.target;
|
|
26223
|
-
return /* @__PURE__ */ (0,
|
|
26305
|
+
return /* @__PURE__ */ (0, import_jsx_runtime122.jsx)(
|
|
26224
26306
|
import_framer_motion33.motion.path,
|
|
26225
26307
|
{
|
|
26226
26308
|
d: l.path,
|
|
@@ -26248,7 +26330,7 @@ var Sankey = (0, import_react141.forwardRef)(function Sankey2({
|
|
|
26248
26330
|
duration: 0.6,
|
|
26249
26331
|
ease: [0.16, 1, 0.3, 1]
|
|
26250
26332
|
},
|
|
26251
|
-
children: /* @__PURE__ */ (0,
|
|
26333
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("title", { children: `${l.sourceNode.label} \u2192 ${l.targetNode.label}: ${formatValue(l.value)}` })
|
|
26252
26334
|
},
|
|
26253
26335
|
`${reactId}-link-${l.source}-${l.target}`
|
|
26254
26336
|
);
|
|
@@ -26259,7 +26341,7 @@ var Sankey = (0, import_react141.forwardRef)(function Sankey2({
|
|
|
26259
26341
|
const isFirst = n.column === 0;
|
|
26260
26342
|
const isLast = n.column === columnCount - 1;
|
|
26261
26343
|
const active = hoveredNode === n;
|
|
26262
|
-
return /* @__PURE__ */ (0,
|
|
26344
|
+
return /* @__PURE__ */ (0, import_jsx_runtime122.jsxs)(
|
|
26263
26345
|
"g",
|
|
26264
26346
|
{
|
|
26265
26347
|
className: "ods-sankey__node-group",
|
|
@@ -26267,7 +26349,7 @@ var Sankey = (0, import_react141.forwardRef)(function Sankey2({
|
|
|
26267
26349
|
onMouseLeave: () => fireNode(null),
|
|
26268
26350
|
onClick: onNodeClick ? () => onNodeClick(n) : void 0,
|
|
26269
26351
|
children: [
|
|
26270
|
-
/* @__PURE__ */ (0,
|
|
26352
|
+
/* @__PURE__ */ (0, import_jsx_runtime122.jsx)(
|
|
26271
26353
|
import_framer_motion33.motion.rect,
|
|
26272
26354
|
{
|
|
26273
26355
|
x: n.x,
|
|
@@ -26296,10 +26378,10 @@ var Sankey = (0, import_react141.forwardRef)(function Sankey2({
|
|
|
26296
26378
|
delay: disableAnimation ? 0 : 0.2 + n.column * 0.05,
|
|
26297
26379
|
ease: [0.16, 1, 0.3, 1]
|
|
26298
26380
|
},
|
|
26299
|
-
children: /* @__PURE__ */ (0,
|
|
26381
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime122.jsx)("title", { children: `${n.label} \u2014 in ${formatValue(n.inFlow)} \xB7 out ${formatValue(n.outFlow)}` })
|
|
26300
26382
|
}
|
|
26301
26383
|
),
|
|
26302
|
-
/* @__PURE__ */ (0,
|
|
26384
|
+
/* @__PURE__ */ (0, import_jsx_runtime122.jsx)(
|
|
26303
26385
|
"text",
|
|
26304
26386
|
{
|
|
26305
26387
|
x: isFirst ? n.x - 6 : isLast ? n.x + nodeWidth + 6 : n.x + nodeWidth + 6,
|
|
@@ -26327,7 +26409,7 @@ Sankey.displayName = "Sankey";
|
|
|
26327
26409
|
// src/components/Switch/Switch.tsx
|
|
26328
26410
|
var import_react142 = require("react");
|
|
26329
26411
|
var import_react_aria12 = require("react-aria");
|
|
26330
|
-
var
|
|
26412
|
+
var import_jsx_runtime123 = require("react/jsx-runtime");
|
|
26331
26413
|
var Switch = (0, import_react142.forwardRef)(function Switch2({
|
|
26332
26414
|
checked,
|
|
26333
26415
|
defaultChecked,
|
|
@@ -26376,7 +26458,7 @@ var Switch = (0, import_react142.forwardRef)(function Switch2({
|
|
|
26376
26458
|
onBlur: _onBlur,
|
|
26377
26459
|
...passthroughProps
|
|
26378
26460
|
} = props;
|
|
26379
|
-
return /* @__PURE__ */ (0,
|
|
26461
|
+
return /* @__PURE__ */ (0, import_jsx_runtime123.jsxs)(
|
|
26380
26462
|
"label",
|
|
26381
26463
|
{
|
|
26382
26464
|
className: cn(
|
|
@@ -26387,7 +26469,7 @@ var Switch = (0, import_react142.forwardRef)(function Switch2({
|
|
|
26387
26469
|
className
|
|
26388
26470
|
),
|
|
26389
26471
|
children: [
|
|
26390
|
-
/* @__PURE__ */ (0,
|
|
26472
|
+
/* @__PURE__ */ (0, import_jsx_runtime123.jsx)(
|
|
26391
26473
|
"input",
|
|
26392
26474
|
{
|
|
26393
26475
|
...passthroughProps,
|
|
@@ -26396,17 +26478,17 @@ var Switch = (0, import_react142.forwardRef)(function Switch2({
|
|
|
26396
26478
|
className: "ods-switch__input"
|
|
26397
26479
|
}
|
|
26398
26480
|
),
|
|
26399
|
-
/* @__PURE__ */ (0,
|
|
26481
|
+
/* @__PURE__ */ (0, import_jsx_runtime123.jsx)(
|
|
26400
26482
|
"div",
|
|
26401
26483
|
{
|
|
26402
26484
|
className: cn("ods-switch__track", isOn && "ods-switch__track--on"),
|
|
26403
26485
|
"aria-hidden": "true",
|
|
26404
|
-
children: /* @__PURE__ */ (0,
|
|
26486
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("div", { className: "ods-switch__thumb" })
|
|
26405
26487
|
}
|
|
26406
26488
|
),
|
|
26407
|
-
(label || description) && /* @__PURE__ */ (0,
|
|
26408
|
-
label && /* @__PURE__ */ (0,
|
|
26409
|
-
description && /* @__PURE__ */ (0,
|
|
26489
|
+
(label || description) && /* @__PURE__ */ (0, import_jsx_runtime123.jsxs)("div", { className: "ods-switch__text", children: [
|
|
26490
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("span", { className: "ods-switch__label", children: label }),
|
|
26491
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("span", { className: "ods-switch__description", children: description })
|
|
26410
26492
|
] })
|
|
26411
26493
|
]
|
|
26412
26494
|
}
|
|
@@ -26417,7 +26499,7 @@ Switch.displayName = "Switch";
|
|
|
26417
26499
|
// src/components/Table/Table.tsx
|
|
26418
26500
|
var import_react143 = require("react");
|
|
26419
26501
|
var import_icons39 = require("@octaviaflow/icons");
|
|
26420
|
-
var
|
|
26502
|
+
var import_jsx_runtime124 = require("react/jsx-runtime");
|
|
26421
26503
|
function TableInner({
|
|
26422
26504
|
columns,
|
|
26423
26505
|
data,
|
|
@@ -26468,7 +26550,7 @@ function TableInner({
|
|
|
26468
26550
|
[onSelectionChange, selectedRows]
|
|
26469
26551
|
);
|
|
26470
26552
|
const totalCols = columns.length + (selectable ? 1 : 0) + (expandable ? 1 : 0);
|
|
26471
|
-
return /* @__PURE__ */ (0,
|
|
26553
|
+
return /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
|
|
26472
26554
|
"div",
|
|
26473
26555
|
{
|
|
26474
26556
|
...rest,
|
|
@@ -26476,9 +26558,9 @@ function TableInner({
|
|
|
26476
26558
|
className: cn("ods-table-wrapper", className),
|
|
26477
26559
|
role: "region",
|
|
26478
26560
|
"aria-label": ariaLabel,
|
|
26479
|
-
children: /* @__PURE__ */ (0,
|
|
26480
|
-
/* @__PURE__ */ (0,
|
|
26481
|
-
selectable && /* @__PURE__ */ (0,
|
|
26561
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime124.jsxs)("table", { className: "ods-table", children: [
|
|
26562
|
+
/* @__PURE__ */ (0, import_jsx_runtime124.jsx)("thead", { className: "ods-table__header", children: /* @__PURE__ */ (0, import_jsx_runtime124.jsxs)("tr", { children: [
|
|
26563
|
+
selectable && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("th", { className: "ods-table__cell--checkbox", scope: "col", children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
|
|
26482
26564
|
"input",
|
|
26483
26565
|
{
|
|
26484
26566
|
type: "checkbox",
|
|
@@ -26487,8 +26569,8 @@ function TableInner({
|
|
|
26487
26569
|
onChange: handleSelectAll
|
|
26488
26570
|
}
|
|
26489
26571
|
) }),
|
|
26490
|
-
expandable && /* @__PURE__ */ (0,
|
|
26491
|
-
columns.map((col) => /* @__PURE__ */ (0,
|
|
26572
|
+
expandable && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("th", { className: "ods-table__cell--expand", scope: "col", "aria-label": "Expand" }),
|
|
26573
|
+
columns.map((col) => /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
|
|
26492
26574
|
"th",
|
|
26493
26575
|
{
|
|
26494
26576
|
className: cn("ods-table__cell", col.sortable && "ods-table__cell--sortable"),
|
|
@@ -26496,9 +26578,9 @@ function TableInner({
|
|
|
26496
26578
|
scope: "col",
|
|
26497
26579
|
"aria-sort": sortKey === col.key ? sortDirection === "asc" ? "ascending" : "descending" : void 0,
|
|
26498
26580
|
onClick: col.sortable ? () => handleSort(col.key) : void 0,
|
|
26499
|
-
children: /* @__PURE__ */ (0,
|
|
26581
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime124.jsxs)("span", { className: "ods-table__header-content", children: [
|
|
26500
26582
|
col.header,
|
|
26501
|
-
col.sortable && /* @__PURE__ */ (0,
|
|
26583
|
+
col.sortable && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
|
|
26502
26584
|
"span",
|
|
26503
26585
|
{
|
|
26504
26586
|
className: cn(
|
|
@@ -26506,7 +26588,7 @@ function TableInner({
|
|
|
26506
26588
|
sortKey === col.key && "ods-table__sort-icon--active"
|
|
26507
26589
|
),
|
|
26508
26590
|
"aria-hidden": "true",
|
|
26509
|
-
children: sortKey === col.key ? sortDirection === "desc" ? /* @__PURE__ */ (0,
|
|
26591
|
+
children: sortKey === col.key ? sortDirection === "desc" ? /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(import_icons39.CaretDownIcon, { size: "xs" }) : /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(import_icons39.CaretUpIcon, { size: "xs" }) : /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(import_icons39.CaretSortIcon, { size: "xs" })
|
|
26510
26592
|
}
|
|
26511
26593
|
)
|
|
26512
26594
|
] })
|
|
@@ -26514,10 +26596,10 @@ function TableInner({
|
|
|
26514
26596
|
col.key
|
|
26515
26597
|
))
|
|
26516
26598
|
] }) }),
|
|
26517
|
-
/* @__PURE__ */ (0,
|
|
26518
|
-
loading && /* @__PURE__ */ (0,
|
|
26519
|
-
!loading && data.length === 0 && /* @__PURE__ */ (0,
|
|
26520
|
-
data.map((row, rowIndex) => /* @__PURE__ */ (0,
|
|
26599
|
+
/* @__PURE__ */ (0, import_jsx_runtime124.jsxs)("tbody", { children: [
|
|
26600
|
+
loading && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("tr", { children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("td", { colSpan: totalCols, className: "ods-table__loading", children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("div", { className: "ods-table__loading-bar" }) }) }),
|
|
26601
|
+
!loading && data.length === 0 && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("tr", { children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("td", { colSpan: totalCols, className: "ods-table__empty", children: emptyMessage }) }),
|
|
26602
|
+
data.map((row, rowIndex) => /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
|
|
26521
26603
|
TableRow,
|
|
26522
26604
|
{
|
|
26523
26605
|
row,
|
|
@@ -26551,14 +26633,14 @@ function TableRow({
|
|
|
26551
26633
|
}) {
|
|
26552
26634
|
const isSelected = selectedRows?.has(rowIndex) ?? false;
|
|
26553
26635
|
const [expanded, setExpanded] = (0, import_react143.useState)(false);
|
|
26554
|
-
return /* @__PURE__ */ (0,
|
|
26555
|
-
/* @__PURE__ */ (0,
|
|
26636
|
+
return /* @__PURE__ */ (0, import_jsx_runtime124.jsxs)(import_jsx_runtime124.Fragment, { children: [
|
|
26637
|
+
/* @__PURE__ */ (0, import_jsx_runtime124.jsxs)(
|
|
26556
26638
|
"tr",
|
|
26557
26639
|
{
|
|
26558
26640
|
className: cn("ods-table__row", isSelected && "ods-table__row--selected"),
|
|
26559
26641
|
"data-row-index": rowIndex,
|
|
26560
26642
|
children: [
|
|
26561
|
-
selectable && /* @__PURE__ */ (0,
|
|
26643
|
+
selectable && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("td", { className: "ods-table__cell--checkbox", children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
|
|
26562
26644
|
"input",
|
|
26563
26645
|
{
|
|
26564
26646
|
type: "checkbox",
|
|
@@ -26567,7 +26649,7 @@ function TableRow({
|
|
|
26567
26649
|
onChange: () => onSelectRow(rowIndex)
|
|
26568
26650
|
}
|
|
26569
26651
|
) }),
|
|
26570
|
-
expandable && /* @__PURE__ */ (0,
|
|
26652
|
+
expandable && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("td", { className: "ods-table__cell--expand", children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
|
|
26571
26653
|
"button",
|
|
26572
26654
|
{
|
|
26573
26655
|
type: "button",
|
|
@@ -26575,14 +26657,14 @@ function TableRow({
|
|
|
26575
26657
|
"aria-label": expanded ? "Collapse row" : "Expand row",
|
|
26576
26658
|
"aria-expanded": expanded,
|
|
26577
26659
|
onClick: () => setExpanded(!expanded),
|
|
26578
|
-
children: /* @__PURE__ */ (0,
|
|
26660
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(import_icons39.CaretRightIcon, { size: "xs" })
|
|
26579
26661
|
}
|
|
26580
26662
|
) }),
|
|
26581
|
-
columns.map((col) => /* @__PURE__ */ (0,
|
|
26663
|
+
columns.map((col) => /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("td", { className: "ods-table__cell", children: col.render ? col.render(row[col.key], row, rowIndex) : row[col.key] }, col.key))
|
|
26582
26664
|
]
|
|
26583
26665
|
}
|
|
26584
26666
|
),
|
|
26585
|
-
expandable && expanded && renderExpanded && /* @__PURE__ */ (0,
|
|
26667
|
+
expandable && expanded && renderExpanded && /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("tr", { className: "ods-table__row--expanded", children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("td", { colSpan: totalCols, className: "ods-table__expanded-cell", children: renderExpanded(row, rowIndex) }) })
|
|
26586
26668
|
] });
|
|
26587
26669
|
}
|
|
26588
26670
|
|
|
@@ -26590,7 +26672,7 @@ function TableRow({
|
|
|
26590
26672
|
var import_framer_motion34 = require("framer-motion");
|
|
26591
26673
|
var import_react144 = require("react");
|
|
26592
26674
|
var import_react_aria13 = require("react-aria");
|
|
26593
|
-
var
|
|
26675
|
+
var import_jsx_runtime125 = require("react/jsx-runtime");
|
|
26594
26676
|
function TabButton({
|
|
26595
26677
|
item,
|
|
26596
26678
|
state,
|
|
@@ -26601,7 +26683,7 @@ function TabButton({
|
|
|
26601
26683
|
const isSelected = state.selectedKey === item.key;
|
|
26602
26684
|
const isDisabled = state.disabledKeys.has(item.key);
|
|
26603
26685
|
const { onDrag, onDragStart, onDragEnd, onAnimationStart, ...safeTabProps } = tabProps;
|
|
26604
|
-
return /* @__PURE__ */ (0,
|
|
26686
|
+
return /* @__PURE__ */ (0, import_jsx_runtime125.jsxs)(
|
|
26605
26687
|
import_framer_motion34.motion.div,
|
|
26606
26688
|
{
|
|
26607
26689
|
...safeTabProps,
|
|
@@ -26613,7 +26695,7 @@ function TabButton({
|
|
|
26613
26695
|
),
|
|
26614
26696
|
children: [
|
|
26615
26697
|
item.rendered,
|
|
26616
|
-
isSelected && /* @__PURE__ */ (0,
|
|
26698
|
+
isSelected && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
|
|
26617
26699
|
import_framer_motion34.motion.div,
|
|
26618
26700
|
{
|
|
26619
26701
|
className: "ods-tabs__indicator",
|
|
@@ -26628,7 +26710,7 @@ function TabButton({
|
|
|
26628
26710
|
function TabPanelContent({ state, panelContent, ...props }) {
|
|
26629
26711
|
const ref = (0, import_react144.useRef)(null);
|
|
26630
26712
|
const { tabPanelProps } = (0, import_react_aria13.useTabPanel)(props, state, ref);
|
|
26631
|
-
return /* @__PURE__ */ (0,
|
|
26713
|
+
return /* @__PURE__ */ (0, import_jsx_runtime125.jsx)("div", { ...tabPanelProps, ref, className: "ods-tabs__panel", children: panelContent });
|
|
26632
26714
|
}
|
|
26633
26715
|
var SCROLL_EDGE_EPSILON = 1;
|
|
26634
26716
|
var SCROLL_STEP_PX = 200;
|
|
@@ -26657,9 +26739,9 @@ function Tabs({
|
|
|
26657
26739
|
return map;
|
|
26658
26740
|
}, [items]);
|
|
26659
26741
|
const stateProps = {
|
|
26660
|
-
children: items.map((item) => /* @__PURE__ */ (0,
|
|
26661
|
-
item.icon && /* @__PURE__ */ (0,
|
|
26662
|
-
/* @__PURE__ */ (0,
|
|
26742
|
+
children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime125.jsxs)($05678f3aee5e7d1a$export$6d08773d2e66f8f2, { textValue: item.label, children: [
|
|
26743
|
+
item.icon && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)("span", { className: "ods-tabs__icon", children: item.icon }),
|
|
26744
|
+
/* @__PURE__ */ (0, import_jsx_runtime125.jsx)("span", { children: item.label })
|
|
26663
26745
|
] }, item.value)),
|
|
26664
26746
|
selectedKey,
|
|
26665
26747
|
onSelectionChange: handleSelectionChange,
|
|
@@ -26697,9 +26779,9 @@ function Tabs({
|
|
|
26697
26779
|
el.scrollBy({ left: dir * SCROLL_STEP_PX, behavior: "smooth" });
|
|
26698
26780
|
};
|
|
26699
26781
|
const currentPanelContent = panelContentMap.get(String(selectedKey));
|
|
26700
|
-
return /* @__PURE__ */ (0,
|
|
26701
|
-
/* @__PURE__ */ (0,
|
|
26702
|
-
orientation === "horizontal" && canScrollLeft && /* @__PURE__ */ (0,
|
|
26782
|
+
return /* @__PURE__ */ (0, import_jsx_runtime125.jsxs)("div", { className: cn("ods-tabs", `ods-tabs--${orientation}`, className), children: [
|
|
26783
|
+
/* @__PURE__ */ (0, import_jsx_runtime125.jsxs)("div", { className: "ods-tabs__list-wrap", children: [
|
|
26784
|
+
orientation === "horizontal" && canScrollLeft && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
|
|
26703
26785
|
"button",
|
|
26704
26786
|
{
|
|
26705
26787
|
type: "button",
|
|
@@ -26707,16 +26789,16 @@ function Tabs({
|
|
|
26707
26789
|
onClick: () => scrollBy(-1),
|
|
26708
26790
|
"aria-label": "Scroll tabs left",
|
|
26709
26791
|
tabIndex: -1,
|
|
26710
|
-
children: /* @__PURE__ */ (0,
|
|
26792
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(ChevronSvg, { dir: "left" })
|
|
26711
26793
|
}
|
|
26712
26794
|
),
|
|
26713
|
-
/* @__PURE__ */ (0,
|
|
26795
|
+
/* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
|
|
26714
26796
|
"div",
|
|
26715
26797
|
{
|
|
26716
26798
|
className: "ods-tabs__scroller",
|
|
26717
26799
|
ref: scrollContainerRef,
|
|
26718
26800
|
onScroll: orientation === "horizontal" ? onScroll : void 0,
|
|
26719
|
-
children: /* @__PURE__ */ (0,
|
|
26801
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime125.jsx)("div", { ...tabListProps, ref, className: "ods-tabs__list", children: [...state.collection].map((item) => /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
|
|
26720
26802
|
TabButton,
|
|
26721
26803
|
{
|
|
26722
26804
|
item,
|
|
@@ -26727,7 +26809,7 @@ function Tabs({
|
|
|
26727
26809
|
)) })
|
|
26728
26810
|
}
|
|
26729
26811
|
),
|
|
26730
|
-
orientation === "horizontal" && canScrollRight && /* @__PURE__ */ (0,
|
|
26812
|
+
orientation === "horizontal" && canScrollRight && /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
|
|
26731
26813
|
"button",
|
|
26732
26814
|
{
|
|
26733
26815
|
type: "button",
|
|
@@ -26735,16 +26817,16 @@ function Tabs({
|
|
|
26735
26817
|
onClick: () => scrollBy(1),
|
|
26736
26818
|
"aria-label": "Scroll tabs right",
|
|
26737
26819
|
tabIndex: -1,
|
|
26738
|
-
children: /* @__PURE__ */ (0,
|
|
26820
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(ChevronSvg, { dir: "right" })
|
|
26739
26821
|
}
|
|
26740
26822
|
)
|
|
26741
26823
|
] }),
|
|
26742
|
-
/* @__PURE__ */ (0,
|
|
26824
|
+
/* @__PURE__ */ (0, import_jsx_runtime125.jsx)(TabPanelContent, { state, panelContent: currentPanelContent }, state.selectedKey)
|
|
26743
26825
|
] });
|
|
26744
26826
|
}
|
|
26745
26827
|
function ChevronSvg({ dir }) {
|
|
26746
26828
|
const d = dir === "left" ? "M11 4L5 10l6 6" : "M9 4l6 6-6 6";
|
|
26747
|
-
return /* @__PURE__ */ (0,
|
|
26829
|
+
return /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
|
|
26748
26830
|
"svg",
|
|
26749
26831
|
{
|
|
26750
26832
|
width: "14",
|
|
@@ -26756,7 +26838,7 @@ function ChevronSvg({ dir }) {
|
|
|
26756
26838
|
strokeLinecap: "round",
|
|
26757
26839
|
strokeLinejoin: "round",
|
|
26758
26840
|
"aria-hidden": "true",
|
|
26759
|
-
children: /* @__PURE__ */ (0,
|
|
26841
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime125.jsx)("path", { d })
|
|
26760
26842
|
}
|
|
26761
26843
|
);
|
|
26762
26844
|
}
|
|
@@ -26764,7 +26846,7 @@ function ChevronSvg({ dir }) {
|
|
|
26764
26846
|
// src/components/TagsInput/TagsInput.tsx
|
|
26765
26847
|
var import_react145 = require("react");
|
|
26766
26848
|
var import_icons40 = require("@octaviaflow/icons");
|
|
26767
|
-
var
|
|
26849
|
+
var import_jsx_runtime126 = require("react/jsx-runtime");
|
|
26768
26850
|
var TagsInput = (0, import_react145.forwardRef)(
|
|
26769
26851
|
function TagsInput2({
|
|
26770
26852
|
label,
|
|
@@ -26815,7 +26897,7 @@ var TagsInput = (0, import_react145.forwardRef)(
|
|
|
26815
26897
|
}
|
|
26816
26898
|
};
|
|
26817
26899
|
const describedBy = [consumerDescribedBy, hintId].filter(Boolean).join(" ") || void 0;
|
|
26818
|
-
return /* @__PURE__ */ (0,
|
|
26900
|
+
return /* @__PURE__ */ (0, import_jsx_runtime126.jsxs)(
|
|
26819
26901
|
"div",
|
|
26820
26902
|
{
|
|
26821
26903
|
className: cn(
|
|
@@ -26826,7 +26908,7 @@ var TagsInput = (0, import_react145.forwardRef)(
|
|
|
26826
26908
|
wrapperClassName
|
|
26827
26909
|
),
|
|
26828
26910
|
children: [
|
|
26829
|
-
label && /* @__PURE__ */ (0,
|
|
26911
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
|
|
26830
26912
|
"label",
|
|
26831
26913
|
{
|
|
26832
26914
|
id: labelId,
|
|
@@ -26835,10 +26917,10 @@ var TagsInput = (0, import_react145.forwardRef)(
|
|
|
26835
26917
|
children: label
|
|
26836
26918
|
}
|
|
26837
26919
|
),
|
|
26838
|
-
/* @__PURE__ */ (0,
|
|
26839
|
-
value.map((tag, i) => /* @__PURE__ */ (0,
|
|
26840
|
-
/* @__PURE__ */ (0,
|
|
26841
|
-
/* @__PURE__ */ (0,
|
|
26920
|
+
/* @__PURE__ */ (0, import_jsx_runtime126.jsxs)("div", { className: "ods-tags__field", children: [
|
|
26921
|
+
value.map((tag, i) => /* @__PURE__ */ (0, import_jsx_runtime126.jsxs)("span", { className: "ods-tags__chip", children: [
|
|
26922
|
+
/* @__PURE__ */ (0, import_jsx_runtime126.jsx)("span", { className: "ods-tags__chip-text", children: tag }),
|
|
26923
|
+
/* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
|
|
26842
26924
|
"button",
|
|
26843
26925
|
{
|
|
26844
26926
|
type: "button",
|
|
@@ -26846,11 +26928,11 @@ var TagsInput = (0, import_react145.forwardRef)(
|
|
|
26846
26928
|
onClick: () => removeTag(i),
|
|
26847
26929
|
"aria-label": `Remove ${tag}`,
|
|
26848
26930
|
disabled,
|
|
26849
|
-
children: /* @__PURE__ */ (0,
|
|
26931
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(import_icons40.CloseIcon, { size: "xs" })
|
|
26850
26932
|
}
|
|
26851
26933
|
)
|
|
26852
26934
|
] }, `${tag}-${i}`)),
|
|
26853
|
-
/* @__PURE__ */ (0,
|
|
26935
|
+
/* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
|
|
26854
26936
|
"input",
|
|
26855
26937
|
{
|
|
26856
26938
|
...rest,
|
|
@@ -26870,7 +26952,7 @@ var TagsInput = (0, import_react145.forwardRef)(
|
|
|
26870
26952
|
}
|
|
26871
26953
|
)
|
|
26872
26954
|
] }),
|
|
26873
|
-
error ? /* @__PURE__ */ (0,
|
|
26955
|
+
error ? /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
|
|
26874
26956
|
"div",
|
|
26875
26957
|
{
|
|
26876
26958
|
id: hintId,
|
|
@@ -26878,7 +26960,7 @@ var TagsInput = (0, import_react145.forwardRef)(
|
|
|
26878
26960
|
role: "alert",
|
|
26879
26961
|
children: error
|
|
26880
26962
|
}
|
|
26881
|
-
) : helperText ? /* @__PURE__ */ (0,
|
|
26963
|
+
) : helperText ? /* @__PURE__ */ (0, import_jsx_runtime126.jsx)("div", { id: hintId, className: "ods-tags__hint", children: helperText }) : null
|
|
26882
26964
|
]
|
|
26883
26965
|
}
|
|
26884
26966
|
);
|
|
@@ -26888,7 +26970,7 @@ TagsInput.displayName = "TagsInput";
|
|
|
26888
26970
|
|
|
26889
26971
|
// src/components/TemplateCard/TemplateCard.tsx
|
|
26890
26972
|
var import_react146 = require("react");
|
|
26891
|
-
var
|
|
26973
|
+
var import_jsx_runtime127 = require("react/jsx-runtime");
|
|
26892
26974
|
var TemplateCard = (0, import_react146.forwardRef)(
|
|
26893
26975
|
function TemplateCard2({
|
|
26894
26976
|
name,
|
|
@@ -26924,7 +27006,7 @@ var TemplateCard = (0, import_react146.forwardRef)(
|
|
|
26924
27006
|
const isInteractive = Boolean(href || onClick) && !disabled;
|
|
26925
27007
|
const hasInternalInteractive = Boolean(cta || footer);
|
|
26926
27008
|
const useStretchedLink = Boolean(href) && !disabled && hasInternalInteractive;
|
|
26927
|
-
const titleContent = useStretchedLink ? /* @__PURE__ */ (0,
|
|
27009
|
+
const titleContent = useStretchedLink ? /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
|
|
26928
27010
|
"a",
|
|
26929
27011
|
{
|
|
26930
27012
|
className: "ods-template-card__stretched-link",
|
|
@@ -26936,8 +27018,8 @@ var TemplateCard = (0, import_react146.forwardRef)(
|
|
|
26936
27018
|
const renderAuthor = () => {
|
|
26937
27019
|
if (!author) return null;
|
|
26938
27020
|
const derivedInitials = author.avatar?.initials ?? (typeof author.name === "string" ? author.name.charAt(0).toUpperCase() : void 0);
|
|
26939
|
-
return /* @__PURE__ */ (0,
|
|
26940
|
-
(author.avatar || derivedInitials) && /* @__PURE__ */ (0,
|
|
27021
|
+
return /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)("div", { className: "ods-template-card__author", children: [
|
|
27022
|
+
(author.avatar || derivedInitials) && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
|
|
26941
27023
|
Avatar,
|
|
26942
27024
|
{
|
|
26943
27025
|
size: "xs",
|
|
@@ -26947,8 +27029,8 @@ var TemplateCard = (0, import_react146.forwardRef)(
|
|
|
26947
27029
|
className: "ods-template-card__author-avatar"
|
|
26948
27030
|
}
|
|
26949
27031
|
),
|
|
26950
|
-
/* @__PURE__ */ (0,
|
|
26951
|
-
author.byline && /* @__PURE__ */ (0,
|
|
27032
|
+
/* @__PURE__ */ (0, import_jsx_runtime127.jsx)("span", { className: "ods-template-card__author-name", children: author.name }),
|
|
27033
|
+
author.byline && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("span", { className: "ods-template-card__author-byline", children: author.byline })
|
|
26952
27034
|
] });
|
|
26953
27035
|
};
|
|
26954
27036
|
const hasImage = Boolean(image);
|
|
@@ -26962,8 +27044,8 @@ var TemplateCard = (0, import_react146.forwardRef)(
|
|
|
26962
27044
|
if (iconConnector === "plus") return "+";
|
|
26963
27045
|
return iconConnector;
|
|
26964
27046
|
};
|
|
26965
|
-
const body = /* @__PURE__ */ (0,
|
|
26966
|
-
showMedia && /* @__PURE__ */ (0,
|
|
27047
|
+
const body = /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(import_jsx_runtime127.Fragment, { children: [
|
|
27048
|
+
showMedia && /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(
|
|
26967
27049
|
"div",
|
|
26968
27050
|
{
|
|
26969
27051
|
className: cn(
|
|
@@ -26976,9 +27058,9 @@ var TemplateCard = (0, import_react146.forwardRef)(
|
|
|
26976
27058
|
"aria-hidden": "true",
|
|
26977
27059
|
children: [
|
|
26978
27060
|
hasImage && image,
|
|
26979
|
-
hasIcon && /* @__PURE__ */ (0,
|
|
26980
|
-
hasIconFlow && /* @__PURE__ */ (0,
|
|
26981
|
-
i > 0 && /* @__PURE__ */ (0,
|
|
27061
|
+
hasIcon && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("span", { className: "ods-template-card__icon", children: icon }),
|
|
27062
|
+
hasIconFlow && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("span", { className: "ods-template-card__icon-flow", children: icons.map((step, i) => /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)("span", { className: "ods-template-card__icon-flow-item", children: [
|
|
27063
|
+
i > 0 && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
|
|
26982
27064
|
"span",
|
|
26983
27065
|
{
|
|
26984
27066
|
className: "ods-template-card__icon-connector",
|
|
@@ -26986,7 +27068,7 @@ var TemplateCard = (0, import_react146.forwardRef)(
|
|
|
26986
27068
|
children: renderConnector()
|
|
26987
27069
|
}
|
|
26988
27070
|
),
|
|
26989
|
-
/* @__PURE__ */ (0,
|
|
27071
|
+
/* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
|
|
26990
27072
|
"span",
|
|
26991
27073
|
{
|
|
26992
27074
|
className: cn(
|
|
@@ -26999,13 +27081,13 @@ var TemplateCard = (0, import_react146.forwardRef)(
|
|
|
26999
27081
|
}
|
|
27000
27082
|
)
|
|
27001
27083
|
] }, i)) }),
|
|
27002
|
-
badge && /* @__PURE__ */ (0,
|
|
27084
|
+
badge && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("span", { className: "ods-template-card__badge", children: badge })
|
|
27003
27085
|
]
|
|
27004
27086
|
}
|
|
27005
27087
|
),
|
|
27006
|
-
/* @__PURE__ */ (0,
|
|
27007
|
-
category && /* @__PURE__ */ (0,
|
|
27008
|
-
/* @__PURE__ */ (0,
|
|
27088
|
+
/* @__PURE__ */ (0, import_jsx_runtime127.jsxs)("div", { className: "ods-template-card__content", children: [
|
|
27089
|
+
category && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("div", { className: "ods-template-card__category", children: category }),
|
|
27090
|
+
/* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
|
|
27009
27091
|
Card.Title,
|
|
27010
27092
|
{
|
|
27011
27093
|
as: nameAs,
|
|
@@ -27014,7 +27096,7 @@ var TemplateCard = (0, import_react146.forwardRef)(
|
|
|
27014
27096
|
children: titleContent
|
|
27015
27097
|
}
|
|
27016
27098
|
),
|
|
27017
|
-
description && /* @__PURE__ */ (0,
|
|
27099
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
|
|
27018
27100
|
Card.Description,
|
|
27019
27101
|
{
|
|
27020
27102
|
id: descId,
|
|
@@ -27022,18 +27104,18 @@ var TemplateCard = (0, import_react146.forwardRef)(
|
|
|
27022
27104
|
children: description
|
|
27023
27105
|
}
|
|
27024
27106
|
),
|
|
27025
|
-
requirements && requirements.length > 0 && /* @__PURE__ */ (0,
|
|
27107
|
+
requirements && requirements.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
|
|
27026
27108
|
"div",
|
|
27027
27109
|
{
|
|
27028
27110
|
className: "ods-template-card__requirements",
|
|
27029
27111
|
"aria-label": "Requirements",
|
|
27030
|
-
children: requirements.map((r, i) => /* @__PURE__ */ (0,
|
|
27112
|
+
children: requirements.map((r, i) => /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("span", { className: "ods-template-card__requirement", children: r }, i))
|
|
27031
27113
|
}
|
|
27032
27114
|
),
|
|
27033
|
-
stats && stats.length > 0 && /* @__PURE__ */ (0,
|
|
27034
|
-
/* @__PURE__ */ (0,
|
|
27035
|
-
/* @__PURE__ */ (0,
|
|
27036
|
-
s.icon && /* @__PURE__ */ (0,
|
|
27115
|
+
stats && stats.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("dl", { className: "ods-template-card__stats", children: stats.map((s, i) => /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)("div", { className: "ods-template-card__stat", children: [
|
|
27116
|
+
/* @__PURE__ */ (0, import_jsx_runtime127.jsx)("dt", { className: "ods-template-card__stat-label", children: s.label }),
|
|
27117
|
+
/* @__PURE__ */ (0, import_jsx_runtime127.jsxs)("dd", { className: "ods-template-card__stat-value", children: [
|
|
27118
|
+
s.icon && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
|
|
27037
27119
|
"span",
|
|
27038
27120
|
{
|
|
27039
27121
|
className: "ods-template-card__stat-icon",
|
|
@@ -27044,12 +27126,12 @@ var TemplateCard = (0, import_react146.forwardRef)(
|
|
|
27044
27126
|
s.value
|
|
27045
27127
|
] })
|
|
27046
27128
|
] }, i)) }),
|
|
27047
|
-
tags && tags.length > 0 && /* @__PURE__ */ (0,
|
|
27048
|
-
(author || cta || footer) && /* @__PURE__ */ (0,
|
|
27129
|
+
tags && tags.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("div", { className: "ods-template-card__tags", children: tags.map((t, i) => /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("span", { className: "ods-template-card__tag", children: t }, i)) }),
|
|
27130
|
+
(author || cta || footer) && /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)("div", { className: "ods-template-card__footer-row", children: [
|
|
27049
27131
|
renderAuthor(),
|
|
27050
|
-
(cta || footer) && /* @__PURE__ */ (0,
|
|
27051
|
-
cta && /* @__PURE__ */ (0,
|
|
27052
|
-
footer && /* @__PURE__ */ (0,
|
|
27132
|
+
(cta || footer) && /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)("div", { className: "ods-template-card__footer-actions", children: [
|
|
27133
|
+
cta && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("div", { className: "ods-template-card__cta", children: cta }),
|
|
27134
|
+
footer && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("div", { className: "ods-template-card__footer", children: footer })
|
|
27053
27135
|
] })
|
|
27054
27136
|
] })
|
|
27055
27137
|
] })
|
|
@@ -27063,7 +27145,7 @@ var TemplateCard = (0, import_react146.forwardRef)(
|
|
|
27063
27145
|
className
|
|
27064
27146
|
);
|
|
27065
27147
|
if (href && !disabled && !useStretchedLink) {
|
|
27066
|
-
return /* @__PURE__ */ (0,
|
|
27148
|
+
return /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
|
|
27067
27149
|
Card,
|
|
27068
27150
|
{
|
|
27069
27151
|
asChild: true,
|
|
@@ -27072,7 +27154,7 @@ var TemplateCard = (0, import_react146.forwardRef)(
|
|
|
27072
27154
|
className: sharedClass,
|
|
27073
27155
|
"aria-labelledby": nameId,
|
|
27074
27156
|
"aria-describedby": descId,
|
|
27075
|
-
children: /* @__PURE__ */ (0,
|
|
27157
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
|
|
27076
27158
|
"a",
|
|
27077
27159
|
{
|
|
27078
27160
|
...rest,
|
|
@@ -27086,7 +27168,7 @@ var TemplateCard = (0, import_react146.forwardRef)(
|
|
|
27086
27168
|
}
|
|
27087
27169
|
);
|
|
27088
27170
|
}
|
|
27089
|
-
return /* @__PURE__ */ (0,
|
|
27171
|
+
return /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
|
|
27090
27172
|
Card,
|
|
27091
27173
|
{
|
|
27092
27174
|
...rest,
|
|
@@ -27109,7 +27191,7 @@ TemplateCard.displayName = "TemplateCard";
|
|
|
27109
27191
|
// src/components/TestimonialCard/TestimonialCard.tsx
|
|
27110
27192
|
var import_icons41 = require("@octaviaflow/icons");
|
|
27111
27193
|
var import_react147 = require("react");
|
|
27112
|
-
var
|
|
27194
|
+
var import_jsx_runtime128 = require("react/jsx-runtime");
|
|
27113
27195
|
function isAuthorObject(v) {
|
|
27114
27196
|
return typeof v === "object" && v !== null && !("type" in v) && // exclude React elements
|
|
27115
27197
|
"name" in v;
|
|
@@ -27141,7 +27223,7 @@ var TestimonialCard = (0, import_react147.forwardRef)(function TestimonialCard2(
|
|
|
27141
27223
|
};
|
|
27142
27224
|
const renderAvatar = () => {
|
|
27143
27225
|
if (!isAuthorObject(author) && legacyAvatar) {
|
|
27144
|
-
return /* @__PURE__ */ (0,
|
|
27226
|
+
return /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(
|
|
27145
27227
|
"span",
|
|
27146
27228
|
{
|
|
27147
27229
|
className: "ods-testimonial__avatar ods-testimonial__avatar--legacy",
|
|
@@ -27150,7 +27232,7 @@ var TestimonialCard = (0, import_react147.forwardRef)(function TestimonialCard2(
|
|
|
27150
27232
|
}
|
|
27151
27233
|
);
|
|
27152
27234
|
}
|
|
27153
|
-
return /* @__PURE__ */ (0,
|
|
27235
|
+
return /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(
|
|
27154
27236
|
Avatar,
|
|
27155
27237
|
{
|
|
27156
27238
|
size: size === "sm" ? "xs" : size === "lg" ? "md" : "sm",
|
|
@@ -27161,7 +27243,7 @@ var TestimonialCard = (0, import_react147.forwardRef)(function TestimonialCard2(
|
|
|
27161
27243
|
}
|
|
27162
27244
|
);
|
|
27163
27245
|
};
|
|
27164
|
-
return /* @__PURE__ */ (0,
|
|
27246
|
+
return /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)(
|
|
27165
27247
|
Card,
|
|
27166
27248
|
{
|
|
27167
27249
|
...rest,
|
|
@@ -27178,26 +27260,26 @@ var TestimonialCard = (0, import_react147.forwardRef)(function TestimonialCard2(
|
|
|
27178
27260
|
"aria-labelledby": authorId,
|
|
27179
27261
|
"aria-describedby": quoteId,
|
|
27180
27262
|
children: [
|
|
27181
|
-
/* @__PURE__ */ (0,
|
|
27182
|
-
/* @__PURE__ */ (0,
|
|
27183
|
-
logo && /* @__PURE__ */ (0,
|
|
27263
|
+
/* @__PURE__ */ (0, import_jsx_runtime128.jsxs)("div", { className: "ods-testimonial__head", children: [
|
|
27264
|
+
/* @__PURE__ */ (0, import_jsx_runtime128.jsx)("span", { className: "ods-testimonial__quote", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(import_icons41.QuotesIcon, { size: "md" }) }),
|
|
27265
|
+
logo && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("span", { className: "ods-testimonial__logo", "aria-hidden": "true", children: logo })
|
|
27184
27266
|
] }),
|
|
27185
|
-
/* @__PURE__ */ (0,
|
|
27186
|
-
typeof rating === "number" && /* @__PURE__ */ (0,
|
|
27267
|
+
/* @__PURE__ */ (0, import_jsx_runtime128.jsx)("blockquote", { id: quoteId, className: "ods-testimonial__text", children: quote }),
|
|
27268
|
+
typeof rating === "number" && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(
|
|
27187
27269
|
"div",
|
|
27188
27270
|
{
|
|
27189
27271
|
className: "ods-testimonial__rating",
|
|
27190
27272
|
role: "img",
|
|
27191
27273
|
"aria-label": `${rating} out of 5 stars`,
|
|
27192
27274
|
children: Array.from({ length: 5 }).map(
|
|
27193
|
-
(_, i) => i < Math.round(rating) ? /* @__PURE__ */ (0,
|
|
27275
|
+
(_, i) => i < Math.round(rating) ? /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(
|
|
27194
27276
|
import_icons41.StarFilledIcon,
|
|
27195
27277
|
{
|
|
27196
27278
|
size: "xs",
|
|
27197
27279
|
className: "ods-testimonial__star ods-testimonial__star--on"
|
|
27198
27280
|
},
|
|
27199
27281
|
i
|
|
27200
|
-
) : /* @__PURE__ */ (0,
|
|
27282
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(
|
|
27201
27283
|
import_icons41.StarIcon,
|
|
27202
27284
|
{
|
|
27203
27285
|
size: "xs",
|
|
@@ -27208,11 +27290,11 @@ var TestimonialCard = (0, import_react147.forwardRef)(function TestimonialCard2(
|
|
|
27208
27290
|
)
|
|
27209
27291
|
}
|
|
27210
27292
|
),
|
|
27211
|
-
/* @__PURE__ */ (0,
|
|
27293
|
+
/* @__PURE__ */ (0, import_jsx_runtime128.jsxs)("figcaption", { className: "ods-testimonial__author", id: authorId, children: [
|
|
27212
27294
|
renderAvatar(),
|
|
27213
|
-
/* @__PURE__ */ (0,
|
|
27214
|
-
/* @__PURE__ */ (0,
|
|
27215
|
-
resolved.role && /* @__PURE__ */ (0,
|
|
27295
|
+
/* @__PURE__ */ (0, import_jsx_runtime128.jsxs)("span", { className: "ods-testimonial__author-info", children: [
|
|
27296
|
+
/* @__PURE__ */ (0, import_jsx_runtime128.jsx)("span", { className: "ods-testimonial__author-name", children: resolved.name }),
|
|
27297
|
+
resolved.role && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("span", { className: "ods-testimonial__author-role", children: resolved.role })
|
|
27216
27298
|
] })
|
|
27217
27299
|
] })
|
|
27218
27300
|
]
|
|
@@ -27596,7 +27678,7 @@ function useTextareaSelection({
|
|
|
27596
27678
|
// src/hooks/useTextareaTools.tsx
|
|
27597
27679
|
var import_icons42 = require("@octaviaflow/icons");
|
|
27598
27680
|
var import_react150 = require("react");
|
|
27599
|
-
var
|
|
27681
|
+
var import_jsx_runtime129 = require("react/jsx-runtime");
|
|
27600
27682
|
function useTextareaTools({
|
|
27601
27683
|
textareaRef,
|
|
27602
27684
|
value,
|
|
@@ -27732,28 +27814,28 @@ var prependLineTool = (id, prefix, label, icon, title) => ({
|
|
|
27732
27814
|
onAction: (h) => h.prependLines(prefix)
|
|
27733
27815
|
});
|
|
27734
27816
|
var textareaTools = {
|
|
27735
|
-
bold: () => wrapTool("bold", "**", "**", "Bold", /* @__PURE__ */ (0,
|
|
27736
|
-
italic: () => wrapTool("italic", "*", "*", "Italic", /* @__PURE__ */ (0,
|
|
27817
|
+
bold: () => wrapTool("bold", "**", "**", "Bold", /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(import_icons42.TextBoldIcon, {}), "Bold (\u2318B)"),
|
|
27818
|
+
italic: () => wrapTool("italic", "*", "*", "Italic", /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(import_icons42.TextItalicIcon, {}), "Italic (\u2318I)"),
|
|
27737
27819
|
strikethrough: () => wrapTool(
|
|
27738
27820
|
"strike",
|
|
27739
27821
|
"~~",
|
|
27740
27822
|
"~~",
|
|
27741
27823
|
"Strikethrough",
|
|
27742
|
-
/* @__PURE__ */ (0,
|
|
27824
|
+
/* @__PURE__ */ (0, import_jsx_runtime129.jsx)(import_icons42.TextStrikethroughIcon, {}),
|
|
27743
27825
|
"Strikethrough"
|
|
27744
27826
|
),
|
|
27745
|
-
code: () => wrapTool("code", "`", "`", "Code", /* @__PURE__ */ (0,
|
|
27827
|
+
code: () => wrapTool("code", "`", "`", "Code", /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(import_icons42.CodeIcon, {}), "Inline code"),
|
|
27746
27828
|
codeBlock: () => ({
|
|
27747
27829
|
id: "code-block",
|
|
27748
27830
|
label: "Code block",
|
|
27749
|
-
icon: /* @__PURE__ */ (0,
|
|
27831
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(import_icons42.CodeIcon, {}),
|
|
27750
27832
|
title: "Code block",
|
|
27751
27833
|
onAction: (h) => h.wrap("```\n", "\n```")
|
|
27752
27834
|
}),
|
|
27753
27835
|
link: () => ({
|
|
27754
27836
|
id: "link",
|
|
27755
27837
|
label: "Link",
|
|
27756
|
-
icon: /* @__PURE__ */ (0,
|
|
27838
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(import_icons42.TextLinkIcon, {}),
|
|
27757
27839
|
title: "Insert link",
|
|
27758
27840
|
onAction: (h) => {
|
|
27759
27841
|
const sel = h.selection;
|
|
@@ -27766,41 +27848,41 @@ var textareaTools = {
|
|
|
27766
27848
|
`heading-${level}`,
|
|
27767
27849
|
`${"#".repeat(level)} `,
|
|
27768
27850
|
`H${level}`,
|
|
27769
|
-
/* @__PURE__ */ (0,
|
|
27851
|
+
/* @__PURE__ */ (0, import_jsx_runtime129.jsx)(import_icons42.HeadingIcon, {}),
|
|
27770
27852
|
`Heading ${level}`
|
|
27771
27853
|
),
|
|
27772
27854
|
bulletList: () => prependLineTool(
|
|
27773
27855
|
"ul",
|
|
27774
27856
|
"- ",
|
|
27775
27857
|
"Bullet list",
|
|
27776
|
-
/* @__PURE__ */ (0,
|
|
27858
|
+
/* @__PURE__ */ (0, import_jsx_runtime129.jsx)(import_icons42.ListBulletedIcon, {}),
|
|
27777
27859
|
"Bullet list"
|
|
27778
27860
|
),
|
|
27779
27861
|
numberedList: () => prependLineTool(
|
|
27780
27862
|
"ol",
|
|
27781
27863
|
"1. ",
|
|
27782
27864
|
"Numbered list",
|
|
27783
|
-
/* @__PURE__ */ (0,
|
|
27865
|
+
/* @__PURE__ */ (0, import_jsx_runtime129.jsx)(import_icons42.ListNumberedIcon, {}),
|
|
27784
27866
|
"Numbered list"
|
|
27785
27867
|
),
|
|
27786
27868
|
quote: () => prependLineTool(
|
|
27787
27869
|
"quote",
|
|
27788
27870
|
"> ",
|
|
27789
27871
|
"Quote",
|
|
27790
|
-
/* @__PURE__ */ (0,
|
|
27872
|
+
/* @__PURE__ */ (0, import_jsx_runtime129.jsx)(import_icons42.QuotesIcon, {}),
|
|
27791
27873
|
"Quote"
|
|
27792
27874
|
),
|
|
27793
27875
|
undo: () => ({
|
|
27794
27876
|
id: "undo",
|
|
27795
27877
|
label: "Undo",
|
|
27796
|
-
icon: /* @__PURE__ */ (0,
|
|
27878
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(import_icons42.UndoIcon, {}),
|
|
27797
27879
|
title: "Undo (\u2318Z)",
|
|
27798
27880
|
onAction: (h) => h.undo()
|
|
27799
27881
|
}),
|
|
27800
27882
|
redo: () => ({
|
|
27801
27883
|
id: "redo",
|
|
27802
27884
|
label: "Redo",
|
|
27803
|
-
icon: /* @__PURE__ */ (0,
|
|
27885
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(import_icons42.RedoIcon, {}),
|
|
27804
27886
|
title: "Redo (\u2318\u21E7Z)",
|
|
27805
27887
|
onAction: (h) => h.redo()
|
|
27806
27888
|
}),
|
|
@@ -27812,7 +27894,7 @@ var textareaTools = {
|
|
|
27812
27894
|
};
|
|
27813
27895
|
|
|
27814
27896
|
// src/components/Textarea/Textarea.tsx
|
|
27815
|
-
var
|
|
27897
|
+
var import_jsx_runtime130 = require("react/jsx-runtime");
|
|
27816
27898
|
var Textarea = (0, import_react151.forwardRef)(
|
|
27817
27899
|
function Textarea2({
|
|
27818
27900
|
label,
|
|
@@ -27961,7 +28043,7 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
27961
28043
|
minWidth: toCss2(minWidth),
|
|
27962
28044
|
resize: resolvedResize
|
|
27963
28045
|
};
|
|
27964
|
-
return /* @__PURE__ */ (0,
|
|
28046
|
+
return /* @__PURE__ */ (0, import_jsx_runtime130.jsxs)(
|
|
27965
28047
|
"div",
|
|
27966
28048
|
{
|
|
27967
28049
|
className: cn(
|
|
@@ -27975,7 +28057,7 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
27975
28057
|
),
|
|
27976
28058
|
style: consumerStyle,
|
|
27977
28059
|
children: [
|
|
27978
|
-
label && /* @__PURE__ */ (0,
|
|
28060
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
|
|
27979
28061
|
"label",
|
|
27980
28062
|
{
|
|
27981
28063
|
...labelProps,
|
|
@@ -27984,15 +28066,15 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
27984
28066
|
children: label
|
|
27985
28067
|
}
|
|
27986
28068
|
),
|
|
27987
|
-
toolbarEnabled && toolbarPosition === "top" && /* @__PURE__ */ (0,
|
|
28069
|
+
toolbarEnabled && toolbarPosition === "top" && /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
|
|
27988
28070
|
TextareaToolbar,
|
|
27989
28071
|
{
|
|
27990
28072
|
tools: toolbar.tools,
|
|
27991
28073
|
onRun: toolbar.runTool
|
|
27992
28074
|
}
|
|
27993
28075
|
),
|
|
27994
|
-
/* @__PURE__ */ (0,
|
|
27995
|
-
/* @__PURE__ */ (0,
|
|
28076
|
+
/* @__PURE__ */ (0, import_jsx_runtime130.jsxs)("div", { className: "ods-textarea__wrapper", children: [
|
|
28077
|
+
/* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
|
|
27996
28078
|
"textarea",
|
|
27997
28079
|
{
|
|
27998
28080
|
...props,
|
|
@@ -28017,7 +28099,7 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
28017
28099
|
}
|
|
28018
28100
|
),
|
|
28019
28101
|
cmdEnabled && cmdPalette.isOpen && cmdPalette.items.length > 0 && typeof document !== "undefined" && (0, import_react_dom17.createPortal)(
|
|
28020
|
-
/* @__PURE__ */ (0,
|
|
28102
|
+
/* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
|
|
28021
28103
|
"ul",
|
|
28022
28104
|
{
|
|
28023
28105
|
id: `${baseId}-cmd-list`,
|
|
@@ -28029,7 +28111,7 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
28029
28111
|
top: (cmdPalette.caretRect?.bottom ?? 0) + 6,
|
|
28030
28112
|
left: cmdPalette.caretRect?.left ?? 0
|
|
28031
28113
|
},
|
|
28032
|
-
children: cmdPalette.items.map((c, i) => /* @__PURE__ */ (0,
|
|
28114
|
+
children: cmdPalette.items.map((c, i) => /* @__PURE__ */ (0, import_jsx_runtime130.jsxs)(
|
|
28033
28115
|
"li",
|
|
28034
28116
|
{
|
|
28035
28117
|
id: `${baseId}-cmd-${c.id}`,
|
|
@@ -28046,10 +28128,10 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
28046
28128
|
onMouseEnter: () => {
|
|
28047
28129
|
},
|
|
28048
28130
|
children: [
|
|
28049
|
-
c.icon && /* @__PURE__ */ (0,
|
|
28050
|
-
/* @__PURE__ */ (0,
|
|
28051
|
-
/* @__PURE__ */ (0,
|
|
28052
|
-
c.description && /* @__PURE__ */ (0,
|
|
28131
|
+
c.icon && /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("span", { className: "ods-textarea__cmd-icon", children: c.icon }),
|
|
28132
|
+
/* @__PURE__ */ (0, import_jsx_runtime130.jsxs)("span", { className: "ods-textarea__cmd-text", children: [
|
|
28133
|
+
/* @__PURE__ */ (0, import_jsx_runtime130.jsx)("span", { className: "ods-textarea__cmd-label", children: c.label }),
|
|
28134
|
+
c.description && /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("span", { className: "ods-textarea__cmd-desc", children: c.description })
|
|
28053
28135
|
] })
|
|
28054
28136
|
]
|
|
28055
28137
|
},
|
|
@@ -28060,7 +28142,7 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
28060
28142
|
document.body
|
|
28061
28143
|
),
|
|
28062
28144
|
selectionToolbar && sel.active && sel.rect && typeof document !== "undefined" && (0, import_react_dom17.createPortal)(
|
|
28063
|
-
/* @__PURE__ */ (0,
|
|
28145
|
+
/* @__PURE__ */ (0, import_jsx_runtime130.jsxs)(
|
|
28064
28146
|
"div",
|
|
28065
28147
|
{
|
|
28066
28148
|
role: "toolbar",
|
|
@@ -28073,7 +28155,7 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
28073
28155
|
},
|
|
28074
28156
|
onMouseDown: (e) => e.preventDefault(),
|
|
28075
28157
|
children: [
|
|
28076
|
-
/* @__PURE__ */ (0,
|
|
28158
|
+
/* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
|
|
28077
28159
|
"button",
|
|
28078
28160
|
{
|
|
28079
28161
|
type: "button",
|
|
@@ -28081,10 +28163,10 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
28081
28163
|
onClick: () => sel.copy(),
|
|
28082
28164
|
"aria-label": "Copy selection",
|
|
28083
28165
|
title: "Copy",
|
|
28084
|
-
children: /* @__PURE__ */ (0,
|
|
28166
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(import_icons43.CopyIcon, { size: "xs" })
|
|
28085
28167
|
}
|
|
28086
28168
|
),
|
|
28087
|
-
/* @__PURE__ */ (0,
|
|
28169
|
+
/* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
|
|
28088
28170
|
"button",
|
|
28089
28171
|
{
|
|
28090
28172
|
type: "button",
|
|
@@ -28092,10 +28174,10 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
28092
28174
|
onClick: () => sel.cut(),
|
|
28093
28175
|
"aria-label": "Cut selection",
|
|
28094
28176
|
title: "Cut",
|
|
28095
|
-
children: /* @__PURE__ */ (0,
|
|
28177
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(import_icons43.CutIcon, { size: "xs" })
|
|
28096
28178
|
}
|
|
28097
28179
|
),
|
|
28098
|
-
selectionActions?.map((a) => /* @__PURE__ */ (0,
|
|
28180
|
+
selectionActions?.map((a) => /* @__PURE__ */ (0, import_jsx_runtime130.jsxs)(
|
|
28099
28181
|
"button",
|
|
28100
28182
|
{
|
|
28101
28183
|
type: "button",
|
|
@@ -28109,7 +28191,7 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
28109
28191
|
title: typeof a.label === "string" ? a.label : void 0,
|
|
28110
28192
|
children: [
|
|
28111
28193
|
a.icon,
|
|
28112
|
-
a.label && /* @__PURE__ */ (0,
|
|
28194
|
+
a.label && /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("span", { className: "ods-textarea__sel-btn-label", children: a.label })
|
|
28113
28195
|
]
|
|
28114
28196
|
},
|
|
28115
28197
|
a.id
|
|
@@ -28119,7 +28201,7 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
28119
28201
|
),
|
|
28120
28202
|
document.body
|
|
28121
28203
|
),
|
|
28122
|
-
maxLength != null && /* @__PURE__ */ (0,
|
|
28204
|
+
maxLength != null && /* @__PURE__ */ (0, import_jsx_runtime130.jsxs)(
|
|
28123
28205
|
"span",
|
|
28124
28206
|
{
|
|
28125
28207
|
className: "ods-textarea__count",
|
|
@@ -28132,14 +28214,14 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
28132
28214
|
}
|
|
28133
28215
|
)
|
|
28134
28216
|
] }),
|
|
28135
|
-
toolbarEnabled && toolbarPosition === "bottom" && /* @__PURE__ */ (0,
|
|
28217
|
+
toolbarEnabled && toolbarPosition === "bottom" && /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
|
|
28136
28218
|
TextareaToolbar,
|
|
28137
28219
|
{
|
|
28138
28220
|
tools: toolbar.tools,
|
|
28139
28221
|
onRun: toolbar.runTool
|
|
28140
28222
|
}
|
|
28141
28223
|
),
|
|
28142
|
-
error && errorMessage ? /* @__PURE__ */ (0,
|
|
28224
|
+
error && errorMessage ? /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
|
|
28143
28225
|
"div",
|
|
28144
28226
|
{
|
|
28145
28227
|
id: hintId,
|
|
@@ -28147,7 +28229,7 @@ var Textarea = (0, import_react151.forwardRef)(
|
|
|
28147
28229
|
role: "alert",
|
|
28148
28230
|
children: errorMessage
|
|
28149
28231
|
}
|
|
28150
|
-
) : helperText ? /* @__PURE__ */ (0,
|
|
28232
|
+
) : helperText ? /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("div", { id: hintId, className: "ods-textarea__hint", children: helperText }) : null
|
|
28151
28233
|
]
|
|
28152
28234
|
}
|
|
28153
28235
|
);
|
|
@@ -28158,7 +28240,7 @@ function TextareaToolbar({
|
|
|
28158
28240
|
tools,
|
|
28159
28241
|
onRun
|
|
28160
28242
|
}) {
|
|
28161
|
-
return /* @__PURE__ */ (0,
|
|
28243
|
+
return /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
|
|
28162
28244
|
"div",
|
|
28163
28245
|
{
|
|
28164
28246
|
role: "toolbar",
|
|
@@ -28171,7 +28253,7 @@ function TextareaToolbar({
|
|
|
28171
28253
|
},
|
|
28172
28254
|
children: tools.map((t) => {
|
|
28173
28255
|
if (t.kind === "divider") {
|
|
28174
|
-
return /* @__PURE__ */ (0,
|
|
28256
|
+
return /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
|
|
28175
28257
|
"span",
|
|
28176
28258
|
{
|
|
28177
28259
|
className: "ods-textarea__toolbar-divider",
|
|
@@ -28180,7 +28262,7 @@ function TextareaToolbar({
|
|
|
28180
28262
|
t.id
|
|
28181
28263
|
);
|
|
28182
28264
|
}
|
|
28183
|
-
return /* @__PURE__ */ (0,
|
|
28265
|
+
return /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
|
|
28184
28266
|
"button",
|
|
28185
28267
|
{
|
|
28186
28268
|
type: "button",
|
|
@@ -28188,7 +28270,7 @@ function TextareaToolbar({
|
|
|
28188
28270
|
title: t.title ?? (typeof t.label === "string" ? t.label : void 0),
|
|
28189
28271
|
"aria-label": typeof t.label === "string" ? t.label : t.id,
|
|
28190
28272
|
onClick: () => onRun(t.id),
|
|
28191
|
-
children: t.icon ? /* @__PURE__ */ (0,
|
|
28273
|
+
children: t.icon ? /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("span", { className: "ods-textarea__toolbar-icon", children: t.icon }) : /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("span", { className: "ods-textarea__toolbar-text", children: t.label })
|
|
28192
28274
|
},
|
|
28193
28275
|
t.id
|
|
28194
28276
|
);
|
|
@@ -28200,7 +28282,7 @@ function TextareaToolbar({
|
|
|
28200
28282
|
// src/components/Timeline/Timeline.tsx
|
|
28201
28283
|
var import_framer_motion35 = require("framer-motion");
|
|
28202
28284
|
var import_react152 = require("react");
|
|
28203
|
-
var
|
|
28285
|
+
var import_jsx_runtime131 = require("react/jsx-runtime");
|
|
28204
28286
|
var Timeline = (0, import_react152.forwardRef)(
|
|
28205
28287
|
function Timeline2({
|
|
28206
28288
|
items,
|
|
@@ -28210,16 +28292,16 @@ var Timeline = (0, import_react152.forwardRef)(
|
|
|
28210
28292
|
className,
|
|
28211
28293
|
...rest
|
|
28212
28294
|
}, ref) {
|
|
28213
|
-
return /* @__PURE__ */ (0,
|
|
28295
|
+
return /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
|
|
28214
28296
|
"ol",
|
|
28215
28297
|
{
|
|
28216
28298
|
...rest,
|
|
28217
28299
|
ref,
|
|
28218
28300
|
className: cn("ods-timeline", `ods-timeline--${size}`, className),
|
|
28219
|
-
children: /* @__PURE__ */ (0,
|
|
28301
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(import_framer_motion35.AnimatePresence, { initial: false, children: items.map((item, idx) => {
|
|
28220
28302
|
const last = idx === items.length - 1;
|
|
28221
28303
|
const status = item.status ?? "default";
|
|
28222
|
-
return /* @__PURE__ */ (0,
|
|
28304
|
+
return /* @__PURE__ */ (0, import_jsx_runtime131.jsxs)(
|
|
28223
28305
|
import_framer_motion35.motion.li,
|
|
28224
28306
|
{
|
|
28225
28307
|
layout: animated,
|
|
@@ -28236,8 +28318,8 @@ var Timeline = (0, import_react152.forwardRef)(
|
|
|
28236
28318
|
delay: animated ? idx * staggerDelay / 1e3 : 0
|
|
28237
28319
|
},
|
|
28238
28320
|
children: [
|
|
28239
|
-
/* @__PURE__ */ (0,
|
|
28240
|
-
/* @__PURE__ */ (0,
|
|
28321
|
+
/* @__PURE__ */ (0, import_jsx_runtime131.jsxs)("div", { className: "ods-timeline__rail", children: [
|
|
28322
|
+
/* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
|
|
28241
28323
|
"span",
|
|
28242
28324
|
{
|
|
28243
28325
|
className: cn(
|
|
@@ -28248,12 +28330,12 @@ var Timeline = (0, import_react152.forwardRef)(
|
|
|
28248
28330
|
children: item.icon
|
|
28249
28331
|
}
|
|
28250
28332
|
),
|
|
28251
|
-
!last && /* @__PURE__ */ (0,
|
|
28333
|
+
!last && /* @__PURE__ */ (0, import_jsx_runtime131.jsx)("span", { className: "ods-timeline__line", "aria-hidden": "true" })
|
|
28252
28334
|
] }),
|
|
28253
|
-
/* @__PURE__ */ (0,
|
|
28254
|
-
/* @__PURE__ */ (0,
|
|
28255
|
-
item.description && /* @__PURE__ */ (0,
|
|
28256
|
-
item.meta && /* @__PURE__ */ (0,
|
|
28335
|
+
/* @__PURE__ */ (0, import_jsx_runtime131.jsxs)("div", { className: "ods-timeline__body", children: [
|
|
28336
|
+
/* @__PURE__ */ (0, import_jsx_runtime131.jsx)("div", { className: "ods-timeline__title", children: item.title }),
|
|
28337
|
+
item.description && /* @__PURE__ */ (0, import_jsx_runtime131.jsx)("div", { className: "ods-timeline__desc", children: item.description }),
|
|
28338
|
+
item.meta && /* @__PURE__ */ (0, import_jsx_runtime131.jsx)("div", { className: "ods-timeline__meta", children: item.meta })
|
|
28257
28339
|
] })
|
|
28258
28340
|
]
|
|
28259
28341
|
},
|
|
@@ -28270,7 +28352,7 @@ Timeline.displayName = "Timeline";
|
|
|
28270
28352
|
var import_react153 = require("react");
|
|
28271
28353
|
var import_react_dom18 = require("react-dom");
|
|
28272
28354
|
var import_icons44 = require("@octaviaflow/icons");
|
|
28273
|
-
var
|
|
28355
|
+
var import_jsx_runtime132 = require("react/jsx-runtime");
|
|
28274
28356
|
var pad = (n) => n.toString().padStart(2, "0");
|
|
28275
28357
|
function format(v, use24h, showSeconds) {
|
|
28276
28358
|
const base = `${pad(v.hours)}:${pad(v.minutes)}${showSeconds ? `:${pad(v.seconds ?? 0)}` : ""}`;
|
|
@@ -28502,7 +28584,7 @@ var TimePicker = (0, import_react153.forwardRef)(
|
|
|
28502
28584
|
if (draft && draft.seg === seg) return draft.digits.padStart(2, "0");
|
|
28503
28585
|
return pad(val);
|
|
28504
28586
|
};
|
|
28505
|
-
const segButton = (seg, val) => /* @__PURE__ */ (0,
|
|
28587
|
+
const segButton = (seg, val) => /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(
|
|
28506
28588
|
"button",
|
|
28507
28589
|
{
|
|
28508
28590
|
ref: refOf(seg),
|
|
@@ -28522,7 +28604,7 @@ var TimePicker = (0, import_react153.forwardRef)(
|
|
|
28522
28604
|
children: segDisplay(seg, val)
|
|
28523
28605
|
}
|
|
28524
28606
|
);
|
|
28525
|
-
return /* @__PURE__ */ (0,
|
|
28607
|
+
return /* @__PURE__ */ (0, import_jsx_runtime132.jsxs)(
|
|
28526
28608
|
"div",
|
|
28527
28609
|
{
|
|
28528
28610
|
...rest,
|
|
@@ -28535,7 +28617,7 @@ var TimePicker = (0, import_react153.forwardRef)(
|
|
|
28535
28617
|
className
|
|
28536
28618
|
),
|
|
28537
28619
|
children: [
|
|
28538
|
-
label && /* @__PURE__ */ (0,
|
|
28620
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(
|
|
28539
28621
|
"label",
|
|
28540
28622
|
{
|
|
28541
28623
|
id: labelId,
|
|
@@ -28544,7 +28626,7 @@ var TimePicker = (0, import_react153.forwardRef)(
|
|
|
28544
28626
|
children: label
|
|
28545
28627
|
}
|
|
28546
28628
|
),
|
|
28547
|
-
/* @__PURE__ */ (0,
|
|
28629
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsxs)(
|
|
28548
28630
|
"button",
|
|
28549
28631
|
{
|
|
28550
28632
|
type: "button",
|
|
@@ -28560,9 +28642,9 @@ var TimePicker = (0, import_react153.forwardRef)(
|
|
|
28560
28642
|
"aria-describedby": describedBy,
|
|
28561
28643
|
"aria-invalid": error ? true : void 0,
|
|
28562
28644
|
children: [
|
|
28563
|
-
/* @__PURE__ */ (0,
|
|
28564
|
-
/* @__PURE__ */ (0,
|
|
28565
|
-
/* @__PURE__ */ (0,
|
|
28645
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)("span", { className: "ods-timepicker__trigger-icon", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(import_icons44.TimeIcon, { size: "xs" }) }),
|
|
28646
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)("span", { className: "ods-timepicker__value", children: format(value, use24h, showSeconds) }),
|
|
28647
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)(
|
|
28566
28648
|
"span",
|
|
28567
28649
|
{
|
|
28568
28650
|
className: cn(
|
|
@@ -28570,14 +28652,14 @@ var TimePicker = (0, import_react153.forwardRef)(
|
|
|
28570
28652
|
open && "ods-timepicker__chev--open"
|
|
28571
28653
|
),
|
|
28572
28654
|
"aria-hidden": "true",
|
|
28573
|
-
children: /* @__PURE__ */ (0,
|
|
28655
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(import_icons44.ChevronDownIcon, { size: "xs" })
|
|
28574
28656
|
}
|
|
28575
28657
|
)
|
|
28576
28658
|
]
|
|
28577
28659
|
}
|
|
28578
28660
|
),
|
|
28579
28661
|
open && typeof document !== "undefined" && (0, import_react_dom18.createPortal)(
|
|
28580
|
-
/* @__PURE__ */ (0,
|
|
28662
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsxs)(
|
|
28581
28663
|
"div",
|
|
28582
28664
|
{
|
|
28583
28665
|
ref: popoverRef,
|
|
@@ -28586,18 +28668,18 @@ var TimePicker = (0, import_react153.forwardRef)(
|
|
|
28586
28668
|
"aria-label": "Select time",
|
|
28587
28669
|
style: anchoredPopoverStyle(popoverPos),
|
|
28588
28670
|
children: [
|
|
28589
|
-
/* @__PURE__ */ (0,
|
|
28590
|
-
/* @__PURE__ */ (0,
|
|
28671
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsxs)("div", { className: "ods-timepicker__head", children: [
|
|
28672
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsxs)("div", { className: "ods-timepicker__display", children: [
|
|
28591
28673
|
segButton("hours", value.hours),
|
|
28592
|
-
/* @__PURE__ */ (0,
|
|
28674
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)("span", { className: "ods-timepicker__display-sep", children: ":" }),
|
|
28593
28675
|
segButton("minutes", value.minutes),
|
|
28594
|
-
showSeconds && /* @__PURE__ */ (0,
|
|
28595
|
-
/* @__PURE__ */ (0,
|
|
28676
|
+
showSeconds && /* @__PURE__ */ (0, import_jsx_runtime132.jsxs)(import_jsx_runtime132.Fragment, { children: [
|
|
28677
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)("span", { className: "ods-timepicker__display-sep", children: ":" }),
|
|
28596
28678
|
segButton("seconds", value.seconds ?? 0)
|
|
28597
28679
|
] })
|
|
28598
28680
|
] }),
|
|
28599
|
-
!use24h && /* @__PURE__ */ (0,
|
|
28600
|
-
/* @__PURE__ */ (0,
|
|
28681
|
+
!use24h && /* @__PURE__ */ (0, import_jsx_runtime132.jsxs)("div", { className: "ods-timepicker__period", children: [
|
|
28682
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)(
|
|
28601
28683
|
"button",
|
|
28602
28684
|
{
|
|
28603
28685
|
type: "button",
|
|
@@ -28609,7 +28691,7 @@ var TimePicker = (0, import_react153.forwardRef)(
|
|
|
28609
28691
|
children: "AM"
|
|
28610
28692
|
}
|
|
28611
28693
|
),
|
|
28612
|
-
/* @__PURE__ */ (0,
|
|
28694
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)(
|
|
28613
28695
|
"button",
|
|
28614
28696
|
{
|
|
28615
28697
|
type: "button",
|
|
@@ -28623,41 +28705,41 @@ var TimePicker = (0, import_react153.forwardRef)(
|
|
|
28623
28705
|
)
|
|
28624
28706
|
] })
|
|
28625
28707
|
] }),
|
|
28626
|
-
/* @__PURE__ */ (0,
|
|
28627
|
-
/* @__PURE__ */ (0,
|
|
28628
|
-
/* @__PURE__ */ (0,
|
|
28629
|
-
/* @__PURE__ */ (0,
|
|
28708
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)("div", { className: "ods-timepicker__body", children: segOrder().map((seg, i, arr) => /* @__PURE__ */ (0, import_jsx_runtime132.jsxs)(import_react153.Fragment, { children: [
|
|
28709
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsxs)("div", { className: "ods-timepicker__col", children: [
|
|
28710
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)("span", { className: "ods-timepicker__col-lbl", children: seg === "hours" ? "HOUR" : seg === "minutes" ? "MIN" : "SEC" }),
|
|
28711
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)(
|
|
28630
28712
|
"button",
|
|
28631
28713
|
{
|
|
28632
28714
|
type: "button",
|
|
28633
28715
|
className: "ods-timepicker__step",
|
|
28634
28716
|
onClick: () => stepBy(seg, 1),
|
|
28635
28717
|
"aria-label": `${seg} up`,
|
|
28636
|
-
children: /* @__PURE__ */ (0,
|
|
28718
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(import_icons44.CaretUpIcon, { size: "xs" })
|
|
28637
28719
|
}
|
|
28638
28720
|
),
|
|
28639
|
-
/* @__PURE__ */ (0,
|
|
28721
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)("span", { className: "ods-timepicker__col-val", children: pad(
|
|
28640
28722
|
seg === "hours" ? value.hours : seg === "minutes" ? value.minutes : value.seconds ?? 0
|
|
28641
28723
|
) }),
|
|
28642
|
-
/* @__PURE__ */ (0,
|
|
28724
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)(
|
|
28643
28725
|
"button",
|
|
28644
28726
|
{
|
|
28645
28727
|
type: "button",
|
|
28646
28728
|
className: "ods-timepicker__step",
|
|
28647
28729
|
onClick: () => stepBy(seg, -1),
|
|
28648
28730
|
"aria-label": `${seg} down`,
|
|
28649
|
-
children: /* @__PURE__ */ (0,
|
|
28731
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(import_icons44.CaretDownIcon, { size: "xs" })
|
|
28650
28732
|
}
|
|
28651
28733
|
)
|
|
28652
28734
|
] }),
|
|
28653
|
-
i < arr.length - 1 && /* @__PURE__ */ (0,
|
|
28735
|
+
i < arr.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime132.jsx)("span", { className: "ods-timepicker__sep", children: ":" })
|
|
28654
28736
|
] }, seg)) })
|
|
28655
28737
|
]
|
|
28656
28738
|
}
|
|
28657
28739
|
),
|
|
28658
28740
|
document.body
|
|
28659
28741
|
),
|
|
28660
|
-
error ? /* @__PURE__ */ (0,
|
|
28742
|
+
error ? /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(
|
|
28661
28743
|
"div",
|
|
28662
28744
|
{
|
|
28663
28745
|
id: hintId,
|
|
@@ -28665,7 +28747,7 @@ var TimePicker = (0, import_react153.forwardRef)(
|
|
|
28665
28747
|
role: "alert",
|
|
28666
28748
|
children: error
|
|
28667
28749
|
}
|
|
28668
|
-
) : helperText ? /* @__PURE__ */ (0,
|
|
28750
|
+
) : helperText ? /* @__PURE__ */ (0, import_jsx_runtime132.jsx)("div", { id: hintId, className: "ods-timepicker__hint", children: helperText }) : null
|
|
28669
28751
|
]
|
|
28670
28752
|
}
|
|
28671
28753
|
);
|
|
@@ -28676,7 +28758,7 @@ TimePicker.displayName = "TimePicker";
|
|
|
28676
28758
|
// src/components/TimezonePicker/TimezonePicker.tsx
|
|
28677
28759
|
var import_react154 = require("react");
|
|
28678
28760
|
var import_icons45 = require("@octaviaflow/icons");
|
|
28679
|
-
var
|
|
28761
|
+
var import_jsx_runtime133 = require("react/jsx-runtime");
|
|
28680
28762
|
var DEFAULT_TZS = [
|
|
28681
28763
|
{ iana: "America/Los_Angeles", label: "Pacific Time", offset: "UTC\u22128" },
|
|
28682
28764
|
{ iana: "America/Denver", label: "Mountain Time", offset: "UTC\u22127" },
|
|
@@ -28811,7 +28893,7 @@ var TimezonePicker = (0, import_react154.forwardRef)(
|
|
|
28811
28893
|
const setTriggerRef = (node) => {
|
|
28812
28894
|
triggerRef.current = node;
|
|
28813
28895
|
};
|
|
28814
|
-
return /* @__PURE__ */ (0,
|
|
28896
|
+
return /* @__PURE__ */ (0, import_jsx_runtime133.jsxs)(
|
|
28815
28897
|
"div",
|
|
28816
28898
|
{
|
|
28817
28899
|
...rest,
|
|
@@ -28824,7 +28906,7 @@ var TimezonePicker = (0, import_react154.forwardRef)(
|
|
|
28824
28906
|
className
|
|
28825
28907
|
),
|
|
28826
28908
|
children: [
|
|
28827
|
-
label && /* @__PURE__ */ (0,
|
|
28909
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime133.jsx)(
|
|
28828
28910
|
"label",
|
|
28829
28911
|
{
|
|
28830
28912
|
id: labelId,
|
|
@@ -28833,7 +28915,7 @@ var TimezonePicker = (0, import_react154.forwardRef)(
|
|
|
28833
28915
|
children: label
|
|
28834
28916
|
}
|
|
28835
28917
|
),
|
|
28836
|
-
/* @__PURE__ */ (0,
|
|
28918
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsxs)(
|
|
28837
28919
|
"button",
|
|
28838
28920
|
{
|
|
28839
28921
|
ref: setTriggerRef,
|
|
@@ -28850,17 +28932,17 @@ var TimezonePicker = (0, import_react154.forwardRef)(
|
|
|
28850
28932
|
"aria-describedby": describedBy,
|
|
28851
28933
|
"aria-invalid": error ? true : void 0,
|
|
28852
28934
|
children: [
|
|
28853
|
-
/* @__PURE__ */ (0,
|
|
28854
|
-
/* @__PURE__ */ (0,
|
|
28855
|
-
/* @__PURE__ */ (0,
|
|
28856
|
-
/* @__PURE__ */ (0,
|
|
28935
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsx)("span", { className: "ods-tzpicker__trigger-icon", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime133.jsx)(import_icons45.GlobeIcon, { size: "xs" }) }),
|
|
28936
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsx)("span", { className: "ods-tzpicker__info", children: selected ? /* @__PURE__ */ (0, import_jsx_runtime133.jsxs)(import_jsx_runtime133.Fragment, { children: [
|
|
28937
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsx)("span", { className: "ods-tzpicker__name", children: selected.label }),
|
|
28938
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsxs)("span", { className: "ods-tzpicker__meta", children: [
|
|
28857
28939
|
selected.iana.split("/").pop()?.replace(/_/g, " "),
|
|
28858
28940
|
" \xB7",
|
|
28859
28941
|
" ",
|
|
28860
28942
|
selected.offset
|
|
28861
28943
|
] })
|
|
28862
|
-
] }) : /* @__PURE__ */ (0,
|
|
28863
|
-
/* @__PURE__ */ (0,
|
|
28944
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime133.jsx)("span", { className: "ods-tzpicker__name ods-tzpicker__name--placeholder", children: placeholder }) }),
|
|
28945
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsx)(
|
|
28864
28946
|
"span",
|
|
28865
28947
|
{
|
|
28866
28948
|
className: cn(
|
|
@@ -28868,13 +28950,13 @@ var TimezonePicker = (0, import_react154.forwardRef)(
|
|
|
28868
28950
|
open && "ods-tzpicker__chev--open"
|
|
28869
28951
|
),
|
|
28870
28952
|
"aria-hidden": "true",
|
|
28871
|
-
children: /* @__PURE__ */ (0,
|
|
28953
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime133.jsx)(import_icons45.ChevronDownIcon, { size: "xs" })
|
|
28872
28954
|
}
|
|
28873
28955
|
)
|
|
28874
28956
|
]
|
|
28875
28957
|
}
|
|
28876
28958
|
),
|
|
28877
|
-
open && /* @__PURE__ */ (0,
|
|
28959
|
+
open && /* @__PURE__ */ (0, import_jsx_runtime133.jsxs)(
|
|
28878
28960
|
"div",
|
|
28879
28961
|
{
|
|
28880
28962
|
className: "ods-tzpicker__popover",
|
|
@@ -28882,9 +28964,9 @@ var TimezonePicker = (0, import_react154.forwardRef)(
|
|
|
28882
28964
|
"aria-label": "Select timezone",
|
|
28883
28965
|
onKeyDown: handlePopoverKey,
|
|
28884
28966
|
children: [
|
|
28885
|
-
/* @__PURE__ */ (0,
|
|
28886
|
-
/* @__PURE__ */ (0,
|
|
28887
|
-
/* @__PURE__ */ (0,
|
|
28967
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsxs)("div", { className: "ods-tzpicker__search", children: [
|
|
28968
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsx)("span", { className: "ods-tzpicker__search-icon", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime133.jsx)(import_icons45.SearchIcon, { size: "xs" }) }),
|
|
28969
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsx)(
|
|
28888
28970
|
"input",
|
|
28889
28971
|
{
|
|
28890
28972
|
ref: inputRef,
|
|
@@ -28900,7 +28982,7 @@ var TimezonePicker = (0, import_react154.forwardRef)(
|
|
|
28900
28982
|
}
|
|
28901
28983
|
)
|
|
28902
28984
|
] }),
|
|
28903
|
-
/* @__PURE__ */ (0,
|
|
28985
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsxs)(
|
|
28904
28986
|
"ul",
|
|
28905
28987
|
{
|
|
28906
28988
|
ref: listRef,
|
|
@@ -28909,11 +28991,11 @@ var TimezonePicker = (0, import_react154.forwardRef)(
|
|
|
28909
28991
|
role: "listbox",
|
|
28910
28992
|
"aria-labelledby": labelId,
|
|
28911
28993
|
children: [
|
|
28912
|
-
filtered.length === 0 && /* @__PURE__ */ (0,
|
|
28994
|
+
filtered.length === 0 && /* @__PURE__ */ (0, import_jsx_runtime133.jsx)("li", { className: "ods-tzpicker__empty", role: "presentation", children: "No timezones found" }),
|
|
28913
28995
|
filtered.map((opt, i) => {
|
|
28914
28996
|
const isSelected = opt.iana === value;
|
|
28915
28997
|
const isActive2 = i === activeIndex;
|
|
28916
|
-
return /* @__PURE__ */ (0,
|
|
28998
|
+
return /* @__PURE__ */ (0, import_jsx_runtime133.jsx)("li", { role: "presentation", children: /* @__PURE__ */ (0, import_jsx_runtime133.jsxs)(
|
|
28917
28999
|
"button",
|
|
28918
29000
|
{
|
|
28919
29001
|
type: "button",
|
|
@@ -28930,17 +29012,17 @@ var TimezonePicker = (0, import_react154.forwardRef)(
|
|
|
28930
29012
|
onClick: () => select(opt.iana),
|
|
28931
29013
|
onMouseEnter: () => setActiveIndex(i),
|
|
28932
29014
|
children: [
|
|
28933
|
-
/* @__PURE__ */ (0,
|
|
28934
|
-
/* @__PURE__ */ (0,
|
|
28935
|
-
/* @__PURE__ */ (0,
|
|
29015
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsxs)("span", { className: "ods-tzpicker__opt-text", children: [
|
|
29016
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsx)("span", { className: "ods-tzpicker__opt-name", children: opt.label }),
|
|
29017
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsx)("span", { className: "ods-tzpicker__opt-iana", children: opt.iana })
|
|
28936
29018
|
] }),
|
|
28937
|
-
/* @__PURE__ */ (0,
|
|
28938
|
-
isSelected && /* @__PURE__ */ (0,
|
|
29019
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsx)("span", { className: "ods-tzpicker__opt-off", children: opt.offset }),
|
|
29020
|
+
isSelected && /* @__PURE__ */ (0, import_jsx_runtime133.jsx)(
|
|
28939
29021
|
"span",
|
|
28940
29022
|
{
|
|
28941
29023
|
className: "ods-tzpicker__opt-check",
|
|
28942
29024
|
"aria-hidden": "true",
|
|
28943
|
-
children: /* @__PURE__ */ (0,
|
|
29025
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime133.jsx)(import_icons45.CheckmarkIcon, { size: "xs" })
|
|
28944
29026
|
}
|
|
28945
29027
|
)
|
|
28946
29028
|
]
|
|
@@ -28953,7 +29035,7 @@ var TimezonePicker = (0, import_react154.forwardRef)(
|
|
|
28953
29035
|
]
|
|
28954
29036
|
}
|
|
28955
29037
|
),
|
|
28956
|
-
error ? /* @__PURE__ */ (0,
|
|
29038
|
+
error ? /* @__PURE__ */ (0, import_jsx_runtime133.jsx)(
|
|
28957
29039
|
"div",
|
|
28958
29040
|
{
|
|
28959
29041
|
id: hintId,
|
|
@@ -28961,7 +29043,7 @@ var TimezonePicker = (0, import_react154.forwardRef)(
|
|
|
28961
29043
|
role: "alert",
|
|
28962
29044
|
children: error
|
|
28963
29045
|
}
|
|
28964
|
-
) : helperText ? /* @__PURE__ */ (0,
|
|
29046
|
+
) : helperText ? /* @__PURE__ */ (0, import_jsx_runtime133.jsx)("div", { id: hintId, className: "ods-tzpicker__hint", children: helperText }) : null
|
|
28965
29047
|
]
|
|
28966
29048
|
}
|
|
28967
29049
|
);
|
|
@@ -28973,10 +29055,10 @@ TimezonePicker.displayName = "TimezonePicker";
|
|
|
28973
29055
|
var import_framer_motion36 = require("framer-motion");
|
|
28974
29056
|
var import_react155 = require("react");
|
|
28975
29057
|
var import_react_dom19 = require("react-dom");
|
|
28976
|
-
var
|
|
29058
|
+
var import_jsx_runtime134 = require("react/jsx-runtime");
|
|
28977
29059
|
var defaultIcons = {
|
|
28978
|
-
success: /* @__PURE__ */ (0,
|
|
28979
|
-
/* @__PURE__ */ (0,
|
|
29060
|
+
success: /* @__PURE__ */ (0, import_jsx_runtime134.jsxs)("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: [
|
|
29061
|
+
/* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
28980
29062
|
"circle",
|
|
28981
29063
|
{
|
|
28982
29064
|
cx: "8",
|
|
@@ -28986,7 +29068,7 @@ var defaultIcons = {
|
|
|
28986
29068
|
stroke: "var(--ods-status-success-bd)"
|
|
28987
29069
|
}
|
|
28988
29070
|
),
|
|
28989
|
-
/* @__PURE__ */ (0,
|
|
29071
|
+
/* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
28990
29072
|
"path",
|
|
28991
29073
|
{
|
|
28992
29074
|
d: "m5 8 2 2 4-4.5",
|
|
@@ -28997,8 +29079,8 @@ var defaultIcons = {
|
|
|
28997
29079
|
}
|
|
28998
29080
|
)
|
|
28999
29081
|
] }),
|
|
29000
|
-
error: /* @__PURE__ */ (0,
|
|
29001
|
-
/* @__PURE__ */ (0,
|
|
29082
|
+
error: /* @__PURE__ */ (0, import_jsx_runtime134.jsxs)("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: [
|
|
29083
|
+
/* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
29002
29084
|
"circle",
|
|
29003
29085
|
{
|
|
29004
29086
|
cx: "8",
|
|
@@ -29008,7 +29090,7 @@ var defaultIcons = {
|
|
|
29008
29090
|
stroke: "var(--ods-status-failed-bd)"
|
|
29009
29091
|
}
|
|
29010
29092
|
),
|
|
29011
|
-
/* @__PURE__ */ (0,
|
|
29093
|
+
/* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
29012
29094
|
"path",
|
|
29013
29095
|
{
|
|
29014
29096
|
d: "M5.5 5.5l5 5M10.5 5.5l-5 5",
|
|
@@ -29018,8 +29100,8 @@ var defaultIcons = {
|
|
|
29018
29100
|
}
|
|
29019
29101
|
)
|
|
29020
29102
|
] }),
|
|
29021
|
-
warning: /* @__PURE__ */ (0,
|
|
29022
|
-
/* @__PURE__ */ (0,
|
|
29103
|
+
warning: /* @__PURE__ */ (0, import_jsx_runtime134.jsxs)("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: [
|
|
29104
|
+
/* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
29023
29105
|
"circle",
|
|
29024
29106
|
{
|
|
29025
29107
|
cx: "8",
|
|
@@ -29029,7 +29111,7 @@ var defaultIcons = {
|
|
|
29029
29111
|
stroke: "var(--ods-status-pending-bd)"
|
|
29030
29112
|
}
|
|
29031
29113
|
),
|
|
29032
|
-
/* @__PURE__ */ (0,
|
|
29114
|
+
/* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
29033
29115
|
"path",
|
|
29034
29116
|
{
|
|
29035
29117
|
d: "M8 4.5v4.2M8 11v.5",
|
|
@@ -29039,8 +29121,8 @@ var defaultIcons = {
|
|
|
29039
29121
|
}
|
|
29040
29122
|
)
|
|
29041
29123
|
] }),
|
|
29042
|
-
info: /* @__PURE__ */ (0,
|
|
29043
|
-
/* @__PURE__ */ (0,
|
|
29124
|
+
info: /* @__PURE__ */ (0, import_jsx_runtime134.jsxs)("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: [
|
|
29125
|
+
/* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
29044
29126
|
"circle",
|
|
29045
29127
|
{
|
|
29046
29128
|
cx: "8",
|
|
@@ -29050,7 +29132,7 @@ var defaultIcons = {
|
|
|
29050
29132
|
stroke: "var(--ods-status-running-bd)"
|
|
29051
29133
|
}
|
|
29052
29134
|
),
|
|
29053
|
-
/* @__PURE__ */ (0,
|
|
29135
|
+
/* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
29054
29136
|
"path",
|
|
29055
29137
|
{
|
|
29056
29138
|
d: "M8 7.5v4M8 4.5v.5",
|
|
@@ -29064,19 +29146,19 @@ var defaultIcons = {
|
|
|
29064
29146
|
var ToastContext = (0, import_react155.createContext)(null);
|
|
29065
29147
|
function ToastBody({ item, onDismiss }) {
|
|
29066
29148
|
const dismiss = () => onDismiss(item.id);
|
|
29067
|
-
if (item.render) return /* @__PURE__ */ (0,
|
|
29149
|
+
if (item.render) return /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(import_jsx_runtime134.Fragment, { children: item.render({ id: item.id, dismiss }) });
|
|
29068
29150
|
const title = item.title ?? item.message;
|
|
29069
|
-
return /* @__PURE__ */ (0,
|
|
29070
|
-
/* @__PURE__ */ (0,
|
|
29071
|
-
/* @__PURE__ */ (0,
|
|
29072
|
-
title && /* @__PURE__ */ (0,
|
|
29073
|
-
item.description && /* @__PURE__ */ (0,
|
|
29151
|
+
return /* @__PURE__ */ (0, import_jsx_runtime134.jsxs)(import_jsx_runtime134.Fragment, { children: [
|
|
29152
|
+
/* @__PURE__ */ (0, import_jsx_runtime134.jsx)("span", { className: "ods-toast__icon", "aria-hidden": "true", children: item.icon ?? defaultIcons[item.variant] }),
|
|
29153
|
+
/* @__PURE__ */ (0, import_jsx_runtime134.jsxs)("div", { className: "ods-toast__body", children: [
|
|
29154
|
+
title && /* @__PURE__ */ (0, import_jsx_runtime134.jsx)("div", { className: "ods-toast__title", children: title }),
|
|
29155
|
+
item.description && /* @__PURE__ */ (0, import_jsx_runtime134.jsx)("div", { className: "ods-toast__desc", children: item.description })
|
|
29074
29156
|
] }),
|
|
29075
|
-
(item.actionLabel || item.action) && /* @__PURE__ */ (0,
|
|
29157
|
+
(item.actionLabel || item.action) && /* @__PURE__ */ (0, import_jsx_runtime134.jsx)("div", { className: "ods-toast__action", children: item.actionLabel ? (
|
|
29076
29158
|
// First-class action chip — consistent styling, auto-dismiss
|
|
29077
29159
|
// after the consumer's onAction runs. This is the path most
|
|
29078
29160
|
// consumers should use ("Undo", "Retry", "View").
|
|
29079
|
-
/* @__PURE__ */ (0,
|
|
29161
|
+
/* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
29080
29162
|
"button",
|
|
29081
29163
|
{
|
|
29082
29164
|
type: "button",
|
|
@@ -29095,7 +29177,7 @@ function ToastBody({ item, onDismiss }) {
|
|
|
29095
29177
|
// (including any explicit dismiss() they want to call).
|
|
29096
29178
|
item.action
|
|
29097
29179
|
) }),
|
|
29098
|
-
item.closeable && /* @__PURE__ */ (0,
|
|
29180
|
+
item.closeable && /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
29099
29181
|
"button",
|
|
29100
29182
|
{
|
|
29101
29183
|
type: "button",
|
|
@@ -29105,7 +29187,7 @@ function ToastBody({ item, onDismiss }) {
|
|
|
29105
29187
|
e.stopPropagation();
|
|
29106
29188
|
dismiss();
|
|
29107
29189
|
},
|
|
29108
|
-
children: /* @__PURE__ */ (0,
|
|
29190
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime134.jsx)("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
29109
29191
|
"path",
|
|
29110
29192
|
{
|
|
29111
29193
|
d: "M3 3l8 8M11 3l-8 8",
|
|
@@ -29138,7 +29220,7 @@ function PositionStack({ items, position, onDismiss, maxStack }) {
|
|
|
29138
29220
|
}
|
|
29139
29221
|
return { y: maxStack * 10 * dir, scale: 1 - maxStack * 0.05, opacity: 0 };
|
|
29140
29222
|
};
|
|
29141
|
-
return /* @__PURE__ */ (0,
|
|
29223
|
+
return /* @__PURE__ */ (0, import_jsx_runtime134.jsxs)(
|
|
29142
29224
|
"div",
|
|
29143
29225
|
{
|
|
29144
29226
|
className: cn(
|
|
@@ -29151,7 +29233,7 @@ function PositionStack({ items, position, onDismiss, maxStack }) {
|
|
|
29151
29233
|
onMouseLeave: () => setHovered(false),
|
|
29152
29234
|
"aria-live": "polite",
|
|
29153
29235
|
children: [
|
|
29154
|
-
/* @__PURE__ */ (0,
|
|
29236
|
+
/* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
29155
29237
|
"div",
|
|
29156
29238
|
{
|
|
29157
29239
|
className: cn("ods-toast-stack__scroll", expanded && "ods-toast-stack__scroll--expanded"),
|
|
@@ -29161,9 +29243,9 @@ function PositionStack({ items, position, onDismiss, maxStack }) {
|
|
|
29161
29243
|
setPinned((p) => !p);
|
|
29162
29244
|
}
|
|
29163
29245
|
},
|
|
29164
|
-
children: /* @__PURE__ */ (0,
|
|
29246
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(import_framer_motion36.AnimatePresence, { mode: "popLayout", children: ordered.map((item, idx) => {
|
|
29165
29247
|
const s = stackedStyle(idx);
|
|
29166
|
-
return /* @__PURE__ */ (0,
|
|
29248
|
+
return /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
29167
29249
|
import_framer_motion36.motion.div,
|
|
29168
29250
|
{
|
|
29169
29251
|
layout: true,
|
|
@@ -29186,14 +29268,14 @@ function PositionStack({ items, position, onDismiss, maxStack }) {
|
|
|
29186
29268
|
setPinned(true);
|
|
29187
29269
|
}
|
|
29188
29270
|
},
|
|
29189
|
-
children: /* @__PURE__ */ (0,
|
|
29271
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(ToastBody, { item, onDismiss })
|
|
29190
29272
|
},
|
|
29191
29273
|
item.id
|
|
29192
29274
|
);
|
|
29193
29275
|
}) })
|
|
29194
29276
|
}
|
|
29195
29277
|
),
|
|
29196
|
-
expanded && items.length > 1 && pinned && /* @__PURE__ */ (0,
|
|
29278
|
+
expanded && items.length > 1 && pinned && /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
29197
29279
|
"button",
|
|
29198
29280
|
{
|
|
29199
29281
|
type: "button",
|
|
@@ -29286,10 +29368,10 @@ function ToastProvider({
|
|
|
29286
29368
|
return out;
|
|
29287
29369
|
}, [toasts]);
|
|
29288
29370
|
const ctx = { toast, dismiss, dismissAll };
|
|
29289
|
-
const containers = /* @__PURE__ */ (0,
|
|
29371
|
+
const containers = /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(import_jsx_runtime134.Fragment, { children: POSITIONS.map((pos) => {
|
|
29290
29372
|
const list = groups[pos];
|
|
29291
29373
|
if (list.length === 0) return null;
|
|
29292
|
-
return /* @__PURE__ */ (0,
|
|
29374
|
+
return /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
29293
29375
|
PositionStack,
|
|
29294
29376
|
{
|
|
29295
29377
|
items: list,
|
|
@@ -29300,7 +29382,7 @@ function ToastProvider({
|
|
|
29300
29382
|
pos
|
|
29301
29383
|
);
|
|
29302
29384
|
}) });
|
|
29303
|
-
return /* @__PURE__ */ (0,
|
|
29385
|
+
return /* @__PURE__ */ (0, import_jsx_runtime134.jsxs)(ToastContext.Provider, { value: ctx, children: [
|
|
29304
29386
|
children,
|
|
29305
29387
|
typeof document !== "undefined" && (0, import_react_dom19.createPortal)(containers, document.body)
|
|
29306
29388
|
] });
|
|
@@ -29321,7 +29403,7 @@ function useToast() {
|
|
|
29321
29403
|
|
|
29322
29404
|
// src/components/Toggle/Toggle.tsx
|
|
29323
29405
|
var import_react156 = require("react");
|
|
29324
|
-
var
|
|
29406
|
+
var import_jsx_runtime135 = require("react/jsx-runtime");
|
|
29325
29407
|
function Toggle({
|
|
29326
29408
|
label,
|
|
29327
29409
|
options,
|
|
@@ -29402,7 +29484,7 @@ function Toggle({
|
|
|
29402
29484
|
);
|
|
29403
29485
|
const selectedIdx = options.findIndex((o) => o.value === value);
|
|
29404
29486
|
const fallbackTabIdx = selectedIdx >= 0 ? selectedIdx : findNextEnabled(-1, 1);
|
|
29405
|
-
return /* @__PURE__ */ (0,
|
|
29487
|
+
return /* @__PURE__ */ (0, import_jsx_runtime135.jsxs)(
|
|
29406
29488
|
"div",
|
|
29407
29489
|
{
|
|
29408
29490
|
...rest,
|
|
@@ -29414,8 +29496,8 @@ function Toggle({
|
|
|
29414
29496
|
className
|
|
29415
29497
|
),
|
|
29416
29498
|
children: [
|
|
29417
|
-
label && /* @__PURE__ */ (0,
|
|
29418
|
-
/* @__PURE__ */ (0,
|
|
29499
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime135.jsx)("span", { id: labelId, className: "ods-toggle-field__label", children: label }),
|
|
29500
|
+
/* @__PURE__ */ (0, import_jsx_runtime135.jsx)(
|
|
29419
29501
|
"div",
|
|
29420
29502
|
{
|
|
29421
29503
|
role: "radiogroup",
|
|
@@ -29432,7 +29514,7 @@ function Toggle({
|
|
|
29432
29514
|
children: options.map((opt, i) => {
|
|
29433
29515
|
const active = opt.value === value;
|
|
29434
29516
|
const isDisabled = disabled || opt.disabled;
|
|
29435
|
-
return /* @__PURE__ */ (0,
|
|
29517
|
+
return /* @__PURE__ */ (0, import_jsx_runtime135.jsxs)(
|
|
29436
29518
|
"button",
|
|
29437
29519
|
{
|
|
29438
29520
|
ref: (el) => {
|
|
@@ -29450,8 +29532,8 @@ function Toggle({
|
|
|
29450
29532
|
active && "ods-toggle__opt--active"
|
|
29451
29533
|
),
|
|
29452
29534
|
children: [
|
|
29453
|
-
opt.icon && /* @__PURE__ */ (0,
|
|
29454
|
-
/* @__PURE__ */ (0,
|
|
29535
|
+
opt.icon && /* @__PURE__ */ (0, import_jsx_runtime135.jsx)("span", { className: "ods-toggle__icon", "aria-hidden": "true", children: opt.icon }),
|
|
29536
|
+
/* @__PURE__ */ (0, import_jsx_runtime135.jsx)("span", { className: "ods-toggle__label", children: opt.label })
|
|
29455
29537
|
]
|
|
29456
29538
|
},
|
|
29457
29539
|
opt.value
|
|
@@ -29459,7 +29541,7 @@ function Toggle({
|
|
|
29459
29541
|
})
|
|
29460
29542
|
}
|
|
29461
29543
|
),
|
|
29462
|
-
error ? /* @__PURE__ */ (0,
|
|
29544
|
+
error ? /* @__PURE__ */ (0, import_jsx_runtime135.jsx)(
|
|
29463
29545
|
"div",
|
|
29464
29546
|
{
|
|
29465
29547
|
id: hintId,
|
|
@@ -29467,7 +29549,7 @@ function Toggle({
|
|
|
29467
29549
|
role: "alert",
|
|
29468
29550
|
children: error
|
|
29469
29551
|
}
|
|
29470
|
-
) : helperText ? /* @__PURE__ */ (0,
|
|
29552
|
+
) : helperText ? /* @__PURE__ */ (0, import_jsx_runtime135.jsx)("div", { id: hintId, className: "ods-toggle-field__hint", children: helperText }) : null
|
|
29471
29553
|
]
|
|
29472
29554
|
}
|
|
29473
29555
|
);
|
|
@@ -29475,9 +29557,9 @@ function Toggle({
|
|
|
29475
29557
|
Toggle.displayName = "Toggle";
|
|
29476
29558
|
|
|
29477
29559
|
// src/components/Toolbar/Toolbar.tsx
|
|
29478
|
-
var
|
|
29560
|
+
var import_jsx_runtime136 = require("react/jsx-runtime");
|
|
29479
29561
|
function Toolbar({ children, className }) {
|
|
29480
|
-
return /* @__PURE__ */ (0,
|
|
29562
|
+
return /* @__PURE__ */ (0, import_jsx_runtime136.jsx)("div", { role: "toolbar", className: cn("ods-toolbar", className), children });
|
|
29481
29563
|
}
|
|
29482
29564
|
function ToolbarButton({
|
|
29483
29565
|
icon,
|
|
@@ -29489,7 +29571,7 @@ function ToolbarButton({
|
|
|
29489
29571
|
className,
|
|
29490
29572
|
children
|
|
29491
29573
|
}) {
|
|
29492
|
-
return /* @__PURE__ */ (0,
|
|
29574
|
+
return /* @__PURE__ */ (0, import_jsx_runtime136.jsxs)(
|
|
29493
29575
|
"button",
|
|
29494
29576
|
{
|
|
29495
29577
|
type: "button",
|
|
@@ -29499,33 +29581,33 @@ function ToolbarButton({
|
|
|
29499
29581
|
"aria-pressed": active,
|
|
29500
29582
|
"aria-label": ariaLabel ?? (typeof label === "string" ? label : void 0),
|
|
29501
29583
|
children: [
|
|
29502
|
-
icon && /* @__PURE__ */ (0,
|
|
29503
|
-
label && /* @__PURE__ */ (0,
|
|
29584
|
+
icon && /* @__PURE__ */ (0, import_jsx_runtime136.jsx)("span", { className: "ods-toolbar__btn-icon", "aria-hidden": "true", children: icon }),
|
|
29585
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime136.jsx)("span", { className: "ods-toolbar__btn-label", children: label }),
|
|
29504
29586
|
children
|
|
29505
29587
|
]
|
|
29506
29588
|
}
|
|
29507
29589
|
);
|
|
29508
29590
|
}
|
|
29509
29591
|
function ToolbarDivider() {
|
|
29510
|
-
return /* @__PURE__ */ (0,
|
|
29592
|
+
return /* @__PURE__ */ (0, import_jsx_runtime136.jsx)("span", { className: "ods-toolbar__divider", "aria-hidden": "true" });
|
|
29511
29593
|
}
|
|
29512
29594
|
function ToolbarSpacer() {
|
|
29513
|
-
return /* @__PURE__ */ (0,
|
|
29595
|
+
return /* @__PURE__ */ (0, import_jsx_runtime136.jsx)("span", { className: "ods-toolbar__spacer" });
|
|
29514
29596
|
}
|
|
29515
29597
|
|
|
29516
29598
|
// src/components/ToolCard/ToolCard.tsx
|
|
29517
29599
|
var import_react157 = require("react");
|
|
29518
29600
|
var import_icons46 = require("@octaviaflow/icons");
|
|
29519
|
-
var
|
|
29601
|
+
var import_jsx_runtime137 = require("react/jsx-runtime");
|
|
29520
29602
|
var CATEGORY_GLYPH = {
|
|
29521
|
-
search: /* @__PURE__ */ (0,
|
|
29522
|
-
database: /* @__PURE__ */ (0,
|
|
29523
|
-
web: /* @__PURE__ */ (0,
|
|
29524
|
-
code: /* @__PURE__ */ (0,
|
|
29525
|
-
file: /* @__PURE__ */ (0,
|
|
29526
|
-
api: /* @__PURE__ */ (0,
|
|
29527
|
-
ai: /* @__PURE__ */ (0,
|
|
29528
|
-
custom: /* @__PURE__ */ (0,
|
|
29603
|
+
search: /* @__PURE__ */ (0, import_jsx_runtime137.jsx)(import_icons46.SearchIcon, { size: "xs" }),
|
|
29604
|
+
database: /* @__PURE__ */ (0, import_jsx_runtime137.jsx)(import_icons46.DataBaseIcon, { size: "xs" }),
|
|
29605
|
+
web: /* @__PURE__ */ (0, import_jsx_runtime137.jsx)(import_icons46.GlobeIcon, { size: "xs" }),
|
|
29606
|
+
code: /* @__PURE__ */ (0, import_jsx_runtime137.jsx)(import_icons46.CodeIcon, { size: "xs" }),
|
|
29607
|
+
file: /* @__PURE__ */ (0, import_jsx_runtime137.jsx)(import_icons46.DocumentIcon, { size: "xs" }),
|
|
29608
|
+
api: /* @__PURE__ */ (0, import_jsx_runtime137.jsx)(import_icons46.ApiIcon, { size: "xs" }),
|
|
29609
|
+
ai: /* @__PURE__ */ (0, import_jsx_runtime137.jsx)(import_icons46.MagicWandIcon, { size: "xs" }),
|
|
29610
|
+
custom: /* @__PURE__ */ (0, import_jsx_runtime137.jsx)(import_icons46.ExtensionsIcon, { size: "xs" })
|
|
29529
29611
|
};
|
|
29530
29612
|
var ToolCard = (0, import_react157.forwardRef)(
|
|
29531
29613
|
function ToolCard2({
|
|
@@ -29563,7 +29645,7 @@ var ToolCard = (0, import_react157.forwardRef)(
|
|
|
29563
29645
|
}
|
|
29564
29646
|
};
|
|
29565
29647
|
const showSwitch = !hideToggle && onToggle !== void 0;
|
|
29566
|
-
return /* @__PURE__ */ (0,
|
|
29648
|
+
return /* @__PURE__ */ (0, import_jsx_runtime137.jsxs)(
|
|
29567
29649
|
"div",
|
|
29568
29650
|
{
|
|
29569
29651
|
...rest,
|
|
@@ -29586,7 +29668,7 @@ var ToolCard = (0, import_react157.forwardRef)(
|
|
|
29586
29668
|
"aria-label": ariaLabel,
|
|
29587
29669
|
"aria-describedby": descId,
|
|
29588
29670
|
children: [
|
|
29589
|
-
/* @__PURE__ */ (0,
|
|
29671
|
+
/* @__PURE__ */ (0, import_jsx_runtime137.jsx)(
|
|
29590
29672
|
"span",
|
|
29591
29673
|
{
|
|
29592
29674
|
className: cn(
|
|
@@ -29597,15 +29679,15 @@ var ToolCard = (0, import_react157.forwardRef)(
|
|
|
29597
29679
|
children: icon ?? CATEGORY_GLYPH[category]
|
|
29598
29680
|
}
|
|
29599
29681
|
),
|
|
29600
|
-
/* @__PURE__ */ (0,
|
|
29601
|
-
/* @__PURE__ */ (0,
|
|
29602
|
-
/* @__PURE__ */ (0,
|
|
29603
|
-
isNew && /* @__PURE__ */ (0,
|
|
29604
|
-
badge && /* @__PURE__ */ (0,
|
|
29682
|
+
/* @__PURE__ */ (0, import_jsx_runtime137.jsxs)("div", { className: "ods-tool-card__body", children: [
|
|
29683
|
+
/* @__PURE__ */ (0, import_jsx_runtime137.jsxs)("div", { className: "ods-tool-card__head", children: [
|
|
29684
|
+
/* @__PURE__ */ (0, import_jsx_runtime137.jsx)("span", { id: nameId, className: "ods-tool-card__name", children: name }),
|
|
29685
|
+
isNew && /* @__PURE__ */ (0, import_jsx_runtime137.jsx)("span", { className: "ods-tool-card__new", "aria-label": "New", children: "NEW" }),
|
|
29686
|
+
badge && /* @__PURE__ */ (0, import_jsx_runtime137.jsx)("span", { className: "ods-tool-card__badge", children: badge })
|
|
29605
29687
|
] }),
|
|
29606
|
-
description && /* @__PURE__ */ (0,
|
|
29688
|
+
description && /* @__PURE__ */ (0, import_jsx_runtime137.jsx)("div", { id: descId, className: "ods-tool-card__desc", children: description })
|
|
29607
29689
|
] }),
|
|
29608
|
-
showSwitch && /* @__PURE__ */ (0,
|
|
29690
|
+
showSwitch && /* @__PURE__ */ (0, import_jsx_runtime137.jsx)(
|
|
29609
29691
|
"button",
|
|
29610
29692
|
{
|
|
29611
29693
|
type: "button",
|
|
@@ -29626,7 +29708,7 @@ var ToolCard = (0, import_react157.forwardRef)(
|
|
|
29626
29708
|
e.stopPropagation();
|
|
29627
29709
|
}
|
|
29628
29710
|
},
|
|
29629
|
-
children: /* @__PURE__ */ (0,
|
|
29711
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime137.jsx)("span", { className: "ods-tool-card__switch-thumb", "aria-hidden": "true" })
|
|
29630
29712
|
}
|
|
29631
29713
|
)
|
|
29632
29714
|
]
|
|
@@ -29637,7 +29719,7 @@ var ToolCard = (0, import_react157.forwardRef)(
|
|
|
29637
29719
|
ToolCard.displayName = "ToolCard";
|
|
29638
29720
|
|
|
29639
29721
|
// src/components/TopBar/TopBar.tsx
|
|
29640
|
-
var
|
|
29722
|
+
var import_jsx_runtime138 = require("react/jsx-runtime");
|
|
29641
29723
|
function TopBar({
|
|
29642
29724
|
brand,
|
|
29643
29725
|
workspaceSwitcher,
|
|
@@ -29657,32 +29739,32 @@ function TopBar({
|
|
|
29657
29739
|
const showDividerAfterBrand = hasBrandBlock && (hasWorkspace || hasCrumbs || hasTitle);
|
|
29658
29740
|
const showDividerAfterWorkspace = hasWorkspace && (hasCrumbs || hasTitle);
|
|
29659
29741
|
const BrandRoot = brand?.href ? "a" : "div";
|
|
29660
|
-
return /* @__PURE__ */ (0,
|
|
29661
|
-
/* @__PURE__ */ (0,
|
|
29662
|
-
brand && /* @__PURE__ */ (0,
|
|
29742
|
+
return /* @__PURE__ */ (0, import_jsx_runtime138.jsxs)("header", { ...props, className: cn("ods-topbar", className), children: [
|
|
29743
|
+
/* @__PURE__ */ (0, import_jsx_runtime138.jsxs)("div", { className: "ods-topbar__left", children: [
|
|
29744
|
+
brand && /* @__PURE__ */ (0, import_jsx_runtime138.jsxs)(
|
|
29663
29745
|
BrandRoot,
|
|
29664
29746
|
{
|
|
29665
29747
|
href: brand.href,
|
|
29666
29748
|
className: cn("ods-topbar__brand", brand.href && "ods-topbar__brand--link"),
|
|
29667
29749
|
children: [
|
|
29668
|
-
brand.logo && /* @__PURE__ */ (0,
|
|
29669
|
-
/* @__PURE__ */ (0,
|
|
29750
|
+
brand.logo && /* @__PURE__ */ (0, import_jsx_runtime138.jsx)("span", { className: "ods-topbar__brand-mark", children: brand.logo }),
|
|
29751
|
+
/* @__PURE__ */ (0, import_jsx_runtime138.jsx)("span", { className: "ods-topbar__brand-name", children: brand.name })
|
|
29670
29752
|
]
|
|
29671
29753
|
}
|
|
29672
29754
|
),
|
|
29673
|
-
showDividerAfterBrand && /* @__PURE__ */ (0,
|
|
29674
|
-
workspaceSwitcher && /* @__PURE__ */ (0,
|
|
29675
|
-
showDividerAfterWorkspace && /* @__PURE__ */ (0,
|
|
29676
|
-
hasCrumbs && /* @__PURE__ */ (0,
|
|
29677
|
-
idx > 0 && /* @__PURE__ */ (0,
|
|
29678
|
-
crumb.href ? /* @__PURE__ */ (0,
|
|
29755
|
+
showDividerAfterBrand && /* @__PURE__ */ (0, import_jsx_runtime138.jsx)("span", { className: "ods-topbar__divider", "aria-hidden": "true" }),
|
|
29756
|
+
workspaceSwitcher && /* @__PURE__ */ (0, import_jsx_runtime138.jsx)("div", { className: "ods-topbar__workspace", children: workspaceSwitcher }),
|
|
29757
|
+
showDividerAfterWorkspace && /* @__PURE__ */ (0, import_jsx_runtime138.jsx)("span", { className: "ods-topbar__divider", "aria-hidden": "true" }),
|
|
29758
|
+
hasCrumbs && /* @__PURE__ */ (0, import_jsx_runtime138.jsx)("nav", { className: "ods-topbar__breadcrumbs", "aria-label": "Breadcrumb", children: /* @__PURE__ */ (0, import_jsx_runtime138.jsx)("ol", { children: breadcrumbs.map((crumb, idx) => /* @__PURE__ */ (0, import_jsx_runtime138.jsxs)("li", { className: "ods-topbar__crumb", children: [
|
|
29759
|
+
idx > 0 && /* @__PURE__ */ (0, import_jsx_runtime138.jsx)("span", { className: "ods-topbar__separator", "aria-hidden": "true", children: "/" }),
|
|
29760
|
+
crumb.href ? /* @__PURE__ */ (0, import_jsx_runtime138.jsx)("a", { href: crumb.href, children: crumb.label }) : /* @__PURE__ */ (0, import_jsx_runtime138.jsx)("span", { "aria-current": idx === breadcrumbs.length - 1 ? "page" : void 0, children: crumb.label })
|
|
29679
29761
|
] }, idx)) }) }),
|
|
29680
|
-
hasTitle && /* @__PURE__ */ (0,
|
|
29762
|
+
hasTitle && /* @__PURE__ */ (0, import_jsx_runtime138.jsx)("h1", { className: "ods-topbar__title", children: title })
|
|
29681
29763
|
] }),
|
|
29682
|
-
children && /* @__PURE__ */ (0,
|
|
29683
|
-
/* @__PURE__ */ (0,
|
|
29684
|
-
onSearch && /* @__PURE__ */ (0,
|
|
29685
|
-
/* @__PURE__ */ (0,
|
|
29764
|
+
children && /* @__PURE__ */ (0, import_jsx_runtime138.jsx)("div", { className: "ods-topbar__center", children }),
|
|
29765
|
+
/* @__PURE__ */ (0, import_jsx_runtime138.jsxs)("div", { className: "ods-topbar__right", children: [
|
|
29766
|
+
onSearch && /* @__PURE__ */ (0, import_jsx_runtime138.jsxs)("div", { className: "ods-topbar__search", children: [
|
|
29767
|
+
/* @__PURE__ */ (0, import_jsx_runtime138.jsx)(
|
|
29686
29768
|
"svg",
|
|
29687
29769
|
{
|
|
29688
29770
|
className: "ods-topbar__search-icon",
|
|
@@ -29691,7 +29773,7 @@ function TopBar({
|
|
|
29691
29773
|
viewBox: "0 0 20 20",
|
|
29692
29774
|
fill: "currentColor",
|
|
29693
29775
|
"aria-hidden": "true",
|
|
29694
|
-
children: /* @__PURE__ */ (0,
|
|
29776
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime138.jsx)(
|
|
29695
29777
|
"path",
|
|
29696
29778
|
{
|
|
29697
29779
|
fillRule: "evenodd",
|
|
@@ -29701,7 +29783,7 @@ function TopBar({
|
|
|
29701
29783
|
)
|
|
29702
29784
|
}
|
|
29703
29785
|
),
|
|
29704
|
-
/* @__PURE__ */ (0,
|
|
29786
|
+
/* @__PURE__ */ (0, import_jsx_runtime138.jsx)(
|
|
29705
29787
|
"input",
|
|
29706
29788
|
{
|
|
29707
29789
|
type: "search",
|
|
@@ -29712,7 +29794,7 @@ function TopBar({
|
|
|
29712
29794
|
}
|
|
29713
29795
|
)
|
|
29714
29796
|
] }),
|
|
29715
|
-
actions && /* @__PURE__ */ (0,
|
|
29797
|
+
actions && /* @__PURE__ */ (0, import_jsx_runtime138.jsx)("div", { className: "ods-topbar__actions", children: actions })
|
|
29716
29798
|
] })
|
|
29717
29799
|
] });
|
|
29718
29800
|
}
|
|
@@ -29721,13 +29803,13 @@ function TopBar({
|
|
|
29721
29803
|
var import_framer_motion37 = require("framer-motion");
|
|
29722
29804
|
var import_react158 = require("react");
|
|
29723
29805
|
var import_icons47 = require("@octaviaflow/icons");
|
|
29724
|
-
var
|
|
29806
|
+
var import_jsx_runtime139 = require("react/jsx-runtime");
|
|
29725
29807
|
var DEFAULT_KIND_GLYPH = {
|
|
29726
|
-
thought: /* @__PURE__ */ (0,
|
|
29727
|
-
tool: /* @__PURE__ */ (0,
|
|
29728
|
-
input: /* @__PURE__ */ (0,
|
|
29729
|
-
output: /* @__PURE__ */ (0,
|
|
29730
|
-
error: /* @__PURE__ */ (0,
|
|
29808
|
+
thought: /* @__PURE__ */ (0, import_jsx_runtime139.jsx)(import_icons47.IdeaIcon, { size: "xs" }),
|
|
29809
|
+
tool: /* @__PURE__ */ (0, import_jsx_runtime139.jsx)(import_icons47.BuildToolIcon, { size: "xs" }),
|
|
29810
|
+
input: /* @__PURE__ */ (0, import_jsx_runtime139.jsx)(import_icons47.ConnectionReceiveIcon, { size: "xs" }),
|
|
29811
|
+
output: /* @__PURE__ */ (0, import_jsx_runtime139.jsx)(import_icons47.ConnectionSendIcon, { size: "xs" }),
|
|
29812
|
+
error: /* @__PURE__ */ (0, import_jsx_runtime139.jsx)(import_icons47.WarningAltIcon, { size: "xs" })
|
|
29731
29813
|
};
|
|
29732
29814
|
var FALLBACK_GLYPH = DEFAULT_KIND_GLYPH.thought;
|
|
29733
29815
|
var TraceStep = (0, import_react158.forwardRef)(
|
|
@@ -29767,7 +29849,7 @@ var TraceStep = (0, import_react158.forwardRef)(
|
|
|
29767
29849
|
onOpenChange?.(next);
|
|
29768
29850
|
}, [canExpand, open, isControlled, onOpenChange]);
|
|
29769
29851
|
const resolvedGlyph = icon ?? kindIcons?.[kind] ?? DEFAULT_KIND_GLYPH[kind] ?? FALLBACK_GLYPH;
|
|
29770
|
-
return /* @__PURE__ */ (0,
|
|
29852
|
+
return /* @__PURE__ */ (0, import_jsx_runtime139.jsxs)(
|
|
29771
29853
|
"div",
|
|
29772
29854
|
{
|
|
29773
29855
|
...rest,
|
|
@@ -29783,18 +29865,18 @@ var TraceStep = (0, import_react158.forwardRef)(
|
|
|
29783
29865
|
className
|
|
29784
29866
|
),
|
|
29785
29867
|
children: [
|
|
29786
|
-
/* @__PURE__ */ (0,
|
|
29787
|
-
/* @__PURE__ */ (0,
|
|
29868
|
+
/* @__PURE__ */ (0, import_jsx_runtime139.jsxs)("div", { className: "ods-trace-step__rail", "aria-hidden": "true", children: [
|
|
29869
|
+
/* @__PURE__ */ (0, import_jsx_runtime139.jsx)(
|
|
29788
29870
|
import_framer_motion37.motion.span,
|
|
29789
29871
|
{
|
|
29790
29872
|
className: "ods-trace-step__icon",
|
|
29791
29873
|
initial: disableAnimation ? false : { scale: 0.6, opacity: 0 },
|
|
29792
29874
|
animate: { scale: 1, opacity: 1 },
|
|
29793
29875
|
transition: { duration: 0.2, ease: [0.16, 1, 0.3, 1] },
|
|
29794
|
-
children: status === "running" ? /* @__PURE__ */ (0,
|
|
29876
|
+
children: status === "running" ? /* @__PURE__ */ (0, import_jsx_runtime139.jsx)("span", { className: "ods-trace-step__spin", children: /* @__PURE__ */ (0, import_jsx_runtime139.jsx)(import_icons47.CircleDashIcon, { size: "xs" }) }) : resolvedGlyph
|
|
29795
29877
|
}
|
|
29796
29878
|
),
|
|
29797
|
-
!isLast && /* @__PURE__ */ (0,
|
|
29879
|
+
!isLast && /* @__PURE__ */ (0, import_jsx_runtime139.jsx)(
|
|
29798
29880
|
import_framer_motion37.motion.span,
|
|
29799
29881
|
{
|
|
29800
29882
|
className: "ods-trace-step__line",
|
|
@@ -29804,8 +29886,8 @@ var TraceStep = (0, import_react158.forwardRef)(
|
|
|
29804
29886
|
}
|
|
29805
29887
|
)
|
|
29806
29888
|
] }),
|
|
29807
|
-
/* @__PURE__ */ (0,
|
|
29808
|
-
/* @__PURE__ */ (0,
|
|
29889
|
+
/* @__PURE__ */ (0, import_jsx_runtime139.jsxs)("div", { className: "ods-trace-step__body", children: [
|
|
29890
|
+
/* @__PURE__ */ (0, import_jsx_runtime139.jsxs)(
|
|
29809
29891
|
"button",
|
|
29810
29892
|
{
|
|
29811
29893
|
id: headId,
|
|
@@ -29816,7 +29898,7 @@ var TraceStep = (0, import_react158.forwardRef)(
|
|
|
29816
29898
|
"aria-controls": canExpand ? contentId : void 0,
|
|
29817
29899
|
disabled: !canExpand,
|
|
29818
29900
|
children: [
|
|
29819
|
-
index != null && /* @__PURE__ */ (0,
|
|
29901
|
+
index != null && /* @__PURE__ */ (0, import_jsx_runtime139.jsx)(
|
|
29820
29902
|
"span",
|
|
29821
29903
|
{
|
|
29822
29904
|
className: cn(
|
|
@@ -29826,32 +29908,32 @@ var TraceStep = (0, import_react158.forwardRef)(
|
|
|
29826
29908
|
children: index
|
|
29827
29909
|
}
|
|
29828
29910
|
),
|
|
29829
|
-
/* @__PURE__ */ (0,
|
|
29830
|
-
tool && /* @__PURE__ */ (0,
|
|
29911
|
+
/* @__PURE__ */ (0, import_jsx_runtime139.jsx)("span", { className: "ods-trace-step__title", children: title }),
|
|
29912
|
+
tool && /* @__PURE__ */ (0, import_jsx_runtime139.jsxs)(
|
|
29831
29913
|
"span",
|
|
29832
29914
|
{
|
|
29833
29915
|
className: "ods-trace-step__tool",
|
|
29834
29916
|
title: tool,
|
|
29835
29917
|
"aria-label": `Tool: ${tool}`,
|
|
29836
29918
|
children: [
|
|
29837
|
-
/* @__PURE__ */ (0,
|
|
29919
|
+
/* @__PURE__ */ (0, import_jsx_runtime139.jsx)("span", { className: "ods-trace-step__tool-icon", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime139.jsx)(import_icons47.BuildToolIcon, { size: "xs" }) }),
|
|
29838
29920
|
tool
|
|
29839
29921
|
]
|
|
29840
29922
|
}
|
|
29841
29923
|
),
|
|
29842
|
-
/* @__PURE__ */ (0,
|
|
29843
|
-
tokens != null && /* @__PURE__ */ (0,
|
|
29924
|
+
/* @__PURE__ */ (0, import_jsx_runtime139.jsxs)("span", { className: "ods-trace-step__meta", children: [
|
|
29925
|
+
tokens != null && /* @__PURE__ */ (0, import_jsx_runtime139.jsxs)(
|
|
29844
29926
|
"span",
|
|
29845
29927
|
{
|
|
29846
29928
|
className: "ods-trace-step__tokens",
|
|
29847
29929
|
"aria-label": `${tokens} tokens`,
|
|
29848
29930
|
children: [
|
|
29849
|
-
/* @__PURE__ */ (0,
|
|
29931
|
+
/* @__PURE__ */ (0, import_jsx_runtime139.jsx)("span", { children: tokens.toLocaleString() }),
|
|
29850
29932
|
" tok"
|
|
29851
29933
|
]
|
|
29852
29934
|
}
|
|
29853
29935
|
),
|
|
29854
|
-
duration && /* @__PURE__ */ (0,
|
|
29936
|
+
duration && /* @__PURE__ */ (0, import_jsx_runtime139.jsx)(
|
|
29855
29937
|
"span",
|
|
29856
29938
|
{
|
|
29857
29939
|
className: "ods-trace-step__duration",
|
|
@@ -29860,20 +29942,20 @@ var TraceStep = (0, import_react158.forwardRef)(
|
|
|
29860
29942
|
}
|
|
29861
29943
|
)
|
|
29862
29944
|
] }),
|
|
29863
|
-
canExpand && /* @__PURE__ */ (0,
|
|
29945
|
+
canExpand && /* @__PURE__ */ (0, import_jsx_runtime139.jsx)(
|
|
29864
29946
|
import_framer_motion37.motion.span,
|
|
29865
29947
|
{
|
|
29866
29948
|
className: "ods-trace-step__chev",
|
|
29867
29949
|
"aria-hidden": "true",
|
|
29868
29950
|
animate: { rotate: open ? 180 : 0 },
|
|
29869
29951
|
transition: { duration: 0.18, ease: [0.16, 1, 0.3, 1] },
|
|
29870
|
-
children: /* @__PURE__ */ (0,
|
|
29952
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime139.jsx)(import_icons47.CaretDownIcon, { size: "xs" })
|
|
29871
29953
|
}
|
|
29872
29954
|
)
|
|
29873
29955
|
]
|
|
29874
29956
|
}
|
|
29875
29957
|
),
|
|
29876
|
-
/* @__PURE__ */ (0,
|
|
29958
|
+
/* @__PURE__ */ (0, import_jsx_runtime139.jsx)(import_framer_motion37.AnimatePresence, { initial: false, children: canExpand && open && /* @__PURE__ */ (0, import_jsx_runtime139.jsx)(
|
|
29877
29959
|
import_framer_motion37.motion.div,
|
|
29878
29960
|
{
|
|
29879
29961
|
id: contentId,
|
|
@@ -29885,7 +29967,7 @@ var TraceStep = (0, import_react158.forwardRef)(
|
|
|
29885
29967
|
exit: disableAnimation ? void 0 : { height: 0, opacity: 0 },
|
|
29886
29968
|
transition: { duration: 0.2, ease: [0.16, 1, 0.3, 1] },
|
|
29887
29969
|
style: { overflow: "hidden" },
|
|
29888
|
-
children: /* @__PURE__ */ (0,
|
|
29970
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime139.jsx)("div", { className: "ods-trace-step__content-inner", children })
|
|
29889
29971
|
},
|
|
29890
29972
|
"content"
|
|
29891
29973
|
) })
|
|
@@ -29901,7 +29983,7 @@ TraceStep.displayName = "TraceStep";
|
|
|
29901
29983
|
var import_icons48 = require("@octaviaflow/icons");
|
|
29902
29984
|
var import_framer_motion38 = require("framer-motion");
|
|
29903
29985
|
var import_react159 = require("react");
|
|
29904
|
-
var
|
|
29986
|
+
var import_jsx_runtime140 = require("react/jsx-runtime");
|
|
29905
29987
|
function buildVisibleList(nodes, expanded, out = [], level = 0, parentId = null) {
|
|
29906
29988
|
for (const n of nodes) {
|
|
29907
29989
|
out.push({ node: n, level, parentId });
|
|
@@ -30064,7 +30146,7 @@ var TreeView = (0, import_react159.forwardRef)(
|
|
|
30064
30146
|
const myIdx = visibleIdx.value;
|
|
30065
30147
|
visibleIdx.value += 1;
|
|
30066
30148
|
const showLoadingChild = isExpanded && isLoading && !kids;
|
|
30067
|
-
return /* @__PURE__ */ (0,
|
|
30149
|
+
return /* @__PURE__ */ (0, import_jsx_runtime140.jsxs)(
|
|
30068
30150
|
"li",
|
|
30069
30151
|
{
|
|
30070
30152
|
id: `${baseId}-node-${node.id}`,
|
|
@@ -30084,7 +30166,7 @@ var TreeView = (0, import_react159.forwardRef)(
|
|
|
30084
30166
|
handleKeyDown(e, myIdx);
|
|
30085
30167
|
},
|
|
30086
30168
|
children: [
|
|
30087
|
-
/* @__PURE__ */ (0,
|
|
30169
|
+
/* @__PURE__ */ (0, import_jsx_runtime140.jsxs)(
|
|
30088
30170
|
"div",
|
|
30089
30171
|
{
|
|
30090
30172
|
className: "ods-tree__row",
|
|
@@ -30097,7 +30179,7 @@ var TreeView = (0, import_react159.forwardRef)(
|
|
|
30097
30179
|
handleSelect(node);
|
|
30098
30180
|
},
|
|
30099
30181
|
children: [
|
|
30100
|
-
/* @__PURE__ */ (0,
|
|
30182
|
+
/* @__PURE__ */ (0, import_jsx_runtime140.jsx)(
|
|
30101
30183
|
"button",
|
|
30102
30184
|
{
|
|
30103
30185
|
type: "button",
|
|
@@ -30112,12 +30194,12 @@ var TreeView = (0, import_react159.forwardRef)(
|
|
|
30112
30194
|
e.stopPropagation();
|
|
30113
30195
|
if (isBranch && !node.disabled) void toggleExpand(node);
|
|
30114
30196
|
},
|
|
30115
|
-
children: isBranch && /* @__PURE__ */ (0,
|
|
30197
|
+
children: isBranch && /* @__PURE__ */ (0, import_jsx_runtime140.jsx)(import_icons48.ChevronRightIcon, { size: "xs", "aria-hidden": true })
|
|
30116
30198
|
}
|
|
30117
30199
|
),
|
|
30118
|
-
(node.icon || node.iconExpanded) && /* @__PURE__ */ (0,
|
|
30119
|
-
/* @__PURE__ */ (0,
|
|
30120
|
-
node.trailing && /* @__PURE__ */ (0,
|
|
30200
|
+
(node.icon || node.iconExpanded) && /* @__PURE__ */ (0, import_jsx_runtime140.jsx)("span", { className: "ods-tree__icon", "aria-hidden": "true", children: isExpanded && node.iconExpanded ? node.iconExpanded : node.icon }),
|
|
30201
|
+
/* @__PURE__ */ (0, import_jsx_runtime140.jsx)("span", { className: "ods-tree__label", children: node.label }),
|
|
30202
|
+
node.trailing && /* @__PURE__ */ (0, import_jsx_runtime140.jsx)(
|
|
30121
30203
|
"span",
|
|
30122
30204
|
{
|
|
30123
30205
|
className: "ods-tree__trailing",
|
|
@@ -30128,7 +30210,7 @@ var TreeView = (0, import_react159.forwardRef)(
|
|
|
30128
30210
|
]
|
|
30129
30211
|
}
|
|
30130
30212
|
),
|
|
30131
|
-
isBranch && isExpanded && /* @__PURE__ */ (0,
|
|
30213
|
+
isBranch && isExpanded && /* @__PURE__ */ (0, import_jsx_runtime140.jsx)(
|
|
30132
30214
|
import_framer_motion38.motion.ul,
|
|
30133
30215
|
{
|
|
30134
30216
|
role: "group",
|
|
@@ -30136,7 +30218,7 @@ var TreeView = (0, import_react159.forwardRef)(
|
|
|
30136
30218
|
initial: reducedMotion ? false : { height: 0, opacity: 0 },
|
|
30137
30219
|
animate: reducedMotion ? void 0 : { height: "auto", opacity: 1 },
|
|
30138
30220
|
transition: reducedMotion ? { duration: 0 } : { duration: 0.14 },
|
|
30139
|
-
children: showLoadingChild ? /* @__PURE__ */ (0,
|
|
30221
|
+
children: showLoadingChild ? /* @__PURE__ */ (0, import_jsx_runtime140.jsx)(
|
|
30140
30222
|
"li",
|
|
30141
30223
|
{
|
|
30142
30224
|
className: "ods-tree__loading",
|
|
@@ -30148,7 +30230,7 @@ var TreeView = (0, import_react159.forwardRef)(
|
|
|
30148
30230
|
"aria-busy": "true",
|
|
30149
30231
|
children: "Loading\u2026"
|
|
30150
30232
|
}
|
|
30151
|
-
) : kids && kids.length > 0 ? kids.map((c) => renderNode(c, level + 1, visibleIdx)) : /* @__PURE__ */ (0,
|
|
30233
|
+
) : kids && kids.length > 0 ? kids.map((c) => renderNode(c, level + 1, visibleIdx)) : /* @__PURE__ */ (0, import_jsx_runtime140.jsx)(
|
|
30152
30234
|
"li",
|
|
30153
30235
|
{
|
|
30154
30236
|
className: "ods-tree__empty",
|
|
@@ -30170,7 +30252,7 @@ var TreeView = (0, import_react159.forwardRef)(
|
|
|
30170
30252
|
const visibleIdxCursor = { value: 0 };
|
|
30171
30253
|
(0, import_react159.useEffect)(() => {
|
|
30172
30254
|
}, [tabStopId]);
|
|
30173
|
-
return /* @__PURE__ */ (0,
|
|
30255
|
+
return /* @__PURE__ */ (0, import_jsx_runtime140.jsx)(
|
|
30174
30256
|
"ul",
|
|
30175
30257
|
{
|
|
30176
30258
|
...rest,
|
|
@@ -30194,7 +30276,7 @@ TreeView.displayName = "TreeView";
|
|
|
30194
30276
|
|
|
30195
30277
|
// src/components/UserCard/UserCard.tsx
|
|
30196
30278
|
var import_react160 = require("react");
|
|
30197
|
-
var
|
|
30279
|
+
var import_jsx_runtime141 = require("react/jsx-runtime");
|
|
30198
30280
|
var UserCard = (0, import_react160.forwardRef)(
|
|
30199
30281
|
function UserCard2({
|
|
30200
30282
|
name,
|
|
@@ -30222,7 +30304,7 @@ var UserCard = (0, import_react160.forwardRef)(
|
|
|
30222
30304
|
const isInteractive = Boolean(href || onClick) && !disabled;
|
|
30223
30305
|
const renderAvatar = () => {
|
|
30224
30306
|
if (avatarNode) {
|
|
30225
|
-
return /* @__PURE__ */ (0,
|
|
30307
|
+
return /* @__PURE__ */ (0, import_jsx_runtime141.jsx)(
|
|
30226
30308
|
"span",
|
|
30227
30309
|
{
|
|
30228
30310
|
className: "ods-user-card__avatar ods-user-card__avatar--legacy",
|
|
@@ -30232,7 +30314,7 @@ var UserCard = (0, import_react160.forwardRef)(
|
|
|
30232
30314
|
);
|
|
30233
30315
|
}
|
|
30234
30316
|
const derivedInitials = avatar?.initials ?? (typeof initial === "string" ? initial : typeof name === "string" ? name.charAt(0).toUpperCase() : void 0);
|
|
30235
|
-
return /* @__PURE__ */ (0,
|
|
30317
|
+
return /* @__PURE__ */ (0, import_jsx_runtime141.jsx)(
|
|
30236
30318
|
Avatar,
|
|
30237
30319
|
{
|
|
30238
30320
|
size: orientation === "horizontal" ? "md" : "lg",
|
|
@@ -30244,10 +30326,10 @@ var UserCard = (0, import_react160.forwardRef)(
|
|
|
30244
30326
|
}
|
|
30245
30327
|
);
|
|
30246
30328
|
};
|
|
30247
|
-
const body = /* @__PURE__ */ (0,
|
|
30329
|
+
const body = /* @__PURE__ */ (0, import_jsx_runtime141.jsxs)(import_jsx_runtime141.Fragment, { children: [
|
|
30248
30330
|
renderAvatar(),
|
|
30249
|
-
/* @__PURE__ */ (0,
|
|
30250
|
-
/* @__PURE__ */ (0,
|
|
30331
|
+
/* @__PURE__ */ (0, import_jsx_runtime141.jsxs)("div", { className: "ods-user-card__body", children: [
|
|
30332
|
+
/* @__PURE__ */ (0, import_jsx_runtime141.jsx)(
|
|
30251
30333
|
Card.Title,
|
|
30252
30334
|
{
|
|
30253
30335
|
as: nameAs,
|
|
@@ -30256,14 +30338,14 @@ var UserCard = (0, import_react160.forwardRef)(
|
|
|
30256
30338
|
children: name
|
|
30257
30339
|
}
|
|
30258
30340
|
),
|
|
30259
|
-
role && /* @__PURE__ */ (0,
|
|
30260
|
-
meta && /* @__PURE__ */ (0,
|
|
30341
|
+
role && /* @__PURE__ */ (0, import_jsx_runtime141.jsx)("div", { className: "ods-user-card__role", children: role }),
|
|
30342
|
+
meta && /* @__PURE__ */ (0, import_jsx_runtime141.jsx)("div", { className: "ods-user-card__meta", children: meta })
|
|
30261
30343
|
] }),
|
|
30262
|
-
stats && stats.length > 0 && /* @__PURE__ */ (0,
|
|
30263
|
-
/* @__PURE__ */ (0,
|
|
30264
|
-
/* @__PURE__ */ (0,
|
|
30344
|
+
stats && stats.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime141.jsx)("div", { className: "ods-user-card__stats", children: stats.map((s, i) => /* @__PURE__ */ (0, import_jsx_runtime141.jsxs)("div", { className: "ods-user-card__stat", children: [
|
|
30345
|
+
/* @__PURE__ */ (0, import_jsx_runtime141.jsx)("div", { className: "ods-user-card__stat-value", children: s.value }),
|
|
30346
|
+
/* @__PURE__ */ (0, import_jsx_runtime141.jsx)("div", { className: "ods-user-card__stat-label", children: s.label })
|
|
30265
30347
|
] }, i)) }),
|
|
30266
|
-
action && /* @__PURE__ */ (0,
|
|
30348
|
+
action && /* @__PURE__ */ (0, import_jsx_runtime141.jsx)("div", { className: "ods-user-card__action", children: action })
|
|
30267
30349
|
] });
|
|
30268
30350
|
const sharedClass = cn(
|
|
30269
30351
|
"ods-user-card",
|
|
@@ -30273,7 +30355,7 @@ var UserCard = (0, import_react160.forwardRef)(
|
|
|
30273
30355
|
className
|
|
30274
30356
|
);
|
|
30275
30357
|
if (href && !disabled) {
|
|
30276
|
-
return /* @__PURE__ */ (0,
|
|
30358
|
+
return /* @__PURE__ */ (0, import_jsx_runtime141.jsx)(
|
|
30277
30359
|
Card,
|
|
30278
30360
|
{
|
|
30279
30361
|
asChild: true,
|
|
@@ -30281,7 +30363,7 @@ var UserCard = (0, import_react160.forwardRef)(
|
|
|
30281
30363
|
padding: "none",
|
|
30282
30364
|
className: sharedClass,
|
|
30283
30365
|
"aria-labelledby": nameId,
|
|
30284
|
-
children: /* @__PURE__ */ (0,
|
|
30366
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime141.jsx)(
|
|
30285
30367
|
"a",
|
|
30286
30368
|
{
|
|
30287
30369
|
...rest,
|
|
@@ -30295,7 +30377,7 @@ var UserCard = (0, import_react160.forwardRef)(
|
|
|
30295
30377
|
}
|
|
30296
30378
|
);
|
|
30297
30379
|
}
|
|
30298
|
-
return /* @__PURE__ */ (0,
|
|
30380
|
+
return /* @__PURE__ */ (0, import_jsx_runtime141.jsx)(
|
|
30299
30381
|
Card,
|
|
30300
30382
|
{
|
|
30301
30383
|
...rest,
|
|
@@ -31350,7 +31432,7 @@ function findContainingGroup(point, nodes, exclude = []) {
|
|
|
31350
31432
|
|
|
31351
31433
|
// src/workflow/components/FlowEdge/FlowEdge.tsx
|
|
31352
31434
|
var import_react162 = require("react");
|
|
31353
|
-
var
|
|
31435
|
+
var import_jsx_runtime142 = require("react/jsx-runtime");
|
|
31354
31436
|
function FlowEdgeImpl({
|
|
31355
31437
|
edge,
|
|
31356
31438
|
nodes,
|
|
@@ -31424,7 +31506,7 @@ function FlowEdgeImpl({
|
|
|
31424
31506
|
setDraftLabel(edge.label ?? "");
|
|
31425
31507
|
}
|
|
31426
31508
|
};
|
|
31427
|
-
return /* @__PURE__ */ (0,
|
|
31509
|
+
return /* @__PURE__ */ (0, import_jsx_runtime142.jsxs)(
|
|
31428
31510
|
"g",
|
|
31429
31511
|
{
|
|
31430
31512
|
className: cn(
|
|
@@ -31450,7 +31532,7 @@ function FlowEdgeImpl({
|
|
|
31450
31532
|
setEditing(true);
|
|
31451
31533
|
},
|
|
31452
31534
|
children: [
|
|
31453
|
-
/* @__PURE__ */ (0,
|
|
31535
|
+
/* @__PURE__ */ (0, import_jsx_runtime142.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime142.jsx)(
|
|
31454
31536
|
"marker",
|
|
31455
31537
|
{
|
|
31456
31538
|
id: markerId,
|
|
@@ -31460,11 +31542,11 @@ function FlowEdgeImpl({
|
|
|
31460
31542
|
markerWidth: "7",
|
|
31461
31543
|
markerHeight: "7",
|
|
31462
31544
|
orient: "auto-start-reverse",
|
|
31463
|
-
children: /* @__PURE__ */ (0,
|
|
31545
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime142.jsx)("path", { d: "M0 0L10 5L0 10z", fill: stroke })
|
|
31464
31546
|
}
|
|
31465
31547
|
) }),
|
|
31466
|
-
/* @__PURE__ */ (0,
|
|
31467
|
-
/* @__PURE__ */ (0,
|
|
31548
|
+
/* @__PURE__ */ (0, import_jsx_runtime142.jsx)("path", { d: hitD, stroke: "transparent", strokeWidth: 20, fill: "none" }),
|
|
31549
|
+
/* @__PURE__ */ (0, import_jsx_runtime142.jsx)(
|
|
31468
31550
|
"path",
|
|
31469
31551
|
{
|
|
31470
31552
|
d,
|
|
@@ -31479,7 +31561,7 @@ function FlowEdgeImpl({
|
|
|
31479
31561
|
} : void 0
|
|
31480
31562
|
}
|
|
31481
31563
|
),
|
|
31482
|
-
showChrome && /* @__PURE__ */ (0,
|
|
31564
|
+
showChrome && /* @__PURE__ */ (0, import_jsx_runtime142.jsx)(
|
|
31483
31565
|
"foreignObject",
|
|
31484
31566
|
{
|
|
31485
31567
|
x: midX - 140,
|
|
@@ -31487,8 +31569,8 @@ function FlowEdgeImpl({
|
|
|
31487
31569
|
width: 280,
|
|
31488
31570
|
height: 32,
|
|
31489
31571
|
style: { overflow: "visible", pointerEvents: "none" },
|
|
31490
|
-
children: /* @__PURE__ */ (0,
|
|
31491
|
-
(label || editing) && (editing ? /* @__PURE__ */ (0,
|
|
31572
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime142.jsxs)("div", { className: "ods-flow-edge-v2__chrome", children: [
|
|
31573
|
+
(label || editing) && (editing ? /* @__PURE__ */ (0, import_jsx_runtime142.jsx)(
|
|
31492
31574
|
"input",
|
|
31493
31575
|
{
|
|
31494
31576
|
ref: inputRef,
|
|
@@ -31502,7 +31584,7 @@ function FlowEdgeImpl({
|
|
|
31502
31584
|
onMouseDown: (e) => e.stopPropagation(),
|
|
31503
31585
|
"aria-label": "Edit edge label"
|
|
31504
31586
|
}
|
|
31505
|
-
) : /* @__PURE__ */ (0,
|
|
31587
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime142.jsx)(
|
|
31506
31588
|
"button",
|
|
31507
31589
|
{
|
|
31508
31590
|
type: "button",
|
|
@@ -31519,10 +31601,10 @@ function FlowEdgeImpl({
|
|
|
31519
31601
|
},
|
|
31520
31602
|
title: onLabelChange ? "Double-click to edit" : void 0,
|
|
31521
31603
|
tabIndex: onLabelChange ? 0 : -1,
|
|
31522
|
-
children: /* @__PURE__ */ (0,
|
|
31604
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime142.jsx)("span", { children: label })
|
|
31523
31605
|
}
|
|
31524
31606
|
)),
|
|
31525
|
-
hasDelete && /* @__PURE__ */ (0,
|
|
31607
|
+
hasDelete && /* @__PURE__ */ (0, import_jsx_runtime142.jsx)(
|
|
31526
31608
|
"button",
|
|
31527
31609
|
{
|
|
31528
31610
|
type: "button",
|
|
@@ -31532,7 +31614,7 @@ function FlowEdgeImpl({
|
|
|
31532
31614
|
onDelete?.(edge.id);
|
|
31533
31615
|
},
|
|
31534
31616
|
"aria-label": "Delete edge",
|
|
31535
|
-
children: /* @__PURE__ */ (0,
|
|
31617
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime142.jsx)("svg", { width: "10", height: "10", viewBox: "0 0 10 10", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime142.jsx)(
|
|
31536
31618
|
"path",
|
|
31537
31619
|
{
|
|
31538
31620
|
d: "M2 2l6 6M8 2l-6 6",
|
|
@@ -31615,7 +31697,7 @@ function useFlowNodeContext() {
|
|
|
31615
31697
|
}
|
|
31616
31698
|
|
|
31617
31699
|
// src/workflow/components/FlowNode/FlowNode.tsx
|
|
31618
|
-
var
|
|
31700
|
+
var import_jsx_runtime143 = require("react/jsx-runtime");
|
|
31619
31701
|
function FlowNode3({
|
|
31620
31702
|
node,
|
|
31621
31703
|
selected,
|
|
@@ -31674,7 +31756,7 @@ function FlowNode3({
|
|
|
31674
31756
|
bridge.selectNode(node.id, e.metaKey || e.ctrlKey || e.shiftKey);
|
|
31675
31757
|
bridge.notifyNodeClick(node.id);
|
|
31676
31758
|
};
|
|
31677
|
-
return /* @__PURE__ */ (0,
|
|
31759
|
+
return /* @__PURE__ */ (0, import_jsx_runtime143.jsx)(
|
|
31678
31760
|
"div",
|
|
31679
31761
|
{
|
|
31680
31762
|
ref: wrapperRef,
|
|
@@ -31703,7 +31785,7 @@ function FlowNode3({
|
|
|
31703
31785
|
onPointerDown: handlePointerDown,
|
|
31704
31786
|
onPointerMove: handlePointerMove,
|
|
31705
31787
|
onClick: handleClick,
|
|
31706
|
-
children: /* @__PURE__ */ (0,
|
|
31788
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime143.jsx)(FlowNodeContext.Provider, { value: ctx, children: /* @__PURE__ */ (0, import_jsx_runtime143.jsx)(Kind, { node, selected, dragging, isConnecting }) })
|
|
31707
31789
|
}
|
|
31708
31790
|
);
|
|
31709
31791
|
}
|
|
@@ -31715,7 +31797,7 @@ function buildNodeKindRegistry(defaults, overrides) {
|
|
|
31715
31797
|
|
|
31716
31798
|
// src/workflow/components/Handle/Handle.tsx
|
|
31717
31799
|
var import_react166 = require("react");
|
|
31718
|
-
var
|
|
31800
|
+
var import_jsx_runtime144 = require("react/jsx-runtime");
|
|
31719
31801
|
var DEFAULT_HANDLE_ID = "default";
|
|
31720
31802
|
function Handle({
|
|
31721
31803
|
type,
|
|
@@ -31765,7 +31847,7 @@ function Handle({
|
|
|
31765
31847
|
clientY: e.clientY
|
|
31766
31848
|
});
|
|
31767
31849
|
};
|
|
31768
|
-
return /* @__PURE__ */ (0,
|
|
31850
|
+
return /* @__PURE__ */ (0, import_jsx_runtime144.jsxs)(
|
|
31769
31851
|
"div",
|
|
31770
31852
|
{
|
|
31771
31853
|
ref,
|
|
@@ -31787,8 +31869,8 @@ function Handle({
|
|
|
31787
31869
|
},
|
|
31788
31870
|
onPointerDown: handlePointerDown,
|
|
31789
31871
|
children: [
|
|
31790
|
-
/* @__PURE__ */ (0,
|
|
31791
|
-
label && /* @__PURE__ */ (0,
|
|
31872
|
+
/* @__PURE__ */ (0, import_jsx_runtime144.jsx)("div", { className: "ods-flow-handle__dot" }),
|
|
31873
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime144.jsx)("span", { className: "ods-flow-handle__label", children: label })
|
|
31792
31874
|
]
|
|
31793
31875
|
}
|
|
31794
31876
|
);
|
|
@@ -31809,7 +31891,7 @@ function handleSideStyle(side, index, total) {
|
|
|
31809
31891
|
|
|
31810
31892
|
// src/workflow/components/NodeResizer/NodeResizer.tsx
|
|
31811
31893
|
var import_react167 = require("react");
|
|
31812
|
-
var
|
|
31894
|
+
var import_jsx_runtime145 = require("react/jsx-runtime");
|
|
31813
31895
|
function NodeResizer({
|
|
31814
31896
|
isVisible,
|
|
31815
31897
|
minWidth = 80,
|
|
@@ -31928,7 +32010,7 @@ function NodeResizer({
|
|
|
31928
32010
|
return { ...base, top: "100%", left: "100%" };
|
|
31929
32011
|
}
|
|
31930
32012
|
};
|
|
31931
|
-
return /* @__PURE__ */ (0,
|
|
32013
|
+
return /* @__PURE__ */ (0, import_jsx_runtime145.jsx)("div", { className: cn("ods-node-resizer"), "data-flow-no-drag": "true", children: ["nw", "ne", "sw", "se"].map((corner) => /* @__PURE__ */ (0, import_jsx_runtime145.jsx)(
|
|
31932
32014
|
"div",
|
|
31933
32015
|
{
|
|
31934
32016
|
style: handleStyle(corner),
|
|
@@ -31955,7 +32037,7 @@ function cursorFor(corner) {
|
|
|
31955
32037
|
// src/workflow/components/kinds/BaseNode.tsx
|
|
31956
32038
|
var import_icons49 = require("@octaviaflow/icons");
|
|
31957
32039
|
var import_react168 = require("react");
|
|
31958
|
-
var
|
|
32040
|
+
var import_jsx_runtime146 = require("react/jsx-runtime");
|
|
31959
32041
|
function BaseNode({
|
|
31960
32042
|
kind,
|
|
31961
32043
|
kindIcon,
|
|
@@ -31974,7 +32056,7 @@ function BaseNode({
|
|
|
31974
32056
|
const ctx = (0, import_react168.useContext)(FlowNodeContext);
|
|
31975
32057
|
const bridge = (0, import_react168.useContext)(FlowNodeBridgeContext);
|
|
31976
32058
|
const deleteHandler = onDelete === false ? void 0 : onDelete ?? (ctx && bridge ? () => bridge.deleteNode(ctx.id) : void 0);
|
|
31977
|
-
return /* @__PURE__ */ (0,
|
|
32059
|
+
return /* @__PURE__ */ (0, import_jsx_runtime146.jsxs)(
|
|
31978
32060
|
"div",
|
|
31979
32061
|
{
|
|
31980
32062
|
className: cn(
|
|
@@ -31984,31 +32066,31 @@ function BaseNode({
|
|
|
31984
32066
|
className
|
|
31985
32067
|
),
|
|
31986
32068
|
children: [
|
|
31987
|
-
/* @__PURE__ */ (0,
|
|
31988
|
-
kindIcon && /* @__PURE__ */ (0,
|
|
31989
|
-
/* @__PURE__ */ (0,
|
|
32069
|
+
/* @__PURE__ */ (0, import_jsx_runtime146.jsxs)("div", { className: "ods-flow-base-node__pill", children: [
|
|
32070
|
+
kindIcon && /* @__PURE__ */ (0, import_jsx_runtime146.jsx)("span", { className: "ods-flow-base-node__pill-icon", "aria-hidden": "true", children: kindIcon }),
|
|
32071
|
+
/* @__PURE__ */ (0, import_jsx_runtime146.jsx)("span", { className: "ods-flow-base-node__pill-label", children: kind })
|
|
31990
32072
|
] }),
|
|
31991
|
-
status && status !== "idle" && /* @__PURE__ */ (0,
|
|
32073
|
+
status && status !== "idle" && /* @__PURE__ */ (0, import_jsx_runtime146.jsx)(
|
|
31992
32074
|
"span",
|
|
31993
32075
|
{
|
|
31994
32076
|
className: cn("ods-flow-base-node__status", `ods-flow-base-node__status--${status}`),
|
|
31995
32077
|
"aria-hidden": "true"
|
|
31996
32078
|
}
|
|
31997
32079
|
),
|
|
31998
|
-
/* @__PURE__ */ (0,
|
|
31999
|
-
/* @__PURE__ */ (0,
|
|
32000
|
-
/* @__PURE__ */ (0,
|
|
32001
|
-
/* @__PURE__ */ (0,
|
|
32002
|
-
/* @__PURE__ */ (0,
|
|
32003
|
-
(chip !== void 0 || description !== void 0 || valueChip !== void 0) && /* @__PURE__ */ (0,
|
|
32004
|
-
chip !== void 0 && /* @__PURE__ */ (0,
|
|
32005
|
-
description !== void 0 && /* @__PURE__ */ (0,
|
|
32006
|
-
valueChip !== void 0 && /* @__PURE__ */ (0,
|
|
32080
|
+
/* @__PURE__ */ (0, import_jsx_runtime146.jsxs)("div", { className: "ods-flow-base-node__body", children: [
|
|
32081
|
+
/* @__PURE__ */ (0, import_jsx_runtime146.jsxs)("div", { className: "ods-flow-base-node__content", children: [
|
|
32082
|
+
/* @__PURE__ */ (0, import_jsx_runtime146.jsx)("div", { className: "ods-flow-base-node__bubble", "aria-hidden": "true", children: icon }),
|
|
32083
|
+
/* @__PURE__ */ (0, import_jsx_runtime146.jsxs)("div", { className: "ods-flow-base-node__content-text", children: [
|
|
32084
|
+
/* @__PURE__ */ (0, import_jsx_runtime146.jsx)("div", { className: "ods-flow-base-node__content-title", children: title }),
|
|
32085
|
+
(chip !== void 0 || description !== void 0 || valueChip !== void 0) && /* @__PURE__ */ (0, import_jsx_runtime146.jsxs)("div", { className: "ods-flow-base-node__content-info", children: [
|
|
32086
|
+
chip !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime146.jsx)("span", { className: "ods-flow-base-node__chip", children: chip }),
|
|
32087
|
+
description !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime146.jsx)("span", { className: "ods-flow-base-node__description", children: description }),
|
|
32088
|
+
valueChip !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime146.jsx)("span", { className: "ods-flow-base-node__value-chip", children: valueChip })
|
|
32007
32089
|
] })
|
|
32008
32090
|
] })
|
|
32009
32091
|
] }),
|
|
32010
|
-
footer && /* @__PURE__ */ (0,
|
|
32011
|
-
deleteHandler && /* @__PURE__ */ (0,
|
|
32092
|
+
footer && /* @__PURE__ */ (0, import_jsx_runtime146.jsx)("div", { className: "ods-flow-base-node__footer", children: footer }),
|
|
32093
|
+
deleteHandler && /* @__PURE__ */ (0, import_jsx_runtime146.jsx)(
|
|
32012
32094
|
"button",
|
|
32013
32095
|
{
|
|
32014
32096
|
type: "button",
|
|
@@ -32020,7 +32102,7 @@ function BaseNode({
|
|
|
32020
32102
|
"aria-label": "Delete node",
|
|
32021
32103
|
"data-flow-no-drag": "true",
|
|
32022
32104
|
title: "Delete node",
|
|
32023
|
-
children: /* @__PURE__ */ (0,
|
|
32105
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime146.jsx)(import_icons49.TrashCanIcon, { size: 16, "aria-hidden": true })
|
|
32024
32106
|
}
|
|
32025
32107
|
)
|
|
32026
32108
|
] }),
|
|
@@ -32031,12 +32113,12 @@ function BaseNode({
|
|
|
32031
32113
|
}
|
|
32032
32114
|
|
|
32033
32115
|
// src/workflow/components/kinds/index.tsx
|
|
32034
|
-
var
|
|
32116
|
+
var import_jsx_runtime147 = require("react/jsx-runtime");
|
|
32035
32117
|
var ActionNode = ({
|
|
32036
32118
|
node
|
|
32037
32119
|
}) => {
|
|
32038
32120
|
const d = node.data ?? {};
|
|
32039
|
-
return /* @__PURE__ */ (0,
|
|
32121
|
+
return /* @__PURE__ */ (0, import_jsx_runtime147.jsxs)(
|
|
32040
32122
|
BaseNode,
|
|
32041
32123
|
{
|
|
32042
32124
|
kind: d.kind ?? "ACTION",
|
|
@@ -32048,8 +32130,8 @@ var ActionNode = ({
|
|
|
32048
32130
|
status: d.status,
|
|
32049
32131
|
accent: "green",
|
|
32050
32132
|
children: [
|
|
32051
|
-
/* @__PURE__ */ (0,
|
|
32052
|
-
/* @__PURE__ */ (0,
|
|
32133
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "target", position: "top" }),
|
|
32134
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "source", position: "bottom" })
|
|
32053
32135
|
]
|
|
32054
32136
|
}
|
|
32055
32137
|
);
|
|
@@ -32058,7 +32140,7 @@ var TriggerNode = ({
|
|
|
32058
32140
|
node
|
|
32059
32141
|
}) => {
|
|
32060
32142
|
const d = node.data ?? {};
|
|
32061
|
-
return /* @__PURE__ */ (0,
|
|
32143
|
+
return /* @__PURE__ */ (0, import_jsx_runtime147.jsx)(
|
|
32062
32144
|
BaseNode,
|
|
32063
32145
|
{
|
|
32064
32146
|
kind: d.kind ?? "TRIGGER",
|
|
@@ -32069,7 +32151,7 @@ var TriggerNode = ({
|
|
|
32069
32151
|
valueChip: d.valueChip,
|
|
32070
32152
|
status: d.status,
|
|
32071
32153
|
accent: "green",
|
|
32072
|
-
children: /* @__PURE__ */ (0,
|
|
32154
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "source", position: "bottom" })
|
|
32073
32155
|
}
|
|
32074
32156
|
);
|
|
32075
32157
|
};
|
|
@@ -32081,7 +32163,7 @@ var ConditionNode = ({
|
|
|
32081
32163
|
{ id: "true", label: "true" },
|
|
32082
32164
|
{ id: "false", label: "false" }
|
|
32083
32165
|
];
|
|
32084
|
-
return /* @__PURE__ */ (0,
|
|
32166
|
+
return /* @__PURE__ */ (0, import_jsx_runtime147.jsxs)(
|
|
32085
32167
|
BaseNode,
|
|
32086
32168
|
{
|
|
32087
32169
|
kind: d.kind ?? "CONDITION",
|
|
@@ -32093,8 +32175,8 @@ var ConditionNode = ({
|
|
|
32093
32175
|
status: d.status,
|
|
32094
32176
|
accent: "amber",
|
|
32095
32177
|
children: [
|
|
32096
|
-
/* @__PURE__ */ (0,
|
|
32097
|
-
branches.map((b, i) => /* @__PURE__ */ (0,
|
|
32178
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "target", position: "top" }),
|
|
32179
|
+
branches.map((b, i) => /* @__PURE__ */ (0, import_jsx_runtime147.jsx)(
|
|
32098
32180
|
Handle,
|
|
32099
32181
|
{
|
|
32100
32182
|
type: "source",
|
|
@@ -32122,7 +32204,7 @@ var GroupNode = ({
|
|
|
32122
32204
|
e.stopPropagation();
|
|
32123
32205
|
bridge.toggleNodeCollapse(node.id);
|
|
32124
32206
|
};
|
|
32125
|
-
return /* @__PURE__ */ (0,
|
|
32207
|
+
return /* @__PURE__ */ (0, import_jsx_runtime147.jsxs)(
|
|
32126
32208
|
"div",
|
|
32127
32209
|
{
|
|
32128
32210
|
className: "ods-flow-group",
|
|
@@ -32133,9 +32215,9 @@ var GroupNode = ({
|
|
|
32133
32215
|
height: collapsed ? 36 : node.height ?? 200
|
|
32134
32216
|
},
|
|
32135
32217
|
children: [
|
|
32136
|
-
!collapsed && /* @__PURE__ */ (0,
|
|
32137
|
-
/* @__PURE__ */ (0,
|
|
32138
|
-
/* @__PURE__ */ (0,
|
|
32218
|
+
!collapsed && /* @__PURE__ */ (0, import_jsx_runtime147.jsx)(NodeResizer, { minWidth: 240, minHeight: 120 }),
|
|
32219
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsxs)("div", { className: "ods-flow-group__header", "data-flow-no-drag": "false", children: [
|
|
32220
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(
|
|
32139
32221
|
"button",
|
|
32140
32222
|
{
|
|
32141
32223
|
type: "button",
|
|
@@ -32148,16 +32230,16 @@ var GroupNode = ({
|
|
|
32148
32230
|
children: collapsed ? "\u25B8" : "\u25BE"
|
|
32149
32231
|
}
|
|
32150
32232
|
),
|
|
32151
|
-
/* @__PURE__ */ (0,
|
|
32152
|
-
d.subtitle && /* @__PURE__ */ (0,
|
|
32153
|
-
disabled && /* @__PURE__ */ (0,
|
|
32154
|
-
collapsed && hiddenCount !== void 0 && hiddenCount > 0 && /* @__PURE__ */ (0,
|
|
32233
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)("span", { className: "ods-flow-group__title", children: d.title ?? "Group" }),
|
|
32234
|
+
d.subtitle && /* @__PURE__ */ (0, import_jsx_runtime147.jsx)("span", { className: "ods-flow-group__subtitle", children: d.subtitle }),
|
|
32235
|
+
disabled && /* @__PURE__ */ (0, import_jsx_runtime147.jsx)("span", { className: "ods-flow-group__disabled-badge", "aria-label": "Disabled subflow", children: "Disabled" }),
|
|
32236
|
+
collapsed && hiddenCount !== void 0 && hiddenCount > 0 && /* @__PURE__ */ (0, import_jsx_runtime147.jsxs)("span", { className: "ods-flow-group__count", "aria-label": `${hiddenCount} hidden steps`, children: [
|
|
32155
32237
|
hiddenCount,
|
|
32156
32238
|
" steps"
|
|
32157
32239
|
] })
|
|
32158
32240
|
] }),
|
|
32159
|
-
/* @__PURE__ */ (0,
|
|
32160
|
-
/* @__PURE__ */ (0,
|
|
32241
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "target", position: "top", id: "__group_in" }),
|
|
32242
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "source", position: "bottom", id: "__group_out" })
|
|
32161
32243
|
]
|
|
32162
32244
|
}
|
|
32163
32245
|
);
|
|
@@ -32170,7 +32252,7 @@ var ForEachNode = ({
|
|
|
32170
32252
|
{ id: "each", label: "Each" },
|
|
32171
32253
|
{ id: "done", label: "Done" }
|
|
32172
32254
|
];
|
|
32173
|
-
return /* @__PURE__ */ (0,
|
|
32255
|
+
return /* @__PURE__ */ (0, import_jsx_runtime147.jsxs)(
|
|
32174
32256
|
BaseNode,
|
|
32175
32257
|
{
|
|
32176
32258
|
kind: d.kind ?? "FOR EACH",
|
|
@@ -32182,8 +32264,8 @@ var ForEachNode = ({
|
|
|
32182
32264
|
status: d.status,
|
|
32183
32265
|
accent: "amber",
|
|
32184
32266
|
children: [
|
|
32185
|
-
/* @__PURE__ */ (0,
|
|
32186
|
-
branches.map((b, i) => /* @__PURE__ */ (0,
|
|
32267
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "target", position: "top" }),
|
|
32268
|
+
branches.map((b, i) => /* @__PURE__ */ (0, import_jsx_runtime147.jsx)(
|
|
32187
32269
|
Handle,
|
|
32188
32270
|
{
|
|
32189
32271
|
type: "source",
|
|
@@ -32203,7 +32285,7 @@ var OutputNode = ({
|
|
|
32203
32285
|
node
|
|
32204
32286
|
}) => {
|
|
32205
32287
|
const d = node.data ?? {};
|
|
32206
|
-
return /* @__PURE__ */ (0,
|
|
32288
|
+
return /* @__PURE__ */ (0, import_jsx_runtime147.jsx)(
|
|
32207
32289
|
BaseNode,
|
|
32208
32290
|
{
|
|
32209
32291
|
kind: d.kind ?? "OUTPUT",
|
|
@@ -32213,7 +32295,7 @@ var OutputNode = ({
|
|
|
32213
32295
|
description: d.description ?? d.subtitle,
|
|
32214
32296
|
status: d.status,
|
|
32215
32297
|
accent: "green",
|
|
32216
|
-
children: /* @__PURE__ */ (0,
|
|
32298
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "target", position: "top" })
|
|
32217
32299
|
}
|
|
32218
32300
|
);
|
|
32219
32301
|
};
|
|
@@ -32221,7 +32303,7 @@ var ErrorNode = ({
|
|
|
32221
32303
|
node
|
|
32222
32304
|
}) => {
|
|
32223
32305
|
const d = node.data ?? {};
|
|
32224
|
-
return /* @__PURE__ */ (0,
|
|
32306
|
+
return /* @__PURE__ */ (0, import_jsx_runtime147.jsxs)(
|
|
32225
32307
|
BaseNode,
|
|
32226
32308
|
{
|
|
32227
32309
|
kind: d.kind ?? "ERROR",
|
|
@@ -32232,8 +32314,8 @@ var ErrorNode = ({
|
|
|
32232
32314
|
status: d.status ?? "error",
|
|
32233
32315
|
accent: "red",
|
|
32234
32316
|
children: [
|
|
32235
|
-
/* @__PURE__ */ (0,
|
|
32236
|
-
/* @__PURE__ */ (0,
|
|
32317
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "target", position: "top" }),
|
|
32318
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "source", position: "bottom" })
|
|
32237
32319
|
]
|
|
32238
32320
|
}
|
|
32239
32321
|
);
|
|
@@ -32244,7 +32326,7 @@ var WaitNode = ({
|
|
|
32244
32326
|
const d = node.data ?? {};
|
|
32245
32327
|
const waitMs = d.waitMs;
|
|
32246
32328
|
const durationChip = waitMs ? `${Math.round(waitMs / 100) / 10}s` : void 0;
|
|
32247
|
-
return /* @__PURE__ */ (0,
|
|
32329
|
+
return /* @__PURE__ */ (0, import_jsx_runtime147.jsxs)(
|
|
32248
32330
|
BaseNode,
|
|
32249
32331
|
{
|
|
32250
32332
|
kind: d.kind ?? "WAIT",
|
|
@@ -32255,8 +32337,8 @@ var WaitNode = ({
|
|
|
32255
32337
|
status: d.status,
|
|
32256
32338
|
accent: "violet",
|
|
32257
32339
|
children: [
|
|
32258
|
-
/* @__PURE__ */ (0,
|
|
32259
|
-
/* @__PURE__ */ (0,
|
|
32340
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "target", position: "top" }),
|
|
32341
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "source", position: "bottom" })
|
|
32260
32342
|
]
|
|
32261
32343
|
}
|
|
32262
32344
|
);
|
|
@@ -32269,7 +32351,7 @@ var ParallelNode = ({
|
|
|
32269
32351
|
{ id: "a", label: "a" },
|
|
32270
32352
|
{ id: "b", label: "b" }
|
|
32271
32353
|
];
|
|
32272
|
-
return /* @__PURE__ */ (0,
|
|
32354
|
+
return /* @__PURE__ */ (0, import_jsx_runtime147.jsxs)(
|
|
32273
32355
|
BaseNode,
|
|
32274
32356
|
{
|
|
32275
32357
|
kind: d.kind ?? "PARALLEL",
|
|
@@ -32280,8 +32362,8 @@ var ParallelNode = ({
|
|
|
32280
32362
|
status: d.status,
|
|
32281
32363
|
accent: "blue",
|
|
32282
32364
|
children: [
|
|
32283
|
-
/* @__PURE__ */ (0,
|
|
32284
|
-
branches.map((b, i) => /* @__PURE__ */ (0,
|
|
32365
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "target", position: "top" }),
|
|
32366
|
+
branches.map((b, i) => /* @__PURE__ */ (0, import_jsx_runtime147.jsx)(
|
|
32285
32367
|
Handle,
|
|
32286
32368
|
{
|
|
32287
32369
|
type: "source",
|
|
@@ -32301,7 +32383,7 @@ var StickyNode = ({
|
|
|
32301
32383
|
node
|
|
32302
32384
|
}) => {
|
|
32303
32385
|
const d = node.data ?? {};
|
|
32304
|
-
return /* @__PURE__ */ (0,
|
|
32386
|
+
return /* @__PURE__ */ (0, import_jsx_runtime147.jsxs)(
|
|
32305
32387
|
"div",
|
|
32306
32388
|
{
|
|
32307
32389
|
className: "ods-flow-sticky",
|
|
@@ -32310,8 +32392,8 @@ var StickyNode = ({
|
|
|
32310
32392
|
minHeight: node.height ?? 120
|
|
32311
32393
|
},
|
|
32312
32394
|
children: [
|
|
32313
|
-
d.title && /* @__PURE__ */ (0,
|
|
32314
|
-
d.description && /* @__PURE__ */ (0,
|
|
32395
|
+
d.title && /* @__PURE__ */ (0, import_jsx_runtime147.jsx)("div", { className: "ods-flow-sticky__title", children: d.title }),
|
|
32396
|
+
d.description && /* @__PURE__ */ (0, import_jsx_runtime147.jsx)("div", { className: "ods-flow-sticky__body", children: d.description })
|
|
32315
32397
|
]
|
|
32316
32398
|
}
|
|
32317
32399
|
);
|
|
@@ -32320,7 +32402,7 @@ var WebhookNode = ({
|
|
|
32320
32402
|
node
|
|
32321
32403
|
}) => {
|
|
32322
32404
|
const d = node.data ?? {};
|
|
32323
|
-
return /* @__PURE__ */ (0,
|
|
32405
|
+
return /* @__PURE__ */ (0, import_jsx_runtime147.jsx)(
|
|
32324
32406
|
BaseNode,
|
|
32325
32407
|
{
|
|
32326
32408
|
kind: d.kind ?? "WEBHOOK",
|
|
@@ -32331,7 +32413,7 @@ var WebhookNode = ({
|
|
|
32331
32413
|
valueChip: d.valueChip,
|
|
32332
32414
|
status: d.status,
|
|
32333
32415
|
accent: "blue",
|
|
32334
|
-
children: /* @__PURE__ */ (0,
|
|
32416
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "source", position: "bottom" })
|
|
32335
32417
|
}
|
|
32336
32418
|
);
|
|
32337
32419
|
};
|
|
@@ -32339,7 +32421,7 @@ var HttpRequestNode = ({
|
|
|
32339
32421
|
node
|
|
32340
32422
|
}) => {
|
|
32341
32423
|
const d = node.data ?? {};
|
|
32342
|
-
return /* @__PURE__ */ (0,
|
|
32424
|
+
return /* @__PURE__ */ (0, import_jsx_runtime147.jsxs)(
|
|
32343
32425
|
BaseNode,
|
|
32344
32426
|
{
|
|
32345
32427
|
kind: d.kind ?? "HTTP",
|
|
@@ -32351,8 +32433,8 @@ var HttpRequestNode = ({
|
|
|
32351
32433
|
status: d.status,
|
|
32352
32434
|
accent: "blue",
|
|
32353
32435
|
children: [
|
|
32354
|
-
/* @__PURE__ */ (0,
|
|
32355
|
-
/* @__PURE__ */ (0,
|
|
32436
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "target", position: "top" }),
|
|
32437
|
+
/* @__PURE__ */ (0, import_jsx_runtime147.jsx)(Handle, { type: "source", position: "bottom" })
|
|
32356
32438
|
]
|
|
32357
32439
|
}
|
|
32358
32440
|
);
|
|
@@ -32373,7 +32455,7 @@ var DEFAULT_NODE_KINDS = {
|
|
|
32373
32455
|
};
|
|
32374
32456
|
|
|
32375
32457
|
// src/workflow/components/FlowCanvas/FlowCanvas.tsx
|
|
32376
|
-
var
|
|
32458
|
+
var import_jsx_runtime148 = require("react/jsx-runtime");
|
|
32377
32459
|
var DEFAULT_VIEWPORT2 = { x: 0, y: 0, zoom: 1 };
|
|
32378
32460
|
function FlowCanvas2(props) {
|
|
32379
32461
|
const viewportPropProvided = props.viewport !== void 0 || props.defaultViewport !== void 0;
|
|
@@ -33281,7 +33363,7 @@ function FlowCanvas2(props) {
|
|
|
33281
33363
|
containers.sort((a, b) => depth(a) - depth(b));
|
|
33282
33364
|
return [...containers, ...others];
|
|
33283
33365
|
}, [visibleNodes]);
|
|
33284
|
-
return /* @__PURE__ */ (0,
|
|
33366
|
+
return /* @__PURE__ */ (0, import_jsx_runtime148.jsx)(FlowStoreContext.Provider, { value: store, children: /* @__PURE__ */ (0, import_jsx_runtime148.jsx)(FlowInstanceContext.Provider, { value: instance, children: /* @__PURE__ */ (0, import_jsx_runtime148.jsx)(HandleRegistryContext.Provider, { value: handleRegistry, children: /* @__PURE__ */ (0, import_jsx_runtime148.jsx)(FlowDispatchContext.Provider, { value: dispatch, children: /* @__PURE__ */ (0, import_jsx_runtime148.jsx)(FlowNodeBridgeContext.Provider, { value: bridge, children: /* @__PURE__ */ (0, import_jsx_runtime148.jsxs)(
|
|
33285
33367
|
"div",
|
|
33286
33368
|
{
|
|
33287
33369
|
ref: containerRef,
|
|
@@ -33326,7 +33408,7 @@ function FlowCanvas2(props) {
|
|
|
33326
33408
|
},
|
|
33327
33409
|
"data-empty": isEmpty ? "true" : void 0,
|
|
33328
33410
|
children: [
|
|
33329
|
-
background !== "none" && /* @__PURE__ */ (0,
|
|
33411
|
+
background !== "none" && /* @__PURE__ */ (0, import_jsx_runtime148.jsx)(
|
|
33330
33412
|
"div",
|
|
33331
33413
|
{
|
|
33332
33414
|
className: cn(
|
|
@@ -33340,7 +33422,7 @@ function FlowCanvas2(props) {
|
|
|
33340
33422
|
}
|
|
33341
33423
|
}
|
|
33342
33424
|
),
|
|
33343
|
-
/* @__PURE__ */ (0,
|
|
33425
|
+
/* @__PURE__ */ (0, import_jsx_runtime148.jsxs)(
|
|
33344
33426
|
"div",
|
|
33345
33427
|
{
|
|
33346
33428
|
className: "ods-flow-canvas-v2__viewport",
|
|
@@ -33351,7 +33433,7 @@ function FlowCanvas2(props) {
|
|
|
33351
33433
|
transformOrigin: "0 0"
|
|
33352
33434
|
},
|
|
33353
33435
|
children: [
|
|
33354
|
-
/* @__PURE__ */ (0,
|
|
33436
|
+
/* @__PURE__ */ (0, import_jsx_runtime148.jsx)(
|
|
33355
33437
|
EdgesLayer,
|
|
33356
33438
|
{
|
|
33357
33439
|
edges: visibleEdges,
|
|
@@ -33366,7 +33448,7 @@ function FlowCanvas2(props) {
|
|
|
33366
33448
|
orderedNodes.map((node) => {
|
|
33367
33449
|
const Kind = kinds[node.type] ?? kinds.action;
|
|
33368
33450
|
if (!Kind) return null;
|
|
33369
|
-
return /* @__PURE__ */ (0,
|
|
33451
|
+
return /* @__PURE__ */ (0, import_jsx_runtime148.jsx)(
|
|
33370
33452
|
FlowNode3,
|
|
33371
33453
|
{
|
|
33372
33454
|
node,
|
|
@@ -33381,7 +33463,7 @@ function FlowCanvas2(props) {
|
|
|
33381
33463
|
]
|
|
33382
33464
|
}
|
|
33383
33465
|
),
|
|
33384
|
-
isEmpty && emptyState && /* @__PURE__ */ (0,
|
|
33466
|
+
isEmpty && emptyState && /* @__PURE__ */ (0, import_jsx_runtime148.jsx)("div", { className: "ods-flow-canvas-v2__empty", children: emptyState }),
|
|
33385
33467
|
children
|
|
33386
33468
|
]
|
|
33387
33469
|
}
|
|
@@ -33461,7 +33543,7 @@ var EdgesLayer = (0, import_react169.memo)(function EdgesLayer2({
|
|
|
33461
33543
|
ghost,
|
|
33462
33544
|
handleVersion: _handleVersion
|
|
33463
33545
|
}) {
|
|
33464
|
-
return /* @__PURE__ */ (0,
|
|
33546
|
+
return /* @__PURE__ */ (0, import_jsx_runtime148.jsxs)(
|
|
33465
33547
|
"svg",
|
|
33466
33548
|
{
|
|
33467
33549
|
className: "ods-flow-canvas-v2__edges",
|
|
@@ -33469,7 +33551,7 @@ var EdgesLayer = (0, import_react169.memo)(function EdgesLayer2({
|
|
|
33469
33551
|
width: "100%",
|
|
33470
33552
|
height: "100%",
|
|
33471
33553
|
children: [
|
|
33472
|
-
/* @__PURE__ */ (0,
|
|
33554
|
+
/* @__PURE__ */ (0, import_jsx_runtime148.jsx)("g", { style: { pointerEvents: "auto" }, children: edges.map((edge) => /* @__PURE__ */ (0, import_jsx_runtime148.jsx)(
|
|
33473
33555
|
FlowEdge2,
|
|
33474
33556
|
{
|
|
33475
33557
|
edge,
|
|
@@ -33481,7 +33563,7 @@ var EdgesLayer = (0, import_react169.memo)(function EdgesLayer2({
|
|
|
33481
33563
|
},
|
|
33482
33564
|
edge.id
|
|
33483
33565
|
)) }),
|
|
33484
|
-
ghost && /* @__PURE__ */ (0,
|
|
33566
|
+
ghost && /* @__PURE__ */ (0, import_jsx_runtime148.jsx)(
|
|
33485
33567
|
"path",
|
|
33486
33568
|
{
|
|
33487
33569
|
d: `M ${ghost.start.x} ${ghost.start.y} L ${ghost.end.x} ${ghost.end.y}`,
|
|
@@ -33497,7 +33579,7 @@ var EdgesLayer = (0, import_react169.memo)(function EdgesLayer2({
|
|
|
33497
33579
|
});
|
|
33498
33580
|
|
|
33499
33581
|
// src/components/WorkflowEditor/WorkflowEditor.tsx
|
|
33500
|
-
var
|
|
33582
|
+
var import_jsx_runtime149 = require("react/jsx-runtime");
|
|
33501
33583
|
var NODE_KIND_MAP = {
|
|
33502
33584
|
trigger: "trigger",
|
|
33503
33585
|
action: "action",
|
|
@@ -33542,7 +33624,7 @@ function WorkflowEditor({
|
|
|
33542
33624
|
drawer,
|
|
33543
33625
|
console: consoleSlot,
|
|
33544
33626
|
minimap,
|
|
33545
|
-
emptyState = /* @__PURE__ */ (0,
|
|
33627
|
+
emptyState = /* @__PURE__ */ (0, import_jsx_runtime149.jsx)(DefaultEmptyState, {}),
|
|
33546
33628
|
children,
|
|
33547
33629
|
background = "dots",
|
|
33548
33630
|
snapToGrid = true,
|
|
@@ -33698,8 +33780,8 @@ function WorkflowEditor({
|
|
|
33698
33780
|
wf.setViewport({ x: cw / 2 - cx * zoom, y: ch / 2 - cy * zoom, zoom });
|
|
33699
33781
|
}, [workflow.canvas.nodes, canvasSize, wf]);
|
|
33700
33782
|
const defaultToolbar = (0, import_react170.useMemo)(
|
|
33701
|
-
() => /* @__PURE__ */ (0,
|
|
33702
|
-
onSave && /* @__PURE__ */ (0,
|
|
33783
|
+
() => /* @__PURE__ */ (0, import_jsx_runtime149.jsxs)(FlowToolbar, { placement: "left", children: [
|
|
33784
|
+
onSave && /* @__PURE__ */ (0, import_jsx_runtime149.jsx)(
|
|
33703
33785
|
FlowToolbarButton,
|
|
33704
33786
|
{
|
|
33705
33787
|
icon: FlowToolbarIcons.save,
|
|
@@ -33708,7 +33790,7 @@ function WorkflowEditor({
|
|
|
33708
33790
|
onClick: () => onSave(workflow)
|
|
33709
33791
|
}
|
|
33710
33792
|
),
|
|
33711
|
-
onRun && /* @__PURE__ */ (0,
|
|
33793
|
+
onRun && /* @__PURE__ */ (0, import_jsx_runtime149.jsx)(
|
|
33712
33794
|
FlowToolbarButton,
|
|
33713
33795
|
{
|
|
33714
33796
|
icon: isExecuting ? FlowToolbarIcons.stop : FlowToolbarIcons.run,
|
|
@@ -33719,7 +33801,7 @@ function WorkflowEditor({
|
|
|
33719
33801
|
onClick: isExecuting ? onStop : onRun
|
|
33720
33802
|
}
|
|
33721
33803
|
),
|
|
33722
|
-
/* @__PURE__ */ (0,
|
|
33804
|
+
/* @__PURE__ */ (0, import_jsx_runtime149.jsx)(
|
|
33723
33805
|
FlowToolbarButton,
|
|
33724
33806
|
{
|
|
33725
33807
|
icon: isLockMode ? FlowToolbarIcons.lock : FlowToolbarIcons.unlock,
|
|
@@ -33729,7 +33811,7 @@ function WorkflowEditor({
|
|
|
33729
33811
|
onClick: toggleLock
|
|
33730
33812
|
}
|
|
33731
33813
|
),
|
|
33732
|
-
/* @__PURE__ */ (0,
|
|
33814
|
+
/* @__PURE__ */ (0, import_jsx_runtime149.jsx)(
|
|
33733
33815
|
FlowToolbarButton,
|
|
33734
33816
|
{
|
|
33735
33817
|
icon: FlowToolbarIcons.reset,
|
|
@@ -33737,7 +33819,7 @@ function WorkflowEditor({
|
|
|
33737
33819
|
onClick: handleReset
|
|
33738
33820
|
}
|
|
33739
33821
|
),
|
|
33740
|
-
drawer && /* @__PURE__ */ (0,
|
|
33822
|
+
drawer && /* @__PURE__ */ (0, import_jsx_runtime149.jsx)(
|
|
33741
33823
|
FlowToolbarButton,
|
|
33742
33824
|
{
|
|
33743
33825
|
icon: isDrawerOpen ? FlowToolbarIcons.drawerClose : FlowToolbarIcons.drawerOpen,
|
|
@@ -33746,8 +33828,8 @@ function WorkflowEditor({
|
|
|
33746
33828
|
onClick: toggleDrawer
|
|
33747
33829
|
}
|
|
33748
33830
|
),
|
|
33749
|
-
/* @__PURE__ */ (0,
|
|
33750
|
-
onSettings && /* @__PURE__ */ (0,
|
|
33831
|
+
/* @__PURE__ */ (0, import_jsx_runtime149.jsx)(FlowToolbarDivider, {}),
|
|
33832
|
+
onSettings && /* @__PURE__ */ (0, import_jsx_runtime149.jsx)(
|
|
33751
33833
|
FlowToolbarButton,
|
|
33752
33834
|
{
|
|
33753
33835
|
icon: FlowToolbarIcons.settings,
|
|
@@ -33755,7 +33837,7 @@ function WorkflowEditor({
|
|
|
33755
33837
|
onClick: onSettings
|
|
33756
33838
|
}
|
|
33757
33839
|
),
|
|
33758
|
-
/* @__PURE__ */ (0,
|
|
33840
|
+
/* @__PURE__ */ (0, import_jsx_runtime149.jsx)(
|
|
33759
33841
|
FlowToolbarButton,
|
|
33760
33842
|
{
|
|
33761
33843
|
icon: FlowToolbarIcons.history,
|
|
@@ -33764,7 +33846,7 @@ function WorkflowEditor({
|
|
|
33764
33846
|
onClick: toggleHistory
|
|
33765
33847
|
}
|
|
33766
33848
|
),
|
|
33767
|
-
isDebugModeEnabled && /* @__PURE__ */ (0,
|
|
33849
|
+
isDebugModeEnabled && /* @__PURE__ */ (0, import_jsx_runtime149.jsx)(
|
|
33768
33850
|
FlowToolbarButton,
|
|
33769
33851
|
{
|
|
33770
33852
|
icon: FlowToolbarIcons.debug,
|
|
@@ -33773,8 +33855,8 @@ function WorkflowEditor({
|
|
|
33773
33855
|
onClick: toggleDebug
|
|
33774
33856
|
}
|
|
33775
33857
|
),
|
|
33776
|
-
/* @__PURE__ */ (0,
|
|
33777
|
-
/* @__PURE__ */ (0,
|
|
33858
|
+
/* @__PURE__ */ (0, import_jsx_runtime149.jsx)(FlowToolbarDivider, {}),
|
|
33859
|
+
/* @__PURE__ */ (0, import_jsx_runtime149.jsx)(
|
|
33778
33860
|
FlowToolbarButton,
|
|
33779
33861
|
{
|
|
33780
33862
|
icon: FlowToolbarIcons.undo,
|
|
@@ -33784,7 +33866,7 @@ function WorkflowEditor({
|
|
|
33784
33866
|
onClick: undo
|
|
33785
33867
|
}
|
|
33786
33868
|
),
|
|
33787
|
-
/* @__PURE__ */ (0,
|
|
33869
|
+
/* @__PURE__ */ (0, import_jsx_runtime149.jsx)(
|
|
33788
33870
|
FlowToolbarButton,
|
|
33789
33871
|
{
|
|
33790
33872
|
icon: FlowToolbarIcons.redo,
|
|
@@ -33794,8 +33876,8 @@ function WorkflowEditor({
|
|
|
33794
33876
|
onClick: redo
|
|
33795
33877
|
}
|
|
33796
33878
|
),
|
|
33797
|
-
/* @__PURE__ */ (0,
|
|
33798
|
-
/* @__PURE__ */ (0,
|
|
33879
|
+
/* @__PURE__ */ (0, import_jsx_runtime149.jsx)(FlowToolbarDivider, {}),
|
|
33880
|
+
/* @__PURE__ */ (0, import_jsx_runtime149.jsx)(
|
|
33799
33881
|
FlowToolbarZoom,
|
|
33800
33882
|
{
|
|
33801
33883
|
zoom: workflow.canvas.viewport.zoom,
|
|
@@ -33834,21 +33916,21 @@ function WorkflowEditor({
|
|
|
33834
33916
|
);
|
|
33835
33917
|
const resolvedToolbar = toolbar === "default" ? defaultToolbar : toolbar === null ? null : toolbar;
|
|
33836
33918
|
const isEmpty = workflow.canvas.nodes.length === 0 && workflow.canvas.edges.length === 0;
|
|
33837
|
-
return /* @__PURE__ */ (0,
|
|
33919
|
+
return /* @__PURE__ */ (0, import_jsx_runtime149.jsxs)(
|
|
33838
33920
|
"div",
|
|
33839
33921
|
{
|
|
33840
33922
|
className: cn("ods-workflow-editor", className),
|
|
33841
33923
|
style: { width, height, position: "relative", display: "flex", overflow: "hidden" },
|
|
33842
33924
|
children: [
|
|
33843
|
-
drawer && isDrawerOpen && /* @__PURE__ */ (0,
|
|
33844
|
-
/* @__PURE__ */ (0,
|
|
33925
|
+
drawer && isDrawerOpen && /* @__PURE__ */ (0, import_jsx_runtime149.jsx)("div", { className: "ods-workflow-editor__drawer", children: drawer }),
|
|
33926
|
+
/* @__PURE__ */ (0, import_jsx_runtime149.jsxs)(
|
|
33845
33927
|
"div",
|
|
33846
33928
|
{
|
|
33847
33929
|
ref: handleCanvasRef,
|
|
33848
33930
|
className: "ods-workflow-editor__canvas-wrapper",
|
|
33849
33931
|
style: { position: "relative", flex: 1, minWidth: 0 },
|
|
33850
33932
|
children: [
|
|
33851
|
-
/* @__PURE__ */ (0,
|
|
33933
|
+
/* @__PURE__ */ (0, import_jsx_runtime149.jsx)(
|
|
33852
33934
|
FlowCanvas2,
|
|
33853
33935
|
{
|
|
33854
33936
|
nodes: nextNodes,
|
|
@@ -33862,9 +33944,9 @@ function WorkflowEditor({
|
|
|
33862
33944
|
children: resolvedToolbar
|
|
33863
33945
|
}
|
|
33864
33946
|
),
|
|
33865
|
-
minimap && /* @__PURE__ */ (0,
|
|
33866
|
-
consoleSlot && /* @__PURE__ */ (0,
|
|
33867
|
-
isEmpty && emptyState && /* @__PURE__ */ (0,
|
|
33947
|
+
minimap && /* @__PURE__ */ (0, import_jsx_runtime149.jsx)("div", { className: "ods-workflow-editor__minimap", children: minimap }),
|
|
33948
|
+
consoleSlot && /* @__PURE__ */ (0, import_jsx_runtime149.jsx)("div", { className: "ods-workflow-editor__console", children: consoleSlot }),
|
|
33949
|
+
isEmpty && emptyState && /* @__PURE__ */ (0, import_jsx_runtime149.jsx)("div", { className: "ods-workflow-editor__empty", children: emptyState }),
|
|
33868
33950
|
children
|
|
33869
33951
|
]
|
|
33870
33952
|
}
|
|
@@ -33874,7 +33956,7 @@ function WorkflowEditor({
|
|
|
33874
33956
|
);
|
|
33875
33957
|
}
|
|
33876
33958
|
function DefaultEmptyState() {
|
|
33877
|
-
return /* @__PURE__ */ (0,
|
|
33959
|
+
return /* @__PURE__ */ (0, import_jsx_runtime149.jsxs)(
|
|
33878
33960
|
"div",
|
|
33879
33961
|
{
|
|
33880
33962
|
style: {
|
|
@@ -33889,14 +33971,14 @@ function DefaultEmptyState() {
|
|
|
33889
33971
|
pointerEvents: "none"
|
|
33890
33972
|
},
|
|
33891
33973
|
children: [
|
|
33892
|
-
/* @__PURE__ */ (0,
|
|
33974
|
+
/* @__PURE__ */ (0, import_jsx_runtime149.jsx)(
|
|
33893
33975
|
"div",
|
|
33894
33976
|
{
|
|
33895
33977
|
style: { fontSize: 14, fontWeight: 600, color: "var(--ods-text-primary)", marginBottom: 4 },
|
|
33896
33978
|
children: "Start with a trigger"
|
|
33897
33979
|
}
|
|
33898
33980
|
),
|
|
33899
|
-
/* @__PURE__ */ (0,
|
|
33981
|
+
/* @__PURE__ */ (0, import_jsx_runtime149.jsx)("div", { style: { fontSize: 12 }, children: "Drop an action here, or use the drawer to add your first node." })
|
|
33900
33982
|
]
|
|
33901
33983
|
}
|
|
33902
33984
|
);
|
|
@@ -33933,7 +34015,7 @@ function useWorkflowRuntime(startedAt, active) {
|
|
|
33933
34015
|
}
|
|
33934
34016
|
|
|
33935
34017
|
// src/components/WorkflowHeader/WorkflowHeader.tsx
|
|
33936
|
-
var
|
|
34018
|
+
var import_jsx_runtime150 = require("react/jsx-runtime");
|
|
33937
34019
|
function WorkflowHeader({
|
|
33938
34020
|
name,
|
|
33939
34021
|
statusTone,
|
|
@@ -33976,21 +34058,21 @@ function WorkflowHeader({
|
|
|
33976
34058
|
className
|
|
33977
34059
|
);
|
|
33978
34060
|
if (loading) {
|
|
33979
|
-
return /* @__PURE__ */ (0,
|
|
33980
|
-
/* @__PURE__ */ (0,
|
|
33981
|
-
/* @__PURE__ */ (0,
|
|
33982
|
-
/* @__PURE__ */ (0,
|
|
34061
|
+
return /* @__PURE__ */ (0, import_jsx_runtime150.jsxs)("header", { className: rootCls, "data-loading": "true", children: [
|
|
34062
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsxs)("div", { className: "ods-workflow-header__left", children: [
|
|
34063
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)(Skeleton, { variant: "text", width: "120px" }),
|
|
34064
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)(Skeleton, { variant: "text", width: "180px" })
|
|
33983
34065
|
] }),
|
|
33984
|
-
/* @__PURE__ */ (0,
|
|
33985
|
-
/* @__PURE__ */ (0,
|
|
33986
|
-
/* @__PURE__ */ (0,
|
|
34066
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsxs)("div", { className: "ods-workflow-header__right", children: [
|
|
34067
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)(Skeleton, { variant: "circular", width: "28px", height: "28px" }),
|
|
34068
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)(Skeleton, { variant: "circular", width: "28px", height: "28px" })
|
|
33987
34069
|
] })
|
|
33988
34070
|
] });
|
|
33989
34071
|
}
|
|
33990
34072
|
const envAccentStyle = environment?.accent ? { borderLeftColor: environment.accent } : void 0;
|
|
33991
|
-
return /* @__PURE__ */ (0,
|
|
33992
|
-
/* @__PURE__ */ (0,
|
|
33993
|
-
onBack && /* @__PURE__ */ (0,
|
|
34073
|
+
return /* @__PURE__ */ (0, import_jsx_runtime150.jsxs)("header", { className: rootCls, "data-running": isRunning ? "true" : void 0, children: [
|
|
34074
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsxs)("div", { className: "ods-workflow-header__left", children: [
|
|
34075
|
+
onBack && /* @__PURE__ */ (0, import_jsx_runtime150.jsxs)(
|
|
33994
34076
|
"button",
|
|
33995
34077
|
{
|
|
33996
34078
|
type: "button",
|
|
@@ -33998,13 +34080,13 @@ function WorkflowHeader({
|
|
|
33998
34080
|
onClick: onBack,
|
|
33999
34081
|
"aria-label": `Back to ${typeof parentLabel === "string" ? parentLabel : "previous"}`,
|
|
34000
34082
|
children: [
|
|
34001
|
-
/* @__PURE__ */ (0,
|
|
34002
|
-
/* @__PURE__ */ (0,
|
|
34003
|
-
/* @__PURE__ */ (0,
|
|
34083
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)(import_icons50.ChevronLeftIcon, { size: "sm" }),
|
|
34084
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)("span", { className: "ods-workflow-header__back-label", children: parentLabel }),
|
|
34085
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)("span", { className: "ods-workflow-header__back-separator", "aria-hidden": "true", children: "/" })
|
|
34004
34086
|
]
|
|
34005
34087
|
}
|
|
34006
34088
|
),
|
|
34007
|
-
/* @__PURE__ */ (0,
|
|
34089
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)(
|
|
34008
34090
|
"span",
|
|
34009
34091
|
{
|
|
34010
34092
|
className: cn(
|
|
@@ -34015,10 +34097,10 @@ function WorkflowHeader({
|
|
|
34015
34097
|
role: "img"
|
|
34016
34098
|
}
|
|
34017
34099
|
),
|
|
34018
|
-
/* @__PURE__ */ (0,
|
|
34019
|
-
saveIndicator && /* @__PURE__ */ (0,
|
|
34020
|
-
/* @__PURE__ */ (0,
|
|
34021
|
-
/* @__PURE__ */ (0,
|
|
34100
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)("h1", { className: "ods-workflow-header__title", title: typeof name === "string" ? name : void 0, children: name }),
|
|
34101
|
+
saveIndicator && /* @__PURE__ */ (0, import_jsx_runtime150.jsxs)(import_jsx_runtime150.Fragment, { children: [
|
|
34102
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)("span", { className: "ods-workflow-header__sep", "aria-hidden": "true" }),
|
|
34103
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)(
|
|
34022
34104
|
"span",
|
|
34023
34105
|
{
|
|
34024
34106
|
className: cn(
|
|
@@ -34034,11 +34116,11 @@ function WorkflowHeader({
|
|
|
34034
34116
|
] }),
|
|
34035
34117
|
leftSlot
|
|
34036
34118
|
] }),
|
|
34037
|
-
/* @__PURE__ */ (0,
|
|
34119
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsxs)("div", { className: "ods-workflow-header__right", children: [
|
|
34038
34120
|
rightSlot,
|
|
34039
34121
|
environment && // Consumer-driven env chip. Accent (left border colour) comes
|
|
34040
34122
|
// from the consumer — we don't bake in environment names.
|
|
34041
|
-
/* @__PURE__ */ (0,
|
|
34123
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)(
|
|
34042
34124
|
Chip,
|
|
34043
34125
|
{
|
|
34044
34126
|
size: "sm",
|
|
@@ -34054,72 +34136,72 @@ function WorkflowHeader({
|
|
|
34054
34136
|
children: environment.label
|
|
34055
34137
|
}
|
|
34056
34138
|
),
|
|
34057
|
-
onToggleConsole && (isRunning || consoleHasLogs) && /* @__PURE__ */ (0,
|
|
34139
|
+
onToggleConsole && (isRunning || consoleHasLogs) && /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(
|
|
34058
34140
|
Button,
|
|
34059
34141
|
{
|
|
34060
34142
|
variant: "ghost",
|
|
34061
34143
|
size: "sm",
|
|
34062
34144
|
pressed: !!isConsoleOpen,
|
|
34063
34145
|
"aria-label": isConsoleOpen ? "Hide execution console" : "Show execution console",
|
|
34064
|
-
leftIcon: /* @__PURE__ */ (0,
|
|
34146
|
+
leftIcon: /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(import_icons50.TerminalIcon, { size: "sm" }),
|
|
34065
34147
|
onClick: onToggleConsole,
|
|
34066
34148
|
children: "Console"
|
|
34067
34149
|
}
|
|
34068
34150
|
),
|
|
34069
|
-
(environment || onToggleConsole && (isRunning || consoleHasLogs)) && (isRunning || onRun || menuItems && menuItems.length > 0) && /* @__PURE__ */ (0,
|
|
34070
|
-
isRunning ? onStop && /* @__PURE__ */ (0,
|
|
34151
|
+
(environment || onToggleConsole && (isRunning || consoleHasLogs)) && (isRunning || onRun || menuItems && menuItems.length > 0) && /* @__PURE__ */ (0, import_jsx_runtime150.jsx)("span", { className: "ods-workflow-header__micro-divider", "aria-hidden": "true" }),
|
|
34152
|
+
isRunning ? onStop && /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(
|
|
34071
34153
|
Button,
|
|
34072
34154
|
{
|
|
34073
34155
|
variant: "ghost",
|
|
34074
34156
|
size: "sm",
|
|
34075
34157
|
"aria-label": runtime ? `Stop execution (running ${runtime})` : "Stop execution",
|
|
34076
|
-
leftIcon: /* @__PURE__ */ (0,
|
|
34158
|
+
leftIcon: /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(import_icons50.StopFilledAltIcon, { size: "sm", className: "ods-workflow-header__stop-glyph" }),
|
|
34077
34159
|
onClick: onStop,
|
|
34078
|
-
children: /* @__PURE__ */ (0,
|
|
34079
|
-
/* @__PURE__ */ (0,
|
|
34080
|
-
runtime && /* @__PURE__ */ (0,
|
|
34081
|
-
/* @__PURE__ */ (0,
|
|
34082
|
-
/* @__PURE__ */ (0,
|
|
34160
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime150.jsxs)("span", { className: "ods-workflow-header__stop-label", children: [
|
|
34161
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)("span", { children: "Stop" }),
|
|
34162
|
+
runtime && /* @__PURE__ */ (0, import_jsx_runtime150.jsxs)(import_jsx_runtime150.Fragment, { children: [
|
|
34163
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)("span", { className: "ods-workflow-header__stop-dot", "aria-hidden": "true", children: "\xB7" }),
|
|
34164
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)("span", { className: "ods-workflow-header__runtime", children: runtime })
|
|
34083
34165
|
] })
|
|
34084
34166
|
] })
|
|
34085
34167
|
}
|
|
34086
|
-
) : onRun && /* @__PURE__ */ (0,
|
|
34168
|
+
) : onRun && /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(
|
|
34087
34169
|
Button,
|
|
34088
34170
|
{
|
|
34089
34171
|
variant: "primary",
|
|
34090
34172
|
size: "sm",
|
|
34091
34173
|
"aria-label": "Run workflow",
|
|
34092
|
-
leftIcon: /* @__PURE__ */ (0,
|
|
34174
|
+
leftIcon: /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(import_icons50.PlayFilledAltIcon, { size: "sm" }),
|
|
34093
34175
|
onClick: onRun,
|
|
34094
34176
|
children: "Run"
|
|
34095
34177
|
}
|
|
34096
34178
|
),
|
|
34097
|
-
menu ?? (menuItems && menuItems.length > 0 && /* @__PURE__ */ (0,
|
|
34179
|
+
menu ?? (menuItems && menuItems.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(
|
|
34098
34180
|
DropdownMenu,
|
|
34099
34181
|
{
|
|
34100
34182
|
"aria-label": menuLabel,
|
|
34101
34183
|
align: "end",
|
|
34102
34184
|
triggerClassName: "ods-workflow-header__menu-trigger",
|
|
34103
34185
|
...menuProps,
|
|
34104
|
-
trigger: menuTrigger ?? /* @__PURE__ */ (0,
|
|
34186
|
+
trigger: menuTrigger ?? /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(
|
|
34105
34187
|
"span",
|
|
34106
34188
|
{
|
|
34107
34189
|
"aria-hidden": "true",
|
|
34108
34190
|
className: "ods-workflow-header__menu-icon",
|
|
34109
|
-
children: /* @__PURE__ */ (0,
|
|
34191
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(import_icons50.OverflowMenuVerticalIcon, { size: "sm" })
|
|
34110
34192
|
}
|
|
34111
34193
|
),
|
|
34112
34194
|
items: menuItems
|
|
34113
34195
|
}
|
|
34114
34196
|
))
|
|
34115
34197
|
] }),
|
|
34116
|
-
/* @__PURE__ */ (0,
|
|
34198
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)("span", { className: "ods-workflow-header__progress", "aria-hidden": "true" })
|
|
34117
34199
|
] });
|
|
34118
34200
|
}
|
|
34119
34201
|
|
|
34120
34202
|
// src/components/WorkflowHeader/WorkflowHeaderExpanded.tsx
|
|
34121
34203
|
var import_icons51 = require("@octaviaflow/icons");
|
|
34122
|
-
var
|
|
34204
|
+
var import_jsx_runtime151 = require("react/jsx-runtime");
|
|
34123
34205
|
function WorkflowHeaderExpanded({
|
|
34124
34206
|
name,
|
|
34125
34207
|
statusTone = "draft",
|
|
@@ -34147,15 +34229,15 @@ function WorkflowHeaderExpanded({
|
|
|
34147
34229
|
const tickedRuntime = useWorkflowRuntime(runStartedAt, !!isRunning);
|
|
34148
34230
|
const runtime = runtimeOverride ?? tickedRuntime ?? void 0;
|
|
34149
34231
|
const effectiveTone = statusTone === "draft" && isRunning ? "running" : statusTone;
|
|
34150
|
-
return /* @__PURE__ */ (0,
|
|
34232
|
+
return /* @__PURE__ */ (0, import_jsx_runtime151.jsxs)(
|
|
34151
34233
|
"header",
|
|
34152
34234
|
{
|
|
34153
34235
|
className: cn("ods-workflow-header-expanded", className),
|
|
34154
34236
|
"data-running": isRunning ? "true" : void 0,
|
|
34155
34237
|
children: [
|
|
34156
|
-
/* @__PURE__ */ (0,
|
|
34157
|
-
/* @__PURE__ */ (0,
|
|
34158
|
-
onBack && /* @__PURE__ */ (0,
|
|
34238
|
+
/* @__PURE__ */ (0, import_jsx_runtime151.jsxs)("div", { className: "ods-workflow-header-expanded__row ods-workflow-header-expanded__row--top", children: [
|
|
34239
|
+
/* @__PURE__ */ (0, import_jsx_runtime151.jsxs)("div", { className: "ods-workflow-header-expanded__left", children: [
|
|
34240
|
+
onBack && /* @__PURE__ */ (0, import_jsx_runtime151.jsxs)(
|
|
34159
34241
|
"button",
|
|
34160
34242
|
{
|
|
34161
34243
|
type: "button",
|
|
@@ -34163,13 +34245,13 @@ function WorkflowHeaderExpanded({
|
|
|
34163
34245
|
onClick: onBack,
|
|
34164
34246
|
"aria-label": `Back to ${typeof parentLabel === "string" ? parentLabel : "previous"}`,
|
|
34165
34247
|
children: [
|
|
34166
|
-
/* @__PURE__ */ (0,
|
|
34167
|
-
/* @__PURE__ */ (0,
|
|
34168
|
-
/* @__PURE__ */ (0,
|
|
34248
|
+
/* @__PURE__ */ (0, import_jsx_runtime151.jsx)(import_icons51.ChevronLeftIcon, { size: "sm" }),
|
|
34249
|
+
/* @__PURE__ */ (0, import_jsx_runtime151.jsx)("span", { children: parentLabel }),
|
|
34250
|
+
/* @__PURE__ */ (0, import_jsx_runtime151.jsx)("span", { "aria-hidden": "true", className: "ods-workflow-header-expanded__back-sep", children: "/" })
|
|
34169
34251
|
]
|
|
34170
34252
|
}
|
|
34171
34253
|
),
|
|
34172
|
-
/* @__PURE__ */ (0,
|
|
34254
|
+
/* @__PURE__ */ (0, import_jsx_runtime151.jsx)(
|
|
34173
34255
|
"span",
|
|
34174
34256
|
{
|
|
34175
34257
|
className: cn(
|
|
@@ -34180,10 +34262,10 @@ function WorkflowHeaderExpanded({
|
|
|
34180
34262
|
role: "img"
|
|
34181
34263
|
}
|
|
34182
34264
|
),
|
|
34183
|
-
/* @__PURE__ */ (0,
|
|
34265
|
+
/* @__PURE__ */ (0, import_jsx_runtime151.jsx)("h1", { className: "ods-workflow-header-expanded__title", children: name })
|
|
34184
34266
|
] }),
|
|
34185
|
-
/* @__PURE__ */ (0,
|
|
34186
|
-
environment && /* @__PURE__ */ (0,
|
|
34267
|
+
/* @__PURE__ */ (0, import_jsx_runtime151.jsxs)("div", { className: "ods-workflow-header-expanded__right", children: [
|
|
34268
|
+
environment && /* @__PURE__ */ (0, import_jsx_runtime151.jsx)(
|
|
34187
34269
|
Chip,
|
|
34188
34270
|
{
|
|
34189
34271
|
size: "sm",
|
|
@@ -34195,58 +34277,58 @@ function WorkflowHeaderExpanded({
|
|
|
34195
34277
|
children: environment.label
|
|
34196
34278
|
}
|
|
34197
34279
|
),
|
|
34198
|
-
onToggleConsole && (isRunning || consoleHasLogs) && /* @__PURE__ */ (0,
|
|
34280
|
+
onToggleConsole && (isRunning || consoleHasLogs) && /* @__PURE__ */ (0, import_jsx_runtime151.jsx)(
|
|
34199
34281
|
Button,
|
|
34200
34282
|
{
|
|
34201
34283
|
variant: "ghost",
|
|
34202
34284
|
size: "sm",
|
|
34203
34285
|
pressed: !!isConsoleOpen,
|
|
34204
34286
|
"aria-label": isConsoleOpen ? "Hide execution console" : "Show execution console",
|
|
34205
|
-
leftIcon: /* @__PURE__ */ (0,
|
|
34287
|
+
leftIcon: /* @__PURE__ */ (0, import_jsx_runtime151.jsx)(import_icons51.TerminalIcon, { size: "sm" }),
|
|
34206
34288
|
onClick: onToggleConsole,
|
|
34207
34289
|
children: "Console"
|
|
34208
34290
|
}
|
|
34209
34291
|
),
|
|
34210
|
-
(environment || onToggleConsole && (isRunning || consoleHasLogs)) && (isRunning || onRun || menuItems && menuItems.length > 0) && /* @__PURE__ */ (0,
|
|
34211
|
-
isRunning ? onStop && /* @__PURE__ */ (0,
|
|
34292
|
+
(environment || onToggleConsole && (isRunning || consoleHasLogs)) && (isRunning || onRun || menuItems && menuItems.length > 0) && /* @__PURE__ */ (0, import_jsx_runtime151.jsx)("span", { className: "ods-workflow-header-expanded__micro-divider", "aria-hidden": "true" }),
|
|
34293
|
+
isRunning ? onStop && /* @__PURE__ */ (0, import_jsx_runtime151.jsx)(
|
|
34212
34294
|
Button,
|
|
34213
34295
|
{
|
|
34214
34296
|
variant: "ghost",
|
|
34215
34297
|
size: "sm",
|
|
34216
34298
|
"aria-label": runtime ? `Stop execution (running ${runtime})` : "Stop execution",
|
|
34217
|
-
leftIcon: /* @__PURE__ */ (0,
|
|
34299
|
+
leftIcon: /* @__PURE__ */ (0, import_jsx_runtime151.jsx)(import_icons51.StopFilledAltIcon, { size: "sm", className: "ods-workflow-header-expanded__stop-glyph" }),
|
|
34218
34300
|
onClick: onStop,
|
|
34219
|
-
children: /* @__PURE__ */ (0,
|
|
34220
|
-
/* @__PURE__ */ (0,
|
|
34221
|
-
runtime && /* @__PURE__ */ (0,
|
|
34222
|
-
/* @__PURE__ */ (0,
|
|
34223
|
-
/* @__PURE__ */ (0,
|
|
34301
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime151.jsxs)("span", { style: { display: "inline-flex", gap: 4, alignItems: "center" }, children: [
|
|
34302
|
+
/* @__PURE__ */ (0, import_jsx_runtime151.jsx)("span", { children: "Stop" }),
|
|
34303
|
+
runtime && /* @__PURE__ */ (0, import_jsx_runtime151.jsxs)(import_jsx_runtime151.Fragment, { children: [
|
|
34304
|
+
/* @__PURE__ */ (0, import_jsx_runtime151.jsx)("span", { "aria-hidden": "true", style: { opacity: 0.6 }, children: "\xB7" }),
|
|
34305
|
+
/* @__PURE__ */ (0, import_jsx_runtime151.jsx)("span", { className: "ods-workflow-header-expanded__runtime", children: runtime })
|
|
34224
34306
|
] })
|
|
34225
34307
|
] })
|
|
34226
34308
|
}
|
|
34227
|
-
) : onRun && /* @__PURE__ */ (0,
|
|
34309
|
+
) : onRun && /* @__PURE__ */ (0, import_jsx_runtime151.jsx)(
|
|
34228
34310
|
Button,
|
|
34229
34311
|
{
|
|
34230
34312
|
variant: "primary",
|
|
34231
34313
|
size: "sm",
|
|
34232
34314
|
"aria-label": "Run workflow",
|
|
34233
|
-
leftIcon: /* @__PURE__ */ (0,
|
|
34315
|
+
leftIcon: /* @__PURE__ */ (0, import_jsx_runtime151.jsx)(import_icons51.PlayFilledAltIcon, { size: "sm" }),
|
|
34234
34316
|
onClick: onRun,
|
|
34235
34317
|
children: "Run"
|
|
34236
34318
|
}
|
|
34237
34319
|
),
|
|
34238
|
-
menu ?? (menuItems && menuItems.length > 0 && /* @__PURE__ */ (0,
|
|
34320
|
+
menu ?? (menuItems && menuItems.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime151.jsx)(
|
|
34239
34321
|
DropdownMenu,
|
|
34240
34322
|
{
|
|
34241
34323
|
"aria-label": menuLabel,
|
|
34242
34324
|
align: "end",
|
|
34243
34325
|
...menuProps,
|
|
34244
|
-
trigger: menuTrigger ?? /* @__PURE__ */ (0,
|
|
34326
|
+
trigger: menuTrigger ?? /* @__PURE__ */ (0, import_jsx_runtime151.jsx)(
|
|
34245
34327
|
Button,
|
|
34246
34328
|
{
|
|
34247
34329
|
variant: "ghost",
|
|
34248
34330
|
size: "sm",
|
|
34249
|
-
leftIcon: /* @__PURE__ */ (0,
|
|
34331
|
+
leftIcon: /* @__PURE__ */ (0, import_jsx_runtime151.jsx)(import_icons51.OverflowMenuVerticalIcon, { size: "sm" })
|
|
34250
34332
|
}
|
|
34251
34333
|
),
|
|
34252
34334
|
items: menuItems
|
|
@@ -34254,10 +34336,10 @@ function WorkflowHeaderExpanded({
|
|
|
34254
34336
|
))
|
|
34255
34337
|
] })
|
|
34256
34338
|
] }),
|
|
34257
|
-
(meta || saveLabel) && /* @__PURE__ */ (0,
|
|
34339
|
+
(meta || saveLabel) && /* @__PURE__ */ (0, import_jsx_runtime151.jsx)("div", { className: "ods-workflow-header-expanded__row ods-workflow-header-expanded__row--bottom", children: /* @__PURE__ */ (0, import_jsx_runtime151.jsxs)("span", { className: "ods-workflow-header-expanded__meta", children: [
|
|
34258
34340
|
meta,
|
|
34259
|
-
meta && saveLabel && /* @__PURE__ */ (0,
|
|
34260
|
-
saveLabel && /* @__PURE__ */ (0,
|
|
34341
|
+
meta && saveLabel && /* @__PURE__ */ (0, import_jsx_runtime151.jsx)("span", { "aria-hidden": "true", style: { margin: "0 6px", opacity: 0.4 }, children: "\xB7" }),
|
|
34342
|
+
saveLabel && /* @__PURE__ */ (0, import_jsx_runtime151.jsx)(
|
|
34261
34343
|
"span",
|
|
34262
34344
|
{
|
|
34263
34345
|
className: cn(
|
|
@@ -34269,7 +34351,7 @@ function WorkflowHeaderExpanded({
|
|
|
34269
34351
|
}
|
|
34270
34352
|
)
|
|
34271
34353
|
] }) }),
|
|
34272
|
-
/* @__PURE__ */ (0,
|
|
34354
|
+
/* @__PURE__ */ (0, import_jsx_runtime151.jsx)("span", { className: "ods-workflow-header-expanded__progress", "aria-hidden": "true" })
|
|
34273
34355
|
]
|
|
34274
34356
|
}
|
|
34275
34357
|
);
|
|
@@ -34279,7 +34361,7 @@ function WorkflowHeaderExpanded({
|
|
|
34279
34361
|
var import_icons52 = require("@octaviaflow/icons");
|
|
34280
34362
|
var import_fast_xml_parser = require("fast-xml-parser");
|
|
34281
34363
|
var import_react172 = require("react");
|
|
34282
|
-
var
|
|
34364
|
+
var import_jsx_runtime152 = require("react/jsx-runtime");
|
|
34283
34365
|
function parseXml(src) {
|
|
34284
34366
|
if (typeof window !== "undefined" && typeof window.DOMParser !== "undefined") {
|
|
34285
34367
|
try {
|
|
@@ -34370,7 +34452,7 @@ var XmlViewer = (0, import_react172.forwardRef)(
|
|
|
34370
34452
|
const bodyStyle = height !== void 0 ? { height: typeof height === "number" ? `${height}px` : height } : maxHeight !== void 0 ? {
|
|
34371
34453
|
maxHeight: typeof maxHeight === "number" ? `${maxHeight}px` : maxHeight
|
|
34372
34454
|
} : void 0;
|
|
34373
|
-
return /* @__PURE__ */ (0,
|
|
34455
|
+
return /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)(
|
|
34374
34456
|
"div",
|
|
34375
34457
|
{
|
|
34376
34458
|
...rest,
|
|
@@ -34378,9 +34460,9 @@ var XmlViewer = (0, import_react172.forwardRef)(
|
|
|
34378
34460
|
id: baseId,
|
|
34379
34461
|
className: cn("ods-xml-viewer", className),
|
|
34380
34462
|
children: [
|
|
34381
|
-
(title || status || parsed.error) && /* @__PURE__ */ (0,
|
|
34382
|
-
title && /* @__PURE__ */ (0,
|
|
34383
|
-
parsed.error && /* @__PURE__ */ (0,
|
|
34463
|
+
(title || status || parsed.error) && /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("div", { className: "ods-xml-viewer__head", children: [
|
|
34464
|
+
title && /* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__title", children: title }),
|
|
34465
|
+
parsed.error && /* @__PURE__ */ (0, import_jsx_runtime152.jsx)(
|
|
34384
34466
|
"span",
|
|
34385
34467
|
{
|
|
34386
34468
|
className: "ods-xml-viewer__status ods-xml-viewer__status--error",
|
|
@@ -34388,9 +34470,9 @@ var XmlViewer = (0, import_react172.forwardRef)(
|
|
|
34388
34470
|
children: "Invalid XML"
|
|
34389
34471
|
}
|
|
34390
34472
|
),
|
|
34391
|
-
status && !parsed.error && /* @__PURE__ */ (0,
|
|
34473
|
+
status && !parsed.error && /* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__status", children: status })
|
|
34392
34474
|
] }),
|
|
34393
|
-
/* @__PURE__ */ (0,
|
|
34475
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("div", { className: "ods-xml-viewer__body", style: bodyStyle, "data-mode": mode, children: mode === "edit" ? /* @__PURE__ */ (0, import_jsx_runtime152.jsx)(XmlEditBody, { text: data, onChange, onValidate }) : parsed.error ? /* @__PURE__ */ (0, import_jsx_runtime152.jsx)("pre", { className: "ods-xml-viewer__raw", children: data }) : parsed.root ? /* @__PURE__ */ (0, import_jsx_runtime152.jsx)(
|
|
34394
34476
|
XmlNodeRow,
|
|
34395
34477
|
{
|
|
34396
34478
|
node: parsed.root,
|
|
@@ -34434,8 +34516,8 @@ function XmlEditBody({ text: initial, onChange, onValidate }) {
|
|
|
34434
34516
|
(0, import_react172.useEffect)(() => {
|
|
34435
34517
|
validate(initial);
|
|
34436
34518
|
}, []);
|
|
34437
|
-
return /* @__PURE__ */ (0,
|
|
34438
|
-
parseError && /* @__PURE__ */ (0,
|
|
34519
|
+
return /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("div", { className: "ods-xml-viewer__edit", children: [
|
|
34520
|
+
parseError && /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)(
|
|
34439
34521
|
InlineMessage,
|
|
34440
34522
|
{
|
|
34441
34523
|
tone: "danger",
|
|
@@ -34452,7 +34534,7 @@ function XmlEditBody({ text: initial, onChange, onValidate }) {
|
|
|
34452
34534
|
]
|
|
34453
34535
|
}
|
|
34454
34536
|
),
|
|
34455
|
-
/* @__PURE__ */ (0,
|
|
34537
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)(
|
|
34456
34538
|
CodeEditor,
|
|
34457
34539
|
{
|
|
34458
34540
|
value: text,
|
|
@@ -34495,27 +34577,27 @@ function XmlNodeRow({
|
|
|
34495
34577
|
if (node.type === "text") {
|
|
34496
34578
|
const t = (node.text ?? "").trim();
|
|
34497
34579
|
const truncated = t.length > truncateAt ? `${t.slice(0, truncateAt)}\u2026` : t;
|
|
34498
|
-
return /* @__PURE__ */ (0,
|
|
34499
|
-
/* @__PURE__ */ (0,
|
|
34500
|
-
/* @__PURE__ */ (0,
|
|
34580
|
+
return /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("div", { className: "ods-xml-viewer__row", style: { paddingLeft: pad2 }, children: [
|
|
34581
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__caret-spacer" }),
|
|
34582
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__text", children: truncated })
|
|
34501
34583
|
] });
|
|
34502
34584
|
}
|
|
34503
34585
|
if (node.type === "comment") {
|
|
34504
|
-
return /* @__PURE__ */ (0,
|
|
34505
|
-
/* @__PURE__ */ (0,
|
|
34506
|
-
/* @__PURE__ */ (0,
|
|
34586
|
+
return /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("div", { className: "ods-xml-viewer__row", style: { paddingLeft: pad2 }, children: [
|
|
34587
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__caret-spacer" }),
|
|
34588
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__comment", children: `<!-- ${node.text} -->` })
|
|
34507
34589
|
] });
|
|
34508
34590
|
}
|
|
34509
34591
|
if (node.type === "cdata") {
|
|
34510
|
-
return /* @__PURE__ */ (0,
|
|
34511
|
-
/* @__PURE__ */ (0,
|
|
34512
|
-
/* @__PURE__ */ (0,
|
|
34592
|
+
return /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("div", { className: "ods-xml-viewer__row", style: { paddingLeft: pad2 }, children: [
|
|
34593
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__caret-spacer" }),
|
|
34594
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__cdata", children: `<![CDATA[${node.text}]]>` })
|
|
34513
34595
|
] });
|
|
34514
34596
|
}
|
|
34515
34597
|
if (node.type === "pi") {
|
|
34516
|
-
return /* @__PURE__ */ (0,
|
|
34517
|
-
/* @__PURE__ */ (0,
|
|
34518
|
-
/* @__PURE__ */ (0,
|
|
34598
|
+
return /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("div", { className: "ods-xml-viewer__row", style: { paddingLeft: pad2 }, children: [
|
|
34599
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__caret-spacer" }),
|
|
34600
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__pi", children: `<?${node.text}?>` })
|
|
34519
34601
|
] });
|
|
34520
34602
|
}
|
|
34521
34603
|
const children = node.children ?? [];
|
|
@@ -34524,58 +34606,58 @@ function XmlNodeRow({
|
|
|
34524
34606
|
const inlineTextChild = children.length === 1 && children[0].type === "text" ? children[0].text ?? "" : null;
|
|
34525
34607
|
if (inlineTextChild !== null) {
|
|
34526
34608
|
const isMultiLine = inlineTextChild.includes("\n");
|
|
34527
|
-
const openTag = /* @__PURE__ */ (0,
|
|
34528
|
-
/* @__PURE__ */ (0,
|
|
34529
|
-
/* @__PURE__ */ (0,
|
|
34530
|
-
showAttributes && attrs.map(([k, v]) => /* @__PURE__ */ (0,
|
|
34531
|
-
/* @__PURE__ */ (0,
|
|
34532
|
-
/* @__PURE__ */ (0,
|
|
34533
|
-
/* @__PURE__ */ (0,
|
|
34609
|
+
const openTag = /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)(import_jsx_runtime152.Fragment, { children: [
|
|
34610
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__bracket", children: "<" }),
|
|
34611
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__tag", children: node.name }),
|
|
34612
|
+
showAttributes && attrs.map(([k, v]) => /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("span", { className: "ods-xml-viewer__attr", children: [
|
|
34613
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__attr-name", children: k }),
|
|
34614
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__attr-eq", children: "=" }),
|
|
34615
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__attr-value", children: `"${v}"` })
|
|
34534
34616
|
] }, k)),
|
|
34535
|
-
/* @__PURE__ */ (0,
|
|
34617
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__bracket", children: ">" })
|
|
34536
34618
|
] });
|
|
34537
|
-
const closeTag = /* @__PURE__ */ (0,
|
|
34538
|
-
/* @__PURE__ */ (0,
|
|
34539
|
-
/* @__PURE__ */ (0,
|
|
34540
|
-
/* @__PURE__ */ (0,
|
|
34619
|
+
const closeTag = /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)(import_jsx_runtime152.Fragment, { children: [
|
|
34620
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__bracket", children: "</" }),
|
|
34621
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__tag", children: node.name }),
|
|
34622
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__bracket", children: ">" })
|
|
34541
34623
|
] });
|
|
34542
34624
|
if (isMultiLine) {
|
|
34543
34625
|
const innerPad = pad2 + 12;
|
|
34544
|
-
return /* @__PURE__ */ (0,
|
|
34545
|
-
/* @__PURE__ */ (0,
|
|
34546
|
-
/* @__PURE__ */ (0,
|
|
34626
|
+
return /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("div", { children: [
|
|
34627
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("div", { className: "ods-xml-viewer__row", style: { paddingLeft: pad2 }, children: [
|
|
34628
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__caret-spacer" }),
|
|
34547
34629
|
openTag
|
|
34548
34630
|
] }),
|
|
34549
|
-
/* @__PURE__ */ (0,
|
|
34631
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)(
|
|
34550
34632
|
"div",
|
|
34551
34633
|
{
|
|
34552
34634
|
className: "ods-xml-viewer__row ods-xml-viewer__row--multiline",
|
|
34553
34635
|
style: { paddingLeft: innerPad },
|
|
34554
|
-
children: /* @__PURE__ */ (0,
|
|
34636
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__text", children: inlineTextChild })
|
|
34555
34637
|
}
|
|
34556
34638
|
),
|
|
34557
|
-
/* @__PURE__ */ (0,
|
|
34558
|
-
/* @__PURE__ */ (0,
|
|
34639
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("div", { className: "ods-xml-viewer__row", style: { paddingLeft: pad2 }, children: [
|
|
34640
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__caret-spacer" }),
|
|
34559
34641
|
closeTag
|
|
34560
34642
|
] })
|
|
34561
34643
|
] });
|
|
34562
34644
|
}
|
|
34563
|
-
return /* @__PURE__ */ (0,
|
|
34564
|
-
/* @__PURE__ */ (0,
|
|
34645
|
+
return /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("div", { className: "ods-xml-viewer__row", style: { paddingLeft: pad2 }, children: [
|
|
34646
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__caret-spacer" }),
|
|
34565
34647
|
openTag,
|
|
34566
|
-
/* @__PURE__ */ (0,
|
|
34648
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__text", children: inlineTextChild }),
|
|
34567
34649
|
closeTag
|
|
34568
34650
|
] });
|
|
34569
34651
|
}
|
|
34570
|
-
return /* @__PURE__ */ (0,
|
|
34571
|
-
/* @__PURE__ */ (0,
|
|
34652
|
+
return /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("div", { children: [
|
|
34653
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsxs)(
|
|
34572
34654
|
"div",
|
|
34573
34655
|
{
|
|
34574
34656
|
className: "ods-xml-viewer__row ods-xml-viewer__row--element",
|
|
34575
34657
|
style: { paddingLeft: pad2 },
|
|
34576
34658
|
onClick: () => !isSelfClosing && setOpen((o) => !o),
|
|
34577
34659
|
children: [
|
|
34578
|
-
isSelfClosing ? /* @__PURE__ */ (0,
|
|
34660
|
+
isSelfClosing ? /* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__caret-spacer" }) : /* @__PURE__ */ (0, import_jsx_runtime152.jsx)(
|
|
34579
34661
|
"button",
|
|
34580
34662
|
{
|
|
34581
34663
|
type: "button",
|
|
@@ -34589,30 +34671,30 @@ function XmlNodeRow({
|
|
|
34589
34671
|
e.stopPropagation();
|
|
34590
34672
|
setOpen((o) => !o);
|
|
34591
34673
|
},
|
|
34592
|
-
children: /* @__PURE__ */ (0,
|
|
34674
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime152.jsx)(import_icons52.ChevronRightIcon, { size: "xs" })
|
|
34593
34675
|
}
|
|
34594
34676
|
),
|
|
34595
|
-
/* @__PURE__ */ (0,
|
|
34596
|
-
/* @__PURE__ */ (0,
|
|
34597
|
-
showAttributes && attrs.map(([k, v]) => /* @__PURE__ */ (0,
|
|
34598
|
-
/* @__PURE__ */ (0,
|
|
34599
|
-
/* @__PURE__ */ (0,
|
|
34600
|
-
/* @__PURE__ */ (0,
|
|
34677
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__bracket", children: "<" }),
|
|
34678
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__tag", children: node.name }),
|
|
34679
|
+
showAttributes && attrs.map(([k, v]) => /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("span", { className: "ods-xml-viewer__attr", children: [
|
|
34680
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__attr-name", children: k }),
|
|
34681
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__attr-eq", children: "=" }),
|
|
34682
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__attr-value", children: `"${v}"` })
|
|
34601
34683
|
] }, k)),
|
|
34602
|
-
isSelfClosing ? /* @__PURE__ */ (0,
|
|
34603
|
-
/* @__PURE__ */ (0,
|
|
34604
|
-
!open && /* @__PURE__ */ (0,
|
|
34605
|
-
/* @__PURE__ */ (0,
|
|
34684
|
+
isSelfClosing ? /* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__bracket", children: " />" }) : /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)(import_jsx_runtime152.Fragment, { children: [
|
|
34685
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__bracket", children: ">" }),
|
|
34686
|
+
!open && /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)(import_jsx_runtime152.Fragment, { children: [
|
|
34687
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("span", { className: "ods-xml-viewer__preview", children: [
|
|
34606
34688
|
children.length,
|
|
34607
34689
|
" child",
|
|
34608
34690
|
children.length === 1 ? "" : "ren"
|
|
34609
34691
|
] }),
|
|
34610
|
-
/* @__PURE__ */ (0,
|
|
34611
|
-
/* @__PURE__ */ (0,
|
|
34612
|
-
/* @__PURE__ */ (0,
|
|
34692
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__bracket", children: "</" }),
|
|
34693
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__tag", children: node.name }),
|
|
34694
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__bracket", children: ">" })
|
|
34613
34695
|
] })
|
|
34614
34696
|
] }),
|
|
34615
|
-
copyable && /* @__PURE__ */ (0,
|
|
34697
|
+
copyable && /* @__PURE__ */ (0, import_jsx_runtime152.jsx)(
|
|
34616
34698
|
"button",
|
|
34617
34699
|
{
|
|
34618
34700
|
type: "button",
|
|
@@ -34622,14 +34704,14 @@ function XmlNodeRow({
|
|
|
34622
34704
|
),
|
|
34623
34705
|
"aria-label": copied ? "Copied" : `Copy ${node.name} subtree`,
|
|
34624
34706
|
onClick: onCopy,
|
|
34625
|
-
children: copied ? /* @__PURE__ */ (0,
|
|
34707
|
+
children: copied ? /* @__PURE__ */ (0, import_jsx_runtime152.jsx)(import_icons52.CheckmarkIcon, { size: "xs" }) : /* @__PURE__ */ (0, import_jsx_runtime152.jsx)(import_icons52.CopyIcon, { size: "xs" })
|
|
34626
34708
|
}
|
|
34627
34709
|
)
|
|
34628
34710
|
]
|
|
34629
34711
|
}
|
|
34630
34712
|
),
|
|
34631
|
-
!isSelfClosing && open && /* @__PURE__ */ (0,
|
|
34632
|
-
children.map((c, i) => /* @__PURE__ */ (0,
|
|
34713
|
+
!isSelfClosing && open && /* @__PURE__ */ (0, import_jsx_runtime152.jsxs)(import_jsx_runtime152.Fragment, { children: [
|
|
34714
|
+
children.map((c, i) => /* @__PURE__ */ (0, import_jsx_runtime152.jsx)(
|
|
34633
34715
|
XmlNodeRow,
|
|
34634
34716
|
{
|
|
34635
34717
|
node: c,
|
|
@@ -34641,11 +34723,11 @@ function XmlNodeRow({
|
|
|
34641
34723
|
},
|
|
34642
34724
|
i
|
|
34643
34725
|
)),
|
|
34644
|
-
/* @__PURE__ */ (0,
|
|
34645
|
-
/* @__PURE__ */ (0,
|
|
34646
|
-
/* @__PURE__ */ (0,
|
|
34647
|
-
/* @__PURE__ */ (0,
|
|
34648
|
-
/* @__PURE__ */ (0,
|
|
34726
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsxs)("div", { className: "ods-xml-viewer__row", style: { paddingLeft: pad2 }, children: [
|
|
34727
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__caret-spacer" }),
|
|
34728
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__bracket", children: "</" }),
|
|
34729
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__tag", children: node.name }),
|
|
34730
|
+
/* @__PURE__ */ (0, import_jsx_runtime152.jsx)("span", { className: "ods-xml-viewer__bracket", children: ">" })
|
|
34649
34731
|
] })
|
|
34650
34732
|
] })
|
|
34651
34733
|
] });
|
|
@@ -34655,7 +34737,7 @@ function XmlNodeRow({
|
|
|
34655
34737
|
var import_icons53 = require("@octaviaflow/icons");
|
|
34656
34738
|
var import_react173 = require("react");
|
|
34657
34739
|
var import_yaml = __toESM(require("yaml"), 1);
|
|
34658
|
-
var
|
|
34740
|
+
var import_jsx_runtime153 = require("react/jsx-runtime");
|
|
34659
34741
|
function toYaml(value, indent = 0) {
|
|
34660
34742
|
const pad2 = " ".repeat(indent);
|
|
34661
34743
|
if (value === null) return "null";
|
|
@@ -34854,7 +34936,7 @@ var YamlViewer = (0, import_react173.forwardRef)(
|
|
|
34854
34936
|
const bodyStyle = height !== void 0 ? { height: typeof height === "number" ? `${height}px` : height } : maxHeight !== void 0 ? {
|
|
34855
34937
|
maxHeight: typeof maxHeight === "number" ? `${maxHeight}px` : maxHeight
|
|
34856
34938
|
} : void 0;
|
|
34857
|
-
return /* @__PURE__ */ (0,
|
|
34939
|
+
return /* @__PURE__ */ (0, import_jsx_runtime153.jsxs)(
|
|
34858
34940
|
"div",
|
|
34859
34941
|
{
|
|
34860
34942
|
...rest,
|
|
@@ -34866,11 +34948,11 @@ var YamlViewer = (0, import_react173.forwardRef)(
|
|
|
34866
34948
|
className
|
|
34867
34949
|
),
|
|
34868
34950
|
children: [
|
|
34869
|
-
(title || status || copyable) && /* @__PURE__ */ (0,
|
|
34870
|
-
title && /* @__PURE__ */ (0,
|
|
34871
|
-
/* @__PURE__ */ (0,
|
|
34872
|
-
status && /* @__PURE__ */ (0,
|
|
34873
|
-
copyable && /* @__PURE__ */ (0,
|
|
34951
|
+
(title || status || copyable) && /* @__PURE__ */ (0, import_jsx_runtime153.jsxs)("div", { className: "ods-yaml-viewer__head", children: [
|
|
34952
|
+
title && /* @__PURE__ */ (0, import_jsx_runtime153.jsx)("span", { className: "ods-yaml-viewer__title", children: title }),
|
|
34953
|
+
/* @__PURE__ */ (0, import_jsx_runtime153.jsxs)("span", { className: "ods-yaml-viewer__head-right", children: [
|
|
34954
|
+
status && /* @__PURE__ */ (0, import_jsx_runtime153.jsx)("span", { className: "ods-yaml-viewer__status", children: status }),
|
|
34955
|
+
copyable && /* @__PURE__ */ (0, import_jsx_runtime153.jsx)(
|
|
34874
34956
|
"button",
|
|
34875
34957
|
{
|
|
34876
34958
|
type: "button",
|
|
@@ -34880,16 +34962,16 @@ var YamlViewer = (0, import_react173.forwardRef)(
|
|
|
34880
34962
|
),
|
|
34881
34963
|
"aria-label": copied ? "Copied" : "Copy YAML",
|
|
34882
34964
|
onClick: onCopy,
|
|
34883
|
-
children: copied ? /* @__PURE__ */ (0,
|
|
34965
|
+
children: copied ? /* @__PURE__ */ (0, import_jsx_runtime153.jsx)(import_icons53.CheckmarkIcon, { size: "xs" }) : /* @__PURE__ */ (0, import_jsx_runtime153.jsx)(import_icons53.CopyIcon, { size: "xs" })
|
|
34884
34966
|
}
|
|
34885
34967
|
)
|
|
34886
34968
|
] })
|
|
34887
34969
|
] }),
|
|
34888
|
-
/* @__PURE__ */ (0,
|
|
34970
|
+
/* @__PURE__ */ (0, import_jsx_runtime153.jsx)("div", { className: "ods-yaml-viewer__body", style: bodyStyle, "data-mode": mode, children: mode === "edit" ? /* @__PURE__ */ (0, import_jsx_runtime153.jsx)(YamlEditBody, { text, onChange, onValidate }) : tokens.map((t) => {
|
|
34889
34971
|
if (hidden.has(t.index)) return null;
|
|
34890
34972
|
const lineNo = t.index + 1;
|
|
34891
34973
|
const isCollapsed = collapsed.has(t.index);
|
|
34892
|
-
return /* @__PURE__ */ (0,
|
|
34974
|
+
return /* @__PURE__ */ (0, import_jsx_runtime153.jsxs)(
|
|
34893
34975
|
"div",
|
|
34894
34976
|
{
|
|
34895
34977
|
className: cn(
|
|
@@ -34898,7 +34980,7 @@ var YamlViewer = (0, import_react173.forwardRef)(
|
|
|
34898
34980
|
isCollapsed && "ods-yaml-viewer__line--collapsed"
|
|
34899
34981
|
),
|
|
34900
34982
|
children: [
|
|
34901
|
-
showLineNumbers && /* @__PURE__ */ (0,
|
|
34983
|
+
showLineNumbers && /* @__PURE__ */ (0, import_jsx_runtime153.jsx)(
|
|
34902
34984
|
"span",
|
|
34903
34985
|
{
|
|
34904
34986
|
className: "ods-yaml-viewer__line-no",
|
|
@@ -34906,7 +34988,7 @@ var YamlViewer = (0, import_react173.forwardRef)(
|
|
|
34906
34988
|
children: lineNo
|
|
34907
34989
|
}
|
|
34908
34990
|
),
|
|
34909
|
-
/* @__PURE__ */ (0,
|
|
34991
|
+
/* @__PURE__ */ (0, import_jsx_runtime153.jsx)(
|
|
34910
34992
|
"span",
|
|
34911
34993
|
{
|
|
34912
34994
|
className: "ods-yaml-viewer__indent",
|
|
@@ -34914,7 +34996,7 @@ var YamlViewer = (0, import_react173.forwardRef)(
|
|
|
34914
34996
|
"aria-hidden": "true"
|
|
34915
34997
|
}
|
|
34916
34998
|
),
|
|
34917
|
-
t.hasChildren ? /* @__PURE__ */ (0,
|
|
34999
|
+
t.hasChildren ? /* @__PURE__ */ (0, import_jsx_runtime153.jsx)(
|
|
34918
35000
|
"button",
|
|
34919
35001
|
{
|
|
34920
35002
|
type: "button",
|
|
@@ -34925,15 +35007,15 @@ var YamlViewer = (0, import_react173.forwardRef)(
|
|
|
34925
35007
|
onClick: () => toggle(t.index),
|
|
34926
35008
|
"aria-expanded": !isCollapsed,
|
|
34927
35009
|
"aria-label": isCollapsed ? "Expand" : "Collapse",
|
|
34928
|
-
children: /* @__PURE__ */ (0,
|
|
35010
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime153.jsx)(import_icons53.ChevronRightIcon, { size: "xs" })
|
|
34929
35011
|
}
|
|
34930
|
-
) : /* @__PURE__ */ (0,
|
|
34931
|
-
t.kind === "comment" && /* @__PURE__ */ (0,
|
|
34932
|
-
t.kind === "key" && /* @__PURE__ */ (0,
|
|
34933
|
-
t.raw.trim().startsWith("-") && /* @__PURE__ */ (0,
|
|
34934
|
-
/* @__PURE__ */ (0,
|
|
34935
|
-
/* @__PURE__ */ (0,
|
|
34936
|
-
t.inlineValue && /* @__PURE__ */ (0,
|
|
35012
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime153.jsx)("span", { className: "ods-yaml-viewer__caret-spacer" }),
|
|
35013
|
+
t.kind === "comment" && /* @__PURE__ */ (0, import_jsx_runtime153.jsx)("span", { className: "ods-yaml-viewer__comment", children: t.raw.trim() }),
|
|
35014
|
+
t.kind === "key" && /* @__PURE__ */ (0, import_jsx_runtime153.jsxs)(import_jsx_runtime153.Fragment, { children: [
|
|
35015
|
+
t.raw.trim().startsWith("-") && /* @__PURE__ */ (0, import_jsx_runtime153.jsx)("span", { className: "ods-yaml-viewer__dash", children: "- " }),
|
|
35016
|
+
/* @__PURE__ */ (0, import_jsx_runtime153.jsx)("span", { className: "ods-yaml-viewer__key", children: t.key }),
|
|
35017
|
+
/* @__PURE__ */ (0, import_jsx_runtime153.jsx)("span", { className: "ods-yaml-viewer__colon", children: ":" }),
|
|
35018
|
+
t.inlineValue && /* @__PURE__ */ (0, import_jsx_runtime153.jsxs)(
|
|
34937
35019
|
"span",
|
|
34938
35020
|
{
|
|
34939
35021
|
className: cn(
|
|
@@ -34946,11 +35028,11 @@ var YamlViewer = (0, import_react173.forwardRef)(
|
|
|
34946
35028
|
]
|
|
34947
35029
|
}
|
|
34948
35030
|
),
|
|
34949
|
-
isCollapsed && /* @__PURE__ */ (0,
|
|
35031
|
+
isCollapsed && /* @__PURE__ */ (0, import_jsx_runtime153.jsx)("span", { className: "ods-yaml-viewer__preview", children: " \u2026" })
|
|
34950
35032
|
] }),
|
|
34951
|
-
t.kind === "sequence" && /* @__PURE__ */ (0,
|
|
34952
|
-
/* @__PURE__ */ (0,
|
|
34953
|
-
/* @__PURE__ */ (0,
|
|
35033
|
+
t.kind === "sequence" && /* @__PURE__ */ (0, import_jsx_runtime153.jsxs)(import_jsx_runtime153.Fragment, { children: [
|
|
35034
|
+
/* @__PURE__ */ (0, import_jsx_runtime153.jsx)("span", { className: "ods-yaml-viewer__dash", children: "- " }),
|
|
35035
|
+
/* @__PURE__ */ (0, import_jsx_runtime153.jsx)(
|
|
34954
35036
|
"span",
|
|
34955
35037
|
{
|
|
34956
35038
|
className: cn(
|
|
@@ -34961,7 +35043,7 @@ var YamlViewer = (0, import_react173.forwardRef)(
|
|
|
34961
35043
|
}
|
|
34962
35044
|
)
|
|
34963
35045
|
] }),
|
|
34964
|
-
t.kind === "scalar" && /* @__PURE__ */ (0,
|
|
35046
|
+
t.kind === "scalar" && /* @__PURE__ */ (0, import_jsx_runtime153.jsx)(
|
|
34965
35047
|
"span",
|
|
34966
35048
|
{
|
|
34967
35049
|
className: cn(
|
|
@@ -34971,7 +35053,7 @@ var YamlViewer = (0, import_react173.forwardRef)(
|
|
|
34971
35053
|
children: t.raw.trim()
|
|
34972
35054
|
}
|
|
34973
35055
|
),
|
|
34974
|
-
t.kind === "blank" && /* @__PURE__ */ (0,
|
|
35056
|
+
t.kind === "blank" && /* @__PURE__ */ (0, import_jsx_runtime153.jsx)("span", { children: "\xA0" })
|
|
34975
35057
|
]
|
|
34976
35058
|
},
|
|
34977
35059
|
t.index
|
|
@@ -35027,8 +35109,8 @@ function YamlEditBody({ text: initial, onChange, onValidate }) {
|
|
|
35027
35109
|
(0, import_react173.useEffect)(() => {
|
|
35028
35110
|
validate(initial);
|
|
35029
35111
|
}, []);
|
|
35030
|
-
return /* @__PURE__ */ (0,
|
|
35031
|
-
parseError && /* @__PURE__ */ (0,
|
|
35112
|
+
return /* @__PURE__ */ (0, import_jsx_runtime153.jsxs)("div", { className: "ods-yaml-viewer__edit", children: [
|
|
35113
|
+
parseError && /* @__PURE__ */ (0, import_jsx_runtime153.jsxs)(
|
|
35032
35114
|
InlineMessage,
|
|
35033
35115
|
{
|
|
35034
35116
|
tone: "danger",
|
|
@@ -35045,7 +35127,7 @@ function YamlEditBody({ text: initial, onChange, onValidate }) {
|
|
|
35045
35127
|
]
|
|
35046
35128
|
}
|
|
35047
35129
|
),
|
|
35048
|
-
/* @__PURE__ */ (0,
|
|
35130
|
+
/* @__PURE__ */ (0, import_jsx_runtime153.jsx)(
|
|
35049
35131
|
CodeEditor,
|
|
35050
35132
|
{
|
|
35051
35133
|
value: text,
|
|
@@ -35449,7 +35531,7 @@ function useTraceTimeline({
|
|
|
35449
35531
|
var import_config = require("@octaviaflow/config");
|
|
35450
35532
|
var import_react180 = require("react");
|
|
35451
35533
|
var import_react_aria15 = require("react-aria");
|
|
35452
|
-
var
|
|
35534
|
+
var import_jsx_runtime154 = require("react/jsx-runtime");
|
|
35453
35535
|
var OdsContext = (0, import_react180.createContext)(null);
|
|
35454
35536
|
function OdsProvider({ config: userConfig, children }) {
|
|
35455
35537
|
const resolved = (0, import_react180.useMemo)(() => (0, import_config.resolveConfig)(userConfig), [userConfig]);
|
|
@@ -35470,7 +35552,7 @@ function OdsProvider({ config: userConfig, children }) {
|
|
|
35470
35552
|
}
|
|
35471
35553
|
}, [resolved]);
|
|
35472
35554
|
const contextValue = (0, import_react180.useMemo)(() => ({ config: resolved }), [resolved]);
|
|
35473
|
-
return /* @__PURE__ */ (0,
|
|
35555
|
+
return /* @__PURE__ */ (0, import_jsx_runtime154.jsx)(OdsContext.Provider, { value: contextValue, children: /* @__PURE__ */ (0, import_jsx_runtime154.jsx)(import_react_aria15.OverlayProvider, { children }) });
|
|
35474
35556
|
}
|
|
35475
35557
|
function useOds() {
|
|
35476
35558
|
const ctx = (0, import_react180.useContext)(OdsContext);
|
|
@@ -35931,6 +36013,7 @@ function applyVerticalLayout(nodes, edges) {
|
|
|
35931
36013
|
Spotlight,
|
|
35932
36014
|
Stack,
|
|
35933
36015
|
Stat,
|
|
36016
|
+
StatusList,
|
|
35934
36017
|
StatusTiles,
|
|
35935
36018
|
Stepper,
|
|
35936
36019
|
Switch,
|