Skip to content

Commit

Permalink
Give default title and action label to the application enable modal
Browse files Browse the repository at this point in the history
  • Loading branch information
DaoDaoNoCode committed Jan 15, 2025
1 parent bfe6c12 commit 998f891
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions frontend/src/pages/exploreApplication/EnableModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -99,17 +99,17 @@ const EnableModal: React.FC<EnableModalProps> = ({ selectedApp, shown, onClose }
className="odh-enable-modal"
data-id="enable-modal"
variant={ModalVariant.small}
title={enable.title}
title={enable.title || `Enable ${selectedApp.spec.displayName}`}

Check warning on line 102 in frontend/src/pages/exploreApplication/EnableModal.tsx

View check run for this annotation

Codecov / codecov/patch

frontend/src/pages/exploreApplication/EnableModal.tsx#L102

Added line #L102 was not covered by tests
isOpen
onClose={handleClose}
actions={[
<Button
key="confirm"
variant="primary"
onClick={onDoEnableApp}
isDisabled={validationInProgress || isEnableValuesHasEmptyValue}
isDisabled={validationInProgress || (enable.variables && isEnableValuesHasEmptyValue)}

Check warning on line 110 in frontend/src/pages/exploreApplication/EnableModal.tsx

View check run for this annotation

Codecov / codecov/patch

frontend/src/pages/exploreApplication/EnableModal.tsx#L110

Added line #L110 was not covered by tests
>
{enable.actionLabel}
{enable.actionLabel || 'Enable'}

Check warning on line 112 in frontend/src/pages/exploreApplication/EnableModal.tsx

View check run for this annotation

Codecov / codecov/patch

frontend/src/pages/exploreApplication/EnableModal.tsx#L112

Added line #L112 was not covered by tests
</Button>,
<Button key="cancel" variant="link" onClick={handleClose}>
{validationInProgress ? 'Close' : 'Cancel'}
Expand Down

0 comments on commit 998f891

Please sign in to comment.