@galaxy-io/filament-ui 0.2.0 → 0.3.0
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/connections/ConnectorNameChips.d.ts +8 -0
- package/dist/components/connections/ConnectorNameChips.js +34 -0
- package/dist/module/hooks.d.ts +1 -1
- package/dist/module/routes.d.ts +1 -1
- package/dist/module/schemas.d.ts +1 -2
- package/dist/module/schemas.js +1 -2
- package/dist/pages/connections/components/drawer/ConnectionDrawer.js +4 -27
- package/dist/pages/pipelines/PipelineCanvasPage.js +2 -1
- package/dist/pages/pipelines/canvas/PipelineCanvasControls.js +2 -5
- package/dist/pages/pipelines/canvas/PipelineCanvasFlow.js +10 -12
- package/dist/pages/pipelines/canvas/constants.d.ts +3 -1
- package/dist/pages/pipelines/canvas/constants.js +11 -1
- package/dist/pages/pipelines/canvas/hooks/usePipelineCanvasSelection.d.ts +2 -3
- package/dist/pages/pipelines/canvas/hooks/usePipelineCanvasSelection.js +6 -13
- package/dist/pages/pipelines/canvas/hooks/usePipelineCanvasSelectionReveal.js +11 -12
- package/dist/pages/pipelines/canvas/panel/PipelineCanvasPanel.js +8 -35
- package/dist/pages/pipelines/canvas/panel/PipelineCanvasPanelColumn.d.ts +3 -0
- package/dist/pages/pipelines/canvas/panel/PipelineCanvasPanelColumn.js +63 -0
- package/dist/pages/pipelines/canvas/panel/PipelineCanvasPanelHeader.d.ts +5 -3
- package/dist/pages/pipelines/canvas/panel/PipelineCanvasPanelHeader.js +21 -14
- package/dist/pages/pipelines/canvas/panel/PipelineCanvasPanelLayout.d.ts +3 -0
- package/dist/pages/pipelines/canvas/panel/PipelineCanvasPanelLayout.js +28 -0
- package/dist/pages/pipelines/canvas/panel/PipelineCanvasPanelOpenButton.d.ts +3 -0
- package/dist/pages/pipelines/canvas/panel/PipelineCanvasPanelOpenButton.js +18 -0
- package/dist/pages/pipelines/canvas/panel/activity/PipelineCanvasPanelActivity.d.ts +5 -1
- package/dist/pages/pipelines/canvas/panel/activity/PipelineCanvasPanelActivity.js +19 -19
- package/dist/pages/pipelines/canvas/panel/activity/PipelineCanvasPanelActivityHeader.d.ts +7 -0
- package/dist/pages/pipelines/canvas/panel/activity/PipelineCanvasPanelActivityHeader.js +41 -0
- package/dist/pages/pipelines/canvas/panel/activity/PipelineCanvasPanelActivityLine.js +2 -2
- package/dist/pages/pipelines/canvas/panel/activity/constants.d.ts +5 -0
- package/dist/pages/pipelines/canvas/panel/activity/constants.js +8 -0
- package/dist/pages/pipelines/canvas/panel/activity/hooks/usePipelineCanvasPanelActivityRunIds.d.ts +1 -0
- package/dist/pages/pipelines/canvas/panel/activity/hooks/usePipelineCanvasPanelActivityRunIds.js +14 -0
- package/dist/pages/pipelines/canvas/panel/activity/hooks/usePipelineCanvasPanelActivityStickToBottom.d.ts +2 -0
- package/dist/pages/pipelines/canvas/panel/activity/hooks/usePipelineCanvasPanelActivityStickToBottom.js +57 -0
- package/dist/pages/pipelines/canvas/panel/activity/utils.d.ts +1 -0
- package/dist/pages/pipelines/canvas/panel/activity/utils.js +6 -1
- package/dist/pages/pipelines/canvas/panel/constants.d.ts +13 -5
- package/dist/pages/pipelines/canvas/panel/constants.js +7 -1
- package/dist/pages/pipelines/canvas/panel/overview/node/PipelineCanvasPanelNodeDetail.js +7 -2
- package/dist/pages/pipelines/canvas/panel/overview/resource/PipelineCanvasPanelResourceDetail.js +1 -0
- package/dist/pages/pipelines/canvas/panel/overview/resource/PipelineCanvasPanelResourceSection.js +1 -1
- package/dist/pages/pipelines/canvas/routes/PipelineCanvasRoutes.js +4 -5
- package/dist/pages/pipelines/canvas/routes/PipelineCanvasRoutesList.js +1 -0
- package/dist/pages/pipelines/canvas/routes/PipelineCanvasRoutesToolbar.js +3 -1
- package/dist/pages/pipelines/canvas/routes/constants.d.ts +1 -0
- package/dist/pages/pipelines/canvas/utils.d.ts +0 -3
- package/dist/pages/pipelines/canvas/utils.js +1 -11
- package/dist/pages/pipelines/components/header/PipelinePageEditActions.js +1 -2
- package/dist/pages/pipelines/components/header/PipelinePageRunActions.js +1 -7
- package/dist/styles.css +6 -6
- package/package.json +3 -3
- package/dist/pages/pipelines/canvas/panel/PipelineCanvasPanelTabHeader.d.ts +0 -3
- package/dist/pages/pipelines/canvas/panel/PipelineCanvasPanelTabHeader.js +0 -35
- package/dist/pages/pipelines/canvas/panel/types.d.ts +0 -4
- package/dist/pages/pipelines/canvas/panel/types.js +0 -8
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import BaseHeader, { BaseHeaderSize } from "../../../../components/BaseHeader.js";
|
|
2
|
-
import { ArrowLeftIcon, TrashIcon } from "@phosphor-icons/react";
|
|
2
|
+
import { ArrowLeftIcon, TrashIcon, XIcon } from "@phosphor-icons/react";
|
|
3
3
|
import Button, { ButtonSize, ButtonVariant } from "@galaxy-io/dls/buttons/Button";
|
|
4
4
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
5
5
|
import Flex, { AlignItems } from "@galaxy-io/dls/layout/Flex";
|
|
6
6
|
import FlexItem from "@galaxy-io/dls/layout/FlexItem";
|
|
7
7
|
import Divider from "@galaxy-io/dls/layout/Divider";
|
|
8
8
|
//#region src/pages/pipelines/canvas/panel/PipelineCanvasPanelHeader.tsx
|
|
9
|
-
var PipelineCanvasPanelHeader = ({ title, description, icon, tile, onBack, onClose, onDelete }) => /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsxs(Flex, {
|
|
9
|
+
var PipelineCanvasPanelHeader = ({ title, description, icon, tile, actions, hasDivider, onBack, onClose, onDelete }) => /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsxs(Flex, {
|
|
10
10
|
alignItems: AlignItems.CENTER,
|
|
11
11
|
gap: 8,
|
|
12
12
|
padding: [8, 12],
|
|
@@ -20,8 +20,7 @@ var PipelineCanvasPanelHeader = ({ title, description, icon, tile, onBack, onClo
|
|
|
20
20
|
variant: ButtonVariant.SECONDARY,
|
|
21
21
|
size: ButtonSize.SMALL,
|
|
22
22
|
onClick: onBack,
|
|
23
|
-
ariaLabel: "Back to configuration"
|
|
24
|
-
tooltip: "Back to configuration"
|
|
23
|
+
ariaLabel: "Back to configuration"
|
|
25
24
|
})
|
|
26
25
|
}),
|
|
27
26
|
tile && /* @__PURE__ */ jsx(FlexItem, {
|
|
@@ -36,18 +35,26 @@ var PipelineCanvasPanelHeader = ({ title, description, icon, tile, onBack, onClo
|
|
|
36
35
|
title,
|
|
37
36
|
description,
|
|
38
37
|
icon,
|
|
39
|
-
actions:
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
38
|
+
actions: [
|
|
39
|
+
...actions ?? [],
|
|
40
|
+
onDelete && /* @__PURE__ */ jsx(Button, {
|
|
41
|
+
icon: TrashIcon,
|
|
42
|
+
variant: ButtonVariant.SECONDARY,
|
|
43
|
+
size: ButtonSize.SMALL,
|
|
44
|
+
onClick: onDelete,
|
|
45
|
+
ariaLabel: "Delete"
|
|
46
|
+
}, "delete"),
|
|
47
|
+
onClose && /* @__PURE__ */ jsx(Button, {
|
|
48
|
+
icon: XIcon,
|
|
49
|
+
variant: ButtonVariant.SECONDARY,
|
|
50
|
+
size: ButtonSize.SMALL,
|
|
51
|
+
onClick: onClose,
|
|
52
|
+
ariaLabel: "Close"
|
|
53
|
+
}, "close")
|
|
54
|
+
]
|
|
48
55
|
})
|
|
49
56
|
})
|
|
50
57
|
]
|
|
51
|
-
}), /* @__PURE__ */ jsx(Divider, {})] });
|
|
58
|
+
}), hasDivider && /* @__PURE__ */ jsx(Divider, {})] });
|
|
52
59
|
//#endregion
|
|
53
60
|
export { PipelineCanvasPanelHeader as default };
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { usePipelineCanvasSelection } from "../hooks/usePipelineCanvasSelection.js";
|
|
2
|
+
import { PIPELINE_CANVAS_PANEL_MAIN_ID, PIPELINE_CANVAS_PANEL_SIDEBAR_STORAGE_KEY } from "./constants.js";
|
|
3
|
+
import PipelineCanvasPanel from "./PipelineCanvasPanel.js";
|
|
4
|
+
import PipelineCanvasPanelColumn from "./PipelineCanvasPanelColumn.js";
|
|
5
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
6
|
+
import ResizablePanels, { ResizablePanel } from "@galaxy-io/dls/layout/ResizablePanels";
|
|
7
|
+
//#region src/pages/pipelines/canvas/panel/PipelineCanvasPanelLayout.tsx
|
|
8
|
+
var PipelineCanvasPanelLayout = ({ children }) => {
|
|
9
|
+
const { showPanel } = usePipelineCanvasSelection();
|
|
10
|
+
return /* @__PURE__ */ jsxs(ResizablePanels, {
|
|
11
|
+
hasDividers: true,
|
|
12
|
+
storageKey: PIPELINE_CANVAS_PANEL_SIDEBAR_STORAGE_KEY,
|
|
13
|
+
children: [/* @__PURE__ */ jsx(ResizablePanel, {
|
|
14
|
+
id: PIPELINE_CANVAS_PANEL_MAIN_ID,
|
|
15
|
+
min: 240,
|
|
16
|
+
children: /* @__PURE__ */ jsx(PipelineCanvasPanelColumn, { children })
|
|
17
|
+
}), showPanel && /* @__PURE__ */ jsx(ResizablePanel, {
|
|
18
|
+
id: "pipeline-canvas-sidebar",
|
|
19
|
+
ariaLabel: "Configuration",
|
|
20
|
+
defaultValue: 420,
|
|
21
|
+
min: 320,
|
|
22
|
+
max: 760,
|
|
23
|
+
children: /* @__PURE__ */ jsx(PipelineCanvasPanel, {})
|
|
24
|
+
})]
|
|
25
|
+
});
|
|
26
|
+
};
|
|
27
|
+
//#endregion
|
|
28
|
+
export { PipelineCanvasPanelLayout as default };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { usePipelineCanvasSelection } from "../hooks/usePipelineCanvasSelection.js";
|
|
2
|
+
import { SidebarSimpleIcon } from "@phosphor-icons/react";
|
|
3
|
+
import Button, { ButtonSize, ButtonVariant } from "@galaxy-io/dls/buttons/Button";
|
|
4
|
+
import { jsx } from "react/jsx-runtime";
|
|
5
|
+
//#region src/pages/pipelines/canvas/panel/PipelineCanvasPanelOpenButton.tsx
|
|
6
|
+
var PipelineCanvasPanelOpenButton = () => {
|
|
7
|
+
const { showPanel, setShowPanel } = usePipelineCanvasSelection();
|
|
8
|
+
if (showPanel) return null;
|
|
9
|
+
return /* @__PURE__ */ jsx(Button, {
|
|
10
|
+
icon: SidebarSimpleIcon,
|
|
11
|
+
variant: ButtonVariant.SECONDARY,
|
|
12
|
+
size: ButtonSize.MEDIUM,
|
|
13
|
+
ariaLabel: "Open configuration panel",
|
|
14
|
+
onClick: () => setShowPanel(true)
|
|
15
|
+
});
|
|
16
|
+
};
|
|
17
|
+
//#endregion
|
|
18
|
+
export { PipelineCanvasPanelOpenButton as default };
|
|
@@ -1,3 +1,7 @@
|
|
|
1
1
|
import { FC } from 'react';
|
|
2
|
-
|
|
2
|
+
import { RunInfo } from '../../../../../gen/ingestion/v1/runs_pb';
|
|
3
|
+
interface PipelineCanvasPanelActivityProps {
|
|
4
|
+
runIds: RunInfo["id"][];
|
|
5
|
+
}
|
|
6
|
+
declare const PipelineCanvasPanelActivity: FC<PipelineCanvasPanelActivityProps>;
|
|
3
7
|
export default PipelineCanvasPanelActivity;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { getRunEventKey } from "./utils.js";
|
|
1
|
+
import { useTailRunsStream } from "../../../../../api/queries/runs.js";
|
|
2
|
+
import { usePipelineCanvasPanelActivityStickToBottom } from "./hooks/usePipelineCanvasPanelActivityStickToBottom.js";
|
|
3
|
+
import { appendUnseenRunEvents, getRunEventKey } from "./utils.js";
|
|
4
4
|
import PipelineCanvasPanelActivityLine_default from "./PipelineCanvasPanelActivityLine.js";
|
|
5
5
|
/* empty css */
|
|
6
6
|
import { PulseIcon } from "@phosphor-icons/react";
|
|
7
|
-
import { useRef, useState } from "react";
|
|
7
|
+
import { useMemo, useRef, useState } from "react";
|
|
8
8
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
9
9
|
import Flex, { FlexDirection } from "@galaxy-io/dls/layout/Flex";
|
|
10
10
|
import Text, { TextSize, TextVariant } from "@galaxy-io/dls/text/Text";
|
|
@@ -16,8 +16,6 @@ import EmptyLayout from "@galaxy-io/dls/layout/EmptyLayout";
|
|
|
16
16
|
import { useVirtualizer } from "@tanstack/react-virtual";
|
|
17
17
|
import Flasher from "@galaxy-io/dls/transform/Flasher";
|
|
18
18
|
//#region src/pages/pipelines/canvas/panel/activity/PipelineCanvasPanelActivity.tsx
|
|
19
|
-
var ESTIMATED_LINE_HEIGHT = 18;
|
|
20
|
-
var LINE_GAP = 2;
|
|
21
19
|
var ActivityList = /*#__PURE__*/ styled("div")({
|
|
22
20
|
name: "ActivityList",
|
|
23
21
|
class: "filament-PipelineCanvasPanelActivity-ActivityList-admjy64",
|
|
@@ -28,20 +26,21 @@ var ActivityListLine = /*#__PURE__*/ styled("div")({
|
|
|
28
26
|
class: "filament-PipelineCanvasPanelActivity-ActivityListLine-ahvd670",
|
|
29
27
|
propsAsIs: false
|
|
30
28
|
});
|
|
31
|
-
var PipelineCanvasPanelActivity = () => {
|
|
32
|
-
const { id } = usePipelineParams();
|
|
33
|
-
const { data: activeRunsData } = useListActivePipelineRunsQuery(id);
|
|
34
|
-
const [runIds, setRunIds] = useState([]);
|
|
35
|
-
const mergedRunIds = [.../* @__PURE__ */ new Set([...runIds, ...(activeRunsData?.runs ?? []).map((run) => run.id)])].slice(-8);
|
|
36
|
-
if (mergedRunIds.join("|") !== runIds.join("|")) setRunIds(mergedRunIds);
|
|
29
|
+
var PipelineCanvasPanelActivity = ({ runIds }) => {
|
|
37
30
|
const { events, isStreaming } = useTailRunsStream(runIds);
|
|
38
31
|
const bodyRef = useRef(null);
|
|
32
|
+
const contentRef = useRef(null);
|
|
33
|
+
const isPinned = usePipelineCanvasPanelActivityStickToBottom(bodyRef, contentRef, runIds.length > 0);
|
|
34
|
+
const [frozenEvents, setFrozenEvents] = useState(null);
|
|
35
|
+
if (!isPinned && frozenEvents === null) setFrozenEvents(events);
|
|
36
|
+
if (isPinned && frozenEvents !== null) setFrozenEvents(null);
|
|
37
|
+
const shownEvents = useMemo(() => frozenEvents ? appendUnseenRunEvents(frozenEvents, events) : events, [frozenEvents, events]);
|
|
39
38
|
const virtualizer = useVirtualizer({
|
|
40
|
-
count:
|
|
39
|
+
count: shownEvents.length,
|
|
41
40
|
getScrollElement: () => bodyRef.current,
|
|
42
|
-
estimateSize: () =>
|
|
43
|
-
getItemKey: (index) => getRunEventKey(
|
|
44
|
-
gap:
|
|
41
|
+
estimateSize: () => 18,
|
|
42
|
+
getItemKey: (index) => getRunEventKey(shownEvents[index]),
|
|
43
|
+
gap: 2
|
|
45
44
|
});
|
|
46
45
|
if (runIds.length === 0) return /* @__PURE__ */ jsx(Flex, {
|
|
47
46
|
direction: FlexDirection.COLUMN,
|
|
@@ -59,8 +58,9 @@ var PipelineCanvasPanelActivity = () => {
|
|
|
59
58
|
children: /* @__PURE__ */ jsx(ScrollArea, {
|
|
60
59
|
ref: bodyRef,
|
|
61
60
|
children: /* @__PURE__ */ jsxs(Flex, {
|
|
61
|
+
ref: contentRef,
|
|
62
62
|
direction: FlexDirection.COLUMN,
|
|
63
|
-
gap:
|
|
63
|
+
gap: 2,
|
|
64
64
|
padding: [8, 12],
|
|
65
65
|
children: [/* @__PURE__ */ jsx(ActivityList, {
|
|
66
66
|
style: { height: virtualizer.getTotalSize() },
|
|
@@ -68,10 +68,10 @@ var PipelineCanvasPanelActivity = () => {
|
|
|
68
68
|
ref: virtualizer.measureElement,
|
|
69
69
|
"data-index": item.index,
|
|
70
70
|
style: { transform: `translateY(${item.start}px)` },
|
|
71
|
-
children: /* @__PURE__ */ jsx(PipelineCanvasPanelActivityLine_default, { event:
|
|
71
|
+
children: /* @__PURE__ */ jsx(PipelineCanvasPanelActivityLine_default, { event: shownEvents[item.index] })
|
|
72
72
|
}, item.key))
|
|
73
73
|
}), isStreaming && /* @__PURE__ */ jsx(Text, {
|
|
74
|
-
size: TextSize.
|
|
74
|
+
size: TextSize.BODY_SM,
|
|
75
75
|
variant: TextVariant.TERTIARY,
|
|
76
76
|
family: FontFamily.MONO,
|
|
77
77
|
children: /* @__PURE__ */ jsx(Flasher, {
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
interface PipelineCanvasPanelActivityHeaderProps {
|
|
3
|
+
isOpen: boolean;
|
|
4
|
+
onToggle: () => void;
|
|
5
|
+
}
|
|
6
|
+
declare const PipelineCanvasPanelActivityHeader: FC<PipelineCanvasPanelActivityHeaderProps>;
|
|
7
|
+
export default PipelineCanvasPanelActivityHeader;
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { RunStatus } from "../../../../../gen/ingestion/v1/runs_pb.js";
|
|
2
|
+
import PipelineRunStatusSwatch from "../../../../../components/runs/PipelineRunStatusSwatch.js";
|
|
3
|
+
import { usePipelineCanvasIsRunning } from "../../hooks/usePipelineCanvasIsRunning.js";
|
|
4
|
+
import PipelineCanvasPanelHeader from "../PipelineCanvasPanelHeader.js";
|
|
5
|
+
import { CaretDownIcon, CaretUpIcon, PulseIcon } from "@phosphor-icons/react";
|
|
6
|
+
import Button, { ButtonSize, ButtonVariant } from "@galaxy-io/dls/buttons/Button";
|
|
7
|
+
import { SquareSize } from "@galaxy-io/dls/shapes/Square";
|
|
8
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
9
|
+
import Flex, { AlignItems } from "@galaxy-io/dls/layout/Flex";
|
|
10
|
+
import Text, { TextSize, TextVariant } from "@galaxy-io/dls/text/Text";
|
|
11
|
+
//#region src/pages/pipelines/canvas/panel/activity/PipelineCanvasPanelActivityHeader.tsx
|
|
12
|
+
var PipelineCanvasPanelActivityHeader = ({ isOpen, onToggle }) => {
|
|
13
|
+
const isRunning = usePipelineCanvasIsRunning();
|
|
14
|
+
return /* @__PURE__ */ jsx(PipelineCanvasPanelHeader, {
|
|
15
|
+
title: "Activity",
|
|
16
|
+
icon: PulseIcon,
|
|
17
|
+
hasDivider: isOpen,
|
|
18
|
+
actions: [isRunning && /* @__PURE__ */ jsxs(Flex, {
|
|
19
|
+
alignItems: AlignItems.CENTER,
|
|
20
|
+
gap: 8,
|
|
21
|
+
shrink: 0,
|
|
22
|
+
children: [/* @__PURE__ */ jsx(PipelineRunStatusSwatch, {
|
|
23
|
+
status: RunStatus.RUNNING,
|
|
24
|
+
size: SquareSize.SMALL
|
|
25
|
+
}), /* @__PURE__ */ jsx(Text, {
|
|
26
|
+
as: "span",
|
|
27
|
+
size: TextSize.BODY_SM,
|
|
28
|
+
variant: TextVariant.SECONDARY,
|
|
29
|
+
children: "Running"
|
|
30
|
+
})]
|
|
31
|
+
}, "running"), /* @__PURE__ */ jsx(Button, {
|
|
32
|
+
icon: isOpen ? CaretDownIcon : CaretUpIcon,
|
|
33
|
+
ariaLabel: isOpen ? "Collapse activity" : "Expand activity",
|
|
34
|
+
variant: ButtonVariant.SECONDARY,
|
|
35
|
+
size: ButtonSize.SMALL,
|
|
36
|
+
onClick: onToggle
|
|
37
|
+
}, "toggle")]
|
|
38
|
+
});
|
|
39
|
+
};
|
|
40
|
+
//#endregion
|
|
41
|
+
export { PipelineCanvasPanelActivityHeader as default };
|
|
@@ -21,13 +21,13 @@ var PipelineCanvasPanelActivityLine = ({ event }) => {
|
|
|
21
21
|
children: [/* @__PURE__ */ jsx(FlexItem, {
|
|
22
22
|
shrink: 0,
|
|
23
23
|
children: /* @__PURE__ */ jsx(Text, {
|
|
24
|
-
size: TextSize.
|
|
24
|
+
size: TextSize.BODY_SM,
|
|
25
25
|
variant: TextVariant.TERTIARY,
|
|
26
26
|
family: FontFamily.MONO,
|
|
27
27
|
children: formatRunEventTime(event)
|
|
28
28
|
})
|
|
29
29
|
}), /* @__PURE__ */ jsx(Detail, { children: /* @__PURE__ */ jsxs(Text, {
|
|
30
|
-
size: TextSize.
|
|
30
|
+
size: TextSize.BODY_SM,
|
|
31
31
|
variant: getRunEventTextVariant(event),
|
|
32
32
|
family: FontFamily.MONO,
|
|
33
33
|
isSelectable: true,
|
|
@@ -1 +1,6 @@
|
|
|
1
|
+
import { Space } from '@galaxy-io/dls/theme/enums';
|
|
1
2
|
export declare const PIPELINE_CANVAS_PANEL_ACTIVITY_MAX_RUNS = 8;
|
|
3
|
+
export declare const PIPELINE_CANVAS_PANEL_ACTIVITY_ESTIMATED_LINE_HEIGHT = 18;
|
|
4
|
+
export declare const PIPELINE_CANVAS_PANEL_ACTIVITY_LINE_GAP: Space;
|
|
5
|
+
export declare const PIPELINE_CANVAS_PANEL_ACTIVITY_STICK_THRESHOLD_PX = 24;
|
|
6
|
+
export declare const PIPELINE_CANVAS_PANEL_ACTIVITY_UNPIN_KEYS: Set<string>;
|
package/dist/pages/pipelines/canvas/panel/activity/hooks/usePipelineCanvasPanelActivityRunIds.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const usePipelineCanvasPanelActivityRunIds: () => string[];
|
package/dist/pages/pipelines/canvas/panel/activity/hooks/usePipelineCanvasPanelActivityRunIds.js
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { usePipelineParams } from "../../../../../../module/hooks.js";
|
|
2
|
+
import { useListActivePipelineRunsQuery } from "../../../../../../api/queries/runs.js";
|
|
3
|
+
import { useState } from "react";
|
|
4
|
+
//#region src/pages/pipelines/canvas/panel/activity/hooks/usePipelineCanvasPanelActivityRunIds.ts
|
|
5
|
+
var usePipelineCanvasPanelActivityRunIds = () => {
|
|
6
|
+
const { id } = usePipelineParams();
|
|
7
|
+
const { data: activeRunsData } = useListActivePipelineRunsQuery(id);
|
|
8
|
+
const [runIds, setRunIds] = useState([]);
|
|
9
|
+
const mergedRunIds = [.../* @__PURE__ */ new Set([...runIds, ...(activeRunsData?.runs ?? []).map((run) => run.id)])].slice(-8);
|
|
10
|
+
if (mergedRunIds.join("|") !== runIds.join("|")) setRunIds(mergedRunIds);
|
|
11
|
+
return runIds;
|
|
12
|
+
};
|
|
13
|
+
//#endregion
|
|
14
|
+
export { usePipelineCanvasPanelActivityRunIds };
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { PIPELINE_CANVAS_PANEL_ACTIVITY_UNPIN_KEYS } from "../constants.js";
|
|
2
|
+
import { useEffect, useState } from "react";
|
|
3
|
+
//#region src/pages/pipelines/canvas/panel/activity/hooks/usePipelineCanvasPanelActivityStickToBottom.ts
|
|
4
|
+
var usePipelineCanvasPanelActivityStickToBottom = (scrollerRef, contentRef, isEnabled) => {
|
|
5
|
+
const [isPinned, setIsPinned] = useState(true);
|
|
6
|
+
useEffect(() => {
|
|
7
|
+
const scroller = scrollerRef.current;
|
|
8
|
+
const content = contentRef.current;
|
|
9
|
+
const root = scroller?.parentElement;
|
|
10
|
+
if (!isEnabled || !scroller || !content || !root) return;
|
|
11
|
+
let isPinnedNow = true;
|
|
12
|
+
const setPinned = (next) => {
|
|
13
|
+
if (isPinnedNow === next) return;
|
|
14
|
+
isPinnedNow = next;
|
|
15
|
+
setIsPinned(next);
|
|
16
|
+
};
|
|
17
|
+
const isAtBottom = () => scroller.scrollHeight - scroller.scrollTop - scroller.clientHeight <= 24;
|
|
18
|
+
const scrollToBottom = () => {
|
|
19
|
+
if (isPinnedNow) scroller.scrollTop = scroller.scrollHeight;
|
|
20
|
+
};
|
|
21
|
+
const repinAtBottom = () => {
|
|
22
|
+
if (isAtBottom()) setPinned(true);
|
|
23
|
+
};
|
|
24
|
+
const unpin = () => setPinned(false);
|
|
25
|
+
const handleWheel = (event) => {
|
|
26
|
+
if (event.deltaY < 0) unpin();
|
|
27
|
+
};
|
|
28
|
+
const handleKeyDown = (event) => {
|
|
29
|
+
if (PIPELINE_CANVAS_PANEL_ACTIVITY_UNPIN_KEYS.has(event.key)) unpin();
|
|
30
|
+
};
|
|
31
|
+
const observer = new ResizeObserver(scrollToBottom);
|
|
32
|
+
observer.observe(content);
|
|
33
|
+
observer.observe(scroller);
|
|
34
|
+
scroller.addEventListener("wheel", handleWheel, { passive: true });
|
|
35
|
+
scroller.addEventListener("keydown", handleKeyDown);
|
|
36
|
+
scroller.addEventListener("scroll", repinAtBottom, { passive: true });
|
|
37
|
+
root.addEventListener("pointerdown", unpin);
|
|
38
|
+
root.addEventListener("pointerup", repinAtBottom);
|
|
39
|
+
scrollToBottom();
|
|
40
|
+
return () => {
|
|
41
|
+
observer.disconnect();
|
|
42
|
+
scroller.removeEventListener("wheel", handleWheel);
|
|
43
|
+
scroller.removeEventListener("keydown", handleKeyDown);
|
|
44
|
+
scroller.removeEventListener("scroll", repinAtBottom);
|
|
45
|
+
root.removeEventListener("pointerdown", unpin);
|
|
46
|
+
root.removeEventListener("pointerup", repinAtBottom);
|
|
47
|
+
setIsPinned(true);
|
|
48
|
+
};
|
|
49
|
+
}, [
|
|
50
|
+
scrollerRef,
|
|
51
|
+
contentRef,
|
|
52
|
+
isEnabled
|
|
53
|
+
]);
|
|
54
|
+
return isPinned;
|
|
55
|
+
};
|
|
56
|
+
//#endregion
|
|
57
|
+
export { usePipelineCanvasPanelActivityStickToBottom };
|
|
@@ -4,3 +4,4 @@ export declare const formatRunEventTime: (event: RunEvent) => string;
|
|
|
4
4
|
export declare const getRunEventKey: (event: RunEvent) => number;
|
|
5
5
|
export declare const formatRunEventDetail: (event: RunEvent) => string;
|
|
6
6
|
export declare const getRunEventTextVariant: (event: RunEvent) => TextVariant;
|
|
7
|
+
export declare const appendUnseenRunEvents: (frozen: RunEvent[], live: RunEvent[]) => RunEvent[];
|
|
@@ -37,5 +37,10 @@ var getRunEventTextVariant = (event) => {
|
|
|
37
37
|
if (event.isReplay) return TextVariant.TERTIARY;
|
|
38
38
|
return TextVariant.SECONDARY;
|
|
39
39
|
};
|
|
40
|
+
var appendUnseenRunEvents = (frozen, live) => {
|
|
41
|
+
const frozenKeys = new Set(frozen.map(getRunEventKey));
|
|
42
|
+
const unseen = live.filter((event) => !frozenKeys.has(getRunEventKey(event)));
|
|
43
|
+
return unseen.length > 0 ? [...frozen, ...unseen] : frozen;
|
|
44
|
+
};
|
|
40
45
|
//#endregion
|
|
41
|
-
export { formatRunEventDetail, formatRunEventTime, getRunEventKey, getRunEventTextVariant };
|
|
46
|
+
export { appendUnseenRunEvents, formatRunEventDetail, formatRunEventTime, getRunEventKey, getRunEventTextVariant };
|
|
@@ -1,7 +1,15 @@
|
|
|
1
|
-
import { Space } from '@galaxy-io/dls/theme/enums';
|
|
2
1
|
import { PipelineCanvasNodeType } from '../types';
|
|
3
|
-
export declare const
|
|
4
|
-
export declare const
|
|
5
|
-
export declare const
|
|
6
|
-
export declare const
|
|
2
|
+
export declare const PIPELINE_CANVAS_PANEL_MAIN_ID = "pipeline-canvas-main";
|
|
3
|
+
export declare const PIPELINE_CANVAS_PANEL_VIEW_ID = "pipeline-canvas-view";
|
|
4
|
+
export declare const PIPELINE_CANVAS_PANEL_SIDEBAR_ID = "pipeline-canvas-sidebar";
|
|
5
|
+
export declare const PIPELINE_CANVAS_PANEL_ACTIVITY_ID = "pipeline-canvas-activity";
|
|
6
|
+
export declare const PIPELINE_CANVAS_PANEL_MAIN_MIN_SIZE = 240;
|
|
7
|
+
export declare const PIPELINE_CANVAS_PANEL_SIDEBAR_WIDTH = 420;
|
|
8
|
+
export declare const PIPELINE_CANVAS_PANEL_SIDEBAR_MIN_WIDTH = 320;
|
|
9
|
+
export declare const PIPELINE_CANVAS_PANEL_SIDEBAR_MAX_WIDTH = 760;
|
|
10
|
+
export declare const PIPELINE_CANVAS_PANEL_ACTIVITY_HEIGHT = 320;
|
|
11
|
+
export declare const PIPELINE_CANVAS_PANEL_ACTIVITY_MIN_HEIGHT = 160;
|
|
12
|
+
export declare const PIPELINE_CANVAS_PANEL_ACTIVITY_MAX_HEIGHT = 640;
|
|
13
|
+
export declare const PIPELINE_CANVAS_PANEL_SIDEBAR_STORAGE_KEY = "filament:pipeline-canvas:sidebar";
|
|
14
|
+
export declare const PIPELINE_CANVAS_PANEL_ACTIVITY_STORAGE_KEY = "filament:pipeline-canvas:activity";
|
|
7
15
|
export declare const PIPELINE_CANVAS_NODE_TYPE_TO_RESOURCE_EMPTY_MESSAGE_MAP: Record<PipelineCanvasNodeType, string>;
|
|
@@ -1,9 +1,15 @@
|
|
|
1
1
|
import { PipelineCanvasNodeType } from "../types.js";
|
|
2
2
|
//#region src/pages/pipelines/canvas/panel/constants.ts
|
|
3
|
+
var PIPELINE_CANVAS_PANEL_MAIN_ID = "pipeline-canvas-main";
|
|
4
|
+
var PIPELINE_CANVAS_PANEL_VIEW_ID = "pipeline-canvas-view";
|
|
5
|
+
var PIPELINE_CANVAS_PANEL_SIDEBAR_ID = "pipeline-canvas-sidebar";
|
|
6
|
+
var PIPELINE_CANVAS_PANEL_ACTIVITY_ID = "pipeline-canvas-activity";
|
|
7
|
+
var PIPELINE_CANVAS_PANEL_SIDEBAR_STORAGE_KEY = "filament:pipeline-canvas:sidebar";
|
|
8
|
+
var PIPELINE_CANVAS_PANEL_ACTIVITY_STORAGE_KEY = "filament:pipeline-canvas:activity";
|
|
3
9
|
var PIPELINE_CANVAS_NODE_TYPE_TO_RESOURCE_EMPTY_MESSAGE_MAP = {
|
|
4
10
|
[PipelineCanvasNodeType.SOURCE]: "Connect this source to a sink to route resources.",
|
|
5
11
|
[PipelineCanvasNodeType.SINK]: "Connect a source to this sink to route resources.",
|
|
6
12
|
[PipelineCanvasNodeType.PLACEHOLDER]: "Connect a source to a sink to route resources."
|
|
7
13
|
};
|
|
8
14
|
//#endregion
|
|
9
|
-
export { PIPELINE_CANVAS_NODE_TYPE_TO_RESOURCE_EMPTY_MESSAGE_MAP };
|
|
15
|
+
export { PIPELINE_CANVAS_NODE_TYPE_TO_RESOURCE_EMPTY_MESSAGE_MAP, PIPELINE_CANVAS_PANEL_ACTIVITY_ID, PIPELINE_CANVAS_PANEL_ACTIVITY_STORAGE_KEY, PIPELINE_CANVAS_PANEL_MAIN_ID, PIPELINE_CANVAS_PANEL_SIDEBAR_ID, PIPELINE_CANVAS_PANEL_SIDEBAR_STORAGE_KEY, PIPELINE_CANVAS_PANEL_VIEW_ID };
|
|
@@ -2,6 +2,7 @@ import { PipelineCanvasNodeType } from "../../../types.js";
|
|
|
2
2
|
import { ConnectorTileSize } from "../../../../../../components/connections/types.js";
|
|
3
3
|
import ConnectorTile from "../../../../../../components/connections/ConnectorTile.js";
|
|
4
4
|
import ConnectionKindChip from "../../../../../../components/connections/ConnectionKindChip.js";
|
|
5
|
+
import ConnectorNameChips from "../../../../../../components/connections/ConnectorNameChips.js";
|
|
5
6
|
import KeyValueList from "../../../../../../components/KeyValueList.js";
|
|
6
7
|
import KeyValueListRow from "../../../../../../components/KeyValueListRow.js";
|
|
7
8
|
import { usePipelineNodeConfig } from "../../../../components/node/hooks/usePipelineNodeConfig.js";
|
|
@@ -52,6 +53,7 @@ var PipelineCanvasPanelNodeDetail = ({ node }) => {
|
|
|
52
53
|
}),
|
|
53
54
|
onBack: clearSelection,
|
|
54
55
|
onClose: () => setShowPanel(false),
|
|
56
|
+
hasDivider: true,
|
|
55
57
|
onDelete: isReadOnly ? void 0 : () => {
|
|
56
58
|
removeNode(node.id);
|
|
57
59
|
clearSelection();
|
|
@@ -68,9 +70,12 @@ var PipelineCanvasPanelNodeDetail = ({ node }) => {
|
|
|
68
70
|
variant: BoxVariant.SECONDARY,
|
|
69
71
|
children: [/* @__PURE__ */ jsx(KeyValueListRow, {
|
|
70
72
|
label: "Connector",
|
|
71
|
-
value: /* @__PURE__ */ jsx(
|
|
73
|
+
value: connection ? /* @__PURE__ */ jsx(ConnectorNameChips, {
|
|
74
|
+
connector: connection.connector,
|
|
75
|
+
kind
|
|
76
|
+
}) : /* @__PURE__ */ jsx(Text, {
|
|
72
77
|
size: TextSize.BODY_SM,
|
|
73
|
-
children:
|
|
78
|
+
children: EMPTY_VALUE
|
|
74
79
|
})
|
|
75
80
|
}), /* @__PURE__ */ jsx(KeyValueListRow, {
|
|
76
81
|
label: "Kind",
|
package/dist/pages/pipelines/canvas/panel/overview/resource/PipelineCanvasPanelResourceSection.js
CHANGED
|
@@ -4,13 +4,13 @@ import { ConnectorTileSize } from "../../../../../../components/connections/type
|
|
|
4
4
|
import ConnectorTile from "../../../../../../components/connections/ConnectorTile.js";
|
|
5
5
|
import PipelineResourceCreateForm from "../../../../components/resource/PipelineResourceCreateForm.js";
|
|
6
6
|
import { PIPELINE_CANVAS_NODE_SINK_HANDLE_ID } from "../../../constants.js";
|
|
7
|
-
import { PIPELINE_CANVAS_NODE_TYPE_TO_RESOURCE_EMPTY_MESSAGE_MAP } from "../../constants.js";
|
|
8
7
|
import { isConnectionNode } from "../../../utils.js";
|
|
9
8
|
import { getCanvasEdgeResource } from "../../../graph/serialize.js";
|
|
10
9
|
import { canConnectEdge } from "../../../graph/rules.js";
|
|
11
10
|
import { usePipelineCanvasActions, usePipelineCanvasReadOnly, usePipelineCanvasState } from "../../../providers/canvas/PipelineCanvasProvider.js";
|
|
12
11
|
import { usePipelineCanvasSelection } from "../../../hooks/usePipelineCanvasSelection.js";
|
|
13
12
|
import PipelineTransformFieldsMarker from "../../../../components/transform/PipelineTransformFieldsMarker.js";
|
|
13
|
+
import { PIPELINE_CANVAS_NODE_TYPE_TO_RESOURCE_EMPTY_MESSAGE_MAP } from "../../constants.js";
|
|
14
14
|
import { usePipelineCanvasConnections } from "../../../hooks/usePipelineCanvasConnections.js";
|
|
15
15
|
import PipelineCanvasPanelItem from "../PipelineCanvasPanelItem.js";
|
|
16
16
|
import PipelineCanvasPanelSection from "../../PipelineCanvasPanelSection.js";
|
|
@@ -1,23 +1,22 @@
|
|
|
1
1
|
import { usePipelineCanvasSelection } from "../hooks/usePipelineCanvasSelection.js";
|
|
2
|
-
import PipelineCanvasPanel from "../panel/PipelineCanvasPanel.js";
|
|
3
2
|
import { usePipelineCanvasRoutes } from "./hooks/usePipelineCanvasRoutes.js";
|
|
4
3
|
import { usePipelineCanvasRoutesDraft } from "./hooks/usePipelineCanvasRoutesDraft.js";
|
|
5
4
|
import PipelineCanvasRoutesList from "./PipelineCanvasRoutesList.js";
|
|
6
5
|
import PipelineCanvasRoutesToolbar from "./PipelineCanvasRoutesToolbar.js";
|
|
7
6
|
import { useState } from "react";
|
|
8
|
-
import {
|
|
7
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
9
8
|
import Flex, { FlexDirection } from "@galaxy-io/dls/layout/Flex";
|
|
10
9
|
import Divider from "@galaxy-io/dls/layout/Divider";
|
|
11
10
|
//#region src/pages/pipelines/canvas/routes/PipelineCanvasRoutes.tsx
|
|
12
11
|
var PipelineCanvasRoutes = () => {
|
|
13
|
-
const { sinkIds
|
|
12
|
+
const { sinkIds } = usePipelineCanvasSelection();
|
|
14
13
|
const [search, setSearch] = useState("");
|
|
15
14
|
const { routes, hasRoutes } = usePipelineCanvasRoutes({
|
|
16
15
|
search,
|
|
17
16
|
sinkIds
|
|
18
17
|
});
|
|
19
18
|
const draft = usePipelineCanvasRoutesDraft();
|
|
20
|
-
return /* @__PURE__ */ jsxs(
|
|
19
|
+
return /* @__PURE__ */ jsxs(Flex, {
|
|
21
20
|
direction: FlexDirection.COLUMN,
|
|
22
21
|
height: "100%",
|
|
23
22
|
children: [
|
|
@@ -33,7 +32,7 @@ var PipelineCanvasRoutes = () => {
|
|
|
33
32
|
draftState: draft
|
|
34
33
|
})
|
|
35
34
|
]
|
|
36
|
-
})
|
|
35
|
+
});
|
|
37
36
|
};
|
|
38
37
|
//#endregion
|
|
39
38
|
export { PipelineCanvasRoutes as default };
|
|
@@ -61,6 +61,7 @@ var PipelineCanvasRoutesList = ({ routes, hasRoutes, draftState }) => {
|
|
|
61
61
|
onClick: handleBackgroundClick,
|
|
62
62
|
children: /* @__PURE__ */ jsx(ScrollArea, {
|
|
63
63
|
ref: scrollerRef,
|
|
64
|
+
canScrollHorizontally: true,
|
|
64
65
|
children: /* @__PURE__ */ jsx(ListInner, {
|
|
65
66
|
style: { height: virtualizer.getTotalSize() },
|
|
66
67
|
children: virtualizer.getVirtualItems().map((item) => /* @__PURE__ */ jsx(ListRowSlot, {
|
|
@@ -3,6 +3,7 @@ import { ConnectorTileSize } from "../../../../components/connections/types.js";
|
|
|
3
3
|
import ConnectorTile from "../../../../components/connections/ConnectorTile.js";
|
|
4
4
|
import { usePipelineCanvasSelection } from "../hooks/usePipelineCanvasSelection.js";
|
|
5
5
|
import PipelineCanvasViewSwitcher from "../PipelineCanvasViewSwitcher.js";
|
|
6
|
+
import PipelineCanvasPanelOpenButton from "../panel/PipelineCanvasPanelOpenButton.js";
|
|
6
7
|
import { usePipelineCanvasRoutesSinks } from "./hooks/usePipelineCanvasRoutesSinks.js";
|
|
7
8
|
import { PlusIcon } from "@phosphor-icons/react";
|
|
8
9
|
import Button, { ButtonSize, ButtonVariant } from "@galaxy-io/dls/buttons/Button";
|
|
@@ -75,7 +76,8 @@ var PipelineCanvasRoutesToolbar = ({ onSearch, canAddRoute, onAddRoute }) => {
|
|
|
75
76
|
variant: ButtonVariant.SECONDARY,
|
|
76
77
|
size: ButtonSize.MEDIUM,
|
|
77
78
|
onClick: onAddRoute
|
|
78
|
-
})
|
|
79
|
+
}),
|
|
80
|
+
/* @__PURE__ */ jsx(PipelineCanvasPanelOpenButton, {})
|
|
79
81
|
]
|
|
80
82
|
});
|
|
81
83
|
};
|
|
@@ -9,6 +9,7 @@ export declare const PIPELINE_CANVAS_ROUTES_OVERSCAN = 6;
|
|
|
9
9
|
export declare const PIPELINE_CANVAS_ROUTES_EDGE_CONTROL_INSET = 24;
|
|
10
10
|
export declare const PIPELINE_CANVAS_ROUTES_EDGE_CONTROL_GAP: Space;
|
|
11
11
|
export declare const PIPELINE_CANVAS_ROUTES_EDGE_MIN_WIDTH = 560;
|
|
12
|
+
export declare const PIPELINE_CANVAS_ROUTES_ROW_MIN_WIDTH: number;
|
|
12
13
|
export declare const PIPELINE_CANVAS_ROUTES_EDGE_HIT_PADDING = 4;
|
|
13
14
|
export declare const PIPELINE_CANVAS_ROUTES_EDGE_FAN_CONTROL_X = 22;
|
|
14
15
|
export declare const PIPELINE_CANVAS_ROUTES_EDGE_FAN_END_X = 28;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { FitViewOptions } from '@xyflow/react';
|
|
2
1
|
import { Theme } from '@galaxy-io/dls/theme/tokens/types';
|
|
3
2
|
import { EdgeValidation } from '../../../gen/ingestion/v1/capabilities_pb';
|
|
4
3
|
import { ReadMode, WriteMode } from '../../../gen/ingestion/v1/common_pb';
|
|
@@ -26,8 +25,6 @@ interface PipelineCanvasEdgeStatusConfig {
|
|
|
26
25
|
export declare const getEdgeResourceStatus: ({ hasReadLevers, resource, columns, cursorOptions, isManagedIncremental, hasPrimaryKey, }: PipelineCanvasEdgeStatusResources, { verdict, readMode, writeMode, cursor }: PipelineCanvasEdgeStatusConfig) => PipelineResourceStatus | undefined;
|
|
27
26
|
export declare const hasSiblingIncrementalRead: (edges: CanvasEdge[], { source, target }: Pick<CanvasEdge, "source" | "target">, excludedEdgeId?: CanvasEdge["id"]) => boolean;
|
|
28
27
|
export declare const getTransformStepCount: (transform: PipelineCanvasEdgeTransform | undefined, resource: PipelineEdge["resource"]) => number;
|
|
29
|
-
export declare const getPipelineCanvasFitPadding: (showPanel: boolean) => NonNullable<FitViewOptions["padding"]>;
|
|
30
|
-
export declare const getPipelineCanvasFitViewOptions: (showPanel: boolean) => FitViewOptions;
|
|
31
28
|
export declare const mapElementsToSelected: <T extends {
|
|
32
29
|
id: string;
|
|
33
30
|
selected?: boolean;
|
|
@@ -31,16 +31,6 @@ var getTransformStepCount = (transform, resource) => {
|
|
|
31
31
|
if (resources === void 0 || !isJsonObject(resources)) return 0;
|
|
32
32
|
return getTransformEntryStepCount(resources[resource]);
|
|
33
33
|
};
|
|
34
|
-
var getPipelineCanvasFitPadding = (showPanel) => ({
|
|
35
|
-
top: `48px`,
|
|
36
|
-
bottom: `48px`,
|
|
37
|
-
left: `80px`,
|
|
38
|
-
right: `${32 + (showPanel ? 540 : 28)}px`
|
|
39
|
-
});
|
|
40
|
-
var getPipelineCanvasFitViewOptions = (showPanel) => ({
|
|
41
|
-
padding: getPipelineCanvasFitPadding(showPanel),
|
|
42
|
-
maxZoom: 1
|
|
43
|
-
});
|
|
44
34
|
var mapElementsToSelected = (elements, selectedId) => elements.map((element) => {
|
|
45
35
|
const selected = element.id === selectedId;
|
|
46
36
|
return element.selected === selected ? element : {
|
|
@@ -75,4 +65,4 @@ var mapCanvasNodesToFlowEndpoints = (nodes) => ({
|
|
|
75
65
|
var isConnectionNode = (node) => node.type === PipelineCanvasNodeType.SOURCE || node.type === PipelineCanvasNodeType.SINK;
|
|
76
66
|
var isPipelineCanvasConnectionDisabled = (connection, isSourceDisabled) => isSourceDisabled && connection.kind === ConnectorKind.SOURCE;
|
|
77
67
|
//#endregion
|
|
78
|
-
export { getDefaultDestinationResource, getEdgeModeOptions, getEdgeResourceStatus,
|
|
68
|
+
export { getDefaultDestinationResource, getEdgeModeOptions, getEdgeResourceStatus, getTransformStepCount, hasSiblingIncrementalRead, isConnectionNode, isPipelineCanvasConnectionDisabled, mapCanvasNodesToFlowEndpoints, mapEdgesToStyledEdges, mapElementsToSelected };
|