@devtron-labs/devtron-fe-common-lib 0.0.86 → 0.0.87-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 (99) hide show
  1. package/dist/Common/AppStatus/constants.d.ts +0 -20
  2. package/dist/Common/AppStatus/index.d.ts +1 -0
  3. package/dist/Common/Constants.d.ts +19 -0
  4. package/dist/Common/Dialogs/Types.d.ts +17 -2
  5. package/dist/Common/EmptyState/GenericFilterEmptyState.d.ts +5 -2
  6. package/dist/Common/EmptyState/types.d.ts +13 -0
  7. package/dist/Common/Helper.d.ts +8 -0
  8. package/dist/Common/Hooks/useStateFilters/types.d.ts +1 -1
  9. package/dist/Common/Modals/Modal.d.ts +3 -0
  10. package/dist/Common/Modals/OpaqueModal.d.ts +3 -0
  11. package/dist/Common/Modals/VisibleModal.d.ts +2 -1
  12. package/dist/Common/Modals/VisibleModal2.d.ts +2 -1
  13. package/dist/Common/Pagination/index.d.ts +1 -0
  14. package/dist/Common/PopupMenu.d.ts +1 -1
  15. package/dist/Common/Types.d.ts +3 -1
  16. package/dist/Common/index.d.ts +1 -0
  17. package/dist/Shared/Components/CICDHistory/AppStatusDetailsChart.d.ts +4 -0
  18. package/dist/Shared/Components/CICDHistory/Artifacts.d.ts +5 -0
  19. package/dist/Shared/Components/CICDHistory/CDEmptyState.d.ts +14 -0
  20. package/dist/Shared/Components/CICDHistory/CiPipelineSourceConfig.d.ts +11 -0
  21. package/dist/Shared/Components/CICDHistory/DeploymentDetailSteps.d.ts +4 -0
  22. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/DeploymentHistoryConfigList.component.d.ts +4 -0
  23. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/DeploymentHistoryDetailedView.d.ts +4 -0
  24. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/DeploymentHistoryDiffView.d.ts +4 -0
  25. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/DeploymentHistoryHeader.d.ts +4 -0
  26. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/DeploymentHistorySidebar.d.ts +4 -0
  27. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/index.d.ts +3 -0
  28. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/types.d.ts +36 -0
  29. package/dist/Shared/Components/CICDHistory/DeploymentHistoryDiff/utils.d.ts +11 -0
  30. package/dist/Shared/Components/CICDHistory/DeploymentStatusBreakdown.d.ts +4 -0
  31. package/dist/Shared/Components/CICDHistory/DeploymentStatusDetailRow.d.ts +3 -0
  32. package/dist/Shared/Components/CICDHistory/DetectBottom.d.ts +4 -0
  33. package/dist/Shared/Components/CICDHistory/ErrorInfoStatusBar.d.ts +3 -0
  34. package/dist/Shared/Components/CICDHistory/History.components.d.ts +5 -0
  35. package/dist/Shared/Components/CICDHistory/LogsRenderer.d.ts +4 -0
  36. package/dist/Shared/Components/CICDHistory/Sidebar.d.ts +5 -0
  37. package/dist/Shared/Components/CICDHistory/StatusFilterButtonComponent.d.ts +3 -0
  38. package/dist/Shared/Components/CICDHistory/TriggerOutput.d.ts +6 -0
  39. package/dist/Shared/Components/CICDHistory/constants.d.ts +45 -0
  40. package/dist/Shared/Components/CICDHistory/index.d.ts +17 -0
  41. package/dist/Shared/Components/CICDHistory/service.d.ts +28 -0
  42. package/dist/Shared/Components/CICDHistory/types.d.ts +590 -0
  43. package/dist/Shared/Components/CICDHistory/utils.d.ts +6 -0
  44. package/dist/Shared/Components/Error/ErrorBar.d.ts +4 -0
  45. package/dist/Shared/Components/Error/index.d.ts +2 -0
  46. package/dist/Shared/Components/Error/types.d.ts +9 -0
  47. package/dist/Shared/Components/Error/utils.d.ts +3 -0
  48. package/dist/Shared/Components/FeatureDescription/FeatureDescriptionModal.d.ts +3 -0
  49. package/dist/Shared/Components/FeatureDescription/FeatureTitleWithInfo.d.ts +4 -0
  50. package/dist/Shared/Components/FeatureDescription/constant.d.ts +8 -0
  51. package/dist/Shared/Components/FeatureDescription/index.d.ts +2 -0
  52. package/dist/Shared/Components/FeatureDescription/types.d.ts +19 -0
  53. package/dist/Shared/Components/FeatureDescription/utils.d.ts +6 -0
  54. package/dist/Shared/Components/GitCommitInfoGeneric/GitCommitInfoGeneric.d.ts +4 -0
  55. package/dist/Shared/Components/GitCommitInfoGeneric/GitMaterialInfoHeader.d.ts +9 -0
  56. package/dist/Shared/Components/GitCommitInfoGeneric/index.d.ts +1 -0
  57. package/dist/Shared/Components/GitCommitInfoGeneric/types.d.ts +11 -0
  58. package/dist/Shared/Components/ImageWithFallback/ImageWithFallback.component.d.ts +4 -0
  59. package/dist/Shared/Components/ImageWithFallback/index.d.ts +2 -0
  60. package/dist/Shared/Components/ImageWithFallback/types.d.ts +12 -0
  61. package/dist/Shared/Components/ModalSidebarPanel/ModalSidebarPanel.component.d.ts +4 -0
  62. package/dist/Shared/Components/ModalSidebarPanel/index.d.ts +2 -0
  63. package/dist/Shared/Components/ModalSidebarPanel/types.d.ts +9 -0
  64. package/dist/Shared/Components/ShowMoreText/ShowMoreText.d.ts +5 -0
  65. package/dist/Shared/Components/index.d.ts +6 -0
  66. package/dist/Shared/Helpers.d.ts +8 -1
  67. package/dist/Shared/Hooks/UsePrompt/UsePrompt.d.ts +8 -0
  68. package/dist/Shared/Hooks/UsePrompt/index.d.ts +1 -0
  69. package/dist/Shared/Hooks/UsePrompt/types.d.ts +6 -0
  70. package/dist/Shared/Hooks/index.d.ts +1 -0
  71. package/dist/Shared/Providers/ImageSelectionUtility/types.d.ts +0 -1
  72. package/dist/Shared/Services/common.service.d.ts +3 -0
  73. package/dist/Shared/Services/index.d.ts +2 -0
  74. package/dist/Shared/Services/types.d.ts +13 -0
  75. package/dist/Shared/Store/IndexStore.d.ts +48 -0
  76. package/dist/Shared/Store/index.d.ts +1 -0
  77. package/dist/Shared/constants.d.ts +304 -0
  78. package/dist/Shared/index.d.ts +3 -1
  79. package/dist/Shared/types.d.ts +239 -46
  80. package/dist/Shared/validations.d.ts +4 -0
  81. package/dist/assets/index.css +1 -1
  82. package/dist/{cssMode-bd8cba6b.js → cssMode-520db43c.js} +1 -1
  83. package/dist/{freemarker2-d754a142.js → freemarker2-8102ab8d.js} +1 -1
  84. package/dist/{handlebars-dba74ee7.js → handlebars-48b54c55.js} +1 -1
  85. package/dist/{html-61f0b6d0.js → html-57fe72de.js} +1 -1
  86. package/dist/{htmlMode-58687491.js → htmlMode-fad88102.js} +1 -1
  87. package/dist/{index-ca58e138.js → index-ed2ecc9f.js} +59527 -54224
  88. package/dist/index.js +416 -326
  89. package/dist/{javascript-4b280c7e.js → javascript-095bc45f.js} +1 -1
  90. package/dist/{jsonMode-5e0eb04a.js → jsonMode-53b436a9.js} +1 -1
  91. package/dist/{liquid-ecf9204c.js → liquid-e4152333.js} +1 -1
  92. package/dist/{mdx-eed000f1.js → mdx-9b3781e3.js} +1 -1
  93. package/dist/{python-e984551d.js → python-ab53c9a3.js} +1 -1
  94. package/dist/{razor-abf548e5.js → razor-4edb4a7d.js} +1 -1
  95. package/dist/{tsMode-ff9cf530.js → tsMode-42e8d846.js} +1 -1
  96. package/dist/{typescript-d7e0892b.js → typescript-1e5018b9.js} +1 -1
  97. package/dist/{xml-50360005.js → xml-c55b1b7f.js} +1 -1
  98. package/dist/{yaml-9674090c.js → yaml-bb2d8678.js} +1 -1
  99. package/package.json +17 -15
@@ -1,6 +1,187 @@
1
- import { PatchOperationType } from './constants';
2
- import { OptionType, CommonNodeAttr, ResponseType, UserApprovalConfigType, VulnerabilityType } from '../Common';
1
+ import { EnvironmentTypeEnum, PatchOperationType } from './constants';
2
+ import { OptionType, CommonNodeAttr, ResponseType, UserApprovalConfigType, VulnerabilityType, DeploymentAppTypes } from '../Common';
3
3
 
4
+ export declare enum EnvType {
5
+ CHART = "helm_charts",
6
+ APPLICATION = "apps"
7
+ }
8
+ export interface EnvDetails {
9
+ envType: EnvType;
10
+ envId: number;
11
+ appId: number;
12
+ }
13
+ interface OtherEnvironment {
14
+ environmentId: number;
15
+ environmentName: string;
16
+ appMetrics: boolean;
17
+ infraMetrics: boolean;
18
+ prod: boolean;
19
+ }
20
+ export interface PodMetaData {
21
+ containers: Array<string>;
22
+ initContainers: any;
23
+ ephemeralContainers: any;
24
+ isNew: boolean;
25
+ name: string;
26
+ uid: string;
27
+ }
28
+ export interface Info {
29
+ value: string;
30
+ name: string;
31
+ }
32
+ export interface Health {
33
+ status: string;
34
+ message?: string;
35
+ }
36
+ export interface TargetLabel {
37
+ 'app.kubernetes.io/instance': string;
38
+ 'app.kubernetes.io/name': string;
39
+ }
40
+ export interface TargetLabels {
41
+ targetLabel: TargetLabel;
42
+ }
43
+ export interface NetworkingInfo {
44
+ targetLabels: TargetLabels;
45
+ }
46
+ export declare enum Nodes {
47
+ Service = "Service",
48
+ Alertmanager = "Alertmanager",
49
+ PodSecurity = "PodSecurityPolicy",
50
+ ConfigMap = "ConfigMap",
51
+ ServiceAccount = "ServiceAccount",
52
+ ClusterRoleBinding = "ClusterRoleBinding",
53
+ RoleBinding = "RoleBinding",
54
+ ClusterRole = "ClusterRole",
55
+ Role = "Role",
56
+ Prometheus = "Prometheus",
57
+ ServiceMonitor = "ServiceMonitor",
58
+ Deployment = "Deployment",
59
+ MutatingWebhookConfiguration = "MutatingWebhookConfiguration",
60
+ DaemonSet = "DaemonSet",
61
+ Secret = "Secret",
62
+ ValidatingWebhookConfiguration = "ValidatingWebhookConfiguration",
63
+ Pod = "Pod",
64
+ Ingress = "Ingress",
65
+ ReplicaSet = "ReplicaSet",
66
+ Endpoints = "Endpoints",
67
+ Cluster = "ClusterRoleBinding",
68
+ PodSecurityPolicy = "PodSecurityPolicy",
69
+ CronJob = "CronJob",
70
+ Job = "Job",
71
+ ReplicationController = "ReplicationController",
72
+ StatefulSet = "StatefulSet",
73
+ Rollout = "Rollout",
74
+ PersistentVolumeClaim = "PersistentVolumeClaim",
75
+ PersistentVolume = "PersistentVolume",
76
+ Containers = "Containers",
77
+ InitContainers = "InitContainers",
78
+ EndpointSlice = "EndpointSlice",
79
+ NetworkPolicy = "NetworkPolicy",
80
+ StorageClass = "StorageClass",
81
+ VolumeSnapshot = "VolumeSnapshot",
82
+ VolumeSnapshotContent = "VolumeSnapshotContent",
83
+ VolumeSnapshotClass = "VolumeSnapshotClass",
84
+ PodDisruptionBudget = "PodDisruptionBudget",
85
+ Event = "Event",
86
+ Namespace = "Namespace",
87
+ Overview = "Overview"
88
+ }
89
+ export type NodeType = keyof typeof Nodes;
90
+ export interface Node {
91
+ createdAt: Date;
92
+ health: Health;
93
+ kind: NodeType;
94
+ name: string;
95
+ namespace: string;
96
+ networkingInfo: NetworkingInfo;
97
+ resourceVersion: string;
98
+ uid: string;
99
+ version: string;
100
+ parentRefs: Array<Node>;
101
+ group: string;
102
+ isSelected: boolean;
103
+ info: Info[];
104
+ port: number;
105
+ canBeHibernated: boolean;
106
+ isHibernated: boolean;
107
+ }
108
+ export interface iNodes extends Array<iNode> {
109
+ }
110
+ export interface iNode extends Node {
111
+ childNodes: iNodes;
112
+ type: NodeType;
113
+ status: string;
114
+ }
115
+ export interface ResourceTree {
116
+ conditions: any;
117
+ newGenerationReplicaSet: string;
118
+ nodes: Array<Node>;
119
+ podMetadata: Array<PodMetaData>;
120
+ status: string;
121
+ resourcesSyncResult?: Record<string, string>;
122
+ }
123
+ export declare enum AppType {
124
+ DEVTRON_APP = "devtron_app",
125
+ DEVTRON_HELM_CHART = "devtron_helm_chart",
126
+ EXTERNAL_HELM_CHART = "external_helm_chart",
127
+ EXTERNAL_ARGO_APP = "external_argo_app"
128
+ }
129
+ export interface HelmReleaseStatus {
130
+ status: string;
131
+ message: string;
132
+ description: string;
133
+ }
134
+ interface MaterialInfo {
135
+ author: string;
136
+ branch: string;
137
+ message: string;
138
+ modifiedTime: string;
139
+ revision: string;
140
+ url: string;
141
+ webhookData: string;
142
+ }
143
+ export interface AppDetails {
144
+ appId?: number;
145
+ appName: string;
146
+ appStoreAppName?: string;
147
+ appStoreAppVersion?: string;
148
+ appStoreChartId?: number;
149
+ appStoreChartName?: string;
150
+ appStoreInstalledAppVersionId?: number;
151
+ ciArtifactId?: number;
152
+ deprecated?: false;
153
+ environmentId?: number;
154
+ environmentName: string;
155
+ installedAppId?: number;
156
+ instanceDetail?: null;
157
+ k8sVersion?: string;
158
+ lastDeployedBy?: string;
159
+ lastDeployedTime: string;
160
+ namespace: string;
161
+ resourceTree: ResourceTree;
162
+ materialInfo?: MaterialInfo[];
163
+ releaseVersion?: string;
164
+ dataSource?: string;
165
+ lastDeployedPipeline?: string;
166
+ otherEnvironment?: OtherEnvironment[];
167
+ projectName?: string;
168
+ appType?: AppType;
169
+ helmReleaseStatus?: HelmReleaseStatus;
170
+ clusterId?: number;
171
+ notes?: string;
172
+ deploymentAppType?: DeploymentAppTypes;
173
+ ipsAccessProvided?: boolean;
174
+ externalCi?: boolean;
175
+ clusterName?: string;
176
+ dockerRegistryId?: string;
177
+ deploymentAppDeleteRequest?: boolean;
178
+ userApprovalConfig?: string;
179
+ isVirtualEnvironment?: boolean;
180
+ imageTag?: string;
181
+ helmPackageName?: string;
182
+ appStatus?: string;
183
+ chartAvatar?: string;
184
+ }
4
185
  export declare enum RegistryType {
5
186
  GIT = "git",
6
187
  GITHUB = "github",
@@ -169,7 +350,11 @@ export declare enum ResourceKindType {
169
350
  job = "job",
170
351
  cluster = "cluster",
171
352
  release = "release",
172
- releaseTrack = "release-track"
353
+ releaseTrack = "release-track",
354
+ tenant = "tenant",
355
+ installation = "installation",
356
+ environment = "environment",
357
+ cdPipeline = "cd-pipeline"
173
358
  }
174
359
  /**
175
360
  * Versions support for the resources on BE
@@ -209,50 +394,18 @@ export declare enum WebhookEventNameType {
209
394
  PULL_REQUEST = "Pull Request",
210
395
  TAG_CREATION = "Tag Creation"
211
396
  }
212
- export declare enum Nodes {
213
- Service = "Service",
214
- Alertmanager = "Alertmanager",
215
- PodSecurity = "PodSecurityPolicy",
216
- ConfigMap = "ConfigMap",
217
- ServiceAccount = "ServiceAccount",
218
- ClusterRoleBinding = "ClusterRoleBinding",
219
- RoleBinding = "RoleBinding",
220
- ClusterRole = "ClusterRole",
221
- Role = "Role",
222
- Prometheus = "Prometheus",
223
- ServiceMonitor = "ServiceMonitor",
224
- Deployment = "Deployment",
225
- MutatingWebhookConfiguration = "MutatingWebhookConfiguration",
226
- DaemonSet = "DaemonSet",
227
- Secret = "Secret",
228
- ValidatingWebhookConfiguration = "ValidatingWebhookConfiguration",
229
- Pod = "Pod",
230
- Ingress = "Ingress",
231
- ReplicaSet = "ReplicaSet",
232
- Endpoints = "Endpoints",
233
- Cluster = "ClusterRoleBinding",
234
- PodSecurityPolicy = "PodSecurityPolicy",
235
- CronJob = "CronJob",
236
- Job = "Job",
237
- ReplicationController = "ReplicationController",
238
- StatefulSet = "StatefulSet",
239
- Rollout = "Rollout",
240
- PersistentVolumeClaim = "PersistentVolumeClaim",
241
- PersistentVolume = "PersistentVolume",
242
- Containers = "Containers",
243
- InitContainers = "InitContainers",
244
- EndpointSlice = "EndpointSlice",
245
- NetworkPolicy = "NetworkPolicy",
246
- StorageClass = "StorageClass",
247
- VolumeSnapshot = "VolumeSnapshot",
248
- VolumeSnapshotContent = "VolumeSnapshotContent",
249
- VolumeSnapshotClass = "VolumeSnapshotClass",
250
- PodDisruptionBudget = "PodDisruptionBudget",
251
- Event = "Event",
252
- Namespace = "Namespace",
253
- Overview = "Overview"
397
+ export type IntersectionOptions = {
398
+ root?: React.RefObject<Element>;
399
+ rootMargin?: string;
400
+ threshold?: number | number[];
401
+ once?: boolean;
402
+ defaultIntersecting?: boolean;
403
+ };
404
+ export type IntersectionChangeHandler = (entry: IntersectionObserverEntry) => void;
405
+ export interface InputFieldState<T = string> {
406
+ value: T;
407
+ error: string;
254
408
  }
255
- export type NodeType = keyof typeof Nodes;
256
409
  export declare enum AggregationKeys {
257
410
  Workloads = "Workloads",
258
411
  Networking = "Networking",
@@ -265,3 +418,43 @@ export declare enum AggregationKeys {
265
418
  Namespaces = "Namespaces"
266
419
  }
267
420
  export type AggregationKeysType = keyof typeof AggregationKeys;
421
+ export interface EnvironmentType {
422
+ /**
423
+ * Unique identifier for the environment
424
+ */
425
+ id: number;
426
+ /**
427
+ * Name of the environment
428
+ */
429
+ name: string;
430
+ /**
431
+ * Associated namespace for the environment
432
+ */
433
+ namespace: string;
434
+ /**
435
+ * Type of the environment
436
+ */
437
+ environmentType: EnvironmentTypeEnum;
438
+ /**
439
+ * Associated cluster for the environment
440
+ */
441
+ cluster: string;
442
+ }
443
+ export interface CreatedByDTO {
444
+ icon: boolean;
445
+ id: number;
446
+ name: string;
447
+ }
448
+ export declare enum DependencyType {
449
+ UPSTREAM = "upstream",
450
+ DOWNSTREAM = "downstream",
451
+ LEVEL = "level"
452
+ }
453
+ export interface scrollableInterface {
454
+ autoBottomScroll: boolean;
455
+ }
456
+ export declare enum PromiseAllStatusType {
457
+ FULFILLED = "fulfilled",
458
+ REJECTED = "rejected"
459
+ }
460
+ export {};
@@ -8,6 +8,7 @@ export declare const MESSAGES: {
8
8
  CAN_NOT_START_END_WITH_SEPARATORS: string;
9
9
  getMinMaxCharMessage: (min: number, max: number) => string;
10
10
  getMaxCharMessage: (max: number) => string;
11
+ getMinCharMessage: (min: number) => string;
11
12
  VALID_POSITIVE_NUMBER: string;
12
13
  VALID_POSITIVE_INTEGER: string;
13
14
  MAX_SAFE_INTEGER: string;
@@ -15,5 +16,8 @@ export declare const MESSAGES: {
15
16
  export declare const requiredField: (value: string) => ValidationResponseType;
16
17
  export declare const validateName: (name: string) => ValidationResponseType;
17
18
  export declare const validateDescription: (description: string) => ValidationResponseType;
19
+ export declare const validateStringLength: (value: string, maxLimit: number, minLimit: number) => ValidationResponseType;
18
20
  export declare const validateRequiredPositiveNumber: (value: string | number) => ValidationResponseType;
19
21
  export declare const validateRequiredPositiveInteger: (value: string | number) => ValidationResponseType;
22
+ export declare const validateURL: (url: string, allowBase64Url?: boolean) => ValidationResponseType;
23
+ export declare const validateIfImageExist: (url: string) => Promise<ValidationResponseType>;