@odigos/ui-kit 0.0.37 → 0.0.38
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 +8 -0
- package/lib/components/segment/index.d.ts +1 -0
- package/lib/components.js +8 -8
- package/lib/constants.js +1 -1
- package/lib/containers/multi-source-control/index.d.ts +2 -0
- package/lib/containers/overview-drawer/index.d.ts +1 -0
- package/lib/containers/source-drawer/index.d.ts +1 -0
- package/lib/containers/source-selection-form/index.d.ts +1 -1
- package/lib/containers.js +48 -20
- package/lib/functions.js +5 -5
- package/lib/hooks/useSourceSelectionFormData.d.ts +3 -1
- package/lib/hooks.js +3 -3
- package/lib/icons/common/index.d.ts +1 -0
- package/lib/icons/common/retry-icon/index.d.ts +2 -0
- package/lib/icons/common/retry-icon/retry-icon.stories.d.ts +8 -0
- package/lib/icons.js +7 -7
- package/lib/{index-BGzxan6E.js → index-BcuXR1ve.js} +1 -1
- package/lib/{index-Be0m3TUg.js → index-BsDmE-1M.js} +700 -3780
- package/lib/{index-CNbTSsNJ.js → index-CEBMbbOj.js} +2 -2
- package/lib/{index-BbEmZ4Wj.js → index-CMWGlHc6.js} +2 -2
- package/lib/{index-DJpBLpwG.js → index-Cn0s9o5b.js} +9 -2
- package/lib/{index-7YZOplrB.js → index-Dd01kW5v.js} +1 -1
- package/lib/{index--2v2LKeo.js → index-DtCiWUAb.js} +4 -4
- package/lib/{index-t3OxxFsp.js → index-E-5xGoYC.js} +1 -1
- package/lib/{index-oEjS7cX3.js → index-McgJMLSC.js} +4 -4
- package/lib/{index-aRNtyuuU.js → index-di3Hlzql.js} +1 -1
- package/lib/{index-D8AnbGCE.js → index-jnB_opsW.js} +1 -1
- package/lib/snippets.js +8 -8
- package/lib/store.js +1 -1
- package/lib/theme.js +1 -1
- package/lib/{useSourceSelectionFormData-CH2xUOpu.js → useSourceSelectionFormData-KKJLbIoW.js} +11 -7
- package/lib/{useTransition-0Rz0QKmh.js → useTransition-DE4VdDIO.js} +1 -1
- package/package.json +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.0.38](https://github.com/odigos-io/ui-kit/compare/ui-kit-v0.0.37...ui-kit-v0.0.38) (2025-06-11)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* add buttons to rollout-restart workloads ([#168](https://github.com/odigos-io/ui-kit/issues/168)) ([bd303bb](https://github.com/odigos-io/ui-kit/commit/bd303bb1e4161a2b9a50923d91ff8e9569e20a35))
|
|
9
|
+
* search for sources in source selection form ([#169](https://github.com/odigos-io/ui-kit/issues/169)) ([195f8b8](https://github.com/odigos-io/ui-kit/commit/195f8b85410d46062dc9929b08e371f4d06468d5))
|
|
10
|
+
|
|
3
11
|
## [0.0.37](https://github.com/odigos-io/ui-kit/compare/ui-kit-v0.0.36...ui-kit-v0.0.37) (2025-06-08)
|
|
4
12
|
|
|
5
13
|
|
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-BsDmE-1M.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-BsDmE-1M.js';
|
|
3
|
+
export { C as CancelWarning, D as DeleteWarning } from './index-CEBMbbOj.js';
|
|
4
4
|
import React, { Component, createElement, createContext } from 'react';
|
|
5
|
-
import { T as Theme } from './index-
|
|
5
|
+
import { T as Theme } from './index-di3Hlzql.js';
|
|
6
6
|
import './types.js';
|
|
7
|
-
import './index-
|
|
8
|
-
import './index-
|
|
7
|
+
import './index-jnB_opsW.js';
|
|
8
|
+
import './index-CMWGlHc6.js';
|
|
9
9
|
import 'styled-components';
|
|
10
|
-
import './index-
|
|
10
|
+
import './index-Dd01kW5v.js';
|
|
11
11
|
import './index-BV85P9UP.js';
|
|
12
|
-
import './useTransition-
|
|
12
|
+
import './useTransition-DE4VdDIO.js';
|
|
13
13
|
import 'react-dom';
|
|
14
14
|
|
|
15
15
|
const ErrorBoundaryContext = createContext(null);
|
package/lib/constants.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { A as ACTION_OPTIONS, B as BUTTON_TEXTS, D as DEFAULT_DATA_STREAM_NAME, k as DISPLAY_TITLES, F as FORM_ALERTS, I as INSTRUMENTATION_RULE_OPTIONS, M as MONITORS_OPTIONS, S as STORAGE_KEYS } from './index-
|
|
1
|
+
export { A as ACTION_OPTIONS, B as BUTTON_TEXTS, D as DEFAULT_DATA_STREAM_NAME, k as DISPLAY_TITLES, F as FORM_ALERTS, I as INSTRUMENTATION_RULE_OPTIONS, M as MONITORS_OPTIONS, S as STORAGE_KEYS } from './index-di3Hlzql.js';
|
|
2
2
|
export { D as DESTINATION_CATEGORIES } from './index-Dqief9td.js';
|
|
3
3
|
import 'react';
|
|
4
4
|
import './types.js';
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import { WorkloadId } from '@/types';
|
|
2
3
|
import { type SelectedState } from '@/store';
|
|
3
4
|
interface MultiSourceControlProps {
|
|
4
5
|
totalSourceCount: number;
|
|
5
6
|
uninstrumentSources: (payload: SelectedState['selectedSources']) => void;
|
|
7
|
+
restartWorkloads: (sourceIds: WorkloadId[]) => Promise<void>;
|
|
6
8
|
}
|
|
7
9
|
declare const MultiSourceControl: React.FC<MultiSourceControlProps>;
|
|
8
10
|
export { MultiSourceControl, type MultiSourceControlProps };
|
|
@@ -16,6 +16,7 @@ interface OverviewDrawerProps extends PropsWithChildren {
|
|
|
16
16
|
onDelete?: () => void;
|
|
17
17
|
onCancel?: () => void;
|
|
18
18
|
tabs?: DrawerProps['header']['tabs'];
|
|
19
|
+
headerActionButtons?: DrawerProps['header']['actionButtons'];
|
|
19
20
|
}
|
|
20
21
|
interface OverviewDrawerRef {
|
|
21
22
|
closeDrawer: () => void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type
|
|
2
|
+
import { type FetchSingleNamespace } from '@/types';
|
|
3
3
|
import { type AvailableSourcesByNamespace, type NamespaceSelectionFormData, type SourceSelectionFormData } from '@/store';
|
|
4
4
|
interface SourceSelectionFormProps {
|
|
5
5
|
isModal?: boolean;
|
package/lib/containers.js
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
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 { k 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, l as getActionIcon, f as useModalStore, F as FORM_ALERTS, d as useFilterStore, M as MONITORS_OPTIONS, t as styleInject, i as useSelectedStore, e as useInstrumentStore, n as getInstrumentationRuleIcon, a as useDataStreamStore, m as getEntityId, S as STORAGE_KEYS, j as useSetupStore, I as INSTRUMENTATION_RULE_OPTIONS, u as useDarkMode } from './index-
|
|
3
|
+
import { k 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, l as getActionIcon, f as useModalStore, F as FORM_ALERTS, d as useFilterStore, M as MONITORS_OPTIONS, t as styleInject, i as useSelectedStore, e as useInstrumentStore, n as getInstrumentationRuleIcon, a as useDataStreamStore, m as getEntityId, S as STORAGE_KEYS, j as useSetupStore, I as INSTRUMENTATION_RULE_OPTIONS, u as useDarkMode } from './index-di3Hlzql.js';
|
|
4
4
|
import { ActionType, ActionKeyTypes, InputTypes, FieldTypes, EntityTypes, StatusType, Crud, OtherStatus, NodeTypes, AddNodeTypes, EdgeTypes, SignalType, HeadersCollectionKeyTypes, CodeAttributesKeyTypes, PayloadCollectionKeyTypes, InstrumentationRuleType } 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, I as IconButton, e as DataCardFields, s as IconsNav, p as IconGroup } from './index-
|
|
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, I as IconButton, e as DataCardFields, s as IconsNav, p as IconGroup } from './index-BsDmE-1M.js';
|
|
6
6
|
import { i as isEmpty, s as safeJsonParse } from './index-BV85P9UP.js';
|
|
7
|
-
import { i as CheckCircledIcon, O as OdigosLogo } from './index-
|
|
8
|
-
import { C as CrossCircledIcon, O as OdigosLogoText, a as OverviewIcon, F as FilterIcon, D as DataStreamsIcon, 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 } from './index-
|
|
12
|
-
import { T as TrashIcon, S as SearchIcon, P as PlusIcon$1, f as CheckIcon, A as ArrowIcon, a as CopyIcon, g as CrossIcon } from './index-
|
|
13
|
-
import { D as DeleteWarning, C as CancelWarning } from './index-
|
|
14
|
-
import { m as mapConditions, b as getStatusIcon, c as capitalizeFirstLetter } from './index-
|
|
15
|
-
import { f as filterActions, i as getConditionsBooleans, n as getEntityLabel, m as getEntityIcon, w as sleep$1, p as getPlatformIcon, q as getPlatformLabel, h as formatBytes, k as getContainersIcons, r as getValueForRange, l as getDestinationIcon, g as filterSourcesByStream, e as filterSources, b as filterDestinationsByStream, a as filterDestinations, v as mapDestinationFieldsForDisplay, c as compareCondition, t as getYamlFieldsForDestination, d as deepClone, o as getMetricForEntity, s as getWorkloadId, j as getContainersInstrumentedCount, u as isOverTime } from './index
|
|
7
|
+
import { i as CheckCircledIcon, O as OdigosLogo } from './index-Dd01kW5v.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-Cn0s9o5b.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-KKJLbIoW.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-DE4VdDIO.js';
|
|
11
|
+
import { E as EditIcon } from './index-E-5xGoYC.js';
|
|
12
|
+
import { T as TrashIcon, S as SearchIcon, P as PlusIcon$1, f as CheckIcon, A as ArrowIcon, a as CopyIcon, g as CrossIcon } from './index-jnB_opsW.js';
|
|
13
|
+
import { D as DeleteWarning, C as CancelWarning } from './index-CEBMbbOj.js';
|
|
14
|
+
import { m as mapConditions, b as getStatusIcon, c as capitalizeFirstLetter } from './index-CMWGlHc6.js';
|
|
15
|
+
import { f as filterActions, i as getConditionsBooleans, n as getEntityLabel, m as getEntityIcon, w as sleep$1, p as getPlatformIcon, q as getPlatformLabel, h as formatBytes, k as getContainersIcons, r as getValueForRange, l as getDestinationIcon, g as filterSourcesByStream, e as filterSources, b as filterDestinationsByStream, a as filterDestinations, v as mapDestinationFieldsForDisplay, c as compareCondition, t as getYamlFieldsForDestination, d as deepClone, o as getMetricForEntity, s as getWorkloadId, j as getContainersInstrumentedCount, u as isOverTime } from './index-DtCiWUAb.js';
|
|
16
16
|
import { createPortal } from 'react-dom';
|
|
17
17
|
import { m as mapExportedSignals } from './index-BlZKWuxe.js';
|
|
18
|
-
import { N as NoteBackToSummary, E as EditButton } from './index-
|
|
18
|
+
import { N as NoteBackToSummary, E as EditButton } from './index-McgJMLSC.js';
|
|
19
19
|
import { D as DESTINATION_CATEGORIES } from './index-Dqief9td.js';
|
|
20
|
-
import { a6 as RulesIcon, a7 as SourcesIcon, a3 as ActionsIcon, a4 as DestinationsIcon } from './index-
|
|
20
|
+
import { a6 as RulesIcon, a7 as SourcesIcon, a3 as ActionsIcon, a4 as DestinationsIcon } from './index-BcuXR1ve.js';
|
|
21
21
|
|
|
22
22
|
const buildCard$3 = (action) => {
|
|
23
23
|
const { type, spec: { actionName, notes, signals, disabled, collectContainerAttributes, collectReplicaSetAttributes, collectWorkloadId, collectClusterId, labelsAttributes, annotationsAttributes, clusterAttributes, attributeNamesToDelete, renames, piiCategories, fallbackSamplingRatio, samplingPercentage, endpointsFilters, servicesNameFilters, attributeFilters, }, } = action;
|
|
@@ -529,7 +529,7 @@ const ActionForm = ({ isUpdate, action, formData, formErrors, handleFormChange }
|
|
|
529
529
|
React.createElement(TextArea, { title: 'Notes', value: formData['notes'], onChange: ({ target: { value } }) => handleFormChange('notes', value), errorMessage: formErrors['notes'] })));
|
|
530
530
|
};
|
|
531
531
|
|
|
532
|
-
const OverviewDrawer = forwardRef(({ children, width = 640, title, titleTooltip, hideEditTitleFromEdit, icons, iconSrcs, isEdit = false, isFormDirty = false, isLastItem = false, onEdit, onSave, onDelete, onCancel, tabs }, drawerRef) => {
|
|
532
|
+
const OverviewDrawer = forwardRef(({ children, width = 640, title, titleTooltip, hideEditTitleFromEdit, icons, iconSrcs, isEdit = false, isFormDirty = false, isLastItem = false, onEdit, onSave, onDelete, onCancel, tabs, headerActionButtons, }, drawerRef) => {
|
|
533
533
|
const theme = Theme.useTheme();
|
|
534
534
|
const { isThisPending } = usePendingStore();
|
|
535
535
|
const { addNotification } = useNotificationStore();
|
|
@@ -596,7 +596,7 @@ const OverviewDrawer = forwardRef(({ children, width = 640, title, titleTooltip,
|
|
|
596
596
|
hideFromHistory: true,
|
|
597
597
|
});
|
|
598
598
|
};
|
|
599
|
-
const actionButtons = [];
|
|
599
|
+
const actionButtons = headerActionButtons || [];
|
|
600
600
|
if (!!onEdit && !isEdit)
|
|
601
601
|
actionButtons.push({
|
|
602
602
|
'data-id': 'drawer-edit',
|
|
@@ -668,6 +668,8 @@ const EditTitle = forwardRef(({ title }, ref) => {
|
|
|
668
668
|
}));
|
|
669
669
|
return React.createElement(Input, { "data-id": 'title', value: inputValue, onChange: (e) => setInputValue(e.target.value) });
|
|
670
670
|
});
|
|
671
|
+
EditTitle.displayName = EditTitle.name;
|
|
672
|
+
OverviewDrawer.displayName = OverviewDrawer.name;
|
|
671
673
|
|
|
672
674
|
const FormContainer$4 = styled.div `
|
|
673
675
|
width: 100%;
|
|
@@ -13406,7 +13408,7 @@ const createEdge = (edgeId, params) => {
|
|
|
13406
13408
|
const buildEdges = ({ theme, nodes, metrics, containerHeight }) => {
|
|
13407
13409
|
const edges = [];
|
|
13408
13410
|
const actionNodeId = nodes.find(({ id: nodeId }) => [`${EntityTypes.Action}-${NodeTypes.Frame}`, `${EntityTypes.Action}-${NodeTypes.Add}`].includes(nodeId))?.id;
|
|
13409
|
-
const scrollTopLimit = -
|
|
13411
|
+
const scrollTopLimit = -nodeHeight$5 / 2 + framePadding$4;
|
|
13410
13412
|
const scrollBottomLimit = Math.floor(containerHeight / nodeHeight$5) * nodeHeight$5 - (nodeHeight$5 / 2 + framePadding$4);
|
|
13411
13413
|
const isBaseNode = (nodeType) => nodeType === NodeTypes.Base || nodeType === NodeTypes.Edged;
|
|
13412
13414
|
nodes.forEach(({ type: nodeType, id: nodeId, data: { type: entityType, id: entityId, status }, position }) => {
|
|
@@ -15604,7 +15606,7 @@ const Container$5 = styled.div `
|
|
|
15604
15606
|
border: 1px solid ${({ theme }) => theme.colors.border};
|
|
15605
15607
|
background-color: ${({ theme }) => theme.colors.dropdown_bg};
|
|
15606
15608
|
`;
|
|
15607
|
-
const MultiSourceControl = ({ totalSourceCount, uninstrumentSources }) => {
|
|
15609
|
+
const MultiSourceControl = ({ totalSourceCount, uninstrumentSources, restartWorkloads }) => {
|
|
15608
15610
|
const theme = Theme.useTheme();
|
|
15609
15611
|
const Transition = useTransition({
|
|
15610
15612
|
container: Container$5,
|
|
@@ -15623,6 +15625,14 @@ const MultiSourceControl = ({ totalSourceCount, uninstrumentSources }) => {
|
|
|
15623
15625
|
const onDeselect = () => {
|
|
15624
15626
|
setSelectedSources({});
|
|
15625
15627
|
};
|
|
15628
|
+
const onRestart = () => {
|
|
15629
|
+
const payload = [];
|
|
15630
|
+
Object.values(selectedSources).forEach((sources) => {
|
|
15631
|
+
payload.push(...sources.map((source) => getWorkloadId(source)));
|
|
15632
|
+
});
|
|
15633
|
+
restartWorkloads(payload);
|
|
15634
|
+
onDeselect();
|
|
15635
|
+
};
|
|
15626
15636
|
const onDelete = () => {
|
|
15627
15637
|
const payload = {};
|
|
15628
15638
|
Object.entries(selectedSources).forEach(([ns, sources]) => {
|
|
@@ -15642,6 +15652,9 @@ const MultiSourceControl = ({ totalSourceCount, uninstrumentSources }) => {
|
|
|
15642
15652
|
React.createElement(Divider, { orientation: 'vertical', length: '16px' }),
|
|
15643
15653
|
React.createElement(Button, { variant: 'tertiary', onClick: onDeselect },
|
|
15644
15654
|
React.createElement(Text, { family: 'secondary', decoration: 'underline' }, "Deselect")),
|
|
15655
|
+
React.createElement(Button, { variant: 'tertiary', onClick: onRestart },
|
|
15656
|
+
React.createElement(RetryIcon, null),
|
|
15657
|
+
React.createElement(Text, { family: 'secondary', decoration: 'underline' }, "Restart")),
|
|
15645
15658
|
React.createElement(Button, { variant: 'tertiary', onClick: () => setIsWarnModalOpen(true) },
|
|
15646
15659
|
React.createElement(TrashIcon, null),
|
|
15647
15660
|
React.createElement(Text, { family: 'secondary', decoration: 'underline', color: theme.text.error }, "Uninstrument"))),
|
|
@@ -16121,7 +16134,7 @@ const DataContainer$1 = styled.div `
|
|
|
16121
16134
|
flex-direction: column;
|
|
16122
16135
|
gap: 12px;
|
|
16123
16136
|
`;
|
|
16124
|
-
const SourceDrawer = ({ persistSources, updateSource, fetchDescribeSource }) => {
|
|
16137
|
+
const SourceDrawer = ({ persistSources, updateSource, fetchDescribeSource, restartWorkloads }) => {
|
|
16125
16138
|
const { sources } = useEntityStore();
|
|
16126
16139
|
const { selectedStreamName } = useDataStreamStore();
|
|
16127
16140
|
const { drawerType, drawerEntityId } = useDrawerStore();
|
|
@@ -16196,6 +16209,15 @@ const SourceDrawer = ({ persistSources, updateSource, fetchDescribeSource }) =>
|
|
|
16196
16209
|
onClick: () => setSelectedTab(Tabs.Pods),
|
|
16197
16210
|
selected: selectedTab === Tabs.Pods,
|
|
16198
16211
|
},
|
|
16212
|
+
], headerActionButtons: [
|
|
16213
|
+
{
|
|
16214
|
+
'data-id': 'rollout-restart',
|
|
16215
|
+
variant: 'tertiary',
|
|
16216
|
+
onClick: () => restartWorkloads([drawerEntityId]),
|
|
16217
|
+
children: (React.createElement(React.Fragment, null,
|
|
16218
|
+
React.createElement(RetryIcon, null),
|
|
16219
|
+
React.createElement(Text, { size: 14, family: 'secondary', decoration: 'underline' }, "Restart"))),
|
|
16220
|
+
},
|
|
16199
16221
|
] }, selectedTab === Tabs.Overview ? (isEditing ? (React.createElement(FormContainer, null,
|
|
16200
16222
|
React.createElement(SourceForm, { formData: formData, handleFormChange: (...params) => {
|
|
16201
16223
|
setIsFormDirty(true);
|
|
@@ -16211,11 +16233,12 @@ const ActionsRow = styled(FlexRow) `
|
|
|
16211
16233
|
justify-content: space-between;
|
|
16212
16234
|
`;
|
|
16213
16235
|
const SearchWrapper = styled.div `
|
|
16214
|
-
width:
|
|
16236
|
+
max-width: 350px;
|
|
16215
16237
|
`;
|
|
16216
16238
|
const SourceSelectionForm = forwardRef(({ isModal, fetchSingleNamespace, onClickSummary }, ref) => {
|
|
16239
|
+
const theme = Theme.useTheme();
|
|
16217
16240
|
const formState = useSourceSelectionFormData({ fetchSingleNamespace });
|
|
16218
|
-
const { availableSources, selectedSources, getApiSourcesPayload, getApiFutureAppsPayload, searchText, setSearchText, showSelectedOnly, setShowSelectedOnly } = formState;
|
|
16241
|
+
const { availableSources, selectedSources, getApiSourcesPayload, getApiFutureAppsPayload, searchText, setSearchText, searchBy, setSearchBy, showSelectedOnly, setShowSelectedOnly } = formState;
|
|
16219
16242
|
useImperativeHandle(ref, () => ({
|
|
16220
16243
|
getFormValues: () => ({
|
|
16221
16244
|
initial: availableSources,
|
|
@@ -16232,10 +16255,15 @@ const SourceSelectionForm = forwardRef(({ isModal, fetchSingleNamespace, onClick
|
|
|
16232
16255
|
React.createElement(ActionsRow, null,
|
|
16233
16256
|
React.createElement(SearchWrapper, null,
|
|
16234
16257
|
React.createElement(Input, { placeholder: DISPLAY_TITLES.SEARCH_NAMESPACES, icon: SearchIcon, value: searchText, onChange: (e) => setSearchText(e.target.value.toLowerCase()) })),
|
|
16258
|
+
React.createElement(Segment, { options: [
|
|
16259
|
+
{ label: DISPLAY_TITLES.SOURCE, value: EntityTypes.Source, selectedBgColor: theme.text.secondary, selectedTextColor: theme.text.primary },
|
|
16260
|
+
{ label: DISPLAY_TITLES.NAMESPACE, value: EntityTypes.Namespace, selectedBgColor: theme.text.secondary, selectedTextColor: theme.text.primary },
|
|
16261
|
+
], selected: searchBy, setSelected: setSearchBy }),
|
|
16235
16262
|
React.createElement(Toggle, { title: DISPLAY_TITLES.SHOW_SELECTED_ONLY, initialValue: showSelectedOnly, onChange: setShowSelectedOnly }))),
|
|
16236
16263
|
React.createElement(Divider, null),
|
|
16237
16264
|
React.createElement(SourceList, { isModal: isModal, ...formState }))));
|
|
16238
16265
|
});
|
|
16266
|
+
SourceSelectionForm.displayName = SourceSelectionForm.name;
|
|
16239
16267
|
|
|
16240
16268
|
const SourceModal = ({ fetchSingleNamespace, persistSources }) => {
|
|
16241
16269
|
const { currentModal, setCurrentModal } = useModalStore();
|
package/lib/functions.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
export { c as capitalizeFirstLetter, f as flattenObjectKeys, g as getMonitorIcon, a as getProgrammingLanguageIcon, b as getStatusIcon, m as mapConditions, n as numbersOnly, p as parseJsonStringToPrettyString, r as removeEmptyValuesFromObject, s as safeJsonStringify, d as splitCamelString } from './index-
|
|
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, i as getConditionsBooleans, k as getContainersIcons, j as getContainersInstrumentedCount, l as getDestinationIcon, m as getEntityIcon, n as getEntityLabel, o as getMetricForEntity, p as getPlatformIcon, q as getPlatformLabel, r as getValueForRange, s as getWorkloadId, t as getYamlFieldsForDestination, u as isOverTime, v as mapDestinationFieldsForDisplay, w as sleep } from './index
|
|
3
|
-
export { l as getActionIcon, m as getEntityId, n as getInstrumentationRuleIcon } from './index-
|
|
1
|
+
export { c as capitalizeFirstLetter, f as flattenObjectKeys, g as getMonitorIcon, a as getProgrammingLanguageIcon, b as getStatusIcon, m as mapConditions, n as numbersOnly, p as parseJsonStringToPrettyString, r as removeEmptyValuesFromObject, s as safeJsonStringify, d as splitCamelString } from './index-CMWGlHc6.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, i as getConditionsBooleans, k as getContainersIcons, j as getContainersInstrumentedCount, l as getDestinationIcon, m as getEntityIcon, n as getEntityLabel, o as getMetricForEntity, p as getPlatformIcon, q as getPlatformLabel, r as getValueForRange, s as getWorkloadId, t as getYamlFieldsForDestination, u as isOverTime, v as mapDestinationFieldsForDisplay, w as sleep } from './index-DtCiWUAb.js';
|
|
3
|
+
export { l as getActionIcon, m as getEntityId, n as getInstrumentationRuleIcon } from './index-di3Hlzql.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-Dd01kW5v.js';
|
|
10
|
+
import './index-BcuXR1ve.js';
|
|
11
11
|
|
|
12
12
|
const cleanObjectEmptyStringsValues = (obj) => {
|
|
13
13
|
const cleanArray = (arr) => arr.filter((item) => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type Dispatch, type SetStateAction } from 'react';
|
|
2
|
-
import type
|
|
2
|
+
import { EntityTypes, type FetchSingleNamespace } from '@/types';
|
|
3
3
|
import { type AvailableSource, type AvailableSourcesByNamespace, type NamespaceSelectionFormData, type SourceSelectionFormData } from '@/store';
|
|
4
4
|
export type SelectedNamespace = string;
|
|
5
5
|
interface UseSourceFormDataParams {
|
|
@@ -18,6 +18,8 @@ export interface UseSourceSelectionFormData {
|
|
|
18
18
|
onSelectFutureApps: (bool: boolean, namespace?: SelectedNamespace) => void;
|
|
19
19
|
searchText: string;
|
|
20
20
|
setSearchText: Dispatch<SetStateAction<string>>;
|
|
21
|
+
searchBy: EntityTypes;
|
|
22
|
+
setSearchBy: Dispatch<SetStateAction<EntityTypes>>;
|
|
21
23
|
showSelectedOnly: boolean;
|
|
22
24
|
setShowSelectedOnly: Dispatch<SetStateAction<boolean>>;
|
|
23
25
|
}
|
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-KKJLbIoW.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-DE4VdDIO.js';
|
|
3
3
|
import './types.js';
|
|
4
|
-
import './index-
|
|
4
|
+
import './index-di3Hlzql.js';
|
|
5
5
|
import 'react';
|
|
6
6
|
import 'styled-components';
|
|
7
7
|
import './index-BV85P9UP.js';
|
|
@@ -13,6 +13,7 @@ export * from './list-icon/index';
|
|
|
13
13
|
export * from './no-data-icon/index';
|
|
14
14
|
export * from './notebook-icon/index';
|
|
15
15
|
export * from './notification-icon/index';
|
|
16
|
+
export * from './retry-icon/index';
|
|
16
17
|
export * from './search-icon/index';
|
|
17
18
|
export * from './sort-arrows-icon/index';
|
|
18
19
|
export * from './terminal-icon/index';
|
package/lib/icons.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { T as Theme } from './index-
|
|
2
|
-
export { p as AddClusterInfoIcon, C as CodeAttributesIcon, q as DeleteAttributeIcon, H as HeadersCollectionIcon, o as ImageErrorIcon, K as K8sLogo, s as PayloadCollectionIcon, P as PiiMaskingIcon, R as RenameAttributeIcon, r as SamplerIcon } from './index-
|
|
3
|
-
export { C as CPlusPlusLogo, d as CSharpLogo, i as CheckCircledIcon, D as DotnetLogo, E as ElixirLogo, h as ErrorTriangleIcon, G as GoLogo, I as InfoIcon, J as JavaLogo, K as KafkaLogo, L as LogsIcon, g as MetricsIcon, M as MysqlLogo, N as NginxLogo, f as NodejsLogo, O as OdigosLogo, c as PhpLogo, P as PostgresLogo, e as PythonLogo, R as RedisLogo, b as RubyLogo, a as RustLogo, S as SwiftLogo, 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, S as SlackLogo, T as TerminalIcon } from './index-
|
|
5
|
-
export { A as ArrowIcon, f as CheckIcon, C as CodeIcon, a as CopyIcon, g as CrossIcon, E as ExtendArrowIcon, d as EyeClosedIcon, e as EyeOpenIcon, L as ListIcon, M as MinusIcon, N as NoDataIcon, b as NotebookIcon, P as PlusIcon, S as SearchIcon, c as SortArrowsIcon, T as TrashIcon, X as XIcon } from './index-
|
|
1
|
+
import { T as Theme } from './index-di3Hlzql.js';
|
|
2
|
+
export { p as AddClusterInfoIcon, C as CodeAttributesIcon, q as DeleteAttributeIcon, H as HeadersCollectionIcon, o as ImageErrorIcon, K as K8sLogo, s as PayloadCollectionIcon, P as PiiMaskingIcon, R as RenameAttributeIcon, r as SamplerIcon } from './index-di3Hlzql.js';
|
|
3
|
+
export { C as CPlusPlusLogo, d as CSharpLogo, i as CheckCircledIcon, D as DotnetLogo, E as ElixirLogo, h as ErrorTriangleIcon, G as GoLogo, I as InfoIcon, J as JavaLogo, K as KafkaLogo, L as LogsIcon, g as MetricsIcon, M as MysqlLogo, N as NginxLogo, f as NodejsLogo, O as OdigosLogo, c as PhpLogo, P as PostgresLogo, e as PythonLogo, R as RedisLogo, b as RubyLogo, a as RustLogo, S as SwiftLogo, T as TracesIcon, W as WarningTriangleIcon } from './index-Dd01kW5v.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-Cn0s9o5b.js';
|
|
5
|
+
export { A as ArrowIcon, f as CheckIcon, C as CodeIcon, a as CopyIcon, g as CrossIcon, E as ExtendArrowIcon, d as EyeClosedIcon, e as EyeOpenIcon, L as ListIcon, M as MinusIcon, N as NoDataIcon, b as NotebookIcon, P as PlusIcon, S as SearchIcon, c as SortArrowsIcon, T as TrashIcon, X as XIcon } from './index-jnB_opsW.js';
|
|
6
6
|
import React from 'react';
|
|
7
|
-
export { E as EditIcon } from './index-
|
|
8
|
-
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 { E as EditIcon } from './index-E-5xGoYC.js';
|
|
8
|
+
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-BcuXR1ve.js';
|
|
9
9
|
import './types.js';
|
|
10
10
|
import 'styled-components';
|
|
11
11
|
|