@galaxy-io/filament-ui 0.15.0 → 0.17.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/README.md +8 -1
- package/dist/components/ListSearch.js +4 -1
- package/dist/gen/ingestion/v1/transformations_pb.d.ts +6 -1
- package/dist/gen/ingestion/v1/transformations_pb.js +1 -1
- package/dist/module/FilamentLayout.d.ts +2 -0
- package/dist/module/FilamentLayout.js +43 -38
- package/dist/module/GalaxyProductsProvider.d.ts +8 -0
- package/dist/module/GalaxyProductsProvider.js +11 -0
- package/dist/module/commands.js +2 -2
- package/dist/module/constants.d.ts +2 -1
- package/dist/module/constants.js +3 -2
- package/dist/module/nav.js +1 -1
- package/dist/module/paths.d.ts +3 -1
- package/dist/module/paths.js +2 -1
- package/dist/module/schemas.js +1 -1
- package/dist/module/types.d.ts +5 -0
- package/dist/module/types.js +6 -1
- package/dist/pages/connections/ConnectionsPage.js +1 -1
- package/dist/pages/connections/components/create/select/CreateConnectionSelectorBody.js +2 -0
- package/dist/pages/connections/components/drawer/ConnectionDrawerActions.js +13 -3
- package/dist/pages/connections/components/form/ConnectionForm.js +8 -4
- package/dist/pages/connections/constants.d.ts +3 -0
- package/dist/pages/connections/constants.js +6 -1
- package/dist/pages/observability/ObservabilityPage.js +1 -1
- package/dist/pages/observability/components/setup/constants.js +1 -1
- package/dist/pages/pipelines/canvas/PipelineCanvasConnectionSelector.d.ts +1 -0
- package/dist/pages/pipelines/canvas/PipelineCanvasConnectionSelector.js +5 -1
- package/dist/pages/pipelines/canvas/PipelineCanvasEditWidget.js +1 -1
- package/dist/pages/pipelines/canvas/panel/overview/resource/PipelineCanvasPanelResourceDetail.js +1 -0
- package/dist/pages/pipelines/canvas/routes/PipelineCanvasRoutesToolbar.js +4 -0
- package/dist/pages/pipelines/components/create/components/CreatePipelineModalFooter.js +6 -4
- package/dist/pages/pipelines/components/create/steps/CreatePipelineModalResources.js +2 -0
- package/dist/pages/pipelines/components/create/steps/components/CreatePipelineModalResourcesColumnsPane.js +2 -0
- package/dist/pages/pipelines/components/header/PipelinePageRunActions.js +1 -1
- package/dist/pages/pipelines/components/run/PipelineRunModal.js +2 -0
- package/dist/pages/pipelines/components/run/PipelineRunModalResourcesPane.js +2 -0
- package/dist/pages/pipelines/components/transform/PipelineTransformFieldsProvider.d.ts +1 -0
- package/dist/pages/pipelines/components/transform/PipelineTransformFieldsProvider.js +3 -1
- package/dist/pages/pipelines/components/transform/hooks/usePipelineTransformFieldsIssues.js +3 -2
- package/dist/pages/pipelines/components/transform/hooks/usePipelineTransformFieldsValidation.js +5 -3
- package/dist/pages/pipelines/components/transform/types.d.ts +1 -0
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -40,7 +40,7 @@ pnpm check:host # type-check and build the fixture host against the package
|
|
|
40
40
|
|
|
41
41
|
| Subpath | What |
|
|
42
42
|
|---|---|
|
|
43
|
-
| `./paths` | `FilamentPath` and `
|
|
43
|
+
| `./paths` | `FilamentPath`, `createFilamentHref` and `createFilamentFlowSearch` |
|
|
44
44
|
| `./routes` | one `*RouteOptions` per page, plus `filamentLayoutRouteOptions` and `filamentNotFoundRouteOptions` |
|
|
45
45
|
| `./FilamentLayout` | the shell, its sidebar and the URL-driven drawer and modals |
|
|
46
46
|
| `./commands` | `useFilamentCommandItems({ base, transport })` for a host command palette |
|
|
@@ -62,6 +62,13 @@ pnpm check:host # type-check and build the fixture host against the package
|
|
|
62
62
|
6. **Own the query client.** Filament works with TanStack's defaults. Skip retries for `NotFound`, `PermissionDenied`, `Unauthenticated`, `InvalidArgument` and `Unimplemented`, or a missing pipeline retries for about 7s before its not-found page. A `staleTime` of 30s is recommended.
|
|
63
63
|
7. **Proxy** `/ingestion.v1.IngestionService`, `/metrics.v1.MetricsService` and `/auth.v1.AuthService` to the Filament API at the transport's `baseUrl`. When another product also serves `metrics.v1.MetricsService`, put one product behind a prefix.
|
|
64
64
|
8. **Give the layout a box.** `FilamentLayout` fills its parent, so the parent needs a definite height (a flex child with `min-height: 0`).
|
|
65
|
+
9. **Tell Filament where the other Galaxy products live** with `productUrls` on `FilamentLayout`, keyed by `GalaxyProduct` from `./paths`. Each is the product's mount path on the same origin, such as `{ alchemy: "/functions" }`, or its full URL when it runs on its own domain. A product left out gets no links.
|
|
66
|
+
|
|
67
|
+
### Links into other Galaxy products
|
|
68
|
+
|
|
69
|
+
Galaxy products hand people to each other with one shape. The callee owns its link format in a component-free `./links` export, such as `createAlchemyFunctionHref` and `parseAlchemyReturnSearch` from `@galaxy-io/alchemy-ui/links`. The link carries a seed, a `returnTo` and a `returnLabel` naming the screen that asked, and the result comes back on `returnTo` as search keys prefixed with the callee's name, such as `alchemyFunctionId`. A cancel comes back without them.
|
|
70
|
+
|
|
71
|
+
Library code reads a product's URL with `useGalaxyProductUrl(GalaxyProduct.ALCHEMY)` and hides the entry point when it is undefined. The standalone server writes its runtime config into `index.html` as the JSON script `filament-runtime-config`, with `products` set by the `GALAXY_<PRODUCT>_URL` variables, and the standalone app passes them to `FilamentLayout`. Every product reads the same variables, and a callee sends people back only to the origins of the products it was given, so a standalone pair sets both URLs on both servers. A new product adds itself to `GalaxyProduct`, to `products` in `ui/config.go` and to `galaxy.productUrls` in the chart.
|
|
65
72
|
|
|
66
73
|
### Releasing
|
|
67
74
|
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import { useFilamentSearchUpdate, useListSearch } from "../module/hooks.js";
|
|
1
|
+
import { useFilamentLayoutSearch, useFilamentSearchUpdate, useListSearch } from "../module/hooks.js";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
3
|
import SearchInput from "@galaxy-io/dls/inputs/SearchInput";
|
|
4
4
|
//#region src/components/ListSearch.tsx
|
|
5
5
|
var ListSearch = ({ placeholder }) => {
|
|
6
6
|
const updateSearch = useFilamentSearchUpdate();
|
|
7
7
|
const { q = "" } = useListSearch();
|
|
8
|
+
const { flow } = useFilamentLayoutSearch();
|
|
8
9
|
const handleSearch = (term) => {
|
|
9
10
|
if (term === q) return;
|
|
10
11
|
updateSearch((prev) => ({
|
|
@@ -17,6 +18,8 @@ var ListSearch = ({ placeholder }) => {
|
|
|
17
18
|
placeholder: `${placeholder}...`,
|
|
18
19
|
defaultValue: q,
|
|
19
20
|
debounceMs: 300,
|
|
21
|
+
hotKeys: ["/"],
|
|
22
|
+
shouldBindHotKey: !flow,
|
|
20
23
|
onSearch: handleSearch,
|
|
21
24
|
fillWidth: true
|
|
22
25
|
});
|
|
@@ -161,7 +161,8 @@ export declare const ListTransformFunctionsResponseSchema: GenMessage<ListTransf
|
|
|
161
161
|
/**
|
|
162
162
|
* ValidateTransformRequest compiles a transform against one resource's
|
|
163
163
|
* schema, read from the source connection, exactly as a run would. The
|
|
164
|
-
* transform is the same JSON object an edge carries
|
|
164
|
+
* transform is the same JSON object an edge carries, and columns is the
|
|
165
|
+
* edge's column selection for the resource, empty when it reads every column.
|
|
165
166
|
*
|
|
166
167
|
* @generated from message ingestion.v1.ValidateTransformRequest
|
|
167
168
|
*/
|
|
@@ -178,6 +179,10 @@ export type ValidateTransformRequest = Message<"ingestion.v1.ValidateTransformRe
|
|
|
178
179
|
* @generated from field: google.protobuf.Struct transform = 3;
|
|
179
180
|
*/
|
|
180
181
|
transform?: JsonObject | undefined;
|
|
182
|
+
/**
|
|
183
|
+
* @generated from field: repeated string columns = 4;
|
|
184
|
+
*/
|
|
185
|
+
columns: string[];
|
|
181
186
|
};
|
|
182
187
|
/**
|
|
183
188
|
* Describes the message ingestion.v1.ValidateTransformRequest.
|
|
@@ -5,7 +5,7 @@ import { file_google_protobuf_struct } from "@bufbuild/protobuf/wkt";
|
|
|
5
5
|
/**
|
|
6
6
|
* Describes the file ingestion/v1/transformations.proto.
|
|
7
7
|
*/
|
|
8
|
-
var file_ingestion_v1_transformations = /*@__PURE__*/ fileDesc("
|
|
8
|
+
var file_ingestion_v1_transformations = /*@__PURE__*/ fileDesc("CiJpbmdlc3Rpb24vdjEvdHJhbnNmb3JtYXRpb25zLnByb3RvEgxpbmdlc3Rpb24udjEiNQodTGlzdFRyYW5zZm9ybUZ1bmN0aW9uc1JlcXVlc3QSFAoMbG9naWNhbF90eXBlGAEgASgJIp8BChFUcmFuc2Zvcm1Bcmd1bWVudBIMCgRuYW1lGAEgASgJEhUKDWxvZ2ljYWxfdHlwZXMYAiADKAkSEQoJaXNfY29sdW1uGAMgASgIEhIKCmlzX2xpdGVyYWwYBCABKAgSEwoLaXNfb3B0aW9uYWwYBSABKAgSEwoLaXNfdmFyaWFkaWMYBiABKAgSFAoMZGlzcGxheV9uYW1lGAcgASgJIp8CChFUcmFuc2Zvcm1GdW5jdGlvbhIMCgRuYW1lGAEgASgJEhMKC2Rlc2NyaXB0aW9uGAIgASgJEi0KBGFyZ3MYAyADKAsyHy5pbmdlc3Rpb24udjEuVHJhbnNmb3JtQXJndW1lbnQSDwoHcmV0dXJucxgEIAEoCRIUCgxkaXNwbGF5X25hbWUYBSABKAkSEQoJc2FtZV90eXBlGAYgASgIEhUKDXJldHVybnNfaW5wdXQYByABKAgSFwoPb3BlcmF0b3Jfc3ltYm9sGAggASgJEhoKEmNvbmRpdGlvbl9vcGVyYXRvchgJIAEoCBIaChJ2YXJpYWRpY19hZGRfbGFiZWwYCiABKAkSFgoOY29uZGl0aW9uX2pvaW4YCyABKAkihQEKHkxpc3RUcmFuc2Zvcm1GdW5jdGlvbnNSZXNwb25zZRIyCglmdW5jdGlvbnMYASADKAsyHy5pbmdlc3Rpb24udjEuVHJhbnNmb3JtRnVuY3Rpb24SFwoPZ3JhbW1hcl92ZXJzaW9uGAIgASgFEhYKDmdyYW1tYXJfc2NoZW1hGAMgASgJIocBChhWYWxpZGF0ZVRyYW5zZm9ybVJlcXVlc3QSHAoUc291cmNlX2Nvbm5lY3Rpb25faWQYASABKAkSEAoIcmVzb3VyY2UYAiABKAkSKgoJdHJhbnNmb3JtGAMgASgLMhcuZ29vZ2xlLnByb3RvYnVmLlN0cnVjdBIPCgdjb2x1bW5zGAQgAygJIj0KF1RyYW5zZm9ybUV4cHJlc3Npb25UeXBlEgwKBHBhdGgYASABKAkSFAoMbG9naWNhbF90eXBlGAIgASgJItABChlWYWxpZGF0ZVRyYW5zZm9ybVJlc3BvbnNlEg0KBXZhbGlkGAEgASgIEi0KBmlzc3VlcxgCIAMoCzIdLmluZ2VzdGlvbi52MS5WYWxpZGF0aW9uRXJyb3ISNAoOb3V0cHV0X2NvbHVtbnMYAyADKAsyHC5pbmdlc3Rpb24udjEuUmVzb3VyY2VDb2x1bW4SPwoQZXhwcmVzc2lvbl90eXBlcxgEIAMoCzIlLmluZ2VzdGlvbi52MS5UcmFuc2Zvcm1FeHByZXNzaW9uVHlwZWIGcHJvdG8z", [file_google_protobuf_struct, file_ingestion_v1_connectors]);
|
|
9
9
|
/**
|
|
10
10
|
* Describes the message ingestion.v1.ListTransformFunctionsRequest.
|
|
11
11
|
* Use `create(ListTransformFunctionsRequestSchema)` to create a new message.
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { FC, ReactNode } from 'react';
|
|
2
|
+
import { GalaxyProductUrls } from './types';
|
|
2
3
|
export interface FilamentLayoutProps {
|
|
3
4
|
sidebarFooter?: ReactNode;
|
|
5
|
+
productUrls?: GalaxyProductUrls;
|
|
4
6
|
}
|
|
5
7
|
declare const FilamentLayout: FC<FilamentLayoutProps>;
|
|
6
8
|
export default FilamentLayout;
|
|
@@ -7,11 +7,13 @@ import ConnectionDrawer from "../pages/connections/components/drawer/ConnectionD
|
|
|
7
7
|
import EditConnectionModal from "../pages/connections/components/edit/EditConnectionModal.js";
|
|
8
8
|
import CreatePipelineModal from "../pages/pipelines/components/create/CreatePipelineModal.js";
|
|
9
9
|
import PipelineRunModal from "../pages/pipelines/components/run/PipelineRunModal.js";
|
|
10
|
+
import { GALAXY_DEFAULT_PRODUCT_URLS } from "./constants.js";
|
|
11
|
+
import { GalaxyProductsProvider } from "./GalaxyProductsProvider.js";
|
|
10
12
|
import { useCallback } from "react";
|
|
11
13
|
import { Outlet } from "@tanstack/react-router";
|
|
12
|
-
import {
|
|
14
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
13
15
|
//#region src/module/FilamentLayout.tsx
|
|
14
|
-
var FilamentLayout = ({ sidebarFooter }) => {
|
|
16
|
+
var FilamentLayout = ({ sidebarFooter, productUrls = GALAXY_DEFAULT_PRODUCT_URLS }) => {
|
|
15
17
|
const updateSearch = useFilamentSearchUpdate();
|
|
16
18
|
const { connectionId, pipelineId, flow, connector, connectorKind, connectorSearch, sourceId, sinkIds, resources, resyncResources } = useFilamentLayoutSearch();
|
|
17
19
|
const handleCloseDrawer = useCallback(() => {
|
|
@@ -29,42 +31,45 @@ var FilamentLayout = ({ sidebarFooter }) => {
|
|
|
29
31
|
...createFilamentFlowCloseSearch(prev)
|
|
30
32
|
}), { replace: true });
|
|
31
33
|
}, [updateSearch]);
|
|
32
|
-
return /* @__PURE__ */ jsxs(
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
34
|
+
return /* @__PURE__ */ jsxs(GalaxyProductsProvider, {
|
|
35
|
+
productUrls,
|
|
36
|
+
children: [
|
|
37
|
+
/* @__PURE__ */ jsx(MainLayout, {
|
|
38
|
+
sidebarFooter,
|
|
39
|
+
children: /* @__PURE__ */ jsx(Outlet, {})
|
|
40
|
+
}),
|
|
41
|
+
/* @__PURE__ */ jsx(ConnectionDrawer, {
|
|
42
|
+
connectionId,
|
|
43
|
+
isOpen: !!connectionId,
|
|
44
|
+
onClose: handleCloseDrawer
|
|
45
|
+
}),
|
|
46
|
+
/* @__PURE__ */ jsx(CreateConnectionModal, {
|
|
47
|
+
isOpen: flow === Flow.CREATE_CONNECTION,
|
|
48
|
+
connector,
|
|
49
|
+
connectorKind,
|
|
50
|
+
connectorSearch,
|
|
51
|
+
onClose: handleCloseFlow
|
|
52
|
+
}),
|
|
53
|
+
/* @__PURE__ */ jsx(EditConnectionModal, {
|
|
54
|
+
isOpen: flow === Flow.EDIT_CONNECTION && !!connectionId,
|
|
55
|
+
connectionId,
|
|
56
|
+
onClose: handleCloseFlow
|
|
57
|
+
}),
|
|
58
|
+
/* @__PURE__ */ jsx(CreatePipelineModal, {
|
|
59
|
+
isOpen: flow === Flow.CREATE_PIPELINE,
|
|
60
|
+
sourceId,
|
|
61
|
+
sinkIds,
|
|
62
|
+
onClose: handleCloseFlow
|
|
63
|
+
}),
|
|
64
|
+
/* @__PURE__ */ jsx(PipelineRunModal, {
|
|
65
|
+
isOpen: flow === Flow.RUN_PIPELINE && !!pipelineId,
|
|
66
|
+
pipelineId,
|
|
67
|
+
resources,
|
|
68
|
+
resyncResources,
|
|
69
|
+
onClose: handleCloseFlow
|
|
70
|
+
})
|
|
71
|
+
]
|
|
72
|
+
});
|
|
68
73
|
};
|
|
69
74
|
//#endregion
|
|
70
75
|
export { FilamentLayout as default };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { FC, PropsWithChildren } from 'react';
|
|
2
|
+
import { GalaxyProduct, GalaxyProductUrls } from './types';
|
|
3
|
+
interface GalaxyProductsProviderProps {
|
|
4
|
+
productUrls: GalaxyProductUrls;
|
|
5
|
+
}
|
|
6
|
+
export declare const GalaxyProductsProvider: FC<PropsWithChildren<GalaxyProductsProviderProps>>;
|
|
7
|
+
export declare const useGalaxyProductUrl: (product: GalaxyProduct) => string | undefined;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { GALAXY_DEFAULT_PRODUCT_URLS } from "./constants.js";
|
|
2
|
+
import { createContext } from "react";
|
|
3
|
+
import { jsx } from "react/jsx-runtime";
|
|
4
|
+
//#region src/module/GalaxyProductsProvider.tsx
|
|
5
|
+
var GalaxyProductUrlsContext = createContext(GALAXY_DEFAULT_PRODUCT_URLS);
|
|
6
|
+
var GalaxyProductsProvider = ({ productUrls, children }) => /* @__PURE__ */ jsx(GalaxyProductUrlsContext.Provider, {
|
|
7
|
+
value: productUrls,
|
|
8
|
+
children
|
|
9
|
+
});
|
|
10
|
+
//#endregion
|
|
11
|
+
export { GalaxyProductsProvider };
|
package/dist/module/commands.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { FilamentNavItem, Flow } from "./types.js";
|
|
1
2
|
import { FilamentPath, createFilamentFlowSearch } from "./paths.js";
|
|
2
3
|
import { ConnectorKind } from "../gen/ingestion/v1/common_pb.js";
|
|
3
|
-
import { FilamentNavItem, Flow } from "./types.js";
|
|
4
4
|
import { useFilamentFlowOpen, useFilamentMountedBase, useFilamentSearchUpdate } from "./hooks.js";
|
|
5
5
|
import { FILAMENT_NAV_ITEMS, FILAMENT_NAV_ITEM_TO_COMMAND_ID_MAP, FILAMENT_NAV_ITEM_TO_ICON_MAP, FILAMENT_NAV_ITEM_TO_KEYWORDS_MAP, FILAMENT_NAV_ITEM_TO_LABEL_MAP, FILAMENT_NAV_ITEM_TO_PATH_MAP } from "./nav.js";
|
|
6
6
|
import { CONNECTOR_KIND_TO_CREATE_TITLE_MAP, CONNECTOR_KIND_TO_PATH_MAP } from "../components/connections/constants.js";
|
|
@@ -8,8 +8,8 @@ import { useListConnectionsQuery } from "../api/queries/connections.js";
|
|
|
8
8
|
import { PIPELINE_CREATE_TITLE } from "../components/pipelines/constants.js";
|
|
9
9
|
import { formatPipelineName } from "../components/pipelines/utils.js";
|
|
10
10
|
import { useListPipelinesQuery } from "../api/queries/pipelines.js";
|
|
11
|
-
import ConnectorCommandIcon from "../components/connections/ConnectorCommandIcon.js";
|
|
12
11
|
import { FILAMENT_COMMAND_GROUP_CONNECTIONS, FILAMENT_COMMAND_GROUP_CREATE, FILAMENT_COMMAND_GROUP_GO_TO, FILAMENT_COMMAND_GROUP_PIPELINES, FILAMENT_CONNECTOR_KIND_TO_CREATE_COMMAND_ID_MAP, FILAMENT_CONNECTOR_KIND_TO_NAV_ITEM_MAP } from "./constants.js";
|
|
12
|
+
import ConnectorCommandIcon from "../components/connections/ConnectorCommandIcon.js";
|
|
13
13
|
import { PlusIcon } from "@phosphor-icons/react";
|
|
14
14
|
import { useMemo } from "react";
|
|
15
15
|
import { useNavigate } from "@tanstack/react-router";
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { ConnectorKind } from '../gen/ingestion/v1/common_pb';
|
|
2
|
-
import { FilamentNavItem } from './types';
|
|
2
|
+
import { FilamentNavItem, GalaxyProductUrls } from './types';
|
|
3
3
|
export declare const FILAMENT_COMMAND_GROUP_GO_TO = "Go to";
|
|
4
4
|
export declare const FILAMENT_COMMAND_GROUP_CREATE = "Create";
|
|
5
5
|
export declare const FILAMENT_COMMAND_GROUP_PIPELINES = "Pipelines";
|
|
6
6
|
export declare const FILAMENT_COMMAND_GROUP_CONNECTIONS = "Connections";
|
|
7
7
|
export declare const FILAMENT_CONNECTOR_KIND_TO_NAV_ITEM_MAP: Record<ConnectorKind, FilamentNavItem>;
|
|
8
8
|
export declare const FILAMENT_CONNECTOR_KIND_TO_CREATE_COMMAND_ID_MAP: Record<ConnectorKind, string>;
|
|
9
|
+
export declare const GALAXY_DEFAULT_PRODUCT_URLS: GalaxyProductUrls;
|
package/dist/module/constants.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ConnectorKind } from "../gen/ingestion/v1/common_pb.js";
|
|
2
1
|
import { FilamentNavItem } from "./types.js";
|
|
2
|
+
import { ConnectorKind } from "../gen/ingestion/v1/common_pb.js";
|
|
3
3
|
//#region src/module/constants.ts
|
|
4
4
|
var FILAMENT_COMMAND_GROUP_GO_TO = "Go to";
|
|
5
5
|
var FILAMENT_COMMAND_GROUP_CREATE = "Create";
|
|
@@ -15,5 +15,6 @@ var FILAMENT_CONNECTOR_KIND_TO_CREATE_COMMAND_ID_MAP = {
|
|
|
15
15
|
[ConnectorKind.SOURCE]: "new-source",
|
|
16
16
|
[ConnectorKind.SINK]: "new-sink"
|
|
17
17
|
};
|
|
18
|
+
var GALAXY_DEFAULT_PRODUCT_URLS = {};
|
|
18
19
|
//#endregion
|
|
19
|
-
export { FILAMENT_COMMAND_GROUP_CONNECTIONS, FILAMENT_COMMAND_GROUP_CREATE, FILAMENT_COMMAND_GROUP_GO_TO, FILAMENT_COMMAND_GROUP_PIPELINES, FILAMENT_CONNECTOR_KIND_TO_CREATE_COMMAND_ID_MAP, FILAMENT_CONNECTOR_KIND_TO_NAV_ITEM_MAP };
|
|
20
|
+
export { FILAMENT_COMMAND_GROUP_CONNECTIONS, FILAMENT_COMMAND_GROUP_CREATE, FILAMENT_COMMAND_GROUP_GO_TO, FILAMENT_COMMAND_GROUP_PIPELINES, FILAMENT_CONNECTOR_KIND_TO_CREATE_COMMAND_ID_MAP, FILAMENT_CONNECTOR_KIND_TO_NAV_ITEM_MAP, GALAXY_DEFAULT_PRODUCT_URLS };
|
package/dist/module/nav.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { FilamentPath } from "./paths.js";
|
|
2
1
|
import { FilamentNavItem } from "./types.js";
|
|
2
|
+
import { FilamentPath } from "./paths.js";
|
|
3
3
|
import { ChartLineIcon, DatabaseIcon, FlowArrowIcon, TrayArrowDownIcon } from "@phosphor-icons/react";
|
|
4
4
|
//#region src/module/nav.ts
|
|
5
5
|
var FILAMENT_NAV_ITEMS = [
|
package/dist/module/paths.d.ts
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { FilamentFlowSeed, FilamentLayoutSearch } from './schemas';
|
|
2
|
-
import { Flow } from './types';
|
|
2
|
+
import { Flow, GalaxyProduct } from './types';
|
|
3
|
+
export type { GalaxyProductUrls } from './types';
|
|
4
|
+
export { GalaxyProduct };
|
|
3
5
|
export declare enum FilamentPath {
|
|
4
6
|
OBSERVABILITY = "./observability",
|
|
5
7
|
PIPELINES = "./pipelines",
|
package/dist/module/paths.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { GalaxyProduct } from "./types.js";
|
|
1
2
|
//#region src/module/paths.ts
|
|
2
3
|
var FilamentPath = /* @__PURE__ */ function(FilamentPath) {
|
|
3
4
|
FilamentPath["OBSERVABILITY"] = "./observability";
|
|
@@ -30,4 +31,4 @@ var createFilamentFlowSearch = (flow, seed = {}) => ({
|
|
|
30
31
|
flow
|
|
31
32
|
});
|
|
32
33
|
//#endregion
|
|
33
|
-
export { FilamentPath, createFilamentFlowSearch, createFilamentHref };
|
|
34
|
+
export { FilamentPath, GalaxyProduct, createFilamentFlowSearch, createFilamentHref };
|
package/dist/module/schemas.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { Flow } from "./types.js";
|
|
1
2
|
import { ConnectorKind } from "../gen/ingestion/v1/common_pb.js";
|
|
2
3
|
import { SortBy, SortOrder } from "../gen/ingestion/v1/sorting_pb.js";
|
|
3
4
|
import { RunStatus } from "../gen/ingestion/v1/runs_pb.js";
|
|
@@ -5,7 +6,6 @@ import { ObservabilityRefreshInterval, ObservabilityRunsView, ObservabilityThrou
|
|
|
5
6
|
import { MetricDimension } from "../gen/metrics/v1/metrics_pb.js";
|
|
6
7
|
import { PipelineCanvasView } from "../pages/pipelines/canvas/types.js";
|
|
7
8
|
import { SettingsTeamView } from "../pages/settings/types.js";
|
|
8
|
-
import { Flow } from "./types.js";
|
|
9
9
|
import z from "zod";
|
|
10
10
|
//#region src/module/schemas.ts
|
|
11
11
|
var listSearchParamsSchema = z.object({
|
package/dist/module/types.d.ts
CHANGED
package/dist/module/types.js
CHANGED
|
@@ -13,5 +13,10 @@ var FilamentNavItem = /* @__PURE__ */ function(FilamentNavItem) {
|
|
|
13
13
|
FilamentNavItem["SINKS"] = "SINKS";
|
|
14
14
|
return FilamentNavItem;
|
|
15
15
|
}({});
|
|
16
|
+
var GalaxyProduct = /* @__PURE__ */ function(GalaxyProduct) {
|
|
17
|
+
GalaxyProduct["ALCHEMY"] = "alchemy";
|
|
18
|
+
GalaxyProduct["FILAMENT"] = "filament";
|
|
19
|
+
return GalaxyProduct;
|
|
20
|
+
}({});
|
|
16
21
|
//#endregion
|
|
17
|
-
export { FilamentNavItem, Flow };
|
|
22
|
+
export { FilamentNavItem, Flow, GalaxyProduct };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ConnectorKind } from "../../gen/ingestion/v1/common_pb.js";
|
|
2
1
|
import { Flow } from "../../module/types.js";
|
|
2
|
+
import { ConnectorKind } from "../../gen/ingestion/v1/common_pb.js";
|
|
3
3
|
import { useConnectionsSearch, useFilamentFlowOpen, useFilamentSearchUpdate } from "../../module/hooks.js";
|
|
4
4
|
import { CONNECTOR_KIND_TO_CREATE_TITLE_MAP, CONNECTOR_KIND_TO_PLURAL_LABEL_MAP, CONNECTOR_KIND_TO_PLURAL_NOUN_MAP } from "../../components/connections/constants.js";
|
|
5
5
|
import { createListConnectionsInput, useSuspenseListConnectionsInfiniteQuery } from "../../api/queries/connections.js";
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { Flow } from "../../../../module/types.js";
|
|
2
|
-
import { useFilamentSearchUpdate } from "../../../../module/hooks.js";
|
|
2
|
+
import { useFilamentFlowOpen, useFilamentSearchUpdate } from "../../../../module/hooks.js";
|
|
3
3
|
import { DeleteConnectionRequestSchema } from "../../../../gen/ingestion/v1/connections_pb.js";
|
|
4
4
|
import { useDeleteConnectionMutation } from "../../../../api/queries/connections.js";
|
|
5
|
+
import { CONNECTOR_KIND_TO_PIPELINE_SEED_MAP } from "../../constants.js";
|
|
5
6
|
import { useConfirm } from "../../../../hooks/useConfirm.js";
|
|
6
|
-
import { DotsThreeIcon, PencilIcon, TrashIcon } from "@phosphor-icons/react";
|
|
7
|
+
import { DotsThreeIcon, FlowArrowIcon, PencilIcon, TrashIcon } from "@phosphor-icons/react";
|
|
7
8
|
import Button, { ButtonSize, ButtonVariant } from "@galaxy-io/dls/buttons/Button";
|
|
8
9
|
import { create } from "@bufbuild/protobuf";
|
|
9
10
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -12,6 +13,7 @@ import ConfirmDialog from "@galaxy-io/dls/modal/ConfirmDialog";
|
|
|
12
13
|
//#region src/pages/connections/components/drawer/ConnectionDrawerActions.tsx
|
|
13
14
|
var ConnectionDrawerActions = ({ connection, isOpen, onClose }) => {
|
|
14
15
|
const updateSearch = useFilamentSearchUpdate();
|
|
16
|
+
const openFlow = useFilamentFlowOpen();
|
|
15
17
|
const { mutate: deleteConnection } = useDeleteConnectionMutation();
|
|
16
18
|
const { handleOpen, isOpen: confirmIsOpen, target, handleClose, handleConfirm } = useConfirm({
|
|
17
19
|
entityLabel: "Connection",
|
|
@@ -22,6 +24,9 @@ var ConnectionDrawerActions = ({ connection, isOpen, onClose }) => {
|
|
|
22
24
|
onConfirmed: onClose
|
|
23
25
|
});
|
|
24
26
|
const isDeleted = !!connection.deletedAt;
|
|
27
|
+
const handleCreatePipeline = () => {
|
|
28
|
+
openFlow(Flow.CREATE_PIPELINE, CONNECTOR_KIND_TO_PIPELINE_SEED_MAP[connection.kind](connection.id));
|
|
29
|
+
};
|
|
25
30
|
const handleEdit = () => {
|
|
26
31
|
updateSearch((prev) => ({
|
|
27
32
|
...prev,
|
|
@@ -32,11 +37,16 @@ var ConnectionDrawerActions = ({ connection, isOpen, onClose }) => {
|
|
|
32
37
|
trigger: /* @__PURE__ */ jsx(Button, {
|
|
33
38
|
icon: DotsThreeIcon,
|
|
34
39
|
ariaLabel: "Connection actions",
|
|
35
|
-
tooltip: "Connection actions",
|
|
36
40
|
variant: ButtonVariant.TERTIARY,
|
|
37
41
|
size: ButtonSize.SMALL
|
|
38
42
|
}),
|
|
39
43
|
children: [
|
|
44
|
+
/* @__PURE__ */ jsx(MenuItem, {
|
|
45
|
+
label: "Create pipeline",
|
|
46
|
+
icon: FlowArrowIcon,
|
|
47
|
+
onSelect: handleCreatePipeline,
|
|
48
|
+
isDisabled: isDeleted
|
|
49
|
+
}),
|
|
40
50
|
/* @__PURE__ */ jsx(MenuItem, {
|
|
41
51
|
label: "Edit connection",
|
|
42
52
|
icon: PencilIcon,
|
|
@@ -15,7 +15,7 @@ import ConnectionFormWrapper from "./ConnectionFormWrapper.js";
|
|
|
15
15
|
import { createRequiredFieldsValidationErrorMap } from "./validation.js";
|
|
16
16
|
import { getErrorMessage, isNotFoundError } from "../../../../utils/errors.js";
|
|
17
17
|
import { getNameError, isNameValid } from "../../../../utils/validation.js";
|
|
18
|
-
import { ArrowLeftIcon,
|
|
18
|
+
import { ArrowLeftIcon, CheckIcon } from "@phosphor-icons/react";
|
|
19
19
|
import Button, { ButtonVariant } from "@galaxy-io/dls/buttons/Button";
|
|
20
20
|
import ErrorLayout from "@galaxy-io/dls/layout/ErrorLayout";
|
|
21
21
|
import { useCallback, useMemo } from "react";
|
|
@@ -163,12 +163,13 @@ var ConnectionForm = ({ isOpen, connectorName, connectorKind, connectionId, secr
|
|
|
163
163
|
const renderFooter = () => {
|
|
164
164
|
return match(state.phase).with(ConnectionFormPhase.IDLE, ConnectionFormPhase.ERROR, () => /* @__PURE__ */ jsx(Button, {
|
|
165
165
|
label: "Validate",
|
|
166
|
-
|
|
166
|
+
hotKeys: ["mod", "enter"],
|
|
167
|
+
shouldBindHotKey: true,
|
|
167
168
|
onClick: handleTestConnection,
|
|
168
|
-
isDisabled
|
|
169
|
-
isIconTrailing: true
|
|
169
|
+
isDisabled
|
|
170
170
|
})).with(ConnectionFormPhase.VALIDATING, () => /* @__PURE__ */ jsx(Button, {
|
|
171
171
|
label: "Validate",
|
|
172
|
+
hotKeys: ["mod", "enter"],
|
|
172
173
|
isLoading: true
|
|
173
174
|
})).with(ConnectionFormPhase.VALIDATED, () => /* @__PURE__ */ jsxs(Flex, {
|
|
174
175
|
alignItems: AlignItems.CENTER,
|
|
@@ -179,10 +180,13 @@ var ConnectionForm = ({ isOpen, connectorName, connectorKind, connectionId, secr
|
|
|
179
180
|
}), /* @__PURE__ */ jsx(Button, {
|
|
180
181
|
label: submitLabel,
|
|
181
182
|
icon: CheckIcon,
|
|
183
|
+
hotKeys: ["mod", "enter"],
|
|
184
|
+
shouldBindHotKey: true,
|
|
182
185
|
onClick: handleSubmit
|
|
183
186
|
})]
|
|
184
187
|
})).with(ConnectionFormPhase.SUBMITTING, () => /* @__PURE__ */ jsx(Button, {
|
|
185
188
|
label: submitLabel,
|
|
189
|
+
hotKeys: ["mod", "enter"],
|
|
186
190
|
isLoading: true
|
|
187
191
|
})).exhaustive();
|
|
188
192
|
};
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { ConnectorKind } from '../../gen/ingestion/v1/common_pb';
|
|
2
|
+
import { Connection } from '../../gen/ingestion/v1/connections_pb';
|
|
2
3
|
import { CreateConnectionSelectorShelf } from './components/create/types';
|
|
4
|
+
import { FilamentFlowSeed } from '../../module/schemas';
|
|
3
5
|
export declare const CONNECTOR_GRID_MIN_COLUMN_WIDTH = 320;
|
|
4
6
|
export declare const CONNECTION_PIPELINES_PAGE_SIZE = 1000;
|
|
5
7
|
export declare const CREATE_CONNECTION_SELECTOR_GHOST_COUNT = 6;
|
|
@@ -10,3 +12,4 @@ export declare const CREATE_CONNECTION_SELECTOR_CARD_MIN_HEIGHT = 150;
|
|
|
10
12
|
export declare const CONNECTOR_KIND_TO_DESCRIPTION_MAP: Record<ConnectorKind, string>;
|
|
11
13
|
export declare const CONNECTOR_KIND_TO_DOCS_PATH_MAP: Record<ConnectorKind, string>;
|
|
12
14
|
export declare const CONNECTOR_KIND_TO_EMPTY_MESSAGE_MAP: Record<ConnectorKind.SOURCE | ConnectorKind.SINK, string>;
|
|
15
|
+
export declare const CONNECTOR_KIND_TO_PIPELINE_SEED_MAP: Record<ConnectorKind, (connectionId: Connection["id"]) => FilamentFlowSeed>;
|
|
@@ -22,5 +22,10 @@ var CONNECTOR_KIND_TO_EMPTY_MESSAGE_MAP = {
|
|
|
22
22
|
[ConnectorKind.SOURCE]: "Connect data sources to move data in.",
|
|
23
23
|
[ConnectorKind.SINK]: "Connect data sinks to move data out."
|
|
24
24
|
};
|
|
25
|
+
var CONNECTOR_KIND_TO_PIPELINE_SEED_MAP = {
|
|
26
|
+
[ConnectorKind.UNSPECIFIED]: () => ({}),
|
|
27
|
+
[ConnectorKind.SOURCE]: (sourceId) => ({ sourceId }),
|
|
28
|
+
[ConnectorKind.SINK]: (sinkId) => ({ sinkIds: [sinkId] })
|
|
29
|
+
};
|
|
25
30
|
//#endregion
|
|
26
|
-
export { CONNECTION_PIPELINES_PAGE_SIZE, CONNECTOR_KIND_TO_DESCRIPTION_MAP, CONNECTOR_KIND_TO_DOCS_PATH_MAP, CONNECTOR_KIND_TO_EMPTY_MESSAGE_MAP, CREATE_CONNECTION_SELECTOR_GRID_COLUMNS, CREATE_CONNECTION_SELECTOR_SHELF_ORDER, CREATE_CONNECTION_SELECTOR_SHELF_TO_LABEL_MAP };
|
|
31
|
+
export { CONNECTION_PIPELINES_PAGE_SIZE, CONNECTOR_KIND_TO_DESCRIPTION_MAP, CONNECTOR_KIND_TO_DOCS_PATH_MAP, CONNECTOR_KIND_TO_EMPTY_MESSAGE_MAP, CONNECTOR_KIND_TO_PIPELINE_SEED_MAP, CREATE_CONNECTION_SELECTOR_GRID_COLUMNS, CREATE_CONNECTION_SELECTOR_SHELF_ORDER, CREATE_CONNECTION_SELECTOR_SHELF_TO_LABEL_MAP };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ConnectorKind } from "../../gen/ingestion/v1/common_pb.js";
|
|
2
1
|
import { Flow } from "../../module/types.js";
|
|
2
|
+
import { ConnectorKind } from "../../gen/ingestion/v1/common_pb.js";
|
|
3
3
|
import { useFilamentFlowOpen } from "../../module/hooks.js";
|
|
4
4
|
import { PIPELINE_CREATE_TITLE } from "../../components/pipelines/constants.js";
|
|
5
5
|
import ObservabilityBand from "./components/band/ObservabilityBand.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { Flow } from "../../../../module/types.js";
|
|
1
2
|
import { ConnectorKind } from "../../../../gen/ingestion/v1/common_pb.js";
|
|
2
3
|
import { ListPipelinesRequestSchema } from "../../../../gen/ingestion/v1/pipelines_pb.js";
|
|
3
|
-
import { Flow } from "../../../../module/types.js";
|
|
4
4
|
import { ListConnectionsRequestSchema } from "../../../../gen/ingestion/v1/connections_pb.js";
|
|
5
5
|
import { PIPELINE_CREATE_TITLE } from "../../../../components/pipelines/constants.js";
|
|
6
6
|
import { ObservabilitySetupStep, ObservabilitySetupStepStatus } from "./types.js";
|
|
@@ -6,6 +6,7 @@ interface PipelineCanvasConnectionSelectorProps {
|
|
|
6
6
|
onSelect?: (connection: Connection) => void;
|
|
7
7
|
width?: number;
|
|
8
8
|
fillHeight?: boolean;
|
|
9
|
+
shouldBindHotKey?: boolean;
|
|
9
10
|
}
|
|
10
11
|
declare const PipelineCanvasConnectionSelector: FC<PipelineCanvasConnectionSelectorProps>;
|
|
11
12
|
export default PipelineCanvasConnectionSelector;
|
|
@@ -16,7 +16,7 @@ import SearchInput from "@galaxy-io/dls/inputs/SearchInput";
|
|
|
16
16
|
import Divider from "@galaxy-io/dls/layout/Divider";
|
|
17
17
|
//#region src/pages/pipelines/canvas/PipelineCanvasConnectionSelector.tsx
|
|
18
18
|
var DEFAULT_STATE = { q: "" };
|
|
19
|
-
var PipelineCanvasConnectionSelector = ({ kindFilter = ConnectorKind.UNSPECIFIED, onSelect, width = 320, fillHeight = false }) => {
|
|
19
|
+
var PipelineCanvasConnectionSelector = ({ kindFilter = ConnectorKind.UNSPECIFIED, onSelect, width = 320, fillHeight = false, shouldBindHotKey = false }) => {
|
|
20
20
|
const [state, setState] = useState(DEFAULT_STATE);
|
|
21
21
|
const canvasState = usePipelineCanvasState();
|
|
22
22
|
const { addNode } = usePipelineCanvasActions();
|
|
@@ -54,6 +54,10 @@ var PipelineCanvasConnectionSelector = ({ kindFilter = ConnectorKind.UNSPECIFIED
|
|
|
54
54
|
placeholder: "Search connections...",
|
|
55
55
|
debounceMs: 300,
|
|
56
56
|
onSearch: handleSearch,
|
|
57
|
+
...shouldBindHotKey ? {
|
|
58
|
+
hotKeys: ["/"],
|
|
59
|
+
shouldBindHotKey
|
|
60
|
+
} : {},
|
|
57
61
|
fillWidth: true
|
|
58
62
|
})
|
|
59
63
|
}),
|
|
@@ -26,7 +26,7 @@ var PipelineCanvasEditWidget = () => {
|
|
|
26
26
|
variant: PopoverVariant.PRIMARY,
|
|
27
27
|
isOpen: isAddNodeOpen,
|
|
28
28
|
onOpenChange: handleAddNodeOpenChange,
|
|
29
|
-
body: /* @__PURE__ */ jsx(PipelineCanvasConnectionSelector, {}),
|
|
29
|
+
body: /* @__PURE__ */ jsx(PipelineCanvasConnectionSelector, { shouldBindHotKey: true }),
|
|
30
30
|
children: /* @__PURE__ */ jsx(Button, {
|
|
31
31
|
icon: PIPELINE_CANVAS_EDIT_MODE_TO_ICON_MAP[PipelineCanvasEditMode.ADD_NODE],
|
|
32
32
|
variant: ButtonVariant.PRIMARY,
|
package/dist/pages/pipelines/canvas/panel/overview/resource/PipelineCanvasPanelResourceDetail.js
CHANGED
|
@@ -263,6 +263,7 @@ var PipelineCanvasPanelResourceDetail = ({ edge }) => {
|
|
|
263
263
|
onChange: handleTransformChange,
|
|
264
264
|
resource,
|
|
265
265
|
columns: selectedColumns,
|
|
266
|
+
columnSelection: selectedColumnNames,
|
|
266
267
|
sourceConnectionId,
|
|
267
268
|
isReadOnly,
|
|
268
269
|
children: /* @__PURE__ */ jsx(PipelineCanvasPanelResourceTransformSection, {})
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ConnectorKind } from "../../../../gen/ingestion/v1/common_pb.js";
|
|
2
|
+
import { useFilamentLayoutSearch } from "../../../../module/hooks.js";
|
|
2
3
|
import { ConnectorTileSize } from "../../../../components/connections/types.js";
|
|
3
4
|
import ConnectorTile from "../../../../components/connections/ConnectorTile.js";
|
|
4
5
|
import { usePipelineCanvasSelection } from "../hooks/usePipelineCanvasSelection.js";
|
|
@@ -21,6 +22,7 @@ import { useElementWidth } from "@galaxy-io/dls/hooks/useElementWidth";
|
|
|
21
22
|
var PipelineCanvasRoutesToolbar = ({ onSearch, canAddRoute, onAddRoute }) => {
|
|
22
23
|
const { sinkIds, setSinkIds } = usePipelineCanvasSelection();
|
|
23
24
|
const sinks = usePipelineCanvasRoutesSinks();
|
|
25
|
+
const { flow } = useFilamentLayoutSearch();
|
|
24
26
|
const toolbarRef = useRef(null);
|
|
25
27
|
const toolbarWidth = useElementWidth(toolbarRef);
|
|
26
28
|
const isCompact = toolbarWidth !== void 0 && toolbarWidth < 580;
|
|
@@ -64,6 +66,8 @@ var PipelineCanvasRoutesToolbar = ({ onSearch, canAddRoute, onAddRoute }) => {
|
|
|
64
66
|
debounceMs: 300,
|
|
65
67
|
onSearch,
|
|
66
68
|
placeholder: "Search resources...",
|
|
69
|
+
hotKeys: ["/"],
|
|
70
|
+
shouldBindHotKey: !flow,
|
|
67
71
|
fillWidth: true
|
|
68
72
|
})
|
|
69
73
|
}),
|
|
@@ -7,7 +7,7 @@ import { useWebhookEndpointSync } from "../../../../../components/webhooks/hooks
|
|
|
7
7
|
import { mapCreatePipelineNotifierToRequest, mapCreatePipelineStateToRequest, mapCreatePipelineStateToVersionRequest } from "../serialize.js";
|
|
8
8
|
import { useCreatePipelineNotifierMutation } from "../../../../../api/queries/notifiers.js";
|
|
9
9
|
import { useCreatePipelineVersionMutation } from "../../../../../api/queries/pipeline_versions.js";
|
|
10
|
-
import { ArrowLeftIcon,
|
|
10
|
+
import { ArrowLeftIcon, PlusIcon, WarningIcon } from "@phosphor-icons/react";
|
|
11
11
|
import Button, { ButtonVariant } from "@galaxy-io/dls/buttons/Button";
|
|
12
12
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
13
13
|
import Flex, { AlignItems, JustifyContent } from "@galaxy-io/dls/layout/Flex";
|
|
@@ -99,16 +99,18 @@ var CreatePipelineModalFooter = () => {
|
|
|
99
99
|
if (isLastStep) return /* @__PURE__ */ jsx(Button, {
|
|
100
100
|
label: isSubmitting ? "Creating..." : "Create pipeline",
|
|
101
101
|
icon: PlusIcon,
|
|
102
|
+
hotKeys: ["mod", "enter"],
|
|
103
|
+
shouldBindHotKey: true,
|
|
102
104
|
isLoading: isSubmitting,
|
|
103
105
|
isDisabled: isSubmitting || isNextDisabled,
|
|
104
106
|
onClick: handleCreate
|
|
105
107
|
});
|
|
106
108
|
return /* @__PURE__ */ jsx(Button, {
|
|
107
109
|
label: "Next",
|
|
108
|
-
|
|
110
|
+
hotKeys: ["mod", "enter"],
|
|
111
|
+
shouldBindHotKey: true,
|
|
109
112
|
onClick: () => goNext(),
|
|
110
|
-
isDisabled: isNextDisabled
|
|
111
|
-
isIconTrailing: true
|
|
113
|
+
isDisabled: isNextDisabled
|
|
112
114
|
});
|
|
113
115
|
};
|
|
114
116
|
return /* @__PURE__ */ jsxs(Flex, {
|
|
@@ -78,6 +78,8 @@ var CreatePipelineModalResources = ({ activeRow, onActiveResourceChange }) => {
|
|
|
78
78
|
onChange: handleSearchChange,
|
|
79
79
|
placeholder: "Search resources...",
|
|
80
80
|
ariaLabel: "Search resources",
|
|
81
|
+
hotKeys: ["/"],
|
|
82
|
+
shouldBindHotKey: true,
|
|
81
83
|
fillWidth: true
|
|
82
84
|
}), isContinuous && /* @__PURE__ */ jsx(FlexItem, {
|
|
83
85
|
shrink: 0,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ExecutionMode } from "../../../../gen/ingestion/v1/common_pb.js";
|
|
2
1
|
import { Flow } from "../../../../module/types.js";
|
|
2
|
+
import { ExecutionMode } from "../../../../gen/ingestion/v1/common_pb.js";
|
|
3
3
|
import { useFilamentFlowOpen, usePipelineParams } from "../../../../module/hooks.js";
|
|
4
4
|
import { ValidatePipelineRequestSchema } from "../../../../gen/ingestion/v1/capabilities_pb.js";
|
|
5
5
|
import { getErrorMessage } from "../../../../utils/errors.js";
|
|
@@ -147,6 +147,8 @@ var PipelineRunModalContent = ({ isOpen, pipeline, seed, onClose }) => {
|
|
|
147
147
|
icon: PlayIcon,
|
|
148
148
|
iconWeight: IconWeight.FILL,
|
|
149
149
|
variant: ButtonVariant.PRIMARY,
|
|
150
|
+
hotKeys: ["mod", "enter"],
|
|
151
|
+
shouldBindHotKey: true,
|
|
150
152
|
isLoading: isRunning,
|
|
151
153
|
isDisabled: !!parsed.error || runResources.length === 0,
|
|
152
154
|
onClick: handleRun
|
|
@@ -21,6 +21,7 @@ interface PipelineTransformFieldsProviderProps {
|
|
|
21
21
|
onChange: (definition: TransformDefinition | undefined) => void;
|
|
22
22
|
resource: Resource["name"];
|
|
23
23
|
columns: ResourceColumn[];
|
|
24
|
+
columnSelection: ResourceColumn["name"][];
|
|
24
25
|
sourceConnectionId: Connection["id"];
|
|
25
26
|
isReadOnly?: boolean;
|
|
26
27
|
}
|
|
@@ -35,7 +35,7 @@ var usePipelineTransformFieldsEditor = () => {
|
|
|
35
35
|
if (!editor) throw new Error("usePipelineTransformFieldsEditor must be used within PipelineTransformFieldsStepCard");
|
|
36
36
|
return editor;
|
|
37
37
|
};
|
|
38
|
-
var PipelineTransformFieldsProvider = ({ definition, onChange, resource, columns, sourceConnectionId, isReadOnly = false, children }) => {
|
|
38
|
+
var PipelineTransformFieldsProvider = ({ definition, onChange, resource, columns, columnSelection, sourceConnectionId, isReadOnly = false, children }) => {
|
|
39
39
|
const { data: catalog } = useSuspenseListTransformFunctionsQuery({ input: create(ListTransformFunctionsRequestSchema, {}) });
|
|
40
40
|
const functionsByName = useMemo(() => new Map(catalog.functions.map((fn) => [fn.name, fn])), [catalog.functions]);
|
|
41
41
|
const [state, dispatch] = useReducer(pipelineTransformFieldsReducer, {
|
|
@@ -104,6 +104,7 @@ var PipelineTransformFieldsProvider = ({ definition, onChange, resource, columns
|
|
|
104
104
|
const environment = useMemo(() => ({
|
|
105
105
|
resource,
|
|
106
106
|
columns,
|
|
107
|
+
columnSelection,
|
|
107
108
|
sourceConnectionId,
|
|
108
109
|
functionsByName,
|
|
109
110
|
grammarVersion: catalog.grammarVersion,
|
|
@@ -111,6 +112,7 @@ var PipelineTransformFieldsProvider = ({ definition, onChange, resource, columns
|
|
|
111
112
|
}), [
|
|
112
113
|
resource,
|
|
113
114
|
columns,
|
|
115
|
+
columnSelection,
|
|
114
116
|
sourceConnectionId,
|
|
115
117
|
functionsByName,
|
|
116
118
|
catalog.grammarVersion,
|
|
@@ -8,7 +8,7 @@ import { create } from "@bufbuild/protobuf";
|
|
|
8
8
|
//#region src/pages/pipelines/components/transform/hooks/usePipelineTransformFieldsIssues.ts
|
|
9
9
|
var usePipelineTransformFieldsIssues = () => {
|
|
10
10
|
const { steps } = usePipelineTransformFieldsState();
|
|
11
|
-
const { resource, sourceConnectionId, grammarVersion } = usePipelineTransformFieldsEnvironment();
|
|
11
|
+
const { resource, columnSelection, sourceConnectionId, grammarVersion } = usePipelineTransformFieldsEnvironment();
|
|
12
12
|
const definition = useMemo(() => serializeTransformDefinition(resource, steps, grammarVersion), [
|
|
13
13
|
grammarVersion,
|
|
14
14
|
resource,
|
|
@@ -18,7 +18,8 @@ var usePipelineTransformFieldsIssues = () => {
|
|
|
18
18
|
input: create(ValidateTransformRequestSchema, {
|
|
19
19
|
sourceConnectionId,
|
|
20
20
|
resource,
|
|
21
|
-
transform: definition
|
|
21
|
+
transform: definition,
|
|
22
|
+
columns: columnSelection
|
|
22
23
|
}),
|
|
23
24
|
options: { enabled: sourceConnectionId !== "" && definition !== void 0 }
|
|
24
25
|
});
|
package/dist/pages/pipelines/components/transform/hooks/usePipelineTransformFieldsValidation.js
CHANGED
|
@@ -16,7 +16,7 @@ var NO_ERRORS = /* @__PURE__ */ new Map();
|
|
|
16
16
|
var NO_TYPES = /* @__PURE__ */ new Map();
|
|
17
17
|
var usePipelineTransformFieldsValidation = (draft) => {
|
|
18
18
|
const { steps } = usePipelineTransformFieldsState();
|
|
19
|
-
const { resource, columns: resourceColumns, sourceConnectionId, functionsByName, grammarVersion, isReadOnly } = usePipelineTransformFieldsEnvironment();
|
|
19
|
+
const { resource, columns: resourceColumns, columnSelection, sourceConnectionId, functionsByName, grammarVersion, isReadOnly } = usePipelineTransformFieldsEnvironment();
|
|
20
20
|
const savedIssues = usePipelineTransformFieldsIssues();
|
|
21
21
|
const requiresValidation = sourceConnectionId !== "";
|
|
22
22
|
const prefixDefinition = useMemo(() => {
|
|
@@ -33,7 +33,8 @@ var usePipelineTransformFieldsValidation = (draft) => {
|
|
|
33
33
|
input: create(ValidateTransformRequestSchema, {
|
|
34
34
|
sourceConnectionId,
|
|
35
35
|
resource,
|
|
36
|
-
transform: prefixDefinition
|
|
36
|
+
transform: prefixDefinition,
|
|
37
|
+
columns: columnSelection
|
|
37
38
|
}),
|
|
38
39
|
options: { enabled: hasPrefix }
|
|
39
40
|
});
|
|
@@ -55,7 +56,8 @@ var usePipelineTransformFieldsValidation = (draft) => {
|
|
|
55
56
|
input: create(ValidateTransformRequestSchema, {
|
|
56
57
|
sourceConnectionId,
|
|
57
58
|
resource,
|
|
58
|
-
transform: definition
|
|
59
|
+
transform: definition,
|
|
60
|
+
columns: columnSelection
|
|
59
61
|
}),
|
|
60
62
|
options: {
|
|
61
63
|
enabled: requiresValidation && isValidatable && isSettled && !isPrefixPending && prefixError === null,
|
|
@@ -124,6 +124,7 @@ export interface PipelineTransformFieldsState {
|
|
|
124
124
|
export interface PipelineTransformFieldsEnvironment {
|
|
125
125
|
resource: Resource["name"];
|
|
126
126
|
columns: ResourceColumn[];
|
|
127
|
+
columnSelection: ResourceColumn["name"][];
|
|
127
128
|
sourceConnectionId: Connection["id"];
|
|
128
129
|
functionsByName: Map<TransformFunction["name"], TransformFunction>;
|
|
129
130
|
grammarVersion: ListTransformFunctionsResponse["grammarVersion"];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@galaxy-io/filament-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.17.0",
|
|
4
4
|
"description": "Filament's web UI as a Galaxy module a host app mounts",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"repository": {
|
|
@@ -113,7 +113,7 @@
|
|
|
113
113
|
"@codemirror/view": "^6.43.1",
|
|
114
114
|
"@connectrpc/connect": "^2.1.0",
|
|
115
115
|
"@connectrpc/connect-query": "^2.1.1",
|
|
116
|
-
"@galaxy-io/dls": "^2.
|
|
116
|
+
"@galaxy-io/dls": "^2.14.0",
|
|
117
117
|
"@lezer/highlight": "^1.2.3",
|
|
118
118
|
"@tanstack/react-query": "^5.90.12",
|
|
119
119
|
"@tanstack/react-router": "^1.141.2",
|
|
@@ -141,7 +141,7 @@
|
|
|
141
141
|
"@connectrpc/connect": "^2.1.0",
|
|
142
142
|
"@connectrpc/connect-query": "^2.1.1",
|
|
143
143
|
"@connectrpc/connect-web": "^2.1.0",
|
|
144
|
-
"@galaxy-io/dls": "^2.
|
|
144
|
+
"@galaxy-io/dls": "^2.14.0",
|
|
145
145
|
"@lezer/highlight": "^1.2.3",
|
|
146
146
|
"@tanstack/react-query": "^5.90.12",
|
|
147
147
|
"@tanstack/react-router": "^1.141.2",
|