Skip to content

Commit 391240c

Browse files
authored
fix: Information button label in Connect Cluster dialog (#4083)
* fix: labels * fix: cleanup unused
1 parent 7cf4744 commit 391240c

File tree

2 files changed

+8
-20
lines changed

2 files changed

+8
-20
lines changed

src/components/Clusters/components/AuthForm.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ const OIDCform = ({ resource, setResource, ...props }) => {
5959
propertyPath="$.scopes"
6060
title={t('clusters.wizard.auth.scopes')}
6161
accessible-name={t('clusters.wizard.auth.scopes')}
62+
ariaLabel={t('clusters.wizard.auth.scopes')}
6263
/>
6364
</ResourceForm.Wrapper>
6465
);

src/components/Clusters/components/KubeconfigUpload/KubeconfigFileUpload.js

Lines changed: 7 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import { useState } from 'react';
22
import { FileInput } from 'shared/components/FileInput/FileInput';
3-
import { Title, Button, Popover, Text } from '@ui5/webcomponents-react';
3+
import { Title } from '@ui5/webcomponents-react';
44
import { useTranslation } from 'react-i18next';
5-
import { createPortal } from 'react-dom';
5+
import { HintButton } from 'shared/components/DescriptionHint/DescriptionHint';
66

77
export function KubeconfigFileUpload({ onKubeconfigTextAdded }) {
88
const { t } = useTranslation();
@@ -26,26 +26,13 @@ export function KubeconfigFileUpload({ onKubeconfigTextAdded }) {
2626
<Title level="H5" className="sap-margin-bottom-tiny">
2727
{t('clusters.wizard.kubeconfig')}
2828
<>
29-
<Button
30-
id="descriptionOpener"
31-
icon="hint"
32-
design="Transparent"
29+
<HintButton
30+
setShowTitleDescription={setShowTitleDescription}
31+
showTitleDescription={showTitleDescription}
32+
description={t('clusters.wizard.intro')}
3333
className="sap-margin-begin-tiny"
34-
onClick={() => {
35-
setShowTitleDescription(true);
36-
}}
34+
ariaTitle={t('clusters.wizard.kubeconfig')}
3735
/>
38-
{createPortal(
39-
<Popover
40-
opener="descriptionOpener"
41-
open={showTitleDescription}
42-
onClose={() => setShowTitleDescription(false)}
43-
placement="End"
44-
>
45-
<Text className="description">{t('clusters.wizard.intro')}</Text>
46-
</Popover>,
47-
document.body,
48-
)}
4936
</>
5037
</Title>
5138
<FileInput

0 commit comments

Comments
 (0)