@devtron-labs/devtron-fe-common-lib 0.0.64-beta-3 → 0.0.65-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.
- package/dist/Common/Constants.d.ts +1 -0
- package/dist/Common/DraggableWrapper/DraggableWrapper.d.ts +1 -1
- package/dist/Common/DraggableWrapper/types.d.ts +8 -1
- package/dist/Common/Hooks/useUrlFilters/index.d.ts +1 -1
- package/dist/Common/Hooks/useUrlFilters/types.d.ts +54 -1
- package/dist/Common/Hooks/useUrlFilters/useUrlFilters.d.ts +2 -14
- package/dist/Common/Types.d.ts +2 -2
- package/dist/Common/index.d.ts +0 -1
- package/dist/Pages/GlobalConfigurations/Authorization/constants.d.ts +5 -1
- package/dist/Pages/GlobalConfigurations/Authorization/index.d.ts +1 -0
- package/dist/Pages/GlobalConfigurations/Authorization/types.d.ts +23 -0
- package/dist/Shared/Components/BulkSelection/BulkSelectionDropdownItems.d.ts +1 -1
- package/dist/Shared/Components/BulkSelection/constants.d.ts +1 -1
- package/dist/Shared/Components/BulkSelection/types.d.ts +3 -0
- package/dist/Shared/Components/ExcludedImageNode/ExcludedImageNode.d.ts +3 -0
- package/dist/Shared/Components/ExcludedImageNode/index.d.ts +1 -0
- package/dist/Shared/Components/ExcludedImageNode/types.d.ts +3 -0
- package/dist/Shared/Components/FilterChips/FilterChips.component.d.ts +6 -0
- package/dist/Shared/Components/FilterChips/index.d.ts +2 -0
- package/dist/Shared/Components/FilterChips/types.d.ts +37 -0
- package/dist/Shared/Components/ImageCard/ArtifactInfo/ArtifactInfo.d.ts +3 -0
- package/dist/Shared/Components/ImageCard/ArtifactInfo/index.d.ts +1 -0
- package/dist/Shared/Components/ImageCard/ArtifactInfo/types.d.ts +3 -0
- package/dist/Shared/Components/ImageCard/ImageCard.d.ts +3 -0
- package/dist/Shared/Components/ImageCard/SequentialCDCardTitle/DeploymentEnvState/DeploymentEnvState.d.ts +3 -0
- package/dist/Shared/Components/ImageCard/SequentialCDCardTitle/DeploymentEnvState/constants.d.ts +6 -0
- package/dist/Shared/Components/ImageCard/SequentialCDCardTitle/DeploymentEnvState/index.d.ts +1 -0
- package/dist/Shared/Components/ImageCard/SequentialCDCardTitle/DeploymentEnvState/types.d.ts +9 -0
- package/dist/Shared/Components/ImageCard/SequentialCDCardTitle/DeploymentEnvState/utils.d.ts +2 -0
- package/dist/Shared/Components/ImageCard/SequentialCDCardTitle/SequentialCDCardTitle.d.ts +3 -0
- package/dist/Shared/Components/ImageCard/SequentialCDCardTitle/index.d.ts +1 -0
- package/dist/Shared/Components/ImageCard/index.d.ts +3 -0
- package/dist/Shared/Components/ImageCard/types.d.ts +38 -0
- package/dist/Shared/Components/ImageCardAccordion/ImageCardAccordion.d.ts +3 -0
- package/dist/Shared/Components/ImageCardAccordion/index.d.ts +1 -0
- package/dist/Shared/Components/ImageCardAccordion/types.d.ts +22 -0
- package/dist/Shared/Components/ScannedByToolModal/ScannedByToolModal.d.ts +3 -0
- package/dist/Shared/Components/ScannedByToolModal/index.d.ts +1 -0
- package/dist/Shared/Components/ScannedByToolModal/types.d.ts +3 -0
- package/dist/Shared/Components/Vulnerabilities/Vulnerabilities.d.ts +3 -0
- package/dist/Shared/Components/Vulnerabilities/constants.d.ts +4 -0
- package/dist/Shared/Components/Vulnerabilities/index.d.ts +1 -0
- package/dist/Shared/Components/Vulnerabilities/service.d.ts +28 -0
- package/dist/Shared/Components/Vulnerabilities/types.d.ts +9 -0
- package/dist/Shared/Components/index.d.ts +6 -0
- package/dist/Shared/constants.d.ts +19 -0
- package/dist/Shared/index.d.ts +2 -0
- package/dist/Shared/types.d.ts +23 -0
- package/dist/assets/index.css +1 -1
- package/dist/index.js +23868 -215
- package/package.json +1 -1
- package/dist/abap-9f67f57a.js +0 -1314
- package/dist/apex-ff62e532.js +0 -315
- package/dist/assets/editor.worker-d26000ef.js +0 -9
- package/dist/assets/json.worker-f23a4654.js +0 -40
- package/dist/assets/yaml.worker-35ea3f9a.js +0 -467
- package/dist/azcli-31e64a7f.js +0 -74
- package/dist/bat-0ffe897e.js +0 -95
- package/dist/bicep-3414a2b1.js +0 -108
- package/dist/cameligo-df1f3f25.js +0 -168
- package/dist/clojure-65b0f010.js +0 -754
- package/dist/coffee-437f0fba.js +0 -228
- package/dist/cpp-66843dd5.js +0 -390
- package/dist/csharp-621d9a49.js +0 -320
- package/dist/csp-de0d5244.js +0 -57
- package/dist/css-7cd5ed4c.js +0 -186
- package/dist/cssMode-0eb181b8.js +0 -1446
- package/dist/cypher-70ad96fe.js +0 -262
- package/dist/dart-33ae3739.js +0 -270
- package/dist/dockerfile-f2274a50.js +0 -132
- package/dist/ecl-3b8294a3.js +0 -454
- package/dist/elixir-b9dcc73a.js +0 -489
- package/dist/flow9-bdde8316.js +0 -141
- package/dist/freemarker2-4361569f.js +0 -643
- package/dist/fsharp-eac2e449.js +0 -210
- package/dist/go-d12ed8d4.js +0 -208
- package/dist/graphql-c7356b69.js +0 -141
- package/dist/handlebars-babdfc67.js +0 -391
- package/dist/hcl-e883a0d4.js +0 -177
- package/dist/html-23b49eab.js +0 -281
- package/dist/htmlMode-f37a1616.js +0 -1456
- package/dist/index-3a430320.js +0 -127405
- package/dist/ini-425ab711.js +0 -68
- package/dist/java-2bc0fd68.js +0 -221
- package/dist/javascript-3597fa14.js +0 -75
- package/dist/jsonMode-b97d1b5f.js +0 -1867
- package/dist/julia-1c932615.js +0 -496
- package/dist/kotlin-1ab839c8.js +0 -245
- package/dist/less-6fe856f5.js +0 -168
- package/dist/lexon-4955ac52.js +0 -151
- package/dist/liquid-9778cbb4.js +0 -238
- package/dist/lua-3cca0047.js +0 -157
- package/dist/m3-132e9cb6.js +0 -210
- package/dist/markdown-ea59a0c1.js +0 -202
- package/dist/mips-19811f4b.js +0 -194
- package/dist/msdax-69954a10.js +0 -377
- package/dist/mysql-82088e5d.js +0 -876
- package/dist/objective-c-1976eccc.js +0 -188
- package/dist/pascal-8ef177cb.js +0 -245
- package/dist/pascaligo-bc517b9e.js +0 -158
- package/dist/perl-8b93582c.js +0 -599
- package/dist/pgsql-00c11a6d.js +0 -847
- package/dist/php-4c8c276f.js +0 -471
- package/dist/pla-e9b4ffb1.js +0 -131
- package/dist/postiats-2071af8c.js +0 -544
- package/dist/powerquery-8e388ceb.js +0 -890
- package/dist/powershell-e35db398.js +0 -233
- package/dist/protobuf-a24b9176.js +0 -422
- package/dist/pug-2c94d9b8.js +0 -393
- package/dist/python-e4dba3c0.js +0 -259
- package/dist/qsharp-d730d7fe.js +0 -282
- package/dist/r-be193556.js +0 -245
- package/dist/razor-242f0a8f.js +0 -512
- package/dist/redis-9690c6ac.js +0 -298
- package/dist/redshift-6bdcdeaa.js +0 -806
- package/dist/restructuredtext-a08c1d20.js +0 -162
- package/dist/ruby-2247692b.js +0 -444
- package/dist/rust-1dffb4d5.js +0 -337
- package/dist/sb-136598e9.js +0 -110
- package/dist/scala-b1100fed.js +0 -353
- package/dist/scheme-038c8094.js +0 -114
- package/dist/scss-700d1b52.js +0 -244
- package/dist/shell-86c16e0f.js +0 -224
- package/dist/solidity-c05fdf3c.js +0 -1351
- package/dist/sophia-cd645d71.js +0 -190
- package/dist/sparql-01d9ec9c.js +0 -193
- package/dist/sql-4c33df41.js +0 -818
- package/dist/st-52cf1408.js +0 -414
- package/dist/swift-13c792ba.js +0 -315
- package/dist/systemverilog-0bd8b730.js +0 -556
- package/dist/tcl-463d7c75.js +0 -232
- package/dist/tsMode-bf606946.js +0 -811
- package/dist/twig-0d98f5ec.js +0 -323
- package/dist/typescript-9ed04bdd.js +0 -328
- package/dist/vb-3a2b0a51.js +0 -364
- package/dist/wgsl-b2ddb3e4.js +0 -420
- package/dist/xml-825eaa31.js +0 -95
- package/dist/yaml-c9fb7842.js +0 -184
|
@@ -6,4 +6,4 @@ import { DraggableWrapperProps } from './types';
|
|
|
6
6
|
* 2. dragSelector will be used to identify the grabbable button that will grab the div to drag
|
|
7
7
|
* 3. parentRef is the reference point from which we will derive the base top:0 ,left: 0 position
|
|
8
8
|
*/
|
|
9
|
-
export default function DraggableWrapper({ children, zIndex, positionVariant, dragSelector, parentRef, boundaryGap, childDivProps, }: DraggableWrapperProps): JSX.Element;
|
|
9
|
+
export default function DraggableWrapper({ children, zIndex, positionVariant, dragSelector, parentRef, boundaryGap, childDivProps, layoutFixDelta }: DraggableWrapperProps): JSX.Element;
|
|
@@ -5,7 +5,10 @@ export declare enum DraggablePositionVariant {
|
|
|
5
5
|
}
|
|
6
6
|
export interface DraggableWrapperProps {
|
|
7
7
|
children: ReactNode;
|
|
8
|
-
|
|
8
|
+
/**
|
|
9
|
+
* Support for passing the direct value or calc functions as well
|
|
10
|
+
*/
|
|
11
|
+
zIndex?: number | string;
|
|
9
12
|
positionVariant?: DraggablePositionVariant;
|
|
10
13
|
/**
|
|
11
14
|
* dragSelector (class - (append with .), id, etc) will be used to identify the grabbable button that will grab the div to drag
|
|
@@ -14,6 +17,10 @@ export interface DraggableWrapperProps {
|
|
|
14
17
|
parentRef?: RefObject<HTMLDivElement>;
|
|
15
18
|
boundaryGap?: number;
|
|
16
19
|
childDivProps?: HTMLAttributes<HTMLDivElement>;
|
|
20
|
+
/**
|
|
21
|
+
* Delta for fixing the scrollable layout positioning
|
|
22
|
+
*/
|
|
23
|
+
layoutFixDelta?: number;
|
|
17
24
|
}
|
|
18
25
|
/**
|
|
19
26
|
* dragClassName is the class that we feed to Draggable to identify dragging buttons
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export { default as useUrlFilters } from './useUrlFilters';
|
|
2
|
-
export type { UseUrlFiltersProps } from './types';
|
|
2
|
+
export type { UseUrlFiltersProps, UseUrlFiltersReturnType } from './types';
|
|
@@ -1,6 +1,59 @@
|
|
|
1
|
-
|
|
1
|
+
import { SortingOrder } from '../../Constants';
|
|
2
|
+
export interface UseUrlFiltersProps<T, K> {
|
|
2
3
|
/**
|
|
3
4
|
* The key on which the sorting should be applied
|
|
4
5
|
*/
|
|
5
6
|
initialSortKey?: T;
|
|
7
|
+
/**
|
|
8
|
+
* Callback function for parsing the search params
|
|
9
|
+
*/
|
|
10
|
+
parseSearchParams?: (searchParams: URLSearchParams) => K;
|
|
6
11
|
}
|
|
12
|
+
export type UseUrlFiltersReturnType<T, K = unknown> = K & {
|
|
13
|
+
/**
|
|
14
|
+
* Currently applied page size
|
|
15
|
+
*/
|
|
16
|
+
pageSize: number;
|
|
17
|
+
/**
|
|
18
|
+
* Handler for updating the current page
|
|
19
|
+
*/
|
|
20
|
+
changePage: (pageNumber: number) => void;
|
|
21
|
+
/**
|
|
22
|
+
* Handler for updating the current page size
|
|
23
|
+
*/
|
|
24
|
+
changePageSize: (pageSize: number) => void;
|
|
25
|
+
/**
|
|
26
|
+
* Current search key
|
|
27
|
+
*/
|
|
28
|
+
searchKey: string;
|
|
29
|
+
/**
|
|
30
|
+
* Handler for updating the search
|
|
31
|
+
*/
|
|
32
|
+
handleSearch: (searchKey: string) => void;
|
|
33
|
+
/**
|
|
34
|
+
* Computed offset using the pageSize and pageNumber
|
|
35
|
+
*
|
|
36
|
+
* Note: Used in pagination component
|
|
37
|
+
*/
|
|
38
|
+
offset: number;
|
|
39
|
+
/**
|
|
40
|
+
* Key on which the sorting is applied
|
|
41
|
+
*/
|
|
42
|
+
sortBy: T;
|
|
43
|
+
/**
|
|
44
|
+
* Current sort order
|
|
45
|
+
*/
|
|
46
|
+
sortOrder: SortingOrder;
|
|
47
|
+
/**
|
|
48
|
+
* Handle the sorting type change / key change
|
|
49
|
+
*/
|
|
50
|
+
handleSorting: (sortBy: T) => void;
|
|
51
|
+
/**
|
|
52
|
+
* Clear all the applied filters
|
|
53
|
+
*/
|
|
54
|
+
clearFilters: () => void;
|
|
55
|
+
/**
|
|
56
|
+
* Update the search params with the passed object
|
|
57
|
+
*/
|
|
58
|
+
updateSearchParams: (paramsToSerialize: K) => void;
|
|
59
|
+
};
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { UseUrlFiltersProps } from './types';
|
|
1
|
+
import { UseUrlFiltersProps, UseUrlFiltersReturnType } from './types';
|
|
3
2
|
/**
|
|
4
3
|
* Generic hook for implementing URL based filters.
|
|
5
4
|
* eg: pagination, search, sort.
|
|
@@ -17,16 +16,5 @@ import { UseUrlFiltersProps } from './types';
|
|
|
17
16
|
* ```
|
|
18
17
|
*
|
|
19
18
|
*/
|
|
20
|
-
declare const useUrlFilters: <T = string>({ initialSortKey }?: UseUrlFiltersProps<T>) =>
|
|
21
|
-
pageSize: number;
|
|
22
|
-
changePage: (page: number) => void;
|
|
23
|
-
changePageSize: (_pageSize: number) => void;
|
|
24
|
-
searchKey: string;
|
|
25
|
-
handleSearch: (searchTerm: string) => void;
|
|
26
|
-
offset: number;
|
|
27
|
-
sortBy: T;
|
|
28
|
-
sortOrder: SortingOrder;
|
|
29
|
-
handleSorting: (_sortBy: T) => void;
|
|
30
|
-
clearFilters: () => void;
|
|
31
|
-
};
|
|
19
|
+
declare const useUrlFilters: <T = string, K = unknown>({ initialSortKey, parseSearchParams, }?: UseUrlFiltersProps<T, K>) => UseUrlFiltersReturnType<T, K>;
|
|
32
20
|
export default useUrlFilters;
|
package/dist/Common/Types.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ import React, { ReactNode, CSSProperties } from 'react';
|
|
|
2
2
|
import { Placement } from 'tippy.js';
|
|
3
3
|
import { ImageComment, ReleaseTag } from './ImageTags.Types';
|
|
4
4
|
import { DockerConfigOverrideType, SortingOrder, TaskErrorObj } from '.';
|
|
5
|
+
import { RegistryType } from '../Shared';
|
|
5
6
|
/**
|
|
6
7
|
* Generic response type object with support for overriding the result type
|
|
7
8
|
*
|
|
@@ -247,7 +248,7 @@ export interface CDMaterialType {
|
|
|
247
248
|
imageReleaseTags?: ReleaseTag[];
|
|
248
249
|
artifactStatus?: string;
|
|
249
250
|
filterState: FilterStates;
|
|
250
|
-
registryType?:
|
|
251
|
+
registryType?: RegistryType;
|
|
251
252
|
imagePath?: string;
|
|
252
253
|
registryName?: string;
|
|
253
254
|
scanToolId?: number;
|
|
@@ -341,7 +342,6 @@ export interface CommonNodeAttr {
|
|
|
341
342
|
};
|
|
342
343
|
appReleaseTagNames?: string[];
|
|
343
344
|
tagsEditable?: boolean;
|
|
344
|
-
isGitOpsRepoNotConfigured?: boolean;
|
|
345
345
|
deploymentAppCreated?: boolean;
|
|
346
346
|
isLast?: boolean;
|
|
347
347
|
downstreamEnvironments?: DownstreamNodesEnvironmentsType[];
|
package/dist/Common/index.d.ts
CHANGED
|
@@ -37,7 +37,6 @@ export * from './ImageTags.Types';
|
|
|
37
37
|
export * from './ResizableTextarea';
|
|
38
38
|
export { default as DebouncedSearch } from './DebouncedSearch/DebouncedSearch';
|
|
39
39
|
export { default as Grid } from './Grid/Grid';
|
|
40
|
-
export { default as CodeEditor } from './CodeEditor/CodeEditor';
|
|
41
40
|
export { default as Select } from './Select/Select';
|
|
42
41
|
export { default as ClipboardButton } from './ClipboardButton/ClipboardButton';
|
|
43
42
|
export * from './Hooks';
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
export declare enum UserListSortableKeys {
|
|
2
|
+
email = "email_id",
|
|
3
|
+
lastLogin = "last_login"
|
|
4
|
+
}
|
|
1
5
|
/**
|
|
2
6
|
* User Status received from the API
|
|
3
7
|
*/
|
|
@@ -11,5 +15,5 @@ export declare enum UserStatusDto {
|
|
|
11
15
|
export declare enum UserStatus {
|
|
12
16
|
active = "active",
|
|
13
17
|
inactive = "inactive",
|
|
14
|
-
temporary = "
|
|
18
|
+
temporary = "temporaryAccess"
|
|
15
19
|
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { SortingParams } from '../../../Common';
|
|
2
|
+
import { UserListSortableKeys, UserStatus } from './constants';
|
|
3
|
+
export type BaseFilterQueryParams<T> = {
|
|
4
|
+
/**
|
|
5
|
+
* Offset for the list result
|
|
6
|
+
*/
|
|
7
|
+
offset?: number;
|
|
8
|
+
/**
|
|
9
|
+
* Number of items required in the list
|
|
10
|
+
*/
|
|
11
|
+
size?: number;
|
|
12
|
+
/**
|
|
13
|
+
* Search string (if any)
|
|
14
|
+
*/
|
|
15
|
+
searchKey?: string;
|
|
16
|
+
/**
|
|
17
|
+
* If true, all items are returned with any search / filtering applied without pagination
|
|
18
|
+
*/
|
|
19
|
+
showAll?: boolean;
|
|
20
|
+
} & SortingParams<T>;
|
|
21
|
+
export type UserListFilterParams = BaseFilterQueryParams<UserListSortableKeys> & {
|
|
22
|
+
status: UserStatus[];
|
|
23
|
+
};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { BulkSelectionDropdownItemsProps } from './types';
|
|
2
|
-
declare const BulkSelectionDropdownItems: <T>({ locator, label, isSelected, handleBulkSelection, icon: Icon, }: BulkSelectionDropdownItemsProps<T>) => JSX.Element;
|
|
2
|
+
declare const BulkSelectionDropdownItems: <T>({ locator, label, isSelected, handleBulkSelection, icon: Icon, iconClass, }: BulkSelectionDropdownItemsProps<T>) => JSX.Element;
|
|
3
3
|
export default BulkSelectionDropdownItems;
|
|
@@ -2,7 +2,7 @@ export declare const BULK_DROPDOWN_TEST_ID: "bulk-selection-pop-up-menu";
|
|
|
2
2
|
export declare const BulkSelectionOptionsLabels: {
|
|
3
3
|
readonly SELECT_ALL_ON_PAGE: "All on this page";
|
|
4
4
|
readonly SELECT_ALL_ACROSS_PAGES: "All across pages";
|
|
5
|
-
readonly CLEAR_ALL_SELECTIONS: "Clear selection";
|
|
5
|
+
readonly CLEAR_ALL_SELECTIONS: "Clear selection(s)";
|
|
6
6
|
};
|
|
7
7
|
export declare const SELECT_ALL_ACROSS_PAGES_LOCATOR: "*";
|
|
8
8
|
export declare const getInvalidActionMessage: (action: string) => string;
|
|
@@ -23,6 +23,8 @@ export interface GetBulkSelectionCheckboxValuesType {
|
|
|
23
23
|
export interface UseBulkSelectionReturnType<T> extends GetBulkSelectionCheckboxValuesType {
|
|
24
24
|
selectedIdentifiers: T;
|
|
25
25
|
handleBulkSelection: ({ action, data }: HandleBulkSelectionType<T>) => void;
|
|
26
|
+
isBulkSelectionApplied: boolean;
|
|
27
|
+
getSelectedIdentifiersCount: () => number;
|
|
26
28
|
}
|
|
27
29
|
export interface BulkSelectionProps {
|
|
28
30
|
showPagination: boolean;
|
|
@@ -32,6 +34,7 @@ export interface BulkSelectionDropdownItemsType {
|
|
|
32
34
|
label: string;
|
|
33
35
|
isSelected: boolean;
|
|
34
36
|
icon: React.FunctionComponent<React.SVGProps<SVGSVGElement>>;
|
|
37
|
+
iconClass?: string;
|
|
35
38
|
}
|
|
36
39
|
export interface BulkSelectionDropdownItemsProps<T> extends BulkSelectionDropdownItemsType, Pick<UseBulkSelectionReturnType<T>, 'handleBulkSelection'> {
|
|
37
40
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ExcludedImageNode } from './ExcludedImageNode';
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { FilterChipsProps } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* Component for rendering the applied filter chips
|
|
4
|
+
*/
|
|
5
|
+
declare const FilterChips: ({ filterConfig, clearFilters, onRemoveFilter, getFormattedLabel, getFormattedValue, }: FilterChipsProps) => JSX.Element;
|
|
6
|
+
export default FilterChips;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
export interface FilterChipProps {
|
|
3
|
+
/**
|
|
4
|
+
* Filter label
|
|
5
|
+
*/
|
|
6
|
+
label: string;
|
|
7
|
+
/**
|
|
8
|
+
* Corresponding value of the filter
|
|
9
|
+
*/
|
|
10
|
+
value: unknown;
|
|
11
|
+
/**
|
|
12
|
+
* Callback handler for removing the filter
|
|
13
|
+
*/
|
|
14
|
+
handleRemoveFilter: (label: string, valueToRemove: unknown) => void;
|
|
15
|
+
/**
|
|
16
|
+
* If passed, the label will be formatted accordingly
|
|
17
|
+
*/
|
|
18
|
+
getFormattedLabel?: (filterKey: string) => ReactNode;
|
|
19
|
+
/**
|
|
20
|
+
* If passed, the label will be formatted accordingly
|
|
21
|
+
*/
|
|
22
|
+
getFormattedValue?: (filterKey: string, filterValue: unknown) => ReactNode;
|
|
23
|
+
}
|
|
24
|
+
export interface FilterChipsProps extends Pick<FilterChipProps, 'getFormattedLabel' | 'getFormattedValue'> {
|
|
25
|
+
/**
|
|
26
|
+
* Current filter configuration
|
|
27
|
+
*/
|
|
28
|
+
filterConfig: Record<string, unknown>;
|
|
29
|
+
/**
|
|
30
|
+
* Callback handler for removing the filters
|
|
31
|
+
*/
|
|
32
|
+
clearFilters: () => void;
|
|
33
|
+
/**
|
|
34
|
+
* Handler for removing a applied filter
|
|
35
|
+
*/
|
|
36
|
+
onRemoveFilter: (filterConfig: Record<string, unknown>) => void;
|
|
37
|
+
}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { ArtifactInfoProps } from '../types';
|
|
2
|
+
declare const ArtifactInfo: ({ imagePath, registryName, registryType, image, deployedTime, deployedBy, isRollbackTrigger, excludedImagePathNode, approvalChecksNode, approvalInfoTippy, }: ArtifactInfoProps) => JSX.Element;
|
|
3
|
+
export default ArtifactInfo;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ArtifactInfo } from './ArtifactInfo';
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { ImageCardProps } from './types';
|
|
2
|
+
declare const ImageCard: ({ testIdLocator, cta, sequentialCDCardTitleProps, artifactInfoProps, imageTagContainerProps, children, rootClassName, materialInfoRootClassName, }: ImageCardProps) => JSX.Element;
|
|
3
|
+
export default ImageCard;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as DeploymentEnvState } from './DeploymentEnvState';
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { SequentialCDCardTitleProps } from '../types';
|
|
2
|
+
declare const SequentialCDCardTitle: ({ isLatest, isRunningOnParentCD, artifactStatus, environmentName, parentEnvironmentName, stageType, showLatestTag, isVirtualEnvironment, }: SequentialCDCardTitleProps) => JSX.Element;
|
|
3
|
+
export default SequentialCDCardTitle;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as SequentialCDCardTitle } from './SequentialCDCardTitle';
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { ImageTaggingContainerType } from '../../../Common';
|
|
3
|
+
import { RegistryType } from '../..';
|
|
4
|
+
export interface ArtifactInfoProps {
|
|
5
|
+
imagePath: string;
|
|
6
|
+
registryName: string;
|
|
7
|
+
registryType: RegistryType;
|
|
8
|
+
image: string;
|
|
9
|
+
deployedTime: string;
|
|
10
|
+
deployedBy: string;
|
|
11
|
+
isRollbackTrigger: boolean;
|
|
12
|
+
excludedImagePathNode: ReactNode;
|
|
13
|
+
approvalChecksNode?: ReactNode;
|
|
14
|
+
approvalInfoTippy?: ReactNode;
|
|
15
|
+
}
|
|
16
|
+
export interface SequentialCDCardTitleProps {
|
|
17
|
+
isLatest: boolean;
|
|
18
|
+
isRunningOnParentCD: boolean;
|
|
19
|
+
artifactStatus: string;
|
|
20
|
+
environmentName: string;
|
|
21
|
+
parentEnvironmentName: string;
|
|
22
|
+
stageType: string;
|
|
23
|
+
showLatestTag: boolean;
|
|
24
|
+
isVirtualEnvironment: boolean;
|
|
25
|
+
}
|
|
26
|
+
export interface ImageCardProps {
|
|
27
|
+
testIdLocator: string;
|
|
28
|
+
sequentialCDCardTitleProps: SequentialCDCardTitleProps;
|
|
29
|
+
cta: ReactNode;
|
|
30
|
+
artifactInfoProps: ArtifactInfoProps;
|
|
31
|
+
imageTagContainerProps: ImageTaggingContainerType;
|
|
32
|
+
/**
|
|
33
|
+
* Meant for ImageCardAccordion
|
|
34
|
+
*/
|
|
35
|
+
children?: ReactNode;
|
|
36
|
+
rootClassName?: string;
|
|
37
|
+
materialInfoRootClassName?: string;
|
|
38
|
+
}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { ImageCardAccordionProps } from './types';
|
|
2
|
+
declare const ImageCardAccordion: ({ isSecurityModuleInstalled, artifactId, applicationId, environmentId, changesCard, isScanned, isScanEnabled, }: ImageCardAccordionProps) => JSX.Element;
|
|
3
|
+
export default ImageCardAccordion;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ImageCardAccordion } from './ImageCardAccordion';
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import React, { ReactNode } from 'react';
|
|
2
|
+
import { CDModalTabType, VulnerabilityType } from '../../../Common';
|
|
3
|
+
export interface ImageCardAccordionProps {
|
|
4
|
+
isSecurityModuleInstalled: boolean;
|
|
5
|
+
artifactId: number;
|
|
6
|
+
applicationId: number;
|
|
7
|
+
environmentId: number;
|
|
8
|
+
changesCard: ReactNode;
|
|
9
|
+
isScanned: boolean;
|
|
10
|
+
isScanEnabled: boolean;
|
|
11
|
+
}
|
|
12
|
+
export interface SecurityDetailsType {
|
|
13
|
+
vulnerabilities: VulnerabilityType[];
|
|
14
|
+
scanToolId: number;
|
|
15
|
+
lastExecution: string;
|
|
16
|
+
}
|
|
17
|
+
export interface AccordionItemProps {
|
|
18
|
+
currentTab: CDModalTabType;
|
|
19
|
+
activeTab: CDModalTabType;
|
|
20
|
+
setActiveTab: React.Dispatch<React.SetStateAction<CDModalTabType>>;
|
|
21
|
+
buttonText: string;
|
|
22
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ScannedByToolModal } from './ScannedByToolModal';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Vulnerabilities } from './Vulnerabilities';
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { VulnerabilityType } from '../../../Common';
|
|
2
|
+
interface LastExecutionResponseType {
|
|
3
|
+
code: number;
|
|
4
|
+
status: string;
|
|
5
|
+
result: {
|
|
6
|
+
scanExecutionId: number;
|
|
7
|
+
lastExecution: string;
|
|
8
|
+
appId?: number;
|
|
9
|
+
appName?: string;
|
|
10
|
+
envId?: number;
|
|
11
|
+
envName?: string;
|
|
12
|
+
pod?: string;
|
|
13
|
+
replicaSet?: string;
|
|
14
|
+
image?: string;
|
|
15
|
+
objectType: 'app' | 'chart';
|
|
16
|
+
scanned: boolean;
|
|
17
|
+
scanEnabled: boolean;
|
|
18
|
+
severityCount: {
|
|
19
|
+
critical: number;
|
|
20
|
+
moderate: number;
|
|
21
|
+
low: number;
|
|
22
|
+
};
|
|
23
|
+
vulnerabilities: VulnerabilityType[];
|
|
24
|
+
scanToolId?: number;
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
export declare function getLastExecutionByArtifactAppEnv(artifact: string | number, appId: number | string, envId: number | string): Promise<LastExecutionResponseType>;
|
|
28
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export interface VulnerabilitiesProps {
|
|
3
|
+
isScanned: boolean;
|
|
4
|
+
isScanEnabled: boolean;
|
|
5
|
+
artifactId: number;
|
|
6
|
+
applicationId: number;
|
|
7
|
+
environmentId: number;
|
|
8
|
+
setVulnerabilityCount: React.Dispatch<React.SetStateAction<number>>;
|
|
9
|
+
}
|
|
@@ -1,3 +1,9 @@
|
|
|
1
1
|
export * from './APIResponseHandler';
|
|
2
2
|
export * from './ReactSelect';
|
|
3
3
|
export * from './BulkSelection';
|
|
4
|
+
export * from './ImageCard';
|
|
5
|
+
export * from './ImageCardAccordion';
|
|
6
|
+
export * from './ExcludedImageNode';
|
|
7
|
+
export * from './ScannedByToolModal';
|
|
8
|
+
export * from './Vulnerabilities';
|
|
9
|
+
export * from './FilterChips';
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export declare const ARTIFACT_STATUS: {
|
|
2
|
+
PROGRESSING: string;
|
|
3
|
+
DEGRADED: string;
|
|
4
|
+
FAILED: string;
|
|
5
|
+
};
|
|
6
|
+
export declare const STAGE_TYPE: {
|
|
7
|
+
CD: string;
|
|
8
|
+
CI: string;
|
|
9
|
+
GIT: string;
|
|
10
|
+
PRECD: string;
|
|
11
|
+
POSTCD: string;
|
|
12
|
+
ROLLBACK: string;
|
|
13
|
+
};
|
|
14
|
+
export declare const SCAN_TOOL_ID_TRIVY = 3;
|
|
15
|
+
export declare const IMAGE_SCAN_TOOL: {
|
|
16
|
+
Clair: string;
|
|
17
|
+
Trivy: string;
|
|
18
|
+
};
|
|
19
|
+
export declare const EXCLUDED_IMAGE_TOOLTIP = "This image is excluded for new deployment as it does not match the filter conditions configured for this environment.";
|
package/dist/Shared/index.d.ts
CHANGED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export declare enum RegistryType {
|
|
2
|
+
GIT = "git",
|
|
3
|
+
GITHUB = "github",
|
|
4
|
+
GITLAB = "gitlab",
|
|
5
|
+
BITBUCKET = "bitbucket",
|
|
6
|
+
DOCKER = "docker",
|
|
7
|
+
DOCKER_HUB = "docker-hub",
|
|
8
|
+
ACR = "acr",
|
|
9
|
+
QUAY = "quay",
|
|
10
|
+
ECR = "ecr",
|
|
11
|
+
ARTIFACT_REGISTRY = "artifact-registry",
|
|
12
|
+
GCR = "gcr",
|
|
13
|
+
OTHER = "other"
|
|
14
|
+
}
|
|
15
|
+
export declare enum DefaultUserKey {
|
|
16
|
+
system = "system",
|
|
17
|
+
admin = "admin"
|
|
18
|
+
}
|
|
19
|
+
export declare enum Severity {
|
|
20
|
+
CRITICAL = "critical",
|
|
21
|
+
MODERATE = "moderate",
|
|
22
|
+
LOW = "low"
|
|
23
|
+
}
|