@odigos/ui-kit 0.0.63 → 0.0.65

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.
Files changed (35) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/lib/components/key-value-input-list/index.d.ts +2 -0
  3. package/lib/components/toggle/index.d.ts +1 -1
  4. package/lib/components.js +7 -7
  5. package/lib/containers/index.d.ts +1 -0
  6. package/lib/containers/system-settings/index.d.ts +8 -0
  7. package/lib/containers/system-settings/settings/collector-gateway-settings.d.ts +4 -0
  8. package/lib/containers/system-settings/settings/collector-node-settings.d.ts +4 -0
  9. package/lib/containers/system-settings/settings/options.d.ts +7 -0
  10. package/lib/containers/system-settings/settings/other-settings.d.ts +4 -0
  11. package/lib/containers/system-settings/settings/styled.d.ts +2 -0
  12. package/lib/containers/system-settings/settings/types.d.ts +5 -0
  13. package/lib/containers/system-settings/settings/ui-settings.d.ts +4 -0
  14. package/lib/containers/system-settings/settings/user-instrumnetation-envs-settings.d.ts +4 -0
  15. package/lib/containers.js +277 -22
  16. package/lib/functions.js +2 -2
  17. package/lib/hooks/useGenericForm.d.ts +1 -1
  18. package/lib/hooks.js +3 -3
  19. package/lib/icons/common/gear-icon/index.d.ts +2 -0
  20. package/lib/icons/common/index.d.ts +1 -0
  21. package/lib/icons.js +2 -2
  22. package/lib/{index-1fcb0269.js → index-391844c6.js} +1 -8
  23. package/lib/{index-9e56485b.js → index-42f40e7c.js} +2 -7
  24. package/lib/{index-ec555530.js → index-5e5f7bda.js} +6 -1
  25. package/lib/{index-eb03f43f.js → index-7074fb24.js} +1 -1
  26. package/lib/{index-56ab40b8.js → index-c1df4281.js} +16 -1
  27. package/lib/{index-61caa474.js → index-f2da9ad4.js} +68 -72
  28. package/lib/mock-data/config/index.d.ts +2 -0
  29. package/lib/mock-data/index.d.ts +1 -0
  30. package/lib/snippets.js +5 -5
  31. package/lib/types/config/index.d.ts +89 -0
  32. package/lib/types/index.d.ts +1 -0
  33. package/lib/types.js +43 -1
  34. package/lib/{useTransition-750816e0.js → useTransition-c2aef0e4.js} +33 -13
  35. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.0.65](https://github.com/odigos-io/ui-kit/compare/ui-kit-v0.0.64...ui-kit-v0.0.65) (2025-07-21)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * close on save ([9579c54](https://github.com/odigos-io/ui-kit/commit/9579c5474b5bf960828a83286455523a9a0deaa1))
9
+ * props, and exports for system settings ([#263](https://github.com/odigos-io/ui-kit/issues/263)) ([7279e3c](https://github.com/odigos-io/ui-kit/commit/7279e3ca043de51a4e7cf659427284e563d810ec))
10
+
11
+ ## [0.0.64](https://github.com/odigos-io/ui-kit/compare/ui-kit-v0.0.63...ui-kit-v0.0.64) (2025-07-21)
12
+
13
+
14
+ ### Features
15
+
16
+ * add drawer for "system settings" ([#261](https://github.com/odigos-io/ui-kit/issues/261)) ([cd3eb2e](https://github.com/odigos-io/ui-kit/commit/cd3eb2e986ffdf4796c4d98423405cfa7f1bfc2c))
17
+
3
18
  ## [0.0.63](https://github.com/odigos-io/ui-kit/compare/ui-kit-v0.0.62...ui-kit-v0.0.63) (2025-07-21)
4
19
 
5
20
 
@@ -9,10 +9,12 @@ interface KeyValueInputsListProps {
9
9
  onChange?: (validKeyValuePairs: Row[]) => void;
10
10
  title?: string;
11
11
  tooltip?: string;
12
+ disabled?: boolean;
12
13
  required?: boolean;
13
14
  errorMessage?: string;
14
15
  keyPlaceholder?: string;
15
16
  valuePlaceholder?: string;
17
+ inputMaxWidth?: number;
16
18
  }
17
19
  declare const KeyValueInputsList: FC<KeyValueInputsListProps>;
18
20
  export { KeyValueInputsList, type KeyValueInputsListProps };
@@ -1,6 +1,6 @@
1
1
  import { type FC } from 'react';
2
2
  interface ToggleProps {
3
- title: string;
3
+ title?: string;
4
4
  tooltip?: string;
5
5
  initialValue?: boolean;
6
6
  onChange?: (value: boolean) => void;
package/lib/components.js CHANGED
@@ -1,16 +1,16 @@
1
- import { B as Button } from './index-61caa474.js';
2
- export { A as AutocompleteInput, a as Badge, a6 as CenterThis, C as Checkbox, b as Code, c as ConditionDetails, D as DataCard, e as DataCardFieldTypes, d as DataCardFields, f as DataFinger, g as DataTab, h as DescribeRow, i as Divider, j as DocsButton, k as Drawer, m as DrawerFooter, l as DrawerHeader, n as Dropdown, E as ExtendArrow, F as FadeLoader, o as FieldError, p as FieldLabel, a5 as FlexColumn, a4 as FlexRow, H as Header, I as IconButton, q as IconGroup, r as IconTitleBadge, s as IconWrapped, t as IconsNav, u as ImageControlled, v as Input, w as InputList, x as InputTable, y as InteractiveTable, K as KeyValueInputsList, M as Modal, a9 as ModalBody, z as MonitorsCheckboxes, G as MonitorsIcons, N as NavigationButtons, J as NoDataFound, L as NotificationNote, a8 as Overlay, P as Popup, O as PopupForm, S as ScrollX, Q as SectionTitle, R as Segment, U as SelectionButton, V as SkeletonLoader, W as Status, X as Stepper, Y as TabList, aa as TableContainer, ab as TableTitleWrap, ac as TableWrap, Z as Tag, _ as Text, $ as TextArea, a0 as Toggle, T as ToggleCodeComponent, a1 as Tooltip, a2 as TraceLoader, a7 as VerticalScroll, a3 as WarningModal } from './index-61caa474.js';
3
- export { C as CancelWarning, D as DeleteWarning } from './index-eb03f43f.js';
1
+ import { B as Button } from './index-f2da9ad4.js';
2
+ export { A as AutocompleteInput, a as Badge, a6 as CenterThis, C as Checkbox, b as Code, c as ConditionDetails, D as DataCard, e as DataCardFieldTypes, d as DataCardFields, f as DataFinger, g as DataTab, h as DescribeRow, i as Divider, j as DocsButton, k as Drawer, m as DrawerFooter, l as DrawerHeader, n as Dropdown, E as ExtendArrow, F as FadeLoader, o as FieldError, p as FieldLabel, a5 as FlexColumn, a4 as FlexRow, H as Header, I as IconButton, q as IconGroup, r as IconTitleBadge, s as IconWrapped, t as IconsNav, u as ImageControlled, v as Input, w as InputList, x as InputTable, y as InteractiveTable, K as KeyValueInputsList, M as Modal, a9 as ModalBody, z as MonitorsCheckboxes, G as MonitorsIcons, N as NavigationButtons, J as NoDataFound, L as NotificationNote, a8 as Overlay, P as Popup, O as PopupForm, S as ScrollX, Q as SectionTitle, R as Segment, U as SelectionButton, V as SkeletonLoader, W as Status, X as Stepper, Y as TabList, aa as TableContainer, ab as TableTitleWrap, ac as TableWrap, Z as Tag, _ as Text, $ as TextArea, a0 as Toggle, T as ToggleCodeComponent, a1 as Tooltip, a2 as TraceLoader, a7 as VerticalScroll, a3 as WarningModal } from './index-f2da9ad4.js';
3
+ export { C as CancelWarning, D as DeleteWarning } from './index-7074fb24.js';
4
4
  import React, { createContext, Component, createElement } from 'react';
5
5
  import { T as Theme } from './index-bd48e6e2.js';
6
+ import 'styled-components';
7
+ import './index-391844c6.js';
6
8
  import './types.js';
7
- import './index-1fcb0269.js';
9
+ import './index-5e5f7bda.js';
8
10
  import './index-58440c5c.js';
9
- import 'styled-components';
10
11
  import './index-50101bec.js';
11
- import './index-ec555530.js';
12
12
  import 'react-dom';
13
- import './useTransition-750816e0.js';
13
+ import './useTransition-c2aef0e4.js';
14
14
 
15
15
  const ErrorBoundaryContext = createContext(null);
16
16
 
@@ -34,6 +34,7 @@ export * from './source-modal';
34
34
  export * from './source-selection-form';
35
35
  export * from './source-table';
36
36
  export * from './system-overview';
37
+ export * from './system-settings';
37
38
  export * from './table-cell-conditions';
38
39
  export * from './toast-list';
39
40
  export * from './toggle-dark-mode';
@@ -0,0 +1,8 @@
1
+ import { type FC } from 'react';
2
+ import type { OdigosConfig } from '@/types';
3
+ interface SystemSettingsProps {
4
+ fetchSettings: () => Promise<OdigosConfig | undefined>;
5
+ onSave: (payload: OdigosConfig) => Promise<void>;
6
+ }
7
+ declare const SystemSettings: FC<SystemSettingsProps>;
8
+ export { SystemSettings, type SystemSettingsProps };
@@ -0,0 +1,4 @@
1
+ import { type FC } from 'react';
2
+ import type { SettingsProps } from './types';
3
+ declare const CollectorGatewaySettings: FC<SettingsProps>;
4
+ export { CollectorGatewaySettings };
@@ -0,0 +1,4 @@
1
+ import { type FC } from 'react';
2
+ import type { SettingsProps } from './types';
3
+ declare const CollectorNodeSettings: FC<SettingsProps>;
4
+ export { CollectorNodeSettings };
@@ -0,0 +1,7 @@
1
+ import type { DropdownOption } from '@/components';
2
+ import { AgentEnvVarsInjectionMethod, MountMethod, Profile, ProgrammingLanguages, UiMode } from '@/types';
3
+ export declare const UI_MODE_OPTIONS: DropdownOption<UiMode>[];
4
+ export declare const INSTRUMENTATION_LANG_OPTIONS: DropdownOption<ProgrammingLanguages>[];
5
+ export declare const MOUNT_METHOD_OPTIONS: DropdownOption<MountMethod>[];
6
+ export declare const AGENT_ENV_VARS_INJECTION_METHOD_OPTIONS: DropdownOption<AgentEnvVarsInjectionMethod>[];
7
+ export declare const PROFILE_OPTIONS: DropdownOption<Profile>[];
@@ -0,0 +1,4 @@
1
+ import { type FC } from 'react';
2
+ import type { SettingsProps } from './types';
3
+ declare const OtherSettings: FC<SettingsProps>;
4
+ export { OtherSettings };
@@ -0,0 +1,2 @@
1
+ export declare const Card: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
2
+ export declare const CardTitle: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("@/components").TextProps, never>> & string & Omit<import("react").FC<import("@/components").TextProps>, keyof import("react").Component<any, {}, any>>;
@@ -0,0 +1,5 @@
1
+ import type { OdigosConfig } from '@/types';
2
+ export interface SettingsProps {
3
+ formData: OdigosConfig;
4
+ handleFormChange: (key: keyof OdigosConfig | string, value: any) => void;
5
+ }
@@ -0,0 +1,4 @@
1
+ import { type FC } from 'react';
2
+ import type { SettingsProps } from './types';
3
+ declare const UiSettings: FC<SettingsProps>;
4
+ export { UiSettings };
@@ -0,0 +1,4 @@
1
+ import { type FC } from 'react';
2
+ import type { SettingsProps } from './types';
3
+ declare const UserInstrumentationEnvsSettings: FC<SettingsProps>;
4
+ export { UserInstrumentationEnvsSettings };
package/lib/containers.js CHANGED
@@ -1,17 +1,17 @@
1
1
  import React, { useState, useEffect, forwardRef, useRef, useImperativeHandle, useMemo, Fragment, useCallback, Children } from 'react';
2
2
  import styled, { css } from 'styled-components';
3
3
  import { b as DISPLAY_TITLES, T as Theme, U as usePendingStore, V as useNotificationStore, O as useDrawerStore, B as BUTTON_TEXTS, W as useEntityStore, A as ACTION_OPTIONS, g as getActionIcon, z as useModalStore, F as FORM_ALERTS, X as useFilterStore, D as DISPLAY_LANGUAGES, M as MONITORS_OPTIONS, d as getInstrumentationRuleIcon, Y as useDataStreamStore, Z as useInstrumentStore, c as getEntityId, S as STORAGE_KEYS, a as DEFAULT_DATA_STREAM_NAME, _ as useSetupStore, e as getProgrammingLanguageIcon, I as INSTRUMENTATION_RULE_OPTIONS, $ as useSelectedStore, j as ImageErrorIcon, a0 as useDarkMode } from './index-bd48e6e2.js';
4
- import { ActionType, ActionKeyTypes, InputTypes, FieldTypes, EntityTypes, StatusType, Crud, OtherStatus, NodeTypes, EdgeTypes, AddNodeTypes, SignalType, HeadersCollectionKeyTypes, CustomInstrumentationsKeyTypes, CodeAttributesKeyTypes, PayloadCollectionKeyTypes, InstrumentationRuleType, K8sResourceKind } from './types.js';
5
- import { e as DataCardFieldTypes, p as FieldLabel, C as Checkbox, o as FieldError, v as Input, x as InputTable, K as KeyValueInputsList, w as InputList, _ as Text, R as Segment, Q as SectionTitle, j as DocsButton, z as MonitorsCheckboxes, $ as TextArea, k as Drawer, c as ConditionDetails, D as DataCard, a5 as FlexColumn, M as Modal, N as NavigationButtons, a9 as ModalBody, L as NotificationNote, A as AutocompleteInput, i as Divider, W as Status, a4 as FlexRow, a1 as Tooltip, s as IconWrapped, G as MonitorsIcons, aa as TableContainer, ab as TableTitleWrap, r as IconTitleBadge, ac as TableWrap, y as InteractiveTable, a6 as CenterThis, J as NoDataFound, a2 as TraceLoader, a as Badge, E as ExtendArrow, a7 as VerticalScroll, U as SelectionButton, B as Button, n as Dropdown, ad as nodeConfig, ae as useNodesState, af as useEdgesState, ag as Flow, ah as applyNodeChanges, P as Popup, a0 as Toggle, I as IconButton, ai as AddButton, F as FadeLoader, g as DataTab, X as Stepper, d as DataCardFields, Z as Tag, aj as MarkerType, t as IconsNav, ak as CopyText, h as DescribeRow, al as PodContainer, am as SourceContainer, q as IconGroup, O as PopupForm } from './index-61caa474.js';
6
- import { i as isEmpty, s as safeJsonParse } from './index-ec555530.js';
4
+ import { ActionType, ActionKeyTypes, InputTypes, FieldTypes, EntityTypes, StatusType, Crud, OtherStatus, NodeTypes, EdgeTypes, AddNodeTypes, SignalType, HeadersCollectionKeyTypes, CustomInstrumentationsKeyTypes, CodeAttributesKeyTypes, PayloadCollectionKeyTypes, InstrumentationRuleType, K8sResourceKind, UiMode, ProgrammingLanguages, MountMethod, AgentEnvVarsInjectionMethod, Profile } from './types.js';
5
+ import { e as DataCardFieldTypes, p as FieldLabel, C as Checkbox, o as FieldError, v as Input, x as InputTable, K as KeyValueInputsList, w as InputList, _ as Text, R as Segment, Q as SectionTitle, j as DocsButton, z as MonitorsCheckboxes, $ as TextArea, k as Drawer, c as ConditionDetails, D as DataCard, a5 as FlexColumn, M as Modal, N as NavigationButtons, a9 as ModalBody, L as NotificationNote, A as AutocompleteInput, i as Divider, W as Status, a4 as FlexRow, a1 as Tooltip, s as IconWrapped, G as MonitorsIcons, aa as TableContainer, ab as TableTitleWrap, r as IconTitleBadge, ac as TableWrap, y as InteractiveTable, a6 as CenterThis, J as NoDataFound, a2 as TraceLoader, a as Badge, E as ExtendArrow, a7 as VerticalScroll, U as SelectionButton, B as Button, n as Dropdown, ad as nodeConfig, ae as useNodesState, af as useEdgesState, ag as Flow, ah as applyNodeChanges, P as Popup, a0 as Toggle, I as IconButton, ai as AddButton, F as FadeLoader, g as DataTab, X as Stepper, d as DataCardFields, Z as Tag, aj as MarkerType, t as IconsNav, ak as CopyText, h as DescribeRow, al as PodContainer, am as SourceContainer, q as IconGroup, O as PopupForm } from './index-f2da9ad4.js';
6
+ import { i as isEmpty, s as safeJsonParse, d as deepClone } from './index-5e5f7bda.js';
7
7
  import { C as CheckCircledIcon, O as OdigosLogo } from './index-50101bec.js';
8
- import { C as CrossCircledIcon, O as OdigosLogoText, a as OverviewIcon, F as FilterIcon, D as DataStreamsIcon, R as RefreshLeftArrowIcon, N as NotificationIcon, U as UserIcon, S as SlackLogo, K as KeyIcon, T as TerminalIcon } from './index-56ab40b8.js';
8
+ import { C as CrossCircledIcon, O as OdigosLogoText, a as OverviewIcon, F as FilterIcon, D as DataStreamsIcon, A as ArrowIcon, R as RefreshLeftArrowIcon, N as NotificationIcon, U as UserIcon, S as SlackLogo, K as KeyIcon, T as TerminalIcon, G as GearIcon } from './index-c1df4281.js';
9
9
  import { useActionFormData, useSessionStorage, useDataStreamFormData, useDestinationFormData, useClickNotification, useSourceFormData, useSourceSelectionFormData } from './hooks.js';
10
- import { u as useKeyDown, a as useOnClickOutside, b as useContainerSize, c as useClickNode, d as usePopup, e as useInstrumentationRuleFormData, f as useTransition, g as useTimeAgo, h as useCopy, i as useGenericForm } from './useTransition-750816e0.js';
11
- import { E as EditIcon, T as TrashIcon, S as SearchIcon, h as CheckIcon, A as ArrowIcon, P as PlusIcon, a as CopyIcon } from './index-1fcb0269.js';
12
- import { D as DeleteWarning, C as CancelWarning } from './index-eb03f43f.js';
10
+ import { u as useKeyDown, a as useOnClickOutside, b as useContainerSize, c as useClickNode, d as usePopup, e as useInstrumentationRuleFormData, f as useTransition, g as useTimeAgo, h as useCopy, i as useGenericForm } from './useTransition-c2aef0e4.js';
11
+ import { E as EditIcon, T as TrashIcon, S as SearchIcon, h as CheckIcon, P as PlusIcon, a as CopyIcon } from './index-391844c6.js';
12
+ import { D as DeleteWarning, C as CancelWarning } from './index-7074fb24.js';
13
13
  import { g as getConditionsBooleans, m as mapConditions, b as getStatusIcon, h as splitCamelString, c as capitalizeFirstLetter, i as isStringABoolean, p as parseBooleanFromString } from './index-58440c5c.js';
14
- import { f as filterActions, m as getEntityLabel, l as getEntityIcon, w as sleep, 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, v as mapDestinationFieldsForDisplay, c as compareCondition, s as getYamlFieldsForDestination, d as deepClone, n as getMetricForEntity, r as getWorkloadId, t as hasUnhealthyInstances, i as getContainersInstrumentedCount, u as isOverTime } from './index-9e56485b.js';
14
+ import { f as filterActions, l as getEntityLabel, k as getEntityIcon, v as sleep, n as getPlatformIcon, o as getPlatformLabel, g as formatBytes, i as getContainersIcons, p as getValueForRange, j as getDestinationIcon, e as filterSourcesByStream, d as filterSources, b as filterDestinationsByStream, a as filterDestinations, u as mapDestinationFieldsForDisplay, c as compareCondition, r as getYamlFieldsForDestination, m as getMetricForEntity, q as getWorkloadId, s as hasUnhealthyInstances, h as getContainersInstrumentedCount, t as isOverTime } from './index-42f40e7c.js';
15
15
  import { m as mapExportedSignals } from './index-6a6bea6e.js';
16
16
  import { NoteBackToSummary, EditButton } from './snippets.js';
17
17
  import { D as DESTINATION_CATEGORIES } from './index-1cb4f9e2.js';
@@ -677,7 +677,7 @@ const FormContainer$4 = styled.div `
677
677
  overflow: overlay;
678
678
  overflow-y: auto;
679
679
  `;
680
- const DataContainer$3 = styled.div `
680
+ const DataContainer$4 = styled.div `
681
681
  display: flex;
682
682
  flex-direction: column;
683
683
  gap: 12px;
@@ -732,7 +732,7 @@ const ActionDrawer = ({ updateAction, deleteAction }) => {
732
732
  React.createElement(ActionForm, { isUpdate: true, action: thisOptionType, formData: formData, formErrors: formErrors, handleFormChange: (...params) => {
733
733
  setIsFormDirty(true);
734
734
  handleFormChange(...params);
735
- } }))) : (React.createElement(DataContainer$3, null,
735
+ } }))) : (React.createElement(DataContainer$4, null,
736
736
  React.createElement(ConditionDetails, { conditions: thisItem.conditions || [] }),
737
737
  React.createElement(DataCard, { title: DISPLAY_TITLES.ACTION_DETAILS, data: !!thisItem ? buildCard$3(thisItem) : [] })))));
738
738
  };
@@ -2508,7 +2508,7 @@ const FormContainer$2 = styled.div `
2508
2508
  overflow: overlay;
2509
2509
  overflow-y: auto;
2510
2510
  `;
2511
- const DataContainer$2 = styled.div `
2511
+ const DataContainer$3 = styled.div `
2512
2512
  display: flex;
2513
2513
  flex-direction: column;
2514
2514
  gap: 12px;
@@ -2573,7 +2573,7 @@ const DestinationDrawer = ({ categories, updateDestination, deleteDestination, t
2573
2573
  }, dynamicFields: dynamicFields, setDynamicFields: (...params) => {
2574
2574
  setIsFormDirty(true);
2575
2575
  setDynamicFields(...params);
2576
- }, validateForm: validateForm, testConnection: testConnection }))) : (React.createElement(DataContainer$2, null,
2576
+ }, validateForm: validateForm, testConnection: testConnection }))) : (React.createElement(DataContainer$3, null,
2577
2577
  thisItem.conditions?.length ? React.createElement(ConditionDetails, { conditions: thisItem.conditions }) : null,
2578
2578
  React.createElement(DataCard, { title: DISPLAY_TITLES.DESTINATION_DETAILS, data: !!thisItem ? buildCard$2(thisItem, yamlFields) : [] })))));
2579
2579
  };
@@ -4286,7 +4286,7 @@ const FormContainer = styled.div `
4286
4286
  overflow: overlay;
4287
4287
  overflow-y: auto;
4288
4288
  `;
4289
- const DataContainer$1 = styled.div `
4289
+ const DataContainer$2 = styled.div `
4290
4290
  display: flex;
4291
4291
  flex-direction: column;
4292
4292
  gap: 12px;
@@ -4375,7 +4375,7 @@ const SourceDrawer = ({ persistSources, updateSource, fetchDescribeSource, resta
4375
4375
  setIsFormDirty(true);
4376
4376
  handleFormChange(...params);
4377
4377
  handleFormChange('currentStreamName', selectedStreamName);
4378
- } }))) : (React.createElement(DataContainer$1, null,
4378
+ } }))) : (React.createElement(DataContainer$2, null,
4379
4379
  React.createElement(ConditionDetails, { conditions: thisItem.conditions || [] }),
4380
4380
  React.createElement(DataCard, { title: DISPLAY_TITLES.SOURCE_DETAILS, data: !!thisItem ? buildCard(thisItem) : [] }),
4381
4381
  React.createElement(DataCard, { title: DISPLAY_TITLES.DETECTED_CONTAINERS, titleBadge: containersData.isLoading ? OtherStatus.Loading : containersData.containers.length, description: containersData.description || DISPLAY_TITLES.DETECTED_CONTAINERS_DESCRIPTION }, containersData.containers.map((container) => (React.createElement(SourceContainer, { key: `source-container-${container.containerName}`, ...container, callbackRuntimeOverride: async (payload) => await updateSource(drawerEntityId, payload) }))))))) : (React.createElement(Describe$1, { source: thisItem, fetchDescribeSource: fetchDescribeSource }))));
@@ -4699,30 +4699,285 @@ const Describe = ({ fetchDescribeOdigos }) => {
4699
4699
  React.createElement(DataCard, { title: 'Node Collector', withExtend: true }, Object.values(describe?.nodeCollector || {}).map(mapObjectToCardChildren))));
4700
4700
  };
4701
4701
 
4702
- const DataContainer = styled.div `
4702
+ const DataContainer$1 = styled.div `
4703
4703
  display: flex;
4704
4704
  flex-direction: column;
4705
4705
  gap: 12px;
4706
4706
  `;
4707
- const DRAWER_WIDTH = '750px';
4708
- const TITLE_TEXT = 'System Overview';
4707
+ const DRAWER_WIDTH$1 = '750px';
4708
+ const TITLE_TEXT$1 = 'System Overview';
4709
4709
  const SystemOverview = ({ tokens, saveToken, fetchDescribeOdigos }) => {
4710
4710
  const [isOpen, setIsOpen] = useState(false);
4711
4711
  const toggleOpen = () => setIsOpen((prev) => !prev);
4712
4712
  return (React.createElement(React.Fragment, null,
4713
- React.createElement(IconButton, { key: 'cli', onClick: toggleOpen, tooltip: TITLE_TEXT },
4713
+ React.createElement(IconButton, { key: TITLE_TEXT$1, onClick: toggleOpen, tooltip: TITLE_TEXT$1 },
4714
4714
  React.createElement(TerminalIcon, { size: 18 })),
4715
- React.createElement(Drawer, { width: DRAWER_WIDTH, isOpen: isOpen, onClose: toggleOpen, header: {
4715
+ React.createElement(Drawer, { width: DRAWER_WIDTH$1, isOpen: isOpen, onClose: toggleOpen, header: {
4716
4716
  icons: [TerminalIcon],
4717
- title: TITLE_TEXT,
4717
+ title: TITLE_TEXT$1,
4718
4718
  }, footer: {
4719
4719
  isOpen: false,
4720
4720
  } },
4721
- React.createElement(DataContainer, null,
4721
+ React.createElement(DataContainer$1, null,
4722
4722
  !!tokens?.length && React.createElement(Tokens, { tokens: tokens, saveToken: saveToken }),
4723
4723
  React.createElement(Describe, { fetchDescribeOdigos: fetchDescribeOdigos })))));
4724
4724
  };
4725
4725
 
4726
+ const Card = styled.div `
4727
+ align-self: stretch;
4728
+ display: flex;
4729
+ flex-direction: column;
4730
+ align-items: flex-start;
4731
+ gap: 16px;
4732
+ padding: 16px;
4733
+ border-radius: 24px;
4734
+ background: ${({ theme }) => theme.colors.secondary + Theme.opacity.hex['004']};
4735
+ `;
4736
+ const CardTitle = styled(Text) `
4737
+ color: ${({ theme }) => theme.text.secondary};
4738
+ font-size: 18px;
4739
+ font-weight: 600;
4740
+ line-height: 20px;
4741
+ `;
4742
+
4743
+ const UI_MODE_OPTIONS = [
4744
+ { id: UiMode.Default, value: 'Default' },
4745
+ { id: UiMode.ReadOnly, value: 'Read Only' },
4746
+ ];
4747
+ const INSTRUMENTATION_LANG_OPTIONS = [
4748
+ {
4749
+ id: ProgrammingLanguages.Go,
4750
+ value: DISPLAY_LANGUAGES[ProgrammingLanguages.Go],
4751
+ icon: getProgrammingLanguageIcon(ProgrammingLanguages.Go),
4752
+ },
4753
+ {
4754
+ id: ProgrammingLanguages.JavaScript,
4755
+ value: DISPLAY_LANGUAGES[ProgrammingLanguages.JavaScript],
4756
+ icon: getProgrammingLanguageIcon(ProgrammingLanguages.JavaScript),
4757
+ },
4758
+ {
4759
+ id: ProgrammingLanguages.Python,
4760
+ value: DISPLAY_LANGUAGES[ProgrammingLanguages.Python],
4761
+ icon: getProgrammingLanguageIcon(ProgrammingLanguages.Python),
4762
+ },
4763
+ {
4764
+ id: ProgrammingLanguages.Java,
4765
+ value: DISPLAY_LANGUAGES[ProgrammingLanguages.Java],
4766
+ icon: getProgrammingLanguageIcon(ProgrammingLanguages.Java),
4767
+ },
4768
+ {
4769
+ id: ProgrammingLanguages.Php,
4770
+ value: DISPLAY_LANGUAGES[ProgrammingLanguages.Php],
4771
+ icon: getProgrammingLanguageIcon(ProgrammingLanguages.Php),
4772
+ },
4773
+ {
4774
+ id: ProgrammingLanguages.Ruby,
4775
+ value: DISPLAY_LANGUAGES[ProgrammingLanguages.Ruby],
4776
+ icon: getProgrammingLanguageIcon(ProgrammingLanguages.Ruby),
4777
+ },
4778
+ {
4779
+ id: ProgrammingLanguages.DotNet,
4780
+ value: DISPLAY_LANGUAGES[ProgrammingLanguages.DotNet],
4781
+ icon: getProgrammingLanguageIcon(ProgrammingLanguages.DotNet),
4782
+ },
4783
+ ];
4784
+ const MOUNT_METHOD_OPTIONS = [
4785
+ { id: MountMethod.VirtualDevice, value: 'Virtual Device' },
4786
+ { id: MountMethod.HostPath, value: 'Host Path' },
4787
+ // { id: MountMethod.InitContainer, value: 'Init Container' },
4788
+ ];
4789
+ const AGENT_ENV_VARS_INJECTION_METHOD_OPTIONS = [
4790
+ { id: AgentEnvVarsInjectionMethod.Loader, value: 'Loader' },
4791
+ { id: AgentEnvVarsInjectionMethod.PodManifest, value: 'Pod Manifest' },
4792
+ { id: AgentEnvVarsInjectionMethod.LoaderFallbackToPodManifest, value: 'Loader Fallback to Pod Manifest' },
4793
+ ];
4794
+ const PROFILE_OPTIONS = [
4795
+ // { id: Profile.CategoryAttributes, value: 'Category Attributes' },
4796
+ { id: Profile.CodeAttributes, value: 'Code Attributes' },
4797
+ // { id: Profile.CopyScope, value: 'Copy Scope' },
4798
+ // { id: Profile.HostnameAsPodname, value: 'Hostname as Podname' },
4799
+ { id: Profile.FullPayloadCollection, value: 'Full Payload Collection' },
4800
+ { id: Profile.DbPayloadCollection, value: 'DB Payload Collection' },
4801
+ { id: Profile.QueryOperationDetector, value: 'Query Operation Detector' },
4802
+ // { id: Profile.Semconv, value: 'Semconv' },
4803
+ // { id: Profile.ReduceSpanNameCardinality, value: 'Reduce Span Name Cardinality' },
4804
+ { id: Profile.AllowConcurrentAgents, value: 'Allow Concurrent Agents' },
4805
+ { id: Profile.JavaEbpfInstrumentations, value: 'Java EBPF Instrumentations' },
4806
+ { id: Profile.JavaNativeInstrumentations, value: 'Java Native Instrumentations' },
4807
+ // { id: Profile.LegacyDotnetInstrumentation, value: 'Legacy .NET Instrumentation' },
4808
+ // { id: Profile.MountMethodK8sHostPath, value: 'Mount Method K8s Host Path' },
4809
+ // { id: Profile.MountMethodK8sVirtualDevice, value: 'Mount Method K8s Virtual Device' },
4810
+ // { id: Profile.PodManifestEnvVarInjection, value: 'Pod Manifest Env Var Injection' },
4811
+ // { id: Profile.DisableGin, value: 'Disable Gin' },
4812
+ // { id: Profile.SmallBatches, value: 'Small Batches' },
4813
+ { id: Profile.SizeS, value: 'Size S' },
4814
+ { id: Profile.SizeM, value: 'Size M' },
4815
+ { id: Profile.SizeL, value: 'Size L' },
4816
+ ];
4817
+
4818
+ const UiSettings = ({ formData, handleFormChange }) => {
4819
+ return (React.createElement(Card, null,
4820
+ React.createElement(CardTitle, null, "UI"),
4821
+ React.createElement(Dropdown, { title: 'UI Mode', tooltip: 'Mode of the UI - default or readonly', options: UI_MODE_OPTIONS, value: UI_MODE_OPTIONS.find((option) => option.id === formData.uiMode), onSelect: (option) => handleFormChange('uiMode', option.id) }),
4822
+ React.createElement(Input, { title: 'UI Pagination Limit', tooltip: 'Pagination limit for UI paginated fetching', type: 'number', value: formData.uiPaginationLimit.toString(), onChange: (e) => handleFormChange('uiPaginationLimit', Number(e.target.value)) }),
4823
+ React.createElement(Input, { title: 'Central Backend URL', tooltip: 'URL of the central backend', value: formData.centralBackendURL, onChange: (e) => handleFormChange('centralBackendURL', e.target.value) }),
4824
+ React.createElement(Input, { title: 'OIDC Tenant URL', tooltip: 'URL of the OIDC tenant', value: formData.oidc?.tenantUrl, onChange: (e) => handleFormChange('oidc.tenantUrl', e.target.value) }),
4825
+ React.createElement(Input, { title: 'OIDC Client ID', tooltip: 'Client ID of the OIDC application', value: formData.oidc?.clientId, onChange: (e) => handleFormChange('oidc.clientId', e.target.value) }),
4826
+ React.createElement(Input, { title: 'OIDC Client Secret', tooltip: 'Client Secret of the OIDC application', type: 'password', value: formData.oidc?.clientSecret, onChange: (e) => handleFormChange('oidc.clientSecret', e.target.value) })));
4827
+ };
4828
+
4829
+ const OtherSettings = ({ formData, handleFormChange }) => {
4830
+ return (React.createElement(Card, null,
4831
+ React.createElement(CardTitle, null, "Other"),
4832
+ React.createElement(Toggle, { title: 'Telemetry Enabled', tooltip: 'Enable anonymous telemetry collection', initialValue: formData.telemetryEnabled, onChange: (bool) => handleFormChange('telemetryEnabled', bool) }),
4833
+ React.createElement(Toggle, { title: 'OpenShift Enabled', tooltip: 'Enable OpenShift-specific features', initialValue: formData.openshiftEnabled, onChange: (bool) => handleFormChange('openshiftEnabled', bool) }),
4834
+ React.createElement(Toggle, { title: 'Karpenter Enabled', tooltip: 'Enable Karpenter support', initialValue: formData.karpenterEnabled, onChange: (bool) => handleFormChange('karpenterEnabled', bool) }),
4835
+ React.createElement(Toggle, { title: 'PSP Enabled', tooltip: 'Enable Pod Security Policy support', initialValue: formData.psp, onChange: (bool) => handleFormChange('psp', bool) }),
4836
+ React.createElement(Toggle, { title: 'Allow Concurrent Agents', tooltip: 'Allow concurrent running agents', initialValue: formData.allowConcurrentAgents, onChange: (bool) => handleFormChange('allowConcurrentAgents', bool) }),
4837
+ React.createElement(Toggle, { title: 'Skip Webhook Issuer Creation', tooltip: 'Skip creation of the webhook issuer', initialValue: formData.skipWebhookIssuerCreation, onChange: (bool) => handleFormChange('skipWebhookIssuerCreation', bool) }),
4838
+ React.createElement(Toggle, { title: 'Automatic Rollout Disabled', tooltip: 'Disable automatic rollout of pods after instrumentation', initialValue: formData.rollout?.automaticRolloutDisabled, onChange: (bool) => handleFormChange('rollout.automaticRolloutDisabled', bool) }),
4839
+ React.createElement(Input, { title: 'Cluster Name', tooltip: 'Name of the cluster', value: formData.clusterName, onChange: (e) => handleFormChange('clusterName', e.target.value) }),
4840
+ React.createElement(Input, { title: 'Image Prefix', tooltip: 'Image prefix for all Odigos components', value: formData.imagePrefix, onChange: (e) => handleFormChange('imagePrefix', e.target.value) }),
4841
+ React.createElement(InputList, { title: 'Ignored Namespaces', tooltip: 'List of namespaces to exclude from instrumentation', value: formData.ignoredNamespaces, onChange: (arr) => handleFormChange('ignoredNamespaces', arr) }),
4842
+ React.createElement(InputList, { title: 'Ignored Containers', tooltip: 'List of container names to exclude from instrumentation', value: formData.ignoredContainers, onChange: (arr) => handleFormChange('ignoredContainers', arr) }),
4843
+ React.createElement(Dropdown, { title: 'Profiles', tooltip: 'Profiles to enable', isMulti: true, options: PROFILE_OPTIONS, value: PROFILE_OPTIONS.filter((option) => formData.profiles.includes(option.id)), onSelect: (option) => handleFormChange('profiles', [...formData.profiles, option.id]), onDeselect: (option) => handleFormChange('profiles', formData.profiles.filter((p) => p !== option.id)) }),
4844
+ React.createElement(Dropdown, { title: 'Mount Method', tooltip: 'Method used to mount volume', options: MOUNT_METHOD_OPTIONS, value: MOUNT_METHOD_OPTIONS.find((option) => option.id === formData.mountMethod), onSelect: (option) => handleFormChange('mountMethod', option.id) }),
4845
+ React.createElement(Dropdown, { title: 'Agent Env Vars Injection Method', tooltip: 'How to inject env vars into agents', options: AGENT_ENV_VARS_INJECTION_METHOD_OPTIONS, value: AGENT_ENV_VARS_INJECTION_METHOD_OPTIONS.find((option) => option.id === formData.agentEnvVarsInjectionMethod), onSelect: (option) => handleFormChange('agentEnvVarsInjectionMethod', option.id) }),
4846
+ React.createElement(Input, { title: 'Custom Container Runtime Socket Path', tooltip: 'Path to the custom container runtime socket', value: formData.customContainerRuntimeSocketPath, onChange: (e) => handleFormChange('customContainerRuntimeSocketPath', e.target.value) }),
4847
+ React.createElement(Input, { title: 'Odiglet Health Probe Bind Port', tooltip: 'Port to bind the health probe', value: formData.odigletHealthProbeBindPort.toString(), onChange: (e) => handleFormChange('odigletHealthProbeBindPort', Number(e.target.value)) }),
4848
+ React.createElement(Toggle, { title: 'Rollback Disabled', tooltip: 'Disable rollback', initialValue: formData.rollbackDisabled, onChange: (bool) => handleFormChange('rollbackDisabled', bool) }),
4849
+ React.createElement(Input, { title: 'Rollback Grace Time', tooltip: 'Grace time for rollback', value: formData.rollbackGraceTime, onChange: (e) => handleFormChange('rollbackGraceTime', e.target.value) }),
4850
+ React.createElement(Input, { title: 'Rollback Stability Window', tooltip: 'Stability window for rollback', value: formData.rollbackStabilityWindow, onChange: (e) => handleFormChange('rollbackStabilityWindow', e.target.value) }),
4851
+ React.createElement(KeyValueInputsList, { title: 'Node Selector', value: Object.entries(formData.nodeSelector || {}).map(([key, value]) => ({
4852
+ key,
4853
+ value,
4854
+ })), onChange: (arr) => handleFormChange('nodeSelector', arr.reduce((acc, { key, value }) => ({
4855
+ ...acc,
4856
+ [key]: value,
4857
+ }), {})) })));
4858
+ };
4859
+
4860
+ const CollectorNodeSettings = ({ formData, handleFormChange }) => {
4861
+ return (React.createElement(Card, null,
4862
+ React.createElement(CardTitle, null, "Collector Node"),
4863
+ React.createElement(Input, { title: 'Collector Own Metrics Port', tooltip: "Port for the collector's own Prometheus metrics", type: 'number', value: formData.collectorNode?.collectorOwnMetricsPort?.toString() || '', onChange: (e) => handleFormChange('collectorNode.collectorOwnMetricsPort', Number(e.target.value)) }),
4864
+ React.createElement(Input, { title: 'Request Memory (MB)', tooltip: 'Request memory for the collector node in Megabytes', type: 'number', value: formData.collectorNode?.requestMemoryMiB?.toString() || '', onChange: (e) => handleFormChange('collectorNode.requestMemoryMiB', Number(e.target.value)) }),
4865
+ React.createElement(Input, { title: 'Limit Memory (MB)', tooltip: 'Limit memory for the collector node in Megabytes', type: 'number', value: formData.collectorNode?.limitMemoryMiB?.toString() || '', onChange: (e) => handleFormChange('collectorNode.limitMemoryMiB', Number(e.target.value)) }),
4866
+ React.createElement(Input, { title: 'Request CPU (Millicores)', tooltip: 'Request CPU for the collector node in Millicores', type: 'number', value: formData.collectorNode?.requestCPUm?.toString() || '', onChange: (e) => handleFormChange('collectorNode.requestCPUm', Number(e.target.value)) }),
4867
+ React.createElement(Input, { title: 'Limit CPU (Millicores)', tooltip: 'Limit CPU for the collector node in Millicores', type: 'number', value: formData.collectorNode?.limitCPUm?.toString() || '', onChange: (e) => handleFormChange('collectorNode.limitCPUm', Number(e.target.value)) }),
4868
+ React.createElement(Input, { title: 'Memory Limiter Limit (MB)', tooltip: 'Memory limiter limit for the collector node in Megabytes', type: 'number', value: formData.collectorNode?.memoryLimiterLimitMiB?.toString() || '', onChange: (e) => handleFormChange('collectorNode.memoryLimiterLimitMiB', Number(e.target.value)) }),
4869
+ React.createElement(Input, { title: 'Memory Limiter Spike Limit (MB)', tooltip: 'Memory limiter spike limit for the collector node in Megabytes', type: 'number', value: formData.collectorNode?.memoryLimiterSpikeLimitMiB?.toString() || '', onChange: (e) => handleFormChange('collectorNode.memoryLimiterSpikeLimitMiB', Number(e.target.value)) }),
4870
+ React.createElement(Input, { title: 'Go Memory Limit (MB)', tooltip: 'Go memory limit for the collector node in Megabytes', type: 'number', value: formData.collectorNode?.goMemLimitMiB?.toString() || '', onChange: (e) => handleFormChange('collectorNode.goMemLimitMiB', Number(e.target.value)) }),
4871
+ React.createElement(Input, { title: 'K8s Node Logs Directory', tooltip: 'Target directory for K8s logs if `/var/log` is a symlink', value: formData.collectorNode?.k8sNodeLogsDirectory || '', onChange: (e) => handleFormChange('collectorNode.k8sNodeLogsDirectory', e.target.value) })));
4872
+ };
4873
+
4874
+ const CollectorGatewaySettings = ({ formData, handleFormChange }) => {
4875
+ return (React.createElement(Card, null,
4876
+ React.createElement(CardTitle, null, "Collector Gateway"),
4877
+ React.createElement(Input, { title: 'Min. Replicas', tooltip: 'Minimum number of replicas for the collector gateway', type: 'number', value: formData.collectorGateway?.minReplicas?.toString() || '', onChange: (e) => handleFormChange('collectorGateway.minReplicas', Number(e.target.value)) }),
4878
+ React.createElement(Input, { title: 'Max. Replicas', tooltip: 'Maximum number of replicas for the collector gateway', type: 'number', value: formData.collectorGateway?.maxReplicas?.toString() || '', onChange: (e) => handleFormChange('collectorGateway.maxReplicas', Number(e.target.value)) }),
4879
+ React.createElement(Input, { title: 'Request Memory (MB)', tooltip: 'Request memory for the collector gateway in Megabytes', type: 'number', value: formData.collectorGateway?.requestMemoryMiB?.toString() || '', onChange: (e) => handleFormChange('collectorGateway.requestMemoryMiB', Number(e.target.value)) }),
4880
+ React.createElement(Input, { title: 'Limit Memory (MB)', tooltip: 'Limit memory for the collector gateway in Megabytes', type: 'number', value: formData.collectorGateway?.limitMemoryMiB?.toString() || '', onChange: (e) => handleFormChange('collectorGateway.limitMemoryMiB', Number(e.target.value)) }),
4881
+ React.createElement(Input, { title: 'Request CPU (Millicores)', tooltip: 'Request CPU for the collector gateway in Millicores', type: 'number', value: formData.collectorGateway?.requestCPUm?.toString() || '', onChange: (e) => handleFormChange('collectorGateway.requestCPUm', Number(e.target.value)) }),
4882
+ React.createElement(Input, { title: 'Limit CPU (Millicores)', tooltip: 'Limit CPU for the collector gateway in Millicores', type: 'number', value: formData.collectorGateway?.limitCPUm?.toString() || '', onChange: (e) => handleFormChange('collectorGateway.limitCPUm', Number(e.target.value)) }),
4883
+ React.createElement(Input, { title: 'Memory Limiter Limit (MB)', tooltip: 'Memory limiter limit for the collector gateway in Megabytes', type: 'number', value: formData.collectorGateway?.memoryLimiterLimitMiB?.toString() || '', onChange: (e) => handleFormChange('collectorGateway.memoryLimiterLimitMiB', Number(e.target.value)) }),
4884
+ React.createElement(Input, { title: 'Memory Limiter Spike Limit (MB)', tooltip: 'Memory limiter spike limit for the collector gateway in Megabytes', type: 'number', value: formData.collectorGateway?.memoryLimiterSpikeLimitMiB?.toString() || '', onChange: (e) => handleFormChange('collectorGateway.memoryLimiterSpikeLimitMiB', Number(e.target.value)) }),
4885
+ React.createElement(Input, { title: 'Go Memory Limit (MB)', tooltip: 'Go memory limit for the collector gateway in Megabytes', type: 'number', value: formData.collectorGateway?.goMemLimitMiB?.toString() || '', onChange: (e) => handleFormChange('collectorGateway.goMemLimitMiB', Number(e.target.value)) })));
4886
+ };
4887
+
4888
+ const UserInstrumentationEnvsSettings = ({ formData, handleFormChange }) => {
4889
+ return (React.createElement(Card, null,
4890
+ React.createElement(CardTitle, null, "User Instrumentation Environment Variables"),
4891
+ INSTRUMENTATION_LANG_OPTIONS.map(({ id, value, icon }) => (React.createElement(Card, { key: `${id}-card` },
4892
+ React.createElement(FlexRow, { "$gap": 8, "$alignItems": 'flex-start' },
4893
+ React.createElement(FlexRow, { "$gap": 8 },
4894
+ React.createElement(FlexRow, { "$gap": 8, style: { minWidth: '100px' } },
4895
+ React.createElement(IconWrapped, { icon: icon }),
4896
+ React.createElement(Text, { size: 14 }, value)),
4897
+ React.createElement(Tooltip, { text: 'enable/disable user instrumentation for this language' },
4898
+ React.createElement(Toggle, { initialValue: formData.userInstrumentationEnvs?.languages[id]?.enabled, onChange: (bool) => handleFormChange(`userInstrumentationEnvs.languages.${id}.enabled`, bool) }))),
4899
+ React.createElement(KeyValueInputsList, { inputMaxWidth: 220, disabled: !formData.userInstrumentationEnvs?.languages[id]?.enabled, value: Object.entries(formData.userInstrumentationEnvs?.languages[id]?.env || {}).map(([k, v]) => ({
4900
+ key: k,
4901
+ value: v,
4902
+ })), onChange: (rows) => {
4903
+ handleFormChange(`userInstrumentationEnvs.languages.${id}.env`, rows.reduce((acc, { key, value }) => ({
4904
+ ...acc,
4905
+ [key]: value,
4906
+ }), {}));
4907
+ } })))))));
4908
+ };
4909
+
4910
+ const DataContainer = styled.div `
4911
+ display: flex;
4912
+ flex-direction: column;
4913
+ gap: 12px;
4914
+ `;
4915
+ const DRAWER_WIDTH = '750px';
4916
+ const TITLE_TEXT = 'System Settings';
4917
+ const SystemSettings = ({ fetchSettings, onSave }) => {
4918
+ const [settings, setSettings] = useState(undefined);
4919
+ const { formData, handleFormChange, resetFormData, isFormDirty } = useGenericForm(settings);
4920
+ useEffect(() => {
4921
+ fetchSettings().then(setSettings);
4922
+ // eslint-disable-next-line react-hooks/exhaustive-deps
4923
+ }, []);
4924
+ const [isSaving, setIsSaving] = useState(false);
4925
+ const [isOpen, setIsOpen] = useState(false);
4926
+ const toggleOpen = () => setIsOpen((prev) => !prev);
4927
+ const [cancelWarningOpen, setCancelWarningOpen] = useState(false);
4928
+ const [cancelApproveCallback, setCancelApproveCallback] = useState(null);
4929
+ const handleWithCancelWarning = (callback) => {
4930
+ if (isFormDirty) {
4931
+ setCancelWarningOpen(true);
4932
+ setCancelApproveCallback(() => callback);
4933
+ }
4934
+ else {
4935
+ callback();
4936
+ }
4937
+ };
4938
+ return (React.createElement(React.Fragment, null,
4939
+ React.createElement(IconButton, { key: TITLE_TEXT, onClick: toggleOpen, tooltip: TITLE_TEXT },
4940
+ React.createElement(GearIcon, { size: 18 })),
4941
+ React.createElement(Drawer, { width: DRAWER_WIDTH, isOpen: isOpen, onClose: () => handleWithCancelWarning(toggleOpen), header: {
4942
+ icons: [GearIcon],
4943
+ title: TITLE_TEXT,
4944
+ }, footer: {
4945
+ isOpen: isFormDirty,
4946
+ centerButtons: [
4947
+ {
4948
+ 'data-id': 'drawer-cancel',
4949
+ variant: 'secondary',
4950
+ onClick: () => handleWithCancelWarning(resetFormData),
4951
+ children: BUTTON_TEXTS.CANCEL,
4952
+ },
4953
+ {
4954
+ 'data-id': 'drawer-save',
4955
+ variant: 'primary',
4956
+ onClick: async () => {
4957
+ setIsSaving(true);
4958
+ await onSave(formData);
4959
+ setSettings(await fetchSettings());
4960
+ setIsSaving(false);
4961
+ toggleOpen();
4962
+ },
4963
+ children: BUTTON_TEXTS.SAVE,
4964
+ },
4965
+ ],
4966
+ } }, formData?.imagePrefix !== undefined && !isSaving ? (React.createElement(DataContainer, null,
4967
+ React.createElement(UserInstrumentationEnvsSettings, { formData: formData, handleFormChange: handleFormChange }),
4968
+ React.createElement(UiSettings, { formData: formData, handleFormChange: handleFormChange }),
4969
+ React.createElement(CollectorNodeSettings, { formData: formData, handleFormChange: handleFormChange }),
4970
+ React.createElement(CollectorGatewaySettings, { formData: formData, handleFormChange: handleFormChange }),
4971
+ React.createElement(OtherSettings, { formData: formData, handleFormChange: handleFormChange }))) : (React.createElement(CenterThis, null,
4972
+ React.createElement(FadeLoader, { scale: 1.2 })))),
4973
+ React.createElement(CancelWarning, { isOpen: cancelWarningOpen, name: TITLE_TEXT, onApprove: () => {
4974
+ cancelApproveCallback?.();
4975
+ setCancelWarningOpen(false);
4976
+ }, onDeny: () => {
4977
+ setCancelWarningOpen(false);
4978
+ } })));
4979
+ };
4980
+
4726
4981
  const Container$1 = styled.div `
4727
4982
  position: fixed;
4728
4983
  bottom: 12px;
@@ -4800,4 +5055,4 @@ const ToggleDarkMode = () => {
4800
5055
  React.createElement(Background, { "$darkMode": darkMode })));
4801
5056
  };
4802
5057
 
4803
- export { ActionDrawer, ActionForm, ActionModal, ActionTable, AwaitPipeline, ComputePlatformSelect, ComputePlatforms, ComputePlatformsActionsMenu, ConditionDropdown, ConnectionStatusDropdown, ConnectionTypeDropdown, DataFlow, DataFlowActionsMenu, DataStreamDrawer, DataStreamForm, DataStreamSelectionForm, DestinationDrawer, DestinationForm, DestinationModal, DestinationSelectionForm, DestinationTable, ErrorDropdown, InstrumentationRuleDrawer, InstrumentationRuleForm, InstrumentationRuleModal, InstrumentationRuleTable, KindDropdown, LanguageDropdown, MonitorDropdown, MultiSourceControl, NamespaceDropdown, NavIconIds, NotificationManager, OverviewDrawer, ServiceMap, SetupSummary, SideNav, SlackInvite, SourceDrawer, SourceForm, SourceModal, SourceSelectionForm, SourceTable, SystemOverview, TableCellConditions, ToastList, ToggleDarkMode };
5058
+ export { ActionDrawer, ActionForm, ActionModal, ActionTable, AwaitPipeline, ComputePlatformSelect, ComputePlatforms, ComputePlatformsActionsMenu, ConditionDropdown, ConnectionStatusDropdown, ConnectionTypeDropdown, DataFlow, DataFlowActionsMenu, DataStreamDrawer, DataStreamForm, DataStreamSelectionForm, DestinationDrawer, DestinationForm, DestinationModal, DestinationSelectionForm, DestinationTable, ErrorDropdown, InstrumentationRuleDrawer, InstrumentationRuleForm, InstrumentationRuleModal, InstrumentationRuleTable, KindDropdown, LanguageDropdown, MonitorDropdown, MultiSourceControl, NamespaceDropdown, NavIconIds, NotificationManager, OverviewDrawer, ServiceMap, SetupSummary, SideNav, SlackInvite, SourceDrawer, SourceForm, SourceModal, SourceSelectionForm, SourceTable, SystemOverview, SystemSettings, TableCellConditions, ToastList, ToggleDarkMode };
package/lib/functions.js CHANGED
@@ -1,9 +1,9 @@
1
1
  export { c as capitalizeFirstLetter, f as flattenObjectKeys, g as getConditionsBooleans, a as getMonitorIcon, b as getStatusIcon, i as isStringABoolean, d as isValidVersion, m as mapConditions, n as numbersOnly, p as parseBooleanFromString, e as parseJsonStringToPrettyString, r as removeEmptyValuesFromObject, s as safeJsonStringify, h as splitCamelString } from './index-58440c5c.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 hasUnhealthyInstances, u as isOverTime, v as mapDestinationFieldsForDisplay, w as sleep } from './index-9e56485b.js';
2
+ export { c as compareCondition, f as filterActions, a as filterDestinations, b as filterDestinationsByStream, d as filterSources, e as filterSourcesByStream, g as formatBytes, i as getContainersIcons, h as getContainersInstrumentedCount, j as getDestinationIcon, k as getEntityIcon, l as getEntityLabel, m as getMetricForEntity, n as getPlatformIcon, o as getPlatformLabel, p as getValueForRange, q as getWorkloadId, r as getYamlFieldsForDestination, s as hasUnhealthyInstances, t as isOverTime, u as mapDestinationFieldsForDisplay, v as sleep } from './index-42f40e7c.js';
3
+ export { d as deepClone, i as isEmpty, s as safeJsonParse } from './index-5e5f7bda.js';
3
4
  export { g as getActionIcon, c as getEntityId, d as getInstrumentationRuleIcon, e as getProgrammingLanguageIcon } from './index-bd48e6e2.js';
4
5
  export { g as getIdFromSseTarget, i as isLegalK8sLabel, m as mapExportedSignals } from './index-6a6bea6e.js';
5
6
  import { ProgrammingLanguages, EntityTypes } from './types.js';
6
- export { i as isEmpty, s as safeJsonParse } from './index-ec555530.js';
7
7
  import 'react';
8
8
  import 'styled-components';
9
9
  import './index-50101bec.js';
@@ -1,5 +1,5 @@
1
1
  import type { AnyObj } from '@/types';
2
- export declare const useGenericForm: <Form extends AnyObj>(initialFormData: Form) => {
2
+ export declare const useGenericForm: <Form extends AnyObj>(initialFormData: Form | undefined) => {
3
3
  formData: Form;
4
4
  formErrors: Partial<Record<keyof Form, string>>;
5
5
  isFormDirty: boolean;
package/lib/hooks.js CHANGED
@@ -2,9 +2,9 @@ import { ActionKeyTypes, ActionType, StatusType, EntityTypes, FieldTypes } from
2
2
  import { V as useNotificationStore, F as FORM_ALERTS, O as useDrawerStore, W as useEntityStore, Y as useDataStreamStore, _ as useSetupStore } from './index-bd48e6e2.js';
3
3
  import { useState, useEffect, useMemo } from 'react';
4
4
  import 'styled-components';
5
- import { i as isEmpty, s as safeJsonParse } from './index-ec555530.js';
6
- import { i as useGenericForm } from './useTransition-750816e0.js';
7
- export { c as useClickNode, b as useContainerSize, h as useCopy, e as useInstrumentationRuleFormData, u as useKeyDown, a as useOnClickOutside, d as usePopup, g as useTimeAgo, f as useTransition } from './useTransition-750816e0.js';
5
+ import { i as isEmpty, s as safeJsonParse } from './index-5e5f7bda.js';
6
+ import { i as useGenericForm } from './useTransition-c2aef0e4.js';
7
+ export { c as useClickNode, b as useContainerSize, h as useCopy, e as useInstrumentationRuleFormData, u as useKeyDown, a as useOnClickOutside, d as usePopup, g as useTimeAgo, f as useTransition } from './useTransition-c2aef0e4.js';
8
8
  import { g as getIdFromSseTarget, i as isLegalK8sLabel, m as mapExportedSignals } from './index-6a6bea6e.js';
9
9
 
10
10
  const INITIAL$2 = {
@@ -0,0 +1,2 @@
1
+ import type { SVG } from '@/types';
2
+ export declare const GearIcon: SVG;
@@ -9,6 +9,7 @@ export * from './edited-icon';
9
9
  export * from './extend-arrow-icon';
10
10
  export * from './filter-icon';
11
11
  export * from './folder-icon';
12
+ export * from './gear-icon';
12
13
  export * from './image-error-icon';
13
14
  export * from './key-icon';
14
15
  export * from './list-icon';
package/lib/icons.js CHANGED
@@ -1,9 +1,9 @@
1
1
  import { T as Theme } from './index-bd48e6e2.js';
2
2
  export { f as AddClusterInfoIcon, n as CPlusPlusLogo, o as CSharpLogo, C as CodeAttributesIcon, l as CustomInstrumentationIcon, h as DeleteAttributeIcon, p as DotnetLogo, E as ElixirLogo, G as GoLogo, H as HeadersCollectionIcon, j as ImageErrorIcon, J as JavaLogo, K as K8sLogo, k as KafkaLogo, q as MysqlLogo, N as NginxLogo, r as NodejsLogo, m as PayloadCollectionIcon, s as PhpLogo, P as PiiMaskingIcon, t as PostgresLogo, u as PythonLogo, v as RedisLogo, R as RenameAttributeIcon, w as RubyLogo, x as RustLogo, i as SamplerIcon, y as SwiftLogo } from './index-bd48e6e2.js';
3
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-50101bec.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 RefreshLeftArrowIcon, S as SlackLogo, T as TerminalIcon, U as UserIcon } from './index-56ab40b8.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-1fcb0269.js';
4
+ export { A as ArrowIcon, C as CrossCircledIcon, D as DataStreamsIcon, F as FilterIcon, G as GearIcon, K as KeyIcon, N as NotificationIcon, O as OdigosLogoText, a as OverviewIcon, R as RefreshLeftArrowIcon, S as SlackLogo, T as TerminalIcon, U as UserIcon } from './index-c1df4281.js';
6
5
  import React from 'react';
6
+ export { 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-391844c6.js';
7
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-acc7c7dd.js';
8
8
  import './types.js';
9
9
  import 'styled-components';