Skip to content

Commit

Permalink
fix(ComplianceRemediationButton): RHICOMPL-873 color
Browse files Browse the repository at this point in the history
Fixes color of ComplianceRemediationButton to match button primary color
(white).  The color is also used for on disabled state.

In general scenario the icon within a button would share the same color
as the text.  Unfortunately, this is not the case (?).

Use of direct CSS variables is deliberate for consistency.  Previously
used background color (provided from react-tokens) had a wrong color.
  • Loading branch information
vkrizan committed Jan 4, 2021
1 parent 9ad16f3 commit 0ae6976
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { RemediationButton } from '@redhat-cloud-services/frontend-components-re
import flatten from 'lodash/flatten';
import { connect } from 'react-redux';
import { addNotification } from '@redhat-cloud-services/frontend-components-notifications';
import globalBackgroundColor100 from '@patternfly/react-tokens/dist/js/global_BackgroundColor_100';
import { AnsibeTowerIcon } from '@patternfly/react-icons';

class ComplianceRemediationButton extends React.Component {
Expand Down Expand Up @@ -69,7 +68,7 @@ class ComplianceRemediationButton extends React.Component {
onRemediationCreated={ result => addNotification(result.getNotification()) }
dataProvider={ this.dataProvider }
>
<AnsibeTowerIcon size='sm' color={globalBackgroundColor100.value} />
<AnsibeTowerIcon size='sm' color='var(--pf-c-button--m-primary--Color)' />
&nbsp;Remediate
</RemediationButton>
</React.Fragment>
Expand Down

0 comments on commit 0ae6976

Please sign in to comment.