@devtron-labs/devtron-fe-common-lib 0.5.0-beta-6 → 0.5.0-beta-8

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 (55) hide show
  1. package/dist/Common/Constants.d.ts +1 -0
  2. package/dist/Common/Helper.d.ts +0 -1
  3. package/dist/Common/Toggle/Toggle.d.ts +1 -2
  4. package/dist/Shared/Components/CICDHistory/AppStatusDetailsChart.d.ts +1 -1
  5. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/DeploymentHistoryConfigList.component.d.ts +3 -0
  6. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/DeploymentHistoryDetailedView.d.ts +3 -0
  7. package/dist/Shared/Components/CICDHistory/{DeploymentHistoryConfigDiff → DeploymentHistoryDiff}/DeploymentHistoryDiffView.d.ts +1 -1
  8. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/DeploymentHistoryHeader.d.ts +3 -0
  9. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/DeploymentHistorySidebar.d.ts +3 -0
  10. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/index.d.ts +3 -0
  11. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/types.d.ts +35 -0
  12. package/dist/Shared/Components/CICDHistory/TriggerOutput.d.ts +1 -1
  13. package/dist/Shared/Components/CICDHistory/index.d.ts +1 -1
  14. package/dist/Shared/Components/CICDHistory/types.d.ts +10 -7
  15. package/dist/Shared/Components/Collapse/Collapse.d.ts +1 -6
  16. package/dist/Shared/Components/CollapsibleList/CollapsibleList.component.d.ts +2 -2
  17. package/dist/Shared/Components/CollapsibleList/CollapsibleList.types.d.ts +35 -18
  18. package/dist/Shared/Components/DeploymentConfigDiff/DeploymentConfigDiff.component.d.ts +1 -1
  19. package/dist/Shared/Components/DeploymentConfigDiff/DeploymentConfigDiff.types.d.ts +14 -31
  20. package/dist/Shared/Components/DeploymentConfigDiff/DeploymentConfigDiff.utils.d.ts +2 -3
  21. package/dist/Shared/Components/DeploymentConfigDiff/DeploymentConfigDiffAccordion.d.ts +1 -1
  22. package/dist/Shared/Components/DeploymentConfigDiff/DeploymentConfigDiffMain.d.ts +1 -1
  23. package/dist/Shared/Components/DeploymentConfigDiff/DeploymentConfigDiffNavigation.d.ts +1 -1
  24. package/dist/Shared/Components/DeploymentConfigDiff/index.d.ts +0 -1
  25. package/dist/Shared/Components/SelectPicker/type.d.ts +1 -6
  26. package/dist/Shared/Helpers.d.ts +0 -13
  27. package/dist/Shared/Services/app.service.d.ts +1 -4
  28. package/dist/Shared/Services/app.types.d.ts +7 -31
  29. package/dist/Shared/types.d.ts +1 -0
  30. package/dist/assets/index.css +1 -1
  31. package/dist/{cssMode-Bp5KglQa.js → cssMode-BCTavoMr.js} +1 -1
  32. package/dist/{freemarker2-83m_tw4B.js → freemarker2-Bu5vRfuf.js} +1 -1
  33. package/dist/{handlebars-BEaq8PE9.js → handlebars-CfBxsAkH.js} +1 -1
  34. package/dist/{html-DjsTC88w.js → html-CzPfHxwO.js} +1 -1
  35. package/dist/{htmlMode-Bh_As7NM.js → htmlMode-D6UItUi4.js} +1 -1
  36. package/dist/{index-CGeGletC.js → index-SqV_EjFi.js} +28776 -29020
  37. package/dist/index.js +391 -397
  38. package/dist/{javascript-BujkRhBk.js → javascript-C4dhflIc.js} +1 -1
  39. package/dist/{jsonMode-CuxkqNLy.js → jsonMode-JIxmGWP2.js} +1 -1
  40. package/dist/{liquid-CnlhLSM9.js → liquid-BasD2TkK.js} +1 -1
  41. package/dist/{mdx-DbEMSDX2.js → mdx-YRYvCR5A.js} +1 -1
  42. package/dist/{python-BBDLv7kh.js → python-tpFYDtvk.js} +1 -1
  43. package/dist/{razor-BWMGbwYK.js → razor-bOw1Th0O.js} +1 -1
  44. package/dist/{tsMode-CKi5DKdR.js → tsMode-_HRuSYur.js} +1 -1
  45. package/dist/{typescript-Dg1658sC.js → typescript-CMGrRshP.js} +1 -1
  46. package/dist/{xml-BCOAEvUp.js → xml-CrSvXNNb.js} +1 -1
  47. package/dist/{yaml-C3K-0wE8.js → yaml-Bw2LHXoL.js} +1 -1
  48. package/package.json +1 -2
  49. package/dist/Shared/Components/CICDHistory/DeploymentHistoryConfigDiff/DeploymentHistoryConfigDiff.d.ts +0 -2
  50. package/dist/Shared/Components/CICDHistory/DeploymentHistoryConfigDiff/DeploymentHistoryConfigDiffCompare.d.ts +0 -2
  51. package/dist/Shared/Components/CICDHistory/DeploymentHistoryConfigDiff/helpers.d.ts +0 -6
  52. package/dist/Shared/Components/CICDHistory/DeploymentHistoryConfigDiff/index.d.ts +0 -2
  53. package/dist/Shared/Components/CICDHistory/DeploymentHistoryConfigDiff/types.d.ts +0 -36
  54. package/dist/Shared/Components/CICDHistory/DeploymentHistoryConfigDiff/utils.d.ts +0 -22
  55. package/dist/Shared/Components/DeploymentConfigDiff/DeploymentConfigDiff.constants.d.ts +0 -6
@@ -44,6 +44,7 @@ export declare const URLS: {
44
44
  GLOBAL_CONFIG_SCOPED_VARIABLES: string;
45
45
  GLOBAL_CONFIG_DEPLOYMENT_CHARTS_LIST: string;
46
46
  NETWORK_STATUS_INTERFACE: string;
47
+ CONFIG_DRIFT: string;
47
48
  };
48
49
  export declare const ROUTES: {
49
50
  APP: string;
@@ -120,5 +120,4 @@ export declare const DropdownIndicator: (props: any) => JSX.Element;
120
120
  export declare function mapByKey<T = Map<any, any>>(arr: any[], id: string): T;
121
121
  export declare function asyncWrap(promise: any): any[];
122
122
  export declare const prefixZeroIfSingleDigit: (value?: number) => string | number;
123
- export declare const throttle: <T extends (...args: unknown[]) => unknown>(func: T, delay?: number) => ((...args: Parameters<T>) => void);
124
123
  export {};
@@ -1,4 +1,4 @@
1
- declare const Toggle: ({ selected, onSelect, color, rootClassName, disabled, dataTestId, Icon, iconClass, throttleOnChange, ...props }: {
1
+ declare const Toggle: ({ selected, onSelect, color, rootClassName, disabled, dataTestId, Icon, iconClass, ...props }: {
2
2
  [x: string]: any;
3
3
  selected?: boolean;
4
4
  onSelect?: any;
@@ -8,6 +8,5 @@ declare const Toggle: ({ selected, onSelect, color, rootClassName, disabled, dat
8
8
  dataTestId?: string;
9
9
  Icon?: any;
10
10
  iconClass?: string;
11
- throttleOnChange?: boolean;
12
11
  }) => JSX.Element;
13
12
  export default Toggle;
@@ -1,3 +1,3 @@
1
1
  import { AppStatusDetailsChartType } from './types';
2
- declare const AppStatusDetailsChart: ({ filterRemoveHealth, showFooter }: AppStatusDetailsChartType) => JSX.Element;
2
+ declare const AppStatusDetailsChart: ({ filterRemoveHealth, showFooter, showConfigDriftInfo, onClose, }: AppStatusDetailsChartType) => JSX.Element;
3
3
  export default AppStatusDetailsChart;
@@ -0,0 +1,3 @@
1
+ import { TemplateConfiguration } from './types';
2
+ declare const DeploymentHistoryConfigList: ({ setFullScreenView, deploymentHistoryList, setDeploymentHistoryList, }: TemplateConfiguration) => JSX.Element;
3
+ export default DeploymentHistoryConfigList;
@@ -0,0 +1,3 @@
1
+ import { CompareViewDeploymentType } from './types';
2
+ declare const DeploymentHistoryDetailedView: ({ setFullScreenView, deploymentHistoryList, setDeploymentHistoryList, renderRunSource, resourceId, }: CompareViewDeploymentType) => JSX.Element;
3
+ export default DeploymentHistoryDetailedView;
@@ -1,3 +1,3 @@
1
1
  import { DeploymentTemplateHistoryType } from '../types';
2
- declare const DeploymentHistoryDiffView: ({ currentConfiguration, baseTemplateConfiguration, previousConfigAvailable, isUnpublished, isDeleteDraft, rootClassName, sortingConfig, codeEditorKey, }: DeploymentTemplateHistoryType) => JSX.Element;
2
+ declare const DeploymentHistoryDiffView: ({ currentConfiguration, baseTemplateConfiguration, previousConfigAvailable, isUnpublished, isDeleteDraft, rootClassName, comparisonBodyClassName, sortOrder, }: DeploymentTemplateHistoryType) => JSX.Element;
3
3
  export default DeploymentHistoryDiffView;
@@ -0,0 +1,3 @@
1
+ import { CompareWithBaseConfiguration } from './types';
2
+ declare const DeploymentHistoryHeader: ({ selectedDeploymentTemplate, setSelectedDeploymentTemplate, setFullScreenView, setLoader, setPreviousConfigAvailable, renderRunSource, resourceId, }: CompareWithBaseConfiguration) => JSX.Element;
3
+ export default DeploymentHistoryHeader;
@@ -0,0 +1,3 @@
1
+ import { DeploymentHistorySidebarType } from '../types';
2
+ declare const DeploymentHistorySidebar: ({ deploymentHistoryList, setDeploymentHistoryList, }: DeploymentHistorySidebarType) => JSX.Element;
3
+ export default DeploymentHistorySidebar;
@@ -0,0 +1,3 @@
1
+ export { default as DeploymentHistoryDetailedView } from './DeploymentHistoryDetailedView';
2
+ export { default as DeploymentHistoryConfigList } from './DeploymentHistoryConfigList.component';
3
+ export { default as DeploymentHistoryDiffView } from './DeploymentHistoryDiffView';
@@ -0,0 +1,35 @@
1
+ import { OptionType } from '../../../../Common';
2
+ import { DeploymentTemplateList, RunSourceType, RenderRunSourceType } from '../types';
3
+ export interface DeploymentHistoryParamsType {
4
+ appId: string;
5
+ pipelineId?: string;
6
+ historyComponent?: string;
7
+ baseConfigurationId?: string;
8
+ historyComponentName?: string;
9
+ envId?: string;
10
+ triggerId?: string;
11
+ }
12
+ export interface CompareViewDeploymentType extends RenderRunSourceType {
13
+ setFullScreenView: React.Dispatch<React.SetStateAction<boolean>>;
14
+ deploymentHistoryList: DeploymentTemplateList[];
15
+ setDeploymentHistoryList: React.Dispatch<React.SetStateAction<DeploymentTemplateList[]>>;
16
+ resourceId?: number;
17
+ }
18
+ export interface DeploymentTemplateOptions extends OptionType {
19
+ author: string;
20
+ status: string;
21
+ runSource?: RunSourceType;
22
+ }
23
+ export interface CompareWithBaseConfiguration extends RenderRunSourceType {
24
+ selectedDeploymentTemplate: DeploymentTemplateOptions;
25
+ setSelectedDeploymentTemplate: (selected: any) => void;
26
+ setFullScreenView: React.Dispatch<React.SetStateAction<boolean>>;
27
+ setLoader: React.Dispatch<React.SetStateAction<boolean>>;
28
+ setPreviousConfigAvailable: React.Dispatch<React.SetStateAction<boolean>>;
29
+ resourceId?: number;
30
+ }
31
+ export interface TemplateConfiguration {
32
+ setFullScreenView: React.Dispatch<React.SetStateAction<boolean>>;
33
+ deploymentHistoryList: DeploymentTemplateList[];
34
+ setDeploymentHistoryList: React.Dispatch<React.SetStateAction<DeploymentTemplateList[]>>;
35
+ }
@@ -1,5 +1,5 @@
1
1
  import { default as React } from 'react';
2
2
  import { TriggerDetailsType, TriggerOutputProps } from './types';
3
3
  export declare const TriggerDetails: React.MemoExoticComponent<({ status, startedOn, finishedOn, triggeredBy, triggeredByEmail, ciMaterials, gitTriggers, message, podStatus, type, stage, artifact, environmentName, isJobView, workerPodName, triggerMetadata, renderDeploymentHistoryTriggerMetaText, renderTargetConfigInfo, }: TriggerDetailsType) => JSX.Element>;
4
- declare const TriggerOutput: ({ fullScreenView, triggerHistory, setTriggerHistory, setFullScreenView, deploymentAppType, isBlobStorageConfigured, appReleaseTags, tagsEditable, hideImageTaggingHardDelete, fetchIdData, setFetchTriggerIdData, selectedEnvironmentName, deploymentHistoryResult, renderRunSource, renderCIListHeader, renderDeploymentApprovalInfo, processVirtualEnvironmentDeploymentData, renderVirtualHistoryArtifacts, renderDeploymentHistoryTriggerMetaText, resourceId, scrollToTop, scrollToBottom, renderTargetConfigInfo, appName, }: TriggerOutputProps) => JSX.Element;
4
+ declare const TriggerOutput: ({ fullScreenView, triggerHistory, setTriggerHistory, setFullScreenView, setDeploymentHistoryList, deploymentHistoryList, deploymentAppType, isBlobStorageConfigured, appReleaseTags, tagsEditable, hideImageTaggingHardDelete, fetchIdData, setFetchTriggerIdData, selectedEnvironmentName, deploymentHistoryResult, renderRunSource, renderCIListHeader, renderDeploymentApprovalInfo, processVirtualEnvironmentDeploymentData, renderVirtualHistoryArtifacts, renderDeploymentHistoryTriggerMetaText, resourceId, scrollToTop, scrollToBottom, renderTargetConfigInfo, }: TriggerOutputProps) => JSX.Element;
5
5
  export default TriggerOutput;
@@ -11,6 +11,6 @@ export * from './History.components';
11
11
  export * from './utils';
12
12
  export * from './TriggerOutput';
13
13
  export { default as LogsRenderer } from './LogsRenderer';
14
- export * from './DeploymentHistoryConfigDiff';
14
+ export * from './DeploymentHistoryDiff';
15
15
  export * from './CiPipelineSourceConfig';
16
16
  export * from './StatusFilterButtonComponent';
@@ -322,13 +322,14 @@ export interface TriggerOutputProps extends RenderRunSourceType, Pick<TriggerDet
322
322
  fullScreenView: boolean;
323
323
  triggerHistory: Map<number, History>;
324
324
  setFullScreenView: React.Dispatch<React.SetStateAction<boolean>>;
325
+ deploymentHistoryList: DeploymentTemplateList[];
326
+ setDeploymentHistoryList: React.Dispatch<React.SetStateAction<DeploymentTemplateList[]>>;
325
327
  deploymentAppType: DeploymentAppTypes;
326
328
  isBlobStorageConfigured: boolean;
327
329
  appReleaseTags: string[];
328
330
  tagsEditable: boolean;
329
331
  hideImageTaggingHardDelete: boolean;
330
332
  fetchIdData: FetchIdDataStatus;
331
- appName: string;
332
333
  selectedEnvironmentName?: string;
333
334
  renderCIListHeader?: (renderCIListHeaderProps: RenderCIListHeaderProps) => JSX.Element;
334
335
  renderDeploymentApprovalInfo?: (userApprovalMetadata: UserApprovalMetadataType) => JSX.Element;
@@ -342,7 +343,7 @@ export interface TriggerOutputProps extends RenderRunSourceType, Pick<TriggerDet
342
343
  scrollToTop: ReturnType<typeof useScrollable>[1];
343
344
  scrollToBottom: ReturnType<typeof useScrollable>[2];
344
345
  }
345
- export interface HistoryLogsProps extends Pick<TriggerOutputProps, 'scrollToTop' | 'scrollToBottom' | 'setFullScreenView' | 'deploymentAppType' | 'isBlobStorageConfigured' | 'appReleaseTags' | 'tagsEditable' | 'hideImageTaggingHardDelete' | 'selectedEnvironmentName' | 'processVirtualEnvironmentDeploymentData' | 'renderDeploymentApprovalInfo' | 'renderCIListHeader' | 'renderVirtualHistoryArtifacts' | 'fullScreenView' | 'appName' | 'triggerHistory'> {
346
+ export interface HistoryLogsProps extends Pick<TriggerOutputProps, 'scrollToTop' | 'scrollToBottom' | 'setFullScreenView' | 'deploymentHistoryList' | 'setDeploymentHistoryList' | 'deploymentAppType' | 'isBlobStorageConfigured' | 'appReleaseTags' | 'tagsEditable' | 'hideImageTaggingHardDelete' | 'selectedEnvironmentName' | 'processVirtualEnvironmentDeploymentData' | 'renderDeploymentApprovalInfo' | 'renderCIListHeader' | 'renderVirtualHistoryArtifacts' | 'fullScreenView'> {
346
347
  triggerDetails: History;
347
348
  loading: boolean;
348
349
  userApprovalMetadata: UserApprovalMetadataType;
@@ -392,11 +393,8 @@ export interface DeploymentTemplateHistoryType {
392
393
  isUnpublished?: boolean;
393
394
  isDeleteDraft?: boolean;
394
395
  rootClassName?: string;
395
- codeEditorKey?: React.Key;
396
- sortingConfig?: {
397
- sortBy: string;
398
- sortOrder: SortingOrder;
399
- };
396
+ comparisonBodyClassName?: string;
397
+ sortOrder?: SortingOrder;
400
398
  }
401
399
  export interface DeploymentHistoryDetailRes extends ResponseType {
402
400
  result?: DeploymentHistoryDetail;
@@ -419,6 +417,8 @@ export interface DeploymentHistorySidebarType {
419
417
  export interface AppStatusDetailsChartType {
420
418
  filterRemoveHealth?: boolean;
421
419
  showFooter: boolean;
420
+ showConfigDriftInfo?: boolean;
421
+ onClose?: () => void;
422
422
  }
423
423
  export interface StatusFilterButtonType {
424
424
  nodes: Array<Node>;
@@ -432,6 +432,9 @@ export declare enum NodeStatus {
432
432
  Suspended = "suspended",
433
433
  Unknown = "unknown"
434
434
  }
435
+ export declare enum NodeFilters {
436
+ drifted = "drifted"
437
+ }
435
438
  type NodesMap = {
436
439
  [key in NodeType]?: Map<string, any>;
437
440
  };
@@ -1,7 +1,2 @@
1
1
  import { CollapseProps } from './types';
2
- /**
3
- * Collapse component for smoothly expanding or collapsing its content.
4
- * Dynamically calculates the content height and applies smooth transitions.
5
- * It also supports a callback when the transition ends.
6
- */
7
- export declare const Collapse: ({ expand, onTransitionEnd, children }: CollapseProps) => JSX.Element;
2
+ export declare const Collapse: ({ expand, children }: CollapseProps) => JSX.Element;
@@ -1,2 +1,2 @@
1
- import { CollapsibleListProps } from './CollapsibleList.types';
2
- export declare const CollapsibleList: ({ config, onCollapseBtnClick }: CollapsibleListProps) => JSX.Element;
1
+ import { CollapsibleListProps, TabOptions } from './CollapsibleList.types';
2
+ export declare const CollapsibleList: <TabType extends TabOptions>({ config, tabType, onCollapseBtnClick, }: CollapsibleListProps<TabType>) => JSX.Element;
@@ -1,6 +1,30 @@
1
1
  import { default as React } from 'react';
2
2
  import { TippyProps } from '@tippyjs/react';
3
- export interface CollapsibleListItem {
3
+ interface ButtonTab {
4
+ /**
5
+ * Is tab active ( for button tab )
6
+ */
7
+ isActive: boolean;
8
+ /**
9
+ * The callback function to handle click events on the button.
10
+ */
11
+ onClick?: (e: React.MouseEvent<HTMLButtonElement>) => void;
12
+ href?: never;
13
+ }
14
+ interface NavLinkTab {
15
+ /**
16
+ * The URL of the nav link.
17
+ */
18
+ href: string;
19
+ /**
20
+ * The callback function to handle click events on the nav link.
21
+ */
22
+ onClick?: (e: React.MouseEvent<HTMLAnchorElement>) => void;
23
+ isActive?: never;
24
+ }
25
+ export type TabOptions = 'button' | 'navLink';
26
+ type ConditionalTabType<TabType extends TabOptions> = TabType extends 'button' ? ButtonTab : NavLinkTab;
27
+ export type CollapsibleListItem<TabType extends TabOptions> = ConditionalTabType<TabType> & {
4
28
  /**
5
29
  * The title of the list item.
6
30
  */
@@ -9,10 +33,6 @@ export interface CollapsibleListItem {
9
33
  * The subtitle of the list item.
10
34
  */
11
35
  subtitle?: string;
12
- /**
13
- * If true, the title will be rendered with line-through.
14
- */
15
- strikeThrough?: boolean;
16
36
  /**
17
37
  * Configuration for the icon.
18
38
  */
@@ -30,16 +50,8 @@ export interface CollapsibleListItem {
30
50
  */
31
51
  tooltipProps?: TippyProps;
32
52
  };
33
- /**
34
- * The URL of the nav link.
35
- */
36
- href?: string;
37
- /**
38
- * The callback function to handle click events on the nav link.
39
- */
40
- onClick?: (e: React.MouseEvent<HTMLAnchorElement>) => void;
41
- }
42
- export interface CollapsibleListConfig {
53
+ };
54
+ export interface CollapsibleListConfig<TabType extends 'button' | 'navLink'> {
43
55
  /**
44
56
  * The unique identifier for the collapsible list.
45
57
  */
@@ -77,17 +89,21 @@ export interface CollapsibleListConfig {
77
89
  /**
78
90
  * An array of items to be displayed in the collapsible list.
79
91
  */
80
- items: CollapsibleListItem[];
92
+ items: CollapsibleListItem<TabType>[];
81
93
  /**
82
94
  * Boolean indicating whether the list is expanded or not.
83
95
  */
84
96
  isExpanded?: boolean;
85
97
  }
86
- export interface CollapsibleListProps {
98
+ export interface CollapsibleListProps<TabType extends TabOptions> {
87
99
  /**
88
100
  * An array of collapsible list configurations.
89
101
  */
90
- config: CollapsibleListConfig[];
102
+ config: CollapsibleListConfig<TabType>[];
103
+ /**
104
+ * Type of tab list: button or navLink
105
+ */
106
+ tabType: TabType;
91
107
  /**
92
108
  * Function to handle the collapse button click event.
93
109
  *
@@ -97,3 +113,4 @@ export interface CollapsibleListProps {
97
113
  */
98
114
  onCollapseBtnClick?: (id: string, e: React.MouseEvent<HTMLButtonElement>) => void;
99
115
  }
116
+ export {};
@@ -1,2 +1,2 @@
1
1
  import { DeploymentConfigDiffProps } from './DeploymentConfigDiff.types';
2
- export declare const DeploymentConfigDiff: ({ isLoading, configList, collapsibleNavList, navList, goBackURL, navHeading, navHelpText, isNavHelpTextShowingError, tabConfig, showDetailedDiffState, hideDiffState, renderedInDrawer, ...resProps }: DeploymentConfigDiffProps) => JSX.Element;
2
+ export declare const DeploymentConfigDiff: ({ isLoading, configList, collapsibleNavList, navList, goBackURL, navHeading, navHelpText, tabConfig, ...resProps }: DeploymentConfigDiffProps) => JSX.Element;
@@ -4,12 +4,6 @@ import { DeploymentHistoryDetail } from '../CICDHistory';
4
4
  import { CollapsibleListConfig, CollapsibleListItem } from '../CollapsibleList';
5
5
  import { SelectPickerProps } from '../SelectPicker';
6
6
  import { CollapseProps } from '../Collapse';
7
- export declare enum DeploymentConfigDiffState {
8
- NO_DIFF = "noDiff",
9
- HAS_DIFF = "hasDiff",
10
- ADDED = "added",
11
- DELETED = "deleted"
12
- }
13
7
  export interface DeploymentConfigType {
14
8
  list: DeploymentHistoryDetail;
15
9
  heading: React.ReactNode;
@@ -17,13 +11,10 @@ export interface DeploymentConfigType {
17
11
  export interface DeploymentConfigListItem {
18
12
  id: string;
19
13
  title: string;
20
- name?: string;
21
- pathType: EnvResourceType;
22
14
  primaryConfig: DeploymentConfigType;
23
15
  secondaryConfig: DeploymentConfigType;
24
- diffState: DeploymentConfigDiffState;
25
- singleView?: boolean;
26
- groupHeader?: string;
16
+ hasDiff?: boolean;
17
+ isDeploymentTemplate?: boolean;
27
18
  }
28
19
  export type DeploymentConfigDiffSelectPickerProps = {
29
20
  type: 'string';
@@ -36,10 +27,12 @@ export type DeploymentConfigDiffSelectPickerProps = {
36
27
  text?: never;
37
28
  selectPickerProps: SelectPickerProps;
38
29
  };
39
- export interface DeploymentConfigDiffNavigationItem extends Pick<CollapsibleListItem, 'href' | 'title' | 'onClick'> {
40
- diffState: DeploymentConfigListItem['diffState'];
30
+ export interface DeploymentConfigDiffNavigationItem extends Pick<CollapsibleListItem<'navLink'>, 'title'> {
31
+ hasDiff?: boolean;
32
+ href: string;
33
+ onClick: (e: React.MouseEvent<HTMLAnchorElement>) => void;
41
34
  }
42
- export interface DeploymentConfigDiffNavigationCollapsibleItem extends Pick<CollapsibleListConfig, 'id' | 'header' | 'noItemsText'> {
35
+ export interface DeploymentConfigDiffNavigationCollapsibleItem extends Pick<CollapsibleListConfig<'navLink'>, 'id' | 'header' | 'noItemsText'> {
43
36
  items: DeploymentConfigDiffNavigationItem[];
44
37
  }
45
38
  export interface DeploymentConfigDiffProps {
@@ -47,19 +40,14 @@ export interface DeploymentConfigDiffProps {
47
40
  errorConfig?: {
48
41
  error: boolean;
49
42
  code: number;
50
- message?: string;
51
- redirectURL?: string;
52
43
  reload: () => void;
53
44
  };
54
45
  configList: DeploymentConfigListItem[];
55
- showDetailedDiffState?: boolean;
56
- hideDiffState?: boolean;
57
46
  headerText?: string;
58
47
  scrollIntoViewId?: string;
59
48
  selectorsConfig: {
60
49
  primaryConfig: DeploymentConfigDiffSelectPickerProps[];
61
50
  secondaryConfig: DeploymentConfigDiffSelectPickerProps[];
62
- hideDivider?: boolean;
63
51
  };
64
52
  sortingConfig?: {
65
53
  sortBy: string;
@@ -71,39 +59,34 @@ export interface DeploymentConfigDiffProps {
71
59
  goBackURL?: string;
72
60
  navHeading: string;
73
61
  navHelpText?: string;
74
- isNavHelpTextShowingError?: boolean;
75
62
  tabConfig?: {
76
63
  tabs: string[];
77
64
  activeTab: string;
78
65
  onClick: (tab: string) => void;
79
66
  };
80
- scopeVariablesConfig?: {
81
- convertVariables: boolean;
82
- onConvertVariablesClick: () => void;
83
- };
84
- renderedInDrawer?: boolean;
85
67
  }
86
- export interface DeploymentConfigDiffNavigationProps extends Pick<DeploymentConfigDiffProps, 'isLoading' | 'navList' | 'collapsibleNavList' | 'goBackURL' | 'navHeading' | 'navHelpText' | 'isNavHelpTextShowingError' | 'tabConfig' | 'showDetailedDiffState' | 'hideDiffState'> {
68
+ export interface DeploymentConfigDiffNavigationProps extends Pick<DeploymentConfigDiffProps, 'isLoading' | 'navList' | 'collapsibleNavList' | 'goBackURL' | 'navHeading' | 'navHelpText' | 'tabConfig'> {
87
69
  }
88
- export interface DeploymentConfigDiffMainProps extends Pick<DeploymentConfigDiffProps, 'isLoading' | 'errorConfig' | 'headerText' | 'configList' | 'scrollIntoViewId' | 'selectorsConfig' | 'sortingConfig' | 'scopeVariablesConfig' | 'showDetailedDiffState' | 'hideDiffState'> {
70
+ export interface DeploymentConfigDiffMainProps extends Pick<DeploymentConfigDiffProps, 'isLoading' | 'errorConfig' | 'headerText' | 'configList' | 'scrollIntoViewId' | 'selectorsConfig' | 'sortingConfig'> {
89
71
  }
90
- export type DeploymentConfigDiffAccordionProps = Pick<CollapseProps, 'onTransitionEnd'> & Pick<DeploymentConfigDiffProps, 'showDetailedDiffState' | 'hideDiffState'> & {
72
+ export interface DeploymentConfigDiffAccordionProps extends Pick<CollapseProps, 'onTransitionEnd'> {
91
73
  id: string;
92
74
  title: string;
93
75
  children: React.ReactNode;
94
- diffState: DeploymentConfigDiffState;
76
+ hasDiff?: boolean;
95
77
  isExpanded?: boolean;
96
78
  onClick?: (e: React.MouseEvent<HTMLButtonElement>) => void;
97
- };
79
+ }
98
80
  export type DiffHeadingDataType<DeploymentTemplate> = DeploymentTemplate extends true ? DeploymentTemplateDTO : ConfigMapSecretDataConfigDatumDTO;
99
81
  export type AppEnvDeploymentConfigListParams<IsManifestView> = (IsManifestView extends true ? {
100
82
  currentList: ManifestTemplateDTO;
101
83
  compareList: ManifestTemplateDTO;
84
+ sortOrder?: never;
102
85
  } : {
103
86
  currentList: AppEnvDeploymentConfigDTO;
104
87
  compareList: AppEnvDeploymentConfigDTO;
88
+ sortOrder?: SortingOrder;
105
89
  }) & {
106
90
  getNavItemHref: (resourceType: EnvResourceType, resourceName: string) => string;
107
91
  isManifestView?: IsManifestView;
108
- convertVariables?: boolean;
109
92
  };
@@ -1,6 +1,5 @@
1
1
  import { DeploymentConfigDiffProps, AppEnvDeploymentConfigListParams } from '..';
2
- import { ConfigMapSecretDataConfigDatumDTO, DeploymentTemplateDTO, TemplateListDTO } from '../../Services/app.types';
3
- export declare const getDeploymentTemplateData: (data: DeploymentTemplateDTO) => any;
2
+ import { ConfigMapSecretDataConfigDatumDTO, TemplateListDTO } from '../../Services/app.types';
4
3
  /**
5
4
  * Retrieves the draft data from the given configuration data object.
6
5
  *
@@ -28,7 +27,7 @@ export declare const mergeConfigDataArraysByName: (primaryArray: ConfigMapSecret
28
27
  *
29
28
  * @returns An object containing the combined deployment configuration list, a collapsible navigation list, and a navigation list.
30
29
  */
31
- export declare const getAppEnvDeploymentConfigList: <ManifestView extends boolean = false>({ currentList, compareList, getNavItemHref, isManifestView, convertVariables, }: AppEnvDeploymentConfigListParams<ManifestView>) => {
30
+ export declare const getAppEnvDeploymentConfigList: <ManifestView extends boolean = false>({ currentList, compareList, getNavItemHref, isManifestView, sortOrder, }: AppEnvDeploymentConfigListParams<ManifestView>) => {
32
31
  configList: DeploymentConfigDiffProps["configList"];
33
32
  navList: DeploymentConfigDiffProps["navList"];
34
33
  collapsibleNavList: DeploymentConfigDiffProps["collapsibleNavList"];
@@ -1,2 +1,2 @@
1
1
  import { DeploymentConfigDiffAccordionProps } from './DeploymentConfigDiff.types';
2
- export declare const DeploymentConfigDiffAccordion: ({ diffState, showDetailedDiffState, hideDiffState, children, title, id, isExpanded, onClick, onTransitionEnd, }: DeploymentConfigDiffAccordionProps) => JSX.Element;
2
+ export declare const DeploymentConfigDiffAccordion: import('react').ForwardRefExoticComponent<DeploymentConfigDiffAccordionProps & import('react').RefAttributes<HTMLDivElement>>;
@@ -1,2 +1,2 @@
1
1
  import { DeploymentConfigDiffMainProps } from './DeploymentConfigDiff.types';
2
- export declare const DeploymentConfigDiffMain: ({ isLoading, errorConfig, headerText, configList, selectorsConfig, sortingConfig, scrollIntoViewId, scopeVariablesConfig, showDetailedDiffState, hideDiffState, }: DeploymentConfigDiffMainProps) => JSX.Element;
2
+ export declare const DeploymentConfigDiffMain: ({ isLoading, errorConfig, headerText, configList, selectorsConfig, sortingConfig, scrollIntoViewId, }: DeploymentConfigDiffMainProps) => JSX.Element;
@@ -1,2 +1,2 @@
1
1
  import { DeploymentConfigDiffNavigationProps } from './DeploymentConfigDiff.types';
2
- export declare const DeploymentConfigDiffNavigation: ({ isLoading, collapsibleNavList, navList, goBackURL, navHeading, navHelpText, isNavHelpTextShowingError, tabConfig, showDetailedDiffState, hideDiffState, }: DeploymentConfigDiffNavigationProps) => JSX.Element;
2
+ export declare const DeploymentConfigDiffNavigation: ({ isLoading, collapsibleNavList, navList, goBackURL, navHeading, navHelpText, tabConfig, }: DeploymentConfigDiffNavigationProps) => JSX.Element;
@@ -1,4 +1,3 @@
1
1
  export * from './DeploymentConfigDiff.component';
2
2
  export * from './DeploymentConfigDiff.types';
3
3
  export * from './DeploymentConfigDiff.utils';
4
- export * from './DeploymentConfigDiff.constants';
@@ -4,12 +4,11 @@ import { ComponentSizeType } from '../../constants';
4
4
  import { MutableRefObject, ReactElement, ReactNode } from 'react';
5
5
  import { GroupBase, GroupHeadingProps, Props as ReactSelectProps, SelectInstance } from 'react-select';
6
6
  import { CreatableProps } from 'react-select/creatable';
7
- import { TooltipProps } from '@Common/Tooltip/types';
8
7
  export interface SelectPickerOptionType<OptionValue = string | number> extends OptionType<OptionValue, ReactNode> {
9
8
  /**
10
9
  * Description to be displayed for the option
11
10
  */
12
- description?: ReactNode;
11
+ description?: string;
13
12
  /**
14
13
  * Icon at the start of the option
15
14
  */
@@ -18,10 +17,6 @@ export interface SelectPickerOptionType<OptionValue = string | number> extends O
18
17
  * Icon at the end of the option
19
18
  */
20
19
  endIcon?: ReactElement;
21
- /**
22
- * Props passed to show the tippy on option
23
- */
24
- tooltipProps?: Omit<TooltipProps, 'alwaysShowTippyOnHover' | 'showOnTruncate' | 'shortcutKeyCombo'> | (Omit<TooltipProps, 'alwaysShowTippyOnHover' | 'showOnTruncate' | 'content'> & Required<Pick<TooltipProps, 'shortcutKeyCombo'>>);
25
20
  }
26
21
  type SelectProps<OptionValue, IsMulti extends boolean> = ReactSelectProps<SelectPickerOptionType<OptionValue>, IsMulti, GroupBase<SelectPickerOptionType<OptionValue>>>;
27
22
  declare module 'react-select/base' {
@@ -50,17 +50,4 @@ export declare const getIsManualApprovalSpecific: (userApprovalConfig?: Pick<Use
50
50
  */
51
51
  export declare const getHandleOpenURL: (url: string) => () => void;
52
52
  export declare const getDefaultValueFromType: (value: unknown) => {};
53
- /**
54
- * Groups an array of objects by a specified key.
55
- *
56
- * This function takes an array of objects and a key, and groups the objects in the array
57
- * based on the value of the specified key. If an object does not have the specified key,
58
- * it will be grouped under the `'UNGROUPED'` key.
59
- *
60
- * @param array - The array of objects to be grouped.
61
- * @param key - The key of the object used to group the array.
62
- * @returns An object where the keys are the unique values of the specified key in the array,
63
- * and the values are arrays of objects that share the same key value.
64
- */
65
- export declare const groupArrayByObjectKey: <T extends Record<string, any>, K extends keyof T>(array: T[], key: K) => Record<string, T[]>;
66
53
  export {};
@@ -5,7 +5,4 @@ export declare const getCITriggerInfo: (params: GetCITriggerInfoParamsType) => P
5
5
  * The only difference between this and getCITriggerInfo is it doesn't have env and trigger related meta info
6
6
  */
7
7
  export declare const getArtifactInfo: (params: Pick<GetCITriggerInfoParamsType, "ciArtifactId">) => Promise<CIMaterialInfoType>;
8
- export declare const getAppEnvDeploymentConfig: ({ params, signal, }: {
9
- params: AppEnvDeploymentConfigPayloadType;
10
- signal?: AbortSignal;
11
- }) => Promise<ResponseType<AppEnvDeploymentConfigDTO>>;
8
+ export declare const getAppEnvDeploymentConfig: (params: AppEnvDeploymentConfigPayloadType, signal?: AbortSignal) => Promise<ResponseType<AppEnvDeploymentConfigDTO>>;
@@ -114,7 +114,6 @@ export interface DraftMetadataDTO {
114
114
  draftId: number;
115
115
  draftVersionId: number;
116
116
  draftState: number;
117
- draftResolvedValue: string;
118
117
  approvers: string[];
119
118
  canApprove: boolean;
120
119
  commentsCount: number;
@@ -151,40 +150,26 @@ export interface ConfigMapSecretDataType {
151
150
  export declare enum ConfigResourceType {
152
151
  ConfigMap = "ConfigMap",
153
152
  Secret = "Secret",
154
- DeploymentTemplate = "Deployment Template",
155
- PipelineStrategy = "Pipeline Strategy"
153
+ DeploymentTemplate = "Deployment Template"
156
154
  }
157
155
  export interface DeploymentTemplateDTO {
158
156
  resourceType: ConfigResourceType.DeploymentTemplate;
159
- data: Record<string, any>;
160
- deploymentDraftData: ConfigMapSecretDataType | null;
161
- variableSnapshot: {
162
- 'Deployment Template': Record<string, string>;
157
+ data: {
158
+ [key: string]: any;
163
159
  };
164
- templateVersion: string;
165
- isAppMetricsEnabled?: true;
166
- resolvedValue: Record<string, any>;
160
+ deploymentDraftData: ConfigMapSecretDataType | null;
167
161
  }
168
162
  export interface ConfigMapSecretDataDTO {
169
163
  resourceType: Extract<ConfigResourceType, ConfigResourceType.ConfigMap | ConfigResourceType.Secret>;
170
164
  data: ConfigMapSecretDataType;
171
- variableSnapshot: Record<string, Record<string, string>>;
172
- resolvedValue: string;
173
- }
174
- export interface PipelineConfigDataDTO {
175
- resourceType: ConfigResourceType.PipelineStrategy;
176
- data: Record<string, any>;
177
- pipelineTriggerType: string;
178
- Strategy: string;
179
165
  }
180
166
  export interface AppEnvDeploymentConfigDTO {
181
167
  deploymentTemplate: DeploymentTemplateDTO | null;
182
168
  configMapData: ConfigMapSecretDataDTO | null;
183
169
  secretsData: ConfigMapSecretDataDTO | null;
184
- pipelineConfigData?: PipelineConfigDataDTO;
185
170
  isAppAdmin: boolean;
186
171
  }
187
- export type AppEnvDeploymentConfigPayloadType = {
172
+ export interface AppEnvDeploymentConfigPayloadType {
188
173
  appName: string;
189
174
  envName: string;
190
175
  configType: AppEnvDeploymentConfigType;
@@ -193,14 +178,7 @@ export type AppEnvDeploymentConfigPayloadType = {
193
178
  resourceType?: ConfigResourceType;
194
179
  resourceId?: number;
195
180
  resourceName?: string;
196
- configArea?: 'AppConfiguration';
197
- } | {
198
- appName: string;
199
- envName: string;
200
- pipelineId: number;
201
- configArea: 'CdRollback' | 'DeploymentHistory';
202
- wfrId: number;
203
- };
181
+ }
204
182
  export declare enum TemplateListType {
205
183
  DefaultVersions = 1,
206
184
  PublishedOnEnvironments = 2,
@@ -218,7 +196,6 @@ export interface TemplateListDTO {
218
196
  finishedOn?: string;
219
197
  status?: string;
220
198
  pipelineId?: number;
221
- wfrId?: number;
222
199
  }
223
200
  export interface ManifestTemplateDTO {
224
201
  data: string;
@@ -235,7 +212,6 @@ export declare enum EnvResourceType {
235
212
  ConfigMap = "configmap",
236
213
  Secret = "secrets",
237
214
  DeploymentTemplate = "deployment-template",
238
- Manifest = "manifest",
239
- PipelineStrategy = "pipeline-strategy"
215
+ Manifest = "manifest"
240
216
  }
241
217
  export {};
@@ -104,6 +104,7 @@ export interface Node {
104
104
  port: number;
105
105
  canBeHibernated: boolean;
106
106
  isHibernated: boolean;
107
+ hasDrift?: boolean;
107
108
  }
108
109
  export interface iNodes extends Array<iNode> {
109
110
  }