Browse Source

SONAR-17815 Updating links for learn more CAYC and translation changes

tags/9.9.0.65466
Revanshu Paliwal 1 year ago
parent
commit
2d1ab592f0

+ 3
- 5
server/sonar-web/src/main/js/apps/overview/branches/CleanAsYouCodeWarning.tsx View File

@@ -18,6 +18,7 @@
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
import * as React from 'react';
import DocLink from '../../../components/common/DocLink';
import Link from '../../../components/common/Link';
import { Alert } from '../../../components/ui/Alert';
import { translate } from '../../../helpers/l10n';
@@ -45,12 +46,9 @@ export default function CleanAsYouCodeWarning({ component }: Props) {
</div>
)}

<Link
target="_blank"
to="https://docs.sonarqube.org/latest/user-guide/clean-as-you-code/#quality-gate"
>
<DocLink to="/user-guide/clean-as-you-code/">
{translate('overview.quality_gate.conditions.cayc.link')}
</Link>
</DocLink>
</>
);
}

+ 3
- 1
server/sonar-web/src/main/js/apps/quality-gates/components/DetailsHeader.tsx View File

@@ -38,6 +38,8 @@ interface Props {
refreshList: () => Promise<void>;
}

const TOOLTIP_MOUSE_LEAVE_DELAY = 0.3;

export default class DetailsHeader extends React.PureComponent<Props> {
handleActionRefresh = () => {
const { refreshItem, refreshList } = this.props;
@@ -72,7 +74,7 @@ export default class DetailsHeader extends React.PureComponent<Props> {
<h2>{qualityGate.name}</h2>
{qualityGate.isBuiltIn && <BuiltInQualityGateBadge className="spacer-left" />}
{!qualityGate.isCaycCompliant && (
<Tooltip overlay={<CaycBadgeTooltip />}>
<Tooltip overlay={<CaycBadgeTooltip />} mouseLeaveDelay={TOOLTIP_MOUSE_LEAVE_DELAY}>
<AlertWarnIcon className="spacer-left" />
</Tooltip>
)}

+ 5
- 0
server/sonar-web/src/main/js/components/ui/Alert.tsx View File

@@ -97,6 +97,11 @@ const StyledAlert = styled.div<{ isInline: boolean; variantInfo: AlertVariantInf

a,
.button-link {
border-color: ${colors.primarya40};
}

a: hover,
.button-link:hover {
border-color: ${colors.darkBlue};
}
`;

+ 5
- 0
server/sonar-web/src/main/js/components/ui/__tests__/__snapshots__/Alert-test.tsx.snap View File

@@ -17,6 +17,11 @@ exports[`should render banner alert with correct css 1`] = `

.emotion-0 a,
.emotion-0 .button-link {
border-color: rgba(35, 107, 151, 0.40);
}

.emotion-0 a:hover,
.emotion-0 .button-link:hover {
border-color: #236a97;
}


+ 1
- 1
sonar-core/src/main/resources/org/sonar/l10n/core.properties View File

@@ -1854,7 +1854,7 @@ quality_gates.cayc.unlock_edit=Unlock editing
quality_gates.cayc.tooltip.message=This quality gate does not comply with Clean as You Code.
quality_gates.cayc.badge.tooltip.learn_more=Learn more: Clean as You Code
quality_gates.cayc.banner.title=This quality gate complies with Clean as You Code
quality_gates.cayc.banner.description=This quality gate complies with the {cayc_link} methodology so that you benefit from the most efficient approach to delivering Clean Code. The quality gate ensures that the {new_code_link} you’re working on has:
quality_gates.cayc.banner.description=This quality gate complies with the {cayc_link} methodology, so that you benefit from the most efficient approach to delivering Clean Code. The quality gate ensures that the {new_code_link} you’re working on has:
quality_gates.cayc.banner.list_item1=No bugs
quality_gates.cayc.banner.list_item2=No vulnerabilities
quality_gates.cayc.banner.list_item3=No security hotspots to review

Loading…
Cancel
Save