@devtron-labs/devtron-fe-common-lib 1.13.0-beta-7 → 1.13.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 (180) hide show
  1. package/dist/{@common-rjsf-CsUgIJpt.js → @code-editor-DfxVL5Vn.js} +17429 -16802
  2. package/dist/@common-rjsf-6fcCPJuJ.js +617 -0
  3. package/dist/{@framer-motion-CR14HVwJ.js → @framer-motion-DyOLEeMN.js} +1 -1
  4. package/dist/{@react-dates-z_WnuIha.js → @react-dates-B7d8RWU9.js} +14 -14
  5. package/dist/{@react-select-C1KOG39W.js → @react-select-Coo19Q6a.js} +1 -1
  6. package/dist/{@react-virtualized-sticky-tree-DE3LznCK.js → @react-virtualized-sticky-tree-BPjPJDIR.js} +1 -1
  7. package/dist/{@vendor-0Z6AwxJy.js → @vendor-D9q4wrnL.js} +45999 -45989
  8. package/dist/Common/Checkbox/Checkbox.d.ts +2 -0
  9. package/dist/Common/Checkbox/index.d.ts +1 -0
  10. package/dist/Common/Common.service.d.ts +2 -2
  11. package/dist/Common/Constants.d.ts +2 -2
  12. package/dist/Common/Drawer/index.d.ts +1 -0
  13. package/dist/Common/EmptyState/index.d.ts +2 -0
  14. package/dist/Common/Helper.d.ts +5 -1
  15. package/dist/Common/RJSF/Form.d.ts +1 -1
  16. package/dist/Common/Toggle/Toggle.d.ts +4 -1
  17. package/dist/Common/Types.d.ts +4 -2
  18. package/dist/Common/index.d.ts +2 -3
  19. package/dist/Pages/Applications/DevtronApps/Details/CDPipeline/services.d.ts +1 -1
  20. package/dist/Pages/Applications/DevtronApps/Details/CDPipeline/types.d.ts +1 -2
  21. package/dist/Pages/GlobalConfigurations/ClustersAndEnvironments/index.d.ts +1 -0
  22. package/dist/Pages/GlobalConfigurations/ClustersAndEnvironments/types.d.ts +8 -0
  23. package/dist/Pages/GlobalConfigurations/index.d.ts +1 -0
  24. package/dist/Pages/ResourceBrowser/service.d.ts +1 -1
  25. package/dist/Pages/ResourceBrowser/types.d.ts +38 -0
  26. package/dist/Shared/Components/ActionMenu/ActionMenu.component.d.ts +1 -2
  27. package/dist/Shared/Components/ActionMenu/ActionMenuItem.d.ts +2 -0
  28. package/dist/Shared/Components/ActionMenu/index.d.ts +2 -2
  29. package/dist/Shared/Components/ActionMenu/types.d.ts +88 -11
  30. package/dist/Shared/Components/ActionMenu/useActionMenu.hook.d.ts +275 -0
  31. package/dist/Shared/Components/ActionMenu/utils.d.ts +7 -0
  32. package/dist/Shared/Components/AppStatusModal/AppStatusBody.d.ts +2 -0
  33. package/dist/Shared/Components/AppStatusModal/AppStatusContent.d.ts +3 -0
  34. package/dist/Shared/Components/AppStatusModal/AppStatusModal.component.d.ts +3 -0
  35. package/dist/Shared/Components/AppStatusModal/AppStatusModalTabList.d.ts +3 -0
  36. package/dist/Shared/Components/AppStatusModal/constants.d.ts +4 -0
  37. package/dist/Shared/Components/AppStatusModal/index.d.ts +3 -0
  38. package/dist/Shared/Components/AppStatusModal/service.d.ts +4 -0
  39. package/dist/Shared/Components/AppStatusModal/types.d.ts +84 -0
  40. package/dist/Shared/Components/AppStatusModal/utils.d.ts +8 -0
  41. package/dist/Shared/Components/Button/types.d.ts +3 -1
  42. package/dist/Shared/Components/CICDHistory/DeploymentStatusBreakdown.d.ts +1 -1
  43. package/dist/Shared/Components/CICDHistory/DeploymentStatusDetailRow.d.ts +1 -1
  44. package/dist/Shared/Components/CICDHistory/LogStageAccordion.d.ts +1 -1
  45. package/dist/Shared/Components/CICDHistory/constants.d.ts +1 -0
  46. package/dist/Shared/Components/CICDHistory/index.d.ts +0 -1
  47. package/dist/Shared/Components/CICDHistory/service.d.ts +3 -0
  48. package/dist/Shared/Components/CICDHistory/types.d.ts +12 -77
  49. package/dist/Shared/Components/CICDHistory/utils.d.ts +7 -3
  50. package/dist/Shared/Components/DeploymentStatusBreakdown/constants.d.ts +10 -0
  51. package/dist/Shared/Components/DeploymentStatusBreakdown/index.d.ts +3 -0
  52. package/dist/Shared/Components/DeploymentStatusBreakdown/types.d.ts +22 -0
  53. package/dist/Shared/Components/DeploymentStatusBreakdown/utils.d.ts +20 -0
  54. package/dist/Shared/Components/Error/ErrorBar.d.ts +1 -1
  55. package/dist/Shared/Components/Error/types.d.ts +4 -0
  56. package/dist/Shared/Components/Error/utils.d.ts +1 -0
  57. package/dist/Shared/Components/FramerComponents/index.d.ts +2 -2
  58. package/dist/Shared/Components/Header/HeaderWithCreateButton/HeaderWithCreateButon.d.ts +1 -3
  59. package/dist/Shared/Components/Header/HeaderWithCreateButton/types.d.ts +10 -0
  60. package/dist/Shared/Components/Header/HeaderWithCreateButton/utils.d.ts +2 -0
  61. package/dist/Shared/Components/Header/HelpButton.d.ts +2 -0
  62. package/dist/Shared/Components/Header/PageHeader.d.ts +1 -1
  63. package/dist/Shared/Components/Header/constants.d.ts +5 -4
  64. package/dist/Shared/Components/Header/types.d.ts +15 -10
  65. package/dist/Shared/Components/Header/utils.d.ts +5 -1
  66. package/dist/Shared/Components/Icon/Icon.d.ts +35 -10
  67. package/dist/Shared/Components/Icon/IconBase.d.ts +1 -1
  68. package/dist/Shared/Components/Icon/types.d.ts +30 -8
  69. package/dist/Shared/Components/InfoBlock/constants.d.ts +2 -2
  70. package/dist/Shared/Components/InfoBlock/types.d.ts +2 -2
  71. package/dist/Shared/Components/InfoIconTippy/InfoIconTippy.d.ts +1 -1
  72. package/dist/Shared/Components/License/index.d.ts +1 -1
  73. package/dist/Shared/Components/License/utils.d.ts +2 -1
  74. package/dist/Shared/Components/LoginBanner/Testimonials.components.d.ts +3 -0
  75. package/dist/Shared/Components/LoginBanner/index.d.ts +2 -0
  76. package/dist/Shared/Components/Popover/Popover.component.d.ts +8 -0
  77. package/dist/Shared/Components/Popover/index.d.ts +3 -0
  78. package/dist/Shared/Components/Popover/types.d.ts +105 -0
  79. package/dist/Shared/Components/Popover/usePopover.hook.d.ts +2 -0
  80. package/dist/Shared/Components/Popover/utils.d.ts +92 -0
  81. package/dist/Shared/Components/Security/SecurityModal/utils.d.ts +1 -1
  82. package/dist/Shared/Components/SelectPicker/common.d.ts +2 -0
  83. package/dist/Shared/Components/SelectPicker/index.d.ts +1 -0
  84. package/dist/Shared/Components/SelectPicker/type.d.ts +4 -0
  85. package/dist/Shared/Components/StatusComponent/types.d.ts +2 -1
  86. package/dist/Shared/Components/Switch/Switch.component.d.ts +3 -0
  87. package/dist/Shared/Components/Switch/constants.d.ts +14 -0
  88. package/dist/Shared/Components/Switch/index.d.ts +3 -0
  89. package/dist/Shared/Components/Switch/types.d.ts +101 -0
  90. package/dist/Shared/Components/Switch/utils.d.ts +10 -0
  91. package/dist/Shared/Components/TabGroup/TabGroup.helpers.d.ts +1 -1
  92. package/dist/Shared/Components/TabGroup/TabGroup.types.d.ts +33 -7
  93. package/dist/Shared/Components/TargetPlatforms/TargetPlatformListTooltip.d.ts +1 -1
  94. package/dist/Shared/Components/TargetPlatforms/types.d.ts +1 -2
  95. package/dist/Shared/Components/index.d.ts +3 -3
  96. package/dist/Shared/Helpers.d.ts +2 -2
  97. package/dist/Shared/Providers/index.d.ts +1 -1
  98. package/dist/Shared/Providers/types.d.ts +11 -1
  99. package/dist/Shared/constants.d.ts +18 -24
  100. package/dist/Shared/types.d.ts +110 -4
  101. package/dist/assets/@code-editor.css +1 -0
  102. package/dist/assets/@common-rjsf.css +1 -1
  103. package/dist/assets/ic-amazon-eks.13404569.svg +5 -0
  104. package/dist/assets/ic-arrow-square-out.59bb549a.svg +3 -0
  105. package/dist/assets/ic-azure-aks.a9e437d5.svg +46 -0
  106. package/dist/assets/{ic-timeout-red.5eda1010.svg → ic-bulk-check.0f698efa.svg} +4 -4
  107. package/dist/assets/ic-bulk-check.99e92f7a.svg +21 -0
  108. package/dist/assets/{ic-magnifying-glass.cf47bce0.svg → ic-caret-down-small.7c4f88bf.svg} +1 -1
  109. package/dist/assets/ic-caret-right.0ff813c2.svg +3 -0
  110. package/dist/assets/ic-celebration.77350694.svg +238 -0
  111. package/dist/assets/ic-chat-circle-online.51348da5.svg +4 -0
  112. package/dist/assets/{ic-medal.a2e911f5.svg → ic-checkbox-hover.0151d832.svg} +4 -3
  113. package/dist/assets/{ic-k8s-job.f4414c10.svg → ic-checkbox-hover.93e8d66a.svg} +4 -3
  114. package/dist/assets/ic-checkbox-intermediate.24c6d21d.svg +22 -0
  115. package/dist/assets/ic-checkbox-intermediate.2a2d6c49.svg +22 -0
  116. package/dist/assets/ic-checkbox-selected.47444fab.svg +20 -0
  117. package/dist/assets/ic-checkbox-selected.c5539d6f.svg +20 -0
  118. package/dist/assets/{ic-check-grey.f556e371.svg → ic-checkbox-unselected.8054e3d7.svg} +2 -4
  119. package/dist/assets/ic-checkbox-unselected.ab91cdba.svg +19 -0
  120. package/dist/assets/ic-cloud-vms.27ea954e.svg +5 -0
  121. package/dist/assets/ic-cluster.71ba9e26.svg +3 -0
  122. package/dist/assets/ic-delete-dots.5380e0d0.svg +62 -0
  123. package/dist/assets/ic-disconnect.2ad261fc.svg +3 -0
  124. package/dist/assets/ic-discord-fill.103b579a.svg +3 -0
  125. package/dist/assets/ic-edit.3249ed32.svg +3 -0
  126. package/dist/assets/ic-enterprise-feat.5ee25d5b.svg +3 -0
  127. package/dist/assets/ic-enterprise-tag.209dd129.svg +43 -0
  128. package/dist/assets/ic-expand-right-sm.9b347d49.svg +3 -0
  129. package/dist/assets/ic-expand-sm.a9a724f8.svg +3 -0
  130. package/dist/assets/ic-file-edit.96a172c7.svg +3 -0
  131. package/dist/assets/ic-file.c3c45e13.svg +3 -0
  132. package/dist/assets/ic-files.b0ebea46.svg +3 -0
  133. package/dist/assets/ic-gift-gradient.7690a246.svg +9 -0
  134. package/dist/assets/ic-gift.9b048fc7.svg +3 -0
  135. package/dist/assets/ic-gitlab.ac331d67.svg +31 -0
  136. package/dist/assets/ic-google-gke.07314724.svg +9 -0
  137. package/dist/assets/ic-install.28c3beec.svg +3 -0
  138. package/dist/assets/ic-k3s.7f4bf72d.svg +3 -0
  139. package/dist/assets/ic-kind.bd8ee992.svg +9 -0
  140. package/dist/assets/ic-laptop.485e21b4.svg +3 -0
  141. package/dist/assets/ic-man-on-rocket.7f67e914.svg +94 -0
  142. package/dist/assets/ic-megaphone-left.6b2a00b7.svg +3 -0
  143. package/dist/assets/ic-megaphone-right.9d6bcd36.svg +3 -0
  144. package/dist/assets/ic-minikube.d9ff1575.svg +9 -0
  145. package/dist/assets/ic-mobile.7c649251.svg +4 -0
  146. package/dist/assets/ic-path.d4fef3b0.svg +3 -0
  147. package/dist/assets/ic-sparkle-color.01c0be88.svg +1 -0
  148. package/dist/assets/ic-ubuntu.fa47508f.svg +4 -0
  149. package/dist/assets/ic-user-circle.7d7152fa.svg +3 -0
  150. package/dist/assets/ic-wifi-slash.d0390749.svg +3 -0
  151. package/dist/index.d.ts +3 -0
  152. package/dist/index.js +883 -850
  153. package/package.json +1 -1
  154. package/dist/Common/Checkbox.d.ts +0 -5
  155. package/dist/Shared/Components/ActionMenu/ActionMenuOption.d.ts +0 -3
  156. package/dist/Shared/Components/AnnouncementBanner/AnnouncementBanner.d.ts +0 -6
  157. package/dist/Shared/Components/AnnouncementBanner/index.d.ts +0 -1
  158. package/dist/Shared/Components/CICDHistory/AppStatusDetailsChart.d.ts +0 -3
  159. package/dist/Shared/Components/CICDHistory/ErrorInfoStatusBar.d.ts +0 -2
  160. package/dist/Shared/Components/EnterpriseTag/EnterpriseTag.component.d.ts +0 -2
  161. package/dist/Shared/Components/EnterpriseTag/index.d.ts +0 -1
  162. package/dist/Shared/Components/Header/HelpNav.d.ts +0 -3
  163. package/dist/Shared/Components/LoadingCard.d.ts +0 -5
  164. package/dist/assets/ic-charts.f41e185f.svg +0 -19
  165. package/dist/assets/ic-chat-circle-dots.e15514f8.svg +0 -23
  166. package/dist/assets/ic-disconnected.551d6161.svg +0 -29
  167. package/dist/assets/ic-discord-fill.1a1b291d.svg +0 -19
  168. package/dist/assets/ic-fast-forward.8d1a414b.svg +0 -4
  169. package/dist/assets/ic-feedback.d32fa6b0.svg +0 -19
  170. package/dist/assets/ic-files.fc290dee.svg +0 -19
  171. package/dist/assets/ic-flask.d0624c30.svg +0 -3
  172. package/dist/assets/ic-lego.1d2c5e1d.svg +0 -3
  173. package/dist/assets/ic-login-devtron-logo.702a1d04.svg +0 -22
  174. package/dist/assets/ic-megaphone.b9f9a901.svg +0 -19
  175. package/dist/assets/ic-onboarding.c98f9ef9.svg +0 -19
  176. package/dist/assets/ic-play-outline.a4f09bf9.svg +0 -3
  177. package/dist/assets/ic-strategy-blue-green.0b348d03.svg +0 -6
  178. package/dist/assets/ic-strategy-canary.db010ee7.svg +0 -5
  179. package/dist/assets/ic-strategy-recreate.f0acddaa.svg +0 -4
  180. package/dist/assets/ic-strategy-rolling.1c356cdb.svg +0 -6
@@ -0,0 +1,92 @@
1
+ import { HTMLMotionProps } from 'framer-motion';
2
+ import { UsePopoverProps } from './types';
3
+ export declare const getPopoverAlignmentStyle: ({ position, alignment }: Pick<UsePopoverProps, "position" | "alignment">) => {
4
+ right: number;
5
+ left?: undefined;
6
+ bottom?: undefined;
7
+ top?: undefined;
8
+ } | {
9
+ left: string;
10
+ right?: undefined;
11
+ bottom?: undefined;
12
+ top?: undefined;
13
+ } | {
14
+ left: number;
15
+ right?: undefined;
16
+ bottom?: undefined;
17
+ top?: undefined;
18
+ } | {
19
+ bottom: number;
20
+ right?: undefined;
21
+ left?: undefined;
22
+ top?: undefined;
23
+ } | {
24
+ top: string;
25
+ right?: undefined;
26
+ left?: undefined;
27
+ bottom?: undefined;
28
+ } | {
29
+ top: number;
30
+ right?: undefined;
31
+ left?: undefined;
32
+ bottom?: undefined;
33
+ };
34
+ export declare const getPopoverPositionStyle: ({ position }: Pick<UsePopoverProps, "position">) => {
35
+ bottom: string;
36
+ marginBottom: number;
37
+ right?: undefined;
38
+ marginRight?: undefined;
39
+ left?: undefined;
40
+ marginLeft?: undefined;
41
+ top?: undefined;
42
+ marginTop?: undefined;
43
+ } | {
44
+ right: string;
45
+ marginRight: number;
46
+ bottom?: undefined;
47
+ marginBottom?: undefined;
48
+ left?: undefined;
49
+ marginLeft?: undefined;
50
+ top?: undefined;
51
+ marginTop?: undefined;
52
+ } | {
53
+ left: string;
54
+ marginLeft: number;
55
+ bottom?: undefined;
56
+ marginBottom?: undefined;
57
+ right?: undefined;
58
+ marginRight?: undefined;
59
+ top?: undefined;
60
+ marginTop?: undefined;
61
+ } | {
62
+ top: string;
63
+ marginTop: number;
64
+ bottom?: undefined;
65
+ marginBottom?: undefined;
66
+ right?: undefined;
67
+ marginRight?: undefined;
68
+ left?: undefined;
69
+ marginLeft?: undefined;
70
+ };
71
+ export declare const getPopoverFramerProps: ({ position, alignment }: Pick<UsePopoverProps, "position" | "alignment">) => {
72
+ initial: {
73
+ [x: string]: number;
74
+ opacity: number;
75
+ };
76
+ animate: {
77
+ [x: string]: number;
78
+ opacity: number;
79
+ };
80
+ exit: {
81
+ [x: string]: number;
82
+ opacity: number;
83
+ };
84
+ transformTemplate: HTMLMotionProps<"div">["transformTemplate"];
85
+ };
86
+ export declare const getPopoverActualPositionAlignment: ({ position, alignment, triggerRect, popoverRect, }: Pick<UsePopoverProps, "position" | "alignment"> & {
87
+ triggerRect: DOMRect;
88
+ popoverRect: DOMRect;
89
+ }) => {
90
+ fallbackPosition: "top" | "bottom" | "right" | "left";
91
+ fallbackAlignment: "start" | "middle" | "end";
92
+ };
@@ -1,7 +1,7 @@
1
1
  import { SEVERITIES } from './constants';
2
2
  import { GetResourceScanDetailsResponseType, ImageScanVulnerabilityType, ImageVulnerabilityType, ScanResultDTO, SeveritiesDTO, VulnerabilityCountType } from './types';
3
3
  export declare const mapSeveritiesToSegmentedBarChartEntities: (severities: Partial<Record<keyof typeof SEVERITIES, number>>) => {
4
- color: "var(--R500)" | "var(--N300)" | "var(--O500)" | "var(--G500)" | "var(--Y500)" | "var(--R700)";
4
+ color: "var(--R500)" | "var(--N300)" | "var(--O500)" | "var(--Y500)" | "var(--G500)" | "var(--R700)";
5
5
  label: "Unknown" | "Critical" | "High" | "Medium" | "Low" | "Failures" | "Successes" | "Exceptions";
6
6
  value: number;
7
7
  }[];
@@ -8,8 +8,10 @@ export declare const SelectPickerControl: <OptionValue>(props: ControlProps<Sele
8
8
  export declare const SelectPickerInput: <OptionValue>(props: InputProps<SelectPickerOptionType<OptionValue>>) => JSX.Element;
9
9
  export declare const SelectPickerValueContainer: <OptionValue, IsMulti extends boolean>({ showSelectedOptionsCount, customSelectedOptionsCount, ...props }: ValueContainerProps<SelectPickerOptionType<OptionValue>> & Pick<SelectPickerProps<OptionValue, IsMulti>, "showSelectedOptionsCount" | "customSelectedOptionsCount">) => JSX.Element;
10
10
  export declare const SelectPickerOption: <OptionValue, IsMulti extends boolean>({ disableDescriptionEllipsis, ...props }: OptionProps<SelectPickerOptionType<OptionValue>> & Pick<SelectPickerProps<OptionValue, IsMulti>, "disableDescriptionEllipsis">) => JSX.Element;
11
+ export declare const SelectPickerMenuListFooter: ({ menuListFooterConfig, }: Required<Pick<SelectPickerProps, "menuListFooterConfig">>) => JSX.Element;
11
12
  export declare const SelectPickerMenuList: <OptionValue>(props: MenuListProps<SelectPickerOptionType<OptionValue>>) => JSX.Element;
12
13
  export declare const SelectPickerMultiValueLabel: <OptionValue, IsMulti extends boolean>({ getIsOptionValid, ...props }: MultiValueProps<SelectPickerOptionType<OptionValue>, true> & Pick<SelectPickerProps<OptionValue, IsMulti>["multiSelectProps"], "getIsOptionValid">) => JSX.Element;
13
14
  export declare const SelectPickerMultiValueRemove: (props: MultiValueRemoveProps) => JSX.Element;
14
15
  export declare const SelectPickerGroupHeading: <OptionValue>({ isGroupHeadingSelectable, ...props }: SelectPickerGroupHeadingProps<OptionValue>) => JSX.Element;
15
16
  export declare const renderLoadingMessage: () => JSX.Element;
17
+ export declare const ValueContainerWithLoadingShimmer: (props: ValueContainerProps) => JSX.Element;
@@ -1,3 +1,4 @@
1
+ export { ValueContainerWithLoadingShimmer } from './common';
1
2
  export { default as FilterSelectPicker } from './FilterSelectPicker';
2
3
  export { default as SelectPicker } from './SelectPicker.component';
3
4
  export * from './SelectPickerTextArea.component';
@@ -40,6 +40,10 @@ type MenuListFooterConfigType = {
40
40
  buttonProps: {
41
41
  variant: ButtonVariantType.primary | ButtonVariantType.borderLess;
42
42
  } & Omit<ButtonProps<ButtonComponentType>, 'size' | 'fullWidth' | 'icon' | 'endIcon' | 'variant' | 'style'>;
43
+ } | {
44
+ type: 'customNode';
45
+ value: ReactElement;
46
+ buttonProps?: never;
43
47
  };
44
48
  declare module 'react-select/base' {
45
49
  interface Props<Option, IsMulti extends boolean, Group extends GroupBase<Option>> {
@@ -16,7 +16,8 @@ export declare enum StatusType {
16
16
  PROGRESSING = "PROGRESSING",
17
17
  INPROGRESS = "INPROGRESS",
18
18
  HIBERNATING = "HIBERNATING",
19
- TIMED_OUT = "TIMED_OUT"
19
+ TIMED_OUT = "TIMED_OUT",
20
+ DELETING = "DELETING"
20
21
  }
21
22
  export interface StatusComponentProps {
22
23
  /** The status to display, either a predefined StatusType or a custom string. */
@@ -0,0 +1,3 @@
1
+ import { SwitchProps } from './types';
2
+ declare const Switch: ({ ariaLabel, dataTestId, isDisabled, isLoading, isChecked, tooltipContent, shape, variant, iconColor, iconName, indeterminate, size, name, onChange, }: SwitchProps) => JSX.Element;
3
+ export default Switch;
@@ -0,0 +1,14 @@
1
+ import { IconBaseColorType } from '../../types';
2
+ import { SwitchProps } from './types';
3
+ export declare const SWITCH_VARIANTS: Readonly<Record<SwitchProps['variant'], null>>;
4
+ export declare const SWITCH_SHAPES: Readonly<Record<SwitchProps['shape'], null>>;
5
+ export declare const ROUNDED_SWITCH_SIZE_MAP: Readonly<Record<SwitchProps['size'], string>>;
6
+ export declare const SQUARE_SWITCH_SIZE_MAP: typeof ROUNDED_SWITCH_SIZE_MAP;
7
+ export declare const SWITCH_HEIGHT_MAP: Readonly<Record<SwitchProps['size'], string>>;
8
+ export declare const LOADING_COLOR_MAP: Record<SwitchProps['variant'], IconBaseColorType>;
9
+ export declare const ROUNDED_SWITCH_TRACK_COLOR_MAP: Record<SwitchProps['variant'], string>;
10
+ export declare const SQUARE_SWITCH_TRACK_COLOR_MAP: typeof ROUNDED_SWITCH_TRACK_COLOR_MAP;
11
+ export declare const ROUNDED_SWITCH_THUMB_SIZE_MAP: Record<SwitchProps['size'], string>;
12
+ export declare const INDETERMINATE_ICON_WIDTH_MAP: Record<SwitchProps['size'], string>;
13
+ export declare const SWITCH_THUMB_PADDING_MAP: Record<SwitchProps['size'], string>;
14
+ export declare const THUMB_OUTER_PADDING_MAP: Record<SwitchProps['shape'], string>;
@@ -0,0 +1,3 @@
1
+ export { SWITCH_SHAPES, SWITCH_VARIANTS } from './constants';
2
+ export { default as Switch } from './Switch.component';
3
+ export type { SwitchProps } from './types';
@@ -0,0 +1,101 @@
1
+ import { ComponentSizeType } from '../../constants';
2
+ import { IconBaseColorType } from '../../types';
3
+ import { IconName } from '../Icon';
4
+ /**
5
+ * Represents the properties for configuring the shape and behavior of a switch component.
6
+ *
7
+ * - When `shape` is `rounded`:
8
+ * - The switch will have a rounded appearance.
9
+ * - `iconName`, `iconColor`, and `indeterminate` are not applicable.
10
+ *
11
+ * - When `shape` is `square`:
12
+ * - The switch will have a square appearance.
13
+ * - `iconName` specifies the name of the icon to display.
14
+ * - `iconColor` allows customization of the icon's color in the active state.
15
+ * - `indeterminate` indicates whether the switch is in an indeterminate state, typically used for checkboxes to represent a mixed state.
16
+ * If `indeterminate` is true, the switch will not be fully checked or unchecked.
17
+ */
18
+ type SwitchShapeProps = {
19
+ /**
20
+ * The shape of the switch. Defaults to `rounded` if not specified.
21
+ */
22
+ shape?: 'rounded';
23
+ /**
24
+ * Icon name is not applicable for the `rounded` shape.
25
+ */
26
+ iconName?: never;
27
+ /**
28
+ * Icon color is not applicable for the `rounded` shape.
29
+ */
30
+ iconColor?: never;
31
+ /**
32
+ * Indicates whether the switch is in an indeterminate state.
33
+ * This state is typically used for checkboxes to indicate a mixed state.
34
+ * If true, the switch will not be fully checked or unchecked. Due this state alone we are keeping role as `checkbox` instead of `switch`.
35
+ * This property is not applicable for the `square` shape.
36
+ * @default false
37
+ */
38
+ indeterminate?: boolean;
39
+ } | {
40
+ /**
41
+ * The shape of the switch. Must be `square` to enable icon-related properties.
42
+ */
43
+ shape: 'square';
44
+ /**
45
+ * The name of the icon to display when the shape is `square`.
46
+ */
47
+ iconName: IconName;
48
+ /**
49
+ * The color of the icon. If provided, this will override the default color in the active state.
50
+ */
51
+ iconColor?: IconBaseColorType;
52
+ indeterminate?: never;
53
+ };
54
+ /**
55
+ * Represents the properties for the `Switch` component.
56
+ */
57
+ export type SwitchProps = {
58
+ /**
59
+ * The ARIA label for the switch, used for accessibility purposes.
60
+ */
61
+ ariaLabel: string;
62
+ /**
63
+ * Used in forms to identify the switch.
64
+ */
65
+ name: string;
66
+ /**
67
+ * A unique identifier for testing purposes.
68
+ */
69
+ dataTestId: string;
70
+ /**
71
+ * The visual variant of the switch.
72
+ *
73
+ * @default `positive`
74
+ */
75
+ variant?: 'theme' | 'positive';
76
+ /**
77
+ * The size of the switch.
78
+ * @default `ComponentSizeType.medium`
79
+ */
80
+ size?: Extract<ComponentSizeType, ComponentSizeType.medium | ComponentSizeType.small>;
81
+ onChange: () => void;
82
+ /**
83
+ * Indicates whether the switch is disabled.
84
+ */
85
+ isDisabled?: boolean;
86
+ /**
87
+ * Indicates whether the switch is in a loading state.
88
+ */
89
+ isLoading?: boolean;
90
+ /**
91
+ * Indicates whether the switch is currently checked (on).
92
+ */
93
+ isChecked: boolean;
94
+ /**
95
+ * Optional tooltip content to display when hovering over the switch.
96
+ *
97
+ * @default undefined
98
+ */
99
+ tooltipContent?: string;
100
+ } & SwitchShapeProps;
101
+ export {};
@@ -0,0 +1,10 @@
1
+ import { IconBaseColorType } from '../../types';
2
+ import { SwitchProps } from './types';
3
+ export declare const getSwitchContainerClass: ({ shape, size }: Required<Pick<SwitchProps, "shape" | "size">>) => string;
4
+ export declare const getSwitchTrackColor: ({ shape, variant, isChecked, isLoading, }: Required<Pick<SwitchProps, "shape" | "variant" | "isChecked" | "isLoading">>) => string;
5
+ export declare const getSwitchThumbClass: ({ shape, size, showIndeterminateIcon, }: Pick<SwitchProps, "shape" | "size"> & {
6
+ showIndeterminateIcon: boolean;
7
+ }) => string;
8
+ export declare const getSwitchIconColor: ({ iconColor, isChecked, variant, }: Pick<SwitchProps, "iconColor" | "isChecked" | "variant">) => IconBaseColorType;
9
+ export declare const getThumbPosition: ({ isLoading, isChecked, }: Pick<SwitchProps, "isLoading" | "isChecked">) => "left" | "right" | "center";
10
+ export declare const getThumbPadding: ({ shape, isLoading }: Pick<SwitchProps, "shape" | "isLoading">) => string;
@@ -1,5 +1,5 @@
1
1
  import { TabGroupProps, TabProps } from './TabGroup.types';
2
- export declare const getTabIcon: ({ icon, showError, showWarning, className, size, active, }: Pick<TabProps, "showError" | "showWarning" | "icon" | "active"> & Pick<TabGroupProps, "size"> & {
2
+ export declare const getTabIcon: ({ icon, showError, showWarning, className, size, active, iconElement, }: Pick<TabProps, "showError" | "showWarning" | "icon" | "active" | "iconElement"> & Pick<TabGroupProps, "size"> & {
3
3
  className: string;
4
4
  }) => JSX.Element;
5
5
  export declare const getTabBadge: (badge: TabProps["badge"], className: string) => JSX.Element;
@@ -65,6 +65,38 @@ type TabTooltipProps = {
65
65
  shouldWrapTooltip?: never;
66
66
  tooltipProps?: never;
67
67
  };
68
+ /**
69
+ * Represents the properties for defining an icon in a tab group.
70
+ * This type allows for three configurations:
71
+ *
72
+ * 1. **Icon as a functional component or string**:
73
+ * - Use the `icon` property to specify either a functional component that renders an SVG or a string representing the name of the icon.
74
+ * - The `iconElement` property must not be provided in this case.
75
+ *
76
+ * 2. **Icon as a JSX element**:
77
+ * - Use the `iconElement` property to specify a JSX element representing the icon.
78
+ * - The `icon` property must not be provided in this case.
79
+ *
80
+ * 3. **No icon**:
81
+ * - Neither `icon` nor `iconElement` is provided, resulting in no icon being displayed.
82
+ *
83
+ */
84
+ type TabGroupIconProp = {
85
+ /**
86
+ * A functional component rendering an SVG or a string representing the icon name. Mutually exclusive with `iconElement`.
87
+ */
88
+ icon: React.FunctionComponent<React.SVGProps<SVGSVGElement>> | IconName;
89
+ iconElement?: never;
90
+ } | {
91
+ icon?: never;
92
+ /**
93
+ * A JSX element representing the icon. Mutually exclusive with `icon`.
94
+ */
95
+ iconElement: JSX.Element;
96
+ } | {
97
+ icon?: never;
98
+ iconElement?: never;
99
+ };
68
100
  export type TabProps = {
69
101
  /**
70
102
  * Unique identifier for the tab.
@@ -79,12 +111,6 @@ export type TabProps = {
79
111
  * @note - If passed as a `string[]`, it will be rendered with a bullet in-between strings.
80
112
  */
81
113
  description?: string | string[];
82
- /**
83
- * Icon to be displayed in the tab.
84
- * This can either be a functional component that renders a SVG
85
- * or a string representing the name of the icon to be rendered by the Icon component.
86
- */
87
- icon?: React.FunctionComponent<React.SVGProps<SVGSVGElement>> | IconName;
88
114
  /**
89
115
  * Badge number to be displayed on the tab, typically for notifications.
90
116
  */
@@ -107,7 +133,7 @@ export type TabProps = {
107
133
  * Disables the tab, preventing interaction and indicating an inactive state.
108
134
  */
109
135
  disabled?: boolean;
110
- } & ConditionalTabType & TabTooltipProps;
136
+ } & ConditionalTabType & TabTooltipProps & TabGroupIconProp;
111
137
  export interface TabGroupProps {
112
138
  /**
113
139
  * Array of tabs to be rendered.
@@ -1,3 +1,3 @@
1
1
  import { TargetPlatformListTooltipProps } from './types';
2
- declare const TargetPlatformListTooltip: ({ targetPlatforms, children }: TargetPlatformListTooltipProps) => JSX.Element;
2
+ declare const TargetPlatformListTooltip: ({ targetPlatforms, children, appendTo }: TargetPlatformListTooltipProps) => JSX.Element;
3
3
  export default TargetPlatformListTooltip;
@@ -2,6 +2,5 @@ import { TooltipProps } from '@Common/Tooltip/types';
2
2
  import { TargetPlatformsDTO } from '../../types';
3
3
  export interface TargetPlatformBadgeListProps extends Required<Pick<TargetPlatformsDTO, 'targetPlatforms'>> {
4
4
  }
5
- export interface TargetPlatformListTooltipProps extends Pick<TargetPlatformsDTO, 'targetPlatforms'> {
6
- children: TooltipProps['children'];
5
+ export interface TargetPlatformListTooltipProps extends Pick<TargetPlatformsDTO, 'targetPlatforms'>, Pick<TooltipProps, 'children' | 'appendTo'> {
7
6
  }
@@ -3,8 +3,8 @@ export * from './ActionMenu';
3
3
  export * from './ActivityIndicator';
4
4
  export * from './AnimatedDeployButton';
5
5
  export * from './AnimatedTimer';
6
- export * from './AnnouncementBanner';
7
6
  export * from './APIResponseHandler';
7
+ export * from './AppStatusModal';
8
8
  export * from './ArtifactInfoModal';
9
9
  export * from './Backdrop';
10
10
  export * from './BulkOperations';
@@ -24,12 +24,12 @@ export * from './CountrySelect';
24
24
  export * from './CustomInput';
25
25
  export * from './DatePicker';
26
26
  export * from './DeploymentConfigDiff';
27
+ export * from './DeploymentStatusBreakdown';
27
28
  export * from './DetectBottom';
28
29
  export * from './DiffViewer';
29
30
  export * from './DynamicDataTable';
30
31
  export * from './EditableTextArea';
31
32
  export * from './EditImageFormField';
32
- export * from './EnterpriseTag';
33
33
  export * from './EnvironmentSelector';
34
34
  export * from './Error';
35
35
  export * from './ExcludedImageNode';
@@ -56,7 +56,6 @@ export * from './InfoIconTippy';
56
56
  export * from './InvalidYAMLTippy';
57
57
  export * from './KeyValueTable';
58
58
  export * from './License';
59
- export { default as LoadingCard } from './LoadingCard';
60
59
  export * from './LoginBanner';
61
60
  export * from './MaterialHistory';
62
61
  export * from './ModalSidebarPanel';
@@ -72,6 +71,7 @@ export * from './SelectPicker';
72
71
  export * from './ShowMoreText';
73
72
  export * from './SSOProviderIcon';
74
73
  export * from './StatusComponent';
74
+ export * from './Switch';
75
75
  export * from './TabGroup';
76
76
  export * from './Table';
77
77
  export * from './TagsKeyValueTable';
@@ -4,7 +4,7 @@ import { StrictRJSFSchema } from '@rjsf/utils';
4
4
  import { Pair } from 'yaml';
5
5
  import { MaterialHistoryType } from '@Shared/Services/app.types';
6
6
  import { ApprovalConfigDataType, MaterialInfo, SortingOrder, UserApprovalConfigType, UserApprovalInfo } from '../Common';
7
- import { AggregatedNodes, DeploymentStatusDetailsBreakdownDataType, DeploymentStatusDetailsType, PodMetadatum } from './Components';
7
+ import { AggregatedNodes, PodMetadatum } from './Components';
8
8
  import { BorderConfigType, GetTimeDifferenceParamsType, GitTriggers, IntersectionChangeHandler, IntersectionOptions, PreventOutsideFocusProps, TargetPlatformItemDTO, TargetPlatformsDTO, WebhookEventNameType } from './types';
9
9
  interface HighlightSearchTextProps {
10
10
  /**
@@ -36,7 +36,6 @@ export declare const isNullOrUndefined: (value: unknown) => boolean;
36
36
  export declare const handleDisableSubmitOnEnter: (event: React.KeyboardEvent<HTMLFormElement>) => void;
37
37
  export declare const getKeyToBooleanMapFromArray: <T extends string | number>(arr?: T[]) => Record<T, boolean>;
38
38
  export declare const renderValidInputButtonTippy: (children: ReactElement) => JSX.Element;
39
- export declare const processDeploymentStatusDetailsData: (data?: DeploymentStatusDetailsType) => DeploymentStatusDetailsBreakdownDataType;
40
39
  export declare function aggregateNodes(nodes: any[], podMetadata: PodMetadatum[]): AggregatedNodes;
41
40
  export declare const decode: (data: any, isEncoded?: boolean) => {};
42
41
  export declare const isTimeStringAvailable: (time: string) => boolean;
@@ -101,4 +100,5 @@ export declare const deriveBorderRadiusAndBorderClassFromConfig: ({ borderConfig
101
100
  }) => string;
102
101
  export declare const getClassNameForStickyHeaderWithShadow: (isStuck: boolean, topClassName?: string) => string;
103
102
  export declare const clearCookieOnLogout: () => void;
103
+ export declare const getAppDetailsURL: (appId: number | string, envId?: number | string) => string;
104
104
  export {};
@@ -1,5 +1,5 @@
1
1
  export * from './ImageSelectionUtility';
2
2
  export * from './MainContextProvider';
3
3
  export * from './ThemeProvider';
4
- export type { MainContext } from './types';
4
+ export type { MainContext, ReloadVersionConfigTypes } from './types';
5
5
  export * from './UserEmailProvider';
@@ -1,7 +1,16 @@
1
1
  import { Dispatch, MutableRefObject, ReactNode, SetStateAction } from 'react';
2
2
  import { SERVER_MODE } from '../../Common';
3
3
  import { ServerInfo } from '../Components/Header/types';
4
- import { DevtronLicenseInfo, IntelligenceConfig, LicenseInfoDialogType } from '..';
4
+ import { DevtronLicenseInfo, IntelligenceConfig, LicenseInfoDialogType, ToastManager } from '..';
5
+ export interface ReloadVersionConfigTypes {
6
+ bgUpdated: boolean;
7
+ handleAppUpdate: () => void;
8
+ doesNeedRefresh: boolean;
9
+ updateServiceWorker: () => Promise<void>;
10
+ handleControllerChange: () => void;
11
+ updateToastRef: MutableRefObject<ReturnType<typeof ToastManager.showToast>> | null;
12
+ isRefreshing: boolean;
13
+ }
5
14
  export interface MainContext {
6
15
  serverMode: SERVER_MODE;
7
16
  setServerMode: (serverMode: SERVER_MODE) => void;
@@ -46,6 +55,7 @@ export interface MainContext {
46
55
  licenseData: DevtronLicenseInfo;
47
56
  setLicenseData: Dispatch<SetStateAction<DevtronLicenseInfo>>;
48
57
  canFetchHelmAppStatus: boolean;
58
+ reloadVersionConfig: ReloadVersionConfigTypes;
49
59
  intelligenceConfig: IntelligenceConfig;
50
60
  setIntelligenceConfig: Dispatch<SetStateAction<IntelligenceConfig>>;
51
61
  }
@@ -1,5 +1,6 @@
1
- import { OptionType } from '../Common/Types';
2
- import { CDMaterialSidebarType, ConfigKeysWithLockType, ConfigurationType } from './types';
1
+ import { DeploymentNodeType, OptionType } from '../Common/Types';
2
+ import { InfoBlockProps } from './Components';
3
+ import { CDMaterialSidebarType, ConfigKeysWithLockType, ConfigurationType, IconBaseColorType } from './types';
3
4
  export declare const ARTIFACT_STATUS: {
4
5
  PROGRESSING: string;
5
6
  DEGRADED: string;
@@ -50,28 +51,6 @@ export declare enum EnvironmentTypeEnum {
50
51
  production = "Production",
51
52
  nonProduction = "Non-Production"
52
53
  }
53
- export declare enum TIMELINE_STATUS {
54
- DEPLOYMENT_INITIATED = "DEPLOYMENT_INITIATED",
55
- GIT_COMMIT = "GIT_COMMIT",
56
- GIT_COMMIT_FAILED = "GIT_COMMIT_FAILED",
57
- ARGOCD_SYNC = "ARGOCD_SYNC",
58
- ARGOCD_SYNC_FAILED = "ARGOCD_SYNC_FAILED",
59
- KUBECTL_APPLY = "KUBECTL_APPLY",
60
- KUBECTL_APPLY_STARTED = "KUBECTL_APPLY_STARTED",
61
- KUBECTL_APPLY_SYNCED = "KUBECTL_APPLY_SYNCED",
62
- HEALTHY = "HEALTHY",
63
- APP_HEALTH = "APP_HEALTH",
64
- DEPLOYMENT_FAILED = "FAILED",
65
- FETCH_TIMED_OUT = "TIMED_OUT",
66
- UNABLE_TO_FETCH_STATUS = "UNABLE_TO_FETCH_STATUS",
67
- DEGRADED = "DEGRADED",
68
- DEPLOYMENT_SUPERSEDED = "DEPLOYMENT_SUPERSEDED",
69
- ABORTED = "ABORTED",
70
- INPROGRESS = "INPROGRESS",
71
- HELM_PACKAGE_GENERATED = "HELM_PACKAGE_GENERATED",
72
- HELM_MANIFEST_PUSHED_TO_HELM_REPO = "HELM_MANIFEST_PUSHED_TO_HELM_REPO",
73
- HELM_MANIFEST_PUSHED_TO_HELM_REPO_FAILED = "HELM_MANIFEST_PUSHED_TO_HELM_REPO_FAILED"
74
- }
75
54
  /**
76
55
  * Constants for NO MATCHING result
77
56
  */
@@ -435,3 +414,18 @@ export declare const Routes: {
435
414
  };
436
415
  export declare const ENTERPRISE_SUPPORT_LINK = "enterprise@devtron.ai";
437
416
  export declare const INVALID_LICENSE_KEY = "inValid";
417
+ export declare enum InfoBlockVariant {
418
+ ERROR = "error",
419
+ HELP = "help",
420
+ INFORMATION = "information",
421
+ SUCCESS = "success",
422
+ WARNING = "warning",
423
+ NEUTRAL = "neutral"
424
+ }
425
+ export type InfoBlockVariantType = 'error' | 'help' | 'information' | 'success' | 'warning' | 'neutral';
426
+ export declare const VARIANT_TO_BG_MAP: Record<InfoBlockProps['variant'], string>;
427
+ export declare const VARIANT_TO_ICON_COLOR_MAP: Record<InfoBlockProps['variant'], IconBaseColorType>;
428
+ export declare const VARIANT_TO_BORDER_MAP: Record<InfoBlockProps['variant'], string>;
429
+ export declare const DEPLOYMENT_STAGE_TO_NODE_MAP: Readonly<Record<DeploymentStageType, DeploymentNodeType>>;
430
+ export declare const APP_DETAILS_FALLBACK_POLLING_INTERVAL = 30000;
431
+ export declare const PROGRESSING_DEPLOYMENT_STATUS_POLLING_INTERVAL = 10000;