@devtron-labs/devtron-fe-common-lib 0.6.0-patch-1-beta-13 → 0.6.0-patch-1-beta-14

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 (31) hide show
  1. package/dist/Common/Constants.d.ts +4 -0
  2. package/dist/Pages/ResourceBrowser/Helper.d.ts +11 -0
  3. package/dist/Pages/ResourceBrowser/ResourceBrowser.Types.d.ts +31 -1
  4. package/dist/Pages/ResourceBrowser/constants.d.ts +4 -0
  5. package/dist/Pages/ResourceBrowser/index.d.ts +1 -0
  6. package/dist/Pages/ResourceBrowser/service.d.ts +2 -1
  7. package/dist/Shared/Components/BulkSelection/BulkSelection.d.ts +1 -1
  8. package/dist/Shared/Components/BulkSelection/types.d.ts +4 -0
  9. package/dist/Shared/Components/NumbersCount/NumbersCount.component.d.ts +3 -0
  10. package/dist/Shared/Components/NumbersCount/index.d.ts +1 -0
  11. package/dist/Shared/Components/NumbersCount/types.d.ts +13 -0
  12. package/dist/Shared/Components/index.d.ts +1 -0
  13. package/dist/{cssMode-BqyPCtyc.js → cssMode-M1Y9Kveo.js} +1 -1
  14. package/dist/{freemarker2-IpV4WKoD.js → freemarker2-DFHdIRy9.js} +1 -1
  15. package/dist/{handlebars-P_tJGTpo.js → handlebars-D3nRxdU4.js} +1 -1
  16. package/dist/{html-B3ql4U_Y.js → html-BLyZhTBG.js} +1 -1
  17. package/dist/{htmlMode-9sbgjEyu.js → htmlMode-DAfmKWRj.js} +1 -1
  18. package/dist/{index-Cb292vn8.js → index-C480g8oV.js} +6568 -6515
  19. package/dist/index.d.ts +1 -0
  20. package/dist/index.js +600 -595
  21. package/dist/{javascript-v38eq-N9.js → javascript-BdnZ6IyG.js} +1 -1
  22. package/dist/{jsonMode-4ldwiZJg.js → jsonMode-C8WqxQsN.js} +1 -1
  23. package/dist/{liquid-DsHGid7C.js → liquid-cjrN7uoQ.js} +1 -1
  24. package/dist/{mdx-BbHRDNpe.js → mdx-DmM1s3iv.js} +1 -1
  25. package/dist/{python-h-Ztjhxn.js → python-ltuT5SCI.js} +1 -1
  26. package/dist/{razor-BTpD6aAa.js → razor-DDrHqsOF.js} +1 -1
  27. package/dist/{tsMode-CYbI0DHG.js → tsMode-vQlSwK4Y.js} +1 -1
  28. package/dist/{typescript-RQhutDpb.js → typescript-uoDdupI_.js} +1 -1
  29. package/dist/{xml-Ch7RqBBb.js → xml-XgRfdLM5.js} +1 -1
  30. package/dist/{yaml-eL6RPtuA.js → yaml-dAeR2S7e.js} +1 -1
  31. package/package.json +1 -1
@@ -46,6 +46,7 @@ export declare const URLS: {
46
46
  GLOBAL_CONFIG_DEPLOYMENT_CHARTS_LIST: string;
47
47
  NETWORK_STATUS_INTERFACE: string;
48
48
  RESOURCE_BROWSER: string;
49
+ COMPARE_CLUSTERS: string;
49
50
  };
50
51
  export declare const ROUTES: {
51
52
  APP: string;
@@ -54,6 +55,8 @@ export declare const ROUTES: {
54
55
  PROJECT_LIST_MIN: string;
55
56
  USER_CHECK_ROLE: string;
56
57
  IMAGE_TAGGING: string;
58
+ CREATE_RESOURCE: string;
59
+ K8S_RESOURCE_CREATE: string;
57
60
  CI_CONFIG_GET: string;
58
61
  CD_MATERIAL_GET: string;
59
62
  DEPLOYMENT_TEMPLATE_LIST: string;
@@ -92,6 +95,7 @@ export declare const ROUTES: {
92
95
  DEPLOYMENT_CHARTS_LIST: string;
93
96
  USER_LIST_MIN: string;
94
97
  CONFIG_DATA: string;
98
+ K8S_RESOURCE: string;
95
99
  K8S_RESOURCE_LIST: string;
96
100
  };
97
101
  export declare enum KEY_VALUE {
@@ -1,2 +1,13 @@
1
1
  import { AggregationKeys, NodeType } from '../../Shared';
2
+ import { ApiResourceGroupType, CreateResourceRequestBodyParamsType, CreateResourceRequestBodyType } from './ResourceBrowser.Types';
2
3
  export declare function getAggregator(nodeType: NodeType, defaultAsOtherResources?: boolean): AggregationKeys;
4
+ export declare const getK8sResourceListPayload: (clusterId: string, namespace: string, selectedResource: ApiResourceGroupType, filters: object) => {
5
+ clusterId: number;
6
+ k8sRequest: {
7
+ resourceIdentifier: {
8
+ namespace: string;
9
+ groupVersionKind: import('./ResourceBrowser.Types').GVKType;
10
+ };
11
+ };
12
+ };
13
+ export declare const createResourceRequestBody: ({ clusterId, group, version, kind, name, namespace, updatedManifest, }: CreateResourceRequestBodyParamsType) => CreateResourceRequestBodyType;
@@ -54,7 +54,7 @@ export interface BulkOperation {
54
54
  operation: (signal: AbortSignal, data?: unknown) => Promise<void>;
55
55
  }
56
56
  export type BulkOperationModalProps = {
57
- operationType: 'restart' | 'delete';
57
+ operationType: 'restart' | 'delete' | 'creation';
58
58
  clusterName: string;
59
59
  operations: NonNullable<BulkOperation[]>;
60
60
  handleModalClose: () => void;
@@ -64,4 +64,34 @@ export type BulkOperationModalProps = {
64
64
  shouldAllowForceOperation?: true;
65
65
  };
66
66
  export type BulkOperationModalState = BulkOperationModalProps['operationType'] | 'closed';
67
+ export interface CreateResourceRequestBodyType {
68
+ appId: string;
69
+ clusterId: number;
70
+ k8sRequest: {
71
+ resourceIdentifier: Required<K8sRequestResourceIdentifierType>;
72
+ patch?: string;
73
+ };
74
+ }
75
+ export interface ResourceManifestDTO {
76
+ manifestResponse: {
77
+ manifest: Record<string, unknown>;
78
+ };
79
+ secretViewAccess: boolean;
80
+ }
81
+ export interface CreateResourceRequestBodyParamsType extends Pick<CreateResourceRequestBodyType, 'clusterId'>, Required<Pick<K8sRequestResourceIdentifierType, 'name' | 'namespace'>> {
82
+ updatedManifest?: string;
83
+ group: GVKType['Group'];
84
+ version: GVKType['Version'];
85
+ kind: GVKType['Kind'];
86
+ }
87
+ export interface CreateResourcePayload {
88
+ clusterId: number;
89
+ manifest: string;
90
+ }
91
+ export interface CreateResourceDTO {
92
+ kind: string;
93
+ name: string;
94
+ isUpdate: boolean;
95
+ error: string;
96
+ }
67
97
  export {};
@@ -0,0 +1,4 @@
1
+ export declare const ALL_NAMESPACE_OPTION: {
2
+ value: string;
3
+ label: string;
4
+ };
@@ -1,4 +1,5 @@
1
1
  export * from './ResourceBrowser.Types';
2
2
  export * from './Helper';
3
+ export * from './constants';
3
4
  export * from './types';
4
5
  export * from './service';
@@ -1,3 +1,4 @@
1
1
  import { ResponseType } from '../../Common/Types';
2
- import { K8sResourceDetailType, K8sResourceListPayloadType } from './ResourceBrowser.Types';
2
+ import { CreateResourceDTO, CreateResourcePayload, K8sResourceDetailType, K8sResourceListPayloadType } from './ResourceBrowser.Types';
3
3
  export declare const getK8sResourceList: (resourceListPayload: K8sResourceListPayloadType, signal?: AbortSignal) => Promise<ResponseType<K8sResourceDetailType>>;
4
+ export declare const createNewResource: (resourceListPayload: CreateResourcePayload) => Promise<ResponseType<CreateResourceDTO[]>>;
@@ -1,3 +1,3 @@
1
1
  import { BulkSelectionProps } from './types';
2
- declare const BulkSelection: <T>({ showPagination, disabled }: BulkSelectionProps) => JSX.Element;
2
+ declare const BulkSelection: <T>({ showPagination, disabled, showChevronDownIcon }: BulkSelectionProps) => JSX.Element;
3
3
  export default BulkSelection;
@@ -28,6 +28,10 @@ export interface UseBulkSelectionReturnType<T> extends GetBulkSelectionCheckboxV
28
28
  }
29
29
  export interface BulkSelectionProps {
30
30
  showPagination: boolean;
31
+ /**
32
+ * @default true
33
+ */
34
+ showChevronDownIcon?: boolean;
31
35
  disabled?: boolean;
32
36
  }
33
37
  export interface BulkSelectionDropdownItemsType {
@@ -0,0 +1,3 @@
1
+ import { NumbersCountProps } from './types';
2
+ declare const NumbersCount: ({ count, isApprox, isSelected }: NumbersCountProps) => JSX.Element;
3
+ export default NumbersCount;
@@ -0,0 +1 @@
1
+ export { default as NumbersCount } from './NumbersCount.component';
@@ -0,0 +1,13 @@
1
+ export interface NumbersCountProps {
2
+ count: number;
3
+ /**
4
+ * @default false
5
+ * @description If true, it will change the bgColor to var(--B500)
6
+ */
7
+ isSelected?: boolean;
8
+ /**
9
+ * @default false
10
+ * @description If true, it will show the count with tilde like ~number
11
+ */
12
+ isApprox?: boolean;
13
+ }
@@ -41,3 +41,4 @@ export * from './Collapse';
41
41
  export * from './Security';
42
42
  export * from './Button';
43
43
  export * from './InvalidYAMLTippy';
44
+ export * from './NumbersCount';
@@ -1,7 +1,7 @@
1
1
  var Fe = Object.defineProperty;
2
2
  var Le = (e, n, i) => n in e ? Fe(e, n, { enumerable: !0, configurable: !0, writable: !0, value: i }) : e[n] = i;
3
3
  var k = (e, n, i) => Le(e, typeof n != "symbol" ? n + "" : n, i);
4
- import { m as je } from "./index-Cb292vn8.js";
4
+ import { m as je } from "./index-C480g8oV.js";
5
5
  /*!-----------------------------------------------------------------------------
6
6
  * Copyright (c) Microsoft Corporation. All rights reserved.
7
7
  * Version: 0.44.0(3e047efd345ff102c8c61b5398fb30845aaac166)
@@ -1,4 +1,4 @@
1
- import { m as f } from "./index-Cb292vn8.js";
1
+ import { m as f } from "./index-C480g8oV.js";
2
2
  /*!-----------------------------------------------------------------------------
3
3
  * Copyright (c) Microsoft Corporation. All rights reserved.
4
4
  * Version: 0.44.0(3e047efd345ff102c8c61b5398fb30845aaac166)
@@ -1,4 +1,4 @@
1
- import { m as l } from "./index-Cb292vn8.js";
1
+ import { m as l } from "./index-C480g8oV.js";
2
2
  /*!-----------------------------------------------------------------------------
3
3
  * Copyright (c) Microsoft Corporation. All rights reserved.
4
4
  * Version: 0.44.0(3e047efd345ff102c8c61b5398fb30845aaac166)
@@ -1,4 +1,4 @@
1
- import { m as s } from "./index-Cb292vn8.js";
1
+ import { m as s } from "./index-C480g8oV.js";
2
2
  /*!-----------------------------------------------------------------------------
3
3
  * Copyright (c) Microsoft Corporation. All rights reserved.
4
4
  * Version: 0.44.0(3e047efd345ff102c8c61b5398fb30845aaac166)
@@ -1,7 +1,7 @@
1
1
  var Be = Object.defineProperty;
2
2
  var $e = (e, n, i) => n in e ? Be(e, n, { enumerable: !0, configurable: !0, writable: !0, value: i }) : e[n] = i;
3
3
  var k = (e, n, i) => $e(e, typeof n != "symbol" ? n + "" : n, i);
4
- import { m as qe } from "./index-Cb292vn8.js";
4
+ import { m as qe } from "./index-C480g8oV.js";
5
5
  /*!-----------------------------------------------------------------------------
6
6
  * Copyright (c) Microsoft Corporation. All rights reserved.
7
7
  * Version: 0.44.0(3e047efd345ff102c8c61b5398fb30845aaac166)