@odigos/ui-kit 0.0.44 → 0.0.46
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/CHANGELOG.md +19 -0
- package/lib/components/data-tab/index.d.ts +1 -0
- package/lib/components/toggle/index.d.ts +1 -0
- package/lib/components.js +8 -8
- package/lib/constants/strings/index.d.ts +3 -0
- package/lib/constants.js +1 -1
- package/lib/containers/data-stream-form/index.d.ts +1 -1
- package/lib/containers/data-stream-modal/data-stream-modal.stories.d.ts +9 -0
- package/lib/containers/data-stream-modal/index.d.ts +5 -0
- package/lib/containers/destination-modal/choose-destination/destinations-list/index.d.ts +1 -0
- package/lib/containers/destination-modal/choose-destination/index.d.ts +2 -2
- package/lib/containers/destination-modal/index.d.ts +3 -2
- package/lib/containers.js +78 -45
- package/lib/functions/get-conditions-booleans/index.d.ts +4 -0
- package/lib/functions.js +5 -5
- package/lib/hooks/useSourceSelectionFormData.d.ts +4 -4
- package/lib/hooks.js +3 -3
- package/lib/icons.js +6 -6
- package/lib/{index-AM8c03-E.js → index-B1IScVBT.js} +16 -22
- package/lib/{index-b8zuk7ta.js → index-BJpPcCBm.js} +27 -4
- package/lib/{index-BD7meETN.js → index-BRGQ84pJ.js} +3 -0
- package/lib/{index-CY3kjYr3.js → index-BUCure0Q.js} +1 -1
- package/lib/{index-BL1s2-bo.js → index-C4aVlsHh.js} +1 -1
- package/lib/{index-Dxj04GUZ.js → index-C8vqcUbP.js} +2 -2
- package/lib/{index-DZWbhK14.js → index-CeHgnkLY.js} +1 -1
- package/lib/{index-Bup9Thvg.js → index-CpT8LSxY.js} +5 -20
- package/lib/{index-C3BU6Xe-.js → index-DypjdLnz.js} +1 -1
- package/lib/{index-BDBeg2A7.js → index-fEP_guwb.js} +4 -4
- package/lib/snippets.js +7 -7
- package/lib/store/useSetupStore.d.ts +7 -2
- package/lib/store.js +1 -1
- package/lib/theme.js +1 -1
- package/lib/types/common/index.d.ts +3 -0
- package/lib/types/namespaces/index.d.ts +1 -0
- package/lib/types/sources/index.d.ts +2 -6
- package/lib/types.js +5 -1
- package/lib/{useSourceSelectionFormData-DmZnRueA.js → useSourceSelectionFormData-CMXqoHZs.js} +52 -32
- package/lib/{useTransition-BWC_F-Pl.js → useTransition-DsrDiKOV.js} +1 -1
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.0.46](https://github.com/odigos-io/ui-kit/compare/ui-kit-v0.0.45...ui-kit-v0.0.46) (2025-06-24)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* turn on data streams ([#164](https://github.com/odigos-io/ui-kit/issues/164)) ([f7956f4](https://github.com/odigos-io/ui-kit/commit/f7956f4d9a444aa7c88d62ab9fbeeee3c523e855))
|
|
9
|
+
|
|
10
|
+
## [0.0.45](https://github.com/odigos-io/ui-kit/compare/ui-kit-v0.0.44...ui-kit-v0.0.45) (2025-06-23)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### Features
|
|
14
|
+
|
|
15
|
+
* re-use getConditionsBooleans function ([#188](https://github.com/odigos-io/ui-kit/issues/188)) ([e602132](https://github.com/odigos-io/ui-kit/commit/e60213239340354d44c4855abf8a39da44acdeee))
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
### Bug Fixes
|
|
19
|
+
|
|
20
|
+
* initialize extend state with initialExtended prop in DataCard component ([#189](https://github.com/odigos-io/ui-kit/issues/189)) ([31604ca](https://github.com/odigos-io/ui-kit/commit/31604cabee2587c647354601fca37d3816a4807d))
|
|
21
|
+
|
|
3
22
|
## [0.0.44](https://github.com/odigos-io/ui-kit/compare/ui-kit-v0.0.43...ui-kit-v0.0.44) (2025-06-19)
|
|
4
23
|
|
|
5
24
|
|
package/lib/components.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { B as Button } from './index-
|
|
2
|
-
export { a as AutocompleteInput, b as Badge, a1 as CenterThis, C as Checkbox, c as Code, d as ConditionDetails, D as DataCard, f as DataCardFieldTypes, e as DataCardFields, g as DataTab, h as Divider, i as DocsButton, j as Drawer, l as DrawerFooter, k as DrawerHeader, m as Dropdown, E as ExtendArrow, F as FadeLoader, n as FieldError, o as FieldLabel, a0 as FlexColumn, $ as FlexRow, H as Header, I as IconButton, p as IconGroup, q as IconTitleBadge, r as IconWrapped, s as IconsNav, t as ImageControlled, u as Input, v as InputList, w as InputTable, x as InteractiveTable, K as KeyValueInputsList, M as Modal, a4 as ModalBody, y as MonitorsCheckboxes, z as MonitorsIcons, N as NavigationButtons, G as NoDataFound, J as NotificationNote, a3 as Overlay, S as ScrollX, L as SectionTitle, O as Segment, P as SelectionButton, Q as SkeletonLoader, R as Status, U as Stepper, a5 as TableContainer, a6 as TableTitleWrap, a7 as TableWrap, V as Text, W as TextArea, X as Toggle, T as ToggleCodeComponent, Y as Tooltip, Z as TraceLoader, a2 as VerticalScroll, _ as WarningModal } from './index-
|
|
3
|
-
export { C as CancelWarning, D as DeleteWarning } from './index-
|
|
1
|
+
import { B as Button } from './index-B1IScVBT.js';
|
|
2
|
+
export { a as AutocompleteInput, b as Badge, a1 as CenterThis, C as Checkbox, c as Code, d as ConditionDetails, D as DataCard, f as DataCardFieldTypes, e as DataCardFields, g as DataTab, h as Divider, i as DocsButton, j as Drawer, l as DrawerFooter, k as DrawerHeader, m as Dropdown, E as ExtendArrow, F as FadeLoader, n as FieldError, o as FieldLabel, a0 as FlexColumn, $ as FlexRow, H as Header, I as IconButton, p as IconGroup, q as IconTitleBadge, r as IconWrapped, s as IconsNav, t as ImageControlled, u as Input, v as InputList, w as InputTable, x as InteractiveTable, K as KeyValueInputsList, M as Modal, a4 as ModalBody, y as MonitorsCheckboxes, z as MonitorsIcons, N as NavigationButtons, G as NoDataFound, J as NotificationNote, a3 as Overlay, S as ScrollX, L as SectionTitle, O as Segment, P as SelectionButton, Q as SkeletonLoader, R as Status, U as Stepper, a5 as TableContainer, a6 as TableTitleWrap, a7 as TableWrap, V as Text, W as TextArea, X as Toggle, T as ToggleCodeComponent, Y as Tooltip, Z as TraceLoader, a2 as VerticalScroll, _ as WarningModal } from './index-B1IScVBT.js';
|
|
3
|
+
export { C as CancelWarning, D as DeleteWarning } from './index-C8vqcUbP.js';
|
|
4
4
|
import React, { Component, createElement, createContext } from 'react';
|
|
5
|
-
import { T as Theme } from './index-
|
|
5
|
+
import { T as Theme } from './index-BRGQ84pJ.js';
|
|
6
6
|
import './types.js';
|
|
7
|
-
import './index-
|
|
8
|
-
import './index-
|
|
7
|
+
import './index-BUCure0Q.js';
|
|
8
|
+
import './index-BJpPcCBm.js';
|
|
9
9
|
import 'styled-components';
|
|
10
|
-
import './index-
|
|
10
|
+
import './index-CeHgnkLY.js';
|
|
11
11
|
import './index-BV85P9UP.js';
|
|
12
|
-
import './useTransition-
|
|
12
|
+
import './useTransition-DsrDiKOV.js';
|
|
13
13
|
import 'react-dom';
|
|
14
14
|
|
|
15
15
|
const ErrorBoundaryContext = createContext(null);
|
|
@@ -31,6 +31,7 @@ export declare const DISPLAY_TITLES: {
|
|
|
31
31
|
NAME_YOUR_STREAM_PLACEHOLDER: string;
|
|
32
32
|
STREAM_DESCRIPTION: string;
|
|
33
33
|
STREAM_CONFIRM: string;
|
|
34
|
+
DATA_STREAM_EXISTS_WARNING: (curr: string, next: string) => string;
|
|
34
35
|
ACTION: string;
|
|
35
36
|
ACTIONS: string;
|
|
36
37
|
ADD_ACTION: string;
|
|
@@ -88,6 +89,8 @@ export declare const DISPLAY_TITLES: {
|
|
|
88
89
|
TO_MODIFY_OTEL_DATA: string;
|
|
89
90
|
QUICK_BACK_TO_SUMMARY: string;
|
|
90
91
|
GO_TO_SUMMARY: string;
|
|
92
|
+
FUTURE_APPS_TITLE: string;
|
|
93
|
+
FUTURE_APPS_DESCRIPTION: string;
|
|
91
94
|
OVERIDE: string;
|
|
92
95
|
OVERIDDEN: string;
|
|
93
96
|
OVERRIDE_RUNTIME_DETAILS: string;
|
package/lib/constants.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { A as ACTION_OPTIONS, B as BUTTON_TEXTS, k as DEFAULT_DATA_STREAM_NAME, D as DISPLAY_LANGUAGES, l as DISPLAY_TITLES, F as FORM_ALERTS, I as INSTRUMENTATION_RULE_OPTIONS, L as LANGUAGE_OPTIONS, M as MONITORS_OPTIONS, S as STORAGE_KEYS } from './index-
|
|
1
|
+
export { A as ACTION_OPTIONS, B as BUTTON_TEXTS, k as DEFAULT_DATA_STREAM_NAME, D as DISPLAY_LANGUAGES, l as DISPLAY_TITLES, F as FORM_ALERTS, I as INSTRUMENTATION_RULE_OPTIONS, L as LANGUAGE_OPTIONS, M as MONITORS_OPTIONS, S as STORAGE_KEYS } from './index-BRGQ84pJ.js';
|
|
2
2
|
export { D as DESTINATION_CATEGORIES } from './index-Dqief9td.js';
|
|
3
3
|
import 'react';
|
|
4
4
|
import './types.js';
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { StoryFn } from '@storybook/react';
|
|
3
|
+
import { type DataStreamModalProps } from '.';
|
|
4
|
+
declare const _default: {
|
|
5
|
+
title: string;
|
|
6
|
+
component: React.FC<DataStreamModalProps>;
|
|
7
|
+
};
|
|
8
|
+
export default _default;
|
|
9
|
+
export declare const Default: StoryFn<DataStreamModalProps>;
|
|
@@ -4,6 +4,7 @@ interface DestinationsListProps {
|
|
|
4
4
|
items: DestinationCategories;
|
|
5
5
|
onSelectNew: (item: DestinationOption) => void;
|
|
6
6
|
onSelectConfigured: (id: string) => void;
|
|
7
|
+
isLoadingForDestinationIds: string[];
|
|
7
8
|
}
|
|
8
9
|
declare const DestinationsList: FC<DestinationsListProps>;
|
|
9
10
|
export { DestinationsList, type DestinationsListProps };
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import { DestinationsListProps } from './destinations-list';
|
|
2
3
|
import { type DestinationCategories, type DestinationOption, SignalType } from '@/types';
|
|
3
|
-
interface Props {
|
|
4
|
+
interface Props extends Pick<DestinationsListProps, 'onSelectConfigured' | 'isLoadingForDestinationIds'> {
|
|
4
5
|
hidden?: boolean;
|
|
5
6
|
categories: DestinationCategories;
|
|
6
7
|
potentialDestinations: DestinationOption[];
|
|
7
8
|
onSelectNew: (item: DestinationOption, selectedMonitors: SignalType[]) => void;
|
|
8
|
-
onSelectConfigured: (id: string) => void;
|
|
9
9
|
}
|
|
10
10
|
export declare const ChooseDestinationBody: React.FC<Props>;
|
|
11
11
|
export {};
|
|
@@ -4,8 +4,9 @@ interface DestinationModalProps {
|
|
|
4
4
|
isOnboarding?: boolean;
|
|
5
5
|
categories: DestinationCategories;
|
|
6
6
|
potentialDestinations: DestinationOption[];
|
|
7
|
-
createDestination: (destination: DestinationFormData) => void
|
|
8
|
-
updateDestination: (id: string, destination: DestinationFormData) => void
|
|
7
|
+
createDestination: (destination: DestinationFormData) => Promise<void>;
|
|
8
|
+
updateDestination: (id: string, destination: DestinationFormData) => Promise<void>;
|
|
9
|
+
deleteDestination: (id: string) => Promise<void>;
|
|
9
10
|
testConnection: TestConnectionFunc;
|
|
10
11
|
}
|
|
11
12
|
declare const DestinationModal: FC<DestinationModalProps>;
|
package/lib/containers.js
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import React, { useState, useEffect, forwardRef, useRef, useImperativeHandle, useMemo, memo, useContext, createContext, useCallback, useLayoutEffect, Fragment } from 'react';
|
|
2
2
|
import styled, { css } from 'styled-components';
|
|
3
|
-
import { l as DISPLAY_TITLES, T as Theme, h as usePendingStore, g as useNotificationStore, b as useDrawerStore, B as BUTTON_TEXTS, c as useEntityStore, A as ACTION_OPTIONS, m as getActionIcon, f as useModalStore, F as FORM_ALERTS, d as useFilterStore, M as MONITORS_OPTIONS, $ as styleInject, i as useSelectedStore, e as useInstrumentStore, o as getInstrumentationRuleIcon, a as useDataStreamStore, n as getEntityId, S as STORAGE_KEYS, j as useSetupStore, I as INSTRUMENTATION_RULE_OPTIONS, u as useDarkMode } from './index-
|
|
3
|
+
import { l as DISPLAY_TITLES, T as Theme, h as usePendingStore, g as useNotificationStore, b as useDrawerStore, B as BUTTON_TEXTS, c as useEntityStore, A as ACTION_OPTIONS, m as getActionIcon, f as useModalStore, F as FORM_ALERTS, d as useFilterStore, M as MONITORS_OPTIONS, $ as styleInject, i as useSelectedStore, e as useInstrumentStore, o as getInstrumentationRuleIcon, a as useDataStreamStore, n as getEntityId, S as STORAGE_KEYS, k as DEFAULT_DATA_STREAM_NAME, j as useSetupStore, I as INSTRUMENTATION_RULE_OPTIONS, u as useDarkMode } from './index-BRGQ84pJ.js';
|
|
4
4
|
import { ActionType, ActionKeyTypes, InputTypes, FieldTypes, EntityTypes, StatusType, Crud, OtherStatus, NodeTypes, AddNodeTypes, EdgeTypes, SignalType, HeadersCollectionKeyTypes, CodeAttributesKeyTypes, PayloadCollectionKeyTypes, InstrumentationRuleType, K8sResourceKind } from './types.js';
|
|
5
|
-
import { f as DataCardFieldTypes, o as FieldLabel, C as Checkbox, n as FieldError, u as Input, w as InputTable, K as KeyValueInputsList, v as InputList, V as Text, O as Segment, L as SectionTitle, i as DocsButton, y as MonitorsCheckboxes, W as TextArea, j as Drawer, d as ConditionDetails, D as DataCard, a0 as FlexColumn, M as Modal, N as NavigationButtons, a4 as ModalBody, J as NotificationNote, a as AutocompleteInput, h as Divider, R as Status, $ as FlexRow, Y as Tooltip, r as IconWrapped, z as MonitorsIcons, a5 as TableContainer, a6 as TableTitleWrap, q as IconTitleBadge, a7 as TableWrap, x as InteractiveTable, a1 as CenterThis, G as NoDataFound, Z as TraceLoader, b as Badge, E as ExtendArrow, a2 as VerticalScroll, P as SelectionButton, B as Button, m as Dropdown, a8 as getDefaultExportFromCjs, F as FadeLoader, g as DataTab, Q as SkeletonLoader, X as Toggle, A as AddButton$1, U as Stepper,
|
|
5
|
+
import { f as DataCardFieldTypes, o as FieldLabel, C as Checkbox, n as FieldError, u as Input, w as InputTable, K as KeyValueInputsList, v as InputList, V as Text, O as Segment, L as SectionTitle, i as DocsButton, y as MonitorsCheckboxes, W as TextArea, j as Drawer, d as ConditionDetails, D as DataCard, a0 as FlexColumn, M as Modal, N as NavigationButtons, a4 as ModalBody, J as NotificationNote, a as AutocompleteInput, h as Divider, R as Status, $ as FlexRow, Y as Tooltip, r as IconWrapped, z as MonitorsIcons, a5 as TableContainer, a6 as TableTitleWrap, q as IconTitleBadge, a7 as TableWrap, x as InteractiveTable, a1 as CenterThis, G as NoDataFound, Z as TraceLoader, b as Badge, E as ExtendArrow, a2 as VerticalScroll, P as SelectionButton, B as Button, m as Dropdown, a8 as getDefaultExportFromCjs, F as FadeLoader, g as DataTab, Q as SkeletonLoader, X as Toggle, I as IconButton, A as AddButton$1, U as Stepper, e as DataCardFields, s as IconsNav, p as IconGroup } from './index-B1IScVBT.js';
|
|
6
6
|
import { i as isEmpty, s as safeJsonParse } from './index-BV85P9UP.js';
|
|
7
|
-
import { C as CheckCircledIcon, O as OdigosLogo } from './index-
|
|
8
|
-
import { C as CrossCircledIcon, O as OdigosLogoText, a as OverviewIcon, F as FilterIcon, D as DataStreamsIcon, R as RetryIcon, N as NotificationIcon, S as SlackLogo, K as KeyIcon, T as TerminalIcon } from './index-
|
|
9
|
-
import { u as useActionFormData, a as useClickNode, e as useSessionStorage, c as useDataStreamFormData, d as useDestinationFormData, b as useClickNotification, f as useSourceFormData, g as useSourceSelectionFormData } from './useSourceSelectionFormData-
|
|
10
|
-
import { d as useKeyDown, e as useOnClickOutside, u as useContainerSize, c as useInstrumentationRuleFormData, g as useTransition, f as useTimeAgo, a as useCopy } from './useTransition-
|
|
11
|
-
import { E as EditIcon, T as TrashIcon, S as SearchIcon, P as PlusIcon$1, h as CheckIcon, A as ArrowIcon, a as CopyIcon, i as CrossIcon } from './index-
|
|
12
|
-
import { D as DeleteWarning, C as CancelWarning } from './index-
|
|
13
|
-
import { m as mapConditions,
|
|
14
|
-
import { f as filterActions,
|
|
7
|
+
import { C as CheckCircledIcon, O as OdigosLogo } from './index-CeHgnkLY.js';
|
|
8
|
+
import { C as CrossCircledIcon, O as OdigosLogoText, a as OverviewIcon, F as FilterIcon, D as DataStreamsIcon, R as RetryIcon, N as NotificationIcon, S as SlackLogo, K as KeyIcon, T as TerminalIcon } from './index-C4aVlsHh.js';
|
|
9
|
+
import { u as useActionFormData, a as useClickNode, e as useSessionStorage, c as useDataStreamFormData, d as useDestinationFormData, b as useClickNotification, f as useSourceFormData, g as useSourceSelectionFormData } from './useSourceSelectionFormData-CMXqoHZs.js';
|
|
10
|
+
import { d as useKeyDown, e as useOnClickOutside, u as useContainerSize, c as useInstrumentationRuleFormData, g as useTransition, f as useTimeAgo, a as useCopy } from './useTransition-DsrDiKOV.js';
|
|
11
|
+
import { E as EditIcon, T as TrashIcon, S as SearchIcon, P as PlusIcon$1, h as CheckIcon, A as ArrowIcon, a as CopyIcon, i as CrossIcon } from './index-BUCure0Q.js';
|
|
12
|
+
import { D as DeleteWarning, C as CancelWarning } from './index-C8vqcUbP.js';
|
|
13
|
+
import { g as getConditionsBooleans, m as mapConditions, b as getStatusIcon, c as capitalizeFirstLetter } from './index-BJpPcCBm.js';
|
|
14
|
+
import { f as filterActions, m as getEntityLabel, l as getEntityIcon, v as sleep$1, o as getPlatformIcon, p as getPlatformLabel, h as formatBytes, j as getContainersIcons, q as getValueForRange, k as getDestinationIcon, g as filterSourcesByStream, e as filterSources, b as filterDestinationsByStream, a as filterDestinations, u as mapDestinationFieldsForDisplay, c as compareCondition, s as getYamlFieldsForDestination, d as deepClone, n as getMetricForEntity, r as getWorkloadId, i as getContainersInstrumentedCount, t as isOverTime } from './index-CpT8LSxY.js';
|
|
15
15
|
import { createPortal } from 'react-dom';
|
|
16
16
|
import { m as mapExportedSignals } from './index-BlZKWuxe.js';
|
|
17
|
-
import { N as NoteBackToSummary, E as EditButton } from './index-
|
|
17
|
+
import { N as NoteBackToSummary, E as EditButton } from './index-fEP_guwb.js';
|
|
18
18
|
import { D as DESTINATION_CATEGORIES } from './index-Dqief9td.js';
|
|
19
|
-
import { a6 as RulesIcon, a7 as SourcesIcon, a3 as ActionsIcon, a4 as DestinationsIcon } from './index-
|
|
19
|
+
import { a6 as RulesIcon, a7 as SourcesIcon, a3 as ActionsIcon, a4 as DestinationsIcon } from './index-DypjdLnz.js';
|
|
20
20
|
|
|
21
21
|
const buildCard$3 = (action) => {
|
|
22
22
|
const { type, spec: { actionName, notes, signals, disabled, collectContainerAttributes, collectReplicaSetAttributes, collectWorkloadId, collectClusterId, labelsAttributes, annotationsAttributes, clusterAttributes, attributeNamesToDelete, renames, piiCategories, fallbackSamplingRatio, samplingPercentage, endpointsFilters, servicesNameFilters, attributeFilters, }, } = action;
|
|
@@ -852,16 +852,13 @@ const buildSpecCell$1 = (action) => {
|
|
|
852
852
|
};
|
|
853
853
|
|
|
854
854
|
const TableCellConditions = ({ conditions, id }) => {
|
|
855
|
-
const errors = useMemo(() => conditions
|
|
856
|
-
const warnings = useMemo(() => conditions?.filter(({ status }) => status === StatusType.Warning) || [], [conditions]);
|
|
857
|
-
const disableds = useMemo(() => conditions?.filter(({ status }) => status === OtherStatus.Disabled) || [], [conditions]);
|
|
858
|
-
const isLoading = useMemo(() => !conditions?.length || !!conditions?.find(({ status }) => status === OtherStatus.Loading), [conditions]);
|
|
855
|
+
const { errors, warnings, disableds, hasLoadings } = useMemo(() => getConditionsBooleans(conditions), [conditions]);
|
|
859
856
|
const conditionsToShow = errors.length > 0 ? errors : warnings.length > 0 ? warnings : disableds.length > 0 ? disableds : [];
|
|
860
857
|
if (conditionsToShow.length > 0) {
|
|
861
858
|
return (React.createElement("div", { style: { lineHeight: 1 } },
|
|
862
859
|
React.createElement(ConditionsStatuses, { conditions: conditionsToShow, id: id })));
|
|
863
860
|
}
|
|
864
|
-
const elseStatus =
|
|
861
|
+
const elseStatus = hasLoadings ? OtherStatus.Loading : StatusType.Success;
|
|
865
862
|
return (React.createElement("div", { style: { lineHeight: 1 } },
|
|
866
863
|
React.createElement(Status, { status: elseStatus, title: elseStatus, withBorder: true, withIcon: true })));
|
|
867
864
|
};
|
|
@@ -7028,6 +7025,7 @@ function XYDrag({ onNodeMouseDown, getStoreItems, onDragStart, onDrag, onDragSto
|
|
|
7028
7025
|
let dragStarted = false;
|
|
7029
7026
|
let d3Selection = null;
|
|
7030
7027
|
let abortDrag = false; // prevents unintentional dragging on multitouch
|
|
7028
|
+
let nodePositionsChanged = false;
|
|
7031
7029
|
// public functions
|
|
7032
7030
|
function update({ noDragClassName, handleSelector, domNode, isSelectable, nodeId, nodeClickDistance = 0, }) {
|
|
7033
7031
|
d3Selection = select(domNode);
|
|
@@ -7084,6 +7082,7 @@ function XYDrag({ onNodeMouseDown, getStoreItems, onDragStart, onDrag, onDragSto
|
|
|
7084
7082
|
dragItem.position = position;
|
|
7085
7083
|
dragItem.internals.positionAbsolute = positionAbsolute;
|
|
7086
7084
|
}
|
|
7085
|
+
nodePositionsChanged = nodePositionsChanged || hasChange;
|
|
7087
7086
|
if (!hasChange) {
|
|
7088
7087
|
return;
|
|
7089
7088
|
}
|
|
@@ -7155,6 +7154,7 @@ function XYDrag({ onNodeMouseDown, getStoreItems, onDragStart, onDrag, onDragSto
|
|
|
7155
7154
|
const { domNode, nodeDragThreshold, transform, snapGrid, snapToGrid } = getStoreItems();
|
|
7156
7155
|
containerBounds = domNode?.getBoundingClientRect() || null;
|
|
7157
7156
|
abortDrag = false;
|
|
7157
|
+
nodePositionsChanged = false;
|
|
7158
7158
|
if (nodeDragThreshold === 0) {
|
|
7159
7159
|
startDrag(event);
|
|
7160
7160
|
}
|
|
@@ -7201,7 +7201,10 @@ function XYDrag({ onNodeMouseDown, getStoreItems, onDragStart, onDrag, onDragSto
|
|
|
7201
7201
|
cancelAnimationFrame(autoPanId);
|
|
7202
7202
|
if (dragItems.size > 0) {
|
|
7203
7203
|
const { nodeLookup, updateNodePositions, onNodeDragStop, onSelectionDragStop } = getStoreItems();
|
|
7204
|
-
|
|
7204
|
+
if (nodePositionsChanged) {
|
|
7205
|
+
updateNodePositions(dragItems, false);
|
|
7206
|
+
nodePositionsChanged = false;
|
|
7207
|
+
}
|
|
7205
7208
|
if (onDragStop || onNodeDragStop || (!nodeId && onSelectionDragStop)) {
|
|
7206
7209
|
const [currentNode, currentNodes] = getEventHandlerParams({
|
|
7207
7210
|
nodeId,
|
|
@@ -14373,8 +14376,11 @@ const Container$d = styled.div `
|
|
|
14373
14376
|
padding: 4px;
|
|
14374
14377
|
`;
|
|
14375
14378
|
const DataStreamForm = ({ formData, handleFormChange, formErrors }) => {
|
|
14379
|
+
const { dataStreams, selectedStreamName } = useDataStreamStore();
|
|
14380
|
+
const existingDS = useMemo(() => dataStreams.find((s) => s.name === formData.name && s.name !== selectedStreamName), [dataStreams, formData.name, selectedStreamName]);
|
|
14376
14381
|
return (React.createElement(Container$d, null,
|
|
14377
|
-
React.createElement(Input, { name: 'name', title: DISPLAY_TITLES.STREAM_NAME, placeholder: DISPLAY_TITLES.NAME_YOUR_STREAM_PLACEHOLDER, required: true, value: formData.name, onChange: ({ target: { value } }) => handleFormChange('name', value), errorMessage: formErrors['name'] })
|
|
14382
|
+
React.createElement(Input, { name: 'name', title: DISPLAY_TITLES.STREAM_NAME, placeholder: DISPLAY_TITLES.NAME_YOUR_STREAM_PLACEHOLDER, required: true, value: formData.name, onChange: ({ target: { value } }) => handleFormChange('name', value), errorMessage: formErrors['name'] }),
|
|
14383
|
+
existingDS && React.createElement(NotificationNote, { type: StatusType.Warning, message: DISPLAY_TITLES.DATA_STREAM_EXISTS_WARNING(selectedStreamName, existingDS.name) })));
|
|
14378
14384
|
};
|
|
14379
14385
|
|
|
14380
14386
|
const FormContainer$3 = styled.div `
|
|
@@ -14457,9 +14463,7 @@ const SelectionRow = styled(FlexRow) `
|
|
|
14457
14463
|
const Stretch = styled.div `
|
|
14458
14464
|
width: 100%;
|
|
14459
14465
|
`;
|
|
14460
|
-
const DataStreamSelect = ({
|
|
14461
|
-
// onClickNewDataStream,
|
|
14462
|
-
updateDataStream, deleteDataStream, }) => {
|
|
14466
|
+
const DataStreamSelect = ({ onClickNewDataStream, updateDataStream, deleteDataStream }) => {
|
|
14463
14467
|
const theme = Theme.useTheme();
|
|
14464
14468
|
const { dataStreams, selectedStreamName, setSelectedStreamName } = useDataStreamStore();
|
|
14465
14469
|
const [popupOpen, setPopupOpen] = useState(false);
|
|
@@ -14468,13 +14472,18 @@ updateDataStream, deleteDataStream, }) => {
|
|
|
14468
14472
|
const [editOpenForDataStreamName, setEditOpenForDataStreamName] = useState('');
|
|
14469
14473
|
const [deleteOpenForDataStreamName, setDeleteOpenForDataStreamName] = useState('');
|
|
14470
14474
|
const [searchText, setSearchText] = useState('');
|
|
14471
|
-
const
|
|
14472
|
-
|
|
14475
|
+
const rows = useMemo(() => dataStreams
|
|
14476
|
+
.filter(({ name }) => !searchText || name.toLowerCase().includes(searchText.toLowerCase()))
|
|
14477
|
+
.map(({ name }) => (React.createElement(SelectionRow, { key: `stream-${name}` },
|
|
14473
14478
|
React.createElement(Stretch, null,
|
|
14474
14479
|
React.createElement(SelectionButton, { label: name, isSelected: selectedStreamName === name, onClick: () => {
|
|
14475
14480
|
setSelectedStreamName(name);
|
|
14476
14481
|
setPopupOpen(false);
|
|
14477
|
-
}, color: 'transparent', style: { width: '100%', justifyContent: 'flex-start' } }))
|
|
14482
|
+
}, color: 'transparent', style: { width: '100%', justifyContent: 'flex-start' } })),
|
|
14483
|
+
name !== DEFAULT_DATA_STREAM_NAME && (React.createElement(IconButton, { onClick: () => setDeleteOpenForDataStreamName(name), tooltip: BUTTON_TEXTS.DELETE },
|
|
14484
|
+
React.createElement(TrashIcon, null))),
|
|
14485
|
+
React.createElement(IconButton, { onClick: () => setEditOpenForDataStreamName(name), tooltip: BUTTON_TEXTS.EDIT },
|
|
14486
|
+
React.createElement(EditIcon, null))))), [dataStreams, selectedStreamName, searchText]);
|
|
14478
14487
|
return (React.createElement(React.Fragment, null,
|
|
14479
14488
|
React.createElement(RelativeContainer$1, null,
|
|
14480
14489
|
React.createElement(Container$c, { "$gap": 0 },
|
|
@@ -14484,7 +14493,12 @@ updateDataStream, deleteDataStream, }) => {
|
|
|
14484
14493
|
"Data Stream: ",
|
|
14485
14494
|
selectedStreamName),
|
|
14486
14495
|
React.createElement(ExtendArrow, { extend: popupOpen }),
|
|
14487
|
-
React.createElement(Badge, { label: dataStreams.length }))
|
|
14496
|
+
React.createElement(Badge, { label: dataStreams.length })),
|
|
14497
|
+
React.createElement(Divider, { orientation: 'vertical', length: '32px', thickness: 2, margin: '0' }),
|
|
14498
|
+
React.createElement(AddButton$1, { onClick: () => {
|
|
14499
|
+
setSelectedStreamName('');
|
|
14500
|
+
onClickNewDataStream();
|
|
14501
|
+
}, label: BUTTON_TEXTS.NEW })),
|
|
14488
14502
|
popupOpen && (React.createElement(AbsoluteContainer$1, { ref: containerRef },
|
|
14489
14503
|
React.createElement(SelectionMenuHeader, null,
|
|
14490
14504
|
React.createElement(Input, { placeholder: 'Search...', icon: SearchIcon, value: searchText, onChange: (e) => setSearchText(e.target.value) })),
|
|
@@ -14528,7 +14542,7 @@ const DataStreamSelectionForm = forwardRef(({ isModal, onClickSummary }, ref) =>
|
|
|
14528
14542
|
validateForm,
|
|
14529
14543
|
getFormValues: () => formData,
|
|
14530
14544
|
}));
|
|
14531
|
-
return (React.createElement(ModalBody, { "$isNotModal": !isModal
|
|
14545
|
+
return (React.createElement(ModalBody, { "$isNotModal": !isModal },
|
|
14532
14546
|
React.createElement(FlexColumn, { "$gap": 24 },
|
|
14533
14547
|
onClickSummary && React.createElement(NoteBackToSummary, { onClick: onClickSummary }),
|
|
14534
14548
|
React.createElement(SectionTitle, { title: DISPLAY_TITLES.NAME_YOUR_STREAM, description: DISPLAY_TITLES.STREAM_DESCRIPTION }),
|
|
@@ -14846,7 +14860,7 @@ const ListsWrapper = styled.div `
|
|
|
14846
14860
|
flex-direction: column;
|
|
14847
14861
|
gap: 12px;
|
|
14848
14862
|
`;
|
|
14849
|
-
const DestinationsList = ({ items, onSelectNew, onSelectConfigured }) => {
|
|
14863
|
+
const DestinationsList = ({ items, onSelectNew, onSelectConfigured, isLoadingForDestinationIds }) => {
|
|
14850
14864
|
const { configuredDestinationsUpdateOnly } = useSetupStore();
|
|
14851
14865
|
return items.map((category) => {
|
|
14852
14866
|
const isAlreadyExisting = category.name === DESTINATION_CATEGORIES['EXISTS']['TITLE'];
|
|
@@ -14855,13 +14869,15 @@ const DestinationsList = ({ items, onSelectNew, onSelectConfigured }) => {
|
|
|
14855
14869
|
category.items.map((item) => {
|
|
14856
14870
|
// Following replaceAll() is to create a "legal" data-id (no spaces) for Cypress testing
|
|
14857
14871
|
const key = `select-${category.name.replaceAll(' ', '')}-destination-${item.type}`;
|
|
14858
|
-
const isChecked = item.selected || configuredDestinationsUpdateOnly.some((dest) => dest.id === item.id);
|
|
14859
14872
|
const monitors = Object.keys(item.supportedSignals).filter((signal) => item.supportedSignals[signal].supported);
|
|
14860
|
-
const onClick = isAlreadyExisting ? () => onSelectConfigured(item.id) : () => onSelectNew(item);
|
|
14861
14873
|
const { icon, iconSrc } = getDestinationIcon(item.type);
|
|
14874
|
+
const isChecked = item.selected || configuredDestinationsUpdateOnly.some((dest) => dest.id === item.id);
|
|
14875
|
+
const isLoading = !!isLoadingForDestinationIds.find((id) => id === item.id);
|
|
14876
|
+
const onClick = isAlreadyExisting ? () => onSelectConfigured(item.id) : () => onSelectNew(item);
|
|
14862
14877
|
return (React.createElement(DataTab, { key: key, "data-id": key, title: item.displayName, hoverText: BUTTON_TEXTS.SELECT, onClick: onClick, iconProps: { icon, iconSrc }, visualProps: { monitors, monitorsWithLabels: true }, checkboxProps: {
|
|
14863
14878
|
withCheckbox: isAlreadyExisting,
|
|
14864
14879
|
isChecked,
|
|
14880
|
+
isLoading,
|
|
14865
14881
|
onCheckboxChange: () => onSelectConfigured(item.id),
|
|
14866
14882
|
} }));
|
|
14867
14883
|
})));
|
|
@@ -14925,7 +14941,7 @@ const createConfiguredItems = (destinations, selectedStreamName, configuredDesti
|
|
|
14925
14941
|
},
|
|
14926
14942
|
};
|
|
14927
14943
|
});
|
|
14928
|
-
const ChooseDestinationBody = ({ hidden, categories, potentialDestinations, onSelectNew, onSelectConfigured }) => {
|
|
14944
|
+
const ChooseDestinationBody = ({ hidden, categories, potentialDestinations, onSelectNew, onSelectConfigured, isLoadingForDestinationIds }) => {
|
|
14929
14945
|
const { destinations } = useEntityStore();
|
|
14930
14946
|
const { selectedStreamName } = useDataStreamStore();
|
|
14931
14947
|
const { configuredDestinations, configuredDestinationsUpdateOnly } = useSetupStore();
|
|
@@ -14972,7 +14988,7 @@ const ChooseDestinationBody = ({ hidden, categories, potentialDestinations, onSe
|
|
|
14972
14988
|
React.createElement(Divider, null),
|
|
14973
14989
|
!filteredDestinations.length ? (React.createElement(NoDataFoundWrapper, null,
|
|
14974
14990
|
React.createElement(NoDataFound, { title: 'No destinations found' }))) : (React.createElement(ListsContainer, null,
|
|
14975
|
-
React.createElement(DestinationsList, { items: filteredDestinations, onSelectNew: (dest) => onSelectNew(dest, selectedMonitors), onSelectConfigured: onSelectConfigured })))));
|
|
14991
|
+
React.createElement(DestinationsList, { items: filteredDestinations, onSelectNew: (dest) => onSelectNew(dest, selectedMonitors), onSelectConfigured: onSelectConfigured, isLoadingForDestinationIds: isLoadingForDestinationIds })))));
|
|
14976
14992
|
};
|
|
14977
14993
|
|
|
14978
14994
|
const Container$8 = styled.div `
|
|
@@ -14986,17 +15002,18 @@ const SideMenuWrapper = styled.div `
|
|
|
14986
15002
|
display: none;
|
|
14987
15003
|
}
|
|
14988
15004
|
`;
|
|
14989
|
-
const DestinationModal = ({ isOnboarding, categories, potentialDestinations, createDestination, updateDestination, testConnection }) => {
|
|
15005
|
+
const DestinationModal = ({ isOnboarding, categories, potentialDestinations, createDestination, updateDestination, deleteDestination, testConnection }) => {
|
|
14990
15006
|
const { destinations } = useEntityStore();
|
|
14991
15007
|
const { selectedStreamName } = useDataStreamStore();
|
|
14992
15008
|
const { currentModal, setCurrentModal } = useModalStore();
|
|
14993
|
-
const { addConfiguredDestination, addConfiguredDestinationUpdateOnly } = useSetupStore();
|
|
15009
|
+
const { addConfiguredDestination, addConfiguredDestinationUpdateOnly, removeConfiguredDestinationUpdateOnly, configuredDestinationsUpdateOnly } = useSetupStore();
|
|
14994
15010
|
const isOpen = currentModal === EntityTypes.Destination;
|
|
14995
15011
|
const [selectedItem, setSelectedItem] = useState(undefined);
|
|
14996
15012
|
const { formData, formErrors, handleFormChange, resetFormData, validateForm, setYamlFields, dynamicFields, setDynamicFields, loadFormWithDrawerItem } = useDestinationFormData({
|
|
14997
15013
|
supportedSignals: selectedItem?.supportedSignals,
|
|
14998
15014
|
preLoadedFields: selectedItem?.fields,
|
|
14999
15015
|
});
|
|
15016
|
+
const [isLoadingForDestinationIds, setIsLoadingForDestinationIds] = useState([]);
|
|
15000
15017
|
const getDestPayload = (alreadyConfigDest) => {
|
|
15001
15018
|
const fields = {};
|
|
15002
15019
|
if (!alreadyConfigDest) {
|
|
@@ -15022,7 +15039,7 @@ const DestinationModal = ({ isOnboarding, categories, potentialDestinations, cre
|
|
|
15022
15039
|
},
|
|
15023
15040
|
};
|
|
15024
15041
|
};
|
|
15025
|
-
const handleAdd = (alreadyConfigDest) => {
|
|
15042
|
+
const handleAdd = async (alreadyConfigDest) => {
|
|
15026
15043
|
// Handle new cases from onboarding
|
|
15027
15044
|
if (isOnboarding && !alreadyConfigDest) {
|
|
15028
15045
|
const payload = getDestPayload();
|
|
@@ -15031,7 +15048,13 @@ const DestinationModal = ({ isOnboarding, categories, potentialDestinations, cre
|
|
|
15031
15048
|
// Handle already configured cases from onboarding
|
|
15032
15049
|
else if (isOnboarding && alreadyConfigDest) {
|
|
15033
15050
|
const payload = getDestPayload(alreadyConfigDest);
|
|
15034
|
-
|
|
15051
|
+
const alreadyAdded = configuredDestinationsUpdateOnly.some((dest) => dest.id === alreadyConfigDest.id);
|
|
15052
|
+
if (alreadyAdded) {
|
|
15053
|
+
removeConfiguredDestinationUpdateOnly(alreadyConfigDest);
|
|
15054
|
+
}
|
|
15055
|
+
else {
|
|
15056
|
+
addConfiguredDestinationUpdateOnly(payload);
|
|
15057
|
+
}
|
|
15035
15058
|
}
|
|
15036
15059
|
// Handle new cases from overview
|
|
15037
15060
|
else if (!isOnboarding && !alreadyConfigDest) {
|
|
@@ -15040,8 +15063,15 @@ const DestinationModal = ({ isOnboarding, categories, potentialDestinations, cre
|
|
|
15040
15063
|
// Handle already configured cases from overview
|
|
15041
15064
|
else if (!isOnboarding && alreadyConfigDest) {
|
|
15042
15065
|
const payload = getDestPayload(alreadyConfigDest);
|
|
15043
|
-
const
|
|
15044
|
-
|
|
15066
|
+
const alreadyAdded = payload.dataStreamNames.some((streamName) => streamName === selectedStreamName);
|
|
15067
|
+
setIsLoadingForDestinationIds((prev) => [...prev, alreadyConfigDest.id]);
|
|
15068
|
+
if (alreadyAdded) {
|
|
15069
|
+
await deleteDestination(alreadyConfigDest.id);
|
|
15070
|
+
}
|
|
15071
|
+
else {
|
|
15072
|
+
await updateDestination(alreadyConfigDest.id, loadFormWithDrawerItem(payload));
|
|
15073
|
+
}
|
|
15074
|
+
setIsLoadingForDestinationIds((prev) => prev.filter((id) => id !== alreadyConfigDest.id));
|
|
15045
15075
|
}
|
|
15046
15076
|
else {
|
|
15047
15077
|
console.warn('DestinationModal: handleAdd: No action taken, no destination or already configured destination found');
|
|
@@ -15112,7 +15142,7 @@ const DestinationModal = ({ isOnboarding, categories, potentialDestinations, cre
|
|
|
15112
15142
|
{ stepNumber: 2, title: DISPLAY_TITLES.CONNECTION },
|
|
15113
15143
|
] })),
|
|
15114
15144
|
React.createElement(ModalBody, { style: { margin: '32px 24px 12px 24px' } },
|
|
15115
|
-
React.createElement(ChooseDestinationBody, { hidden: selectedItem !== undefined, categories: categories, potentialDestinations: potentialDestinations, onSelectNew: handleSelectNew, onSelectConfigured: handleSelectConfigured }),
|
|
15145
|
+
React.createElement(ChooseDestinationBody, { hidden: selectedItem !== undefined, categories: categories, potentialDestinations: potentialDestinations, onSelectNew: handleSelectNew, onSelectConfigured: handleSelectConfigured, isLoadingForDestinationIds: isLoadingForDestinationIds }),
|
|
15116
15146
|
selectedItem && (React.createElement(DestinationForm, { categoryItem: selectedItem, formData: formData, formErrors: formErrors, handleFormChange: handleFormChange, dynamicFields: dynamicFields, setDynamicFields: setDynamicFields, validateForm: validateForm, testConnection: testConnection }))))));
|
|
15117
15147
|
};
|
|
15118
15148
|
|
|
@@ -15189,7 +15219,7 @@ const DestinationSelectionForm = ({ isSourcesListEmpty, goToSources, categories,
|
|
|
15189
15219
|
React.createElement(PlusIcon$1, null),
|
|
15190
15220
|
React.createElement(Text, { color: theme.colors.secondary, size: 14, decoration: 'underline', family: 'secondary' }, DISPLAY_TITLES.ADD_DESTINATION))),
|
|
15191
15221
|
React.createElement(DestinationList, { categories: categories, withDelete: true }))),
|
|
15192
|
-
React.createElement(DestinationModal, { isOnboarding: true, categories: categories, potentialDestinations: potentialDestinations, updateDestination: () => { }, createDestination: () => { }, testConnection: testConnection })));
|
|
15222
|
+
React.createElement(DestinationModal, { isOnboarding: true, categories: categories, potentialDestinations: potentialDestinations, updateDestination: async () => { }, createDestination: async () => { }, deleteDestination: async () => { }, testConnection: testConnection })));
|
|
15193
15223
|
};
|
|
15194
15224
|
|
|
15195
15225
|
const columns$2 = [
|
|
@@ -15998,7 +16028,7 @@ const NotSourcesWrapper = styled(CenterThis) `
|
|
|
15998
16028
|
const SelectionCount = styled(Text) `
|
|
15999
16029
|
width: 18px;
|
|
16000
16030
|
`;
|
|
16001
|
-
const SourceList = ({ isModal = false, withInstances = true, filteredNamespacesAndSources, selectedNamespace, onSelectNamespace, selectedSources, onSelectSource }) => {
|
|
16031
|
+
const SourceList = ({ isModal = false, withInstances = true, filteredNamespacesAndSources, selectedNamespace, onSelectNamespace, selectedSources, onSelectSource, selectedFutureApps, onSelectFutureApps, }) => {
|
|
16002
16032
|
const theme = Theme.useTheme();
|
|
16003
16033
|
const { namespacesLoading } = useEntityStore();
|
|
16004
16034
|
const matrix = Object.entries(filteredNamespacesAndSources || {});
|
|
@@ -16008,6 +16038,7 @@ const SourceList = ({ isModal = false, withInstances = true, filteredNamespacesA
|
|
|
16008
16038
|
const NamespaceIcon = getEntityIcon(EntityTypes.Namespace);
|
|
16009
16039
|
return (React.createElement(Container$4, { "$isModal": isModal }, matrix.map(([namespace, sources]) => {
|
|
16010
16040
|
const sourcesForNamespace = selectedSources?.[namespace] || [];
|
|
16041
|
+
const futureAppsForNamespace = selectedFutureApps?.[namespace]?.selected || false;
|
|
16011
16042
|
const onlySelectedSources = sourcesForNamespace.filter(({ selected }) => selected);
|
|
16012
16043
|
const isNamespaceLoaded = sourcesForNamespace.length > 0;
|
|
16013
16044
|
const isNamespaceSelected = selectedNamespace === namespace;
|
|
@@ -16024,6 +16055,9 @@ const SourceList = ({ isModal = false, withInstances = true, filteredNamespacesA
|
|
|
16024
16055
|
React.createElement(NamespaceIcon, null),
|
|
16025
16056
|
React.createElement(Text, null, namespace)),
|
|
16026
16057
|
React.createElement(FlexRow, { "$gap": 12 },
|
|
16058
|
+
onSelectFutureApps && (React.createElement(React.Fragment, null,
|
|
16059
|
+
React.createElement(Toggle, { title: DISPLAY_TITLES.FUTURE_APPS_TITLE, tooltip: DISPLAY_TITLES.FUTURE_APPS_DESCRIPTION, initialValue: futureAppsForNamespace, onChange: (bool) => onSelectFutureApps(bool, namespace), flipHorizontally: true }),
|
|
16060
|
+
React.createElement(Divider, { orientation: 'vertical', length: '12px', margin: '0' }))),
|
|
16027
16061
|
React.createElement(SelectionCount, { size: 10, color: theme.text.grey }, isNamespaceLoaded ? `${onlySelectedSources.length}/${sources.length}` : null),
|
|
16028
16062
|
onSelectNamespace && React.createElement(ExtendArrow, { extend: isNamespaceSelected }))),
|
|
16029
16063
|
(isNamespaceSelected || !onSelectNamespace) &&
|
|
@@ -16057,16 +16091,15 @@ const Container$3 = styled.div `
|
|
|
16057
16091
|
height: fit-content;
|
|
16058
16092
|
overflow-y: scroll;
|
|
16059
16093
|
`;
|
|
16060
|
-
const SetupSummary = ({
|
|
16061
|
-
|
|
16062
|
-
onEditSources, onEditDestinations, categories, }) => {
|
|
16063
|
-
// const { selectedStreamName } = useDataStreamStore();
|
|
16094
|
+
const SetupSummary = ({ onEditStream, onEditSources, onEditDestinations, categories }) => {
|
|
16095
|
+
const { selectedStreamName } = useDataStreamStore();
|
|
16064
16096
|
const { configuredSources, configuredDestinations, configuredDestinationsUpdateOnly } = useSetupStore();
|
|
16065
16097
|
const sourceCount = useMemo(() => Object.values(configuredSources).reduce((total, sourceList) => total + sourceList.filter((s) => s.selected).length, 0), [configuredSources]);
|
|
16066
16098
|
return (React.createElement(ModalBody, { "$isNotModal": true },
|
|
16067
16099
|
React.createElement(FlexColumn, { "$gap": 12 },
|
|
16068
16100
|
React.createElement(SectionTitle, { title: DISPLAY_TITLES.SUMMARY, description: DISPLAY_TITLES.STREAM_CONFIRM }),
|
|
16069
16101
|
React.createElement(Container$3, null,
|
|
16102
|
+
React.createElement(DataCard, { title: DISPLAY_TITLES.STREAM_NAME, action: () => React.createElement(EditButton, { onClick: onEditStream }), data: [{ title: '', value: selectedStreamName }] }),
|
|
16070
16103
|
React.createElement(DataCard, { title: DISPLAY_TITLES.SELECTED_SOURCES, titleBadge: sourceCount, action: () => React.createElement(EditButton, { onClick: onEditSources }) },
|
|
16071
16104
|
React.createElement(SourceList, { filteredNamespacesAndSources: configuredSources, withInstances: false })),
|
|
16072
16105
|
React.createElement(DataCard, { title: DISPLAY_TITLES.SELECTED_DESTINATIONS, titleBadge: configuredDestinations.length + configuredDestinationsUpdateOnly.length, action: () => React.createElement(EditButton, { onClick: onEditDestinations }) },
|
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
import { StatusType, type Condition } from '@/types';
|
|
2
2
|
export declare const getConditionsBooleans: (conditions: Condition[]) => {
|
|
3
|
+
errors: Condition[];
|
|
3
4
|
hasErrors: boolean;
|
|
5
|
+
warnings: Condition[];
|
|
4
6
|
hasWarnings: boolean;
|
|
7
|
+
disableds: Condition[];
|
|
5
8
|
hasDisableds: boolean;
|
|
9
|
+
loadings: Condition[];
|
|
6
10
|
hasLoadings: boolean;
|
|
7
11
|
priorotizedStatus: StatusType | undefined;
|
|
8
12
|
};
|
package/lib/functions.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
export { c as capitalizeFirstLetter, f as flattenObjectKeys, g as
|
|
2
|
-
export { c as compareCondition, d as deepClone, f as filterActions, a as filterDestinations, b as filterDestinationsByStream, e as filterSources, g as filterSourcesByStream, h as formatBytes,
|
|
3
|
-
export { m as getActionIcon, n as getEntityId, o as getInstrumentationRuleIcon, p as getProgrammingLanguageIcon } from './index-
|
|
1
|
+
export { c as capitalizeFirstLetter, f as flattenObjectKeys, g as getConditionsBooleans, a as getMonitorIcon, b as getStatusIcon, i as isValidVersion, m as mapConditions, n as numbersOnly, p as parseBooleanFromString, d as parseJsonStringToPrettyString, r as removeEmptyValuesFromObject, s as safeJsonStringify, e as splitCamelString } from './index-BJpPcCBm.js';
|
|
2
|
+
export { c as compareCondition, d as deepClone, f as filterActions, a as filterDestinations, b as filterDestinationsByStream, e as filterSources, g as filterSourcesByStream, h as formatBytes, j as getContainersIcons, i as getContainersInstrumentedCount, k as getDestinationIcon, l as getEntityIcon, m as getEntityLabel, n as getMetricForEntity, o as getPlatformIcon, p as getPlatformLabel, q as getValueForRange, r as getWorkloadId, s as getYamlFieldsForDestination, t as isOverTime, u as mapDestinationFieldsForDisplay, v as sleep } from './index-CpT8LSxY.js';
|
|
3
|
+
export { m as getActionIcon, n as getEntityId, o as getInstrumentationRuleIcon, p as getProgrammingLanguageIcon } from './index-BRGQ84pJ.js';
|
|
4
4
|
export { g as getIdFromSseTarget, i as isLegalK8sLabel, m as mapExportedSignals } from './index-BlZKWuxe.js';
|
|
5
5
|
import { EntityTypes } from './types.js';
|
|
6
6
|
export { i as isEmpty, s as safeJsonParse } from './index-BV85P9UP.js';
|
|
7
7
|
import 'react';
|
|
8
8
|
import 'styled-components';
|
|
9
|
-
import './index-
|
|
10
|
-
import './index-
|
|
9
|
+
import './index-CeHgnkLY.js';
|
|
10
|
+
import './index-DypjdLnz.js';
|
|
11
11
|
|
|
12
12
|
const cleanObjectEmptyStringsValues = (obj) => {
|
|
13
13
|
const cleanArray = (arr) => arr.filter((item) => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type Dispatch, type SetStateAction } from 'react';
|
|
2
2
|
import { EntityTypes, type FetchSingleNamespace } from '@/types';
|
|
3
3
|
import { type AvailableSource, type AvailableSourcesByNamespace, type NamespaceSelectionFormData, type SourceSelectionFormData } from '@/store';
|
|
4
|
-
export type
|
|
4
|
+
export type NamespaceName = string;
|
|
5
5
|
interface UseSourceFormDataParams {
|
|
6
6
|
fetchSingleNamespace: FetchSingleNamespace;
|
|
7
7
|
}
|
|
@@ -11,11 +11,11 @@ export interface UseSourceSelectionFormData {
|
|
|
11
11
|
getApiSourcesPayload: () => SourceSelectionFormData;
|
|
12
12
|
getApiFutureAppsPayload: () => NamespaceSelectionFormData;
|
|
13
13
|
selectedNamespace: string;
|
|
14
|
-
onSelectNamespace: (namespace:
|
|
14
|
+
onSelectNamespace: (namespace: NamespaceName, selectAll?: boolean) => void;
|
|
15
15
|
selectedSources: SourceSelectionFormData;
|
|
16
|
-
onSelectSource: (source: AvailableSource, namespace?:
|
|
16
|
+
onSelectSource: (source: AvailableSource, namespace?: NamespaceName) => void;
|
|
17
17
|
selectedFutureApps: NamespaceSelectionFormData;
|
|
18
|
-
onSelectFutureApps: (bool: boolean, namespace?:
|
|
18
|
+
onSelectFutureApps: (bool: boolean, namespace?: NamespaceName) => void;
|
|
19
19
|
searchText: string;
|
|
20
20
|
setSearchText: Dispatch<SetStateAction<string>>;
|
|
21
21
|
searchBy: EntityTypes;
|
package/lib/hooks.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { u as useActionFormData, a as useClickNode, b as useClickNotification, c as useDataStreamFormData, d as useDestinationFormData, e as useSessionStorage, f as useSourceFormData, g as useSourceSelectionFormData } from './useSourceSelectionFormData-
|
|
2
|
-
export { u as useContainerSize, a as useCopy, b as useGenericForm, c as useInstrumentationRuleFormData, d as useKeyDown, e as useOnClickOutside, f as useTimeAgo, g as useTransition } from './useTransition-
|
|
1
|
+
export { u as useActionFormData, a as useClickNode, b as useClickNotification, c as useDataStreamFormData, d as useDestinationFormData, e as useSessionStorage, f as useSourceFormData, g as useSourceSelectionFormData } from './useSourceSelectionFormData-CMXqoHZs.js';
|
|
2
|
+
export { u as useContainerSize, a as useCopy, b as useGenericForm, c as useInstrumentationRuleFormData, d as useKeyDown, e as useOnClickOutside, f as useTimeAgo, g as useTransition } from './useTransition-DsrDiKOV.js';
|
|
3
3
|
import './types.js';
|
|
4
|
-
import './index-
|
|
4
|
+
import './index-BRGQ84pJ.js';
|
|
5
5
|
import 'react';
|
|
6
6
|
import 'styled-components';
|
|
7
7
|
import './index-BV85P9UP.js';
|
package/lib/icons.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { T as Theme } from './index-
|
|
2
|
-
export { q as AddClusterInfoIcon, x as CPlusPlusLogo, y as CSharpLogo, C as CodeAttributesIcon, r as DeleteAttributeIcon, z as DotnetLogo, E as ElixirLogo, G as GoLogo, H as HeadersCollectionIcon, t as ImageErrorIcon, J as JavaLogo, K as K8sLogo, v as KafkaLogo, N as MysqlLogo, O as NginxLogo, Q as NodejsLogo, w as PayloadCollectionIcon, U as PhpLogo, P as PiiMaskingIcon, V as PostgresLogo, W as PythonLogo, X as RedisLogo, R as RenameAttributeIcon, Y as RubyLogo, Z as RustLogo, s as SamplerIcon, _ as SwiftLogo } from './index-
|
|
3
|
-
export { C as CheckCircledIcon, E as ErrorTriangleIcon, I as InfoIcon, L as LogsIcon, M as MetricsIcon, O as OdigosLogo, T as TracesIcon, W as WarningTriangleIcon } from './index-
|
|
4
|
-
export { C as CrossCircledIcon, D as DataStreamsIcon, F as FilterIcon, K as KeyIcon, N as NotificationIcon, O as OdigosLogoText, a as OverviewIcon, R as RetryIcon, S as SlackLogo, T as TerminalIcon } from './index-
|
|
5
|
-
export { A as ArrowIcon, h as CheckIcon, C as CodeIcon, a as CopyIcon, i as CrossIcon, E as EditIcon, b as EditedIcon, c as ExtendArrowIcon, f as EyeClosedIcon, g as EyeOpenIcon, L as ListIcon, M as MinusIcon, N as NoDataIcon, d as NotebookIcon, P as PlusIcon, S as SearchIcon, e as SortArrowsIcon, T as TrashIcon, X as XIcon } from './index-
|
|
1
|
+
import { T as Theme } from './index-BRGQ84pJ.js';
|
|
2
|
+
export { q as AddClusterInfoIcon, x as CPlusPlusLogo, y as CSharpLogo, C as CodeAttributesIcon, r as DeleteAttributeIcon, z as DotnetLogo, E as ElixirLogo, G as GoLogo, H as HeadersCollectionIcon, t as ImageErrorIcon, J as JavaLogo, K as K8sLogo, v as KafkaLogo, N as MysqlLogo, O as NginxLogo, Q as NodejsLogo, w as PayloadCollectionIcon, U as PhpLogo, P as PiiMaskingIcon, V as PostgresLogo, W as PythonLogo, X as RedisLogo, R as RenameAttributeIcon, Y as RubyLogo, Z as RustLogo, s as SamplerIcon, _ as SwiftLogo } from './index-BRGQ84pJ.js';
|
|
3
|
+
export { C as CheckCircledIcon, E as ErrorTriangleIcon, I as InfoIcon, L as LogsIcon, M as MetricsIcon, O as OdigosLogo, T as TracesIcon, W as WarningTriangleIcon } from './index-CeHgnkLY.js';
|
|
4
|
+
export { C as CrossCircledIcon, D as DataStreamsIcon, F as FilterIcon, K as KeyIcon, N as NotificationIcon, O as OdigosLogoText, a as OverviewIcon, R as RetryIcon, S as SlackLogo, T as TerminalIcon } from './index-C4aVlsHh.js';
|
|
5
|
+
export { A as ArrowIcon, h as CheckIcon, C as CodeIcon, a as CopyIcon, i as CrossIcon, E as EditIcon, b as EditedIcon, c as ExtendArrowIcon, f as EyeClosedIcon, g as EyeOpenIcon, L as ListIcon, M as MinusIcon, N as NoDataIcon, d as NotebookIcon, P as PlusIcon, S as SearchIcon, e as SortArrowsIcon, T as TrashIcon, X as XIcon } from './index-BUCure0Q.js';
|
|
6
6
|
import React from 'react';
|
|
7
|
-
export { a3 as ActionsIcon, A as AlaudaLogo, a as AlibabaCloudLogo, b as AppDynamicsLogo, c as AwsCloudwatchLogo, d as AwsS3Logo, e as AwsXrayLogo, f as AxiomLogo, B as BetterStackLogo, g as BlobStorageLogo, h as BonreeLogo, C as CauselyLogo, i as ChecklyLogo, j as ChronosphereLogo, k as ClickhouseLogo, l as CoralogixLogo, D as Dash0Logo, m as DatadogLogo, a4 as DestinationsIcon, n as DynatraceLogo, E as ElasticApmLogo, o as ElasticSearchLogo, G as GigapipeLogo, p as GoogleCloudPlatformLogo, q as GrafanaLogo, r as GreptimeLogo, s as GroundcoverLogo, H as HoneycombLogo, t as HyperDxLogo, I as InstanaLogo, J as JaegerLogo, K as KloudmateLogo, L as Last9Logo, u as LightstepLogo, v as LogzioLogo, w as LokiLogo, x as LumigoLogo, M as MiddlewareLogo, a5 as NamespacesIcon, N as NewRelicLogo, O as ObserveLogo, y as OneUptimeLogo, z as OpenObserveLogo, F as OpenTelemetryLogo, P as OpsVerseLogo, Q as OracleLogo, R as PrometheusLogo, S as QrynLogo, T as QuickwitLogo, a6 as RulesIcon, U as SeqLogo, W as SignozLogo, a7 as SourcesIcon, X as SplunkLogo, Y as SumoLogicLogo, Z as TelemetryHubLogo, _ as TempoLogo, $ as TingyunLogo, a0 as TraceloopLogo, a1 as UptraceLogo, a2 as VictoriaMetricsLogo, V as VmLogo } from './index-
|
|
7
|
+
export { a3 as ActionsIcon, A as AlaudaLogo, a as AlibabaCloudLogo, b as AppDynamicsLogo, c as AwsCloudwatchLogo, d as AwsS3Logo, e as AwsXrayLogo, f as AxiomLogo, B as BetterStackLogo, g as BlobStorageLogo, h as BonreeLogo, C as CauselyLogo, i as ChecklyLogo, j as ChronosphereLogo, k as ClickhouseLogo, l as CoralogixLogo, D as Dash0Logo, m as DatadogLogo, a4 as DestinationsIcon, n as DynatraceLogo, E as ElasticApmLogo, o as ElasticSearchLogo, G as GigapipeLogo, p as GoogleCloudPlatformLogo, q as GrafanaLogo, r as GreptimeLogo, s as GroundcoverLogo, H as HoneycombLogo, t as HyperDxLogo, I as InstanaLogo, J as JaegerLogo, K as KloudmateLogo, L as Last9Logo, u as LightstepLogo, v as LogzioLogo, w as LokiLogo, x as LumigoLogo, M as MiddlewareLogo, a5 as NamespacesIcon, N as NewRelicLogo, O as ObserveLogo, y as OneUptimeLogo, z as OpenObserveLogo, F as OpenTelemetryLogo, P as OpsVerseLogo, Q as OracleLogo, R as PrometheusLogo, S as QrynLogo, T as QuickwitLogo, a6 as RulesIcon, U as SeqLogo, W as SignozLogo, a7 as SourcesIcon, X as SplunkLogo, Y as SumoLogicLogo, Z as TelemetryHubLogo, _ as TempoLogo, $ as TingyunLogo, a0 as TraceloopLogo, a1 as UptraceLogo, a2 as VictoriaMetricsLogo, V as VmLogo } from './index-DypjdLnz.js';
|
|
8
8
|
import './types.js';
|
|
9
9
|
import 'styled-components';
|
|
10
10
|
|