@devtron-labs/devtron-fe-common-lib 0.0.52-beta-3 → 0.0.52-beta-4

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 (130) hide show
  1. package/.eslintrc.js +16 -84
  2. package/.github/workflows/release-package.yml +3 -2
  3. package/dist/Common/BreadCrumb/BreadCrumb.d.ts +1 -1
  4. package/dist/Common/BreadCrumb/BreadcrumbStore.d.ts +2 -2
  5. package/dist/Common/Constants.d.ts +9 -1
  6. package/dist/Common/CustomInput/CustomInput.d.ts +1 -1
  7. package/dist/Common/CustomInput/Types.d.ts +2 -2
  8. package/dist/Common/CustomTagSelector/ResizableTagTextArea.d.ts +1 -1
  9. package/dist/Common/DeleteComponentModal/DeleteComponent.d.ts +1 -1
  10. package/dist/Common/DevtronProgressing/DevtronProgressing.d.ts +1 -1
  11. package/dist/Common/Dialogs/ConfirmationDialog.d.ts +6 -6
  12. package/dist/Common/Dialogs/DeleteDialog.d.ts +1 -1
  13. package/dist/Common/Dialogs/ForceDeleteDialog.d.ts +1 -1
  14. package/dist/Common/Dialogs/Types.d.ts +1 -1
  15. package/dist/Common/EmptyState/EmptyState.d.ts +17 -20
  16. package/dist/Common/EmptyState/GenericEmptyState.d.ts +1 -1
  17. package/dist/Common/Error.d.ts +1 -2
  18. package/dist/Common/ErrorScreenNotFound.d.ts +1 -1
  19. package/dist/Common/Helper.d.ts +1 -1
  20. package/dist/Common/ImageTags.d.ts +1 -1
  21. package/dist/Common/InfoColorBar/InfoColourbar.d.ts +1 -1
  22. package/dist/Common/Modals/Modal.d.ts +2 -2
  23. package/dist/Common/Modals/OpaqueModal.d.ts +3 -3
  24. package/dist/Common/Modals/VisibleModal.d.ts +3 -3
  25. package/dist/Common/Modals/VisibleModal2.d.ts +3 -3
  26. package/dist/Common/MultiSelectCustomization.d.ts +1 -1
  27. package/dist/Common/Policy.Types.d.ts +2 -2
  28. package/dist/Common/PopupMenu.d.ts +5 -5
  29. package/dist/Common/Progressing.d.ts +2 -2
  30. package/dist/Common/RadioGroup/RadioGroup.d.ts +1 -1
  31. package/dist/Common/ResizableTextarea.d.ts +1 -1
  32. package/dist/Common/TippyCustomized.d.ts +1 -1
  33. package/dist/Common/ToastBody.d.ts +5 -5
  34. package/dist/Common/Types.d.ts +1 -0
  35. package/dist/index.d.ts +1 -1
  36. package/dist/index.js +376 -287
  37. package/package.json +2 -19
  38. package/src/Common/AddCDButton/AddCDButton.tsx +2 -1
  39. package/src/Common/Api.ts +25 -20
  40. package/src/Common/AppStatus/AppStatus.tsx +12 -12
  41. package/src/Common/AppStatus/utils.ts +5 -6
  42. package/src/Common/BreadCrumb/BreadCrumb.tsx +28 -32
  43. package/src/Common/BreadCrumb/BreadcrumbStore.tsx +2 -2
  44. package/src/Common/BreadCrumb/Types.ts +12 -11
  45. package/src/Common/ChartVersionAndTypeSelector.tsx +1 -1
  46. package/src/Common/Checkbox.tsx +19 -17
  47. package/src/Common/ClipboardButton/ClipboardButton.tsx +1 -1
  48. package/src/Common/ClipboardButton/__tests__/ClipboardButton.test.tsx +1 -0
  49. package/src/Common/Common.service.ts +65 -60
  50. package/src/Common/Constants.ts +18 -9
  51. package/src/Common/CustomInput/CustomInput.tsx +29 -22
  52. package/src/Common/CustomInput/Types.ts +4 -4
  53. package/src/Common/CustomInput/index.ts +1 -1
  54. package/src/Common/CustomTagSelector/PropagateTagInfo.tsx +18 -15
  55. package/src/Common/CustomTagSelector/ResizableTagTextArea.tsx +9 -9
  56. package/src/Common/CustomTagSelector/TagDetails.tsx +3 -9
  57. package/src/Common/CustomTagSelector/TagLabelSelect.tsx +9 -7
  58. package/src/Common/CustomTagSelector/TagLabelValueSelector.tsx +35 -31
  59. package/src/Common/CustomTagSelector/TagSelector.utils.ts +3 -2
  60. package/src/Common/CustomTagSelector/Types.ts +1 -1
  61. package/src/Common/CustomTagSelector/ValidationRules.ts +22 -18
  62. package/src/Common/CustomTagSelector/index.ts +2 -2
  63. package/src/Common/DebouncedSearch/DebouncedSearch.tsx +1 -2
  64. package/src/Common/DebouncedSearch/__tests__/DebouncedSearch.test.tsx +1 -0
  65. package/src/Common/DeleteComponentModal/DeleteComponent.tsx +32 -27
  66. package/src/Common/DeleteComponentModal/types.ts +1 -1
  67. package/src/Common/DevtronProgressing/DevtronProgressing.tsx +8 -5
  68. package/src/Common/Dialogs/ConfirmationDialog.tsx +24 -24
  69. package/src/Common/Dialogs/DeleteDialog.tsx +5 -3
  70. package/src/Common/Dialogs/DialogForm.tsx +35 -31
  71. package/src/Common/Dialogs/ForceDeleteDialog.tsx +7 -13
  72. package/src/Common/Dialogs/Types.ts +12 -12
  73. package/src/Common/Dialogs/index.ts +1 -1
  74. package/src/Common/Drawer/Drawer.tsx +1 -1
  75. package/src/Common/EmptyState/EmptyState.tsx +17 -13
  76. package/src/Common/EmptyState/GenericEmptyState.tsx +29 -7
  77. package/src/Common/Error.tsx +5 -5
  78. package/src/Common/ErrorScreenNotFound.tsx +12 -9
  79. package/src/Common/Grid/Grid.tsx +2 -1
  80. package/src/Common/Helper.tsx +37 -36
  81. package/src/Common/Hooks/UseClickOutside/UseClickOutside.tsx +1 -1
  82. package/src/Common/Hooks/UseSuperAdmin/UseSuperAdmin.tsx +1 -1
  83. package/src/Common/Hooks/UseWindowSize/UseWindowSize.tsx +7 -5
  84. package/src/Common/ImageTags.Types.ts +3 -2
  85. package/src/Common/ImageTags.tsx +66 -61
  86. package/src/Common/InfoColorBar/InfoColourbar.tsx +5 -10
  87. package/src/Common/Modals/Modal.tsx +3 -3
  88. package/src/Common/Modals/OpaqueModal.tsx +18 -25
  89. package/src/Common/Modals/VisibleModal.tsx +3 -7
  90. package/src/Common/Modals/VisibleModal2.tsx +15 -20
  91. package/src/Common/MultiSelectCustomization.tsx +13 -9
  92. package/src/Common/Policy.Types.ts +38 -38
  93. package/src/Common/PopupMenu.tsx +9 -10
  94. package/src/Common/Progressing.tsx +18 -15
  95. package/src/Common/RJSF/Form.tsx +1 -0
  96. package/src/Common/RJSF/common/FieldRow.tsx +1 -0
  97. package/src/Common/RJSF/config.ts +1 -0
  98. package/src/Common/RJSF/templates/ArrayFieldItemTemplate.tsx +1 -1
  99. package/src/Common/RJSF/templates/ArrayFieldTemplate.tsx +1 -0
  100. package/src/Common/RJSF/templates/BaseInput.tsx +1 -0
  101. package/src/Common/RJSF/templates/ButtonTemplates/AddButton.tsx +1 -0
  102. package/src/Common/RJSF/templates/ButtonTemplates/RemoveButton.tsx +1 -0
  103. package/src/Common/RJSF/templates/ButtonTemplates/SubmitButton.tsx +6 -1
  104. package/src/Common/RJSF/templates/Description.tsx +1 -0
  105. package/src/Common/RJSF/templates/Field.tsx +3 -14
  106. package/src/Common/RJSF/templates/FieldErrorTemplate.tsx +9 -6
  107. package/src/Common/RJSF/templates/ObjectFieldTemplate.tsx +7 -5
  108. package/src/Common/RJSF/templates/TitleField.tsx +1 -0
  109. package/src/Common/RJSF/templates/WrapIfAdditionalTemplate.tsx +1 -0
  110. package/src/Common/RJSF/utils.ts +57 -53
  111. package/src/Common/RJSF/widgets/Checkbox.tsx +2 -2
  112. package/src/Common/RJSF/widgets/Select.tsx +1 -0
  113. package/src/Common/RadioGroup/RadioGroup.tsx +23 -18
  114. package/src/Common/RadioGroup.tsx +23 -24
  115. package/src/Common/Reload.tsx +1 -0
  116. package/src/Common/ResizableTextarea.tsx +17 -18
  117. package/src/Common/Security/ScanVulnerabilitiesTable.tsx +34 -29
  118. package/src/Common/ServerError.ts +1 -5
  119. package/src/Common/TippyCustomized.tsx +38 -41
  120. package/src/Common/ToastBody.tsx +7 -6
  121. package/src/Common/Toggle/Toggle.tsx +3 -3
  122. package/src/Common/Types.ts +20 -19
  123. package/src/custom.d.ts +7 -7
  124. package/src/index.ts +1 -1
  125. package/.eslintignore +0 -79
  126. package/.github/pull_request_template.md +0 -25
  127. package/.github/workflows/ci.yml +0 -31
  128. package/.husky/pre-commit +0 -5
  129. package/.lintstagedrc +0 -3
  130. package/.nvmrc +0 -1
package/.eslintrc.js CHANGED
@@ -1,109 +1,41 @@
1
1
  module.exports = {
2
2
  parser: '@typescript-eslint/parser',
3
- plugins: ['@typescript-eslint', 'react', 'prettier'],
3
+ plugins: ['@typescript-eslint'],
4
4
  env: {
5
+ commonjs: true,
5
6
  browser: true,
6
- es2021: true,
7
+ es6: true,
7
8
  },
8
9
  parserOptions: {
9
- ecmaVersion: 2021,
10
+ ecmaVersion: 2018,
10
11
  sourceType: 'module',
11
12
  ecmaFeatures: {
12
13
  jsx: true,
13
14
  },
14
15
  project: ['./tsconfig.json'],
15
16
  },
16
- globals: {
17
- JSX: true,
18
- },
19
- extends: [
20
- 'eslint:recommended',
21
- 'plugin:react/recommended',
22
- 'plugin:react/jsx-runtime',
23
- 'plugin:@typescript-eslint/eslint-recommended',
24
- 'airbnb',
25
- 'airbnb/hooks',
26
- 'prettier',
27
- ],
28
17
  rules: {
29
- 'prettier/prettier': ['error'],
30
- 'linebreak-style': ['error', 'unix'],
31
- 'no-console': 'warn',
32
18
  'no-var': 'error',
33
19
  'no-duplicate-imports': 'error',
34
- 'no-shadow': 'off',
35
- '@typescript-eslint/no-shadow': 'warn',
36
20
  '@typescript-eslint/explicit-function-return-type': 'off',
21
+ '@typescript-eslint/no-explicit-any': 'off',
22
+ '@typescript-eslint/no-use-before-define': 'off',
37
23
  '@typescript-eslint/explicit-member-accessibility': 'off',
38
- // Since we are using typescript, we can disable the no-unused-vars rule for enum,etc
39
- 'no-unused-vars': 'off',
40
- '@typescript-eslint/no-unused-vars': 'error',
41
- 'react/jsx-filename-extension': [
42
- 'error',
43
- {
44
- extensions: ['tsx'],
45
- },
46
- ],
47
- 'react/jsx-props-no-spreading': 'off',
48
- 'react/prefer-stateless-function': 'off',
49
- 'jsx-a11y/click-events-have-key-events': 'off',
50
- 'jsx-a11y/no-static-element-interactions': 'off',
51
- 'jsx-a11y/no-noninteractive-element-interactions': 'off',
52
- 'no-underscore-dangle': 'off',
53
- 'import/no-extraneous-dependencies': [
54
- 'warn',
55
- {
56
- devDependencies: true,
57
- },
58
- ],
59
- 'no-plusplus': [
60
- 'error',
61
- {
62
- allowForLoopAfterthoughts: true,
63
- },
64
- ],
65
- // Since we dont use prop-types, we can disable this rule
66
- 'react/require-default-props': 'off',
67
- 'react-hooks/exhaustive-deps': 'off',
68
- 'react/function-component-definition': [
69
- 'warn',
70
- {
71
- namedComponents: 'arrow-function',
72
- unnamedComponents: 'arrow-function',
73
- },
74
- ],
75
- 'react/jsx-uses-react': 'off',
76
- 'react/react-in-jsx-scope': 'off',
77
- // additional rules:
78
- '@typescript-eslint/no-floating-promises': 'error',
79
- 'import/extensions': [
80
- 'warn',
81
- 'ignorePackages',
82
- {
83
- js: 'never',
84
- jsx: 'never',
85
- ts: 'never',
86
- tsx: 'never',
87
- },
88
- ],
24
+ curly: [2, 'all'],
25
+ 'keyword-spacing': 'error',
26
+ 'prettier/prettier': ['error', { semi: false }],
89
27
  },
90
- overrides: [
91
- {
92
- files: ['*.ts', '*.tsx'],
93
- rules: {
94
- 'no-undef': 'off',
95
- },
96
- },
28
+ extends: [
29
+ 'eslint:recommended',
30
+ 'plugin:@typescript-eslint/eslint-recommended',
31
+ 'plugin:@typescript-eslint/recommended',
32
+ 'prettier/@typescript-eslint',
33
+ 'plugin:prettier/recommended',
34
+ 'plugin:react/recommended',
97
35
  ],
98
36
  settings: {
99
37
  react: {
100
38
  version: 'detect',
101
39
  },
102
- 'import/resolver': {
103
- node: {
104
- moduleDirectory: ['src', 'node_modules'],
105
- extensions: ['.js', '.jsx', '.ts', '.tsx'],
106
- },
107
- },
108
40
  },
109
41
  }
@@ -11,7 +11,7 @@ jobs:
11
11
  - uses: actions/checkout@v3
12
12
  - uses: actions/setup-node@v3
13
13
  with:
14
- node-version-file: '.nvmrc'
14
+ node-version: 16
15
15
  - run: npm ci
16
16
  - run: npm test
17
17
 
@@ -25,7 +25,7 @@ jobs:
25
25
  - uses: actions/checkout@v3
26
26
  - uses: actions/setup-node@v3
27
27
  with:
28
- node-version-file: '.nvmrc'
28
+ node-version: 16
29
29
  registry-url: https://npm.pkg.github.com/
30
30
  - run: npm ci
31
31
  - run: npm run build-lib
@@ -46,3 +46,4 @@ jobs:
46
46
  - run: npm publish --access public
47
47
  env:
48
48
  NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
49
+
@@ -1,4 +1,4 @@
1
- import * as React from 'react';
1
+ import React from 'react';
2
2
  import { Breadcrumbs, UseBreadcrumbOptionalProps, UseBreadcrumbState } from './Types';
3
3
  export declare const BreadcrumbContext: React.Context<any>;
4
4
  export declare function useBreadcrumb(props?: UseBreadcrumbOptionalProps, deps?: any[]): UseBreadcrumbState;
@@ -1,8 +1,8 @@
1
- /// <reference types="react" />
1
+ import React from 'react';
2
2
  declare const Store: ({ children }: {
3
3
  children: any;
4
4
  }) => JSX.Element;
5
- export declare const BreadcrumbContext: import("react").Context<{
5
+ export declare const BreadcrumbContext: React.Context<{
6
6
  state: {
7
7
  alias: {};
8
8
  };
@@ -1,4 +1,4 @@
1
- import { RegistryTypeDetailType } from './Types';
1
+ import { RegistryTypeDetailType } from "./Types";
2
2
  export declare const FALLBACK_REQUEST_TIMEOUT = 60000;
3
3
  export declare const Host: string;
4
4
  export declare const DOCUMENTATION_HOME_PAGE = "https://docs.devtron.ai";
@@ -64,4 +64,12 @@ export declare const RepositoryAction: {
64
64
  CHART_PULL: string;
65
65
  CHART_PUSH: string;
66
66
  };
67
+ export declare enum APPROVAL_MODAL_TYPE {
68
+ CONFIG = "CONFIG",
69
+ DEPLOYMENT = "DEPLOYMENT"
70
+ }
67
71
  export declare const MAX_Z_INDEX = 2147483647;
72
+ export declare const SELECTED_APPROVAL_TAB_STATE: {
73
+ APPROVAL: string;
74
+ PENDING: string;
75
+ };
@@ -1,3 +1,3 @@
1
1
  /// <reference types="react" />
2
2
  import { CustomInputProps } from './Types';
3
- export declare const CustomInput: ({ name, value, error, onChange, onFocus, label, type, disabled, labelClassName, placeholder, tabIndex, dataTestid, isRequiredField, autoFocus, rootClassName, autoComplete, helperText, handleOnBlur, readOnly, noTrim, ref, onKeyPress, defaultValue, onKeyDown, required, additionalErrorInfo, }: CustomInputProps) => JSX.Element;
3
+ export declare function CustomInput({ name, value, error, onChange, onFocus, label, type, disabled, labelClassName, placeholder, tabIndex, dataTestid, isRequiredField, autoFocus, rootClassName, autoComplete, helperText, handleOnBlur, readOnly, noTrim, ref, onKeyPress, defaultValue, onKeyDown, required, additionalErrorInfo, inputWrapClassName, }: CustomInputProps): JSX.Element;
@@ -1,5 +1,4 @@
1
- import { HTMLInputTypeAttribute } from 'react';
2
- import * as React from 'react';
1
+ import React, { HTMLInputTypeAttribute } from 'react';
3
2
  export interface CustomInputProps {
4
3
  name: string;
5
4
  value: string | number;
@@ -27,4 +26,5 @@ export interface CustomInputProps {
27
26
  onKeyDown?: (e: any) => void;
28
27
  required?: boolean;
29
28
  additionalErrorInfo?: React.ReactNode;
29
+ inputWrapClassName?: string;
30
30
  }
@@ -1,3 +1,3 @@
1
1
  /// <reference types="react" />
2
2
  import { ResizableTagTextAreaProps } from './Types';
3
- export declare const ResizableTagTextArea: ({ className, minHeight, maxHeight, value, onChange, onBlur, onFocus, placeholder, tabIndex, refVar, dependentRef, dataTestId, handleKeyDown, }: ResizableTagTextAreaProps) => JSX.Element;
3
+ export declare function ResizableTagTextArea({ className, minHeight, maxHeight, value, onChange, onBlur, onFocus, placeholder, tabIndex, refVar, dependentRef, dataTestId, handleKeyDown, }: ResizableTagTextAreaProps): JSX.Element;
@@ -1,4 +1,4 @@
1
1
  /// <reference types="react" />
2
2
  import { DeleteComponentProps } from './types';
3
- declare const DeleteComponent: ({ setDeleting, toggleConfirmation, deleteComponent, title, component, payload, confirmationDialogDescription, redirectTo, url, reload, configuration, closeCustomComponent, }: DeleteComponentProps) => JSX.Element;
3
+ declare function DeleteComponent({ setDeleting, toggleConfirmation, deleteComponent, title, component, payload, confirmationDialogDescription, redirectTo, url, reload, configuration, closeCustomComponent, }: DeleteComponentProps): JSX.Element;
4
4
  export default DeleteComponent;
@@ -1,3 +1,3 @@
1
1
  /// <reference types="react" />
2
2
  import { DevtronProgressingProps } from './types';
3
- export declare const DevtronProgressing: ({ classes, parentClasses }: DevtronProgressingProps) => JSX.Element;
3
+ export declare function DevtronProgressing({ classes, parentClasses }: DevtronProgressingProps): JSX.Element;
@@ -1,9 +1,9 @@
1
1
  /// <reference types="react" />
2
2
  import { ConfirmationDialogBodyType, ConfirmationDialogButtonGroupType, ConfirmationDialogIconType, ConfirmationDialogType } from './Types';
3
- declare const ConfirmationDialog: {
4
- ({ className, children }: ConfirmationDialogType): JSX.Element;
5
- Icon: ({ src, className }: ConfirmationDialogIconType) => JSX.Element;
6
- Body: ({ title, subtitle, children }: ConfirmationDialogBodyType) => JSX.Element;
7
- ButtonGroup: ({ children }: ConfirmationDialogButtonGroupType) => JSX.Element;
8
- };
3
+ declare function ConfirmationDialog({ className, children }: ConfirmationDialogType): JSX.Element;
4
+ declare namespace ConfirmationDialog {
5
+ var Icon: ({ src, className }: ConfirmationDialogIconType) => JSX.Element;
6
+ var Body: ({ title, subtitle, children }: ConfirmationDialogBodyType) => JSX.Element;
7
+ var ButtonGroup: ({ children }: ConfirmationDialogButtonGroupType) => JSX.Element;
8
+ }
9
9
  export default ConfirmationDialog;
@@ -1,4 +1,4 @@
1
- import * as React from 'react';
1
+ import React from 'react';
2
2
  import { DeleteDialogProps } from './Types';
3
3
  export declare const DeleteDialog: React.FC<DeleteDialogProps> & {
4
4
  Description?: React.FC<any>;
@@ -1,3 +1,3 @@
1
1
  /// <reference types="react" />
2
2
  import { ForceDeleteDialogType } from './Types';
3
- export default function ForceDeleteDialog({ onClickDelete, closeDeleteModal, forceDeleteDialogTitle, forceDeleteDialogMessage, }: ForceDeleteDialogType): JSX.Element;
3
+ export default function ForceDeleteDialog({ onClickDelete, closeDeleteModal, forceDeleteDialogTitle, forceDeleteDialogMessage }: ForceDeleteDialogType): JSX.Element;
@@ -1,4 +1,4 @@
1
- import { ReactNode } from 'react';
1
+ import { ReactNode } from "react";
2
2
  export interface DeleteDialogProps {
3
3
  title: string;
4
4
  description?: string;
@@ -1,28 +1,25 @@
1
- import * as React from 'react';
1
+ import React from 'react';
2
2
  import './emptyState.scss';
3
- declare const EmptyState: {
4
- ({ children, className }: {
3
+ declare function EmptyState({ children, className }: {
4
+ children: any;
5
+ className?: string;
6
+ }): JSX.Element;
7
+ declare namespace EmptyState {
8
+ var Image: ({ children }: {
5
9
  children: any;
6
- className?: string;
7
- }): JSX.Element;
8
- Image: typeof Image;
9
- Title: typeof Title;
10
- Subtitle: ({ children, className }: {
10
+ }) => any;
11
+ var Title: ({ children }: {
12
+ children: any;
13
+ }) => any;
14
+ var Subtitle: ({ children, className }: {
11
15
  children: any;
12
16
  className?: string;
13
17
  }) => JSX.Element;
14
- Button: typeof Button;
15
- Loading: React.FC<{
18
+ var Button: ({ children }: {
19
+ children: any;
20
+ }) => any;
21
+ var Loading: React.FC<{
16
22
  text: string;
17
23
  }>;
18
- };
19
- declare function Image({ children }: {
20
- children: any;
21
- }): any;
22
- declare function Title({ children }: {
23
- children: any;
24
- }): any;
25
- declare function Button({ children }: {
26
- children: any;
27
- }): any;
24
+ }
28
25
  export default EmptyState;
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
2
  import { GenericEmptyStateType } from '../Types';
3
3
  import './emptyState.scss';
4
- declare const GenericEmptyState: ({ title, image, subTitle, isButtonAvailable, classname, styles, heightToDeduct, imageType, renderButton, imageClassName, children, SvgImage, noImage, layout, contentClassName, }: GenericEmptyStateType) => JSX.Element;
4
+ declare function GenericEmptyState({ title, image, subTitle, isButtonAvailable, classname, styles, heightToDeduct, imageType, renderButton, imageClassName, children, SvgImage, noImage, layout, contentClassName, imageStyles, }: GenericEmptyStateType): JSX.Element;
5
5
  export default GenericEmptyState;
@@ -1,5 +1,4 @@
1
- import { Component } from 'react';
2
- import * as React from 'react';
1
+ import React, { Component } from 'react';
3
2
  export declare class ErrorScreenManager extends Component<{
4
3
  code?: number;
5
4
  reload?: (...args: any[]) => any;
@@ -1,3 +1,3 @@
1
1
  /// <reference types="react" />
2
- declare const ErrorScreenNotFound: () => JSX.Element;
2
+ declare function ErrorScreenNotFound(): JSX.Element;
3
3
  export default ErrorScreenNotFound;
@@ -1,5 +1,5 @@
1
1
  import * as Sentry from '@sentry/browser';
2
- import * as React from 'react';
2
+ import React from 'react';
3
3
  import { AsyncOptions, UseSearchString } from './Types';
4
4
  export declare function showError(serverError: any, showToastOnUnknownError?: boolean, hideAccessError?: boolean): void;
5
5
  interface ConditionalWrapper<T> {
@@ -1,4 +1,4 @@
1
1
  /// <reference types="react" />
2
2
  import { ImageButtonType, ImageTaggingContainerType } from './ImageTags.Types';
3
- export declare const ImageTagsContainer: ({ ciPipelineId, artifactId, imageComment, imageReleaseTags, updateCurrentAppMaterial, appReleaseTagNames, setAppReleaseTagNames, tagsEditable, setTagsEditable, toggleCardMode, hideHardDelete, forceReInit, isSuperAdmin, }: ImageTaggingContainerType) => JSX.Element;
3
+ export declare const ImageTagsContainer: ({ ciPipelineId, artifactId, imageComment, imageReleaseTags, updateCurrentAppMaterial, appReleaseTagNames, setAppReleaseTagNames, tagsEditable, setTagsEditable, toggleCardMode, hideHardDelete, forceReInit, isSuperAdmin }: ImageTaggingContainerType) => JSX.Element;
4
4
  export declare const ImageTagButton: ({ text, isSoftDeleted, isEditing, onSoftDeleteClick, onHardDeleteClick, tagId, softDeleteTags, isSuperAdmin, duplicateTag, hideHardDelete, }: ImageButtonType) => JSX.Element;
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
2
  import { InfoColourBarType } from '../Types';
3
3
  import './infoColourBar.scss';
4
- declare const InfoColourBar: ({ message, classname, Icon, iconClass, iconSize, renderActionButton, linkText, redirectLink, linkOnClick, linkClass, internalLink, styles, }: InfoColourBarType) => JSX.Element;
4
+ declare function InfoColourBar({ message, classname, Icon, iconClass, iconSize, renderActionButton, linkText, redirectLink, linkOnClick, linkClass, internalLink, styles, }: InfoColourBarType): JSX.Element;
5
5
  export default InfoColourBar;
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
1
+ import React from 'react';
2
2
  import { ModalType } from '../Types';
3
- export declare const Modal: ({ style, children, modal, rootClassName, onClick, callbackRef, preventWheelDisable, noBackDrop, }: ModalType) => import("react").ReactPortal;
3
+ export declare const Modal: ({ style, children, modal, rootClassName, onClick, callbackRef, preventWheelDisable, noBackDrop, }: ModalType) => React.ReactPortal;
@@ -1,12 +1,12 @@
1
- import { Component } from 'react';
1
+ import React from 'react';
2
2
  export interface OpaqueModalProps {
3
3
  className?: string;
4
4
  onHide?: any;
5
5
  noBackground?: boolean;
6
6
  }
7
- export declare class OpaqueModal extends Component<OpaqueModalProps> {
7
+ export declare class OpaqueModal extends React.Component<OpaqueModalProps> {
8
8
  modalRef: HTMLElement;
9
9
  componentDidMount(): void;
10
10
  componentWillUnmount(): void;
11
- render(): import("react").ReactPortal;
11
+ render(): React.ReactPortal;
12
12
  }
@@ -1,5 +1,5 @@
1
- import { Component } from 'react';
2
- export declare class VisibleModal extends Component<{
1
+ import React from 'react';
2
+ export declare class VisibleModal extends React.Component<{
3
3
  className: string;
4
4
  parentClassName?: string;
5
5
  noBackground?: boolean;
@@ -11,5 +11,5 @@ export declare class VisibleModal extends Component<{
11
11
  escFunction(event: any): void;
12
12
  componentDidMount(): void;
13
13
  componentWillUnmount(): void;
14
- render(): import("react").ReactPortal;
14
+ render(): React.ReactPortal;
15
15
  }
@@ -1,5 +1,5 @@
1
- import { Component } from 'react';
2
- export declare class VisibleModal2 extends Component<{
1
+ import React from 'react';
2
+ export declare class VisibleModal2 extends React.Component<{
3
3
  className: string;
4
4
  close?: (e: any) => void;
5
5
  }> {
@@ -8,5 +8,5 @@ export declare class VisibleModal2 extends Component<{
8
8
  escFunction(event: any): void;
9
9
  componentDidMount(): void;
10
10
  componentWillUnmount(): void;
11
- render(): import("react").ReactPortal;
11
+ render(): React.ReactPortal;
12
12
  }
@@ -1,4 +1,4 @@
1
- import * as React from 'react';
1
+ import React from 'react';
2
2
  export declare const Option: (props: any) => JSX.Element;
3
3
  export declare const SingleSelectOption: (props: any) => JSX.Element;
4
4
  export declare const MultiValueContainer: (props: any) => JSX.Element;
@@ -1,5 +1,5 @@
1
- import { VariableType } from './CIPipeline.Types';
2
- import { ResponseType } from './Types';
1
+ import { VariableType } from "./CIPipeline.Types";
2
+ import { ResponseType } from "./Types";
3
3
  export declare enum ApplyPolicyToStage {
4
4
  PRE_CI = "PRE_CI",
5
5
  POST_CI = "POST_CI",
@@ -1,8 +1,8 @@
1
1
  /// <reference types="react" />
2
2
  import { PopupMenuBodyType, PopupMenuButtonType, PopupMenuType } from './Types';
3
- declare const PopupMenu: {
4
- ({ children, onToggleCallback, autoClose, autoPosition, }: PopupMenuType): any;
5
- Button: ({ children, disabled, rootClassName, tabIndex, onHover, isKebab, dataTestId, }: PopupMenuButtonType) => JSX.Element;
6
- Body: ({ children, rootClassName, style, autoWidth, preventWheelDisable, noBackDrop, }: PopupMenuBodyType) => JSX.Element;
7
- };
3
+ declare function PopupMenu({ children, onToggleCallback, autoClose, autoPosition, }: PopupMenuType): any;
4
+ declare namespace PopupMenu {
5
+ var Button: ({ children, disabled, rootClassName, tabIndex, onHover, isKebab, dataTestId, }: PopupMenuButtonType) => JSX.Element;
6
+ var Body: ({ children, rootClassName, style, autoWidth, preventWheelDisable, noBackDrop, }: PopupMenuBodyType) => JSX.Element;
7
+ }
8
8
  export default PopupMenu;
@@ -1,4 +1,4 @@
1
1
  /// <reference types="react" />
2
2
  import { ProgressingProps } from './Types';
3
- export declare const Progressing: ({ pageLoader, size, theme, styles, fillColor }: ProgressingProps) => JSX.Element;
4
- export declare const DetailsProgressing: ({ loadingText, size, fullHeight, styles, fillColor, children, }: ProgressingProps) => JSX.Element;
3
+ export declare function Progressing({ pageLoader, size, theme, styles, fillColor }: ProgressingProps): JSX.Element;
4
+ export declare function DetailsProgressing({ loadingText, size, fullHeight, styles, fillColor, children, }: ProgressingProps): JSX.Element;
@@ -1,4 +1,4 @@
1
- import * as React from 'react';
1
+ import React from 'react';
2
2
  import './radioGroup.scss';
3
3
  interface RadioGroupInterface {
4
4
  name: string;
@@ -1,3 +1,3 @@
1
- import * as React from 'react';
1
+ import React from 'react';
2
2
  import { ResizableTextareaProps } from './Types';
3
3
  export declare const ResizableTextarea: React.FC<ResizableTextareaProps>;
@@ -1,4 +1,4 @@
1
1
  /// <reference types="react" />
2
2
  import 'tippy.js/animations/shift-toward-subtle.css';
3
3
  import { TippyCustomizedProps } from './Types';
4
- export declare const TippyCustomized: (props: TippyCustomizedProps) => JSX.Element;
4
+ export declare function TippyCustomized(props: TippyCustomizedProps): JSX.Element;
@@ -1,18 +1,18 @@
1
- import { Component } from 'react';
2
- export declare class ToastBody extends Component<{
1
+ import React from 'react';
2
+ export declare class ToastBody extends React.Component<{
3
3
  title: string;
4
4
  subtitle?: string;
5
5
  }> {
6
6
  render(): JSX.Element;
7
7
  }
8
- export declare class ToastBody3 extends Component<{
8
+ export declare class ToastBody3 extends React.Component<{
9
9
  text: string;
10
10
  onClick: (...args: any[]) => void;
11
11
  buttonText: string;
12
12
  }> {
13
13
  render(): JSX.Element;
14
14
  }
15
- export declare class ToastBodyWithButton extends Component<{
15
+ export declare class ToastBodyWithButton extends React.Component<{
16
16
  title: string;
17
17
  subtitle?: string;
18
18
  onClick: (...args: any[]) => void;
@@ -20,4 +20,4 @@ export declare class ToastBodyWithButton extends Component<{
20
20
  }> {
21
21
  render(): JSX.Element;
22
22
  }
23
- export declare const toastAccessDenied: (title?: string, subtitle?: string) => import("react").ReactText;
23
+ export declare const toastAccessDenied: (title?: string, subtitle?: string) => React.ReactText;
@@ -87,6 +87,7 @@ export interface GenericEmptyStateType {
87
87
  imageClassName?: string;
88
88
  children?: ReactNode;
89
89
  noImage?: boolean;
90
+ imageStyles?: CSSProperties;
90
91
  /**
91
92
  * @default 'column'
92
93
  */
package/dist/index.d.ts CHANGED
@@ -1 +1 @@
1
- export * from './Common';
1
+ export * from "./Common";