From 5fce4d0f3ca97ca2d4487631b3de8706cc7c27ab Mon Sep 17 00:00:00 2001 From: shivani170 Date: Thu, 28 Aug 2025 10:38:11 +0530 Subject: [PATCH 01/11] chore: infrastructure management icon moved to common --- src/Common/Constants.ts | 1 + src/Shared/Components/DocLink/constants.ts | 2 +- .../Components/FeatureDescription/types.ts | 2 +- src/Shared/Components/Header/PageHeader.tsx | 13 +++++++++--- src/Shared/Components/Header/types.ts | 1 + .../InfrastructureManagementIcon/Index.tsx | 2 ++ .../InfrastructureManagementIcon.tsx | 20 +++++++++++++++++++ src/Shared/Components/index.ts | 1 + 8 files changed, 37 insertions(+), 5 deletions(-) create mode 100644 src/Shared/Components/InfrastructureManagementIcon/Index.tsx create mode 100644 src/Shared/Components/InfrastructureManagementIcon/InfrastructureManagementIcon.tsx diff --git a/src/Common/Constants.ts b/src/Common/Constants.ts index 449d69db6..01cf66dd4 100644 --- a/src/Common/Constants.ts +++ b/src/Common/Constants.ts @@ -173,6 +173,7 @@ export const ROUTES = { LICENSE_DATA: 'license/data', ENV: 'env', APP_METADATA: 'app-metadata', + SOFTWARE_DISTRIBUTION_HUB: '/software-distribution-hub', } as const export enum KEY_VALUE { diff --git a/src/Shared/Components/DocLink/constants.ts b/src/Shared/Components/DocLink/constants.ts index 2c114073e..3f3a6aa5a 100644 --- a/src/Shared/Components/DocLink/constants.ts +++ b/src/Shared/Components/DocLink/constants.ts @@ -116,7 +116,7 @@ export const DOCUMENTATION = { GLOBAL_CONFIG_PULL_IMAGE_DIGEST: 'global-configurations/pull-image-digest', GLOBAL_CONFIG_TAGS: 'getting-started/global-configurations/tags-policy', - // Software distribution hub + // Software Release Management SOFTWARE_DISTRIBUTION_HUB: 'usage/software-distribution-hub', RELEASE_TRACKS: 'usage/software-distribution-hub/release-hub#creating-release-tracks-and-versions', RELEASES: 'usage/software-distribution-hub/release-hub#creating-release-tracks-and-versions', diff --git a/src/Shared/Components/FeatureDescription/types.ts b/src/Shared/Components/FeatureDescription/types.ts index 3c1ce9bf2..c8120580a 100644 --- a/src/Shared/Components/FeatureDescription/types.ts +++ b/src/Shared/Components/FeatureDescription/types.ts @@ -51,7 +51,7 @@ type FeatureDescriptionModalWithTabsConfig = { } export type FeatureDescriptionModalProps = { - title: string + title: React.ReactNode closeModalText?: string closeModal?: () => void } & ( diff --git a/src/Shared/Components/Header/PageHeader.tsx b/src/Shared/Components/Header/PageHeader.tsx index b0916a840..a15405fe8 100644 --- a/src/Shared/Components/Header/PageHeader.tsx +++ b/src/Shared/Components/Header/PageHeader.tsx @@ -53,8 +53,15 @@ const PageHeader = ({ const { setLoginCount, setShowGettingStartedCard, setSidePanelConfig, sidePanelConfig } = useMainContext() const { showSwitchThemeLocationTippy, handleShowSwitchThemeLocationTippyChange } = useTheme() - const { isTippyCustomized, tippyRedirectLink, TippyIcon, tippyMessage, onClickTippyButton, additionalContent } = - tippyProps || {} + const { + isTippyCustomized, + tippyRedirectLink, + TippyIcon, + tippyMessage, + onClickTippyButton, + additionalContent, + tippyHeader, + } = tippyProps || {} const { email } = useUserEmail() const [currentServerInfo, setCurrentServerInfo] = useState<{ serverInfo: ServerInfo; fetchingServerInfo: boolean }>( { @@ -226,7 +233,7 @@ const PageHeader = ({ (isTippyCustomized ? ( tippyMessage?: string onClickTippyButton?: () => void + tippyHeader?: string } onClose?: () => void } diff --git a/src/Shared/Components/InfrastructureManagementIcon/Index.tsx b/src/Shared/Components/InfrastructureManagementIcon/Index.tsx new file mode 100644 index 000000000..e232a8896 --- /dev/null +++ b/src/Shared/Components/InfrastructureManagementIcon/Index.tsx @@ -0,0 +1,2 @@ +/* eslint-disable import/prefer-default-export */ +export { InfrastructureManagementIcon } from './InfrastructureManagementIcon' diff --git a/src/Shared/Components/InfrastructureManagementIcon/InfrastructureManagementIcon.tsx b/src/Shared/Components/InfrastructureManagementIcon/InfrastructureManagementIcon.tsx new file mode 100644 index 000000000..c0d7e60ee --- /dev/null +++ b/src/Shared/Components/InfrastructureManagementIcon/InfrastructureManagementIcon.tsx @@ -0,0 +1,20 @@ +import { URLS } from '@Common/Constants' +import { ComponentSizeType } from '@Shared/constants' + +import { Button, ButtonComponentType, ButtonVariantType } from '../Button' +import { Icon } from '../Icon' + +export const InfrastructureManagementIcon = () => ( +