Sha256: dd1d976818e567781fe57964db14cb6dd4a3176a1bded96408560a4b58932f0d

Contents?: true

Size: 655 Bytes

Versions: 67

Compression:

Stored size: 655 Bytes

Contents

import React from 'react';
import PropTypes from 'prop-types';
import { Label } from '@patternfly/react-core';
import { CheckCircleIcon } from '@patternfly/react-icons';
import { translate as __ } from 'foremanReact/common/I18n';
import InactiveText from '../scenes/ContentViews/components/InactiveText';

const AddedStatusLabel = ({ added }) => {
  if (added) {
    return (
      <Label variant="outline" color="green" icon={<CheckCircleIcon />}>
        {__('Added')}
      </Label>
    );
  }
  return <InactiveText text={__('Not added')} />;
};

AddedStatusLabel.propTypes = {
  added: PropTypes.bool.isRequired,
};

export default AddedStatusLabel;

Version data entries

67 entries across 67 versions & 1 rubygems

Version Path
katello-4.15.0.rc2 webpack/components/AddedStatusLabel.js
katello-4.15.0.rc1 webpack/components/AddedStatusLabel.js
katello-4.14.1 webpack/components/AddedStatusLabel.js
katello-4.14.0 webpack/components/AddedStatusLabel.js
katello-4.14.0.rc3 webpack/components/AddedStatusLabel.js
katello-4.14.0.rc2 webpack/components/AddedStatusLabel.js
katello-4.14.0.rc1.1 webpack/components/AddedStatusLabel.js
katello-4.14.0.rc1 webpack/components/AddedStatusLabel.js
katello-4.13.1 webpack/components/AddedStatusLabel.js
katello-4.13.0 webpack/components/AddedStatusLabel.js
katello-4.12.1 webpack/components/AddedStatusLabel.js
katello-4.13.0.rc1 webpack/components/AddedStatusLabel.js
katello-4.12.0 webpack/components/AddedStatusLabel.js
katello-4.12.0.rc3 webpack/components/AddedStatusLabel.js
katello-4.12.0.rc2 webpack/components/AddedStatusLabel.js
katello-4.12.0.rc1 webpack/components/AddedStatusLabel.js
katello-4.11.1 webpack/components/AddedStatusLabel.js
katello-4.11.0 webpack/components/AddedStatusLabel.js
katello-4.11.0.rc2 webpack/components/AddedStatusLabel.js
katello-4.11.0.rc1 webpack/components/AddedStatusLabel.js