Skip to content

Commit ee1bbc1

Browse files
authored
Merge pull request #284 from devtron-labs/refactor/compare-manifest
feat: Deployment Template, ConfigMap, Secret UI Revamp
2 parents c9ccf45 + d90f5d2 commit ee1bbc1

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+956
-198
lines changed

package-lock.json

Lines changed: 2 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: 1 addition & 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": "0.5.3",
3+
"version": "0.5.4",
44
"description": "Supporting common component library",
55
"type": "module",
66
"main": "dist/index.js",

src/Assets/Icon/ic-warning-y5.svg

Lines changed: 20 additions & 0 deletions
Loading

src/Common/ChartVersionAndTypeSelector.tsx

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,17 @@
1515
*/
1616

1717
import { useEffect, useState } from 'react'
18+
import { SelectPicker, SelectPickerVariantType } from '@Shared/Components'
1819
import { fetchChartTemplateVersions } from './Common.service'
19-
import { ChartVersionAndTypeSelectorProps, DeploymentChartVersionType } from './Types'
20+
import { ChartVersionAndTypeSelectorProps } from './Types'
2021
import { getFilteredChartVersions, showError } from './Helper'
21-
import { SelectPicker, SelectPickerVariantType } from '@Shared/Components'
22+
23+
interface DeploymentChartVersionType {
24+
chartRefId: number
25+
chartVersion: string
26+
chartType: string
27+
type: number
28+
}
2229

2330
// @TODO: Generalize this component to be used in CodeEditor as Chart selector toolbar
2431
// when the Code Editor is moved to the fe-common-lib

src/Common/CodeEditor/CodeEditor.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@ import ReactGA from 'react-ga4'
2121
import * as monaco from 'monaco-editor/esm/vs/editor/editor.api'
2222
import { configureMonacoYaml } from 'monaco-yaml'
2323

24+
import { ReactComponent as ICWarningY5 } from '@Icons/ic-warning-y5.svg'
2425
import { ReactComponent as Info } from '../../Assets/Icon/ic-info-filled.svg'
2526
import { ReactComponent as ErrorIcon } from '../../Assets/Icon/ic-error-exclamation.svg'
26-
import { ReactComponent as WarningIcon } from '../../Assets/Icon/ic-warning.svg'
2727
import './codeEditor.scss'
2828
import 'monaco-editor'
2929

@@ -452,7 +452,7 @@ const ValidationError = () => {
452452

453453
const Warning: React.FC<InformationBarProps> = (props) => (
454454
<div className={`code-editor__warning ${props.className || ''}`}>
455-
<WarningIcon className="code-editor__information-info-icon" />
455+
<ICWarningY5 className="code-editor__information-info-icon" />
456456
{props.text}
457457
{props.children}
458458
</div>
@@ -476,7 +476,7 @@ const Information: React.FC<InformationBarProps> = (props) => (
476476

477477
const Clipboard = () => {
478478
const { state } = useCodeEditorContext()
479-
return <ClipboardButton content={state.code} rootClassName="bcn-1" iconSize={20} />
479+
return <ClipboardButton content={state.code} iconSize={16} />
480480
}
481481

482482
const SplitPane = ({}) => {

src/Common/CodeEditor/codeEditor.scss

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -105,18 +105,6 @@
105105
min-height: 300px;
106106
}
107107

108-
.code-editor__warning {
109-
font-size: 12px;
110-
font-weight: 400;
111-
line-height: 1.33;
112-
letter-spacing: normal;
113-
color: var(--Y700);
114-
height: auto;
115-
padding: 8px 16px;
116-
border-bottom: 1px solid #d6dbdf;
117-
background-color: var(--Y100);
118-
}
119-
120108
.code-editor__information {
121109
font-size: 12px;
122110
font-weight: 400;

src/Common/Constants.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ export const DOCUMENTATION_HOME_PAGE = 'https://docs.devtron.ai'
2424
export const DOCUMENTATION_VERSION = '/v/v0.7'
2525
export const DISCORD_LINK = 'https://discord.devtron.ai/'
2626
export const DOCUMENTATION = {
27+
APP_METRICS: `${DOCUMENTATION_HOME_PAGE}${DOCUMENTATION_VERSION}/usage/applications/app-details/app-metrics`,
2728
APP_TAGS: `${DOCUMENTATION_HOME_PAGE}${DOCUMENTATION_VERSION}/usage/applications/create-application#tags`,
2829
APP_OVERVIEW_TAGS: `${DOCUMENTATION_HOME_PAGE}${DOCUMENTATION_VERSION}/usage/applications/overview#manage-tags`,
2930
BLOB_STORAGE: `${DOCUMENTATION_HOME_PAGE}${DOCUMENTATION_VERSION}/getting-started/install/installation-configuration#configuration-of-blob-storage`,
@@ -70,6 +71,7 @@ export const URLS = {
7071
export const ROUTES = {
7172
APP: 'app',
7273
APP_ARTIFACT_PROMOTE_MATERIAL: 'app/artifact/promotion-request/material',
74+
APP_TEMPLATE_DATA: 'app/template/data',
7375
PROJECT_LIST_MIN: 'team/autocomplete',
7476
USER_CHECK_ROLE: 'user/check/roles',
7577
IMAGE_TAGGING: 'app/image-tagging',
@@ -507,6 +509,7 @@ export const API_STATUS_CODES = {
507509
PERMISSION_DENIED: 403,
508510
NOT_FOUND: 404,
509511
EXPECTATION_FAILED: 417,
512+
LOCKED: 423,
510513
}
511514

512515
export enum SERVER_MODE {

src/Common/Helper.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -642,7 +642,7 @@ export const powerSetOfSubstringsFromStart = (strings: string[], regex: RegExp)
642642
return _keys
643643
})
644644

645-
export const convertJSONPointerToJSONPath = (pointer: string) => pointer.replace(/\//g, '.').replace(/\./, '$.')
645+
export const convertJSONPointerToJSONPath = (pointer: string) => pointer.replace(/\/([\*0-9]+)\//g, '[$1].').replace(/\//g, '.').replace(/\./, '$.')
646646

647647
export const flatMapOfJSONPaths = (
648648
paths: string[],

src/Common/Types.ts

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -771,6 +771,8 @@ export interface AppEnvironment {
771771
isProtected?: boolean
772772
pipelineId?: number
773773
latestCdWorkflowRunnerId?: number
774+
commits?: string[]
775+
ciArtifactId?: number
774776
}
775777

776778
export interface Strategy {
@@ -901,13 +903,6 @@ export interface CiPipeline {
901903
pipelineType?: string
902904
}
903905

904-
export interface DeploymentChartVersionType {
905-
chartRefId: number
906-
chartVersion: string
907-
chartType: string
908-
type: number
909-
}
910-
911906
export interface ChartVersionAndTypeSelectorProps {
912907
setSelectedChartRefId: React.Dispatch<React.SetStateAction<number>>
913908
}

src/Pages/App/AppConfigurations/index.ts

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)