Skip to content

Commit

Permalink
Fixed approve button look
Browse files Browse the repository at this point in the history
  • Loading branch information
rmathis committed Oct 28, 2022
1 parent cefb930 commit 0b8ccc8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion backend/src/main/resources/i18n/messages.properties
Original file line number Diff line number Diff line change
Expand Up @@ -812,7 +812,7 @@ message.algorithms-unique=Each algorithm may only be used once.

label.approve=Approve
label.disapprove=Unapprove
label.approval=Approval
label.approval=Approved
value.approved=Approved
value.disapproved=Not Approved
label.group-approvers=Approvers
Expand Down
7 changes: 4 additions & 3 deletions ui/src/app/metadata/domain/source/component/SourceList.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ import OverlayTrigger from 'react-bootstrap/OverlayTrigger';


import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
import { faTrash, faCheck } from '@fortawesome/free-solid-svg-icons';
import { faSquareCheck, faTrash } from '@fortawesome/free-solid-svg-icons';
import { faSquare } from '@fortawesome/free-regular-svg-icons';

import FormattedDate from '../../../../core/components/FormattedDate';
import Translate from '../../../../i18n/components/translate';
Expand Down Expand Up @@ -68,14 +69,14 @@ export default function SourceList({ entities, onDelete, onEnable, onApprove, on
<td className="text-center align-middle">
<span className="d-flex justify-content-center align-items-center">
{onApprove ?
<Button variant={source.approved ? 'outline-success' : 'outline-success' }
<Button variant={source.approved ? 'outline-success' : 'outline-primary' }
id={`approve-switch-${source.id}`}
size="sm" className=""
onClick={() => onApprove(source, !source.approved)}>
<span className=" me-1">
<Translate value={source.approved ? 'label.disapprove' : 'label.approve'} />
</span>
<FontAwesomeIcon size="lg" icon={faCheck} />
<FontAwesomeIcon size="lg" icon={source.approved ? faSquareCheck : faSquare} />
</Button>
:
<Badge bg={source.approved ? 'success' : 'danger'}>
Expand Down

0 comments on commit 0b8ccc8

Please sign in to comment.