diff options
-rw-r--r-- | server/sonar-web/src/main/js/app/components/GlobalFooter.tsx | 24 | ||||
-rw-r--r-- | sonar-core/src/main/resources/org/sonar/l10n/core.properties | 3 |
2 files changed, 20 insertions, 7 deletions
diff --git a/server/sonar-web/src/main/js/app/components/GlobalFooter.tsx b/server/sonar-web/src/main/js/app/components/GlobalFooter.tsx index cd6b1af6d72..06496f14848 100644 --- a/server/sonar-web/src/main/js/app/components/GlobalFooter.tsx +++ b/server/sonar-web/src/main/js/app/components/GlobalFooter.tsx @@ -27,6 +27,7 @@ import AppVersionStatus from '../../components/shared/AppVersionStatus'; import { COMMUNITY_FORUM_URL, DocLink } from '../../helpers/doc-links'; import { useDocUrl } from '../../helpers/docs'; import { getEdition } from '../../helpers/editions'; +import { EditionKey } from '../../types/editions'; import GlobalFooterBranding from './GlobalFooterBranding'; import { useAppState } from './app-state/withAppStateContext'; @@ -41,6 +42,8 @@ export default function GlobalFooter({ hideLoggedInInfo }: Readonly<GlobalFooter const docUrl = useDocUrl(); + const isCommunityBuildRunning = appState.edition === EditionKey.community; + return ( <StyledFooter className="sw-p-6" id="footer"> <div className="sw-typo-default sw-h-full sw-flex sw-flex-col sw-items-stretch"> @@ -73,12 +76,21 @@ export default function GlobalFooter({ hideLoggedInInfo }: Readonly<GlobalFooter )} <li> - <LinkStandalone - highlight={LinkHighlight.CurrentColor} - to="https://www.gnu.org/licenses/lgpl-3.0.txt" - > - {intl.formatMessage({ id: 'footer.license' })} - </LinkStandalone> + {isCommunityBuildRunning ? ( + <LinkStandalone + highlight={LinkHighlight.CurrentColor} + to="https://www.gnu.org/licenses/lgpl-3.0.txt" + > + {intl.formatMessage({ id: 'footer.license.lgplv3' })} + </LinkStandalone> + ) : ( + <LinkStandalone + highlight={LinkHighlight.CurrentColor} + to="https://www.sonarsource.com/legal/sonarqube/terms-and-conditions/" + > + {intl.formatMessage({ id: 'footer.license.sqs' })} + </LinkStandalone> + )} </li> <li> diff --git a/sonar-core/src/main/resources/org/sonar/l10n/core.properties b/sonar-core/src/main/resources/org/sonar/l10n/core.properties index 76efd8bddd1..4bf3975a842 100644 --- a/sonar-core/src/main/resources/org/sonar/l10n/core.properties +++ b/sonar-core/src/main/resources/org/sonar/l10n/core.properties @@ -4759,7 +4759,8 @@ footer.community=Community footer.contact_us=Contact us footer.documentation=Documentation footer.help=Help -footer.license=LGPL v3 +footer.license.lgplv3=LGPL v3 +footer.license.sqs=SonarQube Server Terms & Conditions footer.news=News footer.plugins=Plugins footer.pricing=Pricing |