@devtron-labs/devtron-fe-common-lib 0.3.12 → 0.3.14-beta-1

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 (56) hide show
  1. package/dist/Common/Constants.d.ts +1 -0
  2. package/dist/Common/Helper.d.ts +1 -0
  3. package/dist/Common/Toggle/Toggle.d.ts +2 -1
  4. package/dist/Common/Tooltip/ShortcutKeyComboTooltipContent.d.ts +3 -0
  5. package/dist/Common/Tooltip/Tooltip.d.ts +1 -1
  6. package/dist/Common/Tooltip/index.d.ts +1 -0
  7. package/dist/Common/Tooltip/types.d.ts +39 -0
  8. package/dist/Shared/Components/Button/types.d.ts +1 -1
  9. package/dist/Shared/Components/CICDHistory/DeploymentHistoryConfigDiff/DeploymentHistoryConfigDiff.d.ts +2 -0
  10. package/dist/Shared/Components/CICDHistory/DeploymentHistoryConfigDiff/DeploymentHistoryConfigDiffCompare.d.ts +2 -0
  11. package/dist/Shared/Components/CICDHistory/{DeploymentHistoryDiff → DeploymentHistoryConfigDiff}/DeploymentHistoryDiffView.d.ts +1 -1
  12. package/dist/Shared/Components/CICDHistory/DeploymentHistoryConfigDiff/helpers.d.ts +3 -0
  13. package/dist/Shared/Components/CICDHistory/DeploymentHistoryConfigDiff/index.d.ts +2 -0
  14. package/dist/Shared/Components/CICDHistory/DeploymentHistoryConfigDiff/types.d.ts +34 -0
  15. package/dist/Shared/Components/CICDHistory/DeploymentHistoryConfigDiff/utils.d.ts +21 -0
  16. package/dist/Shared/Components/CICDHistory/History.components.d.ts +54 -1
  17. package/dist/Shared/Components/CICDHistory/LogsRenderer.d.ts +55 -2
  18. package/dist/Shared/Components/CICDHistory/TriggerOutput.d.ts +1 -1
  19. package/dist/Shared/Components/CICDHistory/index.d.ts +2 -2
  20. package/dist/Shared/Components/CICDHistory/types.d.ts +13 -5
  21. package/dist/Shared/Components/DeploymentConfigDiff/DeploymentConfigDiff.component.d.ts +1 -1
  22. package/dist/Shared/Components/DeploymentConfigDiff/DeploymentConfigDiff.types.d.ts +25 -10
  23. package/dist/Shared/Components/DeploymentConfigDiff/DeploymentConfigDiff.utils.d.ts +10 -3
  24. package/dist/Shared/Components/DeploymentConfigDiff/DeploymentConfigDiffAccordion.d.ts +9 -2
  25. package/dist/Shared/Components/DeploymentConfigDiff/DeploymentConfigDiffMain.d.ts +1 -1
  26. package/dist/Shared/Components/DeploymentConfigDiff/DeploymentConfigDiffNavigation.d.ts +1 -1
  27. package/dist/Shared/Components/SelectPicker/type.d.ts +5 -0
  28. package/dist/Shared/Helpers.d.ts +13 -0
  29. package/dist/Shared/Services/app.service.d.ts +7 -1
  30. package/dist/Shared/Services/app.types.d.ts +34 -7
  31. package/dist/assets/index.css +1 -1
  32. package/dist/{cssMode-CSrSSFls.js → cssMode-IylcoDbx.js} +1 -1
  33. package/dist/{freemarker2-gNSPakfi.js → freemarker2-Dc0BAReS.js} +1 -1
  34. package/dist/{handlebars-U05gCB6c.js → handlebars-D8d3oeeL.js} +1 -1
  35. package/dist/{html-BSgM7zG4.js → html-DHIUzE39.js} +1 -1
  36. package/dist/{htmlMode-DZDTPhJ9.js → htmlMode-C8ZDw4HO.js} +1 -1
  37. package/dist/{index-CMK9o8Mr.js → index-ByVomRMV.js} +44222 -44039
  38. package/dist/index.js +406 -397
  39. package/dist/{javascript-BagPBd8V.js → javascript-ietUe3zr.js} +1 -1
  40. package/dist/{jsonMode-DoSGktbS.js → jsonMode-D-2SVjtk.js} +1 -1
  41. package/dist/{liquid-CVtirNJX.js → liquid-rTZVyZ7L.js} +1 -1
  42. package/dist/{mdx-NbX_-jqo.js → mdx-DlWEeuen.js} +1 -1
  43. package/dist/{python-Dvx_IPjD.js → python-CoQh6-mN.js} +1 -1
  44. package/dist/{razor-BE1hcPKi.js → razor-B7QZez8l.js} +1 -1
  45. package/dist/{tsMode-lRC0dkbJ.js → tsMode-PD0LurRg.js} +1 -1
  46. package/dist/{typescript-DXtZgVL8.js → typescript-Cl3AgiB7.js} +1 -1
  47. package/dist/{xml-cDwxXlwI.js → xml-DUme7BW4.js} +1 -1
  48. package/dist/{yaml-DGTBq1Cb.js → yaml-CZ5BQ0MU.js} +1 -1
  49. package/package.json +2 -1
  50. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/DeploymentHistoryConfigList.component.d.ts +0 -3
  51. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/DeploymentHistoryDetailedView.d.ts +0 -3
  52. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/DeploymentHistoryHeader.d.ts +0 -3
  53. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/DeploymentHistorySidebar.d.ts +0 -3
  54. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/index.d.ts +0 -3
  55. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/types.d.ts +0 -35
  56. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/utils.d.ts +0 -11
@@ -286,3 +286,4 @@ export declare const VULNERABILITIES_SORT_PRIORITY: {
286
286
  low: number;
287
287
  unknown: number;
288
288
  };
289
+ export declare const IS_PLATFORM_MAC_OS: boolean;
@@ -120,4 +120,5 @@ 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);
123
124
  export {};
@@ -1,4 +1,4 @@
1
- declare const Toggle: ({ selected, onSelect, color, rootClassName, disabled, dataTestId, Icon, iconClass, ...props }: {
1
+ declare const Toggle: ({ selected, onSelect, color, rootClassName, disabled, dataTestId, Icon, iconClass, throttleOnChange, ...props }: {
2
2
  [x: string]: any;
3
3
  selected?: boolean;
4
4
  onSelect?: any;
@@ -8,5 +8,6 @@ declare const Toggle: ({ selected, onSelect, color, rootClassName, disabled, dat
8
8
  dataTestId?: string;
9
9
  Icon?: any;
10
10
  iconClass?: string;
11
+ throttleOnChange?: boolean;
11
12
  }) => JSX.Element;
12
13
  export default Toggle;
@@ -0,0 +1,3 @@
1
+ import { TooltipProps } from './types';
2
+ declare const ShortcutKeyComboTooltipContent: ({ text, combo }: TooltipProps["shortcutKeyCombo"]) => JSX.Element;
3
+ export default ShortcutKeyComboTooltipContent;
@@ -1,3 +1,3 @@
1
1
  import { TooltipProps } from './types';
2
- declare const Tooltip: ({ alwaysShowTippyOnHover, showOnTruncate, wordBreak, children: child, ...rest }: TooltipProps) => JSX.Element;
2
+ declare const Tooltip: ({ shortcutKeyCombo, alwaysShowTippyOnHover, showOnTruncate, wordBreak, children: child, ...rest }: TooltipProps) => JSX.Element;
3
3
  export default Tooltip;
@@ -1,2 +1,3 @@
1
1
  export { default as Tooltip } from './Tooltip';
2
+ export type { SupportedKeyboardKeysType } from './types';
2
3
  export { TOOLTIP_CONTENTS } from './constants';
@@ -1,4 +1,11 @@
1
1
  import { TippyProps } from '@tippyjs/react';
2
+ export declare const KEYBOARD_KEYS_MAP: {
3
+ readonly Control: "⌘" | "Ctrl";
4
+ readonly Shift: "⇧";
5
+ readonly F: "F";
6
+ readonly E: "E";
7
+ };
8
+ export type SupportedKeyboardKeysType = keyof typeof KEYBOARD_KEYS_MAP;
2
9
  type BaseTooltipProps = {
3
10
  /**
4
11
  * If true, show tippy on truncate
@@ -10,6 +17,12 @@ type BaseTooltipProps = {
10
17
  * @default false
11
18
  */
12
19
  alwaysShowTippyOnHover?: never;
20
+ /**
21
+ * If true, use the common styling for shortcuts
22
+ * @default undefined
23
+ */
24
+ shortcutKeyCombo?: never;
25
+ content: TippyProps['content'];
13
26
  } | {
14
27
  /**
15
28
  * If alwaysShowTippyOnHover is defined this prop doesn't work
@@ -18,9 +31,35 @@ type BaseTooltipProps = {
18
31
  showOnTruncate?: never;
19
32
  /**
20
33
  * If true, wrap with tippy irrespective of other options
34
+ * @default true
35
+ */
36
+ alwaysShowTippyOnHover: boolean;
37
+ /**
38
+ * If true, use the common styling for shortcuts
39
+ * @default undefined
40
+ */
41
+ shortcutKeyCombo?: never;
42
+ content: TippyProps['content'];
43
+ } | {
44
+ /**
45
+ * If true, show tippy on truncate
46
+ * @default false
47
+ */
48
+ showOnTruncate?: never;
49
+ /**
50
+ * If showOnTruncate is defined this prop doesn't work
21
51
  * @default false
22
52
  */
23
53
  alwaysShowTippyOnHover?: boolean;
54
+ /**
55
+ * If true, use the common styling for shortcuts
56
+ * @default undefined
57
+ */
58
+ shortcutKeyCombo: {
59
+ text: string;
60
+ combo: SupportedKeyboardKeysType[];
61
+ };
62
+ content?: never;
24
63
  };
25
64
  export type TooltipProps = BaseTooltipProps & TippyProps & {
26
65
  /**
@@ -82,7 +82,7 @@ export type ButtonProps = ({
82
82
  /**
83
83
  * Props for tooltip
84
84
  */
85
- tooltipProps: Omit<TooltipProps, 'alwaysShowTippyOnHover' | 'showOnTruncate'>;
85
+ tooltipProps: Omit<TooltipProps, 'alwaysShowTippyOnHover' | 'showOnTruncate' | 'shortcutKeyCombo'> | (Omit<TooltipProps, 'alwaysShowTippyOnHover' | 'showOnTruncate' | 'content'> & Required<Pick<TooltipProps, 'shortcutKeyCombo'>>);
86
86
  } | {
87
87
  showTooltip?: never;
88
88
  tooltipProps?: never;
@@ -0,0 +1,2 @@
1
+ import { DeploymentHistoryConfigDiffProps } from './types';
2
+ export declare const DeploymentHistoryConfigDiff: ({ appName, envName, pipelineId, wfrId, triggerHistory, setFullScreenView, }: DeploymentHistoryConfigDiffProps) => JSX.Element;
@@ -0,0 +1,2 @@
1
+ import { DeploymentHistoryDiffDetailedProps } from './types';
2
+ export declare const DeploymentHistoryConfigDiffCompare: ({ envName, setFullScreenView, pipelineDeployments, wfrId, previousWfrId, convertVariables, setConvertVariables, ...props }: DeploymentHistoryDiffDetailedProps) => JSX.Element;
@@ -1,3 +1,3 @@
1
1
  import { DeploymentTemplateHistoryType } from '../types';
2
- declare const DeploymentHistoryDiffView: ({ currentConfiguration, baseTemplateConfiguration, previousConfigAvailable, isUnpublished, isDeleteDraft, rootClassName, comparisonBodyClassName, sortOrder, }: DeploymentTemplateHistoryType) => JSX.Element;
2
+ declare const DeploymentHistoryDiffView: ({ currentConfiguration, baseTemplateConfiguration, previousConfigAvailable, isUnpublished, isDeleteDraft, rootClassName, sortOrder, }: DeploymentTemplateHistoryType) => JSX.Element;
3
3
  export default DeploymentHistoryDiffView;
@@ -0,0 +1,3 @@
1
+ import { DeploymentConfigDiffProps } from '@Shared/Components/DeploymentConfigDiff';
2
+ export declare const renderDeploymentHistoryConfig: (config: DeploymentConfigDiffProps["configList"], heading: string, pathname: string) => JSX.Element;
3
+ export declare const renderPipelineDeploymentStatusIcon: (status: string) => JSX.Element;
@@ -0,0 +1,2 @@
1
+ export * from './DeploymentHistoryConfigDiff';
2
+ export { default as DeploymentHistoryDiffView } from './DeploymentHistoryDiffView';
@@ -0,0 +1,34 @@
1
+ import { Dispatch, SetStateAction } from 'react';
2
+ import { DeploymentConfigDiffProps } from '@Shared/Components/DeploymentConfigDiff';
3
+ import { EnvResourceType } from '../../../Services';
4
+ import { History } from '../types';
5
+ export interface DeploymentHistoryConfigDiffProps {
6
+ appName: string;
7
+ envName: string;
8
+ pipelineId: number;
9
+ wfrId: number;
10
+ triggerHistory: Map<number, History>;
11
+ setFullScreenView: (fullscreen: boolean) => void;
12
+ }
13
+ export type DeploymentHistoryDiffDetailedProps = Pick<DeploymentConfigDiffProps, 'collapsibleNavList' | 'configList' | 'errorConfig' | 'isLoading' | 'navList'> & Pick<DeploymentHistoryConfigDiffProps, 'setFullScreenView' | 'wfrId' | 'envName'> & {
14
+ pipelineDeployments: History[];
15
+ previousWfrId: number;
16
+ convertVariables: boolean;
17
+ setConvertVariables: Dispatch<SetStateAction<boolean>>;
18
+ };
19
+ export interface DeploymentHistoryConfigDiffQueryParams {
20
+ compareWfrId: number;
21
+ }
22
+ export interface DeploymentHistoryConfigDiffRouteParams {
23
+ resourceType: EnvResourceType;
24
+ resourceName: string;
25
+ }
26
+ export interface DeploymentHistoryParamsType {
27
+ appId: string;
28
+ pipelineId?: string;
29
+ historyComponent?: string;
30
+ baseConfigurationId?: string;
31
+ historyComponentName?: string;
32
+ envId?: string;
33
+ triggerId?: string;
34
+ }
@@ -0,0 +1,21 @@
1
+ import { History } from '../types';
2
+ import { DeploymentHistoryConfigDiffProps } from './types';
3
+ export declare const getPipelineDeployments: (triggerHistory: DeploymentHistoryConfigDiffProps["triggerHistory"]) => History[];
4
+ export declare const getPipelineDeploymentsWfrIds: ({ pipelineDeployments, wfrId, }: {
5
+ pipelineDeployments: History[];
6
+ } & Pick<DeploymentHistoryConfigDiffProps, "wfrId">) => {
7
+ currentWfrId: number;
8
+ previousWfrId: number;
9
+ };
10
+ export declare const getPipelineDeploymentsOptions: (pipelineDeployments: History[], wfrId: number) => {
11
+ currentDeployment: string;
12
+ pipelineDeploymentsOptions: {
13
+ value: number;
14
+ label: string;
15
+ description: string;
16
+ startIcon: JSX.Element;
17
+ }[];
18
+ };
19
+ export declare const parseDeploymentHistoryDiffSearchParams: (compareWfrId: number) => (searchParams: URLSearchParams) => {
20
+ compareWfrId: number;
21
+ };
@@ -1,4 +1,57 @@
1
+ import { IWithShortcut } from 'react-keybind';
1
2
  import { GitChangesType, LogResizeButtonType, ScrollerType } from './types';
2
- export declare const LogResizeButton: ({ fullScreenView, setFullScreenView }: LogResizeButtonType) => JSX.Element;
3
+ export declare const LogResizeButton: {
4
+ new (props: Readonly<LogResizeButtonType & IWithShortcut>): {
5
+ render(): JSX.Element;
6
+ context: any;
7
+ setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<LogResizeButtonType & IWithShortcut>) => {} | Pick<{}, K>) | Pick<{}, K>, callback?: (() => void) | undefined): void;
8
+ forceUpdate(callback?: (() => void) | undefined): void;
9
+ readonly props: Readonly<LogResizeButtonType & IWithShortcut> & Readonly<{
10
+ children?: import('react').ReactNode;
11
+ }>;
12
+ state: Readonly<{}>;
13
+ refs: {
14
+ [key: string]: import('react').ReactInstance;
15
+ };
16
+ componentDidMount?(): void;
17
+ shouldComponentUpdate?(nextProps: Readonly<LogResizeButtonType & IWithShortcut>, nextState: Readonly<{}>, nextContext: any): boolean;
18
+ componentWillUnmount?(): void;
19
+ componentDidCatch?(error: Error, errorInfo: import('react').ErrorInfo): void;
20
+ getSnapshotBeforeUpdate?(prevProps: Readonly<LogResizeButtonType & IWithShortcut>, prevState: Readonly<{}>): any;
21
+ componentDidUpdate?(prevProps: Readonly<LogResizeButtonType & IWithShortcut>, prevState: Readonly<{}>, snapshot?: any): void;
22
+ componentWillMount?(): void;
23
+ UNSAFE_componentWillMount?(): void;
24
+ componentWillReceiveProps?(nextProps: Readonly<LogResizeButtonType & IWithShortcut>, nextContext: any): void;
25
+ UNSAFE_componentWillReceiveProps?(nextProps: Readonly<LogResizeButtonType & IWithShortcut>, nextContext: any): void;
26
+ componentWillUpdate?(nextProps: Readonly<LogResizeButtonType & IWithShortcut>, nextState: Readonly<{}>, nextContext: any): void;
27
+ UNSAFE_componentWillUpdate?(nextProps: Readonly<LogResizeButtonType & IWithShortcut>, nextState: Readonly<{}>, nextContext: any): void;
28
+ };
29
+ new (props: LogResizeButtonType & IWithShortcut, context?: any): {
30
+ render(): JSX.Element;
31
+ context: any;
32
+ setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<LogResizeButtonType & IWithShortcut>) => {} | Pick<{}, K>) | Pick<{}, K>, callback?: (() => void) | undefined): void;
33
+ forceUpdate(callback?: (() => void) | undefined): void;
34
+ readonly props: Readonly<LogResizeButtonType & IWithShortcut> & Readonly<{
35
+ children?: import('react').ReactNode;
36
+ }>;
37
+ state: Readonly<{}>;
38
+ refs: {
39
+ [key: string]: import('react').ReactInstance;
40
+ };
41
+ componentDidMount?(): void;
42
+ shouldComponentUpdate?(nextProps: Readonly<LogResizeButtonType & IWithShortcut>, nextState: Readonly<{}>, nextContext: any): boolean;
43
+ componentWillUnmount?(): void;
44
+ componentDidCatch?(error: Error, errorInfo: import('react').ErrorInfo): void;
45
+ getSnapshotBeforeUpdate?(prevProps: Readonly<LogResizeButtonType & IWithShortcut>, prevState: Readonly<{}>): any;
46
+ componentDidUpdate?(prevProps: Readonly<LogResizeButtonType & IWithShortcut>, prevState: Readonly<{}>, snapshot?: any): void;
47
+ componentWillMount?(): void;
48
+ UNSAFE_componentWillMount?(): void;
49
+ componentWillReceiveProps?(nextProps: Readonly<LogResizeButtonType & IWithShortcut>, nextContext: any): void;
50
+ UNSAFE_componentWillReceiveProps?(nextProps: Readonly<LogResizeButtonType & IWithShortcut>, nextContext: any): void;
51
+ componentWillUpdate?(nextProps: Readonly<LogResizeButtonType & IWithShortcut>, nextState: Readonly<{}>, nextContext: any): void;
52
+ UNSAFE_componentWillUpdate?(nextProps: Readonly<LogResizeButtonType & IWithShortcut>, nextState: Readonly<{}>, nextContext: any): void;
53
+ };
54
+ contextType?: import('react').Context<any> | undefined;
55
+ };
3
56
  export declare const Scroller: ({ scrollToTop, scrollToBottom, style }: ScrollerType) => JSX.Element;
4
57
  export declare const GitChanges: ({ gitTriggers, ciMaterials, artifact, userApprovalMetadata, triggeredByEmail, ciPipelineId, artifactId, imageComment, imageReleaseTags, appReleaseTagNames, tagsEditable, hideImageTaggingHardDelete, appliedFilters, appliedFiltersTimestamp, promotionApprovalMetadata, selectedEnvironmentName, renderCIListHeader, }: GitChangesType) => JSX.Element;
@@ -1,3 +1,56 @@
1
+ import { IWithShortcut } from 'react-keybind';
1
2
  import { LogsRendererType } from './types';
2
- export declare const LogsRenderer: ({ triggerDetails, isBlobStorageConfigured, parentType, fullScreenView, }: LogsRendererType) => JSX.Element;
3
- export default LogsRenderer;
3
+ declare const _default: {
4
+ new (props: Readonly<LogsRendererType & IWithShortcut>): {
5
+ render(): JSX.Element;
6
+ context: any;
7
+ setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<LogsRendererType & IWithShortcut>) => {} | Pick<{}, K>) | Pick<{}, K>, callback?: (() => void) | undefined): void;
8
+ forceUpdate(callback?: (() => void) | undefined): void;
9
+ readonly props: Readonly<LogsRendererType & IWithShortcut> & Readonly<{
10
+ children?: import('react').ReactNode;
11
+ }>;
12
+ state: Readonly<{}>;
13
+ refs: {
14
+ [key: string]: import('react').ReactInstance;
15
+ };
16
+ componentDidMount?(): void;
17
+ shouldComponentUpdate?(nextProps: Readonly<LogsRendererType & IWithShortcut>, nextState: Readonly<{}>, nextContext: any): boolean;
18
+ componentWillUnmount?(): void;
19
+ componentDidCatch?(error: Error, errorInfo: import('react').ErrorInfo): void;
20
+ getSnapshotBeforeUpdate?(prevProps: Readonly<LogsRendererType & IWithShortcut>, prevState: Readonly<{}>): any;
21
+ componentDidUpdate?(prevProps: Readonly<LogsRendererType & IWithShortcut>, prevState: Readonly<{}>, snapshot?: any): void;
22
+ componentWillMount?(): void;
23
+ UNSAFE_componentWillMount?(): void;
24
+ componentWillReceiveProps?(nextProps: Readonly<LogsRendererType & IWithShortcut>, nextContext: any): void;
25
+ UNSAFE_componentWillReceiveProps?(nextProps: Readonly<LogsRendererType & IWithShortcut>, nextContext: any): void;
26
+ componentWillUpdate?(nextProps: Readonly<LogsRendererType & IWithShortcut>, nextState: Readonly<{}>, nextContext: any): void;
27
+ UNSAFE_componentWillUpdate?(nextProps: Readonly<LogsRendererType & IWithShortcut>, nextState: Readonly<{}>, nextContext: any): void;
28
+ };
29
+ new (props: LogsRendererType & IWithShortcut, context?: any): {
30
+ render(): JSX.Element;
31
+ context: any;
32
+ setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<LogsRendererType & IWithShortcut>) => {} | Pick<{}, K>) | Pick<{}, K>, callback?: (() => void) | undefined): void;
33
+ forceUpdate(callback?: (() => void) | undefined): void;
34
+ readonly props: Readonly<LogsRendererType & IWithShortcut> & Readonly<{
35
+ children?: import('react').ReactNode;
36
+ }>;
37
+ state: Readonly<{}>;
38
+ refs: {
39
+ [key: string]: import('react').ReactInstance;
40
+ };
41
+ componentDidMount?(): void;
42
+ shouldComponentUpdate?(nextProps: Readonly<LogsRendererType & IWithShortcut>, nextState: Readonly<{}>, nextContext: any): boolean;
43
+ componentWillUnmount?(): void;
44
+ componentDidCatch?(error: Error, errorInfo: import('react').ErrorInfo): void;
45
+ getSnapshotBeforeUpdate?(prevProps: Readonly<LogsRendererType & IWithShortcut>, prevState: Readonly<{}>): any;
46
+ componentDidUpdate?(prevProps: Readonly<LogsRendererType & IWithShortcut>, prevState: Readonly<{}>, snapshot?: any): void;
47
+ componentWillMount?(): void;
48
+ UNSAFE_componentWillMount?(): void;
49
+ componentWillReceiveProps?(nextProps: Readonly<LogsRendererType & IWithShortcut>, nextContext: any): void;
50
+ UNSAFE_componentWillReceiveProps?(nextProps: Readonly<LogsRendererType & IWithShortcut>, nextContext: any): void;
51
+ componentWillUpdate?(nextProps: Readonly<LogsRendererType & IWithShortcut>, nextState: Readonly<{}>, nextContext: any): void;
52
+ UNSAFE_componentWillUpdate?(nextProps: Readonly<LogsRendererType & IWithShortcut>, nextState: Readonly<{}>, nextContext: any): void;
53
+ };
54
+ contextType?: import('react').Context<any> | undefined;
55
+ };
56
+ export default _default;
@@ -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, setDeploymentHistoryList, deploymentHistoryList, deploymentAppType, isBlobStorageConfigured, appReleaseTags, tagsEditable, hideImageTaggingHardDelete, fetchIdData, setFetchTriggerIdData, selectedEnvironmentName, deploymentHistoryResult, renderRunSource, renderCIListHeader, renderDeploymentApprovalInfo, processVirtualEnvironmentDeploymentData, renderVirtualHistoryArtifacts, renderDeploymentHistoryTriggerMetaText, resourceId, scrollToTop, scrollToBottom, renderTargetConfigInfo, }: TriggerOutputProps) => 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;
5
5
  export default TriggerOutput;
@@ -10,7 +10,7 @@ export * from './service';
10
10
  export * from './History.components';
11
11
  export * from './utils';
12
12
  export * from './TriggerOutput';
13
- export * from './LogsRenderer';
14
- export * from './DeploymentHistoryDiff';
13
+ export { default as LogsRenderer } from './LogsRenderer';
14
+ export * from './DeploymentHistoryConfigDiff';
15
15
  export * from './CiPipelineSourceConfig';
16
16
  export * from './StatusFilterButtonComponent';
@@ -1,5 +1,5 @@
1
1
  import { CSSProperties, ReactElement } from 'react';
2
- import { OptionType, UserApprovalMetadataType, ReleaseTag, ImageComment, PromotionApprovalMetadataType, FilterConditionsListType, DeploymentAppTypes, ResponseType, PaginationProps, useScrollable, SortingOrder } from '../../../Common';
2
+ import { OptionType, UserApprovalMetadataType, ReleaseTag, ImageComment, PromotionApprovalMetadataType, FilterConditionsListType, DeploymentAppTypes, ResponseType, PaginationProps, useScrollable, SortingOrder, SupportedKeyboardKeysType } from '../../../Common';
3
3
  import { DeploymentStageType } from '../../constants';
4
4
  import { AggregationKeys, GitTriggers, Node, NodeType, ResourceKindType, ResourceVersionType } from '../../types';
5
5
  export declare enum HistoryComponentType {
@@ -14,6 +14,16 @@ export declare enum FetchIdDataStatus {
14
14
  SUSPEND = "SUSPEND"
15
15
  }
16
16
  export interface LogResizeButtonType {
17
+ /**
18
+ * If given, that shortcut combo will be bound to the button
19
+ * @default null
20
+ */
21
+ shortcutCombo?: SupportedKeyboardKeysType[];
22
+ /**
23
+ * If true, only show the button when location.pathname contains '/logs'
24
+ * @default true
25
+ */
26
+ showOnlyWhenPathIncludesLogs?: boolean;
17
27
  fullScreenView: boolean;
18
28
  setFullScreenView: React.Dispatch<React.SetStateAction<boolean>>;
19
29
  }
@@ -312,14 +322,13 @@ export interface TriggerOutputProps extends RenderRunSourceType, Pick<TriggerDet
312
322
  fullScreenView: boolean;
313
323
  triggerHistory: Map<number, History>;
314
324
  setFullScreenView: React.Dispatch<React.SetStateAction<boolean>>;
315
- deploymentHistoryList: DeploymentTemplateList[];
316
- setDeploymentHistoryList: React.Dispatch<React.SetStateAction<DeploymentTemplateList[]>>;
317
325
  deploymentAppType: DeploymentAppTypes;
318
326
  isBlobStorageConfigured: boolean;
319
327
  appReleaseTags: string[];
320
328
  tagsEditable: boolean;
321
329
  hideImageTaggingHardDelete: boolean;
322
330
  fetchIdData: FetchIdDataStatus;
331
+ appName: string;
323
332
  selectedEnvironmentName?: string;
324
333
  renderCIListHeader?: (renderCIListHeaderProps: RenderCIListHeaderProps) => JSX.Element;
325
334
  renderDeploymentApprovalInfo?: (userApprovalMetadata: UserApprovalMetadataType) => JSX.Element;
@@ -333,7 +342,7 @@ export interface TriggerOutputProps extends RenderRunSourceType, Pick<TriggerDet
333
342
  scrollToTop: ReturnType<typeof useScrollable>[1];
334
343
  scrollToBottom: ReturnType<typeof useScrollable>[2];
335
344
  }
336
- export interface HistoryLogsProps extends Pick<TriggerOutputProps, 'scrollToTop' | 'scrollToBottom' | 'setFullScreenView' | 'deploymentHistoryList' | 'setDeploymentHistoryList' | 'deploymentAppType' | 'isBlobStorageConfigured' | 'appReleaseTags' | 'tagsEditable' | 'hideImageTaggingHardDelete' | 'selectedEnvironmentName' | 'processVirtualEnvironmentDeploymentData' | 'renderDeploymentApprovalInfo' | 'renderCIListHeader' | 'renderVirtualHistoryArtifacts' | 'fullScreenView'> {
345
+ export interface HistoryLogsProps extends Pick<TriggerOutputProps, 'scrollToTop' | 'scrollToBottom' | 'setFullScreenView' | 'deploymentAppType' | 'isBlobStorageConfigured' | 'appReleaseTags' | 'tagsEditable' | 'hideImageTaggingHardDelete' | 'selectedEnvironmentName' | 'processVirtualEnvironmentDeploymentData' | 'renderDeploymentApprovalInfo' | 'renderCIListHeader' | 'renderVirtualHistoryArtifacts' | 'fullScreenView' | 'appName' | 'triggerHistory'> {
337
346
  triggerDetails: History;
338
347
  loading: boolean;
339
348
  userApprovalMetadata: UserApprovalMetadataType;
@@ -383,7 +392,6 @@ export interface DeploymentTemplateHistoryType {
383
392
  isUnpublished?: boolean;
384
393
  isDeleteDraft?: boolean;
385
394
  rootClassName?: string;
386
- comparisonBodyClassName?: string;
387
395
  sortOrder?: SortingOrder;
388
396
  }
389
397
  export interface DeploymentHistoryDetailRes extends ResponseType {
@@ -1,2 +1,2 @@
1
1
  import { DeploymentConfigDiffProps } from './DeploymentConfigDiff.types';
2
- export declare const DeploymentConfigDiff: ({ isLoading, configList, collapsibleNavList, navList, goBackURL, navHeading, navHelpText, tabConfig, ...resProps }: DeploymentConfigDiffProps) => JSX.Element;
2
+ export declare const DeploymentConfigDiff: ({ isLoading, configList, collapsibleNavList, navList, goBackURL, navHeading, navHelpText, tabConfig, showDetailedDiffState, renderedInDrawer, ...resProps }: DeploymentConfigDiffProps) => JSX.Element;
@@ -4,6 +4,12 @@ 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
+ }
7
13
  export interface DeploymentConfigType {
8
14
  list: DeploymentHistoryDetail;
9
15
  heading: React.ReactNode;
@@ -13,8 +19,9 @@ export interface DeploymentConfigListItem {
13
19
  title: string;
14
20
  primaryConfig: DeploymentConfigType;
15
21
  secondaryConfig: DeploymentConfigType;
16
- hasDiff?: boolean;
17
- isDeploymentTemplate?: boolean;
22
+ diffState: DeploymentConfigDiffState;
23
+ singleView?: boolean;
24
+ groupHeader?: string;
18
25
  }
19
26
  export type DeploymentConfigDiffSelectPickerProps = {
20
27
  type: 'string';
@@ -28,7 +35,7 @@ export type DeploymentConfigDiffSelectPickerProps = {
28
35
  selectPickerProps: SelectPickerProps;
29
36
  };
30
37
  export interface DeploymentConfigDiffNavigationItem extends Pick<CollapsibleListItem, 'href' | 'title' | 'onClick'> {
31
- hasDiff?: boolean;
38
+ diffState: DeploymentConfigListItem['diffState'];
32
39
  }
33
40
  export interface DeploymentConfigDiffNavigationCollapsibleItem extends Pick<CollapsibleListConfig, 'id' | 'header' | 'noItemsText'> {
34
41
  items: DeploymentConfigDiffNavigationItem[];
@@ -41,11 +48,13 @@ export interface DeploymentConfigDiffProps {
41
48
  reload: () => void;
42
49
  };
43
50
  configList: DeploymentConfigListItem[];
51
+ showDetailedDiffState?: boolean;
44
52
  headerText?: string;
45
53
  scrollIntoViewId?: string;
46
54
  selectorsConfig: {
47
55
  primaryConfig: DeploymentConfigDiffSelectPickerProps[];
48
56
  secondaryConfig: DeploymentConfigDiffSelectPickerProps[];
57
+ hideDivider?: boolean;
49
58
  };
50
59
  sortingConfig?: {
51
60
  sortBy: string;
@@ -62,29 +71,35 @@ export interface DeploymentConfigDiffProps {
62
71
  activeTab: string;
63
72
  onClick: (tab: string) => void;
64
73
  };
74
+ scopeVariablesConfig?: {
75
+ convertVariables: boolean;
76
+ onConvertVariablesClick: () => void;
77
+ };
78
+ renderedInDrawer?: boolean;
65
79
  }
66
- export interface DeploymentConfigDiffNavigationProps extends Pick<DeploymentConfigDiffProps, 'isLoading' | 'navList' | 'collapsibleNavList' | 'goBackURL' | 'navHeading' | 'navHelpText' | 'tabConfig'> {
80
+ export interface DeploymentConfigDiffNavigationProps extends Pick<DeploymentConfigDiffProps, 'isLoading' | 'navList' | 'collapsibleNavList' | 'goBackURL' | 'navHeading' | 'navHelpText' | 'tabConfig' | 'showDetailedDiffState'> {
67
81
  }
68
- export interface DeploymentConfigDiffMainProps extends Pick<DeploymentConfigDiffProps, 'isLoading' | 'errorConfig' | 'headerText' | 'configList' | 'scrollIntoViewId' | 'selectorsConfig' | 'sortingConfig'> {
82
+ export interface DeploymentConfigDiffMainProps extends Pick<DeploymentConfigDiffProps, 'isLoading' | 'errorConfig' | 'headerText' | 'configList' | 'scrollIntoViewId' | 'selectorsConfig' | 'sortingConfig' | 'scopeVariablesConfig' | 'showDetailedDiffState'> {
69
83
  }
70
- export interface DeploymentConfigDiffAccordionProps extends Pick<CollapseProps, 'onTransitionEnd'> {
84
+ export type DeploymentConfigDiffAccordionProps = Pick<CollapseProps, 'onTransitionEnd'> & Pick<DeploymentConfigDiffProps, 'showDetailedDiffState'> & {
71
85
  id: string;
72
86
  title: string;
73
87
  children: React.ReactNode;
74
- hasDiff?: boolean;
88
+ diffState: DeploymentConfigDiffState;
75
89
  isExpanded?: boolean;
76
90
  onClick?: (e: React.MouseEvent<HTMLButtonElement>) => void;
77
- }
91
+ };
78
92
  export type DiffHeadingDataType<DeploymentTemplate> = DeploymentTemplate extends true ? DeploymentTemplateDTO : ConfigMapSecretDataConfigDatumDTO;
79
93
  export type AppEnvDeploymentConfigListParams<IsManifestView> = (IsManifestView extends true ? {
80
94
  currentList: ManifestTemplateDTO;
81
95
  compareList: ManifestTemplateDTO;
82
- sortOrder?: never;
83
96
  } : {
84
97
  currentList: AppEnvDeploymentConfigDTO;
85
98
  compareList: AppEnvDeploymentConfigDTO;
86
- sortOrder?: SortingOrder;
87
99
  }) & {
88
100
  getNavItemHref: (resourceType: EnvResourceType, resourceName: string) => string;
89
101
  isManifestView?: IsManifestView;
102
+ convertVariables?: boolean;
103
+ currentDeploymentTemplateResolvedData?: AppEnvDeploymentConfigDTO;
104
+ compareDeploymentTemplateResolvedData?: AppEnvDeploymentConfigDTO;
90
105
  };
@@ -1,5 +1,7 @@
1
- import { AppEnvDeploymentConfigListParams, DeploymentConfigDiffProps } from '..';
2
- import { ConfigMapSecretDataConfigDatumDTO, TemplateListDTO } from '../../Services/app.types';
1
+ import { FunctionComponent, SVGProps } from 'react';
2
+ import { AppEnvDeploymentConfigListParams, DeploymentConfigDiffProps, DeploymentConfigDiffState } from '..';
3
+ import { ConfigMapSecretDataConfigDatumDTO, DeploymentTemplateDTO, TemplateListDTO } from '../../Services/app.types';
4
+ export declare const getDeploymentTemplateData: (data: DeploymentTemplateDTO) => any;
3
5
  /**
4
6
  * Retrieves the draft data from the given configuration data object.
5
7
  *
@@ -27,12 +29,17 @@ export declare const mergeConfigDataArraysByName: (primaryArray: ConfigMapSecret
27
29
  *
28
30
  * @returns An object containing the combined deployment configuration list, a collapsible navigation list, and a navigation list.
29
31
  */
30
- export declare const getAppEnvDeploymentConfigList: <ManifestView extends boolean = false>({ currentList, compareList, getNavItemHref, isManifestView, sortOrder, }: AppEnvDeploymentConfigListParams<ManifestView>) => {
32
+ export declare const getAppEnvDeploymentConfigList: <ManifestView extends boolean = false>({ currentList, compareList, getNavItemHref, isManifestView, convertVariables, currentDeploymentTemplateResolvedData, compareDeploymentTemplateResolvedData, }: AppEnvDeploymentConfigListParams<ManifestView>) => {
31
33
  configList: DeploymentConfigDiffProps["configList"];
32
34
  navList: DeploymentConfigDiffProps["navList"];
33
35
  collapsibleNavList: DeploymentConfigDiffProps["collapsibleNavList"];
34
36
  };
37
+ export declare const getDeploymentTemplateValues: (deploymentTemplate: DeploymentTemplateDTO) => string;
35
38
  export declare const getDefaultVersionAndPreviousDeploymentOptions: (data: TemplateListDTO[]) => {
36
39
  previousDeployments: TemplateListDTO[];
37
40
  defaultVersions: TemplateListDTO[];
38
41
  };
42
+ export declare const diffStateTextMap: Record<DeploymentConfigDiffState, string>;
43
+ export declare const diffStateIconMap: Record<DeploymentConfigDiffState, FunctionComponent<SVGProps<SVGSVGElement>>>;
44
+ export declare const diffStateTooltipTextMap: Record<DeploymentConfigDiffState, string>;
45
+ export declare const diffStateTextColorMap: Record<DeploymentConfigDiffState, `c${string}`>;
@@ -1,2 +1,9 @@
1
- import { DeploymentConfigDiffAccordionProps } from './DeploymentConfigDiff.types';
2
- export declare const DeploymentConfigDiffAccordion: import('react').ForwardRefExoticComponent<DeploymentConfigDiffAccordionProps & import('react').RefAttributes<HTMLDivElement>>;
1
+ import { DeploymentConfigDiffState } from './DeploymentConfigDiff.types';
2
+ export declare const DeploymentConfigDiffAccordion: import('react').ForwardRefExoticComponent<Pick<import('../Collapse').CollapseProps, "onTransitionEnd"> & Pick<import('./DeploymentConfigDiff.types').DeploymentConfigDiffProps, "showDetailedDiffState"> & {
3
+ id: string;
4
+ title: string;
5
+ children: React.ReactNode;
6
+ diffState: DeploymentConfigDiffState;
7
+ isExpanded?: boolean;
8
+ onClick?: (e: React.MouseEvent<HTMLButtonElement>) => void;
9
+ } & 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, }: DeploymentConfigDiffMainProps) => JSX.Element;
2
+ export declare const DeploymentConfigDiffMain: ({ isLoading, errorConfig, headerText, configList, selectorsConfig, sortingConfig, scrollIntoViewId, scopeVariablesConfig, showDetailedDiffState, }: 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, tabConfig, }: DeploymentConfigDiffNavigationProps) => JSX.Element;
2
+ export declare const DeploymentConfigDiffNavigation: ({ isLoading, collapsibleNavList, navList, goBackURL, navHeading, navHelpText, tabConfig, showDetailedDiffState, }: DeploymentConfigDiffNavigationProps) => JSX.Element;
@@ -4,6 +4,7 @@ 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 { TippyProps } from '@tippyjs/react';
7
8
  export interface SelectPickerOptionType<OptionValue = string | number> extends OptionType<OptionValue, ReactNode> {
8
9
  /**
9
10
  * Description to be displayed for the option
@@ -17,6 +18,10 @@ export interface SelectPickerOptionType<OptionValue = string | number> extends O
17
18
  * Icon at the end of the option
18
19
  */
19
20
  endIcon?: ReactElement;
21
+ /**
22
+ * Props passed to show the tippy on option
23
+ */
24
+ tooltipProps?: TippyProps;
20
25
  }
21
26
  type SelectProps<OptionValue, IsMulti extends boolean> = ReactSelectProps<SelectPickerOptionType<OptionValue>, IsMulti, GroupBase<SelectPickerOptionType<OptionValue>>>;
22
27
  declare module 'react-select/base' {
@@ -50,4 +50,17 @@ 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[]>;
53
66
  export {};
@@ -5,4 +5,10 @@ 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: AppEnvDeploymentConfigPayloadType, signal?: AbortSignal) => Promise<ResponseType<AppEnvDeploymentConfigDTO>>;
8
+ export declare const getAppEnvDeploymentConfig: ({ params, payload, signal, }: {
9
+ params: AppEnvDeploymentConfigPayloadType;
10
+ payload?: {
11
+ values: string;
12
+ };
13
+ signal?: AbortSignal;
14
+ }) => Promise<ResponseType<AppEnvDeploymentConfigDTO>>;