@devtron-labs/devtron-fe-common-lib 0.1.18-beta-1 → 0.1.18-beta-2

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 (50) hide show
  1. package/dist/Common/Constants.d.ts +7 -0
  2. package/dist/Common/CustomTagSelector/TagDetails.d.ts +1 -1
  3. package/dist/Common/CustomTagSelector/TagLabelSelect.d.ts +1 -1
  4. package/dist/Common/CustomTagSelector/Types.d.ts +0 -7
  5. package/dist/Common/SearchBar/SearchBar.component.d.ts +1 -1
  6. package/dist/Common/SearchBar/types.d.ts +2 -4
  7. package/dist/Common/Security/ScanVulnerabilitiesTable.d.ts +1 -1
  8. package/dist/Common/Security/types.d.ts +4 -0
  9. package/dist/Common/Types.d.ts +2 -2
  10. package/dist/Shared/Components/CICDHistory/constants.d.ts +0 -2
  11. package/dist/Shared/Components/CICDHistory/types.d.ts +0 -31
  12. package/dist/Shared/Components/CICDHistory/utils.d.ts +1 -2
  13. package/dist/Shared/Components/FilterButton/FilterButton.d.ts +5 -0
  14. package/dist/Shared/Components/FilterButton/index.d.ts +1 -0
  15. package/dist/Shared/Components/FilterButton/types.d.ts +12 -0
  16. package/dist/Shared/Components/FilterButton/utils.d.ts +15 -0
  17. package/dist/Shared/Components/GitCommitInfoGeneric/GitMaterialInfoHeader.d.ts +0 -1
  18. package/dist/Shared/Components/MaterialHistory/MaterialHistory.component.d.ts +1 -1
  19. package/dist/Shared/Components/MaterialHistory/types.d.ts +0 -1
  20. package/dist/Shared/Components/Vulnerabilities/utils.d.ts +1 -0
  21. package/dist/Shared/Components/index.d.ts +1 -1
  22. package/dist/Shared/Helpers.d.ts +0 -2
  23. package/dist/Shared/constants.d.ts +0 -1
  24. package/dist/Shared/types.d.ts +12 -7
  25. package/dist/assets/index.css +1 -1
  26. package/dist/{cssMode-dd9c8938.js → cssMode-39959d48.js} +1 -1
  27. package/dist/{freemarker2-bfde4a40.js → freemarker2-6311b9fa.js} +1 -1
  28. package/dist/{handlebars-3baf2a17.js → handlebars-0138e9ef.js} +1 -1
  29. package/dist/{html-131d3751.js → html-a5b8df32.js} +1 -1
  30. package/dist/{htmlMode-811dc567.js → htmlMode-563a1e1f.js} +1 -1
  31. package/dist/{index-fba1e081.js → index-f1286a73.js} +20617 -20803
  32. package/dist/index.d.ts +1 -2
  33. package/dist/index.js +478 -482
  34. package/dist/{javascript-e54c5226.js → javascript-58b90a5d.js} +1 -1
  35. package/dist/{jsonMode-45645d08.js → jsonMode-ab3b2334.js} +1 -1
  36. package/dist/{liquid-11d98806.js → liquid-291b40fd.js} +1 -1
  37. package/dist/{mdx-b3597be3.js → mdx-af564f98.js} +1 -1
  38. package/dist/{python-f03458e8.js → python-cce24e87.js} +1 -1
  39. package/dist/{razor-c2be26db.js → razor-5c83c35b.js} +1 -1
  40. package/dist/{tsMode-194a7065.js → tsMode-2808c7f5.js} +1 -1
  41. package/dist/{typescript-9b114ab0.js → typescript-15583804.js} +1 -1
  42. package/dist/{xml-f9b3f85b.js → xml-fae8c417.js} +1 -1
  43. package/dist/{yaml-99b078e9.js → yaml-5f7747f7.js} +1 -1
  44. package/package.json +1 -1
  45. package/dist/Common/SearchBar/utils.d.ts +0 -3
  46. package/dist/Shared/Components/CICDHistory/LogStageAccordion.d.ts +0 -4
  47. package/dist/Shared/Components/GitCommitInfoGeneric/constants.d.ts +0 -4
  48. package/dist/Shared/Components/ScannedObjectBar/ScannedObjectBar.d.ts +0 -4
  49. package/dist/Shared/Components/ScannedObjectBar/index.d.ts +0 -1
  50. package/dist/Shared/Components/ScannedObjectBar/types.d.ts +0 -7
@@ -267,3 +267,10 @@ export declare const DATE_TIME_FORMATS: {
267
267
  DD_MMM_YYYY_HH_MM: string;
268
268
  DD_MMM_YYYY: string;
269
269
  };
270
+ export declare const VULNERABILITIES_SORT_PRIORITY: {
271
+ critical: number;
272
+ high: number;
273
+ medium: number;
274
+ low: number;
275
+ unknown: number;
276
+ };
@@ -1,3 +1,3 @@
1
1
  import { TagDetailType } from './Types';
2
2
 
3
- export declare const TagDetails: ({ index, tagData, setTagData, removeTag, tabIndex, suggestedTagsOptions, hidePropagateTag, }: TagDetailType) => JSX.Element;
3
+ export declare const TagDetails: ({ index, tagData, setTagData, removeTag, tabIndex, suggestedTagsOptions, }: TagDetailType) => JSX.Element;
@@ -1,3 +1,3 @@
1
1
  import { TagLabelSelectType } from './Types';
2
2
 
3
- export declare const TagLabelSelect: ({ isCreateApp, labelTags, setLabelTags, tabIndex, hidePropagateTag }: TagLabelSelectType) => JSX.Element;
3
+ export declare const TagLabelSelect: ({ isCreateApp, labelTags, setLabelTags, tabIndex }: TagLabelSelectType) => JSX.Element;
@@ -21,11 +21,6 @@ export interface TagErrorType {
21
21
  isValid: boolean;
22
22
  messages: string[];
23
23
  }
24
- export declare enum APP_TYPE {
25
- HELM_CHART = "helm-chart",
26
- DEVTRON_APPS = "app",
27
- JOB = "job"
28
- }
29
24
  export interface TagLabelSelectType {
30
25
  isCreateApp?: boolean;
31
26
  labelTags: TagType[];
@@ -34,7 +29,6 @@ export interface TagLabelSelectType {
34
29
  selectedProjectId?: number;
35
30
  suggestedTagsOptions?: SuggestedTagOptionType[];
36
31
  reloadProjectTags?: boolean;
37
- hidePropagateTag?: boolean;
38
32
  }
39
33
  export interface TagDetailType {
40
34
  index: number;
@@ -43,7 +37,6 @@ export interface TagDetailType {
43
37
  removeTag?: (index: number) => void;
44
38
  tabIndex?: number;
45
39
  suggestedTagsOptions?: SuggestedTagOptionType[];
46
- hidePropagateTag?: boolean;
47
40
  }
48
41
  export interface TagLabelValueSelectorType {
49
42
  selectedTagIndex: number;
@@ -34,5 +34,5 @@ import { SearchBarProps } from './types';
34
34
  * <SearchBar inputProps={{ placeholder: 'Enter search text' }} />
35
35
  * ```
36
36
  */
37
- declare const SearchBar: ({ initialSearchText, handleSearchChange, handleEnter, inputProps, containerClassName, shouldDebounce, debounceTimeout, dataTestId, noBackgroundAndBorder, size, }: SearchBarProps) => JSX.Element;
37
+ declare const SearchBar: ({ initialSearchText, handleSearchChange, handleEnter, inputProps, containerClassName, shouldDebounce, debounceTimeout, dataTestId, noBackgroundAndBorder, componentSize, }: SearchBarProps) => JSX.Element;
38
38
  export default SearchBar;
@@ -42,9 +42,7 @@ export interface SearchBarProps {
42
42
  */
43
43
  noBackgroundAndBorder?: boolean;
44
44
  /**
45
- * Height of the searchbar
46
- *
47
- * @default 'ComponentSizeType.medium'
45
+ * Height of the Search bar, Large is 36px and Medium is 32px
48
46
  */
49
- size?: ComponentSizeType.medium | ComponentSizeType.large;
47
+ componentSize?: ComponentSizeType.large | ComponentSizeType.medium;
50
48
  }
@@ -1,3 +1,3 @@
1
1
  import { ScanVulnerabilitiesTableProps } from '../Types';
2
2
 
3
- export default function ScanVulnerabilitiesTable({ vulnerabilities, hidePolicy, shouldStick }: ScanVulnerabilitiesTableProps): JSX.Element;
3
+ export default function ScanVulnerabilitiesTable({ vulnerabilities, hidePolicy, shouldStick, }: ScanVulnerabilitiesTableProps): JSX.Element;
@@ -0,0 +1,4 @@
1
+ export declare enum VulnerabilitiesTableSortKeys {
2
+ SEVERITY = "severity",
3
+ PACKAGE = "package"
4
+ }
@@ -2,7 +2,7 @@ import { default as React, ReactNode, CSSProperties } from 'react';
2
2
  import { Placement } from 'tippy.js';
3
3
  import { ImageComment, ReleaseTag } from './ImageTags.Types';
4
4
  import { ACTION_STATE, DEPLOYMENT_WINDOW_TYPE, DockerConfigOverrideType, SortingOrder, TaskErrorObj } from '.';
5
- import { RegistryType } from '../Shared';
5
+ import { RegistryType, Severity } from '../Shared';
6
6
 
7
7
  /**
8
8
  * Generic response type object with support for overriding the result type
@@ -492,7 +492,7 @@ export declare enum DeploymentAppTypes {
492
492
  }
493
493
  export interface VulnerabilityType {
494
494
  name: string;
495
- severity: 'CRITICAL' | 'MODERATE' | 'LOW';
495
+ severity: Severity;
496
496
  package: string;
497
497
  version: string;
498
498
  fixedVersion: string;
@@ -43,5 +43,3 @@ export declare const DEFAULT_ENV = "devtron-ci";
43
43
  export declare const LOGS_RETRY_COUNT = 3;
44
44
  export declare const DEPLOYMENT_STATUS_QUERY_PARAM = "deployment-status";
45
45
  export declare const MANIFEST_STATUS_HEADERS: string[];
46
- export declare const LOGS_STAGE_IDENTIFIER = "STAGE_INFO";
47
- export declare const LOGS_STAGE_STREAM_SEPARATOR = "|";
@@ -584,37 +584,6 @@ export interface TriggerHistoryFilterCriteriaProps {
584
584
  releaseId: number;
585
585
  showCurrentReleaseDeployments: boolean;
586
586
  }
587
- export declare enum StageStatusType {
588
- SUCCESS = "Success",
589
- FAILURE = "Failure",
590
- /**
591
- * Not given in API response
592
- */
593
- PROGRESSING = "Progressing"
594
- }
595
- export interface StageInfoDTO {
596
- stage: string;
597
- startTime: string;
598
- endTime?: string;
599
- status?: StageStatusType;
600
- }
601
- export interface StageDetailType extends Pick<StageInfoDTO, 'stage' | 'startTime' | 'endTime' | 'status'> {
602
- logs: string[];
603
- isOpen: boolean;
604
- }
605
- export interface LogStageAccordionProps extends StageDetailType {
606
- handleStageClose: (index: number) => void;
607
- handleStageOpen: (index: number) => void;
608
- stageIndex: number;
609
- /**
610
- * A stage is loading if it is last in current stage list and event is not closed
611
- */
612
- isLoading: boolean;
613
- }
614
- export interface CreateMarkupReturnType {
615
- __html: string;
616
- isSearchKeyPresent: boolean;
617
- }
618
587
  export type TriggerHistoryFilterCriteriaType = `${string}|${string}|${string}`[];
619
588
  export declare const terminalStatus: Set<string>;
620
589
  export declare const statusSet: Set<string>;
@@ -1,7 +1,6 @@
1
- import { TriggerHistoryFilterCriteriaProps, DeploymentHistoryResultObject, TriggerHistoryFilterCriteriaType, StageStatusType } from './types';
1
+ import { TriggerHistoryFilterCriteriaProps, DeploymentHistoryResultObject, TriggerHistoryFilterCriteriaType } from './types';
2
2
 
3
3
  export declare const getTriggerHistoryFilterCriteria: ({ appId, envId, releaseId, showCurrentReleaseDeployments, }: TriggerHistoryFilterCriteriaProps) => TriggerHistoryFilterCriteriaType;
4
4
  export declare const getParsedTriggerHistory: (result: any) => DeploymentHistoryResultObject;
5
5
  export declare const buildHoverHtmlForWebhook: (eventName: any, condition: any, selectors: any) => JSX.Element;
6
6
  export declare const renderIcon: (iconState: string) => JSX.Element;
7
- export declare const getStageStatusIcon: (status: StageStatusType) => JSX.Element;
@@ -0,0 +1,5 @@
1
+ import { default as React } from 'react';
2
+ import { FilterButtonPropsType } from './types';
3
+
4
+ declare const FilterButton: React.FC<FilterButtonPropsType>;
5
+ export default FilterButton;
@@ -0,0 +1 @@
1
+ export { default as FilterButton } from './FilterButton';
@@ -0,0 +1,12 @@
1
+ import { OptionType } from '../../../Common/Types';
2
+
3
+ export interface FilterButtonPropsType {
4
+ placeholder: string;
5
+ appliedFilters: string[];
6
+ options: OptionType[];
7
+ handleApplyChange: (selectedOptions: string[]) => void;
8
+ disabled?: boolean;
9
+ getFormattedFilterLabelValue?: (identifier: string) => string;
10
+ menuAlignFromRight?: boolean;
11
+ controlWidth?: string;
12
+ }
@@ -0,0 +1,15 @@
1
+ export declare const getFilterStyle: (controlWidth?: string, menuAlignFromRight?: boolean) => {
2
+ menu: (base: any) => any;
3
+ control: (base: any, state: any) => any;
4
+ container: (base: any) => any;
5
+ singleValue: (base: any) => any;
6
+ option: (base: any, state: any) => any;
7
+ valueContainer: (base: any) => any;
8
+ dropdownIndicator: (base: any, state: any) => any;
9
+ group: (base: any) => any;
10
+ groupHeading: (base: any) => any;
11
+ menuList: (base: any) => any;
12
+ multiValue: (base: any) => any;
13
+ multiValueLabel: (base: any) => any;
14
+ placeholder: (base: any) => any;
15
+ };
@@ -1,4 +1,3 @@
1
-
2
1
  declare const GitMaterialInfoHeader: ({ index, repoUrl, materialType, materialValue, style, ...props }: {
3
2
  [x: string]: any;
4
3
  index: any;
@@ -1,4 +1,4 @@
1
1
  import { MaterialHistoryProps } from './types';
2
2
 
3
- declare const MaterialHistory: ({ material, pipelineName, ciPipelineId, selectCommit, isCommitInfoModal, }: MaterialHistoryProps) => JSX.Element;
3
+ declare const MaterialHistory: ({ material, pipelineName, ciPipelineId, selectCommit }: MaterialHistoryProps) => JSX.Element;
4
4
  export default MaterialHistory;
@@ -5,5 +5,4 @@ export interface MaterialHistoryProps {
5
5
  pipelineName: string;
6
6
  ciPipelineId?: string;
7
7
  selectCommit?: (materialId: string, commit: string, ciPipelineId?: string) => void;
8
- isCommitInfoModal?: boolean;
9
8
  }
@@ -1,4 +1,5 @@
1
1
  import { LastExecutionResponseType, LastExecutionResultType } from '../../types';
2
2
 
3
+ export declare const getSortedVulnerabilities: (vulnerabilities: any) => any;
3
4
  export declare const getParsedScanResult: (scanResult: any) => LastExecutionResultType;
4
5
  export declare const parseLastExecutionResponse: (response: any) => LastExecutionResponseType;
@@ -10,7 +10,6 @@ export * from './FilterChips';
10
10
  export * from './ActivityIndicator';
11
11
  export * from './GenericSectionErrorState';
12
12
  export * from './KeyValueList';
13
- export * from './ScannedObjectBar';
14
13
  export * from './InfoIconTippy';
15
14
  export * from './EditableTextArea';
16
15
  export * from './Header';
@@ -34,3 +33,4 @@ export * from './Plugin';
34
33
  export * from './KeyValueTable';
35
34
  export * from './SelectPicker';
36
35
  export * from './DetectBottom';
36
+ export * from './FilterButton';
@@ -32,7 +32,5 @@ export declare const renderValidInputButtonTippy: (children: ReactElement) => JS
32
32
  export declare const processDeploymentStatusDetailsData: (data?: DeploymentStatusDetailsType) => DeploymentStatusDetailsBreakdownDataType;
33
33
  export declare function aggregateNodes(nodes: any[], podMetadata: PodMetadatum[]): AggregatedNodes;
34
34
  export declare const decode: (data: any, isEncoded?: boolean) => {};
35
- export declare const isTimeStringAvailable: (time: string) => boolean;
36
- export declare const getTimeDifference: (startTime: string, endTime: string) => string;
37
35
  export declare const getFileNameFromHeaders: (headers: Headers) => string;
38
36
  export {};
@@ -354,7 +354,6 @@ export declare enum K8sResourcePayloadAppType {
354
354
  HELM_APP = 1,
355
355
  EXTERNAL_ARGO_APP = 2
356
356
  }
357
- export declare const ANSI_UP_REGEX: RegExp;
358
357
  /**
359
358
  * Size variants for components
360
359
  */
@@ -202,8 +202,10 @@ export declare enum DefaultUserKey {
202
202
  }
203
203
  export declare enum Severity {
204
204
  CRITICAL = "critical",
205
- MODERATE = "moderate",
206
- LOW = "low"
205
+ HIGH = "high",
206
+ MEDIUM = "medium",
207
+ LOW = "low",
208
+ UNKNOWN = "unknown"
207
209
  }
208
210
  export declare enum ImagePromotionTabs {
209
211
  REQUEST = "request",
@@ -369,13 +371,16 @@ export declare enum ResourceVersionType {
369
371
  v1 = "v1",
370
372
  alpha1 = "alpha1"
371
373
  }
374
+ export interface SeverityCount {
375
+ critical: number;
376
+ high: number;
377
+ medium: number;
378
+ low: number;
379
+ unknown: number;
380
+ }
372
381
  export interface LastExecutionResultType {
373
382
  lastExecution: string;
374
- severityCount: {
375
- critical: number;
376
- moderate: number;
377
- low: number;
378
- };
383
+ severityCount: SeverityCount;
379
384
  vulnerabilities: VulnerabilityType[];
380
385
  scanExecutionId?: number;
381
386
  appId?: number;