@devtron-labs/devtron-fe-common-lib 0.1.16-beta-1 → 0.1.16-beta-3
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/Api.d.ts +1 -1
- package/dist/Common/CIPipeline.Types.d.ts +1 -0
- package/dist/Common/Constants.d.ts +2 -0
- package/dist/Common/CustomInput/Types.d.ts +2 -2
- package/dist/Common/Modals/VisibleModal.d.ts +1 -1
- package/dist/Common/Modals/VisibleModal2.d.ts +1 -1
- package/dist/Common/MultiSelectCustomization.d.ts +1 -1
- package/dist/Common/Types.d.ts +2 -2
- package/dist/Shared/Components/DetectBottom/DetectBottom.component.d.ts +2 -1
- package/dist/Shared/Components/EditImageFormField/EditImageFormField.d.ts +4 -0
- package/dist/Shared/Components/EditImageFormField/constants.d.ts +6 -0
- package/dist/Shared/Components/EditImageFormField/index.d.ts +2 -0
- package/dist/Shared/Components/EditImageFormField/types.d.ts +18 -0
- package/dist/Shared/Components/GitCommitInfoGeneric/GitMaterialInfoHeader.d.ts +0 -1
- package/dist/Shared/Components/MaterialHistory/MaterialHistory.component.d.ts +1 -1
- package/dist/Shared/Components/MaterialHistory/types.d.ts +0 -1
- package/dist/Shared/Components/Plugin/service.d.ts +3 -1
- package/dist/Shared/Components/Plugin/types.d.ts +8 -2
- package/dist/Shared/Components/Plugin/utils.d.ts +3 -0
- package/dist/Shared/Components/SelectPicker/SelectPicker.component.d.ts +1 -1
- package/dist/Shared/Components/SelectPicker/type.d.ts +10 -1
- package/dist/Shared/Components/index.d.ts +1 -0
- package/dist/Shared/constants.d.ts +1 -0
- package/dist/Shared/validations.d.ts +3 -0
- package/dist/assets/index.css +1 -1
- package/dist/{cssMode-6b5749e9.js → cssMode-9d46c29e.js} +1 -1
- package/dist/{freemarker2-e0fb10ce.js → freemarker2-f424b7d3.js} +1 -1
- package/dist/{handlebars-62af9221.js → handlebars-cd842efa.js} +1 -1
- package/dist/{html-b0e3e379.js → html-e195840d.js} +1 -1
- package/dist/{htmlMode-379fcbe4.js → htmlMode-90c6effe.js} +1 -1
- package/dist/{index-3748b21f.js → index-929341c0.js} +19505 -19370
- package/dist/index.d.ts +1 -0
- package/dist/index.js +378 -371
- package/dist/{javascript-b6335dbb.js → javascript-730d138b.js} +1 -1
- package/dist/{jsonMode-6f501f0a.js → jsonMode-595c0e49.js} +1 -1
- package/dist/{liquid-d84af754.js → liquid-4b1beab5.js} +1 -1
- package/dist/{mdx-4a5fb899.js → mdx-bd1f5806.js} +1 -1
- package/dist/{python-6c4bd907.js → python-e2cb1a69.js} +1 -1
- package/dist/{razor-4ae36407.js → razor-79753b32.js} +1 -1
- package/dist/{tsMode-12c1ae2a.js → tsMode-8951e816.js} +1 -1
- package/dist/{typescript-5f19ff23.js → typescript-50709c01.js} +1 -1
- package/dist/{xml-dc68f4b6.js → xml-b2530eaf.js} +1 -1
- package/dist/{yaml-094132f3.js → yaml-7b6c85c0.js} +1 -1
- package/package.json +1 -1
- package/dist/Shared/Components/GitCommitInfoGeneric/constants.d.ts +0 -4
package/dist/Common/Api.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ import { ResponseType, APIOptions } from './Types';
|
|
|
4
4
|
export declare const post: (url: string, data: object, options?: APIOptions, isMultipartRequest?: boolean) => Promise<ResponseType>;
|
|
5
5
|
export declare const put: (url: string, data: object, options?: APIOptions) => Promise<ResponseType>;
|
|
6
6
|
export declare const patch: (url: string, data: object, options?: APIOptions) => Promise<ResponseType>;
|
|
7
|
-
export declare const get: (url: string, options?: APIOptions) => Promise<ResponseType
|
|
7
|
+
export declare const get: <T = any>(url: string, options?: APIOptions) => Promise<ResponseType<T>>;
|
|
8
8
|
export declare const trash: (url: string, data?: object, options?: APIOptions) => Promise<ResponseType>;
|
|
9
9
|
/**
|
|
10
10
|
* Aborts the previous request before triggering next request
|
|
@@ -78,6 +78,7 @@ export declare const ROUTES: {
|
|
|
78
78
|
PLUGIN_GLOBAL_LIST_DETAIL_V2: string;
|
|
79
79
|
PLUGIN_GLOBAL_LIST_V2: string;
|
|
80
80
|
PLUGIN_GLOBAL_LIST_TAGS: string;
|
|
81
|
+
PLUGIN_LIST_MIN: string;
|
|
81
82
|
};
|
|
82
83
|
export declare enum KEY_VALUE {
|
|
83
84
|
KEY = "key",
|
|
@@ -267,3 +268,4 @@ export declare const DATE_TIME_FORMATS: {
|
|
|
267
268
|
DD_MMM_YYYY_HH_MM: string;
|
|
268
269
|
DD_MMM_YYYY: string;
|
|
269
270
|
};
|
|
271
|
+
export declare const SEMANTIC_VERSION_DOCUMENTATION_LINK = "https://semver.org/";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { default as React, HTMLInputTypeAttribute, InputHTMLAttributes } from 'react';
|
|
1
|
+
import { default as React, HTMLInputTypeAttribute, InputHTMLAttributes, ReactNode } from 'react';
|
|
2
2
|
|
|
3
3
|
export interface CustomInputProps {
|
|
4
4
|
name: string;
|
|
@@ -17,7 +17,7 @@ export interface CustomInputProps {
|
|
|
17
17
|
autoFocus?: boolean;
|
|
18
18
|
rootClassName?: string;
|
|
19
19
|
error?: string[] | string;
|
|
20
|
-
helperText?:
|
|
20
|
+
helperText?: ReactNode;
|
|
21
21
|
handleOnBlur?: (e: any) => void;
|
|
22
22
|
readOnly?: boolean;
|
|
23
23
|
noTrim?: boolean;
|
package/dist/Common/Types.d.ts
CHANGED
|
@@ -177,10 +177,10 @@ export interface RadioGroupItemProps {
|
|
|
177
177
|
export interface RadioGroupInterface {
|
|
178
178
|
name: string;
|
|
179
179
|
onChange: any;
|
|
180
|
-
className?: string;
|
|
181
180
|
initialTab: string;
|
|
182
|
-
disabled: boolean;
|
|
183
181
|
children: ReactNode;
|
|
182
|
+
disabled?: boolean;
|
|
183
|
+
className?: string;
|
|
184
184
|
}
|
|
185
185
|
export interface RadioInterface {
|
|
186
186
|
children: ReactNode;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
interface DetectBottomProps {
|
|
2
2
|
callback: () => void;
|
|
3
|
+
hasError?: boolean;
|
|
3
4
|
}
|
|
4
|
-
declare const DetectBottom: ({ callback }: DetectBottomProps) => JSX.Element;
|
|
5
|
+
declare const DetectBottom: ({ callback, hasError }: DetectBottomProps) => JSX.Element;
|
|
5
6
|
export default DetectBottom;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { EditImageFormFieldProps } from './types';
|
|
2
|
+
|
|
3
|
+
declare const EditImageFormField: ({ defaultIcon, errorMessage, handleError, url, handleURLChange, ariaLabelPrefix, dataTestIdPrefix, altText, }: EditImageFormFieldProps) => JSX.Element;
|
|
4
|
+
export default EditImageFormField;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
|
|
3
|
+
export interface EditImageFormFieldProps {
|
|
4
|
+
defaultIcon: ReactNode;
|
|
5
|
+
errorMessage: string;
|
|
6
|
+
handleError: (error: string) => void;
|
|
7
|
+
url: string;
|
|
8
|
+
handleURLChange: (url: string) => void;
|
|
9
|
+
altText: string;
|
|
10
|
+
ariaLabelPrefix: string;
|
|
11
|
+
dataTestIdPrefix: string;
|
|
12
|
+
}
|
|
13
|
+
export interface FallbackImageProps extends Pick<EditImageFormFieldProps, 'defaultIcon'> {
|
|
14
|
+
/**
|
|
15
|
+
* @default - false
|
|
16
|
+
*/
|
|
17
|
+
showEditIcon?: boolean;
|
|
18
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { MaterialHistoryProps } from './types';
|
|
2
2
|
|
|
3
|
-
declare const MaterialHistory: ({ material, pipelineName, ciPipelineId, selectCommit
|
|
3
|
+
declare const MaterialHistory: ({ material, pipelineName, ciPipelineId, selectCommit }: MaterialHistoryProps) => JSX.Element;
|
|
4
4
|
export default MaterialHistory;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ResponseType } from '../../../Common';
|
|
2
|
+
import { GetPluginStoreDataReturnType, GetPluginStoreDataServiceParamsType, MinParentPluginDTO, PluginDetailServiceParamsType } from './types';
|
|
2
3
|
|
|
3
4
|
export declare const getPluginsDetail: ({ appId, parentPluginIds, pluginIds, shouldShowError, }: PluginDetailServiceParamsType) => Promise<Pick<GetPluginStoreDataReturnType, 'pluginStore'>>;
|
|
4
5
|
export declare const getPluginStoreData: ({ searchKey, selectedTags, appId, offset, signal, }: GetPluginStoreDataServiceParamsType) => Promise<GetPluginStoreDataReturnType>;
|
|
5
6
|
export declare const getAvailablePluginTags: (appId: number) => Promise<string[]>;
|
|
7
|
+
export declare const getParentPluginList: (appId?: number) => Promise<ResponseType<MinParentPluginDTO[]>>;
|
|
@@ -14,6 +14,11 @@ export interface GetPluginTagsPayloadType {
|
|
|
14
14
|
export interface PluginTagNamesDTO {
|
|
15
15
|
tagNames: string[];
|
|
16
16
|
}
|
|
17
|
+
export interface MinParentPluginDTO {
|
|
18
|
+
id: number;
|
|
19
|
+
pluginName: string;
|
|
20
|
+
icon: string;
|
|
21
|
+
}
|
|
17
22
|
/**
|
|
18
23
|
* Minimal data of child plugins
|
|
19
24
|
*/
|
|
@@ -45,6 +50,7 @@ export interface ParentPluginDTO {
|
|
|
45
50
|
type: PluginCreationType;
|
|
46
51
|
icon: string;
|
|
47
52
|
pluginVersions: PluginVersionsDTO;
|
|
53
|
+
pluginIdentifier: string;
|
|
48
54
|
}
|
|
49
55
|
export interface PluginDetailDTO {
|
|
50
56
|
parentPlugins: ParentPluginDTO[];
|
|
@@ -66,11 +72,11 @@ export interface PluginDetailPayloadType extends Pick<PluginDetailServiceParamsT
|
|
|
66
72
|
export interface PluginListFiltersType extends Pick<BaseFilterQueryParams<unknown>, 'searchKey'> {
|
|
67
73
|
selectedTags: string[];
|
|
68
74
|
}
|
|
69
|
-
interface ParentPluginType extends Pick<ParentPluginDTO, 'id' | 'name' | 'description' | 'type' | 'icon'> {
|
|
75
|
+
interface ParentPluginType extends Pick<ParentPluginDTO, 'id' | 'name' | 'description' | 'type' | 'icon' | 'pluginIdentifier'> {
|
|
70
76
|
latestVersionId: MinimalPluginVersionDataDTO['id'];
|
|
71
77
|
pluginVersions: MinimalPluginVersionDataDTO[];
|
|
72
78
|
}
|
|
73
|
-
interface DetailedPluginVersionType extends Pick<MinimalPluginVersionDataDTO, 'id' | 'description' | 'name' | 'pluginVersion'>, Pick<DetailedPluginVersionDTO, 'tags' | 'isLatest' | 'inputVariables' | 'outputVariables' | 'updatedBy' | 'docLink'>, Pick<ParentPluginType, 'icon' | 'type'> {
|
|
79
|
+
interface DetailedPluginVersionType extends Pick<MinimalPluginVersionDataDTO, 'id' | 'description' | 'name' | 'pluginVersion'>, Pick<DetailedPluginVersionDTO, 'tags' | 'isLatest' | 'inputVariables' | 'outputVariables' | 'updatedBy' | 'docLink'>, Pick<ParentPluginType, 'icon' | 'type' | 'pluginIdentifier'> {
|
|
74
80
|
parentPluginId: ParentPluginType['id'];
|
|
75
81
|
}
|
|
76
82
|
export interface PluginDataStoreType {
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { OptionProps } from 'react-select';
|
|
2
|
+
import { OptionType } from '../../../Common/Types';
|
|
1
3
|
import { ParentPluginDTO, PluginDataStoreType } from './types';
|
|
2
4
|
|
|
3
5
|
export declare const parsePluginDetailsDTOIntoPluginStore: (pluginData: ParentPluginDTO[]) => PluginDataStoreType;
|
|
@@ -14,6 +16,7 @@ export declare const pluginTagSelectStyles: {
|
|
|
14
16
|
group: (base: any) => any;
|
|
15
17
|
groupHeading: (base: any) => any;
|
|
16
18
|
};
|
|
19
|
+
export declare const PluginTagOption: (props: OptionProps<OptionType, true>) => JSX.Element;
|
|
17
20
|
/**
|
|
18
21
|
* @description This method takes the initial plugin data store and updates the keys with the target parent plugin store and plugin version store
|
|
19
22
|
*/
|
|
@@ -81,5 +81,5 @@ import { SelectPickerProps } from './type';
|
|
|
81
81
|
* <SelectPicker ... showSelectedOptionsCount />
|
|
82
82
|
* ```
|
|
83
83
|
*/
|
|
84
|
-
declare const SelectPicker: ({ error, icon, renderMenuListFooter, helperText, placeholder, label, showSelectedOptionIcon, size, disabledTippyContent, showSelectedOptionsCount, menuSize, ...props }: SelectPickerProps) => JSX.Element;
|
|
84
|
+
declare const SelectPicker: ({ error, icon, renderMenuListFooter, helperText, placeholder, label, showSelectedOptionIcon, size, disabledTippyContent, showSelectedOptionsCount, menuSize, optionListError, reloadOptionList, ...props }: SelectPickerProps) => JSX.Element;
|
|
85
85
|
export default SelectPicker;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ServerErrors } from '../../../Common/ServerError';
|
|
1
2
|
import { OptionType } from '../../../Common/Types';
|
|
2
3
|
import { ComponentSizeType } from '../../constants';
|
|
3
4
|
import { ReactElement, ReactNode } from 'react';
|
|
@@ -18,7 +19,7 @@ export interface SelectPickerOptionType extends OptionType<number | string, Reac
|
|
|
18
19
|
endIcon?: ReactElement;
|
|
19
20
|
}
|
|
20
21
|
type SelectProps = ReactSelectProps<SelectPickerOptionType>;
|
|
21
|
-
export interface SelectPickerProps extends Pick<SelectProps, 'options' | 'value' | 'onChange' | 'isSearchable' | 'isClearable' | 'isLoading' | 'hideSelectedOptions' | 'controlShouldRenderValue' | 'closeMenuOnSelect' | 'isDisabled' | 'isLoading' | 'required' | 'isOptionDisabled' | 'placeholder'>, Required<Pick<SelectProps, 'classNamePrefix' | 'inputId' | 'name'>> {
|
|
22
|
+
export interface SelectPickerProps extends Pick<SelectProps, 'options' | 'value' | 'onChange' | 'isSearchable' | 'isClearable' | 'isLoading' | 'hideSelectedOptions' | 'controlShouldRenderValue' | 'closeMenuOnSelect' | 'isDisabled' | 'isLoading' | 'required' | 'isOptionDisabled' | 'placeholder' | 'autoFocus' | 'onKeyDown'>, Required<Pick<SelectProps, 'classNamePrefix' | 'inputId' | 'name'>> {
|
|
22
23
|
/**
|
|
23
24
|
* Icon to be rendered in the control
|
|
24
25
|
*/
|
|
@@ -70,5 +71,13 @@ export interface SelectPickerProps extends Pick<SelectProps, 'options' | 'value'
|
|
|
70
71
|
* @default 'ComponentSizeType.small'
|
|
71
72
|
*/
|
|
72
73
|
menuSize?: ComponentSizeType;
|
|
74
|
+
/**
|
|
75
|
+
* If true, would show generic section error state as no options message
|
|
76
|
+
*/
|
|
77
|
+
optionListError?: ServerErrors;
|
|
78
|
+
/**
|
|
79
|
+
* Would reload the option list when called in case optionListError is present
|
|
80
|
+
*/
|
|
81
|
+
reloadOptionList?: () => void;
|
|
73
82
|
}
|
|
74
83
|
export {};
|
|
@@ -12,6 +12,7 @@ export declare const MESSAGES: {
|
|
|
12
12
|
VALID_POSITIVE_NUMBER: string;
|
|
13
13
|
VALID_POSITIVE_INTEGER: string;
|
|
14
14
|
MAX_SAFE_INTEGER: string;
|
|
15
|
+
INVALID_SEMANTIC_VERSION: string;
|
|
15
16
|
};
|
|
16
17
|
export declare const requiredField: (value: string) => ValidationResponseType;
|
|
17
18
|
export declare const validateName: (name: string) => ValidationResponseType;
|
|
@@ -28,3 +29,5 @@ export declare const validateUniqueKeys: (keys: string[]) => {
|
|
|
28
29
|
isValid: boolean;
|
|
29
30
|
message: string;
|
|
30
31
|
};
|
|
32
|
+
export declare const validateSematicVersioning: (version: string) => ValidationResponseType;
|
|
33
|
+
export declare const validateDisplayName: (name: string) => ValidationResponseType;
|