@devtron-labs/devtron-fe-common-lib 1.19.0-pre-5 → 1.19.0-pre-7
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/{@code-editor-KdvtlDLy.js → @code-editor-CxJ5P0f_.js} +6406 -6327
- package/dist/{@common-rjsf-C7SGh5DL.js → @common-rjsf-eJgxZaTa.js} +1 -1
- package/dist/{@framer-motion-DZveCoIL.js → @framer-motion-BKkW77Gi.js} +14 -12
- package/dist/Common/Constants.d.ts +8 -0
- package/dist/Common/Hooks/UseRegisterShortcut/types.d.ts +1 -0
- package/dist/Common/Hooks/UseRegisterShortcut/utils.d.ts +1 -1
- package/dist/Common/SearchBar/SearchBar.component.d.ts +1 -1
- package/dist/Common/SearchBar/types.d.ts +4 -0
- package/dist/Common/Types.d.ts +0 -3
- package/dist/Pages-Devtron-2.0/ApplicationManagement/Overview/Overview.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/ApplicationManagement/Overview/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/ApplicationManagement/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/Automation&Enablement/Overview/Overview.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/Automation&Enablement/Overview/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/Automation&Enablement/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/CostVisibility/Overview/Overview.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/CostVisibility/Overview/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/CostVisibility/Shared/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/CostVisibility/Shared/types.d.ts +9 -0
- package/dist/Pages-Devtron-2.0/CostVisibility/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/GlobalConfiguration/Overview/Overview.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/GlobalConfiguration/Overview/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/GlobalConfiguration/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/GlobalOverview/GlobalOverview.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/GlobalOverview/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/InfrastructureManagement/Overview/Overview.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/InfrastructureManagement/Overview/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/InfrastructureManagement/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/SecurityCenter/Overview/Overview.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/SecurityCenter/Overview/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/SecurityCenter/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/SoftwareReleaseManagement/Overview/Overview.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/SoftwareReleaseManagement/Overview/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/SoftwareReleaseManagement/index.d.ts +1 -0
- package/dist/Pages-Devtron-2.0/index.d.ts +1 -0
- package/dist/Shared/Components/Backdrop/types.d.ts +11 -2
- package/dist/Shared/Components/DTFocusTrap/DTFocusTrap.d.ts +1 -1
- package/dist/Shared/Components/DTFocusTrap/types.d.ts +0 -9
- package/dist/Shared/Components/FramerComponents/index.d.ts +2 -2
- package/dist/Shared/Components/GenericSectionErrorState/GenericSectionErrorState.component.d.ts +2 -1
- package/dist/Shared/Components/GenericSectionErrorState/types.d.ts +21 -5
- package/dist/Shared/Components/Icon/Icon.d.ts +8 -0
- package/dist/Shared/Components/Illustration/Illustration.d.ts +1 -0
- package/dist/Shared/Components/KeyboardShortcut/KeyboardShortcut.component.d.ts +3 -0
- package/dist/Shared/Components/KeyboardShortcut/index.d.ts +1 -0
- package/dist/Shared/Components/KeyboardShortcut/types.d.ts +4 -0
- package/dist/Shared/Components/TreeView/TreeView.component.d.ts +1 -1
- package/dist/Shared/Components/TreeView/TreeViewNodeContent.d.ts +1 -1
- package/dist/Shared/Components/TreeView/constants.d.ts +3 -0
- package/dist/Shared/Components/TreeView/types.d.ts +13 -3
- package/dist/Shared/Components/index.d.ts +1 -0
- package/dist/Shared/Hooks/useUserPreferences/service.d.ts +1 -1
- package/dist/Shared/Hooks/useUserPreferences/types.d.ts +31 -2
- package/dist/assets/@code-editor.css +1 -1
- package/dist/assets/ic-bot.65f403dd.svg +3 -0
- package/dist/assets/ic-clipboard.2869fa7d.svg +3 -0
- package/dist/assets/ic-cloud.aa7acc8a.svg +3 -0
- package/dist/assets/ic-coins.2c15f406.svg +3 -0
- package/dist/assets/ic-devtron-text.67a413b6.svg +3 -0
- package/dist/assets/ic-files-changed.04e6de3f.svg +3 -0
- package/dist/assets/ic-right-panel-collapse.0ecf8ceb.svg +3 -0
- package/dist/assets/ic-trend-up.5752ef30.svg +3 -0
- package/dist/assets/no-cluster-cost-enabled.038c73db.webp +0 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +804 -800
- package/package.json +1 -1
@@ -1,7 +1,7 @@
|
|
1
1
|
import { j as n, au as T, aw as J, av as K } from "./@vendor-3ORIJA0h.js";
|
2
2
|
import V, { useState as q, useEffect as Y, forwardRef as G, useMemo as E } from "react";
|
3
3
|
import z, { getDefaultRegistry as Q } from "@rjsf/core";
|
4
|
-
import { T as O, j as F, c as w, b as N, S as X, i as Z, g as ee, a as te, d as R, e as ne } from "./@code-editor-
|
4
|
+
import { T as O, j as F, c as w, b as N, S as X, i as Z, g as ee, a as te, d as R, e as ne } from "./@code-editor-CxJ5P0f_.js";
|
5
5
|
import { getUiOptions as B, getTemplate as $, getSubmitButtonOptions as re, ADDITIONAL_PROPERTY_FLAG as L, errorId as se, englishStringTranslator as ae, TranslatableString as oe, titleId as le, canExpand as ie, deepEquals as ce } from "@rjsf/utils";
|
6
6
|
import { ReactComponent as de } from "./assets/ic-add.cfaa779b.svg";
|
7
7
|
import { ReactComponent as ue } from "./assets/ic-warning.ecf7ff97.svg";
|
@@ -3323,7 +3323,7 @@ var Ys = ri({
|
|
3323
3323
|
checkIsScrollRoot: function(t) {
|
3324
3324
|
return window.getComputedStyle(t).position === "fixed";
|
3325
3325
|
}
|
3326
|
-
}), Xs = m(m(m(m({}, Eo), ka), Zo), bs),
|
3326
|
+
}), Xs = m(m(m(m({}, Eo), ka), Zo), bs), su = /* @__PURE__ */ qi(function(t, e) {
|
3327
3327
|
return Ca(t, e, Xs, ps, ks);
|
3328
3328
|
});
|
3329
3329
|
function ni() {
|
@@ -3410,7 +3410,7 @@ function qs(t) {
|
|
3410
3410
|
Mi(r) && e.push(r);
|
3411
3411
|
}), e;
|
3412
3412
|
}
|
3413
|
-
var
|
3413
|
+
var uu = function(t) {
|
3414
3414
|
var e = t.children, r = t.custom, n = t.initial, i = n === void 0 ? !0 : n, s = t.onExitComplete, o = t.exitBeforeEnter, a = t.presenceAffectsLayout, u = a === void 0 ? !0 : a, l = R(Ws(), 1), f = l[0], v = F(Ie).forceRender;
|
3415
3415
|
v && (f = v);
|
3416
3416
|
var c = ni(), d = qs(e), p = d, h = /* @__PURE__ */ new Set(), g = $(p), b = $(/* @__PURE__ */ new Map()).current, P = $(!0);
|
@@ -3501,7 +3501,7 @@ function ai(t, e) {
|
|
3501
3501
|
return Z.update(n, !1, !0);
|
3502
3502
|
}), r;
|
3503
3503
|
}
|
3504
|
-
function
|
3504
|
+
function lu(t, e, r, n) {
|
3505
3505
|
var i = typeof e == "function" ? e : tu(e, r, n);
|
3506
3506
|
return Array.isArray(t) ? Wr(t, i) : Wr([t], function(s) {
|
3507
3507
|
var o = R(s, 1), a = o[0];
|
@@ -3519,7 +3519,7 @@ function Wr(t, e) {
|
|
3519
3519
|
return e(r);
|
3520
3520
|
});
|
3521
3521
|
}
|
3522
|
-
function
|
3522
|
+
function fu(t) {
|
3523
3523
|
for (var e = [], r = 1; r < arguments.length; r++)
|
3524
3524
|
e[r - 1] = arguments[r];
|
3525
3525
|
var n = t.length;
|
@@ -3533,7 +3533,7 @@ function lu(t) {
|
|
3533
3533
|
}
|
3534
3534
|
return ai(e, i);
|
3535
3535
|
}
|
3536
|
-
function
|
3536
|
+
function cu(t, e) {
|
3537
3537
|
e === void 0 && (e = {});
|
3538
3538
|
var r = F(_t).isStatic, n = $(null), i = ii(q(t) ? t.get() : t);
|
3539
3539
|
return Vt(function() {
|
@@ -3588,17 +3588,19 @@ function nu() {
|
|
3588
3588
|
};
|
3589
3589
|
return n;
|
3590
3590
|
}
|
3591
|
-
function
|
3591
|
+
function iu() {
|
3592
3592
|
var t = ft(nu);
|
3593
3593
|
return N(t.mount, []), t;
|
3594
3594
|
}
|
3595
|
+
var vu = iu;
|
3595
3596
|
export {
|
3596
|
-
|
3597
|
+
uu as A,
|
3597
3598
|
Ps as a,
|
3598
|
-
|
3599
|
-
|
3600
|
-
|
3601
|
-
|
3602
|
-
|
3599
|
+
lu as b,
|
3600
|
+
fu as c,
|
3601
|
+
cu as d,
|
3602
|
+
vu as e,
|
3603
|
+
iu as f,
|
3604
|
+
su as m,
|
3603
3605
|
ii as u
|
3604
3606
|
};
|
@@ -64,6 +64,14 @@ export declare const URLS: {
|
|
64
64
|
readonly GLOBAL_CONFIG_TEMPLATES_DEVTRON_APP_DETAIL: "/global-config/templates/devtron-apps/detail/:appId";
|
65
65
|
readonly LICENSE_AUTH: "/license-auth";
|
66
66
|
readonly GLOBAL_CONFIG_EDIT_CLUSTER: "/global-config/cluster-env/edit/:clusterId";
|
67
|
+
readonly COST_VISIBILITY_OVERVIEW: "/cost-visibility/overview";
|
68
|
+
readonly COST_BREAKDOWN_ROUTE: "/cost-visibility/breakdown/:breakdownViewType";
|
69
|
+
readonly COST_BREAKDOWN_CLUSTERS: "/cost-visibility/breakdown/clusters";
|
70
|
+
readonly COST_BREAKDOWN_ENVIRONMENTS: "/cost-visibility/breakdown/environments";
|
71
|
+
readonly COST_BREAKDOWN_PROJECTS: "/cost-visibility/breakdown/projects";
|
72
|
+
readonly COST_BREAKDOWN_APPLICATIONS: "/cost-visibility/breakdown/applications";
|
73
|
+
readonly COST_BREAKDOWN_ITEM_NAME: ":itemName";
|
74
|
+
readonly COST_CONFIGURATIONS: "/cost-visibility/configurations";
|
67
75
|
};
|
68
76
|
export declare const ROUTES: {
|
69
77
|
readonly APP: "app";
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { ShortcutType } from './types';
|
2
2
|
export declare const preprocessKeys: (keys: ShortcutType["keys"]) => {
|
3
|
-
keys: ("N" | "R" | "Enter" | "/" | "Alt" | "F" | "E" | "K" | "X" | "A" | "S" | "Home" | "End" | "." | "Space" | "Control" | "Shift" | "Meta" | "Escape" | "ArrowLeft" | "ArrowRight" | "ArrowUp" | "ArrowDown" | "PageUp" | "PageDown" | "Backspace" | "Delete")[];
|
3
|
+
keys: ("N" | "R" | "Enter" | "/" | "Alt" | "F" | "E" | "K" | "X" | "A" | "S" | "Home" | "End" | "." | "Space" | ">" | "Control" | "Shift" | "Meta" | "Escape" | "ArrowLeft" | "ArrowRight" | "ArrowUp" | "ArrowDown" | "PageUp" | "PageDown" | "Backspace" | "Delete")[];
|
4
4
|
id: string;
|
5
5
|
};
|
6
6
|
export declare const verifyCallbackStack: (stack: ShortcutType["callbackStack"]) => void;
|
@@ -33,5 +33,5 @@ import { SearchBarProps } from './types';
|
|
33
33
|
* <SearchBar inputProps={{ placeholder: 'Enter search text' }} />
|
34
34
|
* ```
|
35
35
|
*/
|
36
|
-
declare const SearchBar: ({ initialSearchText, handleSearchChange, handleEnter, inputProps, containerClassName, shouldDebounce, debounceTimeout, dataTestId, noBackgroundAndBorder, size, keyboardShortcut, }: SearchBarProps) => JSX.Element;
|
36
|
+
declare const SearchBar: ({ initialSearchText, handleSearchChange, handleEnter, inputProps, containerClassName, shouldDebounce, debounceTimeout, dataTestId, noBackgroundAndBorder, size, keyboardShortcut, variant, }: SearchBarProps) => JSX.Element;
|
37
37
|
export default SearchBar;
|
package/dist/Common/Types.d.ts
CHANGED
@@ -0,0 +1 @@
|
|
1
|
+
export declare const Overview: () => JSX.Element;
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Overview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Overview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export declare const Overview: () => JSX.Element;
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Overview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Overview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export declare const Overview: () => JSX.Element;
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Overview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './types';
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Shared';
|
@@ -0,0 +1 @@
|
|
1
|
+
export declare const Overview: () => JSX.Element;
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Overview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Overview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export declare const GlobalOverview: () => JSX.Element;
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './GlobalOverview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export declare const Overview: () => JSX.Element;
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Overview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Overview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export declare const Overview: () => JSX.Element;
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Overview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Overview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export declare const Overview: () => JSX.Element;
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Overview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './Overview';
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './CostVisibility';
|
@@ -1,6 +1,15 @@
|
|
1
|
-
import { MouseEvent, ReactNode } from 'react';
|
1
|
+
import { MouseEvent, ReactNode, SyntheticEvent } from 'react';
|
2
2
|
import { DTFocusTrapType } from '../DTFocusTrap';
|
3
|
-
export interface BackdropProps extends Pick<DTFocusTrapType, 'deactivateFocusOnEscape' | 'initialFocus'
|
3
|
+
export interface BackdropProps extends Pick<DTFocusTrapType, 'deactivateFocusOnEscape' | 'initialFocus'> {
|
4
|
+
/**
|
5
|
+
* Callback function that gets triggered when the Escape key is pressed. \
|
6
|
+
* Should be wrapped in useCallback to prevent unnecessary re-renders.
|
7
|
+
* @example
|
8
|
+
* const handleEscape = useCallback(() => {
|
9
|
+
* // Handle escape key press
|
10
|
+
* }, []);
|
11
|
+
*/
|
12
|
+
onEscape: (e?: SyntheticEvent) => void;
|
4
13
|
/**
|
5
14
|
* The content to be rendered within the backdrop component.
|
6
15
|
*/
|
@@ -4,5 +4,5 @@ export declare const useFocusTrapControl: () => {
|
|
4
4
|
disableFocusTrap: typeof noop;
|
5
5
|
resumeFocusTrap: typeof noop;
|
6
6
|
};
|
7
|
-
declare const DTFocusTrap: ({
|
7
|
+
declare const DTFocusTrap: ({ deactivateFocusOnEscape, children, initialFocus }: DTFocusTrapType) => JSX.Element;
|
8
8
|
export default DTFocusTrap;
|
@@ -8,15 +8,6 @@ type FocusTargetValueOrFalse = FocusTargetValue | false;
|
|
8
8
|
*/
|
9
9
|
type FocusTargetOrFalse = FocusTargetValueOrFalse | (() => FocusTargetValueOrFalse);
|
10
10
|
export interface DTFocusTrapType {
|
11
|
-
/**
|
12
|
-
* Callback function that gets triggered when the Escape key is pressed. \
|
13
|
-
* Should be wrapped in useCallback to prevent unnecessary re-renders.
|
14
|
-
* @example
|
15
|
-
* const handleEscape = useCallback(() => {
|
16
|
-
* // Handle escape key press
|
17
|
-
* }, []);
|
18
|
-
*/
|
19
|
-
onEscape: (e?: KeyboardEvent | MouseEvent) => void;
|
20
11
|
/**
|
21
12
|
* If focus should be deactivated on escape, pass false when escape is disabled or has no action
|
22
13
|
* true for cases when we are closing modals or dialogs
|
@@ -1,2 +1,2 @@
|
|
1
|
-
import { animate, AnimatePresence, motion, useAnimationControls, useMotionTemplate, useMotionValue } from 'framer-motion';
|
2
|
-
export { animate, AnimatePresence, motion, useAnimationControls, useMotionTemplate, useMotionValue };
|
1
|
+
import { animate, AnimatePresence, motion, useAnimation, useAnimationControls, useMotionTemplate, useMotionValue } from 'framer-motion';
|
2
|
+
export { animate, AnimatePresence, motion, useAnimation, useAnimationControls, useMotionTemplate, useMotionValue };
|
package/dist/Shared/Components/GenericSectionErrorState/GenericSectionErrorState.component.d.ts
CHANGED
@@ -1,3 +1,4 @@
|
|
1
|
+
import { ButtonComponentType } from '../Button';
|
1
2
|
import { GenericSectionErrorStateProps } from './types';
|
2
|
-
declare const GenericSectionErrorState: ({ reload, withBorder, title, subTitle, description, buttonText, rootClassName, useInfoIcon, progressingProps, }: GenericSectionErrorStateProps) => JSX.Element;
|
3
|
+
declare const GenericSectionErrorState: <T extends ButtonComponentType = ButtonComponentType.button>({ reload, buttonProps, customIcon, withBorder, title, subTitle, description, buttonText, rootClassName, useInfoIcon, progressingProps, }: GenericSectionErrorStateProps<T>) => JSX.Element;
|
3
4
|
export default GenericSectionErrorState;
|
@@ -1,10 +1,7 @@
|
|
1
1
|
import { ReactNode } from 'react';
|
2
|
+
import { ButtonComponentType, ButtonProps } from '../Button';
|
2
3
|
import { IconsProps } from '../Icon';
|
3
|
-
export type GenericSectionErrorStateProps = {
|
4
|
-
/**
|
5
|
-
* Handler for reloading the section
|
6
|
-
*/
|
7
|
-
reload?: () => void;
|
4
|
+
export type GenericSectionErrorStateProps<ButtonType extends ButtonComponentType = ButtonComponentType.button> = {
|
8
5
|
/**
|
9
6
|
* If true, border is added to the section
|
10
7
|
*
|
@@ -37,6 +34,7 @@ export type GenericSectionErrorStateProps = {
|
|
37
34
|
*/
|
38
35
|
progressingProps: Omit<IconsProps, 'name'>;
|
39
36
|
useInfoIcon?: false;
|
37
|
+
customIcon?: never;
|
40
38
|
} | {
|
41
39
|
progressingProps?: never;
|
42
40
|
/**
|
@@ -45,7 +43,25 @@ export type GenericSectionErrorStateProps = {
|
|
45
43
|
* @default false
|
46
44
|
*/
|
47
45
|
useInfoIcon: true;
|
46
|
+
customIcon?: never;
|
47
|
+
} | {
|
48
|
+
progressingProps?: never;
|
49
|
+
useInfoIcon?: never;
|
50
|
+
customIcon?: never;
|
48
51
|
} | {
|
52
|
+
customIcon: JSX.Element;
|
49
53
|
progressingProps?: never;
|
50
54
|
useInfoIcon?: never;
|
55
|
+
}) & ({
|
56
|
+
/**
|
57
|
+
* Handler for reloading the section
|
58
|
+
*/
|
59
|
+
reload: () => void;
|
60
|
+
buttonProps?: never;
|
61
|
+
} | {
|
62
|
+
reload?: never;
|
63
|
+
buttonProps: ButtonProps<ButtonType>;
|
64
|
+
} | {
|
65
|
+
reload?: never;
|
66
|
+
buttonProps?: never;
|
51
67
|
});
|
@@ -22,6 +22,7 @@ export declare const iconMap: {
|
|
22
22
|
'ic-bharatpe': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
23
23
|
'ic-bitbucket': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
24
24
|
'ic-book-open': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
25
|
+
'ic-bot': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
25
26
|
'ic-brain': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
26
27
|
'ic-browser': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
27
28
|
'ic-bug': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
@@ -42,13 +43,16 @@ export declare const iconMap: {
|
|
42
43
|
'ic-ci-linked': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
43
44
|
'ic-circle-loader': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
44
45
|
'ic-clean-brush': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
46
|
+
'ic-clipboard': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
45
47
|
'ic-clock': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
46
48
|
'ic-close-large': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
47
49
|
'ic-close-small': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
48
50
|
'ic-cloud-vms': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
51
|
+
'ic-cloud': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
49
52
|
'ic-cluster-isolated': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
50
53
|
'ic-cluster': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
51
54
|
'ic-code': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
55
|
+
'ic-coins': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
52
56
|
'ic-container-registry': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
53
57
|
'ic-container': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
54
58
|
'ic-cookr': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
@@ -66,6 +70,7 @@ export declare const iconMap: {
|
|
66
70
|
'ic-devtron-app': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
67
71
|
'ic-devtron-header-logo': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
68
72
|
'ic-devtron-job': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
73
|
+
'ic-devtron-text': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
69
74
|
'ic-devtron': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
70
75
|
'ic-diff-added': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
71
76
|
'ic-diff-deleted': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
@@ -91,6 +96,7 @@ export declare const iconMap: {
|
|
91
96
|
'ic-file-edit': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
92
97
|
'ic-file-key': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
93
98
|
'ic-file': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
99
|
+
'ic-files-changed': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
94
100
|
'ic-files': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
95
101
|
'ic-filter-applied': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
96
102
|
'ic-filter': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
@@ -178,6 +184,7 @@ export declare const iconMap: {
|
|
178
184
|
'ic-quay': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
179
185
|
'ic-quote': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
180
186
|
'ic-resize-handle': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
187
|
+
'ic-right-panel-collapse': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
181
188
|
'ic-rocket-gear': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
182
189
|
'ic-rocket-launch': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
183
190
|
'ic-selected': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
@@ -218,6 +225,7 @@ export declare const iconMap: {
|
|
218
225
|
'ic-timer': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
219
226
|
'ic-traffic-signal': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
220
227
|
'ic-travclan': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
228
|
+
'ic-trend-up': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
221
229
|
'ic-two-cubes': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
222
230
|
'ic-ubuntu': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
223
231
|
'ic-unknown': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement>>;
|
@@ -4,6 +4,7 @@ export declare const illustrationMap: {
|
|
4
4
|
'img-code': string;
|
5
5
|
'img-man-on-rocket': string;
|
6
6
|
'img-no-result': string;
|
7
|
+
'no-cluster-cost-enabled': string;
|
7
8
|
};
|
8
9
|
export type IllustrationName = keyof typeof illustrationMap;
|
9
10
|
export interface IllustrationProps extends Omit<IllustrationBaseProps, 'name' | 'illustrationMap'> {
|
@@ -0,0 +1 @@
|
|
1
|
+
export { default as KeyboardShortcut } from './KeyboardShortcut.component';
|
@@ -1,3 +1,3 @@
|
|
1
1
|
import { TreeViewProps } from './types';
|
2
|
-
declare const TreeView: <DataAttributeType = null>({ nodes, isControlled, expandedMap: expandedMapProp, selectedId, onToggle: onToggleProp, onSelect, depth, mode, flatNodeList: flatNodeListProp, getUpdateItemsRefMap: getUpdateItemsRefMapProp, variant, defaultExpandedMap, }: TreeViewProps<DataAttributeType>) => JSX.Element;
|
2
|
+
declare const TreeView: <DataAttributeType = null>({ nodes, isControlled, expandedMap: expandedMapProp, selectedId, onToggle: onToggleProp, onSelect, depth, mode, flatNodeList: flatNodeListProp, getUpdateItemsRefMap: getUpdateItemsRefMapProp, variant, defaultExpandedMap, highlightSelectedHeadingOnlyWhenCollapsed, }: TreeViewProps<DataAttributeType>) => JSX.Element;
|
3
3
|
export default TreeView;
|
@@ -1,3 +1,3 @@
|
|
1
1
|
import { TreeViewNodeContentProps } from './types';
|
2
|
-
declare const TreeViewNodeContent: ({ startIconConfig, title, subtitle, type, customTooltipConfig, strikeThrough, isSelected, }: TreeViewNodeContentProps) => JSX.Element;
|
2
|
+
declare const TreeViewNodeContent: ({ startIconConfig, title, subtitle, type, customTooltipConfig, strikeThrough, isSelected, variant, }: TreeViewNodeContentProps) => JSX.Element;
|
3
3
|
export default TreeViewNodeContent;
|
@@ -2,3 +2,6 @@ import { TreeViewProps } from './types';
|
|
2
2
|
export declare const DEFAULT_NO_ITEMS_TEXT = "No items found";
|
3
3
|
export declare const VARIANT_TO_BG_CLASS_MAP: Record<TreeViewProps['variant'], string>;
|
4
4
|
export declare const VARIANT_TO_HOVER_CLASS_MAP: Record<TreeViewProps['variant'], string>;
|
5
|
+
export declare const VARIANT_TO_SELECTED_CLASS_MAP: Record<TreeViewProps['variant'], string>;
|
6
|
+
export declare const VARIANT_TO_TEXT_CLASS_MAP: Record<TreeViewProps['variant'], string>;
|
7
|
+
export declare const VARIANT_TO_TREE_ITEM_ACTIVE_BG_CLASS_MAP: Record<TreeViewProps['variant'], string>;
|
@@ -96,9 +96,11 @@ export type TreeItem<DataAttributeType = null> = BaseNode<DataAttributeType> & {
|
|
96
96
|
onClick?: (e: SyntheticEvent) => void;
|
97
97
|
href?: never;
|
98
98
|
clearQueryParamsOnNavigation?: never;
|
99
|
+
activeClassName?: never;
|
99
100
|
} | {
|
100
101
|
as: 'link';
|
101
102
|
href: string;
|
103
|
+
activeClassName?: string;
|
102
104
|
/**
|
103
105
|
* The callback function to handle click events on the nav link.
|
104
106
|
*/
|
@@ -113,6 +115,7 @@ export type TreeItem<DataAttributeType = null> = BaseNode<DataAttributeType> & {
|
|
113
115
|
href?: never;
|
114
116
|
onClick?: never;
|
115
117
|
clearQueryParamsOnNavigation?: never;
|
118
|
+
activeClassName?: never;
|
116
119
|
});
|
117
120
|
/**
|
118
121
|
* Props for the TreeView component.
|
@@ -151,14 +154,21 @@ export type TreeViewProps<DataAttributeType = null> = {
|
|
151
154
|
*/
|
152
155
|
mode?: 'navigation' | 'form';
|
153
156
|
/**
|
154
|
-
* If primary the background color will be bg__primary and bg__hover--opaque
|
157
|
+
* If primary the background color will be bg__primary and bg__hover--opaque \
|
158
|
+
* if secondary the background color will be bg__secondary bg__hover-secondary--opaque,
|
159
|
+
* if sidenav the background color will be bg__transparent bg__hover-sidebar-item.
|
155
160
|
* @default 'primary'
|
156
161
|
*/
|
157
|
-
variant?: 'primary' | 'secondary';
|
162
|
+
variant?: 'primary' | 'secondary' | 'sidenav';
|
158
163
|
/**
|
159
164
|
* @default {}
|
160
165
|
*/
|
161
166
|
defaultExpandedMap?: Record<string, boolean>;
|
167
|
+
/**
|
168
|
+
* When true, the selected heading (`selectedId`) will be highlighted only when it is collapsed.
|
169
|
+
* @default false
|
170
|
+
*/
|
171
|
+
highlightSelectedHeadingOnlyWhenCollapsed?: boolean;
|
162
172
|
} /**
|
163
173
|
* WARNING: For internal use only.
|
164
174
|
*/ & ({
|
@@ -188,7 +198,7 @@ export type TreeViewProps<DataAttributeType = null> = {
|
|
188
198
|
expandedMap?: never;
|
189
199
|
isControlled?: false;
|
190
200
|
});
|
191
|
-
export interface TreeViewNodeContentProps extends Pick<BaseNode, 'startIconConfig' | 'title' | 'subtitle' | 'customTooltipConfig' | 'strikeThrough'
|
201
|
+
export interface TreeViewNodeContentProps extends Pick<BaseNode, 'startIconConfig' | 'title' | 'subtitle' | 'customTooltipConfig' | 'strikeThrough'>, Required<Pick<TreeViewProps, 'variant'>> {
|
192
202
|
type: 'heading' | 'item';
|
193
203
|
isSelected: boolean;
|
194
204
|
}
|
@@ -59,6 +59,7 @@ export * from './ImageWithFallback';
|
|
59
59
|
export * from './InfoBlock';
|
60
60
|
export * from './InfoIconTippy';
|
61
61
|
export * from './InvalidYAMLTippy';
|
62
|
+
export * from './KeyboardShortcut';
|
62
63
|
export * from './KeyValueTable';
|
63
64
|
export * from './License';
|
64
65
|
export { default as LoadingCard } from './LoadingCard';
|
@@ -4,7 +4,7 @@ import { PreferredResourceKindType, UserPreferenceFilteredListTypes, UserPrefere
|
|
4
4
|
* @description This function fetches the user preferences from the server. It uses the `get` method to make a request to the server and retrieves the user preferences based on the `USER_PREFERENCES_ATTRIBUTE_KEY`. The result is parsed and returned as a `UserPreferencesType` object.
|
5
5
|
* @throws Will throw an error if the request fails or if the result is not in the expected format.
|
6
6
|
*/
|
7
|
-
export declare const getUserPreferences: () => Promise<UserPreferencesType>;
|
7
|
+
export declare const getUserPreferences: (signal?: AbortSignal) => Promise<UserPreferencesType>;
|
8
8
|
export declare const updateUserPreferences: ({ path, value, resourceKind, shouldThrowError, userPreferencesResponse, }: UserPreferenceResourceProps) => Promise<boolean>;
|
9
9
|
/**
|
10
10
|
* Optimized function to get updated user preferences with resource filtering
|
@@ -1,6 +1,8 @@
|
|
1
1
|
import { USER_PREFERENCES_ATTRIBUTE_KEY } from './constants';
|
2
2
|
import { AppThemeType, ThemeConfigType, ThemePreferenceType } from '../../Providers/ThemeProvider/types';
|
3
3
|
import { ResourceKindType } from '../../types';
|
4
|
+
export type NavigationItemID = 'application-management-overview' | 'application-management-applications' | 'application-management-application-groups' | 'application-management-chart-store' | 'application-management-bulk-edit' | 'application-management-configurations' | 'application-management-policies' | 'application-management-others' | 'infrastructure-management-overview' | 'infrastructure-management-resource-browser' | 'infrastructure-management-intercepted-changes' | 'infrastructure-management-resource-watcher' | 'infrastructure-management-catalog-framework' | 'software-release-management-overview' | 'software-release-management-software-release' | 'cost-visibility-overview' | 'cost-visibility-cost-breakdown' | 'cost-visibility-configurations' | 'security-center-overview' | 'security-center-application-security' | 'security-center-security-policies' | 'automation-and-enablement-jobs' | 'automation-and-enablement-alerting' | 'automation-and-enablement-incident-response' | 'automation-and-enablement-api-portal' | 'automation-and-enablement-runbook-automation' | 'global-configuration-sso-login-services' | 'global-configuration-host-urls' | 'global-configuration-cluster-and-environments' | 'global-configuration-container-oci-registry' | 'global-configuration-authorization';
|
5
|
+
export type NavigationSubMenuItemID = 'application-management-configurations-gitops' | 'application-management-configurations-git-accounts' | 'application-management-configurations-external-links' | 'application-management-configurations-chart-repository' | 'application-management-configurations-deployment-charts' | 'application-management-configurations-notifications' | 'application-management-configurations-catalog-frameworks' | 'application-management-configurations-scoped-variables' | 'application-management-configurations-build-infra' | 'application-management-policies-deployment-window' | 'application-management-policies-approval-policy' | 'application-management-policies-plugin-policy' | 'application-management-policies-pull-image-digest' | 'application-management-policies-tag-policy' | 'application-management-policies-filter-conditions' | 'application-management-policies-lock-deployment-configuration' | 'application-management-others-application-templates' | 'application-management-others-projects' | 'cost-visibility-cost-breakdown-clusters' | 'cost-visibility-cost-breakdown-environments' | 'cost-visibility-cost-breakdown-projects' | 'cost-visibility-cost-breakdown-applications' | 'global-configuration-authorization-user-permissions' | 'global-configuration-authorization-permission-groups' | 'global-configuration-authorization-api-tokens';
|
4
6
|
export interface GetUserPreferencesQueryParamsType {
|
5
7
|
key: typeof USER_PREFERENCES_ATTRIBUTE_KEY;
|
6
8
|
}
|
@@ -36,13 +38,18 @@ export interface GetUserPreferencesParsedDTO {
|
|
36
38
|
*
|
37
39
|
*/
|
38
40
|
resources?: UserPreferenceResourceType;
|
41
|
+
commandBar: {
|
42
|
+
recentNavigationActions: {
|
43
|
+
id: NavigationItemID | NavigationSubMenuItemID;
|
44
|
+
}[];
|
45
|
+
};
|
39
46
|
}
|
40
47
|
export interface UserPreferencesPayloadValueType extends GetUserPreferencesParsedDTO {
|
41
48
|
}
|
42
49
|
export interface UpdateUserPreferencesPayloadType extends Pick<GetUserPreferencesQueryParamsType, 'key'> {
|
43
50
|
value: string;
|
44
51
|
}
|
45
|
-
export interface UserPreferencesType {
|
52
|
+
export interface UserPreferencesType extends Pick<GetUserPreferencesParsedDTO, 'commandBar'> {
|
46
53
|
/**
|
47
54
|
* Preferred theme for the user
|
48
55
|
* If null, would forcibly show user theme switcher dialog for user to select
|
@@ -69,7 +76,7 @@ export interface UseUserPreferencesProps {
|
|
69
76
|
migrateUserPreferences?: (userPreferencesResponse: UserPreferencesType) => Promise<UserPreferencesType>;
|
70
77
|
recentlyVisitedFetchConfig?: RecentlyVisitedFetchConfigType;
|
71
78
|
}
|
72
|
-
|
79
|
+
type UserPathValueMapType = {
|
73
80
|
path: 'themePreference';
|
74
81
|
value: Required<Pick<UpdatedUserPreferencesType, 'themePreference' | 'appTheme'>>;
|
75
82
|
resourceKind?: never;
|
@@ -84,7 +91,28 @@ export type UserPathValueMapType = {
|
|
84
91
|
value: Required<BaseRecentlyVisitedEntitiesTypes[]>;
|
85
92
|
resourceKind: PreferredResourceKindType;
|
86
93
|
userPreferencesResponse?: UserPreferencesType;
|
94
|
+
} | {
|
95
|
+
path: 'commandBar.recentNavigationActions';
|
96
|
+
value: UserPreferencesType['commandBar']['recentNavigationActions'];
|
97
|
+
resourceKind?: never;
|
98
|
+
userPreferencesResponse?: never;
|
87
99
|
};
|
100
|
+
export type GetUserPreferencePayloadParams = {
|
101
|
+
userPreferencesResponse: UserPreferencesType;
|
102
|
+
resourceKind?: PreferredResourceKindType;
|
103
|
+
} & ({
|
104
|
+
path: 'themePreference';
|
105
|
+
value: Required<Pick<UpdatedUserPreferencesType, 'themePreference' | 'appTheme'>>;
|
106
|
+
} | {
|
107
|
+
path: 'pipelineRBACViewSelectedTab';
|
108
|
+
value: Required<Pick<UserPreferencesType, 'pipelineRBACViewSelectedTab'>>;
|
109
|
+
} | {
|
110
|
+
path: 'resources';
|
111
|
+
value: Required<BaseRecentlyVisitedEntitiesTypes[]>;
|
112
|
+
} | {
|
113
|
+
path: 'commandBar.recentNavigationActions';
|
114
|
+
value: UserPreferencesType['commandBar']['recentNavigationActions'];
|
115
|
+
});
|
88
116
|
export type UserPreferenceResourceProps = UserPathValueMapType & {
|
89
117
|
shouldThrowError?: boolean;
|
90
118
|
userPreferencesResponse?: UserPreferencesType;
|
@@ -92,3 +120,4 @@ export type UserPreferenceResourceProps = UserPathValueMapType & {
|
|
92
120
|
export interface UserPreferenceFilteredListTypes extends UserPreferenceRecentlyVisitedAppsTypes {
|
93
121
|
userPreferencesResponse?: UserPreferencesType;
|
94
122
|
}
|
123
|
+
export {};
|