@devtron-labs/devtron-fe-common-lib 1.2.17-beta-3 → 1.2.17-beta-5

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.
@@ -13,7 +13,6 @@ export declare const DOCUMENTATION: {
13
13
  GLOBAL_CONFIG_BUILD_INFRA: string;
14
14
  };
15
15
  export declare const PATTERNS: {
16
- STRING: RegExp;
17
16
  NATURAL_NUMBERS: RegExp;
18
17
  KUBERNETES_KEY_PREFIX: RegExp;
19
18
  KUBERNETES_KEY_NAME: RegExp;
@@ -0,0 +1,2 @@
1
+ import { TagLabelSelectType } from './Types';
2
+ export declare const TagLabelSelect: ({ isCreateApp, labelTags, setLabelTags, tabIndex, hidePropagateTag }: TagLabelSelectType) => JSX.Element;
@@ -0,0 +1,12 @@
1
+ export declare const baseSelectStyles: {
2
+ control: (base: any, state: any) => any;
3
+ singleValue: (base: any, state: any) => any;
4
+ placeholder: (base: any, state: any) => any;
5
+ option: (base: any, state: any) => any;
6
+ dropdownIndicator: (styles: any) => any;
7
+ valueContainer: (base: any, state: any) => any;
8
+ indicatorsContainer: (base: any, state: any) => any;
9
+ menu: (base: any, state: any) => any;
10
+ };
11
+ export declare const validateKubernetesKey: (key: string) => void;
12
+ export declare const validateKubernetesValue: (value: string) => void;
@@ -5,16 +5,6 @@ export interface SuggestedTagOptionType extends OptionType {
5
5
  description: string;
6
6
  propagate: boolean;
7
7
  }
8
- export declare enum DeploymentPolicy {
9
- ALLOW = "allow",
10
- BLOCK = "block",
11
- BLOCK_PROD = "block-prod",
12
- BLOCK_NON_PROD = "block-non-prod"
13
- }
14
- export interface VariableValueConstraintTypes {
15
- choices?: string[];
16
- blockCustomValue?: boolean;
17
- }
18
8
  export interface TagType {
19
9
  id?: number;
20
10
  key: string;
@@ -26,8 +16,20 @@ export interface TagType {
26
16
  isInvalidValue?: boolean;
27
17
  isSuggested?: boolean;
28
18
  isPropagateDisabled?: boolean;
29
- deploymentPolicy?: DeploymentPolicy;
30
- valueConstraint?: VariableValueConstraintTypes;
19
+ }
20
+ export interface TagErrorType {
21
+ isValid: boolean;
22
+ messages: string[];
23
+ }
24
+ export interface TagLabelSelectType {
25
+ isCreateApp?: boolean;
26
+ labelTags: TagType[];
27
+ setLabelTags: (tagList: TagType[]) => void;
28
+ tabIndex?: number;
29
+ selectedProjectId?: number;
30
+ suggestedTagsOptions?: SuggestedTagOptionType[];
31
+ reloadProjectTags?: boolean;
32
+ hidePropagateTag?: boolean;
31
33
  }
32
34
  export interface TagDetailType {
33
35
  index: number;
@@ -1,6 +1,6 @@
1
1
  export { default as PropagateTagInfo } from './PropagateTagInfo';
2
2
  export * from './TagDetails';
3
+ export * from './TagLabelSelect';
3
4
  export * from './TagLabelValueSelector';
4
5
  export * from './ResizableTagTextArea';
5
6
  export * from './Types';
6
- export { validateTagKeyValue, validateTagValue } from './tags.utils';
@@ -1,6 +1,6 @@
1
1
  import { default as React, SyntheticEvent } from 'react';
2
2
  import { JSONPathOptions } from 'jsonpath-plus';
3
- import { AsyncOptions, DeploymentNodeType, UseSearchString } from './Types';
3
+ import { AsyncOptions, UseSearchString } from './Types';
4
4
  import { scrollableInterface } from '../Shared';
5
5
  import * as Sentry from '@sentry/browser';
6
6
  export declare function showError(serverError: any, showToastOnUnknownError?: boolean, hideAccessError?: boolean): void;
@@ -135,6 +135,5 @@ export declare const getSanitizedIframe: (iframeString: string) => string;
135
135
  * This method adds default attributes to iframe - title, loading ="lazy", width="100%", height="100%"
136
136
  */
137
137
  export declare const getIframeWithDefaultAttributes: (iframeString: string, defaultName?: string) => string;
138
- export declare const getStageTitle: (stageType: DeploymentNodeType) => string;
139
138
  export declare const getGoLangFormattedDateWithTimezone: (dateFormat: string) => string;
140
139
  export {};
@@ -2,4 +2,5 @@ export declare const FALLBACK_ENTITY: {
2
2
  color: string;
3
3
  label: string;
4
4
  value: number;
5
+ proportionalValue: string;
5
6
  };
@@ -2,10 +2,12 @@ export type Entity = {
2
2
  color: string;
3
3
  label: string;
4
4
  value: number;
5
+ proportionalValue?: string;
5
6
  };
6
7
  export interface SegmentedBarChartProps {
7
8
  entities: NonNullable<Entity[]>;
8
9
  rootClassName?: string;
9
10
  countClassName?: string;
10
11
  labelClassName?: string;
12
+ isProportional?: boolean;
11
13
  }
@@ -3,7 +3,7 @@ import { TippyProps } from '@tippyjs/react';
3
3
  import { Placement } from 'tippy.js';
4
4
  import { UserGroupDTO } from '../Pages/GlobalConfigurations';
5
5
  import { ImageComment, ReleaseTag } from './ImageTags.Types';
6
- import { MandatoryPluginBaseStateType, RegistryType, RuntimePluginVariables, Severity, PolicyBlockInfo } from '../Shared';
6
+ import { MandatoryPluginBaseStateType, RegistryType, RuntimePluginVariables, Severity } from '../Shared';
7
7
  import { ACTION_STATE, DEPLOYMENT_WINDOW_TYPE, DockerConfigOverrideType, RefVariableType, SortingOrder, TaskErrorObj, VariableTypeFormat } from '.';
8
8
  /**
9
9
  * Generic response type object with support for overriding the result type
@@ -433,10 +433,6 @@ export interface CDMaterialType {
433
433
  * Would currently only be received in case of release
434
434
  */
435
435
  appWorkflowId: number;
436
- /**
437
- * Denotes trigger blocking due to mandatory tags, (might be used for plugins and other features in future)
438
- */
439
- deploymentBlockedState?: PolicyBlockInfo;
440
436
  }
441
437
  export declare enum CDMaterialServiceEnum {
442
438
  ROLLBACK = "rollback",
@@ -473,15 +469,6 @@ export interface DownstreamNodesEnvironmentsType {
473
469
  environmentId: number;
474
470
  environmentName: string;
475
471
  }
476
- export declare enum TriggerBlockType {
477
- MANDATORY_TAG = "mandatory-tags",
478
- MANDATORY_PLUGIN = "mandatory-plugins",
479
- SECURITY_SCAN = "security-scan"
480
- }
481
- export interface TriggerBlockedInfo {
482
- blockedBy: TriggerBlockType;
483
- blockedReason?: string;
484
- }
485
472
  export interface CommonNodeAttr extends Pick<MandatoryPluginBaseStateType, 'isTriggerBlocked' | 'pluginBlockState'> {
486
473
  connectingCiPipelineId?: number;
487
474
  parents: string | number[] | string[];
@@ -544,7 +531,6 @@ export interface CommonNodeAttr extends Pick<MandatoryPluginBaseStateType, 'isTr
544
531
  downstreamEnvironments?: DownstreamNodesEnvironmentsType[];
545
532
  cipipelineId?: number;
546
533
  isDeploymentBlocked?: boolean;
547
- triggerBlockedInfo?: TriggerBlockedInfo;
548
534
  }
549
535
  export declare enum DeploymentAppTypes {
550
536
  HELM = "helm",
@@ -607,7 +593,6 @@ export interface CDMaterialsMetaInfo {
607
593
  * This is the ID of user that has request the material
608
594
  */
609
595
  requestedUserId: number;
610
- deploymentBlockedState?: PolicyBlockInfo;
611
596
  runtimeParams: RuntimePluginVariables[];
612
597
  }
613
598
  export interface ImagePromotionMaterialInfo {
@@ -686,7 +671,7 @@ export interface Strategy {
686
671
  config: any;
687
672
  default?: boolean;
688
673
  }
689
- export interface CDStage extends Partial<Pick<CommonNodeAttr, 'triggerBlockedInfo'>> {
674
+ export interface CDStage {
690
675
  status: string;
691
676
  name: string;
692
677
  triggerType: 'AUTOMATIC' | 'MANUAL';
@@ -696,14 +681,14 @@ export interface CDStageConfigMapSecretNames {
696
681
  configMaps: any[];
697
682
  secrets: any[];
698
683
  }
699
- export interface PrePostDeployStageType extends MandatoryPluginBaseStateType, Partial<Pick<CommonNodeAttr, 'triggerBlockedInfo'>> {
684
+ export interface PrePostDeployStageType extends MandatoryPluginBaseStateType {
700
685
  isValid: boolean;
701
686
  steps: TaskErrorObj[];
702
687
  triggerType: string;
703
688
  name: string;
704
689
  status: string;
705
690
  }
706
- export interface CdPipeline extends Partial<Pick<CommonNodeAttr, 'triggerBlockedInfo'>> {
691
+ export interface CdPipeline {
707
692
  id: number;
708
693
  environmentId: number;
709
694
  environmentName?: string;
@@ -735,7 +720,6 @@ export interface CdPipeline extends Partial<Pick<CommonNodeAttr, 'triggerBlocked
735
720
  isProdEnv?: boolean;
736
721
  isGitOpsRepoNotConfigured?: boolean;
737
722
  isDeploymentBlocked?: boolean;
738
- isTriggerBlocked?: boolean;
739
723
  }
740
724
  export interface ExternalCiConfig {
741
725
  id: number;
@@ -20,8 +20,6 @@ export type DynamicDataTableHeaderType<K extends string> = {
20
20
  isSortable?: boolean;
21
21
  /** An optional boolean to control the visibility of the column. */
22
22
  isHidden?: boolean;
23
- /** An optional boolean to show the column */
24
- renderAdditionalContent?: () => ReactNode;
25
23
  };
26
24
  export declare enum DynamicDataTableRowDataType {
27
25
  TEXT = "text",
@@ -46,5 +46,4 @@ export * from './EnterpriseTag';
46
46
  export * from './ConfirmationModal';
47
47
  export * from './DiffViewer';
48
48
  export * from './DynamicDataTable';
49
- export * from './TagsKeyValueTable';
50
49
  export * from './FileUpload';
@@ -1,5 +1,5 @@
1
1
  import { Dayjs } from 'dayjs';
2
- import { OptionType, CommonNodeAttr, ResponseType, UserApprovalConfigType, VulnerabilityType, DeploymentAppTypes, ServerErrors, SortingParams, TriggerBlockType, ValueConstraintType, VariableType, RefVariableType, PluginType } from '../Common';
2
+ import { OptionType, CommonNodeAttr, ResponseType, UserApprovalConfigType, VulnerabilityType, DeploymentAppTypes, ServerErrors, SortingParams, ValueConstraintType, VariableType, RefVariableType, PluginType } from '../Common';
3
3
  import { EnvironmentTypeEnum, PatchOperationType } from './constants';
4
4
  export declare enum EnvType {
5
5
  CHART = "helm_charts",
@@ -752,24 +752,6 @@ export interface PreventOutsideFocusProps {
752
752
  identifier: string;
753
753
  preventFocus: boolean;
754
754
  }
755
- export interface PolicyBlockInfo {
756
- isBlocked: boolean;
757
- blockedBy: TriggerBlockType;
758
- reason: string;
759
- }
760
- export interface PipelineStageBlockInfo {
761
- node: PolicyBlockInfo;
762
- pre: PolicyBlockInfo;
763
- post: PolicyBlockInfo;
764
- }
765
- export interface PolicyConsequencesDTO {
766
- cd: PipelineStageBlockInfo;
767
- ci: PipelineStageBlockInfo;
768
- }
769
- export interface GetPolicyConsequencesProps {
770
- appId: number;
771
- envId: number;
772
- }
773
755
  export interface UploadFileDTO {
774
756
  id: number;
775
757
  name: string;