Skip to content

Commit

Permalink
remove key, add aria-describedBy,format
Browse files Browse the repository at this point in the history
  • Loading branch information
jenny-s51 committed Nov 4, 2024
1 parent 3a75b9d commit 465607a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@ const ConnectionsList: React.FC = () => {
createButton={
<>
<Button
key={`action-${ProjectSectionID.CONNECTIONS}`}
variant="primary"
data-testid="create-connection-button"
aria-describedby={
Expand All @@ -90,11 +89,7 @@ const ConnectionsList: React.FC = () => {
Create connection
</Button>
{enabledConnectionTypes.length === 0 && (
<Tooltip
id="no-connection-types-tooltip"
content="No connection types available"
triggerRef={tooltipRef}
/>
<Tooltip content="No connection types available" triggerRef={tooltipRef} />
)}
</>
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,10 @@ import { createSecret, replaceSecret } from '~/api';
import { NotebookKind, ProjectKind } from '~/k8sTypes';
import { getDisplayNameFromK8sResource } from '~/concepts/k8s/utils';
import { Connection, ConnectionTypeConfigMapObj } from '~/concepts/connectionTypes/types';
import { filterEnabledConnectionTypes, getConnectionTypeDisplayName } from '~/concepts/connectionTypes/utils';
import {
filterEnabledConnectionTypes,
getConnectionTypeDisplayName,
} from '~/concepts/connectionTypes/utils';
import { useWatchConnectionTypes } from '~/utilities/useWatchConnectionTypes';
import { useNotebooksStates } from '~/pages/projects/notebook/useNotebooksStates';
import { SpawnerPageSectionTitles } from '~/pages/projects/screens/spawner/const';
Expand Down Expand Up @@ -143,6 +146,9 @@ export const ConnectionsFormSection: React.FC<Props> = ({
<FlexItem>
<Button
data-testid="create-connection-button"
aria-describedby={
unselectedConnections.length === 0 ? 'no-connection-types-tooltip' : undefined
}
variant="secondary"
id="no-connection-types-tooltip"
content="No connection types available"
Expand Down

0 comments on commit 465607a

Please sign in to comment.