From 1d4b45c8b37cc57c8577744df7adc3de0afc945f Mon Sep 17 00:00:00 2001 From: Viktor Vorona Date: Fri, 23 Aug 2024 15:49:17 +0200 Subject: [PATCH] SONAR-22728 Change Activity Split line text --- .../js/components/charts/SplitLinePopover.tsx | 2 +- .../js/components/common/DocumentationLink.tsx | 16 ++++++++++++---- .../resources/org/sonar/l10n/core.properties | 2 +- 3 files changed, 14 insertions(+), 6 deletions(-) diff --git a/server/sonar-web/src/main/js/components/charts/SplitLinePopover.tsx b/server/sonar-web/src/main/js/components/charts/SplitLinePopover.tsx index 3d29dc59f22..5fab13951de 100644 --- a/server/sonar-web/src/main/js/components/charts/SplitLinePopover.tsx +++ b/server/sonar-web/src/main/js/components/charts/SplitLinePopover.tsx @@ -45,7 +45,7 @@ export default function SplitLinePopover({ paddingLeft, splitPointDate, xScale } title={translate('project_activity.graphs.rating_split.title')} description={translate('project_activity.graphs.rating_split.description')} footer={ - + {translate('learn_more')} } diff --git a/server/sonar-web/src/main/js/components/common/DocumentationLink.tsx b/server/sonar-web/src/main/js/components/common/DocumentationLink.tsx index 1942843ef1f..b95aeeb4688 100644 --- a/server/sonar-web/src/main/js/components/common/DocumentationLink.tsx +++ b/server/sonar-web/src/main/js/components/common/DocumentationLink.tsx @@ -18,15 +18,23 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -import { Link, LinkProps } from '@sonarsource/echoes-react'; +import { Link, LinkProps, LinkStandalone } from '@sonarsource/echoes-react'; import * as React from 'react'; import { DocLink } from '../../helpers/doc-links'; import { useDocUrl } from '../../helpers/docs'; -type Props = Omit & { innerRef?: React.Ref; to: DocLink }; +type Props = Omit & { + innerRef?: React.Ref; + standalone?: boolean; + to: DocLink; +}; -export default function DocumentationLink({ to, innerRef, ...props }: Props) { +export default function DocumentationLink({ to, innerRef, standalone = false, ...props }: Props) { const toStatic = useDocUrl(to); - return ; + return standalone ? ( + + ) : ( + + ); } 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 048ad0b33ee..a0cbeea5099 100644 --- a/sonar-core/src/main/resources/org/sonar/l10n/core.properties +++ b/sonar-core/src/main/resources/org/sonar/l10n/core.properties @@ -2034,7 +2034,7 @@ project_activity.graphs.data_table.no_data_warning_check_dates_x_y=There is no d project_activity.graphs.data_table.data_gap=The chart history for issues related to software qualities may contain gaps while information is not available for one or more projects. {learn_more} project_activity.graphs.rating_split.title=Metrics calculation changed -project_activity.graphs.rating_split.description=The way we calculate ratings has changed and it might have affected your ratings. +project_activity.graphs.rating_split.description=The way we calculate ratings has changed and it might have affected this metric's values. project_activity.graphs.rating_split.info_icon=Metrics calculation change information project_activity.custom_metric.covered_lines=Covered Lines -- 2.39.5