Skip to content

Commit 775e5db

Browse files
committed
Merge branch 'develop' of https://github.com/devtron-labs/devtron-fe-common-lib into feat/day-picker
2 parents f27592a + 2163c58 commit 775e5db

35 files changed

+221
-68
lines changed

package-lock.json

Lines changed: 19 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@devtron-labs/devtron-fe-common-lib",
3-
"version": "1.20.6-pre-53",
3+
"version": "1.21.0-pre-0",
44
"description": "Supporting common component library",
55
"type": "module",
66
"main": "dist/index.js",
@@ -107,6 +107,7 @@
107107
"@codemirror/lint": "6.8.4",
108108
"@codemirror/merge": "^6.10.0",
109109
"@codemirror/search": "6.5.8",
110+
"@datasert/cronjs-parser": "^1.4.0",
110111
"@lezer/highlight": "1.2.1",
111112
"@replit/codemirror-indentation-markers": "6.5.3",
112113
"@replit/codemirror-vscode-keymap": "6.0.2",
@@ -118,6 +119,7 @@
118119
"ansi_up": "^5.2.1",
119120
"chart.js": "^4.5.0",
120121
"codemirror-json-schema": "0.8.0",
122+
"cronstrue": "^3.9.0",
121123
"dayjs": "^1.11.13",
122124
"fast-json-patch": "^3.1.1",
123125
"focus-trap-react": "^10.3.1",
Lines changed: 3 additions & 0 deletions
Loading
Lines changed: 3 additions & 0 deletions
Loading
Lines changed: 3 additions & 0 deletions
Loading

src/Common/BreadCrumb/BreadCrumb.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -114,9 +114,7 @@ export const BreadCrumb: React.FC<Breadcrumbs> = ({
114114
{breadcrumb.name}
115115
</ConditionalWrap>
116116

117-
{idx + 1 !== filteredCrumbs.length && breadcrumb.name && (
118-
getBreadCrumbSeparator(sep)
119-
)}
117+
{idx + 1 !== filteredCrumbs.length && breadcrumb.name && getBreadCrumbSeparator(sep)}
120118
</React.Fragment>
121119
))}
122120
</>

src/Common/CIPipeline.Types.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -338,6 +338,7 @@ export interface TaskErrorObj {
338338
name: ErrorObj
339339
inlineStepDetail?: StepDetailTaskErrorObj
340340
pluginRefStepDetail?: StepDetailTaskErrorObj
341+
outputDirectoryPath?: ErrorObj[]
341342
}
342343
export interface FormErrorObjectType {
343344
name: ErrorObj

src/Common/Constants.ts

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ const DATA_PROTECTION_BACKUP_AND_SCHEDULE =
6565
`${DATA_PROTECTION_ROOT}/backup-and-schedule/:view(${Object.values(BackupAndScheduleListViewEnum).join('|')})` as const
6666
const GLOBAL_CONFIG_ROOT = '/global-configuration'
6767
const AI_RECOMMENDATIONS_ROOT = '/ai-recommendations'
68+
const OBSERVABILITY_ROOT = '/observability'
6869

6970
export const URLS = {
7071
LOGIN: '/login',
@@ -131,7 +132,10 @@ export const URLS = {
131132
// SECURITY CENTER
132133
SECURITY_CENTER: SECURITY_CENTER_ROOT,
133134
SECURITY_CENTER_OVERVIEW: `${SECURITY_CENTER_ROOT}/overview`,
134-
SECURITY_CENTER_SCANS: `${SECURITY_CENTER_ROOT}/scans`,
135+
SECURITY_CENTER_VULNERABILITIES: `${SECURITY_CENTER_ROOT}/vulnerabilities`,
136+
SECURITY_CENTER_VULNERABILITY_DEPLOYMENTS: `${SECURITY_CENTER_ROOT}/vulnerabilities/deployments`,
137+
SECURITY_CENTER_VULNERABILITY_CVES: `${SECURITY_CENTER_ROOT}/vulnerabilities/cves`,
138+
SECURITY_CENTER_SECURITY_ENABLEMENT: `${SECURITY_CENTER_ROOT}/security-enablement`,
135139
SECURITY_CENTER_POLICIES: `${SECURITY_CENTER_ROOT}/policies`,
136140
// AUTOMATION AND ENABLEMENT
137141
AUTOMATION_AND_ENABLEMENT: AUTOMATION_AND_ENABLEMENT_ROOT,
@@ -154,6 +158,10 @@ export const URLS = {
154158
AI_RECOMMENDATIONS: AI_RECOMMENDATIONS_ROOT,
155159
AI_RECOMMENDATIONS_OVERVIEW: `${AI_RECOMMENDATIONS_ROOT}/overview`,
156160
EXTERNAL_APPS: 'ea',
161+
// OBSERVABILITY
162+
OBSERVABILITY: OBSERVABILITY_ROOT,
163+
OBSERVABILITY_OVERVIEW: `${OBSERVABILITY_ROOT}/overview`,
164+
OBSERVABILITY_CUSTOMER_LIST: `${OBSERVABILITY_ROOT}/tenants`,
157165
} as const
158166

159167
export const ROUTES = {

src/Common/SegmentedBarChart/SegmentedBarChart.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ const SegmentedBarChart: React.FC<SegmentedBarChartProps> = ({
3232
countClassName,
3333
labelClassName,
3434
isProportional,
35+
hideTotal,
3536
swapLegendAndBar = false,
3637
showAnimationOnBar = false,
3738
isLoading,
@@ -58,7 +59,7 @@ const SegmentedBarChart: React.FC<SegmentedBarChartProps> = ({
5859
<div className="shimmer w-64 lh-1-5 h-24" />
5960
) : (
6061
<span className={countClassName} data-testid={`segmented-bar-chart-${label}-value`}>
61-
{isProportional ? `${value}/${total}` : value}
62+
{isProportional && !hideTotal ? `${value}/${total}` : value}
6263
</span>
6364
)
6465

src/Common/SegmentedBarChart/types.ts

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,23 @@ type EntityPropType =
3232
entities: NonNullable<Omit<Entity, 'label'> & { label?: never }>[]
3333
}
3434

35+
type ProportionalType =
36+
| {
37+
isProportional?: true
38+
hideTotal?: boolean
39+
}
40+
| {
41+
isProportional?: false | never
42+
hideTotal?: never
43+
}
44+
3545
export type SegmentedBarChartProps = {
3646
rootClassName?: string
3747
countClassName?: string
3848
labelClassName?: string
39-
isProportional?: boolean
4049
swapLegendAndBar?: boolean
4150
showAnimationOnBar?: boolean
4251
isLoading?: boolean
4352
size?: ComponentSizeType
44-
} & EntityPropType
53+
} & EntityPropType &
54+
ProportionalType

0 commit comments

Comments
 (0)