@devtron-labs/devtron-fe-common-lib 0.2.30-beta-8 → 0.2.31-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.
Files changed (32) hide show
  1. package/dist/Common/Helper.d.ts +1 -0
  2. package/dist/Common/ToastBody.d.ts +1 -1
  3. package/dist/Common/Types.d.ts +2 -1
  4. package/dist/Shared/Components/Button/Button.component.d.ts +1 -6
  5. package/dist/Shared/Components/Button/constants.d.ts +2 -3
  6. package/dist/Shared/Components/Button/types.d.ts +12 -29
  7. package/dist/Shared/Components/Button/utils.d.ts +1 -3
  8. package/dist/Shared/Services/index.d.ts +0 -1
  9. package/dist/assets/index.css +1 -1
  10. package/dist/{cssMode-BG6o7oFP.js → cssMode-B4MC8utt.js} +1 -1
  11. package/dist/{freemarker2-DdoIf_sp.js → freemarker2-COGXjt2m.js} +1 -1
  12. package/dist/{handlebars-CGQHNJr1.js → handlebars-DO9bvobG.js} +1 -1
  13. package/dist/{html-Dj9xTLBG.js → html-C87o8XgA.js} +1 -1
  14. package/dist/{htmlMode-CskuHMJm.js → htmlMode-CCdCNEiS.js} +1 -1
  15. package/dist/{index-raDXwKRX.js → index-BELlKbGn.js} +27227 -26867
  16. package/dist/index.js +266 -268
  17. package/dist/{javascript-C8zDaPOb.js → javascript-dmldAF15.js} +1 -1
  18. package/dist/{jsonMode-HCpu5k3I.js → jsonMode-C7Mx53uE.js} +1 -1
  19. package/dist/{liquid-BancFx9U.js → liquid-RaGvGnGA.js} +1 -1
  20. package/dist/{mdx-BT84XBrj.js → mdx-YVWuIZhT.js} +1 -1
  21. package/dist/{python-Bk9QOSWL.js → python-VxWeJgUS.js} +1 -1
  22. package/dist/{razor-DSRo2jh3.js → razor-C3ICaAR3.js} +1 -1
  23. package/dist/{tsMode-BUf6TKWa.js → tsMode-86kn82Zs.js} +1 -1
  24. package/dist/{typescript-64xZmZfe.js → typescript-D-sdwq08.js} +1 -1
  25. package/dist/{xml-Dc8p_cP6.js → xml-BBuFM5Wu.js} +1 -1
  26. package/dist/{yaml-CAfuHNby.js → yaml-C_O86aJS.js} +1 -1
  27. package/package.json +2 -2
  28. package/dist/Shared/Services/ToastManager/ToastContent.d.ts +0 -2
  29. package/dist/Shared/Services/ToastManager/constants.d.ts +0 -4
  30. package/dist/Shared/Services/ToastManager/index.d.ts +0 -3
  31. package/dist/Shared/Services/ToastManager/toastManager.service.d.ts +0 -69
  32. package/dist/Shared/Services/ToastManager/types.d.ts +0 -40
@@ -126,4 +126,5 @@ export declare const DropdownIndicator: (props: any) => JSX.Element;
126
126
  export declare function mapByKey<T = Map<any, any>>(arr: any[], id: string): T;
127
127
  export declare function asyncWrap(promise: any): any[];
128
128
  export declare const prefixZeroIfSingleDigit: (value?: number) => string | number;
129
+ export declare const getContainerRegistryIcon: (registryValue: string) => JSX.Element;
129
130
  export {};
@@ -20,4 +20,4 @@ export declare class ToastBodyWithButton extends React.Component<{
20
20
  }> {
21
21
  render(): JSX.Element;
22
22
  }
23
- export declare const toastAccessDenied: (title?: string, subtitle?: string) => import('react-toastify').Id;
23
+ export declare const toastAccessDenied: (title?: string, subtitle?: string) => React.ReactText;
@@ -1,4 +1,4 @@
1
- import { default as React, ReactNode, CSSProperties } from 'react';
1
+ import { default as React, ReactNode, CSSProperties, ReactElement } from 'react';
2
2
  import { Placement } from 'tippy.js';
3
3
  import { UserGroupDTO } from '../Pages/GlobalConfigurations';
4
4
  import { ImageComment, ReleaseTag } from './ImageTags.Types';
@@ -620,6 +620,7 @@ export interface RegistryTypeDetailType {
620
620
  registryURL: InputDetailType;
621
621
  id: InputDetailType;
622
622
  password: InputDetailType;
623
+ startIcon: ReactElement;
623
624
  }
624
625
  export interface UseSearchString {
625
626
  queryParams: URLSearchParams;
@@ -57,11 +57,6 @@ import { ButtonProps } from './types';
57
57
  * ```tsx
58
58
  * <Button component={ButtonComponentType.link} linkProps={{ to: '#' }} />
59
59
  * ```
60
- *
61
- * @example Icon button
62
- * ```tsx
63
- * <Button icon={<ICCube />} ariaLabel="Label" />
64
- * ```
65
60
  */
66
- declare const Button: ({ dataTestId, text, variant, size, style, startIcon, endIcon, disabled, isLoading, showTooltip, tooltipProps, icon, ariaLabel, ...props }: ButtonProps) => JSX.Element;
61
+ declare const Button: ({ dataTestId, text, variant, size, style, startIcon, endIcon, disabled, isLoading, showTooltip, tooltipProps, ...props }: ButtonProps) => JSX.Element;
67
62
  export default Button;
@@ -1,6 +1,5 @@
1
1
  import { ProgressingProps } from '../../../Common/Types';
2
2
  import { ButtonProps } from './types';
3
3
  export declare const BUTTON_SIZE_TO_CLASS_NAME_MAP: Record<ButtonProps['size'], string>;
4
- export declare const ICON_BUTTON_SIZE_TO_CLASS_NAME_MAP: Record<ButtonProps['size'], string>;
5
- export declare const BUTTON_SIZE_TO_ICON_SIZE_MAP: Record<ButtonProps['size'], ProgressingProps['size']>;
6
- export declare const ICON_BUTTON_SIZE_TO_ICON_SIZE_MAP: Record<ButtonProps['size'], ProgressingProps['size']>;
4
+ export declare const BUTTON_SIZE_TO_ICON_CLASS_NAME_MAP: Record<ButtonProps['size'], string>;
5
+ export declare const BUTTON_SIZE_TO_LOADER_SIZE_MAP: Record<ButtonProps['size'], ProgressingProps['size']>;
@@ -11,7 +11,6 @@ export declare enum ButtonVariantType {
11
11
  export declare enum ButtonStyleType {
12
12
  default = "default",
13
13
  negative = "negative",
14
- negativeGrey = "negative-grey",
15
14
  positive = "positive",
16
15
  warning = "warning",
17
16
  neutral = "neutral"
@@ -60,6 +59,18 @@ export type ButtonProps = ({
60
59
  * @default ButtonStyleType.default
61
60
  */
62
61
  style?: ButtonStyleType;
62
+ /**
63
+ * Text to be displayed in the button
64
+ */
65
+ text: string;
66
+ /**
67
+ * If provided, icon to be displayed at the start of the button
68
+ */
69
+ startIcon?: ReactElement;
70
+ /**
71
+ * If provided, icon to be displayed at the end of the button
72
+ */
73
+ endIcon?: ReactElement;
63
74
  /**
64
75
  * If true, the loading state is shown for the button with disabled
65
76
  */
@@ -86,32 +97,4 @@ export type ButtonProps = ({
86
97
  } | {
87
98
  showTooltip?: never;
88
99
  tooltipProps?: never;
89
- }) & ({
90
- icon?: never;
91
- ariaLabel?: never;
92
- /**
93
- * Text to be displayed in the button
94
- */
95
- text: string;
96
- /**
97
- * If provided, icon to be displayed at the start of the button
98
- */
99
- startIcon?: ReactElement;
100
- /**
101
- * If provided, icon to be displayed at the end of the button
102
- */
103
- endIcon?: ReactElement;
104
- } | {
105
- /**
106
- * If provided, icon button is rendered
107
- */
108
- icon: ReactElement;
109
- /**
110
- * Label for the icon button for accessibility.
111
- * Shown on hover in tooltip if tippy is not provided explicitly
112
- */
113
- ariaLabel: string;
114
- text?: never;
115
- startIcon?: never;
116
- endIcon?: never;
117
100
  });
@@ -1,4 +1,2 @@
1
1
  import { ButtonProps } from './types';
2
- export declare const getButtonIconClassName: ({ size, icon }: Pick<ButtonProps, "size" | "icon">) => string;
3
- export declare const getButtonLoaderSize: ({ size, icon }: Pick<ButtonProps, "size" | "icon">) => number;
4
- export declare const getButtonDerivedClass: ({ size, variant, style, isLoading, icon, }: Pick<ButtonProps, "variant" | "size" | "style" | "isLoading" | "icon">) => string;
2
+ export declare const getButtonDerivedClass: ({ size, variant, style, isLoading, }: Pick<ButtonProps, "variant" | "size" | "style" | "isLoading">) => string;
@@ -2,4 +2,3 @@ export * from './types';
2
2
  export * from './app.types';
3
3
  export * from './app.service';
4
4
  export * from './common.service';
5
- export * from './ToastManager';