UNPKG

@taboo/cms

Version:

A node.js powered CMS (Content Management System) that is built on Koa web framework, uses mongoose for MongoDB connections and has admin dashboard built in React with Mobx and Rsuite. It can be used as React client side application, or as server side ren

20 lines (16 loc) 499 B
import React from 'react'; import PropTypes from 'prop-types'; const BooleanIcon = ({ value, size = 'md', className = '', ...props }) => { let src = '/images/_shared/icon-cancel.png'; if (value) { src = '/images/_shared/icon-ok.png'; } className = `icon-img ${size} ${className}`; return <img src={src} {...props} className={className} />; }; BooleanIcon.propTypes = { value: PropTypes.bool, size: PropTypes.string, className: PropTypes.string, }; export default BooleanIcon;